From 9aed362d1dc28f4cde19efcc61f93ef66992e936 Mon Sep 17 00:00:00 2001 From: Arie Date: Thu, 15 Aug 2024 15:23:02 +0200 Subject: [PATCH] Add types to user class --- app/models/user.rb | 30 +- db/schema.rb | 3 +- sorbet/config | 2 + sorbet/rbi/annotations/.gitattributes | 1 + sorbet/rbi/annotations/actionmailer.rbi | 4 +- sorbet/rbi/annotations/actionpack.rbi | 49 +- sorbet/rbi/annotations/actionview.rbi | 6 +- sorbet/rbi/annotations/activejob.rbi | 44 + sorbet/rbi/annotations/activemodel.rbi | 6 +- sorbet/rbi/annotations/activerecord.rbi | 19 +- sorbet/rbi/annotations/activesupport.rbi | 320 +- sorbet/rbi/annotations/devise.rbi | 168 + sorbet/rbi/annotations/faraday.rbi | 2 +- sorbet/rbi/annotations/globalid.rbi | 2 +- sorbet/rbi/annotations/minitest.rbi | 119 + sorbet/rbi/annotations/railties.rbi | 5 +- sorbet/rbi/annotations/rainbow.rbi | 8 +- sorbet/rbi/annotations/sidekiq.rbi | 47 +- sorbet/rbi/annotations/stripe.rbi | 251 +- sorbet/rbi/annotations/webmock.rbi | 2 +- sorbet/rbi/dsl/.gitattributes | 1 + .../rbi/dsl/abstract_controller/caching.rbi | 1 + .../abstract_controller/caching/fragments.rbi | 1 + .../rbi/dsl/abstract_controller/callbacks.rbi | 1 + .../rbi/dsl/abstract_controller/helpers.rbi | 1 + .../rbi/dsl/abstract_controller/rendering.rbi | 1 + .../rbi/dsl/abstract_controller/url_for.rbi | 1 + .../dsl/action_cable/channel/callbacks.rbi | 1 + .../action_cable/channel/periodic_timers.rbi | 1 + .../connection/callbacks.rbi} | 14 +- .../connection/identification.rbi | 24 + .../dsl/action_controller/api_rendering.rbi | 1 + sorbet/rbi/dsl/action_controller/caching.rbi | 1 + .../dsl/action_controller/conditional_get.rbi | 1 + .../content_security_policy.rbi | 1 + .../dsl/action_controller/data_streaming.rbi | 1 + .../dsl/action_controller/etag_with_flash.rbi | 1 + .../etag_with_template_digest.rbi | 1 + sorbet/rbi/dsl/action_controller/flash.rbi | 1 + .../dsl/action_controller/form_builder.rbi | 1 + sorbet/rbi/dsl/action_controller/helpers.rbi | 1 + .../dsl/action_controller/params_wrapper.rbi | 1 + .../rbi/dsl/action_controller/redirecting.rbi | 1 + .../rbi/dsl/action_controller/renderers.rbi | 1 + .../dsl/action_controller/renderers/all.rbi | 1 + .../request_forgery_protection.rbi | 1 + sorbet/rbi/dsl/action_controller/rescue.rbi | 1 + .../dsl/action_controller/respond_with.rbi | 1 + .../action_controller/test_case/behavior.rbi | 1 + sorbet/rbi/dsl/action_controller/url_for.rbi | 1 + sorbet/rbi/dsl/action_dispatch/assertions.rbi | 10 + .../dsl/action_dispatch/integration_test.rbi | 1 + .../routing/route_set/mounted_helpers.rbi | 1 + .../dsl/action_dispatch/routing/url_for.rbi | 1 + .../dsl/action_mailbox/base_controller.rbi | 18 - .../rbi/dsl/action_mailbox/inbound_email.rbi | 823 - .../dsl/action_mailbox/incineration_job.rbi | 15 - .../mailgun/inbound_emails_controller.rbi | 18 - .../mandrill/inbound_emails_controller.rbi | 18 - .../postmark/inbound_emails_controller.rbi | 18 - .../relay/inbound_emails_controller.rbi | 18 - .../sendgrid/inbound_emails_controller.rbi | 18 - sorbet/rbi/dsl/action_mailbox/routing_job.rbi | 15 - sorbet/rbi/dsl/action_mailer/callbacks.rbi | 23 + .../dsl/action_mailer/delivery_methods.rbi | 1 + sorbet/rbi/dsl/action_mailer/form_builder.rbi | 20 + .../dsl/action_mailer/mail_delivery_job.rbi | 6 +- .../rbi/dsl/action_mailer/queued_delivery.rbi | 30 + sorbet/rbi/dsl/action_mailer/rescuable.rbi | 1 + .../dsl/action_mailer/test_case/behavior.rbi | 1 + .../dsl/action_text/encrypted_rich_text.rbi | 855 +- sorbet/rbi/dsl/action_text/rich_text.rbi | 856 +- sorbet/rbi/dsl/action_view/helpers.rbi | 1 + .../dsl/action_view/helpers/form_helper.rbi | 1 + .../action_view/helpers/form_tag_helper.rbi | 1 + .../dsl/action_view/helpers/text_helper.rbi | 1 + sorbet/rbi/dsl/action_view/layouts.rbi | 6 +- sorbet/rbi/dsl/action_view/rendering.rbi | 1 + sorbet/rbi/dsl/active_job/callbacks.rbi | 1 + sorbet/rbi/dsl/active_job/enqueuing.rbi | 19 + sorbet/rbi/dsl/active_job/exceptions.rbi | 10 +- sorbet/rbi/dsl/active_job/execution.rbi | 1 + sorbet/rbi/dsl/active_job/logging.rbi | 1 + sorbet/rbi/dsl/active_job/queue_adapter.rbi | 1 + sorbet/rbi/dsl/active_job/queue_name.rbi | 1 + sorbet/rbi/dsl/active_job/queue_priority.rbi | 1 + .../test_helper/test_queue_adapter.rbi | 1 + sorbet/rbi/dsl/active_model/api.rbi | 5 + .../dsl/active_model/attribute_methods.rbi | 11 +- sorbet/rbi/dsl/active_model/attributes.rbi | 18 +- sorbet/rbi/dsl/active_model/conversion.rbi | 22 + sorbet/rbi/dsl/active_model/dirty.rbi | 11 +- sorbet/rbi/dsl/active_model/model.rbi | 5 + .../rbi/dsl/active_model/serializers/json.rbi | 1 + sorbet/rbi/dsl/active_model/validations.rbi | 1 + .../active_model/validations/callbacks.rbi | 1 + .../dsl/active_record/attribute_methods.rbi | 14 +- .../active_record/attribute_methods/dirty.rbi | 11 +- .../attribute_methods/serialization.rbi | 20 + .../time_zone_conversion.rbi | 1 + sorbet/rbi/dsl/active_record/attributes.rbi | 13 +- sorbet/rbi/dsl/active_record/callbacks.rbi | 1 + sorbet/rbi/dsl/active_record/core.rbi | 16 +- .../rbi/dsl/active_record/counter_cache.rbi | 26 + .../destroy_association_async_job.rbi | 33 - .../encryption/encryptable_record.rbi | 1 + sorbet/rbi/dsl/active_record/inheritance.rbi | 1 + sorbet/rbi/dsl/active_record/integration.rbi | 1 + .../dsl/active_record/internal_metadata.rbi | 905 - .../dsl/active_record/locking/optimistic.rbi | 1 + sorbet/rbi/dsl/active_record/model_schema.rbi | 1 + .../dsl/active_record/nested_attributes.rbi | 1 + .../rbi/dsl/active_record/normalization.rbi | 24 + .../dsl/active_record/readonly_attributes.rbi | 1 + sorbet/rbi/dsl/active_record/reflection.rbi | 6 + .../dsl/active_record/schema_migration.rbi | 734 - sorbet/rbi/dsl/active_record/scoping.rbi | 1 + .../rbi/dsl/active_record/scoping/default.rbi | 1 + .../rbi/dsl/active_record/secure_password.rbi | 10 + .../rbi/dsl/active_record/serialization.rbi | 1 + sorbet/rbi/dsl/active_record/signed_id.rbi | 1 + .../rbi/dsl/active_record/test_fixtures.rbi | 58 - sorbet/rbi/dsl/active_record/timestamp.rbi | 1 + sorbet/rbi/dsl/active_record/token_for.rbi | 21 + .../dsl/active_reservation_checker_worker.rbi | 1 + .../active_reservations_checker_worker.rbi | 1 + sorbet/rbi/dsl/active_storage/analyze_job.rbi | 10 +- sorbet/rbi/dsl/active_storage/attachment.rbi | 817 +- .../dsl/active_storage/base_controller.rbi | 18 - sorbet/rbi/dsl/active_storage/blob.rbi | 1056 +- .../active_storage/blobs/proxy_controller.rbi | 18 - .../blobs/redirect_controller.rbi | 18 - sorbet/rbi/dsl/active_storage/current.rbi | 15 +- .../direct_uploads_controller.rbi | 18 - .../dsl/active_storage/disk_controller.rbi | 18 - sorbet/rbi/dsl/active_storage/mirror_job.rbi | 11 +- .../dsl/active_storage/preview_image_job.rbi | 22 + sorbet/rbi/dsl/active_storage/purge_job.rbi | 10 +- .../reflection/active_record_extensions.rbi | 1 + .../representations/base_controller.rbi | 18 - .../representations/proxy_controller.rbi | 18 - .../representations/redirect_controller.rbi | 18 - sorbet/rbi/dsl/active_storage/streaming.rbi | 1 + .../rbi/dsl/active_storage/transform_job.rbi | 22 + .../rbi/dsl/active_storage/variant_record.rbi | 667 +- .../dsl/active_support/actionable_error.rbi | 1 + sorbet/rbi/dsl/active_support/callbacks.rbi | 1 + sorbet/rbi/dsl/active_support/rescuable.rbi | 1 + .../active_support/testing/file_fixtures.rbi | 1 + .../dsl/allow_reservation_player_worker.rbi | 1 + sorbet/rbi/dsl/announce_donator_worker.rbi | 1 + sorbet/rbi/dsl/api/application_controller.rbi | 1 + sorbet/rbi/dsl/api/donators_controller.rbi | 36 - .../dsl/api/league_requests_controller.rbi | 36 - sorbet/rbi/dsl/api/maps_controller.rbi | 36 - .../rbi/dsl/api/reservations_controller.rbi | 36 - sorbet/rbi/dsl/api/servers_controller.rbi | 36 - sorbet/rbi/dsl/api/users_controller.rbi | 36 - sorbet/rbi/dsl/application_controller.rbi | 4 + sorbet/rbi/dsl/available_maps_worker.rbi | 19 + .../carrier_wave/compatibility/paperclip.rbi | 1 + .../rbi/dsl/carrier_wave/uploader/cache.rbi | 1 + .../dsl/carrier_wave/uploader/callbacks.rbi | 1 + .../carrier_wave/uploader/configuration.rbi | 1 + .../dsl/carrier_wave/uploader/download.rbi | 1 + .../dsl/carrier_wave/uploader/processing.rbi | 1 + .../rbi/dsl/carrier_wave/uploader/remove.rbi | 1 + .../rbi/dsl/carrier_wave/uploader/store.rbi | 1 + sorbet/rbi/dsl/carrier_wave/uploader/url.rbi | 1 + .../dsl/carrier_wave/uploader/versions.rbi | 1 + sorbet/rbi/dsl/cleanup_worker.rbi | 1 + sorbet/rbi/dsl/cron_worker.rbi | 1 + .../dsl/devise/confirmations_controller.rbi | 58 - sorbet/rbi/dsl/devise/failure_app.rbi | 1 + sorbet/rbi/dsl/devise/mailer.rbi | 1 + .../rbi/dsl/devise/models/authenticatable.rbi | 1 + .../devise/omniauth_callbacks_controller.rbi | 58 - .../rbi/dsl/devise/passwords_controller.rbi | 58 - .../dsl/devise/registrations_controller.rbi | 58 - sorbet/rbi/dsl/devise/sessions_controller.rbi | 58 - sorbet/rbi/dsl/devise/unlocks_controller.rbi | 58 - sorbet/rbi/dsl/devise_controller.rbi | 1 + sorbet/rbi/dsl/disable_mitigations_worker.rbi | 1 + sorbet/rbi/dsl/donators_controller.rbi | 48 - sorbet/rbi/dsl/file_upload.rbi | 495 +- sorbet/rbi/dsl/file_uploads_controller.rbi | 48 - .../rbi/dsl/generated_path_helpers_module.rbi | 98 +- .../rbi/dsl/generated_url_helpers_module.rbi | 98 +- sorbet/rbi/dsl/group.rbi | 478 +- sorbet/rbi/dsl/group_server.rbi | 504 +- sorbet/rbi/dsl/group_user.rbi | 522 +- sorbet/rbi/dsl/hiperz_server.rbi | 2296 - sorbet/rbi/dsl/hiperz_server_information.rbi | 869 - .../dsl/inactive_server_checker_worker.rbi | 13 +- .../dsl/inactive_servers_checker_worker.rbi | 1 + sorbet/rbi/dsl/league_requests_controller.rbi | 48 - sorbet/rbi/dsl/local_server.rbi | 667 +- sorbet/rbi/dsl/location.rbi | 486 +- sorbet/rbi/dsl/log_scan_worker.rbi | 1 + sorbet/rbi/dsl/log_upload.rbi | 527 +- sorbet/rbi/dsl/log_uploads_controller.rbi | 1 + sorbet/rbi/dsl/log_worker.rbi | 1 + sorbet/rbi/dsl/map_upload.rbi | 557 +- sorbet/rbi/dsl/map_uploads_controller.rbi | 48 - ...hly_donation_progress_announcer_worker.rbi | 1 + sorbet/rbi/dsl/nfo_server.rbi | 667 +- sorbet/rbi/dsl/order.rbi | 547 +- sorbet/rbi/dsl/orders_controller.rbi | 48 - sorbet/rbi/dsl/pages_controller.rbi | 48 - sorbet/rbi/dsl/paypal_order.rbi | 535 +- sorbet/rbi/dsl/player_statistic.rbi | 525 +- .../rbi/dsl/player_statistics_controller.rbi | 48 - .../rbi/dsl/private_server_cleanup_worker.rbi | 1 + sorbet/rbi/dsl/private_servers_controller.rbi | 48 - sorbet/rbi/dsl/product.rbi | 482 +- .../inbound_emails/sources_controller.rbi | 36 - .../inbound_emails_controller.rbi | 36 - .../action_mailbox/incinerates_controller.rbi | 36 - .../action_mailbox/reroutes_controller.rbi | 36 - .../dsl/rails/conductor/base_controller.rbi | 39 - sorbet/rbi/dsl/rcon_ftp_server.rbi | 672 +- sorbet/rbi/dsl/remote_server.rbi | 672 +- sorbet/rbi/dsl/reservation.rbi | 764 +- sorbet/rbi/dsl/reservation_player.rbi | 516 +- sorbet/rbi/dsl/reservation_status.rbi | 500 +- sorbet/rbi/dsl/reservation_worker.rbi | 1 + sorbet/rbi/dsl/reservations_controller.rbi | 1 + sorbet/rbi/dsl/sentry/send_event_job.rbi | 22 + sorbet/rbi/dsl/server.rbi | 673 +- sorbet/rbi/dsl/server_config.rbi | 540 +- sorbet/rbi/dsl/server_notification.rbi | 455 +- sorbet/rbi/dsl/server_notification_worker.rbi | 1 + sorbet/rbi/dsl/server_statistic.rbi | 557 +- .../rbi/dsl/server_statistics_controller.rbi | 48 - sorbet/rbi/dsl/server_update_worker.rbi | 19 + sorbet/rbi/dsl/server_upload.rbi | 545 +- ...s_worker.rbi => server_version_worker.rbi} | 7 +- sorbet/rbi/dsl/servers_controller.rbi | 48 - .../rbi/dsl/servers_notification_worker.rbi | 1 + sorbet/rbi/dsl/sessions_controller.rbi | 58 - sorbet/rbi/dsl/simrai_server.rbi | 2278 - sorbet/rbi/dsl/sprockets/rails/context.rbi | 1 + sorbet/rbi/dsl/sprockets/rails/helper.rbi | 1 + sorbet/rbi/dsl/ssh_server.rbi | 667 +- sorbet/rbi/dsl/stac_log.rbi | 1281 + .../rbi/dsl/stac_logs_downloader_worker.rbi | 19 + sorbet/rbi/dsl/stripe_order.rbi | 535 +- sorbet/rbi/dsl/time.rbi | 13 + sorbet/rbi/dsl/tragic_server.rbi | 672 +- .../turbo/native/navigation_controller.rbi | 18 - .../turbo/streams/action_broadcast_job.rbi | 19 +- .../rbi/dsl/turbo/streams/broadcast_job.rbi | 11 +- .../turbo/streams/broadcast_stream_job.rbi | 22 + sorbet/rbi/dsl/update_server_page_worker.rbi | 1 + .../rbi/dsl/update_steam_nickname_worker.rbi | 1 + .../rbi/dsl/upload_files_to_server_worker.rbi | 1 + .../dsl/upload_files_to_servers_worker.rbi | 1 + sorbet/rbi/dsl/user.rbi | 686 +- sorbet/rbi/dsl/users_controller.rbi | 48 - sorbet/rbi/dsl/voucher.rbi | 564 +- sorbet/rbi/dsl/vouchers_controller.rbi | 48 - sorbet/rbi/dsl/whitelist.rbi | 535 +- sorbet/rbi/dsl/whitelist_tf.rbi | 486 +- sorbet/rbi/gems/.gitattributes | 1 + ...ncable@7.0.5.rbi => actioncable@7.2.0.rbi} | 2452 +- sorbet/rbi/gems/actionmailbox@7.0.5.rbi | 1435 - sorbet/rbi/gems/actionmailbox@7.2.0.rbi | 9 + ...ailer@7.0.5.rbi => actionmailer@7.2.0.rbi} | 1020 +- ...ionpack@7.0.5.rbi => actionpack@7.2.0.rbi} | 17835 +++---- sorbet/rbi/gems/actiontext@7.0.5.rbi | 1503 - sorbet/rbi/gems/actiontext@7.2.0.rbi | 1851 + ...ionview@7.0.5.rbi => actionview@7.2.0.rbi} | 6181 +-- ...ctivejob@7.0.5.rbi => activejob@7.2.0.rbi} | 966 +- .../activemodel-serializers-xml@1.0.2.rbi | 10 +- ...emodel@7.0.5.rbi => activemodel@7.2.0.rbi} | 1967 +- ...ecord@7.0.5.rbi => activerecord@7.2.0.rbi} | 17860 ++++--- sorbet/rbi/gems/activestorage@7.0.5.rbi | 2127 - sorbet/rbi/gems/activestorage@7.2.0.rbi | 3711 ++ ...port@7.0.5.rbi => activesupport@7.2.0.rbi} | 9143 ++-- ...ssable@2.8.4.rbi => addressable@2.8.7.rbi} | 304 +- ...irbrussh@1.4.1.rbi => airbrussh@1.5.2.rbi} | 1 + sorbet/rbi/gems/american_date@1.2.0.rbi | 8 - sorbet/rbi/gems/american_date@1.3.0.rbi | 26 + sorbet/rbi/gems/ast@2.4.2.rbi | 1 + ...0.rbi => autoprefixer-rails@10.4.19.0.rbi} | 1 + sorbet/rbi/gems/aws-eventstream@1.3.0.rbi | 380 + sorbet/rbi/gems/aws-partitions@1.963.0.rbi | 694 + sorbet/rbi/gems/aws-sdk-core@3.201.4.rbi | 18475 ++++++++ sorbet/rbi/gems/aws-sdk-kms@1.88.0.rbi | 11712 +++++ sorbet/rbi/gems/aws-sdk-s3@1.157.0.rbi | 32299 +++++++++++++ sorbet/rbi/gems/aws-sigv4@1.9.1.rbi | 664 + sorbet/rbi/gems/backport@1.2.0.rbi | 1 + sorbet/rbi/gems/base32_pure@0.1.0.rbi | 1 + sorbet/rbi/gems/base64@0.2.0.rbi | 507 + .../{bcrypt@3.1.18.rbi => bcrypt@3.1.20.rbi} | 11 +- ...pbkdf@1.1.0.rbi => bcrypt_pbkdf@1.1.1.rbi} | 1 + ...enchmark@0.2.1.rbi => benchmark@0.3.0.rbi} | 80 +- sorbet/rbi/gems/better_errors@2.10.1.rbi | 1 + sorbet/rbi/gems/bigdecimal@3.1.8.rbi | 78 + ...@1.0.0.rbi => binding_of_caller@1.0.1.rbi} | 1 + sorbet/rbi/gems/bootsnap@1.18.4.rbi | 970 + sorbet/rbi/gems/bootstrap@4.6.2.rbi | 8 +- .../{builder@3.2.4.rbi => builder@3.3.0.rbi} | 48 +- ...2.1.0.rbi => capistrano-bundler@2.1.1.rbi} | 1 + sorbet/rbi/gems/capistrano-ext@1.2.1.rbi | 1 + .../gems/capistrano-faster-assets@1.1.0.rbi | 1 + .../rbi/gems/capistrano-maintenance@1.2.1.rbi | 1 + ...s@1.6.2.rbi => capistrano-rails@1.6.3.rbi} | 1 + sorbet/rbi/gems/capistrano-rvm@0.1.2.rbi | 1 + ...20388544468d7fedbd89d06df9ea8225c8e6a0.rbi | 1 + sorbet/rbi/gems/capistrano3-puma@5.2.0.rbi | 1 + ...trano@3.17.3.rbi => capistrano@3.19.1.rbi} | 1 + ...apybara@3.39.2.rbi => capybara@3.40.0.rbi} | 1414 +- ...erwave@2.2.4.rbi => carrierwave@3.0.7.rbi} | 1205 +- sorbet/rbi/gems/childprocess@5.1.0.rbi | 383 + sorbet/rbi/gems/chronic@0.10.2.rbi | 1 + sorbet/rbi/gems/chunky_png@1.3.15.rbi | 1 + sorbet/rbi/gems/clipboard-rails@1.7.1.rbi | 17 - sorbet/rbi/gems/coderay@1.1.3.rbi | 1 + sorbet/rbi/gems/coffee-rails@5.0.0.rbi | 8 +- .../rbi/gems/coffee-script-source@1.12.2.rbi | 15 +- sorbet/rbi/gems/coffee-script@2.4.1.rbi | 1 + ...by@1.2.2.rbi => concurrent-ruby@1.3.4.rbi} | 844 +- sorbet/rbi/gems/connection_pool@2.4.1.rbi | 4 +- sorbet/rbi/gems/coveralls@0.8.23.rbi | 1 + .../gems/{crack@0.4.5.rbi => crack@1.0.0.rbi} | 1 + sorbet/rbi/gems/crass@1.0.6.rbi | 1 + sorbet/rbi/gems/csv@3.3.0.rbi | 4696 ++ ...rbi => cucumber-ci-environment@10.0.1.rbi} | 62 +- ...re@11.0.0.rbi => cucumber-core@13.0.3.rbi} | 800 +- ... cucumber-cucumber-expressions@17.1.0.rbi} | 481 +- ...23.0.1.rbi => cucumber-gherkin@27.0.0.rbi} | 161 +- ...rbi => cucumber-html-formatter@21.7.0.rbi} | 1 + ...8.0.0.rbi => cucumber-messages@22.0.0.rbi} | 926 +- ...ils@2.6.1.rbi => cucumber-rails@3.0.0.rbi} | 1 + ...rbi => cucumber-tag-expressions@6.1.0.rbi} | 165 +- ...{cucumber@8.0.0.rbi => cucumber@9.2.0.rbi} | 1076 +- sorbet/rbi/gems/dante@0.2.0.rbi | 1 + ... database_cleaner-active_record@2.2.0.rbi} | 127 +- .../rbi/gems/database_cleaner-core@2.0.1.rbi | 1 + sorbet/rbi/gems/database_cleaner@2.0.2.rbi | 1 + .../gems/{date@3.3.3.rbi => date@3.3.4.rbi} | 7 +- ...or@1.1.0.rbi => debug_inspector@1.2.0.rbi} | 12 +- sorbet/rbi/gems/delorean@2.1.0.rbi | 1 + .../{devise@4.9.2.rbi => devise@4.9.4.rbi} | 343 +- ...{diff-lcs@1.5.0.rbi => diff-lcs@1.5.1.rbi} | 142 +- .../{docile@1.4.0.rbi => docile@1.4.1.rbi} | 1 + ...90701.rbi => domain_name@0.6.20240107.rbi} | 66 +- sorbet/rbi/gems/down@5.4.2.rbi | 479 + sorbet/rbi/gems/draper@4.0.2.rbi | 28 +- sorbet/rbi/gems/drb@2.2.1.rbi | 1347 + sorbet/rbi/gems/e2mmap@0.1.0.rbi | 1 + sorbet/rbi/gems/ed25519@1.3.0.rbi | 1 + .../{erubi@1.12.0.rbi => erubi@1.13.0.rbi} | 35 +- .../{et-orbi@1.2.7.rbi => et-orbi@1.2.11.rbi} | 127 +- sorbet/rbi/gems/eventmachine@1.2.7.rbi | 1 + .../{execjs@2.8.1.rbi => execjs@2.9.1.rbi} | 191 +- ...ry_bot@6.2.1.rbi => factory_bot@6.4.6.rbi} | 143 +- ...@6.2.0.rbi => factory_bot_rails@6.4.3.rbi} | 26 +- sorbet/rbi/gems/faraday-em_http@1.0.0.rbi | 37 +- .../rbi/gems/faraday-em_synchrony@1.0.0.rbi | 37 +- sorbet/rbi/gems/faraday-excon@1.1.0.rbi | 37 +- sorbet/rbi/gems/faraday-httpclient@1.0.1.rbi | 37 +- sorbet/rbi/gems/faraday-multipart@1.0.4.rbi | 16 +- ...p@1.0.1.rbi => faraday-net_http@1.0.2.rbi} | 59 +- .../faraday-net_http_persistent@1.2.0.rbi | 37 +- sorbet/rbi/gems/faraday-patron@1.0.0.rbi | 37 +- sorbet/rbi/gems/faraday-rack@1.0.0.rbi | 37 +- sorbet/rbi/gems/faraday-retry@1.0.3.rbi | 31 +- sorbet/rbi/gems/faraday@1.10.3.rbi | 16 +- sorbet/rbi/gems/ffi-compiler@1.0.1.rbi | 320 - sorbet/rbi/gems/ffi-compiler@1.3.2.rbi | 183 + .../gems/{ffi@1.15.5.rbi => ffi@1.17.0.rbi} | 488 +- .../rbi/gems/font-awesome-rails@4.7.0.8.rbi | 8 +- .../{fugit@1.8.1.rbi => fugit@1.11.0.rbi} | 369 +- ...{geocoder@1.8.1.rbi => geocoder@1.8.3.rbi} | 23 +- ...{globalid@1.1.0.rbi => globalid@1.2.1.rbi} | 381 +- ...d34b87721639cb79235a6828585d604a49ced0.rbi | 1 + .../gems/{haml@6.1.1.rbi => haml@6.3.0.rbi} | 106 +- ...{hashdiff@1.0.1.rbi => hashdiff@1.1.1.rbi} | 9 +- sorbet/rbi/gems/hashie@5.0.0.rbi | 1 + sorbet/rbi/gems/hiredis@0.6.3.rbi | 1 + ...geoip2@0.1.2.rbi => hive_geoip2@0.1.3.rbi} | 1 + sorbet/rbi/gems/hotwire-rails@0.1.3.rbi | 8 +- ...cookie@1.0.5.rbi => http-cookie@1.0.7.rbi} | 188 +- sorbet/rbi/gems/http-form_data@2.3.0.rbi | 6 +- .../gems/{http@5.1.1.rbi => http@5.2.0.rbi} | 215 +- .../gems/{i18n@1.14.1.rbi => i18n@1.14.5.rbi} | 148 +- ...1.12.2.rbi => image_processing@1.13.0.rbi} | 39 +- ...ls@1.2.1.rbi => importmap-rails@2.0.1.rbi} | 28 +- ...console@0.6.0.rbi => io-console@0.7.2.rbi} | 1 + sorbet/rbi/gems/irb@1.7.0.rbi | 2701 -- ...nkler@1.5.6.rbi => jaro_winkler@1.6.0.rbi} | 3 + ...builder@2.11.5.rbi => jbuilder@2.12.0.rbi} | 113 +- sorbet/rbi/gems/jmespath@1.6.2.rbi | 1921 + ...rails@4.5.1.rbi => jquery-rails@4.6.0.rbi} | 8 +- .../gems/{json@2.6.3.rbi => json@2.7.2.rbi} | 180 +- sorbet/rbi/gems/json_expressions@0.9.0.rbi | 4 +- sorbet/rbi/gems/kramdown-parser-gfm@1.1.0.rbi | 7 +- sorbet/rbi/gems/kramdown@2.4.0.rbi | 1 + .../language_server-protocol@3.17.0.3.rbi | 14234 +++++- sorbet/rbi/gems/launchy@2.5.2.rbi | 833 - sorbet/rbi/gems/launchy@3.0.1.rbi | 663 + sorbet/rbi/gems/libv8-node@18.16.0.0.rbi | 107 - sorbet/rbi/gems/libv8-node@18.19.0.0.rbi | 9 + ...ttp-ffi@0.4.0.rbi => llhttp-ffi@0.5.0.rbi} | 1 + sorbet/rbi/gems/logger@1.6.0.rbi | 903 + ...{lograge@0.12.0.rbi => lograge@0.14.0.rbi} | 187 +- sorbet/rbi/gems/logs_tf@0.0.5.rbi | 1 + .../{loofah@2.21.3.rbi => loofah@2.22.0.rbi} | 141 +- sorbet/rbi/gems/mail@2.8.1.rbi | 36 +- .../{marcel@1.0.2.rbi => marcel@1.0.4.rbi} | 97 +- sorbet/rbi/gems/matrix@0.4.2.rbi | 1 + ...mind-db@1.1.1.rbi => maxmind-db@1.2.0.rbi} | 80 +- ...ip2@1.1.0.rbi => maxmind-geoip2@1.2.0.rbi} | 193 +- sorbet/rbi/gems/maxminddb@0.1.22.rbi | 1 + ...chanize@2.9.1.rbi => mechanize@2.12.0.rbi} | 461 +- ...urce@1.0.0.rbi => method_source@1.1.0.rbi} | 50 +- ....1.rbi => mime-types-data@3.2024.0806.rbi} | 62 +- ...e-types@3.4.1.rbi => mime-types@3.5.2.rbi} | 141 +- ...gick@4.12.0.rbi => mini_magick@4.13.2.rbi} | 89 +- ...ini_mime@1.1.2.rbi => mini_mime@1.1.5.rbi} | 39 +- ..._racer@0.8.0.rbi => mini_racer@0.14.1.rbi} | 89 +- ...initest@5.18.1.rbi => minitest@5.25.0.rbi} | 585 +- sorbet/rbi/gems/msgpack@1.7.2.rbi | 320 + sorbet/rbi/gems/multi_json@1.15.0.rbi | 1 + sorbet/rbi/gems/multi_test@1.1.0.rbi | 1 + ...ulti_xml@0.6.0.rbi => multi_xml@0.7.1.rbi} | 42 +- ...ost@2.3.0.rbi => multipart-post@2.4.1.rbi} | 23 +- .../{net-ftp@0.2.0.rbi => net-ftp@0.3.7.rbi} | 306 +- .../rbi/gems/net-http-digest_auth@1.4.1.rbi | 1 + sorbet/rbi/gems/net-http-persistent@4.0.2.rbi | 1 + sorbet/rbi/gems/net-imap@0.3.6.rbi | 3781 -- sorbet/rbi/gems/net-imap@0.4.14.rbi | 10845 +++++ sorbet/rbi/gems/net-pop@0.1.2.rbi | 1 + ...tocol@0.2.1.rbi => net-protocol@0.2.2.rbi} | 1 + sorbet/rbi/gems/net-scp@4.0.0.rbi | 1 + sorbet/rbi/gems/net-sftp@4.0.0.rbi | 117 +- ...{net-smtp@0.3.3.rbi => net-smtp@0.5.0.rbi} | 503 +- .../{net-ssh@7.1.0.rbi => net-ssh@7.2.3.rbi} | 355 +- sorbet/rbi/gems/netrc@0.11.0.rbi | 1 + .../gems/{nio4r@2.5.9.rbi => nio4r@2.7.3.rbi} | 11 +- .../gems/{time@0.2.2.rbi => nkf@0.2.0.rbi} | 5 +- ...okogiri@1.15.2.rbi => nokogiri@1.16.7.rbi} | 312 +- sorbet/rbi/gems/oily_png@1.2.1.rbi | 1 + sorbet/rbi/gems/omniauth-openid@2.0.1.rbi | 11 +- ... omniauth-rails_csrf_protection@1.0.2.rbi} | 132 +- sorbet/rbi/gems/omniauth-steam@1.0.6.rbi | 11 +- ...{omniauth@2.1.1.rbi => omniauth@2.1.2.rbi} | 129 +- sorbet/rbi/gems/orm_adapter@0.5.0.rbi | 1 + ...arallel@1.23.0.rbi => parallel@1.26.2.rbi} | 58 +- ...sts@4.2.1.rbi => parallel_tests@4.7.1.rbi} | 57 +- ...{parser@3.2.2.3.rbi => parser@3.3.4.2.rbi} | 2241 +- ...st@1.7.4.rbi => paypal-sdk-rest@1.7.5.rbi} | 1 + .../rbi/gems/{pg@1.5.3.rbi => pg@1.5.7.rbi} | 176 +- sorbet/rbi/gems/popper_js@1.16.1.rbi | 8 +- sorbet/rbi/gems/prettier_print@1.2.1.rbi | 8 - sorbet/rbi/gems/prism@0.30.0.rbi | 39212 ++++++++++++++++ sorbet/rbi/gems/pry-nav@1.0.0.rbi | 1 + sorbet/rbi/gems/pry@0.14.2.rbi | 11 - sorbet/rbi/gems/psych@5.1.2.rbi | 1715 + ...ffix@5.0.1.rbi => public_suffix@6.0.1.rbi} | 5 +- .../gems/{puma@5.6.6.rbi => puma@5.6.8.rbi} | 96 +- sorbet/rbi/gems/raabro@1.4.0.rbi | 1 + .../gems/{racc@1.7.1.rbi => racc@1.8.1.rbi} | 73 +- ...cache@1.13.0.rbi => rack-cache@1.17.0.rbi} | 424 +- sorbet/rbi/gems/rack-openid@1.4.2.rbi | 188 +- ...on@3.0.6.rbi => rack-protection@3.2.0.rbi} | 204 +- sorbet/rbi/gems/rack-session@1.0.2.rbi | 9 + sorbet/rbi/gems/rack-test@2.1.0.rbi | 185 +- .../gems/{rack@2.2.7.rbi => rack@2.2.9.rbi} | 300 +- sorbet/rbi/gems/rackup@1.0.0.rbi | 9 + .../gems/rails-controller-testing@1.0.5.rbi | 49 +- sorbet/rbi/gems/rails-dom-testing@2.0.3.rbi | 458 - sorbet/rbi/gems/rails-dom-testing@2.2.0.rbi | 758 + .../rbi/gems/rails-html-sanitizer@1.6.0.rbi | 103 +- .../gems/{rails@7.0.5.rbi => rails@7.2.0.rbi} | 1 + ...{railties@7.0.5.rbi => railties@7.2.0.rbi} | 2711 +- sorbet/rbi/gems/rainbow@3.1.1.rbi | 11 - .../gems/{rake@13.0.6.rbi => rake@13.2.1.rbi} | 181 +- sorbet/rbi/gems/rb-fsevent@0.11.2.rbi | 1 + ...otify@0.10.1.rbi => rb-inotify@0.11.1.rbi} | 1 + .../gems/{rbi@0.0.16.rbi => rbi@0.1.14.rbi} | 2197 +- sorbet/rbi/gems/rbs@2.8.4.rbi | 1 + sorbet/rbi/gems/rbzip2@0.3.0.rbi | 1 + sorbet/rbi/gems/rdoc@6.7.0.rbi | 12721 +++++ ...k@5.3.0.rbi => redis-actionpack@5.4.0.rbi} | 107 +- sorbet/rbi/gems/redis-activesupport@5.3.0.rbi | 87 +- sorbet/rbi/gems/redis-client@0.22.2.rbi | 1359 + sorbet/rbi/gems/redis-rack-cache@2.2.1.rbi | 360 +- sorbet/rbi/gems/redis-rack@2.1.4.rbi | 403 - sorbet/rbi/gems/redis-rack@3.0.0.rbi | 188 + sorbet/rbi/gems/redis-rails@5.0.2.rbi | 86 +- ...store@1.9.2.rbi => redis-store@1.11.0.rbi} | 154 +- .../gems/{redis@4.8.1.rbi => redis@5.2.0.rbi} | 2531 +- ...rser@2.8.1.rbi => regexp_parser@2.9.2.rbi} | 357 +- sorbet/rbi/gems/reline@0.3.5.rbi | 2058 - sorbet/rbi/gems/reline@0.5.9.rbi | 2425 + ...2bba89168d8259ced331f0c5a6d75f529c06b7.rbi | 1 + ...tore@1.5.1.rbi => request_store@1.7.0.rbi} | 1 + ...ponders@3.1.0.rbi => responders@3.1.1.rbi} | 511 +- sorbet/rbi/gems/reverse_markdown@2.1.1.rbi | 1 + .../gems/{rexml@3.2.5.rbi => rexml@3.3.5.rbi} | 627 +- .../gems/{rouge@4.1.2.rbi => rouge@4.3.0.rbi} | 107 +- ....rbi => rspec-activemodel-mocks@1.2.0.rbi} | 85 +- ...bi => rspec-collection_matchers@1.2.1.rbi} | 360 +- ...-core@3.12.2.rbi => rspec-core@3.13.0.rbi} | 665 +- ...12.3.rbi => rspec-expectations@3.13.1.rbi} | 324 +- ...ocks@3.12.5.rbi => rspec-mocks@3.13.1.rbi} | 412 +- ...-rails@6.0.3.rbi => rspec-rails@6.1.3.rbi} | 55 +- ...rt@3.12.0.rbi => rspec-support@3.13.1.rbi} | 641 +- ...-ast@1.29.0.rbi => rubocop-ast@1.32.0.rbi} | 866 +- ...{rubocop@1.52.1.rbi => rubocop@1.65.1.rbi} | 8890 ++-- sorbet/rbi/gems/ruby-lsp@0.5.1.rbi | 14 - sorbet/rbi/gems/ruby-openid@2.9.2.rbi | 7 +- sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi | 1 + ...uby-vips@2.1.4.rbi => ruby-vips@2.2.2.rbi} | 371 +- sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi | 1 + ...{rubyntlm@0.6.3.rbi => rubyntlm@0.6.5.rbi} | 160 +- sorbet/rbi/gems/rubyzip@2.3.2.rbi | 3 + sorbet/rbi/gems/sass-listen@4.0.0.rbi | 1 + sorbet/rbi/gems/sass-rails@6.0.0.rbi | 1 + sorbet/rbi/gems/sass@3.7.4.rbi | 1 + sorbet/rbi/gems/sassc-rails@2.1.2.rbi | 24 +- sorbet/rbi/gems/sassc@2.4.0.rbi | 1 + sorbet/rbi/gems/sd_notify@0.1.1.rbi | 111 + sorbet/rbi/gems/securerandom@0.3.1.rbi | 73 + sorbet/rbi/gems/sentry-rails@5.19.0.rbi | 988 + sorbet/rbi/gems/sentry-raven@3.1.2.rbi | 3214 -- sorbet/rbi/gems/sentry-ruby@5.19.0.rbi | 6103 +++ sorbet/rbi/gems/sentry-sidekiq@5.19.0.rbi | 706 + ...s@5.3.0.rbi => shoulda-matchers@6.3.1.rbi} | 2962 +- ...ron@1.10.1.rbi => sidekiq-cron@1.12.0.rbi} | 280 +- sorbet/rbi/gems/sidekiq@6.5.9.rbi | 1267 - sorbet/rbi/gems/sidekiq@7.3.0.rbi | 1880 + ...e_form@5.2.0.rbi => simple_form@5.3.1.rbi} | 442 +- sorbet/rbi/gems/simplecov-html@0.10.2.rbi | 1 + sorbet/rbi/gems/simplecov@0.16.1.rbi | 1 + ...graph@0.49.0.rbi => solargraph@0.50.0.rbi} | 104 +- sorbet/rbi/gems/spoom@1.1.15.rbi | 2383 - sorbet/rbi/gems/spoom@1.4.2.rbi | 4932 ++ sorbet/rbi/gems/sprockets-rails@3.4.2.rbi | 1277 - sorbet/rbi/gems/sprockets-rails@3.5.2.rbi | 1157 + ...prockets@4.2.0.rbi => sprockets@4.2.1.rbi} | 47 +- .../{sshkit@1.21.4.rbi => sshkit@1.23.0.rbi} | 1 + sorbet/rbi/gems/ssrf_filter@1.1.1.rbi | 167 - sorbet/rbi/gems/ssrf_filter@1.1.2.rbi | 116 + ...1a1acc2e76631e91cb25a263b3d00373371695.rbi | 3 +- ...ils@1.2.1.rbi => stimulus-rails@1.3.3.rbi} | 8 +- sorbet/rbi/gems/stringio@3.1.1.rbi | 9 + sorbet/rbi/gems/stripe@12.5.0.rbi | 9025 ++++ sorbet/rbi/gems/stripe@8.5.0.rbi | 5611 --- sorbet/rbi/gems/strscan@3.1.0.rbi | 9 + sorbet/rbi/gems/sync@0.5.0.rbi | 1 + sorbet/rbi/gems/syntax_tree@6.1.1.rbi | 8 - ...ys-uname@1.2.3.rbi => sys-uname@1.3.0.rbi} | 89 +- ...{tapioca@0.10.5.rbi => tapioca@0.16.0.rbi} | 1642 +- .../{temple@0.10.2.rbi => temple@0.10.3.rbi} | 19 +- ...or@1.7.1.rbi => term-ansicolor@1.11.2.rbi} | 1 + .../{terser@1.1.16.rbi => terser@1.2.3.rbi} | 81 +- sorbet/rbi/gems/text@1.3.1.rbi | 1 + sorbet/rbi/gems/tf2_line_parser@0.2.3.rbi | 1 + .../gems/{thor@1.2.2.rbi => thor@1.3.1.rbi} | 1209 +- .../gems/{tilt@2.2.0.rbi => tilt@2.4.0.rbi} | 145 +- sorbet/rbi/gems/time@0.3.0.rbi | 438 + .../{timeout@0.3.2.rbi => timeout@0.4.1.rbi} | 57 +- .../gems/{tins@1.32.1.rbi => tins@1.33.0.rbi} | 1 + sorbet/rbi/gems/turbo-rails@1.4.0.rbi | 131 - sorbet/rbi/gems/turbo-rails@2.0.6.rbi | 1300 + sorbet/rbi/gems/tzinfo@2.0.6.rbi | 1 + sorbet/rbi/gems/unf@0.1.4.rbi | 38 - sorbet/rbi/gems/unf_ext@0.0.8.2.rbi | 8 - ....2.rbi => unicode-display_width@2.5.0.rbi} | 1 + sorbet/rbi/gems/unparser@0.6.5.rbi | 4538 -- sorbet/rbi/gems/useragent@0.16.10.rbi | 9 + .../rbi/gems/{vcr@6.1.0.rbi => vcr@6.2.0.rbi} | 115 +- sorbet/rbi/gems/warden@1.2.9.rbi | 7 +- ...{webmock@3.18.1.rbi => webmock@3.23.1.rbi} | 1011 +- sorbet/rbi/gems/webrick@1.8.1.rbi | 1 + sorbet/rbi/gems/webrobots@0.1.2.rbi | 5 - ...r@0.7.5.rbi => websocket-driver@0.7.6.rbi} | 182 +- .../rbi/gems/websocket-extensions@0.1.5.rbi | 1 + .../gems/will_paginate-bootstrap4@0.2.2.rbi | 14 +- sorbet/rbi/gems/will_paginate@3.3.1.rbi | 348 + sorbet/rbi/gems/xml-simple@1.1.9.rbi | 1 + sorbet/rbi/gems/xpath@3.2.0.rbi | 5 +- ...sorbet@0.7.0.rbi => yard-sorbet@0.9.0.rbi} | 150 +- .../gems/{yard@0.9.34.rbi => yard@0.9.36.rbi} | 129 +- ...zeitwerk@2.6.8.rbi => zeitwerk@2.6.17.rbi} | 279 +- sorbet/rbi/gems/zonebie@0.6.1.rbi | 1 + sorbet/rbi/todo.rbi | 6 +- 591 files changed, 274684 insertions(+), 96331 deletions(-) create mode 100644 sorbet/rbi/annotations/.gitattributes create mode 100644 sorbet/rbi/annotations/activejob.rbi create mode 100644 sorbet/rbi/annotations/devise.rbi create mode 100644 sorbet/rbi/annotations/minitest.rbi create mode 100644 sorbet/rbi/dsl/.gitattributes rename sorbet/rbi/dsl/{active_record/validations.rbi => action_cable/connection/callbacks.rbi} (54%) create mode 100644 sorbet/rbi/dsl/action_cable/connection/identification.rbi create mode 100644 sorbet/rbi/dsl/action_dispatch/assertions.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/base_controller.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/inbound_email.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/incineration_job.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/ingresses/mailgun/inbound_emails_controller.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/ingresses/mandrill/inbound_emails_controller.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/ingresses/postmark/inbound_emails_controller.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/ingresses/relay/inbound_emails_controller.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/ingresses/sendgrid/inbound_emails_controller.rbi delete mode 100644 sorbet/rbi/dsl/action_mailbox/routing_job.rbi create mode 100644 sorbet/rbi/dsl/action_mailer/callbacks.rbi create mode 100644 sorbet/rbi/dsl/action_mailer/form_builder.rbi create mode 100644 sorbet/rbi/dsl/action_mailer/queued_delivery.rbi create mode 100644 sorbet/rbi/dsl/active_job/enqueuing.rbi create mode 100644 sorbet/rbi/dsl/active_model/conversion.rbi create mode 100644 sorbet/rbi/dsl/active_record/attribute_methods/serialization.rbi create mode 100644 sorbet/rbi/dsl/active_record/counter_cache.rbi delete mode 100644 sorbet/rbi/dsl/active_record/destroy_association_async_job.rbi delete mode 100644 sorbet/rbi/dsl/active_record/internal_metadata.rbi create mode 100644 sorbet/rbi/dsl/active_record/normalization.rbi delete mode 100644 sorbet/rbi/dsl/active_record/schema_migration.rbi create mode 100644 sorbet/rbi/dsl/active_record/secure_password.rbi delete mode 100644 sorbet/rbi/dsl/active_record/test_fixtures.rbi create mode 100644 sorbet/rbi/dsl/active_record/token_for.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/base_controller.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/blobs/proxy_controller.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/blobs/redirect_controller.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/direct_uploads_controller.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/disk_controller.rbi create mode 100644 sorbet/rbi/dsl/active_storage/preview_image_job.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/representations/base_controller.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/representations/proxy_controller.rbi delete mode 100644 sorbet/rbi/dsl/active_storage/representations/redirect_controller.rbi create mode 100644 sorbet/rbi/dsl/active_storage/transform_job.rbi delete mode 100644 sorbet/rbi/dsl/api/donators_controller.rbi delete mode 100644 sorbet/rbi/dsl/api/league_requests_controller.rbi delete mode 100644 sorbet/rbi/dsl/api/maps_controller.rbi delete mode 100644 sorbet/rbi/dsl/api/reservations_controller.rbi delete mode 100644 sorbet/rbi/dsl/api/servers_controller.rbi delete mode 100644 sorbet/rbi/dsl/api/users_controller.rbi create mode 100644 sorbet/rbi/dsl/available_maps_worker.rbi delete mode 100644 sorbet/rbi/dsl/devise/confirmations_controller.rbi delete mode 100644 sorbet/rbi/dsl/devise/omniauth_callbacks_controller.rbi delete mode 100644 sorbet/rbi/dsl/devise/passwords_controller.rbi delete mode 100644 sorbet/rbi/dsl/devise/registrations_controller.rbi delete mode 100644 sorbet/rbi/dsl/devise/sessions_controller.rbi delete mode 100644 sorbet/rbi/dsl/devise/unlocks_controller.rbi delete mode 100644 sorbet/rbi/dsl/donators_controller.rbi delete mode 100644 sorbet/rbi/dsl/file_uploads_controller.rbi delete mode 100644 sorbet/rbi/dsl/hiperz_server.rbi delete mode 100644 sorbet/rbi/dsl/hiperz_server_information.rbi delete mode 100644 sorbet/rbi/dsl/league_requests_controller.rbi delete mode 100644 sorbet/rbi/dsl/map_uploads_controller.rbi delete mode 100644 sorbet/rbi/dsl/orders_controller.rbi delete mode 100644 sorbet/rbi/dsl/pages_controller.rbi delete mode 100644 sorbet/rbi/dsl/player_statistics_controller.rbi delete mode 100644 sorbet/rbi/dsl/private_servers_controller.rbi delete mode 100644 sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails/sources_controller.rbi delete mode 100644 sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails_controller.rbi delete mode 100644 sorbet/rbi/dsl/rails/conductor/action_mailbox/incinerates_controller.rbi delete mode 100644 sorbet/rbi/dsl/rails/conductor/action_mailbox/reroutes_controller.rbi delete mode 100644 sorbet/rbi/dsl/rails/conductor/base_controller.rbi create mode 100644 sorbet/rbi/dsl/sentry/send_event_job.rbi delete mode 100644 sorbet/rbi/dsl/server_statistics_controller.rbi create mode 100644 sorbet/rbi/dsl/server_update_worker.rbi rename sorbet/rbi/dsl/{server_updates_worker.rbi => server_version_worker.rbi} (75%) delete mode 100644 sorbet/rbi/dsl/servers_controller.rbi delete mode 100644 sorbet/rbi/dsl/sessions_controller.rbi delete mode 100644 sorbet/rbi/dsl/simrai_server.rbi create mode 100644 sorbet/rbi/dsl/stac_log.rbi create mode 100644 sorbet/rbi/dsl/stac_logs_downloader_worker.rbi create mode 100644 sorbet/rbi/dsl/time.rbi delete mode 100644 sorbet/rbi/dsl/turbo/native/navigation_controller.rbi create mode 100644 sorbet/rbi/dsl/turbo/streams/broadcast_stream_job.rbi delete mode 100644 sorbet/rbi/dsl/users_controller.rbi delete mode 100644 sorbet/rbi/dsl/vouchers_controller.rbi create mode 100644 sorbet/rbi/gems/.gitattributes rename sorbet/rbi/gems/{actioncable@7.0.5.rbi => actioncable@7.2.0.rbi} (54%) delete mode 100644 sorbet/rbi/gems/actionmailbox@7.0.5.rbi create mode 100644 sorbet/rbi/gems/actionmailbox@7.2.0.rbi rename sorbet/rbi/gems/{actionmailer@7.0.5.rbi => actionmailer@7.2.0.rbi} (71%) rename sorbet/rbi/gems/{actionpack@7.0.5.rbi => actionpack@7.2.0.rbi} (55%) delete mode 100644 sorbet/rbi/gems/actiontext@7.0.5.rbi create mode 100644 sorbet/rbi/gems/actiontext@7.2.0.rbi rename sorbet/rbi/gems/{actionview@7.0.5.rbi => actionview@7.2.0.rbi} (80%) rename sorbet/rbi/gems/{activejob@7.0.5.rbi => activejob@7.2.0.rbi} (73%) rename sorbet/rbi/gems/{activemodel@7.0.5.rbi => activemodel@7.2.0.rbi} (78%) rename sorbet/rbi/gems/{activerecord@7.0.5.rbi => activerecord@7.2.0.rbi} (75%) delete mode 100644 sorbet/rbi/gems/activestorage@7.0.5.rbi create mode 100644 sorbet/rbi/gems/activestorage@7.2.0.rbi rename sorbet/rbi/gems/{activesupport@7.0.5.rbi => activesupport@7.2.0.rbi} (76%) rename sorbet/rbi/gems/{addressable@2.8.4.rbi => addressable@2.8.7.rbi} (89%) rename sorbet/rbi/gems/{airbrussh@1.4.1.rbi => airbrussh@1.5.2.rbi} (99%) delete mode 100644 sorbet/rbi/gems/american_date@1.2.0.rbi create mode 100644 sorbet/rbi/gems/american_date@1.3.0.rbi rename sorbet/rbi/gems/{autoprefixer-rails@10.4.13.0.rbi => autoprefixer-rails@10.4.19.0.rbi} (99%) create mode 100644 sorbet/rbi/gems/aws-eventstream@1.3.0.rbi create mode 100644 sorbet/rbi/gems/aws-partitions@1.963.0.rbi create mode 100644 sorbet/rbi/gems/aws-sdk-core@3.201.4.rbi create mode 100644 sorbet/rbi/gems/aws-sdk-kms@1.88.0.rbi create mode 100644 sorbet/rbi/gems/aws-sdk-s3@1.157.0.rbi create mode 100644 sorbet/rbi/gems/aws-sigv4@1.9.1.rbi create mode 100644 sorbet/rbi/gems/base64@0.2.0.rbi rename sorbet/rbi/gems/{bcrypt@3.1.18.rbi => bcrypt@3.1.20.rbi} (97%) rename sorbet/rbi/gems/{bcrypt_pbkdf@1.1.0.rbi => bcrypt_pbkdf@1.1.1.rbi} (99%) rename sorbet/rbi/gems/{benchmark@0.2.1.rbi => benchmark@0.3.0.rbi} (92%) create mode 100644 sorbet/rbi/gems/bigdecimal@3.1.8.rbi rename sorbet/rbi/gems/{binding_of_caller@1.0.0.rbi => binding_of_caller@1.0.1.rbi} (99%) create mode 100644 sorbet/rbi/gems/bootsnap@1.18.4.rbi rename sorbet/rbi/gems/{builder@3.2.4.rbi => builder@3.3.0.rbi} (93%) rename sorbet/rbi/gems/{capistrano-bundler@2.1.0.rbi => capistrano-bundler@2.1.1.rbi} (99%) rename sorbet/rbi/gems/{capistrano-rails@1.6.2.rbi => capistrano-rails@1.6.3.rbi} (99%) rename sorbet/rbi/gems/{capistrano@3.17.3.rbi => capistrano@3.19.1.rbi} (99%) rename sorbet/rbi/gems/{capybara@3.39.2.rbi => capybara@3.40.0.rbi} (89%) rename sorbet/rbi/gems/{carrierwave@2.2.4.rbi => carrierwave@3.0.7.rbi} (85%) create mode 100644 sorbet/rbi/gems/childprocess@5.1.0.rbi delete mode 100644 sorbet/rbi/gems/clipboard-rails@1.7.1.rbi rename sorbet/rbi/gems/{concurrent-ruby@1.2.2.rbi => concurrent-ruby@1.3.4.rbi} (97%) rename sorbet/rbi/gems/{crack@0.4.5.rbi => crack@1.0.0.rbi} (99%) create mode 100644 sorbet/rbi/gems/csv@3.3.0.rbi rename sorbet/rbi/gems/{cucumber-ci-environment@9.2.0.rbi => cucumber-ci-environment@10.0.1.rbi} (56%) rename sorbet/rbi/gems/{cucumber-core@11.0.0.rbi => cucumber-core@13.0.3.rbi} (65%) rename sorbet/rbi/gems/{cucumber-cucumber-expressions@15.2.0.rbi => cucumber-cucumber-expressions@17.1.0.rbi} (78%) rename sorbet/rbi/gems/{cucumber-gherkin@23.0.1.rbi => cucumber-gherkin@27.0.0.rbi} (88%) rename sorbet/rbi/gems/{cucumber-html-formatter@19.2.0.rbi => cucumber-html-formatter@21.7.0.rbi} (99%) rename sorbet/rbi/gems/{cucumber-messages@18.0.0.rbi => cucumber-messages@22.0.0.rbi} (82%) rename sorbet/rbi/gems/{cucumber-rails@2.6.1.rbi => cucumber-rails@3.0.0.rbi} (99%) rename sorbet/rbi/gems/{cucumber-tag-expressions@4.1.0.rbi => cucumber-tag-expressions@6.1.0.rbi} (56%) rename sorbet/rbi/gems/{cucumber@8.0.0.rbi => cucumber@9.2.0.rbi} (90%) rename sorbet/rbi/gems/{database_cleaner-active_record@2.1.0.rbi => database_cleaner-active_record@2.2.0.rbi} (86%) rename sorbet/rbi/gems/{date@3.3.3.rbi => date@3.3.4.rbi} (82%) rename sorbet/rbi/gems/{debug_inspector@1.1.0.rbi => debug_inspector@1.2.0.rbi} (61%) rename sorbet/rbi/gems/{devise@4.9.2.rbi => devise@4.9.4.rbi} (93%) rename sorbet/rbi/gems/{diff-lcs@1.5.0.rbi => diff-lcs@1.5.1.rbi} (91%) rename sorbet/rbi/gems/{docile@1.4.0.rbi => docile@1.4.1.rbi} (99%) rename sorbet/rbi/gems/{domain_name@0.5.20190701.rbi => domain_name@0.6.20240107.rbi} (81%) create mode 100644 sorbet/rbi/gems/down@5.4.2.rbi create mode 100644 sorbet/rbi/gems/drb@2.2.1.rbi rename sorbet/rbi/gems/{erubi@1.12.0.rbi => erubi@1.13.0.rbi} (91%) rename sorbet/rbi/gems/{et-orbi@1.2.7.rbi => et-orbi@1.2.11.rbi} (77%) rename sorbet/rbi/gems/{execjs@2.8.1.rbi => execjs@2.9.1.rbi} (67%) rename sorbet/rbi/gems/{factory_bot@6.2.1.rbi => factory_bot@6.4.6.rbi} (93%) rename sorbet/rbi/gems/{factory_bot_rails@6.2.0.rbi => factory_bot_rails@6.4.3.rbi} (85%) rename sorbet/rbi/gems/{faraday-net_http@1.0.1.rbi => faraday-net_http@1.0.2.rbi} (76%) delete mode 100644 sorbet/rbi/gems/ffi-compiler@1.0.1.rbi create mode 100644 sorbet/rbi/gems/ffi-compiler@1.3.2.rbi rename sorbet/rbi/gems/{ffi@1.15.5.rbi => ffi@1.17.0.rbi} (83%) rename sorbet/rbi/gems/{fugit@1.8.1.rbi => fugit@1.11.0.rbi} (79%) rename sorbet/rbi/gems/{geocoder@1.8.1.rbi => geocoder@1.8.3.rbi} (98%) rename sorbet/rbi/gems/{globalid@1.1.0.rbi => globalid@1.2.1.rbi} (52%) rename sorbet/rbi/gems/{haml@6.1.1.rbi => haml@6.3.0.rbi} (94%) rename sorbet/rbi/gems/{hashdiff@1.0.1.rbi => hashdiff@1.1.1.rbi} (96%) rename sorbet/rbi/gems/{hive_geoip2@0.1.2.rbi => hive_geoip2@0.1.3.rbi} (99%) rename sorbet/rbi/gems/{http-cookie@1.0.5.rbi => http-cookie@1.0.7.rbi} (87%) rename sorbet/rbi/gems/{http@5.1.1.rbi => http@5.2.0.rbi} (94%) rename sorbet/rbi/gems/{i18n@1.14.1.rbi => i18n@1.14.5.rbi} (95%) rename sorbet/rbi/gems/{image_processing@1.12.2.rbi => image_processing@1.13.0.rbi} (97%) rename sorbet/rbi/gems/{importmap-rails@1.2.1.rbi => importmap-rails@2.0.1.rbi} (90%) rename sorbet/rbi/gems/{io-console@0.6.0.rbi => io-console@0.7.2.rbi} (99%) delete mode 100644 sorbet/rbi/gems/irb@1.7.0.rbi rename sorbet/rbi/gems/{jaro_winkler@1.5.6.rbi => jaro_winkler@1.6.0.rbi} (89%) rename sorbet/rbi/gems/{jbuilder@2.11.5.rbi => jbuilder@2.12.0.rbi} (83%) create mode 100644 sorbet/rbi/gems/jmespath@1.6.2.rbi rename sorbet/rbi/gems/{jquery-rails@4.5.1.rbi => jquery-rails@4.6.0.rbi} (85%) rename sorbet/rbi/gems/{json@2.6.3.rbi => json@2.7.2.rbi} (92%) delete mode 100644 sorbet/rbi/gems/launchy@2.5.2.rbi create mode 100644 sorbet/rbi/gems/launchy@3.0.1.rbi delete mode 100644 sorbet/rbi/gems/libv8-node@18.16.0.0.rbi create mode 100644 sorbet/rbi/gems/libv8-node@18.19.0.0.rbi rename sorbet/rbi/gems/{llhttp-ffi@0.4.0.rbi => llhttp-ffi@0.5.0.rbi} (99%) create mode 100644 sorbet/rbi/gems/logger@1.6.0.rbi rename sorbet/rbi/gems/{lograge@0.12.0.rbi => lograge@0.14.0.rbi} (72%) rename sorbet/rbi/gems/{loofah@2.21.3.rbi => loofah@2.22.0.rbi} (88%) rename sorbet/rbi/gems/{marcel@1.0.2.rbi => marcel@1.0.4.rbi} (66%) rename sorbet/rbi/gems/{maxmind-db@1.1.1.rbi => maxmind-db@1.2.0.rbi} (84%) rename sorbet/rbi/gems/{maxmind-geoip2@1.1.0.rbi => maxmind-geoip2@1.2.0.rbi} (91%) rename sorbet/rbi/gems/{mechanize@2.9.1.rbi => mechanize@2.12.0.rbi} (92%) rename sorbet/rbi/gems/{method_source@1.0.0.rbi => method_source@1.1.0.rbi} (86%) rename sorbet/rbi/gems/{mime-types-data@3.2023.0218.1.rbi => mime-types-data@3.2024.0806.rbi} (55%) rename sorbet/rbi/gems/{mime-types@3.4.1.rbi => mime-types@3.5.2.rbi} (92%) rename sorbet/rbi/gems/{mini_magick@4.12.0.rbi => mini_magick@4.13.2.rbi} (94%) rename sorbet/rbi/gems/{mini_mime@1.1.2.rbi => mini_mime@1.1.5.rbi} (82%) rename sorbet/rbi/gems/{mini_racer@0.8.0.rbi => mini_racer@0.14.1.rbi} (72%) rename sorbet/rbi/gems/{minitest@5.18.1.rbi => minitest@5.25.0.rbi} (70%) create mode 100644 sorbet/rbi/gems/msgpack@1.7.2.rbi rename sorbet/rbi/gems/{multi_xml@0.6.0.rbi => multi_xml@0.7.1.rbi} (72%) rename sorbet/rbi/gems/{multipart-post@2.3.0.rbi => multipart-post@2.4.1.rbi} (96%) rename sorbet/rbi/gems/{net-ftp@0.2.0.rbi => net-ftp@0.3.7.rbi} (78%) delete mode 100644 sorbet/rbi/gems/net-imap@0.3.6.rbi create mode 100644 sorbet/rbi/gems/net-imap@0.4.14.rbi rename sorbet/rbi/gems/{net-protocol@0.2.1.rbi => net-protocol@0.2.2.rbi} (99%) rename sorbet/rbi/gems/{net-smtp@0.3.3.rbi => net-smtp@0.5.0.rbi} (68%) rename sorbet/rbi/gems/{net-ssh@7.1.0.rbi => net-ssh@7.2.3.rbi} (96%) rename sorbet/rbi/gems/{nio4r@2.5.9.rbi => nio4r@2.7.3.rbi} (97%) rename sorbet/rbi/gems/{time@0.2.2.rbi => nkf@0.2.0.rbi} (50%) rename sorbet/rbi/gems/{nokogiri@1.15.2.rbi => nokogiri@1.16.7.rbi} (96%) rename sorbet/rbi/gems/{omniauth-rails_csrf_protection@1.0.1.rbi => omniauth-rails_csrf_protection@1.0.2.rbi} (56%) rename sorbet/rbi/gems/{omniauth@2.1.1.rbi => omniauth@2.1.2.rbi} (90%) rename sorbet/rbi/gems/{parallel@1.23.0.rbi => parallel@1.26.2.rbi} (81%) rename sorbet/rbi/gems/{parallel_tests@4.2.1.rbi => parallel_tests@4.7.1.rbi} (79%) rename sorbet/rbi/gems/{parser@3.2.2.3.rbi => parser@3.3.4.2.rbi} (75%) rename sorbet/rbi/gems/{paypal-sdk-rest@1.7.4.rbi => paypal-sdk-rest@1.7.5.rbi} (99%) rename sorbet/rbi/gems/{pg@1.5.3.rbi => pg@1.5.7.rbi} (95%) delete mode 100644 sorbet/rbi/gems/prettier_print@1.2.1.rbi create mode 100644 sorbet/rbi/gems/prism@0.30.0.rbi create mode 100644 sorbet/rbi/gems/psych@5.1.2.rbi rename sorbet/rbi/gems/{public_suffix@5.0.1.rbi => public_suffix@6.0.1.rbi} (99%) rename sorbet/rbi/gems/{puma@5.6.6.rbi => puma@5.6.8.rbi} (98%) rename sorbet/rbi/gems/{racc@1.7.1.rbi => racc@1.8.1.rbi} (71%) rename sorbet/rbi/gems/{rack-cache@1.13.0.rbi => rack-cache@1.17.0.rbi} (79%) rename sorbet/rbi/gems/{rack-protection@3.0.6.rbi => rack-protection@3.2.0.rbi} (84%) create mode 100644 sorbet/rbi/gems/rack-session@1.0.2.rbi rename sorbet/rbi/gems/{rack@2.2.7.rbi => rack@2.2.9.rbi} (96%) create mode 100644 sorbet/rbi/gems/rackup@1.0.0.rbi delete mode 100644 sorbet/rbi/gems/rails-dom-testing@2.0.3.rbi create mode 100644 sorbet/rbi/gems/rails-dom-testing@2.2.0.rbi rename sorbet/rbi/gems/{rails@7.0.5.rbi => rails@7.2.0.rbi} (99%) rename sorbet/rbi/gems/{railties@7.0.5.rbi => railties@7.2.0.rbi} (65%) rename sorbet/rbi/gems/{rake@13.0.6.rbi => rake@13.2.1.rbi} (95%) rename sorbet/rbi/gems/{rb-inotify@0.10.1.rbi => rb-inotify@0.11.1.rbi} (99%) rename sorbet/rbi/gems/{rbi@0.0.16.rbi => rbi@0.1.14.rbi} (57%) create mode 100644 sorbet/rbi/gems/rdoc@6.7.0.rbi rename sorbet/rbi/gems/{redis-actionpack@5.3.0.rbi => redis-actionpack@5.4.0.rbi} (60%) create mode 100644 sorbet/rbi/gems/redis-client@0.22.2.rbi delete mode 100644 sorbet/rbi/gems/redis-rack@2.1.4.rbi create mode 100644 sorbet/rbi/gems/redis-rack@3.0.0.rbi rename sorbet/rbi/gems/{redis-store@1.9.2.rbi => redis-store@1.11.0.rbi} (76%) rename sorbet/rbi/gems/{redis@4.8.1.rbi => redis@5.2.0.rbi} (69%) rename sorbet/rbi/gems/{regexp_parser@2.8.1.rbi => regexp_parser@2.9.2.rbi} (96%) delete mode 100644 sorbet/rbi/gems/reline@0.3.5.rbi create mode 100644 sorbet/rbi/gems/reline@0.5.9.rbi rename sorbet/rbi/gems/{request_store@1.5.1.rbi => request_store@1.7.0.rbi} (99%) rename sorbet/rbi/gems/{responders@3.1.0.rbi => responders@3.1.1.rbi} (68%) rename sorbet/rbi/gems/{rexml@3.2.5.rbi => rexml@3.3.5.rbi} (90%) rename sorbet/rbi/gems/{rouge@4.1.2.rbi => rouge@4.3.0.rbi} (98%) rename sorbet/rbi/gems/{rspec-activemodel-mocks@1.1.0.rbi => rspec-activemodel-mocks@1.2.0.rbi} (84%) rename sorbet/rbi/gems/{rspec-collection_matchers@1.2.0.rbi => rspec-collection_matchers@1.2.1.rbi} (66%) rename sorbet/rbi/gems/{rspec-core@3.12.2.rbi => rspec-core@3.13.0.rbi} (95%) rename sorbet/rbi/gems/{rspec-expectations@3.12.3.rbi => rspec-expectations@3.13.1.rbi} (97%) rename sorbet/rbi/gems/{rspec-mocks@3.12.5.rbi => rspec-mocks@3.13.1.rbi} (94%) rename sorbet/rbi/gems/{rspec-rails@6.0.3.rbi => rspec-rails@6.1.3.rbi} (74%) rename sorbet/rbi/gems/{rspec-support@3.12.0.rbi => rspec-support@3.13.1.rbi} (84%) rename sorbet/rbi/gems/{rubocop-ast@1.29.0.rbi => rubocop-ast@1.32.0.rbi} (92%) rename sorbet/rbi/gems/{rubocop@1.52.1.rbi => rubocop@1.65.1.rbi} (90%) delete mode 100644 sorbet/rbi/gems/ruby-lsp@0.5.1.rbi rename sorbet/rbi/gems/{ruby-vips@2.1.4.rbi => ruby-vips@2.2.2.rbi} (54%) rename sorbet/rbi/gems/{rubyntlm@0.6.3.rbi => rubyntlm@0.6.5.rbi} (85%) create mode 100644 sorbet/rbi/gems/sd_notify@0.1.1.rbi create mode 100644 sorbet/rbi/gems/securerandom@0.3.1.rbi create mode 100644 sorbet/rbi/gems/sentry-rails@5.19.0.rbi delete mode 100644 sorbet/rbi/gems/sentry-raven@3.1.2.rbi create mode 100644 sorbet/rbi/gems/sentry-ruby@5.19.0.rbi create mode 100644 sorbet/rbi/gems/sentry-sidekiq@5.19.0.rbi rename sorbet/rbi/gems/{shoulda-matchers@5.3.0.rbi => shoulda-matchers@6.3.1.rbi} (85%) rename sorbet/rbi/gems/{sidekiq-cron@1.10.1.rbi => sidekiq-cron@1.12.0.rbi} (60%) delete mode 100644 sorbet/rbi/gems/sidekiq@6.5.9.rbi create mode 100644 sorbet/rbi/gems/sidekiq@7.3.0.rbi rename sorbet/rbi/gems/{simple_form@5.2.0.rbi => simple_form@5.3.1.rbi} (90%) rename sorbet/rbi/gems/{solargraph@0.49.0.rbi => solargraph@0.50.0.rbi} (99%) delete mode 100644 sorbet/rbi/gems/spoom@1.1.15.rbi create mode 100644 sorbet/rbi/gems/spoom@1.4.2.rbi delete mode 100644 sorbet/rbi/gems/sprockets-rails@3.4.2.rbi create mode 100644 sorbet/rbi/gems/sprockets-rails@3.5.2.rbi rename sorbet/rbi/gems/{sprockets@4.2.0.rbi => sprockets@4.2.1.rbi} (99%) rename sorbet/rbi/gems/{sshkit@1.21.4.rbi => sshkit@1.23.0.rbi} (99%) delete mode 100644 sorbet/rbi/gems/ssrf_filter@1.1.1.rbi create mode 100644 sorbet/rbi/gems/ssrf_filter@1.1.2.rbi rename sorbet/rbi/gems/{stimulus-rails@1.2.1.rbi => stimulus-rails@1.3.3.rbi} (82%) create mode 100644 sorbet/rbi/gems/stringio@3.1.1.rbi create mode 100644 sorbet/rbi/gems/stripe@12.5.0.rbi delete mode 100644 sorbet/rbi/gems/stripe@8.5.0.rbi create mode 100644 sorbet/rbi/gems/strscan@3.1.0.rbi delete mode 100644 sorbet/rbi/gems/syntax_tree@6.1.1.rbi rename sorbet/rbi/gems/{sys-uname@1.2.3.rbi => sys-uname@1.3.0.rbi} (77%) rename sorbet/rbi/gems/{tapioca@0.10.5.rbi => tapioca@0.16.0.rbi} (73%) rename sorbet/rbi/gems/{temple@0.10.2.rbi => temple@0.10.3.rbi} (98%) rename sorbet/rbi/gems/{term-ansicolor@1.7.1.rbi => term-ansicolor@1.11.2.rbi} (99%) rename sorbet/rbi/gems/{terser@1.1.16.rbi => terser@1.2.3.rbi} (78%) rename sorbet/rbi/gems/{thor@1.2.2.rbi => thor@1.3.1.rbi} (79%) rename sorbet/rbi/gems/{tilt@2.2.0.rbi => tilt@2.4.0.rbi} (90%) create mode 100644 sorbet/rbi/gems/time@0.3.0.rbi rename sorbet/rbi/gems/{timeout@0.3.2.rbi => timeout@0.4.1.rbi} (81%) rename sorbet/rbi/gems/{tins@1.32.1.rbi => tins@1.33.0.rbi} (99%) delete mode 100644 sorbet/rbi/gems/turbo-rails@1.4.0.rbi create mode 100644 sorbet/rbi/gems/turbo-rails@2.0.6.rbi delete mode 100644 sorbet/rbi/gems/unf@0.1.4.rbi delete mode 100644 sorbet/rbi/gems/unf_ext@0.0.8.2.rbi rename sorbet/rbi/gems/{unicode-display_width@2.4.2.rbi => unicode-display_width@2.5.0.rbi} (99%) delete mode 100644 sorbet/rbi/gems/unparser@0.6.5.rbi create mode 100644 sorbet/rbi/gems/useragent@0.16.10.rbi rename sorbet/rbi/gems/{vcr@6.1.0.rbi => vcr@6.2.0.rbi} (97%) rename sorbet/rbi/gems/{webmock@3.18.1.rbi => webmock@3.23.1.rbi} (66%) rename sorbet/rbi/gems/{websocket-driver@0.7.5.rbi => websocket-driver@0.7.6.rbi} (86%) rename sorbet/rbi/gems/{yard-sorbet@0.7.0.rbi => yard-sorbet@0.9.0.rbi} (72%) rename sorbet/rbi/gems/{yard@0.9.34.rbi => yard@0.9.36.rbi} (99%) rename sorbet/rbi/gems/{zeitwerk@2.6.8.rbi => zeitwerk@2.6.17.rbi} (81%) diff --git a/app/models/user.rb b/app/models/user.rb index a747d4c0a..5a2d9762a 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -1,6 +1,8 @@ # frozen_string_literal: true +# typed: false class User < ActiveRecord::Base + extend T::Sig devise :omniauthable, :rememberable, :trackable has_many :reservations @@ -30,36 +32,44 @@ def self.find_for_steam_auth(auth, _signed_in_resource = nil) user end + sig { returns(String) } def steam_profile_url "http://steamcommunity.com/profiles/#{uid}" end + sig { returns(T::Boolean) } def donator? @donator ||= group_ids.include?(Group.donator_group.id) end + sig { returns(T::Boolean) } def admin? @admin ||= group_ids.include?(Group.admin_group.id) end + sig { returns(T::Boolean) } def league_admin? @league_admin ||= group_ids.include?(Group.league_admin_group.id) end + sig { returns(T::Boolean) } def streamer? @streamer ||= group_ids.include?(Group.streamer_group.id) end + sig { returns(T::Boolean) } def trusted_api? @trusted_api ||= group_ids.include?(Group.trusted_api_group.id) end + sig { returns(T.nilable(T::Boolean)) } def banned? return false if ReservationPlayer.whitelisted_uid?(uid) - ReservationPlayer.banned_uid?(uid) || ReservationPlayer.banned_ip?(current_sign_in_ip) + !!(ReservationPlayer.banned_uid?(uid) || ReservationPlayer.banned_ip?(current_sign_in_ip)) end + sig { returns(ActiveSupport::Duration) } def maximum_reservation_length if admin? || donator? 10.hours @@ -68,6 +78,7 @@ def maximum_reservation_length end end + sig { returns(ActiveSupport::Duration) } def reservation_extension_time if donator? 1.hour @@ -76,27 +87,33 @@ def reservation_extension_time end end + sig { returns(T.nilable(Integer)) } def total_reservation_seconds reservations.to_a.sum(&:duration) end + sig { returns(T::Boolean) } def top10? Statistic.top_10_users.key?(self) end + sig { returns(T.nilable(ActiveSupport::TimeWithZone)) } def donator_until group_users.find_by_group_id(Group.donator_group)&.expires_at end + sig { returns(T::Boolean) } def private_server_option? @private_server_option ||= groups.include?(Group.private_user(self)) end + sig { returns(T.nilable(Server)) } def private_server Group.private_user(self).servers.first end + sig { params(server_id: String).returns(T.nilable(T::Boolean)) } def private_server_id=(server_id) return unless server_id.to_i.positive? @@ -105,39 +122,46 @@ def private_server_id=(server_id) group_server.save! end + sig { returns(T.nilable(T::Boolean)) } def current_sign_in_ip_changed_and_ipv4? current_sign_in_ip_ipv4? && current_sign_in_ip_changed? end + sig { returns(T.nilable(T::Boolean)) } def current_sign_in_ip_ipv4? self[:current_sign_in_ip] && IPAddr.new(self[:current_sign_in_ip]).ipv4? end + sig { returns(T.nilable(Geocoder::Result::Base)) } def geocoded return unless current_sign_in_ip_ipv4? @geocoded ||= Geocoder.search(current_sign_in_ip).try(:first) end + sig { returns(T::Boolean) } def from_na? na_timezone? || na_sign_in_ip? end + sig { returns(T.nilable(T::Boolean)) } def banned_country? current_sign_in_ip_ipv4? && ReservationPlayer.banned_country?(current_sign_in_ip) end private + sig { returns(T::Boolean) } def na_timezone? return false unless time_zone ['US & Canada', 'Canada', 'Chicago', 'New_York', 'Los_Angeles', 'Denver', 'Phoenix', 'Halifax', 'Goose_Bay', 'St_Johns', 'Anchorage'].any? do |zone| - time_zone.match(/#{zone}/) + time_zone&.match(/#{zone}/) end end + sig { returns(T::Boolean) } def na_sign_in_ip? - geocoded && (geocoded.data['continent']['code'] == 'NA') + geocoded&.data&.[]('continent')&.[]('code') == 'NA' end end diff --git a/db/schema.rb b/db/schema.rb index 80bf15ebd..7e9a1b9e5 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -10,7 +10,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema[7.2].define(version: 2024_07_03_131707) do +ActiveRecord::Schema[7.2].define(version: 2024_08_13_083542) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" @@ -341,6 +341,7 @@ t.float "longitude" t.integer "expired_reservations", default: 0 t.string "demos_tf_api_key" + t.boolean "enforce_league_bans" t.index ["api_key"], name: "index_users_on_api_key", unique: true t.index ["latitude", "longitude"], name: "index_users_on_latitude_and_longitude" t.index ["reset_password_token"], name: "index_users_on_reset_password_token", unique: true diff --git a/sorbet/config b/sorbet/config index de457cda6..507592181 100644 --- a/sorbet/config +++ b/sorbet/config @@ -1,3 +1,5 @@ --dir . +--ignore=tmp/ --ignore=vendor/ +--suppress-payload-superclass-redefinition-for=Reline::ANSI diff --git a/sorbet/rbi/annotations/.gitattributes b/sorbet/rbi/annotations/.gitattributes new file mode 100644 index 000000000..d2eacd2c6 --- /dev/null +++ b/sorbet/rbi/annotations/.gitattributes @@ -0,0 +1 @@ +**/*.rbi linguist-vendored=true diff --git a/sorbet/rbi/annotations/actionmailer.rbi b/sorbet/rbi/annotations/actionmailer.rbi index e806f9909..3d2771dfa 100644 --- a/sorbet/rbi/annotations/actionmailer.rbi +++ b/sorbet/rbi/annotations/actionmailer.rbi @@ -1,10 +1,10 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. # Please run `bin/tapioca annotations` to update it. class ActionMailer::Base - sig { params(headers: T.untyped, block: T.nilable(T.proc.void)).returns(Mail::Message) } + sig { params(headers: T.untyped, block: T.nilable(T.proc.params(arg0: ActionMailer::Collector).void)).returns(Mail::Message) } def mail(headers = nil, &block); end end diff --git a/sorbet/rbi/annotations/actionpack.rbi b/sorbet/rbi/annotations/actionpack.rbi index c4f521258..9fdb5f288 100644 --- a/sorbet/rbi/annotations/actionpack.rbi +++ b/sorbet/rbi/annotations/actionpack.rbi @@ -1,4 +1,4 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. @@ -75,8 +75,8 @@ class ActionController::Parameters sig { returns(String) } def inspect; end - sig { params(other_hash: T.untyped).returns(ActionController::Parameters) } - def merge!(other_hash); end + sig { params(other_hash: T.untyped, block: T.untyped).returns(ActionController::Parameters) } + def merge!(other_hash, &block); end sig { params(other_hash: T.untyped).returns(ActionController::Parameters) } def merge(other_hash); end @@ -110,11 +110,12 @@ class ActionController::Parameters sig { params(key: T.any(String, Symbol)).returns(T.untyped) } def [](key); end - sig { params(key: T.any(String, Symbol, T::Array[T.any(String, Symbol)])).returns(T.untyped) } + sig { params(key: T.any(String, Symbol)).returns(ActionController::Parameters) } + sig { params(key: T::Array[T.any(String, Symbol)]).returns(T::Array[ActionController::Parameters]) } def require(key); end - # required is an alias of require - sig { params(key: T.any(String, Symbol, T::Array[T.any(String, Symbol)])).returns(T.untyped) } + sig { params(key: T.any(String, Symbol)).returns(ActionController::Parameters) } + sig { params(key: T::Array[T.any(String, Symbol)]).returns(T::Array[ActionController::Parameters]) } def required(key); end sig { params(other_hash: T.untyped).returns(ActionController::Parameters) } @@ -141,24 +142,6 @@ class ActionController::Parameters sig { params(block: T.untyped).returns(ActionController::Parameters) } def select(&block); end - sig { returns(T.any(Symbol, T::Boolean)) } - def self.action_on_unpermitted_parameters; end - - sig { params(obj: T.any(Symbol, T::Boolean)).void } - def self.action_on_unpermitted_parameters=(obj); end - - sig { returns(T::Array[T.any(String, Symbol)]) } - def self.always_permitted_parameters; end - - sig { params(obj: T::Array[T.any(String, Symbol)]).void } - def self.always_permitted_parameters=(obj); end - - sig { returns(T::Boolean) } - def self.permit_all_parameters; end - - sig { params(obj: T::Boolean).void } - def self.permit_all_parameters=(obj); end - sig { params(keys: T.any(String, Symbol)).returns(ActionController::Parameters) } def slice!(*keys); end @@ -199,6 +182,24 @@ class ActionController::Parameters sig { params(keys: T.any(String, Symbol)).returns(T.untyped) } def values_at(*keys); end + + sig { returns(T.any(Symbol, T::Boolean)) } + def self.action_on_unpermitted_parameters; end + + sig { params(obj: T.any(Symbol, T::Boolean)).void } + def self.action_on_unpermitted_parameters=(obj); end + + sig { returns(T::Array[T.any(String, Symbol)]) } + def self.always_permitted_parameters; end + + sig { params(obj: T::Array[T.any(String, Symbol)]).void } + def self.always_permitted_parameters=(obj); end + + sig { returns(T::Boolean) } + def self.permit_all_parameters; end + + sig { params(obj: T::Boolean).void } + def self.permit_all_parameters=(obj); end end module ActionController::RequestForgeryProtection diff --git a/sorbet/rbi/annotations/actionview.rbi b/sorbet/rbi/annotations/actionview.rbi index eb3b6b9ca..9c939f032 100644 --- a/sorbet/rbi/annotations/actionview.rbi +++ b/sorbet/rbi/annotations/actionview.rbi @@ -1,13 +1,11 @@ -# typed: strong +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. # Please run `bin/tapioca annotations` to update it. module ActionView - TemplateError = T.type_alias { - Template::Error -} + TemplateError = T.type_alias { Template::Error } class MissingTemplate < ActionView::ActionViewError sig { returns(String) } diff --git a/sorbet/rbi/annotations/activejob.rbi b/sorbet/rbi/annotations/activejob.rbi new file mode 100644 index 000000000..0f7441e3e --- /dev/null +++ b/sorbet/rbi/annotations/activejob.rbi @@ -0,0 +1,44 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This file was pulled from a central RBI files repository. +# Please run `bin/tapioca annotations` to update it. + +class ActiveJob::Base + sig { params(blk: T.proc.bind(T.attached_class).params(job: T.attached_class).void).void } + def self.after_discard(&blk); end + + sig { params(filters: T.untyped, blk: T.nilable(T.proc.bind(T.attached_class).params(job: T.attached_class).void)).void } + def self.after_enqueue(*filters, &blk); end + + sig { params(filters: T.untyped, blk: T.nilable(T.proc.bind(T.attached_class).params(job: T.attached_class).void)).void } + def self.after_perform(*filters, &blk); end + + sig { params(filters: T.untyped, blk: T.nilable(T.proc.bind(T.attached_class).params(job: T.attached_class, block: T.untyped).void)).void } + def self.around_enqueue(*filters, &blk); end + + sig { params(filters: T.untyped, blk: T.nilable(T.proc.bind(T.attached_class).params(job: T.attached_class, block: T.untyped).void)).void } + def self.around_perform(*filters, &blk); end + + sig { params(filters: T.untyped, blk: T.nilable(T.proc.bind(T.attached_class).params(job: T.attached_class).void)).void } + def self.before_enqueue(*filters, &blk); end + + sig { params(filters: T.untyped, blk: T.nilable(T.proc.bind(T.attached_class).params(job: T.attached_class).void)).void } + def self.before_perform(*filters, &blk); end + + sig { type_parameters(:ExceptionType).params(exceptions: T::Class[T.type_parameter(:ExceptionType)], block: T.nilable(T.proc.params(job: T.attached_class, error: T.type_parameter(:ExceptionType)).void)).void } + sig { params(exceptions: T.any(Module, String), block: T.nilable(T.proc.params(job: T.attached_class, error: T.untyped).void)).void } + def self.discard_on(*exceptions, &block); end + + sig { params(klasses: T.any(Module, String), with: T.nilable(Symbol), block: T.nilable(T.proc.params(exception: T.untyped).void)).void } + def self.rescue_from(*klasses, with: nil, &block); end + + sig { params(exceptions: T.any(Module, String), wait: T.any(ActiveSupport::Duration, Integer, Symbol, T.proc.params(executions: Integer).returns(Integer)), attempts: T.any(Integer, Symbol), queue: T.nilable(T.any(String, Symbol)), priority: T.untyped, jitter: Numeric, block: T.nilable(T.proc.params(job: T.attached_class, error: T.untyped).void)).void } + def self.retry_on(*exceptions, wait: 3.seconds, attempts: 5, queue: nil, priority: nil, jitter: JITTER_DEFAULT, &block); end + + sig { params(part_name: T.nilable(T.any(String, Symbol)), block: T.nilable(T.proc.bind(T.attached_class).returns(T.untyped))).void } + def self.queue_as(part_name = nil, &block); end + + sig { params(priority: T.untyped, block: T.nilable(T.proc.bind(T.attached_class).returns(T.untyped))).void } + def self.queue_with_priority(priority = nil, &block); end +end diff --git a/sorbet/rbi/annotations/activemodel.rbi b/sorbet/rbi/annotations/activemodel.rbi index d90bcfe90..1e1a64243 100644 --- a/sorbet/rbi/annotations/activemodel.rbi +++ b/sorbet/rbi/annotations/activemodel.rbi @@ -1,13 +1,11 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. # Please run `bin/tapioca annotations` to update it. class ActiveModel::Errors - Elem = type_member { - { fixed: ActiveModel::Error } -} + Elem = type_member { { fixed: ActiveModel::Error } } sig { params(attribute: T.any(Symbol, String)).returns(T::Array[String]) } def [](attribute); end diff --git a/sorbet/rbi/annotations/activerecord.rbi b/sorbet/rbi/annotations/activerecord.rbi index 82e9f9ccc..c023f0da7 100644 --- a/sorbet/rbi/annotations/activerecord.rbi +++ b/sorbet/rbi/annotations/activerecord.rbi @@ -1,4 +1,4 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. @@ -13,11 +13,21 @@ class ActiveRecord::Migration # @shim: Methods on migration are delegated to `SchemaStatements` using `method_missing` include ActiveRecord::ConnectionAdapters::SchemaStatements - # @shim: Methods on migration are delegated to `DatabaseaStatements` using `method_missing` + # @shim: Methods on migration are delegated to `DatabaseStatements` using `method_missing` include ActiveRecord::ConnectionAdapters::DatabaseStatements end class ActiveRecord::Base + sig { returns(FalseClass) } + def blank?; end + + # @shim: since `present?` is always true, `presence` always returns `self` + sig { returns(T.self_type) } + def presence; end + + sig { returns(TrueClass) } + def present?; end + sig { params(args: T.untyped, options: T.untyped, block: T.nilable(T.proc.bind(T.attached_class).params(record: T.attached_class).void)).void } def self.after_initialize(*args, **options, &block); end @@ -75,3 +85,8 @@ class ActiveRecord::Base sig { params(args: T.untyped, options: T.untyped, block: T.nilable(T.proc.bind(T.attached_class).params(record: T.attached_class).void)).void } def self.after_rollback(*args, **options, &block); end end + +class ActiveRecord::Relation + sig { returns(T::Boolean) } + def blank?; end +end diff --git a/sorbet/rbi/annotations/activesupport.rbi b/sorbet/rbi/annotations/activesupport.rbi index 56db82991..36594788d 100644 --- a/sorbet/rbi/annotations/activesupport.rbi +++ b/sorbet/rbi/annotations/activesupport.rbi @@ -1,4 +1,4 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. @@ -49,22 +49,54 @@ class ActiveSupport::TimeWithZone # @shim: Methods on ActiveSupport::TimeWithZone are delegated to `Time` using `method_missing include ::DateAndTime::Calculations + + sig { returns(FalseClass) } + def blank?; end + + # @shim: since `present?` is always true, `presence` always returns `self` + sig { returns(T.self_type) } + def presence; end + + # @shim: since `blank?` is always false, `present?` always returns `true` + sig { returns(TrueClass) } + def present?; end end class Object sig { returns(T::Boolean) } def blank?; end + sig { returns(FalseClass) } + def html_safe?; end + + sig { returns(T.nilable(T.self_type)) } + def presence; end + + sig { params(another_object: T.untyped).returns(T.nilable(T.self_type)) } + def presence_in(another_object); end + sig { returns(T::Boolean) } def present?; end end class Hash + sig { returns(T::Boolean) } + def blank?; end + + sig { returns(T::Boolean) } + def present?; end + sig { returns(T::Boolean) } def extractable_options?; end end class Array + sig { returns(T::Boolean) } + def blank?; end + + sig { returns(T::Boolean) } + def present?; end + sig { params(position: Integer).returns(T.self_type) } def from(position); end @@ -125,12 +157,292 @@ class Array sig { params(value: T.untyped, block: T.nilable(T.proc.params(element: Elem).returns(T.untyped))).returns(T::Array[T::Array[Elem]]) } def split(value = nil, &block); end - sig { params(object: T.untyped).returns(T::Array[T.untyped]) } - def self.wrap(object); end - sig { params(block: T.nilable(T.proc.params(element: Elem).returns(T.untyped))).returns(T.any(T::Array[Elem], T::Enumerator[Elem])) } def extract!(&block); end sig { returns(ActiveSupport::ArrayInquirer) } def inquiry; end + + sig { params(object: T.untyped).returns(T::Array[T.untyped]) } + def self.wrap(object); end +end + +class Date + sig { returns(FalseClass) } + def blank?; end + + # @shim: since `present?` is always true, `presence` always returns `self` + sig { returns(T.self_type) } + def presence; end + + # @shim: since `blank?` is always false, `present?` always returns `true` + sig { returns(TrueClass) } + def present?; end +end + +class DateTime + sig { returns(FalseClass) } + def blank?; end + + # @shim: since `present?` is always true, `presence` always returns `self` + sig { returns(T.self_type) } + def presence; end + + # @shim: since `blank?` is always false, `present?` always returns `true` + sig { returns(TrueClass) } + def present?; end +end + +class NilClass + sig { returns(TrueClass) } + def blank?; end + + # @shim: since `present?` is always false, `presence` always returns `nil` + sig { returns(NilClass) } + def presence; end + + # @shim: since `blank?` is always true, `present?` always returns `false` + sig { returns(FalseClass) } + def present?; end +end + +class FalseClass + sig { returns(TrueClass) } + def blank?; end + + # @shim: since `present?` is always false, `presence` always returns `nil` + sig { returns(NilClass) } + def presence; end + + # @shim: since `blank?` is always true, `present?` always returns `false` + sig { returns(FalseClass) } + def present?; end +end + +class TrueClass + sig { returns(FalseClass) } + def blank?; end + + # @shim: since `present?` is always true, `presence` always returns `self` + sig { returns(T.self_type) } + def presence; end + + # @shim: since `blank?` is always false, `present?` always returns `true` + sig { returns(TrueClass) } + def present?; end +end + +class Numeric + sig { returns(FalseClass) } + def blank?; end + + sig { returns(TrueClass) } + def html_safe?; end + + # @shim: since `present?` is always true, `presence` always returns `self` + sig { returns(T.self_type) } + def presence; end + + # @shim: since `blank?` is always false, `present?` always returns `true` + sig { returns(TrueClass) } + def present?; end +end + +class Time + sig { returns(FalseClass) } + def blank?; end + + # @shim: since `present?` is always true, `presence` always returns `self` + sig { returns(T.self_type) } + def presence; end + + # @shim: since `blank?` is always false, `present?` always returns `true` + sig { returns(TrueClass) } + def present?; end + + sig { returns(ActiveSupport::TimeZone) } + def self.zone; end + + sig { returns(T.any(ActiveSupport::TimeWithZone, ::Time)) } + def self.current; end +end + +class Symbol + sig { returns(T::Boolean) } + def blank?; end + + sig { returns(T::Boolean) } + def present?; end + + # alias for `#start_with?` + sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) } + def starts_with?(*string_or_regexp); end + + # alias for `#end_with?` + sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) } + def ends_with?(*string_or_regexp); end +end + +class String + sig { returns(TrueClass) } + def acts_like_string?; end + + sig { params(position: Integer).returns(T.nilable(String)) } + sig { params(position: T.any(T::Range[Integer], Regexp)).returns(T.nilable(String)) } + sig { params(position: String).returns(T.nilable(String)) } + def at(position); end + + sig { returns(String) } + def as_json; end + + sig { returns(T::Boolean) } + def blank?; end + + sig { params(first_letter: Symbol).returns(String) } + def camelcase(first_letter = :upper); end + + sig { params(first_letter: Symbol).returns(String) } + def camelize(first_letter = :upper); end + + sig { returns(String) } + def classify; end + + sig { returns(T.untyped) } + def constantize; end + + sig { returns(String) } + def dasherize; end + + sig { returns(String) } + def deconstantize; end + + sig { returns(String) } + def demodulize; end + + # alias for `#end_with?` + sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) } + def ends_with?(*string_or_regexp); end + + sig { returns(String) } + def downcase_first; end + + sig { params(string: String).returns(T::Boolean) } + def exclude?(string); end + + sig { params(limit: Integer).returns(String) } + def first(limit = 1); end + + sig { params(separate_class_name_and_id_with_underscore: T::Boolean).returns(String) } + def foreign_key(separate_class_name_and_id_with_underscore = true); end + + sig { params(position: Integer).returns(String) } + def from(position); end + + sig { returns(ActiveSupport::SafeBuffer) } + def html_safe; end + + sig { params(capitalize: T::Boolean, keep_id_suffix: T::Boolean).returns(String) } + def humanize(capitalize: true, keep_id_suffix: false); end + + sig { params(zone: T.nilable(T.any(ActiveSupport::TimeZone, String))).returns(T.any(ActiveSupport::TimeWithZone, Time)) } + def in_time_zone(zone = ::Time.zone); end + + sig { params(amount: Integer, indent_string: T.nilable(String), indent_empty_lines: T::Boolean).returns(String) } + def indent(amount, indent_string = nil, indent_empty_lines = false); end + + sig { params(amount: Integer, indent_string: T.nilable(String), indent_empty_lines: T::Boolean).returns(T.nilable(String)) } + def indent!(amount, indent_string = nil, indent_empty_lines = false); end + + sig { returns(ActiveSupport::StringInquirer) } + def inquiry; end + + sig { returns(T::Boolean) } + def is_utf8?; end + + sig { params(limit: Integer).returns(String) } + def last(limit = 1); end + + sig { returns(ActiveSupport::Multibyte::Chars) } + def mb_chars; end + + sig { params(separator: String, preserve_case: T::Boolean, locale: T.nilable(Symbol)).returns(String) } + def parameterize(separator: "-", preserve_case: false, locale: nil); end + + sig { params(count: T.nilable(T.any(Integer, Symbol)), locale: T.nilable(Symbol)).returns(String) } + def pluralize(count = nil, locale = :en); end + + sig { returns(T::Boolean) } + def present?; end + + sig { params(patterns: T.any(String, Regexp)).returns(String) } + def remove(*patterns); end + + sig { params(patterns: T.any(String, Regexp)).returns(String) } + def remove!(*patterns); end + + sig { returns(T.untyped) } + def safe_constantize; end + + sig { params(locale: Symbol).returns(String) } + def singularize(locale = :en); end + + sig { returns(String) } + def squish; end + + sig { returns(String) } + def squish!; end + + # alias for `#start_with?` + sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) } + def starts_with?(*string_or_regexp); end + + sig { returns(String) } + def strip_heredoc; end + + sig { returns(String) } + def tableize; end + + sig { params(keep_id_suffix: T::Boolean).returns(String) } + def titlecase(keep_id_suffix: false); end + + sig { params(keep_id_suffix: T::Boolean).returns(String) } + def titleize(keep_id_suffix: false); end + + sig { params(position: Integer).returns(String) } + def to(position); end + + sig { returns(::Date) } + def to_date; end + + sig { returns(::DateTime) } + def to_datetime; end + + sig { params(form: T.nilable(Symbol)).returns(T.nilable(Time)) } + def to_time(form = :local); end + + sig { params(truncate_to: Integer, options: T::Hash[Symbol, T.anything]).returns(String) } + def truncate(truncate_to, options = {}); end + + sig { params(truncate_to: Integer, omission: T.nilable(String)).returns(String) } + def truncate_bytes(truncate_to, omission: "…"); end + + sig { params(words_count: Integer, options: T::Hash[Symbol, T.anything]).returns(String) } + def truncate_words(words_count, options = {}); end + + sig { returns(String) } + def underscore; end + + sig { returns(String) } + def upcase_first; end +end + +class ActiveSupport::ErrorReporter + sig { type_parameters(:Block, :Fallback).params(error_classes: T.class_of(Exception), severity: T.nilable(Symbol), context: T.nilable(T::Hash[Symbol, T.untyped]), fallback: T.nilable(T.proc.returns(T.type_parameter(:Fallback))), source: T.nilable(String), blk: T.proc.returns(T.type_parameter(:Block))).returns(T.any(T.type_parameter(:Block), T.type_parameter(:Fallback))) } + def handle(*error_classes, severity: T.unsafe(nil), context: T.unsafe(nil), fallback: T.unsafe(nil), source: T.unsafe(nil), &blk); end + + sig { type_parameters(:Block).params(error_classes: T.class_of(Exception), severity: T.nilable(Symbol), context: T.nilable(T::Hash[Symbol, T.untyped]), source: T.nilable(String), blk: T.proc.returns(T.type_parameter(:Block))).returns(T.type_parameter(:Block)) } + def record(*error_classes, severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil), &blk); end + + sig { params(error: Exception, handled: T::Boolean, severity: T.nilable(Symbol), context: T::Hash[Symbol, T.untyped], source: T.nilable(String)).void } + def report(error, handled: true, severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil)); end end diff --git a/sorbet/rbi/annotations/devise.rbi b/sorbet/rbi/annotations/devise.rbi new file mode 100644 index 000000000..db48648eb --- /dev/null +++ b/sorbet/rbi/annotations/devise.rbi @@ -0,0 +1,168 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This file was pulled from a central RBI files repository. +# Please run `bin/tapioca annotations` to update it. + +# @shim: Devise controllers are loaded by rails +class DeviseController + sig { returns(T.untyped) } + def resource; end + + # Proxy to devise map name + sig { returns(String) } + def resource_name; end + + sig { returns(String) } + def scope_name; end + + # Proxy to devise map class + sig { returns(T::Class[T.anything]) } + def resource_class; end + + # Returns a signed in resource from session (if one exists) + sig { returns(T.untyped) } + def signed_in_resource; end + + # Attempt to find the mapped route for devise based on request path + sig { returns(T.untyped) } + def devise_mapping; end + + sig { returns(T.untyped) } + def navigational_formats; end + + sig { returns(ActionController::Parameters) } + def resource_params; end + + sig { returns(String) } + def translation_scope; end +end + +# @shim: Devise controllers are loaded by rails +class Devise::ConfirmationsController < DeviseController + sig { returns(T.untyped) } + def new; end + + # POST /resource/confirmation + sig { returns(T.untyped) } + def create; end + + # GET /resource/confirmation?confirmation_token=abcdef + sig { returns(T.untyped) } + def show; end +end + +# @shim: Devise controllers are loaded by rails +class Devise::PasswordsController < DeviseController + # GET /resource/password/new + sig { returns(T.untyped) } + def new; end + + # POST /resource/password + sig { returns(T.untyped) } + def create; end + + # GET /resource/password/edit?reset_password_token=abcdef + sig { returns(T.untyped) } + def edit; end + + # PUT /resource/password + sig { returns(T.untyped) } + def update; end +end + +# @shim: Devise controllers are loaded by rails +class Devise::RegistrationsController < DeviseController + sig { returns(T.untyped) } + def new; end + + # POST /resource + sig { returns(T.untyped) } + def create; end + + # GET /resource/edit + sig { returns(T.untyped) } + def edit; end + + # PUT /resource + # We need to use a copy of the resource because we don't want to change + # the current user in place. + sig { returns(T.untyped) } + def update; end + + # DELETE /resource + sig { returns(T.untyped) } + def destroy; end + + # GET /resource/cancel + # Forces the session data which is usually expired after sign + # in to be expired now. This is useful if the user wants to + # cancel oauth signing in/up in the middle of the process, + # removing all OAuth session data. + sig { returns(T.untyped) } + def cancel; end +end + +# @shim: Devise controllers are loaded by rails +class Devise::SessionsController < DeviseController + # GET /resource/sign_in + sig { returns(T.untyped) } + def new; end + + # POST /resource/sign_in + sig { returns(T.untyped) } + def create; end + + # DELETE /resource/sign_out + sig { returns(T.untyped) } + def destroy; end + + sig { returns(ActionController::Parameters) } + def sign_in_params; end +end + +# @shim: Devise controllers are loaded by rails +class Devise::UnlocksController < DeviseController + # GET /resource/unlock/new + sig { returns(T.untyped) } + def new; end + + # POST /resource/unlock + sig { returns(T.untyped) } + def create; end + + # GET /resource/unlock?unlock_token=abcdef + sig { returns(T.untyped) } + def show; end + + # The path used after sending unlock password instructions + sig { params(resource: T.untyped).returns(String) } + def after_sending_unlock_instructions_path_for(resource); end + + # The path used after unlocking the resource + sig { params(resource: T.untyped).returns(String) } + def after_unlock_path_for(resource); end +end + +# @shim: Devise controllers are loaded by rails +class Devise::OmniauthCallbacksController < DeviseController + # GET|POST /resource/auth/provider + sig { returns(T.untyped) } + def passthru; end + + # GET|POST /resource/auth/provider/callback + sig { returns(T.untyped) } + def failure; end + + sig { returns(String) } + def failed_strategy; end + + sig { returns(String) } + def failure_message; end + + sig { params(scope: String).returns(String) } + def after_omniauth_failure_path_for(scope); end + + sig { returns(String) } + def translation_scope; end +end diff --git a/sorbet/rbi/annotations/faraday.rbi b/sorbet/rbi/annotations/faraday.rbi index 59240715c..c992c1afe 100644 --- a/sorbet/rbi/annotations/faraday.rbi +++ b/sorbet/rbi/annotations/faraday.rbi @@ -1,4 +1,4 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. diff --git a/sorbet/rbi/annotations/globalid.rbi b/sorbet/rbi/annotations/globalid.rbi index e70d46b02..916b21d22 100644 --- a/sorbet/rbi/annotations/globalid.rbi +++ b/sorbet/rbi/annotations/globalid.rbi @@ -1,4 +1,4 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. diff --git a/sorbet/rbi/annotations/minitest.rbi b/sorbet/rbi/annotations/minitest.rbi new file mode 100644 index 000000000..64a89286e --- /dev/null +++ b/sorbet/rbi/annotations/minitest.rbi @@ -0,0 +1,119 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This file was pulled from a central RBI files repository. +# Please run `bin/tapioca annotations` to update it. + +module Minitest::Assertions + sig { params(test: T.anything, msg: T.anything).returns(TrueClass) } + def assert(test, msg = nil); end + + sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) } + def assert_empty(obj, msg = nil); end + + sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) } + def assert_equal(exp, act, msg = nil); end + + sig { params(exp: T.anything, act: T.anything, delta: Numeric, msg: T.anything).returns(TrueClass) } + def assert_in_delta(exp, act, delta = T.unsafe(nil), msg = nil); end + + sig { params(a: T.anything, b: T.anything, epsilon: Numeric, msg: T.anything).returns(TrueClass) } + def assert_in_epsilon(a, b, epsilon = T.unsafe(nil), msg = nil); end + + sig { params(collection: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) } + def assert_includes(collection, obj, msg = nil); end + + sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) } + def assert_instance_of(cls, obj, msg = nil); end + + sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) } + def assert_kind_of(cls, obj, msg = nil); end + + sig { params(matcher: T.any(String, Regexp), obj: T.anything, msg: T.anything).returns(MatchData) } + def assert_match(matcher, obj, msg = nil); end + + sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) } + def assert_nil(obj, msg = nil); end + + sig { params(o1: T.anything, op: T.any(Symbol, String), o2: T.anything, msg: T.anything).returns(TrueClass) } + def assert_operator(o1, op, o2 = T.unsafe(nil), msg = nil); end + + sig { params(stdout: T.nilable(T.any(String, Regexp)), stderr: T.nilable(T.any(String, Regexp)), block: T.proc.void).returns(T::Boolean) } + def assert_output(stdout = nil, stderr = nil, &block); end + + sig { params(path: T.any(String, Pathname), msg: T.anything).returns(TrueClass) } + def assert_path_exists(path, msg = nil); end + + sig { params(block: T.proc.void).returns(TrueClass) } + def assert_pattern(&block); end + + sig { params(o1: T.anything, op: T.any(String, Symbol), msg: T.anything).returns(TrueClass) } + def assert_predicate(o1, op, msg = nil); end + + sig { params(exp: NilClass, block: T.proc.void).returns(StandardError) } + sig { type_parameters(:T).params(exp: T.any(T::Class[T.type_parameter(:T)], Regexp, String), block: T.proc.void).returns(T.type_parameter(:T)) } + def assert_raises(*exp, &block); end + + sig { params(obj: T.anything, meth: T.any(String, Symbol), msg: T.anything, include_all: T::Boolean).returns(TrueClass) } + def assert_respond_to(obj, meth, msg = nil, include_all: false); end + + sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) } + def assert_same(exp, act, msg = nil); end + + sig { params(send_ary: T::Array[T.anything], m: T.anything).returns(T::Boolean) } + def assert_send(send_ary, m = nil); end + + sig { params(block: T.proc.void).returns(T::Boolean) } + def assert_silent(&block); end + + sig { params(sym: Symbol, msg: T.anything, block: T.proc.void).returns(T.anything) } + def assert_throws(sym, msg = nil, &block); end + + sig { params(test: T.anything, msg: T.anything).returns(TrueClass) } + def refute(test, msg = nil); end + + sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) } + def refute_empty(obj, msg = nil); end + + sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) } + def refute_equal(exp, act, msg = nil); end + + sig { params(exp: T.anything, act: T.anything, delta: Numeric, msg: T.anything).returns(TrueClass) } + def refute_in_delta(exp, act, delta = T.unsafe(nil), msg = nil); end + + sig { params(a: T.anything, b: T.anything, epsilon: Numeric, msg: T.anything).returns(TrueClass) } + def refute_in_epsilon(a, b, epsilon = T.unsafe(nil), msg = nil); end + + sig { params(collection: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) } + def refute_includes(collection, obj, msg = nil); end + + sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) } + def refute_instance_of(cls, obj, msg = nil); end + + sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) } + def refute_kind_of(cls, obj, msg = nil); end + + sig { params(matcher: T.any(String, Regexp), obj: T.anything, msg: T.anything).returns(TrueClass) } + def refute_match(matcher, obj, msg = nil); end + + sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) } + def refute_nil(obj, msg = nil); end + + sig { params(block: T.proc.void).returns(TrueClass) } + def refute_pattern(&block); end + + sig { params(o1: T.anything, op: T.any(Symbol, String), o2: T.anything, msg: T.anything).returns(TrueClass) } + def refute_operator(o1, op, o2 = T.unsafe(nil), msg = nil); end + + sig { params(path: T.any(String, Pathname), msg: T.anything).returns(TrueClass) } + def refute_path_exists(path, msg = nil); end + + sig { params(o1: T.anything, op: T.any(String, Symbol), msg: T.anything).returns(TrueClass) } + def refute_predicate(o1, op, msg = nil); end + + sig { params(obj: T.anything, meth: T.any(String, Symbol), msg: T.anything, include_all: T::Boolean).returns(TrueClass) } + def refute_respond_to(obj, meth, msg = nil, include_all: false); end + + sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) } + def refute_same(exp, act, msg = nil); end +end diff --git a/sorbet/rbi/annotations/railties.rbi b/sorbet/rbi/annotations/railties.rbi index f71f1350f..cec2842d3 100644 --- a/sorbet/rbi/annotations/railties.rbi +++ b/sorbet/rbi/annotations/railties.rbi @@ -1,4 +1,4 @@ -# typed: strong +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. @@ -18,6 +18,9 @@ module Rails sig { returns(ActiveSupport::EnvironmentInquirer) } def env; end + sig { returns(ActiveSupport::ErrorReporter) } + def error; end + sig { returns(ActiveSupport::Logger) } def logger; end diff --git a/sorbet/rbi/annotations/rainbow.rbi b/sorbet/rbi/annotations/rainbow.rbi index 60ba90a9b..0d2cb4e48 100644 --- a/sorbet/rbi/annotations/rainbow.rbi +++ b/sorbet/rbi/annotations/rainbow.rbi @@ -1,4 +1,4 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. @@ -60,14 +60,14 @@ module Rainbow class X11Named < Rainbow::Color::RGB include Rainbow::X11ColorNames + sig { params(ground: Symbol, name: Symbol).void } + def initialize(ground, name); end + sig { returns(T::Array[Symbol]) } def self.color_names; end sig { returns(String) } def self.valid_names; end - - sig { params(ground: Symbol, name: Symbol).void } - def initialize(ground, name); end end end diff --git a/sorbet/rbi/annotations/sidekiq.rbi b/sorbet/rbi/annotations/sidekiq.rbi index 143b4b44a..38dc28493 100644 --- a/sorbet/rbi/annotations/sidekiq.rbi +++ b/sorbet/rbi/annotations/sidekiq.rbi @@ -1,32 +1,31 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. # Please run `bin/tapioca annotations` to update it. class Sidekiq::CLI - sig { returns(Sidekiq::CLI) } - def self.instance; end - sig { returns(Sidekiq::Launcher) } def launcher; end + + sig { returns(Sidekiq::CLI) } + def self.instance; end end class Sidekiq::Client + sig { params(item: T.untyped).returns(T.untyped) } def normalize_item(item); end + + sig { params(item_class: T.untyped).returns(T.untyped) } def normalized_hash(item_class); end end class Sidekiq::DeadSet < ::Sidekiq::JobSet - Elem = type_member { - { fixed: Sidekiq::SortedEntry } -} + Elem = type_member { { fixed: Sidekiq::SortedEntry } } end class Sidekiq::JobSet < ::Sidekiq::SortedSet - Elem = type_member { - { fixed: Sidekiq::SortedEntry } -} + Elem = type_member { { fixed: Sidekiq::SortedEntry } } end class Sidekiq::Launcher @@ -35,21 +34,15 @@ class Sidekiq::Launcher end class Sidekiq::Middleware::Chain - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } end class Sidekiq::ProcessSet - Elem = type_member { - { fixed: Sidekiq::Process } -} + Elem = type_member { { fixed: Sidekiq::Process } } end class Sidekiq::Queue - Elem = type_member { - { fixed: Sidekiq::Job } -} + Elem = type_member { { fixed: Sidekiq::Job } } sig { returns(T::Boolean) } def paused?; end @@ -59,21 +52,15 @@ class Sidekiq::Queue end class Sidekiq::RetrySet < ::Sidekiq::JobSet - Elem = type_member { - { fixed: Sidekiq::SortedEntry } -} + Elem = type_member { { fixed: Sidekiq::SortedEntry } } end class Sidekiq::ScheduledSet < ::Sidekiq::JobSet - Elem = type_member { - { fixed: Sidekiq::SortedEntry } -} + Elem = type_member { { fixed: Sidekiq::SortedEntry } } end class Sidekiq::SortedSet - Elem = type_member { - { fixed: Sidekiq::SortedEntry } -} + Elem = type_member { { fixed: Sidekiq::SortedEntry } } end module Sidekiq::Job @@ -93,7 +80,5 @@ module Sidekiq::Job::ClassMethods end class Sidekiq::WorkSet - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } end diff --git a/sorbet/rbi/annotations/stripe.rbi b/sorbet/rbi/annotations/stripe.rbi index 1ae187982..24b1b84c2 100644 --- a/sorbet/rbi/annotations/stripe.rbi +++ b/sorbet/rbi/annotations/stripe.rbi @@ -1,16 +1,11 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. # Please run `bin/tapioca annotations` to update it. class Stripe::APIResource < Stripe::StripeObject - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::APIResource) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } sig { returns(Stripe::APIResource) } def refresh; end @@ -27,15 +22,13 @@ class Stripe::APIResource < Stripe::StripeObject # @method_missing: from StripeObject sig { params(val: T::Hash[T.any(String, Symbol), T.untyped]).void } def metadata=(val); end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::APIResource) } + def self.retrieve(id, opts = nil); end end class Stripe::ApplicationFee < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::ApplicationFee) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -44,15 +37,13 @@ class Stripe::ApplicationFee < Stripe::APIResource # @method_missing: from StripeObject sig { returns(Stripe::ListObject) } def refunds; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::ApplicationFee) } + def self.retrieve(id, opts = nil); end end class Stripe::BalanceTransaction < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::BalanceTransaction) } - def self.retrieve(id, opts = {}); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -82,12 +73,13 @@ class Stripe::BalanceTransaction < Stripe::APIResource # @method_missing: from StripeObject sig { returns(Integer) } def created; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::BalanceTransaction) } + def self.retrieve(id, opts = {}); end end class Stripe::BankAccount < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -107,12 +99,7 @@ class Stripe::BankAccount < Stripe::APIResource end class Stripe::Card < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Card) } - def self.retrieve(id, opts = {}); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -149,15 +136,13 @@ class Stripe::Card < Stripe::APIResource # @method_missing: from StripeObject sig { params(other: String).returns(String) } def last4=(other); end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Card) } + def self.retrieve(id, opts = {}); end end class Stripe::Charge < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Charge) } - def self.retrieve(id, opts = {}); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(Stripe::ListObject) } @@ -230,28 +215,24 @@ class Stripe::Charge < Stripe::APIResource # @method_missing: from StripeObject sig { returns(T.nilable(T.any(String, Stripe::Customer))) } def customer; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Charge) } + def self.retrieve(id, opts = {}); end end class Stripe::Coupon < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Coupon) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(T.nilable(String)) } def name; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Coupon) } + def self.retrieve(id, opts = nil); end end class Stripe::CreditNote < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::CreditNote) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(Integer) } @@ -300,12 +281,13 @@ class Stripe::CreditNote < Stripe::APIResource # @method_missing: from StripeObject sig { returns(T.nilable(Stripe::Refund)) } def refund; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::CreditNote) } + def self.retrieve(id, opts = nil); end end class Stripe::CreditNoteLineItem < Stripe::StripeObject - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -333,12 +315,7 @@ class Stripe::CreditNoteLineItem < Stripe::StripeObject end class Stripe::Customer < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Customer) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -379,12 +356,13 @@ class Stripe::Customer < Stripe::APIResource # @method_missing: from StripeObject sig { returns(T.nilable(String)) } def email; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Customer) } + def self.retrieve(id, opts = nil); end end class Stripe::CustomerBalanceTransaction < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(Integer) } @@ -420,9 +398,7 @@ class Stripe::CustomerBalanceTransaction < Stripe::APIResource end class Stripe::Discount < Stripe::StripeObject - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(Stripe::Coupon) } @@ -430,12 +406,7 @@ class Stripe::Discount < Stripe::StripeObject end class Stripe::Dispute < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Dispute) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(T.nilable(String)) } @@ -452,12 +423,13 @@ class Stripe::Dispute < Stripe::APIResource # @method_missing: from StripeObject sig { returns(T::Array[Stripe::BalanceTransaction]) } def balance_transactions; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Dispute) } + def self.retrieve(id, opts = nil); end end class Stripe::Event < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -476,12 +448,7 @@ class Stripe::Event < Stripe::APIResource end class Stripe::Invoice < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Invoice) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(T.nilable(Stripe::PaymentIntent)) } @@ -532,16 +499,15 @@ class Stripe::Invoice < Stripe::APIResource def subtotal; end # @method_missing: from StripeObject + sig { returns(T::Hash[T.untyped, T.untyped]) } def status_transitions; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Invoice) } + def self.retrieve(id, opts = nil); end end class Stripe::InvoiceItem < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::InvoiceItem) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(T.nilable(Stripe::Plan)) } @@ -561,16 +527,15 @@ class Stripe::InvoiceItem < Stripe::APIResource # unsure how to represent a StripeObject with specific keys/mmethods without causing typing errors # @method_missing: from StripeObject + sig { returns(T::Hash[T.untyped, T.untyped]) } def period; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::InvoiceItem) } + def self.retrieve(id, opts = nil); end end class Stripe::File < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::File) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -607,12 +572,13 @@ class Stripe::File < Stripe::APIResource # @method_missing: from StripeObject sig { returns(String) } def url; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::File) } + def self.retrieve(id, opts = nil); end end class Stripe::ListObject - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(T::Array[T.untyped]) } @@ -624,12 +590,7 @@ class Stripe::ListObject end class Stripe::PaymentIntent < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::PaymentIntent) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -646,15 +607,13 @@ class Stripe::PaymentIntent < Stripe::APIResource # @method_missing: from StripeObject sig { returns(Stripe::ListObject) } def line_items; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::PaymentIntent) } + def self.retrieve(id, opts = nil); end end class Stripe::PaymentMethod < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::PaymentMethod) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(Stripe::Card) } @@ -663,15 +622,13 @@ class Stripe::PaymentMethod < Stripe::APIResource # @method_missing: from StripeObject sig { returns(String) } def type; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::PaymentMethod) } + def self.retrieve(id, opts = nil); end end class Stripe::Payout < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Payout) } - def self.retrieve(id, opts = {}); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(Integer) } @@ -684,32 +641,29 @@ class Stripe::Payout < Stripe::APIResource # @method_missing: from StripeObject sig { returns(Integer) } def amount; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Payout) } + def self.retrieve(id, opts = {}); end end class Stripe::Plan < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Plan) } - def self.retrieve(id, opts = {}); end + Elem = type_member { { fixed: T.untyped } } # unsure how to represent a StripeObject with specific keys/mmethods without causing typing errors # @method_missing: from StripeObject + sig { returns(T::Hash[T.untyped, T.untyped]) } def period; end # @method_missing: from StripeObject sig { returns(T.any(String, Stripe::Product)) } def product; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Plan) } + def self.retrieve(id, opts = {}); end end class Stripe::Product < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Product) } - def self.retrieve(id, opts = {}); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -722,15 +676,13 @@ class Stripe::Product < Stripe::APIResource # @method_missing: from StripeObject sig { returns(T::Boolean) } def shippable; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Product) } + def self.retrieve(id, opts = {}); end end class Stripe::Refund < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Refund) } - def self.retrieve(id, opts = {}); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -751,12 +703,13 @@ class Stripe::Refund < Stripe::APIResource # @method_missing: from StripeObject sig { returns(Integer) } def created; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.any(String, T::Array[String])]), opts: T.nilable(T::Hash[T.untyped, T.untyped])).returns(Stripe::Refund) } + def self.retrieve(id, opts = {}); end end class Stripe::Source < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Source) } def self.retrieve(id, opts = nil); end @@ -771,9 +724,7 @@ class Stripe::StripeError end class Stripe::StripeObject - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(T.any(Stripe::Subscription, Stripe::Customer, Stripe::Invoice)) } @@ -784,12 +735,7 @@ class Stripe::StripeObject end class Stripe::Subscription < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Subscription) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { params(val: T::Array[T::Hash[Symbol, T.untyped]]).void } @@ -810,12 +756,13 @@ class Stripe::Subscription < Stripe::APIResource # @method_missing: from StripeObject sig { returns(T.nilable(T.any(T.nilable(Stripe::Invoice), T.nilable(String)))) } def latest_invoice; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Subscription) } + def self.retrieve(id, opts = nil); end end class Stripe::TaxRate < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(T.nilable(String)) } @@ -831,12 +778,7 @@ class Stripe::TaxRate < Stripe::APIResource end class Stripe::Token < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Token) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(String) } @@ -845,17 +787,18 @@ class Stripe::Token < Stripe::APIResource # @method_missing: from StripeObject sig { returns(Stripe::BankAccount) } def bank_account; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Token) } + def self.retrieve(id, opts = nil); end end class Stripe::Transfer < Stripe::APIResource - Elem = type_member { - { fixed: T.untyped } -} - - sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Transfer) } - def self.retrieve(id, opts = nil); end + Elem = type_member { { fixed: T.untyped } } # @method_missing: from StripeObject sig { returns(Stripe::ListObject) } def reversals; end + + sig { params(id: T.any(String, T::Hash[Symbol, T.untyped]), opts: T.nilable(T::Hash[Symbol, T.untyped])).returns(Stripe::Transfer) } + def self.retrieve(id, opts = nil); end end diff --git a/sorbet/rbi/annotations/webmock.rbi b/sorbet/rbi/annotations/webmock.rbi index f6b9c033b..16456ddf4 100644 --- a/sorbet/rbi/annotations/webmock.rbi +++ b/sorbet/rbi/annotations/webmock.rbi @@ -1,4 +1,4 @@ -# typed: strict +# typed: true # DO NOT EDIT MANUALLY # This file was pulled from a central RBI files repository. diff --git a/sorbet/rbi/dsl/.gitattributes b/sorbet/rbi/dsl/.gitattributes new file mode 100644 index 000000000..d9bb82a4d --- /dev/null +++ b/sorbet/rbi/dsl/.gitattributes @@ -0,0 +1 @@ +**/*.rbi linguist-generated=true diff --git a/sorbet/rbi/dsl/abstract_controller/caching.rbi b/sorbet/rbi/dsl/abstract_controller/caching.rbi index 3c397620d..826d65cab 100644 --- a/sorbet/rbi/dsl/abstract_controller/caching.rbi +++ b/sorbet/rbi/dsl/abstract_controller/caching.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AbstractController::Caching`. # Please instead update this file by running `bin/tapioca dsl AbstractController::Caching`. + module AbstractController::Caching include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/abstract_controller/caching/fragments.rbi b/sorbet/rbi/dsl/abstract_controller/caching/fragments.rbi index ea36ce31e..d04a840a8 100644 --- a/sorbet/rbi/dsl/abstract_controller/caching/fragments.rbi +++ b/sorbet/rbi/dsl/abstract_controller/caching/fragments.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AbstractController::Caching::Fragments`. # Please instead update this file by running `bin/tapioca dsl AbstractController::Caching::Fragments`. + module AbstractController::Caching::Fragments include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/abstract_controller/callbacks.rbi b/sorbet/rbi/dsl/abstract_controller/callbacks.rbi index e5ef916a5..97d95a8e8 100644 --- a/sorbet/rbi/dsl/abstract_controller/callbacks.rbi +++ b/sorbet/rbi/dsl/abstract_controller/callbacks.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AbstractController::Callbacks`. # Please instead update this file by running `bin/tapioca dsl AbstractController::Callbacks`. + module AbstractController::Callbacks include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/abstract_controller/helpers.rbi b/sorbet/rbi/dsl/abstract_controller/helpers.rbi index e4c003aaa..3f1bbc125 100644 --- a/sorbet/rbi/dsl/abstract_controller/helpers.rbi +++ b/sorbet/rbi/dsl/abstract_controller/helpers.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AbstractController::Helpers`. # Please instead update this file by running `bin/tapioca dsl AbstractController::Helpers`. + module AbstractController::Helpers include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/abstract_controller/rendering.rbi b/sorbet/rbi/dsl/abstract_controller/rendering.rbi index b6458761d..4a3bfe1e4 100644 --- a/sorbet/rbi/dsl/abstract_controller/rendering.rbi +++ b/sorbet/rbi/dsl/abstract_controller/rendering.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AbstractController::Rendering`. # Please instead update this file by running `bin/tapioca dsl AbstractController::Rendering`. + module AbstractController::Rendering mixes_in_class_methods ::ActionView::ViewPaths::ClassMethods end diff --git a/sorbet/rbi/dsl/abstract_controller/url_for.rbi b/sorbet/rbi/dsl/abstract_controller/url_for.rbi index 5cda13ffa..14ffe072e 100644 --- a/sorbet/rbi/dsl/abstract_controller/url_for.rbi +++ b/sorbet/rbi/dsl/abstract_controller/url_for.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AbstractController::UrlFor`. # Please instead update this file by running `bin/tapioca dsl AbstractController::UrlFor`. + module AbstractController::UrlFor include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_cable/channel/callbacks.rbi b/sorbet/rbi/dsl/action_cable/channel/callbacks.rbi index 50b6f076d..6bd1913ef 100644 --- a/sorbet/rbi/dsl/action_cable/channel/callbacks.rbi +++ b/sorbet/rbi/dsl/action_cable/channel/callbacks.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionCable::Channel::Callbacks`. # Please instead update this file by running `bin/tapioca dsl ActionCable::Channel::Callbacks`. + module ActionCable::Channel::Callbacks include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_cable/channel/periodic_timers.rbi b/sorbet/rbi/dsl/action_cable/channel/periodic_timers.rbi index 37382315a..9e62b4fbb 100644 --- a/sorbet/rbi/dsl/action_cable/channel/periodic_timers.rbi +++ b/sorbet/rbi/dsl/action_cable/channel/periodic_timers.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionCable::Channel::PeriodicTimers`. # Please instead update this file by running `bin/tapioca dsl ActionCable::Channel::PeriodicTimers`. + module ActionCable::Channel::PeriodicTimers include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/validations.rbi b/sorbet/rbi/dsl/action_cable/connection/callbacks.rbi similarity index 54% rename from sorbet/rbi/dsl/active_record/validations.rbi rename to sorbet/rbi/dsl/action_cable/connection/callbacks.rbi index f7697f9a1..21a0a147c 100644 --- a/sorbet/rbi/dsl/active_record/validations.rbi +++ b/sorbet/rbi/dsl/action_cable/connection/callbacks.rbi @@ -1,28 +1,24 @@ # typed: true # DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveRecord::Validations`. -# Please instead update this file by running `bin/tapioca dsl ActiveRecord::Validations`. +# This is an autogenerated file for dynamic methods in `ActionCable::Connection::Callbacks`. +# Please instead update this file by running `bin/tapioca dsl ActionCable::Connection::Callbacks`. -module ActiveRecord::Validations + +module ActionCable::Connection::Callbacks include GeneratedInstanceMethods - mixes_in_class_methods ::ActiveModel::Validations::ClassMethods + mixes_in_class_methods ::ActiveSupport::Callbacks::ClassMethods mixes_in_class_methods GeneratedClassMethods module GeneratedClassMethods def __callbacks; end def __callbacks=(value); end def __callbacks?; end - def _validators; end - def _validators=(value); end - def _validators?; end end module GeneratedInstanceMethods def __callbacks; end def __callbacks?; end - def _validators; end - def _validators?; end end end diff --git a/sorbet/rbi/dsl/action_cable/connection/identification.rbi b/sorbet/rbi/dsl/action_cable/connection/identification.rbi new file mode 100644 index 000000000..e835fe780 --- /dev/null +++ b/sorbet/rbi/dsl/action_cable/connection/identification.rbi @@ -0,0 +1,24 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActionCable::Connection::Identification`. +# Please instead update this file by running `bin/tapioca dsl ActionCable::Connection::Identification`. + + +module ActionCable::Connection::Identification + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def identifiers; end + def identifiers=(value); end + def identifiers?; end + end + + module GeneratedInstanceMethods + def identifiers; end + def identifiers=(value); end + def identifiers?; end + end +end diff --git a/sorbet/rbi/dsl/action_controller/api_rendering.rbi b/sorbet/rbi/dsl/action_controller/api_rendering.rbi index 891a67ed3..ee5efecb6 100644 --- a/sorbet/rbi/dsl/action_controller/api_rendering.rbi +++ b/sorbet/rbi/dsl/action_controller/api_rendering.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::ApiRendering`. # Please instead update this file by running `bin/tapioca dsl ActionController::ApiRendering`. + module ActionController::ApiRendering mixes_in_class_methods ::ActionView::ViewPaths::ClassMethods mixes_in_class_methods ::ActionView::Rendering::ClassMethods diff --git a/sorbet/rbi/dsl/action_controller/caching.rbi b/sorbet/rbi/dsl/action_controller/caching.rbi index 3e3d1ab9b..f88717f92 100644 --- a/sorbet/rbi/dsl/action_controller/caching.rbi +++ b/sorbet/rbi/dsl/action_controller/caching.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::Caching`. # Please instead update this file by running `bin/tapioca dsl ActionController::Caching`. + module ActionController::Caching include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/conditional_get.rbi b/sorbet/rbi/dsl/action_controller/conditional_get.rbi index be922d2b3..a35b10224 100644 --- a/sorbet/rbi/dsl/action_controller/conditional_get.rbi +++ b/sorbet/rbi/dsl/action_controller/conditional_get.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::ConditionalGet`. # Please instead update this file by running `bin/tapioca dsl ActionController::ConditionalGet`. + module ActionController::ConditionalGet include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/content_security_policy.rbi b/sorbet/rbi/dsl/action_controller/content_security_policy.rbi index a32524d40..fb4f36501 100644 --- a/sorbet/rbi/dsl/action_controller/content_security_policy.rbi +++ b/sorbet/rbi/dsl/action_controller/content_security_policy.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::ContentSecurityPolicy`. # Please instead update this file by running `bin/tapioca dsl ActionController::ContentSecurityPolicy`. + module ActionController::ContentSecurityPolicy include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/data_streaming.rbi b/sorbet/rbi/dsl/action_controller/data_streaming.rbi index c233ddf5f..91ac61162 100644 --- a/sorbet/rbi/dsl/action_controller/data_streaming.rbi +++ b/sorbet/rbi/dsl/action_controller/data_streaming.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::DataStreaming`. # Please instead update this file by running `bin/tapioca dsl ActionController::DataStreaming`. + module ActionController::DataStreaming mixes_in_class_methods ::ActionController::Rendering::ClassMethods end diff --git a/sorbet/rbi/dsl/action_controller/etag_with_flash.rbi b/sorbet/rbi/dsl/action_controller/etag_with_flash.rbi index a47c99480..ab5f950c3 100644 --- a/sorbet/rbi/dsl/action_controller/etag_with_flash.rbi +++ b/sorbet/rbi/dsl/action_controller/etag_with_flash.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::EtagWithFlash`. # Please instead update this file by running `bin/tapioca dsl ActionController::EtagWithFlash`. + module ActionController::EtagWithFlash include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/etag_with_template_digest.rbi b/sorbet/rbi/dsl/action_controller/etag_with_template_digest.rbi index 9b275ba70..d6602b7c8 100644 --- a/sorbet/rbi/dsl/action_controller/etag_with_template_digest.rbi +++ b/sorbet/rbi/dsl/action_controller/etag_with_template_digest.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::EtagWithTemplateDigest`. # Please instead update this file by running `bin/tapioca dsl ActionController::EtagWithTemplateDigest`. + module ActionController::EtagWithTemplateDigest include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/flash.rbi b/sorbet/rbi/dsl/action_controller/flash.rbi index 7793a6252..d68546701 100644 --- a/sorbet/rbi/dsl/action_controller/flash.rbi +++ b/sorbet/rbi/dsl/action_controller/flash.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::Flash`. # Please instead update this file by running `bin/tapioca dsl ActionController::Flash`. + module ActionController::Flash include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/form_builder.rbi b/sorbet/rbi/dsl/action_controller/form_builder.rbi index dc249ce22..059161cc7 100644 --- a/sorbet/rbi/dsl/action_controller/form_builder.rbi +++ b/sorbet/rbi/dsl/action_controller/form_builder.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::FormBuilder`. # Please instead update this file by running `bin/tapioca dsl ActionController::FormBuilder`. + module ActionController::FormBuilder include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/helpers.rbi b/sorbet/rbi/dsl/action_controller/helpers.rbi index b33bbd494..dbfe5f4bf 100644 --- a/sorbet/rbi/dsl/action_controller/helpers.rbi +++ b/sorbet/rbi/dsl/action_controller/helpers.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::Helpers`. # Please instead update this file by running `bin/tapioca dsl ActionController::Helpers`. + module ActionController::Helpers include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/params_wrapper.rbi b/sorbet/rbi/dsl/action_controller/params_wrapper.rbi index d5f1e388a..4b12f1edd 100644 --- a/sorbet/rbi/dsl/action_controller/params_wrapper.rbi +++ b/sorbet/rbi/dsl/action_controller/params_wrapper.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::ParamsWrapper`. # Please instead update this file by running `bin/tapioca dsl ActionController::ParamsWrapper`. + module ActionController::ParamsWrapper include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/redirecting.rbi b/sorbet/rbi/dsl/action_controller/redirecting.rbi index 8460401d2..32ac3ea1e 100644 --- a/sorbet/rbi/dsl/action_controller/redirecting.rbi +++ b/sorbet/rbi/dsl/action_controller/redirecting.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::Redirecting`. # Please instead update this file by running `bin/tapioca dsl ActionController::Redirecting`. + module ActionController::Redirecting include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/renderers.rbi b/sorbet/rbi/dsl/action_controller/renderers.rbi index ec7617948..0c6e186d3 100644 --- a/sorbet/rbi/dsl/action_controller/renderers.rbi +++ b/sorbet/rbi/dsl/action_controller/renderers.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::Renderers`. # Please instead update this file by running `bin/tapioca dsl ActionController::Renderers`. + module ActionController::Renderers include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/renderers/all.rbi b/sorbet/rbi/dsl/action_controller/renderers/all.rbi index 80b72aa1f..5d5b25b57 100644 --- a/sorbet/rbi/dsl/action_controller/renderers/all.rbi +++ b/sorbet/rbi/dsl/action_controller/renderers/all.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::Renderers::All`. # Please instead update this file by running `bin/tapioca dsl ActionController::Renderers::All`. + module ActionController::Renderers::All include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/request_forgery_protection.rbi b/sorbet/rbi/dsl/action_controller/request_forgery_protection.rbi index 70e272728..d12ad2fcc 100644 --- a/sorbet/rbi/dsl/action_controller/request_forgery_protection.rbi +++ b/sorbet/rbi/dsl/action_controller/request_forgery_protection.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::RequestForgeryProtection`. # Please instead update this file by running `bin/tapioca dsl ActionController::RequestForgeryProtection`. + module ActionController::RequestForgeryProtection include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/rescue.rbi b/sorbet/rbi/dsl/action_controller/rescue.rbi index c4f14684c..b58f09628 100644 --- a/sorbet/rbi/dsl/action_controller/rescue.rbi +++ b/sorbet/rbi/dsl/action_controller/rescue.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::Rescue`. # Please instead update this file by running `bin/tapioca dsl ActionController::Rescue`. + module ActionController::Rescue include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/respond_with.rbi b/sorbet/rbi/dsl/action_controller/respond_with.rbi index 429a67f3b..e5c3d0f08 100644 --- a/sorbet/rbi/dsl/action_controller/respond_with.rbi +++ b/sorbet/rbi/dsl/action_controller/respond_with.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::RespondWith`. # Please instead update this file by running `bin/tapioca dsl ActionController::RespondWith`. + module ActionController::RespondWith include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/test_case/behavior.rbi b/sorbet/rbi/dsl/action_controller/test_case/behavior.rbi index 375bb9957..ee0cd10b1 100644 --- a/sorbet/rbi/dsl/action_controller/test_case/behavior.rbi +++ b/sorbet/rbi/dsl/action_controller/test_case/behavior.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::TestCase::Behavior`. # Please instead update this file by running `bin/tapioca dsl ActionController::TestCase::Behavior`. + module ActionController::TestCase::Behavior include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_controller/url_for.rbi b/sorbet/rbi/dsl/action_controller/url_for.rbi index 8a1567952..8b1aa82c2 100644 --- a/sorbet/rbi/dsl/action_controller/url_for.rbi +++ b/sorbet/rbi/dsl/action_controller/url_for.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionController::UrlFor`. # Please instead update this file by running `bin/tapioca dsl ActionController::UrlFor`. + module ActionController::UrlFor include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_dispatch/assertions.rbi b/sorbet/rbi/dsl/action_dispatch/assertions.rbi new file mode 100644 index 000000000..002fcd57b --- /dev/null +++ b/sorbet/rbi/dsl/action_dispatch/assertions.rbi @@ -0,0 +1,10 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActionDispatch::Assertions`. +# Please instead update this file by running `bin/tapioca dsl ActionDispatch::Assertions`. + + +module ActionDispatch::Assertions + mixes_in_class_methods ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods +end diff --git a/sorbet/rbi/dsl/action_dispatch/integration_test.rbi b/sorbet/rbi/dsl/action_dispatch/integration_test.rbi index 9db8d9faf..ff92dad53 100644 --- a/sorbet/rbi/dsl/action_dispatch/integration_test.rbi +++ b/sorbet/rbi/dsl/action_dispatch/integration_test.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionDispatch::IntegrationTest`. # Please instead update this file by running `bin/tapioca dsl ActionDispatch::IntegrationTest`. + class ActionDispatch::IntegrationTest include GeneratedUrlHelpersModule include GeneratedPathHelpersModule diff --git a/sorbet/rbi/dsl/action_dispatch/routing/route_set/mounted_helpers.rbi b/sorbet/rbi/dsl/action_dispatch/routing/route_set/mounted_helpers.rbi index 09b33877a..8810693c2 100644 --- a/sorbet/rbi/dsl/action_dispatch/routing/route_set/mounted_helpers.rbi +++ b/sorbet/rbi/dsl/action_dispatch/routing/route_set/mounted_helpers.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionDispatch::Routing::RouteSet::MountedHelpers`. # Please instead update this file by running `bin/tapioca dsl ActionDispatch::Routing::RouteSet::MountedHelpers`. + module ActionDispatch::Routing::RouteSet::MountedHelpers include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_dispatch/routing/url_for.rbi b/sorbet/rbi/dsl/action_dispatch/routing/url_for.rbi index 96483c686..8bb4a03f4 100644 --- a/sorbet/rbi/dsl/action_dispatch/routing/url_for.rbi +++ b/sorbet/rbi/dsl/action_dispatch/routing/url_for.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionDispatch::Routing::UrlFor`. # Please instead update this file by running `bin/tapioca dsl ActionDispatch::Routing::UrlFor`. + module ActionDispatch::Routing::UrlFor include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_mailbox/base_controller.rbi b/sorbet/rbi/dsl/action_mailbox/base_controller.rbi deleted file mode 100644 index d9c77df13..000000000 --- a/sorbet/rbi/dsl/action_mailbox/base_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::BaseController`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::BaseController`. - -class ActionMailbox::BaseController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/inbound_email.rbi b/sorbet/rbi/dsl/action_mailbox/inbound_email.rbi deleted file mode 100644 index 2b67e3268..000000000 --- a/sorbet/rbi/dsl/action_mailbox/inbound_email.rbi +++ /dev/null @@ -1,823 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::InboundEmail`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::InboundEmail`. - -class ActionMailbox::InboundEmail - include GeneratedAssociationMethods - include EnumMethodsModule - extend CommonRelationMethods - extend GeneratedRelationMethods - - sig { returns(ActiveStorage::Attached::One) } - def raw_email; end - - sig { params(attachable: T.untyped).returns(T.untyped) } - def raw_email=(attachable); end - - private - - sig { returns(NilClass) } - def to_ary; end - - class << self - sig { returns(T::Hash[T.any(String, Symbol), Integer]) } - def statuses; end - end - - module CommonRelationMethods - sig do - params( - block: T.nilable(T.proc.params(record: ::ActionMailbox::InboundEmail).returns(T.untyped)) - ).returns(T::Boolean) - end - def any?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def average(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def build(attributes = nil, &block); end - - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } - def calculate(operation, column_name); end - - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def create(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def create!(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def create_or_find_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def create_or_find_by!(attributes, &block); end - - sig { returns(T::Array[::ActionMailbox::InboundEmail]) } - def destroy_all; end - - sig { params(conditions: T.untyped).returns(T::Boolean) } - def exists?(conditions = :none); end - - sig { returns(T.nilable(::ActionMailbox::InboundEmail)) } - def fifth; end - - sig { returns(::ActionMailbox::InboundEmail) } - def fifth!; end - - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end - - sig { params(args: T.untyped).returns(T.nilable(::ActionMailbox::InboundEmail)) } - def find_by(*args); end - - sig { params(args: T.untyped).returns(::ActionMailbox::InboundEmail) } - def find_by!(*args); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def find_or_create_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def find_or_create_by!(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def find_or_initialize_by(attributes, &block); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(T.nilable(::ActionMailbox::InboundEmail)) } - def find_signed(signed_id, purpose: nil); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(::ActionMailbox::InboundEmail) } - def find_signed!(signed_id, purpose: nil); end - - sig { params(arg: T.untyped, args: T.untyped).returns(::ActionMailbox::InboundEmail) } - def find_sole_by(arg, *args); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def first(limit = nil); end - - sig { returns(::ActionMailbox::InboundEmail) } - def first!; end - - sig { returns(T.nilable(::ActionMailbox::InboundEmail)) } - def forty_two; end - - sig { returns(::ActionMailbox::InboundEmail) } - def forty_two!; end - - sig { returns(T.nilable(::ActionMailbox::InboundEmail)) } - def fourth; end - - sig { returns(::ActionMailbox::InboundEmail) } - def fourth!; end - - sig { returns(Array) } - def ids; end - - sig { params(record: T.untyped).returns(T::Boolean) } - def include?(record); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def last(limit = nil); end - - sig { returns(::ActionMailbox::InboundEmail) } - def last!; end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActionMailbox::InboundEmail).returns(T.untyped)) - ).returns(T::Boolean) - end - def many?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def maximum(column_name); end - - sig { params(record: T.untyped).returns(T::Boolean) } - def member?(record); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def minimum(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActionMailbox::InboundEmail).void) - ).returns(::ActionMailbox::InboundEmail) - end - def new(attributes = nil, &block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActionMailbox::InboundEmail).returns(T.untyped)) - ).returns(T::Boolean) - end - def none?(&block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActionMailbox::InboundEmail).returns(T.untyped)) - ).returns(T::Boolean) - end - def one?(&block); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pick(*column_names); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pluck(*column_names); end - - sig { returns(T.nilable(::ActionMailbox::InboundEmail)) } - def second; end - - sig { returns(::ActionMailbox::InboundEmail) } - def second!; end - - sig { returns(T.nilable(::ActionMailbox::InboundEmail)) } - def second_to_last; end - - sig { returns(::ActionMailbox::InboundEmail) } - def second_to_last!; end - - sig { returns(::ActionMailbox::InboundEmail) } - def sole; end - - sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) - end - def sum(column_name = nil, &block); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def take(limit = nil); end - - sig { returns(::ActionMailbox::InboundEmail) } - def take!; end - - sig { returns(T.nilable(::ActionMailbox::InboundEmail)) } - def third; end - - sig { returns(::ActionMailbox::InboundEmail) } - def third!; end - - sig { returns(T.nilable(::ActionMailbox::InboundEmail)) } - def third_to_last; end - - sig { returns(::ActionMailbox::InboundEmail) } - def third_to_last!; end - end - - module EnumMethodsModule - sig { void } - def bounced!; end - - sig { returns(T::Boolean) } - def bounced?; end - - sig { void } - def delivered!; end - - sig { returns(T::Boolean) } - def delivered?; end - - sig { void } - def failed!; end - - sig { returns(T::Boolean) } - def failed?; end - - sig { void } - def pending!; end - - sig { returns(T::Boolean) } - def pending?; end - - sig { void } - def processing!; end - - sig { returns(T::Boolean) } - def processing?; end - end - - module GeneratedAssociationMethods - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } - def build_raw_email_attachment(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } - def build_raw_email_blob(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } - def create_raw_email_attachment(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } - def create_raw_email_attachment!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } - def create_raw_email_blob(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } - def create_raw_email_blob!(*args, &blk); end - - sig { returns(T.untyped) } - def raw_email_attachment; end - - sig { params(value: T.untyped).void } - def raw_email_attachment=(value); end - - sig { returns(T.untyped) } - def raw_email_blob; end - - sig { params(value: T.untyped).void } - def raw_email_blob=(value); end - - sig { returns(T.untyped) } - def reload_raw_email_attachment; end - - sig { returns(T.untyped) } - def reload_raw_email_blob; end - end - - module GeneratedAssociationRelationMethods - sig { returns(PrivateAssociationRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def bounced(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def delivered(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def failed(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def includes(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_bounced(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_delivered(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_failed(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_pending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_processing(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def pending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def processing(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def unscope(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def with_attached_raw_email(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def without(*args, &blk); end - end - - module GeneratedRelationMethods - sig { returns(PrivateRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def bounced(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def delivered(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def failed(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def includes(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_bounced(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_delivered(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_failed(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_pending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_processing(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def pending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def processing(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def unscope(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def with_attached_raw_email(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def without(*args, &blk); end - end - - class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::ActionMailbox::InboundEmail } } - - sig { returns(T::Array[::ActionMailbox::InboundEmail]) } - def to_ary; end - end - - class PrivateAssociationRelationWhereChain < PrivateAssociationRelation - Elem = type_member { { fixed: ::ActionMailbox::InboundEmail } } - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateAssociationRelation) } - def not(opts, *rest); end - end - - class PrivateCollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::ActionMailbox::InboundEmail } } - - sig do - params( - records: T.any(::ActionMailbox::InboundEmail, T::Enumerable[T.any(::ActionMailbox::InboundEmail, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(PrivateCollectionProxy) - end - def <<(*records); end - - sig do - params( - records: T.any(::ActionMailbox::InboundEmail, T::Enumerable[T.any(::ActionMailbox::InboundEmail, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(PrivateCollectionProxy) - end - def append(*records); end - - sig { returns(PrivateCollectionProxy) } - def clear; end - - sig do - params( - records: T.any(::ActionMailbox::InboundEmail, T::Enumerable[T.any(::ActionMailbox::InboundEmail, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(PrivateCollectionProxy) - end - def concat(*records); end - - sig do - params( - records: T.any(::ActionMailbox::InboundEmail, Integer, String, T::Enumerable[T.any(::ActionMailbox::InboundEmail, Integer, String, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(T::Array[::ActionMailbox::InboundEmail]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActionMailbox::InboundEmail, Integer, String, T::Enumerable[T.any(::ActionMailbox::InboundEmail, Integer, String, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(T::Array[::ActionMailbox::InboundEmail]) - end - def destroy(*records); end - - sig { returns(T::Array[::ActionMailbox::InboundEmail]) } - def load_target; end - - sig do - params( - records: T.any(::ActionMailbox::InboundEmail, T::Enumerable[T.any(::ActionMailbox::InboundEmail, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(PrivateCollectionProxy) - end - def prepend(*records); end - - sig do - params( - records: T.any(::ActionMailbox::InboundEmail, T::Enumerable[T.any(::ActionMailbox::InboundEmail, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(PrivateCollectionProxy) - end - def push(*records); end - - sig do - params( - other_array: T.any(::ActionMailbox::InboundEmail, T::Enumerable[T.any(::ActionMailbox::InboundEmail, T::Enumerable[::ActionMailbox::InboundEmail])]) - ).returns(T::Array[::ActionMailbox::InboundEmail]) - end - def replace(other_array); end - - sig { returns(PrivateAssociationRelation) } - def scope; end - - sig { returns(T::Array[::ActionMailbox::InboundEmail]) } - def target; end - - sig { returns(T::Array[::ActionMailbox::InboundEmail]) } - def to_ary; end - end - - class PrivateRelation < ::ActiveRecord::Relation - include CommonRelationMethods - include GeneratedRelationMethods - - Elem = type_member { { fixed: ::ActionMailbox::InboundEmail } } - - sig { returns(T::Array[::ActionMailbox::InboundEmail]) } - def to_ary; end - end - - class PrivateRelationWhereChain < PrivateRelation - Elem = type_member { { fixed: ::ActionMailbox::InboundEmail } } - - sig { params(args: T.untyped).returns(PrivateRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateRelation) } - def not(opts, *rest); end - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/incineration_job.rbi b/sorbet/rbi/dsl/action_mailbox/incineration_job.rbi deleted file mode 100644 index d26676dec..000000000 --- a/sorbet/rbi/dsl/action_mailbox/incineration_job.rbi +++ /dev/null @@ -1,15 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::IncinerationJob`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::IncinerationJob`. - -class ActionMailbox::IncinerationJob - class << self - sig { params(inbound_email: T.untyped).returns(T.any(ActionMailbox::IncinerationJob, FalseClass)) } - def perform_later(inbound_email); end - - sig { params(inbound_email: T.untyped).returns(T.untyped) } - def perform_now(inbound_email); end - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/ingresses/mailgun/inbound_emails_controller.rbi b/sorbet/rbi/dsl/action_mailbox/ingresses/mailgun/inbound_emails_controller.rbi deleted file mode 100644 index 4aaaadae3..000000000 --- a/sorbet/rbi/dsl/action_mailbox/ingresses/mailgun/inbound_emails_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::Ingresses::Mailgun::InboundEmailsController`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::Ingresses::Mailgun::InboundEmailsController`. - -class ActionMailbox::Ingresses::Mailgun::InboundEmailsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/ingresses/mandrill/inbound_emails_controller.rbi b/sorbet/rbi/dsl/action_mailbox/ingresses/mandrill/inbound_emails_controller.rbi deleted file mode 100644 index dc58a66b3..000000000 --- a/sorbet/rbi/dsl/action_mailbox/ingresses/mandrill/inbound_emails_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::Ingresses::Mandrill::InboundEmailsController`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::Ingresses::Mandrill::InboundEmailsController`. - -class ActionMailbox::Ingresses::Mandrill::InboundEmailsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/ingresses/postmark/inbound_emails_controller.rbi b/sorbet/rbi/dsl/action_mailbox/ingresses/postmark/inbound_emails_controller.rbi deleted file mode 100644 index e48a8bdd2..000000000 --- a/sorbet/rbi/dsl/action_mailbox/ingresses/postmark/inbound_emails_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::Ingresses::Postmark::InboundEmailsController`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::Ingresses::Postmark::InboundEmailsController`. - -class ActionMailbox::Ingresses::Postmark::InboundEmailsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/ingresses/relay/inbound_emails_controller.rbi b/sorbet/rbi/dsl/action_mailbox/ingresses/relay/inbound_emails_controller.rbi deleted file mode 100644 index 6968f7168..000000000 --- a/sorbet/rbi/dsl/action_mailbox/ingresses/relay/inbound_emails_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::Ingresses::Relay::InboundEmailsController`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::Ingresses::Relay::InboundEmailsController`. - -class ActionMailbox::Ingresses::Relay::InboundEmailsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/ingresses/sendgrid/inbound_emails_controller.rbi b/sorbet/rbi/dsl/action_mailbox/ingresses/sendgrid/inbound_emails_controller.rbi deleted file mode 100644 index 3197a04da..000000000 --- a/sorbet/rbi/dsl/action_mailbox/ingresses/sendgrid/inbound_emails_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::Ingresses::Sendgrid::InboundEmailsController`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::Ingresses::Sendgrid::InboundEmailsController`. - -class ActionMailbox::Ingresses::Sendgrid::InboundEmailsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/action_mailbox/routing_job.rbi b/sorbet/rbi/dsl/action_mailbox/routing_job.rbi deleted file mode 100644 index 7b3e4f30c..000000000 --- a/sorbet/rbi/dsl/action_mailbox/routing_job.rbi +++ /dev/null @@ -1,15 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActionMailbox::RoutingJob`. -# Please instead update this file by running `bin/tapioca dsl ActionMailbox::RoutingJob`. - -class ActionMailbox::RoutingJob - class << self - sig { params(inbound_email: T.untyped).returns(T.any(ActionMailbox::RoutingJob, FalseClass)) } - def perform_later(inbound_email); end - - sig { params(inbound_email: T.untyped).returns(T.untyped) } - def perform_now(inbound_email); end - end -end diff --git a/sorbet/rbi/dsl/action_mailer/callbacks.rbi b/sorbet/rbi/dsl/action_mailer/callbacks.rbi new file mode 100644 index 000000000..db0d35054 --- /dev/null +++ b/sorbet/rbi/dsl/action_mailer/callbacks.rbi @@ -0,0 +1,23 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActionMailer::Callbacks`. +# Please instead update this file by running `bin/tapioca dsl ActionMailer::Callbacks`. + + +module ActionMailer::Callbacks + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def __callbacks; end + def __callbacks=(value); end + def __callbacks?; end + end + + module GeneratedInstanceMethods + def __callbacks; end + def __callbacks?; end + end +end diff --git a/sorbet/rbi/dsl/action_mailer/delivery_methods.rbi b/sorbet/rbi/dsl/action_mailer/delivery_methods.rbi index 0b1965137..a4d7c6c0b 100644 --- a/sorbet/rbi/dsl/action_mailer/delivery_methods.rbi +++ b/sorbet/rbi/dsl/action_mailer/delivery_methods.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionMailer::DeliveryMethods`. # Please instead update this file by running `bin/tapioca dsl ActionMailer::DeliveryMethods`. + module ActionMailer::DeliveryMethods include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_mailer/form_builder.rbi b/sorbet/rbi/dsl/action_mailer/form_builder.rbi new file mode 100644 index 000000000..ca921d316 --- /dev/null +++ b/sorbet/rbi/dsl/action_mailer/form_builder.rbi @@ -0,0 +1,20 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActionMailer::FormBuilder`. +# Please instead update this file by running `bin/tapioca dsl ActionMailer::FormBuilder`. + + +module ActionMailer::FormBuilder + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def _default_form_builder; end + def _default_form_builder=(value); end + def _default_form_builder?; end + end + + module GeneratedInstanceMethods; end +end diff --git a/sorbet/rbi/dsl/action_mailer/mail_delivery_job.rbi b/sorbet/rbi/dsl/action_mailer/mail_delivery_job.rbi index 48b9d856b..ef86f9058 100644 --- a/sorbet/rbi/dsl/action_mailer/mail_delivery_job.rbi +++ b/sorbet/rbi/dsl/action_mailer/mail_delivery_job.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionMailer::MailDeliveryJob`. # Please instead update this file by running `bin/tapioca dsl ActionMailer::MailDeliveryJob`. + class ActionMailer::MailDeliveryJob class << self sig do @@ -13,10 +14,11 @@ class ActionMailer::MailDeliveryJob delivery_method: T.untyped, args: T.untyped, kwargs: T.untyped, - params: T.untyped + params: T.untyped, + block: T.nilable(T.proc.params(job: ActionMailer::MailDeliveryJob).void) ).returns(T.any(ActionMailer::MailDeliveryJob, FalseClass)) end - def perform_later(mailer, mail_method, delivery_method, args:, kwargs: T.unsafe(nil), params: T.unsafe(nil)); end + def perform_later(mailer, mail_method, delivery_method, args:, kwargs: T.unsafe(nil), params: T.unsafe(nil), &block); end sig do params( diff --git a/sorbet/rbi/dsl/action_mailer/queued_delivery.rbi b/sorbet/rbi/dsl/action_mailer/queued_delivery.rbi new file mode 100644 index 000000000..a5101467b --- /dev/null +++ b/sorbet/rbi/dsl/action_mailer/queued_delivery.rbi @@ -0,0 +1,30 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActionMailer::QueuedDelivery`. +# Please instead update this file by running `bin/tapioca dsl ActionMailer::QueuedDelivery`. + + +module ActionMailer::QueuedDelivery + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def deliver_later_queue_name; end + def deliver_later_queue_name=(value); end + def deliver_later_queue_name?; end + def delivery_job; end + def delivery_job=(value); end + def delivery_job?; end + end + + module GeneratedInstanceMethods + def deliver_later_queue_name; end + def deliver_later_queue_name=(value); end + def deliver_later_queue_name?; end + def delivery_job; end + def delivery_job=(value); end + def delivery_job?; end + end +end diff --git a/sorbet/rbi/dsl/action_mailer/rescuable.rbi b/sorbet/rbi/dsl/action_mailer/rescuable.rbi index 25cb25ca1..5bd7ad4a6 100644 --- a/sorbet/rbi/dsl/action_mailer/rescuable.rbi +++ b/sorbet/rbi/dsl/action_mailer/rescuable.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionMailer::Rescuable`. # Please instead update this file by running `bin/tapioca dsl ActionMailer::Rescuable`. + module ActionMailer::Rescuable include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_mailer/test_case/behavior.rbi b/sorbet/rbi/dsl/action_mailer/test_case/behavior.rbi index a545590cf..cab5a0491 100644 --- a/sorbet/rbi/dsl/action_mailer/test_case/behavior.rbi +++ b/sorbet/rbi/dsl/action_mailer/test_case/behavior.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionMailer::TestCase::Behavior`. # Please instead update this file by running `bin/tapioca dsl ActionMailer::TestCase::Behavior`. + module ActionMailer::TestCase::Behavior include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/action_text/encrypted_rich_text.rbi b/sorbet/rbi/dsl/action_text/encrypted_rich_text.rbi index 303d15ab9..c5853f1fa 100644 --- a/sorbet/rbi/dsl/action_text/encrypted_rich_text.rbi +++ b/sorbet/rbi/dsl/action_text/encrypted_rich_text.rbi @@ -4,8 +4,10 @@ # This is an autogenerated file for dynamic methods in `ActionText::EncryptedRichText`. # Please instead update this file by running `bin/tapioca dsl ActionText::EncryptedRichText`. + class ActionText::EncryptedRichText include GeneratedAssociationMethods + include GeneratedAttributeMethods extend CommonRelationMethods extend GeneratedRelationMethods @@ -28,9 +30,20 @@ class ActionText::EncryptedRichText end def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(::ActionText::EncryptedRichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -39,12 +52,29 @@ class ActionText::EncryptedRichText end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig do + params( + column_name: NilClass, + block: T.proc.params(object: ::ActionText::EncryptedRichText).void + ).returns(Integer) + end + def count(column_name = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(::ActionText::EncryptedRichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -53,6 +83,17 @@ class ActionText::EncryptedRichText end def create(attributes = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(::ActionText::EncryptedRichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -61,6 +102,12 @@ class ActionText::EncryptedRichText end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -69,6 +116,12 @@ class ActionText::EncryptedRichText end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -89,8 +142,23 @@ class ActionText::EncryptedRichText sig { returns(::ActionText::EncryptedRichText) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ActionText::EncryptedRichText) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ActionText::EncryptedRichText]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ActionText::EncryptedRichText).void + ).returns(T.nilable(::ActionText::EncryptedRichText)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ActionText::EncryptedRichText)) } def find_by(*args); end @@ -98,6 +166,54 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped).returns(::ActionText::EncryptedRichText) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ActionText::EncryptedRichText).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ActionText::EncryptedRichText]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ActionText::EncryptedRichText]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ActionText::EncryptedRichText]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -106,6 +222,12 @@ class ActionText::EncryptedRichText end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -114,6 +236,12 @@ class ActionText::EncryptedRichText end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -131,7 +259,8 @@ class ActionText::EncryptedRichText sig { params(arg: T.untyped, args: T.untyped).returns(::ActionText::EncryptedRichText) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActionText::EncryptedRichText)) } + sig { params(limit: Integer).returns(T::Array[::ActionText::EncryptedRichText]) } def first(limit = nil); end sig { returns(::ActionText::EncryptedRichText) } @@ -152,10 +281,36 @@ class ActionText::EncryptedRichText sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActionText::EncryptedRichText)) } + sig { params(limit: Integer).returns(T::Array[::ActionText::EncryptedRichText]) } def last(limit = nil); end sig { returns(::ActionText::EncryptedRichText) } @@ -177,6 +332,17 @@ class ActionText::EncryptedRichText sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(::ActionText::EncryptedRichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::EncryptedRichText).void) + ).returns(T::Array[::ActionText::EncryptedRichText]) + end sig do params( attributes: T.untyped, @@ -220,15 +386,18 @@ class ActionText::EncryptedRichText sig { returns(::ActionText::EncryptedRichText) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ActionText::EncryptedRichText).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActionText::EncryptedRichText)) } + sig { params(limit: Integer).returns(T::Array[::ActionText::EncryptedRichText]) } def take(limit = nil); end sig { returns(::ActionText::EncryptedRichText) } @@ -256,10 +425,10 @@ class ActionText::EncryptedRichText # This method is created by ActiveRecord on the `ActionText::RichText` class because it declared `has_many :embeds_attachments`. # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(ActiveRecord::Associations::CollectionProxy) } + sig { returns(::ActiveStorage::Attachment::PrivateCollectionProxy) } def embeds_attachments; end - sig { params(value: T::Enumerable[T.untyped]).void } + sig { params(value: T::Enumerable[::ActiveStorage::Attachment]).void } def embeds_attachments=(value); end sig { returns(T::Array[T.untyped]) } @@ -270,10 +439,10 @@ class ActionText::EncryptedRichText # This method is created by ActiveRecord on the `ActionText::RichText` class because it declared `has_many :embeds_blobs, through: :embeds_attachments`. # 🔗 [Rails guide for `has_many_through` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-through-association) - sig { returns(ActiveRecord::Associations::CollectionProxy) } + sig { returns(::ActiveStorage::Blob::PrivateCollectionProxy) } def embeds_blobs; end - sig { params(value: T::Enumerable[T.untyped]).void } + sig { params(value: T::Enumerable[::ActiveStorage::Blob]).void } def embeds_blobs=(value); end sig { returns(T.untyped) } @@ -284,6 +453,9 @@ class ActionText::EncryptedRichText sig { returns(T.untyped) } def reload_record; end + + sig { void } + def reset_record; end end module GeneratedAssociationRelationMethods @@ -299,8 +471,8 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -314,13 +486,13 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -332,40 +504,6 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -390,6 +528,9 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -414,6 +555,9 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -441,34 +585,480 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def with_attached_embeds(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end + module GeneratedAttributeMethods + sig { returns(T.nilable(::String)) } + def body; end + + sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } + def body=(value); end + + sig { returns(T::Boolean) } + def body?; end + + sig { returns(T.nilable(::String)) } + def body_before_last_save; end + + sig { returns(T.untyped) } + def body_before_type_cast; end + + sig { returns(T::Boolean) } + def body_came_from_user?; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def body_change; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def body_change_to_be_saved; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def body_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def body_in_database; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def body_previous_change; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def body_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def body_previously_was; end + + sig { returns(T.nilable(::String)) } + def body_was; end + + sig { void } + def body_will_change!; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def created_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def created_at=(value); end + + sig { returns(T::Boolean) } + def created_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_before_last_save; end + + sig { returns(T.untyped) } + def created_at_before_type_cast; end + + sig { returns(T::Boolean) } + def created_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_was; end + + sig { void } + def created_at_will_change!; end + + sig { returns(::Integer) } + def id; end + + sig { params(value: ::Integer).returns(::Integer) } + def id=(value); end + + sig { returns(T::Boolean) } + def id?; end + + sig { returns(T.nilable(::Integer)) } + def id_before_last_save; end + + sig { returns(T.untyped) } + def id_before_type_cast; end + + sig { returns(T::Boolean) } + def id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_previously_was; end + + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def id_was; end + + sig { void } + def id_will_change!; end + + sig { returns(::String) } + def name; end + + sig { params(value: ::String).returns(::String) } + def name=(value); end + + sig { returns(T::Boolean) } + def name?; end + + sig { returns(T.nilable(::String)) } + def name_before_last_save; end + + sig { returns(T.untyped) } + def name_before_type_cast; end + + sig { returns(T::Boolean) } + def name_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def name_change; end + + sig { returns(T.nilable([::String, ::String])) } + def name_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def name_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def name_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def name_previously_was; end + + sig { returns(T.nilable(::String)) } + def name_was; end + + sig { void } + def name_will_change!; end + + sig { returns(::Integer) } + def record_id; end + + sig { params(value: ::Integer).returns(::Integer) } + def record_id=(value); end + + sig { returns(T::Boolean) } + def record_id?; end + + sig { returns(T.nilable(::Integer)) } + def record_id_before_last_save; end + + sig { returns(T.untyped) } + def record_id_before_type_cast; end + + sig { returns(T::Boolean) } + def record_id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def record_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def record_id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def record_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def record_id_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def record_id_was; end + + sig { void } + def record_id_will_change!; end + + sig { returns(::String) } + def record_type; end + + sig { params(value: ::String).returns(::String) } + def record_type=(value); end + + sig { returns(T::Boolean) } + def record_type?; end + + sig { returns(T.nilable(::String)) } + def record_type_before_last_save; end + + sig { returns(T.untyped) } + def record_type_before_type_cast; end + + sig { returns(T::Boolean) } + def record_type_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_change; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def record_type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def record_type_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def record_type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def record_type_previously_was; end + + sig { returns(T.nilable(::String)) } + def record_type_was; end + + sig { void } + def record_type_will_change!; end + + sig { void } + def restore_body!; end + + sig { void } + def restore_created_at!; end + + sig { void } + def restore_id!; end + + sig { void } + def restore_id_value!; end + + sig { void } + def restore_name!; end + + sig { void } + def restore_record_id!; end + + sig { void } + def restore_record_type!; end + + sig { void } + def restore_updated_at!; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def saved_change_to_body; end + + sig { returns(T::Boolean) } + def saved_change_to_body?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_created_at; end + + sig { returns(T::Boolean) } + def saved_change_to_created_at?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id; end + + sig { returns(T::Boolean) } + def saved_change_to_id?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_name; end + + sig { returns(T::Boolean) } + def saved_change_to_name?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_record_id; end + + sig { returns(T::Boolean) } + def saved_change_to_record_id?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_record_type; end + + sig { returns(T::Boolean) } + def saved_change_to_record_type?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_updated_at; end + + sig { returns(T::Boolean) } + def saved_change_to_updated_at?; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def updated_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def updated_at=(value); end + + sig { returns(T::Boolean) } + def updated_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_before_last_save; end + + sig { returns(T.untyped) } + def updated_at_before_type_cast; end + + sig { returns(T::Boolean) } + def updated_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_was; end + + sig { void } + def updated_at_will_change!; end + + sig { returns(T::Boolean) } + def will_save_change_to_body?; end + + sig { returns(T::Boolean) } + def will_save_change_to_created_at?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + + sig { returns(T::Boolean) } + def will_save_change_to_name?; end + + sig { returns(T::Boolean) } + def will_save_change_to_record_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_record_type?; end + + sig { returns(T::Boolean) } + def will_save_change_to_updated_at?; end + end + module GeneratedRelationMethods sig { returns(PrivateRelation) } def all; end @@ -482,8 +1072,8 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -497,13 +1087,13 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -539,6 +1129,9 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -563,6 +1156,9 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -593,9 +1189,15 @@ class ActionText::EncryptedRichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def with_attached_embeds(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -606,10 +1208,48 @@ class ActionText::EncryptedRichText Elem = type_member { { fixed: ::ActionText::EncryptedRichText } } + sig { returns(T::Array[::ActionText::EncryptedRichText]) } + def to_a; end + sig { returns(T::Array[::ActionText::EncryptedRichText]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ActionText::EncryptedRichText } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ActionText::EncryptedRichText } } @@ -653,20 +1293,6 @@ class ActionText::EncryptedRichText end def concat(*records); end - sig do - params( - records: T.any(::ActionText::EncryptedRichText, Integer, String, T::Enumerable[T.any(::ActionText::EncryptedRichText, Integer, String, T::Enumerable[::ActionText::EncryptedRichText])]) - ).returns(T::Array[::ActionText::EncryptedRichText]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActionText::EncryptedRichText, Integer, String, T::Enumerable[T.any(::ActionText::EncryptedRichText, Integer, String, T::Enumerable[::ActionText::EncryptedRichText])]) - ).returns(T::Array[::ActionText::EncryptedRichText]) - end - def destroy(*records); end - sig { returns(T::Array[::ActionText::EncryptedRichText]) } def load_target; end @@ -697,6 +1323,9 @@ class ActionText::EncryptedRichText sig { returns(T::Array[::ActionText::EncryptedRichText]) } def target; end + sig { returns(T::Array[::ActionText::EncryptedRichText]) } + def to_a; end + sig { returns(T::Array[::ActionText::EncryptedRichText]) } def to_ary; end end @@ -707,10 +1336,48 @@ class ActionText::EncryptedRichText Elem = type_member { { fixed: ::ActionText::EncryptedRichText } } + sig { returns(T::Array[::ActionText::EncryptedRichText]) } + def to_a; end + sig { returns(T::Array[::ActionText::EncryptedRichText]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ActionText::EncryptedRichText } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ActionText::EncryptedRichText } } diff --git a/sorbet/rbi/dsl/action_text/rich_text.rbi b/sorbet/rbi/dsl/action_text/rich_text.rbi index 0f7e01ac5..85b553bc2 100644 --- a/sorbet/rbi/dsl/action_text/rich_text.rbi +++ b/sorbet/rbi/dsl/action_text/rich_text.rbi @@ -4,8 +4,10 @@ # This is an autogenerated file for dynamic methods in `ActionText::RichText`. # Please instead update this file by running `bin/tapioca dsl ActionText::RichText`. + class ActionText::RichText include GeneratedAssociationMethods + include GeneratedAttributeMethods extend CommonRelationMethods extend GeneratedRelationMethods @@ -28,9 +30,20 @@ class ActionText::RichText end def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(::ActionText::RichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -39,12 +52,24 @@ class ActionText::RichText end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ActionText::RichText).void).returns(Integer) } + def count(column_name = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(::ActionText::RichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -53,6 +78,17 @@ class ActionText::RichText end def create(attributes = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(::ActionText::RichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -61,6 +97,12 @@ class ActionText::RichText end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -69,6 +111,12 @@ class ActionText::RichText end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -89,8 +137,23 @@ class ActionText::RichText sig { returns(::ActionText::RichText) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ActionText::RichText) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ActionText::RichText]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ActionText::RichText).void + ).returns(T.nilable(::ActionText::RichText)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ActionText::RichText)) } def find_by(*args); end @@ -98,6 +161,54 @@ class ActionText::RichText sig { params(args: T.untyped).returns(::ActionText::RichText) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ActionText::RichText).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ActionText::RichText]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ActionText::RichText]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ActionText::RichText]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -106,6 +217,12 @@ class ActionText::RichText end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -114,6 +231,12 @@ class ActionText::RichText end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -131,7 +254,8 @@ class ActionText::RichText sig { params(arg: T.untyped, args: T.untyped).returns(::ActionText::RichText) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActionText::RichText)) } + sig { params(limit: Integer).returns(T::Array[::ActionText::RichText]) } def first(limit = nil); end sig { returns(::ActionText::RichText) } @@ -152,10 +276,36 @@ class ActionText::RichText sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActionText::RichText)) } + sig { params(limit: Integer).returns(T::Array[::ActionText::RichText]) } def last(limit = nil); end sig { returns(::ActionText::RichText) } @@ -177,6 +327,17 @@ class ActionText::RichText sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(::ActionText::RichText) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActionText::RichText).void) + ).returns(T::Array[::ActionText::RichText]) + end sig do params( attributes: T.untyped, @@ -220,15 +381,18 @@ class ActionText::RichText sig { returns(::ActionText::RichText) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ActionText::RichText).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActionText::RichText)) } + sig { params(limit: Integer).returns(T::Array[::ActionText::RichText]) } def take(limit = nil); end sig { returns(::ActionText::RichText) } @@ -256,10 +420,10 @@ class ActionText::RichText # This method is created by ActiveRecord on the `ActionText::RichText` class because it declared `has_many :embeds_attachments`. # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(ActiveRecord::Associations::CollectionProxy) } + sig { returns(::ActiveStorage::Attachment::PrivateCollectionProxy) } def embeds_attachments; end - sig { params(value: T::Enumerable[T.untyped]).void } + sig { params(value: T::Enumerable[::ActiveStorage::Attachment]).void } def embeds_attachments=(value); end sig { returns(T::Array[T.untyped]) } @@ -270,10 +434,10 @@ class ActionText::RichText # This method is created by ActiveRecord on the `ActionText::RichText` class because it declared `has_many :embeds_blobs, through: :embeds_attachments`. # 🔗 [Rails guide for `has_many_through` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-through-association) - sig { returns(ActiveRecord::Associations::CollectionProxy) } + sig { returns(::ActiveStorage::Blob::PrivateCollectionProxy) } def embeds_blobs; end - sig { params(value: T::Enumerable[T.untyped]).void } + sig { params(value: T::Enumerable[::ActiveStorage::Blob]).void } def embeds_blobs=(value); end sig { returns(T.untyped) } @@ -282,8 +446,17 @@ class ActionText::RichText sig { params(value: T.untyped).void } def record=(value); end + sig { returns(T::Boolean) } + def record_changed?; end + + sig { returns(T::Boolean) } + def record_previously_changed?; end + sig { returns(T.untyped) } def reload_record; end + + sig { void } + def reset_record; end end module GeneratedAssociationRelationMethods @@ -299,8 +472,8 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -314,13 +487,13 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -332,40 +505,6 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -390,6 +529,9 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -414,6 +556,9 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -441,34 +586,480 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def with_attached_embeds(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end + module GeneratedAttributeMethods + sig { returns(T.untyped) } + def body; end + + sig { params(value: T.untyped).returns(T.untyped) } + def body=(value); end + + sig { returns(T::Boolean) } + def body?; end + + sig { returns(T.untyped) } + def body_before_last_save; end + + sig { returns(T.untyped) } + def body_before_type_cast; end + + sig { returns(T::Boolean) } + def body_came_from_user?; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def body_change; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def body_change_to_be_saved; end + + sig { params(from: T.untyped, to: T.untyped).returns(T::Boolean) } + def body_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.untyped) } + def body_in_database; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def body_previous_change; end + + sig { params(from: T.untyped, to: T.untyped).returns(T::Boolean) } + def body_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.untyped) } + def body_previously_was; end + + sig { returns(T.untyped) } + def body_was; end + + sig { void } + def body_will_change!; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def created_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def created_at=(value); end + + sig { returns(T::Boolean) } + def created_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_before_last_save; end + + sig { returns(T.untyped) } + def created_at_before_type_cast; end + + sig { returns(T::Boolean) } + def created_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_was; end + + sig { void } + def created_at_will_change!; end + + sig { returns(::Integer) } + def id; end + + sig { params(value: ::Integer).returns(::Integer) } + def id=(value); end + + sig { returns(T::Boolean) } + def id?; end + + sig { returns(T.nilable(::Integer)) } + def id_before_last_save; end + + sig { returns(T.untyped) } + def id_before_type_cast; end + + sig { returns(T::Boolean) } + def id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_previously_was; end + + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def id_was; end + + sig { void } + def id_will_change!; end + + sig { returns(::String) } + def name; end + + sig { params(value: ::String).returns(::String) } + def name=(value); end + + sig { returns(T::Boolean) } + def name?; end + + sig { returns(T.nilable(::String)) } + def name_before_last_save; end + + sig { returns(T.untyped) } + def name_before_type_cast; end + + sig { returns(T::Boolean) } + def name_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def name_change; end + + sig { returns(T.nilable([::String, ::String])) } + def name_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def name_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def name_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def name_previously_was; end + + sig { returns(T.nilable(::String)) } + def name_was; end + + sig { void } + def name_will_change!; end + + sig { returns(::Integer) } + def record_id; end + + sig { params(value: ::Integer).returns(::Integer) } + def record_id=(value); end + + sig { returns(T::Boolean) } + def record_id?; end + + sig { returns(T.nilable(::Integer)) } + def record_id_before_last_save; end + + sig { returns(T.untyped) } + def record_id_before_type_cast; end + + sig { returns(T::Boolean) } + def record_id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def record_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def record_id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def record_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def record_id_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def record_id_was; end + + sig { void } + def record_id_will_change!; end + + sig { returns(::String) } + def record_type; end + + sig { params(value: ::String).returns(::String) } + def record_type=(value); end + + sig { returns(T::Boolean) } + def record_type?; end + + sig { returns(T.nilable(::String)) } + def record_type_before_last_save; end + + sig { returns(T.untyped) } + def record_type_before_type_cast; end + + sig { returns(T::Boolean) } + def record_type_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_change; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def record_type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def record_type_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def record_type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def record_type_previously_was; end + + sig { returns(T.nilable(::String)) } + def record_type_was; end + + sig { void } + def record_type_will_change!; end + + sig { void } + def restore_body!; end + + sig { void } + def restore_created_at!; end + + sig { void } + def restore_id!; end + + sig { void } + def restore_id_value!; end + + sig { void } + def restore_name!; end + + sig { void } + def restore_record_id!; end + + sig { void } + def restore_record_type!; end + + sig { void } + def restore_updated_at!; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def saved_change_to_body; end + + sig { returns(T::Boolean) } + def saved_change_to_body?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_created_at; end + + sig { returns(T::Boolean) } + def saved_change_to_created_at?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id; end + + sig { returns(T::Boolean) } + def saved_change_to_id?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_name; end + + sig { returns(T::Boolean) } + def saved_change_to_name?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_record_id; end + + sig { returns(T::Boolean) } + def saved_change_to_record_id?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_record_type; end + + sig { returns(T::Boolean) } + def saved_change_to_record_type?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_updated_at; end + + sig { returns(T::Boolean) } + def saved_change_to_updated_at?; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def updated_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def updated_at=(value); end + + sig { returns(T::Boolean) } + def updated_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_before_last_save; end + + sig { returns(T.untyped) } + def updated_at_before_type_cast; end + + sig { returns(T::Boolean) } + def updated_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_was; end + + sig { void } + def updated_at_will_change!; end + + sig { returns(T::Boolean) } + def will_save_change_to_body?; end + + sig { returns(T::Boolean) } + def will_save_change_to_created_at?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + + sig { returns(T::Boolean) } + def will_save_change_to_name?; end + + sig { returns(T::Boolean) } + def will_save_change_to_record_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_record_type?; end + + sig { returns(T::Boolean) } + def will_save_change_to_updated_at?; end + end + module GeneratedRelationMethods sig { returns(PrivateRelation) } def all; end @@ -482,8 +1073,8 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -497,13 +1088,13 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -539,6 +1130,9 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -563,6 +1157,9 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -593,9 +1190,15 @@ class ActionText::RichText sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def with_attached_embeds(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -606,10 +1209,48 @@ class ActionText::RichText Elem = type_member { { fixed: ::ActionText::RichText } } + sig { returns(T::Array[::ActionText::RichText]) } + def to_a; end + sig { returns(T::Array[::ActionText::RichText]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ActionText::RichText } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ActionText::RichText } } @@ -653,20 +1294,6 @@ class ActionText::RichText end def concat(*records); end - sig do - params( - records: T.any(::ActionText::RichText, Integer, String, T::Enumerable[T.any(::ActionText::RichText, Integer, String, T::Enumerable[::ActionText::RichText])]) - ).returns(T::Array[::ActionText::RichText]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActionText::RichText, Integer, String, T::Enumerable[T.any(::ActionText::RichText, Integer, String, T::Enumerable[::ActionText::RichText])]) - ).returns(T::Array[::ActionText::RichText]) - end - def destroy(*records); end - sig { returns(T::Array[::ActionText::RichText]) } def load_target; end @@ -697,6 +1324,9 @@ class ActionText::RichText sig { returns(T::Array[::ActionText::RichText]) } def target; end + sig { returns(T::Array[::ActionText::RichText]) } + def to_a; end + sig { returns(T::Array[::ActionText::RichText]) } def to_ary; end end @@ -707,10 +1337,48 @@ class ActionText::RichText Elem = type_member { { fixed: ::ActionText::RichText } } + sig { returns(T::Array[::ActionText::RichText]) } + def to_a; end + sig { returns(T::Array[::ActionText::RichText]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ActionText::RichText } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ActionText::RichText } } diff --git a/sorbet/rbi/dsl/action_view/helpers.rbi b/sorbet/rbi/dsl/action_view/helpers.rbi index 8c13c0165..efa2fd86f 100644 --- a/sorbet/rbi/dsl/action_view/helpers.rbi +++ b/sorbet/rbi/dsl/action_view/helpers.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionView::Helpers`. # Please instead update this file by running `bin/tapioca dsl ActionView::Helpers`. + module ActionView::Helpers include GeneratedUrlHelpersModule include GeneratedPathHelpersModule diff --git a/sorbet/rbi/dsl/action_view/helpers/form_helper.rbi b/sorbet/rbi/dsl/action_view/helpers/form_helper.rbi index 53e7bf94d..10a330a0a 100644 --- a/sorbet/rbi/dsl/action_view/helpers/form_helper.rbi +++ b/sorbet/rbi/dsl/action_view/helpers/form_helper.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionView::Helpers::FormHelper`. # Please instead update this file by running `bin/tapioca dsl ActionView::Helpers::FormHelper`. + module ActionView::Helpers::FormHelper mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods diff --git a/sorbet/rbi/dsl/action_view/helpers/form_tag_helper.rbi b/sorbet/rbi/dsl/action_view/helpers/form_tag_helper.rbi index 5ed609a33..ca1d562d2 100644 --- a/sorbet/rbi/dsl/action_view/helpers/form_tag_helper.rbi +++ b/sorbet/rbi/dsl/action_view/helpers/form_tag_helper.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionView::Helpers::FormTagHelper`. # Please instead update this file by running `bin/tapioca dsl ActionView::Helpers::FormTagHelper`. + module ActionView::Helpers::FormTagHelper mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods diff --git a/sorbet/rbi/dsl/action_view/helpers/text_helper.rbi b/sorbet/rbi/dsl/action_view/helpers/text_helper.rbi index a1b29002a..733cb5f4f 100644 --- a/sorbet/rbi/dsl/action_view/helpers/text_helper.rbi +++ b/sorbet/rbi/dsl/action_view/helpers/text_helper.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionView::Helpers::TextHelper`. # Please instead update this file by running `bin/tapioca dsl ActionView::Helpers::TextHelper`. + module ActionView::Helpers::TextHelper mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods end diff --git a/sorbet/rbi/dsl/action_view/layouts.rbi b/sorbet/rbi/dsl/action_view/layouts.rbi index fc9f9d044..4f1bd8eb9 100644 --- a/sorbet/rbi/dsl/action_view/layouts.rbi +++ b/sorbet/rbi/dsl/action_view/layouts.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionView::Layouts`. # Please instead update this file by running `bin/tapioca dsl ActionView::Layouts`. + module ActionView::Layouts include GeneratedInstanceMethods @@ -20,5 +21,8 @@ module ActionView::Layouts def _layout_conditions?; end end - module GeneratedInstanceMethods; end + module GeneratedInstanceMethods + def _layout_conditions; end + def _layout_conditions?; end + end end diff --git a/sorbet/rbi/dsl/action_view/rendering.rbi b/sorbet/rbi/dsl/action_view/rendering.rbi index 96825dd54..52ac48949 100644 --- a/sorbet/rbi/dsl/action_view/rendering.rbi +++ b/sorbet/rbi/dsl/action_view/rendering.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActionView::Rendering`. # Please instead update this file by running `bin/tapioca dsl ActionView::Rendering`. + module ActionView::Rendering mixes_in_class_methods ::ActionView::ViewPaths::ClassMethods end diff --git a/sorbet/rbi/dsl/active_job/callbacks.rbi b/sorbet/rbi/dsl/active_job/callbacks.rbi index fcf2b5255..b780394a5 100644 --- a/sorbet/rbi/dsl/active_job/callbacks.rbi +++ b/sorbet/rbi/dsl/active_job/callbacks.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::Callbacks`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::Callbacks`. + module ActiveJob::Callbacks include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_job/enqueuing.rbi b/sorbet/rbi/dsl/active_job/enqueuing.rbi new file mode 100644 index 000000000..a55a52ea2 --- /dev/null +++ b/sorbet/rbi/dsl/active_job/enqueuing.rbi @@ -0,0 +1,19 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveJob::Enqueuing`. +# Please instead update this file by running `bin/tapioca dsl ActiveJob::Enqueuing`. + + +module ActiveJob::Enqueuing + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def enqueue_after_transaction_commit; end + def enqueue_after_transaction_commit=(value); end + end + + module GeneratedInstanceMethods; end +end diff --git a/sorbet/rbi/dsl/active_job/exceptions.rbi b/sorbet/rbi/dsl/active_job/exceptions.rbi index 1b49871aa..f1c1f6c40 100644 --- a/sorbet/rbi/dsl/active_job/exceptions.rbi +++ b/sorbet/rbi/dsl/active_job/exceptions.rbi @@ -4,15 +4,23 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::Exceptions`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::Exceptions`. + module ActiveJob::Exceptions include GeneratedInstanceMethods mixes_in_class_methods GeneratedClassMethods module GeneratedClassMethods + def after_discard_procs; end + def after_discard_procs=(value); end + def after_discard_procs?; end def retry_jitter; end def retry_jitter=(value); end end - module GeneratedInstanceMethods; end + module GeneratedInstanceMethods + def after_discard_procs; end + def after_discard_procs=(value); end + def after_discard_procs?; end + end end diff --git a/sorbet/rbi/dsl/active_job/execution.rbi b/sorbet/rbi/dsl/active_job/execution.rbi index 807d7091d..7fa4a61ef 100644 --- a/sorbet/rbi/dsl/active_job/execution.rbi +++ b/sorbet/rbi/dsl/active_job/execution.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::Execution`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::Execution`. + module ActiveJob::Execution include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_job/logging.rbi b/sorbet/rbi/dsl/active_job/logging.rbi index 6a19fdd0b..d3759116a 100644 --- a/sorbet/rbi/dsl/active_job/logging.rbi +++ b/sorbet/rbi/dsl/active_job/logging.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::Logging`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::Logging`. + module ActiveJob::Logging include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_job/queue_adapter.rbi b/sorbet/rbi/dsl/active_job/queue_adapter.rbi index 6d563d67f..7d7053a1c 100644 --- a/sorbet/rbi/dsl/active_job/queue_adapter.rbi +++ b/sorbet/rbi/dsl/active_job/queue_adapter.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::QueueAdapter`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::QueueAdapter`. + module ActiveJob::QueueAdapter include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_job/queue_name.rbi b/sorbet/rbi/dsl/active_job/queue_name.rbi index b10fb8ee6..e728614c0 100644 --- a/sorbet/rbi/dsl/active_job/queue_name.rbi +++ b/sorbet/rbi/dsl/active_job/queue_name.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::QueueName`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::QueueName`. + module ActiveJob::QueueName include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_job/queue_priority.rbi b/sorbet/rbi/dsl/active_job/queue_priority.rbi index a3e13cc40..ec03184cc 100644 --- a/sorbet/rbi/dsl/active_job/queue_priority.rbi +++ b/sorbet/rbi/dsl/active_job/queue_priority.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::QueuePriority`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::QueuePriority`. + module ActiveJob::QueuePriority include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_job/test_helper/test_queue_adapter.rbi b/sorbet/rbi/dsl/active_job/test_helper/test_queue_adapter.rbi index d76f319f5..8539af17e 100644 --- a/sorbet/rbi/dsl/active_job/test_helper/test_queue_adapter.rbi +++ b/sorbet/rbi/dsl/active_job/test_helper/test_queue_adapter.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveJob::TestHelper::TestQueueAdapter`. # Please instead update this file by running `bin/tapioca dsl ActiveJob::TestHelper::TestQueueAdapter`. + module ActiveJob::TestHelper::TestQueueAdapter include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_model/api.rbi b/sorbet/rbi/dsl/active_model/api.rbi index 40d1b14a0..a02d0e137 100644 --- a/sorbet/rbi/dsl/active_model/api.rbi +++ b/sorbet/rbi/dsl/active_model/api.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::API`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::API`. + module ActiveModel::API include GeneratedInstanceMethods @@ -18,6 +19,9 @@ module ActiveModel::API def _validators; end def _validators=(value); end def _validators?; end + def param_delimiter; end + def param_delimiter=(value); end + def param_delimiter?; end end module GeneratedInstanceMethods @@ -25,5 +29,6 @@ module ActiveModel::API def __callbacks?; end def _validators; end def _validators?; end + def param_delimiter=(value); end end end diff --git a/sorbet/rbi/dsl/active_model/attribute_methods.rbi b/sorbet/rbi/dsl/active_model/attribute_methods.rbi index 093f939f7..8e58d7b91 100644 --- a/sorbet/rbi/dsl/active_model/attribute_methods.rbi +++ b/sorbet/rbi/dsl/active_model/attribute_methods.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::AttributeMethods`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::AttributeMethods`. + module ActiveModel::AttributeMethods include GeneratedInstanceMethods @@ -13,15 +14,15 @@ module ActiveModel::AttributeMethods def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end end module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end end end diff --git a/sorbet/rbi/dsl/active_model/attributes.rbi b/sorbet/rbi/dsl/active_model/attributes.rbi index 86ace17d1..d300cb5f4 100644 --- a/sorbet/rbi/dsl/active_model/attributes.rbi +++ b/sorbet/rbi/dsl/active_model/attributes.rbi @@ -4,31 +4,27 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::Attributes`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::Attributes`. + module ActiveModel::Attributes include GeneratedInstanceMethods + mixes_in_class_methods ::ActiveModel::AttributeRegistration::ClassMethods mixes_in_class_methods ::ActiveModel::AttributeMethods::ClassMethods mixes_in_class_methods GeneratedClassMethods module GeneratedClassMethods - def _default_attributes; end - def _default_attributes=(value); end - def _default_attributes?; end def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end - def attribute_types; end - def attribute_types=(value); end - def attribute_types?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end end module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end end end diff --git a/sorbet/rbi/dsl/active_model/conversion.rbi b/sorbet/rbi/dsl/active_model/conversion.rbi new file mode 100644 index 000000000..9289cdd0f --- /dev/null +++ b/sorbet/rbi/dsl/active_model/conversion.rbi @@ -0,0 +1,22 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveModel::Conversion`. +# Please instead update this file by running `bin/tapioca dsl ActiveModel::Conversion`. + + +module ActiveModel::Conversion + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def param_delimiter; end + def param_delimiter=(value); end + def param_delimiter?; end + end + + module GeneratedInstanceMethods + def param_delimiter=(value); end + end +end diff --git a/sorbet/rbi/dsl/active_model/dirty.rbi b/sorbet/rbi/dsl/active_model/dirty.rbi index d8c8dcb1c..7eb00d3d0 100644 --- a/sorbet/rbi/dsl/active_model/dirty.rbi +++ b/sorbet/rbi/dsl/active_model/dirty.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::Dirty`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::Dirty`. + module ActiveModel::Dirty include GeneratedInstanceMethods @@ -14,15 +15,15 @@ module ActiveModel::Dirty def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end end module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end end end diff --git a/sorbet/rbi/dsl/active_model/model.rbi b/sorbet/rbi/dsl/active_model/model.rbi index fc405b2cb..c594ba3a1 100644 --- a/sorbet/rbi/dsl/active_model/model.rbi +++ b/sorbet/rbi/dsl/active_model/model.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::Model`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::Model`. + module ActiveModel::Model include GeneratedInstanceMethods @@ -18,6 +19,9 @@ module ActiveModel::Model def _validators; end def _validators=(value); end def _validators?; end + def param_delimiter; end + def param_delimiter=(value); end + def param_delimiter?; end end module GeneratedInstanceMethods @@ -25,5 +29,6 @@ module ActiveModel::Model def __callbacks?; end def _validators; end def _validators?; end + def param_delimiter=(value); end end end diff --git a/sorbet/rbi/dsl/active_model/serializers/json.rbi b/sorbet/rbi/dsl/active_model/serializers/json.rbi index bca80cf05..ab70ce933 100644 --- a/sorbet/rbi/dsl/active_model/serializers/json.rbi +++ b/sorbet/rbi/dsl/active_model/serializers/json.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::Serializers::JSON`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::Serializers::JSON`. + module ActiveModel::Serializers::JSON include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_model/validations.rbi b/sorbet/rbi/dsl/active_model/validations.rbi index af7112c27..5b129e015 100644 --- a/sorbet/rbi/dsl/active_model/validations.rbi +++ b/sorbet/rbi/dsl/active_model/validations.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::Validations`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::Validations`. + module ActiveModel::Validations include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_model/validations/callbacks.rbi b/sorbet/rbi/dsl/active_model/validations/callbacks.rbi index 4618b1ae6..7ca05416d 100644 --- a/sorbet/rbi/dsl/active_model/validations/callbacks.rbi +++ b/sorbet/rbi/dsl/active_model/validations/callbacks.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveModel::Validations::Callbacks`. # Please instead update this file by running `bin/tapioca dsl ActiveModel::Validations::Callbacks`. + module ActiveModel::Validations::Callbacks include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/attribute_methods.rbi b/sorbet/rbi/dsl/active_record/attribute_methods.rbi index af6eba2ac..d65dd4371 100644 --- a/sorbet/rbi/dsl/active_record/attribute_methods.rbi +++ b/sorbet/rbi/dsl/active_record/attribute_methods.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::AttributeMethods`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::AttributeMethods`. + module ActiveRecord::AttributeMethods include GeneratedInstanceMethods @@ -14,9 +15,12 @@ module ActiveRecord::AttributeMethods def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end + def default_column_serializer; end + def default_column_serializer=(value); end + def default_column_serializer?; end def partial_inserts; end def partial_inserts=(value); end def partial_inserts?; end @@ -37,8 +41,8 @@ module ActiveRecord::AttributeMethods module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end def partial_inserts; end def partial_inserts?; end def partial_updates; end diff --git a/sorbet/rbi/dsl/active_record/attribute_methods/dirty.rbi b/sorbet/rbi/dsl/active_record/attribute_methods/dirty.rbi index 4eaba8359..516acdb79 100644 --- a/sorbet/rbi/dsl/active_record/attribute_methods/dirty.rbi +++ b/sorbet/rbi/dsl/active_record/attribute_methods/dirty.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::AttributeMethods::Dirty`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::AttributeMethods::Dirty`. + module ActiveRecord::AttributeMethods::Dirty include GeneratedInstanceMethods @@ -14,9 +15,9 @@ module ActiveRecord::AttributeMethods::Dirty def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end def partial_inserts; end def partial_inserts=(value); end def partial_inserts?; end @@ -28,8 +29,8 @@ module ActiveRecord::AttributeMethods::Dirty module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end def partial_inserts; end def partial_inserts?; end def partial_updates; end diff --git a/sorbet/rbi/dsl/active_record/attribute_methods/serialization.rbi b/sorbet/rbi/dsl/active_record/attribute_methods/serialization.rbi new file mode 100644 index 000000000..9d06e2766 --- /dev/null +++ b/sorbet/rbi/dsl/active_record/attribute_methods/serialization.rbi @@ -0,0 +1,20 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveRecord::AttributeMethods::Serialization`. +# Please instead update this file by running `bin/tapioca dsl ActiveRecord::AttributeMethods::Serialization`. + + +module ActiveRecord::AttributeMethods::Serialization + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def default_column_serializer; end + def default_column_serializer=(value); end + def default_column_serializer?; end + end + + module GeneratedInstanceMethods; end +end diff --git a/sorbet/rbi/dsl/active_record/attribute_methods/time_zone_conversion.rbi b/sorbet/rbi/dsl/active_record/attribute_methods/time_zone_conversion.rbi index 912853771..be40114db 100644 --- a/sorbet/rbi/dsl/active_record/attribute_methods/time_zone_conversion.rbi +++ b/sorbet/rbi/dsl/active_record/attribute_methods/time_zone_conversion.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::AttributeMethods::TimeZoneConversion`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::AttributeMethods::TimeZoneConversion`. + module ActiveRecord::AttributeMethods::TimeZoneConversion include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/attributes.rbi b/sorbet/rbi/dsl/active_record/attributes.rbi index e81f17235..75bcc1a44 100644 --- a/sorbet/rbi/dsl/active_record/attributes.rbi +++ b/sorbet/rbi/dsl/active_record/attributes.rbi @@ -4,16 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Attributes`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Attributes`. -module ActiveRecord::Attributes - include GeneratedInstanceMethods - - mixes_in_class_methods GeneratedClassMethods - module GeneratedClassMethods - def attributes_to_define_after_schema_loads; end - def attributes_to_define_after_schema_loads=(value); end - def attributes_to_define_after_schema_loads?; end - end - - module GeneratedInstanceMethods; end +module ActiveRecord::Attributes + mixes_in_class_methods ::ActiveModel::AttributeRegistration::ClassMethods end diff --git a/sorbet/rbi/dsl/active_record/callbacks.rbi b/sorbet/rbi/dsl/active_record/callbacks.rbi index 2efcc9dc2..5a31b22ce 100644 --- a/sorbet/rbi/dsl/active_record/callbacks.rbi +++ b/sorbet/rbi/dsl/active_record/callbacks.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Callbacks`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Callbacks`. + module ActiveRecord::Callbacks include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/core.rbi b/sorbet/rbi/dsl/active_record/core.rbi index cd1ffaf2d..1aec8930c 100644 --- a/sorbet/rbi/dsl/active_record/core.rbi +++ b/sorbet/rbi/dsl/active_record/core.rbi @@ -4,12 +4,19 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Core`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Core`. + module ActiveRecord::Core include GeneratedInstanceMethods mixes_in_class_methods GeneratedClassMethods module GeneratedClassMethods + def _destroy_association_async_job; end + def _destroy_association_async_job=(value); end + def _destroy_association_async_job?; end + def attributes_for_inspect; end + def attributes_for_inspect=(value); end + def attributes_for_inspect?; end def belongs_to_required_by_default; end def belongs_to_required_by_default=(value); end def belongs_to_required_by_default?; end @@ -22,8 +29,8 @@ module ActiveRecord::Core def default_shard; end def default_shard=(value); end def default_shard?; end - def destroy_association_async_job; end - def destroy_association_async_job=(value); end + def destroy_association_async_batch_size; end + def destroy_association_async_batch_size=(value); end def enumerate_columns_in_select_statements; end def enumerate_columns_in_select_statements=(value); end def enumerate_columns_in_select_statements?; end @@ -33,6 +40,9 @@ module ActiveRecord::Core def logger; end def logger=(value); end def logger?; end + def run_commit_callbacks_on_first_saved_instances_in_transaction; end + def run_commit_callbacks_on_first_saved_instances_in_transaction=(value); end + def run_commit_callbacks_on_first_saved_instances_in_transaction?; end def shard_selector; end def shard_selector=(value); end def shard_selector?; end @@ -48,7 +58,7 @@ module ActiveRecord::Core def default_role?; end def default_shard; end def default_shard?; end - def destroy_association_async_job; end + def destroy_association_async_batch_size; end def logger; end def logger?; end end diff --git a/sorbet/rbi/dsl/active_record/counter_cache.rbi b/sorbet/rbi/dsl/active_record/counter_cache.rbi new file mode 100644 index 000000000..9aff98ebf --- /dev/null +++ b/sorbet/rbi/dsl/active_record/counter_cache.rbi @@ -0,0 +1,26 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveRecord::CounterCache`. +# Please instead update this file by running `bin/tapioca dsl ActiveRecord::CounterCache`. + + +module ActiveRecord::CounterCache + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def _counter_cache_columns; end + def _counter_cache_columns=(value); end + def _counter_cache_columns?; end + def counter_cached_association_names; end + def counter_cached_association_names=(value); end + def counter_cached_association_names?; end + end + + module GeneratedInstanceMethods + def counter_cached_association_names; end + def counter_cached_association_names?; end + end +end diff --git a/sorbet/rbi/dsl/active_record/destroy_association_async_job.rbi b/sorbet/rbi/dsl/active_record/destroy_association_async_job.rbi deleted file mode 100644 index b47c87524..000000000 --- a/sorbet/rbi/dsl/active_record/destroy_association_async_job.rbi +++ /dev/null @@ -1,33 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveRecord::DestroyAssociationAsyncJob`. -# Please instead update this file by running `bin/tapioca dsl ActiveRecord::DestroyAssociationAsyncJob`. - -class ActiveRecord::DestroyAssociationAsyncJob - class << self - sig do - params( - owner_model_name: T.untyped, - owner_id: T.untyped, - association_class: T.untyped, - association_ids: T.untyped, - association_primary_key_column: T.untyped, - ensuring_owner_was_method: T.untyped - ).returns(T.any(ActiveRecord::DestroyAssociationAsyncJob, FalseClass)) - end - def perform_later(owner_model_name: T.unsafe(nil), owner_id: T.unsafe(nil), association_class: T.unsafe(nil), association_ids: T.unsafe(nil), association_primary_key_column: T.unsafe(nil), ensuring_owner_was_method: T.unsafe(nil)); end - - sig do - params( - owner_model_name: T.untyped, - owner_id: T.untyped, - association_class: T.untyped, - association_ids: T.untyped, - association_primary_key_column: T.untyped, - ensuring_owner_was_method: T.untyped - ).returns(T.untyped) - end - def perform_now(owner_model_name: T.unsafe(nil), owner_id: T.unsafe(nil), association_class: T.unsafe(nil), association_ids: T.unsafe(nil), association_primary_key_column: T.unsafe(nil), ensuring_owner_was_method: T.unsafe(nil)); end - end -end diff --git a/sorbet/rbi/dsl/active_record/encryption/encryptable_record.rbi b/sorbet/rbi/dsl/active_record/encryption/encryptable_record.rbi index c364de6de..73b5a4628 100644 --- a/sorbet/rbi/dsl/active_record/encryption/encryptable_record.rbi +++ b/sorbet/rbi/dsl/active_record/encryption/encryptable_record.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Encryption::EncryptableRecord`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Encryption::EncryptableRecord`. + module ActiveRecord::Encryption::EncryptableRecord include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/inheritance.rbi b/sorbet/rbi/dsl/active_record/inheritance.rbi index a132d62bb..53130bd50 100644 --- a/sorbet/rbi/dsl/active_record/inheritance.rbi +++ b/sorbet/rbi/dsl/active_record/inheritance.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Inheritance`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Inheritance`. + module ActiveRecord::Inheritance include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/integration.rbi b/sorbet/rbi/dsl/active_record/integration.rbi index 277bb35ff..6fc6d69eb 100644 --- a/sorbet/rbi/dsl/active_record/integration.rbi +++ b/sorbet/rbi/dsl/active_record/integration.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Integration`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Integration`. + module ActiveRecord::Integration include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/internal_metadata.rbi b/sorbet/rbi/dsl/active_record/internal_metadata.rbi deleted file mode 100644 index 40a144a24..000000000 --- a/sorbet/rbi/dsl/active_record/internal_metadata.rbi +++ /dev/null @@ -1,905 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveRecord::InternalMetadata`. -# Please instead update this file by running `bin/tapioca dsl ActiveRecord::InternalMetadata`. - -class ActiveRecord::InternalMetadata - include GeneratedAttributeMethods - extend CommonRelationMethods - extend GeneratedRelationMethods - - private - - sig { returns(NilClass) } - def to_ary; end - - module CommonRelationMethods - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::InternalMetadata).returns(T.untyped)) - ).returns(T::Boolean) - end - def any?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def average(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def build(attributes = nil, &block); end - - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } - def calculate(operation, column_name); end - - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def create(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def create!(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def create_or_find_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def create_or_find_by!(attributes, &block); end - - sig { returns(T::Array[::ActiveRecord::InternalMetadata]) } - def destroy_all; end - - sig { params(conditions: T.untyped).returns(T::Boolean) } - def exists?(conditions = :none); end - - sig { returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def fifth; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def fifth!; end - - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end - - sig { params(args: T.untyped).returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def find_by(*args); end - - sig { params(args: T.untyped).returns(::ActiveRecord::InternalMetadata) } - def find_by!(*args); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def find_or_create_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def find_or_create_by!(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def find_or_initialize_by(attributes, &block); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def find_signed(signed_id, purpose: nil); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(::ActiveRecord::InternalMetadata) } - def find_signed!(signed_id, purpose: nil); end - - sig { params(arg: T.untyped, args: T.untyped).returns(::ActiveRecord::InternalMetadata) } - def find_sole_by(arg, *args); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def first(limit = nil); end - - sig { returns(::ActiveRecord::InternalMetadata) } - def first!; end - - sig { returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def forty_two; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def forty_two!; end - - sig { returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def fourth; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def fourth!; end - - sig { returns(Array) } - def ids; end - - sig { params(record: T.untyped).returns(T::Boolean) } - def include?(record); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def last(limit = nil); end - - sig { returns(::ActiveRecord::InternalMetadata) } - def last!; end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::InternalMetadata).returns(T.untyped)) - ).returns(T::Boolean) - end - def many?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def maximum(column_name); end - - sig { params(record: T.untyped).returns(T::Boolean) } - def member?(record); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def minimum(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::InternalMetadata).void) - ).returns(::ActiveRecord::InternalMetadata) - end - def new(attributes = nil, &block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::InternalMetadata).returns(T.untyped)) - ).returns(T::Boolean) - end - def none?(&block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::InternalMetadata).returns(T.untyped)) - ).returns(T::Boolean) - end - def one?(&block); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pick(*column_names); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pluck(*column_names); end - - sig { returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def second; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def second!; end - - sig { returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def second_to_last; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def second_to_last!; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def sole; end - - sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) - end - def sum(column_name = nil, &block); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def take(limit = nil); end - - sig { returns(::ActiveRecord::InternalMetadata) } - def take!; end - - sig { returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def third; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def third!; end - - sig { returns(T.nilable(::ActiveRecord::InternalMetadata)) } - def third_to_last; end - - sig { returns(::ActiveRecord::InternalMetadata) } - def third_to_last!; end - end - - module GeneratedAssociationRelationMethods - sig { returns(PrivateAssociationRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def includes(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def unscope(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def without(*args, &blk); end - end - - module GeneratedAttributeMethods - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at; end - - sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } - def created_at=(value); end - - sig { returns(T::Boolean) } - def created_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_before_last_save; end - - sig { returns(T.untyped) } - def created_at_before_type_cast; end - - sig { returns(T::Boolean) } - def created_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def created_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_previous_change; end - - sig { returns(T::Boolean) } - def created_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_was; end - - sig { void } - def created_at_will_change!; end - - sig { returns(T.nilable(::String)) } - def key; end - - sig { params(value: ::String).returns(::String) } - def key=(value); end - - sig { returns(T::Boolean) } - def key?; end - - sig { returns(T.nilable(::String)) } - def key_before_last_save; end - - sig { returns(T.untyped) } - def key_before_type_cast; end - - sig { returns(T::Boolean) } - def key_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def key_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def key_change_to_be_saved; end - - sig { returns(T::Boolean) } - def key_changed?; end - - sig { returns(T.nilable(::String)) } - def key_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def key_previous_change; end - - sig { returns(T::Boolean) } - def key_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def key_previously_was; end - - sig { returns(T.nilable(::String)) } - def key_was; end - - sig { void } - def key_will_change!; end - - sig { void } - def restore_created_at!; end - - sig { void } - def restore_key!; end - - sig { void } - def restore_updated_at!; end - - sig { void } - def restore_value!; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_created_at; end - - sig { returns(T::Boolean) } - def saved_change_to_created_at?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_key; end - - sig { returns(T::Boolean) } - def saved_change_to_key?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_updated_at; end - - sig { returns(T::Boolean) } - def saved_change_to_updated_at?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_value; end - - sig { returns(T::Boolean) } - def saved_change_to_value?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at; end - - sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } - def updated_at=(value); end - - sig { returns(T::Boolean) } - def updated_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_before_last_save; end - - sig { returns(T.untyped) } - def updated_at_before_type_cast; end - - sig { returns(T::Boolean) } - def updated_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def updated_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_previous_change; end - - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_was; end - - sig { void } - def updated_at_will_change!; end - - sig { returns(T.nilable(::String)) } - def value; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def value=(value); end - - sig { returns(T::Boolean) } - def value?; end - - sig { returns(T.nilable(::String)) } - def value_before_last_save; end - - sig { returns(T.untyped) } - def value_before_type_cast; end - - sig { returns(T::Boolean) } - def value_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def value_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def value_change_to_be_saved; end - - sig { returns(T::Boolean) } - def value_changed?; end - - sig { returns(T.nilable(::String)) } - def value_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def value_previous_change; end - - sig { returns(T::Boolean) } - def value_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def value_previously_was; end - - sig { returns(T.nilable(::String)) } - def value_was; end - - sig { void } - def value_will_change!; end - - sig { returns(T::Boolean) } - def will_save_change_to_created_at?; end - - sig { returns(T::Boolean) } - def will_save_change_to_key?; end - - sig { returns(T::Boolean) } - def will_save_change_to_updated_at?; end - - sig { returns(T::Boolean) } - def will_save_change_to_value?; end - end - - module GeneratedRelationMethods - sig { returns(PrivateRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def includes(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def unscope(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def without(*args, &blk); end - end - - class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::ActiveRecord::InternalMetadata } } - - sig { returns(T::Array[::ActiveRecord::InternalMetadata]) } - def to_ary; end - end - - class PrivateAssociationRelationWhereChain < PrivateAssociationRelation - Elem = type_member { { fixed: ::ActiveRecord::InternalMetadata } } - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateAssociationRelation) } - def not(opts, *rest); end - end - - class PrivateCollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::ActiveRecord::InternalMetadata } } - - sig do - params( - records: T.any(::ActiveRecord::InternalMetadata, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(PrivateCollectionProxy) - end - def <<(*records); end - - sig do - params( - records: T.any(::ActiveRecord::InternalMetadata, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(PrivateCollectionProxy) - end - def append(*records); end - - sig { returns(PrivateCollectionProxy) } - def clear; end - - sig do - params( - records: T.any(::ActiveRecord::InternalMetadata, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(PrivateCollectionProxy) - end - def concat(*records); end - - sig do - params( - records: T.any(::ActiveRecord::InternalMetadata, Integer, String, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, Integer, String, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(T::Array[::ActiveRecord::InternalMetadata]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActiveRecord::InternalMetadata, Integer, String, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, Integer, String, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(T::Array[::ActiveRecord::InternalMetadata]) - end - def destroy(*records); end - - sig { returns(T::Array[::ActiveRecord::InternalMetadata]) } - def load_target; end - - sig do - params( - records: T.any(::ActiveRecord::InternalMetadata, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(PrivateCollectionProxy) - end - def prepend(*records); end - - sig do - params( - records: T.any(::ActiveRecord::InternalMetadata, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(PrivateCollectionProxy) - end - def push(*records); end - - sig do - params( - other_array: T.any(::ActiveRecord::InternalMetadata, T::Enumerable[T.any(::ActiveRecord::InternalMetadata, T::Enumerable[::ActiveRecord::InternalMetadata])]) - ).returns(T::Array[::ActiveRecord::InternalMetadata]) - end - def replace(other_array); end - - sig { returns(PrivateAssociationRelation) } - def scope; end - - sig { returns(T::Array[::ActiveRecord::InternalMetadata]) } - def target; end - - sig { returns(T::Array[::ActiveRecord::InternalMetadata]) } - def to_ary; end - end - - class PrivateRelation < ::ActiveRecord::Relation - include CommonRelationMethods - include GeneratedRelationMethods - - Elem = type_member { { fixed: ::ActiveRecord::InternalMetadata } } - - sig { returns(T::Array[::ActiveRecord::InternalMetadata]) } - def to_ary; end - end - - class PrivateRelationWhereChain < PrivateRelation - Elem = type_member { { fixed: ::ActiveRecord::InternalMetadata } } - - sig { params(args: T.untyped).returns(PrivateRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateRelation) } - def not(opts, *rest); end - end -end diff --git a/sorbet/rbi/dsl/active_record/locking/optimistic.rbi b/sorbet/rbi/dsl/active_record/locking/optimistic.rbi index a4c42bad3..99efc8b40 100644 --- a/sorbet/rbi/dsl/active_record/locking/optimistic.rbi +++ b/sorbet/rbi/dsl/active_record/locking/optimistic.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Locking::Optimistic`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Locking::Optimistic`. + module ActiveRecord::Locking::Optimistic include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/model_schema.rbi b/sorbet/rbi/dsl/active_record/model_schema.rbi index 5db56366c..85bd9dafa 100644 --- a/sorbet/rbi/dsl/active_record/model_schema.rbi +++ b/sorbet/rbi/dsl/active_record/model_schema.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::ModelSchema`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::ModelSchema`. + module ActiveRecord::ModelSchema include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/nested_attributes.rbi b/sorbet/rbi/dsl/active_record/nested_attributes.rbi index 24b735aaa..6bbad79fe 100644 --- a/sorbet/rbi/dsl/active_record/nested_attributes.rbi +++ b/sorbet/rbi/dsl/active_record/nested_attributes.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::NestedAttributes`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::NestedAttributes`. + module ActiveRecord::NestedAttributes include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/normalization.rbi b/sorbet/rbi/dsl/active_record/normalization.rbi new file mode 100644 index 000000000..24b3404bd --- /dev/null +++ b/sorbet/rbi/dsl/active_record/normalization.rbi @@ -0,0 +1,24 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveRecord::Normalization`. +# Please instead update this file by running `bin/tapioca dsl ActiveRecord::Normalization`. + + +module ActiveRecord::Normalization + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def normalized_attributes; end + def normalized_attributes=(value); end + def normalized_attributes?; end + end + + module GeneratedInstanceMethods + def normalized_attributes; end + def normalized_attributes=(value); end + def normalized_attributes?; end + end +end diff --git a/sorbet/rbi/dsl/active_record/readonly_attributes.rbi b/sorbet/rbi/dsl/active_record/readonly_attributes.rbi index d2d906baa..c6477f57b 100644 --- a/sorbet/rbi/dsl/active_record/readonly_attributes.rbi +++ b/sorbet/rbi/dsl/active_record/readonly_attributes.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::ReadonlyAttributes`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::ReadonlyAttributes`. + module ActiveRecord::ReadonlyAttributes include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/reflection.rbi b/sorbet/rbi/dsl/active_record/reflection.rbi index 838578cda..8328dd4cd 100644 --- a/sorbet/rbi/dsl/active_record/reflection.rbi +++ b/sorbet/rbi/dsl/active_record/reflection.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Reflection`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Reflection`. + module ActiveRecord::Reflection include GeneratedInstanceMethods @@ -19,6 +20,9 @@ module ActiveRecord::Reflection def automatic_scope_inversing; end def automatic_scope_inversing=(value); end def automatic_scope_inversing?; end + def automatically_invert_plural_associations; end + def automatically_invert_plural_associations=(value); end + def automatically_invert_plural_associations?; end end module GeneratedInstanceMethods @@ -28,5 +32,7 @@ module ActiveRecord::Reflection def aggregate_reflections?; end def automatic_scope_inversing; end def automatic_scope_inversing?; end + def automatically_invert_plural_associations; end + def automatically_invert_plural_associations?; end end end diff --git a/sorbet/rbi/dsl/active_record/schema_migration.rbi b/sorbet/rbi/dsl/active_record/schema_migration.rbi deleted file mode 100644 index 002498b66..000000000 --- a/sorbet/rbi/dsl/active_record/schema_migration.rbi +++ /dev/null @@ -1,734 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveRecord::SchemaMigration`. -# Please instead update this file by running `bin/tapioca dsl ActiveRecord::SchemaMigration`. - -class ActiveRecord::SchemaMigration - include GeneratedAttributeMethods - extend CommonRelationMethods - extend GeneratedRelationMethods - - private - - sig { returns(NilClass) } - def to_ary; end - - module CommonRelationMethods - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::SchemaMigration).returns(T.untyped)) - ).returns(T::Boolean) - end - def any?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def average(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def build(attributes = nil, &block); end - - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } - def calculate(operation, column_name); end - - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def create(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def create!(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def create_or_find_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def create_or_find_by!(attributes, &block); end - - sig { returns(T::Array[::ActiveRecord::SchemaMigration]) } - def destroy_all; end - - sig { params(conditions: T.untyped).returns(T::Boolean) } - def exists?(conditions = :none); end - - sig { returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def fifth; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def fifth!; end - - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end - - sig { params(args: T.untyped).returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def find_by(*args); end - - sig { params(args: T.untyped).returns(::ActiveRecord::SchemaMigration) } - def find_by!(*args); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def find_or_create_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def find_or_create_by!(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def find_or_initialize_by(attributes, &block); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def find_signed(signed_id, purpose: nil); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(::ActiveRecord::SchemaMigration) } - def find_signed!(signed_id, purpose: nil); end - - sig { params(arg: T.untyped, args: T.untyped).returns(::ActiveRecord::SchemaMigration) } - def find_sole_by(arg, *args); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def first(limit = nil); end - - sig { returns(::ActiveRecord::SchemaMigration) } - def first!; end - - sig { returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def forty_two; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def forty_two!; end - - sig { returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def fourth; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def fourth!; end - - sig { returns(Array) } - def ids; end - - sig { params(record: T.untyped).returns(T::Boolean) } - def include?(record); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def last(limit = nil); end - - sig { returns(::ActiveRecord::SchemaMigration) } - def last!; end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::SchemaMigration).returns(T.untyped)) - ).returns(T::Boolean) - end - def many?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def maximum(column_name); end - - sig { params(record: T.untyped).returns(T::Boolean) } - def member?(record); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def minimum(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::ActiveRecord::SchemaMigration).void) - ).returns(::ActiveRecord::SchemaMigration) - end - def new(attributes = nil, &block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::SchemaMigration).returns(T.untyped)) - ).returns(T::Boolean) - end - def none?(&block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::ActiveRecord::SchemaMigration).returns(T.untyped)) - ).returns(T::Boolean) - end - def one?(&block); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pick(*column_names); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pluck(*column_names); end - - sig { returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def second; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def second!; end - - sig { returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def second_to_last; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def second_to_last!; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def sole; end - - sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) - end - def sum(column_name = nil, &block); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def take(limit = nil); end - - sig { returns(::ActiveRecord::SchemaMigration) } - def take!; end - - sig { returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def third; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def third!; end - - sig { returns(T.nilable(::ActiveRecord::SchemaMigration)) } - def third_to_last; end - - sig { returns(::ActiveRecord::SchemaMigration) } - def third_to_last!; end - end - - module GeneratedAssociationRelationMethods - sig { returns(PrivateAssociationRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def includes(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def unscope(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def without(*args, &blk); end - end - - module GeneratedAttributeMethods - sig { void } - def restore_version!; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_version; end - - sig { returns(T::Boolean) } - def saved_change_to_version?; end - - sig { returns(T.nilable(::String)) } - def version; end - - sig { params(value: ::String).returns(::String) } - def version=(value); end - - sig { returns(T::Boolean) } - def version?; end - - sig { returns(T.nilable(::String)) } - def version_before_last_save; end - - sig { returns(T.untyped) } - def version_before_type_cast; end - - sig { returns(T::Boolean) } - def version_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def version_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def version_change_to_be_saved; end - - sig { returns(T::Boolean) } - def version_changed?; end - - sig { returns(T.nilable(::String)) } - def version_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def version_previous_change; end - - sig { returns(T::Boolean) } - def version_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def version_previously_was; end - - sig { returns(T.nilable(::String)) } - def version_was; end - - sig { void } - def version_will_change!; end - - sig { returns(T::Boolean) } - def will_save_change_to_version?; end - end - - module GeneratedRelationMethods - sig { returns(PrivateRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def includes(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def unscope(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def without(*args, &blk); end - end - - class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::ActiveRecord::SchemaMigration } } - - sig { returns(T::Array[::ActiveRecord::SchemaMigration]) } - def to_ary; end - end - - class PrivateAssociationRelationWhereChain < PrivateAssociationRelation - Elem = type_member { { fixed: ::ActiveRecord::SchemaMigration } } - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateAssociationRelation) } - def not(opts, *rest); end - end - - class PrivateCollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::ActiveRecord::SchemaMigration } } - - sig do - params( - records: T.any(::ActiveRecord::SchemaMigration, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(PrivateCollectionProxy) - end - def <<(*records); end - - sig do - params( - records: T.any(::ActiveRecord::SchemaMigration, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(PrivateCollectionProxy) - end - def append(*records); end - - sig { returns(PrivateCollectionProxy) } - def clear; end - - sig do - params( - records: T.any(::ActiveRecord::SchemaMigration, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(PrivateCollectionProxy) - end - def concat(*records); end - - sig do - params( - records: T.any(::ActiveRecord::SchemaMigration, Integer, String, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, Integer, String, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(T::Array[::ActiveRecord::SchemaMigration]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActiveRecord::SchemaMigration, Integer, String, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, Integer, String, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(T::Array[::ActiveRecord::SchemaMigration]) - end - def destroy(*records); end - - sig { returns(T::Array[::ActiveRecord::SchemaMigration]) } - def load_target; end - - sig do - params( - records: T.any(::ActiveRecord::SchemaMigration, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(PrivateCollectionProxy) - end - def prepend(*records); end - - sig do - params( - records: T.any(::ActiveRecord::SchemaMigration, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(PrivateCollectionProxy) - end - def push(*records); end - - sig do - params( - other_array: T.any(::ActiveRecord::SchemaMigration, T::Enumerable[T.any(::ActiveRecord::SchemaMigration, T::Enumerable[::ActiveRecord::SchemaMigration])]) - ).returns(T::Array[::ActiveRecord::SchemaMigration]) - end - def replace(other_array); end - - sig { returns(PrivateAssociationRelation) } - def scope; end - - sig { returns(T::Array[::ActiveRecord::SchemaMigration]) } - def target; end - - sig { returns(T::Array[::ActiveRecord::SchemaMigration]) } - def to_ary; end - end - - class PrivateRelation < ::ActiveRecord::Relation - include CommonRelationMethods - include GeneratedRelationMethods - - Elem = type_member { { fixed: ::ActiveRecord::SchemaMigration } } - - sig { returns(T::Array[::ActiveRecord::SchemaMigration]) } - def to_ary; end - end - - class PrivateRelationWhereChain < PrivateRelation - Elem = type_member { { fixed: ::ActiveRecord::SchemaMigration } } - - sig { params(args: T.untyped).returns(PrivateRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateRelation) } - def not(opts, *rest); end - end -end diff --git a/sorbet/rbi/dsl/active_record/scoping.rbi b/sorbet/rbi/dsl/active_record/scoping.rbi index 3cb1522a3..229070b39 100644 --- a/sorbet/rbi/dsl/active_record/scoping.rbi +++ b/sorbet/rbi/dsl/active_record/scoping.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Scoping`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Scoping`. + module ActiveRecord::Scoping include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/scoping/default.rbi b/sorbet/rbi/dsl/active_record/scoping/default.rbi index 77334e577..28518b0c3 100644 --- a/sorbet/rbi/dsl/active_record/scoping/default.rbi +++ b/sorbet/rbi/dsl/active_record/scoping/default.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Scoping::Default`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Scoping::Default`. + module ActiveRecord::Scoping::Default include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/secure_password.rbi b/sorbet/rbi/dsl/active_record/secure_password.rbi new file mode 100644 index 000000000..6c06f86b7 --- /dev/null +++ b/sorbet/rbi/dsl/active_record/secure_password.rbi @@ -0,0 +1,10 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveRecord::SecurePassword`. +# Please instead update this file by running `bin/tapioca dsl ActiveRecord::SecurePassword`. + + +module ActiveRecord::SecurePassword + mixes_in_class_methods ::ActiveModel::SecurePassword::ClassMethods +end diff --git a/sorbet/rbi/dsl/active_record/serialization.rbi b/sorbet/rbi/dsl/active_record/serialization.rbi index a3808ddf6..59b5278ae 100644 --- a/sorbet/rbi/dsl/active_record/serialization.rbi +++ b/sorbet/rbi/dsl/active_record/serialization.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Serialization`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Serialization`. + module ActiveRecord::Serialization include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/signed_id.rbi b/sorbet/rbi/dsl/active_record/signed_id.rbi index ccac45e8e..0db888ffb 100644 --- a/sorbet/rbi/dsl/active_record/signed_id.rbi +++ b/sorbet/rbi/dsl/active_record/signed_id.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::SignedId`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::SignedId`. + module ActiveRecord::SignedId include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/test_fixtures.rbi b/sorbet/rbi/dsl/active_record/test_fixtures.rbi deleted file mode 100644 index 0cef89b73..000000000 --- a/sorbet/rbi/dsl/active_record/test_fixtures.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveRecord::TestFixtures`. -# Please instead update this file by running `bin/tapioca dsl ActiveRecord::TestFixtures`. - -module ActiveRecord::TestFixtures - include GeneratedInstanceMethods - - mixes_in_class_methods GeneratedClassMethods - - module GeneratedClassMethods - def fixture_class_names; end - def fixture_class_names=(value); end - def fixture_class_names?; end - def fixture_path; end - def fixture_path=(value); end - def fixture_path?; end - def fixture_table_names; end - def fixture_table_names=(value); end - def fixture_table_names?; end - def lock_threads; end - def lock_threads=(value); end - def lock_threads?; end - def pre_loaded_fixtures; end - def pre_loaded_fixtures=(value); end - def pre_loaded_fixtures?; end - def use_instantiated_fixtures; end - def use_instantiated_fixtures=(value); end - def use_instantiated_fixtures?; end - def use_transactional_tests; end - def use_transactional_tests=(value); end - def use_transactional_tests?; end - end - - module GeneratedInstanceMethods - def fixture_class_names; end - def fixture_class_names=(value); end - def fixture_class_names?; end - def fixture_path; end - def fixture_path?; end - def fixture_table_names; end - def fixture_table_names=(value); end - def fixture_table_names?; end - def lock_threads; end - def lock_threads=(value); end - def lock_threads?; end - def pre_loaded_fixtures; end - def pre_loaded_fixtures=(value); end - def pre_loaded_fixtures?; end - def use_instantiated_fixtures; end - def use_instantiated_fixtures=(value); end - def use_instantiated_fixtures?; end - def use_transactional_tests; end - def use_transactional_tests=(value); end - def use_transactional_tests?; end - end -end diff --git a/sorbet/rbi/dsl/active_record/timestamp.rbi b/sorbet/rbi/dsl/active_record/timestamp.rbi index 687957e4c..31ee3190a 100644 --- a/sorbet/rbi/dsl/active_record/timestamp.rbi +++ b/sorbet/rbi/dsl/active_record/timestamp.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveRecord::Timestamp`. # Please instead update this file by running `bin/tapioca dsl ActiveRecord::Timestamp`. + module ActiveRecord::Timestamp include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_record/token_for.rbi b/sorbet/rbi/dsl/active_record/token_for.rbi new file mode 100644 index 000000000..4e1eec698 --- /dev/null +++ b/sorbet/rbi/dsl/active_record/token_for.rbi @@ -0,0 +1,21 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveRecord::TokenFor`. +# Please instead update this file by running `bin/tapioca dsl ActiveRecord::TokenFor`. + + +module ActiveRecord::TokenFor + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def generated_token_verifier; end + def generated_token_verifier=(value); end + def token_definitions; end + def token_definitions=(value); end + end + + module GeneratedInstanceMethods; end +end diff --git a/sorbet/rbi/dsl/active_reservation_checker_worker.rbi b/sorbet/rbi/dsl/active_reservation_checker_worker.rbi index adf1f8965..50cbdddd6 100644 --- a/sorbet/rbi/dsl/active_reservation_checker_worker.rbi +++ b/sorbet/rbi/dsl/active_reservation_checker_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveReservationCheckerWorker`. # Please instead update this file by running `bin/tapioca dsl ActiveReservationCheckerWorker`. + class ActiveReservationCheckerWorker class << self sig { params(reservation_id: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/active_reservations_checker_worker.rbi b/sorbet/rbi/dsl/active_reservations_checker_worker.rbi index 257168052..ecd26ba8e 100644 --- a/sorbet/rbi/dsl/active_reservations_checker_worker.rbi +++ b/sorbet/rbi/dsl/active_reservations_checker_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveReservationsCheckerWorker`. # Please instead update this file by running `bin/tapioca dsl ActiveReservationsCheckerWorker`. + class ActiveReservationsCheckerWorker class << self sig { params(reservation_ids: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/active_storage/analyze_job.rbi b/sorbet/rbi/dsl/active_storage/analyze_job.rbi index 9b4b0859f..7b4806800 100644 --- a/sorbet/rbi/dsl/active_storage/analyze_job.rbi +++ b/sorbet/rbi/dsl/active_storage/analyze_job.rbi @@ -4,10 +4,16 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::AnalyzeJob`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::AnalyzeJob`. + class ActiveStorage::AnalyzeJob class << self - sig { params(blob: T.untyped).returns(T.any(ActiveStorage::AnalyzeJob, FalseClass)) } - def perform_later(blob); end + sig do + params( + blob: T.untyped, + block: T.nilable(T.proc.params(job: ActiveStorage::AnalyzeJob).void) + ).returns(T.any(ActiveStorage::AnalyzeJob, FalseClass)) + end + def perform_later(blob, &block); end sig { params(blob: T.untyped).returns(T.untyped) } def perform_now(blob); end diff --git a/sorbet/rbi/dsl/active_storage/attachment.rbi b/sorbet/rbi/dsl/active_storage/attachment.rbi index 11fcc71ff..80505449f 100644 --- a/sorbet/rbi/dsl/active_storage/attachment.rbi +++ b/sorbet/rbi/dsl/active_storage/attachment.rbi @@ -4,8 +4,10 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::Attachment`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::Attachment`. + class ActiveStorage::Attachment include GeneratedAssociationMethods + include GeneratedAttributeMethods extend CommonRelationMethods extend GeneratedRelationMethods @@ -22,9 +24,20 @@ class ActiveStorage::Attachment end def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(::ActiveStorage::Attachment) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -33,12 +46,29 @@ class ActiveStorage::Attachment end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig do + params( + column_name: NilClass, + block: T.proc.params(object: ::ActiveStorage::Attachment).void + ).returns(Integer) + end + def count(column_name = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(::ActiveStorage::Attachment) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -47,6 +77,17 @@ class ActiveStorage::Attachment end def create(attributes = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(::ActiveStorage::Attachment) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -55,6 +96,12 @@ class ActiveStorage::Attachment end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -63,6 +110,12 @@ class ActiveStorage::Attachment end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -83,8 +136,23 @@ class ActiveStorage::Attachment sig { returns(::ActiveStorage::Attachment) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ActiveStorage::Attachment) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ActiveStorage::Attachment]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ActiveStorage::Attachment).void + ).returns(T.nilable(::ActiveStorage::Attachment)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ActiveStorage::Attachment)) } def find_by(*args); end @@ -92,6 +160,54 @@ class ActiveStorage::Attachment sig { params(args: T.untyped).returns(::ActiveStorage::Attachment) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ActiveStorage::Attachment).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ActiveStorage::Attachment]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ActiveStorage::Attachment]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ActiveStorage::Attachment]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -100,6 +216,12 @@ class ActiveStorage::Attachment end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -108,6 +230,12 @@ class ActiveStorage::Attachment end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -125,7 +253,8 @@ class ActiveStorage::Attachment sig { params(arg: T.untyped, args: T.untyped).returns(::ActiveStorage::Attachment) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Attachment)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::Attachment]) } def first(limit = nil); end sig { returns(::ActiveStorage::Attachment) } @@ -146,10 +275,36 @@ class ActiveStorage::Attachment sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Attachment)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::Attachment]) } def last(limit = nil); end sig { returns(::ActiveStorage::Attachment) } @@ -171,6 +326,17 @@ class ActiveStorage::Attachment sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(::ActiveStorage::Attachment) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Attachment).void) + ).returns(T::Array[::ActiveStorage::Attachment]) + end sig do params( attributes: T.untyped, @@ -214,15 +380,18 @@ class ActiveStorage::Attachment sig { returns(::ActiveStorage::Attachment) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ActiveStorage::Attachment).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Attachment)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::Attachment]) } def take(limit = nil); end sig { returns(::ActiveStorage::Attachment) } @@ -242,19 +411,25 @@ class ActiveStorage::Attachment end module GeneratedAssociationMethods - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } def blob; end - sig { params(value: T.untyped).void } + sig { params(value: T.nilable(::ActiveStorage::Blob)).void } def blob=(value); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { returns(T::Boolean) } + def blob_changed?; end + + sig { returns(T::Boolean) } + def blob_previously_changed?; end + + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def build_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_blob!(*args, &blk); end sig { returns(T.untyped) } @@ -263,11 +438,23 @@ class ActiveStorage::Attachment sig { params(value: T.untyped).void } def record=(value); end - sig { returns(T.untyped) } + sig { returns(T::Boolean) } + def record_changed?; end + + sig { returns(T::Boolean) } + def record_previously_changed?; end + + sig { returns(T.nilable(::ActiveStorage::Blob)) } def reload_blob; end sig { returns(T.untyped) } def reload_record; end + + sig { void } + def reset_blob; end + + sig { void } + def reset_record; end end module GeneratedAssociationRelationMethods @@ -283,8 +470,8 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -298,13 +485,13 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -316,40 +503,6 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -374,6 +527,9 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -398,6 +554,9 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -425,34 +584,423 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def with_all_variant_records(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end + module GeneratedAttributeMethods + sig { returns(::Integer) } + def blob_id; end + + sig { params(value: ::Integer).returns(::Integer) } + def blob_id=(value); end + + sig { returns(T::Boolean) } + def blob_id?; end + + sig { returns(T.nilable(::Integer)) } + def blob_id_before_last_save; end + + sig { returns(T.untyped) } + def blob_id_before_type_cast; end + + sig { returns(T::Boolean) } + def blob_id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def blob_id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def blob_id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def blob_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def blob_id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def blob_id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def blob_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def blob_id_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def blob_id_was; end + + sig { void } + def blob_id_will_change!; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def created_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def created_at=(value); end + + sig { returns(T::Boolean) } + def created_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_before_last_save; end + + sig { returns(T.untyped) } + def created_at_before_type_cast; end + + sig { returns(T::Boolean) } + def created_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_was; end + + sig { void } + def created_at_will_change!; end + + sig { returns(::Integer) } + def id; end + + sig { params(value: ::Integer).returns(::Integer) } + def id=(value); end + + sig { returns(T::Boolean) } + def id?; end + + sig { returns(T.nilable(::Integer)) } + def id_before_last_save; end + + sig { returns(T.untyped) } + def id_before_type_cast; end + + sig { returns(T::Boolean) } + def id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_previously_was; end + + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def id_was; end + + sig { void } + def id_will_change!; end + + sig { returns(::String) } + def name; end + + sig { params(value: ::String).returns(::String) } + def name=(value); end + + sig { returns(T::Boolean) } + def name?; end + + sig { returns(T.nilable(::String)) } + def name_before_last_save; end + + sig { returns(T.untyped) } + def name_before_type_cast; end + + sig { returns(T::Boolean) } + def name_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def name_change; end + + sig { returns(T.nilable([::String, ::String])) } + def name_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def name_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def name_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def name_previously_was; end + + sig { returns(T.nilable(::String)) } + def name_was; end + + sig { void } + def name_will_change!; end + + sig { returns(::Integer) } + def record_id; end + + sig { params(value: ::Integer).returns(::Integer) } + def record_id=(value); end + + sig { returns(T::Boolean) } + def record_id?; end + + sig { returns(T.nilable(::Integer)) } + def record_id_before_last_save; end + + sig { returns(T.untyped) } + def record_id_before_type_cast; end + + sig { returns(T::Boolean) } + def record_id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def record_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def record_id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def record_id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def record_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def record_id_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def record_id_was; end + + sig { void } + def record_id_will_change!; end + + sig { returns(::String) } + def record_type; end + + sig { params(value: ::String).returns(::String) } + def record_type=(value); end + + sig { returns(T::Boolean) } + def record_type?; end + + sig { returns(T.nilable(::String)) } + def record_type_before_last_save; end + + sig { returns(T.untyped) } + def record_type_before_type_cast; end + + sig { returns(T::Boolean) } + def record_type_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_change; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def record_type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def record_type_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def record_type_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def record_type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def record_type_previously_was; end + + sig { returns(T.nilable(::String)) } + def record_type_was; end + + sig { void } + def record_type_will_change!; end + + sig { void } + def restore_blob_id!; end + + sig { void } + def restore_created_at!; end + + sig { void } + def restore_id!; end + + sig { void } + def restore_id_value!; end + + sig { void } + def restore_name!; end + + sig { void } + def restore_record_id!; end + + sig { void } + def restore_record_type!; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_blob_id; end + + sig { returns(T::Boolean) } + def saved_change_to_blob_id?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_created_at; end + + sig { returns(T::Boolean) } + def saved_change_to_created_at?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id; end + + sig { returns(T::Boolean) } + def saved_change_to_id?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_name; end + + sig { returns(T::Boolean) } + def saved_change_to_name?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_record_id; end + + sig { returns(T::Boolean) } + def saved_change_to_record_id?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_record_type; end + + sig { returns(T::Boolean) } + def saved_change_to_record_type?; end + + sig { returns(T::Boolean) } + def will_save_change_to_blob_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_created_at?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + + sig { returns(T::Boolean) } + def will_save_change_to_name?; end + + sig { returns(T::Boolean) } + def will_save_change_to_record_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_record_type?; end + end + module GeneratedRelationMethods sig { returns(PrivateRelation) } def all; end @@ -466,8 +1014,8 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -481,13 +1029,13 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -523,6 +1071,9 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -547,6 +1098,9 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -577,9 +1131,15 @@ class ActiveStorage::Attachment sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def with_all_variant_records(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -590,10 +1150,48 @@ class ActiveStorage::Attachment Elem = type_member { { fixed: ::ActiveStorage::Attachment } } + sig { returns(T::Array[::ActiveStorage::Attachment]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::Attachment]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ActiveStorage::Attachment } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ActiveStorage::Attachment } } @@ -637,20 +1235,6 @@ class ActiveStorage::Attachment end def concat(*records); end - sig do - params( - records: T.any(::ActiveStorage::Attachment, Integer, String, T::Enumerable[T.any(::ActiveStorage::Attachment, Integer, String, T::Enumerable[::ActiveStorage::Attachment])]) - ).returns(T::Array[::ActiveStorage::Attachment]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActiveStorage::Attachment, Integer, String, T::Enumerable[T.any(::ActiveStorage::Attachment, Integer, String, T::Enumerable[::ActiveStorage::Attachment])]) - ).returns(T::Array[::ActiveStorage::Attachment]) - end - def destroy(*records); end - sig { returns(T::Array[::ActiveStorage::Attachment]) } def load_target; end @@ -681,6 +1265,9 @@ class ActiveStorage::Attachment sig { returns(T::Array[::ActiveStorage::Attachment]) } def target; end + sig { returns(T::Array[::ActiveStorage::Attachment]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::Attachment]) } def to_ary; end end @@ -691,10 +1278,48 @@ class ActiveStorage::Attachment Elem = type_member { { fixed: ::ActiveStorage::Attachment } } + sig { returns(T::Array[::ActiveStorage::Attachment]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::Attachment]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ActiveStorage::Attachment } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ActiveStorage::Attachment } } diff --git a/sorbet/rbi/dsl/active_storage/base_controller.rbi b/sorbet/rbi/dsl/active_storage/base_controller.rbi deleted file mode 100644 index 92e3c22d2..000000000 --- a/sorbet/rbi/dsl/active_storage/base_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::BaseController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::BaseController`. - -class ActiveStorage::BaseController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/blob.rbi b/sorbet/rbi/dsl/active_storage/blob.rbi index 6dad697f0..19c0a3c5c 100644 --- a/sorbet/rbi/dsl/active_storage/blob.rbi +++ b/sorbet/rbi/dsl/active_storage/blob.rbi @@ -4,10 +4,14 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::Blob`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::Blob`. + class ActiveStorage::Blob include GeneratedAssociationMethods + include GeneratedAttributeMethods extend CommonRelationMethods extend GeneratedRelationMethods + include GeneratedSecureTokenMethods + include GeneratedStoredAttributesMethods sig { returns(ActiveStorage::Attached::One) } def preview_image; end @@ -28,9 +32,16 @@ class ActiveStorage::Blob end def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void)).returns(::ActiveStorage::Blob) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -39,12 +50,20 @@ class ActiveStorage::Blob end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ActiveStorage::Blob).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void)).returns(::ActiveStorage::Blob) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -53,6 +72,13 @@ class ActiveStorage::Blob end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void)).returns(::ActiveStorage::Blob) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -61,6 +87,12 @@ class ActiveStorage::Blob end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -69,6 +101,12 @@ class ActiveStorage::Blob end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -89,8 +127,23 @@ class ActiveStorage::Blob sig { returns(::ActiveStorage::Blob) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ActiveStorage::Blob) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ActiveStorage::Blob]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ActiveStorage::Blob).void + ).returns(T.nilable(::ActiveStorage::Blob)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ActiveStorage::Blob)) } def find_by(*args); end @@ -98,6 +151,54 @@ class ActiveStorage::Blob sig { params(args: T.untyped).returns(::ActiveStorage::Blob) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ActiveStorage::Blob).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ActiveStorage::Blob]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ActiveStorage::Blob]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ActiveStorage::Blob]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -106,6 +207,12 @@ class ActiveStorage::Blob end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -114,6 +221,12 @@ class ActiveStorage::Blob end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -131,7 +244,8 @@ class ActiveStorage::Blob sig { params(arg: T.untyped, args: T.untyped).returns(::ActiveStorage::Blob) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::Blob]) } def first(limit = nil); end sig { returns(::ActiveStorage::Blob) } @@ -152,10 +266,36 @@ class ActiveStorage::Blob sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::Blob]) } def last(limit = nil); end sig { returns(::ActiveStorage::Blob) } @@ -177,6 +317,13 @@ class ActiveStorage::Blob sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void)).returns(::ActiveStorage::Blob) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::Blob).void) + ).returns(T::Array[::ActiveStorage::Blob]) + end sig do params( attributes: T.untyped, @@ -220,15 +367,18 @@ class ActiveStorage::Blob sig { returns(::ActiveStorage::Blob) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ActiveStorage::Blob).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::Blob]) } def take(limit = nil); end sig { returns(::ActiveStorage::Blob) } @@ -256,48 +406,54 @@ class ActiveStorage::Blob # This method is created by ActiveRecord on the `ActiveStorage::Blob` class because it declared `has_many :attachments`. # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(ActiveRecord::Associations::CollectionProxy) } + sig { returns(::ActiveStorage::Attachment::PrivateCollectionProxy) } def attachments; end - sig { params(value: T::Enumerable[T.untyped]).void } + sig { params(value: T::Enumerable[::ActiveStorage::Attachment]).void } def attachments=(value); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } def build_preview_image_attachment(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def build_preview_image_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } def create_preview_image_attachment(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } def create_preview_image_attachment!(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_preview_image_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_preview_image_blob!(*args, &blk); end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Attachment)) } def preview_image_attachment; end - sig { params(value: T.untyped).void } + sig { params(value: T.nilable(::ActiveStorage::Attachment)).void } def preview_image_attachment=(value); end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } def preview_image_blob; end - sig { params(value: T.untyped).void } + sig { params(value: T.nilable(::ActiveStorage::Blob)).void } def preview_image_blob=(value); end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Attachment)) } def reload_preview_image_attachment; end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } def reload_preview_image_blob; end + sig { void } + def reset_preview_image_attachment; end + + sig { void } + def reset_preview_image_blob; end + sig { returns(T::Array[T.untyped]) } def variant_record_ids; end @@ -306,10 +462,10 @@ class ActiveStorage::Blob # This method is created by ActiveRecord on the `ActiveStorage::Blob` class because it declared `has_many :variant_records`. # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(ActiveRecord::Associations::CollectionProxy) } + sig { returns(::ActiveStorage::VariantRecord::PrivateCollectionProxy) } def variant_records; end - sig { params(value: T::Enumerable[T.untyped]).void } + sig { params(value: T::Enumerable[::ActiveStorage::VariantRecord]).void } def variant_records=(value); end end @@ -326,8 +482,8 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -341,13 +497,13 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -359,40 +515,6 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -417,6 +539,9 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -441,6 +566,9 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -471,34 +599,594 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def with_attached_preview_image(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end + module GeneratedAttributeMethods + sig { returns(::Integer) } + def byte_size; end + + sig { params(value: ::Integer).returns(::Integer) } + def byte_size=(value); end + + sig { returns(T::Boolean) } + def byte_size?; end + + sig { returns(T.nilable(::Integer)) } + def byte_size_before_last_save; end + + sig { returns(T.untyped) } + def byte_size_before_type_cast; end + + sig { returns(T::Boolean) } + def byte_size_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def byte_size_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def byte_size_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def byte_size_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def byte_size_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def byte_size_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def byte_size_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def byte_size_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def byte_size_was; end + + sig { void } + def byte_size_will_change!; end + + sig { returns(T.nilable(::String)) } + def checksum; end + + sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } + def checksum=(value); end + + sig { returns(T::Boolean) } + def checksum?; end + + sig { returns(T.nilable(::String)) } + def checksum_before_last_save; end + + sig { returns(T.untyped) } + def checksum_before_type_cast; end + + sig { returns(T::Boolean) } + def checksum_came_from_user?; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def checksum_change; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def checksum_change_to_be_saved; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def checksum_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def checksum_in_database; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def checksum_previous_change; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def checksum_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def checksum_previously_was; end + + sig { returns(T.nilable(::String)) } + def checksum_was; end + + sig { void } + def checksum_will_change!; end + + sig { returns(T.nilable(::String)) } + def content_type; end + + sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } + def content_type=(value); end + + sig { returns(T::Boolean) } + def content_type?; end + + sig { returns(T.nilable(::String)) } + def content_type_before_last_save; end + + sig { returns(T.untyped) } + def content_type_before_type_cast; end + + sig { returns(T::Boolean) } + def content_type_came_from_user?; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def content_type_change; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def content_type_change_to_be_saved; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def content_type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def content_type_in_database; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def content_type_previous_change; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def content_type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def content_type_previously_was; end + + sig { returns(T.nilable(::String)) } + def content_type_was; end + + sig { void } + def content_type_will_change!; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def created_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def created_at=(value); end + + sig { returns(T::Boolean) } + def created_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_before_last_save; end + + sig { returns(T.untyped) } + def created_at_before_type_cast; end + + sig { returns(T::Boolean) } + def created_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_was; end + + sig { void } + def created_at_will_change!; end + + sig { returns(::String) } + def filename; end + + sig { params(value: ::String).returns(::String) } + def filename=(value); end + + sig { returns(T::Boolean) } + def filename?; end + + sig { returns(T.nilable(::String)) } + def filename_before_last_save; end + + sig { returns(T.untyped) } + def filename_before_type_cast; end + + sig { returns(T::Boolean) } + def filename_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def filename_change; end + + sig { returns(T.nilable([::String, ::String])) } + def filename_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def filename_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def filename_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def filename_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def filename_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def filename_previously_was; end + + sig { returns(T.nilable(::String)) } + def filename_was; end + + sig { void } + def filename_will_change!; end + + sig { returns(::Integer) } + def id; end + + sig { params(value: ::Integer).returns(::Integer) } + def id=(value); end + + sig { returns(T::Boolean) } + def id?; end + + sig { returns(T.nilable(::Integer)) } + def id_before_last_save; end + + sig { returns(T.untyped) } + def id_before_type_cast; end + + sig { returns(T::Boolean) } + def id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_previously_was; end + + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def id_was; end + + sig { void } + def id_will_change!; end + + sig { returns(::String) } + def key; end + + sig { params(value: ::String).returns(::String) } + def key=(value); end + + sig { returns(T::Boolean) } + def key?; end + + sig { returns(T.nilable(::String)) } + def key_before_last_save; end + + sig { returns(T.untyped) } + def key_before_type_cast; end + + sig { returns(T::Boolean) } + def key_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def key_change; end + + sig { returns(T.nilable([::String, ::String])) } + def key_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def key_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def key_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def key_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def key_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def key_previously_was; end + + sig { returns(T.nilable(::String)) } + def key_was; end + + sig { void } + def key_will_change!; end + + sig { returns(T.untyped) } + def metadata; end + + sig { params(value: T.untyped).returns(T.untyped) } + def metadata=(value); end + + sig { returns(T::Boolean) } + def metadata?; end + + sig { returns(T.untyped) } + def metadata_before_last_save; end + + sig { returns(T.untyped) } + def metadata_before_type_cast; end + + sig { returns(T::Boolean) } + def metadata_came_from_user?; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def metadata_change; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def metadata_change_to_be_saved; end + + sig { params(from: T.untyped, to: T.untyped).returns(T::Boolean) } + def metadata_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.untyped) } + def metadata_in_database; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def metadata_previous_change; end + + sig { params(from: T.untyped, to: T.untyped).returns(T::Boolean) } + def metadata_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.untyped) } + def metadata_previously_was; end + + sig { returns(T.untyped) } + def metadata_was; end + + sig { void } + def metadata_will_change!; end + + sig { void } + def restore_byte_size!; end + + sig { void } + def restore_checksum!; end + + sig { void } + def restore_content_type!; end + + sig { void } + def restore_created_at!; end + + sig { void } + def restore_filename!; end + + sig { void } + def restore_id!; end + + sig { void } + def restore_id_value!; end + + sig { void } + def restore_key!; end + + sig { void } + def restore_metadata!; end + + sig { void } + def restore_service_name!; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_byte_size; end + + sig { returns(T::Boolean) } + def saved_change_to_byte_size?; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def saved_change_to_checksum; end + + sig { returns(T::Boolean) } + def saved_change_to_checksum?; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def saved_change_to_content_type; end + + sig { returns(T::Boolean) } + def saved_change_to_content_type?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_created_at; end + + sig { returns(T::Boolean) } + def saved_change_to_created_at?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_filename; end + + sig { returns(T::Boolean) } + def saved_change_to_filename?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id; end + + sig { returns(T::Boolean) } + def saved_change_to_id?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_key; end + + sig { returns(T::Boolean) } + def saved_change_to_key?; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def saved_change_to_metadata; end + + sig { returns(T::Boolean) } + def saved_change_to_metadata?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_service_name; end + + sig { returns(T::Boolean) } + def saved_change_to_service_name?; end + + sig { returns(::String) } + def service_name; end + + sig { params(value: ::String).returns(::String) } + def service_name=(value); end + + sig { returns(T::Boolean) } + def service_name?; end + + sig { returns(T.nilable(::String)) } + def service_name_before_last_save; end + + sig { returns(T.untyped) } + def service_name_before_type_cast; end + + sig { returns(T::Boolean) } + def service_name_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def service_name_change; end + + sig { returns(T.nilable([::String, ::String])) } + def service_name_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def service_name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def service_name_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def service_name_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def service_name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def service_name_previously_was; end + + sig { returns(T.nilable(::String)) } + def service_name_was; end + + sig { void } + def service_name_will_change!; end + + sig { returns(T::Boolean) } + def will_save_change_to_byte_size?; end + + sig { returns(T::Boolean) } + def will_save_change_to_checksum?; end + + sig { returns(T::Boolean) } + def will_save_change_to_content_type?; end + + sig { returns(T::Boolean) } + def will_save_change_to_created_at?; end + + sig { returns(T::Boolean) } + def will_save_change_to_filename?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + + sig { returns(T::Boolean) } + def will_save_change_to_key?; end + + sig { returns(T::Boolean) } + def will_save_change_to_metadata?; end + + sig { returns(T::Boolean) } + def will_save_change_to_service_name?; end + end + module GeneratedRelationMethods sig { returns(PrivateRelation) } def all; end @@ -512,8 +1200,8 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -527,13 +1215,13 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -569,6 +1257,9 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -593,6 +1284,9 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -626,23 +1320,146 @@ class ActiveStorage::Blob sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def with_attached_preview_image(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end + module GeneratedSecureTokenMethods + sig { returns(T::Boolean) } + def regenerate_key; end + end + + module GeneratedStoredAttributesMethods + sig { returns(T.untyped) } + def analyzed; end + + sig { params(value: T.untyped).returns(T.untyped) } + def analyzed=(value); end + + sig { returns(T.untyped) } + def analyzed_before_last_save; end + + sig { returns(T.untyped) } + def analyzed_change; end + + sig { returns(T::Boolean) } + def analyzed_changed?; end + + sig { returns(T.untyped) } + def analyzed_was; end + + sig { returns(T.untyped) } + def composed; end + + sig { params(value: T.untyped).returns(T.untyped) } + def composed=(value); end + + sig { returns(T.untyped) } + def composed_before_last_save; end + + sig { returns(T.untyped) } + def composed_change; end + + sig { returns(T::Boolean) } + def composed_changed?; end + + sig { returns(T.untyped) } + def composed_was; end + + sig { returns(T.untyped) } + def identified; end + + sig { params(value: T.untyped).returns(T.untyped) } + def identified=(value); end + + sig { returns(T.untyped) } + def identified_before_last_save; end + + sig { returns(T.untyped) } + def identified_change; end + + sig { returns(T::Boolean) } + def identified_changed?; end + + sig { returns(T.untyped) } + def identified_was; end + + sig { returns(T.untyped) } + def saved_change_to_analyzed; end + + sig { returns(T::Boolean) } + def saved_change_to_analyzed?; end + + sig { returns(T.untyped) } + def saved_change_to_composed; end + + sig { returns(T::Boolean) } + def saved_change_to_composed?; end + + sig { returns(T.untyped) } + def saved_change_to_identified; end + + sig { returns(T::Boolean) } + def saved_change_to_identified?; end + end + class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation include CommonRelationMethods include GeneratedAssociationRelationMethods Elem = type_member { { fixed: ::ActiveStorage::Blob } } + sig { returns(T::Array[::ActiveStorage::Blob]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::Blob]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ActiveStorage::Blob } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ActiveStorage::Blob } } @@ -686,20 +1503,6 @@ class ActiveStorage::Blob end def concat(*records); end - sig do - params( - records: T.any(::ActiveStorage::Blob, Integer, String, T::Enumerable[T.any(::ActiveStorage::Blob, Integer, String, T::Enumerable[::ActiveStorage::Blob])]) - ).returns(T::Array[::ActiveStorage::Blob]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActiveStorage::Blob, Integer, String, T::Enumerable[T.any(::ActiveStorage::Blob, Integer, String, T::Enumerable[::ActiveStorage::Blob])]) - ).returns(T::Array[::ActiveStorage::Blob]) - end - def destroy(*records); end - sig { returns(T::Array[::ActiveStorage::Blob]) } def load_target; end @@ -730,6 +1533,9 @@ class ActiveStorage::Blob sig { returns(T::Array[::ActiveStorage::Blob]) } def target; end + sig { returns(T::Array[::ActiveStorage::Blob]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::Blob]) } def to_ary; end end @@ -740,10 +1546,48 @@ class ActiveStorage::Blob Elem = type_member { { fixed: ::ActiveStorage::Blob } } + sig { returns(T::Array[::ActiveStorage::Blob]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::Blob]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ActiveStorage::Blob } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ActiveStorage::Blob } } diff --git a/sorbet/rbi/dsl/active_storage/blobs/proxy_controller.rbi b/sorbet/rbi/dsl/active_storage/blobs/proxy_controller.rbi deleted file mode 100644 index c5e260cd1..000000000 --- a/sorbet/rbi/dsl/active_storage/blobs/proxy_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::Blobs::ProxyController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::Blobs::ProxyController`. - -class ActiveStorage::Blobs::ProxyController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/blobs/redirect_controller.rbi b/sorbet/rbi/dsl/active_storage/blobs/redirect_controller.rbi deleted file mode 100644 index ee0d20338..000000000 --- a/sorbet/rbi/dsl/active_storage/blobs/redirect_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::Blobs::RedirectController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::Blobs::RedirectController`. - -class ActiveStorage::Blobs::RedirectController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/current.rbi b/sorbet/rbi/dsl/active_storage/current.rbi index 3f68d0ded..be334c3f0 100644 --- a/sorbet/rbi/dsl/active_storage/current.rbi +++ b/sorbet/rbi/dsl/active_storage/current.rbi @@ -4,20 +4,19 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::Current`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::Current`. -class ActiveStorage::Current - sig { returns(T.untyped) } - def url_options; end - sig { params(value: T.untyped).returns(T.untyped) } - def url_options=(value); end +class ActiveStorage::Current + include GeneratedAttributeMethods class << self sig { returns(T.untyped) } - def host; end + def url_options; end - sig { params(host: T.untyped).returns(T.untyped) } - def host=(host); end + sig { params(value: T.untyped).returns(T.untyped) } + def url_options=(value); end + end + module GeneratedAttributeMethods sig { returns(T.untyped) } def url_options; end diff --git a/sorbet/rbi/dsl/active_storage/direct_uploads_controller.rbi b/sorbet/rbi/dsl/active_storage/direct_uploads_controller.rbi deleted file mode 100644 index 4c8b34201..000000000 --- a/sorbet/rbi/dsl/active_storage/direct_uploads_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::DirectUploadsController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::DirectUploadsController`. - -class ActiveStorage::DirectUploadsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/disk_controller.rbi b/sorbet/rbi/dsl/active_storage/disk_controller.rbi deleted file mode 100644 index ed4fb1fb2..000000000 --- a/sorbet/rbi/dsl/active_storage/disk_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::DiskController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::DiskController`. - -class ActiveStorage::DiskController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/mirror_job.rbi b/sorbet/rbi/dsl/active_storage/mirror_job.rbi index d8aefeda1..bf0cac6c4 100644 --- a/sorbet/rbi/dsl/active_storage/mirror_job.rbi +++ b/sorbet/rbi/dsl/active_storage/mirror_job.rbi @@ -4,10 +4,17 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::MirrorJob`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::MirrorJob`. + class ActiveStorage::MirrorJob class << self - sig { params(key: T.untyped, checksum: T.untyped).returns(T.any(ActiveStorage::MirrorJob, FalseClass)) } - def perform_later(key, checksum:); end + sig do + params( + key: T.untyped, + checksum: T.untyped, + block: T.nilable(T.proc.params(job: ActiveStorage::MirrorJob).void) + ).returns(T.any(ActiveStorage::MirrorJob, FalseClass)) + end + def perform_later(key, checksum:, &block); end sig { params(key: T.untyped, checksum: T.untyped).returns(T.untyped) } def perform_now(key, checksum:); end diff --git a/sorbet/rbi/dsl/active_storage/preview_image_job.rbi b/sorbet/rbi/dsl/active_storage/preview_image_job.rbi new file mode 100644 index 000000000..59d6f46d0 --- /dev/null +++ b/sorbet/rbi/dsl/active_storage/preview_image_job.rbi @@ -0,0 +1,22 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveStorage::PreviewImageJob`. +# Please instead update this file by running `bin/tapioca dsl ActiveStorage::PreviewImageJob`. + + +class ActiveStorage::PreviewImageJob + class << self + sig do + params( + blob: T.untyped, + variations: T.untyped, + block: T.nilable(T.proc.params(job: ActiveStorage::PreviewImageJob).void) + ).returns(T.any(ActiveStorage::PreviewImageJob, FalseClass)) + end + def perform_later(blob, variations, &block); end + + sig { params(blob: T.untyped, variations: T.untyped).returns(T.untyped) } + def perform_now(blob, variations); end + end +end diff --git a/sorbet/rbi/dsl/active_storage/purge_job.rbi b/sorbet/rbi/dsl/active_storage/purge_job.rbi index 07e3bbba4..bbbc6355b 100644 --- a/sorbet/rbi/dsl/active_storage/purge_job.rbi +++ b/sorbet/rbi/dsl/active_storage/purge_job.rbi @@ -4,10 +4,16 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::PurgeJob`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::PurgeJob`. + class ActiveStorage::PurgeJob class << self - sig { params(blob: T.untyped).returns(T.any(ActiveStorage::PurgeJob, FalseClass)) } - def perform_later(blob); end + sig do + params( + blob: T.untyped, + block: T.nilable(T.proc.params(job: ActiveStorage::PurgeJob).void) + ).returns(T.any(ActiveStorage::PurgeJob, FalseClass)) + end + def perform_later(blob, &block); end sig { params(blob: T.untyped).returns(T.untyped) } def perform_now(blob); end diff --git a/sorbet/rbi/dsl/active_storage/reflection/active_record_extensions.rbi b/sorbet/rbi/dsl/active_storage/reflection/active_record_extensions.rbi index 372891f86..7e6fe684b 100644 --- a/sorbet/rbi/dsl/active_storage/reflection/active_record_extensions.rbi +++ b/sorbet/rbi/dsl/active_storage/reflection/active_record_extensions.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::Reflection::ActiveRecordExtensions`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::Reflection::ActiveRecordExtensions`. + module ActiveStorage::Reflection::ActiveRecordExtensions include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_storage/representations/base_controller.rbi b/sorbet/rbi/dsl/active_storage/representations/base_controller.rbi deleted file mode 100644 index 22feddc38..000000000 --- a/sorbet/rbi/dsl/active_storage/representations/base_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::Representations::BaseController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::Representations::BaseController`. - -class ActiveStorage::Representations::BaseController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/representations/proxy_controller.rbi b/sorbet/rbi/dsl/active_storage/representations/proxy_controller.rbi deleted file mode 100644 index ce450105d..000000000 --- a/sorbet/rbi/dsl/active_storage/representations/proxy_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::Representations::ProxyController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::Representations::ProxyController`. - -class ActiveStorage::Representations::ProxyController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/representations/redirect_controller.rbi b/sorbet/rbi/dsl/active_storage/representations/redirect_controller.rbi deleted file mode 100644 index 5b0692c56..000000000 --- a/sorbet/rbi/dsl/active_storage/representations/redirect_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ActiveStorage::Representations::RedirectController`. -# Please instead update this file by running `bin/tapioca dsl ActiveStorage::Representations::RedirectController`. - -class ActiveStorage::Representations::RedirectController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/active_storage/streaming.rbi b/sorbet/rbi/dsl/active_storage/streaming.rbi index 8d1370c8d..d4a390a49 100644 --- a/sorbet/rbi/dsl/active_storage/streaming.rbi +++ b/sorbet/rbi/dsl/active_storage/streaming.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::Streaming`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::Streaming`. + module ActiveStorage::Streaming mixes_in_class_methods ::ActionController::Rendering::ClassMethods mixes_in_class_methods ::ActionController::Live::ClassMethods diff --git a/sorbet/rbi/dsl/active_storage/transform_job.rbi b/sorbet/rbi/dsl/active_storage/transform_job.rbi new file mode 100644 index 000000000..e7962640a --- /dev/null +++ b/sorbet/rbi/dsl/active_storage/transform_job.rbi @@ -0,0 +1,22 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ActiveStorage::TransformJob`. +# Please instead update this file by running `bin/tapioca dsl ActiveStorage::TransformJob`. + + +class ActiveStorage::TransformJob + class << self + sig do + params( + blob: T.untyped, + transformations: T.untyped, + block: T.nilable(T.proc.params(job: ActiveStorage::TransformJob).void) + ).returns(T.any(ActiveStorage::TransformJob, FalseClass)) + end + def perform_later(blob, transformations, &block); end + + sig { params(blob: T.untyped, transformations: T.untyped).returns(T.untyped) } + def perform_now(blob, transformations); end + end +end diff --git a/sorbet/rbi/dsl/active_storage/variant_record.rbi b/sorbet/rbi/dsl/active_storage/variant_record.rbi index 897fa6a92..12ab74c17 100644 --- a/sorbet/rbi/dsl/active_storage/variant_record.rbi +++ b/sorbet/rbi/dsl/active_storage/variant_record.rbi @@ -4,8 +4,10 @@ # This is an autogenerated file for dynamic methods in `ActiveStorage::VariantRecord`. # Please instead update this file by running `bin/tapioca dsl ActiveStorage::VariantRecord`. + class ActiveStorage::VariantRecord include GeneratedAssociationMethods + include GeneratedAttributeMethods extend CommonRelationMethods extend GeneratedRelationMethods @@ -28,9 +30,20 @@ class ActiveStorage::VariantRecord end def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(::ActiveStorage::VariantRecord) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -39,12 +52,29 @@ class ActiveStorage::VariantRecord end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig do + params( + column_name: NilClass, + block: T.proc.params(object: ::ActiveStorage::VariantRecord).void + ).returns(Integer) + end + def count(column_name = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(::ActiveStorage::VariantRecord) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -53,6 +83,17 @@ class ActiveStorage::VariantRecord end def create(attributes = nil, &block); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(::ActiveStorage::VariantRecord) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -61,6 +102,12 @@ class ActiveStorage::VariantRecord end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -69,6 +116,12 @@ class ActiveStorage::VariantRecord end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -89,8 +142,23 @@ class ActiveStorage::VariantRecord sig { returns(::ActiveStorage::VariantRecord) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ActiveStorage::VariantRecord) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ActiveStorage::VariantRecord]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ActiveStorage::VariantRecord).void + ).returns(T.nilable(::ActiveStorage::VariantRecord)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ActiveStorage::VariantRecord)) } def find_by(*args); end @@ -98,6 +166,54 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped).returns(::ActiveStorage::VariantRecord) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ActiveStorage::VariantRecord).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ActiveStorage::VariantRecord]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ActiveStorage::VariantRecord]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ActiveStorage::VariantRecord]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -106,6 +222,12 @@ class ActiveStorage::VariantRecord end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -114,6 +236,12 @@ class ActiveStorage::VariantRecord end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -131,7 +259,8 @@ class ActiveStorage::VariantRecord sig { params(arg: T.untyped, args: T.untyped).returns(::ActiveStorage::VariantRecord) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::VariantRecord)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::VariantRecord]) } def first(limit = nil); end sig { returns(::ActiveStorage::VariantRecord) } @@ -152,10 +281,36 @@ class ActiveStorage::VariantRecord sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::VariantRecord)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::VariantRecord]) } def last(limit = nil); end sig { returns(::ActiveStorage::VariantRecord) } @@ -177,6 +332,17 @@ class ActiveStorage::VariantRecord sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig do + params( + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(::ActiveStorage::VariantRecord) + end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ActiveStorage::VariantRecord).void) + ).returns(T::Array[::ActiveStorage::VariantRecord]) + end sig do params( attributes: T.untyped, @@ -220,15 +386,18 @@ class ActiveStorage::VariantRecord sig { returns(::ActiveStorage::VariantRecord) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ActiveStorage::VariantRecord).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::VariantRecord)) } + sig { params(limit: Integer).returns(T::Array[::ActiveStorage::VariantRecord]) } def take(limit = nil); end sig { returns(::ActiveStorage::VariantRecord) } @@ -248,59 +417,74 @@ class ActiveStorage::VariantRecord end module GeneratedAssociationMethods - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } def blob; end - sig { params(value: T.untyped).void } + sig { params(value: T.nilable(::ActiveStorage::Blob)).void } def blob=(value); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { returns(T::Boolean) } + def blob_changed?; end + + sig { returns(T::Boolean) } + def blob_previously_changed?; end + + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def build_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } def build_image_attachment(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def build_image_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_blob!(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } def create_image_attachment(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } def create_image_attachment!(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_image_blob(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(T.untyped) } + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } def create_image_blob!(*args, &blk); end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Attachment)) } def image_attachment; end - sig { params(value: T.untyped).void } + sig { params(value: T.nilable(::ActiveStorage::Attachment)).void } def image_attachment=(value); end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } def image_blob; end - sig { params(value: T.untyped).void } + sig { params(value: T.nilable(::ActiveStorage::Blob)).void } def image_blob=(value); end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } def reload_blob; end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Attachment)) } def reload_image_attachment; end - sig { returns(T.untyped) } + sig { returns(T.nilable(::ActiveStorage::Blob)) } def reload_image_blob; end + + sig { void } + def reset_blob; end + + sig { void } + def reset_image_attachment; end + + sig { void } + def reset_image_blob; end end module GeneratedAssociationRelationMethods @@ -316,8 +500,8 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -331,13 +515,13 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -349,40 +533,6 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -407,6 +557,9 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -431,6 +584,9 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -458,34 +614,252 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def with_attached_image(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end + module GeneratedAttributeMethods + sig { returns(::Integer) } + def blob_id; end + + sig { params(value: ::Integer).returns(::Integer) } + def blob_id=(value); end + + sig { returns(T::Boolean) } + def blob_id?; end + + sig { returns(T.nilable(::Integer)) } + def blob_id_before_last_save; end + + sig { returns(T.untyped) } + def blob_id_before_type_cast; end + + sig { returns(T::Boolean) } + def blob_id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def blob_id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def blob_id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def blob_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def blob_id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def blob_id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def blob_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def blob_id_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def blob_id_was; end + + sig { void } + def blob_id_will_change!; end + + sig { returns(::Integer) } + def id; end + + sig { params(value: ::Integer).returns(::Integer) } + def id=(value); end + + sig { returns(T::Boolean) } + def id?; end + + sig { returns(T.nilable(::Integer)) } + def id_before_last_save; end + + sig { returns(T.untyped) } + def id_before_type_cast; end + + sig { returns(T::Boolean) } + def id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_previously_was; end + + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def id_was; end + + sig { void } + def id_will_change!; end + + sig { void } + def restore_blob_id!; end + + sig { void } + def restore_id!; end + + sig { void } + def restore_id_value!; end + + sig { void } + def restore_variation_digest!; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_blob_id; end + + sig { returns(T::Boolean) } + def saved_change_to_blob_id?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id; end + + sig { returns(T::Boolean) } + def saved_change_to_id?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + + sig { returns(T.nilable([::String, ::String])) } + def saved_change_to_variation_digest; end + + sig { returns(T::Boolean) } + def saved_change_to_variation_digest?; end + + sig { returns(::String) } + def variation_digest; end + + sig { params(value: ::String).returns(::String) } + def variation_digest=(value); end + + sig { returns(T::Boolean) } + def variation_digest?; end + + sig { returns(T.nilable(::String)) } + def variation_digest_before_last_save; end + + sig { returns(T.untyped) } + def variation_digest_before_type_cast; end + + sig { returns(T::Boolean) } + def variation_digest_came_from_user?; end + + sig { returns(T.nilable([::String, ::String])) } + def variation_digest_change; end + + sig { returns(T.nilable([::String, ::String])) } + def variation_digest_change_to_be_saved; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def variation_digest_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def variation_digest_in_database; end + + sig { returns(T.nilable([::String, ::String])) } + def variation_digest_previous_change; end + + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def variation_digest_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def variation_digest_previously_was; end + + sig { returns(T.nilable(::String)) } + def variation_digest_was; end + + sig { void } + def variation_digest_will_change!; end + + sig { returns(T::Boolean) } + def will_save_change_to_blob_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + + sig { returns(T::Boolean) } + def will_save_change_to_variation_digest?; end + end + module GeneratedRelationMethods sig { returns(PrivateRelation) } def all; end @@ -499,8 +873,8 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -514,13 +888,13 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -556,6 +930,9 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -580,6 +957,9 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -610,9 +990,15 @@ class ActiveStorage::VariantRecord sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def with_attached_image(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -623,10 +1009,48 @@ class ActiveStorage::VariantRecord Elem = type_member { { fixed: ::ActiveStorage::VariantRecord } } + sig { returns(T::Array[::ActiveStorage::VariantRecord]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::VariantRecord]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ActiveStorage::VariantRecord } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ActiveStorage::VariantRecord } } @@ -670,20 +1094,6 @@ class ActiveStorage::VariantRecord end def concat(*records); end - sig do - params( - records: T.any(::ActiveStorage::VariantRecord, Integer, String, T::Enumerable[T.any(::ActiveStorage::VariantRecord, Integer, String, T::Enumerable[::ActiveStorage::VariantRecord])]) - ).returns(T::Array[::ActiveStorage::VariantRecord]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ActiveStorage::VariantRecord, Integer, String, T::Enumerable[T.any(::ActiveStorage::VariantRecord, Integer, String, T::Enumerable[::ActiveStorage::VariantRecord])]) - ).returns(T::Array[::ActiveStorage::VariantRecord]) - end - def destroy(*records); end - sig { returns(T::Array[::ActiveStorage::VariantRecord]) } def load_target; end @@ -714,6 +1124,9 @@ class ActiveStorage::VariantRecord sig { returns(T::Array[::ActiveStorage::VariantRecord]) } def target; end + sig { returns(T::Array[::ActiveStorage::VariantRecord]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::VariantRecord]) } def to_ary; end end @@ -724,10 +1137,48 @@ class ActiveStorage::VariantRecord Elem = type_member { { fixed: ::ActiveStorage::VariantRecord } } + sig { returns(T::Array[::ActiveStorage::VariantRecord]) } + def to_a; end + sig { returns(T::Array[::ActiveStorage::VariantRecord]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ActiveStorage::VariantRecord } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ActiveStorage::VariantRecord } } diff --git a/sorbet/rbi/dsl/active_support/actionable_error.rbi b/sorbet/rbi/dsl/active_support/actionable_error.rbi index a79d2b320..64b88fa85 100644 --- a/sorbet/rbi/dsl/active_support/actionable_error.rbi +++ b/sorbet/rbi/dsl/active_support/actionable_error.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveSupport::ActionableError`. # Please instead update this file by running `bin/tapioca dsl ActiveSupport::ActionableError`. + module ActiveSupport::ActionableError include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_support/callbacks.rbi b/sorbet/rbi/dsl/active_support/callbacks.rbi index 646f9950b..4c1ad1358 100644 --- a/sorbet/rbi/dsl/active_support/callbacks.rbi +++ b/sorbet/rbi/dsl/active_support/callbacks.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveSupport::Callbacks`. # Please instead update this file by running `bin/tapioca dsl ActiveSupport::Callbacks`. + module ActiveSupport::Callbacks include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_support/rescuable.rbi b/sorbet/rbi/dsl/active_support/rescuable.rbi index 793108da9..cf65f829e 100644 --- a/sorbet/rbi/dsl/active_support/rescuable.rbi +++ b/sorbet/rbi/dsl/active_support/rescuable.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveSupport::Rescuable`. # Please instead update this file by running `bin/tapioca dsl ActiveSupport::Rescuable`. + module ActiveSupport::Rescuable include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/active_support/testing/file_fixtures.rbi b/sorbet/rbi/dsl/active_support/testing/file_fixtures.rbi index 0bdaa8be1..ba004cf53 100644 --- a/sorbet/rbi/dsl/active_support/testing/file_fixtures.rbi +++ b/sorbet/rbi/dsl/active_support/testing/file_fixtures.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ActiveSupport::Testing::FileFixtures`. # Please instead update this file by running `bin/tapioca dsl ActiveSupport::Testing::FileFixtures`. + module ActiveSupport::Testing::FileFixtures include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/allow_reservation_player_worker.rbi b/sorbet/rbi/dsl/allow_reservation_player_worker.rbi index 2c5c12840..19c06abd7 100644 --- a/sorbet/rbi/dsl/allow_reservation_player_worker.rbi +++ b/sorbet/rbi/dsl/allow_reservation_player_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AllowReservationPlayerWorker`. # Please instead update this file by running `bin/tapioca dsl AllowReservationPlayerWorker`. + class AllowReservationPlayerWorker class << self sig { params(reservation_player_id: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/announce_donator_worker.rbi b/sorbet/rbi/dsl/announce_donator_worker.rbi index bdb71ccfc..60ab16647 100644 --- a/sorbet/rbi/dsl/announce_donator_worker.rbi +++ b/sorbet/rbi/dsl/announce_donator_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `AnnounceDonatorWorker`. # Please instead update this file by running `bin/tapioca dsl AnnounceDonatorWorker`. + class AnnounceDonatorWorker class << self sig { params(nickname: T.untyped, product_name: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/api/application_controller.rbi b/sorbet/rbi/dsl/api/application_controller.rbi index 95e042006..88996b8d7 100644 --- a/sorbet/rbi/dsl/api/application_controller.rbi +++ b/sorbet/rbi/dsl/api/application_controller.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Api::ApplicationController`. # Please instead update this file by running `bin/tapioca dsl Api::ApplicationController`. + class Api::ApplicationController include GeneratedUrlHelpersModule include GeneratedPathHelpersModule diff --git a/sorbet/rbi/dsl/api/donators_controller.rbi b/sorbet/rbi/dsl/api/donators_controller.rbi deleted file mode 100644 index b3fdb5e00..000000000 --- a/sorbet/rbi/dsl/api/donators_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Api::DonatorsController`. -# Please instead update this file by running `bin/tapioca dsl Api::DonatorsController`. - -class Api::DonatorsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/api/league_requests_controller.rbi b/sorbet/rbi/dsl/api/league_requests_controller.rbi deleted file mode 100644 index 660eee45a..000000000 --- a/sorbet/rbi/dsl/api/league_requests_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Api::LeagueRequestsController`. -# Please instead update this file by running `bin/tapioca dsl Api::LeagueRequestsController`. - -class Api::LeagueRequestsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/api/maps_controller.rbi b/sorbet/rbi/dsl/api/maps_controller.rbi deleted file mode 100644 index ab6a37434..000000000 --- a/sorbet/rbi/dsl/api/maps_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Api::MapsController`. -# Please instead update this file by running `bin/tapioca dsl Api::MapsController`. - -class Api::MapsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/api/reservations_controller.rbi b/sorbet/rbi/dsl/api/reservations_controller.rbi deleted file mode 100644 index 0eb5106f5..000000000 --- a/sorbet/rbi/dsl/api/reservations_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Api::ReservationsController`. -# Please instead update this file by running `bin/tapioca dsl Api::ReservationsController`. - -class Api::ReservationsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/api/servers_controller.rbi b/sorbet/rbi/dsl/api/servers_controller.rbi deleted file mode 100644 index f24bf7ca4..000000000 --- a/sorbet/rbi/dsl/api/servers_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Api::ServersController`. -# Please instead update this file by running `bin/tapioca dsl Api::ServersController`. - -class Api::ServersController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/api/users_controller.rbi b/sorbet/rbi/dsl/api/users_controller.rbi deleted file mode 100644 index 4d5aada3d..000000000 --- a/sorbet/rbi/dsl/api/users_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Api::UsersController`. -# Please instead update this file by running `bin/tapioca dsl Api::UsersController`. - -class Api::UsersController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/application_controller.rbi b/sorbet/rbi/dsl/application_controller.rbi index 8835e39d2..2dac82301 100644 --- a/sorbet/rbi/dsl/application_controller.rbi +++ b/sorbet/rbi/dsl/application_controller.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ApplicationController`. # Please instead update this file by running `bin/tapioca dsl ApplicationController`. + class ApplicationController include GeneratedUrlHelpersModule include GeneratedPathHelpersModule @@ -41,6 +42,9 @@ class ApplicationController sig { returns(T.untyped) } def current_streamer; end + sig { returns(T.untyped) } + def current_trusted_api; end + sig { returns(T.untyped) } def time_zone_from_cookie; end end diff --git a/sorbet/rbi/dsl/available_maps_worker.rbi b/sorbet/rbi/dsl/available_maps_worker.rbi new file mode 100644 index 000000000..4dd17f6e5 --- /dev/null +++ b/sorbet/rbi/dsl/available_maps_worker.rbi @@ -0,0 +1,19 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `AvailableMapsWorker`. +# Please instead update this file by running `bin/tapioca dsl AvailableMapsWorker`. + + +class AvailableMapsWorker + class << self + sig { returns(String) } + def perform_async; end + + sig { params(interval: T.any(DateTime, Time)).returns(String) } + def perform_at(interval); end + + sig { params(interval: Numeric).returns(String) } + def perform_in(interval); end + end +end diff --git a/sorbet/rbi/dsl/carrier_wave/compatibility/paperclip.rbi b/sorbet/rbi/dsl/carrier_wave/compatibility/paperclip.rbi index 3838fec5c..a65c9063a 100644 --- a/sorbet/rbi/dsl/carrier_wave/compatibility/paperclip.rbi +++ b/sorbet/rbi/dsl/carrier_wave/compatibility/paperclip.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Compatibility::Paperclip`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Compatibility::Paperclip`. + module CarrierWave::Compatibility::Paperclip include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/cache.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/cache.rbi index 132327a46..e3584b1f2 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/cache.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/cache.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Cache`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Cache`. + module CarrierWave::Uploader::Cache include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/callbacks.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/callbacks.rbi index 3639fa0da..67d4f434c 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/callbacks.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/callbacks.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Callbacks`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Callbacks`. + module CarrierWave::Uploader::Callbacks include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/configuration.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/configuration.rbi index dba63dc24..0a507343d 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/configuration.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/configuration.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Configuration`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Configuration`. + module CarrierWave::Uploader::Configuration include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/download.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/download.rbi index c2499cd59..4312174eb 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/download.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/download.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Download`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Download`. + module CarrierWave::Uploader::Download include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/processing.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/processing.rbi index 40aa7b26a..91d2dc6eb 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/processing.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/processing.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Processing`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Processing`. + module CarrierWave::Uploader::Processing include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/remove.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/remove.rbi index 26c68b20f..1e24b5add 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/remove.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/remove.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Remove`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Remove`. + module CarrierWave::Uploader::Remove include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/store.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/store.rbi index 16b93b893..5f65f6132 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/store.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/store.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Store`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Store`. + module CarrierWave::Uploader::Store include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/url.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/url.rbi index 1a53f7aee..ae0683e46 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/url.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/url.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Url`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Url`. + module CarrierWave::Uploader::Url include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/carrier_wave/uploader/versions.rbi b/sorbet/rbi/dsl/carrier_wave/uploader/versions.rbi index 8fe4ee84e..d4b9e33d0 100644 --- a/sorbet/rbi/dsl/carrier_wave/uploader/versions.rbi +++ b/sorbet/rbi/dsl/carrier_wave/uploader/versions.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CarrierWave::Uploader::Versions`. # Please instead update this file by running `bin/tapioca dsl CarrierWave::Uploader::Versions`. + module CarrierWave::Uploader::Versions include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/cleanup_worker.rbi b/sorbet/rbi/dsl/cleanup_worker.rbi index 1c10fce45..5b0c05834 100644 --- a/sorbet/rbi/dsl/cleanup_worker.rbi +++ b/sorbet/rbi/dsl/cleanup_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CleanupWorker`. # Please instead update this file by running `bin/tapioca dsl CleanupWorker`. + class CleanupWorker class << self sig { returns(String) } diff --git a/sorbet/rbi/dsl/cron_worker.rbi b/sorbet/rbi/dsl/cron_worker.rbi index 3af6b8d2d..79d877adf 100644 --- a/sorbet/rbi/dsl/cron_worker.rbi +++ b/sorbet/rbi/dsl/cron_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `CronWorker`. # Please instead update this file by running `bin/tapioca dsl CronWorker`. + class CronWorker class << self sig { returns(String) } diff --git a/sorbet/rbi/dsl/devise/confirmations_controller.rbi b/sorbet/rbi/dsl/devise/confirmations_controller.rbi deleted file mode 100644 index 8d9313fae..000000000 --- a/sorbet/rbi/dsl/devise/confirmations_controller.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Devise::ConfirmationsController`. -# Please instead update this file by running `bin/tapioca dsl Devise::ConfirmationsController`. - -class Devise::ConfirmationsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - include ::ApplicationController::HelperMethods - - sig { returns(T.untyped) } - def devise_mapping; end - - sig { returns(T.untyped) } - def resource; end - - sig { returns(T.untyped) } - def resource_class; end - - sig { returns(T.untyped) } - def resource_name; end - - sig { returns(T.untyped) } - def resource_params; end - - sig { returns(T.untyped) } - def scope_name; end - - sig { returns(T.untyped) } - def signed_in_resource; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/devise/failure_app.rbi b/sorbet/rbi/dsl/devise/failure_app.rbi index cce499662..95acf101b 100644 --- a/sorbet/rbi/dsl/devise/failure_app.rbi +++ b/sorbet/rbi/dsl/devise/failure_app.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Devise::FailureApp`. # Please instead update this file by running `bin/tapioca dsl Devise::FailureApp`. + class Devise::FailureApp include GeneratedUrlHelpersModule include GeneratedPathHelpersModule diff --git a/sorbet/rbi/dsl/devise/mailer.rbi b/sorbet/rbi/dsl/devise/mailer.rbi index 09d98b3ee..561f55dba 100644 --- a/sorbet/rbi/dsl/devise/mailer.rbi +++ b/sorbet/rbi/dsl/devise/mailer.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Devise::Mailer`. # Please instead update this file by running `bin/tapioca dsl Devise::Mailer`. + class Devise::Mailer include GeneratedUrlHelpersModule diff --git a/sorbet/rbi/dsl/devise/models/authenticatable.rbi b/sorbet/rbi/dsl/devise/models/authenticatable.rbi index 8b53d644b..a6401356b 100644 --- a/sorbet/rbi/dsl/devise/models/authenticatable.rbi +++ b/sorbet/rbi/dsl/devise/models/authenticatable.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Devise::Models::Authenticatable`. # Please instead update this file by running `bin/tapioca dsl Devise::Models::Authenticatable`. + module Devise::Models::Authenticatable include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/devise/omniauth_callbacks_controller.rbi b/sorbet/rbi/dsl/devise/omniauth_callbacks_controller.rbi deleted file mode 100644 index 7fd7cf007..000000000 --- a/sorbet/rbi/dsl/devise/omniauth_callbacks_controller.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Devise::OmniauthCallbacksController`. -# Please instead update this file by running `bin/tapioca dsl Devise::OmniauthCallbacksController`. - -class Devise::OmniauthCallbacksController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - include ::ApplicationController::HelperMethods - - sig { returns(T.untyped) } - def devise_mapping; end - - sig { returns(T.untyped) } - def resource; end - - sig { returns(T.untyped) } - def resource_class; end - - sig { returns(T.untyped) } - def resource_name; end - - sig { returns(T.untyped) } - def resource_params; end - - sig { returns(T.untyped) } - def scope_name; end - - sig { returns(T.untyped) } - def signed_in_resource; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/devise/passwords_controller.rbi b/sorbet/rbi/dsl/devise/passwords_controller.rbi deleted file mode 100644 index e6a00b4cb..000000000 --- a/sorbet/rbi/dsl/devise/passwords_controller.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Devise::PasswordsController`. -# Please instead update this file by running `bin/tapioca dsl Devise::PasswordsController`. - -class Devise::PasswordsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - include ::ApplicationController::HelperMethods - - sig { returns(T.untyped) } - def devise_mapping; end - - sig { returns(T.untyped) } - def resource; end - - sig { returns(T.untyped) } - def resource_class; end - - sig { returns(T.untyped) } - def resource_name; end - - sig { returns(T.untyped) } - def resource_params; end - - sig { returns(T.untyped) } - def scope_name; end - - sig { returns(T.untyped) } - def signed_in_resource; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/devise/registrations_controller.rbi b/sorbet/rbi/dsl/devise/registrations_controller.rbi deleted file mode 100644 index 7c16344c4..000000000 --- a/sorbet/rbi/dsl/devise/registrations_controller.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Devise::RegistrationsController`. -# Please instead update this file by running `bin/tapioca dsl Devise::RegistrationsController`. - -class Devise::RegistrationsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - include ::ApplicationController::HelperMethods - - sig { returns(T.untyped) } - def devise_mapping; end - - sig { returns(T.untyped) } - def resource; end - - sig { returns(T.untyped) } - def resource_class; end - - sig { returns(T.untyped) } - def resource_name; end - - sig { returns(T.untyped) } - def resource_params; end - - sig { returns(T.untyped) } - def scope_name; end - - sig { returns(T.untyped) } - def signed_in_resource; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/devise/sessions_controller.rbi b/sorbet/rbi/dsl/devise/sessions_controller.rbi deleted file mode 100644 index 80469b6e6..000000000 --- a/sorbet/rbi/dsl/devise/sessions_controller.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Devise::SessionsController`. -# Please instead update this file by running `bin/tapioca dsl Devise::SessionsController`. - -class Devise::SessionsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - include ::ApplicationController::HelperMethods - - sig { returns(T.untyped) } - def devise_mapping; end - - sig { returns(T.untyped) } - def resource; end - - sig { returns(T.untyped) } - def resource_class; end - - sig { returns(T.untyped) } - def resource_name; end - - sig { returns(T.untyped) } - def resource_params; end - - sig { returns(T.untyped) } - def scope_name; end - - sig { returns(T.untyped) } - def signed_in_resource; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/devise/unlocks_controller.rbi b/sorbet/rbi/dsl/devise/unlocks_controller.rbi deleted file mode 100644 index 86ec5e05d..000000000 --- a/sorbet/rbi/dsl/devise/unlocks_controller.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Devise::UnlocksController`. -# Please instead update this file by running `bin/tapioca dsl Devise::UnlocksController`. - -class Devise::UnlocksController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - include ::ApplicationController::HelperMethods - - sig { returns(T.untyped) } - def devise_mapping; end - - sig { returns(T.untyped) } - def resource; end - - sig { returns(T.untyped) } - def resource_class; end - - sig { returns(T.untyped) } - def resource_name; end - - sig { returns(T.untyped) } - def resource_params; end - - sig { returns(T.untyped) } - def scope_name; end - - sig { returns(T.untyped) } - def signed_in_resource; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/devise_controller.rbi b/sorbet/rbi/dsl/devise_controller.rbi index 60578604e..a2f5fa7b8 100644 --- a/sorbet/rbi/dsl/devise_controller.rbi +++ b/sorbet/rbi/dsl/devise_controller.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `DeviseController`. # Please instead update this file by running `bin/tapioca dsl DeviseController`. + class DeviseController sig { returns(HelperProxy) } def helpers; end diff --git a/sorbet/rbi/dsl/disable_mitigations_worker.rbi b/sorbet/rbi/dsl/disable_mitigations_worker.rbi index 39a9c43d1..e69fcdfe3 100644 --- a/sorbet/rbi/dsl/disable_mitigations_worker.rbi +++ b/sorbet/rbi/dsl/disable_mitigations_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `DisableMitigationsWorker`. # Please instead update this file by running `bin/tapioca dsl DisableMitigationsWorker`. + class DisableMitigationsWorker class << self sig { params(reservation_id: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/donators_controller.rbi b/sorbet/rbi/dsl/donators_controller.rbi deleted file mode 100644 index 163d38600..000000000 --- a/sorbet/rbi/dsl/donators_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `DonatorsController`. -# Please instead update this file by running `bin/tapioca dsl DonatorsController`. - -class DonatorsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/file_upload.rbi b/sorbet/rbi/dsl/file_upload.rbi index c9becc66a..e7335e09e 100644 --- a/sorbet/rbi/dsl/file_upload.rbi +++ b/sorbet/rbi/dsl/file_upload.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `FileUpload`. # Please instead update this file by running `bin/tapioca dsl FileUpload`. + class FileUpload include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class FileUpload sig { params(block: T.nilable(T.proc.params(record: ::FileUpload).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::FileUpload).void)).returns(::FileUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class FileUpload end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::FileUpload).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::FileUpload).void)).returns(::FileUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class FileUpload end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::FileUpload).void)).returns(::FileUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class FileUpload end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class FileUpload end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class FileUpload sig { returns(::FileUpload) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::FileUpload) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::FileUpload]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::FileUpload).void).returns(T.nilable(::FileUpload)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::FileUpload)) } def find_by(*args); end @@ -89,6 +134,54 @@ class FileUpload sig { params(args: T.untyped).returns(::FileUpload) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::FileUpload).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::FileUpload]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::FileUpload]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::FileUpload]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class FileUpload end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class FileUpload end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class FileUpload sig { params(arg: T.untyped, args: T.untyped).returns(::FileUpload) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::FileUpload)) } + sig { params(limit: Integer).returns(T::Array[::FileUpload]) } def first(limit = nil); end sig { returns(::FileUpload) } @@ -143,10 +249,36 @@ class FileUpload sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::FileUpload)) } + sig { params(limit: Integer).returns(T::Array[::FileUpload]) } def last(limit = nil); end sig { returns(::FileUpload) } @@ -164,6 +296,13 @@ class FileUpload sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::FileUpload).void)).returns(::FileUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::FileUpload).void) + ).returns(T::Array[::FileUpload]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class FileUpload sig { returns(::FileUpload) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::FileUpload).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::FileUpload)) } + sig { params(limit: Integer).returns(T::Array[::FileUpload]) } def take(limit = nil); end sig { returns(::FileUpload) } @@ -239,6 +381,9 @@ class FileUpload sig { returns(T.nilable(::User)) } def reload_user; end + sig { void } + def reset_user; end + sig { returns(T::Array[T.untyped]) } def server_ids; end @@ -272,6 +417,12 @@ class FileUpload sig { params(value: T.nilable(::User)).void } def user=(value); end + + sig { returns(T::Boolean) } + def user_changed?; end + + sig { returns(T::Boolean) } + def user_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -287,8 +438,8 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -302,13 +453,13 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -320,40 +471,6 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -378,6 +495,9 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -402,6 +522,9 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -429,33 +552,21 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end module GeneratedAttributeMethods - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + sig { returns(::ActiveSupport::TimeWithZone) } def created_at; end sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } @@ -473,23 +584,23 @@ class FileUpload sig { returns(T::Boolean) } def created_at_came_from_user?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_change; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -524,8 +635,8 @@ class FileUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_change_to_be_saved; end - sig { returns(T::Boolean) } - def file_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_in_database; end @@ -533,8 +644,8 @@ class FileUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_previous_change; end - sig { returns(T::Boolean) } - def file_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_previously_was; end @@ -545,7 +656,7 @@ class FileUpload sig { void } def file_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -563,27 +674,72 @@ class FileUpload sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -599,13 +755,16 @@ class FileUpload sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_updated_at!; end sig { void } def restore_user_id!; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def saved_change_to_created_at; end sig { returns(T::Boolean) } @@ -617,13 +776,19 @@ class FileUpload sig { returns(T::Boolean) } def saved_change_to_file?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def saved_change_to_updated_at; end sig { returns(T::Boolean) } @@ -635,7 +800,7 @@ class FileUpload sig { returns(T::Boolean) } def saved_change_to_user_id?; end - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + sig { returns(::ActiveSupport::TimeWithZone) } def updated_at; end sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } @@ -653,23 +818,23 @@ class FileUpload sig { returns(T::Boolean) } def updated_at_came_from_user?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_change; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -704,8 +869,8 @@ class FileUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def user_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_in_database; end @@ -713,8 +878,8 @@ class FileUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_previous_change; end - sig { returns(T::Boolean) } - def user_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_previously_was; end @@ -734,6 +899,9 @@ class FileUpload sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_updated_at?; end @@ -754,8 +922,8 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -769,13 +937,13 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -811,6 +979,9 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -835,6 +1006,9 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -865,6 +1039,12 @@ class FileUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -875,10 +1055,48 @@ class FileUpload Elem = type_member { { fixed: ::FileUpload } } + sig { returns(T::Array[::FileUpload]) } + def to_a; end + sig { returns(T::Array[::FileUpload]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::FileUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::FileUpload } } @@ -922,20 +1140,6 @@ class FileUpload end def concat(*records); end - sig do - params( - records: T.any(::FileUpload, Integer, String, T::Enumerable[T.any(::FileUpload, Integer, String, T::Enumerable[::FileUpload])]) - ).returns(T::Array[::FileUpload]) - end - def delete(*records); end - - sig do - params( - records: T.any(::FileUpload, Integer, String, T::Enumerable[T.any(::FileUpload, Integer, String, T::Enumerable[::FileUpload])]) - ).returns(T::Array[::FileUpload]) - end - def destroy(*records); end - sig { returns(T::Array[::FileUpload]) } def load_target; end @@ -966,6 +1170,9 @@ class FileUpload sig { returns(T::Array[::FileUpload]) } def target; end + sig { returns(T::Array[::FileUpload]) } + def to_a; end + sig { returns(T::Array[::FileUpload]) } def to_ary; end end @@ -976,10 +1183,48 @@ class FileUpload Elem = type_member { { fixed: ::FileUpload } } + sig { returns(T::Array[::FileUpload]) } + def to_a; end + sig { returns(T::Array[::FileUpload]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::FileUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::FileUpload } } diff --git a/sorbet/rbi/dsl/file_uploads_controller.rbi b/sorbet/rbi/dsl/file_uploads_controller.rbi deleted file mode 100644 index c0f34ac25..000000000 --- a/sorbet/rbi/dsl/file_uploads_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `FileUploadsController`. -# Please instead update this file by running `bin/tapioca dsl FileUploadsController`. - -class FileUploadsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/generated_path_helpers_module.rbi b/sorbet/rbi/dsl/generated_path_helpers_module.rbi index db9e3382a..ff3be1cbe 100644 --- a/sorbet/rbi/dsl/generated_path_helpers_module.rbi +++ b/sorbet/rbi/dsl/generated_path_helpers_module.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `GeneratedPathHelpersModule`. # Please instead update this file by running `bin/tapioca dsl GeneratedPathHelpersModule`. + module GeneratedPathHelpersModule include ::ActionDispatch::Routing::UrlFor include ::ActionDispatch::Routing::PolymorphicRoutes @@ -60,10 +61,10 @@ module GeneratedPathHelpersModule def edit_page_path(*args); end sig { params(args: T.untyped).returns(String) } - def edit_rails_conductor_inbound_email_path(*args); end + def edit_reservation_path(*args); end sig { params(args: T.untyped).returns(String) } - def edit_reservation_path(*args); end + def edit_server_config_path(*args); end sig { params(args: T.untyped).returns(String) } def edit_server_path(*args); end @@ -80,6 +81,9 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def edit_voucher_path(*args); end + sig { params(args: T.untyped).returns(String) } + def edit_whitelist_path(*args); end + sig { params(args: T.untyped).returns(String) } def extend_api_reservation_path(*args); end @@ -110,6 +114,9 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def find_servers_for_user_reservations_path(*args); end + sig { params(args: T.untyped).returns(String) } + def force_update_server_path(*args); end + sig { params(args: T.untyped).returns(String) } def i_am_feeling_lucky_reservations_path(*args); end @@ -125,9 +132,24 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def login_path(*args); end + sig { params(args: T.untyped).returns(String) } + def map_upload_path(*args); end + sig { params(args: T.untyped).returns(String) } def map_uploads_path(*args); end + sig { params(args: T.untyped).returns(String) } + def maps_path(*args); end + + sig { params(args: T.untyped).returns(String) } + def maps_sorted_path(*args); end + + sig { params(args: T.untyped).returns(String) } + def motd_rcon_command_reservation_path(*args); end + + sig { params(args: T.untyped).returns(String) } + def motd_reservation_path(*args); end + sig { params(args: T.untyped).returns(String) } def new_api_donator_path(*args); end @@ -149,18 +171,15 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def new_page_path(*args); end - sig { params(args: T.untyped).returns(String) } - def new_rails_conductor_inbound_email_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def new_rails_conductor_inbound_email_source_path(*args); end - sig { params(args: T.untyped).returns(String) } def new_reservation_log_upload_path(*args); end sig { params(args: T.untyped).returns(String) } def new_reservation_path(*args); end + sig { params(args: T.untyped).returns(String) } + def new_server_config_path(*args); end + sig { params(args: T.untyped).returns(String) } def new_server_path(*args); end @@ -173,6 +192,9 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def new_voucher_path(*args); end + sig { params(args: T.untyped).returns(String) } + def new_whitelist_path(*args); end + sig { params(args: T.untyped).returns(String) } def no_to_war_path(*args); end @@ -212,21 +234,6 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def rails_blob_representation_proxy_path(*args); end - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_incinerate_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_reroute_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_sources_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_emails_path(*args); end - sig { params(args: T.untyped).returns(String) } def rails_direct_uploads_path(*args); end @@ -245,27 +252,9 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def rails_mailers_path(*args); end - sig { params(args: T.untyped).returns(String) } - def rails_mailgun_inbound_emails_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_mandrill_inbound_emails_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_mandrill_inbound_health_check_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_postmark_inbound_emails_path(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_relay_inbound_emails_path(*args); end - sig { params(args: T.untyped).returns(String) } def rails_representation_path(*args); end - sig { params(args: T.untyped).returns(String) } - def rails_sendgrid_inbound_emails_path(*args); end - sig { params(args: T.untyped).returns(String) } def rails_service_blob_path(*args); end @@ -305,9 +294,18 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def reservations_path(*args); end + sig { params(args: T.untyped).returns(String) } + def restart_server_path(*args); end + sig { params(args: T.untyped).returns(String) } def root_path(*args); end + sig { params(args: T.untyped).returns(String) } + def server_config_path(*args); end + + sig { params(args: T.untyped).returns(String) } + def server_configs_path(*args); end + sig { params(args: T.untyped).returns(String) } def server_path(*args); end @@ -353,6 +351,9 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def show_reservation_statistic_path(*args); end + sig { params(args: T.untyped).returns(String) } + def show_sdr_path(*args); end + sig { params(args: T.untyped).returns(String) } def show_server_ip_player_statistic_path(*args); end @@ -365,6 +366,12 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def sidekiq_web_path(*args); end + sig { params(args: T.untyped).returns(String) } + def stac_log_path(*args); end + + sig { params(args: T.untyped).returns(String) } + def stac_logs_path(*args); end + sig { params(args: T.untyped).returns(String) } def statistics_pages_path(*args); end @@ -407,6 +414,9 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def upload_map_path(*args); end + sig { params(args: T.untyped).returns(String) } + def upload_path(*args); end + sig { params(args: T.untyped).returns(String) } def user_path(*args); end @@ -425,6 +435,12 @@ module GeneratedPathHelpersModule sig { params(args: T.untyped).returns(String) } def vouchers_path(*args); end + sig { params(args: T.untyped).returns(String) } + def whitelist_path(*args); end + + sig { params(args: T.untyped).returns(String) } + def whitelists_path(*args); end + sig { params(args: T.untyped).returns(String) } def your_reservations_path(*args); end end diff --git a/sorbet/rbi/dsl/generated_url_helpers_module.rbi b/sorbet/rbi/dsl/generated_url_helpers_module.rbi index f218ee3f2..895bd0152 100644 --- a/sorbet/rbi/dsl/generated_url_helpers_module.rbi +++ b/sorbet/rbi/dsl/generated_url_helpers_module.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `GeneratedUrlHelpersModule`. # Please instead update this file by running `bin/tapioca dsl GeneratedUrlHelpersModule`. + module GeneratedUrlHelpersModule include ::ActionDispatch::Routing::UrlFor include ::ActionDispatch::Routing::PolymorphicRoutes @@ -60,10 +61,10 @@ module GeneratedUrlHelpersModule def edit_page_url(*args); end sig { params(args: T.untyped).returns(String) } - def edit_rails_conductor_inbound_email_url(*args); end + def edit_reservation_url(*args); end sig { params(args: T.untyped).returns(String) } - def edit_reservation_url(*args); end + def edit_server_config_url(*args); end sig { params(args: T.untyped).returns(String) } def edit_server_url(*args); end @@ -80,6 +81,9 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def edit_voucher_url(*args); end + sig { params(args: T.untyped).returns(String) } + def edit_whitelist_url(*args); end + sig { params(args: T.untyped).returns(String) } def extend_api_reservation_url(*args); end @@ -110,6 +114,9 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def find_servers_for_user_reservations_url(*args); end + sig { params(args: T.untyped).returns(String) } + def force_update_server_url(*args); end + sig { params(args: T.untyped).returns(String) } def i_am_feeling_lucky_reservations_url(*args); end @@ -125,9 +132,24 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def login_url(*args); end + sig { params(args: T.untyped).returns(String) } + def map_upload_url(*args); end + sig { params(args: T.untyped).returns(String) } def map_uploads_url(*args); end + sig { params(args: T.untyped).returns(String) } + def maps_sorted_url(*args); end + + sig { params(args: T.untyped).returns(String) } + def maps_url(*args); end + + sig { params(args: T.untyped).returns(String) } + def motd_rcon_command_reservation_url(*args); end + + sig { params(args: T.untyped).returns(String) } + def motd_reservation_url(*args); end + sig { params(args: T.untyped).returns(String) } def new_api_donator_url(*args); end @@ -149,18 +171,15 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def new_page_url(*args); end - sig { params(args: T.untyped).returns(String) } - def new_rails_conductor_inbound_email_source_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def new_rails_conductor_inbound_email_url(*args); end - sig { params(args: T.untyped).returns(String) } def new_reservation_log_upload_url(*args); end sig { params(args: T.untyped).returns(String) } def new_reservation_url(*args); end + sig { params(args: T.untyped).returns(String) } + def new_server_config_url(*args); end + sig { params(args: T.untyped).returns(String) } def new_server_url(*args); end @@ -173,6 +192,9 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def new_voucher_url(*args); end + sig { params(args: T.untyped).returns(String) } + def new_whitelist_url(*args); end + sig { params(args: T.untyped).returns(String) } def no_to_war_url(*args); end @@ -212,21 +234,6 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def rails_blob_url(*args); end - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_incinerate_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_reroute_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_sources_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_email_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_conductor_inbound_emails_url(*args); end - sig { params(args: T.untyped).returns(String) } def rails_direct_uploads_url(*args); end @@ -245,27 +252,9 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def rails_mailers_url(*args); end - sig { params(args: T.untyped).returns(String) } - def rails_mailgun_inbound_emails_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_mandrill_inbound_emails_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_mandrill_inbound_health_check_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_postmark_inbound_emails_url(*args); end - - sig { params(args: T.untyped).returns(String) } - def rails_relay_inbound_emails_url(*args); end - sig { params(args: T.untyped).returns(String) } def rails_representation_url(*args); end - sig { params(args: T.untyped).returns(String) } - def rails_sendgrid_inbound_emails_url(*args); end - sig { params(args: T.untyped).returns(String) } def rails_service_blob_proxy_url(*args); end @@ -305,9 +294,18 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def reservations_url(*args); end + sig { params(args: T.untyped).returns(String) } + def restart_server_url(*args); end + sig { params(args: T.untyped).returns(String) } def root_url(*args); end + sig { params(args: T.untyped).returns(String) } + def server_config_url(*args); end + + sig { params(args: T.untyped).returns(String) } + def server_configs_url(*args); end + sig { params(args: T.untyped).returns(String) } def server_providers_pages_url(*args); end @@ -353,6 +351,9 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def show_reservation_statistic_url(*args); end + sig { params(args: T.untyped).returns(String) } + def show_sdr_url(*args); end + sig { params(args: T.untyped).returns(String) } def show_server_ip_player_statistic_url(*args); end @@ -365,6 +366,12 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def sidekiq_web_url(*args); end + sig { params(args: T.untyped).returns(String) } + def stac_log_url(*args); end + + sig { params(args: T.untyped).returns(String) } + def stac_logs_url(*args); end + sig { params(args: T.untyped).returns(String) } def statistics_pages_url(*args); end @@ -407,6 +414,9 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def upload_map_url(*args); end + sig { params(args: T.untyped).returns(String) } + def upload_url(*args); end + sig { params(args: T.untyped).returns(String) } def user_url(*args); end @@ -425,6 +435,12 @@ module GeneratedUrlHelpersModule sig { params(args: T.untyped).returns(String) } def vouchers_url(*args); end + sig { params(args: T.untyped).returns(String) } + def whitelist_url(*args); end + + sig { params(args: T.untyped).returns(String) } + def whitelists_url(*args); end + sig { params(args: T.untyped).returns(String) } def your_reservations_url(*args); end end diff --git a/sorbet/rbi/dsl/group.rbi b/sorbet/rbi/dsl/group.rbi index 0ec2b6138..84e22e1ae 100644 --- a/sorbet/rbi/dsl/group.rbi +++ b/sorbet/rbi/dsl/group.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Group`. # Please instead update this file by running `bin/tapioca dsl Group`. + class Group include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,27 +20,61 @@ class Group sig { params(block: T.nilable(T.proc.params(record: ::Group).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Group).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def create_or_find_by!(attributes, &block); end @@ -55,8 +90,18 @@ class Group sig { returns(::Group) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Group) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Group]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Group).void).returns(T.nilable(::Group)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Group)) } def find_by(*args); end @@ -64,12 +109,72 @@ class Group sig { params(args: T.untyped).returns(::Group) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Group).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Group]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Group]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Group]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def find_or_initialize_by(attributes, &block); end @@ -82,7 +187,8 @@ class Group sig { params(arg: T.untyped, args: T.untyped).returns(::Group) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Group)) } + sig { params(limit: Integer).returns(T::Array[::Group]) } def first(limit = nil); end sig { returns(::Group) } @@ -103,10 +209,36 @@ class Group sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Group)) } + sig { params(limit: Integer).returns(T::Array[::Group]) } def last(limit = nil); end sig { returns(::Group) } @@ -124,6 +256,13 @@ class Group sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Group).void) + ).returns(T::Array[::Group]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Group).void)).returns(::Group) } def new(attributes = nil, &block); end @@ -154,15 +293,18 @@ class Group sig { returns(::Group) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Group).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Group)) } + sig { params(limit: Integer).returns(T::Array[::Group]) } def take(limit = nil); end sig { returns(::Group) } @@ -252,8 +394,8 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -267,13 +409,13 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -285,40 +427,6 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -343,6 +451,9 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -367,6 +478,9 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -394,27 +508,15 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -444,8 +546,13 @@ class Group sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -453,8 +560,13 @@ class Group sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -465,7 +577,7 @@ class Group sig { void } def created_at_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -483,27 +595,72 @@ class Group sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -534,8 +691,8 @@ class Group sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -543,8 +700,8 @@ class Group sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -561,6 +718,9 @@ class Group sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_name!; end @@ -573,12 +733,18 @@ class Group sig { returns(T::Boolean) } def saved_change_to_created_at?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_name; end @@ -615,8 +781,13 @@ class Group sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -624,8 +795,13 @@ class Group sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -642,6 +818,9 @@ class Group sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_name?; end @@ -662,8 +841,8 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -677,13 +856,13 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -719,6 +898,9 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -743,6 +925,9 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -773,6 +958,12 @@ class Group sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -783,10 +974,48 @@ class Group Elem = type_member { { fixed: ::Group } } + sig { returns(T::Array[::Group]) } + def to_a; end + sig { returns(T::Array[::Group]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Group } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Group } } @@ -830,20 +1059,6 @@ class Group end def concat(*records); end - sig do - params( - records: T.any(::Group, Integer, String, T::Enumerable[T.any(::Group, Integer, String, T::Enumerable[::Group])]) - ).returns(T::Array[::Group]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Group, Integer, String, T::Enumerable[T.any(::Group, Integer, String, T::Enumerable[::Group])]) - ).returns(T::Array[::Group]) - end - def destroy(*records); end - sig { returns(T::Array[::Group]) } def load_target; end @@ -874,6 +1089,9 @@ class Group sig { returns(T::Array[::Group]) } def target; end + sig { returns(T::Array[::Group]) } + def to_a; end + sig { returns(T::Array[::Group]) } def to_ary; end end @@ -884,10 +1102,48 @@ class Group Elem = type_member { { fixed: ::Group } } + sig { returns(T::Array[::Group]) } + def to_a; end + sig { returns(T::Array[::Group]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Group } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Group } } diff --git a/sorbet/rbi/dsl/group_server.rbi b/sorbet/rbi/dsl/group_server.rbi index a785f63a4..110697256 100644 --- a/sorbet/rbi/dsl/group_server.rbi +++ b/sorbet/rbi/dsl/group_server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `GroupServer`. # Please instead update this file by running `bin/tapioca dsl GroupServer`. + class GroupServer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class GroupServer sig { params(block: T.nilable(T.proc.params(record: ::GroupServer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupServer).void)).returns(::GroupServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class GroupServer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::GroupServer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupServer).void)).returns(::GroupServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class GroupServer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupServer).void)).returns(::GroupServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class GroupServer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class GroupServer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class GroupServer sig { returns(::GroupServer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::GroupServer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::GroupServer]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::GroupServer).void).returns(T.nilable(::GroupServer)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::GroupServer)) } def find_by(*args); end @@ -89,6 +134,54 @@ class GroupServer sig { params(args: T.untyped).returns(::GroupServer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::GroupServer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::GroupServer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::GroupServer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::GroupServer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class GroupServer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class GroupServer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class GroupServer sig { params(arg: T.untyped, args: T.untyped).returns(::GroupServer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::GroupServer)) } + sig { params(limit: Integer).returns(T::Array[::GroupServer]) } def first(limit = nil); end sig { returns(::GroupServer) } @@ -143,10 +249,36 @@ class GroupServer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::GroupServer)) } + sig { params(limit: Integer).returns(T::Array[::GroupServer]) } def last(limit = nil); end sig { returns(::GroupServer) } @@ -164,6 +296,13 @@ class GroupServer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupServer).void)).returns(::GroupServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupServer).void) + ).returns(T::Array[::GroupServer]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class GroupServer sig { returns(::GroupServer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::GroupServer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::GroupServer)) } + sig { params(limit: Integer).returns(T::Array[::GroupServer]) } def take(limit = nil); end sig { returns(::GroupServer) } @@ -251,17 +393,35 @@ class GroupServer sig { params(value: T.nilable(::Group)).void } def group=(value); end + sig { returns(T::Boolean) } + def group_changed?; end + + sig { returns(T::Boolean) } + def group_previously_changed?; end + sig { returns(T.nilable(::Group)) } def reload_group; end sig { returns(T.nilable(::Server)) } def reload_server; end + sig { void } + def reset_group; end + + sig { void } + def reset_server; end + sig { returns(T.nilable(::Server)) } def server; end sig { params(value: T.nilable(::Server)).void } def server=(value); end + + sig { returns(T::Boolean) } + def server_changed?; end + + sig { returns(T::Boolean) } + def server_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -277,8 +437,8 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -292,13 +452,13 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -310,40 +470,6 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -368,6 +494,9 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -392,6 +521,9 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -419,27 +551,15 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -469,8 +589,13 @@ class GroupServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -478,8 +603,13 @@ class GroupServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -514,8 +644,8 @@ class GroupServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def group_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def group_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def group_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def group_id_in_database; end @@ -523,8 +653,8 @@ class GroupServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def group_id_previous_change; end - sig { returns(T::Boolean) } - def group_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def group_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def group_id_previously_was; end @@ -535,7 +665,7 @@ class GroupServer sig { void } def group_id_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -553,27 +683,72 @@ class GroupServer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -589,6 +764,9 @@ class GroupServer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_server_id!; end @@ -607,12 +785,18 @@ class GroupServer sig { returns(T::Boolean) } def saved_change_to_group_id?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def saved_change_to_server_id; end @@ -649,8 +833,8 @@ class GroupServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def server_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_in_database; end @@ -658,8 +842,8 @@ class GroupServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_id_previous_change; end - sig { returns(T::Boolean) } - def server_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_previously_was; end @@ -694,8 +878,13 @@ class GroupServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -703,8 +892,13 @@ class GroupServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -724,6 +918,9 @@ class GroupServer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_server_id?; end @@ -744,8 +941,8 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -759,13 +956,13 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -801,6 +998,9 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -825,6 +1025,9 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -855,6 +1058,12 @@ class GroupServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -865,10 +1074,48 @@ class GroupServer Elem = type_member { { fixed: ::GroupServer } } + sig { returns(T::Array[::GroupServer]) } + def to_a; end + sig { returns(T::Array[::GroupServer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::GroupServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::GroupServer } } @@ -912,20 +1159,6 @@ class GroupServer end def concat(*records); end - sig do - params( - records: T.any(::GroupServer, Integer, String, T::Enumerable[T.any(::GroupServer, Integer, String, T::Enumerable[::GroupServer])]) - ).returns(T::Array[::GroupServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::GroupServer, Integer, String, T::Enumerable[T.any(::GroupServer, Integer, String, T::Enumerable[::GroupServer])]) - ).returns(T::Array[::GroupServer]) - end - def destroy(*records); end - sig { returns(T::Array[::GroupServer]) } def load_target; end @@ -956,6 +1189,9 @@ class GroupServer sig { returns(T::Array[::GroupServer]) } def target; end + sig { returns(T::Array[::GroupServer]) } + def to_a; end + sig { returns(T::Array[::GroupServer]) } def to_ary; end end @@ -966,10 +1202,48 @@ class GroupServer Elem = type_member { { fixed: ::GroupServer } } + sig { returns(T::Array[::GroupServer]) } + def to_a; end + sig { returns(T::Array[::GroupServer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::GroupServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::GroupServer } } diff --git a/sorbet/rbi/dsl/group_user.rbi b/sorbet/rbi/dsl/group_user.rbi index d335ef463..681fd8c5d 100644 --- a/sorbet/rbi/dsl/group_user.rbi +++ b/sorbet/rbi/dsl/group_user.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `GroupUser`. # Please instead update this file by running `bin/tapioca dsl GroupUser`. + class GroupUser include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class GroupUser sig { params(block: T.nilable(T.proc.params(record: ::GroupUser).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupUser).void)).returns(::GroupUser) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class GroupUser end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::GroupUser).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupUser).void)).returns(::GroupUser) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class GroupUser end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupUser).void)).returns(::GroupUser) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class GroupUser end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class GroupUser end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class GroupUser sig { returns(::GroupUser) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::GroupUser) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::GroupUser]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::GroupUser).void).returns(T.nilable(::GroupUser)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::GroupUser)) } def find_by(*args); end @@ -89,6 +134,54 @@ class GroupUser sig { params(args: T.untyped).returns(::GroupUser) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::GroupUser).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::GroupUser]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::GroupUser]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::GroupUser]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class GroupUser end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class GroupUser end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class GroupUser sig { params(arg: T.untyped, args: T.untyped).returns(::GroupUser) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::GroupUser)) } + sig { params(limit: Integer).returns(T::Array[::GroupUser]) } def first(limit = nil); end sig { returns(::GroupUser) } @@ -143,10 +249,36 @@ class GroupUser sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::GroupUser)) } + sig { params(limit: Integer).returns(T::Array[::GroupUser]) } def last(limit = nil); end sig { returns(::GroupUser) } @@ -164,6 +296,13 @@ class GroupUser sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::GroupUser).void)).returns(::GroupUser) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::GroupUser).void) + ).returns(T::Array[::GroupUser]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class GroupUser sig { returns(::GroupUser) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::GroupUser).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::GroupUser)) } + sig { params(limit: Integer).returns(T::Array[::GroupUser]) } def take(limit = nil); end sig { returns(::GroupUser) } @@ -251,17 +393,35 @@ class GroupUser sig { params(value: T.nilable(::Group)).void } def group=(value); end + sig { returns(T::Boolean) } + def group_changed?; end + + sig { returns(T::Boolean) } + def group_previously_changed?; end + sig { returns(T.nilable(::Group)) } def reload_group; end sig { returns(T.nilable(::User)) } def reload_user; end + sig { void } + def reset_group; end + + sig { void } + def reset_user; end + sig { returns(T.nilable(::User)) } def user; end sig { params(value: T.nilable(::User)).void } def user=(value); end + + sig { returns(T::Boolean) } + def user_changed?; end + + sig { returns(T::Boolean) } + def user_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -277,8 +437,8 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -292,13 +452,13 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -310,40 +470,6 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -368,6 +494,9 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -392,6 +521,9 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -419,27 +551,15 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -469,8 +589,13 @@ class GroupUser sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -478,8 +603,13 @@ class GroupUser sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -514,8 +644,13 @@ class GroupUser sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def expires_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def expires_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def expires_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def expires_at_in_database; end @@ -523,8 +658,13 @@ class GroupUser sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def expires_at_previous_change; end - sig { returns(T::Boolean) } - def expires_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def expires_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def expires_at_previously_was; end @@ -559,8 +699,8 @@ class GroupUser sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def group_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def group_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def group_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def group_id_in_database; end @@ -568,8 +708,8 @@ class GroupUser sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def group_id_previous_change; end - sig { returns(T::Boolean) } - def group_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def group_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def group_id_previously_was; end @@ -580,7 +720,7 @@ class GroupUser sig { void } def group_id_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -598,27 +738,72 @@ class GroupUser sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -637,6 +822,9 @@ class GroupUser sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_updated_at!; end @@ -661,12 +849,18 @@ class GroupUser sig { returns(T::Boolean) } def saved_change_to_group_id?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def saved_change_to_updated_at; end @@ -703,8 +897,13 @@ class GroupUser sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -712,8 +911,13 @@ class GroupUser sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -748,8 +952,8 @@ class GroupUser sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def user_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_in_database; end @@ -757,8 +961,8 @@ class GroupUser sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_previous_change; end - sig { returns(T::Boolean) } - def user_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_previously_was; end @@ -781,6 +985,9 @@ class GroupUser sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_updated_at?; end @@ -801,8 +1008,8 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -816,13 +1023,13 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -858,6 +1065,9 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -882,6 +1092,9 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -912,6 +1125,12 @@ class GroupUser sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -922,10 +1141,48 @@ class GroupUser Elem = type_member { { fixed: ::GroupUser } } + sig { returns(T::Array[::GroupUser]) } + def to_a; end + sig { returns(T::Array[::GroupUser]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::GroupUser } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::GroupUser } } @@ -969,20 +1226,6 @@ class GroupUser end def concat(*records); end - sig do - params( - records: T.any(::GroupUser, Integer, String, T::Enumerable[T.any(::GroupUser, Integer, String, T::Enumerable[::GroupUser])]) - ).returns(T::Array[::GroupUser]) - end - def delete(*records); end - - sig do - params( - records: T.any(::GroupUser, Integer, String, T::Enumerable[T.any(::GroupUser, Integer, String, T::Enumerable[::GroupUser])]) - ).returns(T::Array[::GroupUser]) - end - def destroy(*records); end - sig { returns(T::Array[::GroupUser]) } def load_target; end @@ -1013,6 +1256,9 @@ class GroupUser sig { returns(T::Array[::GroupUser]) } def target; end + sig { returns(T::Array[::GroupUser]) } + def to_a; end + sig { returns(T::Array[::GroupUser]) } def to_ary; end end @@ -1023,10 +1269,48 @@ class GroupUser Elem = type_member { { fixed: ::GroupUser } } + sig { returns(T::Array[::GroupUser]) } + def to_a; end + sig { returns(T::Array[::GroupUser]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::GroupUser } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::GroupUser } } diff --git a/sorbet/rbi/dsl/hiperz_server.rbi b/sorbet/rbi/dsl/hiperz_server.rbi deleted file mode 100644 index a22665714..000000000 --- a/sorbet/rbi/dsl/hiperz_server.rbi +++ /dev/null @@ -1,2296 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `HiperzServer`. -# Please instead update this file by running `bin/tapioca dsl HiperzServer`. - -class HiperzServer - include GeneratedAssociationMethods - include GeneratedAttributeMethods - extend CommonRelationMethods - extend GeneratedRelationMethods - - private - - sig { returns(NilClass) } - def to_ary; end - - module CommonRelationMethods - sig { params(block: T.nilable(T.proc.params(record: ::HiperzServer).returns(T.untyped))).returns(T::Boolean) } - def any?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def average(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def build(attributes = nil, &block); end - - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } - def calculate(operation, column_name); end - - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def create(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def create!(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def create_or_find_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def create_or_find_by!(attributes, &block); end - - sig { returns(T::Array[::HiperzServer]) } - def destroy_all; end - - sig { params(conditions: T.untyped).returns(T::Boolean) } - def exists?(conditions = :none); end - - sig { returns(T.nilable(::HiperzServer)) } - def fifth; end - - sig { returns(::HiperzServer) } - def fifth!; end - - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end - - sig { params(args: T.untyped).returns(T.nilable(::HiperzServer)) } - def find_by(*args); end - - sig { params(args: T.untyped).returns(::HiperzServer) } - def find_by!(*args); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def find_or_create_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def find_or_create_by!(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def find_or_initialize_by(attributes, &block); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(T.nilable(::HiperzServer)) } - def find_signed(signed_id, purpose: nil); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(::HiperzServer) } - def find_signed!(signed_id, purpose: nil); end - - sig { params(arg: T.untyped, args: T.untyped).returns(::HiperzServer) } - def find_sole_by(arg, *args); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def first(limit = nil); end - - sig { returns(::HiperzServer) } - def first!; end - - sig { returns(T.nilable(::HiperzServer)) } - def forty_two; end - - sig { returns(::HiperzServer) } - def forty_two!; end - - sig { returns(T.nilable(::HiperzServer)) } - def fourth; end - - sig { returns(::HiperzServer) } - def fourth!; end - - sig { returns(Array) } - def ids; end - - sig { params(record: T.untyped).returns(T::Boolean) } - def include?(record); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def last(limit = nil); end - - sig { returns(::HiperzServer) } - def last!; end - - sig { params(block: T.nilable(T.proc.params(record: ::HiperzServer).returns(T.untyped))).returns(T::Boolean) } - def many?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def maximum(column_name); end - - sig { params(record: T.untyped).returns(T::Boolean) } - def member?(record); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def minimum(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServer).void) - ).returns(::HiperzServer) - end - def new(attributes = nil, &block); end - - sig { params(block: T.nilable(T.proc.params(record: ::HiperzServer).returns(T.untyped))).returns(T::Boolean) } - def none?(&block); end - - sig { params(block: T.nilable(T.proc.params(record: ::HiperzServer).returns(T.untyped))).returns(T::Boolean) } - def one?(&block); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pick(*column_names); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pluck(*column_names); end - - sig { returns(T.nilable(::HiperzServer)) } - def second; end - - sig { returns(::HiperzServer) } - def second!; end - - sig { returns(T.nilable(::HiperzServer)) } - def second_to_last; end - - sig { returns(::HiperzServer) } - def second_to_last!; end - - sig { returns(::HiperzServer) } - def sole; end - - sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) - end - def sum(column_name = nil, &block); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def take(limit = nil); end - - sig { returns(::HiperzServer) } - def take!; end - - sig { returns(T.nilable(::HiperzServer)) } - def third; end - - sig { returns(::HiperzServer) } - def third!; end - - sig { returns(T.nilable(::HiperzServer)) } - def third_to_last; end - - sig { returns(::HiperzServer) } - def third_to_last!; end - end - - module GeneratedAssociationMethods - sig { params(args: T.untyped, blk: T.untyped).returns(::HiperzServerInformation) } - def build_hiperz_server_information(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::Location) } - def build_location(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::HiperzServerInformation) } - def create_hiperz_server_information(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::HiperzServerInformation) } - def create_hiperz_server_information!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::Location) } - def create_location(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::Location) } - def create_location!(*args, &blk); end - - sig { returns(T::Array[T.untyped]) } - def current_reservation_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def current_reservation_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :current_reservations`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::Reservation::PrivateCollectionProxy) } - def current_reservations; end - - sig { params(value: T::Enumerable[::Reservation]).void } - def current_reservations=(value); end - - sig { returns(T::Array[T.untyped]) } - def group_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def group_ids=(ids); end - - sig { returns(T::Array[T.untyped]) } - def group_server_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def group_server_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :group_servers`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::GroupServer::PrivateCollectionProxy) } - def group_servers; end - - sig { params(value: T::Enumerable[::GroupServer]).void } - def group_servers=(value); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :groups, through: :group_servers`. - # 🔗 [Rails guide for `has_many_through` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-through-association) - sig { returns(::Group::PrivateCollectionProxy) } - def groups; end - - sig { params(value: T::Enumerable[::Group]).void } - def groups=(value); end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def hiperz_server_information; end - - sig { params(value: T.nilable(::HiperzServerInformation)).void } - def hiperz_server_information=(value); end - - sig { returns(T.nilable(::Location)) } - def location; end - - sig { params(value: T.nilable(::Location)).void } - def location=(value); end - - sig { returns(T::Array[T.untyped]) } - def recent_server_statistic_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def recent_server_statistic_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :recent_server_statistics`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::ServerStatistic::PrivateCollectionProxy) } - def recent_server_statistics; end - - sig { params(value: T::Enumerable[::ServerStatistic]).void } - def recent_server_statistics=(value); end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def reload_hiperz_server_information; end - - sig { returns(T.nilable(::Location)) } - def reload_location; end - - sig { returns(T::Array[T.untyped]) } - def reservation_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def reservation_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :reservations`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::Reservation::PrivateCollectionProxy) } - def reservations; end - - sig { params(value: T::Enumerable[::Reservation]).void } - def reservations=(value); end - - sig { returns(T::Array[T.untyped]) } - def server_statistic_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def server_statistic_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :server_statistics`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::ServerStatistic::PrivateCollectionProxy) } - def server_statistics; end - - sig { params(value: T::Enumerable[::ServerStatistic]).void } - def server_statistics=(value); end - end - - module GeneratedAssociationRelationMethods - sig { returns(PrivateAssociationRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def includes(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def near(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_reverse_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def unscope(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def within_bounding_box(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def without(*args, &blk); end - end - - module GeneratedAttributeMethods - sig { returns(T.nilable(T::Boolean)) } - def active; end - - sig { params(value: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } - def active=(value); end - - sig { returns(T::Boolean) } - def active?; end - - sig { returns(T.nilable(T::Boolean)) } - def active_before_last_save; end - - sig { returns(T.untyped) } - def active_before_type_cast; end - - sig { returns(T::Boolean) } - def active_came_from_user?; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def active_change; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def active_change_to_be_saved; end - - sig { returns(T::Boolean) } - def active_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def active_in_database; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def active_previous_change; end - - sig { returns(T::Boolean) } - def active_previously_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def active_previously_was; end - - sig { returns(T.nilable(T::Boolean)) } - def active_was; end - - sig { void } - def active_will_change!; end - - sig { returns(T.nilable(::String)) } - def billing_id; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def billing_id=(value); end - - sig { returns(T::Boolean) } - def billing_id?; end - - sig { returns(T.nilable(::String)) } - def billing_id_before_last_save; end - - sig { returns(T.untyped) } - def billing_id_before_type_cast; end - - sig { returns(T::Boolean) } - def billing_id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def billing_id_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def billing_id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def billing_id_changed?; end - - sig { returns(T.nilable(::String)) } - def billing_id_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def billing_id_previous_change; end - - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def billing_id_previously_was; end - - sig { returns(T.nilable(::String)) } - def billing_id_was; end - - sig { void } - def billing_id_will_change!; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at; end - - sig { params(value: T.nilable(::ActiveSupport::TimeWithZone)).returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at=(value); end - - sig { returns(T::Boolean) } - def created_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_before_last_save; end - - sig { returns(T.untyped) } - def created_at_before_type_cast; end - - sig { returns(T::Boolean) } - def created_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def created_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_previous_change; end - - sig { returns(T::Boolean) } - def created_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_was; end - - sig { void } - def created_at_will_change!; end - - sig { returns(T.nilable(::String)) } - def ftp_password; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def ftp_password=(value); end - - sig { returns(T::Boolean) } - def ftp_password?; end - - sig { returns(T.nilable(::String)) } - def ftp_password_before_last_save; end - - sig { returns(T.untyped) } - def ftp_password_before_type_cast; end - - sig { returns(T::Boolean) } - def ftp_password_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_password_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_password_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ftp_password_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_password_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_password_previous_change; end - - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_password_previously_was; end - - sig { returns(T.nilable(::String)) } - def ftp_password_was; end - - sig { void } - def ftp_password_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def ftp_port=(value); end - - sig { returns(T::Boolean) } - def ftp_port?; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_before_last_save; end - - sig { returns(T.untyped) } - def ftp_port_before_type_cast; end - - sig { returns(T::Boolean) } - def ftp_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def ftp_port_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def ftp_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ftp_port_changed?; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def ftp_port_previous_change; end - - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_was; end - - sig { void } - def ftp_port_will_change!; end - - sig { returns(T.nilable(::String)) } - def ftp_username; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def ftp_username=(value); end - - sig { returns(T::Boolean) } - def ftp_username?; end - - sig { returns(T.nilable(::String)) } - def ftp_username_before_last_save; end - - sig { returns(T.untyped) } - def ftp_username_before_type_cast; end - - sig { returns(T::Boolean) } - def ftp_username_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_username_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_username_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ftp_username_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_username_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_username_previous_change; end - - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_username_previously_was; end - - sig { returns(T.nilable(::String)) } - def ftp_username_was; end - - sig { void } - def ftp_username_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def id; end - - sig { params(value: ::Integer).returns(::Integer) } - def id=(value); end - - sig { returns(T::Boolean) } - def id?; end - - sig { returns(T.nilable(::Integer)) } - def id_before_last_save; end - - sig { returns(T.untyped) } - def id_before_type_cast; end - - sig { returns(T::Boolean) } - def id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def id_changed?; end - - sig { returns(T.nilable(::Integer)) } - def id_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_previous_change; end - - sig { returns(T::Boolean) } - def id_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def id_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def id_was; end - - sig { void } - def id_will_change!; end - - sig { returns(T.nilable(::String)) } - def ip; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def ip=(value); end - - sig { returns(T::Boolean) } - def ip?; end - - sig { returns(T.nilable(::String)) } - def ip_before_last_save; end - - sig { returns(T.untyped) } - def ip_before_type_cast; end - - sig { returns(T::Boolean) } - def ip_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ip_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ip_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ip_changed?; end - - sig { returns(T.nilable(::String)) } - def ip_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ip_previous_change; end - - sig { returns(T::Boolean) } - def ip_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def ip_previously_was; end - - sig { returns(T.nilable(::String)) } - def ip_was; end - - sig { void } - def ip_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def last_known_version=(value); end - - sig { returns(T::Boolean) } - def last_known_version?; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_before_last_save; end - - sig { returns(T.untyped) } - def last_known_version_before_type_cast; end - - sig { returns(T::Boolean) } - def last_known_version_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def last_known_version_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def last_known_version_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_known_version_changed?; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def last_known_version_previous_change; end - - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_was; end - - sig { void } - def last_known_version_will_change!; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def last_sdr_ip=(value); end - - sig { returns(T::Boolean) } - def last_sdr_ip?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_before_last_save; end - - sig { returns(T.untyped) } - def last_sdr_ip_before_type_cast; end - - sig { returns(T::Boolean) } - def last_sdr_ip_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_ip_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_ip_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_ip_previous_change; end - - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_previously_was; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_was; end - - sig { void } - def last_sdr_ip_will_change!; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def last_sdr_port=(value); end - - sig { returns(T::Boolean) } - def last_sdr_port?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_before_last_save; end - - sig { returns(T.untyped) } - def last_sdr_port_before_type_cast; end - - sig { returns(T::Boolean) } - def last_sdr_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_port_previous_change; end - - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_previously_was; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_was; end - - sig { void } - def last_sdr_port_will_change!; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def last_sdr_tv_port=(value); end - - sig { returns(T::Boolean) } - def last_sdr_tv_port?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_before_last_save; end - - sig { returns(T.untyped) } - def last_sdr_tv_port_before_type_cast; end - - sig { returns(T::Boolean) } - def last_sdr_tv_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_tv_port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_tv_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_tv_port_previous_change; end - - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_previously_was; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_was; end - - sig { void } - def last_sdr_tv_port_will_change!; end - - sig { returns(T.nilable(::Float)) } - def latitude; end - - sig { params(value: T.nilable(::Float)).returns(T.nilable(::Float)) } - def latitude=(value); end - - sig { returns(T::Boolean) } - def latitude?; end - - sig { returns(T.nilable(::Float)) } - def latitude_before_last_save; end - - sig { returns(T.untyped) } - def latitude_before_type_cast; end - - sig { returns(T::Boolean) } - def latitude_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def latitude_change; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def latitude_change_to_be_saved; end - - sig { returns(T::Boolean) } - def latitude_changed?; end - - sig { returns(T.nilable(::Float)) } - def latitude_in_database; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def latitude_previous_change; end - - sig { returns(T::Boolean) } - def latitude_previously_changed?; end - - sig { returns(T.nilable(::Float)) } - def latitude_previously_was; end - - sig { returns(T.nilable(::Float)) } - def latitude_was; end - - sig { void } - def latitude_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def location_id; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def location_id=(value); end - - sig { returns(T::Boolean) } - def location_id?; end - - sig { returns(T.nilable(::Integer)) } - def location_id_before_last_save; end - - sig { returns(T.untyped) } - def location_id_before_type_cast; end - - sig { returns(T::Boolean) } - def location_id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def location_id_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def location_id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def location_id_changed?; end - - sig { returns(T.nilable(::Integer)) } - def location_id_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def location_id_previous_change; end - - sig { returns(T::Boolean) } - def location_id_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def location_id_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def location_id_was; end - - sig { void } - def location_id_will_change!; end - - sig { returns(T.nilable(::Float)) } - def longitude; end - - sig { params(value: T.nilable(::Float)).returns(T.nilable(::Float)) } - def longitude=(value); end - - sig { returns(T::Boolean) } - def longitude?; end - - sig { returns(T.nilable(::Float)) } - def longitude_before_last_save; end - - sig { returns(T.untyped) } - def longitude_before_type_cast; end - - sig { returns(T::Boolean) } - def longitude_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def longitude_change; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def longitude_change_to_be_saved; end - - sig { returns(T::Boolean) } - def longitude_changed?; end - - sig { returns(T.nilable(::Float)) } - def longitude_in_database; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def longitude_previous_change; end - - sig { returns(T::Boolean) } - def longitude_previously_changed?; end - - sig { returns(T.nilable(::Float)) } - def longitude_previously_was; end - - sig { returns(T.nilable(::Float)) } - def longitude_was; end - - sig { void } - def longitude_will_change!; end - - sig { returns(T.nilable(::String)) } - def name; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def name=(value); end - - sig { returns(T::Boolean) } - def name?; end - - sig { returns(T.nilable(::String)) } - def name_before_last_save; end - - sig { returns(T.untyped) } - def name_before_type_cast; end - - sig { returns(T::Boolean) } - def name_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def name_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def name_change_to_be_saved; end - - sig { returns(T::Boolean) } - def name_changed?; end - - sig { returns(T.nilable(::String)) } - def name_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def name_previous_change; end - - sig { returns(T::Boolean) } - def name_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def name_previously_was; end - - sig { returns(T.nilable(::String)) } - def name_was; end - - sig { void } - def name_will_change!; end - - sig { returns(T.nilable(::String)) } - def path; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def path=(value); end - - sig { returns(T::Boolean) } - def path?; end - - sig { returns(T.nilable(::String)) } - def path_before_last_save; end - - sig { returns(T.untyped) } - def path_before_type_cast; end - - sig { returns(T::Boolean) } - def path_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def path_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def path_change_to_be_saved; end - - sig { returns(T::Boolean) } - def path_changed?; end - - sig { returns(T.nilable(::String)) } - def path_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def path_previous_change; end - - sig { returns(T::Boolean) } - def path_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def path_previously_was; end - - sig { returns(T.nilable(::String)) } - def path_was; end - - sig { void } - def path_will_change!; end - - sig { returns(T.nilable(::String)) } - def port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def port=(value); end - - sig { returns(T::Boolean) } - def port?; end - - sig { returns(T.nilable(::String)) } - def port_before_last_save; end - - sig { returns(T.untyped) } - def port_before_type_cast; end - - sig { returns(T::Boolean) } - def port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def port_changed?; end - - sig { returns(T.nilable(::String)) } - def port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def port_previous_change; end - - sig { returns(T::Boolean) } - def port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def port_previously_was; end - - sig { returns(T.nilable(::String)) } - def port_was; end - - sig { void } - def port_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def position; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def position=(value); end - - sig { returns(T::Boolean) } - def position?; end - - sig { returns(T.nilable(::Integer)) } - def position_before_last_save; end - - sig { returns(T.untyped) } - def position_before_type_cast; end - - sig { returns(T::Boolean) } - def position_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def position_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def position_change_to_be_saved; end - - sig { returns(T::Boolean) } - def position_changed?; end - - sig { returns(T.nilable(::Integer)) } - def position_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def position_previous_change; end - - sig { returns(T::Boolean) } - def position_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def position_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def position_was; end - - sig { void } - def position_will_change!; end - - sig { returns(T.nilable(::String)) } - def rcon; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def rcon=(value); end - - sig { returns(T::Boolean) } - def rcon?; end - - sig { returns(T.nilable(::String)) } - def rcon_before_last_save; end - - sig { returns(T.untyped) } - def rcon_before_type_cast; end - - sig { returns(T::Boolean) } - def rcon_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def rcon_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def rcon_change_to_be_saved; end - - sig { returns(T::Boolean) } - def rcon_changed?; end - - sig { returns(T.nilable(::String)) } - def rcon_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def rcon_previous_change; end - - sig { returns(T::Boolean) } - def rcon_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def rcon_previously_was; end - - sig { returns(T.nilable(::String)) } - def rcon_was; end - - sig { void } - def rcon_will_change!; end - - sig { void } - def restore_active!; end - - sig { void } - def restore_billing_id!; end - - sig { void } - def restore_created_at!; end - - sig { void } - def restore_ftp_password!; end - - sig { void } - def restore_ftp_port!; end - - sig { void } - def restore_ftp_username!; end - - sig { void } - def restore_id!; end - - sig { void } - def restore_ip!; end - - sig { void } - def restore_last_known_version!; end - - sig { void } - def restore_last_sdr_ip!; end - - sig { void } - def restore_last_sdr_port!; end - - sig { void } - def restore_last_sdr_tv_port!; end - - sig { void } - def restore_latitude!; end - - sig { void } - def restore_location_id!; end - - sig { void } - def restore_longitude!; end - - sig { void } - def restore_name!; end - - sig { void } - def restore_path!; end - - sig { void } - def restore_port!; end - - sig { void } - def restore_position!; end - - sig { void } - def restore_rcon!; end - - sig { void } - def restore_sdr!; end - - sig { void } - def restore_tv_port!; end - - sig { void } - def restore_type!; end - - sig { void } - def restore_update_started_at!; end - - sig { void } - def restore_update_status!; end - - sig { void } - def restore_updated_at!; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def saved_change_to_active; end - - sig { returns(T::Boolean) } - def saved_change_to_active?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_billing_id; end - - sig { returns(T::Boolean) } - def saved_change_to_billing_id?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_created_at; end - - sig { returns(T::Boolean) } - def saved_change_to_created_at?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_ftp_password; end - - sig { returns(T::Boolean) } - def saved_change_to_ftp_password?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_ftp_port; end - - sig { returns(T::Boolean) } - def saved_change_to_ftp_port?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_ftp_username; end - - sig { returns(T::Boolean) } - def saved_change_to_ftp_username?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_id; end - - sig { returns(T::Boolean) } - def saved_change_to_id?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_ip; end - - sig { returns(T::Boolean) } - def saved_change_to_ip?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_last_known_version; end - - sig { returns(T::Boolean) } - def saved_change_to_last_known_version?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_last_sdr_ip; end - - sig { returns(T::Boolean) } - def saved_change_to_last_sdr_ip?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_last_sdr_port; end - - sig { returns(T::Boolean) } - def saved_change_to_last_sdr_port?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_last_sdr_tv_port; end - - sig { returns(T::Boolean) } - def saved_change_to_last_sdr_tv_port?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def saved_change_to_latitude; end - - sig { returns(T::Boolean) } - def saved_change_to_latitude?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_location_id; end - - sig { returns(T::Boolean) } - def saved_change_to_location_id?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def saved_change_to_longitude; end - - sig { returns(T::Boolean) } - def saved_change_to_longitude?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_name; end - - sig { returns(T::Boolean) } - def saved_change_to_name?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_path; end - - sig { returns(T::Boolean) } - def saved_change_to_path?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_port; end - - sig { returns(T::Boolean) } - def saved_change_to_port?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_position; end - - sig { returns(T::Boolean) } - def saved_change_to_position?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_rcon; end - - sig { returns(T::Boolean) } - def saved_change_to_rcon?; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def saved_change_to_sdr; end - - sig { returns(T::Boolean) } - def saved_change_to_sdr?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_tv_port; end - - sig { returns(T::Boolean) } - def saved_change_to_tv_port?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_type; end - - sig { returns(T::Boolean) } - def saved_change_to_type?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_update_started_at; end - - sig { returns(T::Boolean) } - def saved_change_to_update_started_at?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_update_status; end - - sig { returns(T::Boolean) } - def saved_change_to_update_status?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_updated_at; end - - sig { returns(T::Boolean) } - def saved_change_to_updated_at?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr; end - - sig { params(value: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } - def sdr=(value); end - - sig { returns(T::Boolean) } - def sdr?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_before_last_save; end - - sig { returns(T.untyped) } - def sdr_before_type_cast; end - - sig { returns(T::Boolean) } - def sdr_came_from_user?; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def sdr_change; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def sdr_change_to_be_saved; end - - sig { returns(T::Boolean) } - def sdr_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_in_database; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def sdr_previous_change; end - - sig { returns(T::Boolean) } - def sdr_previously_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_previously_was; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_was; end - - sig { void } - def sdr_will_change!; end - - sig { returns(T.nilable(::String)) } - def tv_port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def tv_port=(value); end - - sig { returns(T::Boolean) } - def tv_port?; end - - sig { returns(T.nilable(::String)) } - def tv_port_before_last_save; end - - sig { returns(T.untyped) } - def tv_port_before_type_cast; end - - sig { returns(T::Boolean) } - def tv_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def tv_port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def tv_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def tv_port_changed?; end - - sig { returns(T.nilable(::String)) } - def tv_port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def tv_port_previous_change; end - - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def tv_port_previously_was; end - - sig { returns(T.nilable(::String)) } - def tv_port_was; end - - sig { void } - def tv_port_will_change!; end - - sig { returns(T.nilable(::String)) } - def type; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def type=(value); end - - sig { returns(T::Boolean) } - def type?; end - - sig { returns(T.nilable(::String)) } - def type_before_last_save; end - - sig { returns(T.untyped) } - def type_before_type_cast; end - - sig { returns(T::Boolean) } - def type_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def type_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def type_change_to_be_saved; end - - sig { returns(T::Boolean) } - def type_changed?; end - - sig { returns(T.nilable(::String)) } - def type_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def type_previous_change; end - - sig { returns(T::Boolean) } - def type_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def type_previously_was; end - - sig { returns(T.nilable(::String)) } - def type_was; end - - sig { void } - def type_will_change!; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at; end - - sig { params(value: T.nilable(::ActiveSupport::TimeWithZone)).returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at=(value); end - - sig { returns(T::Boolean) } - def update_started_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_before_last_save; end - - sig { returns(T.untyped) } - def update_started_at_before_type_cast; end - - sig { returns(T::Boolean) } - def update_started_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def update_started_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def update_started_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def update_started_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def update_started_at_previous_change; end - - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_was; end - - sig { void } - def update_started_at_will_change!; end - - sig { returns(T.nilable(::String)) } - def update_status; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def update_status=(value); end - - sig { returns(T::Boolean) } - def update_status?; end - - sig { returns(T.nilable(::String)) } - def update_status_before_last_save; end - - sig { returns(T.untyped) } - def update_status_before_type_cast; end - - sig { returns(T::Boolean) } - def update_status_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def update_status_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def update_status_change_to_be_saved; end - - sig { returns(T::Boolean) } - def update_status_changed?; end - - sig { returns(T.nilable(::String)) } - def update_status_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def update_status_previous_change; end - - sig { returns(T::Boolean) } - def update_status_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def update_status_previously_was; end - - sig { returns(T.nilable(::String)) } - def update_status_was; end - - sig { void } - def update_status_will_change!; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at; end - - sig { params(value: T.nilable(::ActiveSupport::TimeWithZone)).returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at=(value); end - - sig { returns(T::Boolean) } - def updated_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_before_last_save; end - - sig { returns(T.untyped) } - def updated_at_before_type_cast; end - - sig { returns(T::Boolean) } - def updated_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def updated_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_previous_change; end - - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_was; end - - sig { void } - def updated_at_will_change!; end - - sig { returns(T::Boolean) } - def will_save_change_to_active?; end - - sig { returns(T::Boolean) } - def will_save_change_to_billing_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_created_at?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ftp_password?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ftp_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ftp_username?; end - - sig { returns(T::Boolean) } - def will_save_change_to_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ip?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_known_version?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_sdr_ip?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_sdr_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_sdr_tv_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_latitude?; end - - sig { returns(T::Boolean) } - def will_save_change_to_location_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_longitude?; end - - sig { returns(T::Boolean) } - def will_save_change_to_name?; end - - sig { returns(T::Boolean) } - def will_save_change_to_path?; end - - sig { returns(T::Boolean) } - def will_save_change_to_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_position?; end - - sig { returns(T::Boolean) } - def will_save_change_to_rcon?; end - - sig { returns(T::Boolean) } - def will_save_change_to_sdr?; end - - sig { returns(T::Boolean) } - def will_save_change_to_tv_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_type?; end - - sig { returns(T::Boolean) } - def will_save_change_to_update_started_at?; end - - sig { returns(T::Boolean) } - def will_save_change_to_update_status?; end - - sig { returns(T::Boolean) } - def will_save_change_to_updated_at?; end - end - - module GeneratedRelationMethods - sig { returns(PrivateRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def includes(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def near(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_reverse_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def unscope(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def within_bounding_box(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def without(*args, &blk); end - end - - class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::HiperzServer } } - - sig { returns(T::Array[::HiperzServer]) } - def to_ary; end - end - - class PrivateAssociationRelationWhereChain < PrivateAssociationRelation - Elem = type_member { { fixed: ::HiperzServer } } - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateAssociationRelation) } - def not(opts, *rest); end - end - - class PrivateCollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::HiperzServer } } - - sig do - params( - records: T.any(::HiperzServer, T::Enumerable[T.any(::HiperzServer, T::Enumerable[::HiperzServer])]) - ).returns(PrivateCollectionProxy) - end - def <<(*records); end - - sig do - params( - records: T.any(::HiperzServer, T::Enumerable[T.any(::HiperzServer, T::Enumerable[::HiperzServer])]) - ).returns(PrivateCollectionProxy) - end - def append(*records); end - - sig { returns(PrivateCollectionProxy) } - def clear; end - - sig do - params( - records: T.any(::HiperzServer, T::Enumerable[T.any(::HiperzServer, T::Enumerable[::HiperzServer])]) - ).returns(PrivateCollectionProxy) - end - def concat(*records); end - - sig do - params( - records: T.any(::HiperzServer, Integer, String, T::Enumerable[T.any(::HiperzServer, Integer, String, T::Enumerable[::HiperzServer])]) - ).returns(T::Array[::HiperzServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::HiperzServer, Integer, String, T::Enumerable[T.any(::HiperzServer, Integer, String, T::Enumerable[::HiperzServer])]) - ).returns(T::Array[::HiperzServer]) - end - def destroy(*records); end - - sig { returns(T::Array[::HiperzServer]) } - def load_target; end - - sig do - params( - records: T.any(::HiperzServer, T::Enumerable[T.any(::HiperzServer, T::Enumerable[::HiperzServer])]) - ).returns(PrivateCollectionProxy) - end - def prepend(*records); end - - sig do - params( - records: T.any(::HiperzServer, T::Enumerable[T.any(::HiperzServer, T::Enumerable[::HiperzServer])]) - ).returns(PrivateCollectionProxy) - end - def push(*records); end - - sig do - params( - other_array: T.any(::HiperzServer, T::Enumerable[T.any(::HiperzServer, T::Enumerable[::HiperzServer])]) - ).returns(T::Array[::HiperzServer]) - end - def replace(other_array); end - - sig { returns(PrivateAssociationRelation) } - def scope; end - - sig { returns(T::Array[::HiperzServer]) } - def target; end - - sig { returns(T::Array[::HiperzServer]) } - def to_ary; end - end - - class PrivateRelation < ::ActiveRecord::Relation - include CommonRelationMethods - include GeneratedRelationMethods - - Elem = type_member { { fixed: ::HiperzServer } } - - sig { returns(T::Array[::HiperzServer]) } - def to_ary; end - end - - class PrivateRelationWhereChain < PrivateRelation - Elem = type_member { { fixed: ::HiperzServer } } - - sig { params(args: T.untyped).returns(PrivateRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateRelation) } - def not(opts, *rest); end - end -end diff --git a/sorbet/rbi/dsl/hiperz_server_information.rbi b/sorbet/rbi/dsl/hiperz_server_information.rbi deleted file mode 100644 index 412dc2af4..000000000 --- a/sorbet/rbi/dsl/hiperz_server_information.rbi +++ /dev/null @@ -1,869 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `HiperzServerInformation`. -# Please instead update this file by running `bin/tapioca dsl HiperzServerInformation`. - -class HiperzServerInformation - include GeneratedAssociationMethods - include GeneratedAttributeMethods - extend CommonRelationMethods - extend GeneratedRelationMethods - - private - - sig { returns(NilClass) } - def to_ary; end - - module CommonRelationMethods - sig do - params( - block: T.nilable(T.proc.params(record: ::HiperzServerInformation).returns(T.untyped)) - ).returns(T::Boolean) - end - def any?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def average(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def build(attributes = nil, &block); end - - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } - def calculate(operation, column_name); end - - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def create(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def create!(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def create_or_find_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def create_or_find_by!(attributes, &block); end - - sig { returns(T::Array[::HiperzServerInformation]) } - def destroy_all; end - - sig { params(conditions: T.untyped).returns(T::Boolean) } - def exists?(conditions = :none); end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def fifth; end - - sig { returns(::HiperzServerInformation) } - def fifth!; end - - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end - - sig { params(args: T.untyped).returns(T.nilable(::HiperzServerInformation)) } - def find_by(*args); end - - sig { params(args: T.untyped).returns(::HiperzServerInformation) } - def find_by!(*args); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def find_or_create_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def find_or_create_by!(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def find_or_initialize_by(attributes, &block); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(T.nilable(::HiperzServerInformation)) } - def find_signed(signed_id, purpose: nil); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(::HiperzServerInformation) } - def find_signed!(signed_id, purpose: nil); end - - sig { params(arg: T.untyped, args: T.untyped).returns(::HiperzServerInformation) } - def find_sole_by(arg, *args); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def first(limit = nil); end - - sig { returns(::HiperzServerInformation) } - def first!; end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def forty_two; end - - sig { returns(::HiperzServerInformation) } - def forty_two!; end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def fourth; end - - sig { returns(::HiperzServerInformation) } - def fourth!; end - - sig { returns(Array) } - def ids; end - - sig { params(record: T.untyped).returns(T::Boolean) } - def include?(record); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def last(limit = nil); end - - sig { returns(::HiperzServerInformation) } - def last!; end - - sig do - params( - block: T.nilable(T.proc.params(record: ::HiperzServerInformation).returns(T.untyped)) - ).returns(T::Boolean) - end - def many?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def maximum(column_name); end - - sig { params(record: T.untyped).returns(T::Boolean) } - def member?(record); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def minimum(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::HiperzServerInformation).void) - ).returns(::HiperzServerInformation) - end - def new(attributes = nil, &block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::HiperzServerInformation).returns(T.untyped)) - ).returns(T::Boolean) - end - def none?(&block); end - - sig do - params( - block: T.nilable(T.proc.params(record: ::HiperzServerInformation).returns(T.untyped)) - ).returns(T::Boolean) - end - def one?(&block); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pick(*column_names); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pluck(*column_names); end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def second; end - - sig { returns(::HiperzServerInformation) } - def second!; end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def second_to_last; end - - sig { returns(::HiperzServerInformation) } - def second_to_last!; end - - sig { returns(::HiperzServerInformation) } - def sole; end - - sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) - end - def sum(column_name = nil, &block); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def take(limit = nil); end - - sig { returns(::HiperzServerInformation) } - def take!; end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def third; end - - sig { returns(::HiperzServerInformation) } - def third!; end - - sig { returns(T.nilable(::HiperzServerInformation)) } - def third_to_last; end - - sig { returns(::HiperzServerInformation) } - def third_to_last!; end - end - - module GeneratedAssociationMethods - sig { params(args: T.untyped, blk: T.untyped).returns(::Server) } - def build_server(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::Server) } - def create_server(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::Server) } - def create_server!(*args, &blk); end - - sig { returns(T.nilable(::Server)) } - def reload_server; end - - sig { returns(T.nilable(::Server)) } - def server; end - - sig { params(value: T.nilable(::Server)).void } - def server=(value); end - end - - module GeneratedAssociationRelationMethods - sig { returns(PrivateAssociationRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def includes(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def unscope(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def without(*args, &blk); end - end - - module GeneratedAttributeMethods - sig { returns(T.nilable(::Integer)) } - def hiperz_id; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def hiperz_id=(value); end - - sig { returns(T::Boolean) } - def hiperz_id?; end - - sig { returns(T.nilable(::Integer)) } - def hiperz_id_before_last_save; end - - sig { returns(T.untyped) } - def hiperz_id_before_type_cast; end - - sig { returns(T::Boolean) } - def hiperz_id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def hiperz_id_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def hiperz_id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def hiperz_id_changed?; end - - sig { returns(T.nilable(::Integer)) } - def hiperz_id_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def hiperz_id_previous_change; end - - sig { returns(T::Boolean) } - def hiperz_id_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def hiperz_id_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def hiperz_id_was; end - - sig { void } - def hiperz_id_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def id; end - - sig { params(value: ::Integer).returns(::Integer) } - def id=(value); end - - sig { returns(T::Boolean) } - def id?; end - - sig { returns(T.nilable(::Integer)) } - def id_before_last_save; end - - sig { returns(T.untyped) } - def id_before_type_cast; end - - sig { returns(T::Boolean) } - def id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def id_changed?; end - - sig { returns(T.nilable(::Integer)) } - def id_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_previous_change; end - - sig { returns(T::Boolean) } - def id_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def id_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def id_was; end - - sig { void } - def id_will_change!; end - - sig { void } - def restore_hiperz_id!; end - - sig { void } - def restore_id!; end - - sig { void } - def restore_server_id!; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_hiperz_id; end - - sig { returns(T::Boolean) } - def saved_change_to_hiperz_id?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_id; end - - sig { returns(T::Boolean) } - def saved_change_to_id?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_server_id; end - - sig { returns(T::Boolean) } - def saved_change_to_server_id?; end - - sig { returns(T.nilable(::Integer)) } - def server_id; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def server_id=(value); end - - sig { returns(T::Boolean) } - def server_id?; end - - sig { returns(T.nilable(::Integer)) } - def server_id_before_last_save; end - - sig { returns(T.untyped) } - def server_id_before_type_cast; end - - sig { returns(T::Boolean) } - def server_id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def server_id_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def server_id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def server_id_changed?; end - - sig { returns(T.nilable(::Integer)) } - def server_id_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def server_id_previous_change; end - - sig { returns(T::Boolean) } - def server_id_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def server_id_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def server_id_was; end - - sig { void } - def server_id_will_change!; end - - sig { returns(T::Boolean) } - def will_save_change_to_hiperz_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_server_id?; end - end - - module GeneratedRelationMethods - sig { returns(PrivateRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def includes(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def unscope(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def without(*args, &blk); end - end - - class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::HiperzServerInformation } } - - sig { returns(T::Array[::HiperzServerInformation]) } - def to_ary; end - end - - class PrivateAssociationRelationWhereChain < PrivateAssociationRelation - Elem = type_member { { fixed: ::HiperzServerInformation } } - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateAssociationRelation) } - def not(opts, *rest); end - end - - class PrivateCollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::HiperzServerInformation } } - - sig do - params( - records: T.any(::HiperzServerInformation, T::Enumerable[T.any(::HiperzServerInformation, T::Enumerable[::HiperzServerInformation])]) - ).returns(PrivateCollectionProxy) - end - def <<(*records); end - - sig do - params( - records: T.any(::HiperzServerInformation, T::Enumerable[T.any(::HiperzServerInformation, T::Enumerable[::HiperzServerInformation])]) - ).returns(PrivateCollectionProxy) - end - def append(*records); end - - sig { returns(PrivateCollectionProxy) } - def clear; end - - sig do - params( - records: T.any(::HiperzServerInformation, T::Enumerable[T.any(::HiperzServerInformation, T::Enumerable[::HiperzServerInformation])]) - ).returns(PrivateCollectionProxy) - end - def concat(*records); end - - sig do - params( - records: T.any(::HiperzServerInformation, Integer, String, T::Enumerable[T.any(::HiperzServerInformation, Integer, String, T::Enumerable[::HiperzServerInformation])]) - ).returns(T::Array[::HiperzServerInformation]) - end - def delete(*records); end - - sig do - params( - records: T.any(::HiperzServerInformation, Integer, String, T::Enumerable[T.any(::HiperzServerInformation, Integer, String, T::Enumerable[::HiperzServerInformation])]) - ).returns(T::Array[::HiperzServerInformation]) - end - def destroy(*records); end - - sig { returns(T::Array[::HiperzServerInformation]) } - def load_target; end - - sig do - params( - records: T.any(::HiperzServerInformation, T::Enumerable[T.any(::HiperzServerInformation, T::Enumerable[::HiperzServerInformation])]) - ).returns(PrivateCollectionProxy) - end - def prepend(*records); end - - sig do - params( - records: T.any(::HiperzServerInformation, T::Enumerable[T.any(::HiperzServerInformation, T::Enumerable[::HiperzServerInformation])]) - ).returns(PrivateCollectionProxy) - end - def push(*records); end - - sig do - params( - other_array: T.any(::HiperzServerInformation, T::Enumerable[T.any(::HiperzServerInformation, T::Enumerable[::HiperzServerInformation])]) - ).returns(T::Array[::HiperzServerInformation]) - end - def replace(other_array); end - - sig { returns(PrivateAssociationRelation) } - def scope; end - - sig { returns(T::Array[::HiperzServerInformation]) } - def target; end - - sig { returns(T::Array[::HiperzServerInformation]) } - def to_ary; end - end - - class PrivateRelation < ::ActiveRecord::Relation - include CommonRelationMethods - include GeneratedRelationMethods - - Elem = type_member { { fixed: ::HiperzServerInformation } } - - sig { returns(T::Array[::HiperzServerInformation]) } - def to_ary; end - end - - class PrivateRelationWhereChain < PrivateRelation - Elem = type_member { { fixed: ::HiperzServerInformation } } - - sig { params(args: T.untyped).returns(PrivateRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateRelation) } - def not(opts, *rest); end - end -end diff --git a/sorbet/rbi/dsl/inactive_server_checker_worker.rbi b/sorbet/rbi/dsl/inactive_server_checker_worker.rbi index 6a02091e7..6f983d9bc 100644 --- a/sorbet/rbi/dsl/inactive_server_checker_worker.rbi +++ b/sorbet/rbi/dsl/inactive_server_checker_worker.rbi @@ -4,15 +4,16 @@ # This is an autogenerated file for dynamic methods in `InactiveServerCheckerWorker`. # Please instead update this file by running `bin/tapioca dsl InactiveServerCheckerWorker`. + class InactiveServerCheckerWorker class << self - sig { params(server_id: T.untyped).returns(String) } - def perform_async(server_id); end + sig { params(server_id: T.untyped, latest_version: T.untyped).returns(String) } + def perform_async(server_id, latest_version); end - sig { params(interval: T.any(DateTime, Time), server_id: T.untyped).returns(String) } - def perform_at(interval, server_id); end + sig { params(interval: T.any(DateTime, Time), server_id: T.untyped, latest_version: T.untyped).returns(String) } + def perform_at(interval, server_id, latest_version); end - sig { params(interval: Numeric, server_id: T.untyped).returns(String) } - def perform_in(interval, server_id); end + sig { params(interval: Numeric, server_id: T.untyped, latest_version: T.untyped).returns(String) } + def perform_in(interval, server_id, latest_version); end end end diff --git a/sorbet/rbi/dsl/inactive_servers_checker_worker.rbi b/sorbet/rbi/dsl/inactive_servers_checker_worker.rbi index 6e253d058..7a6670672 100644 --- a/sorbet/rbi/dsl/inactive_servers_checker_worker.rbi +++ b/sorbet/rbi/dsl/inactive_servers_checker_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `InactiveServersCheckerWorker`. # Please instead update this file by running `bin/tapioca dsl InactiveServersCheckerWorker`. + class InactiveServersCheckerWorker class << self sig { params(server_ids: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/league_requests_controller.rbi b/sorbet/rbi/dsl/league_requests_controller.rbi deleted file mode 100644 index 1c9dd40d7..000000000 --- a/sorbet/rbi/dsl/league_requests_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `LeagueRequestsController`. -# Please instead update this file by running `bin/tapioca dsl LeagueRequestsController`. - -class LeagueRequestsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/local_server.rbi b/sorbet/rbi/dsl/local_server.rbi index ee9839923..aab57c81c 100644 --- a/sorbet/rbi/dsl/local_server.rbi +++ b/sorbet/rbi/dsl/local_server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `LocalServer`. # Please instead update this file by running `bin/tapioca dsl LocalServer`. + class LocalServer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class LocalServer sig { params(block: T.nilable(T.proc.params(record: ::LocalServer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::LocalServer).void)).returns(::LocalServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class LocalServer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::LocalServer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::LocalServer).void)).returns(::LocalServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class LocalServer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::LocalServer).void)).returns(::LocalServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class LocalServer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class LocalServer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class LocalServer sig { returns(::LocalServer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::LocalServer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::LocalServer]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::LocalServer).void).returns(T.nilable(::LocalServer)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::LocalServer)) } def find_by(*args); end @@ -89,6 +134,54 @@ class LocalServer sig { params(args: T.untyped).returns(::LocalServer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::LocalServer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::LocalServer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::LocalServer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::LocalServer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class LocalServer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class LocalServer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class LocalServer sig { params(arg: T.untyped, args: T.untyped).returns(::LocalServer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::LocalServer)) } + sig { params(limit: Integer).returns(T::Array[::LocalServer]) } def first(limit = nil); end sig { returns(::LocalServer) } @@ -143,10 +249,36 @@ class LocalServer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::LocalServer)) } + sig { params(limit: Integer).returns(T::Array[::LocalServer]) } def last(limit = nil); end sig { returns(::LocalServer) } @@ -164,6 +296,13 @@ class LocalServer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::LocalServer).void)).returns(::LocalServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LocalServer).void) + ).returns(T::Array[::LocalServer]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class LocalServer sig { returns(::LocalServer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::LocalServer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::LocalServer)) } + sig { params(limit: Integer).returns(T::Array[::LocalServer]) } def take(limit = nil); end sig { returns(::LocalServer) } @@ -315,6 +457,9 @@ class LocalServer sig { params(value: T::Enumerable[::Reservation]).void } def reservations=(value); end + sig { void } + def reset_location; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -343,8 +488,8 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -358,8 +503,8 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -367,7 +512,7 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -379,40 +524,6 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -446,6 +557,9 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -470,6 +584,9 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -497,27 +614,15 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -550,8 +655,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -559,8 +664,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -595,8 +700,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def billing_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_in_database; end @@ -604,8 +709,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_previous_change; end - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_previously_was; end @@ -640,8 +745,13 @@ class LocalServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -649,8 +759,13 @@ class LocalServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -685,8 +800,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_in_database; end @@ -694,8 +809,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_previous_change; end - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_previously_was; end @@ -730,8 +845,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_port_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_in_database; end @@ -739,8 +854,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_previous_change; end - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_previously_was; end @@ -775,8 +890,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_username_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_in_database; end @@ -784,8 +899,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_previous_change; end - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_previously_was; end @@ -796,7 +911,7 @@ class LocalServer sig { void } def ftp_username_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -814,27 +929,72 @@ class LocalServer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -865,8 +1025,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -874,8 +1034,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -910,8 +1070,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_known_version_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_in_database; end @@ -919,8 +1079,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_previous_change; end - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_previously_was; end @@ -955,8 +1115,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_in_database; end @@ -964,8 +1124,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_previously_was; end @@ -1000,8 +1160,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_in_database; end @@ -1009,8 +1169,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_previously_was; end @@ -1045,8 +1205,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_in_database; end @@ -1054,8 +1214,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_previously_was; end @@ -1090,8 +1250,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1099,8 +1259,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1135,8 +1295,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def location_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_in_database; end @@ -1144,8 +1304,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_previous_change; end - sig { returns(T::Boolean) } - def location_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_previously_was; end @@ -1180,8 +1340,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1189,8 +1349,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1225,8 +1385,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1234,8 +1394,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1270,8 +1430,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_change_to_be_saved; end - sig { returns(T::Boolean) } - def path_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_in_database; end @@ -1279,8 +1439,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_previous_change; end - sig { returns(T::Boolean) } - def path_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_previously_was; end @@ -1315,8 +1475,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_change_to_be_saved; end - sig { returns(T::Boolean) } - def port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_in_database; end @@ -1324,8 +1484,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_previous_change; end - sig { returns(T::Boolean) } - def port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_previously_was; end @@ -1360,8 +1520,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_change_to_be_saved; end - sig { returns(T::Boolean) } - def position_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_in_database; end @@ -1369,8 +1529,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_previous_change; end - sig { returns(T::Boolean) } - def position_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_previously_was; end @@ -1405,8 +1565,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1414,8 +1574,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1447,6 +1607,9 @@ class LocalServer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -1540,12 +1703,18 @@ class LocalServer sig { returns(T::Boolean) } def saved_change_to_ftp_username?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -1684,8 +1853,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_in_database; end @@ -1693,8 +1862,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_previous_change; end - sig { returns(T::Boolean) } - def sdr_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_previously_was; end @@ -1729,8 +1898,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_in_database; end @@ -1738,8 +1907,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_previous_change; end - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_previously_was; end @@ -1774,8 +1943,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -1783,8 +1952,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -1819,8 +1988,13 @@ class LocalServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_in_database; end @@ -1828,8 +2002,13 @@ class LocalServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_previous_change; end - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_previously_was; end @@ -1864,8 +2043,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_in_database; end @@ -1873,8 +2052,8 @@ class LocalServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_previous_change; end - sig { returns(T::Boolean) } - def update_status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_previously_was; end @@ -1909,8 +2088,13 @@ class LocalServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1918,8 +2102,13 @@ class LocalServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1951,6 +2140,9 @@ class LocalServer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -2022,8 +2214,8 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -2037,8 +2229,8 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -2046,7 +2238,7 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2091,6 +2283,9 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2115,6 +2310,9 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2145,6 +2343,12 @@ class LocalServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2158,10 +2362,48 @@ class LocalServer Elem = type_member { { fixed: ::LocalServer } } + sig { returns(T::Array[::LocalServer]) } + def to_a; end + sig { returns(T::Array[::LocalServer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::LocalServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::LocalServer } } @@ -2205,20 +2447,6 @@ class LocalServer end def concat(*records); end - sig do - params( - records: T.any(::LocalServer, Integer, String, T::Enumerable[T.any(::LocalServer, Integer, String, T::Enumerable[::LocalServer])]) - ).returns(T::Array[::LocalServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::LocalServer, Integer, String, T::Enumerable[T.any(::LocalServer, Integer, String, T::Enumerable[::LocalServer])]) - ).returns(T::Array[::LocalServer]) - end - def destroy(*records); end - sig { returns(T::Array[::LocalServer]) } def load_target; end @@ -2249,6 +2477,9 @@ class LocalServer sig { returns(T::Array[::LocalServer]) } def target; end + sig { returns(T::Array[::LocalServer]) } + def to_a; end + sig { returns(T::Array[::LocalServer]) } def to_ary; end end @@ -2259,10 +2490,48 @@ class LocalServer Elem = type_member { { fixed: ::LocalServer } } + sig { returns(T::Array[::LocalServer]) } + def to_a; end + sig { returns(T::Array[::LocalServer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::LocalServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::LocalServer } } diff --git a/sorbet/rbi/dsl/location.rbi b/sorbet/rbi/dsl/location.rbi index 1b406dd36..c50a06cc1 100644 --- a/sorbet/rbi/dsl/location.rbi +++ b/sorbet/rbi/dsl/location.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Location`. # Please instead update this file by running `bin/tapioca dsl Location`. + class Location include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,27 +20,61 @@ class Location sig { params(block: T.nilable(T.proc.params(record: ::Location).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Location).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def create_or_find_by!(attributes, &block); end @@ -55,8 +90,18 @@ class Location sig { returns(::Location) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Location) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Location]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Location).void).returns(T.nilable(::Location)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Location)) } def find_by(*args); end @@ -64,12 +109,72 @@ class Location sig { params(args: T.untyped).returns(::Location) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Location).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Location]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Location]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Location]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def find_or_initialize_by(attributes, &block); end @@ -82,7 +187,8 @@ class Location sig { params(arg: T.untyped, args: T.untyped).returns(::Location) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Location)) } + sig { params(limit: Integer).returns(T::Array[::Location]) } def first(limit = nil); end sig { returns(::Location) } @@ -103,10 +209,36 @@ class Location sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Location)) } + sig { params(limit: Integer).returns(T::Array[::Location]) } def last(limit = nil); end sig { returns(::Location) } @@ -124,6 +256,13 @@ class Location sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Location).void) + ).returns(T::Array[::Location]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Location).void)).returns(::Location) } def new(attributes = nil, &block); end @@ -154,15 +293,18 @@ class Location sig { returns(::Location) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Location).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Location)) } + sig { params(limit: Integer).returns(T::Array[::Location]) } def take(limit = nil); end sig { returns(::Location) } @@ -210,8 +352,8 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -225,13 +367,13 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -243,40 +385,6 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -301,6 +409,9 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -325,6 +436,9 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -352,27 +466,15 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -402,8 +504,13 @@ class Location sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -411,8 +518,13 @@ class Location sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -447,8 +559,8 @@ class Location sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def flag_change_to_be_saved; end - sig { returns(T::Boolean) } - def flag_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def flag_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def flag_in_database; end @@ -456,8 +568,8 @@ class Location sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def flag_previous_change; end - sig { returns(T::Boolean) } - def flag_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def flag_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def flag_previously_was; end @@ -468,7 +580,7 @@ class Location sig { void } def flag_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -486,27 +598,72 @@ class Location sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -537,8 +694,8 @@ class Location sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -546,8 +703,8 @@ class Location sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -567,6 +724,9 @@ class Location sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_name!; end @@ -585,12 +745,18 @@ class Location sig { returns(T::Boolean) } def saved_change_to_flag?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_name; end @@ -627,8 +793,13 @@ class Location sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -636,8 +807,13 @@ class Location sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -657,6 +833,9 @@ class Location sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_name?; end @@ -677,8 +856,8 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -692,13 +871,13 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -734,6 +913,9 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -758,6 +940,9 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -788,6 +973,12 @@ class Location sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -798,10 +989,48 @@ class Location Elem = type_member { { fixed: ::Location } } + sig { returns(T::Array[::Location]) } + def to_a; end + sig { returns(T::Array[::Location]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Location } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Location } } @@ -845,20 +1074,6 @@ class Location end def concat(*records); end - sig do - params( - records: T.any(::Location, Integer, String, T::Enumerable[T.any(::Location, Integer, String, T::Enumerable[::Location])]) - ).returns(T::Array[::Location]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Location, Integer, String, T::Enumerable[T.any(::Location, Integer, String, T::Enumerable[::Location])]) - ).returns(T::Array[::Location]) - end - def destroy(*records); end - sig { returns(T::Array[::Location]) } def load_target; end @@ -889,6 +1104,9 @@ class Location sig { returns(T::Array[::Location]) } def target; end + sig { returns(T::Array[::Location]) } + def to_a; end + sig { returns(T::Array[::Location]) } def to_ary; end end @@ -899,10 +1117,48 @@ class Location Elem = type_member { { fixed: ::Location } } + sig { returns(T::Array[::Location]) } + def to_a; end + sig { returns(T::Array[::Location]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Location } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Location } } diff --git a/sorbet/rbi/dsl/log_scan_worker.rbi b/sorbet/rbi/dsl/log_scan_worker.rbi index 515e3b215..d7506e6be 100644 --- a/sorbet/rbi/dsl/log_scan_worker.rbi +++ b/sorbet/rbi/dsl/log_scan_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `LogScanWorker`. # Please instead update this file by running `bin/tapioca dsl LogScanWorker`. + class LogScanWorker class << self sig { params(reservation_id: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/log_upload.rbi b/sorbet/rbi/dsl/log_upload.rbi index 3db2f01ed..726d15ad6 100644 --- a/sorbet/rbi/dsl/log_upload.rbi +++ b/sorbet/rbi/dsl/log_upload.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `LogUpload`. # Please instead update this file by running `bin/tapioca dsl LogUpload`. + class LogUpload include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class LogUpload sig { params(block: T.nilable(T.proc.params(record: ::LogUpload).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::LogUpload).void)).returns(::LogUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class LogUpload end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::LogUpload).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::LogUpload).void)).returns(::LogUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class LogUpload end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::LogUpload).void)).returns(::LogUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class LogUpload end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class LogUpload end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class LogUpload sig { returns(::LogUpload) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::LogUpload) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::LogUpload]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::LogUpload).void).returns(T.nilable(::LogUpload)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::LogUpload)) } def find_by(*args); end @@ -89,6 +134,54 @@ class LogUpload sig { params(args: T.untyped).returns(::LogUpload) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::LogUpload).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::LogUpload]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::LogUpload]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::LogUpload]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class LogUpload end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class LogUpload end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class LogUpload sig { params(arg: T.untyped, args: T.untyped).returns(::LogUpload) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::LogUpload)) } + sig { params(limit: Integer).returns(T::Array[::LogUpload]) } def first(limit = nil); end sig { returns(::LogUpload) } @@ -143,10 +249,36 @@ class LogUpload sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::LogUpload)) } + sig { params(limit: Integer).returns(T::Array[::LogUpload]) } def last(limit = nil); end sig { returns(::LogUpload) } @@ -164,6 +296,13 @@ class LogUpload sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::LogUpload).void)).returns(::LogUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::LogUpload).void) + ).returns(T::Array[::LogUpload]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class LogUpload sig { returns(::LogUpload) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::LogUpload).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::LogUpload)) } + sig { params(limit: Integer).returns(T::Array[::LogUpload]) } def take(limit = nil); end sig { returns(::LogUpload) } @@ -244,6 +386,15 @@ class LogUpload sig { params(value: T.nilable(::Reservation)).void } def reservation=(value); end + + sig { returns(T::Boolean) } + def reservation_changed?; end + + sig { returns(T::Boolean) } + def reservation_previously_changed?; end + + sig { void } + def reset_reservation; end end module GeneratedAssociationRelationMethods @@ -259,8 +410,8 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -274,13 +425,13 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -292,40 +443,6 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -350,6 +467,9 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -374,6 +494,9 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -401,27 +524,15 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -451,8 +562,13 @@ class LogUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -460,8 +576,13 @@ class LogUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -496,8 +617,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_name_change_to_be_saved; end - sig { returns(T::Boolean) } - def file_name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_name_in_database; end @@ -505,8 +626,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_name_previous_change; end - sig { returns(T::Boolean) } - def file_name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_name_previously_was; end @@ -517,7 +638,7 @@ class LogUpload sig { void } def file_name_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -535,27 +656,72 @@ class LogUpload sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -586,8 +752,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def map_name_change_to_be_saved; end - sig { returns(T::Boolean) } - def map_name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def map_name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def map_name_in_database; end @@ -595,8 +761,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def map_name_previous_change; end - sig { returns(T::Boolean) } - def map_name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def map_name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def map_name_previously_was; end @@ -631,8 +797,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def reservation_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_in_database; end @@ -640,8 +806,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_id_previous_change; end - sig { returns(T::Boolean) } - def reservation_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_previously_was; end @@ -661,6 +827,9 @@ class LogUpload sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_map_name!; end @@ -691,12 +860,18 @@ class LogUpload sig { returns(T::Boolean) } def saved_change_to_file_name?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_map_name; end @@ -757,8 +932,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_change_to_be_saved; end - sig { returns(T::Boolean) } - def status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_in_database; end @@ -766,8 +941,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_previous_change; end - sig { returns(T::Boolean) } - def status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_previously_was; end @@ -802,8 +977,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def title_change_to_be_saved; end - sig { returns(T::Boolean) } - def title_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def title_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def title_in_database; end @@ -811,8 +986,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def title_previous_change; end - sig { returns(T::Boolean) } - def title_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def title_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def title_previously_was; end @@ -847,8 +1022,13 @@ class LogUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -856,8 +1036,13 @@ class LogUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -892,8 +1077,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def url_change_to_be_saved; end - sig { returns(T::Boolean) } - def url_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def url_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def url_in_database; end @@ -901,8 +1086,8 @@ class LogUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def url_previous_change; end - sig { returns(T::Boolean) } - def url_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def url_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def url_previously_was; end @@ -922,6 +1107,9 @@ class LogUpload sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_map_name?; end @@ -954,8 +1142,8 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -969,13 +1157,13 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -1011,6 +1199,9 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -1035,6 +1226,9 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1065,6 +1259,12 @@ class LogUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -1075,10 +1275,48 @@ class LogUpload Elem = type_member { { fixed: ::LogUpload } } + sig { returns(T::Array[::LogUpload]) } + def to_a; end + sig { returns(T::Array[::LogUpload]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::LogUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::LogUpload } } @@ -1122,20 +1360,6 @@ class LogUpload end def concat(*records); end - sig do - params( - records: T.any(::LogUpload, Integer, String, T::Enumerable[T.any(::LogUpload, Integer, String, T::Enumerable[::LogUpload])]) - ).returns(T::Array[::LogUpload]) - end - def delete(*records); end - - sig do - params( - records: T.any(::LogUpload, Integer, String, T::Enumerable[T.any(::LogUpload, Integer, String, T::Enumerable[::LogUpload])]) - ).returns(T::Array[::LogUpload]) - end - def destroy(*records); end - sig { returns(T::Array[::LogUpload]) } def load_target; end @@ -1166,6 +1390,9 @@ class LogUpload sig { returns(T::Array[::LogUpload]) } def target; end + sig { returns(T::Array[::LogUpload]) } + def to_a; end + sig { returns(T::Array[::LogUpload]) } def to_ary; end end @@ -1176,10 +1403,48 @@ class LogUpload Elem = type_member { { fixed: ::LogUpload } } + sig { returns(T::Array[::LogUpload]) } + def to_a; end + sig { returns(T::Array[::LogUpload]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::LogUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::LogUpload } } diff --git a/sorbet/rbi/dsl/log_uploads_controller.rbi b/sorbet/rbi/dsl/log_uploads_controller.rbi index 51b038d94..b1e28e159 100644 --- a/sorbet/rbi/dsl/log_uploads_controller.rbi +++ b/sorbet/rbi/dsl/log_uploads_controller.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `LogUploadsController`. # Please instead update this file by running `bin/tapioca dsl LogUploadsController`. + class LogUploadsController sig { returns(HelperProxy) } def helpers; end diff --git a/sorbet/rbi/dsl/log_worker.rbi b/sorbet/rbi/dsl/log_worker.rbi index 3b0a845c1..7cab229d7 100644 --- a/sorbet/rbi/dsl/log_worker.rbi +++ b/sorbet/rbi/dsl/log_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `LogWorker`. # Please instead update this file by running `bin/tapioca dsl LogWorker`. + class LogWorker class << self sig { params(raw_line: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/map_upload.rbi b/sorbet/rbi/dsl/map_upload.rbi index fc7d9e5f9..948ac8928 100644 --- a/sorbet/rbi/dsl/map_upload.rbi +++ b/sorbet/rbi/dsl/map_upload.rbi @@ -4,12 +4,19 @@ # This is an autogenerated file for dynamic methods in `MapUpload`. # Please instead update this file by running `bin/tapioca dsl MapUpload`. + class MapUpload include GeneratedAssociationMethods include GeneratedAttributeMethods extend CommonRelationMethods extend GeneratedRelationMethods + sig { returns(ActiveStorage::Attached::One) } + def file; end + + sig { params(attachable: T.untyped).returns(T.untyped) } + def file=(attachable); end + private sig { returns(NilClass) } @@ -19,9 +26,16 @@ class MapUpload sig { params(block: T.nilable(T.proc.params(record: ::MapUpload).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::MapUpload).void)).returns(::MapUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -30,12 +44,20 @@ class MapUpload end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::MapUpload).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::MapUpload).void)).returns(::MapUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -44,6 +66,13 @@ class MapUpload end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::MapUpload).void)).returns(::MapUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -52,6 +81,12 @@ class MapUpload end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -60,6 +95,12 @@ class MapUpload end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -80,8 +121,18 @@ class MapUpload sig { returns(::MapUpload) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::MapUpload) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::MapUpload]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::MapUpload).void).returns(T.nilable(::MapUpload)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::MapUpload)) } def find_by(*args); end @@ -89,6 +140,54 @@ class MapUpload sig { params(args: T.untyped).returns(::MapUpload) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::MapUpload).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::MapUpload]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::MapUpload]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::MapUpload]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -97,6 +196,12 @@ class MapUpload end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -105,6 +210,12 @@ class MapUpload end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -122,7 +233,8 @@ class MapUpload sig { params(arg: T.untyped, args: T.untyped).returns(::MapUpload) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::MapUpload)) } + sig { params(limit: Integer).returns(T::Array[::MapUpload]) } def first(limit = nil); end sig { returns(::MapUpload) } @@ -143,10 +255,36 @@ class MapUpload sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::MapUpload)) } + sig { params(limit: Integer).returns(T::Array[::MapUpload]) } def last(limit = nil); end sig { returns(::MapUpload) } @@ -164,6 +302,13 @@ class MapUpload sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::MapUpload).void)).returns(::MapUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::MapUpload).void) + ).returns(T::Array[::MapUpload]) + end sig do params( attributes: T.untyped, @@ -199,15 +344,18 @@ class MapUpload sig { returns(::MapUpload) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::MapUpload).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::MapUpload)) } + sig { params(limit: Integer).returns(T::Array[::MapUpload]) } def take(limit = nil); end sig { returns(::MapUpload) } @@ -227,23 +375,74 @@ class MapUpload end module GeneratedAssociationMethods + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } + def build_file_attachment(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } + def build_file_blob(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(::User) } def build_user(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } + def create_file_attachment(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Attachment) } + def create_file_attachment!(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } + def create_file_blob(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(::ActiveStorage::Blob) } + def create_file_blob!(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(::User) } def create_user(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(::User) } def create_user!(*args, &blk); end + sig { returns(T.nilable(::ActiveStorage::Attachment)) } + def file_attachment; end + + sig { params(value: T.nilable(::ActiveStorage::Attachment)).void } + def file_attachment=(value); end + + sig { returns(T.nilable(::ActiveStorage::Blob)) } + def file_blob; end + + sig { params(value: T.nilable(::ActiveStorage::Blob)).void } + def file_blob=(value); end + + sig { returns(T.nilable(::ActiveStorage::Attachment)) } + def reload_file_attachment; end + + sig { returns(T.nilable(::ActiveStorage::Blob)) } + def reload_file_blob; end + sig { returns(T.nilable(::User)) } def reload_user; end + sig { void } + def reset_file_attachment; end + + sig { void } + def reset_file_blob; end + + sig { void } + def reset_user; end + sig { returns(T.nilable(::User)) } def user; end sig { params(value: T.nilable(::User)).void } def user=(value); end + + sig { returns(T::Boolean) } + def user_changed?; end + + sig { returns(T::Boolean) } + def user_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -259,8 +458,8 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -274,13 +473,13 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -292,40 +491,6 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -350,6 +515,9 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -374,6 +542,9 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -401,27 +572,18 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_attached_file(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -451,8 +613,13 @@ class MapUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -460,8 +627,13 @@ class MapUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -496,8 +668,8 @@ class MapUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_change_to_be_saved; end - sig { returns(T::Boolean) } - def file_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_in_database; end @@ -505,8 +677,8 @@ class MapUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_previous_change; end - sig { returns(T::Boolean) } - def file_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_previously_was; end @@ -517,7 +689,7 @@ class MapUpload sig { void } def file_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -535,27 +707,72 @@ class MapUpload sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -586,8 +803,8 @@ class MapUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -595,8 +812,8 @@ class MapUpload sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -616,6 +833,9 @@ class MapUpload sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_name!; end @@ -637,12 +857,18 @@ class MapUpload sig { returns(T::Boolean) } def saved_change_to_file?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_name; end @@ -685,8 +911,13 @@ class MapUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -694,8 +925,13 @@ class MapUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -730,8 +966,8 @@ class MapUpload sig { returns(T.nilable([::Integer, ::Integer])) } def user_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def user_id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def user_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_in_database; end @@ -739,8 +975,8 @@ class MapUpload sig { returns(T.nilable([::Integer, ::Integer])) } def user_id_previous_change; end - sig { returns(T::Boolean) } - def user_id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def user_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_previously_was; end @@ -760,6 +996,9 @@ class MapUpload sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_name?; end @@ -783,8 +1022,8 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -798,13 +1037,13 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -840,6 +1079,9 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -864,6 +1106,9 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -894,6 +1139,15 @@ class MapUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_attached_file(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -904,10 +1158,48 @@ class MapUpload Elem = type_member { { fixed: ::MapUpload } } + sig { returns(T::Array[::MapUpload]) } + def to_a; end + sig { returns(T::Array[::MapUpload]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::MapUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::MapUpload } } @@ -951,20 +1243,6 @@ class MapUpload end def concat(*records); end - sig do - params( - records: T.any(::MapUpload, Integer, String, T::Enumerable[T.any(::MapUpload, Integer, String, T::Enumerable[::MapUpload])]) - ).returns(T::Array[::MapUpload]) - end - def delete(*records); end - - sig do - params( - records: T.any(::MapUpload, Integer, String, T::Enumerable[T.any(::MapUpload, Integer, String, T::Enumerable[::MapUpload])]) - ).returns(T::Array[::MapUpload]) - end - def destroy(*records); end - sig { returns(T::Array[::MapUpload]) } def load_target; end @@ -995,6 +1273,9 @@ class MapUpload sig { returns(T::Array[::MapUpload]) } def target; end + sig { returns(T::Array[::MapUpload]) } + def to_a; end + sig { returns(T::Array[::MapUpload]) } def to_ary; end end @@ -1005,10 +1286,48 @@ class MapUpload Elem = type_member { { fixed: ::MapUpload } } + sig { returns(T::Array[::MapUpload]) } + def to_a; end + sig { returns(T::Array[::MapUpload]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::MapUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::MapUpload } } diff --git a/sorbet/rbi/dsl/map_uploads_controller.rbi b/sorbet/rbi/dsl/map_uploads_controller.rbi deleted file mode 100644 index 5cc1e25f5..000000000 --- a/sorbet/rbi/dsl/map_uploads_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `MapUploadsController`. -# Please instead update this file by running `bin/tapioca dsl MapUploadsController`. - -class MapUploadsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/monthly_donation_progress_announcer_worker.rbi b/sorbet/rbi/dsl/monthly_donation_progress_announcer_worker.rbi index 1e01ded5d..1ac010d87 100644 --- a/sorbet/rbi/dsl/monthly_donation_progress_announcer_worker.rbi +++ b/sorbet/rbi/dsl/monthly_donation_progress_announcer_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `MonthlyDonationProgressAnnouncerWorker`. # Please instead update this file by running `bin/tapioca dsl MonthlyDonationProgressAnnouncerWorker`. + class MonthlyDonationProgressAnnouncerWorker class << self sig { returns(String) } diff --git a/sorbet/rbi/dsl/nfo_server.rbi b/sorbet/rbi/dsl/nfo_server.rbi index d3a1d705c..3ea120363 100644 --- a/sorbet/rbi/dsl/nfo_server.rbi +++ b/sorbet/rbi/dsl/nfo_server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `NfoServer`. # Please instead update this file by running `bin/tapioca dsl NfoServer`. + class NfoServer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class NfoServer sig { params(block: T.nilable(T.proc.params(record: ::NfoServer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::NfoServer).void)).returns(::NfoServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class NfoServer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::NfoServer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::NfoServer).void)).returns(::NfoServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class NfoServer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::NfoServer).void)).returns(::NfoServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class NfoServer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class NfoServer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class NfoServer sig { returns(::NfoServer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::NfoServer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::NfoServer]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::NfoServer).void).returns(T.nilable(::NfoServer)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::NfoServer)) } def find_by(*args); end @@ -89,6 +134,54 @@ class NfoServer sig { params(args: T.untyped).returns(::NfoServer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::NfoServer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::NfoServer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::NfoServer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::NfoServer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class NfoServer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class NfoServer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class NfoServer sig { params(arg: T.untyped, args: T.untyped).returns(::NfoServer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::NfoServer)) } + sig { params(limit: Integer).returns(T::Array[::NfoServer]) } def first(limit = nil); end sig { returns(::NfoServer) } @@ -143,10 +249,36 @@ class NfoServer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::NfoServer)) } + sig { params(limit: Integer).returns(T::Array[::NfoServer]) } def last(limit = nil); end sig { returns(::NfoServer) } @@ -164,6 +296,13 @@ class NfoServer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::NfoServer).void)).returns(::NfoServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::NfoServer).void) + ).returns(T::Array[::NfoServer]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class NfoServer sig { returns(::NfoServer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::NfoServer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::NfoServer)) } + sig { params(limit: Integer).returns(T::Array[::NfoServer]) } def take(limit = nil); end sig { returns(::NfoServer) } @@ -315,6 +457,9 @@ class NfoServer sig { params(value: T::Enumerable[::Reservation]).void } def reservations=(value); end + sig { void } + def reset_location; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -343,8 +488,8 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -358,8 +503,8 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -367,7 +512,7 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -379,40 +524,6 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -446,6 +557,9 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -470,6 +584,9 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -497,27 +614,15 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -550,8 +655,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -559,8 +664,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -595,8 +700,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def billing_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_in_database; end @@ -604,8 +709,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_previous_change; end - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_previously_was; end @@ -640,8 +745,13 @@ class NfoServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -649,8 +759,13 @@ class NfoServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -685,8 +800,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_in_database; end @@ -694,8 +809,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_previous_change; end - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_previously_was; end @@ -730,8 +845,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_port_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_in_database; end @@ -739,8 +854,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_previous_change; end - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_previously_was; end @@ -775,8 +890,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_username_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_in_database; end @@ -784,8 +899,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_previous_change; end - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_previously_was; end @@ -796,7 +911,7 @@ class NfoServer sig { void } def ftp_username_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -814,27 +929,72 @@ class NfoServer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -865,8 +1025,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -874,8 +1034,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -910,8 +1070,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_known_version_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_in_database; end @@ -919,8 +1079,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_previous_change; end - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_previously_was; end @@ -955,8 +1115,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_in_database; end @@ -964,8 +1124,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_previously_was; end @@ -1000,8 +1160,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_in_database; end @@ -1009,8 +1169,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_previously_was; end @@ -1045,8 +1205,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_in_database; end @@ -1054,8 +1214,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_previously_was; end @@ -1090,8 +1250,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1099,8 +1259,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1135,8 +1295,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def location_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_in_database; end @@ -1144,8 +1304,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_previous_change; end - sig { returns(T::Boolean) } - def location_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_previously_was; end @@ -1180,8 +1340,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1189,8 +1349,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1225,8 +1385,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1234,8 +1394,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1270,8 +1430,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_change_to_be_saved; end - sig { returns(T::Boolean) } - def path_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_in_database; end @@ -1279,8 +1439,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_previous_change; end - sig { returns(T::Boolean) } - def path_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_previously_was; end @@ -1315,8 +1475,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_change_to_be_saved; end - sig { returns(T::Boolean) } - def port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_in_database; end @@ -1324,8 +1484,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_previous_change; end - sig { returns(T::Boolean) } - def port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_previously_was; end @@ -1360,8 +1520,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_change_to_be_saved; end - sig { returns(T::Boolean) } - def position_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_in_database; end @@ -1369,8 +1529,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_previous_change; end - sig { returns(T::Boolean) } - def position_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_previously_was; end @@ -1405,8 +1565,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1414,8 +1574,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1447,6 +1607,9 @@ class NfoServer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -1540,12 +1703,18 @@ class NfoServer sig { returns(T::Boolean) } def saved_change_to_ftp_username?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -1684,8 +1853,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_in_database; end @@ -1693,8 +1862,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_previous_change; end - sig { returns(T::Boolean) } - def sdr_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_previously_was; end @@ -1729,8 +1898,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_in_database; end @@ -1738,8 +1907,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_previous_change; end - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_previously_was; end @@ -1774,8 +1943,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -1783,8 +1952,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -1819,8 +1988,13 @@ class NfoServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_in_database; end @@ -1828,8 +2002,13 @@ class NfoServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_previous_change; end - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_previously_was; end @@ -1864,8 +2043,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_in_database; end @@ -1873,8 +2052,8 @@ class NfoServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_previous_change; end - sig { returns(T::Boolean) } - def update_status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_previously_was; end @@ -1909,8 +2088,13 @@ class NfoServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1918,8 +2102,13 @@ class NfoServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1951,6 +2140,9 @@ class NfoServer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -2022,8 +2214,8 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -2037,8 +2229,8 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -2046,7 +2238,7 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2091,6 +2283,9 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2115,6 +2310,9 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2145,6 +2343,12 @@ class NfoServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2158,10 +2362,48 @@ class NfoServer Elem = type_member { { fixed: ::NfoServer } } + sig { returns(T::Array[::NfoServer]) } + def to_a; end + sig { returns(T::Array[::NfoServer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::NfoServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::NfoServer } } @@ -2205,20 +2447,6 @@ class NfoServer end def concat(*records); end - sig do - params( - records: T.any(::NfoServer, Integer, String, T::Enumerable[T.any(::NfoServer, Integer, String, T::Enumerable[::NfoServer])]) - ).returns(T::Array[::NfoServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::NfoServer, Integer, String, T::Enumerable[T.any(::NfoServer, Integer, String, T::Enumerable[::NfoServer])]) - ).returns(T::Array[::NfoServer]) - end - def destroy(*records); end - sig { returns(T::Array[::NfoServer]) } def load_target; end @@ -2249,6 +2477,9 @@ class NfoServer sig { returns(T::Array[::NfoServer]) } def target; end + sig { returns(T::Array[::NfoServer]) } + def to_a; end + sig { returns(T::Array[::NfoServer]) } def to_ary; end end @@ -2259,10 +2490,48 @@ class NfoServer Elem = type_member { { fixed: ::NfoServer } } + sig { returns(T::Array[::NfoServer]) } + def to_a; end + sig { returns(T::Array[::NfoServer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::NfoServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::NfoServer } } diff --git a/sorbet/rbi/dsl/order.rbi b/sorbet/rbi/dsl/order.rbi index a77c2c1db..1a88fedd0 100644 --- a/sorbet/rbi/dsl/order.rbi +++ b/sorbet/rbi/dsl/order.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Order`. # Please instead update this file by running `bin/tapioca dsl Order`. + class Order include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,27 +20,61 @@ class Order sig { params(block: T.nilable(T.proc.params(record: ::Order).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Order).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def create_or_find_by!(attributes, &block); end @@ -55,8 +90,18 @@ class Order sig { returns(::Order) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Order) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Order]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Order).void).returns(T.nilable(::Order)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Order)) } def find_by(*args); end @@ -64,12 +109,72 @@ class Order sig { params(args: T.untyped).returns(::Order) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Order).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Order]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Order]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Order]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def find_or_initialize_by(attributes, &block); end @@ -82,7 +187,8 @@ class Order sig { params(arg: T.untyped, args: T.untyped).returns(::Order) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Order)) } + sig { params(limit: Integer).returns(T::Array[::Order]) } def first(limit = nil); end sig { returns(::Order) } @@ -103,10 +209,36 @@ class Order sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Order)) } + sig { params(limit: Integer).returns(T::Array[::Order]) } def last(limit = nil); end sig { returns(::Order) } @@ -124,6 +256,13 @@ class Order sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Order).void) + ).returns(T::Array[::Order]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Order).void)).returns(::Order) } def new(attributes = nil, &block); end @@ -154,15 +293,18 @@ class Order sig { returns(::Order) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Order).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Order)) } + sig { params(limit: Integer).returns(T::Array[::Order]) } def take(limit = nil); end sig { returns(::Order) } @@ -215,6 +357,12 @@ class Order sig { params(value: T.nilable(::Product)).void } def product=(value); end + sig { returns(T::Boolean) } + def product_changed?; end + + sig { returns(T::Boolean) } + def product_previously_changed?; end + sig { returns(T.nilable(::Product)) } def reload_product; end @@ -224,12 +372,27 @@ class Order sig { returns(T.nilable(::Voucher)) } def reload_voucher; end + sig { void } + def reset_product; end + + sig { void } + def reset_user; end + + sig { void } + def reset_voucher; end + sig { returns(T.nilable(::User)) } def user; end sig { params(value: T.nilable(::User)).void } def user=(value); end + sig { returns(T::Boolean) } + def user_changed?; end + + sig { returns(T::Boolean) } + def user_previously_changed?; end + sig { returns(T.nilable(::Voucher)) } def voucher; end @@ -250,8 +413,8 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -265,13 +428,13 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -283,40 +446,6 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -341,6 +470,9 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -365,6 +497,9 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -392,27 +527,15 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -442,8 +565,13 @@ class Order sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -451,8 +579,13 @@ class Order sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -487,8 +620,8 @@ class Order sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def gift_change_to_be_saved; end - sig { returns(T::Boolean) } - def gift_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def gift_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def gift_in_database; end @@ -496,8 +629,8 @@ class Order sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def gift_previous_change; end - sig { returns(T::Boolean) } - def gift_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def gift_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def gift_previously_was; end @@ -508,7 +641,7 @@ class Order sig { void } def gift_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -526,27 +659,72 @@ class Order sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -577,8 +755,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payer_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def payer_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payer_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payer_id_in_database; end @@ -586,8 +764,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payer_id_previous_change; end - sig { returns(T::Boolean) } - def payer_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payer_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payer_id_previously_was; end @@ -622,8 +800,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payment_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def payment_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payment_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payment_id_in_database; end @@ -631,8 +809,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payment_id_previous_change; end - sig { returns(T::Boolean) } - def payment_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payment_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payment_id_previously_was; end @@ -667,8 +845,8 @@ class Order sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def product_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_in_database; end @@ -676,8 +854,8 @@ class Order sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_previous_change; end - sig { returns(T::Boolean) } - def product_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_previously_was; end @@ -697,6 +875,9 @@ class Order sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_payer_id!; end @@ -730,12 +911,18 @@ class Order sig { returns(T::Boolean) } def saved_change_to_gift?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_payer_id; end @@ -802,8 +989,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_change_to_be_saved; end - sig { returns(T::Boolean) } - def status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_in_database; end @@ -811,8 +998,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_previous_change; end - sig { returns(T::Boolean) } - def status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_previously_was; end @@ -847,8 +1034,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -856,8 +1043,8 @@ class Order sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -892,8 +1079,13 @@ class Order sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -901,8 +1093,13 @@ class Order sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -937,8 +1134,8 @@ class Order sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def user_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_in_database; end @@ -946,8 +1143,8 @@ class Order sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_previous_change; end - sig { returns(T::Boolean) } - def user_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_previously_was; end @@ -967,6 +1164,9 @@ class Order sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_payer_id?; end @@ -1002,8 +1202,8 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -1017,13 +1217,13 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -1059,6 +1259,9 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -1083,6 +1286,9 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1113,6 +1319,12 @@ class Order sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -1123,10 +1335,48 @@ class Order Elem = type_member { { fixed: ::Order } } + sig { returns(T::Array[::Order]) } + def to_a; end + sig { returns(T::Array[::Order]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Order } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Order } } @@ -1170,20 +1420,6 @@ class Order end def concat(*records); end - sig do - params( - records: T.any(::Order, Integer, String, T::Enumerable[T.any(::Order, Integer, String, T::Enumerable[::Order])]) - ).returns(T::Array[::Order]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Order, Integer, String, T::Enumerable[T.any(::Order, Integer, String, T::Enumerable[::Order])]) - ).returns(T::Array[::Order]) - end - def destroy(*records); end - sig { returns(T::Array[::Order]) } def load_target; end @@ -1214,6 +1450,9 @@ class Order sig { returns(T::Array[::Order]) } def target; end + sig { returns(T::Array[::Order]) } + def to_a; end + sig { returns(T::Array[::Order]) } def to_ary; end end @@ -1224,10 +1463,48 @@ class Order Elem = type_member { { fixed: ::Order } } + sig { returns(T::Array[::Order]) } + def to_a; end + sig { returns(T::Array[::Order]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Order } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Order } } diff --git a/sorbet/rbi/dsl/orders_controller.rbi b/sorbet/rbi/dsl/orders_controller.rbi deleted file mode 100644 index eb12bb032..000000000 --- a/sorbet/rbi/dsl/orders_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `OrdersController`. -# Please instead update this file by running `bin/tapioca dsl OrdersController`. - -class OrdersController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/pages_controller.rbi b/sorbet/rbi/dsl/pages_controller.rbi deleted file mode 100644 index 1cb6a4adb..000000000 --- a/sorbet/rbi/dsl/pages_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `PagesController`. -# Please instead update this file by running `bin/tapioca dsl PagesController`. - -class PagesController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/paypal_order.rbi b/sorbet/rbi/dsl/paypal_order.rbi index 8386b051f..1ee835fad 100644 --- a/sorbet/rbi/dsl/paypal_order.rbi +++ b/sorbet/rbi/dsl/paypal_order.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `PaypalOrder`. # Please instead update this file by running `bin/tapioca dsl PaypalOrder`. + class PaypalOrder include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class PaypalOrder sig { params(block: T.nilable(T.proc.params(record: ::PaypalOrder).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::PaypalOrder).void)).returns(::PaypalOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class PaypalOrder end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::PaypalOrder).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::PaypalOrder).void)).returns(::PaypalOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class PaypalOrder end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::PaypalOrder).void)).returns(::PaypalOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class PaypalOrder end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class PaypalOrder end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class PaypalOrder sig { returns(::PaypalOrder) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::PaypalOrder) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::PaypalOrder]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::PaypalOrder).void).returns(T.nilable(::PaypalOrder)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::PaypalOrder)) } def find_by(*args); end @@ -89,6 +134,54 @@ class PaypalOrder sig { params(args: T.untyped).returns(::PaypalOrder) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::PaypalOrder).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::PaypalOrder]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::PaypalOrder]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::PaypalOrder]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class PaypalOrder end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class PaypalOrder end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class PaypalOrder sig { params(arg: T.untyped, args: T.untyped).returns(::PaypalOrder) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::PaypalOrder)) } + sig { params(limit: Integer).returns(T::Array[::PaypalOrder]) } def first(limit = nil); end sig { returns(::PaypalOrder) } @@ -143,10 +249,36 @@ class PaypalOrder sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::PaypalOrder)) } + sig { params(limit: Integer).returns(T::Array[::PaypalOrder]) } def last(limit = nil); end sig { returns(::PaypalOrder) } @@ -164,6 +296,13 @@ class PaypalOrder sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::PaypalOrder).void)).returns(::PaypalOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PaypalOrder).void) + ).returns(T::Array[::PaypalOrder]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class PaypalOrder sig { returns(::PaypalOrder) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::PaypalOrder).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::PaypalOrder)) } + sig { params(limit: Integer).returns(T::Array[::PaypalOrder]) } def take(limit = nil); end sig { returns(::PaypalOrder) } @@ -269,6 +411,15 @@ class PaypalOrder sig { returns(T.nilable(::Voucher)) } def reload_voucher; end + sig { void } + def reset_product; end + + sig { void } + def reset_user; end + + sig { void } + def reset_voucher; end + sig { returns(T.nilable(::User)) } def user; end @@ -295,8 +446,8 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -310,13 +461,13 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -328,40 +479,6 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -386,6 +503,9 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -410,6 +530,9 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -437,27 +560,15 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -487,8 +598,13 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -496,8 +612,13 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -532,8 +653,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def gift_change_to_be_saved; end - sig { returns(T::Boolean) } - def gift_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def gift_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def gift_in_database; end @@ -541,8 +662,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def gift_previous_change; end - sig { returns(T::Boolean) } - def gift_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def gift_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def gift_previously_was; end @@ -553,7 +674,7 @@ class PaypalOrder sig { void } def gift_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -571,27 +692,72 @@ class PaypalOrder sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -622,8 +788,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payer_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def payer_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payer_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payer_id_in_database; end @@ -631,8 +797,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payer_id_previous_change; end - sig { returns(T::Boolean) } - def payer_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payer_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payer_id_previously_was; end @@ -667,8 +833,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payment_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def payment_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payment_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payment_id_in_database; end @@ -676,8 +842,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payment_id_previous_change; end - sig { returns(T::Boolean) } - def payment_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payment_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payment_id_previously_was; end @@ -712,8 +878,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def product_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_in_database; end @@ -721,8 +887,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_previous_change; end - sig { returns(T::Boolean) } - def product_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_previously_was; end @@ -742,6 +908,9 @@ class PaypalOrder sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_payer_id!; end @@ -775,12 +944,18 @@ class PaypalOrder sig { returns(T::Boolean) } def saved_change_to_gift?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_payer_id; end @@ -847,8 +1022,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_change_to_be_saved; end - sig { returns(T::Boolean) } - def status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_in_database; end @@ -856,8 +1031,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_previous_change; end - sig { returns(T::Boolean) } - def status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_previously_was; end @@ -892,8 +1067,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -901,8 +1076,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -937,8 +1112,13 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -946,8 +1126,13 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -982,8 +1167,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def user_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_in_database; end @@ -991,8 +1176,8 @@ class PaypalOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_previous_change; end - sig { returns(T::Boolean) } - def user_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_previously_was; end @@ -1012,6 +1197,9 @@ class PaypalOrder sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_payer_id?; end @@ -1047,8 +1235,8 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -1062,13 +1250,13 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -1104,6 +1292,9 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -1128,6 +1319,9 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1158,6 +1352,12 @@ class PaypalOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -1168,10 +1368,48 @@ class PaypalOrder Elem = type_member { { fixed: ::PaypalOrder } } + sig { returns(T::Array[::PaypalOrder]) } + def to_a; end + sig { returns(T::Array[::PaypalOrder]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::PaypalOrder } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::PaypalOrder } } @@ -1215,20 +1453,6 @@ class PaypalOrder end def concat(*records); end - sig do - params( - records: T.any(::PaypalOrder, Integer, String, T::Enumerable[T.any(::PaypalOrder, Integer, String, T::Enumerable[::PaypalOrder])]) - ).returns(T::Array[::PaypalOrder]) - end - def delete(*records); end - - sig do - params( - records: T.any(::PaypalOrder, Integer, String, T::Enumerable[T.any(::PaypalOrder, Integer, String, T::Enumerable[::PaypalOrder])]) - ).returns(T::Array[::PaypalOrder]) - end - def destroy(*records); end - sig { returns(T::Array[::PaypalOrder]) } def load_target; end @@ -1259,6 +1483,9 @@ class PaypalOrder sig { returns(T::Array[::PaypalOrder]) } def target; end + sig { returns(T::Array[::PaypalOrder]) } + def to_a; end + sig { returns(T::Array[::PaypalOrder]) } def to_ary; end end @@ -1269,10 +1496,48 @@ class PaypalOrder Elem = type_member { { fixed: ::PaypalOrder } } + sig { returns(T::Array[::PaypalOrder]) } + def to_a; end + sig { returns(T::Array[::PaypalOrder]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::PaypalOrder } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::PaypalOrder } } diff --git a/sorbet/rbi/dsl/player_statistic.rbi b/sorbet/rbi/dsl/player_statistic.rbi index 1d42437a7..7336c276b 100644 --- a/sorbet/rbi/dsl/player_statistic.rbi +++ b/sorbet/rbi/dsl/player_statistic.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `PlayerStatistic`. # Please instead update this file by running `bin/tapioca dsl PlayerStatistic`. + class PlayerStatistic include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class PlayerStatistic sig { params(block: T.nilable(T.proc.params(record: ::PlayerStatistic).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::PlayerStatistic).void)).returns(::PlayerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class PlayerStatistic end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::PlayerStatistic).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::PlayerStatistic).void)).returns(::PlayerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class PlayerStatistic end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::PlayerStatistic).void)).returns(::PlayerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class PlayerStatistic end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class PlayerStatistic end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class PlayerStatistic sig { returns(::PlayerStatistic) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::PlayerStatistic) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::PlayerStatistic]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::PlayerStatistic).void + ).returns(T.nilable(::PlayerStatistic)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::PlayerStatistic)) } def find_by(*args); end @@ -89,6 +139,54 @@ class PlayerStatistic sig { params(args: T.untyped).returns(::PlayerStatistic) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::PlayerStatistic).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::PlayerStatistic]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::PlayerStatistic]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::PlayerStatistic]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class PlayerStatistic end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class PlayerStatistic end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class PlayerStatistic sig { params(arg: T.untyped, args: T.untyped).returns(::PlayerStatistic) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::PlayerStatistic)) } + sig { params(limit: Integer).returns(T::Array[::PlayerStatistic]) } def first(limit = nil); end sig { returns(::PlayerStatistic) } @@ -143,10 +254,36 @@ class PlayerStatistic sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::PlayerStatistic)) } + sig { params(limit: Integer).returns(T::Array[::PlayerStatistic]) } def last(limit = nil); end sig { returns(::PlayerStatistic) } @@ -164,6 +301,13 @@ class PlayerStatistic sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::PlayerStatistic).void)).returns(::PlayerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::PlayerStatistic).void) + ).returns(T::Array[::PlayerStatistic]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class PlayerStatistic sig { returns(::PlayerStatistic) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::PlayerStatistic).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::PlayerStatistic)) } + sig { params(limit: Integer).returns(T::Array[::PlayerStatistic]) } def take(limit = nil); end sig { returns(::PlayerStatistic) } @@ -287,6 +434,24 @@ class PlayerStatistic sig { params(value: T.nilable(::ReservationPlayer)).void } def reservation_player=(value); end + sig { returns(T::Boolean) } + def reservation_player_changed?; end + + sig { returns(T::Boolean) } + def reservation_player_previously_changed?; end + + sig { void } + def reset_reservation; end + + sig { void } + def reset_reservation_player; end + + sig { void } + def reset_server; end + + sig { void } + def reset_user; end + sig { returns(T.nilable(::Server)) } def server; end @@ -313,8 +478,8 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -328,13 +493,13 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -346,40 +511,6 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -404,6 +535,9 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -428,6 +562,9 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -455,27 +592,15 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -505,8 +630,13 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -514,8 +644,13 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -526,7 +661,7 @@ class PlayerStatistic sig { void } def created_at_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -544,27 +679,72 @@ class PlayerStatistic sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -595,8 +775,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def loss_change_to_be_saved; end - sig { returns(T::Boolean) } - def loss_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def loss_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def loss_in_database; end @@ -604,8 +784,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def loss_previous_change; end - sig { returns(T::Boolean) } - def loss_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def loss_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def loss_previously_was; end @@ -640,8 +820,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def minutes_connected_change_to_be_saved; end - sig { returns(T::Boolean) } - def minutes_connected_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def minutes_connected_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def minutes_connected_in_database; end @@ -649,8 +829,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def minutes_connected_previous_change; end - sig { returns(T::Boolean) } - def minutes_connected_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def minutes_connected_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def minutes_connected_previously_was; end @@ -685,8 +865,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ping_change_to_be_saved; end - sig { returns(T::Boolean) } - def ping_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ping_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ping_in_database; end @@ -694,8 +874,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ping_previous_change; end - sig { returns(T::Boolean) } - def ping_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ping_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ping_previously_was; end @@ -730,8 +910,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_player_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def reservation_player_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_player_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_player_id_in_database; end @@ -739,8 +919,8 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_player_id_previous_change; end - sig { returns(T::Boolean) } - def reservation_player_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_player_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_player_id_previously_was; end @@ -757,6 +937,9 @@ class PlayerStatistic sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_loss!; end @@ -778,12 +961,18 @@ class PlayerStatistic sig { returns(T::Boolean) } def saved_change_to_created_at?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def saved_change_to_loss; end @@ -838,8 +1027,13 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -847,8 +1041,13 @@ class PlayerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -865,6 +1064,9 @@ class PlayerStatistic sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_loss?; end @@ -894,8 +1096,8 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -909,13 +1111,13 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -951,6 +1153,9 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -975,6 +1180,9 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1005,6 +1213,12 @@ class PlayerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -1015,10 +1229,48 @@ class PlayerStatistic Elem = type_member { { fixed: ::PlayerStatistic } } + sig { returns(T::Array[::PlayerStatistic]) } + def to_a; end + sig { returns(T::Array[::PlayerStatistic]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::PlayerStatistic } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::PlayerStatistic } } @@ -1062,20 +1314,6 @@ class PlayerStatistic end def concat(*records); end - sig do - params( - records: T.any(::PlayerStatistic, Integer, String, T::Enumerable[T.any(::PlayerStatistic, Integer, String, T::Enumerable[::PlayerStatistic])]) - ).returns(T::Array[::PlayerStatistic]) - end - def delete(*records); end - - sig do - params( - records: T.any(::PlayerStatistic, Integer, String, T::Enumerable[T.any(::PlayerStatistic, Integer, String, T::Enumerable[::PlayerStatistic])]) - ).returns(T::Array[::PlayerStatistic]) - end - def destroy(*records); end - sig { returns(T::Array[::PlayerStatistic]) } def load_target; end @@ -1106,6 +1344,9 @@ class PlayerStatistic sig { returns(T::Array[::PlayerStatistic]) } def target; end + sig { returns(T::Array[::PlayerStatistic]) } + def to_a; end + sig { returns(T::Array[::PlayerStatistic]) } def to_ary; end end @@ -1116,10 +1357,48 @@ class PlayerStatistic Elem = type_member { { fixed: ::PlayerStatistic } } + sig { returns(T::Array[::PlayerStatistic]) } + def to_a; end + sig { returns(T::Array[::PlayerStatistic]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::PlayerStatistic } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::PlayerStatistic } } diff --git a/sorbet/rbi/dsl/player_statistics_controller.rbi b/sorbet/rbi/dsl/player_statistics_controller.rbi deleted file mode 100644 index 1dffe604e..000000000 --- a/sorbet/rbi/dsl/player_statistics_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `PlayerStatisticsController`. -# Please instead update this file by running `bin/tapioca dsl PlayerStatisticsController`. - -class PlayerStatisticsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/private_server_cleanup_worker.rbi b/sorbet/rbi/dsl/private_server_cleanup_worker.rbi index daab33c87..01a3296d8 100644 --- a/sorbet/rbi/dsl/private_server_cleanup_worker.rbi +++ b/sorbet/rbi/dsl/private_server_cleanup_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `PrivateServerCleanupWorker`. # Please instead update this file by running `bin/tapioca dsl PrivateServerCleanupWorker`. + class PrivateServerCleanupWorker class << self sig { returns(String) } diff --git a/sorbet/rbi/dsl/private_servers_controller.rbi b/sorbet/rbi/dsl/private_servers_controller.rbi deleted file mode 100644 index e9547182b..000000000 --- a/sorbet/rbi/dsl/private_servers_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `PrivateServersController`. -# Please instead update this file by running `bin/tapioca dsl PrivateServersController`. - -class PrivateServersController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/product.rbi b/sorbet/rbi/dsl/product.rbi index a4c446138..1225760e6 100644 --- a/sorbet/rbi/dsl/product.rbi +++ b/sorbet/rbi/dsl/product.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Product`. # Please instead update this file by running `bin/tapioca dsl Product`. + class Product include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,27 +20,61 @@ class Product sig { params(block: T.nilable(T.proc.params(record: ::Product).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Product).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def create_or_find_by!(attributes, &block); end @@ -55,8 +90,18 @@ class Product sig { returns(::Product) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Product) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Product]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Product).void).returns(T.nilable(::Product)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Product)) } def find_by(*args); end @@ -64,12 +109,72 @@ class Product sig { params(args: T.untyped).returns(::Product) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Product).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Product]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Product]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Product]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def find_or_initialize_by(attributes, &block); end @@ -82,7 +187,8 @@ class Product sig { params(arg: T.untyped, args: T.untyped).returns(::Product) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Product)) } + sig { params(limit: Integer).returns(T::Array[::Product]) } def first(limit = nil); end sig { returns(::Product) } @@ -103,10 +209,36 @@ class Product sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Product)) } + sig { params(limit: Integer).returns(T::Array[::Product]) } def last(limit = nil); end sig { returns(::Product) } @@ -124,6 +256,13 @@ class Product sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Product).void) + ).returns(T::Array[::Product]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Product).void)).returns(::Product) } def new(attributes = nil, &block); end @@ -154,15 +293,18 @@ class Product sig { returns(::Product) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Product).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Product)) } + sig { params(limit: Integer).returns(T::Array[::Product]) } def take(limit = nil); end sig { returns(::Product) } @@ -210,8 +352,8 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -225,13 +367,13 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -243,40 +385,6 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -301,6 +409,9 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -325,6 +436,9 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -352,27 +466,15 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -402,8 +504,8 @@ class Product sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -411,8 +513,8 @@ class Product sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -447,8 +549,8 @@ class Product sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def currency_change_to_be_saved; end - sig { returns(T::Boolean) } - def currency_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def currency_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def currency_in_database; end @@ -456,8 +558,8 @@ class Product sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def currency_previous_change; end - sig { returns(T::Boolean) } - def currency_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def currency_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def currency_previously_was; end @@ -492,8 +594,8 @@ class Product sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def days_change_to_be_saved; end - sig { returns(T::Boolean) } - def days_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def days_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def days_in_database; end @@ -501,8 +603,8 @@ class Product sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def days_previous_change; end - sig { returns(T::Boolean) } - def days_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def days_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def days_previously_was; end @@ -537,8 +639,8 @@ class Product sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def grants_private_server_change_to_be_saved; end - sig { returns(T::Boolean) } - def grants_private_server_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def grants_private_server_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def grants_private_server_in_database; end @@ -546,8 +648,8 @@ class Product sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def grants_private_server_previous_change; end - sig { returns(T::Boolean) } - def grants_private_server_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def grants_private_server_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def grants_private_server_previously_was; end @@ -558,7 +660,7 @@ class Product sig { void } def grants_private_server_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -576,27 +678,72 @@ class Product sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -627,8 +774,8 @@ class Product sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -636,8 +783,8 @@ class Product sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -672,8 +819,8 @@ class Product sig { returns(T.nilable([::BigDecimal, ::BigDecimal])) } def price_change_to_be_saved; end - sig { returns(T::Boolean) } - def price_changed?; end + sig { params(from: ::BigDecimal, to: ::BigDecimal).returns(T::Boolean) } + def price_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::BigDecimal)) } def price_in_database; end @@ -681,8 +828,8 @@ class Product sig { returns(T.nilable([::BigDecimal, ::BigDecimal])) } def price_previous_change; end - sig { returns(T::Boolean) } - def price_previously_changed?; end + sig { params(from: ::BigDecimal, to: ::BigDecimal).returns(T::Boolean) } + def price_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::BigDecimal)) } def price_previously_was; end @@ -708,6 +855,9 @@ class Product sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_name!; end @@ -738,12 +888,18 @@ class Product sig { returns(T::Boolean) } def saved_change_to_grants_private_server?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_name; end @@ -771,6 +927,9 @@ class Product sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_name?; end @@ -791,8 +950,8 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -806,13 +965,13 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -848,6 +1007,9 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -872,6 +1034,9 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -902,6 +1067,12 @@ class Product sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -912,10 +1083,48 @@ class Product Elem = type_member { { fixed: ::Product } } + sig { returns(T::Array[::Product]) } + def to_a; end + sig { returns(T::Array[::Product]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Product } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Product } } @@ -959,20 +1168,6 @@ class Product end def concat(*records); end - sig do - params( - records: T.any(::Product, Integer, String, T::Enumerable[T.any(::Product, Integer, String, T::Enumerable[::Product])]) - ).returns(T::Array[::Product]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Product, Integer, String, T::Enumerable[T.any(::Product, Integer, String, T::Enumerable[::Product])]) - ).returns(T::Array[::Product]) - end - def destroy(*records); end - sig { returns(T::Array[::Product]) } def load_target; end @@ -1003,6 +1198,9 @@ class Product sig { returns(T::Array[::Product]) } def target; end + sig { returns(T::Array[::Product]) } + def to_a; end + sig { returns(T::Array[::Product]) } def to_ary; end end @@ -1013,10 +1211,48 @@ class Product Elem = type_member { { fixed: ::Product } } + sig { returns(T::Array[::Product]) } + def to_a; end + sig { returns(T::Array[::Product]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Product } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Product } } diff --git a/sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails/sources_controller.rbi b/sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails/sources_controller.rbi deleted file mode 100644 index 2ed2cd59f..000000000 --- a/sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails/sources_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Rails::Conductor::ActionMailbox::InboundEmails::SourcesController`. -# Please instead update this file by running `bin/tapioca dsl Rails::Conductor::ActionMailbox::InboundEmails::SourcesController`. - -class Rails::Conductor::ActionMailbox::InboundEmails::SourcesController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails_controller.rbi b/sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails_controller.rbi deleted file mode 100644 index 26ffe81ee..000000000 --- a/sorbet/rbi/dsl/rails/conductor/action_mailbox/inbound_emails_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Rails::Conductor::ActionMailbox::InboundEmailsController`. -# Please instead update this file by running `bin/tapioca dsl Rails::Conductor::ActionMailbox::InboundEmailsController`. - -class Rails::Conductor::ActionMailbox::InboundEmailsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/rails/conductor/action_mailbox/incinerates_controller.rbi b/sorbet/rbi/dsl/rails/conductor/action_mailbox/incinerates_controller.rbi deleted file mode 100644 index e53f65aa6..000000000 --- a/sorbet/rbi/dsl/rails/conductor/action_mailbox/incinerates_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Rails::Conductor::ActionMailbox::IncineratesController`. -# Please instead update this file by running `bin/tapioca dsl Rails::Conductor::ActionMailbox::IncineratesController`. - -class Rails::Conductor::ActionMailbox::IncineratesController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/rails/conductor/action_mailbox/reroutes_controller.rbi b/sorbet/rbi/dsl/rails/conductor/action_mailbox/reroutes_controller.rbi deleted file mode 100644 index 15a472f06..000000000 --- a/sorbet/rbi/dsl/rails/conductor/action_mailbox/reroutes_controller.rbi +++ /dev/null @@ -1,36 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Rails::Conductor::ActionMailbox::ReroutesController`. -# Please instead update this file by running `bin/tapioca dsl Rails::Conductor::ActionMailbox::ReroutesController`. - -class Rails::Conductor::ActionMailbox::ReroutesController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/rails/conductor/base_controller.rbi b/sorbet/rbi/dsl/rails/conductor/base_controller.rbi deleted file mode 100644 index b59403815..000000000 --- a/sorbet/rbi/dsl/rails/conductor/base_controller.rbi +++ /dev/null @@ -1,39 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Rails::Conductor::BaseController`. -# Please instead update this file by running `bin/tapioca dsl Rails::Conductor::BaseController`. - -class Rails::Conductor::BaseController - include GeneratedUrlHelpersModule - include GeneratedPathHelpersModule - - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/rcon_ftp_server.rbi b/sorbet/rbi/dsl/rcon_ftp_server.rbi index abef8fdce..07bda72a7 100644 --- a/sorbet/rbi/dsl/rcon_ftp_server.rbi +++ b/sorbet/rbi/dsl/rcon_ftp_server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `RconFtpServer`. # Please instead update this file by running `bin/tapioca dsl RconFtpServer`. + class RconFtpServer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class RconFtpServer sig { params(block: T.nilable(T.proc.params(record: ::RconFtpServer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::RconFtpServer).void)).returns(::RconFtpServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class RconFtpServer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::RconFtpServer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::RconFtpServer).void)).returns(::RconFtpServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class RconFtpServer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::RconFtpServer).void)).returns(::RconFtpServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class RconFtpServer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class RconFtpServer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class RconFtpServer sig { returns(::RconFtpServer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::RconFtpServer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::RconFtpServer]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::RconFtpServer).void + ).returns(T.nilable(::RconFtpServer)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::RconFtpServer)) } def find_by(*args); end @@ -89,6 +139,54 @@ class RconFtpServer sig { params(args: T.untyped).returns(::RconFtpServer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::RconFtpServer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::RconFtpServer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::RconFtpServer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::RconFtpServer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class RconFtpServer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class RconFtpServer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class RconFtpServer sig { params(arg: T.untyped, args: T.untyped).returns(::RconFtpServer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::RconFtpServer)) } + sig { params(limit: Integer).returns(T::Array[::RconFtpServer]) } def first(limit = nil); end sig { returns(::RconFtpServer) } @@ -143,10 +254,36 @@ class RconFtpServer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::RconFtpServer)) } + sig { params(limit: Integer).returns(T::Array[::RconFtpServer]) } def last(limit = nil); end sig { returns(::RconFtpServer) } @@ -164,6 +301,13 @@ class RconFtpServer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::RconFtpServer).void)).returns(::RconFtpServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RconFtpServer).void) + ).returns(T::Array[::RconFtpServer]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class RconFtpServer sig { returns(::RconFtpServer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::RconFtpServer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::RconFtpServer)) } + sig { params(limit: Integer).returns(T::Array[::RconFtpServer]) } def take(limit = nil); end sig { returns(::RconFtpServer) } @@ -315,6 +462,9 @@ class RconFtpServer sig { params(value: T::Enumerable[::Reservation]).void } def reservations=(value); end + sig { void } + def reset_location; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -343,8 +493,8 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -358,8 +508,8 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -367,7 +517,7 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -379,40 +529,6 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -446,6 +562,9 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -470,6 +589,9 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -497,27 +619,15 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -550,8 +660,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -559,8 +669,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -595,8 +705,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def billing_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_in_database; end @@ -604,8 +714,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_previous_change; end - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_previously_was; end @@ -640,8 +750,13 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -649,8 +764,13 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -685,8 +805,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_in_database; end @@ -694,8 +814,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_previous_change; end - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_previously_was; end @@ -730,8 +850,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_port_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_in_database; end @@ -739,8 +859,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_previous_change; end - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_previously_was; end @@ -775,8 +895,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_username_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_in_database; end @@ -784,8 +904,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_previous_change; end - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_previously_was; end @@ -796,7 +916,7 @@ class RconFtpServer sig { void } def ftp_username_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -814,27 +934,72 @@ class RconFtpServer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -865,8 +1030,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -874,8 +1039,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -910,8 +1075,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_known_version_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_in_database; end @@ -919,8 +1084,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_previous_change; end - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_previously_was; end @@ -955,8 +1120,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_in_database; end @@ -964,8 +1129,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_previously_was; end @@ -1000,8 +1165,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_in_database; end @@ -1009,8 +1174,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_previously_was; end @@ -1045,8 +1210,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_in_database; end @@ -1054,8 +1219,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_previously_was; end @@ -1090,8 +1255,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1099,8 +1264,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1135,8 +1300,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def location_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_in_database; end @@ -1144,8 +1309,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_previous_change; end - sig { returns(T::Boolean) } - def location_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_previously_was; end @@ -1180,8 +1345,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1189,8 +1354,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1225,8 +1390,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1234,8 +1399,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1270,8 +1435,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_change_to_be_saved; end - sig { returns(T::Boolean) } - def path_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_in_database; end @@ -1279,8 +1444,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_previous_change; end - sig { returns(T::Boolean) } - def path_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_previously_was; end @@ -1315,8 +1480,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_change_to_be_saved; end - sig { returns(T::Boolean) } - def port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_in_database; end @@ -1324,8 +1489,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_previous_change; end - sig { returns(T::Boolean) } - def port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_previously_was; end @@ -1360,8 +1525,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_change_to_be_saved; end - sig { returns(T::Boolean) } - def position_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_in_database; end @@ -1369,8 +1534,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_previous_change; end - sig { returns(T::Boolean) } - def position_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_previously_was; end @@ -1405,8 +1570,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1414,8 +1579,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1447,6 +1612,9 @@ class RconFtpServer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -1540,12 +1708,18 @@ class RconFtpServer sig { returns(T::Boolean) } def saved_change_to_ftp_username?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -1684,8 +1858,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_in_database; end @@ -1693,8 +1867,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_previous_change; end - sig { returns(T::Boolean) } - def sdr_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_previously_was; end @@ -1729,8 +1903,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_in_database; end @@ -1738,8 +1912,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_previous_change; end - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_previously_was; end @@ -1774,8 +1948,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -1783,8 +1957,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -1819,8 +1993,13 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_in_database; end @@ -1828,8 +2007,13 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_previous_change; end - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_previously_was; end @@ -1864,8 +2048,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_in_database; end @@ -1873,8 +2057,8 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_previous_change; end - sig { returns(T::Boolean) } - def update_status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_previously_was; end @@ -1909,8 +2093,13 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1918,8 +2107,13 @@ class RconFtpServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1951,6 +2145,9 @@ class RconFtpServer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -2022,8 +2219,8 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -2037,8 +2234,8 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -2046,7 +2243,7 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2091,6 +2288,9 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2115,6 +2315,9 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2145,6 +2348,12 @@ class RconFtpServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2158,10 +2367,48 @@ class RconFtpServer Elem = type_member { { fixed: ::RconFtpServer } } + sig { returns(T::Array[::RconFtpServer]) } + def to_a; end + sig { returns(T::Array[::RconFtpServer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::RconFtpServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::RconFtpServer } } @@ -2205,20 +2452,6 @@ class RconFtpServer end def concat(*records); end - sig do - params( - records: T.any(::RconFtpServer, Integer, String, T::Enumerable[T.any(::RconFtpServer, Integer, String, T::Enumerable[::RconFtpServer])]) - ).returns(T::Array[::RconFtpServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::RconFtpServer, Integer, String, T::Enumerable[T.any(::RconFtpServer, Integer, String, T::Enumerable[::RconFtpServer])]) - ).returns(T::Array[::RconFtpServer]) - end - def destroy(*records); end - sig { returns(T::Array[::RconFtpServer]) } def load_target; end @@ -2249,6 +2482,9 @@ class RconFtpServer sig { returns(T::Array[::RconFtpServer]) } def target; end + sig { returns(T::Array[::RconFtpServer]) } + def to_a; end + sig { returns(T::Array[::RconFtpServer]) } def to_ary; end end @@ -2259,10 +2495,48 @@ class RconFtpServer Elem = type_member { { fixed: ::RconFtpServer } } + sig { returns(T::Array[::RconFtpServer]) } + def to_a; end + sig { returns(T::Array[::RconFtpServer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::RconFtpServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::RconFtpServer } } diff --git a/sorbet/rbi/dsl/remote_server.rbi b/sorbet/rbi/dsl/remote_server.rbi index da53b230c..e69d550ec 100644 --- a/sorbet/rbi/dsl/remote_server.rbi +++ b/sorbet/rbi/dsl/remote_server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `RemoteServer`. # Please instead update this file by running `bin/tapioca dsl RemoteServer`. + class RemoteServer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class RemoteServer sig { params(block: T.nilable(T.proc.params(record: ::RemoteServer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::RemoteServer).void)).returns(::RemoteServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class RemoteServer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::RemoteServer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::RemoteServer).void)).returns(::RemoteServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class RemoteServer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::RemoteServer).void)).returns(::RemoteServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class RemoteServer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class RemoteServer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class RemoteServer sig { returns(::RemoteServer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::RemoteServer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::RemoteServer]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::RemoteServer).void + ).returns(T.nilable(::RemoteServer)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::RemoteServer)) } def find_by(*args); end @@ -89,6 +139,54 @@ class RemoteServer sig { params(args: T.untyped).returns(::RemoteServer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::RemoteServer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::RemoteServer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::RemoteServer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::RemoteServer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class RemoteServer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class RemoteServer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class RemoteServer sig { params(arg: T.untyped, args: T.untyped).returns(::RemoteServer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::RemoteServer)) } + sig { params(limit: Integer).returns(T::Array[::RemoteServer]) } def first(limit = nil); end sig { returns(::RemoteServer) } @@ -143,10 +254,36 @@ class RemoteServer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::RemoteServer)) } + sig { params(limit: Integer).returns(T::Array[::RemoteServer]) } def last(limit = nil); end sig { returns(::RemoteServer) } @@ -164,6 +301,13 @@ class RemoteServer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::RemoteServer).void)).returns(::RemoteServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::RemoteServer).void) + ).returns(T::Array[::RemoteServer]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class RemoteServer sig { returns(::RemoteServer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::RemoteServer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::RemoteServer)) } + sig { params(limit: Integer).returns(T::Array[::RemoteServer]) } def take(limit = nil); end sig { returns(::RemoteServer) } @@ -315,6 +462,9 @@ class RemoteServer sig { params(value: T::Enumerable[::Reservation]).void } def reservations=(value); end + sig { void } + def reset_location; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -343,8 +493,8 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -358,8 +508,8 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -367,7 +517,7 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -379,40 +529,6 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -446,6 +562,9 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -470,6 +589,9 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -497,27 +619,15 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -550,8 +660,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -559,8 +669,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -595,8 +705,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def billing_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_in_database; end @@ -604,8 +714,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_previous_change; end - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_previously_was; end @@ -640,8 +750,13 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -649,8 +764,13 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -685,8 +805,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_in_database; end @@ -694,8 +814,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_previous_change; end - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_previously_was; end @@ -730,8 +850,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_port_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_in_database; end @@ -739,8 +859,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_previous_change; end - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_previously_was; end @@ -775,8 +895,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_username_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_in_database; end @@ -784,8 +904,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_previous_change; end - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_previously_was; end @@ -796,7 +916,7 @@ class RemoteServer sig { void } def ftp_username_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -814,27 +934,72 @@ class RemoteServer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -865,8 +1030,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -874,8 +1039,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -910,8 +1075,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_known_version_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_in_database; end @@ -919,8 +1084,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_previous_change; end - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_previously_was; end @@ -955,8 +1120,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_in_database; end @@ -964,8 +1129,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_previously_was; end @@ -1000,8 +1165,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_in_database; end @@ -1009,8 +1174,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_previously_was; end @@ -1045,8 +1210,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_in_database; end @@ -1054,8 +1219,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_previously_was; end @@ -1090,8 +1255,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1099,8 +1264,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1135,8 +1300,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def location_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_in_database; end @@ -1144,8 +1309,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_previous_change; end - sig { returns(T::Boolean) } - def location_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_previously_was; end @@ -1180,8 +1345,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1189,8 +1354,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1225,8 +1390,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1234,8 +1399,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1270,8 +1435,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_change_to_be_saved; end - sig { returns(T::Boolean) } - def path_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_in_database; end @@ -1279,8 +1444,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_previous_change; end - sig { returns(T::Boolean) } - def path_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_previously_was; end @@ -1315,8 +1480,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_change_to_be_saved; end - sig { returns(T::Boolean) } - def port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_in_database; end @@ -1324,8 +1489,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_previous_change; end - sig { returns(T::Boolean) } - def port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_previously_was; end @@ -1360,8 +1525,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_change_to_be_saved; end - sig { returns(T::Boolean) } - def position_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_in_database; end @@ -1369,8 +1534,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_previous_change; end - sig { returns(T::Boolean) } - def position_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_previously_was; end @@ -1405,8 +1570,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1414,8 +1579,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1447,6 +1612,9 @@ class RemoteServer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -1540,12 +1708,18 @@ class RemoteServer sig { returns(T::Boolean) } def saved_change_to_ftp_username?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -1684,8 +1858,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_in_database; end @@ -1693,8 +1867,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_previous_change; end - sig { returns(T::Boolean) } - def sdr_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_previously_was; end @@ -1729,8 +1903,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_in_database; end @@ -1738,8 +1912,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_previous_change; end - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_previously_was; end @@ -1774,8 +1948,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -1783,8 +1957,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -1819,8 +1993,13 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_in_database; end @@ -1828,8 +2007,13 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_previous_change; end - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_previously_was; end @@ -1864,8 +2048,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_in_database; end @@ -1873,8 +2057,8 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_previous_change; end - sig { returns(T::Boolean) } - def update_status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_previously_was; end @@ -1909,8 +2093,13 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1918,8 +2107,13 @@ class RemoteServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1951,6 +2145,9 @@ class RemoteServer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -2022,8 +2219,8 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -2037,8 +2234,8 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -2046,7 +2243,7 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2091,6 +2288,9 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2115,6 +2315,9 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2145,6 +2348,12 @@ class RemoteServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2158,10 +2367,48 @@ class RemoteServer Elem = type_member { { fixed: ::RemoteServer } } + sig { returns(T::Array[::RemoteServer]) } + def to_a; end + sig { returns(T::Array[::RemoteServer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::RemoteServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::RemoteServer } } @@ -2205,20 +2452,6 @@ class RemoteServer end def concat(*records); end - sig do - params( - records: T.any(::RemoteServer, Integer, String, T::Enumerable[T.any(::RemoteServer, Integer, String, T::Enumerable[::RemoteServer])]) - ).returns(T::Array[::RemoteServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::RemoteServer, Integer, String, T::Enumerable[T.any(::RemoteServer, Integer, String, T::Enumerable[::RemoteServer])]) - ).returns(T::Array[::RemoteServer]) - end - def destroy(*records); end - sig { returns(T::Array[::RemoteServer]) } def load_target; end @@ -2249,6 +2482,9 @@ class RemoteServer sig { returns(T::Array[::RemoteServer]) } def target; end + sig { returns(T::Array[::RemoteServer]) } + def to_a; end + sig { returns(T::Array[::RemoteServer]) } def to_ary; end end @@ -2259,10 +2495,48 @@ class RemoteServer Elem = type_member { { fixed: ::RemoteServer } } + sig { returns(T::Array[::RemoteServer]) } + def to_a; end + sig { returns(T::Array[::RemoteServer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::RemoteServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::RemoteServer } } diff --git a/sorbet/rbi/dsl/reservation.rbi b/sorbet/rbi/dsl/reservation.rbi index b5c3c828c..92e9ca5c7 100644 --- a/sorbet/rbi/dsl/reservation.rbi +++ b/sorbet/rbi/dsl/reservation.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Reservation`. # Please instead update this file by running `bin/tapioca dsl Reservation`. + class Reservation include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class Reservation sig { params(block: T.nilable(T.proc.params(record: ::Reservation).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Reservation).void)).returns(::Reservation) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class Reservation end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Reservation).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Reservation).void)).returns(::Reservation) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class Reservation end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Reservation).void)).returns(::Reservation) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class Reservation end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class Reservation end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class Reservation sig { returns(::Reservation) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Reservation) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Reservation]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Reservation).void).returns(T.nilable(::Reservation)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Reservation)) } def find_by(*args); end @@ -89,6 +134,54 @@ class Reservation sig { params(args: T.untyped).returns(::Reservation) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Reservation).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Reservation]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Reservation]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Reservation]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class Reservation end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class Reservation end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class Reservation sig { params(arg: T.untyped, args: T.untyped).returns(::Reservation) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Reservation)) } + sig { params(limit: Integer).returns(T::Array[::Reservation]) } def first(limit = nil); end sig { returns(::Reservation) } @@ -143,10 +249,36 @@ class Reservation sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Reservation)) } + sig { params(limit: Integer).returns(T::Array[::Reservation]) } def last(limit = nil); end sig { returns(::Reservation) } @@ -164,6 +296,13 @@ class Reservation sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Reservation).void)).returns(::Reservation) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Reservation).void) + ).returns(T::Array[::Reservation]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class Reservation sig { returns(::Reservation) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Reservation).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Reservation)) } + sig { params(limit: Integer).returns(T::Array[::Reservation]) } def take(limit = nil); end sig { returns(::Reservation) } @@ -317,18 +459,42 @@ class Reservation sig { params(value: T::Enumerable[::ReservationStatus]).void } def reservation_statuses=(value); end + sig { void } + def reset_server; end + + sig { void } + def reset_server_config; end + + sig { void } + def reset_user; end + + sig { void } + def reset_whitelist; end + sig { returns(T.nilable(::Server)) } def server; end sig { params(value: T.nilable(::Server)).void } def server=(value); end + sig { returns(T::Boolean) } + def server_changed?; end + sig { returns(T.nilable(::ServerConfig)) } def server_config; end sig { params(value: T.nilable(::ServerConfig)).void } def server_config=(value); end + sig { returns(T::Boolean) } + def server_config_changed?; end + + sig { returns(T::Boolean) } + def server_config_previously_changed?; end + + sig { returns(T::Boolean) } + def server_previously_changed?; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -343,17 +509,43 @@ class Reservation sig { params(value: T::Enumerable[::ServerStatistic]).void } def server_statistics=(value); end + sig { returns(T::Array[T.untyped]) } + def stac_log_ids; end + + sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } + def stac_log_ids=(ids); end + + # This method is created by ActiveRecord on the `Reservation` class because it declared `has_many :stac_logs`. + # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) + sig { returns(::StacLog::PrivateCollectionProxy) } + def stac_logs; end + + sig { params(value: T::Enumerable[::StacLog]).void } + def stac_logs=(value); end + sig { returns(T.nilable(::User)) } def user; end sig { params(value: T.nilable(::User)).void } def user=(value); end + sig { returns(T::Boolean) } + def user_changed?; end + + sig { returns(T::Boolean) } + def user_previously_changed?; end + sig { returns(T.nilable(::Whitelist)) } def whitelist; end sig { params(value: T.nilable(::Whitelist)).void } def whitelist=(value); end + + sig { returns(T::Boolean) } + def whitelist_changed?; end + + sig { returns(T::Boolean) } + def whitelist_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -369,8 +561,8 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -384,13 +576,13 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -402,40 +594,6 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -460,6 +618,9 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -484,6 +645,9 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -511,27 +675,15 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -561,8 +713,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def auto_end_change_to_be_saved; end - sig { returns(T::Boolean) } - def auto_end_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def auto_end_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def auto_end_in_database; end @@ -570,8 +722,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def auto_end_previous_change; end - sig { returns(T::Boolean) } - def auto_end_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def auto_end_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def auto_end_previously_was; end @@ -606,8 +758,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -615,8 +772,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -651,8 +813,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def custom_whitelist_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def custom_whitelist_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def custom_whitelist_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def custom_whitelist_id_in_database; end @@ -660,8 +822,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def custom_whitelist_id_previous_change; end - sig { returns(T::Boolean) } - def custom_whitelist_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def custom_whitelist_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def custom_whitelist_id_previously_was; end @@ -696,8 +858,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def duration_change_to_be_saved; end - sig { returns(T::Boolean) } - def duration_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def duration_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def duration_in_database; end @@ -705,8 +867,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def duration_previous_change; end - sig { returns(T::Boolean) } - def duration_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def duration_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def duration_previously_was; end @@ -741,8 +903,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def enable_arena_respawn_change_to_be_saved; end - sig { returns(T::Boolean) } - def enable_arena_respawn_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def enable_arena_respawn_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def enable_arena_respawn_in_database; end @@ -750,8 +912,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def enable_arena_respawn_previous_change; end - sig { returns(T::Boolean) } - def enable_arena_respawn_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def enable_arena_respawn_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def enable_arena_respawn_previously_was; end @@ -786,8 +948,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def enable_demos_tf_change_to_be_saved; end - sig { returns(T::Boolean) } - def enable_demos_tf_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def enable_demos_tf_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def enable_demos_tf_in_database; end @@ -795,8 +957,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def enable_demos_tf_previous_change; end - sig { returns(T::Boolean) } - def enable_demos_tf_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def enable_demos_tf_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def enable_demos_tf_previously_was; end @@ -831,8 +993,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def enable_plugins_change_to_be_saved; end - sig { returns(T::Boolean) } - def enable_plugins_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def enable_plugins_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def enable_plugins_in_database; end @@ -840,8 +1002,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def enable_plugins_previous_change; end - sig { returns(T::Boolean) } - def enable_plugins_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def enable_plugins_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def enable_plugins_previously_was; end @@ -876,8 +1038,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def end_instantly_change_to_be_saved; end - sig { returns(T::Boolean) } - def end_instantly_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def end_instantly_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def end_instantly_in_database; end @@ -885,8 +1047,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def end_instantly_previous_change; end - sig { returns(T::Boolean) } - def end_instantly_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def end_instantly_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def end_instantly_previously_was; end @@ -921,8 +1083,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def ended_change_to_be_saved; end - sig { returns(T::Boolean) } - def ended_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def ended_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def ended_in_database; end @@ -930,8 +1092,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def ended_previous_change; end - sig { returns(T::Boolean) } - def ended_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def ended_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def ended_previously_was; end @@ -966,8 +1128,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def ends_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def ends_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def ends_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def ends_at_in_database; end @@ -975,8 +1142,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def ends_at_previous_change; end - sig { returns(T::Boolean) } - def ends_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def ends_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def ends_at_previously_was; end @@ -1011,8 +1183,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def first_map_change_to_be_saved; end - sig { returns(T::Boolean) } - def first_map_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def first_map_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def first_map_in_database; end @@ -1020,8 +1192,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def first_map_previous_change; end - sig { returns(T::Boolean) } - def first_map_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def first_map_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def first_map_previously_was; end @@ -1056,8 +1228,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def gameye_location_change_to_be_saved; end - sig { returns(T::Boolean) } - def gameye_location_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def gameye_location_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def gameye_location_in_database; end @@ -1065,8 +1237,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def gameye_location_previous_change; end - sig { returns(T::Boolean) } - def gameye_location_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def gameye_location_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def gameye_location_previously_was; end @@ -1077,7 +1249,7 @@ class Reservation sig { void } def gameye_location_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -1095,27 +1267,72 @@ class Reservation sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -1146,8 +1363,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def inactive_minute_counter_change_to_be_saved; end - sig { returns(T::Boolean) } - def inactive_minute_counter_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def inactive_minute_counter_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def inactive_minute_counter_in_database; end @@ -1155,8 +1372,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def inactive_minute_counter_previous_change; end - sig { returns(T::Boolean) } - def inactive_minute_counter_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def inactive_minute_counter_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def inactive_minute_counter_previously_was; end @@ -1191,8 +1408,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_number_of_players_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_number_of_players_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_number_of_players_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_number_of_players_in_database; end @@ -1200,8 +1417,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_number_of_players_previous_change; end - sig { returns(T::Boolean) } - def last_number_of_players_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_number_of_players_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_number_of_players_previously_was; end @@ -1236,8 +1453,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def logsecret_change_to_be_saved; end - sig { returns(T::Boolean) } - def logsecret_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def logsecret_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def logsecret_in_database; end @@ -1245,8 +1462,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def logsecret_previous_change; end - sig { returns(T::Boolean) } - def logsecret_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def logsecret_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def logsecret_previously_was; end @@ -1281,8 +1498,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def password_change_to_be_saved; end - sig { returns(T::Boolean) } - def password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def password_in_database; end @@ -1290,8 +1507,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def password_previous_change; end - sig { returns(T::Boolean) } - def password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def password_previously_was; end @@ -1326,8 +1543,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def provisioned_change_to_be_saved; end - sig { returns(T::Boolean) } - def provisioned_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def provisioned_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def provisioned_in_database; end @@ -1335,8 +1552,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def provisioned_previous_change; end - sig { returns(T::Boolean) } - def provisioned_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def provisioned_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def provisioned_previously_was; end @@ -1371,8 +1588,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1380,8 +1597,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1431,6 +1648,9 @@ class Reservation sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_inactive_minute_counter!; end @@ -1557,12 +1777,18 @@ class Reservation sig { returns(T::Boolean) } def saved_change_to_gameye_location?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def saved_change_to_inactive_minute_counter; end @@ -1695,8 +1921,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def sdr_ip_in_database; end @@ -1704,8 +1930,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def sdr_ip_previously_was; end @@ -1740,8 +1966,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def sdr_port_in_database; end @@ -1749,8 +1975,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def sdr_port_previous_change; end - sig { returns(T::Boolean) } - def sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def sdr_port_previously_was; end @@ -1785,8 +2011,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def sdr_tv_port_in_database; end @@ -1794,8 +2020,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def sdr_tv_port_previously_was; end @@ -1830,8 +2056,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_config_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def server_config_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_config_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_config_id_in_database; end @@ -1839,8 +2065,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_config_id_previous_change; end - sig { returns(T::Boolean) } - def server_config_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_config_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_config_id_previously_was; end @@ -1875,8 +2101,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def server_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_in_database; end @@ -1884,8 +2110,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_id_previous_change; end - sig { returns(T::Boolean) } - def server_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_previously_was; end @@ -1920,8 +2146,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def start_instantly_change_to_be_saved; end - sig { returns(T::Boolean) } - def start_instantly_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def start_instantly_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def start_instantly_in_database; end @@ -1929,8 +2155,8 @@ class Reservation sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def start_instantly_previous_change; end - sig { returns(T::Boolean) } - def start_instantly_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def start_instantly_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def start_instantly_previously_was; end @@ -1965,8 +2191,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def starts_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def starts_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def starts_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def starts_at_in_database; end @@ -1974,8 +2205,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def starts_at_previous_change; end - sig { returns(T::Boolean) } - def starts_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def starts_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def starts_at_previously_was; end @@ -2010,8 +2246,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_password_in_database; end @@ -2019,8 +2255,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_password_previous_change; end - sig { returns(T::Boolean) } - def tv_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_password_previously_was; end @@ -2055,8 +2291,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_relaypassword_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_relaypassword_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_relaypassword_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_relaypassword_in_database; end @@ -2064,8 +2300,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_relaypassword_previous_change; end - sig { returns(T::Boolean) } - def tv_relaypassword_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_relaypassword_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_relaypassword_previously_was; end @@ -2100,8 +2336,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -2109,8 +2350,13 @@ class Reservation sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -2145,8 +2391,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def user_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_in_database; end @@ -2154,8 +2400,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_previous_change; end - sig { returns(T::Boolean) } - def user_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_previously_was; end @@ -2190,8 +2436,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def whitelist_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def whitelist_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def whitelist_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def whitelist_id_in_database; end @@ -2199,8 +2445,8 @@ class Reservation sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def whitelist_id_previous_change; end - sig { returns(T::Boolean) } - def whitelist_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def whitelist_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def whitelist_id_previously_was; end @@ -2250,6 +2496,9 @@ class Reservation sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_inactive_minute_counter?; end @@ -2318,8 +2567,8 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -2333,13 +2582,13 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2375,6 +2624,9 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2399,6 +2651,9 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2429,6 +2684,12 @@ class Reservation sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -2439,10 +2700,48 @@ class Reservation Elem = type_member { { fixed: ::Reservation } } + sig { returns(T::Array[::Reservation]) } + def to_a; end + sig { returns(T::Array[::Reservation]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Reservation } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Reservation } } @@ -2486,20 +2785,6 @@ class Reservation end def concat(*records); end - sig do - params( - records: T.any(::Reservation, Integer, String, T::Enumerable[T.any(::Reservation, Integer, String, T::Enumerable[::Reservation])]) - ).returns(T::Array[::Reservation]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Reservation, Integer, String, T::Enumerable[T.any(::Reservation, Integer, String, T::Enumerable[::Reservation])]) - ).returns(T::Array[::Reservation]) - end - def destroy(*records); end - sig { returns(T::Array[::Reservation]) } def load_target; end @@ -2530,6 +2815,9 @@ class Reservation sig { returns(T::Array[::Reservation]) } def target; end + sig { returns(T::Array[::Reservation]) } + def to_a; end + sig { returns(T::Array[::Reservation]) } def to_ary; end end @@ -2540,10 +2828,48 @@ class Reservation Elem = type_member { { fixed: ::Reservation } } + sig { returns(T::Array[::Reservation]) } + def to_a; end + sig { returns(T::Array[::Reservation]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Reservation } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Reservation } } diff --git a/sorbet/rbi/dsl/reservation_player.rbi b/sorbet/rbi/dsl/reservation_player.rbi index 24d00dac4..c7b16ae60 100644 --- a/sorbet/rbi/dsl/reservation_player.rbi +++ b/sorbet/rbi/dsl/reservation_player.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ReservationPlayer`. # Please instead update this file by running `bin/tapioca dsl ReservationPlayer`. + class ReservationPlayer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class ReservationPlayer sig { params(block: T.nilable(T.proc.params(record: ::ReservationPlayer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationPlayer).void)).returns(::ReservationPlayer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class ReservationPlayer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ReservationPlayer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationPlayer).void)).returns(::ReservationPlayer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class ReservationPlayer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationPlayer).void)).returns(::ReservationPlayer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class ReservationPlayer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class ReservationPlayer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class ReservationPlayer sig { returns(::ReservationPlayer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ReservationPlayer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ReservationPlayer]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ReservationPlayer).void + ).returns(T.nilable(::ReservationPlayer)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ReservationPlayer)) } def find_by(*args); end @@ -89,6 +139,54 @@ class ReservationPlayer sig { params(args: T.untyped).returns(::ReservationPlayer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ReservationPlayer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ReservationPlayer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ReservationPlayer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ReservationPlayer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class ReservationPlayer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class ReservationPlayer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class ReservationPlayer sig { params(arg: T.untyped, args: T.untyped).returns(::ReservationPlayer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ReservationPlayer)) } + sig { params(limit: Integer).returns(T::Array[::ReservationPlayer]) } def first(limit = nil); end sig { returns(::ReservationPlayer) } @@ -143,10 +254,36 @@ class ReservationPlayer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ReservationPlayer)) } + sig { params(limit: Integer).returns(T::Array[::ReservationPlayer]) } def last(limit = nil); end sig { returns(::ReservationPlayer) } @@ -164,6 +301,13 @@ class ReservationPlayer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationPlayer).void)).returns(::ReservationPlayer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationPlayer).void) + ).returns(T::Array[::ReservationPlayer]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class ReservationPlayer sig { returns(::ReservationPlayer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ReservationPlayer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ReservationPlayer)) } + sig { params(limit: Integer).returns(T::Array[::ReservationPlayer]) } def take(limit = nil); end sig { returns(::ReservationPlayer) } @@ -269,6 +416,21 @@ class ReservationPlayer sig { params(value: T.nilable(::Reservation)).void } def reservation=(value); end + sig { returns(T::Boolean) } + def reservation_changed?; end + + sig { returns(T::Boolean) } + def reservation_previously_changed?; end + + sig { void } + def reset_reservation; end + + sig { void } + def reset_server; end + + sig { void } + def reset_user; end + sig { returns(T.nilable(::Server)) } def server; end @@ -280,6 +442,12 @@ class ReservationPlayer sig { params(value: T.nilable(::User)).void } def user=(value); end + + sig { returns(T::Boolean) } + def user_changed?; end + + sig { returns(T::Boolean) } + def user_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -295,8 +463,8 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -310,8 +478,8 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -319,7 +487,7 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -331,40 +499,6 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -398,6 +532,9 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -422,6 +559,9 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -449,27 +589,15 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -478,7 +606,7 @@ class ReservationPlayer end module GeneratedAttributeMethods - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -496,27 +624,72 @@ class ReservationPlayer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -547,8 +720,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -556,8 +729,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -592,8 +765,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -601,8 +774,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -637,8 +810,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -646,8 +819,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -682,8 +855,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -691,8 +864,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -727,8 +900,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def reservation_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_in_database; end @@ -736,8 +909,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_id_previous_change; end - sig { returns(T::Boolean) } - def reservation_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_previously_was; end @@ -751,6 +924,9 @@ class ReservationPlayer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -772,12 +948,18 @@ class ReservationPlayer sig { void } def restore_whitelisted!; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -844,8 +1026,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def steam_uid_change_to_be_saved; end - sig { returns(T::Boolean) } - def steam_uid_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def steam_uid_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def steam_uid_in_database; end @@ -853,8 +1035,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def steam_uid_previous_change; end - sig { returns(T::Boolean) } - def steam_uid_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def steam_uid_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def steam_uid_previously_was; end @@ -889,8 +1071,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def whitelisted_change_to_be_saved; end - sig { returns(T::Boolean) } - def whitelisted_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def whitelisted_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def whitelisted_in_database; end @@ -898,8 +1080,8 @@ class ReservationPlayer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def whitelisted_previous_change; end - sig { returns(T::Boolean) } - def whitelisted_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def whitelisted_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def whitelisted_previously_was; end @@ -913,6 +1095,9 @@ class ReservationPlayer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -948,8 +1133,8 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -963,8 +1148,8 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -972,7 +1157,7 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -1017,6 +1202,9 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -1041,6 +1229,9 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1071,6 +1262,12 @@ class ReservationPlayer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -1084,10 +1281,48 @@ class ReservationPlayer Elem = type_member { { fixed: ::ReservationPlayer } } + sig { returns(T::Array[::ReservationPlayer]) } + def to_a; end + sig { returns(T::Array[::ReservationPlayer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ReservationPlayer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ReservationPlayer } } @@ -1131,20 +1366,6 @@ class ReservationPlayer end def concat(*records); end - sig do - params( - records: T.any(::ReservationPlayer, Integer, String, T::Enumerable[T.any(::ReservationPlayer, Integer, String, T::Enumerable[::ReservationPlayer])]) - ).returns(T::Array[::ReservationPlayer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ReservationPlayer, Integer, String, T::Enumerable[T.any(::ReservationPlayer, Integer, String, T::Enumerable[::ReservationPlayer])]) - ).returns(T::Array[::ReservationPlayer]) - end - def destroy(*records); end - sig { returns(T::Array[::ReservationPlayer]) } def load_target; end @@ -1175,6 +1396,9 @@ class ReservationPlayer sig { returns(T::Array[::ReservationPlayer]) } def target; end + sig { returns(T::Array[::ReservationPlayer]) } + def to_a; end + sig { returns(T::Array[::ReservationPlayer]) } def to_ary; end end @@ -1185,10 +1409,48 @@ class ReservationPlayer Elem = type_member { { fixed: ::ReservationPlayer } } + sig { returns(T::Array[::ReservationPlayer]) } + def to_a; end + sig { returns(T::Array[::ReservationPlayer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ReservationPlayer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ReservationPlayer } } diff --git a/sorbet/rbi/dsl/reservation_status.rbi b/sorbet/rbi/dsl/reservation_status.rbi index 35f563af3..94ed169be 100644 --- a/sorbet/rbi/dsl/reservation_status.rbi +++ b/sorbet/rbi/dsl/reservation_status.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ReservationStatus`. # Please instead update this file by running `bin/tapioca dsl ReservationStatus`. + class ReservationStatus include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class ReservationStatus sig { params(block: T.nilable(T.proc.params(record: ::ReservationStatus).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationStatus).void)).returns(::ReservationStatus) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class ReservationStatus end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ReservationStatus).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationStatus).void)).returns(::ReservationStatus) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class ReservationStatus end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationStatus).void)).returns(::ReservationStatus) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class ReservationStatus end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class ReservationStatus end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class ReservationStatus sig { returns(::ReservationStatus) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ReservationStatus) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ReservationStatus]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ReservationStatus).void + ).returns(T.nilable(::ReservationStatus)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ReservationStatus)) } def find_by(*args); end @@ -89,6 +139,54 @@ class ReservationStatus sig { params(args: T.untyped).returns(::ReservationStatus) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ReservationStatus).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ReservationStatus]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ReservationStatus]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ReservationStatus]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class ReservationStatus end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class ReservationStatus end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class ReservationStatus sig { params(arg: T.untyped, args: T.untyped).returns(::ReservationStatus) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ReservationStatus)) } + sig { params(limit: Integer).returns(T::Array[::ReservationStatus]) } def first(limit = nil); end sig { returns(::ReservationStatus) } @@ -143,10 +254,36 @@ class ReservationStatus sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ReservationStatus)) } + sig { params(limit: Integer).returns(T::Array[::ReservationStatus]) } def last(limit = nil); end sig { returns(::ReservationStatus) } @@ -164,6 +301,13 @@ class ReservationStatus sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ReservationStatus).void)).returns(::ReservationStatus) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ReservationStatus).void) + ).returns(T::Array[::ReservationStatus]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class ReservationStatus sig { returns(::ReservationStatus) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ReservationStatus).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ReservationStatus)) } + sig { params(limit: Integer).returns(T::Array[::ReservationStatus]) } def take(limit = nil); end sig { returns(::ReservationStatus) } @@ -244,6 +391,15 @@ class ReservationStatus sig { params(value: T.nilable(::Reservation)).void } def reservation=(value); end + + sig { returns(T::Boolean) } + def reservation_changed?; end + + sig { returns(T::Boolean) } + def reservation_previously_changed?; end + + sig { void } + def reset_reservation; end end module GeneratedAssociationRelationMethods @@ -259,8 +415,8 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -274,13 +430,13 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -292,40 +448,6 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -350,6 +472,9 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -374,6 +499,9 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -401,27 +529,15 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -451,8 +567,13 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -460,8 +581,13 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -472,7 +598,7 @@ class ReservationStatus sig { void } def created_at_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -490,27 +616,72 @@ class ReservationStatus sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -541,8 +712,8 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def reservation_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_in_database; end @@ -550,8 +721,8 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def reservation_id_previous_change; end - sig { returns(T::Boolean) } - def reservation_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_previously_was; end @@ -568,6 +739,9 @@ class ReservationStatus sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_reservation_id!; end @@ -583,12 +757,18 @@ class ReservationStatus sig { returns(T::Boolean) } def saved_change_to_created_at?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def saved_change_to_reservation_id; end @@ -631,8 +811,8 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_change_to_be_saved; end - sig { returns(T::Boolean) } - def status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_in_database; end @@ -640,8 +820,8 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_previous_change; end - sig { returns(T::Boolean) } - def status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_previously_was; end @@ -676,8 +856,13 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -685,8 +870,13 @@ class ReservationStatus sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -703,6 +893,9 @@ class ReservationStatus sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_reservation_id?; end @@ -726,8 +919,8 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -741,13 +934,13 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -783,6 +976,9 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -807,6 +1003,9 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -837,6 +1036,12 @@ class ReservationStatus sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -847,10 +1052,48 @@ class ReservationStatus Elem = type_member { { fixed: ::ReservationStatus } } + sig { returns(T::Array[::ReservationStatus]) } + def to_a; end + sig { returns(T::Array[::ReservationStatus]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ReservationStatus } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ReservationStatus } } @@ -894,20 +1137,6 @@ class ReservationStatus end def concat(*records); end - sig do - params( - records: T.any(::ReservationStatus, Integer, String, T::Enumerable[T.any(::ReservationStatus, Integer, String, T::Enumerable[::ReservationStatus])]) - ).returns(T::Array[::ReservationStatus]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ReservationStatus, Integer, String, T::Enumerable[T.any(::ReservationStatus, Integer, String, T::Enumerable[::ReservationStatus])]) - ).returns(T::Array[::ReservationStatus]) - end - def destroy(*records); end - sig { returns(T::Array[::ReservationStatus]) } def load_target; end @@ -938,6 +1167,9 @@ class ReservationStatus sig { returns(T::Array[::ReservationStatus]) } def target; end + sig { returns(T::Array[::ReservationStatus]) } + def to_a; end + sig { returns(T::Array[::ReservationStatus]) } def to_ary; end end @@ -948,10 +1180,48 @@ class ReservationStatus Elem = type_member { { fixed: ::ReservationStatus } } + sig { returns(T::Array[::ReservationStatus]) } + def to_a; end + sig { returns(T::Array[::ReservationStatus]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ReservationStatus } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ReservationStatus } } diff --git a/sorbet/rbi/dsl/reservation_worker.rbi b/sorbet/rbi/dsl/reservation_worker.rbi index c580c5787..c3ff4fb7d 100644 --- a/sorbet/rbi/dsl/reservation_worker.rbi +++ b/sorbet/rbi/dsl/reservation_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ReservationWorker`. # Please instead update this file by running `bin/tapioca dsl ReservationWorker`. + class ReservationWorker class << self sig { params(reservation_id: T.untyped, action: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/reservations_controller.rbi b/sorbet/rbi/dsl/reservations_controller.rbi index ce9be7369..465078268 100644 --- a/sorbet/rbi/dsl/reservations_controller.rbi +++ b/sorbet/rbi/dsl/reservations_controller.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ReservationsController`. # Please instead update this file by running `bin/tapioca dsl ReservationsController`. + class ReservationsController sig { returns(HelperProxy) } def helpers; end diff --git a/sorbet/rbi/dsl/sentry/send_event_job.rbi b/sorbet/rbi/dsl/sentry/send_event_job.rbi new file mode 100644 index 000000000..0aa23f30d --- /dev/null +++ b/sorbet/rbi/dsl/sentry/send_event_job.rbi @@ -0,0 +1,22 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `Sentry::SendEventJob`. +# Please instead update this file by running `bin/tapioca dsl Sentry::SendEventJob`. + + +class Sentry::SendEventJob + class << self + sig do + params( + event: T.untyped, + hint: T.untyped, + block: T.nilable(T.proc.params(job: Sentry::SendEventJob).void) + ).returns(T.any(Sentry::SendEventJob, FalseClass)) + end + def perform_later(event, hint = T.unsafe(nil), &block); end + + sig { params(event: T.untyped, hint: T.untyped).returns(T.untyped) } + def perform_now(event, hint = T.unsafe(nil)); end + end +end diff --git a/sorbet/rbi/dsl/server.rbi b/sorbet/rbi/dsl/server.rbi index de4ebe4ac..c9ff888eb 100644 --- a/sorbet/rbi/dsl/server.rbi +++ b/sorbet/rbi/dsl/server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Server`. # Please instead update this file by running `bin/tapioca dsl Server`. + class Server include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,27 +20,61 @@ class Server sig { params(block: T.nilable(T.proc.params(record: ::Server).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Server).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def create_or_find_by!(attributes, &block); end @@ -55,8 +90,18 @@ class Server sig { returns(::Server) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Server) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Server]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Server).void).returns(T.nilable(::Server)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Server)) } def find_by(*args); end @@ -64,12 +109,72 @@ class Server sig { params(args: T.untyped).returns(::Server) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Server).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Server]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Server]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Server]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def find_or_initialize_by(attributes, &block); end @@ -82,7 +187,8 @@ class Server sig { params(arg: T.untyped, args: T.untyped).returns(::Server) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Server)) } + sig { params(limit: Integer).returns(T::Array[::Server]) } def first(limit = nil); end sig { returns(::Server) } @@ -103,10 +209,36 @@ class Server sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Server)) } + sig { params(limit: Integer).returns(T::Array[::Server]) } def last(limit = nil); end sig { returns(::Server) } @@ -124,6 +256,13 @@ class Server sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Server).void) + ).returns(T::Array[::Server]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Server).void)).returns(::Server) } def new(attributes = nil, &block); end @@ -154,15 +293,18 @@ class Server sig { returns(::Server) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Server).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Server)) } + sig { params(limit: Integer).returns(T::Array[::Server]) } def take(limit = nil); end sig { returns(::Server) } @@ -239,6 +381,12 @@ class Server sig { params(value: T.nilable(::Location)).void } def location=(value); end + sig { returns(T::Boolean) } + def location_changed?; end + + sig { returns(T::Boolean) } + def location_previously_changed?; end + sig { returns(T::Array[T.untyped]) } def recent_server_statistic_ids; end @@ -270,6 +418,9 @@ class Server sig { params(value: T::Enumerable[::Reservation]).void } def reservations=(value); end + sig { void } + def reset_location; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -298,8 +449,8 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -313,8 +464,8 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -322,7 +473,7 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -334,40 +485,6 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -401,6 +518,9 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -425,6 +545,9 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -452,27 +575,15 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -505,8 +616,8 @@ class Server sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -514,8 +625,8 @@ class Server sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -550,8 +661,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def billing_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_in_database; end @@ -559,8 +670,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_previous_change; end - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_previously_was; end @@ -595,8 +706,13 @@ class Server sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -604,8 +720,13 @@ class Server sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -640,8 +761,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_in_database; end @@ -649,8 +770,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_previous_change; end - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_previously_was; end @@ -685,8 +806,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_port_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_in_database; end @@ -694,8 +815,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_previous_change; end - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_previously_was; end @@ -730,8 +851,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_username_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_in_database; end @@ -739,8 +860,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_previous_change; end - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_previously_was; end @@ -751,7 +872,7 @@ class Server sig { void } def ftp_username_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -769,27 +890,72 @@ class Server sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -820,8 +986,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -829,8 +995,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -865,8 +1031,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_known_version_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_in_database; end @@ -874,8 +1040,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_previous_change; end - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_previously_was; end @@ -910,8 +1076,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_in_database; end @@ -919,8 +1085,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_previously_was; end @@ -955,8 +1121,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_in_database; end @@ -964,8 +1130,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_previously_was; end @@ -1000,8 +1166,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_in_database; end @@ -1009,8 +1175,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_previously_was; end @@ -1045,8 +1211,8 @@ class Server sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1054,8 +1220,8 @@ class Server sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1090,8 +1256,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def location_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_in_database; end @@ -1099,8 +1265,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_previous_change; end - sig { returns(T::Boolean) } - def location_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_previously_was; end @@ -1135,8 +1301,8 @@ class Server sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1144,8 +1310,8 @@ class Server sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1180,8 +1346,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1189,8 +1355,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1225,8 +1391,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_change_to_be_saved; end - sig { returns(T::Boolean) } - def path_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_in_database; end @@ -1234,8 +1400,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_previous_change; end - sig { returns(T::Boolean) } - def path_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_previously_was; end @@ -1270,8 +1436,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_change_to_be_saved; end - sig { returns(T::Boolean) } - def port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_in_database; end @@ -1279,8 +1445,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_previous_change; end - sig { returns(T::Boolean) } - def port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_previously_was; end @@ -1315,8 +1481,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_change_to_be_saved; end - sig { returns(T::Boolean) } - def position_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_in_database; end @@ -1324,8 +1490,8 @@ class Server sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_previous_change; end - sig { returns(T::Boolean) } - def position_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_previously_was; end @@ -1360,8 +1526,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1369,8 +1535,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1402,6 +1568,9 @@ class Server sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -1495,12 +1664,18 @@ class Server sig { returns(T::Boolean) } def saved_change_to_ftp_username?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -1639,8 +1814,8 @@ class Server sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_in_database; end @@ -1648,8 +1823,8 @@ class Server sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_previous_change; end - sig { returns(T::Boolean) } - def sdr_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_previously_was; end @@ -1684,8 +1859,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_in_database; end @@ -1693,8 +1868,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_previous_change; end - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_previously_was; end @@ -1729,8 +1904,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -1738,8 +1913,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -1774,8 +1949,13 @@ class Server sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_in_database; end @@ -1783,8 +1963,13 @@ class Server sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_previous_change; end - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_previously_was; end @@ -1819,8 +2004,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_in_database; end @@ -1828,8 +2013,8 @@ class Server sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_previous_change; end - sig { returns(T::Boolean) } - def update_status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_previously_was; end @@ -1864,8 +2049,13 @@ class Server sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1873,8 +2063,13 @@ class Server sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1906,6 +2101,9 @@ class Server sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -1977,8 +2175,8 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -1992,8 +2190,8 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -2001,7 +2199,7 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2046,6 +2244,9 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2070,6 +2271,9 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2100,6 +2304,12 @@ class Server sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2113,10 +2323,48 @@ class Server Elem = type_member { { fixed: ::Server } } + sig { returns(T::Array[::Server]) } + def to_a; end + sig { returns(T::Array[::Server]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Server } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Server } } @@ -2160,20 +2408,6 @@ class Server end def concat(*records); end - sig do - params( - records: T.any(::Server, Integer, String, T::Enumerable[T.any(::Server, Integer, String, T::Enumerable[::Server])]) - ).returns(T::Array[::Server]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Server, Integer, String, T::Enumerable[T.any(::Server, Integer, String, T::Enumerable[::Server])]) - ).returns(T::Array[::Server]) - end - def destroy(*records); end - sig { returns(T::Array[::Server]) } def load_target; end @@ -2204,6 +2438,9 @@ class Server sig { returns(T::Array[::Server]) } def target; end + sig { returns(T::Array[::Server]) } + def to_a; end + sig { returns(T::Array[::Server]) } def to_ary; end end @@ -2214,10 +2451,48 @@ class Server Elem = type_member { { fixed: ::Server } } + sig { returns(T::Array[::Server]) } + def to_a; end + sig { returns(T::Array[::Server]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Server } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Server } } diff --git a/sorbet/rbi/dsl/server_config.rbi b/sorbet/rbi/dsl/server_config.rbi index e207a02da..e56b90a4d 100644 --- a/sorbet/rbi/dsl/server_config.rbi +++ b/sorbet/rbi/dsl/server_config.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ServerConfig`. # Please instead update this file by running `bin/tapioca dsl ServerConfig`. + class ServerConfig include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class ServerConfig sig { params(block: T.nilable(T.proc.params(record: ::ServerConfig).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerConfig).void)).returns(::ServerConfig) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class ServerConfig end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ServerConfig).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerConfig).void)).returns(::ServerConfig) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class ServerConfig end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerConfig).void)).returns(::ServerConfig) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class ServerConfig end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class ServerConfig end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class ServerConfig sig { returns(::ServerConfig) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ServerConfig) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ServerConfig]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ServerConfig).void + ).returns(T.nilable(::ServerConfig)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ServerConfig)) } def find_by(*args); end @@ -89,6 +139,54 @@ class ServerConfig sig { params(args: T.untyped).returns(::ServerConfig) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ServerConfig).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ServerConfig]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ServerConfig]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ServerConfig]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class ServerConfig end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class ServerConfig end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class ServerConfig sig { params(arg: T.untyped, args: T.untyped).returns(::ServerConfig) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerConfig)) } + sig { params(limit: Integer).returns(T::Array[::ServerConfig]) } def first(limit = nil); end sig { returns(::ServerConfig) } @@ -143,10 +254,36 @@ class ServerConfig sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerConfig)) } + sig { params(limit: Integer).returns(T::Array[::ServerConfig]) } def last(limit = nil); end sig { returns(::ServerConfig) } @@ -164,6 +301,13 @@ class ServerConfig sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerConfig).void)).returns(::ServerConfig) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerConfig).void) + ).returns(T::Array[::ServerConfig]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class ServerConfig sig { returns(::ServerConfig) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ServerConfig).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerConfig)) } + sig { params(limit: Integer).returns(T::Array[::ServerConfig]) } def take(limit = nil); end sig { returns(::ServerConfig) } @@ -255,8 +402,8 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -270,13 +417,13 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -288,40 +435,6 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -346,6 +459,9 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -370,6 +486,9 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -397,27 +516,15 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -447,8 +554,13 @@ class ServerConfig sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -456,8 +568,13 @@ class ServerConfig sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -492,8 +609,8 @@ class ServerConfig sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_change_to_be_saved; end - sig { returns(T::Boolean) } - def file_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_in_database; end @@ -501,8 +618,8 @@ class ServerConfig sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_previous_change; end - sig { returns(T::Boolean) } - def file_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_previously_was; end @@ -513,7 +630,52 @@ class ServerConfig sig { void } def file_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(T.nilable(T::Boolean)) } + def hidden; end + + sig { params(value: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def hidden=(value); end + + sig { returns(T::Boolean) } + def hidden?; end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_before_last_save; end + + sig { returns(T.untyped) } + def hidden_before_type_cast; end + + sig { returns(T::Boolean) } + def hidden_came_from_user?; end + + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def hidden_change; end + + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def hidden_change_to_be_saved; end + + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def hidden_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_in_database; end + + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def hidden_previous_change; end + + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def hidden_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_previously_was; end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_was; end + + sig { void } + def hidden_will_change!; end + + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -531,27 +693,72 @@ class ServerConfig sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -564,9 +771,15 @@ class ServerConfig sig { void } def restore_file!; end + sig { void } + def restore_hidden!; end + sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_updated_at!; end @@ -582,12 +795,24 @@ class ServerConfig sig { returns(T::Boolean) } def saved_change_to_file?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def saved_change_to_hidden; end + + sig { returns(T::Boolean) } + def saved_change_to_hidden?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def saved_change_to_updated_at; end @@ -618,8 +843,13 @@ class ServerConfig sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -627,8 +857,13 @@ class ServerConfig sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -645,9 +880,15 @@ class ServerConfig sig { returns(T::Boolean) } def will_save_change_to_file?; end + sig { returns(T::Boolean) } + def will_save_change_to_hidden?; end + sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_updated_at?; end end @@ -665,8 +906,8 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -680,13 +921,13 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -722,6 +963,9 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -746,6 +990,9 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -776,6 +1023,12 @@ class ServerConfig sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -786,10 +1039,48 @@ class ServerConfig Elem = type_member { { fixed: ::ServerConfig } } + sig { returns(T::Array[::ServerConfig]) } + def to_a; end + sig { returns(T::Array[::ServerConfig]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ServerConfig } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ServerConfig } } @@ -833,20 +1124,6 @@ class ServerConfig end def concat(*records); end - sig do - params( - records: T.any(::ServerConfig, Integer, String, T::Enumerable[T.any(::ServerConfig, Integer, String, T::Enumerable[::ServerConfig])]) - ).returns(T::Array[::ServerConfig]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ServerConfig, Integer, String, T::Enumerable[T.any(::ServerConfig, Integer, String, T::Enumerable[::ServerConfig])]) - ).returns(T::Array[::ServerConfig]) - end - def destroy(*records); end - sig { returns(T::Array[::ServerConfig]) } def load_target; end @@ -877,6 +1154,9 @@ class ServerConfig sig { returns(T::Array[::ServerConfig]) } def target; end + sig { returns(T::Array[::ServerConfig]) } + def to_a; end + sig { returns(T::Array[::ServerConfig]) } def to_ary; end end @@ -887,10 +1167,48 @@ class ServerConfig Elem = type_member { { fixed: ::ServerConfig } } + sig { returns(T::Array[::ServerConfig]) } + def to_a; end + sig { returns(T::Array[::ServerConfig]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ServerConfig } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ServerConfig } } diff --git a/sorbet/rbi/dsl/server_notification.rbi b/sorbet/rbi/dsl/server_notification.rbi index 1c66d5641..b5c8498a4 100644 --- a/sorbet/rbi/dsl/server_notification.rbi +++ b/sorbet/rbi/dsl/server_notification.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ServerNotification`. # Please instead update this file by running `bin/tapioca dsl ServerNotification`. + class ServerNotification include GeneratedAttributeMethods extend CommonRelationMethods @@ -22,9 +23,16 @@ class ServerNotification end def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerNotification).void)).returns(::ServerNotification) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -33,12 +41,20 @@ class ServerNotification end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ServerNotification).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerNotification).void)).returns(::ServerNotification) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -47,6 +63,13 @@ class ServerNotification end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerNotification).void)).returns(::ServerNotification) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -55,6 +78,12 @@ class ServerNotification end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -63,6 +92,12 @@ class ServerNotification end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -83,8 +118,23 @@ class ServerNotification sig { returns(::ServerNotification) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ServerNotification) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ServerNotification]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ServerNotification).void + ).returns(T.nilable(::ServerNotification)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ServerNotification)) } def find_by(*args); end @@ -92,6 +142,54 @@ class ServerNotification sig { params(args: T.untyped).returns(::ServerNotification) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ServerNotification).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ServerNotification]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ServerNotification]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ServerNotification]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -100,6 +198,12 @@ class ServerNotification end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -108,6 +212,12 @@ class ServerNotification end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -125,7 +235,8 @@ class ServerNotification sig { params(arg: T.untyped, args: T.untyped).returns(::ServerNotification) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerNotification)) } + sig { params(limit: Integer).returns(T::Array[::ServerNotification]) } def first(limit = nil); end sig { returns(::ServerNotification) } @@ -146,10 +257,36 @@ class ServerNotification sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerNotification)) } + sig { params(limit: Integer).returns(T::Array[::ServerNotification]) } def last(limit = nil); end sig { returns(::ServerNotification) } @@ -171,6 +308,13 @@ class ServerNotification sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerNotification).void)).returns(::ServerNotification) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerNotification).void) + ).returns(T::Array[::ServerNotification]) + end sig do params( attributes: T.untyped, @@ -214,15 +358,18 @@ class ServerNotification sig { returns(::ServerNotification) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ServerNotification).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerNotification)) } + sig { params(limit: Integer).returns(T::Array[::ServerNotification]) } def take(limit = nil); end sig { returns(::ServerNotification) } @@ -254,8 +401,8 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -269,13 +416,13 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -287,40 +434,6 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -345,6 +458,9 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -369,6 +485,9 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -396,33 +515,21 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end module GeneratedAttributeMethods - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -440,27 +547,72 @@ class ServerNotification sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -491,8 +643,8 @@ class ServerNotification sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def message_change_to_be_saved; end - sig { returns(T::Boolean) } - def message_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def message_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def message_in_database; end @@ -500,8 +652,8 @@ class ServerNotification sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def message_previous_change; end - sig { returns(T::Boolean) } - def message_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def message_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def message_previously_was; end @@ -536,8 +688,8 @@ class ServerNotification sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def notification_type_change_to_be_saved; end - sig { returns(T::Boolean) } - def notification_type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def notification_type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def notification_type_in_database; end @@ -545,8 +697,8 @@ class ServerNotification sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def notification_type_previous_change; end - sig { returns(T::Boolean) } - def notification_type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def notification_type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def notification_type_previously_was; end @@ -560,18 +712,27 @@ class ServerNotification sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_message!; end sig { void } def restore_notification_type!; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_message; end @@ -587,6 +748,9 @@ class ServerNotification sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_message?; end @@ -607,8 +771,8 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -622,13 +786,13 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -664,6 +828,9 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -688,6 +855,9 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -718,6 +888,12 @@ class ServerNotification sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -728,10 +904,48 @@ class ServerNotification Elem = type_member { { fixed: ::ServerNotification } } + sig { returns(T::Array[::ServerNotification]) } + def to_a; end + sig { returns(T::Array[::ServerNotification]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ServerNotification } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ServerNotification } } @@ -775,20 +989,6 @@ class ServerNotification end def concat(*records); end - sig do - params( - records: T.any(::ServerNotification, Integer, String, T::Enumerable[T.any(::ServerNotification, Integer, String, T::Enumerable[::ServerNotification])]) - ).returns(T::Array[::ServerNotification]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ServerNotification, Integer, String, T::Enumerable[T.any(::ServerNotification, Integer, String, T::Enumerable[::ServerNotification])]) - ).returns(T::Array[::ServerNotification]) - end - def destroy(*records); end - sig { returns(T::Array[::ServerNotification]) } def load_target; end @@ -819,6 +1019,9 @@ class ServerNotification sig { returns(T::Array[::ServerNotification]) } def target; end + sig { returns(T::Array[::ServerNotification]) } + def to_a; end + sig { returns(T::Array[::ServerNotification]) } def to_ary; end end @@ -829,10 +1032,48 @@ class ServerNotification Elem = type_member { { fixed: ::ServerNotification } } + sig { returns(T::Array[::ServerNotification]) } + def to_a; end + sig { returns(T::Array[::ServerNotification]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ServerNotification } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ServerNotification } } diff --git a/sorbet/rbi/dsl/server_notification_worker.rbi b/sorbet/rbi/dsl/server_notification_worker.rbi index 637274014..671c53a0a 100644 --- a/sorbet/rbi/dsl/server_notification_worker.rbi +++ b/sorbet/rbi/dsl/server_notification_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ServerNotificationWorker`. # Please instead update this file by running `bin/tapioca dsl ServerNotificationWorker`. + class ServerNotificationWorker class << self sig { params(reservation_id: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/server_statistic.rbi b/sorbet/rbi/dsl/server_statistic.rbi index 559380024..e11caf0ee 100644 --- a/sorbet/rbi/dsl/server_statistic.rbi +++ b/sorbet/rbi/dsl/server_statistic.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ServerStatistic`. # Please instead update this file by running `bin/tapioca dsl ServerStatistic`. + class ServerStatistic include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class ServerStatistic sig { params(block: T.nilable(T.proc.params(record: ::ServerStatistic).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerStatistic).void)).returns(::ServerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class ServerStatistic end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ServerStatistic).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerStatistic).void)).returns(::ServerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class ServerStatistic end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerStatistic).void)).returns(::ServerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class ServerStatistic end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class ServerStatistic end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class ServerStatistic sig { returns(::ServerStatistic) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ServerStatistic) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ServerStatistic]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ServerStatistic).void + ).returns(T.nilable(::ServerStatistic)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ServerStatistic)) } def find_by(*args); end @@ -89,6 +139,54 @@ class ServerStatistic sig { params(args: T.untyped).returns(::ServerStatistic) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ServerStatistic).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ServerStatistic]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ServerStatistic]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ServerStatistic]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class ServerStatistic end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class ServerStatistic end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class ServerStatistic sig { params(arg: T.untyped, args: T.untyped).returns(::ServerStatistic) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerStatistic)) } + sig { params(limit: Integer).returns(T::Array[::ServerStatistic]) } def first(limit = nil); end sig { returns(::ServerStatistic) } @@ -143,10 +254,36 @@ class ServerStatistic sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerStatistic)) } + sig { params(limit: Integer).returns(T::Array[::ServerStatistic]) } def last(limit = nil); end sig { returns(::ServerStatistic) } @@ -164,6 +301,13 @@ class ServerStatistic sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerStatistic).void)).returns(::ServerStatistic) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerStatistic).void) + ).returns(T::Array[::ServerStatistic]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class ServerStatistic sig { returns(::ServerStatistic) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ServerStatistic).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerStatistic)) } + sig { params(limit: Integer).returns(T::Array[::ServerStatistic]) } def take(limit = nil); end sig { returns(::ServerStatistic) } @@ -257,11 +404,29 @@ class ServerStatistic sig { params(value: T.nilable(::Reservation)).void } def reservation=(value); end + sig { returns(T::Boolean) } + def reservation_changed?; end + + sig { returns(T::Boolean) } + def reservation_previously_changed?; end + + sig { void } + def reset_reservation; end + + sig { void } + def reset_server; end + sig { returns(T.nilable(::Server)) } def server; end sig { params(value: T.nilable(::Server)).void } def server=(value); end + + sig { returns(T::Boolean) } + def server_changed?; end + + sig { returns(T::Boolean) } + def server_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -277,8 +442,8 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -292,13 +457,13 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -310,40 +475,6 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -368,6 +499,9 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -392,6 +526,9 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -419,27 +556,15 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -469,8 +594,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def cpu_usage_change_to_be_saved; end - sig { returns(T::Boolean) } - def cpu_usage_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def cpu_usage_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def cpu_usage_in_database; end @@ -478,8 +603,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def cpu_usage_previous_change; end - sig { returns(T::Boolean) } - def cpu_usage_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def cpu_usage_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def cpu_usage_previously_was; end @@ -514,8 +639,13 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -523,8 +653,13 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -559,8 +694,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def fps_change_to_be_saved; end - sig { returns(T::Boolean) } - def fps_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def fps_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def fps_in_database; end @@ -568,8 +703,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def fps_previous_change; end - sig { returns(T::Boolean) } - def fps_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def fps_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def fps_previously_was; end @@ -580,7 +715,7 @@ class ServerStatistic sig { void } def fps_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -598,27 +733,72 @@ class ServerStatistic sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -649,8 +829,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def map_name_change_to_be_saved; end - sig { returns(T::Boolean) } - def map_name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def map_name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def map_name_in_database; end @@ -658,8 +838,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def map_name_previous_change; end - sig { returns(T::Boolean) } - def map_name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def map_name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def map_name_previously_was; end @@ -694,8 +874,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def number_of_players_change_to_be_saved; end - sig { returns(T::Boolean) } - def number_of_players_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def number_of_players_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def number_of_players_in_database; end @@ -703,8 +883,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def number_of_players_previous_change; end - sig { returns(T::Boolean) } - def number_of_players_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def number_of_players_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def number_of_players_previously_was; end @@ -739,8 +919,8 @@ class ServerStatistic sig { returns(T.nilable([::Integer, ::Integer])) } def reservation_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def reservation_id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def reservation_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_in_database; end @@ -748,8 +928,8 @@ class ServerStatistic sig { returns(T.nilable([::Integer, ::Integer])) } def reservation_id_previous_change; end - sig { returns(T::Boolean) } - def reservation_id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def reservation_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def reservation_id_previously_was; end @@ -772,6 +952,9 @@ class ServerStatistic sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_map_name!; end @@ -811,12 +994,18 @@ class ServerStatistic sig { returns(T::Boolean) } def saved_change_to_fps?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_map_name; end @@ -883,8 +1072,8 @@ class ServerStatistic sig { returns(T.nilable([::Integer, ::Integer])) } def server_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def server_id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def server_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_in_database; end @@ -892,8 +1081,8 @@ class ServerStatistic sig { returns(T.nilable([::Integer, ::Integer])) } def server_id_previous_change; end - sig { returns(T::Boolean) } - def server_id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def server_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_previously_was; end @@ -928,8 +1117,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def traffic_in_change_to_be_saved; end - sig { returns(T::Boolean) } - def traffic_in_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def traffic_in_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def traffic_in_in_database; end @@ -937,8 +1126,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def traffic_in_previous_change; end - sig { returns(T::Boolean) } - def traffic_in_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def traffic_in_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def traffic_in_previously_was; end @@ -973,8 +1162,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def traffic_out_change_to_be_saved; end - sig { returns(T::Boolean) } - def traffic_out_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def traffic_out_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def traffic_out_in_database; end @@ -982,8 +1171,8 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def traffic_out_previous_change; end - sig { returns(T::Boolean) } - def traffic_out_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def traffic_out_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def traffic_out_previously_was; end @@ -1018,8 +1207,13 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1027,8 +1221,13 @@ class ServerStatistic sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1051,6 +1250,9 @@ class ServerStatistic sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_map_name?; end @@ -1086,8 +1288,8 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -1101,13 +1303,13 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -1143,6 +1345,9 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -1167,6 +1372,9 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1197,6 +1405,12 @@ class ServerStatistic sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -1207,10 +1421,48 @@ class ServerStatistic Elem = type_member { { fixed: ::ServerStatistic } } + sig { returns(T::Array[::ServerStatistic]) } + def to_a; end + sig { returns(T::Array[::ServerStatistic]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ServerStatistic } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ServerStatistic } } @@ -1254,20 +1506,6 @@ class ServerStatistic end def concat(*records); end - sig do - params( - records: T.any(::ServerStatistic, Integer, String, T::Enumerable[T.any(::ServerStatistic, Integer, String, T::Enumerable[::ServerStatistic])]) - ).returns(T::Array[::ServerStatistic]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ServerStatistic, Integer, String, T::Enumerable[T.any(::ServerStatistic, Integer, String, T::Enumerable[::ServerStatistic])]) - ).returns(T::Array[::ServerStatistic]) - end - def destroy(*records); end - sig { returns(T::Array[::ServerStatistic]) } def load_target; end @@ -1298,6 +1536,9 @@ class ServerStatistic sig { returns(T::Array[::ServerStatistic]) } def target; end + sig { returns(T::Array[::ServerStatistic]) } + def to_a; end + sig { returns(T::Array[::ServerStatistic]) } def to_ary; end end @@ -1308,10 +1549,48 @@ class ServerStatistic Elem = type_member { { fixed: ::ServerStatistic } } + sig { returns(T::Array[::ServerStatistic]) } + def to_a; end + sig { returns(T::Array[::ServerStatistic]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ServerStatistic } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ServerStatistic } } diff --git a/sorbet/rbi/dsl/server_statistics_controller.rbi b/sorbet/rbi/dsl/server_statistics_controller.rbi deleted file mode 100644 index fcbdc58d6..000000000 --- a/sorbet/rbi/dsl/server_statistics_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ServerStatisticsController`. -# Please instead update this file by running `bin/tapioca dsl ServerStatisticsController`. - -class ServerStatisticsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/server_update_worker.rbi b/sorbet/rbi/dsl/server_update_worker.rbi new file mode 100644 index 000000000..5c6233804 --- /dev/null +++ b/sorbet/rbi/dsl/server_update_worker.rbi @@ -0,0 +1,19 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `ServerUpdateWorker`. +# Please instead update this file by running `bin/tapioca dsl ServerUpdateWorker`. + + +class ServerUpdateWorker + class << self + sig { params(latest_version: T.untyped).returns(String) } + def perform_async(latest_version); end + + sig { params(interval: T.any(DateTime, Time), latest_version: T.untyped).returns(String) } + def perform_at(interval, latest_version); end + + sig { params(interval: Numeric, latest_version: T.untyped).returns(String) } + def perform_in(interval, latest_version); end + end +end diff --git a/sorbet/rbi/dsl/server_upload.rbi b/sorbet/rbi/dsl/server_upload.rbi index 26b92911b..2a5d70032 100644 --- a/sorbet/rbi/dsl/server_upload.rbi +++ b/sorbet/rbi/dsl/server_upload.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ServerUpload`. # Please instead update this file by running `bin/tapioca dsl ServerUpload`. + class ServerUpload include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class ServerUpload sig { params(block: T.nilable(T.proc.params(record: ::ServerUpload).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerUpload).void)).returns(::ServerUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class ServerUpload end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::ServerUpload).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerUpload).void)).returns(::ServerUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class ServerUpload end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerUpload).void)).returns(::ServerUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class ServerUpload end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class ServerUpload end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class ServerUpload sig { returns(::ServerUpload) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::ServerUpload) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::ServerUpload]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::ServerUpload).void + ).returns(T.nilable(::ServerUpload)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::ServerUpload)) } def find_by(*args); end @@ -89,6 +139,54 @@ class ServerUpload sig { params(args: T.untyped).returns(::ServerUpload) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::ServerUpload).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::ServerUpload]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::ServerUpload]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::ServerUpload]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class ServerUpload end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class ServerUpload end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class ServerUpload sig { params(arg: T.untyped, args: T.untyped).returns(::ServerUpload) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerUpload)) } + sig { params(limit: Integer).returns(T::Array[::ServerUpload]) } def first(limit = nil); end sig { returns(::ServerUpload) } @@ -143,10 +254,36 @@ class ServerUpload sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerUpload)) } + sig { params(limit: Integer).returns(T::Array[::ServerUpload]) } def last(limit = nil); end sig { returns(::ServerUpload) } @@ -164,6 +301,13 @@ class ServerUpload sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::ServerUpload).void)).returns(::ServerUpload) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::ServerUpload).void) + ).returns(T::Array[::ServerUpload]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class ServerUpload sig { returns(::ServerUpload) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::ServerUpload).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::ServerUpload)) } + sig { params(limit: Integer).returns(T::Array[::ServerUpload]) } def take(limit = nil); end sig { returns(::ServerUpload) } @@ -251,17 +398,35 @@ class ServerUpload sig { params(value: T.nilable(::FileUpload)).void } def file_upload=(value); end + sig { returns(T::Boolean) } + def file_upload_changed?; end + + sig { returns(T::Boolean) } + def file_upload_previously_changed?; end + sig { returns(T.nilable(::FileUpload)) } def reload_file_upload; end sig { returns(T.nilable(::Server)) } def reload_server; end + sig { void } + def reset_file_upload; end + + sig { void } + def reset_server; end + sig { returns(T.nilable(::Server)) } def server; end sig { params(value: T.nilable(::Server)).void } def server=(value); end + + sig { returns(T::Boolean) } + def server_changed?; end + + sig { returns(T::Boolean) } + def server_previously_changed?; end end module GeneratedAssociationRelationMethods @@ -277,8 +442,8 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -292,13 +457,13 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -310,40 +475,6 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -368,6 +499,9 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -392,6 +526,9 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -419,33 +556,21 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end module GeneratedAttributeMethods - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + sig { returns(::ActiveSupport::TimeWithZone) } def created_at; end sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } @@ -463,23 +588,23 @@ class ServerUpload sig { returns(T::Boolean) } def created_at_came_from_user?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_change; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -514,8 +639,8 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def file_upload_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def file_upload_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def file_upload_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def file_upload_id_in_database; end @@ -523,8 +648,8 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def file_upload_id_previous_change; end - sig { returns(T::Boolean) } - def file_upload_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def file_upload_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def file_upload_id_previously_was; end @@ -535,7 +660,7 @@ class ServerUpload sig { void } def file_upload_id_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -553,27 +678,72 @@ class ServerUpload sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -589,6 +759,9 @@ class ServerUpload sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_server_id!; end @@ -601,7 +774,7 @@ class ServerUpload sig { void } def restore_uploaded_at!; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def saved_change_to_created_at; end sig { returns(T::Boolean) } @@ -613,12 +786,18 @@ class ServerUpload sig { returns(T::Boolean) } def saved_change_to_file_upload_id?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def saved_change_to_server_id; end @@ -631,7 +810,7 @@ class ServerUpload sig { returns(T::Boolean) } def saved_change_to_started_at?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def saved_change_to_updated_at; end sig { returns(T::Boolean) } @@ -667,8 +846,8 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def server_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_in_database; end @@ -676,8 +855,8 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def server_id_previous_change; end - sig { returns(T::Boolean) } - def server_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def server_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def server_id_previously_was; end @@ -712,8 +891,13 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def started_at_in_database; end @@ -721,8 +905,13 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def started_at_previous_change; end - sig { returns(T::Boolean) } - def started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def started_at_previously_was; end @@ -733,7 +922,7 @@ class ServerUpload sig { void } def started_at_will_change!; end - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + sig { returns(::ActiveSupport::TimeWithZone) } def updated_at; end sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } @@ -751,23 +940,23 @@ class ServerUpload sig { returns(T::Boolean) } def updated_at_came_from_user?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_change; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -802,8 +991,13 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def uploaded_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def uploaded_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def uploaded_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def uploaded_at_in_database; end @@ -811,8 +1005,13 @@ class ServerUpload sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def uploaded_at_previous_change; end - sig { returns(T::Boolean) } - def uploaded_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def uploaded_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def uploaded_at_previously_was; end @@ -832,6 +1031,9 @@ class ServerUpload sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_server_id?; end @@ -858,8 +1060,8 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -873,13 +1075,13 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -915,6 +1117,9 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -939,6 +1144,9 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -969,6 +1177,12 @@ class ServerUpload sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -979,10 +1193,48 @@ class ServerUpload Elem = type_member { { fixed: ::ServerUpload } } + sig { returns(T::Array[::ServerUpload]) } + def to_a; end + sig { returns(T::Array[::ServerUpload]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::ServerUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::ServerUpload } } @@ -1026,20 +1278,6 @@ class ServerUpload end def concat(*records); end - sig do - params( - records: T.any(::ServerUpload, Integer, String, T::Enumerable[T.any(::ServerUpload, Integer, String, T::Enumerable[::ServerUpload])]) - ).returns(T::Array[::ServerUpload]) - end - def delete(*records); end - - sig do - params( - records: T.any(::ServerUpload, Integer, String, T::Enumerable[T.any(::ServerUpload, Integer, String, T::Enumerable[::ServerUpload])]) - ).returns(T::Array[::ServerUpload]) - end - def destroy(*records); end - sig { returns(T::Array[::ServerUpload]) } def load_target; end @@ -1070,6 +1308,9 @@ class ServerUpload sig { returns(T::Array[::ServerUpload]) } def target; end + sig { returns(T::Array[::ServerUpload]) } + def to_a; end + sig { returns(T::Array[::ServerUpload]) } def to_ary; end end @@ -1080,10 +1321,48 @@ class ServerUpload Elem = type_member { { fixed: ::ServerUpload } } + sig { returns(T::Array[::ServerUpload]) } + def to_a; end + sig { returns(T::Array[::ServerUpload]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::ServerUpload } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::ServerUpload } } diff --git a/sorbet/rbi/dsl/server_updates_worker.rbi b/sorbet/rbi/dsl/server_version_worker.rbi similarity index 75% rename from sorbet/rbi/dsl/server_updates_worker.rbi rename to sorbet/rbi/dsl/server_version_worker.rbi index 5b9c588a6..3231f9428 100644 --- a/sorbet/rbi/dsl/server_updates_worker.rbi +++ b/sorbet/rbi/dsl/server_version_worker.rbi @@ -1,10 +1,11 @@ # typed: true # DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ServerUpdatesWorker`. -# Please instead update this file by running `bin/tapioca dsl ServerUpdatesWorker`. +# This is an autogenerated file for dynamic methods in `ServerVersionWorker`. +# Please instead update this file by running `bin/tapioca dsl ServerVersionWorker`. -class ServerUpdatesWorker + +class ServerVersionWorker class << self sig { returns(String) } def perform_async; end diff --git a/sorbet/rbi/dsl/servers_controller.rbi b/sorbet/rbi/dsl/servers_controller.rbi deleted file mode 100644 index e68fc294c..000000000 --- a/sorbet/rbi/dsl/servers_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `ServersController`. -# Please instead update this file by running `bin/tapioca dsl ServersController`. - -class ServersController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/servers_notification_worker.rbi b/sorbet/rbi/dsl/servers_notification_worker.rbi index 7895c82a3..57d6309f1 100644 --- a/sorbet/rbi/dsl/servers_notification_worker.rbi +++ b/sorbet/rbi/dsl/servers_notification_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `ServersNotificationWorker`. # Please instead update this file by running `bin/tapioca dsl ServersNotificationWorker`. + class ServersNotificationWorker class << self sig { returns(String) } diff --git a/sorbet/rbi/dsl/sessions_controller.rbi b/sorbet/rbi/dsl/sessions_controller.rbi deleted file mode 100644 index ed31e53ac..000000000 --- a/sorbet/rbi/dsl/sessions_controller.rbi +++ /dev/null @@ -1,58 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `SessionsController`. -# Please instead update this file by running `bin/tapioca dsl SessionsController`. - -class SessionsController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - include ::ApplicationController::HelperMethods - - sig { returns(T.untyped) } - def devise_mapping; end - - sig { returns(T.untyped) } - def resource; end - - sig { returns(T.untyped) } - def resource_class; end - - sig { returns(T.untyped) } - def resource_name; end - - sig { returns(T.untyped) } - def resource_params; end - - sig { returns(T.untyped) } - def scope_name; end - - sig { returns(T.untyped) } - def signed_in_resource; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/simrai_server.rbi b/sorbet/rbi/dsl/simrai_server.rbi deleted file mode 100644 index af17a1882..000000000 --- a/sorbet/rbi/dsl/simrai_server.rbi +++ /dev/null @@ -1,2278 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `SimraiServer`. -# Please instead update this file by running `bin/tapioca dsl SimraiServer`. - -class SimraiServer - include GeneratedAssociationMethods - include GeneratedAttributeMethods - extend CommonRelationMethods - extend GeneratedRelationMethods - - private - - sig { returns(NilClass) } - def to_ary; end - - module CommonRelationMethods - sig { params(block: T.nilable(T.proc.params(record: ::SimraiServer).returns(T.untyped))).returns(T::Boolean) } - def any?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def average(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def build(attributes = nil, &block); end - - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } - def calculate(operation, column_name); end - - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def create(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def create!(attributes = nil, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def create_or_find_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def create_or_find_by!(attributes, &block); end - - sig { returns(T::Array[::SimraiServer]) } - def destroy_all; end - - sig { params(conditions: T.untyped).returns(T::Boolean) } - def exists?(conditions = :none); end - - sig { returns(T.nilable(::SimraiServer)) } - def fifth; end - - sig { returns(::SimraiServer) } - def fifth!; end - - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end - - sig { params(args: T.untyped).returns(T.nilable(::SimraiServer)) } - def find_by(*args); end - - sig { params(args: T.untyped).returns(::SimraiServer) } - def find_by!(*args); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def find_or_create_by(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def find_or_create_by!(attributes, &block); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def find_or_initialize_by(attributes, &block); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(T.nilable(::SimraiServer)) } - def find_signed(signed_id, purpose: nil); end - - sig { params(signed_id: T.untyped, purpose: T.untyped).returns(::SimraiServer) } - def find_signed!(signed_id, purpose: nil); end - - sig { params(arg: T.untyped, args: T.untyped).returns(::SimraiServer) } - def find_sole_by(arg, *args); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def first(limit = nil); end - - sig { returns(::SimraiServer) } - def first!; end - - sig { returns(T.nilable(::SimraiServer)) } - def forty_two; end - - sig { returns(::SimraiServer) } - def forty_two!; end - - sig { returns(T.nilable(::SimraiServer)) } - def fourth; end - - sig { returns(::SimraiServer) } - def fourth!; end - - sig { returns(Array) } - def ids; end - - sig { params(record: T.untyped).returns(T::Boolean) } - def include?(record); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def last(limit = nil); end - - sig { returns(::SimraiServer) } - def last!; end - - sig { params(block: T.nilable(T.proc.params(record: ::SimraiServer).returns(T.untyped))).returns(T::Boolean) } - def many?(&block); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def maximum(column_name); end - - sig { params(record: T.untyped).returns(T::Boolean) } - def member?(record); end - - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } - def minimum(column_name); end - - sig do - params( - attributes: T.untyped, - block: T.nilable(T.proc.params(object: ::SimraiServer).void) - ).returns(::SimraiServer) - end - def new(attributes = nil, &block); end - - sig { params(block: T.nilable(T.proc.params(record: ::SimraiServer).returns(T.untyped))).returns(T::Boolean) } - def none?(&block); end - - sig { params(block: T.nilable(T.proc.params(record: ::SimraiServer).returns(T.untyped))).returns(T::Boolean) } - def one?(&block); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pick(*column_names); end - - sig { params(column_names: T.untyped).returns(T.untyped) } - def pluck(*column_names); end - - sig { returns(T.nilable(::SimraiServer)) } - def second; end - - sig { returns(::SimraiServer) } - def second!; end - - sig { returns(T.nilable(::SimraiServer)) } - def second_to_last; end - - sig { returns(::SimraiServer) } - def second_to_last!; end - - sig { returns(::SimraiServer) } - def sole; end - - sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) - end - def sum(column_name = nil, &block); end - - sig { params(limit: T.untyped).returns(T.untyped) } - def take(limit = nil); end - - sig { returns(::SimraiServer) } - def take!; end - - sig { returns(T.nilable(::SimraiServer)) } - def third; end - - sig { returns(::SimraiServer) } - def third!; end - - sig { returns(T.nilable(::SimraiServer)) } - def third_to_last; end - - sig { returns(::SimraiServer) } - def third_to_last!; end - end - - module GeneratedAssociationMethods - sig { params(args: T.untyped, blk: T.untyped).returns(::Location) } - def build_location(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::Location) } - def create_location(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(::Location) } - def create_location!(*args, &blk); end - - sig { returns(T::Array[T.untyped]) } - def current_reservation_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def current_reservation_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :current_reservations`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::Reservation::PrivateCollectionProxy) } - def current_reservations; end - - sig { params(value: T::Enumerable[::Reservation]).void } - def current_reservations=(value); end - - sig { returns(T::Array[T.untyped]) } - def group_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def group_ids=(ids); end - - sig { returns(T::Array[T.untyped]) } - def group_server_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def group_server_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :group_servers`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::GroupServer::PrivateCollectionProxy) } - def group_servers; end - - sig { params(value: T::Enumerable[::GroupServer]).void } - def group_servers=(value); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :groups, through: :group_servers`. - # 🔗 [Rails guide for `has_many_through` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-through-association) - sig { returns(::Group::PrivateCollectionProxy) } - def groups; end - - sig { params(value: T::Enumerable[::Group]).void } - def groups=(value); end - - sig { returns(T.nilable(::Location)) } - def location; end - - sig { params(value: T.nilable(::Location)).void } - def location=(value); end - - sig { returns(T::Array[T.untyped]) } - def recent_server_statistic_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def recent_server_statistic_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :recent_server_statistics`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::ServerStatistic::PrivateCollectionProxy) } - def recent_server_statistics; end - - sig { params(value: T::Enumerable[::ServerStatistic]).void } - def recent_server_statistics=(value); end - - sig { returns(T.nilable(::Location)) } - def reload_location; end - - sig { returns(T::Array[T.untyped]) } - def reservation_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def reservation_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :reservations`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::Reservation::PrivateCollectionProxy) } - def reservations; end - - sig { params(value: T::Enumerable[::Reservation]).void } - def reservations=(value); end - - sig { returns(T::Array[T.untyped]) } - def server_statistic_ids; end - - sig { params(ids: T::Array[T.untyped]).returns(T::Array[T.untyped]) } - def server_statistic_ids=(ids); end - - # This method is created by ActiveRecord on the `Server` class because it declared `has_many :server_statistics`. - # 🔗 [Rails guide for `has_many` association](https://guides.rubyonrails.org/association_basics.html#the-has-many-association) - sig { returns(::ServerStatistic::PrivateCollectionProxy) } - def server_statistics; end - - sig { params(value: T::Enumerable[::ServerStatistic]).void } - def server_statistics=(value); end - end - - module GeneratedAssociationRelationMethods - sig { returns(PrivateAssociationRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def includes(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def near(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def not_reverse_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def unscope(*args, &blk); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def within_bounding_box(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def without(*args, &blk); end - end - - module GeneratedAttributeMethods - sig { returns(T.nilable(T::Boolean)) } - def active; end - - sig { params(value: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } - def active=(value); end - - sig { returns(T::Boolean) } - def active?; end - - sig { returns(T.nilable(T::Boolean)) } - def active_before_last_save; end - - sig { returns(T.untyped) } - def active_before_type_cast; end - - sig { returns(T::Boolean) } - def active_came_from_user?; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def active_change; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def active_change_to_be_saved; end - - sig { returns(T::Boolean) } - def active_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def active_in_database; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def active_previous_change; end - - sig { returns(T::Boolean) } - def active_previously_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def active_previously_was; end - - sig { returns(T.nilable(T::Boolean)) } - def active_was; end - - sig { void } - def active_will_change!; end - - sig { returns(T.nilable(::String)) } - def billing_id; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def billing_id=(value); end - - sig { returns(T::Boolean) } - def billing_id?; end - - sig { returns(T.nilable(::String)) } - def billing_id_before_last_save; end - - sig { returns(T.untyped) } - def billing_id_before_type_cast; end - - sig { returns(T::Boolean) } - def billing_id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def billing_id_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def billing_id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def billing_id_changed?; end - - sig { returns(T.nilable(::String)) } - def billing_id_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def billing_id_previous_change; end - - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def billing_id_previously_was; end - - sig { returns(T.nilable(::String)) } - def billing_id_was; end - - sig { void } - def billing_id_will_change!; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at; end - - sig { params(value: T.nilable(::ActiveSupport::TimeWithZone)).returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at=(value); end - - sig { returns(T::Boolean) } - def created_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_before_last_save; end - - sig { returns(T.untyped) } - def created_at_before_type_cast; end - - sig { returns(T::Boolean) } - def created_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def created_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def created_at_previous_change; end - - sig { returns(T::Boolean) } - def created_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def created_at_was; end - - sig { void } - def created_at_will_change!; end - - sig { returns(T.nilable(::String)) } - def ftp_password; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def ftp_password=(value); end - - sig { returns(T::Boolean) } - def ftp_password?; end - - sig { returns(T.nilable(::String)) } - def ftp_password_before_last_save; end - - sig { returns(T.untyped) } - def ftp_password_before_type_cast; end - - sig { returns(T::Boolean) } - def ftp_password_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_password_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_password_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ftp_password_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_password_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_password_previous_change; end - - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_password_previously_was; end - - sig { returns(T.nilable(::String)) } - def ftp_password_was; end - - sig { void } - def ftp_password_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def ftp_port=(value); end - - sig { returns(T::Boolean) } - def ftp_port?; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_before_last_save; end - - sig { returns(T.untyped) } - def ftp_port_before_type_cast; end - - sig { returns(T::Boolean) } - def ftp_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def ftp_port_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def ftp_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ftp_port_changed?; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def ftp_port_previous_change; end - - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def ftp_port_was; end - - sig { void } - def ftp_port_will_change!; end - - sig { returns(T.nilable(::String)) } - def ftp_username; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def ftp_username=(value); end - - sig { returns(T::Boolean) } - def ftp_username?; end - - sig { returns(T.nilable(::String)) } - def ftp_username_before_last_save; end - - sig { returns(T.untyped) } - def ftp_username_before_type_cast; end - - sig { returns(T::Boolean) } - def ftp_username_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_username_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_username_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ftp_username_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_username_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ftp_username_previous_change; end - - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def ftp_username_previously_was; end - - sig { returns(T.nilable(::String)) } - def ftp_username_was; end - - sig { void } - def ftp_username_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def id; end - - sig { params(value: ::Integer).returns(::Integer) } - def id=(value); end - - sig { returns(T::Boolean) } - def id?; end - - sig { returns(T.nilable(::Integer)) } - def id_before_last_save; end - - sig { returns(T.untyped) } - def id_before_type_cast; end - - sig { returns(T::Boolean) } - def id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def id_changed?; end - - sig { returns(T.nilable(::Integer)) } - def id_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def id_previous_change; end - - sig { returns(T::Boolean) } - def id_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def id_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def id_was; end - - sig { void } - def id_will_change!; end - - sig { returns(T.nilable(::String)) } - def ip; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def ip=(value); end - - sig { returns(T::Boolean) } - def ip?; end - - sig { returns(T.nilable(::String)) } - def ip_before_last_save; end - - sig { returns(T.untyped) } - def ip_before_type_cast; end - - sig { returns(T::Boolean) } - def ip_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ip_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ip_change_to_be_saved; end - - sig { returns(T::Boolean) } - def ip_changed?; end - - sig { returns(T.nilable(::String)) } - def ip_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def ip_previous_change; end - - sig { returns(T::Boolean) } - def ip_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def ip_previously_was; end - - sig { returns(T.nilable(::String)) } - def ip_was; end - - sig { void } - def ip_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def last_known_version=(value); end - - sig { returns(T::Boolean) } - def last_known_version?; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_before_last_save; end - - sig { returns(T.untyped) } - def last_known_version_before_type_cast; end - - sig { returns(T::Boolean) } - def last_known_version_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def last_known_version_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def last_known_version_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_known_version_changed?; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def last_known_version_previous_change; end - - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def last_known_version_was; end - - sig { void } - def last_known_version_will_change!; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def last_sdr_ip=(value); end - - sig { returns(T::Boolean) } - def last_sdr_ip?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_before_last_save; end - - sig { returns(T.untyped) } - def last_sdr_ip_before_type_cast; end - - sig { returns(T::Boolean) } - def last_sdr_ip_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_ip_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_ip_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_ip_previous_change; end - - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_previously_was; end - - sig { returns(T.nilable(::String)) } - def last_sdr_ip_was; end - - sig { void } - def last_sdr_ip_will_change!; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def last_sdr_port=(value); end - - sig { returns(T::Boolean) } - def last_sdr_port?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_before_last_save; end - - sig { returns(T.untyped) } - def last_sdr_port_before_type_cast; end - - sig { returns(T::Boolean) } - def last_sdr_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_port_previous_change; end - - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_previously_was; end - - sig { returns(T.nilable(::String)) } - def last_sdr_port_was; end - - sig { void } - def last_sdr_port_will_change!; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def last_sdr_tv_port=(value); end - - sig { returns(T::Boolean) } - def last_sdr_tv_port?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_before_last_save; end - - sig { returns(T.untyped) } - def last_sdr_tv_port_before_type_cast; end - - sig { returns(T::Boolean) } - def last_sdr_tv_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_tv_port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_tv_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def last_sdr_tv_port_previous_change; end - - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_previously_was; end - - sig { returns(T.nilable(::String)) } - def last_sdr_tv_port_was; end - - sig { void } - def last_sdr_tv_port_will_change!; end - - sig { returns(T.nilable(::Float)) } - def latitude; end - - sig { params(value: T.nilable(::Float)).returns(T.nilable(::Float)) } - def latitude=(value); end - - sig { returns(T::Boolean) } - def latitude?; end - - sig { returns(T.nilable(::Float)) } - def latitude_before_last_save; end - - sig { returns(T.untyped) } - def latitude_before_type_cast; end - - sig { returns(T::Boolean) } - def latitude_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def latitude_change; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def latitude_change_to_be_saved; end - - sig { returns(T::Boolean) } - def latitude_changed?; end - - sig { returns(T.nilable(::Float)) } - def latitude_in_database; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def latitude_previous_change; end - - sig { returns(T::Boolean) } - def latitude_previously_changed?; end - - sig { returns(T.nilable(::Float)) } - def latitude_previously_was; end - - sig { returns(T.nilable(::Float)) } - def latitude_was; end - - sig { void } - def latitude_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def location_id; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def location_id=(value); end - - sig { returns(T::Boolean) } - def location_id?; end - - sig { returns(T.nilable(::Integer)) } - def location_id_before_last_save; end - - sig { returns(T.untyped) } - def location_id_before_type_cast; end - - sig { returns(T::Boolean) } - def location_id_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def location_id_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def location_id_change_to_be_saved; end - - sig { returns(T::Boolean) } - def location_id_changed?; end - - sig { returns(T.nilable(::Integer)) } - def location_id_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def location_id_previous_change; end - - sig { returns(T::Boolean) } - def location_id_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def location_id_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def location_id_was; end - - sig { void } - def location_id_will_change!; end - - sig { returns(T.nilable(::Float)) } - def longitude; end - - sig { params(value: T.nilable(::Float)).returns(T.nilable(::Float)) } - def longitude=(value); end - - sig { returns(T::Boolean) } - def longitude?; end - - sig { returns(T.nilable(::Float)) } - def longitude_before_last_save; end - - sig { returns(T.untyped) } - def longitude_before_type_cast; end - - sig { returns(T::Boolean) } - def longitude_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def longitude_change; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def longitude_change_to_be_saved; end - - sig { returns(T::Boolean) } - def longitude_changed?; end - - sig { returns(T.nilable(::Float)) } - def longitude_in_database; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def longitude_previous_change; end - - sig { returns(T::Boolean) } - def longitude_previously_changed?; end - - sig { returns(T.nilable(::Float)) } - def longitude_previously_was; end - - sig { returns(T.nilable(::Float)) } - def longitude_was; end - - sig { void } - def longitude_will_change!; end - - sig { returns(T.nilable(::String)) } - def name; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def name=(value); end - - sig { returns(T::Boolean) } - def name?; end - - sig { returns(T.nilable(::String)) } - def name_before_last_save; end - - sig { returns(T.untyped) } - def name_before_type_cast; end - - sig { returns(T::Boolean) } - def name_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def name_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def name_change_to_be_saved; end - - sig { returns(T::Boolean) } - def name_changed?; end - - sig { returns(T.nilable(::String)) } - def name_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def name_previous_change; end - - sig { returns(T::Boolean) } - def name_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def name_previously_was; end - - sig { returns(T.nilable(::String)) } - def name_was; end - - sig { void } - def name_will_change!; end - - sig { returns(T.nilable(::String)) } - def path; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def path=(value); end - - sig { returns(T::Boolean) } - def path?; end - - sig { returns(T.nilable(::String)) } - def path_before_last_save; end - - sig { returns(T.untyped) } - def path_before_type_cast; end - - sig { returns(T::Boolean) } - def path_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def path_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def path_change_to_be_saved; end - - sig { returns(T::Boolean) } - def path_changed?; end - - sig { returns(T.nilable(::String)) } - def path_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def path_previous_change; end - - sig { returns(T::Boolean) } - def path_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def path_previously_was; end - - sig { returns(T.nilable(::String)) } - def path_was; end - - sig { void } - def path_will_change!; end - - sig { returns(T.nilable(::String)) } - def port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def port=(value); end - - sig { returns(T::Boolean) } - def port?; end - - sig { returns(T.nilable(::String)) } - def port_before_last_save; end - - sig { returns(T.untyped) } - def port_before_type_cast; end - - sig { returns(T::Boolean) } - def port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def port_changed?; end - - sig { returns(T.nilable(::String)) } - def port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def port_previous_change; end - - sig { returns(T::Boolean) } - def port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def port_previously_was; end - - sig { returns(T.nilable(::String)) } - def port_was; end - - sig { void } - def port_will_change!; end - - sig { returns(T.nilable(::Integer)) } - def position; end - - sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } - def position=(value); end - - sig { returns(T::Boolean) } - def position?; end - - sig { returns(T.nilable(::Integer)) } - def position_before_last_save; end - - sig { returns(T.untyped) } - def position_before_type_cast; end - - sig { returns(T::Boolean) } - def position_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def position_change; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def position_change_to_be_saved; end - - sig { returns(T::Boolean) } - def position_changed?; end - - sig { returns(T.nilable(::Integer)) } - def position_in_database; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def position_previous_change; end - - sig { returns(T::Boolean) } - def position_previously_changed?; end - - sig { returns(T.nilable(::Integer)) } - def position_previously_was; end - - sig { returns(T.nilable(::Integer)) } - def position_was; end - - sig { void } - def position_will_change!; end - - sig { returns(T.nilable(::String)) } - def rcon; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def rcon=(value); end - - sig { returns(T::Boolean) } - def rcon?; end - - sig { returns(T.nilable(::String)) } - def rcon_before_last_save; end - - sig { returns(T.untyped) } - def rcon_before_type_cast; end - - sig { returns(T::Boolean) } - def rcon_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def rcon_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def rcon_change_to_be_saved; end - - sig { returns(T::Boolean) } - def rcon_changed?; end - - sig { returns(T.nilable(::String)) } - def rcon_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def rcon_previous_change; end - - sig { returns(T::Boolean) } - def rcon_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def rcon_previously_was; end - - sig { returns(T.nilable(::String)) } - def rcon_was; end - - sig { void } - def rcon_will_change!; end - - sig { void } - def restore_active!; end - - sig { void } - def restore_billing_id!; end - - sig { void } - def restore_created_at!; end - - sig { void } - def restore_ftp_password!; end - - sig { void } - def restore_ftp_port!; end - - sig { void } - def restore_ftp_username!; end - - sig { void } - def restore_id!; end - - sig { void } - def restore_ip!; end - - sig { void } - def restore_last_known_version!; end - - sig { void } - def restore_last_sdr_ip!; end - - sig { void } - def restore_last_sdr_port!; end - - sig { void } - def restore_last_sdr_tv_port!; end - - sig { void } - def restore_latitude!; end - - sig { void } - def restore_location_id!; end - - sig { void } - def restore_longitude!; end - - sig { void } - def restore_name!; end - - sig { void } - def restore_path!; end - - sig { void } - def restore_port!; end - - sig { void } - def restore_position!; end - - sig { void } - def restore_rcon!; end - - sig { void } - def restore_sdr!; end - - sig { void } - def restore_tv_port!; end - - sig { void } - def restore_type!; end - - sig { void } - def restore_update_started_at!; end - - sig { void } - def restore_update_status!; end - - sig { void } - def restore_updated_at!; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def saved_change_to_active; end - - sig { returns(T::Boolean) } - def saved_change_to_active?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_billing_id; end - - sig { returns(T::Boolean) } - def saved_change_to_billing_id?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_created_at; end - - sig { returns(T::Boolean) } - def saved_change_to_created_at?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_ftp_password; end - - sig { returns(T::Boolean) } - def saved_change_to_ftp_password?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_ftp_port; end - - sig { returns(T::Boolean) } - def saved_change_to_ftp_port?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_ftp_username; end - - sig { returns(T::Boolean) } - def saved_change_to_ftp_username?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_id; end - - sig { returns(T::Boolean) } - def saved_change_to_id?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_ip; end - - sig { returns(T::Boolean) } - def saved_change_to_ip?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_last_known_version; end - - sig { returns(T::Boolean) } - def saved_change_to_last_known_version?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_last_sdr_ip; end - - sig { returns(T::Boolean) } - def saved_change_to_last_sdr_ip?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_last_sdr_port; end - - sig { returns(T::Boolean) } - def saved_change_to_last_sdr_port?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_last_sdr_tv_port; end - - sig { returns(T::Boolean) } - def saved_change_to_last_sdr_tv_port?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def saved_change_to_latitude; end - - sig { returns(T::Boolean) } - def saved_change_to_latitude?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_location_id; end - - sig { returns(T::Boolean) } - def saved_change_to_location_id?; end - - sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } - def saved_change_to_longitude; end - - sig { returns(T::Boolean) } - def saved_change_to_longitude?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_name; end - - sig { returns(T::Boolean) } - def saved_change_to_name?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_path; end - - sig { returns(T::Boolean) } - def saved_change_to_path?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_port; end - - sig { returns(T::Boolean) } - def saved_change_to_port?; end - - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } - def saved_change_to_position; end - - sig { returns(T::Boolean) } - def saved_change_to_position?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_rcon; end - - sig { returns(T::Boolean) } - def saved_change_to_rcon?; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def saved_change_to_sdr; end - - sig { returns(T::Boolean) } - def saved_change_to_sdr?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_tv_port; end - - sig { returns(T::Boolean) } - def saved_change_to_tv_port?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_type; end - - sig { returns(T::Boolean) } - def saved_change_to_type?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_update_started_at; end - - sig { returns(T::Boolean) } - def saved_change_to_update_started_at?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def saved_change_to_update_status; end - - sig { returns(T::Boolean) } - def saved_change_to_update_status?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def saved_change_to_updated_at; end - - sig { returns(T::Boolean) } - def saved_change_to_updated_at?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr; end - - sig { params(value: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } - def sdr=(value); end - - sig { returns(T::Boolean) } - def sdr?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_before_last_save; end - - sig { returns(T.untyped) } - def sdr_before_type_cast; end - - sig { returns(T::Boolean) } - def sdr_came_from_user?; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def sdr_change; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def sdr_change_to_be_saved; end - - sig { returns(T::Boolean) } - def sdr_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_in_database; end - - sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } - def sdr_previous_change; end - - sig { returns(T::Boolean) } - def sdr_previously_changed?; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_previously_was; end - - sig { returns(T.nilable(T::Boolean)) } - def sdr_was; end - - sig { void } - def sdr_will_change!; end - - sig { returns(T.nilable(::String)) } - def tv_port; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def tv_port=(value); end - - sig { returns(T::Boolean) } - def tv_port?; end - - sig { returns(T.nilable(::String)) } - def tv_port_before_last_save; end - - sig { returns(T.untyped) } - def tv_port_before_type_cast; end - - sig { returns(T::Boolean) } - def tv_port_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def tv_port_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def tv_port_change_to_be_saved; end - - sig { returns(T::Boolean) } - def tv_port_changed?; end - - sig { returns(T.nilable(::String)) } - def tv_port_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def tv_port_previous_change; end - - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def tv_port_previously_was; end - - sig { returns(T.nilable(::String)) } - def tv_port_was; end - - sig { void } - def tv_port_will_change!; end - - sig { returns(T.nilable(::String)) } - def type; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def type=(value); end - - sig { returns(T::Boolean) } - def type?; end - - sig { returns(T.nilable(::String)) } - def type_before_last_save; end - - sig { returns(T.untyped) } - def type_before_type_cast; end - - sig { returns(T::Boolean) } - def type_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def type_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def type_change_to_be_saved; end - - sig { returns(T::Boolean) } - def type_changed?; end - - sig { returns(T.nilable(::String)) } - def type_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def type_previous_change; end - - sig { returns(T::Boolean) } - def type_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def type_previously_was; end - - sig { returns(T.nilable(::String)) } - def type_was; end - - sig { void } - def type_will_change!; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at; end - - sig { params(value: T.nilable(::ActiveSupport::TimeWithZone)).returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at=(value); end - - sig { returns(T::Boolean) } - def update_started_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_before_last_save; end - - sig { returns(T.untyped) } - def update_started_at_before_type_cast; end - - sig { returns(T::Boolean) } - def update_started_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def update_started_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def update_started_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def update_started_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def update_started_at_previous_change; end - - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def update_started_at_was; end - - sig { void } - def update_started_at_will_change!; end - - sig { returns(T.nilable(::String)) } - def update_status; end - - sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } - def update_status=(value); end - - sig { returns(T::Boolean) } - def update_status?; end - - sig { returns(T.nilable(::String)) } - def update_status_before_last_save; end - - sig { returns(T.untyped) } - def update_status_before_type_cast; end - - sig { returns(T::Boolean) } - def update_status_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def update_status_change; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def update_status_change_to_be_saved; end - - sig { returns(T::Boolean) } - def update_status_changed?; end - - sig { returns(T.nilable(::String)) } - def update_status_in_database; end - - sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } - def update_status_previous_change; end - - sig { returns(T::Boolean) } - def update_status_previously_changed?; end - - sig { returns(T.nilable(::String)) } - def update_status_previously_was; end - - sig { returns(T.nilable(::String)) } - def update_status_was; end - - sig { void } - def update_status_will_change!; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at; end - - sig { params(value: T.nilable(::ActiveSupport::TimeWithZone)).returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at=(value); end - - sig { returns(T::Boolean) } - def updated_at?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_before_last_save; end - - sig { returns(T.untyped) } - def updated_at_before_type_cast; end - - sig { returns(T::Boolean) } - def updated_at_came_from_user?; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_change; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_change_to_be_saved; end - - sig { returns(T::Boolean) } - def updated_at_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_in_database; end - - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } - def updated_at_previous_change; end - - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_previously_was; end - - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } - def updated_at_was; end - - sig { void } - def updated_at_will_change!; end - - sig { returns(T::Boolean) } - def will_save_change_to_active?; end - - sig { returns(T::Boolean) } - def will_save_change_to_billing_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_created_at?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ftp_password?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ftp_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ftp_username?; end - - sig { returns(T::Boolean) } - def will_save_change_to_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_ip?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_known_version?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_sdr_ip?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_sdr_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_last_sdr_tv_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_latitude?; end - - sig { returns(T::Boolean) } - def will_save_change_to_location_id?; end - - sig { returns(T::Boolean) } - def will_save_change_to_longitude?; end - - sig { returns(T::Boolean) } - def will_save_change_to_name?; end - - sig { returns(T::Boolean) } - def will_save_change_to_path?; end - - sig { returns(T::Boolean) } - def will_save_change_to_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_position?; end - - sig { returns(T::Boolean) } - def will_save_change_to_rcon?; end - - sig { returns(T::Boolean) } - def will_save_change_to_sdr?; end - - sig { returns(T::Boolean) } - def will_save_change_to_tv_port?; end - - sig { returns(T::Boolean) } - def will_save_change_to_type?; end - - sig { returns(T::Boolean) } - def will_save_change_to_update_started_at?; end - - sig { returns(T::Boolean) } - def will_save_change_to_update_status?; end - - sig { returns(T::Boolean) } - def will_save_change_to_updated_at?; end - end - - module GeneratedRelationMethods - sig { returns(PrivateRelation) } - def all; end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def and(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def annotate(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def create_with(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def eager_load(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def except(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def excluding(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extending(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def from(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def group(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def having(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def in_order_of(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def includes(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def invert_where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def left_outer_joins(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def limit(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def lock(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def merge(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def near(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def none(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def not_reverse_geocoded(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def offset(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def only(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def optimizer_hints(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def or(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def preload(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def readonly(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def references(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reorder(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reselect(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def reverse_order(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def rewhere(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def select(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def strict_loading(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def structurally_compatible?(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def uniq!(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def unscope(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } - def where(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def within_bounding_box(*args, &blk); end - - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def without(*args, &blk); end - end - - class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::SimraiServer } } - - sig { returns(T::Array[::SimraiServer]) } - def to_ary; end - end - - class PrivateAssociationRelationWhereChain < PrivateAssociationRelation - Elem = type_member { { fixed: ::SimraiServer } } - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateAssociationRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateAssociationRelation) } - def not(opts, *rest); end - end - - class PrivateCollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include CommonRelationMethods - include GeneratedAssociationRelationMethods - - Elem = type_member { { fixed: ::SimraiServer } } - - sig do - params( - records: T.any(::SimraiServer, T::Enumerable[T.any(::SimraiServer, T::Enumerable[::SimraiServer])]) - ).returns(PrivateCollectionProxy) - end - def <<(*records); end - - sig do - params( - records: T.any(::SimraiServer, T::Enumerable[T.any(::SimraiServer, T::Enumerable[::SimraiServer])]) - ).returns(PrivateCollectionProxy) - end - def append(*records); end - - sig { returns(PrivateCollectionProxy) } - def clear; end - - sig do - params( - records: T.any(::SimraiServer, T::Enumerable[T.any(::SimraiServer, T::Enumerable[::SimraiServer])]) - ).returns(PrivateCollectionProxy) - end - def concat(*records); end - - sig do - params( - records: T.any(::SimraiServer, Integer, String, T::Enumerable[T.any(::SimraiServer, Integer, String, T::Enumerable[::SimraiServer])]) - ).returns(T::Array[::SimraiServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::SimraiServer, Integer, String, T::Enumerable[T.any(::SimraiServer, Integer, String, T::Enumerable[::SimraiServer])]) - ).returns(T::Array[::SimraiServer]) - end - def destroy(*records); end - - sig { returns(T::Array[::SimraiServer]) } - def load_target; end - - sig do - params( - records: T.any(::SimraiServer, T::Enumerable[T.any(::SimraiServer, T::Enumerable[::SimraiServer])]) - ).returns(PrivateCollectionProxy) - end - def prepend(*records); end - - sig do - params( - records: T.any(::SimraiServer, T::Enumerable[T.any(::SimraiServer, T::Enumerable[::SimraiServer])]) - ).returns(PrivateCollectionProxy) - end - def push(*records); end - - sig do - params( - other_array: T.any(::SimraiServer, T::Enumerable[T.any(::SimraiServer, T::Enumerable[::SimraiServer])]) - ).returns(T::Array[::SimraiServer]) - end - def replace(other_array); end - - sig { returns(PrivateAssociationRelation) } - def scope; end - - sig { returns(T::Array[::SimraiServer]) } - def target; end - - sig { returns(T::Array[::SimraiServer]) } - def to_ary; end - end - - class PrivateRelation < ::ActiveRecord::Relation - include CommonRelationMethods - include GeneratedRelationMethods - - Elem = type_member { { fixed: ::SimraiServer } } - - sig { returns(T::Array[::SimraiServer]) } - def to_ary; end - end - - class PrivateRelationWhereChain < PrivateRelation - Elem = type_member { { fixed: ::SimraiServer } } - - sig { params(args: T.untyped).returns(PrivateRelation) } - def associated(*args); end - - sig { params(args: T.untyped).returns(PrivateRelation) } - def missing(*args); end - - sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateRelation) } - def not(opts, *rest); end - end -end diff --git a/sorbet/rbi/dsl/sprockets/rails/context.rbi b/sorbet/rbi/dsl/sprockets/rails/context.rbi index 35ea9a446..c1d739f55 100644 --- a/sorbet/rbi/dsl/sprockets/rails/context.rbi +++ b/sorbet/rbi/dsl/sprockets/rails/context.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Sprockets::Rails::Context`. # Please instead update this file by running `bin/tapioca dsl Sprockets::Rails::Context`. + module Sprockets::Rails::Context include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/sprockets/rails/helper.rbi b/sorbet/rbi/dsl/sprockets/rails/helper.rbi index ee7724a0c..347cd4e2d 100644 --- a/sorbet/rbi/dsl/sprockets/rails/helper.rbi +++ b/sorbet/rbi/dsl/sprockets/rails/helper.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Sprockets::Rails::Helper`. # Please instead update this file by running `bin/tapioca dsl Sprockets::Rails::Helper`. + module Sprockets::Rails::Helper include GeneratedInstanceMethods diff --git a/sorbet/rbi/dsl/ssh_server.rbi b/sorbet/rbi/dsl/ssh_server.rbi index aa9d11a58..38bc5f3db 100644 --- a/sorbet/rbi/dsl/ssh_server.rbi +++ b/sorbet/rbi/dsl/ssh_server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `SshServer`. # Please instead update this file by running `bin/tapioca dsl SshServer`. + class SshServer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class SshServer sig { params(block: T.nilable(T.proc.params(record: ::SshServer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::SshServer).void)).returns(::SshServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class SshServer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::SshServer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::SshServer).void)).returns(::SshServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class SshServer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::SshServer).void)).returns(::SshServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class SshServer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class SshServer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class SshServer sig { returns(::SshServer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::SshServer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::SshServer]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::SshServer).void).returns(T.nilable(::SshServer)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::SshServer)) } def find_by(*args); end @@ -89,6 +134,54 @@ class SshServer sig { params(args: T.untyped).returns(::SshServer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::SshServer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::SshServer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::SshServer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::SshServer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class SshServer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class SshServer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class SshServer sig { params(arg: T.untyped, args: T.untyped).returns(::SshServer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::SshServer)) } + sig { params(limit: Integer).returns(T::Array[::SshServer]) } def first(limit = nil); end sig { returns(::SshServer) } @@ -143,10 +249,36 @@ class SshServer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::SshServer)) } + sig { params(limit: Integer).returns(T::Array[::SshServer]) } def last(limit = nil); end sig { returns(::SshServer) } @@ -164,6 +296,13 @@ class SshServer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::SshServer).void)).returns(::SshServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::SshServer).void) + ).returns(T::Array[::SshServer]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class SshServer sig { returns(::SshServer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::SshServer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::SshServer)) } + sig { params(limit: Integer).returns(T::Array[::SshServer]) } def take(limit = nil); end sig { returns(::SshServer) } @@ -315,6 +457,9 @@ class SshServer sig { params(value: T::Enumerable[::Reservation]).void } def reservations=(value); end + sig { void } + def reset_location; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -343,8 +488,8 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -358,8 +503,8 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -367,7 +512,7 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -379,40 +524,6 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -446,6 +557,9 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -470,6 +584,9 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -497,27 +614,15 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -550,8 +655,8 @@ class SshServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -559,8 +664,8 @@ class SshServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -595,8 +700,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def billing_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_in_database; end @@ -604,8 +709,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_previous_change; end - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_previously_was; end @@ -640,8 +745,13 @@ class SshServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -649,8 +759,13 @@ class SshServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -685,8 +800,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_in_database; end @@ -694,8 +809,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_previous_change; end - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_previously_was; end @@ -730,8 +845,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_port_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_in_database; end @@ -739,8 +854,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_previous_change; end - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_previously_was; end @@ -775,8 +890,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_username_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_in_database; end @@ -784,8 +899,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_previous_change; end - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_previously_was; end @@ -796,7 +911,7 @@ class SshServer sig { void } def ftp_username_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -814,27 +929,72 @@ class SshServer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -865,8 +1025,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -874,8 +1034,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -910,8 +1070,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_known_version_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_in_database; end @@ -919,8 +1079,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_previous_change; end - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_previously_was; end @@ -955,8 +1115,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_in_database; end @@ -964,8 +1124,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_previously_was; end @@ -1000,8 +1160,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_in_database; end @@ -1009,8 +1169,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_previously_was; end @@ -1045,8 +1205,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_in_database; end @@ -1054,8 +1214,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_previously_was; end @@ -1090,8 +1250,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1099,8 +1259,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1135,8 +1295,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def location_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_in_database; end @@ -1144,8 +1304,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_previous_change; end - sig { returns(T::Boolean) } - def location_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_previously_was; end @@ -1180,8 +1340,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1189,8 +1349,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1225,8 +1385,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1234,8 +1394,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1270,8 +1430,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_change_to_be_saved; end - sig { returns(T::Boolean) } - def path_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_in_database; end @@ -1279,8 +1439,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_previous_change; end - sig { returns(T::Boolean) } - def path_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_previously_was; end @@ -1315,8 +1475,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_change_to_be_saved; end - sig { returns(T::Boolean) } - def port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_in_database; end @@ -1324,8 +1484,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_previous_change; end - sig { returns(T::Boolean) } - def port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_previously_was; end @@ -1360,8 +1520,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_change_to_be_saved; end - sig { returns(T::Boolean) } - def position_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_in_database; end @@ -1369,8 +1529,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_previous_change; end - sig { returns(T::Boolean) } - def position_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_previously_was; end @@ -1405,8 +1565,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1414,8 +1574,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1447,6 +1607,9 @@ class SshServer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -1540,12 +1703,18 @@ class SshServer sig { returns(T::Boolean) } def saved_change_to_ftp_username?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -1684,8 +1853,8 @@ class SshServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_in_database; end @@ -1693,8 +1862,8 @@ class SshServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_previous_change; end - sig { returns(T::Boolean) } - def sdr_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_previously_was; end @@ -1729,8 +1898,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_in_database; end @@ -1738,8 +1907,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_previous_change; end - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_previously_was; end @@ -1774,8 +1943,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -1783,8 +1952,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -1819,8 +1988,13 @@ class SshServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_in_database; end @@ -1828,8 +2002,13 @@ class SshServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_previous_change; end - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_previously_was; end @@ -1864,8 +2043,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_in_database; end @@ -1873,8 +2052,8 @@ class SshServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_previous_change; end - sig { returns(T::Boolean) } - def update_status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_previously_was; end @@ -1909,8 +2088,13 @@ class SshServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1918,8 +2102,13 @@ class SshServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1951,6 +2140,9 @@ class SshServer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -2022,8 +2214,8 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -2037,8 +2229,8 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -2046,7 +2238,7 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2091,6 +2283,9 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2115,6 +2310,9 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2145,6 +2343,12 @@ class SshServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2158,10 +2362,48 @@ class SshServer Elem = type_member { { fixed: ::SshServer } } + sig { returns(T::Array[::SshServer]) } + def to_a; end + sig { returns(T::Array[::SshServer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::SshServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::SshServer } } @@ -2205,20 +2447,6 @@ class SshServer end def concat(*records); end - sig do - params( - records: T.any(::SshServer, Integer, String, T::Enumerable[T.any(::SshServer, Integer, String, T::Enumerable[::SshServer])]) - ).returns(T::Array[::SshServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::SshServer, Integer, String, T::Enumerable[T.any(::SshServer, Integer, String, T::Enumerable[::SshServer])]) - ).returns(T::Array[::SshServer]) - end - def destroy(*records); end - sig { returns(T::Array[::SshServer]) } def load_target; end @@ -2249,6 +2477,9 @@ class SshServer sig { returns(T::Array[::SshServer]) } def target; end + sig { returns(T::Array[::SshServer]) } + def to_a; end + sig { returns(T::Array[::SshServer]) } def to_ary; end end @@ -2259,10 +2490,48 @@ class SshServer Elem = type_member { { fixed: ::SshServer } } + sig { returns(T::Array[::SshServer]) } + def to_a; end + sig { returns(T::Array[::SshServer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::SshServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::SshServer } } diff --git a/sorbet/rbi/dsl/stac_log.rbi b/sorbet/rbi/dsl/stac_log.rbi new file mode 100644 index 000000000..c34a94ac6 --- /dev/null +++ b/sorbet/rbi/dsl/stac_log.rbi @@ -0,0 +1,1281 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `StacLog`. +# Please instead update this file by running `bin/tapioca dsl StacLog`. + + +class StacLog + include GeneratedAssociationMethods + include GeneratedAttributeMethods + extend CommonRelationMethods + extend GeneratedRelationMethods + + private + + sig { returns(NilClass) } + def to_ary; end + + module CommonRelationMethods + sig { params(block: T.nilable(T.proc.params(record: ::StacLog).returns(T.untyped))).returns(T::Boolean) } + def any?(&block); end + + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } + def average(column_name); end + + sig { params(block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def build(attributes = nil, &block); end + + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } + def calculate(operation, column_name); end + + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::StacLog).void).returns(Integer) } + def count(column_name = nil, &block); end + + sig { params(block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def create(attributes = nil, &block); end + + sig { params(block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def create!(attributes = nil, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def create_or_find_by(attributes, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def create_or_find_by!(attributes, &block); end + + sig { returns(T::Array[::StacLog]) } + def destroy_all; end + + sig { params(conditions: T.untyped).returns(T::Boolean) } + def exists?(conditions = :none); end + + sig { returns(T.nilable(::StacLog)) } + def fifth; end + + sig { returns(::StacLog) } + def fifth!; end + + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::StacLog) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::StacLog]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::StacLog).void).returns(T.nilable(::StacLog)) } + def find(args = nil, &block); end + + sig { params(args: T.untyped).returns(T.nilable(::StacLog)) } + def find_by(*args); end + + sig { params(args: T.untyped).returns(::StacLog) } + def find_by!(*args); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::StacLog).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::StacLog]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::StacLog]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::StacLog]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def find_or_create_by(attributes, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def find_or_create_by!(attributes, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def find_or_initialize_by(attributes, &block); end + + sig { params(signed_id: T.untyped, purpose: T.untyped).returns(T.nilable(::StacLog)) } + def find_signed(signed_id, purpose: nil); end + + sig { params(signed_id: T.untyped, purpose: T.untyped).returns(::StacLog) } + def find_signed!(signed_id, purpose: nil); end + + sig { params(arg: T.untyped, args: T.untyped).returns(::StacLog) } + def find_sole_by(arg, *args); end + + sig { returns(T.nilable(::StacLog)) } + sig { params(limit: Integer).returns(T::Array[::StacLog]) } + def first(limit = nil); end + + sig { returns(::StacLog) } + def first!; end + + sig { returns(T.nilable(::StacLog)) } + def forty_two; end + + sig { returns(::StacLog) } + def forty_two!; end + + sig { returns(T.nilable(::StacLog)) } + def fourth; end + + sig { returns(::StacLog) } + def fourth!; end + + sig { returns(Array) } + def ids; end + + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + + sig { params(record: T.untyped).returns(T::Boolean) } + def include?(record); end + + sig { returns(T.nilable(::StacLog)) } + sig { params(limit: Integer).returns(T::Array[::StacLog]) } + def last(limit = nil); end + + sig { returns(::StacLog) } + def last!; end + + sig { params(block: T.nilable(T.proc.params(record: ::StacLog).returns(T.untyped))).returns(T::Boolean) } + def many?(&block); end + + sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + def maximum(column_name); end + + sig { params(record: T.untyped).returns(T::Boolean) } + def member?(record); end + + sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + def minimum(column_name); end + + sig { params(block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StacLog).void) + ).returns(T::Array[::StacLog]) + end + sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::StacLog).void)).returns(::StacLog) } + def new(attributes = nil, &block); end + + sig { params(block: T.nilable(T.proc.params(record: ::StacLog).returns(T.untyped))).returns(T::Boolean) } + def none?(&block); end + + sig { params(block: T.nilable(T.proc.params(record: ::StacLog).returns(T.untyped))).returns(T::Boolean) } + def one?(&block); end + + sig { params(column_names: T.untyped).returns(T.untyped) } + def pick(*column_names); end + + sig { params(column_names: T.untyped).returns(T.untyped) } + def pluck(*column_names); end + + sig { returns(T.nilable(::StacLog)) } + def second; end + + sig { returns(::StacLog) } + def second!; end + + sig { returns(T.nilable(::StacLog)) } + def second_to_last; end + + sig { returns(::StacLog) } + def second_to_last!; end + + sig { returns(::StacLog) } + def sole; end + + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } + sig do + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::StacLog).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) + end + def sum(initial_value_or_column = nil, &block); end + + sig { returns(T.nilable(::StacLog)) } + sig { params(limit: Integer).returns(T::Array[::StacLog]) } + def take(limit = nil); end + + sig { returns(::StacLog) } + def take!; end + + sig { returns(T.nilable(::StacLog)) } + def third; end + + sig { returns(::StacLog) } + def third!; end + + sig { returns(T.nilable(::StacLog)) } + def third_to_last; end + + sig { returns(::StacLog) } + def third_to_last!; end + end + + module GeneratedAssociationMethods + sig { params(args: T.untyped, blk: T.untyped).returns(::Reservation) } + def build_reservation(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(::Reservation) } + def create_reservation(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(::Reservation) } + def create_reservation!(*args, &blk); end + + sig { returns(T.nilable(::Reservation)) } + def reload_reservation; end + + sig { returns(T.nilable(::Reservation)) } + def reservation; end + + sig { params(value: T.nilable(::Reservation)).void } + def reservation=(value); end + + sig { returns(T::Boolean) } + def reservation_changed?; end + + sig { returns(T::Boolean) } + def reservation_previously_changed?; end + + sig { void } + def reset_reservation; end + end + + module GeneratedAssociationRelationMethods + sig { returns(PrivateAssociationRelation) } + def all; end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def and(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def annotate(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def create_with(*args, &blk); end + + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def eager_load(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def except(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def excluding(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def extending(*args, &blk); end + + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def from(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } + def group(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def having(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def in_order_of(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def includes(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def invert_where(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def joins(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def left_joins(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def left_outer_joins(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def limit(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def lock(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def merge(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def none(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def offset(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def only(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def optimizer_hints(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def or(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def order(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def preload(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def readonly(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def references(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def reorder(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def reselect(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def reverse_order(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def rewhere(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def select(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def strict_loading(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def structurally_compatible?(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def uniq!(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def unscope(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } + def where(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def without(*args, &blk); end + end + + module GeneratedAttributeMethods + sig { returns(T.untyped) } + def contents; end + + sig { params(value: T.untyped).returns(T.untyped) } + def contents=(value); end + + sig { returns(T::Boolean) } + def contents?; end + + sig { returns(T.untyped) } + def contents_before_last_save; end + + sig { returns(T.untyped) } + def contents_before_type_cast; end + + sig { returns(T::Boolean) } + def contents_came_from_user?; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def contents_change; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def contents_change_to_be_saved; end + + sig { params(from: T.untyped, to: T.untyped).returns(T::Boolean) } + def contents_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.untyped) } + def contents_in_database; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def contents_previous_change; end + + sig { params(from: T.untyped, to: T.untyped).returns(T::Boolean) } + def contents_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.untyped) } + def contents_previously_was; end + + sig { returns(T.untyped) } + def contents_was; end + + sig { void } + def contents_will_change!; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def created_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def created_at=(value); end + + sig { returns(T::Boolean) } + def created_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_before_last_save; end + + sig { returns(T.untyped) } + def created_at_before_type_cast; end + + sig { returns(T::Boolean) } + def created_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def created_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def created_at_was; end + + sig { void } + def created_at_will_change!; end + + sig { returns(T.nilable(::String)) } + def filename; end + + sig { params(value: T.nilable(::String)).returns(T.nilable(::String)) } + def filename=(value); end + + sig { returns(T::Boolean) } + def filename?; end + + sig { returns(T.nilable(::String)) } + def filename_before_last_save; end + + sig { returns(T.untyped) } + def filename_before_type_cast; end + + sig { returns(T::Boolean) } + def filename_came_from_user?; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def filename_change; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def filename_change_to_be_saved; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def filename_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def filename_in_database; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def filename_previous_change; end + + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def filename_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::String)) } + def filename_previously_was; end + + sig { returns(T.nilable(::String)) } + def filename_was; end + + sig { void } + def filename_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def filesize; end + + sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } + def filesize=(value); end + + sig { returns(T::Boolean) } + def filesize?; end + + sig { returns(T.nilable(::Integer)) } + def filesize_before_last_save; end + + sig { returns(T.untyped) } + def filesize_before_type_cast; end + + sig { returns(T::Boolean) } + def filesize_came_from_user?; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def filesize_change; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def filesize_change_to_be_saved; end + + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def filesize_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def filesize_in_database; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def filesize_previous_change; end + + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def filesize_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def filesize_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def filesize_was; end + + sig { void } + def filesize_will_change!; end + + sig { returns(::Integer) } + def id; end + + sig { params(value: ::Integer).returns(::Integer) } + def id=(value); end + + sig { returns(T::Boolean) } + def id?; end + + sig { returns(T.nilable(::Integer)) } + def id_before_last_save; end + + sig { returns(T.untyped) } + def id_before_type_cast; end + + sig { returns(T::Boolean) } + def id_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_previously_was; end + + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def id_was; end + + sig { void } + def id_will_change!; end + + sig { returns(T.nilable(::Integer)) } + def reservation_id; end + + sig { params(value: T.nilable(::Integer)).returns(T.nilable(::Integer)) } + def reservation_id=(value); end + + sig { returns(T::Boolean) } + def reservation_id?; end + + sig { returns(T.nilable(::Integer)) } + def reservation_id_before_last_save; end + + sig { returns(T.untyped) } + def reservation_id_before_type_cast; end + + sig { returns(T::Boolean) } + def reservation_id_came_from_user?; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def reservation_id_change; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def reservation_id_change_to_be_saved; end + + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def reservation_id_in_database; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def reservation_id_previous_change; end + + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def reservation_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def reservation_id_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def reservation_id_was; end + + sig { void } + def reservation_id_will_change!; end + + sig { void } + def restore_contents!; end + + sig { void } + def restore_created_at!; end + + sig { void } + def restore_filename!; end + + sig { void } + def restore_filesize!; end + + sig { void } + def restore_id!; end + + sig { void } + def restore_id_value!; end + + sig { void } + def restore_reservation_id!; end + + sig { void } + def restore_updated_at!; end + + sig { returns(T.nilable([T.untyped, T.untyped])) } + def saved_change_to_contents; end + + sig { returns(T::Boolean) } + def saved_change_to_contents?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_created_at; end + + sig { returns(T::Boolean) } + def saved_change_to_created_at?; end + + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } + def saved_change_to_filename; end + + sig { returns(T::Boolean) } + def saved_change_to_filename?; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def saved_change_to_filesize; end + + sig { returns(T::Boolean) } + def saved_change_to_filesize?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id; end + + sig { returns(T::Boolean) } + def saved_change_to_id?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + def saved_change_to_reservation_id; end + + sig { returns(T::Boolean) } + def saved_change_to_reservation_id?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def saved_change_to_updated_at; end + + sig { returns(T::Boolean) } + def saved_change_to_updated_at?; end + + sig { returns(::ActiveSupport::TimeWithZone) } + def updated_at; end + + sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } + def updated_at=(value); end + + sig { returns(T::Boolean) } + def updated_at?; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_before_last_save; end + + sig { returns(T.untyped) } + def updated_at_before_type_cast; end + + sig { returns(T::Boolean) } + def updated_at_came_from_user?; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_change; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_change_to_be_saved; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_in_database; end + + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } + def updated_at_previous_change; end + + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_previously_was; end + + sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + def updated_at_was; end + + sig { void } + def updated_at_will_change!; end + + sig { returns(T::Boolean) } + def will_save_change_to_contents?; end + + sig { returns(T::Boolean) } + def will_save_change_to_created_at?; end + + sig { returns(T::Boolean) } + def will_save_change_to_filename?; end + + sig { returns(T::Boolean) } + def will_save_change_to_filesize?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + + sig { returns(T::Boolean) } + def will_save_change_to_reservation_id?; end + + sig { returns(T::Boolean) } + def will_save_change_to_updated_at?; end + end + + module GeneratedRelationMethods + sig { returns(PrivateRelation) } + def all; end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def and(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def annotate(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def create_with(*args, &blk); end + + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def eager_load(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def except(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def excluding(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def extending(*args, &blk); end + + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def from(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } + def group(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def having(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def in_order_of(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def includes(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def invert_where(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def joins(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def left_joins(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def left_outer_joins(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def limit(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def lock(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def merge(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def none(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def offset(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def only(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def optimizer_hints(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def or(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def order(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def preload(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def readonly(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def references(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def reorder(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def reselect(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def reverse_order(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def rewhere(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def select(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def strict_loading(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def structurally_compatible?(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def uniq!(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def unscope(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } + def where(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def without(*args, &blk); end + end + + class PrivateAssociationRelation < ::ActiveRecord::AssociationRelation + include CommonRelationMethods + include GeneratedAssociationRelationMethods + + Elem = type_member { { fixed: ::StacLog } } + + sig { returns(T::Array[::StacLog]) } + def to_a; end + + sig { returns(T::Array[::StacLog]) } + def to_ary; end + end + + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::StacLog } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::StacLog } } + + sig { params(args: T.untyped).returns(PrivateAssociationRelation) } + def associated(*args); end + + sig { params(args: T.untyped).returns(PrivateAssociationRelation) } + def missing(*args); end + + sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateAssociationRelation) } + def not(opts, *rest); end + end + + class PrivateCollectionProxy < ::ActiveRecord::Associations::CollectionProxy + include CommonRelationMethods + include GeneratedAssociationRelationMethods + + Elem = type_member { { fixed: ::StacLog } } + + sig do + params( + records: T.any(::StacLog, T::Enumerable[T.any(::StacLog, T::Enumerable[::StacLog])]) + ).returns(PrivateCollectionProxy) + end + def <<(*records); end + + sig do + params( + records: T.any(::StacLog, T::Enumerable[T.any(::StacLog, T::Enumerable[::StacLog])]) + ).returns(PrivateCollectionProxy) + end + def append(*records); end + + sig { returns(PrivateCollectionProxy) } + def clear; end + + sig do + params( + records: T.any(::StacLog, T::Enumerable[T.any(::StacLog, T::Enumerable[::StacLog])]) + ).returns(PrivateCollectionProxy) + end + def concat(*records); end + + sig { returns(T::Array[::StacLog]) } + def load_target; end + + sig do + params( + records: T.any(::StacLog, T::Enumerable[T.any(::StacLog, T::Enumerable[::StacLog])]) + ).returns(PrivateCollectionProxy) + end + def prepend(*records); end + + sig do + params( + records: T.any(::StacLog, T::Enumerable[T.any(::StacLog, T::Enumerable[::StacLog])]) + ).returns(PrivateCollectionProxy) + end + def push(*records); end + + sig do + params( + other_array: T.any(::StacLog, T::Enumerable[T.any(::StacLog, T::Enumerable[::StacLog])]) + ).returns(T::Array[::StacLog]) + end + def replace(other_array); end + + sig { returns(PrivateAssociationRelation) } + def scope; end + + sig { returns(T::Array[::StacLog]) } + def target; end + + sig { returns(T::Array[::StacLog]) } + def to_a; end + + sig { returns(T::Array[::StacLog]) } + def to_ary; end + end + + class PrivateRelation < ::ActiveRecord::Relation + include CommonRelationMethods + include GeneratedRelationMethods + + Elem = type_member { { fixed: ::StacLog } } + + sig { returns(T::Array[::StacLog]) } + def to_a; end + + sig { returns(T::Array[::StacLog]) } + def to_ary; end + end + + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::StacLog } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + + class PrivateRelationWhereChain < PrivateRelation + Elem = type_member { { fixed: ::StacLog } } + + sig { params(args: T.untyped).returns(PrivateRelation) } + def associated(*args); end + + sig { params(args: T.untyped).returns(PrivateRelation) } + def missing(*args); end + + sig { params(opts: T.untyped, rest: T.untyped).returns(PrivateRelation) } + def not(opts, *rest); end + end +end diff --git a/sorbet/rbi/dsl/stac_logs_downloader_worker.rbi b/sorbet/rbi/dsl/stac_logs_downloader_worker.rbi new file mode 100644 index 000000000..e3d18df6d --- /dev/null +++ b/sorbet/rbi/dsl/stac_logs_downloader_worker.rbi @@ -0,0 +1,19 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `StacLogsDownloaderWorker`. +# Please instead update this file by running `bin/tapioca dsl StacLogsDownloaderWorker`. + + +class StacLogsDownloaderWorker + class << self + sig { params(reservation_id: T.untyped).returns(String) } + def perform_async(reservation_id); end + + sig { params(interval: T.any(DateTime, Time), reservation_id: T.untyped).returns(String) } + def perform_at(interval, reservation_id); end + + sig { params(interval: Numeric, reservation_id: T.untyped).returns(String) } + def perform_in(interval, reservation_id); end + end +end diff --git a/sorbet/rbi/dsl/stripe_order.rbi b/sorbet/rbi/dsl/stripe_order.rbi index 82a96842d..8a09fdfe2 100644 --- a/sorbet/rbi/dsl/stripe_order.rbi +++ b/sorbet/rbi/dsl/stripe_order.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `StripeOrder`. # Please instead update this file by running `bin/tapioca dsl StripeOrder`. + class StripeOrder include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class StripeOrder sig { params(block: T.nilable(T.proc.params(record: ::StripeOrder).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::StripeOrder).void)).returns(::StripeOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class StripeOrder end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::StripeOrder).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::StripeOrder).void)).returns(::StripeOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class StripeOrder end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::StripeOrder).void)).returns(::StripeOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class StripeOrder end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class StripeOrder end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class StripeOrder sig { returns(::StripeOrder) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::StripeOrder) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::StripeOrder]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::StripeOrder).void).returns(T.nilable(::StripeOrder)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::StripeOrder)) } def find_by(*args); end @@ -89,6 +134,54 @@ class StripeOrder sig { params(args: T.untyped).returns(::StripeOrder) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::StripeOrder).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::StripeOrder]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::StripeOrder]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::StripeOrder]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class StripeOrder end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class StripeOrder end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class StripeOrder sig { params(arg: T.untyped, args: T.untyped).returns(::StripeOrder) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::StripeOrder)) } + sig { params(limit: Integer).returns(T::Array[::StripeOrder]) } def first(limit = nil); end sig { returns(::StripeOrder) } @@ -143,10 +249,36 @@ class StripeOrder sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::StripeOrder)) } + sig { params(limit: Integer).returns(T::Array[::StripeOrder]) } def last(limit = nil); end sig { returns(::StripeOrder) } @@ -164,6 +296,13 @@ class StripeOrder sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::StripeOrder).void)).returns(::StripeOrder) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::StripeOrder).void) + ).returns(T::Array[::StripeOrder]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class StripeOrder sig { returns(::StripeOrder) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::StripeOrder).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::StripeOrder)) } + sig { params(limit: Integer).returns(T::Array[::StripeOrder]) } def take(limit = nil); end sig { returns(::StripeOrder) } @@ -269,6 +411,15 @@ class StripeOrder sig { returns(T.nilable(::Voucher)) } def reload_voucher; end + sig { void } + def reset_product; end + + sig { void } + def reset_user; end + + sig { void } + def reset_voucher; end + sig { returns(T.nilable(::User)) } def user; end @@ -295,8 +446,8 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -310,13 +461,13 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -328,40 +479,6 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -386,6 +503,9 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -410,6 +530,9 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -437,27 +560,15 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -487,8 +598,13 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -496,8 +612,13 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -532,8 +653,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def gift_change_to_be_saved; end - sig { returns(T::Boolean) } - def gift_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def gift_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def gift_in_database; end @@ -541,8 +662,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def gift_previous_change; end - sig { returns(T::Boolean) } - def gift_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def gift_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def gift_previously_was; end @@ -553,7 +674,7 @@ class StripeOrder sig { void } def gift_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -571,27 +692,72 @@ class StripeOrder sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -622,8 +788,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payer_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def payer_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payer_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payer_id_in_database; end @@ -631,8 +797,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payer_id_previous_change; end - sig { returns(T::Boolean) } - def payer_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payer_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payer_id_previously_was; end @@ -667,8 +833,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payment_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def payment_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payment_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payment_id_in_database; end @@ -676,8 +842,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def payment_id_previous_change; end - sig { returns(T::Boolean) } - def payment_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def payment_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def payment_id_previously_was; end @@ -712,8 +878,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def product_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_in_database; end @@ -721,8 +887,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_previous_change; end - sig { returns(T::Boolean) } - def product_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_previously_was; end @@ -742,6 +908,9 @@ class StripeOrder sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_payer_id!; end @@ -775,12 +944,18 @@ class StripeOrder sig { returns(T::Boolean) } def saved_change_to_gift?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_payer_id; end @@ -847,8 +1022,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_change_to_be_saved; end - sig { returns(T::Boolean) } - def status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_in_database; end @@ -856,8 +1031,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def status_previous_change; end - sig { returns(T::Boolean) } - def status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def status_previously_was; end @@ -892,8 +1067,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -901,8 +1076,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -937,8 +1112,13 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -946,8 +1126,13 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -982,8 +1167,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def user_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_in_database; end @@ -991,8 +1176,8 @@ class StripeOrder sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def user_id_previous_change; end - sig { returns(T::Boolean) } - def user_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def user_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def user_id_previously_was; end @@ -1012,6 +1197,9 @@ class StripeOrder sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_payer_id?; end @@ -1047,8 +1235,8 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -1062,13 +1250,13 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -1104,6 +1292,9 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -1128,6 +1319,9 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1158,6 +1352,12 @@ class StripeOrder sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -1168,10 +1368,48 @@ class StripeOrder Elem = type_member { { fixed: ::StripeOrder } } + sig { returns(T::Array[::StripeOrder]) } + def to_a; end + sig { returns(T::Array[::StripeOrder]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::StripeOrder } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::StripeOrder } } @@ -1215,20 +1453,6 @@ class StripeOrder end def concat(*records); end - sig do - params( - records: T.any(::StripeOrder, Integer, String, T::Enumerable[T.any(::StripeOrder, Integer, String, T::Enumerable[::StripeOrder])]) - ).returns(T::Array[::StripeOrder]) - end - def delete(*records); end - - sig do - params( - records: T.any(::StripeOrder, Integer, String, T::Enumerable[T.any(::StripeOrder, Integer, String, T::Enumerable[::StripeOrder])]) - ).returns(T::Array[::StripeOrder]) - end - def destroy(*records); end - sig { returns(T::Array[::StripeOrder]) } def load_target; end @@ -1259,6 +1483,9 @@ class StripeOrder sig { returns(T::Array[::StripeOrder]) } def target; end + sig { returns(T::Array[::StripeOrder]) } + def to_a; end + sig { returns(T::Array[::StripeOrder]) } def to_ary; end end @@ -1269,10 +1496,48 @@ class StripeOrder Elem = type_member { { fixed: ::StripeOrder } } + sig { returns(T::Array[::StripeOrder]) } + def to_a; end + sig { returns(T::Array[::StripeOrder]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::StripeOrder } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::StripeOrder } } diff --git a/sorbet/rbi/dsl/time.rbi b/sorbet/rbi/dsl/time.rbi new file mode 100644 index 000000000..8b24b5752 --- /dev/null +++ b/sorbet/rbi/dsl/time.rbi @@ -0,0 +1,13 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `Time`. +# Please instead update this file by running `bin/tapioca dsl Time`. + + +class Time + class << self + sig { returns(::ActiveSupport::TimeWithZone) } + def current; end + end +end diff --git a/sorbet/rbi/dsl/tragic_server.rbi b/sorbet/rbi/dsl/tragic_server.rbi index 53aa3ebae..510e0af49 100644 --- a/sorbet/rbi/dsl/tragic_server.rbi +++ b/sorbet/rbi/dsl/tragic_server.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `TragicServer`. # Please instead update this file by running `bin/tapioca dsl TragicServer`. + class TragicServer include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class TragicServer sig { params(block: T.nilable(T.proc.params(record: ::TragicServer).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::TragicServer).void)).returns(::TragicServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class TragicServer end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::TragicServer).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::TragicServer).void)).returns(::TragicServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class TragicServer end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::TragicServer).void)).returns(::TragicServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class TragicServer end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class TragicServer end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,23 @@ class TragicServer sig { returns(::TragicServer) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::TragicServer) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::TragicServer]) + end + sig do + params( + args: NilClass, + block: T.proc.params(object: ::TragicServer).void + ).returns(T.nilable(::TragicServer)) + end + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::TragicServer)) } def find_by(*args); end @@ -89,6 +139,54 @@ class TragicServer sig { params(args: T.untyped).returns(::TragicServer) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::TragicServer).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::TragicServer]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::TragicServer]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::TragicServer]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -97,6 +195,12 @@ class TragicServer end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -105,6 +209,12 @@ class TragicServer end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -122,7 +232,8 @@ class TragicServer sig { params(arg: T.untyped, args: T.untyped).returns(::TragicServer) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::TragicServer)) } + sig { params(limit: Integer).returns(T::Array[::TragicServer]) } def first(limit = nil); end sig { returns(::TragicServer) } @@ -143,10 +254,36 @@ class TragicServer sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::TragicServer)) } + sig { params(limit: Integer).returns(T::Array[::TragicServer]) } def last(limit = nil); end sig { returns(::TragicServer) } @@ -164,6 +301,13 @@ class TragicServer sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::TragicServer).void)).returns(::TragicServer) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::TragicServer).void) + ).returns(T::Array[::TragicServer]) + end sig do params( attributes: T.untyped, @@ -199,15 +343,18 @@ class TragicServer sig { returns(::TragicServer) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::TragicServer).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::TragicServer)) } + sig { params(limit: Integer).returns(T::Array[::TragicServer]) } def take(limit = nil); end sig { returns(::TragicServer) } @@ -315,6 +462,9 @@ class TragicServer sig { params(value: T::Enumerable[::Reservation]).void } def reservations=(value); end + sig { void } + def reset_location; end + sig { returns(T::Array[T.untyped]) } def server_statistic_ids; end @@ -343,8 +493,8 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -358,8 +508,8 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -367,7 +517,7 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -379,40 +529,6 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -446,6 +562,9 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -470,6 +589,9 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -497,27 +619,15 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -550,8 +660,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_change_to_be_saved; end - sig { returns(T::Boolean) } - def active_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_in_database; end @@ -559,8 +669,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def active_previous_change; end - sig { returns(T::Boolean) } - def active_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def active_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def active_previously_was; end @@ -595,8 +705,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def billing_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_in_database; end @@ -604,8 +714,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def billing_id_previous_change; end - sig { returns(T::Boolean) } - def billing_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def billing_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def billing_id_previously_was; end @@ -640,8 +750,13 @@ class TragicServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -649,8 +764,13 @@ class TragicServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -685,8 +805,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_password_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_in_database; end @@ -694,8 +814,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_password_previous_change; end - sig { returns(T::Boolean) } - def ftp_password_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_password_previously_was; end @@ -730,8 +850,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_port_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_in_database; end @@ -739,8 +859,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def ftp_port_previous_change; end - sig { returns(T::Boolean) } - def ftp_port_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def ftp_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def ftp_port_previously_was; end @@ -775,8 +895,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_change_to_be_saved; end - sig { returns(T::Boolean) } - def ftp_username_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_in_database; end @@ -784,8 +904,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ftp_username_previous_change; end - sig { returns(T::Boolean) } - def ftp_username_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ftp_username_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ftp_username_previously_was; end @@ -796,7 +916,7 @@ class TragicServer sig { void } def ftp_username_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -814,27 +934,72 @@ class TragicServer sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -865,8 +1030,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_in_database; end @@ -874,8 +1039,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def ip_previous_change; end - sig { returns(T::Boolean) } - def ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def ip_previously_was; end @@ -910,8 +1075,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_known_version_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_in_database; end @@ -919,8 +1084,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def last_known_version_previous_change; end - sig { returns(T::Boolean) } - def last_known_version_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def last_known_version_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def last_known_version_previously_was; end @@ -955,8 +1120,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_in_database; end @@ -964,8 +1129,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_ip_previously_was; end @@ -1000,8 +1165,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_in_database; end @@ -1009,8 +1174,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_port_previously_was; end @@ -1045,8 +1210,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_in_database; end @@ -1054,8 +1219,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sdr_tv_port_previous_change; end - sig { returns(T::Boolean) } - def last_sdr_tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sdr_tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sdr_tv_port_previously_was; end @@ -1090,8 +1255,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1099,8 +1264,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1135,8 +1300,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def location_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_in_database; end @@ -1144,8 +1309,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def location_id_previous_change; end - sig { returns(T::Boolean) } - def location_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def location_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def location_id_previously_was; end @@ -1180,8 +1345,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1189,8 +1354,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1225,8 +1390,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1234,8 +1399,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1270,8 +1435,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_change_to_be_saved; end - sig { returns(T::Boolean) } - def path_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_in_database; end @@ -1279,8 +1444,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def path_previous_change; end - sig { returns(T::Boolean) } - def path_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def path_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def path_previously_was; end @@ -1315,8 +1480,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_change_to_be_saved; end - sig { returns(T::Boolean) } - def port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_in_database; end @@ -1324,8 +1489,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def port_previous_change; end - sig { returns(T::Boolean) } - def port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def port_previously_was; end @@ -1360,8 +1525,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_change_to_be_saved; end - sig { returns(T::Boolean) } - def position_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_in_database; end @@ -1369,8 +1534,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def position_previous_change; end - sig { returns(T::Boolean) } - def position_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def position_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def position_previously_was; end @@ -1405,8 +1570,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_change_to_be_saved; end - sig { returns(T::Boolean) } - def rcon_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_in_database; end @@ -1414,8 +1579,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def rcon_previous_change; end - sig { returns(T::Boolean) } - def rcon_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def rcon_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def rcon_previously_was; end @@ -1447,6 +1612,9 @@ class TragicServer sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_ip!; end @@ -1540,12 +1708,18 @@ class TragicServer sig { returns(T::Boolean) } def saved_change_to_ftp_username?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_ip; end @@ -1684,8 +1858,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_change_to_be_saved; end - sig { returns(T::Boolean) } - def sdr_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_in_database; end @@ -1693,8 +1867,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } def sdr_previous_change; end - sig { returns(T::Boolean) } - def sdr_previously_changed?; end + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def sdr_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(T::Boolean)) } def sdr_previously_was; end @@ -1729,8 +1903,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_change_to_be_saved; end - sig { returns(T::Boolean) } - def tv_port_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_in_database; end @@ -1738,8 +1912,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tv_port_previous_change; end - sig { returns(T::Boolean) } - def tv_port_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tv_port_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tv_port_previously_was; end @@ -1774,8 +1948,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_change_to_be_saved; end - sig { returns(T::Boolean) } - def type_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_in_database; end @@ -1783,8 +1957,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def type_previous_change; end - sig { returns(T::Boolean) } - def type_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def type_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def type_previously_was; end @@ -1819,8 +1993,13 @@ class TragicServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_started_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_in_database; end @@ -1828,8 +2007,13 @@ class TragicServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def update_started_at_previous_change; end - sig { returns(T::Boolean) } - def update_started_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def update_started_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def update_started_at_previously_was; end @@ -1864,8 +2048,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_change_to_be_saved; end - sig { returns(T::Boolean) } - def update_status_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_in_database; end @@ -1873,8 +2057,8 @@ class TragicServer sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def update_status_previous_change; end - sig { returns(T::Boolean) } - def update_status_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def update_status_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def update_status_previously_was; end @@ -1909,8 +2093,13 @@ class TragicServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1918,8 +2107,13 @@ class TragicServer sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1951,6 +2145,9 @@ class TragicServer sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_ip?; end @@ -2022,8 +2219,8 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -2037,8 +2234,8 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -2046,7 +2243,7 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2091,6 +2288,9 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2115,6 +2315,9 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2145,6 +2348,12 @@ class TragicServer sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2158,10 +2367,48 @@ class TragicServer Elem = type_member { { fixed: ::TragicServer } } + sig { returns(T::Array[::TragicServer]) } + def to_a; end + sig { returns(T::Array[::TragicServer]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::TragicServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::TragicServer } } @@ -2205,20 +2452,6 @@ class TragicServer end def concat(*records); end - sig do - params( - records: T.any(::TragicServer, Integer, String, T::Enumerable[T.any(::TragicServer, Integer, String, T::Enumerable[::TragicServer])]) - ).returns(T::Array[::TragicServer]) - end - def delete(*records); end - - sig do - params( - records: T.any(::TragicServer, Integer, String, T::Enumerable[T.any(::TragicServer, Integer, String, T::Enumerable[::TragicServer])]) - ).returns(T::Array[::TragicServer]) - end - def destroy(*records); end - sig { returns(T::Array[::TragicServer]) } def load_target; end @@ -2249,6 +2482,9 @@ class TragicServer sig { returns(T::Array[::TragicServer]) } def target; end + sig { returns(T::Array[::TragicServer]) } + def to_a; end + sig { returns(T::Array[::TragicServer]) } def to_ary; end end @@ -2259,10 +2495,48 @@ class TragicServer Elem = type_member { { fixed: ::TragicServer } } + sig { returns(T::Array[::TragicServer]) } + def to_a; end + sig { returns(T::Array[::TragicServer]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::TragicServer } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::TragicServer } } diff --git a/sorbet/rbi/dsl/turbo/native/navigation_controller.rbi b/sorbet/rbi/dsl/turbo/native/navigation_controller.rbi deleted file mode 100644 index 7e8cbda19..000000000 --- a/sorbet/rbi/dsl/turbo/native/navigation_controller.rbi +++ /dev/null @@ -1,18 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `Turbo::Native::NavigationController`. -# Please instead update this file by running `bin/tapioca dsl Turbo::Native::NavigationController`. - -class Turbo::Native::NavigationController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::ActionController::Base::HelperMethods - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/turbo/streams/action_broadcast_job.rbi b/sorbet/rbi/dsl/turbo/streams/action_broadcast_job.rbi index 1d4901cfc..e19717655 100644 --- a/sorbet/rbi/dsl/turbo/streams/action_broadcast_job.rbi +++ b/sorbet/rbi/dsl/turbo/streams/action_broadcast_job.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Turbo::Streams::ActionBroadcastJob`. # Please instead update this file by running `bin/tapioca dsl Turbo::Streams::ActionBroadcastJob`. + class Turbo::Streams::ActionBroadcastJob class << self sig do @@ -11,12 +12,22 @@ class Turbo::Streams::ActionBroadcastJob stream: T.untyped, action: T.untyped, target: T.untyped, - rendering: T.untyped + attributes: T.untyped, + rendering: T.untyped, + block: T.nilable(T.proc.params(job: Turbo::Streams::ActionBroadcastJob).void) ).returns(T.any(Turbo::Streams::ActionBroadcastJob, FalseClass)) end - def perform_later(stream, action:, target:, **rendering); end + def perform_later(stream, action:, target:, attributes: T.unsafe(nil), **rendering, &block); end - sig { params(stream: T.untyped, action: T.untyped, target: T.untyped, rendering: T.untyped).returns(T.untyped) } - def perform_now(stream, action:, target:, **rendering); end + sig do + params( + stream: T.untyped, + action: T.untyped, + target: T.untyped, + attributes: T.untyped, + rendering: T.untyped + ).returns(T.untyped) + end + def perform_now(stream, action:, target:, attributes: T.unsafe(nil), **rendering); end end end diff --git a/sorbet/rbi/dsl/turbo/streams/broadcast_job.rbi b/sorbet/rbi/dsl/turbo/streams/broadcast_job.rbi index 75809447b..bdda7f649 100644 --- a/sorbet/rbi/dsl/turbo/streams/broadcast_job.rbi +++ b/sorbet/rbi/dsl/turbo/streams/broadcast_job.rbi @@ -4,10 +4,17 @@ # This is an autogenerated file for dynamic methods in `Turbo::Streams::BroadcastJob`. # Please instead update this file by running `bin/tapioca dsl Turbo::Streams::BroadcastJob`. + class Turbo::Streams::BroadcastJob class << self - sig { params(stream: T.untyped, rendering: T.untyped).returns(T.any(Turbo::Streams::BroadcastJob, FalseClass)) } - def perform_later(stream, **rendering); end + sig do + params( + stream: T.untyped, + rendering: T.untyped, + block: T.nilable(T.proc.params(job: Turbo::Streams::BroadcastJob).void) + ).returns(T.any(Turbo::Streams::BroadcastJob, FalseClass)) + end + def perform_later(stream, **rendering, &block); end sig { params(stream: T.untyped, rendering: T.untyped).returns(T.untyped) } def perform_now(stream, **rendering); end diff --git a/sorbet/rbi/dsl/turbo/streams/broadcast_stream_job.rbi b/sorbet/rbi/dsl/turbo/streams/broadcast_stream_job.rbi new file mode 100644 index 000000000..4a21674bc --- /dev/null +++ b/sorbet/rbi/dsl/turbo/streams/broadcast_stream_job.rbi @@ -0,0 +1,22 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for dynamic methods in `Turbo::Streams::BroadcastStreamJob`. +# Please instead update this file by running `bin/tapioca dsl Turbo::Streams::BroadcastStreamJob`. + + +class Turbo::Streams::BroadcastStreamJob + class << self + sig do + params( + stream: T.untyped, + content: T.untyped, + block: T.nilable(T.proc.params(job: Turbo::Streams::BroadcastStreamJob).void) + ).returns(T.any(Turbo::Streams::BroadcastStreamJob, FalseClass)) + end + def perform_later(stream, content:, &block); end + + sig { params(stream: T.untyped, content: T.untyped).returns(T.untyped) } + def perform_now(stream, content:); end + end +end diff --git a/sorbet/rbi/dsl/update_server_page_worker.rbi b/sorbet/rbi/dsl/update_server_page_worker.rbi index 0b22eb94e..3e7fb54cf 100644 --- a/sorbet/rbi/dsl/update_server_page_worker.rbi +++ b/sorbet/rbi/dsl/update_server_page_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `UpdateServerPageWorker`. # Please instead update this file by running `bin/tapioca dsl UpdateServerPageWorker`. + class UpdateServerPageWorker class << self sig { returns(String) } diff --git a/sorbet/rbi/dsl/update_steam_nickname_worker.rbi b/sorbet/rbi/dsl/update_steam_nickname_worker.rbi index 30bbccb8e..8c7337e63 100644 --- a/sorbet/rbi/dsl/update_steam_nickname_worker.rbi +++ b/sorbet/rbi/dsl/update_steam_nickname_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `UpdateSteamNicknameWorker`. # Please instead update this file by running `bin/tapioca dsl UpdateSteamNicknameWorker`. + class UpdateSteamNicknameWorker class << self sig { params(steam_uid: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/upload_files_to_server_worker.rbi b/sorbet/rbi/dsl/upload_files_to_server_worker.rbi index b56f7f3cd..26ee8a338 100644 --- a/sorbet/rbi/dsl/upload_files_to_server_worker.rbi +++ b/sorbet/rbi/dsl/upload_files_to_server_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `UploadFilesToServerWorker`. # Please instead update this file by running `bin/tapioca dsl UploadFilesToServerWorker`. + class UploadFilesToServerWorker class << self sig { params(options: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/upload_files_to_servers_worker.rbi b/sorbet/rbi/dsl/upload_files_to_servers_worker.rbi index c44bb1ece..b96002f8e 100644 --- a/sorbet/rbi/dsl/upload_files_to_servers_worker.rbi +++ b/sorbet/rbi/dsl/upload_files_to_servers_worker.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `UploadFilesToServersWorker`. # Please instead update this file by running `bin/tapioca dsl UploadFilesToServersWorker`. + class UploadFilesToServersWorker class << self sig { params(options: T.untyped).returns(String) } diff --git a/sorbet/rbi/dsl/user.rbi b/sorbet/rbi/dsl/user.rbi index 9d92c311c..ff0cde20c 100644 --- a/sorbet/rbi/dsl/user.rbi +++ b/sorbet/rbi/dsl/user.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `User`. # Please instead update this file by running `bin/tapioca dsl User`. + class User include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,27 +20,61 @@ class User sig { params(block: T.nilable(T.proc.params(record: ::User).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::User).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def create_or_find_by!(attributes, &block); end @@ -55,8 +90,18 @@ class User sig { returns(::User) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::User) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::User]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::User).void).returns(T.nilable(::User)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::User)) } def find_by(*args); end @@ -64,12 +109,72 @@ class User sig { params(args: T.untyped).returns(::User) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::User).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::User]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::User]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::User]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def find_or_initialize_by(attributes, &block); end @@ -82,7 +187,8 @@ class User sig { params(arg: T.untyped, args: T.untyped).returns(::User) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::User)) } + sig { params(limit: Integer).returns(T::Array[::User]) } def first(limit = nil); end sig { returns(::User) } @@ -103,10 +209,36 @@ class User sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::User)) } + sig { params(limit: Integer).returns(T::Array[::User]) } def last(limit = nil); end sig { returns(::User) } @@ -124,6 +256,13 @@ class User sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::User).void) + ).returns(T::Array[::User]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::User).void)).returns(::User) } def new(attributes = nil, &block); end @@ -154,15 +293,18 @@ class User sig { returns(::User) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::User).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::User)) } + sig { params(limit: Integer).returns(T::Array[::User]) } def take(limit = nil); end sig { returns(::User) } @@ -350,8 +492,8 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -365,8 +507,8 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end @@ -374,7 +516,7 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -386,40 +528,6 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -453,6 +561,9 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -477,6 +588,9 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -504,27 +618,15 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def within_bounding_box(*args, &blk); end @@ -557,8 +659,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def api_key_change_to_be_saved; end - sig { returns(T::Boolean) } - def api_key_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def api_key_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def api_key_in_database; end @@ -566,8 +668,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def api_key_previous_change; end - sig { returns(T::Boolean) } - def api_key_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def api_key_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def api_key_previously_was; end @@ -602,8 +704,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -611,8 +718,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -647,8 +759,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def current_sign_in_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def current_sign_in_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def current_sign_in_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def current_sign_in_at_in_database; end @@ -656,8 +773,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def current_sign_in_at_previous_change; end - sig { returns(T::Boolean) } - def current_sign_in_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def current_sign_in_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def current_sign_in_at_previously_was; end @@ -692,8 +814,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def current_sign_in_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def current_sign_in_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def current_sign_in_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def current_sign_in_ip_in_database; end @@ -701,8 +823,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def current_sign_in_ip_previous_change; end - sig { returns(T::Boolean) } - def current_sign_in_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def current_sign_in_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def current_sign_in_ip_previously_was; end @@ -737,8 +859,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def demos_tf_api_key_change_to_be_saved; end - sig { returns(T::Boolean) } - def demos_tf_api_key_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def demos_tf_api_key_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def demos_tf_api_key_in_database; end @@ -746,8 +868,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def demos_tf_api_key_previous_change; end - sig { returns(T::Boolean) } - def demos_tf_api_key_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def demos_tf_api_key_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def demos_tf_api_key_previously_was; end @@ -782,8 +904,8 @@ class User sig { returns(T.nilable([::String, ::String])) } def email_change_to_be_saved; end - sig { returns(T::Boolean) } - def email_changed?; end + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def email_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def email_in_database; end @@ -791,8 +913,8 @@ class User sig { returns(T.nilable([::String, ::String])) } def email_previous_change; end - sig { returns(T::Boolean) } - def email_previously_changed?; end + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def email_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def email_previously_was; end @@ -827,8 +949,8 @@ class User sig { returns(T.nilable([::String, ::String])) } def encrypted_password_change_to_be_saved; end - sig { returns(T::Boolean) } - def encrypted_password_changed?; end + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def encrypted_password_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def encrypted_password_in_database; end @@ -836,8 +958,8 @@ class User sig { returns(T.nilable([::String, ::String])) } def encrypted_password_previous_change; end - sig { returns(T::Boolean) } - def encrypted_password_previously_changed?; end + sig { params(from: ::String, to: ::String).returns(T::Boolean) } + def encrypted_password_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def encrypted_password_previously_was; end @@ -872,8 +994,8 @@ class User sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def expired_reservations_change_to_be_saved; end - sig { returns(T::Boolean) } - def expired_reservations_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def expired_reservations_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def expired_reservations_in_database; end @@ -881,8 +1003,8 @@ class User sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def expired_reservations_previous_change; end - sig { returns(T::Boolean) } - def expired_reservations_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def expired_reservations_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def expired_reservations_previously_was; end @@ -893,7 +1015,7 @@ class User sig { void } def expired_reservations_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -911,27 +1033,72 @@ class User sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -962,8 +1129,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def last_sign_in_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sign_in_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def last_sign_in_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def last_sign_in_at_in_database; end @@ -971,8 +1143,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def last_sign_in_at_previous_change; end - sig { returns(T::Boolean) } - def last_sign_in_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def last_sign_in_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def last_sign_in_at_previously_was; end @@ -1007,8 +1184,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sign_in_ip_change_to_be_saved; end - sig { returns(T::Boolean) } - def last_sign_in_ip_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sign_in_ip_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sign_in_ip_in_database; end @@ -1016,8 +1193,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def last_sign_in_ip_previous_change; end - sig { returns(T::Boolean) } - def last_sign_in_ip_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def last_sign_in_ip_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def last_sign_in_ip_previously_was; end @@ -1052,8 +1229,8 @@ class User sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def latitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_in_database; end @@ -1061,8 +1238,8 @@ class User sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def latitude_previous_change; end - sig { returns(T::Boolean) } - def latitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def latitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def latitude_previously_was; end @@ -1097,8 +1274,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def logs_tf_api_key_change_to_be_saved; end - sig { returns(T::Boolean) } - def logs_tf_api_key_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def logs_tf_api_key_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def logs_tf_api_key_in_database; end @@ -1106,8 +1283,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def logs_tf_api_key_previous_change; end - sig { returns(T::Boolean) } - def logs_tf_api_key_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def logs_tf_api_key_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def logs_tf_api_key_previously_was; end @@ -1142,8 +1319,8 @@ class User sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_change_to_be_saved; end - sig { returns(T::Boolean) } - def longitude_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_in_database; end @@ -1151,8 +1328,8 @@ class User sig { returns(T.nilable([T.nilable(::Float), T.nilable(::Float)])) } def longitude_previous_change; end - sig { returns(T::Boolean) } - def longitude_previously_changed?; end + sig { params(from: T.nilable(::Float), to: T.nilable(::Float)).returns(T::Boolean) } + def longitude_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Float)) } def longitude_previously_was; end @@ -1187,8 +1364,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_change_to_be_saved; end - sig { returns(T::Boolean) } - def name_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_in_database; end @@ -1196,8 +1373,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def name_previous_change; end - sig { returns(T::Boolean) } - def name_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def name_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def name_previously_was; end @@ -1232,8 +1409,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def nickname_change_to_be_saved; end - sig { returns(T::Boolean) } - def nickname_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def nickname_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def nickname_in_database; end @@ -1241,8 +1418,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def nickname_previous_change; end - sig { returns(T::Boolean) } - def nickname_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def nickname_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def nickname_previously_was; end @@ -1277,8 +1454,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def provider_change_to_be_saved; end - sig { returns(T::Boolean) } - def provider_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def provider_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def provider_in_database; end @@ -1286,8 +1463,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def provider_previous_change; end - sig { returns(T::Boolean) } - def provider_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def provider_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def provider_previously_was; end @@ -1322,8 +1499,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def remember_created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def remember_created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def remember_created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def remember_created_at_in_database; end @@ -1331,8 +1513,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def remember_created_at_previous_change; end - sig { returns(T::Boolean) } - def remember_created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def remember_created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def remember_created_at_previously_was; end @@ -1367,8 +1554,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def remember_token_change_to_be_saved; end - sig { returns(T::Boolean) } - def remember_token_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def remember_token_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def remember_token_in_database; end @@ -1376,8 +1563,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def remember_token_previous_change; end - sig { returns(T::Boolean) } - def remember_token_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def remember_token_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def remember_token_previously_was; end @@ -1412,8 +1599,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def reset_password_sent_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def reset_password_sent_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def reset_password_sent_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def reset_password_sent_at_in_database; end @@ -1421,8 +1613,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def reset_password_sent_at_previous_change; end - sig { returns(T::Boolean) } - def reset_password_sent_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def reset_password_sent_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def reset_password_sent_at_previously_was; end @@ -1457,8 +1654,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def reset_password_token_change_to_be_saved; end - sig { returns(T::Boolean) } - def reset_password_token_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def reset_password_token_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def reset_password_token_in_database; end @@ -1466,8 +1663,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def reset_password_token_previous_change; end - sig { returns(T::Boolean) } - def reset_password_token_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def reset_password_token_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def reset_password_token_previously_was; end @@ -1505,6 +1702,9 @@ class User sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_last_sign_in_at!; end @@ -1601,12 +1801,18 @@ class User sig { returns(T::Boolean) } def saved_change_to_expired_reservations?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def saved_change_to_last_sign_in_at; end @@ -1727,8 +1933,8 @@ class User sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def sign_in_count_change_to_be_saved; end - sig { returns(T::Boolean) } - def sign_in_count_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def sign_in_count_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def sign_in_count_in_database; end @@ -1736,8 +1942,8 @@ class User sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def sign_in_count_previous_change; end - sig { returns(T::Boolean) } - def sign_in_count_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def sign_in_count_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def sign_in_count_previously_was; end @@ -1772,8 +1978,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def time_zone_change_to_be_saved; end - sig { returns(T::Boolean) } - def time_zone_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def time_zone_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def time_zone_in_database; end @@ -1781,8 +1987,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def time_zone_previous_change; end - sig { returns(T::Boolean) } - def time_zone_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def time_zone_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def time_zone_previously_was; end @@ -1817,8 +2023,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def uid_change_to_be_saved; end - sig { returns(T::Boolean) } - def uid_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def uid_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def uid_in_database; end @@ -1826,8 +2032,8 @@ class User sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def uid_previous_change; end - sig { returns(T::Boolean) } - def uid_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def uid_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def uid_previously_was; end @@ -1862,8 +2068,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -1871,8 +2082,13 @@ class User sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -1910,6 +2126,9 @@ class User sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_last_sign_in_at?; end @@ -1972,8 +2191,8 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -1987,8 +2206,8 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end @@ -1996,7 +2215,7 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def geocoded(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -2041,6 +2260,9 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def not_reverse_geocoded(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -2065,6 +2287,9 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -2095,6 +2320,12 @@ class User sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def within_bounding_box(*args, &blk); end @@ -2108,10 +2339,48 @@ class User Elem = type_member { { fixed: ::User } } + sig { returns(T::Array[::User]) } + def to_a; end + sig { returns(T::Array[::User]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::User } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::User } } @@ -2155,20 +2424,6 @@ class User end def concat(*records); end - sig do - params( - records: T.any(::User, Integer, String, T::Enumerable[T.any(::User, Integer, String, T::Enumerable[::User])]) - ).returns(T::Array[::User]) - end - def delete(*records); end - - sig do - params( - records: T.any(::User, Integer, String, T::Enumerable[T.any(::User, Integer, String, T::Enumerable[::User])]) - ).returns(T::Array[::User]) - end - def destroy(*records); end - sig { returns(T::Array[::User]) } def load_target; end @@ -2199,6 +2454,9 @@ class User sig { returns(T::Array[::User]) } def target; end + sig { returns(T::Array[::User]) } + def to_a; end + sig { returns(T::Array[::User]) } def to_ary; end end @@ -2209,10 +2467,48 @@ class User Elem = type_member { { fixed: ::User } } + sig { returns(T::Array[::User]) } + def to_a; end + sig { returns(T::Array[::User]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::User } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::User } } diff --git a/sorbet/rbi/dsl/users_controller.rbi b/sorbet/rbi/dsl/users_controller.rbi deleted file mode 100644 index 179919df5..000000000 --- a/sorbet/rbi/dsl/users_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `UsersController`. -# Please instead update this file by running `bin/tapioca dsl UsersController`. - -class UsersController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/voucher.rbi b/sorbet/rbi/dsl/voucher.rbi index 44596378e..eafa4d19f 100644 --- a/sorbet/rbi/dsl/voucher.rbi +++ b/sorbet/rbi/dsl/voucher.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Voucher`. # Please instead update this file by running `bin/tapioca dsl Voucher`. + class Voucher include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,27 +20,61 @@ class Voucher sig { params(block: T.nilable(T.proc.params(record: ::Voucher).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Voucher).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def create_or_find_by!(attributes, &block); end @@ -55,8 +90,18 @@ class Voucher sig { returns(::Voucher) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Voucher) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Voucher]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Voucher).void).returns(T.nilable(::Voucher)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Voucher)) } def find_by(*args); end @@ -64,12 +109,72 @@ class Voucher sig { params(args: T.untyped).returns(::Voucher) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Voucher).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Voucher]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Voucher]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Voucher]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def find_or_initialize_by(attributes, &block); end @@ -82,7 +187,8 @@ class Voucher sig { params(arg: T.untyped, args: T.untyped).returns(::Voucher) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Voucher)) } + sig { params(limit: Integer).returns(T::Array[::Voucher]) } def first(limit = nil); end sig { returns(::Voucher) } @@ -103,10 +209,36 @@ class Voucher sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Voucher)) } + sig { params(limit: Integer).returns(T::Array[::Voucher]) } def last(limit = nil); end sig { returns(::Voucher) } @@ -124,6 +256,13 @@ class Voucher sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Voucher).void) + ).returns(T::Array[::Voucher]) + end sig { params(attributes: T.untyped, block: T.nilable(T.proc.params(object: ::Voucher).void)).returns(::Voucher) } def new(attributes = nil, &block); end @@ -154,15 +293,18 @@ class Voucher sig { returns(::Voucher) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Voucher).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Voucher)) } + sig { params(limit: Integer).returns(T::Array[::Voucher]) } def take(limit = nil); end sig { returns(::Voucher) } @@ -200,6 +342,12 @@ class Voucher sig { params(value: T.nilable(::User)).void } def claimed_by=(value); end + sig { returns(T::Boolean) } + def claimed_by_changed?; end + + sig { returns(T::Boolean) } + def claimed_by_previously_changed?; end + sig { params(args: T.untyped, blk: T.untyped).returns(::User) } def create_claimed_by(*args, &blk); end @@ -230,18 +378,36 @@ class Voucher sig { params(value: T.nilable(::User)).void } def created_by=(value); end + sig { returns(T::Boolean) } + def created_by_changed?; end + + sig { returns(T::Boolean) } + def created_by_previously_changed?; end + sig { returns(T.nilable(::Order)) } def order; end sig { params(value: T.nilable(::Order)).void } def order=(value); end + sig { returns(T::Boolean) } + def order_changed?; end + + sig { returns(T::Boolean) } + def order_previously_changed?; end + sig { returns(T.nilable(::Product)) } def product; end sig { params(value: T.nilable(::Product)).void } def product=(value); end + sig { returns(T::Boolean) } + def product_changed?; end + + sig { returns(T::Boolean) } + def product_previously_changed?; end + sig { returns(T.nilable(::User)) } def reload_claimed_by; end @@ -253,6 +419,18 @@ class Voucher sig { returns(T.nilable(::Product)) } def reload_product; end + + sig { void } + def reset_claimed_by; end + + sig { void } + def reset_created_by; end + + sig { void } + def reset_order; end + + sig { void } + def reset_product; end end module GeneratedAssociationRelationMethods @@ -268,8 +446,8 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -283,13 +461,13 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -301,40 +479,6 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -359,6 +503,9 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -383,6 +530,9 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -410,27 +560,15 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -460,8 +598,13 @@ class Voucher sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def claimed_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def claimed_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def claimed_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def claimed_at_in_database; end @@ -469,8 +612,13 @@ class Voucher sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def claimed_at_previous_change; end - sig { returns(T::Boolean) } - def claimed_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def claimed_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def claimed_at_previously_was; end @@ -505,8 +653,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def claimed_by_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def claimed_by_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def claimed_by_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def claimed_by_id_in_database; end @@ -514,8 +662,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def claimed_by_id_previous_change; end - sig { returns(T::Boolean) } - def claimed_by_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def claimed_by_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def claimed_by_id_previously_was; end @@ -550,8 +698,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def code_change_to_be_saved; end - sig { returns(T::Boolean) } - def code_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def code_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def code_in_database; end @@ -559,8 +707,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def code_previous_change; end - sig { returns(T::Boolean) } - def code_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def code_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def code_previously_was; end @@ -595,8 +743,13 @@ class Voucher sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -604,8 +757,13 @@ class Voucher sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -640,8 +798,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def created_by_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_by_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def created_by_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def created_by_id_in_database; end @@ -649,8 +807,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def created_by_id_previous_change; end - sig { returns(T::Boolean) } - def created_by_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def created_by_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def created_by_id_previously_was; end @@ -661,7 +819,7 @@ class Voucher sig { void } def created_by_id_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -679,27 +837,72 @@ class Voucher sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -730,8 +933,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def order_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def order_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def order_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def order_id_in_database; end @@ -739,8 +942,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def order_id_previous_change; end - sig { returns(T::Boolean) } - def order_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def order_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def order_id_previously_was; end @@ -775,8 +978,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def product_id_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_in_database; end @@ -784,8 +987,8 @@ class Voucher sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def product_id_previous_change; end - sig { returns(T::Boolean) } - def product_id_previously_changed?; end + sig { params(from: T.nilable(::Integer), to: T.nilable(::Integer)).returns(T::Boolean) } + def product_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def product_id_previously_was; end @@ -814,6 +1017,9 @@ class Voucher sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_order_id!; end @@ -853,12 +1059,18 @@ class Voucher sig { returns(T::Boolean) } def saved_change_to_created_by_id?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } def saved_change_to_order_id; end @@ -901,8 +1113,13 @@ class Voucher sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -910,8 +1127,13 @@ class Voucher sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -940,6 +1162,9 @@ class Voucher sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_order_id?; end @@ -963,8 +1188,8 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -978,13 +1203,13 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -1020,6 +1245,9 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -1044,6 +1272,9 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -1074,6 +1305,12 @@ class Voucher sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -1084,10 +1321,48 @@ class Voucher Elem = type_member { { fixed: ::Voucher } } + sig { returns(T::Array[::Voucher]) } + def to_a; end + sig { returns(T::Array[::Voucher]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Voucher } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Voucher } } @@ -1131,20 +1406,6 @@ class Voucher end def concat(*records); end - sig do - params( - records: T.any(::Voucher, Integer, String, T::Enumerable[T.any(::Voucher, Integer, String, T::Enumerable[::Voucher])]) - ).returns(T::Array[::Voucher]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Voucher, Integer, String, T::Enumerable[T.any(::Voucher, Integer, String, T::Enumerable[::Voucher])]) - ).returns(T::Array[::Voucher]) - end - def destroy(*records); end - sig { returns(T::Array[::Voucher]) } def load_target; end @@ -1175,6 +1436,9 @@ class Voucher sig { returns(T::Array[::Voucher]) } def target; end + sig { returns(T::Array[::Voucher]) } + def to_a; end + sig { returns(T::Array[::Voucher]) } def to_ary; end end @@ -1185,10 +1449,48 @@ class Voucher Elem = type_member { { fixed: ::Voucher } } + sig { returns(T::Array[::Voucher]) } + def to_a; end + sig { returns(T::Array[::Voucher]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Voucher } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Voucher } } diff --git a/sorbet/rbi/dsl/vouchers_controller.rbi b/sorbet/rbi/dsl/vouchers_controller.rbi deleted file mode 100644 index 261fbf09f..000000000 --- a/sorbet/rbi/dsl/vouchers_controller.rbi +++ /dev/null @@ -1,48 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for dynamic methods in `VouchersController`. -# Please instead update this file by running `bin/tapioca dsl VouchersController`. - -class VouchersController - sig { returns(HelperProxy) } - def helpers; end - - module HelperMethods - include ::Turbo::DriveHelper - include ::Turbo::FramesHelper - include ::Turbo::IncludesHelper - include ::Turbo::StreamsHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::Turbo::Streams::ActionHelper - include ::ActionText::ContentHelper - include ::ActionText::TagHelper - include ::Importmap::ImportmapTagsHelper - include ::ActionController::Base::HelperMethods - include ::ApplicationHelper - include ::LogLineHelper - include ::RconHelper - include ::ReservationsHelper - include ::SessionsHelper - include ::FontAwesome::Rails::IconHelper - include ::DeviseHelper - - sig { returns(T.untyped) } - def current_admin; end - - sig { returns(T.untyped) } - def current_league_admin; end - - sig { returns(T.untyped) } - def current_streamer; end - - sig { returns(T.untyped) } - def time_zone_from_cookie; end - end - - class HelperProxy < ::ActionView::Base - include HelperMethods - end -end diff --git a/sorbet/rbi/dsl/whitelist.rbi b/sorbet/rbi/dsl/whitelist.rbi index 9b67b53fd..156c95320 100644 --- a/sorbet/rbi/dsl/whitelist.rbi +++ b/sorbet/rbi/dsl/whitelist.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `Whitelist`. # Please instead update this file by running `bin/tapioca dsl Whitelist`. + class Whitelist include GeneratedAssociationMethods include GeneratedAttributeMethods @@ -19,9 +20,16 @@ class Whitelist sig { params(block: T.nilable(T.proc.params(record: ::Whitelist).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Whitelist).void)).returns(::Whitelist) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -30,12 +38,20 @@ class Whitelist end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::Whitelist).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Whitelist).void)).returns(::Whitelist) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -44,6 +60,13 @@ class Whitelist end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::Whitelist).void)).returns(::Whitelist) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -52,6 +75,12 @@ class Whitelist end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -60,6 +89,12 @@ class Whitelist end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -80,8 +115,18 @@ class Whitelist sig { returns(::Whitelist) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::Whitelist) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::Whitelist]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::Whitelist).void).returns(T.nilable(::Whitelist)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::Whitelist)) } def find_by(*args); end @@ -89,6 +134,54 @@ class Whitelist sig { params(args: T.untyped).returns(::Whitelist) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::Whitelist).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::Whitelist]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::Whitelist]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::Whitelist]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -97,6 +190,12 @@ class Whitelist end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -105,6 +204,12 @@ class Whitelist end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -122,7 +227,8 @@ class Whitelist sig { params(arg: T.untyped, args: T.untyped).returns(::Whitelist) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Whitelist)) } + sig { params(limit: Integer).returns(T::Array[::Whitelist]) } def first(limit = nil); end sig { returns(::Whitelist) } @@ -143,10 +249,36 @@ class Whitelist sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Whitelist)) } + sig { params(limit: Integer).returns(T::Array[::Whitelist]) } def last(limit = nil); end sig { returns(::Whitelist) } @@ -164,6 +296,13 @@ class Whitelist sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::Whitelist).void)).returns(::Whitelist) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::Whitelist).void) + ).returns(T::Array[::Whitelist]) + end sig do params( attributes: T.untyped, @@ -199,15 +338,18 @@ class Whitelist sig { returns(::Whitelist) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::Whitelist).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::Whitelist)) } + sig { params(limit: Integer).returns(T::Array[::Whitelist]) } def take(limit = nil); end sig { returns(::Whitelist) } @@ -255,8 +397,8 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -270,13 +412,13 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -288,40 +430,6 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -346,6 +454,9 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -370,6 +481,9 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -397,27 +511,15 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -447,8 +549,13 @@ class Whitelist sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end @@ -456,8 +563,13 @@ class Whitelist sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -492,8 +604,8 @@ class Whitelist sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_change_to_be_saved; end - sig { returns(T::Boolean) } - def file_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_in_database; end @@ -501,8 +613,8 @@ class Whitelist sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def file_previous_change; end - sig { returns(T::Boolean) } - def file_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def file_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def file_previously_was; end @@ -513,7 +625,52 @@ class Whitelist sig { void } def file_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(T.nilable(T::Boolean)) } + def hidden; end + + sig { params(value: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def hidden=(value); end + + sig { returns(T::Boolean) } + def hidden?; end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_before_last_save; end + + sig { returns(T.untyped) } + def hidden_before_type_cast; end + + sig { returns(T::Boolean) } + def hidden_came_from_user?; end + + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def hidden_change; end + + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def hidden_change_to_be_saved; end + + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def hidden_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_in_database; end + + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def hidden_previous_change; end + + sig { params(from: T.nilable(T::Boolean), to: T.nilable(T::Boolean)).returns(T::Boolean) } + def hidden_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_previously_was; end + + sig { returns(T.nilable(T::Boolean)) } + def hidden_was; end + + sig { void } + def hidden_will_change!; end + + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -531,27 +688,72 @@ class Whitelist sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -564,9 +766,15 @@ class Whitelist sig { void } def restore_file!; end + sig { void } + def restore_hidden!; end + sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_updated_at!; end @@ -582,12 +790,24 @@ class Whitelist sig { returns(T::Boolean) } def saved_change_to_file?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([T.nilable(T::Boolean), T.nilable(T::Boolean)])) } + def saved_change_to_hidden; end + + sig { returns(T::Boolean) } + def saved_change_to_hidden?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def saved_change_to_updated_at; end @@ -618,8 +838,13 @@ class Whitelist sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end @@ -627,8 +852,13 @@ class Whitelist sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig do + params( + from: T.nilable(::ActiveSupport::TimeWithZone), + to: T.nilable(::ActiveSupport::TimeWithZone) + ).returns(T::Boolean) + end + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -645,9 +875,15 @@ class Whitelist sig { returns(T::Boolean) } def will_save_change_to_file?; end + sig { returns(T::Boolean) } + def will_save_change_to_hidden?; end + sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_updated_at?; end end @@ -665,8 +901,8 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -680,13 +916,13 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -722,6 +958,9 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -746,6 +985,9 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -776,6 +1018,12 @@ class Whitelist sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -786,10 +1034,48 @@ class Whitelist Elem = type_member { { fixed: ::Whitelist } } + sig { returns(T::Array[::Whitelist]) } + def to_a; end + sig { returns(T::Array[::Whitelist]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::Whitelist } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::Whitelist } } @@ -833,20 +1119,6 @@ class Whitelist end def concat(*records); end - sig do - params( - records: T.any(::Whitelist, Integer, String, T::Enumerable[T.any(::Whitelist, Integer, String, T::Enumerable[::Whitelist])]) - ).returns(T::Array[::Whitelist]) - end - def delete(*records); end - - sig do - params( - records: T.any(::Whitelist, Integer, String, T::Enumerable[T.any(::Whitelist, Integer, String, T::Enumerable[::Whitelist])]) - ).returns(T::Array[::Whitelist]) - end - def destroy(*records); end - sig { returns(T::Array[::Whitelist]) } def load_target; end @@ -877,6 +1149,9 @@ class Whitelist sig { returns(T::Array[::Whitelist]) } def target; end + sig { returns(T::Array[::Whitelist]) } + def to_a; end + sig { returns(T::Array[::Whitelist]) } def to_ary; end end @@ -887,10 +1162,48 @@ class Whitelist Elem = type_member { { fixed: ::Whitelist } } + sig { returns(T::Array[::Whitelist]) } + def to_a; end + sig { returns(T::Array[::Whitelist]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::Whitelist } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::Whitelist } } diff --git a/sorbet/rbi/dsl/whitelist_tf.rbi b/sorbet/rbi/dsl/whitelist_tf.rbi index 5dadfc53e..fd04c1116 100644 --- a/sorbet/rbi/dsl/whitelist_tf.rbi +++ b/sorbet/rbi/dsl/whitelist_tf.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for dynamic methods in `WhitelistTf`. # Please instead update this file by running `bin/tapioca dsl WhitelistTf`. + class WhitelistTf include GeneratedAttributeMethods extend CommonRelationMethods @@ -18,9 +19,16 @@ class WhitelistTf sig { params(block: T.nilable(T.proc.params(record: ::WhitelistTf).returns(T.untyped))).returns(T::Boolean) } def any?(&block); end - sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def average(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::WhitelistTf).void)).returns(::WhitelistTf) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -29,12 +37,20 @@ class WhitelistTf end def build(attributes = nil, &block); end - sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.untyped) } + sig { params(operation: Symbol, column_name: T.any(String, Symbol)).returns(T.any(Integer, Float, BigDecimal)) } def calculate(operation, column_name); end - sig { params(column_name: T.untyped).returns(T.untyped) } - def count(column_name = nil); end + sig { params(column_name: T.nilable(T.any(String, Symbol))).returns(Integer) } + sig { params(column_name: NilClass, block: T.proc.params(object: ::WhitelistTf).void).returns(Integer) } + def count(column_name = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::WhitelistTf).void)).returns(::WhitelistTf) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -43,6 +59,13 @@ class WhitelistTf end def create(attributes = nil, &block); end + sig { params(block: T.nilable(T.proc.params(object: ::WhitelistTf).void)).returns(::WhitelistTf) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -51,6 +74,12 @@ class WhitelistTf end def create!(attributes = nil, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -59,6 +88,12 @@ class WhitelistTf end def create_or_find_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -79,8 +114,18 @@ class WhitelistTf sig { returns(::WhitelistTf) } def fifth!; end - sig { params(args: T.untyped).returns(T.untyped) } - def find(*args); end + sig do + params( + args: T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything]) + ).returns(::WhitelistTf) + end + sig do + params( + args: T::Array[T.any(String, Symbol, ::ActiveSupport::Multibyte::Chars, T::Boolean, BigDecimal, Numeric, ::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, ::ActiveSupport::Duration, T::Class[T.anything])] + ).returns(T::Enumerable[::WhitelistTf]) + end + sig { params(args: NilClass, block: T.proc.params(object: ::WhitelistTf).void).returns(T.nilable(::WhitelistTf)) } + def find(args = nil, &block); end sig { params(args: T.untyped).returns(T.nilable(::WhitelistTf)) } def find_by(*args); end @@ -88,6 +133,54 @@ class WhitelistTf sig { params(args: T.untyped).returns(::WhitelistTf) } def find_by!(*args); end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: ::WhitelistTf).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[::WhitelistTf]) + end + def find_each(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol, + block: T.proc.params(object: T::Array[::WhitelistTf]).void + ).void + end + sig do + params( + start: T.untyped, + finish: T.untyped, + batch_size: Integer, + error_on_ignore: T.untyped, + order: Symbol + ).returns(T::Enumerator[T::Enumerator[::WhitelistTf]]) + end + def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil, order: :asc, &block); end + + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -96,6 +189,12 @@ class WhitelistTf end def find_or_create_by(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -104,6 +203,12 @@ class WhitelistTf end def find_or_create_by!(attributes, &block); end + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -121,7 +226,8 @@ class WhitelistTf sig { params(arg: T.untyped, args: T.untyped).returns(::WhitelistTf) } def find_sole_by(arg, *args); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::WhitelistTf)) } + sig { params(limit: Integer).returns(T::Array[::WhitelistTf]) } def first(limit = nil); end sig { returns(::WhitelistTf) } @@ -142,10 +248,36 @@ class WhitelistTf sig { returns(Array) } def ids; end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped, + block: T.proc.params(object: PrivateRelation).void + ).void + end + sig do + params( + of: Integer, + start: T.untyped, + finish: T.untyped, + load: T.untyped, + error_on_ignore: T.untyped, + order: Symbol, + use_ranges: T.untyped + ).returns(::ActiveRecord::Batches::BatchEnumerator) + end + def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, order: :asc, use_ranges: nil, &block); end + sig { params(record: T.untyped).returns(T::Boolean) } def include?(record); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::WhitelistTf)) } + sig { params(limit: Integer).returns(T::Array[::WhitelistTf]) } def last(limit = nil); end sig { returns(::WhitelistTf) } @@ -163,6 +295,13 @@ class WhitelistTf sig { params(column_name: T.any(String, Symbol)).returns(T.untyped) } def minimum(column_name); end + sig { params(block: T.nilable(T.proc.params(object: ::WhitelistTf).void)).returns(::WhitelistTf) } + sig do + params( + attributes: T::Array[T.untyped], + block: T.nilable(T.proc.params(object: ::WhitelistTf).void) + ).returns(T::Array[::WhitelistTf]) + end sig do params( attributes: T.untyped, @@ -198,15 +337,18 @@ class WhitelistTf sig { returns(::WhitelistTf) } def sole; end + sig { params(initial_value_or_column: T.untyped).returns(T.any(Integer, Float, BigDecimal)) } sig do - params( - column_name: T.nilable(T.any(String, Symbol)), - block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) - ).returns(T.untyped) + type_parameters(:U) + .params( + initial_value_or_column: T.nilable(T.type_parameter(:U)), + block: T.proc.params(object: ::WhitelistTf).returns(T.type_parameter(:U)) + ).returns(T.type_parameter(:U)) end - def sum(column_name = nil, &block); end + def sum(initial_value_or_column = nil, &block); end - sig { params(limit: T.untyped).returns(T.untyped) } + sig { returns(T.nilable(::WhitelistTf)) } + sig { params(limit: Integer).returns(T::Array[::WhitelistTf]) } def take(limit = nil); end sig { returns(::WhitelistTf) } @@ -238,8 +380,8 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateAssociationRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def eager_load(*args, &blk); end @@ -253,13 +395,13 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } @@ -271,40 +413,6 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def includes(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert!(attributes, returning: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def insert_all(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)) - ).returns(ActiveRecord::Result) - end - def insert_all!(attributes, returning: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def invert_where(*args, &blk); end @@ -329,6 +437,9 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def offset(*args, &blk); end @@ -353,6 +464,9 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def reorder(*args, &blk); end @@ -380,27 +494,15 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def unscope(*args, &blk); end - sig do - params( - attributes: Hash, - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert(attributes, returning: nil, unique_by: nil); end - - sig do - params( - attributes: T::Array[Hash], - returning: T.nilable(T.any(T::Array[Symbol], FalseClass)), - unique_by: T.nilable(T.any(T::Array[Symbol], Symbol)) - ).returns(ActiveRecord::Result) - end - def upsert_all(attributes, returning: nil, unique_by: nil); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateAssociationRelation) } def without(*args, &blk); end end @@ -430,8 +532,8 @@ class WhitelistTf sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def content_change_to_be_saved; end - sig { returns(T::Boolean) } - def content_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def content_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def content_in_database; end @@ -439,8 +541,8 @@ class WhitelistTf sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def content_previous_change; end - sig { returns(T::Boolean) } - def content_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def content_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def content_previously_was; end @@ -451,7 +553,7 @@ class WhitelistTf sig { void } def content_will_change!; end - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + sig { returns(::ActiveSupport::TimeWithZone) } def created_at; end sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } @@ -469,23 +571,23 @@ class WhitelistTf sig { returns(T::Boolean) } def created_at_came_from_user?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_change; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def created_at_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_in_database; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def created_at_previous_change; end - sig { returns(T::Boolean) } - def created_at_previously_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def created_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def created_at_previously_was; end @@ -496,7 +598,7 @@ class WhitelistTf sig { void } def created_at_will_change!; end - sig { returns(T.nilable(::Integer)) } + sig { returns(::Integer) } def id; end sig { params(value: ::Integer).returns(::Integer) } @@ -514,27 +616,72 @@ class WhitelistTf sig { returns(T::Boolean) } def id_came_from_user?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_change_to_be_saved; end - sig { returns(T::Boolean) } - def id_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_in_database; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def id_previous_change; end - sig { returns(T::Boolean) } - def id_previously_changed?; end + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::Integer)) } def id_previously_was; end + sig { returns(::Integer) } + def id_value; end + + sig { params(value: ::Integer).returns(::Integer) } + def id_value=(value); end + + sig { returns(T::Boolean) } + def id_value?; end + + sig { returns(T.nilable(::Integer)) } + def id_value_before_last_save; end + + sig { returns(T.untyped) } + def id_value_before_type_cast; end + + sig { returns(T::Boolean) } + def id_value_came_from_user?; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_change_to_be_saved; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_in_database; end + + sig { returns(T.nilable([::Integer, ::Integer])) } + def id_value_previous_change; end + + sig { params(from: ::Integer, to: ::Integer).returns(T::Boolean) } + def id_value_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end + + sig { returns(T.nilable(::Integer)) } + def id_value_previously_was; end + + sig { returns(T.nilable(::Integer)) } + def id_value_was; end + + sig { void } + def id_value_will_change!; end + sig { returns(T.nilable(::Integer)) } def id_was; end @@ -550,6 +697,9 @@ class WhitelistTf sig { void } def restore_id!; end + sig { void } + def restore_id_value!; end + sig { void } def restore_tf_whitelist_id!; end @@ -562,25 +712,31 @@ class WhitelistTf sig { returns(T::Boolean) } def saved_change_to_content?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def saved_change_to_created_at; end sig { returns(T::Boolean) } def saved_change_to_created_at?; end - sig { returns(T.nilable([T.nilable(::Integer), T.nilable(::Integer)])) } + sig { returns(T.nilable([::Integer, ::Integer])) } def saved_change_to_id; end sig { returns(T::Boolean) } def saved_change_to_id?; end + sig { returns(T.nilable([::Integer, ::Integer])) } + def saved_change_to_id_value; end + + sig { returns(T::Boolean) } + def saved_change_to_id_value?; end + sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def saved_change_to_tf_whitelist_id; end sig { returns(T::Boolean) } def saved_change_to_tf_whitelist_id?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def saved_change_to_updated_at; end sig { returns(T::Boolean) } @@ -610,8 +766,8 @@ class WhitelistTf sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tf_whitelist_id_change_to_be_saved; end - sig { returns(T::Boolean) } - def tf_whitelist_id_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tf_whitelist_id_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tf_whitelist_id_in_database; end @@ -619,8 +775,8 @@ class WhitelistTf sig { returns(T.nilable([T.nilable(::String), T.nilable(::String)])) } def tf_whitelist_id_previous_change; end - sig { returns(T::Boolean) } - def tf_whitelist_id_previously_changed?; end + sig { params(from: T.nilable(::String), to: T.nilable(::String)).returns(T::Boolean) } + def tf_whitelist_id_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::String)) } def tf_whitelist_id_previously_was; end @@ -631,7 +787,7 @@ class WhitelistTf sig { void } def tf_whitelist_id_will_change!; end - sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } + sig { returns(::ActiveSupport::TimeWithZone) } def updated_at; end sig { params(value: ::ActiveSupport::TimeWithZone).returns(::ActiveSupport::TimeWithZone) } @@ -649,23 +805,23 @@ class WhitelistTf sig { returns(T::Boolean) } def updated_at_came_from_user?; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_change; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_change_to_be_saved; end - sig { returns(T::Boolean) } - def updated_at_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_in_database; end - sig { returns(T.nilable([T.nilable(::ActiveSupport::TimeWithZone), T.nilable(::ActiveSupport::TimeWithZone)])) } + sig { returns(T.nilable([::ActiveSupport::TimeWithZone, ::ActiveSupport::TimeWithZone])) } def updated_at_previous_change; end - sig { returns(T::Boolean) } - def updated_at_previously_changed?; end + sig { params(from: ::ActiveSupport::TimeWithZone, to: ::ActiveSupport::TimeWithZone).returns(T::Boolean) } + def updated_at_previously_changed?(from: T.unsafe(nil), to: T.unsafe(nil)); end sig { returns(T.nilable(::ActiveSupport::TimeWithZone)) } def updated_at_previously_was; end @@ -685,6 +841,9 @@ class WhitelistTf sig { returns(T::Boolean) } def will_save_change_to_id?; end + sig { returns(T::Boolean) } + def will_save_change_to_id_value?; end + sig { returns(T::Boolean) } def will_save_change_to_tf_whitelist_id?; end @@ -705,8 +864,8 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def create_with(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def distinct(*args, &blk); end + sig { params(value: T::Boolean).returns(PrivateRelation) } + def distinct(value = true); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def eager_load(*args, &blk); end @@ -720,13 +879,13 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def extending(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } - def extract_associated(*args, &blk); end + sig { params(association: Symbol).returns(T::Array[T.untyped]) } + def extract_associated(association); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def from(*args, &blk); end - sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationGroupChain) } def group(*args, &blk); end sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } @@ -762,6 +921,9 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def none(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def null_relation?(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def offset(*args, &blk); end @@ -786,6 +948,9 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def references(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def regroup(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def reorder(*args, &blk); end @@ -816,6 +981,12 @@ class WhitelistTf sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelationWhereChain) } def where(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with(*args, &blk); end + + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } + def with_recursive(*args, &blk); end + sig { params(args: T.untyped, blk: T.untyped).returns(PrivateRelation) } def without(*args, &blk); end end @@ -826,10 +997,48 @@ class WhitelistTf Elem = type_member { { fixed: ::WhitelistTf } } + sig { returns(T::Array[::WhitelistTf]) } + def to_a; end + sig { returns(T::Array[::WhitelistTf]) } def to_ary; end end + class PrivateAssociationRelationGroupChain < PrivateAssociationRelation + Elem = type_member { { fixed: ::WhitelistTf } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateAssociationRelationWhereChain < PrivateAssociationRelation Elem = type_member { { fixed: ::WhitelistTf } } @@ -873,20 +1082,6 @@ class WhitelistTf end def concat(*records); end - sig do - params( - records: T.any(::WhitelistTf, Integer, String, T::Enumerable[T.any(::WhitelistTf, Integer, String, T::Enumerable[::WhitelistTf])]) - ).returns(T::Array[::WhitelistTf]) - end - def delete(*records); end - - sig do - params( - records: T.any(::WhitelistTf, Integer, String, T::Enumerable[T.any(::WhitelistTf, Integer, String, T::Enumerable[::WhitelistTf])]) - ).returns(T::Array[::WhitelistTf]) - end - def destroy(*records); end - sig { returns(T::Array[::WhitelistTf]) } def load_target; end @@ -917,6 +1112,9 @@ class WhitelistTf sig { returns(T::Array[::WhitelistTf]) } def target; end + sig { returns(T::Array[::WhitelistTf]) } + def to_a; end + sig { returns(T::Array[::WhitelistTf]) } def to_ary; end end @@ -927,10 +1125,48 @@ class WhitelistTf Elem = type_member { { fixed: ::WhitelistTf } } + sig { returns(T::Array[::WhitelistTf]) } + def to_a; end + sig { returns(T::Array[::WhitelistTf]) } def to_ary; end end + class PrivateRelationGroupChain < PrivateRelation + Elem = type_member { { fixed: ::WhitelistTf } } + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) } + def average(column_name); end + + sig do + params( + operation: Symbol, + column_name: T.any(String, Symbol) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def calculate(operation, column_name); end + + sig { params(column_name: T.untyped).returns(T::Hash[T.untyped, Integer]) } + def count(column_name = nil); end + + sig { params(args: T.untyped, blk: T.untyped).returns(T.self_type) } + def having(*args, &blk); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def maximum(column_name); end + + sig { params(column_name: T.any(String, Symbol)).returns(T::Hash[T.untyped, T.untyped]) } + def minimum(column_name); end + + sig do + params( + column_name: T.nilable(T.any(String, Symbol)), + block: T.nilable(T.proc.params(record: T.untyped).returns(T.untyped)) + ).returns(T::Hash[T.untyped, T.any(Integer, Float, BigDecimal)]) + end + def sum(column_name = nil, &block); end + end + class PrivateRelationWhereChain < PrivateRelation Elem = type_member { { fixed: ::WhitelistTf } } diff --git a/sorbet/rbi/gems/.gitattributes b/sorbet/rbi/gems/.gitattributes new file mode 100644 index 000000000..d9bb82a4d --- /dev/null +++ b/sorbet/rbi/gems/.gitattributes @@ -0,0 +1 @@ +**/*.rbi linguist-generated=true diff --git a/sorbet/rbi/gems/actioncable@7.0.5.rbi b/sorbet/rbi/gems/actioncable@7.2.0.rbi similarity index 54% rename from sorbet/rbi/gems/actioncable@7.0.5.rbi rename to sorbet/rbi/gems/actioncable@7.2.0.rbi index ebfc68b1b..549a160bc 100644 --- a/sorbet/rbi/gems/actioncable@7.0.5.rbi +++ b/sorbet/rbi/gems/actioncable@7.2.0.rbi @@ -4,131 +4,144 @@ # This is an autogenerated file for types exported from the `actioncable` gem. # Please instead update this file by running `bin/tapioca gem actioncable`. -# source://actioncable//lib/action_cable/gem_version.rb#3 -module ActionCable - extend ::ActiveSupport::Autoload +# :markup: markdown +# :include: ../README.md +# +# source://actioncable//lib/action_cable.rb#54 +module ActionCable private # Singleton instance of the server # - # source://actioncable//lib/action_cable.rb#51 + # source://actioncable//lib/action_cable.rb#77 def server; end class << self - # Returns the currently loaded version of Action Cable as a Gem::Version. + # source://actioncable//lib/action_cable/deprecator.rb#6 + def deprecator; end + + # Returns the currently loaded version of Action Cable as a `Gem::Version`. # - # source://actioncable//lib/action_cable/gem_version.rb#5 + # source://actioncable//lib/action_cable/gem_version.rb#7 def gem_version; end # Singleton instance of the server # - # source://actioncable//lib/action_cable.rb#51 + # source://actioncable//lib/action_cable.rb#77 def server; end - # Returns the currently loaded version of Action Cable as a Gem::Version. + # Returns the currently loaded version of Action Cable as a `Gem::Version`. # - # source://actioncable//lib/action_cable/version.rb#7 + # source://actioncable//lib/action_cable/version.rb#9 def version; end end end -# source://actioncable//lib/action_cable/channel.rb#4 -module ActionCable::Channel - extend ::ActiveSupport::Autoload -end - -# The channel provides the basic structure of grouping behavior into logical units when communicating over the WebSocket connection. -# You can think of a channel like a form of controller, but one that's capable of pushing content to the subscriber in addition to simply -# responding to the subscriber's direct requests. -# -# Channel instances are long-lived. A channel object will be instantiated when the cable consumer becomes a subscriber, and then -# lives until the consumer disconnects. This may be seconds, minutes, hours, or even days. That means you have to take special care -# not to do anything silly in a channel that would balloon its memory footprint or whatever. The references are forever, so they won't be released -# as is normally the case with a controller instance that gets thrown away after every request. -# -# Long-lived channels (and connections) also mean you're responsible for ensuring that the data is fresh. If you hold a reference to a user -# record, but the name is changed while that reference is held, you may be sending stale data if you don't take precautions to avoid it. -# -# The upside of long-lived channel instances is that you can use instance variables to keep reference to objects that future subscriber requests -# can interact with. Here's a quick example: -# -# class ChatChannel < ApplicationCable::Channel -# def subscribed -# @room = Chat::Room[params[:room_number]] -# end +# source://actioncable//lib/action_cable/channel/base.rb#10 +module ActionCable::Channel; end + +# # Action Cable Channel Base +# +# The channel provides the basic structure of grouping behavior into logical +# units when communicating over the WebSocket connection. You can think of a +# channel like a form of controller, but one that's capable of pushing content +# to the subscriber in addition to simply responding to the subscriber's direct +# requests. +# +# Channel instances are long-lived. A channel object will be instantiated when +# the cable consumer becomes a subscriber, and then lives until the consumer +# disconnects. This may be seconds, minutes, hours, or even days. That means you +# have to take special care not to do anything silly in a channel that would +# balloon its memory footprint or whatever. The references are forever, so they +# won't be released as is normally the case with a controller instance that gets +# thrown away after every request. +# +# Long-lived channels (and connections) also mean you're responsible for +# ensuring that the data is fresh. If you hold a reference to a user record, but +# the name is changed while that reference is held, you may be sending stale +# data if you don't take precautions to avoid it. +# +# The upside of long-lived channel instances is that you can use instance +# variables to keep reference to objects that future subscriber requests can +# interact with. Here's a quick example: +# +# class ChatChannel < ApplicationCable::Channel +# def subscribed +# @room = Chat::Room[params[:room_number]] +# end # -# def speak(data) -# @room.speak data, user: current_user +# def speak(data) +# @room.speak data, user: current_user +# end # end -# end # -# The #speak action simply uses the Chat::Room object that was created when the channel was first subscribed to by the consumer when that -# subscriber wants to say something in the room. +# The #speak action simply uses the Chat::Room object that was created when the +# channel was first subscribed to by the consumer when that subscriber wants to +# say something in the room. # -# == Action processing +# ## Action processing # # Unlike subclasses of ActionController::Base, channels do not follow a RESTful # constraint form for their actions. Instead, Action Cable operates through a -# remote-procedure call model. You can declare any public method on the -# channel (optionally taking a data argument), and this method is -# automatically exposed as callable to the client. +# remote-procedure call model. You can declare any public method on the channel +# (optionally taking a `data` argument), and this method is automatically +# exposed as callable to the client. # # Example: # -# class AppearanceChannel < ApplicationCable::Channel -# def subscribed -# @connection_token = generate_connection_token -# end -# -# def unsubscribed -# current_user.disappear @connection_token -# end +# class AppearanceChannel < ApplicationCable::Channel +# def subscribed +# @connection_token = generate_connection_token +# end # -# def appear(data) -# current_user.appear @connection_token, on: data['appearing_on'] -# end +# def unsubscribed +# current_user.disappear @connection_token +# end # -# def away -# current_user.away @connection_token -# end +# def appear(data) +# current_user.appear @connection_token, on: data['appearing_on'] +# end # -# private -# def generate_connection_token -# SecureRandom.hex(36) +# def away +# current_user.away @connection_token # end -# end # -# In this example, the subscribed and unsubscribed methods are not callable methods, as they -# were already declared in ActionCable::Channel::Base, but #appear -# and #away are. #generate_connection_token is also not -# callable, since it's a private method. You'll see that appear accepts a data -# parameter, which it then uses as part of its model call. #away -# does not, since it's simply a trigger action. +# private +# def generate_connection_token +# SecureRandom.hex(36) +# end +# end # -# Also note that in this example, current_user is available because -# it was marked as an identifying attribute on the connection. All such -# identifiers will automatically create a delegation method of the same name -# on the channel instance. +# In this example, the subscribed and unsubscribed methods are not callable +# methods, as they were already declared in ActionCable::Channel::Base, but +# `#appear` and `#away` are. `#generate_connection_token` is also not callable, +# since it's a private method. You'll see that appear accepts a data parameter, +# which it then uses as part of its model call. `#away` does not, since it's +# simply a trigger action. # -# == Rejecting subscription requests +# Also note that in this example, `current_user` is available because it was +# marked as an identifying attribute on the connection. All such identifiers +# will automatically create a delegation method of the same name on the channel +# instance. +# +# ## Rejecting subscription requests # # A channel can reject a subscription request in the #subscribed callback by # invoking the #reject method: # -# class ChatChannel < ApplicationCable::Channel -# def subscribed -# @room = Chat::Room[params[:room_number]] -# reject unless current_user.can_access?(@room) +# class ChatChannel < ApplicationCable::Channel +# def subscribed +# @room = Chat::Room[params[:room_number]] +# reject unless current_user.can_access?(@room) +# end # end -# end # -# In this example, the subscription will be rejected if the -# current_user does not have access to the chat room. On the -# client-side, the Channel#rejected callback will get invoked when -# the server rejects the subscription request. +# In this example, the subscription will be rejected if the `current_user` does +# not have access to the chat room. On the client-side, the `Channel#rejected` +# callback will get invoked when the server rejects the subscription request. # -# source://actioncable//lib/action_cable/channel/base.rb#97 +# source://actioncable//lib/action_cable/channel/base.rb#110 class ActionCable::Channel::Base include ::ActiveSupport::Callbacks include ::ActionCable::Channel::Callbacks @@ -147,249 +160,285 @@ class ActionCable::Channel::Base # @return [Base] a new instance of Base # - # source://actioncable//lib/action_cable/channel/base.rb#144 + # source://actioncable//lib/action_cable/channel/base.rb#156 def initialize(connection, identifier, params = T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_subscribe_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_unsubscribe_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _subscribe_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _unsubscribe_callbacks; end # Returns the value of attribute connection. # - # source://actioncable//lib/action_cable/channel/base.rb#105 + # source://actioncable//lib/action_cable/channel/base.rb#118 def connection; end # Returns the value of attribute identifier. # - # source://actioncable//lib/action_cable/channel/base.rb#105 + # source://actioncable//lib/action_cable/channel/base.rb#118 def identifier; end - # source://actioncable//lib/action_cable/channel/base.rb#106 + # source://actioncable//lib/action_cable/channel/base.rb#119 def logger(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute params. # - # source://actioncable//lib/action_cable/channel/base.rb#105 + # source://actioncable//lib/action_cable/channel/base.rb#118 def params; end - # Extract the action name from the passed data and process it via the channel. The process will ensure - # that the action requested is a public method on the channel declared by the user (so not one of the callbacks - # like #subscribed). + # Extract the action name from the passed data and process it via the channel. + # The process will ensure that the action requested is a public method on the + # channel declared by the user (so not one of the callbacks like #subscribed). # - # source://actioncable//lib/action_cable/channel/base.rb#164 + # source://actioncable//lib/action_cable/channel/base.rb#176 def perform_action(data); end - # source://actioncable//lib/action_cable/channel/periodic_timers.rb#9 + # source://actioncable//lib/action_cable/channel/periodic_timers.rb#11 def periodic_timers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # This method is called after subscription has been added to the connection - # and confirms or rejects the subscription. + # This method is called after subscription has been added to the connection and + # confirms or rejects the subscription. # - # source://actioncable//lib/action_cable/channel/base.rb#179 + # source://actioncable//lib/action_cable/channel/base.rb#191 def subscribe_to_channel; end - # Called by the cable connection when it's cut, so the channel has a chance to cleanup with callbacks. - # This method is not intended to be called directly by the user. Instead, override the #unsubscribed callback. + # Called by the cable connection when it's cut, so the channel has a chance to + # cleanup with callbacks. This method is not intended to be called directly by + # the user. Instead, override the #unsubscribed callback. # - # source://actioncable//lib/action_cable/channel/base.rb#190 + # source://actioncable//lib/action_cable/channel/base.rb#203 def unsubscribe_from_channel; end private - # source://actioncable//lib/action_cable/channel/base.rb#276 + # source://actioncable//lib/action_cable/channel/base.rb#293 def action_signature(action, data); end - # source://actioncable//lib/action_cable/channel/base.rb#228 + # source://actioncable//lib/action_cable/channel/base.rb#245 def defer_subscription_confirmation!; end # @return [Boolean] # - # source://actioncable//lib/action_cable/channel/base.rb#232 + # source://actioncable//lib/action_cable/channel/base.rb#249 def defer_subscription_confirmation?; end - # source://actioncable//lib/action_cable/channel/base.rb#248 + # source://actioncable//lib/action_cable/channel/base.rb#265 def delegate_connection_identifiers; end - # source://actioncable//lib/action_cable/channel/base.rb#264 + # source://actioncable//lib/action_cable/channel/base.rb#281 def dispatch_action(action, data); end - # source://actioncable//lib/action_cable/channel/base.rb#222 + # source://actioncable//lib/action_cable/channel/base.rb#239 def ensure_confirmation_sent; end - # source://actioncable//lib/action_cable/channel/base.rb#256 + # source://actioncable//lib/action_cable/channel/base.rb#273 def extract_action(data); end + # source://actioncable//lib/action_cable/channel/base.rb#304 + def parameter_filter; end + # @return [Boolean] # - # source://actioncable//lib/action_cable/channel/base.rb#260 + # source://actioncable//lib/action_cable/channel/base.rb#277 def processable_action?(action); end - # source://actioncable//lib/action_cable/channel/base.rb#240 + # source://actioncable//lib/action_cable/channel/base.rb#257 def reject; end - # source://actioncable//lib/action_cable/channel/base.rb#295 + # source://actioncable//lib/action_cable/channel/base.rb#319 def reject_subscription; end - # Called once a consumer has become a subscriber of the channel. Usually the place to set up any streams - # you want this channel to be sending to the subscriber. + # Called once a consumer has become a subscriber of the channel. Usually the + # place to set up any streams you want this channel to be sending to the + # subscriber. # - # source://actioncable//lib/action_cable/channel/base.rb#199 + # source://actioncable//lib/action_cable/channel/base.rb#213 def subscribed; end # @return [Boolean] # - # source://actioncable//lib/action_cable/channel/base.rb#236 + # source://actioncable//lib/action_cable/channel/base.rb#253 def subscription_confirmation_sent?; end # @return [Boolean] # - # source://actioncable//lib/action_cable/channel/base.rb#244 + # source://actioncable//lib/action_cable/channel/base.rb#261 def subscription_rejected?; end - # Transmit a hash of data to the subscriber. The hash will automatically be wrapped in a JSON envelope with - # the proper channel identifier marked as the recipient. + # Transmit a hash of data to the subscriber. The hash will automatically be + # wrapped in a JSON envelope with the proper channel identifier marked as the + # recipient. # - # source://actioncable//lib/action_cable/channel/base.rb#211 + # source://actioncable//lib/action_cable/channel/base.rb#226 def transmit(data, via: T.unsafe(nil)); end - # source://actioncable//lib/action_cable/channel/base.rb#284 + # source://actioncable//lib/action_cable/channel/base.rb#308 def transmit_subscription_confirmation; end - # source://actioncable//lib/action_cable/channel/base.rb#300 + # source://actioncable//lib/action_cable/channel/base.rb#324 def transmit_subscription_rejection; end - # Called once a consumer has cut its cable connection. Can be used for cleaning up connections or marking - # users as offline or the like. + # Called once a consumer has cut its cable connection. Can be used for cleaning + # up connections or marking users as offline or the like. # - # source://actioncable//lib/action_cable/channel/base.rb#205 + # source://actioncable//lib/action_cable/channel/base.rb#219 def unsubscribed; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _subscribe_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _subscribe_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _unsubscribe_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _unsubscribe_callbacks=(value); end - # A list of method names that should be considered actions. This - # includes all public instance methods on a channel, less - # any internal methods (defined on Base), adding back in - # any methods that are internal, but still exist on the class - # itself. + # A list of method names that should be considered actions. This includes all + # public instance methods on a channel, less any internal methods (defined on + # Base), adding back in any methods that are internal, but still exist on the + # class itself. # - # ==== Returns - # * Set - A set of all methods that should be considered actions. + # #### Returns + # * `Set` - A set of all methods that should be considered actions. # - # source://actioncable//lib/action_cable/channel/base.rb#117 + # source://actioncable//lib/action_cable/channel/base.rb#129 def action_methods; end - # source://actioncable//lib/action_cable/channel/periodic_timers.rb#9 + # source://actioncable//lib/action_cable/channel/periodic_timers.rb#11 def periodic_timers; end - # source://actioncable//lib/action_cable/channel/periodic_timers.rb#9 + # source://actioncable//lib/action_cable/channel/periodic_timers.rb#11 def periodic_timers=(value); end - # source://actioncable//lib/action_cable/channel/periodic_timers.rb#9 + # source://actioncable//lib/action_cable/channel/periodic_timers.rb#11 def periodic_timers?; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end private - # action_methods are cached and there is sometimes need to refresh - # them. ::clear_action_methods! allows you to do that, so next time - # you run action_methods, they will be recalculated. + # action_methods are cached and there is sometimes need to refresh them. + # ::clear_action_methods! allows you to do that, so next time you run + # action_methods, they will be recalculated. # - # source://actioncable//lib/action_cable/channel/base.rb#133 + # source://actioncable//lib/action_cable/channel/base.rb#145 def clear_action_methods!; end # Refresh the cached action_methods when a new action_method is added. # - # source://actioncable//lib/action_cable/channel/base.rb#138 + # source://actioncable//lib/action_cable/channel/base.rb#150 def method_added(name); end end end -# source://actioncable//lib/action_cable/channel/broadcasting.rb#7 +# source://actioncable//lib/action_cable/channel/broadcasting.rb#9 module ActionCable::Channel::Broadcasting extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionCable::Channel::Broadcasting::ClassMethods - # source://actioncable//lib/action_cable/channel/broadcasting.rb#10 - def broadcast_to(*_arg0, **_arg1, &_arg2); end + # source://actioncable//lib/action_cable/channel/broadcasting.rb#45 + def broadcast_to(model, message); end - # source://actioncable//lib/action_cable/channel/broadcasting.rb#10 - def broadcasting_for(*_arg0, **_arg1, &_arg2); end + # source://actioncable//lib/action_cable/channel/broadcasting.rb#41 + def broadcasting_for(model); end end # source://actioncable//lib/action_cable/channel/broadcasting.rb#12 module ActionCable::Channel::Broadcasting::ClassMethods - # Broadcast a hash to a unique broadcasting for this model in this channel. + # Broadcast a hash to a unique broadcasting for this `model` in this channel. # # source://actioncable//lib/action_cable/channel/broadcasting.rb#14 def broadcast_to(model, message); end - # Returns a unique broadcasting identifier for this model in this channel: + # Returns a unique broadcasting identifier for this `model` in this channel: # - # CommentsChannel.broadcasting_for("all") # => "comments:all" + # CommentsChannel.broadcasting_for("all") # => "comments:all" # - # You can pass any object as a target (e.g. Active Record model), and it - # would be serialized into a string under the hood. + # You can pass any object as a target (e.g. Active Record model), and it would + # be serialized into a string under the hood. # # source://actioncable//lib/action_cable/channel/broadcasting.rb#24 def broadcasting_for(model); end - # source://actioncable//lib/action_cable/channel/broadcasting.rb#28 + private + + # source://actioncable//lib/action_cable/channel/broadcasting.rb#29 def serialize_broadcasting(object); end end -# source://actioncable//lib/action_cable/channel/callbacks.rb#7 +# # Action Cable Channel Callbacks +# +# Action Cable Channel provides callback hooks that are invoked during the life +# cycle of a channel: +# +# * [before_subscribe](rdoc-ref:ClassMethods#before_subscribe) +# * [after_subscribe](rdoc-ref:ClassMethods#after_subscribe) (aliased as +# [on_subscribe](rdoc-ref:ClassMethods#on_subscribe)) +# * [before_unsubscribe](rdoc-ref:ClassMethods#before_unsubscribe) +# * [after_unsubscribe](rdoc-ref:ClassMethods#after_unsubscribe) (aliased as +# [on_unsubscribe](rdoc-ref:ClassMethods#on_unsubscribe)) +# +# +# #### Example +# +# class ChatChannel < ApplicationCable::Channel +# after_subscribe :send_welcome_message, unless: :subscription_rejected? +# after_subscribe :track_subscription +# +# private +# def send_welcome_message +# broadcast_to(...) +# end +# +# def track_subscription +# # ... +# end +# end +# +# source://actioncable//lib/action_cable/channel/callbacks.rb#38 module ActionCable::Channel::Callbacks extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -412,135 +461,163 @@ module ActionCable::Channel::Callbacks end end -# source://actioncable//lib/action_cable/channel/callbacks.rb#16 +# source://actioncable//lib/action_cable/channel/callbacks.rb#47 module ActionCable::Channel::Callbacks::ClassMethods - # source://actioncable//lib/action_cable/channel/callbacks.rb#21 + # This callback will be triggered after the Base#subscribed method is called, + # even if the subscription was rejected with the Base#reject method. + # + # To trigger the callback only on successful subscriptions, use the + # Base#subscription_rejected? method: + # + # after_subscribe :my_method, unless: :subscription_rejected? + # + # source://actioncable//lib/action_cable/channel/callbacks.rb#60 def after_subscribe(*methods, &block); end - # source://actioncable//lib/action_cable/channel/callbacks.rb#30 + # source://actioncable//lib/action_cable/channel/callbacks.rb#69 def after_unsubscribe(*methods, &block); end - # source://actioncable//lib/action_cable/channel/callbacks.rb#17 + # source://actioncable//lib/action_cable/channel/callbacks.rb#48 def before_subscribe(*methods, &block); end - # source://actioncable//lib/action_cable/channel/callbacks.rb#26 + # source://actioncable//lib/action_cable/channel/callbacks.rb#65 def before_unsubscribe(*methods, &block); end - # source://actioncable//lib/action_cable/channel/callbacks.rb#21 + # This callback will be triggered after the Base#subscribed method is called, + # even if the subscription was rejected with the Base#reject method. + # + # To trigger the callback only on successful subscriptions, use the + # Base#subscription_rejected? method: + # + # after_subscribe :my_method, unless: :subscription_rejected? + # + # source://actioncable//lib/action_cable/channel/callbacks.rb#60 def on_subscribe(*methods, &block); end - # source://actioncable//lib/action_cable/channel/callbacks.rb#30 + # source://actioncable//lib/action_cable/channel/callbacks.rb#69 def on_unsubscribe(*methods, &block); end end -# Stub +stream_from+ to track streams for the channel. -# Add public aliases for +subscription_confirmation_sent?+ and -# +subscription_rejected?+. +# # Action Cable Channel Stub +# +# Stub `stream_from` to track streams for the channel. Add public aliases for +# `subscription_confirmation_sent?` and `subscription_rejected?`. # -# source://actioncable//lib/action_cable/channel/test_case.rb#21 +# source://actioncable//lib/action_cable/channel/test_case.rb#24 module ActionCable::Channel::ChannelStub # @return [Boolean] # - # source://actioncable//lib/action_cable/channel/test_case.rb#22 + # source://actioncable//lib/action_cable/channel/test_case.rb#25 def confirmed?; end # @return [Boolean] # - # source://actioncable//lib/action_cable/channel/test_case.rb#26 + # source://actioncable//lib/action_cable/channel/test_case.rb#29 def rejected?; end # Make periodic timers no-op # - # source://actioncable//lib/action_cable/channel/test_case.rb#43 + # source://actioncable//lib/action_cable/channel/test_case.rb#46 def start_periodic_timers; end - # source://actioncable//lib/action_cable/channel/test_case.rb#34 + # source://actioncable//lib/action_cable/channel/test_case.rb#37 def stop_all_streams; end # Make periodic timers no-op # - # source://actioncable//lib/action_cable/channel/test_case.rb#43 + # source://actioncable//lib/action_cable/channel/test_case.rb#46 def stop_periodic_timers; end - # source://actioncable//lib/action_cable/channel/test_case.rb#30 + # source://actioncable//lib/action_cable/channel/test_case.rb#33 def stream_from(broadcasting, *_arg1); end - # source://actioncable//lib/action_cable/channel/test_case.rb#38 + # source://actioncable//lib/action_cable/channel/test_case.rb#41 def streams; end end -# source://actioncable//lib/action_cable/channel/test_case.rb#47 +# source://actioncable//lib/action_cable/channel/test_case.rb#50 class ActionCable::Channel::ConnectionStub # @return [ConnectionStub] a new instance of ConnectionStub # - # source://actioncable//lib/action_cable/channel/test_case.rb#50 + # source://actioncable//lib/action_cable/channel/test_case.rb#55 def initialize(identifiers = T.unsafe(nil)); end - # source://actioncable//lib/action_cable/channel/test_case.rb#66 + # source://actioncable//lib/action_cable/channel/test_case.rb#53 + def config(*_arg0, **_arg1, &_arg2); end + + # source://actioncable//lib/action_cable/channel/test_case.rb#72 def connection_identifier; end # Returns the value of attribute identifiers. # - # source://actioncable//lib/action_cable/channel/test_case.rb#48 + # source://actioncable//lib/action_cable/channel/test_case.rb#51 def identifiers; end # Returns the value of attribute logger. # - # source://actioncable//lib/action_cable/channel/test_case.rb#48 + # source://actioncable//lib/action_cable/channel/test_case.rb#51 def logger; end + # source://actioncable//lib/action_cable/channel/test_case.rb#53 + def pubsub(*_arg0, **_arg1, &_arg2); end + + # Returns the value of attribute server. + # + # source://actioncable//lib/action_cable/channel/test_case.rb#51 + def server; end + # Returns the value of attribute subscriptions. # - # source://actioncable//lib/action_cable/channel/test_case.rb#48 + # source://actioncable//lib/action_cable/channel/test_case.rb#51 def subscriptions; end # Returns the value of attribute transmissions. # - # source://actioncable//lib/action_cable/channel/test_case.rb#48 + # source://actioncable//lib/action_cable/channel/test_case.rb#51 def transmissions; end - # source://actioncable//lib/action_cable/channel/test_case.rb#62 + # source://actioncable//lib/action_cable/channel/test_case.rb#68 def transmit(cable_message); end private - # source://actioncable//lib/action_cable/channel/test_case.rb#71 + # source://actioncable//lib/action_cable/channel/test_case.rb#77 def connection_gid(ids); end end -# source://actioncable//lib/action_cable/channel/naming.rb#5 +# source://actioncable//lib/action_cable/channel/naming.rb#7 module ActionCable::Channel::Naming extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionCable::Channel::Naming::ClassMethods - # source://actioncable//lib/action_cable/channel/naming.rb#22 - def channel_name(*_arg0, **_arg1, &_arg2); end + # source://actioncable//lib/action_cable/channel/naming.rb#23 + def channel_name; end end -# source://actioncable//lib/action_cable/channel/naming.rb#8 +# source://actioncable//lib/action_cable/channel/naming.rb#10 module ActionCable::Channel::Naming::ClassMethods - # Returns the name of the channel, underscored, without the Channel ending. - # If the channel is in a namespace, then the namespaces are represented by single + # Returns the name of the channel, underscored, without the `Channel` ending. If + # the channel is in a namespace, then the namespaces are represented by single # colon separators in the channel name. # - # ChatChannel.channel_name # => 'chat' - # Chats::AppearancesChannel.channel_name # => 'chats:appearances' - # FooChats::BarAppearancesChannel.channel_name # => 'foo_chats:bar_appearances' + # ChatChannel.channel_name # => 'chat' + # Chats::AppearancesChannel.channel_name # => 'chats:appearances' + # FooChats::BarAppearancesChannel.channel_name # => 'foo_chats:bar_appearances' # - # source://actioncable//lib/action_cable/channel/naming.rb#16 + # source://actioncable//lib/action_cable/channel/naming.rb#18 def channel_name; end end -# source://actioncable//lib/action_cable/channel/test_case.rb#10 +# source://actioncable//lib/action_cable/channel/test_case.rb#12 class ActionCable::Channel::NonInferrableChannelError < ::StandardError # @return [NonInferrableChannelError] a new instance of NonInferrableChannelError # - # source://actioncable//lib/action_cable/channel/test_case.rb#11 + # source://actioncable//lib/action_cable/channel/test_case.rb#13 def initialize(name); end end -# source://actioncable//lib/action_cable/channel/periodic_timers.rb#5 +# source://actioncable//lib/action_cable/channel/periodic_timers.rb#7 module ActionCable::Channel::PeriodicTimers extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -573,16 +650,14 @@ module ActionCable::Channel::PeriodicTimers end end -# source://actioncable//lib/action_cable/channel/periodic_timers.rb#15 +# source://actioncable//lib/action_cable/channel/periodic_timers.rb#17 module ActionCable::Channel::PeriodicTimers::ClassMethods - # Periodically performs a task on the channel, like updating an online - # user counter, polling a backend for new status messages, sending - # regular "heartbeat" messages, or doing some internal work and giving - # progress updates. + # Periodically performs a task on the channel, like updating an online user + # counter, polling a backend for new status messages, sending regular + # "heartbeat" messages, or doing some internal work and giving progress updates. # - # Pass a method name or lambda argument or provide a block to call. - # Specify the calling period in seconds using the every: - # keyword argument. + # Pass a method name or lambda argument or provide a block to call. Specify the + # calling period in seconds using the `every:` keyword argument. # # periodically :transmit_progress, every: 5.seconds # @@ -594,290 +669,305 @@ module ActionCable::Channel::PeriodicTimers::ClassMethods def periodically(callback_or_method_name = T.unsafe(nil), every:, &block); end end -# Streams allow channels to route broadcastings to the subscriber. A broadcasting is, as discussed elsewhere, a pubsub queue where any data -# placed into it is automatically sent to the clients that are connected at that time. It's purely an online queue, though. If you're not -# streaming a broadcasting at the very moment it sends out an update, you will not get that update, even if you connect after it has been sent. +# # Action Cable Channel Streams # -# Most commonly, the streamed broadcast is sent straight to the subscriber on the client-side. The channel just acts as a connector between -# the two parties (the broadcaster and the channel subscriber). Here's an example of a channel that allows subscribers to get all new -# comments on a given page: +# Streams allow channels to route broadcastings to the subscriber. A +# broadcasting is, as discussed elsewhere, a pubsub queue where any data placed +# into it is automatically sent to the clients that are connected at that time. +# It's purely an online queue, though. If you're not streaming a broadcasting at +# the very moment it sends out an update, you will not get that update, even if +# you connect after it has been sent. # -# class CommentsChannel < ApplicationCable::Channel -# def follow(data) -# stream_from "comments_for_#{data['recording_id']}" -# end +# Most commonly, the streamed broadcast is sent straight to the subscriber on +# the client-side. The channel just acts as a connector between the two parties +# (the broadcaster and the channel subscriber). Here's an example of a channel +# that allows subscribers to get all new comments on a given page: +# +# class CommentsChannel < ApplicationCable::Channel +# def follow(data) +# stream_from "comments_for_#{data['recording_id']}" +# end # -# def unfollow -# stop_all_streams +# def unfollow +# stop_all_streams +# end # end -# end # -# Based on the above example, the subscribers of this channel will get whatever data is put into the, -# let's say, comments_for_45 broadcasting as soon as it's put there. +# Based on the above example, the subscribers of this channel will get whatever +# data is put into the, let's say, `comments_for_45` broadcasting as soon as +# it's put there. # # An example broadcasting for this channel looks like so: # -# ActionCable.server.broadcast "comments_for_45", { author: 'DHH', content: 'Rails is just swell' } +# ActionCable.server.broadcast "comments_for_45", { author: 'DHH', content: 'Rails is just swell' } # -# If you have a stream that is related to a model, then the broadcasting used can be generated from the model and channel. -# The following example would subscribe to a broadcasting like comments:Z2lkOi8vVGVzdEFwcC9Qb3N0LzE. +# If you have a stream that is related to a model, then the broadcasting used +# can be generated from the model and channel. The following example would +# subscribe to a broadcasting like `comments:Z2lkOi8vVGVzdEFwcC9Qb3N0LzE`. # -# class CommentsChannel < ApplicationCable::Channel -# def subscribed -# post = Post.find(params[:id]) -# stream_for post +# class CommentsChannel < ApplicationCable::Channel +# def subscribed +# post = Post.find(params[:id]) +# stream_for post +# end # end -# end # # You can then broadcast to this channel using: # -# CommentsChannel.broadcast_to(@post, @comment) +# CommentsChannel.broadcast_to(@post, @comment) # -# If you don't just want to parlay the broadcast unfiltered to the subscriber, you can also supply a callback that lets you alter what is sent out. -# The below example shows how you can use this to provide performance introspection in the process: +# If you don't just want to parlay the broadcast unfiltered to the subscriber, +# you can also supply a callback that lets you alter what is sent out. The below +# example shows how you can use this to provide performance introspection in the +# process: # -# class ChatChannel < ApplicationCable::Channel -# def subscribed -# @room = Chat::Room[params[:room_number]] +# class ChatChannel < ApplicationCable::Channel +# def subscribed +# @room = Chat::Room[params[:room_number]] # -# stream_for @room, coder: ActiveSupport::JSON do |message| -# if message['originated_at'].present? -# elapsed_time = (Time.now.to_f - message['originated_at']).round(2) +# stream_for @room, coder: ActiveSupport::JSON do |message| +# if message['originated_at'].present? +# elapsed_time = (Time.now.to_f - message['originated_at']).round(2) # -# ActiveSupport::Notifications.instrument :performance, measurement: 'Chat.message_delay', value: elapsed_time, action: :timing -# logger.info "Message took #{elapsed_time}s to arrive" -# end +# ActiveSupport::Notifications.instrument :performance, measurement: 'Chat.message_delay', value: elapsed_time, action: :timing +# logger.info "Message took #{elapsed_time}s to arrive" +# end # -# transmit message +# transmit message +# end # end # end -# end # # You can stop streaming from all broadcasts by calling #stop_all_streams. # -# source://actioncable//lib/action_cable/channel/streams.rb#65 +# source://actioncable//lib/action_cable/channel/streams.rb#77 module ActionCable::Channel::Streams extend ::ActiveSupport::Concern - # source://actioncable//lib/action_cable/channel/streams.rb#138 + # source://actioncable//lib/action_cable/channel/streams.rb#153 def pubsub(*_arg0, **_arg1, &_arg2); end # Unsubscribes all streams associated with this channel from the pubsub queue. # - # source://actioncable//lib/action_cable/channel/streams.rb#120 + # source://actioncable//lib/action_cable/channel/streams.rb#135 def stop_all_streams; end - # Unsubscribes streams for the model. + # Unsubscribes streams for the `model`. # - # source://actioncable//lib/action_cable/channel/streams.rb#115 + # source://actioncable//lib/action_cable/channel/streams.rb#130 def stop_stream_for(model); end - # Unsubscribes streams from the named broadcasting. + # Unsubscribes streams from the named `broadcasting`. # - # source://actioncable//lib/action_cable/channel/streams.rb#106 + # source://actioncable//lib/action_cable/channel/streams.rb#121 def stop_stream_from(broadcasting); end - # Start streaming the pubsub queue for the model in this channel. Optionally, you can pass a - # callback that'll be used instead of the default of just transmitting the updates straight - # to the subscriber. + # Start streaming the pubsub queue for the `model` in this channel. Optionally, + # you can pass a `callback` that'll be used instead of the default of just + # transmitting the updates straight to the subscriber. # - # Pass coder: ActiveSupport::JSON to decode messages as JSON before passing to the callback. - # Defaults to coder: nil which does no decoding, passes raw messages. + # Pass `coder: ActiveSupport::JSON` to decode messages as JSON before passing to + # the callback. Defaults to `coder: nil` which does no decoding, passes raw + # messages. # - # source://actioncable//lib/action_cable/channel/streams.rb#101 + # source://actioncable//lib/action_cable/channel/streams.rb#116 def stream_for(model, callback = T.unsafe(nil), coder: T.unsafe(nil), &block); end - # Start streaming from the named broadcasting pubsub queue. Optionally, you can pass a callback that'll be used - # instead of the default of just transmitting the updates straight to the subscriber. - # Pass coder: ActiveSupport::JSON to decode messages as JSON before passing to the callback. - # Defaults to coder: nil which does no decoding, passes raw messages. + # Start streaming from the named `broadcasting` pubsub queue. Optionally, you + # can pass a `callback` that'll be used instead of the default of just + # transmitting the updates straight to the subscriber. Pass `coder: + # ActiveSupport::JSON` to decode messages as JSON before passing to the + # callback. Defaults to `coder: nil` which does no decoding, passes raw + # messages. # - # source://actioncable//lib/action_cable/channel/streams.rb#76 + # source://actioncable//lib/action_cable/channel/streams.rb#90 def stream_from(broadcasting, callback = T.unsafe(nil), coder: T.unsafe(nil), &block); end - # Calls stream_for with the given model if it's present to start streaming, + # Calls stream_for with the given `model` if it's present to start streaming, # otherwise rejects the subscription. # - # source://actioncable//lib/action_cable/channel/streams.rb#129 + # source://actioncable//lib/action_cable/channel/streams.rb#144 def stream_or_reject_for(model); end private - # May be overridden to change the default stream handling behavior - # which decodes JSON and transmits to the client. + # May be overridden to change the default stream handling behavior which decodes + # JSON and transmits to the client. # # TODO: Tests demonstrating this. # - # TODO: Room for optimization. Update transmit API to be coder-aware - # so we can no-op when pubsub and connection are both JSON-encoded. - # Then we can skip decode+encode if we're just proxying messages. + # TODO: Room for optimization. Update transmit API to be coder-aware so we can + # no-op when pubsub and connection are both JSON-encoded. Then we can skip + # decode+encode if we're just proxying messages. # - # source://actioncable//lib/action_cable/channel/streams.rb#174 + # source://actioncable//lib/action_cable/channel/streams.rb#189 def default_stream_handler(broadcasting, coder:); end - # source://actioncable//lib/action_cable/channel/streams.rb#195 + # source://actioncable//lib/action_cable/channel/streams.rb#210 def identity_handler; end - # source://actioncable//lib/action_cable/channel/streams.rb#179 + # source://actioncable//lib/action_cable/channel/streams.rb#194 def stream_decoder(handler = T.unsafe(nil), coder:); end - # May be overridden to add instrumentation, logging, specialized error - # handling, or other forms of handler decoration. + # May be overridden to add instrumentation, logging, specialized error handling, + # or other forms of handler decoration. # # TODO: Tests demonstrating this. # - # source://actioncable//lib/action_cable/channel/streams.rb#158 + # source://actioncable//lib/action_cable/channel/streams.rb#173 def stream_handler(broadcasting, user_handler, coder: T.unsafe(nil)); end - # source://actioncable//lib/action_cable/channel/streams.rb#187 + # source://actioncable//lib/action_cable/channel/streams.rb#202 def stream_transmitter(handler = T.unsafe(nil), broadcasting:); end - # source://actioncable//lib/action_cable/channel/streams.rb#140 + # source://actioncable//lib/action_cable/channel/streams.rb#155 def streams; end - # Always wrap the outermost handler to invoke the user handler on the - # worker pool rather than blocking the event loop. + # Always wrap the outermost handler to invoke the user handler on the worker + # pool rather than blocking the event loop. # - # source://actioncable//lib/action_cable/channel/streams.rb#146 + # source://actioncable//lib/action_cable/channel/streams.rb#161 def worker_pool_stream_handler(broadcasting, user_handler, coder: T.unsafe(nil)); end end # Superclass for Action Cable channel functional tests. # -# == Basic example +# ## Basic example # # Functional tests are written as follows: -# 1. First, one uses the +subscribe+ method to simulate subscription creation. -# 2. Then, one asserts whether the current state is as expected. "State" can be anything: -# transmitted messages, subscribed streams, etc. +# 1. First, one uses the `subscribe` method to simulate subscription creation. +# 2. Then, one asserts whether the current state is as expected. "State" can be +# anything: transmitted messages, subscribed streams, etc. +# # # For example: # -# class ChatChannelTest < ActionCable::Channel::TestCase -# def test_subscribed_with_room_number -# # Simulate a subscription creation -# subscribe room_number: 1 +# class ChatChannelTest < ActionCable::Channel::TestCase +# def test_subscribed_with_room_number +# # Simulate a subscription creation +# subscribe room_number: 1 # -# # Asserts that the subscription was successfully created -# assert subscription.confirmed? +# # Asserts that the subscription was successfully created +# assert subscription.confirmed? # -# # Asserts that the channel subscribes connection to a stream -# assert_has_stream "chat_1" +# # Asserts that the channel subscribes connection to a stream +# assert_has_stream "chat_1" # -# # Asserts that the channel subscribes connection to a specific -# # stream created for a model -# assert_has_stream_for Room.find(1) -# end +# # Asserts that the channel subscribes connection to a specific +# # stream created for a model +# assert_has_stream_for Room.find(1) +# end # -# def test_does_not_stream_with_incorrect_room_number -# subscribe room_number: -1 +# def test_does_not_stream_with_incorrect_room_number +# subscribe room_number: -1 # -# # Asserts that not streams was started -# assert_no_streams -# end +# # Asserts that not streams was started +# assert_no_streams +# end # -# def test_does_not_subscribe_without_room_number -# subscribe +# def test_does_not_subscribe_without_room_number +# subscribe # -# # Asserts that the subscription was rejected -# assert subscription.rejected? +# # Asserts that the subscription was rejected +# assert subscription.rejected? +# end # end -# end # # You can also perform actions: -# def test_perform_speak -# subscribe room_number: 1 +# def test_perform_speak +# subscribe room_number: 1 +# +# perform :speak, message: "Hello, Rails!" +# +# assert_equal "Hello, Rails!", transmissions.last["text"] +# end # -# perform :speak, message: "Hello, Rails!" +# ## Special methods # -# assert_equal "Hello, Rails!", transmissions.last["text"] -# end +# ActionCable::Channel::TestCase will also automatically provide the following +# instance methods for use in the tests: # -# == Special methods +# connection +# : An ActionCable::Channel::ConnectionStub, representing the current HTTP +# connection. # -# ActionCable::Channel::TestCase will also automatically provide the following instance -# methods for use in the tests: +# subscription +# : An instance of the current channel, created when you call `subscribe`. # -# connection:: -# An ActionCable::Channel::ConnectionStub, representing the current HTTP connection. -# subscription:: -# An instance of the current channel, created when you call +subscribe+. -# transmissions:: -# A list of all messages that have been transmitted into the channel. +# transmissions +# : A list of all messages that have been transmitted into the channel. # # -# == Channel is automatically inferred +# ## Channel is automatically inferred # # ActionCable::Channel::TestCase will automatically infer the channel under test # from the test class name. If the channel cannot be inferred from the test -# class name, you can explicitly set it with +tests+. -# -# class SpecialEdgeCaseChannelTest < ActionCable::Channel::TestCase -# tests SpecialChannel -# end +# class name, you can explicitly set it with `tests`. # -# == Specifying connection identifiers +# class SpecialEdgeCaseChannelTest < ActionCable::Channel::TestCase +# tests SpecialChannel +# end # -# You need to set up your connection manually to provide values for the identifiers. -# To do this just use: +# ## Specifying connection identifiers # -# stub_connection(user: users(:john)) +# You need to set up your connection manually to provide values for the +# identifiers. To do this just use: # -# == Testing broadcasting +# stub_connection(user: users(:john)) # -# ActionCable::Channel::TestCase enhances ActionCable::TestHelper assertions (e.g. -# +assert_broadcasts+) to handle broadcasting to models: +# ## Testing broadcasting # +# ActionCable::Channel::TestCase enhances ActionCable::TestHelper assertions +# (e.g. `assert_broadcasts`) to handle broadcasting to models: # -# # in your channel -# def speak(data) -# broadcast_to room, text: data["message"] -# end +# # in your channel +# def speak(data) +# broadcast_to room, text: data["message"] +# end # -# def test_speak -# subscribe room_id: rooms(:chat).id +# def test_speak +# subscribe room_id: rooms(:chat).id # -# assert_broadcast_on(rooms(:chat), text: "Hello, Rails!") do -# perform :speak, message: "Hello, Rails!" -# end -# end +# assert_broadcast_on(rooms(:chat), text: "Hello, Rails!") do +# perform :speak, message: "Hello, Rails!" +# end +# end # -# source://actioncable//lib/action_cable/channel/test_case.rb#181 +# source://actioncable//lib/action_cable/channel/test_case.rb#190 class ActionCable::Channel::TestCase < ::ActiveSupport::TestCase include ::ActiveSupport::Testing::ConstantLookup - include ::ActionCable::TestHelper include ::ActionCable::Channel::TestCase::Behavior extend ::ActiveSupport::Testing::ConstantLookup::ClassMethods extend ::ActionCable::Channel::TestCase::Behavior::ClassMethods - # source://actioncable//lib/action_cable/channel/test_case.rb#191 + # source://actioncable//lib/action_cable/channel/test_case.rb#200 def _channel_class; end - # source://actioncable//lib/action_cable/channel/test_case.rb#191 + # source://actioncable//lib/action_cable/channel/test_case.rb#200 def _channel_class=(_arg0); end - # source://actioncable//lib/action_cable/channel/test_case.rb#191 + # source://actioncable//lib/action_cable/channel/test_case.rb#200 def _channel_class?; end - # source://actioncable//lib/action_cable/channel/test_case.rb#193 + # source://actioncable//lib/action_cable/channel/test_case.rb#202 def connection; end - # source://actioncable//lib/action_cable/channel/test_case.rb#193 + # source://actioncable//lib/action_cable/channel/test_case.rb#202 def subscription; end class << self - # source://actioncable//lib/action_cable/channel/test_case.rb#191 + # source://actioncable//lib/action_cable/channel/test_case.rb#200 def _channel_class; end - # source://actioncable//lib/action_cable/channel/test_case.rb#191 + # source://actioncable//lib/action_cable/channel/test_case.rb#200 def _channel_class=(value); end - # source://actioncable//lib/action_cable/channel/test_case.rb#191 + # source://actioncable//lib/action_cable/channel/test_case.rb#200 def _channel_class?; end end end -# source://actioncable//lib/action_cable/channel/test_case.rb#182 +# source://actioncable//lib/action_cable/channel/test_case.rb#191 module ActionCable::Channel::TestCase::Behavior include ::ActionCable::TestHelper extend ::ActiveSupport::Concern @@ -888,84 +978,104 @@ module ActionCable::Channel::TestCase::Behavior mixes_in_class_methods ::ActiveSupport::Testing::ConstantLookup::ClassMethods mixes_in_class_methods ::ActionCable::Channel::TestCase::Behavior::ClassMethods - # source://actioncable//lib/action_cable/channel/test_case.rb#273 + # source://actioncable//lib/action_cable/channel/test_case.rb#282 def assert_broadcast_on(stream_or_object, *args); end - # Enhance TestHelper assertions to handle non-String - # broadcastings + # Enhance TestHelper assertions to handle non-String broadcastings # - # source://actioncable//lib/action_cable/channel/test_case.rb#269 + # source://actioncable//lib/action_cable/channel/test_case.rb#278 def assert_broadcasts(stream_or_object, *args); end + # Asserts that the specified stream has not been started. + # + # def test_assert_no_started_stream + # subscribe + # assert_has_no_stream 'messages' + # end + # + # source://actioncable//lib/action_cable/channel/test_case.rb#326 + def assert_has_no_stream(stream); end + + # Asserts that the specified stream for a model has not started. + # + # def test_assert_no_started_stream_for + # subscribe id: 41 + # assert_has_no_stream_for User.find(42) + # end + # + # source://actioncable//lib/action_cable/channel/test_case.rb#337 + def assert_has_no_stream_for(object); end + # Asserts that the specified stream has been started. # - # def test_assert_started_stream - # subscribe - # assert_has_stream 'messages' - # end + # def test_assert_started_stream + # subscribe + # assert_has_stream 'messages' + # end # - # source://actioncable//lib/action_cable/channel/test_case.rb#295 + # source://actioncable//lib/action_cable/channel/test_case.rb#304 def assert_has_stream(stream); end # Asserts that the specified stream for a model has started. # - # def test_assert_started_stream_for - # subscribe id: 42 - # assert_has_stream_for User.find(42) - # end + # def test_assert_started_stream_for + # subscribe id: 42 + # assert_has_stream_for User.find(42) + # end # - # source://actioncable//lib/action_cable/channel/test_case.rb#306 + # source://actioncable//lib/action_cable/channel/test_case.rb#315 def assert_has_stream_for(object); end # Asserts that no streams have been started. # - # def test_assert_no_started_stream - # subscribe - # assert_no_streams - # end + # def test_assert_no_started_stream + # subscribe + # assert_no_streams + # end # - # source://actioncable//lib/action_cable/channel/test_case.rb#284 + # source://actioncable//lib/action_cable/channel/test_case.rb#293 def assert_no_streams; end # Perform action on a channel. # # NOTE: Must be subscribed. # - # source://actioncable//lib/action_cable/channel/test_case.rb#256 + # source://actioncable//lib/action_cable/channel/test_case.rb#266 def perform(action, data = T.unsafe(nil)); end # Set up test connection with the specified identifiers: # - # class ApplicationCable < ActionCable::Connection::Base - # identified_by :user, :token - # end + # class ApplicationCable < ActionCable::Connection::Base + # identified_by :user, :token + # end # - # stub_connection(user: users[:john], token: 'my-secret-token') + # stub_connection(user: users[:john], token: 'my-secret-token') # - # source://actioncable//lib/action_cable/channel/test_case.rb#234 + # source://actioncable//lib/action_cable/channel/test_case.rb#243 def stub_connection(identifiers = T.unsafe(nil)); end - # Subscribe to the channel under test. Optionally pass subscription parameters as a Hash. + # Subscribe to the channel under test. Optionally pass subscription parameters + # as a Hash. # - # source://actioncable//lib/action_cable/channel/test_case.rb#239 + # source://actioncable//lib/action_cable/channel/test_case.rb#249 def subscribe(params = T.unsafe(nil)); end # Returns messages transmitted into channel # - # source://actioncable//lib/action_cable/channel/test_case.rb#262 + # source://actioncable//lib/action_cable/channel/test_case.rb#272 def transmissions; end # Unsubscribe the subscription under test. # - # source://actioncable//lib/action_cable/channel/test_case.rb#248 + # source://actioncable//lib/action_cable/channel/test_case.rb#258 def unsubscribe; end private - # source://actioncable//lib/action_cable/channel/test_case.rb#315 + # source://actioncable//lib/action_cable/channel/test_case.rb#346 def broadcasting_for(stream_or_object); end - # source://actioncable//lib/action_cable/channel/test_case.rb#311 + # source://actioncable//lib/action_cable/channel/test_case.rb#342 def check_subscribed!; end module GeneratedClassMethods @@ -981,381 +1091,498 @@ module ActionCable::Channel::TestCase::Behavior end end -# source://actioncable//lib/action_cable/channel/test_case.rb#188 +# source://actioncable//lib/action_cable/channel/test_case.rb#197 ActionCable::Channel::TestCase::Behavior::CHANNEL_IDENTIFIER = T.let(T.unsafe(nil), String) -# source://actioncable//lib/action_cable/channel/test_case.rb#198 +# source://actioncable//lib/action_cable/channel/test_case.rb#207 module ActionCable::Channel::TestCase::Behavior::ClassMethods - # source://actioncable//lib/action_cable/channel/test_case.rb#210 + # source://actioncable//lib/action_cable/channel/test_case.rb#219 def channel_class; end # @raise [NonInferrableChannelError] # - # source://actioncable//lib/action_cable/channel/test_case.rb#218 + # source://actioncable//lib/action_cable/channel/test_case.rb#227 def determine_default_channel(name); end - # source://actioncable//lib/action_cable/channel/test_case.rb#199 + # source://actioncable//lib/action_cable/channel/test_case.rb#208 def tests(channel); end end -# source://actioncable//lib/action_cable/connection.rb#4 -module ActionCable::Connection - extend ::ActiveSupport::Autoload -end +# source://actioncable//lib/action_cable/connection/identification.rb#8 +module ActionCable::Connection; end -# source://actioncable//lib/action_cable/connection/test_case.rb#20 +# source://actioncable//lib/action_cable/connection/test_case.rb#22 module ActionCable::Connection::Assertions - # Asserts that the connection is rejected (via +reject_unauthorized_connection+). + # Asserts that the connection is rejected (via + # `reject_unauthorized_connection`). # - # # Asserts that connection without user_id fails - # assert_reject_connection { connect params: { user_id: '' } } + # # Asserts that connection without user_id fails + # assert_reject_connection { connect params: { user_id: '' } } # - # source://actioncable//lib/action_cable/connection/test_case.rb#25 + # source://actioncable//lib/action_cable/connection/test_case.rb#28 def assert_reject_connection(&block); end end -# source://actioncable//lib/action_cable/connection/authorization.rb#5 +# source://actioncable//lib/action_cable/connection/authorization.rb#7 module ActionCable::Connection::Authorization - # Closes the WebSocket connection if it is open and returns a 404 "File not Found" response. + # Closes the WebSocket connection if it is open and returns an "unauthorized" + # reason. # # @raise [UnauthorizedError] # - # source://actioncable//lib/action_cable/connection/authorization.rb#9 + # source://actioncable//lib/action_cable/connection/authorization.rb#12 def reject_unauthorized_connection; end end -# source://actioncable//lib/action_cable/connection/authorization.rb#6 +# source://actioncable//lib/action_cable/connection/authorization.rb#8 class ActionCable::Connection::Authorization::UnauthorizedError < ::StandardError; end -# For every WebSocket connection the Action Cable server accepts, a Connection object will be instantiated. This instance becomes the parent -# of all of the channel subscriptions that are created from there on. Incoming messages are then routed to these channel subscriptions -# based on an identifier sent by the Action Cable consumer. The Connection itself does not deal with any specific application logic beyond -# authentication and authorization. +# # Action Cable Connection Base # -# Here's a basic example: +# For every WebSocket connection the Action Cable server accepts, a Connection +# object will be instantiated. This instance becomes the parent of all of the +# channel subscriptions that are created from there on. Incoming messages are +# then routed to these channel subscriptions based on an identifier sent by the +# Action Cable consumer. The Connection itself does not deal with any specific +# application logic beyond authentication and authorization. # -# module ApplicationCable -# class Connection < ActionCable::Connection::Base -# identified_by :current_user +# Here's a basic example: # -# def connect -# self.current_user = find_verified_user -# logger.add_tags current_user.name -# end +# module ApplicationCable +# class Connection < ActionCable::Connection::Base +# identified_by :current_user # -# def disconnect -# # Any cleanup work needed when the cable connection is cut. -# end +# def connect +# self.current_user = find_verified_user +# logger.add_tags current_user.name +# end # -# private -# def find_verified_user -# User.find_by_identity(cookies.encrypted[:identity_id]) || -# reject_unauthorized_connection +# def disconnect +# # Any cleanup work needed when the cable connection is cut. # end +# +# private +# def find_verified_user +# User.find_by_identity(cookies.encrypted[:identity_id]) || +# reject_unauthorized_connection +# end +# end # end -# end # -# First, we declare that this connection can be identified by its current_user. This allows us to later be able to find all connections -# established for that current_user (and potentially disconnect them). You can declare as many -# identification indexes as you like. Declaring an identification means that an attr_accessor is automatically set for that key. +# First, we declare that this connection can be identified by its current_user. +# This allows us to later be able to find all connections established for that +# current_user (and potentially disconnect them). You can declare as many +# identification indexes as you like. Declaring an identification means that an +# attr_accessor is automatically set for that key. # -# Second, we rely on the fact that the WebSocket connection is established with the cookies from the domain being sent along. This makes -# it easy to use signed cookies that were set when logging in via a web interface to authorize the WebSocket connection. +# Second, we rely on the fact that the WebSocket connection is established with +# the cookies from the domain being sent along. This makes it easy to use signed +# cookies that were set when logging in via a web interface to authorize the +# WebSocket connection. # -# Finally, we add a tag to the connection-specific logger with the name of the current user to easily distinguish their messages in the log. +# Finally, we add a tag to the connection-specific logger with the name of the +# current user to easily distinguish their messages in the log. # # Pretty simple, eh? # -# source://actioncable//lib/action_cable/connection/base.rb#46 +# source://actioncable//lib/action_cable/connection/base.rb#57 class ActionCable::Connection::Base include ::ActionCable::Connection::Identification include ::ActionCable::Connection::InternalChannel include ::ActionCable::Connection::Authorization + include ::ActiveSupport::Callbacks + include ::ActionCable::Connection::Callbacks include ::ActiveSupport::Rescuable extend ::ActionCable::Connection::Identification::ClassMethods + extend ::ActiveSupport::Callbacks::ClassMethods + extend ::ActiveSupport::DescendantsTracker + extend ::ActionCable::Connection::Callbacks::ClassMethods extend ::ActiveSupport::Rescuable::ClassMethods # @return [Base] a new instance of Base # - # source://actioncable//lib/action_cable/connection/base.rb#55 + # source://actioncable//lib/action_cable/connection/base.rb#67 def initialize(server, env, coder: T.unsafe(nil)); end - # source://actioncable//lib/action_cable/connection/base.rb#125 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _command_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_command_callbacks(&block); end + + # source://actioncable//lib/action_cable/connection/base.rb#147 def beat; end # Close the WebSocket connection. # - # source://actioncable//lib/action_cable/connection/base.rb#100 + # source://actioncable//lib/action_cable/connection/base.rb#120 def close(reason: T.unsafe(nil), reconnect: T.unsafe(nil)); end - # source://actioncable//lib/action_cable/connection/base.rb#87 + # source://actioncable//lib/action_cable/connection/base.rb#65 + def config(*_arg0, **_arg1, &_arg2); end + + # source://actioncable//lib/action_cable/connection/base.rb#101 def dispatch_websocket_message(websocket_message); end # Returns the value of attribute env. # - # source://actioncable//lib/action_cable/connection/base.rb#52 + # source://actioncable//lib/action_cable/connection/base.rb#64 def env; end - # source://actioncable//lib/action_cable/connection/base.rb#53 + # source://actioncable//lib/action_cable/connection/base.rb#65 def event_loop(*_arg0, **_arg1, &_arg2); end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/base.rb#109 + def handle_channel_command(payload); end + + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers; end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers=(_arg0); end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers?; end + # source://actioncable//lib/action_cable/connection/base.rb#168 + def inspect; end + # Returns the value of attribute logger. # - # source://actioncable//lib/action_cable/connection/base.rb#52 + # source://actioncable//lib/action_cable/connection/base.rb#64 def logger; end - # source://actioncable//lib/action_cable/connection/base.rb#142 + # source://actioncable//lib/action_cable/connection/base.rb#164 def on_close(reason, code); end - # source://actioncable//lib/action_cable/connection/base.rb#137 + # source://actioncable//lib/action_cable/connection/base.rb#159 def on_error(message); end - # source://actioncable//lib/action_cable/connection/base.rb#133 + # source://actioncable//lib/action_cable/connection/base.rb#155 def on_message(message); end - # source://actioncable//lib/action_cable/connection/base.rb#129 + # source://actioncable//lib/action_cable/connection/base.rb#151 def on_open; end - # Called by the server when a new WebSocket connection is established. This configures the callbacks intended for overwriting by the user. - # This method should not be called directly -- instead rely upon on the #connect (and #disconnect) callbacks. + # Called by the server when a new WebSocket connection is established. This + # configures the callbacks intended for overwriting by the user. This method + # should not be called directly -- instead rely upon on the #connect (and + # #disconnect) callbacks. # - # source://actioncable//lib/action_cable/connection/base.rb#71 + # source://actioncable//lib/action_cable/connection/base.rb#85 def process; end # Returns the value of attribute protocol. # - # source://actioncable//lib/action_cable/connection/base.rb#52 + # source://actioncable//lib/action_cable/connection/base.rb#64 def protocol; end - # source://actioncable//lib/action_cable/connection/base.rb#53 + # source://actioncable//lib/action_cable/connection/base.rb#65 def pubsub(*_arg0, **_arg1, &_arg2); end # Decodes WebSocket messages and dispatches them to subscribed channels. # WebSocket message transfer encoding is always JSON. # - # source://actioncable//lib/action_cable/connection/base.rb#83 + # source://actioncable//lib/action_cable/connection/base.rb#97 def receive(websocket_message); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # Invoke a method on the connection asynchronously through the pool of thread workers. + # Invoke a method on the connection asynchronously through the pool of thread + # workers. # - # source://actioncable//lib/action_cable/connection/base.rb#110 + # source://actioncable//lib/action_cable/connection/base.rb#131 def send_async(method, *arguments); end # Returns the value of attribute server. # - # source://actioncable//lib/action_cable/connection/base.rb#52 + # source://actioncable//lib/action_cable/connection/base.rb#64 def server; end - # Return a basic hash of statistics for the connection keyed with identifier, started_at, subscriptions, and request_id. - # This can be returned by a health check against the connection. + # Return a basic hash of statistics for the connection keyed with `identifier`, + # `started_at`, `subscriptions`, and `request_id`. This can be returned by a + # health check against the connection. # - # source://actioncable//lib/action_cable/connection/base.rb#116 + # source://actioncable//lib/action_cable/connection/base.rb#138 def statistics; end # Returns the value of attribute subscriptions. # - # source://actioncable//lib/action_cable/connection/base.rb#52 + # source://actioncable//lib/action_cable/connection/base.rb#64 def subscriptions; end - # source://actioncable//lib/action_cable/connection/base.rb#95 + # source://actioncable//lib/action_cable/connection/base.rb#115 def transmit(cable_message); end # Returns the value of attribute worker_pool. # - # source://actioncable//lib/action_cable/connection/base.rb#52 + # source://actioncable//lib/action_cable/connection/base.rb#64 def worker_pool; end private # @return [Boolean] # - # source://actioncable//lib/action_cable/connection/base.rb#201 + # source://actioncable//lib/action_cable/connection/base.rb#228 def allow_request_origin?; end - # The cookies of the request that initiated the WebSocket connection. Useful for performing authorization checks. + # The cookies of the request that initiated the WebSocket connection. Useful for + # performing authorization checks. # - # source://actioncable//lib/action_cable/connection/base.rb#159 + # source://actioncable//lib/action_cable/connection/base.rb#187 def cookies; end - # source://actioncable//lib/action_cable/connection/base.rb#167 + # source://actioncable//lib/action_cable/connection/base.rb#195 def decode(websocket_message); end - # source://actioncable//lib/action_cable/connection/base.rb#163 + # source://actioncable//lib/action_cable/connection/base.rb#191 def encode(cable_message); end - # source://actioncable//lib/action_cable/connection/base.rb#243 + # source://actioncable//lib/action_cable/connection/base.rb#271 def finished_request_message; end - # source://actioncable//lib/action_cable/connection/base.rb#183 + # source://actioncable//lib/action_cable/connection/base.rb#211 def handle_close; end - # source://actioncable//lib/action_cable/connection/base.rb#171 + # source://actioncable//lib/action_cable/connection/base.rb#199 def handle_open; end - # source://actioncable//lib/action_cable/connection/base.rb#251 + # source://actioncable//lib/action_cable/connection/base.rb#279 def invalid_request_message; end # Returns the value of attribute message_buffer. # - # source://actioncable//lib/action_cable/connection/base.rb#148 + # source://actioncable//lib/action_cable/connection/base.rb#174 def message_buffer; end - # Tags are declared in the server but computed in the connection. This allows us per-connection tailored tags. + # Tags are declared in the server but computed in the connection. This allows us + # per-connection tailored tags. # - # source://actioncable//lib/action_cable/connection/base.rb#229 + # source://actioncable//lib/action_cable/connection/base.rb#257 def new_tagged_logger; end - # The request that initiated the WebSocket connection is available here. This gives access to the environment, cookies, etc. + # The request that initiated the WebSocket connection is available here. This + # gives access to the environment, cookies, etc. # - # source://actioncable//lib/action_cable/connection/base.rb#151 + # source://actioncable//lib/action_cable/connection/base.rb#178 def request; end - # source://actioncable//lib/action_cable/connection/base.rb#220 + # source://actioncable//lib/action_cable/connection/base.rb#247 def respond_to_invalid_request; end - # source://actioncable//lib/action_cable/connection/base.rb#215 + # source://actioncable//lib/action_cable/connection/base.rb#242 def respond_to_successful_request; end - # source://actioncable//lib/action_cable/connection/base.rb#194 + # source://actioncable//lib/action_cable/connection/base.rb#222 def send_welcome_message; end - # source://actioncable//lib/action_cable/connection/base.rb#234 + # source://actioncable//lib/action_cable/connection/base.rb#262 def started_request_message; end - # source://actioncable//lib/action_cable/connection/base.rb#257 + # source://actioncable//lib/action_cable/connection/base.rb#285 def successful_request_message; end # Returns the value of attribute websocket. # - # source://actioncable//lib/action_cable/connection/base.rb#147 + # source://actioncable//lib/action_cable/connection/base.rb#173 def websocket; end class << self - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _command_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _command_callbacks=(value); end + + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers; end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers=(value); end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers?; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end end end -# source://actioncable//lib/action_cable/connection/client_socket.rb#11 +# # Action Cable Connection Callbacks +# +# The [before_command](rdoc-ref:ClassMethods#before_command), +# [after_command](rdoc-ref:ClassMethods#after_command), and +# [around_command](rdoc-ref:ClassMethods#around_command) callbacks are invoked +# when sending commands to the client, such as when subscribing, unsubscribing, +# or performing an action. +# +# #### Example +# +# module ApplicationCable +# class Connection < ActionCable::Connection::Base +# identified_by :user +# +# around_command :set_current_account +# +# private +# +# def set_current_account +# # Now all channels could use Current.account +# Current.set(account: user.account) { yield } +# end +# end +# end +# +# source://actioncable//lib/action_cable/connection/callbacks.rb#34 +module ActionCable::Connection::Callbacks + extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + include ::ActiveSupport::Callbacks + + mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActiveSupport::Callbacks::ClassMethods + mixes_in_class_methods ::ActiveSupport::DescendantsTracker + mixes_in_class_methods ::ActionCable::Connection::Callbacks::ClassMethods + + module GeneratedClassMethods + def __callbacks; end + def __callbacks=(value); end + def __callbacks?; end + end + + module GeneratedInstanceMethods + def __callbacks; end + def __callbacks?; end + end +end + +# source://actioncable//lib/action_cable/connection/callbacks.rb#42 +module ActionCable::Connection::Callbacks::ClassMethods + # source://actioncable//lib/action_cable/connection/callbacks.rb#47 + def after_command(*methods, &block); end + + # source://actioncable//lib/action_cable/connection/callbacks.rb#51 + def around_command(*methods, &block); end + + # source://actioncable//lib/action_cable/connection/callbacks.rb#43 + def before_command(*methods, &block); end +end + +# source://actioncable//lib/action_cable/connection/client_socket.rb#13 class ActionCable::Connection::ClientSocket # @return [ClientSocket] a new instance of ClientSocket # - # source://actioncable//lib/action_cable/connection/client_socket.rb#34 + # source://actioncable//lib/action_cable/connection/client_socket.rb#36 def initialize(env, event_target, event_loop, protocols); end # @return [Boolean] # - # source://actioncable//lib/action_cable/connection/client_socket.rb#112 + # source://actioncable//lib/action_cable/connection/client_socket.rb#114 def alive?; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#108 + # source://actioncable//lib/action_cable/connection/client_socket.rb#110 def client_gone; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#90 + # source://actioncable//lib/action_cable/connection/client_socket.rb#92 def close(code = T.unsafe(nil), reason = T.unsafe(nil)); end # Returns the value of attribute env. # - # source://actioncable//lib/action_cable/connection/client_socket.rb#32 + # source://actioncable//lib/action_cable/connection/client_socket.rb#34 def env; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#104 + # source://actioncable//lib/action_cable/connection/client_socket.rb#106 def parse(data); end - # source://actioncable//lib/action_cable/connection/client_socket.rb#116 + # source://actioncable//lib/action_cable/connection/client_socket.rb#118 def protocol; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#69 + # source://actioncable//lib/action_cable/connection/client_socket.rb#71 def rack_response; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#57 + # source://actioncable//lib/action_cable/connection/client_socket.rb#59 def start_driver; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#80 + # source://actioncable//lib/action_cable/connection/client_socket.rb#82 def transmit(message); end # Returns the value of attribute url. # - # source://actioncable//lib/action_cable/connection/client_socket.rb#32 + # source://actioncable//lib/action_cable/connection/client_socket.rb#34 def url; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#74 + # source://actioncable//lib/action_cable/connection/client_socket.rb#76 def write(data); end private - # source://actioncable//lib/action_cable/connection/client_socket.rb#140 + # source://actioncable//lib/action_cable/connection/client_socket.rb#142 def begin_close(reason, code); end - # source://actioncable//lib/action_cable/connection/client_socket.rb#134 + # source://actioncable//lib/action_cable/connection/client_socket.rb#136 def emit_error(message); end - # source://actioncable//lib/action_cable/connection/client_socket.rb#149 + # source://actioncable//lib/action_cable/connection/client_socket.rb#151 def finalize_close; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#121 + # source://actioncable//lib/action_cable/connection/client_socket.rb#123 def open; end - # source://actioncable//lib/action_cable/connection/client_socket.rb#128 + # source://actioncable//lib/action_cable/connection/client_socket.rb#130 def receive_message(data); end class << self - # source://actioncable//lib/action_cable/connection/client_socket.rb#12 + # source://actioncable//lib/action_cable/connection/client_socket.rb#14 def determine_url(env); end # @return [Boolean] # - # source://actioncable//lib/action_cable/connection/client_socket.rb#17 + # source://actioncable//lib/action_cable/connection/client_socket.rb#19 def secure_request?(env); end end end -# source://actioncable//lib/action_cable/connection/client_socket.rb#30 +# source://actioncable//lib/action_cable/connection/client_socket.rb#32 ActionCable::Connection::ClientSocket::CLOSED = T.let(T.unsafe(nil), Integer) -# source://actioncable//lib/action_cable/connection/client_socket.rb#29 +# source://actioncable//lib/action_cable/connection/client_socket.rb#31 ActionCable::Connection::ClientSocket::CLOSING = T.let(T.unsafe(nil), Integer) -# source://actioncable//lib/action_cable/connection/client_socket.rb#27 +# source://actioncable//lib/action_cable/connection/client_socket.rb#29 ActionCable::Connection::ClientSocket::CONNECTING = T.let(T.unsafe(nil), Integer) -# source://actioncable//lib/action_cable/connection/client_socket.rb#28 +# source://actioncable//lib/action_cable/connection/client_socket.rb#30 ActionCable::Connection::ClientSocket::OPEN = T.let(T.unsafe(nil), Integer) -# source://actioncable//lib/action_cable/connection/identification.rb#7 +# source://actioncable//lib/action_cable/connection/identification.rb#9 module ActionCable::Connection::Identification extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -1363,14 +1590,15 @@ module ActionCable::Connection::Identification mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActionCable::Connection::Identification::ClassMethods - # Return a single connection identifier that combines the value of all the registered identifiers into a single gid. + # Return a single connection identifier that combines the value of all the + # registered identifiers into a single gid. # - # source://actioncable//lib/action_cable/connection/identification.rb#27 + # source://actioncable//lib/action_cable/connection/identification.rb#31 def connection_identifier; end private - # source://actioncable//lib/action_cable/connection/identification.rb#36 + # source://actioncable//lib/action_cable/connection/identification.rb#40 def connection_gid(ids); end module GeneratedClassMethods @@ -1386,91 +1614,96 @@ module ActionCable::Connection::Identification end end -# source://actioncable//lib/action_cable/connection/identification.rb#14 +# source://actioncable//lib/action_cable/connection/identification.rb#16 module ActionCable::Connection::Identification::ClassMethods - # Mark a key as being a connection identifier index that can then be used to find the specific connection again later. - # Common identifiers are current_user and current_account, but could be anything, really. + # Mark a key as being a connection identifier index that can then be used to + # find the specific connection again later. Common identifiers are current_user + # and current_account, but could be anything, really. # - # Note that anything marked as an identifier will automatically create a delegate by the same name on any - # channel instances created off the connection. + # Note that anything marked as an identifier will automatically create a + # delegate by the same name on any channel instances created off the connection. # - # source://actioncable//lib/action_cable/connection/identification.rb#20 + # source://actioncable//lib/action_cable/connection/identification.rb#23 def identified_by(*identifiers); end end -# Makes it possible for the RemoteConnection to disconnect a specific connection. +# # Action Cable InternalChannel +# +# Makes it possible for the RemoteConnection to disconnect a specific +# connection. # -# source://actioncable//lib/action_cable/connection/internal_channel.rb#6 +# source://actioncable//lib/action_cable/connection/internal_channel.rb#11 module ActionCable::Connection::InternalChannel extend ::ActiveSupport::Concern private - # source://actioncable//lib/action_cable/connection/internal_channel.rb#10 + # source://actioncable//lib/action_cable/connection/internal_channel.rb#15 def internal_channel; end - # source://actioncable//lib/action_cable/connection/internal_channel.rb#31 + # source://actioncable//lib/action_cable/connection/internal_channel.rb#36 def process_internal_message(message); end - # source://actioncable//lib/action_cable/connection/internal_channel.rb#14 + # source://actioncable//lib/action_cable/connection/internal_channel.rb#19 def subscribe_to_internal_channel; end - # source://actioncable//lib/action_cable/connection/internal_channel.rb#25 + # source://actioncable//lib/action_cable/connection/internal_channel.rb#30 def unsubscribe_from_internal_channel; end end -# Allows us to buffer messages received from the WebSocket before the Connection has been fully initialized, and is ready to receive them. +# Allows us to buffer messages received from the WebSocket before the Connection +# has been fully initialized, and is ready to receive them. # -# source://actioncable//lib/action_cable/connection/message_buffer.rb#6 +# source://actioncable//lib/action_cable/connection/message_buffer.rb#9 class ActionCable::Connection::MessageBuffer # @return [MessageBuffer] a new instance of MessageBuffer # - # source://actioncable//lib/action_cable/connection/message_buffer.rb#7 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#10 def initialize(connection); end - # source://actioncable//lib/action_cable/connection/message_buffer.rb#12 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#15 def append(message); end - # source://actioncable//lib/action_cable/connection/message_buffer.rb#28 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#31 def process!; end # @return [Boolean] # - # source://actioncable//lib/action_cable/connection/message_buffer.rb#24 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#27 def processing?; end private - # source://actioncable//lib/action_cable/connection/message_buffer.rb#45 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#48 def buffer(message); end # Returns the value of attribute buffered_messages. # - # source://actioncable//lib/action_cable/connection/message_buffer.rb#35 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#38 def buffered_messages; end # Returns the value of attribute connection. # - # source://actioncable//lib/action_cable/connection/message_buffer.rb#34 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#37 def connection; end - # source://actioncable//lib/action_cable/connection/message_buffer.rb#41 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#44 def receive(message); end - # source://actioncable//lib/action_cable/connection/message_buffer.rb#49 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#52 def receive_buffered_messages; end # @return [Boolean] # - # source://actioncable//lib/action_cable/connection/message_buffer.rb#37 + # source://actioncable//lib/action_cable/connection/message_buffer.rb#40 def valid?(message); end end -# source://actioncable//lib/action_cable/connection/test_case.rb#12 +# source://actioncable//lib/action_cable/connection/test_case.rb#14 class ActionCable::Connection::NonInferrableConnectionError < ::StandardError # @return [NonInferrableConnectionError] a new instance of NonInferrableConnectionError # - # source://actioncable//lib/action_cable/connection/test_case.rb#13 + # source://actioncable//lib/action_cable/connection/test_case.rb#15 def initialize(name); end end @@ -1508,210 +1741,218 @@ class ActionCable::Connection::Stream def clean_rack_hijack; end end -# source://actioncable//lib/action_cable/connection/stream_event_loop.rb#8 +# source://actioncable//lib/action_cable/connection/stream_event_loop.rb#9 class ActionCable::Connection::StreamEventLoop # @return [StreamEventLoop] a new instance of StreamEventLoop # - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#9 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#10 def initialize; end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#29 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#30 def attach(io, stream); end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#37 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#38 def detach(io, stream); end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#22 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#23 def post(task = T.unsafe(nil), &block); end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#55 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#56 def stop; end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#18 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#19 def timer(interval, &block); end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#46 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#47 def writes_pending(io); end private - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#85 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#86 def run; end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#61 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#62 def spawn; end - # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#81 + # source://actioncable//lib/action_cable/connection/stream_event_loop.rb#82 def wakeup; end end -# Collection class for all the channel subscriptions established on a given connection. Responsible for routing incoming commands that arrive on -# the connection to the proper channel. +# # Action Cable Connection Subscriptions +# +# Collection class for all the channel subscriptions established on a given +# connection. Responsible for routing incoming commands that arrive on the +# connection to the proper channel. # -# source://actioncable//lib/action_cable/connection/subscriptions.rb#9 +# source://actioncable//lib/action_cable/connection/subscriptions.rb#14 class ActionCable::Connection::Subscriptions # @return [Subscriptions] a new instance of Subscriptions # - # source://actioncable//lib/action_cable/connection/subscriptions.rb#10 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#15 def initialize(connection); end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#28 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#33 def add(data); end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#15 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#20 def execute_command(data); end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#59 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#64 def identifiers; end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#69 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#74 def logger(*_arg0, **_arg1, &_arg2); end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#55 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#60 def perform_action(data); end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#45 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#50 def remove(data); end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#50 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#55 def remove_subscription(subscription); end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#63 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#68 def unsubscribe_from_all; end private # Returns the value of attribute connection. # - # source://actioncable//lib/action_cable/connection/subscriptions.rb#68 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#73 def connection; end - # source://actioncable//lib/action_cable/connection/subscriptions.rb#71 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#76 def find(data); end # Returns the value of attribute subscriptions. # - # source://actioncable//lib/action_cable/connection/subscriptions.rb#68 + # source://actioncable//lib/action_cable/connection/subscriptions.rb#73 def subscriptions; end end -# Allows the use of per-connection tags against the server logger. This wouldn't work using the traditional -# ActiveSupport::TaggedLogging enhanced Rails.logger, as that logger will reset the tags between requests. -# The connection is long-lived, so it needs its own set of tags for its independent duration. +# # Action Cable Connection TaggedLoggerProxy +# +# Allows the use of per-connection tags against the server logger. This wouldn't +# work using the traditional ActiveSupport::TaggedLogging enhanced Rails.logger, +# as that logger will reset the tags between requests. The connection is +# long-lived, so it needs its own set of tags for its independent duration. # -# source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#8 +# source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#13 class ActionCable::Connection::TaggedLoggerProxy # @return [TaggedLoggerProxy] a new instance of TaggedLoggerProxy # - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#11 + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#16 def initialize(logger, tags:); end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#16 + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#21 def add_tags(*tags); end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#31 - def debug(message); end + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#36 + def debug(message = T.unsafe(nil), &block); end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#31 - def error(message); end + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#36 + def error(message = T.unsafe(nil), &block); end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#31 - def fatal(message); end + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#36 + def fatal(message = T.unsafe(nil), &block); end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#31 - def info(message); end + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#36 + def info(message = T.unsafe(nil), &block); end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#21 + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#26 def tag(logger, &block); end # Returns the value of attribute tags. # - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#9 + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#14 def tags; end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#31 - def unknown(message); end + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#36 + def unknown(message = T.unsafe(nil), &block); end - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#31 - def warn(message); end + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#36 + def warn(message = T.unsafe(nil), &block); end private - # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#37 - def log(type, message); end + # source://actioncable//lib/action_cable/connection/tagged_logger_proxy.rb#42 + def log(type, message, &block); end end +# # Action Cable Connection TestCase +# # Unit test Action Cable connections. # -# Useful to check whether a connection's +identified_by+ gets assigned properly +# Useful to check whether a connection's `identified_by` gets assigned properly # and that any improper connection requests are rejected. # -# == Basic example +# ## Basic example # # Unit tests are written as follows: # -# 1. Simulate a connection attempt by calling +connect+. -# 2. Assert state, e.g. identifiers, has been assigned. +# 1. Simulate a connection attempt by calling `connect`. +# 2. Assert state, e.g. identifiers, has been assigned. # # -# class ApplicationCable::ConnectionTest < ActionCable::Connection::TestCase -# def test_connects_with_proper_cookie -# # Simulate the connection request with a cookie. -# cookies["user_id"] = users(:john).id +# class ApplicationCable::ConnectionTest < ActionCable::Connection::TestCase +# def test_connects_with_proper_cookie +# # Simulate the connection request with a cookie. +# cookies["user_id"] = users(:john).id # -# connect +# connect # -# # Assert the connection identifier matches the fixture. -# assert_equal users(:john).id, connection.user.id -# end +# # Assert the connection identifier matches the fixture. +# assert_equal users(:john).id, connection.user.id +# end # -# def test_rejects_connection_without_proper_cookie -# assert_reject_connection { connect } +# def test_rejects_connection_without_proper_cookie +# assert_reject_connection { connect } +# end # end -# end # -# +connect+ accepts additional information about the HTTP request with the -# +params+, +headers+, +session+, and Rack +env+ options. +# `connect` accepts additional information about the HTTP request with the +# `params`, `headers`, `session`, and Rack `env` options. # -# def test_connect_with_headers_and_query_string -# connect params: { user_id: 1 }, headers: { "X-API-TOKEN" => "secret-my" } +# def test_connect_with_headers_and_query_string +# connect params: { user_id: 1 }, headers: { "X-API-TOKEN" => "secret-my" } # -# assert_equal "1", connection.user.id -# assert_equal "secret-my", connection.token -# end +# assert_equal "1", connection.user.id +# assert_equal "secret-my", connection.token +# end # -# def test_connect_with_params -# connect params: { user_id: 1 } +# def test_connect_with_params +# connect params: { user_id: 1 } # -# assert_equal "1", connection.user.id -# end +# assert_equal "1", connection.user.id +# end # # You can also set up the correct cookies before the connection request: # -# def test_connect_with_cookies -# # Plain cookies: -# cookies["user_id"] = 1 +# def test_connect_with_cookies +# # Plain cookies: +# cookies["user_id"] = 1 # -# # Or signed/encrypted: -# # cookies.signed["user_id"] = 1 -# # cookies.encrypted["user_id"] = 1 +# # Or signed/encrypted: +# # cookies.signed["user_id"] = 1 +# # cookies.encrypted["user_id"] = 1 # -# connect +# connect # -# assert_equal "1", connection.user_id -# end +# assert_equal "1", connection.user_id +# end # -# == Connection is automatically inferred +# ## Connection is automatically inferred # -# ActionCable::Connection::TestCase will automatically infer the connection under test -# from the test class name. If the channel cannot be inferred from the test -# class name, you can explicitly set it with +tests+. +# ActionCable::Connection::TestCase will automatically infer the connection +# under test from the test class name. If the channel cannot be inferred from +# the test class name, you can explicitly set it with `tests`. # -# class ConnectionTest < ActionCable::Connection::TestCase -# tests ApplicationCable::Connection -# end +# class ConnectionTest < ActionCable::Connection::TestCase +# tests ApplicationCable::Connection +# end # -# source://actioncable//lib/action_cable/connection/test_case.rb#129 +# source://actioncable//lib/action_cable/connection/test_case.rb#141 class ActionCable::Connection::TestCase < ::ActiveSupport::TestCase include ::ActiveSupport::Testing::ConstantLookup include ::ActionCable::Connection::Assertions @@ -1719,31 +1960,31 @@ class ActionCable::Connection::TestCase < ::ActiveSupport::TestCase extend ::ActiveSupport::Testing::ConstantLookup::ClassMethods extend ::ActionCable::Connection::TestCase::Behavior::ClassMethods - # source://actioncable//lib/action_cable/connection/test_case.rb#139 + # source://actioncable//lib/action_cable/connection/test_case.rb#151 def _connection_class; end - # source://actioncable//lib/action_cable/connection/test_case.rb#139 + # source://actioncable//lib/action_cable/connection/test_case.rb#151 def _connection_class=(_arg0); end - # source://actioncable//lib/action_cable/connection/test_case.rb#139 + # source://actioncable//lib/action_cable/connection/test_case.rb#151 def _connection_class?; end - # source://actioncable//lib/action_cable/connection/test_case.rb#141 + # source://actioncable//lib/action_cable/connection/test_case.rb#153 def connection; end class << self - # source://actioncable//lib/action_cable/connection/test_case.rb#139 + # source://actioncable//lib/action_cable/connection/test_case.rb#151 def _connection_class; end - # source://actioncable//lib/action_cable/connection/test_case.rb#139 + # source://actioncable//lib/action_cable/connection/test_case.rb#151 def _connection_class=(value); end - # source://actioncable//lib/action_cable/connection/test_case.rb#139 + # source://actioncable//lib/action_cable/connection/test_case.rb#151 def _connection_class?; end end end -# source://actioncable//lib/action_cable/connection/test_case.rb#130 +# source://actioncable//lib/action_cable/connection/test_case.rb#142 module ActionCable::Connection::TestCase::Behavior include ::ActionCable::Connection::Assertions extend ::ActiveSupport::Concern @@ -1758,25 +1999,25 @@ module ActionCable::Connection::TestCase::Behavior # # Accepts request path as the first argument and the following request options: # - # - params – URL parameters (Hash) - # - headers – request headers (Hash) - # - session – session data (Hash) - # - env – additional Rack env configuration (Hash) + # * params – URL parameters (Hash) + # * headers – request headers (Hash) + # * session – session data (Hash) + # * env – additional Rack env configuration (Hash) # - # source://actioncable//lib/action_cable/connection/test_case.rb#183 + # source://actioncable//lib/action_cable/connection/test_case.rb#195 def connect(path = T.unsafe(nil), **request_params); end - # source://actioncable//lib/action_cable/connection/test_case.rb#203 + # source://actioncable//lib/action_cable/connection/test_case.rb#215 def cookies; end # Exert #disconnect on the connection under test. # - # source://actioncable//lib/action_cable/connection/test_case.rb#196 + # source://actioncable//lib/action_cable/connection/test_case.rb#208 def disconnect; end private - # source://actioncable//lib/action_cable/connection/test_case.rb#208 + # source://actioncable//lib/action_cable/connection/test_case.rb#220 def build_test_request(path, params: T.unsafe(nil), headers: T.unsafe(nil), session: T.unsafe(nil), env: T.unsafe(nil)); end module GeneratedClassMethods @@ -1792,198 +2033,221 @@ module ActionCable::Connection::TestCase::Behavior end end -# source://actioncable//lib/action_cable/connection/test_case.rb#146 +# source://actioncable//lib/action_cable/connection/test_case.rb#158 module ActionCable::Connection::TestCase::Behavior::ClassMethods - # source://actioncable//lib/action_cable/connection/test_case.rb#158 + # source://actioncable//lib/action_cable/connection/test_case.rb#170 def connection_class; end # @raise [NonInferrableConnectionError] # - # source://actioncable//lib/action_cable/connection/test_case.rb#166 + # source://actioncable//lib/action_cable/connection/test_case.rb#178 def determine_default_connection(name); end - # source://actioncable//lib/action_cable/connection/test_case.rb#147 + # source://actioncable//lib/action_cable/connection/test_case.rb#159 def tests(connection); end end -# source://actioncable//lib/action_cable/connection/test_case.rb#133 +# source://actioncable//lib/action_cable/connection/test_case.rb#145 ActionCable::Connection::TestCase::Behavior::DEFAULT_PATH = T.let(T.unsafe(nil), String) -# source://actioncable//lib/action_cable/connection/test_case.rb#47 +# source://actioncable//lib/action_cable/connection/test_case.rb#57 module ActionCable::Connection::TestConnection - # source://actioncable//lib/action_cable/connection/test_case.rb#50 + # source://actioncable//lib/action_cable/connection/test_case.rb#60 def initialize(request); end # Returns the value of attribute logger. # - # source://actioncable//lib/action_cable/connection/test_case.rb#48 + # source://actioncable//lib/action_cable/connection/test_case.rb#58 def logger; end # Returns the value of attribute request. # - # source://actioncable//lib/action_cable/connection/test_case.rb#48 + # source://actioncable//lib/action_cable/connection/test_case.rb#58 def request; end end -# We don't want to use the whole "encryption stack" for connection -# unit-tests, but we want to make sure that users test against the correct types -# of cookies (i.e. signed or encrypted or plain) +# We don't want to use the whole "encryption stack" for connection unit-tests, +# but we want to make sure that users test against the correct types of cookies +# (i.e. signed or encrypted or plain) # -# source://actioncable//lib/action_cable/connection/test_case.rb#33 -class ActionCable::Connection::TestCookieJar < ::ActiveSupport::HashWithIndifferentAccess - # source://actioncable//lib/action_cable/connection/test_case.rb#38 +# source://actioncable//lib/action_cable/connection/test_case.rb#43 +class ActionCable::Connection::TestCookieJar < ::ActionCable::Connection::TestCookies + # source://actioncable//lib/action_cable/connection/test_case.rb#48 def encrypted; end - # source://actioncable//lib/action_cable/connection/test_case.rb#34 + # source://actioncable//lib/action_cable/connection/test_case.rb#44 def signed; end end -# source://actioncable//lib/action_cable/connection/test_case.rb#43 +# source://actioncable//lib/action_cable/connection/test_case.rb#33 +class ActionCable::Connection::TestCookies < ::ActiveSupport::HashWithIndifferentAccess + # source://actioncable//lib/action_cable/connection/test_case.rb#34 + def []=(name, options); end +end + +# source://actioncable//lib/action_cable/connection/test_case.rb#53 class ActionCable::Connection::TestRequest < ::ActionDispatch::TestRequest # Returns the value of attribute cookie_jar. # - # source://actioncable//lib/action_cable/connection/test_case.rb#44 + # source://actioncable//lib/action_cable/connection/test_case.rb#54 def cookie_jar; end # Sets the attribute cookie_jar # # @param value the value to set the attribute cookie_jar to. # - # source://actioncable//lib/action_cable/connection/test_case.rb#44 + # source://actioncable//lib/action_cable/connection/test_case.rb#54 def cookie_jar=(_arg0); end # Returns the value of attribute session. # - # source://actioncable//lib/action_cable/connection/test_case.rb#44 + # source://actioncable//lib/action_cable/connection/test_case.rb#54 def session; end # Sets the attribute session # # @param value the value to set the attribute session to. # - # source://actioncable//lib/action_cable/connection/test_case.rb#44 + # source://actioncable//lib/action_cable/connection/test_case.rb#54 def session=(_arg0); end end +# # Action Cable Connection WebSocket +# # Wrap the real socket to minimize the externally-presented API # -# source://actioncable//lib/action_cable/connection/web_socket.rb#8 +# source://actioncable//lib/action_cable/connection/web_socket.rb#12 class ActionCable::Connection::WebSocket # @return [WebSocket] a new instance of WebSocket # - # source://actioncable//lib/action_cable/connection/web_socket.rb#9 + # source://actioncable//lib/action_cable/connection/web_socket.rb#13 def initialize(env, event_target, event_loop, protocols: T.unsafe(nil)); end # @return [Boolean] # - # source://actioncable//lib/action_cable/connection/web_socket.rb#17 + # source://actioncable//lib/action_cable/connection/web_socket.rb#21 def alive?; end - # source://actioncable//lib/action_cable/connection/web_socket.rb#25 - def close; end + # source://actioncable//lib/action_cable/connection/web_socket.rb#29 + def close(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://actioncable//lib/action_cable/connection/web_socket.rb#13 + # source://actioncable//lib/action_cable/connection/web_socket.rb#17 def possible?; end - # source://actioncable//lib/action_cable/connection/web_socket.rb#29 + # source://actioncable//lib/action_cable/connection/web_socket.rb#33 def protocol; end - # source://actioncable//lib/action_cable/connection/web_socket.rb#33 + # source://actioncable//lib/action_cable/connection/web_socket.rb#37 def rack_response; end - # source://actioncable//lib/action_cable/connection/web_socket.rb#21 - def transmit(data); end + # source://actioncable//lib/action_cable/connection/web_socket.rb#25 + def transmit(*_arg0, **_arg1, &_arg2); end private # Returns the value of attribute websocket. # - # source://actioncable//lib/action_cable/connection/web_socket.rb#38 + # source://actioncable//lib/action_cable/connection/web_socket.rb#42 def websocket; end end -# source://actioncable//lib/action_cable/engine.rb#9 -class ActionCable::Engine < ::Rails::Engine; end +# source://actioncable//lib/action_cable/engine.rb#10 +class ActionCable::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end -# source://actioncable//lib/action_cable/helpers/action_cable_helper.rb#4 +# source://actioncable//lib/action_cable/helpers/action_cable_helper.rb#6 module ActionCable::Helpers; end -# source://actioncable//lib/action_cable/helpers/action_cable_helper.rb#5 +# source://actioncable//lib/action_cable/helpers/action_cable_helper.rb#7 module ActionCable::Helpers::ActionCableHelper - # Returns an "action-cable-url" meta tag with the value of the URL specified in your - # configuration. Ensure this is above your JavaScript tag: + # Returns an "action-cable-url" meta tag with the value of the URL specified in + # your configuration. Ensure this is above your JavaScript tag: # - # - # <%= action_cable_meta_tag %> - # <%= javascript_include_tag 'application', 'data-turbo-track' => 'reload' %> - # + # + # <%= action_cable_meta_tag %> + # <%= javascript_include_tag 'application', 'data-turbo-track' => 'reload' %> + # # - # This is then used by Action Cable to determine the URL of your WebSocket server. - # Your JavaScript can then connect to the server without needing to specify the - # URL directly: + # This is then used by Action Cable to determine the URL of your WebSocket + # server. Your JavaScript can then connect to the server without needing to + # specify the URL directly: # - # import Cable from "@rails/actioncable" - # window.Cable = Cable - # window.App = {} - # App.cable = Cable.createConsumer() + # import Cable from "@rails/actioncable" + # window.Cable = Cable + # window.App = {} + # App.cable = Cable.createConsumer() # # Make sure to specify the correct server location in each of your environment # config files: # - # config.action_cable.mount_path = "/cable123" - # <%= action_cable_meta_tag %> would render: - # => + # config.action_cable.mount_path = "/cable123" + # <%= action_cable_meta_tag %> would render: + # => # - # config.action_cable.url = "ws://actioncable.com" - # <%= action_cable_meta_tag %> would render: - # => + # config.action_cable.url = "ws://actioncable.com" + # <%= action_cable_meta_tag %> would render: + # => # - # source://actioncable//lib/action_cable/helpers/action_cable_helper.rb#34 + # source://actioncable//lib/action_cable/helpers/action_cable_helper.rb#36 def action_cable_meta_tag; end end -# source://actioncable//lib/action_cable.rb#33 +# source://actioncable//lib/action_cable.rb#58 ActionCable::INTERNAL = T.let(T.unsafe(nil), Hash) +# # Action Cable Remote Connections +# # If you need to disconnect a given connection, you can go through the # RemoteConnections. You can find the connections you're looking for by # searching for the identifier declared on the connection. For example: # -# module ApplicationCable -# class Connection < ActionCable::Connection::Base -# identified_by :current_user -# .... +# module ApplicationCable +# class Connection < ActionCable::Connection::Base +# identified_by :current_user +# .... +# end # end -# end # -# ActionCable.server.remote_connections.where(current_user: User.find(1)).disconnect +# ActionCable.server.remote_connections.where(current_user: User.find(1)).disconnect +# +# This will disconnect all the connections established for `User.find(1)`, +# across all servers running on all machines, because it uses the internal +# channel that all of these servers are subscribed to. +# +# By default, server sends a "disconnect" message with "reconnect" flag set to +# true. You can override it by specifying the `reconnect` option: # -# This will disconnect all the connections established for -# User.find(1), across all servers running on all machines, because -# it uses the internal channel that all of these servers are subscribed to. +# ActionCable.server.remote_connections.where(current_user: User.find(1)).disconnect(reconnect: false) # -# source://actioncable//lib/action_cable/remote_connections.rb#22 +# source://actioncable//lib/action_cable/remote_connections.rb#31 class ActionCable::RemoteConnections # @return [RemoteConnections] a new instance of RemoteConnections # - # source://actioncable//lib/action_cable/remote_connections.rb#25 + # source://actioncable//lib/action_cable/remote_connections.rb#34 def initialize(server); end # Returns the value of attribute server. # - # source://actioncable//lib/action_cable/remote_connections.rb#23 + # source://actioncable//lib/action_cable/remote_connections.rb#32 def server; end - # source://actioncable//lib/action_cable/remote_connections.rb#29 + # source://actioncable//lib/action_cable/remote_connections.rb#38 def where(identifier); end end -# Represents a single remote connection found via ActionCable.server.remote_connections.where(*). -# Exists solely for the purpose of calling #disconnect on that connection. +# # Action Cable Remote Connection # -# source://actioncable//lib/action_cable/remote_connections.rb#36 +# Represents a single remote connection found via +# `ActionCable.server.remote_connections.where(*)`. Exists solely for the +# purpose of calling #disconnect on that connection. +# +# source://actioncable//lib/action_cable/remote_connections.rb#48 class ActionCable::RemoteConnections::RemoteConnection include ::ActionCable::Connection::InternalChannel include ::ActionCable::Connection::Identification @@ -1991,387 +2255,448 @@ class ActionCable::RemoteConnections::RemoteConnection # @return [RemoteConnection] a new instance of RemoteConnection # - # source://actioncable//lib/action_cable/remote_connections.rb#41 + # source://actioncable//lib/action_cable/remote_connections.rb#53 def initialize(server, ids); end # Uses the internal channel to disconnect the connection. # - # source://actioncable//lib/action_cable/remote_connections.rb#47 - def disconnect; end + # source://actioncable//lib/action_cable/remote_connections.rb#59 + def disconnect(reconnect: T.unsafe(nil)); end - # source://actioncable//lib/action_cable/remote_connections.rb#52 + # source://actioncable//lib/action_cable/remote_connections.rb#64 def identifiers; end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers=(_arg0); end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers?; end protected # Returns the value of attribute server. # - # source://actioncable//lib/action_cable/remote_connections.rb#57 + # source://actioncable//lib/action_cable/remote_connections.rb#69 def server; end private # @raise [InvalidIdentifiersError] # - # source://actioncable//lib/action_cable/remote_connections.rb#60 + # source://actioncable//lib/action_cable/remote_connections.rb#72 def set_identifier_instance_vars(ids); end # @return [Boolean] # - # source://actioncable//lib/action_cable/remote_connections.rb#65 + # source://actioncable//lib/action_cable/remote_connections.rb#77 def valid_identifiers?(ids); end class << self - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers; end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers=(value); end - # source://actioncable//lib/action_cable/connection/identification.rb#11 + # source://actioncable//lib/action_cable/connection/identification.rb#13 def identifiers?; end end end -# source://actioncable//lib/action_cable/remote_connections.rb#37 +# source://actioncable//lib/action_cable/remote_connections.rb#49 class ActionCable::RemoteConnections::RemoteConnection::InvalidIdentifiersError < ::StandardError; end -# source://actioncable//lib/action_cable/server.rb#4 -module ActionCable::Server - extend ::ActiveSupport::Autoload -end +# source://actioncable//lib/action_cable/server/base.rb#8 +module ActionCable::Server; end -# A singleton ActionCable::Server instance is available via ActionCable.server. It's used by the Rack process that starts the Action Cable server, but -# is also used by the user to reach the RemoteConnections object, which is used for finding and disconnecting connections across all servers. +# # Action Cable Server Base # -# Also, this is the server instance used for broadcasting. See Broadcasting for more information. +# A singleton ActionCable::Server instance is available via ActionCable.server. +# It's used by the Rack process that starts the Action Cable server, but is also +# used by the user to reach the RemoteConnections object, which is used for +# finding and disconnecting connections across all servers. # -# source://actioncable//lib/action_cable/server/base.rb#11 +# Also, this is the server instance used for broadcasting. See Broadcasting for +# more information. +# +# source://actioncable//lib/action_cable/server/base.rb#18 class ActionCable::Server::Base include ::ActionCable::Server::Broadcasting include ::ActionCable::Server::Connections # @return [Base] a new instance of Base # - # source://actioncable//lib/action_cable/server/base.rb#24 + # source://actioncable//lib/action_cable/server/base.rb#31 def initialize(config: T.unsafe(nil)); end # Called by Rack to set up the server. # - # source://actioncable//lib/action_cable/server/base.rb#31 + # source://actioncable//lib/action_cable/server/base.rb#38 def call(env); end # Returns the value of attribute config. # - # source://actioncable//lib/action_cable/server/base.rb#17 + # source://actioncable//lib/action_cable/server/base.rb#24 def config; end - # All of the identifiers applied to the connection class associated with this server. + # All of the identifiers applied to the connection class associated with this + # server. # - # source://actioncable//lib/action_cable/server/base.rb#87 + # source://actioncable//lib/action_cable/server/base.rb#102 def connection_identifiers; end - # Disconnect all the connections identified by +identifiers+ on this server or any others via RemoteConnections. + # Disconnect all the connections identified by `identifiers` on this server or + # any others via RemoteConnections. # - # source://actioncable//lib/action_cable/server/base.rb#37 + # source://actioncable//lib/action_cable/server/base.rb#46 def disconnect(identifiers); end - # source://actioncable//lib/action_cable/server/base.rb#62 + # source://actioncable//lib/action_cable/server/base.rb#71 def event_loop; end - # source://actioncable//lib/action_cable/server/base.rb#20 + # source://actioncable//lib/action_cable/server/base.rb#27 def logger(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute mutex. # - # source://actioncable//lib/action_cable/server/base.rb#22 + # source://actioncable//lib/action_cable/server/base.rb#29 def mutex; end # Adapter used for all streams/broadcasting. # - # source://actioncable//lib/action_cable/server/base.rb#82 + # source://actioncable//lib/action_cable/server/base.rb#96 def pubsub; end # Gateway to RemoteConnections. See that class for details. # - # source://actioncable//lib/action_cable/server/base.rb#58 + # source://actioncable//lib/action_cable/server/base.rb#67 def remote_connections; end - # source://actioncable//lib/action_cable/server/base.rb#41 + # source://actioncable//lib/action_cable/server/base.rb#50 def restart; end - # The worker pool is where we run connection callbacks and channel actions. We do as little as possible on the server's main thread. - # The worker pool is an executor service that's backed by a pool of threads working from a task queue. The thread pool size maxes out - # at 4 worker threads by default. Tune the size yourself with config.action_cable.worker_pool_size. + # The worker pool is where we run connection callbacks and channel actions. We + # do as little as possible on the server's main thread. The worker pool is an + # executor service that's backed by a pool of threads working from a task queue. + # The thread pool size maxes out at 4 worker threads by default. Tune the size + # yourself with `config.action_cable.worker_pool_size`. # - # Using Active Record, Redis, etc within your channel actions means you'll get a separate connection from each thread in the worker pool. - # Plan your deployment accordingly: 5 servers each running 5 Puma workers each running an 8-thread worker pool means at least 200 database - # connections. + # Using Active Record, Redis, etc within your channel actions means you'll get a + # separate connection from each thread in the worker pool. Plan your deployment + # accordingly: 5 servers each running 5 Puma workers each running an 8-thread + # worker pool means at least 200 database connections. # - # Also, ensure that your database connection pool size is as least as large as your worker pool size. Otherwise, workers may oversubscribe - # the database connection pool and block while they wait for other workers to release their connections. Use a smaller worker pool or a larger - # database connection pool instead. + # Also, ensure that your database connection pool size is as least as large as + # your worker pool size. Otherwise, workers may oversubscribe the database + # connection pool and block while they wait for other workers to release their + # connections. Use a smaller worker pool or a larger database connection pool + # instead. # - # source://actioncable//lib/action_cable/server/base.rb#77 + # source://actioncable//lib/action_cable/server/base.rb#91 def worker_pool; end class << self - # source://actioncable//lib/action_cable/server/base.rb#15 + # source://actioncable//lib/action_cable/server/base.rb#22 def config; end - # source://actioncable//lib/action_cable/server/base.rb#15 + # source://actioncable//lib/action_cable/server/base.rb#22 def config=(val); end - # source://actioncable//lib/action_cable/server/base.rb#19 + # source://actioncable//lib/action_cable/server/base.rb#26 def logger; end end end -# Broadcasting is how other parts of your application can send messages to a channel's subscribers. As explained in Channel, most of the time, these -# broadcastings are streamed directly to the clients subscribed to the named broadcasting. Let's explain with a full-stack example: +# # Action Cable Server Broadcasting +# +# Broadcasting is how other parts of your application can send messages to a +# channel's subscribers. As explained in Channel, most of the time, these +# broadcastings are streamed directly to the clients subscribed to the named +# broadcasting. Let's explain with a full-stack example: # -# class WebNotificationsChannel < ApplicationCable::Channel -# def subscribed -# stream_from "web_notifications_#{current_user.id}" +# class WebNotificationsChannel < ApplicationCable::Channel +# def subscribed +# stream_from "web_notifications_#{current_user.id}" +# end # end -# end # -# # Somewhere in your app this is called, perhaps from a NewCommentJob: -# ActionCable.server.broadcast \ -# "web_notifications_1", { title: "New things!", body: "All that's fit for print" } +# # Somewhere in your app this is called, perhaps from a NewCommentJob: +# ActionCable.server.broadcast \ +# "web_notifications_1", { title: "New things!", body: "All that's fit for print" } # -# # Client-side CoffeeScript, which assumes you've already requested the right to send web notifications: -# App.cable.subscriptions.create "WebNotificationsChannel", -# received: (data) -> -# new Notification data['title'], body: data['body'] +# # Client-side CoffeeScript, which assumes you've already requested the right to send web notifications: +# App.cable.subscriptions.create "WebNotificationsChannel", +# received: (data) -> +# new Notification data['title'], body: data['body'] # -# source://actioncable//lib/action_cable/server/broadcasting.rb#22 +# source://actioncable//lib/action_cable/server/broadcasting.rb#28 module ActionCable::Server::Broadcasting - # Broadcast a hash directly to a named broadcasting. This will later be JSON encoded. + # Broadcast a hash directly to a named `broadcasting`. This will later be JSON + # encoded. # - # source://actioncable//lib/action_cable/server/broadcasting.rb#24 + # source://actioncable//lib/action_cable/server/broadcasting.rb#31 def broadcast(broadcasting, message, coder: T.unsafe(nil)); end - # Returns a broadcaster for a named broadcasting that can be reused. Useful when you have an object that - # may need multiple spots to transmit to a specific broadcasting over and over. + # Returns a broadcaster for a named `broadcasting` that can be reused. Useful + # when you have an object that may need multiple spots to transmit to a specific + # broadcasting over and over. # - # source://actioncable//lib/action_cable/server/broadcasting.rb#30 + # source://actioncable//lib/action_cable/server/broadcasting.rb#38 def broadcaster_for(broadcasting, coder: T.unsafe(nil)); end end -# source://actioncable//lib/action_cable/server/broadcasting.rb#35 +# source://actioncable//lib/action_cable/server/broadcasting.rb#43 class ActionCable::Server::Broadcasting::Broadcaster # @return [Broadcaster] a new instance of Broadcaster # - # source://actioncable//lib/action_cable/server/broadcasting.rb#38 + # source://actioncable//lib/action_cable/server/broadcasting.rb#46 def initialize(server, broadcasting, coder:); end - # source://actioncable//lib/action_cable/server/broadcasting.rb#42 + # source://actioncable//lib/action_cable/server/broadcasting.rb#50 def broadcast(message); end # Returns the value of attribute broadcasting. # - # source://actioncable//lib/action_cable/server/broadcasting.rb#36 + # source://actioncable//lib/action_cable/server/broadcasting.rb#44 def broadcasting; end # Returns the value of attribute coder. # - # source://actioncable//lib/action_cable/server/broadcasting.rb#36 + # source://actioncable//lib/action_cable/server/broadcasting.rb#44 def coder; end # Returns the value of attribute server. # - # source://actioncable//lib/action_cable/server/broadcasting.rb#36 + # source://actioncable//lib/action_cable/server/broadcasting.rb#44 def server; end end -# An instance of this configuration object is available via ActionCable.server.config, which allows you to tweak Action Cable configuration -# in a Rails config initializer. +# # Action Cable Server Configuration # -# source://actioncable//lib/action_cable/server/configuration.rb#7 +# An instance of this configuration object is available via +# ActionCable.server.config, which allows you to tweak Action Cable +# configuration in a Rails config initializer. +# +# source://actioncable//lib/action_cable/server/configuration.rb#14 class ActionCable::Server::Configuration # @return [Configuration] a new instance of Configuration # - # source://actioncable//lib/action_cable/server/configuration.rb#14 + # source://actioncable//lib/action_cable/server/configuration.rb#22 def initialize; end # Returns the value of attribute allow_same_origin_as_host. # - # source://actioncable//lib/action_cable/server/configuration.rb#10 + # source://actioncable//lib/action_cable/server/configuration.rb#17 def allow_same_origin_as_host; end # Sets the attribute allow_same_origin_as_host # # @param value the value to set the attribute allow_same_origin_as_host to. # - # source://actioncable//lib/action_cable/server/configuration.rb#10 + # source://actioncable//lib/action_cable/server/configuration.rb#17 def allow_same_origin_as_host=(_arg0); end # Returns the value of attribute allowed_request_origins. # - # source://actioncable//lib/action_cable/server/configuration.rb#10 + # source://actioncable//lib/action_cable/server/configuration.rb#17 def allowed_request_origins; end # Sets the attribute allowed_request_origins # # @param value the value to set the attribute allowed_request_origins to. # - # source://actioncable//lib/action_cable/server/configuration.rb#10 + # source://actioncable//lib/action_cable/server/configuration.rb#17 def allowed_request_origins=(_arg0); end # Returns the value of attribute cable. # - # source://actioncable//lib/action_cable/server/configuration.rb#11 + # source://actioncable//lib/action_cable/server/configuration.rb#18 def cable; end # Sets the attribute cable # # @param value the value to set the attribute cable to. # - # source://actioncable//lib/action_cable/server/configuration.rb#11 + # source://actioncable//lib/action_cable/server/configuration.rb#18 def cable=(_arg0); end # Returns the value of attribute connection_class. # - # source://actioncable//lib/action_cable/server/configuration.rb#9 + # source://actioncable//lib/action_cable/server/configuration.rb#16 def connection_class; end # Sets the attribute connection_class # # @param value the value to set the attribute connection_class to. # - # source://actioncable//lib/action_cable/server/configuration.rb#9 + # source://actioncable//lib/action_cable/server/configuration.rb#16 def connection_class=(_arg0); end # Returns the value of attribute disable_request_forgery_protection. # - # source://actioncable//lib/action_cable/server/configuration.rb#10 + # source://actioncable//lib/action_cable/server/configuration.rb#17 def disable_request_forgery_protection; end # Sets the attribute disable_request_forgery_protection # # @param value the value to set the attribute disable_request_forgery_protection to. # - # source://actioncable//lib/action_cable/server/configuration.rb#10 + # source://actioncable//lib/action_cable/server/configuration.rb#17 def disable_request_forgery_protection=(_arg0); end + # Returns the value of attribute filter_parameters. + # + # source://actioncable//lib/action_cable/server/configuration.rb#17 + def filter_parameters; end + + # Sets the attribute filter_parameters + # + # @param value the value to set the attribute filter_parameters to. + # + # source://actioncable//lib/action_cable/server/configuration.rb#17 + def filter_parameters=(_arg0); end + + # Returns the value of attribute health_check_application. + # + # source://actioncable//lib/action_cable/server/configuration.rb#20 + def health_check_application; end + + # Sets the attribute health_check_application + # + # @param value the value to set the attribute health_check_application to. + # + # source://actioncable//lib/action_cable/server/configuration.rb#20 + def health_check_application=(_arg0); end + + # Returns the value of attribute health_check_path. + # + # source://actioncable//lib/action_cable/server/configuration.rb#20 + def health_check_path; end + + # Sets the attribute health_check_path + # + # @param value the value to set the attribute health_check_path to. + # + # source://actioncable//lib/action_cable/server/configuration.rb#20 + def health_check_path=(_arg0); end + # Returns the value of attribute log_tags. # - # source://actioncable//lib/action_cable/server/configuration.rb#8 + # source://actioncable//lib/action_cable/server/configuration.rb#15 def log_tags; end # Sets the attribute log_tags # # @param value the value to set the attribute log_tags to. # - # source://actioncable//lib/action_cable/server/configuration.rb#8 + # source://actioncable//lib/action_cable/server/configuration.rb#15 def log_tags=(_arg0); end # Returns the value of attribute logger. # - # source://actioncable//lib/action_cable/server/configuration.rb#8 + # source://actioncable//lib/action_cable/server/configuration.rb#15 def logger; end # Sets the attribute logger # # @param value the value to set the attribute logger to. # - # source://actioncable//lib/action_cable/server/configuration.rb#8 + # source://actioncable//lib/action_cable/server/configuration.rb#15 def logger=(_arg0); end # Returns the value of attribute mount_path. # - # source://actioncable//lib/action_cable/server/configuration.rb#11 + # source://actioncable//lib/action_cable/server/configuration.rb#18 def mount_path; end # Sets the attribute mount_path # # @param value the value to set the attribute mount_path to. # - # source://actioncable//lib/action_cable/server/configuration.rb#11 + # source://actioncable//lib/action_cable/server/configuration.rb#18 def mount_path=(_arg0); end # Returns the value of attribute precompile_assets. # - # source://actioncable//lib/action_cable/server/configuration.rb#12 + # source://actioncable//lib/action_cable/server/configuration.rb#19 def precompile_assets; end # Sets the attribute precompile_assets # # @param value the value to set the attribute precompile_assets to. # - # source://actioncable//lib/action_cable/server/configuration.rb#12 + # source://actioncable//lib/action_cable/server/configuration.rb#19 def precompile_assets=(_arg0); end - # Returns constant of subscription adapter specified in config/cable.yml. - # If the adapter cannot be found, this will default to the Redis adapter. - # Also makes sure proper dependencies are required. + # Returns constant of subscription adapter specified in config/cable.yml. If the + # adapter cannot be found, this will default to the Redis adapter. Also makes + # sure proper dependencies are required. # - # source://actioncable//lib/action_cable/server/configuration.rb#27 + # source://actioncable//lib/action_cable/server/configuration.rb#40 def pubsub_adapter; end # Returns the value of attribute url. # - # source://actioncable//lib/action_cable/server/configuration.rb#11 + # source://actioncable//lib/action_cable/server/configuration.rb#18 def url; end # Sets the attribute url # # @param value the value to set the attribute url to. # - # source://actioncable//lib/action_cable/server/configuration.rb#11 + # source://actioncable//lib/action_cable/server/configuration.rb#18 def url=(_arg0); end # Returns the value of attribute worker_pool_size. # - # source://actioncable//lib/action_cable/server/configuration.rb#9 + # source://actioncable//lib/action_cable/server/configuration.rb#16 def worker_pool_size; end # Sets the attribute worker_pool_size # # @param value the value to set the attribute worker_pool_size to. # - # source://actioncable//lib/action_cable/server/configuration.rb#9 + # source://actioncable//lib/action_cable/server/configuration.rb#16 def worker_pool_size=(_arg0); end end -# Collection class for all the connections that have been established on this specific server. Remember, usually you'll run many Action Cable servers, so -# you can't use this collection as a full list of all of the connections established against your application. Instead, use RemoteConnections for that. +# # Action Cable Server Connections +# +# Collection class for all the connections that have been established on this +# specific server. Remember, usually you'll run many Action Cable servers, so +# you can't use this collection as a full list of all of the connections +# established against your application. Instead, use RemoteConnections for that. # -# source://actioncable//lib/action_cable/server/connections.rb#7 +# source://actioncable//lib/action_cable/server/connections.rb#13 module ActionCable::Server::Connections - # source://actioncable//lib/action_cable/server/connections.rb#14 + # source://actioncable//lib/action_cable/server/connections.rb#20 def add_connection(connection); end - # source://actioncable//lib/action_cable/server/connections.rb#10 + # source://actioncable//lib/action_cable/server/connections.rb#16 def connections; end - # source://actioncable//lib/action_cable/server/connections.rb#31 + # source://actioncable//lib/action_cable/server/connections.rb#39 def open_connections_statistics; end - # source://actioncable//lib/action_cable/server/connections.rb#18 + # source://actioncable//lib/action_cable/server/connections.rb#24 def remove_connection(connection); end - # WebSocket connection implementations differ on when they'll mark a connection as stale. We basically never want a connection to go stale, as you - # then can't rely on being able to communicate with the connection. To solve this, a 3 second heartbeat runs on all connections. If the beat fails, we automatically + # WebSocket connection implementations differ on when they'll mark a connection + # as stale. We basically never want a connection to go stale, as you then can't + # rely on being able to communicate with the connection. To solve this, a 3 + # second heartbeat runs on all connections. If the beat fails, we automatically # disconnect. # - # source://actioncable//lib/action_cable/server/connections.rb#25 + # source://actioncable//lib/action_cable/server/connections.rb#33 def setup_heartbeat_timer; end end -# source://actioncable//lib/action_cable/server/connections.rb#8 +# source://actioncable//lib/action_cable/server/connections.rb#14 ActionCable::Server::Connections::BEAT_INTERVAL = T.let(T.unsafe(nil), Integer) # Worker used by Server.send_async to do connection work in threads. # -# source://actioncable//lib/action_cable/server/worker/active_record_connection_management.rb#5 +# source://actioncable//lib/action_cable/server/worker.rb#12 class ActionCable::Server::Worker include ::ActiveSupport::Callbacks include ::ActionCable::Server::Worker::ActiveRecordConnectionManagement @@ -2380,96 +2705,94 @@ class ActionCable::Server::Worker # @return [Worker] a new instance of Worker # - # source://actioncable//lib/action_cable/server/worker.rb#20 + # source://actioncable//lib/action_cable/server/worker.rb#21 def initialize(max_size: T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_work_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _work_callbacks; end - # source://actioncable//lib/action_cable/server/worker.rb#47 + # source://actioncable//lib/action_cable/server/worker.rb#48 def async_exec(receiver, *args, connection:, &block); end - # source://actioncable//lib/action_cable/server/worker.rb#51 + # source://actioncable//lib/action_cable/server/worker.rb#52 def async_invoke(receiver, method, *args, connection: T.unsafe(nil), &block); end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#56 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#74 def connection; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#100 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#116 def connection=(obj); end # Returns the value of attribute executor. # - # source://actioncable//lib/action_cable/server/worker.rb#18 + # source://actioncable//lib/action_cable/server/worker.rb#19 def executor; end - # Stop processing work: any work that has not already started - # running will be discarded from the queue + # Stop processing work: any work that has not already started running will be + # discarded from the queue # - # source://actioncable//lib/action_cable/server/worker.rb#31 + # source://actioncable//lib/action_cable/server/worker.rb#32 def halt; end - # source://actioncable//lib/action_cable/server/worker.rb#57 + # source://actioncable//lib/action_cable/server/worker.rb#58 def invoke(receiver, method, *args, connection:, &block); end # @return [Boolean] # - # source://actioncable//lib/action_cable/server/worker.rb#35 + # source://actioncable//lib/action_cable/server/worker.rb#36 def stopping?; end - # source://actioncable//lib/action_cable/server/worker.rb#39 + # source://actioncable//lib/action_cable/server/worker.rb#40 def work(connection, &block); end private - # source://actioncable//lib/action_cable/server/worker.rb#69 + # source://actioncable//lib/action_cable/server/worker.rb#70 def logger; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _work_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _work_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#48 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#49 def connection; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#92 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#108 def connection=(obj); end end end -# source://actioncable//lib/action_cable/server/worker/active_record_connection_management.rb#6 +# source://actioncable//lib/action_cable/server/worker/active_record_connection_management.rb#8 module ActionCable::Server::Worker::ActiveRecordConnectionManagement extend ::ActiveSupport::Concern - # source://actioncable//lib/action_cable/server/worker/active_record_connection_management.rb#15 + # source://actioncable//lib/action_cable/server/worker/active_record_connection_management.rb#17 def with_database_connections(&block); end end -# source://actioncable//lib/action_cable/subscription_adapter.rb#4 -module ActionCable::SubscriptionAdapter - extend ::ActiveSupport::Autoload -end +# source://actioncable//lib/action_cable/subscription_adapter/async.rb#6 +module ActionCable::SubscriptionAdapter; end # source://actioncable//lib/action_cable/subscription_adapter/async.rb#7 class ActionCable::SubscriptionAdapter::Async < ::ActionCable::SubscriptionAdapter::Inline @@ -2493,262 +2816,447 @@ class ActionCable::SubscriptionAdapter::Async::AsyncSubscriberMap < ::ActionCabl def invoke_callback(*_arg0); end end -# source://actioncable//lib/action_cable/subscription_adapter/base.rb#5 +# source://actioncable//lib/action_cable/subscription_adapter/base.rb#7 class ActionCable::SubscriptionAdapter::Base # @return [Base] a new instance of Base # - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#8 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#10 def initialize(server); end # @raise [NotImplementedError] # - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#13 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#15 def broadcast(channel, payload); end - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#29 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#31 def identifier; end # Returns the value of attribute logger. # - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#6 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#8 def logger; end # Returns the value of attribute server. # - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#6 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#8 def server; end # @raise [NotImplementedError] # - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#25 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#27 def shutdown; end # @raise [NotImplementedError] # - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#17 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#19 def subscribe(channel, message_callback, success_callback = T.unsafe(nil)); end # @raise [NotImplementedError] # - # source://actioncable//lib/action_cable/subscription_adapter/base.rb#21 + # source://actioncable//lib/action_cable/subscription_adapter/base.rb#23 def unsubscribe(channel, message_callback); end end -# source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#5 +# source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#7 module ActionCable::SubscriptionAdapter::ChannelPrefix - # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#6 + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#8 def broadcast(channel, payload); end - # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#11 + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#13 def subscribe(channel, callback, success_callback = T.unsafe(nil)); end - # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#16 + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#18 def unsubscribe(channel, callback); end private # Returns the channel name, including channel_prefix specified in cable.yml # - # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#23 + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#25 def channel_with_prefix(channel); end end -# source://actioncable//lib/action_cable/subscription_adapter/inline.rb#5 +# source://actioncable//lib/action_cable/subscription_adapter/inline.rb#7 class ActionCable::SubscriptionAdapter::Inline < ::ActionCable::SubscriptionAdapter::Base # @return [Inline] a new instance of Inline # - # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#6 + # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#8 def initialize(*_arg0); end - # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#11 + # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#13 def broadcast(channel, payload); end - # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#23 + # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#25 def shutdown; end - # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#15 + # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#17 def subscribe(channel, callback, success_callback = T.unsafe(nil)); end - # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#19 + # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#21 def unsubscribe(channel, callback); end private - # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#32 + # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#34 def new_subscriber_map; end - # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#28 + # source://actioncable//lib/action_cable/subscription_adapter/inline.rb#30 def subscriber_map; end end -# source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#5 +# source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#11 +class ActionCable::SubscriptionAdapter::PostgreSQL < ::ActionCable::SubscriptionAdapter::Base + include ::ActionCable::SubscriptionAdapter::ChannelPrefix + + # @return [PostgreSQL] a new instance of PostgreSQL + # + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#14 + def initialize(*_arg0); end + + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#8 + def broadcast(channel, payload); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#33 + def shutdown; end + + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#13 + def subscribe(channel, callback, success_callback = T.unsafe(nil)); end + + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#18 + def unsubscribe(channel, callback); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#52 + def with_broadcast_connection(&block); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#37 + def with_subscriptions_connection(&block); end + + private + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#61 + def channel_identifier(channel); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#65 + def listener; end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#69 + def verify!(pg_conn); end +end + +# source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#75 +class ActionCable::SubscriptionAdapter::PostgreSQL::Listener < ::ActionCable::SubscriptionAdapter::SubscriberMap + # @return [Listener] a new instance of Listener + # + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#76 + def initialize(adapter, event_loop); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#120 + def add_channel(channel, on_success); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#128 + def invoke_callback(*_arg0); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#89 + def listen; end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#124 + def remove_channel(channel); end + + # source://actioncable//lib/action_cable/subscription_adapter/postgresql.rb#115 + def shutdown; end +end + +# source://actioncable//lib/action_cable/subscription_adapter/redis.rb#12 +class ActionCable::SubscriptionAdapter::Redis < ::ActionCable::SubscriptionAdapter::Base + include ::ActionCable::SubscriptionAdapter::ChannelPrefix + + # @return [Redis] a new instance of Redis + # + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#22 + def initialize(*_arg0); end + + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#8 + def broadcast(channel, payload); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#44 + def redis_connection_for_subscriptions; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#18 + def redis_connector; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#18 + def redis_connector=(val); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#40 + def shutdown; end + + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#13 + def subscribe(channel, callback, success_callback = T.unsafe(nil)); end + + # source://actioncable//lib/action_cable/subscription_adapter/channel_prefix.rb#18 + def unsubscribe(channel, callback); end + + private + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#63 + def config_options; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#49 + def listener; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#59 + def redis_connection; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#53 + def redis_connection_for_broadcasts; end + + class << self + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#18 + def redis_connector; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#18 + def redis_connector=(val); end + end +end + +# source://actioncable//lib/action_cable/subscription_adapter/redis.rb#67 +class ActionCable::SubscriptionAdapter::Redis::Listener < ::ActionCable::SubscriptionAdapter::SubscriberMap + # @return [Listener] a new instance of Listener + # + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#68 + def initialize(adapter, config_options, event_loop); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#141 + def add_channel(channel, on_success); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#155 + def invoke_callback(*_arg0); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#89 + def listen(conn); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#149 + def remove_channel(channel); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#128 + def shutdown; end + + private + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#160 + def ensure_listener_running; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#249 + def extract_subscribed_client(conn); end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#204 + def reset; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#197 + def resubscribe; end + + # @return [Boolean] + # + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#185 + def retry_connecting?; end + + # source://actioncable//lib/action_cable/subscription_adapter/redis.rb#177 + def when_connected(&block); end +end + +# source://actioncable//lib/action_cable/subscription_adapter/redis.rb#247 +ActionCable::SubscriptionAdapter::Redis::Listener::ConnectionError = RedisClient::ConnectionError + +# source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#7 class ActionCable::SubscriptionAdapter::SubscriberMap # @return [SubscriberMap] a new instance of SubscriberMap # - # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#6 + # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#8 def initialize; end - # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#47 + # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#49 def add_channel(channel, on_success); end - # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#11 + # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#13 def add_subscriber(channel, subscriber, on_success); end - # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#36 + # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#38 def broadcast(channel, message); end - # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#54 + # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#56 def invoke_callback(callback, message); end - # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#51 + # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#53 def remove_channel(channel); end - # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#25 + # source://actioncable//lib/action_cable/subscription_adapter/subscriber_map.rb#27 def remove_subscriber(channel, subscriber); end end -# == Test adapter for Action Cable +# ## Test adapter for Action Cable # # The test adapter should be used only in testing. Along with # ActionCable::TestHelper it makes a great tool to test your Rails application. # -# To use the test adapter set +adapter+ value to +test+ in your +config/cable.yml+ file. +# To use the test adapter set `adapter` value to `test` in your +# `config/cable.yml` file. # -# NOTE: Test adapter extends the ActionCable::SubscriptionsAdapter::Async adapter, -# so it could be used in system tests too. +# NOTE: `Test` adapter extends the `ActionCable::SubscriptionAdapter::Async` +# adapter, so it could be used in system tests too. # -# source://actioncable//lib/action_cable/subscription_adapter/test.rb#16 +# source://actioncable//lib/action_cable/subscription_adapter/test.rb#17 class ActionCable::SubscriptionAdapter::Test < ::ActionCable::SubscriptionAdapter::Async - # source://actioncable//lib/action_cable/subscription_adapter/test.rb#17 + # source://actioncable//lib/action_cable/subscription_adapter/test.rb#18 def broadcast(channel, payload); end - # source://actioncable//lib/action_cable/subscription_adapter/test.rb#22 + # source://actioncable//lib/action_cable/subscription_adapter/test.rb#23 def broadcasts(channel); end - # source://actioncable//lib/action_cable/subscription_adapter/test.rb#30 + # source://actioncable//lib/action_cable/subscription_adapter/test.rb#31 def clear; end - # source://actioncable//lib/action_cable/subscription_adapter/test.rb#26 + # source://actioncable//lib/action_cable/subscription_adapter/test.rb#27 def clear_messages(channel); end private - # source://actioncable//lib/action_cable/subscription_adapter/test.rb#35 + # source://actioncable//lib/action_cable/subscription_adapter/test.rb#36 def channels_data; end end -# source://actioncable//lib/action_cable/test_case.rb#6 -class ActionCable::TestCase < ::ActiveSupport::TestCase - include ::ActionCable::TestHelper -end +# source://actioncable//lib/action_cable/test_case.rb#8 +class ActionCable::TestCase < ::ActiveSupport::TestCase; end # Provides helper methods for testing Action Cable broadcasting # -# source://actioncable//lib/action_cable/test_helper.rb#5 +# source://actioncable//lib/action_cable/test_helper.rb#7 module ActionCable::TestHelper - # source://actioncable//lib/action_cable/test_helper.rb#16 + # source://actioncable//lib/action_cable/test_helper.rb#18 def after_teardown; end # Asserts that the specified message has been sent to the stream. # - # def test_assert_transmitted_message - # ActionCable.server.broadcast 'messages', text: 'hello' - # assert_broadcast_on('messages', text: 'hello') - # end + # def test_assert_transmitted_message + # ActionCable.server.broadcast 'messages', text: 'hello' + # assert_broadcast_on('messages', text: 'hello') + # end # - # If a block is passed, that block should cause a message with the specified data to be sent. + # If a block is passed, that block should cause a message with the specified + # data to be sent. # - # def test_assert_broadcast_on_again - # assert_broadcast_on('messages', text: 'hello') do - # ActionCable.server.broadcast 'messages', text: 'hello' + # def test_assert_broadcast_on_again + # assert_broadcast_on('messages', text: 'hello') do + # ActionCable.server.broadcast 'messages', text: 'hello' + # end # end - # end # - # source://actioncable//lib/action_cable/test_helper.rb#97 + # source://actioncable//lib/action_cable/test_helper.rb#116 def assert_broadcast_on(stream, data, &block); end - # Asserts that the number of broadcasted messages to the stream matches the given number. - # - # def test_broadcasts - # assert_broadcasts 'messages', 0 - # ActionCable.server.broadcast 'messages', { text: 'hello' } - # assert_broadcasts 'messages', 1 - # ActionCable.server.broadcast 'messages', { text: 'world' } - # assert_broadcasts 'messages', 2 - # end + # Asserts that the number of broadcasted messages to the stream matches the + # given number. # - # If a block is passed, that block should cause the specified number of - # messages to be broadcasted. - # - # def test_broadcasts_again - # assert_broadcasts('messages', 1) do + # def test_broadcasts + # assert_broadcasts 'messages', 0 # ActionCable.server.broadcast 'messages', { text: 'hello' } + # assert_broadcasts 'messages', 1 + # ActionCable.server.broadcast 'messages', { text: 'world' } + # assert_broadcasts 'messages', 2 # end # - # assert_broadcasts('messages', 2) do - # ActionCable.server.broadcast 'messages', { text: 'hi' } - # ActionCable.server.broadcast 'messages', { text: 'how are you?' } + # If a block is passed, that block should cause the specified number of messages + # to be broadcasted. + # + # def test_broadcasts_again + # assert_broadcasts('messages', 1) do + # ActionCable.server.broadcast 'messages', { text: 'hello' } + # end + # + # assert_broadcasts('messages', 2) do + # ActionCable.server.broadcast 'messages', { text: 'hi' } + # ActionCable.server.broadcast 'messages', { text: 'how are you?' } + # end # end - # end # - # source://actioncable//lib/action_cable/test_helper.rb#45 + # source://actioncable//lib/action_cable/test_helper.rb#48 def assert_broadcasts(stream, number, &block); end # Asserts that no messages have been sent to the stream. # - # def test_no_broadcasts - # assert_no_broadcasts 'messages' - # ActionCable.server.broadcast 'messages', { text: 'hi' } - # assert_broadcasts 'messages', 1 - # end + # def test_no_broadcasts + # assert_no_broadcasts 'messages' + # ActionCable.server.broadcast 'messages', { text: 'hi' } + # assert_broadcasts 'messages', 1 + # end # # If a block is passed, that block should not cause any message to be sent. # - # def test_broadcasts_again - # assert_no_broadcasts 'messages' do - # # No job messages should be sent from this block + # def test_broadcasts_again + # assert_no_broadcasts 'messages' do + # # No job messages should be sent from this block + # end # end - # end # # Note: This assertion is simply a shortcut for: # - # assert_broadcasts 'messages', 0, &block + # assert_broadcasts 'messages', 0, &block # - # source://actioncable//lib/action_cable/test_helper.rb#78 + # source://actioncable//lib/action_cable/test_helper.rb#80 def assert_no_broadcasts(stream, &block); end - # source://actioncable//lib/action_cable/test_helper.rb#6 + # source://actioncable//lib/action_cable/test_helper.rb#8 def before_setup; end - # source://actioncable//lib/action_cable/test_helper.rb#126 + # source://actioncable//lib/action_cable/test_helper.rb#146 def broadcasts(*_arg0, **_arg1, &_arg2); end - # source://actioncable//lib/action_cable/test_helper.rb#126 + # Returns the messages that are broadcasted in the block. + # + # def test_broadcasts + # messages = capture_broadcasts('messages') do + # ActionCable.server.broadcast 'messages', { text: 'hi' } + # ActionCable.server.broadcast 'messages', { text: 'how are you?' } + # end + # assert_equal 2, messages.length + # assert_equal({ text: 'hi' }, messages.first) + # assert_equal({ text: 'how are you?' }, messages.last) + # end + # + # source://actioncable//lib/action_cable/test_helper.rb#96 + def capture_broadcasts(stream, &block); end + + # source://actioncable//lib/action_cable/test_helper.rb#146 def clear_messages(*_arg0, **_arg1, &_arg2); end - # source://actioncable//lib/action_cable/test_helper.rb#122 + # source://actioncable//lib/action_cable/test_helper.rb#142 def pubsub_adapter; end private - # source://actioncable//lib/action_cable/test_helper.rb#129 - def broadcasts_size(channel); end + # source://actioncable//lib/action_cable/test_helper.rb#149 + def new_broadcasts_from(current_messages, stream, assertion, &block); end end -# source://actioncable//lib/action_cable/gem_version.rb#9 +# source://actioncable//lib/action_cable/gem_version.rb#11 module ActionCable::VERSION; end -# source://actioncable//lib/action_cable/gem_version.rb#10 +# source://actioncable//lib/action_cable/gem_version.rb#12 ActionCable::VERSION::MAJOR = T.let(T.unsafe(nil), Integer) -# source://actioncable//lib/action_cable/gem_version.rb#11 +# source://actioncable//lib/action_cable/gem_version.rb#13 ActionCable::VERSION::MINOR = T.let(T.unsafe(nil), Integer) -# source://actioncable//lib/action_cable/gem_version.rb#13 +# source://actioncable//lib/action_cable/gem_version.rb#15 ActionCable::VERSION::PRE = T.let(T.unsafe(nil), T.untyped) -# source://actioncable//lib/action_cable/gem_version.rb#15 +# source://actioncable//lib/action_cable/gem_version.rb#17 ActionCable::VERSION::STRING = T.let(T.unsafe(nil), String) -# source://actioncable//lib/action_cable/gem_version.rb#12 +# source://actioncable//lib/action_cable/gem_version.rb#14 ActionCable::VERSION::TINY = T.let(T.unsafe(nil), Integer) + +class ActiveSupport::TestCase < ::Minitest::Test + include ::Turbo::Broadcastable::TestHelper + include ::ActionCable::TestHelper + include ::Turbo::Streams::StreamName +end diff --git a/sorbet/rbi/gems/actionmailbox@7.0.5.rbi b/sorbet/rbi/gems/actionmailbox@7.0.5.rbi deleted file mode 100644 index c71e4b8e3..000000000 --- a/sorbet/rbi/gems/actionmailbox@7.0.5.rbi +++ /dev/null @@ -1,1435 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `actionmailbox` gem. -# Please instead update this file by running `bin/tapioca gem actionmailbox`. - -# source://actionmailbox//lib/action_mailbox.rb#5 -module ActionMailbox - extend ::ActiveSupport::Autoload - - # source://actionmailbox//lib/action_mailbox.rb#14 - def incinerate; end - - # source://actionmailbox//lib/action_mailbox.rb#14 - def incinerate=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#15 - def incinerate_after; end - - # source://actionmailbox//lib/action_mailbox.rb#15 - def incinerate_after=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#12 - def ingress; end - - # source://actionmailbox//lib/action_mailbox.rb#12 - def ingress=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#13 - def logger; end - - # source://actionmailbox//lib/action_mailbox.rb#13 - def logger=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#16 - def queues; end - - # source://actionmailbox//lib/action_mailbox.rb#16 - def queues=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#17 - def storage_service; end - - # source://actionmailbox//lib/action_mailbox.rb#17 - def storage_service=(val); end - - class << self - # source://actionmailbox//lib/action_mailbox.rb#14 - def incinerate; end - - # source://actionmailbox//lib/action_mailbox.rb#14 - def incinerate=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#15 - def incinerate_after; end - - # source://actionmailbox//lib/action_mailbox.rb#15 - def incinerate_after=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#12 - def ingress; end - - # source://actionmailbox//lib/action_mailbox.rb#12 - def ingress=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#13 - def logger; end - - # source://actionmailbox//lib/action_mailbox.rb#13 - def logger=(val); end - - # source://actionmailbox//lib/action_mailbox.rb#16 - def queues; end - - # source://actionmailbox//lib/action_mailbox.rb#16 - def queues=(val); end - - # source://railties/7.0.5/lib/rails/engine.rb#405 - def railtie_helpers_paths; end - - # source://railties/7.0.5/lib/rails/engine.rb#394 - def railtie_namespace; end - - # source://railties/7.0.5/lib/rails/engine.rb#409 - def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end - - # source://actionmailbox//lib/action_mailbox.rb#17 - def storage_service; end - - # source://actionmailbox//lib/action_mailbox.rb#17 - def storage_service=(val); end - - # source://railties/7.0.5/lib/rails/engine.rb#397 - def table_name_prefix; end - - # source://railties/7.0.5/lib/rails/engine.rb#401 - def use_relative_model_naming?; end - end -end - -# The base class for all application mailboxes. Not intended to be inherited from directly. Inherit from -# +ApplicationMailbox+ instead, as that's where the app-specific routing is configured. This routing -# is specified in the following ways: -# -# class ApplicationMailbox < ActionMailbox::Base -# # Any of the recipients of the mail (whether to, cc, bcc) are matched against the regexp. -# routing /^replies@/i => :replies -# -# # Any of the recipients of the mail (whether to, cc, bcc) needs to be an exact match for the string. -# routing "help@example.com" => :help -# -# # Any callable (proc, lambda, etc) object is passed the inbound_email record and is a match if true. -# routing ->(inbound_email) { inbound_email.mail.to.size > 2 } => :multiple_recipients -# -# # Any object responding to #match? is called with the inbound_email record as an argument. Match if true. -# routing CustomAddress.new => :custom -# -# # Any inbound_email that has not been already matched will be sent to the BackstopMailbox. -# routing :all => :backstop -# end -# -# Application mailboxes need to override the #process method, which is invoked by the framework after -# callbacks have been run. The callbacks available are: +before_processing+, +after_processing+, and -# +around_processing+. The primary use case is ensure certain preconditions to processing are fulfilled -# using +before_processing+ callbacks. -# -# If a precondition fails to be met, you can halt the processing using the +#bounced!+ method, -# which will silently prevent any further processing, but not actually send out any bounce notice. You -# can also pair this behavior with the invocation of an Action Mailer class responsible for sending out -# an actual bounce email. This is done using the #bounce_with method, which takes the mail object returned -# by an Action Mailer method, like so: -# -# class ForwardsMailbox < ApplicationMailbox -# before_processing :ensure_sender_is_a_user -# -# private -# def ensure_sender_is_a_user -# unless User.exist?(email_address: mail.from) -# bounce_with UserRequiredMailer.missing(inbound_email) -# end -# end -# end -# -# During the processing of the inbound email, the status will be tracked. Before processing begins, -# the email will normally have the +pending+ status. Once processing begins, just before callbacks -# and the #process method is called, the status is changed to +processing+. If processing is allowed to -# complete, the status is changed to +delivered+. If a bounce is triggered, then +bounced+. If an unhandled -# exception is bubbled up, then +failed+. -# -# Exceptions can be handled at the class level using the familiar +Rescuable+ approach: -# -# class ForwardsMailbox < ApplicationMailbox -# rescue_from(ApplicationSpecificVerificationError) { bounced! } -# end -# -# source://actionmailbox//lib/action_mailbox/base.rb#63 -class ActionMailbox::Base - include ::ActiveSupport::Rescuable - include ::ActionMailbox::Routing - include ::ActiveSupport::Callbacks - include ::ActionMailbox::Callbacks - extend ::ActiveSupport::Rescuable::ClassMethods - extend ::ActionMailbox::Routing::ClassMethods - extend ::ActiveSupport::Callbacks::ClassMethods - extend ::ActiveSupport::DescendantsTracker - extend ::ActionMailbox::Callbacks::ClassMethods - - # @return [Base] a new instance of Base - # - # source://actionmailbox//lib/action_mailbox/base.rb#76 - def initialize(inbound_email); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 - def _process_callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 - def _run_process_callbacks(&block); end - - # Enqueues the given +message+ for delivery and changes the inbound email's status to +:bounced+. - # - # source://actionmailbox//lib/action_mailbox/base.rb#101 - def bounce_with(message); end - - # source://actionmailbox//lib/action_mailbox/base.rb#68 - def bounced!(*_arg0, **_arg1, &_arg2); end - - # source://actionmailbox//lib/action_mailbox/base.rb#68 - def delivered!(*_arg0, **_arg1, &_arg2); end - - # @return [Boolean] - # - # source://actionmailbox//lib/action_mailbox/base.rb#95 - def finished_processing?; end - - # Returns the value of attribute inbound_email. - # - # source://actionmailbox//lib/action_mailbox/base.rb#67 - def inbound_email; end - - # source://actionmailbox//lib/action_mailbox/base.rb#70 - def logger(*_arg0, **_arg1, &_arg2); end - - # source://actionmailbox//lib/action_mailbox/base.rb#68 - def mail(*_arg0, **_arg1, &_arg2); end - - # source://actionmailbox//lib/action_mailbox/base.rb#80 - def perform_processing; end - - # source://actionmailbox//lib/action_mailbox/base.rb#91 - def process; end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers; end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers=(_arg0); end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers?; end - - # source://actionmailbox//lib/action_mailbox/routing.rb#9 - def router; end - - # source://actionmailbox//lib/action_mailbox/routing.rb#9 - def router=(val); end - - private - - # source://actionmailbox//lib/action_mailbox/base.rb#107 - def track_status_of_inbound_email; end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks=(value); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 - def _process_callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 - def _process_callbacks=(value); end - - # source://actionmailbox//lib/action_mailbox/base.rb#72 - def receive(inbound_email); end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers; end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers=(value); end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers?; end - - # source://actionmailbox//lib/action_mailbox/routing.rb#9 - def router; end - - # source://actionmailbox//lib/action_mailbox/routing.rb#9 - def router=(val); end - end -end - -class ActionMailbox::BaseController < ::ActionController::Base - private - - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 - def _layout(lookup_context, formats); end - - def authenticate_by_password; end - def ensure_configured; end - def ingress_name; end - def password; end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 - def middleware_stack; end - end -end - -# Defines the callbacks related to processing. -# -# source://actionmailbox//lib/action_mailbox/callbacks.rb#7 -module ActionMailbox::Callbacks - extend ::ActiveSupport::Concern - include GeneratedInstanceMethods - include ::ActiveSupport::Callbacks - - mixes_in_class_methods GeneratedClassMethods - mixes_in_class_methods ::ActiveSupport::Callbacks::ClassMethods - mixes_in_class_methods ::ActiveSupport::DescendantsTracker - mixes_in_class_methods ::ActionMailbox::Callbacks::ClassMethods - - module GeneratedClassMethods - def __callbacks; end - def __callbacks=(value); end - def __callbacks?; end - end - - module GeneratedInstanceMethods - def __callbacks; end - def __callbacks?; end - end -end - -# source://actionmailbox//lib/action_mailbox/callbacks.rb#0 -module ActionMailbox::Callbacks::ClassMethods - # source://actionmailbox//lib/action_mailbox/callbacks.rb#25 - def after_processing(*methods, &block); end - - # source://actionmailbox//lib/action_mailbox/callbacks.rb#29 - def around_processing(*methods, &block); end - - # source://actionmailbox//lib/action_mailbox/callbacks.rb#21 - def before_processing(*methods, &block); end -end - -# source://actionmailbox//lib/action_mailbox/callbacks.rb#11 -ActionMailbox::Callbacks::TERMINATOR = T.let(T.unsafe(nil), Proc) - -# source://actionmailbox//lib/action_mailbox/engine.rb#12 -class ActionMailbox::Engine < ::Rails::Engine; end - -class ActionMailbox::InboundEmail < ::ActionMailbox::Record - include ::ActionMailbox::InboundEmail::GeneratedAttributeMethods - include ::ActionMailbox::InboundEmail::GeneratedAssociationMethods - - class << self - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - end -end - -module ActionMailbox::InboundEmail::GeneratedAssociationMethods; end -module ActionMailbox::InboundEmail::GeneratedAttributeMethods; end - -module ActionMailbox::InboundEmail::Incineratable - extend ::ActiveSupport::Concern - - def incinerate; end - def incinerate_later; end -end - -class ActionMailbox::InboundEmail::Incineratable::Incineration - def initialize(inbound_email); end - - def run; end - - private - - def due?; end - def processed?; end -end - -module ActionMailbox::InboundEmail::MessageId - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionMailbox::InboundEmail::MessageId::ClassMethods -end - -module ActionMailbox::InboundEmail::MessageId::ClassMethods - def create_and_extract_message_id!(source, **options); end - - private - - def create_and_upload_raw_email!(source); end - def extract_message_id(source); end - def generate_missing_message_id(message_checksum); end -end - -module ActionMailbox::InboundEmail::Routable - extend ::ActiveSupport::Concern - - def route; end - def route_later; end -end - -class ActionMailbox::IncinerationJob < ::ActiveJob::Base - def perform(inbound_email); end - - class << self - # source://activejob/7.0.5/lib/active_job/queue_name.rb#56 - def queue_name; end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers; end - - def schedule(inbound_email); end - end -end - -class ActionMailbox::Record < ::ActiveRecord::Base - include ::ActionMailbox::Record::GeneratedAttributeMethods - include ::ActionMailbox::Record::GeneratedAssociationMethods - - class << self - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - end -end - -module ActionMailbox::Record::GeneratedAssociationMethods; end -module ActionMailbox::Record::GeneratedAttributeMethods; end - -# Encapsulates the routes that live on the ApplicationMailbox and performs the actual routing when -# an inbound_email is received. -# -# source://actionmailbox//lib/action_mailbox/router.rb#6 -class ActionMailbox::Router - # @return [Router] a new instance of Router - # - # source://actionmailbox//lib/action_mailbox/router.rb#9 - def initialize; end - - # source://actionmailbox//lib/action_mailbox/router.rb#19 - def add_route(address, to:); end - - # source://actionmailbox//lib/action_mailbox/router.rb#13 - def add_routes(routes); end - - # source://actionmailbox//lib/action_mailbox/router.rb#33 - def mailbox_for(inbound_email); end - - # source://actionmailbox//lib/action_mailbox/router.rb#23 - def route(inbound_email); end - - private - - # Returns the value of attribute routes. - # - # source://actionmailbox//lib/action_mailbox/router.rb#38 - def routes; end -end - -# source://actionmailbox//lib/action_mailbox/router/route.rb#7 -class ActionMailbox::Router::Route - # source://actionmailbox//lib/action_mailbox/router/route.rb#10 - def initialize(address, to:); end - - # source://actionmailbox//lib/action_mailbox/router/route.rb#8 - def address; end - - # source://actionmailbox//lib/action_mailbox/router/route.rb#31 - def mailbox_class; end - - # source://actionmailbox//lib/action_mailbox/router/route.rb#8 - def mailbox_name; end - - # source://actionmailbox//lib/action_mailbox/router/route.rb#16 - def match?(inbound_email); end - - private - - # source://actionmailbox//lib/action_mailbox/router/route.rb#36 - def ensure_valid_address; end -end - -# source://actionmailbox//lib/action_mailbox/router.rb#7 -class ActionMailbox::Router::RoutingError < ::StandardError; end - -# See ActionMailbox::Base for how to specify routing. -# -# source://actionmailbox//lib/action_mailbox/routing.rb#5 -module ActionMailbox::Routing - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionMailbox::Routing::ClassMethods -end - -# source://actionmailbox//lib/action_mailbox/routing.rb#0 -module ActionMailbox::Routing::ClassMethods - # source://actionmailbox//lib/action_mailbox/routing.rb#21 - def mailbox_for(inbound_email); end - - # source://actionmailbox//lib/action_mailbox/routing.rb#17 - def route(inbound_email); end - - # source://actionmailbox//lib/action_mailbox/routing.rb#13 - def routing(routes); end -end - -class ActionMailbox::RoutingJob < ::ActiveJob::Base - def perform(inbound_email); end - - class << self - # source://activejob/7.0.5/lib/active_job/queue_name.rb#56 - def queue_name; end - end -end - -# source://actionmailbox//lib/action_mailbox/test_case.rb#7 -class ActionMailbox::TestCase < ::ActiveSupport::TestCase - include ::ActionMailbox::TestHelper -end - -# source://actionmailbox//lib/action_mailbox/test_helper.rb#6 -module ActionMailbox::TestHelper - # Create an InboundEmail record using an eml fixture in the format of message/rfc822 - # referenced with +fixture_name+ located in +test/fixtures/files/fixture_name+. - # - # source://actionmailbox//lib/action_mailbox/test_helper.rb#9 - def create_inbound_email_from_fixture(fixture_name, status: T.unsafe(nil)); end - - # Creates an InboundEmail by specifying through options or a block. - # - # ==== Options - # - # * :status - The +status+ to set for the created InboundEmail. - # For possible statuses, see its documentation. - # - # ==== Creating a simple email - # - # When you only need to set basic fields like +from+, +to+, +subject+, and - # +body+, you can pass them directly as options. - # - # create_inbound_email_from_mail(from: "david@loudthinking.com", subject: "Hello!") - # - # ==== Creating a multi-part email - # - # When you need to create a more intricate email, like a multi-part email - # that contains both a plaintext version and an HTML version, you can pass a - # block. - # - # create_inbound_email_from_mail do - # to "David Heinemeier Hansson " - # from "Bilbo Baggins " - # subject "Come down to the Shire!" - # - # text_part do - # body "Please join us for a party at Bag End" - # end - # - # html_part do - # body "

Please join us for a party at Bag End

" - # end - # end - # - # As with +Mail.new+, you can also use a block parameter to define the parts - # of the message: - # - # create_inbound_email_from_mail do |mail| - # mail.to "David Heinemeier Hansson " - # mail.from "Bilbo Baggins " - # mail.subject "Come down to the Shire!" - # - # mail.text_part do |part| - # part.body "Please join us for a party at Bag End" - # end - # - # mail.html_part do |part| - # part.body "

Please join us for a party at Bag End

" - # end - # end - # - # source://actionmailbox//lib/action_mailbox/test_helper.rb#63 - def create_inbound_email_from_mail(status: T.unsafe(nil), **mail_options, &block); end - - # Create an InboundEmail using the raw rfc822 +source+ as text. - # - # source://actionmailbox//lib/action_mailbox/test_helper.rb#72 - def create_inbound_email_from_source(source, status: T.unsafe(nil)); end - - # Create an InboundEmail from fixture using the same arguments as create_inbound_email_from_fixture - # and immediately route it to processing. - # - # source://actionmailbox//lib/action_mailbox/test_helper.rb#79 - def receive_inbound_email_from_fixture(*args); end - - # Create an InboundEmail using the same options or block as - # create_inbound_email_from_mail, then immediately route it for processing. - # - # source://actionmailbox//lib/action_mailbox/test_helper.rb#85 - def receive_inbound_email_from_mail(**kwargs, &block); end - - # Create an InboundEmail using the same arguments as create_inbound_email_from_source and immediately route it - # to processing. - # - # source://actionmailbox//lib/action_mailbox/test_helper.rb#91 - def receive_inbound_email_from_source(*args); end -end - -# source://actionmailbox//lib/action_mailbox/mail_ext/address_equality.rb#3 -module Mail - class << self - # source://mail/2.8.1/lib/mail/mail.rb#163 - def all(*args, &block); end - - # source://mail/2.8.1/lib/mail/mail.rb#183 - def connection(&block); end - - # source://mail/2.8.1/lib/mail/mail.rb#98 - def defaults(&block); end - - # source://mail/2.8.1/lib/mail/mail.rb#174 - def delete_all(*args, &block); end - - # source://mail/2.8.1/lib/mail/mail.rb#131 - def deliver(*args, &block); end - - # source://mail/2.8.1/lib/mail/mail.rb#103 - def delivery_method; end - - # source://mail/2.8.1/lib/mail.rb#35 - def eager_autoload!; end - - # source://mail/2.8.1/lib/mail/mail.rb#139 - def find(*args, &block); end - - # source://mail/2.8.1/lib/mail/mail.rb#145 - def find_and_delete(*args, &block); end - - # source://mail/2.8.1/lib/mail/mail.rb#151 - def first(*args, &block); end - - # source://actionmailbox//lib/action_mailbox/mail_ext/from_source.rb#4 - def from_source(source); end - - # source://mail/2.8.1/lib/mail/mail.rb#233 - def inform_interceptors(mail); end - - # source://mail/2.8.1/lib/mail/mail.rb#227 - def inform_observers(mail); end - - # source://mail/2.8.1/lib/mail/mail.rb#157 - def last(*args, &block); end - - # source://mail/2.8.1/lib/mail/mail.rb#50 - def new(*args, &block); end - - # source://mail/2.8.1/lib/mail/mail.rb#243 - def random_tag; end - - # source://mail/2.8.1/lib/mail/mail.rb#168 - def read(filename); end - - # source://mail/2.8.1/lib/mail/mail.rb#179 - def read_from_string(mail_as_string); end - - # source://mail/2.8.1/lib/mail.rb#23 - def register_autoload(name, path); end - - # source://mail/2.8.1/lib/mail/mail.rb#215 - def register_interceptor(interceptor); end - - # source://mail/2.8.1/lib/mail/mail.rb#196 - def register_observer(observer); end - - # source://mail/2.8.1/lib/mail/mail.rb#108 - def retriever_method; end - - # source://mail/2.8.1/lib/mail/mail.rb#252 - def something_random; end - - # source://mail/2.8.1/lib/mail/mail.rb#256 - def uniq; end - - # source://mail/2.8.1/lib/mail/mail.rb#223 - def unregister_interceptor(interceptor); end - - # source://mail/2.8.1/lib/mail/mail.rb#204 - def unregister_observer(observer); end - end -end - -# source://actionmailbox//lib/action_mailbox/mail_ext/address_equality.rb#4 -class Mail::Address - # source://mail/2.8.1/lib/mail/elements/address.rb#25 - def initialize(value = T.unsafe(nil)); end - - # source://actionmailbox//lib/action_mailbox/mail_ext/address_equality.rb#5 - def ==(other_address); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#65 - def address(output_type = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#79 - def address=(value); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#132 - def comments; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#173 - def decoded; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#87 - def display_name(output_type = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#99 - def display_name=(str); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#118 - def domain(output_type = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#169 - def encoded; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#47 - def format(output_type = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#177 - def group; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#164 - def inspect; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#108 - def local(output_type = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#147 - def name; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#36 - def raw; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#156 - def to_s; end - - private - - # source://mail/2.8.1/lib/mail/elements/address.rb#237 - def format_comments; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#254 - def get_comments; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#218 - def get_display_name; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#250 - def get_domain; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#246 - def get_local; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#227 - def get_name; end - - # source://mail/2.8.1/lib/mail/elements/address.rb#183 - def parse(value = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#198 - def strip_all_comments(string); end - - # source://mail/2.8.1/lib/mail/elements/address.rb#207 - def strip_domain_comments(value); end - - class << self - # source://actionmailbox//lib/action_mailbox/mail_ext/address_wrapping.rb#5 - def wrap(address); end - end -end - -# source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#4 -class Mail::Message - # source://mail/2.8.1/lib/mail/message.rb#107 - def initialize(*args, &block); end - - # source://mail/2.8.1/lib/mail/message.rb#334 - def <=>(other); end - - # source://mail/2.8.1/lib/mail/message.rb#373 - def ==(other); end - - # source://mail/2.8.1/lib/mail/message.rb#1334 - def [](name); end - - # source://mail/2.8.1/lib/mail/message.rb#1316 - def []=(name, value); end - - # source://mail/2.8.1/lib/mail/message.rb#1558 - def action; end - - # source://mail/2.8.1/lib/mail/message.rb#1472 - def add_charset; end - - # source://mail/2.8.1/lib/mail/message.rb#1487 - def add_content_transfer_encoding; end - - # source://mail/2.8.1/lib/mail/message.rb#1465 - def add_content_type; end - - # source://mail/2.8.1/lib/mail/message.rb#1448 - def add_date(date_val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1757 - def add_file(values); end - - # source://mail/2.8.1/lib/mail/message.rb#1438 - def add_message_id(msg_id_val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1458 - def add_mime_version(ver_val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1701 - def add_part(part); end - - # source://mail/2.8.1/lib/mail/message.rb#1927 - def all_parts; end - - # source://mail/2.8.1/lib/mail/message.rb#1918 - def attachment; end - - # source://mail/2.8.1/lib/mail/message.rb#1913 - def attachment?; end - - # source://mail/2.8.1/lib/mail/message.rb#1626 - def attachments; end - - # source://mail/2.8.1/lib/mail/message.rb#500 - def bcc(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#512 - def bcc=(val); end - - # source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#21 - def bcc_addresses; end - - # source://mail/2.8.1/lib/mail/message.rb#1306 - def bcc_addrs; end - - # source://mail/2.8.1/lib/mail/message.rb#1251 - def body(value = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1237 - def body=(value); end - - # source://mail/2.8.1/lib/mail/message.rb#1260 - def body_encoding(value = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1268 - def body_encoding=(value); end - - # source://mail/2.8.1/lib/mail/message.rb#1554 - def bounced?; end - - # source://mail/2.8.1/lib/mail/message.rb#1583 - def boundary; end - - # source://mail/2.8.1/lib/mail/message.rb#541 - def cc(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#553 - def cc=(val); end - - # source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#17 - def cc_addresses; end - - # source://mail/2.8.1/lib/mail/message.rb#1300 - def cc_addrs; end - - # source://mail/2.8.1/lib/mail/message.rb#1497 - def charset; end - - # source://mail/2.8.1/lib/mail/message.rb#1506 - def charset=(value); end - - # source://mail/2.8.1/lib/mail/message.rb#557 - def comments(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#561 - def comments=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#565 - def content_description(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#569 - def content_description=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#573 - def content_disposition(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#577 - def content_disposition=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#581 - def content_id(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#585 - def content_id=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#589 - def content_location(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#593 - def content_location=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#597 - def content_transfer_encoding(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#601 - def content_transfer_encoding=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#605 - def content_type(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#609 - def content_type=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1523 - def content_type_parameters; end - - # source://mail/2.8.1/lib/mail/message.rb#1773 - def convert_to_multipart; end - - # source://mail/2.8.1/lib/mail/message.rb#613 - def date(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#617 - def date=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1907 - def decode_body; end - - # source://mail/2.8.1/lib/mail/message.rb#1886 - def decoded; end - - # source://mail/2.8.1/lib/mail/message.rb#1204 - def default(sym, val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#250 - def deliver; end - - # source://mail/2.8.1/lib/mail/message.rb#267 - def deliver!; end - - # source://mail/2.8.1/lib/mail/message.rb#199 - def delivery_handler; end - - # source://mail/2.8.1/lib/mail/message.rb#199 - def delivery_handler=(_arg0); end - - # source://mail/2.8.1/lib/mail/message.rb#274 - def delivery_method(method = T.unsafe(nil), settings = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1543 - def delivery_status_part; end - - # source://mail/2.8.1/lib/mail/message.rb#1538 - def delivery_status_report?; end - - # source://mail/2.8.1/lib/mail/message.rb#1282 - def destinations; end - - # source://mail/2.8.1/lib/mail/message.rb#1570 - def diagnostic_code; end - - # source://mail/2.8.1/lib/mail/message.rb#1803 - def encoded; end - - # source://mail/2.8.1/lib/mail/message.rb#418 - def envelope_date; end - - # source://mail/2.8.1/lib/mail/message.rb#414 - def envelope_from; end - - # source://mail/2.8.1/lib/mail/message.rb#1566 - def error_status; end - - # source://mail/2.8.1/lib/mail/message.rb#471 - def errors; end - - # source://mail/2.8.1/lib/mail/message.rb#1923 - def filename; end - - # source://mail/2.8.1/lib/mail/message.rb#1562 - def final_recipient; end - - # source://mail/2.8.1/lib/mail/message.rb#1931 - def find_first_mime_type(mt); end - - # source://mail/2.8.1/lib/mail/message.rb#658 - def from(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#670 - def from=(val); end - - # source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#5 - def from_address; end - - # source://mail/2.8.1/lib/mail/message.rb#1288 - def from_addrs; end - - # source://mail/2.8.1/lib/mail/message.rb#1630 - def has_attachments?; end - - # source://mail/2.8.1/lib/mail/message.rb#1423 - def has_charset?; end - - # source://mail/2.8.1/lib/mail/message.rb#1428 - def has_content_transfer_encoding?; end - - # source://mail/2.8.1/lib/mail/message.rb#1418 - def has_content_type?; end - - # source://mail/2.8.1/lib/mail/message.rb#1408 - def has_date?; end - - # source://mail/2.8.1/lib/mail/message.rb#1402 - def has_message_id?; end - - # source://mail/2.8.1/lib/mail/message.rb#1414 - def has_mime_version?; end - - # source://mail/2.8.1/lib/mail/message.rb#443 - def header(value = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#428 - def header=(value); end - - # source://mail/2.8.1/lib/mail/message.rb#1396 - def header_fields; end - - # source://mail/2.8.1/lib/mail/message.rb#448 - def headers(hash = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1635 - def html_part(&block); end - - # source://mail/2.8.1/lib/mail/message.rb#1655 - def html_part=(msg); end - - # source://mail/2.8.1/lib/mail/message.rb#674 - def in_reply_to(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#678 - def in_reply_to=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#240 - def inform_interceptors; end - - # source://mail/2.8.1/lib/mail/message.rb#236 - def inform_observers; end - - # source://mail/2.8.1/lib/mail/message.rb#1873 - def inspect; end - - # source://mail/2.8.1/lib/mail/message.rb#1877 - def inspect_structure; end - - # source://mail/2.8.1/lib/mail/message.rb#1960 - def is_marked_for_delete?; end - - # source://mail/2.8.1/lib/mail/message.rb#682 - def keywords(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#686 - def keywords=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1513 - def main_type; end - - # source://mail/2.8.1/lib/mail/message.rb#1947 - def mark_for_delete=(value = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#703 - def message_id(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#712 - def message_id=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1377 - def method_missing(name, *args, &block); end - - # source://mail/2.8.1/lib/mail/message.rb#1492 - def mime_type; end - - # source://mail/2.8.1/lib/mail/message.rb#729 - def mime_version(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#739 - def mime_version=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1528 - def multipart?; end - - # source://mail/2.8.1/lib/mail/message.rb#1533 - def multipart_report?; end - - # source://mail/2.8.1/lib/mail/message.rb#1722 - def part(params = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1588 - def parts; end - - # source://mail/2.8.1/lib/mail/message.rb#223 - def perform_deliveries; end - - # source://mail/2.8.1/lib/mail/message.rb#223 - def perform_deliveries=(_arg0); end - - # source://mail/2.8.1/lib/mail/message.rb#230 - def raise_delivery_errors; end - - # source://mail/2.8.1/lib/mail/message.rb#230 - def raise_delivery_errors=(_arg0); end - - # source://mail/2.8.1/lib/mail/message.rb#410 - def raw_envelope; end - - # source://mail/2.8.1/lib/mail/message.rb#397 - def raw_source; end - - # source://mail/2.8.1/lib/mail/message.rb#1899 - def read; end - - # source://mail/2.8.1/lib/mail/message.rb#1791 - def ready_to_send!; end - - # source://mail/2.8.1/lib/mail/message.rb#743 - def received(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#751 - def received=(val); end - - # source://actionmailbox//lib/action_mailbox/mail_ext/recipients.rb#5 - def recipients; end - - # source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#9 - def recipients_addresses; end - - # source://mail/2.8.1/lib/mail/message.rb#755 - def references(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#759 - def references=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1574 - def remote_mta; end - - # source://mail/2.8.1/lib/mail/message.rb#282 - def reply(*args, &block); end - - # source://mail/2.8.1/lib/mail/message.rb#788 - def reply_to(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#800 - def reply_to=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#829 - def resent_bcc(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#841 - def resent_bcc=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#870 - def resent_cc(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#882 - def resent_cc=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#886 - def resent_date(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#890 - def resent_date=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#919 - def resent_from(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#931 - def resent_from=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#935 - def resent_message_id(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#939 - def resent_message_id=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#958 - def resent_sender(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#968 - def resent_sender=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#997 - def resent_to(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1009 - def resent_to=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1578 - def retryable?; end - - # source://mail/2.8.1/lib/mail/message.rb#1014 - def return_path(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1019 - def return_path=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1037 - def sender(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1047 - def sender=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#402 - def set_envelope(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1939 - def skip_deletion; end - - # source://mail/2.8.1/lib/mail/message.rb#1067 - def smtp_envelope_from(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1081 - def smtp_envelope_from=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1100 - def smtp_envelope_to(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1117 - def smtp_envelope_to=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1518 - def sub_type; end - - # source://mail/2.8.1/lib/mail/message.rb#1142 - def subject(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1152 - def subject=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1964 - def text?; end - - # source://mail/2.8.1/lib/mail/message.rb#1644 - def text_part(&block); end - - # source://mail/2.8.1/lib/mail/message.rb#1679 - def text_part=(msg); end - - # source://mail/2.8.1/lib/mail/message.rb#1181 - def to(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#1193 - def to=(val); end - - # source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#13 - def to_addresses; end - - # source://mail/2.8.1/lib/mail/message.rb#1294 - def to_addrs; end - - # source://mail/2.8.1/lib/mail/message.rb#1869 - def to_s; end - - # source://mail/2.8.1/lib/mail/message.rb#1823 - def to_yaml(opts = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#621 - def transport_encoding(val = T.unsafe(nil)); end - - # source://mail/2.8.1/lib/mail/message.rb#629 - def transport_encoding=(val); end - - # source://mail/2.8.1/lib/mail/message.rb#1811 - def without_attachments!; end - - # source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#25 - def x_original_to_addresses; end - - private - - # source://mail/2.8.1/lib/mail/message.rb#2067 - def add_boundary; end - - # source://mail/2.8.1/lib/mail/message.rb#2032 - def add_encoding_to_body; end - - # source://mail/2.8.1/lib/mail/message.rb#2062 - def add_multipart_alternate_header; end - - # source://mail/2.8.1/lib/mail/message.rb#2079 - def add_multipart_mixed_header; end - - # source://mail/2.8.1/lib/mail/message.rb#2048 - def add_required_fields; end - - # source://mail/2.8.1/lib/mail/message.rb#2056 - def add_required_message_fields; end - - # source://actionmailbox//lib/action_mailbox/mail_ext/addresses.rb#30 - def address_list(obj); end - - # source://mail/2.8.1/lib/mail/message.rb#2025 - def allowed_encodings; end - - # source://mail/2.8.1/lib/mail/message.rb#1990 - def body_lazy(value); end - - # source://mail/2.8.1/lib/mail/message.rb#2152 - def decode_body_as_text; end - - # source://mail/2.8.1/lib/mail/message.rb#2142 - def do_delivery; end - - # source://mail/2.8.1/lib/mail/message.rb#2124 - def find_attachment; end - - # source://mail/2.8.1/lib/mail/message.rb#2038 - def identify_and_set_transfer_encoding; end - - # source://mail/2.8.1/lib/mail/message.rb#2086 - def init_with_hash(hash); end - - # source://mail/2.8.1/lib/mail/message.rb#2116 - def init_with_string(string); end - - # source://mail/2.8.1/lib/mail/message.rb#384 - def initialize_copy(original); end - - # source://mail/2.8.1/lib/mail/message.rb#1979 - def parse_message; end - - # source://mail/2.8.1/lib/mail/message.rb#2005 - def process_body_raw; end - - # source://mail/2.8.1/lib/mail/message.rb#1985 - def raw_source=(value); end - - # source://mail/2.8.1/lib/mail/message.rb#2021 - def separate_parts; end - - # source://mail/2.8.1/lib/mail/message.rb#2013 - def set_envelope_header; end - - class << self - # source://mail/2.8.1/lib/mail/message.rb#232 - def default_charset; end - - # source://mail/2.8.1/lib/mail/message.rb#233 - def default_charset=(charset); end - - # source://mail/2.8.1/lib/mail/message.rb#1865 - def from_hash(hash); end - - # source://mail/2.8.1/lib/mail/message.rb#1843 - def from_yaml(str); end - end -end - -# source://mail/2.8.1/lib/mail/message.rb#1970 -Mail::Message::HEADER_SEPARATOR = T.let(T.unsafe(nil), Regexp) - -# source://mail/2.8.1/lib/mail/mail.rb#241 -Mail::RANDOM_TAG = T.let(T.unsafe(nil), String) - -module Rails - class << self - # source://railties/7.0.5/lib/rails.rb#38 - def app_class; end - - # source://railties/7.0.5/lib/rails.rb#38 - def app_class=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#39 - def application; end - - # source://railties/7.0.5/lib/rails.rb#37 - def application=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#123 - def autoloaders; end - - # source://railties/7.0.5/lib/rails.rb#50 - def backtrace_cleaner; end - - # source://railties/7.0.5/lib/rails.rb#38 - def cache; end - - # source://railties/7.0.5/lib/rails.rb#38 - def cache=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#46 - def configuration; end - - # source://railties/7.0.5/lib/rails.rb#72 - def env; end - - # source://railties/7.0.5/lib/rails.rb#79 - def env=(environment); end - - # source://railties/7.0.5/lib/rails.rb#90 - def error; end - - # source://railties/7.0.5/lib/rails/gem_version.rb#5 - def gem_version; end - - # source://railties/7.0.5/lib/rails.rb#103 - def groups(*groups); end - - # source://railties/7.0.5/lib/rails.rb#43 - def initialize!(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails.rb#43 - def initialized?(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails.rb#38 - def logger; end - - # source://railties/7.0.5/lib/rails.rb#38 - def logger=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#119 - def public_path; end - - # source://railties/7.0.5/lib/rails.rb#63 - def root; end - - # source://railties/7.0.5/lib/rails/version.rb#7 - def version; end - end -end - -# source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#11 -Rails::Html = Rails::HTML diff --git a/sorbet/rbi/gems/actionmailbox@7.2.0.rbi b/sorbet/rbi/gems/actionmailbox@7.2.0.rbi new file mode 100644 index 000000000..f84bdc572 --- /dev/null +++ b/sorbet/rbi/gems/actionmailbox@7.2.0.rbi @@ -0,0 +1,9 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `actionmailbox` gem. +# Please instead update this file by running `bin/tapioca gem actionmailbox`. + + +# THIS IS AN EMPTY RBI FILE. +# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/actionmailer@7.0.5.rbi b/sorbet/rbi/gems/actionmailer@7.2.0.rbi similarity index 71% rename from sorbet/rbi/gems/actionmailer@7.0.5.rbi rename to sorbet/rbi/gems/actionmailer@7.2.0.rbi index 9e3c2d0e0..96b2316dd 100644 --- a/sorbet/rbi/gems/actionmailer@7.0.5.rbi +++ b/sorbet/rbi/gems/actionmailer@7.2.0.rbi @@ -4,37 +4,45 @@ # This is an autogenerated file for types exported from the `actionmailer` gem. # Please instead update this file by running `bin/tapioca gem actionmailer`. + +# :include: ../README.rdoc +# # source://actionmailer//lib/action_mailer/gem_version.rb#3 module ActionMailer extend ::ActiveSupport::Autoload class << self - # source://actionmailer//lib/action_mailer.rb#56 + # source://actionmailer//lib/action_mailer/deprecator.rb#4 + def deprecator; end + + # source://actionmailer//lib/action_mailer.rb#61 def eager_load!; end - # Returns the currently loaded version of Action Mailer as a Gem::Version. + # Returns the currently loaded version of Action Mailer as a +Gem::Version+. # # source://actionmailer//lib/action_mailer/gem_version.rb#5 def gem_version; end # Returns the currently loaded version of Action Mailer as a - # Gem::Version. + # +Gem::Version+. # # source://actionmailer//lib/action_mailer/version.rb#8 def version; end end end +# = Action Mailer \Base +# # Action Mailer allows you to send email from your application using a mailer model and views. # -# = Mailer Models +# == Mailer Models # # To use Action Mailer, you need to create a mailer model. # # $ bin/rails generate mailer Notifier # # The generated model inherits from ApplicationMailer which in turn -# inherits from ActionMailer::Base. A mailer model defines methods +# inherits from +ActionMailer::Base+. A mailer model defines methods # used to generate an email message. In these methods, you can set up variables to be used in # the mailer views, options on the mail itself such as the :from address, and attachments. # @@ -71,7 +79,7 @@ end # # * mail - Allows you to specify email to be sent. # -# The hash passed to the mail method allows you to specify any header that a Mail::Message +# The hash passed to the mail method allows you to specify any header that a +Mail::Message+ # will accept (any valid email header including optional fields). # # The +mail+ method, if not passed a block, will inspect your views and send all the views with @@ -98,7 +106,7 @@ end # format.html { render "some_other_template" } # end # -# = Mailer views +# == Mailer views # # Like Action Controller, each mailer class has a corresponding view directory in which each # method of the class looks for a template with its name. @@ -126,7 +134,7 @@ end # <%= truncate(@note.body, length: 25) %> # # -# = Generating URLs +# == Generating URLs # # URLs can be generated in mailer views using url_for or named routes. Unlike controllers from # Action Pack, the mailer instance doesn't have any context about the incoming request, so you'll need @@ -154,7 +162,7 @@ end # # By default when config.force_ssl is +true+, URLs generated for hosts will use the HTTPS protocol. # -# = Sending mail +# == Sending mail # # Once a mailer action and template are defined, you can deliver your message or defer its creation and # delivery for later: @@ -164,7 +172,7 @@ end # mail.deliver_now # generates and sends the email now # # The ActionMailer::MessageDelivery class is a wrapper around a delegate that will call -# your method to generate the mail. If you want direct access to the delegator, or Mail::Message, +# your method to generate the mail. If you want direct access to the delegator, or +Mail::Message+, # you can call the message method on the ActionMailer::MessageDelivery object. # # NotifierMailer.welcome(User.first).message # => a Mail::Message object @@ -179,7 +187,7 @@ end # You never instantiate your mailer class. Rather, you just call the method you defined on the class itself. # All instance methods are expected to return a message object to be sent. # -# = Multipart Emails +# == Multipart Emails # # Multipart messages can also be used implicitly because Action Mailer will automatically detect and use # multipart templates, where each template is named after the name of the action, followed by the content @@ -200,7 +208,7 @@ end # This means that you'll have to manually add each part to the email and set the content type of the email # to multipart/alternative. # -# = Attachments +# == Attachments # # Sending attachment in emails is easy: # @@ -227,7 +235,7 @@ end # end # end # -# You can also send attachments with html template, in this case you need to add body, attachments, +# You can also send attachments with HTML template, in this case you need to add body, attachments, # and custom content type like this: # # class NotifierMailer < ApplicationMailer @@ -240,7 +248,7 @@ end # end # end # -# = Inline Attachments +# == Inline Attachments # # You can also specify that a file should be displayed inline with other HTML. This is useful # if you want to display a corporate logo or a photo. @@ -266,7 +274,7 @@ end # # <%= image_tag attachments['photo.png'].url, alt: 'Our Photo', class: 'photo' -%> # -# = Observing and Intercepting Mails +# == Observing and Intercepting Mails # # Action Mailer provides hooks into the Mail observer and interceptor methods. These allow you to # register classes that are called during the mail delivery life cycle. @@ -277,9 +285,9 @@ end # An interceptor class must implement the :delivering_email(message) method which will be # called before the email is sent, allowing you to make modifications to the email before it hits # the delivery agents. Your class should make any needed modifications directly to the passed -# in Mail::Message instance. +# in +Mail::Message+ instance. # -# = Default Hash +# == Default \Hash # # Action Mailer provides some intelligent defaults for your emails, these are usually specified in a # default method inside the class definition: @@ -288,15 +296,15 @@ end # default sender: 'system@example.com' # end # -# You can pass in any header value that a Mail::Message accepts. Out of the box, -# ActionMailer::Base sets the following: +# You can pass in any header value that a +Mail::Message+ accepts. Out of the box, +# +ActionMailer::Base+ sets the following: # # * mime_version: "1.0" # * charset: "UTF-8" # * content_type: "text/plain" # * parts_order: [ "text/plain", "text/enriched", "text/html" ] # -# parts_order and charset are not actually valid Mail::Message header fields, +# parts_order and charset are not actually valid +Mail::Message+ header fields, # but Action Mailer translates them appropriately and sets the correct values. # # As you can pass in any header, you need to either quote the header as a string, or pass it in as @@ -328,14 +336,16 @@ end # # config.action_mailer.default_options = { from: "no-reply@example.org" } # -# = Callbacks +# == \Callbacks # -# You can specify callbacks using before_action and after_action for configuring your messages. -# This may be useful, for example, when you want to add default inline attachments for all -# messages sent out by a certain mailer class: +# You can specify callbacks using before_action and after_action for configuring your messages, +# and using before_deliver and after_deliver for wrapping the delivery process. +# For example, when you want to add default inline attachments and log delivery for all messages +# sent out by a certain mailer class: # # class NotifierMailer < ApplicationMailer # before_action :add_inline_attachment! +# after_deliver :log_delivery # # def welcome # mail @@ -345,9 +355,13 @@ end # def add_inline_attachment! # attachments.inline["footer.jpg"] = File.read('/path/to/filename.jpg') # end +# +# def log_delivery +# Rails.logger.info "Sent email with message id '#{message.message_id}' at #{Time.current}." +# end # end # -# Callbacks in Action Mailer are implemented using +# Action callbacks in Action Mailer are implemented using # AbstractController::Callbacks, so you can define and configure # callbacks in the same manner that you would use callbacks in classes that # inherit from ActionController::Base. @@ -356,7 +370,7 @@ end # using before_action rather than after_action in your # Action Mailer classes so that headers are parsed properly. # -# = Rescuing Errors +# == Rescuing Errors # # +rescue+ blocks inside of a mailer method cannot rescue errors that occur # outside of rendering -- for example, record deserialization errors in a @@ -379,10 +393,10 @@ end # end # end # -# = Previewing emails +# == Previewing emails # # You can preview your email templates visually by adding a mailer preview file to the -# ActionMailer::Base.preview_path. Since most emails do something interesting +# ActionMailer::Base.preview_paths. Since most emails do something interesting # with database data, you'll need to write some scenarios to load messages with fake data: # # class NotifierMailerPreview < ActionMailer::Preview @@ -391,12 +405,12 @@ end # end # end # -# Methods must return a Mail::Message object which can be generated by calling the mailer +# Methods must return a +Mail::Message+ object which can be generated by calling the mailer # method without the additional deliver_now / deliver_later. The location of the -# mailer previews directory can be configured using the preview_path option which has a default +# mailer preview directories can be configured using the preview_paths option which has a default # of test/mailers/previews: # -# config.action_mailer.preview_path = "#{Rails.root}/lib/mailer_previews" +# config.action_mailer.preview_paths << "#{Rails.root}/lib/mailer_previews" # # An overview of all previews is accessible at http://localhost:3000/rails/mailers # on a running development server instance. @@ -416,7 +430,7 @@ end # and register_preview_interceptor if they should operate on both sending and # previewing emails. # -# = Configuration options +# == Configuration options # # These options are specified on the class level, like # ActionMailer::Base.raise_delivery_errors = true @@ -439,20 +453,21 @@ end # This is a symbol and one of :plain (will send the password Base64 encoded), :login (will # send the password Base64 encoded) or :cram_md5 (combines a Challenge/Response mechanism to exchange # information and a cryptographic Message Digest 5 algorithm to hash important information) -# * :enable_starttls - Use STARTTLS when connecting to your SMTP server and fail if unsupported. Defaults to false. +# * :enable_starttls - Use STARTTLS when connecting to your SMTP server and fail if unsupported. Defaults +# to false. Requires at least version 2.7 of the Mail gem. # * :enable_starttls_auto - Detects if STARTTLS is enabled in your SMTP server and starts # to use it. Defaults to true. # * :openssl_verify_mode - When using TLS, you can set how OpenSSL checks the certificate. This is # really useful if you need to validate a self-signed and/or a wildcard certificate. You can use the name # of an OpenSSL verify constant ('none' or 'peer') or directly the constant -# (OpenSSL::SSL::VERIFY_NONE or OpenSSL::SSL::VERIFY_PEER). +# (+OpenSSL::SSL::VERIFY_NONE+ or +OpenSSL::SSL::VERIFY_PEER+). # * :ssl/:tls Enables the SMTP connection to use SMTP/TLS (SMTPS: SMTP over direct TLS connection) # * :open_timeout Number of seconds to wait while attempting to open a connection. # * :read_timeout Number of seconds to wait until timing-out a read(2) call. # # * sendmail_settings - Allows you to override options for the :sendmail delivery method. # * :location - The location of the sendmail executable. Defaults to /usr/sbin/sendmail. -# * :arguments - The command line arguments. Defaults to -i with -f sender@address +# * :arguments - The command line arguments. Defaults to %w[ -i ] with -f sender@address # added automatically before the message is sent. # # * file_settings - Allows you to override options for the :file delivery method. @@ -473,20 +488,25 @@ end # * deliveries - Keeps an array of all the emails sent out through the Action Mailer with # delivery_method :test. Most useful for unit and functional testing. # -# * delivery_job - The job class used with deliver_later. Defaults to -# +ActionMailer::MailDeliveryJob+. +# * delivery_job - The job class used with deliver_later. Mailers can set this to use a +# custom delivery job. Defaults to +ActionMailer::MailDeliveryJob+. # -# * deliver_later_queue_name - The name of the queue used with deliver_later. +# * deliver_later_queue_name - The queue name used by deliver_later with the default +# delivery_job. Mailers can set this to use a custom queue name. # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://actionmailer//lib/action_mailer/base.rb#466 +# source://actionmailer//lib/action_mailer/base.rb#476 class ActionMailer::Base < ::AbstractController::Base + include ::ActionMailer::Callbacks + include ::ActiveSupport::Callbacks include ::ActionMailer::DeliveryMethods + include ::ActionMailer::QueuedDelivery include ::ActiveSupport::Rescuable include ::ActionMailer::Rescuable include ::ActionMailer::Parameterized include ::ActionMailer::Previews + include ::ActionMailer::FormBuilder include ::ActionView::ViewPaths include ::AbstractController::Rendering include ::AbstractController::Logger @@ -494,21 +514,23 @@ class ActionMailer::Base < ::AbstractController::Base include ::AbstractController::Helpers include ::AbstractController::Translation include ::AbstractController::AssetPaths - include ::ActiveSupport::Callbacks include ::AbstractController::Callbacks include ::AbstractController::Caching::Fragments include ::AbstractController::Caching::ConfigMethods include ::AbstractController::Caching include ::ActionView::Rendering include ::ActionView::Layouts + extend ::ActionMailer::Callbacks::ClassMethods + extend ::ActiveSupport::Callbacks::ClassMethods extend ::ActionMailer::DeliveryMethods::ClassMethods extend ::ActiveSupport::Rescuable::ClassMethods extend ::ActionMailer::Rescuable::ClassMethods extend ::ActionMailer::Parameterized::ClassMethods extend ::ActionMailer::Previews::ClassMethods + extend ::ActionMailer::FormBuilder::ClassMethods extend ::ActionView::ViewPaths::ClassMethods + extend ::AbstractController::Helpers::Resolution extend ::AbstractController::Helpers::ClassMethods - extend ::ActiveSupport::Callbacks::ClassMethods extend ::AbstractController::Callbacks::ClassMethods extend ::AbstractController::Caching::Fragments::ClassMethods extend ::AbstractController::Caching::ClassMethods @@ -518,49 +540,61 @@ class ActionMailer::Base < ::AbstractController::Base # @return [Base] a new instance of Base # - # source://actionmailer//lib/action_mailer/base.rb#632 + # source://actionmailer//lib/action_mailer/base.rb#643 def initialize; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _deliver_callbacks; end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_deliver_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_process_action_callbacks(&block); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end # Allows you to add attachments to an email, like so: @@ -592,106 +626,109 @@ class ActionMailer::Base < ::AbstractController::Base # # or by index # mail.attachments[0] # => Mail::Part (first attachment) # - # source://actionmailer//lib/action_mailer/base.rb#749 + # source://actionmailer//lib/action_mailer/base.rb#760 def attachments; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_asset_host_protocol=(value); end - # source://actionmailer//lib/action_mailer/base.rb#490 + # source://actionmailer//lib/action_mailer/base.rb#502 def default_params; end - # source://actionmailer//lib/action_mailer/base.rb#490 + # source://actionmailer//lib/action_mailer/base.rb#502 def default_params=(_arg0); end - # source://actionmailer//lib/action_mailer/base.rb#490 + # source://actionmailer//lib/action_mailer/base.rb#502 def default_params?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#9 def deliver_later_queue_name; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 - def deliver_later_queue_name=(val); end + # source://actionmailer//lib/action_mailer/queued_delivery.rb#9 + def deliver_later_queue_name=(_arg0); end - # source://actionmailer//lib/action_mailer/base.rb#489 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#9 + def deliver_later_queue_name?; end + + # source://actionmailer//lib/action_mailer/queued_delivery.rb#8 def delivery_job; end - # source://actionmailer//lib/action_mailer/base.rb#489 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#8 def delivery_job=(_arg0); end - # source://actionmailer//lib/action_mailer/base.rb#489 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#8 def delivery_job?; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#19 def delivery_method; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#19 def delivery_method=(_arg0); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#19 def delivery_method?; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#17 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 def delivery_methods; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#17 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 def delivery_methods=(_arg0); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#17 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 def delivery_methods?; end # Returns an email in the format "Name ". # # If the name is a blank string, it returns just the address. # - # source://actionmailer//lib/action_mailer/base.rb#673 + # source://actionmailer//lib/action_mailer/base.rb#684 def email_address_with_name(address, name); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def file_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def file_settings=(_arg0); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def file_settings?; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # Allows you to pass random and unusual headers to the new Mail::Message + # Allows you to pass random and unusual headers to the new +Mail::Message+ # object which will add them to itself. # # headers['X-Special-Domain-Specific-Header'] = "SecretValue" # # You can also pass a hash into headers of header field names and values, - # which will then be set on the Mail::Message object: + # which will then be set on the +Mail::Message+ object: # # headers 'X-Special-Domain-Specific-Header' => "SecretValue", # 'In-Reply-To' => incoming.message_id # - # The resulting Mail::Message will have the following in its header: + # The resulting +Mail::Message+ will have the following in its header: # # X-Special-Domain-Specific-Header: SecretValue # @@ -715,19 +752,19 @@ class ActionMailer::Base < ::AbstractController::Base # +nil+ in order to reset the value otherwise another field will be added # for the same header. # - # source://actionmailer//lib/action_mailer/base.rb#711 + # source://actionmailer//lib/action_mailer/base.rb#722 def headers(args = T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end # The main method that creates the message and renders the email templates. There are @@ -737,7 +774,7 @@ class ActionMailer::Base < ::AbstractController::Base # the most used headers in an email message, these are: # # * +:subject+ - The subject of the message, if this is omitted, Action Mailer will - # ask the Rails I18n class for a translated +:subject+ in the scope of + # ask the \Rails I18n class for a translated +:subject+ in the scope of # [mailer_scope, action_name] or if this is missing, will translate the # humanized version of the +action_name+ # * +:to+ - Who the message is destined for, can be a string of addresses, or an array @@ -774,7 +811,7 @@ class ActionMailer::Base < ::AbstractController::Base # templates in the view paths using by default the mailer name and the # method name that it is being called from, it will then create parts for # each of these templates intelligently, making educated guesses on correct - # content type and sequence, and return a fully prepared Mail::Message + # content type and sequence, and return a fully prepared +Mail::Message+ # ready to call :deliver on to send. # # For example: @@ -819,158 +856,164 @@ class ActionMailer::Base < ::AbstractController::Base # format.html # end # - # source://actionmailer//lib/action_mailer/base.rb#858 + # source://actionmailer//lib/action_mailer/base.rb#869 def mail(headers = T.unsafe(nil), &block); end # Returns the name of the mailer object. # - # source://actionmailer//lib/action_mailer/base.rb#666 + # source://actionmailer//lib/action_mailer/base.rb#677 def mailer_name; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def message; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def message=(_arg0); end - # source://actionmailer//lib/action_mailer/parameterized.rb#91 + # source://actionmailer//lib/action_mailer/parameterized.rb#95 def params; end - # source://actionmailer//lib/action_mailer/parameterized.rb#91 + # source://actionmailer//lib/action_mailer/parameterized.rb#93 def params=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#14 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#16 def perform_deliveries; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#14 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#16 def perform_deliveries=(val); end # source://actionmailer//lib/action_mailer/preview.rb#25 def preview_interceptors; end # source://actionmailer//lib/action_mailer/preview.rb#14 - def preview_path; end + def preview_paths; end - # source://actionmailer//lib/action_mailer/base.rb#638 + # source://actionmailer//lib/action_mailer/base.rb#649 def process(method_name, *args, **_arg2); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#13 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 def raise_delivery_errors; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#13 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 def raise_delivery_errors=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def sendmail_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def sendmail_settings=(_arg0); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def sendmail_settings?; end # source://actionmailer//lib/action_mailer/preview.rb#22 def show_previews; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def smtp_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def smtp_settings=(_arg0); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def smtp_settings?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def test_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def test_settings=(_arg0); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def test_settings?; end private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end - # source://actionmailer//lib/action_mailer/base.rb#1059 + # source://actionmailer//lib/action_mailer/base.rb#1070 def _protected_ivars; end - # source://actionmailer//lib/action_mailer/base.rb#935 + # source://actionmailer//lib/action_mailer/base.rb#946 def apply_defaults(headers); end - # source://actionmailer//lib/action_mailer/base.rb#955 + # source://actionmailer//lib/action_mailer/base.rb#966 def assign_headers_to_message(message, headers); end - # source://actionmailer//lib/action_mailer/base.rb#961 + # source://actionmailer//lib/action_mailer/base.rb#972 def collect_responses(headers, &block); end # @yield [collector] # - # source://actionmailer//lib/action_mailer/base.rb#971 + # source://actionmailer//lib/action_mailer/base.rb#982 def collect_responses_from_block(headers); end - # source://actionmailer//lib/action_mailer/base.rb#985 + # source://actionmailer//lib/action_mailer/base.rb#996 def collect_responses_from_templates(headers); end - # source://actionmailer//lib/action_mailer/base.rb#978 + # source://actionmailer//lib/action_mailer/base.rb#989 def collect_responses_from_text(headers); end - # source://actionmailer//lib/action_mailer/base.rb#945 + # source://actionmailer//lib/action_mailer/base.rb#956 def compute_default(value); end - # source://actionmailer//lib/action_mailer/base.rb#1028 + # source://actionmailer//lib/action_mailer/base.rb#1039 def create_parts_from_responses(m, responses); end - # Translates the +subject+ using Rails I18n class under [mailer_scope, action_name] scope. + # Translates the +subject+ using \Rails I18n class under [mailer_scope, action_name] scope. # If it does not find a translation for the +subject+ under the specified scope it will default to a # humanized version of the action_name. # If the subject has interpolations, you can pass them through the +interpolations+ parameter. # - # source://actionmailer//lib/action_mailer/base.rb#925 + # source://actionmailer//lib/action_mailer/base.rb#936 def default_i18n_subject(interpolations = T.unsafe(nil)); end - # source://actionmailer//lib/action_mailer/base.rb#998 + # source://actionmailer//lib/action_mailer/base.rb#1009 def each_template(paths, name, &block); end - # source://actionmailer//lib/action_mailer/base.rb#1041 + # source://actionmailer//lib/action_mailer/base.rb#1052 def insert_part(container, response, charset); end - # source://actionmailer//lib/action_mailer/base.rb#1055 + # source://actionmailer//lib/action_mailer/base.rb#1066 def instrument_name; end # This and #instrument_name is for caching instrument # - # source://actionmailer//lib/action_mailer/base.rb#1048 + # source://actionmailer//lib/action_mailer/base.rb#1059 def instrument_payload(key); end # Used by #mail to set the content type of the message. @@ -983,83 +1026,98 @@ class ActionMailer::Base < ::AbstractController::Base # attachments, or the message is multipart, then the default content type is # used. # - # source://actionmailer//lib/action_mailer/base.rb#903 + # source://actionmailer//lib/action_mailer/base.rb#914 def set_content_type(m, user_content_type, class_default); end - # source://actionmailer//lib/action_mailer/base.rb#1007 + # source://actionmailer//lib/action_mailer/base.rb#1018 def wrap_inline_attachments(message); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionmailer//lib/action_mailer/form_builder.rb#18 + def _default_form_builder; end + + # source://actionmailer//lib/action_mailer/form_builder.rb#18 + def _default_form_builder=(value); end + + # source://actionmailer//lib/action_mailer/form_builder.rb#18 + def _default_form_builder?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _deliver_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _deliver_callbacks=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#15 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#17 def _helpers; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout=(value); end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout?; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions=(value); end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _process_action_callbacks=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end # Returns the name of the current mailer. This method is also being used as a path for a view lookup. # If this is an anonymous mailer, this method will return +anonymous+ instead. # - # source://actionmailer//lib/action_mailer/base.rb#558 + # source://actionmailer//lib/action_mailer/base.rb#570 def controller_path; end # Sets the defaults through app configuration: @@ -1068,13 +1126,13 @@ class ActionMailer::Base < ::AbstractController::Base # # Aliased by ::default_options= # - # source://actionmailer//lib/action_mailer/base.rb#570 + # source://actionmailer//lib/action_mailer/base.rb#582 def default(value = T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_asset_host_protocol=(value); end # Sets the defaults through app configuration: @@ -1086,131 +1144,134 @@ class ActionMailer::Base < ::AbstractController::Base # # config.action_mailer.default_options = { from: "no-reply@example.org" } # - # source://actionmailer//lib/action_mailer/base.rb#570 + # source://actionmailer//lib/action_mailer/base.rb#582 def default_options=(value = T.unsafe(nil)); end - # source://actionmailer//lib/action_mailer/base.rb#490 + # source://actionmailer//lib/action_mailer/base.rb#502 def default_params; end - # source://actionmailer//lib/action_mailer/base.rb#490 + # source://actionmailer//lib/action_mailer/base.rb#502 def default_params=(value); end - # source://actionmailer//lib/action_mailer/base.rb#490 + # source://actionmailer//lib/action_mailer/base.rb#502 def default_params?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#9 def deliver_later_queue_name; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 - def deliver_later_queue_name=(val); end + # source://actionmailer//lib/action_mailer/queued_delivery.rb#9 + def deliver_later_queue_name=(value); end - # Wraps an email delivery inside of ActiveSupport::Notifications instrumentation. + # source://actionmailer//lib/action_mailer/queued_delivery.rb#9 + def deliver_later_queue_name?; end + + # Wraps an email delivery inside of ActiveSupport::Notifications instrumentation. # - # This method is actually called by the Mail::Message object itself - # through a callback when you call :deliver on the Mail::Message, - # calling +deliver_mail+ directly and passing a Mail::Message will do + # This method is actually called by the +Mail::Message+ object itself + # through a callback when you call :deliver on the +Mail::Message+, + # calling +deliver_mail+ directly and passing a +Mail::Message+ will do # nothing except tell the logger you sent the email. # - # source://actionmailer//lib/action_mailer/base.rb#585 + # source://actionmailer//lib/action_mailer/base.rb#597 def deliver_mail(mail); end - # source://actionmailer//lib/action_mailer/base.rb#489 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#8 def delivery_job; end - # source://actionmailer//lib/action_mailer/base.rb#489 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#8 def delivery_job=(value); end - # source://actionmailer//lib/action_mailer/base.rb#489 + # source://actionmailer//lib/action_mailer/queued_delivery.rb#8 def delivery_job?; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#19 def delivery_method; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#19 def delivery_method=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#19 def delivery_method?; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#17 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 def delivery_methods; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#17 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 def delivery_methods=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#17 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#18 def delivery_methods?; end # Returns an email in the format "Name ". # # If the name is a blank string, it returns just the address. # - # source://actionmailer//lib/action_mailer/base.rb#595 + # source://actionmailer//lib/action_mailer/base.rb#607 def email_address_with_name(address, name); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def file_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def file_settings=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def file_settings?; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end # Returns the name of the current mailer. This method is also being used as a path for a view lookup. # If this is an anonymous mailer, this method will return +anonymous+ instead. # - # source://actionmailer//lib/action_mailer/base.rb#558 + # source://actionmailer//lib/action_mailer/base.rb#570 def mailer_name; end # Allows to set the name of current mailer. # - # source://actionmailer//lib/action_mailer/base.rb#562 + # source://actionmailer//lib/action_mailer/base.rb#574 def mailer_name=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#14 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#16 def perform_deliveries; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#14 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#16 def perform_deliveries=(val); end # source://actionmailer//lib/action_mailer/preview.rb#25 @@ -1220,63 +1281,69 @@ class ActionMailer::Base < ::AbstractController::Base def preview_interceptors=(val); end # source://actionmailer//lib/action_mailer/preview.rb#14 - def preview_path; end + def preview_paths; end # source://actionmailer//lib/action_mailer/preview.rb#14 - def preview_path=(val); end + def preview_paths=(val); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#13 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 def raise_delivery_errors; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#13 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#15 def raise_delivery_errors=(val); end + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + # Register an Interceptor which will be called before mail is sent. # Either a class, string, or symbol can be passed in as the Interceptor. # If a string or symbol is passed in it will be camelized and constantized. # - # source://actionmailer//lib/action_mailer/base.rb#535 + # source://actionmailer//lib/action_mailer/base.rb#547 def register_interceptor(interceptor); end # Register one or more Interceptors which will be called before mail is sent. # - # source://actionmailer//lib/action_mailer/base.rb#509 + # source://actionmailer//lib/action_mailer/base.rb#521 def register_interceptors(*interceptors); end # Register an Observer which will be notified when mail is delivered. # Either a class, string, or symbol can be passed in as the Observer. # If a string or symbol is passed in it will be camelized and constantized. # - # source://actionmailer//lib/action_mailer/base.rb#521 + # source://actionmailer//lib/action_mailer/base.rb#533 def register_observer(observer); end # Register one or more Observers which will be notified when mail is delivered. # - # source://actionmailer//lib/action_mailer/base.rb#499 + # source://actionmailer//lib/action_mailer/base.rb#511 def register_observers(*observers); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def sendmail_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def sendmail_settings=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def sendmail_settings?; end # source://actionmailer//lib/action_mailer/preview.rb#22 @@ -1285,75 +1352,75 @@ class ActionMailer::Base < ::AbstractController::Base # source://actionmailer//lib/action_mailer/preview.rb#22 def show_previews=(val); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def smtp_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def smtp_settings=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def smtp_settings?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end # Emails do not support relative path links. # # @return [Boolean] # - # source://actionmailer//lib/action_mailer/base.rb#931 + # source://actionmailer//lib/action_mailer/base.rb#942 def supports_path?; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def test_settings; end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def test_settings=(value); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#52 def test_settings?; end # Unregister a previously registered Interceptor. # Either a class, string, or symbol can be passed in as the Interceptor. # If a string or symbol is passed in it will be camelized and constantized. # - # source://actionmailer//lib/action_mailer/base.rb#542 + # source://actionmailer//lib/action_mailer/base.rb#554 def unregister_interceptor(interceptor); end # Unregister one or more previously registered Interceptors. # - # source://actionmailer//lib/action_mailer/base.rb#514 + # source://actionmailer//lib/action_mailer/base.rb#526 def unregister_interceptors(*interceptors); end # Unregister a previously registered Observer. # Either a class, string, or symbol can be passed in as the Observer. # If a string or symbol is passed in it will be camelized and constantized. # - # source://actionmailer//lib/action_mailer/base.rb#528 + # source://actionmailer//lib/action_mailer/base.rb#540 def unregister_observer(observer); end # Unregister one or more previously registered Observers. # - # source://actionmailer//lib/action_mailer/base.rb#504 + # source://actionmailer//lib/action_mailer/base.rb#516 def unregister_observers(*observers); end private - # source://actionmailer//lib/action_mailer/base.rb#616 - def method_missing(method_name, *args, **_arg2); end + # source://actionmailer//lib/action_mailer/base.rb#628 + def method_missing(method_name, *_arg1, **_arg2, &_arg3); end - # source://actionmailer//lib/action_mailer/base.rb#546 + # source://actionmailer//lib/action_mailer/base.rb#558 def observer_class_for(value); end # @return [Boolean] # - # source://actionmailer//lib/action_mailer/base.rb#625 + # source://actionmailer//lib/action_mailer/base.rb#636 def respond_to_missing?(method, include_all = T.unsafe(nil)); end - # source://actionmailer//lib/action_mailer/base.rb#603 + # source://actionmailer//lib/action_mailer/base.rb#615 def set_payload_for_mail(payload, mail); end end end @@ -1361,50 +1428,95 @@ end # source://actionmailer//lib/action_mailer/base.rb#0 module ActionMailer::Base::HelperMethods include ::ActionMailer::MailHelper + include ::ActionText::ContentHelper + include ::ActionText::TagHelper - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#31 - def combined_fragment_cache_key(*args, **_arg1, &block); end + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#34 + def combined_fragment_cache_key(*_arg0, **_arg1, &_arg2); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#43 - def view_cache_dependencies(*args, **_arg1, &block); end + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#45 + def view_cache_dependencies(*_arg0, **_arg1, &_arg2); end end -# source://actionmailer//lib/action_mailer/base.rb#757 +# source://actionmailer//lib/action_mailer/base.rb#768 class ActionMailer::Base::LateAttachmentsProxy < ::SimpleDelegator - # source://actionmailer//lib/action_mailer/base.rb#759 + # source://actionmailer//lib/action_mailer/base.rb#770 def []=(_name, _content); end - # source://actionmailer//lib/action_mailer/base.rb#758 + # source://actionmailer//lib/action_mailer/base.rb#769 def inline; end private # @raise [RuntimeError] # - # source://actionmailer//lib/action_mailer/base.rb#762 + # source://actionmailer//lib/action_mailer/base.rb#773 def _raise_error; end end -# source://actionmailer//lib/action_mailer/base.rb#652 +# source://actionmailer//lib/action_mailer/base.rb#663 class ActionMailer::Base::NullMail - # source://actionmailer//lib/action_mailer/base.rb#653 + # source://actionmailer//lib/action_mailer/base.rb#664 def body; end - # source://actionmailer//lib/action_mailer/base.rb#654 + # source://actionmailer//lib/action_mailer/base.rb#665 def header; end - # source://actionmailer//lib/action_mailer/base.rb#660 - def method_missing(*args); end + # source://actionmailer//lib/action_mailer/base.rb#671 + def method_missing(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://actionmailer//lib/action_mailer/base.rb#656 + # source://actionmailer//lib/action_mailer/base.rb#667 def respond_to?(string, include_all = T.unsafe(nil)); end end -# source://actionmailer//lib/action_mailer/base.rb#485 +# source://actionmailer//lib/action_mailer/base.rb#498 ActionMailer::Base::PROTECTED_IVARS = T.let(T.unsafe(nil), Array) +# source://actionmailer//lib/action_mailer/callbacks.rb#4 +module ActionMailer::Callbacks + extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + include ::ActiveSupport::Callbacks + + mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActionMailer::Callbacks::ClassMethods + mixes_in_class_methods ::ActiveSupport::Callbacks::ClassMethods + mixes_in_class_methods ::ActiveSupport::DescendantsTracker + + module GeneratedClassMethods + def __callbacks; end + def __callbacks=(value); end + def __callbacks?; end + end + + module GeneratedInstanceMethods + def __callbacks; end + def __callbacks?; end + end +end + +# source://actionmailer//lib/action_mailer/callbacks.rb#12 +module ActionMailer::Callbacks::ClassMethods + # Defines a callback that will get called right after the + # message's delivery method is finished. + # + # source://actionmailer//lib/action_mailer/callbacks.rb#21 + def after_deliver(*filters, &blk); end + + # Defines a callback that will get called around the message's deliver method. + # + # source://actionmailer//lib/action_mailer/callbacks.rb#26 + def around_deliver(*filters, &blk); end + + # Defines a callback that will get called right before the + # message is sent to the delivery method. + # + # source://actionmailer//lib/action_mailer/callbacks.rb#15 + def before_deliver(*filters, &blk); end +end + # source://actionmailer//lib/action_mailer/collector.rb#8 class ActionMailer::Collector include ::AbstractController::Collector @@ -1433,10 +1545,12 @@ class ActionMailer::Collector def responses; end end +# = Action Mailer \DeliveryMethods +# # This module handles everything related to mail delivery, from registering # new delivery methods to configuring the mail object to be sent. # -# source://actionmailer//lib/action_mailer/delivery_methods.rb#8 +# source://actionmailer//lib/action_mailer/delivery_methods.rb#10 module ActionMailer::DeliveryMethods extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -1444,7 +1558,7 @@ module ActionMailer::DeliveryMethods mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActionMailer::DeliveryMethods::ClassMethods - # source://actionmailer//lib/action_mailer/delivery_methods.rb#78 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#79 def wrap_delivery_behavior!(*args); end module GeneratedClassMethods @@ -1492,28 +1606,75 @@ end # Helpers for creating and wrapping delivery behavior, used by DeliveryMethods. # -# source://actionmailer//lib/action_mailer/delivery_methods.rb#40 +# source://actionmailer//lib/action_mailer/delivery_methods.rb#41 module ActionMailer::DeliveryMethods::ClassMethods # Adds a new delivery method through the given class using the given # symbol as alias and the default options supplied. # # add_delivery_method :sendmail, Mail::Sendmail, # location: '/usr/sbin/sendmail', - # arguments: '-i' + # arguments: %w[ -i ] # - # source://actionmailer//lib/action_mailer/delivery_methods.rb#50 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#51 def add_delivery_method(symbol, klass, default_options = T.unsafe(nil)); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#42 - def deliveries(*_arg0, **_arg1, &_arg2); end + # source://actionmailer//lib/action_mailer/delivery_methods.rb#43 + def deliveries(&_arg0); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#42 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#43 def deliveries=(arg); end - # source://actionmailer//lib/action_mailer/delivery_methods.rb#56 + # source://actionmailer//lib/action_mailer/delivery_methods.rb#57 def wrap_delivery_behavior(mail, method = T.unsafe(nil), options = T.unsafe(nil)); end end +# = Action Mailer Form Builder +# +# Override the default form builder for all views rendered by this +# mailer and any of its descendants. Accepts a subclass of +# ActionView::Helpers::FormBuilder. +# +# While emails typically will not include forms, this can be used +# by views that are shared between controllers and mailers. +# +# For more information, see +ActionController::FormBuilder+. +# +# source://actionmailer//lib/action_mailer/form_builder.rb#14 +module ActionMailer::FormBuilder + extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActionMailer::FormBuilder::ClassMethods + + # Default form builder for the mailer + # + # source://actionmailer//lib/action_mailer/form_builder.rb#33 + def default_form_builder; end + + module GeneratedClassMethods + def _default_form_builder; end + def _default_form_builder=(value); end + def _default_form_builder?; end + end + + module GeneratedInstanceMethods; end +end + +# source://actionmailer//lib/action_mailer/form_builder.rb#21 +module ActionMailer::FormBuilder::ClassMethods + # Set the form builder to be used as the default for all forms + # in the views rendered by this mailer and its subclasses. + # + # ==== Parameters + # * builder - Default form builder, an instance of ActionView::Helpers::FormBuilder + # + # source://actionmailer//lib/action_mailer/form_builder.rb#27 + def default_form_builder(builder); end +end + +# = Action Mailer \InlinePreviewInterceptor +# # Implements a mailer preview interceptor that converts image tag src attributes # that use inline cid: style URLs to data: style URLs so that they are visible # when previewing an HTML email in a web browser. @@ -1523,104 +1684,115 @@ end # # ActionMailer::Base.preview_interceptors.delete(ActionMailer::InlinePreviewInterceptor) # -# source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#15 +# source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#17 class ActionMailer::InlinePreviewInterceptor include ::Base64 # @return [InlinePreviewInterceptor] a new instance of InlinePreviewInterceptor # - # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#24 + # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#26 def initialize(message); end - # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#28 + # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#30 def transform!; end private - # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#49 + # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#51 def data_url(part); end - # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#53 + # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#55 def find_part(cid); end - # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#45 + # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#47 def html_part; end # Returns the value of attribute message. # - # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#43 + # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#45 def message; end class << self - # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#20 + # source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#22 def previewing_email(message); end end end -# source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#16 +# source://actionmailer//lib/action_mailer/inline_preview_interceptor.rb#18 ActionMailer::InlinePreviewInterceptor::PATTERN = T.let(T.unsafe(nil), Regexp) +# = Action Mailer \LogSubscriber +# # Implements the ActiveSupport::LogSubscriber for logging notifications when # email is delivered or received. # -# source://actionmailer//lib/action_mailer/log_subscriber.rb#8 +# source://actionmailer//lib/action_mailer/log_subscriber.rb#10 class ActionMailer::LogSubscriber < ::ActiveSupport::LogSubscriber # An email was delivered. # - # source://actionmailer//lib/action_mailer/log_subscriber.rb#10 + # source://actionmailer//lib/action_mailer/log_subscriber.rb#12 def deliver(event); end # Use the logger configured for ActionMailer::Base. # - # source://actionmailer//lib/action_mailer/log_subscriber.rb#33 + # source://actionmailer//lib/action_mailer/log_subscriber.rb#38 def logger; end # An email was generated. # - # source://actionmailer//lib/action_mailer/log_subscriber.rb#24 + # source://actionmailer//lib/action_mailer/log_subscriber.rb#28 def process(event); end + + class << self + # source://activesupport/7.2.0/lib/active_support/log_subscriber.rb#84 + def log_levels; end + end end -# The ActionMailer::MailDeliveryJob class is used when you +# = Action Mailer \MailDeliveryJob +# +# The +ActionMailer::MailDeliveryJob+ class is used when you # want to send emails outside of the request-response cycle. It supports # sending either parameterized or normal mail. # # Exceptions are rescued and handled by the mailer class. # -# source://actionmailer//lib/action_mailer/mail_delivery_job.rb#11 +# source://actionmailer//lib/action_mailer/mail_delivery_job.rb#13 class ActionMailer::MailDeliveryJob < ::ActiveJob::Base - # source://actionmailer//lib/action_mailer/mail_delivery_job.rb#16 + # source://actionmailer//lib/action_mailer/mail_delivery_job.rb#21 def perform(mailer, mail_method, delivery_method, args:, kwargs: T.unsafe(nil), params: T.unsafe(nil)); end private - # source://actionmailer//lib/action_mailer/mail_delivery_job.rb#35 + # source://actionmailer//lib/action_mailer/mail_delivery_job.rb#40 def handle_exception_with_mailer_class(exception); end # "Deserialize" the mailer class name by hand in case another argument # (like a Global ID reference) raised DeserializationError. # - # source://actionmailer//lib/action_mailer/mail_delivery_job.rb#29 + # source://actionmailer//lib/action_mailer/mail_delivery_job.rb#34 def mailer_class; end class << self - # source://activejob/7.0.5/lib/active_job/queue_name.rb#56 + # source://activejob/7.2.0/lib/active_job/queue_name.rb#55 def queue_name; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end end end +# = Action Mailer \MailHelper +# # Provides helper methods for ActionMailer::Base that can be used for easily # formatting messages, accessing mailer or message instances, and the # attachments list. # -# source://actionmailer//lib/action_mailer/mail_helper.rb#7 +# source://actionmailer//lib/action_mailer/mail_helper.rb#9 module ActionMailer::MailHelper # Access the message attachments list. # - # source://actionmailer//lib/action_mailer/mail_helper.rb#43 + # source://actionmailer//lib/action_mailer/mail_helper.rb#45 def attachments; end # Take the text and format it, indented two spaces for each line, and @@ -1636,7 +1808,7 @@ module ActionMailer::MailHelper # block_format text # # => " This is the paragraph.\n\n * item1\n * item2\n" # - # source://actionmailer//lib/action_mailer/mail_helper.rb#20 + # source://actionmailer//lib/action_mailer/mail_helper.rb#22 def block_format(text); end # Returns +text+ wrapped at +len+ columns and indented +indent+ spaces. @@ -1648,25 +1820,27 @@ module ActionMailer::MailHelper # format_paragraph(my_text, 25, 4) # # => " Here is a sample text with\n more than 40 characters" # - # source://actionmailer//lib/action_mailer/mail_helper.rb#55 + # source://actionmailer//lib/action_mailer/mail_helper.rb#57 def format_paragraph(text, len = T.unsafe(nil), indent = T.unsafe(nil)); end # Access the mailer instance. # - # source://actionmailer//lib/action_mailer/mail_helper.rb#33 + # source://actionmailer//lib/action_mailer/mail_helper.rb#35 def mailer; end # Access the message instance. # - # source://actionmailer//lib/action_mailer/mail_helper.rb#38 + # source://actionmailer//lib/action_mailer/mail_helper.rb#40 def message; end end -# The ActionMailer::MessageDelivery class is used by +# = Action Mailer \MessageDelivery +# +# The +ActionMailer::MessageDelivery+ class is used by # ActionMailer::Base when creating a new mailer. # MessageDelivery is a wrapper (+Delegator+ subclass) around a lazy -# created Mail::Message. You can get direct access to the -# Mail::Message, deliver the email or schedule the email to be sent +# created +Mail::Message+. You can get direct access to the +# +Mail::Message+, deliver the email or schedule the email to be sent # through Active Job. # # Notifier.welcome(User.first) # an ActionMailer::MessageDelivery object @@ -1674,21 +1848,21 @@ end # Notifier.welcome(User.first).deliver_later # enqueue email delivery as a job through Active Job # Notifier.welcome(User.first).message # a Mail::Message object # -# source://actionmailer//lib/action_mailer/message_delivery.rb#17 +# source://actionmailer//lib/action_mailer/message_delivery.rb#19 class ActionMailer::MessageDelivery # @return [MessageDelivery] a new instance of MessageDelivery # - # source://actionmailer//lib/action_mailer/message_delivery.rb#18 + # source://actionmailer//lib/action_mailer/message_delivery.rb#20 def initialize(mailer_class, action, *args, **_arg3); end # Method calls are delegated to the Mail::Message that's ready to deliver. # - # source://actionmailer//lib/action_mailer/message_delivery.rb#29 + # source://actionmailer//lib/action_mailer/message_delivery.rb#31 def __getobj__; end # Unused except for delegator internals (dup, marshalling). # - # source://actionmailer//lib/action_mailer/message_delivery.rb#34 + # source://actionmailer//lib/action_mailer/message_delivery.rb#36 def __setobj__(mail_message); end # Enqueues the email to be delivered through Active Job. When the @@ -1706,15 +1880,16 @@ class ActionMailer::MessageDelivery # * :queue - Enqueue the email on the specified queue. # * :priority - Enqueues the email with the specified priority # - # By default, the email will be enqueued using ActionMailer::MailDeliveryJob. Each - # ActionMailer::Base class can specify the job to use by setting the class variable - # +delivery_job+. + # By default, the email will be enqueued using ActionMailer::MailDeliveryJob on + # the default queue. Mailer classes can customize the queue name used for the default + # job by assigning a +deliver_later_queue_name+ class variable, or provide a custom job + # by assigning a +delivery_job+. When a custom job is used, it controls the queue name. # # class AccountRegistrationMailer < ApplicationMailer # self.delivery_job = RegistrationDeliveryJob # end # - # source://actionmailer//lib/action_mailer/message_delivery.rb#98 + # source://actionmailer//lib/action_mailer/message_delivery.rb#102 def deliver_later(options = T.unsafe(nil)); end # Enqueues the email to be delivered through Active Job. When the @@ -1734,22 +1909,23 @@ class ActionMailer::MessageDelivery # * :queue - Enqueue the email on the specified queue # * :priority - Enqueues the email with the specified priority # - # By default, the email will be enqueued using ActionMailer::MailDeliveryJob. Each - # ActionMailer::Base class can specify the job to use by setting the class variable - # +delivery_job+. + # By default, the email will be enqueued using ActionMailer::MailDeliveryJob on + # the default queue. Mailer classes can customize the queue name used for the default + # job by assigning a +deliver_later_queue_name+ class variable, or provide a custom job + # by assigning a +delivery_job+. When a custom job is used, it controls the queue name. # # class AccountRegistrationMailer < ApplicationMailer # self.delivery_job = RegistrationDeliveryJob # end # - # source://actionmailer//lib/action_mailer/message_delivery.rb#72 + # source://actionmailer//lib/action_mailer/message_delivery.rb#75 def deliver_later!(options = T.unsafe(nil)); end # Delivers an email: # # Notifier.welcome(User.first).deliver_now # - # source://actionmailer//lib/action_mailer/message_delivery.rb#117 + # source://actionmailer//lib/action_mailer/message_delivery.rb#123 def deliver_now; end # Delivers an email without checking +perform_deliveries+ and +raise_delivery_errors+, @@ -1757,30 +1933,30 @@ class ActionMailer::MessageDelivery # # Notifier.welcome(User.first).deliver_now! # - # source://actionmailer//lib/action_mailer/message_delivery.rb#107 + # source://actionmailer//lib/action_mailer/message_delivery.rb#111 def deliver_now!; end # Returns the resulting Mail::Message # - # source://actionmailer//lib/action_mailer/message_delivery.rb#39 + # source://actionmailer//lib/action_mailer/message_delivery.rb#41 def message; end # Was the delegate loaded, causing the mailer action to be processed? # # @return [Boolean] # - # source://actionmailer//lib/action_mailer/message_delivery.rb#44 + # source://actionmailer//lib/action_mailer/message_delivery.rb#46 def processed?; end private - # source://actionmailer//lib/action_mailer/message_delivery.rb#132 + # source://actionmailer//lib/action_mailer/message_delivery.rb#140 def enqueue_delivery(delivery_method, options = T.unsafe(nil)); end # Returns the processed Mailer instance. We keep this instance - # on hand so we can delegate exception handling to it. + # on hand so we can run callbacks and delegate exception handling to it. # - # source://actionmailer//lib/action_mailer/message_delivery.rb#126 + # source://actionmailer//lib/action_mailer/message_delivery.rb#134 def processed_mailer; end end @@ -1792,6 +1968,8 @@ class ActionMailer::NonInferrableMailerError < ::StandardError def initialize(name); end end +# = Action Mailer \Parameterized +# # Provides the option to parameterize mailers in order to share instance variable # setup, processing, and common headers. # @@ -1876,14 +2054,14 @@ end # # InvitationsMailer.with(inviter: person_a, invitee: person_b).account_invitation.deliver_later # -# source://actionmailer//lib/action_mailer/parameterized.rb#87 +# source://actionmailer//lib/action_mailer/parameterized.rb#89 module ActionMailer::Parameterized extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionMailer::Parameterized::ClassMethods end -# source://actionmailer//lib/action_mailer/parameterized.rb#94 +# source://actionmailer//lib/action_mailer/parameterized.rb#100 module ActionMailer::Parameterized::ClassMethods # Provide the parameters to the mailer in order to use them in the instance methods and callbacks. # @@ -1891,41 +2069,41 @@ module ActionMailer::Parameterized::ClassMethods # # See Parameterized documentation for full example. # - # source://actionmailer//lib/action_mailer/parameterized.rb#100 + # source://actionmailer//lib/action_mailer/parameterized.rb#106 def with(params); end end -# source://actionmailer//lib/action_mailer/parameterized.rb#105 +# source://actionmailer//lib/action_mailer/parameterized.rb#111 class ActionMailer::Parameterized::Mailer # @return [Mailer] a new instance of Mailer # - # source://actionmailer//lib/action_mailer/parameterized.rb#106 + # source://actionmailer//lib/action_mailer/parameterized.rb#112 def initialize(mailer, params); end private - # source://actionmailer//lib/action_mailer/parameterized.rb#111 - def method_missing(method_name, *args, **_arg2); end + # source://actionmailer//lib/action_mailer/parameterized.rb#117 + def method_missing(method_name, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://actionmailer//lib/action_mailer/parameterized.rb#120 + # source://actionmailer//lib/action_mailer/parameterized.rb#125 def respond_to_missing?(method, include_all = T.unsafe(nil)); end end -# source://actionmailer//lib/action_mailer/parameterized.rb#125 +# source://actionmailer//lib/action_mailer/parameterized.rb#130 class ActionMailer::Parameterized::MessageDelivery < ::ActionMailer::MessageDelivery # @return [MessageDelivery] a new instance of MessageDelivery # - # source://actionmailer//lib/action_mailer/parameterized.rb#126 - def initialize(mailer_class, action, params, *args, **_arg4); end + # source://actionmailer//lib/action_mailer/parameterized.rb#131 + def initialize(mailer_class, action, params, *_arg3, **_arg4, &_arg5); end private - # source://actionmailer//lib/action_mailer/parameterized.rb#140 + # source://actionmailer//lib/action_mailer/parameterized.rb#144 def enqueue_delivery(delivery_method, options = T.unsafe(nil)); end - # source://actionmailer//lib/action_mailer/parameterized.rb#133 + # source://actionmailer//lib/action_mailer/parameterized.rb#137 def processed_mailer; end end @@ -1994,7 +2172,7 @@ class ActionMailer::Preview def load_previews; end # source://actionmailer//lib/action_mailer/preview.rb#127 - def preview_path; end + def preview_paths; end # source://actionmailer//lib/action_mailer/preview.rb#131 def show_previews; end @@ -2040,13 +2218,43 @@ module ActionMailer::Previews::ClassMethods def interceptor_class_for(interceptor); end end +# source://actionmailer//lib/action_mailer/queued_delivery.rb#4 +module ActionMailer::QueuedDelivery + extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + module GeneratedClassMethods + def deliver_later_queue_name; end + def deliver_later_queue_name=(value); end + def deliver_later_queue_name?; end + def delivery_job; end + def delivery_job=(value); end + def delivery_job?; end + end + + module GeneratedInstanceMethods + def deliver_later_queue_name; end + def deliver_later_queue_name=(value); end + def deliver_later_queue_name?; end + def delivery_job; end + def delivery_job=(value); end + def delivery_job?; end + end +end + # source://actionmailer//lib/action_mailer/railtie.rb#9 class ActionMailer::Railtie < ::Rails::Railtie; end -# Provides +rescue_from+ for mailers. Wraps mailer action processing, -# mail job processing, and mail delivery. +# = Action Mailer \Rescuable +# +# Provides +# {rescue_from}[rdoc-ref:ActiveSupport::Rescuable::ClassMethods#rescue_from] +# for mailers. Wraps mailer action processing, mail job processing, and mail +# delivery to handle configured errors. # -# source://actionmailer//lib/action_mailer/rescuable.rb#6 +# source://actionmailer//lib/action_mailer/rescuable.rb#10 module ActionMailer::Rescuable extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -2056,12 +2264,12 @@ module ActionMailer::Rescuable mixes_in_class_methods ::ActiveSupport::Rescuable::ClassMethods mixes_in_class_methods ::ActionMailer::Rescuable::ClassMethods - # source://actionmailer//lib/action_mailer/rescuable.rb#16 + # source://actionmailer//lib/action_mailer/rescuable.rb#20 def handle_exceptions; end private - # source://actionmailer//lib/action_mailer/rescuable.rb#23 + # source://actionmailer//lib/action_mailer/rescuable.rb#27 def process(*_arg0, **_arg1, &_arg2); end module GeneratedClassMethods @@ -2079,7 +2287,7 @@ end # source://actionmailer//lib/action_mailer/rescuable.rb#0 module ActionMailer::Rescuable::ClassMethods - # source://actionmailer//lib/action_mailer/rescuable.rb#11 + # source://actionmailer//lib/action_mailer/rescuable.rb#15 def handle_exception(exception); end end @@ -2088,7 +2296,6 @@ class ActionMailer::TestCase < ::ActiveSupport::TestCase include ::ActiveSupport::Testing::ConstantLookup include ::ActiveJob::TestHelper include ::ActionMailer::TestHelper - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions include ::ActionMailer::TestCase::Behavior @@ -2105,7 +2312,7 @@ class ActionMailer::TestCase < ::ActiveSupport::TestCase def _mailer_class?; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end # source://actionmailer//lib/action_mailer/test_case.rb#41 @@ -2124,7 +2331,6 @@ module ActionMailer::TestCase::Behavior include ::ActiveSupport::Testing::Assertions include ::ActiveJob::TestHelper include ::ActionMailer::TestHelper - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions extend ::ActiveSupport::Concern @@ -2135,30 +2341,36 @@ module ActionMailer::TestCase::Behavior mixes_in_class_methods ::ActiveSupport::Testing::ConstantLookup::ClassMethods mixes_in_class_methods ::ActionMailer::TestCase::Behavior::ClassMethods + # Reads the fixture file for the given mailer. + # + # This is useful when testing mailers by being able to write the body of + # an email inside a fixture. See the testing guide for a concrete example: + # https://guides.rubyonrails.org/testing.html#revenge-of-the-fixtures + # + # source://actionmailer//lib/action_mailer/test_case.rb#82 + def read_fixture(action); end + private - # source://actionmailer//lib/action_mailer/test_case.rb#106 + # source://actionmailer//lib/action_mailer/test_case.rb#115 def charset; end - # source://actionmailer//lib/action_mailer/test_case.rb#110 + # source://actionmailer//lib/action_mailer/test_case.rb#119 def encode(subject); end - # source://actionmailer//lib/action_mailer/test_case.rb#78 + # source://actionmailer//lib/action_mailer/test_case.rb#87 def initialize_test_deliveries; end - # source://actionmailer//lib/action_mailer/test_case.rb#114 - def read_fixture(action); end - - # source://actionmailer//lib/action_mailer/test_case.rb#95 + # source://actionmailer//lib/action_mailer/test_case.rb#104 def restore_delivery_method; end - # source://actionmailer//lib/action_mailer/test_case.rb#85 + # source://actionmailer//lib/action_mailer/test_case.rb#94 def restore_test_deliveries; end - # source://actionmailer//lib/action_mailer/test_case.rb#90 + # source://actionmailer//lib/action_mailer/test_case.rb#99 def set_delivery_method(method); end - # source://actionmailer//lib/action_mailer/test_case.rb#100 + # source://actionmailer//lib/action_mailer/test_case.rb#109 def set_expected_mail; end module GeneratedClassMethods @@ -2201,7 +2413,7 @@ end # Provides helper methods for testing Action Mailer, including #assert_emails # and #assert_no_emails. # -# source://actionmailer//lib/action_mailer/test_helper.rb#8 +# source://actionmailer//lib/action_mailer/test_helper.rb#9 module ActionMailer::TestHelper include ::ActiveSupport::Testing::Assertions include ::ActiveJob::TestHelper @@ -2230,22 +2442,54 @@ module ActionMailer::TestHelper # end # end # - # source://actionmailer//lib/action_mailer/test_helper.rb#34 + # source://actionmailer//lib/action_mailer/test_helper.rb#35 def assert_emails(number, &block); end # Asserts that a specific email has been enqueued, optionally - # matching arguments. + # matching arguments and/or params. # # def test_email # ContactMailer.welcome.deliver_later # assert_enqueued_email_with ContactMailer, :welcome # end # + # def test_email_with_parameters + # ContactMailer.with(greeting: "Hello").welcome.deliver_later + # assert_enqueued_email_with ContactMailer, :welcome, args: { greeting: "Hello" } + # end + # # def test_email_with_arguments # ContactMailer.welcome("Hello", "Goodbye").deliver_later # assert_enqueued_email_with ContactMailer, :welcome, args: ["Hello", "Goodbye"] # end # + # def test_email_with_named_arguments + # ContactMailer.welcome(greeting: "Hello", farewell: "Goodbye").deliver_later + # assert_enqueued_email_with ContactMailer, :welcome, args: [{ greeting: "Hello", farewell: "Goodbye" }] + # end + # + # def test_email_with_parameters_and_arguments + # ContactMailer.with(greeting: "Hello").welcome("Cheers", "Goodbye").deliver_later + # assert_enqueued_email_with ContactMailer, :welcome, params: { greeting: "Hello" }, args: ["Cheers", "Goodbye"] + # end + # + # def test_email_with_parameters_and_named_arguments + # ContactMailer.with(greeting: "Hello").welcome(farewell: "Goodbye").deliver_later + # assert_enqueued_email_with ContactMailer, :welcome, params: { greeting: "Hello" }, args: [{farewell: "Goodbye"}] + # end + # + # def test_email_with_parameterized_mailer + # ContactMailer.with(greeting: "Hello").welcome.deliver_later + # assert_enqueued_email_with ContactMailer.with(greeting: "Hello"), :welcome + # end + # + # def test_email_with_matchers + # ContactMailer.with(greeting: "Hello").welcome("Cheers", "Goodbye").deliver_later + # assert_enqueued_email_with ContactMailer, :welcome, + # params: ->(params) { /hello/i.match?(params[:greeting]) }, + # args: ->(args) { /cheers/i.match?(args[0]) } + # end + # # If a block is passed, that block should cause the specified email # to be enqueued. # @@ -2264,8 +2508,8 @@ module ActionMailer::TestHelper # end # end # - # source://actionmailer//lib/action_mailer/test_helper.rb#126 - def assert_enqueued_email_with(mailer, method, args: T.unsafe(nil), queue: T.unsafe(nil), &block); end + # source://actionmailer//lib/action_mailer/test_helper.rb#157 + def assert_enqueued_email_with(mailer, method, params: T.unsafe(nil), args: T.unsafe(nil), queue: T.unsafe(nil), &block); end # Asserts that the number of emails enqueued for later delivery matches # the given number. @@ -2292,7 +2536,7 @@ module ActionMailer::TestHelper # end # end # - # source://actionmailer//lib/action_mailer/test_helper.rb#92 + # source://actionmailer//lib/action_mailer/test_helper.rb#91 def assert_enqueued_emails(number, &block); end # Asserts that no emails have been sent. @@ -2315,7 +2559,7 @@ module ActionMailer::TestHelper # # assert_emails 0, &block # - # source://actionmailer//lib/action_mailer/test_helper.rb#64 + # source://actionmailer//lib/action_mailer/test_helper.rb#63 def assert_no_emails(&block); end # Asserts that no emails are enqueued for later delivery. @@ -2334,12 +2578,70 @@ module ActionMailer::TestHelper # end # end # - # source://actionmailer//lib/action_mailer/test_helper.rb#150 + # source://actionmailer//lib/action_mailer/test_helper.rb#191 def assert_no_enqueued_emails(&block); end + # Returns any emails that are sent in the block. + # + # def test_emails + # emails = capture_emails do + # ContactMailer.welcome.deliver_now + # end + # assert_equal "Hi there", emails.first.subject + # + # emails = capture_emails do + # ContactMailer.welcome.deliver_now + # ContactMailer.welcome.deliver_later + # end + # assert_equal "Hi there", emails.first.subject + # end + # + # source://actionmailer//lib/action_mailer/test_helper.rb#249 + def capture_emails(&block); end + + # Delivers all enqueued emails. If a block is given, delivers all of the emails + # that were enqueued throughout the duration of the block. If a block is + # not given, delivers all the enqueued emails up to this point in the test. + # + # def test_deliver_enqueued_emails + # deliver_enqueued_emails do + # ContactMailer.welcome.deliver_later + # end + # + # assert_emails 1 + # end + # + # def test_deliver_enqueued_emails_without_block + # ContactMailer.welcome.deliver_later + # + # deliver_enqueued_emails + # + # assert_emails 1 + # end + # + # If the +:queue+ option is specified, + # then only the emails(s) enqueued to a specific queue will be performed. + # + # def test_deliver_enqueued_emails_with_queue + # deliver_enqueued_emails queue: :external_mailers do + # CustomerMailer.deliver_later_queue_name = :external_mailers + # CustomerMailer.welcome.deliver_later # will be performed + # EmployeeMailer.deliver_later_queue_name = :internal_mailers + # EmployeeMailer.welcome.deliver_later # will not be performed + # end + # + # assert_emails 1 + # end + # + # If the +:at+ option is specified, then only delivers emails enqueued to deliver + # immediately or before the given time. + # + # source://actionmailer//lib/action_mailer/test_helper.rb#231 + def deliver_enqueued_emails(queue: T.unsafe(nil), at: T.unsafe(nil), &block); end + private - # source://actionmailer//lib/action_mailer/test_helper.rb#155 + # source://actionmailer//lib/action_mailer/test_helper.rb#258 def delivery_job_filter(job); end end diff --git a/sorbet/rbi/gems/actionpack@7.0.5.rbi b/sorbet/rbi/gems/actionpack@7.2.0.rbi similarity index 55% rename from sorbet/rbi/gems/actionpack@7.0.5.rbi rename to sorbet/rbi/gems/actionpack@7.2.0.rbi index e553721c6..6f290e53e 100644 --- a/sorbet/rbi/gems/actionpack@7.0.5.rbi +++ b/sorbet/rbi/gems/actionpack@7.2.0.rbi @@ -4,50 +4,58 @@ # This is an autogenerated file for types exported from the `actionpack` gem. # Please instead update this file by running `bin/tapioca gem actionpack`. -# source://actionpack//lib/abstract_controller.rb#8 + +# :markup: markdown +# +# source://actionpack//lib/abstract_controller/deprecator.rb#5 module AbstractController extend ::ActiveSupport::Autoload class << self - # source://actionpack//lib/abstract_controller.rb#24 + # source://actionpack//lib/abstract_controller/deprecator.rb#6 + def deprecator; end + + # source://actionpack//lib/abstract_controller.rb#27 def eager_load!; end end end # Raised when a non-existing controller action is triggered. # -# source://actionpack//lib/abstract_controller/base.rb#11 +# source://actionpack//lib/abstract_controller/base.rb#13 class AbstractController::ActionNotFound < ::StandardError include ::DidYouMean::Correctable # @return [ActionNotFound] a new instance of ActionNotFound # - # source://actionpack//lib/abstract_controller/base.rb#14 + # source://actionpack//lib/abstract_controller/base.rb#16 def initialize(message = T.unsafe(nil), controller = T.unsafe(nil), action = T.unsafe(nil)); end - # source://actionpack//lib/abstract_controller/base.rb#12 + # source://actionpack//lib/abstract_controller/base.rb#14 def action; end - # source://actionpack//lib/abstract_controller/base.rb#12 + # source://actionpack//lib/abstract_controller/base.rb#14 def controller; end - # source://actionpack//lib/abstract_controller/base.rb#23 + # source://actionpack//lib/abstract_controller/base.rb#25 def corrections; end end -# source://actionpack//lib/abstract_controller/asset_paths.rb#4 +# source://actionpack//lib/abstract_controller/asset_paths.rb#6 module AbstractController::AssetPaths extend ::ActiveSupport::Concern end -# AbstractController::Base is a low-level API. Nobody should be -# using it directly, and subclasses (like ActionController::Base) are -# expected to provide their own +render+ method, since rendering means -# different things depending on the context. +# # Abstract Controller Base +# +# AbstractController::Base is a low-level API. Nobody should be using it +# directly, and subclasses (like ActionController::Base) are expected to provide +# their own `render` method, since rendering means different things depending on +# the context. # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://actionpack//lib/abstract_controller/base.rb#33 +# source://actionpack//lib/abstract_controller/base.rb#37 class AbstractController::Base include ::ActiveSupport::Configurable extend ::ActiveSupport::Configurable::ClassMethods @@ -55,248 +63,248 @@ class AbstractController::Base # Delegates to the class's ::action_methods. # - # source://actionpack//lib/abstract_controller/base.rb#161 + # source://actionpack//lib/abstract_controller/base.rb#172 def action_methods; end # Returns the name of the action this controller is processing. # - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def action_name; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def action_name=(_arg0); end - # Returns true if a method for the action is available and - # can be dispatched, false otherwise. + # Returns true if a method for the action is available and can be dispatched, + # false otherwise. # - # Notice that action_methods.include?("foo") may return - # false and available_action?("foo") returns true because - # this method considers actions that are also available - # through other means, for example, implicit render ones. + # Notice that `action_methods.include?("foo")` may return false and + # `available_action?("foo")` returns true because this method considers actions + # that are also available through other means, for example, implicit render + # ones. # - # ==== Parameters - # * action_name - The name of an action to be tested + # #### Parameters + # * `action_name` - The name of an action to be tested # # @return [Boolean] # - # source://actionpack//lib/abstract_controller/base.rb#175 + # source://actionpack//lib/abstract_controller/base.rb#187 def available_action?(action_name); end # Delegates to the class's ::controller_path. # - # source://actionpack//lib/abstract_controller/base.rb#156 + # source://actionpack//lib/abstract_controller/base.rb#167 def controller_path; end # Returns the formats that can be processed by the controller. # - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def formats; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def formats=(_arg0); end - # source://actionpack//lib/abstract_controller/base.rb#194 + # source://actionpack//lib/abstract_controller/base.rb#204 def inspect; end - # Tests if a response body is set. Used to determine if the - # +process_action+ callback needs to be terminated in - # AbstractController::Callbacks. + # Tests if a response body is set. Used to determine if the `process_action` + # callback needs to be terminated in AbstractController::Callbacks. # # @return [Boolean] # - # source://actionpack//lib/abstract_controller/base.rb#182 + # source://actionpack//lib/abstract_controller/base.rb#193 def performed?; end - # Calls the action going through the entire action dispatch stack. + # Calls the action going through the entire Action Dispatch stack. # - # The actual method that is called is determined by calling - # #method_for_action. If no method can handle the action, then an - # AbstractController::ActionNotFound error is raised. + # The actual method that is called is determined by calling #method_for_action. + # If no method can handle the action, then an AbstractController::ActionNotFound + # error is raised. # - # ==== Returns - # * self + # #### Returns + # * `self` # - # source://actionpack//lib/abstract_controller/base.rb#142 - def process(action, *args, **_arg2); end + # source://actionpack//lib/abstract_controller/base.rb#154 + def process(action, *_arg1, **_arg2, &_arg3); end # Returns the body of the HTTP response sent by the controller. # - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def response_body; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def response_body=(_arg0); end - # Actually call the method associated with the action. Override - # this method if you wish to change how action methods are called, - # not to add additional behavior around it. For example, you would - # override #send_action if you want to inject arguments into the - # method. + # Actually call the method associated with the action. Override this method if + # you wish to change how action methods are called, not to add additional + # behavior around it. For example, you would override #send_action if you want + # to inject arguments into the method. def send_action(*_arg0); end private - # Takes an action name and returns the name of the method that will - # handle the action. + # Takes an action name and returns the name of the method that will handle the + # action. # # It checks if the action name is valid and returns false otherwise. # # See method_for_action for more information. # - # ==== Parameters - # * action_name - An action name to find a method name for + # #### Parameters + # * `action_name` - An action name to find a method name for # - # ==== Returns - # * string - The name of the method that handles the action - # * false - No valid method name could be found. - # Raise +AbstractController::ActionNotFound+. # - # source://actionpack//lib/abstract_controller/base.rb#246 + # #### Returns + # * `string` - The name of the method that handles the action + # * false - No valid method name could be found. + # + # Raise `AbstractController::ActionNotFound`. + # + # source://actionpack//lib/abstract_controller/base.rb#258 def _find_action_name(action_name); end - # If the action name was not found, but a method called "action_missing" - # was found, #method_for_action will return "_handle_action_missing". - # This method calls #action_missing with the current action name. + # If the action name was not found, but a method called "action_missing" was + # found, #method_for_action will return "_handle_action_missing". This method + # calls #action_missing with the current action name. # - # source://actionpack//lib/abstract_controller/base.rb#228 + # source://actionpack//lib/abstract_controller/base.rb#238 def _handle_action_missing(*args); end # Checks if the action name is valid and returns false otherwise. # # @return [Boolean] # - # source://actionpack//lib/abstract_controller/base.rb#282 + # source://actionpack//lib/abstract_controller/base.rb#295 def _valid_action_name?(action_name); end - # Returns true if the name can be considered an action because - # it has a method defined in the controller. + # Returns true if the name can be considered an action because it has a method + # defined in the controller. # - # ==== Parameters - # * name - The name of an action to be tested + # #### Parameters + # * `name` - The name of an action to be tested # # @return [Boolean] # - # source://actionpack//lib/abstract_controller/base.rb#204 + # source://actionpack//lib/abstract_controller/base.rb#215 def action_method?(name); end - # Takes an action name and returns the name of the method that will - # handle the action. In normal cases, this method returns the same - # name as it receives. By default, if #method_for_action receives - # a name that is not an action, it will look for an #action_missing - # method and return "_handle_action_missing" if one is found. + # Takes an action name and returns the name of the method that will handle the + # action. In normal cases, this method returns the same name as it receives. By + # default, if #method_for_action receives a name that is not an action, it will + # look for an #action_missing method and return "_handle_action_missing" if one + # is found. + # + # Subclasses may override this method to add additional conditions that should + # be considered an action. For instance, an HTTP controller with a template + # matching the action name is considered to exist. # - # Subclasses may override this method to add additional conditions - # that should be considered an action. For instance, an HTTP controller - # with a template matching the action name is considered to exist. + # If you override this method to handle additional cases, you may also provide a + # method (like `_handle_method_missing`) to handle the case. # - # If you override this method to handle additional cases, you may - # also provide a method (like +_handle_method_missing+) to handle - # the case. + # If none of these conditions are true, and `method_for_action` returns `nil`, + # an `AbstractController::ActionNotFound` exception will be raised. # - # If none of these conditions are true, and +method_for_action+ - # returns +nil+, an +AbstractController::ActionNotFound+ exception will be raised. + # #### Parameters + # * `action_name` - An action name to find a method name for # - # ==== Parameters - # * action_name - An action name to find a method name for # - # ==== Returns - # * string - The name of the method that handles the action - # * nil - No method name could be found. + # #### Returns + # * `string` - The name of the method that handles the action + # * `nil` - No method name could be found. # - # source://actionpack//lib/abstract_controller/base.rb#273 + # source://actionpack//lib/abstract_controller/base.rb#286 def method_for_action(action_name); end - # Call the action. Override this in a subclass to modify the - # behavior around processing an action. This, and not #process, - # is the intended way to override action dispatching. + # Call the action. Override this in a subclass to modify the behavior around + # processing an action. This, and not #process, is the intended way to override + # action dispatching. # - # Notice that the first argument is the method to be dispatched - # which is *not* necessarily the same as the action name. + # Notice that the first argument is the method to be dispatched which is **not** + # necessarily the same as the action name. # - # source://actionpack//lib/abstract_controller/base.rb#214 + # source://actionpack//lib/abstract_controller/base.rb#225 def process_action(*_arg0, **_arg1, &_arg2); end class << self # Returns the value of attribute abstract. # - # source://actionpack//lib/abstract_controller/base.rb#50 + # source://actionpack//lib/abstract_controller/base.rb#54 def abstract; end - # Define a controller as abstract. See internal_methods for more - # details. + # Define a controller as abstract. See internal_methods for more details. # - # source://actionpack//lib/abstract_controller/base.rb#55 + # source://actionpack//lib/abstract_controller/base.rb#58 def abstract!; end # Returns the value of attribute abstract. # - # source://actionpack//lib/abstract_controller/base.rb#50 + # source://actionpack//lib/abstract_controller/base.rb#54 def abstract?; end - # A list of method names that should be considered actions. This - # includes all public instance methods on a controller, less - # any internal methods (see internal_methods), adding back in - # any methods that are internal, but still exist on the class - # itself. + # A list of method names that should be considered actions. This includes all + # public instance methods on a controller, less any internal methods (see + # internal_methods), adding back in any methods that are internal, but still + # exist on the class itself. # - # ==== Returns - # * Set - A set of all methods that should be considered actions. + # #### Returns + # * `Set` - A set of all methods that should be considered actions. # - # source://actionpack//lib/abstract_controller/base.rb#89 + # source://actionpack//lib/abstract_controller/base.rb#97 def action_methods; end - # action_methods are cached and there is sometimes a need to refresh - # them. ::clear_action_methods! allows you to do that, so next time - # you run action_methods, they will be recalculated. + # action_methods are cached and there is sometimes a need to refresh them. + # ::clear_action_methods! allows you to do that, so next time you run + # action_methods, they will be recalculated. # - # source://actionpack//lib/abstract_controller/base.rb#107 + # source://actionpack//lib/abstract_controller/base.rb#112 def clear_action_methods!; end # Returns the full controller name, underscored, without the ending Controller. # - # class MyApp::MyPostsController < AbstractController::Base + # class MyApp::MyPostsController < AbstractController::Base # - # end + # end # - # MyApp::MyPostsController.controller_path # => "my_app/my_posts" + # MyApp::MyPostsController.controller_path # => "my_app/my_posts" # - # ==== Returns - # * String + # #### Returns + # * `String` # - # source://actionpack//lib/abstract_controller/base.rb#121 + # source://actionpack//lib/abstract_controller/base.rb#127 def controller_path; end - # source://actionpack//lib/abstract_controller/base.rb#59 + # source://actionpack//lib/abstract_controller/base.rb#137 + def eager_load!; end + + # source://actionpack//lib/abstract_controller/base.rb#62 def inherited(klass); end - # A list of all internal methods for a controller. This finds the first - # abstract superclass of a controller, and gets a list of all public - # instance methods on that abstract class. Public instance methods of - # a controller would normally be considered action methods, so methods - # declared on abstract classes are being removed. - # (ActionController::Metal and ActionController::Base are defined as abstract) + # A list of all internal methods for a controller. This finds the first abstract + # superclass of a controller, and gets a list of all public instance methods on + # that abstract class. Public instance methods of a controller would normally be + # considered action methods, so methods declared on abstract classes are being + # removed. (ActionController::Metal and ActionController::Base are defined as + # abstract) # - # source://actionpack//lib/abstract_controller/base.rb#74 + # source://actionpack//lib/abstract_controller/base.rb#77 def internal_methods; end # Refresh the cached action_methods when a new action_method is added. # - # source://actionpack//lib/abstract_controller/base.rb#126 + # source://actionpack//lib/abstract_controller/base.rb#132 def method_added(name); end - # Returns true if the given controller is capable of rendering - # a path. A subclass of +AbstractController::Base+ - # may return false. An Email controller for example does not - # support paths, only full URLs. + # Returns true if the given controller is capable of rendering a path. A + # subclass of `AbstractController::Base` may return false. An Email controller + # for example does not support paths, only full URLs. # # @return [Boolean] # - # source://actionpack//lib/abstract_controller/base.rb#190 + # source://actionpack//lib/abstract_controller/base.rb#200 def supports_path?; end end end -# source://actionpack//lib/abstract_controller/caching.rb#4 +# source://actionpack//lib/abstract_controller/caching.rb#6 module AbstractController::Caching include ::AbstractController::Caching::ConfigMethods extend ::ActiveSupport::Concern @@ -309,14 +317,14 @@ module AbstractController::Caching mixes_in_class_methods ::AbstractController::Caching::ClassMethods mixes_in_class_methods ::AbstractController::Caching::ConfigMethods - # source://actionpack//lib/abstract_controller/caching.rb#52 + # source://actionpack//lib/abstract_controller/caching.rb#54 def view_cache_dependencies; end private # Convenience accessor. # - # source://actionpack//lib/abstract_controller/caching.rb#58 + # source://actionpack//lib/abstract_controller/caching.rb#60 def cache(key, options = T.unsafe(nil), &block); end module GeneratedClassMethods @@ -338,43 +346,44 @@ module AbstractController::Caching end end -# source://actionpack//lib/abstract_controller/caching.rb#46 +# source://actionpack//lib/abstract_controller/caching.rb#48 module AbstractController::Caching::ClassMethods - # source://actionpack//lib/abstract_controller/caching.rb#47 + # source://actionpack//lib/abstract_controller/caching.rb#49 def view_cache_dependency(&dependency); end end -# source://actionpack//lib/abstract_controller/caching.rb#12 +# source://actionpack//lib/abstract_controller/caching.rb#14 module AbstractController::Caching::ConfigMethods - # source://actionpack//lib/abstract_controller/caching.rb#13 + # source://actionpack//lib/abstract_controller/caching.rb#15 def cache_store; end - # source://actionpack//lib/abstract_controller/caching.rb#17 + # source://actionpack//lib/abstract_controller/caching.rb#19 def cache_store=(store); end private # @return [Boolean] # - # source://actionpack//lib/abstract_controller/caching.rb#22 + # source://actionpack//lib/abstract_controller/caching.rb#24 def cache_configured?; end end -# Fragment caching is used for caching various blocks within -# views without caching the entire action as a whole. This is -# useful when certain elements of an action change frequently or -# depend on complicated state while other parts rarely change or -# can be shared amongst multiple parties. The caching is done using -# the +cache+ helper available in the Action View. See +# # Abstract Controller Caching Fragments +# +# Fragment caching is used for caching various blocks within views without +# caching the entire action as a whole. This is useful when certain elements of +# an action change frequently or depend on complicated state while other parts +# rarely change or can be shared amongst multiple parties. The caching is done +# using the `cache` helper available in the Action View. See # ActionView::Helpers::CacheHelper for more information. # -# While it's strongly recommended that you use key-based cache -# expiration (see links in CacheHelper for more information), -# it is also possible to manually expire caches. For example: +# While it's strongly recommended that you use key-based cache expiration (see +# links in CacheHelper for more information), it is also possible to manually +# expire caches. For example: # -# expire_fragment('name_of_cache') +# expire_fragment('name_of_cache') # -# source://actionpack//lib/abstract_controller/caching/fragments.rb#18 +# source://actionpack//lib/abstract_controller/caching/fragments.rb#21 module AbstractController::Caching::Fragments extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -382,57 +391,55 @@ module AbstractController::Caching::Fragments mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::AbstractController::Caching::Fragments::ClassMethods - # Given a key (as described in +expire_fragment+), returns - # a key array suitable for use in reading, writing, or expiring a - # cached fragment. All keys begin with :views, - # followed by ENV["RAILS_CACHE_ID"] or ENV["RAILS_APP_VERSION"] if set, - # followed by any controller-wide key prefix values, ending - # with the specified +key+ value. + # Given a key (as described in `expire_fragment`), returns a key array suitable + # for use in reading, writing, or expiring a cached fragment. All keys begin + # with `:views`, followed by `ENV["RAILS_CACHE_ID"]` or + # `ENV["RAILS_APP_VERSION"]` if set, followed by any controller-wide key prefix + # values, ending with the specified `key` value. # # source://actionpack//lib/abstract_controller/caching/fragments.rb#68 def combined_fragment_cache_key(key); end # Removes fragments from the cache. # - # +key+ can take one of three forms: + # `key` can take one of three forms: # - # * String - This would normally take the form of a path, like - # pages/45/notes. - # * Hash - Treated as an implicit call to +url_for+, like - # { controller: 'pages', action: 'notes', id: 45} - # * Regexp - Will remove any fragment that matches, so - # %r{pages/\d*/notes} might remove all notes. Make sure you - # don't use anchors in the regex (^ or $) because - # the actual filename matched looks like - # ./cache/filename/path.cache. Note: Regexp expiration is - # only supported on caches that can iterate over all keys (unlike - # memcached). + # * String - This would normally take the form of a path, like + # `pages/45/notes`. + # * Hash - Treated as an implicit call to `url_for`, like `{ controller: + # 'pages', action: 'notes', id: 45}` + # * Regexp - Will remove any fragment that matches, so `%r{pages/\d*/notes}` + # might remove all notes. Make sure you don't use anchors in the regex (`^` + # or `$`) because the actual filename matched looks like + # `./cache/filename/path.cache`. Note: Regexp expiration is only supported + # on caches that can iterate over all keys (unlike memcached). # - # +options+ is passed through to the cache store's +delete+ - # method (or delete_matched, for Regexp keys). # - # source://actionpack//lib/abstract_controller/caching/fragments.rb#132 + # `options` is passed through to the cache store's `delete` method (or + # `delete_matched`, for Regexp keys). + # + # source://actionpack//lib/abstract_controller/caching/fragments.rb#131 def expire_fragment(key, options = T.unsafe(nil)); end - # Check if a cached fragment from the location signified by - # +key+ exists (see +expire_fragment+ for acceptable formats). + # Check if a cached fragment from the location signified by `key` exists (see + # `expire_fragment` for acceptable formats). # # @return [Boolean] # # source://actionpack//lib/abstract_controller/caching/fragments.rb#105 def fragment_exist?(key, options = T.unsafe(nil)); end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#145 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#144 def instrument_fragment_cache(name, key, &block); end - # Reads a cached fragment from the location signified by +key+ - # (see +expire_fragment+ for acceptable formats). + # Reads a cached fragment from the location signified by `key` (see + # `expire_fragment` for acceptable formats). # # source://actionpack//lib/abstract_controller/caching/fragments.rb#93 def read_fragment(key, options = T.unsafe(nil)); end - # Writes +content+ to the location signified by - # +key+ (see +expire_fragment+ for acceptable formats). + # Writes `content` to the location signified by `key` (see `expire_fragment` for + # acceptable formats). # # source://actionpack//lib/abstract_controller/caching/fragments.rb#80 def write_fragment(key, content, options = T.unsafe(nil)); end @@ -450,53 +457,50 @@ module AbstractController::Caching::Fragments end end -# source://actionpack//lib/abstract_controller/caching/fragments.rb#35 +# source://actionpack//lib/abstract_controller/caching/fragments.rb#38 module AbstractController::Caching::Fragments::ClassMethods - # Allows you to specify controller-wide key prefixes for - # cache fragments. Pass either a constant +value+, or a block - # which computes a value each time a cache key is generated. + # Allows you to specify controller-wide key prefixes for cache fragments. Pass + # either a constant `value`, or a block which computes a value each time a cache + # key is generated. # - # For example, you may want to prefix all fragment cache keys - # with a global version identifier, so you can easily - # invalidate all caches. + # For example, you may want to prefix all fragment cache keys with a global + # version identifier, so you can easily invalidate all caches. # - # class ApplicationController - # fragment_cache_key "v1" - # end + # class ApplicationController + # fragment_cache_key "v1" + # end # - # When it's time to invalidate all fragments, simply change - # the string constant. Or, progressively roll out the cache - # invalidation using a computed value: + # When it's time to invalidate all fragments, simply change the string constant. + # Or, progressively roll out the cache invalidation using a computed value: # - # class ApplicationController - # fragment_cache_key do - # @account.id.odd? ? "v1" : "v2" + # class ApplicationController + # fragment_cache_key do + # @account.id.odd? ? "v1" : "v2" + # end # end - # end # - # source://actionpack//lib/abstract_controller/caching/fragments.rb#57 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#58 def fragment_cache_key(value = T.unsafe(nil), &key); end end -# = Abstract Controller Callbacks -# -# Abstract Controller provides hooks during the life cycle of a controller action. -# Callbacks allow you to trigger logic during this cycle. Available callbacks are: +# # Abstract Controller Callbacks # -# * after_action -# * append_after_action -# * append_around_action -# * append_before_action -# * around_action -# * before_action -# * prepend_after_action -# * prepend_around_action -# * prepend_before_action -# * skip_after_action -# * skip_around_action -# * skip_before_action +# Abstract Controller provides hooks during the life cycle of a controller +# action. Callbacks allow you to trigger logic during this cycle. Available +# callbacks are: # -# NOTE: Calling the same callback multiple times will overwrite previous callback definitions. +# * `after_action` +# * `append_after_action` +# * `append_around_action` +# * `append_before_action` +# * `around_action` +# * `before_action` +# * `prepend_after_action` +# * `prepend_around_action` +# * `prepend_before_action` +# * `skip_after_action` +# * `skip_around_action` +# * `skip_before_action` # # source://actionpack//lib/abstract_controller/callbacks.rb#24 module AbstractController::Callbacks @@ -511,10 +515,10 @@ module AbstractController::Callbacks private - # Override AbstractController::Base#process_action to run the - # process_action callbacks around the normal behavior. + # Override `AbstractController::Base#process_action` to run the `process_action` + # callbacks around the normal behavior. # - # source://actionpack//lib/abstract_controller/callbacks.rb#232 + # source://actionpack//lib/abstract_controller/callbacks.rb#259 def process_action(*_arg0, **_arg1, &_arg2); end module GeneratedClassMethods @@ -529,253 +533,259 @@ module AbstractController::Callbacks end end -# source://actionpack//lib/abstract_controller/callbacks.rb#38 +# source://actionpack//lib/abstract_controller/callbacks.rb#39 class AbstractController::Callbacks::ActionFilter # @return [ActionFilter] a new instance of ActionFilter # - # source://actionpack//lib/abstract_controller/callbacks.rb#39 - def initialize(actions); end + # source://actionpack//lib/abstract_controller/callbacks.rb#40 + def initialize(filters, conditional_key, actions); end # @return [Boolean] # - # source://actionpack//lib/abstract_controller/callbacks.rb#43 + # source://actionpack//lib/abstract_controller/callbacks.rb#46 def after(controller); end # @return [Boolean] # - # source://actionpack//lib/abstract_controller/callbacks.rb#43 + # source://actionpack//lib/abstract_controller/callbacks.rb#46 def around(controller); end # @return [Boolean] # - # source://actionpack//lib/abstract_controller/callbacks.rb#43 + # source://actionpack//lib/abstract_controller/callbacks.rb#46 def before(controller); end # @return [Boolean] # - # source://actionpack//lib/abstract_controller/callbacks.rb#43 + # source://actionpack//lib/abstract_controller/callbacks.rb#46 def match?(controller); end end -# source://actionpack//lib/abstract_controller/callbacks.rb#52 +# source://actionpack//lib/abstract_controller/callbacks.rb#74 module AbstractController::Callbacks::ClassMethods - # Take callback names and an optional callback proc, normalize them, - # then call the block with each callback. This allows us to abstract - # the normalization across several methods that use it. + # Take callback names and an optional callback proc, normalize them, then call + # the block with each callback. This allows us to abstract the normalization + # across several methods that use it. # - # ==== Parameters - # * callbacks - An array of callbacks, with an optional - # options hash as the last parameter. - # * block - A proc that should be added to the callbacks. + # #### Parameters + # * `callbacks` - An array of callbacks, with an optional options hash as the + # last parameter. + # * `block` - A proc that should be added to the callbacks. # - # ==== Block Parameters - # * name - The callback to be added. - # * options - A hash of options to be used when adding the callback. # - # source://actionpack//lib/abstract_controller/callbacks.rb#96 + # #### Block Parameters + # * `name` - The callback to be added. + # * `options` - A hash of options to be used when adding the callback. + # + # source://actionpack//lib/abstract_controller/callbacks.rb#120 def _insert_callbacks(callbacks, block = T.unsafe(nil)); end - # source://actionpack//lib/abstract_controller/callbacks.rb#77 + # source://actionpack//lib/abstract_controller/callbacks.rb#98 def _normalize_callback_option(options, from, to); end - # If +:only+ or +:except+ are used, convert the options into the - # +:if+ and +:unless+ options of ActiveSupport::Callbacks. + # If `:only` or `:except` are used, convert the options into the `:if` and + # `:unless` options of ActiveSupport::Callbacks. # - # The basic idea is that :only => :index gets converted to - # :if => proc {|c| c.action_name == "index" }. + # The basic idea is that `:only => :index` gets converted to `:if => proc {|c| + # c.action_name == "index" }`. # - # Note that :only has priority over :if in case they - # are used together. + # Note that `:only` has priority over `:if` in case they are used together. # - # only: :index, if: -> { true } # the :if option will be ignored. + # only: :index, if: -> { true } # the :if option will be ignored. # - # Note that :if has priority over :except in case they - # are used together. + # Note that `:if` has priority over `:except` in case they are used together. # - # except: :index, if: -> { true } # the :except option will be ignored. + # except: :index, if: -> { true } # the :except option will be ignored. # - # ==== Options - # * only - The callback should be run only for this action. - # * except - The callback should be run for all actions except this action. + # #### Options + # * `only` - The callback should be run only for this action. + # * `except` - The callback should be run for all actions except this action. # - # source://actionpack//lib/abstract_controller/callbacks.rb#72 + # source://actionpack//lib/abstract_controller/callbacks.rb#93 def _normalize_callback_options(options); end - # source://actionpack//lib/abstract_controller/callbacks.rb#204 + # source://actionpack//lib/abstract_controller/callbacks.rb#231 def after_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#204 + # source://actionpack//lib/abstract_controller/callbacks.rb#231 def append_after_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#204 + # source://actionpack//lib/abstract_controller/callbacks.rb#231 def append_around_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#204 + # source://actionpack//lib/abstract_controller/callbacks.rb#231 def append_before_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#204 + # source://actionpack//lib/abstract_controller/callbacks.rb#231 def around_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#204 + # source://actionpack//lib/abstract_controller/callbacks.rb#231 def before_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#210 + # source://actionpack//lib/abstract_controller/callbacks.rb#237 def prepend_after_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#210 + # source://actionpack//lib/abstract_controller/callbacks.rb#237 def prepend_around_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#210 + # source://actionpack//lib/abstract_controller/callbacks.rb#237 def prepend_before_action(*names, &blk); end - # source://actionpack//lib/abstract_controller/callbacks.rb#218 + # source://actionpack//lib/abstract_controller/callbacks.rb#245 def skip_after_action(*names); end - # source://actionpack//lib/abstract_controller/callbacks.rb#218 + # source://actionpack//lib/abstract_controller/callbacks.rb#245 def skip_around_action(*names); end - # source://actionpack//lib/abstract_controller/callbacks.rb#218 + # source://actionpack//lib/abstract_controller/callbacks.rb#245 def skip_before_action(*names); end end -# source://actionpack//lib/abstract_controller/collector.rb#6 +# source://actionpack//lib/abstract_controller/collector.rb#8 module AbstractController::Collector - # source://actionpack//lib/abstract_controller/collector.rb#10 - def atom(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def atom(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/abstract_controller/collector.rb#12 + def bmp(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def bmp(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def css(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def css(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def csv(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def csv(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def gif(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def gif(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def gzip(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def gzip(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def html(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def html(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def ics(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def ics(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def jpeg(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def jpeg(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def js(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def js(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def json(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def json(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def m4a(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def m4a(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def mp3(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def mp3(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def mp4(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def mp4(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def mpeg(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def mpeg(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def multipart_form(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def multipart_form(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def ogg(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def ogg(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def otf(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def otf(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def pdf(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def pdf(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def png(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def png(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def rss(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def rss(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def svg(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def svg(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def text(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def text(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def tiff(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def tiff(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def ttf(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def ttf(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def turbo_stream(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def url_encoded_form(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def url_encoded_form(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def vcf(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def vcf(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def vtt(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def vtt(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def webm(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def webm(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def woff(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def webp(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def woff2(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def woff(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def xml(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def woff2(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def yaml(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def xml(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/collector.rb#10 - def zip(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#12 + def yaml(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/abstract_controller/collector.rb#12 + def zip(*_arg0, **_arg1, &_arg2); end private - # source://actionpack//lib/abstract_controller/collector.rb#26 - def method_missing(symbol, *args, **_arg2, &block); end + # source://actionpack//lib/abstract_controller/collector.rb#27 + def method_missing(symbol, *_arg1, **_arg2, &_arg3); end class << self - # source://actionpack//lib/abstract_controller/collector.rb#7 + # source://actionpack//lib/abstract_controller/collector.rb#9 def generate_method_for_mime(mime); end end end -# source://actionpack//lib/abstract_controller/rendering.rb#9 +# source://actionpack//lib/abstract_controller/rendering.rb#11 class AbstractController::DoubleRenderError < ::AbstractController::Error # @return [DoubleRenderError] a new instance of DoubleRenderError # - # source://actionpack//lib/abstract_controller/rendering.rb#12 + # source://actionpack//lib/abstract_controller/rendering.rb#14 def initialize(message = T.unsafe(nil)); end end -# source://actionpack//lib/abstract_controller/rendering.rb#10 +# source://actionpack//lib/abstract_controller/rendering.rb#12 AbstractController::DoubleRenderError::DEFAULT_MESSAGE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/abstract_controller/error.rb#4 +# source://actionpack//lib/abstract_controller/error.rb#6 class AbstractController::Error < ::StandardError; end -# source://actionpack//lib/abstract_controller/helpers.rb#7 +# source://actionpack//lib/abstract_controller/helpers.rb#9 module AbstractController::Helpers extend ::ActiveSupport::Concern + extend ::AbstractController::Helpers::Resolution include GeneratedInstanceMethods mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::AbstractController::Helpers::ClassMethods - # source://actionpack//lib/abstract_controller/helpers.rb#40 + # source://actionpack//lib/abstract_controller/helpers.rb#28 def _helpers; end module GeneratedClassMethods @@ -791,152 +801,152 @@ module AbstractController::Helpers end end -# source://actionpack//lib/abstract_controller/helpers.rb#44 +# source://actionpack//lib/abstract_controller/helpers.rb#64 module AbstractController::Helpers::ClassMethods + include ::AbstractController::Helpers::Resolution + # Sets the attribute _helpers # # @param value the value to set the attribute _helpers to. # - # source://actionpack//lib/abstract_controller/helpers.rb#56 + # source://actionpack//lib/abstract_controller/helpers.rb#76 def _helpers=(_arg0); end - # source://actionpack//lib/abstract_controller/helpers.rb#185 + # source://actionpack//lib/abstract_controller/helpers.rb#216 def _helpers_for_modification; end - # Clears up all existing helpers in this class, only keeping the helper - # with the same name as this class. + # Clears up all existing helpers in this class, only keeping the helper with the + # same name as this class. # - # source://actionpack//lib/abstract_controller/helpers.rb#159 + # source://actionpack//lib/abstract_controller/helpers.rb#207 def clear_helpers; end # Includes the given modules in the template class. # - # Modules can be specified in different ways. All of the following calls - # include +FooHelper+: + # Modules can be specified in different ways. All of the following calls include + # `FooHelper`: # - # # Module, recommended. - # helper FooHelper + # # Module, recommended. + # helper FooHelper # - # # String/symbol without the "helper" suffix, camel or snake case. - # helper "Foo" - # helper :Foo - # helper "foo" - # helper :foo + # # String/symbol without the "helper" suffix, camel or snake case. + # helper "Foo" + # helper :Foo + # helper "foo" + # helper :foo # - # The last two assume that "foo".camelize returns "Foo". + # The last two assume that `"foo".camelize` returns "Foo". # - # When strings or symbols are passed, the method finds the actual module - # object using String#constantize. Therefore, if the module has not been - # yet loaded, it has to be autoloadable, which is normally the case. + # When strings or symbols are passed, the method finds the actual module object + # using String#constantize. Therefore, if the module has not been yet loaded, it + # has to be autoloadable, which is normally the case. # - # Namespaces are supported. The following calls include +Foo::BarHelper+: + # Namespaces are supported. The following calls include `Foo::BarHelper`: # - # # Module, recommended. - # helper Foo::BarHelper + # # Module, recommended. + # helper Foo::BarHelper # - # # String/symbol without the "helper" suffix, camel or snake case. - # helper "Foo::Bar" - # helper :"Foo::Bar" - # helper "foo/bar" - # helper :"foo/bar" + # # String/symbol without the "helper" suffix, camel or snake case. + # helper "Foo::Bar" + # helper :"Foo::Bar" + # helper "foo/bar" + # helper :"foo/bar" # - # The last two assume that "foo/bar".camelize returns "Foo::Bar". + # The last two assume that `"foo/bar".camelize` returns "Foo::Bar". # - # The method accepts a block too. If present, the block is evaluated in - # the context of the controller helper module. This simple call makes the - # +wadus+ method available in templates of the enclosing controller: + # The method accepts a block too. If present, the block is evaluated in the + # context of the controller helper module. This simple call makes the `wadus` + # method available in templates of the enclosing controller: # - # helper do - # def wadus - # "wadus" + # helper do + # def wadus + # "wadus" + # end # end - # end # # Furthermore, all the above styles can be mixed together: # - # helper FooHelper, "woo", "bar/baz" do - # def wadus - # "wadus" + # helper FooHelper, "woo", "bar/baz" do + # def wadus + # "wadus" + # end # end - # end # - # source://actionpack//lib/abstract_controller/helpers.rb#148 + # source://actionpack//lib/abstract_controller/helpers.rb#196 def helper(*args, &block); end # Declare a controller method as a helper. For example, the following - # makes the +current_user+ and +logged_in?+ controller methods available + # makes the `current_user` and `logged_in?` controller methods available # to the view: - # class ApplicationController < ActionController::Base - # helper_method :current_user, :logged_in? + # class ApplicationController < ActionController::Base + # helper_method :current_user, :logged_in? # - # private - # def current_user - # @current_user ||= User.find_by(id: session[:user]) - # end + # private + # def current_user + # @current_user ||= User.find_by(id: session[:user]) + # end # - # def logged_in? - # current_user != nil - # end - # end + # def logged_in? + # current_user != nil + # end + # end # # In a view: - # <% if logged_in? -%>Welcome, <%= current_user.name %><% end -%> + # <% if logged_in? -%>Welcome, <%= current_user.name %><% end -%> # - # ==== Parameters - # * method[, method] - A name or names of a method on the controller - # to be made available on the view. + # #### Parameters + # * `method[, method]` - A name or names of a method on the controller to be + # made available on the view. # - # source://actionpack//lib/abstract_controller/helpers.rb#80 + # source://actionpack//lib/abstract_controller/helpers.rb#126 def helper_method(*methods); end - # When a class is inherited, wrap its helper module in a new module. - # This ensures that the parent class's module can be changed - # independently of the child class's. + # When a class is inherited, wrap its helper module in a new module. This + # ensures that the parent class's module can be changed independently of the + # child class's. # - # source://actionpack//lib/abstract_controller/helpers.rb#48 + # source://actionpack//lib/abstract_controller/helpers.rb#68 def inherited(klass); end - # Given an array of values like the ones accepted by +helper+, this method - # returns an array with the corresponding modules, in the same order. - # - # source://actionpack//lib/abstract_controller/helpers.rb#170 - def modules_for_helpers(modules_or_helper_prefixes); end - private - # source://actionpack//lib/abstract_controller/helpers.rb#204 + # source://actionpack//lib/abstract_controller/helpers.rb#235 def default_helper_module!; end - # source://actionpack//lib/abstract_controller/helpers.rb#193 + # source://actionpack//lib/abstract_controller/helpers.rb#224 def define_helpers_module(klass, helpers = T.unsafe(nil)); end end -# source://actionpack//lib/abstract_controller/helpers.rb#26 -class AbstractController::Helpers::MissingHelperError < ::LoadError - # @return [MissingHelperError] a new instance of MissingHelperError - # - # source://actionpack//lib/abstract_controller/helpers.rb#27 - def initialize(error, path); end +# source://actionpack//lib/abstract_controller/helpers.rb#32 +module AbstractController::Helpers::Resolution + # source://actionpack//lib/abstract_controller/helpers.rb#48 + def all_helpers_from_path(path); end + + # source://actionpack//lib/abstract_controller/helpers.rb#57 + def helper_modules_from_paths(paths); end + + # source://actionpack//lib/abstract_controller/helpers.rb#33 + def modules_for_helpers(modules_or_helper_prefixes); end end -# source://actionpack//lib/abstract_controller/logger.rb#6 +# source://actionpack//lib/abstract_controller/logger.rb#8 module AbstractController::Logger extend ::ActiveSupport::Concern include ::ActiveSupport::Benchmarkable end -# source://actionpack//lib/abstract_controller/railties/routes_helpers.rb#6 +# source://actionpack//lib/abstract_controller/railties/routes_helpers.rb#8 module AbstractController::Railties; end -# source://actionpack//lib/abstract_controller/railties/routes_helpers.rb#7 +# source://actionpack//lib/abstract_controller/railties/routes_helpers.rb#9 module AbstractController::Railties::RoutesHelpers class << self - # source://actionpack//lib/abstract_controller/railties/routes_helpers.rb#8 + # source://actionpack//lib/abstract_controller/railties/routes_helpers.rb#10 def with(routes, include_path_helpers = T.unsafe(nil)); end end end -# source://actionpack//lib/abstract_controller/rendering.rb#17 +# source://actionpack//lib/abstract_controller/rendering.rb#19 module AbstractController::Rendering extend ::ActiveSupport::Concern include ::ActionView::ViewPaths @@ -944,146 +954,133 @@ module AbstractController::Rendering mixes_in_class_methods ::ActionView::ViewPaths::ClassMethods # Normalizes arguments and options, and then delegates to render_to_body and - # sticks the result in self.response_body. + # sticks the result in `self.response_body`. # - # Supported options depend on the underlying +render_to_body+ implementation. + # Supported options depend on the underlying `render_to_body` implementation. # - # source://actionpack//lib/abstract_controller/rendering.rb#25 + # source://actionpack//lib/abstract_controller/rendering.rb#27 def render(*args, &block); end # Performs the actual template rendering. # - # source://actionpack//lib/abstract_controller/rendering.rb#49 + # source://actionpack//lib/abstract_controller/rendering.rb#51 def render_to_body(options = T.unsafe(nil)); end # Similar to #render, but only returns the rendered template as a string, - # instead of setting +self.response_body+. + # instead of setting `self.response_body`. # - # If a component extends the semantics of +response_body+ (as ActionController - # extends it to be anything that responds to the method each), this method - # needs to be overridden in order to still return a string. + # If a component extends the semantics of `response_body` (as ActionController + # extends it to be anything that responds to the method each), this method needs + # to be overridden in order to still return a string. # - # source://actionpack//lib/abstract_controller/rendering.rb#43 + # source://actionpack//lib/abstract_controller/rendering.rb#45 def render_to_string(*args, &block); end - # Returns +Content-Type+ of rendered content. + # Returns `Content-Type` of rendered content. # - # source://actionpack//lib/abstract_controller/rendering.rb#53 + # source://actionpack//lib/abstract_controller/rendering.rb#55 def rendered_format; end - # This method should return a hash with assigns. - # You can overwrite this configuration per controller. + # This method should return a hash with assigns. You can overwrite this + # configuration per controller. # - # source://actionpack//lib/abstract_controller/rendering.rb#61 + # source://actionpack//lib/abstract_controller/rendering.rb#63 def view_assigns; end private - # Normalize args by converting render "foo" to - # render :action => "foo" and render "foo/bar" to - # render :file => "foo/bar". + # Normalize args by converting `render "foo"` to `render action: "foo"` and + # `render "foo/bar"` to `render file: "foo/bar"`. # - # source://actionpack//lib/abstract_controller/rendering.rb#73 + # source://actionpack//lib/abstract_controller/rendering.rb#74 def _normalize_args(action = T.unsafe(nil), options = T.unsafe(nil)); end # Normalize options. # - # source://actionpack//lib/abstract_controller/rendering.rb#88 + # source://actionpack//lib/abstract_controller/rendering.rb#89 def _normalize_options(options); end # Normalize args and options. # - # source://actionpack//lib/abstract_controller/rendering.rb#114 + # source://actionpack//lib/abstract_controller/rendering.rb#115 def _normalize_render(*args, &block); end # Process the rendered format. # - # source://actionpack//lib/abstract_controller/rendering.rb#98 + # source://actionpack//lib/abstract_controller/rendering.rb#99 def _process_format(format); end # Process extra options. # - # source://actionpack//lib/abstract_controller/rendering.rb#93 + # source://actionpack//lib/abstract_controller/rendering.rb#94 def _process_options(options); end - # source://actionpack//lib/abstract_controller/rendering.rb#101 + # source://actionpack//lib/abstract_controller/rendering.rb#102 def _process_variant(options); end - # source://actionpack//lib/abstract_controller/rendering.rb#121 + # source://actionpack//lib/abstract_controller/rendering.rb#122 def _protected_ivars; end - # source://actionpack//lib/abstract_controller/rendering.rb#104 + # source://actionpack//lib/abstract_controller/rendering.rb#105 def _set_html_content_type; end - # source://actionpack//lib/abstract_controller/rendering.rb#110 + # source://actionpack//lib/abstract_controller/rendering.rb#111 def _set_rendered_content_type(format); end - # source://actionpack//lib/abstract_controller/rendering.rb#107 + # source://actionpack//lib/abstract_controller/rendering.rb#108 def _set_vary_header; end end -# source://actionpack//lib/abstract_controller/rendering.rb#57 +# source://actionpack//lib/abstract_controller/rendering.rb#59 AbstractController::Rendering::DEFAULT_PROTECTED_INSTANCE_VARIABLES = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/abstract_controller/translation.rb#6 +# source://actionpack//lib/abstract_controller/translation.rb#8 module AbstractController::Translation - # Delegates to I18n.localize. Also aliased as l. + # Delegates to `I18n.localize`. # - # source://actionpack//lib/abstract_controller/translation.rb#33 + # source://actionpack//lib/abstract_controller/translation.rb#37 def l(object, **options); end - # Delegates to I18n.localize. Also aliased as l. + # Delegates to `I18n.localize`. # - # source://actionpack//lib/abstract_controller/translation.rb#33 + # source://actionpack//lib/abstract_controller/translation.rb#37 def localize(object, **options); end - # source://actionpack//lib/abstract_controller/translation.rb#7 - def raise_on_missing_translations; end - - # source://actionpack//lib/abstract_controller/translation.rb#7 - def raise_on_missing_translations=(val); end - - # Delegates to I18n.translate. Also aliased as t. + # Delegates to `I18n.translate`. # # When the given key starts with a period, it will be scoped by the current - # controller and action. So if you call translate(".foo") from - # PeopleController#index, it will convert the call to - # I18n.translate("people.index.foo"). This makes it less repetitive - # to translate many keys within the same controller / action and gives you a - # simple framework for scoping them consistently. + # controller and action. So if you call `translate(".foo")` from + # `PeopleController#index`, it will convert the call to + # `I18n.translate("people.index.foo")`. This makes it less repetitive to + # translate many keys within the same controller / action and gives you a simple + # framework for scoping them consistently. # # source://actionpack//lib/abstract_controller/translation.rb#17 def t(key, **options); end - # Delegates to I18n.translate. Also aliased as t. + # Delegates to `I18n.translate`. # # When the given key starts with a period, it will be scoped by the current - # controller and action. So if you call translate(".foo") from - # PeopleController#index, it will convert the call to - # I18n.translate("people.index.foo"). This makes it less repetitive - # to translate many keys within the same controller / action and gives you a - # simple framework for scoping them consistently. + # controller and action. So if you call `translate(".foo")` from + # `PeopleController#index`, it will convert the call to + # `I18n.translate("people.index.foo")`. This makes it less repetitive to + # translate many keys within the same controller / action and gives you a simple + # framework for scoping them consistently. # # source://actionpack//lib/abstract_controller/translation.rb#17 def translate(key, **options); end - - class << self - # source://actionpack//lib/abstract_controller/translation.rb#7 - def raise_on_missing_translations; end - - # source://actionpack//lib/abstract_controller/translation.rb#7 - def raise_on_missing_translations=(val); end - end end -# Includes +url_for+ into the host class (e.g. an abstract controller or mailer). The class -# has to provide a +RouteSet+ by implementing the _routes methods. Otherwise, an -# exception will be raised. +# # URL For +# +# Includes `url_for` into the host class (e.g. an abstract controller or +# mailer). The class has to provide a `RouteSet` by implementing the `_routes` +# methods. Otherwise, an exception will be raised. # -# Note that this module is completely decoupled from HTTP - the only requirement is a valid -# _routes implementation. +# Note that this module is completely decoupled from HTTP - the only requirement +# is a valid `_routes` implementation. # -# source://actionpack//lib/abstract_controller/url_for.rb#10 +# source://actionpack//lib/abstract_controller/url_for.rb#14 module AbstractController::UrlFor extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -1092,7 +1089,7 @@ module AbstractController::UrlFor mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::AbstractController::UrlFor::ClassMethods - # source://actionpack//lib/abstract_controller/url_for.rb#14 + # source://actionpack//lib/abstract_controller/url_for.rb#18 def _routes; end module GeneratedClassMethods @@ -1108,117 +1105,129 @@ module AbstractController::UrlFor end end -# source://actionpack//lib/abstract_controller/url_for.rb#19 +# source://actionpack//lib/abstract_controller/url_for.rb#23 module AbstractController::UrlFor::ClassMethods - # source://actionpack//lib/abstract_controller/url_for.rb#20 + # source://actionpack//lib/abstract_controller/url_for.rb#24 def _routes; end - # source://actionpack//lib/abstract_controller/url_for.rb#24 + # source://actionpack//lib/abstract_controller/url_for.rb#28 def action_methods; end end -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#13 +# # Action Controller +# +# Action Controller is a module of Action Pack. +# +# Action Controller provides a base controller class that can be subclassed to +# implement filters and actions to handle requests. The result of an action is +# typically content generated from views. +# +# source://actionpack//lib/action_controller/deprecator.rb#5 module ActionController extend ::ActiveSupport::Autoload class << self - # See Renderers.add + # See Renderers.add # - # source://actionpack//lib/action_controller/metal/renderers.rb#7 + # source://actionpack//lib/action_controller/metal/renderers.rb#9 def add_renderer(key, &block); end - # See Renderers.remove + # source://actionpack//lib/action_controller/deprecator.rb#6 + def deprecator; end + + # See Renderers.remove # - # source://actionpack//lib/action_controller/metal/renderers.rb#12 + # source://actionpack//lib/action_controller/metal/renderers.rb#14 def remove_renderer(key); end end end -# API Controller is a lightweight version of ActionController::Base, -# created for applications that don't require all functionalities that a complete -# \Rails controller provides, allowing you to create controllers with just the -# features that you need for API only applications. +# # Action Controller API # -# An API Controller is different from a normal controller in the sense that -# by default it doesn't include a number of features that are usually required -# by browser access only: layouts and templates rendering, -# flash, assets, and so on. This makes the entire controller stack thinner, -# suitable for API applications. It doesn't mean you won't have such -# features if you need them: they're all available for you to include in -# your application, they're just not part of the default API controller stack. +# API Controller is a lightweight version of ActionController::Base, created for +# applications that don't require all functionalities that a complete Rails +# controller provides, allowing you to create controllers with just the features +# that you need for API only applications. # -# Normally, +ApplicationController+ is the only controller that inherits from -# ActionController::API. All other controllers in turn inherit from -# +ApplicationController+. +# An API Controller is different from a normal controller in the sense that by +# default it doesn't include a number of features that are usually required by +# browser access only: layouts and templates rendering, flash, assets, and so +# on. This makes the entire controller stack thinner, suitable for API +# applications. It doesn't mean you won't have such features if you need them: +# they're all available for you to include in your application, they're just not +# part of the default API controller stack. +# +# Normally, `ApplicationController` is the only controller that inherits from +# `ActionController::API`. All other controllers in turn inherit from +# `ApplicationController`. # # A sample controller could look like this: # -# class PostsController < ApplicationController -# def index -# posts = Post.all -# render json: posts +# class PostsController < ApplicationController +# def index +# posts = Post.all +# render json: posts +# end # end -# end # # Request, response, and parameters objects all work the exact same way as # ActionController::Base. # -# == Renders +# ## Renders # -# The default API Controller stack includes all renderers, which means you -# can use render :json and siblings freely in your controllers. Keep -# in mind that templates are not going to be rendered, so you need to ensure -# your controller is calling either render or redirect_to in -# all actions, otherwise it will return 204 No Content. +# The default API Controller stack includes all renderers, which means you can +# use `render :json` and siblings freely in your controllers. Keep in mind that +# templates are not going to be rendered, so you need to ensure your controller +# is calling either `render` or `redirect_to` in all actions, otherwise it will +# return `204 No Content`. # -# def show -# post = Post.find(params[:id]) -# render json: post -# end +# def show +# post = Post.find(params[:id]) +# render json: post +# end # -# == Redirects +# ## Redirects # # Redirects are used to move from one action to another. You can use the -# redirect_to method in your controllers in the same way as in +# `redirect_to` method in your controllers in the same way as in # ActionController::Base. For example: # -# def create -# redirect_to root_url and return if not_authorized? -# # do stuff here -# end +# def create +# redirect_to root_url and return if not_authorized? +# # do stuff here +# end # -# == Adding New Behavior +# ## Adding New Behavior # # In some scenarios you may want to add back some functionality provided by # ActionController::Base that is not present by default in -# ActionController::API, for instance MimeResponds. This -# module gives you the respond_to method. Adding it is quite simple, -# you just need to include the module in a specific controller or in -# +ApplicationController+ in case you want it available in your entire -# application: -# -# class ApplicationController < ActionController::API -# include ActionController::MimeResponds -# end -# -# class PostsController < ApplicationController -# def index -# posts = Post.all -# -# respond_to do |format| -# format.json { render json: posts } -# format.xml { render xml: posts } +# `ActionController::API`, for instance `MimeResponds`. This module gives you +# the `respond_to` method. Adding it is quite simple, you just need to include +# the module in a specific controller or in `ApplicationController` in case you +# want it available in your entire application: +# +# class ApplicationController < ActionController::API +# include ActionController::MimeResponds +# end +# +# class PostsController < ApplicationController +# def index +# posts = Post.all +# +# respond_to do |format| +# format.json { render json: posts } +# format.xml { render xml: posts } +# end # end # end -# end # -# Make sure to check the modules included in ActionController::Base -# if you want to use any other functionality that is not provided -# by ActionController::API out of the box. +# Make sure to check the modules included in ActionController::Base if you want +# to use any other functionality that is not provided by `ActionController::API` +# out of the box. # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://actionpack//lib/action_controller/api.rb#89 +# source://actionpack//lib/action_controller/api.rb#92 class ActionController::API < ::ActionController::Metal include ::ActionView::ViewPaths include ::AbstractController::Rendering @@ -1237,6 +1246,7 @@ class ActionController::API < ::ActionController::Metal include ::ActionController::ConditionalGet include ::ActionController::BasicImplicitRender include ::ActionController::StrongParameters + include ::ActionController::RateLimiting include ::ActionController::DataStreaming include ::ActionController::DefaultHeaders include ::ActionController::Logging @@ -1247,11 +1257,17 @@ class ActionController::API < ::ActionController::Metal include ::ActionController::Instrumentation include ::ActionController::ParamsWrapper include ::ActionController::RespondWith + include ::Devise::Controllers::SignInOut + include ::Devise::Controllers::StoreLocation + include ::Devise::Controllers::Helpers + include ::Devise::Controllers::UrlHelpers + include ::Turbo::RequestIdTracking extend ::ActionView::ViewPaths::ClassMethods extend ::AbstractController::UrlFor::ClassMethods extend ::ActionController::Rendering::ClassMethods extend ::ActionController::Renderers::ClassMethods extend ::ActionController::ConditionalGet::ClassMethods + extend ::ActionController::RateLimiting::ClassMethods extend ::ActionController::DefaultHeaders::ClassMethods extend ::ActionController::Logging::ClassMethods extend ::ActiveSupport::Callbacks::ClassMethods @@ -1260,26 +1276,27 @@ class ActionController::API < ::ActionController::Metal extend ::ActionController::Instrumentation::ClassMethods extend ::ActionController::ParamsWrapper::ClassMethods extend ::ActionController::RespondWith::ClassMethods + extend ::Devise::Controllers::Helpers::ClassMethods - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _process_action_callbacks; end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers=(_arg0); end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_process_action_callbacks(&block); end # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 @@ -1291,86 +1308,92 @@ class ActionController::API < ::ActionController::Metal # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers=(_arg0); end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to=(_arg0); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder=(_arg0); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder?; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _process_action_callbacks=(value); end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers=(value); end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers?; end # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 @@ -1382,271 +1405,436 @@ class ActionController::API < ::ActionController::Metal # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers=(value); end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder?; end - # Shortcut helper that returns all the ActionController::API modules except - # the ones passed as arguments: + # Shortcut helper that returns all the ActionController::API modules except the + # ones passed as arguments: # - # class MyAPIBaseController < ActionController::Metal - # ActionController::API.without_modules(:UrlFor).each do |left| - # include left + # class MyAPIBaseController < ActionController::Metal + # ActionController::API.without_modules(:UrlFor).each do |left| + # include left + # end # end - # end # - # This gives better control over what you want to exclude and makes it easier - # to create an API controller class, instead of listing the modules required + # This gives better control over what you want to exclude and makes it easier to + # create an API controller class, instead of listing the modules required # manually. # - # source://actionpack//lib/action_controller/api.rb#104 + # source://actionpack//lib/action_controller/api.rb#107 def without_modules(*modules); end end end -# source://actionpack//lib/action_controller/api.rb#112 +# source://actionpack//lib/action_controller/api.rb#115 ActionController::API::MODULES = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_controller/metal/exceptions.rb#4 +# source://actionpack//lib/action_controller/metal/exceptions.rb#6 class ActionController::ActionControllerError < ::StandardError; end -# source://actionpack//lib/action_controller/api/api_rendering.rb#4 +# source://actionpack//lib/action_controller/metal/allow_browser.rb#6 +module ActionController::AllowBrowser + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionController::AllowBrowser::ClassMethods + + private + + # source://actionpack//lib/action_controller/metal/allow_browser.rb#53 + def allow_browser(versions:, block:); end +end + +# source://actionpack//lib/action_controller/metal/allow_browser.rb#63 +class ActionController::AllowBrowser::BrowserBlocker + # @return [BrowserBlocker] a new instance of BrowserBlocker + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#70 + def initialize(request, versions:); end + + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#74 + def blocked?; end + + # Returns the value of attribute request. + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#68 + def request; end + + # Returns the value of attribute versions. + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#68 + def versions; end + + private + + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#95 + def bot?; end + + # source://actionpack//lib/action_controller/metal/allow_browser.rb#111 + def expanded_versions; end + + # source://actionpack//lib/action_controller/metal/allow_browser.rb#107 + def minimum_browser_version_for_browser; end + + # source://actionpack//lib/action_controller/metal/allow_browser.rb#115 + def normalized_browser_name; end + + # source://actionpack//lib/action_controller/metal/allow_browser.rb#79 + def parsed_user_agent; end + + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#87 + def unsupported_browser?; end + + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#83 + def user_agent_version_reported?; end + + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#99 + def version_below_minimum_required?; end + + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#91 + def version_guarded_browser?; end +end + +# source://actionpack//lib/action_controller/metal/allow_browser.rb#64 +ActionController::AllowBrowser::BrowserBlocker::SETS = T.let(T.unsafe(nil), Hash) + +# source://actionpack//lib/action_controller/metal/allow_browser.rb#9 +module ActionController::AllowBrowser::ClassMethods + # Specify the browser versions that will be allowed to access all actions (or + # some, as limited by `only:` or `except:`). Only browsers matched in the hash + # or named set passed to `versions:` will be blocked if they're below the + # versions specified. This means that all other browsers, as well as agents that + # aren't reporting a user-agent header, will be allowed access. + # + # A browser that's blocked will by default be served the file in + # public/406-unsupported-browser.html with a HTTP status code of "406 Not + # Acceptable". + # + # In addition to specifically named browser versions, you can also pass + # `:modern` as the set to restrict support to browsers natively supporting webp + # images, web push, badges, import maps, CSS nesting, and CSS :has. This + # includes Safari 17.2+, Chrome 120+, Firefox 121+, Opera 106+. + # + # You can use https://caniuse.com to check for browser versions supporting the + # features you use. + # + # You can use `ActiveSupport::Notifications` to subscribe to events of browsers + # being blocked using the `browser_block.action_controller` event name. + # + # Examples: + # + # class ApplicationController < ActionController::Base + # # Allow only browsers natively supporting webp images, web push, badges, import maps, CSS nesting, and CSS :has + # allow_browser versions: :modern + # end + # + # class ApplicationController < ActionController::Base + # # All versions of Chrome and Opera will be allowed, but no versions of "internet explorer" (ie). Safari needs to be 16.4+ and Firefox 121+. + # allow_browser versions: { safari: 16.4, firefox: 121, ie: false } + # end + # + # class MessagesController < ApplicationController + # # In addition to the browsers blocked by ApplicationController, also block Opera below 104 and Chrome below 119 for the show action. + # allow_browser versions: { opera: 104, chrome: 119 }, only: :show + # end + # + # source://actionpack//lib/action_controller/metal/allow_browser.rb#47 + def allow_browser(versions:, block: T.unsafe(nil), **options); end +end + +# source://actionpack//lib/action_controller/api/api_rendering.rb#6 module ActionController::ApiRendering extend ::ActiveSupport::Concern include ::ActionController::Rendering mixes_in_class_methods ::ActionController::Rendering::ClassMethods - # source://actionpack//lib/action_controller/api/api_rendering.rb#11 + # source://actionpack//lib/action_controller/api/api_rendering.rb#13 def render_to_body(options = T.unsafe(nil)); end end -# source://actionpack//lib/action_controller/metal/exceptions.rb#7 +# source://actionpack//lib/action_controller/metal/exceptions.rb#9 class ActionController::BadRequest < ::ActionController::ActionControllerError # @return [BadRequest] a new instance of BadRequest # - # source://actionpack//lib/action_controller/metal/exceptions.rb#8 + # source://actionpack//lib/action_controller/metal/exceptions.rb#10 def initialize(msg = T.unsafe(nil)); end end -# Action Controllers are the core of a web request in \Rails. They are made up of one or more actions that are executed -# on request and then either it renders a template or redirects to another action. An action is defined as a public method -# on the controller, which will automatically be made accessible to the web-server through \Rails Routes. +# # Action Controller Base # -# By default, only the ApplicationController in a \Rails application inherits from ActionController::Base. All other -# controllers inherit from ApplicationController. This gives you one class to configure things such as +# Action Controllers are the core of a web request in Rails. They are made up of +# one or more actions that are executed on request and then either it renders a +# template or redirects to another action. An action is defined as a public +# method on the controller, which will automatically be made accessible to the +# web-server through Rails Routes. +# +# By default, only the ApplicationController in a Rails application inherits +# from `ActionController::Base`. All other controllers inherit from +# ApplicationController. This gives you one class to configure things such as # request forgery protection and filtering of sensitive request parameters. # # A sample controller could look like this: # -# class PostsController < ApplicationController -# def index -# @posts = Post.all -# end +# class PostsController < ApplicationController +# def index +# @posts = Post.all +# end # -# def create -# @post = Post.create params[:post] -# redirect_to posts_path +# def create +# @post = Post.create params[:post] +# redirect_to posts_path +# end # end -# end # -# Actions, by default, render a template in the app/views directory corresponding to the name of the controller and action -# after executing code in the action. For example, the +index+ action of the PostsController would render the -# template app/views/posts/index.html.erb by default after populating the @posts instance variable. +# Actions, by default, render a template in the `app/views` directory +# corresponding to the name of the controller and action after executing code in +# the action. For example, the `index` action of the PostsController would +# render the template `app/views/posts/index.html.erb` by default after +# populating the `@posts` instance variable. # -# Unlike index, the create action will not render a template. After performing its main purpose (creating a -# new post), it initiates a redirect instead. This redirect works by returning an external -# 302 Moved HTTP response that takes the user to the index action. +# Unlike index, the create action will not render a template. After performing +# its main purpose (creating a new post), it initiates a redirect instead. This +# redirect works by returning an external `302 Moved` HTTP response that takes +# the user to the index action. # -# These two methods represent the two basic action archetypes used in Action Controllers: Get-and-show and do-and-redirect. -# Most actions are variations on these themes. +# These two methods represent the two basic action archetypes used in Action +# Controllers: Get-and-show and do-and-redirect. Most actions are variations on +# these themes. # -# == Requests +# ## Requests # -# For every request, the router determines the value of the +controller+ and +action+ keys. These determine which controller -# and action are called. The remaining request parameters, the session (if one is available), and the full request with -# all the HTTP headers are made available to the action through accessor methods. Then the action is performed. +# For every request, the router determines the value of the `controller` and +# `action` keys. These determine which controller and action are called. The +# remaining request parameters, the session (if one is available), and the full +# request with all the HTTP headers are made available to the action through +# accessor methods. Then the action is performed. # -# The full request object is available via the request accessor and is primarily used to query for HTTP headers: +# The full request object is available via the request accessor and is primarily +# used to query for HTTP headers: # -# def server_ip -# location = request.env["REMOTE_ADDR"] -# render plain: "This server hosted at #{location}" -# end +# def server_ip +# location = request.env["REMOTE_ADDR"] +# render plain: "This server hosted at #{location}" +# end # -# == Parameters +# ## Parameters # -# All request parameters, whether they come from a query string in the URL or form data submitted through a POST request are -# available through the params method which returns a hash. For example, an action that was performed through -# /posts?category=All&limit=5 will include { "category" => "All", "limit" => "5" } in params. +# All request parameters, whether they come from a query string in the URL or +# form data submitted through a POST request are available through the `params` +# method which returns a hash. For example, an action that was performed through +# `/posts?category=All&limit=5` will include `{ "category" => "All", "limit" => +# "5" }` in `params`. # -# It's also possible to construct multi-dimensional parameter hashes by specifying keys using brackets, such as: +# It's also possible to construct multi-dimensional parameter hashes by +# specifying keys using brackets, such as: # -# -# +# +# # -# A request coming from a form holding these inputs will include { "post" => { "name" => "david", "address" => "hyacintvej" } }. -# If the address input had been named post[address][street], the params would have included -# { "post" => { "address" => { "street" => "hyacintvej" } } }. There's no limit to the depth of the nesting. +# A request coming from a form holding these inputs will include `{ "post" => { +# "name" => "david", "address" => "hyacintvej" } }`. If the address input had +# been named `post[address][street]`, the `params` would have included `{ "post" +# => { "address" => { "street" => "hyacintvej" } } }`. There's no limit to the +# depth of the nesting. # -# == Sessions +# ## Sessions # -# Sessions allow you to store objects in between requests. This is useful for objects that are not yet ready to be persisted, -# such as a Signup object constructed in a multi-paged process, or objects that don't change much and are needed all the time, such -# as a User object for a system that requires login. The session should not be used, however, as a cache for objects where it's likely -# they could be changed unknowingly. It's usually too much work to keep it all synchronized -- something databases already excel at. +# Sessions allow you to store objects in between requests. This is useful for +# objects that are not yet ready to be persisted, such as a Signup object +# constructed in a multi-paged process, or objects that don't change much and +# are needed all the time, such as a User object for a system that requires +# login. The session should not be used, however, as a cache for objects where +# it's likely they could be changed unknowingly. It's usually too much work to +# keep it all synchronized -- something databases already excel at. # -# You can place objects in the session by using the session method, which accesses a hash: +# You can place objects in the session by using the `session` method, which +# accesses a hash: # -# session[:person] = Person.authenticate(user_name, password) +# session[:person] = Person.authenticate(user_name, password) # # You can retrieve it again through the same hash: # -# "Hello #{session[:person]}" +# "Hello #{session[:person]}" # -# For removing objects from the session, you can either assign a single key to +nil+: +# For removing objects from the session, you can either assign a single key to +# `nil`: # -# # removes :person from session -# session[:person] = nil +# # removes :person from session +# session[:person] = nil # -# or you can remove the entire session with +reset_session+. +# or you can remove the entire session with `reset_session`. # # By default, sessions are stored in an encrypted browser cookie (see -# ActionDispatch::Session::CookieStore). Thus the user will not be able to -# read or edit the session data. However, the user can keep a copy of the -# cookie even after it has expired, so you should avoid storing sensitive -# information in cookie-based sessions. +# ActionDispatch::Session::CookieStore). Thus the user will not be able to read +# or edit the session data. However, the user can keep a copy of the cookie even +# after it has expired, so you should avoid storing sensitive information in +# cookie-based sessions. # -# == Responses +# ## Responses # -# Each action results in a response, which holds the headers and document to be sent to the user's browser. The actual response -# object is generated automatically through the use of renders and redirects and requires no user intervention. +# Each action results in a response, which holds the headers and document to be +# sent to the user's browser. The actual response object is generated +# automatically through the use of renders and redirects and requires no user +# intervention. # -# == Renders +# ## Renders # -# Action Controller sends content to the user by using one of five rendering methods. The most versatile and common is the rendering -# of a template. Included in the Action Pack is the Action View, which enables rendering of ERB templates. It's automatically configured. -# The controller passes objects to the view by assigning instance variables: +# Action Controller sends content to the user by using one of five rendering +# methods. The most versatile and common is the rendering of a template. +# Included in the Action Pack is the Action View, which enables rendering of ERB +# templates. It's automatically configured. The controller passes objects to the +# view by assigning instance variables: # -# def show -# @post = Post.find(params[:id]) -# end +# def show +# @post = Post.find(params[:id]) +# end # # Which are then automatically available to the view: # -# Title: <%= @post.title %> +# Title: <%= @post.title %> # -# You don't have to rely on the automated rendering. For example, actions that could result in the rendering of different templates -# will use the manual rendering methods: +# You don't have to rely on the automated rendering. For example, actions that +# could result in the rendering of different templates will use the manual +# rendering methods: # -# def search -# @results = Search.find(params[:query]) -# case @results.count -# when 0 then render action: "no_results" -# when 1 then render action: "show" -# when 2..10 then render action: "show_many" +# def search +# @results = Search.find(params[:query]) +# case @results.count +# when 0 then render action: "no_results" +# when 1 then render action: "show" +# when 2..10 then render action: "show_many" +# end # end -# end # # Read more about writing ERB and Builder templates in ActionView::Base. # -# == Redirects +# ## Redirects # -# Redirects are used to move from one action to another. For example, after a create action, which stores a blog entry to the -# database, we might like to show the user the new entry. Because we're following good DRY principles (Don't Repeat Yourself), we're -# going to reuse (and redirect to) a show action that we'll assume has already been created. The code might look like this: +# Redirects are used to move from one action to another. For example, after a +# `create` action, which stores a blog entry to the database, we might like to +# show the user the new entry. Because we're following good DRY principles +# (Don't Repeat Yourself), we're going to reuse (and redirect to) a `show` +# action that we'll assume has already been created. The code might look like +# this: # -# def create -# @entry = Entry.new(params[:entry]) -# if @entry.save -# # The entry was saved correctly, redirect to show -# redirect_to action: 'show', id: @entry.id -# else -# # things didn't go so well, do something else +# def create +# @entry = Entry.new(params[:entry]) +# if @entry.save +# # The entry was saved correctly, redirect to show +# redirect_to action: 'show', id: @entry.id +# else +# # things didn't go so well, do something else +# end # end -# end # -# In this case, after saving our new entry to the database, the user is redirected to the show method, which is then executed. -# Note that this is an external HTTP-level redirection which will cause the browser to make a second request (a GET to the show action), -# and not some internal re-routing which calls both "create" and then "show" within one request. +# In this case, after saving our new entry to the database, the user is +# redirected to the `show` method, which is then executed. Note that this is an +# external HTTP-level redirection which will cause the browser to make a second +# request (a GET to the show action), and not some internal re-routing which +# calls both "create" and then "show" within one request. # -# Learn more about redirect_to and what options you have in ActionController::Redirecting. +# Learn more about `redirect_to` and what options you have in +# ActionController::Redirecting. # -# == Calling multiple redirects or renders +# ## Calling multiple redirects or renders # -# An action may contain only a single render or a single redirect. Attempting to try to do either again will result in a DoubleRenderError: +# An action may perform only a single render or a single redirect. Attempting to +# do either again will result in a DoubleRenderError: # -# def do_something -# redirect_to action: "elsewhere" -# render action: "overthere" # raises DoubleRenderError -# end +# def do_something +# redirect_to action: "elsewhere" +# render action: "overthere" # raises DoubleRenderError +# end # -# If you need to redirect on the condition of something, then be sure to add "and return" to halt execution. +# If you need to redirect on the condition of something, then be sure to add +# "return" to halt execution. # -# def do_something -# redirect_to(action: "elsewhere") and return if monkeys.nil? -# render action: "overthere" # won't be called if monkeys is nil -# end +# def do_something +# if monkeys.nil? +# redirect_to(action: "elsewhere") +# return +# end +# render action: "overthere" # won't be called if monkeys is nil +# end # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://actionpack//lib/action_controller/base.rb#167 +# source://actionpack//lib/action_controller/base.rb#207 class ActionController::Base < ::ActionController::Metal include ::ActionView::ViewPaths include ::AbstractController::Rendering @@ -1687,6 +1875,8 @@ class ActionController::Base < ::ActionController::Metal include ::ActionController::RequestForgeryProtection include ::ActionController::ContentSecurityPolicy include ::ActionController::PermissionsPolicy + include ::ActionController::RateLimiting + include ::ActionController::AllowBrowser include ::ActionController::Streaming include ::ActionController::DataStreaming include ::ActionController::HttpAuthentication::Basic::ControllerMethods @@ -1698,8 +1888,17 @@ class ActionController::Base < ::ActionController::Metal include ::ActionController::Rescue include ::ActionController::Instrumentation include ::ActionController::ParamsWrapper + include ::Turbo::Native::Navigation + include ::Turbo::Frames::FrameRequest + include ::Turbo::Streams::TurboStreamsTagBuilder include ::ActionController::RespondWith + include ::Devise::Controllers::SignInOut + include ::Devise::Controllers::StoreLocation + include ::Devise::Controllers::Helpers + include ::Devise::Controllers::UrlHelpers + include ::Turbo::RequestIdTracking extend ::ActionView::ViewPaths::ClassMethods + extend ::AbstractController::Helpers::Resolution extend ::AbstractController::Helpers::ClassMethods extend ::ActionController::Helpers::ClassMethods extend ::AbstractController::UrlFor::ClassMethods @@ -1719,6 +1918,8 @@ class ActionController::Base < ::ActionController::Metal extend ::ActionController::RequestForgeryProtection::ClassMethods extend ::ActionController::ContentSecurityPolicy::ClassMethods extend ::ActionController::PermissionsPolicy::ClassMethods + extend ::ActionController::RateLimiting::ClassMethods + extend ::ActionController::AllowBrowser::ClassMethods extend ::ActionController::HttpAuthentication::Basic::ControllerMethods::ClassMethods extend ::ActionController::DefaultHeaders::ClassMethods extend ::ActionController::Logging::ClassMethods @@ -1727,44 +1928,51 @@ class ActionController::Base < ::ActionController::Metal extend ::ActionController::ParamsWrapper::ClassMethods extend ::Responders::ControllerMethod extend ::ActionController::RespondWith::ClassMethods + extend ::Devise::Controllers::Helpers::ClassMethods - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack//lib/abstract_controller/helpers.rb#11 + # source://actionpack//lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack//lib/abstract_controller/helpers.rb#11 + # source://actionpack//lib/abstract_controller/helpers.rb#13 def _helper_methods=(_arg0); end - # source://actionpack//lib/abstract_controller/helpers.rb#11 + # source://actionpack//lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _process_action_callbacks; end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers=(_arg0); end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_process_action_callbacks(&block); end - # source://actionpack//lib/abstract_controller/caching.rb#42 + # source://actionpack//lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack//lib/abstract_controller/caching.rb#42 + # source://actionpack//lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(_arg0); end - # source://actionpack//lib/abstract_controller/caching.rb#42 + # source://actionpack//lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 @@ -1776,295 +1984,300 @@ class ActionController::Base < ::ActionController::Metal # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://actionpack//lib/action_controller/metal/flash.rb#36 + # source://actionpack//lib/action_controller/metal/flash.rb#38 def alert; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_asset_host_protocol; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_asset_host_protocol=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_protect_from_forgery; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest; end - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest=(_arg0); end - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest?; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers=(_arg0); end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://actionpack//lib/action_controller/metal/flash.rb#10 + # source://actionpack//lib/action_controller/metal/flash.rb#12 def flash(*_arg0, **_arg1, &_arg2); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(_arg0); end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # source://actionpack//lib/action_controller/metal/helpers.rb#63 + # source://actionpack//lib/action_controller/metal/helpers.rb#70 def helpers_path; end - # source://actionpack//lib/action_controller/metal/helpers.rb#63 + # source://actionpack//lib/action_controller/metal/helpers.rb#70 def helpers_path=(_arg0); end - # source://actionpack//lib/action_controller/metal/helpers.rb#63 + # source://actionpack//lib/action_controller/metal/helpers.rb#70 def helpers_path?; end - # source://actionpack//lib/action_controller/metal/helpers.rb#64 + # source://actionpack//lib/action_controller/metal/helpers.rb#71 def include_all_helpers; end - # source://actionpack//lib/action_controller/metal/helpers.rb#64 + # source://actionpack//lib/action_controller/metal/helpers.rb#71 def include_all_helpers=(_arg0); end - # source://actionpack//lib/action_controller/metal/helpers.rb#64 + # source://actionpack//lib/action_controller/metal/helpers.rb#71 def include_all_helpers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to=(_arg0); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://actionpack//lib/action_controller/metal/flash.rb#36 + # source://actionpack//lib/action_controller/metal/flash.rb#38 def notice; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def request_forgery_protection_token; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def request_forgery_protection_token=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder=(_arg0); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def urlsafe_csrf_tokens; end - private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end - # source://actionpack//lib/action_controller/base.rb#266 + def _layout_from_proc; end + + # source://actionpack//lib/action_controller/base.rb#324 def _protected_ivars; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack//lib/action_controller/form_builder.rb#31 + # source://actionpack//lib/action_controller/form_builder.rb#35 def _default_form_builder; end - # source://actionpack//lib/action_controller/form_builder.rb#31 + # source://actionpack//lib/action_controller/form_builder.rb#35 def _default_form_builder=(value); end - # source://actionpack//lib/action_controller/form_builder.rb#31 + # source://actionpack//lib/action_controller/form_builder.rb#35 def _default_form_builder?; end - # source://actionpack//lib/action_controller/metal/flash.rb#8 + # source://actionpack//lib/action_controller/metal/flash.rb#10 def _flash_types; end - # source://actionpack//lib/action_controller/metal/flash.rb#8 + # source://actionpack//lib/action_controller/metal/flash.rb#10 def _flash_types=(value); end - # source://actionpack//lib/action_controller/metal/flash.rb#8 + # source://actionpack//lib/action_controller/metal/flash.rb#10 def _flash_types?; end - # source://actionpack//lib/abstract_controller/helpers.rb#11 + # source://actionpack//lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack//lib/abstract_controller/helpers.rb#11 + # source://actionpack//lib/abstract_controller/helpers.rb#13 def _helper_methods=(value); end - # source://actionpack//lib/abstract_controller/helpers.rb#11 + # source://actionpack//lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://actionpack//lib/abstract_controller/helpers.rb#15 + # source://actionpack//lib/abstract_controller/helpers.rb#17 def _helpers; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout=(value); end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout?; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions=(value); end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _process_action_callbacks=(value); end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers=(value); end - # source://actionpack//lib/action_controller/metal/renderers.rb#31 + # source://actionpack//lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://actionpack//lib/abstract_controller/caching.rb#42 + # source://actionpack//lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack//lib/abstract_controller/caching.rb#42 + # source://actionpack//lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(value); end - # source://actionpack//lib/abstract_controller/caching.rb#42 + # source://actionpack//lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 @@ -2076,291 +2289,319 @@ class ActionController::Base < ::ActionController::Metal # source://actionpack//lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_asset_host_protocol; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_asset_host_protocol=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_protect_from_forgery; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest; end - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest=(value); end - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest?; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers=(value); end - # source://actionpack//lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(value); end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack//lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # source://actionpack//lib/action_controller/metal/helpers.rb#63 + # source://actionpack//lib/action_controller/metal/helpers.rb#70 def helpers_path; end - # source://actionpack//lib/action_controller/metal/helpers.rb#63 + # source://actionpack//lib/action_controller/metal/helpers.rb#70 def helpers_path=(value); end - # source://actionpack//lib/action_controller/metal/helpers.rb#63 + # source://actionpack//lib/action_controller/metal/helpers.rb#70 def helpers_path?; end - # source://actionpack//lib/action_controller/metal/helpers.rb#64 + # source://actionpack//lib/action_controller/metal/helpers.rb#71 def include_all_helpers; end - # source://actionpack//lib/action_controller/metal/helpers.rb#64 + # source://actionpack//lib/action_controller/metal/helpers.rb#71 def include_all_helpers=(value); end - # source://actionpack//lib/action_controller/metal/helpers.rb#64 + # source://actionpack//lib/action_controller/metal/helpers.rb#71 def include_all_helpers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack//lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack//lib/action_controller/metal/redirecting.rb#13 + # source://actionpack//lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def request_forgery_protection_token; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def request_forgery_protection_token=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def urlsafe_csrf_tokens; end - - # source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#97 - def urlsafe_csrf_tokens=(urlsafe_csrf_tokens); end - # Shortcut helper that returns all the modules included in # ActionController::Base except the ones passed as arguments: # - # class MyBaseController < ActionController::Metal - # ActionController::Base.without_modules(:ParamsWrapper, :Streaming).each do |left| - # include left + # class MyBaseController < ActionController::Metal + # ActionController::Base.without_modules(:ParamsWrapper, :Streaming).each do |left| + # include left + # end # end - # end # - # This gives better control over what you want to exclude and makes it - # easier to create a bare controller class, instead of listing the modules - # required manually. + # This gives better control over what you want to exclude and makes it easier to + # create a bare controller class, instead of listing the modules required + # manually. # - # source://actionpack//lib/action_controller/base.rb#198 + # source://actionpack//lib/action_controller/base.rb#222 def without_modules(*modules); end end end # source://actionpack//lib/action_controller/base.rb#0 module ActionController::Base::HelperMethods - # source://actionpack//lib/action_controller/metal/flash.rb#39 - def alert(*args, **_arg1, &block); end + include ::ActionText::ContentHelper + include ::ActionText::TagHelper + include ::Turbo::DriveHelper + include ::Turbo::FramesHelper + include ::Turbo::IncludesHelper + include ::Turbo::StreamsHelper + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::Turbo::Streams::ActionHelper + include ::Importmap::ImportmapTagsHelper + + # source://actionpack//lib/action_controller/metal/flash.rb#41 + def alert(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/abstract_controller/caching/fragments.rb#34 + def combined_fragment_cache_key(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/action_controller/metal/content_security_policy.rb#13 + def content_security_policy?(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/action_controller/metal/content_security_policy.rb#14 + def content_security_policy_nonce(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/action_controller/metal/cookies.rb#10 + def cookies(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/caching/fragments.rb#31 - def combined_fragment_cache_key(*args, **_arg1, &block); end + # source://devise/4.9.4/lib/devise/controllers/helpers.rb#13 + def devise_controller?(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/content_security_policy.rb#11 - def content_security_policy?(*args, **_arg1, &block); end + # source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#102 + def form_authenticity_token(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/content_security_policy.rb#12 - def content_security_policy_nonce(*args, **_arg1, &block); end + # source://actionpack//lib/action_controller/metal/flash.rb#41 + def notice(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/cookies.rb#8 - def cookies(*args, **_arg1, &block); end + # source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#103 + def protect_against_forgery?(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#106 - def form_authenticity_token(*args, **_arg1, &block); end + # source://devise/4.9.4/lib/devise/controllers/helpers.rb#13 + def signed_in?(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/flash.rb#39 - def notice(*args, **_arg1, &block); end + def turbo_frame_request?(*_arg0, **_arg1, &_arg2); end + def turbo_frame_request_id(*_arg0, **_arg1, &_arg2); end + def turbo_native_app?(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#107 - def protect_against_forgery?(*args, **_arg1, &block); end + # source://actionpack//lib/abstract_controller/caching.rb#45 + def view_cache_dependencies(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/abstract_controller/caching.rb#43 - def view_cache_dependencies(*args, **_arg1, &block); end + # source://devise/4.9.4/lib/devise/controllers/helpers.rb#13 + def warden(*_arg0, **_arg1, &_arg2); end end -# source://actionpack//lib/action_controller/base.rb#206 +# source://actionpack//lib/action_controller/base.rb#230 ActionController::Base::MODULES = T.let(T.unsafe(nil), Array) # Define some internal variables that should not be propagated to the view. # -# source://actionpack//lib/action_controller/base.rb#261 +# source://actionpack//lib/action_controller/base.rb#318 ActionController::Base::PROTECTED_IVARS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_controller/metal/basic_implicit_render.rb#4 +# source://actionpack//lib/action_controller/metal/basic_implicit_render.rb#6 module ActionController::BasicImplicitRender - # source://actionpack//lib/action_controller/metal/basic_implicit_render.rb#11 + # source://actionpack//lib/action_controller/metal/basic_implicit_render.rb#13 def default_render; end - # source://actionpack//lib/action_controller/metal/basic_implicit_render.rb#5 + # source://actionpack//lib/action_controller/metal/basic_implicit_render.rb#7 def send_action(method, *args); end end -# \Caching is a cheap way of speeding up slow applications by keeping the result of -# calculations, renderings, and database calls around for subsequent requests. +# # Action Controller Caching +# +# Caching is a cheap way of speeding up slow applications by keeping the result +# of calculations, renderings, and database calls around for subsequent +# requests. # # You can read more about each approach by clicking the modules below. # # Note: To turn off all caching provided by Action Controller, set -# config.action_controller.perform_caching = false +# config.action_controller.perform_caching = false # -# == \Caching stores +# ## Caching stores # -# All the caching stores from ActiveSupport::Cache are available to be used as backends -# for Action Controller caching. +# All the caching stores from ActiveSupport::Cache are available to be used as +# backends for Action Controller caching. # # Configuration examples (FileStore is the default): # -# config.action_controller.cache_store = :memory_store -# config.action_controller.cache_store = :file_store, '/path/to/cache/directory' -# config.action_controller.cache_store = :mem_cache_store, 'localhost' -# config.action_controller.cache_store = :mem_cache_store, Memcached::Rails.new('localhost:11211') -# config.action_controller.cache_store = MyOwnStore.new('parameter') +# config.action_controller.cache_store = :memory_store +# config.action_controller.cache_store = :file_store, '/path/to/cache/directory' +# config.action_controller.cache_store = :mem_cache_store, 'localhost' +# config.action_controller.cache_store = :mem_cache_store, Memcached::Rails.new('localhost:11211') +# config.action_controller.cache_store = MyOwnStore.new('parameter') # -# source://actionpack//lib/action_controller/caching.rb#24 +# source://actionpack//lib/action_controller/caching.rb#29 module ActionController::Caching extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -2374,10 +2615,10 @@ module ActionController::Caching private - # source://actionpack//lib/action_controller/caching.rb#40 + # source://actionpack//lib/action_controller/caching.rb#45 def instrument_name; end - # source://actionpack//lib/action_controller/caching.rb#32 + # source://actionpack//lib/action_controller/caching.rb#37 def instrument_payload(key); end module GeneratedClassMethods @@ -2399,7 +2640,7 @@ module ActionController::Caching end end -# source://actionpack//lib/action_controller/metal/conditional_get.rb#7 +# source://actionpack//lib/action_controller/metal/conditional_get.rb#9 module ActionController::ConditionalGet include ::ActionController::Head extend ::ActiveSupport::Concern @@ -2408,258 +2649,270 @@ module ActionController::ConditionalGet mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActionController::ConditionalGet::ClassMethods - # Sets the +Cache-Control+ header, overwriting existing directives. This - # method will also ensure an HTTP +Date+ header for client compatibility. + # Sets the `Cache-Control` header, overwriting existing directives. This method + # will also ensure an HTTP `Date` header for client compatibility. + # + # Defaults to issuing the `private` directive, so that intermediate caches must + # not cache the response. # - # Defaults to issuing the +private+ directive, so that intermediate caches - # must not cache the response. + # #### Options # - # ==== Options + # `:public` + # : If true, replaces the default `private` directive with the `public` + # directive. # - # [+:public+] - # If true, replaces the default +private+ directive with the +public+ - # directive. - # [+:must_revalidate+] - # If true, adds the +must-revalidate+ directive. - # [+:stale_while_revalidate+] - # Sets the value of the +stale-while-revalidate+ directive. - # [+:stale_if_error+] - # Sets the value of the +stale-if-error+ directive. + # `:must_revalidate` + # : If true, adds the `must-revalidate` directive. # - # Any additional key-value pairs are concatenated as directives. For a list - # of supported +Cache-Control+ directives, see the {article on - # MDN}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control]. + # `:stale_while_revalidate` + # : Sets the value of the `stale-while-revalidate` directive. # - # ==== Examples + # `:stale_if_error` + # : Sets the value of the `stale-if-error` directive. # - # expires_in 10.minutes - # # => Cache-Control: max-age=600, private # - # expires_in 10.minutes, public: true - # # => Cache-Control: max-age=600, public + # Any additional key-value pairs are concatenated as directives. For a list of + # supported `Cache-Control` directives, see the [article on + # MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control). # - # expires_in 10.minutes, public: true, must_revalidate: true - # # => Cache-Control: max-age=600, public, must-revalidate + # #### Examples # - # expires_in 1.hour, stale_while_revalidate: 60.seconds - # # => Cache-Control: max-age=3600, private, stale-while-revalidate=60 + # expires_in 10.minutes + # # => Cache-Control: max-age=600, private # - # expires_in 1.hour, stale_if_error: 5.minutes - # # => Cache-Control: max-age=3600, private, stale-if-error=300 + # expires_in 10.minutes, public: true + # # => Cache-Control: max-age=600, public # - # expires_in 1.hour, public: true, "s-maxage": 3.hours, "no-transform": true - # # => Cache-Control: max-age=3600, public, s-maxage=10800, no-transform=true + # expires_in 10.minutes, public: true, must_revalidate: true + # # => Cache-Control: max-age=600, public, must-revalidate # - # source://actionpack//lib/action_controller/metal/conditional_get.rb#274 + # expires_in 1.hour, stale_while_revalidate: 60.seconds + # # => Cache-Control: max-age=3600, private, stale-while-revalidate=60 + # + # expires_in 1.hour, stale_if_error: 5.minutes + # # => Cache-Control: max-age=3600, private, stale-if-error=300 + # + # expires_in 1.hour, public: true, "s-maxage": 3.hours, "no-transform": true + # # => Cache-Control: max-age=3600, public, s-maxage=10800, no-transform=true + # + # source://actionpack//lib/action_controller/metal/conditional_get.rb#288 def expires_in(seconds, options = T.unsafe(nil)); end - # Sets an HTTP 1.1 +Cache-Control+ header of no-cache. This means the - # resource will be marked as stale, so clients must always revalidate. + # Sets an HTTP 1.1 `Cache-Control` header of `no-cache`. This means the resource + # will be marked as stale, so clients must always revalidate. # Intermediate/browser caches may still store the asset. # - # source://actionpack//lib/action_controller/metal/conditional_get.rb#292 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#306 def expires_now; end - # Sets the +etag+, +last_modified+, or both on the response, and renders a - # 304 Not Modified response if the request is already fresh. - # - # ==== Options - # - # [+:etag+] - # Sets a "weak" ETag validator on the response. See the +:weak_etag+ option. - # [+:weak_etag+] - # Sets a "weak" ETag validator on the response. Requests that specify an - # +If-None-Match+ header may receive a 304 Not Modified response - # if the ETag matches exactly. - # - # A weak ETag indicates semantic equivalence, not byte-for-byte equality, - # so they're good for caching HTML pages in browser caches. They can't be - # used for responses that must be byte-identical, like serving +Range+ - # requests within a PDF file. - # [+:strong_etag+] - # Sets a "strong" ETag validator on the response. Requests that specify an - # +If-None-Match+ header may receive a 304 Not Modified response - # if the ETag matches exactly. - # - # A strong ETag implies exact equality -- the response must match byte for - # byte. This is necessary for serving +Range+ requests within a large - # video or PDF file, for example, or for compatibility with some CDNs that - # don't support weak ETags. - # [+:last_modified+] - # Sets a "weak" last-update validator on the response. Subsequent requests - # that specify an +If-Modified-Since+ header may receive a 304 Not Modified - # response if +last_modified+ <= +If-Modified-Since+. - # [+:public+] - # By default the +Cache-Control+ header is private. Set this option to - # +true+ if you want your application to be cacheable by other devices, - # such as proxy caches. - # [+:cache_control+] - # When given, will overwrite an existing +Cache-Control+ header. For a - # list of +Cache-Control+ directives, see the {article on - # MDN}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control]. - # [+:template+] - # By default, the template digest for the current controller/action is - # included in ETags. If the action renders a different template, you can - # include its digest instead. If the action doesn't render a template at - # all, you can pass template: false to skip any attempt to check - # for a template digest. - # - # ==== Examples - # - # def show - # @article = Article.find(params[:id]) - # fresh_when(etag: @article, last_modified: @article.updated_at, public: true) - # end - # - # This will send a 304 Not Modified response if the request - # specifies a matching ETag and +If-Modified-Since+ header. Otherwise, it - # will render the +show+ template. + # Sets the `etag`, `last_modified`, or both on the response, and renders a `304 + # Not Modified` response if the request is already fresh. + # + # #### Options + # + # `:etag` + # : Sets a "weak" ETag validator on the response. See the `:weak_etag` option. + # + # `:weak_etag` + # : Sets a "weak" ETag validator on the response. Requests that specify an + # `If-None-Match` header may receive a `304 Not Modified` response if the + # ETag matches exactly. + # + # : A weak ETag indicates semantic equivalence, not byte-for-byte equality, so + # they're good for caching HTML pages in browser caches. They can't be used + # for responses that must be byte-identical, like serving `Range` requests + # within a PDF file. + # + # `:strong_etag` + # : Sets a "strong" ETag validator on the response. Requests that specify an + # `If-None-Match` header may receive a `304 Not Modified` response if the + # ETag matches exactly. + # + # : A strong ETag implies exact equality -- the response must match byte for + # byte. This is necessary for serving `Range` requests within a large video + # or PDF file, for example, or for compatibility with some CDNs that don't + # support weak ETags. + # + # `:last_modified` + # : Sets a "weak" last-update validator on the response. Subsequent requests + # that specify an `If-Modified-Since` header may receive a `304 Not + # Modified` response if `last_modified` <= `If-Modified-Since`. + # + # `:public` + # : By default the `Cache-Control` header is private. Set this option to + # `true` if you want your application to be cacheable by other devices, such + # as proxy caches. + # + # `:cache_control` + # : When given, will overwrite an existing `Cache-Control` header. For a list + # of `Cache-Control` directives, see the [article on + # MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Contr + # ol). + # + # `:template` + # : By default, the template digest for the current controller/action is + # included in ETags. If the action renders a different template, you can + # include its digest instead. If the action doesn't render a template at + # all, you can pass `template: false` to skip any attempt to check for a + # template digest. + # + # + # #### Examples + # + # def show + # @article = Article.find(params[:id]) + # fresh_when(etag: @article, last_modified: @article.updated_at, public: true) + # end + # + # This will send a `304 Not Modified` response if the request specifies a + # matching ETag and `If-Modified-Since` header. Otherwise, it will render the + # `show` template. # # You can also just pass a record: # - # def show - # @article = Article.find(params[:id]) - # fresh_when(@article) - # end + # def show + # @article = Article.find(params[:id]) + # fresh_when(@article) + # end # - # +etag+ will be set to the record, and +last_modified+ will be set to the - # record's +updated_at+. + # `etag` will be set to the record, and `last_modified` will be set to the + # record's `updated_at`. # - # You can also pass an object that responds to +maximum+, such as a - # collection of records: + # You can also pass an object that responds to `maximum`, such as a collection + # of records: # - # def index - # @articles = Article.all - # fresh_when(@articles) - # end + # def index + # @articles = Article.all + # fresh_when(@articles) + # end # - # In this case, +etag+ will be set to the collection, and +last_modified+ - # will be set to maximum(:updated_at) (the timestamp of the most - # recently updated record). + # In this case, `etag` will be set to the collection, and `last_modified` will + # be set to `maximum(:updated_at)` (the timestamp of the most recently updated + # record). # - # When passing a record or a collection, you can still specify other - # options, such as +:public+ and +:cache_control+: + # When passing a record or a collection, you can still specify other options, + # such as `:public` and `:cache_control`: # - # def show - # @article = Article.find(params[:id]) - # fresh_when(@article, public: true, cache_control: { no_cache: true }) - # end + # def show + # @article = Article.find(params[:id]) + # fresh_when(@article, public: true, cache_control: { no_cache: true }) + # end # - # The above will set Cache-Control: public, no-cache in the response. + # The above will set `Cache-Control: public, no-cache` in the response. # # When rendering a different template than the controller/action's default # template, you can indicate which digest to include in the ETag: # - # before_action { fresh_when @article, template: "widgets/show" } + # before_action { fresh_when @article, template: "widgets/show" } # - # source://actionpack//lib/action_controller/metal/conditional_get.rb#128 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#138 def fresh_when(object = T.unsafe(nil), etag: T.unsafe(nil), weak_etag: T.unsafe(nil), strong_etag: T.unsafe(nil), last_modified: T.unsafe(nil), public: T.unsafe(nil), cache_control: T.unsafe(nil), template: T.unsafe(nil)); end # Cache or yield the block. The cache is supposed to never expire. # - # You can use this method when you have an HTTP response that never changes, - # and the browser and proxies should cache it indefinitely. + # You can use this method when you have an HTTP response that never changes, and + # the browser and proxies should cache it indefinitely. # - # * +public+: By default, HTTP responses are private, cached only on the - # user's web browser. To allow proxies to cache the response, set +true+ to - # indicate that they can serve the cached response to all users. + # * `public`: By default, HTTP responses are private, cached only on the + # user's web browser. To allow proxies to cache the response, set `true` to + # indicate that they can serve the cached response to all users. # - # source://actionpack//lib/action_controller/metal/conditional_get.rb#304 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#318 def http_cache_forever(public: T.unsafe(nil)); end - # Sets an HTTP 1.1 +Cache-Control+ header of no-store. This means the - # resource may not be stored in any cache. + # Sets an HTTP 1.1 `Cache-Control` header of `no-store`. This means the resource + # may not be stored in any cache. # - # source://actionpack//lib/action_controller/metal/conditional_get.rb#314 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#328 def no_store; end - # Sets the +etag+ and/or +last_modified+ on the response and checks them - # against the request. If the request doesn't match the provided options, it - # is considered stale, and the response should be rendered from scratch. - # Otherwise, it is fresh, and a 304 Not Modified is sent. + # Sets the `etag` and/or `last_modified` on the response and checks them against + # the request. If the request doesn't match the provided options, it is + # considered stale, and the response should be rendered from scratch. Otherwise, + # it is fresh, and a `304 Not Modified` is sent. # - # ==== Options + # #### Options # # See #fresh_when for supported options. # - # ==== Examples + # #### Examples # - # def show - # @article = Article.find(params[:id]) + # def show + # @article = Article.find(params[:id]) # - # if stale?(etag: @article, last_modified: @article.updated_at) - # @statistics = @article.really_expensive_call - # respond_to do |format| - # # all the supported formats + # if stale?(etag: @article, last_modified: @article.updated_at) + # @statistics = @article.really_expensive_call + # respond_to do |format| + # # all the supported formats + # end # end # end - # end # # You can also just pass a record: # - # def show - # @article = Article.find(params[:id]) + # def show + # @article = Article.find(params[:id]) # - # if stale?(@article) - # @statistics = @article.really_expensive_call - # respond_to do |format| - # # all the supported formats + # if stale?(@article) + # @statistics = @article.really_expensive_call + # respond_to do |format| + # # all the supported formats + # end # end # end - # end # - # +etag+ will be set to the record, and +last_modified+ will be set to the - # record's +updated_at+. + # `etag` will be set to the record, and `last_modified` will be set to the + # record's `updated_at`. # - # You can also pass an object that responds to +maximum+, such as a - # collection of records: + # You can also pass an object that responds to `maximum`, such as a collection + # of records: # - # def index - # @articles = Article.all + # def index + # @articles = Article.all # - # if stale?(@articles) - # @statistics = @articles.really_expensive_call - # respond_to do |format| - # # all the supported formats + # if stale?(@articles) + # @statistics = @articles.really_expensive_call + # respond_to do |format| + # # all the supported formats + # end # end # end - # end # - # In this case, +etag+ will be set to the collection, and +last_modified+ - # will be set to maximum(:updated_at) (the timestamp of the most - # recently updated record). + # In this case, `etag` will be set to the collection, and `last_modified` will + # be set to `maximum(:updated_at)` (the timestamp of the most recently updated + # record). # - # When passing a record or a collection, you can still specify other - # options, such as +:public+ and +:cache_control+: + # When passing a record or a collection, you can still specify other options, + # such as `:public` and `:cache_control`: # - # def show - # @article = Article.find(params[:id]) + # def show + # @article = Article.find(params[:id]) # - # if stale?(@article, public: true, cache_control: { no_cache: true }) - # @statistics = @articles.really_expensive_call - # respond_to do |format| - # # all the supported formats + # if stale?(@article, public: true, cache_control: { no_cache: true }) + # @statistics = @articles.really_expensive_call + # respond_to do |format| + # # all the supported formats + # end # end # end - # end # - # The above will set Cache-Control: public, no-cache in the response. + # The above will set `Cache-Control: public, no-cache` in the response. # # When rendering a different template than the controller/action's default # template, you can indicate which digest to include in the ETag: # - # def show - # super if stale?(@article, template: "widgets/show") - # end + # def show + # super if stale?(@article, template: "widgets/show") + # end # # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/conditional_get.rb#227 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#237 def stale?(object = T.unsafe(nil), **freshness_kwargs); end private - # source://actionpack//lib/action_controller/metal/conditional_get.rb#319 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#333 def combine_etags(validator, options); end module GeneratedClassMethods @@ -2675,28 +2928,28 @@ module ActionController::ConditionalGet end end -# source://actionpack//lib/action_controller/metal/conditional_get.rb#16 +# source://actionpack//lib/action_controller/metal/conditional_get.rb#18 module ActionController::ConditionalGet::ClassMethods - # Allows you to consider additional controller-wide information when generating an ETag. - # For example, if you serve pages tailored depending on who's logged in at the moment, you - # may want to add the current user id to be part of the ETag to prevent unauthorized displaying - # of cached pages. - # - # class InvoicesController < ApplicationController - # etag { current_user&.id } - # - # def show - # # Etag will differ even for the same invoice when it's viewed by a different current_user - # @invoice = Invoice.find(params[:id]) - # fresh_when etag: @invoice + # Allows you to consider additional controller-wide information when generating + # an ETag. For example, if you serve pages tailored depending on who's logged in + # at the moment, you may want to add the current user id to be part of the ETag + # to prevent unauthorized displaying of cached pages. + # + # class InvoicesController < ApplicationController + # etag { current_user&.id } + # + # def show + # # Etag will differ even for the same invoice when it's viewed by a different current_user + # @invoice = Invoice.find(params[:id]) + # fresh_when etag: @invoice + # end # end - # end # - # source://actionpack//lib/action_controller/metal/conditional_get.rb#31 + # source://actionpack//lib/action_controller/metal/conditional_get.rb#33 def etag(&etagger); end end -# source://actionpack//lib/action_controller/metal/content_security_policy.rb#4 +# source://actionpack//lib/action_controller/metal/content_security_policy.rb#6 module ActionController::ContentSecurityPolicy extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -2715,13 +2968,13 @@ module ActionController::ContentSecurityPolicy # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/content_security_policy.rb#73 + # source://actionpack//lib/action_controller/metal/content_security_policy.rb#74 def content_security_policy?; end - # source://actionpack//lib/action_controller/metal/content_security_policy.rb#77 + # source://actionpack//lib/action_controller/metal/content_security_policy.rb#78 def content_security_policy_nonce; end - # source://actionpack//lib/action_controller/metal/content_security_policy.rb#81 + # source://actionpack//lib/action_controller/metal/content_security_policy.rb#82 def current_content_security_policy; end module GeneratedClassMethods @@ -2742,69 +2995,70 @@ module ActionController::ContentSecurityPolicy end end -# source://actionpack//lib/action_controller/metal/content_security_policy.rb#15 +# source://actionpack//lib/action_controller/metal/content_security_policy.rb#17 module ActionController::ContentSecurityPolicy::ClassMethods - # Overrides parts of the globally configured +Content-Security-Policy+ - # header: + # Overrides parts of the globally configured `Content-Security-Policy` header: # - # class PostsController < ApplicationController - # content_security_policy do |policy| - # policy.base_uri "https://www.example.com" + # class PostsController < ApplicationController + # content_security_policy do |policy| + # policy.base_uri "https://www.example.com" + # end # end - # end # - # Options can be passed similar to +before_action+. For example, pass - # only: :index to override the header on the index action only: + # Options can be passed similar to `before_action`. For example, pass `only: + # :index` to override the header on the index action only: # - # class PostsController < ApplicationController - # content_security_policy(only: :index) do |policy| - # policy.default_src :self, :https + # class PostsController < ApplicationController + # content_security_policy(only: :index) do |policy| + # policy.default_src :self, :https + # end # end - # end # - # Pass +false+ to remove the +Content-Security-Policy+ header: + # Pass `false` to remove the `Content-Security-Policy` header: # - # class PostsController < ApplicationController - # content_security_policy false, only: :index - # end + # class PostsController < ApplicationController + # content_security_policy false, only: :index + # end # - # source://actionpack//lib/action_controller/metal/content_security_policy.rb#39 + # source://actionpack//lib/action_controller/metal/content_security_policy.rb#40 def content_security_policy(enabled = T.unsafe(nil), **options, &block); end - # Overrides the globally configured +Content-Security-Policy-Report-Only+ + # Overrides the globally configured `Content-Security-Policy-Report-Only` # header: # - # class PostsController < ApplicationController - # content_security_policy_report_only only: :index - # end + # class PostsController < ApplicationController + # content_security_policy_report_only only: :index + # end # - # Pass +false+ to remove the +Content-Security-Policy-Report-Only+ header: + # Pass `false` to remove the `Content-Security-Policy-Report-Only` header: # - # class PostsController < ApplicationController - # content_security_policy_report_only false, only: :index - # end + # class PostsController < ApplicationController + # content_security_policy_report_only false, only: :index + # end # - # source://actionpack//lib/action_controller/metal/content_security_policy.rb#65 + # source://actionpack//lib/action_controller/metal/content_security_policy.rb#66 def content_security_policy_report_only(report_only = T.unsafe(nil), **options); end end -# source://actionpack//lib/action_controller/metal/cookies.rb#4 +# source://actionpack//lib/action_controller/metal/cookies.rb#6 module ActionController::Cookies extend ::ActiveSupport::Concern private - # The cookies for the current request. See ActionDispatch::Cookies for - # more information. + # The cookies for the current request. See ActionDispatch::Cookies for more + # information. # - # source://actionpack//lib/action_controller/metal/cookies.rb#14 + # source://actionpack//lib/action_controller/metal/cookies.rb#16 def cookies; end end +# # Action Controller Data Streaming +# # Methods for sending arbitrary data and for streaming files to the browser, # instead of rendering. # -# source://actionpack//lib/action_controller/metal/data_streaming.rb#9 +# source://actionpack//lib/action_controller/metal/data_streaming.rb#13 module ActionController::DataStreaming extend ::ActiveSupport::Concern include ::ActionController::Rendering @@ -2813,131 +3067,142 @@ module ActionController::DataStreaming private - # Sends the given binary data to the browser. This method is similar to - # render plain: data, but also allows you to specify whether - # the browser should display the response as a file attachment (i.e. in a - # download dialog) or as inline data. You may also set the content type, - # the file name, and other things. + # Sends the given binary data to the browser. This method is similar to `render + # plain: data`, but also allows you to specify whether the browser should + # display the response as a file attachment (i.e. in a download dialog) or as + # inline data. You may also set the content type, the file name, and other + # things. # # Options: - # * :filename - suggests a filename for the browser to use. - # * :type - specifies an HTTP content type. Defaults to +application/octet-stream+. - # You can specify either a string or a symbol for a registered type with Mime::Type.register, for example +:json+. - # If omitted, type will be inferred from the file extension specified in :filename. - # If no content type is registered for the extension, the default type +application/octet-stream+ will be used. - # * :disposition - specifies whether the file will be shown inline or downloaded. - # Valid values are "inline" and "attachment" (default). - # * :status - specifies the status code to send with the response. Defaults to 200. + # * `:filename` - suggests a filename for the browser to use. + # * `:type` - specifies an HTTP content type. Defaults to + # `application/octet-stream`. You can specify either a string or a symbol + # for a registered type with `Mime::Type.register`, for example `:json`. If + # omitted, type will be inferred from the file extension specified in + # `:filename`. If no content type is registered for the extension, the + # default type `application/octet-stream` will be used. + # * `:disposition` - specifies whether the file will be shown inline or + # downloaded. Valid values are `"inline"` and `"attachment"` (default). + # * `:status` - specifies the status code to send with the response. Defaults + # to 200. + # # # Generic data download: # - # send_data buffer + # send_data buffer # # Download a dynamically-generated tarball: # - # send_data generate_tgz('dir'), filename: 'dir.tgz' + # send_data generate_tgz('dir'), filename: 'dir.tgz' # # Display an image Active Record in the browser: # - # send_data image.data, type: image.content_type, disposition: 'inline' + # send_data image.data, type: image.content_type, disposition: 'inline' # - # See +send_file+ for more information on HTTP Content-* headers and caching. + # See `send_file` for more information on HTTP `Content-*` headers and caching. # - # source://actionpack//lib/action_controller/metal/data_streaming.rb#109 + # source://actionpack//lib/action_controller/metal/data_streaming.rb#120 def send_data(data, options = T.unsafe(nil)); end - # Sends the file. This uses a server-appropriate method (such as +X-Sendfile+) - # via the +Rack::Sendfile+ middleware. The header to use is set via - # +config.action_dispatch.x_sendfile_header+. - # Your server can also configure this for you by setting the +X-Sendfile-Type+ header. + # Sends the file. This uses a server-appropriate method (such as `X-Sendfile`) + # via the `Rack::Sendfile` middleware. The header to use is set via + # `config.action_dispatch.x_sendfile_header`. Your server can also configure + # this for you by setting the `X-Sendfile-Type` header. # - # Be careful to sanitize the path parameter if it is coming from a web - # page. send_file(params[:path]) allows a malicious user to - # download any file on your server. + # Be careful to sanitize the path parameter if it is coming from a web page. + # `send_file(params[:path])` allows a malicious user to download any file on + # your server. # # Options: - # * :filename - suggests a filename for the browser to use. - # Defaults to File.basename(path). - # * :type - specifies an HTTP content type. - # You can specify either a string or a symbol for a registered type with Mime::Type.register, for example +:json+. - # If omitted, the type will be inferred from the file extension specified in :filename. - # If no content type is registered for the extension, the default type +application/octet-stream+ will be used. - # * :disposition - specifies whether the file will be shown inline or downloaded. - # Valid values are "inline" and "attachment" (default). - # * :status - specifies the status code to send with the response. Defaults to 200. - # * :url_based_filename - set to +true+ if you want the browser to guess the filename from - # the URL, which is necessary for i18n filenames on certain browsers - # (setting :filename overrides this option). - # - # The default +Content-Type+ and +Content-Disposition+ headers are - # set to download arbitrary binary files in as many browsers as - # possible. IE versions 4, 5, 5.5, and 6 are all known to have - # a variety of quirks (especially when downloading over SSL). + # * `:filename` - suggests a filename for the browser to use. Defaults to + # `File.basename(path)`. + # * `:type` - specifies an HTTP content type. You can specify either a string + # or a symbol for a registered type with `Mime::Type.register`, for example + # `:json`. If omitted, the type will be inferred from the file extension + # specified in `:filename`. If no content type is registered for the + # extension, the default type `application/octet-stream` will be used. + # * `:disposition` - specifies whether the file will be shown inline or + # downloaded. Valid values are `"inline"` and `"attachment"` (default). + # * `:status` - specifies the status code to send with the response. Defaults + # to 200. + # * `:url_based_filename` - set to `true` if you want the browser to guess the + # filename from the URL, which is necessary for i18n filenames on certain + # browsers (setting `:filename` overrides this option). + # + # + # The default `Content-Type` and `Content-Disposition` headers are set to + # download arbitrary binary files in as many browsers as possible. IE versions + # 4, 5, 5.5, and 6 are all known to have a variety of quirks (especially when + # downloading over SSL). # # Simple download: # - # send_file '/path/to.zip' + # send_file '/path/to.zip' # # Show a JPEG in the browser: # - # send_file '/path/to.jpeg', type: 'image/jpeg', disposition: 'inline' + # send_file '/path/to.jpeg', type: 'image/jpeg', disposition: 'inline' # # Show a 404 page in the browser: # - # send_file '/path/to/404.html', type: 'text/html; charset=utf-8', disposition: 'inline', status: 404 + # send_file '/path/to/404.html', type: 'text/html; charset=utf-8', disposition: 'inline', status: 404 # - # You can use other Content-* HTTP headers to provide additional - # information to the client. See MDN for a - # {list of HTTP headers}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers]. + # You can use other `Content-*` HTTP headers to provide additional information + # to the client. See MDN for a [list of HTTP + # headers](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers). # - # Also be aware that the document may be cached by proxies and browsers. - # The +Pragma+ and +Cache-Control+ headers declare how the file may be cached - # by intermediaries. They default to require clients to validate with - # the server before releasing cached responses. See - # https://www.mnot.net/cache_docs/ for an overview of web caching and - # {RFC 9111}[https://www.rfc-editor.org/rfc/rfc9111.html#name-cache-control] - # for the +Cache-Control+ header spec. + # Also be aware that the document may be cached by proxies and browsers. The + # `Pragma` and `Cache-Control` headers declare how the file may be cached by + # intermediaries. They default to require clients to validate with the server + # before releasing cached responses. See https://www.mnot.net/cache_docs/ for an + # overview of web caching and [RFC + # 9111](https://www.rfc-editor.org/rfc/rfc9111.html#name-cache-control) for the + # `Cache-Control` header spec. # # @raise [MissingFile] # - # source://actionpack//lib/action_controller/metal/data_streaming.rb#69 + # source://actionpack//lib/action_controller/metal/data_streaming.rb#76 def send_file(path, options = T.unsafe(nil)); end # @raise [ArgumentError] # - # source://actionpack//lib/action_controller/metal/data_streaming.rb#114 + # source://actionpack//lib/action_controller/metal/data_streaming.rb#125 def send_file_headers!(options); end end -# source://actionpack//lib/action_controller/metal/data_streaming.rb#15 +# source://actionpack//lib/action_controller/metal/data_streaming.rb#19 ActionController::DataStreaming::DEFAULT_SEND_FILE_DISPOSITION = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_controller/metal/data_streaming.rb#14 +# source://actionpack//lib/action_controller/metal/data_streaming.rb#18 ActionController::DataStreaming::DEFAULT_SEND_FILE_TYPE = T.let(T.unsafe(nil), String) -# Allows configuring default headers that will be automatically merged into -# each response. +# # Action Controller Default Headers # -# source://actionpack//lib/action_controller/metal/default_headers.rb#6 +# Allows configuring default headers that will be automatically merged into each +# response. +# +# source://actionpack//lib/action_controller/metal/default_headers.rb#10 module ActionController::DefaultHeaders extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionController::DefaultHeaders::ClassMethods end -# source://actionpack//lib/action_controller/metal/default_headers.rb#9 +# source://actionpack//lib/action_controller/metal/default_headers.rb#13 module ActionController::DefaultHeaders::ClassMethods - # source://actionpack//lib/action_controller/metal/default_headers.rb#10 + # source://actionpack//lib/action_controller/metal/default_headers.rb#14 def make_response!(request); end end +# # Action Controller Etag With Flash +# # When you're using the flash, it's generally used as a conditional on the view. # This means the content of the view depends on the flash. Which in turn means # that the ETag for a response should be computed with the content of the flash # in mind. This does that by including the content of the flash as a component # in the ETag that's generated for a response. # -# source://actionpack//lib/action_controller/metal/etag_with_flash.rb#9 +# source://actionpack//lib/action_controller/metal/etag_with_flash.rb#13 module ActionController::EtagWithFlash extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -2959,24 +3224,26 @@ module ActionController::EtagWithFlash end end -# When our views change, they should bubble up into HTTP cache freshness -# and bust browser caches. So the template digest for the current action -# is automatically included in the ETag. +# # Action Controller Etag With Template Digest +# +# When our views change, they should bubble up into HTTP cache freshness and +# bust browser caches. So the template digest for the current action is +# automatically included in the ETag. # # Enabled by default for apps that use Action View. Disable by setting # -# config.action_controller.etag_with_template_digest = false +# config.action_controller.etag_with_template_digest = false # -# Override the template to digest by passing +:template+ to +fresh_when+ -# and +stale?+ calls. For example: +# Override the template to digest by passing `:template` to `fresh_when` and +# `stale?` calls. For example: # -# # We're going to render widgets/show, not posts/show -# fresh_when @post, template: 'widgets/show' +# # We're going to render widgets/show, not posts/show +# fresh_when @post, template: 'widgets/show' # -# # We're not going to render a template, so omit it from the ETag. -# fresh_when @post, template: false +# # We're not going to render a template, so omit it from the ETag. +# fresh_when @post, template: false # -# source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#21 +# source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#25 module ActionController::EtagWithTemplateDigest extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -2987,18 +3254,18 @@ module ActionController::EtagWithTemplateDigest private - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#35 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#39 def determine_template_etag(options); end - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#51 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#55 def lookup_and_digest_template(template); end - # Pick the template digest to include in the ETag. If the +:template+ option - # is present, use the named template. If +:template+ is +nil+ or absent, use - # the default controller/action template. If +:template+ is false, omit the - # template digest from the ETag. + # Pick the template digest to include in the ETag. If the `:template` option is + # present, use the named template. If `:template` is `nil` or absent, use the + # default controller/action template. If `:template` is false, omit the template + # digest from the ETag. # - # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#45 + # source://actionpack//lib/action_controller/metal/etag_with_template_digest.rb#49 def pick_template_for_etag(options); end module GeneratedClassMethods @@ -3020,7 +3287,7 @@ module ActionController::EtagWithTemplateDigest end end -# source://actionpack//lib/action_controller/metal/flash.rb#4 +# source://actionpack//lib/action_controller/metal/flash.rb#6 module ActionController::Flash extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -3030,7 +3297,7 @@ module ActionController::Flash private - # source://actionpack//lib/action_controller/metal/flash.rb#51 + # source://actionpack//lib/action_controller/metal/flash.rb#53 def redirect_to(options = T.unsafe(nil), response_options_and_flash = T.unsafe(nil)); end module GeneratedClassMethods @@ -3042,58 +3309,60 @@ module ActionController::Flash module GeneratedInstanceMethods; end end -# source://actionpack//lib/action_controller/metal/flash.rb#14 +# source://actionpack//lib/action_controller/metal/flash.rb#16 module ActionController::Flash::ClassMethods - # source://actionpack//lib/action_controller/metal/flash.rb#45 + # source://actionpack//lib/action_controller/metal/flash.rb#47 def action_methods; end # Creates new flash types. You can pass as many types as you want to create - # flash types other than the default alert and notice in - # your controllers and views. For instance: + # flash types other than the default `alert` and `notice` in your controllers + # and views. For instance: # - # # in application_controller.rb - # class ApplicationController < ActionController::Base - # add_flash_types :warning - # end + # # in application_controller.rb + # class ApplicationController < ActionController::Base + # add_flash_types :warning + # end # - # # in your controller - # redirect_to user_path(@user), warning: "Incomplete profile" + # # in your controller + # redirect_to user_path(@user), warning: "Incomplete profile" # - # # in your view - # <%= warning %> + # # in your view + # <%= warning %> # # This method will automatically define a new method for each of the given # names, and it will be available in your views. # - # source://actionpack//lib/action_controller/metal/flash.rb#32 + # source://actionpack//lib/action_controller/metal/flash.rb#34 def add_flash_types(*types); end end -# Override the default form builder for all views rendered by this -# controller and any of its descendants. Accepts a subclass of +# # Action Controller Form Builder +# +# Override the default form builder for all views rendered by this controller +# and any of its descendants. Accepts a subclass of # ActionView::Helpers::FormBuilder. # # For example, given a form builder: # -# class AdminFormBuilder < ActionView::Helpers::FormBuilder -# def special_field(name) +# class AdminFormBuilder < ActionView::Helpers::FormBuilder +# def special_field(name) +# end # end -# end # # The controller specifies a form builder as its default: # -# class AdminAreaController < ApplicationController -# default_form_builder AdminFormBuilder -# end +# class AdminAreaController < ApplicationController +# default_form_builder AdminFormBuilder +# end # -# Then in the view any form using +form_for+ will be an instance of the +# Then in the view any form using `form_for` will be an instance of the # specified form builder: # -# <%= form_for(@instance) do |builder| %> -# <%= builder.special_field(:name) %> -# <% end %> +# <%= form_for(@instance) do |builder| %> +# <%= builder.special_field(:name) %> +# <% end %> # -# source://actionpack//lib/action_controller/form_builder.rb#27 +# source://actionpack//lib/action_controller/form_builder.rb#31 module ActionController::FormBuilder extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -3103,7 +3372,7 @@ module ActionController::FormBuilder # Default form builder for the controller # - # source://actionpack//lib/action_controller/form_builder.rb#46 + # source://actionpack//lib/action_controller/form_builder.rb#51 def default_form_builder; end module GeneratedClassMethods @@ -3115,101 +3384,107 @@ module ActionController::FormBuilder module GeneratedInstanceMethods; end end -# source://actionpack//lib/action_controller/form_builder.rb#34 +# source://actionpack//lib/action_controller/form_builder.rb#38 module ActionController::FormBuilder::ClassMethods - # Set the form builder to be used as the default for all forms - # in the views rendered by this controller and its subclasses. + # Set the form builder to be used as the default for all forms in the views + # rendered by this controller and its subclasses. # - # ==== Parameters - # * builder - Default form builder, an instance of ActionView::Helpers::FormBuilder + # #### Parameters + # * `builder` - Default form builder, an instance of + # ActionView::Helpers::FormBuilder # - # source://actionpack//lib/action_controller/form_builder.rb#40 + # source://actionpack//lib/action_controller/form_builder.rb#45 def default_form_builder(builder); end end -# source://actionpack//lib/action_controller/metal/head.rb#4 +# source://actionpack//lib/action_controller/metal/head.rb#6 module ActionController::Head - # Returns a response that has no content (merely headers). The options - # argument is interpreted to be a hash of header names and values. - # This allows you to easily return a response that consists only of - # significant headers: + # Returns a response that has no content (merely headers). The options argument + # is interpreted to be a hash of header names and values. This allows you to + # easily return a response that consists only of significant headers: # - # head :created, location: person_path(@person) + # head :created, location: person_path(@person) # - # head :created, location: @person + # head :created, location: @person # # It can also be used to return exceptional conditions: # - # return head(:method_not_allowed) unless request.post? - # return head(:bad_request) unless valid_request? - # render + # return head(:method_not_allowed) unless request.post? + # return head(:bad_request) unless valid_request? + # render # - # See +Rack::Utils::SYMBOL_TO_STATUS_CODE+ for a full list of valid +status+ symbols. + # See `Rack::Utils::SYMBOL_TO_STATUS_CODE` for a full list of valid `status` + # symbols. # - # source://actionpack//lib/action_controller/metal/head.rb#21 + # source://actionpack//lib/action_controller/metal/head.rb#23 def head(status, options = T.unsafe(nil)); end private # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/head.rb#52 + # source://actionpack//lib/action_controller/metal/head.rb#56 def include_content?(status); end end -# The \Rails framework provides a large number of helpers for working with assets, dates, forms, -# numbers and model objects, to name a few. These helpers are available to all templates -# by default. +# # Action Controller Helpers +# +# The Rails framework provides a large number of helpers for working with +# assets, dates, forms, numbers and model objects, to name a few. These helpers +# are available to all templates by default. # -# In addition to using the standard template helpers provided, creating custom helpers to -# extract complicated logic or reusable functionality is strongly encouraged. By default, each controller -# will include all helpers. These helpers are only accessible on the controller through #helpers +# In addition to using the standard template helpers provided, creating custom +# helpers to extract complicated logic or reusable functionality is strongly +# encouraged. By default, each controller will include all helpers. These +# helpers are only accessible on the controller through `#helpers` # -# In previous versions of \Rails the controller will include a helper which -# matches the name of the controller, e.g., MyController will automatically -# include MyHelper. You can revert to the old behavior with the following: +# In previous versions of Rails the controller will include a helper which +# matches the name of the controller, e.g., `MyController` will automatically +# include `MyHelper`. You can revert to the old behavior with the following: # -# # config/application.rb -# class Application < Rails::Application -# config.action_controller.include_all_helpers = false -# end +# # config/application.rb +# class Application < Rails::Application +# config.action_controller.include_all_helpers = false +# end # -# Additional helpers can be specified using the +helper+ class method in ActionController::Base or any -# controller which inherits from it. +# Additional helpers can be specified using the `helper` class method in +# ActionController::Base or any controller which inherits from it. # -# The +to_s+ method from the \Time class can be wrapped in a helper method to display a custom message if -# a \Time object is blank: +# The `to_s` method from the Time class can be wrapped in a helper method to +# display a custom message if a Time object is blank: # -# module FormattedTimeHelper -# def format_time(time, format=:long, blank_message=" ") -# time.blank? ? blank_message : time.to_fs(format) +# module FormattedTimeHelper +# def format_time(time, format=:long, blank_message=" ") +# time.blank? ? blank_message : time.to_fs(format) +# end # end -# end # -# FormattedTimeHelper can now be included in a controller, using the +helper+ class method: +# FormattedTimeHelper can now be included in a controller, using the `helper` +# class method: # -# class EventsController < ActionController::Base -# helper FormattedTimeHelper -# def index -# @events = Event.all +# class EventsController < ActionController::Base +# helper FormattedTimeHelper +# def index +# @events = Event.all +# end # end -# end # -# Then, in any view rendered by EventsController, the format_time method can be called: +# Then, in any view rendered by `EventsController`, the `format_time` method can +# be called: # -# <% @events.each do |event| -%> -#

-# <%= format_time(event.time, :short, "N/A") %> | <%= event.name %> -#

-# <% end -%> +# <% @events.each do |event| -%> +#

+# <%= format_time(event.time, :short, "N/A") %> | <%= event.name %> +#

+# <% end -%> # -# Finally, assuming we have two event instances, one which has a time and one which does not, -# the output might look like this: +# Finally, assuming we have two event instances, one which has a time and one +# which does not, the output might look like this: # -# 23 Aug 11:30 | Carolina Railhawks Soccer Match -# N/A | Carolina Railhawks Training Workshop +# 23 Aug 11:30 | Carolina Railhawks Soccer Match +# N/A | Carolina Railhawks Training Workshop # -# source://actionpack//lib/action_controller/metal/helpers.rb#56 +# source://actionpack//lib/action_controller/metal/helpers.rb#63 module ActionController::Helpers extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -3221,20 +3496,20 @@ module ActionController::Helpers # Provides a proxy to access helper methods from outside the view. # - # source://actionpack//lib/action_controller/metal/helpers.rb#128 + # source://actionpack//lib/action_controller/metal/helpers.rb#125 def helpers; end class << self # Returns the value of attribute helpers_path. # - # source://actionpack//lib/action_controller/metal/helpers.rb#59 + # source://actionpack//lib/action_controller/metal/helpers.rb#66 def helpers_path; end # Sets the attribute helpers_path # # @param value the value to set the attribute helpers_path to. # - # source://actionpack//lib/action_controller/metal/helpers.rb#59 + # source://actionpack//lib/action_controller/metal/helpers.rb#66 def helpers_path=(_arg0); end end @@ -3263,586 +3538,594 @@ module ActionController::Helpers end end -# source://actionpack//lib/action_controller/metal/helpers.rb#67 +# source://actionpack//lib/action_controller/metal/helpers.rb#74 module ActionController::Helpers::ClassMethods - # Returns a list of helper names in a given path. - # - # ActionController::Base.all_helpers_from_path 'app/helpers' - # # => ["application", "chart", "rubygems"] - # - # source://actionpack//lib/action_controller/metal/helpers.rb#111 - def all_helpers_from_path(path); end - # Declares helper accessors for controller attributes. For example, the - # following adds new +name+ and name= instance methods to a - # controller and makes them available to the view: - # attr_accessor :name - # helper_attr :name + # following adds new `name` and `name=` instance methods to a controller and + # makes them available to the view: + # attr_accessor :name + # helper_attr :name # - # ==== Parameters - # * attrs - Names of attributes to be converted into helpers. + # #### Parameters + # * `attrs` - Names of attributes to be converted into helpers. # - # source://actionpack//lib/action_controller/metal/helpers.rb#76 + # source://actionpack//lib/action_controller/metal/helpers.rb#84 def helper_attr(*attrs); end # Provides a proxy to access helper methods from outside the view. # - # Note that the proxy is rendered under a different view context. - # This may cause incorrect behaviour with capture methods. Consider - # using {helper}[rdoc-ref:AbstractController::Helpers::ClassMethods#helper] - # instead when using +capture+. + # Note that the proxy is rendered under a different view context. This may cause + # incorrect behavior with capture methods. Consider using + # [helper](rdoc-ref:AbstractController::Helpers::ClassMethods#helper) instead + # when using `capture`. # - # source://actionpack//lib/action_controller/metal/helpers.rb#86 + # source://actionpack//lib/action_controller/metal/helpers.rb#94 def helpers; end - # Override modules_for_helpers to accept +:all+ as argument, which loads - # all helpers in helpers_path. + # Override modules_for_helpers to accept `:all` as argument, which loads all + # helpers in helpers_path. + # + # #### Parameters + # * `args` - A list of helpers # - # ==== Parameters - # * args - A list of helpers # - # ==== Returns - # * array - A normalized list of modules for the list of helpers provided. + # #### Returns + # * `array` - A normalized list of modules for the list of helpers provided. # - # source://actionpack//lib/action_controller/metal/helpers.rb#102 + # source://actionpack//lib/action_controller/metal/helpers.rb#112 def modules_for_helpers(args); end private - # Extract helper names from files in app/helpers/**/*_helper.rb + # Extract helper names from files in `app/helpers/***/**_helper.rb` # - # source://actionpack//lib/action_controller/metal/helpers.rb#122 + # source://actionpack//lib/action_controller/metal/helpers.rb#119 def all_application_helpers; end end # HTTP Basic, Digest, and Token authentication. # -# source://actionpack//lib/action_controller/metal/http_authentication.rb#9 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#11 module ActionController::HttpAuthentication; end -# = HTTP \Basic authentication +# # HTTP Basic authentication # -# === Simple \Basic example +# ### Simple Basic example # -# class PostsController < ApplicationController -# http_basic_authenticate_with name: "dhh", password: "secret", except: :index +# class PostsController < ApplicationController +# http_basic_authenticate_with name: "dhh", password: "secret", except: :index # -# def index -# render plain: "Everyone can see me!" -# end +# def index +# render plain: "Everyone can see me!" +# end # -# def edit -# render plain: "I'm only accessible if you know the password" +# def edit +# render plain: "I'm only accessible if you know the password" +# end # end -# end # -# === Advanced \Basic example +# ### Advanced Basic example # -# Here is a more advanced \Basic example where only Atom feeds and the XML API are protected by HTTP authentication. -# The regular HTML interface is protected by a session approach: +# Here is a more advanced Basic example where only Atom feeds and the XML API +# are protected by HTTP authentication. The regular HTML interface is protected +# by a session approach: # -# class ApplicationController < ActionController::Base -# before_action :set_account, :authenticate +# class ApplicationController < ActionController::Base +# before_action :set_account, :authenticate # -# private -# def set_account -# @account = Account.find_by(url_name: request.subdomains.first) -# end +# private +# def set_account +# @account = Account.find_by(url_name: request.subdomains.first) +# end # -# def authenticate -# case request.format -# when Mime[:xml], Mime[:atom] -# if user = authenticate_with_http_basic { |u, p| @account.users.authenticate(u, p) } -# @current_user = user -# else -# request_http_basic_authentication -# end -# else -# if session_authenticated? -# @current_user = @account.users.find(session[:authenticated][:user_id]) +# def authenticate +# case request.format +# when Mime[:xml], Mime[:atom] +# if user = authenticate_with_http_basic { |u, p| @account.users.authenticate(u, p) } +# @current_user = user +# else +# request_http_basic_authentication +# end # else -# redirect_to(login_url) and return false +# if session_authenticated? +# @current_user = @account.users.find(session[:authenticated][:user_id]) +# else +# redirect_to(login_url) and return false +# end # end # end -# end -# end +# end # # In your integration tests, you can do something like this: # -# def test_access_granted_from_xml -# authorization = ActionController::HttpAuthentication::Basic.encode_credentials(users(:dhh).name, users(:dhh).password) +# def test_access_granted_from_xml +# authorization = ActionController::HttpAuthentication::Basic.encode_credentials(users(:dhh).name, users(:dhh).password) # -# get "/notes/1.xml", headers: { 'HTTP_AUTHORIZATION' => authorization } +# get "/notes/1.xml", headers: { 'HTTP_AUTHORIZATION' => authorization } # -# assert_equal 200, status -# end +# assert_equal 200, status +# end # -# source://actionpack//lib/action_controller/metal/http_authentication.rb#66 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#69 module ActionController::HttpAuthentication::Basic extend ::ActionController::HttpAuthentication::Basic - # source://actionpack//lib/action_controller/metal/http_authentication.rb#127 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#130 def auth_param(request); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#123 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#126 def auth_scheme(request); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#105 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#108 def authenticate(request, &login_procedure); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#135 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#138 def authentication_request(controller, realm, message); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#119 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#122 def decode_credentials(request); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#131 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#134 def encode_credentials(user_name, password); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#111 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#114 def has_basic_credentials?(request); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#115 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#118 def user_name_and_password(request); end end -# source://actionpack//lib/action_controller/metal/http_authentication.rb#69 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#72 module ActionController::HttpAuthentication::Basic::ControllerMethods extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionController::HttpAuthentication::Basic::ControllerMethods::ClassMethods - # source://actionpack//lib/action_controller/metal/http_authentication.rb#92 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#95 def authenticate_or_request_with_http_basic(realm = T.unsafe(nil), message = T.unsafe(nil), &login_procedure); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#96 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#99 def authenticate_with_http_basic(&login_procedure); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#83 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#86 def http_basic_authenticate_or_request_with(name:, password:, realm: T.unsafe(nil), message: T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#100 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#103 def request_http_basic_authentication(realm = T.unsafe(nil), message = T.unsafe(nil)); end end -# source://actionpack//lib/action_controller/metal/http_authentication.rb#72 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#75 module ActionController::HttpAuthentication::Basic::ControllerMethods::ClassMethods - # Enables HTTP \Basic authentication. + # Enables HTTP Basic authentication. # # See ActionController::HttpAuthentication::Basic for example usage. # # @raise [ArgumentError] # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#76 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#79 def http_basic_authenticate_with(name:, password:, realm: T.unsafe(nil), **options); end end -# = HTTP \Digest authentication +# # HTTP Digest authentication # -# === Simple \Digest example +# ### Simple Digest example # -# require "openssl" -# class PostsController < ApplicationController -# REALM = "SuperSecret" -# USERS = {"dhh" => "secret", #plain text password -# "dap" => OpenSSL::Digest::MD5.hexdigest(["dap",REALM,"secret"].join(":"))} #ha1 digest password +# require "openssl" +# class PostsController < ApplicationController +# REALM = "SuperSecret" +# USERS = {"dhh" => "secret", #plain text password +# "dap" => OpenSSL::Digest::MD5.hexdigest(["dap",REALM,"secret"].join(":"))} #ha1 digest password # -# before_action :authenticate, except: [:index] +# before_action :authenticate, except: [:index] # -# def index -# render plain: "Everyone can see me!" -# end +# def index +# render plain: "Everyone can see me!" +# end # -# def edit -# render plain: "I'm only accessible if you know the password" -# end +# def edit +# render plain: "I'm only accessible if you know the password" +# end # -# private -# def authenticate -# authenticate_or_request_with_http_digest(REALM) do |username| -# USERS[username] +# private +# def authenticate +# authenticate_or_request_with_http_digest(REALM) do |username| +# USERS[username] +# end # end -# end -# end +# end # -# === Notes +# ### Notes # -# The +authenticate_or_request_with_http_digest+ block must return the user's password -# or the ha1 digest hash so the framework can appropriately hash to check the user's -# credentials. Returning +nil+ will cause authentication to fail. +# The `authenticate_or_request_with_http_digest` block must return the user's +# password or the ha1 digest hash so the framework can appropriately hash to +# check the user's credentials. Returning `nil` will cause authentication to +# fail. # -# Storing the ha1 hash: MD5(username:realm:password), is better than storing a plain password. If -# the password file or database is compromised, the attacker would be able to use the ha1 hash to -# authenticate as the user at this +realm+, but would not have the user's password to try using at -# other sites. +# Storing the ha1 hash: MD5(username:realm:password), is better than storing a +# plain password. If the password file or database is compromised, the attacker +# would be able to use the ha1 hash to authenticate as the user at this `realm`, +# but would not have the user's password to try using at other sites. # -# In rare instances, web servers or front proxies strip authorization headers before -# they reach your application. You can debug this situation by logging all environment -# variables, and check for HTTP_AUTHORIZATION, amongst others. +# In rare instances, web servers or front proxies strip authorization headers +# before they reach your application. You can debug this situation by logging +# all environment variables, and check for HTTP_AUTHORIZATION, amongst others. # -# source://actionpack//lib/action_controller/metal/http_authentication.rb#185 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#189 module ActionController::HttpAuthentication::Digest extend ::ActionController::HttpAuthentication::Digest # Returns false on a valid response, true otherwise. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#211 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#215 def authenticate(request, realm, &password_procedure); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#269 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#274 def authentication_header(controller, realm); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#276 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#281 def authentication_request(controller, realm, message = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#262 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#267 def decode_credentials(header); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#258 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#263 def decode_credentials_header(request); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#253 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#258 def encode_credentials(http_method, credentials, password, password_is_ha1); end - # Returns the expected response for a request of +http_method+ to +uri+ with the decoded +credentials+ and the expected +password+ - # Optional parameter +password_is_ha1+ is set to +true+ by default, since best practice is to store ha1 digest instead - # of a plain-text password. + # Returns the expected response for a request of `http_method` to `uri` with the + # decoded `credentials` and the expected `password` Optional parameter + # `password_is_ha1` is set to `true` by default, since best practice is to store + # ha1 digest instead of a plain-text password. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#243 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#248 def expected_response(http_method, uri, credentials, password, password_is_ha1 = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#249 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#254 def ha1(credentials, password); end # Uses an MD5 digest based on time to generate a value to be used only once. # - # A server-specified data string which should be uniquely generated each time a 401 response is made. - # It is recommended that this string be base64 or hexadecimal data. - # Specifically, since the string is passed in the header lines as a quoted string, the double-quote character is not allowed. - # - # The contents of the nonce are implementation dependent. - # The quality of the implementation depends on a good choice. - # A nonce might, for example, be constructed as the base 64 encoding of - # - # time-stamp H(time-stamp ":" ETag ":" private-key) - # - # where time-stamp is a server-generated time or other non-repeating value, - # ETag is the value of the HTTP ETag header associated with the requested entity, - # and private-key is data known only to the server. - # With a nonce of this form a server would recalculate the hash portion after receiving the client authentication header and - # reject the request if it did not match the nonce from that header or - # if the time-stamp value is not recent enough. In this way the server can limit the time of the nonce's validity. - # The inclusion of the ETag prevents a replay request for an updated version of the resource. - # (Note: including the IP address of the client in the nonce would appear to offer the server the ability - # to limit the reuse of the nonce to the same client that originally got it. - # However, that would break proxy farms, where requests from a single user often go through different proxies in the farm. - # Also, IP address spoofing is not that hard.) - # - # An implementation might choose not to accept a previously used nonce or a previously used digest, in order to - # protect against a replay attack. Or, an implementation might choose to use one-time nonces or digests for - # POST, PUT, or PATCH requests, and a time-stamp for GET requests. For more details on the issues involved see Section 4 - # of this document. - # - # The nonce is opaque to the client. Composed of Time, and hash of Time with secret - # key from the Rails session secret generated upon creation of project. Ensures - # the time cannot be modified by client. - # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#321 + # A server-specified data string which should be uniquely generated each time a + # 401 response is made. It is recommended that this string be base64 or + # hexadecimal data. Specifically, since the string is passed in the header lines + # as a quoted string, the double-quote character is not allowed. + # + # The contents of the nonce are implementation dependent. The quality of the + # implementation depends on a good choice. A nonce might, for example, be + # constructed as the base 64 encoding of + # + # time-stamp H(time-stamp ":" ETag ":" private-key) + # + # where time-stamp is a server-generated time or other non-repeating value, ETag + # is the value of the HTTP ETag header associated with the requested entity, and + # private-key is data known only to the server. With a nonce of this form a + # server would recalculate the hash portion after receiving the client + # authentication header and reject the request if it did not match the nonce + # from that header or if the time-stamp value is not recent enough. In this way + # the server can limit the time of the nonce's validity. The inclusion of the + # ETag prevents a replay request for an updated version of the resource. (Note: + # including the IP address of the client in the nonce would appear to offer the + # server the ability to limit the reuse of the nonce to the same client that + # originally got it. However, that would break proxy farms, where requests from + # a single user often go through different proxies in the farm. Also, IP address + # spoofing is not that hard.) + # + # An implementation might choose not to accept a previously used nonce or a + # previously used digest, in order to protect against a replay attack. Or, an + # implementation might choose to use one-time nonces or digests for POST, PUT, + # or PATCH requests, and a time-stamp for GET requests. For more details on the + # issues involved see Section 4 of this document. + # + # The nonce is opaque to the client. Composed of Time, and hash of Time with + # secret key from the Rails session secret generated upon creation of project. + # Ensures the time cannot be modified by client. + # + # source://actionpack//lib/action_controller/metal/http_authentication.rb#330 def nonce(secret_key, time = T.unsafe(nil)); end # Opaque based on digest of secret key # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#340 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#348 def opaque(secret_key); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#283 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#288 def secret_token(request); end - # Returns false unless the request credentials response value matches the expected value. - # First try the password as a ha1 digest password. If this fails, then try it as a plain - # text password. + # Returns false unless the request credentials response value matches the + # expected value. First try the password as a ha1 digest password. If this + # fails, then try it as a plain text password. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#218 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#222 def validate_digest_response(request, realm, &password_procedure); end - # Might want a shorter timeout depending on whether the request - # is a PATCH, PUT, or POST, and if the client is a browser or web service. - # Can be much shorter if the Stale directive is implemented. This would - # allow a user to use new nonce without prompting the user again for their - # username and password. + # Might want a shorter timeout depending on whether the request is a PATCH, PUT, + # or POST, and if the client is a browser or web service. Can be much shorter if + # the Stale directive is implemented. This would allow a user to use new nonce + # without prompting the user again for their username and password. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#333 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#341 def validate_nonce(secret_key, request, value, seconds_to_timeout = T.unsafe(nil)); end end -# source://actionpack//lib/action_controller/metal/http_authentication.rb#188 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#192 module ActionController::HttpAuthentication::Digest::ControllerMethods - # Authenticate using an HTTP \Digest, or otherwise render an HTTP header - # requesting the client to send a \Digest. + # Authenticate using an HTTP Digest, or otherwise render an HTTP header + # requesting the client to send a Digest. # # See ActionController::HttpAuthentication::Digest for example usage. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#193 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#197 def authenticate_or_request_with_http_digest(realm = T.unsafe(nil), message = T.unsafe(nil), &password_procedure); end - # Authenticate using an HTTP \Digest. Returns true if authentication is + # Authenticate using an HTTP Digest. Returns true if authentication is # successful, false otherwise. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#199 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#203 def authenticate_with_http_digest(realm = T.unsafe(nil), &password_procedure); end - # Render an HTTP header requesting the client to send a \Digest for + # Render an HTTP header requesting the client to send a Digest for # authentication. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#205 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#209 def request_http_digest_authentication(realm = T.unsafe(nil), message = T.unsafe(nil)); end end -# = HTTP \Token authentication +# # HTTP Token authentication # -# === Simple \Token example +# ### Simple Token example # -# class PostsController < ApplicationController -# TOKEN = "secret" +# class PostsController < ApplicationController +# TOKEN = "secret" # -# before_action :authenticate, except: [ :index ] +# before_action :authenticate, except: [ :index ] # -# def index -# render plain: "Everyone can see me!" -# end +# def index +# render plain: "Everyone can see me!" +# end # -# def edit -# render plain: "I'm only accessible if you know the password" -# end +# def edit +# render plain: "I'm only accessible if you know the password" +# end # -# private -# def authenticate -# authenticate_or_request_with_http_token do |token, options| -# # Compare the tokens in a time-constant manner, to mitigate -# # timing attacks. -# ActiveSupport::SecurityUtils.secure_compare(token, TOKEN) +# private +# def authenticate +# authenticate_or_request_with_http_token do |token, options| +# # Compare the tokens in a time-constant manner, to mitigate +# # timing attacks. +# ActiveSupport::SecurityUtils.secure_compare(token, TOKEN) +# end # end -# end -# end +# end # +# Here is a more advanced Token example where only Atom feeds and the XML API +# are protected by HTTP token authentication. The regular HTML interface is +# protected by a session approach: # -# Here is a more advanced Token example where only Atom feeds and the XML API are protected by HTTP token authentication. -# The regular HTML interface is protected by a session approach: -# -# class ApplicationController < ActionController::Base -# before_action :set_account, :authenticate +# class ApplicationController < ActionController::Base +# before_action :set_account, :authenticate # -# private -# def set_account -# @account = Account.find_by(url_name: request.subdomains.first) -# end +# private +# def set_account +# @account = Account.find_by(url_name: request.subdomains.first) +# end # -# def authenticate -# case request.format -# when Mime[:xml], Mime[:atom] -# if user = authenticate_with_http_token { |t, o| @account.users.authenticate(t, o) } -# @current_user = user +# def authenticate +# case request.format +# when Mime[:xml], Mime[:atom] +# if user = authenticate_with_http_token { |t, o| @account.users.authenticate(t, o) } +# @current_user = user +# else +# request_http_token_authentication +# end # else -# request_http_token_authentication -# end -# else -# if session_authenticated? -# @current_user = @account.users.find(session[:authenticated][:user_id]) -# else -# redirect_to(login_url) and return false +# if session_authenticated? +# @current_user = @account.users.find(session[:authenticated][:user_id]) +# else +# redirect_to(login_url) and return false +# end # end # end -# end -# end -# +# end # # In your integration tests, you can do something like this: # -# def test_access_granted_from_xml -# authorization = ActionController::HttpAuthentication::Token.encode_credentials(users(:dhh).token) -# -# get "/notes/1.xml", headers: { 'HTTP_AUTHORIZATION' => authorization } +# def test_access_granted_from_xml +# authorization = ActionController::HttpAuthentication::Token.encode_credentials(users(:dhh).token) # -# assert_equal 200, status -# end +# get "/notes/1.xml", headers: { 'HTTP_AUTHORIZATION' => authorization } # +# assert_equal 200, status +# end # -# On shared hosts, Apache sometimes doesn't pass authentication headers to -# FCGI instances. If your environment matches this description and you cannot +# On shared hosts, Apache sometimes doesn't pass authentication headers to FCGI +# instances. If your environment matches this description and you cannot # authenticate, try this rule in your Apache setup: # -# RewriteRule ^(.*)$ dispatch.fcgi [E=X-HTTP_AUTHORIZATION:%{HTTP:Authorization},QSA,L] +# RewriteRule ^(.*)$ dispatch.fcgi [E=X-HTTP_AUTHORIZATION:%{HTTP:Authorization},QSA,L] # -# source://actionpack//lib/action_controller/metal/http_authentication.rb#419 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#425 module ActionController::HttpAuthentication::Token extend ::ActionController::HttpAuthentication::Token - # If token Authorization header is present, call the login - # procedure with the present token and options. + # If token Authorization header is present, call the login procedure with the + # present token and options. # - # Returns the return value of login_procedure if a - # token is found. Returns nil if no token is found. + # Returns the return value of `login_procedure` if a token is found. Returns + # `nil` if no token is found. # - # ==== Parameters + # #### Parameters # - # * +controller+ - ActionController::Base instance for the current request. - # * +login_procedure+ - Proc to call if a token is present. The Proc - # should take two arguments: + # * `controller` - ActionController::Base instance for the current request. + # * `login_procedure` - Proc to call if a token is present. The Proc should + # take two arguments: # - # authenticate(controller) { |token, options| ... } + # authenticate(controller) { |token, options| ... } # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#461 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#472 def authenticate(controller, &login_procedure); end # Sets a WWW-Authenticate header to let the client know a token is desired. # # Returns nothing. # - # ==== Parameters + # #### Parameters # - # * +controller+ - ActionController::Base instance for the outgoing response. - # * +realm+ - String realm to use in the header. + # * `controller` - ActionController::Base instance for the outgoing response. + # * `realm` - String realm to use in the header. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#541 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#558 def authentication_request(controller, realm, message = T.unsafe(nil)); end # Encodes the given token and options into an Authorization header value. # # Returns String. # - # ==== Parameters + # #### Parameters # - # * +token+ - String token. - # * +options+ - Optional Hash of the options. + # * `token` - String token. + # * `options` - Optional Hash of the options. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#526 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#542 def encode_credentials(token, options = T.unsafe(nil)); end - # Takes +raw_params+ and turns it into an array of parameters. + # Takes `raw_params` and turns it into an array of parameters. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#496 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#507 def params_array_from(raw_params); end - # This method takes an authorization body and splits up the key-value - # pairs by the standardized :, ;, or \t - # delimiters defined in +AUTHN_PAIR_DELIMITERS+. + # This method takes an authorization body and splits up the key-value pairs by + # the standardized `:`, `;`, or `\t` delimiters defined in + # `AUTHN_PAIR_DELIMITERS`. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#508 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#522 def raw_params(auth); end - # This removes the " characters wrapping the value. + # This removes the `"` characters wrapping the value. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#501 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#512 def rewrite_param_values(array_params); end - # Parses the token and options out of the token Authorization header. - # The value for the Authorization header is expected to have the prefix - # "Token" or "Bearer". If the header looks like this: + # Parses the token and options out of the token Authorization header. The value + # for the Authorization header is expected to have the prefix `"Token"` or + # `"Bearer"`. If the header looks like this: # - # Authorization: Token token="abc", nonce="def" + # Authorization: Token token="abc", nonce="def" # - # Then the returned token is "abc", and the options are - # {nonce: "def"}. + # Then the returned token is `"abc"`, and the options are `{nonce: "def"}`. # - # Returns an +Array+ of [String, Hash] if a token is present. - # Returns +nil+ if no token is found. + # Returns an `Array` of `[String, Hash]` if a token is present. Returns `nil` if + # no token is found. # - # ==== Parameters + # #### Parameters # - # * +request+ - ActionDispatch::Request instance with the current headers. + # * `request` - ActionDispatch::Request instance with the current headers. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#483 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#494 def token_and_options(request); end - # source://actionpack//lib/action_controller/metal/http_authentication.rb#491 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#502 def token_params_from(auth); end end -# source://actionpack//lib/action_controller/metal/http_authentication.rb#422 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#428 ActionController::HttpAuthentication::Token::AUTHN_PAIR_DELIMITERS = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_controller/metal/http_authentication.rb#425 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#431 module ActionController::HttpAuthentication::Token::ControllerMethods - # Authenticate using an HTTP Bearer token, or otherwise render an HTTP - # header requesting the client to send a Bearer token. + # Authenticate using an HTTP Bearer token, or otherwise render an HTTP header + # requesting the client to send a Bearer token. For the authentication to be + # considered successful, `login_procedure` should return a non-nil value. + # Typically, the authenticated user is returned. # # See ActionController::HttpAuthentication::Token for example usage. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#430 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#438 def authenticate_or_request_with_http_token(realm = T.unsafe(nil), message = T.unsafe(nil), &login_procedure); end - # Authenticate using an HTTP Bearer token. Returns true if - # authentication is successful, false otherwise. + # Authenticate using an HTTP Bearer token. Returns the return value of + # `login_procedure` if a token is found. Returns `nil` if no token is found. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#436 + # See ActionController::HttpAuthentication::Token for example usage. + # + # source://actionpack//lib/action_controller/metal/http_authentication.rb#446 def authenticate_with_http_token(&login_procedure); end # Render an HTTP header requesting the client to send a Bearer token for # authentication. # - # source://actionpack//lib/action_controller/metal/http_authentication.rb#442 + # source://actionpack//lib/action_controller/metal/http_authentication.rb#452 def request_http_token_authentication(realm = T.unsafe(nil), message = T.unsafe(nil)); end end -# source://actionpack//lib/action_controller/metal/http_authentication.rb#420 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#426 ActionController::HttpAuthentication::Token::TOKEN_KEY = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_controller/metal/http_authentication.rb#421 +# source://actionpack//lib/action_controller/metal/http_authentication.rb#427 ActionController::HttpAuthentication::Token::TOKEN_REGEX = T.let(T.unsafe(nil), Regexp) -# Handles implicit rendering for a controller action that does not -# explicitly respond with +render+, +respond_to+, +redirect+, or +head+. +# source://actionpack//lib/action_controller/metal/http_authentication.rb#516 +ActionController::HttpAuthentication::Token::WHITESPACED_AUTHN_PAIR_DELIMITERS = T.let(T.unsafe(nil), Regexp) + +# # Action Controller Implicit Render # -# For API controllers, the implicit response is always 204 No Content. +# Handles implicit rendering for a controller action that does not explicitly +# respond with `render`, `respond_to`, `redirect`, or `head`. # -# For all other controllers, we use these heuristics to decide whether to -# render a template, raise an error for a missing template, or respond with -# 204 No Content: +# For API controllers, the implicit response is always `204 No Content`. # -# First, if we DO find a template, it's rendered. Template lookup accounts -# for the action name, locales, format, variant, template handlers, and more -# (see +render+ for details). +# For all other controllers, we use these heuristics to decide whether to render +# a template, raise an error for a missing template, or respond with `204 No +# Content`: +# +# First, if we DO find a template, it's rendered. Template lookup accounts for +# the action name, locales, format, variant, template handlers, and more (see +# `render` for details). # # Second, if we DON'T find a template but the controller action does have -# templates for other formats, variants, etc., then we trust that you meant -# to provide a template for this response, too, and we raise -# ActionController::UnknownFormat with an explanation. +# templates for other formats, variants, etc., then we trust that you meant to +# provide a template for this response, too, and we raise +# ActionController::UnknownFormat with an explanation. # # Third, if we DON'T find a template AND the request is a page load in a web -# browser (technically, a non-XHR GET request for an HTML response) where -# you reasonably expect to have rendered a template, then we raise -# ActionController::MissingExactTemplate with an explanation. +# browser (technically, a non-XHR GET request for an HTML response) where you +# reasonably expect to have rendered a template, then we raise +# ActionController::MissingExactTemplate with an explanation. # # Finally, if we DON'T find a template AND the request isn't a browser page -# load, then we implicitly respond with 204 No Content. +# load, then we implicitly respond with `204 No Content`. # -# source://actionpack//lib/action_controller/metal/implicit_render.rb#29 +# source://actionpack//lib/action_controller/metal/implicit_render.rb#33 module ActionController::ImplicitRender include ::ActionController::BasicImplicitRender - # source://actionpack//lib/action_controller/metal/implicit_render.rb#33 + # source://actionpack//lib/action_controller/metal/implicit_render.rb#37 def default_render; end - # source://actionpack//lib/action_controller/metal/implicit_render.rb#52 + # source://actionpack//lib/action_controller/metal/implicit_render.rb#56 def method_for_action(action_name); end private # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/implicit_render.rb#59 + # source://actionpack//lib/action_controller/metal/implicit_render.rb#63 def interactive_browser_request?; end end -# Adds instrumentation to several ends in ActionController::Base. It also provides -# some hooks related with process_action. This allows an ORM like Active Record -# and/or DataMapper to plug in ActionController and show related information. +# # Action Controller Instrumentation +# +# Adds instrumentation to several ends in ActionController::Base. It also +# provides some hooks related with process_action. This allows an ORM like +# Active Record and/or DataMapper to plug in ActionController and show related +# information. # # Check ActiveRecord::Railties::ControllerRuntime for an example. # -# source://actionpack//lib/action_controller/metal/instrumentation.rb#12 +# source://actionpack//lib/action_controller/metal/instrumentation.rb#17 module ActionController::Instrumentation extend ::ActiveSupport::Concern include ::ActiveSupport::Benchmarkable @@ -3850,16 +4133,19 @@ module ActionController::Instrumentation mixes_in_class_methods ::ActionController::Instrumentation::ClassMethods - # source://actionpack//lib/action_controller/metal/instrumentation.rb#40 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#24 + def initialize(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/action_controller/metal/instrumentation.rb#50 def redirect_to(*_arg0); end - # source://actionpack//lib/action_controller/metal/instrumentation.rb#19 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#29 def render(*_arg0); end - # source://actionpack//lib/action_controller/metal/instrumentation.rb#34 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#44 def send_data(data, options = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/instrumentation.rb#27 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#37 def send_file(path, options = T.unsafe(nil)); end def view_runtime; end @@ -3867,1052 +4153,1157 @@ module ActionController::Instrumentation private - # Every time after an action is processed, this method is invoked - # with the payload, so you can add more information. + # Every time after an action is processed, this method is invoked with the + # payload, so you can add more information. # - # source://actionpack//lib/action_controller/metal/instrumentation.rb#96 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#106 def append_info_to_payload(payload); end # A hook which allows you to clean up any time, wrongly taken into account in # views, like database querying time. # - # def cleanup_view_runtime - # super - time_taken_in_something_expensive - # end + # def cleanup_view_runtime + # super - time_taken_in_something_expensive + # end # - # source://actionpack//lib/action_controller/metal/instrumentation.rb#90 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#100 def cleanup_view_runtime; end # A hook invoked every time a before callback is halted. # - # source://actionpack//lib/action_controller/metal/instrumentation.rb#80 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#90 def halted_callback_hook(filter, _); end - # source://actionpack//lib/action_controller/metal/instrumentation.rb#50 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#60 def process_action(*_arg0); end end -# source://actionpack//lib/action_controller/metal/instrumentation.rb#100 +# source://actionpack//lib/action_controller/metal/instrumentation.rb#110 module ActionController::Instrumentation::ClassMethods - # A hook which allows other frameworks to log what happened during - # controller process action. This method should return an array - # with the messages to be added. + # A hook which allows other frameworks to log what happened during controller + # process action. This method should return an array with the messages to be + # added. # - # source://actionpack//lib/action_controller/metal/instrumentation.rb#104 + # source://actionpack//lib/action_controller/metal/instrumentation.rb#114 def log_process_action(payload); end end -# source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#8 +# source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#10 class ActionController::InvalidAuthenticityToken < ::ActionController::ActionControllerError; end -# source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#11 +# source://actionpack//lib/action_controller/metal/request_forgery_protection.rb#13 class ActionController::InvalidCrossOriginRequest < ::ActionController::ActionControllerError; end -# Mix this module into your controller, and all actions in that controller -# will be able to stream data to the client as it's written. +# Raised when initializing Parameters with keys that aren't strings or symbols. # -# class MyController < ActionController::Base -# include ActionController::Live +# ActionController::Parameters.new(123 => 456) +# # => ActionController::InvalidParameterKey: all keys must be Strings or Symbols, got: Integer # -# def stream -# response.headers['Content-Type'] = 'text/event-stream' -# 100.times { -# response.stream.write "hello world\n" -# sleep 1 -# } -# ensure -# response.stream.close +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#74 +class ActionController::InvalidParameterKey < ::ArgumentError; end + +# # Action Controller Live +# +# Mix this module into your controller, and all actions in that controller will +# be able to stream data to the client as it's written. +# +# class MyController < ActionController::Base +# include ActionController::Live +# +# def stream +# response.headers['Content-Type'] = 'text/event-stream' +# 100.times { +# response.stream.write "hello world\n" +# sleep 1 +# } +# ensure +# response.stream.close +# end # end -# end # -# There are a few caveats with this module. You *cannot* write headers after the -# response has been committed (Response#committed? will return truthy). -# Calling +write+ or +close+ on the response stream will cause the response -# object to be committed. Make sure all headers are set before calling write -# or close on your stream. +# There are a few caveats with this module. You **cannot** write headers after +# the response has been committed (Response#committed? will return truthy). +# Calling `write` or `close` on the response stream will cause the response +# object to be committed. Make sure all headers are set before calling write or +# close on your stream. # -# You *must* call close on your stream when you're finished, otherwise the +# You **must** call close on your stream when you're finished, otherwise the # socket may be left open forever. # # The final caveat is that your actions are executed in a separate thread than -# the main thread. Make sure your actions are thread safe, and this shouldn't -# be a problem (don't share state across threads, etc). +# the main thread. Make sure your actions are thread safe, and this shouldn't be +# a problem (don't share state across threads, etc). +# +# Note that Rails includes `Rack::ETag` by default, which will buffer your +# response. As a result, streaming responses may not work properly with Rack +# 2.2.x, and you may need to implement workarounds in your application. You can +# either set the `ETag` or `Last-Modified` response headers or remove +# `Rack::ETag` from the middleware stack to address this issue. +# +# Here's an example of how you can set the `Last-Modified` header if your Rack +# version is 2.2.x: +# +# def stream +# response.headers["Content-Type"] = "text/event-stream" +# response.headers["Last-Modified"] = Time.now.httpdate # Add this line if your Rack version is 2.2.x +# ... +# end # -# source://actionpack//lib/action_controller/metal/live.rb#37 +# source://actionpack//lib/action_controller/metal/live.rb#56 module ActionController::Live extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionController::Live::ClassMethods - # source://actionpack//lib/action_controller/test_case.rb#24 + # source://actionpack//lib/action_controller/test_case.rb#26 def new_controller_thread; end - # source://actionpack//lib/action_controller/metal/live.rb#249 + # source://actionpack//lib/action_controller/metal/live.rb#273 def process(name); end - # source://actionpack//lib/action_controller/metal/live.rb#295 + # source://actionpack//lib/action_controller/metal/live.rb#319 def response_body=(body); end - # Sends a stream to the browser, which is helpful when you're generating exports or other running data where you - # don't want the entire file buffered in memory first. Similar to send_data, but where the data is generated live. + # Sends a stream to the browser, which is helpful when you're generating exports + # or other running data where you don't want the entire file buffered in memory + # first. Similar to send_data, but where the data is generated live. # # Options: - # * :filename - suggests a filename for the browser to use. - # * :type - specifies an HTTP content type. - # You can specify either a string or a symbol for a registered type with Mime::Type.register, for example :json. - # If omitted, type will be inferred from the file extension specified in :filename. - # If no content type is registered for the extension, the default type 'application/octet-stream' will be used. - # * :disposition - specifies whether the file will be shown inline or downloaded. - # Valid values are 'inline' and 'attachment' (default). + # * `:filename` - suggests a filename for the browser to use. + # * `:type` - specifies an HTTP content type. You can specify either a string + # or a symbol for a registered type with `Mime::Type.register`, for example + # :json. If omitted, type will be inferred from the file extension specified + # in `:filename`. If no content type is registered for the extension, the + # default type 'application/octet-stream' will be used. + # * `:disposition` - specifies whether the file will be shown inline or + # downloaded. Valid values are 'inline' and 'attachment' (default). + # # # Example of generating a csv export: # - # send_stream(filename: "subscribers.csv") do |stream| - # stream.write "email_address,updated_at\n" + # send_stream(filename: "subscribers.csv") do |stream| + # stream.write "email_address,updated_at\n" # - # @subscribers.find_each do |subscriber| - # stream.write "#{subscriber.email_address},#{subscriber.updated_at}\n" - # end - # end + # @subscribers.find_each do |subscriber| + # stream.write "#{subscriber.email_address},#{subscriber.updated_at}\n" + # end + # end # - # source://actionpack//lib/action_controller/metal/live.rb#321 + # source://actionpack//lib/action_controller/metal/live.rb#348 def send_stream(filename:, disposition: T.unsafe(nil), type: T.unsafe(nil)); end private - # source://actionpack//lib/action_controller/metal/live.rb#348 + # source://actionpack//lib/action_controller/metal/live.rb#378 def log_error(exception); end end -# source://actionpack//lib/action_controller/metal/live.rb#127 +# source://actionpack//lib/action_controller/metal/live.rb#148 class ActionController::Live::Buffer < ::ActionDispatch::Response::Buffer include ::MonitorMixin # @return [Buffer] a new instance of Buffer # - # source://actionpack//lib/action_controller/metal/live.rb#143 + # source://actionpack//lib/action_controller/metal/live.rb#163 def initialize(response); end - # Inform the producer/writing thread that the client has - # disconnected; the reading thread is no longer interested in - # anything that's being written. + # Inform the producer/writing thread that the client has disconnected; the + # reading thread is no longer interested in anything that's being written. # # See also #close. # - # source://actionpack//lib/action_controller/metal/live.rb#193 + # source://actionpack//lib/action_controller/metal/live.rb#217 def abort; end - # source://actionpack//lib/action_controller/metal/live.rb#212 + # source://actionpack//lib/action_controller/metal/live.rb#236 def call_on_error; end - # Write a 'close' event to the buffer; the producer/writing thread - # uses this to notify us that it's finished supplying content. + # Write a 'close' event to the buffer; the producer/writing thread uses this to + # notify us that it's finished supplying content. # # See also #abort. # - # source://actionpack//lib/action_controller/metal/live.rb#180 + # source://actionpack//lib/action_controller/metal/live.rb#205 def close; end # Is the client still connected and waiting for content? # - # The result of calling `write` when this is `false` is determined - # by `ignore_disconnect`. + # The result of calling `write` when this is `false` is determined by + # `ignore_disconnect`. # # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/live.rb#204 + # source://actionpack//lib/action_controller/metal/live.rb#228 def connected?; end # Ignore that the client has disconnected. # - # If this value is `true`, calling `write` after the client - # disconnects will result in the written content being silently - # discarded. If this value is `false` (the default), a - # ClientDisconnected exception will be raised. + # If this value is `true`, calling `write` after the client disconnects will + # result in the written content being silently discarded. If this value is + # `false` (the default), a ClientDisconnected exception will be raised. # - # source://actionpack//lib/action_controller/metal/live.rb#141 + # source://actionpack//lib/action_controller/metal/live.rb#161 def ignore_disconnect; end # Ignore that the client has disconnected. # - # If this value is `true`, calling `write` after the client - # disconnects will result in the written content being silently - # discarded. If this value is `false` (the default), a - # ClientDisconnected exception will be raised. + # If this value is `true`, calling `write` after the client disconnects will + # result in the written content being silently discarded. If this value is + # `false` (the default), a ClientDisconnected exception will be raised. # - # source://actionpack//lib/action_controller/metal/live.rb#141 + # source://actionpack//lib/action_controller/metal/live.rb#161 def ignore_disconnect=(_arg0); end - # source://actionpack//lib/action_controller/metal/live.rb#208 + # source://actionpack//lib/action_controller/metal/live.rb#232 def on_error(&block); end - # source://actionpack//lib/action_controller/metal/live.rb#151 + # source://actionpack//lib/action_controller/metal/live.rb#177 def write(string); end - # Same as +write+ but automatically include a newline at the end of the string. + # Same as `write` but automatically include a newline at the end of the string. # - # source://actionpack//lib/action_controller/metal/live.rb#172 + # source://actionpack//lib/action_controller/metal/live.rb#197 def writeln(string); end private - # source://actionpack//lib/action_controller/metal/live.rb#228 + # source://actionpack//lib/action_controller/metal/live.rb#252 def build_queue(queue_size); end - # source://actionpack//lib/action_controller/metal/live.rb#217 + # source://actionpack//lib/action_controller/metal/live.rb#241 def each_chunk(&block); end class << self # Returns the value of attribute queue_size. # - # source://actionpack//lib/action_controller/metal/live.rb#131 + # source://actionpack//lib/action_controller/metal/live.rb#152 def queue_size; end # Sets the attribute queue_size # # @param value the value to set the attribute queue_size to. # - # source://actionpack//lib/action_controller/metal/live.rb#131 + # source://actionpack//lib/action_controller/metal/live.rb#152 def queue_size=(_arg0); end end end -# source://actionpack//lib/action_controller/metal/live.rb#40 +# source://actionpack//lib/action_controller/metal/live.rb#59 module ActionController::Live::ClassMethods - # source://actionpack//lib/action_controller/metal/live.rb#41 + # source://actionpack//lib/action_controller/metal/live.rb#60 def make_response!(request); end end -# source://actionpack//lib/action_controller/metal/live.rb#124 +# source://actionpack//lib/action_controller/metal/live.rb#145 class ActionController::Live::ClientDisconnected < ::RuntimeError; end -# source://actionpack//lib/action_controller/metal/live.rb#233 +# source://actionpack//lib/action_controller/metal/live.rb#257 class ActionController::Live::Response < ::ActionDispatch::Response private - # source://actionpack//lib/action_controller/metal/live.rb#235 + # source://actionpack//lib/action_controller/metal/live.rb#259 def before_committed; end - # source://actionpack//lib/action_controller/metal/live.rb#242 + # source://actionpack//lib/action_controller/metal/live.rb#266 def build_buffer(response, body); end end -# This class provides the ability to write an SSE (Server Sent Event) -# to an IO stream. The class is initialized with a stream and can be used -# to either write a JSON string or an object which can be converted to JSON. +# # Action Controller Live Server Sent Events +# +# This class provides the ability to write an SSE (Server Sent Event) to an IO +# stream. The class is initialized with a stream and can be used to either write +# a JSON string or an object which can be converted to JSON. # # Writing an object will convert it into standard SSE format with whatever # options you have configured. You may choose to set the following options: # -# 1) Event. If specified, an event with this name will be dispatched on -# the browser. -# 2) Retry. The reconnection time in milliseconds used when attempting -# to send the event. -# 3) Id. If the connection dies while sending an SSE to the browser, then -# the server will receive a +Last-Event-ID+ header with value equal to +id+. +# 1) Event. If specified, an event with this name will be dispatched on +# the browser. +# 2) Retry. The reconnection time in milliseconds used when attempting +# to send the event. +# 3) Id. If the connection dies while sending an SSE to the browser, then +# the server will receive a +Last-Event-ID+ header with value equal to +id+. # -# After setting an option in the constructor of the SSE object, all future -# SSEs sent across the stream will use those options unless overridden. +# After setting an option in the constructor of the SSE object, all future SSEs +# sent across the stream will use those options unless overridden. # # Example Usage: # -# class MyController < ActionController::Base -# include ActionController::Live -# -# def index -# response.headers['Content-Type'] = 'text/event-stream' -# sse = SSE.new(response.stream, retry: 300, event: "event-name") -# sse.write({ name: 'John'}) -# sse.write({ name: 'John'}, id: 10) -# sse.write({ name: 'John'}, id: 10, event: "other-event") -# sse.write({ name: 'John'}, id: 10, event: "other-event", retry: 500) -# ensure -# sse.close +# class MyController < ActionController::Base +# include ActionController::Live +# +# def index +# response.headers['Content-Type'] = 'text/event-stream' +# sse = SSE.new(response.stream, retry: 300, event: "event-name") +# sse.write({ name: 'John'}) +# sse.write({ name: 'John'}, id: 10) +# sse.write({ name: 'John'}, id: 10, event: "other-event") +# sse.write({ name: 'John'}, id: 10, event: "other-event", retry: 500) +# ensure +# sse.close +# end # end -# end # -# Note: SSEs are not currently supported by IE. However, they are supported -# by Chrome, Firefox, Opera, and Safari. +# Note: SSEs are not currently supported by IE. However, they are supported by +# Chrome, Firefox, Opera, and Safari. # -# source://actionpack//lib/action_controller/metal/live.rb#88 +# source://actionpack//lib/action_controller/metal/live.rb#109 class ActionController::Live::SSE # @return [SSE] a new instance of SSE # - # source://actionpack//lib/action_controller/metal/live.rb#91 + # source://actionpack//lib/action_controller/metal/live.rb#112 def initialize(stream, options = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/live.rb#96 + # source://actionpack//lib/action_controller/metal/live.rb#117 def close; end - # source://actionpack//lib/action_controller/metal/live.rb#100 + # source://actionpack//lib/action_controller/metal/live.rb#121 def write(object, options = T.unsafe(nil)); end private - # source://actionpack//lib/action_controller/metal/live.rb#110 + # source://actionpack//lib/action_controller/metal/live.rb#131 def perform_write(json, options); end end -# source://actionpack//lib/action_controller/metal/live.rb#89 +# source://actionpack//lib/action_controller/metal/live.rb#110 ActionController::Live::SSE::PERMITTED_OPTIONS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_controller/test_case.rb#169 +# source://actionpack//lib/action_controller/test_case.rb#174 class ActionController::LiveTestResponse < ::ActionController::Live::Response # Was there a server-side error? # - # source://rack/2.2.7/lib/rack/response.rb#141 + # source://rack/2.2.9/lib/rack/response.rb#141 def error?; end # Was the URL not found? # - # source://rack/2.2.7/lib/rack/response.rb#151 + # source://rack/2.2.9/lib/rack/response.rb#151 def missing?; end # Was the response successful? # - # source://rack/2.2.7/lib/rack/response.rb#138 + # source://rack/2.2.9/lib/rack/response.rb#138 def success?; end end -# source://actionpack//lib/action_controller/log_subscriber.rb#4 +# source://actionpack//lib/action_controller/log_subscriber.rb#6 class ActionController::LogSubscriber < ::ActiveSupport::LogSubscriber - # source://actionpack//lib/action_controller/log_subscriber.rb#67 + # source://actionpack//lib/action_controller/log_subscriber.rb#80 def exist_fragment?(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#67 + # source://actionpack//lib/action_controller/log_subscriber.rb#80 def expire_fragment(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#40 + # source://actionpack//lib/action_controller/log_subscriber.rb#47 def halted_callback(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#76 + # source://actionpack//lib/action_controller/log_subscriber.rb#90 def logger; end - # source://actionpack//lib/action_controller/log_subscriber.rb#20 + # source://actionpack//lib/action_controller/log_subscriber.rb#26 def process_action(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#67 + # source://actionpack//lib/action_controller/log_subscriber.rb#80 def read_fragment(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#48 + # source://actionpack//lib/action_controller/log_subscriber.rb#57 def redirect_to(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#52 + # source://actionpack//lib/action_controller/log_subscriber.rb#62 def send_data(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#44 + # source://actionpack//lib/action_controller/log_subscriber.rb#52 def send_file(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#7 + # source://actionpack//lib/action_controller/log_subscriber.rb#9 def start_processing(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#56 + # source://actionpack//lib/action_controller/log_subscriber.rb#67 def unpermitted_parameters(event); end - # source://actionpack//lib/action_controller/log_subscriber.rb#67 + # source://actionpack//lib/action_controller/log_subscriber.rb#80 def write_fragment(event); end + + class << self + # source://activesupport/7.2.0/lib/active_support/log_subscriber.rb#84 + def log_levels; end + end end -# source://actionpack//lib/action_controller/log_subscriber.rb#5 +# source://actionpack//lib/action_controller/log_subscriber.rb#7 ActionController::LogSubscriber::INTERNAL_PARAMS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_controller/metal/logging.rb#4 +# source://actionpack//lib/action_controller/metal/logging.rb#6 module ActionController::Logging extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionController::Logging::ClassMethods end -# source://actionpack//lib/action_controller/metal/logging.rb#7 +# source://actionpack//lib/action_controller/metal/logging.rb#9 module ActionController::Logging::ClassMethods # Set a different log level per request. # - # # Use the debug log level if a particular cookie is set. - # class ApplicationController < ActionController::Base - # log_at :debug, if: -> { cookies[:debug] } - # end + # # Use the debug log level if a particular cookie is set. + # class ApplicationController < ActionController::Base + # log_at :debug, if: -> { cookies[:debug] } + # end # - # source://actionpack//lib/action_controller/metal/logging.rb#15 + # source://actionpack//lib/action_controller/metal/logging.rb#17 def log_at(level, **options); end end -# ActionController::Metal is the simplest possible controller, providing a +# # Action Controller Metal +# +# `ActionController::Metal` is the simplest possible controller, providing a # valid Rack interface without the additional niceties provided by # ActionController::Base. # # A sample metal controller might look like this: # -# class HelloController < ActionController::Metal -# def index -# self.response_body = "Hello World!" +# class HelloController < ActionController::Metal +# def index +# self.response_body = "Hello World!" +# end # end -# end # -# And then to route requests to your metal controller, you would add -# something like this to config/routes.rb: +# And then to route requests to your metal controller, you would add something +# like this to `config/routes.rb`: # -# get 'hello', to: HelloController.action(:index) +# get 'hello', to: HelloController.action(:index) # -# The +action+ method returns a valid Rack application for the \Rails -# router to dispatch to. +# The ::action method returns a valid Rack application for the Rails router to +# dispatch to. # -# == Rendering Helpers +# ## Rendering Helpers # -# ActionController::Metal by default provides no utilities for rendering -# views, partials, or other responses aside from explicitly calling of -# response_body=, content_type=, and status=. To -# add the render helpers you're used to having in a normal controller, you -# can do the following: +# By default, `ActionController::Metal` provides no utilities for rendering +# views, partials, or other responses aside from some low-level setters such +# as #response_body=, #content_type=, and #status=. To add the render helpers +# you're used to having in a normal controller, you can do the following: # -# class HelloController < ActionController::Metal -# include AbstractController::Rendering -# include ActionView::Layouts -# append_view_path "#{Rails.root}/app/views" +# class HelloController < ActionController::Metal +# include AbstractController::Rendering +# include ActionView::Layouts +# append_view_path "#{Rails.root}/app/views" # -# def index -# render "hello/index" +# def index +# render "hello/index" +# end # end -# end # -# == Redirection Helpers +# ## Redirection Helpers # # To add redirection helpers to your metal controller, do the following: # -# class HelloController < ActionController::Metal -# include ActionController::Redirecting -# include Rails.application.routes.url_helpers +# class HelloController < ActionController::Metal +# include ActionController::Redirecting +# include Rails.application.routes.url_helpers # -# def index -# redirect_to root_url +# def index +# redirect_to root_url +# end # end -# end # -# == Other Helpers +# ## Other Helpers # -# You can refer to the modules included in ActionController::Base to see -# other features you can bring into your metal controller. +# You can refer to the modules included in ActionController::Base to see other +# features you can bring into your metal controller. # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://actionpack//lib/action_controller/metal.rb#117 +# source://actionpack//lib/action_controller/metal.rb#121 class ActionController::Metal < ::AbstractController::Base include ::ActionController::Testing::Functional # @return [Metal] a new instance of Metal # - # source://actionpack//lib/action_controller/metal.rb#150 + # source://actionpack//lib/action_controller/metal.rb#210 def initialize; end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#content_type + # + # source://actionpack//lib/action_controller/metal.rb#204 def content_type(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#content_type= + # + # source://actionpack//lib/action_controller/metal.rb#192 def content_type=(arg); end # Delegates to the class's ::controller_name. # - # source://actionpack//lib/action_controller/metal.rb#141 + # source://actionpack//lib/action_controller/metal.rb#156 def controller_name; end - # source://actionpack//lib/action_controller/metal.rb#185 + # source://actionpack//lib/action_controller/metal.rb#249 def dispatch(name, request, response); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#headers. + # + # source://actionpack//lib/action_controller/metal.rb#180 def headers(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#location + # + # source://actionpack//lib/action_controller/metal.rb#200 def location(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#location= + # + # source://actionpack//lib/action_controller/metal.rb#188 def location=(arg); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#media_type + # + # source://actionpack//lib/action_controller/metal.rb#208 def media_type(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack; end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack=(_arg0); end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack?; end - # source://actionpack//lib/action_controller/metal.rb#157 + # source://actionpack//lib/action_controller/metal.rb#219 def params; end - # source://actionpack//lib/action_controller/metal.rb#161 + # source://actionpack//lib/action_controller/metal.rb#223 def params=(val); end # Tests if render or redirect has already happened. # # @return [Boolean] # - # source://actionpack//lib/action_controller/metal.rb#181 + # source://actionpack//lib/action_controller/metal.rb#245 def performed?; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # :attr_reader: request + # + # The ActionDispatch::Request instance for the current request. + # + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def request; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def request=(_arg0); end - # source://actionpack//lib/action_controller/metal.rb#206 + # source://actionpack//lib/action_controller/metal.rb#284 def reset_session; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # :attr_reader: response + # + # The ActionDispatch::Response instance for the current response. + # + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def response; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 - def response=(_arg0); end + # Assign the response and mark it as committed. No further processing will + # occur. + # + # source://actionpack//lib/action_controller/metal.rb#268 + def response=(response); end - # source://actionpack//lib/action_controller/metal.rb#172 + # source://actionpack//lib/action_controller/metal.rb#234 def response_body=(body); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#status + # + # source://actionpack//lib/action_controller/metal.rb#196 def response_code(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal.rb#146 + # The ActionDispatch::Request::Session instance for the current request. + # See further details in the + # [Active Controller Session guide](https://guides.rubyonrails.org/action_controller_overview.html#session). + # + # source://actionpack//lib/action_controller/metal.rb#176 def session(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal.rb#197 + # source://actionpack//lib/action_controller/metal.rb#275 def set_request!(request); end - # source://actionpack//lib/action_controller/metal.rb#193 + # source://actionpack//lib/action_controller/metal.rb#257 def set_response!(response); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#status + # + # source://actionpack//lib/action_controller/metal.rb#196 def status(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal.rb#147 + # Delegates to ActionDispatch::Response#status= + # + # source://actionpack//lib/action_controller/metal.rb#184 def status=(arg); end - # source://actionpack//lib/action_controller/metal.rb#202 + # source://actionpack//lib/action_controller/metal.rb#280 def to_a; end - # Basic url_for that can be overridden for more robust functionality. + # Basic `url_for` that can be overridden for more robust functionality. # - # source://actionpack//lib/action_controller/metal.rb#168 + # source://actionpack//lib/action_controller/metal.rb#230 def url_for(string); end class << self # Returns a Rack endpoint for the given action name. # - # source://actionpack//lib/action_controller/metal.rb#231 + # source://actionpack//lib/action_controller/metal.rb#315 def action(name); end - # source://actionpack//lib/action_controller/metal.rb#136 + # source://actionpack//lib/action_controller/metal.rb#140 def action_encoding_template(action); end - # Returns the last part of the controller's name, underscored, without the ending - # Controller. For instance, PostsController returns posts. - # Namespaces are left out, so Admin::PostsController returns posts as well. + # Returns the last part of the controller's name, underscored, without the + # ending `Controller`. For instance, `PostsController` returns `posts`. + # Namespaces are left out, so `Admin::PostsController` returns `posts` as well. # - # ==== Returns - # * string + # #### Returns + # * `string` # - # source://actionpack//lib/action_controller/metal.rb#126 + # source://actionpack//lib/action_controller/metal.rb#130 def controller_name; end - # Direct dispatch to the controller. Instantiates the controller, then - # executes the action named +name+. + # Direct dispatch to the controller. Instantiates the controller, then executes + # the action named `name`. # - # source://actionpack//lib/action_controller/metal.rb#247 + # source://actionpack//lib/action_controller/metal.rb#331 def dispatch(name, req, res); end - # source://actionpack//lib/action_controller/metal.rb#212 - def inherited(base); end - - # source://actionpack//lib/action_controller/metal.rb#130 + # source://actionpack//lib/action_controller/metal.rb#134 def make_response!(request); end - # Alias for +middleware_stack+. + # The middleware stack used by this controller. + # + # By default uses a variation of ActionDispatch::MiddlewareStack which allows + # for the following syntax: + # + # class PostsController < ApplicationController + # use AuthenticationMiddleware, except: [:index, :show] + # end # - # source://actionpack//lib/action_controller/metal.rb#226 + # Read more about [Rails middleware stack] + # (https://guides.rubyonrails.org/rails_on_rack.html#action-dispatcher-middleware-stack) + # in the guides. + # + # source://actionpack//lib/action_controller/metal.rb#310 def middleware; end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack; end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack=(value); end - # source://actionpack//lib/action_controller/metal.rb#210 + # source://actionpack//lib/action_controller/metal.rb#288 def middleware_stack?; end # Pushes the given Rack middleware and its arguments to the bottom of the # middleware stack. # - # source://actionpack//lib/action_controller/metal.rb#220 + # source://actionpack//lib/action_controller/metal.rb#293 def use(*_arg0, **_arg1, &_arg2); end + + private + + # @private + # + # source://actionpack//lib/action_controller/metal.rb#146 + def inherited(subclass); end end end -# source://actionpack//lib/action_controller/metal/exceptions.rb#50 +# source://actionpack//lib/action_controller/metal/exceptions.rb#52 class ActionController::MethodNotAllowed < ::ActionController::ActionControllerError # @return [MethodNotAllowed] a new instance of MethodNotAllowed # - # source://actionpack//lib/action_controller/metal/exceptions.rb#51 + # source://actionpack//lib/action_controller/metal/exceptions.rb#53 def initialize(*allowed_methods); end end -# Extend ActionDispatch middleware stack to make it aware of options -# allowing the following syntax in controllers: +# # Action Controller MiddlewareStack # -# class PostsController < ApplicationController -# use AuthenticationMiddleware, except: [:index, :show] -# end +# Extend ActionDispatch middleware stack to make it aware of options allowing +# the following syntax in controllers: +# +# class PostsController < ApplicationController +# use AuthenticationMiddleware, except: [:index, :show] +# end # -# source://actionpack//lib/action_controller/metal.rb#14 +# source://actionpack//lib/action_controller/metal.rb#18 class ActionController::MiddlewareStack < ::ActionDispatch::MiddlewareStack - # source://actionpack//lib/action_controller/metal.rb#27 + # source://actionpack//lib/action_controller/metal.rb#31 def build(action, app = T.unsafe(nil), &block); end private - # source://actionpack//lib/action_controller/metal.rb#40 + # source://actionpack//lib/action_controller/metal.rb#44 def build_middleware(klass, args, block); end end -# source://actionpack//lib/action_controller/metal.rb#37 +# source://actionpack//lib/action_controller/metal.rb#41 ActionController::MiddlewareStack::EXCLUDE = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_controller/metal.rb#36 +# source://actionpack//lib/action_controller/metal.rb#40 ActionController::MiddlewareStack::INCLUDE = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_controller/metal.rb#15 +# source://actionpack//lib/action_controller/metal.rb#19 class ActionController::MiddlewareStack::Middleware < ::ActionDispatch::MiddlewareStack::Middleware # @return [Middleware] a new instance of Middleware # - # source://actionpack//lib/action_controller/metal.rb#16 + # source://actionpack//lib/action_controller/metal.rb#20 def initialize(klass, args, actions, strategy, block); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal.rb#22 + # source://actionpack//lib/action_controller/metal.rb#26 def valid?(action); end end -# source://actionpack//lib/action_controller/metal.rb#38 +# source://actionpack//lib/action_controller/metal.rb#42 ActionController::MiddlewareStack::NULL = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_controller/metal/mime_responds.rb#6 +# source://actionpack//lib/action_controller/metal/mime_responds.rb#8 module ActionController::MimeResponds - # Without web-service support, an action which collects the data for displaying a list of people - # might look something like this: + # Without web-service support, an action which collects the data for displaying + # a list of people might look something like this: # - # def index - # @people = Person.all - # end + # def index + # @people = Person.all + # end # - # That action implicitly responds to all formats, but formats can also be explicitly enumerated: + # That action implicitly responds to all formats, but formats can also be + # explicitly enumerated: # - # def index - # @people = Person.all - # respond_to :html, :js - # end + # def index + # @people = Person.all + # respond_to :html, :js + # end # # Here's the same action, with web-service support baked in: # - # def index - # @people = Person.all + # def index + # @people = Person.all # - # respond_to do |format| - # format.html - # format.js - # format.xml { render xml: @people } + # respond_to do |format| + # format.html + # format.js + # format.xml { render xml: @people } + # end # end - # end # - # What that says is, "if the client wants HTML or JS in response to this action, just respond as we - # would have before, but if the client wants XML, return them the list of people in XML format." - # (Rails determines the desired response format from the HTTP Accept header submitted by the client.) + # What that says is, "if the client wants HTML or JS in response to this action, + # just respond as we would have before, but if the client wants XML, return them + # the list of people in XML format." (Rails determines the desired response + # format from the HTTP Accept header submitted by the client.) # - # Supposing you have an action that adds a new person, optionally creating their company - # (by name) if it does not already exist, without web-services, it might look like this: + # Supposing you have an action that adds a new person, optionally creating their + # company (by name) if it does not already exist, without web-services, it might + # look like this: # - # def create - # @company = Company.find_or_create_by(name: params[:company][:name]) - # @person = @company.people.create(params[:person]) + # def create + # @company = Company.find_or_create_by(name: params[:company][:name]) + # @person = @company.people.create(params[:person]) # - # redirect_to(person_list_url) - # end + # redirect_to(person_list_url) + # end # # Here's the same action, with web-service support baked in: # - # def create - # company = params[:person].delete(:company) - # @company = Company.find_or_create_by(name: company[:name]) - # @person = @company.people.create(params[:person]) + # def create + # company = params[:person].delete(:company) + # @company = Company.find_or_create_by(name: company[:name]) + # @person = @company.people.create(params[:person]) # - # respond_to do |format| - # format.html { redirect_to(person_list_url) } - # format.js - # format.xml { render xml: @person.to_xml(include: @company) } + # respond_to do |format| + # format.html { redirect_to(person_list_url) } + # format.js + # format.xml { render xml: @person.to_xml(include: @company) } + # end # end - # end # - # If the client wants HTML, we just redirect them back to the person list. If they want JavaScript, - # then it is an Ajax request and we render the JavaScript template associated with this action. - # Lastly, if the client wants XML, we render the created person as XML, but with a twist: we also - # include the person's company in the rendered XML, so you get something like this: + # If the client wants HTML, we just redirect them back to the person list. If + # they want JavaScript, then it is an Ajax request and we render the JavaScript + # template associated with this action. Lastly, if the client wants XML, we + # render the created person as XML, but with a twist: we also include the + # person's company in the rendered XML, so you get something like this: # - # - # ... - # ... - # + # # ... - # ... # ... - # - # + # + # ... + # ... + # ... + # + # # # Note, however, the extra bit at the top of that action: # - # company = params[:person].delete(:company) - # @company = Company.find_or_create_by(name: company[:name]) + # company = params[:person].delete(:company) + # @company = Company.find_or_create_by(name: company[:name]) # - # This is because the incoming XML document (if a web-service request is in process) can only contain a - # single root-node. So, we have to rearrange things so that the request looks like this (url-encoded): + # This is because the incoming XML document (if a web-service request is in + # process) can only contain a single root-node. So, we have to rearrange things + # so that the request looks like this (url-encoded): # - # person[name]=...&person[company][name]=...&... + # person[name]=...&person[company][name]=...&... # # And, like this (xml-encoded): # - # - # ... - # + # # ... - # - # + # + # ... + # + # # - # In other words, we make the request so that it operates on a single entity's person. Then, in the action, - # we extract the company data from the request, find or create the company, and then create the new person - # with the remaining data. + # In other words, we make the request so that it operates on a single entity's + # person. Then, in the action, we extract the company data from the request, + # find or create the company, and then create the new person with the remaining + # data. # - # Note that you can define your own XML parameter parser which would allow you to describe multiple entities - # in a single request (i.e., by wrapping them all in a single root node), but if you just go with the flow - # and accept Rails' defaults, life will be much easier. + # Note that you can define your own XML parameter parser which would allow you + # to describe multiple entities in a single request (i.e., by wrapping them all + # in a single root node), but if you just go with the flow and accept Rails' + # defaults, life will be much easier. # - # If you need to use a MIME type which isn't supported by default, you can register your own handlers in - # +config/initializers/mime_types.rb+ as follows. + # If you need to use a MIME type which isn't supported by default, you can + # register your own handlers in `config/initializers/mime_types.rb` as follows. # - # Mime::Type.register "image/jpeg", :jpg + # Mime::Type.register "image/jpeg", :jpg # - # +respond_to+ also allows you to specify a common block for different formats by using +any+: + # `respond_to` also allows you to specify a common block for different formats + # by using `any`: # - # def index - # @people = Person.all + # def index + # @people = Person.all # - # respond_to do |format| - # format.html - # format.any(:xml, :json) { render request.format.to_sym => @people } + # respond_to do |format| + # format.html + # format.any(:xml, :json) { render request.format.to_sym => @people } + # end # end - # end # # In the example above, if the format is xml, it will render: # - # render xml: @people + # render xml: @people # # Or if the format is json: # - # render json: @people + # render json: @people # - # +any+ can also be used with no arguments, in which case it will be used for any format requested by - # the user: + # `any` can also be used with no arguments, in which case it will be used for + # any format requested by the user: # - # respond_to do |format| - # format.html - # format.any { redirect_to support_path } - # end + # respond_to do |format| + # format.html + # format.any { redirect_to support_path } + # end # # Formats can have different variants. # - # The request variant is a specialization of the request format, like :tablet, - # :phone, or :desktop. + # The request variant is a specialization of the request format, like `:tablet`, + # `:phone`, or `:desktop`. # - # We often want to render different html/json/xml templates for phones, - # tablets, and desktop browsers. Variants make it easy. + # We often want to render different html/json/xml templates for phones, tablets, + # and desktop browsers. Variants make it easy. # - # You can set the variant in a +before_action+: + # You can set the variant in a `before_action`: # - # request.variant = :tablet if /iPad/.match?(request.user_agent) + # request.variant = :tablet if /iPad/.match?(request.user_agent) # # Respond to variants in the action just like you respond to formats: # - # respond_to do |format| - # format.html do |variant| - # variant.tablet # renders app/views/projects/show.html+tablet.erb - # variant.phone { extra_setup; render ... } - # variant.none { special_setup } # executed only if there is no variant set + # respond_to do |format| + # format.html do |variant| + # variant.tablet # renders app/views/projects/show.html+tablet.erb + # variant.phone { extra_setup; render ... } + # variant.none { special_setup } # executed only if there is no variant set + # end # end - # end # # Provide separate templates for each format and variant: # - # app/views/projects/show.html.erb - # app/views/projects/show.html+tablet.erb - # app/views/projects/show.html+phone.erb + # app/views/projects/show.html.erb + # app/views/projects/show.html+tablet.erb + # app/views/projects/show.html+phone.erb # - # When you're not sharing any code within the format, you can simplify defining variants - # using the inline syntax: + # When you're not sharing any code within the format, you can simplify defining + # variants using the inline syntax: # - # respond_to do |format| - # format.js { render "trash" } - # format.html.phone { redirect_to progress_path } - # format.html.none { render "trash" } - # end + # respond_to do |format| + # format.js { render "trash" } + # format.html.phone { redirect_to progress_path } + # format.html.none { render "trash" } + # end # - # Variants also support common +any+/+all+ block that formats have. + # Variants also support common `any`/`all` block that formats have. # # It works for both inline: # - # respond_to do |format| - # format.html.any { render html: "any" } - # format.html.phone { render html: "phone" } - # end + # respond_to do |format| + # format.html.any { render html: "any" } + # format.html.phone { render html: "phone" } + # end # # and block syntax: # - # respond_to do |format| - # format.html do |variant| - # variant.any(:tablet, :phablet){ render html: "any" } - # variant.phone { render html: "phone" } + # respond_to do |format| + # format.html do |variant| + # variant.any(:tablet, :phablet){ render html: "any" } + # variant.phone { render html: "phone" } + # end # end - # end # # You can also set an array of variants: # - # request.variant = [:tablet, :phone] + # request.variant = [:tablet, :phone] # - # This will work similarly to formats and MIME types negotiation. If there - # is no +:tablet+ variant declared, the +:phone+ variant will be used: + # This will work similarly to formats and MIME types negotiation. If there is no + # `:tablet` variant declared, the `:phone` variant will be used: # - # respond_to do |format| - # format.html.none - # format.html.phone # this gets rendered - # end + # respond_to do |format| + # format.html.none + # format.html.phone # this gets rendered + # end # # @raise [ArgumentError] # @yield [collector] # - # source://actionpack//lib/action_controller/metal/mime_responds.rb#201 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#211 def respond_to(*mimes); end end -# A container for responses available from the current controller for -# requests for different mime-types sent to a particular action. +# A container for responses available from the current controller for requests +# for different mime-types sent to a particular action. # -# The public controller methods +respond_to+ may be called with a block -# that is used to define responses to different mime-types, e.g. -# for +respond_to+ : +# The public controller methods `respond_to` may be called with a block that is +# used to define responses to different mime-types, e.g. for `respond_to` : # -# respond_to do |format| -# format.html -# format.xml { render xml: @people } -# end +# respond_to do |format| +# format.html +# format.xml { render xml: @people } +# end # -# In this usage, the argument passed to the block (+format+ above) is an -# instance of the ActionController::MimeResponds::Collector class. This -# object serves as a container in which available responses can be stored by -# calling any of the dynamically generated, mime-type-specific methods such -# as +html+, +xml+ etc on the Collector. Each response is represented by a -# corresponding block if present. +# In this usage, the argument passed to the block (`format` above) is an +# instance of the ActionController::MimeResponds::Collector class. This object +# serves as a container in which available responses can be stored by calling +# any of the dynamically generated, mime-type-specific methods such as `html`, +# `xml` etc on the Collector. Each response is represented by a corresponding +# block if present. # -# A subsequent call to #negotiate_format(request) will enable the Collector -# to determine which specific mime-type it should respond with for the current +# A subsequent call to #negotiate_format(request) will enable the Collector to +# determine which specific mime-type it should respond with for the current # request, with this response then being accessible by calling #response. # -# source://actionpack//lib/action_controller/metal/mime_responds.rb#242 +# source://actionpack//lib/action_controller/metal/mime_responds.rb#251 class ActionController::MimeResponds::Collector include ::AbstractController::Collector # @return [Collector] a new instance of Collector # - # source://actionpack//lib/action_controller/metal/mime_responds.rb#246 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#255 def initialize(mimes, variant = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#253 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#262 def all(*args, &block); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#253 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#262 def any(*args, &block); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/mime_responds.rb#271 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#280 def any_response?; end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#262 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#271 def custom(mime_type, &block); end # Returns the value of attribute format. # - # source://actionpack//lib/action_controller/metal/mime_responds.rb#244 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#253 def format; end # Sets the attribute format # # @param value the value to set the attribute format to. # - # source://actionpack//lib/action_controller/metal/mime_responds.rb#244 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#253 def format=(_arg0); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#288 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#297 def negotiate_format(request); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#275 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#284 def response; end end -# source://actionpack//lib/action_controller/metal/mime_responds.rb#292 +# source://actionpack//lib/action_controller/metal/mime_responds.rb#301 class ActionController::MimeResponds::Collector::VariantCollector # @return [VariantCollector] a new instance of VariantCollector # - # source://actionpack//lib/action_controller/metal/mime_responds.rb#293 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#302 def initialize(variant = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#298 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#307 def all(*args, &block); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#298 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#307 def any(*args, &block); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#309 - def method_missing(name, *args, &block); end + # source://actionpack//lib/action_controller/metal/mime_responds.rb#318 + def method_missing(name, *_arg1, &block); end - # source://actionpack//lib/action_controller/metal/mime_responds.rb#313 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#322 def variant; end private - # source://actionpack//lib/action_controller/metal/mime_responds.rb#322 + # source://actionpack//lib/action_controller/metal/mime_responds.rb#331 def variant_key; end end -# source://actionpack//lib/action_controller/metal/exceptions.rb#94 -class ActionController::MissingExactTemplate < ::ActionController::UnknownFormat; end +# source://actionpack//lib/action_controller/metal/exceptions.rb#96 +class ActionController::MissingExactTemplate < ::ActionController::UnknownFormat + # @return [MissingExactTemplate] a new instance of MissingExactTemplate + # + # source://actionpack//lib/action_controller/metal/exceptions.rb#99 + def initialize(message, controller, action_name); end + + # Returns the value of attribute action_name. + # + # source://actionpack//lib/action_controller/metal/exceptions.rb#97 + def action_name; end + + # Returns the value of attribute controller. + # + # source://actionpack//lib/action_controller/metal/exceptions.rb#97 + def controller; end +end -# source://actionpack//lib/action_controller/metal/exceptions.rb#59 +# source://actionpack//lib/action_controller/metal/exceptions.rb#61 class ActionController::MissingFile < ::ActionController::ActionControllerError; end -# See Responder#api_behavior +# See `Responder#api_behavior` # -# source://actionpack//lib/action_controller/metal/renderers.rb#17 +# source://actionpack//lib/action_controller/metal/renderers.rb#19 class ActionController::MissingRenderer < ::LoadError # @return [MissingRenderer] a new instance of MissingRenderer # - # source://actionpack//lib/action_controller/metal/renderers.rb#18 + # source://actionpack//lib/action_controller/metal/renderers.rb#20 def initialize(format); end end -# source://actionpack//lib/action_controller/metal/exceptions.rb#56 +# source://actionpack//lib/action_controller/metal/exceptions.rb#58 class ActionController::NotImplemented < ::ActionController::MethodNotAllowed; end # Specify binary encoding for parameters for a given action. # -# source://actionpack//lib/action_controller/metal/parameter_encoding.rb#5 +# source://actionpack//lib/action_controller/metal/parameter_encoding.rb#7 module ActionController::ParameterEncoding extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionController::ParameterEncoding::ClassMethods end -# source://actionpack//lib/action_controller/metal/parameter_encoding.rb#8 +# source://actionpack//lib/action_controller/metal/parameter_encoding.rb#10 module ActionController::ParameterEncoding::ClassMethods - # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#18 + # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#20 def action_encoding_template(action); end - # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#9 + # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#11 def inherited(klass); end - # Specify the encoding for a parameter on an action. - # If not specified the default is UTF-8. + # Specify the encoding for a parameter on an action. If not specified the + # default is UTF-8. # # You can specify a binary (ASCII_8BIT) parameter with: # - # class RepositoryController < ActionController::Base - # # This specifies that file_path is not UTF-8 and is instead ASCII_8BIT - # param_encoding :show, :file_path, Encoding::ASCII_8BIT + # class RepositoryController < ActionController::Base + # # This specifies that file_path is not UTF-8 and is instead ASCII_8BIT + # param_encoding :show, :file_path, Encoding::ASCII_8BIT # - # def show - # @repo = Repository.find_by_filesystem_path params[:file_path] + # def show + # @repo = Repository.find_by_filesystem_path params[:file_path] # - # # params[:repo_name] remains UTF-8 encoded - # @repo_name = params[:repo_name] - # end + # # params[:repo_name] remains UTF-8 encoded + # @repo_name = params[:repo_name] + # end # - # def index - # @repositories = Repository.all + # def index + # @repositories = Repository.all + # end # end - # end # - # The file_path parameter on the show action would be encoded as ASCII-8BIT, - # but all other arguments will remain UTF-8 encoded. - # This is useful in the case where an application must handle data - # but encoding of the data is unknown, like file system data. + # The file_path parameter on the show action would be encoded as ASCII-8BIT, but + # all other arguments will remain UTF-8 encoded. This is useful in the case + # where an application must handle data but encoding of the data is unknown, + # like file system data. # - # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#77 + # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#79 def param_encoding(action, param, encoding); end - # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#14 + # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#16 def setup_param_encode; end - # Specify that a given action's parameters should all be encoded as - # ASCII-8BIT (it "skips" the encoding default of UTF-8). + # Specify that a given action's parameters should all be encoded as ASCII-8BIT + # (it "skips" the encoding default of UTF-8). # # For example, a controller would use it like this: # - # class RepositoryController < ActionController::Base - # skip_parameter_encoding :show + # class RepositoryController < ActionController::Base + # skip_parameter_encoding :show # - # def show - # @repo = Repository.find_by_filesystem_path params[:file_path] + # def show + # @repo = Repository.find_by_filesystem_path params[:file_path] # - # # `repo_name` is guaranteed to be UTF-8, but was ASCII-8BIT, so - # # tag it as such - # @repo_name = params[:repo_name].force_encoding 'UTF-8' - # end + # # `repo_name` is guaranteed to be UTF-8, but was ASCII-8BIT, so + # # tag it as such + # @repo_name = params[:repo_name].force_encoding 'UTF-8' + # end # - # def index - # @repositories = Repository.all + # def index + # @repositories = Repository.all + # end # end - # end # # The show action in the above controller would have all parameter values - # encoded as ASCII-8BIT. This is useful in the case where an application - # must handle data but encoding of the data is unknown, like file system data. + # encoded as ASCII-8BIT. This is useful in the case where an application must + # handle data but encoding of the data is unknown, like file system data. # - # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#48 + # source://actionpack//lib/action_controller/metal/parameter_encoding.rb#50 def skip_parameter_encoding(action); end end # Raised when a required parameter is missing. # -# params = ActionController::Parameters.new(a: {}) -# params.fetch(:b) -# # => ActionController::ParameterMissing: param is missing or the value is empty: b -# params.require(:a) -# # => ActionController::ParameterMissing: param is missing or the value is empty: a +# params = ActionController::Parameters.new(a: {}) +# params.fetch(:b) +# # => ActionController::ParameterMissing: param is missing or the value is empty: b +# params.require(:a) +# # => ActionController::ParameterMissing: param is missing or the value is empty: a # -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#21 +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#24 class ActionController::ParameterMissing < ::KeyError # @return [ParameterMissing] a new instance of ParameterMissing # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#24 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#27 def initialize(param, keys = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#33 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#36 def corrections; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#22 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#25 def keys; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#22 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#25 def param; end end -# == Action Controller \Parameters +# # Action Controller Parameters # # Allows you to choose which attributes should be permitted for mass updating # and thus prevent accidentally exposing that which shouldn't be exposed. @@ -4920,944 +5311,1007 @@ end # used to mark parameters as required. The latter is used to set the parameter # as permitted and limit which attributes should be allowed for mass updating. # -# params = ActionController::Parameters.new({ -# person: { -# name: "Francesco", -# age: 22, -# role: "admin" -# } -# }) +# params = ActionController::Parameters.new({ +# person: { +# name: "Francesco", +# age: 22, +# role: "admin" +# } +# }) # -# permitted = params.require(:person).permit(:name, :age) -# permitted # => #"Francesco", "age"=>22} permitted: true> -# permitted.permitted? # => true +# permitted = params.require(:person).permit(:name, :age) +# permitted # => #"Francesco", "age"=>22} permitted: true> +# permitted.permitted? # => true # -# Person.first.update!(permitted) -# # => # +# Person.first.update!(permitted) +# # => # # # It provides two options that controls the top-level behavior of new instances: # -# * +permit_all_parameters+ - If it's +true+, all the parameters will be -# permitted by default. The default is +false+. -# * +action_on_unpermitted_parameters+ - Controls behavior when parameters that are not explicitly -# permitted are found. The default value is :log in test and development environments, -# +false+ otherwise. The values can be: -# * +false+ to take no action. -# * :log to emit an ActiveSupport::Notifications.instrument event on the -# unpermitted_parameters.action_controller topic and log at the DEBUG level. -# * :raise to raise a ActionController::UnpermittedParameters exception. +# * `permit_all_parameters` - If it's `true`, all the parameters will be +# permitted by default. The default is `false`. +# * `action_on_unpermitted_parameters` - Controls behavior when parameters +# that are not explicitly permitted are found. The default value is `:log` +# in test and development environments, `false` otherwise. The values can +# be: +# * `false` to take no action. +# * `:log` to emit an `ActiveSupport::Notifications.instrument` event on +# the `unpermitted_parameters.action_controller` topic and log at the +# DEBUG level. +# * `:raise` to raise an ActionController::UnpermittedParameters +# exception. +# +# # # Examples: # -# params = ActionController::Parameters.new -# params.permitted? # => false +# params = ActionController::Parameters.new +# params.permitted? # => false # -# ActionController::Parameters.permit_all_parameters = true +# ActionController::Parameters.permit_all_parameters = true # -# params = ActionController::Parameters.new -# params.permitted? # => true +# params = ActionController::Parameters.new +# params.permitted? # => true # -# params = ActionController::Parameters.new(a: "123", b: "456") -# params.permit(:c) -# # => # +# params = ActionController::Parameters.new(a: "123", b: "456") +# params.permit(:c) +# # => # # -# ActionController::Parameters.action_on_unpermitted_parameters = :raise +# ActionController::Parameters.action_on_unpermitted_parameters = :raise # -# params = ActionController::Parameters.new(a: "123", b: "456") -# params.permit(:c) -# # => ActionController::UnpermittedParameters: found unpermitted keys: a, b +# params = ActionController::Parameters.new(a: "123", b: "456") +# params.permit(:c) +# # => ActionController::UnpermittedParameters: found unpermitted keys: a, b # # Please note that these options *are not thread-safe*. In a multi-threaded # environment they should only be set once at boot-time and never mutated at # runtime. # -# You can fetch values of ActionController::Parameters using either -# :key or "key". +# You can fetch values of `ActionController::Parameters` using either `:key` or +# `"key"`. # -# params = ActionController::Parameters.new(key: "value") -# params[:key] # => "value" -# params["key"] # => "value" +# params = ActionController::Parameters.new(key: "value") +# params[:key] # => "value" +# params["key"] # => "value" # -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#132 +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#147 class ActionController::Parameters - # Returns a new instance of ActionController::Parameters. - # Also, sets the +permitted+ attribute to the default value of - # ActionController::Parameters.permit_all_parameters. + include ::ActiveSupport::DeepMergeable + + # Returns a new `ActionController::Parameters` instance. Also, sets the + # `permitted` attribute to the default value of + # `ActionController::Parameters.permit_all_parameters`. # - # class Person < ActiveRecord::Base - # end + # class Person < ActiveRecord::Base + # end # - # params = ActionController::Parameters.new(name: "Francesco") - # params.permitted? # => false - # Person.new(params) # => ActiveModel::ForbiddenAttributesError + # params = ActionController::Parameters.new(name: "Francesco") + # params.permitted? # => false + # Person.new(params) # => ActiveModel::ForbiddenAttributesError # - # ActionController::Parameters.permit_all_parameters = true + # ActionController::Parameters.permit_all_parameters = true # - # params = ActionController::Parameters.new(name: "Francesco") - # params.permitted? # => true - # Person.new(params) # => # + # params = ActionController::Parameters.new(name: "Francesco") + # params.permitted? # => true + # Person.new(params) # => # # # @return [Parameters] a new instance of Parameters # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#267 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#288 def initialize(parameters = T.unsafe(nil), logging_context = T.unsafe(nil)); end - # Returns true if another +Parameters+ object contains the same content and + # Returns true if another `Parameters` object contains the same content and # permitted flag. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#275 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#302 def ==(other); end - # Returns a parameter for the given +key+. If not found, - # returns +nil+. + # Returns a parameter for the given `key`. If not found, returns `nil`. # - # params = ActionController::Parameters.new(person: { name: "Francesco" }) - # params[:person] # => #"Francesco"} permitted: false> - # params[:none] # => nil + # params = ActionController::Parameters.new(person: { name: "Francesco" }) + # params[:person] # => #"Francesco"} permitted: false> + # params[:none] # => nil # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#643 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#670 def [](key); end - # Assigns a value to a given +key+. The given key may still get filtered out - # when +permit+ is called. + # Assigns a value to a given `key`. The given key may still get filtered out + # when #permit is called. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#649 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#676 def []=(key, value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#243 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#250 def always_permitted_parameters; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#243 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#250 def always_permitted_parameters=(val); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def as_json(*_arg0, **_arg1, &_arg2); end - # Returns a new instance of ActionController::Parameters with +nil+ values removed. + # Returns a new `ActionController::Parameters` instance with `nil` values + # removed. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#819 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#847 def compact; end - # Removes all +nil+ values in place and returns +self+, or +nil+ if no changes were made. + # Removes all `nil` values in place and returns `self`, or `nil` if no changes + # were made. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#824 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#853 def compact!; end - # Returns a new instance of ActionController::Parameters without the blank values. - # Uses Object#blank? for determining if a value is blank. + # Returns a new `ActionController::Parameters` instance without the blank + # values. Uses Object#blank? for determining if a value is blank. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#830 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#859 def compact_blank; end - # Removes all blank values in place and returns self. - # Uses Object#blank? for determining if a value is blank. + # Removes all blank values in place and returns self. Uses Object#blank? for + # determining if a value is blank. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#836 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#865 def compact_blank!; end # Attribute that keeps track of converted arrays, if any, to avoid double - # looping in the common use case permit + mass-assignment. Defined in a - # method to instantiate it only if needed. + # looping in the common use case permit + mass-assignment. Defined in a method + # to instantiate it only if needed. # - # Testing membership still loops, but it's going to be faster than our own - # loop that converts values. Also, we are not going to build a new array - # object per fetch. + # Testing membership still loops, but it's going to be faster than our own loop + # that converts values. Also, we are not going to build a new array object per + # fetch. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#407 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#436 def converted_arrays; end - # Returns duplicate of object including all parameters. + # Returns a duplicate `ActionController::Parameters` instance with the same + # permitted parameters. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#921 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#965 def deep_dup; end - # Returns a new ActionController::Parameters instance with the - # results of running +block+ once for every key. This includes the keys - # from the root hash and from all nested hashes and arrays. The values are unchanged. + # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#770 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#900 + def deep_merge?(other_hash); end + + # Returns a new `ActionController::Parameters` instance with the results of + # running `block` once for every key. This includes the keys from the root hash + # and from all nested hashes and arrays. The values are unchanged. + # + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#797 def deep_transform_keys(&block); end - # Returns the ActionController::Parameters instance changing its keys. - # This includes the keys from the root hash and from all nested hashes and arrays. - # The values are unchanged. + # Returns the same `ActionController::Parameters` instance with changed keys. + # This includes the keys from the root hash and from all nested hashes and + # arrays. The values are unchanged. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#779 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#806 def deep_transform_keys!(&block); end - # Deletes a key-value pair from +Parameters+ and returns the value. If - # +key+ is not found, returns +nil+ (or, with optional code block, yields - # +key+ and returns the result). Cf. #extract!, which returns the - # corresponding +ActionController::Parameters+ object. + # Deletes a key-value pair from `Parameters` and returns the value. If `key` is + # not found, returns `nil` (or, with optional code block, yields `key` and + # returns the result). This method is similar to #extract!, which returns the + # corresponding `ActionController::Parameters` object. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#788 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#815 def delete(key, &block); end # Removes items that the block evaluates to true and returns self. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#812 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#839 def delete_if(&block); end - # Extracts the nested parameter from the given +keys+ by calling +dig+ - # at each step. Returns +nil+ if any intermediate step is +nil+. + # Extracts the nested parameter from the given `keys` by calling `dig` at each + # step. Returns `nil` if any intermediate step is `nil`. # - # params = ActionController::Parameters.new(foo: { bar: { baz: 1 } }) - # params.dig(:foo, :bar, :baz) # => 1 - # params.dig(:foo, :zot, :xyz) # => nil + # params = ActionController::Parameters.new(foo: { bar: { baz: 1 } }) + # params.dig(:foo, :bar, :baz) # => 1 + # params.dig(:foo, :zot, :xyz) # => nil # - # params2 = ActionController::Parameters.new(foo: [10, 11, 12]) - # params2.dig(:foo, 1) # => 11 + # params2 = ActionController::Parameters.new(foo: [10, 11, 12]) + # params2.dig(:foo, 1) # => 11 # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#687 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#714 def dig(*keys); end - # Convert all hashes in values into parameters, then yield each pair in - # the same way as Hash#each_pair. + # Convert all hashes in values into parameters, then yield each pair in the same + # way as `Hash#each_pair`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#379 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#403 def each(&block); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def each_key(*_arg0, **_arg1, &_arg2); end - # Convert all hashes in values into parameters, then yield each pair in - # the same way as Hash#each_pair. + # Convert all hashes in values into parameters, then yield each pair in the same + # way as `Hash#each_pair`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#379 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#403 def each_pair(&block); end - # Convert all hashes in values into parameters, then yield each value in - # the same way as Hash#each_value. + # Convert all hashes in values into parameters, then yield each value in the + # same way as `Hash#each_value`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#391 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#415 def each_value(&block); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def empty?(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#916 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#959 def encode_with(coder); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#283 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#310 def eql?(other); end - # Returns a new ActionController::Parameters instance that - # filters out the given +keys+. + # Returns a new `ActionController::Parameters` instance that filters out the + # given `keys`. # - # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) - # params.except(:a, :b) # => #3} permitted: false> - # params.except(:d) # => #1, "b"=>2, "c"=>3} permitted: false> + # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) + # params.except(:a, :b) # => #3} permitted: false> + # params.except(:d) # => #1, "b"=>2, "c"=>3} permitted: false> # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#716 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#742 def except(*keys); end + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 + def exclude?(*_arg0, **_arg1, &_arg2); end + # Removes and returns the key/value pairs matching the given keys. # - # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) - # params.extract!(:a, :b) # => #1, "b"=>2} permitted: false> - # params # => #3} permitted: false> + # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) + # params.extract!(:a, :b) # => #1, "b"=>2} permitted: false> + # params # => #3} permitted: false> # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#725 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#752 def extract!(*keys); end - # Returns a parameter for the given +key+. If the +key+ - # can't be found, there are several options: With no other arguments, - # it will raise an ActionController::ParameterMissing error; - # if a second argument is given, then that is returned (converted to an - # instance of ActionController::Parameters if possible); if a block - # is given, then that will be run and its result returned. - # - # params = ActionController::Parameters.new(person: { name: "Francesco" }) - # params.fetch(:person) # => #"Francesco"} permitted: false> - # params.fetch(:none) # => ActionController::ParameterMissing: param is missing or the value is empty: none - # params.fetch(:none, {}) # => # - # params.fetch(:none, "Francesco") # => "Francesco" - # params.fetch(:none) { "Francesco" } # => "Francesco" - # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#666 + # Returns parameter value for the given `key` separated by `delimiter`. + # + # params = ActionController::Parameters.new(id: "1_123", tags: "ruby,rails") + # params.extract_value(:id) # => ["1", "123"] + # params.extract_value(:tags, delimiter: ",") # => ["ruby", "rails"] + # params.extract_value(:non_existent_key) # => nil + # + # Note that if the given `key`'s value contains blank elements, then the + # returned array will include empty strings. + # + # params = ActionController::Parameters.new(tags: "ruby,rails,,web") + # params.extract_value(:tags, delimiter: ",") # => ["ruby", "rails", "", "web"] + # + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#983 + def extract_value(key, delimiter: T.unsafe(nil)); end + + # Returns a parameter for the given `key`. If the `key` can't be found, there + # are several options: With no other arguments, it will raise an + # ActionController::ParameterMissing error; if a second argument is given, then + # that is returned (converted to an instance of `ActionController::Parameters` + # if possible); if a block is given, then that will be run and its result + # returned. + # + # params = ActionController::Parameters.new(person: { name: "Francesco" }) + # params.fetch(:person) # => #"Francesco"} permitted: false> + # params.fetch(:none) # => ActionController::ParameterMissing: param is missing or the value is empty: none + # params.fetch(:none, {}) # => # + # params.fetch(:none, "Francesco") # => "Francesco" + # params.fetch(:none) { "Francesco" } # => "Francesco" + # + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#693 def fetch(key, *args); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def has_key?(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 - def has_value?(*_arg0, **_arg1, &_arg2); end + # Returns true if the given value is present for some key in the parameters. + # + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#870 + def has_value?(value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#289 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#316 def hash; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def include?(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#898 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#941 def init_with(coder); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#885 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#928 def inspect; end - # Equivalent to Hash#keep_if, but returns +nil+ if no changes were made. + # Equivalent to Hash#keep_if, but returns `nil` if no changes were made. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#799 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#826 def keep_if(&block); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def key?(*_arg0, **_arg1, &_arg2); end - # :method: values + # :method: to_s # # :call-seq: - # values() + # to_s() # - # Returns a new array of the values of the parameters. + # Returns the content of the parameters as a string. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def keys(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def member?(*_arg0, **_arg1, &_arg2); end - # Returns a new ActionController::Parameters with all keys from - # +other_hash+ merged into current hash. + # Returns a new `ActionController::Parameters` instance with all keys from + # `other_hash` merged into current hash. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#848 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#884 def merge(other_hash); end - # Returns current ActionController::Parameters instance with - # +other_hash+ merged into current hash. + # :call-seq: merge!(other_hash) + # + # Returns the current `ActionController::Parameters` instance with `other_hash` + # merged into current hash. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#856 - def merge!(other_hash); end + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#895 + def merge!(other_hash, &block); end - # Returns a new ActionController::Parameters instance that - # includes only the given +filters+ and sets the +permitted+ attribute - # for the object to +true+. This is useful for limiting which attributes - # should be allowed for mass updating. + # Returns a new `ActionController::Parameters` instance that includes only the + # given `filters` and sets the `permitted` attribute for the object to `true`. + # This is useful for limiting which attributes should be allowed for mass + # updating. # - # params = ActionController::Parameters.new(user: { name: "Francesco", age: 22, role: "admin" }) - # permitted = params.require(:user).permit(:name, :age) - # permitted.permitted? # => true - # permitted.has_key?(:name) # => true - # permitted.has_key?(:age) # => true - # permitted.has_key?(:role) # => false + # params = ActionController::Parameters.new(user: { name: "Francesco", age: 22, role: "admin" }) + # permitted = params.require(:user).permit(:name, :age) + # permitted.permitted? # => true + # permitted.has_key?(:name) # => true + # permitted.has_key?(:age) # => true + # permitted.has_key?(:role) # => false # # Only permitted scalars pass the filter. For example, given # - # params.permit(:name) + # params.permit(:name) # - # +:name+ passes if it is a key of +params+ whose associated value is of type - # +String+, +Symbol+, +NilClass+, +Numeric+, +TrueClass+, +FalseClass+, - # +Date+, +Time+, +DateTime+, +StringIO+, +IO+, - # +ActionDispatch::Http::UploadedFile+ or +Rack::Test::UploadedFile+. - # Otherwise, the key +:name+ is filtered out. + # `:name` passes if it is a key of `params` whose associated value is of type + # `String`, `Symbol`, `NilClass`, `Numeric`, `TrueClass`, `FalseClass`, `Date`, + # `Time`, `DateTime`, `StringIO`, `IO`, ActionDispatch::Http::UploadedFile or + # `Rack::Test::UploadedFile`. Otherwise, the key `:name` is filtered out. # - # You may declare that the parameter should be an array of permitted scalars - # by mapping it to an empty array: + # You may declare that the parameter should be an array of permitted scalars by + # mapping it to an empty array: # - # params = ActionController::Parameters.new(tags: ["rails", "parameters"]) - # params.permit(tags: []) + # params = ActionController::Parameters.new(tags: ["rails", "parameters"]) + # params.permit(tags: []) # - # Sometimes it is not possible or convenient to declare the valid keys of - # a hash parameter or its internal structure. Just map to an empty hash: + # Sometimes it is not possible or convenient to declare the valid keys of a hash + # parameter or its internal structure. Just map to an empty hash: # - # params.permit(preferences: {}) + # params.permit(preferences: {}) # - # Be careful because this opens the door to arbitrary input. In this - # case, +permit+ ensures values in the returned structure are permitted - # scalars and filters out anything else. + # Be careful because this opens the door to arbitrary input. In this case, + # `permit` ensures values in the returned structure are permitted scalars and + # filters out anything else. # - # You can also use +permit+ on nested parameters, like: + # You can also use `permit` on nested parameters, like: # - # params = ActionController::Parameters.new({ - # person: { - # name: "Francesco", - # age: 22, - # pets: [{ - # name: "Purplish", - # category: "dogs" - # }] - # } - # }) - # - # permitted = params.permit(person: [ :name, { pets: :name } ]) - # permitted.permitted? # => true - # permitted[:person][:name] # => "Francesco" - # permitted[:person][:age] # => nil - # permitted[:person][:pets][0][:name] # => "Purplish" - # permitted[:person][:pets][0][:category] # => nil - # - # Note that if you use +permit+ in a key that points to a hash, - # it won't allow all the hash. You also need to specify which - # attributes inside the hash should be permitted. - # - # params = ActionController::Parameters.new({ - # person: { - # contact: { - # email: "none@test.com", - # phone: "555-1234" + # params = ActionController::Parameters.new({ + # person: { + # name: "Francesco", + # age: 22, + # pets: [{ + # name: "Purplish", + # category: "dogs" + # }] # } - # } - # }) - # - # params.require(:person).permit(:contact) - # # => # - # - # params.require(:person).permit(contact: :phone) - # # => ##"555-1234"} permitted: true>} permitted: true> - # - # params.require(:person).permit(contact: [ :email, :phone ]) - # # => ##"none@test.com", "phone"=>"555-1234"} permitted: true>} permitted: true> - # - # If your parameters specify multiple parameters indexed by a number, - # you can permit each set of parameters under the numeric key to be the same using the same syntax as permitting a single item. - # - # params = ActionController::Parameters.new({ - # person: { - # '0': { - # email: "none@test.com", - # phone: "555-1234" - # }, - # '1': { - # email: "nothing@test.com", - # phone: "555-6789" - # }, - # } - # }) - # params.permit(person: [:email]).to_h - # # => {"person"=>{"0"=>{"email"=>"none@test.com"}, "1"=>{"email"=>"nothing@test.com"}}} - # - # If you want to specify what keys you want from each numeric key, you can instead specify each one individually - # - # params = ActionController::Parameters.new({ - # person: { - # '0': { - # email: "none@test.com", - # phone: "555-1234" - # }, - # '1': { - # email: "nothing@test.com", - # phone: "555-6789" - # }, - # } - # }) - # params.permit(person: { '0': [:email], '1': [:phone]}).to_h - # # => {"person"=>{"0"=>{"email"=>"none@test.com"}, "1"=>{"phone"=>"555-6789"}}} + # }) + # + # permitted = params.permit(person: [ :name, { pets: :name } ]) + # permitted.permitted? # => true + # permitted[:person][:name] # => "Francesco" + # permitted[:person][:age] # => nil + # permitted[:person][:pets][0][:name] # => "Purplish" + # permitted[:person][:pets][0][:category] # => nil + # + # Note that if you use `permit` in a key that points to a hash, it won't allow + # all the hash. You also need to specify which attributes inside the hash should + # be permitted. + # + # params = ActionController::Parameters.new({ + # person: { + # contact: { + # email: "none@test.com", + # phone: "555-1234" + # } + # } + # }) + # + # params.require(:person).permit(:contact) + # # => # + # + # params.require(:person).permit(contact: :phone) + # # => ##"555-1234"} permitted: true>} permitted: true> + # + # params.require(:person).permit(contact: [ :email, :phone ]) + # # => ##"none@test.com", "phone"=>"555-1234"} permitted: true>} permitted: true> + # + # If your parameters specify multiple parameters indexed by a number, you can + # permit each set of parameters under the numeric key to be the same using the + # same syntax as permitting a single item. + # + # params = ActionController::Parameters.new({ + # person: { + # '0': { + # email: "none@test.com", + # phone: "555-1234" + # }, + # '1': { + # email: "nothing@test.com", + # phone: "555-6789" + # }, + # } + # }) + # params.permit(person: [:email]).to_h + # # => {"person"=>{"0"=>{"email"=>"none@test.com"}, "1"=>{"email"=>"nothing@test.com"}}} + # + # If you want to specify what keys you want from each numeric key, you can + # instead specify each one individually + # + # params = ActionController::Parameters.new({ + # person: { + # '0': { + # email: "none@test.com", + # phone: "555-1234" + # }, + # '1': { + # email: "nothing@test.com", + # phone: "555-6789" + # }, + # } + # }) + # params.permit(person: { '0': [:email], '1': [:phone]}).to_h + # # => {"person"=>{"0"=>{"email"=>"none@test.com"}, "1"=>{"phone"=>"555-6789"}}} # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#620 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#648 def permit(*filters); end - # Sets the +permitted+ attribute to +true+. This can be used to pass - # mass assignment. Returns +self+. + # Sets the `permitted` attribute to `true`. This can be used to pass mass + # assignment. Returns `self`. # - # class Person < ActiveRecord::Base - # end + # class Person < ActiveRecord::Base + # end # - # params = ActionController::Parameters.new(name: "Francesco") - # params.permitted? # => false - # Person.new(params) # => ActiveModel::ForbiddenAttributesError - # params.permit! - # params.permitted? # => true - # Person.new(params) # => # + # params = ActionController::Parameters.new(name: "Francesco") + # params.permitted? # => false + # Person.new(params) # => ActiveModel::ForbiddenAttributesError + # params.permit! + # params.permitted? # => true + # Person.new(params) # => # # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#433 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#462 def permit!; end - # Returns +true+ if the parameter is permitted, +false+ otherwise. + # Returns `true` if the parameter is permitted, `false` otherwise. # - # params = ActionController::Parameters.new - # params.permitted? # => false - # params.permit! - # params.permitted? # => true + # params = ActionController::Parameters.new + # params.permitted? # => false + # params.permit! + # params.permitted? # => true # # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#417 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#446 def permitted?; end - # Returns a new instance of ActionController::Parameters with items - # that the block evaluates to true removed. + # Returns a new `ActionController::Parameters` instance with items that the + # block evaluates to true removed. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#807 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#834 def reject(&block); end # Removes items that the block evaluates to true and returns self. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#812 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#839 def reject!(&block); end # This method accepts both a single key and an array of keys. # - # When passed a single key, if it exists and its associated value is - # either present or the singleton +false+, returns said value: + # When passed a single key, if it exists and its associated value is either + # present or the singleton `false`, returns said value: # - # ActionController::Parameters.new(person: { name: "Francesco" }).require(:person) - # # => #"Francesco"} permitted: false> + # ActionController::Parameters.new(person: { name: "Francesco" }).require(:person) + # # => #"Francesco"} permitted: false> # - # Otherwise raises ActionController::ParameterMissing: + # Otherwise raises ActionController::ParameterMissing: # - # ActionController::Parameters.new.require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new.require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # ActionController::Parameters.new(person: nil).require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new(person: nil).require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # ActionController::Parameters.new(person: "\t").require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new(person: "\t").require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # ActionController::Parameters.new(person: {}).require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new(person: {}).require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # When given an array of keys, the method tries to require each one of them - # in order. If it succeeds, an array with the respective return values is - # returned: + # When given an array of keys, the method tries to require each one of them in + # order. If it succeeds, an array with the respective return values is returned: # - # params = ActionController::Parameters.new(user: { ... }, profile: { ... }) - # user_params, profile_params = params.require([:user, :profile]) + # params = ActionController::Parameters.new(user: { ... }, profile: { ... }) + # user_params, profile_params = params.require([:user, :profile]) # # Otherwise, the method re-raises the first exception found: # - # params = ActionController::Parameters.new(user: {}, profile: {}) - # user_params, profile_params = params.require([:user, :profile]) - # # ActionController::ParameterMissing: param is missing or the value is empty: user + # params = ActionController::Parameters.new(user: {}, profile: {}) + # user_params, profile_params = params.require([:user, :profile]) + # # ActionController::ParameterMissing: param is missing or the value is empty: user # # Technically this method can be used to fetch terminal values: # - # # CAREFUL - # params = ActionController::Parameters.new(person: { name: "Finn" }) - # name = params.require(:person).require(:name) # CAREFUL + # # CAREFUL + # params = ActionController::Parameters.new(person: { name: "Finn" }) + # name = params.require(:person).require(:name) # CAREFUL # # but take into account that at some point those ones have to be permitted: # - # def person_params - # params.require(:person).permit(:name).tap do |person_params| - # person_params.require(:name) # SAFER + # def person_params + # params.require(:person).permit(:name).tap do |person_params| + # person_params.require(:name) # SAFER + # end # end - # end # # for example. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#494 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#522 def require(key); end # This method accepts both a single key and an array of keys. # - # When passed a single key, if it exists and its associated value is - # either present or the singleton +false+, returns said value: + # When passed a single key, if it exists and its associated value is either + # present or the singleton `false`, returns said value: # - # ActionController::Parameters.new(person: { name: "Francesco" }).require(:person) - # # => #"Francesco"} permitted: false> + # ActionController::Parameters.new(person: { name: "Francesco" }).require(:person) + # # => #"Francesco"} permitted: false> # - # Otherwise raises ActionController::ParameterMissing: + # Otherwise raises ActionController::ParameterMissing: # - # ActionController::Parameters.new.require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new.require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # ActionController::Parameters.new(person: nil).require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new(person: nil).require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # ActionController::Parameters.new(person: "\t").require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new(person: "\t").require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # ActionController::Parameters.new(person: {}).require(:person) - # # ActionController::ParameterMissing: param is missing or the value is empty: person + # ActionController::Parameters.new(person: {}).require(:person) + # # ActionController::ParameterMissing: param is missing or the value is empty: person # - # When given an array of keys, the method tries to require each one of them - # in order. If it succeeds, an array with the respective return values is - # returned: + # When given an array of keys, the method tries to require each one of them in + # order. If it succeeds, an array with the respective return values is returned: # - # params = ActionController::Parameters.new(user: { ... }, profile: { ... }) - # user_params, profile_params = params.require([:user, :profile]) + # params = ActionController::Parameters.new(user: { ... }, profile: { ... }) + # user_params, profile_params = params.require([:user, :profile]) # # Otherwise, the method re-raises the first exception found: # - # params = ActionController::Parameters.new(user: {}, profile: {}) - # user_params, profile_params = params.require([:user, :profile]) - # # ActionController::ParameterMissing: param is missing or the value is empty: user + # params = ActionController::Parameters.new(user: {}, profile: {}) + # user_params, profile_params = params.require([:user, :profile]) + # # ActionController::ParameterMissing: param is missing or the value is empty: user # # Technically this method can be used to fetch terminal values: # - # # CAREFUL - # params = ActionController::Parameters.new(person: { name: "Finn" }) - # name = params.require(:person).require(:name) # CAREFUL + # # CAREFUL + # params = ActionController::Parameters.new(person: { name: "Finn" }) + # name = params.require(:person).require(:name) # CAREFUL # # but take into account that at some point those ones have to be permitted: # - # def person_params - # params.require(:person).permit(:name).tap do |person_params| - # person_params.require(:name) # SAFER + # def person_params + # params.require(:person).permit(:name).tap do |person_params| + # person_params.require(:name) # SAFER + # end # end - # end # # for example. - # Alias of #require. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#494 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#522 def required(key); end - # Returns a new ActionController::Parameters with all keys from - # current hash merged into +other_hash+. + # Returns a new `ActionController::Parameters` instance with all keys from + # current hash merged into `other_hash`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#863 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#906 def reverse_merge(other_hash); end - # Returns current ActionController::Parameters instance with - # current hash merged into +other_hash+. + # Returns the current `ActionController::Parameters` instance with current hash + # merged into `other_hash`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#872 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#915 def reverse_merge!(other_hash); end - # Returns a new instance of ActionController::Parameters with only - # items that the block evaluates to true. + # Returns a new `ActionController::Parameters` instance with only items that the + # block evaluates to true. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#794 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#821 def select(&block); end - # Equivalent to Hash#keep_if, but returns +nil+ if no changes were made. + # Equivalent to Hash#keep_if, but returns `nil` if no changes were made. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#799 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#826 def select!(&block); end - # Returns a new ActionController::Parameters instance that - # includes only the given +keys+. If the given +keys+ - # don't exist, returns an empty hash. + # Returns a new `ActionController::Parameters` instance that includes only the + # given `keys`. If the given `keys` don't exist, returns an empty hash. # - # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) - # params.slice(:a, :b) # => #1, "b"=>2} permitted: false> - # params.slice(:d) # => # + # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) + # params.slice(:a, :b) # => #1, "b"=>2} permitted: false> + # params.slice(:d) # => # # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#699 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#725 def slice(*keys); end - # Returns current ActionController::Parameters instance which - # contains only the given +keys+. + # Returns the current `ActionController::Parameters` instance which contains + # only the given `keys`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#705 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#731 def slice!(*keys); end - # This is required by ActiveModel attribute assignment, so that user can - # pass +Parameters+ to a mass assignment methods in a model. It should not - # matter as we are using +HashWithIndifferentAccess+ internally. + # This is required by ActiveModel attribute assignment, so that user can pass + # `Parameters` to a mass assignment methods in a model. It should not matter as + # we are using `HashWithIndifferentAccess` internally. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#881 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#924 def stringify_keys; end - # Returns a safe ActiveSupport::HashWithIndifferentAccess - # representation of the parameters with all unpermitted keys removed. + # Returns a safe ActiveSupport::HashWithIndifferentAccess representation of the + # parameters with all unpermitted keys removed. # - # params = ActionController::Parameters.new({ - # name: "Senjougahara Hitagi", - # oddity: "Heavy stone crab" - # }) - # params.to_h - # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash + # params = ActionController::Parameters.new({ + # name: "Senjougahara Hitagi", + # oddity: "Heavy stone crab" + # }) + # params.to_h + # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash # - # safe_params = params.permit(:name) - # safe_params.to_h # => {"name"=>"Senjougahara Hitagi"} + # safe_params = params.permit(:name) + # safe_params.to_h # => {"name"=>"Senjougahara Hitagi"} # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#305 - def to_h; end + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#332 + def to_h(&block); end - # Returns a safe Hash representation of the parameters - # with all unpermitted keys removed. + # Returns a safe `Hash` representation of the parameters with all unpermitted + # keys removed. # - # params = ActionController::Parameters.new({ - # name: "Senjougahara Hitagi", - # oddity: "Heavy stone crab" - # }) - # params.to_hash - # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash + # params = ActionController::Parameters.new({ + # name: "Senjougahara Hitagi", + # oddity: "Heavy stone crab" + # }) + # params.to_hash + # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash # - # safe_params = params.permit(:name) - # safe_params.to_hash # => {"name"=>"Senjougahara Hitagi"} + # safe_params = params.permit(:name) + # safe_params.to_hash # => {"name"=>"Senjougahara Hitagi"} # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#325 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#352 def to_hash; end # Returns a string representation of the receiver suitable for use as a URL # query string: # - # params = ActionController::Parameters.new({ - # name: "David", - # nationality: "Danish" - # }) - # params.to_query - # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash + # params = ActionController::Parameters.new({ + # name: "David", + # nationality: "Danish" + # }) + # params.to_query + # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash # - # safe_params = params.permit(:name, :nationality) - # safe_params.to_query - # # => "name=David&nationality=Danish" + # safe_params = params.permit(:name, :nationality) + # safe_params.to_query + # # => "name=David&nationality=Danish" # # An optional namespace can be passed to enclose key names: # - # params = ActionController::Parameters.new({ - # name: "David", - # nationality: "Danish" - # }) - # safe_params = params.permit(:name, :nationality) - # safe_params.to_query("user") - # # => "user%5Bname%5D=David&user%5Bnationality%5D=Danish" - # - # The string pairs "key=value" that conform the query string - # are sorted lexicographically in ascending order. + # params = ActionController::Parameters.new({ + # name: "David", + # nationality: "Danish" + # }) + # safe_params = params.permit(:name, :nationality) + # safe_params.to_query("user") + # # => "user%5Bname%5D=David&user%5Bnationality%5D=Danish" # - # This method is also aliased as +to_param+. + # The string pairs `"key=value"` that conform the query string are sorted + # lexicographically in ascending order. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#357 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#382 def to_param(*args); end # Returns a string representation of the receiver suitable for use as a URL # query string: # - # params = ActionController::Parameters.new({ - # name: "David", - # nationality: "Danish" - # }) - # params.to_query - # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash + # params = ActionController::Parameters.new({ + # name: "David", + # nationality: "Danish" + # }) + # params.to_query + # # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash # - # safe_params = params.permit(:name, :nationality) - # safe_params.to_query - # # => "name=David&nationality=Danish" + # safe_params = params.permit(:name, :nationality) + # safe_params.to_query + # # => "name=David&nationality=Danish" # # An optional namespace can be passed to enclose key names: # - # params = ActionController::Parameters.new({ - # name: "David", - # nationality: "Danish" - # }) - # safe_params = params.permit(:name, :nationality) - # safe_params.to_query("user") - # # => "user%5Bname%5D=David&user%5Bnationality%5D=Danish" + # params = ActionController::Parameters.new({ + # name: "David", + # nationality: "Danish" + # }) + # safe_params = params.permit(:name, :nationality) + # safe_params.to_query("user") + # # => "user%5Bname%5D=David&user%5Bnationality%5D=Danish" # - # The string pairs "key=value" that conform the query string - # are sorted lexicographically in ascending order. + # The string pairs `"key=value"` that conform the query string are sorted + # lexicographically in ascending order. # - # This method is also aliased as +to_param+. - # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#357 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#382 def to_query(*args); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#237 def to_s(*_arg0, **_arg1, &_arg2); end - # Returns an unsafe, unfiltered - # ActiveSupport::HashWithIndifferentAccess representation of the - # parameters. + # Returns an unsafe, unfiltered ActiveSupport::HashWithIndifferentAccess + # representation of the parameters. # - # params = ActionController::Parameters.new({ - # name: "Senjougahara Hitagi", - # oddity: "Heavy stone crab" - # }) - # params.to_unsafe_h - # # => {"name"=>"Senjougahara Hitagi", "oddity" => "Heavy stone crab"} + # params = ActionController::Parameters.new({ + # name: "Senjougahara Hitagi", + # oddity: "Heavy stone crab" + # }) + # params.to_unsafe_h + # # => {"name"=>"Senjougahara Hitagi", "oddity" => "Heavy stone crab"} # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#372 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#396 def to_unsafe_h; end - # Returns an unsafe, unfiltered - # ActiveSupport::HashWithIndifferentAccess representation of the - # parameters. + # Returns an unsafe, unfiltered ActiveSupport::HashWithIndifferentAccess + # representation of the parameters. # - # params = ActionController::Parameters.new({ - # name: "Senjougahara Hitagi", - # oddity: "Heavy stone crab" - # }) - # params.to_unsafe_h - # # => {"name"=>"Senjougahara Hitagi", "oddity" => "Heavy stone crab"} + # params = ActionController::Parameters.new({ + # name: "Senjougahara Hitagi", + # oddity: "Heavy stone crab" + # }) + # params.to_unsafe_h + # # => {"name"=>"Senjougahara Hitagi", "oddity" => "Heavy stone crab"} # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#372 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#396 def to_unsafe_hash; end - # Returns a new ActionController::Parameters instance with the - # results of running +block+ once for every key. The values are unchanged. + # Returns a new `ActionController::Parameters` instance with the results of + # running `block` once for every key. The values are unchanged. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#752 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#779 def transform_keys(&block); end # Performs keys transformation and returns the altered - # ActionController::Parameters instance. + # `ActionController::Parameters` instance. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#761 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#788 def transform_keys!(&block); end - # Returns a new ActionController::Parameters with the results of - # running +block+ once for every value. The keys are unchanged. + # Returns a new `ActionController::Parameters` instance with the results of + # running `block` once for every value. The keys are unchanged. # - # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) - # params.transform_values { |x| x * 2 } - # # => #2, "b"=>4, "c"=>6} permitted: false> + # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) + # params.transform_values { |x| x * 2 } + # # => #2, "b"=>4, "c"=>6} permitted: false> # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#735 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#762 def transform_values; end # Performs values transformation and returns the altered - # ActionController::Parameters instance. + # `ActionController::Parameters` instance. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#744 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#771 def transform_values!; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 - def value?(*_arg0, **_arg1, &_arg2); end + # Returns true if the given value is present for some key in the parameters. + # + # @return [Boolean] + # + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#870 + def value?(value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#233 - def values(*_arg0, **_arg1, &_arg2); end + # Returns a new array of the values of the parameters. + # + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#425 + def values; end - # Returns values that were assigned to the given +keys+. Note that all the - # +Hash+ objects will be converted to ActionController::Parameters. + # Returns values that were assigned to the given `keys`. Note that all the + # `Hash` objects will be converted to `ActionController::Parameters`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#842 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#878 def values_at(*keys); end - # Returns a new ActionController::Parameters with all keys from - # current hash merged into +other_hash+. + # Returns a new `ActionController::Parameters` instance with all keys from + # current hash merged into `other_hash`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#863 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#906 def with_defaults(other_hash); end - # Returns current ActionController::Parameters instance with - # current hash merged into +other_hash+. + # Returns the current `ActionController::Parameters` instance with current hash + # merged into `other_hash`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#872 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#915 def with_defaults!(other_hash); end + # Returns a new `ActionController::Parameters` instance that filters out the + # given `keys`. + # + # params = ActionController::Parameters.new(a: 1, b: 2, c: 3) + # params.except(:a, :b) # => #3} permitted: false> + # params.except(:d) # => #1, "b"=>2, "c"=>3} permitted: false> + # + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#742 + def without(*keys); end + protected - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#936 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#996 def each_nested_attribute; end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#932 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#992 def nested_attributes?; end # Returns the value of attribute parameters. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#928 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#988 def parameters; end # Sets the attribute permitted # # @param value the value to set the attribute permitted to. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#930 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#990 def permitted=(_arg0); end private + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1045 + def _deep_transform_keys_in_object(object, &block); end + + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1064 + def _deep_transform_keys_in_object!(object, &block); end + # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1076 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1177 def array_of_permitted_scalars?(value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#964 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1025 def convert_hashes_to_parameters(key, value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#949 - def convert_parameters_to_hashes(value, using); end + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1009 + def convert_parameters_to_hashes(value, using, &block); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#970 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1031 def convert_value_to_parameters(value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#990 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1091 def each_element(object, filter, &block); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1088 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1189 def hash_filter(params, filter); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1147 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1250 def initialize_copy(source); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#943 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1003 def new_instance_with_inherited_permitted_status(hash); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1082 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1183 def non_scalar?(value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1132 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1233 def permit_any_in_array(array); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1115 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1216 def permit_any_in_parameters(params); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1047 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1148 def permitted_scalar?(value); end # Adds existing keys to the params if their values are scalar. # # For example: # - # puts self.keys #=> ["zipcode(90210i)"] - # params = {} + # puts self.keys #=> ["zipcode(90210i)"] + # params = {} # - # permitted_scalar_filter(params, "zipcode") + # permitted_scalar_filter(params, "zipcode") # - # puts params.keys # => ["zipcode"] + # puts params.keys # => ["zipcode"] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1061 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1162 def permitted_scalar_filter(params, permitted_key); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#984 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1085 def specify_numeric_keys?(filter); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1016 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1117 def unpermitted_keys(params); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1003 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1104 def unpermitted_parameters!(params); end class << self - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#135 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#152 def action_on_unpermitted_parameters; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#135 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#152 def action_on_unpermitted_parameters=(val); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#243 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#253 + def allow_deprecated_parameters_hash_equality; end + + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#260 + def allow_deprecated_parameters_hash_equality=(value); end + + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#250 def always_permitted_parameters; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#243 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#250 def always_permitted_parameters=(val); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#889 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#932 def hook_into_yaml_loading; end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#246 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#267 def nested_attribute?(key, value); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#133 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#150 def permit_all_parameters; end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#133 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#150 def permit_all_parameters=(val); end end end -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1086 +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1187 ActionController::Parameters::EMPTY_ARRAY = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1087 +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1188 ActionController::Parameters::EMPTY_HASH = T.let(T.unsafe(nil), Hash) -# This is a list of permitted scalar types that includes the ones -# supported in XML and JSON requests. +# --- Filtering ---------------------------------------------------------- # -# This list is in particular used to filter ordinary requests, String goes -# as first element to quickly short-circuit the common case. +# This is a list of permitted scalar types that includes the ones supported in +# XML and JSON requests. # -# If you modify this collection please update the API of +permit+ above. +# This list is in particular used to filter ordinary requests, String goes as +# first element to quickly short-circuit the common case. # -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1031 +# If you modify this collection please update the one in the #permit doc as +# well. +# +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1132 ActionController::Parameters::PERMITTED_SCALAR_TYPES = T.let(T.unsafe(nil), Array) +# # Action Controller Params Wrapper +# # Wraps the parameters hash into a nested hash. This will allow clients to # submit requests without having to specify any root elements. # @@ -5874,8 +6328,8 @@ ActionController::Parameters::PERMITTED_SCALAR_TYPES = T.let(T.unsafe(nil), Arra # wrap_parameters format: [:json, :xml, :url_encoded_form, :multipart_form] # end # -# If you enable +ParamsWrapper+ for +:json+ format, instead of having to -# send JSON parameters like this: +# If you enable `ParamsWrapper` for `:json` format, instead of having to send +# JSON parameters like this: # # {"user": {"name": "Konata"}} # @@ -5884,45 +6338,44 @@ ActionController::Parameters::PERMITTED_SCALAR_TYPES = T.let(T.unsafe(nil), Arra # {"name": "Konata"} # # And it will be wrapped into a nested hash with the key name matching the -# controller's name. For example, if you're posting to +UsersController+, -# your new +params+ hash will look like this: +# controller's name. For example, if you're posting to `UsersController`, your +# new `params` hash will look like this: # # {"name" => "Konata", "user" => {"name" => "Konata"}} # -# You can also specify the key in which the parameters should be wrapped to, -# and also the list of attributes it should wrap by using either +:include+ or -# +:exclude+ options like this: +# You can also specify the key in which the parameters should be wrapped to, and +# also the list of attributes it should wrap by using either `:include` or +# `:exclude` options like this: # # class UsersController < ApplicationController # wrap_parameters :person, include: [:username, :password] # end # -# On Active Record models with no +:include+ or +:exclude+ option set, -# it will only wrap the parameters returned by the class method -# attribute_names. +# On Active Record models with no `:include` or `:exclude` option set, it will +# only wrap the parameters returned by the class method `attribute_names`. # -# If you're going to pass the parameters to an +ActiveModel+ object (such as -# User.new(params[:user])), you might consider passing the model class to -# the method instead. The +ParamsWrapper+ will actually try to determine the -# list of attribute names from the model and only wrap those attributes: +# If you're going to pass the parameters to an `ActiveModel` object (such as +# `User.new(params[:user])`), you might consider passing the model class to the +# method instead. The `ParamsWrapper` will actually try to determine the list of +# attribute names from the model and only wrap those attributes: # # class UsersController < ApplicationController # wrap_parameters Person # end # -# You still could pass +:include+ and +:exclude+ to set the list of attributes +# You still could pass `:include` and `:exclude` to set the list of attributes # you want to wrap. # # By default, if you don't specify the key in which the parameters would be -# wrapped to, +ParamsWrapper+ will actually try to determine if there's -# a model related to it or not. This controller, for example: +# wrapped to, `ParamsWrapper` will actually try to determine if there's a model +# related to it or not. This controller, for example: # # class Admin::UsersController < ApplicationController # end # -# will try to check if Admin::User or +User+ model exists, and use it to -# determine the wrapper key respectively. If both models don't exist, -# it will then fallback to use +user+ as the key. +# will try to check if `Admin::User` or `User` model exists, and use it to +# determine the wrapper key respectively. If both models don't exist, it will +# then fall back to use `user` as the key. # # To disable this functionality for a controller: # @@ -5930,7 +6383,7 @@ ActionController::Parameters::PERMITTED_SCALAR_TYPES = T.let(T.unsafe(nil), Arra # wrap_parameters false # end # -# source://actionpack//lib/action_controller/metal/params_wrapper.rb#80 +# source://actionpack//lib/action_controller/metal/params_wrapper.rb#83 module ActionController::ParamsWrapper extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -5968,8 +6421,8 @@ module ActionController::ParamsWrapper # source://actionpack//lib/action_controller/metal/params_wrapper.rb#263 def _wrapper_key; end - # Performs parameters wrapping upon the request. Called automatically - # by the metal call stack. + # Performs parameters wrapping upon the request. Called automatically by the + # metal call stack. # # source://actionpack//lib/action_controller/metal/params_wrapper.rb#257 def process_action(*_arg0); end @@ -5992,55 +6445,52 @@ module ActionController::ParamsWrapper::ClassMethods # source://actionpack//lib/action_controller/metal/params_wrapper.rb#189 def _set_wrapper_options(options); end - # Sets the default wrapper key or model which will be used to determine - # wrapper key and attribute names. Called automatically when the - # module is inherited. + # Sets the default wrapper key or model which will be used to determine wrapper + # key and attribute names. Called automatically when the module is inherited. # # source://actionpack//lib/action_controller/metal/params_wrapper.rb#244 def inherited(klass); end - # Sets the name of the wrapper key, or the model which +ParamsWrapper+ - # would use to determine the attribute names from. + # Sets the name of the wrapper key, or the model which `ParamsWrapper` would use + # to determine the attribute names from. # - # ==== Examples - # wrap_parameters format: :xml - # # enables the parameter wrapper for XML format + # #### Examples + # wrap_parameters format: :xml + # # enables the parameter wrapper for XML format # - # wrap_parameters :person - # # wraps parameters into +params[:person]+ hash + # wrap_parameters :person + # # wraps parameters into +params[:person]+ hash # - # wrap_parameters Person - # # wraps parameters by determining the wrapper key from Person class - # # (+person+, in this case) and the list of attribute names + # wrap_parameters Person + # # wraps parameters by determining the wrapper key from Person class + # # (+person+, in this case) and the list of attribute names # - # wrap_parameters include: [:username, :title] - # # wraps only +:username+ and +:title+ attributes from parameters. + # wrap_parameters include: [:username, :title] + # # wraps only +:username+ and +:title+ attributes from parameters. # - # wrap_parameters false - # # disables parameters wrapping for this controller altogether. + # wrap_parameters false + # # disables parameters wrapping for this controller altogether. # - # ==== Options - # * :format - The list of formats in which the parameters wrapper - # will be enabled. - # * :include - The list of attribute names which parameters wrapper - # will wrap into a nested hash. - # * :exclude - The list of attribute names which parameters wrapper - # will exclude from a nested hash. + # #### Options + # * `:format` - The list of formats in which the parameters wrapper will be + # enabled. + # * `:include` - The list of attribute names which parameters wrapper will + # wrap into a nested hash. + # * `:exclude` - The list of attribute names which parameters wrapper will + # exclude from a nested hash. # - # source://actionpack//lib/action_controller/metal/params_wrapper.rb#220 + # source://actionpack//lib/action_controller/metal/params_wrapper.rb#221 def wrap_parameters(name_or_model_or_options, options = T.unsafe(nil)); end end -# source://actionpack//lib/action_controller/metal/params_wrapper.rb#83 +# source://actionpack//lib/action_controller/metal/params_wrapper.rb#86 ActionController::ParamsWrapper::EXCLUDE_PARAMETERS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_controller/metal/params_wrapper.rb#87 +# source://actionpack//lib/action_controller/metal/params_wrapper.rb#88 class ActionController::ParamsWrapper::Options < ::Struct - include ::Mutex_m - # @return [Options] a new instance of Options # - # source://actionpack//lib/action_controller/metal/params_wrapper.rb#98 + # source://actionpack//lib/action_controller/metal/params_wrapper.rb#97 def initialize(name, format, include, exclude, klass, model); end # Returns the value of attribute include @@ -6050,12 +6500,6 @@ class ActionController::ParamsWrapper::Options < ::Struct # source://actionpack//lib/action_controller/metal/params_wrapper.rb#108 def include; end - # source://mutex_m/0.1.2/mutex_m.rb#93 - def lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#83 - def locked?; end - # Returns the value of attribute model # # @return [Object] the current value of model @@ -6070,78 +6514,124 @@ class ActionController::ParamsWrapper::Options < ::Struct # source://actionpack//lib/action_controller/metal/params_wrapper.rb#141 def name; end - # source://mutex_m/0.1.2/mutex_m.rb#78 - def synchronize(&block); end - - # source://mutex_m/0.1.2/mutex_m.rb#88 - def try_lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#98 - def unlock; end - private - # Determine the wrapper model from the controller's name. By convention, - # this could be done by trying to find the defined model that has the - # same singular name as the controller. For example, +UsersController+ - # will try to find if the +User+ model exists. + # Determine the wrapper model from the controller's name. By convention, this + # could be done by trying to find the defined model that has the same singular + # name as the controller. For example, `UsersController` will try to find if the + # `User` model exists. # - # This method also does namespace lookup. Foo::Bar::UsersController will - # try to find Foo::Bar::User, Foo::User and finally User. + # This method also does namespace lookup. Foo::Bar::UsersController will try to + # find Foo::Bar::User, Foo::User and finally User. # # source://actionpack//lib/action_controller/metal/params_wrapper.rb#165 def _default_wrap_model; end class << self - # source://actionpack//lib/action_controller/metal/params_wrapper.rb#90 + # source://actionpack//lib/action_controller/metal/params_wrapper.rb#89 def from_hash(hash); end end end -# source://actionpack//lib/action_controller/metal/permissions_policy.rb#4 +# source://actionpack//lib/action_controller/metal/permissions_policy.rb#6 module ActionController::PermissionsPolicy extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionController::PermissionsPolicy::ClassMethods end -# source://actionpack//lib/action_controller/metal/permissions_policy.rb#7 +# source://actionpack//lib/action_controller/metal/permissions_policy.rb#9 module ActionController::PermissionsPolicy::ClassMethods - # Overrides parts of the globally configured +Feature-Policy+ - # header: + # Overrides parts of the globally configured `Feature-Policy` header: # - # class PagesController < ApplicationController - # permissions_policy do |policy| - # policy.geolocation "https://example.com" + # class PagesController < ApplicationController + # permissions_policy do |policy| + # policy.geolocation "https://example.com" + # end # end - # end # - # Options can be passed similar to +before_action+. For example, pass - # only: :index to override the header on the index action only: + # Options can be passed similar to `before_action`. For example, pass `only: + # :index` to override the header on the index action only: # - # class PagesController < ApplicationController - # permissions_policy(only: :index) do |policy| - # policy.camera :self + # class PagesController < ApplicationController + # permissions_policy(only: :index) do |policy| + # policy.camera :self + # end # end - # end # - # source://actionpack//lib/action_controller/metal/permissions_policy.rb#26 + # source://actionpack//lib/action_controller/metal/permissions_policy.rb#27 def permissions_policy(**options, &block); end end -# source://actionpack//lib/action_controller/railtie.rb#11 +# source://actionpack//lib/action_controller/railtie.rb#13 class ActionController::Railtie < ::Rails::Railtie; end -# source://actionpack//lib/action_controller/railties/helpers.rb#4 +# source://actionpack//lib/action_controller/railties/helpers.rb#6 module ActionController::Railties; end -# source://actionpack//lib/action_controller/railties/helpers.rb#5 +# source://actionpack//lib/action_controller/railties/helpers.rb#7 module ActionController::Railties::Helpers - # source://actionpack//lib/action_controller/railties/helpers.rb#6 + # source://actionpack//lib/action_controller/railties/helpers.rb#8 def inherited(klass); end end -# source://actionpack//lib/action_controller/metal/redirecting.rb#4 +# source://actionpack//lib/action_controller/metal/rate_limiting.rb#6 +module ActionController::RateLimiting + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionController::RateLimiting::ClassMethods + + private + + # source://actionpack//lib/action_controller/metal/rate_limiting.rb#53 + def rate_limiting(to:, within:, by:, with:, store:); end +end + +# source://actionpack//lib/action_controller/metal/rate_limiting.rb#9 +module ActionController::RateLimiting::ClassMethods + # Applies a rate limit to all actions or those specified by the normal + # `before_action` filters with `only:` and `except:`. + # + # The maximum number of requests allowed is specified `to:` and constrained to + # the window of time given by `within:`. + # + # Rate limits are by default unique to the ip address making the request, but + # you can provide your own identity function by passing a callable in the `by:` + # parameter. It's evaluated within the context of the controller processing the + # request. + # + # Requests that exceed the rate limit are refused with a `429 Too Many Requests` + # response. You can specialize this by passing a callable in the `with:` + # parameter. It's evaluated within the context of the controller processing the + # request. + # + # Rate limiting relies on a backing `ActiveSupport::Cache` store and defaults to + # `config.action_controller.cache_store`, which itself defaults to the global + # `config.cache_store`. If you don't want to store rate limits in the same + # datastore as your general caches, you can pass a custom store in the `store` + # parameter. + # + # Examples: + # + # class SessionsController < ApplicationController + # rate_limit to: 10, within: 3.minutes, only: :create + # end + # + # class SignupsController < ApplicationController + # rate_limit to: 1000, within: 10.seconds, + # by: -> { request.domain }, with: -> { redirect_to busy_controller_url, alert: "Too many signups on domain!" }, only: :new + # end + # + # class APIController < ApplicationController + # RATE_LIMIT_STORE = ActiveSupport::Cache::RedisCacheStore.new(url: ENV["REDIS_URL"]) + # rate_limit to: 10, within: 3.minutes, store: RATE_LIMIT_STORE + # end + # + # source://actionpack//lib/action_controller/metal/rate_limiting.rb#47 + def rate_limit(to:, within:, by: T.unsafe(nil), with: T.unsafe(nil), store: T.unsafe(nil), **options); end +end + +# source://actionpack//lib/action_controller/metal/redirecting.rb#6 module ActionController::Redirecting extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -6154,154 +6644,181 @@ module ActionController::Redirecting mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::AbstractController::UrlFor::ClassMethods - # source://actionpack//lib/action_controller/metal/redirecting.rb#130 + # source://actionpack//lib/action_controller/metal/redirecting.rb#158 def _compute_redirect_to_location(request, options); end - # Soft deprecated alias for #redirect_back_or_to where the +fallback_location+ location is supplied as a keyword argument instead - # of the first positional argument. + # Soft deprecated alias for #redirect_back_or_to where the `fallback_location` + # location is supplied as a keyword argument instead of the first positional + # argument. # - # source://actionpack//lib/action_controller/metal/redirecting.rb#95 + # source://actionpack//lib/action_controller/metal/redirecting.rb#121 def redirect_back(fallback_location:, allow_other_host: T.unsafe(nil), **args); end - # Redirects the browser to the page that issued the request (the referrer) - # if possible, otherwise redirects to the provided default fallback - # location. + # Redirects the browser to the page that issued the request (the referrer) if + # possible, otherwise redirects to the provided default fallback location. # - # The referrer information is pulled from the HTTP +Referer+ (sic) header on - # the request. This is an optional header and its presence on the request is - # subject to browser security settings and user preferences. If the request - # is missing this header, the fallback_location will be used. + # The referrer information is pulled from the HTTP `Referer` (sic) header on the + # request. This is an optional header and its presence on the request is subject + # to browser security settings and user preferences. If the request is missing + # this header, the `fallback_location` will be used. # - # redirect_back_or_to({ action: "show", id: 5 }) - # redirect_back_or_to @post - # redirect_back_or_to "http://www.rubyonrails.org" - # redirect_back_or_to "/images/screenshot.jpg" - # redirect_back_or_to posts_url - # redirect_back_or_to proc { edit_post_url(@post) } - # redirect_back_or_to '/', allow_other_host: false + # redirect_back_or_to({ action: "show", id: 5 }) + # redirect_back_or_to @post + # redirect_back_or_to "http://www.rubyonrails.org" + # redirect_back_or_to "/images/screenshot.jpg" + # redirect_back_or_to posts_url + # redirect_back_or_to proc { edit_post_url(@post) } + # redirect_back_or_to '/', allow_other_host: false # - # ==== Options - # * :allow_other_host - Allow or disallow redirection to the host that is different to the current host, defaults to true. + # #### Options + # * `:allow_other_host` - Allow or disallow redirection to the host that is + # different to the current host, defaults to true. # - # All other options that can be passed to #redirect_to are accepted as - # options, and the behavior is identical. # - # source://actionpack//lib/action_controller/metal/redirecting.rb#121 + # All other options that can be passed to #redirect_to are accepted as options, + # and the behavior is identical. + # + # source://actionpack//lib/action_controller/metal/redirecting.rb#148 def redirect_back_or_to(fallback_location, allow_other_host: T.unsafe(nil), **options); end - # Redirects the browser to the target specified in +options+. This parameter can be any one of: + # Redirects the browser to the target specified in `options`. This parameter can + # be any one of: + # + # * `Hash` - The URL will be generated by calling url_for with the `options`. + # * `Record` - The URL will be generated by calling url_for with the + # `options`, which will reference a named URL for that record. + # * `String` starting with `protocol://` (like `http://`) or a protocol + # relative reference (like `//`) - Is passed straight through as the target + # for redirection. + # * `String` not containing a protocol - The current protocol and host is + # prepended to the string. + # * `Proc` - A block that will be executed in the controller's context. Should + # return any option accepted by `redirect_to`. # - # * Hash - The URL will be generated by calling url_for with the +options+. - # * Record - The URL will be generated by calling url_for with the +options+, which will reference a named URL for that record. - # * String starting with protocol:// (like http://) or a protocol relative reference (like //) - Is passed straight through as the target for redirection. - # * String not containing a protocol - The current protocol and host is prepended to the string. - # * Proc - A block that will be executed in the controller's context. Should return any option accepted by +redirect_to+. # - # === Examples: + # ### Examples # - # redirect_to action: "show", id: 5 - # redirect_to @post - # redirect_to "http://www.rubyonrails.org" - # redirect_to "/images/screenshot.jpg" - # redirect_to posts_url - # redirect_to proc { edit_post_url(@post) } + # redirect_to action: "show", id: 5 + # redirect_to @post + # redirect_to "http://www.rubyonrails.org" + # redirect_to "/images/screenshot.jpg" + # redirect_to posts_url + # redirect_to proc { edit_post_url(@post) } # - # The redirection happens as a 302 Found header unless otherwise specified using the :status option: + # The redirection happens as a `302 Found` header unless otherwise specified + # using the `:status` option: # - # redirect_to post_url(@post), status: :found - # redirect_to action: 'atom', status: :moved_permanently - # redirect_to post_url(@post), status: 301 - # redirect_to action: 'atom', status: 302 + # redirect_to post_url(@post), status: :found + # redirect_to action: 'atom', status: :moved_permanently + # redirect_to post_url(@post), status: 301 + # redirect_to action: 'atom', status: 302 # - # The status code can either be a standard {HTTP Status code}[https://www.iana.org/assignments/http-status-codes] as an - # integer, or a symbol representing the downcased, underscored and symbolized description. - # Note that the status code must be a 3xx HTTP code, or redirection will not occur. + # The status code can either be a standard [HTTP Status + # code](https://www.iana.org/assignments/http-status-codes) as an integer, or a + # symbol representing the downcased, underscored and symbolized description. + # Note that the status code must be a 3xx HTTP code, or redirection will not + # occur. # # If you are using XHR requests other than GET or POST and redirecting after the # request then some browsers will follow the redirect using the original request # method. This may lead to undesirable behavior such as a double DELETE. To work - # around this you can return a 303 See Other status code which will be + # around this you can return a `303 See Other` status code which will be # followed using a GET request. # - # redirect_to posts_url, status: :see_other - # redirect_to action: 'index', status: 303 + # redirect_to posts_url, status: :see_other + # redirect_to action: 'index', status: 303 # - # It is also possible to assign a flash message as part of the redirection. There are two special accessors for the commonly used flash names - # +alert+ and +notice+ as well as a general purpose +flash+ bucket. + # It is also possible to assign a flash message as part of the redirection. + # There are two special accessors for the commonly used flash names `alert` and + # `notice` as well as a general purpose `flash` bucket. # - # redirect_to post_url(@post), alert: "Watch it, mister!" - # redirect_to post_url(@post), status: :found, notice: "Pay attention to the road" - # redirect_to post_url(@post), status: 301, flash: { updated_post_id: @post.id } - # redirect_to({ action: 'atom' }, alert: "Something serious happened") + # redirect_to post_url(@post), alert: "Watch it, mister!" + # redirect_to post_url(@post), status: :found, notice: "Pay attention to the road" + # redirect_to post_url(@post), status: 301, flash: { updated_post_id: @post.id } + # redirect_to({ action: 'atom' }, alert: "Something serious happened") # - # Statements after +redirect_to+ in our controller get executed, so +redirect_to+ doesn't stop the execution of the function. - # To terminate the execution of the function immediately after the +redirect_to+, use return. + # Statements after `redirect_to` in our controller get executed, so + # `redirect_to` doesn't stop the execution of the function. To terminate the + # execution of the function immediately after the `redirect_to`, use return. # - # redirect_to post_url(@post) and return + # redirect_to post_url(@post) and return # - # === Open Redirect protection + # ### Open Redirect protection # - # By default, Rails protects against redirecting to external hosts for your app's safety, so called open redirects. - # Note: this was a new default in Rails 7.0, after upgrading opt-in by uncommenting the line with +raise_on_open_redirects+ in config/initializers/new_framework_defaults_7_0.rb + # By default, Rails protects against redirecting to external hosts for your + # app's safety, so called open redirects. Note: this was a new default in Rails + # 7.0, after upgrading opt-in by uncommenting the line with + # `raise_on_open_redirects` in + # `config/initializers/new_framework_defaults_7_0.rb` # # Here #redirect_to automatically validates the potentially-unsafe URL: # - # redirect_to params[:redirect_url] + # redirect_to params[:redirect_url] # # Raises UnsafeRedirectError in the case of an unsafe redirect. # - # To allow any external redirects pass allow_other_host: true, though using a user-provided param in that case is unsafe. + # To allow any external redirects pass `allow_other_host: true`, though using a + # user-provided param in that case is unsafe. # - # redirect_to "https://rubyonrails.org", allow_other_host: true + # redirect_to "https://rubyonrails.org", allow_other_host: true # - # See #url_from for more information on what an internal and safe URL is, or how to fall back to an alternate redirect URL in the unsafe case. + # See #url_from for more information on what an internal and safe URL is, or how + # to fall back to an alternate redirect URL in the unsafe case. # # @raise [ActionControllerError] # - # source://actionpack//lib/action_controller/metal/redirecting.rb#82 + # source://actionpack//lib/action_controller/metal/redirecting.rb#103 def redirect_to(options = T.unsafe(nil), response_options = T.unsafe(nil)); end - # Verifies the passed +location+ is an internal URL that's safe to redirect to and returns it, or nil if not. - # Useful to wrap a params provided redirect URL and fallback to an alternate URL to redirect to: + # Verifies the passed `location` is an internal URL that's safe to redirect to + # and returns it, or nil if not. Useful to wrap a params provided redirect URL + # and fall back to an alternate URL to redirect to: # - # redirect_to url_from(params[:redirect_url]) || root_url + # redirect_to url_from(params[:redirect_url]) || root_url # - # The +location+ is considered internal, and safe, if it's on the same host as request.host: + # The `location` is considered internal, and safe, if it's on the same host as + # `request.host`: # - # # If request.host is example.com: - # url_from("https://example.com/profile") # => "https://example.com/profile" - # url_from("http://example.com/profile") # => "http://example.com/profile" - # url_from("http://evil.com/profile") # => nil + # # If request.host is example.com: + # url_from("https://example.com/profile") # => "https://example.com/profile" + # url_from("http://example.com/profile") # => "http://example.com/profile" + # url_from("http://evil.com/profile") # => nil # # Subdomains are considered part of the host: # - # # If request.host is on https://example.com or https://app.example.com, you'd get: - # url_from("https://dev.example.com/profile") # => nil + # # If request.host is on https://example.com or https://app.example.com, you'd get: + # url_from("https://dev.example.com/profile") # => nil # - # NOTE: there's a similarity with {url_for}[rdoc-ref:ActionDispatch::Routing::UrlFor#url_for], which generates an internal URL from various options from within the app, e.g. url_for(@post). - # However, #url_from is meant to take an external parameter to verify as in url_from(params[:redirect_url]). + # NOTE: there's a similarity with + # [url_for](rdoc-ref:ActionDispatch::Routing::UrlFor#url_for), which generates + # an internal URL from various options from within the app, e.g. + # `url_for(@post)`. However, #url_from is meant to take an external parameter to + # verify as in `url_from(params[:redirect_url])`. # - # source://actionpack//lib/action_controller/metal/redirecting.rb#169 + # source://actionpack//lib/action_controller/metal/redirecting.rb#202 def url_from(location); end private - # source://actionpack//lib/action_controller/metal/redirecting.rb#175 + # source://actionpack//lib/action_controller/metal/redirecting.rb#208 def _allow_other_host; end - # source://actionpack//lib/action_controller/metal/redirecting.rb#189 + # source://actionpack//lib/action_controller/metal/redirecting.rb#222 def _enforce_open_redirect_protection(location, allow_other_host:); end - # source://actionpack//lib/action_controller/metal/redirecting.rb#179 + # source://actionpack//lib/action_controller/metal/redirecting.rb#241 + def _ensure_url_is_http_header_safe(url); end + + # source://actionpack//lib/action_controller/metal/redirecting.rb#212 def _extract_redirect_to_status(options, response_options); end # @return [Boolean] # - # source://actionpack//lib/action_controller/metal/redirecting.rb#197 + # source://actionpack//lib/action_controller/metal/redirecting.rb#230 def _url_host_allowed?(url); end class << self - # source://actionpack//lib/action_controller/metal/redirecting.rb#130 + # source://actionpack//lib/action_controller/metal/redirecting.rb#158 def _compute_redirect_to_location(request, options); end end @@ -6318,111 +6835,135 @@ module ActionController::Redirecting end end -# source://actionpack//lib/action_controller/metal/redirecting.rb#10 +# source://actionpack//lib/action_controller/metal/redirecting.rb#14 +ActionController::Redirecting::ILLEGAL_HEADER_VALUE_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://actionpack//lib/action_controller/metal/redirecting.rb#12 class ActionController::Redirecting::UnsafeRedirectError < ::StandardError; end -# source://actionpack//lib/action_controller/metal/exceptions.rb#14 +# source://actionpack//lib/action_controller/metal/exceptions.rb#16 class ActionController::RenderError < ::ActionController::ActionControllerError; end -# ActionController::Renderer allows you to render arbitrary templates -# without requirement of being in controller actions. -# -# You get a concrete renderer class by invoking ActionController::Base#renderer. -# For example: +# # Action Controller Renderer # -# ApplicationController.renderer +# ActionController::Renderer allows you to render arbitrary templates without +# being inside a controller action. # -# It allows you to call method #render directly. +# You can get a renderer instance by calling `renderer` on a controller class: # -# ApplicationController.renderer.render template: '...' +# ApplicationController.renderer +# PostsController.renderer # -# You can use this shortcut in a controller, instead of the previous example: -# -# ApplicationController.render template: '...' -# -# #render allows you to use the same options that you can use when rendering in a controller. -# For example: +# and render a template by calling the #render method: # -# FooController.render :action, locals: { ... }, assigns: { ... } +# ApplicationController.renderer.render template: "posts/show", assigns: { post: Post.first } +# PostsController.renderer.render :show, assigns: { post: Post.first } # -# The template will be rendered in a Rack environment which is accessible through -# ActionController::Renderer#env. You can set it up in two ways: +# As a shortcut, you can also call `render` directly on the controller class +# itself: # -# * by changing renderer defaults, like +# ApplicationController.render template: "posts/show", assigns: { post: Post.first } +# PostsController.render :show, assigns: { post: Post.first } # -# ApplicationController.renderer.defaults # => hash with default Rack environment -# -# * by initializing an instance of renderer by passing it a custom environment. -# -# ApplicationController.renderer.new(method: 'post', https: true) -# -# source://actionpack//lib/action_controller/renderer.rb#36 +# source://actionpack//lib/action_controller/renderer.rb#27 class ActionController::Renderer - # Accepts a custom Rack environment to render templates in. - # It will be merged with the default Rack environment defined by - # +ActionController::Renderer::DEFAULTS+. + # Initializes a new Renderer. + # + # #### Parameters + # + # * `controller` - The controller class to instantiate for rendering. + # * `env` - The Rack env to use for mocking a request when rendering. Entries + # can be typical Rack env keys and values, or they can be any of the + # following, which will be converted appropriately: + # * `:http_host` - The HTTP host for the incoming request. Converts to + # Rack's `HTTP_HOST`. + # * `:https` - Boolean indicating whether the incoming request uses HTTPS. + # Converts to Rack's `HTTPS`. + # * `:method` - The HTTP method for the incoming request, + # case-insensitive. Converts to Rack's `REQUEST_METHOD`. + # * `:script_name` - The portion of the incoming request's URL path that + # corresponds to the application. Converts to Rack's `SCRIPT_NAME`. + # * `:input` - The input stream. Converts to Rack's `rack.input`. + # + # * `defaults` - Default values for the Rack env. Entries are specified in the + # same format as `env`. `env` will be merged on top of these values. + # `defaults` will be retained when calling #new on a renderer instance. + # + # + # If no `http_host` is specified, the env HTTP host will be derived from the + # routes' `default_url_options`. In this case, the `https` boolean and the + # `script_name` will also be derived from `default_url_options` if they were not + # specified. Additionally, the `https` boolean will fall back to + # `Rails.application.config.force_ssl` if `default_url_options` does not specify + # a `protocol`. # # @return [Renderer] a new instance of Renderer # - # source://actionpack//lib/action_controller/renderer.rb#65 + # source://actionpack//lib/action_controller/renderer.rb#111 def initialize(controller, env, defaults); end # Returns the value of attribute controller. # - # source://actionpack//lib/action_controller/renderer.rb#37 + # source://actionpack//lib/action_controller/renderer.rb#28 def controller; end - # Returns the value of attribute defaults. - # - # source://actionpack//lib/action_controller/renderer.rb#37 + # source://actionpack//lib/action_controller/renderer.rb#122 def defaults; end - # Create a new renderer for the same controller but with a new env. + # Creates a new renderer using the same controller, but with a new Rack env. + # + # ApplicationController.renderer.new(method: "post") # - # source://actionpack//lib/action_controller/renderer.rb#53 + # source://actionpack//lib/action_controller/renderer.rb#72 def new(env = T.unsafe(nil)); end - # Renders a template to a string, just like ActionController::Rendering#render_to_string. + # source://actionpack//lib/action_controller/renderer.rb#151 + def normalize_env(env, &_arg1); end + + # Renders a template to a string, just like + # ActionController::Rendering#render_to_string. # - # source://actionpack//lib/action_controller/renderer.rb#72 + # source://actionpack//lib/action_controller/renderer.rb#129 def render(*args); end - # Renders a template to a string, just like ActionController::Rendering#render_to_string. + # Renders a template to a string, just like + # ActionController::Rendering#render_to_string. # - # source://actionpack//lib/action_controller/renderer.rb#72 + # source://actionpack//lib/action_controller/renderer.rb#129 def render_to_string(*args); end - # Create a new renderer for the same controller but with new defaults. + # Creates a new renderer using the same controller, but with the given defaults + # merged on top of the previous defaults. # - # source://actionpack//lib/action_controller/renderer.rb#58 + # source://actionpack//lib/action_controller/renderer.rb#78 def with_defaults(defaults); end private - # source://actionpack//lib/action_controller/renderer.rb#86 - def normalize_keys(defaults, env); end - - # source://actionpack//lib/action_controller/renderer.rb#107 - def rack_key_for(key); end - - # source://actionpack//lib/action_controller/renderer.rb#111 - def rack_value_for(key, value); end + # source://actionpack//lib/action_controller/renderer.rb#153 + def env_for_request; end class << self - # Create a new renderer instance for a specific controller class. + # Creates a new renderer using the given controller class. See ::new. # - # source://actionpack//lib/action_controller/renderer.rb#48 + # source://actionpack//lib/action_controller/renderer.rb#64 def for(controller, env = T.unsafe(nil), defaults = T.unsafe(nil)); end + + # source://actionpack//lib/action_controller/renderer.rb#35 + def normalize_env(env); end end end -# source://actionpack//lib/action_controller/renderer.rb#39 +# source://actionpack//lib/action_controller/renderer.rb#30 ActionController::Renderer::DEFAULTS = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_controller/renderer.rb#99 +# source://actionpack//lib/action_controller/renderer.rb#149 +ActionController::Renderer::DEFAULT_ENV = T.let(T.unsafe(nil), Hash) + +# source://actionpack//lib/action_controller/renderer.rb#141 ActionController::Renderer::RACK_KEY_TRANSLATION = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_controller/metal/renderers.rb#23 +# source://actionpack//lib/action_controller/metal/renderers.rb#25 module ActionController::Renderers extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -6430,71 +6971,73 @@ module ActionController::Renderers mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActionController::Renderers::ClassMethods - # source://actionpack//lib/action_controller/metal/renderers.rb#144 + # source://actionpack//lib/action_controller/metal/renderers.rb#145 def _render_to_body_with_renderer(options); end - # source://actionpack//lib/action_controller/metal/renderers.rb#170 + # source://actionpack//lib/action_controller/metal/renderers.rb#171 def _render_with_renderer_js(js, options); end - # source://actionpack//lib/action_controller/metal/renderers.rb#155 + # source://actionpack//lib/action_controller/metal/renderers.rb#156 def _render_with_renderer_json(json, options); end - # source://actionpack//lib/action_controller/metal/renderers.rb#175 + # source://turbo-rails/2.0.6/lib/turbo/engine.rb#83 + def _render_with_renderer_turbo_stream(turbo_streams_html, options); end + + # source://actionpack//lib/action_controller/metal/renderers.rb#176 def _render_with_renderer_xml(xml, options); end - # Called by +render+ in AbstractController::Rendering - # which sets the return value as the +response_body+. + # Called by `render` in AbstractController::Rendering which sets the return + # value as the `response_body`. # - # If no renderer is found, +super+ returns control to - # ActionView::Rendering.render_to_body, if present. + # If no renderer is found, `super` returns control to + # `ActionView::Rendering.render_to_body`, if present. # - # source://actionpack//lib/action_controller/metal/renderers.rb#140 + # source://actionpack//lib/action_controller/metal/renderers.rb#141 def render_to_body(options); end class << self - # source://actionpack//lib/action_controller/metal/renderers.rb#90 + # source://actionpack//lib/action_controller/metal/renderers.rb#91 def _render_with_renderer_method_name(key); end - # Adds a new renderer to call within controller actions. - # A renderer is invoked by passing its name as an option to - # AbstractController::Rendering#render. To create a renderer - # pass it a name and a block. The block takes two arguments, the first - # is the value paired with its key and the second is the remaining - # hash of options passed to +render+. + # Adds a new renderer to call within controller actions. A renderer is invoked + # by passing its name as an option to AbstractController::Rendering#render. To + # create a renderer pass it a name and a block. The block takes two arguments, + # the first is the value paired with its key and the second is the remaining + # hash of options passed to `render`. # # Create a csv renderer: # - # ActionController::Renderers.add :csv do |obj, options| - # filename = options[:filename] || 'data' - # str = obj.respond_to?(:to_csv) ? obj.to_csv : obj.to_s - # send_data str, type: Mime[:csv], - # disposition: "attachment; filename=#{filename}.csv" - # end + # ActionController::Renderers.add :csv do |obj, options| + # filename = options[:filename] || 'data' + # str = obj.respond_to?(:to_csv) ? obj.to_csv : obj.to_s + # send_data str, type: Mime[:csv], + # disposition: "attachment; filename=#{filename}.csv" + # end # - # Note that we used Mime[:csv] for the csv mime type as it comes with Rails. + # Note that we used [Mime](:csv) for the csv mime type as it comes with Rails. # For a custom renderer, you'll need to register a mime type with - # Mime::Type.register. + # `Mime::Type.register`. # # To use the csv renderer in a controller action: # - # def show - # @csvable = Csvable.find(params[:id]) - # respond_to do |format| - # format.html - # format.csv { render csv: @csvable, filename: @csvable.name } + # def show + # @csvable = Csvable.find(params[:id]) + # respond_to do |format| + # format.html + # format.csv { render csv: @csvable, filename: @csvable.name } + # end # end - # end # - # source://actionpack//lib/action_controller/metal/renderers.rb#74 + # source://actionpack//lib/action_controller/metal/renderers.rb#75 def add(key, &block); end # This method is the opposite of add method. # # To remove a csv renderer: # - # ActionController::Renderers.remove(:csv) + # ActionController::Renderers.remove(:csv) # - # source://actionpack//lib/action_controller/metal/renderers.rb#84 + # source://actionpack//lib/action_controller/metal/renderers.rb#85 def remove(key); end end @@ -6514,7 +7057,7 @@ end # Used in ActionController::Base and ActionController::API to include all # renderers by default. # -# source://actionpack//lib/action_controller/metal/renderers.rb#36 +# source://actionpack//lib/action_controller/metal/renderers.rb#38 module ActionController::Renderers::All extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -6536,329 +7079,354 @@ module ActionController::Renderers::All end end -# source://actionpack//lib/action_controller/metal/renderers.rb#94 +# source://actionpack//lib/action_controller/metal/renderers.rb#95 module ActionController::Renderers::ClassMethods - # Adds, by name, a renderer or renderers to the +_renderers+ available - # to call within controller actions. + # Adds, by name, a renderer or renderers to the `_renderers` available to call + # within controller actions. # # It is useful when rendering from an ActionController::Metal controller or # otherwise to add an available renderer proc to a specific controller. # - # Both ActionController::Base and ActionController::API - # include ActionController::Renderers::All, making all renderers - # available in the controller. See Renderers::RENDERERS and Renderers.add. + # Both ActionController::Base and ActionController::API include + # ActionController::Renderers::All, making all renderers available in the + # controller. See Renderers::RENDERERS and Renderers.add. # - # Since ActionController::Metal controllers cannot render, the controller - # must include AbstractController::Rendering, ActionController::Rendering, - # and ActionController::Renderers, and have at least one renderer. + # Since ActionController::Metal controllers cannot render, the controller must + # include AbstractController::Rendering, ActionController::Rendering, and + # ActionController::Renderers, and have at least one renderer. # - # Rather than including ActionController::Renderers::All and including all renderers, - # you may specify which renderers to include by passing the renderer name or names to - # +use_renderers+. For example, a controller that includes only the :json renderer - # (+_render_with_renderer_json+) might look like: + # Rather than including ActionController::Renderers::All and including all + # renderers, you may specify which renderers to include by passing the renderer + # name or names to `use_renderers`. For example, a controller that includes only + # the `:json` renderer (`_render_with_renderer_json`) might look like: # - # class MetalRenderingController < ActionController::Metal - # include AbstractController::Rendering - # include ActionController::Rendering - # include ActionController::Renderers + # class MetalRenderingController < ActionController::Metal + # include AbstractController::Rendering + # include ActionController::Rendering + # include ActionController::Renderers # - # use_renderers :json + # use_renderers :json # - # def show - # render json: record + # def show + # render json: record + # end # end - # end # - # You must specify a +use_renderer+, else the +controller.renderer+ and - # +controller._renderers+ will be nil, and the action will fail. + # You must specify a `use_renderer`, else the `controller.renderer` and + # `controller._renderers` will be `nil`, and the action will fail. # - # source://actionpack//lib/action_controller/metal/renderers.rb#128 + # source://actionpack//lib/action_controller/metal/renderers.rb#129 def use_renderer(*args); end - # Adds, by name, a renderer or renderers to the +_renderers+ available - # to call within controller actions. + # Adds, by name, a renderer or renderers to the `_renderers` available to call + # within controller actions. # # It is useful when rendering from an ActionController::Metal controller or # otherwise to add an available renderer proc to a specific controller. # - # Both ActionController::Base and ActionController::API - # include ActionController::Renderers::All, making all renderers - # available in the controller. See Renderers::RENDERERS and Renderers.add. + # Both ActionController::Base and ActionController::API include + # ActionController::Renderers::All, making all renderers available in the + # controller. See Renderers::RENDERERS and Renderers.add. # - # Since ActionController::Metal controllers cannot render, the controller - # must include AbstractController::Rendering, ActionController::Rendering, - # and ActionController::Renderers, and have at least one renderer. + # Since ActionController::Metal controllers cannot render, the controller must + # include AbstractController::Rendering, ActionController::Rendering, and + # ActionController::Renderers, and have at least one renderer. # - # Rather than including ActionController::Renderers::All and including all renderers, - # you may specify which renderers to include by passing the renderer name or names to - # +use_renderers+. For example, a controller that includes only the :json renderer - # (+_render_with_renderer_json+) might look like: + # Rather than including ActionController::Renderers::All and including all + # renderers, you may specify which renderers to include by passing the renderer + # name or names to `use_renderers`. For example, a controller that includes only + # the `:json` renderer (`_render_with_renderer_json`) might look like: # - # class MetalRenderingController < ActionController::Metal - # include AbstractController::Rendering - # include ActionController::Rendering - # include ActionController::Renderers + # class MetalRenderingController < ActionController::Metal + # include AbstractController::Rendering + # include ActionController::Rendering + # include ActionController::Renderers # - # use_renderers :json + # use_renderers :json # - # def show - # render json: record + # def show + # render json: record + # end # end - # end # - # You must specify a +use_renderer+, else the +controller.renderer+ and - # +controller._renderers+ will be nil, and the action will fail. + # You must specify a `use_renderer`, else the `controller.renderer` and + # `controller._renderers` will be `nil`, and the action will fail. # - # source://actionpack//lib/action_controller/metal/renderers.rb#128 + # source://actionpack//lib/action_controller/metal/renderers.rb#129 def use_renderers(*args); end end # A Set containing renderer names that correspond to available renderer procs. -# Default values are :json, :js, :xml. +# Default values are `:json`, `:js`, `:xml`. # -# source://actionpack//lib/action_controller/metal/renderers.rb#28 +# source://actionpack//lib/action_controller/metal/renderers.rb#30 ActionController::Renderers::RENDERERS = T.let(T.unsafe(nil), Set) -# source://actionpack//lib/action_controller/metal/rendering.rb#4 +# source://actionpack//lib/action_controller/metal/rendering.rb#6 module ActionController::Rendering extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionController::Rendering::ClassMethods - # Renders a template and assigns the result to +self.response_body+. + # Renders a template and assigns the result to `self.response_body`. + # + # If no rendering mode option is specified, the template will be derived from + # the first argument. + # + # render "posts/show" + # # => renders app/views/posts/show.html.erb + # + # # In a PostsController action... + # render :show + # # => renders app/views/posts/show.html.erb + # + # If the first argument responds to `render_in`, the template will be rendered + # by calling `render_in` with the current view context. + # + # class Greeting + # def render_in(view_context) + # view_context.render html: "

Hello, World

" + # end # - # If no rendering mode option is specified, the template will be derived - # from the first argument. + # def format + # :html + # end + # end + # + # render(Greeting.new) + # # => "

Hello, World

" + # + # render(renderable: Greeting.new) + # # => "

Hello, World

" # - # render "posts/show" - # # => renders app/views/posts/show.html.erb + # #### Rendering Mode # - # # In a PostsController action... - # render :show - # # => renders app/views/posts/show.html.erb + # `:partial` + # : See ActionView::PartialRenderer for details. # - # If the first argument responds to +render_in+, the template will be - # rendered by calling +render_in+ with the current view context. + # render partial: "posts/form", locals: { post: Post.new } + # # => renders app/views/posts/_form.html.erb # - # ==== \Rendering Mode + # `:file` + # : Renders the contents of a file. This option should **not** be used with + # unsanitized user input. # - # [+:partial+] - # See ActionView::PartialRenderer for details. + # render file: "/path/to/some/file" + # # => renders /path/to/some/file # - # render partial: "posts/form", locals: { post: Post.new } - # # => renders app/views/posts/_form.html.erb + # `:inline` + # : Renders an ERB template string. # - # [+:file+] - # Renders the contents of a file. This option should not be used - # with unsanitized user input. + # @name = "World" + # render inline: "

Hello, <%= @name %>!

" + # # => renders "

Hello, World!

" # - # render file: "/path/to/some/file" - # # => renders /path/to/some/file + # `:body` + # : Renders the provided text, and sets the content type as `text/plain`. # - # [+:inline+] - # Renders an ERB template string. + # render body: "Hello, World!" + # # => renders "Hello, World!" # - # @name = "World" - # render inline: "

Hello, <%= @name %>!

" - # # => renders "

Hello, World!

" + # `:plain` + # : Renders the provided text, and sets the content type as `text/plain`. # - # [+:body+] - # Renders the provided text, and sets the content type as +text/plain+. + # render plain: "Hello, World!" + # # => renders "Hello, World!" # - # render body: "Hello, World!" - # # => renders "Hello, World!" + # `:html` + # : Renders the provided HTML string, and sets the content type as + # `text/html`. If the string is not `html_safe?`, performs HTML escaping on + # the string before rendering. # - # [+:plain+] - # Renders the provided text, and sets the content type as +text/plain+. + # render html: "

Hello, World!

".html_safe + # # => renders "

Hello, World!

" # - # render plain: "Hello, World!" - # # => renders "Hello, World!" + # render html: "

Hello, World!

" + # # => renders "<h1>Hello, World!</h1>" # - # [+:html+] - # Renders the provided HTML string, and sets the content type as +text/html+. - # If the string is not +html_safe?+, performs HTML escaping on the string - # before rendering. + # `:json` + # : Renders the provided object as JSON, and sets the content type as + # `application/json`. If the object is not a string, it will be converted to + # JSON by calling `to_json`. # - # render html: "

Hello, World!

".html_safe - # # => renders "

Hello, World!

" + # render json: { hello: "world" } + # # => renders "{\"hello\":\"world\"}" # - # render html: "

Hello, World!

" - # # => renders "<h1>Hello, World!</h1>" + # `:renderable` + # : Renders the provided object by calling `render_in` with the current view + # context. The response format is determined by calling `format` on the + # renderable if it responds to `format`, falling back to `text/html` by + # default. # - # [+:json+] - # Renders the provided object as JSON, and sets the content type as - # +application/json+. If the object is not a string, it will be converted - # to JSON by calling +to_json+. + # render renderable: Greeting.new + # # => renders "

Hello, World

" # - # render json: { hello: "world" } - # # => renders "{\"hello\":\"world\"}" # # By default, when a rendering mode is specified, no layout template is # rendered. # - # ==== Options + # #### Options # - # [+:assigns+] - # Hash of instance variable assignments for the template. + # `:assigns` + # : Hash of instance variable assignments for the template. # - # render inline: "

Hello, <%= @name %>!

", assigns: { name: "World" } - # # => renders "

Hello, World!

" + # render inline: "

Hello, <%= @name %>!

", assigns: { name: "World" } + # # => renders "

Hello, World!

" # - # [+:locals+] - # Hash of local variable assignments for the template. + # `:locals` + # : Hash of local variable assignments for the template. # - # render inline: "

Hello, <%= name %>!

", locals: { name: "World" } - # # => renders "

Hello, World!

" + # render inline: "

Hello, <%= name %>!

", locals: { name: "World" } + # # => renders "

Hello, World!

" # - # [+:layout+] - # The layout template to render. Can also be +false+ or +true+ to disable - # or (re)enable the default layout template. + # `:layout` + # : The layout template to render. Can also be `false` or `true` to disable or + # (re)enable the default layout template. # - # render "posts/show", layout: "holiday" - # # => renders app/views/posts/show.html.erb with the app/views/layouts/holiday.html.erb layout + # render "posts/show", layout: "holiday" + # # => renders app/views/posts/show.html.erb with the app/views/layouts/holiday.html.erb layout # - # render "posts/show", layout: false - # # => renders app/views/posts/show.html.erb with no layout + # render "posts/show", layout: false + # # => renders app/views/posts/show.html.erb with no layout # - # render inline: "

Hello, World!

", layout: true - # # => renders "

Hello, World!

" with the default layout + # render inline: "

Hello, World!

", layout: true + # # => renders "

Hello, World!

" with the default layout # - # [+:status+] - # The HTTP status code to send with the response. Can be specified as a - # number or as the status name in Symbol form. Defaults to 200. + # `:status` + # : The HTTP status code to send with the response. Can be specified as a + # number or as the status name in Symbol form. Defaults to 200. # - # render "posts/new", status: 422 - # # => renders app/views/posts/new.html.erb with HTTP status code 422 + # render "posts/new", status: 422 + # # => renders app/views/posts/new.html.erb with HTTP status code 422 # - # render "posts/new", status: :unprocessable_entity - # # => renders app/views/posts/new.html.erb with HTTP status code 422 + # render "posts/new", status: :unprocessable_entity + # # => renders app/views/posts/new.html.erb with HTTP status code 422 # # -- # Check for double render errors and set the content_type after rendering. # # @raise [::AbstractController::DoubleRenderError] # - # source://actionpack//lib/action_controller/metal/rendering.rb#137 + # source://actionpack//lib/action_controller/metal/rendering.rb#165 def render(*args); end - # source://actionpack//lib/action_controller/metal/rendering.rb#157 + # source://actionpack//lib/action_controller/metal/rendering.rb#185 def render_to_body(options = T.unsafe(nil)); end # Similar to #render, but only returns the rendered template as a string, - # instead of setting +self.response_body+. + # instead of setting `self.response_body`. # -- # Override render_to_string because body can now be set to a Rack body. # - # source://actionpack//lib/action_controller/metal/rendering.rb#146 + # source://actionpack//lib/action_controller/metal/rendering.rb#174 def render_to_string(*_arg0); end private - # Normalize arguments by catching blocks and setting them on :update. - # - # source://actionpack//lib/action_controller/metal/rendering.rb#199 - def _normalize_args(action = T.unsafe(nil), options = T.unsafe(nil), &blk); end - # Normalize both text and status options. # - # source://actionpack//lib/action_controller/metal/rendering.rb#206 + # source://actionpack//lib/action_controller/metal/rendering.rb#227 def _normalize_options(options); end - # source://actionpack//lib/action_controller/metal/rendering.rb#220 + # source://actionpack//lib/action_controller/metal/rendering.rb#241 def _normalize_text(options); end # Process controller specific options, as status, content-type and location. # - # source://actionpack//lib/action_controller/metal/rendering.rb#229 + # source://actionpack//lib/action_controller/metal/rendering.rb#250 def _process_options(options); end - # source://actionpack//lib/action_controller/metal/rendering.rb#168 + # source://actionpack//lib/action_controller/metal/rendering.rb#196 def _process_variant(options); end - # source://actionpack//lib/action_controller/metal/rendering.rb#174 + # source://actionpack//lib/action_controller/metal/rendering.rb#202 def _render_in_priorities(options); end - # source://actionpack//lib/action_controller/metal/rendering.rb#182 + # source://actionpack//lib/action_controller/metal/rendering.rb#210 def _set_html_content_type; end - # source://actionpack//lib/action_controller/metal/rendering.rb#186 + # source://actionpack//lib/action_controller/metal/rendering.rb#214 def _set_rendered_content_type(format); end - # source://actionpack//lib/action_controller/metal/rendering.rb#192 + # source://actionpack//lib/action_controller/metal/rendering.rb#220 def _set_vary_header; end # Before processing, set the request formats in current controller formats. # - # source://actionpack//lib/action_controller/metal/rendering.rb#163 + # source://actionpack//lib/action_controller/metal/rendering.rb#191 def process_action(*_arg0); end end -# source://actionpack//lib/action_controller/metal/rendering.rb#9 +# source://actionpack//lib/action_controller/metal/rendering.rb#11 module ActionController::Rendering::ClassMethods - # source://actionpack//lib/action_controller/metal/rendering.rb#21 + # source://actionpack//lib/action_controller/metal/rendering.rb#23 def inherited(klass); end - # source://actionpack//lib/action_controller/metal/rendering.rb#11 + # source://actionpack//lib/action_controller/metal/rendering.rb#13 def render(*_arg0, **_arg1, &_arg2); end - # Returns a renderer instance (inherited from ActionController::Renderer) - # for the controller. + # Returns a renderer instance (inherited from ActionController::Renderer) for + # the controller. # - # source://actionpack//lib/action_controller/metal/rendering.rb#15 + # source://actionpack//lib/action_controller/metal/rendering.rb#17 def renderer; end - # source://actionpack//lib/action_controller/metal/rendering.rb#17 + # source://actionpack//lib/action_controller/metal/rendering.rb#19 def setup_renderer!; end end -# source://actionpack//lib/action_controller/metal/rendering.rb#7 +# source://actionpack//lib/action_controller/metal/rendering.rb#9 ActionController::Rendering::RENDER_FORMATS_IN_PRIORITY = T.let(T.unsafe(nil), Array) -# Controller actions are protected from Cross-Site Request Forgery (CSRF) attacks -# by including a token in the rendered HTML for your application. This token is -# stored as a random string in the session, to which an attacker does not have -# access. When a request reaches your application, \Rails verifies the received -# token with the token in the session. All requests are checked except GET requests -# as these should be idempotent. Keep in mind that all session-oriented requests -# are CSRF protected by default, including JavaScript and HTML requests. +# # Action Controller Request Forgery Protection +# +# Controller actions are protected from Cross-Site Request Forgery (CSRF) +# attacks by including a token in the rendered HTML for your application. This +# token is stored as a random string in the session, to which an attacker does +# not have access. When a request reaches your application, Rails verifies the +# received token with the token in the session. All requests are checked except +# GET requests as these should be idempotent. Keep in mind that all +# session-oriented requests are CSRF protected by default, including JavaScript +# and HTML requests. # # Since HTML and JavaScript requests are typically made from the browser, we -# need to ensure to verify request authenticity for the web browser. We can -# use session-oriented authentication for these types of requests, by using -# the protect_from_forgery method in our controllers. +# need to ensure to verify request authenticity for the web browser. We can use +# session-oriented authentication for these types of requests, by using the +# `protect_from_forgery` method in our controllers. # # GET requests are not protected since they don't have side effects like writing # to the database and don't leak sensitive information. JavaScript requests are -# an exception: a third-party site can use a +# "> # -# The first two characters (">) are required in case the exception happens -# while rendering attributes for a given tag. You can check the real cause -# for the exception in your logger. +# The first two characters (`">`) are required in case the exception happens +# while rendering attributes for a given tag. You can check the real cause for +# the exception in your logger. # -# == Web server support +# ## Web server support # -# Not all web servers support streaming out-of-the-box. You need to check -# the instructions for each of them. +# Not all web servers support streaming out-of-the-box. You need to check the +# instructions for each of them. # -# ==== Unicorn +# #### Unicorn # -# Unicorn supports streaming but it needs to be configured. For this, you -# need to create a config file as follow: +# Unicorn supports streaming but it needs to be configured. For this, you need +# to create a config file as follow: # -# # unicorn.config.rb -# listen 3000, tcp_nopush: false +# # unicorn.config.rb +# listen 3000, tcp_nopush: false # # And use it on initialization: # -# unicorn_rails --config-file unicorn.config.rb +# unicorn_rails --config-file unicorn.config.rb +# +# You may also want to configure other parameters like `:tcp_nodelay`. +# +# For more information, please check the +# [documentation](https://bogomips.org/unicorn/Unicorn/Configurator.html#method- +# i-listen). +# +# If you are using Unicorn with NGINX, you may need to tweak NGINX. Streaming +# should work out of the box on Rainbows. # -# You may also want to configure other parameters like :tcp_nodelay. -# Please check its documentation for more information: https://bogomips.org/unicorn/Unicorn/Configurator.html#method-i-listen +# #### Passenger # -# If you are using Unicorn with NGINX, you may need to tweak NGINX. -# Streaming should work out of the box on Rainbows. +# Phusion Passenger with NGINX, offers two streaming mechanisms out of the box. # -# ==== Passenger +# 1. NGINX response buffering mechanism which is dependent on the value of +# `passenger_buffer_response` option (default is "off"). +# 2. Passenger buffering system which is always 'on' irrespective of the value +# of `passenger_buffer_response`. # -# To be described. # -# source://actionpack//lib/action_controller/metal/streaming.rb#195 +# When `passenger_buffer_response` is turned "on", then streaming would be done +# at the NGINX level which waits until the application is done sending the +# response back to the client. +# +# For more information, please check the [documentation] +# (https://www.phusionpassenger.com/docs/references/config_reference/nginx/#passenger_buffer_response). +# +# source://actionpack//lib/action_controller/metal/streaming.rb#208 module ActionController::Streaming private # Set proper cache control and transfer encoding when streaming # - # source://actionpack//lib/action_controller/metal/streaming.rb#198 + # source://actionpack//lib/action_controller/metal/streaming.rb#240 def _process_options(options); end - # Call render_body if we are streaming instead of usual +render+. + # Call render_body if we are streaming instead of usual `render`. # - # source://actionpack//lib/action_controller/metal/streaming.rb#212 + # source://actionpack//lib/action_controller/metal/streaming.rb#254 def _render_template(options); end end -# == Strong \Parameters +# source://actionpack//lib/action_controller/metal/streaming.rb#209 +class ActionController::Streaming::Body + # Store the response body to be chunked. + # + # @return [Body] a new instance of Body + # + # source://actionpack//lib/action_controller/metal/streaming.rb#214 + def initialize(body); end + + # Close the response body if the response body supports it. + # + # source://actionpack//lib/action_controller/metal/streaming.rb#233 + def close; end + + # For each element yielded by the response body, yield the element in chunked + # encoding. + # + # @yield [TAIL] + # + # source://actionpack//lib/action_controller/metal/streaming.rb#220 + def each(&block); end +end + +# source://actionpack//lib/action_controller/metal/streaming.rb#211 +ActionController::Streaming::Body::TAIL = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_controller/metal/streaming.rb#210 +ActionController::Streaming::Body::TERM = T.let(T.unsafe(nil), String) + +# # Strong Parameters # -# It provides an interface for protecting attributes from end-user -# assignment. This makes Action Controller parameters forbidden -# to be used in Active Model mass assignment until they have been explicitly -# enumerated. +# It provides an interface for protecting attributes from end-user assignment. +# This makes Action Controller parameters forbidden to be used in Active Model +# mass assignment until they have been explicitly enumerated. # # In addition, parameters can be marked as required and flow through a -# predefined raise/rescue flow to end up as a 400 Bad Request with no -# effort. -# -# class PeopleController < ActionController::Base -# # Using "Person.create(params[:person])" would raise an -# # ActiveModel::ForbiddenAttributesError exception because it'd -# # be using mass assignment without an explicit permit step. -# # This is the recommended form: -# def create -# Person.create(person_params) -# end -# -# # This will pass with flying colors as long as there's a person key in the -# # parameters, otherwise it'll raise an ActionController::ParameterMissing -# # exception, which will get caught by ActionController::Base and turned -# # into a 400 Bad Request reply. -# def update -# redirect_to current_account.people.find(params[:id]).tap { |person| -# person.update!(person_params) -# } -# end +# predefined raise/rescue flow to end up as a `400 Bad Request` with no effort. +# +# class PeopleController < ActionController::Base +# # Using "Person.create(params[:person])" would raise an +# # ActiveModel::ForbiddenAttributesError exception because it'd +# # be using mass assignment without an explicit permit step. +# # This is the recommended form: +# def create +# Person.create(person_params) +# end # -# private -# # Using a private method to encapsulate the permissible parameters is -# # a good pattern since you'll be able to reuse the same permit -# # list between create and update. Also, you can specialize this method -# # with per-user checking of permissible attributes. -# def person_params -# params.require(:person).permit(:name, :age) +# # This will pass with flying colors as long as there's a person key in the +# # parameters, otherwise it'll raise an ActionController::ParameterMissing +# # exception, which will get caught by ActionController::Base and turned +# # into a 400 Bad Request reply. +# def update +# redirect_to current_account.people.find(params[:id]).tap { |person| +# person.update!(person_params) +# } # end -# end # -# In order to use accepts_nested_attributes_for with Strong \Parameters, you -# will need to specify which nested attributes should be permitted. You might want -# to allow +:id+ and +:_destroy+, see ActiveRecord::NestedAttributes for more information. +# private +# # Using a private method to encapsulate the permissible parameters is +# # a good pattern since you'll be able to reuse the same permit +# # list between create and update. Also, you can specialize this method +# # with per-user checking of permissible attributes. +# def person_params +# params.require(:person).permit(:name, :age) +# end +# end # -# class Person -# has_many :pets -# accepts_nested_attributes_for :pets -# end +# In order to use `accepts_nested_attributes_for` with Strong Parameters, you +# will need to specify which nested attributes should be permitted. You might +# want to allow `:id` and `:_destroy`, see ActiveRecord::NestedAttributes for +# more information. # -# class PeopleController < ActionController::Base -# def create -# Person.create(person_params) +# class Person +# has_many :pets +# accepts_nested_attributes_for :pets # end # -# ... +# class PeopleController < ActionController::Base +# def create +# Person.create(person_params) +# end # -# private +# ... # -# def person_params -# # It's mandatory to specify the nested attributes that should be permitted. -# # If you use `permit` with just the key that points to the nested attributes hash, -# # it will return an empty hash. -# params.require(:person).permit(:name, :age, pets_attributes: [ :id, :name, :category ]) -# end -# end +# private # -# See ActionController::Parameters.require and ActionController::Parameters.permit -# for more information. +# def person_params +# # It's mandatory to specify the nested attributes that should be permitted. +# # If you use `permit` with just the key that points to the nested attributes hash, +# # it will return an empty hash. +# params.require(:person).permit(:name, :age, pets_attributes: [ :id, :name, :category ]) +# end +# end # -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1221 +# See ActionController::Parameters.require and +# ActionController::Parameters.permit for more information. +# +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#1323 module ActionController::StrongParameters - # Returns a new ActionController::Parameters object that - # has been instantiated with the request.parameters. + # Returns a new ActionController::Parameters object that has been instantiated + # with the `request.parameters`. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1224 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1326 def params; end - # Assigns the given +value+ to the +params+ hash. If +value+ - # is a Hash, this will create an ActionController::Parameters - # object that has been instantiated with the given +value+ hash. + # Assigns the given `value` to the `params` hash. If `value` is a Hash, this + # will create an ActionController::Parameters object that has been instantiated + # with the given `value` hash. # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1239 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#1341 def params=(value); end end -# source://actionpack//lib/action_controller/template_assertions.rb#4 +# source://actionpack//lib/action_controller/template_assertions.rb#6 module ActionController::TemplateAssertions # @raise [NoMethodError] # - # source://actionpack//lib/action_controller/template_assertions.rb#5 + # source://actionpack//lib/action_controller/template_assertions.rb#7 def assert_template(options = T.unsafe(nil), message = T.unsafe(nil)); end end -# Superclass for ActionController functional tests. Functional tests allow you to -# test a single controller action per test method. +# # Action Controller Test Case +# +# Superclass for ActionController functional tests. Functional tests allow you +# to test a single controller action per test method. # -# == Use integration style controller tests over functional style controller tests. +# ## Use integration style controller tests over functional style controller tests. # # Rails discourages the use of functional tests in favor of integration tests # (use ActionDispatch::IntegrationTest). # -# New Rails applications no longer generate functional style controller tests and they should -# only be used for backward compatibility. Integration style controller tests perform actual -# requests, whereas functional style controller tests merely simulate a request. Besides, -# integration tests are as fast as functional tests and provide lot of helpers such as +as+, -# +parsed_body+ for effective testing of controller actions including even API endpoints. +# New Rails applications no longer generate functional style controller tests +# and they should only be used for backward compatibility. Integration style +# controller tests perform actual requests, whereas functional style controller +# tests merely simulate a request. Besides, integration tests are as fast as +# functional tests and provide lot of helpers such as `as`, `parsed_body` for +# effective testing of controller actions including even API endpoints. # -# == Basic example +# ## Basic example # # Functional tests are written as follows: -# 1. First, one uses the +get+, +post+, +patch+, +put+, +delete+, or +head+ method to simulate -# an HTTP request. -# 2. Then, one asserts whether the current state is as expected. "State" can be anything: -# the controller's HTTP response, the database contents, etc. +# 1. First, one uses the `get`, `post`, `patch`, `put`, `delete`, or `head` +# method to simulate an HTTP request. +# 2. Then, one asserts whether the current state is as expected. "State" can be +# anything: the controller's HTTP response, the database contents, etc. +# # # For example: # -# class BooksControllerTest < ActionController::TestCase -# def test_create -# # Simulate a POST response with the given HTTP parameters. -# post(:create, params: { book: { title: "Love Hina" }}) +# class BooksControllerTest < ActionController::TestCase +# def test_create +# # Simulate a POST response with the given HTTP parameters. +# post(:create, params: { book: { title: "Love Hina" }}) # -# # Asserts that the controller tried to redirect us to -# # the created book's URI. -# assert_response :found +# # Asserts that the controller tried to redirect us to +# # the created book's URI. +# assert_response :found # -# # Asserts that the controller really put the book in the database. -# assert_not_nil Book.find_by(title: "Love Hina") +# # Asserts that the controller really put the book in the database. +# assert_not_nil Book.find_by(title: "Love Hina") +# end # end -# end # # You can also send a real document in the simulated HTTP request. # -# def test_create -# json = {book: { title: "Love Hina" }}.to_json -# post :create, body: json -# end +# def test_create +# json = {book: { title: "Love Hina" }}.to_json +# post :create, body: json +# end +# +# ## Special instance variables +# +# ActionController::TestCase will also automatically provide the following +# instance variables for use in the tests: +# +# : The controller instance that will be tested. # -# == Special instance variables +# : An ActionController::TestRequest, representing the current HTTP request. +# You can modify this object before sending the HTTP request. For example, +# you might want to set some session properties before sending a GET +# request. # -# ActionController::TestCase will also automatically provide the following instance -# variables for use in the tests: +# : An ActionDispatch::TestResponse object, representing the response of the +# last HTTP response. In the above example, `@response` becomes valid after +# calling `post`. If the various assert methods are not sufficient, then you +# may use this object to inspect the HTTP response in detail. # -# @controller:: -# The controller instance that will be tested. -# @request:: -# An ActionController::TestRequest, representing the current HTTP -# request. You can modify this object before sending the HTTP request. For example, -# you might want to set some session properties before sending a GET request. -# @response:: -# An ActionDispatch::TestResponse object, representing the response -# of the last HTTP response. In the above example, @response becomes valid -# after calling +post+. If the various assert methods are not sufficient, then you -# may use this object to inspect the HTTP response in detail. # -# == Controller is automatically inferred +# ## Controller is automatically inferred # # ActionController::TestCase will automatically infer the controller under test # from the test class name. If the controller cannot be inferred from the test -# class name, you can explicitly set it with +tests+. +# class name, you can explicitly set it with `tests`. # -# class SpecialEdgeCaseWidgetsControllerTest < ActionController::TestCase -# tests WidgetController -# end +# class SpecialEdgeCaseWidgetsControllerTest < ActionController::TestCase +# tests WidgetController +# end +# +# ## Testing controller internals # -# == \Testing controller internals +# In addition to these specific assertions, you also have easy access to various +# collections that the regular test/unit assertions can be used against. These +# collections are: # -# In addition to these specific assertions, you also have easy access to various collections that the regular test/unit assertions -# can be used against. These collections are: +# * session: Objects being saved in the session. +# * flash: The flash objects currently in the session. +# * cookies: Cookies being sent to the user on this request. # -# * session: Objects being saved in the session. -# * flash: The flash objects currently in the session. -# * cookies: \Cookies being sent to the user on this request. # # These collections can be used just like any other hash: # -# assert_equal "Dave", cookies[:name] # makes sure that a cookie called :name was set as "Dave" -# assert flash.empty? # makes sure that there's nothing in the flash +# assert_equal "Dave", cookies[:name] # makes sure that a cookie called :name was set as "Dave" +# assert flash.empty? # makes sure that there's nothing in the flash # -# On top of the collections, you have the complete URL that a given action redirected to available in redirect_to_url. +# On top of the collections, you have the complete URL that a given action +# redirected to available in `redirect_to_url`. # -# For redirects within the same controller, you can even call follow_redirect and the redirect will be followed, triggering another -# action call which can then be asserted against. +# For redirects within the same controller, you can even call follow_redirect +# and the redirect will be followed, triggering another action call which can +# then be asserted against. # -# == Manipulating session and cookie variables +# ## Manipulating session and cookie variables # -# Sometimes you need to set up the session and cookie variables for a test. -# To do this just assign a value to the session or cookie collection: +# Sometimes you need to set up the session and cookie variables for a test. To +# do this just assign a value to the session or cookie collection: # -# session[:key] = "value" -# cookies[:key] = "value" +# session[:key] = "value" +# cookies[:key] = "value" # # To clear the cookies for a test just clear the cookie collection: # -# cookies.clear +# cookies.clear # -# == \Testing named routes +# ## Testing named routes # -# If you're using named routes, they can be easily tested using the original named routes' methods straight in the test case. +# If you're using named routes, they can be easily tested using the original +# named routes' methods straight in the test case. # -# assert_redirected_to page_url(title: 'foo') +# assert_redirected_to page_url(title: 'foo') # -# source://actionpack//lib/action_controller/test_case.rb#335 +# source://actionpack//lib/action_controller/test_case.rb#358 class ActionController::TestCase < ::ActiveSupport::TestCase include ::ActiveSupport::Testing::ConstantLookup + include ::ActionDispatch::TestProcess::FixtureFile + include ::ActionDispatch::TestProcess include ::ActionDispatch::Assertions::ResponseAssertions - include ::ActionDispatch::Assertions::RoutingAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions - include ::ActionDispatch::TestProcess::FixtureFile - include ::ActionDispatch::TestProcess include ::ActionController::TestCase::Behavior include ::ActionController::TemplateAssertions + include ::ActionDispatch::Assertions::RoutingAssertions include ::ActionDispatch::Assertions extend ::ActiveSupport::Testing::ConstantLookup::ClassMethods extend ::ActionController::TestCase::Behavior::ClassMethods + extend ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods - # source://actionpack//lib/action_controller/test_case.rb#561 + # source://actionpack//lib/action_controller/test_case.rb#591 def _controller_class; end - # source://actionpack//lib/action_controller/test_case.rb#561 + # source://actionpack//lib/action_controller/test_case.rb#591 def _controller_class=(_arg0); end - # source://actionpack//lib/action_controller/test_case.rb#561 + # source://actionpack//lib/action_controller/test_case.rb#591 def _controller_class?; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://actionpack//lib/action_controller/test_case.rb#561 + # source://actionpack//lib/action_controller/test_case.rb#591 def _controller_class; end - # source://actionpack//lib/action_controller/test_case.rb#561 + # source://actionpack//lib/action_controller/test_case.rb#591 def _controller_class=(value); end - # source://actionpack//lib/action_controller/test_case.rb#561 + # source://actionpack//lib/action_controller/test_case.rb#591 def _controller_class?; end - # source://actionpack//lib/action_controller/test_case.rb#336 + # source://actionpack//lib/action_controller/test_case.rb#359 def executor_around_each_request; end - # source://actionpack//lib/action_controller/test_case.rb#336 + # source://actionpack//lib/action_controller/test_case.rb#359 def executor_around_each_request=(_arg0); end end end -# source://actionpack//lib/action_controller/test_case.rb#338 +# source://actionpack//lib/action_controller/test_case.rb#361 module ActionController::TestCase::Behavior include ::ActionDispatch::TestProcess::FixtureFile include ::ActionDispatch::TestProcess + include ::Rails::Dom::Testing::Assertions::DomAssertions + include ::Rails::Dom::Testing::Assertions::SelectorAssertions + include ::Rails::Dom::Testing::Assertions extend ::ActiveSupport::Concern include GeneratedInstanceMethods include ::ActiveSupport::Testing::ConstantLookup - include ::Rails::Dom::Testing::Assertions include ::ActionController::TemplateAssertions + include ::ActionDispatch::Assertions::RoutingAssertions include ::ActionDispatch::Assertions mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveSupport::Testing::ConstantLookup::ClassMethods mixes_in_class_methods ::ActionController::TestCase::Behavior::ClassMethods + mixes_in_class_methods ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods - # source://actionpack//lib/action_controller/test_case.rb#554 + # source://actionpack//lib/action_controller/test_case.rb#584 def build_response(klass); end - # source://actionpack//lib/action_controller/test_case.rb#514 + # source://actionpack//lib/action_controller/test_case.rb#544 def controller_class_name; end - # Simulate a DELETE request with the given parameters and set/volley the response. - # See +get+ for more details. + # Simulate a DELETE request with the given parameters and set/volley the + # response. See `get` for more details. # - # source://actionpack//lib/action_controller/test_case.rb#429 + # source://actionpack//lib/action_controller/test_case.rb#455 def delete(action, **args); end - # source://actionpack//lib/action_controller/test_case.rb#518 + # source://actionpack//lib/action_controller/test_case.rb#548 def generated_path(generated_extras); end # Simulate a GET request with the given parameters. # - # - +action+: The controller action to call. - # - +params+: The hash with HTTP parameters that you want to pass. This may be +nil+. - # - +body+: The request body with a string that is appropriately encoded - # (application/x-www-form-urlencoded or multipart/form-data). - # - +session+: A hash of parameters to store in the session. This may be +nil+. - # - +flash+: A hash of parameters to store in the flash. This may be +nil+. + # * `action`: The controller action to call. + # * `params`: The hash with HTTP parameters that you want to pass. This may be + # `nil`. + # * `body`: The request body with a string that is appropriately encoded + # (`application/x-www-form-urlencoded` or `multipart/form-data`). + # * `session`: A hash of parameters to store in the session. This may be + # `nil`. + # * `flash`: A hash of parameters to store in the flash. This may be `nil`. + # # - # You can also simulate POST, PATCH, PUT, DELETE, and HEAD requests with - # +post+, +patch+, +put+, +delete+, and +head+. - # Example sending parameters, session, and setting a flash message: + # You can also simulate POST, PATCH, PUT, DELETE, and HEAD requests with `post`, + # `patch`, `put`, `delete`, and `head`. Example sending parameters, session, and + # setting a flash message: # - # get :show, - # params: { id: 7 }, - # session: { user_id: 1 }, - # flash: { notice: 'This is flash message' } + # get :show, + # params: { id: 7 }, + # session: { user_id: 1 }, + # flash: { notice: 'This is flash message' } # # Note that the request method is not verified. The different methods are # available to make the tests more expressive. # - # source://actionpack//lib/action_controller/test_case.rb#403 + # source://actionpack//lib/action_controller/test_case.rb#429 def get(action, **args); end # Simulate a HEAD request with the given parameters and set/volley the response. - # See +get+ for more details. + # See `get` for more details. # - # source://actionpack//lib/action_controller/test_case.rb#435 + # source://actionpack//lib/action_controller/test_case.rb#461 def head(action, **args); end - # Simulate a PATCH request with the given parameters and set/volley the response. - # See +get+ for more details. + # Simulate a PATCH request with the given parameters and set/volley the + # response. See `get` for more details. # - # source://actionpack//lib/action_controller/test_case.rb#417 + # source://actionpack//lib/action_controller/test_case.rb#443 def patch(action, **args); end # Simulate a POST request with the given parameters and set/volley the response. - # See +get+ for more details. + # See `get` for more details. # - # source://actionpack//lib/action_controller/test_case.rb#411 + # source://actionpack//lib/action_controller/test_case.rb#437 def post(action, **args); end - # Simulate an HTTP request to +action+ by specifying request method, - # parameters and set/volley the response. - # - # - +action+: The controller action to call. - # - +method+: Request method used to send the HTTP request. Possible values - # are +GET+, +POST+, +PATCH+, +PUT+, +DELETE+, +HEAD+. Defaults to +GET+. Can be a symbol. - # - +params+: The hash with HTTP parameters that you want to pass. This may be +nil+. - # - +body+: The request body with a string that is appropriately encoded - # (application/x-www-form-urlencoded or multipart/form-data). - # - +session+: A hash of parameters to store in the session. This may be +nil+. - # - +flash+: A hash of parameters to store in the flash. This may be +nil+. - # - +format+: Request format. Defaults to +nil+. Can be string or symbol. - # - +as+: Content type. Defaults to +nil+. Must be a symbol that corresponds - # to a mime type. - # - # Example calling +create+ action and sending two params: - # - # process :create, - # method: 'POST', - # params: { - # user: { name: 'Gaurish Sharma', email: 'user@example.com' } - # }, - # session: { user_id: 1 }, - # flash: { notice: 'This is flash message' } - # - # To simulate +GET+, +POST+, +PATCH+, +PUT+, +DELETE+, and +HEAD+ requests - # prefer using #get, #post, #patch, #put, #delete and #head methods - # respectively which will make tests more expressive. + # Simulate an HTTP request to `action` by specifying request method, parameters + # and set/volley the response. + # + # * `action`: The controller action to call. + # * `method`: Request method used to send the HTTP request. Possible values + # are `GET`, `POST`, `PATCH`, `PUT`, `DELETE`, `HEAD`. Defaults to `GET`. + # Can be a symbol. + # * `params`: The hash with HTTP parameters that you want to pass. This may be + # `nil`. + # * `body`: The request body with a string that is appropriately encoded + # (`application/x-www-form-urlencoded` or `multipart/form-data`). + # * `session`: A hash of parameters to store in the session. This may be + # `nil`. + # * `flash`: A hash of parameters to store in the flash. This may be `nil`. + # * `format`: Request format. Defaults to `nil`. Can be string or symbol. + # * `as`: Content type. Defaults to `nil`. Must be a symbol that corresponds + # to a mime type. + # + # + # Example calling `create` action and sending two params: + # + # process :create, + # method: 'POST', + # params: { + # user: { name: 'Gaurish Sharma', email: 'user@example.com' } + # }, + # session: { user_id: 1 }, + # flash: { notice: 'This is flash message' } + # + # To simulate `GET`, `POST`, `PATCH`, `PUT`, `DELETE`, and `HEAD` requests + # prefer using #get, #post, #patch, #put, #delete and #head methods respectively + # which will make tests more expressive. # # It's not recommended to make more than one request in the same test. Instance # variables that are set in one request will not persist to the next request, @@ -7858,49 +8586,49 @@ module ActionController::TestCase::Behavior # # Note that the request method is not verified. # - # source://actionpack//lib/action_controller/test_case.rb#474 + # source://actionpack//lib/action_controller/test_case.rb#504 def process(action, method: T.unsafe(nil), params: T.unsafe(nil), session: T.unsafe(nil), body: T.unsafe(nil), flash: T.unsafe(nil), format: T.unsafe(nil), xhr: T.unsafe(nil), as: T.unsafe(nil)); end # Simulate a PUT request with the given parameters and set/volley the response. - # See +get+ for more details. + # See `get` for more details. # - # source://actionpack//lib/action_controller/test_case.rb#423 + # source://actionpack//lib/action_controller/test_case.rb#449 def put(action, **args); end - # source://actionpack//lib/action_controller/test_case.rb#522 + # source://actionpack//lib/action_controller/test_case.rb#552 def query_parameter_names(generated_extras); end # Returns the value of attribute request. # - # source://actionpack//lib/action_controller/test_case.rb#344 + # source://actionpack//lib/action_controller/test_case.rb#367 def request; end # Returns the value of attribute response. # - # source://actionpack//lib/action_controller/test_case.rb#344 + # source://actionpack//lib/action_controller/test_case.rb#367 def response; end - # source://actionpack//lib/action_controller/test_case.rb#526 + # source://actionpack//lib/action_controller/test_case.rb#556 def setup_controller_request_and_response; end private - # source://actionpack//lib/action_controller/test_case.rb#646 + # source://actionpack//lib/action_controller/test_case.rb#676 def check_required_ivars; end - # source://actionpack//lib/action_controller/test_case.rb#642 + # source://actionpack//lib/action_controller/test_case.rb#672 def document_root_element; end - # source://actionpack//lib/action_controller/test_case.rb#597 + # source://actionpack//lib/action_controller/test_case.rb#627 def process_controller_response(action, cookies, xhr); end - # source://actionpack//lib/action_controller/test_case.rb#632 + # source://actionpack//lib/action_controller/test_case.rb#662 def scrub_env!(env); end - # source://actionpack//lib/action_controller/test_case.rb#567 + # source://actionpack//lib/action_controller/test_case.rb#597 def setup_request(controller_class_name, action, parameters, session, flash, xhr); end - # source://actionpack//lib/action_controller/test_case.rb#589 + # source://actionpack//lib/action_controller/test_case.rb#619 def wrap_execution(&block); end module GeneratedClassMethods @@ -7916,197 +8644,202 @@ module ActionController::TestCase::Behavior end end -# source://actionpack//lib/action_controller/test_case.rb#346 +# source://actionpack//lib/action_controller/test_case.rb#369 module ActionController::TestCase::Behavior::ClassMethods - # source://actionpack//lib/action_controller/test_case.rb#368 + # source://actionpack//lib/action_controller/test_case.rb#391 def controller_class; end - # source://actionpack//lib/action_controller/test_case.rb#364 + # source://actionpack//lib/action_controller/test_case.rb#387 def controller_class=(new_class); end - # source://actionpack//lib/action_controller/test_case.rb#376 + # source://actionpack//lib/action_controller/test_case.rb#399 def determine_default_controller_class(name); end - # Sets the controller class name. Useful if the name can't be inferred from test class. - # Normalizes +controller_class+ before using. + # Sets the controller class name. Useful if the name can't be inferred from test + # class. Normalizes `controller_class` before using. # - # tests WidgetController - # tests :widget - # tests 'widget' + # tests WidgetController + # tests :widget + # tests 'widget' # - # source://actionpack//lib/action_controller/test_case.rb#353 + # source://actionpack//lib/action_controller/test_case.rb#376 def tests(controller_class); end end -# ActionController::TestCase will be deprecated and moved to a gem in the future. -# Please use ActionDispatch::IntegrationTest going forward. +# ActionController::TestCase will be deprecated and moved to a gem in the +# future. Please use ActionDispatch::IntegrationTest going forward. # -# source://actionpack//lib/action_controller/test_case.rb#34 +# source://actionpack//lib/action_controller/test_case.rb#36 class ActionController::TestRequest < ::ActionDispatch::TestRequest # @return [TestRequest] a new instance of TestRequest # - # source://actionpack//lib/action_controller/test_case.rb#57 + # source://actionpack//lib/action_controller/test_case.rb#59 def initialize(env, session, controller_class); end - # source://actionpack//lib/action_controller/test_case.rb#76 + # source://actionpack//lib/action_controller/test_case.rb#78 def assign_parameters(routes, controller_path, action, parameters, generated_path, query_string_keys); end - # source://actionpack//lib/action_controller/test_case.rb#72 + # source://actionpack//lib/action_controller/test_case.rb#74 def content_type=(type); end # Returns the value of attribute controller_class. # - # source://actionpack//lib/action_controller/test_case.rb#42 + # source://actionpack//lib/action_controller/test_case.rb#44 def controller_class; end - # source://actionpack//lib/action_controller/test_case.rb#68 + # source://actionpack//lib/action_controller/test_case.rb#70 def query_string=(string); end private - # source://actionpack//lib/action_controller/test_case.rb#164 + # source://actionpack//lib/action_controller/test_case.rb#169 def params_parsers; end class << self # Create a new test request with default `env` values. # - # source://actionpack//lib/action_controller/test_case.rb#45 + # source://actionpack//lib/action_controller/test_case.rb#47 def create(controller_class); end - # source://actionpack//lib/action_controller/test_case.rb#38 + # source://actionpack//lib/action_controller/test_case.rb#40 def new_session; end private - # source://actionpack//lib/action_controller/test_case.rb#52 + # source://actionpack//lib/action_controller/test_case.rb#54 def default_env; end end end -# source://actionpack//lib/action_controller/test_case.rb#35 +# source://actionpack//lib/action_controller/test_case.rb#37 ActionController::TestRequest::DEFAULT_ENV = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_controller/test_case.rb#136 +# source://actionpack//lib/action_controller/test_case.rb#141 ActionController::TestRequest::ENCODER = T.let(T.unsafe(nil), T.untyped) # Methods #destroy and #load! are overridden to avoid calling methods on the # -# source://actionpack//lib/action_controller/test_case.rb#182 +# source://actionpack//lib/action_controller/test_case.rb#187 class ActionController::TestSession < ::Rack::Session::Abstract::PersistedSecure::SecureSessionHash # @return [TestSession] a new instance of TestSession # - # source://actionpack//lib/action_controller/test_case.rb#185 - def initialize(session = T.unsafe(nil)); end + # source://actionpack//lib/action_controller/test_case.rb#190 + def initialize(session = T.unsafe(nil), id = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/test_case.rb#204 + # source://actionpack//lib/action_controller/test_case.rb#210 def destroy; end - # source://actionpack//lib/action_controller/test_case.rb#208 + # source://actionpack//lib/action_controller/test_case.rb#214 def dig(*keys); end # @return [Boolean] # - # source://actionpack//lib/action_controller/test_case.rb#217 + # source://actionpack//lib/action_controller/test_case.rb#223 def enabled?; end # @return [Boolean] # - # source://actionpack//lib/action_controller/test_case.rb#192 + # source://actionpack//lib/action_controller/test_case.rb#198 def exists?; end - # source://actionpack//lib/action_controller/test_case.rb#213 + # source://actionpack//lib/action_controller/test_case.rb#219 def fetch(key, *args, &block); end - # source://actionpack//lib/action_controller/test_case.rb#196 + # source://actionpack//lib/action_controller/test_case.rb#227 + def id_was; end + + # source://actionpack//lib/action_controller/test_case.rb#202 def keys; end - # source://actionpack//lib/action_controller/test_case.rb#200 + # source://actionpack//lib/action_controller/test_case.rb#206 def values; end private - # source://actionpack//lib/action_controller/test_case.rb#222 + # source://actionpack//lib/action_controller/test_case.rb#232 def load!; end end -# source://actionpack//lib/action_controller/test_case.rb#183 +# source://actionpack//lib/action_controller/test_case.rb#188 ActionController::TestSession::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_controller/metal/testing.rb#4 +# source://actionpack//lib/action_controller/metal/testing.rb#6 module ActionController::Testing; end # Behavior specific to functional tests # -# source://actionpack//lib/action_controller/metal/testing.rb#6 +# source://actionpack//lib/action_controller/metal/testing.rb#8 module ActionController::Testing::Functional - # source://actionpack//lib/action_controller/metal/testing.rb#7 + # source://actionpack//lib/action_controller/metal/testing.rb#9 def clear_instance_variables_between_requests; end - # source://actionpack//lib/action_controller/metal/testing.rb#16 + # source://actionpack//lib/action_controller/metal/testing.rb#18 def recycle!; end end -# Raised when a Parameters instance is not marked as permitted and -# an operation to transform it to hash is called. +# Raised when a Parameters instance is not marked as permitted and an operation +# to transform it to hash is called. # -# params = ActionController::Parameters.new(a: "123", b: "456") -# params.to_h -# # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash +# params = ActionController::Parameters.new(a: "123", b: "456") +# params.to_h +# # => ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash # -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#61 +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#64 class ActionController::UnfilteredParameters < ::ArgumentError # @return [UnfilteredParameters] a new instance of UnfilteredParameters # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#62 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#65 def initialize; end end -# source://actionpack//lib/action_controller/metal/exceptions.rb#73 +# source://actionpack//lib/action_controller/metal/exceptions.rb#75 class ActionController::UnknownFormat < ::ActionController::ActionControllerError; end -# source://actionpack//lib/action_controller/metal/exceptions.rb#70 +# source://actionpack//lib/action_controller/metal/exceptions.rb#72 class ActionController::UnknownHttpMethod < ::ActionController::ActionControllerError; end # Raised when a supplied parameter is not expected and -# ActionController::Parameters.action_on_unpermitted_parameters -# is set to :raise. +# ActionController::Parameters.action_on_unpermitted_parameters is set to +# `:raise`. # -# params = ActionController::Parameters.new(a: "123", b: "456") -# params.permit(:c) -# # => ActionController::UnpermittedParameters: found unpermitted parameters: :a, :b +# params = ActionController::Parameters.new(a: "123", b: "456") +# params.permit(:c) +# # => ActionController::UnpermittedParameters: found unpermitted parameters: :a, :b # -# source://actionpack//lib/action_controller/metal/strong_parameters.rb#46 +# source://actionpack//lib/action_controller/metal/strong_parameters.rb#49 class ActionController::UnpermittedParameters < ::IndexError # @return [UnpermittedParameters] a new instance of UnpermittedParameters # - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#49 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#52 def initialize(params); end - # source://actionpack//lib/action_controller/metal/strong_parameters.rb#47 + # source://actionpack//lib/action_controller/metal/strong_parameters.rb#50 def params; end end -# Includes +url_for+ into the host class. The class has to provide a +RouteSet+ by implementing -# the _routes method. Otherwise, an exception will be raised. +# # Action Controller UrlFor # -# In addition to AbstractController::UrlFor, this module accesses the HTTP layer to define -# URL options like the +host+. In order to do so, this module requires the host class -# to implement +env+ which needs to be Rack-compatible, and +request+ which -# returns an ActionDispatch::Request instance. +# Includes `url_for` into the host class. The class has to provide a `RouteSet` +# by implementing the `_routes` method. Otherwise, an exception will be raised. # -# class RootUrl -# include ActionController::UrlFor -# include Rails.application.routes.url_helpers +# In addition to AbstractController::UrlFor, this module accesses the HTTP layer +# to define URL options like the `host`. In order to do so, this module requires +# the host class to implement `env` which needs to be Rack-compatible, and +# `request` which returns an ActionDispatch::Request instance. # -# delegate :env, :request, to: :controller +# class RootUrl +# include ActionController::UrlFor +# include Rails.application.routes.url_helpers # -# def initialize(controller) -# @controller = controller -# @url = root_path # named route from the application. +# delegate :env, :request, to: :controller +# +# def initialize(controller) +# @controller = controller +# @url = root_path # named route from the application. +# end # end -# end # -# source://actionpack//lib/action_controller/metal/url_for.rb#23 +# source://actionpack//lib/action_controller/metal/url_for.rb#27 module ActionController::UrlFor extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -8116,7 +8849,10 @@ module ActionController::UrlFor mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::AbstractController::UrlFor::ClassMethods - # source://actionpack//lib/action_controller/metal/url_for.rb#28 + # source://actionpack//lib/action_controller/metal/url_for.rb#32 + def initialize(*_arg0, **_arg1, &_arg2); end + + # source://actionpack//lib/action_controller/metal/url_for.rb#37 def url_options; end module GeneratedClassMethods @@ -8132,331 +8868,440 @@ module ActionController::UrlFor end end -# source://actionpack//lib/action_controller/metal/exceptions.rb#25 +# source://actionpack//lib/action_controller/metal/exceptions.rb#27 class ActionController::UrlGenerationError < ::ActionController::ActionControllerError include ::DidYouMean::Correctable # @return [UrlGenerationError] a new instance of UrlGenerationError # - # source://actionpack//lib/action_controller/metal/exceptions.rb#28 + # source://actionpack//lib/action_controller/metal/exceptions.rb#30 def initialize(message, routes = T.unsafe(nil), route_name = T.unsafe(nil), method_name = T.unsafe(nil)); end - # source://actionpack//lib/action_controller/metal/exceptions.rb#39 + # source://actionpack//lib/action_controller/metal/exceptions.rb#41 def corrections; end # Returns the value of attribute method_name. # - # source://actionpack//lib/action_controller/metal/exceptions.rb#26 + # source://actionpack//lib/action_controller/metal/exceptions.rb#28 def method_name; end # Returns the value of attribute route_name. # - # source://actionpack//lib/action_controller/metal/exceptions.rb#26 + # source://actionpack//lib/action_controller/metal/exceptions.rb#28 def route_name; end # Returns the value of attribute routes. # - # source://actionpack//lib/action_controller/metal/exceptions.rb#26 + # source://actionpack//lib/action_controller/metal/exceptions.rb#28 def routes; end end -# source://actionpack//lib/action_dispatch.rb#37 +# # Action Dispatch +# +# Action Dispatch is a module of Action Pack. +# +# Action Dispatch parses information about the web request, handles routing as +# defined by the user, and does advanced processing related to HTTP such as +# MIME-type negotiation, decoding parameters in POST, PATCH, or PUT bodies, +# handling HTTP caching logic, cookies and sessions. +# +# source://actionpack//lib/action_dispatch/deprecator.rb#5 module ActionDispatch extend ::ActiveSupport::Autoload - # source://actionpack//lib/action_dispatch.rb#99 + # source://actionpack//lib/action_dispatch.rb#135 + def eager_load!; end + + # source://actionpack//lib/action_dispatch.rb#121 def test_app; end - # source://actionpack//lib/action_dispatch.rb#99 + # source://actionpack//lib/action_dispatch.rb#121 def test_app=(val); end class << self - # source://actionpack//lib/action_dispatch.rb#99 + # source://actionpack//lib/action_dispatch/deprecator.rb#6 + def deprecator; end + + # source://actionpack//lib/action_dispatch.rb#121 def test_app; end - # source://actionpack//lib/action_dispatch.rb#99 + # source://actionpack//lib/action_dispatch.rb#121 def test_app=(val); end end end -# source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#8 +# source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#9 class ActionDispatch::ActionableExceptions # @return [ActionableExceptions] a new instance of ActionableExceptions # - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#11 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#12 def initialize(app); end - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#15 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#16 def call(env); end - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#9 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#10 def endpoint; end - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#9 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#10 def endpoint=(val); end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#25 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#26 def actionable_request?(request); end - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#29 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#30 def redirect_to(location); end class << self - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#9 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#10 def endpoint; end - # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#9 + # source://actionpack//lib/action_dispatch/middleware/actionable_exceptions.rb#10 def endpoint=(val); end end end -# This is a class that abstracts away an asserted response. It purposely -# does not inherit from Response because it doesn't need it. That means it -# does not have headers or a body. +# This is a class that abstracts away an asserted response. It purposely does +# not inherit from Response because it doesn't need it. That means it does not +# have headers or a body. # -# source://actionpack//lib/action_dispatch/testing/assertion_response.rb#7 +# source://actionpack//lib/action_dispatch/testing/assertion_response.rb#9 class ActionDispatch::AssertionResponse - # Accepts a specific response status code as an Integer (404) or String - # ('404') or a response status range as a Symbol pseudo-code (:success, - # indicating any 200-299 status code). + # Accepts a specific response status code as an Integer (404) or String ('404') + # or a response status range as a Symbol pseudo-code (:success, indicating any + # 200-299 status code). # # @raise [ArgumentError] # @return [AssertionResponse] a new instance of AssertionResponse # - # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#20 + # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#22 def initialize(code_or_name); end # Returns the value of attribute code. # - # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#8 + # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#10 def code; end - # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#33 + # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#35 def code_and_name; end # Returns the value of attribute name. # - # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#8 + # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#10 def name; end private - # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#38 + # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#40 def code_from_name(name); end - # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#42 + # source://actionpack//lib/action_dispatch/testing/assertion_response.rb#44 def name_from_code(code); end end -# source://actionpack//lib/action_dispatch/testing/assertion_response.rb#10 +# source://actionpack//lib/action_dispatch/testing/assertion_response.rb#12 ActionDispatch::AssertionResponse::GENERIC_RESPONSE_CODES = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/testing/assertions/response.rb#4 +# source://actionpack//lib/action_dispatch/testing/assertions/response.rb#6 module ActionDispatch::Assertions include ::ActionDispatch::Assertions::ResponseAssertions - include ::ActionDispatch::Assertions::RoutingAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions + extend ::ActiveSupport::Concern + include ::ActionDispatch::Assertions::RoutingAssertions - # source://actionpack//lib/action_dispatch/testing/assertions.rb#13 + mixes_in_class_methods ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods + + # source://actionpack//lib/action_dispatch/testing/assertions.rb#17 def html_document; end end -# A small suite of assertions that test responses from \Rails applications. +# A small suite of assertions that test responses from Rails applications. # -# source://actionpack//lib/action_dispatch/testing/assertions/response.rb#6 +# source://actionpack//lib/action_dispatch/testing/assertions/response.rb#8 module ActionDispatch::Assertions::ResponseAssertions # Asserts that the response is a redirect to a URL matching the given options. # - # # Asserts that the redirection was to the "index" action on the WeblogController - # assert_redirected_to controller: "weblog", action: "index" + # # Asserts that the redirection was to the "index" action on the WeblogController + # assert_redirected_to controller: "weblog", action: "index" # - # # Asserts that the redirection was to the named route login_url - # assert_redirected_to login_url + # # Asserts that the redirection was to the named route login_url + # assert_redirected_to login_url # - # # Asserts that the redirection was to the URL for @customer - # assert_redirected_to @customer + # # Asserts that the redirection was to the URL for @customer + # assert_redirected_to @customer # - # # Asserts that the redirection matches the regular expression - # assert_redirected_to %r(\Ahttp://example.org) + # # Asserts that the redirection matches the regular expression + # assert_redirected_to %r(\Ahttp://example.org) # - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#53 - def assert_redirected_to(options = T.unsafe(nil), message = T.unsafe(nil)); end + # # Asserts that the redirection has the HTTP status code 301 (Moved + # # Permanently). + # assert_redirected_to "/some/path", status: :moved_permanently + # + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#60 + def assert_redirected_to(url_options = T.unsafe(nil), options = T.unsafe(nil), message = T.unsafe(nil)); end # Asserts that the response is one of the following types: # - # * :success - Status code was in the 200-299 range - # * :redirect - Status code was in the 300-399 range - # * :missing - Status code was 404 - # * :error - Status code was in the 500-599 range + # * `:success` - Status code was in the 200-299 range + # * `:redirect` - Status code was in the 300-399 range + # * `:missing` - Status code was 404 + # * `:error` - Status code was in the 500-599 range + # # - # You can also pass an explicit status number like assert_response(501) - # or its symbolic equivalent assert_response(:not_implemented). - # See +Rack::Utils::SYMBOL_TO_STATUS_CODE+ for a full list. + # You can also pass an explicit status number like `assert_response(501)` or its + # symbolic equivalent `assert_response(:not_implemented)`. See + # `Rack::Utils::SYMBOL_TO_STATUS_CODE` for a full list. # - # # Asserts that the response was a redirection - # assert_response :redirect + # # Asserts that the response was a redirection + # assert_response :redirect # - # # Asserts that the response code was status code 401 (unauthorized) - # assert_response 401 + # # Asserts that the response code was status code 401 (unauthorized) + # assert_response 401 # - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#30 + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#33 def assert_response(type, message = T.unsafe(nil)); end private - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#95 + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#105 def code_with_name(code_or_name); end - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#79 + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#89 def generate_response_message(expected, actual = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#89 + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#99 def location_if_redirected; end - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#70 + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#80 def normalize_argument_to_redirection(fragment); end # Proxy to to_param if the object will respond to it. # - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#66 + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#76 def parameterize(value); end - # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#84 + # source://actionpack//lib/action_dispatch/testing/assertions/response.rb#94 def response_body_if_short; end end -# source://actionpack//lib/action_dispatch/testing/assertions/response.rb#7 +# source://actionpack//lib/action_dispatch/testing/assertions/response.rb#9 ActionDispatch::Assertions::ResponseAssertions::RESPONSE_PREDICATES = T.let(T.unsafe(nil), Hash) -# Suite of assertions to test routes generated by \Rails and the handling of requests made to them. +# Suite of assertions to test routes generated by Rails and the handling of +# requests made to them. # -# source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#11 +# source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#14 module ActionDispatch::Assertions::RoutingAssertions - # Asserts that the provided options can be used to generate the provided path. This is the inverse of +assert_recognizes+. - # The +extras+ parameter is used to tell the request the names and values of additional request parameters that would be in - # a query string. The +message+ parameter allows you to specify a custom error message for assertion failures. + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods + + # Asserts that the provided options can be used to generate the provided path. + # This is the inverse of `assert_recognizes`. The `extras` parameter is used to + # tell the request the names and values of additional request parameters that + # would be in a query string. The `message` parameter allows you to specify a + # custom error message for assertion failures. # - # The +defaults+ parameter is unused. + # The `defaults` parameter is unused. # - # # Asserts that the default action is generated for a route with no action - # assert_generates "/items", controller: "items", action: "index" + # # Asserts that the default action is generated for a route with no action + # assert_generates "/items", controller: "items", action: "index" # - # # Tests that the list action is properly routed - # assert_generates "/items/list", controller: "items", action: "list" + # # Tests that the list action is properly routed + # assert_generates "/items/list", controller: "items", action: "list" # - # # Tests the generation of a route with a parameter - # assert_generates "/items/list/1", { controller: "items", action: "list", id: "1" } + # # Tests the generation of a route with a parameter + # assert_generates "/items/list/1", { controller: "items", action: "list", id: "1" } # - # # Asserts that the generated route gives us our custom route - # assert_generates "changesets/12", { controller: 'scm', action: 'show_diff', revision: "12" } + # # Asserts that the generated route gives us our custom route + # assert_generates "changesets/12", { controller: 'scm', action: 'show_diff', revision: "12" } # - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#85 + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#204 def assert_generates(expected_path, options, defaults = T.unsafe(nil), extras = T.unsafe(nil), message = T.unsafe(nil)); end - # Asserts that the routing of the given +path+ was handled correctly and that the parsed options (given in the +expected_options+ hash) - # match +path+. Basically, it asserts that \Rails recognizes the route given by +expected_options+. + # Asserts that the routing of the given `path` was handled correctly and that + # the parsed options (given in the `expected_options` hash) match `path`. + # Basically, it asserts that Rails recognizes the route given by + # `expected_options`. # - # Pass a hash in the second argument (+path+) to specify the request method. This is useful for routes - # requiring a specific HTTP method. The hash should contain a +:path+ with the incoming request path - # and a +:method+ containing the required HTTP verb. + # Pass a hash in the second argument (`path`) to specify the request method. + # This is useful for routes requiring a specific HTTP method. The hash should + # contain a `:path` with the incoming request path and a `:method` containing + # the required HTTP verb. # - # # Asserts that POSTing to /items will call the create action on ItemsController - # assert_recognizes({controller: 'items', action: 'create'}, {path: 'items', method: :post}) + # # Asserts that POSTing to /items will call the create action on ItemsController + # assert_recognizes({controller: 'items', action: 'create'}, {path: 'items', method: :post}) # - # You can also pass in +extras+ with a hash containing URL parameters that would normally be in the query string. This can be used - # to assert that values in the query string will end up in the params hash correctly. To test query strings you must use the extras - # argument because appending the query string on the path directly will not work. For example: + # You can also pass in `extras` with a hash containing URL parameters that would + # normally be in the query string. This can be used to assert that values in the + # query string will end up in the params hash correctly. To test query strings + # you must use the extras argument because appending the query string on the + # path directly will not work. For example: # - # # Asserts that a path of '/items/list/1?view=print' returns the correct options - # assert_recognizes({controller: 'items', action: 'list', id: '1', view: 'print'}, 'items/list/1', { view: "print" }) + # # Asserts that a path of '/items/list/1?view=print' returns the correct options + # assert_recognizes({controller: 'items', action: 'list', id: '1', view: 'print'}, 'items/list/1', { view: "print" }) # - # The +message+ parameter allows you to pass in an error message that is displayed upon failure. + # The `message` parameter allows you to pass in an error message that is + # displayed upon failure. # - # # Check the default route (i.e., the index action) - # assert_recognizes({controller: 'items', action: 'index'}, 'items') + # # Check the default route (i.e., the index action) + # assert_recognizes({controller: 'items', action: 'index'}, 'items') # - # # Test a specific action - # assert_recognizes({controller: 'items', action: 'list'}, 'items/list') + # # Test a specific action + # assert_recognizes({controller: 'items', action: 'list'}, 'items/list') # - # # Test an action with a parameter - # assert_recognizes({controller: 'items', action: 'destroy', id: '1'}, 'items/destroy/1') + # # Test an action with a parameter + # assert_recognizes({controller: 'items', action: 'destroy', id: '1'}, 'items/destroy/1') # - # # Test a custom route - # assert_recognizes({controller: 'items', action: 'show', id: '1'}, 'view/item1') + # # Test a custom route + # assert_recognizes({controller: 'items', action: 'show', id: '1'}, 'view/item1') # - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#47 + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#164 def assert_recognizes(expected_options, path, extras = T.unsafe(nil), msg = T.unsafe(nil)); end - # Asserts that path and options match both ways; in other words, it verifies that path generates - # options and then that options generates path. This essentially combines +assert_recognizes+ - # and +assert_generates+ into one step. + # Asserts that path and options match both ways; in other words, it verifies + # that `path` generates `options` and then that `options` generates `path`. This + # essentially combines `assert_recognizes` and `assert_generates` into one step. # - # The +extras+ hash allows you to specify options that would normally be provided as a query string to the action. The - # +message+ parameter allows you to specify a custom error message to display upon failure. + # The `extras` hash allows you to specify options that would normally be + # provided as a query string to the action. The `message` parameter allows you + # to specify a custom error message to display upon failure. # - # # Asserts a basic route: a controller with the default action (index) - # assert_routing '/home', controller: 'home', action: 'index' + # # Asserts a basic route: a controller with the default action (index) + # assert_routing '/home', controller: 'home', action: 'index' # - # # Test a route generated with a specific controller, action, and parameter (id) - # assert_routing '/entries/show/23', controller: 'entries', action: 'show', id: 23 + # # Test a route generated with a specific controller, action, and parameter (id) + # assert_routing '/entries/show/23', controller: 'entries', action: 'show', id: 23 # - # # Asserts a basic route (controller + default action), with an error message if it fails - # assert_routing '/store', { controller: 'store', action: 'index' }, {}, {}, 'Route for store index not generated properly' + # # Asserts a basic route (controller + default action), with an error message if it fails + # assert_routing '/store', { controller: 'store', action: 'index' }, {}, {}, 'Route for store index not generated properly' # - # # Tests a route, providing a defaults hash - # assert_routing 'controller/action/9', {id: "9", item: "square"}, {controller: "controller", action: "action"}, {}, {item: "square"} + # # Tests a route, providing a defaults hash + # assert_routing 'controller/action/9', {id: "9", item: "square"}, {controller: "controller", action: "action"}, {}, {item: "square"} # - # # Tests a route with an HTTP method - # assert_routing({ method: 'put', path: '/product/321' }, { controller: "product", action: "update", id: "321" }) + # # Tests a route with an HTTP method + # assert_routing({ method: 'put', path: '/product/321' }, { controller: "product", action: "update", id: "321" }) # - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#128 + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#248 def assert_routing(path, options, defaults = T.unsafe(nil), extras = T.unsafe(nil), message = T.unsafe(nil)); end # ROUTES TODO: These assertions should really work in an integration context # - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#183 - def method_missing(selector, *args, **_arg2, &block); end + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#261 + def method_missing(selector, *_arg1, **_arg2, &_arg3); end - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#12 + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#103 def setup; end - # A helper to make it easier to test different route configurations. - # This method temporarily replaces @routes with a new RouteSet instance. + # A helper to make it easier to test different route configurations. This method + # temporarily replaces @routes with a new RouteSet instance. # - # The new instance is yielded to the passed block. Typically the block - # will create some routes using set.draw { match ... }: + # The new instance is yielded to the passed block. Typically the block will + # create some routes using `set.draw { match ... }`: # - # with_routing do |set| - # set.draw do - # resources :users + # with_routing do |set| + # set.draw do + # resources :users + # end + # assert_equal "/users", users_path # end - # assert_equal "/users", users_path - # end # - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#153 - def with_routing; end + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#121 + def with_routing(&block); end private - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#228 + # @yield [@routes] + # + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#270 + def create_routes; end + + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#336 def fail_on(exception_class, message); end # Recognizes the route for a given path. # - # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#194 + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#302 def recognized_request_for(path, extras = T.unsafe(nil), msg); end + + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#294 + def reset_routes(old_routes, old_controller); end +end + +# source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#76 +module ActionDispatch::Assertions::RoutingAssertions::ClassMethods + # A helper to make it easier to test different route configurations. This method + # temporarily replaces @routes with a new RouteSet instance before each test. + # + # The new instance is yielded to the passed block. Typically the block will + # create some routes using `set.draw { match ... }`: + # + # with_routing do |set| + # set.draw do + # resources :users + # end + # end + # + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#89 + def with_routing(&block); end +end + +# source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#17 +module ActionDispatch::Assertions::RoutingAssertions::WithIntegrationRouting + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionDispatch::Assertions::RoutingAssertions::WithIntegrationRouting::ClassMethods + + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#37 + def with_routing(&block); end + + private + + # @yield [routes] + # + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#46 + def create_routes; end + + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#66 + def reset_routes(old_routes, old_integration_session); end +end + +# source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#20 +module ActionDispatch::Assertions::RoutingAssertions::WithIntegrationRouting::ClassMethods + # source://actionpack//lib/action_dispatch/testing/assertions/routing.rb#21 + def with_routing(&block); end +end + +# # Action Dispatch AssumeSSL +# +# When proxying through a load balancer that terminates SSL, the forwarded +# request will appear as though it's HTTP instead of HTTPS to the application. +# This makes redirects and cookie security target HTTP instead of HTTPS. This +# middleware makes the server assume that the proxy already terminated SSL, and +# that the request really is HTTPS. +# +# source://actionpack//lib/action_dispatch/middleware/assume_ssl.rb#13 +class ActionDispatch::AssumeSSL + # @return [AssumeSSL] a new instance of AssumeSSL + # + # source://actionpack//lib/action_dispatch/middleware/assume_ssl.rb#14 + def initialize(app); end + + # source://actionpack//lib/action_dispatch/middleware/assume_ssl.rb#18 + def call(env); end end +# # Action Dispatch Callbacks +# # Provides callbacks to be executed before and after dispatching the request. # -# source://actionpack//lib/action_dispatch/middleware/callbacks.rb#5 +# source://actionpack//lib/action_dispatch/middleware/callbacks.rb#9 class ActionDispatch::Callbacks include ::ActiveSupport::Callbacks extend ::ActiveSupport::Callbacks::ClassMethods @@ -8464,897 +9309,924 @@ class ActionDispatch::Callbacks # @return [Callbacks] a new instance of Callbacks # - # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#20 + # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#24 def initialize(app); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _call_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_call_callbacks(&block); end - # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#24 + # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#28 def call(env); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _call_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _call_callbacks=(value); end - # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#15 + # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#19 def after(*args, &block); end - # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#11 + # source://actionpack//lib/action_dispatch/middleware/callbacks.rb#15 def before(*args, &block); end end end -# Configures the HTTP -# {Content-Security-Policy}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy] -# response header to help protect against XSS and injection attacks. +# source://actionpack//lib/action_dispatch/constants.rb#8 +module ActionDispatch::Constants; end + +# source://actionpack//lib/action_dispatch/constants.rb#12 +ActionDispatch::Constants::CONTENT_ENCODING = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#13 +ActionDispatch::Constants::CONTENT_SECURITY_POLICY = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#14 +ActionDispatch::Constants::CONTENT_SECURITY_POLICY_REPORT_ONLY = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#16 +ActionDispatch::Constants::FEATURE_POLICY = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#15 +ActionDispatch::Constants::LOCATION = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#19 +ActionDispatch::Constants::SERVER_TIMING = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#20 +ActionDispatch::Constants::STRICT_TRANSPORT_SECURITY = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#11 +ActionDispatch::Constants::VARY = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#18 +ActionDispatch::Constants::X_CASCADE = T.let(T.unsafe(nil), String) + +# source://actionpack//lib/action_dispatch/constants.rb#17 +ActionDispatch::Constants::X_REQUEST_ID = T.let(T.unsafe(nil), String) + +# # Action Dispatch Content Security Policy +# +# Configures the HTTP [Content-Security-Policy] +# (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy) +# response header to help protect against XSS and +# injection attacks. # # Example global policy: # -# Rails.application.config.content_security_policy do |policy| -# policy.default_src :self, :https -# policy.font_src :self, :https, :data -# policy.img_src :self, :https, :data -# policy.object_src :none -# policy.script_src :self, :https -# policy.style_src :self, :https +# Rails.application.config.content_security_policy do |policy| +# policy.default_src :self, :https +# policy.font_src :self, :https, :data +# policy.img_src :self, :https, :data +# policy.object_src :none +# policy.script_src :self, :https +# policy.style_src :self, :https # -# # Specify URI for violation reports -# policy.report_uri "/csp-violation-report-endpoint" -# end +# # Specify URI for violation reports +# policy.report_uri "/csp-violation-report-endpoint" +# end # -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#24 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#29 class ActionDispatch::ContentSecurityPolicy # @return [ContentSecurityPolicy] a new instance of ContentSecurityPolicy # @yield [_self] # @yieldparam _self [ActionDispatch::ContentSecurityPolicy] the object that the method was called on # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#173 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#177 def initialize; end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def base_uri(*sources); end - # Specify whether to prevent the user agent from loading any assets over - # HTTP when the page uses HTTPS: + # Specify whether to prevent the user agent from loading any assets over HTTP + # when the page uses HTTPS: # - # policy.block_all_mixed_content + # policy.block_all_mixed_content # - # Pass +false+ to allow it again: + # Pass `false` to allow it again: # - # policy.block_all_mixed_content false + # policy.block_all_mixed_content false # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#201 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#205 def block_all_mixed_content(enabled = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#290 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#297 def build(context = T.unsafe(nil), nonce = T.unsafe(nil), nonce_directives = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def child_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def connect_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def default_src(*sources); end # Returns the value of attribute directives. # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#171 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#175 def directives; end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def font_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def form_action(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def frame_ancestors(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def frame_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def img_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def manifest_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def media_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def object_src(*sources); end # Restricts the set of plugins that can be embedded: # - # policy.plugin_types "application/x-shockwave-flash" + # policy.plugin_types "application/x-shockwave-flash" # # Leave empty to allow all plugins: # - # policy.plugin_types + # policy.plugin_types # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#217 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#221 def plugin_types(*types); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def prefetch_src(*sources); end - # Enable the {report-uri}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/report-uri] - # directive. Violation reports will be sent to the specified URI: + # Enable the [report-uri] + # (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/report-uri) + # directive. Violation reports will be sent to the + # specified URI: # - # policy.report_uri "/csp-violation-report-endpoint" + # policy.report_uri "/csp-violation-report-endpoint" # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#230 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#236 def report_uri(uri); end - # Specify asset types for which {Subresource Integrity}[https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity] - # is required: + # Specify asset types for which [Subresource Integrity] + # (https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity) is required: # - # policy.require_sri_for :script, :style + # policy.require_sri_for :script, :style # # Leave empty to not require Subresource Integrity: # - # policy.require_sri_for + # policy.require_sri_for # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#243 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#249 def require_sri_for(*types); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def require_trusted_types_for(*sources); end - # Specify whether a {sandbox}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/sandbox] + # Specify whether a [sandbox] + # (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/sandbox) # should be enabled for the requested resource: # - # policy.sandbox + # policy.sandbox # # Values can be passed as arguments: # - # policy.sandbox "allow-scripts", "allow-modals" + # policy.sandbox "allow-scripts", "allow-modals" # - # Pass +false+ to disable the sandbox: + # Pass `false` to disable the sandbox: # - # policy.sandbox false + # policy.sandbox false # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#264 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#271 def sandbox(*values); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def script_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def script_src_attr(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def script_src_elem(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def style_src(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def style_src_attr(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def style_src_elem(*sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def trusted_types(*sources); end # Specify whether user agents should treat any assets over HTTP as HTTPS: # - # policy.upgrade_insecure_requests + # policy.upgrade_insecure_requests # - # Pass +false+ to disable it: + # Pass `false` to disable it: # - # policy.upgrade_insecure_requests false + # policy.upgrade_insecure_requests false # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#282 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#289 def upgrade_insecure_requests(enabled = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#183 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#187 def worker_src(*sources); end private - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#309 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#316 def apply_mapping(source); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#296 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#303 def apply_mappings(sources); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#331 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#338 def build_directive(sources, context); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#315 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#322 def build_directives(context, nonce, nonce_directives); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#178 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#182 def initialize_copy(other); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#353 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#360 def nonce_directive?(directive, nonce_directives); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#335 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#342 def resolve_source(source, context); end end -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#167 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#171 ActionDispatch::ContentSecurityPolicy::DEFAULT_NONCE_DIRECTIVES = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#142 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#146 ActionDispatch::ContentSecurityPolicy::DIRECTIVES = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#123 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#126 ActionDispatch::ContentSecurityPolicy::MAPPINGS = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#25 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#30 class ActionDispatch::ContentSecurityPolicy::Middleware # @return [Middleware] a new instance of Middleware # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#30 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#31 def initialize(app); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#34 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#35 def call(env); end private - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#55 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#57 def header_name(request); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#63 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#65 def policy_present?(headers); end end -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#26 -ActionDispatch::ContentSecurityPolicy::Middleware::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#27 -ActionDispatch::ContentSecurityPolicy::Middleware::POLICY = T.let(T.unsafe(nil), String) - -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#28 -ActionDispatch::ContentSecurityPolicy::Middleware::POLICY_REPORT_ONLY = T.let(T.unsafe(nil), String) - -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#68 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#71 module ActionDispatch::ContentSecurityPolicy::Request - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#75 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#78 def content_security_policy; end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#79 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#82 def content_security_policy=(policy); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#107 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#110 def content_security_policy_nonce; end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#99 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#102 def content_security_policy_nonce_directives; end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#103 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#106 def content_security_policy_nonce_directives=(generator); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#91 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#94 def content_security_policy_nonce_generator; end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#95 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#98 def content_security_policy_nonce_generator=(generator); end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#83 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#86 def content_security_policy_report_only; end - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#87 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#90 def content_security_policy_report_only=(value); end private - # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#118 + # source://actionpack//lib/action_dispatch/http/content_security_policy.rb#121 def generate_content_security_policy_nonce; end end -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#72 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#75 ActionDispatch::ContentSecurityPolicy::Request::NONCE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#73 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#76 ActionDispatch::ContentSecurityPolicy::Request::NONCE_DIRECTIVES = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#71 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#74 ActionDispatch::ContentSecurityPolicy::Request::NONCE_GENERATOR = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#69 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#72 ActionDispatch::ContentSecurityPolicy::Request::POLICY = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#70 +# source://actionpack//lib/action_dispatch/http/content_security_policy.rb#73 ActionDispatch::ContentSecurityPolicy::Request::POLICY_REPORT_ONLY = T.let(T.unsafe(nil), String) -# Read and write data to cookies through ActionController::Base#cookies. +# Read and write data to cookies through ActionController::Cookies#cookies. # -# When reading cookie data, the data is read from the HTTP request header, Cookie. -# When writing cookie data, the data is sent out in the HTTP response header, +Set-Cookie+. +# When reading cookie data, the data is read from the HTTP request header, +# Cookie. When writing cookie data, the data is sent out in the HTTP response +# header, `Set-Cookie`. # # Examples of writing: # -# # Sets a simple session cookie. -# # This cookie will be deleted when the user's browser is closed. -# cookies[:user_name] = "david" +# # Sets a simple session cookie. +# # This cookie will be deleted when the user's browser is closed. +# cookies[:user_name] = "david" # -# # Cookie values are String-based. Other data types need to be serialized. -# cookies[:lat_lon] = JSON.generate([47.68, -122.37]) +# # Cookie values are String-based. Other data types need to be serialized. +# cookies[:lat_lon] = JSON.generate([47.68, -122.37]) # -# # Sets a cookie that expires in 1 hour. -# cookies[:login] = { value: "XJ-122", expires: 1.hour } +# # Sets a cookie that expires in 1 hour. +# cookies[:login] = { value: "XJ-122", expires: 1.hour } # -# # Sets a cookie that expires at a specific time. -# cookies[:login] = { value: "XJ-122", expires: Time.utc(2020, 10, 15, 5) } +# # Sets a cookie that expires at a specific time. +# cookies[:login] = { value: "XJ-122", expires: Time.utc(2020, 10, 15, 5) } # -# # Sets a signed cookie, which prevents users from tampering with its value. -# # It can be read using the signed method `cookies.signed[:name]` -# cookies.signed[:user_id] = current_user.id +# # Sets a signed cookie, which prevents users from tampering with its value. +# # It can be read using the signed method `cookies.signed[:name]` +# cookies.signed[:user_id] = current_user.id # -# # Sets an encrypted cookie value before sending it to the client which -# # prevent users from reading and tampering with its value. -# # It can be read using the encrypted method `cookies.encrypted[:name]` -# cookies.encrypted[:discount] = 45 +# # Sets an encrypted cookie value before sending it to the client which +# # prevent users from reading and tampering with its value. +# # It can be read using the encrypted method `cookies.encrypted[:name]` +# cookies.encrypted[:discount] = 45 # -# # Sets a "permanent" cookie (which expires in 20 years from now). -# cookies.permanent[:login] = "XJ-122" +# # Sets a "permanent" cookie (which expires in 20 years from now). +# cookies.permanent[:login] = "XJ-122" # -# # You can also chain these methods: -# cookies.signed.permanent[:login] = "XJ-122" +# # You can also chain these methods: +# cookies.signed.permanent[:login] = "XJ-122" # # Examples of reading: # -# cookies[:user_name] # => "david" -# cookies.size # => 2 -# JSON.parse(cookies[:lat_lon]) # => [47.68, -122.37] -# cookies.signed[:login] # => "XJ-122" -# cookies.encrypted[:discount] # => 45 +# cookies[:user_name] # => "david" +# cookies.size # => 2 +# JSON.parse(cookies[:lat_lon]) # => [47.68, -122.37] +# cookies.signed[:login] # => "XJ-122" +# cookies.encrypted[:discount] # => 45 # # Example for deleting: # -# cookies.delete :user_name +# cookies.delete :user_name # -# Please note that if you specify a +:domain+ when setting a cookie, you must also specify the domain when deleting the cookie: +# Please note that if you specify a `:domain` when setting a cookie, you must +# also specify the domain when deleting the cookie: # -# cookies[:name] = { -# value: 'a yummy cookie', -# expires: 1.year, -# domain: 'domain.com' -# } +# cookies[:name] = { +# value: 'a yummy cookie', +# expires: 1.year, +# domain: 'domain.com' +# } # -# cookies.delete(:name, domain: 'domain.com') +# cookies.delete(:name, domain: 'domain.com') # # The option symbols for setting cookies are: # -# * :value - The cookie's value. -# * :path - The path for which this cookie applies. Defaults to the root -# of the application. -# * :domain - The domain for which this cookie applies so you can -# restrict to the domain level. If you use a schema like www.example.com -# and want to share session with user.example.com set :domain -# to :all. To support multiple domains, provide an array, and -# the first domain matching request.host will be used. Make -# sure to specify the :domain option with :all or -# Array again when deleting cookies. -# -# domain: nil # Does not set cookie domain. (default) -# domain: :all # Allow the cookie for the top most level -# # domain and subdomains. -# domain: %w(.example.com .example.org) # Allow the cookie -# # for concrete domain names. -# -# * :tld_length - When using :domain => :all, this option can be used to explicitly -# set the TLD length when using a short (<= 3 character) domain that is being interpreted as part of a TLD. -# For example, to share cookies between user1.lvh.me and user2.lvh.me, set :tld_length to 2. -# * :expires - The time at which this cookie expires, as a \Time or ActiveSupport::Duration object. -# * :secure - Whether this cookie is only transmitted to HTTPS servers. -# Default is +false+. -# * :httponly - Whether this cookie is accessible via scripting or -# only HTTP. Defaults to +false+. -# * :same_site - The value of the +SameSite+ cookie attribute, which -# determines how this cookie should be restricted in cross-site contexts. -# Possible values are +:none+, +:lax+, and +:strict+. Defaults to +:lax+. -# -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#182 +# * `:value` - The cookie's value. +# * `:path` - The path for which this cookie applies. Defaults to the root of +# the application. +# * `:domain` - The domain for which this cookie applies so you can restrict +# to the domain level. If you use a schema like www.example.com and want to +# share session with user.example.com set `:domain` to `:all`. To support +# multiple domains, provide an array, and the first domain matching +# `request.host` will be used. Make sure to specify the `:domain` option +# with `:all` or `Array` again when deleting cookies. For more flexibility +# you can set the domain on a per-request basis by specifying `:domain` with +# a proc. +# +# domain: nil # Does not set cookie domain. (default) +# domain: :all # Allow the cookie for the top most level +# # domain and subdomains. +# domain: %w(.example.com .example.org) # Allow the cookie +# # for concrete domain names. +# domain: proc { Tenant.current.cookie_domain } # Set cookie domain dynamically +# domain: proc { |req| ".sub.#{req.host}" } # Set cookie domain dynamically based on request +# +# * `:tld_length` - When using `:domain => :all`, this option can be used to +# explicitly set the TLD length when using a short (<= 3 character) domain +# that is being interpreted as part of a TLD. For example, to share cookies +# between user1.lvh.me and user2.lvh.me, set `:tld_length` to 2. +# * `:expires` - The time at which this cookie expires, as a Time or +# ActiveSupport::Duration object. +# * `:secure` - Whether this cookie is only transmitted to HTTPS servers. +# Default is `false`. +# * `:httponly` - Whether this cookie is accessible via scripting or only +# HTTP. Defaults to `false`. +# * `:same_site` - The value of the `SameSite` cookie attribute, which +# determines how this cookie should be restricted in cross-site contexts. +# Possible values are `nil`, `:none`, `:lax`, and `:strict`. Defaults to +# `:lax`. +# +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#193 class ActionDispatch::Cookies # @return [Cookies] a new instance of Cookies # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#697 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#698 def initialize(app); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#701 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#702 def call(env); end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#188 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#199 ActionDispatch::Cookies::AUTHENTICATED_ENCRYPTED_COOKIE_SALT = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#485 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#504 class ActionDispatch::Cookies::AbstractCookieJar include ::ActionDispatch::Cookies::ChainedCookieJars # @return [AbstractCookieJar] a new instance of AbstractCookieJar # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#488 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#507 def initialize(parent_jar); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#492 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#511 def [](name); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#504 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#523 def []=(name, options); end protected - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#516 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#535 def request; end private - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#534 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#553 def commit(name, options); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#527 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#546 def cookie_metadata(name, options); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#519 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#538 def expiry_options(options); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#533 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#552 def parse(name, data, purpose: T.unsafe(nil)); end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#194 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#205 ActionDispatch::Cookies::COOKIES_DIGEST = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#195 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#206 ActionDispatch::Cookies::COOKIES_ROTATIONS = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#196 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#207 ActionDispatch::Cookies::COOKIES_SAME_SITE_PROTECTION = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#193 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#204 ActionDispatch::Cookies::COOKIES_SERIALIZER = T.let(T.unsafe(nil), String) -# Include in a cookie jar to allow chaining, e.g. +cookies.permanent.signed+. +# Include in a cookie jar to allow chaining, e.g. `cookies.permanent.signed`. # -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#206 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#217 module ActionDispatch::Cookies::ChainedCookieJars - # Returns a jar that'll automatically encrypt cookie values before sending them to the client and will decrypt them for read. - # If the cookie was tampered with by the user (or a 3rd party), +nil+ will be returned. + # Returns a jar that'll automatically encrypt cookie values before sending them + # to the client and will decrypt them for read. If the cookie was tampered with + # by the user (or a 3rd party), `nil` will be returned. # - # If +config.action_dispatch.encrypted_cookie_salt+ and +config.action_dispatch.encrypted_signed_cookie_salt+ - # are both set, legacy cookies encrypted with HMAC AES-256-CBC will be transparently upgraded. + # If `config.action_dispatch.encrypted_cookie_salt` and + # `config.action_dispatch.encrypted_signed_cookie_salt` are both set, legacy + # cookies encrypted with HMAC AES-256-CBC will be transparently upgraded. # - # This jar requires that you set a suitable secret for the verification on your app's +secret_key_base+. + # This jar requires that you set a suitable secret for the verification on your + # app's `secret_key_base`. # # Example: # - # cookies.encrypted[:discount] = 45 - # # => Set-Cookie: discount=DIQ7fw==--K3n//8vvnSbGq9dA--7Xh91HfLpwzbj1czhBiwOg==; path=/ + # cookies.encrypted[:discount] = 45 + # # => Set-Cookie: discount=DIQ7fw==--K3n//8vvnSbGq9dA--7Xh91HfLpwzbj1czhBiwOg==; path=/ # - # cookies.encrypted[:discount] # => 45 + # cookies.encrypted[:discount] # => 45 # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#252 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#272 def encrypted; end - # Returns a jar that'll automatically set the assigned cookies to have an expiration date 20 years from now. Example: + # Returns a jar that'll automatically set the assigned cookies to have an + # expiration date 20 years from now. Example: # - # cookies.permanent[:prefers_open_id] = true - # # => Set-Cookie: prefers_open_id=true; path=/; expires=Sun, 16-Dec-2029 03:24:16 GMT + # cookies.permanent[:prefers_open_id] = true + # # => Set-Cookie: prefers_open_id=true; path=/; expires=Sun, 16-Dec-2029 03:24:16 GMT # - # This jar is only meant for writing. You'll read permanent cookies through the regular accessor. + # This jar is only meant for writing. You'll read permanent cookies through the + # regular accessor. # - # This jar allows chaining with the signed jar as well, so you can set permanent, signed cookies. Examples: + # This jar allows chaining with the signed jar as well, so you can set + # permanent, signed cookies. Examples: # - # cookies.permanent.signed[:remember_me] = current_user.id - # # => Set-Cookie: remember_me=BAhU--848956038e692d7046deab32b7131856ab20e14e; path=/; expires=Sun, 16-Dec-2029 03:24:16 GMT + # cookies.permanent.signed[:remember_me] = current_user.id + # # => Set-Cookie: remember_me=BAhU--848956038e692d7046deab32b7131856ab20e14e; path=/; expires=Sun, 16-Dec-2029 03:24:16 GMT # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#218 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#232 def permanent; end - # Returns a jar that'll automatically generate a signed representation of cookie value and verify it when reading from - # the cookie again. This is useful for creating cookies with values that the user is not supposed to change. If a signed - # cookie was tampered with by the user (or a 3rd party), +nil+ will be returned. + # Returns a jar that'll automatically generate a signed representation of cookie + # value and verify it when reading from the cookie again. This is useful for + # creating cookies with values that the user is not supposed to change. If a + # signed cookie was tampered with by the user (or a 3rd party), `nil` will be + # returned. # - # This jar requires that you set a suitable secret for the verification on your app's +secret_key_base+. + # This jar requires that you set a suitable secret for the verification on your + # app's `secret_key_base`. # # Example: # - # cookies.signed[:discount] = 45 - # # => Set-Cookie: discount=BAhpMg==--2c1c6906c90a3bc4fd54a51ffb41dffa4bf6b5f7; path=/ + # cookies.signed[:discount] = 45 + # # => Set-Cookie: discount=BAhpMg==--2c1c6906c90a3bc4fd54a51ffb41dffa4bf6b5f7; path=/ # - # cookies.signed[:discount] # => 45 + # cookies.signed[:discount] # => 45 # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#234 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#251 def signed; end - # Returns the +signed+ or +encrypted+ jar, preferring +encrypted+ if +secret_key_base+ is set. - # Used by ActionDispatch::Session::CookieStore to avoid the need to introduce new cookie stores. + # Returns the `signed` or `encrypted` jar, preferring `encrypted` if + # `secret_key_base` is set. Used by ActionDispatch::Session::CookieStore to + # avoid the need to introduce new cookie stores. # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#258 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#279 def signed_or_encrypted; end private - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#281 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#302 def encrypted_cookie_cipher; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#275 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#296 def prepare_upgrade_legacy_hmac_aes_cbc_cookies?; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#285 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#306 def signed_cookie_digest; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#268 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#289 def upgrade_legacy_hmac_aes_cbc_cookies?; end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#290 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#311 class ActionDispatch::Cookies::CookieJar include ::ActionDispatch::Cookies::ChainedCookieJars include ::Enumerable # @return [CookieJar] a new instance of CookieJar # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#301 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#322 def initialize(request); end - # Returns the value of the cookie by +name+, or +nil+ if no such cookie exists. + # Returns the value of the cookie by `name`, or `nil` if no such cookie exists. # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#322 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#343 def [](name); end - # Sets the cookie named +name+. The second argument may be the cookie's - # value or a hash of options as documented above. + # Sets the cookie named `name`. The second argument may be the cookie's value or + # a hash of options as documented above. # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#356 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#377 def []=(name, options); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#410 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#439 def always_write_cookie; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#410 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#439 def always_write_cookie=(val); end - # Removes all cookies on the client machine by calling delete for each cookie. + # Removes all cookies on the client machine by calling `delete` for each cookie. # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#400 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#423 def clear(options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#311 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#332 def commit!; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#309 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#330 def committed?; end - # Removes the cookie on the client machine by setting the value to an empty string - # and the expiration date in the past. Like []=, you can pass in - # an options hash to delete cookies with extra data such as a :path. + # Removes the cookie on the client machine by setting the value to an empty + # string and the expiration date in the past. Like `[]=`, you can pass in an + # options hash to delete cookies with extra data such as a `:path`. # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#379 + # Returns the value of the cookie, or `nil` if the cookie does not exist. + # + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#402 def delete(name, options = T.unsafe(nil)); end - # Whether the given cookie is to be deleted by this CookieJar. - # Like []=, you can pass in an options hash to test if a - # deletion applies to a specific :path, :domain etc. + # Whether the given cookie is to be deleted by this CookieJar. Like `[]=`, you + # can pass in an options hash to test if a deletion applies to a specific + # `:path`, `:domain` etc. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#393 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#416 def deleted?(name, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#317 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#338 def each(&block); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#326 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#347 def fetch(name, *args, &block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#330 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#351 def has_key?(name); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#330 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#351 def key?(name); end # Returns the value of attribute request. # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#299 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#320 def request; end # Returns the cookies as Hash. def to_hash(*_arg0); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#350 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#371 def to_header; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#338 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#359 def update(other_hash); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#343 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#364 def update_cookies_from_jar; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#404 - def write(headers); end + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#427 + def write(response); end private - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#413 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#442 def escape(string); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#434 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#450 def handle_options(options); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#417 - def make_set_cookie_header(header); end - # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#430 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#446 def write_cookie?(cookie); end class << self - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#410 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#439 def always_write_cookie; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#410 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#439 def always_write_cookie=(val); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#293 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#314 def build(req, cookies); end end end # Raised when storing more than 4K of session data. # -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#203 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#214 class ActionDispatch::Cookies::CookieOverflow < ::StandardError; end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#190 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#201 ActionDispatch::Cookies::ENCRYPTED_COOKIE_CIPHER = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#186 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#197 ActionDispatch::Cookies::ENCRYPTED_COOKIE_SALT = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#187 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#198 ActionDispatch::Cookies::ENCRYPTED_SIGNED_COOKIE_SALT = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#645 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#646 class ActionDispatch::Cookies::EncryptedKeyRotatingCookieJar < ::ActionDispatch::Cookies::AbstractCookieJar include ::ActionDispatch::Cookies::SerializedCookieJars # @return [EncryptedKeyRotatingCookieJar] a new instance of EncryptedKeyRotatingCookieJar # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#648 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#649 def initialize(parent_jar); end private - # @raise [CookieOverflow] - # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#690 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#691 def commit(name, options); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#682 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#683 def parse(name, encrypted_message, purpose: T.unsafe(nil)); end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#184 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#195 ActionDispatch::Cookies::GENERATOR_KEY = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#183 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#194 ActionDispatch::Cookies::HTTP_HEADER = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#556 -class ActionDispatch::Cookies::JsonSerializer - class << self - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#561 - def dump(value); end - - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#557 - def load(value); end - end -end - # Cookies can typically store 4096 bytes. # -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#200 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#211 ActionDispatch::Cookies::MAX_COOKIE_SIZE = T.let(T.unsafe(nil), Integer) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#544 -class ActionDispatch::Cookies::MarshalWithJsonFallback - class << self - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#551 - def dump(value); end - - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#545 - def load(value); end - end -end - -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#537 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#556 class ActionDispatch::Cookies::PermanentCookieJar < ::ActionDispatch::Cookies::AbstractCookieJar private - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#539 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#558 def commit(name, options); end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#192 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#203 ActionDispatch::Cookies::SECRET_KEY_BASE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#191 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#202 ActionDispatch::Cookies::SIGNED_COOKIE_DIGEST = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#185 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#196 ActionDispatch::Cookies::SIGNED_COOKIE_SALT = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#566 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#563 module ActionDispatch::Cookies::SerializedCookieJars protected - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#579 - def deserialize(name); end - - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#611 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#567 def digest; end + private + + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#610 + def check_for_overflow!(name, options); end + + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#606 + def commit(name, options); end + + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#592 + def parse(name, dumped, force_reserialize: T.unsafe(nil), **_arg3); end + # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#571 - def needs_migration?(value); end + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#586 + def reserialize?(dumped); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#575 - def serialize(value); end - - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#599 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#572 def serializer; end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#567 -ActionDispatch::Cookies::SerializedCookieJars::MARSHAL_SIGNATURE = T.let(T.unsafe(nil), String) - -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#568 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#564 ActionDispatch::Cookies::SerializedCookieJars::SERIALIZER = ActiveSupport::MessageEncryptor::NullSerializer -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#616 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#617 class ActionDispatch::Cookies::SignedKeyRotatingCookieJar < ::ActionDispatch::Cookies::AbstractCookieJar include ::ActionDispatch::Cookies::SerializedCookieJars # @return [SignedKeyRotatingCookieJar] a new instance of SignedKeyRotatingCookieJar # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#619 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#620 def initialize(parent_jar); end private - # @raise [CookieOverflow] - # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#638 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#639 def commit(name, options); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#632 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#633 def parse(name, signed_message, purpose: T.unsafe(nil)); end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#189 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#200 ActionDispatch::Cookies::USE_AUTHENTICATED_COOKIE_ENCRYPTION = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#197 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#208 ActionDispatch::Cookies::USE_COOKIES_WITH_METADATA = T.let(T.unsafe(nil), String) -# This middleware is responsible for logging exceptions and -# showing a debugging page in case the request is local. +# # Action Dispatch DebugExceptions +# +# This middleware is responsible for logging exceptions and showing a debugging +# page in case the request is local. # -# source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#11 +# source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#15 class ActionDispatch::DebugExceptions # @return [DebugExceptions] a new instance of DebugExceptions # - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#19 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#23 def initialize(app, routes_app = T.unsafe(nil), response_format = T.unsafe(nil), interceptors = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#26 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#30 def call(env); end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#176 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#185 def api_request?(content_type); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#114 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#116 def create_template(request, wrapper); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#43 - def invoke_interceptors(request, exception); end + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#50 + def invoke_interceptors(request, exception, wrapper); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#152 - def log_array(logger, lines); end + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#159 + def log_array(logger, lines, request); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#133 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#135 def log_error(request, wrapper); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#180 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#189 def log_rescued_responses?(request); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#162 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#171 def logger(request); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#129 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#131 def render(status, body, format); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#54 - def render_exception(request, exception); end + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#58 + def render_exception(request, exception, wrapper); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#90 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#92 def render_for_api_request(content_type, wrapper); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#76 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#78 def render_for_browser_request(request, wrapper); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#170 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#179 def routes_inspector(exception); end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#166 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#175 def stderr_logger; end class << self - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#12 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#16 def interceptors; end - # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#14 + # source://actionpack//lib/action_dispatch/middleware/debug_exceptions.rb#18 def register_interceptor(object = T.unsafe(nil), &block); end end end +# # Action Dispatch DebugLocks +# # This middleware can be used to diagnose deadlocks in the autoload interlock. # # To use it, insert it near the top of the middleware stack, using -# config/application.rb: +# `config/application.rb`: # # config.middleware.insert_before Rack::Sendfile, ActionDispatch::DebugLocks # -# After restarting the application and re-triggering the deadlock condition, -# the route /rails/locks will show a summary of all threads currently -# known to the interlock, which lock level they are holding or awaiting, and -# their current backtrace. +# After restarting the application and re-triggering the deadlock condition, the +# route `/rails/locks` will show a summary of all threads currently known to the +# interlock, which lock level they are holding or awaiting, and their current +# backtrace. # # Generally a deadlock will be caused by the interlock conflicting with some # other external lock or blocking I/O call. These cannot be automatically @@ -9366,781 +10238,888 @@ end # This middleware exposes operational details of the server, with no access # control. It should only be enabled when in use, and removed thereafter. # -# source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#25 +# source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#29 class ActionDispatch::DebugLocks # @return [DebugLocks] a new instance of DebugLocks # - # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#26 + # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#30 def initialize(app, path = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#31 + # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#35 def call(env); end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#103 + # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#108 def blocked_by?(victim, blocker, all_threads); end - # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#45 + # source://actionpack//lib/action_dispatch/middleware/debug_locks.rb#49 def render_details(req); end end -# source://actionpack//lib/action_dispatch/middleware/debug_view.rb#9 +# source://actionpack//lib/action_dispatch/middleware/debug_view.rb#11 class ActionDispatch::DebugView < ::ActionView::Base # @return [DebugView] a new instance of DebugView # - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#12 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#14 def initialize(assigns); end - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#18 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#21 def compiled_method_container; end - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#42 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#49 def debug_hash(object); end - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#34 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#41 def debug_headers(headers); end - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#22 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#29 def debug_params(params); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#60 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#25 + def error_highlight_available?; end + + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#67 def params_valid?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#56 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#63 def protect_against_forgery?; end - # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#46 + # source://actionpack//lib/action_dispatch/middleware/debug_view.rb#53 def render(*_arg0); end end -# source://actionpack//lib/action_dispatch/middleware/debug_view.rb#10 -ActionDispatch::DebugView::RESCUES_TEMPLATE_PATH = T.let(T.unsafe(nil), String) +# source://actionpack//lib/action_dispatch/middleware/debug_view.rb#12 +ActionDispatch::DebugView::RESCUES_TEMPLATE_PATHS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#7 +# source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#11 class ActionDispatch::ExceptionWrapper # @return [ExceptionWrapper] a new instance of ExceptionWrapper # - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#46 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#50 def initialize(backtrace_cleaner, exception); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#77 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#101 + def actions; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#113 + def annotated_source_code; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#135 def application_trace; end # Returns the value of attribute backtrace_cleaner. # - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#44 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#48 def backtrace_cleaner; end + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#89 + def corrections; end + + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#204 + def error_highlight_available?; end + # Returns the value of attribute exception. # - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#44 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#48 def exception; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#71 + # Returns the value of attribute exception_class_name. + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#48 + def exception_class_name; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#234 + def exception_id; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#230 + def exception_inspect; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#222 + def exception_name; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#129 def exception_trace; end - # Returns the value of attribute file. - # - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#44 - def file; end + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#77 + def failures; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#81 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#93 + def file_name; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#139 def framework_trace; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#85 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#143 def full_trace; end - # Returns the value of attribute line_number. + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#73 + def has_cause?; end + + # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#44 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#81 + def has_corrections?; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#97 def line_number; end + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#226 + def message; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#85 + def original_message; end + # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#121 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#194 def rescue_response?; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#8 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#12 def rescue_responses; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#8 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#12 def rescue_responses=(val); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#63 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#121 def rescue_template; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#26 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#30 def rescue_templates; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#26 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#30 def rescue_templates=(val); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#61 + def routing_error?; end + + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#179 + def show?(request); end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#43 def silent_exceptions; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#43 def silent_exceptions=(val); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#125 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#198 def source_extracts; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#144 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#218 def source_to_show_id; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#67 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#125 def status_code; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#136 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#69 + def sub_template_message; end + + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#65 + def template_error?; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#210 def trace_to_show; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#89 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#147 def traces; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#55 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#105 def unwrapped_exception; end # Returns the value of attribute wrapped_causes. # - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#44 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#48 def wrapped_causes; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#35 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 def wrapper_exceptions; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#35 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 def wrapper_exceptions=(val); end private - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#149 + # Returns the value of attribute backtrace. + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#258 def backtrace; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#153 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#260 + def build_backtrace; end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#283 def causes_for(exception); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#163 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#293 def clean_backtrace(*args); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#190 - def expand_backtrace; end - - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#183 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#346 def extract_file_and_line_number(trace); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#171 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#301 + def extract_source(trace); end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#330 + def extract_source_fragment_lines(source_lines, line); end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#336 def source_fragment(path, line); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#159 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#289 def wrapped_causes_for(exception, backtrace_cleaner); end class << self - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#8 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#12 def rescue_responses; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#8 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#12 def rescue_responses=(val); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#26 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#30 def rescue_templates; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#26 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#30 def rescue_templates=(val); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#43 def silent_exceptions; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#43 def silent_exceptions=(val); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#117 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#175 def status_code_for_exception(class_name); end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#35 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 def wrapper_exceptions; end - # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#35 + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#39 def wrapper_exceptions=(val); end end end -# source://actionpack//lib/action_dispatch/middleware/executor.rb#6 +# source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#239 +class ActionDispatch::ExceptionWrapper::SourceMapLocation + # @return [SourceMapLocation] a new instance of SourceMapLocation + # + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#240 + def initialize(location, template); end + + # source://actionpack//lib/action_dispatch/middleware/exception_wrapper.rb#245 + def spot(exc); end +end + +# source://actionpack//lib/action_dispatch/middleware/executor.rb#8 class ActionDispatch::Executor # @return [Executor] a new instance of Executor # - # source://actionpack//lib/action_dispatch/middleware/executor.rb#7 + # source://actionpack//lib/action_dispatch/middleware/executor.rb#9 def initialize(app, executor); end - # source://actionpack//lib/action_dispatch/middleware/executor.rb#11 + # source://actionpack//lib/action_dispatch/middleware/executor.rb#13 def call(env); end end -# This endpoint serves static files from disk using +Rack::File+. +# # Action Dispatch FileHandler +# +# This endpoint serves static files from disk using `Rack::Files`. # -# URL paths are matched with static files according to expected -# conventions: +path+, +path+.html, +path+/index.html. +# URL paths are matched with static files according to expected conventions: +# `path`, `path`.html, `path`/index.html. # -# Precompressed versions of these files are checked first. Brotli (.br) -# and gzip (.gz) files are supported. If +path+.br exists, this -# endpoint returns that file with a Content-Encoding: br header. +# Precompressed versions of these files are checked first. Brotli (.br) and gzip +# (.gz) files are supported. If `path`.br exists, this endpoint returns that # -# If no matching file is found, this endpoint responds 404 Not Found. +# If no matching file is found, this endpoint responds `404 Not Found`. # -# Pass the +root+ directory to search for matching files, an optional -# index: "index" to change the default +path+/index.html, and optional -# additional response headers. +# Pass the `root` directory to search for matching files, an optional `index: +# "index"` to change the default `path`/index.html, and optional additional +# response headers. # -# source://actionpack//lib/action_dispatch/middleware/static.rb#41 +# source://actionpack//lib/action_dispatch/middleware/static.rb#47 class ActionDispatch::FileHandler # @return [FileHandler] a new instance of FileHandler # - # source://actionpack//lib/action_dispatch/middleware/static.rb#49 + # source://actionpack//lib/action_dispatch/middleware/static.rb#55 def initialize(root, index: T.unsafe(nil), headers: T.unsafe(nil), precompressed: T.unsafe(nil), compressible_content_types: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/static.rb#63 + # source://actionpack//lib/action_dispatch/middleware/static.rb#69 def attempt(env); end - # source://actionpack//lib/action_dispatch/middleware/static.rb#59 + # source://actionpack//lib/action_dispatch/middleware/static.rb#65 def call(env); end private - # source://actionpack//lib/action_dispatch/middleware/static.rb#179 + # source://actionpack//lib/action_dispatch/middleware/static.rb#185 def clean_path(path_info); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/static.rb#143 + # source://actionpack//lib/action_dispatch/middleware/static.rb#149 def compressible?(content_type); end # @yield [path, content_type || "text/plain"] # - # source://actionpack//lib/action_dispatch/middleware/static.rb#156 + # source://actionpack//lib/action_dispatch/middleware/static.rb#162 def each_candidate_filepath(path_info); end - # source://actionpack//lib/action_dispatch/middleware/static.rb#147 + # source://actionpack//lib/action_dispatch/middleware/static.rb#153 def each_precompressed_filepath(filepath); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/static.rb#138 + # source://actionpack//lib/action_dispatch/middleware/static.rb#144 def file_readable?(path); end # Match a URI path to a static file to be served. # - # Used by the +Static+ class to negotiate a servable file in the - # +public/+ directory (see Static#call). + # Used by the `Static` class to negotiate a servable file in the `public/` + # directory (see Static#call). # - # Checks for +path+, +path+.html, and +path+/index.html files, - # in that order, including .br and .gzip compressed extensions. + # Checks for `path`, `path`.html, and `path`/index.html files, in that order, + # including .br and .gzip compressed extensions. # # If a matching file is found, the path and necessary response headers # (Content-Type, Content-Encoding) are returned. # - # source://actionpack//lib/action_dispatch/middleware/static.rb#98 + # source://actionpack//lib/action_dispatch/middleware/static.rb#104 def find_file(path_info, accept_encoding:); end - # source://actionpack//lib/action_dispatch/middleware/static.rb#74 + # source://actionpack//lib/action_dispatch/middleware/static.rb#80 def serve(request, filepath, content_headers); end - # source://actionpack//lib/action_dispatch/middleware/static.rb#106 + # source://actionpack//lib/action_dispatch/middleware/static.rb#112 def try_files(filepath, content_type, accept_encoding:); end - # source://actionpack//lib/action_dispatch/middleware/static.rb#116 + # source://actionpack//lib/action_dispatch/middleware/static.rb#122 def try_precompressed_files(filepath, headers, accept_encoding:); end end -# +Accept-Encoding+ value -> file extension +# `Accept-Encoding` value -> file extension # -# source://actionpack//lib/action_dispatch/middleware/static.rb#43 +# source://actionpack//lib/action_dispatch/middleware/static.rb#49 ActionDispatch::FileHandler::PRECOMPRESSED = T.let(T.unsafe(nil), Hash) -# The flash provides a way to pass temporary primitive-types (String, Array, Hash) between actions. Anything you place in the flash will be exposed -# to the very next action and then cleared out. This is a great way of doing notices and alerts, such as a create -# action that sets flash[:notice] = "Post successfully created" before redirecting to a display action that can -# then expose the flash to its template. Actually, that exposure is automatically done. -# -# class PostsController < ActionController::Base -# def create -# # save post -# flash[:notice] = "Post successfully created" -# redirect_to @post -# end +# # Action Dispatch Flash +# +# The flash provides a way to pass temporary primitive-types (String, Array, +# Hash) between actions. Anything you place in the flash will be exposed to the +# very next action and then cleared out. This is a great way of doing notices +# and alerts, such as a create action that sets `flash[:notice] = "Post +# successfully created"` before redirecting to a display action that can then +# expose the flash to its template. Actually, that exposure is automatically +# done. +# +# class PostsController < ActionController::Base +# def create +# # save post +# flash[:notice] = "Post successfully created" +# redirect_to @post +# end # -# def show -# # doesn't need to assign the flash notice to the template, that's done automatically +# def show +# # doesn't need to assign the flash notice to the template, that's done automatically +# end # end -# end # -# Then in +show.html.erb+: +# Then in `show.html.erb`: # -# <% if flash[:notice] %> -#
<%= flash[:notice] %>
-# <% end %> +# <% if flash[:notice] %> +#
<%= flash[:notice] %>
+# <% end %> # -# Since the +notice+ and +alert+ keys are a common idiom, convenience accessors are available: +# Since the `notice` and `alert` keys are a common idiom, convenience accessors +# are available: # -# flash.alert = "You must be logged in" -# flash.notice = "Post successfully created" +# flash.alert = "You must be logged in" +# flash.notice = "Post successfully created" # -# This example places a string in the flash. And of course, you can put as many as you like at a time too. If you want to pass -# non-primitive types, you will have to handle that in your application. Example: To show messages with links, you will have to -# use sanitize helper. +# This example places a string in the flash. And of course, you can put as many +# as you like at a time too. If you want to pass non-primitive types, you will +# have to handle that in your application. Example: To show messages with links, +# you will have to use sanitize helper. # # Just remember: They'll be gone by the time the next action has been performed. # # See docs on the FlashHash class for more details about the flash. # -# source://actionpack//lib/action_dispatch/middleware/flash.rb#41 +# source://actionpack//lib/action_dispatch/middleware/flash.rb#50 class ActionDispatch::Flash class << self - # source://actionpack//lib/action_dispatch/middleware/flash.rb#293 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#312 def new(app); end end end -# source://actionpack//lib/action_dispatch/middleware/flash.rb#110 +# source://actionpack//lib/action_dispatch/middleware/flash.rb#119 class ActionDispatch::Flash::FlashHash include ::Enumerable # @return [FlashHash] a new instance of FlashHash # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#140 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#149 def initialize(flashes = T.unsafe(nil), discard = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#160 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#169 def [](k); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#154 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#163 def []=(k, v); end - # Convenience accessor for flash[:alert]. + # Convenience accessor for `flash[:alert]`. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#261 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#280 def alert; end - # Convenience accessor for flash[:alert]=. + # Convenience accessor for `flash[:alert]=`. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#266 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#285 def alert=(message); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#193 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#204 def clear; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#178 + # Immediately deletes the single flash entry. Use this method when you want + # remove the message within the current action. See also #discard. + # + # source://actionpack//lib/action_dispatch/middleware/flash.rb#189 def delete(key); end - # Marks the entire flash or a single flash entry to be discarded by the end of the current action: + # Marks the entire flash or a single flash entry to be discarded by the end of + # the current action: # # flash.discard # discard the entire flash at the end of the current action # flash.discard(:warning) # discard only the "warning" entry at the end of the current action # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#246 + # Use this method when you want to display the message in the current action but + # not in the next one. See also #delete. + # + # source://actionpack//lib/action_dispatch/middleware/flash.rb#264 def discard(k = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#198 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#209 def each(&block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#189 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#200 def empty?; end - # Keeps either the entire current flash or a specific flash entry available for the next action: + # Keeps either the entire current flash or a specific flash entry available for + # the next action: # - # flash.keep # keeps the entire flash - # flash.keep(:notice) # keeps only the "notice" entry, the rest of the flash is discarded + # flash.keep # keeps the entire flash + # flash.keep(:notice) # keeps only the "notice" entry, the rest of the flash is discarded # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#236 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#250 def keep(k = T.unsafe(nil)); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#174 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#183 def key?(name); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#170 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#179 def keys; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#164 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#173 def merge!(h); end - # Convenience accessor for flash[:notice]. + # Convenience accessor for `flash[:notice]`. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#271 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#290 def notice; end - # Convenience accessor for flash[:notice]=. + # Convenience accessor for `flash[:notice]=`. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#276 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#295 def notice=(message); end - # Sets a flash that will not be available to the next action, only to the current. + # Sets a flash that will not be available to the next action, only to the + # current. # # flash.now[:message] = "Hello current action" # - # This method enables you to use the flash as a central messaging system in your app. - # When you need to pass an object to the next action, you use the standard flash assign ([]=). - # When you need to pass an object to the current action, you use now, and your object will - # vanish when the current action is done. + # This method enables you to use the flash as a central messaging system in your + # app. When you need to pass an object to the next action, you use the standard + # flash assign (`[]=`). When you need to pass an object to the current action, + # you use `now`, and your object will vanish when the current action is done. # - # Entries set via now are accessed the same way as standard entries: flash['my-key']. + # Entries set via `now` are accessed the same way as standard entries: + # `flash['my-key']`. # # Also, brings two convenience accessors: # - # flash.now.alert = "Beware now!" - # # Equivalent to flash.now[:alert] = "Beware now!" + # flash.now.alert = "Beware now!" + # # Equivalent to flash.now[:alert] = "Beware now!" # - # flash.now.notice = "Good luck now!" - # # Equivalent to flash.now[:notice] = "Good luck now!" + # flash.now.notice = "Good luck now!" + # # Equivalent to flash.now[:notice] = "Good luck now!" # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#228 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#241 def now; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#204 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#215 def replace(h); end # Mark for removal entries that were kept, and delete unkept ones. # - # This method is called automatically by filters, so you generally don't need to care about it. + # This method is called automatically by filters, so you generally don't need to + # care about it. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#255 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#274 def sweep; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#185 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#196 def to_hash; end - # Builds a hash containing the flashes to keep for the next request. - # If there are none to keep, returns +nil+. + # Builds a hash containing the flashes to keep for the next request. If there + # are none to keep, returns `nil`. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#134 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#143 def to_session_value; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#164 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#173 def update(h); end protected # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#281 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#300 def now_is_loaded?; end private - # source://actionpack//lib/action_dispatch/middleware/flash.rb#146 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#155 def initialize_copy(other); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#286 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#305 def stringify_array(array); end class << self - # source://actionpack//lib/action_dispatch/middleware/flash.rb#113 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#122 def from_session_value(value); end end end -# source://actionpack//lib/action_dispatch/middleware/flash.rb#81 +# source://actionpack//lib/action_dispatch/middleware/flash.rb#90 class ActionDispatch::Flash::FlashNow # @return [FlashNow] a new instance of FlashNow # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#84 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#93 def initialize(flash); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#95 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#104 def [](k); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#88 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#97 def []=(k, v); end - # Convenience accessor for flash.now[:alert]=. + # Convenience accessor for `flash.now[:alert]=`. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#100 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#109 def alert=(message); end # Returns the value of attribute flash. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#82 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#91 def flash; end # Sets the attribute flash # # @param value the value to set the attribute flash to. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#82 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#91 def flash=(_arg0); end - # Convenience accessor for flash.now[:notice]=. + # Convenience accessor for `flash.now[:notice]=`. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#105 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#114 def notice=(message); end end -# source://actionpack//lib/action_dispatch/middleware/flash.rb#42 +# source://actionpack//lib/action_dispatch/middleware/flash.rb#51 ActionDispatch::Flash::KEY = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/flash.rb#44 +# source://actionpack//lib/action_dispatch/middleware/flash.rb#53 module ActionDispatch::Flash::RequestMethods - # source://actionpack//lib/action_dispatch/middleware/flash.rb#62 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#71 def commit_flash; end # Access the contents of the flash. Returns a ActionDispatch::Flash::FlashHash. # # See ActionDispatch::Flash for example usage. # - # source://actionpack//lib/action_dispatch/middleware/flash.rb#48 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#57 def flash; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#54 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#63 def flash=(flash); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#58 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#67 def flash_hash; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#75 + # source://actionpack//lib/action_dispatch/middleware/flash.rb#84 def reset_session; end end -# This middleware guards from DNS rebinding attacks by explicitly permitting -# the hosts a request can be sent to, and is passed the options set in -# +config.host_authorization+. +# # Action Dispatch HostAuthorization # -# Requests can opt-out of Host Authorization with +exclude+: +# This middleware guards from DNS rebinding attacks by explicitly permitting the +# hosts a request can be sent to, and is passed the options set in +# `config.host_authorization`. # -# config.host_authorization = { exclude: ->(request) { request.path =~ /healthcheck/ } } +# Requests can opt-out of Host Authorization with `exclude`: # -# When a request comes to an unauthorized host, the +response_app+ -# application will be executed and rendered. If no +response_app+ is given, a -# default one will run. -# The default response app logs blocked host info with level 'error' and -# responds with 403 Forbidden. The body of the response contains debug info -# if +config.consider_all_requests_local+ is set to true, otherwise the body is empty. +# config.host_authorization = { exclude: ->(request) { request.path =~ /healthcheck/ } } # -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#18 +# When a request comes to an unauthorized host, the `response_app` application +# will be executed and rendered. If no `response_app` is given, a default one +# will run. The default response app logs blocked host info with level 'error' +# and responds with `403 Forbidden`. The body of the response contains debug +# info if `config.consider_all_requests_local` is set to true, otherwise the +# body is empty. +# +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#22 class ActionDispatch::HostAuthorization # @return [HostAuthorization] a new instance of HostAuthorization # - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#122 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#127 def initialize(app, hosts, exclude: T.unsafe(nil), response_app: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#130 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#135 def call(env); end private - # @return [Boolean] - # - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#144 - def authorized?(request); end + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#151 + def blocked_hosts(request); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#151 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#163 def excluded?(request); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#155 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#167 def mark_as_authorized(request); end end -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#19 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#23 ActionDispatch::HostAuthorization::ALLOWED_HOSTS_IN_DEVELOPMENT = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#83 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#88 class ActionDispatch::HostAuthorization::DefaultResponseApp - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#86 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#91 def call(env); end private - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#117 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#122 def available_logger(request); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#109 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#114 def log_error(request); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#102 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#107 def response(format, body); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#95 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#100 def response_body(request); end end -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#84 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#89 ActionDispatch::HostAuthorization::DefaultResponseApp::RESPONSE_STATUS = T.let(T.unsafe(nil), Integer) -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#21 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#26 ActionDispatch::HostAuthorization::IPV4_HOSTNAME = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#22 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#27 ActionDispatch::HostAuthorization::IPV6_HOSTNAME = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#23 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#28 ActionDispatch::HostAuthorization::IPV6_HOSTNAME_WITH_PORT = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#20 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#24 ActionDispatch::HostAuthorization::PORT_REGEX = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#30 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#35 class ActionDispatch::HostAuthorization::Permissions # @return [Permissions] a new instance of Permissions # - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#31 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#36 def initialize(hosts); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#39 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#44 def allows?(host); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#35 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#40 def empty?; end private - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#78 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#83 def extract_hostname(host); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#56 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#61 def sanitize_hosts(hosts); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#66 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#71 def sanitize_regexp(host); end - # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#70 + # source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#75 def sanitize_string(host); end end -# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#24 +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#25 +ActionDispatch::HostAuthorization::SUBDOMAIN_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://actionpack//lib/action_dispatch/middleware/host_authorization.rb#29 ActionDispatch::HostAuthorization::VALID_IP_HOSTNAME = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch.rb#80 +# source://actionpack//lib/action_dispatch.rb#89 module ActionDispatch::Http extend ::ActiveSupport::Autoload end -# source://actionpack//lib/action_dispatch/http/cache.rb#5 +# source://actionpack//lib/action_dispatch/http/cache.rb#7 module ActionDispatch::Http::Cache; end -# source://actionpack//lib/action_dispatch/http/cache.rb#6 +# source://actionpack//lib/action_dispatch/http/cache.rb#8 module ActionDispatch::Http::Cache::Request # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#28 + # source://actionpack//lib/action_dispatch/http/cache.rb#30 def etag_matches?(etag); end - # Check response freshness (+Last-Modified+ and ETag) against request - # +If-Modified-Since+ and +If-None-Match+ conditions. If both headers are + # Check response freshness (`Last-Modified` and ETag) against request + # `If-Modified-Since` and `If-None-Match` conditions. If both headers are # supplied, both must match, or the request is not considered fresh. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#38 + # source://actionpack//lib/action_dispatch/http/cache.rb#40 def fresh?(response); end - # source://actionpack//lib/action_dispatch/http/cache.rb#10 + # source://actionpack//lib/action_dispatch/http/cache.rb#12 def if_modified_since; end - # source://actionpack//lib/action_dispatch/http/cache.rb#16 + # source://actionpack//lib/action_dispatch/http/cache.rb#18 def if_none_match; end - # source://actionpack//lib/action_dispatch/http/cache.rb#20 + # source://actionpack//lib/action_dispatch/http/cache.rb#22 def if_none_match_etags; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#24 + # source://actionpack//lib/action_dispatch/http/cache.rb#26 def not_modified?(modified_at); end end -# source://actionpack//lib/action_dispatch/http/cache.rb#7 +# source://actionpack//lib/action_dispatch/http/cache.rb#9 ActionDispatch::Http::Cache::Request::HTTP_IF_MODIFIED_SINCE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/cache.rb#8 +# source://actionpack//lib/action_dispatch/http/cache.rb#10 ActionDispatch::Http::Cache::Request::HTTP_IF_NONE_MATCH = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/cache.rb#51 +# source://actionpack//lib/action_dispatch/http/cache.rb#53 module ActionDispatch::Http::Cache::Response # Returns the value of attribute cache_control. # - # source://actionpack//lib/action_dispatch/http/cache.rb#52 + # source://actionpack//lib/action_dispatch/http/cache.rb#54 def cache_control; end - # source://actionpack//lib/action_dispatch/http/cache.rb#68 + # source://actionpack//lib/action_dispatch/http/cache.rb#70 def date; end - # source://actionpack//lib/action_dispatch/http/cache.rb#78 + # source://actionpack//lib/action_dispatch/http/cache.rb#80 def date=(utc_time); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#74 + # source://actionpack//lib/action_dispatch/http/cache.rb#76 def date?; end - # This method sets a weak ETag validator on the response so browsers - # and proxies may cache the response, keyed on the ETag. On subsequent - # requests, the +If-None-Match+ header is set to the cached ETag. If it - # matches the current ETag, we can return a 304 Not Modified response - # with no body, letting the browser or proxy know that their cache is - # current. Big savings in request time and network bandwidth. + # This method sets a weak ETag validator on the response so browsers and proxies + # may cache the response, keyed on the ETag. On subsequent requests, the + # `If-None-Match` header is set to the cached ETag. If it matches the current + # ETag, we can return a `304 Not Modified` response with no body, letting the + # browser or proxy know that their cache is current. Big savings in request time + # and network bandwidth. # - # Weak ETags are considered to be semantically equivalent but not - # byte-for-byte identical. This is perfect for browser caching of HTML - # pages where we don't care about exact equality, just what the user - # is viewing. + # Weak ETags are considered to be semantically equivalent but not byte-for-byte + # identical. This is perfect for browser caching of HTML pages where we don't + # care about exact equality, just what the user is viewing. # - # Strong ETags are considered byte-for-byte identical. They allow a - # browser or proxy cache to support +Range+ requests, useful for paging - # through a PDF file or scrubbing through a video. Some CDNs only - # support strong ETags and will ignore weak ETags entirely. + # Strong ETags are considered byte-for-byte identical. They allow a browser or + # proxy cache to support `Range` requests, useful for paging through a PDF file + # or scrubbing through a video. Some CDNs only support strong ETags and will + # ignore weak ETags entirely. # - # Weak ETags are what we almost always need, so they're the default. - # Check out #strong_etag= to provide a strong ETag validator. + # Weak ETags are what we almost always need, so they're the default. Check out + # #strong_etag= to provide a strong ETag validator. # - # source://actionpack//lib/action_dispatch/http/cache.rb#101 + # source://actionpack//lib/action_dispatch/http/cache.rb#102 def etag=(weak_validators); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#113 + # source://actionpack//lib/action_dispatch/http/cache.rb#114 def etag?; end - # source://actionpack//lib/action_dispatch/http/cache.rb#54 + # source://actionpack//lib/action_dispatch/http/cache.rb#56 def last_modified; end - # source://actionpack//lib/action_dispatch/http/cache.rb#64 + # source://actionpack//lib/action_dispatch/http/cache.rb#66 def last_modified=(utc_time); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#60 + # source://actionpack//lib/action_dispatch/http/cache.rb#62 def last_modified?; end - # source://actionpack//lib/action_dispatch/http/cache.rb#109 + # source://actionpack//lib/action_dispatch/http/cache.rb#110 def strong_etag=(strong_validators); end - # True if an ETag is set, and it isn't a weak validator (not preceded with W/). + # True if an ETag is set, and it isn't a weak validator (not preceded with + # `W/`). # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#121 + # source://actionpack//lib/action_dispatch/http/cache.rb#123 def strong_etag?; end - # source://actionpack//lib/action_dispatch/http/cache.rb#105 + # source://actionpack//lib/action_dispatch/http/cache.rb#106 def weak_etag=(weak_validators); end - # True if an ETag is set, and it's a weak validator (preceded with W/). + # True if an ETag is set, and it's a weak validator (preceded with `W/`). # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/cache.rb#116 + # source://actionpack//lib/action_dispatch/http/cache.rb#117 def weak_etag?; end private @@ -10148,32 +11127,32 @@ module ActionDispatch::Http::Cache::Response # source://actionpack//lib/action_dispatch/http/cache.rb#146 def cache_control_headers; end - # source://actionpack//lib/action_dispatch/http/cache.rb#138 + # source://actionpack//lib/action_dispatch/http/cache.rb#140 def cache_control_segments; end - # source://actionpack//lib/action_dispatch/http/cache.rb#134 + # source://actionpack//lib/action_dispatch/http/cache.rb#136 def generate_strong_etag(validators); end - # source://actionpack//lib/action_dispatch/http/cache.rb#130 + # source://actionpack//lib/action_dispatch/http/cache.rb#132 def generate_weak_etag(validators); end # source://actionpack//lib/action_dispatch/http/cache.rb#175 def handle_conditional_get!; end - # source://actionpack//lib/action_dispatch/http/cache.rb#185 + # source://actionpack//lib/action_dispatch/http/cache.rb#184 def merge_and_normalize_cache_control!(cache_control); end # source://actionpack//lib/action_dispatch/http/cache.rb#164 def prepare_cache_control!; end end -# source://actionpack//lib/action_dispatch/http/cache.rb#126 +# source://actionpack//lib/action_dispatch/http/cache.rb#128 ActionDispatch::Http::Cache::Response::DATE = T.let(T.unsafe(nil), String) # source://actionpack//lib/action_dispatch/http/cache.rb#168 ActionDispatch::Http::Cache::Response::DEFAULT_CACHE_CONTROL = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/cache.rb#127 +# source://actionpack//lib/action_dispatch/http/cache.rb#129 ActionDispatch::Http::Cache::Response::LAST_MODIFIED = T.let(T.unsafe(nil), String) # source://actionpack//lib/action_dispatch/http/cache.rb#173 @@ -10191,978 +11170,982 @@ ActionDispatch::Http::Cache::Response::PRIVATE = T.let(T.unsafe(nil), String) # source://actionpack//lib/action_dispatch/http/cache.rb#171 ActionDispatch::Http::Cache::Response::PUBLIC = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/cache.rb#128 +# source://actionpack//lib/action_dispatch/http/cache.rb#130 ActionDispatch::Http::Cache::Response::SPECIAL_KEYS = T.let(T.unsafe(nil), Set) -# source://actionpack//lib/action_dispatch/http/content_disposition.rb#5 +# source://actionpack//lib/action_dispatch/http/content_disposition.rb#7 class ActionDispatch::Http::ContentDisposition # @return [ContentDisposition] a new instance of ContentDisposition # - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#12 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#14 def initialize(disposition:, filename:); end - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#19 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#21 def ascii_filename; end # Returns the value of attribute disposition. # - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#10 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#12 def disposition; end # Returns the value of attribute filename. # - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#10 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#12 def filename; end - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#29 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#31 def to_s; end - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#25 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#27 def utf8_filename; end private - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#38 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#40 def percent_escape(string, pattern); end class << self - # source://actionpack//lib/action_dispatch/http/content_disposition.rb#6 + # source://actionpack//lib/action_dispatch/http/content_disposition.rb#8 def format(disposition:, filename:); end end end -# source://actionpack//lib/action_dispatch/http/content_disposition.rb#23 +# source://actionpack//lib/action_dispatch/http/content_disposition.rb#25 ActionDispatch::Http::ContentDisposition::RFC_5987_ESCAPED_CHAR = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/content_disposition.rb#17 +# source://actionpack//lib/action_dispatch/http/content_disposition.rb#19 ActionDispatch::Http::ContentDisposition::TRADITIONAL_ESCAPED_CHAR = T.let(T.unsafe(nil), Regexp) +# # Action Dispatch HTTP Filter Parameters +# # Allows you to specify sensitive query string and POST parameters to filter # from the request log. # -# # Replaces values with "[FILTERED]" for keys that match /foo|bar/i. -# env["action_dispatch.parameter_filter"] = [:foo, "bar"] +# # Replaces values with "[FILTERED]" for keys that match /foo|bar/i. +# env["action_dispatch.parameter_filter"] = [:foo, "bar"] # -# For more information about filter behavior, see ActiveSupport::ParameterFilter. +# For more information about filter behavior, see +# ActiveSupport::ParameterFilter. # -# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#14 +# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#19 module ActionDispatch::Http::FilterParameters - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#19 + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#24 def initialize; end # Returns a hash of request.env with all sensitive data replaced. # - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#34 + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#40 def filtered_env; end # Returns a hash of parameters with all sensitive data replaced. # - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#27 + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#33 def filtered_parameters; end # Reconstructs a path with all sensitive GET parameters replaced. # - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#39 + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#45 def filtered_path; end + # Returns the `ActiveSupport::ParameterFilter` object used to filter in this + # request. + # + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#51 + def parameter_filter; end + private - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#50 + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#60 def env_filter; end - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#63 + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#73 def filtered_query_string; end - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#44 - def parameter_filter; end - - # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#57 + # source://actionpack//lib/action_dispatch/http/filter_parameters.rb#67 def parameter_filter_for(filters); end end -# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#15 +# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#20 ActionDispatch::Http::FilterParameters::ENV_MATCH = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#61 +# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#71 ActionDispatch::Http::FilterParameters::KV_RE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#17 +# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#22 ActionDispatch::Http::FilterParameters::NULL_ENV_FILTER = T.let(T.unsafe(nil), ActiveSupport::ParameterFilter) -# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#16 +# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#21 ActionDispatch::Http::FilterParameters::NULL_PARAM_FILTER = T.let(T.unsafe(nil), ActiveSupport::ParameterFilter) -# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#62 +# source://actionpack//lib/action_dispatch/http/filter_parameters.rb#72 ActionDispatch::Http::FilterParameters::PAIR_RE = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/filter_redirect.rb#5 +# source://actionpack//lib/action_dispatch/http/filter_redirect.rb#7 module ActionDispatch::Http::FilterRedirect - # source://actionpack//lib/action_dispatch/http/filter_redirect.rb#8 + # source://actionpack//lib/action_dispatch/http/filter_redirect.rb#10 def filtered_location; end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/filter_redirect.rb#25 + # source://actionpack//lib/action_dispatch/http/filter_redirect.rb#27 def location_filter_match?; end - # source://actionpack//lib/action_dispatch/http/filter_redirect.rb#17 + # source://actionpack//lib/action_dispatch/http/filter_redirect.rb#19 def location_filters; end + + # source://actionpack//lib/action_dispatch/http/filter_redirect.rb#37 + def parameter_filtered_location; end end -# source://actionpack//lib/action_dispatch/http/filter_redirect.rb#6 +# source://actionpack//lib/action_dispatch/http/filter_redirect.rb#8 ActionDispatch::Http::FilterRedirect::FILTERED = T.let(T.unsafe(nil), String) +# # Action Dispatch HTTP Headers +# # Provides access to the request's HTTP headers from the environment. # -# env = { "CONTENT_TYPE" => "text/plain", "HTTP_USER_AGENT" => "curl/7.43.0" } -# headers = ActionDispatch::Http::Headers.from_hash(env) -# headers["Content-Type"] # => "text/plain" -# headers["User-Agent"] # => "curl/7.43.0" +# env = { "CONTENT_TYPE" => "text/plain", "HTTP_USER_AGENT" => "curl/7.43.0" } +# headers = ActionDispatch::Http::Headers.from_hash(env) +# headers["Content-Type"] # => "text/plain" +# headers["User-Agent"] # => "curl/7.43.0" # # Also note that when headers are mapped to CGI-like variables by the Rack # server, both dashes and underscores are converted to underscores. This # ambiguity cannot be resolved at this stage anymore. Both underscores and # dashes have to be interpreted as if they were originally sent as dashes. # -# # GET / HTTP/1.1 -# # ... -# # User-Agent: curl/7.43.0 -# # X_Custom_Header: token +# # GET / HTTP/1.1 +# # ... +# # User-Agent: curl/7.43.0 +# # X_Custom_Header: token # -# headers["X_Custom_Header"] # => nil -# headers["X-Custom-Header"] # => "token" +# headers["X_Custom_Header"] # => nil +# headers["X-Custom-Header"] # => "token" # -# source://actionpack//lib/action_dispatch/http/headers.rb#24 +# source://actionpack//lib/action_dispatch/http/headers.rb#28 class ActionDispatch::Http::Headers include ::Enumerable # @return [Headers] a new instance of Headers # - # source://actionpack//lib/action_dispatch/http/headers.rb#54 + # source://actionpack//lib/action_dispatch/http/headers.rb#58 def initialize(request); end # Returns the value for the given key mapped to @env. # - # source://actionpack//lib/action_dispatch/http/headers.rb#59 + # source://actionpack//lib/action_dispatch/http/headers.rb#63 def [](key); end # Sets the given value for the key mapped to @env. # - # source://actionpack//lib/action_dispatch/http/headers.rb#64 + # source://actionpack//lib/action_dispatch/http/headers.rb#68 def []=(key, value); end - # Add a value to a multivalued header like +Vary+ or +Accept-Encoding+. + # Add a value to a multivalued header like `Vary` or `Accept-Encoding`. # - # source://actionpack//lib/action_dispatch/http/headers.rb#69 + # source://actionpack//lib/action_dispatch/http/headers.rb#73 def add(key, value); end - # source://actionpack//lib/action_dispatch/http/headers.rb#95 + # source://actionpack//lib/action_dispatch/http/headers.rb#98 def each(&block); end - # source://actionpack//lib/action_dispatch/http/headers.rb#116 + # source://actionpack//lib/action_dispatch/http/headers.rb#118 def env; end # Returns the value for the given key mapped to @env. # - # If the key is not found and an optional code block is not provided, - # raises a KeyError exception. + # If the key is not found and an optional code block is not provided, raises a + # `KeyError` exception. # - # If the code block is provided, then it will be run and - # its result returned. + # If the code block is provided, then it will be run and its result returned. # - # source://actionpack//lib/action_dispatch/http/headers.rb#87 + # source://actionpack//lib/action_dispatch/http/headers.rb#90 def fetch(key, default = T.unsafe(nil)); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/headers.rb#73 + # source://actionpack//lib/action_dispatch/http/headers.rb#77 def include?(key); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/headers.rb#73 + # source://actionpack//lib/action_dispatch/http/headers.rb#77 def key?(key); end # Returns a new Http::Headers instance containing the contents of - # headers_or_env and the original instance. + # `headers_or_env` and the original instance. # - # source://actionpack//lib/action_dispatch/http/headers.rb#101 + # source://actionpack//lib/action_dispatch/http/headers.rb#104 def merge(headers_or_env); end - # Adds the contents of headers_or_env to original instance - # entries; duplicate keys are overwritten with the values from - # headers_or_env. + # Adds the contents of `headers_or_env` to original instance entries; duplicate + # keys are overwritten with the values from `headers_or_env`. # - # source://actionpack//lib/action_dispatch/http/headers.rb#110 + # source://actionpack//lib/action_dispatch/http/headers.rb#112 def merge!(headers_or_env); end private - # Converts an HTTP header name to an environment variable name if it is - # not contained within the headers hash. + # Converts an HTTP header name to an environment variable name if it is not + # contained within the headers hash. # - # source://actionpack//lib/action_dispatch/http/headers.rb#121 + # source://actionpack//lib/action_dispatch/http/headers.rb#123 def env_name(key); end class << self - # source://actionpack//lib/action_dispatch/http/headers.rb#50 + # source://actionpack//lib/action_dispatch/http/headers.rb#54 def from_hash(hash); end end end -# source://actionpack//lib/action_dispatch/http/headers.rb#25 +# source://actionpack//lib/action_dispatch/http/headers.rb#29 ActionDispatch::Http::Headers::CGI_VARIABLES = T.let(T.unsafe(nil), Set) -# source://actionpack//lib/action_dispatch/http/headers.rb#78 +# source://actionpack//lib/action_dispatch/http/headers.rb#82 ActionDispatch::Http::Headers::DEFAULT = T.let(T.unsafe(nil), Object) -# source://actionpack//lib/action_dispatch/http/headers.rb#46 +# source://actionpack//lib/action_dispatch/http/headers.rb#50 ActionDispatch::Http::Headers::HTTP_HEADER = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#7 +# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#9 module ActionDispatch::Http::MimeNegotiation extend ::ActiveSupport::Concern # Returns the accepted MIME type for the request. # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#54 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#42 def accepts; end - # The MIME type of the HTTP request, such as Mime[:xml]. + # The MIME type of the HTTP request, such as [Mime](:xml). # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#23 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#24 def content_mime_type; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#36 - def content_type; end - - # Returns the MIME type for the \format used in the request. + # Returns the MIME type for the format used in the request. # - # GET /posts/5.xml | request.format => Mime[:xml] - # GET /posts/5.xhtml | request.format => Mime[:html] - # GET /posts/5 | request.format => Mime[:html] or Mime[:js], or request.accepts.first + # GET /posts/5.xml | request.format => Mime[:xml] + # GET /posts/5.xhtml | request.format => Mime[:html] + # GET /posts/5 | request.format => Mime[:html] or Mime[:js], or request.accepts.first # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#75 - def format(view_path = T.unsafe(nil)); end + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#63 + def format(_view_path = T.unsafe(nil)); end - # Sets the \format by string extension, which can be used to force custom formats + # Sets the format by string extension, which can be used to force custom formats # that are not controlled by the extension. # - # class ApplicationController < ActionController::Base - # before_action :adjust_format_for_iphone + # class ApplicationController < ActionController::Base + # before_action :adjust_format_for_iphone # - # private - # def adjust_format_for_iphone - # request.format = :iphone if request.env["HTTP_USER_AGENT"][/iPhone/] - # end - # end + # private + # def adjust_format_for_iphone + # request.format = :iphone if request.env["HTTP_USER_AGENT"][/iPhone/] + # end + # end # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#127 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#115 def format=(extension); end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#79 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#67 def formats; end - # Sets the \formats by string extensions. This differs from #format= by allowing you - # to set multiple, ordered formats, which is useful when you want to have a fallback. + # Sets the formats by string extensions. This differs from #format= by allowing + # you to set multiple, ordered formats, which is useful when you want to have a + # fallback. # - # In this example, the +:iphone+ format will be used if it's available, otherwise it'll fallback - # to the +:html+ format. + # In this example, the `:iphone` format will be used if it's available, + # otherwise it'll fall back to the `:html` format. # - # class ApplicationController < ActionController::Base - # before_action :adjust_format_for_iphone_with_html_fallback + # class ApplicationController < ActionController::Base + # before_action :adjust_format_for_iphone_with_html_fallback # - # private - # def adjust_format_for_iphone_with_html_fallback - # request.formats = [ :iphone, :html ] if request.env["HTTP_USER_AGENT"][/iPhone/] - # end - # end + # private + # def adjust_format_for_iphone_with_html_fallback + # request.formats = [ :iphone, :html ] if request.env["HTTP_USER_AGENT"][/iPhone/] + # end + # end # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#146 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#135 def formats=(extensions); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#49 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#37 def has_content_type?; end # Returns the first MIME type that matches the provided array of MIME types. # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#154 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#143 def negotiate_mime(order); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#166 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#155 def should_apply_vary_header?; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#112 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#100 def variant; end - # Sets the \variant for template. + # Sets the variant for template. # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#102 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#90 def variant=(variant); end private - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#190 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#179 def format_from_path_extension; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#175 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#164 def params_readable?; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#186 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#175 def use_accept_header; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#181 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#170 def valid_accept_header; end end -# We use normal content negotiation unless you include */* in your list, -# in which case we assume you're a browser and send HTML. +# We use normal content negotiation unless you include **/** in your list, in +# which case we assume you're a browser and send HTML. # -# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#173 +# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#162 ActionDispatch::Http::MimeNegotiation::BROWSER_LIKE_ACCEPTS = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#10 +# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#12 class ActionDispatch::Http::MimeNegotiation::InvalidType < ::Mime::Type::InvalidMimeType; end -# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#12 +# source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#14 ActionDispatch::Http::MimeNegotiation::RESCUABLE_MIME_FORMAT_ERRORS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/http/parameters.rb#5 +# source://actionpack//lib/action_dispatch/http/parameters.rb#7 module ActionDispatch::Http::Parameters extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionDispatch::Http::Parameters::ClassMethods - # Returns both GET and POST \parameters in a single hash. + # Returns both GET and POST parameters in a single hash. # - # source://actionpack//lib/action_dispatch/http/parameters.rb#50 + # source://actionpack//lib/action_dispatch/http/parameters.rb#52 def parameters; end - # Returns both GET and POST \parameters in a single hash. + # Returns both GET and POST parameters in a single hash. # - # source://actionpack//lib/action_dispatch/http/parameters.rb#50 + # source://actionpack//lib/action_dispatch/http/parameters.rb#52 def params; end - # Returns a hash with the \parameters used to form the \path of the request. - # Returned hash keys are strings: + # Returns a hash with the parameters used to form the path of the request. + # Returned hash keys are symbols: # - # { action: "my_action", controller: "my_controller" } + # { action: "my_action", controller: "my_controller" } # - # source://actionpack//lib/action_dispatch/http/parameters.rb#82 + # source://actionpack//lib/action_dispatch/http/parameters.rb#84 def path_parameters; end - # source://actionpack//lib/action_dispatch/http/parameters.rb#65 + # source://actionpack//lib/action_dispatch/http/parameters.rb#67 def path_parameters=(parameters); end private - # source://actionpack//lib/action_dispatch/http/parameters.rb#100 + # source://actionpack//lib/action_dispatch/http/parameters.rb#102 def log_parse_error_once; end - # source://actionpack//lib/action_dispatch/http/parameters.rb#112 + # source://actionpack//lib/action_dispatch/http/parameters.rb#114 def params_parsers; end - # source://actionpack//lib/action_dispatch/http/parameters.rb#87 + # source://actionpack//lib/action_dispatch/http/parameters.rb#89 def parse_formatted_parameters(parsers); end end -# source://actionpack//lib/action_dispatch/http/parameters.rb#34 +# source://actionpack//lib/action_dispatch/http/parameters.rb#36 module ActionDispatch::Http::Parameters::ClassMethods # Configure the parameter parser for a given MIME type. # - # It accepts a hash where the key is the symbol of the MIME type - # and the value is a proc. + # It accepts a hash where the key is the symbol of the MIME type and the value + # is a proc. # # original_parsers = ActionDispatch::Request.parameter_parsers # xml_parser = -> (raw_post) { Hash.from_xml(raw_post) || {} } # new_parsers = original_parsers.merge(xml: xml_parser) # ActionDispatch::Request.parameter_parsers = new_parsers # - # source://actionpack//lib/action_dispatch/http/parameters.rb#44 + # source://actionpack//lib/action_dispatch/http/parameters.rb#46 def parameter_parsers=(parsers); end end -# source://actionpack//lib/action_dispatch/http/parameters.rb#10 +# source://actionpack//lib/action_dispatch/http/parameters.rb#12 ActionDispatch::Http::Parameters::DEFAULT_PARSERS = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/parameters.rb#8 +# source://actionpack//lib/action_dispatch/http/parameters.rb#10 ActionDispatch::Http::Parameters::PARAMETERS_KEY = T.let(T.unsafe(nil), String) -# Raised when raw data from the request cannot be parsed by the parser -# defined for request's content MIME type. +# Raised when raw data from the request cannot be parsed by the parser defined +# for request's content MIME type. # -# source://actionpack//lib/action_dispatch/http/parameters.rb#19 +# source://actionpack//lib/action_dispatch/http/parameters.rb#21 class ActionDispatch::Http::Parameters::ParseError < ::StandardError # @return [ParseError] a new instance of ParseError # - # source://actionpack//lib/action_dispatch/http/parameters.rb#20 + # source://actionpack//lib/action_dispatch/http/parameters.rb#22 def initialize(message = T.unsafe(nil)); end end -# source://actionpack//lib/action_dispatch/http/url.rb#7 +# source://actionpack//lib/action_dispatch/http/url.rb#9 module ActionDispatch::Http::URL - # source://actionpack//lib/action_dispatch/http/url.rb#179 + # source://actionpack//lib/action_dispatch/http/url.rb#181 def initialize; end - # Returns the \domain part of a \host, such as "rubyonrails.org" in "www.rubyonrails.org". You can specify - # a different tld_length, such as 2 to catch rubyonrails.co.uk in "www.rubyonrails.co.uk". + # Returns the domain part of a host, such as "rubyonrails.org" in + # "www.rubyonrails.org". You can specify a different `tld_length`, such as 2 to + # catch rubyonrails.co.uk in "www.rubyonrails.co.uk". # - # source://actionpack//lib/action_dispatch/http/url.rb#321 + # source://actionpack//lib/action_dispatch/http/url.rb#324 def domain(tld_length = T.unsafe(nil)); end # Returns the host for this request, such as "example.com". # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.host # => "example.com" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.host # => "example.com" # - # source://actionpack//lib/action_dispatch/http/url.rb#226 + # source://actionpack//lib/action_dispatch/http/url.rb#228 def host; end - # Returns a \host:\port string for this request, such as "example.com" or - # "example.com:8080". Port is only included if it is not a default port - # (80 or 443) + # Returns a host:port string for this request, such as "example.com" or + # "example.com:8080". Port is only included if it is not a default port (80 or + # 443) # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' - # req.host_with_port # => "example.com" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' + # req.host_with_port # => "example.com" # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' - # req.host_with_port # => "example.com" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' + # req.host_with_port # => "example.com" # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.host_with_port # => "example.com:8080" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.host_with_port # => "example.com:8080" # - # source://actionpack//lib/action_dispatch/http/url.rb#242 + # source://actionpack//lib/action_dispatch/http/url.rb#244 def host_with_port; end - # Returns a number \port suffix like 8080 if the \port number of this request - # is not the default HTTP \port 80 or HTTPS \port 443. + # Returns a number port suffix like 8080 if the port number of this request is + # not the default HTTP port 80 or HTTPS port 443. # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' - # req.optional_port # => nil + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' + # req.optional_port # => nil # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.optional_port # => 8080 + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.optional_port # => 8080 # - # source://actionpack//lib/action_dispatch/http/url.rb#292 + # source://actionpack//lib/action_dispatch/http/url.rb#294 def optional_port; end # Returns the port number of this request as an integer. # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' - # req.port # => 80 + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' + # req.port # => 80 # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.port # => 8080 + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.port # => 8080 # - # source://actionpack//lib/action_dispatch/http/url.rb#253 + # source://actionpack//lib/action_dispatch/http/url.rb#255 def port; end - # Returns a string \port suffix, including colon, like ":8080" if the \port - # number of this request is not the default HTTP \port 80 or HTTPS \port 443. + # Returns a string port suffix, including colon, like ":8080" if the port number + # of this request is not the default HTTP port 80 or HTTPS port 443. # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' - # req.port_string # => "" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' + # req.port_string # => "" # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.port_string # => ":8080" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.port_string # => ":8080" # - # source://actionpack//lib/action_dispatch/http/url.rb#304 + # source://actionpack//lib/action_dispatch/http/url.rb#306 def port_string; end # Returns 'https://' if this is an SSL request and 'http://' otherwise. # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' - # req.protocol # => "http://" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' + # req.protocol # => "http://" # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com', 'HTTPS' => 'on' - # req.protocol # => "https://" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com', 'HTTPS' => 'on' + # req.protocol # => "https://" # - # source://actionpack//lib/action_dispatch/http/url.rb#200 + # source://actionpack//lib/action_dispatch/http/url.rb#202 def protocol; end - # Returns the \host and port for this request, such as "example.com:8080". + # Returns the host and port for this request, such as "example.com:8080". # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' - # req.raw_host_with_port # => "example.com" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' + # req.raw_host_with_port # => "example.com" # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' - # req.raw_host_with_port # => "example.com:80" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' + # req.raw_host_with_port # => "example.com:80" # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.raw_host_with_port # => "example.com:8080" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.raw_host_with_port # => "example.com:8080" # - # source://actionpack//lib/action_dispatch/http/url.rb#214 + # source://actionpack//lib/action_dispatch/http/url.rb#216 def raw_host_with_port; end - # source://actionpack//lib/action_dispatch/http/url.rb#12 + # source://actionpack//lib/action_dispatch/http/url.rb#14 def secure_protocol; end - # source://actionpack//lib/action_dispatch/http/url.rb#12 + # source://actionpack//lib/action_dispatch/http/url.rb#14 def secure_protocol=(val); end # Returns the requested port, such as 8080, based on SERVER_PORT # - # req = ActionDispatch::Request.new 'SERVER_PORT' => '80' - # req.server_port # => 80 + # req = ActionDispatch::Request.new 'SERVER_PORT' => '80' + # req.server_port # => 80 # - # req = ActionDispatch::Request.new 'SERVER_PORT' => '8080' - # req.server_port # => 8080 + # req = ActionDispatch::Request.new 'SERVER_PORT' => '8080' + # req.server_port # => 8080 # - # source://actionpack//lib/action_dispatch/http/url.rb#315 + # source://actionpack//lib/action_dispatch/http/url.rb#317 def server_port; end - # Returns the standard \port number for this request's protocol. + # Returns the standard port number for this request's protocol. # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.standard_port # => 80 + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.standard_port # => 80 # - # source://actionpack//lib/action_dispatch/http/url.rb#265 + # source://actionpack//lib/action_dispatch/http/url.rb#267 def standard_port; end # Returns whether this request is using the standard port # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' - # req.standard_port? # => true + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:80' + # req.standard_port? # => true # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' - # req.standard_port? # => false + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com:8080' + # req.standard_port? # => false # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/url.rb#280 + # source://actionpack//lib/action_dispatch/http/url.rb#282 def standard_port?; end - # Returns all the \subdomains as a string, so "dev.www" would be - # returned for "dev.www.rubyonrails.org". You can specify a different tld_length, - # such as 2 to catch "www" instead of "www.rubyonrails" - # in "www.rubyonrails.co.uk". + # Returns all the subdomains as a string, so `"dev.www"` would be returned for + # "dev.www.rubyonrails.org". You can specify a different `tld_length`, such as 2 + # to catch `"www"` instead of `"www.rubyonrails"` in "www.rubyonrails.co.uk". # - # source://actionpack//lib/action_dispatch/http/url.rb#337 + # source://actionpack//lib/action_dispatch/http/url.rb#339 def subdomain(tld_length = T.unsafe(nil)); end - # Returns all the \subdomains as an array, so ["dev", "www"] would be - # returned for "dev.www.rubyonrails.org". You can specify a different tld_length, - # such as 2 to catch ["www"] instead of ["www", "rubyonrails"] - # in "www.rubyonrails.co.uk". + # Returns all the subdomains as an array, so `["dev", "www"]` would be returned + # for "dev.www.rubyonrails.org". You can specify a different `tld_length`, such + # as 2 to catch `["www"]` instead of `["www", "rubyonrails"]` in + # "www.rubyonrails.co.uk". # - # source://actionpack//lib/action_dispatch/http/url.rb#329 + # source://actionpack//lib/action_dispatch/http/url.rb#332 def subdomains(tld_length = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/url.rb#13 + # source://actionpack//lib/action_dispatch/http/url.rb#15 def tld_length; end - # source://actionpack//lib/action_dispatch/http/url.rb#13 + # source://actionpack//lib/action_dispatch/http/url.rb#15 def tld_length=(val); end # Returns the complete URL used for this request. # - # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' - # req.url # => "http://example.com" + # req = ActionDispatch::Request.new 'HTTP_HOST' => 'example.com' + # req.url # => "http://example.com" # - # source://actionpack//lib/action_dispatch/http/url.rb#189 + # source://actionpack//lib/action_dispatch/http/url.rb#191 def url; end class << self # Returns the domain part of a host given the domain level. # - # # Top-level domain example - # extract_domain('www.example.com', 1) # => "example.com" - # # Second-level domain example - # extract_domain('dev.www.example.co.uk', 2) # => "example.co.uk" + # # Top-level domain example + # extract_domain('www.example.com', 1) # => "example.com" + # # Second-level domain example + # extract_domain('dev.www.example.co.uk', 2) # => "example.co.uk" # - # source://actionpack//lib/action_dispatch/http/url.rb#22 + # source://actionpack//lib/action_dispatch/http/url.rb#24 def extract_domain(host, tld_length); end # Returns the subdomains of a host as a String given the domain level. # - # # Top-level domain example - # extract_subdomain('www.example.com', 1) # => "www" - # # Second-level domain example - # extract_subdomain('dev.www.example.co.uk', 2) # => "dev.www" + # # Top-level domain example + # extract_subdomain('www.example.com', 1) # => "www" + # # Second-level domain example + # extract_subdomain('dev.www.example.co.uk', 2) # => "dev.www" # - # source://actionpack//lib/action_dispatch/http/url.rb#46 + # source://actionpack//lib/action_dispatch/http/url.rb#48 def extract_subdomain(host, tld_length); end # Returns the subdomains of a host as an Array given the domain level. # - # # Top-level domain example - # extract_subdomains('www.example.com', 1) # => ["www"] - # # Second-level domain example - # extract_subdomains('dev.www.example.co.uk', 2) # => ["dev", "www"] + # # Top-level domain example + # extract_subdomains('www.example.com', 1) # => ["www"] + # # Second-level domain example + # extract_subdomains('dev.www.example.co.uk', 2) # => ["dev", "www"] # - # source://actionpack//lib/action_dispatch/http/url.rb#32 + # source://actionpack//lib/action_dispatch/http/url.rb#34 def extract_subdomains(host, tld_length); end - # source://actionpack//lib/action_dispatch/http/url.rb#58 + # source://actionpack//lib/action_dispatch/http/url.rb#60 def full_url_for(options); end - # source://actionpack//lib/action_dispatch/http/url.rb#70 + # source://actionpack//lib/action_dispatch/http/url.rb#72 def path_for(options); end - # source://actionpack//lib/action_dispatch/http/url.rb#12 + # source://actionpack//lib/action_dispatch/http/url.rb#14 def secure_protocol; end - # source://actionpack//lib/action_dispatch/http/url.rb#12 + # source://actionpack//lib/action_dispatch/http/url.rb#14 def secure_protocol=(val); end - # source://actionpack//lib/action_dispatch/http/url.rb#13 + # source://actionpack//lib/action_dispatch/http/url.rb#15 def tld_length; end - # source://actionpack//lib/action_dispatch/http/url.rb#13 + # source://actionpack//lib/action_dispatch/http/url.rb#15 def tld_length=(val); end - # source://actionpack//lib/action_dispatch/http/url.rb#50 + # source://actionpack//lib/action_dispatch/http/url.rb#52 def url_for(options); end private - # source://actionpack//lib/action_dispatch/http/url.rb#90 + # source://actionpack//lib/action_dispatch/http/url.rb#92 def add_anchor(path, anchor); end - # source://actionpack//lib/action_dispatch/http/url.rb#83 + # source://actionpack//lib/action_dispatch/http/url.rb#85 def add_params(path, params); end - # source://actionpack//lib/action_dispatch/http/url.rb#105 + # source://actionpack//lib/action_dispatch/http/url.rb#107 def build_host_url(host, port, protocol, options, path); end - # source://actionpack//lib/action_dispatch/http/url.rb#96 + # source://actionpack//lib/action_dispatch/http/url.rb#98 def extract_domain_from(host, tld_length); end - # source://actionpack//lib/action_dispatch/http/url.rb#100 + # source://actionpack//lib/action_dispatch/http/url.rb#102 def extract_subdomains_from(host, tld_length); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/url.rb#129 + # source://actionpack//lib/action_dispatch/http/url.rb#131 def named_host?(host); end - # source://actionpack//lib/action_dispatch/http/url.rb#146 + # source://actionpack//lib/action_dispatch/http/url.rb#148 def normalize_host(_host, options); end - # source://actionpack//lib/action_dispatch/http/url.rb#166 + # source://actionpack//lib/action_dispatch/http/url.rb#168 def normalize_port(port, protocol); end - # source://actionpack//lib/action_dispatch/http/url.rb#133 + # source://actionpack//lib/action_dispatch/http/url.rb#135 def normalize_protocol(protocol); end end end -# source://actionpack//lib/action_dispatch/http/url.rb#9 +# source://actionpack//lib/action_dispatch/http/url.rb#11 ActionDispatch::Http::URL::HOST_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/url.rb#8 +# source://actionpack//lib/action_dispatch/http/url.rb#10 ActionDispatch::Http::URL::IP_HOST_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/url.rb#10 +# source://actionpack//lib/action_dispatch/http/url.rb#12 ActionDispatch::Http::URL::PROTOCOL_REGEXP = T.let(T.unsafe(nil), Regexp) +# # Action Dispatch HTTP UploadedFile +# # Models uploaded files. # -# The actual file is accessible via the +tempfile+ accessor, though some -# of its interface is available directly for convenience. +# The actual file is accessible via the `tempfile` accessor, though some of its +# interface is available directly for convenience. # -# Uploaded files are temporary files whose lifespan is one request. When -# the object is finalized Ruby unlinks the file, so there is no need to -# clean them with a separate maintenance task. +# Uploaded files are temporary files whose lifespan is one request. When the +# object is finalized Ruby unlinks the file, so there is no need to clean them +# with a separate maintenance task. # -# source://actionpack//lib/action_dispatch/http/upload.rb#13 +# source://actionpack//lib/action_dispatch/http/upload.rb#17 class ActionDispatch::Http::UploadedFile # @raise [ArgumentError] # @return [UploadedFile] a new instance of UploadedFile # - # source://actionpack//lib/action_dispatch/http/upload.rb#27 + # source://actionpack//lib/action_dispatch/http/upload.rb#31 def initialize(hash); end - # Shortcut for +tempfile.close+. + # Shortcut for `tempfile.close`. # - # source://actionpack//lib/action_dispatch/http/upload.rb#69 + # source://actionpack//lib/action_dispatch/http/upload.rb#73 def close(unlink_now = T.unsafe(nil)); end # A string with the MIME type of the file. # - # source://actionpack//lib/action_dispatch/http/upload.rb#18 + # source://actionpack//lib/action_dispatch/http/upload.rb#22 def content_type; end # A string with the MIME type of the file. # - # source://actionpack//lib/action_dispatch/http/upload.rb#18 + # source://actionpack//lib/action_dispatch/http/upload.rb#22 def content_type=(_arg0); end - # Shortcut for +tempfile.eof?+. + # Shortcut for `tempfile.eof?`. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/upload.rb#94 + # source://actionpack//lib/action_dispatch/http/upload.rb#98 def eof?; end # A string with the headers of the multipart request. # - # source://actionpack//lib/action_dispatch/http/upload.rb#25 + # source://actionpack//lib/action_dispatch/http/upload.rb#29 def headers; end # A string with the headers of the multipart request. # - # source://actionpack//lib/action_dispatch/http/upload.rb#25 + # source://actionpack//lib/action_dispatch/http/upload.rb#29 def headers=(_arg0); end - # Shortcut for +tempfile.open+. + # Shortcut for `tempfile.open`. # - # source://actionpack//lib/action_dispatch/http/upload.rb#64 + # source://actionpack//lib/action_dispatch/http/upload.rb#68 def open; end # The basename of the file in the client. # - # source://actionpack//lib/action_dispatch/http/upload.rb#15 + # source://actionpack//lib/action_dispatch/http/upload.rb#19 def original_filename; end # The basename of the file in the client. # - # source://actionpack//lib/action_dispatch/http/upload.rb#15 + # source://actionpack//lib/action_dispatch/http/upload.rb#19 def original_filename=(_arg0); end - # Shortcut for +tempfile.path+. + # Shortcut for `tempfile.path`. # - # source://actionpack//lib/action_dispatch/http/upload.rb#74 + # source://actionpack//lib/action_dispatch/http/upload.rb#78 def path; end - # Shortcut for +tempfile.read+. + # Shortcut for `tempfile.read`. # - # source://actionpack//lib/action_dispatch/http/upload.rb#59 + # source://actionpack//lib/action_dispatch/http/upload.rb#63 def read(length = T.unsafe(nil), buffer = T.unsafe(nil)); end - # Shortcut for +tempfile.rewind+. + # Shortcut for `tempfile.rewind`. # - # source://actionpack//lib/action_dispatch/http/upload.rb#84 + # source://actionpack//lib/action_dispatch/http/upload.rb#88 def rewind; end - # Shortcut for +tempfile.size+. + # Shortcut for `tempfile.size`. # - # source://actionpack//lib/action_dispatch/http/upload.rb#89 + # source://actionpack//lib/action_dispatch/http/upload.rb#93 def size; end - # A +Tempfile+ object with the actual uploaded file. Note that some of - # its interface is available directly. + # A `Tempfile` object with the actual uploaded file. Note that some of its + # interface is available directly. # - # source://actionpack//lib/action_dispatch/http/upload.rb#22 + # source://actionpack//lib/action_dispatch/http/upload.rb#26 def tempfile; end - # A +Tempfile+ object with the actual uploaded file. Note that some of - # its interface is available directly. + # A `Tempfile` object with the actual uploaded file. Note that some of its + # interface is available directly. # - # source://actionpack//lib/action_dispatch/http/upload.rb#22 + # source://actionpack//lib/action_dispatch/http/upload.rb#26 def tempfile=(_arg0); end - # source://actionpack//lib/action_dispatch/http/upload.rb#98 + # source://actionpack//lib/action_dispatch/http/upload.rb#102 def to_io; end - # Shortcut for +tempfile.to_path+. + # Shortcut for `tempfile.to_path`. # - # source://actionpack//lib/action_dispatch/http/upload.rb#79 + # source://actionpack//lib/action_dispatch/http/upload.rb#83 def to_path; end end -# source://actionpack//lib/action_dispatch.rb#40 -class ActionDispatch::IllegalStateError < ::StandardError; end - -# source://actionpack//lib/action_dispatch/testing/integration.rb#11 +# source://actionpack//lib/action_dispatch/testing/integration.rb#14 module ActionDispatch::Integration; end -# source://actionpack//lib/action_dispatch/testing/integration.rb#12 +# source://actionpack//lib/action_dispatch/testing/integration.rb#15 module ActionDispatch::Integration::RequestHelpers - # Performs a DELETE request with the given parameters. See ActionDispatch::Integration::Session#process - # for more details. + # Performs a DELETE request with the given parameters. See + # ActionDispatch::Integration::Session#process for more details. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#39 + # source://actionpack//lib/action_dispatch/testing/integration.rb#42 def delete(path, **args); end - # Follow a single redirect response. If the last response was not a - # redirect, an exception will be raised. Otherwise, the redirect is - # performed on the location header. If the redirection is a 307 or 308 redirect, - # the same HTTP verb will be used when redirecting, otherwise a GET request - # will be performed. Any arguments are passed to the - # underlying request. + # Follow a single redirect response. If the last response was not a redirect, an + # exception will be raised. Otherwise, the redirect is performed on the location + # header. If the redirection is a 307 or 308 redirect, the same HTTP verb will + # be used when redirecting, otherwise a GET request will be performed. Any + # arguments are passed to the underlying request. + # + # The HTTP_REFERER header will be set to the previous url. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#61 - def follow_redirect!(**args); end + # source://actionpack//lib/action_dispatch/testing/integration.rb#65 + def follow_redirect!(headers: T.unsafe(nil), **args); end - # Performs a GET request with the given parameters. See ActionDispatch::Integration::Session#process - # for more details. + # Performs a GET request with the given parameters. See + # ActionDispatch::Integration::Session#process for more details. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#15 + # source://actionpack//lib/action_dispatch/testing/integration.rb#18 def get(path, **args); end - # Performs a HEAD request with the given parameters. See ActionDispatch::Integration::Session#process - # for more details. + # Performs a HEAD request with the given parameters. See + # ActionDispatch::Integration::Session#process for more details. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#45 + # source://actionpack//lib/action_dispatch/testing/integration.rb#48 def head(path, **args); end - # Performs an OPTIONS request with the given parameters. See ActionDispatch::Integration::Session#process - # for more details. + # Performs an OPTIONS request with the given parameters. See + # ActionDispatch::Integration::Session#process for more details. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#51 + # source://actionpack//lib/action_dispatch/testing/integration.rb#54 def options(path, **args); end - # Performs a PATCH request with the given parameters. See ActionDispatch::Integration::Session#process - # for more details. + # Performs a PATCH request with the given parameters. See + # ActionDispatch::Integration::Session#process for more details. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#27 + # source://actionpack//lib/action_dispatch/testing/integration.rb#30 def patch(path, **args); end - # Performs a POST request with the given parameters. See ActionDispatch::Integration::Session#process - # for more details. + # Performs a POST request with the given parameters. See + # ActionDispatch::Integration::Session#process for more details. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#21 + # source://actionpack//lib/action_dispatch/testing/integration.rb#24 def post(path, **args); end - # Performs a PUT request with the given parameters. See ActionDispatch::Integration::Session#process - # for more details. + # Performs a PUT request with the given parameters. See + # ActionDispatch::Integration::Session#process for more details. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#33 + # source://actionpack//lib/action_dispatch/testing/integration.rb#36 def put(path, **args); end end -# source://actionpack//lib/action_dispatch/testing/integration.rb#316 +# source://actionpack//lib/action_dispatch/testing/integration.rb#324 module ActionDispatch::Integration::Runner - include ::ActionDispatch::Assertions::ResponseAssertions include ::ActionDispatch::Assertions::RoutingAssertions + include ::ActionDispatch::Assertions::ResponseAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions include ::ActionDispatch::Assertions + extend ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods - # source://actionpack//lib/action_dispatch/testing/integration.rb#324 + # source://actionpack//lib/action_dispatch/testing/integration.rb#332 def initialize(*args, &blk); end # Returns the value of attribute app. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#321 + # source://actionpack//lib/action_dispatch/testing/integration.rb#329 def app; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#395 + # source://actionpack//lib/action_dispatch/testing/integration.rb#402 def assertions; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#399 + # source://actionpack//lib/action_dispatch/testing/integration.rb#406 def assertions=(assertions); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def assigns(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#329 + # source://actionpack//lib/action_dispatch/testing/integration.rb#337 def before_setup; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def cookies(*_arg0, **_arg1, &_arg2); end - # Copy the instance variables from the current session instance into the - # test instance. + # Copy the instance variables from the current session instance into the test + # instance. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#405 + # source://actionpack//lib/action_dispatch/testing/integration.rb#412 def copy_session_variables!; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#344 + # source://actionpack//lib/action_dispatch/testing/integration.rb#352 def create_session(app); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#411 + # source://actionpack//lib/action_dispatch/testing/integration.rb#418 def default_url_options; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#415 + # source://actionpack//lib/action_dispatch/testing/integration.rb#422 def default_url_options=(options); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def delete(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def follow_redirect!(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def get(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def head(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#334 + # source://actionpack//lib/action_dispatch/testing/integration.rb#342 def integration_session; end - # Open a new session instance. If a block is given, the new session is - # yielded to the block before being returned. + # Open a new session instance. If a block is given, the new session is yielded + # to the block before being returned. # - # session = open_session do |sess| - # sess.extend(CustomAssertions) - # end + # session = open_session do |sess| + # sess.extend(CustomAssertions) + # end # - # By default, a single session is automatically created for you, but you - # can use this method to open multiple sessions that ought to be tested - # simultaneously. + # By default, a single session is automatically created for you, but you can use + # this method to open multiple sessions that ought to be tested simultaneously. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#387 + # source://actionpack//lib/action_dispatch/testing/integration.rb#394 def open_session; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def patch(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def post(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#367 + # source://actionpack//lib/action_dispatch/testing/integration.rb#375 def put(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#356 + # source://actionpack//lib/action_dispatch/testing/integration.rb#364 def remove!; end - # Reset the current session. This is useful for testing multiple sessions - # in a single test case. + # Reset the current session. This is useful for testing multiple sessions in a + # single test case. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#340 + # source://actionpack//lib/action_dispatch/testing/integration.rb#348 def reset!; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#322 + # source://actionpack//lib/action_dispatch/testing/integration.rb#330 def root_session; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#322 + # source://actionpack//lib/action_dispatch/testing/integration.rb#330 def root_session=(_arg0); end private # Delegate unhandled messages to the current session instance. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#425 - def method_missing(method, *args, **_arg2, &block); end + # source://actionpack//lib/action_dispatch/testing/integration.rb#432 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/testing/integration.rb#420 + # source://actionpack//lib/action_dispatch/testing/integration.rb#427 def respond_to_missing?(method, _); end end -# source://actionpack//lib/action_dispatch/testing/integration.rb#319 +# source://actionpack//lib/action_dispatch/testing/integration.rb#327 ActionDispatch::Integration::Runner::APP_SESSIONS = T.let(T.unsafe(nil), Hash) -# An instance of this class represents a set of requests and responses -# performed sequentially by a test process. Because you can instantiate -# multiple sessions and run them side-by-side, you can also mimic (to some -# limited extent) multiple simultaneous users interacting with your system. +# An instance of this class represents a set of requests and responses performed +# sequentially by a test process. Because you can instantiate multiple sessions +# and run them side-by-side, you can also mimic (to some limited extent) +# multiple simultaneous users interacting with your system. # -# Typically, you will instantiate a new session using -# IntegrationTest#open_session, rather than instantiating -# Integration::Session directly. +# Typically, you will instantiate a new session using Runner#open_session, +# rather than instantiating a Session directly. # -# source://actionpack//lib/action_dispatch/testing/integration.rb#84 +# source://actionpack//lib/action_dispatch/testing/integration.rb#91 class ActionDispatch::Integration::Session include ::Minitest::Assertions - include ::ActionDispatch::Assertions::ResponseAssertions include ::ActionDispatch::Assertions::RoutingAssertions + include ::ActionDispatch::Assertions::ResponseAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions include ::ActionDispatch::Assertions @@ -11171,563 +12154,571 @@ class ActionDispatch::Integration::Session include ::ActionDispatch::TestProcess include ::ActionDispatch::Routing::PolymorphicRoutes include ::ActionDispatch::Routing::UrlFor + extend ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods # Create and initialize a new Session instance. # # @return [Session] a new instance of Session # - # source://actionpack//lib/action_dispatch/testing/integration.rb#126 + # source://actionpack//lib/action_dispatch/testing/integration.rb#133 def initialize(app); end # The Accept header to send. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#103 + # source://actionpack//lib/action_dispatch/testing/integration.rb#110 def accept; end # The Accept header to send. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#103 + # source://actionpack//lib/action_dispatch/testing/integration.rb#110 def accept=(_arg0); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#90 + # source://actionpack//lib/action_dispatch/testing/integration.rb#97 def body(*_arg0, **_arg1, &_arg2); end # A reference to the controller instance used by the last request. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#112 + # source://actionpack//lib/action_dispatch/testing/integration.rb#119 def controller; end - # A map of the cookies returned by the last response, and which will be - # sent with the next request. + # A map of the cookies returned by the last response, and which will be sent + # with the next request. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#107 + # source://actionpack//lib/action_dispatch/testing/integration.rb#114 def cookies; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#90 + # source://actionpack//lib/action_dispatch/testing/integration.rb#97 def headers(*_arg0, **_arg1, &_arg2); end # The hostname used in the last request. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#94 + # source://actionpack//lib/action_dispatch/testing/integration.rb#101 def host; end # Sets the attribute host # Set the host name to use in the next request. # - # session.host! "www.example.com" + # session.host! "www.example.com" # # @param value the value to set the attribute host to. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#97 + # source://actionpack//lib/action_dispatch/testing/integration.rb#104 def host!(_arg0); end # Sets the attribute host # # @param value the value to set the attribute host to. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#97 + # source://actionpack//lib/action_dispatch/testing/integration.rb#104 def host=(_arg0); end # Specify whether or not the session should mimic a secure HTTPS request. # - # session.https! - # session.https!(false) + # session.https! + # session.https!(false) # - # source://actionpack//lib/action_dispatch/testing/integration.rb#174 + # source://actionpack//lib/action_dispatch/testing/integration.rb#180 def https!(flag = T.unsafe(nil)); end - # Returns +true+ if the session is mimicking a secure HTTPS request. + # Returns `true` if the session is mimicking a secure HTTPS request. # - # if session.https? - # ... - # end + # if session.https? + # ... + # end # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/testing/integration.rb#183 + # source://actionpack//lib/action_dispatch/testing/integration.rb#189 def https?; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#91 + # source://actionpack//lib/action_dispatch/testing/integration.rb#98 def path(*_arg0, **_arg1, &_arg2); end # Performs the actual request. # - # - +method+: The HTTP method (GET, POST, PATCH, PUT, DELETE, HEAD, OPTIONS) - # as a symbol. - # - +path+: The URI (as a String) on which you want to perform the - # request. - # - +params+: The HTTP parameters that you want to pass. This may - # be +nil+, - # a Hash, or a String that is appropriately encoded - # (application/x-www-form-urlencoded or - # multipart/form-data). - # - +headers+: Additional headers to pass, as a Hash. The headers will be - # merged into the Rack env hash. - # - +env+: Additional env to pass, as a Hash. The headers will be - # merged into the Rack env hash. - # - +xhr+: Set to +true+ if you want to make an Ajax request. - # Adds request headers characteristic of XMLHttpRequest e.g. HTTP_X_REQUESTED_WITH. - # The headers will be merged into the Rack env hash. - # - +as+: Used for encoding the request with different content type. - # Supports +:json+ by default and will set the appropriate request headers. - # The headers will be merged into the Rack env hash. - # - # This method is rarely used directly. Use +#get+, +#post+, or other standard - # HTTP methods in integration tests. +#process+ is only required when using a - # request method that doesn't have a method defined in the integration tests. + # * `method`: The HTTP method (GET, POST, PATCH, PUT, DELETE, HEAD, OPTIONS) + # as a symbol. + # * `path`: The URI (as a String) on which you want to perform the request. + # * `params`: The HTTP parameters that you want to pass. This may be `nil`, a + # Hash, or a String that is appropriately encoded + # (`application/x-www-form-urlencoded` or `multipart/form-data`). + # * `headers`: Additional headers to pass, as a Hash. The headers will be + # merged into the Rack env hash. + # * `env`: Additional env to pass, as a Hash. The headers will be merged into + # the Rack env hash. + # * `xhr`: Set to `true` if you want to make an Ajax request. Adds request + # headers characteristic of XMLHttpRequest e.g. HTTP_X_REQUESTED_WITH. The + # headers will be merged into the Rack env hash. + # * `as`: Used for encoding the request with different content type. Supports + # `:json` by default and will set the appropriate request headers. The + # headers will be merged into the Rack env hash. + # + # + # This method is rarely used directly. Use RequestHelpers#get, + # RequestHelpers#post, or other standard HTTP methods in integration tests. + # `#process` is only required when using a request method that doesn't have a + # method defined in the integration tests. # # This method returns the response status, after performing the request. - # Furthermore, if this method was called from an ActionDispatch::IntegrationTest object, - # then that object's @response instance variable will point to a Response object - # which one can use to inspect the details of the response. + # Furthermore, if this method was called from an ActionDispatch::IntegrationTest + # object, then that object's `@response` instance variable will point to a + # Response object which one can use to inspect the details of the response. # # Example: - # process :get, '/author', params: { since: 201501011400 } + # process :get, '/author', params: { since: 201501011400 } # - # source://actionpack//lib/action_dispatch/testing/integration.rb#220 + # source://actionpack//lib/action_dispatch/testing/integration.rb#225 def process(method, path, params: T.unsafe(nil), headers: T.unsafe(nil), env: T.unsafe(nil), xhr: T.unsafe(nil), as: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#90 + # source://actionpack//lib/action_dispatch/testing/integration.rb#97 def redirect?(*_arg0, **_arg1, &_arg2); end # The remote_addr used in the last request. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#100 + # source://actionpack//lib/action_dispatch/testing/integration.rb#107 def remote_addr; end # The remote_addr used in the last request. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#100 + # source://actionpack//lib/action_dispatch/testing/integration.rb#107 def remote_addr=(_arg0); end # A reference to the request instance used by the last request. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#115 + # source://actionpack//lib/action_dispatch/testing/integration.rb#122 def request; end # A running counter of the number of requests processed. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#121 + # source://actionpack//lib/action_dispatch/testing/integration.rb#128 def request_count; end # A running counter of the number of requests processed. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#121 + # source://actionpack//lib/action_dispatch/testing/integration.rb#128 def request_count=(_arg0); end - # Resets the instance. This can be used to reset the state information - # in an existing session instance, so it can be used from a clean-slate - # condition. + # Resets the instance. This can be used to reset the state information in an + # existing session instance, so it can be used from a clean-slate condition. # - # session.reset! + # session.reset! # - # source://actionpack//lib/action_dispatch/testing/integration.rb#150 + # source://actionpack//lib/action_dispatch/testing/integration.rb#156 def reset!; end # A reference to the response instance used by the last request. # - # source://actionpack//lib/action_dispatch/testing/integration.rb#118 + # source://actionpack//lib/action_dispatch/testing/integration.rb#125 def response; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#90 + # source://actionpack//lib/action_dispatch/testing/integration.rb#97 def status(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#90 + # source://actionpack//lib/action_dispatch/testing/integration.rb#97 def status_message(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#133 + # source://actionpack//lib/action_dispatch/testing/integration.rb#140 def url_options; end private - # source://actionpack//lib/action_dispatch/testing/integration.rb#300 + # source://actionpack//lib/action_dispatch/testing/integration.rb#308 def _mock_session; end # @yield [location] # - # source://actionpack//lib/action_dispatch/testing/integration.rb#308 + # source://actionpack//lib/action_dispatch/testing/integration.rb#316 def build_expanded_path(path); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#304 + # source://actionpack//lib/action_dispatch/testing/integration.rb#312 def build_full_uri(path, env); end class << self - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end end end -# source://actionpack//lib/action_dispatch/testing/integration.rb#85 +# source://actionpack//lib/action_dispatch/testing/integration.rb#92 ActionDispatch::Integration::Session::DEFAULT_HOST = T.let(T.unsafe(nil), String) -# An integration test spans multiple controllers and actions, -# tying them all together to ensure they work together as expected. It tests -# more completely than either unit or functional tests do, exercising the -# entire stack, from the dispatcher to the database. +# An integration test spans multiple controllers and actions, tying them all +# together to ensure they work together as expected. It tests more completely +# than either unit or functional tests do, exercising the entire stack, from the +# dispatcher to the database. # -# At its simplest, you simply extend IntegrationTest and write your tests -# using the get/post methods: +# At its simplest, you simply extend `IntegrationTest` and write your tests +# using the Integration::RequestHelpers#get and/or +# Integration::RequestHelpers#post methods: # -# require "test_helper" +# require "test_helper" # -# class ExampleTest < ActionDispatch::IntegrationTest -# fixtures :people +# class ExampleTest < ActionDispatch::IntegrationTest +# fixtures :people # -# def test_login -# # get the login page -# get "/login" -# assert_equal 200, status +# def test_login +# # get the login page +# get "/login" +# assert_equal 200, status # -# # post the login and follow through to the home page -# post "/login", params: { username: people(:jamis).username, -# password: people(:jamis).password } -# follow_redirect! -# assert_equal 200, status -# assert_equal "/home", path +# # post the login and follow through to the home page +# post "/login", params: { username: people(:jamis).username, +# password: people(:jamis).password } +# follow_redirect! +# assert_equal 200, status +# assert_equal "/home", path +# end # end -# end # -# However, you can also have multiple session instances open per test, and -# even extend those instances with assertions and methods to create a very -# powerful testing DSL that is specific for your application. You can even -# reference any named routes you happen to have defined. +# However, you can also have multiple session instances open per test, and even +# extend those instances with assertions and methods to create a very powerful +# testing DSL that is specific for your application. You can even reference any +# named routes you happen to have defined. # -# require "test_helper" +# require "test_helper" # -# class AdvancedTest < ActionDispatch::IntegrationTest -# fixtures :people, :rooms +# class AdvancedTest < ActionDispatch::IntegrationTest +# fixtures :people, :rooms # -# def test_login_and_speak -# jamis, david = login(:jamis), login(:david) -# room = rooms(:office) +# def test_login_and_speak +# jamis, david = login(:jamis), login(:david) +# room = rooms(:office) # -# jamis.enter(room) -# jamis.speak(room, "anybody home?") +# jamis.enter(room) +# jamis.speak(room, "anybody home?") # -# david.enter(room) -# david.speak(room, "hello!") -# end +# david.enter(room) +# david.speak(room, "hello!") +# end # -# private +# private # -# module CustomAssertions -# def enter(room) -# # reference a named route, for maximum internal consistency! -# get(room_url(id: room.id)) -# assert(...) -# ... -# end +# module CustomAssertions +# def enter(room) +# # reference a named route, for maximum internal consistency! +# get(room_url(id: room.id)) +# assert(...) +# ... +# end # -# def speak(room, message) -# post "/say/#{room.id}", xhr: true, params: { message: message } -# assert(...) -# ... +# def speak(room, message) +# post "/say/#{room.id}", xhr: true, params: { message: message } +# assert(...) +# ... +# end # end -# end # -# def login(who) -# open_session do |sess| -# sess.extend(CustomAssertions) -# who = people(who) -# sess.post "/login", params: { username: who.username, -# password: who.password } -# assert(...) +# def login(who) +# open_session do |sess| +# sess.extend(CustomAssertions) +# who = people(who) +# sess.post "/login", params: { username: who.username, +# password: who.password } +# assert(...) +# end # end -# end -# end +# end # # Another longer example would be: # # A simple integration test that exercises multiple controllers: # -# require "test_helper" +# require "test_helper" # -# class UserFlowsTest < ActionDispatch::IntegrationTest -# test "login and browse site" do -# # login via https -# https! -# get "/login" -# assert_response :success +# class UserFlowsTest < ActionDispatch::IntegrationTest +# test "login and browse site" do +# # login via https +# https! +# get "/login" +# assert_response :success # -# post "/login", params: { username: users(:david).username, password: users(:david).password } -# follow_redirect! -# assert_equal '/welcome', path -# assert_equal 'Welcome david!', flash[:notice] +# post "/login", params: { username: users(:david).username, password: users(:david).password } +# follow_redirect! +# assert_equal '/welcome', path +# assert_equal 'Welcome david!', flash[:notice] # -# https!(false) -# get "/articles/all" -# assert_response :success -# assert_select 'h1', 'Articles' +# https!(false) +# get "/articles/all" +# assert_response :success +# assert_select 'h1', 'Articles' +# end # end -# end # # As you can see the integration test involves multiple controllers and # exercises the entire stack from database to dispatcher. In addition you can -# have multiple session instances open simultaneously in a test and extend -# those instances with assertion methods to create a very powerful testing -# DSL (domain-specific language) just for your application. +# have multiple session instances open simultaneously in a test and extend those +# instances with assertion methods to create a very powerful testing DSL +# (domain-specific language) just for your application. # # Here's an example of multiple sessions and custom DSL in an integration test # -# require "test_helper" +# require "test_helper" # -# class UserFlowsTest < ActionDispatch::IntegrationTest -# test "login and browse site" do -# # User david logs in -# david = login(:david) -# # User guest logs in -# guest = login(:guest) +# class UserFlowsTest < ActionDispatch::IntegrationTest +# test "login and browse site" do +# # User david logs in +# david = login(:david) +# # User guest logs in +# guest = login(:guest) # -# # Both are now available in different sessions -# assert_equal 'Welcome david!', david.flash[:notice] -# assert_equal 'Welcome guest!', guest.flash[:notice] +# # Both are now available in different sessions +# assert_equal 'Welcome david!', david.flash[:notice] +# assert_equal 'Welcome guest!', guest.flash[:notice] # -# # User david can browse site -# david.browses_site -# # User guest can browse site as well -# guest.browses_site +# # User david can browse site +# david.browses_site +# # User guest can browse site as well +# guest.browses_site # -# # Continue with other assertions -# end +# # Continue with other assertions +# end # -# private +# private # -# module CustomDsl -# def browses_site -# get "/products/all" -# assert_response :success -# assert_select 'h1', 'Products' +# module CustomDsl +# def browses_site +# get "/products/all" +# assert_response :success +# assert_select 'h1', 'Products' +# end # end -# end # -# def login(user) -# open_session do |sess| -# sess.extend(CustomDsl) -# u = users(user) -# sess.https! -# sess.post "/login", params: { username: u.username, password: u.password } -# assert_equal '/welcome', sess.path -# sess.https!(false) +# def login(user) +# open_session do |sess| +# sess.extend(CustomDsl) +# u = users(user) +# sess.https! +# sess.post "/login", params: { username: u.username, password: u.password } +# assert_equal '/welcome', sess.path +# sess.https!(false) +# end # end -# end -# end +# end # -# See the {request helpers documentation}[rdoc-ref:ActionDispatch::Integration::RequestHelpers] for help on how to -# use +get+, etc. +# See the [request helpers documentation] +# (rdoc-ref:ActionDispatch::Integration::RequestHelpers) for help +# on how to use `get`, etc. # -# === Changing the request encoding +# ### Changing the request encoding # -# You can also test your JSON API easily by setting what the request should -# be encoded as: +# You can also test your JSON API easily by setting what the request should be +# encoded as: # -# require "test_helper" +# require "test_helper" # -# class ApiTest < ActionDispatch::IntegrationTest -# test "creates articles" do -# assert_difference -> { Article.count } do -# post articles_path, params: { article: { title: "Ahoy!" } }, as: :json -# end +# class ApiTest < ActionDispatch::IntegrationTest +# test "creates articles" do +# assert_difference -> { Article.count } do +# post articles_path, params: { article: { title: "Ahoy!" } }, as: :json +# end # -# assert_response :success -# assert_equal({ id: Article.last.id, title: "Ahoy!" }, response.parsed_body) +# assert_response :success +# assert_equal({ id: Article.last.id, title: "Ahoy!" }, response.parsed_body) +# end # end -# end # -# The +as+ option passes an "application/json" Accept header (thereby setting +# The `as` option passes an "application/json" Accept header (thereby setting # the request format to JSON unless overridden), sets the content type to # "application/json" and encodes the parameters as JSON. # -# Calling +parsed_body+ on the response parses the response body based on the -# last response MIME type. +# Calling TestResponse#parsed_body on the response parses the response body +# based on the last response MIME type. # -# Out of the box, only :json is supported. But for any custom MIME -# types you've registered, you can add your own encoders with: +# Out of the box, only `:json` is supported. But for any custom MIME types +# you've registered, you can add your own encoders with: # -# ActionDispatch::IntegrationTest.register_encoder :wibble, -# param_encoder: -> params { params.to_wibble }, -# response_parser: -> body { body } +# ActionDispatch::IntegrationTest.register_encoder :wibble, +# param_encoder: -> params { params.to_wibble }, +# response_parser: -> body { body } # -# Where +param_encoder+ defines how the params should be encoded and -# +response_parser+ defines how the response body should be parsed through -# +parsed_body+. +# Where `param_encoder` defines how the params should be encoded and +# `response_parser` defines how the response body should be parsed through +# TestResponse#parsed_body. # -# Consult the Rails Testing Guide for more. +# Consult the [Rails Testing Guide](https://guides.rubyonrails.org/testing.html) +# for more. # -# source://actionpack//lib/action_dispatch/testing/integration.rb#631 +# source://actionpack//lib/action_dispatch/testing/integration.rb#640 class ActionDispatch::IntegrationTest < ::ActiveSupport::TestCase include ::ActionDispatch::TestProcess::FixtureFile - include ::ActionDispatch::Assertions::ResponseAssertions include ::ActionDispatch::Assertions::RoutingAssertions + include ::ActionDispatch::Assertions::ResponseAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions include ::ActionDispatch::Assertions include ::ActionDispatch::Integration::Runner include ::ActionController::TemplateAssertions + include ::ActionDispatch::TestHelpers::PageDumpHelper include ::ActionDispatch::IntegrationTest::Behavior include ::ActionDispatch::Routing::PolymorphicRoutes include ::ActionDispatch::Routing::UrlFor include ::ActionDispatch::IntegrationTest::UrlOptions + include ::ActionDispatch::Assertions::RoutingAssertions::WithIntegrationRouting + include ::Turbo::TestAssertions::IntegrationTestAssertions extend ::ActionDispatch::IntegrationTest::Behavior::ClassMethods + extend ::ActionDispatch::Assertions::RoutingAssertions::WithIntegrationRouting::ClassMethods end -# source://actionpack//lib/action_dispatch/testing/integration.rb#641 +# source://actionpack//lib/action_dispatch/testing/integration.rb#650 module ActionDispatch::IntegrationTest::Behavior - include ::ActionDispatch::Assertions::ResponseAssertions include ::ActionDispatch::Assertions::RoutingAssertions + include ::ActionDispatch::Assertions::ResponseAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions include ::ActionDispatch::Assertions include ::ActionDispatch::Integration::Runner include ::ActionController::TemplateAssertions + include ::ActionDispatch::TestHelpers::PageDumpHelper extend ::ActiveSupport::Concern include ::ActionDispatch::Routing::UrlFor include ::ActionDispatch::IntegrationTest::UrlOptions + include ::ActionDispatch::Assertions::RoutingAssertions::WithIntegrationRouting + include ::Turbo::TestAssertions::IntegrationTestAssertions mixes_in_class_methods ::ActionDispatch::IntegrationTest::Behavior::ClassMethods + mixes_in_class_methods ::ActionDispatch::Assertions::RoutingAssertions::WithIntegrationRouting::ClassMethods - # source://actionpack//lib/action_dispatch/testing/integration.rb#672 + # source://actionpack//lib/action_dispatch/testing/integration.rb#683 def app; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#676 + # source://actionpack//lib/action_dispatch/testing/integration.rb#687 def document_root_element; end end -# source://actionpack//lib/action_dispatch/testing/integration.rb#654 +# source://actionpack//lib/action_dispatch/testing/integration.rb#665 module ActionDispatch::IntegrationTest::Behavior::ClassMethods - # source://actionpack//lib/action_dispatch/testing/integration.rb#655 + # source://actionpack//lib/action_dispatch/testing/integration.rb#666 def app; end - # source://actionpack//lib/action_dispatch/testing/integration.rb#663 + # source://actionpack//lib/action_dispatch/testing/integration.rb#674 def app=(app); end - # source://actionpack//lib/action_dispatch/testing/integration.rb#667 + # source://actionpack//lib/action_dispatch/testing/integration.rb#678 def register_encoder(*args, **options); end end -# source://actionpack//lib/action_dispatch/testing/integration.rb#634 +# source://actionpack//lib/action_dispatch/testing/integration.rb#643 module ActionDispatch::IntegrationTest::UrlOptions extend ::ActiveSupport::Concern - # source://actionpack//lib/action_dispatch/testing/integration.rb#636 + # source://actionpack//lib/action_dispatch/testing/integration.rb#645 def url_options; end end # :stopdoc: # -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#4 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#6 module ActionDispatch::Journey; end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#7 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#9 class ActionDispatch::Journey::Ast # @return [Ast] a new instance of Ast # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#11 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#13 def initialize(tree, formatted); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#37 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#38 def glob?; end # Returns the value of attribute names. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#8 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#10 def names; end # Returns the value of attribute path_params. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#8 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#10 def path_params; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#23 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#25 def requirements=(requirements); end # Returns the value of attribute tree. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#8 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#10 def root; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#33 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#34 def route=(route); end # Returns the value of attribute terminals. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#8 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#10 def terminals; end # Returns the value of attribute tree. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#8 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#10 def tree; end # Returns the value of attribute wildcard_options. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#8 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#10 def wildcard_options; end private # Returns the value of attribute stars. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#42 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#43 def stars; end # Returns the value of attribute symbols. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#42 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#43 def symbols; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#44 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#45 def visit_tree(formatted); end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#6 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#8 class ActionDispatch::Journey::Format # @return [Format] a new instance of Format # - # source://actionpack//lib/action_dispatch/journey/visitors.rb#22 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#24 def initialize(parts); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#37 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#39 def evaluate(hash); end class << self - # source://actionpack//lib/action_dispatch/journey/visitors.rb#14 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#16 def required_path(symbol); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#18 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#20 def required_segment(symbol); end end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#7 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#9 ActionDispatch::Journey::Format::ESCAPE_PATH = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_dispatch/journey/visitors.rb#8 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#10 ActionDispatch::Journey::Format::ESCAPE_SEGMENT = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_dispatch/journey/visitors.rb#10 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#12 class ActionDispatch::Journey::Format::Parameter < ::Struct - # source://actionpack//lib/action_dispatch/journey/visitors.rb#11 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#13 def escape(value); end # Returns the value of attribute escaper @@ -11762,1516 +12753,1540 @@ class ActionDispatch::Journey::Format::Parameter < ::Struct end # The Formatter class is used for formatting URLs. For example, parameters -# passed to +url_for+ in Rails will eventually call Formatter#generate. +# passed to `url_for` in Rails will eventually call Formatter#generate. # -# source://actionpack//lib/action_dispatch/journey/formatter.rb#10 +# source://actionpack//lib/action_dispatch/journey/formatter.rb#12 class ActionDispatch::Journey::Formatter # @return [Formatter] a new instance of Formatter # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#13 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#15 def initialize(routes); end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#97 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#105 def clear; end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#59 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#109 + def eager_load!; end + + # source://actionpack//lib/action_dispatch/journey/formatter.rb#61 def generate(name, options, path_parameters); end # Returns the value of attribute routes. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#11 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#13 def routes; end private - # source://actionpack//lib/action_dispatch/journey/formatter.rb#196 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#209 def build_cache; end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#207 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#220 def cache; end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#102 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#115 def extract_parameterized_parts(route, options, recall); end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#129 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#142 def match_route(name, options); end # Returns an array populated with missing keys if any are present. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#168 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#181 def missing_keys(route, parts); end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#125 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#138 def named_routes; end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#151 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#164 def non_recursive(cache, options); end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#188 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#201 def possibles(cache, options, depth = T.unsafe(nil)); end end -# source://actionpack//lib/action_dispatch/journey/formatter.rb#32 +# source://actionpack//lib/action_dispatch/journey/formatter.rb#34 class ActionDispatch::Journey::Formatter::MissingRoute # @return [MissingRoute] a new instance of MissingRoute # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#35 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#37 def initialize(constraints, missing_keys, unmatched_keys, routes, name); end # Returns the value of attribute constraints. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#33 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#35 def constraints; end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#51 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#53 def message; end # Returns the value of attribute missing_keys. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#33 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#35 def missing_keys; end # Returns the value of attribute name. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#33 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#35 def name; end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#47 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#49 def params; end # @raise [ActionController::UrlGenerationError] # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#43 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#45 def path(method_name); end # Returns the value of attribute routes. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#33 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#35 def routes; end # Returns the value of attribute unmatched_keys. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#33 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#35 def unmatched_keys; end end -# source://actionpack//lib/action_dispatch/journey/formatter.rb#18 +# source://actionpack//lib/action_dispatch/journey/formatter.rb#20 class ActionDispatch::Journey::Formatter::RouteWithParams # @return [RouteWithParams] a new instance of RouteWithParams # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#21 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#23 def initialize(route, parameterized_parts, params); end # Returns the value of attribute params. # - # source://actionpack//lib/action_dispatch/journey/formatter.rb#19 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#21 def params; end - # source://actionpack//lib/action_dispatch/journey/formatter.rb#27 + # source://actionpack//lib/action_dispatch/journey/formatter.rb#29 def path(_); end end -# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#7 +# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#9 module ActionDispatch::Journey::GTG; end -# source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#8 +# source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#10 class ActionDispatch::Journey::GTG::Builder # @return [Builder] a new instance of Builder # - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#13 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#15 def initialize(root); end # Returns the value of attribute ast. # - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#11 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#13 def ast; end # Returns the value of attribute endpoints. # - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#11 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#13 def endpoints; end - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#86 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#87 def firstpos(node); end - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#107 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#108 def lastpos(node); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#64 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#66 def nullable?(node); end # Returns the value of attribute root. # - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#11 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#13 def root; end - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#19 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#21 def transition_table; end private - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#129 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#130 def build_followpos; end - # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#142 + # source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#143 def symbol(edge); end end -# source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#9 +# source://actionpack//lib/action_dispatch/journey/gtg/builder.rb#11 ActionDispatch::Journey::GTG::Builder::DUMMY_END_NODE = T.let(T.unsafe(nil), ActionDispatch::Journey::Nodes::Dummy) -# source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#8 +# source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#10 class ActionDispatch::Journey::GTG::MatchData # @return [MatchData] a new instance of MatchData # - # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#11 + # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#13 def initialize(memos); end # Returns the value of attribute memos. # - # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#9 + # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#11 def memos; end end -# source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#16 +# source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#18 class ActionDispatch::Journey::GTG::Simulator # @return [Simulator] a new instance of Simulator # - # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#21 + # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#23 def initialize(transition_table); end - # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#25 + # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#27 def memos(string); end # Returns the value of attribute tt. # - # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#19 + # source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#21 def tt; end end -# source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#17 +# source://actionpack//lib/action_dispatch/journey/gtg/simulator.rb#19 ActionDispatch::Journey::GTG::Simulator::INITIAL_STATE = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#8 +# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#10 class ActionDispatch::Journey::GTG::TransitionTable include ::ActionDispatch::Journey::NFA::Dot # @return [TransitionTable] a new instance of TransitionTable # - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#16 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#18 def initialize; end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#163 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#165 def []=(from, to, sym); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#32 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#34 def accepting?(state); end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#28 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#30 def accepting_states; end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#24 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#26 def add_accepting(state); end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#36 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#38 def add_memo(idx, memo); end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#98 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#100 def as_json(options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#44 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#46 def eclosure(t); end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#40 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#42 def memo(idx); end # Returns the value of attribute memos. # - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#11 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#13 def memos; end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#48 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#50 def move(t, full_string, start_index, end_index); end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#180 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#182 def states; end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#115 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#117 def to_svg; end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#187 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#189 def transitions; end - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#125 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#127 def visualizer(paths, title = T.unsafe(nil)); end private - # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#198 + # source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#200 def states_hash_for(sym); end end -# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#13 +# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#15 ActionDispatch::Journey::GTG::TransitionTable::DEFAULT_EXP = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#14 +# source://actionpack//lib/action_dispatch/journey/gtg/transition_table.rb#16 ActionDispatch::Journey::GTG::TransitionTable::DEFAULT_EXP_ANCHORED = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/nfa/dot.rb#5 +# source://actionpack//lib/action_dispatch/journey/nfa/dot.rb#7 module ActionDispatch::Journey::NFA; end -# source://actionpack//lib/action_dispatch/journey/nfa/dot.rb#6 +# source://actionpack//lib/action_dispatch/journey/nfa/dot.rb#8 module ActionDispatch::Journey::NFA::Dot - # source://actionpack//lib/action_dispatch/journey/nfa/dot.rb#7 + # source://actionpack//lib/action_dispatch/journey/nfa/dot.rb#9 def to_dot; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#67 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#68 module ActionDispatch::Journey::Nodes; end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#180 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#181 class ActionDispatch::Journey::Nodes::Binary < ::ActionDispatch::Journey::Nodes::Node # @return [Binary] a new instance of Binary # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#183 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#184 def initialize(left, right); end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#188 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#189 def children; end # Returns the value of attribute right. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#181 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#182 def right; end # Sets the attribute right # # @param value the value to set the attribute right to. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#181 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#182 def right=(_arg0); end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#191 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#192 class ActionDispatch::Journey::Nodes::Cat < ::ActionDispatch::Journey::Nodes::Binary # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#192 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#193 def cat?; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#193 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#194 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#132 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#133 class ActionDispatch::Journey::Nodes::Dot < ::ActionDispatch::Journey::Nodes::Terminal - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#133 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#134 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#120 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#121 class ActionDispatch::Journey::Nodes::Dummy < ::ActionDispatch::Journey::Nodes::Literal # @return [Dummy] a new instance of Dummy # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#121 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#122 def initialize(x = T.unsafe(nil)); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#125 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#126 def literal?; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#157 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#158 class ActionDispatch::Journey::Nodes::Group < ::ActionDispatch::Journey::Nodes::Unary # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#159 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#160 def group?; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#158 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#159 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#115 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#116 class ActionDispatch::Journey::Nodes::Literal < ::ActionDispatch::Journey::Nodes::Terminal # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#116 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#117 def literal?; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#117 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#118 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#68 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#69 class ActionDispatch::Journey::Nodes::Node include ::Enumerable # @return [Node] a new instance of Node # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#73 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#74 def initialize(left); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#106 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#107 def cat?; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#78 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#79 def each(&block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#107 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#108 def group?; end # Returns the value of attribute left. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#71 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#72 def left; end # Sets the attribute left # # @param value the value to set the attribute left to. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#71 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#72 def left=(_arg0); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#103 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#104 def literal?; end # Returns the value of attribute memo. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#71 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#72 def memo; end # Sets the attribute memo # # @param value the value to set the attribute memo to. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#71 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#72 def memo=(_arg0); end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#94 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#95 def name; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#105 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#106 def star?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#102 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#103 def symbol?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#104 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#105 def terminal?; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#86 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#87 def to_dot; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#82 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#83 def to_s; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#90 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#91 def to_sym; end # @raise [NotImplementedError] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#98 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#99 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#196 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#197 class ActionDispatch::Journey::Nodes::Or < ::ActionDispatch::Journey::Nodes::Node # @return [Or] a new instance of Or # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#199 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#200 def initialize(children); end # Returns the value of attribute children. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#197 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#198 def children; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#203 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#204 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#128 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#129 class ActionDispatch::Journey::Nodes::Slash < ::ActionDispatch::Journey::Nodes::Terminal - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#129 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#130 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#162 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#163 class ActionDispatch::Journey::Nodes::Star < ::ActionDispatch::Journey::Nodes::Unary # @return [Star] a new instance of Star # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#165 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#166 def initialize(left); end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#175 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#176 def name; end # Returns the value of attribute regexp. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#163 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#164 def regexp; end # Sets the attribute regexp # # @param value the value to set the attribute regexp to. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#163 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#164 def regexp=(_arg0); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#172 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#173 def star?; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#173 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#174 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#136 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#137 class ActionDispatch::Journey::Nodes::Symbol < ::ActionDispatch::Journey::Nodes::Terminal # @return [Symbol] a new instance of Symbol # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#143 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#144 def initialize(left, regexp = T.unsafe(nil)); end # Returns the value of attribute name. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#139 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#140 def name; end # Returns the value of attribute regexp. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#137 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#138 def regexp; end # Sets the attribute regexp # # @param value the value to set the attribute regexp to. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#137 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#138 def regexp=(_arg0); end # Returns the value of attribute regexp. # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#137 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#138 def symbol; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#150 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#151 def symbol?; end - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#149 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#150 def type; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#141 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#142 ActionDispatch::Journey::Nodes::Symbol::DEFAULT_EXP = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#142 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#143 ActionDispatch::Journey::Nodes::Symbol::GREEDY_EXP = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#110 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#111 class ActionDispatch::Journey::Nodes::Terminal < ::ActionDispatch::Journey::Nodes::Node - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#71 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#72 def symbol; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#112 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#113 def terminal?; end end -# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#153 +# source://actionpack//lib/action_dispatch/journey/nodes/node.rb#154 class ActionDispatch::Journey::Nodes::Unary < ::ActionDispatch::Journey::Nodes::Node - # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#154 + # source://actionpack//lib/action_dispatch/journey/nodes/node.rb#155 def children; end end -# source://actionpack//lib/action_dispatch/journey/parser_extras.rb#9 +# source://actionpack//lib/action_dispatch/journey/parser_extras.rb#11 class ActionDispatch::Journey::Parser < ::Racc::Parser include ::ActionDispatch::Journey::Nodes # @return [Parser] a new instance of Parser # - # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#16 + # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#18 def initialize; end # reduce 0 omitted # - # source://actionpack//lib/action_dispatch/journey/parser.rb#137 + # source://actionpack//lib/action_dispatch/journey/parser.rb#138 def _reduce_1(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#165 + # source://actionpack//lib/action_dispatch/journey/parser.rb#166 def _reduce_10(val, _values); end # reduce 14 omitted # - # source://actionpack//lib/action_dispatch/journey/parser.rb#177 + # source://actionpack//lib/action_dispatch/journey/parser.rb#178 def _reduce_15(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#181 + # source://actionpack//lib/action_dispatch/journey/parser.rb#182 def _reduce_16(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#185 + # source://actionpack//lib/action_dispatch/journey/parser.rb#186 def _reduce_17(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#189 + # source://actionpack//lib/action_dispatch/journey/parser.rb#190 def _reduce_18(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#141 + # source://actionpack//lib/action_dispatch/journey/parser.rb#142 def _reduce_2(val, _values); end # reduce 6 omitted # - # source://actionpack//lib/action_dispatch/journey/parser.rb#153 + # source://actionpack//lib/action_dispatch/journey/parser.rb#154 def _reduce_7(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#157 + # source://actionpack//lib/action_dispatch/journey/parser.rb#158 def _reduce_8(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#161 + # source://actionpack//lib/action_dispatch/journey/parser.rb#162 def _reduce_9(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser.rb#193 + # source://actionpack//lib/action_dispatch/journey/parser.rb#194 def _reduce_none(val, _values); end - # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#25 + # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#27 def next_token; end - # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#20 + # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#22 def parse(string); end class << self - # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#12 + # source://actionpack//lib/action_dispatch/journey/parser_extras.rb#14 def parse(string); end end end -# source://actionpack//lib/action_dispatch/journey/parser.rb#92 +# source://actionpack//lib/action_dispatch/journey/parser.rb#93 ActionDispatch::Journey::Parser::Racc_arg = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/journey/parser.rb#131 +# source://actionpack//lib/action_dispatch/journey/parser.rb#132 ActionDispatch::Journey::Parser::Racc_debug_parser = T.let(T.unsafe(nil), FalseClass) -# source://actionpack//lib/action_dispatch/journey/parser.rb#108 +# source://actionpack//lib/action_dispatch/journey/parser.rb#109 ActionDispatch::Journey::Parser::Racc_token_to_s_table = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#5 +# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#7 module ActionDispatch::Journey::Path; end -# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#6 +# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#8 class ActionDispatch::Journey::Path::Pattern # @return [Pattern] a new instance of Pattern # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#9 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#11 def initialize(ast, requirements, separators, anchored); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#156 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#159 def =~(other); end # Returns the value of attribute anchored. # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#7 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#9 def anchored; end # Returns the value of attribute ast. # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#7 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#9 def ast; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#23 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#25 def build_formatter; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#27 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#29 def eager_load!; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#156 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#159 def match(other); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#162 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#165 def match?(other); end # Returns the value of attribute names. # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#7 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#9 def names; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#59 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#62 def optional_names; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#55 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#58 def required_names; end # Returns the value of attribute requirements. # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#7 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#9 def requirements; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#34 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#36 def requirements_anchored?; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#174 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#177 def requirements_for_missing_keys_check; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#166 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#169 def source; end # Returns the value of attribute spec. # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#7 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#9 def spec; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#170 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#173 def to_regexp; end private - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#185 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#188 def offsets; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#181 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#184 def regexp_visitor; end end -# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#65 +# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#68 class ActionDispatch::Journey::Path::Pattern::AnchoredRegexp < ::ActionDispatch::Journey::Visitors::Visitor # @return [AnchoredRegexp] a new instance of AnchoredRegexp # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#66 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#69 def initialize(separator, matchers); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#73 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#76 def accept(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#77 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#80 def visit_CAT(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#94 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#97 def visit_DOT(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#90 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#93 def visit_GROUP(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#94 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#97 def visit_LITERAL(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#108 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#111 def visit_OR(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#99 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#102 def visit_SLASH(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#103 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#106 def visit_STAR(node); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#81 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#84 def visit_SYMBOL(node); end end -# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#121 +# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#124 class ActionDispatch::Journey::Path::Pattern::MatchData # @return [MatchData] a new instance of MatchData # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#124 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#127 def initialize(names, offsets, match); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#138 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#141 def [](x); end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#130 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#133 def captures; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#143 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#146 def length; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#134 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#137 def named_captures; end # Returns the value of attribute names. # - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#122 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#125 def names; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#147 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#150 def post_match; end - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#151 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#154 def to_s; end end -# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#114 +# source://actionpack//lib/action_dispatch/journey/path/pattern.rb#117 class ActionDispatch::Journey::Path::Pattern::UnanchoredRegexp < ::ActionDispatch::Journey::Path::Pattern::AnchoredRegexp - # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#115 + # source://actionpack//lib/action_dispatch/journey/path/pattern.rb#118 def accept(node); end end -# source://actionpack//lib/action_dispatch/journey/route.rb#6 +# source://actionpack//lib/action_dispatch/journey/route.rb#8 class ActionDispatch::Journey::Route # +path+ is a path constraint. - # +constraints+ is a hash of constraints to be applied to this route. + # `constraints` is a hash of constraints to be applied to this route. # # @return [Route] a new instance of Route # - # source://actionpack//lib/action_dispatch/journey/route.rb#56 - def initialize(name:, path:, app: T.unsafe(nil), constraints: T.unsafe(nil), required_defaults: T.unsafe(nil), defaults: T.unsafe(nil), request_method_match: T.unsafe(nil), precedence: T.unsafe(nil), scope_options: T.unsafe(nil), internal: T.unsafe(nil)); end + # source://actionpack//lib/action_dispatch/journey/route.rb#58 + def initialize(name:, path:, app: T.unsafe(nil), constraints: T.unsafe(nil), required_defaults: T.unsafe(nil), defaults: T.unsafe(nil), request_method_match: T.unsafe(nil), precedence: T.unsafe(nil), scope_options: T.unsafe(nil), internal: T.unsafe(nil), source_location: T.unsafe(nil)); end # Returns the value of attribute app. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def app; end # Returns the value of attribute ast. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def ast; end # Returns the value of attribute constraints. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def conditions; end # Returns the value of attribute constraints. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def constraints; end # Returns the value of attribute defaults. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def defaults; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/route.rb#141 + # source://actionpack//lib/action_dispatch/journey/route.rb#144 def dispatcher?; end - # source://actionpack//lib/action_dispatch/journey/route.rb#77 + # source://actionpack//lib/action_dispatch/journey/route.rb#80 def eager_load!; end - # source://actionpack//lib/action_dispatch/journey/route.rb#119 + # source://actionpack//lib/action_dispatch/journey/route.rb#122 def format(path_options); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/route.rb#137 + # source://actionpack//lib/action_dispatch/journey/route.rb#140 def glob?; end # Returns the value of attribute internal. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def internal; end - # source://actionpack//lib/action_dispatch/journey/route.rb#163 + # source://actionpack//lib/action_dispatch/journey/route.rb#166 def ip; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/route.rb#145 + # source://actionpack//lib/action_dispatch/journey/route.rb#148 def matches?(request); end # Returns the value of attribute name. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def name; end - # source://actionpack//lib/action_dispatch/journey/route.rb#114 + # source://actionpack//lib/action_dispatch/journey/route.rb#117 def parts; end # Returns the value of attribute path. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def path; end # Returns the value of attribute precedence. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def precedence; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/route.rb#127 + # source://actionpack//lib/action_dispatch/journey/route.rb#130 def required_default?(key); end - # source://actionpack//lib/action_dispatch/journey/route.rb#131 + # source://actionpack//lib/action_dispatch/journey/route.rb#134 def required_defaults; end - # source://actionpack//lib/action_dispatch/journey/route.rb#102 + # source://actionpack//lib/action_dispatch/journey/route.rb#105 def required_keys; end - # source://actionpack//lib/action_dispatch/journey/route.rb#123 + # source://actionpack//lib/action_dispatch/journey/route.rb#126 def required_parts; end - # Needed for `bin/rails routes`. Picks up succinctly defined requirements - # for a route, for example route + # Needed for `bin/rails routes`. Picks up succinctly defined requirements for a + # route, for example route # - # get 'photo/:id', :controller => 'photos', :action => 'show', - # :id => /[A-Z]\d{5}/ + # get 'photo/:id', :controller => 'photos', :action => 'show', + # :id => /[A-Z]\d{5}/ # - # will have {:controller=>"photos", :action=>"show", :id=>/[A-Z]\d{5}/} - # as requirements. + # will have {:controller=>"photos", :action=>"show", :[id=>/](A-Z){5}/} as + # requirements. # - # source://actionpack//lib/action_dispatch/journey/route.rb#92 + # source://actionpack//lib/action_dispatch/journey/route.rb#95 def requirements; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/route.rb#167 + # source://actionpack//lib/action_dispatch/journey/route.rb#170 def requires_matching_verb?; end # Returns the value of attribute scope_options. # - # source://actionpack//lib/action_dispatch/journey/route.rb#7 + # source://actionpack//lib/action_dispatch/journey/route.rb#9 def scope_options; end - # source://actionpack//lib/action_dispatch/journey/route.rb#106 + # source://actionpack//lib/action_dispatch/journey/route.rb#109 def score(supplied_keys); end - # source://actionpack//lib/action_dispatch/journey/route.rb#114 + # source://actionpack//lib/action_dispatch/journey/route.rb#117 def segment_keys; end - # source://actionpack//lib/action_dispatch/journey/route.rb#98 + # source://actionpack//lib/action_dispatch/journey/route.rb#101 def segments; end - # source://actionpack//lib/action_dispatch/journey/route.rb#171 + # Returns the value of attribute source_location. + # + # source://actionpack//lib/action_dispatch/journey/route.rb#9 + def source_location; end + + # source://actionpack//lib/action_dispatch/journey/route.rb#174 def verb; end private - # source://actionpack//lib/action_dispatch/journey/route.rb#180 + # source://actionpack//lib/action_dispatch/journey/route.rb#183 def match_verb(request); end - # source://actionpack//lib/action_dispatch/journey/route.rb#176 + # source://actionpack//lib/action_dispatch/journey/route.rb#179 def verbs; end class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#47 + # source://actionpack//lib/action_dispatch/journey/route.rb#49 def verb_matcher(verb); end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#12 +# source://actionpack//lib/action_dispatch/journey/route.rb#14 module ActionDispatch::Journey::Route::VerbMatchers; end -# source://actionpack//lib/action_dispatch/journey/route.rb#34 +# source://actionpack//lib/action_dispatch/journey/route.rb#36 class ActionDispatch::Journey::Route::VerbMatchers::All class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#35 + # source://actionpack//lib/action_dispatch/journey/route.rb#37 def call(_); end - # source://actionpack//lib/action_dispatch/journey/route.rb#36 + # source://actionpack//lib/action_dispatch/journey/route.rb#38 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::DELETE class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::GET class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::HEAD class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::LINK class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::OPTIONS class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::PATCH class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::POST class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::PUT class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::TRACE class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#17 +# source://actionpack//lib/action_dispatch/journey/route.rb#19 class ActionDispatch::Journey::Route::VerbMatchers::UNLINK class << self - # source://actionpack//lib/action_dispatch/journey/route.rb#19 + # source://actionpack//lib/action_dispatch/journey/route.rb#21 def call(req); end - # source://actionpack//lib/action_dispatch/journey/route.rb#18 + # source://actionpack//lib/action_dispatch/journey/route.rb#20 def verb; end end end -# source://actionpack//lib/action_dispatch/journey/route.rb#24 +# source://actionpack//lib/action_dispatch/journey/route.rb#26 class ActionDispatch::Journey::Route::VerbMatchers::Unknown # @return [Unknown] a new instance of Unknown # - # source://actionpack//lib/action_dispatch/journey/route.rb#27 + # source://actionpack//lib/action_dispatch/journey/route.rb#29 def initialize(verb); end - # source://actionpack//lib/action_dispatch/journey/route.rb#31 + # source://actionpack//lib/action_dispatch/journey/route.rb#33 def call(request); end # Returns the value of attribute verb. # - # source://actionpack//lib/action_dispatch/journey/route.rb#25 + # source://actionpack//lib/action_dispatch/journey/route.rb#27 def verb; end end -# source://actionpack//lib/action_dispatch/journey/route.rb#13 +# source://actionpack//lib/action_dispatch/journey/route.rb#15 ActionDispatch::Journey::Route::VerbMatchers::VERBS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/journey/route.rb#39 +# source://actionpack//lib/action_dispatch/journey/route.rb#41 ActionDispatch::Journey::Route::VerbMatchers::VERB_TO_CLASS = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#5 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#7 class ActionDispatch::Journey::Router # @return [Router] a new instance of Router # - # source://actionpack//lib/action_dispatch/journey/router.rb#20 + # source://actionpack//lib/action_dispatch/journey/router.rb#22 def initialize(routes); end - # source://actionpack//lib/action_dispatch/journey/router.rb#24 + # source://actionpack//lib/action_dispatch/journey/router.rb#26 def eager_load!; end - # source://actionpack//lib/action_dispatch/journey/router.rb#65 + # source://actionpack//lib/action_dispatch/journey/router.rb#68 def recognize(rails_req); end # Returns the value of attribute routes. # - # source://actionpack//lib/action_dispatch/journey/router.rb#18 + # source://actionpack//lib/action_dispatch/journey/router.rb#20 def routes; end # Sets the attribute routes # # @param value the value to set the attribute routes to. # - # source://actionpack//lib/action_dispatch/journey/router.rb#18 + # source://actionpack//lib/action_dispatch/journey/router.rb#20 def routes=(_arg0); end - # source://actionpack//lib/action_dispatch/journey/router.rb#31 + # source://actionpack//lib/action_dispatch/journey/router.rb#33 def serve(req); end - # source://actionpack//lib/action_dispatch/journey/router.rb#78 + # source://actionpack//lib/action_dispatch/journey/router.rb#81 def visualizer; end private - # source://actionpack//lib/action_dispatch/journey/router.rb#92 + # source://actionpack//lib/action_dispatch/journey/router.rb#95 def ast; end - # source://actionpack//lib/action_dispatch/journey/router.rb#100 + # source://actionpack//lib/action_dispatch/journey/router.rb#103 def custom_routes; end - # source://actionpack//lib/action_dispatch/journey/router.rb#104 + # source://actionpack//lib/action_dispatch/journey/router.rb#107 def filter_routes(path); end - # source://actionpack//lib/action_dispatch/journey/router.rb#109 + # source://actionpack//lib/action_dispatch/journey/router.rb#112 def find_routes(req); end - # source://actionpack//lib/action_dispatch/journey/router.rb#134 + # source://actionpack//lib/action_dispatch/journey/router.rb#137 def match_head_routes(routes, req); end - # source://actionpack//lib/action_dispatch/journey/router.rb#86 + # source://actionpack//lib/action_dispatch/journey/router.rb#89 def partitioned_routes; end - # source://actionpack//lib/action_dispatch/journey/router.rb#96 + # source://actionpack//lib/action_dispatch/journey/router.rb#99 def simulator; end end -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#6 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#8 class ActionDispatch::Journey::Router::Utils class << self - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#90 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#91 def escape_fragment(fragment); end - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#82 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#83 def escape_path(path); end - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#86 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#87 def escape_segment(segment); end # Normalizes URI path. # - # Strips off trailing slash and ensures there is a leading slash. - # Also converts downcase URL encoded string to uppercase. + # Strips off trailing slash and ensures there is a leading slash. Also converts + # downcase URL encoded string to uppercase. # - # normalize_path("/foo") # => "/foo" - # normalize_path("/foo/") # => "/foo" - # normalize_path("foo") # => "/foo" - # normalize_path("") # => "/" - # normalize_path("/%ab") # => "/%AB" + # normalize_path("/foo") # => "/foo" + # normalize_path("/foo/") # => "/foo" + # normalize_path("foo") # => "/foo" + # normalize_path("") # => "/" + # normalize_path("/%ab") # => "/%AB" # - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#17 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#19 def normalize_path(path); end # Replaces any escaped sequences with their unescaped representations. # - # uri = "/topics?title=Ruby%20on%20Rails" - # unescape_uri(uri) #=> "/topics?title=Ruby on Rails" + # uri = "/topics?title=Ruby%20on%20Rails" + # unescape_uri(uri) #=> "/topics?title=Ruby on Rails" # - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#98 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#99 def unescape_uri(uri); end end end -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#80 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#81 ActionDispatch::Journey::Router::Utils::ENCODER = T.let(T.unsafe(nil), ActionDispatch::Journey::Router::Utils::UriEncoder) -# URI path and fragment escaping -# https://tools.ietf.org/html/rfc3986 +# URI path and fragment escaping https://tools.ietf.org/html/rfc3986 # -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#33 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#34 class ActionDispatch::Journey::Router::Utils::UriEncoder - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#51 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#52 def escape_fragment(fragment); end - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#55 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#56 def escape_path(path); end - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#59 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#60 def escape_segment(segment); end - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#63 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#64 def unescape_uri(uri); end private - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#69 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#70 def escape(component, pattern); end - # source://actionpack//lib/action_dispatch/journey/router/utils.rb#73 + # source://actionpack//lib/action_dispatch/journey/router/utils.rb#74 def percent_encode(unsafe); end end -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#40 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#41 ActionDispatch::Journey::Router::Utils::UriEncoder::ALPHA = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#38 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#39 ActionDispatch::Journey::Router::Utils::UriEncoder::DEC2HEX = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#41 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#42 ActionDispatch::Journey::Router::Utils::UriEncoder::DIGIT = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#37 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#38 ActionDispatch::Journey::Router::Utils::UriEncoder::EMPTY = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#34 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#35 ActionDispatch::Journey::Router::Utils::UriEncoder::ENCODE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#45 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#46 ActionDispatch::Journey::Router::Utils::UriEncoder::ESCAPED = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#47 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#48 ActionDispatch::Journey::Router::Utils::UriEncoder::FRAGMENT = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#49 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#50 ActionDispatch::Journey::Router::Utils::UriEncoder::PATH = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#48 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#49 ActionDispatch::Journey::Router::Utils::UriEncoder::SEGMENT = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#43 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#44 ActionDispatch::Journey::Router::Utils::UriEncoder::SUB_DELIMS = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#42 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#43 ActionDispatch::Journey::Router::Utils::UriEncoder::UNRESERVED = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#35 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#36 ActionDispatch::Journey::Router::Utils::UriEncoder::US_ASCII = T.let(T.unsafe(nil), Encoding) -# source://actionpack//lib/action_dispatch/journey/router/utils.rb#36 +# source://actionpack//lib/action_dispatch/journey/router/utils.rb#37 ActionDispatch::Journey::Router::Utils::UriEncoder::UTF_8 = T.let(T.unsafe(nil), Encoding) -# The Routing table. Contains all routes for a system. Routes can be -# added to the table by calling Routes#add_route. +# The Routing table. Contains all routes for a system. Routes can be added to +# the table by calling Routes#add_route. # -# source://actionpack//lib/action_dispatch/journey/routes.rb#7 +# source://actionpack//lib/action_dispatch/journey/routes.rb#9 class ActionDispatch::Journey::Routes include ::Enumerable # @return [Routes] a new instance of Routes # - # source://actionpack//lib/action_dispatch/journey/routes.rb#12 - def initialize; end + # source://actionpack//lib/action_dispatch/journey/routes.rb#14 + def initialize(routes = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/journey/routes.rb#65 + # source://actionpack//lib/action_dispatch/journey/routes.rb#67 def add_route(name, mapping); end # Returns the value of attribute anchored_routes. # - # source://actionpack//lib/action_dispatch/journey/routes.rb#10 + # source://actionpack//lib/action_dispatch/journey/routes.rb#12 def anchored_routes; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#51 + # source://actionpack//lib/action_dispatch/journey/routes.rb#53 def ast; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#37 + # source://actionpack//lib/action_dispatch/journey/routes.rb#39 def clear; end # Returns the value of attribute custom_routes. # - # source://actionpack//lib/action_dispatch/journey/routes.rb#10 + # source://actionpack//lib/action_dispatch/journey/routes.rb#12 def custom_routes; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#33 + # source://actionpack//lib/action_dispatch/journey/routes.rb#35 def each(&block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/routes.rb#20 + # source://actionpack//lib/action_dispatch/journey/routes.rb#22 def empty?; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#29 + # source://actionpack//lib/action_dispatch/journey/routes.rb#31 def last; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#24 + # source://actionpack//lib/action_dispatch/journey/routes.rb#26 def length; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#43 + # source://actionpack//lib/action_dispatch/journey/routes.rb#45 def partition_route(route); end # Returns the value of attribute routes. # - # source://actionpack//lib/action_dispatch/journey/routes.rb#10 + # source://actionpack//lib/action_dispatch/journey/routes.rb#12 def routes; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#58 + # source://actionpack//lib/action_dispatch/journey/routes.rb#60 def simulator; end - # source://actionpack//lib/action_dispatch/journey/routes.rb#24 + # source://actionpack//lib/action_dispatch/journey/routes.rb#26 def size; end private - # source://actionpack//lib/action_dispatch/journey/routes.rb#74 + # source://actionpack//lib/action_dispatch/journey/routes.rb#76 def clear_cache!; end end -# source://actionpack//lib/action_dispatch/journey/scanner.rb#7 +# source://actionpack//lib/action_dispatch/journey/scanner.rb#9 class ActionDispatch::Journey::Scanner # @return [Scanner] a new instance of Scanner # - # source://actionpack//lib/action_dispatch/journey/scanner.rb#8 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#10 def initialize; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/journey/scanner.rb#16 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#18 def eos?; end - # source://actionpack//lib/action_dispatch/journey/scanner.rb#28 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#30 def next_token; end - # source://actionpack//lib/action_dispatch/journey/scanner.rb#20 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#22 def pos; end - # source://actionpack//lib/action_dispatch/journey/scanner.rb#24 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#26 def pre_match; end - # source://actionpack//lib/action_dispatch/journey/scanner.rb#12 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#14 def scan_setup(str); end private - # takes advantage of String @- deduping capabilities in Ruby 2.5 upwards - # see: https://bugs.ruby-lang.org/issues/13077 + # takes advantage of String @- deduping capabilities in Ruby 2.5 upwards see: + # https://bugs.ruby-lang.org/issues/13077 # - # source://actionpack//lib/action_dispatch/journey/scanner.rb#38 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#40 def dedup_scan(regex); end - # source://actionpack//lib/action_dispatch/journey/scanner.rb#43 + # source://actionpack//lib/action_dispatch/journey/scanner.rb#45 def scan; end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#53 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#55 module ActionDispatch::Journey::Visitors; end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#194 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#196 class ActionDispatch::Journey::Visitors::Dot < ::ActionDispatch::Journey::Visitors::FunctionalVisitor # @return [Dot] a new instance of Dot # - # source://actionpack//lib/action_dispatch/journey/visitors.rb#195 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#197 def initialize; end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#200 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#202 def accept(node, seed = T.unsafe(nil)); end private - # source://actionpack//lib/action_dispatch/journey/visitors.rb#215 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#217 def binary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#222 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#224 def nary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#254 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#256 def terminal(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#229 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#231 def unary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#239 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#241 def visit_CAT(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#234 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#236 def visit_GROUP(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#249 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#251 def visit_OR(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#244 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#246 def visit_STAR(node, seed); end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#260 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#262 ActionDispatch::Journey::Visitors::Dot::INSTANCE = T.let(T.unsafe(nil), ActionDispatch::Journey::Visitors::Dot) # Loop through the requirements AST. # -# source://actionpack//lib/action_dispatch/journey/visitors.rb#159 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#161 class ActionDispatch::Journey::Visitors::Each < ::ActionDispatch::Journey::Visitors::FunctionalVisitor - # source://actionpack//lib/action_dispatch/journey/visitors.rb#160 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#162 def visit(node, block); end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#165 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#167 ActionDispatch::Journey::Visitors::Each::INSTANCE = T.let(T.unsafe(nil), ActionDispatch::Journey::Visitors::Each) -# source://actionpack//lib/action_dispatch/journey/visitors.rb#134 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#136 class ActionDispatch::Journey::Visitors::FormatBuilder < ::ActionDispatch::Journey::Visitors::Visitor - # source://actionpack//lib/action_dispatch/journey/visitors.rb#135 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#137 def accept(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#138 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#140 def binary(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#136 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#138 def terminal(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#142 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#144 def visit_GROUP(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#144 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#146 def visit_STAR(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#148 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#150 def visit_SYMBOL(n); end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#95 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#97 class ActionDispatch::Journey::Visitors::FunctionalVisitor - # source://actionpack//lib/action_dispatch/journey/visitors.rb#98 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#100 def accept(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#106 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#108 def binary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#111 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#113 def nary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#122 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#124 def terminal(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#116 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#118 def unary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#102 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#104 def visit(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#109 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#111 def visit_CAT(n, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#126 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#128 def visit_DOT(n, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#119 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#121 def visit_GROUP(n, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#123 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#125 def visit_LITERAL(n, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#114 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#116 def visit_OR(n, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#125 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#127 def visit_SLASH(n, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#120 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#122 def visit_STAR(n, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#124 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#126 def visit_SYMBOL(n, seed); end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#96 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#98 ActionDispatch::Journey::Visitors::FunctionalVisitor::DISPATCH_CACHE = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/journey/visitors.rb#168 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#170 class ActionDispatch::Journey::Visitors::String < ::ActionDispatch::Journey::Visitors::FunctionalVisitor private - # source://actionpack//lib/action_dispatch/journey/visitors.rb#170 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#172 def binary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#174 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#176 def nary(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#183 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#185 def terminal(node, seed); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#187 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#189 def visit_GROUP(node, seed); end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#191 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#193 ActionDispatch::Journey::Visitors::String::INSTANCE = T.let(T.unsafe(nil), ActionDispatch::Journey::Visitors::String) -# source://actionpack//lib/action_dispatch/journey/visitors.rb#54 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#56 class ActionDispatch::Journey::Visitors::Visitor - # source://actionpack//lib/action_dispatch/journey/visitors.rb#57 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#59 def accept(node); end private - # source://actionpack//lib/action_dispatch/journey/visitors.rb#66 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#68 def binary(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#72 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#74 def nary(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#83 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#85 def terminal(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#77 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#79 def unary(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#62 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#64 def visit(node); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#70 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#72 def visit_CAT(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#87 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#89 def visit_DOT(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#80 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#82 def visit_GROUP(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#84 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#86 def visit_LITERAL(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#75 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#77 def visit_OR(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#86 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#88 def visit_SLASH(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#81 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#83 def visit_STAR(n); end - # source://actionpack//lib/action_dispatch/journey/visitors.rb#85 + # source://actionpack//lib/action_dispatch/journey/visitors.rb#87 def visit_SYMBOL(n); end end -# source://actionpack//lib/action_dispatch/journey/visitors.rb#55 +# source://actionpack//lib/action_dispatch/journey/visitors.rb#57 ActionDispatch::Journey::Visitors::Visitor::DISPATCH_CACHE = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/middleware/stack.rb#7 +# source://actionpack//lib/action_dispatch/log_subscriber.rb#6 +class ActionDispatch::LogSubscriber < ::ActiveSupport::LogSubscriber + # source://actionpack//lib/action_dispatch/log_subscriber.rb#7 + def redirect(event); end + + class << self + # source://activesupport/7.2.0/lib/active_support/log_subscriber.rb#84 + def log_levels; end + end +end + +# # Action Dispatch MiddlewareStack +# +# Read more about [Rails middleware +# stack](https://guides.rubyonrails.org/rails_on_rack.html#action-dispatcher-middleware-stack) +# in the guides. +# +# source://actionpack//lib/action_dispatch/middleware/stack.rb#14 class ActionDispatch::MiddlewareStack include ::Enumerable @@ -13279,501 +14294,508 @@ class ActionDispatch::MiddlewareStack # @yield [_self] # @yieldparam _self [ActionDispatch::MiddlewareStack] the object that the method was called on # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#70 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#76 def initialize(*args); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#87 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#93 def [](i); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#160 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#166 def build(app = T.unsafe(nil), &block); end # Deletes a middleware from the middleware stack. # - # Returns the array of middlewares not including the deleted item, or - # returns nil if the target is not found. + # Returns the array of middlewares not including the deleted item, or returns + # nil if the target is not found. # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#125 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#131 def delete(target); end # Deletes a middleware from the middleware stack. # - # Returns the array of middlewares not including the deleted item, or - # raises +RuntimeError+ if the target is not found. + # Returns the array of middlewares not including the deleted item, or raises + # `RuntimeError` if the target is not found. # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#133 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#139 def delete!(target); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#75 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#81 def each(&block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#100 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#106 def insert(index, klass, *args, **_arg3, &block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#108 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#114 def insert_after(index, *args, **_arg2, &block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#100 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#106 def insert_before(index, klass, *args, **_arg3, &block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#83 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#89 def last; end # Returns the value of attribute middlewares. # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#68 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#74 def middlewares; end # Sets the attribute middlewares # # @param value the value to set the attribute middlewares to. # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#68 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#74 def middlewares=(_arg0); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#137 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#143 def move(target, source); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#147 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#153 def move_after(target, source); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#137 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#143 def move_before(target, source); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#79 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#85 def size; end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#114 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#120 def swap(target, *args, **_arg2, &block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#91 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#97 def unshift(klass, *args, **_arg2, &block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#155 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#161 def use(klass, *args, **_arg2, &block); end private - # source://actionpack//lib/action_dispatch/middleware/stack.rb#172 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#178 def assert_index(index, where); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#178 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#184 def build_middleware(klass, args, block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#182 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#188 def index_of(klass); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#96 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#102 def initialize_copy(other); end end -# This class is used to instrument the execution of a single middleware. -# It proxies the +call+ method transparently and instruments the method -# call. +# This class is used to instrument the execution of a single middleware. It +# proxies the `call` method transparently and instruments the method call. # -# source://actionpack//lib/action_dispatch/middleware/stack.rb#48 +# source://actionpack//lib/action_dispatch/middleware/stack.rb#54 class ActionDispatch::MiddlewareStack::InstrumentationProxy # @return [InstrumentationProxy] a new instance of InstrumentationProxy # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#51 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#57 def initialize(middleware, class_name); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#59 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#65 def call(env); end end -# source://actionpack//lib/action_dispatch/middleware/stack.rb#49 +# source://actionpack//lib/action_dispatch/middleware/stack.rb#55 ActionDispatch::MiddlewareStack::InstrumentationProxy::EVENT_NAME = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/middleware/stack.rb#8 +# source://actionpack//lib/action_dispatch/middleware/stack.rb#15 class ActionDispatch::MiddlewareStack::Middleware # @return [Middleware] a new instance of Middleware # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#11 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#18 def initialize(klass, args, block); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#19 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#26 def ==(middleware); end # Returns the value of attribute args. # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#9 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#16 def args; end # Returns the value of attribute block. # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#9 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#16 def block; end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#36 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#43 def build(app); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#40 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#47 def build_instrumented(app); end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#28 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#35 def inspect; end # Returns the value of attribute klass. # - # source://actionpack//lib/action_dispatch/middleware/stack.rb#9 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#16 def klass; end - # source://actionpack//lib/action_dispatch/middleware/stack.rb#17 + # source://actionpack//lib/action_dispatch/middleware/stack.rb#24 def name; end end -# source://actionpack//lib/action_dispatch.rb#43 +# source://actionpack//lib/action_dispatch.rb#50 class ActionDispatch::MissingController < ::NameError; end +# # Action Dispatch PermissionsPolicy +# # Configures the HTTP -# {Feature-Policy}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Feature-Policy] -# response header to specify which browser features the current document and -# its iframes can use. +# [Feature-Policy](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Feature-Policy) +# response header to specify which browser features the current +# document and its iframes can use. # # Example global policy: # -# Rails.application.config.permissions_policy do |policy| -# policy.camera :none -# policy.gyroscope :none -# policy.microphone :none -# policy.usb :none -# policy.fullscreen :self -# policy.payment :self, "https://secure.example.com" -# end +# Rails.application.config.permissions_policy do |policy| +# policy.camera :none +# policy.gyroscope :none +# policy.microphone :none +# policy.usb :none +# policy.fullscreen :self +# policy.payment :self, "https://secure.example.com" +# end +# +# The Feature-Policy header has been renamed to Permissions-Policy. The +# Permissions-Policy requires a different implementation and isn't yet supported +# by all browsers. To avoid having to rename this middleware in the future we +# use the new name for the middleware but keep the old header name and +# implementation for now. # -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#22 +# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#31 class ActionDispatch::PermissionsPolicy # @return [PermissionsPolicy] a new instance of PermissionsPolicy # @yield [_self] # @yieldparam _self [ActionDispatch::PermissionsPolicy] the object that the method was called on # - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#113 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#111 def initialize; end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def accelerometer(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def ambient_light_sensor(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def autoplay(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#132 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#130 def build(context = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def camera(*sources); end # Returns the value of attribute directives. # - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#111 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#109 def directives; end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def encrypted_media(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def fullscreen(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def geolocation(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def gyroscope(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 + def hid(*sources); end + + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 + def idle_detection(*sources); end + + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def magnetometer(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def microphone(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def midi(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def payment(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 def picture_in_picture(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 - def speaker(*sources); end + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 + def screen_wake_lock(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 - def usb(*sources); end + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 + def serial(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 - def vibrate(*sources); end + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 + def sync_xhr(*sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#123 - def vr(*sources); end + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 + def usb(*sources); end + + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#121 + def web_share(*sources); end private - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#150 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#148 def apply_mapping(source); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#137 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#135 def apply_mappings(sources); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#168 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#166 def build_directive(sources, context); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#156 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#154 def build_directives(context); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#118 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#116 def initialize_copy(other); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#172 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#170 def resolve_source(source, context); end end # List of available permissions can be found at -# https://github.com/w3c/webappsec-permissions-policy/blob/master/features.md#policy-controlled-features +# https://github.com/w3c/webappsec-permissions-policy/blob/main/features.md#policy-controlled-features # -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#89 +# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#84 ActionDispatch::PermissionsPolicy::DIRECTIVES = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#82 +# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#77 ActionDispatch::PermissionsPolicy::MAPPINGS = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#23 +# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#32 class ActionDispatch::PermissionsPolicy::Middleware # @return [Middleware] a new instance of Middleware # - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#32 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#33 def initialize(app); end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#36 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#37 def call(env); end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#55 - def html_response?(headers); end - - # @return [Boolean] - # - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#65 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#60 def policy_empty?(policy); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#61 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#56 def policy_present?(headers); end end -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#24 -ActionDispatch::PermissionsPolicy::Middleware::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# The Feature-Policy header has been renamed to Permissions-Policy. -# The Permissions-Policy requires a different implementation and isn't -# yet supported by all browsers. To avoid having to rename this -# middleware in the future we use the new name for the middleware but -# keep the old header name and implementation for now. -# -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#30 -ActionDispatch::PermissionsPolicy::Middleware::POLICY = T.let(T.unsafe(nil), String) - -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#70 +# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#65 module ActionDispatch::PermissionsPolicy::Request - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#73 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#68 def permissions_policy; end - # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#77 + # source://actionpack//lib/action_dispatch/http/permissions_policy.rb#72 def permissions_policy=(policy); end end -# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#71 +# source://actionpack//lib/action_dispatch/http/permissions_policy.rb#66 ActionDispatch::PermissionsPolicy::Request::POLICY = T.let(T.unsafe(nil), String) +# # Action Dispatch PublicExceptions +# # When called, this middleware renders an error page. By default if an HTML -# response is expected it will render static error pages from the /public +# response is expected it will render static error pages from the `/public` # directory. For example when this middleware receives a 500 response it will -# render the template found in /public/500.html. -# If an internationalized locale is set, this middleware will attempt to render -# the template in /public/500..html. If an internationalized template -# is not found it will fall back on /public/500.html. +# render the template found in `/public/500.html`. If an internationalized +# locale is set, this middleware will attempt to render the template in +# `/public/500..html`. If an internationalized template is not found it +# will fall back on `/public/500.html`. # # When a request with a content type other than HTML is made, this middleware # will attempt to convert error information into the appropriate response type. # -# source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#14 +# source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#18 class ActionDispatch::PublicExceptions # @return [PublicExceptions] a new instance of PublicExceptions # - # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#17 + # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#21 def initialize(public_path); end - # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#21 + # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#25 def call(env); end # Returns the value of attribute public_path. # - # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#15 + # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#19 def public_path; end # Sets the attribute public_path # # @param value the value to set the attribute public_path to. # - # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#15 + # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#19 def public_path=(_arg0); end private - # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#35 + # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#39 def render(status, content_type, body); end - # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#44 + # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#48 def render_format(status, content_type, body); end - # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#49 + # source://actionpack//lib/action_dispatch/middleware/public_exceptions.rb#53 def render_html(status); end end -# source://actionpack//lib/action_dispatch/railtie.rb#7 +# source://actionpack//lib/action_dispatch/railtie.rb#10 class ActionDispatch::Railtie < ::Rails::Railtie; end -# ActionDispatch::Reloader wraps the request with callbacks provided by ActiveSupport::Reloader -# callbacks, intended to assist with code reloading during development. +# # Action Dispatch Reloader +# +# ActionDispatch::Reloader wraps the request with callbacks provided by +# ActiveSupport::Reloader, intended to assist with code reloading during +# development. # -# By default, ActionDispatch::Reloader is included in the middleware stack -# only in the development environment; specifically, when +config.cache_classes+ -# is false. +# ActionDispatch::Reloader is included in the middleware stack only if reloading +# is enabled, which it is by the default in `development` mode. # -# source://actionpack//lib/action_dispatch/middleware/reloader.rb#10 +# source://actionpack//lib/action_dispatch/middleware/reloader.rb#14 class ActionDispatch::Reloader < ::ActionDispatch::Executor; end -# This middleware calculates the IP address of the remote client that is -# making the request. It does this by checking various headers that could -# contain the address, and then picking the last-set address that is not -# on the list of trusted IPs. This follows the precedent set by e.g. -# {the Tomcat server}[https://issues.apache.org/bugzilla/show_bug.cgi?id=50453], -# with {reasoning explained at length}[https://blog.gingerlime.com/2012/rails-ip-spoofing-vulnerabilities-and-protection] -# by @gingerlime. A more detailed explanation of the algorithm is given -# at GetIp#calculate_ip. -# -# Some Rack servers concatenate repeated headers, like {HTTP RFC 2616}[https://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4.2] -# requires. Some Rack servers simply drop preceding headers, and only report -# the value that was {given in the last header}[https://andre.arko.net/2011/12/26/repeated-headers-and-ruby-web-servers]. -# If you are behind multiple proxy servers (like NGINX to HAProxy to Unicorn) -# then you should test your Rack server to make sure your data is good. -# -# IF YOU DON'T USE A PROXY, THIS MAKES YOU VULNERABLE TO IP SPOOFING. -# This middleware assumes that there is at least one proxy sitting around -# and setting headers with the client's remote IP address. If you don't use -# a proxy, because you are hosted on e.g. Heroku without SSL, any client can -# claim to have any IP address by setting the +X-Forwarded-For+ header. If you -# care about that, then you need to explicitly drop or ignore those headers -# sometime before this middleware runs. -# -# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#28 +# # Action Dispatch RemoteIp +# +# This middleware calculates the IP address of the remote client that is making +# the request. It does this by checking various headers that could contain the +# address, and then picking the last-set address that is not on the list of +# trusted IPs. This follows the precedent set by e.g. [the Tomcat +# server](https://issues.apache.org/bugzilla/show_bug.cgi?id=50453). A more +# detailed explanation of the algorithm is given at GetIp#calculate_ip. +# +# Some Rack servers concatenate repeated headers, like [HTTP RFC +# 2616](https://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4.2) requires. +# Some Rack servers simply drop preceding headers, and only report the value +# that was [given in the last +# header](https://andre.arko.net/2011/12/26/repeated-headers-and-ruby-web-server +# s). If you are behind multiple proxy servers (like NGINX to HAProxy to +# Unicorn) then you should test your Rack server to make sure your data is good. +# +# IF YOU DON'T USE A PROXY, THIS MAKES YOU VULNERABLE TO IP SPOOFING. This +# middleware assumes that there is at least one proxy sitting around and setting +# headers with the client's remote IP address. If you don't use a proxy, because +# you are hosted on e.g. Heroku without SSL, any client can claim to have any IP +# address by setting the `X-Forwarded-For` header. If you care about that, then +# you need to explicitly drop or ignore those headers sometime before this +# middleware runs. Alternatively, remove this middleware to avoid inadvertently +# relying on it. +# +# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#33 class ActionDispatch::RemoteIp - # Create a new +RemoteIp+ middleware instance. + # Create a new `RemoteIp` middleware instance. # - # The +ip_spoofing_check+ option is on by default. When on, an exception - # is raised if it looks like the client is trying to lie about its own IP - # address. It makes sense to turn off this check on sites aimed at non-IP - # clients (like WAP devices), or behind proxies that set headers in an - # incorrect or confusing way (like AWS ELB). + # The `ip_spoofing_check` option is on by default. When on, an exception is + # raised if it looks like the client is trying to lie about its own IP address. + # It makes sense to turn off this check on sites aimed at non-IP clients (like + # WAP devices), or behind proxies that set headers in an incorrect or confusing + # way (like AWS ELB). # - # The +custom_proxies+ argument can take an enumerable which will be used - # instead of +TRUSTED_PROXIES+. Any proxy setup will put the value you - # want in the middle (or at the beginning) of the +X-Forwarded-For+ list, - # with your proxy servers after it. If your proxies aren't removed, pass - # them in via the +custom_proxies+ parameter. That way, the middleware will - # ignore those IP addresses, and return the one that you want. + # The `custom_proxies` argument can take an enumerable which will be used + # instead of `TRUSTED_PROXIES`. Any proxy setup will put the value you want in + # the middle (or at the beginning) of the `X-Forwarded-For` list, with your + # proxy servers after it. If your proxies aren't removed, pass them in via the + # `custom_proxies` parameter. That way, the middleware will ignore those IP + # addresses, and return the one that you want. # # @return [RemoteIp] a new instance of RemoteIp # - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#60 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#65 def initialize(app, ip_spoofing_check = T.unsafe(nil), custom_proxies = T.unsafe(nil)); end - # Since the IP address may not be needed, we store the object here - # without calculating the IP to keep from slowing down the majority of - # requests. For those requests that do need to know the IP, the - # GetIp#calculate_ip method will calculate the memoized client IP address. + # Since the IP address may not be needed, we store the object here without + # calculating the IP to keep from slowing down the majority of requests. For + # those requests that do need to know the IP, the GetIp#calculate_ip method will + # calculate the memoized client IP address. # - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#90 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#93 def call(env); end # Returns the value of attribute check_ip. # - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#44 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#49 def check_ip; end # Returns the value of attribute proxies. # - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#44 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#49 def proxies; end end -# The GetIp class exists as a way to defer processing of the request data -# into an actual IP address. If the ActionDispatch::Request#remote_ip method -# is called, this class will calculate the value and then memoize it. +# The GetIp class exists as a way to defer processing of the request data into +# an actual IP address. If the ActionDispatch::Request#remote_ip method is +# called, this class will calculate the value and then memoize it. # -# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#99 +# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#102 class ActionDispatch::RemoteIp::GetIp # @return [GetIp] a new instance of GetIp # - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#100 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#103 def initialize(req, check_ip, proxies); end - # Sort through the various IP address headers, looking for the IP most - # likely to be the address of the actual remote client making this - # request. + # Sort through the various IP address headers, looking for the IP most likely to + # be the address of the actual remote client making this request. # - # REMOTE_ADDR will be correct if the request is made directly against the - # Ruby process, on e.g. Heroku. When the request is proxied by another - # server like HAProxy or NGINX, the IP address that made the original - # request will be put in an +X-Forwarded-For+ header. If there are multiple - # proxies, that header may contain a list of IPs. Other proxy services - # set the +Client-Ip+ header instead, so we check that too. + # REMOTE_ADDR will be correct if the request is made directly against the Ruby + # process, on e.g. Heroku. When the request is proxied by another server like + # HAProxy or NGINX, the IP address that made the original request will be put in + # an `X-Forwarded-For` header. If there are multiple proxies, that header may + # contain a list of IPs. Other proxy services set the `Client-Ip` header + # instead, so we check that too. # - # As discussed in {this post about Rails IP Spoofing}[https://blog.gingerlime.com/2012/rails-ip-spoofing-vulnerabilities-and-protection/], - # while the first IP in the list is likely to be the "originating" IP, - # it could also have been set by the client maliciously. + # As discussed in [this post about Rails IP + # Spoofing](https://web.archive.org/web/20170626095448/https://blog.gingerlime.c + # om/2012/rails-ip-spoofing-vulnerabilities-and-protection/), while the first IP + # in the list is likely to be the "originating" IP, it could also have been set + # by the client maliciously. # - # In order to find the first address that is (probably) accurate, we - # take the list of IPs, remove known and trusted proxies, and then take - # the last address left, which was presumably set by one of those proxies. + # In order to find the first address that is (probably) accurate, we take the + # list of IPs, remove known and trusted proxies, and then take the last address + # left, which was presumably set by one of those proxies. # - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#124 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#128 def calculate_ip; end # Memoizes the value returned by #calculate_ip and returns it for # ActionDispatch::Request to use. # - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#167 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#172 def to_s; end private - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#186 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#192 def filter_proxies(ips); end - # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#172 + # source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#177 def ips_from(header); end end -# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#29 +# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#34 class ActionDispatch::RemoteIp::IpSpoofAttackError < ::StandardError; end -# The default trusted IPs list simply includes IP addresses that are -# guaranteed by the IP specification to be private addresses. Those will -# not be the ultimate client IP in production, and so are discarded. See +# The default trusted IPs list simply includes IP addresses that are guaranteed +# by the IP specification to be private addresses. Those will not be the +# ultimate client IP in production, and so are discarded. See # https://en.wikipedia.org/wiki/Private_network for details. # -# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#35 +# source://actionpack//lib/action_dispatch/middleware/remote_ip.rb#40 ActionDispatch::RemoteIp::TRUSTED_PROXIES = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/http/request.rb#18 +# source://actionpack//lib/action_dispatch/http/request.rb#20 class ActionDispatch::Request include ::ActionDispatch::Flash::RequestMethods include ::Rack::Request::Helpers @@ -13790,931 +14812,964 @@ class ActionDispatch::Request # @return [Request] a new instance of Request # - # source://actionpack//lib/action_dispatch/http/request.rb#60 + # source://actionpack//lib/action_dispatch/http/request.rb#62 def initialize(env); end # Override Rack's GET method to support indifferent access. # - # source://actionpack//lib/action_dispatch/http/request.rb#371 + # source://actionpack//lib/action_dispatch/http/request.rb#388 def GET; end # Override Rack's POST method to support indifferent access. # - # source://actionpack//lib/action_dispatch/http/request.rb#387 + # source://actionpack//lib/action_dispatch/http/request.rb#404 def POST; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def accept; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def accept_charset; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def accept_encoding; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def accept_language; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def auth_type; end - # Returns the authorization header regardless of whether it was specified directly or through one of the - # proxy alternatives. + # Returns the authorization header regardless of whether it was specified + # directly or through one of the proxy alternatives. # - # source://actionpack//lib/action_dispatch/http/request.rb#403 + # source://actionpack//lib/action_dispatch/http/request.rb#420 def authorization; end # The request body is an IO input stream. If the RAW_POST_DATA environment # variable is already set, wrap it in a StringIO. # - # source://actionpack//lib/action_dispatch/http/request.rb#333 + # source://actionpack//lib/action_dispatch/http/request.rb#350 def body; end - # source://actionpack//lib/action_dispatch/http/request.rb#354 + # source://actionpack//lib/action_dispatch/http/request.rb#370 def body_stream; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def cache_control; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def client_ip; end - # source://actionpack//lib/action_dispatch/http/request.rb#70 + # source://actionpack//lib/action_dispatch/http/request.rb#72 def commit_cookie_jar!; end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#62 + # source://actionpack//lib/action_dispatch/http/request.rb#452 + def commit_csrf_token; end + + # source://actionpack//lib/action_dispatch/middleware/flash.rb#71 def commit_flash; end # Returns the content length of the request as an integer. # - # source://actionpack//lib/action_dispatch/http/request.rb#269 + # source://actionpack//lib/action_dispatch/http/request.rb#284 def content_length; end - # source://actionpack//lib/action_dispatch/http/request.rb#79 + # source://actionpack//lib/action_dispatch/http/request.rb#81 def controller_class; end - # source://actionpack//lib/action_dispatch/http/request.rb#85 + # source://actionpack//lib/action_dispatch/http/request.rb#87 def controller_class_for(name); end - # source://actionpack//lib/action_dispatch/http/request.rb#170 + # source://actionpack//lib/action_dispatch/http/request.rb#183 def controller_instance; end - # source://actionpack//lib/action_dispatch/http/request.rb#174 + # source://actionpack//lib/action_dispatch/http/request.rb#187 def controller_instance=(controller); end - # source://actionpack//lib/action_dispatch/http/request.rb#156 + # source://actionpack//lib/action_dispatch/http/request.rb#169 def engine_script_name(_routes); end - # source://actionpack//lib/action_dispatch/http/request.rb#160 + # source://actionpack//lib/action_dispatch/http/request.rb#173 def engine_script_name=(name); end - # Determine whether the request body contains form-data by checking - # the request +Content-Type+ for one of the media-types: - # +application/x-www-form-urlencoded+ or +multipart/form-data+. The - # list of form-data media types can be modified through the - # +FORM_DATA_MEDIA_TYPES+ array. + # Determine whether the request body contains form-data by checking the request + # `Content-Type` for one of the media-types: `application/x-www-form-urlencoded` + # or `multipart/form-data`. The list of form-data media types can be modified + # through the `FORM_DATA_MEDIA_TYPES` array. # - # A request body is not assumed to contain form-data when no - # +Content-Type+ header is provided and the request_method is POST. + # A request body is not assumed to contain form-data when no `Content-Type` + # header is provided and the request_method is POST. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/request.rb#350 + # source://actionpack//lib/action_dispatch/http/request.rb#366 def form_data?; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def from; end - # Returns the +String+ full path including params of the last URL requested. + # Returns the `String` full path including params of the last URL requested. # - # # get "/articles" - # request.fullpath # => "/articles" + # # get "/articles" + # request.fullpath # => "/articles" # - # # get "/articles?page=2" - # request.fullpath # => "/articles?page=2" + # # get "/articles?page=2" + # request.fullpath # => "/articles?page=2" # - # source://actionpack//lib/action_dispatch/http/request.rb#248 + # source://actionpack//lib/action_dispatch/http/request.rb#263 def fullpath; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def gateway_interface; end # Provides access to the request's HTTP headers, for example: # - # request.headers["Content-Type"] # => "text/plain" + # request.headers["Content-Type"] # => "text/plain" # - # source://actionpack//lib/action_dispatch/http/request.rb#209 + # source://actionpack//lib/action_dispatch/http/request.rb#225 def headers; end - # source://actionpack//lib/action_dispatch/http/request.rb#178 + # source://actionpack//lib/action_dispatch/http/request.rb#191 def http_auth_salt; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#18 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#20 def ignore_accept_header; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#18 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#20 def ignore_accept_header=(val); end - # source://actionpack//lib/action_dispatch/http/request.rb#427 + # source://actionpack//lib/action_dispatch/http/request.rb#444 def inspect; end - # Returns the IP address of client as a +String+. + # Returns the IP address of client as a `String`. # - # source://actionpack//lib/action_dispatch/http/request.rb#282 + # source://actionpack//lib/action_dispatch/http/request.rb#298 def ip; end # Returns true if the request has a header matching the given key parameter. # - # request.key? :ip_spoofing_check # => true + # request.key? :ip_spoofing_check # => true # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/request.rb#106 + # source://actionpack//lib/action_dispatch/http/request.rb#108 def key?(key); end # True if the request came from localhost, 127.0.0.1, or ::1. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/request.rb#411 + # source://actionpack//lib/action_dispatch/http/request.rb#428 def local?; end - # source://actionpack//lib/action_dispatch/http/request.rb#420 + # source://actionpack//lib/action_dispatch/http/request.rb#437 def logger; end - # The +String+ MIME type of the request. + # The `String` MIME type of the request. # - # # get "/articles" - # request.media_type # => "application/x-www-form-urlencoded" + # # get "/articles" + # request.media_type # => "application/x-www-form-urlencoded" # - # source://actionpack//lib/action_dispatch/http/request.rb#264 + # source://actionpack//lib/action_dispatch/http/request.rb#279 def media_type; end - # Returns the original value of the environment's REQUEST_METHOD, - # even if it was overridden by middleware. See #request_method for - # more information. + # Returns the original value of the environment's REQUEST_METHOD, even if it was + # overridden by middleware. See #request_method for more information. # - # source://actionpack//lib/action_dispatch/http/request.rb#197 - def method; end + # For debugging purposes, when called with arguments this method will fall back + # to Object#method + # + # source://actionpack//lib/action_dispatch/http/request.rb#205 + def method(*args, **_arg1); end # Returns a symbol form of the #method. # - # source://actionpack//lib/action_dispatch/http/request.rb#202 + # source://actionpack//lib/action_dispatch/http/request.rb#218 def method_symbol; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def negotiate; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def origin; end - # Returns a +String+ with the last requested path including their params. + # Returns a `String` with the last requested path including their params. # - # # get '/foo' - # request.original_fullpath # => '/foo' + # # get '/foo' + # request.original_fullpath # => '/foo' # - # # get '/foo?bar' - # request.original_fullpath # => '/foo?bar' + # # get '/foo?bar' + # request.original_fullpath # => '/foo?bar' # - # source://actionpack//lib/action_dispatch/http/request.rb#237 + # source://actionpack//lib/action_dispatch/http/request.rb#252 def original_fullpath; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def original_script_name; end - # Returns the original request URL as a +String+. + # Returns the original request URL as a `String`. # - # # get "/articles?page=2" - # request.original_url # => "http://www.example.com/articles?page=2" + # # get "/articles?page=2" + # request.original_url # => "http://www.example.com/articles?page=2" # - # source://actionpack//lib/action_dispatch/http/request.rb#256 + # source://actionpack//lib/action_dispatch/http/request.rb#271 def original_url; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def path_translated; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def pragma; end # Override Rack's GET method to support indifferent access. # - # source://actionpack//lib/action_dispatch/http/request.rb#371 + # source://actionpack//lib/action_dispatch/http/request.rb#388 def query_parameters; end - # Read the request \body. This is useful for web services that need to - # work with raw requests directly. + # Read the request body. This is useful for web services that need to work with + # raw requests directly. # - # source://actionpack//lib/action_dispatch/http/request.rb#322 + # source://actionpack//lib/action_dispatch/http/request.rb#340 def raw_post; end - # source://rack/2.2.7/lib/rack/request.rb#157 + # source://rack/2.2.9/lib/rack/request.rb#157 def raw_request_method; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def remote_addr; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def remote_host; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def remote_ident; end - # Returns the IP address of client as a +String+, - # usually set by the RemoteIp middleware. + # Returns the IP address of client as a `String`, usually set by the RemoteIp + # middleware. # - # source://actionpack//lib/action_dispatch/http/request.rb#288 + # source://actionpack//lib/action_dispatch/http/request.rb#304 def remote_ip; end - # source://actionpack//lib/action_dispatch/http/request.rb#292 + # source://actionpack//lib/action_dispatch/http/request.rb#308 def remote_ip=(remote_ip); end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def remote_user; end - # Returns the unique request id, which is based on either the +X-Request-Id+ header that can - # be generated by a firewall, load balancer, or web server, or by the RequestId middleware - # (which sets the +action_dispatch.request_id+ environment variable). + # Returns the unique request id, which is based on either the `X-Request-Id` + # header that can be generated by a firewall, load balancer, or web server, or + # by the RequestId middleware (which sets the `action_dispatch.request_id` + # environment variable). # - # This unique ID is useful for tracing a request from end-to-end as part of logging or debugging. - # This relies on the Rack variable set by the ActionDispatch::RequestId middleware. + # This unique ID is useful for tracing a request from end-to-end as part of + # logging or debugging. This relies on the Rack variable set by the + # ActionDispatch::RequestId middleware. # - # source://actionpack//lib/action_dispatch/http/request.rb#305 + # source://actionpack//lib/action_dispatch/http/request.rb#323 def request_id; end - # source://actionpack//lib/action_dispatch/http/request.rb#309 + # source://actionpack//lib/action_dispatch/http/request.rb#327 def request_id=(id); end - # Returns the HTTP \method that the application should see. - # In the case where the \method was overridden by a middleware - # (for instance, if a HEAD request was converted to a GET, - # or if a _method parameter was used to determine the \method - # the application should use), this \method returns the overridden - # value, not the original. + # Returns the HTTP method that the application should see. In the case where the + # method was overridden by a middleware (for instance, if a HEAD request was + # converted to a GET, or if a _method parameter was used to determine the method + # the application should use), this method returns the overridden value, not the + # original. # - # source://actionpack//lib/action_dispatch/http/request.rb#144 + # source://actionpack//lib/action_dispatch/http/request.rb#145 def request_method; end - # source://actionpack//lib/action_dispatch/http/request.rb#164 + # source://actionpack//lib/action_dispatch/http/request.rb#177 def request_method=(request_method); end # Returns a symbol form of the #request_method. # - # source://actionpack//lib/action_dispatch/http/request.rb#190 + # source://actionpack//lib/action_dispatch/http/request.rb#196 def request_method_symbol; end # Override Rack's POST method to support indifferent access. # - # source://actionpack//lib/action_dispatch/http/request.rb#387 + # source://actionpack//lib/action_dispatch/http/request.rb#404 def request_parameters; end - # source://actionpack//lib/action_dispatch/http/request.rb#415 + # source://actionpack//lib/action_dispatch/http/request.rb#432 def request_parameters=(params); end - # source://actionpack//lib/action_dispatch/middleware/flash.rb#75 + # source://actionpack//lib/action_dispatch/http/request.rb#448 + def reset_csrf_token; end + + # source://actionpack//lib/action_dispatch/middleware/flash.rb#84 def reset_session; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#19 - def return_only_media_type_on_content_type; end + # Returns the URI pattern of the matched route for the request, using the same + # format as `bin/rails routes`: + # + # request.route_uri_pattern # => "/:controller(/:action(/:id))(.:format)" + # + # source://actionpack//lib/action_dispatch/http/request.rb#153 + def route_uri_pattern; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#19 - def return_only_media_type_on_content_type=(val); end + # source://actionpack//lib/action_dispatch/http/request.rb#157 + def route_uri_pattern=(pattern); end - # source://actionpack//lib/action_dispatch/http/request.rb#148 + # source://actionpack//lib/action_dispatch/http/request.rb#161 def routes; end - # source://actionpack//lib/action_dispatch/http/request.rb#152 + # source://actionpack//lib/action_dispatch/http/request.rb#165 def routes=(routes); end - # Early Hints is an HTTP/2 status code that indicates hints to help a client start - # making preparations for processing the final response. + # Early Hints is an HTTP/2 status code that indicates hints to help a client + # start making preparations for processing the final response. # - # If the env contains +rack.early_hints+ then the server accepts HTTP2 push for Link headers. + # If the env contains `rack.early_hints` then the server accepts HTTP2 push for + # link headers. # - # The +send_early_hints+ method accepts a hash of links as follows: + # The `send_early_hints` method accepts a hash of links as follows: # - # send_early_hints("Link" => "; rel=preload; as=style\n; rel=preload") + # send_early_hints("link" => "; rel=preload; as=style,; rel=preload") # - # If you are using +javascript_include_tag+ or +stylesheet_link_tag+ the - # Early Hints headers are included by default if supported. + # If you are using `javascript_include_tag` or `stylesheet_link_tag` the Early + # Hints headers are included by default if supported. # - # source://actionpack//lib/action_dispatch/http/request.rb#224 + # source://actionpack//lib/action_dispatch/http/request.rb#241 def send_early_hints(links); end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def server_name; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def server_protocol; end # Returns the lowercase name of the HTTP server software. # - # source://actionpack//lib/action_dispatch/http/request.rb#316 + # source://actionpack//lib/action_dispatch/http/request.rb#334 def server_software; end - # source://actionpack//lib/action_dispatch/http/request.rb#362 + # source://actionpack//lib/action_dispatch/http/request.rb#379 def session=(session); end - # source://actionpack//lib/action_dispatch/http/request.rb#366 + # source://actionpack//lib/action_dispatch/http/request.rb#383 def session_options=(options); end - # @return [Boolean] - # - # source://actionpack//lib/action_dispatch/http/request.rb#182 - def show_exceptions?; end - - # Returns the unique request id, which is based on either the +X-Request-Id+ header that can - # be generated by a firewall, load balancer, or web server, or by the RequestId middleware - # (which sets the +action_dispatch.request_id+ environment variable). + # Returns the unique request id, which is based on either the `X-Request-Id` + # header that can be generated by a firewall, load balancer, or web server, or + # by the RequestId middleware (which sets the `action_dispatch.request_id` + # environment variable). # - # This unique ID is useful for tracing a request from end-to-end as part of logging or debugging. - # This relies on the Rack variable set by the ActionDispatch::RequestId middleware. + # This unique ID is useful for tracing a request from end-to-end as part of + # logging or debugging. This relies on the Rack variable set by the + # ActionDispatch::RequestId middleware. # - # source://actionpack//lib/action_dispatch/http/request.rb#305 + # source://actionpack//lib/action_dispatch/http/request.rb#323 def uuid; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def version; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def x_csrf_token; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def x_forwarded_for; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def x_forwarded_host; end - # source://actionpack//lib/action_dispatch/http/request.rb#50 + # source://actionpack//lib/action_dispatch/http/request.rb#52 def x_request_id; end - # Returns true if the +X-Requested-With+ header contains "XMLHttpRequest" + # Returns true if the `X-Requested-With` header contains "XMLHttpRequest" # (case-insensitive), which may need to be manually added depending on the # choice of JavaScript libraries and frameworks. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/request.rb#276 + # source://actionpack//lib/action_dispatch/http/request.rb#292 def xhr?; end - # Returns true if the +X-Requested-With+ header contains "XMLHttpRequest" + # Returns true if the `X-Requested-With` header contains "XMLHttpRequest" # (case-insensitive), which may need to be manually added depending on the # choice of JavaScript libraries and frameworks. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/request.rb#276 + # source://actionpack//lib/action_dispatch/http/request.rb#292 def xml_http_request?; end private - # source://actionpack//lib/action_dispatch/http/request.rb#432 + # source://actionpack//lib/action_dispatch/http/request.rb#457 def check_method(name); end - # source://actionpack//lib/action_dispatch/http/request.rb#437 + # source://actionpack//lib/action_dispatch/http/request.rb#465 def default_session; end + # source://actionpack//lib/action_dispatch/http/request.rb#469 + def read_body_stream; end + class << self - # source://actionpack//lib/action_dispatch/http/request.rb#56 + # source://actionpack//lib/action_dispatch/http/request.rb#58 def empty; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#18 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#20 def ignore_accept_header; end - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#18 + # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#20 def ignore_accept_header=(val); end - # source://actionpack//lib/action_dispatch/http/parameters.rb#28 + # source://actionpack//lib/action_dispatch/http/parameters.rb#30 def parameter_parsers; end - - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#19 - def return_only_media_type_on_content_type; end - - # source://actionpack//lib/action_dispatch/http/mime_negotiation.rb#19 - def return_only_media_type_on_content_type=(val); end end end -# source://actionpack//lib/action_dispatch/http/request.rb#297 +# source://actionpack//lib/action_dispatch/http/request.rb#313 ActionDispatch::Request::ACTION_DISPATCH_REQUEST_ID = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/request.rb#34 +# source://actionpack//lib/action_dispatch/http/request.rb#36 ActionDispatch::Request::ENV_METHODS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/http/request.rb#127 +# source://actionpack//lib/action_dispatch/http/request.rb#129 ActionDispatch::Request::HTTP_METHODS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/http/request.rb#129 +# source://actionpack//lib/action_dispatch/http/request.rb#131 ActionDispatch::Request::HTTP_METHOD_LOOKUP = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/request.rb#32 +# source://actionpack//lib/action_dispatch/http/request.rb#34 ActionDispatch::Request::LOCALHOST = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/request.rb#73 +# source://actionpack//lib/action_dispatch/http/request.rb#75 class ActionDispatch::Request::PASS_NOT_FOUND class << self - # source://actionpack//lib/action_dispatch/http/request.rb#74 + # source://actionpack//lib/action_dispatch/http/request.rb#76 def action(_); end - # source://actionpack//lib/action_dispatch/http/request.rb#76 + # source://actionpack//lib/action_dispatch/http/request.rb#78 def action_encoding_template(action); end - # source://actionpack//lib/action_dispatch/http/request.rb#75 + # source://actionpack//lib/action_dispatch/http/request.rb#77 def call(_); end end end -# HTTP methods from {RFC 2518: HTTP Extensions for Distributed Authoring -- WEBDAV}[https://www.ietf.org/rfc/rfc2518.txt] +# HTTP methods from [RFC 2518: HTTP Extensions for Distributed Authoring -- WEBDAV](https://www.ietf.org/rfc/rfc2518.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#113 +# source://actionpack//lib/action_dispatch/http/request.rb#115 ActionDispatch::Request::RFC2518 = T.let(T.unsafe(nil), Array) -# HTTP methods from {RFC 2616: Hypertext Transfer Protocol -- HTTP/1.1}[https://www.ietf.org/rfc/rfc2616.txt] +# HTTP methods from [RFC 2616: Hypertext Transfer Protocol -- HTTP/1.1](https://www.ietf.org/rfc/rfc2616.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#111 +# source://actionpack//lib/action_dispatch/http/request.rb#113 ActionDispatch::Request::RFC2616 = T.let(T.unsafe(nil), Array) -# HTTP methods from {RFC 3253: Versioning Extensions to WebDAV}[https://www.ietf.org/rfc/rfc3253.txt] +# HTTP methods from [RFC 3253: Versioning Extensions to WebDAV](https://www.ietf.org/rfc/rfc3253.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#115 +# source://actionpack//lib/action_dispatch/http/request.rb#117 ActionDispatch::Request::RFC3253 = T.let(T.unsafe(nil), Array) -# HTTP methods from {RFC 3648: WebDAV Ordered Collections Protocol}[https://www.ietf.org/rfc/rfc3648.txt] +# HTTP methods from [RFC 3648: WebDAV Ordered Collections Protocol](https://www.ietf.org/rfc/rfc3648.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#117 +# source://actionpack//lib/action_dispatch/http/request.rb#119 ActionDispatch::Request::RFC3648 = T.let(T.unsafe(nil), Array) -# HTTP methods from {RFC 3744: WebDAV Access Control Protocol}[https://www.ietf.org/rfc/rfc3744.txt] +# HTTP methods from [RFC 3744: WebDAV Access Control Protocol](https://www.ietf.org/rfc/rfc3744.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#119 +# source://actionpack//lib/action_dispatch/http/request.rb#121 ActionDispatch::Request::RFC3744 = T.let(T.unsafe(nil), Array) -# HTTP methods from {RFC 4791: Calendaring Extensions to WebDAV}[https://www.ietf.org/rfc/rfc4791.txt] +# HTTP methods from [RFC 4791: Calendaring Extensions to WebDAV](https://www.ietf.org/rfc/rfc4791.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#123 +# source://actionpack//lib/action_dispatch/http/request.rb#125 ActionDispatch::Request::RFC4791 = T.let(T.unsafe(nil), Array) -# HTTP methods from {RFC 5323: WebDAV SEARCH}[https://www.ietf.org/rfc/rfc5323.txt] +# HTTP methods from [RFC 5323: WebDAV SEARCH](https://www.ietf.org/rfc/rfc5323.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#121 +# source://actionpack//lib/action_dispatch/http/request.rb#123 ActionDispatch::Request::RFC5323 = T.let(T.unsafe(nil), Array) -# HTTP methods from {RFC 5789: PATCH Method for HTTP}[https://www.ietf.org/rfc/rfc5789.txt] +# HTTP methods from [RFC 5789: PATCH Method for HTTP](https://www.ietf.org/rfc/rfc5789.txt) # -# source://actionpack//lib/action_dispatch/http/request.rb#125 +# source://actionpack//lib/action_dispatch/http/request.rb#127 ActionDispatch::Request::RFC5789 = T.let(T.unsafe(nil), Array) # Session is responsible for lazily loading the session from store. # -# source://actionpack//lib/action_dispatch/request/session.rb#8 +# source://actionpack//lib/action_dispatch/request/session.rb#10 class ActionDispatch::Request::Session # @return [Session] a new instance of Session # - # source://actionpack//lib/action_dispatch/request/session.rb#74 + # source://actionpack//lib/action_dispatch/request/session.rb#76 def initialize(by, req, enabled: T.unsafe(nil)); end - # Returns value of the key stored in the session or - # +nil+ if the given key is not found in the session. + # Returns value of the key stored in the session or `nil` if the given key is + # not found in the session. # - # source://actionpack//lib/action_dispatch/request/session.rb#110 + # source://actionpack//lib/action_dispatch/request/session.rb#114 def [](key); end # Writes given value to given key of the session. # - # source://actionpack//lib/action_dispatch/request/session.rb#150 + # source://actionpack//lib/action_dispatch/request/session.rb#154 def []=(key, value); end # Clears the session. # - # source://actionpack//lib/action_dispatch/request/session.rb#156 + # source://actionpack//lib/action_dispatch/request/session.rb#160 def clear; end # Deletes given key from the session. # - # source://actionpack//lib/action_dispatch/request/session.rb#184 + # source://actionpack//lib/action_dispatch/request/session.rb#193 def delete(key); end - # source://actionpack//lib/action_dispatch/request/session.rb#95 + # source://actionpack//lib/action_dispatch/request/session.rb#99 def destroy; end - # Returns the nested value specified by the sequence of keys, returning - # +nil+ if any intermediate step is +nil+. + # Returns the nested value specified by the sequence of keys, returning `nil` if + # any intermediate step is `nil`. # - # source://actionpack//lib/action_dispatch/request/session.rb#123 + # source://actionpack//lib/action_dispatch/request/session.rb#127 def dig(*keys); end - # source://actionpack//lib/action_dispatch/request/session.rb#240 + # source://actionpack//lib/action_dispatch/request/session.rb#244 def each(&block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/request/session.rb#230 + # source://actionpack//lib/action_dispatch/request/session.rb#239 def empty?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/request/session.rb#87 + # source://actionpack//lib/action_dispatch/request/session.rb#91 def enabled?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/request/session.rb#220 + # source://actionpack//lib/action_dispatch/request/session.rb#229 def exists?; end - # Returns value of the given key from the session, or raises +KeyError+ - # if can't find the given key and no default value is set. - # Returns default value if specified. + # Returns value of the given key from the session, or raises `KeyError` if can't + # find the given key and no default value is set. Returns default value if + # specified. # - # session.fetch(:foo) - # # => KeyError: key not found: "foo" + # session.fetch(:foo) + # # => KeyError: key not found: "foo" # - # session.fetch(:foo, :bar) - # # => :bar + # session.fetch(:foo, :bar) + # # => :bar # - # session.fetch(:foo) do - # :bar - # end - # # => :bar + # session.fetch(:foo) do + # :bar + # end + # # => :bar # - # source://actionpack//lib/action_dispatch/request/session.rb#203 + # source://actionpack//lib/action_dispatch/request/session.rb#212 def fetch(key, default = T.unsafe(nil), &block); end # Returns true if the session has the given key or false. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/request/session.rb#130 + # source://actionpack//lib/action_dispatch/request/session.rb#134 def has_key?(key); end - # source://actionpack//lib/action_dispatch/request/session.rb#83 + # source://actionpack//lib/action_dispatch/request/session.rb#87 def id; end + # source://actionpack//lib/action_dispatch/request/session.rb#248 + def id_was; end + # Returns true if the session has the given key or false. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/request/session.rb#130 + # source://actionpack//lib/action_dispatch/request/session.rb#134 def include?(key); end - # source://actionpack//lib/action_dispatch/request/session.rb#212 + # source://actionpack//lib/action_dispatch/request/session.rb#221 def inspect; end # Returns true if the session has the given key or false. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/request/session.rb#130 + # source://actionpack//lib/action_dispatch/request/session.rb#134 def key?(key); end # Returns keys of the session as Array. # - # source://actionpack//lib/action_dispatch/request/session.rb#138 + # source://actionpack//lib/action_dispatch/request/session.rb#142 def keys; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/request/session.rb#226 + # source://actionpack//lib/action_dispatch/request/session.rb#235 def loaded?; end - # source://actionpack//lib/action_dispatch/request/session.rb#235 - def merge!(other); end + # Updates the session with given Hash. + # + # session.to_hash + # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2"} + # + # session.update({ "foo" => "bar" }) + # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2", "foo" => "bar"} + # + # session.to_hash + # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2", "foo" => "bar"} + # + # source://actionpack//lib/action_dispatch/request/session.rb#182 + def merge!(hash); end - # source://actionpack//lib/action_dispatch/request/session.rb#91 + # source://actionpack//lib/action_dispatch/request/session.rb#95 def options; end # Returns the session as Hash. # - # source://actionpack//lib/action_dispatch/request/session.rb#162 + # source://actionpack//lib/action_dispatch/request/session.rb#166 def to_h; end # Returns the session as Hash. # - # source://actionpack//lib/action_dispatch/request/session.rb#162 + # source://actionpack//lib/action_dispatch/request/session.rb#166 def to_hash; end # Updates the session with given Hash. # - # session.to_hash - # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2"} + # session.to_hash + # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2"} # - # session.update({ "foo" => "bar" }) - # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2", "foo" => "bar"} + # session.update({ "foo" => "bar" }) + # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2", "foo" => "bar"} # - # session.to_hash - # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2", "foo" => "bar"} + # session.to_hash + # # => {"session_id"=>"e29b9ea315edf98aad94cc78c34cc9b2", "foo" => "bar"} # - # source://actionpack//lib/action_dispatch/request/session.rb#178 + # source://actionpack//lib/action_dispatch/request/session.rb#182 def update(hash); end # Returns values of the session as Array. # - # source://actionpack//lib/action_dispatch/request/session.rb#144 + # source://actionpack//lib/action_dispatch/request/session.rb#148 def values; end private - # source://actionpack//lib/action_dispatch/request/session.rb#261 + # source://actionpack//lib/action_dispatch/request/session.rb#270 def load!; end - # source://actionpack//lib/action_dispatch/request/session.rb#257 + # source://actionpack//lib/action_dispatch/request/session.rb#266 def load_for_delete!; end - # source://actionpack//lib/action_dispatch/request/session.rb#245 + # source://actionpack//lib/action_dispatch/request/session.rb#254 def load_for_read!; end - # source://actionpack//lib/action_dispatch/request/session.rb#249 + # source://actionpack//lib/action_dispatch/request/session.rb#258 def load_for_write!; end class << self # Creates a session hash, merging the properties of the previous session if any. # - # source://actionpack//lib/action_dispatch/request/session.rb#17 + # source://actionpack//lib/action_dispatch/request/session.rb#19 def create(store, req, default_options); end - # source://actionpack//lib/action_dispatch/request/session.rb#41 + # source://actionpack//lib/action_dispatch/request/session.rb#43 def delete(req); end - # source://actionpack//lib/action_dispatch/request/session.rb#27 + # source://actionpack//lib/action_dispatch/request/session.rb#29 def disabled(req); end - # source://actionpack//lib/action_dispatch/request/session.rb#33 + # source://actionpack//lib/action_dispatch/request/session.rb#35 def find(req); end - # source://actionpack//lib/action_dispatch/request/session.rb#37 + # source://actionpack//lib/action_dispatch/request/session.rb#39 def set(req, session); end end end -# source://actionpack//lib/action_dispatch/request/session.rb#9 +# source://actionpack//lib/action_dispatch/request/session.rb#11 class ActionDispatch::Request::Session::DisabledSessionError < ::StandardError; end -# source://actionpack//lib/action_dispatch/request/session.rb#10 +# source://actionpack//lib/action_dispatch/request/session.rb#12 ActionDispatch::Request::Session::ENV_SESSION_KEY = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/request/session.rb#11 +# source://actionpack//lib/action_dispatch/request/session.rb#13 ActionDispatch::Request::Session::ENV_SESSION_OPTIONS_KEY = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/request/session.rb#45 +# source://actionpack//lib/action_dispatch/request/session.rb#47 class ActionDispatch::Request::Session::Options # @return [Options] a new instance of Options # - # source://actionpack//lib/action_dispatch/request/session.rb#54 + # source://actionpack//lib/action_dispatch/request/session.rb#56 def initialize(by, default_options); end - # source://actionpack//lib/action_dispatch/request/session.rb#59 + # source://actionpack//lib/action_dispatch/request/session.rb#61 def [](key); end - # source://actionpack//lib/action_dispatch/request/session.rb#69 + # source://actionpack//lib/action_dispatch/request/session.rb#71 def []=(k, v); end - # source://actionpack//lib/action_dispatch/request/session.rb#63 + # source://actionpack//lib/action_dispatch/request/session.rb#65 def id(req); end - # source://actionpack//lib/action_dispatch/request/session.rb#70 + # source://actionpack//lib/action_dispatch/request/session.rb#72 def to_hash; end - # source://actionpack//lib/action_dispatch/request/session.rb#71 + # source://actionpack//lib/action_dispatch/request/session.rb#73 def values_at(*args); end class << self - # source://actionpack//lib/action_dispatch/request/session.rb#50 + # source://actionpack//lib/action_dispatch/request/session.rb#52 def find(req); end - # source://actionpack//lib/action_dispatch/request/session.rb#46 + # source://actionpack//lib/action_dispatch/request/session.rb#48 def set(req, options); end end end # Singleton object used to determine if an optional param wasn't specified. # -# source://actionpack//lib/action_dispatch/request/session.rb#14 +# source://actionpack//lib/action_dispatch/request/session.rb#16 ActionDispatch::Request::Session::Unspecified = T.let(T.unsafe(nil), Object) -# source://actionpack//lib/action_dispatch/request/utils.rb#7 +# source://actionpack//lib/action_dispatch/request/utils.rb#9 class ActionDispatch::Request::Utils - # source://actionpack//lib/action_dispatch/request/utils.rb#8 + # source://actionpack//lib/action_dispatch/request/utils.rb#10 def perform_deep_munge; end - # source://actionpack//lib/action_dispatch/request/utils.rb#8 + # source://actionpack//lib/action_dispatch/request/utils.rb#10 def perform_deep_munge=(val); end class << self - # source://actionpack//lib/action_dispatch/request/utils.rb#29 + # source://actionpack//lib/action_dispatch/request/utils.rb#31 def check_param_encoding(params); end - # source://actionpack//lib/action_dispatch/request/utils.rb#10 + # source://actionpack//lib/action_dispatch/request/utils.rb#12 def each_param_value(params, &block); end - # source://actionpack//lib/action_dispatch/request/utils.rb#21 + # source://actionpack//lib/action_dispatch/request/utils.rb#23 def normalize_encode_params(params); end - # source://actionpack//lib/action_dispatch/request/utils.rb#8 + # source://actionpack//lib/action_dispatch/request/utils.rb#10 def perform_deep_munge; end - # source://actionpack//lib/action_dispatch/request/utils.rb#8 + # source://actionpack//lib/action_dispatch/request/utils.rb#10 def perform_deep_munge=(val); end - # source://actionpack//lib/action_dispatch/request/utils.rb#44 + # source://actionpack//lib/action_dispatch/request/utils.rb#46 def set_binary_encoding(request, params, controller, action); end end end -# source://actionpack//lib/action_dispatch/request/utils.rb#81 +# source://actionpack//lib/action_dispatch/request/utils.rb#85 class ActionDispatch::Request::Utils::CustomParamEncoder class << self - # source://actionpack//lib/action_dispatch/request/utils.rb#94 + # source://actionpack//lib/action_dispatch/request/utils.rb#101 def action_encoding_template(request, controller, action); end - # source://actionpack//lib/action_dispatch/request/utils.rb#82 + # source://actionpack//lib/action_dispatch/request/utils.rb#86 def encode(request, params, controller, action); end end end # Remove nils from the params hash. # -# source://actionpack//lib/action_dispatch/request/utils.rb#73 +# source://actionpack//lib/action_dispatch/request/utils.rb#77 class ActionDispatch::Request::Utils::NoNilParamEncoder < ::ActionDispatch::Request::Utils::ParamEncoder class << self - # source://actionpack//lib/action_dispatch/request/utils.rb#74 + # source://actionpack//lib/action_dispatch/request/utils.rb#78 def handle_array(params); end end end -# source://actionpack//lib/action_dispatch/request/utils.rb#48 +# source://actionpack//lib/action_dispatch/request/utils.rb#50 class ActionDispatch::Request::Utils::ParamEncoder class << self - # source://actionpack//lib/action_dispatch/request/utils.rb#67 + # source://actionpack//lib/action_dispatch/request/utils.rb#71 def handle_array(params); end # Convert nested Hash to HashWithIndifferentAccess. # - # source://actionpack//lib/action_dispatch/request/utils.rb#50 + # source://actionpack//lib/action_dispatch/request/utils.rb#52 def normalize_encode_params(params); end end end -# source://actionpack//lib/action_dispatch/middleware/cookies.rb#10 +# source://actionpack//lib/action_dispatch/middleware/cookies.rb#12 module ActionDispatch::RequestCookieMethods - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#48 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#50 def authenticated_encrypted_cookie_salt; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#11 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#13 def cookie_jar; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#28 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#30 def cookie_jar=(jar); end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#76 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#78 def cookies_digest; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#80 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#82 def cookies_rotations; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#72 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#74 def cookies_same_site_protection; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#68 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#70 def cookies_serializer; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#56 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#58 def encrypted_cookie_cipher; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#40 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#42 def encrypted_cookie_salt; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#44 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#46 def encrypted_signed_cookie_salt; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#24 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#26 def have_cookie_jar?; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#32 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#34 def key_generator; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#64 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#66 def secret_key_base; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#60 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#62 def signed_cookie_digest; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#36 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#38 def signed_cookie_salt; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#52 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#54 def use_authenticated_cookie_encryption; end - # source://actionpack//lib/action_dispatch/middleware/cookies.rb#84 + # source://actionpack//lib/action_dispatch/middleware/cookies.rb#86 def use_cookies_with_metadata; end end -# source://actionpack//lib/action_dispatch/testing/request_encoder.rb#4 +# source://actionpack//lib/action_dispatch/testing/request_encoder.rb#8 class ActionDispatch::RequestEncoder # @return [RequestEncoder] a new instance of RequestEncoder # - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#16 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#20 def initialize(mime_name, param_encoder, response_parser); end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#32 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#36 def accept_header; end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#28 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#32 def content_type; end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#36 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#40 def encode_params(params); end # Returns the value of attribute response_parser. # - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#14 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#18 def response_parser; end class << self - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#45 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#49 def encoder(name); end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#40 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#44 def parser(content_type); end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#49 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#53 def register_encoder(mime_name, param_encoder: T.unsafe(nil), response_parser: T.unsafe(nil)); end end end -# source://actionpack//lib/action_dispatch/testing/request_encoder.rb#5 +# source://actionpack//lib/action_dispatch/testing/request_encoder.rb#9 class ActionDispatch::RequestEncoder::IdentityEncoder - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#7 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#11 def accept_header; end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#6 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#10 def content_type; end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#8 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#12 def encode_params(params); end - # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#9 + # source://actionpack//lib/action_dispatch/testing/request_encoder.rb#13 def response_parser; end end -# Makes a unique request id available to the +action_dispatch.request_id+ env variable (which is then accessible -# through ActionDispatch::Request#request_id or the alias ActionDispatch::Request#uuid) and sends -# the same id to the client via the +X-Request-Id+ header. +# source://actionpack//lib/action_dispatch/testing/integration.rb#0 +class ActionDispatch::RequestEncoder::TurboStreamEncoder < ::ActionDispatch::RequestEncoder::IdentityEncoder + # source://turbo-rails/2.0.6/lib/turbo/engine.rb#122 + def accept_header; end +end + +# # Action Dispatch RequestId +# +# Makes a unique request id available to the `action_dispatch.request_id` env +# variable (which is then accessible through ActionDispatch::Request#request_id +# or the alias ActionDispatch::Request#uuid) and sends the same id to the client +# via the `X-Request-Id` header. # -# The unique request id is either based on the +X-Request-Id+ header in the request, which would typically be generated -# by a firewall, load balancer, or the web server, or, if this header is not available, a random uuid. If the -# header is accepted from the outside world, we sanitize it to a max of 255 chars and alphanumeric and dashes only. +# The unique request id is either based on the `X-Request-Id` header in the +# request, which would typically be generated by a firewall, load balancer, or +# the web server, or, if this header is not available, a random uuid. If the +# header is accepted from the outside world, we sanitize it to a max of 255 +# chars and alphanumeric and dashes only. # -# The unique request id can be used to trace a request end-to-end and would typically end up being part of log files -# from multiple pieces of the stack. +# The unique request id can be used to trace a request end-to-end and would +# typically end up being part of log files from multiple pieces of the stack. # -# source://actionpack//lib/action_dispatch/middleware/request_id.rb#17 +# source://actionpack//lib/action_dispatch/middleware/request_id.rb#24 class ActionDispatch::RequestId # @return [RequestId] a new instance of RequestId # - # source://actionpack//lib/action_dispatch/middleware/request_id.rb#18 + # source://actionpack//lib/action_dispatch/middleware/request_id.rb#25 def initialize(app, header:); end - # source://actionpack//lib/action_dispatch/middleware/request_id.rb#23 + # source://actionpack//lib/action_dispatch/middleware/request_id.rb#30 def call(env); end private - # source://actionpack//lib/action_dispatch/middleware/request_id.rb#38 + # source://actionpack//lib/action_dispatch/middleware/request_id.rb#45 def internal_request_id; end - # source://actionpack//lib/action_dispatch/middleware/request_id.rb#30 + # source://actionpack//lib/action_dispatch/middleware/request_id.rb#37 def make_request_id(request_id); end end +# # Action Dispatch Response +# # Represents an HTTP response generated by a controller action. Use it to # retrieve the current state of the response, or customize the response. It can -# either represent a real HTTP response (i.e. one that is meant to be sent -# back to the web browser) or a TestResponse (i.e. one that is generated -# from integration tests). -# -# \Response is mostly a Ruby on \Rails framework implementation detail, and -# should never be used directly in controllers. Controllers should use the -# methods defined in ActionController::Base instead. For example, if you want -# to set the HTTP response's content MIME type, then use -# ActionControllerBase#headers instead of Response#headers. -# -# Nevertheless, integration tests may want to inspect controller responses in -# more detail, and that's when \Response can be useful for application -# developers. Integration test methods such as -# Integration::RequestHelpers#get and Integration::RequestHelpers#post return -# objects of type TestResponse (which are of course also of type \Response). +# either represent a real HTTP response (i.e. one that is meant to be sent back +# to the web browser) or a TestResponse (i.e. one that is generated from +# integration tests). +# +# The Response object for the current request is exposed on controllers as +# ActionController::Metal#response. ActionController::Metal also provides a few +# additional methods that delegate to attributes of the Response such as +# ActionController::Metal#headers. +# +# Integration tests will likely also want to inspect responses in more detail. +# Methods such as Integration::RequestHelpers#get and +# Integration::RequestHelpers#post return instances of TestResponse (which +# inherits from Response) for this purpose. # # For example, the following demo integration test prints the body of the # controller response to the console: # -# class DemoControllerTest < ActionDispatch::IntegrationTest -# def test_print_root_path_to_console -# get('/') -# puts response.body -# end -# end +# class DemoControllerTest < ActionDispatch::IntegrationTest +# def test_print_root_path_to_console +# get('/') +# puts response.body +# end +# end # -# source://actionpack//lib/action_dispatch/http/response.rb#36 +# source://actionpack//lib/action_dispatch/http/response.rb#38 class ActionDispatch::Response include ::Rack::Response::Helpers include ::ActionDispatch::Http::FilterRedirect @@ -14725,346 +15780,378 @@ class ActionDispatch::Response # @yield [_self] # @yieldparam _self [ActionDispatch::Response] the object that the method was called on # - # source://actionpack//lib/action_dispatch/http/response.rb#161 - def initialize(status = T.unsafe(nil), header = T.unsafe(nil), body = T.unsafe(nil)); end + # source://actionpack//lib/action_dispatch/http/response.rb#171 + def initialize(status = T.unsafe(nil), headers = T.unsafe(nil), body = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/response.rb#71 + # source://actionpack//lib/action_dispatch/http/response.rb#75 def [](*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/http/response.rb#71 + # source://actionpack//lib/action_dispatch/http/response.rb#75 def []=(*_arg0, **_arg1, &_arg2); end # Aliasing these off because AD::Http::Cache::Response defines them. # - # source://rack/2.2.7/lib/rack/response.rb#229 + # source://rack/2.2.9/lib/rack/response.rb#229 def _cache_control; end - # source://rack/2.2.7/lib/rack/response.rb#233 + # source://rack/2.2.9/lib/rack/response.rb#233 def _cache_control=(v); end - # source://actionpack//lib/action_dispatch/http/response.rb#370 + # source://actionpack//lib/action_dispatch/http/response.rb#396 def abort; end - # source://actionpack//lib/action_dispatch/http/response.rb#183 + # source://actionpack//lib/action_dispatch/http/response.rb#197 def await_commit; end - # source://actionpack//lib/action_dispatch/http/response.rb#189 + # source://actionpack//lib/action_dispatch/http/response.rb#203 def await_sent; end - # Returns the content of the response as a string. This contains the contents - # of any calls to render. + # Returns the content of the response as a string. This contains the contents of + # any calls to `render`. # - # source://actionpack//lib/action_dispatch/http/response.rb#304 + # source://actionpack//lib/action_dispatch/http/response.rb#330 def body; end # Allows you to manually set or override the response body. # - # source://actionpack//lib/action_dispatch/http/response.rb#313 + # source://actionpack//lib/action_dispatch/http/response.rb#339 def body=(body); end - # source://actionpack//lib/action_dispatch/http/response.rb#357 + # source://actionpack//lib/action_dispatch/http/response.rb#383 def body_parts; end - # The charset of the response. HTML wants to know the encoding of the - # content you're giving them, so we need to send that along. + # The charset of the response. HTML wants to know the encoding of the content + # you're giving them, so we need to send that along. # - # source://actionpack//lib/action_dispatch/http/response.rb#274 + # source://actionpack//lib/action_dispatch/http/response.rb#300 def charset; end - # Sets the HTTP character set. In case of +nil+ parameter - # it sets the charset to +default_charset+. + # Sets the HTTP character set. In case of `nil` parameter it sets the charset to + # `default_charset`. # - # response.charset = 'utf-16' # => 'utf-16' - # response.charset = nil # => 'utf-8' + # response.charset = 'utf-16' # => 'utf-16' + # response.charset = nil # => 'utf-8' # - # source://actionpack//lib/action_dispatch/http/response.rb#263 + # source://actionpack//lib/action_dispatch/http/response.rb#289 def charset=(charset); end - # source://actionpack//lib/action_dispatch/http/response.rb#366 + # source://actionpack//lib/action_dispatch/http/response.rb#392 def close; end - # Returns a string to ensure compatibility with Net::HTTPResponse. + # Returns a string to ensure compatibility with `Net::HTTPResponse`. # - # source://actionpack//lib/action_dispatch/http/response.rb#285 + # source://actionpack//lib/action_dispatch/http/response.rb#311 def code; end - # source://actionpack//lib/action_dispatch/http/response.rb#193 + # source://actionpack//lib/action_dispatch/http/response.rb#207 def commit!; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/response.rb#217 + # source://actionpack//lib/action_dispatch/http/response.rb#231 def committed?; end # Content type of response. # - # source://actionpack//lib/action_dispatch/http/response.rb#243 + # source://actionpack//lib/action_dispatch/http/response.rb#269 def content_type; end - # Sets the HTTP response's content MIME type. For example, in the controller - # you could write this: + # Sets the HTTP response's content MIME type. For example, in the controller you + # could write this: # - # response.content_type = "text/plain" + # response.content_type = "text/plain" # - # If a character set has been defined for this response (see charset=) then - # the character set information will also be included in the content type + # If a character set has been defined for this response (see #charset=) then the + # character set information will also be included in the content type # information. # - # source://actionpack//lib/action_dispatch/http/response.rb#233 + # source://actionpack//lib/action_dispatch/http/response.rb#259 def content_type=(content_type); end # Returns the response cookies, converted to a Hash of (name => value) pairs # - # assert_equal 'AuthorOfNewPage', r.cookies['author'] + # assert_equal 'AuthorOfNewPage', r.cookies['author'] # - # source://actionpack//lib/action_dispatch/http/response.rb#394 + # source://actionpack//lib/action_dispatch/http/response.rb#419 def cookies; end - # source://actionpack//lib/action_dispatch/http/response.rb#85 + # source://actionpack//lib/action_dispatch/http/response.rb#88 def default_charset; end - # source://actionpack//lib/action_dispatch/http/response.rb#85 + # source://actionpack//lib/action_dispatch/http/response.rb#88 def default_charset=(val); end - # source://actionpack//lib/action_dispatch/http/response.rb#86 + # source://actionpack//lib/action_dispatch/http/response.rb#89 def default_headers; end - # source://actionpack//lib/action_dispatch/http/response.rb#86 + # source://actionpack//lib/action_dispatch/http/response.rb#89 def default_headers=(val); end - # source://actionpack//lib/action_dispatch/http/response.rb#181 + # source://actionpack//lib/action_dispatch/http/response.rb#195 def delete_header(key); end - # source://actionpack//lib/action_dispatch/http/response.rb#73 + # source://actionpack//lib/action_dispatch/http/response.rb#77 def each(&block); end - # source://actionpack//lib/action_dispatch/http/response.rb#179 + # source://actionpack//lib/action_dispatch/http/response.rb#193 def get_header(key); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/response.rb#178 + # source://actionpack//lib/action_dispatch/http/response.rb#192 def has_header?(key); end - # Get headers for this response. + # The headers for the response. + # + # header["Content-Type"] # => "text/plain" + # header["Content-Type"] = "application/json" + # header["Content-Type"] # => "application/json" + # + # Also aliased as `headers`. # - # source://actionpack//lib/action_dispatch/http/response.rb#67 + # headers["Content-Type"] # => "text/plain" + # headers["Content-Type"] = "application/json" + # headers["Content-Type"] # => "application/json" + # + # Also aliased as `header` for compatibility. + # + # source://actionpack//lib/action_dispatch/http/response.rb#71 def header; end - # Get headers for this response. + # The headers for the response. + # + # header["Content-Type"] # => "text/plain" + # header["Content-Type"] = "application/json" + # header["Content-Type"] # => "application/json" # - # source://actionpack//lib/action_dispatch/http/response.rb#67 + # Also aliased as `headers`. + # + # headers["Content-Type"] # => "text/plain" + # headers["Content-Type"] = "application/json" + # headers["Content-Type"] # => "application/json" + # + # Also aliased as `header` for compatibility. + # + # source://actionpack//lib/action_dispatch/http/response.rb#71 def headers; end # Media type of response. # - # source://actionpack//lib/action_dispatch/http/response.rb#248 + # source://actionpack//lib/action_dispatch/http/response.rb#274 def media_type; end # Returns the corresponding message for the current HTTP status code: # - # response.status = 200 - # response.message # => "OK" + # response.status = 200 + # response.message # => "OK" # - # response.status = 404 - # response.message # => "Not Found" + # response.status = 404 + # response.message # => "Not Found" # - # source://actionpack//lib/action_dispatch/http/response.rb#297 + # source://actionpack//lib/action_dispatch/http/response.rb#323 def message; end - # Turns the Response into a Rack-compatible array of the status, headers, - # and body. Allows explicit splatting: + # Turns the Response into a Rack-compatible array of the status, headers, and + # body. Allows explicit splatting: # - # status, headers, body = *response + # status, headers, body = *response # - # source://actionpack//lib/action_dispatch/http/response.rb#385 + # source://actionpack//lib/action_dispatch/http/response.rb#410 def prepare!; end # The location header we'll be responding with. # - # source://rack/2.2.7/lib/rack/response.rb#204 + # source://rack/2.2.9/lib/rack/response.rb#204 def redirect_url; end # The request that the response is responding to. # - # source://actionpack//lib/action_dispatch/http/response.rb#61 + # source://actionpack//lib/action_dispatch/http/response.rb#53 def request; end # The request that the response is responding to. # - # source://actionpack//lib/action_dispatch/http/response.rb#61 + # source://actionpack//lib/action_dispatch/http/response.rb#53 def request=(_arg0); end - # source://actionpack//lib/action_dispatch/http/response.rb#353 + # source://actionpack//lib/action_dispatch/http/response.rb#379 def reset_body!; end # The response code of the request. # - # source://actionpack//lib/action_dispatch/http/response.rb#280 + # source://actionpack//lib/action_dispatch/http/response.rb#306 def response_code; end - # Send the file stored at +path+ as the response body. + # Send the file stored at `path` as the response body. # - # source://actionpack//lib/action_dispatch/http/response.rb#348 + # source://actionpack//lib/action_dispatch/http/response.rb#374 def send_file(path); end - # source://actionpack//lib/action_dispatch/http/response.rb#201 + # source://actionpack//lib/action_dispatch/http/response.rb#215 def sending!; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/response.rb#216 + # source://actionpack//lib/action_dispatch/http/response.rb#230 def sending?; end - # source://actionpack//lib/action_dispatch/http/response.rb#252 + # source://actionpack//lib/action_dispatch/http/response.rb#278 def sending_file=(v); end - # source://actionpack//lib/action_dispatch/http/response.rb#209 + # source://actionpack//lib/action_dispatch/http/response.rb#223 def sent!; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/response.rb#218 + # source://actionpack//lib/action_dispatch/http/response.rb#232 def sent?; end - # source://actionpack//lib/action_dispatch/http/response.rb#180 + # source://actionpack//lib/action_dispatch/http/response.rb#194 def set_header(key, v); end # The HTTP status code. # - # source://actionpack//lib/action_dispatch/http/response.rb#64 + # source://actionpack//lib/action_dispatch/http/response.rb#56 def status; end # Sets the HTTP status code. # - # source://actionpack//lib/action_dispatch/http/response.rb#221 + # source://actionpack//lib/action_dispatch/http/response.rb#247 def status=(status); end # Returns the corresponding message for the current HTTP status code: # - # response.status = 200 - # response.message # => "OK" + # response.status = 200 + # response.message # => "OK" # - # response.status = 404 - # response.message # => "Not Found" + # response.status = 404 + # response.message # => "Not Found" # - # source://actionpack//lib/action_dispatch/http/response.rb#297 + # source://actionpack//lib/action_dispatch/http/response.rb#323 def status_message; end # The underlying body, as a streamable object. # - # source://actionpack//lib/action_dispatch/http/response.rb#159 + # source://actionpack//lib/action_dispatch/http/response.rb#169 def stream; end - # Turns the Response into a Rack-compatible array of the status, headers, - # and body. Allows explicit splatting: + # Turns the Response into a Rack-compatible array of the status, headers, and + # body. Allows explicit splatting: # - # status, headers, body = *response + # status, headers, body = *response # - # source://actionpack//lib/action_dispatch/http/response.rb#385 + # source://actionpack//lib/action_dispatch/http/response.rb#410 def to_a; end - # source://actionpack//lib/action_dispatch/http/response.rb#308 + # source://actionpack//lib/action_dispatch/http/response.rb#334 def write(string); end private - # source://actionpack//lib/action_dispatch/http/response.rb#466 + # source://actionpack//lib/action_dispatch/http/response.rb#489 def assign_default_content_type_and_charset!; end - # source://actionpack//lib/action_dispatch/http/response.rb#438 + # source://actionpack//lib/action_dispatch/http/response.rb#463 def before_committed; end - # source://actionpack//lib/action_dispatch/http/response.rb#446 + # source://actionpack//lib/action_dispatch/http/response.rb#471 def before_sending; end - # source://actionpack//lib/action_dispatch/http/response.rb#458 + # source://actionpack//lib/action_dispatch/http/response.rb#481 def build_buffer(response, body); end - # source://actionpack//lib/action_dispatch/http/response.rb#506 + # source://actionpack//lib/action_dispatch/http/response.rb#539 def handle_no_content!; end - # source://actionpack//lib/action_dispatch/http/response.rb#462 + # source://actionpack//lib/action_dispatch/http/response.rb#485 def munge_body_object(body); end - # source://actionpack//lib/action_dispatch/http/response.rb#418 + # source://actionpack//lib/action_dispatch/http/response.rb#443 def parse_content_type(content_type); end # Small internal convenience method to get the parsed version of the current # content type header. # - # source://actionpack//lib/action_dispatch/http/response.rb#428 + # source://actionpack//lib/action_dispatch/http/response.rb#453 def parsed_content_type_header; end - # source://actionpack//lib/action_dispatch/http/response.rb#513 - def rack_response(status, header); end + # source://actionpack//lib/action_dispatch/http/response.rb#546 + def rack_response(status, headers); end - # source://actionpack//lib/action_dispatch/http/response.rb#432 + # source://actionpack//lib/action_dispatch/http/response.rb#457 def set_content_type(content_type, charset); end class << self - # source://actionpack//lib/action_dispatch/http/response.rb#149 - def create(status = T.unsafe(nil), header = T.unsafe(nil), body = T.unsafe(nil), default_headers: T.unsafe(nil)); end + # source://actionpack//lib/action_dispatch/http/response.rb#159 + def create(status = T.unsafe(nil), headers = T.unsafe(nil), body = T.unsafe(nil), default_headers: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/response.rb#85 + # source://actionpack//lib/action_dispatch/http/response.rb#88 def default_charset; end - # source://actionpack//lib/action_dispatch/http/response.rb#85 + # source://actionpack//lib/action_dispatch/http/response.rb#88 def default_charset=(val); end - # source://actionpack//lib/action_dispatch/http/response.rb#86 + # source://actionpack//lib/action_dispatch/http/response.rb#89 def default_headers; end - # source://actionpack//lib/action_dispatch/http/response.rb#86 + # source://actionpack//lib/action_dispatch/http/response.rb#89 def default_headers=(val); end - # source://actionpack//lib/action_dispatch/http/response.rb#154 + # source://actionpack//lib/action_dispatch/http/response.rb#164 def merge_default_headers(original, default); end end end -# source://actionpack//lib/action_dispatch/http/response.rb#97 +# source://actionpack//lib/action_dispatch/http/response.rb#100 class ActionDispatch::Response::Buffer # @return [Buffer] a new instance of Buffer # - # source://actionpack//lib/action_dispatch/http/response.rb#98 + # source://actionpack//lib/action_dispatch/http/response.rb#101 def initialize(response, buf); end - # source://actionpack//lib/action_dispatch/http/response.rb#131 + # @raise [IOError] + # + # source://actionpack//lib/action_dispatch/http/response.rb#122 + def <<(string); end + + # source://actionpack//lib/action_dispatch/http/response.rb#141 def abort; end - # source://actionpack//lib/action_dispatch/http/response.rb#105 + # source://actionpack//lib/action_dispatch/http/response.rb#114 def body; end - # source://actionpack//lib/action_dispatch/http/response.rb#134 + # source://actionpack//lib/action_dispatch/http/response.rb#144 def close; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/response.rb#139 + # source://actionpack//lib/action_dispatch/http/response.rb#149 def closed?; end - # source://actionpack//lib/action_dispatch/http/response.rb#121 + # source://actionpack//lib/action_dispatch/http/response.rb#131 def each(&block); end + # source://actionpack//lib/action_dispatch/http/response.rb#108 + def to_ary; end + # @raise [IOError] # - # source://actionpack//lib/action_dispatch/http/response.rb#113 + # source://actionpack//lib/action_dispatch/http/response.rb#122 def write(string); end private - # source://actionpack//lib/action_dispatch/http/response.rb#144 + # source://actionpack//lib/action_dispatch/http/response.rb#154 def each_chunk(&block); end end -# source://actionpack//lib/action_dispatch/http/response.rb#80 +# source://actionpack//lib/action_dispatch/http/response.rb#84 ActionDispatch::Response::CONTENT_TYPE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/response.rb#412 +# source://actionpack//lib/action_dispatch/http/response.rb#437 ActionDispatch::Response::CONTENT_TYPE_PARSER = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/http/response.rb#409 +# source://actionpack//lib/action_dispatch/http/response.rb#434 class ActionDispatch::Response::ContentTypeHeader < ::Struct # Returns the value of attribute charset # @@ -15097,460 +16184,466 @@ class ActionDispatch::Response::ContentTypeHeader < ::Struct end end -# Avoid having to pass an open file handle as the response body. -# Rack::Sendfile will usually intercept the response and uses -# the path directly, so there is no reason to open the file. +# Avoid having to pass an open file handle as the response body. Rack::Sendfile +# will usually intercept the response and uses the path directly, so there is no +# reason to open the file. # -# source://actionpack//lib/action_dispatch/http/response.rb#326 +# source://actionpack//lib/action_dispatch/http/response.rb#352 class ActionDispatch::Response::FileBody # @return [FileBody] a new instance of FileBody # - # source://actionpack//lib/action_dispatch/http/response.rb#329 + # source://actionpack//lib/action_dispatch/http/response.rb#355 def initialize(path); end - # source://actionpack//lib/action_dispatch/http/response.rb#333 + # source://actionpack//lib/action_dispatch/http/response.rb#359 def body; end # Stream the file's contents if Rack::Sendfile isn't present. # - # source://actionpack//lib/action_dispatch/http/response.rb#338 + # source://actionpack//lib/action_dispatch/http/response.rb#364 def each; end - # source://actionpack//lib/action_dispatch/http/response.rb#327 + # source://actionpack//lib/action_dispatch/http/response.rb#353 def to_path; end end -# source://actionpack//lib/action_dispatch/http/response.rb#37 -class ActionDispatch::Response::Header - # @return [Header] a new instance of Header - # - # source://actionpack//lib/action_dispatch/http/response.rb#38 - def initialize(response, header); end - - # source://actionpack//lib/action_dispatch/http/response.rb#43 - def []=(k, v); end - - # source://actionpack//lib/action_dispatch/http/response.rb#51 - def merge(other); end - - # source://actionpack//lib/action_dispatch/http/response.rb#55 - def to_hash; end -end +# To be deprecated: +# +# source://actionpack//lib/action_dispatch/http/response.rb#50 +ActionDispatch::Response::Header = Rack::Utils::HeaderHash -# source://actionpack//lib/action_dispatch/http/response.rb#82 -ActionDispatch::Response::LOCATION = T.let(T.unsafe(nil), String) +# source://actionpack//lib/action_dispatch/http/response.rb#46 +ActionDispatch::Response::Headers = Rack::Utils::HeaderHash -# source://actionpack//lib/action_dispatch/http/response.rb#83 +# source://actionpack//lib/action_dispatch/http/response.rb#86 ActionDispatch::Response::NO_CONTENT_CODES = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/http/response.rb#410 +# source://actionpack//lib/action_dispatch/http/response.rb#435 ActionDispatch::Response::NullContentTypeHeader = T.let(T.unsafe(nil), ActionDispatch::Response::ContentTypeHeader) -# source://actionpack//lib/action_dispatch/http/response.rb#474 +# source://actionpack//lib/action_dispatch/http/response.rb#497 class ActionDispatch::Response::RackBody # @return [RackBody] a new instance of RackBody # - # source://actionpack//lib/action_dispatch/http/response.rb#475 + # source://actionpack//lib/action_dispatch/http/response.rb#498 def initialize(response); end - # source://actionpack//lib/action_dispatch/http/response.rb#489 + # source://actionpack//lib/action_dispatch/http/response.rb#508 def body; end - # source://actionpack//lib/action_dispatch/http/response.rb#483 + # source://actionpack//lib/action_dispatch/http/response.rb#530 + def call(*arguments, &block); end + + # source://actionpack//lib/action_dispatch/http/response.rb#502 def close; end - # source://actionpack//lib/action_dispatch/http/response.rb#479 + # source://actionpack//lib/action_dispatch/http/response.rb#526 def each(*args, &block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/response.rb#493 + # source://actionpack//lib/action_dispatch/http/response.rb#514 def respond_to?(method, include_private = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/response.rb#501 + # source://actionpack//lib/action_dispatch/http/response.rb#522 + def to_ary; end + + # source://actionpack//lib/action_dispatch/http/response.rb#534 def to_path; end end -# source://actionpack//lib/action_dispatch/http/response.rb#81 +# source://actionpack//lib/action_dispatch/http/response.rb#512 +ActionDispatch::Response::RackBody::BODY_METHODS = T.let(T.unsafe(nil), Hash) + +# source://actionpack//lib/action_dispatch/http/response.rb#85 ActionDispatch::Response::SET_COOKIE = T.let(T.unsafe(nil), String) # The routing module provides URL rewriting in native Ruby. It's a way to # redirect incoming requests to controllers and actions. This replaces -# mod_rewrite rules. Best of all, Rails' \Routing works with any web server. -# Routes are defined in config/routes.rb. +# mod_rewrite rules. Best of all, Rails' Routing works with any web server. +# Routes are defined in `config/routes.rb`. # # Think of creating routes as drawing a map for your requests. The map tells # them where to go based on some predefined pattern: # -# Rails.application.routes.draw do -# Pattern 1 tells some request to go to one place -# Pattern 2 tell them to go to another -# ... -# end +# Rails.application.routes.draw do +# Pattern 1 tells some request to go to one place +# Pattern 2 tell them to go to another +# ... +# end # # The following symbols are special: # -# :controller maps to your controller name -# :action maps to an action with your controllers +# :controller maps to your controller name +# :action maps to an action with your controllers # -# Other names simply map to a parameter as in the case of :id. +# Other names simply map to a parameter as in the case of `:id`. # -# == Resources +# ## Resources # -# Resource routing allows you to quickly declare all of the common routes -# for a given resourceful controller. Instead of declaring separate routes -# for your +index+, +show+, +new+, +edit+, +create+, +update+, and +destroy+ -# actions, a resourceful route declares them in a single line of code: +# Resource routing allows you to quickly declare all of the common routes for a +# given resourceful controller. Instead of declaring separate routes for your +# `index`, `show`, `new`, `edit`, `create`, `update`, and `destroy` actions, a +# resourceful route declares them in a single line of code: # -# resources :photos +# resources :photos # -# Sometimes, you have a resource that clients always look up without -# referencing an ID. A common example, /profile always shows the profile of -# the currently logged in user. In this case, you can use a singular resource -# to map /profile (rather than /profile/:id) to the show action. +# Sometimes, you have a resource that clients always look up without referencing +# an ID. A common example, /profile always shows the profile of the currently +# logged in user. In this case, you can use a singular resource to map /profile +# (rather than /profile/:id) to the show action. # -# resource :profile +# resource :profile # -# It's common to have resources that are logically children of other -# resources: +# It's common to have resources that are logically children of other resources: # -# resources :magazines do -# resources :ads -# end +# resources :magazines do +# resources :ads +# end # # You may wish to organize groups of controllers under a namespace. Most -# commonly, you might group a number of administrative controllers under -# an +admin+ namespace. You would place these controllers under the -# app/controllers/admin directory, and you can group them together -# in your router: +# commonly, you might group a number of administrative controllers under an +# `admin` namespace. You would place these controllers under the +# `app/controllers/admin` directory, and you can group them together in your +# router: # -# namespace "admin" do -# resources :posts, :comments -# end +# namespace "admin" do +# resources :posts, :comments +# end # # Alternatively, you can add prefixes to your path without using a separate -# directory by using +scope+. +scope+ takes additional options which -# apply to all enclosed routes. +# directory by using `scope`. `scope` takes additional options which apply to +# all enclosed routes. # -# scope path: "/cpanel", as: 'admin' do -# resources :posts, :comments -# end +# scope path: "/cpanel", as: 'admin' do +# resources :posts, :comments +# end # # For more, see Routing::Mapper::Resources#resources, # Routing::Mapper::Scoping#namespace, and Routing::Mapper::Scoping#scope. # -# == Non-resourceful routes +# ## Non-resourceful routes # -# For routes that don't fit the resources mold, you can use the HTTP helper -# methods get, post, patch, put and delete. +# For routes that don't fit the `resources` mold, you can use the HTTP helper +# methods `get`, `post`, `patch`, `put` and `delete`. # -# get 'post/:id', to: 'posts#show' -# post 'post/:id', to: 'posts#create_comment' +# get 'post/:id', to: 'posts#show' +# post 'post/:id', to: 'posts#create_comment' # -# Now, if you POST to /posts/:id, it will route to the create_comment action. A GET on the same -# URL will route to the show action. +# Now, if you POST to `/posts/:id`, it will route to the `create_comment` +# action. A GET on the same URL will route to the `show` action. # -# If your route needs to respond to more than one HTTP method (or all methods) then using the -# :via option on match is preferable. +# If your route needs to respond to more than one HTTP method (or all methods) +# then using the `:via` option on `match` is preferable. # -# match 'post/:id', to: 'posts#show', via: [:get, :post] +# match 'post/:id', to: 'posts#show', via: [:get, :post] # -# == Named routes +# ## Named routes # -# Routes can be named by passing an :as option, -# allowing for easy reference within your source as +name_of_route_url+ -# for the full URL and +name_of_route_path+ for the URI path. +# Routes can be named by passing an `:as` option, allowing for easy reference +# within your source as `name_of_route_url` for the full URL and +# `name_of_route_path` for the URI path. # # Example: # -# # In config/routes.rb -# get '/login', to: 'accounts#login', as: 'login' +# # In config/routes.rb +# get '/login', to: 'accounts#login', as: 'login' # -# # With render, redirect_to, tests, etc. -# redirect_to login_url +# # With render, redirect_to, tests, etc. +# redirect_to login_url # # Arguments can be passed as well. # -# redirect_to show_item_path(id: 25) +# redirect_to show_item_path(id: 25) # -# Use root as a shorthand to name a route for the root path "/". +# Use `root` as a shorthand to name a route for the root path "/". # -# # In config/routes.rb -# root to: 'blogs#index' +# # In config/routes.rb +# root to: 'blogs#index' # -# # would recognize http://www.example.com/ as -# params = { controller: 'blogs', action: 'index' } +# # would recognize http://www.example.com/ as +# params = { controller: 'blogs', action: 'index' } # -# # and provide these named routes -# root_url # => 'http://www.example.com/' -# root_path # => '/' +# # and provide these named routes +# root_url # => 'http://www.example.com/' +# root_path # => '/' # -# Note: when using +controller+, the route is simply named after the -# method you call on the block parameter rather than map. +# Note: when using `controller`, the route is simply named after the method you +# call on the block parameter rather than map. # -# # In config/routes.rb -# controller :blog do -# get 'blog/show', to: :list -# get 'blog/delete', to: :delete -# get 'blog/edit', to: :edit -# end +# # In config/routes.rb +# controller :blog do +# get 'blog/show' => :list +# get 'blog/delete' => :delete +# get 'blog/edit' => :edit +# end # -# # provides named routes for show, delete, and edit -# link_to @article.title, blog_show_path(id: @article.id) +# # provides named routes for show, delete, and edit +# link_to @article.title, blog_show_path(id: @article.id) # -# == Pretty URLs +# ## Pretty URLs # # Routes can generate pretty URLs. For example: # -# get '/articles/:year/:month/:day', to: 'articles#find_by_id', constraints: { -# year: /\d{4}/, -# month: /\d{1,2}/, -# day: /\d{1,2}/ -# } +# get '/articles/:year/:month/:day', to: 'articles#find_by_id', constraints: { +# year: /\d{4}/, +# month: /\d{1,2}/, +# day: /\d{1,2}/ +# } # # Using the route above, the URL "http://localhost:3000/articles/2005/11/06" # maps to # -# params = {year: '2005', month: '11', day: '06'} +# params = {year: '2005', month: '11', day: '06'} # -# == Regular Expressions and parameters +# ## Regular Expressions and parameters # You can specify a regular expression to define a format for a parameter. # -# controller 'geocode' do -# get 'geocode/:postalcode', to: :show, constraints: { -# postalcode: /\d{5}(-\d{4})?/ -# } -# end +# controller 'geocode' do +# get 'geocode/:postalcode', to: :show, constraints: { +# postalcode: /\d{5}(-\d{4})?/ +# } +# end # # Constraints can include the 'ignorecase' and 'extended syntax' regular # expression modifiers: # -# controller 'geocode' do -# get 'geocode/:postalcode', to: :show, constraints: { -# postalcode: /hx\d\d\s\d[a-z]{2}/i -# } -# end -# -# controller 'geocode' do -# get 'geocode/:postalcode', to: :show, constraints: { -# postalcode: /# Postalcode format -# \d{5} #Prefix -# (-\d{4})? #Suffix -# /x -# } -# end +# controller 'geocode' do +# get 'geocode/:postalcode', to: :show, constraints: { +# postalcode: /hx\d\d\s\d[a-z]{2}/i +# } +# end +# +# controller 'geocode' do +# get 'geocode/:postalcode', to: :show, constraints: { +# postalcode: /# Postalcode format +# \d{5} #Prefix +# (-\d{4})? #Suffix +# /x +# } +# end # -# Using the multiline modifier will raise an +ArgumentError+. -# Encoding regular expression modifiers are silently ignored. The -# match will always use the default encoding or ASCII. +# Using the multiline modifier will raise an `ArgumentError`. Encoding regular +# expression modifiers are silently ignored. The match will always use the +# default encoding or ASCII. # -# == External redirects +# ## External redirects # -# You can redirect any path to another path using the redirect helper in your router: +# You can redirect any path to another path using the redirect helper in your +# router: # -# get "/stories", to: redirect("/posts") +# get "/stories", to: redirect("/posts") # -# == Unicode character routes +# ## Unicode character routes # # You can specify unicode character routes in your router: # -# get "こんにちは", to: "welcome#index" +# get "こんにちは", to: "welcome#index" # -# == Routing to Rack Applications +# ## Routing to Rack Applications # -# Instead of a String, like posts#index, which corresponds to the -# index action in the PostsController, you can specify any Rack application -# as the endpoint for a matcher: +# Instead of a String, like `posts#index`, which corresponds to the index action +# in the PostsController, you can specify any Rack application as the endpoint +# for a matcher: # -# get "/application.js", to: Sprockets +# get "/application.js", to: Sprockets # -# == Reloading routes +# ## Reloading routes # # You can reload routes if you feel you must: # -# Rails.application.reload_routes! +# Rails.application.reload_routes! # -# This will clear all named routes and reload config/routes.rb if the file has been modified from -# last load. To absolutely force reloading, use reload!. +# This will clear all named routes and reload config/routes.rb if the file has +# been modified from last load. To absolutely force reloading, use `reload!`. # -# == Testing Routes +# ## Testing Routes # # The two main methods for testing your routes: # -# === +assert_routing+ +# ### `assert_routing` # -# def test_movie_route_properly_splits -# opts = {controller: "plugin", action: "checkout", id: "2"} -# assert_routing "plugin/checkout/2", opts -# end +# def test_movie_route_properly_splits +# opts = {controller: "plugin", action: "checkout", id: "2"} +# assert_routing "plugin/checkout/2", opts +# end # -# +assert_routing+ lets you test whether or not the route properly resolves into options. +# `assert_routing` lets you test whether or not the route properly resolves into +# options. # -# === +assert_recognizes+ +# ### `assert_recognizes` # -# def test_route_has_options -# opts = {controller: "plugin", action: "show", id: "12"} -# assert_recognizes opts, "/plugins/show/12" -# end +# def test_route_has_options +# opts = {controller: "plugin", action: "show", id: "12"} +# assert_recognizes opts, "/plugins/show/12" +# end # -# Note the subtle difference between the two: +assert_routing+ tests that -# a URL fits options while +assert_recognizes+ tests that a URL -# breaks into parameters properly. +# Note the subtle difference between the two: `assert_routing` tests that a URL +# fits options while `assert_recognizes` tests that a URL breaks into parameters +# properly. # -# In tests you can simply pass the URL or named route to +get+ or +post+. +# In tests you can simply pass the URL or named route to `get` or `post`. # -# def send_to_jail -# get '/jail' -# assert_response :success -# end +# def send_to_jail +# get '/jail' +# assert_response :success +# end # -# def goes_to_login -# get login_url -# #... -# end +# def goes_to_login +# get login_url +# #... +# end # -# == View a list of all your routes +# ## View a list of all your routes # -# rails routes +# $ bin/rails routes # -# Target a specific controller with -c, or grep routes -# using -g. Useful in conjunction with --expanded -# which displays routes vertically. +# Target a specific controller with `-c`, or grep routes using `-g`. Useful in +# conjunction with `--expanded` which displays routes vertically. # # source://actionpack//lib/action_dispatch/routing.rb#248 module ActionDispatch::Routing extend ::ActiveSupport::Autoload end -# source://actionpack//lib/action_dispatch/routing/inspector.rb#129 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#155 module ActionDispatch::Routing::ConsoleFormatter; end -# source://actionpack//lib/action_dispatch/routing/inspector.rb#130 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#156 class ActionDispatch::Routing::ConsoleFormatter::Base # @return [Base] a new instance of Base # - # source://actionpack//lib/action_dispatch/routing/inspector.rb#131 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#157 def initialize; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#145 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#171 def header(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#148 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#174 def no_routes(routes, filter); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#135 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#161 def result; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#142 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#168 def section(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#139 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#165 def section_title(title); end end -# source://actionpack//lib/action_dispatch/routing/inspector.rb#202 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#228 class ActionDispatch::Routing::ConsoleFormatter::Expanded < ::ActionDispatch::Routing::ConsoleFormatter::Base # @return [Expanded] a new instance of Expanded # - # source://actionpack//lib/action_dispatch/routing/inspector.rb#203 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#229 def initialize(width: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#212 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#238 def section(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#208 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#234 def section_title(title); end private - # source://actionpack//lib/action_dispatch/routing/inspector.rb#217 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#243 def draw_expanded_section(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#229 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#258 def route_header(index:); end end -# source://actionpack//lib/action_dispatch/routing/inspector.rb#166 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#192 class ActionDispatch::Routing::ConsoleFormatter::Sheet < ::ActionDispatch::Routing::ConsoleFormatter::Base - # source://actionpack//lib/action_dispatch/routing/inspector.rb#175 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#201 def header(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#171 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#197 def section(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#167 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#193 def section_title(title); end private - # source://actionpack//lib/action_dispatch/routing/inspector.rb#189 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#215 def draw_header(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#180 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#206 def draw_section(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#195 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#221 def widths(routes); end end -# source://actionpack//lib/action_dispatch/routing/endpoint.rb#5 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#263 +class ActionDispatch::Routing::ConsoleFormatter::Unused < ::ActionDispatch::Routing::ConsoleFormatter::Sheet + # source://actionpack//lib/action_dispatch/routing/inspector.rb#264 + def header(routes); end + + # source://actionpack//lib/action_dispatch/routing/inspector.rb#272 + def no_routes(routes, filter); end +end + +# source://actionpack//lib/action_dispatch/routing/endpoint.rb#7 class ActionDispatch::Routing::Endpoint - # source://actionpack//lib/action_dispatch/routing/endpoint.rb#9 + # source://actionpack//lib/action_dispatch/routing/endpoint.rb#11 def app; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/endpoint.rb#6 + # source://actionpack//lib/action_dispatch/routing/endpoint.rb#8 def dispatcher?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/endpoint.rb#12 + # source://actionpack//lib/action_dispatch/routing/endpoint.rb#14 def engine?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/endpoint.rb#8 + # source://actionpack//lib/action_dispatch/routing/endpoint.rb#10 def matches?(req); end - # source://actionpack//lib/action_dispatch/routing/endpoint.rb#10 + # source://actionpack//lib/action_dispatch/routing/endpoint.rb#12 def rack_app; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/endpoint.rb#7 + # source://actionpack//lib/action_dispatch/routing/endpoint.rb#9 def redirect?; end end -# source://actionpack//lib/action_dispatch/routing.rb#258 +# source://actionpack//lib/action_dispatch/routing.rb#260 ActionDispatch::Routing::HTTP_METHODS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/inspector.rb#235 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#285 class ActionDispatch::Routing::HtmlTableFormatter # @return [HtmlTableFormatter] a new instance of HtmlTableFormatter # - # source://actionpack//lib/action_dispatch/routing/inspector.rb#236 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#286 def initialize(view); end # The header is part of the HTML page, so we don't construct it here. # - # source://actionpack//lib/action_dispatch/routing/inspector.rb#250 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#300 def header(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#253 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#303 def no_routes(*_arg0); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#266 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#316 def result; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#245 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#295 def section(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#241 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#291 def section_title(title); end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#12 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#14 class ActionDispatch::Routing::Mapper include ::ActionDispatch::Routing::Mapper::Base include ::ActionDispatch::Routing::Mapper::HttpHelpers @@ -15562,2271 +16655,2312 @@ class ActionDispatch::Routing::Mapper # @return [Mapper] a new instance of Mapper # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2302 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2348 def initialize(set); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#363 + # source://devise/4.9.4/lib/devise/rails/routes.rb#363 def as(scope); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#290 + # source://devise/4.9.4/lib/devise/rails/routes.rb#290 def authenticate(scope = T.unsafe(nil), block = T.unsafe(nil)); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#314 + # source://devise/4.9.4/lib/devise/rails/routes.rb#314 def authenticated(scope = T.unsafe(nil), block = T.unsafe(nil)); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#226 + # source://devise/4.9.4/lib/devise/rails/routes.rb#226 def devise_for(*resources); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#363 + # source://devise/4.9.4/lib/devise/rails/routes.rb#363 def devise_scope(scope); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#331 + # source://devise/4.9.4/lib/devise/rails/routes.rb#331 def unauthenticated(scope = T.unsafe(nil)); end protected - # source://devise/4.9.2/lib/devise/rails/routes.rb#477 + # source://devise/4.9.4/lib/devise/rails/routes.rb#477 def constraints_for(method_to_apply, scope = T.unsafe(nil), block = T.unsafe(nil)); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#390 + # source://devise/4.9.4/lib/devise/rails/routes.rb#390 def devise_confirmation(mapping, controllers); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#421 + # source://devise/4.9.4/lib/devise/rails/routes.rb#421 def devise_omniauth_callback(mapping, controllers); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#385 + # source://devise/4.9.4/lib/devise/rails/routes.rb#385 def devise_password(mapping, controllers); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#402 + # source://devise/4.9.4/lib/devise/rails/routes.rb#402 def devise_registration(mapping, controllers); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#377 + # source://devise/4.9.4/lib/devise/rails/routes.rb#377 def devise_session(mapping, controllers); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#395 + # source://devise/4.9.4/lib/devise/rails/routes.rb#395 def devise_unlock(mapping, controllers); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#509 + # source://devise/4.9.4/lib/devise/rails/routes.rb#509 def raise_no_devise_method_error!(klass); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#499 + # source://devise/4.9.4/lib/devise/rails/routes.rb#499 def raise_no_secret_key; end - # source://devise/4.9.2/lib/devise/rails/routes.rb#488 + # source://devise/4.9.4/lib/devise/rails/routes.rb#488 def set_omniauth_path_prefix!(path_prefix); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#461 + # source://devise/4.9.4/lib/devise/rails/routes.rb#461 def with_devise_exclusive_scope(new_path, new_as, options); end class << self - # source://actionpack//lib/action_dispatch/routing/mapper.rb#381 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#27 + def backtrace_cleaner; end + + # source://actionpack//lib/action_dispatch/routing/mapper.rb#27 + def backtrace_cleaner=(val); end + + # source://actionpack//lib/action_dispatch/routing/mapper.rb#429 def normalize_name(name); end - # Invokes Journey::Router::Utils.normalize_path, then ensures that - # /(:locale) becomes (/:locale). Except for root cases, where the - # former is the correct one. + # Invokes Journey::Router::Utils.normalize_path, then ensures that /(:locale) + # becomes (/:locale). Except for root cases, where the former is the correct + # one. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#364 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#414 def normalize_path(path); end + + # source://actionpack//lib/action_dispatch/routing/mapper.rb#26 + def route_source_locations; end + + # source://actionpack//lib/action_dispatch/routing/mapper.rb#26 + def route_source_locations=(val); end end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#385 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#15 +class ActionDispatch::Routing::Mapper::BacktraceCleaner < ::ActiveSupport::BacktraceCleaner + # @return [BacktraceCleaner] a new instance of BacktraceCleaner + # + # source://actionpack//lib/action_dispatch/routing/mapper.rb#16 + def initialize; end +end + +# source://actionpack//lib/action_dispatch/routing/mapper.rb#433 module ActionDispatch::Routing::Mapper::Base - # source://actionpack//lib/action_dispatch/routing/mapper.rb#618 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#662 def default_url_options(options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#618 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#662 def default_url_options=(options); end # Query if the following named route was already defined. # # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#630 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#674 def has_named_route?(name); end # Matches a URL pattern to one or more routes. # - # You should not use the +match+ method in your router - # without specifying an HTTP method. + # You should not use the `match` method in your router without specifying an + # HTTP method. # # If you want to expose your action to both GET and POST, use: # - # # sets :controller, :action, and :id in params - # match ':controller/:action/:id', via: [:get, :post] + # # sets :controller, :action, and :id in params + # match ':controller/:action/:id', via: [:get, :post] # - # Note that +:controller+, +:action+, and +:id+ are interpreted as URL - # query parameters and thus available through +params+ in an action. + # Note that `:controller`, `:action`, and `:id` are interpreted as URL query + # parameters and thus available through `params` in an action. # - # If you want to expose your action to GET, use +get+ in the router: + # If you want to expose your action to GET, use `get` in the router: # # Instead of: # - # match ":controller/:action/:id" + # match ":controller/:action/:id" # # Do: # - # get ":controller/:action/:id" + # get ":controller/:action/:id" # - # Two of these symbols are special, +:controller+ maps to the controller - # and +:action+ to the controller's action. A pattern can also map - # wildcard segments (globs) to params: + # Two of these symbols are special, `:controller` maps to the controller and + # `:action` to the controller's action. A pattern can also map wildcard segments + # (globs) to params: # - # get 'songs/*category/:title', to: 'songs#show' + # get 'songs/*category/:title', to: 'songs#show' # - # # 'songs/rock/classic/stairway-to-heaven' sets - # # params[:category] = 'rock/classic' - # # params[:title] = 'stairway-to-heaven' + # # 'songs/rock/classic/stairway-to-heaven' sets + # # params[:category] = 'rock/classic' + # # params[:title] = 'stairway-to-heaven' # - # To match a wildcard parameter, it must have a name assigned to it. - # Without a variable name to attach the glob parameter to, the route - # can't be parsed. + # To match a wildcard parameter, it must have a name assigned to it. Without a + # variable name to attach the glob parameter to, the route can't be parsed. # - # When a pattern points to an internal route, the route's +:action+ and - # +:controller+ should be set in options or hash shorthand. Examples: + # When a pattern points to an internal route, the route's `:action` and + # `:controller` should be set in options or hash shorthand. Examples: # - # match 'photos/:id' => 'photos#show', via: :get - # match 'photos/:id', to: 'photos#show', via: :get - # match 'photos/:id', controller: 'photos', action: 'show', via: :get + # match 'photos/:id' => 'photos#show', via: :get + # match 'photos/:id', to: 'photos#show', via: :get + # match 'photos/:id', controller: 'photos', action: 'show', via: :get # - # A pattern can also point to a +Rack+ endpoint i.e. anything that - # responds to +call+: + # A pattern can also point to a `Rack` endpoint i.e. anything that responds to + # `call`: # - # match 'photos/:id', to: -> (hash) { [200, {}, ["Coming soon"]] }, via: :get - # match 'photos/:id', to: PhotoRackApp, via: :get - # # Yes, controller actions are just rack endpoints - # match 'photos/:id', to: PhotosController.action(:show), via: :get + # match 'photos/:id', to: -> (hash) { [200, {}, ["Coming soon"]] }, via: :get + # match 'photos/:id', to: PhotoRackApp, via: :get + # # Yes, controller actions are just rack endpoints + # match 'photos/:id', to: PhotosController.action(:show), via: :get # # Because requesting various HTTP verbs with a single action has security - # implications, you must either specify the actions in - # the via options or use one of the HttpHelpers[rdoc-ref:HttpHelpers] - # instead +match+ + # implications, you must either specify the actions in the via options or use + # one of the [HttpHelpers](rdoc-ref:HttpHelpers) instead `match` # - # === Options + # ### Options # # Any options not seen here are passed on as params with the URL. # - # [:controller] - # The route's controller. + # :controller + # : The route's controller. # - # [:action] - # The route's action. + # :action + # : The route's action. # - # [:param] - # Overrides the default resource identifier +:id+ (name of the - # dynamic segment used to generate the routes). - # You can access that segment from your controller using - # params[<:param>]. - # In your router: + # :param + # : Overrides the default resource identifier `:id` (name of the dynamic + # segment used to generate the routes). You can access that segment from + # your controller using `params[<:param>]`. In your router: # - # resources :users, param: :name + # resources :users, param: :name # - # The +users+ resource here will have the following routes generated for it: + # The `users` resource here will have the following routes generated for it: # - # GET /users(.:format) - # POST /users(.:format) - # GET /users/new(.:format) - # GET /users/:name/edit(.:format) - # GET /users/:name(.:format) - # PATCH/PUT /users/:name(.:format) - # DELETE /users/:name(.:format) + # GET /users(.:format) + # POST /users(.:format) + # GET /users/new(.:format) + # GET /users/:name/edit(.:format) + # GET /users/:name(.:format) + # PATCH/PUT /users/:name(.:format) + # DELETE /users/:name(.:format) # - # You can override ActiveRecord::Base#to_param of a related - # model to construct a URL: + # You can override `ActiveRecord::Base#to_param` of a related model to + # construct a URL: # - # class User < ActiveRecord::Base - # def to_param - # name - # end - # end + # class User < ActiveRecord::Base + # def to_param + # name + # end + # end # - # user = User.find_by(name: 'Phusion') - # user_path(user) # => "/users/Phusion" + # user = User.find_by(name: 'Phusion') + # user_path(user) # => "/users/Phusion" # - # [:path] - # The path prefix for the routes. + # :path + # : The path prefix for the routes. # - # [:module] - # The namespace for :controller. + # :module + # : The namespace for :controller. # - # match 'path', to: 'c#a', module: 'sekret', controller: 'posts', via: :get - # # => Sekret::PostsController + # match 'path', to: 'c#a', module: 'sekret', controller: 'posts', via: :get + # # => Sekret::PostsController # - # See Scoping#namespace for its scope equivalent. + # See `Scoping#namespace` for its scope equivalent. # - # [:as] - # The name used to generate routing helpers. + # :as + # : The name used to generate routing helpers. # - # [:via] - # Allowed HTTP verb(s) for route. + # :via + # : Allowed HTTP verb(s) for route. # - # match 'path', to: 'c#a', via: :get - # match 'path', to: 'c#a', via: [:get, :post] - # match 'path', to: 'c#a', via: :all + # match 'path', to: 'c#a', via: :get + # match 'path', to: 'c#a', via: [:get, :post] + # match 'path', to: 'c#a', via: :all # - # [:to] - # Points to a +Rack+ endpoint. Can be an object that responds to - # +call+ or a string representing a controller's action. + # :to + # : Points to a `Rack` endpoint. Can be an object that responds to `call` or a + # string representing a controller's action. # - # match 'path', to: 'controller#action', via: :get - # match 'path', to: -> (env) { [200, {}, ["Success!"]] }, via: :get - # match 'path', to: RackApp, via: :get + # match 'path', to: 'controller#action', via: :get + # match 'path', to: -> (env) { [200, {}, ["Success!"]] }, via: :get + # match 'path', to: RackApp, via: :get # - # [:on] - # Shorthand for wrapping routes in a specific RESTful context. Valid - # values are +:member+, +:collection+, and +:new+. Only use within - # resource(s) block. For example: + # :on + # : Shorthand for wrapping routes in a specific RESTful context. Valid values + # are `:member`, `:collection`, and `:new`. Only use within `resource(s)` + # block. For example: # - # resource :bar do - # match 'foo', to: 'c#a', on: :member, via: [:get, :post] - # end + # resource :bar do + # match 'foo', to: 'c#a', on: :member, via: [:get, :post] + # end # - # Is equivalent to: + # Is equivalent to: # - # resource :bar do - # member do - # match 'foo', to: 'c#a', via: [:get, :post] - # end - # end + # resource :bar do + # member do + # match 'foo', to: 'c#a', via: [:get, :post] + # end + # end # - # [:constraints] - # Constrains parameters with a hash of regular expressions - # or an object that responds to matches?. In addition, constraints - # other than path can also be specified with any object - # that responds to === (e.g. String, Array, Range, etc.). + # :constraints + # : Constrains parameters with a hash of regular expressions or an object that + # responds to `matches?`. In addition, constraints other than path can also + # be specified with any object that responds to `===` (e.g. String, Array, + # Range, etc.). # - # match 'path/:id', constraints: { id: /[A-Z]\d{5}/ }, via: :get + # match 'path/:id', constraints: { id: /[A-Z]\d{5}/ }, via: :get # - # match 'json_only', constraints: { format: 'json' }, via: :get + # match 'json_only', constraints: { format: 'json' }, via: :get # - # class PermitList - # def matches?(request) request.remote_ip == '1.2.3.4' end - # end - # match 'path', to: 'c#a', constraints: PermitList.new, via: :get + # class PermitList + # def matches?(request) request.remote_ip == '1.2.3.4' end + # end + # match 'path', to: 'c#a', constraints: PermitList.new, via: :get # - # See Scoping#constraints for more examples with its scope - # equivalent. + # See `Scoping#constraints` for more examples with its scope equivalent. # - # [:defaults] - # Sets defaults for parameters + # :defaults + # : Sets defaults for parameters # - # # Sets params[:format] to 'jpg' by default - # match 'path', to: 'c#a', defaults: { format: 'jpg' }, via: :get + # # Sets params[:format] to 'jpg' by default + # match 'path', to: 'c#a', defaults: { format: 'jpg' }, via: :get # - # See Scoping#defaults for its scope equivalent. + # See `Scoping#defaults` for its scope equivalent. # - # [:anchor] - # Boolean to anchor a match pattern. Default is true. When set to - # false, the pattern matches any request prefixed with the given path. + # :anchor + # : Boolean to anchor a `match` pattern. Default is true. When set to false, + # the pattern matches any request prefixed with the given path. # - # # Matches any request starting with 'path' - # match 'path', to: 'c#a', anchor: false, via: :get + # # Matches any request starting with 'path' + # match 'path', to: 'c#a', anchor: false, via: :get # - # [:format] - # Allows you to specify the default value for optional +format+ - # segment or disable it by supplying +false+. + # :format + # : Allows you to specify the default value for optional `format` segment or + # disable it by supplying `false`. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#566 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#610 def match(path, options = T.unsafe(nil)); end # Mount a Rack-based application to be used within the application. # - # mount SomeRackApp, at: "some_route" + # mount SomeRackApp, at: "some_route" # # Alternatively: # - # mount(SomeRackApp => "some_route") + # mount(SomeRackApp => "some_route") # - # For options, see +match+, as +mount+ uses it internally. + # For options, see `match`, as `mount` uses it internally. # - # All mounted applications come with routing helpers to access them. - # These are named after the class specified, so for the above example - # the helper is either +some_rack_app_path+ or +some_rack_app_url+. - # To customize this helper's name, use the +:as+ option: + # All mounted applications come with routing helpers to access them. These are + # named after the class specified, so for the above example the helper is either + # `some_rack_app_path` or `some_rack_app_url`. To customize this helper's name, + # use the `:as` option: # - # mount(SomeRackApp => "some_route", as: "exciting") + # mount(SomeRackApp => "some_route", as: "exciting") # - # This will generate the +exciting_path+ and +exciting_url+ helpers - # which can be used to navigate to this mounted app. + # This will generate the `exciting_path` and `exciting_url` helpers which can be + # used to navigate to this mounted app. # # @raise [ArgumentError] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#588 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#632 def mount(app, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#623 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#667 def with_default_scope(scope, &block); end private - # source://actionpack//lib/action_dispatch/routing/mapper.rb#639 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#683 def app_name(app, rails_app); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#648 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#692 def define_generate_prefix(app, name); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#635 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#679 def rails_app?(app); end end -# Routing Concerns allow you to declare common routes that can be reused -# inside others resources and routes. +# Routing Concerns allow you to declare common routes that can be reused inside +# others resources and routes. # -# concern :commentable do -# resources :comments -# end +# concern :commentable do +# resources :comments +# end # -# concern :image_attachable do -# resources :images, only: :index -# end +# concern :image_attachable do +# resources :images, only: :index +# end # # These concerns are used in Resources routing: # -# resources :messages, concerns: [:commentable, :image_attachable] +# resources :messages, concerns: [:commentable, :image_attachable] # # or in a scope or namespace: # -# namespace :posts do -# concerns :commentable -# end +# namespace :posts do +# concerns :commentable +# end # -# source://actionpack//lib/action_dispatch/routing/mapper.rb#2014 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#2060 module ActionDispatch::Routing::Mapper::Concerns # Define a routing concern using a name. # - # Concerns may be defined inline, using a block, or handled by - # another object, by passing that object as the second parameter. + # Concerns may be defined inline, using a block, or handled by another object, + # by passing that object as the second parameter. # - # The concern object, if supplied, should respond to call, - # which will receive two parameters: + # The concern object, if supplied, should respond to `call`, which will receive + # two parameters: # - # * The current mapper - # * A hash of options which the concern object may use + # * The current mapper + # * A hash of options which the concern object may use # - # Options may also be used by concerns defined in a block by accepting - # a block parameter. So, using a block, you might do something as - # simple as limit the actions available on certain resources, passing - # standard resource options through the concern: + # Options may also be used by concerns defined in a block by accepting a block + # parameter. So, using a block, you might do something as simple as limit the + # actions available on certain resources, passing standard resource options + # through the concern: # - # concern :commentable do |options| - # resources :comments, options - # end + # concern :commentable do |options| + # resources :comments, options + # end # - # resources :posts, concerns: :commentable - # resources :archived_posts do - # # Don't allow comments on archived posts - # concerns :commentable, only: [:index, :show] - # end + # resources :posts, concerns: :commentable + # resources :archived_posts do + # # Don't allow comments on archived posts + # concerns :commentable, only: [:index, :show] + # end # - # Or, using a callable object, you might implement something more - # specific to your application, which would be out of place in your - # routes file. + # Or, using a callable object, you might implement something more specific to + # your application, which would be out of place in your routes file. # - # # purchasable.rb - # class Purchasable - # def initialize(defaults = {}) - # @defaults = defaults - # end + # # purchasable.rb + # class Purchasable + # def initialize(defaults = {}) + # @defaults = defaults + # end # - # def call(mapper, options = {}) - # options = @defaults.merge(options) - # mapper.resources :purchases - # mapper.resources :receipts - # mapper.resources :returns if options[:returnable] + # def call(mapper, options = {}) + # options = @defaults.merge(options) + # mapper.resources :purchases + # mapper.resources :receipts + # mapper.resources :returns if options[:returnable] + # end # end - # end # - # # routes.rb - # concern :purchasable, Purchasable.new(returnable: true) + # # routes.rb + # concern :purchasable, Purchasable.new(returnable: true) # - # resources :toys, concerns: :purchasable - # resources :electronics, concerns: :purchasable - # resources :pets do - # concerns :purchasable, returnable: false - # end + # resources :toys, concerns: :purchasable + # resources :electronics, concerns: :purchasable + # resources :pets do + # concerns :purchasable, returnable: false + # end # - # Any routing helpers can be used inside a concern. If using a - # callable, they're accessible from the Mapper that's passed to - # call. + # Any routing helpers can be used inside a concern. If using a callable, they're + # accessible from the Mapper that's passed to `call`. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2071 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2115 def concern(name, callable = T.unsafe(nil), &block); end # Use the named concerns # - # resources :posts do - # concerns :commentable - # end + # resources :posts do + # concerns :commentable + # end # # Concerns also work in any routes helper that you want to use: # - # namespace :posts do - # concerns :commentable - # end + # namespace :posts do + # concerns :commentable + # end # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2087 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2131 def concerns(*args); end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#15 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#29 class ActionDispatch::Routing::Mapper::Constraints < ::ActionDispatch::Routing::Endpoint # @return [Constraints] a new instance of Constraints # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#21 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#35 def initialize(app, constraints, strategy); end # Returns the value of attribute app. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#16 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#30 def app; end # Returns the value of attribute constraints. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#16 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#30 def constraints; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#36 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#50 def dispatcher?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#38 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#52 def matches?(req); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#45 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#59 def serve(req); end private - # source://actionpack//lib/action_dispatch/routing/mapper.rb#52 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#66 def constraint_args(constraint, request); end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#19 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#33 ActionDispatch::Routing::Mapper::Constraints::CALL = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#18 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#32 ActionDispatch::Routing::Mapper::Constraints::SERVE = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#2099 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#2143 module ActionDispatch::Routing::Mapper::CustomUrls - # Define custom URL helpers that will be added to the application's - # routes. This allows you to override and/or replace the default behavior - # of routing helpers, e.g: + # Define custom URL helpers that will be added to the application's routes. This + # allows you to override and/or replace the default behavior of routing helpers, + # e.g: # - # direct :homepage do - # "https://rubyonrails.org" - # end + # direct :homepage do + # "https://rubyonrails.org" + # end + # + # direct :commentable do |model| + # [ model, anchor: model.dom_id ] + # end # - # direct :commentable do |model| - # [ model, anchor: model.dom_id ] - # end + # direct :main do + # { controller: "pages", action: "index", subdomain: "www" } + # end # - # direct :main do - # { controller: "pages", action: "index", subdomain: "www" } - # end + # The return value from the block passed to `direct` must be a valid set of + # arguments for `url_for` which will actually build the URL string. This can be + # one of the following: # - # The return value from the block passed to +direct+ must be a valid set of - # arguments for +url_for+ which will actually build the URL string. This can - # be one of the following: + # * A string, which is treated as a generated URL + # * A hash, e.g. `{ controller: "pages", action: "index" }` + # * An array, which is passed to `polymorphic_url` + # * An Active Model instance + # * An Active Model class # - # * A string, which is treated as a generated URL - # * A hash, e.g. { controller: "pages", action: "index" } - # * An array, which is passed to +polymorphic_url+ - # * An Active Model instance - # * An Active Model class # - # NOTE: Other URL helpers can be called in the block but be careful not to invoke - # your custom URL helper again otherwise it will result in a stack overflow error. + # NOTE: Other URL helpers can be called in the block but be careful not to + # invoke your custom URL helper again otherwise it will result in a stack + # overflow error. # - # You can also specify default options that will be passed through to - # your URL helper definition, e.g: + # You can also specify default options that will be passed through to your URL + # helper definition, e.g: # - # direct :browse, page: 1, size: 10 do |options| - # [ :products, options.merge(params.permit(:page, :size).to_h.symbolize_keys) ] - # end + # direct :browse, page: 1, size: 10 do |options| + # [ :products, options.merge(params.permit(:page, :size).to_h.symbolize_keys) ] + # end # - # In this instance the +params+ object comes from the context in which the - # block is executed, e.g. generating a URL inside a controller action or a view. - # If the block is executed where there isn't a +params+ object such as this: + # In this instance the `params` object comes from the context in which the block + # is executed, e.g. generating a URL inside a controller action or a view. If + # the block is executed where there isn't a `params` object such as this: # - # Rails.application.routes.url_helpers.browse_path + # Rails.application.routes.url_helpers.browse_path # - # then it will raise a +NameError+. Because of this you need to be aware of the + # then it will raise a `NameError`. Because of this you need to be aware of the # context in which you will use your custom URL helper when defining it. # - # NOTE: The +direct+ method can't be used inside of a scope block such as - # +namespace+ or +scope+ and will raise an error if it detects that it is. + # NOTE: The `direct` method can't be used inside of a scope block such as + # `namespace` or `scope` and will raise an error if it detects that it is. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2147 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2193 def direct(name, options = T.unsafe(nil), &block); end - # Define custom polymorphic mappings of models to URLs. This alters the - # behavior of +polymorphic_url+ and consequently the behavior of - # +link_to+ and +form_for+ when passed a model instance, e.g: + # Define custom polymorphic mappings of models to URLs. This alters the behavior + # of `polymorphic_url` and consequently the behavior of `link_to` and `form_for` + # when passed a model instance, e.g: # - # resource :basket + # resource :basket # - # resolve "Basket" do - # [:basket] - # end + # resolve "Basket" do + # [:basket] + # end # - # This will now generate "/basket" when a +Basket+ instance is passed to - # +link_to+ or +form_for+ instead of the standard "/baskets/:id". + # This will now generate "/basket" when a `Basket` instance is passed to + # `link_to` or `form_for` instead of the standard "/baskets/:id". # - # NOTE: This custom behavior only applies to simple polymorphic URLs where - # a single model instance is passed and not more complicated forms, e.g: + # NOTE: This custom behavior only applies to simple polymorphic URLs where a + # single model instance is passed and not more complicated forms, e.g: # - # # config/routes.rb - # resource :profile - # namespace :admin do - # resources :users - # end + # # config/routes.rb + # resource :profile + # namespace :admin do + # resources :users + # end # - # resolve("User") { [:profile] } + # resolve("User") { [:profile] } # - # # app/views/application/_menu.html.erb - # link_to "Profile", @current_user - # link_to "Profile", [:admin, @current_user] + # # app/views/application/_menu.html.erb + # link_to "Profile", @current_user + # link_to "Profile", [:admin, @current_user] # - # The first +link_to+ will generate "/profile" but the second will generate - # the standard polymorphic URL of "/admin/users/1". + # The first `link_to` will generate "/profile" but the second will generate the + # standard polymorphic URL of "/admin/users/1". # - # You can pass options to a polymorphic mapping - the arity for the block - # needs to be two as the instance is passed as the first argument, e.g: + # You can pass options to a polymorphic mapping - the arity for the block needs + # to be two as the instance is passed as the first argument, e.g: # - # resolve "Basket", anchor: "items" do |basket, options| - # [:basket, options] - # end + # resolve "Basket", anchor: "items" do |basket, options| + # [:basket, options] + # end # - # This generates the URL "/basket#items" because when the last item in an - # array passed to +polymorphic_url+ is a hash then it's treated as options - # to the URL helper that gets called. + # This generates the URL "/basket#items" because when the last item in an array + # passed to `polymorphic_url` is a hash then it's treated as options to the URL + # helper that gets called. # - # NOTE: The +resolve+ method can't be used inside of a scope block such as - # +namespace+ or +scope+ and will raise an error if it detects that it is. + # NOTE: The `resolve` method can't be used inside of a scope block such as + # `namespace` or `scope` and will raise an error if it detects that it is. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2199 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2245 def resolve(*args, &block); end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#682 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#727 module ActionDispatch::Routing::Mapper::HttpHelpers - # Define a route that only recognizes HTTP DELETE. - # For supported arguments, see match[rdoc-ref:Base#match] + # Define a route that only recognizes HTTP DELETE. For supported arguments, see + # [match](rdoc-ref:Base#match) # - # delete 'broccoli', to: 'food#broccoli' + # delete 'broccoli', to: 'food#broccoli' # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#719 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#764 def delete(*args, &block); end - # Define a route that only recognizes HTTP GET. - # For supported arguments, see match[rdoc-ref:Base#match] + # Define a route that only recognizes HTTP GET. For supported arguments, see + # [match](rdoc-ref:Base#match) # - # get 'bacon', to: 'food#bacon' + # get 'bacon', to: 'food#bacon' # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#687 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#732 def get(*args, &block); end - # Define a route that only recognizes HTTP OPTIONS. - # For supported arguments, see match[rdoc-ref:Base#match] + # Define a route that only recognizes HTTP OPTIONS. For supported arguments, see + # [match](rdoc-ref:Base#match) # - # options 'carrots', to: 'food#carrots' + # options 'carrots', to: 'food#carrots' # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#727 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#772 def options(*args, &block); end - # Define a route that only recognizes HTTP PATCH. - # For supported arguments, see match[rdoc-ref:Base#match] + # Define a route that only recognizes HTTP PATCH. For supported arguments, see + # [match](rdoc-ref:Base#match) # - # patch 'bacon', to: 'food#bacon' + # patch 'bacon', to: 'food#bacon' # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#703 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#748 def patch(*args, &block); end - # Define a route that only recognizes HTTP POST. - # For supported arguments, see match[rdoc-ref:Base#match] + # Define a route that only recognizes HTTP POST. For supported arguments, see + # [match](rdoc-ref:Base#match) # - # post 'bacon', to: 'food#bacon' + # post 'bacon', to: 'food#bacon' # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#695 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#740 def post(*args, &block); end - # Define a route that only recognizes HTTP PUT. - # For supported arguments, see match[rdoc-ref:Base#match] + # Define a route that only recognizes HTTP PUT. For supported arguments, see + # [match](rdoc-ref:Base#match) # - # put 'bacon', to: 'food#bacon' + # put 'bacon', to: 'food#bacon' # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#711 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#756 def put(*args, &block); end private - # source://actionpack//lib/action_dispatch/routing/mapper.rb#732 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#777 def map_method(method, args, &block); end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#69 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#83 class ActionDispatch::Routing::Mapper::Mapping # @return [Mapping] a new instance of Mapping # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#118 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#132 def initialize(set:, ast:, controller:, default_action:, to:, formatted:, via:, options_constraints:, anchor:, scope_params:, options:); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#176 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#190 def application; end # Returns the value of attribute ast. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def ast; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#180 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#194 def conditions; end # Returns the value of attribute default_action. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def default_action; end # Returns the value of attribute default_controller. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def default_controller; end # Returns the value of attribute defaults. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def defaults; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#169 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#183 def make_route(name, precedence); end # Returns the value of attribute path. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def path; end # Returns the value of attribute required_defaults. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def required_defaults; end # Returns the value of attribute requirements. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def requirements; end # Returns the value of attribute scope_options. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def scope_options; end # Returns the value of attribute to. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#73 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#87 def to; end private - # source://actionpack//lib/action_dispatch/routing/mapper.rb#316 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#334 def add_controller_module(controller, modyoule); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#269 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#295 def app(blocks); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#335 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#353 def blocks(callable_constraint); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#184 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#198 def build_conditions(current_conditions, request_class); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#281 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#307 def check_controller_and_action(path_params, controller, action); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#296 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#322 def check_part(name, part, path_params, hash); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#342 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#360 def constraints(options, path_params); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#356 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#374 def dispatcher(raise_on_name_error); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#199 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#213 def intern(object); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#265 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#291 def normalize_defaults(options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#233 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#259 def normalize_format(formatted); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#203 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#217 def normalize_options!(options, path_params, modyoule); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#193 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#207 def request_method; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#227 - def split_constraints(path_params, constraints); end + # source://actionpack//lib/action_dispatch/routing/mapper.rb#379 + def route_source_location; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#308 - def split_to(to); end + # source://actionpack//lib/action_dispatch/routing/mapper.rb#253 + def split_constraints(path_params, constraints); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#328 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#346 def translate_controller(controller); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#249 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#275 def verify_regexp_requirements(requirements, wildcard_options); end class << self - # source://actionpack//lib/action_dispatch/routing/mapper.rb#76 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#90 def build(scope, set, ast, controller, default_action, to, via, formatted, options_constraints, anchor, options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#90 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#104 def check_via(via); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#102 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#116 def normalize_path(path, format); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#114 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#128 def optional_format?(path, format); end end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#70 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#84 ActionDispatch::Routing::Mapper::Mapping::ANCHOR_CHARACTERS_REGEX = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#167 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#181 ActionDispatch::Routing::Mapper::Mapping::JOINED_SEPARATORS = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#71 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#85 ActionDispatch::Routing::Mapper::Mapping::OPTIONAL_FORMAT_REGEX = T.let(T.unsafe(nil), Regexp) -# Resource routing allows you to quickly declare all of the common routes -# for a given resourceful controller. Instead of declaring separate routes -# for your +index+, +show+, +new+, +edit+, +create+, +update+, and +destroy+ -# actions, a resourceful route declares them in a single line of code: +# Resource routing allows you to quickly declare all of the common routes for a +# given resourceful controller. Instead of declaring separate routes for your +# `index`, `show`, `new`, `edit`, `create`, `update`, and `destroy` actions, a +# resourceful route declares them in a single line of code: # -# resources :photos +# resources :photos # -# Sometimes, you have a resource that clients always look up without -# referencing an ID. A common example, /profile always shows the profile of -# the currently logged in user. In this case, you can use a singular resource -# to map /profile (rather than /profile/:id) to the show action. +# Sometimes, you have a resource that clients always look up without referencing +# an ID. A common example, /profile always shows the profile of the currently +# logged in user. In this case, you can use a singular resource to map /profile +# (rather than /profile/:id) to the show action. # -# resource :profile +# resource :profile # -# It's common to have resources that are logically children of other -# resources: +# It's common to have resources that are logically children of other resources: # -# resources :magazines do -# resources :ads -# end +# resources :magazines do +# resources :ads +# end # # You may wish to organize groups of controllers under a namespace. Most -# commonly, you might group a number of administrative controllers under -# an +admin+ namespace. You would place these controllers under the -# app/controllers/admin directory, and you can group them together -# in your router: +# commonly, you might group a number of administrative controllers under an +# `admin` namespace. You would place these controllers under the +# `app/controllers/admin` directory, and you can group them together in your +# router: # -# namespace "admin" do -# resources :posts, :comments -# end +# namespace "admin" do +# resources :posts, :comments +# end # -# By default the +:id+ parameter doesn't accept dots. If you need to -# use dots as part of the +:id+ parameter add a constraint which -# overrides this restriction, e.g: +# By default the `:id` parameter doesn't accept dots. If you need to use dots as +# part of the `:id` parameter add a constraint which overrides this restriction, +# e.g: # -# resources :articles, id: /[^\/]+/ +# resources :articles, id: /[^\/]+/ # -# This allows any character other than a slash as part of your +:id+. +# This allows any character other than a slash as part of your `:id`. # -# source://actionpack//lib/action_dispatch/routing/mapper.rb#1122 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#1168 module ActionDispatch::Routing::Mapper::Resources # To add a route to the collection: # - # resources :photos do - # collection do - # get 'search' + # resources :photos do + # collection do + # get 'search' + # end # end - # end # - # This will enable Rails to recognize paths such as /photos/search - # with GET, and route to the search action of +PhotosController+. It will also - # create the search_photos_url and search_photos_path - # route helpers. + # This will enable Rails to recognize paths such as `/photos/search` with GET, + # and route to the search action of `PhotosController`. It will also create the + # `search_photos_url` and `search_photos_path` route helpers. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1500 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1547 def collection(&block); end - # Loads another routes file with the given +name+ located inside the - # +config/routes+ directory. In that file, you can use the normal - # routing DSL, but do not surround it with a - # +Rails.application.routes.draw+ block. + # Loads another routes file with the given `name` located inside the + # `config/routes` directory. In that file, you can use the normal routing DSL, + # but *do not* surround it with a `Rails.application.routes.draw` block. # - # # config/routes.rb - # Rails.application.routes.draw do - # draw :admin # Loads `config/routes/admin.rb` - # draw "third_party/some_gem" # Loads `config/routes/third_party/some_gem.rb` - # end + # # config/routes.rb + # Rails.application.routes.draw do + # draw :admin # Loads `config/routes/admin.rb` + # draw "third_party/some_gem" # Loads `config/routes/third_party/some_gem.rb` + # end # - # # config/routes/admin.rb - # namespace :admin do - # resources :accounts - # end + # # config/routes/admin.rb + # namespace :admin do + # resources :accounts + # end # - # # config/routes/third_party/some_gem.rb - # mount SomeGem::Engine, at: "/some_gem" + # # config/routes/third_party/some_gem.rb + # mount SomeGem::Engine, at: "/some_gem" # - # CAUTION: Use this feature with care. Having multiple routes - # files can negatively impact discoverability and readability. For most - # applications — even those with a few hundred routes — it's easier for - # developers to have a single routes file. + # **CAUTION:** Use this feature with care. Having multiple routes files can + # negatively impact discoverability and readability. For most applications — + # even those with a few hundred routes — it's easier for developers to have a + # single routes file. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1610 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1656 def draw(name); end - # Matches a URL pattern to one or more routes. - # For more information, see match[rdoc-ref:Base#match]. + # Matches a URL pattern to one or more routes. For more information, see + # [match](rdoc-ref:Base#match). # - # match 'path' => 'controller#action', via: :patch - # match 'path', to: 'controller#action', via: :post - # match 'path', 'otherpath', on: :member, via: :get + # match 'path' => 'controller#action', via: :patch + # match 'path', to: 'controller#action', via: :post + # match 'path', 'otherpath', on: :member, via: :get # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1632 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1678 def match(path, *rest, &block); end # To add a member route, add a member block into the resource block: # - # resources :photos do - # member do - # get 'preview' + # resources :photos do + # member do + # get 'preview' + # end # end - # end # - # This will recognize /photos/1/preview with GET, and route to the - # preview action of +PhotosController+. It will also create the - # preview_photo_url and preview_photo_path helpers. + # This will recognize `/photos/1/preview` with GET, and route to the preview + # action of `PhotosController`. It will also create the `preview_photo_url` and + # `preview_photo_path` helpers. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1521 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1568 def member(&block); end # See ActionDispatch::Routing::Mapper::Scoping#namespace. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1568 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1615 def namespace(path, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1547 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1594 def nested(&block); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1537 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1584 def new(&block); end - # Sometimes, you have a resource that clients always look up without - # referencing an ID. A common example, /profile always shows the - # profile of the currently logged in user. In this case, you can use - # a singular resource to map /profile (rather than /profile/:id) to - # the show action: + # Sometimes, you have a resource that clients always look up without referencing + # an ID. A common example, /profile always shows the profile of the currently + # logged in user. In this case, you can use a singular resource to map /profile + # (rather than /profile/:id) to the show action: # - # resource :profile + # resource :profile # - # This creates six different routes in your application, all mapping to - # the +Profiles+ controller (note that the controller is named after - # the plural): + # This creates six different routes in your application, all mapping to the + # `Profiles` controller (note that the controller is named after the plural): # - # GET /profile/new - # GET /profile - # GET /profile/edit - # PATCH/PUT /profile - # DELETE /profile - # POST /profile + # GET /profile/new + # GET /profile + # GET /profile/edit + # PATCH/PUT /profile + # DELETE /profile + # POST /profile # - # If you want instances of a model to work with this resource via - # record identification (e.g. in +form_with+ or +redirect_to+), you - # will need to call resolve[rdoc-ref:CustomUrls#resolve]: + # If you want instances of a model to work with this resource via record + # identification (e.g. in `form_with` or `redirect_to`), you will need to call + # [resolve](rdoc-ref:CustomUrls#resolve): # - # resource :profile - # resolve('Profile') { [:profile] } + # resource :profile + # resolve('Profile') { [:profile] } # - # # Enables this to work with singular routes: - # form_with(model: @profile) {} + # # Enables this to work with singular routes: + # form_with(model: @profile) {} # - # === Options - # Takes same options as resources[rdoc-ref:#resources] + # ### Options + # Takes same options as [resources](rdoc-ref:#resources) # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1292 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1336 def resource(*resources, &block); end - # In Rails, a resourceful route provides a mapping between HTTP verbs - # and URLs and controller actions. By convention, each action also maps - # to particular CRUD operations in a database. A single entry in the - # routing file, such as + # In Rails, a resourceful route provides a mapping between HTTP verbs and URLs + # and controller actions. By convention, each action also maps to particular + # CRUD operations in a database. A single entry in the routing file, such as # - # resources :photos + # resources :photos # - # creates seven different routes in your application, all mapping to - # the +Photos+ controller: + # creates seven different routes in your application, all mapping to the + # `Photos` controller: # - # GET /photos - # GET /photos/new - # POST /photos - # GET /photos/:id - # GET /photos/:id/edit - # PATCH/PUT /photos/:id - # DELETE /photos/:id + # GET /photos + # GET /photos/new + # POST /photos + # GET /photos/:id + # GET /photos/:id/edit + # PATCH/PUT /photos/:id + # DELETE /photos/:id # # Resources can also be nested infinitely by using this block syntax: # - # resources :photos do - # resources :comments - # end + # resources :photos do + # resources :comments + # end # # This generates the following comments routes: # - # GET /photos/:photo_id/comments - # GET /photos/:photo_id/comments/new - # POST /photos/:photo_id/comments - # GET /photos/:photo_id/comments/:id - # GET /photos/:photo_id/comments/:id/edit - # PATCH/PUT /photos/:photo_id/comments/:id - # DELETE /photos/:photo_id/comments/:id + # GET /photos/:photo_id/comments + # GET /photos/:photo_id/comments/new + # POST /photos/:photo_id/comments + # GET /photos/:photo_id/comments/:id + # GET /photos/:photo_id/comments/:id/edit + # PATCH/PUT /photos/:photo_id/comments/:id + # DELETE /photos/:photo_id/comments/:id # - # === Options - # Takes same options as match[rdoc-ref:Base#match] as well as: + # ### Options + # Takes same options as [match](rdoc-ref:Base#match) as well as: # - # [:path_names] - # Allows you to change the segment component of the +edit+ and +new+ actions. - # Actions not specified are not changed. + # :path_names + # : Allows you to change the segment component of the `edit` and `new` + # actions. Actions not specified are not changed. # - # resources :posts, path_names: { new: "brand_new" } + # resources :posts, path_names: { new: "brand_new" } # - # The above example will now change /posts/new to /posts/brand_new. + # The above example will now change /posts/new to /posts/brand_new. # - # [:path] - # Allows you to change the path prefix for the resource. + # :path + # : Allows you to change the path prefix for the resource. # - # resources :posts, path: 'postings' + # resources :posts, path: 'postings' # - # The resource and all segments will now route to /postings instead of /posts. + # The resource and all segments will now route to /postings instead of + # /posts. # - # [:only] - # Only generate routes for the given actions. + # :only + # : Only generate routes for the given actions. # - # resources :cows, only: :show - # resources :cows, only: [:show, :index] + # resources :cows, only: :show + # resources :cows, only: [:show, :index] # - # [:except] - # Generate all routes except for the given actions. + # :except + # : Generate all routes except for the given actions. # - # resources :cows, except: :show - # resources :cows, except: [:show, :index] + # resources :cows, except: :show + # resources :cows, except: [:show, :index] # - # [:shallow] - # Generates shallow routes for nested resource(s). When placed on a parent resource, - # generates shallow routes for all nested resources. + # :shallow + # : Generates shallow routes for nested resource(s). When placed on a parent + # resource, generates shallow routes for all nested resources. # - # resources :posts, shallow: true do - # resources :comments - # end + # resources :posts, shallow: true do + # resources :comments + # end # - # Is the same as: + # Is the same as: # - # resources :posts do - # resources :comments, except: [:show, :edit, :update, :destroy] - # end - # resources :comments, only: [:show, :edit, :update, :destroy] + # resources :posts do + # resources :comments, except: [:show, :edit, :update, :destroy] + # end + # resources :comments, only: [:show, :edit, :update, :destroy] # - # This allows URLs for resources that otherwise would be deeply nested such - # as a comment on a blog post like /posts/a-long-permalink/comments/1234 - # to be shortened to just /comments/1234. + # This allows URLs for resources that otherwise would be deeply nested such + # as a comment on a blog post like `/posts/a-long-permalink/comments/1234` + # to be shortened to just `/comments/1234`. # - # Set shallow: false on a child resource to ignore a parent's shallow parameter. + # Set `shallow: false` on a child resource to ignore a parent's shallow + # parameter. # - # [:shallow_path] - # Prefixes nested shallow routes with the specified path. + # :shallow_path + # : Prefixes nested shallow routes with the specified path. # - # scope shallow_path: "sekret" do - # resources :posts do - # resources :comments, shallow: true - # end - # end + # scope shallow_path: "sekret" do + # resources :posts do + # resources :comments, shallow: true + # end + # end # - # The +comments+ resource here will have the following routes generated for it: + # The `comments` resource here will have the following routes generated for + # it: # - # post_comments GET /posts/:post_id/comments(.:format) - # post_comments POST /posts/:post_id/comments(.:format) - # new_post_comment GET /posts/:post_id/comments/new(.:format) - # edit_comment GET /sekret/comments/:id/edit(.:format) - # comment GET /sekret/comments/:id(.:format) - # comment PATCH/PUT /sekret/comments/:id(.:format) - # comment DELETE /sekret/comments/:id(.:format) + # post_comments GET /posts/:post_id/comments(.:format) + # post_comments POST /posts/:post_id/comments(.:format) + # new_post_comment GET /posts/:post_id/comments/new(.:format) + # edit_comment GET /sekret/comments/:id/edit(.:format) + # comment GET /sekret/comments/:id(.:format) + # comment PATCH/PUT /sekret/comments/:id(.:format) + # comment DELETE /sekret/comments/:id(.:format) # - # [:shallow_prefix] - # Prefixes nested shallow route names with specified prefix. + # :shallow_prefix + # : Prefixes nested shallow route names with specified prefix. # - # scope shallow_prefix: "sekret" do - # resources :posts do - # resources :comments, shallow: true - # end - # end + # scope shallow_prefix: "sekret" do + # resources :posts do + # resources :comments, shallow: true + # end + # end + # + # The `comments` resource here will have the following routes generated for + # it: # - # The +comments+ resource here will have the following routes generated for it: + # post_comments GET /posts/:post_id/comments(.:format) + # post_comments POST /posts/:post_id/comments(.:format) + # new_post_comment GET /posts/:post_id/comments/new(.:format) + # edit_sekret_comment GET /comments/:id/edit(.:format) + # sekret_comment GET /comments/:id(.:format) + # sekret_comment PATCH/PUT /comments/:id(.:format) + # sekret_comment DELETE /comments/:id(.:format) # - # post_comments GET /posts/:post_id/comments(.:format) - # post_comments POST /posts/:post_id/comments(.:format) - # new_post_comment GET /posts/:post_id/comments/new(.:format) - # edit_sekret_comment GET /comments/:id/edit(.:format) - # sekret_comment GET /comments/:id(.:format) - # sekret_comment PATCH/PUT /comments/:id(.:format) - # sekret_comment DELETE /comments/:id(.:format) + # :format + # : Allows you to specify the default value for optional `format` segment or + # disable it by supplying `false`. # - # [:format] - # Allows you to specify the default value for optional +format+ - # segment or disable it by supplying +false+. + # :param + # : Allows you to override the default param name of `:id` in the URL. # - # [:param] - # Allows you to override the default param name of +:id+ in the URL. # - # === Examples + # ### Examples # - # # routes call Admin::PostsController - # resources :posts, module: "admin" + # # routes call +Admin::PostsController+ + # resources :posts, module: "admin" # - # # resource actions are at /admin/posts. - # resources :posts, path: "admin/posts" + # # resource actions are at /admin/posts. + # resources :posts, path: "admin/posts" # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1458 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1506 def resources(*resources, &block); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1257 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1303 def resources_path_names(options); end # You can specify what Rails should route "/" to with the root method: # - # root to: 'pages#main' + # root to: 'pages#main' # - # For options, see +match+, as +root+ uses it internally. + # For options, see `match`, as `root` uses it internally. # # You can also pass a string which will expand # - # root 'pages#main' + # root 'pages#main' # - # You should put the root route at the top of config/routes.rb, - # because this means it will be matched first. As this is the most popular route - # of most Rails applications, this is beneficial. + # You should put the root route at the top of `config/routes.rb`, because this + # means it will be matched first. As this is the most popular route of most + # Rails applications, this is beneficial. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1679 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1725 def root(path, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1576 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1623 def shallow; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1583 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1630 def shallow?; end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1743 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1789 def action_options?(options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1825 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1871 def action_path(name); end # @raise [ArgumentError] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1961 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2007 def add_route(action, controller, options, _path, to, via, formatted, anchor, options_constraints); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1879 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1925 def api_only?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1738 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1784 def apply_action_options(options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1704 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1750 def apply_common_behavior_for(method, resources, options, &block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1801 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1847 def canonical_action?(action); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1946 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1992 def decomposed_match(path, controller, options, _path, to, via, formatted, anchor, options_constraints); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1931 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1977 def get_to_from_path(path, to, action); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1890 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1936 def map_match(paths, options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1988 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2034 def match_root_route(options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1841 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1887 def name_for_action(as, action); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1778 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1824 def nested_options; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1759 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1805 def nested_scope?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1797 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1843 def param_constraint; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1793 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1839 def param_constraint?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1700 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1746 def parent_resource; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1815 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1861 def path_for_action(action, path); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1883 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1929 def path_scope(path); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1829 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1875 def prefix_name_for_action(as, action); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1755 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1801 def resource_method_scope?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1770 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1816 def resource_scope(resource, &block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1751 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1797 def resource_scope?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1747 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1793 def scope_action_options; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1867 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1913 def set_member_mappings_for_resource; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1787 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1833 def shallow_nesting_depth; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1805 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1851 def shallow_scope; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1942 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1988 def using_match_shorthand?(path); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1763 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1809 def with_scope_level(kind); end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#1127 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#1173 ActionDispatch::Routing::Mapper::Resources::CANONICAL_ACTIONS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#1126 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#1172 ActionDispatch::Routing::Mapper::Resources::RESOURCE_OPTIONS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#1129 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#1175 class ActionDispatch::Routing::Mapper::Resources::Resource # @return [Resource] a new instance of Resource # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1132 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1178 def initialize(entities, api_only, shallow, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1157 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1203 def actions; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1165 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1211 def available_actions; end - # Checks for uncountable plurals, and appends "_index" if the plural - # and singular form are the same. + # Checks for uncountable plurals, and appends "_index" if the plural and + # singular form are the same. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1189 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1235 def collection_name; end # Returns the value of attribute path. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1130 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1176 def collection_scope; end # Returns the value of attribute controller. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1130 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1176 def controller; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1149 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1195 def default_actions; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1181 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1227 def member_name; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1199 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1245 def member_scope; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1173 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1219 def name; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1209 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1255 def nested_param; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1213 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1259 def nested_scope; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1205 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1251 def new_scope(new_path); end # Returns the value of attribute param. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1130 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1176 def param; end # Returns the value of attribute path. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1130 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1176 def path; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1177 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1223 def plural; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1193 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1239 def resource_scope; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1217 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1263 def shallow?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1199 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1245 def shallow_scope; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1221 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1267 def singleton?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1181 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1227 def singular; end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#1224 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#1270 class ActionDispatch::Routing::Mapper::Resources::SingletonResource < ::ActionDispatch::Routing::Mapper::Resources::Resource # @return [SingletonResource] a new instance of SingletonResource # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1225 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1271 def initialize(entities, api_only, shallow, options); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1244 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1290 def collection_name; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1232 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1278 def default_actions; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1244 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1290 def member_name; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1130 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1176 def member_scope; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1130 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1176 def nested_scope; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1240 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1286 def plural; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1254 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1300 def singleton?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1244 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1290 def singular; end end -# CANONICAL_ACTIONS holds all actions that does not need a prefix or -# a path appended since they fit properly in their scope level. +# CANONICAL_ACTIONS holds all actions that does not need a prefix or a path +# appended since they fit properly in their scope level. # -# source://actionpack//lib/action_dispatch/routing/mapper.rb#1125 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#1171 ActionDispatch::Routing::Mapper::Resources::VALID_ON_OPTIONS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#2213 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#2259 class ActionDispatch::Routing::Mapper::Scope include ::Enumerable # @return [Scope] a new instance of Scope # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2223 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2269 def initialize(hash, parent = T.unsafe(nil), scope_level = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2282 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2328 def [](key); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2249 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2295 def action_name(name_prefix, prefix, collection_name, member_name); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2289 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2335 def each; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2297 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2343 def frame; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2229 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2275 def nested?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2274 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2320 def new(hash); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2278 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2324 def new_level(level); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2233 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2279 def null?; end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2270 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2316 def options; end # Returns the value of attribute parent. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2221 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2267 def parent; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2245 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2291 def resource_method_scope?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2266 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2312 def resource_scope?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2241 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2287 def resources?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2237 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2283 def root?; end # Returns the value of attribute scope_level. # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#2221 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#2267 def scope_level; end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#2299 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#2345 ActionDispatch::Routing::Mapper::Scope::NULL = T.let(T.unsafe(nil), ActionDispatch::Routing::Mapper::Scope) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#2214 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#2260 ActionDispatch::Routing::Mapper::Scope::OPTIONS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#2219 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#2265 ActionDispatch::Routing::Mapper::Scope::RESOURCE_METHOD_SCOPES = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#2218 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#2264 ActionDispatch::Routing::Mapper::Scope::RESOURCE_SCOPES = T.let(T.unsafe(nil), Array) -# You may wish to organize groups of controllers under a namespace. -# Most commonly, you might group a number of administrative controllers -# under an +admin+ namespace. You would place these controllers under -# the app/controllers/admin directory, and you can group them -# together in your router: +# You may wish to organize groups of controllers under a namespace. Most +# commonly, you might group a number of administrative controllers under an +# `admin` namespace. You would place these controllers under the +# `app/controllers/admin` directory, and you can group them together in your +# router: # -# namespace "admin" do -# resources :posts, :comments -# end +# namespace "admin" do +# resources :posts, :comments +# end # # This will create a number of routes for each of the posts and comments -# controller. For Admin::PostsController, Rails will create: +# controller. For `Admin::PostsController`, Rails will create: # -# GET /admin/posts -# GET /admin/posts/new -# POST /admin/posts -# GET /admin/posts/1 -# GET /admin/posts/1/edit -# PATCH/PUT /admin/posts/1 -# DELETE /admin/posts/1 +# GET /admin/posts +# GET /admin/posts/new +# POST /admin/posts +# GET /admin/posts/1 +# GET /admin/posts/1/edit +# PATCH/PUT /admin/posts/1 +# DELETE /admin/posts/1 # # If you want to route /posts (without the prefix /admin) to -# Admin::PostsController, you could use +# `Admin::PostsController`, you could use # -# scope module: "admin" do -# resources :posts -# end +# scope module: "admin" do +# resources :posts +# end # # or, for a single case # -# resources :posts, module: "admin" +# resources :posts, module: "admin" # -# If you want to route /admin/posts to +PostsController+ -# (without the Admin:: module prefix), you could use +# If you want to route /admin/posts to `PostsController` (without the `Admin::` +# module prefix), you could use # -# scope "/admin" do -# resources :posts -# end +# scope "/admin" do +# resources :posts +# end # # or, for a single case # -# resources :posts, path: "/admin/posts" +# resources :posts, path: "/admin/posts" # -# In each of these cases, the named routes remain the same as if you did -# not use scope. In the last case, the following paths map to -# +PostsController+: +# In each of these cases, the named routes remain the same as if you did not use +# scope. In the last case, the following paths map to `PostsController`: # -# GET /admin/posts -# GET /admin/posts/new -# POST /admin/posts -# GET /admin/posts/1 -# GET /admin/posts/1/edit -# PATCH/PUT /admin/posts/1 -# DELETE /admin/posts/1 +# GET /admin/posts +# GET /admin/posts/new +# POST /admin/posts +# GET /admin/posts/1 +# GET /admin/posts/1/edit +# PATCH/PUT /admin/posts/1 +# DELETE /admin/posts/1 # -# source://actionpack//lib/action_dispatch/routing/mapper.rb#794 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#838 module ActionDispatch::Routing::Mapper::Scoping - # === Parameter Restriction - # Allows you to constrain the nested routes based on a set of rules. - # For instance, in order to change the routes to allow for a dot character in the +id+ parameter: + # ### Parameter Restriction + # Allows you to constrain the nested routes based on a set of rules. For + # instance, in order to change the routes to allow for a dot character in the + # `id` parameter: # - # constraints(id: /\d+\.\d+/) do - # resources :posts - # end + # constraints(id: /\d+\.\d+/) do + # resources :posts + # end # - # Now routes such as +/posts/1+ will no longer be valid, but +/posts/1.1+ will be. - # The +id+ parameter must match the constraint passed in for this example. + # Now routes such as `/posts/1` will no longer be valid, but `/posts/1.1` will + # be. The `id` parameter must match the constraint passed in for this example. # # You may use this to also restrict other parameters: # - # resources :posts do - # constraints(post_id: /\d+\.\d+/) do - # resources :comments + # resources :posts do + # constraints(post_id: /\d+\.\d+/) do + # resources :comments + # end # end - # end # - # === Restricting based on IP + # ### Restricting based on IP # # Routes can also be constrained to an IP or a certain range of IP addresses: # - # constraints(ip: /192\.168\.\d+\.\d+/) do - # resources :posts - # end + # constraints(ip: /192\.168\.\d+\.\d+/) do + # resources :posts + # end # - # Any user connecting from the 192.168.* range will be able to see this resource, - # where as any user connecting outside of this range will be told there is no such route. + # Any user connecting from the 192.168.* range will be able to see this + # resource, where as any user connecting outside of this range will be told + # there is no such route. # - # === Dynamic request matching + # ### Dynamic request matching # # Requests to routes can be constrained based on specific criteria: # - # constraints(-> (req) { /iPhone/.match?(req.env["HTTP_USER_AGENT"]) }) do - # resources :iphones - # end + # constraints(-> (req) { /iPhone/.match?(req.env["HTTP_USER_AGENT"]) }) do + # resources :iphones + # end # - # You are able to move this logic out into a class if it is too complex for routes. - # This class must have a +matches?+ method defined on it which either returns +true+ - # if the user should be given access to that route, or +false+ if the user should not. + # You are able to move this logic out into a class if it is too complex for + # routes. This class must have a `matches?` method defined on it which either + # returns `true` if the user should be given access to that route, or `false` if + # the user should not. # - # class Iphone - # def self.matches?(request) - # /iPhone/.match?(request.env["HTTP_USER_AGENT"]) - # end - # end + # class Iphone + # def self.matches?(request) + # /iPhone/.match?(request.env["HTTP_USER_AGENT"]) + # end + # end # - # An expected place for this code would be +lib/constraints+. + # An expected place for this code would be `lib/constraints`. # # This class is then used like this: # - # constraints(Iphone) do - # resources :iphones - # end + # constraints(Iphone) do + # resources :iphones + # end # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#999 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1046 def constraints(constraints = T.unsafe(nil), &block); end # Scopes routes to a specific controller # - # controller "food" do - # match "bacon", action: :bacon, via: :get - # end + # controller "food" do + # match "bacon", action: :bacon, via: :get + # end # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#884 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#928 def controller(controller); end # Allows you to set default parameters for a route, such as this: - # defaults id: 'home' do - # match 'scoped_pages/(:id)', to: 'pages#show' - # end - # Using this, the +:id+ parameter here will default to 'home'. + # defaults id: 'home' do + # match 'scoped_pages/(:id)', to: 'pages#show' + # end # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1008 + # Using this, the `:id` parameter here will default to 'home'. + # + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1056 def defaults(defaults = T.unsafe(nil)); end # Scopes routes to a specific namespace. For example: # - # namespace :admin do - # resources :posts - # end + # namespace :admin do + # resources :posts + # end # # This generates the following routes: # - # admin_posts GET /admin/posts(.:format) admin/posts#index - # admin_posts POST /admin/posts(.:format) admin/posts#create - # new_admin_post GET /admin/posts/new(.:format) admin/posts#new - # edit_admin_post GET /admin/posts/:id/edit(.:format) admin/posts#edit - # admin_post GET /admin/posts/:id(.:format) admin/posts#show - # admin_post PATCH/PUT /admin/posts/:id(.:format) admin/posts#update - # admin_post DELETE /admin/posts/:id(.:format) admin/posts#destroy + # admin_posts GET /admin/posts(.:format) admin/posts#index + # admin_posts POST /admin/posts(.:format) admin/posts#create + # new_admin_post GET /admin/posts/new(.:format) admin/posts#new + # edit_admin_post GET /admin/posts/:id/edit(.:format) admin/posts#edit + # admin_post GET /admin/posts/:id(.:format) admin/posts#show + # admin_post PATCH/PUT /admin/posts/:id(.:format) admin/posts#update + # admin_post DELETE /admin/posts/:id(.:format) admin/posts#destroy # - # === Options + # ### Options # - # The +:path+, +:as+, +:module+, +:shallow_path+, and +:shallow_prefix+ - # options all default to the name of the namespace. + # The `:path`, `:as`, `:module`, `:shallow_path`, and `:shallow_prefix` options + # all default to the name of the namespace. # - # For options, see Base#match. For +:shallow_path+ option, see - # Resources#resources. + # For options, see `Base#match`. For `:shallow_path` option, see + # `Resources#resources`. # - # # accessible through /sekret/posts rather than /admin/posts - # namespace :admin, path: "sekret" do - # resources :posts - # end + # # accessible through /sekret/posts rather than /admin/posts + # namespace :admin, path: "sekret" do + # resources :posts + # end # - # # maps to Sekret::PostsController rather than Admin::PostsController - # namespace :admin, module: "sekret" do - # resources :posts - # end + # # maps to +Sekret::PostsController+ rather than +Admin::PostsController+ + # namespace :admin, module: "sekret" do + # resources :posts + # end # - # # generates +sekret_posts_path+ rather than +admin_posts_path+ - # namespace :admin, as: "sekret" do - # resources :posts - # end + # # generates +sekret_posts_path+ rather than +admin_posts_path+ + # namespace :admin, as: "sekret" do + # resources :posts + # end # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#929 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#973 def namespace(path, options = T.unsafe(nil), &block); end # Scopes a set of routes to the given default options. # # Take the following route definition as an example: # - # scope path: ":account_id", as: "account" do - # resources :projects - # end + # scope path: ":account_id", as: "account" do + # resources :projects + # end # - # This generates helpers such as +account_projects_path+, just like +resources+ does. - # The difference here being that the routes generated are like /:account_id/projects, - # rather than /accounts/:account_id/projects. + # This generates helpers such as `account_projects_path`, just like `resources` + # does. The difference here being that the routes generated are like + # /:account_id/projects, rather than /accounts/:account_id/projects. # - # === Options + # ### Options # - # Takes same options as Base#match and Resources#resources. + # Takes same options as `Base#match` and `Resources#resources`. # - # # route /posts (without the prefix /admin) to Admin::PostsController - # scope module: "admin" do - # resources :posts - # end + # # route /posts (without the prefix /admin) to +Admin::PostsController+ + # scope module: "admin" do + # resources :posts + # end # - # # prefix the posts resource's requests with '/admin' - # scope path: "/admin" do - # resources :posts - # end + # # prefix the posts resource's requests with '/admin' + # scope path: "/admin" do + # resources :posts + # end # - # # prefix the routing helper name: +sekret_posts_path+ instead of +posts_path+ - # scope as: "sekret" do - # resources :posts - # end + # # prefix the routing helper name: +sekret_posts_path+ instead of +posts_path+ + # scope as: "sekret" do + # resources :posts + # end # - # source://actionpack//lib/action_dispatch/routing/mapper.rb#825 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#869 def scope(*args); end private - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1040 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1088 def merge_action_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1024 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1072 def merge_as_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1064 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1112 def merge_blocks_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1056 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1104 def merge_constraints_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1036 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1084 def merge_controller_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1060 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1108 def merge_defaults_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1048 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1096 def merge_format_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1032 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1080 def merge_module_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1070 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1118 def merge_options_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1052 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1100 def merge_path_names_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1016 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1064 def merge_path_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1020 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1068 def merge_shallow_path_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1028 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1076 def merge_shallow_prefix_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1074 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1122 def merge_shallow_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1078 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1126 def merge_to_scope(parent, child); end - # source://actionpack//lib/action_dispatch/routing/mapper.rb#1044 + # source://actionpack//lib/action_dispatch/routing/mapper.rb#1092 def merge_via_scope(parent, child); end end -# source://actionpack//lib/action_dispatch/routing/mapper.rb#877 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#921 ActionDispatch::Routing::Mapper::Scoping::POISON = T.let(T.unsafe(nil), Object) -# source://actionpack//lib/action_dispatch/routing/mapper.rb#13 +# source://actionpack//lib/action_dispatch/routing/mapper.rb#24 ActionDispatch::Routing::Mapper::URL_OPTIONS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/redirection.rb#103 +# source://actionpack//lib/action_dispatch/routing/redirection.rb#114 class ActionDispatch::Routing::OptionRedirect < ::ActionDispatch::Routing::Redirect - # source://actionpack//lib/action_dispatch/routing/redirection.rb#132 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#143 def inspect; end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#11 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#13 def options; end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#106 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#117 def path(params, request); end end -# source://actionpack//lib/action_dispatch/routing/redirection.rb#78 +# source://actionpack//lib/action_dispatch/routing/redirection.rb#89 class ActionDispatch::Routing::PathRedirect < ::ActionDispatch::Routing::Redirect - # source://actionpack//lib/action_dispatch/routing/redirection.rb#93 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#104 def inspect; end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#81 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#92 def path(params, request); end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/redirection.rb#98 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#109 def interpolation_required?(string, params); end end -# source://actionpack//lib/action_dispatch/routing/redirection.rb#79 +# source://actionpack//lib/action_dispatch/routing/redirection.rb#90 ActionDispatch::Routing::PathRedirect::URL_PARTS = T.let(T.unsafe(nil), Regexp) -# Polymorphic URL helpers are methods for smart resolution to a named route call when -# given an Active Record model instance. They are to be used in combination with -# ActionController::Resources. +# # Action Dispatch Routing PolymorphicRoutes # -# These methods are useful when you want to generate the correct URL or path to a RESTful -# resource without having to know the exact type of the record in question. +# Polymorphic URL helpers are methods for smart resolution to a named route call +# when given an Active Record model instance. They are to be used in combination +# with ActionController::Resources. # -# Nested resources and/or namespaces are also supported, as illustrated in the example: +# These methods are useful when you want to generate the correct URL or path to +# a RESTful resource without having to know the exact type of the record in +# question. # -# polymorphic_url([:admin, @article, @comment]) +# Nested resources and/or namespaces are also supported, as illustrated in the +# example: +# +# polymorphic_url([:admin, @article, @comment]) # # results in: # -# admin_article_comment_url(@article, @comment) +# admin_article_comment_url(@article, @comment) +# +# ## Usage within the framework # -# == Usage within the framework +# Polymorphic URL helpers are used in a number of places throughout the Rails +# framework: # -# Polymorphic URL helpers are used in a number of places throughout the \Rails framework: +# * `url_for`, so you can use it with a record as the argument, e.g. +# `url_for(@article)`; +# * ActionView::Helpers::FormHelper uses `polymorphic_path`, so you can write +# `form_for(@article)` without having to specify `:url` parameter for the +# form action; +# * `redirect_to` (which, in fact, uses `url_for`) so you can write +# `redirect_to(post)` in your controllers; +# * ActionView::Helpers::AtomFeedHelper, so you don't have to explicitly +# specify URLs for feed entries. # -# * url_for, so you can use it with a record as the argument, e.g. -# url_for(@article); -# * ActionView::Helpers::FormHelper uses polymorphic_path, so you can write -# form_for(@article) without having to specify :url parameter for the form -# action; -# * redirect_to (which, in fact, uses url_for) so you can write -# redirect_to(post) in your controllers; -# * ActionView::Helpers::AtomFeedHelper, so you don't have to explicitly specify URLs -# for feed entries. # -# == Prefixed polymorphic helpers +# ## Prefixed polymorphic helpers # -# In addition to polymorphic_url and polymorphic_path methods, a -# number of prefixed helpers are available as a shorthand to action: "..." -# in options. Those are: +# In addition to `polymorphic_url` and `polymorphic_path` methods, a number of +# prefixed helpers are available as a shorthand to `action: "..."` in options. +# Those are: +# +# * `edit_polymorphic_url`, `edit_polymorphic_path` +# * `new_polymorphic_url`, `new_polymorphic_path` # -# * edit_polymorphic_url, edit_polymorphic_path -# * new_polymorphic_url, new_polymorphic_path # # Example usage: # -# edit_polymorphic_path(@post) # => "/posts/1/edit" -# polymorphic_path(@post, format: :pdf) # => "/posts/1.pdf" +# edit_polymorphic_path(@post) # => "/posts/1/edit" +# polymorphic_path(@post, format: :pdf) # => "/posts/1.pdf" # -# == Usage with mounted engines +# ## Usage with mounted engines # # If you are using a mounted engine and you need to use a polymorphic_url # pointing at the engine's routes, pass in the engine's route proxy as the first # argument to the method. For example: # -# polymorphic_url([blog, @post]) # calls blog.post_path(@post) -# form_for([blog, @post]) # => "/blog/posts/1" +# polymorphic_url([blog, @post]) # calls blog.post_path(@post) +# form_for([blog, @post]) # => "/blog/posts/1" # -# source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#57 +# source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#66 module ActionDispatch::Routing::PolymorphicRoutes - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#153 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#162 def edit_polymorphic_path(record_or_hash, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#149 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#158 def edit_polymorphic_url(record_or_hash, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#153 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#162 def new_polymorphic_path(record_or_hash, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#149 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#158 def new_polymorphic_url(record_or_hash, options = T.unsafe(nil)); end # Returns the path component of a URL for the given record. # - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#124 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#133 def polymorphic_path(record_or_hash_or_array, options = T.unsafe(nil)); end - # Constructs a call to a named RESTful route for the given record and returns the - # resulting URL string. For example: + # Constructs a call to a named RESTful route for the given record and returns + # the resulting URL string. For example: + # + # # calls post_url(post) + # polymorphic_url(post) # => "http://example.com/posts/1" + # polymorphic_url([blog, post]) # => "http://example.com/blogs/1/posts/1" + # polymorphic_url([:admin, blog, post]) # => "http://example.com/admin/blogs/1/posts/1" + # polymorphic_url([user, :blog, post]) # => "http://example.com/users/1/blog/posts/1" + # polymorphic_url(Comment) # => "http://example.com/comments" # - # # calls post_url(post) - # polymorphic_url(post) # => "http://example.com/posts/1" - # polymorphic_url([blog, post]) # => "http://example.com/blogs/1/posts/1" - # polymorphic_url([:admin, blog, post]) # => "http://example.com/admin/blogs/1/posts/1" - # polymorphic_url([user, :blog, post]) # => "http://example.com/users/1/blog/posts/1" - # polymorphic_url(Comment) # => "http://example.com/comments" + # #### Options # - # ==== Options + # * `:action` - Specifies the action prefix for the named route: `:new` or + # `:edit`. Default is no prefix. + # * `:routing_type` - Allowed values are `:path` or `:url`. Default is `:url`. # - # * :action - Specifies the action prefix for the named route: - # :new or :edit. Default is no prefix. - # * :routing_type - Allowed values are :path or :url. - # Default is :url. # - # Also includes all the options from url_for. These include such - # things as :anchor or :trailing_slash. Example usage - # is given below: + # Also includes all the options from `url_for`. These include such things as + # `:anchor` or `:trailing_slash`. Example usage is given below: # - # polymorphic_url([blog, post], anchor: 'my_anchor') - # # => "http://example.com/blogs/1/posts/1#my_anchor" - # polymorphic_url([blog, post], anchor: 'my_anchor', script_name: "/my_app") - # # => "http://example.com/my_app/blogs/1/posts/1#my_anchor" + # polymorphic_url([blog, post], anchor: 'my_anchor') + # # => "http://example.com/blogs/1/posts/1#my_anchor" + # polymorphic_url([blog, post], anchor: 'my_anchor', script_name: "/my_app") + # # => "http://example.com/my_app/blogs/1/posts/1#my_anchor" # - # For all of these options, see the documentation for {url_for}[rdoc-ref:ActionDispatch::Routing::UrlFor]. + # For all of these options, see the documentation for + # [url_for](rdoc-ref:ActionDispatch::Routing::UrlFor). # - # ==== Functionality + # #### Functionality # - # # an Article record - # polymorphic_url(record) # same as article_url(record) + # # an Article record + # polymorphic_url(record) # same as article_url(record) # - # # a Comment record - # polymorphic_url(record) # same as comment_url(record) + # # a Comment record + # polymorphic_url(record) # same as comment_url(record) # - # # it recognizes new records and maps to the collection - # record = Comment.new - # polymorphic_url(record) # same as comments_url() + # # it recognizes new records and maps to the collection + # record = Comment.new + # polymorphic_url(record) # same as comments_url() # - # # the class of a record will also map to the collection - # polymorphic_url(Comment) # same as comments_url() + # # the class of a record will also map to the collection + # polymorphic_url(Comment) # same as comments_url() # - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#101 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#110 def polymorphic_url(record_or_hash_or_array, options = T.unsafe(nil)); end private - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#168 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#177 def polymorphic_mapping(record); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#164 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#173 def polymorphic_path_for_action(action, record_or_hash, options); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#160 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#169 def polymorphic_url_for_action(action, record_or_hash, options); end end -# source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#176 +# source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#185 class ActionDispatch::Routing::PolymorphicRoutes::HelperMethodBuilder # @return [HelperMethodBuilder] a new instance of HelperMethodBuilder # - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#239 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#248 def initialize(key_strategy, prefix, suffix); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#253 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#262 def handle_class(klass); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#257 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#266 def handle_class_call(target, klass); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#284 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#293 def handle_list(list); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#261 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#270 def handle_model(record); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#275 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#284 def handle_model_call(target, record); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#245 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#254 def handle_string(record); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#249 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#258 def handle_string_call(target, str); end # Returns the value of attribute prefix. # - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#237 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#246 def prefix; end # Returns the value of attribute suffix. # - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#237 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#246 def suffix; end private - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#338 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#347 def get_method_for_class(klass); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#343 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#352 def get_method_for_string(str); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#330 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#339 def polymorphic_mapping(target, record); end class << self - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#187 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#196 def build(action, type); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#179 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#188 def get(action, type); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#185 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#194 def path; end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#201 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#210 def plural(prefix, suffix); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#205 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#214 def polymorphic_method(recipient, record_or_hash_or_array, action, type, options); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#197 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#206 def singular(prefix, suffix); end - # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#184 + # source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#193 def url; end end end -# source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#177 +# source://actionpack//lib/action_dispatch/routing/polymorphic_routes.rb#186 ActionDispatch::Routing::PolymorphicRoutes::HelperMethodBuilder::CACHE = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/routing/redirection.rb#10 +# source://actionpack//lib/action_dispatch/routing/redirection.rb#12 class ActionDispatch::Routing::Redirect < ::ActionDispatch::Routing::Endpoint # @return [Redirect] a new instance of Redirect # - # source://actionpack//lib/action_dispatch/routing/redirection.rb#13 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#15 def initialize(status, block); end # Returns the value of attribute block. # - # source://actionpack//lib/action_dispatch/routing/redirection.rb#11 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#13 def block; end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#20 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#35 + def build_response(req); end + + # source://actionpack//lib/action_dispatch/routing/redirection.rb#22 def call(env); end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#56 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#67 def inspect; end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#52 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#63 def path(params, request); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/redirection.rb#18 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#20 def redirect?; end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#24 - def serve(req); end - # Returns the value of attribute status. # - # source://actionpack//lib/action_dispatch/routing/redirection.rb#11 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#13 def status; end private - # source://actionpack//lib/action_dispatch/routing/redirection.rb#65 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#76 def escape(params); end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#69 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#80 def escape_fragment(params); end - # source://actionpack//lib/action_dispatch/routing/redirection.rb#73 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#84 def escape_path(params); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/redirection.rb#61 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#72 def relative_path?(path); end end -# source://actionpack//lib/action_dispatch/routing/redirection.rb#137 +# source://actionpack//lib/action_dispatch/routing/redirection.rb#148 module ActionDispatch::Routing::Redirection # Redirect any path to another path: # - # get "/stories" => redirect("/posts") + # get "/stories" => redirect("/posts") # - # This will redirect the user, while ignoring certain parts of the request, including query string, etc. - # /stories, /stories?foo=bar, etc all redirect to /posts. + # This will redirect the user, while ignoring certain parts of the request, + # including query string, etc. `/stories`, `/stories?foo=bar`, etc all redirect + # to `/posts`. # - # The redirect will use a 301 Moved Permanently status code by - # default. This can be overridden with the +:status+ option: + # The redirect will use a `301 Moved Permanently` status code by default. This + # can be overridden with the `:status` option: # - # get "/stories" => redirect("/posts", status: 307) + # get "/stories" => redirect("/posts", status: 307) # # You can also use interpolation in the supplied redirect argument: # - # get 'docs/:article', to: redirect('/wiki/%{article}') + # get 'docs/:article', to: redirect('/wiki/%{article}') # - # Note that if you return a path without a leading slash then the URL is prefixed with the - # current SCRIPT_NAME environment variable. This is typically '/' but may be different in - # a mounted engine or where the application is deployed to a subdirectory of a website. + # Note that if you return a path without a leading slash then the URL is + # prefixed with the current SCRIPT_NAME environment variable. This is typically + # '/' but may be different in a mounted engine or where the application is + # deployed to a subdirectory of a website. # # Alternatively you can use one of the other syntaxes: # - # The block version of redirect allows for the easy encapsulation of any logic associated with - # the redirect in question. Either the params and request are supplied as arguments, or just - # params, depending of how many arguments your block accepts. A string is required as a - # return value. + # The block version of redirect allows for the easy encapsulation of any logic + # associated with the redirect in question. Either the params and request are + # supplied as arguments, or just params, depending of how many arguments your + # block accepts. A string is required as a return value. # - # get 'jokes/:number', to: redirect { |params, request| - # path = (params[:number].to_i.even? ? "wheres-the-beef" : "i-love-lamp") - # "http://#{request.host_with_port}/#{path}" - # } + # get 'jokes/:number', to: redirect { |params, request| + # path = (params[:number].to_i.even? ? "wheres-the-beef" : "i-love-lamp") + # "http://#{request.host_with_port}/#{path}" + # } # - # Note that the do end syntax for the redirect block wouldn't work, as Ruby would pass - # the block to +get+ instead of +redirect+. Use { ... } instead. + # Note that the `do end` syntax for the redirect block wouldn't work, as Ruby + # would pass the block to `get` instead of `redirect`. Use `{ ... }` instead. # - # The options version of redirect allows you to supply only the parts of the URL which need - # to change, it also supports interpolation of the path similar to the first example. + # The options version of redirect allows you to supply only the parts of the URL + # which need to change, it also supports interpolation of the path similar to + # the first example. # - # get 'stores/:name', to: redirect(subdomain: 'stores', path: '/%{name}') - # get 'stores/:name(*all)', to: redirect(subdomain: 'stores', path: '/%{name}%{all}') - # get '/stories', to: redirect(path: '/posts') + # get 'stores/:name', to: redirect(subdomain: 'stores', path: '/%{name}') + # get 'stores/:name(*all)', to: redirect(subdomain: 'stores', path: '/%{name}%{all}') + # get '/stories', to: redirect(path: '/posts') # - # This will redirect the user, while changing only the specified parts of the request, - # for example the +path+ option in the last example. - # /stories, /stories?foo=bar, redirect to /posts and /posts?foo=bar respectively. + # This will redirect the user, while changing only the specified parts of the + # request, for example the `path` option in the last example. `/stories`, + # `/stories?foo=bar`, redirect to `/posts` and `/posts?foo=bar` respectively. # - # Finally, an object which responds to call can be supplied to redirect, allowing you to reuse - # common redirect routes. The call method must accept two arguments, params and request, and return - # a string. + # Finally, an object which responds to call can be supplied to redirect, + # allowing you to reuse common redirect routes. The call method must accept two + # arguments, params and request, and return a string. # - # get 'accounts/:name' => redirect(SubdomainRedirector.new('api')) + # get 'accounts/:name' => redirect(SubdomainRedirector.new('api')) # # @raise [ArgumentError] # - # source://actionpack//lib/action_dispatch/routing/redirection.rb#190 + # source://actionpack//lib/action_dispatch/routing/redirection.rb#204 def redirect(*args, &block); end end -# :stopdoc: +# The RouteSet contains a collection of Route instances, representing the routes +# typically defined in `config/routes.rb`. # -# source://actionpack//lib/action_dispatch/routing/route_set.rb#14 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#17 class ActionDispatch::Routing::RouteSet # @return [RouteSet] a new instance of RouteSet # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#366 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#384 def initialize(config = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#615 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#664 def add_polymorphic_mapping(klass, options, &block); end # @raise [ArgumentError] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#584 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#633 def add_route(mapping, name); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#619 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#668 def add_url_helper(name, options, &block); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#395 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#415 def api_only?; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#415 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#454 def append(&block); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#849 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#893 def call(env); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#439 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#478 def clear!; end + # source://actionpack//lib/action_dispatch/routing/route_set.rb#428 + def default_env; end + # Returns the value of attribute default_scope. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def default_scope; end # Sets the attribute default_scope # # @param value the value to set the attribute default_scope to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def default_scope=(_arg0); end # Returns the value of attribute default_url_options. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#356 def default_url_options; end # Sets the attribute default_url_options # # @param value the value to set the attribute default_url_options to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#356 def default_url_options=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#461 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#499 def define_mounted_helper(name, script_namer = T.unsafe(nil)); end # Returns the value of attribute disable_clear_and_finalize. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#355 def disable_clear_and_finalize; end # Sets the attribute disable_clear_and_finalize # # @param value the value to set the attribute disable_clear_and_finalize to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#355 def disable_clear_and_finalize=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#408 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#447 def draw(&block); end # Returns the value of attribute draw_paths. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#356 def draw_paths; end # Sets the attribute draw_paths # # @param value the value to set the attribute draw_paths to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#356 def draw_paths=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#385 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#404 def eager_load!; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#580 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#629 def empty?; end # Returns the value of attribute env_key. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#339 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#357 def env_key; end - # Generate the path indicated by the arguments, and return an array of - # the keys that were not used to generate it. + # Generate the path indicated by the arguments, and return an array of the keys + # that were not used to generate it. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#760 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#808 def extra_keys(options, recall = T.unsafe(nil)); end - # source://devise/4.9.2/lib/devise/rails/routes.rb#8 + # source://devise/4.9.4/lib/devise/rails/routes.rb#8 def finalize!; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#792 - def find_relative_url_root(options); end - - # source://actionpack//lib/action_dispatch/routing/route_set.rb#788 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#836 def find_script_name(options); end # Returns the value of attribute formatter. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def formatter; end # Sets the attribute formatter # # @param value the value to set the attribute formatter to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def formatter=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#764 + # Returns a Route matching the given requirements, or `nil` if none are found. + # + # This is intended for use by tools such as Language Servers. + # + # Given the routes are defined as: + # + # resources :posts + # + # Then the following will return the Route for the `show` action: + # + # Rails.application.routes.from_requirements(controller: "posts", action: "show") + # + # source://actionpack//lib/action_dispatch/routing/route_set.rb#29 + def from_requirements(requirements); end + + # source://actionpack//lib/action_dispatch/routing/route_set.rb#812 def generate_extras(options, recall = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#488 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#526 def generate_url_helpers(supports_path); end - # Since the router holds references to many parts of the system - # like engines, controllers and the application itself, inspecting - # the route set can actually be really slow, therefore we default - # alias inspect to to_s. + # Since the router holds references to many parts of the system like engines, + # controllers and the application itself, inspecting the route set can actually + # be really slow, therefore we default alias inspect to to_s. def inspect; end - # Contains all the mounted helpers across different - # engines and the `main_app` helper for the application. - # You can include this in your classes if you want to - # access routes for other engines. + # Contains all the mounted helpers across different engines and the `main_app` + # helper for the application. You can include this in your classes if you want + # to access routes for other engines. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#457 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#495 def mounted_helpers; end # Returns the value of attribute named_routes. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def named_routes; end # Sets the attribute named_routes # # @param value the value to set the attribute named_routes to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def named_routes=(_arg0); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#784 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#832 def optimize_routes_generation?; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#796 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#840 def path_for(options, route_name = T.unsafe(nil), reserved = T.unsafe(nil)); end # Returns the value of attribute polymorphic_mappings. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#339 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#357 def polymorphic_mappings; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#419 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#458 def prepend(&block); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#855 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#899 def recognize_path(path, environment = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#870 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#914 def recognize_path_with_request(req, path, extras, raise_on_missing: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#391 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#411 def relative_url_root; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#399 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#419 def request_class; end # Returns the value of attribute resources_path_names. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#355 def resources_path_names; end # Sets the attribute resources_path_names # # @param value the value to set the attribute resources_path_names to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#355 def resources_path_names=(_arg0); end # Returns the value of attribute router. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def router; end # Sets the attribute router # # @param value the value to set the attribute router to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def router=(_arg0); end # Returns the value of attribute set. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def routes; end # Returns the value of attribute set. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def set; end # Sets the attribute set # # @param value the value to set the attribute set to. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#354 def set=(_arg0); end - # The +options+ argument must be a hash whose keys are *symbols*. + # The `options` argument must be a hash whose keys are **symbols**. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#801 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#845 def url_for(options, route_name = T.unsafe(nil), url_strategy = T.unsafe(nil), method_name = T.unsafe(nil), reserved = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#480 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#518 def url_helpers(supports_path = T.unsafe(nil)); end private - # source://actionpack//lib/action_dispatch/routing/route_set.rb#423 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#462 def eval_block(block); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#775 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#823 def generate(route_name, options, recall = T.unsafe(nil), method_name = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#403 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#423 def make_request(env); end class << self - # source://actionpack//lib/action_dispatch/routing/route_set.rb#343 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#361 def default_resources_path_names; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#347 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#365 def new_with_config(config); end end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#362 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#380 class ActionDispatch::Routing::RouteSet::Config < ::Struct # Returns the value of attribute api_only # @@ -17859,149 +18993,148 @@ class ActionDispatch::Routing::RouteSet::Config < ::Struct end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#623 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#672 class ActionDispatch::Routing::RouteSet::CustomUrlHelper # @return [CustomUrlHelper] a new instance of CustomUrlHelper # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#626 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#675 def initialize(name, defaults, &block); end # Returns the value of attribute block. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#624 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#673 def block; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#632 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#681 def call(t, args, only_path = T.unsafe(nil)); end # Returns the value of attribute defaults. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#624 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#673 def defaults; end # Returns the value of attribute name. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#624 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#673 def name; end private - # source://actionpack//lib/action_dispatch/routing/route_set.rb#644 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#693 def eval_block(t, args, options); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#648 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#697 def merge_defaults(options); end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#364 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#382 ActionDispatch::Routing::RouteSet::DEFAULT_CONFIG = T.let(T.unsafe(nil), ActionDispatch::Routing::RouteSet::Config) -# source://actionpack//lib/action_dispatch/routing/route_set.rb#21 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#39 class ActionDispatch::Routing::RouteSet::Dispatcher < ::ActionDispatch::Routing::Endpoint # @return [Dispatcher] a new instance of Dispatcher # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#22 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#40 def initialize(raise_on_name_error); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#26 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#44 def dispatcher?; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#28 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#46 def serve(req); end private - # source://actionpack//lib/action_dispatch/routing/route_set.rb#42 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#60 def controller(req); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#48 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#66 def dispatch(controller, action, req, res); end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#653 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#702 class ActionDispatch::Routing::RouteSet::Generator # @return [Generator] a new instance of Generator # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#656 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#705 def initialize(named_route, options, recall, set); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#668 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#717 def controller; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#672 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#721 def current_controller; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#743 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#791 def different_controller?; end # Generates a path from routes, returns a RouteWithParams or MissingRoute. # MissingRoute will raise ActionController::UrlGenerationError. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#739 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#787 def generate; end # Returns the value of attribute named_route. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#654 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#703 def named_route; end # Remove leading slashes from controllers # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#727 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#775 def normalize_controller!; end - # This pulls :controller, :action, and :id out of the recall. - # The recall key is only used if there is no key in the options - # or if the key in the options is identical. If any of - # :controller, :action or :id is not found, don't pull any + # This pulls :controller, :action, and :id out of the recall. The recall key is + # only used if there is no key in the options or if the key in the options is + # identical. If any of :controller, :action or :id is not found, don't pull any # more keys from the recall. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#709 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#757 def normalize_controller_action_id!; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#684 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#733 def normalize_options!; end # Returns the value of attribute options. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#654 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#703 def options; end # Returns the value of attribute recall. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#654 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#703 def recall; end # Returns the value of attribute set. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#654 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#703 def set; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#676 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#725 def use_recall_for(key); end - # if the current controller is "foo/bar/baz" and controller: "baz/bat" - # is specified, the controller becomes "foo/baz/bat" + # if the current controller is "foo/bar/baz" and controller: "baz/bat" is + # specified, the controller becomes "foo/baz/bat" # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#717 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#765 def use_relative_controller!; end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#749 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#797 def named_route_exists?; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#753 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#801 def segment_keys; end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#448 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#487 module ActionDispatch::Routing::RouteSet::MountedHelpers extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -18026,415 +19159,423 @@ end # maintains an anonymous module that can be used to install helpers for the # named routes. # -# source://actionpack//lib/action_dispatch/routing/route_set.rb#66 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#84 class ActionDispatch::Routing::RouteSet::NamedRouteCollection include ::Enumerable # @return [NamedRouteCollection] a new instance of NamedRouteCollection # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#71 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#89 def initialize; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#121 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#139 def [](name); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#102 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#120 def []=(name, route); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#102 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#120 def add(name, route); end - # Given a +name+, defines name_path and name_url helpers. - # Used by 'direct', 'resolve', and 'polymorphic' route helpers. + # Given a `name`, defines name_path and name_url helpers. Used by 'direct', + # 'resolve', and 'polymorphic' route helpers. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#149 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#167 def add_url_helper(name, defaults, &block); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#88 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#106 def clear; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#88 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#106 def clear!; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#134 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#152 def each(&block); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#121 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#139 def get(name); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#84 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#102 def helper_names; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#125 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#143 def key?(name); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#143 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#161 def length; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#139 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#157 def names; end # Returns the value of attribute path_helpers_module. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#68 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#86 def path_helpers_module; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#79 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#97 def route_defined?(name); end # Returns the value of attribute url_helpers_module. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#68 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#86 def url_helpers_module; end private - # Create a URL helper allowing ordered parameters to be associated - # with corresponding dynamic segments, so you can do: + # Create a URL helper allowing ordered parameters to be associated with + # corresponding dynamic segments, so you can do: # - # foo_url(bar, baz, bang) + # foo_url(bar, baz, bang) # # Instead of: # - # foo_url(bar: bar, baz: baz, bang: bang) + # foo_url(bar: bar, baz: baz, bang: bang) # # Also allow options hash, so you can do: # - # foo_url(bar, baz, bang, sort_by: 'baz') + # foo_url(bar, baz, bang, sort_by: 'baz') # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#317 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#335 def define_url_helper(mod, name, helper, url_strategy); end # Returns the value of attribute routes. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#68 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#86 def routes; end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#172 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#190 class ActionDispatch::Routing::RouteSet::NamedRouteCollection::UrlHelper # @return [UrlHelper] a new instance of UrlHelper # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#255 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#273 def initialize(route, options, route_name); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#262 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#280 def call(t, method_name, args, inner_options, url_strategy); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#274 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#292 def handle_positional_args(controller_options, inner_options, args, result, path_params); end # Returns the value of attribute route_name. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#185 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#203 def route_name; end class << self - # source://actionpack//lib/action_dispatch/routing/route_set.rb#173 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#191 def create(route, options, route_name); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#181 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#199 def optimize_helper?(route); end end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#187 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#205 class ActionDispatch::Routing::RouteSet::NamedRouteCollection::UrlHelper::OptimizedUrlHelper < ::ActionDispatch::Routing::RouteSet::NamedRouteCollection::UrlHelper # @return [OptimizedUrlHelper] a new instance of OptimizedUrlHelper # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#190 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#208 def initialize(route, options, route_name); end # Returns the value of attribute arg_size. # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#188 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#206 def arg_size; end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#196 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#214 def call(t, method_name, args, inner_options, url_strategy); end private # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#227 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#245 def optimize_routes_generation?(t); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#219 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#237 def optimized_helper(args); end - # source://actionpack//lib/action_dispatch/routing/route_set.rb#231 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#249 def parameterize_args(args); end # @raise [ActionController::UrlGenerationError] # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#242 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#260 def raise_generation_error(args); end end # strategy for building URLs to send to the client # -# source://actionpack//lib/action_dispatch/routing/route_set.rb#333 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#351 ActionDispatch::Routing::RouteSet::PATH = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_dispatch/routing/route_set.rb#780 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#828 ActionDispatch::Routing::RouteSet::RESERVED_OPTIONS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/routing/route_set.rb#53 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#71 class ActionDispatch::Routing::RouteSet::StaticDispatcher < ::ActionDispatch::Routing::RouteSet::Dispatcher # @return [StaticDispatcher] a new instance of StaticDispatcher # - # source://actionpack//lib/action_dispatch/routing/route_set.rb#54 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#72 def initialize(controller_class); end private - # source://actionpack//lib/action_dispatch/routing/route_set.rb#60 + # source://actionpack//lib/action_dispatch/routing/route_set.rb#78 def controller(_); end end -# source://actionpack//lib/action_dispatch/routing/route_set.rb#334 +# source://actionpack//lib/action_dispatch/routing/route_set.rb#352 ActionDispatch::Routing::RouteSet::UNKNOWN = T.let(T.unsafe(nil), Proc) -# source://actionpack//lib/action_dispatch/routing/inspector.rb#8 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#10 class ActionDispatch::Routing::RouteWrapper < ::SimpleDelegator - # source://actionpack//lib/action_dispatch/routing/inspector.rb#41 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#56 def action; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#13 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#28 def constraints; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#37 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#52 def controller; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#9 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#17 def endpoint; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/inspector.rb#49 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#64 def engine?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/inspector.rb#45 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#60 def internal?; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#25 + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/routing/inspector.rb#11 + def matches_filter?(filter, value); end + + # source://actionpack//lib/action_dispatch/routing/inspector.rb#40 def name; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#21 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#36 def path; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#17 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#32 def rack_app; end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#29 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#44 def reqs; end end # This class is just used for displaying route information when someone -# executes `bin/rails routes` or looks at the RoutingError page. -# People should not use this class. +# executes `bin/rails routes` or looks at the RoutingError page. People should +# not use this class. # -# source://actionpack//lib/action_dispatch/routing/inspector.rb#58 +# source://actionpack//lib/action_dispatch/routing/inspector.rb#73 class ActionDispatch::Routing::RoutesInspector # @return [RoutesInspector] a new instance of RoutesInspector # - # source://actionpack//lib/action_dispatch/routing/inspector.rb#59 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#74 def initialize(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#64 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#79 def format(formatter, filter = T.unsafe(nil)); end private - # source://actionpack//lib/action_dispatch/routing/inspector.rb#117 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#143 def collect_engine_routes(route); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#104 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#129 def collect_routes(routes); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#93 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#118 def filter_routes(filter); end - # source://actionpack//lib/action_dispatch/routing/inspector.rb#84 + # source://actionpack//lib/action_dispatch/routing/inspector.rb#99 def normalize_filter(filter); end end -# source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#7 +# source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#9 class ActionDispatch::Routing::RoutesProxy include ::ActionDispatch::Routing::PolymorphicRoutes include ::ActionDispatch::Routing::UrlFor # @return [RoutesProxy] a new instance of RoutesProxy # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#13 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#15 def initialize(routes, scope, helpers, script_namer = T.unsafe(nil)); end # Returns the value of attribute routes. # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#10 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#12 def _routes; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end # Returns the value of attribute routes. # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#10 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#12 def routes; end # Sets the attribute routes # # @param value the value to set the attribute routes to. # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#10 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#12 def routes=(_arg0); end # Returns the value of attribute scope. # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#10 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#12 def scope; end # Sets the attribute scope # # @param value the value to set the attribute scope to. # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#10 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#12 def scope=(_arg0); end - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#19 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#21 def url_options; end private - # Keeps the part of the script name provided by the global - # context via ENV["SCRIPT_NAME"], which `mount` doesn't know - # about since it depends on the specific request, but use our - # script name resolver for the mount point dependent part. + # Keeps the part of the script name provided by the global context via + # [ENV]("SCRIPT_NAME"), which `mount` doesn't know about since it depends on the + # specific request, but use our script name resolver for the mount point + # dependent part. # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#58 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#55 def merge_script_names(previous_script_name, new_script_name); end - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#30 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#32 def method_missing(method, *args); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#26 + # source://actionpack//lib/action_dispatch/routing/routes_proxy.rb#28 def respond_to_missing?(method, _); end class << self - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end end end -# source://actionpack//lib/action_dispatch/routing.rb#257 +# source://actionpack//lib/action_dispatch/routing.rb#259 ActionDispatch::Routing::SEPARATORS = T.let(T.unsafe(nil), Array) -# In config/routes.rb you define URL-to-controller mappings, but the reverse +# # Action Dispatch Routing UrlFor +# +# In `config/routes.rb` you define URL-to-controller mappings, but the reverse # is also possible: a URL can be generated from one of your routing definitions. # URL generation functionality is centralized in this module. # -# See ActionDispatch::Routing for general information about routing and config/routes.rb. +# See ActionDispatch::Routing for general information about routing and +# `config/routes.rb`. # -# Tip: If you need to generate URLs from your models or some other place, +# **Tip:** If you need to generate URLs from your models or some other place, # then ActionDispatch::Routing::UrlFor is what you're looking for. Read on for -# an introduction. In general, this module should not be included on its own, -# as it is usually included by +url_helpers+ (as in Rails.application.routes.url_helpers). -# -# == URL generation from parameters -# -# As you may know, some functions, such as ActionController::Base#url_for -# and ActionView::Helpers::UrlHelper#link_to, can generate URLs given a set -# of parameters. For example, you've probably had the chance to write code -# like this in one of your views: -# -# <%= link_to('Click here', controller: 'users', -# action: 'new', message: 'Welcome!') %> -# # => Click here -# -# +link_to+, and all other functions that require URL generation functionality, -# actually use ActionDispatch::Routing::UrlFor under the hood. And in particular, -# they use the ActionDispatch::Routing::UrlFor#url_for method. One can generate -# the same path as the above example by using the following code: -# -# include ActionDispatch::Routing::UrlFor -# url_for(controller: 'users', -# action: 'new', -# message: 'Welcome!', -# only_path: true) -# # => "/users/new?message=Welcome%21" -# -# Notice the only_path: true part. This is because UrlFor has no -# information about the website hostname that your Rails app is serving. So if you -# want to include the hostname as well, then you must also pass the :host -# argument: -# -# include UrlFor -# url_for(controller: 'users', -# action: 'new', -# message: 'Welcome!', -# host: 'www.example.com') -# # => "http://www.example.com/users/new?message=Welcome%21" -# -# By default, all controllers and views have access to a special version of +url_for+, -# that already knows what the current hostname is. So if you use +url_for+ in your -# controllers or your views, then you don't need to explicitly pass the :host -# argument. +# an introduction. In general, this module should not be included on its own, as +# it is usually included by `url_helpers` (as in +# `Rails.application.routes.url_helpers`). +# +# ## URL generation from parameters +# +# As you may know, some functions, such as `ActionController::Base#url_for` and +# ActionView::Helpers::UrlHelper#link_to, can generate URLs given a set of +# parameters. For example, you've probably had the chance to write code like +# this in one of your views: +# +# <%= link_to('Click here', controller: 'users', +# action: 'new', message: 'Welcome!') %> +# # => Click here +# +# `link_to`, and all other functions that require URL generation functionality, +# actually use ActionDispatch::Routing::UrlFor under the hood. And in +# particular, they use the ActionDispatch::Routing::UrlFor#url_for method. One +# can generate the same path as the above example by using the following code: +# +# include ActionDispatch::Routing::UrlFor +# url_for(controller: 'users', +# action: 'new', +# message: 'Welcome!', +# only_path: true) +# # => "/users/new?message=Welcome%21" +# +# Notice the `only_path: true` part. This is because UrlFor has no information +# about the website hostname that your Rails app is serving. So if you want to +# include the hostname as well, then you must also pass the `:host` argument: +# +# include UrlFor +# url_for(controller: 'users', +# action: 'new', +# message: 'Welcome!', +# host: 'www.example.com') +# # => "http://www.example.com/users/new?message=Welcome%21" +# +# By default, all controllers and views have access to a special version of +# `url_for`, that already knows what the current hostname is. So if you use +# `url_for` in your controllers or your views, then you don't need to explicitly +# pass the `:host` argument. # # For convenience, mailers also include ActionDispatch::Routing::UrlFor. So -# within mailers, you can use url_for. However, mailers cannot access -# incoming web requests in order to derive hostname information, so you have -# to provide the +:host+ option or set the default host using -# +default_url_options+. For more information on url_for in mailers see the -# ActionMailer::Base documentation. -# +# within mailers, you can use url_for. However, mailers cannot access incoming +# web requests in order to derive hostname information, so you have to provide +# the `:host` option or set the default host using `default_url_options`. For +# more information on url_for in mailers see the ActionMailer::Base +# documentation. # -# == URL generation for named routes +# ## URL generation for named routes # # UrlFor also allows one to access methods that have been auto-generated from # named routes. For example, suppose that you have a 'users' resource in your -# config/routes.rb: +# `config/routes.rb`: # -# resources :users +# resources :users # -# This generates, among other things, the method users_path. By default, -# this method is accessible from your controllers, views, and mailers. If you need -# to access this auto-generated method from other places (such as a model), then -# you can do that by including Rails.application.routes.url_helpers in your class: +# This generates, among other things, the method `users_path`. By default, this +# method is accessible from your controllers, views, and mailers. If you need to +# access this auto-generated method from other places (such as a model), then +# you can do that by including `Rails.application.routes.url_helpers` in your +# class: # -# class User < ActiveRecord::Base -# include Rails.application.routes.url_helpers +# class User < ActiveRecord::Base +# include Rails.application.routes.url_helpers # -# def base_uri -# user_path(self) +# def base_uri +# user_path(self) +# end # end -# end # -# User.find(1).base_uri # => "/users/1" +# User.find(1).base_uri # => "/users/1" # -# source://actionpack//lib/action_dispatch/routing/url_for.rb#87 +# source://actionpack//lib/action_dispatch/routing/url_for.rb#92 module ActionDispatch::Routing::UrlFor include ::ActionDispatch::Routing::PolymorphicRoutes extend ::ActiveSupport::Concern @@ -18442,108 +19583,112 @@ module ActionDispatch::Routing::UrlFor mixes_in_class_methods GeneratedClassMethods - # source://actionpack//lib/action_dispatch/routing/url_for.rb#106 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#111 def initialize(*_arg0, **_arg1, &_arg2); end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#173 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#182 def full_url_for(options = T.unsafe(nil)); end # Allows calling direct or regular named route. # - # resources :buckets + # resources :buckets # - # direct :recordable do |recording| - # route_for(:bucket, recording.bucket) - # end + # direct :recordable do |recording| + # route_for(:bucket, recording.bucket) + # end # - # direct :threadable do |threadable| - # route_for(:recordable, threadable.parent) - # end + # direct :threadable do |threadable| + # route_for(:recordable, threadable.parent) + # end # - # This maintains the context of the original caller on - # whether to return a path or full URL, e.g: + # This maintains the context of the original caller on whether to return a path + # or full URL, e.g: # - # threadable_path(threadable) # => "/buckets/1" - # threadable_url(threadable) # => "http://example.com/buckets/1" + # threadable_path(threadable) # => "/buckets/1" + # threadable_url(threadable) # => "http://example.com/buckets/1" # - # source://actionpack//lib/action_dispatch/routing/url_for.rb#213 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#222 def route_for(name, *args); end - # Generate a URL based on the options provided, +default_url_options+, and the - # routes defined in config/routes.rb. The following options are supported: - # - # * :only_path - If true, the relative URL is returned. Defaults to +false+. - # * :protocol - The protocol to connect to. Defaults to "http". - # * :host - Specifies the host the link should be targeted at. - # If :only_path is false, this option must be - # provided either explicitly, or via +default_url_options+. - # * :subdomain - Specifies the subdomain of the link, using the +tld_length+ - # to split the subdomain from the host. - # If false, removes all subdomains from the host part of the link. - # * :domain - Specifies the domain of the link, using the +tld_length+ - # to split the domain from the host. - # * :tld_length - Number of labels the TLD id composed of, only used if - # :subdomain or :domain are supplied. Defaults to - # ActionDispatch::Http::URL.tld_length, which in turn defaults to 1. - # * :port - Optionally specify the port to connect to. - # * :anchor - An anchor name to be appended to the path. - # * :params - The query parameters to be appended to the path. - # * :trailing_slash - If true, adds a trailing slash, as in "/archive/2009/". - # * :script_name - Specifies application path relative to domain root. If provided, prepends application path. - # - # Any other key (:controller, :action, etc.) given to - # +url_for+ is forwarded to the Routes module. - # - # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', port: '8080' - # # => 'http://somehost.org:8080/tasks/testing' - # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', anchor: 'ok', only_path: true - # # => '/tasks/testing#ok' - # url_for controller: 'tasks', action: 'testing', trailing_slash: true - # # => 'http://somehost.org/tasks/testing/' - # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', number: '33' - # # => 'http://somehost.org/tasks/testing?number=33' - # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', script_name: "/myapp" - # # => 'http://somehost.org/myapp/tasks/testing' - # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', script_name: "/myapp", only_path: true - # # => '/myapp/tasks/testing' + # Generate a URL based on the options provided, `default_url_options`, and the + # routes defined in `config/routes.rb`. The following options are supported: + # + # * `:only_path` - If true, the relative URL is returned. Defaults to `false`. + # * `:protocol` - The protocol to connect to. Defaults to `"http"`. + # * `:host` - Specifies the host the link should be targeted at. If + # `:only_path` is false, this option must be provided either explicitly, or + # via `default_url_options`. + # * `:subdomain` - Specifies the subdomain of the link, using the `tld_length` + # to split the subdomain from the host. If false, removes all subdomains + # from the host part of the link. + # * `:domain` - Specifies the domain of the link, using the `tld_length` to + # split the domain from the host. + # * `:tld_length` - Number of labels the TLD id composed of, only used if + # `:subdomain` or `:domain` are supplied. Defaults to + # `ActionDispatch::Http::URL.tld_length`, which in turn defaults to 1. + # * `:port` - Optionally specify the port to connect to. + # * `:anchor` - An anchor name to be appended to the path. + # * `:params` - The query parameters to be appended to the path. + # * `:path_params` - The query parameters that will only be used for the named + # dynamic segments of path. If unused, they will be discarded. + # * `:trailing_slash` - If true, adds a trailing slash, as in + # `"/archive/2009/"`. + # * `:script_name` - Specifies application path relative to domain root. If + # provided, prepends application path. + # + # + # Any other key (`:controller`, `:action`, etc.) given to `url_for` is forwarded + # to the Routes module. + # + # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', port: '8080' + # # => 'http://somehost.org:8080/tasks/testing' + # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', anchor: 'ok', only_path: true + # # => '/tasks/testing#ok' + # url_for controller: 'tasks', action: 'testing', trailing_slash: true + # # => 'http://somehost.org/tasks/testing/' + # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', number: '33' + # # => 'http://somehost.org/tasks/testing?number=33' + # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', script_name: "/myapp" + # # => 'http://somehost.org/myapp/tasks/testing' + # url_for controller: 'tasks', action: 'testing', host: 'somehost.org', script_name: "/myapp", only_path: true + # # => '/myapp/tasks/testing' # # Missing routes keys may be filled in from the current request's parameters - # (e.g. +:controller+, +:action+, +:id+, and any other parameters that are - # placed in the path). Given that the current action has been reached - # through GET /users/1: + # (e.g. `:controller`, `:action`, `:id`, and any other parameters that are + # placed in the path). Given that the current action has been reached through + # `GET /users/1`: # - # url_for(only_path: true) # => '/users/1' - # url_for(only_path: true, action: 'edit') # => '/users/1/edit' - # url_for(only_path: true, action: 'edit', id: 2) # => '/users/2/edit' + # url_for(only_path: true) # => '/users/1' + # url_for(only_path: true, action: 'edit') # => '/users/1/edit' + # url_for(only_path: true, action: 'edit', id: 2) # => '/users/2/edit' # - # Notice that no +:id+ parameter was provided to the first +url_for+ call - # and the helper used the one from the route's path. Any path parameter - # implicitly used by +url_for+ can always be overwritten like shown on the - # last +url_for+ calls. + # Notice that no `:id` parameter was provided to the first `url_for` call and + # the helper used the one from the route's path. Any path parameter implicitly + # used by `url_for` can always be overwritten like shown on the last `url_for` + # calls. # - # source://actionpack//lib/action_dispatch/routing/url_for.rb#169 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#178 def url_for(options = T.unsafe(nil)); end - # Hook overridden in controller to add request information - # with +default_url_options+. Application logic should not - # go into url_options. + # Hook overridden in controller to add request information with + # `default_url_options`. Application logic should not go into url_options. # - # source://actionpack//lib/action_dispatch/routing/url_for.rb#114 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#118 def url_options; end protected # @return [Boolean] # - # source://actionpack//lib/action_dispatch/routing/url_for.rb#218 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#227 def optimize_routes_generation?; end private - # source://actionpack//lib/action_dispatch/routing/url_for.rb#230 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#239 def _routes_context; end - # source://actionpack//lib/action_dispatch/routing/url_for.rb#223 + # source://actionpack//lib/action_dispatch/routing/url_for.rb#232 def _with_routes(routes); end module GeneratedClassMethods @@ -18559,102 +19704,106 @@ module ActionDispatch::Routing::UrlFor end end -# This middleware is added to the stack when config.force_ssl = true, and is passed -# the options set in +config.ssl_options+. It does three jobs to enforce secure HTTP -# requests: +# # Action Dispatch SSL +# +# This middleware is added to the stack when `config.force_ssl = true`, and is +# passed the options set in `config.ssl_options`. It does three jobs to enforce +# secure HTTP requests: # -# 1. TLS redirect: Permanently redirects +http://+ requests to +https://+ -# with the same URL host, path, etc. Enabled by default. Set +config.ssl_options+ -# to modify the destination URL -# (e.g. redirect: { host: "secure.widgets.com", port: 8080 }), or set -# redirect: false to disable this feature. +# 1. **TLS redirect**: Permanently redirects `http://` requests to `https://` +# with the same URL host, path, etc. Enabled by default. Set +# `config.ssl_options` to modify the destination URL (e.g. `redirect: { +# host: "secure.widgets.com", port: 8080 }`), or set `redirect: false` to +# disable this feature. # -# Requests can opt-out of redirection with +exclude+: +# Requests can opt-out of redirection with `exclude`: # -# config.ssl_options = { redirect: { exclude: -> request { /healthcheck/.match?(request.path) } } } +# config.ssl_options = { redirect: { exclude: -> request { /healthcheck/.match?(request.path) } } } # -# Cookies will not be flagged as secure for excluded requests. +# Cookies will not be flagged as secure for excluded requests. # -# 2. Secure cookies: Sets the +secure+ flag on cookies to tell browsers they -# must not be sent along with +http://+ requests. Enabled by default. Set -# +config.ssl_options+ with secure_cookies: false to disable this feature. +# 2. **Secure cookies**: Sets the `secure` flag on cookies to tell browsers +# they must not be sent along with `http://` requests. Enabled by default. +# Set `config.ssl_options` with `secure_cookies: false` to disable this +# feature. # -# 3. HTTP Strict Transport Security (HSTS): Tells the browser to remember -# this site as TLS-only and automatically redirect non-TLS requests. -# Enabled by default. Configure +config.ssl_options+ with hsts: false to disable. +# 3. **HTTP Strict Transport Security (HSTS)**: Tells the browser to remember +# this site as TLS-only and automatically redirect non-TLS requests. Enabled +# by default. Configure `config.ssl_options` with `hsts: false` to disable. # -# Set +config.ssl_options+ with hsts: { ... } to configure HSTS: +# Set `config.ssl_options` with `hsts: { ... }` to configure HSTS: # -# * +expires+: How long, in seconds, these settings will stick. The minimum -# required to qualify for browser preload lists is 1 year. Defaults to -# 2 years (recommended). +# * `expires`: How long, in seconds, these settings will stick. The +# minimum required to qualify for browser preload lists is 1 year. +# Defaults to 2 years (recommended). # -# * +subdomains+: Set to +true+ to tell the browser to apply these settings -# to all subdomains. This protects your cookies from interception by a -# vulnerable site on a subdomain. Defaults to +true+. +# * `subdomains`: Set to `true` to tell the browser to apply these +# settings to all subdomains. This protects your cookies from +# interception by a vulnerable site on a subdomain. Defaults to `true`. # -# * +preload+: Advertise that this site may be included in browsers' -# preloaded HSTS lists. HSTS protects your site on every visit except the -# first visit since it hasn't seen your HSTS header yet. To close this -# gap, browser vendors include a baked-in list of HSTS-enabled sites. -# Go to https://hstspreload.org to submit your site for inclusion. -# Defaults to +false+. +# * `preload`: Advertise that this site may be included in browsers' +# preloaded HSTS lists. HSTS protects your site on every visit *except +# the first visit* since it hasn't seen your HSTS header yet. To close +# this gap, browser vendors include a baked-in list of HSTS-enabled +# sites. Go to https://hstspreload.org to submit your site for +# inclusion. Defaults to `false`. # -# To turn off HSTS, omitting the header is not enough. Browsers will remember the -# original HSTS directive until it expires. Instead, use the header to tell browsers to -# expire HSTS immediately. Setting hsts: false is a shortcut for -# hsts: { expires: 0 }. # -# source://actionpack//lib/action_dispatch/middleware/ssl.rb#49 +# To turn off HSTS, omitting the header is not enough. Browsers will +# remember the original HSTS directive until it expires. Instead, use the +# header to tell browsers to expire HSTS immediately. Setting `hsts: false` +# is a shortcut for `hsts: { expires: 0 }`. +# +# source://actionpack//lib/action_dispatch/middleware/ssl.rb#56 class ActionDispatch::SSL # @return [SSL] a new instance of SSL # - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#61 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#66 def initialize(app, redirect: T.unsafe(nil), hsts: T.unsafe(nil), secure_cookies: T.unsafe(nil), ssl_default_redirect_status: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#73 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#78 def call(env); end private # https://tools.ietf.org/html/rfc6797#section-6.1 # - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#107 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#112 def build_hsts_header(hsts); end - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#114 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#119 def flag_cookies_as_secure!(headers); end - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#145 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#160 def https_location_for(request); end - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#92 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#97 def normalize_hsts_options(options); end - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#128 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#143 def redirect_to_https(request); end - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#135 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#150 def redirection_status(request); end - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#88 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#93 def set_hsts_header!(headers); end class << self - # source://actionpack//lib/action_dispatch/middleware/ssl.rb#57 + # source://actionpack//lib/action_dispatch/middleware/ssl.rb#62 def default_hsts_options; end end end -# Default to 2 years as recommended on hstspreload.org. +# :stopdoc: Default to 2 years as recommended on hstspreload.org. # -# source://actionpack//lib/action_dispatch/middleware/ssl.rb#53 +# source://actionpack//lib/action_dispatch/middleware/ssl.rb#58 ActionDispatch::SSL::HSTS_EXPIRES_IN = T.let(T.unsafe(nil), Integer) -# source://actionpack//lib/action_dispatch/middleware/ssl.rb#55 +# source://actionpack//lib/action_dispatch/middleware/ssl.rb#60 ActionDispatch::SSL::PERMANENT_REDIRECT_REQUEST_METHODS = T.let(T.unsafe(nil), Array) -# source://actionpack//lib/action_dispatch/middleware/server_timing.rb#6 +# source://actionpack//lib/action_dispatch/middleware/server_timing.rb#8 class ActionDispatch::ServerTiming # @return [ServerTiming] a new instance of ServerTiming # @@ -18670,9 +19819,6 @@ class ActionDispatch::ServerTiming end end -# source://actionpack//lib/action_dispatch/middleware/server_timing.rb#7 -ActionDispatch::ServerTiming::SERVER_TIMING_HEADER = T.let(T.unsafe(nil), String) - # source://actionpack//lib/action_dispatch/middleware/server_timing.rb#9 class ActionDispatch::ServerTiming::Subscriber include ::Singleton @@ -18706,25 +19852,30 @@ end # source://actionpack//lib/action_dispatch/middleware/server_timing.rb#11 ActionDispatch::ServerTiming::Subscriber::KEY = T.let(T.unsafe(nil), Symbol) -# source://actionpack//lib/action_dispatch.rb#91 -module ActionDispatch::Session; end +# source://actionpack//lib/action_dispatch.rb#100 +module ActionDispatch::Session + class << self + # source://actionpack//lib/action_dispatch.rb#107 + def resolve_store(session_store); end + end +end -# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#90 +# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#97 class ActionDispatch::Session::AbstractSecureStore < ::Rack::Session::Abstract::PersistedSecure include ::ActionDispatch::Session::Compatibility include ::ActionDispatch::Session::StaleSessionCheck include ::ActionDispatch::Session::SessionObject - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#95 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#102 def generate_sid; end private - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#100 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#107 def set_cookie(request, response, cookie); end end -# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#79 +# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#86 class ActionDispatch::Session::AbstractStore < ::Rack::Session::Abstract::Persisted include ::ActionDispatch::Session::Compatibility include ::ActionDispatch::Session::StaleSessionCheck @@ -18732,864 +19883,966 @@ class ActionDispatch::Session::AbstractStore < ::Rack::Session::Abstract::Persis private - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#85 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#92 def set_cookie(request, response, cookie); end end -# A session store that uses an ActiveSupport::Cache::Store to store the sessions. This store is most useful -# if you don't store critical data in your sessions and you don't need them to live for extended periods -# of time. +# # Action Dispatch Session CacheStore +# +# A session store that uses an ActiveSupport::Cache::Store to store the +# sessions. This store is most useful if you don't store critical data in your +# sessions and you don't need them to live for extended periods of time. # -# ==== Options -# * cache - The cache to use. If it is not specified, Rails.cache will be used. -# * expire_after - The length of time a session will be stored before automatically expiring. -# By default, the :expires_in option of the cache is used. +# #### Options +# * `cache` - The cache to use. If it is not specified, `Rails.cache` +# will be used. +# * `expire_after` - The length of time a session will be stored before +# automatically expiring. By default, the `:expires_in` option of the cache +# is used. # -# source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#15 +# source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#22 class ActionDispatch::Session::CacheStore < ::ActionDispatch::Session::AbstractSecureStore # @return [CacheStore] a new instance of CacheStore # - # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#16 + # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#23 def initialize(app, options = T.unsafe(nil)); end # Remove a session from the cache. # - # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#42 + # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#49 def delete_session(env, sid, options); end # Get a session from the cache. # - # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#23 + # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#30 def find_session(env, sid); end # Set a session in the cache. # - # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#31 + # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#38 def write_session(env, sid, session, options); end private # Turn the session id into a cache key. # - # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#50 + # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#57 def cache_key(id); end - # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#54 + # source://actionpack//lib/action_dispatch/middleware/session/cache_store.rb#61 def get_session_with_fallback(sid); end end -# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#20 +# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#22 module ActionDispatch::Session::Compatibility - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#21 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#23 def initialize(app, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#26 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#28 def generate_sid; end private - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#33 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#35 def initialize_sid; end - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#38 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#40 def make_request(env); end end -# This cookie-based session store is the Rails default. It is -# dramatically faster than the alternatives. +# # Action Dispatch Session CookieStore +# +# This cookie-based session store is the Rails default. It is dramatically +# faster than the alternatives. # # Sessions typically contain at most a user ID and flash message; both fit -# within the 4096 bytes cookie size limit. A +CookieOverflow+ exception is raised if -# you attempt to store more than 4096 bytes of data. +# within the 4096 bytes cookie size limit. A `CookieOverflow` exception is +# raised if you attempt to store more than 4096 bytes of data. # -# The cookie jar used for storage is automatically configured to be the -# best possible option given your application's configuration. +# The cookie jar used for storage is automatically configured to be the best +# possible option given your application's configuration. # -# Your cookies will be encrypted using your application's +secret_key_base+. This -# goes a step further than signed cookies in that encrypted cookies cannot +# Your cookies will be encrypted using your application's `secret_key_base`. +# This goes a step further than signed cookies in that encrypted cookies cannot # be altered or read by users. This is the default starting in Rails 4. # # Configure your session store in an initializer: # -# Rails.application.config.session_store :cookie_store, key: '_your_app_session' +# Rails.application.config.session_store :cookie_store, key: '_your_app_session' # -# In the development and test environments your application's +secret_key_base+ is -# generated by Rails and stored in a temporary file in tmp/development_secret.txt. -# In all other environments, it is stored encrypted in the -# config/credentials.yml.enc file. +# In the development and test environments your application's `secret_key_base` +# is generated by Rails and stored in a temporary file in +# `tmp/local_secret.txt`. In all other environments, it is stored encrypted in +# the `config/credentials.yml.enc` file. # -# If your application was not updated to Rails 5.2 defaults, the +secret_key_base+ -# will be found in the old config/secrets.yml file. +# If your application was not updated to Rails 5.2 defaults, the +# `secret_key_base` will be found in the old `config/secrets.yml` file. # -# Note that changing your +secret_key_base+ will invalidate all existing session. -# Additionally, you should take care to make sure you are not relying on the -# ability to decode signed cookies generated by your app in external +# Note that changing your `secret_key_base` will invalidate all existing +# session. Additionally, you should take care to make sure you are not relying +# on the ability to decode signed cookies generated by your app in external # applications or JavaScript before changing it. # -# Because CookieStore extends +Rack::Session::Abstract::Persisted+, many of the -# options described there can be used to customize the session cookie that -# is generated. For example: +# Because CookieStore extends `Rack::Session::Abstract::Persisted`, many of the +# options described there can be used to customize the session cookie that is +# generated. For example: # -# Rails.application.config.session_store :cookie_store, expire_after: 14.days +# Rails.application.config.session_store :cookie_store, expire_after: 14.days # # would set the session cookie to expire automatically 14 days after creation. -# Other useful options include :key, :secure, -# :httponly, and :same_site. +# Other useful options include `:key`, `:secure`, `:httponly`, and `:same_site`. # -# source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#49 +# source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#52 class ActionDispatch::Session::CookieStore < ::ActionDispatch::Session::AbstractSecureStore # @return [CookieStore] a new instance of CookieStore # - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#59 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#64 def initialize(app, options = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#63 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#70 def delete_session(req, session_id, options); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#70 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#77 def load_session(req); end private - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#117 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#124 def cookie_jar(request); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#79 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#86 def extract_session_id(req); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#113 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#120 def get_cookie(req); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#98 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#105 def persistent_session_id!(data, sid = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#109 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#116 def set_cookie(request, session_id, cookie); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#86 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#93 def unpacked_cookie_data(req); end - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#104 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#111 def write_session(req, sid, session_data, options); end end -# source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#50 +# source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#62 +ActionDispatch::Session::CookieStore::DEFAULT_SAME_SITE = T.let(T.unsafe(nil), Proc) + +# source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#53 class ActionDispatch::Session::CookieStore::SessionId # @return [SessionId] a new instance of SessionId # - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#53 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#56 def initialize(session_id, cookie_value = T.unsafe(nil)); end # Returns the value of attribute cookie_value. # - # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#51 + # source://actionpack//lib/action_dispatch/middleware/session/cookie_store.rb#54 def cookie_value; end end -# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#69 +# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#71 module ActionDispatch::Session::SessionObject + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#72 + def commit_session(req, res); end + # @return [Boolean] # - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#74 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#81 def loaded_session?(session); end - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#70 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#77 def prepare_session(req); end end -# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#11 +# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#13 class ActionDispatch::Session::SessionRestoreError < ::StandardError # @return [SessionRestoreError] a new instance of SessionRestoreError # - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#12 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#14 def initialize; end end -# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#43 +# source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#45 module ActionDispatch::Session::StaleSessionCheck - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#48 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#50 def extract_session_id(env); end - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#44 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#46 def load_session(env); end - # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#52 + # source://actionpack//lib/action_dispatch/middleware/session/abstract_store.rb#54 def stale_session_check!; end end -# This middleware rescues any exception returned by the application -# and calls an exceptions app that will wrap it in a format for the end user. +# # Action Dispatch ShowExceptions +# +# This middleware rescues any exception returned by the application and calls an +# exceptions app that will wrap it in a format for the end user. # -# The exceptions app should be passed as parameter on initialization -# of ShowExceptions. Every time there is an exception, ShowExceptions will -# store the exception in env["action_dispatch.exception"], rewrite the -# PATH_INFO to the exception status code and call the Rack app. +# The exceptions app should be passed as a parameter on initialization of +# `ShowExceptions`. Every time there is an exception, `ShowExceptions` will +# store the exception in `env["action_dispatch.exception"]`, rewrite the +# `PATH_INFO` to the exception status code, and call the Rack app. # -# If the application returns a "X-Cascade" pass response, this middleware -# will send an empty response as result with the correct status code. -# If any exception happens inside the exceptions app, this middleware -# catches the exceptions and returns a failsafe response. +# In Rails applications, the exceptions app can be configured with +# `config.exceptions_app`, which defaults to ActionDispatch::PublicExceptions. # -# source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#18 +# If the application returns a response with the `X-Cascade` header set to +# `"pass"`, this middleware will send an empty response as a result with the +# correct status code. If any exception happens inside the exceptions app, this +# middleware catches the exceptions and returns a failsafe response. +# +# source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#25 class ActionDispatch::ShowExceptions # @return [ShowExceptions] a new instance of ShowExceptions # - # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#19 + # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#26 def initialize(app, exceptions_app); end - # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#24 + # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#31 def call(env); end private - # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#58 + # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#67 def fallback_to_html_format_if_invalid_mime_type(request); end - # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#67 + # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#83 def pass_response(status); end - # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#36 - def render_exception(request, exception); end + # source://actionpack//lib/action_dispatch/middleware/show_exceptions.rb#48 + def render_exception(request, wrapper); end end -# This middleware serves static files from disk, if available. -# If no file is found, it hands off to the main app. +# # Action Dispatch Static +# +# This middleware serves static files from disk, if available. If no file is +# found, it hands off to the main app. # -# In Rails apps, this middleware is configured to serve assets from -# the +public/+ directory. +# In Rails apps, this middleware is configured to serve assets from the +# `public/` directory. # -# Only GET and HEAD requests are served. POST and other HTTP methods -# are handed off to the main app. +# Only GET and HEAD requests are served. POST and other HTTP methods are handed +# off to the main app. # # Only files in the root directory are served; path traversal is denied. # -# source://actionpack//lib/action_dispatch/middleware/static.rb#16 +# source://actionpack//lib/action_dispatch/middleware/static.rb#20 class ActionDispatch::Static # @return [Static] a new instance of Static # - # source://actionpack//lib/action_dispatch/middleware/static.rb#17 + # source://actionpack//lib/action_dispatch/middleware/static.rb#21 def initialize(app, path, index: T.unsafe(nil), headers: T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/middleware/static.rb#22 + # source://actionpack//lib/action_dispatch/middleware/static.rb#26 def call(env); end end -# = System Testing +# # System Testing # -# System tests let you test applications in the browser. Because system -# tests use a real browser experience, you can test all of your JavaScript -# easily from your test suite. +# System tests let you test applications in the browser. Because system tests +# use a real browser experience, you can test all of your JavaScript easily from +# your test suite. # -# To create a system test in your application, extend your test class -# from ApplicationSystemTestCase. System tests use Capybara as a -# base and allow you to configure the settings through your -# application_system_test_case.rb file that is generated with a new -# application or scaffold. +# To create a system test in your application, extend your test class from +# `ApplicationSystemTestCase`. System tests use Capybara as a base and allow you +# to configure the settings through your `application_system_test_case.rb` file +# that is generated with a new application or scaffold. # # Here is an example system test: # -# require "application_system_test_case" +# require "application_system_test_case" # -# class Users::CreateTest < ApplicationSystemTestCase -# test "adding a new user" do -# visit users_path -# click_on 'New User' +# class Users::CreateTest < ApplicationSystemTestCase +# test "adding a new user" do +# visit users_path +# click_on 'New User' # -# fill_in 'Name', with: 'Arya' -# click_on 'Create User' +# fill_in 'Name', with: 'Arya' +# click_on 'Create User' # -# assert_text 'Arya' +# assert_text 'Arya' +# end # end -# end # -# When generating an application or scaffold, an +application_system_test_case.rb+ -# file will also be generated containing the base class for system testing. -# This is where you can change the driver, add Capybara settings, and other -# configuration for your system tests. +# When generating an application or scaffold, an +# `application_system_test_case.rb` file will also be generated containing the +# base class for system testing. This is where you can change the driver, add +# Capybara settings, and other configuration for your system tests. # -# require "test_helper" +# require "test_helper" # -# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase -# driven_by :selenium, using: :chrome, screen_size: [1400, 1400] -# end +# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase +# driven_by :selenium, using: :chrome, screen_size: [1400, 1400] +# end # -# By default, ActionDispatch::SystemTestCase is driven by the -# Selenium driver, with the Chrome browser, and a browser size of 1400x1400. +# By default, `ActionDispatch::SystemTestCase` is driven by the Selenium driver, +# with the Chrome browser, and a browser size of 1400x1400. # # Changing the driver configuration options is easy. Let's say you want to use -# the Firefox browser instead of Chrome. In your +application_system_test_case.rb+ -# file add the following: -# -# require "test_helper" -# -# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase -# driven_by :selenium, using: :firefox -# end +# the Firefox browser instead of Chrome. In your +# `application_system_test_case.rb` file add the following: # -# +driven_by+ has a required argument for the driver name. The keyword -# arguments are +:using+ for the browser and +:screen_size+ to change the -# size of the browser screen. These two options are not applicable for -# headless drivers and will be silently ignored if passed. +# require "test_helper" # -# Headless browsers such as headless Chrome and headless Firefox are also supported. -# You can use these browsers by setting the +:using+ argument to +:headless_chrome+ or +:headless_firefox+. +# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase +# driven_by :selenium, using: :firefox +# end # -# To use a headless driver, like Cuprite, update your Gemfile to use -# Cuprite instead of Selenium and then declare the driver name in the -# +application_system_test_case.rb+ file. In this case, you would leave out -# the +:using+ option because the driver is headless, but you can still use -# +:screen_size+ to change the size of the browser screen, also you can use -# +:options+ to pass options supported by the driver. Please refer to your +# `driven_by` has a required argument for the driver name. The keyword arguments +# are `:using` for the browser and `:screen_size` to change the size of the +# browser screen. These two options are not applicable for headless drivers and +# will be silently ignored if passed. +# +# Headless browsers such as headless Chrome and headless Firefox are also +# supported. You can use these browsers by setting the `:using` argument to +# `:headless_chrome` or `:headless_firefox`. +# +# To use a headless driver, like Cuprite, update your Gemfile to use Cuprite +# instead of Selenium and then declare the driver name in the +# `application_system_test_case.rb` file. In this case, you would leave out the +# `:using` option because the driver is headless, but you can still use +# `:screen_size` to change the size of the browser screen, also you can use +# `:options` to pass options supported by the driver. Please refer to your # driver documentation to learn about supported options. # -# require "test_helper" -# require "capybara/cuprite" +# require "test_helper" +# require "capybara/cuprite" # -# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase -# driven_by :cuprite, screen_size: [1400, 1400], options: -# { js_errors: true } -# end +# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase +# driven_by :cuprite, screen_size: [1400, 1400], options: +# { js_errors: true } +# end # -# Some drivers require browser capabilities to be passed as a block instead -# of through the +options+ hash. +# Some drivers require browser capabilities to be passed as a block instead of +# through the `options` hash. # # As an example, if you want to add mobile emulation on chrome, you'll have to -# create an instance of selenium's +Chrome::Options+ object and add -# capabilities with a block. +# create an instance of selenium's `Chrome::Options` object and add capabilities +# with a block. # -# The block will be passed an instance of ::Options where you can -# define the capabilities you want. Please refer to your driver documentation -# to learn about supported options. +# The block will be passed an instance of `::Options` where you can +# define the capabilities you want. Please refer to your driver documentation to +# learn about supported options. # -# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase -# driven_by :selenium, using: :chrome, screen_size: [1024, 768] do |driver_option| -# driver_option.add_emulation(device_name: 'iPhone 6') -# driver_option.add_extension('path/to/chrome_extension.crx') +# class ApplicationSystemTestCase < ActionDispatch::SystemTestCase +# driven_by :selenium, using: :chrome, screen_size: [1024, 768] do |driver_option| +# driver_option.add_emulation(device_name: 'iPhone 6') +# driver_option.add_extension('path/to/chrome_extension.crx') +# end # end -# end # -# Because ActionDispatch::SystemTestCase is a shim between Capybara -# and Rails, any driver that is supported by Capybara is supported by system -# tests as long as you include the required gems and files. +# Because `ActionDispatch::SystemTestCase` is a shim between Capybara and Rails, +# any driver that is supported by Capybara is supported by system tests as long +# as you include the required gems and files. # -# source://actionpack//lib/action_dispatch/system_test_case.rb#112 +# source://actionpack//lib/action_dispatch/system_test_case.rb#114 class ActionDispatch::SystemTestCase < ::ActiveSupport::TestCase include ::Capybara::DSL include ::Capybara::Minitest::Assertions include ::ActionDispatch::SystemTesting::TestHelpers::SetupAndTeardown include ::ActionDispatch::SystemTesting::TestHelpers::ScreenshotHelper + include ::ActionText::SystemTestHelper # @return [SystemTestCase] a new instance of SystemTestCase # - # source://actionpack//lib/action_dispatch/system_test_case.rb#120 + # source://actionpack//lib/action_dispatch/system_test_case.rb#122 def initialize(*_arg0); end private - # source://actionpack//lib/action_dispatch/system_test_case.rb#181 - def method_missing(name, *args, &block); end + # source://actionpack//lib/action_dispatch/system_test_case.rb#191 + def method_missing(name, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/system_test_case.rb#189 + # source://actionpack//lib/action_dispatch/system_test_case.rb#199 def respond_to_missing?(name, include_private = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/system_test_case.rb#163 + # source://actionpack//lib/action_dispatch/system_test_case.rb#173 def url_helpers; end class << self # System Test configuration options # - # The default settings are Selenium, using Chrome, with a screen size - # of 1400x1400. + # The default settings are Selenium, using Chrome, with a screen size of + # 1400x1400. # # Examples: # - # driven_by :cuprite + # driven_by :cuprite # - # driven_by :selenium, screen_size: [800, 800] + # driven_by :selenium, screen_size: [800, 800] # - # driven_by :selenium, using: :chrome + # driven_by :selenium, using: :chrome # - # driven_by :selenium, using: :headless_chrome + # driven_by :selenium, using: :headless_chrome # - # driven_by :selenium, using: :firefox + # driven_by :selenium, using: :firefox # - # driven_by :selenium, using: :headless_firefox + # driven_by :selenium, using: :headless_firefox # - # source://actionpack//lib/action_dispatch/system_test_case.rb#156 + # source://actionpack//lib/action_dispatch/system_test_case.rb#158 def driven_by(driver, using: T.unsafe(nil), screen_size: T.unsafe(nil), options: T.unsafe(nil), &capabilities); end - # source://actionpack//lib/action_dispatch/system_test_case.rb#136 + # source://actionpack//lib/action_dispatch/system_test_case.rb#138 def driver; end - # source://actionpack//lib/action_dispatch/system_test_case.rb#136 + # source://actionpack//lib/action_dispatch/system_test_case.rb#138 def driver=(value); end - # source://actionpack//lib/action_dispatch/system_test_case.rb#136 + # source://actionpack//lib/action_dispatch/system_test_case.rb#138 def driver?; end - # source://actionpack//lib/action_dispatch/system_test_case.rb#126 + # Configuration for the System Test application server. + # + # By default this is localhost. This method allows the host and port to be specified manually. + # + # source://actionpack//lib/action_dispatch/system_test_case.rb#167 + def served_by(host:, port:); end + + # source://actionpack//lib/action_dispatch/system_test_case.rb#128 def start_application; end end end -# source://actionpack//lib/action_dispatch/system_test_case.rb#118 +# source://actionpack//lib/action_dispatch/system_test_case.rb#120 ActionDispatch::SystemTestCase::DEFAULT_HOST = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/system_testing/driver.rb#4 +# source://actionpack//lib/action_dispatch/system_testing/driver.rb#6 module ActionDispatch::SystemTesting; end -# source://actionpack//lib/action_dispatch/system_testing/browser.rb#5 +# source://actionpack//lib/action_dispatch/system_testing/browser.rb#7 class ActionDispatch::SystemTesting::Browser # @return [Browser] a new instance of Browser # - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#8 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#10 def initialize(name); end # @yield [options] # - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#24 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#36 def configure; end # Returns the value of attribute name. # - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#6 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#8 def name; end - # Returns the value of attribute options. - # - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#6 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#26 def options; end - # driver_path can be configured as a proc. The webdrivers gem uses this - # proc to update web drivers. Running this proc early allows us to only - # update the webdriver once and avoid race conditions when using - # parallel tests. + # driver_path is lazily initialized by default. Eagerly set it to avoid race + # conditions when using parallel tests. # - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#33 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#42 def preload; end - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#13 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#15 def type; end private - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#43 - def initialize_options; end + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#74 + def resolve_driver_path(namespace); end - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#53 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#52 def set_default_options; end - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#62 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#61 def set_headless_chrome_browser_options; end - # source://actionpack//lib/action_dispatch/system_testing/browser.rb#69 + # source://actionpack//lib/action_dispatch/system_testing/browser.rb#68 def set_headless_firefox_browser_options; end end -# source://actionpack//lib/action_dispatch/system_testing/driver.rb#5 +# source://actionpack//lib/action_dispatch/system_testing/driver.rb#7 class ActionDispatch::SystemTesting::Driver # @return [Driver] a new instance of Driver # - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#8 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#10 def initialize(driver_type, **options, &capabilities); end # Returns the value of attribute name. # - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#6 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#8 def name; end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#33 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#27 def use; end private - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#58 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#51 def browser_options; end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#44 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#38 def register; end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#78 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#61 def register_cuprite(app); end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#68 - def register_poltergeist(app); end + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#69 + def register_playwright(app); end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#82 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#65 def register_rack_test(app); end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#62 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#55 def register_selenium(app); end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#72 - def register_webkit(app); end - # @return [Boolean] # - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#40 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#34 def registerable?; end - # source://actionpack//lib/action_dispatch/system_testing/driver.rb#86 + # source://actionpack//lib/action_dispatch/system_testing/driver.rb#80 def setup; end end -# source://actionpack//lib/action_dispatch/system_testing/server.rb#5 +# source://actionpack//lib/action_dispatch/system_testing/server.rb#7 class ActionDispatch::SystemTesting::Server - # source://actionpack//lib/action_dispatch/system_testing/server.rb#12 + # source://actionpack//lib/action_dispatch/system_testing/server.rb#14 def run; end private - # source://actionpack//lib/action_dispatch/system_testing/server.rb#26 + # source://actionpack//lib/action_dispatch/system_testing/server.rb#28 def set_port; end - # source://actionpack//lib/action_dispatch/system_testing/server.rb#22 + # source://actionpack//lib/action_dispatch/system_testing/server.rb#24 def set_server; end - # source://actionpack//lib/action_dispatch/system_testing/server.rb#17 + # source://actionpack//lib/action_dispatch/system_testing/server.rb#19 def setup; end class << self # Returns the value of attribute silence_puma. # - # source://actionpack//lib/action_dispatch/system_testing/server.rb#7 + # source://actionpack//lib/action_dispatch/system_testing/server.rb#9 def silence_puma; end # Sets the attribute silence_puma # # @param value the value to set the attribute silence_puma to. # - # source://actionpack//lib/action_dispatch/system_testing/server.rb#7 + # source://actionpack//lib/action_dispatch/system_testing/server.rb#9 def silence_puma=(_arg0); end end end -# source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#5 +# source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#7 module ActionDispatch::SystemTesting::TestHelpers; end # Screenshot helper for system testing. # -# source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#7 +# source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#9 module ActionDispatch::SystemTesting::TestHelpers::ScreenshotHelper - # Takes a screenshot of the current page in the browser if the test - # failed. + # Takes a screenshot of the current page in the browser if the test failed. # - # +take_failed_screenshot+ is called during system test teardown. + # `take_failed_screenshot` is called during system test teardown. # - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#44 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#53 def take_failed_screenshot; end # Takes a screenshot of the current page in the browser. # - # +take_screenshot+ can be used at any point in your system tests to take - # a screenshot of the current state. This can be useful for debugging or - # automating visual testing. You can take multiple screenshots per test - # to investigate changes at different points during your test. These will be - # named with a sequential prefix (or 'failed' for failing tests) + # `take_screenshot` can be used at any point in your system tests to take a + # screenshot of the current state. This can be useful for debugging or + # automating visual testing. You can take multiple screenshots per test to + # investigate changes at different points during your test. These will be named + # with a sequential prefix (or 'failed' for failing tests) + # + # The default screenshots directory is `tmp/screenshots` but you can set a + # different one with `Capybara.save_path` # - # The screenshot will be displayed in your console, if supported. + # You can use the `html` argument or set the + # `RAILS_SYSTEM_TESTING_SCREENSHOT_HTML` environment variable to save the HTML + # from the page that is being screenshotted so you can investigate the elements + # on the page at the time of the screenshot # - # The default screenshots directory is +tmp/screenshots+ but you can set a different - # one with +Capybara.save_path+ + # You can use the `screenshot` argument or set the + # `RAILS_SYSTEM_TESTING_SCREENSHOT` environment variable to control the output. + # Possible values are: + # `simple` (default) + # : Only displays the screenshot path. This is the default value. # - # You can set the +RAILS_SYSTEM_TESTING_SCREENSHOT_HTML+ environment variable to - # save the HTML from the page that is being screenshotted so you can investigate the - # elements on the page at the time of the screenshot + # `inline` + # : Display the screenshot in the terminal using the iTerm image protocol + # (https://iterm2.com/documentation-images.html). # - # You can set the +RAILS_SYSTEM_TESTING_SCREENSHOT+ environment variable to - # control the output. Possible values are: - # * [+simple+ (default)] Only displays the screenshot path. - # This is the default value. - # * [+inline+] Display the screenshot in the terminal using the - # iTerm image protocol (https://iterm2.com/documentation-images.html). - # * [+artifact+] Display the screenshot in the terminal, using the terminal - # artifact format (https://buildkite.github.io/terminal-to-html/inline-images/). + # `artifact` + # : Display the screenshot in the terminal, using the terminal artifact + # format (https://buildkite.github.io/terminal-to-html/inline-images/). # - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#33 - def take_screenshot; end + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#41 + def take_screenshot(html: T.unsafe(nil), screenshot: T.unsafe(nil)); end private # Returns the value of attribute _screenshot_counter. # - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#49 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#61 def _screenshot_counter; end # Sets the attribute _screenshot_counter # # @param value the value to set the attribute _screenshot_counter to. # - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#49 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#61 def _screenshot_counter=(_arg0); end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#90 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#106 def absolute_html_path; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#86 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#98 def absolute_image_path; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#78 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#90 def absolute_path; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#112 - def display_image; end + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#134 + def display_image(html:, screenshot_output:); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#132 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#154 def failed?; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#74 + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#63 + def html_from_env?; end + + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#86 def html_path; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#64 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#76 def image_name; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#70 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#82 def image_path; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#55 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#67 def increment_unique; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#128 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#150 def inline_base64(path); end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#102 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#120 def output_type; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#94 - def save_html; end + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#102 + def relative_image_path; end - # @return [Boolean] - # - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#51 - def save_html?; end + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#111 + def save_html; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#98 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#115 def save_image; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#82 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#94 def screenshots_dir; end + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#130 + def show(img); end + # @return [Boolean] # - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#136 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#158 def supports_screenshot?; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#60 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb#72 def unique; end end -# source://actionpack//lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb#6 +# source://actionpack//lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb#8 module ActionDispatch::SystemTesting::TestHelpers::SetupAndTeardown - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb#13 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb#15 def after_teardown; end - # source://actionpack//lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb#7 + # source://actionpack//lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb#9 def before_teardown; end end -# source://actionpack//lib/action_dispatch/testing/test_process.rb#7 +# source://actionpack//lib/action_dispatch/testing/test_helpers/page_dump_helper.rb#4 +module ActionDispatch::TestHelpers; end + +# source://actionpack//lib/action_dispatch/testing/test_helpers/page_dump_helper.rb#5 +module ActionDispatch::TestHelpers::PageDumpHelper + # Saves the content of response body to a file and tries to open it in your browser. + # Launchy must be present in your Gemfile for the page to open automatically. + # + # source://actionpack//lib/action_dispatch/testing/test_helpers/page_dump_helper.rb#10 + def save_and_open_page(path = T.unsafe(nil)); end + + private + + # source://actionpack//lib/action_dispatch/testing/test_helpers/page_dump_helper.rb#30 + def html_dump_default_path; end + + # source://actionpack//lib/action_dispatch/testing/test_helpers/page_dump_helper.rb#23 + def open_file(path); end + + # @raise [InvalidResponse] + # + # source://actionpack//lib/action_dispatch/testing/test_helpers/page_dump_helper.rb#15 + def save_page(path = T.unsafe(nil)); end +end + +# source://actionpack//lib/action_dispatch/testing/test_helpers/page_dump_helper.rb#6 +class ActionDispatch::TestHelpers::PageDumpHelper::InvalidResponse < ::StandardError; end + +# source://actionpack//lib/action_dispatch/testing/test_process.rb#9 module ActionDispatch::TestProcess include ::ActionDispatch::TestProcess::FixtureFile # @raise [NoMethodError] # - # source://actionpack//lib/action_dispatch/testing/test_process.rb#30 + # source://actionpack//lib/action_dispatch/testing/test_process.rb#35 def assigns(key = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/testing/test_process.rb#44 + # source://actionpack//lib/action_dispatch/testing/test_process.rb#49 def cookies; end - # source://actionpack//lib/action_dispatch/testing/test_process.rb#40 + # source://actionpack//lib/action_dispatch/testing/test_process.rb#45 def flash; end - # source://actionpack//lib/action_dispatch/testing/test_process.rb#48 + # source://actionpack//lib/action_dispatch/testing/test_process.rb#53 def redirect_to_url; end - # source://actionpack//lib/action_dispatch/testing/test_process.rb#36 + # source://actionpack//lib/action_dispatch/testing/test_process.rb#41 def session; end end -# source://actionpack//lib/action_dispatch/testing/test_process.rb#8 +# source://actionpack//lib/action_dispatch/testing/test_process.rb#10 module ActionDispatch::TestProcess::FixtureFile - # Shortcut for Rack::Test::UploadedFile.new(File.join(ActionDispatch::IntegrationTest.file_fixture_path, path), type): + # Shortcut for + # `Rack::Test::UploadedFile.new(File.join(ActionDispatch::IntegrationTest.file_f + # ixture_path, path), type)`: + # + # post :change_avatar, params: { avatar: file_fixture_upload('david.png', 'image/png') } + # + # Default fixture files location is `test/fixtures/files`. + # + # To upload binary files on Windows, pass `:binary` as the last parameter. This + # will not affect other platforms: + # + # post :change_avatar, params: { avatar: file_fixture_upload('david.png', 'image/png', :binary) } + # + # source://actionpack//lib/action_dispatch/testing/test_process.rb#23 + def file_fixture_upload(path, mime_type = T.unsafe(nil), binary = T.unsafe(nil)); end + + # Shortcut for + # `Rack::Test::UploadedFile.new(File.join(ActionDispatch::IntegrationTest.file_f + # ixture_path, path), type)`: # - # post :change_avatar, params: { avatar: fixture_file_upload('david.png', 'image/png') } + # post :change_avatar, params: { avatar: file_fixture_upload('david.png', 'image/png') } # - # Default fixture files location is test/fixtures/files. + # Default fixture files location is `test/fixtures/files`. # - # To upload binary files on Windows, pass :binary as the last parameter. - # This will not affect other platforms: + # To upload binary files on Windows, pass `:binary` as the last parameter. This + # will not affect other platforms: # - # post :change_avatar, params: { avatar: fixture_file_upload('david.png', 'image/png', :binary) } + # post :change_avatar, params: { avatar: file_fixture_upload('david.png', 'image/png', :binary) } # - # source://actionpack//lib/action_dispatch/testing/test_process.rb#19 + # source://actionpack//lib/action_dispatch/testing/test_process.rb#23 def fixture_file_upload(path, mime_type = T.unsafe(nil), binary = T.unsafe(nil)); end end -# source://actionpack//lib/action_dispatch/testing/test_request.rb#7 +# source://actionpack//lib/action_dispatch/testing/test_request.rb#9 class ActionDispatch::TestRequest < ::ActionDispatch::Request - # source://actionpack//lib/action_dispatch/testing/test_request.rb#66 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#68 def accept=(mime_types); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#46 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#48 def action=(action_name); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#30 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#32 def host=(host); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#50 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#52 def if_modified_since=(last_modified); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#54 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#56 def if_none_match=(etag); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#42 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#44 def path=(path); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#34 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#36 def port=(number); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#58 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#60 def remote_addr=(addr); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#26 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#28 def request_method=(method); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#38 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#40 def request_uri=(uri); end - # source://actionpack//lib/action_dispatch/testing/test_request.rb#62 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#64 def user_agent=(user_agent); end class << self - # Create a new test request with default +env+ values. + # Create a new test request with default `env` values. # - # source://actionpack//lib/action_dispatch/testing/test_request.rb#15 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#17 def create(env = T.unsafe(nil)); end private - # source://actionpack//lib/action_dispatch/testing/test_request.rb#21 + # source://actionpack//lib/action_dispatch/testing/test_request.rb#23 def default_env; end end end -# source://actionpack//lib/action_dispatch/testing/test_request.rb#8 +# source://actionpack//lib/action_dispatch/testing/test_request.rb#10 ActionDispatch::TestRequest::DEFAULT_ENV = T.let(T.unsafe(nil), Hash) -# Integration test methods such as Integration::RequestHelpers#get -# and Integration::RequestHelpers#post return objects of class -# TestResponse, which represent the HTTP response results of the requested -# controller actions. +# Integration test methods such as Integration::RequestHelpers#get and +# Integration::RequestHelpers#post return objects of class TestResponse, which +# represent the HTTP response results of the requested controller actions. # # See Response for more information on controller response objects. # -# source://actionpack//lib/action_dispatch/testing/test_response.rb#12 +# source://actionpack//lib/action_dispatch/testing/test_response.rb#13 class ActionDispatch::TestResponse < ::ActionDispatch::Response # Returns a parsed body depending on the response MIME type. When a parser # corresponding to the MIME type is not found, it returns the raw body. # - # ==== Examples - # get "/posts" - # response.content_type # => "text/html; charset=utf-8" - # response.parsed_body.class # => String - # response.parsed_body # => "\n\n..." + # #### Examples + # get "/posts" + # response.content_type # => "text/html; charset=utf-8" + # response.parsed_body.class # => Nokogiri::HTML5::Document + # response.parsed_body.to_html # => "\n\n..." + # + # assert_pattern { response.parsed_body.at("main") => { content: "Hello, world" } } + # + # response.parsed_body.at("main") => {name:, content:} + # assert_equal "main", name + # assert_equal "Some main content", content # - # get "/posts.json" - # response.content_type # => "application/json; charset=utf-8" - # response.parsed_body.class # => Array - # response.parsed_body # => [{"id"=>42, "title"=>"Title"},... + # get "/posts.json" + # response.content_type # => "application/json; charset=utf-8" + # response.parsed_body.class # => Array + # response.parsed_body # => [{"id"=>42, "title"=>"Title"},... # - # get "/posts/42.json" - # response.content_type # => "application/json; charset=utf-8" - # response.parsed_body.class # => Hash - # response.parsed_body # => {"id"=>42, "title"=>"Title"} + # assert_pattern { response.parsed_body => [{ id: 42 }] } # - # source://actionpack//lib/action_dispatch/testing/test_response.rb#35 + # get "/posts/42.json" + # response.content_type # => "application/json; charset=utf-8" + # response.parsed_body.class # => ActiveSupport::HashWithIndifferentAccess + # response.parsed_body # => {"id"=>42, "title"=>"Title"} + # + # assert_pattern { response.parsed_body => [{ title: /title/i }] } + # + # response.parsed_body => {id:, title:} + # assert_equal 42, id + # assert_equal "Title", title + # + # source://actionpack//lib/action_dispatch/testing/test_response.rb#50 def parsed_body; end - # source://actionpack//lib/action_dispatch/testing/test_response.rb#39 + # source://actionpack//lib/action_dispatch/testing/test_response.rb#54 def response_parser; end class << self - # source://actionpack//lib/action_dispatch/testing/test_response.rb#13 + # source://actionpack//lib/action_dispatch/testing/test_response.rb#14 def from_response(response); end end end -# source://actionpack//lib/action_pack/gem_version.rb#3 +# :markup: markdown +# +# source://actionpack//lib/action_pack/gem_version.rb#5 module ActionPack class << self - # Returns the currently loaded version of Action Pack as a Gem::Version. + # Returns the currently loaded version of Action Pack as a `Gem::Version`. # - # source://actionpack//lib/action_pack/gem_version.rb#5 + # source://actionpack//lib/action_pack/gem_version.rb#7 def gem_version; end - # Returns the currently loaded version of Action Pack as a Gem::Version. + # Returns the currently loaded version of Action Pack as a `Gem::Version`. # - # source://actionpack//lib/action_pack/version.rb#7 + # source://actionpack//lib/action_pack/version.rb#9 def version; end end end -# source://actionpack//lib/action_pack/gem_version.rb#9 +# source://actionpack//lib/action_pack/gem_version.rb#11 module ActionPack::VERSION; end -# source://actionpack//lib/action_pack/gem_version.rb#10 +# source://actionpack//lib/action_pack/gem_version.rb#12 ActionPack::VERSION::MAJOR = T.let(T.unsafe(nil), Integer) -# source://actionpack//lib/action_pack/gem_version.rb#11 +# source://actionpack//lib/action_pack/gem_version.rb#13 ActionPack::VERSION::MINOR = T.let(T.unsafe(nil), Integer) -# source://actionpack//lib/action_pack/gem_version.rb#13 +# source://actionpack//lib/action_pack/gem_version.rb#15 ActionPack::VERSION::PRE = T.let(T.unsafe(nil), T.untyped) -# source://actionpack//lib/action_pack/gem_version.rb#15 +# source://actionpack//lib/action_pack/gem_version.rb#17 ActionPack::VERSION::STRING = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_pack/gem_version.rb#12 +# source://actionpack//lib/action_pack/gem_version.rb#14 ActionPack::VERSION::TINY = T.let(T.unsafe(nil), Integer) -# source://actionpack//lib/action_dispatch/http/mime_type.rb#5 +module ActionView::RoutingUrlFor + include ::ActionDispatch::Routing::PolymorphicRoutes + include ::ActionDispatch::Routing::UrlFor +end + +# source://actionpack//lib/action_dispatch/http/mime_type.rb#7 module Mime class << self - # source://actionpack//lib/action_dispatch/http/mime_type.rb#40 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#51 def [](type); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#45 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#64 def fetch(type, &block); end + + # source://actionpack//lib/action_dispatch/http/mime_type.rb#56 + def symbols; end + + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/http/mime_type.rb#60 + def valid_symbols?(symbols); end end end -# ALL isn't a real MIME type, so we don't register it for lookup with the -# other concrete types. It's a wildcard match that we use for +respond_to+ -# negotiation internals. +# ALL isn't a real MIME type, so we don't register it for lookup with the other +# concrete types. It's a wildcard match that we use for `respond_to` negotiation +# internals. # -# source://actionpack//lib/action_dispatch/http/mime_type.rb#333 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#363 Mime::ALL = T.let(T.unsafe(nil), Mime::AllType) -# source://actionpack//lib/action_dispatch/http/mime_type.rb#319 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#349 class Mime::AllType < ::Mime::Type include ::Singleton extend ::Singleton::SingletonClassMethods # @return [AllType] a new instance of AllType # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#322 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#352 def initialize; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#326 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#356 def all?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#327 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#357 def html?; end class << self @@ -19600,60 +20853,67 @@ class Mime::AllType < ::Mime::Type end end -# source://actionpack//lib/action_dispatch/http/mime_type.rb#36 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#47 Mime::EXTENSION_LOOKUP = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/mime_type.rb#37 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#48 Mime::LOOKUP = T.let(T.unsafe(nil), Hash) -# source://actionpack//lib/action_dispatch/http/mime_type.rb#6 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#8 class Mime::Mimes include ::Enumerable # @return [Mimes] a new instance of Mimes # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#11 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#13 def initialize; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#20 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#23 def <<(type); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#25 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#30 def delete_if; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#16 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#19 def each(&block); end # Returns the value of attribute symbols. # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#7 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#9 def symbols; end + + # :nodoc + # + # @return [Boolean] + # + # source://actionpack//lib/action_dispatch/http/mime_type.rb#41 + def valid_symbols?(symbols); end end -# source://actionpack//lib/action_dispatch/http/mime_type.rb#335 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#365 class Mime::NullType include ::Singleton extend ::Singleton::SingletonClassMethods # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#338 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#368 def nil?; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#346 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#376 def ref; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#342 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#372 def to_s; end private - # source://actionpack//lib/action_dispatch/http/mime_type.rb#353 - def method_missing(method, *args); end + # source://actionpack//lib/action_dispatch/http/mime_type.rb#383 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#349 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#379 def respond_to_missing?(method, _); end class << self @@ -19664,404 +20924,223 @@ class Mime::NullType end end -# source://actionpack//lib/action_dispatch/http/mime_type.rb#35 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#46 Mime::SET = T.let(T.unsafe(nil), Mime::Mimes) -# Encapsulates the notion of a MIME type. Can be used at render time, for example, with: +# Encapsulates the notion of a MIME type. Can be used at render time, for +# example, with: # -# class PostsController < ActionController::Base -# def show -# @post = Post.find(params[:id]) +# class PostsController < ActionController::Base +# def show +# @post = Post.find(params[:id]) # -# respond_to do |format| -# format.html -# format.ics { render body: @post.to_ics, mime_type: Mime::Type.lookup("text/calendar") } -# format.xml { render xml: @post } +# respond_to do |format| +# format.html +# format.ics { render body: @post.to_ics, mime_type: Mime::Type.lookup("text/calendar") } +# format.xml { render xml: @post } +# end # end # end -# end # -# source://actionpack//lib/action_dispatch/http/mime_type.rb#64 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#84 class Mime::Type # @return [Type] a new instance of Type # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#234 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#264 def initialize(string, symbol = T.unsafe(nil), synonyms = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#267 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#297 def ==(mime_type); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#259 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#289 def ===(list); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#281 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#311 def =~(mime_type); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#297 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#327 def all?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#274 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#304 def eql?(other); end # Returns the value of attribute hash. # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#225 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#255 def hash; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#293 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#323 def html?; end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#287 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#317 def match?(mime_type); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#255 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#285 def ref; end # Returns the value of attribute symbol. # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#65 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#85 def symbol; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#243 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#273 def to_s; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#247 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#277 def to_str; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#251 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#281 def to_sym; end protected # Returns the value of attribute string. # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#300 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#330 def string; end # Returns the value of attribute synonyms. # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#300 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#330 def synonyms; end private - # source://actionpack//lib/action_dispatch/http/mime_type.rb#306 - def method_missing(method, *args); end + # source://actionpack//lib/action_dispatch/http/mime_type.rb#336 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#314 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#344 def respond_to_missing?(method, include_private = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#304 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#334 def to_a; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#303 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#333 def to_ary; end class << self - # source://actionpack//lib/action_dispatch/http/mime_type.rb#144 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#167 def lookup(string); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#148 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#175 def lookup_by_extension(extension); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#172 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#200 def parse(accept_header); end - # For an input of 'text', returns [Mime[:json], Mime[:xml], Mime[:ics], - # Mime[:html], Mime[:css], Mime[:csv], Mime[:js], Mime[:yaml], Mime[:text]. + # For an input of `'text'`, returns `[Mime[:json], Mime[:xml], Mime[:ics], + # Mime[:html], Mime[:css], Mime[:csv], Mime[:js], Mime[:yaml], Mime[:text]]`. # - # For an input of 'application', returns [Mime[:html], Mime[:js], - # Mime[:xml], Mime[:yaml], Mime[:atom], Mime[:json], Mime[:rss], Mime[:url_encoded_form]. + # For an input of `'application'`, returns `[Mime[:html], Mime[:js], Mime[:xml], + # Mime[:yaml], Mime[:atom], Mime[:json], Mime[:rss], Mime[:url_encoded_form]]`. # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#206 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#236 def parse_data_with_trailing_star(type); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#197 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#227 def parse_trailing_star(accept_header); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#158 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#186 def register(string, symbol, mime_type_synonyms = T.unsafe(nil), extension_synonyms = T.unsafe(nil), skip_lookup = T.unsafe(nil)); end - # Registers an alias that's not used on MIME type lookup, but can be referenced directly. Especially useful for - # rendering different HTML versions depending on the user agent, like an iPhone. + # Registers an alias that's not used on MIME type lookup, but can be referenced + # directly. Especially useful for rendering different HTML versions depending on + # the user agent, like an iPhone. # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#154 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#182 def register_alias(string, symbol, extension_synonyms = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#140 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#163 def register_callback(&block); end # This method is opposite of register method. # # To unregister a MIME type: # - # Mime::Type.unregister(:mobile) + # Mime::Type.unregister(:mobile) # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#215 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#245 def unregister(symbol); end end end # A simple helper class used in parsing the accept header. # -# source://actionpack//lib/action_dispatch/http/mime_type.rb#70 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#90 class Mime::Type::AcceptItem # @return [AcceptItem] a new instance of AcceptItem # - # source://actionpack//lib/action_dispatch/http/mime_type.rb#74 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#94 def initialize(index, name, q = T.unsafe(nil)); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#81 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#101 def <=>(item); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#71 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#91 def index; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#71 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#91 def index=(_arg0); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#71 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#91 def name; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#71 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#91 def name=(_arg0); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#71 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#91 def q; end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#71 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#91 def q=(_arg0); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#71 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#91 def to_s; end end -# source://actionpack//lib/action_dispatch/http/mime_type.rb#88 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#108 class Mime::Type::AcceptList class << self - # source://actionpack//lib/action_dispatch/http/mime_type.rb#131 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#151 def find_item_by_name(array, name); end - # source://actionpack//lib/action_dispatch/http/mime_type.rb#89 + # source://actionpack//lib/action_dispatch/http/mime_type.rb#109 def sort!(list); end end end -# source://actionpack//lib/action_dispatch/http/mime_type.rb#232 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#262 class Mime::Type::InvalidMimeType < ::StandardError; end -# source://actionpack//lib/action_dispatch/http/mime_type.rb#227 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#257 Mime::Type::MIME_NAME = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/mime_type.rb#229 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#259 Mime::Type::MIME_PARAMETER = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/mime_type.rb#228 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#258 Mime::Type::MIME_PARAMETER_VALUE = T.let(T.unsafe(nil), String) -# source://actionpack//lib/action_dispatch/http/mime_type.rb#230 +# source://actionpack//lib/action_dispatch/http/mime_type.rb#260 Mime::Type::MIME_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://actionpack//lib/action_dispatch.rb#33 +# source://actionpack//lib/action_dispatch.rb#35 module Rack class << self - # source://rack/2.2.7/lib/rack/version.rb#26 + # source://rack/2.2.9/lib/rack/version.rb#26 def release; end - # source://rack/2.2.7/lib/rack/version.rb#19 + # source://rack/2.2.9/lib/rack/version.rb#19 def version; end end end - -# source://rack/2.2.7/lib/rack.rb#29 -Rack::CACHE_CONTROL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#31 -Rack::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#32 -Rack::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#43 -Rack::DELETE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#36 -Rack::ETAG = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#30 -Rack::EXPIRES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/file.rb#6 -Rack::File = Rack::Files - -# source://rack/2.2.7/lib/rack.rb#39 -Rack::GET = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#44 -Rack::HEAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#20 -Rack::HTTPS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#35 -Rack::HTTP_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#17 -Rack::HTTP_HOST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#18 -Rack::HTTP_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#19 -Rack::HTTP_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#46 -Rack::LINK = T.let(T.unsafe(nil), String) - -# source://rack-test/2.1.0/lib/rack/test.rb#381 -Rack::MockSession = Rack::Test::Session - -# source://rack/2.2.7/lib/rack.rb#45 -Rack::OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#42 -Rack::PATCH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#21 -Rack::PATH_INFO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#40 -Rack::POST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#41 -Rack::PUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#25 -Rack::QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#53 -Rack::RACK_ERRORS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#63 -Rack::RACK_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#65 -Rack::RACK_HIJACK_IO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#55 -Rack::RACK_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#64 -Rack::RACK_IS_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#54 -Rack::RACK_LOGGER = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#76 -Rack::RACK_METHODOVERRIDE_ORIGINAL_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#67 -Rack::RACK_MULTIPART_BUFFER_SIZE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#68 -Rack::RACK_MULTIPART_TEMPFILE_FACTORY = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#60 -Rack::RACK_MULTIPROCESS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#59 -Rack::RACK_MULTITHREAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#66 -Rack::RACK_RECURSIVE_INCLUDE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#72 -Rack::RACK_REQUEST_COOKIE_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#73 -Rack::RACK_REQUEST_COOKIE_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#70 -Rack::RACK_REQUEST_FORM_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#69 -Rack::RACK_REQUEST_FORM_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#71 -Rack::RACK_REQUEST_FORM_VARS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#74 -Rack::RACK_REQUEST_QUERY_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#75 -Rack::RACK_REQUEST_QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#61 -Rack::RACK_RUNONCE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#56 -Rack::RACK_SESSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#57 -Rack::RACK_SESSION_OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#77 -Rack::RACK_SESSION_UNPACKED_COOKIE_DATA = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#58 -Rack::RACK_SHOWSTATUS_DETAIL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#52 -Rack::RACK_TEMPFILES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#62 -Rack::RACK_URL_SCHEME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#51 -Rack::RACK_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#23 -Rack::RELEASE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#22 -Rack::REQUEST_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#23 -Rack::REQUEST_PATH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#24 -Rack::SCRIPT_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#27 -Rack::SERVER_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#28 -Rack::SERVER_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#26 -Rack::SERVER_PROTOCOL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#33 -Rack::SET_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#48 -Rack::TRACE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#34 -Rack::TRANSFER_ENCODING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#47 -Rack::UNLINK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#16 -Rack::VERSION = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/actiontext@7.0.5.rbi b/sorbet/rbi/gems/actiontext@7.0.5.rbi deleted file mode 100644 index 25467345c..000000000 --- a/sorbet/rbi/gems/actiontext@7.0.5.rbi +++ /dev/null @@ -1,1503 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `actiontext` gem. -# Please instead update this file by running `bin/tapioca gem actiontext`. - -# source://actiontext//lib/action_text.rb#8 -module ActionText - extend ::ActiveSupport::Autoload - - class << self - # source://railties/7.0.5/lib/rails/engine.rb#405 - def railtie_helpers_paths; end - - # source://railties/7.0.5/lib/rails/engine.rb#394 - def railtie_namespace; end - - # source://railties/7.0.5/lib/rails/engine.rb#409 - def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#397 - def table_name_prefix; end - - # source://railties/7.0.5/lib/rails/engine.rb#401 - def use_relative_model_naming?; end - end -end - -# source://actiontext//lib/action_text/attachable.rb#4 -module ActionText::Attachable - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionText::Attachable::ClassMethods - - # source://actiontext//lib/action_text/attachable.rb#66 - def as_json(*_arg0); end - - # source://actiontext//lib/action_text/attachable.rb#46 - def attachable_content_type; end - - # source://actiontext//lib/action_text/attachable.rb#50 - def attachable_filename; end - - # source://actiontext//lib/action_text/attachable.rb#54 - def attachable_filesize; end - - # source://actiontext//lib/action_text/attachable.rb#58 - def attachable_metadata; end - - # source://actiontext//lib/action_text/attachable.rb#42 - def attachable_sgid; end - - # @return [Boolean] - # - # source://actiontext//lib/action_text/attachable.rb#62 - def previewable_attachable?; end - - # source://actiontext//lib/action_text/attachable.rb#74 - def to_attachable_partial_path; end - - # source://actiontext//lib/action_text/attachable.rb#78 - def to_rich_text_attributes(attributes = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attachable.rb#70 - def to_trix_content_attachment_partial_path; end - - class << self - # source://actiontext//lib/action_text/attachable.rb#22 - def from_attachable_sgid(sgid, options = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attachable.rb#10 - def from_node(node); end - - private - - # source://actiontext//lib/action_text/attachable.rb#29 - def attachable_from_sgid(sgid); end - end -end - -# source://actiontext//lib/action_text/attachable.rb#0 -module ActionText::Attachable::ClassMethods - # source://actiontext//lib/action_text/attachable.rb#37 - def from_attachable_sgid(sgid); end -end - -# source://actiontext//lib/action_text/attachable.rb#7 -ActionText::Attachable::LOCATOR_NAME = T.let(T.unsafe(nil), String) - -# source://actiontext//lib/action_text.rb#25 -module ActionText::Attachables - extend ::ActiveSupport::Autoload -end - -# source://actiontext//lib/action_text/attachables/content_attachment.rb#5 -class ActionText::Attachables::ContentAttachment - include ::ActiveModel::Validations - include ::ActiveSupport::Callbacks - include ::ActiveModel::Validations::HelperMethods - include ::ActiveModel::Conversion - include ::ActiveModel::ForbiddenAttributesProtection - include ::ActiveModel::AttributeAssignment - include ::ActiveModel::API - include ::ActiveModel::Model - extend ::ActiveModel::Validations::ClassMethods - extend ::ActiveModel::Naming - extend ::ActiveModel::Callbacks - extend ::ActiveSupport::Callbacks::ClassMethods - extend ::ActiveSupport::DescendantsTracker - extend ::ActiveModel::Translation - extend ::ActiveModel::Validations::HelperMethods - extend ::ActiveModel::Conversion::ClassMethods - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 - def _run_validate_callbacks(&block); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 - def _validate_callbacks; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators?; end - - # source://actiontext//lib/action_text/attachables/content_attachment.rb#20 - def attachable_plain_text_representation(caption); end - - # source://activemodel/7.0.5/lib/active_model/naming.rb#244 - def model_name(*_arg0, **_arg1, &_arg2); end - - # Returns the value of attribute name. - # - # source://actiontext//lib/action_text/attachables/content_attachment.rb#17 - def name; end - - # Sets the attribute name - # - # @param value the value to set the attribute name to. - # - # source://actiontext//lib/action_text/attachables/content_attachment.rb#17 - def name=(_arg0); end - - # source://actiontext//lib/action_text/attachables/content_attachment.rb#29 - def to_partial_path; end - - # source://actiontext//lib/action_text/attachables/content_attachment.rb#33 - def to_trix_content_attachment_partial_path; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#48 - def validation_context; end - - private - - # source://activemodel/7.0.5/lib/active_model/validations.rb#48 - def validation_context=(_arg0); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks=(value); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 - def _validate_callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 - def _validate_callbacks=(value); end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators=(value); end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators?; end - - # source://actiontext//lib/action_text/attachables/content_attachment.rb#8 - def from_node(node); end - end -end - -# source://actiontext//lib/action_text/attachables/missing_attachable.rb#5 -module ActionText::Attachables::MissingAttachable - extend ::ActiveModel::Naming - - # source://activemodel/7.0.5/lib/active_model/naming.rb#244 - def model_name(*_arg0, **_arg1, &_arg2); end - - class << self - # source://actiontext//lib/action_text/attachables/missing_attachable.rb#8 - def to_partial_path; end - end -end - -# source://actiontext//lib/action_text/attachables/remote_image.rb#5 -class ActionText::Attachables::RemoteImage - extend ::ActiveModel::Naming - - # @return [RemoteImage] a new instance of RemoteImage - # - # source://actiontext//lib/action_text/attachables/remote_image.rb#30 - def initialize(attributes = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attachables/remote_image.rb#37 - def attachable_plain_text_representation(caption); end - - # Returns the value of attribute content_type. - # - # source://actiontext//lib/action_text/attachables/remote_image.rb#28 - def content_type; end - - # Returns the value of attribute height. - # - # source://actiontext//lib/action_text/attachables/remote_image.rb#28 - def height; end - - # source://activemodel/7.0.5/lib/active_model/naming.rb#244 - def model_name(*_arg0, **_arg1, &_arg2); end - - # source://actiontext//lib/action_text/attachables/remote_image.rb#41 - def to_partial_path; end - - # Returns the value of attribute url. - # - # source://actiontext//lib/action_text/attachables/remote_image.rb#28 - def url; end - - # Returns the value of attribute width. - # - # source://actiontext//lib/action_text/attachables/remote_image.rb#28 - def width; end - - class << self - # source://actiontext//lib/action_text/attachables/remote_image.rb#9 - def from_node(node); end - - private - - # source://actiontext//lib/action_text/attachables/remote_image.rb#20 - def attributes_from_node(node); end - - # @return [Boolean] - # - # source://actiontext//lib/action_text/attachables/remote_image.rb#16 - def content_type_is_image?(content_type); end - end -end - -# source://actiontext//lib/action_text/attachment.rb#6 -class ActionText::Attachment - include ::ActionText::Attachments::Caching - include ::ActionText::Attachments::Minification - include ::ActionText::Attachments::TrixConversion - extend ::ActionText::Attachments::Minification::ClassMethods - extend ::ActionText::Attachments::TrixConversion::ClassMethods - - # @return [Attachment] a new instance of Attachment - # - # source://actiontext//lib/action_text/attachment.rb#55 - def initialize(node, attachable); end - - # Returns the value of attribute attachable. - # - # source://actiontext//lib/action_text/attachment.rb#50 - def attachable; end - - # source://actiontext//lib/action_text/attachment.rb#60 - def caption; end - - # source://actiontext//lib/action_text/attachment.rb#64 - def full_attributes; end - - # source://actiontext//lib/action_text/attachment.rb#88 - def inspect; end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#302 - def method_missing(method, *args, **_arg2, &block); end - - # Returns the value of attribute node. - # - # source://actiontext//lib/action_text/attachment.rb#50 - def node; end - - # source://actiontext//lib/action_text/attachment.rb#9 - def tag_name; end - - # source://actiontext//lib/action_text/attachment.rb#9 - def tag_name=(val); end - - # source://actiontext//lib/action_text/attachment.rb#80 - def to_html; end - - # source://actiontext//lib/action_text/attachment.rb#52 - def to_param(*_arg0, **_arg1, &_arg2); end - - # source://actiontext//lib/action_text/attachment.rb#72 - def to_plain_text; end - - # source://actiontext//lib/action_text/attachment.rb#84 - def to_s; end - - # source://actiontext//lib/action_text/attachment.rb#68 - def with_full_attributes; end - - private - - # source://actiontext//lib/action_text/attachment.rb#97 - def attachable_attributes; end - - # source://actiontext//lib/action_text/attachment.rb#93 - def node_attributes; end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#294 - def respond_to_missing?(name, include_private = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attachment.rb#101 - def sgid_attributes; end - - class << self - # source://actiontext//lib/action_text/attachment.rb#14 - def fragment_by_canonicalizing_attachments(content); end - - # source://actiontext//lib/action_text/attachment.rb#26 - def from_attachable(attachable, attributes = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attachment.rb#22 - def from_attachables(attachables); end - - # source://actiontext//lib/action_text/attachment.rb#32 - def from_attributes(attributes, attachable = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attachment.rb#18 - def from_node(node, attachable = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attachment.rb#9 - def tag_name; end - - # source://actiontext//lib/action_text/attachment.rb#9 - def tag_name=(val); end - - private - - # source://actiontext//lib/action_text/attachment.rb#39 - def node_from_attributes(attributes); end - - # source://actiontext//lib/action_text/attachment.rb#45 - def process_attributes(attributes); end - end -end - -# source://actiontext//lib/action_text/attachment.rb#11 -ActionText::Attachment::ATTRIBUTES = T.let(T.unsafe(nil), Array) - -# source://actiontext//lib/action_text/attachment_gallery.rb#4 -class ActionText::AttachmentGallery - include ::ActiveModel::Validations - include ::ActiveSupport::Callbacks - include ::ActiveModel::Validations::HelperMethods - include ::ActiveModel::Conversion - include ::ActiveModel::ForbiddenAttributesProtection - include ::ActiveModel::AttributeAssignment - include ::ActiveModel::API - include ::ActiveModel::Model - extend ::ActiveModel::Validations::ClassMethods - extend ::ActiveModel::Naming - extend ::ActiveModel::Callbacks - extend ::ActiveSupport::Callbacks::ClassMethods - extend ::ActiveSupport::DescendantsTracker - extend ::ActiveModel::Translation - extend ::ActiveModel::Validations::HelperMethods - extend ::ActiveModel::Conversion::ClassMethods - - # @return [AttachmentGallery] a new instance of AttachmentGallery - # - # source://actiontext//lib/action_text/attachment_gallery.rb#52 - def initialize(node); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 - def _run_validate_callbacks(&block); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 - def _validate_callbacks; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators?; end - - # source://actiontext//lib/action_text/attachment_gallery.rb#56 - def attachments; end - - # source://actiontext//lib/action_text/attachment_gallery.rb#66 - def inspect; end - - # source://activemodel/7.0.5/lib/active_model/naming.rb#244 - def model_name(*_arg0, **_arg1, &_arg2); end - - # Returns the value of attribute node. - # - # source://actiontext//lib/action_text/attachment_gallery.rb#50 - def node; end - - # source://actiontext//lib/action_text/attachment_gallery.rb#62 - def size; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#48 - def validation_context; end - - private - - # source://activemodel/7.0.5/lib/active_model/validations.rb#48 - def validation_context=(_arg0); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks=(value); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 - def _validate_callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 - def _validate_callbacks=(value); end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators=(value); end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators?; end - - # source://actiontext//lib/action_text/attachment_gallery.rb#41 - def attachment_selector; end - - # source://actiontext//lib/action_text/attachment_gallery.rb#25 - def find_attachment_gallery_nodes(content); end - - # source://actiontext//lib/action_text/attachment_gallery.rb#11 - def fragment_by_canonicalizing_attachment_galleries(content); end - - # source://actiontext//lib/action_text/attachment_gallery.rb#17 - def fragment_by_replacing_attachment_gallery_nodes(content); end - - # source://actiontext//lib/action_text/attachment_gallery.rb#37 - def from_node(node); end - - # source://actiontext//lib/action_text/attachment_gallery.rb#45 - def selector; end - end -end - -# source://actiontext//lib/action_text/attachment_gallery.rb#7 -ActionText::AttachmentGallery::TAG_NAME = T.let(T.unsafe(nil), String) - -# source://actiontext//lib/action_text.rb#33 -module ActionText::Attachments - extend ::ActiveSupport::Autoload -end - -# source://actiontext//lib/action_text/attachments/caching.rb#5 -module ActionText::Attachments::Caching - # source://actiontext//lib/action_text/attachments/caching.rb#6 - def cache_key(*args); end - - private - - # source://actiontext//lib/action_text/attachments/caching.rb#11 - def cache_digest; end -end - -# source://actiontext//lib/action_text/attachments/minification.rb#5 -module ActionText::Attachments::Minification - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionText::Attachments::Minification::ClassMethods -end - -# source://actiontext//lib/action_text/attachments/minification.rb#0 -module ActionText::Attachments::Minification::ClassMethods - # source://actiontext//lib/action_text/attachments/minification.rb#9 - def fragment_by_minifying_attachments(content); end -end - -# source://actiontext//lib/action_text/attachments/trix_conversion.rb#7 -module ActionText::Attachments::TrixConversion - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionText::Attachments::TrixConversion::ClassMethods - - # source://actiontext//lib/action_text/attachments/trix_conversion.rb#22 - def to_trix_attachment(content = T.unsafe(nil)); end - - private - - # source://actiontext//lib/action_text/attachments/trix_conversion.rb#29 - def trix_attachment_content; end -end - -# source://actiontext//lib/action_text/attachments/trix_conversion.rb#0 -module ActionText::Attachments::TrixConversion::ClassMethods - # source://actiontext//lib/action_text/attachments/trix_conversion.rb#11 - def fragment_by_converting_trix_attachments(content); end - - # source://actiontext//lib/action_text/attachments/trix_conversion.rb#17 - def from_trix_attachment(trix_attachment); end -end - -# source://actiontext//lib/action_text/attribute.rb#4 -module ActionText::Attribute - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionText::Attribute::ClassMethods -end - -# source://actiontext//lib/action_text/attribute.rb#0 -module ActionText::Attribute::ClassMethods - # source://actiontext//lib/action_text/attribute.rb#33 - def has_rich_text(name, encrypted: T.unsafe(nil)); end - - # source://actiontext//lib/action_text/attribute.rb#61 - def rich_text_association_names; end - - # source://actiontext//lib/action_text/attribute.rb#57 - def with_all_rich_text; end -end - -# source://actiontext//lib/action_text/content.rb#4 -class ActionText::Content - include ::ActionText::Serialization - include ::ActionText::Rendering - extend ::ActionText::Serialization::ClassMethods - extend ::ActionText::Rendering::ClassMethods - - # @return [Content] a new instance of Content - # - # source://actiontext//lib/action_text/content.rb#19 - def initialize(content = T.unsafe(nil), options = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/content.rb#106 - def ==(other); end - - # source://actiontext//lib/action_text/content.rb#55 - def append_attachables(attachables); end - - # source://actiontext//lib/action_text/content.rb#98 - def as_json(*_arg0); end - - # source://actiontext//lib/action_text/content.rb#49 - def attachables; end - - # source://actiontext//lib/action_text/content.rb#39 - def attachment_galleries; end - - # source://actiontext//lib/action_text/content.rb#33 - def attachments; end - - # source://actiontext//lib/action_text/content.rb#9 - def blank?(*_arg0, **_arg1, &_arg2); end - - # source://actiontext//lib/action_text/content.rb#9 - def empty?(*_arg0, **_arg1, &_arg2); end - - # Returns the value of attribute fragment. - # - # source://actiontext//lib/action_text/content.rb#7 - def fragment; end - - # source://actiontext//lib/action_text/content.rb#45 - def gallery_attachments; end - - # source://actiontext//lib/action_text/content.rb#9 - def html_safe(*_arg0, **_arg1, &_arg2); end - - # source://actiontext//lib/action_text/content.rb#102 - def inspect; end - - # source://actiontext//lib/action_text/content.rb#29 - def links; end - - # source://actiontext//lib/action_text/content.rb#9 - def present?(*_arg0, **_arg1, &_arg2); end - - # source://actiontext//lib/action_text/rendering.rb#13 - def render(*_arg0, **_arg1, &_arg2); end - - # source://actiontext//lib/action_text/content.rb#67 - def render_attachment_galleries(&block); end - - # source://actiontext//lib/action_text/content.rb#60 - def render_attachments(**options, &block); end - - # source://actiontext//lib/action_text/content.rb#82 - def to_html; end - - # source://actiontext//lib/action_text/content.rb#90 - def to_partial_path; end - - # source://actiontext//lib/action_text/content.rb#74 - def to_plain_text; end - - # source://actiontext//lib/action_text/content.rb#86 - def to_rendered_html_with_layout; end - - # source://actiontext//lib/action_text/content.rb#94 - def to_s; end - - # source://actiontext//lib/action_text/content.rb#78 - def to_trix_html; end - - private - - # source://actiontext//lib/action_text/content.rb#121 - def attachment_for_node(node, with_full_attributes: T.unsafe(nil)); end - - # source://actiontext//lib/action_text/content.rb#126 - def attachment_gallery_for_node(node); end - - # source://actiontext//lib/action_text/content.rb#117 - def attachment_gallery_nodes; end - - # source://actiontext//lib/action_text/content.rb#113 - def attachment_nodes; end - - class << self - # source://actiontext//lib/action_text/rendering.rb#11 - def default_renderer; end - - # source://actiontext//lib/action_text/rendering.rb#11 - def default_renderer=(val); end - - # source://actiontext//lib/action_text/content.rb#12 - def fragment_by_canonicalizing_content(content); end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#48 - def renderer; end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#92 - def renderer=(obj); end - end -end - -module ActionText::ContentHelper - def allowed_attributes; end - def allowed_attributes=(val); end - def allowed_tags; end - def allowed_tags=(val); end - def render_action_text_attachment(attachment, locals: T.unsafe(nil)); end - def render_action_text_attachments(content); end - def render_action_text_content(content); end - def sanitize_action_text_content(content); end - def sanitizer; end - def sanitizer=(val); end - def scrubber; end - def scrubber=(val); end - - class << self - def allowed_attributes; end - def allowed_attributes=(val); end - def allowed_tags; end - def allowed_tags=(val); end - def sanitizer; end - def sanitizer=(val); end - def scrubber; end - def scrubber=(val); end - end -end - -class ActionText::EncryptedRichText < ::ActionText::RichText - include ::ActionText::EncryptedRichText::GeneratedAttributeMethods - include ::ActionText::EncryptedRichText::GeneratedAssociationMethods - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/attributes.rb#11 - def attributes_to_define_after_schema_loads; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - - # source://activerecord/7.0.5/lib/active_record/encryption/encryptable_record.rb#11 - def encrypted_attributes; end - end -end - -module ActionText::EncryptedRichText::GeneratedAssociationMethods; end -module ActionText::EncryptedRichText::GeneratedAttributeMethods; end - -# source://actiontext//lib/action_text/encryption.rb#4 -module ActionText::Encryption - # source://actiontext//lib/action_text/encryption.rb#12 - def decrypt; end - - # source://actiontext//lib/action_text/encryption.rb#5 - def encrypt; end - - private - - # source://actiontext//lib/action_text/encryption.rb#24 - def decrypt_rich_texts; end - - # source://actiontext//lib/action_text/encryption.rb#20 - def encrypt_rich_texts; end - - # source://actiontext//lib/action_text/encryption.rb#32 - def encryptable_rich_texts; end - - # @return [Boolean] - # - # source://actiontext//lib/action_text/encryption.rb#28 - def has_encrypted_rich_texts?; end -end - -# source://actiontext//lib/action_text/engine.rb#11 -class ActionText::Engine < ::Rails::Engine; end - -# Fixtures are a way of organizing data that you want to test against; in -# short, sample data. -# -# To learn more about fixtures, read the ActiveRecord::FixtureSet documentation. -# -# === YAML -# -# Like other Active Record-backed models, ActionText::RichText records inherit -# from ActiveRecord::Base instances and can therefore be populated by -# fixtures. -# -# Consider an Article class: -# -# class Article < ApplicationRecord -# has_rich_text :content -# end -# -# To declare fixture data for the related content, first declare fixture -# data for Article instances in test/fixtures/articles.yml: -# -# first: -# title: An Article -# -# Then declare the ActionText::RichText fixture data in -# test/fixtures/action_text/rich_texts.yml, making sure to declare -# each entry's record: key as a polymorphic relationship: -# -# first: -# record: first (Article) -# name: content -# body:
Hello, world.
-# -# When processed, Active Record will insert database records for each fixture -# entry and will ensure the Action Text relationship is intact. -# -# source://actiontext//lib/action_text/fixture_set.rb#38 -class ActionText::FixtureSet - class << self - # Fixtures support Action Text attachments as part of their body - # HTML. - # - # === Examples - # - # For example, consider a second Article fixture declared in - # test/fixtures/articles.yml: - # - # second: - # title: Another Article - # - # You can attach a mention of articles(:first) to second's - # content by embedding a call to ActionText::FixtureSet.attachment - # in the body: value in test/fixtures/action_text/rich_texts.yml: - # - # second: - # record: second (Article) - # name: content - # body:
Hello, <%= ActionText::FixtureSet.attachment("articles", :first) %>
- # - # source://actiontext//lib/action_text/fixture_set.rb#59 - def attachment(fixture_set_name, label, column_type: T.unsafe(nil)); end - end -end - -# source://actiontext//lib/action_text/fragment.rb#4 -class ActionText::Fragment - # @return [Fragment] a new instance of Fragment - # - # source://actiontext//lib/action_text/fragment.rb#24 - def initialize(source); end - - # source://actiontext//lib/action_text/fragment.rb#28 - def find_all(selector); end - - # source://actiontext//lib/action_text/fragment.rb#37 - def replace(selector); end - - # Returns the value of attribute source. - # - # source://actiontext//lib/action_text/fragment.rb#22 - def source; end - - # source://actiontext//lib/action_text/fragment.rb#49 - def to_html; end - - # source://actiontext//lib/action_text/fragment.rb#45 - def to_plain_text; end - - # source://actiontext//lib/action_text/fragment.rb#53 - def to_s; end - - # @yield [source = self.source.clone] - # - # source://actiontext//lib/action_text/fragment.rb#32 - def update; end - - class << self - # source://actiontext//lib/action_text/fragment.rb#17 - def from_html(html); end - - # source://actiontext//lib/action_text/fragment.rb#6 - def wrap(fragment_or_html); end - end -end - -# source://actiontext//lib/action_text/html_conversion.rb#4 -module ActionText::HtmlConversion - extend ::ActionText::HtmlConversion - - # source://actiontext//lib/action_text/html_conversion.rb#15 - def create_element(tag_name, attributes = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/html_conversion.rb#11 - def fragment_for_html(html); end - - # source://actiontext//lib/action_text/html_conversion.rb#7 - def node_to_html(node); end - - private - - # source://actiontext//lib/action_text/html_conversion.rb#20 - def document; end -end - -# source://actiontext//lib/action_text/plain_text_conversion.rb#4 -module ActionText::PlainTextConversion - extend ::ActionText::PlainTextConversion - - # source://actiontext//lib/action_text/plain_text_conversion.rb#7 - def node_to_plain_text(node); end - - private - - # source://actiontext//lib/action_text/plain_text_conversion.rb#104 - def break_if_nested_list(node, text); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#81 - def bullet_for_li_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#93 - def indentation_for_li_node(node); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#100 - def list_node_depth_for_node(node); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#89 - def list_node_name_for_li_node(node); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#32 - def plain_text_for_block(node, index = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#64 - def plain_text_for_blockquote_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#48 - def plain_text_for_br_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#56 - def plain_text_for_div_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#60 - def plain_text_for_figcaption_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#32 - def plain_text_for_h1_node(node, index = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#69 - def plain_text_for_li_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#40 - def plain_text_for_list(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#12 - def plain_text_for_node(node, index = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#20 - def plain_text_for_node_children(node); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#40 - def plain_text_for_ol_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#32 - def plain_text_for_p_node(node, index = T.unsafe(nil)); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#52 - def plain_text_for_text_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#40 - def plain_text_for_ul_node(node, index); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#28 - def plain_text_method_for_node(node); end - - # source://actiontext//lib/action_text/plain_text_conversion.rb#77 - def remove_trailing_newlines(text); end -end - -class ActionText::Record < ::ActiveRecord::Base - include ::ActionText::Record::GeneratedAttributeMethods - include ::ActionText::Record::GeneratedAssociationMethods - - class << self - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - end -end - -module ActionText::Record::GeneratedAssociationMethods; end -module ActionText::Record::GeneratedAttributeMethods; end - -# source://actiontext//lib/action_text/rendering.rb#7 -module ActionText::Rendering - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionText::Rendering::ClassMethods -end - -# source://actiontext//lib/action_text/rendering.rb#0 -module ActionText::Rendering::ClassMethods - # source://actiontext//lib/action_text/rendering.rb#25 - def render(*args, &block); end - - # source://actiontext//lib/action_text/rendering.rb#17 - def with_renderer(renderer); end -end - -class ActionText::RichText < ::ActionText::Record - include ::ActionText::RichText::GeneratedAttributeMethods - include ::ActionText::RichText::GeneratedAssociationMethods - - # source://activerecord/7.0.5/lib/active_record/autosave_association.rb#160 - def autosave_associated_records_for_record(*args); end - - def nil?(*_arg0, **_arg1, &_arg2); end - def to_s(*_arg0, **_arg1, &_arg2); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activerecord/7.0.5/lib/active_record/reflection.rb#11 - def _reflections; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/attributes.rb#11 - def attributes_to_define_after_schema_loads; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - end -end - -module ActionText::RichText::GeneratedAssociationMethods - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#103 - def record; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#111 - def record=(value); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#132 - def record_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#136 - def record_previously_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#19 - def reload_record; end -end - -module ActionText::RichText::GeneratedAttributeMethods; end - -# source://actiontext//lib/action_text/serialization.rb#4 -module ActionText::Serialization - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActionText::Serialization::ClassMethods - - # source://actiontext//lib/action_text/serialization.rb#32 - def _dump(*_arg0); end -end - -# source://actiontext//lib/action_text/serialization.rb#0 -module ActionText::Serialization::ClassMethods - # source://actiontext//lib/action_text/serialization.rb#8 - def _load(content); end - - # source://actiontext//lib/action_text/serialization.rb#12 - def dump(content); end - - # source://actiontext//lib/action_text/serialization.rb#8 - def load(content); end -end - -module ActionText::TagHelper - def rich_text_area_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end - - class << self - def id; end - def id=(val); end - end -end - -# source://actiontext//lib/action_text/trix_attachment.rb#4 -class ActionText::TrixAttachment - # @return [TrixAttachment] a new instance of TrixAttachment - # - # source://actiontext//lib/action_text/trix_attachment.rb#51 - def initialize(node); end - - # source://actiontext//lib/action_text/trix_attachment.rb#55 - def attributes; end - - # Returns the value of attribute node. - # - # source://actiontext//lib/action_text/trix_attachment.rb#49 - def node; end - - # source://actiontext//lib/action_text/trix_attachment.rb#59 - def to_html; end - - # source://actiontext//lib/action_text/trix_attachment.rb#63 - def to_s; end - - private - - # source://actiontext//lib/action_text/trix_attachment.rb#68 - def attachment_attributes; end - - # source://actiontext//lib/action_text/trix_attachment.rb#72 - def composed_attributes; end - - # source://actiontext//lib/action_text/trix_attachment.rb#80 - def read_json_attribute(name); end - - # source://actiontext//lib/action_text/trix_attachment.rb#76 - def read_json_object_attribute(name); end - - class << self - # source://actiontext//lib/action_text/trix_attachment.rb#19 - def from_attributes(attributes); end - - private - - # source://actiontext//lib/action_text/trix_attachment.rb#33 - def process_attributes(attributes); end - - # source://actiontext//lib/action_text/trix_attachment.rb#37 - def transform_attribute_keys(attributes); end - - # source://actiontext//lib/action_text/trix_attachment.rb#41 - def typecast_attribute_values(attributes); end - end -end - -# source://actiontext//lib/action_text/trix_attachment.rb#9 -ActionText::TrixAttachment::ATTRIBUTES = T.let(T.unsafe(nil), Array) - -# source://actiontext//lib/action_text/trix_attachment.rb#10 -ActionText::TrixAttachment::ATTRIBUTE_TYPES = T.let(T.unsafe(nil), Hash) - -# source://actiontext//lib/action_text/trix_attachment.rb#8 -ActionText::TrixAttachment::COMPOSED_ATTRIBUTES = T.let(T.unsafe(nil), Array) - -# source://actiontext//lib/action_text/trix_attachment.rb#6 -ActionText::TrixAttachment::SELECTOR = T.let(T.unsafe(nil), String) - -# source://actiontext//lib/action_text/trix_attachment.rb#5 -ActionText::TrixAttachment::TAG_NAME = T.let(T.unsafe(nil), String) - -module ActionView::Helpers - include ::ActionView::Helpers::SanitizeHelper - include ::ActionView::Helpers::TextHelper - include ::ActionView::Helpers::UrlHelper - include ::ActionView::Helpers::SanitizeHelper - include ::ActionView::Helpers::TextHelper - include ::ActionView::Helpers::FormTagHelper - include ::ActionView::Helpers::FormHelper - include ::ActionView::Helpers::TranslationHelper - - mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods - mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods - - class << self - # source://actionview/7.0.5/lib/action_view/helpers.rb#34 - def eager_load!; end - end -end - -class ActionView::Helpers::FormBuilder - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1700 - def initialize(object_name, object, template, options); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2614 - def button(value = T.unsafe(nil), options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2438 - def check_box(method, options = T.unsafe(nil), checked_value = T.unsafe(nil), unchecked_value = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#907 - def collection_check_boxes(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#919 - def collection_radio_buttons(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#859 - def collection_select(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def color_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def date_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/date_helper.rb#1239 - def date_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def datetime_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def datetime_local_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/date_helper.rb#1263 - def datetime_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def email_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2635 - def emitted_hidden_id?; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 - def field_helpers; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 - def field_helpers=(_arg0); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 - def field_helpers?; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1757 - def field_id(method, *suffixes, namespace: T.unsafe(nil), index: T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1777 - def field_name(method, *methods, multiple: T.unsafe(nil), index: T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2294 - def fields(scope = T.unsafe(nil), model: T.unsafe(nil), **options, &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2257 - def fields_for(record_name, record_object = T.unsafe(nil), fields_options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2521 - def file_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#871 - def grouped_collection_select(method, collection, group_method, group_label_method, option_key_method, option_value_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2482 - def hidden_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1737 - def id; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1677 - def index; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2369 - def label(method, text = T.unsafe(nil), options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def month_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1677 - def multipart; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1680 - def multipart=(multipart); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1677 - def multipart?; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def number_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 - def object; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 - def object=(_arg0); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 - def object_name; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 - def object_name=(_arg0); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 - def options; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 - def options=(_arg0); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def password_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def phone_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2460 - def radio_button(method, tag_value, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def range_field(method, options = T.unsafe(nil)); end - - def rich_text_area(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def search_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#847 - def select(method, choices = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2553 - def submit(value = T.unsafe(nil), options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def telephone_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def text_area(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def text_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def time_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/date_helper.rb#1251 - def time_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#883 - def time_zone_select(method, priority_zones = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1696 - def to_model; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1692 - def to_partial_path; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def url_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 - def week_field(method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#895 - def weekday_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - - private - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2720 - def convert_to_legacy_options(options); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2702 - def fields_for_nested_model(name, object, fields_options, block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2673 - def fields_for_with_nested_attributes(association_name, association, options, block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2669 - def nested_attributes_association?(association_name); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2715 - def nested_child_index(name); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2640 - def objectify_options(options); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2646 - def submit_default_value; end - - class << self - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1688 - def _to_partial_path; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 - def field_helpers; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 - def field_helpers=(value); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 - def field_helpers?; end - end -end - -module ActionView::Helpers::FormHelper - include ::ActionView::Helpers::UrlHelper - include ::ActionView::Helpers::SanitizeHelper - include ::ActionView::Helpers::TextHelper - include ::ActionView::Helpers::FormTagHelper - - mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods - mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1573 - def _object_for_form_builder(object); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1336 - def check_box(object_name, method, options = T.unsafe(nil), checked_value = T.unsafe(nil), unchecked_value = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1366 - def color_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1430 - def date_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1497 - def datetime_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1497 - def datetime_local_field(object_name, method, options = T.unsafe(nil)); end - - def default_form_builder; end - def default_form_builder=(_arg0); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1551 - def email_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1072 - def fields(scope = T.unsafe(nil), model: T.unsafe(nil), **options, &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1021 - def fields_for(record_name, record_object = T.unsafe(nil), options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1238 - def file_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#433 - def form_for(record, options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#754 - def form_with(model: T.unsafe(nil), scope: T.unsafe(nil), url: T.unsafe(nil), format: T.unsafe(nil), **options, &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#479 - def form_with_generates_ids; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#479 - def form_with_generates_ids=(val); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#477 - def form_with_generates_remote_forms; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#477 - def form_with_generates_remote_forms=(val); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1205 - def hidden_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1142 - def label(object_name, method, content_or_options = T.unsafe(nil), options = T.unsafe(nil), &block); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1516 - def month_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#481 - def multiple_file_field_include_hidden; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#481 - def multiple_file_field_include_hidden=(val); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1560 - def number_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1187 - def password_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1398 - def phone_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1358 - def radio_button(object_name, method, tag_value, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1569 - def range_field(object_name, method, options = T.unsafe(nil)); end - - def rich_text_area(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1389 - def search_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1398 - def telephone_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1268 - def text_area(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1166 - def text_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1468 - def time_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1542 - def url_field(object_name, method, options = T.unsafe(nil)); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1533 - def week_field(object_name, method, options = T.unsafe(nil)); end - - private - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#463 - def apply_form_for_options!(object, options); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1607 - def default_form_builder_class; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1578 - def html_options_for_form_with(url_for_options = T.unsafe(nil), model = T.unsafe(nil), html: T.unsafe(nil), local: T.unsafe(nil), skip_enforcing_utf8: T.unsafe(nil), **options); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1593 - def instantiate_builder(record_name, record_object, options); end - - class << self - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#479 - def form_with_generates_ids; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#479 - def form_with_generates_ids=(val); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#477 - def form_with_generates_remote_forms; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#477 - def form_with_generates_remote_forms=(val); end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#481 - def multiple_file_field_include_hidden; end - - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#481 - def multiple_file_field_include_hidden=(val); end - end -end - -module ActionView::Helpers::Tags; end - -class ActionView::Helpers::Tags::ActionText < ::ActionView::Helpers::Tags::Base - include ::ActionView::Helpers::Tags::Placeholderable - - def dom_id(*_arg0, **_arg1, &_arg2); end - def render; end -end diff --git a/sorbet/rbi/gems/actiontext@7.2.0.rbi b/sorbet/rbi/gems/actiontext@7.2.0.rbi new file mode 100644 index 000000000..e4a30303b --- /dev/null +++ b/sorbet/rbi/gems/actiontext@7.2.0.rbi @@ -0,0 +1,1851 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `actiontext` gem. +# Please instead update this file by running `bin/tapioca gem actiontext`. + + +# :markup: markdown +# :include: ../README.md +# +# source://actiontext//lib/action_text/gem_version.rb#5 +module ActionText + extend ::ActiveSupport::Autoload + + class << self + # source://actiontext//lib/action_text/deprecator.rb#6 + def deprecator; end + + # Returns the currently loaded version of Action Text as a `Gem::Version`. + # + # source://actiontext//lib/action_text/gem_version.rb#7 + def gem_version; end + + # source://actiontext//lib/action_text.rb#47 + def html_document_class; end + + # source://actiontext//lib/action_text.rb#53 + def html_document_fragment_class; end + + # source://railties/7.2.0/lib/rails/engine.rb#412 + def railtie_helpers_paths; end + + # source://railties/7.2.0/lib/rails/engine.rb#395 + def railtie_namespace; end + + # source://railties/7.2.0/lib/rails/engine.rb#416 + def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end + + # source://railties/7.2.0/lib/rails/engine.rb#401 + def table_name_prefix; end + + # source://railties/7.2.0/lib/rails/engine.rb#408 + def use_relative_model_naming?; end + + # Returns the currently loaded version of Action Text as a `Gem::Version`. + # + # source://actiontext//lib/action_text/version.rb#9 + def version; end + end +end + +# # Action Text Attachable +# +# Include this module to make a record attachable to an ActionText::Content. +# +# class Person < ApplicationRecord +# include ActionText::Attachable +# end +# +# person = Person.create! name: "Javan" +# html = %Q() +# content = ActionText::Content.new(html) +# content.attachables # => [person] +# +# source://actiontext//lib/action_text/attachable.rb#18 +module ActionText::Attachable + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionText::Attachable::ClassMethods + + # source://actiontext//lib/action_text/attachable.rb#83 + def attachable_content_type; end + + # source://actiontext//lib/action_text/attachable.rb#87 + def attachable_filename; end + + # source://actiontext//lib/action_text/attachable.rb#91 + def attachable_filesize; end + + # source://actiontext//lib/action_text/attachable.rb#95 + def attachable_metadata; end + + # Returns the Signed Global ID for the attachable. The purpose of the ID is set + # to 'attachable' so it can't be reused for other purposes. + # + # source://actiontext//lib/action_text/attachable.rb#79 + def attachable_sgid; end + + # @return [Boolean] + # + # source://actiontext//lib/action_text/attachable.rb#99 + def previewable_attachable?; end + + # Returns the path to the partial that is used for rendering the attachable. + # Defaults to `to_partial_path`. + # + # Override to render a different partial: + # + # class User < ApplicationRecord + # def to_attachable_partial_path + # "users/attachable" + # end + # end + # + # source://actiontext//lib/action_text/attachable.rb#127 + def to_attachable_partial_path; end + + # source://actiontext//lib/action_text/attachable.rb#131 + def to_rich_text_attributes(attributes = T.unsafe(nil)); end + + # Returns the path to the partial that is used for rendering the attachable in + # Trix. Defaults to `to_partial_path`. + # + # Override to render a different partial: + # + # class User < ApplicationRecord + # def to_trix_content_attachment_partial_path + # "users/trix_content_attachment" + # end + # end + # + # source://actiontext//lib/action_text/attachable.rb#113 + def to_trix_content_attachment_partial_path; end + + private + + # source://actiontext//lib/action_text/attachable.rb#144 + def attribute_names_for_serialization; end + + # source://actiontext//lib/action_text/attachable.rb#148 + def read_attribute_for_serialization(key); end + + class << self + # source://actiontext//lib/action_text/attachable.rb#43 + def from_attachable_sgid(sgid, options = T.unsafe(nil)); end + + # Extracts the `ActionText::Attachable` from the attachment HTML node: + # + # person = Person.create! name: "Javan" + # html = %Q() + # fragment = ActionText::Fragment.wrap(html) + # attachment_node = fragment.find_all(ActionText::Attachment.tag_name).first + # ActionText::Attachable.from_node(attachment_node) # => person + # + # source://actiontext//lib/action_text/attachable.rb#31 + def from_node(node); end + + private + + # source://actiontext//lib/action_text/attachable.rb#50 + def attachable_from_sgid(sgid); end + end +end + +# source://actiontext//lib/action_text/attachable.rb#0 +module ActionText::Attachable::ClassMethods + # source://actiontext//lib/action_text/attachable.rb#58 + def from_attachable_sgid(sgid); end + + # source://actiontext//lib/action_text/attachable.rb#72 + def to_missing_attachable_partial_path; end +end + +# source://actiontext//lib/action_text/attachable.rb#21 +ActionText::Attachable::LOCATOR_NAME = T.let(T.unsafe(nil), String) + +# source://actiontext//lib/action_text.rb#30 +module ActionText::Attachables + extend ::ActiveSupport::Autoload +end + +# source://actiontext//lib/action_text/attachables/content_attachment.rb#7 +class ActionText::Attachables::ContentAttachment + include ::ActiveModel::Validations + include ::ActiveSupport::Callbacks + include ::ActiveModel::Validations::HelperMethods + include ::ActiveModel::Conversion + include ::ActiveModel::ForbiddenAttributesProtection + include ::ActiveModel::AttributeAssignment + include ::ActiveModel::API + include ::ActiveModel::Access + include ::ActiveModel::Model + extend ::ActiveModel::Validations::ClassMethods + extend ::ActiveModel::Naming + extend ::ActiveModel::Callbacks + extend ::ActiveSupport::Callbacks::ClassMethods + extend ::ActiveSupport::DescendantsTracker + extend ::ActiveModel::Translation + extend ::ActiveModel::Validations::HelperMethods + extend ::ActiveModel::Conversion::ClassMethods + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_validate_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _validate_callbacks; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators?; end + + # source://actiontext//lib/action_text/attachables/content_attachment.rb#20 + def attachable_plain_text_representation(caption); end + + # Returns the value of attribute content. + # + # source://actiontext//lib/action_text/attachables/content_attachment.rb#15 + def content; end + + # Sets the attribute content + # + # @param value the value to set the attribute content to. + # + # source://actiontext//lib/action_text/attachables/content_attachment.rb#15 + def content=(_arg0); end + + # Returns the value of attribute content_type. + # + # source://actiontext//lib/action_text/attachables/content_attachment.rb#15 + def content_type; end + + # Sets the attribute content_type + # + # @param value the value to set the attribute content_type to. + # + # source://actiontext//lib/action_text/attachables/content_attachment.rb#15 + def content_type=(_arg0); end + + # source://activemodel/7.2.0/lib/active_model/naming.rb#255 + def model_name(&_arg0); end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(_arg0); end + + # source://actiontext//lib/action_text/attachables/content_attachment.rb#24 + def to_html; end + + # source://actiontext//lib/action_text/attachables/content_attachment.rb#32 + def to_partial_path; end + + # source://actiontext//lib/action_text/attachables/content_attachment.rb#28 + def to_s; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 + def validation_context; end + + private + + # source://actiontext//lib/action_text/attachables/content_attachment.rb#37 + def content_instance; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 + def validation_context=(_arg0); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _validate_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _validate_callbacks=(value); end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators=(value); end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators?; end + + # source://actiontext//lib/action_text/attachables/content_attachment.rb#10 + def from_node(node); end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(value); end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter?; end + end +end + +# source://actiontext//lib/action_text/attachables/missing_attachable.rb#7 +class ActionText::Attachables::MissingAttachable + extend ::ActiveModel::Naming + + # @return [MissingAttachable] a new instance of MissingAttachable + # + # source://actiontext//lib/action_text/attachables/missing_attachable.rb#12 + def initialize(sgid); end + + # source://actiontext//lib/action_text/attachables/missing_attachable.rb#24 + def model; end + + # source://activemodel/7.2.0/lib/active_model/naming.rb#255 + def model_name(&_arg0); end + + # source://actiontext//lib/action_text/attachables/missing_attachable.rb#16 + def to_partial_path; end +end + +# source://actiontext//lib/action_text/attachables/missing_attachable.rb#10 +ActionText::Attachables::MissingAttachable::DEFAULT_PARTIAL_PATH = T.let(T.unsafe(nil), String) + +# source://actiontext//lib/action_text/attachables/remote_image.rb#7 +class ActionText::Attachables::RemoteImage + extend ::ActiveModel::Naming + + # @return [RemoteImage] a new instance of RemoteImage + # + # source://actiontext//lib/action_text/attachables/remote_image.rb#32 + def initialize(attributes = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/attachables/remote_image.rb#39 + def attachable_plain_text_representation(caption); end + + # Returns the value of attribute content_type. + # + # source://actiontext//lib/action_text/attachables/remote_image.rb#30 + def content_type; end + + # Returns the value of attribute height. + # + # source://actiontext//lib/action_text/attachables/remote_image.rb#30 + def height; end + + # source://activemodel/7.2.0/lib/active_model/naming.rb#255 + def model_name(&_arg0); end + + # source://actiontext//lib/action_text/attachables/remote_image.rb#43 + def to_partial_path; end + + # Returns the value of attribute url. + # + # source://actiontext//lib/action_text/attachables/remote_image.rb#30 + def url; end + + # Returns the value of attribute width. + # + # source://actiontext//lib/action_text/attachables/remote_image.rb#30 + def width; end + + class << self + # source://actiontext//lib/action_text/attachables/remote_image.rb#11 + def from_node(node); end + + private + + # source://actiontext//lib/action_text/attachables/remote_image.rb#22 + def attributes_from_node(node); end + + # @return [Boolean] + # + # source://actiontext//lib/action_text/attachables/remote_image.rb#18 + def content_type_is_image?(content_type); end + end +end + +# # Action Text Attachment +# +# Attachments serialize attachables to HTML or plain text. +# +# class Person < ApplicationRecord +# include ActionText::Attachable +# end +# +# attachable = Person.create! name: "Javan" +# attachment = ActionText::Attachment.from_attachable(attachable) +# attachment.to_html # => " " "[racecar.jpg]" + # + # Use the `caption` when set: + # + # attachment = ActionText::Attachment.from_attachable(attachable, caption: "Vroom vroom") + # attachment.to_plain_text # => "[Vroom vroom]" + # + # The presentation can be overridden by implementing the + # `attachable_plain_text_representation` method: + # + # class Person < ApplicationRecord + # include ActionText::Attachable + # + # def attachable_plain_text_representation + # "[#{name}]" + # end + # end + # + # attachable = Person.create! name: "Javan" + # attachment = ActionText::Attachment.from_attachable(attachable) + # attachment.to_plain_text # => "[Javan]" + # + # source://actiontext//lib/action_text/attachment.rb#110 + def to_plain_text; end + + # source://actiontext//lib/action_text/attachment.rb#127 + def to_s; end + + # source://actiontext//lib/action_text/attachment.rb#81 + def with_full_attributes; end + + private + + # source://actiontext//lib/action_text/attachment.rb#140 + def attachable_attributes; end + + # source://actiontext//lib/action_text/attachment.rb#136 + def node_attributes; end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#179 + def respond_to_missing?(name, include_private = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/attachment.rb#144 + def sgid_attributes; end + + class << self + # source://actiontext//lib/action_text/attachment.rb#27 + def fragment_by_canonicalizing_attachments(content); end + + # source://actiontext//lib/action_text/attachment.rb#39 + def from_attachable(attachable, attributes = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/attachment.rb#35 + def from_attachables(attachables); end + + # source://actiontext//lib/action_text/attachment.rb#45 + def from_attributes(attributes, attachable = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/attachment.rb#31 + def from_node(node, attachable = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/attachment.rb#22 + def tag_name; end + + # source://actiontext//lib/action_text/attachment.rb#22 + def tag_name=(val); end + + private + + # source://actiontext//lib/action_text/attachment.rb#52 + def node_from_attributes(attributes); end + + # source://actiontext//lib/action_text/attachment.rb#58 + def process_attributes(attributes); end + end +end + +# source://actiontext//lib/action_text/attachment.rb#24 +ActionText::Attachment::ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://actiontext//lib/action_text/attachment_gallery.rb#6 +class ActionText::AttachmentGallery + include ::ActiveModel::Validations + include ::ActiveSupport::Callbacks + include ::ActiveModel::Validations::HelperMethods + include ::ActiveModel::Conversion + include ::ActiveModel::ForbiddenAttributesProtection + include ::ActiveModel::AttributeAssignment + include ::ActiveModel::API + include ::ActiveModel::Access + include ::ActiveModel::Model + extend ::ActiveModel::Validations::ClassMethods + extend ::ActiveModel::Naming + extend ::ActiveModel::Callbacks + extend ::ActiveSupport::Callbacks::ClassMethods + extend ::ActiveSupport::DescendantsTracker + extend ::ActiveModel::Translation + extend ::ActiveModel::Validations::HelperMethods + extend ::ActiveModel::Conversion::ClassMethods + + # @return [AttachmentGallery] a new instance of AttachmentGallery + # + # source://actiontext//lib/action_text/attachment_gallery.rb#54 + def initialize(node); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_validate_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _validate_callbacks; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators?; end + + # source://actiontext//lib/action_text/attachment_gallery.rb#58 + def attachments; end + + # source://actiontext//lib/action_text/attachment_gallery.rb#68 + def inspect; end + + # source://activemodel/7.2.0/lib/active_model/naming.rb#255 + def model_name(&_arg0); end + + # Returns the value of attribute node. + # + # source://actiontext//lib/action_text/attachment_gallery.rb#52 + def node; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(_arg0); end + + # source://actiontext//lib/action_text/attachment_gallery.rb#64 + def size; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 + def validation_context; end + + private + + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 + def validation_context=(_arg0); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _validate_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _validate_callbacks=(value); end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators=(value); end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators?; end + + # source://actiontext//lib/action_text/attachment_gallery.rb#43 + def attachment_selector; end + + # source://actiontext//lib/action_text/attachment_gallery.rb#27 + def find_attachment_gallery_nodes(content); end + + # source://actiontext//lib/action_text/attachment_gallery.rb#13 + def fragment_by_canonicalizing_attachment_galleries(content); end + + # source://actiontext//lib/action_text/attachment_gallery.rb#19 + def fragment_by_replacing_attachment_gallery_nodes(content); end + + # source://actiontext//lib/action_text/attachment_gallery.rb#39 + def from_node(node); end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(value); end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter?; end + + # source://actiontext//lib/action_text/attachment_gallery.rb#47 + def selector; end + end +end + +# source://actiontext//lib/action_text/attachment_gallery.rb#9 +ActionText::AttachmentGallery::TAG_NAME = T.let(T.unsafe(nil), String) + +# source://actiontext//lib/action_text.rb#38 +module ActionText::Attachments + extend ::ActiveSupport::Autoload +end + +# source://actiontext//lib/action_text/attachments/caching.rb#7 +module ActionText::Attachments::Caching + # source://actiontext//lib/action_text/attachments/caching.rb#8 + def cache_key(*args); end + + private + + # source://actiontext//lib/action_text/attachments/caching.rb#13 + def cache_digest; end +end + +# source://actiontext//lib/action_text/attachments/minification.rb#7 +module ActionText::Attachments::Minification + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionText::Attachments::Minification::ClassMethods +end + +# source://actiontext//lib/action_text/attachments/minification.rb#0 +module ActionText::Attachments::Minification::ClassMethods + # source://actiontext//lib/action_text/attachments/minification.rb#11 + def fragment_by_minifying_attachments(content); end +end + +# source://actiontext//lib/action_text/attachments/trix_conversion.rb#9 +module ActionText::Attachments::TrixConversion + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionText::Attachments::TrixConversion::ClassMethods + + # source://actiontext//lib/action_text/attachments/trix_conversion.rb#24 + def to_trix_attachment(content = T.unsafe(nil)); end + + private + + # source://actiontext//lib/action_text/attachments/trix_conversion.rb#31 + def trix_attachment_content; end +end + +# source://actiontext//lib/action_text/attachments/trix_conversion.rb#0 +module ActionText::Attachments::TrixConversion::ClassMethods + # source://actiontext//lib/action_text/attachments/trix_conversion.rb#13 + def fragment_by_converting_trix_attachments(content); end + + # source://actiontext//lib/action_text/attachments/trix_conversion.rb#19 + def from_trix_attachment(trix_attachment); end +end + +# source://actiontext//lib/action_text/attribute.rb#6 +module ActionText::Attribute + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionText::Attribute::ClassMethods +end + +# source://actiontext//lib/action_text/attribute.rb#0 +module ActionText::Attribute::ClassMethods + # source://actiontext//lib/action_text/attribute.rb#50 + def has_rich_text(name, encrypted: T.unsafe(nil), strict_loading: T.unsafe(nil)); end + + # source://actiontext//lib/action_text/attribute.rb#80 + def rich_text_association_names; end + + # source://actiontext//lib/action_text/attribute.rb#75 + def with_all_rich_text; end +end + +# # Action Text Content +# +# The `ActionText::Content` class wraps an HTML fragment to add support for +# parsing, rendering and serialization. It can be used to extract links and +# attachments, convert the fragment to plain text, or serialize the fragment to +# the database. +# +# The ActionText::RichText record serializes the `body` attribute as +# `ActionText::Content`. +# +# class Message < ActiveRecord::Base +# has_rich_text :content +# end +# +# message = Message.create!(content: "

Funny times!

") +# body = message.content.body # => # +# body.to_s # => "

Funny times!

" +# body.to_plain_text # => "Funny times!" +# +# source://actiontext//lib/action_text/content.rb#24 +class ActionText::Content + include ::ActionText::ContentHelper + include ::ActionText::Serialization + include ::ActionText::Rendering + extend ::ActionText::Serialization::ClassMethods + extend ::ActionText::Rendering::ClassMethods + + # @return [Content] a new instance of Content + # + # source://actiontext//lib/action_text/content.rb#40 + def initialize(content = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/content.rb#168 + def ==(other); end + + # source://actiontext//lib/action_text/content.rb#93 + def append_attachables(attachables); end + + # source://actiontext//lib/action_text/content.rb#160 + def as_json(*_arg0); end + + # Extracts +ActionText::Attachable+s from the HTML fragment: + # + # attachable = ActiveStorage::Blob.first + # html = %Q() + # content = ActionText::Content.new(html) + # content.attachables # => [attachable] + # + # source://actiontext//lib/action_text/content.rb#87 + def attachables; end + + # source://actiontext//lib/action_text/content.rb#71 + def attachment_galleries; end + + # Extracts +ActionText::Attachment+s from the HTML fragment: + # + # attachable = ActiveStorage::Blob.first + # html = %Q() + # content = ActionText::Content.new(html) + # content.attachments # => [# ["http://example.com/"] + # + # source://actiontext//lib/action_text/content.rb#55 + def links; end + + # source://actiontext//lib/action_text/content.rb#30 + def present?(*_arg0, **_arg1, &_arg2); end + + # source://actiontext//lib/action_text/rendering.rb#14 + def render(*_arg0, **_arg1, &_arg2); end + + # source://actiontext//lib/action_text/content.rb#108 + def render_attachment_galleries(&block); end + + # source://actiontext//lib/action_text/content.rb#98 + def render_attachments(**options, &block); end + + # source://actiontext//lib/action_text/content.rb#137 + def to_html; end + + # source://actiontext//lib/action_text/content.rb#145 + def to_partial_path; end + + # Returns a plain-text version of the markup contained by the content, with tags + # removed but HTML entities encoded. + # + # content = ActionText::Content.new("

Funny times!

") + # content.to_plain_text # => "Funny times!" + # + # content = ActionText::Content.new("
safe
") + # content.to_plain_text # => "safeunsafe" + # + # NOTE: that the returned string is not HTML safe and should not be rendered in + # browsers. + # + # content = ActionText::Content.new("<script>alert()</script>") + # content.to_plain_text # => "" + # + # source://actiontext//lib/action_text/content.rb#129 + def to_plain_text; end + + # source://actiontext//lib/action_text/content.rb#141 + def to_rendered_html_with_layout; end + + # Safely transforms Content into an HTML String. + # + # content = ActionText::Content.new(content: "

Funny times!

") + # content.to_s # => "

Funny times!

" + # + # content = ActionText::Content.new("
safe
") + # content.to_s # => "
safeunsafe
" + # + # source://actiontext//lib/action_text/content.rb#156 + def to_s; end + + # source://actiontext//lib/action_text/content.rb#133 + def to_trix_html; end + + private + + # source://actiontext//lib/action_text/content.rb#185 + def attachment_for_node(node, with_full_attributes: T.unsafe(nil)); end + + # source://actiontext//lib/action_text/content.rb#190 + def attachment_gallery_for_node(node); end + + # source://actiontext//lib/action_text/content.rb#181 + def attachment_gallery_nodes; end + + # source://actiontext//lib/action_text/content.rb#177 + def attachment_nodes; end + + class << self + # source://actiontext//lib/action_text/content.rb#33 + def fragment_by_canonicalizing_content(content); end + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#49 + def renderer; end + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#108 + def renderer=(obj); end + end +end + +module ActionText::ContentHelper + def allowed_attributes; end + def allowed_attributes=(val); end + def allowed_tags; end + def allowed_tags=(val); end + def render_action_text_attachment(attachment, locals: T.unsafe(nil)); end + def render_action_text_attachments(content); end + def render_action_text_content(content); end + def sanitize_action_text_content(content); end + def sanitize_content_attachment(content_attachment); end + def sanitizer; end + def sanitizer=(val); end + def sanitizer_allowed_attributes; end + def sanitizer_allowed_tags; end + def scrubber; end + def scrubber=(val); end + + class << self + def allowed_attributes; end + def allowed_attributes=(val); end + def allowed_tags; end + def allowed_tags=(val); end + def sanitizer; end + def sanitizer=(val); end + def scrubber; end + def scrubber=(val); end + end +end + +class ActionText::EncryptedRichText < ::ActionText::RichText + include ::ActionText::EncryptedRichText::GeneratedAttributeMethods + include ::ActionText::EncryptedRichText::GeneratedAssociationMethods + + class << self + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + + # source://activerecord/7.2.0/lib/active_record/encryption/encryptable_record.rb#11 + def encrypted_attributes; end + end +end + +module ActionText::EncryptedRichText::GeneratedAssociationMethods; end +module ActionText::EncryptedRichText::GeneratedAttributeMethods; end + +# source://actiontext//lib/action_text/encryption.rb#6 +module ActionText::Encryption + # source://actiontext//lib/action_text/encryption.rb#14 + def decrypt; end + + # source://actiontext//lib/action_text/encryption.rb#7 + def encrypt; end + + private + + # source://actiontext//lib/action_text/encryption.rb#26 + def decrypt_rich_texts; end + + # source://actiontext//lib/action_text/encryption.rb#22 + def encrypt_rich_texts; end + + # source://actiontext//lib/action_text/encryption.rb#34 + def encryptable_rich_texts; end + + # @return [Boolean] + # + # source://actiontext//lib/action_text/encryption.rb#30 + def has_encrypted_rich_texts?; end +end + +# source://actiontext//lib/action_text/engine.rb#13 +class ActionText::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end + +# # Action Text FixtureSet +# +# Fixtures are a way of organizing data that you want to test against; in short, +# sample data. +# +# To learn more about fixtures, read the ActiveRecord::FixtureSet documentation. +# +# ### YAML +# +# Like other Active Record-backed models, ActionText::RichText records inherit +# from ActiveRecord::Base instances and can therefore be populated by fixtures. +# +# Consider an `Article` class: +# +# class Article < ApplicationRecord +# has_rich_text :content +# end +# +# To declare fixture data for the related `content`, first declare fixture data +# for `Article` instances in `test/fixtures/articles.yml`: +# +# first: +# title: An Article +# +# Then declare the ActionText::RichText fixture data in +# `test/fixtures/action_text/rich_texts.yml`, making sure to declare each +# entry's `record:` key as a polymorphic relationship: +# +# first: +# record: first (Article) +# name: content +# body:
Hello, world.
+# +# When processed, Active Record will insert database records for each fixture +# entry and will ensure the Action Text relationship is intact. +# +# source://actiontext//lib/action_text/fixture_set.rb#41 +class ActionText::FixtureSet + class << self + # Fixtures support Action Text attachments as part of their `body` HTML. + # + # ### Examples + # + # For example, consider a second `Article` fixture declared in + # `test/fixtures/articles.yml`: + # + # second: + # title: Another Article + # + # You can attach a mention of `articles(:first)` to `second`'s `content` by + # embedding a call to `ActionText::FixtureSet.attachment` in the `body:` value + # in `test/fixtures/action_text/rich_texts.yml`: + # + # second: + # record: second (Article) + # name: content + # body:
Hello, <%= ActionText::FixtureSet.attachment("articles", :first) %>
+ # + # source://actiontext//lib/action_text/fixture_set.rb#61 + def attachment(fixture_set_name, label, column_type: T.unsafe(nil)); end + end +end + +# source://actiontext//lib/action_text/fragment.rb#6 +class ActionText::Fragment + # @return [Fragment] a new instance of Fragment + # + # source://actiontext//lib/action_text/fragment.rb#28 + def initialize(source); end + + # source://actiontext//lib/action_text/fragment.rb#26 + def deconstruct(*_arg0, **_arg1, &_arg2); end + + # source://actiontext//lib/action_text/fragment.rb#32 + def find_all(selector); end + + # source://actiontext//lib/action_text/fragment.rb#41 + def replace(selector); end + + # Returns the value of attribute source. + # + # source://actiontext//lib/action_text/fragment.rb#24 + def source; end + + # source://actiontext//lib/action_text/fragment.rb#54 + def to_html; end + + # source://actiontext//lib/action_text/fragment.rb#50 + def to_plain_text; end + + # source://actiontext//lib/action_text/fragment.rb#58 + def to_s; end + + # @yield [source = self.source.dup] + # + # source://actiontext//lib/action_text/fragment.rb#36 + def update; end + + class << self + # source://actiontext//lib/action_text/fragment.rb#19 + def from_html(html); end + + # source://actiontext//lib/action_text/fragment.rb#8 + def wrap(fragment_or_html); end + end +end + +# source://actiontext//lib/action_text/html_conversion.rb#6 +module ActionText::HtmlConversion + extend ::ActionText::HtmlConversion + + # source://actiontext//lib/action_text/html_conversion.rb#17 + def create_element(tag_name, attributes = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/html_conversion.rb#13 + def fragment_for_html(html); end + + # source://actiontext//lib/action_text/html_conversion.rb#9 + def node_to_html(node); end + + private + + # source://actiontext//lib/action_text/html_conversion.rb#22 + def document; end +end + +# source://actiontext//lib/action_text/plain_text_conversion.rb#6 +module ActionText::PlainTextConversion + extend ::ActionText::PlainTextConversion + + # source://actiontext//lib/action_text/plain_text_conversion.rb#9 + def node_to_plain_text(node); end + + private + + # source://actiontext//lib/action_text/plain_text_conversion.rb#106 + def break_if_nested_list(node, text); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#83 + def bullet_for_li_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#95 + def indentation_for_li_node(node); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#102 + def list_node_depth_for_node(node); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#91 + def list_node_name_for_li_node(node); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#34 + def plain_text_for_block(node, index = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#66 + def plain_text_for_blockquote_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#50 + def plain_text_for_br_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#58 + def plain_text_for_div_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#62 + def plain_text_for_figcaption_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#34 + def plain_text_for_h1_node(node, index = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#71 + def plain_text_for_li_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#42 + def plain_text_for_list(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#14 + def plain_text_for_node(node, index = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#22 + def plain_text_for_node_children(node); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#42 + def plain_text_for_ol_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#34 + def plain_text_for_p_node(node, index = T.unsafe(nil)); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#54 + def plain_text_for_text_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#42 + def plain_text_for_ul_node(node, index); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#30 + def plain_text_method_for_node(node); end + + # source://actiontext//lib/action_text/plain_text_conversion.rb#79 + def remove_trailing_newlines(text); end +end + +class ActionText::Record < ::ActiveRecord::Base + include ::ActionText::Record::GeneratedAttributeMethods + include ::ActionText::Record::GeneratedAssociationMethods + + class << self + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + end +end + +module ActionText::Record::GeneratedAssociationMethods; end +module ActionText::Record::GeneratedAttributeMethods; end + +# source://actiontext//lib/action_text/rendering.rb#9 +module ActionText::Rendering + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionText::Rendering::ClassMethods +end + +# source://actiontext//lib/action_text/rendering.rb#0 +module ActionText::Rendering::ClassMethods + # source://actiontext//lib/action_text/rendering.rb#18 + def action_controller_renderer; end + + # source://actiontext//lib/action_text/rendering.rb#30 + def render(*args, &block); end + + # source://actiontext//lib/action_text/rendering.rb#22 + def with_renderer(renderer); end +end + +class ActionText::RichText < ::ActionText::Record + include ::ActionText::RichText::GeneratedAttributeMethods + include ::ActionText::RichText::GeneratedAssociationMethods + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_embeds_attachments(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_embeds_blobs(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_record(*args); end + + def blank?(*_arg0, **_arg1, &_arg2); end + def empty?(*_arg0, **_arg1, &_arg2); end + def nil?(*_arg0, **_arg1, &_arg2); end + def present?(*_arg0, **_arg1, &_arg2); end + def to_plain_text; end + def to_s(*_arg0, **_arg1, &_arg2); end + def to_trix_html; end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def validate_associated_records_for_embeds_attachments(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def validate_associated_records_for_embeds_blobs(*args); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activestorage/7.2.0/lib/active_storage/reflection.rb#53 + def attachment_reflections; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + + # source://activerecord/7.2.0/lib/active_record/scoping/named.rb#174 + def with_attached_embeds(*args, **_arg1); end + end +end + +module ActionText::RichText::GeneratedAssociationMethods + # source://activestorage/7.2.0/lib/active_storage/attached/model.rb#211 + def embeds; end + + # source://activestorage/7.2.0/lib/active_storage/attached/model.rb#216 + def embeds=(attachables); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#62 + def embeds_attachment_ids; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#72 + def embeds_attachment_ids=(ids); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def embeds_attachments; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def embeds_attachments=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#62 + def embeds_blob_ids; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#72 + def embeds_blob_ids=(ids); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def embeds_blobs; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def embeds_blobs=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def record; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def record=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#146 + def record_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#150 + def record_previously_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_record; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_record; end +end + +module ActionText::RichText::GeneratedAttributeMethods; end + +# source://actiontext//lib/action_text/serialization.rb#6 +module ActionText::Serialization + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActionText::Serialization::ClassMethods + + # source://actiontext//lib/action_text/serialization.rb#34 + def _dump(*_arg0); end +end + +# source://actiontext//lib/action_text/serialization.rb#0 +module ActionText::Serialization::ClassMethods + # source://actiontext//lib/action_text/serialization.rb#10 + def _load(content); end + + # source://actiontext//lib/action_text/serialization.rb#14 + def dump(content); end + + # source://actiontext//lib/action_text/serialization.rb#10 + def load(content); end +end + +# source://actiontext//lib/action_text/system_test_helper.rb#6 +module ActionText::SystemTestHelper + # Locates a Trix editor and fills it in with the given HTML. + # + # The editor can be found by: + # * its `id` + # * its `placeholder` + # * the text from its `label` element + # * its `aria-label` + # * the `name` of its input + # + # + # Examples: + # + # # + # fill_in_rich_text_area "message_content", with: "Hello world!" + # + # # + # fill_in_rich_text_area "Your message here", with: "Hello world!" + # + # # + # # + # fill_in_rich_text_area "Message content", with: "Hello world!" + # + # # + # fill_in_rich_text_area "Message content", with: "Hello world!" + # + # # + # # + # fill_in_rich_text_area "message[content]", with: "Hello world!" + # + # source://actiontext//lib/action_text/system_test_helper.rb#35 + def fill_in_rich_text_area(locator = T.unsafe(nil), with:); end +end + +module ActionText::TagHelper + def rich_text_area_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end + + class << self + def id; end + def id=(val); end + end +end + +# source://actiontext//lib/action_text/trix_attachment.rb#6 +class ActionText::TrixAttachment + # @return [TrixAttachment] a new instance of TrixAttachment + # + # source://actiontext//lib/action_text/trix_attachment.rb#53 + def initialize(node); end + + # source://actiontext//lib/action_text/trix_attachment.rb#57 + def attributes; end + + # Returns the value of attribute node. + # + # source://actiontext//lib/action_text/trix_attachment.rb#51 + def node; end + + # source://actiontext//lib/action_text/trix_attachment.rb#61 + def to_html; end + + # source://actiontext//lib/action_text/trix_attachment.rb#65 + def to_s; end + + private + + # source://actiontext//lib/action_text/trix_attachment.rb#70 + def attachment_attributes; end + + # source://actiontext//lib/action_text/trix_attachment.rb#74 + def composed_attributes; end + + # source://actiontext//lib/action_text/trix_attachment.rb#82 + def read_json_attribute(name); end + + # source://actiontext//lib/action_text/trix_attachment.rb#78 + def read_json_object_attribute(name); end + + class << self + # source://actiontext//lib/action_text/trix_attachment.rb#21 + def from_attributes(attributes); end + + private + + # source://actiontext//lib/action_text/trix_attachment.rb#35 + def process_attributes(attributes); end + + # source://actiontext//lib/action_text/trix_attachment.rb#39 + def transform_attribute_keys(attributes); end + + # source://actiontext//lib/action_text/trix_attachment.rb#43 + def typecast_attribute_values(attributes); end + end +end + +# source://actiontext//lib/action_text/trix_attachment.rb#11 +ActionText::TrixAttachment::ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://actiontext//lib/action_text/trix_attachment.rb#12 +ActionText::TrixAttachment::ATTRIBUTE_TYPES = T.let(T.unsafe(nil), Hash) + +# source://actiontext//lib/action_text/trix_attachment.rb#10 +ActionText::TrixAttachment::COMPOSED_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://actiontext//lib/action_text/trix_attachment.rb#8 +ActionText::TrixAttachment::SELECTOR = T.let(T.unsafe(nil), String) + +# source://actiontext//lib/action_text/trix_attachment.rb#7 +ActionText::TrixAttachment::TAG_NAME = T.let(T.unsafe(nil), String) + +# source://actiontext//lib/action_text/gem_version.rb#11 +module ActionText::VERSION; end + +# source://actiontext//lib/action_text/gem_version.rb#12 +ActionText::VERSION::MAJOR = T.let(T.unsafe(nil), Integer) + +# source://actiontext//lib/action_text/gem_version.rb#13 +ActionText::VERSION::MINOR = T.let(T.unsafe(nil), Integer) + +# source://actiontext//lib/action_text/gem_version.rb#15 +ActionText::VERSION::PRE = T.let(T.unsafe(nil), T.untyped) + +# source://actiontext//lib/action_text/gem_version.rb#17 +ActionText::VERSION::STRING = T.let(T.unsafe(nil), String) + +# source://actiontext//lib/action_text/gem_version.rb#14 +ActionText::VERSION::TINY = T.let(T.unsafe(nil), Integer) + +module ActionView::Helpers + include ::ActionView::Helpers::SanitizeHelper + include ::ActionView::Helpers::TextHelper + include ::ActionView::Helpers::UrlHelper + include ::ActionView::Helpers::SanitizeHelper + include ::ActionView::Helpers::TextHelper + include ::ActionView::Helpers::FormTagHelper + include ::ActionView::Helpers::FormHelper + include ::ActionView::Helpers::TranslationHelper + + mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods + mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods + + class << self + # source://actionview/7.2.0/lib/action_view/helpers.rb#35 + def eager_load!; end + end +end + +class ActionView::Helpers::FormBuilder + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1717 + def initialize(object_name, object, template, options); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2649 + def button(value = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2474 + def check_box(method, options = T.unsafe(nil), checked_value = T.unsafe(nil), unchecked_value = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#908 + def collection_check_boxes(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#920 + def collection_radio_buttons(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#860 + def collection_select(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2042 + def color_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2070 + def date_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/date_helper.rb#1237 + def date_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2084 + def datetime_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2091 + def datetime_local_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/date_helper.rb#1261 + def datetime_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2119 + def email_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2670 + def emitted_hidden_id?; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 + def field_helpers; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 + def field_helpers=(_arg0); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 + def field_helpers?; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1774 + def field_id(method, *suffixes, namespace: T.unsafe(nil), index: T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1794 + def field_name(method, *methods, multiple: T.unsafe(nil), index: T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2328 + def fields(scope = T.unsafe(nil), model: T.unsafe(nil), **options, &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2290 + def fields_for(record_name, record_object = T.unsafe(nil), fields_options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2557 + def file_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#872 + def grouped_collection_select(method, collection, group_method, group_label_method, option_key_method, option_value_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2518 + def hidden_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1754 + def id; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1694 + def index; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2405 + def label(method, text = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2098 + def month_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1694 + def multipart; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1697 + def multipart=(multipart); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1694 + def multipart?; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2126 + def number_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 + def object; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 + def object=(_arg0); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 + def object_name; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 + def object_name=(_arg0); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 + def options; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 + def options=(_arg0); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2028 + def password_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2063 + def phone_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2496 + def radio_button(method, tag_value, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2133 + def range_field(method, options = T.unsafe(nil)); end + + def rich_text_area(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2049 + def search_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#848 + def select(method, choices = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2589 + def submit(value = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2056 + def telephone_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2035 + def text_area(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2021 + def text_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2077 + def time_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/date_helper.rb#1249 + def time_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#884 + def time_zone_select(method, priority_zones = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1713 + def to_model; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1709 + def to_partial_path; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2112 + def url_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2105 + def week_field(method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#896 + def weekday_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end + + private + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2755 + def convert_to_legacy_options(options); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2737 + def fields_for_nested_model(name, object, fields_options, block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2708 + def fields_for_with_nested_attributes(association_name, association, options, block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2704 + def nested_attributes_association?(association_name); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2750 + def nested_child_index(name); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2675 + def objectify_options(options); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2681 + def submit_default_value; end + + class << self + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1705 + def _to_partial_path; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 + def field_helpers; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 + def field_helpers=(value); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 + def field_helpers?; end + end +end + +module ActionView::Helpers::FormHelper + include ::ActionView::Helpers::UrlHelper + include ::ActionView::Helpers::SanitizeHelper + include ::ActionView::Helpers::TextHelper + include ::ActionView::Helpers::FormTagHelper + + mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods + mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1588 + def _object_for_form_builder(object); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1345 + def check_box(object_name, method, options = T.unsafe(nil), checked_value = T.unsafe(nil), unchecked_value = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1375 + def color_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1439 + def date_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1512 + def datetime_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1512 + def datetime_local_field(object_name, method, options = T.unsafe(nil)); end + + def default_form_builder; end + def default_form_builder=(_arg0); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1566 + def email_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1079 + def fields(scope = T.unsafe(nil), model: T.unsafe(nil), **options, &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1028 + def fields_for(record_name, record_object = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1247 + def file_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#435 + def form_for(record, options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#755 + def form_with(model: T.unsafe(nil), scope: T.unsafe(nil), url: T.unsafe(nil), format: T.unsafe(nil), **options, &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#481 + def form_with_generates_ids; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#481 + def form_with_generates_ids=(val); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#479 + def form_with_generates_remote_forms; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#479 + def form_with_generates_remote_forms=(val); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1214 + def hidden_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1151 + def label(object_name, method, content_or_options = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1531 + def month_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#483 + def multiple_file_field_include_hidden; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#483 + def multiple_file_field_include_hidden=(val); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1575 + def number_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1196 + def password_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1407 + def phone_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1367 + def radio_button(object_name, method, tag_value, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1584 + def range_field(object_name, method, options = T.unsafe(nil)); end + + def rich_text_area(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1398 + def search_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1407 + def telephone_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1277 + def text_area(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1175 + def text_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1477 + def time_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1557 + def url_field(object_name, method, options = T.unsafe(nil)); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1548 + def week_field(object_name, method, options = T.unsafe(nil)); end + + private + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#465 + def apply_form_for_options!(object, options); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1622 + def default_form_builder_class; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1593 + def html_options_for_form_with(url_for_options = T.unsafe(nil), model = T.unsafe(nil), html: T.unsafe(nil), local: T.unsafe(nil), skip_enforcing_utf8: T.unsafe(nil), **options); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1608 + def instantiate_builder(record_name, record_object, options); end + + class << self + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#481 + def form_with_generates_ids; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#481 + def form_with_generates_ids=(val); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#479 + def form_with_generates_remote_forms; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#479 + def form_with_generates_remote_forms=(val); end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#483 + def multiple_file_field_include_hidden; end + + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#483 + def multiple_file_field_include_hidden=(val); end + end +end + +module ActionView::Helpers::Tags; end + +class ActionView::Helpers::Tags::ActionText < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::Placeholderable + + def dom_id(*_arg0, **_arg1, &_arg2); end + def render; end +end diff --git a/sorbet/rbi/gems/actionview@7.0.5.rbi b/sorbet/rbi/gems/actionview@7.2.0.rbi similarity index 80% rename from sorbet/rbi/gems/actionview@7.0.5.rbi rename to sorbet/rbi/gems/actionview@7.2.0.rbi index d75547a8f..4d51e25b2 100644 --- a/sorbet/rbi/gems/actionview@7.0.5.rbi +++ b/sorbet/rbi/gems/actionview@7.2.0.rbi @@ -4,583 +4,597 @@ # This is an autogenerated file for types exported from the `actionview` gem. # Please instead update this file by running `bin/tapioca gem actionview`. + class ActionController::Base < ::ActionController::Metal include ::ActionDispatch::Routing::PolymorphicRoutes include ::ActionController::Head include ::AbstractController::Caching::ConfigMethods include ::ActionController::BasicImplicitRender + include ::Devise::Controllers::SignInOut + include ::Devise::Controllers::StoreLocation + extend ::AbstractController::Helpers::Resolution - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://actionview//lib/action_view/layouts.rb#212 + def _layout_conditions; end + + # source://actionview//lib/action_view/layouts.rb#212 + def _layout_conditions?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _process_action_callbacks; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_process_action_callbacks(&block); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#36 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#38 def alert; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_asset_host_protocol; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_asset_host_protocol=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_protect_from_forgery; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest; end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest?; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#10 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#12 def flash(*_arg0, **_arg1, &_arg2); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to=(_arg0); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#36 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#38 def notice; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def request_forgery_protection_token; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def request_forgery_protection_token=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder=(_arg0); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def urlsafe_csrf_tokens; end - private # source://actionview//lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end - # source://actionpack/7.0.5/lib/action_controller/base.rb#266 + def _layout_from_proc; end + + # source://actionpack/7.2.0/lib/action_controller/base.rb#324 def _protected_ivars; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/action_controller/form_builder.rb#31 + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 def _default_form_builder; end - # source://actionpack/7.0.5/lib/action_controller/form_builder.rb#31 + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 def _default_form_builder=(value); end - # source://actionpack/7.0.5/lib/action_controller/form_builder.rb#31 + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 def _default_form_builder?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#8 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 def _flash_types; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#8 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 def _flash_types=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#8 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 def _flash_types?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#15 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#17 def _helpers; end - # source://actionview//lib/action_view/layouts.rb#209 + # source://actionview//lib/action_view/layouts.rb#211 def _layout; end - # source://actionview//lib/action_view/layouts.rb#209 + # source://actionview//lib/action_view/layouts.rb#211 def _layout=(value); end - # source://actionview//lib/action_view/layouts.rb#209 + # source://actionview//lib/action_view/layouts.rb#211 def _layout?; end - # source://actionview//lib/action_view/layouts.rb#210 + # source://actionview//lib/action_view/layouts.rb#212 def _layout_conditions; end - # source://actionview//lib/action_view/layouts.rb#210 + # source://actionview//lib/action_view/layouts.rb#212 def _layout_conditions=(value); end - # source://actionview//lib/action_view/layouts.rb#210 + # source://actionview//lib/action_view/layouts.rb#212 def _layout_conditions?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _process_action_callbacks=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_asset_host_protocol; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_asset_host_protocol=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_protect_from_forgery; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest; end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest?; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def request_forgery_protection_token; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def request_forgery_protection_token=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder; end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder=(value); end - # source://responders/3.1.0/lib/action_controller/respond_with.rb#11 + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 def responder?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def urlsafe_csrf_tokens; end - - # source://actionpack/7.0.5/lib/action_controller/metal/request_forgery_protection.rb#97 - def urlsafe_csrf_tokens=(urlsafe_csrf_tokens); end - - # source://actionpack/7.0.5/lib/action_controller/base.rb#198 + # source://actionpack/7.2.0/lib/action_controller/base.rb#222 def without_modules(*modules); end end end -# source://actionpack/7.0.5/lib/action_controller/base.rb#206 -ActionController::Base::MODULES = T.let(T.unsafe(nil), Array) - -# source://actionpack/7.0.5/lib/action_controller/base.rb#261 -ActionController::Base::PROTECTED_IVARS = T.let(T.unsafe(nil), Array) - +# :include: ../README.rdoc +# # source://actionview//lib/action_view/gem_version.rb#3 module ActionView extend ::ActiveSupport::Autoload class << self - # source://actionview//lib/action_view.rb#90 + # source://actionview//lib/action_view/deprecator.rb#4 + def deprecator; end + + # source://actionview//lib/action_view.rb#93 def eager_load!; end - # Returns the currently loaded version of Action View as a Gem::Version. + # Returns the currently loaded version of Action View as a +Gem::Version+. # # source://actionview//lib/action_view/gem_version.rb#5 def gem_version; end - # Returns the currently loaded version of Action View as a Gem::Version. + # Returns the currently loaded version of Action View as a +Gem::Version+. # # source://actionview//lib/action_view/version.rb#7 def version; end @@ -752,10 +766,10 @@ ActionView::AbstractRenderer::RenderedTemplate::EMPTY_SPACER = T.let(T.unsafe(ni # = Action View Errors # -# source://actionview//lib/action_view/template/error.rb#7 +# source://actionview//lib/action_view/template/error.rb#8 class ActionView::ActionViewError < ::StandardError; end -# = Action View Base +# = Action View \Base # # Action View templates can be written in several ways. # If the template file has a .erb extension, then it uses the erubi[https://rubygems.org/gems/erubi] @@ -789,9 +803,9 @@ class ActionView::ActionViewError < ::StandardError; end # Using sub templates allows you to sidestep tedious replication and extract common display structures in shared templates. The # classic example is the use of a header and footer (even though the Action Pack-way would be to use Layouts): # -# <%= render "shared/header" %> +# <%= render "application/header" %> # Something really specific and terrific -# <%= render "shared/footer" %> +# <%= render "application/footer" %> # # As you see, we use the output embeddings for the render methods. The render call itself will just return a string holding the # result of the rendering. The output embedding writes it to the current template. @@ -800,7 +814,7 @@ class ActionView::ActionViewError < ::StandardError; end # variables defined using the regular embedding tags. Like this: # # <% @page_title = "A Wonderful Hello" %> -# <%= render "shared/header" %> +# <%= render "application/header" %> # # Now the header can pick up on the @page_title variable and use it for outputting a title tag: # @@ -810,9 +824,9 @@ class ActionView::ActionViewError < ::StandardError; end # # You can pass local variables to sub templates by using a hash with the variable names as keys and the objects as values: # -# <%= render "shared/header", { headline: "Welcome", person: person } %> +# <%= render "application/header", { headline: "Welcome", person: person } %> # -# These can now be accessed in shared/header with: +# These can now be accessed in application/header with: # # Headline: <%= headline %> # First name: <%= person.first_name %> @@ -825,10 +839,27 @@ class ActionView::ActionViewError < ::StandardError; end # This is useful in cases where you aren't sure if the local variable has been assigned. Alternatively, you could also use # defined? headline to first check if the variable has been assigned before using it. # +# By default, templates will accept any locals as keyword arguments. To restrict what locals a template accepts, add a locals: magic comment: +# +# <%# locals: (headline:) %> +# +# Headline: <%= headline %> +# +# In cases where the local variables are optional, declare the keyword argument with a default value: +# +# <%# locals: (headline: nil) %> +# +# <% unless headline.nil? %> +# Headline: <%= headline %> +# <% end %> +# +# Read more about strict locals in {Action View Overview}[https://guides.rubyonrails.org/action_view_overview.html#strict-locals] +# in the guides. +# # === Template caching # -# By default, Rails will compile each template to a method in order to render it. When you alter a template, -# Rails will check the file's modification time and recompile it in development mode. +# By default, \Rails will compile each template to a method in order to render it. When you alter a template, +# \Rails will check the file's modification time and recompile it in development mode. # # == Builder # @@ -881,25 +912,27 @@ class ActionView::ActionViewError < ::StandardError; end # end # end # -# For more information on Builder please consult the {source -# code}[https://github.com/jimweirich/builder]. +# For more information on Builder please consult the {source code}[https://github.com/rails/builder]. # -# source://actionview//lib/action_view/base.rb#141 +# source://actionview//lib/action_view/base.rb#157 class ActionView::Base include ::ActionView::Context include ::ERB::Escape include ::ERB::Util + include ::ActiveSupport::CoreExt::ERBUtil + include ::ActiveSupport::CoreExt::ERBUtilPrivate include ::ActiveSupport::Benchmarkable include ::ActionView::Helpers::ActiveModelHelper include ::ActionView::Helpers::AssetUrlHelper include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper include ::ActionView::Helpers::TagHelper - include ::ActionView::Helpers::UrlHelper - include ::ActionView::Helpers::SanitizeHelper include ::ActionView::Helpers::AssetTagHelper include ::ActionView::Helpers::AtomFeedHelper include ::ActionView::Helpers::CacheHelper + include ::ActionView::Helpers::ContentExfiltrationPreventionHelper + include ::ActionView::Helpers::UrlHelper + include ::ActionView::Helpers::SanitizeHelper include ::ActionView::Helpers::ControllerHelper include ::ActionView::Helpers::CspHelper include ::ActionView::Helpers::CsrfHelper @@ -917,6 +950,10 @@ class ActionView::Base include ::ActionView::Helpers::RenderingHelper include ::ActionView::Helpers include ::SimpleForm::ActionViewExtensions::FormHelper + include ::ActionCable::Helpers::ActionCableHelper + include ::Devise::Controllers::UrlHelpers + include ::WillPaginate::I18n + include ::WillPaginate::ViewHelpers extend ::ActionView::Helpers::UrlHelper::ClassMethods extend ::ActionView::Helpers::SanitizeHelper::ClassMethods @@ -924,51 +961,51 @@ class ActionView::Base # # @return [Base] a new instance of Base # - # source://actionview//lib/action_view/base.rb#227 + # source://actionview//lib/action_view/base.rb#244 def initialize(lookup_context, assigns, controller); end - # source://actionview//lib/action_view/base.rb#165 + # source://actionview//lib/action_view/base.rb#181 def _routes; end - # source://actionview//lib/action_view/base.rb#165 + # source://actionview//lib/action_view/base.rb#181 def _routes=(_arg0); end - # source://actionview//lib/action_view/base.rb#165 + # source://actionview//lib/action_view/base.rb#181 def _routes?; end - # source://actionview//lib/action_view/base.rb#240 - def _run(method, template, locals, buffer, add_to_stack: T.unsafe(nil), &block); end + # source://actionview//lib/action_view/base.rb#261 + def _run(method, template, locals, buffer, add_to_stack: T.unsafe(nil), has_strict_locals: T.unsafe(nil), &block); end - # source://actionview//lib/action_view/base.rb#163 + # source://actionview//lib/action_view/base.rb#179 def annotate_rendered_view_with_filenames; end - # source://actionview//lib/action_view/base.rb#163 + # source://actionview//lib/action_view/base.rb#179 def annotate_rendered_view_with_filenames=(val); end - # source://actionview//lib/action_view/base.rb#207 + # source://actionview//lib/action_view/base.rb#223 def assign(new_assigns); end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def assigns; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def assigns=(_arg0); end - # source://actionview//lib/action_view/base.rb#160 + # source://actionview//lib/action_view/base.rb#176 def automatically_disable_submit_tag; end - # source://actionview//lib/action_view/base.rb#160 + # source://actionview//lib/action_view/base.rb#176 def automatically_disable_submit_tag=(val); end # @raise [NotImplementedError] # - # source://actionview//lib/action_view/base.rb#249 + # source://actionview//lib/action_view/base.rb#287 def compiled_method_container; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def config; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attr_internal.rb#33 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attr_internal.rb#44 def config=(_arg0); end # source://actionview//lib/action_view/helpers/translation_helper.rb#18 @@ -977,104 +1014,104 @@ class ActionView::Base # source://actionview//lib/action_view/helpers/translation_helper.rb#18 def debug_missing_translation=(val); end - # source://actionview//lib/action_view/base.rb#157 + # source://actionview//lib/action_view/base.rb#173 def default_formats; end - # source://actionview//lib/action_view/base.rb#157 + # source://actionview//lib/action_view/base.rb#173 def default_formats=(val); end - # source://actionview//lib/action_view/base.rb#145 + # source://actionview//lib/action_view/base.rb#161 def field_error_proc; end - # source://actionview//lib/action_view/base.rb#145 + # source://actionview//lib/action_view/base.rb#161 def field_error_proc=(val); end - # source://actionview//lib/action_view/base.rb#205 + # source://actionview//lib/action_view/base.rb#221 def formats(*_arg0, **_arg1, &_arg2); end - # source://actionview//lib/action_view/base.rb#205 + # source://actionview//lib/action_view/base.rb#221 def formats=(arg); end - # source://actionview//lib/action_view/base.rb#257 + # source://actionview//lib/action_view/base.rb#295 def in_rendering_context(options); end - # source://actionview//lib/action_view/base.rb#205 + # source://actionview//lib/action_view/base.rb#221 def locale(*_arg0, **_arg1, &_arg2); end - # source://actionview//lib/action_view/base.rb#205 + # source://actionview//lib/action_view/base.rb#221 def locale=(arg); end - # source://actionview//lib/action_view/base.rb#166 + # source://actionview//lib/action_view/base.rb#182 def logger; end - # source://actionview//lib/action_view/base.rb#166 + # source://actionview//lib/action_view/base.rb#182 def logger=(_arg0); end - # source://actionview//lib/action_view/base.rb#166 + # source://actionview//lib/action_view/base.rb#182 def logger?; end # Returns the value of attribute lookup_context. # - # source://actionview//lib/action_view/base.rb#202 + # source://actionview//lib/action_view/base.rb#218 def lookup_context; end - # source://actionview//lib/action_view/base.rb#154 + # source://actionview//lib/action_view/base.rb#170 def prefix_partial_path_with_controller_namespace; end - # source://actionview//lib/action_view/base.rb#154 + # source://actionview//lib/action_view/base.rb#170 def prefix_partial_path_with_controller_namespace=(_arg0); end - # source://actionview//lib/action_view/base.rb#154 + # source://actionview//lib/action_view/base.rb#170 def prefix_partial_path_with_controller_namespace?; end - # source://actionview//lib/action_view/base.rb#149 + # source://actionview//lib/action_view/base.rb#165 def streaming_completion_on_exception; end - # source://actionview//lib/action_view/base.rb#149 + # source://actionview//lib/action_view/base.rb#165 def streaming_completion_on_exception=(val); end - # source://actionview//lib/action_view/base.rb#205 + # source://actionview//lib/action_view/base.rb#221 def view_paths(*_arg0, **_arg1, &_arg2); end - # source://actionview//lib/action_view/base.rb#205 + # source://actionview//lib/action_view/base.rb#221 def view_paths=(arg); end # Returns the value of attribute view_renderer. # - # source://actionview//lib/action_view/base.rb#202 + # source://actionview//lib/action_view/base.rb#218 def view_renderer; end class << self - # source://actionview//lib/action_view/base.rb#165 + # source://actionview//lib/action_view/base.rb#181 def _routes; end - # source://actionview//lib/action_view/base.rb#165 + # source://actionview//lib/action_view/base.rb#181 def _routes=(value); end - # source://actionview//lib/action_view/base.rb#165 + # source://actionview//lib/action_view/base.rb#181 def _routes?; end - # source://actionview//lib/action_view/base.rb#163 + # source://actionview//lib/action_view/base.rb#179 def annotate_rendered_view_with_filenames; end - # source://actionview//lib/action_view/base.rb#163 + # source://actionview//lib/action_view/base.rb#179 def annotate_rendered_view_with_filenames=(val); end - # source://actionview//lib/action_view/base.rb#160 + # source://actionview//lib/action_view/base.rb#176 def automatically_disable_submit_tag; end - # source://actionview//lib/action_view/base.rb#160 + # source://actionview//lib/action_view/base.rb#176 def automatically_disable_submit_tag=(val); end - # source://actionview//lib/action_view/base.rb#171 + # source://actionview//lib/action_view/base.rb#187 def cache_template_loading; end - # source://actionview//lib/action_view/base.rb#175 + # source://actionview//lib/action_view/base.rb#191 def cache_template_loading=(value); end # @return [Boolean] # - # source://actionview//lib/action_view/base.rb#197 + # source://actionview//lib/action_view/base.rb#213 def changed?(other); end # source://actionview//lib/action_view/helpers/translation_helper.rb#18 @@ -1083,111 +1120,106 @@ class ActionView::Base # source://actionview//lib/action_view/helpers/translation_helper.rb#18 def debug_missing_translation=(val); end - # source://actionview//lib/action_view/helpers/form_helper.rb#2729 + # source://actionview//lib/action_view/helpers/form_helper.rb#2764 def default_form_builder; end - # source://actionview//lib/action_view/helpers/form_helper.rb#2729 + # source://actionview//lib/action_view/helpers/form_helper.rb#2764 def default_form_builder=(val); end - # source://actionview//lib/action_view/base.rb#157 + # source://actionview//lib/action_view/base.rb#173 def default_formats; end - # source://actionview//lib/action_view/base.rb#157 + # source://actionview//lib/action_view/base.rb#173 def default_formats=(val); end # :stopdoc: # - # source://actionview//lib/action_view/base.rb#213 + # source://actionview//lib/action_view/base.rb#230 def empty; end - # source://actionview//lib/action_view/base.rb#169 + # source://actionview//lib/action_view/base.rb#185 def erb_trim_mode=(arg); end - # source://actionview//lib/action_view/base.rb#145 + # source://actionview//lib/action_view/base.rb#161 def field_error_proc; end - # source://actionview//lib/action_view/base.rb#145 + # source://actionview//lib/action_view/base.rb#161 def field_error_proc=(val); end - # source://actionview//lib/action_view/base.rb#166 + # source://actionview//lib/action_view/base.rb#182 def logger; end - # source://actionview//lib/action_view/base.rb#166 + # source://actionview//lib/action_view/base.rb#182 def logger=(value); end - # source://actionview//lib/action_view/base.rb#166 + # source://actionview//lib/action_view/base.rb#182 def logger?; end - # source://actionview//lib/action_view/base.rb#154 + # source://actionview//lib/action_view/base.rb#170 def prefix_partial_path_with_controller_namespace; end - # source://actionview//lib/action_view/base.rb#154 + # source://actionview//lib/action_view/base.rb#170 def prefix_partial_path_with_controller_namespace=(value); end - # source://actionview//lib/action_view/base.rb#154 + # source://actionview//lib/action_view/base.rb#170 def prefix_partial_path_with_controller_namespace?; end - # source://actionview//lib/action_view/base.rb#149 + # source://actionview//lib/action_view/base.rb#165 def streaming_completion_on_exception; end - # source://actionview//lib/action_view/base.rb#149 + # source://actionview//lib/action_view/base.rb#165 def streaming_completion_on_exception=(val); end - # source://actionview//lib/action_view/base.rb#221 + # source://actionview//lib/action_view/base.rb#238 def with_context(context, assigns = T.unsafe(nil), controller = T.unsafe(nil)); end - # source://actionview//lib/action_view/base.rb#183 + # source://actionview//lib/action_view/base.rb#199 def with_empty_template_cache; end - # source://actionview//lib/action_view/base.rb#217 + # source://actionview//lib/action_view/base.rb#234 def with_view_paths(view_paths, assigns = T.unsafe(nil), controller = T.unsafe(nil)); end # @return [Boolean] # - # source://actionview//lib/action_view/base.rb#179 + # source://actionview//lib/action_view/base.rb#195 def xss_safe?; end end end # source://actionview//lib/action_view/cache_expiry.rb#4 -class ActionView::CacheExpiry; end +module ActionView::CacheExpiry; end # source://actionview//lib/action_view/cache_expiry.rb#5 -class ActionView::CacheExpiry::Executor - # @return [Executor] a new instance of Executor +class ActionView::CacheExpiry::ViewReloader + # @return [ViewReloader] a new instance of ViewReloader # # source://actionview//lib/action_view/cache_expiry.rb#6 - def initialize(watcher:); end - - # source://actionview//lib/action_view/cache_expiry.rb#20 - def complete(_); end - - # source://actionview//lib/action_view/cache_expiry.rb#13 - def run; end - - private + def initialize(watcher:, &block); end - # source://actionview//lib/action_view/cache_expiry.rb#25 - def clear_cache; end -end + # source://actionview//lib/action_view/cache_expiry.rb#21 + def execute; end -# source://actionview//lib/action_view/cache_expiry.rb#32 -class ActionView::CacheExpiry::ViewModificationWatcher - # @return [ViewModificationWatcher] a new instance of ViewModificationWatcher + # @return [Boolean] # - # source://actionview//lib/action_view/cache_expiry.rb#33 - def initialize(watcher:, &block); end - - # source://actionview//lib/action_view/cache_expiry.rb#41 - def execute_if_updated; end + # source://actionview//lib/action_view/cache_expiry.rb#16 + def updated?; end private - # source://actionview//lib/action_view/cache_expiry.rb#61 + # source://actionview//lib/action_view/cache_expiry.rb#64 def all_view_paths; end - # source://actionview//lib/action_view/cache_expiry.rb#57 + # source://actionview//lib/action_view/cache_expiry.rb#37 + def build_watcher; end + + # source://actionview//lib/action_view/cache_expiry.rb#60 def dirs_to_watch; end + + # source://actionview//lib/action_view/cache_expiry.rb#55 + def rebuild_watcher; end + + # source://actionview//lib/action_view/cache_expiry.rb#33 + def reload!; end end # source://actionview//lib/action_view/renderer/partial_renderer/collection_caching.rb#6 @@ -1207,7 +1239,7 @@ module ActionView::CollectionCaching # source://actionview//lib/action_view/renderer/partial_renderer/collection_caching.rb#58 def collection_by_cache_keys(view, template, collection); end - # source://actionview//lib/action_view/renderer/partial_renderer/collection_caching.rb#70 + # source://actionview//lib/action_view/renderer/partial_renderer/collection_caching.rb#71 def expanded_cache_key(key, view, template, digest_path); end # `order_by` is an enumerable object containing keys of the cache, @@ -1226,7 +1258,7 @@ module ActionView::CollectionCaching # If the partial is not already cached it will also be # written back to the underlying cache store. # - # source://actionview//lib/action_view/renderer/partial_renderer/collection_caching.rb#90 + # source://actionview//lib/action_view/renderer/partial_renderer/collection_caching.rb#91 def fetch_or_cache_partial(cached_partials, template, order_by:); end # @return [Boolean] @@ -1239,21 +1271,21 @@ end class ActionView::CollectionRenderer < ::ActionView::PartialRenderer include ::ActionView::AbstractRenderer::ObjectRendering - # source://actionview//lib/action_view/renderer/collection_renderer.rb#122 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#130 def render_collection_derive_partial(collection, context, block); end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#104 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#112 def render_collection_with_partial(collection, partial, context, block); end private - # source://actionview//lib/action_view/renderer/collection_renderer.rb#174 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#182 def collection_with_template(view, template, layout, collection); end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#145 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#153 def render_collection(collection, view, path, template, layout, block); end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#140 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#148 def retrieve_variable(path); end end @@ -1272,46 +1304,52 @@ class ActionView::CollectionRenderer::CollectionIterator # source://actionview//lib/action_view/renderer/collection_renderer.rb#51 def length; end + # source://actionview//lib/action_view/renderer/collection_renderer.rb#55 + def preload!; end + # source://actionview//lib/action_view/renderer/collection_renderer.rb#47 def size; end end -# source://actionview//lib/action_view/renderer/collection_renderer.rb#92 +# source://actionview//lib/action_view/renderer/collection_renderer.rb#100 class ActionView::CollectionRenderer::MixedCollectionIterator < ::ActionView::CollectionRenderer::CollectionIterator # @return [MixedCollectionIterator] a new instance of MixedCollectionIterator # - # source://actionview//lib/action_view/renderer/collection_renderer.rb#93 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#101 def initialize(collection, paths); end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#98 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#106 def each_with_info; end end -# source://actionview//lib/action_view/renderer/collection_renderer.rb#74 +# source://actionview//lib/action_view/renderer/collection_renderer.rb#78 class ActionView::CollectionRenderer::PreloadCollectionIterator < ::ActionView::CollectionRenderer::SameCollectionIterator # @return [PreloadCollectionIterator] a new instance of PreloadCollectionIterator # - # source://actionview//lib/action_view/renderer/collection_renderer.rb#75 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#79 def initialize(collection, path, variables, relation); end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#85 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#89 def each_with_info; end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#81 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#85 def from_collection(collection); end + + # source://actionview//lib/action_view/renderer/collection_renderer.rb#95 + def preload!; end end -# source://actionview//lib/action_view/renderer/collection_renderer.rb#56 +# source://actionview//lib/action_view/renderer/collection_renderer.rb#60 class ActionView::CollectionRenderer::SameCollectionIterator < ::ActionView::CollectionRenderer::CollectionIterator # @return [SameCollectionIterator] a new instance of SameCollectionIterator # - # source://actionview//lib/action_view/renderer/collection_renderer.rb#57 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#61 def initialize(collection, path, variables); end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#67 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#71 def each_with_info; end - # source://actionview//lib/action_view/renderer/collection_renderer.rb#63 + # source://actionview//lib/action_view/renderer/collection_renderer.rb#67 def from_collection(collection); end end @@ -1485,55 +1523,55 @@ ActionView::DependencyTracker::ERBTracker::STRING = T.let(T.unsafe(nil), Regexp) # source://actionview//lib/action_view/dependency_tracker/erb_tracker.rb#16 ActionView::DependencyTracker::ERBTracker::VARIABLE_OR_METHOD_CHAIN = T.let(T.unsafe(nil), Regexp) -# source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#5 -class ActionView::DependencyTracker::RipperTracker - # @return [RipperTracker] a new instance of RipperTracker +# source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#5 +class ActionView::DependencyTracker::RubyTracker + # @return [RubyTracker] a new instance of RubyTracker # - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#20 - def initialize(name, template, view_paths = T.unsafe(nil)); end + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#20 + def initialize(name, template, view_paths = T.unsafe(nil), parser_class: T.unsafe(nil)); end - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#12 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#12 def dependencies; end private - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#38 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#39 def explicit_dependencies; end # Returns the value of attribute name. # - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#25 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#26 def name; end - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#27 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#28 def render_dependencies; end - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#46 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#47 def resolve_directories(wildcard_dependencies); end # Returns the value of attribute template. # - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#25 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#26 def template; end # Returns the value of attribute view_paths. # - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#25 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#26 def view_paths; end class << self - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#8 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#8 def call(name, template, view_paths = T.unsafe(nil)); end # @return [Boolean] # - # source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#16 + # source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#16 def supports_view_paths?; end end end -# source://actionview//lib/action_view/dependency_tracker/ripper_tracker.rb#6 -ActionView::DependencyTracker::RipperTracker::EXPLICIT_DEPENDENCY = T.let(T.unsafe(nil), Regexp) +# source://actionview//lib/action_view/dependency_tracker/ruby_tracker.rb#6 +ActionView::DependencyTracker::RubyTracker::EXPLICIT_DEPENDENCY = T.let(T.unsafe(nil), Regexp) # source://actionview//lib/action_view/digestor.rb#6 class ActionView::Digestor @@ -1542,7 +1580,7 @@ class ActionView::Digestor # # * name - Template name # * format - Template format - # * finder - An instance of ActionView::LookupContext + # * +finder+ - An instance of ActionView::LookupContext # * dependencies - An array of dependent views # # source://actionview//lib/action_view/digestor.rb#16 @@ -1631,76 +1669,79 @@ end # source://actionview//lib/action_view/digestor.rb#115 class ActionView::Digestor::Partial < ::ActionView::Digestor::Node; end -# source://actionview//lib/action_view.rb#33 +# source://actionview//lib/action_view.rb#35 ActionView::ENCODING_FLAG = T.let(T.unsafe(nil), String) -# source://actionview//lib/action_view/template/error.rb#10 +# source://actionview//lib/action_view/template/error.rb#11 class ActionView::EncodingError < ::StandardError; end # A resolver that loads files from the filesystem. # -# source://actionview//lib/action_view/template/resolver.rb#89 +# source://actionview//lib/action_view/template/resolver.rb#91 class ActionView::FileSystemResolver < ::ActionView::Resolver # @raise [ArgumentError] # @return [FileSystemResolver] a new instance of FileSystemResolver # - # source://actionview//lib/action_view/template/resolver.rb#92 + # source://actionview//lib/action_view/template/resolver.rb#94 def initialize(path); end # @return [Boolean] # - # source://actionview//lib/action_view/template/resolver.rb#111 + # source://actionview//lib/action_view/template/resolver.rb#113 def ==(resolver); end - # source://actionview//lib/action_view/template/resolver.rb#116 + # source://actionview//lib/action_view/template/resolver.rb#118 def all_template_paths; end - # source://actionview//lib/action_view/template/resolver.rb#100 + # source://actionview//lib/action_view/template/resolver.rb#127 + def built_templates; end + + # source://actionview//lib/action_view/template/resolver.rb#102 def clear_cache; end # @return [Boolean] # - # source://actionview//lib/action_view/template/resolver.rb#111 + # source://actionview//lib/action_view/template/resolver.rb#113 def eql?(resolver); end # Returns the value of attribute path. # - # source://actionview//lib/action_view/template/resolver.rb#90 + # source://actionview//lib/action_view/template/resolver.rb#92 def path; end - # source://actionview//lib/action_view/template/resolver.rb#106 + # source://actionview//lib/action_view/template/resolver.rb#108 def to_path; end - # source://actionview//lib/action_view/template/resolver.rb#106 + # source://actionview//lib/action_view/template/resolver.rb#108 def to_s; end private - # source://actionview//lib/action_view/template/resolver.rb#126 + # source://actionview//lib/action_view/template/resolver.rb#132 def _find_all(name, prefix, partial, details, key, locals); end - # source://actionview//lib/action_view/template/resolver.rb#145 + # source://actionview//lib/action_view/template/resolver.rb#151 def build_unbound_template(template); end - # source://actionview//lib/action_view/template/resolver.rb#203 + # source://actionview//lib/action_view/template/resolver.rb#209 def escape_entry(entry); end - # source://actionview//lib/action_view/template/resolver.rb#175 + # source://actionview//lib/action_view/template/resolver.rb#181 def filter_and_sort_by_details(templates, requested_details); end - # source://actionview//lib/action_view/template/resolver.rb#141 + # source://actionview//lib/action_view/template/resolver.rb#147 def source_for_template(template); end # Safe glob within @path # - # source://actionview//lib/action_view/template/resolver.rb#190 + # source://actionview//lib/action_view/template/resolver.rb#196 def template_glob(glob); end - # source://actionview//lib/action_view/template/resolver.rb#158 + # source://actionview//lib/action_view/template/resolver.rb#164 def unbound_templates_from_path(path); end end -# source://actionview//lib/action_view/helpers/capture_helper.rb#7 +# source://actionview//lib/action_view/helpers/capture_helper.rb#6 module ActionView::Helpers include ::ActiveSupport::Benchmarkable include ::ActionView::Helpers::ActiveModelHelper @@ -1712,6 +1753,7 @@ module ActionView::Helpers include ::ActionView::Helpers::AssetTagHelper include ::ActionView::Helpers::AtomFeedHelper include ::ActionView::Helpers::CacheHelper + include ::ActionView::Helpers::ContentExfiltrationPreventionHelper include ::ActionView::Helpers::ControllerHelper include ::ActionView::Helpers::CspHelper include ::ActionView::Helpers::CsrfHelper @@ -1735,14 +1777,16 @@ module ActionView::Helpers mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods class << self - # source://actionview//lib/action_view/helpers.rb#34 + # source://actionview//lib/action_view/helpers.rb#35 def eager_load!; end end end -# source://actionview//lib/action_view/helpers/active_model_helper.rb#9 +# source://actionview//lib/action_view/helpers/active_model_helper.rb#8 module ActionView::Helpers::ActiveModelHelper; end +# = Active \Model Instance Tag \Helpers +# # source://actionview//lib/action_view/helpers/active_model_helper.rb#12 module ActionView::Helpers::ActiveModelInstanceTag # source://actionview//lib/action_view/helpers/active_model_helper.rb#20 @@ -1778,6 +1822,8 @@ module ActionView::Helpers::ActiveModelInstanceTag def tag_generate_errors?(options); end end +# = Action View Asset Tag \Helpers +# # This module provides methods for generating HTML that links views to assets such # as images, JavaScripts, stylesheets, and feeds. These methods do not verify # the assets exist before linking to them: @@ -1787,24 +1833,24 @@ end # stylesheet_link_tag("application") # # => # -# source://actionview//lib/action_view/helpers/asset_tag_helper.rb#20 +# source://actionview//lib/action_view/helpers/asset_tag_helper.rb#21 module ActionView::Helpers::AssetTagHelper include ::ActionView::Helpers::AssetUrlHelper include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper include ::ActionView::Helpers::TagHelper - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#28 def apply_stylesheet_media_default; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#28 def apply_stylesheet_media_default=(val); end # Returns an HTML audio tag for the +sources+. If +sources+ is a string, # a single audio tag will be returned. If +sources+ is an array, an audio # tag with nested source tags for each source will be returned. The - # +sources+ can be full paths or files that exist in your public audios - # directory. + # +sources+ can be full paths, files that exist in your public audios + # directory, or Active Storage attachments. # # When the last parameter is a hash you can add HTML attributes using that # parameter. @@ -1818,7 +1864,12 @@ module ActionView::Helpers::AssetTagHelper # audio_tag("sound.wav", "sound.mid") # # => # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#486 + # Active Storage blobs (audios that are uploaded by the users of your app): + # + # audio_tag(user.name_pronunciation_audio) + # # => + # + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#593 def audio_tag(*sources); end # Returns a link tag that browsers and feed readers can use to auto-detect @@ -1849,7 +1900,7 @@ module ActionView::Helpers::AssetTagHelper # auto_discovery_link_tag(:rss, "http://www.example.com/feed.rss", {title: "Example RSS"}) # # => # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#235 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#271 def auto_discovery_link_tag(type = T.unsafe(nil), url_options = T.unsafe(nil), tag_options = T.unsafe(nil)); end # Returns a link tag for a favicon managed by the asset pipeline. @@ -1880,19 +1931,19 @@ module ActionView::Helpers::AssetTagHelper # favicon_link_tag 'mb-icon.png', rel: 'apple-touch-icon', type: 'image/png' # # => # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#276 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#312 def favicon_link_tag(source = T.unsafe(nil), options = T.unsafe(nil)); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 def image_decoding; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 def image_decoding=(val); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#24 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 def image_loading; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#24 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 def image_loading=(val); end # Returns an HTML image tag for the +source+. The +source+ can be a full @@ -1903,8 +1954,8 @@ module ActionView::Helpers::AssetTagHelper # You can add HTML attributes using the +options+. The +options+ supports # additional keys for convenience and conformance: # - # * :size - Supplied as "{Width}x{Height}" or "{Number}", so "30x45" becomes - # width="30" and height="45", and "50" becomes width="50" and height="50". + # * :size - Supplied as "#{width}x#{height}" or "#{number}", so "30x45" becomes + # width="30" height="45", and "50" becomes width="50" height="50". # :size will be ignored if the value is not in the correct format. # * :srcset - If supplied as a hash or array of [source, descriptor] # pairs, each image path will be expanded before the list is formatted as a string. @@ -1941,7 +1992,7 @@ module ActionView::Helpers::AssetTagHelper # image_tag(user.avatar.variant(resize_to_limit: [100, 100]), size: '100') # # => # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#394 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#430 def image_tag(source, options = T.unsafe(nil)); end # Returns an HTML script tag for each of the +sources+ provided. @@ -1959,13 +2010,14 @@ module ActionView::Helpers::AssetTagHelper # When the Asset Pipeline is enabled, you can pass the name of your manifest as # source, and include other JavaScript or CoffeeScript files inside the manifest. # - # If the server supports Early Hints, header links for these assets will be - # automatically pushed. + # If the server supports HTTP Early Hints, and the +defer+ option is not + # enabled, \Rails will push a 103 Early Hints response that links + # to the assets. # # ==== Options # # When the last parameter is a hash you can add HTML attributes using that - # parameter. The following options are supported: + # parameter. This includes but is not limited to the following options: # # * :extname - Append an extension to the generated URL unless the extension # already exists. This only applies for relative URLs. @@ -1977,6 +2029,22 @@ module ActionView::Helpers::AssetTagHelper # when it is set to true. # * :nonce - When set to true, adds an automatic nonce value if # you have Content Security Policy enabled. + # * :async - When set to +true+, adds the +async+ HTML + # attribute, allowing the script to be fetched in parallel to be parsed + # and evaluated as soon as possible. + # * :defer - When set to +true+, adds the +defer+ HTML + # attribute, which indicates to the browser that the script is meant to + # be executed after the document has been parsed. Additionally, prevents + # sending the Preload Links header. + # * :nopush - Specify if the use of server push is not desired + # for the script. Defaults to +true+. + # + # Any other specified options will be treated as HTML attributes for the + # +script+ tag. + # + # For more information regarding how the :async and :defer + # options affect the # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#89 + # javascript_include_tag "http://www.example.com/xmlhr.js", async: true + # # => + # + # javascript_include_tag "http://www.example.com/xmlhr.js", defer: true + # # => + # + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#113 def javascript_include_tag(*sources); end + # Returns an HTML picture tag for the +sources+. If +sources+ is a string, + # a single picture tag will be returned. If +sources+ is an array, a picture + # tag with nested source tags for each source will be returned. The + # +sources+ can be full paths, files that exist in your public images + # directory, or Active Storage attachments. Since the picture tag requires + # an img tag, the last element you provide will be used for the img tag. + # For complete control over the picture tag, a block can be passed, which + # will populate the contents of the tag accordingly. + # + # ==== Options + # + # When the last parameter is a hash you can add HTML attributes using that + # parameter. Apart from all the HTML supported options, the following are supported: + # + # * :image - Hash of options that are passed directly to the +image_tag+ helper. + # + # ==== Examples + # + # picture_tag("picture.webp") + # # => + # picture_tag("gold.png", :image => { :size => "20" }) + # # => + # picture_tag("gold.png", :image => { :size => "45x70" }) + # # => + # picture_tag("picture.webp", "picture.png") + # # => + # picture_tag("picture.webp", "picture.png", :image => { alt: "Image" }) + # # => Image + # picture_tag(["picture.webp", "picture.png"], :image => { alt: "Image" }) + # # => Image + # picture_tag(:class => "my-class") { tag(:source, :srcset => image_path("picture.webp")) + image_tag("picture.png", :alt => "Image") } + # # => Image + # picture_tag { tag(:source, :srcset => image_path("picture-small.webp"), :media => "(min-width: 600px)") + tag(:source, :srcset => image_path("picture-big.webp")) + image_tag("picture.png", :alt => "Image") } + # # => Image + # + # Active Storage blobs (images that are uploaded by the users of your app): + # + # picture_tag(user.profile_picture) + # # => + # + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#491 + def picture_tag(*sources, &block); end + # Returns a link tag that browsers can use to preload the +source+. # The +source+ can be the path of a resource managed by asset pipeline, # a full path, or an URI. @@ -2043,13 +2160,13 @@ module ActionView::Helpers::AssetTagHelper # preload_link_tag("/media/audio.ogg", nopush: true) # # => # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#319 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#355 def preload_link_tag(source, options = T.unsafe(nil)); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 def preload_links_header; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 def preload_links_header=(val); end # Returns a stylesheet link tag for the sources specified as arguments. @@ -2060,8 +2177,8 @@ module ActionView::Helpers::AssetTagHelper # set extname: false in the options. # You can modify the link attributes by passing a hash as the last argument. # - # If the server supports Early Hints, header links for these assets will be - # automatically pushed. + # If the server supports HTTP Early Hints, \Rails will push a 103 Early + # Hints response that links to the assets. # # ==== Options # @@ -2073,6 +2190,10 @@ module ActionView::Helpers::AssetTagHelper # that path. # * :skip_pipeline - This option is used to bypass the asset pipeline # when it is set to true. + # * :nonce - When set to true, adds an automatic nonce value if + # you have Content Security Policy enabled. + # * :nopush - Specify if the use of server push is not desired + # for the stylesheet. Defaults to +true+. # # ==== Examples # @@ -2098,14 +2219,17 @@ module ActionView::Helpers::AssetTagHelper # # => # # # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#170 + # stylesheet_link_tag "style", nonce: true + # # => + # + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#202 def stylesheet_link_tag(*sources); end # Returns an HTML video tag for the +sources+. If +sources+ is a string, # a single video tag will be returned. If +sources+ is an array, a video # tag with nested source tags for each source will be returned. The - # +sources+ can be full paths or files that exist in your public videos - # directory. + # +sources+ can be full paths, files that exist in your public videos + # directory, or Active Storage attachments. # # ==== Options # @@ -2114,8 +2238,8 @@ module ActionView::Helpers::AssetTagHelper # # * :poster - Set an image (like a screenshot) to be shown # before the video loads. The path is calculated like the +src+ of +image_tag+. - # * :size - Supplied as "{Width}x{Height}" or "{Number}", so "30x45" becomes - # width="30" and height="45", and "50" becomes width="50" and height="50". + # * :size - Supplied as "#{width}x#{height}" or "#{number}", so "30x45" becomes + # width="30" height="45", and "50" becomes width="50" height="50". # :size will be ignored if the value is not in the correct format. # * :poster_skip_pipeline will bypass the asset pipeline when using # the :poster option instead using an asset in the public folder. @@ -2145,63 +2269,71 @@ module ActionView::Helpers::AssetTagHelper # video_tag(["trailer.ogg", "trailer.flv"], size: "160x120") # # => # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#459 + # Active Storage blobs (videos that are uploaded by the users of your app): + # + # video_tag(user.intro_video) + # # => + # + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#561 def video_tag(*sources); end private - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#527 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#634 def check_for_image_tag_errors(options); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#518 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#625 def extract_dimensions(size); end # @yield [options] # - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#491 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#598 def multiple_sources_tag_builder(type, sources); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#508 - def resolve_image_source(source, skip_pipeline); end + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#615 + def resolve_asset_source(asset_type, source, skip_pipeline); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#533 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#640 def resolve_link_as(extname, mime_type); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#544 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#654 def send_preload_links_header(preload_links, max_header_size: T.unsafe(nil)); end class << self - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#28 def apply_stylesheet_media_default; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#28 def apply_stylesheet_media_default=(val); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 def image_decoding; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 def image_decoding=(val); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#24 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 def image_loading; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#24 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#25 def image_loading=(val); end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 def preload_links_header; end - # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/asset_tag_helper.rb#27 def preload_links_header=(val); end end end -# Some HTTP client and proxies have a 8kiB header limit +# Some HTTP client and proxies have a 4kiB header limit, but more importantly +# including preload links has diminishing returns so it's best to not go overboard # -# source://actionview//lib/action_view/helpers/asset_tag_helper.rb#543 +# source://actionview//lib/action_view/helpers/asset_tag_helper.rb#652 ActionView::Helpers::AssetTagHelper::MAX_HEADER_SIZE = T.let(T.unsafe(nil), Integer) +# = Action View Asset URL \Helpers +# # This module provides methods for generating asset paths and # URLs. # @@ -2213,8 +2345,8 @@ ActionView::Helpers::AssetTagHelper::MAX_HEADER_SIZE = T.let(T.unsafe(nil), Inte # # === Using asset hosts # -# By default, Rails links to these assets on the current host in the public -# folder, but you can direct Rails to link to assets from a dedicated asset +# By default, \Rails links to these assets on the current host in the public +# folder, but you can direct \Rails to link to assets from a dedicated asset # server by setting ActionController::Base.asset_host in the application # configuration, typically in config/environments/production.rb. # For example, you'd define assets.example.com to be your asset @@ -2314,7 +2446,7 @@ ActionView::Helpers::AssetTagHelper::MAX_HEADER_SIZE = T.let(T.unsafe(nil), Inte # "http://asset%d.example.com", "https://asset1.example.com" # ) # -# source://actionview//lib/action_view/helpers/asset_url_helper.rb#120 +# source://actionview//lib/action_view/helpers/asset_url_helper.rb#121 module ActionView::Helpers::AssetUrlHelper # This is the entry point for all assets. # When using an asset pipeline gem (e.g. propshaft or sprockets-rails), the @@ -2382,7 +2514,7 @@ module ActionView::Helpers::AssetUrlHelper # # @raise [ArgumentError] # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#186 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#187 def asset_path(source, options = T.unsafe(nil)); end # Computes the full URL to an asset in the public directory. This @@ -2395,7 +2527,7 @@ module ActionView::Helpers::AssetUrlHelper # asset_url "application.js" # => http://example.com/assets/application.js # asset_url "application.js", host: "http://cdn.example.com" # => http://cdn.example.com/assets/application.js # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#230 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#231 def asset_url(source, options = T.unsafe(nil)); end # Computes the path to an audio asset in the public audios directory. @@ -2408,7 +2540,7 @@ module ActionView::Helpers::AssetUrlHelper # audio_path("/sounds/horse.wav") # => /sounds/horse.wav # audio_path("http://www.example.com/sounds/horse.wav") # => http://www.example.com/sounds/horse.wav # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#429 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#430 def audio_path(source, options = T.unsafe(nil)); end # Computes the full URL to an audio asset in the public audios directory. @@ -2418,13 +2550,13 @@ module ActionView::Helpers::AssetUrlHelper # # audio_url "horse.wav", host: "http://stage.example.com" # => http://stage.example.com/audios/horse.wav # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#441 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#442 def audio_url(source, options = T.unsafe(nil)); end # Compute extname to append to asset path. Returns +nil+ if # nothing should be added. # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#242 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#243 def compute_asset_extname(source, options = T.unsafe(nil)); end # Pick an asset host for this source. Returns +nil+ if no host is set, @@ -2433,14 +2565,14 @@ module ActionView::Helpers::AssetUrlHelper # or the value returned from invoking call on an object responding to call # (proc or otherwise). # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#276 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#277 def compute_asset_host(source = T.unsafe(nil), options = T.unsafe(nil)); end # Computes asset path to public directory. Plugins and # extensions can override this method to point to custom assets # or generate digested paths or query strings. # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#265 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#266 def compute_asset_path(source, options = T.unsafe(nil)); end # Computes the path to a font asset. @@ -2452,7 +2584,7 @@ module ActionView::Helpers::AssetUrlHelper # font_path("/dir/font.ttf") # => /dir/font.ttf # font_path("http://www.example.com/dir/font.ttf") # => http://www.example.com/dir/font.ttf # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#454 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#455 def font_path(source, options = T.unsafe(nil)); end # Computes the full URL to a font asset. @@ -2462,7 +2594,7 @@ module ActionView::Helpers::AssetUrlHelper # # font_url "font.ttf", host: "http://stage.example.com" # => http://stage.example.com/fonts/font.ttf # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#466 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#467 def font_url(source, options = T.unsafe(nil)); end # Computes the path to an image asset. @@ -2476,10 +2608,10 @@ module ActionView::Helpers::AssetUrlHelper # image_path("http://www.example.com/img/edit.png") # => "http://www.example.com/img/edit.png" # # If you have images as application resources this method may conflict with their named routes. - # The alias +path_to_image+ is provided to avoid that. Rails uses the alias internally, and + # The alias +path_to_image+ is provided to avoid that. \Rails uses the alias internally, and # plugin authors are encouraged to do so. # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#377 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#378 def image_path(source, options = T.unsafe(nil)); end # Computes the full URL to an image asset. @@ -2489,7 +2621,7 @@ module ActionView::Helpers::AssetUrlHelper # # image_url "edit.png", host: "http://stage.example.com" # => http://stage.example.com/assets/edit.png # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#389 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#390 def image_url(source, options = T.unsafe(nil)); end # Computes the path to a JavaScript asset in the public javascripts directory. @@ -2503,7 +2635,7 @@ module ActionView::Helpers::AssetUrlHelper # javascript_path "http://www.example.com/js/xmlhr" # => http://www.example.com/js/xmlhr # javascript_path "http://www.example.com/js/xmlhr.js" # => http://www.example.com/js/xmlhr.js # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#320 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#321 def javascript_path(source, options = T.unsafe(nil)); end # Computes the full URL to a JavaScript asset in the public javascripts directory. @@ -2513,7 +2645,7 @@ module ActionView::Helpers::AssetUrlHelper # # javascript_url "js/xmlhr.js", host: "http://stage.example.com" # => http://stage.example.com/assets/js/xmlhr.js # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#332 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#333 def javascript_url(source, options = T.unsafe(nil)); end # This is the entry point for all assets. @@ -2583,7 +2715,7 @@ module ActionView::Helpers::AssetUrlHelper # # @raise [ArgumentError] # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#186 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#187 def path_to_asset(source, options = T.unsafe(nil)); end # Computes the path to an audio asset in the public audios directory. @@ -2597,7 +2729,7 @@ module ActionView::Helpers::AssetUrlHelper # audio_path("http://www.example.com/sounds/horse.wav") # => http://www.example.com/sounds/horse.wav # aliased to avoid conflicts with an audio_path named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#429 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#430 def path_to_audio(source, options = T.unsafe(nil)); end # Computes the path to a font asset. @@ -2610,7 +2742,7 @@ module ActionView::Helpers::AssetUrlHelper # font_path("http://www.example.com/dir/font.ttf") # => http://www.example.com/dir/font.ttf # aliased to avoid conflicts with a font_path named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#454 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#455 def path_to_font(source, options = T.unsafe(nil)); end # Computes the path to an image asset. @@ -2624,11 +2756,11 @@ module ActionView::Helpers::AssetUrlHelper # image_path("http://www.example.com/img/edit.png") # => "http://www.example.com/img/edit.png" # # If you have images as application resources this method may conflict with their named routes. - # The alias +path_to_image+ is provided to avoid that. Rails uses the alias internally, and + # The alias +path_to_image+ is provided to avoid that. \Rails uses the alias internally, and # plugin authors are encouraged to do so. # aliased to avoid conflicts with an image_path named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#377 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#378 def path_to_image(source, options = T.unsafe(nil)); end # Computes the path to a JavaScript asset in the public javascripts directory. @@ -2643,7 +2775,7 @@ module ActionView::Helpers::AssetUrlHelper # javascript_path "http://www.example.com/js/xmlhr.js" # => http://www.example.com/js/xmlhr.js # aliased to avoid conflicts with a javascript_path named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#320 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#321 def path_to_javascript(source, options = T.unsafe(nil)); end # Computes the path to a stylesheet asset in the public stylesheets directory. @@ -2658,7 +2790,7 @@ module ActionView::Helpers::AssetUrlHelper # stylesheet_path "http://www.example.com/css/style.css" # => http://www.example.com/css/style.css # aliased to avoid conflicts with a stylesheet_path named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#347 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#348 def path_to_stylesheet(source, options = T.unsafe(nil)); end # Computes the path to a video asset in the public videos directory. @@ -2672,14 +2804,14 @@ module ActionView::Helpers::AssetUrlHelper # video_path("http://www.example.com/vid/hd.avi") # => http://www.example.com/vid/hd.avi # aliased to avoid conflicts with a video_path named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#403 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#404 def path_to_video(source, options = T.unsafe(nil)); end # Computes asset path to public directory. Plugins and # extensions can override this method to point to custom assets # or generate digested paths or query strings. # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#265 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#266 def public_compute_asset_path(source, options = T.unsafe(nil)); end # Computes the path to a stylesheet asset in the public stylesheets directory. @@ -2693,7 +2825,7 @@ module ActionView::Helpers::AssetUrlHelper # stylesheet_path "http://www.example.com/css/style" # => http://www.example.com/css/style # stylesheet_path "http://www.example.com/css/style.css" # => http://www.example.com/css/style.css # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#347 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#348 def stylesheet_path(source, options = T.unsafe(nil)); end # Computes the full URL to a stylesheet asset in the public stylesheets directory. @@ -2703,7 +2835,7 @@ module ActionView::Helpers::AssetUrlHelper # # stylesheet_url "css/style.css", host: "http://stage.example.com" # => http://stage.example.com/assets/css/style.css # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#359 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#360 def stylesheet_url(source, options = T.unsafe(nil)); end # Computes the full URL to an asset in the public directory. This @@ -2717,7 +2849,7 @@ module ActionView::Helpers::AssetUrlHelper # asset_url "application.js", host: "http://cdn.example.com" # => http://cdn.example.com/assets/application.js # aliased to avoid conflicts with an asset_url named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#230 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#231 def url_to_asset(source, options = T.unsafe(nil)); end # Computes the full URL to an audio asset in the public audios directory. @@ -2728,7 +2860,7 @@ module ActionView::Helpers::AssetUrlHelper # audio_url "horse.wav", host: "http://stage.example.com" # => http://stage.example.com/audios/horse.wav # aliased to avoid conflicts with an audio_url named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#441 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#442 def url_to_audio(source, options = T.unsafe(nil)); end # Computes the full URL to a font asset. @@ -2739,7 +2871,7 @@ module ActionView::Helpers::AssetUrlHelper # font_url "font.ttf", host: "http://stage.example.com" # => http://stage.example.com/fonts/font.ttf # aliased to avoid conflicts with a font_url named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#466 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#467 def url_to_font(source, options = T.unsafe(nil)); end # Computes the full URL to an image asset. @@ -2750,7 +2882,7 @@ module ActionView::Helpers::AssetUrlHelper # image_url "edit.png", host: "http://stage.example.com" # => http://stage.example.com/assets/edit.png # aliased to avoid conflicts with an image_url named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#389 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#390 def url_to_image(source, options = T.unsafe(nil)); end # Computes the full URL to a JavaScript asset in the public javascripts directory. @@ -2761,7 +2893,7 @@ module ActionView::Helpers::AssetUrlHelper # javascript_url "js/xmlhr.js", host: "http://stage.example.com" # => http://stage.example.com/assets/js/xmlhr.js # aliased to avoid conflicts with a javascript_url named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#332 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#333 def url_to_javascript(source, options = T.unsafe(nil)); end # Computes the full URL to a stylesheet asset in the public stylesheets directory. @@ -2772,7 +2904,7 @@ module ActionView::Helpers::AssetUrlHelper # stylesheet_url "css/style.css", host: "http://stage.example.com" # => http://stage.example.com/assets/css/style.css # aliased to avoid conflicts with a stylesheet_url named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#359 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#360 def url_to_stylesheet(source, options = T.unsafe(nil)); end # Computes the full URL to a video asset in the public videos directory. @@ -2783,7 +2915,7 @@ module ActionView::Helpers::AssetUrlHelper # video_url "hd.avi", host: "http://stage.example.com" # => http://stage.example.com/videos/hd.avi # aliased to avoid conflicts with a video_url named route # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#415 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#416 def url_to_video(source, options = T.unsafe(nil)); end # Computes the path to a video asset in the public videos directory. @@ -2796,7 +2928,7 @@ module ActionView::Helpers::AssetUrlHelper # video_path("/trailers/hd.avi") # => /trailers/hd.avi # video_path("http://www.example.com/vid/hd.avi") # => http://www.example.com/vid/hd.avi # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#403 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#404 def video_path(source, options = T.unsafe(nil)); end # Computes the full URL to a video asset in the public videos directory. @@ -2806,21 +2938,23 @@ module ActionView::Helpers::AssetUrlHelper # # video_url "hd.avi", host: "http://stage.example.com" # => http://stage.example.com/videos/hd.avi # - # source://actionview//lib/action_view/helpers/asset_url_helper.rb#415 + # source://actionview//lib/action_view/helpers/asset_url_helper.rb#416 def video_url(source, options = T.unsafe(nil)); end end -# source://actionview//lib/action_view/helpers/asset_url_helper.rb#235 +# source://actionview//lib/action_view/helpers/asset_url_helper.rb#236 ActionView::Helpers::AssetUrlHelper::ASSET_EXTENSIONS = T.let(T.unsafe(nil), Hash) # Maps asset types to public directory. # -# source://actionview//lib/action_view/helpers/asset_url_helper.rb#253 +# source://actionview//lib/action_view/helpers/asset_url_helper.rb#254 ActionView::Helpers::AssetUrlHelper::ASSET_PUBLIC_DIRECTORIES = T.let(T.unsafe(nil), Hash) -# source://actionview//lib/action_view/helpers/asset_url_helper.rb#121 +# source://actionview//lib/action_view/helpers/asset_url_helper.rb#122 ActionView::Helpers::AssetUrlHelper::URI_REGEXP = T.let(T.unsafe(nil), Regexp) +# = Action View Atom Feed \Helpers +# # source://actionview//lib/action_view/helpers/atom_feed_helper.rb#8 module ActionView::Helpers::AtomFeedHelper # Adds easy defaults to writing Atom feeds with the Builder template engine (this does not work on ERB or any other @@ -2899,9 +3033,9 @@ module ActionView::Helpers::AtomFeedHelper # end # # The Atom spec defines five elements (content rights title subtitle - # summary) which may directly contain xhtml content if type: 'xhtml' + # summary) which may directly contain XHTML content if type: 'xhtml' # is specified as an attribute. If so, this helper will take care of - # the enclosing div and xhtml namespace declaration. Example usage: + # the enclosing div and XHTML namespace declaration. Example usage: # # entry.summary type: 'xhtml' do |xhtml| # xhtml.p pluralize(order.line_items.count, "line item") @@ -2926,7 +3060,7 @@ class ActionView::Helpers::AtomFeedHelper::AtomBuilder private - # Delegate to xml builder, first wrapping the element in an xhtml + # Delegate to XML Builder, first wrapping the element in an XHTML # namespaced div element if the method and arguments indicate # that an xhtml_block? is desired. # @@ -2972,6 +3106,8 @@ class ActionView::Helpers::AtomFeedHelper::AtomFeedBuilder < ::ActionView::Helpe def updated(date_or_time = T.unsafe(nil)); end end +# = Action View Cache \Helpers +# # source://actionview//lib/action_view/helpers/cache_helper.rb#6 module ActionView::Helpers::CacheHelper # This helper exposes a method for caching fragments of a view @@ -3044,11 +3180,11 @@ module ActionView::Helpers::CacheHelper # render 'comments/comments' # render('comments/comments') # - # render "header" translates to render("comments/header") + # render "header" # translates to render("comments/header") # - # render(@topic) translates to render("topics/topic") - # render(topics) translates to render("topics/topic") - # render(message.topics) translates to render("topics/topic") + # render(@topic) # translates to render("topics/topic") + # render(topics) # translates to render("topics/topic") + # render(message.topics) # translates to render("topics/topic") # # It's not possible to derive all render calls like that, though. # Here are a few examples of things that can't be derived: @@ -3213,37 +3349,42 @@ module ActionView::Helpers::CacheHelper def read_fragment_for(name, options); end # source://actionview//lib/action_view/helpers/cache_helper.rb#284 - def write_fragment_for(name, options); end + def write_fragment_for(name, options, &block); end end -# source://actionview//lib/action_view/helpers/cache_helper.rb#295 +# source://actionview//lib/action_view/helpers/cache_helper.rb#289 module ActionView::Helpers::CacheHelper::CachingRegistry extend ::ActionView::Helpers::CacheHelper::CachingRegistry # @return [Boolean] # - # source://actionview//lib/action_view/helpers/cache_helper.rb#298 + # source://actionview//lib/action_view/helpers/cache_helper.rb#292 def caching?; end - # source://actionview//lib/action_view/helpers/cache_helper.rb#302 + # source://actionview//lib/action_view/helpers/cache_helper.rb#296 def track_caching; end end # source://actionview//lib/action_view/helpers/cache_helper.rb#7 class ActionView::Helpers::CacheHelper::UncacheableFragmentError < ::StandardError; end -# CaptureHelper exposes methods to let you extract generated markup which +# = Action View Capture \Helpers +# +# \CaptureHelper exposes methods to let you extract generated markup which # can be used in other parts of a template or layout file. # -# It provides a method to capture blocks into variables through capture and -# a way to capture a block of markup for use in a layout through {content_for}[rdoc-ref:ActionView::Helpers::CaptureHelper#content_for]. +# It provides a method to capture blocks into variables through #capture and +# a way to capture a block of markup for use in a layout through #content_for. +# +# As well as provides a method when using streaming responses through #provide. +# See ActionController::Streaming for more information. # -# source://actionview//lib/action_view/helpers/capture_helper.rb#13 +# source://actionview//lib/action_view/helpers/capture_helper.rb#17 module ActionView::Helpers::CaptureHelper - # The capture method extracts part of a template as a String object. + # The capture method extracts part of a template as a string object. # You can then use this object anywhere in your templates, layout, or helpers. # - # The capture method can be used in ERB templates... + # The capture method can be used in \ERB templates... # # <% @greeting = capture do %> # Welcome to my shiny new web page! The date and time is @@ -3269,8 +3410,8 @@ module ActionView::Helpers::CaptureHelper # # @greeting # => "Welcome to my shiny new web page! The date and time is 2018-09-06 11:09:16 -0500" # - # source://actionview//lib/action_view/helpers/capture_helper.rb#43 - def capture(*args); end + # source://actionview//lib/action_view/helpers/capture_helper.rb#47 + def capture(*args, &block); end # Calling content_for stores a block of markup in an identifier for later use. # In order to access this stored content in other templates, helper modules @@ -3377,10 +3518,11 @@ module ActionView::Helpers::CaptureHelper # # WARNING: content_for is ignored in caches. So you shouldn't use it for elements that will be fragment cached. # - # source://actionview//lib/action_view/helpers/capture_helper.rb#155 + # source://actionview//lib/action_view/helpers/capture_helper.rb#172 def content_for(name, content = T.unsafe(nil), options = T.unsafe(nil), &block); end # content_for? checks whether any content has been captured yet using content_for. + # # Useful to render parts of your layout differently based on what is in your views. # # <%# This is the layout %> @@ -3397,7 +3539,7 @@ module ActionView::Helpers::CaptureHelper # # @return [Boolean] # - # source://actionview//lib/action_view/helpers/capture_helper.rb#195 + # source://actionview//lib/action_view/helpers/capture_helper.rb#215 def content_for?(name); end # The same as +content_for+ but when used with streaming flushes @@ -3406,72 +3548,160 @@ module ActionView::Helpers::CaptureHelper # template, you should use +content_for+, if not, use +provide+ to tell # the layout to stop looking for more contents. # - # source://actionview//lib/action_view/helpers/capture_helper.rb#175 + # See ActionController::Streaming for more information. + # + # source://actionview//lib/action_view/helpers/capture_helper.rb#194 def provide(name, content = T.unsafe(nil), &block); end # Use an alternate output buffer for the duration of the block. # Defaults to a new empty string. # - # source://actionview//lib/action_view/helpers/capture_helper.rb#201 + # source://actionview//lib/action_view/helpers/capture_helper.rb#221 def with_output_buffer(buf = T.unsafe(nil)); end end +# source://actionview//lib/action_view/helpers/content_exfiltration_prevention_helper.rb#5 +module ActionView::Helpers::ContentExfiltrationPreventionHelper + # source://actionview//lib/action_view/helpers/content_exfiltration_prevention_helper.rb#6 + def prepend_content_exfiltration_prevention; end + + # source://actionview//lib/action_view/helpers/content_exfiltration_prevention_helper.rb#6 + def prepend_content_exfiltration_prevention=(val); end + + # source://actionview//lib/action_view/helpers/content_exfiltration_prevention_helper.rb#61 + def prevent_content_exfiltration(html); end + + class << self + # source://actionview//lib/action_view/helpers/content_exfiltration_prevention_helper.rb#6 + def prepend_content_exfiltration_prevention; end + + # source://actionview//lib/action_view/helpers/content_exfiltration_prevention_helper.rb#6 + def prepend_content_exfiltration_prevention=(val); end + end +end + +# Close any open tags that support CDATA (textarea, xmp) before each form tag. +# This prevents attackers from injecting unclosed tags that could capture +# form contents. +# +# For example, an attacker might inject: +# +#
or +# the end of the document would be captured by the attacker's +# # # text_area(:comment, :text, size: "20x30") @@ -6886,7 +7152,7 @@ module ActionView::Helpers::FormHelper # # #{@entry.body} # # # - # source://actionview//lib/action_view/helpers/form_helper.rb#1268 + # source://actionview//lib/action_view/helpers/form_helper.rb#1277 def text_area(object_name, method, options = T.unsafe(nil)); end # Returns an input tag of the "text" type tailored for accessing a specified attribute (identified by +method+) on an object @@ -6895,14 +7161,14 @@ module ActionView::Helpers::FormHelper # shown. # # ==== Examples - # text_field(:post, :title, size: 20) - # # => + # text_field(:article, :title, size: 20) + # # => # - # text_field(:post, :title, class: "create_input") - # # => + # text_field(:article, :title, class: "create_input") + # # => # - # text_field(:post, :title, maxlength: 30, class: "title_input") - # # => + # text_field(:article, :title, maxlength: 30, class: "title_input") + # # => # # text_field(:session, :user, onchange: "if ($('#session_user').val() === 'admin') { alert('Your login cannot be admin!'); }") # # => @@ -6910,7 +7176,7 @@ module ActionView::Helpers::FormHelper # text_field(:snippet, :code, size: 20, class: 'code_input') # # => # - # source://actionview//lib/action_view/helpers/form_helper.rb#1166 + # source://actionview//lib/action_view/helpers/form_helper.rb#1175 def text_field(object_name, method, options = T.unsafe(nil)); end # Returns a text_field of type "time". @@ -6948,7 +7214,7 @@ module ActionView::Helpers::FormHelper # time_field("task", "started_at", value: Time.now, include_seconds: false) # # => # - # source://actionview//lib/action_view/helpers/form_helper.rb#1468 + # source://actionview//lib/action_view/helpers/form_helper.rb#1477 def time_field(object_name, method, options = T.unsafe(nil)); end # Returns a text_field of type "url". @@ -6956,7 +7222,7 @@ module ActionView::Helpers::FormHelper # url_field("user", "homepage") # # => # - # source://actionview//lib/action_view/helpers/form_helper.rb#1542 + # source://actionview//lib/action_view/helpers/form_helper.rb#1557 def url_field(object_name, method, options = T.unsafe(nil)); end # Returns a text_field of type "week". @@ -6972,44 +7238,46 @@ module ActionView::Helpers::FormHelper # week_field("user", "born_on") # # => # - # source://actionview//lib/action_view/helpers/form_helper.rb#1533 + # source://actionview//lib/action_view/helpers/form_helper.rb#1548 def week_field(object_name, method, options = T.unsafe(nil)); end private - # source://actionview//lib/action_view/helpers/form_helper.rb#463 + # source://actionview//lib/action_view/helpers/form_helper.rb#465 def apply_form_for_options!(object, options); end - # source://actionview//lib/action_view/helpers/form_helper.rb#1607 + # source://actionview//lib/action_view/helpers/form_helper.rb#1622 def default_form_builder_class; end - # source://actionview//lib/action_view/helpers/form_helper.rb#1578 + # source://actionview//lib/action_view/helpers/form_helper.rb#1593 def html_options_for_form_with(url_for_options = T.unsafe(nil), model = T.unsafe(nil), html: T.unsafe(nil), local: T.unsafe(nil), skip_enforcing_utf8: T.unsafe(nil), **options); end - # source://actionview//lib/action_view/helpers/form_helper.rb#1593 + # source://actionview//lib/action_view/helpers/form_helper.rb#1608 def instantiate_builder(record_name, record_object, options); end class << self - # source://actionview//lib/action_view/helpers/form_helper.rb#479 + # source://actionview//lib/action_view/helpers/form_helper.rb#481 def form_with_generates_ids; end - # source://actionview//lib/action_view/helpers/form_helper.rb#479 + # source://actionview//lib/action_view/helpers/form_helper.rb#481 def form_with_generates_ids=(val); end - # source://actionview//lib/action_view/helpers/form_helper.rb#477 + # source://actionview//lib/action_view/helpers/form_helper.rb#479 def form_with_generates_remote_forms; end - # source://actionview//lib/action_view/helpers/form_helper.rb#477 + # source://actionview//lib/action_view/helpers/form_helper.rb#479 def form_with_generates_remote_forms=(val); end - # source://actionview//lib/action_view/helpers/form_helper.rb#481 + # source://actionview//lib/action_view/helpers/form_helper.rb#483 def multiple_file_field_include_hidden; end - # source://actionview//lib/action_view/helpers/form_helper.rb#481 + # source://actionview//lib/action_view/helpers/form_helper.rb#483 def multiple_file_field_include_hidden=(val); end end end +# = Action View Form Option \Helpers +# # Provides a number of methods for turning different kinds of containers into a set of option tags. # # The collection_select, select and time_zone_select methods take an options parameter, a hash: @@ -7091,7 +7359,7 @@ end # # # -# source://actionview//lib/action_view/helpers/form_options_helper.rb#93 +# source://actionview//lib/action_view/helpers/form_options_helper.rb#94 module ActionView::Helpers::FormOptionsHelper include ::ActionView::Helpers::SanitizeHelper include ::ActionView::Helpers::CaptureHelper @@ -7181,7 +7449,7 @@ module ActionView::Helpers::FormOptionsHelper # In the rare case you don't want this hidden field, you can pass the # include_hidden: false option to the helper method. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#781 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#782 def collection_check_boxes(object, method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Returns radio button tags for the collection of existing return values @@ -7264,7 +7532,7 @@ module ActionView::Helpers::FormOptionsHelper # In case if you don't want the helper to generate this hidden field you can specify # include_hidden: false option. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#697 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#698 def collection_radio_buttons(object, method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Returns # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#198 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#199 def collection_select(object, method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end # Returns # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#257 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#258 def grouped_collection_select(object, method, collection, group_method, group_label_method, option_key_method, option_value_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end # Returns a string of tags, like options_for_select, but @@ -7430,7 +7698,7 @@ module ActionView::Helpers::FormOptionsHelper # Note: Only the and tags are returned, so you still have to # wrap the output in an appropriate tag. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#461 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#462 def option_groups_from_collection_for_select(collection, group_method, group_label_method, option_key_method, option_value_method, selected_key = T.unsafe(nil)); end # Accepts a container (hash, array, enumerable, your type) and returns a string of option tags. Given a container @@ -7542,7 +7810,7 @@ module ActionView::Helpers::FormOptionsHelper # # NOTE: Only the option tags are returned, you have to wrap this call in a regular HTML select tag. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#357 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#358 def options_for_select(container, selected = T.unsafe(nil)); end # Returns a string of option tags that have been compiled by iterating over the +collection+ and assigning @@ -7570,7 +7838,7 @@ module ActionView::Helpers::FormOptionsHelper # options_from_collection_for_select(@people, 'id', 'name', 1) # should produce the desired results. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#400 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#401 def options_from_collection_for_select(collection, value_method, text_method, selected = T.unsafe(nil)); end # Create a select tag and a series of contained option tags for the provided object and method. @@ -7635,7 +7903,7 @@ module ActionView::Helpers::FormOptionsHelper # In case if you don't want the helper to generate this hidden field you can specify # include_hidden: false option. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#158 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#159 def select(object, method, choices = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Returns a string of option tags for pretty much any time zone in the @@ -7658,7 +7926,7 @@ module ActionView::Helpers::FormOptionsHelper # NOTE: Only the option tags are returned, you have to wrap this call in # a regular HTML select tag. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#578 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#579 def time_zone_options_for_select(selected = T.unsafe(nil), priority_zones = T.unsafe(nil), model = T.unsafe(nil)); end # Returns select and option tags for the given object and method, using @@ -7692,7 +7960,7 @@ module ActionView::Helpers::FormOptionsHelper # # time_zone_select(:user, :time_zone, ActiveSupport::TimeZone.all.sort, model: ActiveSupport::TimeZone) # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#291 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#292 def time_zone_select(object, method, priority_zones = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil)); end # Returns a string of option tags for the days of the week. @@ -7707,49 +7975,52 @@ module ActionView::Helpers::FormOptionsHelper # NOTE: Only the option tags are returned, you have to wrap this call in # a regular HTML select tag. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#610 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#611 def weekday_options_for_select(selected = T.unsafe(nil), index_as_value: T.unsafe(nil), day_format: T.unsafe(nil), beginning_of_week: T.unsafe(nil)); end # Returns select and option tags for the given object and method, using # weekday_options_for_select to generate the list of option tags. # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#297 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#298 def weekday_select(object, method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end private - # source://actionview//lib/action_view/helpers/form_options_helper.rb#808 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#809 def extract_selected_and_disabled(selected); end - # source://actionview//lib/action_view/helpers/form_options_helper.rb#819 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#820 def extract_values_from_collection(collection, value_method, selected); end - # source://actionview//lib/action_view/helpers/form_options_helper.rb#786 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#787 def option_html_attributes(element); end - # source://actionview//lib/action_view/helpers/form_options_helper.rb#794 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#795 def option_text_and_value(option); end # @return [Boolean] # - # source://actionview//lib/action_view/helpers/form_options_helper.rb#804 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#805 def option_value_selected?(value, selected); end - # source://actionview//lib/action_view/helpers/form_options_helper.rb#833 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#834 def prompt_text(prompt); end - # source://actionview//lib/action_view/helpers/form_options_helper.rb#829 + # source://actionview//lib/action_view/helpers/form_options_helper.rb#830 def value_for_collection(item, value); end end +# = Action View Form Tag \Helpers +# # Provides a number of methods for creating form tags that don't rely on an Active Record object assigned to the template like # FormHelper does. Instead, you provide the names and values manually. # # NOTE: The HTML options disabled, readonly, and multiple can all be treated as booleans. So specifying # disabled: true will give disabled="disabled". # -# source://actionview//lib/action_view/helpers/form_tag_helper.rb#17 +# source://actionview//lib/action_view/helpers/form_tag_helper.rb#19 module ActionView::Helpers::FormTagHelper + include ::ActionView::Helpers::ContentExfiltrationPreventionHelper extend ::ActiveSupport::Concern include ::ActionView::Helpers::UrlHelper include ::ActionView::Helpers::SanitizeHelper @@ -7792,32 +8063,19 @@ module ActionView::Helpers::FormTagHelper # # Ask me! # # # - # ==== Deprecated: Rails UJS attributes - # - # Prior to Rails 7, Rails shipped with a JavaScript library called @rails/ujs on by default. Following Rails 7, - # this library is no longer on by default. This library integrated with the following options: + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#566 + def button_tag(content_or_options = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # :call-seq: + # check_box_tag(name, options = {}) + # check_box_tag(name, value, options = {}) + # check_box_tag(name, value, checked, options = {}) # - # * confirm: 'question?' - If present, the - # unobtrusive JavaScript drivers will provide a prompt with - # the question specified. If the user accepts, the form is - # processed normally, otherwise no action is taken. - # * :disable_with - Value of this parameter will be - # used as the value for a disabled version of the submit - # button when the form is submitted. This feature is provided - # by the unobtrusive JavaScript driver. - # - # button_tag "Save", data: { confirm: "Are you sure?" } - # # => - # - # button_tag "Checkout", data: { disable_with: "Please wait..." } - # # => - # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#578 - def button_tag(content_or_options = T.unsafe(nil), options = T.unsafe(nil), &block); end - - # Creates a check box form input tag. + # Creates a check box form input tag. # # ==== Options + # * :value - The value of the input. Defaults to "1". + # * :checked - If set to true, the checkbox will be checked by default. # * :disabled - If set to true, the user will not be able to use this input. # * Any other key creates standard HTML options for the tag. # @@ -7837,8 +8095,8 @@ module ActionView::Helpers::FormTagHelper # check_box_tag 'eula', 'accepted', false, disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#444 - def check_box_tag(name, value = T.unsafe(nil), checked = T.unsafe(nil), options = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#455 + def check_box_tag(name, *args); end # Creates a text field of type "color". # @@ -7860,7 +8118,7 @@ module ActionView::Helpers::FormTagHelper # color_field_tag 'color', '#DEF726', class: 'special_input', disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#676 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#666 def color_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text field of type "date". @@ -7883,7 +8141,7 @@ module ActionView::Helpers::FormTagHelper # date_field_tag 'date', '01/01/2014', class: 'special_input', disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#746 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#736 def date_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text field of type "datetime-local". @@ -7895,8 +8153,23 @@ module ActionView::Helpers::FormTagHelper # * :min - The minimum acceptable value. # * :max - The maximum acceptable value. # * :step - The acceptable value granularity. + # * :include_seconds - Include seconds in the output timestamp format (true by default). + # + # ==== Examples # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#773 + # datetime_field_tag 'name' + # # => + # + # datetime_field_tag 'datetime', '2014-01-01T01:01' + # # => + # + # datetime_field_tag 'datetime', nil, class: 'special_input' + # # => + # + # datetime_field_tag 'datetime', '2014-01-01T01:01', class: 'special_input', disabled: true + # # => + # + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#795 def datetime_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text field of type "datetime-local". @@ -7908,14 +8181,29 @@ module ActionView::Helpers::FormTagHelper # * :min - The minimum acceptable value. # * :max - The maximum acceptable value. # * :step - The acceptable value granularity. + # * :include_seconds - Include seconds in the output timestamp format (true by default). + # + # ==== Examples + # + # datetime_field_tag 'name' + # # => + # + # datetime_field_tag 'datetime', '2014-01-01T01:01' + # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#773 + # datetime_field_tag 'datetime', nil, class: 'special_input' + # # => + # + # datetime_field_tag 'datetime', '2014-01-01T01:01', class: 'special_input', disabled: true + # # => + # + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#795 def datetime_local_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#29 def default_enforce_utf8; end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#29 def default_enforce_utf8=(val); end # Creates a text field of type "email". @@ -7938,13 +8226,13 @@ module ActionView::Helpers::FormTagHelper # email_field_tag 'email', 'email@example.com', class: 'special_input', disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#847 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#897 def email_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#23 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 def embed_authenticity_token_in_remote_forms; end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#23 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 def embed_authenticity_token_in_remote_forms=(val); end # Generate an HTML id attribute value for the given name and @@ -7954,16 +8242,16 @@ module ActionView::Helpers::FormTagHelper # attribute name. # # <%= label_tag :post, :title %> - # <%= text_field_tag :post, :title, aria: { describedby: field_id(:post, :title, :error) } %> + # <%= text_field :post, :title, aria: { describedby: field_id(:post, :title, :error) } %> # <%= tag.span("is blank", id: field_id(:post, :title, :error) %> # # In the example above, the element built by - # the call to text_field_tag declares an + # the call to text_field declares an # aria-describedby attribute referencing the # element, sharing a common id root (post_title, in this # case). # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#99 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#102 def field_id(object_name, method_name, *suffixes, index: T.unsafe(nil), namespace: T.unsafe(nil)); end # Generate an HTML name attribute value for the given name and @@ -7972,13 +8260,13 @@ module ActionView::Helpers::FormTagHelper # Return the value generated by the FormBuilder for the given # attribute name. # - # <%= text_field_tag :post, :title, name: field_name(:post, :title, :subtitle) %> - # <%# => + # <%= text_field :post, :title, name: field_name(:post, :title, :subtitle) %> + # <%# => %> # - # <%= text_field_tag :post, :tag, name: field_name(:post, :tag, multiple: true) %> - # <%# => + # <%= text_field :post, :tag, name: field_name(:post, :tag, multiple: true) %> + # <%# => %> # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#129 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#132 def field_name(object_name, method_name, *method_names, multiple: T.unsafe(nil), index: T.unsafe(nil)); end # Creates a field set for grouping HTML form elements. @@ -8002,9 +8290,33 @@ module ActionView::Helpers::FormTagHelper # <% end %> # # =>

# - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#650 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#638 def field_set_tag(legend = T.unsafe(nil), options = T.unsafe(nil), &block); end + # Creates a field set for grouping HTML form elements. + # + # legend will become the fieldset's title (optional as per W3C). + # options accept the same values as tag. + # + # ==== Examples + # <%= field_set_tag do %> + #

<%= text_field_tag 'name' %>

+ # <% end %> + # # =>

+ # + # <%= field_set_tag 'Your details' do %> + #

<%= text_field_tag 'name' %>

+ # <% end %> + # # =>
Your details

+ # + # <%= field_set_tag nil, class: 'format' do %> + #

<%= text_field_tag 'name' %>

+ # <% end %> + # # =>

+ # + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#638 + def fieldset_tag(legend = T.unsafe(nil), options = T.unsafe(nil), &block); end + # Creates a file upload field. If you are using file uploads then you will also need # to set the multipart option for the form tag: # @@ -8041,7 +8353,7 @@ module ActionView::Helpers::FormTagHelper # file_field_tag 'file', accept: 'text/html', class: 'upload', value: 'index.html' # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#344 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#347 def file_field_tag(name, options = T.unsafe(nil)); end # Starts a form tag that points the action to a URL configured with url_for_options just like @@ -8091,7 +8403,7 @@ module ActionView::Helpers::FormTagHelper # form_tag('http://far.away.com/form', authenticity_token: "cf50faa3fe97702ca1ae") # # form with custom authenticity token # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#75 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#78 def form_tag(url_for_options = T.unsafe(nil), options = T.unsafe(nil), &block); end # Creates a hidden form input field used to transmit data that would be lost due to HTTP's statelessness or @@ -8111,7 +8423,7 @@ module ActionView::Helpers::FormTagHelper # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#305 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#308 def hidden_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Displays an image which when clicked will submit the form. @@ -8145,7 +8457,7 @@ module ActionView::Helpers::FormTagHelper # image_submit_tag("save.png", data: { confirm: "Are you sure?" }) # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#624 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#612 def image_submit_tag(source, options = T.unsafe(nil)); end # Creates a label element. Accepts a block. @@ -8163,7 +8475,7 @@ module ActionView::Helpers::FormTagHelper # label_tag 'name', nil, class: 'small_label' # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#278 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#281 def label_tag(name = T.unsafe(nil), content_or_options = T.unsafe(nil), options = T.unsafe(nil), &block); end # Creates a text field of type "month". @@ -8176,7 +8488,21 @@ module ActionView::Helpers::FormTagHelper # * :max - The maximum acceptable value. # * :step - The acceptable value granularity. # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#788 + # ==== Examples + # + # month_field_tag 'name' + # # => + # + # month_field_tag 'month', '2014-01' + # # => + # + # month_field_tag 'month', nil, class: 'special_input' + # # => + # + # month_field_tag 'month', '2014-01', class: 'special_input', disabled: true + # # => + # + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#824 def month_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a number field. @@ -8224,7 +8550,7 @@ module ActionView::Helpers::FormTagHelper # number_field_tag 'quantity', '1', class: 'special_input', disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#895 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#945 def number_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a password field, a masked text field that will hide the users input behind a mask character. @@ -8257,7 +8583,7 @@ module ActionView::Helpers::FormTagHelper # password_field_tag 'pin', '1234', maxlength: 4, size: 6, class: "pin_input" # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#377 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#380 def password_field_tag(name = T.unsafe(nil), value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text field of type "tel". @@ -8280,13 +8606,18 @@ module ActionView::Helpers::FormTagHelper # telephone_field_tag 'tel', '0123456789', class: 'special_input', disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#722 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#712 def phone_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end + # :call-seq: + # radio_button_tag(name, value, options = {}) + # radio_button_tag(name, value, checked, options = {}) + # # Creates a radio button; use groups of radio buttons named the same to allow users to # select from a group of options. # # ==== Options + # * :checked - If set to true, the radio button will be selected by default. # * :disabled - If set to true, the user will not be able to use this input. # * Any other key creates standard HTML options for the tag. # @@ -8303,8 +8634,8 @@ module ActionView::Helpers::FormTagHelper # radio_button_tag 'color', "green", true, class: "color_input" # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#469 - def radio_button_tag(name, value, checked = T.unsafe(nil), options = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#491 + def radio_button_tag(name, value, *args); end # Creates a range form element. # @@ -8312,7 +8643,18 @@ module ActionView::Helpers::FormTagHelper # # Supports the same options as #number_field_tag. # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#909 + # ==== Examples + # + # range_field_tag 'quantity', '1' + # # => + # + # range_field_tag 'quantity', in: 1...10 + # # => + # + # range_field_tag 'quantity', min: 1, max: 10, step: 2 + # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#699 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#689 def search_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a dropdown selection box, or if the :multiple option is set to true, a multiple @@ -8394,7 +8736,7 @@ module ActionView::Helpers::FormTagHelper # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#198 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#201 def select_tag(name, option_tags = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a submit button with the text value as the caption. @@ -8420,26 +8762,7 @@ module ActionView::Helpers::FormTagHelper # submit_tag "Edit", class: "edit_button" # # => # - # ==== Deprecated: Rails UJS attributes - # - # Prior to Rails 7, Rails shipped with the JavaScript library called @rails/ujs on by default. Following Rails 7, - # this library is no longer on by default. This library integrated with the following options: - # - # * confirm: 'question?' - If present the unobtrusive JavaScript - # drivers will provide a prompt with the question specified. If the user accepts, - # the form is processed normally, otherwise no action is taken. - # * :disable_with - Value of this parameter will be used as the value for a - # disabled version of the submit button when the form is submitted. This feature is - # provided by the unobtrusive JavaScript driver. To disable this feature for a single submit tag - # pass :data => { disable_with: false } Defaults to value attribute. - # - # submit_tag "Complete sale", data: { disable_with: "Submitting..." } - # # => - # - # submit_tag "Save", data: { confirm: "Are you sure?" } - # # => - # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#517 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#525 def submit_tag(value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text field of type "tel". @@ -8462,7 +8785,7 @@ module ActionView::Helpers::FormTagHelper # telephone_field_tag 'tel', '0123456789', class: 'special_input', disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#722 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#712 def telephone_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text input area; use a textarea for longer text inputs such as blog posts or descriptions. @@ -8495,7 +8818,7 @@ module ActionView::Helpers::FormTagHelper # text_area_tag 'comment', nil, class: 'comment_input' # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#410 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#413 def text_area_tag(name, content = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a standard text field; use these text fields to input smaller chunks of text like a username @@ -8535,7 +8858,7 @@ module ActionView::Helpers::FormTagHelper # text_field_tag 'ip', '0.0.0.0', maxlength: 15, size: 20, class: "ip-input" # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#260 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#263 def text_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text field of type "time". @@ -8549,7 +8872,24 @@ module ActionView::Helpers::FormTagHelper # * :step - The acceptable value granularity. # * :include_seconds - Include seconds and ms in the output timestamp format (true by default). # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#760 + # ==== Examples + # + # time_field_tag 'name' + # # => + # + # time_field_tag 'time', '01:01' + # # => + # + # time_field_tag 'time', nil, class: 'special_input' + # # => + # + # time_field_tag 'time', '01:01', include_seconds: true + # # => + # + # time_field_tag 'time', '01:01', min: '00:00', max: '23:59', step: 1 + # # => + # + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#767 def time_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates a text field of type "url". @@ -8572,13 +8912,13 @@ module ActionView::Helpers::FormTagHelper # url_field_tag 'url', 'http://rubyonrails.org', class: 'special_input', disabled: true # # => # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#824 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#874 def url_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end # Creates the hidden UTF-8 enforcer tag. Override this method in a helper # to customize the tag. # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#915 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#976 def utf8_enforcer_tag; end # Creates a text field of type "week". @@ -8591,50 +8931,66 @@ module ActionView::Helpers::FormTagHelper # * :max - The maximum acceptable value. # * :step - The acceptable value granularity. # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#801 + # ==== Examples + # + # week_field_tag 'name' + # # => + # + # week_field_tag 'week', '2014-W01' + # # => + # + # week_field_tag 'week', nil, class: 'special_input' + # # => + # + # week_field_tag 'week', '2014-W01', class: 'special_input', disabled: true + # # => + # + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#851 def week_field_tag(name, value = T.unsafe(nil), options = T.unsafe(nil)); end private - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#1011 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#1073 def convert_direct_upload_option_to_url(options); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#950 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#1011 def extra_tags_for_form(html_options); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#980 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#1041 def form_tag_html(html_options); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#985 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#1047 def form_tag_with_body(html_options, content); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#923 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#984 def html_options_for_form(url_for_options, options); end # see http://www.w3.org/TR/html4/types.html#type-name # - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#992 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#1054 def sanitize_to_id(name); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#996 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#1058 def set_default_disable_with(value, tag_options); end class << self - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#29 def default_enforce_utf8; end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#29 def default_enforce_utf8=(val); end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#23 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 def embed_authenticity_token_in_remote_forms; end - # source://actionview//lib/action_view/helpers/form_tag_helper.rb#23 + # source://actionview//lib/action_view/helpers/form_tag_helper.rb#26 def embed_authenticity_token_in_remote_forms=(val); end end end -# source://actionview//lib/action_view/helpers/javascript_helper.rb#5 +# = Action View JavaScript \Helpers +# +# source://actionview//lib/action_view/helpers/javascript_helper.rb#6 module ActionView::Helpers::JavaScriptHelper # Escapes carriage returns and single and double quotes for JavaScript segments. # @@ -8643,7 +8999,7 @@ module ActionView::Helpers::JavaScriptHelper # # $('some_element').replaceWith('<%= j render 'some/element_template' %>'); # - # source://actionview//lib/action_view/helpers/javascript_helper.rb#27 + # source://actionview//lib/action_view/helpers/javascript_helper.rb#28 def escape_javascript(javascript); end # Escapes carriage returns and single and double quotes for JavaScript segments. @@ -8653,10 +9009,10 @@ module ActionView::Helpers::JavaScriptHelper # # $('some_element').replaceWith('<%= j render 'some/element_template' %>'); # - # source://actionview//lib/action_view/helpers/javascript_helper.rb#27 + # source://actionview//lib/action_view/helpers/javascript_helper.rb#28 def j(javascript); end - # source://actionview//lib/action_view/helpers/javascript_helper.rb#90 + # source://actionview//lib/action_view/helpers/javascript_helper.rb#91 def javascript_cdata_section(content); end # Returns a JavaScript tag with the +content+ inside. Example: @@ -8695,13 +9051,15 @@ module ActionView::Helpers::JavaScriptHelper # alert('All is good') # <% end -%> # - # source://actionview//lib/action_view/helpers/javascript_helper.rb#74 + # source://actionview//lib/action_view/helpers/javascript_helper.rb#75 def javascript_tag(content_or_options_with_block = T.unsafe(nil), html_options = T.unsafe(nil), &block); end end -# source://actionview//lib/action_view/helpers/javascript_helper.rb#6 +# source://actionview//lib/action_view/helpers/javascript_helper.rb#7 ActionView::Helpers::JavaScriptHelper::JS_ESCAPE_MAP = T.let(T.unsafe(nil), Hash) +# = Action View Number \Helpers +# # Provides methods for converting numbers into formatted strings. # Methods are provided for phone numbers, currency, percentage, # precision, positional notation, file size, and pretty printing. @@ -8709,439 +9067,141 @@ ActionView::Helpers::JavaScriptHelper::JS_ESCAPE_MAP = T.let(T.unsafe(nil), Hash # Most methods expect a +number+ argument, and will return it # unchanged if can't be converted into a valid number. # -# source://actionview//lib/action_view/helpers/number_helper.rb#16 +# source://actionview//lib/action_view/helpers/number_helper.rb#17 module ActionView::Helpers::NumberHelper - # Formats a +number+ into a currency string (e.g., $13.65). You - # can customize the format in the +options+ hash. - # - # The currency unit and number formatting of the current locale will be used - # unless otherwise specified in the provided options. No currency conversion - # is performed. If the user is given a way to change their locale, they will - # also be able to change the relative value of the currency displayed with - # this helper. If your application will ever support multiple locales, you - # may want to specify a constant :locale option or consider - # using a library capable of currency conversion. - # - # ==== Options + # Delegates to ActiveSupport::NumberHelper#number_to_currency. # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the level of precision (defaults - # to 2). - # * :unit - Sets the denomination of the currency - # (defaults to "$"). - # * :separator - Sets the separator between the units - # (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ","). - # * :format - Sets the format for non-negative numbers - # (defaults to "%u%n"). Fields are %u for the - # currency, and %n for the number. - # * :negative_format - Sets the format for negative - # numbers (defaults to prepending a hyphen to the formatted - # number given by :format). Accepts the same fields - # than :format, except %n is here the - # absolute value of the number. - # * :raise - If true, raises +InvalidNumberError+ when - # the argument is invalid. - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +false+). + # Additionally, supports a +:raise+ option that will cause + # InvalidNumberError to be raised if +number+ is not a valid number: # - # ==== Examples + # number_to_currency("12x34") # => "$12x34" + # number_to_currency("12x34", raise: true) # => InvalidNumberError # - # number_to_currency(1234567890.50) # => $1,234,567,890.50 - # number_to_currency(1234567890.506) # => $1,234,567,890.51 - # number_to_currency(1234567890.506, precision: 3) # => $1,234,567,890.506 - # number_to_currency(1234567890.506, locale: :fr) # => 1 234 567 890,51 € - # number_to_currency("123a456") # => $123a456 - # - # number_to_currency("123a456", raise: true) # => InvalidNumberError - # - # number_to_currency(-0.456789, precision: 0) - # # => "$0" - # number_to_currency(-1234567890.50, negative_format: "(%u%n)") - # # => ($1,234,567,890.50) - # number_to_currency(1234567890.50, unit: "R$", separator: ",", delimiter: "") - # # => R$1234567890,50 - # number_to_currency(1234567890.50, unit: "R$", separator: ",", delimiter: "", format: "%n %u") - # # => 1234567890,50 R$ - # number_to_currency(1234567890.50, strip_insignificant_zeros: true) - # # => "$1,234,567,890.5" - # - # source://actionview//lib/action_view/helpers/number_helper.rb#127 + # source://actionview//lib/action_view/helpers/number_helper.rb#51 def number_to_currency(number, options = T.unsafe(nil)); end - # Pretty prints (formats and approximates) a number in a way it - # is more readable by humans (e.g.: 1200000000 becomes "1.2 - # Billion"). This is useful for numbers that can get very large - # (and too hard to read). - # - # See number_to_human_size if you want to print a file - # size. - # - # You can also define your own unit-quantifier names if you want - # to use other decimal units (e.g.: 1500 becomes "1.5 - # kilometers", 0.150 becomes "150 milliliters", etc). You may - # define a wide range of unit quantifiers, even fractional ones - # (centi, deci, mili, etc). + # Delegates to ActiveSupport::NumberHelper#number_to_human. # - # ==== Options - # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +true+) - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +true+) - # * :units - A Hash of unit quantifier names. Or a - # string containing an i18n scope where to find this hash. It - # might have the following keys: - # * *integers*: :unit, :ten, - # :hundred, :thousand, :million, - # :billion, :trillion, - # :quadrillion - # * *fractionals*: :deci, :centi, - # :mili, :micro, :nano, - # :pico, :femto - # * :format - Sets the format of the output string - # (defaults to "%n %u"). The field types are: - # * %u - The quantifier (ex.: 'thousand') - # * %n - The number - # * :raise - If true, raises +InvalidNumberError+ when - # the argument is invalid. + # Additionally, supports a +:raise+ option that will cause + # InvalidNumberError to be raised if +number+ is not a valid number: # - # ==== Examples + # number_to_human("12x34") # => "12x34" + # number_to_human("12x34", raise: true) # => InvalidNumberError # - # number_to_human(123) # => "123" - # number_to_human(1234) # => "1.23 Thousand" - # number_to_human(12345) # => "12.3 Thousand" - # number_to_human(1234567) # => "1.23 Million" - # number_to_human(1234567890) # => "1.23 Billion" - # number_to_human(1234567890123) # => "1.23 Trillion" - # number_to_human(1234567890123456) # => "1.23 Quadrillion" - # number_to_human(1234567890123456789) # => "1230 Quadrillion" - # number_to_human(489939, precision: 2) # => "490 Thousand" - # number_to_human(489939, precision: 4) # => "489.9 Thousand" - # number_to_human(1234567, precision: 4, - # significant: false) # => "1.2346 Million" - # number_to_human(1234567, precision: 1, - # separator: ',', - # significant: false) # => "1,2 Million" - # - # number_to_human(500000000, precision: 5) # => "500 Million" - # number_to_human(12345012345, significant: false) # => "12.345 Billion" - # - # Non-significant zeros after the decimal separator are stripped - # out by default (set :strip_insignificant_zeros to - # +false+ to change that): - # - # number_to_human(12.00001) # => "12" - # number_to_human(12.00001, strip_insignificant_zeros: false) # => "12.0" - # - # ==== Custom Unit Quantifiers - # - # You can also use your own custom unit quantifiers: - # - # number_to_human(500000, units: {unit: "ml", thousand: "lt"}) # => "500 lt" - # - # If in your I18n locale you have: - # distance: - # centi: - # one: "centimeter" - # other: "centimeters" - # unit: - # one: "meter" - # other: "meters" - # thousand: - # one: "kilometer" - # other: "kilometers" - # billion: "gazillion-distance" - # - # Then you could do: - # - # number_to_human(543934, units: :distance) # => "544 kilometers" - # number_to_human(54393498, units: :distance) # => "54400 kilometers" - # number_to_human(54393498000, units: :distance) # => "54.4 gazillion-distance" - # number_to_human(343, units: :distance, precision: 1) # => "300 meters" - # number_to_human(1, units: :distance) # => "1 meter" - # number_to_human(0.34, units: :distance) # => "34 centimeters" - # - # source://actionview//lib/action_view/helpers/number_helper.rb#404 + # source://actionview//lib/action_view/helpers/number_helper.rb#111 def number_to_human(number, options = T.unsafe(nil)); end - # Formats the bytes in +number+ into a more understandable - # representation (e.g., giving it 1500 yields 1.46 KB). This - # method is useful for reporting file sizes to users. You can - # customize the format in the +options+ hash. - # - # See number_to_human if you want to pretty-print a - # generic number. + # Delegates to ActiveSupport::NumberHelper#number_to_human_size. # - # ==== Options - # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +true+) - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +true+) - # * :raise - If true, raises +InvalidNumberError+ when - # the argument is invalid. + # Additionally, supports a +:raise+ option that will cause + # InvalidNumberError to be raised if +number+ is not a valid number: # - # ==== Examples + # number_to_human_size("12x34") # => "12x34" + # number_to_human_size("12x34", raise: true) # => InvalidNumberError # - # number_to_human_size(123) # => 123 Bytes - # number_to_human_size(1234) # => 1.21 KB - # number_to_human_size(12345) # => 12.1 KB - # number_to_human_size(1234567) # => 1.18 MB - # number_to_human_size(1234567890) # => 1.15 GB - # number_to_human_size(1234567890123) # => 1.12 TB - # number_to_human_size(1234567890123456) # => 1.1 PB - # number_to_human_size(1234567890123456789) # => 1.07 EB - # number_to_human_size(1234567, precision: 2) # => 1.2 MB - # number_to_human_size(483989, precision: 2) # => 470 KB - # number_to_human_size(1234567, precision: 2, separator: ',') # => 1,2 MB - # number_to_human_size(1234567890123, precision: 5) # => "1.1228 TB" - # number_to_human_size(524288000, precision: 5) # => "500 MB" - # - # source://actionview//lib/action_view/helpers/number_helper.rb#297 + # source://actionview//lib/action_view/helpers/number_helper.rb#99 def number_to_human_size(number, options = T.unsafe(nil)); end - # Formats a +number+ as a percentage string (e.g., 65%). You can - # customize the format in the +options+ hash. - # - # ==== Options - # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +false+). - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +false+). - # * :format - Specifies the format of the percentage - # string The number field is %n (defaults to "%n%"). - # * :raise - If true, raises +InvalidNumberError+ when - # the argument is invalid. - # - # ==== Examples + # Delegates to ActiveSupport::NumberHelper#number_to_percentage. # - # number_to_percentage(100) # => 100.000% - # number_to_percentage("98") # => 98.000% - # number_to_percentage(100, precision: 0) # => 100% - # number_to_percentage(1000, delimiter: '.', separator: ',') # => 1.000,000% - # number_to_percentage(302.24398923423, precision: 5) # => 302.24399% - # number_to_percentage(1000, locale: :fr) # => 1 000,000% - # number_to_percentage("98a") # => 98a% - # number_to_percentage(100, format: "%n %") # => 100.000 % + # Additionally, supports a +:raise+ option that will cause + # InvalidNumberError to be raised if +number+ is not a valid number: # - # number_to_percentage("98a", raise: true) # => InvalidNumberError + # number_to_percentage("99x") # => "99x%" + # number_to_percentage("99x", raise: true) # => InvalidNumberError # - # source://actionview//lib/action_view/helpers/number_helper.rb#167 + # source://actionview//lib/action_view/helpers/number_helper.rb#63 def number_to_percentage(number, options = T.unsafe(nil)); end - # Formats a +number+ into a phone number (US by default e.g., (555) - # 123-9876). You can customize the format in the +options+ hash. + # Delegates to ActiveSupport::NumberHelper#number_to_phone. # - # ==== Options - # - # * :area_code - Adds parentheses around the area code. - # * :delimiter - Specifies the delimiter to use - # (defaults to "-"). - # * :extension - Specifies an extension to add to the - # end of the generated number. - # * :country_code - Sets the country code for the phone - # number. - # * :pattern - Specifies how the number is divided into three - # groups with the custom regexp to override the default format. - # * :raise - If true, raises +InvalidNumberError+ when - # the argument is invalid. + # Additionally, supports a +:raise+ option that will cause + # InvalidNumberError to be raised if +number+ is not a valid number: # - # ==== Examples + # number_to_phone("12x34") # => "12x34" + # number_to_phone("12x34", raise: true) # => InvalidNumberError # - # number_to_phone(5551234) # => 555-1234 - # number_to_phone("5551234") # => 555-1234 - # number_to_phone(1235551234) # => 123-555-1234 - # number_to_phone(1235551234, area_code: true) # => (123) 555-1234 - # number_to_phone(1235551234, delimiter: " ") # => 123 555 1234 - # number_to_phone(1235551234, area_code: true, extension: 555) # => (123) 555-1234 x 555 - # number_to_phone(1235551234, country_code: 1) # => +1-123-555-1234 - # number_to_phone("123a456") # => 123a456 - # number_to_phone("1234a567", raise: true) # => InvalidNumberError - # - # number_to_phone(1235551234, country_code: 1, extension: 1343, delimiter: ".") - # # => +1.123.555.1234 x 1343 - # - # number_to_phone(75561234567, pattern: /(\d{1,4})(\d{4})(\d{4})$/, area_code: true) - # # => "(755) 6123-4567" - # number_to_phone(13312345678, pattern: /(\d{3})(\d{4})(\d{4})$/) - # # => "133-1234-5678" - # - # source://actionview//lib/action_view/helpers/number_helper.rb#62 + # source://actionview//lib/action_view/helpers/number_helper.rb#35 def number_to_phone(number, options = T.unsafe(nil)); end - # Formats a +number+ with grouped thousands using +delimiter+ - # (e.g., 12,324). You can customize the format in the +options+ - # hash. - # - # ==== Options - # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :delimiter - Sets the thousands delimiter (defaults - # to ","). - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter_pattern - Sets a custom regular expression used for - # deriving the placement of delimiter. Helpful when using currency formats - # like INR. - # * :raise - If true, raises +InvalidNumberError+ when - # the argument is invalid. - # - # ==== Examples + # Delegates to ActiveSupport::NumberHelper#number_to_delimited. # - # number_with_delimiter(12345678) # => 12,345,678 - # number_with_delimiter("123456") # => 123,456 - # number_with_delimiter(12345678.05) # => 12,345,678.05 - # number_with_delimiter(12345678, delimiter: ".") # => 12.345.678 - # number_with_delimiter(12345678, delimiter: ",") # => 12,345,678 - # number_with_delimiter(12345678.05, separator: " ") # => 12,345,678 05 - # number_with_delimiter(12345678.05, locale: :fr) # => 12 345 678,05 - # number_with_delimiter("112a") # => 112a - # number_with_delimiter(98765432.98, delimiter: " ", separator: ",") - # # => 98 765 432,98 + # Additionally, supports a +:raise+ option that will cause + # InvalidNumberError to be raised if +number+ is not a valid number: # - # number_with_delimiter("123456.78", - # delimiter_pattern: /(\d+?)(?=(\d\d)+(\d)(?!\d))/) # => "1,23,456.78" + # number_with_delimiter("12x34") # => "12x34" + # number_with_delimiter("12x34", raise: true) # => InvalidNumberError # - # number_with_delimiter("112a", raise: true) # => raise InvalidNumberError - # - # source://actionview//lib/action_view/helpers/number_helper.rb#206 + # source://actionview//lib/action_view/helpers/number_helper.rb#75 def number_with_delimiter(number, options = T.unsafe(nil)); end - # Formats a +number+ with the specified level of - # :precision (e.g., 112.32 has a precision of 2 if - # +:significant+ is +false+, and 5 if +:significant+ is +true+). - # You can customize the format in the +options+ hash. - # - # ==== Options - # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +false+). - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +false+). - # * :raise - If true, raises +InvalidNumberError+ when - # the argument is invalid. + # Delegates to ActiveSupport::NumberHelper#number_to_rounded. # - # ==== Examples - # - # number_with_precision(111.2345) # => 111.235 - # number_with_precision(111.2345, precision: 2) # => 111.23 - # number_with_precision(13, precision: 5) # => 13.00000 - # number_with_precision(389.32314, precision: 0) # => 389 - # number_with_precision(111.2345, significant: true) # => 111 - # number_with_precision(111.2345, precision: 1, significant: true) # => 100 - # number_with_precision(13, precision: 5, significant: true) # => 13.000 - # number_with_precision(111.234, locale: :fr) # => 111,234 + # Additionally, supports a +:raise+ option that will cause + # InvalidNumberError to be raised if +number+ is not a valid number: # - # number_with_precision(13, precision: 5, significant: true, strip_insignificant_zeros: true) - # # => 13 + # number_with_precision("12x34") # => "12x34" + # number_with_precision("12x34", raise: true) # => InvalidNumberError # - # number_with_precision(389.32314, precision: 4, significant: true) # => 389.3 - # number_with_precision(1111.2345, precision: 2, separator: ',', delimiter: '.') - # # => 1.111,23 - # - # source://actionview//lib/action_view/helpers/number_helper.rb#251 + # source://actionview//lib/action_view/helpers/number_helper.rb#87 def number_with_precision(number, options = T.unsafe(nil)); end private - # source://actionview//lib/action_view/helpers/number_helper.rb#409 + # source://actionview//lib/action_view/helpers/number_helper.rb#116 def delegate_number_helper_method(method, number, options); end - # source://actionview//lib/action_view/helpers/number_helper.rb#428 + # source://actionview//lib/action_view/helpers/number_helper.rb#135 def escape_units(units); end - # source://actionview//lib/action_view/helpers/number_helper.rb#418 + # source://actionview//lib/action_view/helpers/number_helper.rb#125 def escape_unsafe_options(options); end # @raise [InvalidNumberError] # - # source://actionview//lib/action_view/helpers/number_helper.rb#451 + # source://actionview//lib/action_view/helpers/number_helper.rb#158 def parse_float(number, raise_error); end # @return [Boolean] # - # source://actionview//lib/action_view/helpers/number_helper.rb#447 + # source://actionview//lib/action_view/helpers/number_helper.rb#154 def valid_float?(number); end # @raise [InvalidNumberError] # - # source://actionview//lib/action_view/helpers/number_helper.rb#434 + # source://actionview//lib/action_view/helpers/number_helper.rb#141 def wrap_with_output_safety_handling(number, raise_on_invalid, &block); end end # Raised when argument +number+ param given to the helpers is invalid and # the option +:raise+ is set to +true+. # -# source://actionview//lib/action_view/helpers/number_helper.rb#19 +# source://actionview//lib/action_view/helpers/number_helper.rb#20 class ActionView::Helpers::NumberHelper::InvalidNumberError < ::StandardError # @return [InvalidNumberError] a new instance of InvalidNumberError # - # source://actionview//lib/action_view/helpers/number_helper.rb#21 + # source://actionview//lib/action_view/helpers/number_helper.rb#22 def initialize(number); end # Returns the value of attribute number. # - # source://actionview//lib/action_view/helpers/number_helper.rb#20 + # source://actionview//lib/action_view/helpers/number_helper.rb#21 def number; end # Sets the attribute number # # @param value the value to set the attribute number to. # - # source://actionview//lib/action_view/helpers/number_helper.rb#20 + # source://actionview//lib/action_view/helpers/number_helper.rb#21 def number=(_arg0); end end +# = Action View Raw Output \Helpers +# # source://actionview//lib/action_view/helpers/output_safety_helper.rb#8 module ActionView::Helpers::OutputSafetyHelper # This method outputs without escaping a string. Since escaping tags is - # now default, this can be used when you don't want Rails to automatically + # now default, this can be used when you don't want \Rails to automatically # escape tags. This is not recommended if the data is coming from the user's # input. # @@ -9158,11 +9218,11 @@ module ActionView::Helpers::OutputSafetyHelper # the supplied separator, are HTML escaped unless they are HTML # safe, and the returned string is marked as HTML safe. # - # safe_join([raw("

foo

"), "

bar

"], "
") - # # => "

foo

<br /><p>bar</p>" + # safe_join([tag.p("foo"), "

bar

"], "
") + # # => "

foo

<br><p>bar</p>" # - # safe_join([raw("

foo

"), raw("

bar

")], raw("
")) - # # => "

foo


bar

" + # safe_join([tag.p("foo"), tag.p("bar")], tag.br) + # # => "

foo


bar

" # # source://actionview//lib/action_view/helpers/output_safety_helper.rb#33 def safe_join(array, sep = T.unsafe(nil)); end @@ -9175,7 +9235,7 @@ module ActionView::Helpers::OutputSafetyHelper def to_sentence(array, options = T.unsafe(nil)); end end -# = Action View Rendering +# = Action View \Rendering \Helpers # # Implements methods that allow rendering from a view context. # In order to use this module, all you need is to implement @@ -9258,10 +9318,12 @@ module ActionView::Helpers::RenderingHelper def render(options = T.unsafe(nil), locals = T.unsafe(nil), &block); end end +# = Action View Sanitize \Helpers +# # The SanitizeHelper module provides a set of methods for scrubbing text of undesired HTML elements. # These helper methods extend Action View making them callable within your template files. # -# source://actionview//lib/action_view/helpers/sanitize_helper.rb#10 +# source://actionview//lib/action_view/helpers/sanitize_helper.rb#11 module ActionView::Helpers::SanitizeHelper extend ::ActiveSupport::Concern @@ -9269,12 +9331,11 @@ module ActionView::Helpers::SanitizeHelper # Sanitizes HTML input, stripping all but known-safe tags and attributes. # - # It also strips href/src attributes with unsafe protocols like - # javascript:, while also protecting against attempts to use Unicode, - # ASCII, and hex character references to work around these protocol filters. - # All special characters will be escaped. + # It also strips +href+ / +src+ attributes with unsafe protocols like +javascript:+, while + # also protecting against attempts to use Unicode, ASCII, and hex character references to work + # around these protocol filters. # - # The default sanitizer is Rails::Html::SafeListSanitizer. See {Rails HTML + # The default sanitizer is +Rails::HTML5::SafeListSanitizer+. See {Rails HTML # Sanitizers}[https://github.com/rails/rails-html-sanitizer] for more information. # # Custom sanitization rules can also be provided. @@ -9284,26 +9345,31 @@ module ActionView::Helpers::SanitizeHelper # # ==== Options # - # * :tags - An array of allowed tags. - # * :attributes - An array of allowed attributes. - # * :scrubber - A {Rails::Html scrubber}[https://github.com/rails/rails-html-sanitizer] + # [+:tags+] + # An array of allowed tags. + # + # [+:attributes+] + # An array of allowed attributes. + # + # [+:scrubber+] + # A {Rails::HTML scrubber}[https://github.com/rails/rails-html-sanitizer] # or {Loofah::Scrubber}[https://github.com/flavorjones/loofah] object that # defines custom sanitization rules. A custom scrubber takes precedence over # custom tags and attributes. # # ==== Examples # - # Normal use: + # ===== Normal use # # <%= sanitize @comment.body %> # - # Providing custom lists of permitted tags and attributes: + # ===== Providing custom lists of permitted tags and attributes # # <%= sanitize @comment.body, tags: %w(strong em a), attributes: %w(href) %> # - # Providing a custom Rails::Html scrubber: + # ===== Providing a custom +Rails::HTML+ scrubber # - # class CommentScrubber < Rails::Html::PermitScrubber + # class CommentScrubber < Rails::HTML::PermitScrubber # def initialize # super # self.tags = %w( form script comment blockquote ) @@ -9315,21 +9381,27 @@ module ActionView::Helpers::SanitizeHelper # end # end # + # + # # <%= sanitize @comment.body, scrubber: CommentScrubber.new %> # # See {Rails HTML Sanitizer}[https://github.com/rails/rails-html-sanitizer] for - # documentation about Rails::Html scrubbers. + # documentation about +Rails::HTML+ scrubbers. # - # Providing a custom Loofah::Scrubber: + # ===== Providing a custom +Loofah::Scrubber+ # # scrubber = Loofah::Scrubber.new do |node| # node.remove if node.name == 'script' # end # + # + # # <%= sanitize @comment.body, scrubber: scrubber %> # # See {Loofah's documentation}[https://github.com/flavorjones/loofah] for more - # information about defining custom Loofah::Scrubber objects. + # information about defining custom +Loofah::Scrubber+ objects. + # + # ==== Global Configuration # # To set the default allowed tags or attributes across your application: # @@ -9337,14 +9409,36 @@ module ActionView::Helpers::SanitizeHelper # config.action_view.sanitized_allowed_tags = ['strong', 'em', 'a'] # config.action_view.sanitized_allowed_attributes = ['href', 'title'] # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#81 + # The default, starting in \Rails 7.1, is to use an HTML5 parser for sanitization (if it is + # available, see NOTE below). If you wish to revert back to the previous HTML4 behavior, you + # can do so by setting the following in your application configuration: + # + # # In config/application.rb + # config.action_view.sanitizer_vendor = Rails::HTML4::Sanitizer + # + # Or, if you're upgrading from a previous version of \Rails and wish to opt into the HTML5 + # behavior: + # + # # In config/application.rb + # config.action_view.sanitizer_vendor = Rails::HTML5::Sanitizer + # + # NOTE: +Rails::HTML5::Sanitizer+ is not supported on JRuby, so on JRuby platforms \Rails will + # fall back to using +Rails::HTML4::Sanitizer+. + # + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#111 def sanitize(html, options = T.unsafe(nil)); end - # Sanitizes a block of CSS code. Used by +sanitize+ when it comes across a style attribute. + # Sanitizes a block of CSS code. Used by #sanitize when it comes across a style attribute. # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#86 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#116 def sanitize_css(style); end + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor; end + + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor=(val); end + # Strips all link tags from +html+ leaving just the link text. # # strip_links('Ruby on Rails') @@ -9359,7 +9453,7 @@ module ActionView::Helpers::SanitizeHelper # strip_links('<malformed & link') # # => <malformed & link # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#120 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#150 def strip_links(html); end # Strips all HTML tags from +html+, including comments and special characters. @@ -9376,64 +9470,72 @@ module ActionView::Helpers::SanitizeHelper # strip_tags("> A quote from Smith & Wesson") # # => > A quote from Smith & Wesson # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#103 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#133 def strip_tags(html); end + + class << self + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor; end + + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor=(val); end + end end -# source://actionview//lib/action_view/helpers/sanitize_helper.rb#124 +# source://actionview//lib/action_view/helpers/sanitize_helper.rb#154 module ActionView::Helpers::SanitizeHelper::ClassMethods - # Gets the Rails::Html::FullSanitizer instance used by +strip_tags+. Replace with + # Gets the Rails::HTML::FullSanitizer instance used by +strip_tags+. Replace with # any object that responds to +sanitize+. # # class Application < Rails::Application # config.action_view.full_sanitizer = MySpecialSanitizer.new # end # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#145 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#175 def full_sanitizer; end # Sets the attribute full_sanitizer # # @param value the value to set the attribute full_sanitizer to. # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#125 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#155 def full_sanitizer=(_arg0); end - # Gets the Rails::Html::LinkSanitizer instance used by +strip_links+. + # Gets the Rails::HTML::LinkSanitizer instance used by +strip_links+. # Replace with any object that responds to +sanitize+. # # class Application < Rails::Application # config.action_view.link_sanitizer = MySpecialSanitizer.new # end # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#155 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#185 def link_sanitizer; end # Sets the attribute link_sanitizer # # @param value the value to set the attribute link_sanitizer to. # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#125 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#155 def link_sanitizer=(_arg0); end - # Gets the Rails::Html::SafeListSanitizer instance used by sanitize and +sanitize_css+. + # Gets the Rails::HTML::SafeListSanitizer instance used by sanitize and +sanitize_css+. # Replace with any object that responds to +sanitize+. # # class Application < Rails::Application # config.action_view.safe_list_sanitizer = MySpecialSanitizer.new # end # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#165 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#195 def safe_list_sanitizer; end # Sets the attribute safe_list_sanitizer # # @param value the value to set the attribute safe_list_sanitizer to. # - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#125 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#155 def safe_list_sanitizer=(_arg0); end - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#135 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#165 def sanitized_allowed_attributes; end # source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#34 @@ -9457,7 +9559,7 @@ module ActionView::Helpers::SanitizeHelper::ClassMethods # source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#48 def sanitized_allowed_protocols=(_); end - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#131 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#161 def sanitized_allowed_tags; end # source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#24 @@ -9487,7 +9589,7 @@ module ActionView::Helpers::SanitizeHelper::ClassMethods # source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#48 def sanitized_uri_attributes=(_); end - # source://actionview//lib/action_view/helpers/sanitize_helper.rb#127 + # source://actionview//lib/action_view/helpers/sanitize_helper.rb#157 def sanitizer_vendor; end private @@ -9496,10 +9598,12 @@ module ActionView::Helpers::SanitizeHelper::ClassMethods def deprecate_option(name); end end +# = Action View Tag \Helpers +# # Provides methods to generate HTML tags programmatically both as a modern # HTML5 compliant builder style and legacy XHTML compliant tags. # -# source://actionview//lib/action_view/helpers/tag_helper.rb#14 +# source://actionview//lib/action_view/helpers/tag_helper.rb#17 module ActionView::Helpers::TagHelper include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper @@ -9518,7 +9622,7 @@ module ActionView::Helpers::TagHelper # cdata_section("hello]]>world") # # => world]]> # - # source://actionview//lib/action_view/helpers/tag_helper.rb#408 + # source://actionview//lib/action_view/helpers/tag_helper.rb#571 def cdata_section(content); end # Returns a string of tokens built from +args+. @@ -9533,7 +9637,7 @@ module ActionView::Helpers::TagHelper # token_list(nil, false, 123, "", "foo", { bar: true }) # # => "123 foo bar" # - # source://actionview//lib/action_view/helpers/tag_helper.rb#388 + # source://actionview//lib/action_view/helpers/tag_helper.rb#551 def class_names(*args); end # Returns an HTML block tag of type +name+ surrounding the +content+. Add @@ -9565,7 +9669,7 @@ module ActionView::Helpers::TagHelper # <% end -%> # # =>
Hello world!
# - # source://actionview//lib/action_view/helpers/tag_helper.rb#368 + # source://actionview//lib/action_view/helpers/tag_helper.rb#529 def content_tag(name, content_or_options_with_block = T.unsafe(nil), options = T.unsafe(nil), escape = T.unsafe(nil), &block); end # Returns an escaped version of +html+ without affecting existing escaped entities. @@ -9576,7 +9680,7 @@ module ActionView::Helpers::TagHelper # escape_once("<< Accept & Checkout") # # => "<< Accept & Checkout" # - # source://actionview//lib/action_view/helpers/tag_helper.rb#420 + # source://actionview//lib/action_view/helpers/tag_helper.rb#583 def escape_once(html); end # Returns an HTML tag. @@ -9656,6 +9760,14 @@ module ActionView::Helpers::TagHelper # # A void element: # tag.br # =>
# + # Note that when using the block form options should be wrapped in + # parenthesis. + # + # <%= tag.a(href: "/about", class: "font-bold") do %> + # About the author + # <% end %> + # # => About the author + # # === Building HTML attributes # # Transforms a Hash into HTML attributes, ready to be interpolated into @@ -9672,7 +9784,7 @@ module ActionView::Helpers::TagHelper # # === Legacy syntax # - # The following format is for legacy syntax support. It will be deprecated in future versions of Rails. + # The following format is for legacy syntax support. It will be deprecated in future versions of \Rails. # # tag(name, options = nil, open = false, escape = true) # @@ -9718,7 +9830,7 @@ module ActionView::Helpers::TagHelper # tag("div", class: { highlight: current_user.admin? }) # # =>
# - # source://actionview//lib/action_view/helpers/tag_helper.rb#331 + # source://actionview//lib/action_view/helpers/tag_helper.rb#492 def tag(name = T.unsafe(nil), options = T.unsafe(nil), open = T.unsafe(nil), escape = T.unsafe(nil)); end # Returns a string of tokens built from +args+. @@ -9733,216 +9845,601 @@ module ActionView::Helpers::TagHelper # token_list(nil, false, 123, "", "foo", { bar: true }) # # => "123 foo bar" # - # source://actionview//lib/action_view/helpers/tag_helper.rb#388 + # source://actionview//lib/action_view/helpers/tag_helper.rb#551 def token_list(*args); end private - # source://actionview//lib/action_view/helpers/tag_helper.rb#425 + # source://actionview//lib/action_view/helpers/tag_helper.rb#593 def build_tag_values(*args); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#445 + # @raise [ArgumentError] + # + # source://actionview//lib/action_view/helpers/tag_helper.rb#588 + def ensure_valid_html5_tag_name(name); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#613 def tag_builder; end class << self - # source://actionview//lib/action_view/helpers/tag_helper.rb#425 + # source://actionview//lib/action_view/helpers/tag_helper.rb#593 def build_tag_values(*args); end + + # @raise [ArgumentError] + # + # source://actionview//lib/action_view/helpers/tag_helper.rb#588 + def ensure_valid_html5_tag_name(name); end end end -# source://actionview//lib/action_view/helpers/tag_helper.rb#31 +# source://actionview//lib/action_view/helpers/tag_helper.rb#34 ActionView::Helpers::TagHelper::ARIA_PREFIXES = T.let(T.unsafe(nil), Set) -# source://actionview//lib/action_view/helpers/tag_helper.rb#18 +# source://actionview//lib/action_view/helpers/tag_helper.rb#21 ActionView::Helpers::TagHelper::BOOLEAN_ATTRIBUTES = T.let(T.unsafe(nil), Set) -# source://actionview//lib/action_view/helpers/tag_helper.rb#32 +# source://actionview//lib/action_view/helpers/tag_helper.rb#35 ActionView::Helpers::TagHelper::DATA_PREFIXES = T.let(T.unsafe(nil), Set) -# source://actionview//lib/action_view/helpers/tag_helper.rb#40 +# source://actionview//lib/action_view/helpers/tag_helper.rb#43 ActionView::Helpers::TagHelper::PRE_CONTENT_STRINGS = T.let(T.unsafe(nil), Hash) -# source://actionview//lib/action_view/helpers/tag_helper.rb#34 +# source://actionview//lib/action_view/helpers/tag_helper.rb#37 ActionView::Helpers::TagHelper::TAG_TYPES = T.let(T.unsafe(nil), Hash) -# source://actionview//lib/action_view/helpers/tag_helper.rb#44 +# source://actionview//lib/action_view/helpers/tag_helper.rb#47 class ActionView::Helpers::TagHelper::TagBuilder include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper # @return [TagBuilder] a new instance of TagBuilder # - # source://actionview//lib/action_view/helpers/tag_helper.rb#51 + # source://actionview//lib/action_view/helpers/tag_helper.rb#229 def initialize(view_context); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#390 + def a(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#393 + def abbr(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#396 + def address(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#292 + def animate(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#299 + def animate_motion(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#306 + def animate_transform(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#96 + def area(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#399 + def article(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#402 + def aside(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + # Transforms a Hash into HTML Attributes, ready to be interpolated into # ERB. # # > # # => # - # source://actionview//lib/action_view/helpers/tag_helper.rb#60 + # source://actionview//lib/action_view/helpers/tag_helper.rb#238 def attributes(attributes); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#133 - def boolean_tag_option(key); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#405 + def audio(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#80 - def content_tag_string(name, content, options, escape = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#408 + def b(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#64 - def p(*arguments, **options, &block); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#110 + def base(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#137 - def tag_option(key, value, escape); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#411 + def bdi(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#91 - def tag_options(options, escape = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#414 + def bdo(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#68 - def tag_string(name, content = T.unsafe(nil), **options, &block); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#417 + def blockquote(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - private + # source://actionview//lib/action_view/helpers/tag_helper.rb#420 + def body(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#167 - def handle_deprecated_escape_options(options); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#303 + def boolean_tag_option(key); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#188 - def method_missing(called, *args, **options, &block); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#124 + def br(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tag_helper.rb#155 - def prefix_tag_option(prefix, key, value, escape); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#423 + def button(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # @return [Boolean] - # - # source://actionview//lib/action_view/helpers/tag_helper.rb#163 - def respond_to_missing?(*args); end -end + # source://actionview//lib/action_view/helpers/tag_helper.rb#426 + def canvas(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end -# source://actionview//lib/action_view/helpers/tag_helper.rb#48 -ActionView::Helpers::TagHelper::TagBuilder::HTML_VOID_ELEMENTS = T.let(T.unsafe(nil), Set) + # source://actionview//lib/action_view/helpers/tag_helper.rb#429 + def caption(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end -# source://actionview//lib/action_view/helpers/tag_helper.rb#49 -ActionView::Helpers::TagHelper::TagBuilder::SVG_SELF_CLOSING_ELEMENTS = T.let(T.unsafe(nil), Set) + # source://actionview//lib/action_view/helpers/tag_helper.rb#313 + def circle(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end -# source://actionview//lib/action_view/helpers/tags.rb#5 -module ActionView::Helpers::Tags - extend ::ActiveSupport::Autoload -end + # source://actionview//lib/action_view/helpers/tag_helper.rb#432 + def cite(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end -# source://actionview//lib/action_view/helpers/tags/base.rb#6 -class ActionView::Helpers::Tags::Base - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::ActionView::Helpers::UrlHelper - include ::ActionView::Helpers::SanitizeHelper - include ::ActionView::Helpers::TextHelper - include ::ActionView::Helpers::FormTagHelper - include ::ActionView::Helpers::ActiveModelInstanceTag - include ::ActionView::Helpers::FormOptionsHelper - extend ::ActionView::Helpers::UrlHelper::ClassMethods - extend ::ActionView::Helpers::SanitizeHelper::ClassMethods + # source://actionview//lib/action_view/helpers/tag_helper.rb#435 + def code(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # @return [Base] a new instance of Base - # - # source://actionview//lib/action_view/helpers/tags/base.rb#12 - def initialize(object_name, method_name, template_object, options = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#138 + def col(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # Returns the value of attribute object. - # - # source://actionview//lib/action_view/helpers/tags/base.rb#10 - def object; end + # source://actionview//lib/action_view/helpers/tag_helper.rb#438 + def colgroup(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # This is what child classes implement. - # - # @raise [NotImplementedError] - # - # source://actionview//lib/action_view/helpers/tags/base.rb#32 - def render; end + # source://actionview//lib/action_view/helpers/tag_helper.rb#252 + def content_tag_string(name, content, options, escape = T.unsafe(nil)); end - private + # source://actionview//lib/action_view/helpers/tag_helper.rb#441 + def data(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#95 - def add_default_name_and_id(options); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#444 + def datalist(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#82 - def add_default_name_and_id_for_value(tag_value, options); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#447 + def dd(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#147 - def add_options(option_tags, options, value = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#450 + def del(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # @return [Boolean] - # - # source://actionview//lib/action_view/helpers/tags/base.rb#173 - def generate_ids?; end + # source://actionview//lib/action_view/helpers/tag_helper.rb#453 + def details(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#165 - def name_and_id_index(options); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#456 + def dfn(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # @return [Boolean] - # - # source://actionview//lib/action_view/helpers/tags/base.rb#142 - def placeholder_required?(html_options); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#459 + def dialog(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#73 - def retrieve_autoindex(pre_match); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#462 + def div(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#62 - def retrieve_object(object); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#465 + def dl(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#115 - def sanitized_method_name; end + # source://actionview//lib/action_view/helpers/tag_helper.rb#468 + def dt(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#119 - def sanitized_value(value); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#320 + def ellipse(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#123 - def select_content_tag(option_tags, options, html_options); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#471 + def em(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#111 - def tag_id(index = T.unsafe(nil), namespace = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#152 + def embed(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#107 - def tag_name(multiple = T.unsafe(nil), index = T.unsafe(nil)); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#474 + def fieldset(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#37 - def value; end + # source://actionview//lib/action_view/helpers/tag_helper.rb#477 + def figcaption(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/base.rb#45 - def value_before_type_cast; end + # source://actionview//lib/action_view/helpers/tag_helper.rb#480 + def figure(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # @return [Boolean] - # - # source://actionview//lib/action_view/helpers/tags/base.rb#57 - def value_came_from_user?; end -end + # source://actionview//lib/action_view/helpers/tag_helper.rb#483 + def footer(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end -# source://actionview//lib/action_view/helpers/tags/check_box.rb#8 -class ActionView::Helpers::Tags::CheckBox < ::ActionView::Helpers::Tags::Base - include ::ActionView::Helpers::Tags::Checkable + # source://actionview//lib/action_view/helpers/tag_helper.rb#486 + def form(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # @return [CheckBox] a new instance of CheckBox - # - # source://actionview//lib/action_view/helpers/tags/check_box.rb#11 - def initialize(object_name, method_name, template_object, checked_value, unchecked_value, options); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#489 + def h1(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/check_box.rb#17 - def render; end + # source://actionview//lib/action_view/helpers/tag_helper.rb#492 + def h2(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - private + # source://actionview//lib/action_view/helpers/tag_helper.rb#495 + def h3(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # @return [Boolean] - # - # source://actionview//lib/action_view/helpers/tags/check_box.rb#42 - def checked?(value); end + # source://actionview//lib/action_view/helpers/tag_helper.rb#498 + def h4(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end - # source://actionview//lib/action_view/helpers/tags/check_box.rb#59 - def hidden_field_for_checkbox(options); end -end + # source://actionview//lib/action_view/helpers/tag_helper.rb#501 + def h5(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end -# source://actionview//lib/action_view/helpers/tags/checkable.rb#6 -module ActionView::Helpers::Tags::Checkable + # source://actionview//lib/action_view/helpers/tag_helper.rb#504 + def h6(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#507 + def head(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#510 + def header(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#513 + def hgroup(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#166 + def hr(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#516 + def html(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#519 + def i(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#522 + def iframe(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#180 + def img(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#194 + def input(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#525 + def ins(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#528 + def kbd(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#208 + def keygen(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#531 + def label(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#534 + def legend(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#537 + def li(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#327 + def line(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#222 + def link(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#540 + def main(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#543 + def map(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#546 + def mark(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#549 + def menu(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#236 + def meta(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#552 + def meter(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#555 + def nav(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#558 + def noscript(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#561 + def object(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#564 + def ol(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#567 + def optgroup(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#570 + def option(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#573 + def output(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#576 + def p(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#334 + def path(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#579 + def picture(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#341 + def polygon(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#348 + def polyline(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#582 + def portal(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#585 + def pre(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#588 + def progress(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#591 + def q(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#355 + def rect(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#594 + def rp(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#597 + def rt(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#600 + def ruby(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#603 + def s(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#606 + def samp(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#609 + def script(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#612 + def search(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#615 + def section(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#618 + def select(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#248 + def self_closing_tag_string(name, options, escape = T.unsafe(nil), tag_suffix = T.unsafe(nil)); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#362 + def set(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#621 + def slot(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#624 + def small(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#250 + def source(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#627 + def span(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#369 + def stop(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#630 + def strong(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#633 + def style(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#636 + def sub(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#639 + def summary(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#642 + def sup(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#645 + def table(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#307 + def tag_option(key, value, escape); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#261 + def tag_options(options, escape = T.unsafe(nil)); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#242 + def tag_string(name, content = T.unsafe(nil), options, escape: T.unsafe(nil), &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#648 + def tbody(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#651 + def td(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#654 + def template(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#657 + def textarea(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#660 + def tfoot(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#663 + def th(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#666 + def thead(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#669 + def time(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#672 + def title(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#675 + def tr(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#264 + def track(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#678 + def u(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#681 + def ul(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#376 + def use(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#684 + def var(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#687 + def video(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#383 + def view(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#278 + def wbr(content = T.unsafe(nil), escape: T.unsafe(nil), **options, &block); end + + private + + # source://actionview//lib/action_view/helpers/tag_helper.rb#337 + def method_missing(called, *args, escape: T.unsafe(nil), **options, &block); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#325 + def prefix_tag_option(prefix, key, value, escape); end + + # @return [Boolean] + # + # source://actionview//lib/action_view/helpers/tag_helper.rb#333 + def respond_to_missing?(*args); end + + class << self + # source://actionview//lib/action_view/helpers/tag_helper.rb#51 + def define_element(name, code_generator:, method_name: T.unsafe(nil)); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#82 + def define_self_closing_element(name, code_generator:, method_name: T.unsafe(nil)); end + + # source://actionview//lib/action_view/helpers/tag_helper.rb#61 + def define_void_element(name, code_generator:, method_name: T.unsafe(nil)); end + end +end + +# source://actionview//lib/action_view/helpers/tags.rb#5 +module ActionView::Helpers::Tags + extend ::ActiveSupport::Autoload +end + +# source://actionview//lib/action_view/helpers/tags/base.rb#6 +class ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::ActionView::Helpers::ContentExfiltrationPreventionHelper + include ::ActionView::Helpers::UrlHelper + include ::ActionView::Helpers::SanitizeHelper + include ::ActionView::Helpers::TextHelper + include ::ActionView::Helpers::FormTagHelper + include ::ActionView::Helpers::ActiveModelInstanceTag + extend ::ActionView::Helpers::UrlHelper::ClassMethods + extend ::ActionView::Helpers::SanitizeHelper::ClassMethods + + # @return [Base] a new instance of Base + # + # source://actionview//lib/action_view/helpers/tags/base.rb#11 + def initialize(object_name, method_name, template_object, options = T.unsafe(nil)); end + + # Returns the value of attribute object. + # + # source://actionview//lib/action_view/helpers/tags/base.rb#9 + def object; end + + # This is what child classes implement. + # + # @raise [NotImplementedError] + # + # source://actionview//lib/action_view/helpers/tags/base.rb#31 + def render; end + + private + + # source://actionview//lib/action_view/helpers/tags/base.rb#96 + def add_default_name_and_id(options); end + + # source://actionview//lib/action_view/helpers/tags/base.rb#83 + def add_default_name_and_id_for_value(tag_value, options); end + + # @return [Boolean] + # + # source://actionview//lib/action_view/helpers/tags/base.rb#132 + def generate_ids?; end + + # source://actionview//lib/action_view/helpers/tags/base.rb#124 + def name_and_id_index(options); end + + # source://actionview//lib/action_view/helpers/tags/base.rb#74 + def retrieve_autoindex(pre_match); end + + # source://actionview//lib/action_view/helpers/tags/base.rb#63 + def retrieve_object(object); end + + # source://actionview//lib/action_view/helpers/tags/base.rb#116 + def sanitized_method_name; end + + # source://actionview//lib/action_view/helpers/tags/base.rb#120 + def sanitized_value(value); end + + # source://actionview//lib/action_view/helpers/tags/base.rb#112 + def tag_id(index = T.unsafe(nil), namespace = T.unsafe(nil)); end + + # source://actionview//lib/action_view/helpers/tags/base.rb#108 + def tag_name(multiple = T.unsafe(nil), index = T.unsafe(nil)); end + + # source://actionview//lib/action_view/helpers/tags/base.rb#36 + def value; end + + # source://actionview//lib/action_view/helpers/tags/base.rb#46 + def value_before_type_cast; end + + # @return [Boolean] + # + # source://actionview//lib/action_view/helpers/tags/base.rb#58 + def value_came_from_user?; end +end + +# source://actionview//lib/action_view/helpers/tags/check_box.rb#8 +class ActionView::Helpers::Tags::CheckBox < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::Checkable + + # @return [CheckBox] a new instance of CheckBox + # + # source://actionview//lib/action_view/helpers/tags/check_box.rb#11 + def initialize(object_name, method_name, template_object, checked_value, unchecked_value, options); end + + # source://actionview//lib/action_view/helpers/tags/check_box.rb#17 + def render; end + + private + + # @return [Boolean] + # + # source://actionview//lib/action_view/helpers/tags/check_box.rb#42 + def checked?(value); end + + # source://actionview//lib/action_view/helpers/tags/check_box.rb#59 + def hidden_field_for_checkbox(options); end +end + +# source://actionview//lib/action_view/helpers/tags/checkable.rb#6 +module ActionView::Helpers::Tags::Checkable # @return [Boolean] # # source://actionview//lib/action_view/helpers/tags/checkable.rb#7 @@ -9952,22 +10449,23 @@ end # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#8 class ActionView::Helpers::Tags::CollectionCheckBoxes < ::ActionView::Helpers::Tags::Base include ::ActionView::Helpers::Tags::CollectionHelpers + include ::ActionView::Helpers::FormOptionsHelper - # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#20 + # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#21 def render(&block); end private - # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#29 + # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#30 def hidden_field_name; end - # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#25 + # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#26 def render_component(builder); end end -# source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#11 +# source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#12 class ActionView::Helpers::Tags::CollectionCheckBoxes::CheckBoxBuilder < ::ActionView::Helpers::Tags::CollectionHelpers::Builder - # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#12 + # source://actionview//lib/action_view/helpers/tags/collection_check_boxes.rb#13 def check_box(extra_html_options = T.unsafe(nil)); end end @@ -10032,30 +10530,34 @@ end # source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#8 class ActionView::Helpers::Tags::CollectionRadioButtons < ::ActionView::Helpers::Tags::Base include ::ActionView::Helpers::Tags::CollectionHelpers + include ::ActionView::Helpers::FormOptionsHelper - # source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#19 + # source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#20 def render(&block); end private - # source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#24 + # source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#25 def render_component(builder); end end -# source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#11 +# source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#12 class ActionView::Helpers::Tags::CollectionRadioButtons::RadioButtonBuilder < ::ActionView::Helpers::Tags::CollectionHelpers::Builder - # source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#12 + # source://actionview//lib/action_view/helpers/tags/collection_radio_buttons.rb#13 def radio_button(extra_html_options = T.unsafe(nil)); end end # source://actionview//lib/action_view/helpers/tags/collection_select.rb#6 class ActionView::Helpers::Tags::CollectionSelect < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::SelectRenderer + include ::ActionView::Helpers::FormOptionsHelper + # @return [CollectionSelect] a new instance of CollectionSelect # - # source://actionview//lib/action_view/helpers/tags/collection_select.rb#7 + # source://actionview//lib/action_view/helpers/tags/collection_select.rb#10 def initialize(object_name, method_name, template_object, collection, value_method, text_method, options, html_options); end - # source://actionview//lib/action_view/helpers/tags/collection_select.rb#16 + # source://actionview//lib/action_view/helpers/tags/collection_select.rb#19 def render; end end @@ -10075,32 +10577,34 @@ class ActionView::Helpers::Tags::DateField < ::ActionView::Helpers::Tags::Dateti private # source://actionview//lib/action_view/helpers/tags/date_field.rb#8 - def format_date(value); end + def format_datetime(value); end end # source://actionview//lib/action_view/helpers/tags/date_select.rb#8 class ActionView::Helpers::Tags::DateSelect < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::SelectRenderer + # @return [DateSelect] a new instance of DateSelect # - # source://actionview//lib/action_view/helpers/tags/date_select.rb#9 + # source://actionview//lib/action_view/helpers/tags/date_select.rb#11 def initialize(object_name, method_name, template_object, options, html_options); end - # source://actionview//lib/action_view/helpers/tags/date_select.rb#15 + # source://actionview//lib/action_view/helpers/tags/date_select.rb#17 def render; end private - # source://actionview//lib/action_view/helpers/tags/date_select.rb#30 + # source://actionview//lib/action_view/helpers/tags/date_select.rb#32 def datetime_selector(options, html_options); end - # source://actionview//lib/action_view/helpers/tags/date_select.rb#43 + # source://actionview//lib/action_view/helpers/tags/date_select.rb#45 def default_datetime(options); end - # source://actionview//lib/action_view/helpers/tags/date_select.rb#26 + # source://actionview//lib/action_view/helpers/tags/date_select.rb#28 def select_type; end class << self - # source://actionview//lib/action_view/helpers/tags/date_select.rb#20 + # source://actionview//lib/action_view/helpers/tags/date_select.rb#22 def select_type; end end end @@ -10112,24 +10616,32 @@ class ActionView::Helpers::Tags::DatetimeField < ::ActionView::Helpers::Tags::Te private - # source://actionview//lib/action_view/helpers/tags/datetime_field.rb#21 + # source://actionview//lib/action_view/helpers/tags/datetime_field.rb#17 def datetime_value(value); end # @raise [NotImplementedError] # - # source://actionview//lib/action_view/helpers/tags/datetime_field.rb#17 - def format_date(value); end + # source://actionview//lib/action_view/helpers/tags/datetime_field.rb#25 + def format_datetime(value); end + + # source://actionview//lib/action_view/helpers/tags/datetime_field.rb#29 + def parse_datetime(value); end end # source://actionview//lib/action_view/helpers/tags/datetime_local_field.rb#6 class ActionView::Helpers::Tags::DatetimeLocalField < ::ActionView::Helpers::Tags::DatetimeField + # @return [DatetimeLocalField] a new instance of DatetimeLocalField + # + # source://actionview//lib/action_view/helpers/tags/datetime_local_field.rb#7 + def initialize(object_name, method_name, template_object, options = T.unsafe(nil)); end + private - # source://actionview//lib/action_view/helpers/tags/datetime_local_field.rb#14 - def format_date(value); end + # source://actionview//lib/action_view/helpers/tags/datetime_local_field.rb#19 + def format_datetime(value); end class << self - # source://actionview//lib/action_view/helpers/tags/datetime_local_field.rb#8 + # source://actionview//lib/action_view/helpers/tags/datetime_local_field.rb#13 def field_type; end end end @@ -10153,12 +10665,15 @@ end # source://actionview//lib/action_view/helpers/tags/grouped_collection_select.rb#6 class ActionView::Helpers::Tags::GroupedCollectionSelect < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::SelectRenderer + include ::ActionView::Helpers::FormOptionsHelper + # @return [GroupedCollectionSelect] a new instance of GroupedCollectionSelect # - # source://actionview//lib/action_view/helpers/tags/grouped_collection_select.rb#7 + # source://actionview//lib/action_view/helpers/tags/grouped_collection_select.rb#10 def initialize(object_name, method_name, template_object, collection, group_method, group_label_method, option_key_method, option_value_method, options, html_options); end - # source://actionview//lib/action_view/helpers/tags/grouped_collection_select.rb#18 + # source://actionview//lib/action_view/helpers/tags/grouped_collection_select.rb#21 def render; end end @@ -10208,7 +10723,7 @@ class ActionView::Helpers::Tags::MonthField < ::ActionView::Helpers::Tags::Datet private # source://actionview//lib/action_view/helpers/tags/month_field.rb#8 - def format_date(value); end + def format_datetime(value); end end # source://actionview//lib/action_view/helpers/tags/number_field.rb#6 @@ -10260,12 +10775,15 @@ end # source://actionview//lib/action_view/helpers/tags/select.rb#6 class ActionView::Helpers::Tags::Select < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::SelectRenderer + include ::ActionView::Helpers::FormOptionsHelper + # @return [Select] a new instance of Select # - # source://actionview//lib/action_view/helpers/tags/select.rb#7 + # source://actionview//lib/action_view/helpers/tags/select.rb#10 def initialize(object_name, method_name, template_object, choices, options, html_options); end - # source://actionview//lib/action_view/helpers/tags/select.rb#16 + # source://actionview//lib/action_view/helpers/tags/select.rb#19 def render; end private @@ -10277,10 +10795,26 @@ class ActionView::Helpers::Tags::Select < ::ActionView::Helpers::Tags::Base # # @return [Boolean] # - # source://actionview//lib/action_view/helpers/tags/select.rb#36 + # source://actionview//lib/action_view/helpers/tags/select.rb#39 def grouped_choices?; end end +# source://actionview//lib/action_view/helpers/tags/select_renderer.rb#6 +module ActionView::Helpers::Tags::SelectRenderer + private + + # source://actionview//lib/action_view/helpers/tags/select_renderer.rb#36 + def add_options(option_tags, options, value = T.unsafe(nil)); end + + # @return [Boolean] + # + # source://actionview//lib/action_view/helpers/tags/select_renderer.rb#31 + def placeholder_required?(html_options); end + + # source://actionview//lib/action_view/helpers/tags/select_renderer.rb#8 + def select_content_tag(option_tags, options, html_options); end +end + # source://actionview//lib/action_view/helpers/tags/tel_field.rb#6 class ActionView::Helpers::Tags::TelField < ::ActionView::Helpers::Tags::TextField; end @@ -10320,7 +10854,7 @@ class ActionView::Helpers::Tags::TimeField < ::ActionView::Helpers::Tags::Dateti private # source://actionview//lib/action_view/helpers/tags/time_field.rb#13 - def format_date(value); end + def format_datetime(value); end end # source://actionview//lib/action_view/helpers/tags/time_select.rb#6 @@ -10328,12 +10862,15 @@ class ActionView::Helpers::Tags::TimeSelect < ::ActionView::Helpers::Tags::DateS # source://actionview//lib/action_view/helpers/tags/time_zone_select.rb#6 class ActionView::Helpers::Tags::TimeZoneSelect < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::SelectRenderer + include ::ActionView::Helpers::FormOptionsHelper + # @return [TimeZoneSelect] a new instance of TimeZoneSelect # - # source://actionview//lib/action_view/helpers/tags/time_zone_select.rb#7 + # source://actionview//lib/action_view/helpers/tags/time_zone_select.rb#10 def initialize(object_name, method_name, template_object, priority_zones, options, html_options); end - # source://actionview//lib/action_view/helpers/tags/time_zone_select.rb#14 + # source://actionview//lib/action_view/helpers/tags/time_zone_select.rb#17 def render; end end @@ -10384,20 +10921,25 @@ class ActionView::Helpers::Tags::WeekField < ::ActionView::Helpers::Tags::Dateti private # source://actionview//lib/action_view/helpers/tags/week_field.rb#8 - def format_date(value); end + def format_datetime(value); end end # source://actionview//lib/action_view/helpers/tags/weekday_select.rb#6 class ActionView::Helpers::Tags::WeekdaySelect < ::ActionView::Helpers::Tags::Base + include ::ActionView::Helpers::Tags::SelectRenderer + include ::ActionView::Helpers::FormOptionsHelper + # @return [WeekdaySelect] a new instance of WeekdaySelect # - # source://actionview//lib/action_view/helpers/tags/weekday_select.rb#7 + # source://actionview//lib/action_view/helpers/tags/weekday_select.rb#10 def initialize(object_name, method_name, template_object, options, html_options); end - # source://actionview//lib/action_view/helpers/tags/weekday_select.rb#13 + # source://actionview//lib/action_view/helpers/tags/weekday_select.rb#16 def render; end end +# = Action View Text \Helpers +# # The TextHelper module provides a set of methods for filtering, formatting # and transforming strings, which can reduce the amount of inline Ruby code in # your views. These helper methods extend Action View making them callable @@ -10421,7 +10963,7 @@ end # simple_format h('Example') # # => "

<a href=\"http://example.com/\">Example</a>

" # -# source://actionview//lib/action_view/helpers/text_helper.rb#35 +# source://actionview//lib/action_view/helpers/text_helper.rb#36 module ActionView::Helpers::TextHelper include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper @@ -10432,41 +10974,44 @@ module ActionView::Helpers::TextHelper mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods # The preferred method of outputting text in your views is to use the - # <%= "text" %> eRuby syntax. The regular _puts_ and _print_ methods + # <%= "text" %> eRuby syntax. The regular +puts+ and +print+ methods # do not operate as expected in an eRuby code block. If you absolutely must - # output text within a non-output code block (i.e., <% %>), you can use the concat method. + # output text within a non-output code block (i.e., <% %>), you + # can use the +concat+ method. # - # <% - # concat "hello" - # # is the equivalent of <%= "hello" %> + # <% concat "hello" %> is equivalent to <%= "hello" %> # - # if logged_in - # concat "Logged in!" - # else - # concat link_to('login', action: :login) - # end - # # will either display "Logged in!" or a login link + # <% + # unless signed_in? + # concat link_to("Sign In", action: :sign_in) + # end # %> # - # source://actionview//lib/action_view/helpers/text_helper.rb#58 + # is equivalent to + # + # <% unless signed_in? %> + # <%= link_to "Sign In", action: :sign_in %> + # <% end %> + # + # source://actionview//lib/action_view/helpers/text_helper.rb#63 def concat(string); end # Returns the current cycle string after a cycle has been started. Useful # for complex table highlighting or any other design need which requires # the current cycle string in more than one place. # - # # Alternate background colors - # @items = [1,2,3,4] + # <%# Alternate background colors %> + # <% @items = [1,2,3,4] %> # <% @items.each do |item| %> #
"> # <%= item %> #
# <% end %> # - # source://actionview//lib/action_view/helpers/text_helper.rb#382 + # source://actionview//lib/action_view/helpers/text_helper.rb#454 def current_cycle(name = T.unsafe(nil)); end - # Creates a Cycle object whose _to_s_ method cycles through elements of an + # Creates a Cycle object whose +to_s+ method cycles through elements of an # array every time it is called. This can be used for example, to alternate # classes for table rows. You can use named cycles to allow nesting in loops. # Passing a Hash as the last parameter with a :name key will create a @@ -10475,8 +11020,8 @@ module ActionView::Helpers::TextHelper # and passing the name of the cycle. The current cycle string can be obtained # anytime using the current_cycle method. # - # # Alternate CSS classes for even and odd numbers... - # @items = [1,2,3,4] + # <%# Alternate CSS classes for even and odd numbers... %> + # <% @items = [1,2,3,4] %> # # <% @items.each do |item| %> # "> @@ -10486,10 +11031,12 @@ module ActionView::Helpers::TextHelper #
# # - # # Cycle CSS classes for rows, and text colors for values within each row - # @items = x = [{first: 'Robert', middle: 'Daniel', last: 'James'}, - # {first: 'Emily', middle: 'Shannon', maiden: 'Pike', last: 'Hicks'}, - # {first: 'June', middle: 'Dae', last: 'Jones'}] + # <%# Cycle CSS classes for rows, and text colors for values within each row %> + # <% @items = [ + # { first: "Robert", middle: "Daniel", last: "James" }, + # { first: "Emily", middle: "Shannon", maiden: "Pike", last: "Hicks" }, + # { first: "June", middle: "Dae", last: "Jones" }, + # ] %> # <% @items.each do |item| %> # "> # @@ -10504,100 +11051,129 @@ module ActionView::Helpers::TextHelper # # <% end %> # - # source://actionview//lib/action_view/helpers/text_helper.rb#358 + # source://actionview//lib/action_view/helpers/text_helper.rb#430 def cycle(first_value, *values); end - # Extracts an excerpt from +text+ that matches the first instance of +phrase+. - # The :radius option expands the excerpt on each side of the first occurrence of +phrase+ by the number of characters - # defined in :radius (which defaults to 100). If the excerpt radius overflows the beginning or end of the +text+, - # then the :omission option (which defaults to "...") will be prepended/appended accordingly. Use the - # :separator option to choose the delimitation. The resulting string will be stripped in any case. If the +phrase+ - # isn't found, +nil+ is returned. + # Extracts the first occurrence of +phrase+ plus surrounding text from + # +text+. An omission marker is prepended / appended if the start / end of + # the result does not coincide with the start / end of +text+. The result + # is always stripped in any case. Returns +nil+ if +phrase+ isn't found. + # + # ==== Options + # + # [+:radius+] + # The number of characters (or tokens — see +:separator+ option) around + # +phrase+ to include in the result. Defaults to 100. + # + # [+:omission+] + # The marker to prepend / append when the start / end of the excerpt + # does not coincide with the start / end of +text+. Defaults to + # "...". + # + # [+:separator+] + # The separator between tokens to count for +:radius+. Defaults to + # "", which treats each character as a token. + # + # ==== Examples # # excerpt('This is an example', 'an', radius: 5) - # # => ...s is an exam... + # # => "...s is an exam..." # # excerpt('This is an example', 'is', radius: 5) - # # => This is a... + # # => "This is a..." # # excerpt('This is an example', 'is') - # # => This is an example + # # => "This is an example" # # excerpt('This next thing is an example', 'ex', radius: 2) - # # => ...next... + # # => "...next..." # # excerpt('This is also an example', 'an', radius: 8, omission: ' ') - # # => is also an example + # # => " is also an example" # # excerpt('This is a very beautiful morning', 'very', separator: ' ', radius: 1) - # # => ...a very beautiful... + # # => "...a very beautiful..." # - # source://actionview//lib/action_view/helpers/text_helper.rb#179 + # source://actionview//lib/action_view/helpers/text_helper.rb#235 def excerpt(text, phrase, options = T.unsafe(nil)); end - # Highlights one or more +phrases+ everywhere in +text+ by inserting it into - # a :highlighter string. The highlighter can be specialized by passing :highlighter - # as a single-quoted string with \1 where the phrase is to be inserted (defaults to - # \1) or passing a block that receives each matched term. By default +text+ - # is sanitized to prevent possible XSS attacks. If the input is trustworthy, passing false - # for :sanitize will turn sanitizing off. + # Highlights occurrences of +phrases+ in +text+ by formatting them with a + # highlighter string. +phrases+ can be one or more strings or regular + # expressions. The result will be marked HTML safe. By default, +text+ is + # sanitized before highlighting to prevent possible XSS attacks. + # + # If a block is specified, it will be used instead of the highlighter + # string. Each occurrence of a phrase will be passed to the block, and its + # return value will be inserted into the final result. + # + # ==== Options + # + # [+:highlighter+] + # The highlighter string. Uses \1 as the placeholder for a + # phrase, similar to +String#sub+. Defaults to "\1". + # This option is ignored if a block is specified. + # + # [+:sanitize+] + # Whether to sanitize +text+ before highlighting. Defaults to true. + # + # ==== Examples # # highlight('You searched for: rails', 'rails') - # # => You searched for: rails + # # => "You searched for: rails" # # highlight('You searched for: rails', /for|rails/) - # # => You searched for: rails + # # => "You searched for: rails" # # highlight('You searched for: ruby, rails, dhh', 'actionpack') - # # => You searched for: ruby, rails, dhh + # # => "You searched for: ruby, rails, dhh" # # highlight('You searched for: rails', ['for', 'rails'], highlighter: '\1') - # # => You searched for: rails + # # => "You searched for: rails" # # highlight('You searched for: rails', 'rails', highlighter: '\1') - # # => You searched for: rails + # # => "You searched for: rails" # # highlight('You searched for: rails', 'rails') { |match| link_to(search_path(q: match, match)) } - # # => You searched for: rails + # # => "You searched for: rails" # # highlight('ruby on rails', 'rails', sanitize: false) - # # => ruby on rails + # # => "ruby on rails" # - # source://actionview//lib/action_view/helpers/text_helper.rb#136 + # source://actionview//lib/action_view/helpers/text_helper.rb#174 def highlight(text, phrases, options = T.unsafe(nil), &block); end # Attempts to pluralize the +singular+ word unless +count+ is 1. If # +plural+ is supplied, it will use that when count is > 1, otherwise # it will use the Inflector to determine the plural form for the given locale, - # which defaults to I18n.locale + # which defaults to +I18n.locale+. # # The word will be pluralized using rules defined for the locale # (you must define your own inflection rules for languages other than English). # See ActiveSupport::Inflector.pluralize # # pluralize(1, 'person') - # # => 1 person + # # => "1 person" # # pluralize(2, 'person') - # # => 2 people + # # => "2 people" # # pluralize(3, 'person', plural: 'users') - # # => 3 users + # # => "3 users" # # pluralize(0, 'person') - # # => 0 people + # # => "0 people" # # pluralize(2, 'Person', locale: :de) - # # => 2 Personen + # # => "2 Personen" # - # source://actionview//lib/action_view/helpers/text_helper.rb#234 + # source://actionview//lib/action_view/helpers/text_helper.rb#290 def pluralize(count, singular, plural_arg = T.unsafe(nil), plural: T.unsafe(nil), locale: T.unsafe(nil)); end # Resets a cycle so that it starts from the first element the next time # it is called. Pass in +name+ to reset a named cycle. # - # # Alternate CSS classes for even and odd numbers... - # @items = [[1,2,3,4], [5,6,3], [3,4,5,6,7,4]] + # <%# Alternate CSS classes for even and odd numbers... %> + # <% @items = [[1,2,3,4], [5,6,3], [3,4,5,6,7,4]] %> # # <% @items.each do |item| %> # "> @@ -10612,10 +11188,10 @@ module ActionView::Helpers::TextHelper # <% end %> #
# - # source://actionview//lib/action_view/helpers/text_helper.rb#405 + # source://actionview//lib/action_view/helpers/text_helper.rb#477 def reset_cycle(name = T.unsafe(nil)); end - # source://actionview//lib/action_view/helpers/text_helper.rb#62 + # source://actionview//lib/action_view/helpers/text_helper.rb#67 def safe_concat(string); end # Returns +text+ transformed into HTML using simple formatting rules. @@ -10630,6 +11206,7 @@ module ActionView::Helpers::TextHelper # # ==== Options # * :sanitize - If +false+, does not sanitize +text+. + # * :sanitize_options - Any extra options you want appended to the sanitize. # * :wrapper_tag - String representing the wrapper tag, defaults to "p" # # ==== Examples @@ -10655,20 +11232,42 @@ module ActionView::Helpers::TextHelper # simple_format("Blinkable! It's true.", {}, sanitize: false) # # => "

Blinkable! It's true.

" # - # source://actionview//lib/action_view/helpers/text_helper.rb#306 + # simple_format("Continue", {}, { sanitize_options: { attributes: %w[target href] } }) + # # => "

Continue

" + # + # source://actionview//lib/action_view/helpers/text_helper.rb#376 def simple_format(text, html_options = T.unsafe(nil), options = T.unsafe(nil)); end - # Truncates a given +text+ after a given :length if +text+ is longer than :length - # (defaults to 30). The last characters will be replaced with the :omission (defaults to "...") - # for a total length not exceeding :length. + # Truncates +text+ if it is longer than a specified +:length+. If +text+ + # is truncated, an omission marker will be appended to the result for a + # total length not exceeding +:length+. + # + # You can also pass a block to render and append extra content after the + # omission marker when +text+ is truncated. However, this content _can_ + # cause the total length to exceed +:length+ characters. + # + # The result will be escaped unless escape: false is specified. + # In any case, the result will be marked HTML-safe. Care should be taken + # if +text+ might contain HTML tags or entities, because truncation could + # produce invalid HTML, such as unbalanced or incomplete tags. + # + # ==== Options # - # Pass a :separator to truncate +text+ at a natural break. + # [+:length+] + # The maximum number of characters that should be returned, excluding + # any extra content from the block. Defaults to 30. # - # Pass a block if you want to show extra content when the text is truncated. + # [+:omission+] + # The string to append after truncating. Defaults to "...". # - # The result is marked as HTML-safe, but it is escaped by default, unless :escape is - # +false+. Care should be taken if +text+ contains HTML tags or entities, because truncation - # may produce invalid HTML (such as unbalanced or incomplete tags). + # [+:separator+] + # A string or regexp used to find a breaking point at which to truncate. + # By default, truncation can occur at any character in +text+. + # + # [+:escape+] + # Whether to escape the result. Defaults to true. + # + # ==== Examples # # truncate("Once upon a time in a world far far away") # # => "Once upon a time in a world..." @@ -10689,9 +11288,9 @@ module ActionView::Helpers::TextHelper # # => "

Once upon a time in a wo..." # # truncate("Once upon a time in a world far far away") { link_to "Continue", "#" } - # # => "Once upon a time in a wo...Continue" + # # => "Once upon a time in a world...Continue" # - # source://actionview//lib/action_view/helpers/text_helper.rb#98 + # source://actionview//lib/action_view/helpers/text_helper.rb#122 def truncate(text, options = T.unsafe(nil), &block); end # Wraps the +text+ into lines no longer than +line_width+ width. This method @@ -10699,77 +11298,79 @@ module ActionView::Helpers::TextHelper # (which is 80 by default). # # word_wrap('Once upon a time') - # # => Once upon a time + # # => "Once upon a time" # # word_wrap('Once upon a time, in a kingdom called Far Far Away, a king fell ill, and finding a successor to the throne turned out to be more trouble than anyone could have imagined...') - # # => Once upon a time, in a kingdom called Far Far Away, a king fell ill, and finding\na successor to the throne turned out to be more trouble than anyone could have\nimagined... + # # => "Once upon a time, in a kingdom called Far Far Away, a king fell ill, and finding\na successor to the throne turned out to be more trouble than anyone could have\nimagined..." # # word_wrap('Once upon a time', line_width: 8) - # # => Once\nupon a\ntime + # # => "Once\nupon a\ntime" # # word_wrap('Once upon a time', line_width: 1) - # # => Once\nupon\na\ntime + # # => "Once\nupon\na\ntime" # - # You can also specify a custom +break_sequence+ ("\n" by default) + # You can also specify a custom +break_sequence+ ("\n" by default): # # word_wrap('Once upon a time', line_width: 1, break_sequence: "\r\n") - # # => Once\r\nupon\r\na\r\ntime + # # => "Once\r\nupon\r\na\r\ntime" # - # source://actionview//lib/action_view/helpers/text_helper.rb#264 + # source://actionview//lib/action_view/helpers/text_helper.rb#320 def word_wrap(text, line_width: T.unsafe(nil), break_sequence: T.unsafe(nil)); end private - # source://actionview//lib/action_view/helpers/text_helper.rb#468 + # source://actionview//lib/action_view/helpers/text_helper.rb#540 def cut_excerpt_part(part_position, part, separator, options); end # The cycle helpers need to store the cycles in a place that is # guaranteed to be reset every time a page is rendered, so it # uses an instance variable of ActionView::Base. # - # source://actionview//lib/action_view/helpers/text_helper.rb#450 + # source://actionview//lib/action_view/helpers/text_helper.rb#522 def get_cycle(name); end - # source://actionview//lib/action_view/helpers/text_helper.rb#455 + # source://actionview//lib/action_view/helpers/text_helper.rb#527 def set_cycle(name, cycle_object); end - # source://actionview//lib/action_view/helpers/text_helper.rb#460 + # source://actionview//lib/action_view/helpers/text_helper.rb#532 def split_paragraphs(text); end end -# source://actionview//lib/action_view/helpers/text_helper.rb#410 +# source://actionview//lib/action_view/helpers/text_helper.rb#482 class ActionView::Helpers::TextHelper::Cycle # @return [Cycle] a new instance of Cycle # - # source://actionview//lib/action_view/helpers/text_helper.rb#413 + # source://actionview//lib/action_view/helpers/text_helper.rb#485 def initialize(first_value, *values); end - # source://actionview//lib/action_view/helpers/text_helper.rb#422 + # source://actionview//lib/action_view/helpers/text_helper.rb#494 def current_value; end - # source://actionview//lib/action_view/helpers/text_helper.rb#418 + # source://actionview//lib/action_view/helpers/text_helper.rb#490 def reset; end - # source://actionview//lib/action_view/helpers/text_helper.rb#426 + # source://actionview//lib/action_view/helpers/text_helper.rb#498 def to_s; end # Returns the value of attribute values. # - # source://actionview//lib/action_view/helpers/text_helper.rb#411 + # source://actionview//lib/action_view/helpers/text_helper.rb#483 def values; end private - # source://actionview//lib/action_view/helpers/text_helper.rb#433 + # source://actionview//lib/action_view/helpers/text_helper.rb#505 def next_index; end - # source://actionview//lib/action_view/helpers/text_helper.rb#437 + # source://actionview//lib/action_view/helpers/text_helper.rb#509 def previous_index; end - # source://actionview//lib/action_view/helpers/text_helper.rb#441 + # source://actionview//lib/action_view/helpers/text_helper.rb#513 def step_index(n); end end +# = Action View Translation \Helpers +# # source://actionview//lib/action_view/helpers/translation_helper.rb#9 module ActionView::Helpers::TranslationHelper include ::ActionView::Helpers::CaptureHelper @@ -10926,16 +11527,19 @@ ActionView::Helpers::TranslationHelper::MISSING_TRANSLATION = T.let(T.unsafe(nil # source://actionview//lib/action_view/helpers/translation_helper.rb#125 ActionView::Helpers::TranslationHelper::NO_DEFAULT = T.let(T.unsafe(nil), Array) +# = Action View URL \Helpers +# # Provides a set of methods for making links and getting URLs that # depend on the routing subsystem (see ActionDispatch::Routing). # This allows you to use the same format for links in views # and controllers. # -# source://actionview//lib/action_view/helpers/url_helper.rb#15 +# source://actionview//lib/action_view/helpers/url_helper.rb#17 module ActionView::Helpers::UrlHelper include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper include ::ActionView::Helpers::TagHelper + include ::ActionView::Helpers::ContentExfiltrationPreventionHelper extend ::ActiveSupport::Concern mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods @@ -10943,9 +11547,6 @@ module ActionView::Helpers::UrlHelper # Generates a form containing a single button that submits to the URL created # by the set of +options+. This is the safest method to ensure links that # cause changes to your data are not triggered by search bots or accelerators. - # If the HTML button does not work with your layout, you can also consider - # using the +link_to+ method with the :method modifier as described in - # the +link_to+ documentation. # # You can control the form and button behavior with +html_options+. Most # values in +html_options+ are passed through to the button element. For @@ -10956,8 +11557,13 @@ module ActionView::Helpers::UrlHelper # +:form_class+ option within +html_options+. It defaults to # "button_to" to allow styling of the form and its children. # - # The form submits a POST request by default. You can specify a different - # HTTP verb via the +:method+ option within +html_options+. + # The form submits a POST request by default if the object is not persisted; + # conversely, if the object is persisted, it will submit a PATCH request. + # To specify a different HTTP verb use the +:method+ option within +html_options+. + # + # If the HTML button generated from +button_to+ does not work with your layout, you can + # consider using the +link_to+ method with the +data-turbo-method+ + # attribute as described in the +link_to+ documentation. # # ==== Options # The +options+ hash accepts the same options as +url_for+. To generate a @@ -11024,44 +11630,63 @@ module ActionView::Helpers::UrlHelper # # # #

" # - # ==== Deprecated: Rails UJS Attributes - # - # Prior to Rails 7, Rails shipped with a JavaScript library called @rails/ujs on by default. Following Rails 7, - # this library is no longer on by default. This library integrated with the following options: - # - # * :remote - If set to true, will allow @rails/ujs to control the - # submit behavior. By default this behavior is an Ajax submit. - # - # @rails/ujs also integrated with the following +:data+ options: - # - # * confirm: "question?" - This will allow @rails/ujs - # to prompt with the question specified (in this case, the - # resulting text would be question?). If the user accepts, the - # button is processed normally, otherwise no action is taken. - # * :disable_with - Value of this parameter will be - # used as the value for a disabled version of the submit - # button when the form is submitted. - # - # ===== Rails UJS Examples - # - # <%= button_to "Create", { action: "create" }, remote: true, form: { "data-type" => "json" } %> - # # => "
- # # - # # - # #
" - # - # source://actionview//lib/action_view/helpers/url_helper.rb#331 + # source://actionview//lib/action_view/helpers/url_helper.rb#296 def button_to(name = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end - # source://actionview//lib/action_view/helpers/url_helper.rb#32 + # source://actionview//lib/action_view/helpers/url_helper.rb#35 def button_to_generates_button_tag; end - # source://actionview//lib/action_view/helpers/url_helper.rb#32 + # source://actionview//lib/action_view/helpers/url_helper.rb#35 def button_to_generates_button_tag=(val); end + # True if the current request URI was generated by the given +options+. + # + # ==== Examples + # Let's say we're in the http://www.example.com/shop/checkout?order=desc&page=1 action. + # + # current_page?(action: 'process') + # # => false + # + # current_page?(action: 'checkout') + # # => true + # + # current_page?(controller: 'library', action: 'checkout') + # # => false + # + # current_page?(controller: 'shop', action: 'checkout') + # # => true + # + # current_page?(controller: 'shop', action: 'checkout', order: 'asc') + # # => false + # + # current_page?(controller: 'shop', action: 'checkout', order: 'desc', page: '1') + # # => true + # + # current_page?(controller: 'shop', action: 'checkout', order: 'desc', page: '2') + # # => false + # + # current_page?('http://www.example.com/shop/checkout') + # # => true + # + # current_page?('http://www.example.com/shop/checkout', check_parameters: true) + # # => false + # + # current_page?('/shop/checkout') + # # => true + # + # current_page?('http://www.example.com/shop/checkout?order=desc&page=1') + # # => true + # + # Let's say we're in the http://www.example.com/products action with method POST in case of invalid product. + # + # current_page?(controller: 'product', action: 'index') + # # => false + # + # We can also pass in the symbol arguments instead of strings. + # # @return [Boolean] # - # source://actionview//lib/action_view/helpers/url_helper.rb#582 + # source://actionview//lib/action_view/helpers/url_helper.rb#548 def current_page?(options = T.unsafe(nil), check_parameters: T.unsafe(nil), **options_as_kwargs); end # Creates an anchor element of the given +name+ using a URL created by the set of +options+. @@ -11097,7 +11722,7 @@ module ActionView::Helpers::UrlHelper # ==== Examples # # Because it relies on +url_for+, +link_to+ supports both older-style controller/action/id arguments - # and newer RESTful routes. Current Rails style favors RESTful routes whenever possible, so base + # and newer RESTful routes. Current \Rails style favors RESTful routes whenever possible, so base # your application on resources and use # # link_to "Profile", profile_path(@profile) @@ -11174,43 +11799,29 @@ module ActionView::Helpers::UrlHelper # link_to "External link", "http://www.rubyonrails.org/", target: "_blank", rel: "nofollow" # # => External link # - # ==== Deprecated: Rails UJS Attributes + # ==== Turbo # - # Prior to Rails 7, Rails shipped with a JavaScript library called @rails/ujs on by default. Following Rails 7, - # this library is no longer on by default. This library integrated with the following options: + # Rails 7 ships with Turbo enabled by default. Turbo provides the following +:data+ options: # - # * method: symbol of HTTP verb - This modifier will dynamically - # create an HTML form and immediately submit the form for processing using - # the HTTP verb specified. Useful for having links perform a POST operation - # in dangerous actions like deleting a record (which search bots can follow - # while spidering your site). Supported verbs are :post, :delete, :patch, and :put. - # Note that if the user has JavaScript disabled, the request will fall back - # to using GET. If href: '#' is used and the user has JavaScript - # disabled clicking the link will have no effect. If you are relying on the - # POST behavior, you should check for it in your controller's action by using - # the request object's methods for post?, delete?, patch?, or put?. - # * remote: true - This will allow @rails/ujs - # to make an Ajax request to the URL in question instead of following - # the link. + # * turbo_method: symbol of HTTP verb - Performs a Turbo link visit + # with the given HTTP verb. Forms are recommended when performing non-+GET+ requests. + # Only use data-turbo-method where a form is not possible. # - # @rails/ujs also integrated with the following +:data+ options: + # * turbo_confirm: "question?" - Adds a confirmation dialog to the link with the + # given value. # - # * confirm: "question?" - This will allow @rails/ujs - # to prompt with the question specified (in this case, the - # resulting text would be question?). If the user accepts, the - # link is processed normally, otherwise no action is taken. - # * :disable_with - Value of this parameter will be used as the - # name for a disabled version of the link. + # {Consult the Turbo Handbook for more information on the options + # above.}[https://turbo.hotwired.dev/handbook/drive#performing-visits-with-a-different-method] # - # ===== Rails UJS Examples + # ===== \Examples # - # link_to "Remove Profile", profile_path(@profile), method: :delete - # # => Remove Profile + # link_to "Delete profile", @profile, data: { turbo_method: :delete } + # # => Delete profile # - # link_to "Visit Other Site", "http://www.rubyonrails.org/", data: { confirm: "Are you sure?" } - # # => Visit Other Site + # link_to "Visit Other Site", "https://rubyonrails.org/", data: { turbo_confirm: "Are you sure?" } + # # => Visit Other Site # - # source://actionview//lib/action_view/helpers/url_helper.rb#209 + # source://actionview//lib/action_view/helpers/url_helper.rb#198 def link_to(name = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Creates a link tag of the given +name+ using a URL created by the set of @@ -11233,7 +11844,7 @@ module ActionView::Helpers::UrlHelper # # If they are logged in... # # => my_username # - # source://actionview//lib/action_view/helpers/url_helper.rb#471 + # source://actionview//lib/action_view/helpers/url_helper.rb#437 def link_to_if(condition, name, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Creates a link tag of the given +name+ using a URL created by the set of @@ -11257,7 +11868,7 @@ module ActionView::Helpers::UrlHelper # # If not... # # => Reply # - # source://actionview//lib/action_view/helpers/url_helper.rb#448 + # source://actionview//lib/action_view/helpers/url_helper.rb#414 def link_to_unless(condition, name, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Creates a link tag of the given +name+ using a URL created by the set of @@ -11299,7 +11910,7 @@ module ActionView::Helpers::UrlHelper # end # %> # - # source://actionview//lib/action_view/helpers/url_helper.rb#424 + # source://actionview//lib/action_view/helpers/url_helper.rb#390 def link_to_unless_current(name, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Creates a mailto link tag to the specified +email_address+, which is @@ -11317,7 +11928,7 @@ module ActionView::Helpers::UrlHelper # * :reply_to - Preset the +Reply-To+ field of the email. # # ==== Obfuscation - # Prior to Rails 4.0, +mail_to+ provided options for encoding the address + # Prior to \Rails 4.0, +mail_to+ provided options for encoding the address # in order to hinder email harvesters. To take advantage of these options, # install the +actionview-encoded_mail_to+ gem. # @@ -11341,7 +11952,7 @@ module ActionView::Helpers::UrlHelper # Email me: me@domain.com # # - # source://actionview//lib/action_view/helpers/url_helper.rb#521 + # source://actionview//lib/action_view/helpers/url_helper.rb#487 def mail_to(email_address, name = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Creates a TEL anchor link tag to the specified +phone_number+. When the @@ -11380,7 +11991,7 @@ module ActionView::Helpers::UrlHelper # Phone me: # # - # source://actionview//lib/action_view/helpers/url_helper.rb#716 + # source://actionview//lib/action_view/helpers/url_helper.rb#669 def phone_to(phone_number, name = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Creates an SMS anchor link tag to the specified +phone_number+. When the @@ -11424,45 +12035,45 @@ module ActionView::Helpers::UrlHelper # Text me: # # - # source://actionview//lib/action_view/helpers/url_helper.rb#665 + # source://actionview//lib/action_view/helpers/url_helper.rb#618 def sms_to(phone_number, name = T.unsafe(nil), html_options = T.unsafe(nil), &block); end # Basic implementation of url_for to allow use helpers without routes existence # - # source://actionview//lib/action_view/helpers/url_helper.rb#35 + # source://actionview//lib/action_view/helpers/url_helper.rb#38 def url_for(options = T.unsafe(nil)); end private - # source://actionview//lib/action_view/helpers/url_helper.rb#47 + # source://actionview//lib/action_view/helpers/url_helper.rb#50 def _back_url; end - # source://actionview//lib/action_view/helpers/url_helper.rb#52 + # source://actionview//lib/action_view/helpers/url_helper.rb#55 def _filtered_referrer; end - # source://actionview//lib/action_view/helpers/url_helper.rb#759 + # source://actionview//lib/action_view/helpers/url_helper.rb#712 def add_method_to_attributes!(html_options, method); end - # source://actionview//lib/action_view/helpers/url_helper.rb#730 + # source://actionview//lib/action_view/helpers/url_helper.rb#683 def convert_options_to_data_attributes(options, html_options); end # @return [Boolean] # - # source://actionview//lib/action_view/helpers/url_helper.rb#753 + # source://actionview//lib/action_view/helpers/url_helper.rb#706 def link_to_remote_options?(options); end - # source://actionview//lib/action_view/helpers/url_helper.rb#770 + # source://actionview//lib/action_view/helpers/url_helper.rb#723 def method_for_options(options); end # @return [Boolean] # - # source://actionview//lib/action_view/helpers/url_helper.rb#788 + # source://actionview//lib/action_view/helpers/url_helper.rb#741 def method_not_get_method?(method); end - # source://actionview//lib/action_view/helpers/url_helper.rb#807 + # source://actionview//lib/action_view/helpers/url_helper.rb#760 def method_tag(method); end - # source://actionview//lib/action_view/helpers/url_helper.rb#853 + # source://actionview//lib/action_view/helpers/url_helper.rb#806 def remove_trailing_slash!(url_string); end # Returns an array of hashes each containing :name and :value keys @@ -11482,20 +12093,20 @@ module ActionView::Helpers::UrlHelper # to_form_params({ name: 'Denmark' }, 'country') # # => [{name: 'country[name]', value: 'Denmark'}] # - # source://actionview//lib/action_view/helpers/url_helper.rb#827 + # source://actionview//lib/action_view/helpers/url_helper.rb#780 def to_form_params(attribute, namespace = T.unsafe(nil)); end - # source://actionview//lib/action_view/helpers/url_helper.rb#793 + # source://actionview//lib/action_view/helpers/url_helper.rb#746 def token_tag(token = T.unsafe(nil), form_options: T.unsafe(nil)); end - # source://actionview//lib/action_view/helpers/url_helper.rb#745 + # source://actionview//lib/action_view/helpers/url_helper.rb#698 def url_target(name, options); end class << self - # source://actionview//lib/action_view/helpers/url_helper.rb#32 + # source://actionview//lib/action_view/helpers/url_helper.rb#35 def button_to_generates_button_tag; end - # source://actionview//lib/action_view/helpers/url_helper.rb#32 + # source://actionview//lib/action_view/helpers/url_helper.rb#35 def button_to_generates_button_tag=(val); end end end @@ -11506,16 +12117,16 @@ end # (link_to_unless_current, for instance), which must be provided # as a method called #request on the context. # -# source://actionview//lib/action_view/helpers/url_helper.rb#21 +# source://actionview//lib/action_view/helpers/url_helper.rb#23 ActionView::Helpers::UrlHelper::BUTTON_TAG_METHOD_VERBS = T.let(T.unsafe(nil), Array) -# source://actionview//lib/action_view/helpers/url_helper.rb#26 +# source://actionview//lib/action_view/helpers/url_helper.rb#29 module ActionView::Helpers::UrlHelper::ClassMethods - # source://actionview//lib/action_view/helpers/url_helper.rb#27 + # source://actionview//lib/action_view/helpers/url_helper.rb#30 def _url_for_modules; end end -# source://actionview//lib/action_view/helpers/url_helper.rb#780 +# source://actionview//lib/action_view/helpers/url_helper.rb#733 ActionView::Helpers::UrlHelper::STRINGIFIED_COMMON_METHODS = T.let(T.unsafe(nil), Hash) # This is a class to fix I18n global state. Whenever you provide I18n.locale during a request, @@ -11528,10 +12139,10 @@ class ActionView::I18nProxy < ::I18n::Config # source://actionview//lib/action_view/rendering.rb#11 def initialize(original_config, lookup_context); end - # source://actionview//lib/action_view/rendering.rb#16 + # source://actionview//lib/action_view/rendering.rb#17 def locale; end - # source://actionview//lib/action_view/rendering.rb#20 + # source://actionview//lib/action_view/rendering.rb#21 def locale=(value); end # source://actionview//lib/action_view/rendering.rb#9 @@ -11541,12 +12152,14 @@ class ActionView::I18nProxy < ::I18n::Config def original_config; end end +# = Action View \Layouts +# # Layouts reverse the common pattern of including shared headers and footers in many templates to isolate changes in # repeated setups. The inclusion pattern has pages that look like this: # -# <%= render "shared/header" %> +# <%= render "application/header" %> # Hello World -# <%= render "shared/footer" %> +# <%= render "application/footer" %> # # This approach is a decent way of keeping common structures isolated from the changing content, but it's verbose # and if you ever want to change the structure of these two includes, you'll have to change all the templates. @@ -11687,7 +12300,7 @@ end # The template will be looked always in app/views/layouts/ folder. But you can point # layouts folder direct also. layout "layouts/demo" is the same as layout "demo". # -# Setting the layout to +nil+ forces it to be looked up in the filesystem and fallbacks to the parent behavior if none exists. +# Setting the layout to +nil+ forces it to be looked up in the filesystem and falls back to the parent behavior if none exists. # Setting it to +nil+ is useful to re-enable template lookup overriding a previous configuration set in the parent: # # class ApplicationController < ActionController::Base @@ -11699,7 +12312,7 @@ end # end # # class CommentsController < ApplicationController -# # Will search for "comments" layout and fallback "application" layout +# # Will search for "comments" layout and fall back to "application" layout # layout nil # end # @@ -11738,7 +12351,7 @@ end # # This will override the controller-wide "weblog_standard" layout, and will render the help action with the "help" layout instead. # -# source://actionview//lib/action_view/layouts.rb#203 +# source://actionview//lib/action_view/layouts.rb#205 module ActionView::Layouts extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -11753,9 +12366,6 @@ module ActionView::Layouts # source://actionview//lib/action_view/layouts.rb#361 def initialize(*_arg0); end - # source://actionview//lib/action_view/layouts.rb#215 - def _layout_conditions(*_arg0, **_arg1, &_arg2); end - # source://actionview//lib/action_view/layouts.rb#350 def _normalize_options(options); end @@ -11824,7 +12434,10 @@ module ActionView::Layouts def _layout_conditions?; end end - module GeneratedInstanceMethods; end + module GeneratedInstanceMethods + def _layout_conditions; end + def _layout_conditions?; end + end end # source://actionview//lib/action_view/layouts.rb#217 @@ -11899,53 +12512,75 @@ end # = Action View Log Subscriber # -# Provides functionality so that Rails can output logs from Action View. +# Provides functionality so that \Rails can output logs from Action View. # # source://actionview//lib/action_view/log_subscriber.rb#9 class ActionView::LogSubscriber < ::ActiveSupport::LogSubscriber + include ::ActionView::LogSubscriber::Utils + # @return [LogSubscriber] a new instance of LogSubscriber # # source://actionview//lib/action_view/log_subscriber.rb#12 def initialize; end - # source://actionview//lib/action_view/log_subscriber.rb#59 - def logger; end - - # source://actionview//lib/action_view/log_subscriber.rb#42 + # source://actionview//lib/action_view/log_subscriber.rb#45 def render_collection(event); end - # source://actionview//lib/action_view/log_subscriber.rb#35 + # source://actionview//lib/action_view/log_subscriber.rb#37 def render_layout(event); end - # source://actionview//lib/action_view/log_subscriber.rb#25 + # source://actionview//lib/action_view/log_subscriber.rb#26 def render_partial(event); end # source://actionview//lib/action_view/log_subscriber.rb#17 def render_template(event); end - # source://actionview//lib/action_view/log_subscriber.rb#53 - def start(name, id, payload); end - private - # source://actionview//lib/action_view/log_subscriber.rb#83 + # source://actionview//lib/action_view/log_subscriber.rb#121 def cache_message(payload); end - # source://actionview//lib/action_view/log_subscriber.rb#65 - def from_rails_root(string); end + # source://actionview//lib/action_view/log_subscriber.rb#113 + def render_count(payload); end - # source://actionview//lib/action_view/log_subscriber.rb#92 - def log_rendering_start(payload, name); end + class << self + # source://actionview//lib/action_view/log_subscriber.rb#105 + def attach_to(*_arg0); end - # source://actionview//lib/action_view/log_subscriber.rb#71 - def rails_root; end + # source://activesupport/7.2.0/lib/active_support/log_subscriber.rb#84 + def log_levels; end + end +end - # source://actionview//lib/action_view/log_subscriber.rb#75 - def render_count(payload); end +# source://actionview//lib/action_view/log_subscriber.rb#76 +class ActionView::LogSubscriber::Start + include ::ActionView::LogSubscriber::Utils + + # source://actionview//lib/action_view/log_subscriber.rb#97 + def finish(name, id, payload); end + + # @return [Boolean] + # + # source://actionview//lib/action_view/log_subscriber.rb#100 + def silenced?(_); end + + # source://actionview//lib/action_view/log_subscriber.rb#79 + def start(name, id, payload); end end -# source://actionview//lib/action_view/log_subscriber.rb#64 -ActionView::LogSubscriber::EMPTY = T.let(T.unsafe(nil), String) +# source://actionview//lib/action_view/log_subscriber.rb#57 +module ActionView::LogSubscriber::Utils + # source://actionview//lib/action_view/log_subscriber.rb#58 + def logger; end + + private + + # source://actionview//lib/action_view/log_subscriber.rb#63 + def from_rails_root(string); end + + # source://actionview//lib/action_view/log_subscriber.rb#69 + def rails_root; end +end # source://actionview//lib/action_view/log_subscriber.rb#10 ActionView::LogSubscriber::VIEWS_PATTERN = T.let(T.unsafe(nil), Regexp) @@ -11966,28 +12601,28 @@ class ActionView::LookupContext # @return [LookupContext] a new instance of LookupContext # - # source://actionview//lib/action_view/lookup_context.rb#216 + # source://actionview//lib/action_view/lookup_context.rb#232 def initialize(view_paths, details = T.unsafe(nil), prefixes = T.unsafe(nil)); end - # source://actionview//lib/action_view/lookup_context.rb#226 + # source://actionview//lib/action_view/lookup_context.rb#242 def digest_cache; end # Override formats= to expand ["*/*"] values and automatically # add :html as fallback to :js. # - # source://actionview//lib/action_view/lookup_context.rb#247 + # source://actionview//lib/action_view/lookup_context.rb#263 def formats=(values); end # Override locale to return a symbol instead of array. # - # source://actionview//lib/action_view/lookup_context.rb#267 + # source://actionview//lib/action_view/lookup_context.rb#283 def locale; end # Overload locale= to also set the I18n.locale. If the current I18n.config object responds # to original_config, it means that it has a copy of the original I18n configuration and it's # acting as proxy, which we need to skip. # - # source://actionview//lib/action_view/lookup_context.rb#274 + # source://actionview//lib/action_view/lookup_context.rb#290 def locale=(value); end # source://actionview//lib/action_view/lookup_context.rb#16 @@ -11996,18 +12631,12 @@ class ActionView::LookupContext # source://actionview//lib/action_view/lookup_context.rb#16 def prefixes=(_arg0); end - # source://actionview//lib/action_view/lookup_context.rb#16 - def rendered_format; end - - # source://actionview//lib/action_view/lookup_context.rb#16 - def rendered_format=(_arg0); end - - # source://actionview//lib/action_view/lookup_context.rb#230 + # source://actionview//lib/action_view/lookup_context.rb#246 def with_prepended_formats(formats); end private - # source://actionview//lib/action_view/lookup_context.rb#237 + # source://actionview//lib/action_view/lookup_context.rb#253 def initialize_details(target, details); end class << self @@ -12068,34 +12697,34 @@ ActionView::LookupContext::Accessors::DEFAULT_PROCS = T.let(T.unsafe(nil), Hash) # Add caching behavior on top of Details. # -# source://actionview//lib/action_view/lookup_context.rb#94 +# source://actionview//lib/action_view/lookup_context.rb#98 module ActionView::LookupContext::DetailsCache # Returns the value of attribute cache. # - # source://actionview//lib/action_view/lookup_context.rb#95 + # source://actionview//lib/action_view/lookup_context.rb#99 def cache; end # Sets the attribute cache # # @param value the value to set the attribute cache to. # - # source://actionview//lib/action_view/lookup_context.rb#95 + # source://actionview//lib/action_view/lookup_context.rb#99 def cache=(_arg0); end # Calculate the details key. Remove the handlers from calculation to improve performance # since the user cannot modify it explicitly. # - # source://actionview//lib/action_view/lookup_context.rb#99 + # source://actionview//lib/action_view/lookup_context.rb#103 def details_key; end # Temporary skip passing the details_key forward. # - # source://actionview//lib/action_view/lookup_context.rb#104 + # source://actionview//lib/action_view/lookup_context.rb#108 def disable_cache; end private - # source://actionview//lib/action_view/lookup_context.rb#112 + # source://actionview//lib/action_view/lookup_context.rb#116 def _set_detail(key, value); end end @@ -12104,7 +12733,7 @@ class ActionView::LookupContext::DetailsKey def eql?(_arg0); end class << self - # source://actionview//lib/action_view/lookup_context.rb#73 + # source://actionview//lib/action_view/lookup_context.rb#77 def clear; end # source://actionview//lib/action_view/lookup_context.rb#65 @@ -12113,55 +12742,61 @@ class ActionView::LookupContext::DetailsKey # source://actionview//lib/action_view/lookup_context.rb#61 def digest_cache(details); end - # source://actionview//lib/action_view/lookup_context.rb#82 + # source://actionview//lib/action_view/lookup_context.rb#86 def digest_caches; end - # source://actionview//lib/action_view/lookup_context.rb#86 - def view_context_class(klass); end + # source://actionview//lib/action_view/lookup_context.rb#90 + def view_context_class; end end end # Helpers related to template lookup using the lookup context information. # -# source://actionview//lib/action_view/lookup_context.rb#121 +# source://actionview//lib/action_view/lookup_context.rb#125 module ActionView::LookupContext::ViewPaths # @return [Boolean] # - # source://actionview//lib/action_view/lookup_context.rb#144 + # source://actionview//lib/action_view/lookup_context.rb#148 def any?(name, prefixes = T.unsafe(nil), partial = T.unsafe(nil)); end # @return [Boolean] # - # source://actionview//lib/action_view/lookup_context.rb#144 + # source://actionview//lib/action_view/lookup_context.rb#148 def any_templates?(name, prefixes = T.unsafe(nil), partial = T.unsafe(nil)); end + # source://actionview//lib/action_view/lookup_context.rb#155 + def append_view_paths(paths); end + # @return [Boolean] # - # source://actionview//lib/action_view/lookup_context.rb#137 + # source://actionview//lib/action_view/lookup_context.rb#141 def exists?(name, prefixes = T.unsafe(nil), partial = T.unsafe(nil), keys = T.unsafe(nil), **options); end - # source://actionview//lib/action_view/lookup_context.rb#124 + # source://actionview//lib/action_view/lookup_context.rb#128 def find(name, prefixes = T.unsafe(nil), partial = T.unsafe(nil), keys = T.unsafe(nil), options = T.unsafe(nil)); end - # source://actionview//lib/action_view/lookup_context.rb#131 + # source://actionview//lib/action_view/lookup_context.rb#135 def find_all(name, prefixes = T.unsafe(nil), partial = T.unsafe(nil), keys = T.unsafe(nil), options = T.unsafe(nil)); end - # source://actionview//lib/action_view/lookup_context.rb#124 + # source://actionview//lib/action_view/lookup_context.rb#128 def find_template(name, prefixes = T.unsafe(nil), partial = T.unsafe(nil), keys = T.unsafe(nil), options = T.unsafe(nil)); end # Returns the value of attribute html_fallback_for_js. # - # source://actionview//lib/action_view/lookup_context.rb#122 + # source://actionview//lib/action_view/lookup_context.rb#126 def html_fallback_for_js; end + # source://actionview//lib/action_view/lookup_context.rb#159 + def prepend_view_paths(paths); end + # @return [Boolean] # - # source://actionview//lib/action_view/lookup_context.rb#137 + # source://actionview//lib/action_view/lookup_context.rb#141 def template_exists?(name, prefixes = T.unsafe(nil), partial = T.unsafe(nil), keys = T.unsafe(nil), **options); end # Returns the value of attribute view_paths. # - # source://actionview//lib/action_view/lookup_context.rb#122 + # source://actionview//lib/action_view/lookup_context.rb#126 def view_paths; end private @@ -12169,30 +12804,30 @@ module ActionView::LookupContext::ViewPaths # Whenever setting view paths, makes a copy so that we can manipulate them in # instance objects as we wish. # - # source://actionview//lib/action_view/lookup_context.rb#154 + # source://actionview//lib/action_view/lookup_context.rb#166 def build_view_paths(paths); end # Compute details hash and key according to user options (e.g. passed from #render). # - # source://actionview//lib/action_view/lookup_context.rb#159 + # source://actionview//lib/action_view/lookup_context.rb#175 def detail_args_for(options); end - # source://actionview//lib/action_view/lookup_context.rb#172 + # source://actionview//lib/action_view/lookup_context.rb#188 def detail_args_for_any; end # Fix when prefix is specified as part of the template name # - # source://actionview//lib/action_view/lookup_context.rb#193 + # source://actionview//lib/action_view/lookup_context.rb#209 def normalize_name(name, prefixes); end end -# source://actionview//lib/action_view/template/error.rb#29 +# source://actionview//lib/action_view/template/error.rb#30 class ActionView::MissingTemplate < ::ActionView::ActionViewError include ::DidYouMean::Correctable # @return [MissingTemplate] a new instance of MissingTemplate # - # source://actionview//lib/action_view/template/error.rb#32 + # source://actionview//lib/action_view/template/error.rb#33 def initialize(paths, path, prefixes, partial, details, *_arg5); end # Apps may have thousands of candidate templates so we attempt to @@ -12200,50 +12835,50 @@ class ActionView::MissingTemplate < ::ActionView::ActionViewError # First we split templates into prefixes and basenames, so that those can # be matched separately. # - # source://actionview//lib/action_view/template/error.rb#92 + # source://actionview//lib/action_view/template/error.rb#93 def corrections; end # Returns the value of attribute partial. # - # source://actionview//lib/action_view/template/error.rb#30 + # source://actionview//lib/action_view/template/error.rb#31 def partial; end # Returns the value of attribute path. # - # source://actionview//lib/action_view/template/error.rb#30 + # source://actionview//lib/action_view/template/error.rb#31 def path; end # Returns the value of attribute paths. # - # source://actionview//lib/action_view/template/error.rb#30 + # source://actionview//lib/action_view/template/error.rb#31 def paths; end # Returns the value of attribute prefixes. # - # source://actionview//lib/action_view/template/error.rb#30 + # source://actionview//lib/action_view/template/error.rb#31 def prefixes; end end -# source://actionview//lib/action_view/template/error.rb#59 +# source://actionview//lib/action_view/template/error.rb#60 class ActionView::MissingTemplate::Results # @return [Results] a new instance of Results # - # source://actionview//lib/action_view/template/error.rb#62 + # source://actionview//lib/action_view/template/error.rb#63 def initialize(size); end - # source://actionview//lib/action_view/template/error.rb#79 + # source://actionview//lib/action_view/template/error.rb#80 def add(path, score); end # @return [Boolean] # - # source://actionview//lib/action_view/template/error.rb#71 + # source://actionview//lib/action_view/template/error.rb#72 def should_record?(score); end - # source://actionview//lib/action_view/template/error.rb#67 + # source://actionview//lib/action_view/template/error.rb#68 def to_a; end end -# source://actionview//lib/action_view/template/error.rb#60 +# source://actionview//lib/action_view/template/error.rb#61 class ActionView::MissingTemplate::Results::Result < ::Struct # Returns the value of attribute path # @@ -12327,23 +12962,80 @@ end # puts sbuf # => "hello\u0005" # # source://actionview//lib/action_view/buffers.rb#21 -class ActionView::OutputBuffer < ::ActiveSupport::SafeBuffer +class ActionView::OutputBuffer # @return [OutputBuffer] a new instance of OutputBuffer # # source://actionview//lib/action_view/buffers.rb#22 - def initialize(*_arg0); end + def initialize(buffer = T.unsafe(nil)); end - # source://actionview//lib/action_view/buffers.rb#27 + # source://actionview//lib/action_view/buffers.rb#42 def <<(value); end - # source://actionview//lib/action_view/buffers.rb#27 + # source://actionview//lib/action_view/buffers.rb#81 + def ==(other); end + + # source://actionview//lib/action_view/buffers.rb#42 def append=(value); end - # source://activesupport/7.0.5/lib/active_support/core_ext/string/output_safety.rb#195 + # source://actionview//lib/action_view/buffers.rb#27 + def blank?(*_arg0, **_arg1, &_arg2); end + + # source://actionview//lib/action_view/buffers.rb#72 + def capture(*args); end + + # source://actionview//lib/action_view/buffers.rb#42 + def concat(value); end + + # source://actionview//lib/action_view/buffers.rb#27 + def empty?(*_arg0, **_arg1, &_arg2); end + + # source://actionview//lib/action_view/buffers.rb#27 + def encode!(*_arg0, **_arg1, &_arg2); end + + # source://actionview//lib/action_view/buffers.rb#27 + def encoding(*_arg0, **_arg1, &_arg2); end + + # source://actionview//lib/action_view/buffers.rb#27 + def force_encoding(*_arg0, **_arg1, &_arg2); end + + # source://actionview//lib/action_view/buffers.rb#29 + def html_safe; end + + # @return [Boolean] + # + # source://actionview//lib/action_view/buffers.rb#38 + def html_safe?; end + + # source://actionview//lib/action_view/buffers.rb#27 + def length(*_arg0, **_arg1, &_arg2); end + + # source://actionview//lib/action_view/buffers.rb#85 + def raw; end + + # Returns the value of attribute raw_buffer. + # + # source://actionview//lib/action_view/buffers.rb#89 + def raw_buffer; end + + # source://actionview//lib/action_view/buffers.rb#56 def safe_append=(value); end - # source://actionview//lib/action_view/buffers.rb#33 + # source://actionview//lib/action_view/buffers.rb#56 + def safe_concat(value); end + + # source://actionview//lib/action_view/buffers.rb#62 def safe_expr_append=(val); end + + # source://actionview//lib/action_view/buffers.rb#29 + def to_s; end + + # source://actionview//lib/action_view/buffers.rb#34 + def to_str; end + + private + + # source://actionview//lib/action_view/buffers.rb#68 + def initialize_copy(other); end end # source://actionview//lib/action_view/flows.rb#6 @@ -12649,7 +13341,7 @@ class ActionView::PartialRenderer < ::ActionView::AbstractRenderer private - # source://actionview//lib/action_view/renderer/partial_renderer.rb#261 + # source://actionview//lib/action_view/renderer/partial_renderer.rb#262 def find_template(path, locals); end # source://actionview//lib/action_view/renderer/partial_renderer.rb#245 @@ -12667,6 +13359,31 @@ class ActionView::PartialRenderer < ::ActionView::AbstractRenderer end end +# source://actionview//lib/action_view/path_registry.rb#4 +module ActionView::PathRegistry + class << self + # source://actionview//lib/action_view/path_registry.rb#53 + def all_file_system_resolvers; end + + # source://actionview//lib/action_view/path_registry.rb#47 + def all_resolvers; end + + # source://actionview//lib/action_view/path_registry.rb#22 + def cast_file_system_resolvers(paths); end + + # Returns the value of attribute file_system_resolver_hooks. + # + # source://actionview//lib/action_view/path_registry.rb#11 + def file_system_resolver_hooks; end + + # source://actionview//lib/action_view/path_registry.rb#14 + def get_view_paths(klass); end + + # source://actionview//lib/action_view/path_registry.rb#18 + def set_view_paths(klass, paths); end + end +end + # = Action View PathSet # # This class is used to store and access paths in Action View. A number of @@ -12685,10 +13402,7 @@ class ActionView::PathSet def initialize(paths = T.unsafe(nil)); end # source://actionview//lib/action_view/path_set.rb#35 - def +(array); end - - # source://actionview//lib/action_view/path_set.rb#41 - def <<(*args); end + def +(other); end # source://actionview//lib/action_view/path_set.rb#16 def [](*_arg0, **_arg1, &_arg2); end @@ -12696,66 +13410,86 @@ class ActionView::PathSet # source://actionview//lib/action_view/path_set.rb#31 def compact; end - # source://actionview//lib/action_view/path_set.rb#41 - def concat(*args); end - # source://actionview//lib/action_view/path_set.rb#16 def each(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://actionview//lib/action_view/path_set.rb#60 + # source://actionview//lib/action_view/path_set.rb#53 def exists?(path, prefixes, partial, details, details_key, locals); end - # source://actionview//lib/action_view/path_set.rb#47 + # source://actionview//lib/action_view/path_set.rb#40 def find(path, prefixes, partial, details, details_key, locals); end - # source://actionview//lib/action_view/path_set.rb#52 + # source://actionview//lib/action_view/path_set.rb#45 def find_all(path, prefixes, partial, details, details_key, locals); end # source://actionview//lib/action_view/path_set.rb#16 def include?(*_arg0, **_arg1, &_arg2); end - # source://actionview//lib/action_view/path_set.rb#41 - def insert(*args); end - # Returns the value of attribute paths. # # source://actionview//lib/action_view/path_set.rb#14 def paths; end - # source://actionview//lib/action_view/path_set.rb#16 - def pop(*_arg0, **_arg1, &_arg2); end - - # source://actionview//lib/action_view/path_set.rb#41 - def push(*args); end - # source://actionview//lib/action_view/path_set.rb#16 def size(*_arg0, **_arg1, &_arg2); end # source://actionview//lib/action_view/path_set.rb#27 def to_ary; end - # source://actionview//lib/action_view/path_set.rb#41 - def unshift(*args); end - private # source://actionview//lib/action_view/path_set.rb#22 def initialize_copy(other); end - # source://actionview//lib/action_view/path_set.rb#65 + # source://actionview//lib/action_view/path_set.rb#58 def search_combinations(prefixes); end - # source://actionview//lib/action_view/path_set.rb#74 + # source://actionview//lib/action_view/path_set.rb#67 def typecast(paths); end end # = Action View Railtie # # source://actionview//lib/action_view/railtie.rb#8 -class ActionView::Railtie < ::Rails::Engine; end +class ActionView::Railtie < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end + +# source://actionview//lib/action_view/buffers.rb#92 +class ActionView::RawOutputBuffer + # @return [RawOutputBuffer] a new instance of RawOutputBuffer + # + # source://actionview//lib/action_view/buffers.rb#93 + def initialize(buffer); end + + # source://actionview//lib/action_view/buffers.rb#97 + def <<(value); end + + # source://actionview//lib/action_view/buffers.rb#103 + def raw; end +end + +# source://actionview//lib/action_view/buffers.rb#150 +class ActionView::RawStreamingBuffer + # @return [RawStreamingBuffer] a new instance of RawStreamingBuffer + # + # source://actionview//lib/action_view/buffers.rb#151 + def initialize(buffer); end + + # source://actionview//lib/action_view/buffers.rb#155 + def <<(value); end + # source://actionview//lib/action_view/buffers.rb#161 + def raw; end +end + +# = Action View \Record \Identifier +# # RecordIdentifier encapsulates methods used by various ActionView helpers # to associate records with DOM elements. # @@ -12783,6 +13517,8 @@ class ActionView::Railtie < ::Rails::Engine; end # automatically generated, following naming conventions encapsulated by the # RecordIdentifier methods #dom_id and #dom_class: # +# dom_id(Post) # => "new_post" +# dom_class(Post) # => "post" # dom_id(Post.new) # => "new_post" # dom_class(Post.new) # => "post" # dom_id(Post.find 42) # => "post_42" @@ -12806,7 +13542,7 @@ class ActionView::Railtie < ::Rails::Engine; end # end # end # -# source://actionview//lib/action_view/record_identifier.rb#56 +# source://actionview//lib/action_view/record_identifier.rb#60 module ActionView::RecordIdentifier include ::ActionView::ModelNaming extend ::ActionView::RecordIdentifier @@ -12822,22 +13558,24 @@ module ActionView::RecordIdentifier # dom_class(post, :edit) # => "edit_post" # dom_class(Person, :edit) # => "edit_person" # - # source://actionview//lib/action_view/record_identifier.rb#74 + # source://actionview//lib/action_view/record_identifier.rb#78 def dom_class(record_or_class, prefix = T.unsafe(nil)); end # The DOM id convention is to use the singular form of an object or class with the id following an underscore. # If no id is found, prefix with "new_" instead. # - # dom_id(Post.find(45)) # => "post_45" - # dom_id(Post.new) # => "new_post" + # dom_id(Post.find(45)) # => "post_45" + # dom_id(Post) # => "new_post" # # If you need to address multiple instances of the same class in the same view, you can prefix the dom_id: # # dom_id(Post.find(45), :edit) # => "edit_post_45" - # dom_id(Post.new, :custom) # => "custom_post" + # dom_id(Post, :custom) # => "custom_post" + # + # @raise [ArgumentError] # - # source://actionview//lib/action_view/record_identifier.rb#89 - def dom_id(record, prefix = T.unsafe(nil)); end + # source://actionview//lib/action_view/record_identifier.rb#93 + def dom_id(record_or_class, prefix = T.unsafe(nil)); end private @@ -12850,779 +13588,67 @@ module ActionView::RecordIdentifier # method that replaces all characters that are invalid inside DOM ids, with valid ones. You need to # make sure yourself that your dom ids are valid, in case you override this method. # - # source://actionview//lib/action_view/record_identifier.rb#106 + # source://actionview//lib/action_view/record_identifier.rb#113 def record_key_for_dom_id(record); end end -# source://actionview//lib/action_view/record_identifier.rb#62 +# source://actionview//lib/action_view/record_identifier.rb#66 ActionView::RecordIdentifier::JOIN = T.let(T.unsafe(nil), String) -# source://actionview//lib/action_view/record_identifier.rb#63 +# source://actionview//lib/action_view/record_identifier.rb#67 ActionView::RecordIdentifier::NEW = T.let(T.unsafe(nil), String) -# source://actionview//lib/action_view/ripper_ast_parser.rb#6 -class ActionView::RenderParser - # @return [RenderParser] a new instance of RenderParser +# source://actionview//lib/action_view/render_parser.rb#4 +module ActionView::RenderParser; end + +# source://actionview//lib/action_view/render_parser.rb#5 +ActionView::RenderParser::ALL_KNOWN_KEYS = T.let(T.unsafe(nil), Array) + +# source://actionview//lib/action_view/render_parser.rb#8 +class ActionView::RenderParser::Base + # @return [Base] a new instance of Base # - # source://actionview//lib/action_view/render_parser.rb#7 + # source://actionview//lib/action_view/render_parser.rb#9 def initialize(name, code); end - # source://actionview//lib/action_view/render_parser.rb#13 - def render_calls; end - private - # source://actionview//lib/action_view/render_parser.rb#22 + # source://actionview//lib/action_view/render_parser.rb#15 def directory; end - # source://actionview//lib/action_view/render_parser.rb#184 - def layout_to_virtual_path(layout_path); end - - # Convert - # render("foo", ...) - # into either - # render(template: "foo", ...) - # or - # render(partial: "foo", ...) - # - # source://actionview//lib/action_view/render_parser.rb#40 - def normalize_args(string, options_hash); end - - # source://actionview//lib/action_view/render_parser.rb#72 - def parse_hash(node); end - - # source://actionview//lib/action_view/render_parser.rb#76 - def parse_hash_to_symbols(node); end - - # source://actionview//lib/action_view/render_parser.rb#48 - def parse_render(node); end - - # source://actionview//lib/action_view/render_parser.rb#95 - def parse_render_from_options(options_hash); end - - # source://actionview//lib/action_view/render_parser.rb#155 - def parse_str(node); end - - # source://actionview//lib/action_view/render_parser.rb#159 - def parse_sym(node); end - - # source://actionview//lib/action_view/render_parser.rb#176 + # source://actionview//lib/action_view/render_parser.rb#19 def partial_to_virtual_path(render_type, partial_path); end - - # @return [Boolean] - # - # source://actionview//lib/action_view/render_parser.rb#164 - def render_template_with_layout?(render_type, options_hash); end - - # @return [Boolean] - # - # source://actionview//lib/action_view/render_parser.rb#170 - def render_template_with_spacer?(options_hash); end - - # source://actionview//lib/action_view/render_parser.rb#26 - def resolve_path_directory(path); end -end - -# source://actionview//lib/action_view/render_parser.rb#90 -ActionView::RenderParser::ALL_KNOWN_KEYS = T.let(T.unsafe(nil), Array) - -# source://actionview//lib/action_view/render_parser.rb#92 -ActionView::RenderParser::RENDER_TYPE_KEYS = T.let(T.unsafe(nil), Array) - -# source://actionview//lib/action_view/ripper_ast_parser.rb#7 -module ActionView::RenderParser::RipperASTParser - extend ::ActionView::RenderParser::RipperASTParser - - # source://actionview//lib/action_view/ripper_ast_parser.rb#188 - def parse_render_nodes(code); end -end - -# source://actionview//lib/action_view/ripper_ast_parser.rb#8 -class ActionView::RenderParser::RipperASTParser::Node < ::Array - # @return [Node] a new instance of Node - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#11 - def initialize(type, arr, opts = T.unsafe(nil)); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#35 - def argument_nodes; end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#57 - def call?; end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#65 - def call_method_name; end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#16 - def children; end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#25 - def fcall?; end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#29 - def fcall_named?(name); end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#74 - def hash?; end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#88 - def hash_from_body(body); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#20 - def inspect; end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#45 - def string?; end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#96 - def symbol?; end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#78 - def to_hash; end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#69 - def to_string; end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#100 - def to_symbol; end - - # Returns the value of attribute type. - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#9 - def type; end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#61 - def variable_name; end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#49 - def variable_reference?; end - - # @return [Boolean] - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#53 - def vcall?; end -end - -# source://actionview//lib/action_view/ripper_ast_parser.rb#111 -class ActionView::RenderParser::RipperASTParser::NodeParser < ::Ripper - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_BEGIN(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_CHAR(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_END(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on___end__(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_alias(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_alias_error(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_aref(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_aref_field(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_arg_ambiguous(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_arg_paren(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_args_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_args_add_block(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_args_add_star(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_args_forward(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_args_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_array(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_aryptn(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_assign(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_assign_error(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_assoc_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_assoc_splat(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_assoclist_from_args(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_backref(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_backtick(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_bare_assoc_hash(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_begin(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_binary(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_block_var(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_blockarg(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_bodystmt(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_brace_block(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_break(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_call(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_case(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_class(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_class_name_error(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_comma(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_command(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_command_call(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_comment(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_const(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_const_path_field(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_const_path_ref(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_const_ref(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_cvar(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_def(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_defined(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_defs(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_do_block(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_dot2(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_dot3(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_dyna_symbol(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_else(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_elsif(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_embdoc(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_embdoc_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_embdoc_end(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_embexpr_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_embexpr_end(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_embvar(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_ensure(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_excessed_comma(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_fcall(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_field(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_float(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_fndptn(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_for(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_gvar(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_hash(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_heredoc_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_heredoc_dedent(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_heredoc_end(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_hshptn(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_ident(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_if(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_if_mod(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_ifop(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_ignored_nl(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_ignored_sp(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_imaginary(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_in(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_int(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_ivar(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_kw(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_kwrest_param(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_label(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_label_end(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_lambda(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_lbrace(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_lbracket(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_lparen(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_magic_comment(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_massign(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_method_add_arg(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_method_add_block(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_mlhs_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_mlhs_add_post(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_mlhs_add_star(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_mlhs_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_mlhs_paren(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_module(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_mrhs_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_mrhs_add_star(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_mrhs_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_mrhs_new_from_args(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_next(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_nl(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_nokw_param(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_op(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_opassign(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_operator_ambiguous(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_param_error(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_params(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_paren(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_parse_error(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_period(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_program(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_qsymbols_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_qsymbols_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_qsymbols_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_qwords_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_qwords_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_qwords_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_rational(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_rbrace(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_rbracket(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_redo(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_regexp_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_regexp_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_regexp_end(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_regexp_literal(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_regexp_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_rescue(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_rescue_mod(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_rest_param(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_retry(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_return(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_return0(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_rparen(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_sclass(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_semicolon(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_sp(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_stmts_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_stmts_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_string_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_string_concat(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_string_content(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_string_dvar(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_string_embexpr(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_string_literal(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_super(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_symbeg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_symbol(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_symbol_literal(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_symbols_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_symbols_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_symbols_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_tlambda(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_tlambeg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_top_const_field(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_top_const_ref(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_tstring_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_tstring_content(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_tstring_end(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_unary(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_undef(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_unless(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_unless_mod(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_until(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_until_mod(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_var_alias(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_var_field(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_var_ref(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_vcall(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_void_stmt(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_when(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_while(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_while_mod(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_word_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_word_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_words_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_words_beg(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_words_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#140 - def on_words_sep(tok); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#123 - def on_xstring_add(list, item); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_xstring_literal(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#116 - def on_xstring_new(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_yield(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_yield0(*args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#131 - def on_zsuper(*args); end end -# source://actionview//lib/action_view/ripper_ast_parser.rb#147 -class ActionView::RenderParser::RipperASTParser::RenderCallExtractor < ::ActionView::RenderParser::RipperASTParser::NodeParser - # @return [RenderCallExtractor] a new instance of RenderCallExtractor - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#152 - def initialize(*args); end +# source://actionview//lib/action_view/render_parser.rb#37 +ActionView::RenderParser::Default = ActionView::RenderParser::PrismRenderParser - # Returns the value of attribute render_calls. - # - # source://actionview//lib/action_view/ripper_ast_parser.rb#148 +# source://actionview//lib/action_view/render_parser/prism_render_parser.rb#5 +class ActionView::RenderParser::PrismRenderParser < ::ActionView::RenderParser::Base + # source://actionview//lib/action_view/render_parser/prism_render_parser.rb#6 def render_calls; end private - # source://actionview//lib/action_view/ripper_ast_parser.rb#177 - def on_arg_paren(content); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#163 - def on_command(name, *args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#159 - def on_fcall(name, *args); end - - # source://actionview//lib/action_view/ripper_ast_parser.rb#181 - def on_paren(content); end + # Accept a call node and return a hash of options for the render call. + # If it doesn't match the expected format, return nil. + # + # source://actionview//lib/action_view/render_parser/prism_render_parser.rb#43 + def render_call_options(node); end - # source://actionview//lib/action_view/ripper_ast_parser.rb#167 - def on_render_call(node); end + # Accept the node that is being passed in the position of the template + # and return the template name and whether or not it is an object + # template. + # + # source://actionview//lib/action_view/render_parser/prism_render_parser.rb#97 + def render_call_template(node); end end -# source://actionview//lib/action_view/ripper_ast_parser.rb#150 -ActionView::RenderParser::RipperASTParser::RenderCallExtractor::METHODS_TO_PARSE = T.let(T.unsafe(nil), Array) +# source://actionview//lib/action_view/render_parser.rb#6 +ActionView::RenderParser::RENDER_TYPE_KEYS = T.let(T.unsafe(nil), Array) +# = Action View \Renderer +# # This is the main entry point for rendering. It basically delegates # to other objects like TemplateRenderer and PartialRenderer which # actually renders the template. @@ -13633,31 +13659,31 @@ ActionView::RenderParser::RipperASTParser::RenderCallExtractor::METHODS_TO_PARSE # the setup and logic necessary to render a view and a new object is created # each time +render+ is called. # -# source://actionview//lib/action_view/renderer/renderer.rb#13 +# source://actionview//lib/action_view/renderer/renderer.rb#15 class ActionView::Renderer # @return [Renderer] a new instance of Renderer # - # source://actionview//lib/action_view/renderer/renderer.rb#16 + # source://actionview//lib/action_view/renderer/renderer.rb#18 def initialize(lookup_context); end - # source://actionview//lib/action_view/renderer/renderer.rb#56 + # source://actionview//lib/action_view/renderer/renderer.rb#52 def cache_hits; end # Returns the value of attribute lookup_context. # - # source://actionview//lib/action_view/renderer/renderer.rb#14 + # source://actionview//lib/action_view/renderer/renderer.rb#16 def lookup_context; end # Sets the attribute lookup_context # # @param value the value to set the attribute lookup_context to. # - # source://actionview//lib/action_view/renderer/renderer.rb#14 + # source://actionview//lib/action_view/renderer/renderer.rb#16 def lookup_context=(_arg0); end # Main render entry point shared by Action View and Action Controller. # - # source://actionview//lib/action_view/renderer/renderer.rb#21 + # source://actionview//lib/action_view/renderer/renderer.rb#23 def render(context, options); end # Render but returns a valid Rack body. If fibers are defined, we return @@ -13666,38 +13692,31 @@ class ActionView::Renderer # Note that partials are not supported to be rendered with streaming, # so in such cases, we just wrap them in an array. # - # source://actionview//lib/action_view/renderer/renderer.rb#38 + # source://actionview//lib/action_view/renderer/renderer.rb#40 def render_body(context, options); end - # Direct access to partial rendering. - # - # source://actionview//lib/action_view/renderer/renderer.rb#52 + # source://actionview//lib/action_view/renderer/renderer.rb#48 def render_partial(context, options, &block); end - # source://actionview//lib/action_view/renderer/renderer.rb#64 - def render_partial_to_object(context, options, &block); end - - # Direct access to template rendering. - # - # source://actionview//lib/action_view/renderer/renderer.rb#47 - def render_template(context, options); end - - # source://actionview//lib/action_view/renderer/renderer.rb#60 - def render_template_to_object(context, options); end - - # source://actionview//lib/action_view/renderer/renderer.rb#25 + # source://actionview//lib/action_view/renderer/renderer.rb#27 def render_to_object(context, options); end private - # source://actionview//lib/action_view/renderer/renderer.rb#107 + # source://actionview//lib/action_view/renderer/renderer.rb#103 def collection_from_object(object); end - # source://actionview//lib/action_view/renderer/renderer.rb#100 + # source://actionview//lib/action_view/renderer/renderer.rb#96 def collection_from_options(options); end + + # source://actionview//lib/action_view/renderer/renderer.rb#61 + def render_partial_to_object(context, options, &block); end + + # source://actionview//lib/action_view/renderer/renderer.rb#57 + def render_template_to_object(context, options); end end -# source://actionview//lib/action_view/rendering.rb#25 +# source://actionview//lib/action_view/rendering.rb#26 module ActionView::Rendering extend ::ActiveSupport::Concern include ::ActionView::ViewPaths @@ -13705,20 +13724,17 @@ module ActionView::Rendering mixes_in_class_methods ::ActionView::ViewPaths::ClassMethods mixes_in_class_methods ::ActionView::Rendering::ClassMethods - # source://actionview//lib/action_view/rendering.rb#31 + # source://actionview//lib/action_view/rendering.rb#32 def initialize; end # Override process to set up I18n proxy. # - # source://actionview//lib/action_view/rendering.rb#37 + # source://actionview//lib/action_view/rendering.rb#38 def process(*_arg0, **_arg1, &_arg2); end - # source://actionview//lib/action_view/rendering.rb#101 + # source://actionview//lib/action_view/rendering.rb#119 def render_to_body(options = T.unsafe(nil)); end - # Returns the value of attribute rendered_format. - # - # source://actionview//lib/action_view/rendering.rb#29 def rendered_format; end # An instance of a view class. The default view class is ActionView::Base. @@ -13732,53 +13748,61 @@ module ActionView::Rendering # # Override this method in a module to change the default behavior. # - # source://actionview//lib/action_view/rendering.rb#91 + # source://actionview//lib/action_view/rendering.rb#109 def view_context; end - # source://actionview//lib/action_view/rendering.rb#77 + # source://actionview//lib/action_view/rendering.rb#95 def view_context_class; end # Returns an object that is able to render templates. # - # source://actionview//lib/action_view/rendering.rb#96 + # source://actionview//lib/action_view/rendering.rb#114 def view_renderer; end private - # Normalize args by converting render "foo" to render :action => "foo" and - # render "foo/bar" to render :template => "foo/bar". + # Normalize args by converting render "foo" to render action: "foo" and + # render "foo/bar" to render template: "foo/bar". # - # source://actionview//lib/action_view/rendering.rb#134 + # source://actionview//lib/action_view/rendering.rb#152 def _normalize_args(action = T.unsafe(nil), options = T.unsafe(nil)); end # Normalize options. # - # source://actionview//lib/action_view/rendering.rb#158 + # source://actionview//lib/action_view/rendering.rb#176 def _normalize_options(options); end # Assign the rendered format to look up context. # - # source://actionview//lib/action_view/rendering.rb#127 + # source://actionview//lib/action_view/rendering.rb#145 def _process_format(format); end # Find and render a template based on the options given. # - # source://actionview//lib/action_view/rendering.rb#108 + # source://actionview//lib/action_view/rendering.rb#126 def _render_template(options); end end -# source://actionview//lib/action_view/rendering.rb#44 +# source://actionview//lib/action_view/rendering.rb#45 module ActionView::Rendering::ClassMethods - # source://actionview//lib/action_view/rendering.rb#48 + # source://actionview//lib/action_view/rendering.rb#49 def _helpers; end - # source://actionview//lib/action_view/rendering.rb#45 + # source://actionview//lib/action_view/rendering.rb#46 def _routes; end - # source://actionview//lib/action_view/rendering.rb#51 + # source://actionview//lib/action_view/rendering.rb#59 def build_view_context_class(klass, supports_path, routes, helpers); end - # source://actionview//lib/action_view/rendering.rb#64 + # source://actionview//lib/action_view/rendering.rb#76 + def eager_load!; end + + # @return [Boolean] + # + # source://actionview//lib/action_view/rendering.rb#52 + def inherit_view_context_class?; end + + # source://actionview//lib/action_view/rendering.rb#82 def view_context_class; end end @@ -13786,29 +13810,32 @@ end # # source://actionview//lib/action_view/template/resolver.rb#12 class ActionView::Resolver - # source://actionview//lib/action_view/template/resolver.rb#68 + # source://actionview//lib/action_view/template/resolver.rb#70 def all_template_paths; end - # source://actionview//lib/action_view/template/resolver.rb#54 + # source://actionview//lib/action_view/template/resolver.rb#65 + def built_templates; end + + # source://actionview//lib/action_view/template/resolver.rb#51 def caching; end - # source://actionview//lib/action_view/template/resolver.rb#54 + # source://actionview//lib/action_view/template/resolver.rb#51 def caching=(val); end - # source://actionview//lib/action_view/template/resolver.rb#78 - def caching?(*_arg0, **_arg1, &_arg2); end + # source://actionview//lib/action_view/template/resolver.rb#80 + def caching?(&_arg0); end - # source://actionview//lib/action_view/template/resolver.rb#60 + # source://actionview//lib/action_view/template/resolver.rb#57 def clear_cache; end # Normalizes the arguments and passes it on to find_templates. # - # source://actionview//lib/action_view/template/resolver.rb#64 + # source://actionview//lib/action_view/template/resolver.rb#61 def find_all(name, prefix = T.unsafe(nil), partial = T.unsafe(nil), details = T.unsafe(nil), key = T.unsafe(nil), locals = T.unsafe(nil)); end private - # source://actionview//lib/action_view/template/resolver.rb#74 + # source://actionview//lib/action_view/template/resolver.rb#76 def _find_all(name, prefix, partial, details, key, locals); end # This is what child classes implement. No defaults are needed @@ -13817,34 +13844,31 @@ class ActionView::Resolver # # @raise [NotImplementedError] # - # source://actionview//lib/action_view/template/resolver.rb#83 + # source://actionview//lib/action_view/template/resolver.rb#85 def find_templates(name, prefix, partial, details, locals = T.unsafe(nil)); end class << self - # source://actionview//lib/action_view/template/resolver.rb#54 + # source://actionview//lib/action_view/template/resolver.rb#51 def caching; end - # source://actionview//lib/action_view/template/resolver.rb#54 + # source://actionview//lib/action_view/template/resolver.rb#51 def caching=(val); end - # source://actionview//lib/action_view/template/resolver.rb#54 + # source://actionview//lib/action_view/template/resolver.rb#51 def caching?; end end end # source://actionview//lib/action_view/template/resolver.rb#13 -ActionView::Resolver::Path = ActionView::TemplatePath - -# source://actionview//lib/action_view/template/resolver.rb#16 class ActionView::Resolver::PathParser - # source://actionview//lib/action_view/template/resolver.rb#19 + # source://actionview//lib/action_view/template/resolver.rb#16 def build_path_regex; end - # source://actionview//lib/action_view/template/resolver.rb#40 + # source://actionview//lib/action_view/template/resolver.rb#37 def parse(path); end end -# source://actionview//lib/action_view/template/resolver.rb#17 +# source://actionview//lib/action_view/template/resolver.rb#14 class ActionView::Resolver::PathParser::ParsedPath < ::Struct # Returns the value of attribute details # @@ -13879,6 +13903,11 @@ end # source://actionview//lib/action_view/routing_url_for.rb#6 module ActionView::RoutingUrlFor + include ::ActionDispatch::Routing::PolymorphicRoutes + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#102 + def default_url_options=(val); end + # Returns the URL for the set of +options+ provided. This takes the # same options as +url_for+ in Action Controller (see the # documentation for ActionDispatch::Routing::UrlFor#url_for). Note that by default @@ -13976,36 +14005,52 @@ module ActionView::RoutingUrlFor # # source://actionview//lib/action_view/routing_url_for.rb#134 def optimize_routes_generation?; end + + class << self + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#102 + def default_url_options=(val); end + end end -# source://actionview//lib/action_view/buffers.rb#41 +# source://actionview//lib/action_view/buffers.rb#108 class ActionView::StreamingBuffer # @return [StreamingBuffer] a new instance of StreamingBuffer # - # source://actionview//lib/action_view/buffers.rb#42 + # source://actionview//lib/action_view/buffers.rb#109 def initialize(block); end - # source://actionview//lib/action_view/buffers.rb#46 + # source://actionview//lib/action_view/buffers.rb#113 def <<(value); end - # source://actionview//lib/action_view/buffers.rb#46 + # source://actionview//lib/action_view/buffers.rb#113 def append=(value); end - # source://actionview//lib/action_view/buffers.rb#46 + # Returns the value of attribute block. + # + # source://actionview//lib/action_view/buffers.rb#147 + def block; end + + # source://actionview//lib/action_view/buffers.rb#126 + def capture; end + + # source://actionview//lib/action_view/buffers.rb#113 def concat(value); end - # source://actionview//lib/action_view/buffers.rb#63 + # source://actionview//lib/action_view/buffers.rb#139 def html_safe; end # @return [Boolean] # - # source://actionview//lib/action_view/buffers.rb#59 + # source://actionview//lib/action_view/buffers.rb#135 def html_safe?; end - # source://actionview//lib/action_view/buffers.rb#54 + # source://actionview//lib/action_view/buffers.rb#143 + def raw; end + + # source://actionview//lib/action_view/buffers.rb#121 def safe_append=(value); end - # source://actionview//lib/action_view/buffers.rb#54 + # source://actionview//lib/action_view/buffers.rb#121 def safe_concat(value); end end @@ -14080,21 +14125,21 @@ class ActionView::StreamingTemplateRenderer::Body def log_error(exception); end end -# source://actionview//lib/action_view/template/error.rb#232 +# source://actionview//lib/action_view/template/error.rb#245 class ActionView::SyntaxErrorInTemplate < ::ActionView::Template::Error # @return [SyntaxErrorInTemplate] a new instance of SyntaxErrorInTemplate # - # source://actionview//lib/action_view/template/error.rb#233 + # source://actionview//lib/action_view/template/error.rb#246 def initialize(template, offending_code_string); end - # source://actionview//lib/action_view/template/error.rb#244 + # source://actionview//lib/action_view/template/error.rb#257 def annotated_source_code; end - # source://actionview//lib/action_view/template/error.rb#238 + # source://actionview//lib/action_view/template/error.rb#251 def message; end end -# = Action View Template +# = Action View \Template # # source://actionview//lib/action_view/template.rb#8 class ActionView::Template @@ -14103,7 +14148,7 @@ class ActionView::Template # @return [Template] a new instance of Template # - # source://actionview//lib/action_view/template.rb#123 + # source://actionview//lib/action_view/template.rb#200 def initialize(source, identifier, handler, locals:, format: T.unsafe(nil), variant: T.unsafe(nil), virtual_path: T.unsafe(nil)); end # This method is responsible for properly setting the encoding of the @@ -14116,42 +14161,46 @@ class ActionView::Template # before passing the source on to the template engine, leaving a # blank line in its stead. # - # source://actionview//lib/action_view/template.rb#189 + # source://actionview//lib/action_view/template.rb#312 def encode!; end # Returns the value of attribute format. # - # source://actionview//lib/action_view/template.rb#121 + # source://actionview//lib/action_view/template.rb#196 def format; end # Returns the value of attribute handler. # - # source://actionview//lib/action_view/template.rb#120 + # source://actionview//lib/action_view/template.rb#195 def handler; end # Returns the value of attribute identifier. # - # source://actionview//lib/action_view/template.rb#120 + # source://actionview//lib/action_view/template.rb#195 def identifier; end - # source://actionview//lib/action_view/template.rb#171 + # source://actionview//lib/action_view/template.rb#291 def inspect; end - # Returns the value of attribute locals. + # The locals this template has been or will be compiled for, or nil if this + # is a strict locals template. # - # source://actionview//lib/action_view/template.rb#121 + # source://actionview//lib/action_view/template.rb#224 def locals; end # Exceptions are marshalled when using the parallel test runner with DRb, so we need # to ensure that references to the template object can be marshalled as well. This means forgoing # the marshalling of the compiler mutex and instantiating that again on unmarshalling. # - # source://actionview//lib/action_view/template.rb#229 + # source://actionview//lib/action_view/template.rb#378 def marshal_dump; end - # source://actionview//lib/action_view/template.rb#233 + # source://actionview//lib/action_view/template.rb#382 def marshal_load(array); end + # source://actionview//lib/action_view/template.rb#387 + def method_name; end + # Render a template. If the template was not compiled yet, it is done # exactly before rendering. # @@ -14159,39 +14208,68 @@ class ActionView::Template # we use a bang in this instrumentation because you don't want to # consume this in production. This is only slow if it's being listened to. # - # source://actionview//lib/action_view/template.rb#154 - def render(view, locals, buffer = T.unsafe(nil), add_to_stack: T.unsafe(nil), &block); end + # source://actionview//lib/action_view/template.rb#262 + def render(view, locals, buffer = T.unsafe(nil), implicit_locals: T.unsafe(nil), add_to_stack: T.unsafe(nil), &block); end - # source://actionview//lib/action_view/template.rb#167 + # source://actionview//lib/action_view/template.rb#287 def short_identifier; end - # source://actionview//lib/action_view/template.rb#175 + # source://actionview//lib/action_view/template.rb#295 def source; end + # source://actionview//lib/action_view/template.rb#232 + def spot(location); end + + # This method is responsible for marking a template as having strict locals + # which means the template can only accept the locals defined in a magic + # comment. For example, if your template acceps the locals +title+ and + # +comment_count+, add the following to your template file: + # + # <%# locals: (title: "Default title", comment_count: 0) %> + # + # Strict locals are useful for validating template arguments and for + # specifying defaults. + # + # source://actionview//lib/action_view/template.rb#357 + def strict_locals!; end + + # Returns whether a template is using strict locals. + # + # @return [Boolean] + # + # source://actionview//lib/action_view/template.rb#371 + def strict_locals?; end + # Returns whether the underlying handler supports streaming. If so, # a streaming buffer *may* be passed when it starts rendering. # # @return [Boolean] # - # source://actionview//lib/action_view/template.rb#144 + # source://actionview//lib/action_view/template.rb#252 def supports_streaming?; end - # source://actionview//lib/action_view/template.rb#163 + # Translate an error location returned by ErrorHighlight to the correct + # source location inside the template. + # + # source://actionview//lib/action_view/template.rb#242 + def translate_location(backtrace_location, spot); end + + # source://actionview//lib/action_view/template.rb#283 def type; end # Returns the value of attribute variable. # - # source://actionview//lib/action_view/template.rb#121 + # source://actionview//lib/action_view/template.rb#196 def variable; end # Returns the value of attribute variant. # - # source://actionview//lib/action_view/template.rb#121 + # source://actionview//lib/action_view/template.rb#196 def variant; end # Returns the value of attribute virtual_path. # - # source://actionview//lib/action_view/template.rb#121 + # source://actionview//lib/action_view/template.rb#196 def virtual_path; end private @@ -14208,42 +14286,55 @@ class ActionView::Template # In general, this means that templates will be UTF-8 inside of Rails, # regardless of the original source encoding. # - # source://actionview//lib/action_view/template.rb#275 + # source://actionview//lib/action_view/template.rb#491 def compile(mod); end # Compile a template. This method ensures a template is compiled # just once and removes the source after it is compiled. # - # source://actionview//lib/action_view/template.rb#241 + # source://actionview//lib/action_view/template.rb#409 def compile!(view); end - # source://actionview//lib/action_view/template.rb#316 + # This method compiles the source of the template. The compilation of templates + # involves setting strict_locals! if applicable, encoding the template, and setting + # frozen string literal. + # + # source://actionview//lib/action_view/template.rb#434 + def compiled_source; end + + # source://actionview//lib/action_view/template.rb#396 + def find_node_by_id(node, node_id); end + + # source://actionview//lib/action_view/template.rb#540 def handle_render_error(view, e); end - # source://actionview//lib/action_view/template.rb#352 + # source://actionview//lib/action_view/template.rb#565 def identifier_method_name; end - # source://actionview//lib/action_view/template.rb#356 + # source://actionview//lib/action_view/template.rb#569 def instrument(action, &block); end - # source://actionview//lib/action_view/template.rb#364 + # source://actionview//lib/action_view/template.rb#577 def instrument_payload; end - # source://actionview//lib/action_view/template.rb#360 + # source://actionview//lib/action_view/template.rb#573 def instrument_render_template(&block); end - # source://actionview//lib/action_view/template.rb#325 + # source://actionview//lib/action_view/template.rb#552 def locals_code; end - # source://actionview//lib/action_view/template.rb#344 - def method_name; end + # source://actionview//lib/action_view/template.rb#532 + def offset; end class << self - # source://actionview//lib/action_view/template.rb#117 + # source://actionview//lib/action_view/template.rb#181 def frozen_string_literal; end - # source://actionview//lib/action_view/template.rb#117 + # source://actionview//lib/action_view/template.rb#181 def frozen_string_literal=(_arg0); end + + # source://actionview//lib/action_view/template.rb#185 + def mime_types_implementation=(implementation); end end end @@ -14251,48 +14342,61 @@ end # fails. This exception then gathers a bunch of intimate details and uses it to report a # precise exception message. # -# source://actionview//lib/action_view/template/error.rb#153 +# source://actionview//lib/action_view/template/error.rb#154 class ActionView::Template::Error < ::ActionView::ActionViewError # @return [Error] a new instance of Error # - # source://actionview//lib/action_view/template/error.rb#159 + # source://actionview//lib/action_view/template/error.rb#162 def initialize(template); end - # source://actionview//lib/action_view/template/error.rb#207 + # source://actionview//lib/action_view/template/error.rb#220 def annotated_source_code; end + # source://actionview//lib/action_view/template/error.rb#171 + def backtrace; end + + # source://actionview//lib/action_view/template/error.rb#175 + def backtrace_locations; end + # Override to prevent #cause resetting during re-raise. # - # source://actionview//lib/action_view/template/error.rb#157 + # source://actionview//lib/action_view/template/error.rb#158 def cause; end - # source://actionview//lib/action_view/template/error.rb#166 + # source://actionview//lib/action_view/template/error.rb#179 def file_name; end - # source://actionview//lib/action_view/template/error.rb#199 + # source://actionview//lib/action_view/template/error.rb#212 def line_number; end - # source://actionview//lib/action_view/template/error.rb#179 + # source://actionview//lib/action_view/template/error.rb#192 def source_extract(indentation = T.unsafe(nil)); end - # source://actionview//lib/action_view/template/error.rb#170 + # source://actionview//lib/action_view/template/error.rb#183 def sub_template_message; end - # source://actionview//lib/action_view/template/error.rb#194 + # source://actionview//lib/action_view/template/error.rb#207 def sub_template_of(template_path); end + # Returns the value of attribute template. + # + # source://actionview//lib/action_view/template/error.rb#160 + def template; end + private - # source://actionview//lib/action_view/template/error.rb#220 + # source://actionview//lib/action_view/template/error.rb#233 def formatted_code_for(source_code, line_counter, indent); end - # source://actionview//lib/action_view/template/error.rb#212 + # source://actionview//lib/action_view/template/error.rb#225 def source_location; end end -# source://actionview//lib/action_view/template/error.rb#154 +# source://actionview//lib/action_view/template/error.rb#155 ActionView::Template::Error::SOURCE_CODE_RADIUS = T.let(T.unsafe(nil), Integer) +# = Action View HTML Template +# # source://actionview//lib/action_view/template/html.rb#6 class ActionView::Template::HTML # @return [HTML] a new instance of HTML @@ -14319,6 +14423,8 @@ class ActionView::Template::HTML def type; end end +# = Action View Template Handlers +# # source://actionview//lib/action_view/template/handlers.rb#6 module ActionView::Template::Handlers # source://actionview//lib/action_view/template/handlers.rb#61 @@ -14390,107 +14496,116 @@ class ActionView::Template::Handlers::Builder end end -# source://actionview//lib/action_view/template/handlers/erb.rb#6 +# source://actionview//lib/action_view/template/handlers/erb.rb#9 class ActionView::Template::Handlers::ERB - # source://actionview//lib/action_view/template/handlers/erb.rb#36 + # source://actionview//lib/action_view/template/handlers/erb.rb#61 def call(template, source); end - # source://actionview//lib/action_view/template/handlers/erb.rb#14 + # source://actionview//lib/action_view/template/handlers/erb.rb#17 def erb_implementation; end - # source://actionview//lib/action_view/template/handlers/erb.rb#14 + # source://actionview//lib/action_view/template/handlers/erb.rb#17 def erb_implementation=(_arg0); end - # source://actionview//lib/action_view/template/handlers/erb.rb#14 + # source://actionview//lib/action_view/template/handlers/erb.rb#17 def erb_implementation?; end - # source://actionview//lib/action_view/template/handlers/erb.rb#11 + # source://actionview//lib/action_view/template/handlers/erb.rb#14 def erb_trim_mode; end - # source://actionview//lib/action_view/template/handlers/erb.rb#11 + # source://actionview//lib/action_view/template/handlers/erb.rb#14 def erb_trim_mode=(_arg0); end - # source://actionview//lib/action_view/template/handlers/erb.rb#11 + # source://actionview//lib/action_view/template/handlers/erb.rb#14 def erb_trim_mode?; end - # source://actionview//lib/action_view/template/handlers/erb.rb#17 + # source://actionview//lib/action_view/template/handlers/erb.rb#20 def escape_ignore_list; end - # source://actionview//lib/action_view/template/handlers/erb.rb#17 + # source://actionview//lib/action_view/template/handlers/erb.rb#20 def escape_ignore_list=(_arg0); end - # source://actionview//lib/action_view/template/handlers/erb.rb#17 + # source://actionview//lib/action_view/template/handlers/erb.rb#20 def escape_ignore_list?; end # @return [Boolean] # - # source://actionview//lib/action_view/template/handlers/erb.rb#32 + # source://actionview//lib/action_view/template/handlers/erb.rb#37 def handles_encoding?; end - # source://actionview//lib/action_view/template/handlers/erb.rb#20 + # source://actionview//lib/action_view/template/handlers/erb.rb#23 def strip_trailing_newlines; end - # source://actionview//lib/action_view/template/handlers/erb.rb#20 + # source://actionview//lib/action_view/template/handlers/erb.rb#23 def strip_trailing_newlines=(_arg0); end - # source://actionview//lib/action_view/template/handlers/erb.rb#20 + # source://actionview//lib/action_view/template/handlers/erb.rb#23 def strip_trailing_newlines?; end # @return [Boolean] # - # source://actionview//lib/action_view/template/handlers/erb.rb#28 + # source://actionview//lib/action_view/template/handlers/erb.rb#33 def supports_streaming?; end + # Translate an error location returned by ErrorHighlight to the correct + # source location inside the template. + # + # source://actionview//lib/action_view/template/handlers/erb.rb#43 + def translate_location(spot, backtrace_location, source); end + private + # source://actionview//lib/action_view/template/handlers/erb.rb#108 + def find_offset(compiled, source_tokens, error_column); end + # @raise [WrongEncodingError] # - # source://actionview//lib/action_view/template/handlers/erb.rb#68 + # source://actionview//lib/action_view/template/handlers/erb.rb#93 def valid_encoding(string, encoding); end class << self - # source://actionview//lib/action_view/template/handlers/erb.rb#24 + # source://actionview//lib/action_view/template/handlers/erb.rb#29 def call(template, source); end - # source://actionview//lib/action_view/template/handlers/erb.rb#14 + # source://actionview//lib/action_view/template/handlers/erb.rb#17 def erb_implementation; end - # source://actionview//lib/action_view/template/handlers/erb.rb#14 + # source://actionview//lib/action_view/template/handlers/erb.rb#17 def erb_implementation=(value); end - # source://actionview//lib/action_view/template/handlers/erb.rb#14 + # source://actionview//lib/action_view/template/handlers/erb.rb#17 def erb_implementation?; end - # source://actionview//lib/action_view/template/handlers/erb.rb#11 + # source://actionview//lib/action_view/template/handlers/erb.rb#14 def erb_trim_mode; end - # source://actionview//lib/action_view/template/handlers/erb.rb#11 + # source://actionview//lib/action_view/template/handlers/erb.rb#14 def erb_trim_mode=(value); end - # source://actionview//lib/action_view/template/handlers/erb.rb#11 + # source://actionview//lib/action_view/template/handlers/erb.rb#14 def erb_trim_mode?; end - # source://actionview//lib/action_view/template/handlers/erb.rb#17 + # source://actionview//lib/action_view/template/handlers/erb.rb#20 def escape_ignore_list; end - # source://actionview//lib/action_view/template/handlers/erb.rb#17 + # source://actionview//lib/action_view/template/handlers/erb.rb#20 def escape_ignore_list=(value); end - # source://actionview//lib/action_view/template/handlers/erb.rb#17 + # source://actionview//lib/action_view/template/handlers/erb.rb#20 def escape_ignore_list?; end - # source://actionview//lib/action_view/template/handlers/erb.rb#20 + # source://actionview//lib/action_view/template/handlers/erb.rb#23 def strip_trailing_newlines; end - # source://actionview//lib/action_view/template/handlers/erb.rb#20 + # source://actionview//lib/action_view/template/handlers/erb.rb#23 def strip_trailing_newlines=(value); end - # source://actionview//lib/action_view/template/handlers/erb.rb#20 + # source://actionview//lib/action_view/template/handlers/erb.rb#23 def strip_trailing_newlines?; end end end -# source://actionview//lib/action_view/template/handlers/erb.rb#22 +# source://actionview//lib/action_view/template/handlers/erb.rb#25 ActionView::Template::Handlers::ERB::ENCODING_TAG = T.let(T.unsafe(nil), Regexp) # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#9 @@ -14500,30 +14615,30 @@ class ActionView::Template::Handlers::ERB::Erubi < ::Erubi::Engine # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#11 def initialize(input, properties = T.unsafe(nil)); end - # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#26 - def evaluate(action_view_erb_handler_context); end - private - # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#69 + # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#65 def add_code(code); end - # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#53 + # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#47 def add_expression(indicator, code); end - # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#74 + # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#70 def add_postamble(_); end - # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#36 + # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#30 def add_text(text); end - # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#79 + # source://actionview//lib/action_view/template/handlers/erb/erubi.rb#75 def flush_newline_if_pending(src); end end -# source://actionview//lib/action_view/template/handlers/erb/erubi.rb#51 +# source://actionview//lib/action_view/template/handlers/erb/erubi.rb#45 ActionView::Template::Handlers::ERB::Erubi::BLOCK_EXPR = T.let(T.unsafe(nil), Regexp) +# source://actionview//lib/action_view/template/handlers/erb.rb#27 +class ActionView::Template::Handlers::ERB::LocationParsingError < ::StandardError; end + # source://actionview//lib/action_view/template/handlers/html.rb#5 class ActionView::Template::Handlers::Html < ::ActionView::Template::Handlers::Raw # source://actionview//lib/action_view/template/handlers/html.rb#6 @@ -14548,6 +14663,17 @@ end # source://actionview//lib/action_view/template/inline.rb#8 ActionView::Template::Inline::Finalizer = T.let(T.unsafe(nil), Proc) +# source://actionview//lib/action_view/template.rb#299 +ActionView::Template::LEADING_ENCODING_REGEXP = T.let(T.unsafe(nil), Regexp) + +# source://actionview//lib/action_view/template.rb#198 +ActionView::Template::NONE = T.let(T.unsafe(nil), Object) + +# source://actionview//lib/action_view/template.rb#549 +ActionView::Template::RUBY_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) + +# = Action View RawFile Template +# # source://actionview//lib/action_view/template/raw_file.rb#6 class ActionView::Template::RawFile # @return [RawFile] a new instance of RawFile @@ -14574,6 +14700,8 @@ class ActionView::Template::RawFile def type=(_arg0); end end +# = Action View Renderable Template for objects that respond to #render_in +# # source://actionview//lib/action_view/template/renderable.rb#6 class ActionView::Template::Renderable # @return [Renderable] a new instance of Renderable @@ -14581,7 +14709,7 @@ class ActionView::Template::Renderable # source://actionview//lib/action_view/template/renderable.rb#7 def initialize(renderable); end - # source://actionview//lib/action_view/template/renderable.rb#19 + # source://actionview//lib/action_view/template/renderable.rb#25 def format; end # source://actionview//lib/action_view/template/renderable.rb#11 @@ -14591,6 +14719,57 @@ class ActionView::Template::Renderable def render(context, *args); end end +# source://actionview//lib/action_view/template.rb#11 +ActionView::Template::STRICT_LOCALS_REGEX = T.let(T.unsafe(nil), Regexp) + +# SimpleType is mostly just a stub implementation for when Action View +# is used without Action Dispatch. +# +# source://actionview//lib/action_view/template/types.rb#9 +class ActionView::Template::SimpleType + # @return [SimpleType] a new instance of SimpleType + # + # source://actionview//lib/action_view/template/types.rb#29 + def initialize(symbol); end + + # source://actionview//lib/action_view/template/types.rb#43 + def ==(type); end + + # source://actionview//lib/action_view/template/types.rb#38 + def ref; end + + # Returns the value of attribute symbol. + # + # source://actionview//lib/action_view/template/types.rb#27 + def symbol; end + + # source://actionview//lib/action_view/template/types.rb#33 + def to_s; end + + # source://actionview//lib/action_view/template/types.rb#33 + def to_str; end + + # source://actionview//lib/action_view/template/types.rb#38 + def to_sym; end + + class << self + # source://actionview//lib/action_view/template/types.rb#14 + def [](type); end + + # Returns the value of attribute symbols. + # + # source://actionview//lib/action_view/template/types.rb#12 + def symbols; end + + # :nodoc + # + # @return [Boolean] + # + # source://actionview//lib/action_view/template/types.rb#22 + def valid_symbols?(symbols); end + end +end + # source://actionview//lib/action_view/template/sources.rb#5 module ActionView::Template::Sources extend ::ActiveSupport::Autoload @@ -14607,6 +14786,8 @@ class ActionView::Template::Sources::File def to_s; end end +# = Action View Text Template +# # source://actionview//lib/action_view/template/text.rb#6 class ActionView::Template::Text # @return [Text] a new instance of Text @@ -14636,67 +14817,8 @@ class ActionView::Template::Text def type=(_arg0); end end -# source://actionview//lib/action_view/template/types.rb#7 -module ActionView::Template::Types - class << self - # source://actionview//lib/action_view/template/types.rb#47 - def [](type); end - - # source://actionview//lib/action_view/template/types.rb#43 - def delegate_to(klass); end - - # source://actionview//lib/action_view/template/types.rb#51 - def symbols; end - - # Returns the value of attribute type_klass. - # - # source://actionview//lib/action_view/template/types.rb#41 - def type_klass; end - - # Sets the attribute type_klass - # - # @param value the value to set the attribute type_klass to. - # - # source://actionview//lib/action_view/template/types.rb#41 - def type_klass=(_arg0); end - end -end - -# source://actionview//lib/action_view/template/types.rb#8 -class ActionView::Template::Types::Type - # @return [Type] a new instance of Type - # - # source://actionview//lib/action_view/template/types.rb#21 - def initialize(symbol); end - - # source://actionview//lib/action_view/template/types.rb#35 - def ==(type); end - - # source://actionview//lib/action_view/template/types.rb#30 - def ref; end - - # Returns the value of attribute symbol. - # - # source://actionview//lib/action_view/template/types.rb#19 - def symbol; end - - # source://actionview//lib/action_view/template/types.rb#25 - def to_s; end - - # source://actionview//lib/action_view/template/types.rb#25 - def to_str; end - - # source://actionview//lib/action_view/template/types.rb#30 - def to_sym; end - - class << self - # source://actionview//lib/action_view/template/types.rb#11 - def [](type); end - end -end - -# source://actionview//lib/action_view/template/types.rb#9 -ActionView::Template::Types::Type::SET = T.let(T.unsafe(nil), T.untyped) +# source://actionview//lib/action_view/template.rb#190 +ActionView::Template::Types = Mime # source://actionview//lib/action_view/template_details.rb#4 class ActionView::TemplateDetails @@ -14796,89 +14918,91 @@ end # source://actionview//lib/action_view/template_details.rb#9 ActionView::TemplateDetails::Requested::ANY_HASH = T.let(T.unsafe(nil), Hash) -# source://actionview//lib/action_view/template/error.rb#230 +# source://actionview//lib/action_view/template/error.rb#243 ActionView::TemplateError = ActionView::Template::Error +# = Action View \TemplatePath +# # Represents a template path within ActionView's lookup and rendering system, # like "users/show" # # TemplatePath makes it convenient to convert between separate name, prefix, # partial arguments and the virtual path. # -# source://actionview//lib/action_view/template_path.rb#9 +# source://actionview//lib/action_view/template_path.rb#11 class ActionView::TemplatePath # @return [TemplatePath] a new instance of TemplatePath # - # source://actionview//lib/action_view/template_path.rb#45 + # source://actionview//lib/action_view/template_path.rb#47 def initialize(name, prefix, partial, virtual); end # @return [Boolean] # - # source://actionview//lib/action_view/template_path.rb#59 + # source://actionview//lib/action_view/template_path.rb#61 def ==(other); end # @return [Boolean] # - # source://actionview//lib/action_view/template_path.rb#59 + # source://actionview//lib/action_view/template_path.rb#61 def eql?(other); end - # source://actionview//lib/action_view/template_path.rb#55 + # source://actionview//lib/action_view/template_path.rb#57 def hash; end # Returns the value of attribute name. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def name; end # Returns the value of attribute partial. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def partial; end # Returns the value of attribute partial. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def partial?; end # Returns the value of attribute prefix. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def prefix; end # Returns the value of attribute virtual. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def to_s; end # Returns the value of attribute virtual. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def to_str; end # Returns the value of attribute virtual. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def virtual; end # Returns the value of attribute virtual. # - # source://actionview//lib/action_view/template_path.rb#10 + # source://actionview//lib/action_view/template_path.rb#12 def virtual_path; end class << self # Convert name, prefix, and partial into a TemplatePath # - # source://actionview//lib/action_view/template_path.rb#41 + # source://actionview//lib/action_view/template_path.rb#43 def build(name, prefix, partial); end # Build a TemplatePath form a virtual path # - # source://actionview//lib/action_view/template_path.rb#26 + # source://actionview//lib/action_view/template_path.rb#28 def parse(virtual); end # Convert name, prefix, and partial into a virtual path string # - # source://actionview//lib/action_view/template_path.rb#15 + # source://actionview//lib/action_view/template_path.rb#17 def virtual(name, prefix, partial); end end end @@ -14899,7 +15023,7 @@ class ActionView::TemplateRenderer < ::ActionView::AbstractRenderer # context object. If no layout is found, it checks if at least a layout with # the given name exists across all details before raising the error. # - # source://actionview//lib/action_view/renderer/template_renderer.rb#87 + # source://actionview//lib/action_view/renderer/template_renderer.rb#88 def find_layout(layout, keys, formats); end # Renders the given template. A string representing the layout can be @@ -14908,25 +15032,28 @@ class ActionView::TemplateRenderer < ::ActionView::AbstractRenderer # source://actionview//lib/action_view/renderer/template_renderer.rb#58 def render_template(view, template, layout_name, locals); end - # source://actionview//lib/action_view/renderer/template_renderer.rb#70 + # source://actionview//lib/action_view/renderer/template_renderer.rb#71 def render_with_layout(view, template, path, locals); end - # source://actionview//lib/action_view/renderer/template_renderer.rb#91 + # source://actionview//lib/action_view/renderer/template_renderer.rb#92 def resolve_layout(layout, keys, formats); end end # = Action View Test Case # -# source://actionview//lib/action_view/test_case.rb#12 +# Read more about ActionView::TestCase in {Testing Rails Applications}[https://guides.rubyonrails.org/testing.html#testing-view-partials] +# in the guides. +# +# source://actionview//lib/action_view/test_case.rb#15 class ActionView::TestCase < ::ActiveSupport::TestCase + include ::ActionDispatch::Assertions::RoutingAssertions + include ::ActionDispatch::Assertions::ResponseAssertions include ::ActionDispatch::TestProcess::FixtureFile include ::ActionDispatch::TestProcess - include ::ActionDispatch::Assertions::ResponseAssertions - include ::ActionDispatch::Assertions::RoutingAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions + include ::ActionDispatch::Assertions include ::AbstractController::Helpers include ::ActiveSupport::Benchmarkable include ::ActionView::Helpers::ActiveModelHelper @@ -14934,11 +15061,12 @@ class ActionView::TestCase < ::ActiveSupport::TestCase include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper include ::ActionView::Helpers::TagHelper - include ::ActionView::Helpers::UrlHelper - include ::ActionView::Helpers::SanitizeHelper include ::ActionView::Helpers::AssetTagHelper include ::ActionView::Helpers::AtomFeedHelper include ::ActionView::Helpers::CacheHelper + include ::ActionView::Helpers::ContentExfiltrationPreventionHelper + include ::ActionView::Helpers::UrlHelper + include ::ActionView::Helpers::SanitizeHelper include ::ActionView::Helpers::ControllerHelper include ::ActionView::Helpers::CspHelper include ::ActionView::Helpers::CsrfHelper @@ -14946,7 +15074,6 @@ class ActionView::TestCase < ::ActiveSupport::TestCase include ::ActionView::Helpers::DebugHelper include ::ActionView::Helpers::TextHelper include ::ActionView::Helpers::FormTagHelper - include ::ActionDispatch::Assertions include ::ActionController::TemplateAssertions include ::ActionView::Context include ::ActionDispatch::Routing::PolymorphicRoutes @@ -14960,21 +15087,24 @@ class ActionView::TestCase < ::ActiveSupport::TestCase include ::ActionView::Helpers::RenderingHelper include ::ActionView::Helpers include ::ActiveSupport::Testing::ConstantLookup + include ::ActionDispatch::Routing::UrlFor include ::ActionView::RoutingUrlFor include ::ActionView::TestCase::Behavior + extend ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods + extend ::AbstractController::Helpers::Resolution extend ::AbstractController::Helpers::ClassMethods extend ::ActionView::Helpers::UrlHelper::ClassMethods extend ::ActionView::Helpers::SanitizeHelper::ClassMethods extend ::ActiveSupport::Testing::ConstantLookup::ClassMethods extend ::ActionView::TestCase::Behavior::ClassMethods - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end # source://actionview//lib/action_view/helpers/translation_helper.rb#18 @@ -14984,21 +15114,30 @@ class ActionView::TestCase < ::ActiveSupport::TestCase def debug_missing_translation=(val); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#15 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#17 def _helpers; end + # source://actionview//lib/action_view/test_case.rb#200 + def content_class; end + + # source://actionview//lib/action_view/test_case.rb#200 + def content_class=(value); end + + # source://actionview//lib/action_view/test_case.rb#200 + def content_class?; end + # source://actionview//lib/action_view/helpers/translation_helper.rb#18 def debug_missing_translation; end @@ -15007,26 +15146,24 @@ class ActionView::TestCase < ::ActiveSupport::TestCase end end -# source://actionview//lib/action_view/test_case.rb#42 +# source://actionview//lib/action_view/test_case.rb#45 module ActionView::TestCase::Behavior include ::ActionDispatch::TestProcess::FixtureFile include ::ActionDispatch::TestProcess - include ::ActionDispatch::Assertions::ResponseAssertions - include ::ActionDispatch::Assertions::RoutingAssertions include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable include ::Rails::Dom::Testing::Assertions::SelectorAssertions include ::Rails::Dom::Testing::Assertions - include ::ActionDispatch::Assertions include ::ActionController::TemplateAssertions include ::ActionView::Context include ::ActionDispatch::Routing::PolymorphicRoutes include ::ActionView::ModelNaming include ::ActionView::RecordIdentifier + include ::ActionDispatch::Routing::UrlFor include ::ActionView::RoutingUrlFor extend ::ActiveSupport::Concern include GeneratedInstanceMethods - include ::Rails::Dom::Testing::Assertions + include ::ActionDispatch::Assertions::RoutingAssertions + include ::ActionDispatch::Assertions include ::AbstractController::Helpers include ::ActionView::Helpers::UrlHelper include ::ActionView::Helpers::SanitizeHelper @@ -15038,104 +15175,155 @@ module ActionView::TestCase::Behavior include ::ActiveSupport::Testing::ConstantLookup mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActionDispatch::Assertions::RoutingAssertions::ClassMethods mixes_in_class_methods ::AbstractController::Helpers::ClassMethods mixes_in_class_methods ::ActionView::Helpers::UrlHelper::ClassMethods mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods mixes_in_class_methods ::ActiveSupport::Testing::ConstantLookup::ClassMethods mixes_in_class_methods ::ActionView::TestCase::Behavior::ClassMethods - # source://actionview//lib/action_view/test_case.rb#136 + # :method: rendered + # + # Returns the content rendered by the last +render+ call. + # + # The returned object behaves like a string but also exposes a number of methods + # that allows you to parse the content string in formats registered using + # .register_parser. + # + # By default includes the following parsers: + # + # +.html+ + # + # Parse the rendered content String into HTML. By default, this means + # a Nokogiri::XML::Node. + # + # test "renders HTML" do + # article = Article.create!(title: "Hello, world") + # + # render partial: "articles/article", locals: { article: article } + # + # assert_pattern { rendered.html.at("main h1") => { content: "Hello, world" } } + # end + # + # To parse the rendered content into a Capybara::Simple::Node, + # re-register an :html parser with a call to + # Capybara.string: + # + # register_parser :html, -> rendered { Capybara.string(rendered) } + # + # test "renders HTML" do + # article = Article.create!(title: "Hello, world") + # + # render partial: article + # + # rendered.html.assert_css "h1", text: "Hello, world" + # end + # + # +.json+ + # + # Parse the rendered content String into JSON. By default, this means + # a ActiveSupport::HashWithIndifferentAccess. + # + # test "renders JSON" do + # article = Article.create!(title: "Hello, world") + # + # render formats: :json, partial: "articles/article", locals: { article: article } + # + # assert_pattern { rendered.json => { title: "Hello, world" } } + # end + # + # source://actionview//lib/action_view/test_case.rb#297 def _routes; end - # source://actionview//lib/action_view/test_case.rb#122 + # source://actionview//lib/action_view/test_case.rb#232 def config; end # Returns the value of attribute controller. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def controller; end # Sets the attribute controller # # @param value the value to set the attribute controller to. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def controller=(_arg0); end - # source://actionview//lib/action_view/test_case.rb#59 + # source://actionview//lib/action_view/test_case.rb#62 def lookup_context(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute output_buffer. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def output_buffer; end # Sets the attribute output_buffer # # @param value the value to set the attribute output_buffer to. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def output_buffer=(_arg0); end - # source://actionview//lib/action_view/test_case.rb#126 + # source://actionview//lib/action_view/test_case.rb#236 def render(options = T.unsafe(nil), local_assigns = T.unsafe(nil), &block); end # Returns the value of attribute rendered. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def rendered; end # Sets the attribute rendered # # @param value the value to set the attribute rendered to. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def rendered=(_arg0); end - # source://actionview//lib/action_view/test_case.rb#132 + # source://actionview//lib/action_view/test_case.rb#242 def rendered_views; end # Returns the value of attribute request. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def request; end # Sets the attribute request # # @param value the value to set the attribute request to. # - # source://actionview//lib/action_view/test_case.rb#60 + # source://actionview//lib/action_view/test_case.rb#63 def request=(_arg0); end - # source://actionview//lib/action_view/test_case.rb#108 + # source://actionview//lib/action_view/test_case.rb#220 def setup_with_controller; end private - # source://actionview//lib/action_view/test_case.rb#251 + # source://actionview//lib/action_view/test_case.rb#404 def _user_defined_ivars; end # The instance of ActionView::Base that is used by +render+. # - # source://actionview//lib/action_view/test_case.rb#207 + # source://actionview//lib/action_view/test_case.rb#356 def _view; end # Need to experiment if this priority is the best one: rendered => output_buffer # - # source://actionview//lib/action_view/test_case.rb#183 + # source://actionview//lib/action_view/test_case.rb#332 def document_root_element; end - # source://actionview//lib/action_view/test_case.rb#265 - def method_missing(selector, *args); end + # source://actionview//lib/action_view/test_case.rb#418 + def method_missing(selector, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://actionview//lib/action_view/test_case.rb#281 + # source://actionview//lib/action_view/test_case.rb#434 def respond_to_missing?(name, include_private = T.unsafe(nil)); end # The instance of ActionView::Base that is used by +render+. # - # source://actionview//lib/action_view/test_case.rb#207 + # source://actionview//lib/action_view/test_case.rb#356 def view; end # Returns a Hash of instance variables and their values, as defined by @@ -15143,13 +15331,16 @@ module ActionView::TestCase::Behavior # rendered. This is generally intended for internal use and extension # frameworks. # - # source://actionview//lib/action_view/test_case.rb#259 + # source://actionview//lib/action_view/test_case.rb#412 def view_assigns; end module GeneratedClassMethods def _helper_methods; end def _helper_methods=(value); end def _helper_methods?; end + def content_class; end + def content_class=(value); end + def content_class?; end end module GeneratedInstanceMethods @@ -15159,137 +15350,222 @@ module ActionView::TestCase::Behavior end end -# source://actionview//lib/action_view/test_case.rb#62 +# source://actionview//lib/action_view/test_case.rb#65 module ActionView::TestCase::Behavior::ClassMethods - # source://actionview//lib/action_view/test_case.rb#72 + # source://actionview//lib/action_view/test_case.rb#164 def determine_default_helper_class(name); end - # source://actionview//lib/action_view/test_case.rb#92 + # source://actionview//lib/action_view/test_case.rb#183 def helper_class; end # Sets the attribute helper_class # # @param value the value to set the attribute helper_class to. # - # source://actionview//lib/action_view/test_case.rb#90 + # source://actionview//lib/action_view/test_case.rb#181 def helper_class=(_arg0); end - # source://actionview//lib/action_view/test_case.rb#78 + # source://actionview//lib/action_view/test_case.rb#170 def helper_method(*methods); end - # source://actionview//lib/action_view/test_case.rb#96 + # source://actionview//lib/action_view/test_case.rb#66 + def inherited(descendant); end + + # source://actionview//lib/action_view/test_case.rb#187 def new(*_arg0); end - # source://actionview//lib/action_view/test_case.rb#63 + # Register a callable to parse rendered content for a given template + # format. + # + # Each registered parser will also define a +#rendered.[FORMAT]+ helper + # method, where +[FORMAT]+ corresponds to the value of the + # +format+ argument. + # + # By default, ActionView::TestCase defines parsers for: + # + # * +:html+ - returns an instance of +Nokogiri::XML::Node+ + # * +:json+ - returns an instance of ActiveSupport::HashWithIndifferentAccess + # + # These pre-registered parsers also define corresponding helpers: + # + # * +:html+ - defines +rendered.html+ + # * +:json+ - defines +rendered.json+ + # + # ==== Parameters + # + # [+format+] + # The name (as a +Symbol+) of the format used to render the content. + # + # [+callable+] + # The parser. A callable object that accepts the rendered string as + # its sole argument. Alternatively, the parser can be specified as a + # block. + # + # ==== Examples + # + # test "renders HTML" do + # article = Article.create!(title: "Hello, world") + # + # render partial: "articles/article", locals: { article: article } + # + # assert_pattern { rendered.html.at("main h1") => { content: "Hello, world" } } + # end + # + # test "renders JSON" do + # article = Article.create!(title: "Hello, world") + # + # render formats: :json, partial: "articles/article", locals: { article: article } + # + # assert_pattern { rendered.json => { title: "Hello, world" } } + # end + # + # To parse the rendered content into RSS, register a call to +RSS::Parser.parse+: + # + # register_parser :rss, -> rendered { RSS::Parser.parse(rendered) } + # + # test "renders RSS" do + # article = Article.create!(title: "Hello, world") + # + # render formats: :rss, partial: article + # + # assert_equal "Hello, world", rendered.rss.items.last.title + # end + # + # To parse the rendered content into a +Capybara::Simple::Node+, + # re-register an +:html+ parser with a call to +Capybara.string+: + # + # register_parser :html, -> rendered { Capybara.string(rendered) } + # + # test "renders HTML" do + # article = Article.create!(title: "Hello, world") + # + # render partial: article + # + # rendered.html.assert_css "h1", text: "Hello, world" + # end + # + # source://actionview//lib/action_view/test_case.rb#148 + def register_parser(format, callable = T.unsafe(nil), &block); end + + # source://actionview//lib/action_view/test_case.rb#155 def tests(helper_class); end private - # source://actionview//lib/action_view/test_case.rb#102 + # source://actionview//lib/action_view/test_case.rb#193 def include_helper_modules!; end end -# source://actionview//lib/action_view/test_case.rb#220 +# source://actionview//lib/action_view/test_case.rb#369 ActionView::TestCase::Behavior::INTERNAL_IVARS = T.let(T.unsafe(nil), Array) -# source://actionview//lib/action_view/test_case.rb#187 +# source://actionview//lib/action_view/test_case.rb#336 module ActionView::TestCase::Behavior::Locals - # source://actionview//lib/action_view/test_case.rb#190 + # source://actionview//lib/action_view/test_case.rb#339 def render(options = T.unsafe(nil), local_assigns = T.unsafe(nil)); end # Returns the value of attribute rendered_views. # - # source://actionview//lib/action_view/test_case.rb#188 + # source://actionview//lib/action_view/test_case.rb#337 def rendered_views; end # Sets the attribute rendered_views # # @param value the value to set the attribute rendered_views to. # - # source://actionview//lib/action_view/test_case.rb#188 + # source://actionview//lib/action_view/test_case.rb#337 def rendered_views=(_arg0); end end +# source://actionview//lib/action_view/test_case.rb#301 +class ActionView::TestCase::Behavior::RenderedViewContent < ::String + # source://actionview//lib/action_view/test_case.rb#150 + def html; end + + # source://actionview//lib/action_view/test_case.rb#150 + def json; end +end + # Need to experiment if this priority is the best one: rendered => output_buffer # -# source://actionview//lib/action_view/test_case.rb#141 +# source://actionview//lib/action_view/test_case.rb#305 class ActionView::TestCase::Behavior::RenderedViewsCollection # @return [RenderedViewsCollection] a new instance of RenderedViewsCollection # - # source://actionview//lib/action_view/test_case.rb#142 + # source://actionview//lib/action_view/test_case.rb#306 def initialize; end - # source://actionview//lib/action_view/test_case.rb#146 + # source://actionview//lib/action_view/test_case.rb#310 def add(view, locals); end - # source://actionview//lib/action_view/test_case.rb#151 + # source://actionview//lib/action_view/test_case.rb#315 def locals_for(view); end - # source://actionview//lib/action_view/test_case.rb#155 + # source://actionview//lib/action_view/test_case.rb#319 def rendered_views; end # @return [Boolean] # - # source://actionview//lib/action_view/test_case.rb#159 + # source://actionview//lib/action_view/test_case.rb#323 def view_rendered?(view, expected_locals); end end # source://actionview//lib/action_view/test_case.rb#0 module ActionView::TestCase::HelperMethods - # source://actionview//lib/action_view/test_case.rb#175 + # source://actionview//lib/action_view/test_case.rb#214 def _test_case; end - # source://actionview//lib/action_view/test_case.rb#171 + # source://actionview//lib/action_view/test_case.rb#210 def protect_against_forgery?; end end -# source://actionview//lib/action_view/test_case.rb#13 +# source://actionview//lib/action_view/test_case.rb#16 class ActionView::TestCase::TestController < ::ActionController::Base include ::ActionDispatch::TestProcess::FixtureFile include ::ActionDispatch::TestProcess # @return [TestController] a new instance of TestController # - # source://actionview//lib/action_view/test_case.rb#31 + # source://actionview//lib/action_view/test_case.rb#34 def initialize; end - # source://actionview//lib/action_view/test_case.rb#23 + # source://actionview//lib/action_view/test_case.rb#26 def controller_path=(path); end # Returns the value of attribute params. # - # source://actionview//lib/action_view/test_case.rb#16 + # source://actionview//lib/action_view/test_case.rb#19 def params; end # Sets the attribute params # # @param value the value to set the attribute params to. # - # source://actionview//lib/action_view/test_case.rb#16 + # source://actionview//lib/action_view/test_case.rb#19 def params=(_arg0); end # Returns the value of attribute request. # - # source://actionview//lib/action_view/test_case.rb#16 + # source://actionview//lib/action_view/test_case.rb#19 def request; end # Sets the attribute request # # @param value the value to set the attribute request to. # - # source://actionview//lib/action_view/test_case.rb#16 + # source://actionview//lib/action_view/test_case.rb#19 def request=(_arg0); end # Returns the value of attribute response. # - # source://actionview//lib/action_view/test_case.rb#16 + # source://actionview//lib/action_view/test_case.rb#19 def response; end # Sets the attribute response # # @param value the value to set the attribute response to. # - # source://actionview//lib/action_view/test_case.rb#16 + # source://actionview//lib/action_view/test_case.rb#19 def response=(_arg0); end private @@ -15297,21 +15573,23 @@ class ActionView::TestCase::TestController < ::ActionController::Base # source://actionview//lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end + def _layout_from_proc; end + class << self - # source://actionview//lib/action_view/test_case.rb#27 + # source://actionview//lib/action_view/test_case.rb#30 def controller_name; end # Overrides AbstractController::Base#controller_path # - # source://actionview//lib/action_view/test_case.rb#20 + # source://actionview//lib/action_view/test_case.rb#23 def controller_path; end # Overrides AbstractController::Base#controller_path # - # source://actionview//lib/action_view/test_case.rb#20 + # source://actionview//lib/action_view/test_case.rb#23 def controller_path=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end end end @@ -15326,6 +15604,9 @@ class ActionView::UnboundTemplate # source://actionview//lib/action_view/unbound_template.rb#20 def bind_locals(locals); end + # source://actionview//lib/action_view/unbound_template.rb#44 + def built_templates; end + # Returns the value of attribute details. # # source://actionview//lib/action_view/unbound_template.rb#7 @@ -15350,10 +15631,10 @@ class ActionView::UnboundTemplate private - # source://actionview//lib/action_view/unbound_template.rb#39 + # source://actionview//lib/action_view/unbound_template.rb#49 def build_template(locals); end - # source://actionview//lib/action_view/unbound_template.rb#53 + # source://actionview//lib/action_view/unbound_template.rb#63 def normalize_locals(locals); end end @@ -15383,7 +15664,7 @@ module ActionView::ViewPaths # The prefixes used in render "foo" shortcuts. # - # source://actionview//lib/action_view/view_paths.rb#90 + # source://actionview//lib/action_view/view_paths.rb#81 def _prefixes; end # source://actionview//lib/action_view/view_paths.rb#11 @@ -15396,10 +15677,10 @@ module ActionView::ViewPaths # the default view path. You may also provide a custom view path # (see ActionView::PathSet for more information) # - # source://actionview//lib/action_view/view_paths.rb#112 + # source://actionview//lib/action_view/view_paths.rb#103 def append_view_path(path); end - # source://actionview//lib/action_view/view_paths.rb#102 + # source://actionview//lib/action_view/view_paths.rb#93 def details_for_lookup; end # source://actionview//lib/action_view/view_paths.rb#11 @@ -15418,7 +15699,7 @@ module ActionView::ViewPaths # information required for looking up templates, i.e. view paths and # details. Check ActionView::LookupContext for more information. # - # source://actionview//lib/action_view/view_paths.rb#97 + # source://actionview//lib/action_view/view_paths.rb#88 def lookup_context; end # Prepend a path to the list of view paths for the current LookupContext. @@ -15428,7 +15709,7 @@ module ActionView::ViewPaths # the default view path. You may also provide a custom view path # (see ActionView::PathSet for more information) # - # source://actionview//lib/action_view/view_paths.rb#122 + # source://actionview//lib/action_view/view_paths.rb#113 def prepend_view_path(path); end # source://actionview//lib/action_view/view_paths.rb#11 @@ -15436,21 +15717,13 @@ module ActionView::ViewPaths # source://actionview//lib/action_view/view_paths.rb#11 def view_paths(*_arg0, **_arg1, &_arg2); end - - class << self - # source://actionview//lib/action_view/view_paths.rb#84 - def all_view_paths; end - - # source://actionview//lib/action_view/view_paths.rb#76 - def get_view_paths(klass); end - - # source://actionview//lib/action_view/view_paths.rb#80 - def set_view_paths(klass, paths); end - end end # source://actionview//lib/action_view/view_paths.rb#14 module ActionView::ViewPaths::ClassMethods + # source://actionview//lib/action_view/view_paths.rb#31 + def _build_view_paths(paths); end + # source://actionview//lib/action_view/view_paths.rb#23 def _prefixes; end @@ -15467,7 +15740,7 @@ module ActionView::ViewPaths::ClassMethods # the default view path. You may also provide a custom view path # (see ActionView::PathSet for more information) # - # source://actionview//lib/action_view/view_paths.rb#37 + # source://actionview//lib/action_view/view_paths.rb#44 def append_view_path(path); end # Prepend a path to the list of view paths for this controller. @@ -15477,12 +15750,12 @@ module ActionView::ViewPaths::ClassMethods # the default view path. You may also provide a custom view path # (see ActionView::PathSet for more information) # - # source://actionview//lib/action_view/view_paths.rb#47 + # source://actionview//lib/action_view/view_paths.rb#54 def prepend_view_path(path); end # A list of all of the default view paths for this controller. # - # source://actionview//lib/action_view/view_paths.rb#52 + # source://actionview//lib/action_view/view_paths.rb#59 def view_paths; end # Set the view paths. @@ -15491,7 +15764,7 @@ module ActionView::ViewPaths::ClassMethods # * paths - If a PathSet is provided, use that; # otherwise, process the parameter into a PathSet. # - # source://actionview//lib/action_view/view_paths.rb#61 + # source://actionview//lib/action_view/view_paths.rb#68 def view_paths=(paths); end private @@ -15499,18 +15772,18 @@ module ActionView::ViewPaths::ClassMethods # Override this method in your controller if you want to change paths prefixes for finding views. # Prefixes defined here will still be added to parents' ._prefixes. # - # source://actionview//lib/action_view/view_paths.rb#68 + # source://actionview//lib/action_view/view_paths.rb#75 def local_prefixes; end end -# source://actionview//lib/action_view/template/error.rb#13 +# source://actionview//lib/action_view/template/error.rb#14 class ActionView::WrongEncodingError < ::ActionView::EncodingError # @return [WrongEncodingError] a new instance of WrongEncodingError # - # source://actionview//lib/action_view/template/error.rb#14 + # source://actionview//lib/action_view/template/error.rb#15 def initialize(string, encoding); end - # source://actionview//lib/action_view/template/error.rb#18 + # source://actionview//lib/action_view/template/error.rb#19 def message; end end diff --git a/sorbet/rbi/gems/activejob@7.0.5.rbi b/sorbet/rbi/gems/activejob@7.2.0.rbi similarity index 73% rename from sorbet/rbi/gems/activejob@7.0.5.rbi rename to sorbet/rbi/gems/activejob@7.2.0.rbi index a3fdb6182..8f678e8e1 100644 --- a/sorbet/rbi/gems/activejob@7.0.5.rbi +++ b/sorbet/rbi/gems/activejob@7.2.0.rbi @@ -4,20 +4,54 @@ # This is an autogenerated file for types exported from the `activejob` gem. # Please instead update this file by running `bin/tapioca gem activejob`. + +# :markup: markdown +# :include: ../README.md +# # source://activejob//lib/active_job/gem_version.rb#3 module ActiveJob extend ::ActiveSupport::Autoload class << self - # Returns the currently loaded version of Active Job as a Gem::Version. + # source://activejob//lib/active_job/queue_adapter.rb#7 + def adapter_name(adapter); end + + # source://activejob//lib/active_job/deprecator.rb#4 + def deprecator; end + + # Returns the currently loaded version of Active Job as a +Gem::Version+. # # source://activejob//lib/active_job/gem_version.rb#5 def gem_version; end - # Returns the currently loaded version of Active Job as a Gem::Version. + # Push many jobs onto the queue at once without running enqueue callbacks. + # Queue adapters may communicate the enqueue status of each job by setting + # successfully_enqueued and/or enqueue_error on the passed-in job instances. + # + # source://activejob//lib/active_job/enqueuing.rb#14 + def perform_all_later(*jobs); end + + # source://activejob//lib/active_job.rb#52 + def use_big_decimal_serializer; end + + # source://activejob//lib/active_job.rb#58 + def use_big_decimal_serializer=(value); end + + # source://activejob//lib/active_job.rb#69 + def verbose_enqueue_logs; end + + # source://activejob//lib/active_job.rb#69 + def verbose_enqueue_logs=(_arg0); end + + # Returns the currently loaded version of Active Job as a +Gem::Version+. # # source://activejob//lib/active_job/version.rb#7 def version; end + + private + + # source://activejob//lib/active_job/instrumentation.rb#6 + def instrument_enqueue_all(queue_adapter, jobs); end end end @@ -43,66 +77,63 @@ module ActiveJob::Arguments private - # source://activejob//lib/active_job/arguments.rb#204 + # source://activejob//lib/active_job/arguments.rb#190 def convert_to_global_id_hash(argument); end # @return [Boolean] # - # source://activejob//lib/active_job/arguments.rb#151 + # source://activejob//lib/active_job/arguments.rb#137 def custom_serialized?(hash); end - # source://activejob//lib/active_job/arguments.rb#122 + # source://activejob//lib/active_job/arguments.rb#110 def deserialize_argument(argument); end - # source://activejob//lib/active_job/arguments.rb#147 + # source://activejob//lib/active_job/arguments.rb#133 def deserialize_global_id(hash); end - # source://activejob//lib/active_job/arguments.rb#161 + # source://activejob//lib/active_job/arguments.rb#147 def deserialize_hash(serialized_hash); end - # source://activejob//lib/active_job/arguments.rb#95 + # source://activejob//lib/active_job/arguments.rb#71 def serialize_argument(argument); end - # source://activejob//lib/active_job/arguments.rb#155 + # source://activejob//lib/active_job/arguments.rb#141 def serialize_hash(argument); end - # source://activejob//lib/active_job/arguments.rb#174 + # source://activejob//lib/active_job/arguments.rb#160 def serialize_hash_key(key); end - # source://activejob//lib/active_job/arguments.rb#185 + # source://activejob//lib/active_job/arguments.rb#171 def serialize_indifferent_hash(indifferent_hash); end # @return [Boolean] # - # source://activejob//lib/active_job/arguments.rb#143 + # source://activejob//lib/active_job/arguments.rb#129 def serialized_global_id?(hash); end - # source://activejob//lib/active_job/arguments.rb#191 + # source://activejob//lib/active_job/arguments.rb#177 def transform_symbol_keys(hash, symbol_keys); end end -# source://activejob//lib/active_job/arguments.rb#52 +# source://activejob//lib/active_job/arguments.rb#50 ActiveJob::Arguments::GLOBALID_KEY = T.let(T.unsafe(nil), String) -# source://activejob//lib/active_job/arguments.rb#60 +# source://activejob//lib/active_job/arguments.rb#58 ActiveJob::Arguments::OBJECT_SERIALIZER_KEY = T.let(T.unsafe(nil), String) -# source://activejob//lib/active_job/arguments.rb#50 -ActiveJob::Arguments::PERMITTED_TYPES = T.let(T.unsafe(nil), Array) - -# source://activejob//lib/active_job/arguments.rb#63 +# source://activejob//lib/active_job/arguments.rb#61 ActiveJob::Arguments::RESERVED_KEYS = T.let(T.unsafe(nil), Array) -# source://activejob//lib/active_job/arguments.rb#56 +# source://activejob//lib/active_job/arguments.rb#54 ActiveJob::Arguments::RUBY2_KEYWORDS_KEY = T.let(T.unsafe(nil), String) -# source://activejob//lib/active_job/arguments.rb#54 +# source://activejob//lib/active_job/arguments.rb#52 ActiveJob::Arguments::SYMBOL_KEYS_KEY = T.let(T.unsafe(nil), String) -# source://activejob//lib/active_job/arguments.rb#58 +# source://activejob//lib/active_job/arguments.rb#56 ActiveJob::Arguments::WITH_INDIFFERENT_ACCESS_KEY = T.let(T.unsafe(nil), String) -# = Active Job +# = Active Job \Base # # Active Job objects can be configured to work with different backend # queuing frameworks. To specify a queue adapter to use: @@ -164,6 +195,7 @@ class ActiveJob::Base include ::ActiveJob::Logging include ::ActiveJob::Timezones include ::ActiveJob::Translation + include ::Sidekiq::Job::Options include ::ActiveJob::TestHelper::TestQueueAdapter extend ::ActiveJob::Core::ClassMethods extend ::ActiveJob::QueueAdapter::ClassMethods @@ -176,85 +208,113 @@ class ActiveJob::Base extend ::ActiveSupport::DescendantsTracker extend ::ActiveJob::Callbacks::ClassMethods extend ::ActiveJob::Exceptions::ClassMethods + extend ::Sidekiq::Job::Options::ClassMethods extend ::ActiveJob::TestHelper::TestQueueAdapter::ClassMethods - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _enqueue_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _perform_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_enqueue_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_perform_callbacks(&block); end - # source://activejob//lib/active_job/logging.rb#11 + # source://activejob//lib/active_job/exceptions.rb#12 + def after_discard_procs; end + + # source://activejob//lib/active_job/exceptions.rb#12 + def after_discard_procs=(_arg0); end + + # source://activejob//lib/active_job/exceptions.rb#12 + def after_discard_procs?; end + + # source://activejob//lib/active_job/logging.rb#15 def logger; end - # source://activejob//lib/active_job/logging.rb#11 + # source://activejob//lib/active_job/logging.rb#15 def logger=(val); end - # source://activejob//lib/active_job/queue_adapter.rb#15 - def queue_adapter(*_arg0, **_arg1, &_arg2); end + # source://activejob//lib/active_job/queue_adapter.rb#27 + def queue_adapter(&_arg0); end - # source://activejob//lib/active_job/queue_name.rb#58 + # source://activejob//lib/active_job/queue_name.rb#57 def queue_name_prefix; end - # source://activejob//lib/active_job/queue_name.rb#58 + # source://activejob//lib/active_job/queue_name.rb#57 def queue_name_prefix=(_arg0); end - # source://activejob//lib/active_job/queue_name.rb#58 + # source://activejob//lib/active_job/queue_name.rb#57 def queue_name_prefix?; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#141 + def sidekiq_options_hash; end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#153 + def sidekiq_options_hash=(_arg0); end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#141 + def sidekiq_retries_exhausted_block; end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#153 + def sidekiq_retries_exhausted_block=(_arg0); end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#141 + def sidekiq_retry_in_block; end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#153 + def sidekiq_retry_in_block=(_arg0); end + class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _enqueue_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _enqueue_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _perform_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _perform_callbacks=(value); end - # source://activejob//lib/active_job/queue_adapter.rb#13 + # source://activejob//lib/active_job/queue_adapter.rb#25 def _queue_adapter; end - # source://activejob//lib/active_job/queue_adapter.rb#13 + # source://activejob//lib/active_job/queue_adapter.rb#25 def _queue_adapter=(value); end - # source://activejob//lib/active_job/queue_adapter.rb#12 + # source://activejob//lib/active_job/queue_adapter.rb#24 def _queue_adapter_name; end - # source://activejob//lib/active_job/queue_adapter.rb#12 + # source://activejob//lib/active_job/queue_adapter.rb#24 def _queue_adapter_name=(value); end # source://activejob//lib/active_job/test_helper.rb#19 @@ -263,64 +323,79 @@ class ActiveJob::Base # source://activejob//lib/active_job/test_helper.rb#19 def _test_adapter=(value); end - # source://activejob//lib/active_job/logging.rb#12 + # source://activejob//lib/active_job/exceptions.rb#12 + def after_discard_procs; end + + # source://activejob//lib/active_job/exceptions.rb#12 + def after_discard_procs=(value); end + + # source://activejob//lib/active_job/exceptions.rb#12 + def after_discard_procs?; end + + # source://activejob//lib/active_job/enqueuing.rb#54 + def enqueue_after_transaction_commit; end + + # source://activejob//lib/active_job/enqueuing.rb#54 + def enqueue_after_transaction_commit=(value); end + + # source://activejob//lib/active_job/logging.rb#26 def log_arguments; end - # source://activejob//lib/active_job/logging.rb#12 + # source://activejob//lib/active_job/logging.rb#26 def log_arguments=(value); end - # source://activejob//lib/active_job/logging.rb#12 + # source://activejob//lib/active_job/logging.rb#26 def log_arguments?; end - # source://activejob//lib/active_job/logging.rb#11 + # source://activejob//lib/active_job/logging.rb#15 def logger; end - # source://activejob//lib/active_job/logging.rb#11 + # source://activejob//lib/active_job/logging.rb#15 def logger=(val); end - # source://activejob//lib/active_job/queue_priority.rb#32 + # source://activejob//lib/active_job/queue_priority.rb#49 def priority; end - # source://activejob//lib/active_job/queue_priority.rb#32 + # source://activejob//lib/active_job/queue_priority.rb#49 def priority=(value); end - # source://activejob//lib/active_job/queue_priority.rb#32 + # source://activejob//lib/active_job/queue_priority.rb#49 def priority?; end - # source://activejob//lib/active_job/queue_name.rb#56 + # source://activejob//lib/active_job/queue_name.rb#55 def queue_name; end - # source://activejob//lib/active_job/queue_name.rb#56 + # source://activejob//lib/active_job/queue_name.rb#55 def queue_name=(value); end - # source://activejob//lib/active_job/queue_name.rb#56 + # source://activejob//lib/active_job/queue_name.rb#55 def queue_name?; end - # source://activejob//lib/active_job/queue_name.rb#57 + # source://activejob//lib/active_job/queue_name.rb#56 def queue_name_delimiter; end - # source://activejob//lib/active_job/queue_name.rb#57 + # source://activejob//lib/active_job/queue_name.rb#56 def queue_name_delimiter=(value); end - # source://activejob//lib/active_job/queue_name.rb#57 + # source://activejob//lib/active_job/queue_name.rb#56 def queue_name_delimiter?; end - # source://activejob//lib/active_job/queue_name.rb#58 + # source://activejob//lib/active_job/queue_name.rb#57 def queue_name_prefix; end - # source://activejob//lib/active_job/queue_name.rb#58 + # source://activejob//lib/active_job/queue_name.rb#57 def queue_name_prefix=(value); end - # source://activejob//lib/active_job/queue_name.rb#58 + # source://activejob//lib/active_job/queue_name.rb#57 def queue_name_prefix?; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end # source://activejob//lib/active_job/exceptions.rb#11 @@ -329,15 +404,38 @@ class ActiveJob::Base # source://activejob//lib/active_job/exceptions.rb#11 def retry_jitter=(value); end - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def skip_after_callbacks_if_terminated(*args, **_arg1, &block); end + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#108 + def sidekiq_options_hash; end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#116 + def sidekiq_options_hash=(val); end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#108 + def sidekiq_retries_exhausted_block; end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#116 + def sidekiq_retries_exhausted_block=(val); end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#108 + def sidekiq_retry_in_block; end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#116 + def sidekiq_retry_in_block=(val); end + + private + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#103 + def __synchronized_sidekiq_options_hash; end - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def skip_after_callbacks_if_terminated=(*args, **_arg1, &block); end + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#103 + def __synchronized_sidekiq_retries_exhausted_block; end + + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#103 + def __synchronized_sidekiq_retry_in_block; end end end -# = Active Job Callbacks +# = Active Job \Callbacks # # Active Job provides hooks during the life cycle of a job. Callbacks allow you # to trigger logic during this cycle. Available callbacks are: @@ -349,9 +447,7 @@ end # * around_perform # * after_perform # -# NOTE: Calling the same callback multiple times will overwrite previous callback definitions. -# -# source://activejob//lib/active_job/callbacks.rb#21 +# source://activejob//lib/active_job/callbacks.rb#18 module ActiveJob::Callbacks extend ::ActiveSupport::Concern extend ::ActiveSupport::Callbacks @@ -364,16 +460,16 @@ module ActiveJob::Callbacks mixes_in_class_methods ::ActiveJob::Callbacks::ClassMethods class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _execute_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_execute_callbacks(&block); end end @@ -392,7 +488,7 @@ end # These methods will be included into any Active Job object, adding # callbacks for +perform+ and +enqueue+ methods. # -# source://activejob//lib/active_job/callbacks.rb#40 +# source://activejob//lib/active_job/callbacks.rb#34 module ActiveJob::Callbacks::ClassMethods # Defines a callback that will get called right after the # job is enqueued. @@ -401,7 +497,8 @@ module ActiveJob::Callbacks::ClassMethods # queue_as :default # # after_enqueue do |job| - # $statsd.increment "enqueue-video-job.success" + # result = job.successfully_enqueued? ? "success" : "failure" + # $statsd.increment "enqueue-video-job.#{result}" # end # # def perform(video_id) @@ -409,7 +506,7 @@ module ActiveJob::Callbacks::ClassMethods # end # end # - # source://activejob//lib/active_job/callbacks.rb#146 + # source://activejob//lib/active_job/callbacks.rb#141 def after_enqueue(*filters, &blk); end # Defines a callback that will get called right after the @@ -427,7 +524,7 @@ module ActiveJob::Callbacks::ClassMethods # end # end # - # source://activejob//lib/active_job/callbacks.rb#75 + # source://activejob//lib/active_job/callbacks.rb#69 def after_perform(*filters, &blk); end # Defines a callback that will get called around the enqueuing @@ -447,7 +544,7 @@ module ActiveJob::Callbacks::ClassMethods # end # end # - # source://activejob//lib/active_job/callbacks.rb#167 + # source://activejob//lib/active_job/callbacks.rb#162 def around_enqueue(*filters, &blk); end # Defines a callback that will get called around the job's perform method. @@ -479,7 +576,7 @@ module ActiveJob::Callbacks::ClassMethods # end # end # - # source://activejob//lib/active_job/callbacks.rb#108 + # source://activejob//lib/active_job/callbacks.rb#102 def around_perform(*filters, &blk); end # Defines a callback that will get called right before the @@ -497,7 +594,7 @@ module ActiveJob::Callbacks::ClassMethods # end # end # - # source://activejob//lib/active_job/callbacks.rb#127 + # source://activejob//lib/active_job/callbacks.rb#121 def before_enqueue(*filters, &blk); end # Defines a callback that will get called right before the @@ -515,7 +612,7 @@ module ActiveJob::Callbacks::ClassMethods # end # end # - # source://activejob//lib/active_job/callbacks.rb#56 + # source://activejob//lib/active_job/callbacks.rb#50 def before_perform(*filters, &blk); end end @@ -526,6 +623,9 @@ class ActiveJob::ConfiguredJob # source://activejob//lib/active_job/configured_job.rb#5 def initialize(job_class, options = T.unsafe(nil)); end + # source://activejob//lib/active_job/configured_job.rb#18 + def perform_all_later(multi_args); end + # source://activejob//lib/active_job/configured_job.rb#14 def perform_later(*_arg0, **_arg1, &_arg2); end @@ -533,10 +633,12 @@ class ActiveJob::ConfiguredJob def perform_now(*_arg0, **_arg1, &_arg2); end end +# = Active Job \Core +# # Provides general behavior that will be included into every Active Job # object that inherits from ActiveJob::Base. # -# source://activejob//lib/active_job/core.rb#6 +# source://activejob//lib/active_job/core.rb#8 module ActiveJob::Core extend ::ActiveSupport::Concern @@ -545,17 +647,17 @@ module ActiveJob::Core # Creates a new job instance. Takes the arguments that will be # passed to the perform method. # - # source://activejob//lib/active_job/core.rb#91 + # source://activejob//lib/active_job/core.rb#93 def initialize(*arguments, **_arg1); end # Job arguments # - # source://activejob//lib/active_job/core.rb#10 + # source://activejob//lib/active_job/core.rb#12 def arguments; end # Job arguments # - # source://activejob//lib/active_job/core.rb#10 + # source://activejob//lib/active_job/core.rb#12 def arguments=(_arg0); end # Attaches the stored job data to the current instance. Receives a hash @@ -585,27 +687,27 @@ module ActiveJob::Core # end # end # - # source://activejob//lib/active_job/core.rb#146 + # source://activejob//lib/active_job/core.rb#150 def deserialize(job_data); end # Track any exceptions raised by the backend so callers can inspect the errors. # - # source://activejob//lib/active_job/core.rb#54 + # source://activejob//lib/active_job/core.rb#56 def enqueue_error; end # Track any exceptions raised by the backend so callers can inspect the errors. # - # source://activejob//lib/active_job/core.rb#54 + # source://activejob//lib/active_job/core.rb#56 def enqueue_error=(_arg0); end # Track when a job was enqueued # - # source://activejob//lib/active_job/core.rb#44 + # source://activejob//lib/active_job/core.rb#46 def enqueued_at; end # Track when a job was enqueued # - # source://activejob//lib/active_job/core.rb#44 + # source://activejob//lib/active_job/core.rb#46 def enqueued_at=(_arg0); end # Hash that contains the number of times this job handled errors for each specific retry_on declaration. @@ -613,7 +715,7 @@ module ActiveJob::Core # while its associated value holds the number of executions where the corresponding retry_on # declaration handled one of its listed exceptions. # - # source://activejob//lib/active_job/core.rb#35 + # source://activejob//lib/active_job/core.rb#37 def exception_executions; end # Hash that contains the number of times this job handled errors for each specific retry_on declaration. @@ -621,135 +723,135 @@ module ActiveJob::Core # while its associated value holds the number of executions where the corresponding retry_on # declaration handled one of its listed exceptions. # - # source://activejob//lib/active_job/core.rb#35 + # source://activejob//lib/active_job/core.rb#37 def exception_executions=(_arg0); end # Number of times this job has been executed (which increments on every retry, like after an exception). # - # source://activejob//lib/active_job/core.rb#29 + # source://activejob//lib/active_job/core.rb#31 def executions; end # Number of times this job has been executed (which increments on every retry, like after an exception). # - # source://activejob//lib/active_job/core.rb#29 + # source://activejob//lib/active_job/core.rb#31 def executions=(_arg0); end # Job Identifier # - # source://activejob//lib/active_job/core.rb#17 + # source://activejob//lib/active_job/core.rb#19 def job_id; end # Job Identifier # - # source://activejob//lib/active_job/core.rb#17 + # source://activejob//lib/active_job/core.rb#19 def job_id=(_arg0); end # I18n.locale to be used during the job. # - # source://activejob//lib/active_job/core.rb#38 + # source://activejob//lib/active_job/core.rb#40 def locale; end # I18n.locale to be used during the job. # - # source://activejob//lib/active_job/core.rb#38 + # source://activejob//lib/active_job/core.rb#40 def locale=(_arg0); end # Priority that the job will have (lower is more priority). # - # source://activejob//lib/active_job/core.rb#23 + # source://activejob//lib/active_job/core.rb#25 def priority=(_arg0); end # ID optionally provided by adapter # - # source://activejob//lib/active_job/core.rb#26 + # source://activejob//lib/active_job/core.rb#28 def provider_job_id; end # ID optionally provided by adapter # - # source://activejob//lib/active_job/core.rb#26 + # source://activejob//lib/active_job/core.rb#28 def provider_job_id=(_arg0); end # Queue in which the job will reside. # - # source://activejob//lib/active_job/core.rb#20 + # source://activejob//lib/active_job/core.rb#22 def queue_name=(_arg0); end - # Timestamp when the job should be performed + # Time when the job should be performed # - # source://activejob//lib/active_job/core.rb#14 + # source://activejob//lib/active_job/core.rb#16 def scheduled_at; end - # Timestamp when the job should be performed + # Time when the job should be performed # - # source://activejob//lib/active_job/core.rb#14 + # source://activejob//lib/active_job/core.rb#16 def scheduled_at=(_arg0); end # Returns a hash with the job data that can safely be passed to the # queuing adapter. # - # source://activejob//lib/active_job/core.rb#104 + # source://activejob//lib/active_job/core.rb#107 def serialize; end # Sets the attribute serialized_arguments # # @param value the value to set the attribute serialized_arguments to. # - # source://activejob//lib/active_job/core.rb#11 + # source://activejob//lib/active_job/core.rb#13 def serialized_arguments=(_arg0); end # Configures the job with the given options. # - # source://activejob//lib/active_job/core.rb#160 + # source://activejob//lib/active_job/core.rb#165 def set(options = T.unsafe(nil)); end # Track whether the adapter received the job successfully. # - # source://activejob//lib/active_job/core.rb#47 + # source://activejob//lib/active_job/core.rb#49 def successfully_enqueued=(_arg0); end # @return [Boolean] # - # source://activejob//lib/active_job/core.rb#49 + # source://activejob//lib/active_job/core.rb#51 def successfully_enqueued?; end # Timezone to be used during the job. # - # source://activejob//lib/active_job/core.rb#41 + # source://activejob//lib/active_job/core.rb#43 def timezone; end # Timezone to be used during the job. # - # source://activejob//lib/active_job/core.rb#41 + # source://activejob//lib/active_job/core.rb#43 def timezone=(_arg0); end private # @return [Boolean] # - # source://activejob//lib/active_job/core.rb#193 + # source://activejob//lib/active_job/core.rb#198 def arguments_serialized?; end - # source://activejob//lib/active_job/core.rb#189 + # source://activejob//lib/active_job/core.rb#194 def deserialize_arguments(serialized_args); end - # source://activejob//lib/active_job/core.rb#178 + # source://activejob//lib/active_job/core.rb#183 def deserialize_arguments_if_needed; end - # source://activejob//lib/active_job/core.rb#185 + # source://activejob//lib/active_job/core.rb#190 def serialize_arguments(arguments); end - # source://activejob//lib/active_job/core.rb#170 + # source://activejob//lib/active_job/core.rb#175 def serialize_arguments_if_needed(arguments); end end # These methods will be included into any Active Job object, adding # helpers for de/serialization and creation of job instances. # -# source://activejob//lib/active_job/core.rb#58 +# source://activejob//lib/active_job/core.rb#60 module ActiveJob::Core::ClassMethods # Creates a new job instance from a hash created with +serialize+ # - # source://activejob//lib/active_job/core.rb#60 + # source://activejob//lib/active_job/core.rb#62 def deserialize(job_data); end # Creates a job preconfigured with the given options. You can call @@ -771,7 +873,7 @@ module ActiveJob::Core::ClassMethods # VideoJob.set(queue: :some_queue, wait_until: Time.now.tomorrow).perform_later(Video.last) # VideoJob.set(queue: :some_queue, wait: 5.minutes, priority: 10).perform_later(Video.last) # - # source://activejob//lib/active_job/core.rb#84 + # source://activejob//lib/active_job/core.rb#86 def set(options = T.unsafe(nil)); end end @@ -787,16 +889,26 @@ class ActiveJob::DeserializationError < ::StandardError def initialize; end end +# source://activejob//lib/active_job/enqueue_after_transaction_commit.rb#4 +module ActiveJob::EnqueueAfterTransactionCommit + private + + # source://activejob//lib/active_job/enqueue_after_transaction_commit.rb#6 + def raw_enqueue; end +end + # Can be raised by adapters if they wish to communicate to the caller a reason # why the adapter was unexpectedly unable to enqueue a job. # -# source://activejob//lib/active_job/enqueuing.rb#10 +# source://activejob//lib/active_job/enqueuing.rb#8 class ActiveJob::EnqueueError < ::StandardError; end -# source://activejob//lib/active_job/enqueuing.rb#12 +# source://activejob//lib/active_job/enqueuing.rb#40 module ActiveJob::Enqueuing extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveJob::Enqueuing::ClassMethods # Enqueues the job to be performed by the queue adapter. @@ -815,13 +927,25 @@ module ActiveJob::Enqueuing # my_job_instance.enqueue wait_until: Date.tomorrow.midnight # my_job_instance.enqueue priority: 10 # - # source://activejob//lib/active_job/enqueuing.rb#59 + # source://activejob//lib/active_job/enqueuing.rb#113 def enqueue(options = T.unsafe(nil)); end + + private + + # source://activejob//lib/active_job/enqueuing.rb#129 + def raw_enqueue; end + + module GeneratedClassMethods + def enqueue_after_transaction_commit; end + def enqueue_after_transaction_commit=(value); end + end + + module GeneratedInstanceMethods; end end # Includes the +perform_later+ method for job initialization. # -# source://activejob//lib/active_job/enqueuing.rb#16 +# source://activejob//lib/active_job/enqueuing.rb#58 module ActiveJob::Enqueuing::ClassMethods # Push a job onto the queue. By default the arguments must be either String, # Integer, Float, NilClass, TrueClass, FalseClass, BigDecimal, Symbol, Date, @@ -831,19 +955,31 @@ module ActiveJob::Enqueuing::ClassMethods # custom serializers. # # Returns an instance of the job class queued with arguments available in - # Job#arguments or false if the enqueue did not succeed. + # Job#arguments or +false+ if the enqueue did not succeed. # # After the attempted enqueue, the job will be yielded to an optional block. # + # If Active Job is used conjointly with Active Record, and #perform_later is called + # inside an Active Record transaction, then the enqueue is implicitly deferred to after + # the transaction is committed, or dropped if it's rolled back. In such case #perform_later + # will return the job instance like if it was successfully enqueued, but will still return + # +false+ if a callback prevented the job from being enqueued. + # + # This behavior can be changed on a per job basis: + # + # class NotificationJob < ApplicationJob + # self.enqueue_after_transaction_commit = false + # end + # # @yield [job] # - # source://activejob//lib/active_job/enqueuing.rb#28 + # source://activejob//lib/active_job/enqueuing.rb#82 def perform_later(*_arg0, **_arg1, &_arg2); end private - # source://activejob//lib/active_job/enqueuing.rb#38 - def job_or_instantiate(*args, **_arg1); end + # source://activejob//lib/active_job/enqueuing.rb#92 + def job_or_instantiate(*args, **_arg1, &_); end end # Provides behavior for retrying and discarding jobs on exceptions. @@ -856,9 +992,10 @@ module ActiveJob::Exceptions mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveJob::Exceptions::ClassMethods - # Reschedules the job to be re-executed. This is useful in combination - # with the +rescue_from+ option. When you rescue an exception from your job - # you can ask Active Job to retry performing your job. + # Reschedules the job to be re-executed. This is useful in combination with + # {rescue_from}[rdoc-ref:ActiveSupport::Rescuable::ClassMethods#rescue_from]. + # When you rescue an exception from your job you can ask Active Job to retry + # performing your job. # # ==== Options # * :wait - Enqueues the job with the specified delay in seconds @@ -878,35 +1015,64 @@ module ActiveJob::Exceptions # end # end # - # source://activejob//lib/active_job/exceptions.rb#124 + # source://activejob//lib/active_job/exceptions.rb#151 def retry_job(options = T.unsafe(nil)); end private - # source://activejob//lib/active_job/exceptions.rb#134 + # source://activejob//lib/active_job/exceptions.rb#161 def determine_delay(seconds_or_duration_or_algorithm:, executions:, jitter: T.unsafe(nil)); end - # source://activejob//lib/active_job/exceptions.rb#154 + # source://activejob//lib/active_job/exceptions.rb#182 def determine_jitter_for_delay(delay, jitter); end - # source://activejob//lib/active_job/exceptions.rb#159 + # source://activejob//lib/active_job/exceptions.rb#187 def executions_for(exceptions); end + # source://activejob//lib/active_job/exceptions.rb#196 + def run_after_discard_procs(exception); end + module GeneratedClassMethods + def after_discard_procs; end + def after_discard_procs=(value); end + def after_discard_procs?; end def retry_jitter; end def retry_jitter=(value); end end - module GeneratedInstanceMethods; end + module GeneratedInstanceMethods + def after_discard_procs; end + def after_discard_procs=(value); end + def after_discard_procs?; end + end end -# source://activejob//lib/active_job/exceptions.rb#14 +# source://activejob//lib/active_job/exceptions.rb#15 module ActiveJob::Exceptions::ClassMethods + # A block to run when a job is about to be discarded for any reason. + # + # ==== Example + # + # class WorkJob < ActiveJob::Base + # after_discard do |job, exception| + # ExceptionNotifier.report(exception) + # end + # + # ... + # + # end + # + # source://activejob//lib/active_job/exceptions.rb#124 + def after_discard(&blk); end + # Discard the job with no attempts to retry, if the exception is raised. This is useful when the subject of the job, # like an Active Record, is no longer available, and the job is thus no longer relevant. # # You can also pass a block that'll be invoked. This block is yielded with the job instance as the first and the error instance as the second parameter. # + # +retry_on+ and +discard_on+ handlers are searched from bottom to top, and up the class hierarchy. The handler of the first class for + # which exception.is_a?(klass) holds true is the one invoked, if any. + # # ==== Example # # class SearchIndexingJob < ActiveJob::Base @@ -921,7 +1087,7 @@ module ActiveJob::Exceptions::ClassMethods # end # end # - # source://activejob//lib/active_job/exceptions.rb#94 + # source://activejob//lib/active_job/exceptions.rb#103 def discard_on(*exceptions); end # Catch the exception and reschedule job for re-execution after so many seconds, for a specific number of attempts. @@ -932,13 +1098,16 @@ module ActiveJob::Exceptions::ClassMethods # You can also pass a block that'll be invoked if the retry attempts fail for custom logic rather than letting # the exception bubble up. This block is yielded with the job instance as the first and the error instance as the second parameter. # + # +retry_on+ and +discard_on+ handlers are searched from bottom to top, and up the class hierarchy. The handler of the first class for + # which exception.is_a?(klass) holds true is the one invoked, if any. + # # ==== Options # * :wait - Re-enqueues the job with a delay specified either in seconds (default: 3 seconds), # as a computing proc that takes the number of executions so far as an argument, or as a symbol reference of - # :exponentially_longer, which applies the wait algorithm of ((executions**4) + (Kernel.rand * (executions**4) * jitter)) + 2 + # :polynomially_longer, which applies the wait algorithm of ((executions**4) + (Kernel.rand * (executions**4) * jitter)) + 2 # (first wait ~3s, then ~18s, then ~83s, etc) - # * :attempts - Re-enqueues the job the specified number of times (default: 5 attempts) or a symbol reference of :unlimited - # to retry the job until it succeeds + # * :attempts - Enqueues the job the specified number of times (default: 5 attempts) or a symbol reference of :unlimited + # to retry the job until it succeeds. The number of attempts includes the original job execution. # * :queue - Re-enqueues the job on a different queue # * :priority - Re-enqueues the job with a different priority # * :jitter - A random delay of wait time used when calculating backoff. The default is 15% (0.15) which represents the upper bound of possible wait time (expressed as a percentage) @@ -951,11 +1120,11 @@ module ActiveJob::Exceptions::ClassMethods # retry_on CustomInfrastructureException, wait: 5.minutes, attempts: :unlimited # # retry_on ActiveRecord::Deadlocked, wait: 5.seconds, attempts: 3 - # retry_on Net::OpenTimeout, Timeout::Error, wait: :exponentially_longer, attempts: 10 # retries at most 10 times for Net::OpenTimeout and Timeout::Error combined + # retry_on Net::OpenTimeout, Timeout::Error, wait: :polynomially_longer, attempts: 10 # retries at most 10 times for Net::OpenTimeout and Timeout::Error combined # # To retry at most 10 times for each individual exception: - # # retry_on Net::OpenTimeout, wait: :exponentially_longer, attempts: 10 + # # retry_on Net::OpenTimeout, wait: :polynomially_longer, attempts: 10 # # retry_on Net::ReadTimeout, wait: 5.seconds, jitter: 0.30, attempts: 10 - # # retry_on Timeout::Error, wait: :exponentially_longer, attempts: 10 + # # retry_on Timeout::Error, wait: :polynomially_longer, attempts: 10 # # retry_on(YetAnotherCustomAppException) do |job, error| # ExceptionNotifier.caught(error) @@ -968,14 +1137,21 @@ module ActiveJob::Exceptions::ClassMethods # end # end # - # source://activejob//lib/active_job/exceptions.rb#58 + # source://activejob//lib/active_job/exceptions.rb#62 def retry_on(*exceptions, wait: T.unsafe(nil), attempts: T.unsafe(nil), queue: T.unsafe(nil), priority: T.unsafe(nil), jitter: T.unsafe(nil)); end end -# source://activejob//lib/active_job/exceptions.rb#131 +# source://activejob//lib/active_job/exceptions.rb#158 ActiveJob::Exceptions::JITTER_DEFAULT = T.let(T.unsafe(nil), Object) -# source://activejob//lib/active_job/execution.rb#7 +# = Active Job \Execution +# +# Provides methods to execute jobs immediately, and wraps job execution so +# that exceptions configured with +# {rescue_from}[rdoc-ref:ActiveSupport::Rescuable::ClassMethods#rescue_from] +# are handled. +# +# source://activejob//lib/active_job/execution.rb#12 module ActiveJob::Execution extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -985,7 +1161,7 @@ module ActiveJob::Execution mixes_in_class_methods ::ActiveSupport::Rescuable::ClassMethods mixes_in_class_methods ::ActiveJob::Execution::ClassMethods - # source://activejob//lib/active_job/execution.rb#51 + # source://activejob//lib/active_job/execution.rb#60 def perform(*_arg0); end # Performs the job immediately. The job is not sent to the queuing adapter @@ -1000,12 +1176,12 @@ module ActiveJob::Execution # # puts MyJob.new(*args).perform_now # => "Hello World!" # - # source://activejob//lib/active_job/execution.rb#40 + # source://activejob//lib/active_job/execution.rb#45 def perform_now; end private - # source://activejob//lib/active_job/execution.rb#56 + # source://activejob//lib/active_job/execution.rb#65 def _perform_job; end module GeneratedClassMethods @@ -1023,77 +1199,118 @@ end # Includes methods for executing and performing jobs instantly. # -# source://activejob//lib/active_job/execution.rb#12 +# source://activejob//lib/active_job/execution.rb#17 module ActiveJob::Execution::ClassMethods - # source://activejob//lib/active_job/execution.rb#21 + # source://activejob//lib/active_job/execution.rb#26 def execute(job_data); end # Performs the job immediately. # # MyJob.perform_now("mike") # - # source://activejob//lib/active_job/execution.rb#17 + # source://activejob//lib/active_job/execution.rb#22 def perform_now(*_arg0, **_arg1, &_arg2); end end -# source://activejob//lib/active_job/instrumentation.rb#4 +# source://activejob//lib/active_job/instrumentation.rb#16 module ActiveJob::Instrumentation extend ::ActiveSupport::Concern - # source://activejob//lib/active_job/instrumentation.rb#13 + # source://activejob//lib/active_job/instrumentation.rb#25 def perform_now; end private - # source://activejob//lib/active_job/instrumentation.rb#18 + # source://activejob//lib/active_job/instrumentation.rb#30 def _perform_job; end - # source://activejob//lib/active_job/instrumentation.rb#39 + # source://activejob//lib/active_job/instrumentation.rb#47 def halted_callback_hook(*_arg0); end - # source://activejob//lib/active_job/instrumentation.rb#23 + # source://activejob//lib/active_job/instrumentation.rb#35 def instrument(operation, payload = T.unsafe(nil), &block); end end -# source://activejob//lib/active_job/log_subscriber.rb#7 +# source://activejob//lib/active_job/log_subscriber.rb#6 class ActiveJob::LogSubscriber < ::ActiveSupport::LogSubscriber - # source://activejob//lib/active_job/log_subscriber.rb#94 + # source://activejob//lib/active_job/log_subscriber.rb#7 + def backtrace_cleaner; end + + # source://activejob//lib/active_job/log_subscriber.rb#7 + def backtrace_cleaner=(_arg0); end + + # source://activejob//lib/active_job/log_subscriber.rb#7 + def backtrace_cleaner?; end + + # source://activejob//lib/active_job/log_subscriber.rb#130 def discard(event); end - # source://activejob//lib/active_job/log_subscriber.rb#8 + # source://activejob//lib/active_job/log_subscriber.rb#9 def enqueue(event); end - # source://activejob//lib/active_job/log_subscriber.rb#27 + # source://activejob//lib/active_job/log_subscriber.rb#49 + def enqueue_all(event); end + + # source://activejob//lib/active_job/log_subscriber.rb#29 def enqueue_at(event); end - # source://activejob//lib/active_job/log_subscriber.rb#71 + # source://activejob//lib/active_job/log_subscriber.rb#105 def enqueue_retry(event); end - # source://activejob//lib/active_job/log_subscriber.rb#53 + # source://activejob//lib/active_job/log_subscriber.rb#86 def perform(event); end - # source://activejob//lib/active_job/log_subscriber.rb#46 + # source://activejob//lib/active_job/log_subscriber.rb#76 def perform_start(event); end - # source://activejob//lib/active_job/log_subscriber.rb#85 + # source://activejob//lib/active_job/log_subscriber.rb#120 def retry_stopped(event); end private - # source://activejob//lib/active_job/log_subscriber.rb#108 + # source://activejob//lib/active_job/log_subscriber.rb#145 def args_info(job); end - # source://activejob//lib/active_job/log_subscriber.rb#117 + # source://activejob//lib/active_job/log_subscriber.rb#203 + def enqueued_jobs_message(adapter, enqueued_jobs); end + + # source://activejob//lib/active_job/log_subscriber.rb#183 + def error(progname = T.unsafe(nil), &block); end + + # source://activejob//lib/active_job/log_subscriber.rb#199 + def extract_enqueue_source_location(locations); end + + # source://activejob//lib/active_job/log_subscriber.rb#154 def format(arg); end - # source://activejob//lib/active_job/log_subscriber.rb#134 + # source://activejob//lib/active_job/log_subscriber.rb#175 + def info(progname = T.unsafe(nil), &block); end + + # source://activejob//lib/active_job/log_subscriber.rb#191 + def log_enqueue_source; end + + # source://activejob//lib/active_job/log_subscriber.rb#171 def logger; end - # source://activejob//lib/active_job/log_subscriber.rb#104 + # source://activejob//lib/active_job/log_subscriber.rb#141 def queue_name(event); end - # source://activejob//lib/active_job/log_subscriber.rb#130 + # source://activejob//lib/active_job/log_subscriber.rb#167 def scheduled_at(event); end + + class << self + # source://activejob//lib/active_job/log_subscriber.rb#7 + def backtrace_cleaner; end + + # source://activejob//lib/active_job/log_subscriber.rb#7 + def backtrace_cleaner=(value); end + + # source://activejob//lib/active_job/log_subscriber.rb#7 + def backtrace_cleaner?; end + + # source://activesupport/7.2.0/lib/active_support/log_subscriber.rb#84 + def log_levels; end + end end # source://activejob//lib/active_job/logging.rb#7 @@ -1103,17 +1320,17 @@ module ActiveJob::Logging mixes_in_class_methods GeneratedClassMethods - # source://activejob//lib/active_job/logging.rb#17 + # source://activejob//lib/active_job/logging.rb#31 def perform_now; end private # @return [Boolean] # - # source://activejob//lib/active_job/logging.rb#31 + # source://activejob//lib/active_job/logging.rb#45 def logger_tagged_by_active_job?; end - # source://activejob//lib/active_job/logging.rb#22 + # source://activejob//lib/active_job/logging.rb#36 def tag_logger(*tags, &block); end module GeneratedClassMethods @@ -1125,10 +1342,13 @@ module ActiveJob::Logging module GeneratedInstanceMethods; end end -# The ActiveJob::QueueAdapter module is used to load the -# correct adapter. The default queue adapter is the +:async+ queue. +# = Active Job Queue adapter +# +# The +ActiveJob::QueueAdapter+ module is used to load the +# correct adapter. The default queue adapter is +:async+, +# which loads the ActiveJob::QueueAdapters::AsyncAdapter. # -# source://activejob//lib/active_job/queue_adapter.rb#8 +# source://activejob//lib/active_job/queue_adapter.rb#20 module ActiveJob::QueueAdapter extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -1148,42 +1368,42 @@ end # Includes the setter method for changing the active queue adapter. # -# source://activejob//lib/active_job/queue_adapter.rb#21 +# source://activejob//lib/active_job/queue_adapter.rb#31 module ActiveJob::QueueAdapter::ClassMethods # Returns the backend queue provider. The default queue adapter - # is the +:async+ queue. See QueueAdapters for more information. + # is +:async+. See QueueAdapters for more information. # - # source://activejob//lib/active_job/queue_adapter.rb#24 + # source://activejob//lib/active_job/queue_adapter.rb#34 def queue_adapter; end # Specify the backend queue provider. The default queue adapter # is the +:async+ queue. See QueueAdapters for more # information. # - # source://activejob//lib/active_job/queue_adapter.rb#37 + # source://activejob//lib/active_job/queue_adapter.rb#49 def queue_adapter=(name_or_adapter); end # Returns string denoting the name of the configured queue adapter. # By default returns "async". # - # source://activejob//lib/active_job/queue_adapter.rb#30 + # source://activejob//lib/active_job/queue_adapter.rb#41 def queue_adapter_name; end private - # source://activejob//lib/active_job/queue_adapter.rb#53 + # source://activejob//lib/active_job/queue_adapter.rb#65 def assign_adapter(adapter_name, queue_adapter); end # @return [Boolean] # - # source://activejob//lib/active_job/queue_adapter.rb#60 + # source://activejob//lib/active_job/queue_adapter.rb#72 def queue_adapter?(object); end end -# source://activejob//lib/active_job/queue_adapter.rb#58 +# source://activejob//lib/active_job/queue_adapter.rb#70 ActiveJob::QueueAdapter::ClassMethods::QUEUE_ADAPTER_METHODS = T.let(T.unsafe(nil), Array) -# == Active Job adapters +# = Active Job adapters # # Active Job has adapters for the following queuing backends: # @@ -1195,10 +1415,14 @@ ActiveJob::QueueAdapter::ClassMethods::QUEUE_ADAPTER_METHODS = T.let(T.unsafe(ni # * {Sidekiq}[https://sidekiq.org] # * {Sneakers}[https://github.com/jondot/sneakers] # * {Sucker Punch}[https://github.com/brandonhilkert/sucker_punch] -# * {Active Job Async Job}[https://api.rubyonrails.org/classes/ActiveJob/QueueAdapters/AsyncAdapter.html] -# * {Active Job Inline}[https://api.rubyonrails.org/classes/ActiveJob/QueueAdapters/InlineAdapter.html] # * Please Note: We are not accepting pull requests for new adapters. See the {README}[link:files/activejob/README_md.html] for more details. # +# For testing and development Active Job has three built-in adapters: +# +# * {Active Job Async}[https://api.rubyonrails.org/classes/ActiveJob/QueueAdapters/AsyncAdapter.html] +# * {Active Job Inline}[https://api.rubyonrails.org/classes/ActiveJob/QueueAdapters/InlineAdapter.html] +# * {Active Job Test}[https://api.rubyonrails.org/classes/ActiveJob/QueueAdapters/TestAdapter.html] +# # === Backends Features # # | | Async | Queues | Delayed | Priorities | Timeout | Retries | @@ -1213,6 +1437,7 @@ ActiveJob::QueueAdapter::ClassMethods::QUEUE_ADAPTER_METHODS = T.let(T.unsafe(ni # | Sucker Punch | Yes | Yes | Yes | No | No | No | # | Active Job Async | Yes | Yes | Yes | No | No | No | # | Active Job Inline | No | Yes | N/A | N/A | N/A | N/A | +# | Active Job Test | No | Yes | N/A | N/A | N/A | N/A | # # ==== Async # @@ -1288,12 +1513,7 @@ ActiveJob::QueueAdapter::ClassMethods::QUEUE_ADAPTER_METHODS = T.let(T.unsafe(ni # N/A: The adapter does not run in a separate process, and therefore doesn't # support retries. # -# === Async and Inline Queue Adapters -# -# Active Job has two built-in queue adapters intended for development and -# testing: +:async+ and +:inline+. -# -# source://activejob//lib/active_job/queue_adapters.rb#113 +# source://activejob//lib/active_job/queue_adapters.rb#114 module ActiveJob::QueueAdapters extend ::ActiveSupport::Autoload @@ -1303,15 +1523,43 @@ module ActiveJob::QueueAdapters # ActiveJob::QueueAdapters.lookup(:sidekiq) # # => ActiveJob::QueueAdapters::SidekiqAdapter # - # source://activejob//lib/active_job/queue_adapters.rb#136 + # source://activejob//lib/active_job/queue_adapters.rb#138 def lookup(name); end end end -# source://activejob//lib/active_job/queue_adapters.rb#128 +# source://activejob//lib/active_job/queue_adapters.rb#130 ActiveJob::QueueAdapters::ADAPTER = T.let(T.unsafe(nil), String) -# == Active Job Async adapter +# = Active Job Abstract Adapter +# +# Active Job supports multiple job queue systems. ActiveJob::QueueAdapters::AbstractAdapter +# forms the abstraction layer which makes this possible. +# +# source://activejob//lib/active_job/queue_adapters/abstract_adapter.rb#9 +class ActiveJob::QueueAdapters::AbstractAdapter + # @raise [NotImplementedError] + # + # source://activejob//lib/active_job/queue_adapters/abstract_adapter.rb#18 + def enqueue(job); end + + # Defines whether enqueuing should happen implicitly to after commit when called + # from inside a transaction. Most adapters should return true, but some adapters + # that use the same database as Active Record and are transaction aware can return + # false to continue enqueuing jobs as part of the transaction. + # + # @return [Boolean] + # + # source://activejob//lib/active_job/queue_adapters/abstract_adapter.rb#14 + def enqueue_after_transaction_commit?; end + + # @raise [NotImplementedError] + # + # source://activejob//lib/active_job/queue_adapters/abstract_adapter.rb#22 + def enqueue_at(job, timestamp); end +end + +# = Active Job Async adapter # # The Async adapter runs jobs with an in-process thread pool. # @@ -1336,7 +1584,7 @@ ActiveJob::QueueAdapters::ADAPTER = T.let(T.unsafe(nil), String) # short-lived jobs. Fine for dev/test; bad for production. # # source://activejob//lib/active_job/queue_adapters/async_adapter.rb#33 -class ActiveJob::QueueAdapters::AsyncAdapter +class ActiveJob::QueueAdapters::AsyncAdapter < ::ActiveJob::QueueAdapters::AbstractAdapter # See {Concurrent::ThreadPoolExecutor}[https://ruby-concurrency.github.io/concurrent-ruby/master/Concurrent/ThreadPoolExecutor.html] for executor options. # # @return [AsyncAdapter] a new instance of AsyncAdapter @@ -1414,7 +1662,7 @@ end # source://activejob//lib/active_job/queue_adapters/async_adapter.rb#75 ActiveJob::QueueAdapters::AsyncAdapter::Scheduler::DEFAULT_EXECUTOR_OPTIONS = T.let(T.unsafe(nil), Hash) -# == Active Job Inline adapter +# = Active Job Inline adapter # # When enqueuing jobs with the Inline adapter the job will be executed # immediately. @@ -1424,21 +1672,26 @@ ActiveJob::QueueAdapters::AsyncAdapter::Scheduler::DEFAULT_EXECUTOR_OPTIONS = T. # Rails.application.config.active_job.queue_adapter = :inline # # source://activejob//lib/active_job/queue_adapters/inline_adapter.rb#13 -class ActiveJob::QueueAdapters::InlineAdapter - # source://activejob//lib/active_job/queue_adapters/inline_adapter.rb#14 +class ActiveJob::QueueAdapters::InlineAdapter < ::ActiveJob::QueueAdapters::AbstractAdapter + # source://activejob//lib/active_job/queue_adapters/inline_adapter.rb#18 def enqueue(job); end + # @return [Boolean] + # + # source://activejob//lib/active_job/queue_adapters/inline_adapter.rb#14 + def enqueue_after_transaction_commit?; end + # @raise [NotImplementedError] # - # source://activejob//lib/active_job/queue_adapters/inline_adapter.rb#18 + # source://activejob//lib/active_job/queue_adapters/inline_adapter.rb#22 def enqueue_at(*_arg0); end end -# == Sidekiq adapter for Active Job +# = Sidekiq adapter for Active Job # # Simple, efficient background processing for Ruby. Sidekiq uses threads to # handle many jobs at the same time in the same process. It does not -# require Rails but will integrate tightly with it to make background +# require \Rails but will integrate tightly with it to make background # processing dead simple. # # Read more about Sidekiq {here}[http://sidekiq.org]. @@ -1447,87 +1700,95 @@ end # # Rails.application.config.active_job.queue_adapter = :sidekiq # -# source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#19 -class ActiveJob::QueueAdapters::SidekiqAdapter - # source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#20 +# source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#20 +class ActiveJob::QueueAdapters::SidekiqAdapter < ::ActiveJob::QueueAdapters::AbstractAdapter + # source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#21 def enqueue(job); end - # source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#29 + # source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#35 + def enqueue_all(jobs); end + + # source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#28 def enqueue_at(job, timestamp); end end -# source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#38 +# source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#66 class ActiveJob::QueueAdapters::SidekiqAdapter::JobWrapper - include ::Sidekiq::Worker - include ::Sidekiq::Worker::Options - extend ::Sidekiq::Worker::Options::ClassMethods - extend ::Sidekiq::Worker::ClassMethods + include ::Sidekiq::Job + include ::Sidekiq::Job::Options + extend ::Sidekiq::Job::Options::ClassMethods + extend ::Sidekiq::Job::ClassMethods - # source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#41 + # source://activejob//lib/active_job/queue_adapters/sidekiq_adapter.rb#69 def perform(job_data); end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#137 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#141 def sidekiq_options_hash; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#149 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#153 def sidekiq_options_hash=(_arg0); end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#137 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#141 def sidekiq_retries_exhausted_block; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#149 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#153 def sidekiq_retries_exhausted_block=(_arg0); end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#137 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#141 def sidekiq_retry_in_block; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#149 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#153 def sidekiq_retry_in_block=(_arg0); end class << self - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#104 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#108 def sidekiq_options_hash; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#112 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#116 def sidekiq_options_hash=(val); end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#104 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#108 def sidekiq_retries_exhausted_block; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#112 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#116 def sidekiq_retries_exhausted_block=(val); end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#104 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#108 def sidekiq_retry_in_block; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#112 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#116 def sidekiq_retry_in_block=(val); end private - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#99 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#103 def __synchronized_sidekiq_options_hash; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#99 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#103 def __synchronized_sidekiq_retries_exhausted_block; end - # source://sidekiq/6.5.9/lib/sidekiq/worker.rb#99 + # source://sidekiq/7.3.0/lib/sidekiq/job.rb#103 def __synchronized_sidekiq_retry_in_block; end end end -# == Test adapter for Active Job +# = Test adapter for Active Job # # The test adapter should be used only in testing. Along with # ActiveJob::TestCase and ActiveJob::TestHelper -# it makes a great tool to test your Rails application. +# it makes a great tool to test your \Rails application. # # To use the test adapter set +queue_adapter+ config to +:test+. # # Rails.application.config.active_job.queue_adapter = :test # # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#14 -class ActiveJob::QueueAdapters::TestAdapter +class ActiveJob::QueueAdapters::TestAdapter < ::ActiveJob::QueueAdapters::AbstractAdapter + # @return [TestAdapter] a new instance of TestAdapter + # + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#18 + def initialize(enqueue_after_transaction_commit: T.unsafe(nil)); end + # Returns the value of attribute at. # # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#15 @@ -1540,15 +1801,32 @@ class ActiveJob::QueueAdapters::TestAdapter # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#15 def at=(_arg0); end - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#28 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#36 def enqueue(job); end - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#33 + # Returns the value of attribute enqueue_after_transaction_commit. + # + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#15 + def enqueue_after_transaction_commit; end + + # Sets the attribute enqueue_after_transaction_commit + # + # @param value the value to set the attribute enqueue_after_transaction_commit to. + # + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#15 + def enqueue_after_transaction_commit=(_arg0); end + + # @return [Boolean] + # + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#22 + def enqueue_after_transaction_commit?; end + + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#41 def enqueue_at(job, timestamp); end # Provides a store of all the enqueued jobs with the TestAdapter so you can check them. # - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#19 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#27 def enqueued_jobs; end # Sets the attribute enqueued_jobs @@ -1596,7 +1874,7 @@ class ActiveJob::QueueAdapters::TestAdapter # Provides a store of all the performed jobs with the TestAdapter so you can check them. # - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#24 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#32 def performed_jobs; end # Sets the attribute performed_jobs @@ -1632,33 +1910,33 @@ class ActiveJob::QueueAdapters::TestAdapter private - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#79 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#87 def filter_as_proc(filter); end # @return [Boolean] # - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#57 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#65 def filtered?(job); end # @return [Boolean] # - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#71 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#79 def filtered_job_class?(job); end # @return [Boolean] # - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#65 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#73 def filtered_queue?(job); end # @return [Boolean] # - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#61 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#69 def filtered_time?(job); end - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#39 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#47 def job_to_hash(job, extras = T.unsafe(nil)); end - # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#48 + # source://activejob//lib/active_job/queue_adapters/test_adapter.rb#56 def perform_or_enqueue(perform, job, job_data); end end @@ -1672,7 +1950,7 @@ module ActiveJob::QueueName # Returns the name of the queue the job will be run on. # - # source://activejob//lib/active_job/queue_name.rb#62 + # source://activejob//lib/active_job/queue_name.rb#61 def queue_name; end module GeneratedClassMethods @@ -1715,8 +1993,7 @@ module ActiveJob::QueueName::ClassMethods # end # # Can be given a block that will evaluate in the context of the job - # allowing +self.arguments+ to be accessed so that a dynamic queue name - # can be applied: + # so that a dynamic queue name can be applied: # # class PublishToFeedJob < ApplicationJob # queue_as do @@ -1734,10 +2011,10 @@ module ActiveJob::QueueName::ClassMethods # end # end # - # source://activejob//lib/active_job/queue_name.rb#40 + # source://activejob//lib/active_job/queue_name.rb#39 def queue_as(part_name = T.unsafe(nil), &block); end - # source://activejob//lib/active_job/queue_name.rb#48 + # source://activejob//lib/active_job/queue_name.rb#47 def queue_name_from_part(part_name); end class << self @@ -1759,7 +2036,7 @@ module ActiveJob::QueuePriority # Returns the priority that the job will be created with # - # source://activejob//lib/active_job/queue_priority.rb#36 + # source://activejob//lib/active_job/queue_priority.rb#53 def priority; end module GeneratedClassMethods @@ -1791,9 +2068,26 @@ module ActiveJob::QueuePriority::ClassMethods # end # end # - # Specify either an argument or a block. + # Can be given a block that will evaluate in the context of the job + # so that a dynamic priority can be applied: + # + # class PublishToFeedJob < ApplicationJob + # queue_with_priority do + # post = self.arguments.first # - # source://activejob//lib/active_job/queue_priority.rb#22 + # if post.paid? + # 10 + # else + # 50 + # end + # end + # + # def perform(post) + # post.to_feed! + # end + # end + # + # source://activejob//lib/active_job/queue_priority.rb#39 def queue_with_priority(priority = T.unsafe(nil), &block); end class << self @@ -1823,29 +2117,31 @@ class ActiveJob::Railtie < ::Rails::Railtie; end # source://activejob//lib/active_job/arguments.rb#26 class ActiveJob::SerializationError < ::ArgumentError; end -# The ActiveJob::Serializers module is used to store a list of known serializers +# = Active Job \Serializers +# +# The +ActiveJob::Serializers+ module is used to store a list of known serializers # and to add new ones. It also has helpers to serialize/deserialize objects. # -# source://activejob//lib/active_job/serializers.rb#8 +# source://activejob//lib/active_job/serializers.rb#10 module ActiveJob::Serializers extend ::ActiveSupport::Autoload - # source://activejob//lib/active_job/serializers.rb#22 + # source://activejob//lib/active_job/serializers.rb#25 def _additional_serializers; end - # source://activejob//lib/active_job/serializers.rb#22 + # source://activejob//lib/active_job/serializers.rb#25 def _additional_serializers=(val); end class << self - # source://activejob//lib/active_job/serializers.rb#22 + # source://activejob//lib/active_job/serializers.rb#25 def _additional_serializers; end - # source://activejob//lib/active_job/serializers.rb#22 + # source://activejob//lib/active_job/serializers.rb#25 def _additional_serializers=(val); end # Adds new serializers to a list of known serializers. # - # source://activejob//lib/active_job/serializers.rb#54 + # source://activejob//lib/active_job/serializers.rb#57 def add_serializers(*new_serializers); end # Returns deserialized object. @@ -1854,25 +2150,39 @@ module ActiveJob::Serializers # # @raise [ArgumentError] # - # source://activejob//lib/active_job/serializers.rb#38 + # source://activejob//lib/active_job/serializers.rb#41 def deserialize(argument); end # Returns serialized representative of the passed object. # Will look up through all known serializers. - # Raises ActiveJob::SerializationError if it can't find a proper serializer. + # Raises ActiveJob::SerializationError if it can't find a proper serializer. # # @raise [SerializationError] # - # source://activejob//lib/active_job/serializers.rb#29 + # source://activejob//lib/active_job/serializers.rb#32 def serialize(argument); end # Returns list of known serializers. # - # source://activejob//lib/active_job/serializers.rb#49 + # source://activejob//lib/active_job/serializers.rb#52 def serializers; end end end +# source://activejob//lib/active_job/serializers/big_decimal_serializer.rb#7 +class ActiveJob::Serializers::BigDecimalSerializer < ::ActiveJob::Serializers::ObjectSerializer + # source://activejob//lib/active_job/serializers/big_decimal_serializer.rb#12 + def deserialize(hash); end + + # source://activejob//lib/active_job/serializers/big_decimal_serializer.rb#8 + def serialize(big_decimal); end + + private + + # source://activejob//lib/active_job/serializers/big_decimal_serializer.rb#17 + def klass; end +end + # source://activejob//lib/active_job/serializers/date_serializer.rb#5 class ActiveJob::Serializers::DateSerializer < ::ActiveJob::Serializers::ObjectSerializer # source://activejob//lib/active_job/serializers/date_serializer.rb#10 @@ -1900,7 +2210,7 @@ end # source://activejob//lib/active_job/serializers/duration_serializer.rb#5 class ActiveJob::Serializers::DurationSerializer < ::ActiveJob::Serializers::ObjectSerializer - # source://activejob//lib/active_job/serializers/duration_serializer.rb#10 + # source://activejob//lib/active_job/serializers/duration_serializer.rb#12 def deserialize(hash); end # source://activejob//lib/active_job/serializers/duration_serializer.rb#6 @@ -1908,7 +2218,7 @@ class ActiveJob::Serializers::DurationSerializer < ::ActiveJob::Serializers::Obj private - # source://activejob//lib/active_job/serializers/duration_serializer.rb#18 + # source://activejob//lib/active_job/serializers/duration_serializer.rb#20 def klass; end end @@ -1948,7 +2258,7 @@ end # end # end # -# source://activejob//lib/active_job/serializers/object_serializer.rb#24 +# source://activejob//lib/active_job/serializers/object_serializer.rb#26 class ActiveJob::Serializers::ObjectSerializer include ::Singleton extend ::Singleton::SingletonClassMethods @@ -1957,19 +2267,19 @@ class ActiveJob::Serializers::ObjectSerializer # # @raise [NotImplementedError] # - # source://activejob//lib/active_job/serializers/object_serializer.rb#42 + # source://activejob//lib/active_job/serializers/object_serializer.rb#44 def deserialize(json); end # Serializes an argument to a JSON primitive type. # - # source://activejob//lib/active_job/serializers/object_serializer.rb#37 + # source://activejob//lib/active_job/serializers/object_serializer.rb#39 def serialize(hash); end # Determines if an argument should be serialized by a serializer. # # @return [Boolean] # - # source://activejob//lib/active_job/serializers/object_serializer.rb#32 + # source://activejob//lib/active_job/serializers/object_serializer.rb#34 def serialize?(argument); end private @@ -1978,17 +2288,17 @@ class ActiveJob::Serializers::ObjectSerializer # # @raise [NotImplementedError] # - # source://activejob//lib/active_job/serializers/object_serializer.rb#48 + # source://activejob//lib/active_job/serializers/object_serializer.rb#50 def klass; end class << self - # source://activejob//lib/active_job/serializers/object_serializer.rb#28 + # source://activejob//lib/active_job/serializers/object_serializer.rb#30 def deserialize(*_arg0, **_arg1, &_arg2); end - # source://activejob//lib/active_job/serializers/object_serializer.rb#28 + # source://activejob//lib/active_job/serializers/object_serializer.rb#30 def serialize(*_arg0, **_arg1, &_arg2); end - # source://activejob//lib/active_job/serializers/object_serializer.rb#28 + # source://activejob//lib/active_job/serializers/object_serializer.rb#30 def serialize?(*_arg0, **_arg1, &_arg2); end private @@ -2050,16 +2360,22 @@ class ActiveJob::Serializers::TimeSerializer < ::ActiveJob::Serializers::TimeObj end # source://activejob//lib/active_job/serializers/time_with_zone_serializer.rb#5 -class ActiveJob::Serializers::TimeWithZoneSerializer < ::ActiveJob::Serializers::TimeObjectSerializer - # source://activejob//lib/active_job/serializers/time_with_zone_serializer.rb#6 +class ActiveJob::Serializers::TimeWithZoneSerializer < ::ActiveJob::Serializers::ObjectSerializer + # source://activejob//lib/active_job/serializers/time_with_zone_serializer.rb#15 def deserialize(hash); end + # source://activejob//lib/active_job/serializers/time_with_zone_serializer.rb#8 + def serialize(time_with_zone); end + private - # source://activejob//lib/active_job/serializers/time_with_zone_serializer.rb#11 + # source://activejob//lib/active_job/serializers/time_with_zone_serializer.rb#20 def klass; end end +# source://activejob//lib/active_job/serializers/time_with_zone_serializer.rb#6 +ActiveJob::Serializers::TimeWithZoneSerializer::NANO_PRECISION = T.let(T.unsafe(nil), Integer) + # source://activejob//lib/active_job/test_case.rb#6 class ActiveJob::TestCase < ::ActiveSupport::TestCase include ::ActiveJob::TestHelper @@ -2071,7 +2387,7 @@ end module ActiveJob::TestHelper include ::ActiveSupport::Testing::Assertions - # source://activejob//lib/active_job/test_helper.rb#51 + # source://activejob//lib/active_job/test_helper.rb#56 def after_teardown; end # Asserts that the number of enqueued jobs matches the given number. @@ -2128,7 +2444,7 @@ module ActiveJob::TestHelper # end # end # - # source://activejob//lib/active_job/test_helper.rb#123 + # source://activejob//lib/active_job/test_helper.rb#122 def assert_enqueued_jobs(number, only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), &block); end # Asserts that the job has been enqueued with the given arguments. @@ -2141,6 +2457,13 @@ module ActiveJob::TestHelper # assert_enqueued_with(at: Date.tomorrow.noon, queue: "my_queue") # end # + # For keyword arguments, specify them as a hash inside an array: + # + # def test_assert_enqueued_with_keyword_arguments + # MyJob.perform_later(arg1: 'value1', arg2: 'value2') + # assert_enqueued_with(job: MyJob, args: [{ arg1: 'value1', arg2: 'value2' }]) + # end + # # The given arguments may also be specified as matcher procs that return a # boolean value indicating whether a job's attribute meets certain criteria. # @@ -2177,7 +2500,7 @@ module ActiveJob::TestHelper # end # end # - # source://activejob//lib/active_job/test_helper.rb#392 + # source://activejob//lib/active_job/test_helper.rb#406 def assert_enqueued_with(job: T.unsafe(nil), args: T.unsafe(nil), at: T.unsafe(nil), queue: T.unsafe(nil), priority: T.unsafe(nil), &block); end # Asserts that no jobs have been enqueued. @@ -2227,7 +2550,7 @@ module ActiveJob::TestHelper # # assert_enqueued_jobs 0, &block # - # source://activejob//lib/active_job/test_helper.rb#185 + # source://activejob//lib/active_job/test_helper.rb#186 def assert_no_enqueued_jobs(only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), &block); end # Asserts that no jobs have been performed. @@ -2283,7 +2606,7 @@ module ActiveJob::TestHelper # # assert_performed_jobs 0, &block # - # source://activejob//lib/active_job/test_helper.rb#343 + # source://activejob//lib/active_job/test_helper.rb#348 def assert_no_performed_jobs(only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), &block); end # Asserts that the number of performed jobs matches the given number. @@ -2373,7 +2696,7 @@ module ActiveJob::TestHelper # end # end # - # source://activejob//lib/active_job/test_helper.rb#275 + # source://activejob//lib/active_job/test_helper.rb#278 def assert_performed_jobs(number, only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), &block); end # Asserts that the job has been performed with the given arguments. @@ -2433,10 +2756,10 @@ module ActiveJob::TestHelper # end # end # - # source://activejob//lib/active_job/test_helper.rb#494 + # source://activejob//lib/active_job/test_helper.rb#510 def assert_performed_with(job: T.unsafe(nil), args: T.unsafe(nil), at: T.unsafe(nil), queue: T.unsafe(nil), priority: T.unsafe(nil), &block); end - # source://activejob//lib/active_job/test_helper.rb#39 + # source://activejob//lib/active_job/test_helper.rb#41 def before_setup; end # source://activejob//lib/active_job/test_helper.rb#9 @@ -2500,10 +2823,14 @@ module ActiveJob::TestHelper # assert_performed_jobs 1 # end # - # If the +:at+ option is specified, then only run jobs enqueued to run - # immediately or before the given time + # If the +:at+ option is specified, then only jobs that have been enqueued + # to run at or before the given time will be performed. This includes jobs + # that have been enqueued without a time. + # + # If queue_adapter_for_test is overridden to return a different adapter, + # +perform_enqueued_jobs+ will merely execute the block. # - # source://activejob//lib/active_job/test_helper.rb#598 + # source://activejob//lib/active_job/test_helper.rb#620 def perform_enqueued_jobs(only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), at: T.unsafe(nil), &block); end # source://activejob//lib/active_job/test_helper.rb#9 @@ -2518,60 +2845,63 @@ module ActiveJob::TestHelper # assert_instance_of CustomQueueAdapter, HelloJob.queue_adapter # end # - # source://activejob//lib/active_job/test_helper.rb#634 + # source://activejob//lib/active_job/test_helper.rb#661 def queue_adapter; end - # Specifies the queue adapter to use with all Active Job test helpers. - # - # Returns an instance of the queue adapter and defaults to - # ActiveJob::QueueAdapters::TestAdapter. - # - # Note: The adapter provided by this method must provide some additional - # methods from those expected of a standard ActiveJob::QueueAdapter - # in order to be used with the active job test helpers. Refer to - # ActiveJob::QueueAdapters::TestAdapter. + # Returns a queue adapter instance to use with all Active Job test helpers. + # By default, returns an instance of ActiveJob::QueueAdapters::TestAdapter. + # Override this method to specify a different adapter. The adapter must + # implement the same interface as ActiveJob::QueueAdapters::TestAdapter. # # source://activejob//lib/active_job/test_helper.rb#66 def queue_adapter_for_test; end private - # source://activejob//lib/active_job/test_helper.rb#639 + # source://activejob//lib/active_job/test_helper.rb#676 def clear_enqueued_jobs; end - # source://activejob//lib/active_job/test_helper.rb#643 + # source://activejob//lib/active_job/test_helper.rb#680 def clear_performed_jobs; end - # source://activejob//lib/active_job/test_helper.rb#704 + # source://activejob//lib/active_job/test_helper.rb#745 def deserialize_args_for_assertion(job); end - # source://activejob//lib/active_job/test_helper.rb#679 + # source://activejob//lib/active_job/test_helper.rb#716 def enqueued_jobs_with(only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), at: T.unsafe(nil), &block); end - # source://activejob//lib/active_job/test_helper.rb#673 + # source://activejob//lib/active_job/test_helper.rb#710 def filter_as_proc(filter); end - # source://activejob//lib/active_job/test_helper.rb#687 + # source://activejob//lib/active_job/test_helper.rb#724 def flush_enqueued_jobs(only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), at: T.unsafe(nil)); end - # source://activejob//lib/active_job/test_helper.rb#711 + # source://activejob//lib/active_job/test_helper.rb#752 def instantiate_job(payload, skip_deserialize_arguments: T.unsafe(nil)); end - # source://activejob//lib/active_job/test_helper.rb#647 + # source://activejob//lib/active_job/test_helper.rb#684 def jobs_with(jobs, only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), at: T.unsafe(nil)); end - # source://activejob//lib/active_job/test_helper.rb#683 + # source://activejob//lib/active_job/test_helper.rb#720 def performed_jobs_with(only: T.unsafe(nil), except: T.unsafe(nil), queue: T.unsafe(nil), &block); end - # source://activejob//lib/active_job/test_helper.rb#695 + # source://activejob//lib/active_job/test_helper.rb#732 def prepare_args_for_assertion(args); end - # source://activejob//lib/active_job/test_helper.rb#718 + # source://activejob//lib/active_job/test_helper.rb#759 def queue_adapter_changed_jobs; end + # source://activejob//lib/active_job/test_helper.rb#666 + def require_active_job_test_adapter!(method); end + + # @return [Boolean] + # + # source://activejob//lib/active_job/test_helper.rb#672 + def using_test_adapter?; end + # @raise [ArgumentError] # - # source://activejob//lib/active_job/test_helper.rb#725 + # source://activejob//lib/active_job/test_helper.rb#766 def validate_option(only: T.unsafe(nil), except: T.unsafe(nil)); end end diff --git a/sorbet/rbi/gems/activemodel-serializers-xml@1.0.2.rbi b/sorbet/rbi/gems/activemodel-serializers-xml@1.0.2.rbi index 53b7becb1..e606241c0 100644 --- a/sorbet/rbi/gems/activemodel-serializers-xml@1.0.2.rbi +++ b/sorbet/rbi/gems/activemodel-serializers-xml@1.0.2.rbi @@ -4,16 +4,20 @@ # This is an autogenerated file for types exported from the `activemodel-serializers-xml` gem. # Please instead update this file by running `bin/tapioca gem activemodel-serializers-xml`. + # source://activemodel-serializers-xml//lib/active_model/serializers/xml.rb#8 module ActiveModel class << self - # source://activemodel/7.0.5/lib/active_model.rb#72 + # source://activemodel/7.2.0/lib/active_model/deprecator.rb#4 + def deprecator; end + + # source://activemodel/7.2.0/lib/active_model.rb#76 def eager_load!; end - # source://activemodel/7.0.5/lib/active_model/gem_version.rb#5 + # source://activemodel/7.2.0/lib/active_model/gem_version.rb#5 def gem_version; end - # source://activemodel/7.0.5/lib/active_model/version.rb#7 + # source://activemodel/7.2.0/lib/active_model/version.rb#7 def version; end end end diff --git a/sorbet/rbi/gems/activemodel@7.0.5.rbi b/sorbet/rbi/gems/activemodel@7.2.0.rbi similarity index 78% rename from sorbet/rbi/gems/activemodel@7.0.5.rbi rename to sorbet/rbi/gems/activemodel@7.2.0.rbi index e835f9d95..ee2828c04 100644 --- a/sorbet/rbi/gems/activemodel@7.0.5.rbi +++ b/sorbet/rbi/gems/activemodel@7.2.0.rbi @@ -4,30 +4,36 @@ # This is an autogenerated file for types exported from the `activemodel` gem. # Please instead update this file by running `bin/tapioca gem activemodel`. + +# :include: ../README.rdoc +# # source://activemodel//lib/active_model/gem_version.rb#3 module ActiveModel extend ::ActiveSupport::Autoload class << self - # source://activemodel//lib/active_model.rb#72 + # source://activemodel//lib/active_model/deprecator.rb#4 + def deprecator; end + + # source://activemodel//lib/active_model.rb#76 def eager_load!; end - # Returns the currently loaded version of \Active \Model as a Gem::Version. + # Returns the currently loaded version of \Active \Model as a +Gem::Version+. # # source://activemodel//lib/active_model/gem_version.rb#5 def gem_version; end - # Returns the currently loaded version of \Active \Model as a Gem::Version. + # Returns the currently loaded version of \Active \Model as a +Gem::Version+. # # source://activemodel//lib/active_model/version.rb#7 def version; end end end -# == Active \Model \API +# = Active \Model \API # # Includes the required interface for an object to interact with -# Action Pack and Action View, using different Active Model modules. +# Action Pack and Action View, using different Active \Model modules. # It includes model name introspections, conversions, translations, and # validations. Besides that, it allows you to initialize the object with a # hash of attributes, pretty much like Active Record does. @@ -43,7 +49,7 @@ end # person.name # => "bob" # person.age # => "18" # -# Note that, by default, ActiveModel::API implements persisted? +# Note that, by default, +ActiveModel::API+ implements #persisted? # to return +false+, which is the most common case. You may want to override # it in your class to simulate a different scenario: # @@ -59,7 +65,7 @@ end # person = Person.new(id: 1, name: 'bob') # person.persisted? # => true # -# Also, if for some reason you need to run code on initialize, make +# Also, if for some reason you need to run code on initialize ( ::new ), make # sure you call +super+ if you want the attributes hash initialization to # happen. # @@ -77,7 +83,7 @@ end # person.omg # => true # # For more detailed information on other functionalities available, please -# refer to the specific modules included in ActiveModel::API +# refer to the specific modules included in +ActiveModel::API+ # (see below). # # source://activemodel//lib/active_model/api.rb#59 @@ -136,6 +142,9 @@ module ActiveModel::API def _validators; end def _validators=(value); end def _validators?; end + def param_delimiter; end + def param_delimiter=(value); end + def param_delimiter?; end end module GeneratedInstanceMethods @@ -143,9 +152,19 @@ module ActiveModel::API def __callbacks?; end def _validators; end def _validators?; end + def param_delimiter=(value); end end end +# source://activemodel//lib/active_model/access.rb#7 +module ActiveModel::Access + # source://activemodel//lib/active_model/access.rb#8 + def slice(*methods); end + + # source://activemodel//lib/active_model/access.rb#12 + def values_at(*methods); end +end + # source://activemodel//lib/active_model/attribute.rb#6 class ActiveModel::Attribute # This method should not be called directly. @@ -156,47 +175,47 @@ class ActiveModel::Attribute # source://activemodel//lib/active_model/attribute.rb#33 def initialize(name, value_before_type_cast, type, original_attribute = T.unsafe(nil), value = T.unsafe(nil)); end - # source://activemodel//lib/active_model/attribute.rb#112 + # source://activemodel//lib/active_model/attribute.rb#115 def ==(other); end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#104 + # source://activemodel//lib/active_model/attribute.rb#107 def came_from_user?; end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#63 + # source://activemodel//lib/active_model/attribute.rb#66 def changed?; end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#67 + # source://activemodel//lib/active_model/attribute.rb#70 def changed_in_place?; end - # source://activemodel//lib/active_model/attribute.rb#132 + # source://activemodel//lib/active_model/attribute.rb#135 def encode_with(coder); end - # source://activemodel//lib/active_model/attribute.rb#112 + # source://activemodel//lib/active_model/attribute.rb#115 def eql?(other); end - # source://activemodel//lib/active_model/attribute.rb#71 + # source://activemodel//lib/active_model/attribute.rb#74 def forgetting_assignment; end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#108 + # source://activemodel//lib/active_model/attribute.rb#111 def has_been_read?; end - # source://activemodel//lib/active_model/attribute.rb#120 + # source://activemodel//lib/active_model/attribute.rb#123 def hash; end - # source://activemodel//lib/active_model/attribute.rb#124 + # source://activemodel//lib/active_model/attribute.rb#127 def init_with(coder); end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#100 + # source://activemodel//lib/active_model/attribute.rb#103 def initialized?; end # Returns the value of attribute name. @@ -207,12 +226,12 @@ class ActiveModel::Attribute # source://activemodel//lib/active_model/attribute.rb#47 def original_value; end - # source://activemodel//lib/active_model/attribute.rb#140 + # source://activemodel//lib/active_model/attribute.rb#143 def original_value_for_database; end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#59 + # source://activemodel//lib/active_model/attribute.rb#62 def serializable?(&block); end # Returns the value of attribute type. @@ -222,7 +241,7 @@ class ActiveModel::Attribute # @raise [NotImplementedError] # - # source://activemodel//lib/active_model/attribute.rb#96 + # source://activemodel//lib/active_model/attribute.rb#99 def type_cast(*_arg0); end # source://activemodel//lib/active_model/attribute.rb#41 @@ -236,39 +255,45 @@ class ActiveModel::Attribute # source://activemodel//lib/active_model/attribute.rb#55 def value_for_database; end - # source://activemodel//lib/active_model/attribute.rb#84 + # source://activemodel//lib/active_model/attribute.rb#87 def with_cast_value(value); end - # source://activemodel//lib/active_model/attribute.rb#88 + # source://activemodel//lib/active_model/attribute.rb#91 def with_type(type); end - # source://activemodel//lib/active_model/attribute.rb#80 + # source://activemodel//lib/active_model/attribute/user_provided_default.rb#7 + def with_user_default(value); end + + # source://activemodel//lib/active_model/attribute.rb#83 def with_value_from_database(value); end - # source://activemodel//lib/active_model/attribute.rb#75 + # source://activemodel//lib/active_model/attribute.rb#78 def with_value_from_user(value); end private - # source://activemodel//lib/active_model/attribute.rb#162 + # source://activemodel//lib/active_model/attribute.rb#169 def _original_value_for_database; end + # source://activemodel//lib/active_model/attribute.rb#165 + def _value_for_database; end + # Returns the value of attribute original_attribute. # - # source://activemodel//lib/active_model/attribute.rb#149 + # source://activemodel//lib/active_model/attribute.rb#152 def assigned?; end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#158 + # source://activemodel//lib/active_model/attribute.rb#161 def changed_from_assignment?; end - # source://activemodel//lib/active_model/attribute.rb#152 + # source://activemodel//lib/active_model/attribute.rb#155 def initialize_dup(other); end # Returns the value of attribute original_attribute. # - # source://activemodel//lib/active_model/attribute.rb#149 + # source://activemodel//lib/active_model/attribute.rb#152 def original_attribute; end class << self @@ -289,123 +314,131 @@ class ActiveModel::Attribute end end -# source://activemodel//lib/active_model/attribute.rb#166 +# source://activemodel//lib/active_model/attribute.rb#173 class ActiveModel::Attribute::FromDatabase < ::ActiveModel::Attribute - # source://activemodel//lib/active_model/attribute.rb#167 + # source://activemodel//lib/active_model/attribute.rb#178 + def forgetting_assignment; end + + # source://activemodel//lib/active_model/attribute.rb#174 def type_cast(value); end private - # source://activemodel//lib/active_model/attribute.rb#172 + # source://activemodel//lib/active_model/attribute.rb#192 def _original_value_for_database; end end -# source://activemodel//lib/active_model/attribute.rb#177 +# source://activemodel//lib/active_model/attribute.rb#197 class ActiveModel::Attribute::FromUser < ::ActiveModel::Attribute # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#182 + # source://activemodel//lib/active_model/attribute.rb#202 def came_from_user?; end - # source://activemodel//lib/active_model/attribute.rb#178 + # source://activemodel//lib/active_model/attribute.rb#198 def type_cast(value); end + + private + + # source://activemodel//lib/active_model/attribute.rb#207 + def _value_for_database; end end -# source://activemodel//lib/active_model/attribute.rb#197 +# source://activemodel//lib/active_model/attribute.rb#222 class ActiveModel::Attribute::Null < ::ActiveModel::Attribute # @return [Null] a new instance of Null # - # source://activemodel//lib/active_model/attribute.rb#198 + # source://activemodel//lib/active_model/attribute.rb#223 def initialize(name); end - # source://activemodel//lib/active_model/attribute.rb#202 + # source://activemodel//lib/active_model/attribute.rb#227 def type_cast(*_arg0); end # @raise [ActiveModel::MissingAttributeError] # - # source://activemodel//lib/active_model/attribute.rb#210 + # source://activemodel//lib/active_model/attribute.rb#235 def with_cast_value(value); end - # source://activemodel//lib/active_model/attribute.rb#206 + # source://activemodel//lib/active_model/attribute.rb#231 def with_type(type); end # @raise [ActiveModel::MissingAttributeError] # - # source://activemodel//lib/active_model/attribute.rb#210 + # source://activemodel//lib/active_model/attribute.rb#235 def with_value_from_database(value); end # @raise [ActiveModel::MissingAttributeError] # - # source://activemodel//lib/active_model/attribute.rb#210 + # source://activemodel//lib/active_model/attribute.rb#235 def with_value_from_user(value); end end -# source://activemodel//lib/active_model/attribute.rb#217 +# source://activemodel//lib/active_model/attribute.rb#242 class ActiveModel::Attribute::Uninitialized < ::ActiveModel::Attribute # @return [Uninitialized] a new instance of Uninitialized # - # source://activemodel//lib/active_model/attribute.rb#220 + # source://activemodel//lib/active_model/attribute.rb#245 def initialize(name, type); end - # source://activemodel//lib/active_model/attribute.rb#241 + # source://activemodel//lib/active_model/attribute.rb#266 def forgetting_assignment; end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#237 + # source://activemodel//lib/active_model/attribute.rb#262 def initialized?; end - # source://activemodel//lib/active_model/attribute.rb#230 + # source://activemodel//lib/active_model/attribute.rb#255 def original_value; end - # source://activemodel//lib/active_model/attribute.rb#224 + # source://activemodel//lib/active_model/attribute.rb#249 def value; end - # source://activemodel//lib/active_model/attribute.rb#234 + # source://activemodel//lib/active_model/attribute.rb#259 def value_for_database; end - # source://activemodel//lib/active_model/attribute.rb#245 + # source://activemodel//lib/active_model/attribute.rb#270 def with_type(type); end end -# source://activemodel//lib/active_model/attribute.rb#218 +# source://activemodel//lib/active_model/attribute.rb#243 ActiveModel::Attribute::Uninitialized::UNINITIALIZED_ORIGINAL_VALUE = T.let(T.unsafe(nil), Object) -# source://activemodel//lib/active_model/attribute/user_provided_default.rb#7 +# source://activemodel//lib/active_model/attribute/user_provided_default.rb#11 class ActiveModel::Attribute::UserProvidedDefault < ::ActiveModel::Attribute::FromUser # @return [UserProvidedDefault] a new instance of UserProvidedDefault # - # source://activemodel//lib/active_model/attribute/user_provided_default.rb#8 + # source://activemodel//lib/active_model/attribute/user_provided_default.rb#12 def initialize(name, value, type, database_default); end - # source://activemodel//lib/active_model/attribute/user_provided_default.rb#25 + # source://activemodel//lib/active_model/attribute/user_provided_default.rb#29 def marshal_dump; end - # source://activemodel//lib/active_model/attribute/user_provided_default.rb#36 + # source://activemodel//lib/active_model/attribute/user_provided_default.rb#40 def marshal_load(values); end - # source://activemodel//lib/active_model/attribute/user_provided_default.rb#13 + # source://activemodel//lib/active_model/attribute/user_provided_default.rb#17 def value_before_type_cast; end - # source://activemodel//lib/active_model/attribute/user_provided_default.rb#21 + # source://activemodel//lib/active_model/attribute/user_provided_default.rb#25 def with_type(type); end private # Returns the value of attribute user_provided_value. # - # source://activemodel//lib/active_model/attribute/user_provided_default.rb#48 + # source://activemodel//lib/active_model/attribute/user_provided_default.rb#52 def user_provided_value; end end -# source://activemodel//lib/active_model/attribute.rb#187 +# source://activemodel//lib/active_model/attribute.rb#212 class ActiveModel::Attribute::WithCastValue < ::ActiveModel::Attribute # @return [Boolean] # - # source://activemodel//lib/active_model/attribute.rb#192 + # source://activemodel//lib/active_model/attribute.rb#217 def changed_in_place?; end - # source://activemodel//lib/active_model/attribute.rb#188 + # source://activemodel//lib/active_model/attribute.rb#213 def type_cast(value); end end @@ -417,7 +450,7 @@ module ActiveModel::AttributeAssignment # keys matching the attribute names. # # If the passed hash responds to permitted? method and the return value - # of this method is +false+ an ActiveModel::ForbiddenAttributesError + # of this method is +false+ an ActiveModel::ForbiddenAttributesError # exception is raised. # # class Cat @@ -440,7 +473,7 @@ module ActiveModel::AttributeAssignment # keys matching the attribute names. # # If the passed hash responds to permitted? method and the return value - # of this method is +false+ an ActiveModel::ForbiddenAttributesError + # of this method is +false+ an ActiveModel::ForbiddenAttributesError # exception is raised. # # class Cat @@ -468,13 +501,13 @@ module ActiveModel::AttributeAssignment def _assign_attributes(attributes); end end -# == Active \Model \Attribute \Methods +# = Active \Model \Attribute \Methods # # Provides a way to add prefixes and suffixes to your methods as -# well as handling the creation of ActiveRecord::Base-like +# well as handling the creation of ActiveRecord::Base - like # class methods such as +table_name+. # -# The requirements to implement ActiveModel::AttributeMethods are to: +# The requirements to implement +ActiveModel::AttributeMethods+ are to: # # * include ActiveModel::AttributeMethods in your class. # * Call each of its methods you want to add, such as +attribute_method_suffix+ @@ -528,8 +561,8 @@ module ActiveModel::AttributeMethods # attribute method. If so, we tell +attribute_missing+ to dispatch the # attribute. This method can be overloaded to customize the behavior. # - # source://activemodel//lib/active_model/attribute_methods.rb#459 - def attribute_missing(match, *args, **_arg2, &block); end + # source://activemodel//lib/active_model/attribute_methods.rb#515 + def attribute_missing(match, *_arg1, **_arg2, &_arg3); end # Allows access to the object attributes, which are held in the hash # returned by attributes, as though they were first-class @@ -542,12 +575,12 @@ module ActiveModel::AttributeMethods # class belonging to the +clients+ table with a +master_id+ foreign key # can instantiate master through Client#master. # - # source://activemodel//lib/active_model/attribute_methods.rb#445 - def method_missing(method, *args, **_arg2, &block); end + # source://activemodel//lib/active_model/attribute_methods.rb#502 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute_methods.rb#468 + # source://activemodel//lib/active_model/attribute_methods.rb#523 def respond_to?(method, include_private_methods = T.unsafe(nil)); end # A +Person+ instance with a +name+ attribute can ask @@ -557,43 +590,43 @@ module ActiveModel::AttributeMethods private - # source://activemodel//lib/active_model/attribute_methods.rb#496 + # source://activemodel//lib/active_model/attribute_methods.rb#551 def _read_attribute(attr); end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute_methods.rb#481 + # source://activemodel//lib/active_model/attribute_methods.rb#536 def attribute_method?(attr_name); end # Returns a struct representing the matching attribute method. # The struct's attributes are prefix, base and suffix. # - # source://activemodel//lib/active_model/attribute_methods.rb#487 + # source://activemodel//lib/active_model/attribute_methods.rb#542 def matched_attribute_method(method_name); end # @raise [ActiveModel::MissingAttributeError] # - # source://activemodel//lib/active_model/attribute_methods.rb#492 + # source://activemodel//lib/active_model/attribute_methods.rb#547 def missing_attribute(attr_name, stack); end module GeneratedClassMethods def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end end module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end end end -# source://activemodel//lib/active_model/attribute_methods.rb#500 +# source://activemodel//lib/active_model/attribute_methods.rb#555 module ActiveModel::AttributeMethods::AttrNames class << self # We want to generate the methods via module_eval rather than @@ -611,18 +644,18 @@ module ActiveModel::AttributeMethods::AttrNames # Making it frozen means that it doesn't get duped when used to # key the @attributes in read_attribute. # - # source://activemodel//lib/active_model/attribute_methods.rb#517 + # source://activemodel//lib/active_model/attribute_methods.rb#572 def define_attribute_accessor_method(owner, attr_name, writer: T.unsafe(nil)); end end end -# source://activemodel//lib/active_model/attribute_methods.rb#501 +# source://activemodel//lib/active_model/attribute_methods.rb#556 ActiveModel::AttributeMethods::AttrNames::DEF_SAFE_NAME = T.let(T.unsafe(nil), Regexp) # source://activemodel//lib/active_model/attribute_methods.rb#68 ActiveModel::AttributeMethods::CALL_COMPILABLE_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://activemodel//lib/active_model/attribute_methods.rb#76 +# source://activemodel//lib/active_model/attribute_methods.rb#75 module ActiveModel::AttributeMethods::ClassMethods # Allows you to make aliases for attributes. # @@ -648,19 +681,25 @@ module ActiveModel::AttributeMethods::ClassMethods # person.name_short? # => true # person.nickname_short? # => true # - # source://activemodel//lib/active_model/attribute_methods.rb#204 + # source://activemodel//lib/active_model/attribute_methods.rb#203 def alias_attribute(new_name, old_name); end + # source://activemodel//lib/active_model/attribute_methods.rb#221 + def alias_attribute_method_definition(code_generator, pattern, new_name, old_name); end + + # source://activemodel//lib/active_model/attribute_methods.rb#377 + def aliases_by_attribute_name; end + # Returns the original name for the alias +name+ # - # source://activemodel//lib/active_model/attribute_methods.rb#243 + # source://activemodel//lib/active_model/attribute_methods.rb#240 def attribute_alias(name); end # Is +new_name+ an alias? # # @return [Boolean] # - # source://activemodel//lib/active_model/attribute_methods.rb#238 + # source://activemodel//lib/active_model/attribute_methods.rb#235 def attribute_alias?(new_name); end # Declares a method available for all attributes with the given prefix @@ -694,7 +733,7 @@ module ActiveModel::AttributeMethods::ClassMethods # person.reset_name_to_default! # person.name # => 'Default Name' # - # source://activemodel//lib/active_model/attribute_methods.rb#176 + # source://activemodel//lib/active_model/attribute_methods.rb#175 def attribute_method_affix(*affixes); end # Declares a method available for all attributes with the given prefix. @@ -728,7 +767,7 @@ module ActiveModel::AttributeMethods::ClassMethods # person.clear_name # person.name # => nil # - # source://activemodel//lib/active_model/attribute_methods.rb#107 + # source://activemodel//lib/active_model/attribute_methods.rb#106 def attribute_method_prefix(*prefixes, parameters: T.unsafe(nil)); end # Declares a method available for all attributes with the given suffix. @@ -761,11 +800,11 @@ module ActiveModel::AttributeMethods::ClassMethods # person.name # => "Bob" # person.name_short? # => true # - # source://activemodel//lib/active_model/attribute_methods.rb#141 + # source://activemodel//lib/active_model/attribute_methods.rb#140 def attribute_method_suffix(*suffixes, parameters: T.unsafe(nil)); end # Declares an attribute that should be prefixed and suffixed by - # ActiveModel::AttributeMethods. + # +ActiveModel::AttributeMethods+. # # To use, pass an attribute name (as string or symbol). Be sure to declare # +define_attribute_method+ after you define any prefix, suffix or affix @@ -793,11 +832,14 @@ module ActiveModel::AttributeMethods::ClassMethods # person.name # => "Bob" # person.name_short? # => true # - # source://activemodel//lib/active_model/attribute_methods.rb#304 - def define_attribute_method(attr_name, _owner: T.unsafe(nil)); end + # source://activemodel//lib/active_model/attribute_methods.rb#306 + def define_attribute_method(attr_name, _owner: T.unsafe(nil), as: T.unsafe(nil)); end + + # source://activemodel//lib/active_model/attribute_methods.rb#315 + def define_attribute_method_pattern(pattern, attr_name, owner:, as:, override: T.unsafe(nil)); end # Declares the attributes that should be prefixed and suffixed by - # ActiveModel::AttributeMethods. + # +ActiveModel::AttributeMethods+. # # To use, pass attribute names (as strings or symbols). Be sure to declare # +define_attribute_methods+ after you define any prefix, suffix, or affix @@ -820,10 +862,16 @@ module ActiveModel::AttributeMethods::ClassMethods # end # end # - # source://activemodel//lib/active_model/attribute_methods.rb#270 + # source://activemodel//lib/active_model/attribute_methods.rb#267 def define_attribute_methods(*attr_names); end - # Removes all the previously dynamically defined methods from the class. + # source://activemodel//lib/active_model/attribute_methods.rb#211 + def eagerly_generate_alias_attribute_methods(new_name, old_name); end + + # source://activemodel//lib/active_model/attribute_methods.rb#217 + def generate_alias_attribute_methods(code_generator, new_name, old_name); end + + # Removes all the previously dynamically defined methods from the class, including alias attribute methods. # # class Person # include ActiveModel::AttributeMethods @@ -831,6 +879,7 @@ module ActiveModel::AttributeMethods::ClassMethods # attr_accessor :name # attribute_method_suffix '_short?' # define_attribute_method :name + # alias_attribute :first_name, :name # # private # def attribute_short?(attr) @@ -840,13 +889,15 @@ module ActiveModel::AttributeMethods::ClassMethods # # person = Person.new # person.name = 'Bob' + # person.first_name # => "Bob" # person.name_short? # => true # # Person.undefine_attribute_methods # # person.name_short? # => NoMethodError + # person.first_name # => NoMethodError # - # source://activemodel//lib/active_model/attribute_methods.rb#345 + # source://activemodel//lib/active_model/attribute_methods.rb#370 def undefine_attribute_methods; end private @@ -861,64 +912,76 @@ module ActiveModel::AttributeMethods::ClassMethods # significantly (in our case our test suite finishes 10% faster with # this cache). # - # source://activemodel//lib/active_model/attribute_methods.rb#370 - def attribute_method_matchers_cache; end + # source://activemodel//lib/active_model/attribute_methods.rb#412 + def attribute_method_patterns_cache; end + + # source://activemodel//lib/active_model/attribute_methods.rb#416 + def attribute_method_patterns_matching(method_name); end - # source://activemodel//lib/active_model/attribute_methods.rb#374 - def attribute_method_matchers_matching(method_name); end + # source://activemodel//lib/active_model/attribute_methods.rb#440 + def build_mangled_name(name); end + + # source://activemodel//lib/active_model/attribute_methods.rb#450 + def define_call(code_generator, name, target_name, mangled_name, parameters, call_args, namespace:, as:); end # Define a method `name` in `mod` that dispatches to `send` # using the given `extra` args. This falls back on `send` # if the called name cannot be compiled. # - # source://activemodel//lib/active_model/attribute_methods.rb#383 - def define_proxy_call(code_generator, name, target, parameters, *call_args, namespace:); end + # source://activemodel//lib/active_model/attribute_methods.rb#425 + def define_proxy_call(code_generator, name, proxy_target, parameters, *call_args, namespace:, as: T.unsafe(nil)); end - # source://activemodel//lib/active_model/attribute_methods.rb#353 + # source://activemodel//lib/active_model/attribute_methods.rb#395 def generated_attribute_methods; end + # source://activemodel//lib/active_model/attribute_methods.rb#382 + def inherited(base); end + # @return [Boolean] # - # source://activemodel//lib/active_model/attribute_methods.rb#357 + # source://activemodel//lib/active_model/attribute_methods.rb#399 def instance_method_already_implemented?(method_name); end + + # source://activemodel//lib/active_model/attribute_methods.rb#391 + def resolve_attribute_name(name); end end -# source://activemodel//lib/active_model/attribute_methods.rb#409 -class ActiveModel::AttributeMethods::ClassMethods::AttributeMethodMatcher - # @return [AttributeMethodMatcher] a new instance of AttributeMethodMatcher +# source://activemodel//lib/active_model/attribute_methods.rb#466 +class ActiveModel::AttributeMethods::ClassMethods::AttributeMethodPattern + # @return [AttributeMethodPattern] a new instance of AttributeMethodPattern # - # source://activemodel//lib/active_model/attribute_methods.rb#414 + # source://activemodel//lib/active_model/attribute_methods.rb#471 def initialize(prefix: T.unsafe(nil), suffix: T.unsafe(nil), parameters: T.unsafe(nil)); end - # source://activemodel//lib/active_model/attribute_methods.rb#423 + # source://activemodel//lib/active_model/attribute_methods.rb#480 def match(method_name); end - # source://activemodel//lib/active_model/attribute_methods.rb#429 + # source://activemodel//lib/active_model/attribute_methods.rb#486 def method_name(attr_name); end # Returns the value of attribute parameters. # - # source://activemodel//lib/active_model/attribute_methods.rb#410 + # source://activemodel//lib/active_model/attribute_methods.rb#467 def parameters; end # Returns the value of attribute prefix. # - # source://activemodel//lib/active_model/attribute_methods.rb#410 + # source://activemodel//lib/active_model/attribute_methods.rb#467 def prefix; end - # Returns the value of attribute suffix. + # Returns the value of attribute proxy_target. # - # source://activemodel//lib/active_model/attribute_methods.rb#410 - def suffix; end + # source://activemodel//lib/active_model/attribute_methods.rb#467 + def proxy_target; end - # Returns the value of attribute target. + # Returns the value of attribute suffix. # - # source://activemodel//lib/active_model/attribute_methods.rb#410 - def target; end + # source://activemodel//lib/active_model/attribute_methods.rb#467 + def suffix; end end -# source://activemodel//lib/active_model/attribute_methods.rb#412 -class ActiveModel::AttributeMethods::ClassMethods::AttributeMethodMatcher::AttributeMethodMatch < ::Struct +# source://activemodel//lib/active_model/attribute_methods.rb#469 +class ActiveModel::AttributeMethods::ClassMethods::AttributeMethodPattern::AttributeMethod < ::Struct # Returns the value of attribute attr_name # # @return [Object] the current value of attr_name @@ -930,16 +993,16 @@ class ActiveModel::AttributeMethods::ClassMethods::AttributeMethodMatcher::Attri # @return [Object] the newly set value def attr_name=(_); end - # Returns the value of attribute target + # Returns the value of attribute proxy_target # - # @return [Object] the current value of target - def target; end + # @return [Object] the current value of proxy_target + def proxy_target; end - # Sets the attribute target + # Sets the attribute proxy_target # - # @param value [Object] the value to set the attribute target to. + # @param value [Object] the value to set the attribute proxy_target to. # @return [Object] the newly set value - def target=(_); end + def proxy_target=(_); end class << self def [](*_arg0); end @@ -950,9 +1013,6 @@ class ActiveModel::AttributeMethods::ClassMethods::AttributeMethodMatcher::Attri end end -# source://activemodel//lib/active_model/attribute_methods.rb#69 -ActiveModel::AttributeMethods::FORWARD_PARAMETERS = T.let(T.unsafe(nil), String) - # source://activemodel//lib/active_model/attribute_methods.rb#67 ActiveModel::AttributeMethods::NAME_COMPILABLE_REGEXP = T.let(T.unsafe(nil), Regexp) @@ -1027,6 +1087,166 @@ end # source://activemodel//lib/active_model/attribute_mutation_tracker.rb#8 ActiveModel::AttributeMutationTracker::OPTION_NOT_GIVEN = T.let(T.unsafe(nil), Object) +# source://activemodel//lib/active_model/attribute_registration.rb#8 +module ActiveModel::AttributeRegistration + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActiveModel::AttributeRegistration::ClassMethods +end + +# source://activemodel//lib/active_model/attribute_registration.rb#11 +module ActiveModel::AttributeRegistration::ClassMethods + # source://activemodel//lib/active_model/attribute_registration.rb#31 + def _default_attributes; end + + # source://activemodel//lib/active_model/attribute_registration.rb#12 + def attribute(name, type = T.unsafe(nil), default: T.unsafe(nil), **options); end + + # source://activemodel//lib/active_model/attribute_registration.rb#37 + def attribute_types; end + + # source://activemodel//lib/active_model/attribute_registration.rb#23 + def decorate_attributes(names = T.unsafe(nil), &decorator); end + + # source://activemodel//lib/active_model/attribute_registration.rb#43 + def type_for_attribute(attribute_name, &block); end + + private + + # source://activemodel//lib/active_model/attribute_registration.rb#81 + def apply_pending_attribute_modifications(attribute_set); end + + # Hook for other modules to override. The attribute type is passed + # through this method immediately after it is resolved, before any type + # decorations are applied. + # + # source://activemodel//lib/active_model/attribute_registration.rb#112 + def hook_attribute_type(attribute, type); end + + # source://activemodel//lib/active_model/attribute_registration.rb#77 + def pending_attribute_modifications; end + + # source://activemodel//lib/active_model/attribute_registration.rb#91 + def reset_default_attributes; end + + # source://activemodel//lib/active_model/attribute_registration.rb#96 + def reset_default_attributes!; end + + # source://activemodel//lib/active_model/attribute_registration.rb#101 + def resolve_attribute_name(name); end + + # source://activemodel//lib/active_model/attribute_registration.rb#105 + def resolve_type_name(name, **options); end +end + +# source://activemodel//lib/active_model/attribute_registration.rb#67 +class ActiveModel::AttributeRegistration::ClassMethods::PendingDecorator < ::Struct + # source://activemodel//lib/active_model/attribute_registration.rb#68 + def apply_to(attribute_set); end + + # Returns the value of attribute decorator + # + # @return [Object] the current value of decorator + def decorator; end + + # Sets the attribute decorator + # + # @param value [Object] the value to set the attribute decorator to. + # @return [Object] the newly set value + def decorator=(_); end + + # Returns the value of attribute names + # + # @return [Object] the current value of names + def names; end + + # Sets the attribute names + # + # @param value [Object] the value to set the attribute names to. + # @return [Object] the newly set value + def names=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://activemodel//lib/active_model/attribute_registration.rb#61 +class ActiveModel::AttributeRegistration::ClassMethods::PendingDefault < ::Struct + # source://activemodel//lib/active_model/attribute_registration.rb#62 + def apply_to(attribute_set); end + + # Returns the value of attribute default + # + # @return [Object] the current value of default + def default; end + + # Sets the attribute default + # + # @param value [Object] the value to set the attribute default to. + # @return [Object] the newly set value + def default=(_); end + + # Returns the value of attribute name + # + # @return [Object] the current value of name + def name; end + + # Sets the attribute name + # + # @param value [Object] the value to set the attribute name to. + # @return [Object] the newly set value + def name=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://activemodel//lib/active_model/attribute_registration.rb#54 +class ActiveModel::AttributeRegistration::ClassMethods::PendingType < ::Struct + # source://activemodel//lib/active_model/attribute_registration.rb#55 + def apply_to(attribute_set); end + + # Returns the value of attribute name + # + # @return [Object] the current value of name + def name; end + + # Sets the attribute name + # + # @param value [Object] the value to set the attribute name to. + # @return [Object] the newly set value + def name=(_); end + + # Returns the value of attribute type + # + # @return [Object] the current value of type + def type; end + + # Sets the attribute type + # + # @param value [Object] the value to set the attribute type to. + # @return [Object] the newly set value + def type=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + # source://activemodel//lib/active_model/attribute_set/builder.rb#6 class ActiveModel::AttributeSet # @return [AttributeSet] a new instance of AttributeSet @@ -1034,7 +1254,7 @@ class ActiveModel::AttributeSet # source://activemodel//lib/active_model/attribute_set.rb#12 def initialize(attributes); end - # source://activemodel//lib/active_model/attribute_set.rb#97 + # source://activemodel//lib/active_model/attribute_set.rb#106 def ==(other); end # source://activemodel//lib/active_model/attribute_set.rb#16 @@ -1043,10 +1263,13 @@ class ActiveModel::AttributeSet # source://activemodel//lib/active_model/attribute_set.rb#20 def []=(name, value); end - # source://activemodel//lib/active_model/attribute_set.rb#88 + # source://activemodel//lib/active_model/attribute_set.rb#93 def accessed; end - # source://activemodel//lib/active_model/attribute_set.rb#68 + # source://activemodel//lib/active_model/attribute_set.rb#24 + def cast_types; end + + # source://activemodel//lib/active_model/attribute_set.rb#73 def deep_dup; end # source://activemodel//lib/active_model/attribute_set.rb#10 @@ -1058,65 +1281,73 @@ class ActiveModel::AttributeSet # source://activemodel//lib/active_model/attribute_set.rb#10 def fetch(*_arg0, **_arg1, &_arg2); end - # source://activemodel//lib/active_model/attribute_set.rb#45 + # source://activemodel//lib/active_model/attribute_set.rb#50 def fetch_value(name, &block); end - # source://activemodel//lib/active_model/attribute_set.rb#63 + # source://activemodel//lib/active_model/attribute_set.rb#68 def freeze; end # @return [Boolean] # - # source://activemodel//lib/active_model/attribute_set.rb#37 - def key?(name); end + # source://activemodel//lib/active_model/attribute_set.rb#41 + def include?(name); end + # @return [Boolean] + # # source://activemodel//lib/active_model/attribute_set.rb#41 + def key?(name); end + + # source://activemodel//lib/active_model/attribute_set.rb#46 def keys; end - # source://activemodel//lib/active_model/attribute_set.rb#92 + # source://activemodel//lib/active_model/attribute_set.rb#97 def map(&block); end - # source://activemodel//lib/active_model/attribute_set.rb#82 + # source://activemodel//lib/active_model/attribute_set.rb#87 def reset(key); end - # source://activemodel//lib/active_model/attribute_set.rb#32 + # source://activemodel//lib/active_model/attribute_set.rb#102 + def reverse_merge!(target_attributes); end + + # source://activemodel//lib/active_model/attribute_set.rb#36 def to_h; end - # source://activemodel//lib/active_model/attribute_set.rb#32 + # source://activemodel//lib/active_model/attribute_set.rb#36 def to_hash; end - # source://activemodel//lib/active_model/attribute_set.rb#24 + # source://activemodel//lib/active_model/attribute_set.rb#28 def values_before_type_cast; end - # source://activemodel//lib/active_model/attribute_set.rb#28 + # source://activemodel//lib/active_model/attribute_set.rb#32 def values_for_database; end - # source://activemodel//lib/active_model/attribute_set.rb#59 + # source://activemodel//lib/active_model/attribute_set.rb#64 def write_cast_value(name, value); end - # source://activemodel//lib/active_model/attribute_set.rb#49 + # source://activemodel//lib/active_model/attribute_set.rb#54 def write_from_database(name, value); end # @raise [FrozenError] # - # source://activemodel//lib/active_model/attribute_set.rb#53 + # source://activemodel//lib/active_model/attribute_set.rb#58 def write_from_user(name, value); end protected # Returns the value of attribute attributes. # - # source://activemodel//lib/active_model/attribute_set.rb#102 + # source://activemodel//lib/active_model/attribute_set.rb#111 def attributes; end private - # source://activemodel//lib/active_model/attribute_set.rb#105 + # source://activemodel//lib/active_model/attribute_set.rb#114 def default_attribute(name); end - # source://activemodel//lib/active_model/attribute_set.rb#77 + # source://activemodel//lib/active_model/attribute_set.rb#82 def initialize_clone(_); end - # source://activemodel//lib/active_model/attribute_set.rb#72 + # source://activemodel//lib/active_model/attribute_set.rb#77 def initialize_dup(_); end end @@ -1165,20 +1396,49 @@ class ActiveModel::AttributeSet::YAMLEncoder def default_types; end end -# source://activemodel//lib/active_model/attributes.rb#7 +# = Active \Model \Attributes +# +# The Attributes module allows models to define attributes beyond simple Ruby +# readers and writers. Similar to Active Record attributes, which are +# typically inferred from the database schema, Active Model Attributes are +# aware of data types, can have default values, and can handle casting and +# serialization. +# +# To use Attributes, include the module in your model class and define your +# attributes using the +attribute+ macro. It accepts a name, a type, a default +# value, and any other options supported by the attribute type. +# +# ==== Examples +# +# class Person +# include ActiveModel::Attributes +# +# attribute :name, :string +# attribute :active, :boolean, default: true +# end +# +# person = Person.new +# person.name = "Volmer" +# +# person.name # => "Volmer" +# person.active # => true +# +# source://activemodel//lib/active_model/attributes.rb#30 module ActiveModel::Attributes extend ::ActiveSupport::Concern include GeneratedInstanceMethods + include ::ActiveModel::AttributeRegistration include ::ActiveModel::AttributeMethods mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActiveModel::AttributeRegistration::ClassMethods mixes_in_class_methods ::ActiveModel::AttributeMethods::ClassMethods mixes_in_class_methods ::ActiveModel::Attributes::ClassMethods - # source://activemodel//lib/active_model/attributes.rb#78 + # source://activemodel//lib/active_model/attributes.rb#106 def initialize(*_arg0); end - # Returns an array of attribute names as strings + # Returns an array of attribute names as strings. # # class Person # include ActiveModel::Attributes @@ -1188,13 +1448,13 @@ module ActiveModel::Attributes # end # # person = Person.new - # person.attribute_names - # # => ["name", "age"] + # person.attribute_names # => ["name", "age"] # - # source://activemodel//lib/active_model/attributes.rb#116 + # source://activemodel//lib/active_model/attributes.rb#146 def attribute_names; end - # Returns a hash of all the attributes with their names as keys and the values of the attributes as values. + # Returns a hash of all the attributes with their names as keys and the + # values of the attributes as values. # # class Person # include ActiveModel::Attributes @@ -1203,59 +1463,74 @@ module ActiveModel::Attributes # attribute :age, :integer # end # - # person = Person.new(name: 'Francesco', age: 22) - # person.attributes - # # => {"name"=>"Francesco", "age"=>22} + # person = Person.new + # person.name = "Francesco" + # person.age = 22 + # + # person.attributes # => { "name" => "Francesco", "age" => 22} # - # source://activemodel//lib/active_model/attributes.rb#100 + # source://activemodel//lib/active_model/attributes.rb#131 def attributes; end - # source://activemodel//lib/active_model/attributes.rb#120 + # source://activemodel//lib/active_model/attributes.rb#150 def freeze; end private - # source://activemodel//lib/active_model/attributes.rb#126 + # source://activemodel//lib/active_model/attributes.rb#156 def _write_attribute(attr_name, value); end - # source://activemodel//lib/active_model/attributes.rb#131 + # source://activemodel//lib/active_model/attributes.rb#161 def attribute(attr_name); end - # source://activemodel//lib/active_model/attributes.rb#126 + # source://activemodel//lib/active_model/attributes.rb#156 def attribute=(attr_name, value); end - # source://activemodel//lib/active_model/attributes.rb#83 + # source://activemodel//lib/active_model/attributes.rb#111 def initialize_dup(other); end module GeneratedClassMethods - def _default_attributes; end - def _default_attributes=(value); end - def _default_attributes?; end def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end - def attribute_types; end - def attribute_types=(value); end - def attribute_types?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end end module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end end end -# source://activemodel//lib/active_model/attributes.rb#18 +# source://activemodel//lib/active_model/attributes.rb#39 module ActiveModel::Attributes::ClassMethods - # source://activemodel//lib/active_model/attributes.rb#19 - def attribute(name, cast_type = T.unsafe(nil), default: T.unsafe(nil), **options); end + # :call-seq: attribute(name, cast_type = nil, default: nil, **options) + # + # Defines a model attribute. In addition to the attribute name, a cast + # type and default value may be specified, as well as any options + # supported by the given cast type. + # + # class Person + # include ActiveModel::Attributes + # + # attribute :name, :string + # attribute :active, :boolean, default: true + # end + # + # person = Person.new + # person.name = "Volmer" + # + # person.name # => "Volmer" + # person.active # => true + # + # source://activemodel//lib/active_model/attributes.rb#59 + def attribute(name, *_arg1, **_arg2, &_arg3); end - # Returns an array of attribute names as strings + # Returns an array of attribute names as strings. # # class Person # include ActiveModel::Attributes @@ -1264,48 +1539,41 @@ module ActiveModel::Attributes::ClassMethods # attribute :age, :integer # end # - # Person.attribute_names - # # => ["name", "age"] + # Person.attribute_names # => ["name", "age"] # - # source://activemodel//lib/active_model/attributes.rb#41 + # source://activemodel//lib/active_model/attributes.rb#74 def attribute_names; end private - # source://activemodel//lib/active_model/attributes.rb#62 - def define_default_attribute(name, value, type); end - - # source://activemodel//lib/active_model/attributes.rb#46 - def define_method_attribute=(name, owner:); end + # source://activemodel//lib/active_model/attributes.rb#92 + def define_method_attribute=(canonical_name, owner:, as: T.unsafe(nil)); end end -# source://activemodel//lib/active_model/attributes.rb#59 -ActiveModel::Attributes::ClassMethods::NO_DEFAULT_PROVIDED = T.let(T.unsafe(nil), Object) - # +BlockValidator+ is a special +EachValidator+ which receives a block on initialization # and call this block for each attribute being validated. +validates_each+ uses this validator. # -# source://activemodel//lib/active_model/validator.rb#177 +# source://activemodel//lib/active_model/validator.rb#179 class ActiveModel::BlockValidator < ::ActiveModel::EachValidator # @return [BlockValidator] a new instance of BlockValidator # - # source://activemodel//lib/active_model/validator.rb#178 + # source://activemodel//lib/active_model/validator.rb#180 def initialize(options, &block); end private - # source://activemodel//lib/active_model/validator.rb#184 + # source://activemodel//lib/active_model/validator.rb#186 def validate_each(record, attribute, value); end end -# == Active \Model \Callbacks +# = Active \Model \Callbacks # # Provides an interface for any class to have Active Record like callbacks. # # Like the Active Record methods, the callback chain is aborted as soon as # one of the methods throws +:abort+. # -# First, extend ActiveModel::Callbacks from the class you are creating: +# First, extend +ActiveModel::Callbacks+ from the class you are creating: # # class MyModel # extend ActiveModel::Callbacks @@ -1354,11 +1622,11 @@ end # Would only create the +after_create+ and +before_create+ callback methods in # your class. # -# NOTE: Calling the same callback multiple times will overwrite previous callback definitions. +# NOTE: Defining the same callback multiple times will overwrite previous callback definitions. # # source://activemodel//lib/active_model/callbacks.rb#65 module ActiveModel::Callbacks - # define_model_callbacks accepts the same options +define_callbacks+ does, + # +define_model_callbacks+ accepts the same options +define_callbacks+ does, # in case you want to overwrite a default. Besides that, it also accepts an # :only option, where you can choose if you want all types (before, # around or after) or just some. @@ -1366,7 +1634,7 @@ module ActiveModel::Callbacks # define_model_callbacks :initialize, only: :after # # Note, the only: hash will apply to all callbacks defined - # on that method call. To get around this you can call the define_model_callbacks + # on that method call. To get around this you can call the +define_model_callbacks+ # method as many times as you need. # # define_model_callbacks :create, only: :after @@ -1393,7 +1661,7 @@ module ActiveModel::Callbacks # end # end # - # NOTE: +method_name+ passed to define_model_callbacks must not end with + # NOTE: +method_name+ passed to +define_model_callbacks+ must not end with # !, ? or =. # # source://activemodel//lib/active_model/callbacks.rb#109 @@ -1416,7 +1684,7 @@ module ActiveModel::Callbacks end end -# == Active \Model \Conversion +# = Active \Model \Conversion # # Handles default conversions: to_model, to_key, to_param, and to_partial_path. # @@ -1440,7 +1708,9 @@ end # source://activemodel//lib/active_model/conversion.rb#24 module ActiveModel::Conversion extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveModel::Conversion::ClassMethods # Returns an Array of all key attributes if any of the attributes is set, whether or not @@ -1458,7 +1728,7 @@ module ActiveModel::Conversion # person = Person.new(1) # person.to_key # => [1] # - # source://activemodel//lib/active_model/conversion.rb#59 + # source://activemodel//lib/active_model/conversion.rb#67 def to_key; end # If your object is already designed to implement all of the \Active \Model @@ -1476,7 +1746,7 @@ module ActiveModel::Conversion # define :to_model yourself returning a proxy object that wraps # your object with \Active \Model compliant methods. # - # source://activemodel//lib/active_model/conversion.rb#41 + # source://activemodel//lib/active_model/conversion.rb#49 def to_model; end # Returns a +string+ representing the object's key suitable for use in URLs, @@ -1498,7 +1768,7 @@ module ActiveModel::Conversion # person = Person.new(1) # person.to_param # => "1" # - # source://activemodel//lib/active_model/conversion.rb#82 + # source://activemodel//lib/active_model/conversion.rb#90 def to_param; end # Returns a +string+ identifying the path associated with the object. @@ -1511,20 +1781,30 @@ module ActiveModel::Conversion # person = Person.new # person.to_partial_path # => "people/person" # - # source://activemodel//lib/active_model/conversion.rb#95 + # source://activemodel//lib/active_model/conversion.rb#103 def to_partial_path; end + + module GeneratedClassMethods + def param_delimiter; end + def param_delimiter=(value); end + def param_delimiter?; end + end + + module GeneratedInstanceMethods + def param_delimiter=(value); end + end end -# source://activemodel//lib/active_model/conversion.rb#99 +# source://activemodel//lib/active_model/conversion.rb#107 module ActiveModel::Conversion::ClassMethods # Provide a class level cache for #to_partial_path. This is an # internal method and should not be accessed directly. # - # source://activemodel//lib/active_model/conversion.rb#102 + # source://activemodel//lib/active_model/conversion.rb#110 def _to_partial_path; end end -# == Active \Model \Dirty +# = Active \Model \Dirty # # Provides a way to track changes in your object in the same way as # Active Record does. @@ -1534,8 +1814,7 @@ end # * include ActiveModel::Dirty in your object. # * Call define_attribute_methods passing each method you want to # track. -# * Call [attr_name]_will_change! before each change to the tracked -# attribute. +# * Call *_will_change! before each change to the tracked attribute. # * Call changes_applied after the changes are persisted. # * Call clear_changes_information when you want to reset the changes # information. @@ -1630,17 +1909,20 @@ end # person.changes # => {"name" => ["Bill", "Bob"]} # # If an attribute is modified in-place then make use of -# [attribute_name]_will_change! to mark that the attribute is changing. +# {*_will_change!}[rdoc-label:method-i-2A_will_change-21] to mark that the attribute is changing. # Otherwise \Active \Model can't track changes to in-place attributes. Note # that Active Record can detect in-place modifications automatically. You do -# not need to call [attribute_name]_will_change! on Active Record models. +# not need to call *_will_change! on Active Record models. # # person.name_will_change! # person.name_change # => ["Bill", "Bill"] # person.name << 'y' # person.name_change # => ["Bill", "Billy"] # -# source://activemodel//lib/active_model/dirty.rb#121 +# Methods can be invoked as +name_changed?+ or by passing an argument to the +# generic method attribute_changed?("name"). +# +# source://activemodel//lib/active_model/dirty.rb#123 module ActiveModel::Dirty extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -1649,36 +1931,36 @@ module ActiveModel::Dirty mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveModel::AttributeMethods::ClassMethods - # source://activemodel//lib/active_model/dirty.rb#143 + # source://activemodel//lib/active_model/dirty.rb#258 def as_json(options = T.unsafe(nil)); end - # Dispatch target for *_changed? attribute methods. + # Dispatch target for {*_changed?}[rdoc-label:method-i-2A_changed-3F] attribute methods. # # @return [Boolean] # - # source://activemodel//lib/active_model/dirty.rb#178 + # source://activemodel//lib/active_model/dirty.rb#293 def attribute_changed?(attr_name, **options); end # @return [Boolean] # - # source://activemodel//lib/active_model/dirty.rb#245 + # source://activemodel//lib/active_model/dirty.rb#360 def attribute_changed_in_place?(attr_name); end - # Dispatch target for *_previously_changed? attribute methods. + # Dispatch target for {*_previously_changed?}[rdoc-label:method-i-2A_previously_changed-3F] attribute methods. # # @return [Boolean] # - # source://activemodel//lib/active_model/dirty.rb#188 + # source://activemodel//lib/active_model/dirty.rb#303 def attribute_previously_changed?(attr_name, **options); end - # Dispatch target for *_previously_was attribute methods. + # Dispatch target for {*_previously_was}[rdoc-label:method-i-2A_previously_was] attribute methods. # - # source://activemodel//lib/active_model/dirty.rb#193 + # source://activemodel//lib/active_model/dirty.rb#308 def attribute_previously_was(attr_name); end - # Dispatch target for *_was attribute methods. + # Dispatch target for {*_was}[rdoc-label:method-i-2A_was] attribute methods. # - # source://activemodel//lib/active_model/dirty.rb#183 + # source://activemodel//lib/active_model/dirty.rb#298 def attribute_was(attr_name); end # Returns an array with the name of the attributes with unsaved changes. @@ -1687,7 +1969,7 @@ module ActiveModel::Dirty # person.name = 'bob' # person.changed # => ["name"] # - # source://activemodel//lib/active_model/dirty.rb#173 + # source://activemodel//lib/active_model/dirty.rb#288 def changed; end # Returns +true+ if any of the attributes has unsaved changes, +false+ otherwise. @@ -1698,7 +1980,7 @@ module ActiveModel::Dirty # # @return [Boolean] # - # source://activemodel//lib/active_model/dirty.rb#164 + # source://activemodel//lib/active_model/dirty.rb#279 def changed?; end # Returns a hash of the attributes with unsaved changes indicating their original @@ -1708,7 +1990,7 @@ module ActiveModel::Dirty # person.name = 'robert' # person.changed_attributes # => {"name" => "bob"} # - # source://activemodel//lib/active_model/dirty.rb#221 + # source://activemodel//lib/active_model/dirty.rb#336 def changed_attributes; end # Returns a hash of changed attributes indicating their original @@ -1718,21 +2000,21 @@ module ActiveModel::Dirty # person.name = 'bob' # person.changes # => { "name" => ["bill", "bob"] } # - # source://activemodel//lib/active_model/dirty.rb#231 + # source://activemodel//lib/active_model/dirty.rb#346 def changes; end # Clears dirty data and moves +changes+ to +previous_changes+ and # +mutations_from_database+ to +mutations_before_last_save+ respectively. # - # source://activemodel//lib/active_model/dirty.rb#150 + # source://activemodel//lib/active_model/dirty.rb#265 def changes_applied; end - # source://activemodel//lib/active_model/dirty.rb#209 + # source://activemodel//lib/active_model/dirty.rb#324 def clear_attribute_changes(attr_names); end # Clears all dirty data: current changes and previous changes. # - # source://activemodel//lib/active_model/dirty.rb#203 + # source://activemodel//lib/active_model/dirty.rb#318 def clear_changes_information; end # Returns a hash of attributes that were changed before the model was saved. @@ -1742,75 +2024,80 @@ module ActiveModel::Dirty # person.save # person.previous_changes # => {"name" => ["bob", "robert"]} # - # source://activemodel//lib/active_model/dirty.rb#241 + # source://activemodel//lib/active_model/dirty.rb#356 def previous_changes; end # Restore all previous data of the provided attributes. # - # source://activemodel//lib/active_model/dirty.rb#198 + # source://activemodel//lib/active_model/dirty.rb#313 def restore_attributes(attr_names = T.unsafe(nil)); end private # Dispatch target for *_change attribute methods. # - # source://activemodel//lib/active_model/dirty.rb#271 + # source://activemodel//lib/active_model/dirty.rb#392 def attribute_change(attr_name); end # Dispatch target for *_previous_change attribute methods. # - # source://activemodel//lib/active_model/dirty.rb#276 + # source://activemodel//lib/active_model/dirty.rb#397 def attribute_previous_change(attr_name); end # Dispatch target for *_will_change! attribute methods. # - # source://activemodel//lib/active_model/dirty.rb#281 + # source://activemodel//lib/active_model/dirty.rb#402 def attribute_will_change!(attr_name); end - # source://activemodel//lib/active_model/dirty.rb#250 + # source://activemodel//lib/active_model/dirty.rb#371 def clear_attribute_change(attr_name); end - # source://activemodel//lib/active_model/dirty.rb#262 + # source://activemodel//lib/active_model/dirty.rb#383 def forget_attribute_assignments; end - # source://activemodel//lib/active_model/dirty.rb#133 + # source://activemodel//lib/active_model/dirty.rb#365 + def init_internals; end + + # source://activemodel//lib/active_model/dirty.rb#248 def initialize_dup(other); end - # source://activemodel//lib/active_model/dirty.rb#266 + # source://activemodel//lib/active_model/dirty.rb#387 def mutations_before_last_save; end - # source://activemodel//lib/active_model/dirty.rb#254 + # source://activemodel//lib/active_model/dirty.rb#375 def mutations_from_database; end # Dispatch target for restore_*! attribute methods. # - # source://activemodel//lib/active_model/dirty.rb#286 + # source://activemodel//lib/active_model/dirty.rb#407 def restore_attribute!(attr_name); end module GeneratedClassMethods def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end end module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end end end +# = Active \Model \EachValidator +# # +EachValidator+ is a validator which iterates through the attributes given # in the options hash invoking the validate_each method passing in the # record, attribute, and value. # # All \Active \Model validations are built on top of this validator. # -# source://activemodel//lib/active_model/validator.rb#132 +# source://activemodel//lib/active_model/validator.rb#134 class ActiveModel::EachValidator < ::ActiveModel::Validator # Returns a new validator instance. All options will be available via the # +options+ reader, however the :attributes option will be removed @@ -1819,26 +2106,26 @@ class ActiveModel::EachValidator < ::ActiveModel::Validator # @raise [ArgumentError] # @return [EachValidator] a new instance of EachValidator # - # source://activemodel//lib/active_model/validator.rb#138 + # source://activemodel//lib/active_model/validator.rb#140 def initialize(options); end # Returns the value of attribute attributes. # - # source://activemodel//lib/active_model/validator.rb#133 + # source://activemodel//lib/active_model/validator.rb#135 def attributes; end # Hook method that gets called by the initializer allowing verification # that the arguments supplied are valid. You could for example raise an # +ArgumentError+ when invalid options are supplied. # - # source://activemodel//lib/active_model/validator.rb#166 + # source://activemodel//lib/active_model/validator.rb#168 def check_validity!; end # Performs validation on the supplied record. By default this will call # +validate_each+ to determine validity therefore subclasses should # override +validate_each+ with validation logic. # - # source://activemodel//lib/active_model/validator.rb#148 + # source://activemodel//lib/active_model/validator.rb#150 def validate(record); end # Override this method in subclasses with the validation logic, adding @@ -1846,16 +2133,16 @@ class ActiveModel::EachValidator < ::ActiveModel::Validator # # @raise [NotImplementedError] # - # source://activemodel//lib/active_model/validator.rb#159 + # source://activemodel//lib/active_model/validator.rb#161 def validate_each(record, attribute, value); end private - # source://activemodel//lib/active_model/validator.rb#170 + # source://activemodel//lib/active_model/validator.rb#172 def prepare_value_for_validation(value, record, attr_name); end end -# == Active \Model \Error +# = Active \Model \Error # # Represents one single error # @@ -1866,7 +2153,7 @@ class ActiveModel::Error # source://activemodel//lib/active_model/error.rb#103 def initialize(base, attribute, type = T.unsafe(nil), **options); end - # source://activemodel//lib/active_model/error.rb#189 + # source://activemodel//lib/active_model/error.rb#190 def ==(other); end # The attribute of +base+ which the error belongs to @@ -1885,7 +2172,7 @@ class ActiveModel::Error # error.details # # => { error: :too_short, count: 5 } # - # source://activemodel//lib/active_model/error.rb#148 + # source://activemodel//lib/active_model/error.rb#149 def detail; end # Returns the error details. @@ -1894,10 +2181,10 @@ class ActiveModel::Error # error.details # # => { error: :too_short, count: 5 } # - # source://activemodel//lib/active_model/error.rb#148 + # source://activemodel//lib/active_model/error.rb#149 def details; end - # source://activemodel//lib/active_model/error.rb#189 + # source://activemodel//lib/active_model/error.rb#190 def eql?(other); end # Returns the full error message. @@ -1906,10 +2193,10 @@ class ActiveModel::Error # error.full_message # # => "Name is too short (minimum is 5 characters)" # - # source://activemodel//lib/active_model/error.rb#158 + # source://activemodel//lib/active_model/error.rb#159 def full_message; end - # source://activemodel//lib/active_model/error.rb#194 + # source://activemodel//lib/active_model/error.rb#195 def hash; end # source://activemodel//lib/active_model/error.rb#13 @@ -1921,7 +2208,7 @@ class ActiveModel::Error # source://activemodel//lib/active_model/error.rb#13 def i18n_customize_full_message?; end - # source://activemodel//lib/active_model/error.rb#198 + # source://activemodel//lib/active_model/error.rb#199 def inspect; end # See if error matches provided +attribute+, +type+, and +options+. @@ -1930,7 +2217,7 @@ class ActiveModel::Error # # @return [Boolean] # - # source://activemodel//lib/active_model/error.rb#165 + # source://activemodel//lib/active_model/error.rb#166 def match?(attribute, type = T.unsafe(nil), **options); end # Returns the error message. @@ -1939,17 +2226,18 @@ class ActiveModel::Error # error.message # # => "is too short (minimum is 5 characters)" # - # source://activemodel//lib/active_model/error.rb#134 + # source://activemodel//lib/active_model/error.rb#135 def message; end - # The options provided when calling +errors#add+ + # The options provided when calling errors#add # - # source://activemodel//lib/active_model/error.rb#127 + # source://activemodel//lib/active_model/error.rb#128 def options; end - # The raw value provided as the second parameter when calling +errors#add+ + # The raw value provided as the second parameter when calling + # errors#add # - # source://activemodel//lib/active_model/error.rb#125 + # source://activemodel//lib/active_model/error.rb#126 def raw_type; end # See if error matches provided +attribute+, +type+, and +options+ exactly. @@ -1959,7 +2247,7 @@ class ActiveModel::Error # # @return [Boolean] # - # source://activemodel//lib/active_model/error.rb#183 + # source://activemodel//lib/active_model/error.rb#184 def strict_match?(attribute, type, **options); end # The type of error, defaults to +:invalid+ unless specified @@ -1969,7 +2257,7 @@ class ActiveModel::Error protected - # source://activemodel//lib/active_model/error.rb#203 + # source://activemodel//lib/active_model/error.rb#204 def attributes_for_hash; end private @@ -2001,7 +2289,7 @@ ActiveModel::Error::CALLBACKS_OPTIONS = T.let(T.unsafe(nil), Array) # source://activemodel//lib/active_model/error.rb#11 ActiveModel::Error::MESSAGE_OPTIONS = T.let(T.unsafe(nil), Array) -# == Active \Model \Errors +# = Active \Model \Errors # # Provides error related functionalities you can include in your object # for handling error messages and interacting with Action View helpers. @@ -2052,7 +2340,7 @@ ActiveModel::Error::MESSAGE_OPTIONS = T.let(T.unsafe(nil), Array) # person.errors.full_messages # => ["name cannot be nil"] # # etc.. # -# source://activemodel//lib/active_model/errors.rb#62 +# source://activemodel//lib/active_model/errors.rb#61 class ActiveModel::Errors include ::Enumerable extend ::Forwardable @@ -2067,7 +2355,7 @@ class ActiveModel::Errors # # @return [Errors] a new instance of Errors # - # source://activemodel//lib/active_model/errors.rb#92 + # source://activemodel//lib/active_model/errors.rb#117 def initialize(base); end # When passed a symbol or a name of a method, returns an array of errors @@ -2076,7 +2364,7 @@ class ActiveModel::Errors # person.errors[:name] # => ["cannot be nil"] # person.errors['name'] # => ["cannot be nil"] # - # source://activemodel//lib/active_model/errors.rb#204 + # source://activemodel//lib/active_model/errors.rb#229 def [](attribute); end # Adds a new error of +type+ on +attribute+. @@ -2101,7 +2389,7 @@ class ActiveModel::Errors # person.errors.messages # # => {:name=>["can't be blank"]} # - # person.errors.add(:name, :too_long, { count: 25 }) + # person.errors.add(:name, :too_long, count: 25) # person.errors.messages # # => ["is too long (maximum is 25 characters)"] # @@ -2129,7 +2417,7 @@ class ActiveModel::Errors # person.errors.details # # => {:base=>[{error: :name_or_email_blank}]} # - # source://activemodel//lib/active_model/errors.rb#317 + # source://activemodel//lib/active_model/errors.rb#342 def add(attribute, type = T.unsafe(nil), **options); end # Returns +true+ if an error matches provided +attribute+ and +type+, @@ -2142,7 +2430,7 @@ class ActiveModel::Errors # If the error requires options, then it returns +true+ with # the correct options, or +false+ with incorrect or missing options. # - # person.errors.add :name, :too_long, { count: 25 } + # person.errors.add :name, :too_long, count: 25 # person.errors.added? :name, :too_long, count: 25 # => true # person.errors.added? :name, "is too long (maximum is 25 characters)" # => true # person.errors.added? :name, :too_long, count: 24 # => false @@ -2151,17 +2439,17 @@ class ActiveModel::Errors # # @return [Boolean] # - # source://activemodel//lib/active_model/errors.rb#347 + # source://activemodel//lib/active_model/errors.rb#372 def added?(attribute, type = T.unsafe(nil), options = T.unsafe(nil)); end # Returns a Hash that can be used as the JSON representation for this # object. You can pass the :full_messages option. This determines - # if the json object should contain full messages or not (false by default). + # if the JSON object should contain full messages or not (false by default). # # person.errors.as_json # => {:name=>["cannot be nil"]} # person.errors.as_json(full_messages: true) # => {:name=>["name cannot be nil"]} # - # source://activemodel//lib/active_model/errors.rb#222 + # source://activemodel//lib/active_model/errors.rb#247 def as_json(options = T.unsafe(nil)); end # Returns all error attribute names @@ -2169,7 +2457,7 @@ class ActiveModel::Errors # person.errors.messages # => {:name=>["cannot be nil", "must be specified"]} # person.errors.attribute_names # => [:name] # - # source://activemodel//lib/active_model/errors.rb#212 + # source://activemodel//lib/active_model/errors.rb#237 def attribute_names; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2186,7 +2474,7 @@ class ActiveModel::Errors # # person.errors.copy!(other) # - # source://activemodel//lib/active_model/errors.rb#113 + # source://activemodel//lib/active_model/errors.rb#138 def copy!(other); end # Delete messages for +key+. Returns the deleted messages. @@ -2195,12 +2483,12 @@ class ActiveModel::Errors # person.errors.delete(:name) # => ["cannot be nil"] # person.errors[:name] # => [] # - # source://activemodel//lib/active_model/errors.rb#190 + # source://activemodel//lib/active_model/errors.rb#215 def delete(attribute, type = T.unsafe(nil), **options); end # Returns a Hash of attributes with an array of their error details. # - # source://activemodel//lib/active_model/errors.rb#251 + # source://activemodel//lib/active_model/errors.rb#276 def details; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2212,14 +2500,14 @@ class ActiveModel::Errors # The actual array of +Error+ objects # This method is aliased to objects. # - # source://activemodel//lib/active_model/errors.rb#82 + # source://activemodel//lib/active_model/errors.rb#107 def errors; end # Returns a full message for a given attribute. # # person.errors.full_message(:name, 'is invalid') # => "Name is invalid" # - # source://activemodel//lib/active_model/errors.rb#426 + # source://activemodel//lib/active_model/errors.rb#451 def full_message(attribute, message); end # Returns all the full error messages in an array. @@ -2233,7 +2521,7 @@ class ActiveModel::Errors # person.errors.full_messages # # => ["Name is too short (minimum is 5 characters)", "Name can't be blank", "Email can't be blank"] # - # source://activemodel//lib/active_model/errors.rb#390 + # source://activemodel//lib/active_model/errors.rb#415 def full_messages; end # Returns all the full error messages for a given attribute in an array. @@ -2247,7 +2535,7 @@ class ActiveModel::Errors # person.errors.full_messages_for(:name) # # => ["Name is too short (minimum is 5 characters)", "Name can't be blank"] # - # source://activemodel//lib/active_model/errors.rb#405 + # source://activemodel//lib/active_model/errors.rb#430 def full_messages_for(attribute); end # Translates an error message in its default scope @@ -2275,7 +2563,7 @@ class ActiveModel::Errors # * errors.attributes.title.blank # * errors.messages.blank # - # source://activemodel//lib/active_model/errors.rb#454 + # source://activemodel//lib/active_model/errors.rb#479 def generate_message(attribute, type = T.unsafe(nil), options = T.unsafe(nil)); end # Returns a Hash of attributes with an array of their Error objects. @@ -2283,7 +2571,7 @@ class ActiveModel::Errors # person.errors.group_by_attribute # # => {:name=>[<#ActiveModel::Error>, <#ActiveModel::Error>]} # - # source://activemodel//lib/active_model/errors.rb#264 + # source://activemodel//lib/active_model/errors.rb#289 def group_by_attribute; end # Returns +true+ if the error messages include an error for the given key @@ -2295,7 +2583,7 @@ class ActiveModel::Errors # # @return [Boolean] # - # source://activemodel//lib/active_model/errors.rb#177 + # source://activemodel//lib/active_model/errors.rb#202 def has_key?(attribute); end # Imports one error. @@ -2308,7 +2596,7 @@ class ActiveModel::Errors # * +:attribute+ - Override the attribute the error belongs to. # * +:type+ - Override type of the error. # - # source://activemodel//lib/active_model/errors.rb#129 + # source://activemodel//lib/active_model/errors.rb#154 def import(error, override_options = T.unsafe(nil)); end # Returns +true+ if the error messages include an error for the given key @@ -2320,10 +2608,10 @@ class ActiveModel::Errors # # @return [Boolean] # - # source://activemodel//lib/active_model/errors.rb#177 + # source://activemodel//lib/active_model/errors.rb#202 def include?(attribute); end - # source://activemodel//lib/active_model/errors.rb#458 + # source://activemodel//lib/active_model/errors.rb#483 def inspect; end # Returns +true+ if the error messages include an error for the given key @@ -2335,7 +2623,7 @@ class ActiveModel::Errors # # @return [Boolean] # - # source://activemodel//lib/active_model/errors.rb#177 + # source://activemodel//lib/active_model/errors.rb#202 def key?(attribute); end # Merges the errors from other, @@ -2349,12 +2637,12 @@ class ActiveModel::Errors # # person.errors.merge!(other) # - # source://activemodel//lib/active_model/errors.rb#149 + # source://activemodel//lib/active_model/errors.rb#174 def merge!(other); end # Returns a Hash of attributes with an array of their error messages. # - # source://activemodel//lib/active_model/errors.rb#243 + # source://activemodel//lib/active_model/errors.rb#268 def messages; end # Returns all the error messages for a given attribute in an array. @@ -2368,20 +2656,20 @@ class ActiveModel::Errors # person.errors.messages_for(:name) # # => ["is too short (minimum is 5 characters)", "can't be blank"] # - # source://activemodel//lib/active_model/errors.rb#419 + # source://activemodel//lib/active_model/errors.rb#444 def messages_for(attribute); end # The actual array of +Error+ objects # This method is aliased to objects. # - # source://activemodel//lib/active_model/errors.rb#82 + # source://activemodel//lib/active_model/errors.rb#107 def objects; end # Returns +true+ if an error on the attribute with the given type is # present, or +false+ otherwise. +type+ is treated the same as for +add+. # # person.errors.add :age - # person.errors.add :name, :too_long, { count: 25 } + # person.errors.add :name, :too_long, count: 25 # person.errors.of_kind? :age # => true # person.errors.of_kind? :name # => false # person.errors.of_kind? :name, :too_long # => true @@ -2391,7 +2679,7 @@ class ActiveModel::Errors # # @return [Boolean] # - # source://activemodel//lib/active_model/errors.rb#370 + # source://activemodel//lib/active_model/errors.rb#395 def of_kind?(attribute, type = T.unsafe(nil)); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2408,7 +2696,7 @@ class ActiveModel::Errors # person.errors.full_messages # # => ["Name is too short (minimum is 5 characters)", "Name can't be blank", "Email can't be blank"] # - # source://activemodel//lib/active_model/errors.rb#390 + # source://activemodel//lib/active_model/errors.rb#415 def to_a; end # Returns a Hash of attributes with their error messages. If +full_messages+ @@ -2417,7 +2705,7 @@ class ActiveModel::Errors # person.errors.to_hash # => {:name=>["cannot be nil"]} # person.errors.to_hash(true) # => {:name=>["name cannot be nil"]} # - # source://activemodel//lib/active_model/errors.rb#231 + # source://activemodel//lib/active_model/errors.rb#256 def to_hash(full_messages = T.unsafe(nil)); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2431,21 +2719,23 @@ class ActiveModel::Errors # person.errors.where(:name, :too_short) # => all name errors being too short # person.errors.where(:name, :too_short, minimum: 2) # => all name errors being too short and minimum is 2 # - # source://activemodel//lib/active_model/errors.rb#164 + # source://activemodel//lib/active_model/errors.rb#189 def where(attribute, type = T.unsafe(nil), **options); end private - # source://activemodel//lib/active_model/errors.rb#97 + # source://activemodel//lib/active_model/errors.rb#122 def initialize_dup(other); end - # source://activemodel//lib/active_model/errors.rb#465 + # source://activemodel//lib/active_model/errors.rb#490 def normalize_arguments(attribute, type, **options); end end -# source://activemodel//lib/active_model/errors.rb#240 +# source://activemodel//lib/active_model/errors.rb#265 ActiveModel::Errors::EMPTY_ARRAY = T.let(T.unsafe(nil), Array) +# = Active \Model \ForbiddenAttributesError +# # Raised when forbidden attributes are used for mass assignment. # # class Person < ActiveRecord::Base @@ -2459,17 +2749,17 @@ ActiveModel::Errors::EMPTY_ARRAY = T.let(T.unsafe(nil), Array) # Person.new(params) # # => # # -# source://activemodel//lib/active_model/forbidden_attributes_protection.rb#16 +# source://activemodel//lib/active_model/forbidden_attributes_protection.rb#18 class ActiveModel::ForbiddenAttributesError < ::StandardError; end -# source://activemodel//lib/active_model/forbidden_attributes_protection.rb#19 +# source://activemodel//lib/active_model/forbidden_attributes_protection.rb#21 module ActiveModel::ForbiddenAttributesProtection private - # source://activemodel//lib/active_model/forbidden_attributes_protection.rb#21 + # source://activemodel//lib/active_model/forbidden_attributes_protection.rb#23 def sanitize_for_mass_assignment(attributes); end - # source://activemodel//lib/active_model/forbidden_attributes_protection.rb#21 + # source://activemodel//lib/active_model/forbidden_attributes_protection.rb#23 def sanitize_forbidden_attributes(attributes); end end @@ -2664,7 +2954,7 @@ module ActiveModel::Lint; end # == Active \Model \Lint \Tests # # You can test whether an object is compliant with the Active \Model API by -# including ActiveModel::Lint::Tests in your TestCase. It will +# including +ActiveModel::Lint::Tests+ in your TestCase. It will # include tests that tell you whether your object is fully compliant, # or if not, which aspects of the API are not implemented. # @@ -2768,12 +3058,12 @@ end # # user = User.first # user.pets.select(:id).first.user_id -# # => ActiveModel::MissingAttributeError: missing attribute: user_id +# # => ActiveModel::MissingAttributeError: missing attribute 'user_id' for Pet # # source://activemodel//lib/active_model/attribute_methods.rb#15 class ActiveModel::MissingAttributeError < ::NoMethodError; end -# == Active \Model \Basic \Model +# = Active \Model \Basic \Model # # Allows implementing models similar to ActiveRecord::Base. # Includes ActiveModel::API for the required interface for an @@ -2809,11 +3099,12 @@ class ActiveModel::MissingAttributeError < ::NoMethodError; end # person.omg # => true # # For more detailed information on other functionalities available, please -# refer to the specific modules included in ActiveModel::Model +# refer to the specific modules included in +ActiveModel::Model+ # (see below). # # source://activemodel//lib/active_model/model.rb#42 module ActiveModel::Model + include ::ActiveModel::Access extend ::ActiveSupport::Concern include GeneratedInstanceMethods include ::ActiveSupport::Callbacks @@ -2838,6 +3129,9 @@ module ActiveModel::Model def _validators; end def _validators=(value); end def _validators?; end + def param_delimiter; end + def param_delimiter=(value); end + def param_delimiter?; end end module GeneratedInstanceMethods @@ -2845,6 +3139,7 @@ module ActiveModel::Model def __callbacks?; end def _validators; end def _validators?; end + def param_delimiter=(value); end end end @@ -3030,16 +3325,25 @@ class ActiveModel::Name # @return [Boolean] # - # source://activemodel//lib/active_model/naming.rb#212 + # source://activemodel//lib/active_model/naming.rb#209 def uncountable?; end private - # source://activemodel//lib/active_model/naming.rb#217 + # source://activemodel//lib/active_model/naming.rb#216 def _singularize(string); end + + # source://activemodel//lib/active_model/naming.rb#220 + def i18n_keys; end + + # source://activemodel//lib/active_model/naming.rb#228 + def i18n_scope; end end -# == Active \Model \Naming +# source://activemodel//lib/active_model/naming.rb#214 +ActiveModel::Name::MISSING_TRANSLATION = T.let(T.unsafe(nil), Integer) + +# = Active \Model \Naming # # Creates a +model_name+ method on your object. # @@ -3059,7 +3363,7 @@ end # is required to pass the \Active \Model Lint test. So either extending the # provided method below, or rolling your own is required. # -# source://activemodel//lib/active_model/naming.rb#241 +# source://activemodel//lib/active_model/naming.rb#252 module ActiveModel::Naming # Returns an ActiveModel::Name object for module. It can be # used to retrieve all kinds of naming-related information @@ -3074,11 +3378,16 @@ module ActiveModel::Naming # Person.model_name.singular # => "person" # Person.model_name.plural # => "people" # - # source://activemodel//lib/active_model/naming.rb#259 + # source://activemodel//lib/active_model/naming.rb#270 def model_name; end + private + + # source://activemodel//lib/active_model/naming.rb#352 + def inherited(base); end + class << self - # source://activemodel//lib/active_model/naming.rb#242 + # source://activemodel//lib/active_model/naming.rb#253 def extended(base); end # Returns string to use for params names. It differs for @@ -3090,7 +3399,7 @@ module ActiveModel::Naming # # For shared engine: # ActiveModel::Naming.param_key(Blog::Post) # => "blog_post" # - # source://activemodel//lib/active_model/naming.rb#327 + # source://activemodel//lib/active_model/naming.rb#338 def param_key(record_or_class); end # Returns the plural class name of a record or class. @@ -3098,7 +3407,7 @@ module ActiveModel::Naming # ActiveModel::Naming.plural(post) # => "posts" # ActiveModel::Naming.plural(Highrise::Person) # => "highrise_people" # - # source://activemodel//lib/active_model/naming.rb#272 + # source://activemodel//lib/active_model/naming.rb#283 def plural(record_or_class); end # Returns string to use while generating route names. It differs for @@ -3113,7 +3422,7 @@ module ActiveModel::Naming # The route key also considers if the noun is uncountable and, in # such cases, automatically appends _index. # - # source://activemodel//lib/active_model/naming.rb#315 + # source://activemodel//lib/active_model/naming.rb#326 def route_key(record_or_class); end # Returns the singular class name of a record or class. @@ -3121,7 +3430,7 @@ module ActiveModel::Naming # ActiveModel::Naming.singular(post) # => "post" # ActiveModel::Naming.singular(Highrise::Person) # => "highrise_person" # - # source://activemodel//lib/active_model/naming.rb#280 + # source://activemodel//lib/active_model/naming.rb#291 def singular(record_or_class); end # Returns string to use while generating route names. It differs for @@ -3133,7 +3442,7 @@ module ActiveModel::Naming # # For shared engine: # ActiveModel::Naming.singular_route_key(Blog::Post) # => "blog_post" # - # source://activemodel//lib/active_model/naming.rb#300 + # source://activemodel//lib/active_model/naming.rb#311 def singular_route_key(record_or_class); end # Identifies whether the class name of a record or class is uncountable. @@ -3143,12 +3452,12 @@ module ActiveModel::Naming # # @return [Boolean] # - # source://activemodel//lib/active_model/naming.rb#288 + # source://activemodel//lib/active_model/naming.rb#299 def uncountable?(record_or_class); end private - # source://activemodel//lib/active_model/naming.rb#331 + # source://activemodel//lib/active_model/naming.rb#342 def model_name_from_record_or_class(record_or_class); end end end @@ -3217,9 +3526,11 @@ end # source://activemodel//lib/active_model/railtie.rb#7 class ActiveModel::Railtie < ::Rails::Railtie; end +# = Active \Model \RangeError +# # Raised when attribute values are out of range. # -# source://activemodel//lib/active_model/errors.rb#494 +# source://activemodel//lib/active_model/errors.rb#523 class ActiveModel::RangeError < ::RangeError; end # source://activemodel//lib/active_model/secure_password.rb#4 @@ -3240,8 +3551,8 @@ end # source://activemodel//lib/active_model/secure_password.rb#17 module ActiveModel::SecurePassword::ClassMethods # Adds methods to set and authenticate against a BCrypt password. - # This mechanism requires you to have a +XXX_digest+ attribute. - # Where +XXX+ is the attribute name of your desired password. + # This mechanism requires you to have a +XXX_digest+ attribute, + # where +XXX+ is the attribute name of your desired password. # # The following validations are added automatically: # * Password must be present on creation @@ -3253,12 +3564,19 @@ module ActiveModel::SecurePassword::ClassMethods # it). When this attribute has a +nil+ value, the validation will not be # triggered. # - # For further customizability, it is possible to suppress the default - # validations by passing validations: false as an argument. + # Additionally, a +XXX_challenge+ attribute is created. When set to a + # value other than +nil+, it will validate against the currently persisted + # password. This validation relies on dirty tracking, as provided by + # ActiveModel::Dirty; if dirty tracking methods are not defined, this + # validation will fail. # - # Add bcrypt (~> 3.1.7) to Gemfile to use #has_secure_password: + # All of the above validations can be omitted by passing + # validations: false as an argument. This allows complete + # customizability of validation behavior. # - # gem 'bcrypt', '~> 3.1.7' + # To use +has_secure_password+, add bcrypt (~> 3.1.7) to your Gemfile: + # + # gem "bcrypt", "~> 3.1.7" # # ==== Examples # @@ -3270,20 +3588,30 @@ module ActiveModel::SecurePassword::ClassMethods # has_secure_password :recovery_password, validations: false # end # - # user = User.new(name: 'david', password: '', password_confirmation: 'nomatch') - # user.save # => false, password required - # user.password = 'mUc3m00RsqyRe' - # user.save # => false, confirmation doesn't match - # user.password_confirmation = 'mUc3m00RsqyRe' - # user.save # => true + # user = User.new(name: "david", password: "", password_confirmation: "nomatch") + # + # user.save # => false, password required + # user.password = "vr00m" + # user.save # => false, confirmation doesn't match + # user.password_confirmation = "vr00m" + # user.save # => true + # + # user.authenticate("notright") # => false + # user.authenticate("vr00m") # => user + # User.find_by(name: "david")&.authenticate("notright") # => false + # User.find_by(name: "david")&.authenticate("vr00m") # => user + # # user.recovery_password = "42password" - # user.recovery_password_digest # => "$2a$04$iOfhwahFymCs5weB3BNH/uXkTG65HR.qpW.bNhEjFP3ftli3o5DQC" - # user.save # => true - # user.authenticate('notright') # => false - # user.authenticate('mUc3m00RsqyRe') # => user - # user.authenticate_recovery_password('42password') # => user - # User.find_by(name: 'david')&.authenticate('notright') # => false - # User.find_by(name: 'david')&.authenticate('mUc3m00RsqyRe') # => user + # user.recovery_password_digest # => "$2a$04$iOfhwahFymCs5weB3BNH/uXkTG65HR.qpW.bNhEjFP3ftli3o5DQC" + # user.save # => true + # + # user.authenticate_recovery_password("42password") # => user + # + # user.update(password: "pwn3d", password_challenge: "") # => false, challenge doesn't authenticate + # user.update(password: "nohack4u", password_challenge: "vr00m") # => true + # + # user.authenticate("vr00m") # => false, old password + # user.authenticate("nohack4u") # => user # # ===== Conditionally requiring a password # @@ -3305,15 +3633,15 @@ module ActiveModel::SecurePassword::ClassMethods # account.is_guest = true # account.valid? # => true # - # source://activemodel//lib/active_model/secure_password.rb#84 + # source://activemodel//lib/active_model/secure_password.rb#101 def has_secure_password(attribute = T.unsafe(nil), validations: T.unsafe(nil)); end end -# source://activemodel//lib/active_model/secure_password.rb#114 +# source://activemodel//lib/active_model/secure_password.rb#148 class ActiveModel::SecurePassword::InstanceMethodsOnActivation < ::Module # @return [InstanceMethodsOnActivation] a new instance of InstanceMethodsOnActivation # - # source://activemodel//lib/active_model/secure_password.rb#115 + # source://activemodel//lib/active_model/secure_password.rb#149 def initialize(attribute); end end @@ -3324,7 +3652,7 @@ end # source://activemodel//lib/active_model/secure_password.rb#10 ActiveModel::SecurePassword::MAX_PASSWORD_LENGTH_ALLOWED = T.let(T.unsafe(nil), Integer) -# == Active \Model \Serialization +# = Active \Model \Serialization # # Provides a basic serialization to a serializable_hash for your objects. # @@ -3354,8 +3682,8 @@ ActiveModel::SecurePassword::MAX_PASSWORD_LENGTH_ALLOWED = T.let(T.unsafe(nil), # at the private method +read_attribute_for_serialization+. # # ActiveModel::Serializers::JSON module automatically includes -# the ActiveModel::Serialization module, so there is no need to -# explicitly include ActiveModel::Serialization. +# the +ActiveModel::Serialization+ module, so there is no need to +# explicitly include +ActiveModel::Serialization+. # # A minimal implementation including JSON would be: # @@ -3486,12 +3814,12 @@ module ActiveModel::Serialization def serializable_attributes(attribute_names); end end -# source://activemodel//lib/active_model.rb#64 +# source://activemodel//lib/active_model.rb#68 module ActiveModel::Serializers extend ::ActiveSupport::Autoload end -# == Active \Model \JSON \Serializer +# = Active \Model \JSON \Serializer # # source://activemodel//lib/active_model/serializers/json.rb#8 module ActiveModel::Serializers::JSON @@ -3634,6 +3962,8 @@ module ActiveModel::Serializers::JSON end end +# = Active \Model \StrictValidationFailed +# # Raised when a validation cannot be corrected by end users and are considered # exceptional. # @@ -3650,12 +3980,12 @@ end # person.valid? # # => ActiveModel::StrictValidationFailed: Name can't be blank # -# source://activemodel//lib/active_model/errors.rb#490 +# source://activemodel//lib/active_model/errors.rb#517 class ActiveModel::StrictValidationFailed < ::StandardError; end -# == Active \Model \Translation +# = Active \Model \Translation # -# Provides integration between your object and the Rails internationalization +# Provides integration between your object and the \Rails internationalization # (i18n) framework. # # A minimal implementation could be: @@ -3668,7 +3998,7 @@ class ActiveModel::StrictValidationFailed < ::StandardError; end # # => "My attribute" # # This also provides the required class methods for hooking into the -# Rails internationalization API, including being able to define a +# \Rails internationalization API, including being able to define a # class-based +i18n_scope+ and +lookup_ancestors+ to find translations in # parent classes. # @@ -3683,7 +4013,7 @@ module ActiveModel::Translation # # Specify +options+ with additional translating options. # - # source://activemodel//lib/active_model/translation.rb#44 + # source://activemodel//lib/active_model/translation.rb#46 def human_attribute_name(attribute, options = T.unsafe(nil)); end # Returns the +i18n_scope+ for the class. Override if you want custom lookup. @@ -3700,208 +4030,370 @@ module ActiveModel::Translation def lookup_ancestors; end end +# source://activemodel//lib/active_model/translation.rb#38 +ActiveModel::Translation::MISSING_TRANSLATION = T.let(T.unsafe(nil), Integer) + # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#4 module ActiveModel::Type class << self - # source://activemodel//lib/active_model/type.rb#37 + # source://activemodel//lib/active_model/type.rb#38 def default_value; end - # source://activemodel//lib/active_model/type.rb#33 + # source://activemodel//lib/active_model/type.rb#34 def lookup(*_arg0, **_arg1, &_arg2); end # Add a new type to the registry, allowing it to be referenced as a # symbol by {attribute}[rdoc-ref:Attributes::ClassMethods#attribute]. # - # source://activemodel//lib/active_model/type.rb#29 + # source://activemodel//lib/active_model/type.rb#30 def register(type_name, klass = T.unsafe(nil), &block); end - # source://activemodel//lib/active_model/type.rb#25 + # source://activemodel//lib/active_model/type.rb#26 def registry; end - # source://activemodel//lib/active_model/type.rb#25 + # source://activemodel//lib/active_model/type.rb#26 def registry=(_arg0); end end end -# source://activemodel//lib/active_model/type/big_integer.rb#7 +# = Active Model \BigInteger \Type +# +# Attribute type for integers that can be serialized to an unlimited number +# of bytes. This type is registered under the +:big_integer+ key. +# +# class Person +# include ActiveModel::Attributes +# +# attribute :id, :big_integer +# end +# +# person = Person.new +# person.id = "18_000_000_000" +# +# person.id # => 18000000000 +# +# All casting and serialization are performed in the same way as the +# standard ActiveModel::Type::Integer type. +# +# source://activemodel//lib/active_model/type/big_integer.rb#25 class ActiveModel::Type::BigInteger < ::ActiveModel::Type::Integer + # source://activemodel//lib/active_model/type/big_integer.rb#26 + def serialize_cast_value(value); end + private - # source://activemodel//lib/active_model/type/big_integer.rb#9 + # source://activemodel//lib/active_model/type/big_integer.rb#31 def max_value; end end -# source://activemodel//lib/active_model/type/binary.rb#5 +# = Active Model \Binary \Type +# +# Attribute type for representation of binary data. This type is registered +# under the +:binary+ key. +# +# Non-string values are coerced to strings using their +to_s+ method. +# +# source://activemodel//lib/active_model/type/binary.rb#11 class ActiveModel::Type::Binary < ::ActiveModel::Type::Value # @return [Boolean] # - # source://activemodel//lib/active_model/type/binary.rb#10 + # source://activemodel//lib/active_model/type/binary.rb#16 def binary?; end - # source://activemodel//lib/active_model/type/binary.rb#14 + # source://activemodel//lib/active_model/type/binary.rb#20 def cast(value); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/binary.rb#27 + # source://activemodel//lib/active_model/type/binary.rb#35 def changed_in_place?(raw_old_value, value); end - # source://activemodel//lib/active_model/type/binary.rb#22 + # source://activemodel//lib/active_model/type/binary.rb#30 def serialize(value); end - # source://activemodel//lib/active_model/type/binary.rb#6 + # source://activemodel//lib/active_model/type/binary.rb#12 def type; end end -# source://activemodel//lib/active_model/type/binary.rb#32 +# source://activemodel//lib/active_model/type/binary.rb#40 class ActiveModel::Type::Binary::Data # @return [Data] a new instance of Data # - # source://activemodel//lib/active_model/type/binary.rb#33 + # source://activemodel//lib/active_model/type/binary.rb#41 def initialize(value); end - # source://activemodel//lib/active_model/type/binary.rb#48 + # source://activemodel//lib/active_model/type/binary.rb#56 def ==(other); end - # source://activemodel//lib/active_model/type/binary.rb#44 + # source://activemodel//lib/active_model/type/binary.rb#52 def hex; end - # source://activemodel//lib/active_model/type/binary.rb#39 + # source://activemodel//lib/active_model/type/binary.rb#47 def to_s; end - # source://activemodel//lib/active_model/type/binary.rb#39 + # source://activemodel//lib/active_model/type/binary.rb#47 def to_str; end end -# == Active \Model \Type \Boolean +# = Active Model \Boolean \Type # -# A class that behaves like a boolean type, including rules for coercion of user input. +# A class that behaves like a boolean type, including rules for coercion of +# user input. # -# === Coercion -# Values set from user input will first be coerced into the appropriate ruby type. -# Coercion behavior is roughly mapped to Ruby's boolean semantics. +# - "false", "f", "0", +0+ or any other value in +# +FALSE_VALUES+ will be coerced to +false+. +# - Empty strings are coerced to +nil+. +# - All other values will be coerced to +true+. # -# - "false", "f" , "0", +0+ or any other value in +FALSE_VALUES+ will be coerced to +false+ -# - Empty strings are coerced to +nil+ -# - All other values will be coerced to +true+ -# -# source://activemodel//lib/active_model/type/boolean.rb#16 +# source://activemodel//lib/active_model/type/boolean.rb#14 class ActiveModel::Type::Boolean < ::ActiveModel::Type::Value - # source://activemodel//lib/active_model/type/boolean.rb#32 + # source://activemodel//lib/active_model/type/boolean.rb#30 def serialize(value); end - # source://activemodel//lib/active_model/type/boolean.rb#28 + # source://activemodel//lib/active_model/type/boolean.rb#34 + def serialize_cast_value(value); end + + # source://activemodel//lib/active_model/type/boolean.rb#26 def type; end private - # source://activemodel//lib/active_model/type/boolean.rb#37 + # source://activemodel//lib/active_model/type/boolean.rb#39 def cast_value(value); end end -# source://activemodel//lib/active_model/type/boolean.rb#17 +# source://activemodel//lib/active_model/type/boolean.rb#15 ActiveModel::Type::Boolean::FALSE_VALUES = T.let(T.unsafe(nil), Set) -# source://activemodel//lib/active_model/type/date.rb#5 +# = Active Model \Date \Type +# +# Attribute type for date representation. It is registered under the +# +:date+ key. +# +# class Person +# include ActiveModel::Attributes +# +# attribute :birthday, :date +# end +# +# person = Person.new +# person.birthday = "1989-07-13" +# +# person.birthday.class # => Date +# person.birthday.year # => 1989 +# person.birthday.month # => 7 +# person.birthday.day # => 13 +# +# String values are parsed using the ISO 8601 date format. Any other values +# are cast using their +to_date+ method, if it exists. +# +# source://activemodel//lib/active_model/type/date.rb#26 class ActiveModel::Type::Date < ::ActiveModel::Type::Value include ::ActiveModel::Type::Helpers::Timezone include ::ActiveModel::Type::Helpers::AcceptsMultiparameterTime::InstanceMethods - # source://activemodel//lib/active_model/type/date.rb#9 + # source://activemodel//lib/active_model/type/date.rb#30 def type; end - # source://activemodel//lib/active_model/type/date.rb#13 + # source://activemodel//lib/active_model/type/date.rb#34 def type_cast_for_schema(value); end private - # source://activemodel//lib/active_model/type/date.rb#18 + # source://activemodel//lib/active_model/type/date.rb#39 def cast_value(value); end - # source://activemodel//lib/active_model/type/date.rb#36 + # source://activemodel//lib/active_model/type/date.rb#57 def fallback_string_to_date(string); end - # source://activemodel//lib/active_model/type/date.rb#30 + # source://activemodel//lib/active_model/type/date.rb#51 def fast_string_to_date(string); end - # source://activemodel//lib/active_model/type/date.rb#40 + # source://activemodel//lib/active_model/type/date.rb#66 def new_date(year, mon, mday); end - # source://activemodel//lib/active_model/type/date.rb#46 + # source://activemodel//lib/active_model/type/date.rb#72 def value_from_multiparameter_assignment(*_arg0); end end -# source://activemodel//lib/active_model/type/date.rb#29 +# source://activemodel//lib/active_model/type/date.rb#50 ActiveModel::Type::Date::ISO_DATE = T.let(T.unsafe(nil), Regexp) -# source://activemodel//lib/active_model/type/date_time.rb#5 +# = Active Model \DateTime \Type +# +# Attribute type to represent dates and times. It is registered under the +# +:datetime+ key. +# +# class Event +# include ActiveModel::Attributes +# +# attribute :start, :datetime +# end +# +# event = Event.new +# event.start = "Wed, 04 Sep 2013 03:00:00 EAT" +# +# event.start.class # => Time +# event.start.year # => 2013 +# event.start.month # => 9 +# event.start.day # => 4 +# event.start.hour # => 3 +# event.start.min # => 0 +# event.start.sec # => 0 +# event.start.zone # => "EAT" +# +# String values are parsed using the ISO 8601 datetime format. Partial +# time-only formats are also accepted. +# +# event.start = "06:07:08+09:00" +# event.start.utc # => 1999-12-31 21:07:08 UTC +# +# The degree of sub-second precision can be customized when declaring an +# attribute: +# +# class Event +# include ActiveModel::Attributes +# +# attribute :start, :datetime, precision: 4 +# end +# +# source://activemodel//lib/active_model/type/date_time.rb#42 class ActiveModel::Type::DateTime < ::ActiveModel::Type::Value include ::ActiveModel::Type::Helpers::Timezone - include ::ActiveModel::Type::Helpers::TimeValue include ::ActiveModel::Type::Helpers::AcceptsMultiparameterTime::InstanceMethods + include ::ActiveModel::Type::Helpers::TimeValue - # source://activemodel//lib/active_model/type/date_time.rb#12 + # source://activemodel//lib/active_model/type/date_time.rb#49 def type; end private - # source://activemodel//lib/active_model/type/date_time.rb#17 + # source://activemodel//lib/active_model/type/date_time.rb#54 def cast_value(value); end - # source://activemodel//lib/active_model/type/date_time.rb#30 + # source://activemodel//lib/active_model/type/date_time.rb#67 def fallback_string_to_time(string); end # '0.123456' -> 123456 # '1.123456' -> 123456 # - # source://activemodel//lib/active_model/type/date_time.rb#26 + # source://activemodel//lib/active_model/type/date_time.rb#63 def microseconds(time); end - # source://activemodel//lib/active_model/type/date_time.rb#37 + # source://activemodel//lib/active_model/type/date_time.rb#79 def value_from_multiparameter_assignment(values_hash); end end -# source://activemodel//lib/active_model/type/decimal.rb#7 +# = Active Model \Decimal \Type +# +# Attribute type for decimal, high-precision floating point numeric +# representation. It is registered under the +:decimal+ key. +# +# class BagOfCoffee +# include ActiveModel::Attributes +# +# attribute :weight, :decimal +# end +# +# Numeric instances are converted to BigDecimal instances. Any other objects +# are cast using their +to_d+ method, except for blank strings, which are +# cast to +nil+. If a +to_d+ method is not defined, the object is converted +# to a string using +to_s+, which is then cast using +to_d+. +# +# bag = BagOfCoffee.new +# +# bag.weight = 0.01 +# bag.weight # => 0.1e-1 +# +# bag.weight = "0.01" +# bag.weight # => 0.1e-1 +# +# bag.weight = "" +# bag.weight # => nil +# +# bag.weight = :arbitrary +# bag.weight # => nil (the result of `.to_s.to_d`) +# +# Decimal precision defaults to 18, and can be customized when declaring an +# attribute: +# +# class BagOfCoffee +# include ActiveModel::Attributes +# +# attribute :weight, :decimal, precision: 24 +# end +# +# source://activemodel//lib/active_model/type/decimal.rb#45 class ActiveModel::Type::Decimal < ::ActiveModel::Type::Value include ::ActiveModel::Type::Helpers::Numeric - # source://activemodel//lib/active_model/type/decimal.rb#11 + # source://activemodel//lib/active_model/type/decimal.rb#49 def type; end - # source://activemodel//lib/active_model/type/decimal.rb#15 + # source://activemodel//lib/active_model/type/decimal.rb#53 def type_cast_for_schema(value); end private - # source://activemodel//lib/active_model/type/decimal.rb#60 + # source://activemodel//lib/active_model/type/decimal.rb#98 def apply_scale(value); end - # source://activemodel//lib/active_model/type/decimal.rb#20 + # source://activemodel//lib/active_model/type/decimal.rb#58 def cast_value(value); end - # source://activemodel//lib/active_model/type/decimal.rb#44 + # source://activemodel//lib/active_model/type/decimal.rb#82 def convert_float_to_big_decimal(value); end - # source://activemodel//lib/active_model/type/decimal.rb#52 + # source://activemodel//lib/active_model/type/decimal.rb#90 def float_precision; end end -# source://activemodel//lib/active_model/type/decimal.rb#9 +# source://activemodel//lib/active_model/type/decimal.rb#47 ActiveModel::Type::Decimal::BIGDECIMAL_PRECISION = T.let(T.unsafe(nil), Integer) -# source://activemodel//lib/active_model/type/float.rb#7 +# = Active Model \Float \Type +# +# Attribute type for floating point numeric values. It is registered under +# the +:float+ key. +# +# class BagOfCoffee +# include ActiveModel::Attributes +# +# attribute :weight, :float +# end +# +# Values are cast using their +to_f+ method, except for the following +# strings: +# +# - Blank strings are cast to +nil+. +# - "Infinity" is cast to +Float::INFINITY+. +# - "-Infinity" is cast to -Float::INFINITY. +# - "NaN" is cast to +Float::NAN+. +# +# bag = BagOfCoffee.new +# +# bag.weight = "0.25" +# bag.weight # => 0.25 +# +# bag.weight = "" +# bag.weight # => nil +# +# bag.weight = "NaN" +# bag.weight # => Float::NAN +# +# source://activemodel//lib/active_model/type/float.rb#36 class ActiveModel::Type::Float < ::ActiveModel::Type::Value include ::ActiveModel::Type::Helpers::Numeric - # source://activemodel//lib/active_model/type/float.rb#10 + # source://activemodel//lib/active_model/type/float.rb#39 def type; end - # source://activemodel//lib/active_model/type/float.rb#14 + # source://activemodel//lib/active_model/type/float.rb#43 def type_cast_for_schema(value); end private - # source://activemodel//lib/active_model/type/float.rb#24 + # source://activemodel//lib/active_model/type/float.rb#53 def cast_value(value); end end @@ -3912,30 +4404,33 @@ module ActiveModel::Type::Helpers; end class ActiveModel::Type::Helpers::AcceptsMultiparameterTime < ::Module # @return [AcceptsMultiparameterTime] a new instance of AcceptsMultiparameterTime # - # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#33 + # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#37 def initialize(defaults: T.unsafe(nil)); end end # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#7 module ActiveModel::Type::Helpers::AcceptsMultiparameterTime::InstanceMethods - # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#20 + # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#24 def assert_valid_value(value); end - # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#12 + # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#16 def cast(value); end # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#8 def serialize(value); end + # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#12 + def serialize_cast_value(value); end + # @return [Boolean] # - # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#28 + # source://activemodel//lib/active_model/type/helpers/accepts_multiparameter_time.rb#32 def value_constructed_by_mass_assignment?(value); end end # source://activemodel//lib/active_model/type/helpers/mutable.rb#6 module ActiveModel::Type::Helpers::Mutable - # source://activemodel//lib/active_model/type/helpers/mutable.rb#11 + # source://activemodel//lib/active_model/type/helpers/mutable.rb#7 def cast(value); end # +raw_old_value+ will be the `_before_type_cast` version of the @@ -3944,45 +4439,50 @@ module ActiveModel::Type::Helpers::Mutable # # @return [Boolean] # - # source://activemodel//lib/active_model/type/helpers/mutable.rb#18 + # source://activemodel//lib/active_model/type/helpers/mutable.rb#14 def changed_in_place?(raw_old_value, new_value); end - # source://activemodel//lib/active_model/type/helpers/mutable.rb#7 - def immutable_value(value); end + # @return [Boolean] + # + # source://activemodel//lib/active_model/type/helpers/mutable.rb#18 + def mutable?; end end # source://activemodel//lib/active_model/type/helpers/numeric.rb#6 module ActiveModel::Type::Helpers::Numeric - # source://activemodel//lib/active_model/type/helpers/numeric.rb#11 + # source://activemodel//lib/active_model/type/helpers/numeric.rb#15 def cast(value); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/helpers/numeric.rb#27 + # source://activemodel//lib/active_model/type/helpers/numeric.rb#31 def changed?(old_value, _new_value, new_value_before_type_cast); end # source://activemodel//lib/active_model/type/helpers/numeric.rb#7 def serialize(value); end + # source://activemodel//lib/active_model/type/helpers/numeric.rb#11 + def serialize_cast_value(value); end + private # @return [Boolean] # - # source://activemodel//lib/active_model/type/helpers/numeric.rb#33 + # source://activemodel//lib/active_model/type/helpers/numeric.rb#37 def equal_nan?(old_value, new_value); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/helpers/numeric.rb#44 + # source://activemodel//lib/active_model/type/helpers/numeric.rb#49 def non_numeric_string?(value); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/helpers/numeric.rb#40 + # source://activemodel//lib/active_model/type/helpers/numeric.rb#44 def number_to_non_number?(old_value, new_value_before_type_cast); end end -# source://activemodel//lib/active_model/type/helpers/numeric.rb#51 +# source://activemodel//lib/active_model/type/helpers/numeric.rb#56 ActiveModel::Type::Helpers::Numeric::NUMERIC_REGEX = T.let(T.unsafe(nil), Regexp) # source://activemodel//lib/active_model/type/helpers/time_value.rb#9 @@ -3991,7 +4491,7 @@ module ActiveModel::Type::Helpers::TimeValue def apply_seconds_precision(value); end # source://activemodel//lib/active_model/type/helpers/time_value.rb#10 - def serialize(value); end + def serialize_cast_value(value); end # source://activemodel//lib/active_model/type/helpers/time_value.rb#38 def type_cast_for_schema(value); end @@ -4001,7 +4501,11 @@ module ActiveModel::Type::Helpers::TimeValue private - # source://activemodel//lib/active_model/type/helpers/time_value.rb#72 + # BUG: Wrapping the Time object with Time.at because Time.new with `in:` in Ruby 3.2.0 + # used to return an invalid Time object + # see: https://bugs.ruby-lang.org/issues/19292 + # + # source://activemodel//lib/active_model/type/helpers/time_value.rb#89 def fast_string_to_time(string); end # source://activemodel//lib/active_model/type/helpers/time_value.rb#47 @@ -4013,7 +4517,7 @@ ActiveModel::Type::Helpers::TimeValue::ISO_DATETIME = T.let(T.unsafe(nil), Regex # source://activemodel//lib/active_model/type/helpers/timezone.rb#8 module ActiveModel::Type::Helpers::Timezone - # source://activemodel//lib/active_model/type/helpers/timezone.rb#13 + # source://activemodel//lib/active_model/type/helpers/timezone.rb#17 def default_timezone; end # @return [Boolean] @@ -4022,80 +4526,159 @@ module ActiveModel::Type::Helpers::Timezone def is_utc?; end end -# source://activemodel//lib/active_model/type/immutable_string.rb#5 +# = Active Model \ImmutableString \Type +# +# Attribute type to represent immutable strings. It casts incoming values to +# frozen strings. +# +# class Person +# include ActiveModel::Attributes +# +# attribute :name, :immutable_string +# end +# +# person = Person.new +# person.name = 1 +# +# person.name # => "1" +# person.name.frozen? # => true +# +# Values are coerced to strings using their +to_s+ method. Boolean values +# are treated differently, however: +true+ will be cast to "t" and +# +false+ will be cast to "f". These strings can be customized when +# declaring an attribute: +# +# class Person +# include ActiveModel::Attributes +# +# attribute :active, :immutable_string, true: "aye", false: "nay" +# end +# +# person = Person.new +# person.active = true +# +# person.active # => "aye" +# +# source://activemodel//lib/active_model/type/immutable_string.rb#37 class ActiveModel::Type::ImmutableString < ::ActiveModel::Type::Value # @return [ImmutableString] a new instance of ImmutableString # - # source://activemodel//lib/active_model/type/immutable_string.rb#6 + # source://activemodel//lib/active_model/type/immutable_string.rb#38 def initialize(**args); end - # source://activemodel//lib/active_model/type/immutable_string.rb#16 + # source://activemodel//lib/active_model/type/immutable_string.rb#48 def serialize(value); end - # source://activemodel//lib/active_model/type/immutable_string.rb#12 + # source://activemodel//lib/active_model/type/immutable_string.rb#57 + def serialize_cast_value(value); end + + # source://activemodel//lib/active_model/type/immutable_string.rb#44 def type; end private - # source://activemodel//lib/active_model/type/immutable_string.rb#26 + # source://activemodel//lib/active_model/type/immutable_string.rb#62 def cast_value(value); end end -# source://activemodel//lib/active_model/type/integer.rb#5 +# = Active Model \Integer \Type +# +# Attribute type for integer representation. This type is registered under +# the +:integer+ key. +# +# class Person +# include ActiveModel::Attributes +# +# attribute :age, :integer +# end +# +# Values are cast using their +to_i+ method, except for blank strings, which +# are cast to +nil+. If a +to_i+ method is not defined or raises an error, +# the value will be cast to +nil+. +# +# person = Person.new +# +# person.age = "18" +# person.age # => 18 +# +# person.age = "" +# person.age # => nil +# +# person.age = :not_an_integer +# person.age # => nil (because Symbol does not define #to_i) +# +# Serialization also works under the same principle. Non-numeric strings are +# serialized as +nil+, for example. +# +# Serialization also validates that the integer can be stored using a +# limited number of bytes. If it cannot, an ActiveModel::RangeError will be +# raised. The default limit is 4 bytes, and can be customized when declaring +# an attribute: +# +# class Person +# include ActiveModel::Attributes +# +# attribute :age, :integer, limit: 6 +# end +# +# source://activemodel//lib/active_model/type/integer.rb#44 class ActiveModel::Type::Integer < ::ActiveModel::Type::Value include ::ActiveModel::Type::Helpers::Numeric # @return [Integer] a new instance of Integer # - # source://activemodel//lib/active_model/type/integer.rb#12 + # source://activemodel//lib/active_model/type/integer.rb#51 def initialize(**_arg0); end - # source://activemodel//lib/active_model/type/integer.rb#21 + # source://activemodel//lib/active_model/type/integer.rb#60 def deserialize(value); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/integer.rb#31 + # source://activemodel//lib/active_model/type/integer.rb#74 def serializable?(value); end - # source://activemodel//lib/active_model/type/integer.rb#26 + # source://activemodel//lib/active_model/type/integer.rb#65 def serialize(value); end - # source://activemodel//lib/active_model/type/integer.rb#17 + # source://activemodel//lib/active_model/type/integer.rb#70 + def serialize_cast_value(value); end + + # source://activemodel//lib/active_model/type/integer.rb#56 def type; end private - # source://activemodel//lib/active_model/type/integer.rb#65 + # source://activemodel//lib/active_model/type/integer.rb#108 def _limit; end - # source://activemodel//lib/active_model/type/integer.rb#46 + # source://activemodel//lib/active_model/type/integer.rb#89 def cast_value(value); end - # source://activemodel//lib/active_model/type/integer.rb#50 + # source://activemodel//lib/active_model/type/integer.rb#93 def ensure_in_range(value); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/integer.rb#42 + # source://activemodel//lib/active_model/type/integer.rb#85 def in_range?(value); end - # source://activemodel//lib/active_model/type/integer.rb#57 + # source://activemodel//lib/active_model/type/integer.rb#100 def max_value; end - # source://activemodel//lib/active_model/type/integer.rb#61 + # source://activemodel//lib/active_model/type/integer.rb#104 def min_value; end # Returns the value of attribute range. # - # source://activemodel//lib/active_model/type/integer.rb#40 + # source://activemodel//lib/active_model/type/integer.rb#83 def range; end end # Column storage size in bytes. # 4 bytes means an integer as opposed to smallint etc. # -# source://activemodel//lib/active_model/type/integer.rb#10 +# source://activemodel//lib/active_model/type/integer.rb#49 ActiveModel::Type::Integer::DEFAULT_LIMIT = T.let(T.unsafe(nil), Integer) # source://activemodel//lib/active_model/type/registry.rb#5 @@ -4106,7 +4689,7 @@ class ActiveModel::Type::Registry def initialize; end # source://activemodel//lib/active_model/type/registry.rb#23 - def lookup(symbol, *args, **_arg2); end + def lookup(symbol, *_arg1, **_arg2, &_arg3); end # source://activemodel//lib/active_model/type/registry.rb#15 def register(type_name, klass = T.unsafe(nil), &block); end @@ -4118,55 +4701,155 @@ class ActiveModel::Type::Registry # Returns the value of attribute registrations. # - # source://activemodel//lib/active_model/type/registry.rb#35 + # source://activemodel//lib/active_model/type/registry.rb#34 def registrations; end end -# source://activemodel//lib/active_model/type/string.rb#7 +# source://activemodel//lib/active_model/type/serialize_cast_value.rb#5 +module ActiveModel::Type::SerializeCastValue + extend ::ActiveSupport::Concern + include ::ActiveModel::Type::SerializeCastValue::DefaultImplementation + + mixes_in_class_methods ::ActiveModel::Type::SerializeCastValue::ClassMethods + + # source://activemodel//lib/active_model/type/serialize_cast_value.rb#41 + def initialize(*_arg0, **_arg1, &_arg2); end + + # source://activemodel//lib/active_model/type/serialize_cast_value.rb#37 + def itself_if_serialize_cast_value_compatible; end + + class << self + # @private + # + # source://activemodel//lib/active_model/type/serialize_cast_value.rb#21 + def included(klass); end + + # source://activemodel//lib/active_model/type/serialize_cast_value.rb#25 + def serialize(type, value); end + end +end + +# source://activemodel//lib/active_model/type/serialize_cast_value.rb#8 +module ActiveModel::Type::SerializeCastValue::ClassMethods + # @return [Boolean] + # + # source://activemodel//lib/active_model/type/serialize_cast_value.rb#9 + def serialize_cast_value_compatible?; end +end + +# source://activemodel//lib/active_model/type/serialize_cast_value.rb#15 +module ActiveModel::Type::SerializeCastValue::DefaultImplementation + # source://activemodel//lib/active_model/type/serialize_cast_value.rb#16 + def serialize_cast_value(value); end +end + +# = Active Model \String \Type +# +# Attribute type for strings. It is registered under the +:string+ key. +# +# This class is a specialization of ActiveModel::Type::ImmutableString. It +# performs coercion in the same way, and can be configured in the same way. +# However, it accounts for mutable strings, so dirty tracking can properly +# check if a string has changed. +# +# source://activemodel//lib/active_model/type/string.rb#15 class ActiveModel::Type::String < ::ActiveModel::Type::ImmutableString # @return [Boolean] # - # source://activemodel//lib/active_model/type/string.rb#8 + # source://activemodel//lib/active_model/type/string.rb#16 def changed_in_place?(raw_old_value, new_value); end - # source://activemodel//lib/active_model/type/string.rb#14 + # source://activemodel//lib/active_model/type/string.rb#22 def to_immutable_string; end private - # source://activemodel//lib/active_model/type/string.rb#25 + # source://activemodel//lib/active_model/type/string.rb#33 def cast_value(value); end end -# source://activemodel//lib/active_model/type/time.rb#5 +# = Active Model \Time \Type +# +# Attribute type for time of day representation. It is registered under the +# +:time+ key. +# +# class Event +# include ActiveModel::Attributes +# +# attribute :start, :time +# end +# +# String values are parsed using the ISO 8601 datetime format, but are +# normalized to have a date of 2000-01-01 and be in the UTC time zone. +# +# event = Event.new +# event.start = "2004-10-25T01:23:45-06:00" +# +# event.start.class # => Time +# event.start # => 2000-01-01 07:23:45 UTC +# +# Partial time-only formats are also accepted. +# +# event.start = "00:01:02+03:00" +# event.start # => 1999-12-31 21:01:02 UTC +# +# The degree of sub-second precision can be customized when declaring an +# attribute: +# +# class Event +# include ActiveModel::Attributes +# +# attribute :start, :time, precision: 4 +# end +# +# source://activemodel//lib/active_model/type/time.rb#38 class ActiveModel::Type::Time < ::ActiveModel::Type::Value include ::ActiveModel::Type::Helpers::Timezone - include ::ActiveModel::Type::Helpers::TimeValue include ::ActiveModel::Type::Helpers::AcceptsMultiparameterTime::InstanceMethods + include ::ActiveModel::Type::Helpers::TimeValue - # source://activemodel//lib/active_model/type/time.rb#12 + # source://activemodel//lib/active_model/type/time.rb#45 def type; end - # source://activemodel//lib/active_model/type/time.rb#16 + # source://activemodel//lib/active_model/type/time.rb#49 def user_input_in_time_zone(value); end private - # source://activemodel//lib/active_model/type/time.rb#32 + # source://activemodel//lib/active_model/type/time.rb#69 def cast_value(value); end end -# source://activemodel//lib/active_model/type/value.rb#5 +# = Active Model \Value \Type +# +# The base class for all attribute types. This class also serves as the +# default type for attributes that do not specify a type. +# +# source://activemodel//lib/active_model/type/value.rb#9 class ActiveModel::Type::Value + include ::ActiveModel::Type::SerializeCastValue + include ::ActiveModel::Type::SerializeCastValue::DefaultImplementation + extend ::ActiveModel::Type::SerializeCastValue::ClassMethods + + # Initializes a type with three basic configuration settings: precision, + # limit, and scale. The Value base class does not define behavior for + # these settings. It uses them for equality comparison and hash key + # generation only. + # # @return [Value] a new instance of Value # - # source://activemodel//lib/active_model/type/value.rb#8 + # source://activemodel//lib/active_model/type/value.rb#17 def initialize(precision: T.unsafe(nil), limit: T.unsafe(nil), scale: T.unsafe(nil)); end - # source://activemodel//lib/active_model/type/value.rb#109 + # source://activemodel//lib/active_model/type/value.rb#121 def ==(other); end - # source://activemodel//lib/active_model/type/value.rb#121 + # @raise [NoMethodError] + # + # source://activemodel//lib/active_model/type/value.rb#144 + def as_json(*_arg0); end + + # source://activemodel//lib/active_model/type/value.rb#133 def assert_valid_value(_); end # These predicates are not documented, as I need to look further into @@ -4174,7 +4857,7 @@ class ActiveModel::Type::Value # # @return [Boolean] # - # source://activemodel//lib/active_model/type/value.rb#65 + # source://activemodel//lib/active_model/type/value.rb#77 def binary?; end # Type casts a value from user input (e.g. from a setter). This value may @@ -4188,7 +4871,7 @@ class ActiveModel::Type::Value # # +value+ The raw input, as provided to the attribute setter. # - # source://activemodel//lib/active_model/type/value.rb#45 + # source://activemodel//lib/active_model/type/value.rb#57 def cast(value); end # Determines whether a value has changed for dirty checking. +old_value+ @@ -4197,7 +4880,7 @@ class ActiveModel::Type::Value # # @return [Boolean] # - # source://activemodel//lib/active_model/type/value.rb#72 + # source://activemodel//lib/active_model/type/value.rb#84 def changed?(old_value, new_value, _new_value_before_type_cast); end # Determines whether the mutable value has been modified since it was @@ -4220,7 +4903,7 @@ class ActiveModel::Type::Value # # @return [Boolean] # - # source://activemodel//lib/active_model/type/value.rb#93 + # source://activemodel//lib/active_model/type/value.rb#105 def changed_in_place?(raw_old_value, new_value); end # Converts a value from database input to the appropriate ruby type. The @@ -4230,41 +4913,43 @@ class ActiveModel::Type::Value # # +value+ The raw input, as provided from the database. # - # source://activemodel//lib/active_model/type/value.rb#31 + # source://activemodel//lib/active_model/type/value.rb#43 def deserialize(value); end - # source://activemodel//lib/active_model/type/value.rb#109 + # source://activemodel//lib/active_model/type/value.rb#121 def eql?(other); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/value.rb#101 + # source://activemodel//lib/active_model/type/value.rb#113 def force_equality?(_value); end - # source://activemodel//lib/active_model/type/value.rb#117 + # source://activemodel//lib/active_model/type/value.rb#129 def hash; end - # source://activemodel//lib/active_model/type/value.rb#124 - def immutable_value(value); end - # Returns the value of attribute limit. # - # source://activemodel//lib/active_model/type/value.rb#6 + # source://activemodel//lib/active_model/type/value.rb#11 def limit; end # @yield [value] # - # source://activemodel//lib/active_model/type/value.rb#105 + # source://activemodel//lib/active_model/type/value.rb#117 def map(value); end + # @return [Boolean] + # + # source://activemodel//lib/active_model/type/value.rb#140 + def mutable?; end + # Returns the value of attribute precision. # - # source://activemodel//lib/active_model/type/value.rb#6 + # source://activemodel//lib/active_model/type/value.rb#11 def precision; end # Returns the value of attribute scale. # - # source://activemodel//lib/active_model/type/value.rb#6 + # source://activemodel//lib/active_model/type/value.rb#11 def scale; end # Returns true if this type can convert +value+ to a type that is usable @@ -4274,7 +4959,7 @@ class ActiveModel::Type::Value # # @return [Boolean] # - # source://activemodel//lib/active_model/type/value.rb#18 + # source://activemodel//lib/active_model/type/value.rb#28 def serializable?(value); end # Casts a value from the ruby type to a type that the database knows how @@ -4282,21 +4967,29 @@ class ActiveModel::Type::Value # +String+, +Numeric+, +Date+, +Time+, +Symbol+, +true+, +false+, or # +nil+. # - # source://activemodel//lib/active_model/type/value.rb#53 + # source://activemodel//lib/active_model/type/value.rb#65 def serialize(value); end - # source://activemodel//lib/active_model/type/value.rb#22 + # @return [Boolean] + # + # source://activemodel//lib/active_model/type/value.rb#136 + def serialized?; end + + # Returns the unique type name as a Symbol. Subclasses should override + # this method. + # + # source://activemodel//lib/active_model/type/value.rb#34 def type; end # Type casts a value for schema dumping. This method is private, as we are # hoping to remove it entirely. # - # source://activemodel//lib/active_model/type/value.rb#59 + # source://activemodel//lib/active_model/type/value.rb#71 def type_cast_for_schema(value); end # @return [Boolean] # - # source://activemodel//lib/active_model/type/value.rb#97 + # source://activemodel//lib/active_model/type/value.rb#109 def value_constructed_by_mass_assignment?(_value); end private @@ -4305,10 +4998,12 @@ class ActiveModel::Type::Value # behavior for user and database inputs. Called by Value#cast for # values except +nil+. # - # source://activemodel//lib/active_model/type/value.rb#132 + # source://activemodel//lib/active_model/type/value.rb#152 def cast_value(value); end end +# = Active \Model \UnknownAttributeError +# # Raised when unknown attributes are supplied via mass assignment. # # class Person @@ -4320,21 +5015,21 @@ end # person.assign_attributes(name: 'Gorby') # # => ActiveModel::UnknownAttributeError: unknown attribute 'name' for Person. # -# source://activemodel//lib/active_model/errors.rb#507 +# source://activemodel//lib/active_model/errors.rb#538 class ActiveModel::UnknownAttributeError < ::NoMethodError # @return [UnknownAttributeError] a new instance of UnknownAttributeError # - # source://activemodel//lib/active_model/errors.rb#510 + # source://activemodel//lib/active_model/errors.rb#541 def initialize(record, attribute); end # Returns the value of attribute attribute. # - # source://activemodel//lib/active_model/errors.rb#508 + # source://activemodel//lib/active_model/errors.rb#539 def attribute; end # Returns the value of attribute record. # - # source://activemodel//lib/active_model/errors.rb#508 + # source://activemodel//lib/active_model/errors.rb#539 def record; end end @@ -4356,7 +5051,7 @@ ActiveModel::VERSION::STRING = T.let(T.unsafe(nil), String) # source://activemodel//lib/active_model/gem_version.rb#12 ActiveModel::VERSION::TINY = T.let(T.unsafe(nil), Integer) -# = Active Model ValidationError +# = Active \Model \ValidationError # # Raised by validate! when the model is invalid. Use the # +model+ method to retrieve the record which did not validate. @@ -4367,20 +5062,20 @@ ActiveModel::VERSION::TINY = T.let(T.unsafe(nil), Integer) # puts invalid.model.errors # end # -# source://activemodel//lib/active_model/validations.rb#425 +# source://activemodel//lib/active_model/validations.rb#460 class ActiveModel::ValidationError < ::StandardError # @return [ValidationError] a new instance of ValidationError # - # source://activemodel//lib/active_model/validations.rb#428 + # source://activemodel//lib/active_model/validations.rb#463 def initialize(model); end # Returns the value of attribute model. # - # source://activemodel//lib/active_model/validations.rb#426 + # source://activemodel//lib/active_model/validations.rb#461 def model; end end -# == Active \Model \Validations +# = Active \Model \Validations # # Provides a full validation framework to your objects. # @@ -4408,7 +5103,7 @@ end # person.invalid? # => true # person.errors.messages # => {first_name:["starts with z."]} # -# Note that ActiveModel::Validations automatically adds an +errors+ +# Note that +ActiveModel::Validations+ automatically adds an +errors+ # method to your instances initialized with a new ActiveModel::Errors # object, so there is no need for you to do this manually. # @@ -4427,7 +5122,7 @@ module ActiveModel::Validations mixes_in_class_methods ::ActiveModel::Translation mixes_in_class_methods ::ActiveModel::Validations::HelperMethods - # source://rspec-collection_matchers/1.2.0/lib/rspec/collection_matchers/rails_extensions.rb#17 + # source://rspec-collection_matchers/1.2.1/lib/rspec/collection_matchers/rails_extensions.rb#17 def error_on(attribute, options = T.unsafe(nil)); end # Returns the +Errors+ object that holds all information about attribute @@ -4444,10 +5139,10 @@ module ActiveModel::Validations # person.valid? # => false # person.errors # => # # - # source://activemodel//lib/active_model/validations.rb#301 + # source://activemodel//lib/active_model/validations.rb#330 def errors; end - # source://rspec-collection_matchers/1.2.0/lib/rspec/collection_matchers/rails_extensions.rb#17 + # source://rspec-collection_matchers/1.2.1/lib/rspec/collection_matchers/rails_extensions.rb#17 def errors_on(attribute, options = T.unsafe(nil)); end # Performs the opposite of valid?. Returns +true+ if errors were @@ -4482,7 +5177,7 @@ module ActiveModel::Validations # # @return [Boolean] # - # source://activemodel//lib/active_model/validations.rb#373 + # source://activemodel//lib/active_model/validations.rb#402 def invalid?(context = T.unsafe(nil)); end # Hook method defining how an attribute value should be retrieved. By default @@ -4535,7 +5230,7 @@ module ActiveModel::Validations # # @return [Boolean] # - # source://activemodel//lib/active_model/validations.rb#334 + # source://activemodel//lib/active_model/validations.rb#363 def valid?(context = T.unsafe(nil)); end # Runs all the specified validations and returns +true+ if no errors were @@ -4570,7 +5265,7 @@ module ActiveModel::Validations # # @return [Boolean] # - # source://activemodel//lib/active_model/validations.rb#334 + # source://activemodel//lib/active_model/validations.rb#363 def validate(context = T.unsafe(nil)); end # Runs all the validations within the specified context. Returns +true+ if @@ -4579,7 +5274,7 @@ module ActiveModel::Validations # Validations with no :on option will run no matter the context. Validations with # some :on option will only run in the specified context. # - # source://activemodel//lib/active_model/validations.rb#382 + # source://activemodel//lib/active_model/validations.rb#411 def validate!(context = T.unsafe(nil)); end # Passes the record off to the class or classes specified and allows them @@ -4619,22 +5314,25 @@ module ActiveModel::Validations # to the class and available as +options+, please refer to the # class version of this method for more information. # - # source://activemodel//lib/active_model/validations/with.rb#137 + # source://activemodel//lib/active_model/validations/with.rb#144 def validates_with(*args, &block); end private + # source://activemodel//lib/active_model/validations.rb#434 + def init_internals; end + # Clean the +Errors+ object if instance is duped. # - # source://activemodel//lib/active_model/validations.rb#283 + # source://activemodel//lib/active_model/validations.rb#312 def initialize_dup(other); end # @raise [ValidationError] # - # source://activemodel//lib/active_model/validations.rb#410 + # source://activemodel//lib/active_model/validations.rb#445 def raise_validation_error; end - # source://activemodel//lib/active_model/validations.rb#405 + # source://activemodel//lib/active_model/validations.rb#440 def run_validations!; end module GeneratedClassMethods @@ -4712,12 +5410,12 @@ class ActiveModel::Validations::AcceptanceValidator::LazilyDefineAttributes < :: def attributes; end end -# == Active \Model \Validation \Callbacks +# = Active \Model \Validation \Callbacks # -# Provides an interface for any class to have +before_validation+ and -# +after_validation+ callbacks. +# Provides an interface for any class to have ClassMethods#before_validation and +# ClassMethods#after_validation callbacks. # -# First, include ActiveModel::Validations::Callbacks from the class you are +# First, include +ActiveModel::Validations::Callbacks+ from the class you are # creating: # # class MyModel @@ -4823,7 +5521,7 @@ module ActiveModel::Validations::Callbacks::ClassMethods def set_options_for_callback(options); end end -# source://activemodel//lib/active_model/validations.rb#55 +# source://activemodel//lib/active_model/validations.rb#74 module ActiveModel::Validations::ClassMethods # Returns +true+ if +attribute+ is an attribute method, +false+ otherwise. # @@ -4838,7 +5536,7 @@ module ActiveModel::Validations::ClassMethods # # @return [Boolean] # - # source://activemodel//lib/active_model/validations.rb#270 + # source://activemodel//lib/active_model/validations.rb#284 def attribute_method?(attribute); end # Clears all of the validators and validations. @@ -4879,12 +5577,12 @@ module ActiveModel::Validations::ClassMethods # # Person._validate_callbacks.empty? # => true # - # source://activemodel//lib/active_model/validations.rb#234 + # source://activemodel//lib/active_model/validations.rb#248 def clear_validators!; end # Copy validators on inheritance. # - # source://activemodel//lib/active_model/validations.rb#275 + # source://activemodel//lib/active_model/validations.rb#289 def inherited(base); end # Adds a validation method or block to the class. This is useful when @@ -4948,15 +5646,15 @@ module ActiveModel::Validations::ClassMethods # # NOTE: Calling +validate+ multiple times on the same method will overwrite previous definitions. # - # source://activemodel//lib/active_model/validations.rb#152 + # source://activemodel//lib/active_model/validations.rb#171 def validate(*args, &block); end # This method is a shortcut to all default validators and any custom - # validator classes ending in 'Validator'. Note that Rails default + # validator classes ending in 'Validator'. Note that \Rails default # validators can be overridden inside specific classes by creating # custom validator classes in their place such as PresenceValidator. # - # Examples of using the default rails validators: + # Examples of using the default Rails validators: # # validates :username, absence: true # validates :terms, acceptance: true @@ -5058,7 +5756,7 @@ module ActiveModel::Validations::ClassMethods # This method is used to define validations that cannot be corrected by end # users and are considered exceptional. So each validator defined with bang # or :strict option set to true will always raise - # ActiveModel::StrictValidationFailed instead of adding error + # ActiveModel::StrictValidationFailed instead of adding error # when validation fails. See validates for more information about # the validation itself. # @@ -5107,7 +5805,7 @@ module ActiveModel::Validations::ClassMethods # method, proc, or string should return or evaluate to a +true+ or +false+ # value. # - # source://activemodel//lib/active_model/validations.rb#85 + # source://activemodel//lib/active_model/validations.rb#104 def validates_each(*attr_names, &block); end # Passes the record off to the class or classes specified and allows them @@ -5138,6 +5836,13 @@ module ActiveModel::Validations::ClassMethods # validates_with MyValidator, MyOtherValidator, on: :create # end # + # There is no default error message for +validates_with+. You must + # manually add errors to the record's errors collection in the validator + # class. + # + # To implement the validate method, you must have a +record+ parameter + # defined, which is the record to be validated. + # # Configuration options: # * :on - Specifies the contexts where this validation is active. # Runs in all validation contexts by default +nil+. You can pass a symbol @@ -5172,7 +5877,7 @@ module ActiveModel::Validations::ClassMethods # end # end # - # source://activemodel//lib/active_model/validations/with.rb#81 + # source://activemodel//lib/active_model/validations/with.rb#88 def validates_with(*args, &block); end # List all validators that are being used to validate the model using @@ -5193,7 +5898,7 @@ module ActiveModel::Validations::ClassMethods # # # # # ] # - # source://activemodel//lib/active_model/validations.rb#192 + # source://activemodel//lib/active_model/validations.rb#206 def validators; end # List all validators that are being used to validate a specific attribute. @@ -5212,7 +5917,7 @@ module ActiveModel::Validations::ClassMethods # # #, # # ] # - # source://activemodel//lib/active_model/validations.rb#254 + # source://activemodel//lib/active_model/validations.rb#268 def validators_on(*attributes); end private @@ -5225,24 +5930,29 @@ module ActiveModel::Validations::ClassMethods # # source://activemodel//lib/active_model/validations/validates.rb#157 def _validates_default_keys; end + + # source://activemodel//lib/active_model/validations.rb#298 + def predicate_for_validation_context(context); end end -# source://activemodel//lib/active_model/validations.rb#89 +# source://activemodel//lib/active_model/validations.rb#108 ActiveModel::Validations::ClassMethods::VALID_OPTIONS_FOR_VALIDATE = T.let(T.unsafe(nil), Array) -# source://activemodel//lib/active_model/validations/clusivity.rb#7 +# source://activemodel//lib/active_model/validations/clusivity.rb#8 module ActiveModel::Validations::Clusivity - # source://activemodel//lib/active_model/validations/clusivity.rb#11 + include ::ActiveModel::Validations::ResolveValue + + # source://activemodel//lib/active_model/validations/clusivity.rb#14 def check_validity!; end private - # source://activemodel//lib/active_model/validations/clusivity.rb#34 + # source://activemodel//lib/active_model/validations/clusivity.rb#31 def delimiter; end # @return [Boolean] # - # source://activemodel//lib/active_model/validations/clusivity.rb#18 + # source://activemodel//lib/active_model/validations/clusivity.rb#21 def include?(record, value); end # After Ruby 2.2, Range#include? on non-number-or-time-ish ranges checks all @@ -5251,33 +5961,31 @@ module ActiveModel::Validations::Clusivity # endpoints, which is fast but is only accurate on Numeric, Time, Date, # or DateTime ranges. # - # source://activemodel//lib/active_model/validations/clusivity.rb#43 + # source://activemodel//lib/active_model/validations/clusivity.rb#40 def inclusion_method(enumerable); end end -# source://activemodel//lib/active_model/validations/clusivity.rb#8 +# source://activemodel//lib/active_model/validations/clusivity.rb#11 ActiveModel::Validations::Clusivity::ERROR_MESSAGE = T.let(T.unsafe(nil), String) # source://activemodel//lib/active_model/validations/comparability.rb#5 module ActiveModel::Validations::Comparability - # source://activemodel//lib/active_model/validations/comparability.rb#21 - def error_options(value, option_value); end - # source://activemodel//lib/active_model/validations/comparability.rb#10 - def option_value(record, option_value); end + def error_options(value, option_value); end end # source://activemodel//lib/active_model/validations/comparability.rb#6 ActiveModel::Validations::Comparability::COMPARE_CHECKS = T.let(T.unsafe(nil), Hash) -# source://activemodel//lib/active_model/validations/comparison.rb#7 +# source://activemodel//lib/active_model/validations/comparison.rb#8 class ActiveModel::Validations::ComparisonValidator < ::ActiveModel::EachValidator include ::ActiveModel::Validations::Comparability + include ::ActiveModel::Validations::ResolveValue - # source://activemodel//lib/active_model/validations/comparison.rb#10 + # source://activemodel//lib/active_model/validations/comparison.rb#12 def check_validity!; end - # source://activemodel//lib/active_model/validations/comparison.rb#17 + # source://activemodel//lib/active_model/validations/comparison.rb#19 def validate_each(record, attr_name, value); end end @@ -5304,41 +6012,41 @@ end # source://activemodel//lib/active_model/validations/exclusion.rb#7 class ActiveModel::Validations::ExclusionValidator < ::ActiveModel::EachValidator + include ::ActiveModel::Validations::ResolveValue include ::ActiveModel::Validations::Clusivity # source://activemodel//lib/active_model/validations/exclusion.rb#10 def validate_each(record, attribute, value); end end -# source://activemodel//lib/active_model/validations/format.rb#5 +# source://activemodel//lib/active_model/validations/format.rb#7 class ActiveModel::Validations::FormatValidator < ::ActiveModel::EachValidator - # source://activemodel//lib/active_model/validations/format.rb#16 + include ::ActiveModel::Validations::ResolveValue + + # source://activemodel//lib/active_model/validations/format.rb#20 def check_validity!; end - # source://activemodel//lib/active_model/validations/format.rb#6 + # source://activemodel//lib/active_model/validations/format.rb#10 def validate_each(record, attribute, value); end private - # source://activemodel//lib/active_model/validations/format.rb#35 + # source://activemodel//lib/active_model/validations/format.rb#34 def check_options_validity(name); end - # source://activemodel//lib/active_model/validations/format.rb#26 - def option_call(record, name); end - - # source://activemodel//lib/active_model/validations/format.rb#31 + # source://activemodel//lib/active_model/validations/format.rb#30 def record_error(record, attribute, name, value); end # @return [Boolean] # - # source://activemodel//lib/active_model/validations/format.rb#49 + # source://activemodel//lib/active_model/validations/format.rb#48 def regexp_using_multiline_anchors?(regexp); end end # source://activemodel//lib/active_model/validations/absence.rb#12 module ActiveModel::Validations::HelperMethods # Validates that the specified attributes are blank (as defined by - # Object#present?). Happens by default on save. + # Object#present?). # # class Person < ActiveRecord::Base # validates_absence_of :first_name @@ -5366,7 +6074,7 @@ module ActiveModel::Validations::HelperMethods # # If the database column does not exist, the +terms_of_service+ attribute # is entirely virtual. This check is performed only if +terms_of_service+ - # is not +nil+ and by default on save. + # is not +nil+. # # Configuration options: # * :message - A custom error message (default is: "must be @@ -5395,17 +6103,23 @@ module ActiveModel::Validations::HelperMethods # Configuration options: # * :message - A custom error message (default is: "failed comparison"). # * :greater_than - Specifies the value must be greater than the - # supplied value. + # supplied value. The default error message for this option is _"must be + # greater than %{count}"_. # * :greater_than_or_equal_to - Specifies the value must be - # greater than or equal to the supplied value. + # greater than or equal to the supplied value. The default error message + # for this option is _"must be greater than or equal to %{count}"_. # * :equal_to - Specifies the value must be equal to the supplied - # value. + # value. The default error message for this option is _"must be equal to + # %{count}"_. # * :less_than - Specifies the value must be less than the - # supplied value. + # supplied value. The default error message for this option is _"must be + # less than %{count}"_. # * :less_than_or_equal_to - Specifies the value must be less - # than or equal to the supplied value. + # than or equal to the supplied value. The default error message for + # this option is _"must be less than or equal to %{count}"_. # * :other_than - Specifies the value must not be equal to the - # supplied value. + # supplied value. The default error message for this option is _"must be + # other than %{count}"_. # # There is also a list of default options supported by every validator: # +:if+, +:unless+, +:on+, +:allow_nil+, +:allow_blank+, and +:strict+ . @@ -5428,7 +6142,7 @@ module ActiveModel::Validations::HelperMethods # validates_comparison_of :preferred_name, other_than: :given_name, allow_nil: true # end # - # source://activemodel//lib/active_model/validations/comparison.rb#77 + # source://activemodel//lib/active_model/validations/comparison.rb#85 def validates_comparison_of(*attr_names); end # Encapsulates the pattern of wanting to validate a password or email @@ -5552,7 +6266,7 @@ module ActiveModel::Validations::HelperMethods # +:if+, +:unless+, +:on+, +:allow_nil+, +:allow_blank+, and +:strict+. # See ActiveModel::Validations::ClassMethods#validates for more information. # - # source://activemodel//lib/active_model/validations/format.rb#108 + # source://activemodel//lib/active_model/validations/format.rb#107 def validates_format_of(*attr_names); end # Validates whether the value of the specified attribute is available in a @@ -5632,14 +6346,15 @@ module ActiveModel::Validations::HelperMethods # +:if+, +:unless+, +:on+, and +:strict+. # See ActiveModel::Validations::ClassMethods#validates for more information. # - # source://activemodel//lib/active_model/validations/length.rb#121 + # source://activemodel//lib/active_model/validations/length.rb#123 def validates_length_of(*attr_names); end # Validates whether the value of the specified attribute is numeric by - # trying to convert it to a float with Kernel.Float (if only_integer - # is +false+) or applying it to the regular expression /\A[\+\-]?\d+\z/ - # (if only_integer is set to +true+). Precision of Kernel.Float values - # are guaranteed up to 15 digits. + # trying to convert it to a float with +Kernel.Float+ (if + # only_integer is +false+) or applying it to the regular + # expression /\A[\+\-]?\d+\z/ (if only_integer is set to + # +true+). Precision of +Kernel.Float+ values are guaranteed up to 15 + # digits. # # class Person < ActiveRecord::Base # validates_numericality_of :value, on: :create @@ -5649,24 +6364,36 @@ module ActiveModel::Validations::HelperMethods # * :message - A custom error message (default is: "is not a number"). # * :only_integer - Specifies whether the value has to be an # integer (default is +false+). + # * :only_numeric - Specifies whether the value has to be an + # instance of Numeric (default is +false+). The default behavior is to + # attempt parsing the value if it is a String. # * :allow_nil - Skip validation if attribute is +nil+ (default is # +false+). Notice that for Integer and Float columns empty strings are # converted to +nil+. # * :greater_than - Specifies the value must be greater than the - # supplied value. + # supplied value. The default error message for this option is _"must be + # greater than %{count}"_. # * :greater_than_or_equal_to - Specifies the value must be - # greater than or equal the supplied value. + # greater than or equal the supplied value. The default error message + # for this option is _"must be greater than or equal to %{count}"_. # * :equal_to - Specifies the value must be equal to the supplied - # value. + # value. The default error message for this option is _"must be equal to + # %{count}"_. # * :less_than - Specifies the value must be less than the - # supplied value. + # supplied value. The default error message for this option is _"must be + # less than %{count}"_. # * :less_than_or_equal_to - Specifies the value must be less - # than or equal the supplied value. + # than or equal the supplied value. The default error message for this + # option is _"must be less than or equal to %{count}"_. # * :other_than - Specifies the value must be other than the - # supplied value. - # * :odd - Specifies the value must be an odd number. - # * :even - Specifies the value must be an even number. - # * :in - Check that the value is within a range. + # supplied value. The default error message for this option is _"must be + # other than %{count}"_. + # * :odd - Specifies the value must be an odd number. The default + # error message for this option is _"must be odd"_. + # * :even - Specifies the value must be an even number. The + # default error message for this option is _"must be even"_. + # * :in - Check that the value is within a range. The default + # error message for this option is _"must be in %{count}"_. # # There is also a list of default options supported by every validator: # +:if+, +:unless+, +:on+, +:allow_nil+, +:allow_blank+, and +:strict+ . @@ -5690,11 +6417,11 @@ module ActiveModel::Validations::HelperMethods # validates_numericality_of :width, greater_than: :minimum_weight # end # - # source://activemodel//lib/active_model/validations/numericality.rb#205 + # source://activemodel//lib/active_model/validations/numericality.rb#217 def validates_numericality_of(*attr_names); end # Validates that the specified attributes are not blank (as defined by - # Object#blank?). Happens by default on save. + # Object#blank?). # # class Person < ActiveRecord::Base # validates_presence_of :first_name @@ -5768,7 +6495,7 @@ module ActiveModel::Validations::HelperMethods # +:if+, +:unless+, +:on+, and +:strict+. # See ActiveModel::Validations::ClassMethods#validates for more information. # - # source://activemodel//lib/active_model/validations/length.rb#121 + # source://activemodel//lib/active_model/validations/length.rb#123 def validates_size_of(*attr_names); end private @@ -5779,111 +6506,115 @@ end # source://activemodel//lib/active_model/validations/inclusion.rb#7 class ActiveModel::Validations::InclusionValidator < ::ActiveModel::EachValidator + include ::ActiveModel::Validations::ResolveValue include ::ActiveModel::Validations::Clusivity # source://activemodel//lib/active_model/validations/inclusion.rb#10 def validate_each(record, attribute, value); end end -# source://activemodel//lib/active_model/validations/length.rb#5 +# source://activemodel//lib/active_model/validations/length.rb#7 class ActiveModel::Validations::LengthValidator < ::ActiveModel::EachValidator + include ::ActiveModel::Validations::ResolveValue + # @return [LengthValidator] a new instance of LengthValidator # - # source://activemodel//lib/active_model/validations/length.rb#11 + # source://activemodel//lib/active_model/validations/length.rb#15 def initialize(options); end - # source://activemodel//lib/active_model/validations/length.rb#24 + # source://activemodel//lib/active_model/validations/length.rb#29 def check_validity!; end - # source://activemodel//lib/active_model/validations/length.rb#40 + # source://activemodel//lib/active_model/validations/length.rb#47 def validate_each(record, attribute, value); end private # @return [Boolean] # - # source://activemodel//lib/active_model/validations/length.rb#67 + # source://activemodel//lib/active_model/validations/length.rb#69 def skip_nil_check?(key); end end -# source://activemodel//lib/active_model/validations/length.rb#7 +# source://activemodel//lib/active_model/validations/length.rb#11 ActiveModel::Validations::LengthValidator::CHECKS = T.let(T.unsafe(nil), Hash) -# source://activemodel//lib/active_model/validations/length.rb#6 +# source://activemodel//lib/active_model/validations/length.rb#10 ActiveModel::Validations::LengthValidator::MESSAGES = T.let(T.unsafe(nil), Hash) -# source://activemodel//lib/active_model/validations/length.rb#9 +# source://activemodel//lib/active_model/validations/length.rb#13 ActiveModel::Validations::LengthValidator::RESERVED_OPTIONS = T.let(T.unsafe(nil), Array) -# source://activemodel//lib/active_model/validations/numericality.rb#8 +# source://activemodel//lib/active_model/validations/numericality.rb#9 class ActiveModel::Validations::NumericalityValidator < ::ActiveModel::EachValidator include ::ActiveModel::Validations::Comparability + include ::ActiveModel::Validations::ResolveValue - # source://activemodel//lib/active_model/validations/numericality.rb#20 + # source://activemodel//lib/active_model/validations/numericality.rb#22 def check_validity!; end - # source://activemodel//lib/active_model/validations/numericality.rb#34 + # source://activemodel//lib/active_model/validations/numericality.rb#36 def validate_each(record, attr_name, value, precision: T.unsafe(nil), scale: T.unsafe(nil)); end private # @return [Boolean] # - # source://activemodel//lib/active_model/validations/numericality.rb#112 + # source://activemodel//lib/active_model/validations/numericality.rb#118 def allow_only_integer?(record); end - # source://activemodel//lib/active_model/validations/numericality.rb#106 + # source://activemodel//lib/active_model/validations/numericality.rb#112 def filtered_options(value); end # @return [Boolean] # - # source://activemodel//lib/active_model/validations/numericality.rb#102 + # source://activemodel//lib/active_model/validations/numericality.rb#108 def is_hexadecimal_literal?(raw_value); end # @return [Boolean] # - # source://activemodel//lib/active_model/validations/numericality.rb#98 + # source://activemodel//lib/active_model/validations/numericality.rb#104 def is_integer?(raw_value); end # @return [Boolean] # - # source://activemodel//lib/active_model/validations/numericality.rb#92 + # source://activemodel//lib/active_model/validations/numericality.rb#94 def is_number?(raw_value, precision, scale); end - # source://activemodel//lib/active_model/validations/numericality.rb#66 + # source://activemodel//lib/active_model/validations/numericality.rb#68 def option_as_number(record, option_value, precision, scale); end - # source://activemodel//lib/active_model/validations/numericality.rb#70 + # source://activemodel//lib/active_model/validations/numericality.rb#72 def parse_as_number(raw_value, precision, scale); end - # source://activemodel//lib/active_model/validations/numericality.rb#84 + # source://activemodel//lib/active_model/validations/numericality.rb#86 def parse_float(raw_value, precision, scale); end - # source://activemodel//lib/active_model/validations/numericality.rb#123 + # source://activemodel//lib/active_model/validations/numericality.rb#122 def prepare_value_for_validation(value, record, attr_name); end # @return [Boolean] # - # source://activemodel//lib/active_model/validations/numericality.rb#144 + # source://activemodel//lib/active_model/validations/numericality.rb#143 def record_attribute_changed_in_place?(record, attr_name); end - # source://activemodel//lib/active_model/validations/numericality.rb#88 + # source://activemodel//lib/active_model/validations/numericality.rb#90 def round(raw_value, scale); end end -# source://activemodel//lib/active_model/validations/numericality.rb#18 +# source://activemodel//lib/active_model/validations/numericality.rb#20 ActiveModel::Validations::NumericalityValidator::HEXADECIMAL_REGEX = T.let(T.unsafe(nil), Regexp) -# source://activemodel//lib/active_model/validations/numericality.rb#16 +# source://activemodel//lib/active_model/validations/numericality.rb#18 ActiveModel::Validations::NumericalityValidator::INTEGER_REGEX = T.let(T.unsafe(nil), Regexp) -# source://activemodel//lib/active_model/validations/numericality.rb#12 +# source://activemodel//lib/active_model/validations/numericality.rb#14 ActiveModel::Validations::NumericalityValidator::NUMBER_CHECKS = T.let(T.unsafe(nil), Hash) -# source://activemodel//lib/active_model/validations/numericality.rb#11 +# source://activemodel//lib/active_model/validations/numericality.rb#13 ActiveModel::Validations::NumericalityValidator::RANGE_CHECKS = T.let(T.unsafe(nil), Hash) -# source://activemodel//lib/active_model/validations/numericality.rb#14 +# source://activemodel//lib/active_model/validations/numericality.rb#16 ActiveModel::Validations::NumericalityValidator::RESERVED_OPTIONS = T.let(T.unsafe(nil), Array) # source://activemodel//lib/active_model/validations/presence.rb#5 @@ -5892,13 +6623,19 @@ class ActiveModel::Validations::PresenceValidator < ::ActiveModel::EachValidator def validate_each(record, attr_name, value); end end +# source://activemodel//lib/active_model/validations/resolve_value.rb#5 +module ActiveModel::Validations::ResolveValue + # source://activemodel//lib/active_model/validations/resolve_value.rb#6 + def resolve_value(record, value); end +end + # source://activemodel//lib/active_model/validations/with.rb#7 class ActiveModel::Validations::WithValidator < ::ActiveModel::EachValidator # source://activemodel//lib/active_model/validations/with.rb#8 def validate_each(record, attr, val); end end -# == Active \Model \Validator +# = Active \Model \Validator # # A simple base class that can be used along with # ActiveModel::Validations::ClassMethods.validates_with @@ -5921,7 +6658,7 @@ end # end # end # -# Any class that inherits from ActiveModel::Validator must implement a method +# Any class that inherits from \ActiveModel::Validator must implement a method # called +validate+ which accepts a +record+. # # class Person @@ -5960,7 +6697,7 @@ end # life cycle, and not on each validation run. # # The easiest way to add custom validators for validating individual attributes -# is with the convenient ActiveModel::EachValidator. +# is with the convenient ActiveModel::EachValidator class. # # class TitleValidator < ActiveModel::EachValidator # def validate_each(record, attribute, value) @@ -5968,8 +6705,8 @@ end # end # end # -# This can now be used in combination with the +validates+ method -# (see ActiveModel::Validations::ClassMethods#validates for more on this). +# This can now be used in combination with the +validates+ method. +# See ActiveModel::Validations::ClassMethods#validates for more on this. # # class Person # include ActiveModel::Validations diff --git a/sorbet/rbi/gems/activerecord@7.0.5.rbi b/sorbet/rbi/gems/activerecord@7.2.0.rbi similarity index 75% rename from sorbet/rbi/gems/activerecord@7.0.5.rbi rename to sorbet/rbi/gems/activerecord@7.2.0.rbi index 1e3f16b09..05f922ea3 100644 --- a/sorbet/rbi/gems/activerecord@7.0.5.rbi +++ b/sorbet/rbi/gems/activerecord@7.2.0.rbi @@ -4,203 +4,330 @@ # This is an autogenerated file for types exported from the `activerecord` gem. # Please instead update this file by running `bin/tapioca gem activerecord`. + +# :include: ../README.rdoc +# # source://activerecord//lib/active_record/gem_version.rb#3 module ActiveRecord + include ::ActiveSupport::Deprecation::DeprecatedConstantAccessor extend ::ActiveSupport::Autoload class << self - # source://activerecord//lib/active_record.rb#277 + # source://activerecord//lib/active_record.rb#377 def action_on_strict_loading_violation; end - # source://activerecord//lib/active_record.rb#277 + # source://activerecord//lib/active_record.rb#377 def action_on_strict_loading_violation=(_arg0); end - # source://activerecord//lib/active_record.rb#270 + # Registers a block to be called after all the current transactions have been + # committed. + # + # If there is no currently open transaction, the block is called immediately. + # + # If there are multiple nested transactions, the block is called after the outermost one + # has been committed, + # + # If any of the currently open transactions is rolled back, the block is never called. + # + # If multiple transactions are open across multiple databases, the block will be invoked + # if and once all of them have been committed. But note that nesting transactions across + # two distinct databases is a sharding anti-pattern that comes with a world of hurts. + # + # source://activerecord//lib/active_record.rb#557 + def after_all_transactions_commit(&block); end + + # source://activerecord//lib/active_record.rb#577 + def all_open_transactions; end + + # source://activerecord//lib/active_record.rb#447 + def allow_deprecated_singular_associations_name; end + + # source://activerecord//lib/active_record.rb#454 + def allow_deprecated_singular_associations_name=(value); end + + # source://activerecord//lib/active_record.rb#370 def application_record_class; end - # source://activerecord//lib/active_record.rb#270 + # source://activerecord//lib/active_record.rb#370 def application_record_class=(_arg0); end - # source://activerecord//lib/active_record.rb#213 + # source://activerecord//lib/active_record.rb#276 def async_query_executor; end - # source://activerecord//lib/active_record.rb#213 + # source://activerecord//lib/active_record.rb#276 def async_query_executor=(_arg0); end - # source://activerecord//lib/active_record.rb#183 + # source://activerecord//lib/active_record.rb#341 + def before_committed_on_all_records; end + + # source://activerecord//lib/active_record.rb#341 + def before_committed_on_all_records=(_arg0); end + + # source://activerecord//lib/active_record.rb#338 + def belongs_to_required_validates_foreign_key; end + + # source://activerecord//lib/active_record.rb#338 + def belongs_to_required_validates_foreign_key=(_arg0); end + + # source://activerecord//lib/active_record.rb#347 + def commit_transaction_on_non_local_return; end + + # source://activerecord//lib/active_record.rb#354 + def commit_transaction_on_non_local_return=(value); end + + # source://activerecord//lib/active_record.rb#218 + def db_warnings_action; end + + # source://activerecord//lib/active_record.rb#220 + def db_warnings_action=(action); end + + # source://activerecord//lib/active_record.rb#247 + def db_warnings_ignore; end + + # source://activerecord//lib/active_record.rb#247 + def db_warnings_ignore=(_arg0); end + + # source://activerecord//lib/active_record.rb#199 def default_timezone; end # Determines whether to use Time.utc (using :utc) or Time.local (using :local) when pulling # dates and times from the database. This is set to :utc by default. # - # source://activerecord//lib/active_record.rb#187 + # source://activerecord//lib/active_record.rb#203 def default_timezone=(default_timezone); end - # source://activerecord//lib/active_record.rb#311 + # source://activerecord//lib/active_record/deprecator.rb#4 + def deprecator; end + + # source://activerecord//lib/active_record.rb#181 + def disable_prepared_statements; end + + # source://activerecord//lib/active_record.rb#181 + def disable_prepared_statements=(_arg0); end + + # Explicitly closes all database connections in all pools. + # + # source://activerecord//lib/active_record.rb#540 + def disconnect_all!; end + + # source://activerecord//lib/active_record.rb#425 def dump_schema_after_migration; end - # source://activerecord//lib/active_record.rb#311 + # source://activerecord//lib/active_record.rb#425 def dump_schema_after_migration=(_arg0); end - # source://activerecord//lib/active_record.rb#321 + # source://activerecord//lib/active_record.rb#435 def dump_schemas; end - # source://activerecord//lib/active_record.rb#321 + # source://activerecord//lib/active_record.rb#435 def dump_schemas=(_arg0); end - # source://activerecord//lib/active_record.rb#365 + # source://activerecord//lib/active_record.rb#529 def eager_load!; end - # source://activerecord//lib/active_record.rb#296 + # source://activerecord//lib/active_record.rb#396 def error_on_ignored_order; end - # source://activerecord//lib/active_record.rb#296 + # source://activerecord//lib/active_record.rb#396 def error_on_ignored_order=(_arg0); end - # Returns the currently loaded version of Active Record as a Gem::Version. + # Returns the currently loaded version of Active Record as a +Gem::Version+. # # source://activerecord//lib/active_record/gem_version.rb#5 def gem_version; end - # source://activerecord//lib/active_record.rb#236 + # source://activerecord//lib/active_record.rb#490 + def generate_secure_token_on; end + + # source://activerecord//lib/active_record.rb#490 + def generate_secure_token_on=(_arg0); end + + # source://activerecord//lib/active_record.rb#299 def global_executor_concurrency; end # Set the +global_executor_concurrency+. This configuration value can only be used # with the global thread pool async query executor. # - # source://activerecord//lib/active_record.rb#228 + # source://activerecord//lib/active_record.rb#291 def global_executor_concurrency=(global_executor_concurrency); end - # source://activerecord//lib/active_record.rb#216 + # source://activerecord//lib/active_record.rb#279 def global_thread_pool_async_query_executor; end - # source://activerecord//lib/active_record.rb#240 + # source://activerecord//lib/active_record.rb#314 def index_nested_attribute_errors; end - # source://activerecord//lib/active_record.rb#240 + # source://activerecord//lib/active_record.rb#314 def index_nested_attribute_errors=(_arg0); end - # source://activerecord//lib/active_record.rb#171 + # source://activerecord//lib/active_record.rb#188 def lazily_load_schema_cache; end - # source://activerecord//lib/active_record.rb#171 + # source://activerecord//lib/active_record.rb#188 def lazily_load_schema_cache=(_arg0); end - # source://activerecord//lib/active_record.rb#180 - def legacy_connection_handling; end - - # source://activerecord//lib/active_record.rb#180 - def legacy_connection_handling=(_arg0); end + # @raise [ArgumentError] + # + # source://activerecord//lib/active_record.rb#256 + def legacy_connection_handling=(_); end - # source://activerecord//lib/active_record.rb#258 + # source://activerecord//lib/active_record.rb#332 def maintain_test_schema; end - # source://activerecord//lib/active_record.rb#258 + # source://activerecord//lib/active_record.rb#332 def maintain_test_schema=(_arg0); end - # source://activerecord//lib/active_record.rb#340 + # source://activerecord//lib/active_record.rb#493 + def marshalling_format_version; end + + # source://activerecord//lib/active_record.rb#497 + def marshalling_format_version=(value); end + + # source://activerecord//lib/active_record.rb#416 + def migration_strategy; end + + # source://activerecord//lib/active_record.rb#416 + def migration_strategy=(_arg0); end + + # source://activerecord//lib/active_record.rb#304 + def permanent_connection_checkout; end + + # Defines whether +ActiveRecord::Base.connection+ is allowed, deprecated, or entirely disallowed. + # + # source://activerecord//lib/active_record.rb#307 + def permanent_connection_checkout=(value); end + + # source://activerecord//lib/active_record.rb#520 + def protocol_adapters; end + + # source://activerecord//lib/active_record.rb#520 + def protocol_adapters=(_arg0); end + + # source://activerecord//lib/active_record.rb#461 def query_transformers; end - # source://activerecord//lib/active_record.rb#340 + # source://activerecord//lib/active_record.rb#461 def query_transformers=(_arg0); end - # source://activerecord//lib/active_record.rb#255 + # source://activerecord//lib/active_record.rb#329 def queues; end - # source://activerecord//lib/active_record.rb#255 + # source://activerecord//lib/active_record.rb#329 def queues=(_arg0); end - # source://activerecord//lib/active_record.rb#355 + # source://activerecord//lib/active_record.rb#476 def raise_int_wider_than_64bit; end - # source://activerecord//lib/active_record.rb#355 + # source://activerecord//lib/active_record.rb#476 def raise_int_wider_than_64bit=(_arg0); end - # source://activerecord//lib/active_record.rb#200 + # source://activerecord//lib/active_record.rb#335 + def raise_on_assign_to_attr_readonly; end + + # source://activerecord//lib/active_record.rb#335 + def raise_on_assign_to_attr_readonly=(_arg0); end + + # source://activerecord//lib/active_record.rb#253 def reading_role; end - # source://activerecord//lib/active_record.rb#200 + # source://activerecord//lib/active_record.rb#253 def reading_role=(_arg0); end - # source://activerecord//lib/active_record.rb#177 + # source://activerecord//lib/active_record.rb#344 + def run_after_transaction_callbacks_in_order_defined; end + + # source://activerecord//lib/active_record.rb#344 + def run_after_transaction_callbacks_in_order_defined=(_arg0); end + + # source://activerecord//lib/active_record.rb#196 def schema_cache_ignored_tables; end - # source://activerecord//lib/active_record.rb#177 + # source://activerecord//lib/active_record.rb#196 def schema_cache_ignored_tables=(_arg0); end - # source://activerecord//lib/active_record.rb#288 + # source://activerecord//lib/active_record.rb#388 def schema_format; end - # source://activerecord//lib/active_record.rb#288 + # source://activerecord//lib/active_record.rb#388 def schema_format=(_arg0); end - # source://activerecord//lib/active_record.rb#328 - def suppress_multiple_database_warning; end - - # source://activerecord//lib/active_record.rb#328 - def suppress_multiple_database_warning=(_arg0); end - - # source://activerecord//lib/active_record.rb#302 + # source://activerecord//lib/active_record.rb#402 def timestamped_migrations; end - # source://activerecord//lib/active_record.rb#302 + # source://activerecord//lib/active_record.rb#402 def timestamped_migrations=(_arg0); end - # source://activerecord//lib/active_record.rb#347 + # source://activerecord//lib/active_record.rb#468 def use_yaml_unsafe_load; end - # source://activerecord//lib/active_record.rb#347 + # source://activerecord//lib/active_record.rb#468 def use_yaml_unsafe_load=(_arg0); end - # source://activerecord//lib/active_record.rb#248 + # source://activerecord//lib/active_record.rb#410 + def validate_migration_timestamps; end + + # source://activerecord//lib/active_record.rb#410 + def validate_migration_timestamps=(_arg0); end + + # source://activerecord//lib/active_record.rb#322 def verbose_query_logs; end - # source://activerecord//lib/active_record.rb#248 + # source://activerecord//lib/active_record.rb#322 def verbose_query_logs=(_arg0); end - # source://activerecord//lib/active_record.rb#337 + # source://activerecord//lib/active_record.rb#444 def verify_foreign_keys_for_fixtures; end - # source://activerecord//lib/active_record.rb#337 + # source://activerecord//lib/active_record.rb#444 def verify_foreign_keys_for_fixtures=(_arg0); end - # Returns the currently loaded version of Active Record as a Gem::Version. + # Returns the currently loaded version of Active Record as a +Gem::Version+. # # source://activerecord//lib/active_record/version.rb#7 def version; end - # source://activerecord//lib/active_record.rb#267 + # source://activerecord//lib/active_record.rb#367 def warn_on_records_fetched_greater_than; end - # source://activerecord//lib/active_record.rb#267 + # source://activerecord//lib/active_record.rb#367 def warn_on_records_fetched_greater_than=(_arg0); end - # source://activerecord//lib/active_record.rb#197 + # source://activerecord//lib/active_record.rb#250 def writing_role; end - # source://activerecord//lib/active_record.rb#197 + # source://activerecord//lib/active_record.rb#250 def writing_role=(_arg0); end - # source://activerecord//lib/active_record.rb#362 + # source://activerecord//lib/active_record.rb#483 def yaml_column_permitted_classes; end - # source://activerecord//lib/active_record.rb#362 + # source://activerecord//lib/active_record.rb#483 def yaml_column_permitted_classes=(_arg0); end end end -# Raised when trying to use a feature in Active Record which requires Active Job but the gem is not present. -# -# source://activerecord//lib/active_record/errors.rb#11 -class ActiveRecord::ActiveJobRequiredError < ::ActiveRecord::ActiveRecordError; end - # = Active Record Errors # # Generic Active Record exception class. # -# source://activerecord//lib/active_record/errors.rb#7 +# source://activerecord//lib/active_record/errors.rb#11 class ActiveRecord::ActiveRecordError < ::StandardError; end +# Superclass for all errors raised from an Active Record adapter. +# +# source://activerecord//lib/active_record/errors.rb#55 +class ActiveRecord::AdapterError < ::ActiveRecord::ActiveRecordError + # @return [AdapterError] a new instance of AdapterError + # + # source://activerecord//lib/active_record/errors.rb#56 + def initialize(message = T.unsafe(nil), connection_pool: T.unsafe(nil)); end + + # Returns the value of attribute connection_pool. + # + # source://activerecord//lib/active_record/errors.rb#61 + def connection_pool; end +end + # Raised when Active Record cannot find database adapter specified in # +config/database.yml+ or programmatically. # @@ -215,7 +342,7 @@ class ActiveRecord::AdapterNotSpecified < ::ActiveRecord::ActiveRecordError; end # AdapterTimeout will be raised when database clients times out while waiting from the server. # -# source://activerecord//lib/active_record/errors.rb#461 +# source://activerecord//lib/active_record/errors.rb#569 class ActiveRecord::AdapterTimeout < ::ActiveRecord::QueryAborted; end # See ActiveRecord::Aggregations::ClassMethods for documentation @@ -237,6 +364,8 @@ module ActiveRecord::Aggregations def initialize_dup(*_arg0); end end +# = Active Record \Aggregations +# # Active Record implements aggregation through a macro-like class method called #composed_of # for representing attributes as value objects. It expresses relationships like "Account [is] # composed of Money [among other things]" or "Person [is] composed of [an] address". Each call @@ -246,8 +375,8 @@ end # the database). # # class Customer < ActiveRecord::Base -# composed_of :balance, class_name: "Money", mapping: %w(balance amount) -# composed_of :address, mapping: [ %w(address_street street), %w(address_city city) ] +# composed_of :balance, class_name: "Money", mapping: { balance: :amount } +# composed_of :address, mapping: { address_street: :street, address_city: :city } # end # # The customer class now has the following methods to manipulate the value objects: @@ -364,7 +493,7 @@ end # class NetworkResource < ActiveRecord::Base # composed_of :cidr, # class_name: 'NetAddr::CIDR', -# mapping: [ %w(network_address network), %w(cidr_range bits) ], +# mapping: { network_address: :network, cidr_range: :bits }, # allow_nil: true, # constructor: Proc.new { |network_address, cidr_range| NetAddr::CIDR.create("#{network_address}/#{cidr_range}") }, # converter: Proc.new { |value| NetAddr::CIDR.create(value.is_a?(Array) ? value.join('/') : value) } @@ -392,7 +521,7 @@ end # # Customer.where(address: Address.new("May Street", "Chicago")) # -# source://activerecord//lib/active_record/aggregations.rb#181 +# source://activerecord//lib/active_record/aggregations.rb#183 module ActiveRecord::Aggregations::ClassMethods # Adds reader and writer methods for manipulating a value object: # composed_of :address adds address and address=(new_address) methods. @@ -403,10 +532,10 @@ module ActiveRecord::Aggregations::ClassMethods # to the Address class, but if the real class name is +CompanyAddress+, you'll have to specify it # with this option. # * :mapping - Specifies the mapping of entity attributes to attributes of the value - # object. Each mapping is represented as an array where the first item is the name of the - # entity attribute and the second item is the name of the attribute in the value object. The + # object. Each mapping is represented as a key-value pair where the key is the name of the + # entity attribute and the value is the name of the attribute in the value object. The # order in which mappings are defined determines the order in which attributes are sent to the - # value class constructor. + # value class constructor. The mapping can be written as a hash or as an array of pairs. # * :allow_nil - Specifies that the value object will not be instantiated when all mapped # attributes are +nil+. Setting the value object to +nil+ has the effect of writing +nil+ to all # mapped attributes. @@ -423,57 +552,58 @@ module ActiveRecord::Aggregations::ClassMethods # can return +nil+ to skip the assignment. # # Option examples: - # composed_of :temperature, mapping: %w(reading celsius) - # composed_of :balance, class_name: "Money", mapping: %w(balance amount) + # composed_of :temperature, mapping: { reading: :celsius } + # composed_of :balance, class_name: "Money", mapping: { balance: :amount } + # composed_of :address, mapping: { address_street: :street, address_city: :city } # composed_of :address, mapping: [ %w(address_street street), %w(address_city city) ] # composed_of :gps_location # composed_of :gps_location, allow_nil: true # composed_of :ip_address, # class_name: 'IPAddr', - # mapping: %w(ip to_i), + # mapping: { ip: :to_i }, # constructor: Proc.new { |ip| IPAddr.new(ip, Socket::AF_INET) }, # converter: Proc.new { |ip| ip.is_a?(Integer) ? IPAddr.new(ip, Socket::AF_INET) : IPAddr.new(ip.to_s) } # - # source://activerecord//lib/active_record/aggregations.rb#222 + # source://activerecord//lib/active_record/aggregations.rb#225 def composed_of(part_id, options = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/aggregations.rb#245 + # source://activerecord//lib/active_record/aggregations.rb#248 def reader_method(name, class_name, mapping, allow_nil, constructor); end - # source://activerecord//lib/active_record/aggregations.rb#258 + # source://activerecord//lib/active_record/aggregations.rb#261 def writer_method(name, class_name, mapping, allow_nil, converter); end end -# source://activerecord//lib/active_record/associations.rb#187 +# source://activerecord//lib/active_record/associations/errors.rb#203 class ActiveRecord::AmbiguousSourceReflectionForThroughAssociation < ::ActiveRecord::ActiveRecordError # @return [AmbiguousSourceReflectionForThroughAssociation] a new instance of AmbiguousSourceReflectionForThroughAssociation # - # source://activerecord//lib/active_record/associations.rb#188 + # source://activerecord//lib/active_record/associations/errors.rb#204 def initialize(klass, macro, association_name, options, possible_sources); end end -# source://activerecord//lib/active_record/associations.rb#4 +# source://activerecord//lib/active_record/associations/errors.rb#4 class ActiveRecord::AssociationNotFoundError < ::ActiveRecord::ConfigurationError include ::DidYouMean::Correctable # @return [AssociationNotFoundError] a new instance of AssociationNotFoundError # - # source://activerecord//lib/active_record/associations.rb#7 + # source://activerecord//lib/active_record/associations/errors.rb#7 def initialize(record = T.unsafe(nil), association_name = T.unsafe(nil)); end # Returns the value of attribute association_name. # - # source://activerecord//lib/active_record/associations.rb#5 + # source://activerecord//lib/active_record/associations/errors.rb#5 def association_name; end - # source://activerecord//lib/active_record/associations.rb#20 + # source://activerecord//lib/active_record/associations/errors.rb#20 def corrections; end # Returns the value of attribute record. # - # source://activerecord//lib/active_record/associations.rb#5 + # source://activerecord//lib/active_record/associations/errors.rb#5 def record; end end @@ -487,15 +617,25 @@ class ActiveRecord::AssociationRelation < ::ActiveRecord::Relation # source://activerecord//lib/active_record/association_relation.rb#14 def ==(other); end + # source://activerecord//lib/active_record/association_relation.rb#20 def insert(attributes, **kwargs); end + + # source://activerecord//lib/active_record/association_relation.rb#20 def insert!(attributes, **kwargs); end + + # source://activerecord//lib/active_record/association_relation.rb#20 def insert_all(attributes, **kwargs); end + + # source://activerecord//lib/active_record/association_relation.rb#20 def insert_all!(attributes, **kwargs); end # source://activerecord//lib/active_record/association_relation.rb#10 def proxy_association; end + # source://activerecord//lib/active_record/association_relation.rb#20 def upsert(attributes, **kwargs); end + + # source://activerecord//lib/active_record/association_relation.rb#20 def upsert_all(attributes, **kwargs); end private @@ -531,7 +671,7 @@ class ActiveRecord::AssociationTypeMismatch < ::ActiveRecord::ActiveRecordError; # See ActiveRecord::Associations::ClassMethods for documentation. # -# source://activerecord//lib/active_record/associations.rb#251 +# source://activerecord//lib/active_record/associations.rb#5 module ActiveRecord::Associations extend ::ActiveSupport::Autoload extend ::ActiveSupport::Concern @@ -540,34 +680,34 @@ module ActiveRecord::Associations # Returns the association instance for the given name, instantiating it if it doesn't already exist # - # source://activerecord//lib/active_record/associations.rb#297 + # source://activerecord//lib/active_record/associations.rb#51 def association(name); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations.rb#311 + # source://activerecord//lib/active_record/associations.rb#65 def association_cached?(name); end private # Returns the specified association instance if it exists, +nil+ otherwise. # - # source://activerecord//lib/active_record/associations.rb#327 + # source://activerecord//lib/active_record/associations.rb#81 def association_instance_get(name); end # Set the specified association instance. # - # source://activerecord//lib/active_record/associations.rb#332 + # source://activerecord//lib/active_record/associations.rb#86 def association_instance_set(name, association); end - # source://activerecord//lib/active_record/associations.rb#321 + # source://activerecord//lib/active_record/associations.rb#75 def init_internals; end - # source://activerecord//lib/active_record/associations.rb#315 + # source://activerecord//lib/active_record/associations.rb#69 def initialize_dup(*_arg0); end class << self - # source://activerecord//lib/active_record/associations.rb#290 + # source://activerecord//lib/active_record/associations.rb#44 def eager_load!; end end end @@ -580,27 +720,30 @@ class ActiveRecord::Associations::AliasTracker # # @return [AliasTracker] a new instance of AliasTracker # - # source://activerecord//lib/active_record/associations/alias_tracker.rb#49 - def initialize(connection, aliases); end + # source://activerecord//lib/active_record/associations/alias_tracker.rb#51 + def initialize(table_alias_length, aliases); end - # source://activerecord//lib/active_record/associations/alias_tracker.rb#54 + # source://activerecord//lib/active_record/associations/alias_tracker.rb#56 def aliased_table_for(arel_table, table_name = T.unsafe(nil)); end # Returns the value of attribute aliases. # - # source://activerecord//lib/active_record/associations/alias_tracker.rb#76 + # source://activerecord//lib/active_record/associations/alias_tracker.rb#78 def aliases; end private - # source://activerecord//lib/active_record/associations/alias_tracker.rb#79 + # source://activerecord//lib/active_record/associations/alias_tracker.rb#81 + def table_alias_for(table_name); end + + # source://activerecord//lib/active_record/associations/alias_tracker.rb#85 def truncate(name); end class << self # source://activerecord//lib/active_record/associations/alias_tracker.rb#9 - def create(connection, initial_table, joins, aliases = T.unsafe(nil)); end + def create(pool, initial_table, joins, aliases = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/alias_tracker.rb#26 + # source://activerecord//lib/active_record/associations/alias_tracker.rb#28 def initial_count_for(connection, name, table_joins); end end end @@ -622,7 +765,7 @@ end # Associations in Active Record are middlemen between the object that # holds the association, known as the owner, and the associated # result set, known as the target. Association metadata is available in -# reflection, which is an instance of ActiveRecord::Reflection::AssociationReflection. +# reflection, which is an instance of +ActiveRecord::Reflection::AssociationReflection+. # # For example, given # @@ -640,34 +783,44 @@ end class ActiveRecord::Associations::Association # @return [Association] a new instance of Association # - # source://activerecord//lib/active_record/associations/association.rb#40 + # source://activerecord//lib/active_record/associations/association.rb#41 def initialize(owner, reflection); end - # source://activerecord//lib/active_record/associations/association.rb#203 + # Whether the association represent a single record + # or a collection of records. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/associations/association.rb#215 + def collection?; end + + # source://activerecord//lib/active_record/associations/association.rb#205 def create(attributes = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/association.rb#207 + # source://activerecord//lib/active_record/associations/association.rb#209 def create!(attributes = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/association.rb#36 + # Returns the value of attribute disable_joins. + # + # source://activerecord//lib/active_record/associations/association.rb#37 def disable_joins; end - # source://activerecord//lib/active_record/associations/association.rb#152 + # source://activerecord//lib/active_record/associations/association.rb#154 def extensions; end - # source://activerecord//lib/active_record/associations/association.rb#193 + # source://activerecord//lib/active_record/associations/association.rb#195 def initialize_attributes(record, except_from_scope_attributes = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/association.rb#136 + # source://activerecord//lib/active_record/associations/association.rb#138 def inversed_from(record); end - # source://activerecord//lib/active_record/associations/association.rb#140 + # source://activerecord//lib/active_record/associations/association.rb#142 def inversed_from_queries(record); end # Returns the class of the target. belongs_to polymorphic overrides this to look at the # polymorphic_type field on the owner. # - # source://activerecord//lib/active_record/associations/association.rb#148 + # source://activerecord//lib/active_record/associations/association.rb#150 def klass; end # Loads the \target if needed and returns it. @@ -681,69 +834,74 @@ class ActiveRecord::Associations::Association # ActiveRecord::RecordNotFound is rescued within the method, and it is # not reraised. The proxy is \reset and +nil+ is the return value. # - # source://activerecord//lib/active_record/associations/association.rb#172 + # source://activerecord//lib/active_record/associations/association.rb#174 def load_target; end # Asserts the \target has been loaded setting the \loaded flag to +true+. # - # source://activerecord//lib/active_record/associations/association.rb#77 + # source://activerecord//lib/active_record/associations/association.rb#79 def loaded!; end # Has the \target been already \loaded? # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#72 + # source://activerecord//lib/active_record/associations/association.rb#74 def loaded?; end # We can't dump @reflection and @through_reflection since it contains the scope proc # - # source://activerecord//lib/active_record/associations/association.rb#182 + # source://activerecord//lib/active_record/associations/association.rb#184 def marshal_dump; end - # source://activerecord//lib/active_record/associations/association.rb#187 + # source://activerecord//lib/active_record/associations/association.rb#189 def marshal_load(data); end - # source://activerecord//lib/active_record/associations/association.rb#38 + # source://activerecord//lib/active_record/associations/association.rb#39 def options(*_arg0, **_arg1, &_arg2); end # source://activerecord//lib/active_record/associations/association.rb#36 def owner; end # source://activerecord//lib/active_record/associations/association.rb#36 + def owner=(_arg0); end + + # Returns the value of attribute reflection. + # + # source://activerecord//lib/active_record/associations/association.rb#37 def reflection; end # Reloads the \target and returns +self+ on success. # The QueryCache is cleared if +force+ is true. # - # source://activerecord//lib/active_record/associations/association.rb#63 + # source://activerecord//lib/active_record/associations/association.rb#65 def reload(force = T.unsafe(nil)); end # Remove the inverse association, if possible # - # source://activerecord//lib/active_record/associations/association.rb#130 + # source://activerecord//lib/active_record/associations/association.rb#132 def remove_inverse_instance(record); end # Resets the \loaded flag to +false+ and sets the \target to +nil+. # - # source://activerecord//lib/active_record/associations/association.rb#51 + # source://activerecord//lib/active_record/associations/association.rb#54 def reset; end - # source://activerecord//lib/active_record/associations/association.rb#57 + # source://activerecord//lib/active_record/associations/association.rb#59 def reset_negative_cache; end - # source://activerecord//lib/active_record/associations/association.rb#110 + # source://activerecord//lib/active_record/associations/association.rb#112 def reset_scope; end - # source://activerecord//lib/active_record/associations/association.rb#98 + # source://activerecord//lib/active_record/associations/association.rb#100 def scope; end # Set the inverse association, if possible # - # source://activerecord//lib/active_record/associations/association.rb#115 + # source://activerecord//lib/active_record/associations/association.rb#117 def set_inverse_instance(record); end - # source://activerecord//lib/active_record/associations/association.rb#122 + # source://activerecord//lib/active_record/associations/association.rb#124 def set_inverse_instance_from_queries(record); end # The target is stale if the target no longer points to the record(s) that the @@ -755,15 +913,17 @@ class ActiveRecord::Associations::Association # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#88 + # source://activerecord//lib/active_record/associations/association.rb#90 def stale_target?; end - # source://activerecord//lib/active_record/associations/association.rb#36 + # Returns the value of attribute target. + # + # source://activerecord//lib/active_record/associations/association.rb#37 def target; end # Sets the target of this association to \target, and the \loaded flag to +true+. # - # source://activerecord//lib/active_record/associations/association.rb#93 + # source://activerecord//lib/active_record/associations/association.rb#95 def target=(target); end private @@ -775,34 +935,34 @@ class ActiveRecord::Associations::Association # by scope.scoping { ... } or unscoped { ... } etc, which affects the scope which # actually gets built. # - # source://activerecord//lib/active_record/associations/association.rb#254 + # source://activerecord//lib/active_record/associations/association.rb#276 def association_scope; end - # source://activerecord//lib/active_record/associations/association.rb#336 + # source://activerecord//lib/active_record/associations/association.rb#359 def build_record(attributes); end - # source://activerecord//lib/active_record/associations/association.rb#351 + # source://activerecord//lib/active_record/associations/association.rb#374 def enqueue_destroy_association(options); end # Reader and writer methods call this so that consistent errors are presented # when the association target class does not exist. # - # source://activerecord//lib/active_record/associations/association.rb#214 + # source://activerecord//lib/active_record/associations/association.rb#222 def ensure_klass_exists!; end - # source://activerecord//lib/active_record/associations/association.rb#218 + # source://activerecord//lib/active_record/associations/association.rb#226 def find_target; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#274 + # source://activerecord//lib/active_record/associations/association.rb#296 def find_target?; end # Returns true if record contains the foreign_key # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#324 + # source://activerecord//lib/active_record/associations/association.rb#346 def foreign_key_for?(record); end # Returns true if there is a foreign key present on the owner which @@ -816,22 +976,22 @@ class ActiveRecord::Associations::Association # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#286 + # source://activerecord//lib/active_record/associations/association.rb#308 def foreign_key_present?; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#359 + # source://activerecord//lib/active_record/associations/association.rb#382 def inversable?(record); end - # source://activerecord//lib/active_record/associations/association.rb#304 + # source://activerecord//lib/active_record/associations/association.rb#326 def inverse_association_for(record); end # Can be redefined by subclasses, notably polymorphic belongs_to # The record parameter is necessary to support polymorphic inverses as we must check for # the association in the specific class of the record. # - # source://activerecord//lib/active_record/associations/association.rb#313 + # source://activerecord//lib/active_record/associations/association.rb#335 def inverse_reflection_for(record); end # Returns true if inverse association on the given record needs to be set. @@ -839,49 +999,52 @@ class ActiveRecord::Associations::Association # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#319 + # source://activerecord//lib/active_record/associations/association.rb#341 def invertible_for?(record); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#364 + # source://activerecord//lib/active_record/associations/association.rb#387 def matches_foreign_key?(record); end # Raises ActiveRecord::AssociationTypeMismatch unless +record+ is of # the kind of the class of the associated objects. Meant to be used as # a safety check when you are about to assign an associated record. # - # source://activerecord//lib/active_record/associations/association.rb#293 + # source://activerecord//lib/active_record/associations/association.rb#315 def raise_on_type_mismatch!(record); end - # source://activerecord//lib/active_record/associations/association.rb#270 + # source://activerecord//lib/active_record/associations/association.rb#292 def scope_for_create; end # Returns true if statement cache should be skipped on the association reader. # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#344 + # source://activerecord//lib/active_record/associations/association.rb#367 def skip_statement_cache?(scope); end + # source://activerecord//lib/active_record/associations/association.rb#252 + def skip_strict_loading(&block); end + # This should be implemented to return the values of the relevant key(s) on the owner, # so that when stale_state is different from the value stored on the last find_target, # the target is stale. # # This is only relevant to certain associations, which is why it returns +nil+ by default. # - # source://activerecord//lib/active_record/associations/association.rb#333 + # source://activerecord//lib/active_record/associations/association.rb#356 def stale_state; end # Can be overridden (i.e. in ThroughAssociation) to merge in other scopes (i.e. the # through association's scope) # - # source://activerecord//lib/active_record/associations/association.rb#266 + # source://activerecord//lib/active_record/associations/association.rb#288 def target_scope; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/association.rb#242 + # source://activerecord//lib/active_record/associations/association.rb#260 def violates_strict_loading?; end end @@ -897,16 +1060,16 @@ class ActiveRecord::Associations::AssociationScope private - # source://activerecord//lib/active_record/associations/association_scope.rb#117 + # source://activerecord//lib/active_record/associations/association_scope.rb#124 def add_constraints(scope, owner, chain); end - # source://activerecord//lib/active_record/associations/association_scope.rb#154 + # source://activerecord//lib/active_record/associations/association_scope.rb#161 def apply_scope(scope, table, key, value); end - # source://activerecord//lib/active_record/associations/association_scope.rb#162 + # source://activerecord//lib/active_record/associations/association_scope.rb#169 def eval_scope(reflection, scope, owner); end - # source://activerecord//lib/active_record/associations/association_scope.rb#105 + # source://activerecord//lib/active_record/associations/association_scope.rb#112 def get_chain(reflection, association, tracker); end # source://activerecord//lib/active_record/associations/association_scope.rb#54 @@ -915,10 +1078,10 @@ class ActiveRecord::Associations::AssociationScope # source://activerecord//lib/active_record/associations/association_scope.rb#58 def last_chain_scope(scope, reflection, owner); end - # source://activerecord//lib/active_record/associations/association_scope.rb#78 + # source://activerecord//lib/active_record/associations/association_scope.rb#81 def next_chain_scope(scope, reflection, next_reflection); end - # source://activerecord//lib/active_record/associations/association_scope.rb#74 + # source://activerecord//lib/active_record/associations/association_scope.rb#77 def transform_value(value); end # Returns the value of attribute value_transformation. @@ -941,19 +1104,19 @@ end # source://activerecord//lib/active_record/associations/association_scope.rb#19 ActiveRecord::Associations::AssociationScope::INSTANCE = T.let(T.unsafe(nil), ActiveRecord::Associations::AssociationScope) -# source://activerecord//lib/active_record/associations/association_scope.rb#94 +# source://activerecord//lib/active_record/associations/association_scope.rb#101 class ActiveRecord::Associations::AssociationScope::ReflectionProxy < ::SimpleDelegator # @return [ReflectionProxy] a new instance of ReflectionProxy # - # source://activerecord//lib/active_record/associations/association_scope.rb#97 + # source://activerecord//lib/active_record/associations/association_scope.rb#104 def initialize(reflection, aliased_table); end # Returns the value of attribute aliased_table. # - # source://activerecord//lib/active_record/associations/association_scope.rb#95 + # source://activerecord//lib/active_record/associations/association_scope.rb#102 def aliased_table; end - # source://activerecord//lib/active_record/associations/association_scope.rb#102 + # source://activerecord//lib/active_record/associations/association_scope.rb#109 def all_includes; end end @@ -961,85 +1124,85 @@ end # # source://activerecord//lib/active_record/associations/belongs_to_association.rb#6 class ActiveRecord::Associations::BelongsToAssociation < ::ActiveRecord::Associations::SingularAssociation - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#48 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#53 def decrement_counters; end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#56 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#61 def decrement_counters_before_last_save; end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#35 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#40 def default(&block); end # source://activerecord//lib/active_record/associations/belongs_to_association.rb#7 def handle_dependency; end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#52 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#57 def increment_counters; end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#30 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#35 def inversed_from(record); end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#39 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#44 def reset; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#79 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#84 def saved_change_to_target?; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#71 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#76 def target_changed?; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#75 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#80 def target_previously_changed?; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#44 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#49 def updated?; end private # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#113 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#118 def find_target?; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#133 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#149 def foreign_key_present?; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#137 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#153 def invertible_for?(record); end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#129 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#145 def primary_key(klass); end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#84 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#89 def replace(record); end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#121 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#126 def replace_keys(record, force: T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#117 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#122 def require_counter_update?; end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#142 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#158 def stale_state; end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#98 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#103 def update_counters(by); end - # source://activerecord//lib/active_record/associations/belongs_to_association.rb#108 + # source://activerecord//lib/active_record/associations/belongs_to_association.rb#113 def update_counters_via_scope(klass, foreign_key, by); end end @@ -1080,7 +1243,7 @@ class ActiveRecord::Associations::BelongsToPolymorphicAssociation < ::ActiveReco def stale_state; end end -# source://activerecord//lib/active_record/associations.rb#264 +# source://activerecord//lib/active_record/associations.rb#18 module ActiveRecord::Associations::Builder; end # source://activerecord//lib/active_record/associations/builder/association.rb#15 @@ -1172,30 +1335,30 @@ ActiveRecord::Associations::Builder::Association::VALID_OPTIONS = T.let(T.unsafe # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#4 class ActiveRecord::Associations::Builder::BelongsTo < ::ActiveRecord::Associations::Builder::SingularAssociation class << self - # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#43 - def touch_record(o, changes, foreign_key, name, touch, touch_method); end + # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#44 + def touch_record(o, changes, foreign_key, name, touch); end private # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#27 def add_counter_cache_callbacks(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#102 + # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#103 def add_default_callbacks(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#108 + # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#109 def add_destroy_callbacks(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#78 + # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#79 def add_touch_callbacks(model, reflection); end # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#20 def define_callbacks(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#130 + # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#144 def define_change_tracking_methods(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#112 + # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#113 def define_validations(model, reflection); end # source://activerecord//lib/active_record/associations/builder/belongs_to.rb#5 @@ -1256,7 +1419,7 @@ class ActiveRecord::Associations::Builder::HasAndBelongsToMany # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#5 def lhs_model; end - # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#63 + # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#59 def middle_reflection(join_model); end # Returns the value of attribute options. @@ -1269,13 +1432,13 @@ class ActiveRecord::Associations::Builder::HasAndBelongsToMany private - # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#96 + # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#92 def belongs_to_options(options); end - # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#75 + # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#71 def middle_options(join_model); end - # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#84 + # source://activerecord//lib/active_record/associations/builder/has_and_belongs_to_many.rb#80 def table_name; end end @@ -1287,7 +1450,7 @@ class ActiveRecord::Associations::Builder::HasMany < ::ActiveRecord::Association # source://activerecord//lib/active_record/associations/builder/has_many.rb#5 def macro; end - # source://activerecord//lib/active_record/associations/builder/has_many.rb#18 + # source://activerecord//lib/active_record/associations/builder/has_many.rb#17 def valid_dependent_options; end # source://activerecord//lib/active_record/associations/builder/has_many.rb#9 @@ -1298,27 +1461,27 @@ end # source://activerecord//lib/active_record/associations/builder/has_one.rb#4 class ActiveRecord::Associations::Builder::HasOne < ::ActiveRecord::Associations::Builder::SingularAssociation class << self - # source://activerecord//lib/active_record/associations/builder/has_one.rb#38 + # source://activerecord//lib/active_record/associations/builder/has_one.rb#37 def touch_record(record, name, touch); end private - # source://activerecord//lib/active_record/associations/builder/has_one.rb#27 + # source://activerecord//lib/active_record/associations/builder/has_one.rb#26 def add_destroy_callbacks(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/has_one.rb#47 + # source://activerecord//lib/active_record/associations/builder/has_one.rb#46 def add_touch_callbacks(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/has_one.rb#22 + # source://activerecord//lib/active_record/associations/builder/has_one.rb#21 def define_callbacks(model, reflection); end - # source://activerecord//lib/active_record/associations/builder/has_one.rb#31 + # source://activerecord//lib/active_record/associations/builder/has_one.rb#30 def define_validations(model, reflection); end # source://activerecord//lib/active_record/associations/builder/has_one.rb#5 def macro; end - # source://activerecord//lib/active_record/associations/builder/has_one.rb#18 + # source://activerecord//lib/active_record/associations/builder/has_one.rb#17 def valid_dependent_options; end # source://activerecord//lib/active_record/associations/builder/has_one.rb#9 @@ -1336,7 +1499,7 @@ class ActiveRecord::Associations::Builder::SingularAssociation < ::ActiveRecord: # Defines the (build|create)_association methods for belongs_to or has_one association # - # source://activerecord//lib/active_record/associations/builder/singular_association.rb#26 + # source://activerecord//lib/active_record/associations/builder/singular_association.rb#30 def define_constructors(mixin, name); end # source://activerecord//lib/active_record/associations/builder/singular_association.rb#7 @@ -1344,6 +1507,8 @@ class ActiveRecord::Associations::Builder::SingularAssociation < ::ActiveRecord: end end +# = Active Record \Associations +# # \Associations are a set of macro-like class methods for tying objects together through # foreign keys. They express relationships like "Project has one Project Manager" # or "Project belongs to a Portfolio". Each macro adds a number of methods to the @@ -1360,23 +1525,42 @@ end # # The project class now has the following methods (and more) to ease the traversal and # manipulation of its relationships: -# * Project#portfolio, Project#portfolio=(portfolio), Project#reload_portfolio -# * Project#project_manager, Project#project_manager=(project_manager), Project#reload_project_manager -# * Project#milestones.empty?, Project#milestones.size, Project#milestones, Project#milestones<<(milestone), -# Project#milestones.delete(milestone), Project#milestones.destroy(milestone), Project#milestones.find(milestone_id), -# Project#milestones.build, Project#milestones.create -# * Project#categories.empty?, Project#categories.size, Project#categories, Project#categories<<(category1), -# Project#categories.delete(category1), Project#categories.destroy(category1) +# +# project = Project.first +# project.portfolio +# project.portfolio = Portfolio.first +# project.reload_portfolio +# +# project.project_manager +# project.project_manager = ProjectManager.first +# project.reload_project_manager +# +# project.milestones.empty? +# project.milestones.size +# project.milestones +# project.milestones << Milestone.first +# project.milestones.delete(Milestone.first) +# project.milestones.destroy(Milestone.first) +# project.milestones.find(Milestone.first.id) +# project.milestones.build +# project.milestones.create +# +# project.categories.empty? +# project.categories.size +# project.categories +# project.categories << Category.first +# project.categories.delete(category1) +# project.categories.destroy(category1) # # === A word of warning # # Don't create associations that have the same name as {instance methods}[rdoc-ref:ActiveRecord::Core] of -# ActiveRecord::Base. Since the association adds a method with that name to -# its model, using an association with the same name as one provided by ActiveRecord::Base will override the method inherited through ActiveRecord::Base and will break things. -# For instance, +attributes+ and +connection+ would be bad choices for association names, because those names already exist in the list of ActiveRecord::Base instance methods. +# +ActiveRecord::Base+. Since the association adds a method with that name to +# its model, using an association with the same name as one provided by +ActiveRecord::Base+ will override the method inherited through +ActiveRecord::Base+ and will break things. +# For instance, +attributes+ and +connection+ would be bad choices for association names, because those names already exist in the list of +ActiveRecord::Base+ instance methods. # # == Auto-generated methods -# See also Instance Public methods below for more details. +# See also "Instance Public methods" below ( from #belongs_to ) for more details. # # === Singular associations (one-to-one) # | | belongs_to | @@ -1622,6 +1806,7 @@ end # def log_after_remove(record) # # ... # end +# end # # It's possible to stack callbacks by passing them as an array. Example: # @@ -2023,7 +2208,7 @@ end # query per addressable type. # For example, if all the addressables are either of class Person or Company, then a total # of 3 queries will be executed. The list of addressable types to load is determined on -# the back of the addresses loaded. This is not supported if Active Record has to fallback +# the back of the addresses loaded. This is not supported if Active Record has to fall back # to the previous implementation of eager loading and will raise ActiveRecord::EagerLoadPolymorphicError. # The reason is that the parent model's type is a column value so its corresponding table # name cannot be put in the +FROM+/+JOIN+ clauses of that query. @@ -2036,45 +2221,45 @@ end # Indexes are appended for any more successive uses of the table name. # # Post.joins(:comments) -# # => SELECT ... FROM posts INNER JOIN comments ON ... +# # SELECT ... FROM posts INNER JOIN comments ON ... # Post.joins(:special_comments) # STI -# # => SELECT ... FROM posts INNER JOIN comments ON ... AND comments.type = 'SpecialComment' +# # SELECT ... FROM posts INNER JOIN comments ON ... AND comments.type = 'SpecialComment' # Post.joins(:comments, :special_comments) # special_comments is the reflection name, posts is the parent table name -# # => SELECT ... FROM posts INNER JOIN comments ON ... INNER JOIN comments special_comments_posts +# # SELECT ... FROM posts INNER JOIN comments ON ... INNER JOIN comments special_comments_posts # # Acts as tree example: # # TreeMixin.joins(:children) -# # => SELECT ... FROM mixins INNER JOIN mixins childrens_mixins ... +# # SELECT ... FROM mixins INNER JOIN mixins childrens_mixins ... # TreeMixin.joins(children: :parent) -# # => SELECT ... FROM mixins INNER JOIN mixins childrens_mixins ... -# INNER JOIN parents_mixins ... +# # SELECT ... FROM mixins INNER JOIN mixins childrens_mixins ... +# # INNER JOIN parents_mixins ... # TreeMixin.joins(children: {parent: :children}) -# # => SELECT ... FROM mixins INNER JOIN mixins childrens_mixins ... -# INNER JOIN parents_mixins ... -# INNER JOIN mixins childrens_mixins_2 +# # SELECT ... FROM mixins INNER JOIN mixins childrens_mixins ... +# # INNER JOIN parents_mixins ... +# # INNER JOIN mixins childrens_mixins_2 # # Has and Belongs to Many join tables use the same idea, but add a _join suffix: # # Post.joins(:categories) -# # => SELECT ... FROM posts INNER JOIN categories_posts ... INNER JOIN categories ... +# # SELECT ... FROM posts INNER JOIN categories_posts ... INNER JOIN categories ... # Post.joins(categories: :posts) -# # => SELECT ... FROM posts INNER JOIN categories_posts ... INNER JOIN categories ... -# INNER JOIN categories_posts posts_categories_join INNER JOIN posts posts_categories +# # SELECT ... FROM posts INNER JOIN categories_posts ... INNER JOIN categories ... +# # INNER JOIN categories_posts posts_categories_join INNER JOIN posts posts_categories # Post.joins(categories: {posts: :categories}) -# # => SELECT ... FROM posts INNER JOIN categories_posts ... INNER JOIN categories ... -# INNER JOIN categories_posts posts_categories_join INNER JOIN posts posts_categories -# INNER JOIN categories_posts categories_posts_join INNER JOIN categories categories_posts_2 +# # SELECT ... FROM posts INNER JOIN categories_posts ... INNER JOIN categories ... +# # INNER JOIN categories_posts posts_categories_join INNER JOIN posts posts_categories +# # INNER JOIN categories_posts categories_posts_join INNER JOIN categories categories_posts_2 # # If you wish to specify your own custom joins using ActiveRecord::QueryMethods#joins method, those table # names will take precedence over the eager associations: # # Post.joins(:comments).joins("inner join comments ...") -# # => SELECT ... FROM posts INNER JOIN comments_posts ON ... INNER JOIN comments ... +# # SELECT ... FROM posts INNER JOIN comments_posts ON ... INNER JOIN comments ... # Post.joins(:comments, :special_comments).joins("inner join comments ...") -# # => SELECT ... FROM posts INNER JOIN comments comments_posts ON ... -# INNER JOIN comments special_comments_posts ... -# INNER JOIN comments ... +# # SELECT ... FROM posts INNER JOIN comments comments_posts ON ... +# # INNER JOIN comments special_comments_posts ... +# # INNER JOIN comments ... # # Table aliases are automatically truncated according to the maximum length of table identifiers # according to the specific database. @@ -2155,7 +2340,8 @@ end # belongs_to :dungeon, inverse_of: :evil_wizard # end # -# For more information, see the documentation for the +:inverse_of+ option. +# For more information, see the documentation for the +:inverse_of+ option and the +# {Active Record Associations guide}[https://guides.rubyonrails.org/association_basics.html#bi-directional-associations]. # # == Deleting from associations # @@ -2177,7 +2363,7 @@ end # specific association types. When no option is given, the behavior is to do nothing # with the associated records when destroying a record. # -# Note that :dependent is implemented using Rails' callback +# Note that :dependent is implemented using \Rails' callback # system, which works by processing callbacks in order. Therefore, other # callbacks declared either before or after the :dependent option # can affect what it does. @@ -2242,7 +2428,7 @@ end # All of the association macros can be specialized through options. This makes cases # more complex than the simple and guessable ones possible. # -# source://activerecord//lib/active_record/associations.rb#1233 +# source://activerecord//lib/active_record/associations.rb#1010 module ActiveRecord::Associations::ClassMethods # Specifies a one-to-one association with another class. This method should only be used # if this class contains the foreign key. If the other class contains the foreign key, @@ -2255,42 +2441,52 @@ module ActiveRecord::Associations::ClassMethods # +association+ is a placeholder for the symbol passed as the +name+ argument, so # belongs_to :author would add among others author.nil?. # - # [association] + # [association] # Returns the associated object. +nil+ is returned if none is found. - # [association=(associate)] + # [association=(associate)] # Assigns the associate object, extracts the primary key, and sets it as the foreign key. # No modification or deletion of existing records takes place. - # [build_association(attributes = {})] + # [build_association(attributes = {})] # Returns a new object of the associated type that has been instantiated # with +attributes+ and linked to this object through a foreign key, but has not yet been saved. - # [create_association(attributes = {})] + # [create_association(attributes = {})] # Returns a new object of the associated type that has been instantiated # with +attributes+, linked to this object through a foreign key, and that # has already been saved (if it passed the validation). - # [create_association!(attributes = {})] + # [create_association!(attributes = {})] # Does the same as create_association, but raises ActiveRecord::RecordInvalid # if the record is invalid. - # [reload_association] + # [reload_association] # Returns the associated object, forcing a database read. - # [association_changed?] + # [reset_association] + # Unloads the associated object. The next access will query it from the database. + # [association_changed?] # Returns true if a new associate object has been assigned and the next save will update the foreign key. - # [association_previously_changed?] + # [association_previously_changed?] # Returns true if the previous save updated the association to reference a new associate object. # - # === Example - # - # A Post class declares belongs_to :author, which will add: - # * Post#author (similar to Author.find(author_id)) - # * Post#author=(author) (similar to post.author_id = author.id) - # * Post#build_author (similar to post.author = Author.new) - # * Post#create_author (similar to post.author = Author.new; post.author.save; post.author) - # * Post#create_author! (similar to post.author = Author.new; post.author.save!; post.author) - # * Post#reload_author - # * Post#author_changed? - # * Post#author_previously_changed? - # The declaration can also include an +options+ hash to specialize the behavior of the association. + # ==== Example + # + # class Post < ActiveRecord::Base + # belongs_to :author + # end + # + # Declaring belongs_to :author adds the following methods (and more): + # + # post = Post.find(7) + # author = Author.find(19) # - # === Scopes + # post.author # similar to Author.find(post.author_id) + # post.author = author # similar to post.author_id = author.id + # post.build_author # similar to post.author = Author.new + # post.create_author # similar to post.author = Author.new; post.author.save; post.author + # post.create_author! # similar to post.author = Author.new; post.author.save!; post.author + # post.reload_author + # post.reset_author + # post.author_changed? + # post.author_previously_changed? + # + # ==== Scopes # # You can pass a second argument +scope+ as a callable (i.e. proc or # lambda) to retrieve a specific record or customize the generated query @@ -2301,56 +2497,68 @@ module ActiveRecord::Associations::ClassMethods # belongs_to :user, -> { joins(:friends) } # belongs_to :level, ->(game) { where("game_level > ?", game.current_level) } # - # === Options + # ==== Options + # + # The declaration can also include an +options+ hash to specialize the behavior of the association. # - # [:class_name] + # [+:class_name+] # Specify the class name of the association. Use it only if that name can't be inferred # from the association name. So belongs_to :author will by default be linked to the Author class, but # if the real class name is Person, you'll have to specify it with this option. - # [:foreign_key] + # [+:foreign_key+] # Specify the foreign key used for the association. By default this is guessed to be the name # of the association with an "_id" suffix. So a class that defines a belongs_to :person # association will use "person_id" as the default :foreign_key. Similarly, # belongs_to :favorite_person, class_name: "Person" will use a foreign key # of "favorite_person_id". # - # If you are going to modify the association (rather than just read from it), then it is - # a good idea to set the :inverse_of option. - # [:foreign_type] + # Setting the :foreign_key option prevents automatic detection of the association's + # inverse, so it is generally a good idea to set the :inverse_of option as well. + # [+:foreign_type+] # Specify the column used to store the associated object's type, if this is a polymorphic # association. By default this is guessed to be the name of the association with a "_type" # suffix. So a class that defines a belongs_to :taggable, polymorphic: true # association will use "taggable_type" as the default :foreign_type. - # [:primary_key] + # [+:primary_key+] # Specify the method that returns the primary key of associated object used for the association. # By default this is +id+. - # [:dependent] + # [+:dependent+] # If set to :destroy, the associated object is destroyed when this object is. If set to # :delete, the associated object is deleted *without* calling its destroy method. If set to # :destroy_async, the associated object is scheduled to be destroyed in a background job. # This option should not be specified when #belongs_to is used in conjunction with # a #has_many relationship on another class because of the potential to leave # orphaned records behind. - # [:counter_cache] + # [+:counter_cache+] # Caches the number of belonging objects on the associate class through the use of CounterCache::ClassMethods#increment_counter # and CounterCache::ClassMethods#decrement_counter. The counter cache is incremented when an object of this # class is created and decremented when it's destroyed. This requires that a column # named #{table_name}_count (such as +comments_count+ for a belonging Comment class) # is used on the associate class (such as a Post class) - that is the migration for # #{table_name}_count is created on the associate class (such that Post.comments_count will - # return the count cached, see note below). You can also specify a custom counter + # return the count cached). You can also specify a custom counter # cache column by providing a column name instead of a +true+/+false+ value to this # option (e.g., counter_cache: :my_custom_counter.) - # Note: Specifying a counter cache will add it to that model's list of readonly attributes - # using +attr_readonly+. - # [:polymorphic] - # Specify this association is a polymorphic association by passing +true+. + # + # Starting to use counter caches on existing large tables can be troublesome, because the column + # values must be backfilled separately of the column addition (to not lock the table for too long) + # and before the use of +:counter_cache+ (otherwise methods like +size+/+any?+/etc, which use + # counter caches internally, can produce incorrect results). To safely backfill the values while keeping + # counter cache columns updated with the child records creation/removal and to avoid the mentioned methods + # use the possibly incorrect counter cache column values and always get the results from the database, + # use counter_cache: { active: false }. + # If you also need to specify a custom column name, use counter_cache: { active: false, column: :my_custom_counter }. + # # Note: If you've enabled the counter cache, then you may want to add the counter cache attribute # to the +attr_readonly+ list in the associated classes (e.g. class Post; attr_readonly :comments_count; end). - # [:validate] + # [+:polymorphic+] + # Specify this association is a polymorphic association by passing +true+. + # Note: Since polymorphic associations rely on storing class names in the database, make sure to update the class names in the + # *_type polymorphic type column of the corresponding rows. + # [+:validate+] # When set to +true+, validates new objects added to association when saving the parent object. +false+ by default. # If you want to ensure associated objects are revalidated on every update, use +validates_associated+. - # [:autosave] + # [+:autosave+] # If true, always save the associated object or destroy it if marked for destruction, when # saving the parent object. # If false, never save or destroy the associated object. @@ -2358,32 +2566,37 @@ module ActiveRecord::Associations::ClassMethods # # Note that NestedAttributes::ClassMethods#accepts_nested_attributes_for # sets :autosave to true. - # [:touch] + # [+:touch+] # If true, the associated object will be touched (the +updated_at+ / +updated_on+ attributes set to current time) # when this record is either saved or destroyed. If you specify a symbol, that attribute # will be updated with the current time in addition to the +updated_at+ / +updated_on+ attribute. # Please note that no validation will be performed when touching, and only the +after_touch+, # +after_commit+, and +after_rollback+ callbacks will be executed. - # [:inverse_of] + # [+:inverse_of+] # Specifies the name of the #has_one or #has_many association on the associated # object that is the inverse of this #belongs_to association. # See ActiveRecord::Associations::ClassMethods's overview on Bi-directional associations for more detail. - # [:optional] + # [+:optional+] # When set to +true+, the association will not have its presence validated. - # [:required] + # [+:required+] # When set to +true+, the association will also have its presence validated. # This will validate the association itself, not the id. You can use # +:inverse_of+ to avoid an extra query during validation. # NOTE: required is set to true by default and is deprecated. If # you don't want to have association presence validated, use optional: true. - # [:default] + # [+:default+] # Provide a callable (i.e. proc or lambda) to specify that the association should # be initialized with a particular record before validation. - # [:strict_loading] + # Please note that callable won't be executed if the record exists. + # [+:strict_loading+] # Enforces strict loading every time the associated record is loaded through this association. - # [:ensuring_owner_was] + # [+:ensuring_owner_was+] # Specifies an instance method to be called on the owner. The method must return true in order for the # associated records to be deleted in a background job. + # [+:query_constraints+] + # Serves as a composite foreign key. Defines the list of columns to be used to query the associated object. + # This is an optional option. By default Rails will attempt to derive the value automatically. + # When the value is set the Array size must match associated model's primary key or +query_constraints+ size. # # Option examples: # belongs_to :firm, foreign_key: "client_of" @@ -2399,8 +2612,9 @@ module ActiveRecord::Associations::ClassMethods # belongs_to :user, optional: true # belongs_to :account, default: -> { company.account } # belongs_to :account, strict_loading: true + # belongs_to :note, query_constraints: [:organization_id, :note_id] # - # source://activerecord//lib/active_record/associations.rb#1799 + # source://activerecord//lib/active_record/associations.rb#1647 def belongs_to(name, scope = T.unsafe(nil), **options); end # Specifies a many-to-many relationship with another class. This associates two classes via an @@ -2420,7 +2634,7 @@ module ActiveRecord::Associations::ClassMethods # The join table should not have a primary key or a model associated with it. You must manually generate the # join table with a migration such as this: # - # class CreateDevelopersProjectsJoinTable < ActiveRecord::Migration[7.0] + # class CreateDevelopersProjectsJoinTable < ActiveRecord::Migration[7.2] # def change # create_join_table :developers, :projects # end @@ -2435,71 +2649,80 @@ module ActiveRecord::Associations::ClassMethods # +collection+ is a placeholder for the symbol passed as the +name+ argument, so # has_and_belongs_to_many :categories would add among others categories.empty?. # - # [collection] + # [collection] # Returns a Relation of all the associated objects. # An empty Relation is returned if none are found. - # [collection<<(object, ...)] + # [collection<<(object, ...)] # Adds one or more objects to the collection by creating associations in the join table # (collection.push and collection.concat are aliases to this method). # Note that this operation instantly fires update SQL without waiting for the save or update call on the # parent object, unless the parent object is a new record. - # [collection.delete(object, ...)] + # [collection.delete(object, ...)] # Removes one or more objects from the collection by removing their associations from the join table. # This does not destroy the objects. - # [collection.destroy(object, ...)] + # [collection.destroy(object, ...)] # Removes one or more objects from the collection by running destroy on each association in the join table, overriding any dependent option. # This does not destroy the objects. - # [collection=objects] + # [collection=objects] # Replaces the collection's content by deleting and adding objects as appropriate. - # [collection_singular_ids] + # [collection_singular_ids] # Returns an array of the associated objects' ids. - # [collection_singular_ids=ids] + # [collection_singular_ids=ids] # Replace the collection by the objects identified by the primary keys in +ids+. - # [collection.clear] + # [collection.clear] # Removes every object from the collection. This does not destroy the objects. - # [collection.empty?] + # [collection.empty?] # Returns +true+ if there are no associated objects. - # [collection.size] + # [collection.size] # Returns the number of associated objects. - # [collection.find(id)] + # [collection.find(id)] # Finds an associated object responding to the +id+ and that # meets the condition that it has to be associated with this object. # Uses the same rules as ActiveRecord::FinderMethods#find. - # [collection.exists?(...)] + # [collection.exists?(...)] # Checks whether an associated object with the given conditions exists. # Uses the same rules as ActiveRecord::FinderMethods#exists?. - # [collection.build(attributes = {})] + # [collection.build(attributes = {})] # Returns a new object of the collection type that has been instantiated # with +attributes+ and linked to this object through the join table, but has not yet been saved. - # [collection.create(attributes = {})] + # [collection.create(attributes = {})] # Returns a new object of the collection type that has been instantiated # with +attributes+, linked to this object through the join table, and that has already been # saved (if it passed the validation). - # [collection.reload] + # [collection.reload] # Returns a Relation of all of the associated objects, forcing a database read. # An empty Relation is returned if none are found. # - # === Example - # - # A Developer class declares has_and_belongs_to_many :projects, which will add: - # * Developer#projects - # * Developer#projects<< - # * Developer#projects.delete - # * Developer#projects.destroy - # * Developer#projects= - # * Developer#project_ids - # * Developer#project_ids= - # * Developer#projects.clear - # * Developer#projects.empty? - # * Developer#projects.size - # * Developer#projects.find(id) - # * Developer#projects.exists?(...) - # * Developer#projects.build (similar to Project.new(developer_id: id)) - # * Developer#projects.create (similar to c = Project.new(developer_id: id); c.save; c) - # * Developer#projects.reload + # ==== Example + # + # class Developer < ActiveRecord::Base + # has_and_belongs_to_many :projects + # end + # + # Declaring has_and_belongs_to_many :projects adds the following methods (and more): + # + # developer = Developer.find(11) + # project = Project.find(9) + # + # developer.projects + # developer.projects << project + # developer.projects.delete(project) + # developer.projects.destroy(project) + # developer.projects = [project] + # developer.project_ids + # developer.project_ids = [9] + # developer.projects.clear + # developer.projects.empty? + # developer.projects.size + # developer.projects.find(9) + # developer.projects.exists?(9) + # developer.projects.build # similar to Project.new(developer_id: 11) + # developer.projects.create # similar to Project.create(developer_id: 11) + # developer.projects.reload + # # The declaration may include an +options+ hash to specialize the behavior of the association. # - # === Scopes + # ==== Scopes # # You can pass a second argument +scope+ as a callable (i.e. proc or # lambda) to retrieve a specific set of records or customize the generated @@ -2511,7 +2734,7 @@ module ActiveRecord::Associations::ClassMethods # where("default_category = ?", post.default_category) # } # - # === Extensions + # ==== Extensions # # The +extension+ argument allows you to pass a block into a # has_and_belongs_to_many association. This is useful for adding new @@ -2526,33 +2749,33 @@ module ActiveRecord::Associations::ClassMethods # end # end # - # === Options + # ==== Options # - # [:class_name] + # [+:class_name+] # Specify the class name of the association. Use it only if that name can't be inferred # from the association name. So has_and_belongs_to_many :projects will by default be linked to the # Project class, but if the real class name is SuperProject, you'll have to specify it with this option. - # [:join_table] + # [+:join_table+] # Specify the name of the join table if the default based on lexical order isn't what you want. # WARNING: If you're overwriting the table name of either class, the +table_name+ method # MUST be declared underneath any #has_and_belongs_to_many declaration in order to work. - # [:foreign_key] + # [+:foreign_key+] # Specify the foreign key used for the association. By default this is guessed to be the name # of this class in lower-case and "_id" suffixed. So a Person class that makes # a #has_and_belongs_to_many association to Project will use "person_id" as the # default :foreign_key. # - # If you are going to modify the association (rather than just read from it), then it is - # a good idea to set the :inverse_of option. - # [:association_foreign_key] + # Setting the :foreign_key option prevents automatic detection of the association's + # inverse, so it is generally a good idea to set the :inverse_of option as well. + # [+:association_foreign_key+] # Specify the foreign key used for the association on the receiving side of the association. # By default this is guessed to be the name of the associated class in lower-case and "_id" suffixed. # So if a Person class makes a #has_and_belongs_to_many association to Project, # the association will use "project_id" as the default :association_foreign_key. - # [:validate] + # [+:validate+] # When set to +true+, validates new objects added to association when saving the parent object. +true+ by default. # If you want to ensure associated objects are revalidated on every update, use +validates_associated+. - # [:autosave] + # [+:autosave+] # If true, always save the associated objects or destroy them if marked for destruction, when # saving the parent object. # If false, never save or destroy the associated objects. @@ -2560,7 +2783,7 @@ module ActiveRecord::Associations::ClassMethods # # Note that NestedAttributes::ClassMethods#accepts_nested_attributes_for sets # :autosave to true. - # [:strict_loading] + # [+:strict_loading+] # Enforces strict loading every time an associated record is loaded through this association. # # Option examples: @@ -2571,7 +2794,7 @@ module ActiveRecord::Associations::ClassMethods # has_and_belongs_to_many :categories, -> { readonly } # has_and_belongs_to_many :categories, strict_loading: true # - # source://activerecord//lib/active_record/associations.rb#1971 + # source://activerecord//lib/active_record/associations.rb#1828 def has_and_belongs_to_many(name, scope = T.unsafe(nil), **options, &extension); end # Specifies a one-to-many association. The following methods for retrieval and query of @@ -2580,15 +2803,15 @@ module ActiveRecord::Associations::ClassMethods # +collection+ is a placeholder for the symbol passed as the +name+ argument, so # has_many :clients would add among others clients.empty?. # - # [collection] + # [collection] # Returns a Relation of all the associated objects. # An empty Relation is returned if none are found. - # [collection<<(object, ...)] + # [collection<<(object, ...)] # Adds one or more objects to the collection by setting their foreign keys to the collection's primary key. # Note that this operation instantly fires update SQL without waiting for the save or update call on the # parent object, unless the parent object is a new record. # This will also run validations and callbacks of associated object(s). - # [collection.delete(object, ...)] + # [collection.delete(object, ...)] # Removes one or more objects from the collection by setting their foreign keys to +NULL+. # Objects will be in addition destroyed if they're associated with dependent: :destroy, # and deleted if they're associated with dependent: :delete_all. @@ -2596,75 +2819,84 @@ module ActiveRecord::Associations::ClassMethods # If the :through option is used, then the join records are deleted (rather than # nullified) by default, but you can specify dependent: :destroy or # dependent: :nullify to override this. - # [collection.destroy(object, ...)] + # [collection.destroy(object, ...)] # Removes one or more objects from the collection by running destroy on # each record, regardless of any dependent option, ensuring callbacks are run. # # If the :through option is used, then the join records are destroyed # instead, not the objects themselves. - # [collection=objects] + # [collection=objects] # Replaces the collections content by deleting and adding objects as appropriate. If the :through # option is true callbacks in the join models are triggered except destroy callbacks, since deletion is # direct by default. You can specify dependent: :destroy or # dependent: :nullify to override this. - # [collection_singular_ids] + # [collection_singular_ids] # Returns an array of the associated objects' ids - # [collection_singular_ids=ids] + # [collection_singular_ids=ids] # Replace the collection with the objects identified by the primary keys in +ids+. This # method loads the models and calls collection=. See above. - # [collection.clear] + # [collection.clear] # Removes every object from the collection. This destroys the associated objects if they # are associated with dependent: :destroy, deletes them directly from the # database if dependent: :delete_all, otherwise sets their foreign keys to +NULL+. # If the :through option is true no destroy callbacks are invoked on the join models. # Join models are directly deleted. - # [collection.empty?] + # [collection.empty?] # Returns +true+ if there are no associated objects. - # [collection.size] + # [collection.size] # Returns the number of associated objects. - # [collection.find(...)] + # [collection.find(...)] # Finds an associated object according to the same rules as ActiveRecord::FinderMethods#find. - # [collection.exists?(...)] + # [collection.exists?(...)] # Checks whether an associated object with the given conditions exists. # Uses the same rules as ActiveRecord::FinderMethods#exists?. - # [collection.build(attributes = {}, ...)] + # [collection.build(attributes = {}, ...)] # Returns one or more new objects of the collection type that have been instantiated # with +attributes+ and linked to this object through a foreign key, but have not yet # been saved. - # [collection.create(attributes = {})] + # [collection.create(attributes = {})] # Returns a new object of the collection type that has been instantiated # with +attributes+, linked to this object through a foreign key, and that has already # been saved (if it passed the validation). *Note*: This only works if the base model # already exists in the DB, not if it is a new (unsaved) record! - # [collection.create!(attributes = {})] + # [collection.create!(attributes = {})] # Does the same as collection.create, but raises ActiveRecord::RecordInvalid # if the record is invalid. - # [collection.reload] + # [collection.reload] # Returns a Relation of all of the associated objects, forcing a database read. # An empty Relation is returned if none are found. # - # === Example - # - # A Firm class declares has_many :clients, which will add: - # * Firm#clients (similar to Client.where(firm_id: id)) - # * Firm#clients<< - # * Firm#clients.delete - # * Firm#clients.destroy - # * Firm#clients= - # * Firm#client_ids - # * Firm#client_ids= - # * Firm#clients.clear - # * Firm#clients.empty? (similar to firm.clients.size == 0) - # * Firm#clients.size (similar to Client.count "firm_id = #{id}") - # * Firm#clients.find (similar to Client.where(firm_id: id).find(id)) - # * Firm#clients.exists?(name: 'ACME') (similar to Client.exists?(name: 'ACME', firm_id: firm.id)) - # * Firm#clients.build (similar to Client.new(firm_id: id)) - # * Firm#clients.create (similar to c = Client.new(firm_id: id); c.save; c) - # * Firm#clients.create! (similar to c = Client.new(firm_id: id); c.save!) - # * Firm#clients.reload + # ==== Example + # + # class Firm < ActiveRecord::Base + # has_many :clients + # end + # + # Declaring has_many :clients adds the following methods (and more): + # + # firm = Firm.find(2) + # client = Client.find(6) + # + # firm.clients # similar to Client.where(firm_id: 2) + # firm.clients << client + # firm.clients.delete(client) + # firm.clients.destroy(client) + # firm.clients = [client] + # firm.client_ids + # firm.client_ids = [6] + # firm.clients.clear + # firm.clients.empty? # similar to firm.clients.size == 0 + # firm.clients.size # similar to Client.count "firm_id = 2" + # firm.clients.find # similar to Client.where(firm_id: 2).find(6) + # firm.clients.exists?(name: 'ACME') # similar to Client.exists?(name: 'ACME', firm_id: 2) + # firm.clients.build # similar to Client.new(firm_id: 2) + # firm.clients.create # similar to Client.create(firm_id: 2) + # firm.clients.create! # similar to Client.create!(firm_id: 2) + # firm.clients.reload + # # The declaration can also include an +options+ hash to specialize the behavior of the association. # - # === Scopes + # ==== Scopes # # You can pass a second argument +scope+ as a callable (i.e. proc or # lambda) to retrieve a specific set of records or customize the generated @@ -2675,7 +2907,7 @@ module ActiveRecord::Associations::ClassMethods # has_many :employees, -> { joins(:address) } # has_many :posts, ->(blog) { where("max_post_length > ?", blog.max_post_length) } # - # === Extensions + # ==== Extensions # # The +extension+ argument allows you to pass a block into a has_many # association. This is useful for adding new finders, creators, and other @@ -2689,31 +2921,31 @@ module ActiveRecord::Associations::ClassMethods # end # end # - # === Options - # [:class_name] + # ==== Options + # [+:class_name+] # Specify the class name of the association. Use it only if that name can't be inferred # from the association name. So has_many :products will by default be linked # to the +Product+ class, but if the real class name is +SpecialProduct+, you'll have to # specify it with this option. - # [:foreign_key] + # [+:foreign_key+] # Specify the foreign key used for the association. By default this is guessed to be the name # of this class in lower-case and "_id" suffixed. So a Person class that makes a #has_many # association will use "person_id" as the default :foreign_key. # - # If you are going to modify the association (rather than just read from it), then it is - # a good idea to set the :inverse_of option. - # [:foreign_type] + # Setting the :foreign_key option prevents automatic detection of the association's + # inverse, so it is generally a good idea to set the :inverse_of option as well. + # [+:foreign_type+] # Specify the column used to store the associated object's type, if this is a polymorphic # association. By default this is guessed to be the name of the polymorphic association # specified on "as" option with a "_type" suffix. So a class that defines a # has_many :tags, as: :taggable association will use "taggable_type" as the # default :foreign_type. - # [:primary_key] + # [+:primary_key+] # Specify the name of the column to use as the primary key for the association. By default this is +id+. - # [:dependent] + # [+:dependent+] # Controls what happens to the associated objects when # their owner is destroyed. Note that these are implemented as - # callbacks, and Rails executes callbacks in order. Therefore, other + # callbacks, and \Rails executes callbacks in order. Therefore, other # similar callbacks may affect the :dependent behavior, and the # :dependent behavior may affect other callbacks. # @@ -2725,7 +2957,7 @@ module ActiveRecord::Associations::ClassMethods # * :delete_all causes all the associated objects to be deleted directly from the database (so callbacks will not be executed). # * :nullify causes the foreign keys to be set to +NULL+. Polymorphic type will also be nullified # on polymorphic associations. Callbacks are not executed. - # * :restrict_with_exception causes an ActiveRecord::DeleteRestrictionError exception to be raised if there are any associated records. + # * :restrict_with_exception causes an ActiveRecord::DeleteRestrictionError exception to be raised if there are any associated records. # * :restrict_with_error causes an error to be added to the owner if there are any associated objects. # # If using with the :through option, the association on the join model must be @@ -2737,12 +2969,12 @@ module ActiveRecord::Associations::ClassMethods # has_many :comments, -> { where published: true }, dependent: :destroy and destroy is # called on a post, only published comments are destroyed. This means that any unpublished comments in the # database would still contain a foreign key pointing to the now deleted post. - # [:counter_cache] + # [+:counter_cache+] # This option can be used to configure a custom named :counter_cache. You only need this option, # when you customized the name of your :counter_cache on the #belongs_to association. - # [:as] + # [+:as+] # Specifies a polymorphic interface (See #belongs_to). - # [:through] + # [+:through+] # Specifies an association through which to perform the query. This can be any other type # of association, including other :through associations. Options for :class_name, # :primary_key and :foreign_key are ignored, as the association uses the @@ -2757,24 +2989,24 @@ module ActiveRecord::Associations::ClassMethods # a good idea to set the :inverse_of option on the source association on the # join model. This allows associated records to be built which will automatically create # the appropriate join model records when they are saved. (See the 'Association Join Models' - # section above.) - # [:disable_joins] + # and 'Setting Inverses' sections above.) + # [+:disable_joins+] # Specifies whether joins should be skipped for an association. If set to true, two or more queries # will be generated. Note that in some cases, if order or limit is applied, it will be done in-memory # due to database limitations. This option is only applicable on has_many :through associations as # +has_many+ alone do not perform a join. - # [:source] + # [+:source+] # Specifies the source association name used by #has_many :through queries. # Only use it if the name cannot be inferred from the association. # has_many :subscribers, through: :subscriptions will look for either :subscribers or # :subscriber on Subscription, unless a :source is given. - # [:source_type] + # [+:source_type+] # Specifies type of the source association used by #has_many :through queries where the source # association is a polymorphic #belongs_to. - # [:validate] + # [+:validate+] # When set to +true+, validates new objects added to association when saving the parent object. +true+ by default. # If you want to ensure associated objects are revalidated on every update, use +validates_associated+. - # [:autosave] + # [+:autosave+] # If true, always save the associated objects or destroy them if marked for destruction, # when saving the parent object. If false, never save or destroy the associated objects. # By default, only save associated objects that are new records. This option is implemented as a @@ -2783,20 +3015,31 @@ module ActiveRecord::Associations::ClassMethods # # Note that NestedAttributes::ClassMethods#accepts_nested_attributes_for sets # :autosave to true. - # [:inverse_of] + # [+:inverse_of+] # Specifies the name of the #belongs_to association on the associated object # that is the inverse of this #has_many association. # See ActiveRecord::Associations::ClassMethods's overview on Bi-directional associations for more detail. - # [:extend] + # [+:extend+] # Specifies a module or array of modules that will be extended into the association object returned. # Useful for defining methods on associations, especially when they should be shared between multiple # association objects. - # [:strict_loading] + # [+:strict_loading+] # When set to +true+, enforces strict loading every time the associated record is loaded through this # association. - # [:ensuring_owner_was] + # [+:ensuring_owner_was+] # Specifies an instance method to be called on the owner. The method must return true in order for the # associated records to be deleted in a background job. + # [+:query_constraints+] + # Serves as a composite foreign key. Defines the list of columns to be used to query the associated object. + # This is an optional option. By default Rails will attempt to derive the value automatically. + # When the value is set the Array size must match associated model's primary key or +query_constraints+ size. + # [+:index_errors+] + # Allows differentiation of multiple validation errors from the association records, by including + # an index in the error attribute name, e.g. +roles[2].level+. + # When set to +true+, the index is based on association order, i.e. database order, with yet to be + # persisted new records placed at the end. + # When set to +:nested_attributes_order+, the index is based on the record order received by + # nested attributes setter, when accepts_nested_attributes_for is used. # # Option examples: # has_many :comments, -> { order("posted_on") } @@ -2809,8 +3052,10 @@ module ActiveRecord::Associations::ClassMethods # has_many :subscribers, through: :subscriptions, source: :user # has_many :subscribers, through: :subscriptions, disable_joins: true # has_many :comments, strict_loading: true + # has_many :comments, query_constraints: [:blog_id, :post_id] + # has_many :comments, index_errors: :nested_attributes_order # - # source://activerecord//lib/active_record/associations.rb#1469 + # source://activerecord//lib/active_record/associations.rb#1268 def has_many(name, scope = T.unsafe(nil), **options, &extension); end # Specifies a one-to-one association with another class. This method should only be used @@ -2823,37 +3068,48 @@ module ActiveRecord::Associations::ClassMethods # +association+ is a placeholder for the symbol passed as the +name+ argument, so # has_one :manager would add among others manager.nil?. # - # [association] + # [association] # Returns the associated object. +nil+ is returned if none is found. - # [association=(associate)] + # [association=(associate)] # Assigns the associate object, extracts the primary key, sets it as the foreign key, # and saves the associate object. To avoid database inconsistencies, permanently deletes an existing # associated object when assigning a new one, even if the new one isn't saved to database. - # [build_association(attributes = {})] + # [build_association(attributes = {})] # Returns a new object of the associated type that has been instantiated # with +attributes+ and linked to this object through a foreign key, but has not # yet been saved. - # [create_association(attributes = {})] + # [create_association(attributes = {})] # Returns a new object of the associated type that has been instantiated # with +attributes+, linked to this object through a foreign key, and that # has already been saved (if it passed the validation). - # [create_association!(attributes = {})] + # [create_association!(attributes = {})] # Does the same as create_association, but raises ActiveRecord::RecordInvalid # if the record is invalid. - # [reload_association] + # [reload_association] # Returns the associated object, forcing a database read. + # [reset_association] + # Unloads the associated object. The next access will query it from the database. # - # === Example + # ==== Example # - # An Account class declares has_one :beneficiary, which will add: - # * Account#beneficiary (similar to Beneficiary.where(account_id: id).first) - # * Account#beneficiary=(beneficiary) (similar to beneficiary.account_id = account.id; beneficiary.save) - # * Account#build_beneficiary (similar to Beneficiary.new(account_id: id)) - # * Account#create_beneficiary (similar to b = Beneficiary.new(account_id: id); b.save; b) - # * Account#create_beneficiary! (similar to b = Beneficiary.new(account_id: id); b.save!; b) - # * Account#reload_beneficiary + # class Account < ActiveRecord::Base + # has_one :beneficiary + # end # - # === Scopes + # Declaring has_one :beneficiary adds the following methods (and more): + # + # account = Account.find(5) + # beneficiary = Beneficiary.find(8) + # + # account.beneficiary # similar to Beneficiary.find_by(account_id: 5) + # account.beneficiary = beneficiary # similar to beneficiary.update(account_id: 5) + # account.build_beneficiary # similar to Beneficiary.new(account_id: 5) + # account.create_beneficiary # similar to Beneficiary.create(account_id: 5) + # account.create_beneficiary! # similar to Beneficiary.create!(account_id: 5) + # account.reload_beneficiary + # account.reset_beneficiary + # + # ==== Scopes # # You can pass a second argument +scope+ as a callable (i.e. proc or # lambda) to retrieve a specific record or customize the generated query @@ -2864,16 +3120,16 @@ module ActiveRecord::Associations::ClassMethods # has_one :employer, -> { joins(:company) } # has_one :latest_post, ->(blog) { where("created_at > ?", blog.enabled_at) } # - # === Options + # ==== Options # # The declaration can also include an +options+ hash to specialize the behavior of the association. # # Options are: - # [:class_name] + # [+:class_name+] # Specify the class name of the association. Use it only if that name can't be inferred # from the association name. So has_one :manager will by default be linked to the Manager class, but # if the real class name is Person, you'll have to specify it with this option. - # [:dependent] + # [+:dependent+] # Controls what happens to the associated object when # its owner is destroyed: # @@ -2885,28 +3141,28 @@ module ActiveRecord::Associations::ClassMethods # * :delete causes the associated object to be deleted directly from the database (so callbacks will not execute) # * :nullify causes the foreign key to be set to +NULL+. Polymorphic type column is also nullified # on polymorphic associations. Callbacks are not executed. - # * :restrict_with_exception causes an ActiveRecord::DeleteRestrictionError exception to be raised if there is an associated record + # * :restrict_with_exception causes an ActiveRecord::DeleteRestrictionError exception to be raised if there is an associated record # * :restrict_with_error causes an error to be added to the owner if there is an associated object # # Note that :dependent option is ignored when using :through option. - # [:foreign_key] + # [+:foreign_key+] # Specify the foreign key used for the association. By default this is guessed to be the name # of this class in lower-case and "_id" suffixed. So a Person class that makes a #has_one association # will use "person_id" as the default :foreign_key. # - # If you are going to modify the association (rather than just read from it), then it is - # a good idea to set the :inverse_of option. - # [:foreign_type] + # Setting the :foreign_key option prevents automatic detection of the association's + # inverse, so it is generally a good idea to set the :inverse_of option as well. + # [+:foreign_type+] # Specify the column used to store the associated object's type, if this is a polymorphic # association. By default this is guessed to be the name of the polymorphic association # specified on "as" option with a "_type" suffix. So a class that defines a # has_one :tag, as: :taggable association will use "taggable_type" as the # default :foreign_type. - # [:primary_key] + # [+:primary_key+] # Specify the method that returns the primary key used for the association. By default this is +id+. - # [:as] + # [+:as+] # Specifies a polymorphic interface (See #belongs_to). - # [:through] + # [+:through+] # Specifies a Join Model through which to perform the query. Options for :class_name, # :primary_key, and :foreign_key are ignored, as the association uses the # source reflection. You can only use a :through query through a #has_one @@ -2921,49 +3177,58 @@ module ActiveRecord::Associations::ClassMethods # a good idea to set the :inverse_of option on the source association on the # join model. This allows associated records to be built which will automatically create # the appropriate join model records when they are saved. (See the 'Association Join Models' - # section above.) - # [:disable_joins] + # and 'Setting Inverses' sections above.) + # [+:disable_joins+] # Specifies whether joins should be skipped for an association. If set to true, two or more queries # will be generated. Note that in some cases, if order or limit is applied, it will be done in-memory # due to database limitations. This option is only applicable on has_one :through associations as # +has_one+ alone does not perform a join. - # [:source] + # [+:source+] # Specifies the source association name used by #has_one :through queries. # Only use it if the name cannot be inferred from the association. # has_one :favorite, through: :favorites will look for a # :favorite on Favorite, unless a :source is given. - # [:source_type] + # [+:source_type+] # Specifies type of the source association used by #has_one :through queries where the source # association is a polymorphic #belongs_to. - # [:validate] + # [+:validate+] # When set to +true+, validates new objects added to association when saving the parent object. +false+ by default. # If you want to ensure associated objects are revalidated on every update, use +validates_associated+. - # [:autosave] - # If true, always save the associated object or destroy it if marked for destruction, - # when saving the parent object. If false, never save or destroy the associated object. - # By default, only save the associated object if it's a new record. + # [+:autosave+] + # If +true+, always saves the associated object or destroys it if marked for destruction, + # when saving the parent object. + # If +false+, never save or destroy the associated object. + # + # By default, only saves the associated object if it's a new record. Setting this option + # to +true+ also enables validations on the associated object unless explicitly disabled + # with validate: false. This is because saving an object with invalid associated + # objects would fail, so any associated objects will go through validation checks. # # Note that NestedAttributes::ClassMethods#accepts_nested_attributes_for sets # :autosave to true. - # [:touch] + # [+:touch+] # If true, the associated object will be touched (the +updated_at+ / +updated_on+ attributes set to current time) # when this record is either saved or destroyed. If you specify a symbol, that attribute # will be updated with the current time in addition to the +updated_at+ / +updated_on+ attribute. # Please note that no validation will be performed when touching, and only the +after_touch+, # +after_commit+, and +after_rollback+ callbacks will be executed. - # [:inverse_of] + # [+:inverse_of+] # Specifies the name of the #belongs_to association on the associated object # that is the inverse of this #has_one association. # See ActiveRecord::Associations::ClassMethods's overview on Bi-directional associations for more detail. - # [:required] + # [+:required+] # When set to +true+, the association will also have its presence validated. # This will validate the association itself, not the id. You can use # +:inverse_of+ to avoid an extra query during validation. - # [:strict_loading] + # [+:strict_loading+] # Enforces strict loading every time the associated record is loaded through this association. - # [:ensuring_owner_was] + # [+:ensuring_owner_was+] # Specifies an instance method to be called on the owner. The method must return true in order for the # associated records to be deleted in a background job. + # [+:query_constraints+] + # Serves as a composite foreign key. Defines the list of columns to be used to query the associated object. + # This is an optional option. By default Rails will attempt to derive the value automatically. + # When the value is set the Array size must match associated model's primary key or +query_constraints+ size. # # Option examples: # has_one :credit_card, dependent: :destroy # destroys the associated credit card @@ -2978,8 +3243,9 @@ module ActiveRecord::Associations::ClassMethods # has_one :primary_address, -> { where(primary: true) }, through: :addressables, source: :addressable # has_one :credit_card, required: true # has_one :credit_card, strict_loading: true + # has_one :employment_record_book, query_constraints: [:organization_id, :employee_id] # - # source://activerecord//lib/active_record/associations.rb#1639 + # source://activerecord//lib/active_record/associations.rb#1459 def has_one(name, scope = T.unsafe(nil), **options); end end @@ -2995,7 +3261,7 @@ end # # The CollectionAssociation class provides common methods to the collections # defined by +has_and_belongs_to_many+, +has_many+ or +has_many+ with -# the +:through association+ option. +# the :through association option. # # You need to be careful with assumptions regarding the target: The proxy # does not fetch records from the database until it needs them, but new @@ -3007,18 +3273,23 @@ end # If you need to work on all current children, new and existing records, # +load_target+ and the +loaded+ flag are your friends. # -# source://activerecord//lib/active_record/associations/collection_association.rb#31 +# source://activerecord//lib/active_record/associations/collection_association.rb#30 class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associations::Association - # source://activerecord//lib/active_record/associations/collection_association.rb#271 + # source://activerecord//lib/active_record/associations/collection_association.rb#279 def add_to_target(record, skip_callbacks: T.unsafe(nil), replace: T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/collection_association.rb#109 + # source://activerecord//lib/active_record/associations/collection_association.rb#117 def build(attributes = T.unsafe(nil), &block); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/associations/collection_association.rb#314 + def collection?; end + # Add +records+ to this association. Since +<<+ flattens its argument list # and inserts each record, +push+ and +concat+ behave identically. # - # source://activerecord//lib/active_record/associations/collection_association.rb#119 + # source://activerecord//lib/active_record/associations/collection_association.rb#127 def concat(*records); end # Removes +records+ from this association calling +before_remove+ and @@ -3029,7 +3300,7 @@ class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associ # are actually removed from the database, that depends precisely on # +delete_records+. They are in any case removed from the collection. # - # source://activerecord//lib/active_record/associations/collection_association.rb#178 + # source://activerecord//lib/active_record/associations/collection_association.rb#186 def delete(*records); end # Removes all records from the association without calling callbacks @@ -3046,7 +3317,7 @@ class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associ # # See delete for more info. # - # source://activerecord//lib/active_record/associations/collection_association.rb#142 + # source://activerecord//lib/active_record/associations/collection_association.rb#150 def delete_all(dependent = T.unsafe(nil)); end # Deletes the +records+ and removes them from this association calling @@ -3055,14 +3326,14 @@ class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associ # Note that this method removes records from the database ignoring the # +:dependent+ option. # - # source://activerecord//lib/active_record/associations/collection_association.rb#187 + # source://activerecord//lib/active_record/associations/collection_association.rb#195 def destroy(*records); end # Destroy all the records from this association. # # See destroy for more info. # - # source://activerecord//lib/active_record/associations/collection_association.rb#164 + # source://activerecord//lib/active_record/associations/collection_association.rb#172 def destroy_all; end # Returns true if the collection is empty. @@ -3076,55 +3347,61 @@ class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associ # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_association.rb#224 + # source://activerecord//lib/active_record/associations/collection_association.rb#232 def empty?; end - # source://activerecord//lib/active_record/associations/collection_association.rb#86 + # source://activerecord//lib/active_record/associations/collection_association.rb#94 def find(*args); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_association.rb#298 + # source://activerecord//lib/active_record/associations/collection_association.rb#306 def find_from_target?; end # Implements the ids reader method, e.g. foo.item_ids for Foo.has_many :items # - # source://activerecord//lib/active_record/associations/collection_association.rb#49 + # source://activerecord//lib/active_record/associations/collection_association.rb#51 def ids_reader; end # Implements the ids writer method, e.g. foo.item_ids= for Foo.has_many :items # - # source://activerecord//lib/active_record/associations/collection_association.rb#60 + # source://activerecord//lib/active_record/associations/collection_association.rb#62 def ids_writer(ids); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_association.rb#250 + # source://activerecord//lib/active_record/associations/collection_association.rb#258 def include?(record); end - # source://activerecord//lib/active_record/associations/collection_association.rb#262 + # source://activerecord//lib/active_record/associations/collection_association.rb#270 def load_target; end + # source://activerecord//lib/active_record/associations/collection_association.rb#31 + def nested_attributes_target; end + + # source://activerecord//lib/active_record/associations/collection_association.rb#31 + def nested_attributes_target=(_arg0); end + # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_association.rb#294 + # source://activerecord//lib/active_record/associations/collection_association.rb#302 def null_scope?; end # Implements the reader method, e.g. foo.items for Foo.has_many :items # - # source://activerecord//lib/active_record/associations/collection_association.rb#32 + # source://activerecord//lib/active_record/associations/collection_association.rb#34 def reader; end # Replace this collection with +other_array+. This will perform a diff # and delete/add only records that have changed. # - # source://activerecord//lib/active_record/associations/collection_association.rb#234 + # source://activerecord//lib/active_record/associations/collection_association.rb#242 def replace(other_array); end - # source://activerecord//lib/active_record/associations/collection_association.rb#79 + # source://activerecord//lib/active_record/associations/collection_association.rb#87 def reset; end - # source://activerecord//lib/active_record/associations/collection_association.rb#288 + # source://activerecord//lib/active_record/associations/collection_association.rb#296 def scope; end # Returns the size of the collection by executing a SELECT COUNT(*) @@ -3138,34 +3415,34 @@ class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associ # This method is abstract in the sense that it relies on # +count_records+, which is a method descendants have to provide. # - # source://activerecord//lib/active_record/associations/collection_association.rb#201 + # source://activerecord//lib/active_record/associations/collection_association.rb#209 def size; end - # source://activerecord//lib/active_record/associations/collection_association.rb#275 + # source://activerecord//lib/active_record/associations/collection_association.rb#283 def target=(record); end # Implements the writer method, e.g. foo.items= for Foo.has_many :items # - # source://activerecord//lib/active_record/associations/collection_association.rb#44 + # source://activerecord//lib/active_record/associations/collection_association.rb#46 def writer(records); end private - # source://activerecord//lib/active_record/associations/collection_association.rb#340 + # source://activerecord//lib/active_record/associations/collection_association.rb#352 def _create_record(attributes, raise = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/collection_association.rb#478 + # source://activerecord//lib/active_record/associations/collection_association.rb#490 def callback(method, record); end - # source://activerecord//lib/active_record/associations/collection_association.rb#484 + # source://activerecord//lib/active_record/associations/collection_association.rb#496 def callbacks_for(callback_name); end # @raise [ActiveRecord::Rollback] # - # source://activerecord//lib/active_record/associations/collection_association.rb#424 + # source://activerecord//lib/active_record/associations/collection_association.rb#436 def concat_records(records, raise = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/collection_association.rb#371 + # source://activerecord//lib/active_record/associations/collection_association.rb#383 def delete_or_destroy(records, method); end # Delete the given records from the association, @@ -3174,23 +3451,23 @@ class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associ # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/associations/collection_association.rb#400 + # source://activerecord//lib/active_record/associations/collection_association.rb#412 def delete_records(records, method); end # If the :inverse_of option has been # specified, then #find scans the entire collection. # - # source://activerecord//lib/active_record/associations/collection_association.rb#507 + # source://activerecord//lib/active_record/associations/collection_association.rb#519 def find_by_scan(*args); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_association.rb#493 + # source://activerecord//lib/active_record/associations/collection_association.rb#505 def include_in_memory?(record); end # Do the relevant stuff to insert the given record into the association collection. # - # source://activerecord//lib/active_record/associations/collection_association.rb#363 + # source://activerecord//lib/active_record/associations/collection_association.rb#375 def insert_record(record, validate = T.unsafe(nil), raise = T.unsafe(nil), &block); end # We have some records loaded from the database (persisted) and some that are @@ -3204,25 +3481,27 @@ class ActiveRecord::Associations::CollectionAssociation < ::ActiveRecord::Associ # * Any changes made to attributes on objects in the memory array are to be preserved # * Otherwise, attributes should have the value found in the database # - # source://activerecord//lib/active_record/associations/collection_association.rb#321 + # source://activerecord//lib/active_record/associations/collection_association.rb#333 def merge_target_lists(persisted, memory); end - # source://activerecord//lib/active_record/associations/collection_association.rb#385 + # source://activerecord//lib/active_record/associations/collection_association.rb#397 def remove_records(existing_records, records, method); end - # source://activerecord//lib/active_record/associations/collection_association.rb#416 + # source://activerecord//lib/active_record/associations/collection_association.rb#428 def replace_common_records_in_memory(new_target, original_target); end - # source://activerecord//lib/active_record/associations/collection_association.rb#443 + # source://activerecord//lib/active_record/associations/collection_association.rb#455 def replace_on_target(record, skip_callbacks, replace:, inversing: T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/collection_association.rb#404 + # source://activerecord//lib/active_record/associations/collection_association.rb#416 def replace_records(new_target, original_target); end - # source://activerecord//lib/active_record/associations/collection_association.rb#307 + # source://activerecord//lib/active_record/associations/collection_association.rb#319 def transaction(&block); end end +# = Active Record Collection Proxy +# # Collection proxies in Active Record are middlemen between an # association, and its target result set. # @@ -3248,11 +3527,11 @@ end # is computed directly through SQL and does not trigger by itself the # instantiation of the actual post records. # -# source://activerecord//lib/active_record/associations/collection_proxy.rb#29 +# source://activerecord//lib/active_record/associations/collection_proxy.rb#31 class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # @return [CollectionProxy] a new instance of CollectionProxy # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#30 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#32 def initialize(klass, association, **_arg2); end # Adds one or more +records+ to the collection by setting their foreign keys @@ -3277,7 +3556,7 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1031 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1049 def <<(*records); end # Equivalent to Array#==. Returns +true+ if the two arrays @@ -3300,33 +3579,36 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # person.pets == other # # => true # + # + # Note that unpersisted records can still be seen as equal: + # # other = [Pet.new(id: 1), Pet.new(id: 2)] # # person.pets == other - # # => false + # # => true # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#962 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#980 def ==(other); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def _select!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def and(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def and!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def annotate(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def annotate!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def annotate_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def annotate_values=(arg); end # Adds one or more +records+ to the collection by setting their foreign keys @@ -3351,10 +3633,10 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1031 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1049 def append(*records); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def arel(*_arg0, **_arg1, &_arg2); end # Returns a new object of the collection type that has been instantiated @@ -3382,12 +3664,12 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # person.pets.size # => 5 # size of the collection # person.pets.count # => 0 # count from database # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#316 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#318 def build(attributes = T.unsafe(nil), &block); end # -- # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#722 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#724 def calculate(operation, column_name); end # Equivalent to +delete_all+. The difference is that returns +self+, instead @@ -3397,7 +3679,7 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # running an SQL query into the database, the +updated_at+ column of # the object is not changed. # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1048 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1066 def clear; end # Adds one or more +records+ to the collection by setting their foreign keys @@ -3422,10 +3704,10 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1031 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1049 def concat(*records); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def construct_join_dependency(*_arg0, **_arg1, &_arg2); end # Returns a new object of the collection type that has been instantiated with @@ -3455,7 +3737,7 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#347 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#349 def create(attributes = T.unsafe(nil), &block); end # Like #create, except that if the record is invalid, raises an exception. @@ -3471,19 +3753,19 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # person.pets.create!(name: nil) # # => ActiveRecord::RecordInvalid: Validation failed: Name can't be blank # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#363 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#365 def create!(attributes = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def create_with(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def create_with!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def create_with_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def create_with_value=(arg); end # Deletes the +records+ supplied from the collection according to the strategy @@ -3602,7 +3884,7 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#618 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#620 def delete(*records); end # Deletes all the records from the collection according to the strategy @@ -3685,7 +3967,7 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # Pet.find(1, 2, 3) # # => ActiveRecord::RecordNotFound: Couldn't find all Pets with 'id': (1, 2, 3) # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#472 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#474 def delete_all(dependent = T.unsafe(nil)); end # Destroys the +records+ supplied and removes them from the collection. @@ -3757,7 +4039,7 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # Pet.find(4, 5, 6) # => ActiveRecord::RecordNotFound: Couldn't find all Pets with 'id': (4, 5, 6) # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#690 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#692 def destroy(*records); end # Deletes the records of the collection directly from the database @@ -3784,31 +4066,31 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # Pet.find(1) # => Couldn't find Pet with id=1 # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#499 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#501 def destroy_all; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def distinct(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def distinct!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def distinct_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def distinct_value=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def eager_load(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def eager_load!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def eager_load_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def eager_load_values=(arg); end # Returns +true+ if the collection is empty. If the collection has been @@ -3832,38 +4114,38 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#829 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#831 def empty?; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def except(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def excluding(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def excluding!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def extending(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def extending!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def extending_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def extending_values=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def extensions(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def extract_associated(*_arg0, **_arg1, &_arg2); end # Finds an object in the collection responding to the +id+. Uses the same - # rules as ActiveRecord::Base.find. Returns ActiveRecord::RecordNotFound + # rules as ActiveRecord::FinderMethods.find. Returns ActiveRecord::RecordNotFound # error if the object cannot be found. # # class Person < ActiveRecord::Base @@ -3889,46 +4171,46 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#136 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#138 def find(*args); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def from(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def from!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def from_clause(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def from_clause=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def group(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def group!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def group_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def group_values=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def having(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def having!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def having_clause(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def having_clause=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def in_order_of(*_arg0, **_arg1, &_arg2); end # Returns +true+ if the given +record+ is present in the collection. @@ -3944,52 +4226,52 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#925 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#927 def include?(record); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def includes(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def includes!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def includes_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def includes_values=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def insert(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def insert!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def insert_all(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def insert_all!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1100 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1118 def inspect; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def invert_where(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def invert_where!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def joins(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def joins!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def joins_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def joins_values=(arg); end # Returns the last record, or the last +n+ records, from the collection. @@ -4019,40 +4301,40 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # another_person_without.pets.last # => nil # another_person_without.pets.last(3) # => [] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#257 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#259 def last(limit = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def left_joins(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def left_outer_joins(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def left_outer_joins!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def left_outer_joins_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def left_outer_joins_values=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def limit(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def limit!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def limit_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def limit_value=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def load_async(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#42 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#44 def load_target; end # Returns +true+ if the association has been loaded, otherwise +false+. @@ -4063,7 +4345,7 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#51 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#53 def loaded; end # Returns +true+ if the association has been loaded, otherwise +false+. @@ -4074,25 +4356,25 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#51 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#53 def loaded?; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def lock(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def lock!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def lock_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def lock_value=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def merge(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def merge!(*_arg0, **_arg1, &_arg2); end # Returns a new object of the collection type that has been instantiated @@ -4120,81 +4402,101 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # person.pets.size # => 5 # size of the collection # person.pets.count # => 0 # count from database # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#316 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#318 def new(attributes = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def none(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def none!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def null_relation?(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def offset(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def offset!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def offset_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def offset_value=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def only(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def optimizer_hints(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def optimizer_hints!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def optimizer_hints_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def optimizer_hints_values=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def or(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def or!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def order(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def order!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def order_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def order_values=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#726 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#728 def pluck(*column_names); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def preload(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def preload!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def preload_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def preload_values=(arg); end # @raise [NoMethodError] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1038 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1056 def prepend(*args); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#929 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1123 + def pretty_print(pp); end + + # Returns the association object for the collection. + # + # class Person < ActiveRecord::Base + # has_many :pets + # end + # + # person.pets.proxy_association + # # => # + # + # Returns the same object as person.association(:pets), + # allowing you to make calls like person.pets.proxy_association.owner. + # + # See Associations::ClassMethods@Association+extensions for more. + # + # source://activerecord//lib/active_record/associations/collection_proxy.rb#944 def proxy_association; end # Adds one or more +records+ to the collection by setting their foreign keys @@ -4219,19 +4521,19 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1031 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1049 def push(*records); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def readonly(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def readonly!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def readonly_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def readonly_value=(arg); end # :method: to_ary @@ -4273,21 +4575,27 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # # # # ] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1006 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1024 def records; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def references(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def references!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def references_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def references_values=(arg); end + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def regroup(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def regroup!(*_arg0, **_arg1, &_arg2); end + # Reloads the collection from the database. Returns +self+. # # class Person < ActiveRecord::Base @@ -4303,19 +4611,19 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # person.pets.reload # fetches pets from the database # # => [#] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1067 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1085 def reload; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reorder(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reorder!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reordering_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reordering_value=(arg); end # Replaces this collection with +other_array+. This will perform a diff @@ -4336,18 +4644,18 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # => [#] # # If the supplied array has an incorrect association type, it raises - # an ActiveRecord::AssociationTypeMismatch error: + # an ActiveRecord::AssociationTypeMismatch error: # # person.pets.replace(["doo", "ggie", "gaga"]) # # => ActiveRecord::AssociationTypeMismatch: Pet expected, got String # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#389 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#391 def replace(other_array); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reselect(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reselect!(*_arg0, **_arg1, &_arg2); end # Unloads the association. Returns +self+. @@ -4367,39 +4675,39 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # person.pets # fetches pets from the database # # => [#] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1088 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1106 def reset; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1094 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1112 def reset_scope; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reverse_order(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reverse_order!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reverse_order_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def reverse_order_value=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def rewhere(*_arg0, **_arg1, &_arg2); end - # Returns a Relation object for the records in this association + # Returns a Relation object for the records in this association # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#934 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#949 def scope; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def scoping(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def select_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def select_values=(arg); end # Returns the size of the collection. If the collection hasn't been loaded, @@ -4427,41 +4735,41 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # # Because the collection is already loaded, this will behave like # # collection.size and no SQL count query is executed. # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#780 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#782 def size; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def skip_preloading!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def skip_query_cache!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def skip_query_cache_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def skip_query_cache_value=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def spawn(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def strict_loading(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def strict_loading!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def strict_loading_value(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def strict_loading_value=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def structurally_compatible?(*_arg0, **_arg1, &_arg2); end # Gives a record (or N records if a parameter is supplied) from the collection - # using the same rules as ActiveRecord::Base.take. + # using the same rules as ActiveRecord::FinderMethods.take. # # class Person < ActiveRecord::Base # has_many :pets @@ -4486,70 +4794,88 @@ class ActiveRecord::Associations::CollectionProxy < ::ActiveRecord::Relation # another_person_without.pets.take # => nil # another_person_without.pets.take(2) # => [] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#287 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#289 def take(limit = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#38 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#40 def target; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def uniq!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def unscope(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def unscope!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def unscope_values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def unscope_values=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def upsert(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def upsert_all(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def values(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def where(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def where!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def where_clause(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def where_clause=(arg); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1114 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def with(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def with!(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def with_recursive(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def with_recursive!(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def with_values(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 + def with_values=(arg); end + + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1137 def without(*_arg0, **_arg1, &_arg2); end private - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1135 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1158 def exec_queries; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1131 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1154 def find_from_target?; end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1122 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1145 def find_nth_from_last(index); end - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1117 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1140 def find_nth_with_limit(index, limit); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/collection_proxy.rb#1127 + # source://activerecord//lib/active_record/associations/collection_proxy.rb#1150 def null_scope?; end end @@ -4586,27 +4912,28 @@ module ActiveRecord::Associations::ForeignAssociation end # = Active Record Has Many Association +# # This is the proxy that handles a has many association. # # If the association has a :through option further specialization # is provided by its child HasManyThroughAssociation. # -# source://activerecord//lib/active_record/associations/has_many_association.rb#10 +# source://activerecord//lib/active_record/associations/has_many_association.rb#11 class ActiveRecord::Associations::HasManyAssociation < ::ActiveRecord::Associations::CollectionAssociation include ::ActiveRecord::Associations::ForeignAssociation - # source://activerecord//lib/active_record/associations/has_many_association.rb#13 + # source://activerecord//lib/active_record/associations/has_many_association.rb#14 def handle_dependency; end - # source://activerecord//lib/active_record/associations/has_many_association.rb#56 + # source://activerecord//lib/active_record/associations/has_many_association.rb#61 def insert_record(record, validate = T.unsafe(nil), raise = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/associations/has_many_association.rb#136 + # source://activerecord//lib/active_record/associations/has_many_association.rb#143 def _create_record(attributes, *_arg1); end - # source://activerecord//lib/active_record/associations/has_many_association.rb#132 + # source://activerecord//lib/active_record/associations/has_many_association.rb#139 def concat_records(records, *_arg1); end # Returns the number of records in this collection. @@ -4623,33 +4950,33 @@ class ActiveRecord::Associations::HasManyAssociation < ::ActiveRecord::Associati # If the collection is empty the target is set to an empty array and # the loaded flag is set to true as well. # - # source://activerecord//lib/active_record/associations/has_many_association.rb#75 + # source://activerecord//lib/active_record/associations/has_many_association.rb#80 def count_records; end - # source://activerecord//lib/active_record/associations/has_many_association.rb#107 + # source://activerecord//lib/active_record/associations/has_many_association.rb#112 def delete_count(method, scope); end - # source://activerecord//lib/active_record/associations/has_many_association.rb#115 + # source://activerecord//lib/active_record/associations/has_many_association.rb#120 def delete_or_nullify_all_records(method); end # Deletes the records according to the :dependent option. # - # source://activerecord//lib/active_record/associations/has_many_association.rb#122 + # source://activerecord//lib/active_record/associations/has_many_association.rb#127 def delete_records(records, method); end - # source://activerecord//lib/active_record/associations/has_many_association.rb#151 + # source://activerecord//lib/active_record/associations/has_many_association.rb#158 def difference(a, b); end - # source://activerecord//lib/active_record/associations/has_many_association.rb#155 + # source://activerecord//lib/active_record/associations/has_many_association.rb#162 def intersection(a, b); end - # source://activerecord//lib/active_record/associations/has_many_association.rb#93 + # source://activerecord//lib/active_record/associations/has_many_association.rb#98 def update_counter(difference, reflection = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/has_many_association.rb#144 + # source://activerecord//lib/active_record/associations/has_many_association.rb#151 def update_counter_if_success(saved_successfully, difference); end - # source://activerecord//lib/active_record/associations/has_many_association.rb#99 + # source://activerecord//lib/active_record/associations/has_many_association.rb#104 def update_counter_in_memory(difference, reflection = T.unsafe(nil)); end end @@ -4672,7 +4999,7 @@ class ActiveRecord::Associations::HasManyThroughAssociation < ::ActiveRecord::As private - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#86 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#90 def build_record(attributes); end # The through record (built with build_record) is temporarily cached @@ -4687,62 +5014,62 @@ class ActiveRecord::Associations::HasManyThroughAssociation < ::ActiveRecord::As # source://activerecord//lib/active_record/associations/has_many_through_association.rb#37 def concat_records(records); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#126 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#130 def delete_or_nullify_all_records(method); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#130 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#134 def delete_records(records, method); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#199 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#203 def delete_through_records(records); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#167 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#171 def difference(a, b); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#183 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#187 def distribution(array); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#215 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#219 def find_target; end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#173 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#177 def intersection(a, b); end # NOTE - not sure that we can actually cope with inverses here # # @return [Boolean] # - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#222 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#226 def invertible_for?(record); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#179 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#183 def mark_occurrence(distribution, record); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#106 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#110 def remove_records(existing_records, records, method); end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#77 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#81 def save_through_record(record); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#111 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#115 def target_reflection_has_associated_record?; end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#189 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#193 def through_records_for(record); end # Returns the value of attribute through_scope. # - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#68 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#69 def through_scope; end - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#70 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#71 def through_scope_attributes; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/has_many_through_association.rb#115 + # source://activerecord//lib/active_record/associations/has_many_through_association.rb#119 def update_through_counter?(method); end end @@ -4760,30 +5087,27 @@ class ActiveRecord::Associations::HasOneAssociation < ::ActiveRecord::Associatio private - # source://activerecord//lib/active_record/associations/has_one_association.rb#130 + # source://activerecord//lib/active_record/associations/has_one_association.rb#133 def _create_record(attributes, raise_error = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/has_one_association.rb#118 + # source://activerecord//lib/active_record/associations/has_one_association.rb#119 def nullify_owner_attributes(record); end - # source://activerecord//lib/active_record/associations/has_one_association.rb#94 + # source://activerecord//lib/active_record/associations/has_one_association.rb#95 def remove_target!(method); end - # source://activerecord//lib/active_record/associations/has_one_association.rb#54 + # source://activerecord//lib/active_record/associations/has_one_association.rb#59 def replace(record, save = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations/has_one_association.rb#90 - def replace_keys(record, force: T.unsafe(nil)); end - # The reason that the save param for replace is false, if for create (not just build), # is because the setting of the foreign keys is actually handled by the scoping when # the record is instantiated, and so they are set straight away and do not need to be # updated within replace. # - # source://activerecord//lib/active_record/associations/has_one_association.rb#86 + # source://activerecord//lib/active_record/associations/has_one_association.rb#91 def set_new_record(record); end - # source://activerecord//lib/active_record/associations/has_one_association.rb#122 + # source://activerecord//lib/active_record/associations/has_one_association.rb#125 def transaction_if(value, &block); end end @@ -4989,7 +5313,7 @@ class ActiveRecord::Associations::JoinDependency::JoinAssociation < ::ActiveReco # @return [Boolean] # - # source://activerecord//lib/active_record/associations/join_dependency/join_association.rb#78 + # source://activerecord//lib/active_record/associations/join_dependency/join_association.rb#80 def readonly?; end # Returns the value of attribute reflection. @@ -4999,7 +5323,7 @@ class ActiveRecord::Associations::JoinDependency::JoinAssociation < ::ActiveReco # @return [Boolean] # - # source://activerecord//lib/active_record/associations/join_dependency/join_association.rb#84 + # source://activerecord//lib/active_record/associations/join_dependency/join_association.rb#86 def strict_loading?; end # Returns the value of attribute table. @@ -5021,8 +5345,8 @@ class ActiveRecord::Associations::JoinDependency::JoinAssociation < ::ActiveReco private - # source://activerecord//lib/active_record/associations/join_dependency/join_association.rb#91 - def append_constraints(join, constraints); end + # source://activerecord//lib/active_record/associations/join_dependency/join_association.rb#93 + def append_constraints(connection, join, constraints); end end # source://activerecord//lib/active_record/associations/join_dependency/join_base.rb#8 @@ -5113,6 +5437,35 @@ class ActiveRecord::Associations::JoinDependency::JoinPart def table_name(*_arg0, **_arg1, &_arg2); end end +# source://activerecord//lib/active_record/associations/nested_error.rb#7 +class ActiveRecord::Associations::NestedError < ::ActiveModel::NestedError + # @return [NestedError] a new instance of NestedError + # + # source://activerecord//lib/active_record/associations/nested_error.rb#8 + def initialize(association, inner_error); end + + private + + # Returns the value of attribute association. + # + # source://activerecord//lib/active_record/associations/nested_error.rb#16 + def association; end + + # source://activerecord//lib/active_record/associations/nested_error.rb#18 + def compute_attribute(inner_error); end + + # source://activerecord//lib/active_record/associations/nested_error.rb#33 + def index; end + + # source://activerecord//lib/active_record/associations/nested_error.rb#28 + def index_errors_setting; end + + # source://activerecord//lib/active_record/associations/nested_error.rb#37 + def ordered_records; end +end + +# = Active Record \Preloader +# # Implements the details of eager loading of Active Record associations. # # Suppose that you have the following two Active Record models: @@ -5131,8 +5484,8 @@ end # # Author.includes(:books).where(name: ['bell hooks', 'Homer']).to_a # -# => SELECT `authors`.* FROM `authors` WHERE `name` IN ('bell hooks', 'Homer') -# => SELECT `books`.* FROM `books` WHERE `author_id` IN (2, 5) +# # SELECT `authors`.* FROM `authors` WHERE `name` IN ('bell hooks', 'Homer') +# # SELECT `books`.* FROM `books` WHERE `author_id` IN (2, 5) # # Active Record saves the ids of the records from the first query to use in # the second. Depending on the number of associations involved there can be @@ -5142,16 +5495,16 @@ end # Record will fall back to a slightly more resource-intensive single query: # # Author.includes(:books).where(books: {title: 'Illiad'}).to_a -# => SELECT `authors`.`id` AS t0_r0, `authors`.`name` AS t0_r1, `authors`.`age` AS t0_r2, -# `books`.`id` AS t1_r0, `books`.`title` AS t1_r1, `books`.`sales` AS t1_r2 -# FROM `authors` -# LEFT OUTER JOIN `books` ON `authors`.`id` = `books`.`author_id` -# WHERE `books`.`title` = 'Illiad' +# # SELECT `authors`.`id` AS t0_r0, `authors`.`name` AS t0_r1, `authors`.`age` AS t0_r2, +# # `books`.`id` AS t1_r0, `books`.`title` AS t1_r1, `books`.`sales` AS t1_r2 +# # FROM `authors` +# # LEFT OUTER JOIN `books` ON `authors`.`id` = `books`.`author_id` +# # WHERE `books`.`title` = 'Illiad' # # This could result in many rows that contain redundant data and it performs poorly at scale # and is therefore only used when necessary. # -# source://activerecord//lib/active_record/associations/preloader.rb#44 +# source://activerecord//lib/active_record/associations/preloader.rb#46 class ActiveRecord::Associations::Preloader extend ::ActiveSupport::Autoload @@ -5175,15 +5528,16 @@ class ActiveRecord::Associations::Preloader # for an Author. # - an Array which specifies multiple association names. This array # is processed recursively. For example, specifying [:avatar, :books] - # allows this method to preload an author's avatar as well as all of his + # allows this method to preload an author's avatar as well as all of their # books. # - a Hash which specifies multiple association names, as well as # association names for the to-be-preloaded association objects. For # example, specifying { author: :avatar } will preload a # book's author, as well as that author's avatar. # - # +:associations+ has the same format as the +:include+ method in - # ActiveRecord::QueryMethods. So +associations+ could look like this: + # +:associations+ has the same format as the arguments to + # ActiveRecord::QueryMethods#includes. So +associations+ could look like + # this: # # :books # [ :books, :author ] @@ -5198,238 +5552,241 @@ class ActiveRecord::Associations::Preloader # # @return [Preloader] a new instance of Preloader # - # source://activerecord//lib/active_record/associations/preloader.rb#96 + # source://activerecord//lib/active_record/associations/preloader.rb#99 def initialize(records:, associations:, scope: T.unsafe(nil), available_records: T.unsafe(nil), associate_by_default: T.unsafe(nil)); end # Returns the value of attribute associate_by_default. # - # source://activerecord//lib/active_record/associations/preloader.rb#54 + # source://activerecord//lib/active_record/associations/preloader.rb#56 def associate_by_default; end # Returns the value of attribute associations. # - # source://activerecord//lib/active_record/associations/preloader.rb#54 + # source://activerecord//lib/active_record/associations/preloader.rb#56 def associations; end - # source://activerecord//lib/active_record/associations/preloader.rb#123 + # source://activerecord//lib/active_record/associations/preloader.rb#126 def branches; end - # source://activerecord//lib/active_record/associations/preloader.rb#117 + # source://activerecord//lib/active_record/associations/preloader.rb#120 def call; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader.rb#113 + # source://activerecord//lib/active_record/associations/preloader.rb#116 def empty?; end - # source://activerecord//lib/active_record/associations/preloader.rb#127 + # source://activerecord//lib/active_record/associations/preloader.rb#130 def loaders; end # Returns the value of attribute records. # - # source://activerecord//lib/active_record/associations/preloader.rb#54 + # source://activerecord//lib/active_record/associations/preloader.rb#56 def records; end # Returns the value of attribute scope. # - # source://activerecord//lib/active_record/associations/preloader.rb#54 + # source://activerecord//lib/active_record/associations/preloader.rb#56 def scope; end end -# source://activerecord//lib/active_record/associations/preloader/association.rb#6 +# source://activerecord//lib/active_record/associations/preloader/association.rb#8 class ActiveRecord::Associations::Preloader::Association # @return [Association] a new instance of Association # - # source://activerecord//lib/active_record/associations/preloader/association.rb#87 + # source://activerecord//lib/active_record/associations/preloader/association.rb#104 def initialize(klass, owners, reflection, preload_scope, reflection_scope, associate_by_default); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#202 + # source://activerecord//lib/active_record/associations/preloader/association.rb#218 def associate_records_from_unscoped(unscoped_records); end # The name of the key on the associated records # - # source://activerecord//lib/active_record/associations/preloader/association.rb#144 + # source://activerecord//lib/active_record/associations/preloader/association.rb#161 def association_key_name; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#102 + # source://activerecord//lib/active_record/associations/preloader/association.rb#119 def future_classes; end # Returns the value of attribute klass. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#85 + # source://activerecord//lib/active_record/associations/preloader/association.rb#102 def klass; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#180 + # source://activerecord//lib/active_record/associations/preloader/association.rb#197 def load_records(raw_records = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/association.rb#159 + # source://activerecord//lib/active_record/associations/preloader/association.rb#176 def loaded?(owner); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#148 + # source://activerecord//lib/active_record/associations/preloader/association.rb#165 def loader_query; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#152 + # source://activerecord//lib/active_record/associations/preloader/association.rb#169 def owners_by_key; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#137 + # source://activerecord//lib/active_record/associations/preloader/association.rb#154 def preloaded_records; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#131 + # source://activerecord//lib/active_record/associations/preloader/association.rb#148 def records_by_owner; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#118 + # source://activerecord//lib/active_record/associations/preloader/association.rb#135 def run; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/association.rb#114 + # source://activerecord//lib/active_record/associations/preloader/association.rb#131 def run?; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#110 + # source://activerecord//lib/active_record/associations/preloader/association.rb#127 def runnable_loaders; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#167 + # source://activerecord//lib/active_record/associations/preloader/association.rb#184 def scope; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#171 + # source://activerecord//lib/active_record/associations/preloader/association.rb#188 def set_inverse(record); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#98 + # source://activerecord//lib/active_record/associations/preloader/association.rb#115 def table_name; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#163 + # source://activerecord//lib/active_record/associations/preloader/association.rb#180 def target_for(owner); end private - # source://activerecord//lib/active_record/associations/preloader/association.rb#229 + # source://activerecord//lib/active_record/associations/preloader/association.rb#245 def associate_records_to_owner(owner, records); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#257 + # source://activerecord//lib/active_record/associations/preloader/association.rb#282 def association_key_type; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#269 + # source://activerecord//lib/active_record/associations/preloader/association.rb#294 def build_scope; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#285 + # source://activerecord//lib/active_record/associations/preloader/association.rb#310 def cascade_strict_loading(scope); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#249 + # source://activerecord//lib/active_record/associations/preloader/association.rb#274 def convert_key(key); end + # source://activerecord//lib/active_record/associations/preloader/association.rb#266 + def derive_key(owner, key); end + # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/association.rb#241 + # source://activerecord//lib/active_record/associations/preloader/association.rb#258 def key_conversion_required?; end # Returns the value of attribute model. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#222 + # source://activerecord//lib/active_record/associations/preloader/association.rb#238 def model; end # The name of the key on the model which declares the association # - # source://activerecord//lib/active_record/associations/preloader/association.rb#225 + # source://activerecord//lib/active_record/associations/preloader/association.rb#241 def owner_key_name; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#261 + # source://activerecord//lib/active_record/associations/preloader/association.rb#286 def owner_key_type; end # Returns the value of attribute owners. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#222 + # source://activerecord//lib/active_record/associations/preloader/association.rb#238 def owners; end # Returns the value of attribute preload_scope. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#222 + # source://activerecord//lib/active_record/associations/preloader/association.rb#238 def preload_scope; end # Returns the value of attribute reflection. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#222 + # source://activerecord//lib/active_record/associations/preloader/association.rb#238 def reflection; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#265 + # source://activerecord//lib/active_record/associations/preloader/association.rb#290 def reflection_scope; end end -# source://activerecord//lib/active_record/associations/preloader/association.rb#7 +# source://activerecord//lib/active_record/associations/preloader/association.rb#9 class ActiveRecord::Associations::Preloader::Association::LoaderQuery # @return [LoaderQuery] a new instance of LoaderQuery # - # source://activerecord//lib/active_record/associations/preloader/association.rb#10 + # source://activerecord//lib/active_record/associations/preloader/association.rb#12 def initialize(scope, association_key_name); end # Returns the value of attribute association_key_name. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#8 + # source://activerecord//lib/active_record/associations/preloader/association.rb#10 def association_key_name; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/association.rb#15 + # source://activerecord//lib/active_record/associations/preloader/association.rb#17 def eql?(other); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#21 + # source://activerecord//lib/active_record/associations/preloader/association.rb#24 def hash; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#38 + # source://activerecord//lib/active_record/associations/preloader/association.rb#41 def load_records_for_keys(keys, &block); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#29 + # source://activerecord//lib/active_record/associations/preloader/association.rb#32 def load_records_in_batch(loaders); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#25 + # source://activerecord//lib/active_record/associations/preloader/association.rb#28 def records_for(loaders); end # Returns the value of attribute scope. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#8 + # source://activerecord//lib/active_record/associations/preloader/association.rb#10 def scope; end end -# source://activerecord//lib/active_record/associations/preloader/association.rb#43 +# source://activerecord//lib/active_record/associations/preloader/association.rb#60 class ActiveRecord::Associations::Preloader::Association::LoaderRecords # @return [LoaderRecords] a new instance of LoaderRecords # - # source://activerecord//lib/active_record/associations/preloader/association.rb#44 + # source://activerecord//lib/active_record/associations/preloader/association.rb#61 def initialize(loaders, loader_query); end - # source://activerecord//lib/active_record/associations/preloader/association.rb#53 + # source://activerecord//lib/active_record/associations/preloader/association.rb#70 def records; end private - # source://activerecord//lib/active_record/associations/preloader/association.rb#80 + # source://activerecord//lib/active_record/associations/preloader/association.rb#97 def already_loaded_records; end # Returns the value of attribute already_loaded_records_by_key. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#58 + # source://activerecord//lib/active_record/associations/preloader/association.rb#75 def already_loaded_records_by_key; end # Returns the value of attribute keys_to_load. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#58 + # source://activerecord//lib/active_record/associations/preloader/association.rb#75 def keys_to_load; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#74 + # source://activerecord//lib/active_record/associations/preloader/association.rb#91 def load_records; end # Returns the value of attribute loader_query. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#58 + # source://activerecord//lib/active_record/associations/preloader/association.rb#75 def loader_query; end # Returns the value of attribute loaders. # - # source://activerecord//lib/active_record/associations/preloader/association.rb#58 + # source://activerecord//lib/active_record/associations/preloader/association.rb#75 def loaders; end - # source://activerecord//lib/active_record/associations/preloader/association.rb#60 + # source://activerecord//lib/active_record/associations/preloader/association.rb#77 def populate_keys_to_load_and_already_loaded_records; end end @@ -5478,22 +5835,22 @@ class ActiveRecord::Associations::Preloader::Branch # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/branch.rb#66 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#72 def done?; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#21 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#27 def future_classes; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#74 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#80 def grouped_records; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#25 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#31 def immediate_future_classes; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#47 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#53 def likely_reflections; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#112 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#118 def loaders; end # Returns the value of attribute parent. @@ -5503,10 +5860,10 @@ class ActiveRecord::Associations::Preloader::Branch # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/branch.rb#102 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#108 def polymorphic?; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#62 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#68 def preloaded_records; end # Sets the attribute preloaded_records @@ -5516,15 +5873,15 @@ class ActiveRecord::Associations::Preloader::Branch # source://activerecord//lib/active_record/associations/preloader/branch.rb#9 def preloaded_records=(_arg0); end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#85 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#91 def preloaders_for_reflection(reflection, reflection_records); end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/branch.rb#54 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#60 def root?; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#70 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#76 def runnable_loaders; end # Returns the value of attribute scope. @@ -5532,28 +5889,28 @@ class ActiveRecord::Associations::Preloader::Branch # source://activerecord//lib/active_record/associations/preloader/branch.rb#8 def scope; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#58 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#64 def source_records; end - # source://activerecord//lib/active_record/associations/preloader/branch.rb#37 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#43 def target_classes; end private - # source://activerecord//lib/active_record/associations/preloader/branch.rb#120 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#126 def build_children(children); end # Returns a class containing the logic needed to load preload the data # and attach it to a relation. The class returned implements a `run` method # that accepts a preloader. # - # source://activerecord//lib/active_record/associations/preloader/branch.rb#137 + # source://activerecord//lib/active_record/associations/preloader/branch.rb#143 def preloader_for(reflection); end end # source://activerecord//lib/active_record/associations/preloader/through_association.rb#6 class ActiveRecord::Associations::Preloader::ThroughAssociation < ::ActiveRecord::Associations::Preloader::Association - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#51 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#49 def future_classes; end # source://activerecord//lib/active_record/associations/preloader/through_association.rb#7 @@ -5562,53 +5919,53 @@ class ActiveRecord::Associations::Preloader::ThroughAssociation < ::ActiveRecord # source://activerecord//lib/active_record/associations/preloader/through_association.rb#11 def records_by_owner; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#41 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#39 def runnable_loaders; end private # @return [Boolean] # - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#67 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#65 def data_available?; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#76 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#74 def middle_records; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#100 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#98 def preload_index; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#72 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#70 def source_preloaders; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#92 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#90 def source_records_by_owner; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#88 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#86 def source_reflection; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#80 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#78 def through_preloaders; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#96 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#94 def through_records_by_owner; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#84 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#82 def through_reflection; end - # source://activerecord//lib/active_record/associations/preloader/through_association.rb#106 + # source://activerecord//lib/active_record/associations/preloader/through_association.rb#104 def through_scope; end end # source://activerecord//lib/active_record/associations/singular_association.rb#6 class ActiveRecord::Associations::SingularAssociation < ::ActiveRecord::Associations::Association - # source://activerecord//lib/active_record/associations/singular_association.rb#22 + # source://activerecord//lib/active_record/associations/singular_association.rb#28 def build(attributes = T.unsafe(nil), &block); end # Implements the reload reader method, e.g. foo.reload_bar for # Foo.has_one :bar # - # source://activerecord//lib/active_record/associations/singular_association.rb#30 + # source://activerecord//lib/active_record/associations/singular_association.rb#36 def force_reload_reader; end # Implements the reader method, e.g. foo.bar for Foo.has_one :bar @@ -5616,28 +5973,35 @@ class ActiveRecord::Associations::SingularAssociation < ::ActiveRecord::Associat # source://activerecord//lib/active_record/associations/singular_association.rb#7 def reader; end - # Implements the writer method, e.g. foo.bar= for Foo.belongs_to :bar + # Resets the \loaded flag to +false+ and sets the \target to +nil+. # # source://activerecord//lib/active_record/associations/singular_association.rb#18 + def reset; end + + # Implements the writer method, e.g. foo.bar= for Foo.belongs_to :bar + # + # source://activerecord//lib/active_record/associations/singular_association.rb#24 def writer(record); end private - # source://activerecord//lib/active_record/associations/singular_association.rb#56 + # @raise [RecordInvalid] + # + # source://activerecord//lib/active_record/associations/singular_association.rb#62 def _create_record(attributes, raise_error = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/associations/singular_association.rb#40 + # source://activerecord//lib/active_record/associations/singular_association.rb#46 def find_target; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/associations/singular_association.rb#48 + # source://activerecord//lib/active_record/associations/singular_association.rb#54 def replace(record); end - # source://activerecord//lib/active_record/associations/singular_association.rb#36 + # source://activerecord//lib/active_record/associations/singular_association.rb#42 def scope_for_create; end - # source://activerecord//lib/active_record/associations/singular_association.rb#52 + # source://activerecord//lib/active_record/associations/singular_association.rb#58 def set_new_record(record); end end @@ -5650,7 +6014,7 @@ module ActiveRecord::Associations::ThroughAssociation private - # source://activerecord//lib/active_record/associations/through_association.rb#109 + # source://activerecord//lib/active_record/associations/through_association.rb#116 def build_record(attributes); end # Construct attributes for :through pointing to owner and associate. This is used by the @@ -5666,24 +6030,24 @@ module ActiveRecord::Associations::ThroughAssociation # situation it is more natural for the user to just create or modify their join records # directly as required. # - # source://activerecord//lib/active_record/associations/through_association.rb#53 + # source://activerecord//lib/active_record/associations/through_association.rb#57 def construct_join_attributes(*records); end - # source://activerecord//lib/active_record/associations/through_association.rb#89 + # source://activerecord//lib/active_record/associations/through_association.rb#96 def ensure_mutable; end - # source://activerecord//lib/active_record/associations/through_association.rb#99 + # source://activerecord//lib/active_record/associations/through_association.rb#106 def ensure_not_nested; end # @return [Boolean] # - # source://activerecord//lib/active_record/associations/through_association.rb#85 + # source://activerecord//lib/active_record/associations/through_association.rb#90 def foreign_key_present?; end # Note: this does not capture all cases, for example it would be impractical # to try to properly support stale-checking for nested associations. # - # source://activerecord//lib/active_record/associations/through_association.rb#79 + # source://activerecord//lib/active_record/associations/through_association.rb#82 def stale_state; end # We merge in these scopes for two reasons: @@ -5691,14 +6055,17 @@ module ActiveRecord::Associations::ThroughAssociation # 1. To get the default_scope conditions for any of the other reflections in the chain # 2. To get the type conditions for any STI models in the chain # - # source://activerecord//lib/active_record/associations/through_association.rb#30 + # source://activerecord//lib/active_record/associations/through_association.rb#34 def target_scope; end - # source://activerecord//lib/active_record/associations/through_association.rb#22 + # source://activerecord//lib/active_record/associations/through_association.rb#26 def through_association; end - # source://activerecord//lib/active_record/associations/through_association.rb#10 + # source://activerecord//lib/active_record/associations/through_association.rb#14 def through_reflection; end + + # source://activerecord//lib/active_record/associations/through_association.rb#10 + def transaction(&block); end end # source://activerecord//lib/active_record/asynchronous_queries_tracker.rb#4 @@ -5763,17 +6130,14 @@ end # AsynchronousQueryInsideTransactionError will be raised when attempting # to perform an asynchronous query from inside a transaction # -# source://activerecord//lib/active_record/errors.rb#426 +# source://activerecord//lib/active_record/errors.rb#528 class ActiveRecord::AsynchronousQueryInsideTransactionError < ::ActiveRecord::ActiveRecordError; end -# source://activerecord//lib/active_record/attribute_assignment.rb#6 +# source://activerecord//lib/active_record/attribute_assignment.rb#4 module ActiveRecord::AttributeAssignment - include ::ActiveModel::ForbiddenAttributesProtection - include ::ActiveModel::AttributeAssignment - private - # source://activerecord//lib/active_record/attribute_assignment.rb#10 + # source://activerecord//lib/active_record/attribute_assignment.rb#6 def _assign_attributes(attributes); end # Instantiates objects for all attribute classes that needs more than one constructor parameter. This is done @@ -5783,24 +6147,19 @@ module ActiveRecord::AttributeAssignment # parentheses to have the parameters typecasted before they're used in the constructor. Use i for Integer and # f for Float. If all the values for a given attribute are empty, the attribute will be set to +nil+. # - # source://activerecord//lib/active_record/attribute_assignment.rb#40 + # source://activerecord//lib/active_record/attribute_assignment.rb#28 def assign_multiparameter_attributes(pairs); end - # Assign any deferred nested attributes after the base attributes have been set. - # - # source://activerecord//lib/active_record/attribute_assignment.rb#30 - def assign_nested_parameter_attributes(pairs); end - - # source://activerecord//lib/active_record/attribute_assignment.rb#46 + # source://activerecord//lib/active_record/attribute_assignment.rb#34 def execute_callstack_for_multiparameter_attributes(callstack); end - # source://activerecord//lib/active_record/attribute_assignment.rb#64 + # source://activerecord//lib/active_record/attribute_assignment.rb#52 def extract_callstack_for_multiparameter_attributes(pairs); end - # source://activerecord//lib/active_record/attribute_assignment.rb#82 + # source://activerecord//lib/active_record/attribute_assignment.rb#70 def find_parameter_position(multiparameter_name); end - # source://activerecord//lib/active_record/attribute_assignment.rb#78 + # source://activerecord//lib/active_record/attribute_assignment.rb#66 def type_cast_attribute_value(multiparameter_name, value); end end @@ -5808,27 +6167,27 @@ end # {ActiveRecord::Base#attributes=}[rdoc-ref:AttributeAssignment#attributes=] method. # The exception has an +attribute+ property that is the name of the offending attribute. # -# source://activerecord//lib/active_record/errors.rb#352 +# source://activerecord//lib/active_record/errors.rb#436 class ActiveRecord::AttributeAssignmentError < ::ActiveRecord::ActiveRecordError # @return [AttributeAssignmentError] a new instance of AttributeAssignmentError # - # source://activerecord//lib/active_record/errors.rb#355 + # source://activerecord//lib/active_record/errors.rb#439 def initialize(message = T.unsafe(nil), exception = T.unsafe(nil), attribute = T.unsafe(nil)); end # Returns the value of attribute attribute. # - # source://activerecord//lib/active_record/errors.rb#353 + # source://activerecord//lib/active_record/errors.rb#437 def attribute; end # Returns the value of attribute exception. # - # source://activerecord//lib/active_record/errors.rb#353 + # source://activerecord//lib/active_record/errors.rb#437 def exception; end end # = Active Record Attribute Methods # -# source://activerecord//lib/active_record/attribute_methods.rb#8 +# source://activerecord//lib/active_record/attribute_methods.rb#7 module ActiveRecord::AttributeMethods extend ::ActiveSupport::Concern extend ::ActiveSupport::Autoload @@ -5851,46 +6210,49 @@ module ActiveRecord::AttributeMethods mixes_in_class_methods ::ActiveRecord::AttributeMethods::Write::ClassMethods mixes_in_class_methods ::ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods mixes_in_class_methods ::ActiveRecord::AttributeMethods::TimeZoneConversion::ClassMethods - mixes_in_class_methods ::ActiveRecord::AttributeMethods::Dirty::ClassMethods mixes_in_class_methods ::ActiveRecord::AttributeMethods::Serialization::ClassMethods - # Returns the value of the attribute identified by attr_name after it has been typecast (for example, - # "2004-12-12" in a date column is cast to a date object, like Date.new(2004, 12, 12)). It raises - # ActiveModel::MissingAttributeError if the identified attribute is missing. - # - # Note: +:id+ is always present. + # Returns the value of the attribute identified by +attr_name+ after it has + # been type cast. (For information about specific type casting behavior, see + # the types under ActiveModel::Type.) # # class Person < ActiveRecord::Base # belongs_to :organization # end # - # person = Person.new(name: 'Francesco', age: '22') - # person[:name] # => "Francesco" - # person[:age] # => 22 + # person = Person.new(name: "Francesco", date_of_birth: "2004-12-12") + # person[:name] # => "Francesco" + # person[:date_of_birth] # => Date.new(2004, 12, 12) + # person[:organization_id] # => nil + # + # Raises ActiveModel::MissingAttributeError if the attribute is missing. + # Note, however, that the +id+ attribute will never be considered missing. # - # person = Person.select('id').first - # person[:name] # => ActiveModel::MissingAttributeError: missing attribute: name - # person[:organization_id] # => ActiveModel::MissingAttributeError: missing attribute: organization_id + # person = Person.select(:name).first + # person[:name] # => "Francesco" + # person[:date_of_birth] # => ActiveModel::MissingAttributeError: missing attribute 'date_of_birth' for Person + # person[:organization_id] # => ActiveModel::MissingAttributeError: missing attribute 'organization_id' for Person + # person[:id] # => nil # - # source://activerecord//lib/active_record/attribute_methods.rb#329 + # source://activerecord//lib/active_record/attribute_methods.rb#414 def [](attr_name); end - # Updates the attribute identified by attr_name with the specified +value+. + # Updates the attribute identified by +attr_name+ using the specified + # +value+. The attribute value will be type cast upon being read. # # class Person < ActiveRecord::Base # end # # person = Person.new - # person[:age] = '22' - # person[:age] # => 22 - # person[:age].class # => Integer + # person[:date_of_birth] = "2004-12-12" + # person[:date_of_birth] # => Date.new(2004, 12, 12) # - # source://activerecord//lib/active_record/attribute_methods.rb#342 + # source://activerecord//lib/active_record/attribute_methods.rb#427 def []=(attr_name, value); end # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#240 + # source://activerecord//lib/active_record/attribute_methods.rb#321 def _has_attribute?(attr_name); end # Returns the name of all database fields which have been read from this @@ -5922,7 +6284,7 @@ module ActiveRecord::AttributeMethods # end # end # - # source://activerecord//lib/active_record/attribute_methods.rb#374 + # source://activerecord//lib/active_record/attribute_methods.rb#459 def accessed_fields; end # Returns an #inspect-like string for the value of the @@ -5941,7 +6303,7 @@ module ActiveRecord::AttributeMethods # person.attribute_for_inspect(:tag_ids) # # => "[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]" # - # source://activerecord//lib/active_record/attribute_methods.rb#283 + # source://activerecord//lib/active_record/attribute_methods.rb#364 def attribute_for_inspect(attr_name); end # Returns an array of names for the attributes available on this object. @@ -5953,7 +6315,7 @@ module ActiveRecord::AttributeMethods # person.attribute_names # # => ["id", "created_at", "updated_at", "name", "age"] # - # source://activerecord//lib/active_record/attribute_methods.rb#252 + # source://activerecord//lib/active_record/attribute_methods.rb#333 def attribute_names; end # Returns +true+ if the specified +attribute+ has been set by the user or by a @@ -5974,7 +6336,7 @@ module ActiveRecord::AttributeMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#305 + # source://activerecord//lib/active_record/attribute_methods.rb#386 def attribute_present?(attr_name); end # Returns a hash of all the attributes with their names as keys and the values of the attributes as values. @@ -5986,7 +6348,7 @@ module ActiveRecord::AttributeMethods # person.attributes # # => {"id"=>3, "created_at"=>Sun, 21 Oct 2012 04:53:04, "updated_at"=>Sun, 21 Oct 2012 04:53:04, "name"=>"Francesco", "age"=>22} # - # source://activerecord//lib/active_record/attribute_methods.rb#264 + # source://activerecord//lib/active_record/attribute_methods.rb#345 def attributes; end # Returns +true+ if the given attribute is in the attributes hash, otherwise +false+. @@ -6003,7 +6365,7 @@ module ActiveRecord::AttributeMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#234 + # source://activerecord//lib/active_record/attribute_methods.rb#315 def has_attribute?(attr_name); end # A Person object with a name attribute can ask person.respond_to?(:name), @@ -6025,40 +6387,48 @@ module ActiveRecord::AttributeMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#207 + # source://activerecord//lib/active_record/attribute_methods.rb#290 def respond_to?(name, include_private = T.unsafe(nil)); end private # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#379 + # source://activerecord//lib/active_record/attribute_methods.rb#494 def attribute_method?(attr_name); end # Filters out the virtual columns and also primary keys, from the attribute names, when the primary # key is to be generated (e.g. the id attribute has no value). # - # source://activerecord//lib/active_record/attribute_methods.rb#399 + # source://activerecord//lib/active_record/attribute_methods.rb#514 def attributes_for_create(attribute_names); end # Filters the primary keys, readonly attributes and virtual columns from the attribute names. # - # source://activerecord//lib/active_record/attribute_methods.rb#389 + # source://activerecord//lib/active_record/attribute_methods.rb#503 def attributes_for_update(attribute_names); end - # source://activerecord//lib/active_record/attribute_methods.rb#384 + # source://activerecord//lib/active_record/attribute_methods.rb#498 def attributes_with_values(attribute_names); end - # source://activerecord//lib/active_record/attribute_methods.rb#407 + # source://activerecord//lib/active_record/attribute_methods.rb#522 def format_for_inspect(name, value); end + # source://activerecord//lib/active_record/attribute_methods.rb#474 + def method_missing(name, *_arg1, **_arg2, &_arg3); end + # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#423 + # source://activerecord//lib/active_record/attribute_methods.rb#538 def pk_attribute?(name); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/attribute_methods.rb#464 + def respond_to_missing?(name, include_private = T.unsafe(nil)); end + class << self - # source://activerecord//lib/active_record/attribute_methods.rb#31 + # source://activerecord//lib/active_record/attribute_methods.rb#30 def dangerous_attribute_methods; end end @@ -6066,9 +6436,12 @@ module ActiveRecord::AttributeMethods def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end + def default_column_serializer; end + def default_column_serializer=(value); end + def default_column_serializer?; end def partial_inserts; end def partial_inserts=(value); end def partial_inserts?; end @@ -6089,8 +6462,8 @@ module ActiveRecord::AttributeMethods module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end def partial_inserts; end def partial_inserts?; end def partial_updates; end @@ -6143,12 +6516,12 @@ module ActiveRecord::AttributeMethods::BeforeTypeCast # task.attributes_before_type_cast # # => {"id"=>nil, "title"=>nil, "is_done"=>true, "completed_on"=>"2012-10-21", "created_at"=>nil, "updated_at"=>nil} # - # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#65 + # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#82 def attributes_before_type_cast; end # Returns a hash of attributes for assignment to the database. # - # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#70 + # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#87 def attributes_for_database; end # Returns the value of the attribute identified by +attr_name+ before @@ -6167,19 +6540,33 @@ module ActiveRecord::AttributeMethods::BeforeTypeCast # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#48 def read_attribute_before_type_cast(attr_name); end + # Returns the value of the attribute identified by +attr_name+ after + # serialization. + # + # class Book < ActiveRecord::Base + # enum :status, { draft: 1, published: 2 } + # end + # + # book = Book.new(status: "published") + # book.read_attribute(:status) # => "published" + # book.read_attribute_for_database(:status) # => 2 + # + # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#65 + def read_attribute_for_database(attr_name); end + private # Dispatch target for *_before_type_cast attribute methods. # - # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#76 + # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#93 def attribute_before_type_cast(attr_name); end # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#84 + # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#101 def attribute_came_from_user?(attr_name); end - # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#80 + # source://activerecord//lib/active_record/attribute_methods/before_type_cast.rb#97 def attribute_for_database(attr_name); end end @@ -6187,9 +6574,30 @@ end module ActiveRecord::AttributeMethods::ClassMethods # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#186 + # source://activerecord//lib/active_record/attribute_methods.rb#259 def _has_attribute?(attr_name); end + # Allows you to make aliases for attributes. + # + # class Person < ActiveRecord::Base + # alias_attribute :nickname, :name + # end + # + # person = Person.create(name: 'Bob') + # person.name # => "Bob" + # person.nickname # => "Bob" + # + # The alias can also be used for querying: + # + # Person.where(nickname: "Bob") + # # SELECT "people".* FROM "people" WHERE "people"."name" = "Bob" + # + # source://activerecord//lib/active_record/attribute_methods.rb#66 + def alias_attribute(new_name, old_name); end + + # source://activerecord//lib/active_record/attribute_methods.rb#87 + def alias_attribute_method_definition(code_generator, pattern, new_name, old_name); end + # Returns +true+ if +attribute+ is an attribute method and table exists, # +false+ otherwise. # @@ -6202,9 +6610,14 @@ module ActiveRecord::AttributeMethods::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#150 + # source://activerecord//lib/active_record/attribute_methods.rb#223 def attribute_method?(attribute); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/attribute_methods.rb#98 + def attribute_methods_generated?; end + # Returns an array of column names as strings if it's not an abstract class and # table exists. Otherwise it returns an empty array. # @@ -6214,7 +6627,7 @@ module ActiveRecord::AttributeMethods::ClassMethods # Person.attribute_names # # => ["id", "created_at", "updated_at", "name", "age"] # - # source://activerecord//lib/active_record/attribute_methods.rb#162 + # source://activerecord//lib/active_record/attribute_methods.rb#235 def attribute_names; end # A method name is 'dangerous' if it is already (re)defined by Active Record, but @@ -6222,7 +6635,7 @@ module ActiveRecord::AttributeMethods::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#109 + # source://activerecord//lib/active_record/attribute_methods.rb#182 def dangerous_attribute_method?(name); end # A class method is 'dangerous' if it is already (re)defined by Active Record, but @@ -6230,15 +6643,24 @@ module ActiveRecord::AttributeMethods::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#127 + # source://activerecord//lib/active_record/attribute_methods.rb#200 def dangerous_class_method?(method_name); end # Generates all the attribute related methods for columns in the database # accessors, mutators and query methods. # - # source://activerecord//lib/active_record/attribute_methods.rb#58 + # source://activerecord//lib/active_record/attribute_methods.rb#104 def define_attribute_methods; end + # source://activerecord//lib/active_record/attribute_methods.rb#76 + def eagerly_generate_alias_attribute_methods(_new_name, _old_name); end + + # source://activerecord//lib/active_record/attribute_methods.rb#80 + def generate_alias_attribute_methods(code_generator, new_name, old_name); end + + # source://activerecord//lib/active_record/attribute_methods.rb#126 + def generate_alias_attributes; end + # Returns true if the given attribute exists, otherwise false. # # class Person < ActiveRecord::Base @@ -6252,13 +6674,10 @@ module ActiveRecord::AttributeMethods::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#180 + # source://activerecord//lib/active_record/attribute_methods.rb#253 def has_attribute?(attr_name); end # source://activerecord//lib/active_record/attribute_methods.rb#42 - def inherited(child_class); end - - # source://activerecord//lib/active_record/attribute_methods.rb#47 def initialize_generated_modules; end # Raises an ActiveRecord::DangerousAttributeError exception when an @@ -6278,19 +6697,106 @@ module ActiveRecord::AttributeMethods::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#91 + # source://activerecord//lib/active_record/attribute_methods.rb#164 def instance_method_already_implemented?(method_name); end # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods.rb#113 + # source://activerecord//lib/active_record/attribute_methods.rb#186 def method_defined_within?(name, klass, superklass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/attribute_methods.rb#70 + # source://activerecord//lib/active_record/attribute_methods.rb#142 def undefine_attribute_methods; end + + private + + # source://activerecord//lib/active_record/attribute_methods.rb#264 + def inherited(child_class); end end -# source://activerecord//lib/active_record/attribute_methods/dirty.rb#7 +# source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#5 +module ActiveRecord::AttributeMethods::CompositePrimaryKey + # Returns the primary key column's value. If the primary key is composite, + # returns an array of the primary key column values. + # + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#8 + def id; end + + # Sets the primary key column's value. If the primary key is composite, + # raises TypeError when the set value not enumerable. + # + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#26 + def id=(value); end + + # Queries the primary key column's value. If the primary key is composite, + # all primary key column values must be queryable. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#37 + def id?; end + + # Returns the primary key column's value before type cast. If the primary key is composite, + # returns an array of primary key column values before type cast. + # + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#47 + def id_before_type_cast; end + + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#75 + def id_for_database; end + + # Returns the primary key column's value from the database. If the primary key is composite, + # returns an array of primary key column values from database. + # + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#67 + def id_in_database; end + + # Returns the primary key column's previous value. If the primary key is composite, + # returns an array of primary key column previous values. + # + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#57 + def id_was; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/attribute_methods/composite_primary_key.rb#16 + def primary_key_values_present?; end +end + +# = Active Record Attribute Methods \Dirty +# +# Provides a way to track changes in your Active Record models. It adds all +# methods from ActiveModel::Dirty and adds database-specific methods. +# +# A newly created +Person+ object is unchanged: +# +# class Person < ActiveRecord::Base +# end +# +# person = Person.create(name: "Allison") +# person.changed? # => false +# +# Change the name: +# +# person.name = 'Alice' +# person.name_in_database # => "Allison" +# person.will_save_change_to_name? # => true +# person.name_change_to_be_saved # => ["Allison", "Alice"] +# person.changes_to_save # => {"name"=>["Allison", "Alice"]} +# +# Save the changes: +# +# person.save +# person.name_in_database # => "Alice" +# person.saved_change_to_name? # => true +# person.saved_change_to_name # => ["Allison", "Alice"] +# person.name_before_last_save # => "Allison" +# +# Similar to ActiveModel::Dirty, methods can be invoked as +# +saved_change_to_name?+ or by passing an argument to the generic method +# saved_change_to_attribute?("name"). +# +# source://activerecord//lib/active_record/attribute_methods/dirty.rb#39 module ActiveRecord::AttributeMethods::Dirty extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -6299,7 +6805,6 @@ module ActiveRecord::AttributeMethods::Dirty mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveModel::AttributeMethods::ClassMethods - mixes_in_class_methods ::ActiveRecord::AttributeMethods::Dirty::ClassMethods # Returns the original value of an attribute before the last save. # @@ -6308,7 +6813,7 @@ module ActiveRecord::AttributeMethods::Dirty # invoked as +name_before_last_save+ instead of # attribute_before_last_save("name"). # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#100 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#108 def attribute_before_last_save(attr_name); end # Returns the change to an attribute that will be persisted during the @@ -6322,7 +6827,7 @@ module ActiveRecord::AttributeMethods::Dirty # If the attribute will change, the result will be an array containing the # original value and the new value about to be saved. # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#142 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#152 def attribute_change_to_be_saved(attr_name); end # Returns the value of an attribute in the database, as opposed to the @@ -6334,7 +6839,7 @@ module ActiveRecord::AttributeMethods::Dirty # saved. It can be invoked as +name_in_database+ instead of # attribute_in_database("name"). # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#154 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#164 def attribute_in_database(attr_name); end # Returns a hash of the attributes that will change when the record is @@ -6344,31 +6849,31 @@ module ActiveRecord::AttributeMethods::Dirty # original attribute values in the database (as opposed to the in-memory # values about to be saved). # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#181 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#191 def attributes_in_database; end # Returns an array of the names of any attributes that will change when # the record is next saved. # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#171 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#181 def changed_attribute_names_to_save; end # Returns a hash containing all the changes that will be persisted during # the next save. # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#165 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#175 def changes_to_save; end # Will the next call to +save+ have any changes to persist? # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#159 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#169 def has_changes_to_save?; end # reload the record and clears changed attributes. # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#57 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#63 def reload(*_arg0); end # Returns the change to an attribute during the last save. If the @@ -6380,7 +6885,7 @@ module ActiveRecord::AttributeMethods::Dirty # invoked as +saved_change_to_name+ instead of # saved_change_to_attribute("name"). # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#90 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#98 def saved_change_to_attribute(attr_name); end # Did this attribute change when we last saved? @@ -6392,27 +6897,29 @@ module ActiveRecord::AttributeMethods::Dirty # # ==== Options # - # +from+ When passed, this method will return false unless the original - # value is equal to the given option + # [+from+] + # When specified, this method will return false unless the original + # value is equal to the given value. # - # +to+ When passed, this method will return false unless the value was - # changed to the given value + # [+to+] + # When specified, this method will return false unless the value will be + # changed to the given value. # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#78 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#86 def saved_change_to_attribute?(attr_name, **options); end # Returns a hash containing all the changes that were just saved. # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#110 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#118 def saved_changes; end # Did the last call to +save+ have any changes to change? # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#105 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#113 def saved_changes?; end # Will this attribute change the next time we save? @@ -6424,41 +6931,46 @@ module ActiveRecord::AttributeMethods::Dirty # # ==== Options # - # +from+ When passed, this method will return false unless the original - # value is equal to the given option + # [+from+] + # When specified, this method will return false unless the original + # value is equal to the given value. # - # +to+ When passed, this method will return false unless the value will be - # changed to the given value + # [+to+] + # When specified, this method will return false unless the value will be + # changed to the given value. # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#128 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#138 def will_save_change_to_attribute?(attr_name, **options); end private - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#221 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#239 def _create_record(attribute_names = T.unsafe(nil)); end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#186 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#204 def _touch_row(attribute_names, time); end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#215 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#233 def _update_record(attribute_names = T.unsafe(nil)); end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#231 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#249 def attribute_names_for_partial_inserts; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#227 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#245 def attribute_names_for_partial_updates; end + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#196 + def init_internals; end + module GeneratedClassMethods def attribute_aliases; end def attribute_aliases=(value); end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers=(value); end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns=(value); end + def attribute_method_patterns?; end def partial_inserts; end def partial_inserts=(value); end def partial_inserts?; end @@ -6470,8 +6982,8 @@ module ActiveRecord::AttributeMethods::Dirty module GeneratedInstanceMethods def attribute_aliases; end def attribute_aliases?; end - def attribute_method_matchers; end - def attribute_method_matchers?; end + def attribute_method_patterns; end + def attribute_method_patterns?; end def partial_inserts; end def partial_inserts?; end def partial_updates; end @@ -6479,115 +6991,105 @@ module ActiveRecord::AttributeMethods::Dirty end end -# source://activerecord//lib/active_record/attribute_methods/dirty.rb#30 -module ActiveRecord::AttributeMethods::Dirty::ClassMethods - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#31 - def partial_writes; end - - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#47 - def partial_writes=(value); end - - # @return [Boolean] - # - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#39 - def partial_writes?; end -end +# source://activerecord//lib/active_record/attribute_methods.rb#25 +class ActiveRecord::AttributeMethods::GeneratedAttributeMethods < ::Module; end # source://activerecord//lib/active_record/attribute_methods.rb#26 -class ActiveRecord::AttributeMethods::GeneratedAttributeMethods < ::Module - include ::Mutex_m - - # source://mutex_m/0.1.2/mutex_m.rb#93 - def lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#83 - def locked?; end - - # source://mutex_m/0.1.2/mutex_m.rb#78 - def synchronize(&block); end - - # source://mutex_m/0.1.2/mutex_m.rb#88 - def try_lock; end +ActiveRecord::AttributeMethods::GeneratedAttributeMethods::LOCK = T.let(T.unsafe(nil), Monitor) - # source://mutex_m/0.1.2/mutex_m.rb#98 - def unlock; end -end - -# source://activerecord//lib/active_record/attribute_methods/primary_key.rb#7 +# = Active Record Attribute Methods Primary Key +# +# source://activerecord//lib/active_record/attribute_methods/primary_key.rb#8 module ActiveRecord::AttributeMethods::PrimaryKey extend ::ActiveSupport::Concern mixes_in_class_methods ::ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods - # Returns the primary key column's value. + # Returns the primary key column's value. If the primary key is composite, + # returns an array of the primary key column values. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#18 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#20 def id; end - # Sets the primary key column's value. + # Sets the primary key column's value. If the primary key is composite, + # raises TypeError when the set value not enumerable. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#23 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#30 def id=(value); end - # Queries the primary key column's value. + # Queries the primary key column's value. If the primary key is composite, + # all primary key column values must be queryable. # # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#28 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#36 def id?; end - # Returns the primary key column's value before type cast. + # Returns the primary key column's value before type cast. If the primary key is composite, + # returns an array of primary key column values before type cast. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#33 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#42 def id_before_type_cast; end - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#47 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#58 def id_for_database; end - # Returns the primary key column's value from the database. + # Returns the primary key column's value from the database. If the primary key is composite, + # returns an array of primary key column values from database. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#43 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#54 def id_in_database; end - # Returns the primary key column's previous value. + # Returns the primary key column's previous value. If the primary key is composite, + # returns an array of primary key column previous values. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#38 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#48 def id_was; end + # @return [Boolean] + # + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#24 + def primary_key_values_present?; end + # Returns this record's primary key value wrapped in an array if one is # available. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#12 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#13 def to_key; end private # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#52 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#63 def attribute_method?(attr_name); end end -# source://activerecord//lib/active_record/attribute_methods/primary_key.rb#56 +# source://activerecord//lib/active_record/attribute_methods/primary_key.rb#67 module ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#63 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#87 + def composite_primary_key?; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#75 def dangerous_attribute_method?(method_name); end - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#89 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#106 def get_primary_key(base_name); end # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#59 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#71 def instance_method_already_implemented?(method_name); end # Defines the primary key field -- can be overridden in subclasses. # Overwriting will negate any effect of the +primary_key_prefix_type+ # setting, though. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#70 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#82 def primary_key; end # Sets the name of the primary key column. @@ -6606,44 +7108,57 @@ module ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods # # Project.primary_key # => "foo_id" # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#119 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#133 def primary_key=(value); end # Returns a quoted version of the primary key name, used to construct # SQL statements. # - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#77 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#94 def quoted_primary_key; end - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#81 + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#98 def reset_primary_key; end private - # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#126 - def suppress_composite_primary_key(pk); end + # source://activerecord//lib/active_record/attribute_methods/primary_key.rb#146 + def inherited(base); end end -# source://activerecord//lib/active_record/attribute_methods/primary_key.rb#57 +# source://activerecord//lib/active_record/attribute_methods/primary_key.rb#68 ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods::ID_ATTRIBUTE_METHODS = T.let(T.unsafe(nil), Set) -# source://activerecord//lib/active_record/attribute_methods/query.rb#5 +# source://activerecord//lib/active_record/attribute_methods/primary_key.rb#69 +ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods::PRIMARY_KEY_NOT_SET = T.let(T.unsafe(nil), BasicObject) + +# = Active Record Attribute Methods \Query +# +# source://activerecord//lib/active_record/attribute_methods/query.rb#6 module ActiveRecord::AttributeMethods::Query extend ::ActiveSupport::Concern - # source://activerecord//lib/active_record/attribute_methods/query.rb#12 + # source://activerecord//lib/active_record/attribute_methods/query.rb#19 + def _query_attribute(attr_name); end + + # source://activerecord//lib/active_record/attribute_methods/query.rb#13 def query_attribute(attr_name); end private - # source://activerecord//lib/active_record/attribute_methods/query.rb#12 + # source://activerecord//lib/active_record/attribute_methods/query.rb#13 def attribute?(attr_name); end + + # source://activerecord//lib/active_record/attribute_methods/query.rb#29 + def query_cast_attribute(attr_name, value); end end -# source://activerecord//lib/active_record/attribute_methods.rb#24 +# source://activerecord//lib/active_record/attribute_methods.rb#23 ActiveRecord::AttributeMethods::RESTRICTED_CLASS_METHODS = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/attribute_methods/read.rb#5 +# = Active Record Attribute Methods \Read +# +# source://activerecord//lib/active_record/attribute_methods/read.rb#6 module ActiveRecord::AttributeMethods::Read extend ::ActiveSupport::Concern @@ -6652,14 +7167,15 @@ module ActiveRecord::AttributeMethods::Read # This method exists to avoid the expensive primary_key check internally, without # breaking compatibility with the read_attribute API # - # source://activerecord//lib/active_record/attribute_methods/read.rb#37 + # source://activerecord//lib/active_record/attribute_methods/read.rb#38 def _read_attribute(attr_name, &block); end - # Returns the value of the attribute identified by attr_name after - # it has been typecast (for example, "2004-12-12" in a date column is cast - # to a date object, like Date.new(2004, 12, 12)). + # Returns the value of the attribute identified by +attr_name+ after it + # has been type cast. For example, a date attribute will cast "2004-12-12" + # to Date.new(2004, 12, 12). (For information about specific type + # casting behavior, see the types under ActiveModel::Type.) # - # source://activerecord//lib/active_record/attribute_methods/read.rb#27 + # source://activerecord//lib/active_record/attribute_methods/read.rb#29 def read_attribute(attr_name, &block); end private @@ -6667,26 +7183,38 @@ module ActiveRecord::AttributeMethods::Read # This method exists to avoid the expensive primary_key check internally, without # breaking compatibility with the read_attribute API # - # source://activerecord//lib/active_record/attribute_methods/read.rb#37 + # source://activerecord//lib/active_record/attribute_methods/read.rb#38 def attribute(attr_name, &block); end end -# source://activerecord//lib/active_record/attribute_methods/read.rb#8 +# source://activerecord//lib/active_record/attribute_methods/read.rb#9 module ActiveRecord::AttributeMethods::Read::ClassMethods private - # source://activerecord//lib/active_record/attribute_methods/read.rb#10 - def define_method_attribute(name, owner:); end + # source://activerecord//lib/active_record/attribute_methods/read.rb#11 + def define_method_attribute(canonical_name, owner:, as: T.unsafe(nil)); end end -# source://activerecord//lib/active_record/attribute_methods/serialization.rb#5 +# = Active Record Attribute Methods \Serialization +# +# source://activerecord//lib/active_record/attribute_methods/serialization.rb#6 module ActiveRecord::AttributeMethods::Serialization extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveRecord::AttributeMethods::Serialization::ClassMethods + + module GeneratedClassMethods + def default_column_serializer; end + def default_column_serializer=(value); end + def default_column_serializer?; end + end + + module GeneratedInstanceMethods; end end -# source://activerecord//lib/active_record/attribute_methods/serialization.rb#18 +# source://activerecord//lib/active_record/attribute_methods/serialization.rb#23 module ActiveRecord::AttributeMethods::Serialization::ClassMethods # If you have an attribute that needs to be saved to the database as a # serialized object, and retrieved by deserializing into the same object, @@ -6708,21 +7236,19 @@ module ActiveRecord::AttributeMethods::Serialization::ClassMethods # ==== Parameters # # * +attr_name+ - The name of the attribute to serialize. - # * +class_name_or_coder+ - Optional. May be one of the following: - # * default - The attribute value will be serialized as YAML. - # The attribute value must respond to +to_yaml+. - # * +Array+ - The attribute value will be serialized as YAML, but an - # empty +Array+ will be serialized as +NULL+. The attribute value - # must be an +Array+. - # * +Hash+ - The attribute value will be serialized as YAML, but an - # empty +Hash+ will be serialized as +NULL+. The attribute value - # must be a +Hash+. - # * +JSON+ - The attribute value will be serialized as JSON. The - # attribute value must respond to +to_json+. - # * custom coder - The attribute value will be serialized + # * +coder+ The serializer implementation to use, e.g. +JSON+. + # * The attribute value will be serialized # using the coder's dump(value) method, and will be # deserialized using the coder's load(string) method. The # +dump+ method may return +nil+ to serialize the value as +NULL+. + # * +type+ - Optional. What the type of the serialized object should be. + # * Attempting to serialize another type will raise an + # ActiveRecord::SerializationTypeMismatch error. + # * If the column is +NULL+ or starting from a new record, the default value + # will set to +type.new+ + # * +yaml+ - Optional. Yaml specific options. The allowed config is: + # * +:permitted_classes+ - +Array+ with the permitted classes. + # * +:unsafe_load+ - Unsafely load YAML blobs, allow YAML to load any class. # # ==== Options # @@ -6730,24 +7256,101 @@ module ActiveRecord::AttributeMethods::Serialization::ClassMethods # this option is not passed, the previous default value (if any) will # be used. Otherwise, the default will be +nil+. # + # ==== Choosing a serializer + # + # While any serialization format can be used, it is recommended to carefully + # evaluate the properties of a serializer before using it, as migrating to + # another format later on can be difficult. + # + # ===== Avoid accepting arbitrary types + # + # When serializing data in a column, it is heavily recommended to make sure + # only expected types will be serialized. For instance some serializer like + # +Marshal+ or +YAML+ are capable of serializing almost any Ruby object. + # + # This can lead to unexpected types being serialized, and it is important + # that type serialization remains backward and forward compatible as long + # as some database records still contain these serialized types. + # + # class Address + # def initialize(line, city, country) + # @line, @city, @country = line, city, country + # end + # end + # + # In the above example, if any of the +Address+ attributes is renamed, + # instances that were persisted before the change will be loaded with the + # old attributes. This problem is even worse when the serialized type comes + # from a dependency which doesn't expect to be serialized this way and may + # change its internal representation without notice. + # + # As such, it is heavily recommended to instead convert these objects into + # primitives of the serialization format, for example: + # + # class Address + # attr_reader :line, :city, :country + # + # def self.load(payload) + # data = YAML.safe_load(payload) + # new(data["line"], data["city"], data["country"]) + # end + # + # def self.dump(address) + # YAML.safe_dump( + # "line" => address.line, + # "city" => address.city, + # "country" => address.country, + # ) + # end + # + # def initialize(line, city, country) + # @line, @city, @country = line, city, country + # end + # end + # + # class User < ActiveRecord::Base + # serialize :address, coder: Address + # end + # + # This pattern allows to be more deliberate about what is serialized, and + # to evolve the format in a backward compatible way. + # + # ===== Ensure serialization stability + # + # Some serialization methods may accept some types they don't support by + # silently casting them to other types. This can cause bugs when the + # data is deserialized. + # + # For instance the +JSON+ serializer provided in the standard library will + # silently cast unsupported types to +String+: + # + # >> JSON.parse(JSON.dump(Struct.new(:foo))) + # => "#" + # # ==== Examples # # ===== Serialize the +preferences+ attribute using YAML # # class User < ActiveRecord::Base - # serialize :preferences + # serialize :preferences, coder: YAML # end # # ===== Serialize the +preferences+ attribute using JSON # # class User < ActiveRecord::Base - # serialize :preferences, JSON + # serialize :preferences, coder: JSON # end # # ===== Serialize the +preferences+ +Hash+ using YAML # # class User < ActiveRecord::Base - # serialize :preferences, Hash + # serialize :preferences, type: Hash, coder: YAML + # end + # + # ===== Serializes +preferences+ to YAML, permitting select classes + # + # class User < ActiveRecord::Base + # serialize :preferences, coder: YAML, yaml: { permitted_classes: [Symbol, Time] } # end # # ===== Serialize the +preferences+ attribute using a custom coder @@ -6769,25 +7372,28 @@ module ActiveRecord::AttributeMethods::Serialization::ClassMethods # end # # class User < ActiveRecord::Base - # serialize :preferences, Rot13JSON + # serialize :preferences, coder: Rot13JSON # end # - # source://activerecord//lib/active_record/attribute_methods/serialization.rb#103 - def serialize(attr_name, class_name_or_coder = T.unsafe(nil), **options); end + # source://activerecord//lib/active_record/attribute_methods/serialization.rb#183 + def serialize(attr_name, coder: T.unsafe(nil), type: T.unsafe(nil), yaml: T.unsafe(nil), **options); end private + # source://activerecord//lib/active_record/attribute_methods/serialization.rb#208 + def build_column_serializer(attr_name, coder, type, yaml = T.unsafe(nil)); end + # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/serialization.rb#126 - def type_incompatible_with_serialize?(type, class_name); end + # source://activerecord//lib/active_record/attribute_methods/serialization.rb#225 + def type_incompatible_with_serialize?(cast_type, coder, type); end end -# source://activerecord//lib/active_record/attribute_methods/serialization.rb#8 +# source://activerecord//lib/active_record/attribute_methods/serialization.rb#9 class ActiveRecord::AttributeMethods::Serialization::ColumnNotSerializableError < ::StandardError # @return [ColumnNotSerializableError] a new instance of ColumnNotSerializableError # - # source://activerecord//lib/active_record/attribute_methods/serialization.rb#9 + # source://activerecord//lib/active_record/attribute_methods/serialization.rb#10 def initialize(name, type); end end @@ -6823,15 +7429,15 @@ end # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#71 module ActiveRecord::AttributeMethods::TimeZoneConversion::ClassMethods - # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#72 - def define_attribute(name, cast_type, **_arg2); end - private # @return [Boolean] # - # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#80 + # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#81 def create_time_zone_conversion_attribute?(name, cast_type); end + + # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#73 + def hook_attribute_type(name, cast_type); end end # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#8 @@ -6859,7 +7465,9 @@ class ActiveRecord::AttributeMethods::TimeZoneConversion::TimeZoneConverter end end -# source://activerecord//lib/active_record/attribute_methods/write.rb#5 +# = Active Record Attribute Methods \Write +# +# source://activerecord//lib/active_record/attribute_methods/write.rb#6 module ActiveRecord::AttributeMethods::Write extend ::ActiveSupport::Concern @@ -6871,9 +7479,8 @@ module ActiveRecord::AttributeMethods::Write # source://activerecord//lib/active_record/attribute_methods/write.rb#41 def _write_attribute(attr_name, value); end - # Updates the attribute identified by attr_name with the - # specified +value+. Empty strings for Integer and Float columns are - # turned into +nil+. + # Updates the attribute identified by +attr_name+ using the specified + # +value+. The attribute value will be type cast upon being read. # # source://activerecord//lib/active_record/attribute_methods/write.rb#31 def write_attribute(attr_name, value); end @@ -6887,12 +7494,12 @@ module ActiveRecord::AttributeMethods::Write def attribute=(attr_name, value); end end -# source://activerecord//lib/active_record/attribute_methods/write.rb#12 +# source://activerecord//lib/active_record/attribute_methods/write.rb#13 module ActiveRecord::AttributeMethods::Write::ClassMethods private - # source://activerecord//lib/active_record/attribute_methods/write.rb#14 - def define_method_attribute=(name, owner:); end + # source://activerecord//lib/active_record/attribute_methods/write.rb#15 + def define_method_attribute=(canonical_name, owner:, as: T.unsafe(nil)); end end # See ActiveRecord::Attributes::ClassMethods for documentation @@ -6900,223 +7507,22 @@ end # source://activerecord//lib/active_record/attributes.rb#7 module ActiveRecord::Attributes extend ::ActiveSupport::Concern - include GeneratedInstanceMethods + include ::ActiveModel::AttributeRegistration - mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActiveModel::AttributeRegistration::ClassMethods mixes_in_class_methods ::ActiveRecord::Attributes::ClassMethods - - module GeneratedClassMethods - def attributes_to_define_after_schema_loads; end - def attributes_to_define_after_schema_loads=(value); end - def attributes_to_define_after_schema_loads?; end - end - - module GeneratedInstanceMethods; end end -# source://activerecord//lib/active_record/attributes.rb#14 +# = Active Record \Attributes +# +# source://activerecord//lib/active_record/attributes.rb#12 module ActiveRecord::Attributes::ClassMethods - # Defines an attribute with a type on this model. It will override the - # type of existing attributes if needed. This allows control over how - # values are converted to and from SQL when assigned to a model. It also - # changes the behavior of values passed to - # {ActiveRecord::Base.where}[rdoc-ref:QueryMethods#where]. This will let you use - # your domain objects across much of Active Record, without having to - # rely on implementation details or monkey patching. - # - # +name+ The name of the methods to define attribute methods for, and the - # column which this will persist to. - # - # +cast_type+ A symbol such as +:string+ or +:integer+, or a type object - # to be used for this attribute. See the examples below for more - # information about providing custom type objects. - # - # ==== Options - # - # The following options are accepted: - # - # +default+ The default value to use when no value is provided. If this option - # is not passed, the previous default value (if any) will be used. - # Otherwise, the default will be +nil+. - # - # +array+ (PostgreSQL only) specifies that the type should be an array (see the - # examples below). - # - # +range+ (PostgreSQL only) specifies that the type should be a range (see the - # examples below). - # - # When using a symbol for +cast_type+, extra options are forwarded to the - # constructor of the type object. - # - # ==== Examples - # - # The type detected by Active Record can be overridden. - # - # # db/schema.rb - # create_table :store_listings, force: true do |t| - # t.decimal :price_in_cents - # end - # - # # app/models/store_listing.rb - # class StoreListing < ActiveRecord::Base - # end - # - # store_listing = StoreListing.new(price_in_cents: '10.1') - # - # # before - # store_listing.price_in_cents # => BigDecimal(10.1) - # - # class StoreListing < ActiveRecord::Base - # attribute :price_in_cents, :integer - # end - # - # # after - # store_listing.price_in_cents # => 10 - # - # A default can also be provided. - # - # # db/schema.rb - # create_table :store_listings, force: true do |t| - # t.string :my_string, default: "original default" - # end - # - # StoreListing.new.my_string # => "original default" - # - # # app/models/store_listing.rb - # class StoreListing < ActiveRecord::Base - # attribute :my_string, :string, default: "new default" - # end - # - # StoreListing.new.my_string # => "new default" - # - # class Product < ActiveRecord::Base - # attribute :my_default_proc, :datetime, default: -> { Time.now } - # end - # - # Product.new.my_default_proc # => 2015-05-30 11:04:48 -0600 - # sleep 1 - # Product.new.my_default_proc # => 2015-05-30 11:04:49 -0600 - # - # \Attributes do not need to be backed by a database column. - # - # # app/models/my_model.rb - # class MyModel < ActiveRecord::Base - # attribute :my_string, :string - # attribute :my_int_array, :integer, array: true - # attribute :my_float_range, :float, range: true - # end - # - # model = MyModel.new( - # my_string: "string", - # my_int_array: ["1", "2", "3"], - # my_float_range: "[1,3.5]", - # ) - # model.attributes - # # => - # { - # my_string: "string", - # my_int_array: [1, 2, 3], - # my_float_range: 1.0..3.5 - # } - # - # Passing options to the type constructor - # - # # app/models/my_model.rb - # class MyModel < ActiveRecord::Base - # attribute :small_int, :integer, limit: 2 - # end - # - # MyModel.create(small_int: 65537) - # # => Error: 65537 is out of range for the limit of two bytes - # - # ==== Creating Custom Types - # - # Users may also define their own custom types, as long as they respond - # to the methods defined on the value type. The method +deserialize+ or - # +cast+ will be called on your type object, with raw input from the - # database or from your controllers. See ActiveModel::Type::Value for the - # expected API. It is recommended that your type objects inherit from an - # existing type, or from ActiveRecord::Type::Value - # - # class MoneyType < ActiveRecord::Type::Integer - # def cast(value) - # if !value.kind_of?(Numeric) && value.include?('$') - # price_in_dollars = value.gsub(/\$/, '').to_f - # super(price_in_dollars * 100) - # else - # super - # end - # end - # end - # - # # config/initializers/types.rb - # ActiveRecord::Type.register(:money, MoneyType) - # - # # app/models/store_listing.rb - # class StoreListing < ActiveRecord::Base - # attribute :price_in_cents, :money - # end - # - # store_listing = StoreListing.new(price_in_cents: '$10.00') - # store_listing.price_in_cents # => 1000 - # - # For more details on creating custom types, see the documentation for - # ActiveModel::Type::Value. For more details on registering your types - # to be referenced by a symbol, see ActiveRecord::Type.register. You can - # also pass a type object directly, in place of a symbol. - # - # ==== \Querying - # - # When {ActiveRecord::Base.where}[rdoc-ref:QueryMethods#where] is called, it will - # use the type defined by the model class to convert the value to SQL, - # calling +serialize+ on your type object. For example: - # - # class Money < Struct.new(:amount, :currency) - # end - # - # class MoneyType < ActiveRecord::Type::Value - # def initialize(currency_converter:) - # @currency_converter = currency_converter - # end - # - # # value will be the result of +deserialize+ or - # # +cast+. Assumed to be an instance of +Money+ in - # # this case. - # def serialize(value) - # value_in_bitcoins = @currency_converter.convert_to_bitcoins(value) - # value_in_bitcoins.amount - # end - # end - # - # # config/initializers/types.rb - # ActiveRecord::Type.register(:money, MoneyType) - # - # # app/models/product.rb - # class Product < ActiveRecord::Base - # currency_converter = ConversionRatesFromTheInternet.new - # attribute :price_in_bitcoins, :money, currency_converter: currency_converter - # end - # - # Product.where(price_in_bitcoins: Money.new(5, "USD")) - # # => SELECT * FROM products WHERE price_in_bitcoins = 0.02230 - # - # Product.where(price_in_bitcoins: Money.new(5, "GBP")) - # # => SELECT * FROM products WHERE price_in_bitcoins = 0.03412 - # - # ==== Dirty Tracking - # - # The type of an attribute is given the opportunity to change how dirty - # tracking is performed. The methods +changed?+ and +changed_in_place?+ - # will be called from ActiveModel::Dirty. See the documentation for those - # methods in ActiveModel::Type::Value for more details. - # - # source://activerecord//lib/active_record/attributes.rb#208 - def attribute(name, cast_type = T.unsafe(nil), default: T.unsafe(nil), **options); end + # source://activerecord//lib/active_record/attributes.rb#240 + def _default_attributes; end # This is the low level API which sits beneath +attribute+. It only # accepts type objects, and will do its work immediately instead of - # waiting for the schema to load. Automatic schema detection and - # ClassMethods#attribute both call this under the hood. While this method + # waiting for the schema to load. While this method # is provided so it can be used by plugin authors, application code # should probably use ClassMethods#attribute. # @@ -7132,19 +7538,30 @@ module ActiveRecord::Attributes::ClassMethods # +user_provided_default+ Whether the default value should be cast using # +cast+ or +deserialize+. # - # source://activerecord//lib/active_record/attributes.rb#253 + # source://activerecord//lib/active_record/attributes.rb#230 def define_attribute(name, cast_type, default: T.unsafe(nil), user_provided_default: T.unsafe(nil)); end - # source://activerecord//lib/active_record/attributes.rb#263 - def load_schema!; end + protected + + # source://activerecord//lib/active_record/attributes.rb#267 + def reload_schema_from_cache(*_arg0); end private - # source://activerecord//lib/active_record/attributes.rb#275 + # source://activerecord//lib/active_record/attributes.rb#276 def define_default_attribute(name, value, type, from_user:); end + + # source://activerecord//lib/active_record/attributes.rb#292 + def reset_default_attributes; end + + # source://activerecord//lib/active_record/attributes.rb#296 + def resolve_type_name(name, **options); end + + # source://activerecord//lib/active_record/attributes.rb#300 + def type_for_column(connection, column); end end -# source://activerecord//lib/active_record/attributes.rb#272 +# source://activerecord//lib/active_record/attributes.rb#273 ActiveRecord::Attributes::ClassMethods::NO_DEFAULT_PROVIDED = T.let(T.unsafe(nil), Object) # = Active Record Autosave Association @@ -7172,7 +7589,7 @@ ActiveRecord::Attributes::ClassMethods::NO_DEFAULT_PROVIDED = T.let(T.unsafe(nil # # Child records are validated unless :validate is +false+. # -# == Callbacks +# == \Callbacks # # Association with autosave option defines several callbacks on your # model (around_save, before_save, after_create, after_update). Please note that @@ -7282,7 +7699,7 @@ ActiveRecord::Attributes::ClassMethods::NO_DEFAULT_PROVIDED = T.let(T.unsafe(nil # exception is if a custom validation context is used, in which case the validations # will always fire on the associated records. # -# source://activerecord//lib/active_record/autosave_association.rb#138 +# source://activerecord//lib/active_record/autosave_association.rb#140 module ActiveRecord::AutosaveAssociation extend ::ActiveSupport::Concern @@ -7293,20 +7710,20 @@ module ActiveRecord::AutosaveAssociation # # @return [Boolean] # - # source://activerecord//lib/active_record/autosave_association.rb#271 + # source://activerecord//lib/active_record/autosave_association.rb#273 def changed_for_autosave?; end # Returns the association for the parent being destroyed. # # Used to avoid updating the counter cache unnecessarily. # - # source://activerecord//lib/active_record/autosave_association.rb#265 + # source://activerecord//lib/active_record/autosave_association.rb#267 def destroyed_by_association; end # Records the association that is being destroyed and destroying this # record in the process. # - # source://activerecord//lib/active_record/autosave_association.rb#258 + # source://activerecord//lib/active_record/autosave_association.rb#260 def destroyed_by_association=(reflection); end # Marks this record to be destroyed as part of the parent's save transaction. @@ -7315,7 +7732,7 @@ module ActiveRecord::AutosaveAssociation # # Only useful if the :autosave option on the parent is enabled for this associated model. # - # source://activerecord//lib/active_record/autosave_association.rb#245 + # source://activerecord//lib/active_record/autosave_association.rb#247 def mark_for_destruction; end # Returns whether or not this record will be destroyed as part of the parent's save transaction. @@ -7324,42 +7741,42 @@ module ActiveRecord::AutosaveAssociation # # @return [Boolean] # - # source://activerecord//lib/active_record/autosave_association.rb#252 + # source://activerecord//lib/active_record/autosave_association.rb#254 def marked_for_destruction?; end # Reloads the attributes of the object as usual and clears marked_for_destruction flag. # - # source://activerecord//lib/active_record/autosave_association.rb#234 + # source://activerecord//lib/active_record/autosave_association.rb#236 def reload(options = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/autosave_association.rb#508 + # source://activerecord//lib/active_record/autosave_association.rb#540 def _ensure_no_duplicate_errors; end # If the record is new or it has changed, returns true. # # @return [Boolean] # - # source://activerecord//lib/active_record/autosave_association.rb#464 + # source://activerecord//lib/active_record/autosave_association.rb#465 def _record_changed?(reflection, record, key); end # Is used as an around_save callback to check while saving a collection # association whether or not the parent was a new record before saving. # - # source://activerecord//lib/active_record/autosave_association.rb#366 + # source://activerecord//lib/active_record/autosave_association.rb#358 def around_save_collection_association; end # Returns the record for an association collection that should be validated # or saved. If +autosave+ is +false+ only new records will be returned, # unless the parent is/was a new record itself. # - # source://activerecord//lib/active_record/autosave_association.rb#279 + # source://activerecord//lib/active_record/autosave_association.rb#286 def associated_records_to_validate_or_save(association, new_record, autosave); end # @return [Boolean] # - # source://activerecord//lib/active_record/autosave_association.rb#470 + # source://activerecord//lib/active_record/autosave_association.rb#472 def association_foreign_key_changed?(reflection, record, key); end # Returns whether or not the association is valid and applies any errors to @@ -7368,13 +7785,19 @@ module ActiveRecord::AutosaveAssociation # # @return [Boolean] # - # source://activerecord//lib/active_record/autosave_association.rb#330 - def association_valid?(reflection, record, index = T.unsafe(nil)); end + # source://activerecord//lib/active_record/autosave_association.rb#337 + def association_valid?(association, record); end + + # source://activerecord//lib/active_record/autosave_association.rb#524 + def compute_primary_key(reflection, record); end + + # source://activerecord//lib/active_record/autosave_association.rb#278 + def init_internals; end # @return [Boolean] # - # source://activerecord//lib/active_record/autosave_association.rb#504 - def custom_validation_context?; end + # source://activerecord//lib/active_record/autosave_association.rb#481 + def inverse_polymorphic_association_changed?(reflection, record); end # Go through nested autosave associations that are loaded in memory (without loading # any new ones), and return true if any are changed for autosave. @@ -7382,17 +7805,14 @@ module ActiveRecord::AutosaveAssociation # # @return [Boolean] # - # source://activerecord//lib/active_record/autosave_association.rb#292 + # source://activerecord//lib/active_record/autosave_association.rb#299 def nested_records_changed_for_autosave?; end - # source://activerecord//lib/active_record/autosave_association.rb#356 - def normalize_reflection_attribute(indexed_attribute, reflection, index, attribute); end - # Saves the associated record if it's new or :autosave is enabled. # # In addition, it will destroy the association if it was marked for destruction. # - # source://activerecord//lib/active_record/autosave_association.rb#479 + # source://activerecord//lib/active_record/autosave_association.rb#492 def save_belongs_to_association(reflection); end # Saves any new associated records, or all loaded autosave associations if @@ -7404,7 +7824,7 @@ module ActiveRecord::AutosaveAssociation # This all happens inside a transaction, _if_ the Transactions module is included into # ActiveRecord::Base after the AutosaveAssociation module, which it does by default. # - # source://activerecord//lib/active_record/autosave_association.rb#383 + # source://activerecord//lib/active_record/autosave_association.rb#375 def save_collection_association(reflection); end # Saves the associated record if it's new or :autosave is enabled @@ -7416,35 +7836,35 @@ module ActiveRecord::AutosaveAssociation # This all happens inside a transaction, _if_ the Transactions module is included into # ActiveRecord::Base after the AutosaveAssociation module, which it does by default. # - # source://activerecord//lib/active_record/autosave_association.rb#437 + # source://activerecord//lib/active_record/autosave_association.rb#429 def save_has_one_association(reflection); end # Validate the associated records if :validate or # :autosave is turned on for the association specified by # +reflection+. # - # source://activerecord//lib/active_record/autosave_association.rb#319 + # source://activerecord//lib/active_record/autosave_association.rb#326 def validate_collection_association(reflection); end # Validate the association if :validate or :autosave is # turned on for the association. # - # source://activerecord//lib/active_record/autosave_association.rb#310 + # source://activerecord//lib/active_record/autosave_association.rb#317 def validate_single_association(reflection); end end -# source://activerecord//lib/active_record/autosave_association.rb#141 +# source://activerecord//lib/active_record/autosave_association.rb#143 module ActiveRecord::AutosaveAssociation::AssociationBuilderExtension class << self - # source://activerecord//lib/active_record/autosave_association.rb#142 + # source://activerecord//lib/active_record/autosave_association.rb#144 def build(model, reflection); end - # source://activerecord//lib/active_record/autosave_association.rb#146 + # source://activerecord//lib/active_record/autosave_association.rb#148 def valid_options; end end end -# source://activerecord//lib/active_record/autosave_association.rb#155 +# source://activerecord//lib/active_record/autosave_association.rb#157 module ActiveRecord::AutosaveAssociation::ClassMethods private @@ -7460,13 +7880,13 @@ module ActiveRecord::AutosaveAssociation::ClassMethods # check if the save or validation methods have already been defined # before actually defining them. # - # source://activerecord//lib/active_record/autosave_association.rb#187 + # source://activerecord//lib/active_record/autosave_association.rb#189 def add_autosave_association_callbacks(reflection); end - # source://activerecord//lib/active_record/autosave_association.rb#217 + # source://activerecord//lib/active_record/autosave_association.rb#219 def define_autosave_validation_callbacks(reflection); end - # source://activerecord//lib/active_record/autosave_association.rb#157 + # source://activerecord//lib/active_record/autosave_association.rb#159 def define_non_cyclic_method(name, &block); end end @@ -7690,7 +8110,7 @@ end # # Connections are usually created through # {ActiveRecord::Base.establish_connection}[rdoc-ref:ConnectionHandling#establish_connection] and retrieved -# by ActiveRecord::Base.connection. All classes inheriting from ActiveRecord::Base will use this +# by ActiveRecord::Base.lease_connection. All classes inheriting from ActiveRecord::Base will use this # connection. But you can also set a class-specific connection. For example, if Course is an # ActiveRecord::Base, but resides in a different database, you can just say Course.establish_connection # and Course and all of its subclasses will use this connection instead. @@ -7739,6 +8159,15 @@ end # # source://activerecord//lib/active_record/base.rb#282 class ActiveRecord::Base + include ::ActionText::Encryption + include ::ActiveModel::Validations + include ::ActiveSupport::Callbacks + include ::ActiveModel::Validations::HelperMethods + include ::ActiveModel::Conversion + include ::ActiveModel::ForbiddenAttributesProtection + include ::ActiveModel::AttributeAssignment + include ::ActiveModel::API + include ::ActiveModel::Access include ::ActiveRecord::Core include ::ActiveRecord::Persistence include ::ActiveRecord::ReadonlyAttributes @@ -7748,19 +8177,15 @@ class ActiveRecord::Base include ::ActiveRecord::Scoping::Default include ::ActiveRecord::Scoping::Named include ::ActiveRecord::Sanitization - include ::ActiveModel::ForbiddenAttributesProtection - include ::ActiveModel::AttributeAssignment include ::ActiveRecord::AttributeAssignment - include ::ActiveModel::Conversion include ::ActiveRecord::Integration - include ::ActiveModel::Validations - include ::ActiveSupport::Callbacks - include ::ActiveModel::Validations::HelperMethods include ::ActiveRecord::Validations include ::ActiveRecord::CounterCache + include ::ActiveModel::AttributeRegistration include ::ActiveRecord::Attributes include ::ActiveRecord::Locking::Optimistic include ::ActiveRecord::Locking::Pessimistic + include ::ActiveRecord::Encryption::EncryptableRecord include ::ActiveModel::AttributeMethods include ::ActiveRecord::AttributeMethods include ::ActiveRecord::Base::GeneratedAttributeMethods @@ -7779,6 +8204,7 @@ class ActiveRecord::Base include ::ActiveRecord::Timestamp include ::ActiveRecord::Associations include ::ActiveModel::SecurePassword + include ::ActiveRecord::SecurePassword include ::ActiveRecord::AutosaveAssociation include ::ActiveRecord::NestedAttributes include ::ActiveRecord::Transactions @@ -7790,16 +8216,27 @@ class ActiveRecord::Base include ::ActiveRecord::Serialization include ::ActiveRecord::Store include ::ActiveRecord::SecureToken + include ::ActiveRecord::TokenFor include ::ActiveRecord::SignedId include ::ActiveRecord::Suppressor - include ::ActiveRecord::Encryption::EncryptableRecord + include ::ActiveRecord::Normalization + include ::ActiveRecord::Marshalling::Methods + include ::ActiveStorage::Attached::Model + include ::ActiveStorage::Reflection::ActiveRecordExtensions + include ::ActionText::Attribute + include ::Turbo::Broadcastable + extend ::ActiveModel::Validations::ClassMethods extend ::ActiveModel::Naming - extend ::ActiveSupport::Benchmarkable + extend ::ActiveModel::Callbacks + extend ::ActiveSupport::Callbacks::ClassMethods extend ::ActiveSupport::DescendantsTracker + extend ::ActiveModel::Translation + extend ::ActiveModel::Validations::HelperMethods + extend ::ActiveModel::Conversion::ClassMethods + extend ::ActiveSupport::Benchmarkable extend ::ActiveRecord::ConnectionHandling extend ::ActiveRecord::QueryCache::ClassMethods extend ::ActiveRecord::Querying - extend ::ActiveModel::Translation extend ::ActiveRecord::Translation extend ::ActiveRecord::DynamicMatchers extend ::ActiveRecord::DelegatedType @@ -7816,29 +8253,26 @@ class ActiveRecord::Base extend ::ActiveRecord::Scoping::Default::ClassMethods extend ::ActiveRecord::Scoping::Named::ClassMethods extend ::ActiveRecord::Sanitization::ClassMethods - extend ::ActiveModel::Conversion::ClassMethods extend ::ActiveRecord::Integration::ClassMethods - extend ::ActiveModel::Validations::ClassMethods - extend ::ActiveModel::Callbacks - extend ::ActiveSupport::Callbacks::ClassMethods - extend ::ActiveModel::Validations::HelperMethods extend ::ActiveRecord::Validations::ClassMethods extend ::ActiveRecord::CounterCache::ClassMethods + extend ::ActiveModel::AttributeRegistration::ClassMethods extend ::ActiveRecord::Attributes::ClassMethods extend ::ActiveRecord::Locking::Optimistic::ClassMethods + extend ::ActiveRecord::Encryption::EncryptableRecord::ClassMethods extend ::ActiveModel::AttributeMethods::ClassMethods extend ::ActiveRecord::AttributeMethods::ClassMethods extend ::ActiveRecord::AttributeMethods::Read::ClassMethods extend ::ActiveRecord::AttributeMethods::Write::ClassMethods extend ::ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods extend ::ActiveRecord::AttributeMethods::TimeZoneConversion::ClassMethods - extend ::ActiveRecord::AttributeMethods::Dirty::ClassMethods extend ::ActiveRecord::AttributeMethods::Serialization::ClassMethods extend ::ActiveRecord::Callbacks::ClassMethods extend ::ActiveModel::Validations::Callbacks::ClassMethods extend ::ActiveRecord::Timestamp::ClassMethods extend ::ActiveRecord::Associations::ClassMethods extend ::ActiveModel::SecurePassword::ClassMethods + extend ::ActiveRecord::SecurePassword::ClassMethods extend ::ActiveRecord::AutosaveAssociation::ClassMethods extend ::ActiveRecord::NestedAttributes::ClassMethods extend ::ActiveRecord::Transactions::ClassMethods @@ -7846,33 +8280,38 @@ class ActiveRecord::Base extend ::ActiveRecord::Reflection::ClassMethods extend ::ActiveRecord::Store::ClassMethods extend ::ActiveRecord::SecureToken::ClassMethods + extend ::ActiveRecord::TokenFor::ClassMethods extend ::ActiveRecord::SignedId::ClassMethods extend ::ActiveRecord::Suppressor::ClassMethods - extend ::ActiveRecord::Encryption::EncryptableRecord::ClassMethods + extend ::ActiveRecord::Normalization::ClassMethods extend ::OrmAdapter::ToAdapter + extend ::ActiveStorage::Attached::Model::ClassMethods + extend ::ActiveStorage::Reflection::ActiveRecordExtensions::ClassMethods + extend ::ActionText::Attribute::ClassMethods + extend ::Turbo::Broadcastable::ClassMethods - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _before_commit_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _commit_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _create_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _destroy_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _find_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _initialize_callbacks; end # source://activerecord//lib/active_record/reflection.rb#11 @@ -7881,64 +8320,64 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/reflection.rb#11 def _reflections?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _rollback_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_before_commit_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_commit_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_create_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_destroy_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_find_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_initialize_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_rollback_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_save_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_touch_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_update_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_validate_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_validation_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _save_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _touch_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _update_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _validate_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _validation_callbacks; end - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 def _validators; end - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 def _validators?; end # source://activerecord//lib/active_record/reflection.rb#12 @@ -7947,17 +8386,23 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/reflection.rb#12 def aggregate_reflections?; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#72 + # source://activestorage/7.2.0/lib/active_storage/reflection.rb#53 + def attachment_reflections; end + + # source://activestorage/7.2.0/lib/active_storage/reflection.rb#53 + def attachment_reflections?; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 def attribute_aliases; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#72 + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 def attribute_aliases?; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#73 - def attribute_method_matchers; end + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#73 - def attribute_method_matchers?; end + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns?; end # source://activerecord//lib/active_record/reflection.rb#13 def automatic_scope_inversing; end @@ -7965,6 +8410,12 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/reflection.rb#13 def automatic_scope_inversing?; end + # source://activerecord//lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations; end + + # source://activerecord//lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations?; end + # source://activerecord//lib/active_record/integration.rb#16 def cache_timestamp_format; end @@ -7983,19 +8434,25 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/integration.rb#32 def collection_cache_versioning?; end - # source://activerecord//lib/active_record/model_schema.rb#171 - def column_for_attribute(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/model_schema.rb#183 + def column_for_attribute(name, &_arg1); end + + # source://activerecord//lib/active_record/counter_cache.rb#10 + def counter_cached_association_names; end - # source://activerecord//lib/active_record/core.rb#74 + # source://activerecord//lib/active_record/counter_cache.rb#10 + def counter_cached_association_names?; end + + # source://activerecord//lib/active_record/core.rb#97 def default_connection_handler; end - # source://activerecord//lib/active_record/core.rb#74 + # source://activerecord//lib/active_record/core.rb#97 def default_connection_handler?; end - # source://activerecord//lib/active_record/core.rb#76 + # source://activerecord//lib/active_record/core.rb#99 def default_role; end - # source://activerecord//lib/active_record/core.rb#76 + # source://activerecord//lib/active_record/core.rb#99 def default_role?; end # source://activerecord//lib/active_record/scoping/default.rb#20 @@ -8004,20 +8461,23 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/scoping/default.rb#19 def default_scopes; end - # source://activerecord//lib/active_record/core.rb#78 + # source://activerecord//lib/active_record/core.rb#101 def default_shard; end - # source://activerecord//lib/active_record/core.rb#78 + # source://activerecord//lib/active_record/core.rb#101 def default_shard?; end - # source://activerecord//lib/active_record/enum.rb#116 + # source://activerecord//lib/active_record/enum.rb#167 def defined_enums; end - # source://activerecord//lib/active_record/enum.rb#116 + # source://activerecord//lib/active_record/enum.rb#167 def defined_enums?; end - # source://activerecord//lib/active_record/core.rb#26 - def destroy_association_async_job; end + # source://activerecord//lib/active_record/core.rb#47 + def destroy_association_async_batch_size; end + + # source://activerecord//lib/active_record/core.rb#37 + def destroy_association_async_job(&_arg0); end # source://activerecord//lib/active_record/encryption/encryptable_record.rb#11 def encrypted_attributes; end @@ -8028,10 +8488,10 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/encryption/encryptable_record.rb#11 def encrypted_attributes?; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json?; end # source://activerecord//lib/active_record/locking/optimistic.rb#56 @@ -8040,14 +8500,14 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/locking/optimistic.rb#56 def lock_optimistically?; end - # source://activerecord//lib/active_record/core.rb#20 + # source://activerecord//lib/active_record/core.rb#22 def logger; end - # source://activerecord//lib/active_record/core.rb#20 + # source://activerecord//lib/active_record/core.rb#22 def logger?; end - # source://activemodel/7.0.5/lib/active_model/naming.rb#244 - def model_name(*_arg0, **_arg1, &_arg2); end + # source://activemodel/7.2.0/lib/active_model/naming.rb#255 + def model_name(&_arg0); end # source://activerecord//lib/active_record/nested_attributes.rb#15 def nested_attributes_options; end @@ -8055,28 +8515,40 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/nested_attributes.rb#15 def nested_attributes_options?; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#18 + # source://activerecord//lib/active_record/normalization.rb#8 + def normalized_attributes; end + + # source://activerecord//lib/active_record/normalization.rb#8 + def normalized_attributes=(_arg0); end + + # source://activerecord//lib/active_record/normalization.rb#8 + def normalized_attributes?; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(_arg0); end + + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#50 def partial_inserts; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#18 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#50 def partial_inserts?; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#17 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#49 def partial_updates; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#17 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#49 def partial_updates?; end - # source://activerecord//lib/active_record/model_schema.rb#156 + # source://activerecord//lib/active_record/model_schema.rb#168 def pluralize_table_names; end - # source://activerecord//lib/active_record/model_schema.rb#156 + # source://activerecord//lib/active_record/model_schema.rb#168 def pluralize_table_names?; end - # source://activerecord//lib/active_record/model_schema.rb#151 + # source://activerecord//lib/active_record/model_schema.rb#163 def primary_key_prefix_type; end - # source://activerecord//lib/active_record/model_schema.rb#151 + # source://activerecord//lib/active_record/model_schema.rb#163 def primary_key_prefix_type?; end # source://activerecord//lib/active_record/timestamp.rb#47 @@ -8100,28 +8572,30 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#67 def skip_time_zone_conversion_for_attributes?; end - # source://activerecord//lib/active_record/inheritance.rb#42 + # source://activerecord//lib/active_record/inheritance.rb#43 def store_full_class_name; end - # source://activerecord//lib/active_record/inheritance.rb#42 + # source://activerecord//lib/active_record/inheritance.rb#43 def store_full_class_name?; end - # source://activerecord//lib/active_record/inheritance.rb#46 + # source://activerecord//lib/active_record/inheritance.rb#47 def store_full_sti_class; end - # source://activerecord//lib/active_record/inheritance.rb#46 + # source://activerecord//lib/active_record/inheritance.rb#47 def store_full_sti_class?; end - # source://activerecord//lib/active_record/model_schema.rb#152 + def suppressed_turbo_broadcasts?(&_arg0); end + + # source://activerecord//lib/active_record/model_schema.rb#164 def table_name_prefix; end - # source://activerecord//lib/active_record/model_schema.rb#152 + # source://activerecord//lib/active_record/model_schema.rb#164 def table_name_prefix?; end - # source://activerecord//lib/active_record/model_schema.rb#153 + # source://activerecord//lib/active_record/model_schema.rb#165 def table_name_suffix; end - # source://activerecord//lib/active_record/model_schema.rb#153 + # source://activerecord//lib/active_record/model_schema.rb#165 def table_name_suffix?; end # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#66 @@ -8136,70 +8610,88 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#68 def time_zone_aware_types?; end - # source://activerecord//lib/active_record/model_schema.rb#171 + # source://activerecord//lib/active_record/model_schema.rb#183 def type_for_attribute(*_arg0, **_arg1, &_arg2); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#48 + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 def validation_context; end private - # source://activemodel/7.0.5/lib/active_model/validations.rb#48 + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 def validation_context=(_arg0); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activerecord//lib/active_record/readonly_attributes.rb#8 + # source://activerecord//lib/active_record/readonly_attributes.rb#11 def _attr_readonly; end - # source://activerecord//lib/active_record/readonly_attributes.rb#8 + # source://activerecord//lib/active_record/readonly_attributes.rb#11 def _attr_readonly=(value); end - # source://activerecord//lib/active_record/readonly_attributes.rb#8 + # source://activerecord//lib/active_record/readonly_attributes.rb#11 def _attr_readonly?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _before_commit_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _before_commit_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _commit_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _commit_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activerecord//lib/active_record/counter_cache.rb#9 + def _counter_cache_columns; end + + # source://activerecord//lib/active_record/counter_cache.rb#9 + def _counter_cache_columns=(value); end + + # source://activerecord//lib/active_record/counter_cache.rb#9 + def _counter_cache_columns?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _create_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _create_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activerecord//lib/active_record/core.rb#24 + def _destroy_association_async_job; end + + # source://activerecord//lib/active_record/core.rb#24 + def _destroy_association_async_job=(value); end + + # source://activerecord//lib/active_record/core.rb#24 + def _destroy_association_async_job?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _destroy_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _destroy_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _find_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _find_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _initialize_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _initialize_callbacks=(value); end # source://activerecord//lib/active_record/reflection.rb#11 @@ -8211,70 +8703,70 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/reflection.rb#11 def _reflections?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _rollback_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _rollback_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _save_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _save_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _touch_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _touch_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _update_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _update_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _validate_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _validate_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _validation_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _validation_callbacks=(value); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 def _validators; end - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 def _validators=(value); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 def _validators?; end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#144 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 def after_create(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#144 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 def after_destroy(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#144 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 def after_find(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#144 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 def after_initialize(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#144 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 def after_save(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#144 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 def after_touch(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#144 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 def after_update(*args, **options, &block); end # source://activerecord//lib/active_record/reflection.rb#12 @@ -8286,53 +8778,62 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/reflection.rb#12 def aggregate_reflections?; end - # source://activerecord//lib/active_record/core.rb#82 + # source://activerecord//lib/active_record/core.rb#108 def application_record_class?; end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#137 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 def around_create(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#137 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 def around_destroy(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#137 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 def around_save(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#137 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 def around_update(*args, **options, &block); end - # source://activerecord//lib/active_record/core.rb#129 + # source://activerecord//lib/active_record/core.rb#128 def asynchronous_queries_session; end - # source://activerecord//lib/active_record/core.rb#133 + # source://activerecord//lib/active_record/core.rb#132 def asynchronous_queries_tracker; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#72 + # source://activestorage/7.2.0/lib/active_storage/reflection.rb#53 + def attachment_reflections; end + + # source://activestorage/7.2.0/lib/active_storage/reflection.rb#53 + def attachment_reflections=(value); end + + # source://activestorage/7.2.0/lib/active_storage/reflection.rb#53 + def attachment_reflections?; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 def attribute_aliases; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#72 + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 def attribute_aliases=(value); end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#72 + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 def attribute_aliases?; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#73 - def attribute_method_matchers; end + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns; end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#73 - def attribute_method_matchers=(value); end + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns=(value); end - # source://activemodel/7.0.5/lib/active_model/attribute_methods.rb#73 - def attribute_method_matchers?; end + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns?; end - # source://activerecord//lib/active_record/attributes.rb#11 - def attributes_to_define_after_schema_loads; end + # source://activerecord//lib/active_record/core.rb#106 + def attributes_for_inspect; end - # source://activerecord//lib/active_record/attributes.rb#11 - def attributes_to_define_after_schema_loads=(value); end + # source://activerecord//lib/active_record/core.rb#106 + def attributes_for_inspect=(value); end - # source://activerecord//lib/active_record/attributes.rb#11 - def attributes_to_define_after_schema_loads?; end + # source://activerecord//lib/active_record/core.rb#106 + def attributes_for_inspect?; end # source://activerecord//lib/active_record/reflection.rb#13 def automatic_scope_inversing; end @@ -8343,25 +8844,34 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/reflection.rb#13 def automatic_scope_inversing?; end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#130 + # source://activerecord//lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations; end + + # source://activerecord//lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations=(value); end + + # source://activerecord//lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations?; end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 def before_create(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#130 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 def before_destroy(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#130 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 def before_save(*args, **options, &block); end - # source://activemodel/7.0.5/lib/active_model/callbacks.rb#130 + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 def before_update(*args, **options, &block); end - # source://activerecord//lib/active_record/core.rb#68 + # source://activerecord//lib/active_record/core.rb#89 def belongs_to_required_by_default; end - # source://activerecord//lib/active_record/core.rb#68 + # source://activerecord//lib/active_record/core.rb#89 def belongs_to_required_by_default=(value); end - # source://activerecord//lib/active_record/core.rb#68 + # source://activerecord//lib/active_record/core.rb#89 def belongs_to_required_by_default?; end # source://activerecord//lib/active_record/integration.rb#16 @@ -8391,64 +8901,76 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/integration.rb#32 def collection_cache_versioning?; end - # source://activerecord//lib/active_record/core.rb#56 + # source://activerecord//lib/active_record/core.rb#77 def configurations; end - # source://activerecord//lib/active_record/core.rb#50 + # source://activerecord//lib/active_record/core.rb#71 def configurations=(config); end - # source://activerecord//lib/active_record/core.rb#201 + # source://activerecord//lib/active_record/core.rb#192 def connected_to_stack; end - # source://activerecord//lib/active_record/core.rb#215 + # source://activerecord//lib/active_record/core.rb#206 def connection_class; end - # source://activerecord//lib/active_record/core.rb#211 + # source://activerecord//lib/active_record/core.rb#202 def connection_class=(b); end - # source://activerecord//lib/active_record/core.rb#219 + # source://activerecord//lib/active_record/core.rb#210 def connection_class?; end - # source://activerecord//lib/active_record/core.rb#223 + # source://activerecord//lib/active_record/core.rb#214 def connection_class_for_self; end - # source://activerecord//lib/active_record/core.rb#94 + # source://activerecord//lib/active_record/core.rb#120 def connection_handler; end - # source://activerecord//lib/active_record/core.rb#98 + # source://activerecord//lib/active_record/core.rb#124 def connection_handler=(handler); end - # source://activerecord//lib/active_record/core.rb#102 - def connection_handlers; end + # source://activerecord//lib/active_record/counter_cache.rb#10 + def counter_cached_association_names; end - # source://activerecord//lib/active_record/core.rb#111 - def connection_handlers=(handlers); end + # source://activerecord//lib/active_record/counter_cache.rb#10 + def counter_cached_association_names=(value); end - # source://activerecord//lib/active_record/core.rb#188 + # source://activerecord//lib/active_record/counter_cache.rb#10 + def counter_cached_association_names?; end + + # source://activerecord//lib/active_record/core.rb#183 def current_preventing_writes; end - # source://activerecord//lib/active_record/core.rb#147 + # source://activerecord//lib/active_record/core.rb#146 def current_role; end - # source://activerecord//lib/active_record/core.rb#169 + # source://activerecord//lib/active_record/core.rb#164 def current_shard; end - # source://activerecord//lib/active_record/core.rb#74 + # source://activerecord//lib/active_record/attribute_methods/serialization.rb#20 + def default_column_serializer; end + + # source://activerecord//lib/active_record/attribute_methods/serialization.rb#20 + def default_column_serializer=(value); end + + # source://activerecord//lib/active_record/attribute_methods/serialization.rb#20 + def default_column_serializer?; end + + # source://activerecord//lib/active_record/core.rb#97 def default_connection_handler; end - # source://activerecord//lib/active_record/core.rb#74 + # source://activerecord//lib/active_record/core.rb#97 def default_connection_handler=(value); end - # source://activerecord//lib/active_record/core.rb#74 + # source://activerecord//lib/active_record/core.rb#97 def default_connection_handler?; end - # source://activerecord//lib/active_record/core.rb#76 + # source://activerecord//lib/active_record/core.rb#99 def default_role; end - # source://activerecord//lib/active_record/core.rb#76 + # source://activerecord//lib/active_record/core.rb#99 def default_role=(value); end - # source://activerecord//lib/active_record/core.rb#76 + # source://activerecord//lib/active_record/core.rb#99 def default_role?; end # source://activerecord//lib/active_record/scoping/default.rb#20 @@ -8463,28 +8985,34 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/scoping/default.rb#19 def default_scopes=(value); end - # source://activerecord//lib/active_record/core.rb#78 + # source://activerecord//lib/active_record/core.rb#101 def default_shard; end - # source://activerecord//lib/active_record/core.rb#78 + # source://activerecord//lib/active_record/core.rb#101 def default_shard=(value); end - # source://activerecord//lib/active_record/core.rb#78 + # source://activerecord//lib/active_record/core.rb#101 def default_shard?; end - # source://activerecord//lib/active_record/enum.rb#116 + # source://activerecord//lib/active_record/enum.rb#167 def defined_enums; end - # source://activerecord//lib/active_record/enum.rb#116 + # source://activerecord//lib/active_record/enum.rb#167 def defined_enums=(value); end - # source://activerecord//lib/active_record/enum.rb#116 + # source://activerecord//lib/active_record/enum.rb#167 def defined_enums?; end - # source://activerecord//lib/active_record/core.rb#26 + # source://activerecord//lib/active_record/core.rb#47 + def destroy_association_async_batch_size; end + + # source://activerecord//lib/active_record/core.rb#47 + def destroy_association_async_batch_size=(value); end + + # source://activerecord//lib/active_record/core.rb#27 def destroy_association_async_job; end - # source://activerecord//lib/active_record/core.rb#26 + # source://activerecord//lib/active_record/core.rb#24 def destroy_association_async_job=(value); end # source://activerecord//lib/active_record/encryption/encryptable_record.rb#11 @@ -8496,73 +9024,79 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/encryption/encryptable_record.rb#11 def encrypted_attributes?; end - # source://activerecord//lib/active_record/core.rb#66 + # source://activerecord//lib/active_record/core.rb#87 def enumerate_columns_in_select_statements; end - # source://activerecord//lib/active_record/core.rb#66 + # source://activerecord//lib/active_record/core.rb#87 def enumerate_columns_in_select_statements=(value); end - # source://activerecord//lib/active_record/core.rb#66 + # source://activerecord//lib/active_record/core.rb#87 def enumerate_columns_in_select_statements?; end - # source://activerecord//lib/active_record/core.rb#72 + # source://activerecord//lib/active_record/token_for.rb#11 + def generated_token_verifier; end + + # source://activerecord//lib/active_record/token_for.rb#11 + def generated_token_verifier=(value); end + + # source://activerecord//lib/active_record/core.rb#93 def has_many_inversing; end - # source://activerecord//lib/active_record/core.rb#72 + # source://activerecord//lib/active_record/core.rb#93 def has_many_inversing=(value); end - # source://activerecord//lib/active_record/core.rb#72 + # source://activerecord//lib/active_record/core.rb#93 def has_many_inversing?; end - # source://activerecord//lib/active_record/model_schema.rb#158 + # source://activerecord//lib/active_record/model_schema.rb#170 def immutable_strings_by_default; end - # source://activerecord//lib/active_record/model_schema.rb#158 + # source://activerecord//lib/active_record/model_schema.rb#170 def immutable_strings_by_default=(value); end - # source://activerecord//lib/active_record/model_schema.rb#158 + # source://activerecord//lib/active_record/model_schema.rb#170 def immutable_strings_by_default?; end - # source://activerecord//lib/active_record/model_schema.rb#157 + # source://activerecord//lib/active_record/model_schema.rb#169 def implicit_order_column; end - # source://activerecord//lib/active_record/model_schema.rb#157 + # source://activerecord//lib/active_record/model_schema.rb#169 def implicit_order_column=(value); end - # source://activerecord//lib/active_record/model_schema.rb#157 + # source://activerecord//lib/active_record/model_schema.rb#169 def implicit_order_column?; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json=(value); end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json?; end - # source://activerecord//lib/active_record/model_schema.rb#160 + # source://activerecord//lib/active_record/model_schema.rb#172 def inheritance_column; end - # source://activerecord//lib/active_record/model_schema.rb#311 + # source://activerecord//lib/active_record/model_schema.rb#326 def inheritance_column=(value); end - # source://activerecord//lib/active_record/model_schema.rb#160 + # source://activerecord//lib/active_record/model_schema.rb#172 def inheritance_column?; end - # source://activerecord//lib/active_record/model_schema.rb#155 + # source://activerecord//lib/active_record/model_schema.rb#167 def internal_metadata_table_name; end - # source://activerecord//lib/active_record/model_schema.rb#155 + # source://activerecord//lib/active_record/model_schema.rb#167 def internal_metadata_table_name=(value); end - # source://activerecord//lib/active_record/model_schema.rb#155 + # source://activerecord//lib/active_record/model_schema.rb#167 def internal_metadata_table_name?; end - # source://activerecord//lib/active_record/store.rb#99 + # source://activerecord//lib/active_record/store.rb#101 def local_stored_attributes; end - # source://activerecord//lib/active_record/store.rb#99 + # source://activerecord//lib/active_record/store.rb#101 def local_stored_attributes=(_arg0); end # source://activerecord//lib/active_record/locking/optimistic.rb#56 @@ -8574,13 +9108,13 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/locking/optimistic.rb#56 def lock_optimistically?; end - # source://activerecord//lib/active_record/core.rb#20 + # source://activerecord//lib/active_record/core.rb#22 def logger; end - # source://activerecord//lib/active_record/core.rb#20 + # source://activerecord//lib/active_record/core.rb#22 def logger=(value); end - # source://activerecord//lib/active_record/core.rb#20 + # source://activerecord//lib/active_record/core.rb#22 def logger?; end # source://activerecord//lib/active_record/nested_attributes.rb#15 @@ -8592,40 +9126,58 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/nested_attributes.rb#15 def nested_attributes_options?; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#18 + # source://activerecord//lib/active_record/normalization.rb#8 + def normalized_attributes; end + + # source://activerecord//lib/active_record/normalization.rb#8 + def normalized_attributes=(value); end + + # source://activerecord//lib/active_record/normalization.rb#8 + def normalized_attributes?; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(value); end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter?; end + + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#50 def partial_inserts; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#18 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#50 def partial_inserts=(value); end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#18 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#50 def partial_inserts?; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#17 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#49 def partial_updates; end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#17 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#49 def partial_updates=(value); end - # source://activerecord//lib/active_record/attribute_methods/dirty.rb#17 + # source://activerecord//lib/active_record/attribute_methods/dirty.rb#49 def partial_updates?; end - # source://activerecord//lib/active_record/model_schema.rb#156 + # source://activerecord//lib/active_record/model_schema.rb#168 def pluralize_table_names; end - # source://activerecord//lib/active_record/model_schema.rb#156 + # source://activerecord//lib/active_record/model_schema.rb#168 def pluralize_table_names=(value); end - # source://activerecord//lib/active_record/model_schema.rb#156 + # source://activerecord//lib/active_record/model_schema.rb#168 def pluralize_table_names?; end - # source://activerecord//lib/active_record/model_schema.rb#151 + # source://activerecord//lib/active_record/model_schema.rb#163 def primary_key_prefix_type; end - # source://activerecord//lib/active_record/model_schema.rb#151 + # source://activerecord//lib/active_record/model_schema.rb#163 def primary_key_prefix_type=(value); end - # source://activerecord//lib/active_record/model_schema.rb#151 + # source://activerecord//lib/active_record/model_schema.rb#163 def primary_key_prefix_type?; end # source://activerecord//lib/active_record/timestamp.rb#47 @@ -8637,22 +9189,31 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/timestamp.rb#47 def record_timestamps?; end - # source://activerecord//lib/active_record/model_schema.rb#154 + # source://activerecord//lib/active_record/core.rb#95 + def run_commit_callbacks_on_first_saved_instances_in_transaction; end + + # source://activerecord//lib/active_record/core.rb#95 + def run_commit_callbacks_on_first_saved_instances_in_transaction=(value); end + + # source://activerecord//lib/active_record/core.rb#95 + def run_commit_callbacks_on_first_saved_instances_in_transaction?; end + + # source://activerecord//lib/active_record/model_schema.rb#166 def schema_migrations_table_name; end - # source://activerecord//lib/active_record/model_schema.rb#154 + # source://activerecord//lib/active_record/model_schema.rb#166 def schema_migrations_table_name=(value); end - # source://activerecord//lib/active_record/model_schema.rb#154 + # source://activerecord//lib/active_record/model_schema.rb#166 def schema_migrations_table_name?; end - # source://activerecord//lib/active_record/core.rb#80 + # source://activerecord//lib/active_record/core.rb#103 def shard_selector; end - # source://activerecord//lib/active_record/core.rb#80 + # source://activerecord//lib/active_record/core.rb#103 def shard_selector=(value); end - # source://activerecord//lib/active_record/core.rb#80 + # source://activerecord//lib/active_record/core.rb#103 def shard_selector?; end # source://activerecord//lib/active_record/signed_id.rb#13 @@ -8673,52 +9234,58 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#67 def skip_time_zone_conversion_for_attributes?; end - # source://activerecord//lib/active_record/inheritance.rb#42 + # source://activerecord//lib/active_record/inheritance.rb#43 def store_full_class_name; end - # source://activerecord//lib/active_record/inheritance.rb#42 + # source://activerecord//lib/active_record/inheritance.rb#43 def store_full_class_name=(value); end - # source://activerecord//lib/active_record/inheritance.rb#42 + # source://activerecord//lib/active_record/inheritance.rb#43 def store_full_class_name?; end - # source://activerecord//lib/active_record/inheritance.rb#46 + # source://activerecord//lib/active_record/inheritance.rb#47 def store_full_sti_class; end - # source://activerecord//lib/active_record/inheritance.rb#46 + # source://activerecord//lib/active_record/inheritance.rb#47 def store_full_sti_class=(value); end - # source://activerecord//lib/active_record/inheritance.rb#46 + # source://activerecord//lib/active_record/inheritance.rb#47 def store_full_sti_class?; end - # source://activerecord//lib/active_record/core.rb#70 + # source://activerecord//lib/active_record/core.rb#91 def strict_loading_by_default; end - # source://activerecord//lib/active_record/core.rb#70 + # source://activerecord//lib/active_record/core.rb#91 def strict_loading_by_default=(value); end - # source://activerecord//lib/active_record/core.rb#70 + # source://activerecord//lib/active_record/core.rb#91 def strict_loading_by_default?; end - # source://activerecord//lib/active_record/core.rb#238 + # source://activerecord//lib/active_record/core.rb#229 def strict_loading_violation!(owner:, reflection:); end - # source://activerecord//lib/active_record/model_schema.rb#152 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#49 + def suppressed_turbo_broadcasts; end + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#108 + def suppressed_turbo_broadcasts=(obj); end + + # source://activerecord//lib/active_record/model_schema.rb#164 def table_name_prefix; end - # source://activerecord//lib/active_record/model_schema.rb#152 + # source://activerecord//lib/active_record/model_schema.rb#164 def table_name_prefix=(value); end - # source://activerecord//lib/active_record/model_schema.rb#152 + # source://activerecord//lib/active_record/model_schema.rb#164 def table_name_prefix?; end - # source://activerecord//lib/active_record/model_schema.rb#153 + # source://activerecord//lib/active_record/model_schema.rb#165 def table_name_suffix; end - # source://activerecord//lib/active_record/model_schema.rb#153 + # source://activerecord//lib/active_record/model_schema.rb#165 def table_name_suffix=(value); end - # source://activerecord//lib/active_record/model_schema.rb#153 + # source://activerecord//lib/active_record/model_schema.rb#165 def table_name_suffix?; end # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#66 @@ -8739,9 +9306,15 @@ class ActiveRecord::Base # source://activerecord//lib/active_record/attribute_methods/time_zone_conversion.rb#68 def time_zone_aware_types?; end + # source://activerecord//lib/active_record/token_for.rb#10 + def token_definitions; end + + # source://activerecord//lib/active_record/token_for.rb#10 + def token_definitions=(value); end + private - # source://activerecord//lib/active_record/model_schema.rb#160 + # source://activerecord//lib/active_record/model_schema.rb#172 def _inheritance_column=(value); end end end @@ -8752,9 +9325,8 @@ module ActiveRecord::Base::GeneratedAssociationMethods; end # source://activerecord//lib/active_record/base.rb#0 module ActiveRecord::Base::GeneratedAttributeMethods; end -# source://orm_adapter/0.5.0/lib/orm_adapter/adapters/active_record.rb#81 -ActiveRecord::Base::OrmAdapter = OrmAdapter::ActiveRecord - +# = Active Record \Batches +# # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#4 module ActiveRecord::Batches # Looping through a collection of records from the database @@ -8788,7 +9360,16 @@ module ActiveRecord::Batches # * :finish - Specifies the primary key value to end at, inclusive of the value. # * :error_on_ignore - Overrides the application config to specify if an error should be raised when # an order is present in the relation. - # * :order - Specifies the primary key order (can be +:asc+ or +:desc+). Defaults to +:asc+. + # * :order - Specifies the primary key order (can be +:asc+ or +:desc+ or an array consisting + # of :asc or :desc). Defaults to +:asc+. + # + # class Order < ActiveRecord::Base + # self.primary_key = [:id_1, :id_2] + # end + # + # Order.find_each(order: [:asc, :desc]) + # + # In the above code, +id_1+ is sorted in ascending order and +id_2+ in descending order. # # Limits are honored, and if present there is no requirement for the batch # size: it can be less than, equal to, or greater than the limit. @@ -8817,7 +9398,7 @@ module ActiveRecord::Batches # NOTE: By its nature, batch processing is subject to race conditions if # other processes are modifying the database. # - # source://activerecord//lib/active_record/relation/batches.rb#68 + # source://activerecord//lib/active_record/relation/batches.rb#79 def find_each(start: T.unsafe(nil), finish: T.unsafe(nil), batch_size: T.unsafe(nil), error_on_ignore: T.unsafe(nil), order: T.unsafe(nil), &block); end # Yields each batch of records that was found by the find options as @@ -8844,7 +9425,16 @@ module ActiveRecord::Batches # * :finish - Specifies the primary key value to end at, inclusive of the value. # * :error_on_ignore - Overrides the application config to specify if an error should be raised when # an order is present in the relation. - # * :order - Specifies the primary key order (can be +:asc+ or +:desc+). Defaults to +:asc+. + # * :order - Specifies the primary key order (can be +:asc+ or +:desc+ or an array consisting + # of :asc or :desc). Defaults to +:asc+. + # + # class Order < ActiveRecord::Base + # self.primary_key = [:id_1, :id_2] + # end + # + # Order.find_in_batches(order: [:asc, :desc]) + # + # In the above code, +id_1+ is sorted in ascending order and +id_2+ in descending order. # # Limits are honored, and if present there is no requirement for the batch # size: it can be less than, equal to, or greater than the limit. @@ -8868,7 +9458,7 @@ module ActiveRecord::Batches # NOTE: By its nature, batch processing is subject to race conditions if # other processes are modifying the database. # - # source://activerecord//lib/active_record/relation/batches.rb#128 + # source://activerecord//lib/active_record/relation/batches.rb#148 def find_in_batches(start: T.unsafe(nil), finish: T.unsafe(nil), batch_size: T.unsafe(nil), error_on_ignore: T.unsafe(nil), order: T.unsafe(nil)); end # Yields ActiveRecord::Relation objects to work with a batch of records. @@ -8899,7 +9489,22 @@ module ActiveRecord::Batches # * :finish - Specifies the primary key value to end at, inclusive of the value. # * :error_on_ignore - Overrides the application config to specify if an error should be raised when # an order is present in the relation. - # * :order - Specifies the primary key order (can be +:asc+ or +:desc+). Defaults to +:asc+. + # * :order - Specifies the primary key order (can be +:asc+ or +:desc+ or an array consisting + # of :asc or :desc). Defaults to +:asc+. + # + # class Order < ActiveRecord::Base + # self.primary_key = [:id_1, :id_2] + # end + # + # Order.in_batches(order: [:asc, :desc]) + # + # In the above code, +id_1+ is sorted in ascending order and +id_2+ in descending order. + # + # * :use_ranges - Specifies whether to use range iteration (id >= x AND id <= y). + # It can make iterating over the whole or almost whole tables several times faster. + # Only whole table iterations use this style of iteration by default. You can disable this behavior by passing +false+. + # If you iterate over the table and the only condition is, e.g., archived_at: nil (and only a tiny fraction + # of the records are archived), it makes sense to opt in to this approach. # # Limits are honored, and if present there is no requirement for the batch # size, it can be less than, equal, or greater than the limit. @@ -8934,25 +9539,37 @@ module ActiveRecord::Batches # NOTE: By its nature, batch processing is subject to race conditions if # other processes are modifying the database. # - # source://activerecord//lib/active_record/relation/batches.rb#204 - def in_batches(of: T.unsafe(nil), start: T.unsafe(nil), finish: T.unsafe(nil), load: T.unsafe(nil), error_on_ignore: T.unsafe(nil), order: T.unsafe(nil)); end + # source://activerecord//lib/active_record/relation/batches.rb#239 + def in_batches(of: T.unsafe(nil), start: T.unsafe(nil), finish: T.unsafe(nil), load: T.unsafe(nil), error_on_ignore: T.unsafe(nil), order: T.unsafe(nil), use_ranges: T.unsafe(nil), &block); end private - # source://activerecord//lib/active_record/relation/batches.rb#286 + # source://activerecord//lib/active_record/relation/batches.rb#325 def act_on_ignored_order(error_on_ignore); end - # source://activerecord//lib/active_record/relation/batches.rb#278 - def apply_finish_limit(relation, finish, order); end + # source://activerecord//lib/active_record/relation/batches.rb#297 + def apply_finish_limit(relation, finish, batch_orders); end + + # source://activerecord//lib/active_record/relation/batches.rb#284 + def apply_limits(relation, start, finish, batch_orders); end - # source://activerecord//lib/active_record/relation/batches.rb#268 - def apply_limits(relation, start, finish, order); end + # source://activerecord//lib/active_record/relation/batches.rb#290 + def apply_start_limit(relation, start, batch_orders); end - # source://activerecord//lib/active_record/relation/batches.rb#274 - def apply_start_limit(relation, start, order); end + # source://activerecord//lib/active_record/relation/batches.rb#304 + def batch_condition(relation, columns, values, operators); end - # source://activerecord//lib/active_record/relation/batches.rb#282 - def batch_order(order); end + # source://activerecord//lib/active_record/relation/batches.rb#339 + def batch_on_loaded_relation(relation:, start:, finish:, order:, batch_limit:); end + + # source://activerecord//lib/active_record/relation/batches.rb#370 + def batch_on_unloaded_relation(relation:, start:, finish:, load:, order:, use_ranges:, remaining:, batch_limit:); end + + # source://activerecord//lib/active_record/relation/batches.rb#319 + def build_batch_orders(order); end + + # source://activerecord//lib/active_record/relation/batches.rb#335 + def get_the_order_of_primary_key(order); end end # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#5 @@ -8962,11 +9579,11 @@ class ActiveRecord::Batches::BatchEnumerator # @return [BatchEnumerator] a new instance of BatchEnumerator # # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#8 - def initialize(relation:, of: T.unsafe(nil), start: T.unsafe(nil), finish: T.unsafe(nil)); end + def initialize(relation:, of: T.unsafe(nil), start: T.unsafe(nil), finish: T.unsafe(nil), order: T.unsafe(nil), use_ranges: T.unsafe(nil)); end # The size of the batches yielded by the BatchEnumerator. # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#25 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#27 def batch_size; end # Deletes records in batches. Returns the total number of rows affected. @@ -8975,16 +9592,16 @@ class ActiveRecord::Batches::BatchEnumerator # # See Relation#delete_all for details of how each batch is deleted. # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#63 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#65 def delete_all; end - # Destroys records in batches. + # Destroys records in batches. Returns the total number of rows affected. # # Person.where("age < 10").in_batches.destroy_all # # See Relation#destroy_all for details of how each batch is destroyed. # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#83 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#96 def destroy_all; end # Yields an ActiveRecord::Relation object for each batch of records. @@ -8993,7 +9610,7 @@ class ActiveRecord::Batches::BatchEnumerator # relation.update_all(awesome: true) # end # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#92 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#107 def each(&block); end # Looping through a collection of records from the database (using the @@ -9018,45 +9635,107 @@ class ActiveRecord::Batches::BatchEnumerator # person.award_trophy(index + 1) # end # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#50 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#52 def each_record(&block); end # The primary key value at which the BatchEnumerator ends, inclusive of the value. # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#19 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#21 def finish; end # The relation from which the BatchEnumerator yields batches. # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#22 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#24 def relation; end # The primary key value from which the BatchEnumerator starts, inclusive of the value. # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#16 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#18 def start; end + # Touches records in batches. Returns the total number of rows affected. + # + # Person.in_batches.touch_all + # + # See Relation#touch_all for details of how each batch is touched. + # + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#85 + def touch_all(*_arg0, **_arg1, &_arg2); end + # Updates records in batches. Returns the total number of rows affected. # # Person.in_batches.update_all("age = age + 1") # # See Relation#update_all for details of how each batch is updated. # - # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#72 + # source://activerecord//lib/active_record/relation/batches/batch_enumerator.rb#74 def update_all(updates); end end -# source://activerecord//lib/active_record/relation/batches.rb#7 +# source://activerecord//lib/active_record/relation/batches.rb#9 +ActiveRecord::Batches::DEFAULT_ORDER = T.let(T.unsafe(nil), Symbol) + +# source://activerecord//lib/active_record/relation/batches.rb#8 ActiveRecord::Batches::ORDER_IGNORE_MESSAGE = T.let(T.unsafe(nil), String) -# source://activerecord//lib/active_record/relation/calculations.rb#6 +# = Active Record \Calculations +# +# source://activerecord//lib/active_record/relation/calculations.rb#7 module ActiveRecord::Calculations + # Same as #average, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#122 + def async_average(column_name); end + + # Same as #count, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#108 + def async_count(column_name = T.unsafe(nil)); end + + # Same as #ids, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#405 + def async_ids; end + + # Same as #maximum, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#152 + def async_maximum(column_name); end + + # Same as #minimum, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#137 + def async_minimum(column_name); end + + # Same as #pick, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#359 + def async_pick(*column_names); end + + # Same as #pluck, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#330 + def async_pluck(*column_names); end + + # Same as #sum, but performs the query asynchronously and returns an + # ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/relation/calculations.rb#182 + def async_sum(identity_or_column = T.unsafe(nil)); end + # Calculates the average value on a given column. Returns +nil+ if there's # no row. See #calculate for examples with options. # # Person.average(:age) # => 35.8 # - # source://activerecord//lib/active_record/relation/calculations.rb#100 + # source://activerecord//lib/active_record/relation/calculations.rb#116 def average(column_name); end # This calculates aggregate values in the given column. Methods for #count, #sum, #average, @@ -9091,7 +9770,7 @@ module ActiveRecord::Calculations # ... # end # - # source://activerecord//lib/active_record/relation/calculations.rb#179 + # source://activerecord//lib/active_record/relation/calculations.rb#217 def calculate(operation, column_name); end # Count the records. @@ -9120,8 +9799,7 @@ module ActiveRecord::Calculations # of each key would be the #count. # # Article.group(:status, :category).count - # # => {["draft", "business"]=>10, ["draft", "technology"]=>4, - # # ["published", "business"]=>0, ["published", "technology"]=>2} + # # => {["draft", "business"]=>10, ["draft", "technology"]=>4, ["published", "technology"]=>2} # # If #count is used with {Relation#select}[rdoc-ref:QueryMethods#select], it will count the selected columns: # @@ -9131,15 +9809,25 @@ module ActiveRecord::Calculations # Note: not all valid {Relation#select}[rdoc-ref:QueryMethods#select] expressions are valid #count expressions. The specifics differ # between databases. In invalid cases, an error from the database is thrown. # - # source://activerecord//lib/active_record/relation/calculations.rb#84 + # When given a block, loads all records in the relation, if the relation + # hasn't been loaded yet. Calls the block with each record in the relation. + # Returns the number of records for which the block returns a truthy value. + # + # Person.count { |person| person.age > 21 } + # # => counts the number of people older that 21 + # + # Note: If there are a lot of records in the relation, loading all records + # could result in performance issues. + # + # source://activerecord//lib/active_record/relation/calculations.rb#94 def count(column_name = T.unsafe(nil)); end - # Pluck all the ID's for the relation using the table's primary key + # Returns the base model's ID's for the relation using the table's primary key # # Person.ids # SELECT people.id FROM people - # Person.joins(:companies).ids # SELECT people.id FROM people INNER JOIN companies ON companies.person_id = people.id + # Person.joins(:company).ids # SELECT people.id FROM people INNER JOIN companies ON companies.id = people.company_id # - # source://activerecord//lib/active_record/relation/calculations.rb#283 + # source://activerecord//lib/active_record/relation/calculations.rb#367 def ids; end # Calculates the maximum value on a given column. The value is returned @@ -9148,7 +9836,7 @@ module ActiveRecord::Calculations # # Person.maximum(:age) # => 93 # - # source://activerecord//lib/active_record/relation/calculations.rb#118 + # source://activerecord//lib/active_record/relation/calculations.rb#146 def maximum(column_name); end # Calculates the minimum value on a given column. The value is returned @@ -9157,7 +9845,7 @@ module ActiveRecord::Calculations # # Person.minimum(:age) # => 7 # - # source://activerecord//lib/active_record/relation/calculations.rb#109 + # source://activerecord//lib/active_record/relation/calculations.rb#131 def minimum(column_name); end # Pick the value(s) from the named column(s) in the current relation. @@ -9175,7 +9863,7 @@ module ActiveRecord::Calculations # # SELECT people.name, people.email_address FROM people WHERE id = 1 LIMIT 1 # # => [ 'David', 'david@loudthinking.com' ] # - # source://activerecord//lib/active_record/relation/calculations.rb#271 + # source://activerecord//lib/active_record/relation/calculations.rb#348 def pick(*column_names); end # Use #pluck as a shortcut to select one or more attributes without @@ -9207,13 +9895,17 @@ module ActiveRecord::Calculations # # SELECT people.id FROM people WHERE people.age = 21 LIMIT 5 # # => [2, 3] # + # Comment.joins(:person).pluck(:id, person: [:id]) + # # SELECT comments.id, people.id FROM comments INNER JOIN people on comments.person_id = people.id + # # => [[1, 2], [2, 2]] + # # Person.pluck(Arel.sql('DATEDIFF(updated_at, created_at)')) # # SELECT DATEDIFF(updated_at, created_at) FROM people # # => ['0', '27761', '173'] # # See also #ids. # - # source://activerecord//lib/active_record/relation/calculations.rb#233 + # source://activerecord//lib/active_record/relation/calculations.rb#287 def pluck(*column_names); end # Calculates the sum of values on a given column. The value is returned @@ -9222,68 +9914,84 @@ module ActiveRecord::Calculations # # Person.sum(:age) # => 4562 # - # source://activerecord//lib/active_record/relation/calculations.rb#127 - def sum(identity_or_column = T.unsafe(nil), &block); end + # When given a block, loads all records in the relation, if the relation + # hasn't been loaded yet. Calls the block with each record in the relation. + # Returns the sum of +initial_value_or_column+ and the block return + # values: + # + # Person.sum { |person| person.age } # => 4562 + # Person.sum(1000) { |person| person.age } # => 5562 + # + # Note: If there are a lot of records in the relation, loading all records + # could result in performance issues. + # + # source://activerecord//lib/active_record/relation/calculations.rb#172 + def sum(initial_value_or_column = T.unsafe(nil), &block); end private - # source://activerecord//lib/active_record/relation/calculations.rb#327 + # source://activerecord//lib/active_record/relation/calculations.rb#449 def aggregate_column(column_name); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/calculations.rb#288 + # source://activerecord//lib/active_record/relation/calculations.rb#410 def all_attributes?(column_names); end - # source://activerecord//lib/active_record/relation/calculations.rb#502 + # source://activerecord//lib/active_record/relation/calculations.rb#659 def build_count_subquery(relation, column_name, distinct); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/calculations.rb#323 + # source://activerecord//lib/active_record/relation/calculations.rb#652 + def build_count_subquery?(operation, column_name, distinct); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/relation/calculations.rb#445 def distinct_select?(column_name); end - # source://activerecord//lib/active_record/relation/calculations.rb#369 + # source://activerecord//lib/active_record/relation/calculations.rb#502 def execute_grouped_calculation(operation, column_name, distinct); end - # source://activerecord//lib/active_record/relation/calculations.rb#339 + # source://activerecord//lib/active_record/relation/calculations.rb#461 def execute_simple_calculation(operation, column_name, distinct); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/calculations.rb#292 + # source://activerecord//lib/active_record/relation/calculations.rb#414 def has_include?(column_name); end - # source://activerecord//lib/active_record/relation/calculations.rb#450 + # source://activerecord//lib/active_record/relation/calculations.rb#589 def lookup_cast_type_from_join_dependencies(name, join_dependencies = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/calculations.rb#335 + # source://activerecord//lib/active_record/relation/calculations.rb#457 def operation_over_aggregate_column(column, operation, distinct); end - # source://activerecord//lib/active_record/relation/calculations.rb#296 + # source://activerecord//lib/active_record/relation/calculations.rb#418 def perform_calculation(operation, column_name); end - # source://activerecord//lib/active_record/relation/calculations.rb#493 + # source://activerecord//lib/active_record/relation/calculations.rb#632 def select_for_count; end - # source://activerecord//lib/active_record/relation/calculations.rb#475 + # source://activerecord//lib/active_record/relation/calculations.rb#614 def type_cast_calculated_value(value, operation, type); end - # source://activerecord//lib/active_record/relation/calculations.rb#458 + # source://activerecord//lib/active_record/relation/calculations.rb#597 def type_cast_pluck_values(result, columns); end - # source://activerecord//lib/active_record/relation/calculations.rb#445 + # source://activerecord//lib/active_record/relation/calculations.rb#584 def type_for(field, &block); end end -# source://activerecord//lib/active_record/relation/calculations.rb#7 +# source://activerecord//lib/active_record/relation/calculations.rb#8 class ActiveRecord::Calculations::ColumnAliasTracker # @return [ColumnAliasTracker] a new instance of ColumnAliasTracker # - # source://activerecord//lib/active_record/relation/calculations.rb#8 + # source://activerecord//lib/active_record/relation/calculations.rb#9 def initialize(connection); end - # source://activerecord//lib/active_record/relation/calculations.rb#13 + # source://activerecord//lib/active_record/relation/calculations.rb#14 def alias_for(field); end private @@ -9296,10 +10004,10 @@ class ActiveRecord::Calculations::ColumnAliasTracker # column_alias_for("count(distinct users.id)") # => "count_distinct_users_id" # column_alias_for("count(*)") # => "count_all" # - # source://activerecord//lib/active_record/relation/calculations.rb#34 + # source://activerecord//lib/active_record/relation/calculations.rb#35 def column_alias_for(field); end - # source://activerecord//lib/active_record/relation/calculations.rb#43 + # source://activerecord//lib/active_record/relation/calculations.rb#44 def truncate(name); end end @@ -9386,7 +10094,7 @@ end # == Types of callbacks # # There are three types of callbacks accepted by the callback macros: method references (symbol), callback objects, -# inline methods (using a proc). Method references and callback objects are the recommended approaches, +# inline methods (using a proc). \Method references and callback objects are the recommended approaches, # inline methods using a proc are sometimes appropriate (such as for creating mix-ins). # # The method reference callbacks work by specifying a protected or private method available in the object, like this: @@ -9475,7 +10183,7 @@ end # # If a before_* callback throws +:abort+, all the later callbacks and # the associated action are cancelled. -# Callbacks are generally run in the order they are defined, with the exception of callbacks defined as +# \Callbacks are generally run in the order they are defined, with the exception of callbacks defined as # methods on the model, which are called last. # # == Ordering callbacks @@ -9536,30 +10244,16 @@ end # end # # In this case the +log_children+ is executed before +do_something_else+. -# The same applies to all non-transactional callbacks. +# This applies to all non-transactional callbacks, and to +before_commit+. # -# As seen below, in case there are multiple transactional callbacks the order -# is reversed. +# For transactional +after_+ callbacks (+after_commit+, +after_rollback+, etc), the order +# can be set via configuration. # -# For example: +# config.active_record.run_after_transaction_callbacks_in_order_defined = false # -# class Topic < ActiveRecord::Base -# has_many :children -# -# after_commit :log_children -# after_commit :do_something_else -# -# private -# def log_children -# # Child processing -# end -# -# def do_something_else -# # Something else -# end -# end -# -# In this case the +do_something_else+ is executed before +log_children+. +# When set to +true+ (the default from \Rails 7.1), callbacks are executed in the order they +# are defined, just like the example above. When set to +false+, the order is reversed, so +# +do_something_else+ is executed before +log_children+. # # == \Transactions # @@ -9591,7 +10285,7 @@ end # # Returns true or false depending on whether the proc is contained in the +before_save+ callback chain on a Topic model. # -# source://activerecord//lib/active_record/callbacks.rb#292 +# source://activerecord//lib/active_record/callbacks.rb#278 module ActiveRecord::Callbacks extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -9604,24 +10298,24 @@ module ActiveRecord::Callbacks mixes_in_class_methods ::ActiveSupport::Callbacks::ClassMethods mixes_in_class_methods ::ActiveSupport::DescendantsTracker - # source://activerecord//lib/active_record/callbacks.rb#433 + # source://activerecord//lib/active_record/callbacks.rb#419 def destroy; end - # source://activerecord//lib/active_record/callbacks.rb#449 + # source://activerecord//lib/active_record/callbacks.rb#435 def increment!(attribute, by = T.unsafe(nil), touch: T.unsafe(nil)); end - # source://activerecord//lib/active_record/callbacks.rb#445 + # source://activerecord//lib/active_record/callbacks.rb#431 def touch(*_arg0, **_arg1); end private - # source://activerecord//lib/active_record/callbacks.rb#458 + # source://activerecord//lib/active_record/callbacks.rb#444 def _create_record; end - # source://activerecord//lib/active_record/callbacks.rb#462 + # source://activerecord//lib/active_record/callbacks.rb#448 def _update_record; end - # source://activerecord//lib/active_record/callbacks.rb#454 + # source://activerecord//lib/active_record/callbacks.rb#440 def create_or_update(**_arg0); end module GeneratedClassMethods @@ -9636,19 +10330,56 @@ module ActiveRecord::Callbacks end end -# source://activerecord//lib/active_record/callbacks.rb#295 +# source://activerecord//lib/active_record/callbacks.rb#281 ActiveRecord::Callbacks::CALLBACKS = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/callbacks.rb#302 +# source://activerecord//lib/active_record/callbacks.rb#288 module ActiveRecord::Callbacks::ClassMethods include ::ActiveModel::Callbacks end -# source://activerecord//lib/active_record.rb#114 +# source://activerecord//lib/active_record.rb#124 module ActiveRecord::Coders; end +# source://activerecord//lib/active_record/coders/column_serializer.rb#5 +class ActiveRecord::Coders::ColumnSerializer + # @return [ColumnSerializer] a new instance of ColumnSerializer + # + # source://activerecord//lib/active_record/coders/column_serializer.rb#9 + def initialize(attr_name, coder, object_class = T.unsafe(nil)); end + + # Public because it's called by Type::Serialized + # + # source://activerecord//lib/active_record/coders/column_serializer.rb#46 + def assert_valid_value(object, action:); end + + # Returns the value of attribute coder. + # + # source://activerecord//lib/active_record/coders/column_serializer.rb#7 + def coder; end + + # source://activerecord//lib/active_record/coders/column_serializer.rb#22 + def dump(object); end + + # source://activerecord//lib/active_record/coders/column_serializer.rb#16 + def init_with(coder); end + + # source://activerecord//lib/active_record/coders/column_serializer.rb#29 + def load(payload); end + + # Returns the value of attribute object_class. + # + # source://activerecord//lib/active_record/coders/column_serializer.rb#6 + def object_class; end + + private + + # source://activerecord//lib/active_record/coders/column_serializer.rb#54 + def check_arity_of_constructor; end +end + # source://activerecord//lib/active_record/coders/json.rb#5 -class ActiveRecord::Coders::JSON +module ActiveRecord::Coders::JSON class << self # source://activerecord//lib/active_record/coders/json.rb#6 def dump(obj); end @@ -9659,54 +10390,63 @@ class ActiveRecord::Coders::JSON end # source://activerecord//lib/active_record/coders/yaml_column.rb#7 -class ActiveRecord::Coders::YAMLColumn +class ActiveRecord::Coders::YAMLColumn < ::ActiveRecord::Coders::ColumnSerializer # @return [YAMLColumn] a new instance of YAMLColumn # - # source://activerecord//lib/active_record/coders/yaml_column.rb#10 - def initialize(attr_name, object_class = T.unsafe(nil)); end + # source://activerecord//lib/active_record/coders/yaml_column.rb#59 + def initialize(attr_name, object_class = T.unsafe(nil), permitted_classes: T.unsafe(nil), unsafe_load: T.unsafe(nil)); end - # source://activerecord//lib/active_record/coders/yaml_column.rb#34 - def assert_valid_value(obj, action:); end + # source://activerecord//lib/active_record/coders/yaml_column.rb#77 + def coder; end - # source://activerecord//lib/active_record/coders/yaml_column.rb#16 - def dump(obj); end + # source://activerecord//lib/active_record/coders/yaml_column.rb#68 + def init_with(coder); end - # source://activerecord//lib/active_record/coders/yaml_column.rb#23 - def load(yaml); end + private - # Returns the value of attribute object_class. - # - # source://activerecord//lib/active_record/coders/yaml_column.rb#8 - def object_class; end + # source://activerecord//lib/active_record/coders/yaml_column.rb#88 + def check_arity_of_constructor; end +end - # Sets the attribute object_class +# source://activerecord//lib/active_record/coders/yaml_column.rb#8 +class ActiveRecord::Coders::YAMLColumn::SafeCoder + # @return [SafeCoder] a new instance of SafeCoder # - # @param value the value to set the attribute object_class to. - # - # source://activerecord//lib/active_record/coders/yaml_column.rb#8 - def object_class=(_arg0); end + # source://activerecord//lib/active_record/coders/yaml_column.rb#9 + def initialize(permitted_classes: T.unsafe(nil), unsafe_load: T.unsafe(nil)); end - private + # source://activerecord//lib/active_record/coders/yaml_column.rb#15 + def dump(object); end - # source://activerecord//lib/active_record/coders/yaml_column.rb#42 - def check_arity_of_constructor; end + # source://activerecord//lib/active_record/coders/yaml_column.rb#33 + def load(payload); end +end - # source://activerecord//lib/active_record/coders/yaml_column.rb#49 - def yaml_load(payload); end +# source://activerecord//lib/active_record/associations/errors.rb#187 +class ActiveRecord::CompositePrimaryKeyMismatchError < ::ActiveRecord::ActiveRecordError + # @return [CompositePrimaryKeyMismatchError] a new instance of CompositePrimaryKeyMismatchError + # + # source://activerecord//lib/active_record/associations/errors.rb#190 + def initialize(reflection = T.unsafe(nil)); end + + # Returns the value of attribute reflection. + # + # source://activerecord//lib/active_record/associations/errors.rb#188 + def reflection; end end -# source://activerecord//lib/active_record/migration.rb#168 +# source://activerecord//lib/active_record/migration.rb#190 class ActiveRecord::ConcurrentMigrationError < ::ActiveRecord::MigrationError # @return [ConcurrentMigrationError] a new instance of ConcurrentMigrationError # - # source://activerecord//lib/active_record/migration.rb#172 + # source://activerecord//lib/active_record/migration.rb#194 def initialize(message = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/migration.rb#169 +# source://activerecord//lib/active_record/migration.rb#191 ActiveRecord::ConcurrentMigrationError::DEFAULT_MESSAGE = T.let(T.unsafe(nil), String) -# source://activerecord//lib/active_record/migration.rb#170 +# source://activerecord//lib/active_record/migration.rb#192 ActiveRecord::ConcurrentMigrationError::RELEASE_LOCK_FAILED_MESSAGE = T.let(T.unsafe(nil), String) # Raised when association is being configured improperly or user tries to use @@ -9715,14 +10455,34 @@ ActiveRecord::ConcurrentMigrationError::RELEASE_LOCK_FAILED_MESSAGE = T.let(T.un # {ActiveRecord::Base.has_and_belongs_to_many}[rdoc-ref:Associations::ClassMethods#has_and_belongs_to_many] # associations. # -# source://activerecord//lib/active_record/errors.rb#299 +# source://activerecord//lib/active_record/errors.rb#377 class ActiveRecord::ConfigurationError < ::ActiveRecord::ActiveRecordError; end -# source://activerecord//lib/active_record/connection_adapters.rb#4 +# source://activerecord//lib/active_record/connection_adapters.rb#6 module ActiveRecord::ConnectionAdapters extend ::ActiveSupport::Autoload + + class << self + # Registers a custom database adapter. + # + # Can also be used to define aliases. + # + # == Example + # + # ActiveRecord::ConnectionAdapters.register("megadb", "MegaDB::ActiveRecordAdapter", "mega_db/active_record_adapter") + # + # ActiveRecord::ConnectionAdapters.register("mysql", "ActiveRecord::ConnectionAdapters::TrilogyAdapter", "active_record/connection_adapters/trilogy_adapter") + # + # source://activerecord//lib/active_record/connection_adapters.rb#22 + def register(name, class_name, path = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters.rb#26 + def resolve(adapter_name); end + end end +# = Active Record Abstract Adapter +# # Active Record supports multiple database systems. AbstractAdapter and # related classes form the abstraction layer which makes this possible. # An AbstractAdapter represents a connection to a database, and provides an @@ -9731,13 +10491,13 @@ end # and +:limit+ options, etc. # # All the concrete database adapters follow the interface laid down in this class. -# {ActiveRecord::Base.connection}[rdoc-ref:ConnectionHandling#connection] returns an AbstractAdapter object, which +# {ActiveRecord::Base.lease_connection}[rdoc-ref:ConnectionHandling#lease_connection] returns an AbstractAdapter object, which # you can use. # # Most of the methods in the adapter are useful during migrations. Most # notably, the instance methods provided by SchemaStatements are very useful. # -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#28 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#31 class ActiveRecord::ConnectionAdapters::AbstractAdapter include ::ActiveSupport::Callbacks include ::ActiveRecord::Migration::JoinTable @@ -9749,28 +10509,29 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter include ::ActiveRecord::ConnectionAdapters::Savepoints extend ::ActiveSupport::Callbacks::ClassMethods extend ::ActiveSupport::DescendantsTracker + extend ::ActiveRecord::ConnectionAdapters::Quoting::ClassMethods # @return [AbstractAdapter] a new instance of AbstractAdapter # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#82 - def initialize(connection, logger = T.unsafe(nil), config = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#126 + def initialize(config_or_deprecated_connection, deprecated_logger = T.unsafe(nil), deprecated_connection_options = T.unsafe(nil), deprecated_config = T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _checkin_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _checkout_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_checkin_callbacks(&block); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_checkout_callbacks(&block); end # Checks whether the connection to the database is still active. This includes @@ -9779,30 +10540,28 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#523 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#651 def active?; end # Returns the human-readable name of the adapter. Use mixed case - one # can always use downcase if needed. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#292 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#356 def adapter_name; end - # @return [Boolean] + # This is meant to be implemented by the adapters that support custom enum types # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#478 - def advisory_locks_enabled?; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#591 + def add_enum_value(*_arg0); end - # Override to check all foreign key constraints in a database. - # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#514 - def all_foreign_keys_valid?; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#598 + def advisory_locks_enabled?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#461 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#565 def async_enabled?; end # Called by ActiveRecord::InsertAll, @@ -9811,64 +10570,97 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter # should be overridden by adapters to implement common features with # non-standard syntax like handling duplicates or returning values. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#642 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#835 def build_insert_sql(insert); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#613 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#806 def case_insensitive_comparison(attribute, value); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#609 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#802 def case_sensitive_comparison(attribute, value); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#118 + # Override to check all foreign key constraints in a database. + # The adapter should raise a +ActiveRecord::StatementInvalid+ if foreign key + # constraints are not met. + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#636 + def check_all_foreign_keys_valid!; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#207 def check_if_write_query(sql); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#657 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#850 def check_version; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#775 + def clean!; end + # Clear any caching the database adapter may be doing. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#574 - def clear_cache!; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#732 + def clear_cache!(new_connection: T.unsafe(nil)); end # Check the connection back in to the connection pool # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#629 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#822 def close; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#223 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#770 + def connect!; end + + # Checks whether the connection to the database was established. This doesn't + # include checking whether the database is actually capable of responding, i.e. + # whether the connection is stale. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#644 + def connected?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#292 def connection_class; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def create(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#217 + def connection_retries; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def create(*_arg0, **_arg1, &_arg2); end # This is meant to be implemented by the adapters that support custom enum types # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#475 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#579 def create_enum(*_arg0); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#653 + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#365 + def database_exists?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#846 def database_version; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#633 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#826 def default_index_type?(index); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#605 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#229 + def default_timezone; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#798 def default_uniqueness_comparison(attribute, value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def delete(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def delete(*_arg0, **_arg1, &_arg2); end # This is meant to be implemented by the adapters that support extensions # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#467 - def disable_extension(name); end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#571 + def disable_extension(name, **_arg1); end # Override to turn off referential integrity while executing &block. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#509 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#629 def disable_referential_integrity; end # Immediately forget this connection ever existed. Unlike disconnect!, @@ -9878,97 +10670,101 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter # undefined. This is called internally just before a forked process gets # rid of a connection that belonged to its parent. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#547 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#707 def discard!; end # Disconnects from the database if already connected. Otherwise, this # method does nothing. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#536 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#693 def disconnect!; end + # This is meant to be implemented by the adapters that support custom enum types + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#583 + def drop_enum(*_arg0); end + # This is meant to be implemented by the adapters that support extensions # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#471 - def enable_extension(name); end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#575 + def enable_extension(name, **_arg1); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def exec_insert_all(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def exec_insert_all(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def exec_query(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def execute(*_arg0, **_arg1, &_arg2); end # this method must only be called while holding connection pool's mutex # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#249 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#313 def expire; end # A list of extensions, to be filled in by adapters that support them. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#497 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#617 def extensions; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#668 - def field_ordered_value(column, values); end - # This is meant to be implemented by the adapters that support advisory # locks # # Return true if we got the lock, otherwise false # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#486 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#606 def get_advisory_lock(lock_id); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#650 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#843 def get_database_version; end # Returns the value of attribute owner. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#42 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#45 def in_use?; end # A list of index algorithms, to be filled by adapters that support them. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#502 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#622 def index_algorithms; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def insert(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def insert(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#175 + def inspect; end # this method must only be called while holding connection pool's mutex # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#208 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#277 def lease; end # Returns the value of attribute lock. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#42 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#45 def lock; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#182 + def lock_thread=(lock_thread); end + # Returns the value of attribute logger. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#42 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#45 def logger; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#153 - def migration_context; end - - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#149 - def migrations_paths; end - # Returns the value of attribute owner. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#42 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#45 def owner; end # Returns the value of attribute pool. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#41 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#44 def pool; end - # Sets the attribute pool - # - # @param value the value to set the attribute pool to. - # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#41 - def pool=(_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#48 + def pool=(value); end # Should primary key values be selected from their corresponding # sequence before the insert statement? If true, next_sequence_value @@ -9976,35 +10772,30 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#405 def prefetch_primary_key?(table_name = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#175 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#244 def prepared_statements; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#175 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#244 def prepared_statements?; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#180 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#249 def prepared_statements_disabled_cache; end # Determines whether writes are currently being prevented. # - # Returns true if the connection is a replica. - # - # If the application is using legacy handling, returns - # true if +connection_handler.prevent_writes+ is set. - # - # If the application is using the new connection handling - # will return true based on +current_preventing_writes+. + # Returns true if the connection is a replica or returns + # the value of +current_preventing_writes+. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#141 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#237 def preventing_writes?; end # Provides access to the underlying database driver for this adapter. For @@ -10018,139 +10809,164 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter # this client. If that is the case, generally you'll want to invalidate # the query cache using +ActiveRecord::Base.clear_query_cache+. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#600 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#790 def raw_connection; end - # Disconnects from the database if already connected, and establishes a - # new connection with the database. Implementors should call super if they - # override the default implementation. + # Disconnects from the database if already connected, and establishes a new + # connection with the database. Implementors should define private #reconnect + # instead. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#529 - def reconnect!; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#657 + def reconnect!(restore_transactions: T.unsafe(nil)); end # This is meant to be implemented by the adapters that support advisory # locks. # # Return true if we released the lock, otherwise false # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#493 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#613 def release_advisory_lock(lock_id); end + # This is meant to be implemented by the adapters that support custom enum types + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#587 + def rename_enum(*_arg0); end + + # This is meant to be implemented by the adapters that support custom enum types + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#595 + def rename_enum_value(*_arg0); end + # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#124 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#213 def replica?; end # Returns true if its required to reload the connection between requests for development mode. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#579 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#745 def requires_reloading?; end # Reset the state of this connection, directing the DBMS to clear # transactions and other connection-related server-side state. Usually a # database-dependent operation. # - # The default implementation does nothing; the implementation should be - # overridden by concrete adapters. + # If a database driver or protocol does not support such a feature, + # implementors may alias this to #reconnect!. Otherwise, implementors + # should call super immediately after resetting the connection (and while + # still holding @lock). # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#563 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#719 def reset!; end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def restart_db_transaction(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#221 + def retry_deadline; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#561 + def return_value_after_insert?(column); end + # The role (e.g. +:writing+) for the current connection. In a # non-multi role application, +:writing+ is returned. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#229 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#298 def role; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def rollback_db_transaction(*_arg0); end - - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def rollback_to_savepoint(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def rollback_db_transaction(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#239 - def schema_cache; end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def rollback_to_savepoint(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#243 - def schema_cache=(cache); end + # Do TransactionRollbackErrors on savepoints affect the parent + # transaction? + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#389 + def savepoint_errors_invalidate_transactions?; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#157 - def schema_migration; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#308 + def schema_cache; end # Returns the version identifier of the schema currently available in # the database. This is generally equal to the number of the highest- # numbered migration that has been executed, or 0 if no schema # information is present / the database is empty. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#664 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#857 def schema_version; end # Seconds since this connection was returned to the pool # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#278 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#342 def seconds_idle; end # The shard (e.g. +:default+) for the current connection. In # a non-sharded application, +:default+ is returned. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#235 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#304 def shard; end # this method must only be called while holding connection pool's mutex (and a desire for segfaults) # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#265 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#329 def steal!; end # Does this adapter support application-enforced advisory locking? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#317 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#398 def supports_advisory_locks?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#307 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#378 def supports_bulk_alter?; end # Does this adapter support creating check constraints? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#384 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#470 def supports_check_constraints?; end # Does this adapter support metadata comments on database objects (tables, columns, indexes)? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#409 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#505 def supports_comments?; end # Can comments for tables, columns, and indexes be specified in create/alter table statements? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#414 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#510 def supports_comments_in_create?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#433 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#529 def supports_common_table_expressions?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#457 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#553 def supports_concurrent_connections?; end # Does this adapter support datetime with precision? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#399 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#495 def supports_datetime_with_precision?; end # Does this adapter support DDL rollbacks in transactions? That is, would @@ -10158,56 +10974,70 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#303 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#374 def supports_ddl_transactions?; end # Does this adapter support creating deferrable constraints? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#379 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#465 def supports_deferrable_constraints?; end + # Does this adapter support creating exclusion constraints? + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#475 + def supports_exclusion_constraints?; end + # Does this adapter support explain? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#348 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#434 def supports_explain?; end # Does this adapter support expression indices? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#343 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#429 def supports_expression_index?; end # Does this adapter support database extensions? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#358 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#444 def supports_extensions?; end # Does this adapter support creating foreign key constraints? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#369 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#455 def supports_foreign_keys?; end # Does this adapter support foreign/external tables? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#424 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#520 def supports_foreign_tables?; end + # Does this adapter support including non-key columns? + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#424 + def supports_index_include?; end + # Does this adapter support index sort order? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#333 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#414 def supports_index_sort_order?; end # Does this adapter support creating indexes in the same statement as @@ -10215,316 +11045,437 @@ class ActiveRecord::ConnectionAdapters::AbstractAdapter # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#364 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#450 def supports_indexes_in_create?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#453 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#549 def supports_insert_conflict_target?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#445 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#541 def supports_insert_on_duplicate_skip?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#449 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#545 def supports_insert_on_duplicate_update?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#441 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#537 def supports_insert_returning?; end - # Does this adapter support json data type? + # Does this adapter support JSON data type? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#404 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#500 def supports_json?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#437 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#533 def supports_lazy_transactions?; end # Does this adapter support materialized views? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#394 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#490 def supports_materialized_views?; end + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#557 + def supports_nulls_not_distinct?; end + # Does this adapter support optimizer hints? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#429 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#525 def supports_optimizer_hints?; end # Does this adapter support partial indices? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#338 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#419 def supports_partial_index?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#328 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#409 def supports_partitioned_indexes?; end + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#393 + def supports_restart_db_transaction?; end + # Does this adapter support savepoints? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#312 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#383 def supports_savepoints?; end # Does this adapter support setting the isolation level for a transaction? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#353 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#439 def supports_transaction_isolation?; end + # Does this adapter support creating unique constraints? + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#480 + def supports_unique_constraints?; end + # Does this adapter support creating invalid constraints? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#374 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#460 def supports_validate_constraints?; end # Does this adapter support views? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#389 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#485 def supports_views?; end # Does this adapter support virtual columns? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#419 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#515 def supports_virtual_columns?; end # Removes the connection from the pool and disconnect it. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#568 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#726 def throw_away!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def truncate(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def truncate(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def truncate_tables(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def truncate_tables(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#283 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#347 def unprepared_statement; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#20 - def update(*_arg0); end - - # @return [Boolean] - # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#128 - def use_metadata_table?; end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#22 + def update(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#203 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#272 def valid_type?(type); end # Checks whether the connection to the database is still active (i.e. not stale). # This is done under the hood by calling #active?. If the connection # is no longer active, then this method will reconnect to the database. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#586 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#752 def verify!; end # Returns the value of attribute visitor. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#42 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#45 def visitor; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#197 def with_instrumenter(instrumenter, &block); end private - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#821 + # Returns a raw connection for internal use with methods that are known + # to both be thread-safe and not rely upon actual server communication. + # This is useful for e.g. string escaping methods. + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1075 + def any_raw_connection; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1182 def arel_visitor; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1064 + def backoff(counter); end + # Builds the result object. # # This is an internal hook to make possible connection adapters to build # custom result objects with connection-specific data. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#832 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1193 def build_result(columns:, rows:, column_types: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#825 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1186 def build_statement_pool; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#623 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#816 def can_perform_case_insensitive_comparison_for?(column); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#807 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1168 def collector; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#796 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1157 def column_for(table_name, column_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#802 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1163 def column_for_attribute(attribute); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#759 + # Perform any necessary initialization upon the newly-established + # connection settings, run queries to configure any application-global + # "session" variables, etc. + # + # Implementations may assume this method will only be called while + # holding @lock (or from #initialize). + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1204 + def configure_connection; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1208 + def default_prepared_statements; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1092 + def extended_type_map_key; end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1050 + def invalidate_transaction(exception); end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1118 def log(sql, name = T.unsafe(nil), binds = T.unsafe(nil), type_casted_binds = T.unsafe(nil), statement_name = T.unsafe(nil), async: T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#775 + # @raise [NotImplementedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1068 + def reconnect; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#938 + def reconnect_can_restore_state?; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1046 + def retryable_connection_error?(exception); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1057 + def retryable_query_error?(exception); end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1136 def transform_query(sql); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#782 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1143 def translate_exception(exception, message:, sql:, binds:); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#749 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1108 def translate_exception_class(e, sql, binds); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#745 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1098 def type_map; end + # Similar to any_raw_connection, but ensures it is validated and + # connected. Any method called on this result still needs to be + # independently thread-safe, so it probably shouldn't talk to the + # server... but some drivers fail if they know the connection has gone + # away. + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1084 + def valid_raw_connection; end + + # Mark the connection as verified. Call this inside a + # `with_raw_connection` block only when the block is guaranteed to + # exercise the raw connection. + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1042 + def verified!; end + # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#792 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1212 + def warning_ignored?(warning); end + + # Lock the monitor, ensure we're properly connected and + # transactions are materialized, and then yield the underlying + # raw connection object. + # + # If +allow_retry+ is true, a connection-related exception will + # cause an automatic reconnect and re-run of the block, up to + # the connection's configured +connection_retries+ setting + # and the configured +retry_deadline+ limit. (Note that when + # +allow_retry+ is true, it's possible to return without having marked + # the connection as verified. If the block is guaranteed to exercise the + # connection, consider calling `verified!` to avoid needless + # verification queries in subsequent calls.) + # + # If +materialize_transactions+ is false, the block will be run without + # ensuring virtual transactions have been materialized in the DB + # server's state. The active transaction will also remain clean + # (if it is not already dirty), meaning it's able to be restored + # by reconnecting and opening an equivalent-depth set of new + # transactions. This should only be used by transaction control + # methods, and internal transaction-agnostic queries. + # + # + # + # It's not the primary use case, so not something to optimize + # for, but note that this method does need to be re-entrant: + # +materialize_transactions+ will re-enter if it has work to do, + # and the yield block can also do so under some circumstances. + # + # In the latter case, we really ought to guarantee the inner + # call will not reconnect (which would interfere with the + # still-yielded connection in the outer block), but we currently + # provide no special enforcement there. + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#975 + def with_raw_connection(allow_retry: T.unsafe(nil), materialize_transactions: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#1153 def without_prepared_statement?(binds); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _checkin_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _checkin_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _checkout_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _checkout_callbacks=(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#68 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#87 def build_read_query_regexp(*parts); end # Does the database for this adapter exist? # - # @raise [NotImplementedError] # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#297 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#361 def database_exists?(config); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#74 - def quoted_column_names; end + # Opens a database console session. + # + # @raise [NotImplementedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#122 + def dbconsole(config, options = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#869 + def extended_type_map(default_timezone:); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#78 - def quoted_table_names; end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#93 + def find_cmd_and_exec(commands, *args); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#57 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#862 + def register_class_with_precision(mapping, key, klass, **kwargs); end + + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#66 def type_cast_config_to_boolean(config); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#47 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#56 def type_cast_config_to_integer(config); end + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#74 + def validate_default_timezone(config); end + private - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#737 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#929 def extract_limit(sql_type); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#733 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#925 def extract_precision(sql_type); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#726 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#918 def extract_scale(sql_type); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#679 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#878 def initialize_type_map(m); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#712 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#911 def register_class_with_limit(mapping, key, klass); end - - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#719 - def register_class_with_precision(mapping, key, klass); end end end -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#29 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#32 ActiveRecord::ConnectionAdapters::AbstractAdapter::ADAPTER_NAME = T.let(T.unsafe(nil), String) -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#39 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#42 ActiveRecord::ConnectionAdapters::AbstractAdapter::COMMENT_REGEX = T.let(T.unsafe(nil), Regexp) -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#65 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#84 ActiveRecord::ConnectionAdapters::AbstractAdapter::DEFAULT_READ_QUERY = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#106 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#195 ActiveRecord::ConnectionAdapters::AbstractAdapter::EXCEPTION_IMMEDIATE = T.let(T.unsafe(nil), Hash) -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#105 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#194 ActiveRecord::ConnectionAdapters::AbstractAdapter::EXCEPTION_NEVER = T.let(T.unsafe(nil), Hash) -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#38 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#935 +ActiveRecord::ConnectionAdapters::AbstractAdapter::EXTENDED_TYPE_MAPS = T.let(T.unsafe(nil), Concurrent::Map) + +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#41 ActiveRecord::ConnectionAdapters::AbstractAdapter::SIMPLE_INT = T.let(T.unsafe(nil), Regexp) -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#742 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#934 ActiveRecord::ConnectionAdapters::AbstractAdapter::TYPE_MAP = T.let(T.unsafe(nil), ActiveRecord::Type::TypeMap) -# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#184 +# source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#253 class ActiveRecord::ConnectionAdapters::AbstractAdapter::Version include ::Comparable # @return [Version] a new instance of Version # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#258 def initialize(version_string, full_version_string = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#194 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#263 def <=>(version_string); end # Returns the value of attribute full_version_string. # - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#187 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#256 def full_version_string; end - # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#198 + # source://activerecord//lib/active_record/connection_adapters/abstract_adapter.rb#267 def to_s; end end # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#12 -module ActiveRecord::ConnectionAdapters::AbstractPool - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#13 - def get_schema_cache(connection); end +module ActiveRecord::ConnectionAdapters::AbstractPool; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#23 - def lazily_set_schema_cache; end - - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#19 - def set_schema_cache(cache); end -end - -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#80 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#114 class ActiveRecord::ConnectionAdapters::AddColumnDefinition < ::Struct # Returns the value of attribute column # @@ -10546,58 +11497,170 @@ class ActiveRecord::ConnectionAdapters::AddColumnDefinition < ::Struct end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#534 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#621 class ActiveRecord::ConnectionAdapters::AlterTable # @return [AlterTable] a new instance of AlterTable # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#539 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#626 def initialize(td); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#558 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#645 def add_check_constraint(expression, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#566 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#653 def add_column(name, type, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#550 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#637 def add_foreign_key(to_table, options); end # Returns the value of attribute adds. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#535 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#622 def adds; end # Returns the value of attribute check_constraint_adds. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#537 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#624 def check_constraint_adds; end # Returns the value of attribute check_constraint_drops. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#537 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#624 def check_constraint_drops; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#562 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#649 def drop_check_constraint(constraint_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#554 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#641 def drop_foreign_key(name); end # Returns the value of attribute foreign_key_adds. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#536 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#623 def foreign_key_adds; end # Returns the value of attribute foreign_key_drops. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#536 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#623 def foreign_key_drops; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#548 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#635 def name; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#82 +# source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#143 +class ActiveRecord::ConnectionAdapters::BoundSchemaReflection + # @return [BoundSchemaReflection] a new instance of BoundSchemaReflection + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#160 + def initialize(abstract_schema_reflection, pool); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#185 + def add(name); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#173 + def cached?(table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#165 + def clear!; end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#217 + def clear_data_source_cache!(name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#193 + def columns(table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#197 + def columns_hash(table_name); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#201 + def columns_hash?(table_name); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#181 + def data_source_exists?(name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#189 + def data_sources(name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#221 + def dump_to(filename); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#205 + def indexes(table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#169 + def load!; end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#177 + def primary_keys(table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#213 + def size; end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#209 + def version; end + + class << self + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#155 + def for_lone_connection(abstract_schema_reflection, connection); end + end +end + +# :nodoc +# +# source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#144 +class ActiveRecord::ConnectionAdapters::BoundSchemaReflection::FakePool + # @return [FakePool] a new instance of FakePool + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#145 + def initialize(connection); end + + # @yield [@connection] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#149 + def with_connection; end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#118 +class ActiveRecord::ConnectionAdapters::ChangeColumnDefaultDefinition < ::Struct + # Returns the value of attribute column + # + # @return [Object] the current value of column + def column; end + + # Sets the attribute column + # + # @param value [Object] the value to set the attribute column to. + # @return [Object] the newly set value + def column=(_); end + + # Returns the value of attribute default + # + # @return [Object] the current value of default + def default; end + + # Sets the attribute default + # + # @param value [Object] the value to set the attribute default to. + # @return [Object] the newly set value + def default=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#116 class ActiveRecord::ConnectionAdapters::ChangeColumnDefinition < ::Struct # Returns the value of attribute column # @@ -10630,11 +11693,16 @@ class ActiveRecord::ConnectionAdapters::ChangeColumnDefinition < ::Struct end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#138 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#174 class ActiveRecord::ConnectionAdapters::CheckConstraintDefinition < ::Struct # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#148 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#188 + def defined_for?(name:, expression: T.unsafe(nil), validate: T.unsafe(nil), **options); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#184 def export_name_on_schema_dump?; end # Returns the value of attribute expression @@ -10648,7 +11716,7 @@ class ActiveRecord::ConnectionAdapters::CheckConstraintDefinition < ::Struct # @return [Object] the newly set value def expression=(_); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#139 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#175 def name; end # Returns the value of attribute options @@ -10675,12 +11743,12 @@ class ActiveRecord::ConnectionAdapters::CheckConstraintDefinition < ::Struct # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#143 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#179 def validate?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#143 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#179 def validated?; end class << self @@ -10711,9 +11779,21 @@ class ActiveRecord::ConnectionAdapters::Column # source://activerecord//lib/active_record/connection_adapters/column.rb#20 def initialize(name, default, sql_type_metadata = T.unsafe(nil), null = T.unsafe(nil), default_function = T.unsafe(nil), collation: T.unsafe(nil), comment: T.unsafe(nil), **_arg7); end - # source://activerecord//lib/active_record/connection_adapters/column.rb#66 + # source://activerecord//lib/active_record/connection_adapters/column.rb#75 def ==(other); end + # whether the column is auto-populated by the database using a sequence + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/column.rb#67 + def auto_incremented_by_db?; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/column.rb#71 + def auto_populated?; end + # @return [Boolean] # # source://activerecord//lib/active_record/connection_adapters/column.rb#34 @@ -10742,7 +11822,7 @@ class ActiveRecord::ConnectionAdapters::Column # source://activerecord//lib/active_record/connection_adapters/column.rb#56 def encode_with(coder); end - # source://activerecord//lib/active_record/connection_adapters/column.rb#66 + # source://activerecord//lib/active_record/connection_adapters/column.rb#75 def eql?(other); end # @return [Boolean] @@ -10750,7 +11830,7 @@ class ActiveRecord::ConnectionAdapters::Column # source://activerecord//lib/active_record/connection_adapters/column.rb#30 def has_default?; end - # source://activerecord//lib/active_record/connection_adapters/column.rb#78 + # source://activerecord//lib/active_record/connection_adapters/column.rb#87 def hash; end # Returns the human name of the column name. @@ -10796,12 +11876,12 @@ class ActiveRecord::ConnectionAdapters::Column # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/column.rb#90 + # source://activerecord//lib/active_record/connection_adapters/column.rb#99 def virtual?; end private - # source://activerecord//lib/active_record/connection_adapters/column.rb#95 + # source://activerecord//lib/active_record/connection_adapters/column.rb#104 def deduplicated; end end @@ -10810,33 +11890,45 @@ end # +columns+ attribute of said TableDefinition object, in order to be used # for generating a number of table creation or table changing SQL statements. # -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#58 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#79 class ActiveRecord::ConnectionAdapters::ColumnDefinition < ::Struct - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#75 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#109 def aliased_types(name, fallback); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#65 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 def collation; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 def collation=(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#65 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 def comment; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 def comment=(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#65 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 def default; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 def default=(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#65 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 + def if_exists; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 + def if_exists=(value); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 + def if_not_exists; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 + def if_not_exists=(value); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 def limit; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 def limit=(value); end # Returns the value of attribute name @@ -10850,10 +11942,10 @@ class ActiveRecord::ConnectionAdapters::ColumnDefinition < ::Struct # @return [Object] the newly set value def name=(_); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#65 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 def null; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 def null=(value); end # Returns the value of attribute options @@ -10867,21 +11959,21 @@ class ActiveRecord::ConnectionAdapters::ColumnDefinition < ::Struct # @return [Object] the newly set value def options=(_); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#65 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 def precision; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 def precision=(value); end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#59 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#93 def primary_key?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#65 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#99 def scale; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#103 def scale=(value); end # Returns the value of attribute sql_type @@ -10915,7 +12007,10 @@ class ActiveRecord::ConnectionAdapters::ColumnDefinition < ::Struct end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#240 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#80 +ActiveRecord::ConnectionAdapters::ColumnDefinition::OPTION_NAMES = T.let(T.unsafe(nil), Array) + +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#300 module ActiveRecord::ConnectionAdapters::ColumnMethods extend ::ActiveSupport::Concern @@ -10924,7 +12019,7 @@ module ActiveRecord::ConnectionAdapters::ColumnMethods # Appends a primary key definition to the table definition. # Can be called multiple times, but this is probably not a good idea. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#245 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#305 def primary_key(name, type = T.unsafe(nil), **options); end end @@ -10932,10 +12027,12 @@ end module ActiveRecord::ConnectionAdapters::ColumnMethods::ClassMethods private - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#269 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#329 def define_column_methods(*column_types); end end +# = Active Record Connection Handler +# # ConnectionHandler is a collection of ConnectionPool objects. It is used # for keeping separate connection pools that connect to different databases. # @@ -10984,11 +12081,11 @@ end # about the model. The model needs to pass a connection specification name to the handler, # in order to look up the correct connection pool. # -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#55 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#57 class ActiveRecord::ConnectionAdapters::ConnectionHandler # @return [ConnectionHandler] a new instance of ConnectionHandler # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#75 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#74 def initialize; end # Returns true if there are any active connections among the connection @@ -10996,27 +12093,24 @@ class ActiveRecord::ConnectionAdapters::ConnectionHandler # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#161 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#155 def active_connections?(role = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#117 - def all_connection_pools; end - # Returns any connections in use by the current thread back to the pool, # and also returns connections to the pool cached by threads that are no # longer alive. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#168 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#162 def clear_active_connections!(role = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#179 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#176 def clear_all_connections!(role = T.unsafe(nil)); end # Clears the cache which maps classes. # # See ConnectionPool#clear_reloadable_connections! for details. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#175 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#172 def clear_reloadable_connections!(role = T.unsafe(nil)); end # Returns true if a connection that's accessible to this class has @@ -11024,78 +12118,81 @@ class ActiveRecord::ConnectionAdapters::ConnectionHandler # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#216 - def connected?(spec_name, role: T.unsafe(nil), shard: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#198 + def connected?(connection_name, role: T.unsafe(nil), shard: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#121 + # Returns the pools for a connection handler and given role. If +:all+ is passed, + # all pools belonging to the connection handler will be returned. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#93 def connection_pool_list(role = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#113 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#87 def connection_pool_names; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#121 + # Returns the pools for a connection handler and given role. If +:all+ is passed, + # all pools belonging to the connection handler will be returned. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#93 def connection_pools(role = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#126 - def establish_connection(config, owner_name: T.unsafe(nil), role: T.unsafe(nil), shard: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#102 + def each_connection_pool(role = T.unsafe(nil), &block); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#113 + def establish_connection(config, owner_name: T.unsafe(nil), role: T.unsafe(nil), shard: T.unsafe(nil), clobber: T.unsafe(nil)); end # Disconnects all currently idle connections. # # See ConnectionPool#flush! for details. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#186 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#183 def flush_idle_connections!(role = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#83 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#79 def prevent_writes; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#87 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#83 def prevent_writes=(prevent_writes); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#221 - def remove_connection_pool(owner, role: T.unsafe(nil), shard: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#203 + def remove_connection_pool(connection_name, role: T.unsafe(nil), shard: T.unsafe(nil)); end # Locate the connection of the nearest super class. This can be an # active or defined connection: if it is the latter, it will be # opened and set as the active connection for the class it was defined # for (not necessarily the current class). # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#194 - def retrieve_connection(spec_name, role: T.unsafe(nil), shard: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#191 + def retrieve_connection(connection_name, role: T.unsafe(nil), shard: T.unsafe(nil)); end - # Retrieving the connection pool happens a lot, so we cache it in @owner_to_pool_manager. + # Retrieving the connection pool happens a lot, so we cache it in @connection_name_to_pool_manager. # This makes retrieving the connection pool O(1) once the process is warm. # When a connection is established or removed, we invalidate the cache. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#235 - def retrieve_connection_pool(owner, role: T.unsafe(nil), shard: T.unsafe(nil)); end - - # Prevent writing to the database regardless of role. - # - # In some cases you may want to prevent writes to the database - # even if you are on a database that can write. +while_preventing_writes+ - # will prevent writes to the database for the duration of the block. - # - # This method does not provide the same protection as a readonly - # user and is meant to be a safeguard against accidental writes. - # - # See +READ_QUERY+ for the queries that are blocked by this - # method. - # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#102 - def while_preventing_writes(enabled = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#212 + def retrieve_connection_pool(connection_name, role: T.unsafe(nil), shard: T.unsafe(nil), strict: T.unsafe(nil)); end private - # Returns the pool manager for an owner. + # Returns the value of attribute connection_name_to_pool_manager. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#244 - def get_pool_manager(owner); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#231 + def connection_name_to_pool_manager; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#273 + def determine_owner_name(owner_name, config); end - # Returns the value of attribute owner_to_pool_manager. + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#247 + def disconnect_pool_from_pool_manager(pool_manager, role, shard); end + + # Returns the pool manager for a connection name / identifier. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#241 - def owner_to_pool_manager; end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#234 + def get_pool_manager(connection_name); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#243 + def pool_managers; end # Returns an instance of PoolConfig for a given adapter. # Accepts a hash one layer deep that contains all connection information. @@ -11109,34 +12206,38 @@ class ActiveRecord::ConnectionAdapters::ConnectionHandler # # @raise [AdapterNotSpecified] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#258 - def resolve_pool_config(config, owner_name, role, shard); end -end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#266 + def resolve_pool_config(config, connection_name, role, shard); end -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#56 -ActiveRecord::ConnectionAdapters::ConnectionHandler::FINALIZER = T.let(T.unsafe(nil), Proc) + # Get the existing pool manager or initialize and assign a new one. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#239 + def set_pool_manager(connection_name); end +end -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#59 -class ActiveRecord::ConnectionAdapters::ConnectionHandler::StringConnectionOwner - # @return [StringConnectionOwner] a new instance of StringConnectionOwner +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#58 +class ActiveRecord::ConnectionAdapters::ConnectionHandler::StringConnectionName + # @return [StringConnectionName] a new instance of StringConnectionName # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#62 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#61 def initialize(name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#70 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#69 def current_preventing_writes; end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#60 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#59 def name; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#66 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_handler.rb#65 def primary_class?; end end +# = Active Record Connection Pool +# # Connection pool base class for managing Active Record database # connections. # @@ -11151,19 +12252,17 @@ end # handle cases in which there are more threads than connections: if all # connections have been checked out, and a thread tries to checkout a # connection anyway, then ConnectionPool will wait until some other thread -# has checked in a connection. +# has checked in a connection, or the +checkout_timeout+ has expired. # # == Obtaining (checking out) a connection # # Connections can be obtained and used from a connection pool in several # ways: # -# 1. Simply use {ActiveRecord::Base.connection}[rdoc-ref:ConnectionHandling.connection] -# as with Active Record 2.1 and -# earlier (pre-connection-pooling). Eventually, when you're done with -# the connection(s) and wish it to be returned to the pool, you call -# {ActiveRecord::Base.clear_active_connections!}[rdoc-ref:ConnectionAdapters::ConnectionHandler#clear_active_connections!]. -# This will be the default behavior for Active Record when used in conjunction with +# 1. Simply use {ActiveRecord::Base.lease_connection}[rdoc-ref:ConnectionHandling#lease_connection]. +# When you're done with the connection(s) and wish it to be returned to the pool, you call +# {ActiveRecord::Base.connection_handler.clear_active_connections!}[rdoc-ref:ConnectionAdapters::ConnectionHandler#clear_active_connections!]. +# This is the default behavior for Active Record when used in conjunction with # Action Pack's request handling cycle. # 2. Manually check out a connection from the pool with # {ActiveRecord::Base.connection_pool.checkout}[rdoc-ref:#checkout]. You are responsible for @@ -11176,6 +12275,12 @@ end # Connections in the pool are actually AbstractAdapter objects (or objects # compatible with AbstractAdapter's interface). # +# While a thread has a connection checked out from the pool using one of the +# above three methods, that connection will automatically be the one used +# by ActiveRecord queries executing on that thread. It is not required to +# explicitly pass the checked out connection to \Rails models or queries, for +# example. +# # == Options # # There are several connection-pooling-related options that you can add to @@ -11200,8 +12305,8 @@ end # # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#8 class ActiveRecord::ConnectionAdapters::ConnectionPool - include ::MonitorMixin include ::ActiveRecord::ConnectionAdapters::QueryCache::ConnectionPoolConfiguration + include ::MonitorMixin include ::ActiveRecord::ConnectionAdapters::AbstractPool # Creates a new ConnectionPool object. +pool_config+ is a PoolConfig @@ -11213,35 +12318,46 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # # @return [ConnectionPool] a new instance of ConnectionPool # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#120 - def initialize(pool_config); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#82 + def initialize(*_arg0, **_arg1, &_arg2); end + + # Returns true if there is an open connection being used for the current thread. + # + # This method only works for connections that have been obtained through + # #lease_connection or #with_connection methods. Connections obtained through + # #checkout will not be detected by #active_connection? + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#371 + def active_connection; end # Returns true if there is an open connection being used for the current thread. # # This method only works for connections that have been obtained through - # #connection or #with_connection methods. Connections obtained through + # #lease_connection or #with_connection methods. Connections obtained through # #checkout will not be detected by #active_connection? # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#371 def active_connection?; end # Returns the value of attribute async_executor. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 def async_executor; end # Returns the value of attribute automatic_reconnect. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#107 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#209 def automatic_reconnect; end # Sets the attribute automatic_reconnect # # @param value the value to set the attribute automatic_reconnect to. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#107 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#209 def automatic_reconnect=(_arg0); end # Check-in a database connection back into the pool, indicating that you @@ -11250,7 +12366,7 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # +conn+: an AbstractAdapter object, which was obtained by earlier by # calling #checkout on this pool. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#349 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#565 def checkin(conn); end # Check-out a database connection from the pool, indicating that you want @@ -11268,19 +12384,22 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # Raises: # - ActiveRecord::ConnectionTimeoutError no connection can be obtained from the pool. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#340 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#542 def checkout(checkout_timeout = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#96 + def checkout_and_verify(connection); end + # Returns the value of attribute checkout_timeout. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#107 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#209 def checkout_timeout; end # Sets the attribute checkout_timeout # # @param value the value to set the attribute checkout_timeout to. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#107 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#209 def checkout_timeout=(_arg0); end # Clears the cache which maps classes and re-connects connections that @@ -11291,7 +12410,7 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # connections in the pool within a timeout interval (default duration is # spec.db_config.checkout_timeout * 2 seconds). # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#298 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#500 def clear_reloadable_connections(raise_on_acquisition_timeout = T.unsafe(nil)); end # Clears the cache which maps classes and re-connects connections that @@ -11303,35 +12422,22 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # clears the cache and reloads connections without any regard for other # connection owning threads. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#322 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#524 def clear_reloadable_connections!; end # Returns true if a connection has already been opened. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#221 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#422 def connected?; end - # Retrieve the connection associated with the current thread, or call - # #checkout to obtain one if necessary. - # - # #connection can be called any number of times; the connection is - # held in a cache keyed by a thread. - # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#180 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#313 def connection; end - # Returns the value of attribute connection_class. - # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#362 def connection_class; end - # Returns the value of attribute connection_class. - # - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def connection_klass(*args, **_arg1, &block); end - # Returns an array containing the connections currently in the pool. # Access to the array does not require synchronization on the pool because # the array is newly created and not retained by the pool. @@ -11344,12 +12450,12 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # thread-safety guarantees of the underlying method. Many of the methods # on connection adapter classes are inherently multi-thread unsafe. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#236 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#437 def connections; end # Returns the value of attribute db_config. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 def db_config; end # Discards all connections in the pool (even if they're currently @@ -11358,12 +12464,12 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # # See AbstractAdapter#discard! # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#277 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#479 def discard!; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#287 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#489 def discarded?; end # Disconnects all connections in the pool, and clears the pool. @@ -11373,7 +12479,7 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # connections in the pool within a timeout interval (default duration is # spec.db_config.checkout_timeout * 2 seconds). # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#246 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#447 def disconnect(raise_on_acquisition_timeout = T.unsafe(nil)); end # Disconnects all connections in the pool, and clears the pool. @@ -11383,43 +12489,69 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # spec.db_config.checkout_timeout * 2 seconds), then the pool is forcefully # disconnected without any regard for other connection owning threads. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#268 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#470 def disconnect!; end # Disconnect all connections that have been idle for at least # +minimum_idle+ seconds. Connections currently checked out, or that were # checked in less than +minimum_idle+ seconds ago, are unaffected. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#420 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#640 def flush(minimum_idle = T.unsafe(nil)); end # Disconnect all currently idle connections. Connections currently checked # out are unaffected. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#442 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#662 def flush!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#167 - def lock_thread=(lock_thread); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#266 + def inspect; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#447 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#294 + def internal_metadata; end + + # Retrieve the connection associated with the current thread, or call + # #checkout to obtain one if necessary. + # + # #lease_connection can be called any number of times; the connection is + # held in a cache keyed by a thread. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#303 + def lease_connection; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#282 + def migration_context; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#286 + def migrations_paths; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#667 def num_waiting_in_queue; end + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#309 + def permanent_lease?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#321 + def pin_connection!(lock_thread); end + # Returns the value of attribute pool_config. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 def pool_config; end # Recover lost connections for the pool. A lost connection can occur if # a programmer forgets to checkin a connection at the end of a thread # or a thread dies unexpectedly. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#397 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#615 def reap; end # Returns the value of attribute reaper. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 def reaper; end # Signal that the thread is finished with the current connection. @@ -11427,57 +12559,73 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # and returns the connection to the pool. # # This method only works for connections that have been obtained through - # #connection or #with_connection methods, connections obtained through + # #lease_connection or #with_connection methods, connections obtained through # #checkout will not be automatically released. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#200 - def release_connection(owner_thread = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#383 + def release_connection(existing_lease = T.unsafe(nil)); end # Remove a connection from the connection pool. The connection will # remain open and active but will no longer be managed by this pool. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#365 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#583 def remove(conn); end # Returns the value of attribute role. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 def role; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#469 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#688 def schedule_query(future_result); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#112 - def schema_cache(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#273 + def schema_cache; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#290 + def schema_migration; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#212 + def schema_reflection(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#112 - def schema_cache=(arg); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#277 + def schema_reflection=(schema_reflection); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#212 + def server_version(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute shard. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 def shard; end # Returns the value of attribute size. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 def size; end - # Return connection pool's usage statistic - # Example: + # Returns the connection pool's usage statistic. # # ActiveRecord::Base.connection_pool.stat # => { size: 15, connections: 1, busy: 1, dead: 0, idle: 0, waiting: 0, checkout_timeout: 5 } # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#455 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#674 def stat; end - # If a connection obtained through #connection or #with_connection methods - # already exists yield it to the block. If no such connection - # exists checkout a connection, yield it to the block, and checkin the - # connection when finished. + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#336 + def unpin_connection!; end + + # Yields a connection from the connection pool to the block. If no connection + # is already checked out by the current thread, a connection will be checked + # out from the pool, yielded to the block, and then returned to the pool when + # the block is finished. If a connection has already been checked out on the + # current thread, such as via #lease_connection or #with_connection, that existing + # connection will be the one yielded and it will not be returned to the pool + # automatically at the end of the block; it is expected that such an existing + # connection will be properly returned to the pool by the code that checked + # it out. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#210 - def with_connection; end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#400 + def with_connection(prevent_permanent_checkout: T.unsafe(nil)); end private @@ -11493,63 +12641,51 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # Implementation detail: the connection returned by +acquire_connection+ # will already be "+connection.lease+ -ed" to the current thread. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#633 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#846 def acquire_connection(checkout_timeout); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#693 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#916 def adopt_connection(conn); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#527 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#737 def attempt_to_checkout_all_existing_connections(raise_on_acquisition_timeout = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#475 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#698 def build_async_executor; end # -- # this is unfortunately not concurrent # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#493 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#716 def bulk_make_new_connections(num_new_conns_needed); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#703 - def checkout_and_verify(c); end - # -- # Must be called in a synchronize block. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#573 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#786 def checkout_for_exclusive_access(checkout_timeout); end # @raise [ConnectionNotEstablished] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#698 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#927 def checkout_new_connection; end - # -- - # From the discussion on GitHub: - # https://github.com/rails/rails/pull/14938#commitcomment-6601951 - # This hook-in method allows for easier monkey-patching fixes needed by - # JRuby users that use Fibers. - # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#508 - def connection_cache_key(thread); end - - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#512 - def current_thread; end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#694 + def connection_lease; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#655 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#876 def new_connection; end # -- # if owner_thread param is omitted, this must be called in synchronize block # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#650 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#871 def release(conn, owner_thread = T.unsafe(nil)); end # -- # if owner_thread param is omitted, this must be called in synchronize block # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#650 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#871 def remove_connection_from_thread_cache(conn, owner_thread = T.unsafe(nil)); end # If the pool is not at a @size limit, establish new connection. Connecting @@ -11558,7 +12694,7 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # Implementation constraint: a newly established connection returned by this # method must be in the +.leased+ state. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#666 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#889 def try_to_checkout_new_connection; end # Take control of all existing connections so a "group" action such as @@ -11566,42 +12702,42 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool # wrap it in +synchronize+ because some pool's actions are allowed # to be performed outside of the main +synchronize+ block. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#520 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#730 def with_exclusively_acquired_all_connections(raise_on_acquisition_timeout = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#593 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#806 def with_new_connections_blocked; end end # Adds the ability to turn a basic fair FIFO queue into one # biased to some thread. # -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#136 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#138 module ActiveRecord::ConnectionAdapters::ConnectionPool::BiasableQueue - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#176 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#178 def with_a_bias_for(thread); end end -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#137 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#139 class ActiveRecord::ConnectionAdapters::ConnectionPool::BiasableQueue::BiasedConditionVariable # semantics of condition variables guarantee that +broadcast+, +broadcast_on_biased+, # +signal+ and +wait+ methods are only called while holding a lock # # @return [BiasedConditionVariable] a new instance of BiasedConditionVariable # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#140 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#142 def initialize(lock, other_cond, preferred_thread); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#147 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#149 def broadcast; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#152 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#154 def broadcast_on_biased; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#157 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#159 def signal; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#166 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#168 def wait(timeout); end end @@ -11611,52 +12747,109 @@ end # @lock as the main pool) so that a returned connection is already # leased and there is no need to re-enter synchronized block. # -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#197 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#199 class ActiveRecord::ConnectionAdapters::ConnectionPool::ConnectionLeasingQueue < ::ActiveRecord::ConnectionAdapters::ConnectionPool::Queue include ::ActiveRecord::ConnectionAdapters::ConnectionPool::BiasableQueue private - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#201 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#203 def internal_poll(timeout); end end +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#121 +class ActiveRecord::ConnectionAdapters::ConnectionPool::Lease + # @return [Lease] a new instance of Lease + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#124 + def initialize; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#136 + def clear(connection); end + + # Returns the value of attribute connection. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#122 + def connection; end + + # Sets the attribute connection + # + # @param value the value to set the attribute connection to. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#122 + def connection=(_arg0); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#129 + def release; end + + # Returns the value of attribute sticky. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#122 + def sticky; end + + # Sets the attribute sticky + # + # @param value the value to set the attribute sticky to. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#122 + def sticky=(_arg0); end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#147 +class ActiveRecord::ConnectionAdapters::ConnectionPool::LeaseRegistry + # @return [LeaseRegistry] a new instance of LeaseRegistry + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#187 + def initialize; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#192 + def [](context); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#198 + def clear; end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#149 +ActiveRecord::ConnectionAdapters::ConnectionPool::LeaseRegistry::WeakKeyMap = ObjectSpace::WeakKeyMap + +# = Active Record Connection Pool \Queue +# # Threadsafe, fair, LIFO queue. Meant to be used by ConnectionPool # with which it shares a Monitor. # -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#11 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#13 class ActiveRecord::ConnectionAdapters::ConnectionPool::Queue # @return [Queue] a new instance of Queue # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#12 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#14 def initialize(lock = T.unsafe(nil)); end # Add +element+ to the queue. Never blocks. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#35 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#37 def add(element); end # Test if any threads are currently waiting on the queue. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#20 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#22 def any_waiting?; end # Remove all elements from the queue. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#50 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#52 def clear; end # If +element+ is in the queue, remove and return it, or +nil+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#43 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#45 def delete(element); end # Returns the number of threads currently waiting on this # queue. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#28 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#30 def num_waiting; end # Remove the head of the queue. @@ -11674,7 +12867,7 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool::Queue # - ActiveRecord::ConnectionTimeoutError if +timeout+ is given and no element # becomes available within +timeout+ seconds, # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#70 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#72 def poll(timeout = T.unsafe(nil)); end private @@ -11683,7 +12876,7 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool::Queue # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#84 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#86 def any?; end # A thread can remove an element from the queue without @@ -11693,73 +12886,75 @@ class ActiveRecord::ConnectionAdapters::ConnectionPool::Queue # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#92 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#94 def can_remove_no_wait?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#75 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#77 def internal_poll(timeout); end # Remove and return the head of the queue if the number of # available elements is strictly greater than the number of # threads currently waiting. Otherwise, return +nil+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#104 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#106 def no_wait_poll; end # Removes and returns the head of the queue if possible, or +nil+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#97 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#99 def remove; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#79 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#81 def synchronize(&block); end # Waits on the queue up to +timeout+ seconds, then removes and # returns the head of the queue. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#110 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/queue.rb#112 def wait_poll(timeout); end end +# = Active Record Connection Pool \Reaper +# # Every +frequency+ seconds, the reaper will call +reap+ and +flush+ on # +pool+. A reaper instantiated with a zero frequency will never reap # the connection pool. # # Configure the frequency by setting +reaping_frequency+ in your database -# yaml file (default 60 seconds). +# YAML file (default 60 seconds). # -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#15 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#17 class ActiveRecord::ConnectionAdapters::ConnectionPool::Reaper # @return [Reaper] a new instance of Reaper # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#18 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#20 def initialize(pool, frequency); end # Returns the value of attribute frequency. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#16 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#18 def frequency; end # Returns the value of attribute pool. # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#16 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#18 def pool; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#72 def run; end class << self - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#28 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#30 def register_pool(pool, frequency); end private - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#39 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool/reaper.rb#41 def spawn_thread(frequency); end end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#84 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#120 class ActiveRecord::ConnectionAdapters::CreateIndexDefinition < ::Struct # Returns the value of attribute algorithm # @@ -11807,7 +13002,7 @@ end module ActiveRecord::ConnectionAdapters::DatabaseLimits # Returns the maximum length of an index name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#16 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#21 def index_name_length; end # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#6 @@ -11815,12 +13010,17 @@ module ActiveRecord::ConnectionAdapters::DatabaseLimits # Returns the maximum length of a table alias. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#11 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#16 def table_alias_length; end + # Returns the maximum length of a table name. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#11 + def table_name_length; end + private - # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#21 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_limits.rb#26 def bind_params_length; end end @@ -11832,12 +13032,12 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # Register a record with the current transaction so that its after_commit and after_rollback callbacks # can be called. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#345 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#407 def add_transaction_record(record, ensure_finalize = T.unsafe(nil)); end # Begins the transaction (and turns off auto-committing). # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#350 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#412 def begin_db_transaction; end # Begins the transaction with the isolation level set. Raises an error by @@ -11846,24 +13046,24 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # # @raise [ActiveRecord::TransactionIsolationError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#364 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#426 def begin_isolated_db_transaction(isolation); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def begin_transaction(*_arg0, **_arg1, &_arg2); end # This is used in the StatementCache object. It returns an object that # can be used to query the database repeatedly. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#49 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#56 def cacheable_query(klass, arel); end # Commits the transaction (and turns on auto-committing). # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#431 def commit_db_transaction; end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def commit_transaction(*_arg0, **_arg1, &_arg2); end # Executes an INSERT query and returns the new record's ID @@ -11874,81 +13074,102 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # # If the next id was calculated in advance (as in Oracle), it should be # passed in as +id_value+. + # Some adapters support the `returning` keyword argument which allows defining the return value of the method: + # `nil` is the default value and maintains default behavior. If an array of column names is passed - + # an array of is returned from the method representing values of the specified columns from the inserted row. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#165 - def create(arel, name = T.unsafe(nil), pk = T.unsafe(nil), id_value = T.unsafe(nil), sequence_name = T.unsafe(nil), binds = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#195 + def create(arel, name = T.unsafe(nil), pk = T.unsafe(nil), id_value = T.unsafe(nil), sequence_name = T.unsafe(nil), binds = T.unsafe(nil), returning: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def current_transaction(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#383 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#453 def default_sequence_name(table, column); end # Executes the delete statement and returns the number of rows affected. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#179 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#212 def delete(arel, name = T.unsafe(nil), binds = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 + def dirty_current_transaction(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def disable_lazy_transactions!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#415 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#485 def empty_insert_statement_value(primary_key = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def enable_lazy_transactions!(*_arg0, **_arg1, &_arg2); end # Executes delete +sql+ statement in the context of this connection using # +binds+ as the bind substitutes. +name+ is logged along with # the executed +sql+ statement. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#138 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#165 def exec_delete(sql, name = T.unsafe(nil), binds = T.unsafe(nil)); end # Executes insert +sql+ statement in the context of this connection using # +binds+ as the bind substitutes. +name+ is logged along with # the executed +sql+ statement. + # Some adapters support the `returning` keyword argument which allows to control the result of the query: + # `nil` is the default value and maintains default behavior. If an array of column names is passed - + # the result will contain values of the specified columns from the inserted row. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#130 - def exec_insert(sql, name = T.unsafe(nil), binds = T.unsafe(nil), pk = T.unsafe(nil), sequence_name = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#157 + def exec_insert(sql, name = T.unsafe(nil), binds = T.unsafe(nil), pk = T.unsafe(nil), sequence_name = T.unsafe(nil), returning: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#149 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#176 def exec_insert_all(sql, name); end # Executes +sql+ statement in the context of this connection using # +binds+ as the bind substitutes. +name+ is logged along with # the executed +sql+ statement. # - # @raise [NotImplementedError] + # Note: the query is assumed to have side effects and the query cache + # will be cleared. If the query is read-only, consider using #select_all + # instead. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#123 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#147 def exec_query(sql, name = T.unsafe(nil), binds = T.unsafe(nil), prepare: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#377 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#447 + def exec_restart_db_transaction; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#441 def exec_rollback_db_transaction; end # Executes update +sql+ statement in the context of this connection using # +binds+ as the bind substitutes. +name+ is logged along with # the executed +sql+ statement. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#145 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#172 def exec_update(sql, name = T.unsafe(nil), binds = T.unsafe(nil)); end # Executes the SQL statement in the context of this connection and returns # the raw result from the connection adapter. + # + # Setting +allow_retry+ to true causes the db to reconnect and retry + # executing the SQL statement in case of a connection-related exception. + # This option should only be enabled for known idempotent queries. + # + # Note: the query is assumed to have side effects and the query cache + # will be cleared. If the query is read-only, consider using #select_all + # instead. + # # Note: depending on your database connector, the result returned by this - # method may be manually memory managed. Consider using the exec_query + # method may be manually memory managed. Consider using #exec_query # wrapper instead. # - # @raise [NotImplementedError] - # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#116 - def execute(sql, name = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#136 + def execute(sql, name = T.unsafe(nil), allow_retry: T.unsafe(nil)); end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#153 - def explain(arel, binds = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#180 + def explain(arel, binds = T.unsafe(nil), options = T.unsafe(nil)); end # Returns an Arel SQL literal for the CURRENT_TIMESTAMP for usage with # arbitrary precision date/time columns. @@ -11956,7 +13177,7 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # Adapters supporting datetime with precision should override this to # provide as much precision as is available. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#453 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#523 def high_precision_current_timestamp; end # Executes an INSERT query and returns the new record's ID @@ -11967,58 +13188,69 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # # If the next id was calculated in advance (as in Oracle), it should be # passed in as +id_value+. + # Some adapters support the `returning` keyword argument which allows defining the return value of the method: + # `nil` is the default value and maintains default behavior. If an array of column names is passed - + # an array of is returned from the method representing values of the specified columns from the inserted row. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#165 - def insert(arel, name = T.unsafe(nil), pk = T.unsafe(nil), id_value = T.unsafe(nil), sequence_name = T.unsafe(nil), binds = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#195 + def insert(arel, name = T.unsafe(nil), pk = T.unsafe(nil), id_value = T.unsafe(nil), sequence_name = T.unsafe(nil), binds = T.unsafe(nil), returning: T.unsafe(nil)); end # Inserts the given fixture into the table. Overridden in adapters that require # something beyond a simple insert (e.g. Oracle). # Most of adapters should implement +insert_fixtures_set+ that leverages bulk SQL insert. # We keep this method to provide fallback - # for databases like sqlite that do not support bulk inserts. + # for databases like SQLite that do not support bulk inserts. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#397 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#467 def insert_fixture(fixture, table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#401 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#471 def insert_fixtures_set(fixture_set, tables_to_delete = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#328 + # @raise [NotImplementedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#527 + def internal_exec_query(sql, name = T.unsafe(nil), binds = T.unsafe(nil), prepare: T.unsafe(nil), async: T.unsafe(nil), allow_retry: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#374 def mark_transaction_written_if_write(sql); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def materialize_transactions(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def open_transactions(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#102 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#113 def query(sql, name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#94 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#105 def query_value(sql, name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#98 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#109 def query_values(sql, name = T.unsafe(nil)); end # Set the sequence to the max value of the table's column. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#388 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#458 def reset_sequence!(table, column, sequence = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#339 - def reset_transaction; end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#385 + def reset_transaction(restore: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#443 + def restart_db_transaction; end # Rolls back the transaction (and turns on auto-committing). Must be # done if the transaction block raises an exception or returns false. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#373 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#435 def rollback_db_transaction; end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#379 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#449 def rollback_to_savepoint(name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def rollback_transaction(*_arg0, **_arg1, &_arg2); end # Sanitizes the given LIMIT parameter in order to prevent SQL injection. @@ -12028,35 +13260,35 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # # Returns Integer and Arel::Nodes::SqlLiteral limits as is. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#425 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#495 def sanitize_limit(limit); end # Returns an ActiveRecord::Result instance. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#62 - def select_all(arel, name = T.unsafe(nil), binds = T.unsafe(nil), preparable: T.unsafe(nil), async: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#69 + def select_all(arel, name = T.unsafe(nil), binds = T.unsafe(nil), preparable: T.unsafe(nil), async: T.unsafe(nil), allow_retry: T.unsafe(nil)); end # Returns a record hash with the column names as keys and column values # as values. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#73 - def select_one(arel, name = T.unsafe(nil), binds = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#84 + def select_one(arel, name = T.unsafe(nil), binds = T.unsafe(nil), async: T.unsafe(nil)); end # Returns an array of arrays containing the field values. # Order is the same as that returned by +columns+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#90 - def select_rows(arel, name = T.unsafe(nil), binds = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#101 + def select_rows(arel, name = T.unsafe(nil), binds = T.unsafe(nil), async: T.unsafe(nil)); end # Returns a single value from a record # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#78 - def select_value(arel, name = T.unsafe(nil), binds = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#89 + def select_value(arel, name = T.unsafe(nil), binds = T.unsafe(nil), async: T.unsafe(nil)); end # Returns an array of the values of the first column in a select: # select_values("SELECT id FROM companies LIMIT 3") => [1,2,3] # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#84 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#95 def select_values(arel, name = T.unsafe(nil), binds = T.unsafe(nil)); end # Converts an arel AST to SQL @@ -12067,6 +13299,17 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # Runs the given block in a database transaction, and returns the result # of the block. # + # == Transaction callbacks + # + # #transaction yields an ActiveRecord::Transaction object on which it is + # possible to register callback: + # + # ActiveRecord::Base.transaction do |transaction| + # transaction.before_commit { puts "before commit!" } + # transaction.after_commit { puts "after commit!" } + # transaction.after_rollback { puts "after rollback!" } + # end + # # == Nested transactions support # # #transaction calls can be nested. By default, this makes all database @@ -12134,9 +13377,9 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # #transaction will raise exceptions when it tries to release the # already-automatically-released savepoints: # - # Model.connection.transaction do # BEGIN - # Model.connection.transaction(requires_new: true) do # CREATE SAVEPOINT active_record_1 - # Model.connection.create_table(...) + # Model.lease_connection.transaction do # BEGIN + # Model.lease_connection.transaction(requires_new: true) do # CREATE SAVEPOINT active_record_1 + # Model.lease_connection.create_table(...) # # active_record_1 now automatically released # end # RELEASE SAVEPOINT active_record_1 <--- BOOM! database error! # end @@ -12169,44 +13412,45 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # * You are joining an existing open transaction # * You are creating a nested (savepoint) transaction # - # The mysql2 and postgresql adapters support setting the transaction + # The mysql2, trilogy, and postgresql adapters support setting the transaction # isolation level. + # :args: (requires_new: nil, isolation: nil, &block) # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#309 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#354 def transaction(requires_new: T.unsafe(nil), isolation: T.unsafe(nil), joinable: T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#352 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#414 def transaction_isolation_levels; end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#322 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#367 def transaction_manager; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#335 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#381 def transaction_open?; end # Executes the truncate statement. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#185 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#218 def truncate(table_name, name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#222 def truncate_tables(*table_names); end # Executes the update statement and returns the number of rows affected. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#173 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#206 def update(arel, name = T.unsafe(nil), binds = T.unsafe(nil)); end # Fixture value is quoted by Arel, however scalar values # are not quotable. In this case we want to convert # the column value to YAML. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#436 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#506 def with_yaml_fallback(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#324 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#369 def within_new_transaction(*_arg0, **_arg1, &_arg2); end # Determines whether the SQL statement is a write query. @@ -12214,62 +13458,76 @@ module ActiveRecord::ConnectionAdapters::DatabaseStatements # @raise [NotImplementedError] # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#107 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#118 def write_query?(sql); end private - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#576 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#685 def arel_from_relation(relation); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#471 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#558 def build_fixture_sql(fixtures, table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#513 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#600 def build_fixture_statements(fixture_set); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#520 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#607 def build_truncate_statement(table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#524 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#611 def build_truncate_statements(table_names); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#534 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#621 def combine_multi_statements(total_sql); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#467 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#554 def default_insert_value(column); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#458 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#541 def execute_batch(statements, name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#567 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#693 + def extract_table_ref_from_insert_sql(sql); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#532 + def internal_execute(sql, name = T.unsafe(nil), allow_retry: T.unsafe(nil), materialize_transactions: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#672 def last_inserted_id(result); end + # @raise [NotImplementedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#547 + def raw_execute(sql, name, async: T.unsafe(nil), allow_retry: T.unsafe(nil), materialize_transactions: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#676 + def returning_column_values(result); end + # Returns an ActiveRecord::Result instance. # - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#539 - def select(sql, name = T.unsafe(nil), binds = T.unsafe(nil), prepare: T.unsafe(nil), async: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#626 + def select(sql, name = T.unsafe(nil), binds = T.unsafe(nil), prepare: T.unsafe(nil), async: T.unsafe(nil), allow_retry: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#571 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#680 def single_value_from_rows(rows); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#563 - def sql_for_insert(sql, pk, binds); end + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#655 + def sql_for_insert(sql, pk, binds, returning); end # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#17 - def to_sql_and_binds(arel_or_sql_string, binds = T.unsafe(nil), preparable = T.unsafe(nil)); end + def to_sql_and_binds(arel_or_sql_string, binds = T.unsafe(nil), preparable = T.unsafe(nil), allow_retry = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#530 + # source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#617 def with_multi_statements; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#464 +# source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#551 ActiveRecord::ConnectionAdapters::DatabaseStatements::DEFAULT_INSERT_VALUE = T.let(T.unsafe(nil), Arel::Nodes::SqlLiteral) # This is a safe default, even if not high precision on all databases # -# source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#445 +# source://activerecord//lib/active_record/connection_adapters/abstract/database_statements.rb#515 ActiveRecord::ConnectionAdapters::DatabaseStatements::HIGH_PRECISION_CURRENT_TIMESTAMP = T.let(T.unsafe(nil), Arel::Nodes::SqlLiteral) # source://activerecord//lib/active_record/connection_adapters/deduplicable.rb#5 @@ -12299,27 +13557,27 @@ module ActiveRecord::ConnectionAdapters::Deduplicable::ClassMethods def registry; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#88 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#124 class ActiveRecord::ConnectionAdapters::ForeignKeyDefinition < ::Struct - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#93 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#129 def column; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#113 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#149 def custom_primary_key?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#109 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#145 def deferrable; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#126 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#162 def defined_for?(to_table: T.unsafe(nil), validate: T.unsafe(nil), **options); end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#122 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#158 def export_name_on_schema_dump?; end # Returns the value of attribute from_table @@ -12333,13 +13591,13 @@ class ActiveRecord::ConnectionAdapters::ForeignKeyDefinition < ::Struct # @return [Object] the newly set value def from_table=(_); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#89 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#125 def name; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#101 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#137 def on_delete; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#105 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#141 def on_update; end # Returns the value of attribute options @@ -12353,7 +13611,7 @@ class ActiveRecord::ConnectionAdapters::ForeignKeyDefinition < ::Struct # @return [Object] the newly set value def options=(_); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#97 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#133 def primary_key; end # Returns the value of attribute to_table @@ -12369,17 +13627,17 @@ class ActiveRecord::ConnectionAdapters::ForeignKeyDefinition < ::Struct # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#117 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#153 def validate?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#117 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#153 def validated?; end private - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#133 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#169 def default_primary_key; end class << self @@ -12395,179 +13653,226 @@ end # this type are typically created and returned by methods in database # adapters. e.g. ActiveRecord::ConnectionAdapters::MySQL::SchemaStatements#indexes # -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#8 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 class ActiveRecord::ConnectionAdapters::IndexDefinition # @return [IndexDefinition] a new instance of IndexDefinition # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#11 - def initialize(table, name, unique = T.unsafe(nil), columns = T.unsafe(nil), lengths: T.unsafe(nil), orders: T.unsafe(nil), opclasses: T.unsafe(nil), where: T.unsafe(nil), type: T.unsafe(nil), using: T.unsafe(nil), comment: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#12 + def initialize(table, name, unique = T.unsafe(nil), columns = T.unsafe(nil), lengths: T.unsafe(nil), orders: T.unsafe(nil), opclasses: T.unsafe(nil), where: T.unsafe(nil), type: T.unsafe(nil), using: T.unsafe(nil), include: T.unsafe(nil), nulls_not_distinct: T.unsafe(nil), comment: T.unsafe(nil), valid: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#36 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#47 def column_options; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def columns; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def comment; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#55 + def defined_for?(columns = T.unsafe(nil), name: T.unsafe(nil), unique: T.unsafe(nil), valid: T.unsafe(nil), include: T.unsafe(nil), nulls_not_distinct: T.unsafe(nil), **options); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 + def include; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def lengths; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def name; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 + def nulls_not_distinct; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def opclasses; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def orders; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def table; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def type; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def unique; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 def using; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#9 - def where; end - - private + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 + def valid; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#45 - def concise_options(options); end -end - -# source://activerecord//lib/active_record/connection_adapters/legacy_pool_manager.rb#5 -class ActiveRecord::ConnectionAdapters::LegacyPoolManager - # @return [LegacyPoolManager] a new instance of LegacyPoolManager + # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/legacy_pool_manager.rb#6 - def initialize; end - - # source://activerecord//lib/active_record/connection_adapters/legacy_pool_manager.rb#22 - def get_pool_config(_, shard); end - - # source://activerecord//lib/active_record/connection_adapters/legacy_pool_manager.rb#14 - def pool_configs(_ = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#43 + def valid?; end - # source://activerecord//lib/active_record/connection_adapters/legacy_pool_manager.rb#18 - def remove_pool_config(_, shard); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#10 + def where; end - # source://activerecord//lib/active_record/connection_adapters/legacy_pool_manager.rb#26 - def set_pool_config(role, shard, pool_config); end + private - # source://activerecord//lib/active_record/connection_adapters/legacy_pool_manager.rb#10 - def shard_names; end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#66 + def concise_options(options); end end -# source://activerecord//lib/active_record/connection_adapters/column.rb#106 +# source://activerecord//lib/active_record/connection_adapters/column.rb#115 class ActiveRecord::ConnectionAdapters::NullColumn < ::ActiveRecord::ConnectionAdapters::Column # @return [NullColumn] a new instance of NullColumn # - # source://activerecord//lib/active_record/connection_adapters/column.rb#107 + # source://activerecord//lib/active_record/connection_adapters/column.rb#116 def initialize(name, **_arg1); end end -# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#31 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#15 class ActiveRecord::ConnectionAdapters::NullPool include ::ActiveRecord::ConnectionAdapters::AbstractPool - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#39 + # @return [NullPool] a new instance of NullPool + # + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#25 + def initialize; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#43 def async_executor; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#37 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#41 def checkin(_); end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#36 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#40 def connection_class; end - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#38 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#45 + def db_config; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#49 + def dirties_query_cache; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#42 def remove(_); end - # Returns the value of attribute schema_cache. - # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#34 + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#39 def schema_cache; end - # Sets the attribute schema_cache - # - # @param value the value to set the attribute schema_cache to. - # - # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#34 - def schema_cache=(_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#35 + def schema_reflection; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#31 + def server_version(connection); end end -# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#76 -class ActiveRecord::ConnectionAdapters::NullTransaction - # @return [NullTransaction] a new instance of NullTransaction - # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#77 - def initialize; end +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#23 +ActiveRecord::ConnectionAdapters::NullPool::NULL_CONFIG = T.let(T.unsafe(nil), ActiveRecord::ConnectionAdapters::NullPool::NullConfig) - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#82 +# source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#18 +class ActiveRecord::ConnectionAdapters::NullPool::NullConfig + # source://activerecord//lib/active_record/connection_adapters/abstract/connection_pool.rb#19 + def method_missing(*_arg0, **_arg1, &_arg2); end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#110 +class ActiveRecord::ConnectionAdapters::NullTransaction + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#115 def add_record(record, _ = T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#123 + def after_commit; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#124 + def after_rollback; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#122 + def before_commit; end + # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#79 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#112 def closed?; end + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#118 + def dirty!; end + # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#81 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#117 + def dirty?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#120 + def invalidate!; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#119 + def invalidated?; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#114 def joinable?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#80 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#121 + def materialized?; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#113 def open?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#78 + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#116 + def restartable?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#111 def state; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#125 + def user_transaction; end end # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#5 class ActiveRecord::ConnectionAdapters::PoolConfig - include ::Mutex_m + include ::MonitorMixin # @return [PoolConfig] a new instance of PoolConfig # - # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#20 + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#29 def initialize(connection_class, db_config, role, shard); end # Returns the value of attribute connection_class. # - # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#8 + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#10 def connection_class; end - # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#30 - def connection_specification_name; end + # Sets the attribute connection_class + # + # @param value the value to set the attribute connection_class to. + # + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#10 + def connection_class=(_arg0); end + + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#44 + def connection_name; end # Returns the value of attribute db_config. # # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#8 def db_config; end - # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#59 + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#69 def discard_pool!; end - # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#38 - def disconnect!; end + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#52 + def disconnect!(automatic_reconnect: T.unsafe(nil)); end - # source://mutex_m/0.1.2/mutex_m.rb#93 - def lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#83 - def locked?; end - - # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#53 + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#65 def pool; end # Returns the value of attribute role. @@ -12575,39 +13880,41 @@ class ActiveRecord::ConnectionAdapters::PoolConfig # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#8 def role; end - # Returns the value of attribute schema_cache. + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#12 + def schema_reflection; end + + # Sets the attribute schema_reflection + # + # @param value the value to set the attribute schema_reflection to. # # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#9 - def schema_cache; end + def schema_reflection=(_arg0); end + + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#40 + def server_version(connection); end - # Sets the attribute schema_cache + # Sets the attribute server_version # - # @param value the value to set the attribute schema_cache to. + # @param value the value to set the attribute server_version to. # # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#9 - def schema_cache=(_arg0); end + def server_version=(_arg0); end # Returns the value of attribute shard. # # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#8 def shard; end - # source://mutex_m/0.1.2/mutex_m.rb#78 - def synchronize(&block); end - - # source://mutex_m/0.1.2/mutex_m.rb#88 - def try_lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#98 - def unlock; end - class << self - # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#15 + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#20 def discard_pools!; end + + # source://activerecord//lib/active_record/connection_adapters/pool_config.rb#24 + def disconnect_all!; end end end -# source://activerecord//lib/active_record/connection_adapters/pool_config.rb#11 +# source://activerecord//lib/active_record/connection_adapters/pool_config.rb#16 ActiveRecord::ConnectionAdapters::PoolConfig::INSTANCES = T.let(T.unsafe(nil), ObjectSpace::WeakMap) # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#5 @@ -12617,29 +13924,32 @@ class ActiveRecord::ConnectionAdapters::PoolManager # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#6 def initialize; end - # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#34 + # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#26 + def each_pool_config(role = T.unsafe(nil), &block); end + + # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#44 def get_pool_config(role, shard); end # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#18 def pool_configs(role = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#30 + # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#40 def remove_pool_config(role, shard); end - # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#26 + # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#36 def remove_role(role); end # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#14 def role_names; end - # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#38 + # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#48 def set_pool_config(role, shard, pool_config); end # source://activerecord//lib/active_record/connection_adapters/pool_manager.rb#10 def shard_names; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#86 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#122 class ActiveRecord::ConnectionAdapters::PrimaryKeyDefinition < ::Struct # Returns the value of attribute name # @@ -12663,13 +13973,13 @@ end # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#7 module ActiveRecord::ConnectionAdapters::QueryCache - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#52 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#167 def initialize(*_arg0); end # Enable the query cache within the block. # - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#59 - def cache; end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#177 + def cache(&block); end # Clears the query cache. # @@ -12678,81 +13988,183 @@ module ActiveRecord::ConnectionAdapters::QueryCache # the same SQL query and repeatedly return the same result each time, silently # undermining the randomness you were expecting. # - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#90 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#203 def clear_query_cache; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#71 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#193 def disable_query_cache!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#67 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#181 def enable_query_cache!; end # Returns the value of attribute query_cache. # - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#50 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#165 def query_cache; end - # Returns the value of attribute query_cache_enabled. + # Sets the attribute query_cache # - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#50 + # @param value the value to set the attribute query_cache to. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#165 + def query_cache=(_arg0); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#172 def query_cache_enabled; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#96 - def select_all(arel, name = T.unsafe(nil), binds = T.unsafe(nil), preparable: T.unsafe(nil), async: T.unsafe(nil)); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#207 + def select_all(arel, name = T.unsafe(nil), binds = T.unsafe(nil), preparable: T.unsafe(nil), async: T.unsafe(nil), allow_retry: T.unsafe(nil)); end # Disable the query cache within the block. # - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#77 - def uncached; end + # Set dirties: false to prevent query caches on all connections from being cleared by write operations. + # (By default, write operations dirty all connections' query caches in case they are replicas whose cache would now be outdated.) + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#189 + def uncached(dirties: T.unsafe(nil), &block); end private # Database adapters can override this method to # provide custom cache information. # - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#145 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#273 def cache_notification_info(sql, name, binds); end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#127 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#249 def cache_sql(sql, name, binds); end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#156 - def configure_query_cache!; end - - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#115 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#231 def lookup_sql_cache(sql, name, binds); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#227 + def unset_query_cache!; end + class << self - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#17 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#19 def dirties_query_cache(base, *method_names); end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#9 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#11 def included(base); end end end -# source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#29 +# source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#81 module ActiveRecord::ConnectionAdapters::QueryCache::ConnectionPoolConfiguration - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#30 - def initialize(*_arg0); end + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#82 + def initialize(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#40 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#96 + def checkout_and_verify(connection); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#139 + def clear_query_cache; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#135 + def dirties_query_cache; end + + # Disable the query cache within the block. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#103 + def disable_query_cache(dirties: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#127 def disable_query_cache!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#35 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#113 + def enable_query_cache; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#123 def enable_query_cache!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#45 + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#150 + def query_cache; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#131 def query_cache_enabled; end + + private + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#157 + def prune_thread_cache; end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#8 +ActiveRecord::ConnectionAdapters::QueryCache::DEFAULT_SIZE = T.let(T.unsafe(nil), Integer) + +# source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#33 +class ActiveRecord::ConnectionAdapters::QueryCache::Store + # @return [Store] a new instance of Store + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#38 + def initialize(max_size); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#53 + def [](key); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#75 + def clear; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#61 + def compute_if_absent(key); end + + # Returns the value of attribute dirties. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#34 + def dirties; end + + # Sets the attribute dirties + # + # @param value the value to set the attribute dirties to. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#34 + def dirties=(_arg0); end + + # Returns the value of attribute dirties. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#34 + def dirties?; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#49 + def empty?; end + + # Returns the value of attribute enabled. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#34 + def enabled; end + + # Sets the attribute enabled + # + # @param value the value to set the attribute enabled to. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#34 + def enabled=(_arg0); end + + # Returns the value of attribute enabled. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#34 + def enabled?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/query_cache.rb#45 + def size; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#8 +# = Active Record Connection Adapters \Quoting +# +# source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#9 module ActiveRecord::ConnectionAdapters::Quoting - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#161 - def column_name_matcher; end + extend ::ActiveSupport::Concern - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#165 - def column_name_with_order_matcher; end + mixes_in_class_methods ::ActiveRecord::ConnectionAdapters::Quoting::ClassMethods + + # Cast a value to be used as a bound parameter of unknown type. For example, + # MySQL might perform dangerous castings when comparing a string to a number, + # so this method will cast numbers to string. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#112 + def cast_bound_value(value); end # If you are having to call this function, you are likely doing something # wrong. The column does not have sufficient type information if the user @@ -12764,368 +14176,406 @@ module ActiveRecord::ConnectionAdapters::Quoting # (varchar vs binary) for example. The type used to get this primitive # should have been provided before reaching the connection adapter. # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#63 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#125 def lookup_cast_type_from_column(column); end # Quotes the column value to help prevent # {SQL injection attacks}[https://en.wikipedia.org/wiki/SQL_injection]. # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#11 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#73 def quote(value); end - # Quote a value to be used as a bound parameter of unknown type. For example, - # MySQL might perform dangerous castings when comparing a string to a number, - # so this method will cast numbers to string. - # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#50 - def quote_bound_value(value); end - - # Quotes the column name. Defaults to no quoting. + # Quotes the column name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#74 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#136 def quote_column_name(column_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#95 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#157 def quote_default_expression(value, column); end # Quotes a string, escaping any ' (single quote) and \ (backslash) # characters. # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#69 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#131 def quote_string(s); end - # Quotes the table name. Defaults to column name quoting. + # Quotes the table name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#79 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#141 def quote_table_name(table_name); end # Override to return the quoted table name for assignment. Defaults to # table quoting. # - # This works for mysql2 where table.column can be used to + # This works for MySQL where table.column can be used to # resolve ambiguity. # # We override this in the sqlite3 and postgresql adapters to use only # the column name (as per syntax requirements). # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#91 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#153 def quote_table_name_for_assignment(table, attr); end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#144 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#206 def quoted_binary(value); end # Quote date/time values for use in SQL input. Includes microseconds # if the value is a Time responding to usec. # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#122 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#184 def quoted_date(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#112 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#174 def quoted_false; end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#139 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#201 def quoted_time(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#104 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#166 def quoted_true; end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#148 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#210 def sanitize_as_sql_comment(value); end # Cast a +value+ to a type that the database understands. For example, # SQLite does not understand dates, so this method will convert a Date # to a String. # - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#32 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#94 def type_cast(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#116 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#178 def unquoted_false; end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#170 def unquoted_true; end private - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#225 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#234 def lookup_cast_type(sql_type); end - # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#215 + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#224 def type_casted_binds(binds); end end -# Regexp for column names (with or without a table name prefix). -# Matches the following: -# -# "#{table_name}.#{column_name}" -# "#{column_name}" -# -# source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#174 -ActiveRecord::ConnectionAdapters::Quoting::COLUMN_NAME = T.let(T.unsafe(nil), Regexp) +# source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#12 +module ActiveRecord::ConnectionAdapters::Quoting::ClassMethods + # Regexp for column names (with or without a table name prefix). + # Matches the following: + # + # "#{table_name}.#{column_name}" + # "#{column_name}" + # + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#18 + def column_name_matcher; end -# Regexp for column names with order (with or without a table name prefix, -# with or without various order modifiers). Matches the following: -# -# "#{table_name}.#{column_name}" -# "#{table_name}.#{column_name} #{direction}" -# "#{table_name}.#{column_name} #{direction} NULLS FIRST" -# "#{table_name}.#{column_name} NULLS LAST" -# "#{column_name}" -# "#{column_name} #{direction}" -# "#{column_name} #{direction} NULLS FIRST" -# "#{column_name} NULLS LAST" -# -# source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#198 -ActiveRecord::ConnectionAdapters::Quoting::COLUMN_NAME_WITH_ORDER = T.let(T.unsafe(nil), Regexp) + # Regexp for column names with order (with or without a table name prefix, + # with or without various order modifiers). Matches the following: + # + # "#{table_name}.#{column_name}" + # "#{table_name}.#{column_name} #{direction}" + # "#{table_name}.#{column_name} #{direction} NULLS FIRST" + # "#{table_name}.#{column_name} NULLS LAST" + # "#{column_name}" + # "#{column_name} #{direction}" + # "#{column_name} #{direction} NULLS FIRST" + # "#{column_name} NULLS LAST" + # + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#44 + def column_name_with_order_matcher; end + + # Quotes the column name. Must be implemented by subclasses + # + # @raise [NotImplementedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#61 + def quote_column_name(column_name); end + + # Quotes the table name. Defaults to column name quoting. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/quoting.rb#66 + def quote_table_name(table_name); end +end -# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#202 +# = Active Record Real \Transaction +# +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#449 class ActiveRecord::ConnectionAdapters::RealTransaction < ::ActiveRecord::ConnectionAdapters::Transaction - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#218 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#480 def commit; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#203 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#450 def materialize!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#213 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#460 + def restart; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#474 def rollback; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#153 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#195 class ActiveRecord::ConnectionAdapters::ReferenceDefinition # @return [ReferenceDefinition] a new instance of ReferenceDefinition # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#154 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#196 def initialize(name, polymorphic: T.unsafe(nil), index: T.unsafe(nil), foreign_key: T.unsafe(nil), type: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#174 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#216 + def add(table_name, connection); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#230 def add_to(table); end private - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#191 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#247 def as_options(value); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#225 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#285 def column_name; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#229 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#289 def column_names; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#217 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#277 def columns; end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#251 + def conditional_options; end + # Returns the value of attribute foreign_key. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#245 def foreign_key; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#213 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#273 def foreign_key_options; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#233 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#293 def foreign_table_name; end # Returns the value of attribute index. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#245 def index; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#203 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#263 def index_options(table_name); end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#245 def name; end # Returns the value of attribute options. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#245 def options; end # Returns the value of attribute polymorphic. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#245 def polymorphic; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#199 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#259 def polymorphic_index_name(table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#195 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#255 def polymorphic_options; end # Returns the value of attribute type. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#245 def type; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#171 +# = Active Record Restart Parent \Transaction +# +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#376 +class ActiveRecord::ConnectionAdapters::RestartParentTransaction < ::ActiveRecord::ConnectionAdapters::Transaction + # @return [RestartParentTransaction] a new instance of RestartParentTransaction + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#377 + def initialize(connection, parent_transaction, **options); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#396 + def commit; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#400 + def full_rollback?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#389 + def materialize!(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#389 + def materialized?(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#389 + def restart(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#391 + def rollback; end +end + +# = Active Record Savepoint \Transaction +# +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#404 class ActiveRecord::ConnectionAdapters::SavepointTransaction < ::ActiveRecord::ConnectionAdapters::Transaction # @return [SavepointTransaction] a new instance of SavepointTransaction # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#172 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#405 def initialize(connection, savepoint_name, parent_transaction, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#194 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#439 def commit; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#199 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#445 def full_rollback?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#184 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#417 def materialize!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#189 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#422 + def restart; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#431 def rollback; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#5 +# = Active Record Connection Adapters \Savepoints +# +# source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#6 module ActiveRecord::ConnectionAdapters::Savepoints - # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#10 + # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#11 def create_savepoint(name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#6 + # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#7 def current_savepoint_name; end - # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#14 + # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#15 def exec_rollback_to_savepoint(name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#18 + # source://activerecord//lib/active_record/connection_adapters/abstract/savepoints.rb#19 def release_savepoint(name = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#7 +# = Active Record Connection Adapters Schema Cache +# +# source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#227 class ActiveRecord::ConnectionAdapters::SchemaCache # @return [SchemaCache] a new instance of SchemaCache # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#38 - def initialize(conn); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#255 + def initialize; end # Add internal cache for table with +table_name+. # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#97 - def add(table_name); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#326 + def add(pool, table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#396 + def add_all(pool); end - # Clears out internal caches + # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#149 - def clear!; end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#294 + def cached?(table_name); end # Clear out internal caches for the data source +name+. # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#164 - def clear_data_source_cache!(name); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#388 + def clear_data_source_cache!(_connection, name); end # Get the columns for a table # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#111 - def columns(table_name); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#338 + def columns(pool, table_name); end # Get the columns for a table as a hash, key is the column name # value is the column object. # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#123 - def columns_hash(table_name); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#352 + def columns_hash(pool, table_name); end # Checks whether the columns hash is already cached for a table. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#130 - def columns_hash?(table_name); end - - # Returns the value of attribute connection. - # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#36 - def connection; end - - # Sets the attribute connection - # - # @param value the value to set the attribute connection to. - # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#36 - def connection=(_arg0); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#359 + def columns_hash?(_pool, table_name); end # A cached lookup for table existence. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#88 - def data_source_exists?(name); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#309 + def data_source_exists?(pool, name); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#106 - def data_sources(name); end - - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#144 - def database_version; end - - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#172 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#406 def dump_to(filename); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#57 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#273 def encode_with(coder); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#134 - def indexes(table_name); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#363 + def indexes(pool, table_name); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#68 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#281 def init_with(coder); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#184 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#416 def marshal_dump; end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#190 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#420 def marshal_load(array); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#79 - def primary_keys(table_name); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#298 + def primary_keys(pool, table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#379 + def schema_version; end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#159 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#383 def size; end - # Returns the value of attribute version. - # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#35 - def version; end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#375 + def version(pool); end private - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#222 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#450 def deep_deduplicate(value); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#214 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#442 def derive_columns_hash_and_deduplicate_values; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#204 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#436 def ignored_table?(table_name); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#48 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#264 def initialize_dup(other); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#241 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#463 def open(filename); end - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#235 - def prepare_data_sources; end - - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#210 - def reset_version!; end - - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#198 - def tables_to_cache; end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#428 + def tables_to_cache(pool); end class << self - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#8 - def load_from(filename); end + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#228 + def _load_from(filename); end private - # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#24 + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#244 def read(filename, &block); end end end @@ -13142,16 +14592,16 @@ class ActiveRecord::ConnectionAdapters::SchemaCreation private - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#162 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#176 def action_sql(action, dependency); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#137 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#151 def add_column_options!(sql, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#128 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#142 def add_table_options!(create_sql, o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#133 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#147 def column_options(o); end # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 @@ -13166,7 +14616,7 @@ class ActiveRecord::ConnectionAdapters::SchemaCreation # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 def quote_table_name(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#120 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#134 def quoted_columns(o); end # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 @@ -13176,64 +14626,76 @@ class ActiveRecord::ConnectionAdapters::SchemaCreation def supports_check_constraints?(*_arg0, **_arg1, &_arg2); end # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 - def supports_foreign_keys?(*_arg0, **_arg1, &_arg2); end + def supports_exclusion_constraints?(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 + def supports_index_include?(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#124 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#138 def supports_index_using?; end # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 def supports_indexes_in_create?(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 + def supports_nulls_not_distinct?(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 def supports_partial_index?(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 + def supports_unique_constraints?(*_arg0, **_arg1, &_arg2); end + # Returns any SQL string to go between CREATE and TABLE. May be nil. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#158 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#172 def table_modifier_in_create(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#152 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#166 def to_sql(sql); end # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 def type_to_sql(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#112 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#16 + def use_foreign_keys?(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#126 def visit_AddCheckConstraint(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#38 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#40 def visit_AddColumnDefinition(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#83 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#95 def visit_AddForeignKey(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#22 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#24 def visit_AlterTable(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#108 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#122 def visit_CheckConstraintDefinition(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#31 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#33 def visit_ColumnDefinition(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#91 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#103 def visit_CreateIndexDefinition(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#116 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#130 def visit_DropCheckConstraint(name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#87 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#99 def visit_DropForeignKey(name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#72 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#82 def visit_ForeignKeyDefinition(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#68 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#78 def visit_PrimaryKeyDefinition(o); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#42 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_creation.rb#44 def visit_TableDefinition(o); end end @@ -13293,6 +14755,107 @@ end # source://activerecord//lib/active_record/connection_adapters/abstract/schema_dumper.rb#6 ActiveRecord::ConnectionAdapters::SchemaDumper::DEFAULT_DATETIME_PRECISION = T.let(T.unsafe(nil), Integer) +# source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#7 +class ActiveRecord::ConnectionAdapters::SchemaReflection + # @return [SchemaReflection] a new instance of SchemaReflection + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#16 + def initialize(cache_path, cache = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#41 + def add(pool, name); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#79 + def cached?(table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#21 + def clear!; end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#73 + def clear_data_source_cache!(pool, name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#49 + def columns(pool, table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#53 + def columns_hash(pool, table_name); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#57 + def columns_hash?(pool, table_name); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#37 + def data_source_exists?(pool, name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#45 + def data_sources(pool, name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#91 + def dump_to(pool, filename); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#61 + def indexes(pool, table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#27 + def load!(pool); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#33 + def primary_keys(pool, table_name); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#69 + def size(pool); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#65 + def version(pool); end + + private + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#106 + def cache(pool); end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#100 + def empty_cache; end + + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#116 + def load_cache(pool); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#110 + def possible_cache_available?; end + + class << self + # Returns the value of attribute check_schema_cache_dump_version. + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#10 + def check_schema_cache_dump_version; end + + # Sets the attribute check_schema_cache_dump_version + # + # @param value the value to set the attribute check_schema_cache_dump_version to. + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#10 + def check_schema_cache_dump_version=(_arg0); end + + # Returns the value of attribute use_schema_cache_dump. + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#9 + def use_schema_cache_dump; end + + # Sets the attribute use_schema_cache_dump + # + # @param value the value to set the attribute use_schema_cache_dump to. + # + # source://activerecord//lib/active_record/connection_adapters/schema_cache.rb#9 + def use_schema_cache_dump=(_arg0); end + end +end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#8 module ActiveRecord::ConnectionAdapters::SchemaStatements include ::ActiveRecord::Migration::JoinTable @@ -13300,7 +14863,6 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # Adds a reference. The reference column is a bigint by default, # the :type option can be used to specify a different type. # Optionally adds a +_type+ column, if :polymorphic option is provided. - # #add_reference and #add_belongs_to are acceptable. # # The +options+ hash can include the following keys: # [:type] @@ -13345,7 +14907,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # add_reference(:products, :supplier, foreign_key: { to_table: :firms }) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#989 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1042 def add_belongs_to(table_name, ref_name, **options); end # Adds a new check constraint to the table. +expression+ is a String @@ -13360,11 +14922,13 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # The +options+ hash can include the following keys: # [:name] # The constraint name. Defaults to chk_rails_. + # [:if_not_exists] + # Silently ignore if the constraint already exists, rather than raise an error. # [:validate] # (PostgreSQL only) Specify whether or not the constraint should be validated. Defaults to +true+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1186 - def add_check_constraint(table_name, expression, **options); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1272 + def add_check_constraint(table_name, expression, if_not_exists: T.unsafe(nil), **options); end # Add a new +type+ column named +column_name+ to +table_name+. # @@ -13400,11 +14964,6 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # :datetime, and :time columns. # * :scale - # Specifies the scale for the :decimal and :numeric columns. - # * :collation - - # Specifies the collation for a :string or :text column. If not specified, the - # column will have the same collation as the table. - # * :comment - - # Specifies the comment for the column. This option is ignored by some backends. # * :if_not_exists - # Specifies if the column already exists to not try to re-add it. This will avoid # duplicate column errors. @@ -13420,7 +14979,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # * The SQL standard says the default scale should be 0, :scale <= # :precision, and makes no comments about the requirements of # :precision. - # * MySQL: :precision [1..63], :scale [0..30]. + # * MySQL: :precision [1..65], :scale [0..30]. # Default is (10,0). # * PostgreSQL: :precision [1..infinity], # :scale [0..infinity]. No default. @@ -13461,10 +15020,10 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # Ignores the method call if the column exists # add_column(:shapes, :triangle, 'polygon', if_not_exists: true) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#617 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#625 def add_column(table_name, column_name, type, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#631 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#632 def add_columns(table_name, *column_names, type:, **options); end # Adds a new foreign key. +from_table+ is the table with the key column, @@ -13494,6 +15053,16 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # ALTER TABLE "articles" ADD CONSTRAINT fk_rails_58ca3d3a82 FOREIGN KEY ("author_id") REFERENCES "users" ("lng_id") # + # ====== Creating a composite foreign key + # + # Assuming "carts" table has "(shop_id, user_id)" as a primary key. + # + # add_foreign_key :orders, :carts, primary_key: [:shop_id, :user_id] + # + # generates: + # + # ALTER TABLE "orders" ADD CONSTRAINT fk_rails_6f5e4cb3a4 FOREIGN KEY ("cart_shop_id", "cart_user_id") REFERENCES "carts" ("shop_id", "user_id") + # # ====== Creating a cascading foreign key # # add_foreign_key :articles, :authors, on_delete: :cascade @@ -13504,9 +15073,11 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # The +options+ hash can include the following keys: # [:column] - # The foreign key column name on +from_table+. Defaults to to_table.singularize + "_id" + # The foreign key column name on +from_table+. Defaults to to_table.singularize + "_id". + # Pass an array to create a composite foreign key. # [:primary_key] # The primary key column name on +to_table+. Defaults to +id+. + # Pass an array to create a composite foreign key. # [:name] # The constraint name. Defaults to fk_rails_. # [:on_delete] @@ -13522,7 +15093,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # (PostgreSQL only) Specify whether or not the foreign key should be deferrable. Valid values are booleans or # +:deferred+ or +:immediate+ to specify the default behavior. Defaults to +false+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1086 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1152 def add_foreign_key(from_table, to_table, **options); end # Adds a new index to the table. +column_name+ can be a single Symbol, or @@ -13603,6 +15174,16 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # Note: Partial indexes are only supported for PostgreSQL and SQLite. # + # ====== Creating an index that includes additional columns + # + # add_index(:accounts, :branch_id, include: :party_id) + # + # generates: + # + # CREATE INDEX index_accounts_on_branch_id ON accounts USING btree(branch_id) INCLUDE (party_id) + # + # Note: only supported by PostgreSQL. + # # ====== Creating an index with a specific method # # add_index(:developers, :name, using: 'btree') @@ -13640,24 +15221,26 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # ====== Creating an index with a specific algorithm # # add_index(:developers, :name, algorithm: :concurrently) - # # CREATE INDEX CONCURRENTLY developers_on_name on developers (name) + # # CREATE INDEX CONCURRENTLY developers_on_name on developers (name) -- PostgreSQL # - # Note: only supported by PostgreSQL. + # add_index(:developers, :name, algorithm: :inplace) + # # CREATE INDEX `index_developers_on_name` ON `developers` (`name`) ALGORITHM = INPLACE -- MySQL + # + # Note: only supported by PostgreSQL and MySQL. # # Concurrently adding an index is not supported in a transaction. # # For more information see the {"Transactional Migrations" section}[rdoc-ref:Migration]. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#852 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#894 def add_index(table_name, column_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1340 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1449 def add_index_options(table_name, column_name, name: T.unsafe(nil), if_not_exists: T.unsafe(nil), internal: T.unsafe(nil), **options); end # Adds a reference. The reference column is a bigint by default, # the :type option can be used to specify a different type. # Optionally adds a +_type+ column, if :polymorphic option is provided. - # #add_reference and #add_belongs_to are acceptable. # # The +options+ hash can include the following keys: # [:type] @@ -13702,7 +15285,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # add_reference(:products, :supplier, foreign_key: { to_table: :firms }) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#989 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1042 def add_reference(table_name, ref_name, **options); end # Adds timestamps (+created_at+ and +updated_at+) columns to +table_name+. @@ -13710,12 +15293,62 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # add_timestamps(:suppliers, null: true) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1317 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1432 def add_timestamps(table_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1229 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1337 def assume_migrated_upto_version(version); end + # Builds an AlterTable object for adding a column to a table. + # + # This definition object contains information about the column that would be created + # if the same arguments were passed to #add_column. See #add_column for information about + # passing a +table_name+, +column_name+, +type+ and other options that can be passed. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#643 + def build_add_column_definition(table_name, column_name, type, **options); end + + # Builds a ChangeColumnDefaultDefinition object. + # + # This definition object contains information about the column change that would occur + # if the same arguments were passed to #change_column_default. See #change_column_default for + # information about passing a +table_name+, +column_name+, +type+ and other options that can be passed. + # + # @raise [NotImplementedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#727 + def build_change_column_default_definition(table_name, column_name, default_or_changes); end + + # Builds a CreateIndexDefinition object. + # + # This definition object contains information about the index that would be created + # if the same arguments were passed to #add_index. See #add_index for information about + # passing a +table_name+, +column_name+, and other additional options that can be passed. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#904 + def build_create_index_definition(table_name, column_name, **options); end + + # Builds a TableDefinition object for a join table. + # + # This definition object contains information about the table that would be created + # if the same arguments were passed to #create_join_table. See #create_join_table for + # information about what arguments should be passed. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#399 + def build_create_join_table_definition(table_1, table_2, column_options: T.unsafe(nil), **options); end + + # Returns a TableDefinition object containing information about the table that would be created + # if the same arguments were passed to #create_table. See #create_table for information about + # passing a +table_name+, and other additional options that can be passed. + # + # @yield [table_definition] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#333 + def build_create_table_definition(table_name, id: T.unsafe(nil), primary_key: T.unsafe(nil), force: T.unsafe(nil), **options); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1528 + def bulk_change_table(table_name, operations); end + # Changes the column's definition according to the new options. # See TableDefinition#column for details of the options you can use. # @@ -13724,7 +15357,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#680 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#700 def change_column(table_name, column_name, type, **options); end # Changes the comment for a column or removes it if +nil+. @@ -13736,7 +15369,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1399 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1510 def change_column_comment(table_name, column_name, comment_or_changes); end # Sets a new default value for a column: @@ -13755,7 +15388,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#698 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#718 def change_column_default(table_name, column_name, default_or_changes); end # Sets or removes a NOT NULL constraint on a column. The +null+ flag @@ -13777,7 +15410,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#718 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#747 def change_column_null(table_name, column_name, null, default = T.unsafe(nil)); end # A block for changing columns in +table+. @@ -13859,8 +15492,8 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # See also Table for details on all of the various column transformations. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#488 - def change_table(table_name, **options); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#501 + def change_table(table_name, base = T.unsafe(nil), **options); end # Changes the comment for a table or removes it if +nil+. # @@ -13871,10 +15504,19 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1389 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1500 def change_table_comment(table_name, comment_or_changes); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1196 + # Checks to see if a check constraint exists on a table for a given check constraint definition. + # + # check_constraint_exists?(:products, name: "price_check") + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1321 + def check_constraint_exists?(table_name, **options); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1284 def check_constraint_options(table_name, expression, options); end # Returns an array of check constraints for the given table. @@ -13882,7 +15524,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1168 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1252 def check_constraints(table_name); end # Checks to see if a column exists in a given table. @@ -13904,12 +15546,12 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#139 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#132 def column_exists?(table_name, column_name, type = T.unsafe(nil), **options); end # Returns an array of +Column+ objects for the table specified by +table_name+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#115 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#107 def columns(table_name); end # Given a set of columns and an ORDER BY clause, returns the columns for a SELECT DISTINCT. @@ -13918,7 +15560,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # columns_for_distinct("posts.id", ["posts.created_at desc"]) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1289 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1398 def columns_for_distinct(columns, orders); end # Creates a new join table with the name created using the lexical order of the first two @@ -13959,10 +15601,10 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # part_id bigint NOT NULL, # ) ENGINE=InnoDB DEFAULT CHARSET=utf8 # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#385 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#380 def create_join_table(table_1, table_2, column_options: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1403 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1514 def create_schema_dumper(options); end # Creates a new table with the name +table_name+. +table_name+ may either @@ -14074,7 +15716,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # generates: # - # CREATE TABLE order ( + # CREATE TABLE orders ( # product_id bigint NOT NULL, # client_id bigint NOT NULL # ); @@ -14108,10 +15750,8 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # See also TableDefinition#column for details on how to create columns. # - # @yield [td] - # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#300 - def create_table(table_name, id: T.unsafe(nil), primary_key: T.unsafe(nil), force: T.unsafe(nil), **options); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#293 + def create_table(table_name, id: T.unsafe(nil), primary_key: T.unsafe(nil), force: T.unsafe(nil), **options, &block); end # Checks to see if the data source +name+ exists on the database. # @@ -14128,17 +15768,17 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#34 def data_sources; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1293 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1402 def distinct_relation_for_primary_key(relation); end # Drops the join table specified by the given arguments. - # See #create_join_table for details. + # See #create_join_table and #drop_table for details. # # Although this command ignores the block if one is given, it can be helpful # to provide one in a migration's +change+ method so it can be reverted. # In that case, the block will be used by #create_join_table. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#405 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#418 def drop_join_table(table_1, table_2, **options); end # Drops a table from the database. @@ -14154,14 +15794,14 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # it can be helpful to provide these in a migration's +change+ method so it can be reverted. # In that case, +options+ and the block will be used by #create_table. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#518 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#531 def drop_table(table_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1220 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1328 def dump_schema_information; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1154 - def foreign_key_column_for(table_name); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1220 + def foreign_key_column_for(table_name, column_name); end # Checks to see if a foreign key exists on a table for a given foreign key definition. # @@ -14176,10 +15816,10 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1150 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1216 def foreign_key_exists?(from_table, to_table = T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1159 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1225 def foreign_key_options(from_table, to_table, options); end # Returns an array of foreign keys for the given table. @@ -14187,10 +15827,10 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1028 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1082 def foreign_keys(table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1366 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1477 def index_algorithm(algorithm); end # Checks to see if an index exists on a table for a given index definition. @@ -14207,19 +15847,22 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # Check an index with a custom name exists # index_exists?(:suppliers, :company_id, name: "idx_company_id") # + # # Check a valid index exists (PostgreSQL only) + # index_exists?(:suppliers, :company_id, valid: true) + # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#99 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#102 def index_exists?(table_name, column_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#921 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#971 def index_name(table_name, options); end # Verifies the existence of an index with a given name. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#936 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#990 def index_name_exists?(table_name, index_name); end # Returns an array of indexes for the given table. @@ -14229,9 +15872,14 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#81 def indexes(table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1225 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1333 def internal_string_options_for_primary_key; end + # Returns the maximum length of an index name in bytes. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1566 + def max_index_name_size; end + # Returns a hash of mappings from the abstract data types to the native # database types. See TableDefinition#column for details on the recognized # abstract data types. @@ -14241,19 +15889,18 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1379 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1490 def options_include_default?(options); end # Returns just a table's primary key # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#152 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#145 def primary_key(table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1372 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1483 def quoted_columns_for_index(column_names, options); end # Removes the reference(s). Also removes a +type+ column if one exists. - # #remove_reference and #remove_belongs_to are acceptable. # # ====== Remove the reference # @@ -14267,19 +15914,25 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # remove_reference(:products, :user, foreign_key: true) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1009 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1061 def remove_belongs_to(table_name, ref_name, foreign_key: T.unsafe(nil), polymorphic: T.unsafe(nil), **options); end - # Removes the given check constraint from the table. + # Removes the given check constraint from the table. Removing a check constraint + # that does not exist will raise an error. # # remove_check_constraint :products, name: "price_check" # + # To silently ignore a non-existent check constraint rather than raise an error, + # use the +if_exists+ option. + # + # remove_check_constraint :products, name: "price_check", if_exists: true + # # The +expression+ parameter will be ignored if present. It can be helpful # to provide this in a migration's +change+ method so it can be reverted. # In that case, +expression+ will be used by #add_check_constraint. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1209 - def remove_check_constraint(table_name, expression = T.unsafe(nil), **options); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1303 + def remove_check_constraint(table_name, expression = T.unsafe(nil), if_exists: T.unsafe(nil), **options); end # Removes the column from the table definition. # @@ -14297,7 +15950,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # remove_column(:suppliers, :qualification, if_exists: true) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#668 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#688 def remove_column(table_name, column_name, type = T.unsafe(nil), **options); end # Removes the given columns from the table definition. @@ -14308,7 +15961,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # remove_columns(:suppliers, :qualification, :experience, type: :string, null: false) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#644 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#664 def remove_columns(table_name, *column_names, type: T.unsafe(nil), **options); end # Removes the given foreign key from the table. Any option parameters provided @@ -14342,7 +15995,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # [:to_table] # The name of the table that contains the referenced primary key. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1127 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1193 def remove_foreign_key(from_table, to_table = T.unsafe(nil), **options); end # Removes the given index from the table. @@ -14382,11 +16035,10 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # For more information see the {"Transactional Migrations" section}[rdoc-ref:Migration]. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#895 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#945 def remove_index(table_name, column_name = T.unsafe(nil), **options); end # Removes the reference(s). Also removes a +type+ column if one exists. - # #remove_reference and #remove_belongs_to are acceptable. # # ====== Remove the reference # @@ -14400,14 +16052,14 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # remove_reference(:products, :user, foreign_key: true) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1009 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1061 def remove_reference(table_name, ref_name, foreign_key: T.unsafe(nil), polymorphic: T.unsafe(nil), **options); end # Removes the timestamp columns (+created_at+ and +updated_at+) from the table definition. # # remove_timestamps(:suppliers) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1332 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1441 def remove_timestamps(table_name, **options); end # Renames a column. @@ -14416,7 +16068,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#726 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#755 def rename_column(table_name, column_name, new_column_name); end # Renames an index. @@ -14425,7 +16077,7 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # rename_index :people, 'index_people_on_last_name', 'index_users_on_last_name' # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#909 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#959 def rename_index(table_name, old_name, new_name); end # Renames a table. @@ -14434,8 +16086,14 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#502 - def rename_table(table_name, new_name); end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#515 + def rename_table(table_name, new_name, **_arg2); end + + # Returns an instance of SchemaCreation, which can be used to visit a schema definition + # object and return DDL. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1524 + def schema_creation; end # Truncates a table alias according to the limits of the current adapter. # @@ -14464,12 +16122,26 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#51 def tables; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1249 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1358 def type_to_sql(type, limit: T.unsafe(nil), precision: T.unsafe(nil), scale: T.unsafe(nil), **_arg4); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1336 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1445 def update_table_definition(table_name, base); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1518 + def use_foreign_keys?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1557 + def valid_column_definition_options; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1561 + def valid_primary_key_options; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1553 + def valid_table_definition_options; end + # Checks to see if the view +view_name+ exists on the database. # # view_exists?(:ebooks) @@ -14486,131 +16158,145 @@ module ActiveRecord::ConnectionAdapters::SchemaStatements private - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1637 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1810 def add_column_for_alter(table_name, column_name, type, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1412 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1595 def add_index_sort_order(quoted_columns, **options); end # Overridden by the MySQL adapter for supporting index lengths and by # the PostgreSQL adapter for supporting operator classes. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1429 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1612 def add_options_for_index_columns(quoted_columns, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1655 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1833 def add_timestamps_for_alter(table_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1612 - def bulk_change_table(table_name, operations); end - # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1608 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1802 def can_remove_index_by_name?(column_name, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1582 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1816 + def change_column_default_for_alter(table_name, column_name, default_or_changes); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1770 def check_constraint_for(table_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1588 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1776 def check_constraint_for!(table_name, expression: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1572 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1760 def check_constraint_name(table_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1408 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1591 def column_options_keys; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1499 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1678 def create_alter_table(name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1495 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1674 def create_table_definition(name, **options); end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1685 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1863 def data_source_sql(name = T.unsafe(nil), type: T.unsafe(nil)); end # Try to identify whether the given column name is an expression # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1535 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1718 def expression_column_name?(column_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1564 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1748 def extract_foreign_key_action(specifier); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1599 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1793 def extract_new_comment_value(default_or_changes); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1599 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1793 def extract_new_default_value(default_or_changes); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1503 - def extract_table_options!(options); end - - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1507 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1690 def fetch_type_metadata(sql_type); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1554 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1738 def foreign_key_for(from_table, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1559 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1743 def foreign_key_for!(from_table, to_table: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1545 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1728 def foreign_key_name(table_name, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1518 + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1756 + def foreign_keys_enabled?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1571 + def generate_index_name(table_name, column); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1701 def index_column_names(column_names); end # @raise [ArgumentError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1437 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1620 def index_name_for_remove(table_name, column_name, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1526 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1709 def index_name_options(column_names); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1672 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1850 def insert_versions_sql(versions); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1419 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1602 def options_for_index_columns(options); end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1689 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1867 def quoted_scope(name = T.unsafe(nil), type: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1647 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1806 + def reference_name_for_table(table_name); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1825 def remove_column_for_alter(table_name, column_name, type = T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1651 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1829 def remove_columns_for_alter(table_name, *column_names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1668 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1846 def remove_timestamps_for_alter(table_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1478 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1661 def rename_column_indexes(table_name, column_name, new_column_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1643 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1821 def rename_column_sql(table_name, column_name, new_column_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1469 - def rename_table_indexes(table_name, new_name); end - - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1491 - def schema_creation; end + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1652 + def rename_table_indexes(table_name, new_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1539 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1722 def strip_table_name_prefix_and_suffix(table_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1593 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1585 + def validate_change_column_null_argument!(value); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1682 + def validate_create_table_options!(options); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1781 def validate_index_length!(table_name, new_name, internal = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_statements.rb#1787 + def validate_table_length!(table_name); end end # source://activerecord//lib/active_record/connection_adapters/sql_type_metadata.rb#6 @@ -14663,6 +16349,8 @@ class ActiveRecord::ConnectionAdapters::SqlTypeMetadata def deduplicated; end end +# = Active Record Connection Adapters \Table +# # Represents an SQL table in an abstract way for updating a table. # Also see TableDefinition and {connection.create_table}[rdoc-ref:SchemaStatements#create_table] # @@ -14707,14 +16395,14 @@ end # t.remove_timestamps # end # -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#617 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#706 class ActiveRecord::ConnectionAdapters::Table include ::ActiveRecord::ConnectionAdapters::ColumnMethods extend ::ActiveRecord::ConnectionAdapters::ColumnMethods::ClassMethods # @return [Table] a new instance of Table # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#622 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#711 def initialize(table_name, base); end # Adds a reference. @@ -14724,19 +16412,19 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.add_reference}[rdoc-ref:SchemaStatements#add_reference] for details of the options you can use. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#767 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#862 def belongs_to(*args, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def bigint(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def binary(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def blob(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def boolean(*names, **options); end # Changes the column's definition according to the new options. @@ -14746,7 +16434,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See TableDefinition#column for details of the options you can use. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#696 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#788 def change(column_name, type, **options); end # Sets a new default value for a column. @@ -14757,7 +16445,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.change_column_default}[rdoc-ref:SchemaStatements#change_column_default] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#707 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#800 def change_default(column_name, default_or_changes); end # Sets or removes a NOT NULL constraint on a column. @@ -14767,7 +16455,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.change_column_null}[rdoc-ref:SchemaStatements#change_column_null] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#717 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#810 def change_null(column_name, null, default = T.unsafe(nil)); end # Adds a check constraint. @@ -14776,16 +16464,29 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.add_check_constraint}[rdoc-ref:SchemaStatements#add_check_constraint] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#821 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#920 def check_constraint(*args, **options); end + # Checks if a check_constraint exists on a table. + # + # unless t.check_constraint_exists?(name: "price_check") + # t.check_constraint("price > 0", name: "price_check") + # end + # + # See {connection.check_constraint_exists?}[rdoc-ref:SchemaStatements#check_constraint_exists?] + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#940 + def check_constraint_exists?(*args, **options); end + # Adds a new column to the named table. # # t.column(:name, :string) # # See TableDefinition#column for details of the options you can use. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#632 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#721 def column(column_name, type, index: T.unsafe(nil), **options); end # Checks to see if a column exists. @@ -14796,19 +16497,19 @@ class ActiveRecord::ConnectionAdapters::Table # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#645 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#735 def column_exists?(column_name, type = T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def date(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def datetime(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def decimal(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def float(*names, **options); end # Adds a foreign key to the table using a supplied table name. @@ -14818,7 +16519,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.add_foreign_key}[rdoc-ref:SchemaStatements#add_foreign_key] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#793 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#890 def foreign_key(*args, **options); end # Checks to see if a foreign key exists. @@ -14829,7 +16530,7 @@ class ActiveRecord::ConnectionAdapters::Table # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#812 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#911 def foreign_key_exists?(*args, **options); end # Adds a new index to the table. +column_name+ can be a single Symbol, or @@ -14841,7 +16542,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.add_index}[rdoc-ref:SchemaStatements#add_index] for details of the options you can use. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#657 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#747 def index(column_name, **options); end # Checks to see if an index exists. @@ -14854,21 +16555,21 @@ class ActiveRecord::ConnectionAdapters::Table # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#668 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#759 def index_exists?(column_name, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def integer(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def json(*names, **options); end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#620 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#709 def name; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def numeric(*names, **options); end # Adds a reference. @@ -14878,7 +16579,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.add_reference}[rdoc-ref:SchemaStatements#add_reference] for details of the options you can use. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#767 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#862 def references(*args, **options); end # Removes the column(s) from the table definition. @@ -14888,7 +16589,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.remove_columns}[rdoc-ref:SchemaStatements#remove_columns] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#727 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#820 def remove(*column_names, **options); end # Removes a reference. Optionally removes a +type+ column. @@ -14898,7 +16599,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.remove_reference}[rdoc-ref:SchemaStatements#remove_reference] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#780 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#876 def remove_belongs_to(*args, **options); end # Removes the given check constraint from the table. @@ -14907,7 +16608,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.remove_check_constraint}[rdoc-ref:SchemaStatements#remove_check_constraint] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#830 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#929 def remove_check_constraint(*args, **options); end # Removes the given foreign key from the table. @@ -14917,7 +16618,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.remove_foreign_key}[rdoc-ref:SchemaStatements#remove_foreign_key] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#803 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#901 def remove_foreign_key(*args, **options); end # Removes the given index from the table. @@ -14929,7 +16630,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.remove_index}[rdoc-ref:SchemaStatements#remove_index] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#739 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#833 def remove_index(column_name = T.unsafe(nil), **options); end # Removes a reference. Optionally removes a +type+ column. @@ -14939,7 +16640,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.remove_reference}[rdoc-ref:SchemaStatements#remove_reference] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#780 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#876 def remove_references(*args, **options); end # Removes the timestamp columns (+created_at+ and +updated_at+) from the table. @@ -14948,7 +16649,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.remove_timestamps}[rdoc-ref:SchemaStatements#remove_timestamps] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#748 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#843 def remove_timestamps(**options); end # Renames a column. @@ -14957,7 +16658,7 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.rename_column}[rdoc-ref:SchemaStatements#rename_column] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#757 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#852 def rename(column_name, new_column_name); end # Renames the given index on the table. @@ -14966,19 +16667,19 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.rename_index}[rdoc-ref:SchemaStatements#rename_index] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#677 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#768 def rename_index(index_name, new_index_name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def string(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def text(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def time(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def timestamp(*names, **options); end # Adds timestamps (+created_at+ and +updated_at+) columns to the table. @@ -14987,20 +16688,27 @@ class ActiveRecord::ConnectionAdapters::Table # # See {connection.add_timestamps}[rdoc-ref:SchemaStatements#add_timestamps] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#686 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#777 def timestamps(**options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def virtual(*names, **options); end + + private + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#945 + def raise_on_if_exist_options(options); end end +# = Active Record Connection Adapters \Table \Definition +# # Represents the schema of an SQL table in an abstract way. This class # provides methods for manipulating the schema representation. # # Inside migration files, the +t+ object in {create_table}[rdoc-ref:SchemaStatements#create_table] # is actually of this type: # -# class SomeMigration < ActiveRecord::Migration[7.0] +# class SomeMigration < ActiveRecord::Migration[7.2] # def up # create_table :foo do |t| # puts t.class # => "ActiveRecord::ConnectionAdapters::TableDefinition" @@ -15012,24 +16720,24 @@ end # end # end # -# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#301 +# source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#363 class ActiveRecord::ConnectionAdapters::TableDefinition include ::ActiveRecord::ConnectionAdapters::ColumnMethods extend ::ActiveRecord::ConnectionAdapters::ColumnMethods::ClassMethods # @return [TableDefinition] a new instance of TableDefinition # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#306 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#368 def initialize(conn, name, temporary: T.unsafe(nil), if_not_exists: T.unsafe(nil), options: T.unsafe(nil), as: T.unsafe(nil), comment: T.unsafe(nil), **_arg7); end # Returns a ColumnDefinition for the column with name +name+. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#339 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#418 def [](name); end # Returns the value of attribute as. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def as; end # Adds a reference. @@ -15040,27 +16748,27 @@ class ActiveRecord::ConnectionAdapters::TableDefinition # # See {connection.add_reference}[rdoc-ref:SchemaStatements#add_reference] for details of the options you can use. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#469 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#548 def belongs_to(*args, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def bigint(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def binary(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def blob(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def boolean(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#443 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#522 def check_constraint(expression, **options); end # Returns the value of attribute check_constraints. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def check_constraints; end # Instantiates a new column for the table. @@ -15131,42 +16839,42 @@ class ActiveRecord::ConnectionAdapters::TableDefinition # t.references :taggable, polymorphic: { default: 'Photo' }, index: false # end # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#410 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#489 def column(name, type, index: T.unsafe(nil), **options); end # Returns an array of ColumnDefinition objects for the columns of the table. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#336 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#415 def columns; end # Returns the value of attribute comment. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def comment; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def date(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def datetime(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def decimal(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def float(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#439 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#518 def foreign_key(to_table, **options); end # Returns the value of attribute foreign_keys. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def foreign_keys; end # Returns the value of attribute if_not_exists. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def if_not_exists; end # Adds index options to the indexes hash, keyed by column name @@ -15174,43 +16882,43 @@ class ActiveRecord::ConnectionAdapters::TableDefinition # # index(:account_id, name: 'index_projects_on_account_id') # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#435 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#514 def index(column_name, **options); end # Returns the value of attribute indexes. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def indexes; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def integer(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def json(*names, **options); end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def name; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#501 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#580 def new_check_constraint_definition(expression, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#476 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#555 def new_column_definition(name, type, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#493 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#572 def new_foreign_key_definition(to_table, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def numeric(*names, **options); end # Returns the value of attribute options. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def options; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#330 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#409 def primary_keys(name = T.unsafe(nil)); end # Adds a reference. @@ -15221,30 +16929,33 @@ class ActiveRecord::ConnectionAdapters::TableDefinition # # See {connection.add_reference}[rdoc-ref:SchemaStatements#add_reference] for details of the options you can use. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#469 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#548 def references(*args, **options); end # remove the column +name+ from the table. # remove_column(:account_id) # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#427 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#506 def remove_column(name); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#392 + def set_primary_key(table_name, id, primary_key, **options); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def string(*names, **options); end # Returns the value of attribute temporary. # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#304 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#366 def temporary; end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def text(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def time(*names, **options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def timestamp(*names, **options); end # Appends :datetime columns :created_at and @@ -15252,258 +16963,375 @@ class ActiveRecord::ConnectionAdapters::TableDefinition # # t.timestamps null: false # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#451 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#530 def timestamps(**options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#272 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#332 def virtual(*names, **options); end private - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#511 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#598 def aliased_types(name, fallback); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#507 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#590 def create_column_definition(name, type, options); end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#515 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#602 def integer_like_primary_key?(type, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#519 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#606 def integer_like_primary_key_type(type, options); end - # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#523 + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#610 def raise_on_duplicate_column(name); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/schema_definitions.rb#586 + def valid_column_definition_options; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#85 +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#128 class ActiveRecord::ConnectionAdapters::Transaction # @return [Transaction] a new instance of Transaction # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#89 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#153 def initialize(connection, isolation: T.unsafe(nil), joinable: T.unsafe(nil), run_commit_callbacks: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#100 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#185 def add_record(record, ensure_finalize = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#142 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#203 + def after_commit(&block); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#211 + def after_rollback(&block); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#195 + def before_commit(&block); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#274 def before_commit_records; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#167 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#181 def closed?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#146 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#298 def commit_records; end # Returns the value of attribute connection. # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#86 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#148 def connection; end + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#169 + def dirty!; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#173 + def dirty?; end + # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#165 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#327 def full_rollback?; end + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#233 + def incomplete!; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#151 + def invalidate!(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#151 + def invalidated?(*_arg0, **_arg1, &_arg2); end + # Returns the value of attribute isolation_level. # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#86 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#148 def isolation_level; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#166 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#328 def joinable?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#118 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#237 def materialize!; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#122 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#242 def materialized?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#168 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#177 def open?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#110 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#219 def records; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#126 + # Can this transaction's current state be recreated by + # rollback+begin ? + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#229 + def restartable?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#246 + def restore!; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#254 def rollback_records; end # Returns the value of attribute savepoint_name. # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#86 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#148 def savepoint_name; end # Returns the value of attribute state. # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#86 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#148 def state; end + # Returns the value of attribute user_transaction. + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#148 + def user_transaction; end + # Returns the value of attribute written. # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#87 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#149 def written; end # Sets the attribute written # # @param value the value to set the attribute written to. # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#87 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#149 def written=(_arg0); end + + protected + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#331 + def append_callbacks(callbacks); end + + private + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#348 + def prepare_instances_to_run_callbacks_on(records); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#340 + def run_action_on_records(records, instances_to_run_callbacks_on); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#336 + def unique_records; end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#129 +class ActiveRecord::ConnectionAdapters::Transaction::Callback + # @return [Callback] a new instance of Callback + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#130 + def initialize(event, callback); end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#139 + def after_commit; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#143 + def after_rollback; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#135 + def before_commit; end end -# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#224 +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#79 +class ActiveRecord::ConnectionAdapters::TransactionInstrumenter + # @return [TransactionInstrumenter] a new instance of TransactionInstrumenter + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#80 + def initialize(payload = T.unsafe(nil)); end + + # @raise [InstrumentationNotStartedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#101 + def finish(outcome); end + + # @raise [InstrumentationAlreadyStartedError] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#90 + def start; end +end + +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#88 +class ActiveRecord::ConnectionAdapters::TransactionInstrumenter::InstrumentationAlreadyStartedError < ::ActiveRecord::ActiveRecordError; end + +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#87 +class ActiveRecord::ConnectionAdapters::TransactionInstrumenter::InstrumentationNotStartedError < ::ActiveRecord::ActiveRecordError; end + +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#487 class ActiveRecord::ConnectionAdapters::TransactionManager # @return [TransactionManager] a new instance of TransactionManager # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#225 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#488 def initialize(connection); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#233 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#496 def begin_transaction(isolation: T.unsafe(nil), joinable: T.unsafe(nil), _lazy: T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#293 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#583 def commit_transaction; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#359 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#651 def current_transaction; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#265 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#551 + def dirty_current_transaction; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#538 def disable_lazy_transactions!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#270 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#543 def enable_lazy_transactions!; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#274 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#547 def lazy_transactions_enabled?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#278 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#567 def materialize_transactions; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#355 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#647 def open_transactions; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#308 + # @return [Boolean] + # + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#563 + def restorable?; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#555 + def restore_transactions; end + + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#600 def rollback_transaction(transaction = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#316 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#612 def within_new_transaction(isolation: T.unsafe(nil), joinable: T.unsafe(nil)); end private # Deallocate invalidated prepared statements outside of the transaction # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#367 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#659 def after_failure_actions(transaction, error); end end -# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#364 +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#656 ActiveRecord::ConnectionAdapters::TransactionManager::NULL_TRANSACTION = T.let(T.unsafe(nil), ActiveRecord::ConnectionAdapters::NullTransaction) -# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#5 +# = Active Record Connection Adapters Transaction State +# +# source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#8 class ActiveRecord::ConnectionAdapters::TransactionState # @return [TransactionState] a new instance of TransactionState # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#6 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#9 def initialize(state = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#11 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#14 def add_child(state); end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#63 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#66 def commit!; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#20 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#23 def committed?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#44 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#47 def completed?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#16 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#19 def finalized?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#67 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#70 def full_commit!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#53 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#56 def full_rollback!; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#24 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#27 def fully_committed?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#40 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#43 def fully_completed?; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#32 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#35 def fully_rolledback?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#58 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#61 def invalidate!; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#36 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#39 def invalidated?; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#71 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#74 def nullify!; end - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#48 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#51 def rollback!; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#28 + # source://activerecord//lib/active_record/connection_adapters/abstract/transaction.rb#31 def rolledback?; end end -# source://activerecord//lib/active_record/connection_handling.rb#4 -module ActiveRecord::ConnectionHandling - # source://activerecord//lib/active_record/connection_handling.rb#337 - def clear_active_connections!(*_arg0, **_arg1, &_arg2); end +# ConnectionFailed will be raised when the network connection to the +# database fails while sending a query or waiting for its result. +# +# source://activerecord//lib/active_record/errors.rb#574 +class ActiveRecord::ConnectionFailed < ::ActiveRecord::QueryAborted; end - # source://activerecord//lib/active_record/connection_handling.rb#337 - def clear_all_connections!(*_arg0, **_arg1, &_arg2); end +# = Active Record Connection Handling +# +# source://activerecord//lib/active_record/connection_handling.rb#5 +module ActiveRecord::ConnectionHandling + # source://activerecord//lib/active_record/connection_handling.rb#324 + def adapter_class; end - # source://activerecord//lib/active_record/connection_handling.rb#333 + # source://activerecord//lib/active_record/connection_handling.rb#358 def clear_cache!; end # Clears the query cache for all connections associated with the current thread. # - # source://activerecord//lib/active_record/connection_handling.rb#266 + # source://activerecord//lib/active_record/connection_handling.rb#244 def clear_query_caches_for_current_thread; end - # source://activerecord//lib/active_record/connection_handling.rb#337 - def clear_reloadable_connections!(*_arg0, **_arg1, &_arg2); end - # Returns +true+ if Active Record is connected. # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_handling.rb#317 + # source://activerecord//lib/active_record/connection_handling.rb#337 def connected?; end # Connects to a role (e.g. writing, reading, or a custom role) and/or @@ -15533,19 +17361,27 @@ module ActiveRecord::ConnectionHandling # Dog.first # finds first Dog record stored on the shard one replica # end # - # source://activerecord//lib/active_record/connection_handling.rb#137 + # source://activerecord//lib/active_record/connection_handling.rb#134 def connected_to(role: T.unsafe(nil), shard: T.unsafe(nil), prevent_writes: T.unsafe(nil), &blk); end - # Returns true if role is the current connected role. + # Returns true if role is the current connected role and/or + # current connected shard. If no shard is passed, the default will be + # used. # # ActiveRecord::Base.connected_to(role: :writing) do # ActiveRecord::Base.connected_to?(role: :writing) #=> true # ActiveRecord::Base.connected_to?(role: :reading) #=> false # end # + # ActiveRecord::Base.connected_to(role: :reading, shard: :shard_one) do + # ActiveRecord::Base.connected_to?(role: :reading, shard: :shard_one) #=> true + # ActiveRecord::Base.connected_to?(role: :reading, shard: :default) #=> false + # ActiveRecord::Base.connected_to?(role: :writing, shard: :shard_one) #=> true + # end + # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_handling.rb#252 + # source://activerecord//lib/active_record/connection_handling.rb#239 def connected_to?(role:, shard: T.unsafe(nil)); end # Connects a role and/or shard to the provided connection names. Optionally +prevent_writes+ @@ -15562,7 +17398,7 @@ module ActiveRecord::ConnectionHandling # Person.first # Read from primary writer # end # - # source://activerecord//lib/active_record/connection_handling.rb#172 + # source://activerecord//lib/active_record/connection_handling.rb#163 def connected_to_many(*classes, role:, shard: T.unsafe(nil), prevent_writes: T.unsafe(nil)); end # Use a specified connection. @@ -15573,48 +17409,45 @@ module ActiveRecord::ConnectionHandling # It is not recommended to use this method in a request since it # does not yield to a block like +connected_to+. # - # source://activerecord//lib/active_record/connection_handling.rb#198 + # source://activerecord//lib/active_record/connection_handling.rb#185 def connecting_to(role: T.unsafe(nil), shard: T.unsafe(nil), prevent_writes: T.unsafe(nil)); end - # Returns the connection currently associated with the class. This can - # also be used to "borrow" the connection to do database work unrelated - # to any of the specific Active Records. + # Soft deprecated. Use +#with_connection+ or +#lease_connection+ instead. # - # source://activerecord//lib/active_record/connection_handling.rb#279 + # source://activerecord//lib/active_record/connection_handling.rb#260 def connection; end # Returns the db_config object from the associated connection: # # ActiveRecord::Base.connection_db_config # # + # @name="primary", @config={pool: 5, timeout: 5000, database: "storage/development.sqlite3", adapter: "sqlite3"}> # # Use only for reading. # - # source://activerecord//lib/active_record/connection_handling.rb#304 + # source://activerecord//lib/active_record/connection_handling.rb#320 def connection_db_config; end - # source://activerecord//lib/active_record/connection_handling.rb#308 + # source://activerecord//lib/active_record/connection_handling.rb#328 def connection_pool; end - # Return the connection specification name from the current class or its parent. + # Returns the connection specification name from the current class or its parent. # - # source://activerecord//lib/active_record/connection_handling.rb#286 + # source://activerecord//lib/active_record/connection_handling.rb#302 def connection_specification_name; end # Sets the attribute connection_specification_name # # @param value the value to set the attribute connection_specification_name to. # - # source://activerecord//lib/active_record/connection_handling.rb#283 + # source://activerecord//lib/active_record/connection_handling.rb#299 def connection_specification_name=(_arg0); end # Connects a model to the databases specified. The +database+ keyword # takes a hash consisting of a +role+ and a +database_key+. # - # This will create a connection handler for switching between connections, - # look up the config hash using the +database_key+ and finally - # establishes a connection to that config. + # This will look up the database config using the +database_key+ and + # establish a connection to that config. # # class AnimalsModel < ApplicationRecord # self.abstract_class = true @@ -15623,7 +17456,7 @@ module ActiveRecord::ConnectionHandling # end # # +connects_to+ also supports horizontal sharding. The horizontal sharding API - # also supports read replicas. Connect a model to a list of shards like this: + # supports read replicas as well. You can connect a model to a list of shards like this: # # class AnimalsModel < ApplicationRecord # self.abstract_class = true @@ -15674,7 +17507,7 @@ module ActiveRecord::ConnectionHandling # ) # # In case {ActiveRecord::Base.configurations}[rdoc-ref:Core.configurations] - # is set (Rails automatically loads the contents of config/database.yml into it), + # is set (\Rails automatically loads the contents of config/database.yml into it), # a symbol can also be given as argument, representing a key in the # configuration hash: # @@ -15683,18 +17516,21 @@ module ActiveRecord::ConnectionHandling # The exceptions AdapterNotSpecified, AdapterNotFound, and +ArgumentError+ # may be returned on an error. # - # source://activerecord//lib/active_record/connection_handling.rb#49 + # source://activerecord//lib/active_record/connection_handling.rb#50 def establish_connection(config_or_env = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_handling.rb#337 - def flush_idle_connections!(*_arg0, **_arg1, &_arg2); end - - # source://activerecord//lib/active_record/connection_handling.rb#256 - def lookup_connection_handler(handler_key); end + # Returns the connection currently associated with the class. This can + # also be used to "borrow" the connection to do database work unrelated + # to any of the specific Active Records. + # The connection will remain leased for the entire duration of the request + # or job, or until +#release_connection+ is called. + # + # source://activerecord//lib/active_record/connection_handling.rb#255 + def lease_connection; end # @return [Boolean] # - # source://activerecord//lib/active_record/connection_handling.rb#293 + # source://activerecord//lib/active_record/connection_handling.rb#309 def primary_class?; end # Prohibit swapping shards while inside of the passed block. @@ -15704,20 +17540,28 @@ module ActiveRecord::ConnectionHandling # is useful in cases you're using sharding to provide per-request # database isolation. # - # source://activerecord//lib/active_record/connection_handling.rb#214 + # source://activerecord//lib/active_record/connection_handling.rb#197 def prohibit_shard_swapping(enabled = T.unsafe(nil)); end - # source://activerecord//lib/active_record/connection_handling.rb#321 - def remove_connection(name = T.unsafe(nil)); end + # Return the currently leased connection into the pool + # + # source://activerecord//lib/active_record/connection_handling.rb#284 + def release_connection; end + + # source://activerecord//lib/active_record/connection_handling.rb#341 + def remove_connection; end - # source://activerecord//lib/active_record/connection_handling.rb#312 + # source://activerecord//lib/active_record/connection_handling.rb#332 def retrieve_connection; end + # source://activerecord//lib/active_record/connection_handling.rb#354 + def schema_cache; end + # Determine whether or not shard swapping is currently prohibited # # @return [Boolean] # - # source://activerecord//lib/active_record/connection_handling.rb#223 + # source://activerecord//lib/active_record/connection_handling.rb#206 def shard_swapping_prohibited?; end # Prevent writing to the database regardless of role. @@ -15732,52 +17576,65 @@ module ActiveRecord::ConnectionHandling # See +READ_QUERY+ for the queries that are blocked by this # method. # - # source://activerecord//lib/active_record/connection_handling.rb#238 + # source://activerecord//lib/active_record/connection_handling.rb#221 def while_preventing_writes(enabled = T.unsafe(nil), &block); end + # Checkouts a connection from the pool, yield it and then check it back in. + # If a connection was already leased via #lease_connection or a parent call to + # #with_connection, that same connection is yieled. + # If #lease_connection is called inside the block, the connection won't be checked + # back in. + # If #connection is called inside the block, the connection won't be checked back in + # unless the +prevent_permanent_checkout+ argument is set to +true+. + # + # source://activerecord//lib/active_record/connection_handling.rb#295 + def with_connection(prevent_permanent_checkout: T.unsafe(nil), &block); end + private - # source://activerecord//lib/active_record/connection_handling.rb#382 + # source://activerecord//lib/active_record/connection_handling.rb#383 def append_to_connected_to_stack(entry); end - # source://activerecord//lib/active_record/connection_handling.rb#341 - def clear_on_handler(handler); end - - # source://activerecord//lib/active_record/connection_handling.rb#347 + # source://activerecord//lib/active_record/connection_handling.rb#363 def resolve_config_for_connection(config_or_env); end - # source://activerecord//lib/active_record/connection_handling.rb#390 - def swap_connection_handler(handler, &blk); end - - # source://activerecord//lib/active_record/connection_handling.rb#357 - def with_handler(handler_key, &blk); end - - # source://activerecord//lib/active_record/connection_handling.rb#362 + # source://activerecord//lib/active_record/connection_handling.rb#372 def with_role_and_shard(role, shard, prevent_writes); end end -# source://activerecord//lib/active_record/connection_handling.rb#6 +# source://activerecord//lib/active_record/connection_handling.rb#7 ActiveRecord::ConnectionHandling::DEFAULT_ENV = T.let(T.unsafe(nil), Proc) -# source://activerecord//lib/active_record/connection_handling.rb#5 +# source://activerecord//lib/active_record/connection_handling.rb#6 ActiveRecord::ConnectionHandling::RAILS_ENV = T.let(T.unsafe(nil), Proc) # Raised when connection to the database could not been established (for example when -# {ActiveRecord::Base.connection=}[rdoc-ref:ConnectionHandling#connection] +# {ActiveRecord::Base.lease_connection=}[rdoc-ref:ConnectionHandling#lease_connection] # is given a +nil+ object). # -# source://activerecord//lib/active_record/errors.rb#57 -class ActiveRecord::ConnectionNotEstablished < ::ActiveRecord::ActiveRecordError; end +# source://activerecord//lib/active_record/errors.rb#67 +class ActiveRecord::ConnectionNotEstablished < ::ActiveRecord::AdapterError + # @return [ConnectionNotEstablished] a new instance of ConnectionNotEstablished + # + # source://activerecord//lib/active_record/errors.rb#68 + def initialize(message = T.unsafe(nil), connection_pool: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/errors.rb#72 + def set_pool(connection_pool); end +end # Raised when a connection could not be obtained within the connection # acquisition timeout period: because max connections in pool # are in use. # -# source://activerecord//lib/active_record/errors.rb#63 +# source://activerecord//lib/active_record/errors.rb#84 class ActiveRecord::ConnectionTimeoutError < ::ActiveRecord::ConnectionNotEstablished; end +# = Active Record \Core +# # source://activerecord//lib/active_record/core.rb#10 module ActiveRecord::Core + include ::ActiveModel::Access extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -15789,19 +17646,19 @@ module ActiveRecord::Core # In both instances, valid attribute keys are determined by the column names of the associated table -- # hence you can't have attributes that aren't part of the table columns. # - # ==== Example: + # ==== Example # # Instantiates a single new object # User.new(first_name: 'Jamie') # # @yield [_self] # @yieldparam _self [ActiveRecord::Core] the object that the method was called on # - # source://activerecord//lib/active_record/core.rb#461 + # source://activerecord//lib/active_record/core.rb#451 def initialize(attributes = T.unsafe(nil)); end # Allows sort on objects # - # source://activerecord//lib/active_record/core.rb#614 + # source://activerecord//lib/active_record/core.rb#638 def <=>(other_object); end # Returns true if +comparison_object+ is the same exact object, or +comparison_object+ @@ -15814,15 +17671,15 @@ module ActiveRecord::Core # Note also that destroying a record preserves its ID in the model instance, so deleted # models are still comparable. # - # source://activerecord//lib/active_record/core.rb#580 + # source://activerecord//lib/active_record/core.rb#604 def ==(comparison_object); end # @return [Boolean] # - # source://activerecord//lib/active_record/core.rb#626 + # source://activerecord//lib/active_record/core.rb#650 def blank?; end - # source://activerecord//lib/active_record/core.rb#682 + # source://activerecord//lib/active_record/core.rb#723 def connection_handler; end # Populate +coder+ with attributes about this record that should be @@ -15838,7 +17695,7 @@ module ActiveRecord::Core # Post.new.encode_with(coder) # coder # => {"attributes" => {"id" => nil, ... }} # - # source://activerecord//lib/active_record/core.rb#565 + # source://activerecord//lib/active_record/core.rb#560 def encode_with(coder); end # Returns true if +comparison_object+ is the same exact object, or +comparison_object+ @@ -15851,27 +17708,32 @@ module ActiveRecord::Core # Note also that destroying a record preserves its ID in the model instance, so deleted # models are still comparable. # - # source://activerecord//lib/active_record/core.rb#580 + # source://activerecord//lib/active_record/core.rb#604 def eql?(comparison_object); end # Clone and freeze the attributes hash such that associations are still # accessible, even on destroyed records, but cloned models will not be # frozen. # - # source://activerecord//lib/active_record/core.rb#603 + # source://activerecord//lib/active_record/core.rb#627 def freeze; end # Returns +true+ if the attributes hash has been frozen. # # @return [Boolean] # - # source://activerecord//lib/active_record/core.rb#609 + # source://activerecord//lib/active_record/core.rb#633 def frozen?; end + # Returns the full contents of the record as a nicely formatted string. + # + # source://activerecord//lib/active_record/core.rb#733 + def full_inspect; end + # Delegates to id in order to allow two records of the same type and id to work with something like: # [ Person.find(1), Person.find(2), Person.find(3) ] & [ Person.find(1), Person.find(4) ] # => [ Person.find(1) ] # - # source://activerecord//lib/active_record/core.rb#590 + # source://activerecord//lib/active_record/core.rb#614 def hash; end # Initialize an empty model object from +coder+. +coder+ should be @@ -15889,7 +17751,7 @@ module ActiveRecord::Core # post.init_with(coder) # post.title # => 'hello world' # - # source://activerecord//lib/active_record/core.rb#488 + # source://activerecord//lib/active_record/core.rb#478 def init_with(coder, &block); end # Initialize an empty model object from +attributes+. @@ -15899,108 +17761,123 @@ module ActiveRecord::Core # @yield [_self] # @yieldparam _self [ActiveRecord::Core] the object that the method was called on # - # source://activerecord//lib/active_record/core.rb#498 + # source://activerecord//lib/active_record/core.rb#488 def init_with_attributes(attributes, new_record = T.unsafe(nil)); end - # Returns the contents of the record as a nicely formatted string. + # Returns the attributes specified by .attributes_for_inspect as a nicely formatted string. # - # source://activerecord//lib/active_record/core.rb#687 + # source://activerecord//lib/active_record/core.rb#728 def inspect; end # @return [Boolean] # - # source://activerecord//lib/active_record/core.rb#622 + # source://activerecord//lib/active_record/core.rb#646 def present?; end # Takes a PP and prettily prints this record to it, allowing you to get a nice result from pp record # when pp is required. # - # source://activerecord//lib/active_record/core.rb#705 + # source://activerecord//lib/active_record/core.rb#739 def pretty_print(pp); end # Marks this record as read only. # - # source://activerecord//lib/active_record/core.rb#678 + # customer = Customer.first + # customer.readonly! + # customer.save # Raises an ActiveRecord::ReadOnlyRecord + # + # source://activerecord//lib/active_record/core.rb#719 def readonly!; end # Returns +true+ if the record is read only. # # @return [Boolean] # - # source://activerecord//lib/active_record/core.rb#631 + # source://activerecord//lib/active_record/core.rb#655 def readonly?; end - # Returns a hash of the given methods with their names as keys and returned values as values. - # - # source://activerecord//lib/active_record/core.rb#729 - def slice(*methods); end - # Sets the record to strict_loading mode. This will raise an error # if the record tries to lazily load an association. # # user = User.first # user.strict_loading! # => true - # user.comments + # user.address.city + # => ActiveRecord::StrictLoadingViolationError + # user.comments.to_a # => ActiveRecord::StrictLoadingViolationError # - # === Parameters: + # ==== Parameters # - # * value - Boolean specifying whether to enable or disable strict loading. - # * mode - Symbol specifying strict loading mode. Defaults to :all. Using - # :n_plus_one_only mode will only raise an error if an association - # that will lead to an n plus one query is lazily loaded. + # * +value+ - Boolean specifying whether to enable or disable strict loading. + # * :mode - Symbol specifying strict loading mode. Defaults to :all. Using + # :n_plus_one_only mode will only raise an error if an association that + # will lead to an n plus one query is lazily loaded. # - # === Example: + # ==== Examples # # user = User.first # user.strict_loading!(false) # => false - # user.comments - # => # + # user.address.city # => "Tatooine" + # user.comments.to_a # => [# "Tatooine" + # user.comments.to_a # => [# ActiveRecord::StrictLoadingViolationError + # + # source://activerecord//lib/active_record/core.rb#693 def strict_loading!(value = T.unsafe(nil), mode: T.unsafe(nil)); end # Returns +true+ if the record is in strict_loading mode. # # @return [Boolean] # - # source://activerecord//lib/active_record/core.rb#636 + # source://activerecord//lib/active_record/core.rb#660 def strict_loading?; end + # Returns +true+ if the record uses strict_loading with +:all+ mode enabled. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/core.rb#710 + def strict_loading_all?; end + # Returns the value of attribute strict_loading_mode. # - # source://activerecord//lib/active_record/core.rb#670 + # source://activerecord//lib/active_record/core.rb#702 def strict_loading_mode; end # Returns +true+ if the record uses strict_loading with +:n_plus_one_only+ mode enabled. # # @return [Boolean] # - # source://activerecord//lib/active_record/core.rb#673 + # source://activerecord//lib/active_record/core.rb#705 def strict_loading_n_plus_one_only?; end - # Returns an array of the values returned by the given methods. - # - # source://activerecord//lib/active_record/core.rb#734 - def values_at(*methods); end - private + # source://activerecord//lib/active_record/core.rb#825 + def attributes_for_inspect; end + # @return [Boolean] # - # source://activerecord//lib/active_record/core.rb#771 + # source://activerecord//lib/active_record/core.rb#795 def custom_inspect_method_defined?; end - # source://activerecord//lib/active_record/core.rb#751 + # source://activerecord//lib/active_record/core.rb#775 def init_internals; end - # source://activerecord//lib/active_record/core.rb#539 + # source://activerecord//lib/active_record/core.rb#530 def initialize_dup(other); end - # source://activerecord//lib/active_record/core.rb#768 + # source://activerecord//lib/active_record/core.rb#792 def initialize_internals_callback; end - # source://activerecord//lib/active_record/core.rb#782 + # source://activerecord//lib/active_record/core.rb#810 + def inspect_with_attributes(attributes_to_list); end + + # source://activerecord//lib/active_record/core.rb#806 def inspection_filter; end # +Array#flatten+ will call +#to_ary+ (recursively) on each of the elements of @@ -16012,10 +17889,16 @@ module ActiveRecord::Core # # See also https://tenderlovemaking.com/2011/06/28/til-its-ok-to-return-nil-from-to_ary.html # - # source://activerecord//lib/active_record/core.rb#747 + # source://activerecord//lib/active_record/core.rb#771 def to_ary; end module GeneratedClassMethods + def _destroy_association_async_job; end + def _destroy_association_async_job=(value); end + def _destroy_association_async_job?; end + def attributes_for_inspect; end + def attributes_for_inspect=(value); end + def attributes_for_inspect?; end def belongs_to_required_by_default; end def belongs_to_required_by_default=(value); end def belongs_to_required_by_default?; end @@ -16028,8 +17911,8 @@ module ActiveRecord::Core def default_shard; end def default_shard=(value); end def default_shard?; end - def destroy_association_async_job; end - def destroy_association_async_job=(value); end + def destroy_association_async_batch_size; end + def destroy_association_async_batch_size=(value); end def enumerate_columns_in_select_statements; end def enumerate_columns_in_select_statements=(value); end def enumerate_columns_in_select_statements?; end @@ -16039,6 +17922,9 @@ module ActiveRecord::Core def logger; end def logger=(value); end def logger?; end + def run_commit_callbacks_on_first_saved_instances_in_transaction; end + def run_commit_callbacks_on_first_saved_instances_in_transaction=(value); end + def run_commit_callbacks_on_first_saved_instances_in_transaction?; end def shard_selector; end def shard_selector=(value); end def shard_selector?; end @@ -16054,186 +17940,82 @@ module ActiveRecord::Core def default_role?; end def default_shard; end def default_shard?; end - def destroy_association_async_job; end + def destroy_association_async_batch_size; end def logger; end def logger?; end end end -# source://activerecord//lib/active_record/core.rb#250 +# source://activerecord//lib/active_record/core.rb#241 module ActiveRecord::Core::ClassMethods - # Override the default class equality method to provide support for decorated models. + # Returns an instance of +Arel::Table+ loaded with the current table name. # - # source://activerecord//lib/active_record/core.rb#415 - def ===(object); end - - # source://activerecord//lib/active_record/core.rb#340 - def action_on_strict_loading_violation; end - - # source://activerecord//lib/active_record/core.rb#348 - def action_on_strict_loading_violation=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def application_record_class; end - - # source://activerecord//lib/active_record/core.rb#348 - def application_record_class=(value); end - - # Returns an instance of Arel::Table loaded with the current table name. - # - # source://activerecord//lib/active_record/core.rb#420 + # source://activerecord//lib/active_record/core.rb#367 def arel_table; end - # source://activerecord//lib/active_record/core.rb#432 - def cached_find_by_statement(key, &block); end - - # source://activerecord//lib/active_record/core.rb#340 - def default_timezone; end - - # source://activerecord//lib/active_record/core.rb#348 - def default_timezone=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def dump_schema_after_migration; end - - # source://activerecord//lib/active_record/core.rb#348 - def dump_schema_after_migration=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def dump_schemas; end - - # source://activerecord//lib/active_record/core.rb#348 - def dump_schemas=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def error_on_ignored_order; end - - # source://activerecord//lib/active_record/core.rb#348 - def error_on_ignored_order=(value); end + # source://activerecord//lib/active_record/core.rb#379 + def cached_find_by_statement(connection, key, &block); end # Returns columns which shouldn't be exposed while calling +#inspect+. # - # source://activerecord//lib/active_record/core.rb#373 + # source://activerecord//lib/active_record/core.rb#325 def filter_attributes; end # Specifies columns which shouldn't be exposed while calling +#inspect+. # - # source://activerecord//lib/active_record/core.rb#382 + # source://activerecord//lib/active_record/core.rb#334 def filter_attributes=(filter_attributes); end - # source://activerecord//lib/active_record/core.rb#268 + # source://activerecord//lib/active_record/core.rb#246 def find(*ids); end - # source://activerecord//lib/active_record/core.rb#287 + # source://activerecord//lib/active_record/core.rb#259 def find_by(*args); end - # source://activerecord//lib/active_record/core.rb#329 + # source://activerecord//lib/active_record/core.rb#306 def find_by!(*args); end - # source://activerecord//lib/active_record/core.rb#362 + # source://activerecord//lib/active_record/core.rb#314 def generated_association_methods; end - # source://activerecord//lib/active_record/core.rb#340 - def index_nested_attribute_errors; end - - # source://activerecord//lib/active_record/core.rb#348 - def index_nested_attribute_errors=(value); end - - # source://activerecord//lib/active_record/core.rb#255 - def inherited(child_class); end - - # source://activerecord//lib/active_record/core.rb#251 + # source://activerecord//lib/active_record/core.rb#242 def initialize_find_by_cache; end - # source://activerecord//lib/active_record/core.rb#358 + # source://activerecord//lib/active_record/core.rb#310 def initialize_generated_modules; end # Returns a string like 'Post(id:integer, title:string, body:text)' # - # source://activerecord//lib/active_record/core.rb#399 + # source://activerecord//lib/active_record/core.rb#351 def inspect; end - # source://activerecord//lib/active_record/core.rb#387 + # source://activerecord//lib/active_record/core.rb#339 def inspection_filter; end - # source://activerecord//lib/active_record/core.rb#340 - def legacy_connection_handling; end - - # source://activerecord//lib/active_record/core.rb#348 - def legacy_connection_handling=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def maintain_test_schema; end - - # source://activerecord//lib/active_record/core.rb#348 - def maintain_test_schema=(value); end - - # source://activerecord//lib/active_record/core.rb#424 + # source://activerecord//lib/active_record/core.rb#371 def predicate_builder; end - # source://activerecord//lib/active_record/core.rb#340 - def queues; end - - # source://activerecord//lib/active_record/core.rb#348 - def queues=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def reading_role; end - - # source://activerecord//lib/active_record/core.rb#348 - def reading_role=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def schema_format; end - - # source://activerecord//lib/active_record/core.rb#348 - def schema_format=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def suppress_multiple_database_warning; end - - # source://activerecord//lib/active_record/core.rb#348 - def suppress_multiple_database_warning=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def timestamped_migrations; end - - # source://activerecord//lib/active_record/core.rb#348 - def timestamped_migrations=(value); end - - # source://activerecord//lib/active_record/core.rb#428 + # source://activerecord//lib/active_record/core.rb#375 def type_caster; end - # source://activerecord//lib/active_record/core.rb#340 - def verbose_query_logs; end - - # source://activerecord//lib/active_record/core.rb#348 - def verbose_query_logs=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def warn_on_records_fetched_greater_than; end - - # source://activerecord//lib/active_record/core.rb#348 - def warn_on_records_fetched_greater_than=(value); end - - # source://activerecord//lib/active_record/core.rb#340 - def writing_role; end + private - # source://activerecord//lib/active_record/core.rb#348 - def writing_role=(value); end + # source://activerecord//lib/active_record/core.rb#421 + def cached_find_by(keys, values); end - private + # source://activerecord//lib/active_record/core.rb#385 + def inherited(subclass); end - # source://activerecord//lib/active_record/core.rb#438 + # source://activerecord//lib/active_record/core.rb#407 def relation; end - # source://activerecord//lib/active_record/core.rb#448 + # source://activerecord//lib/active_record/core.rb#417 def table_metadata; end end -# source://activerecord//lib/active_record/core.rb#775 +# source://activerecord//lib/active_record/core.rb#799 class ActiveRecord::Core::InspectionMask - # source://activerecord//lib/active_record/core.rb#776 + # source://activerecord//lib/active_record/core.rb#800 def pretty_print(pp); end end @@ -16242,23 +18024,46 @@ end # source://activerecord//lib/active_record/counter_cache.rb#5 module ActiveRecord::CounterCache extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveRecord::CounterCache::ClassMethods private - # source://activerecord//lib/active_record/counter_cache.rb#165 + # source://activerecord//lib/active_record/counter_cache.rb#200 def _create_record(attribute_names = T.unsafe(nil)); end - # source://activerecord//lib/active_record/counter_cache.rb#175 + # @return [Boolean] + # + # source://activerecord//lib/active_record/counter_cache.rb#226 + def _foreign_keys_equal?(fkey1, fkey2); end + + # source://activerecord//lib/active_record/counter_cache.rb#210 def destroy_row; end - # source://activerecord//lib/active_record/counter_cache.rb#190 - def each_counter_cached_associations; end + module GeneratedClassMethods + def _counter_cache_columns; end + def _counter_cache_columns=(value); end + def _counter_cache_columns?; end + def counter_cached_association_names; end + def counter_cached_association_names=(value); end + def counter_cached_association_names?; end + end + + module GeneratedInstanceMethods + def counter_cached_association_names; end + def counter_cached_association_names?; end + end end -# source://activerecord//lib/active_record/counter_cache.rb#8 +# source://activerecord//lib/active_record/counter_cache.rb#13 module ActiveRecord::CounterCache::ClassMethods + # @return [Boolean] + # + # source://activerecord//lib/active_record/counter_cache.rb#182 + def counter_cache_column?(name); end + # Decrement a numeric field by one, via a direct SQL update. # # This works the same as #increment_counter but reduces the column value by @@ -16268,6 +18073,7 @@ module ActiveRecord::CounterCache::ClassMethods # # * +counter_name+ - The name of the field that should be decremented. # * +id+ - The id of the object that should be decremented or an array of ids. + # * :by - The amount by which to decrement the value. Defaults to +1+. # * :touch - Touch timestamp columns when updating. # Pass +true+ to touch +updated_at+ and/or +updated_on+. Pass a symbol to # touch that column or an array of symbols to touch just those ones. @@ -16278,11 +18084,15 @@ module ActiveRecord::CounterCache::ClassMethods # DiscussionBoard.decrement_counter(:posts_count, 5) # # # Decrement the posts_count column for the record with an id of 5 + # by a specific amount. + # DiscussionBoard.decrement_counter(:posts_count, 5, by: 3) + # + # # Decrement the posts_count column for the record with an id of 5 # # and update the updated_at value. # DiscussionBoard.decrement_counter(:posts_count, 5, touch: true) # - # source://activerecord//lib/active_record/counter_cache.rb#159 - def decrement_counter(counter_name, id, touch: T.unsafe(nil)); end + # source://activerecord//lib/active_record/counter_cache.rb#178 + def decrement_counter(counter_name, id, by: T.unsafe(nil), touch: T.unsafe(nil)); end # Increment a numeric field by one, via a direct SQL update. # @@ -16295,6 +18105,7 @@ module ActiveRecord::CounterCache::ClassMethods # # * +counter_name+ - The name of the field that should be incremented. # * +id+ - The id of the object that should be incremented or an array of ids. + # * :by - The amount by which to increment the value. Defaults to +1+. # * :touch - Touch timestamp columns when updating. # Pass +true+ to touch +updated_at+ and/or +updated_on+. Pass a symbol to # touch that column or an array of symbols to touch just those ones. @@ -16305,11 +18116,18 @@ module ActiveRecord::CounterCache::ClassMethods # DiscussionBoard.increment_counter(:posts_count, 5) # # # Increment the posts_count column for the record with an id of 5 + # # by a specific amount. + # DiscussionBoard.increment_counter(:posts_count, 5, by: 3) + # + # # Increment the posts_count column for the record with an id of 5 # # and update the updated_at value. # DiscussionBoard.increment_counter(:posts_count, 5, touch: true) # - # source://activerecord//lib/active_record/counter_cache.rb#134 - def increment_counter(counter_name, id, touch: T.unsafe(nil)); end + # source://activerecord//lib/active_record/counter_cache.rb#148 + def increment_counter(counter_name, id, by: T.unsafe(nil), touch: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/counter_cache.rb#186 + def load_schema!; end # Resets one or more counter caches to their correct value using an SQL # count query. This is useful when adding new counter caches, or if the @@ -16332,7 +18150,7 @@ module ActiveRecord::CounterCache::ClassMethods # # attributes. # Post.reset_counters(1, :comments, touch: true) # - # source://activerecord//lib/active_record/counter_cache.rb#29 + # source://activerecord//lib/active_record/counter_cache.rb#34 def reset_counters(id, *counters, touch: T.unsafe(nil)); end # A generic "counter updater" implementation, intended primarily to be @@ -16352,74 +18170,82 @@ module ActiveRecord::CounterCache::ClassMethods # # ==== Examples # - # # For the Post with id of 5, decrement the comment_count by 1, and - # # increment the action_count by 1 - # Post.update_counters 5, comment_count: -1, action_count: 1 + # # For the Post with id of 5, decrement the comments_count by 1, and + # # increment the actions_count by 1 + # Post.update_counters 5, comments_count: -1, actions_count: 1 # # Executes the following SQL: # # UPDATE posts - # # SET comment_count = COALESCE(comment_count, 0) - 1, - # # action_count = COALESCE(action_count, 0) + 1 + # # SET comments_count = COALESCE(comments_count, 0) - 1, + # # actions_count = COALESCE(actions_count, 0) + 1 # # WHERE id = 5 # - # # For the Posts with id of 10 and 15, increment the comment_count by 1 - # Post.update_counters [10, 15], comment_count: 1 + # # For the Posts with id of 10 and 15, increment the comments_count by 1 + # Post.update_counters [10, 15], comments_count: 1 # # Executes the following SQL: # # UPDATE posts - # # SET comment_count = COALESCE(comment_count, 0) + 1 + # # SET comments_count = COALESCE(comments_count, 0) + 1 # # WHERE id IN (10, 15) # - # # For the Posts with id of 10 and 15, increment the comment_count by 1 + # # For the Posts with id of 10 and 15, increment the comments_count by 1 # # and update the updated_at value for each counter. - # Post.update_counters [10, 15], comment_count: 1, touch: true + # Post.update_counters [10, 15], comments_count: 1, touch: true # # Executes the following SQL: # # UPDATE posts - # # SET comment_count = COALESCE(comment_count, 0) + 1, + # # SET comments_count = COALESCE(comments_count, 0) + 1, # # `updated_at` = '2016-10-13T09:59:23-05:00' # # WHERE id IN (10, 15) # - # source://activerecord//lib/active_record/counter_cache.rb#107 + # source://activerecord//lib/active_record/counter_cache.rb#115 def update_counters(id, counters); end end # Raised when attribute has a name reserved by Active Record (when attribute # has name of one of Active Record instance methods). # -# source://activerecord//lib/active_record/errors.rb#343 +# source://activerecord//lib/active_record/errors.rb#427 class ActiveRecord::DangerousAttributeError < ::ActiveRecord::ActiveRecordError; end # Raised when creating a database if it exists. # -# source://activerecord//lib/active_record/errors.rb#266 +# source://activerecord//lib/active_record/errors.rb#344 class ActiveRecord::DatabaseAlreadyExists < ::ActiveRecord::StatementInvalid; end -# ActiveRecord::DatabaseConfigurations returns an array of DatabaseConfig -# objects (either a HashConfig or UrlConfig) that are constructed from the -# application's database configuration hash or URL string. +# = Active Record Database Configurations +# +# +ActiveRecord::DatabaseConfigurations+ returns an array of +DatabaseConfig+ +# objects that are constructed from the application's database +# configuration hash or URL string. +# +# The array of +DatabaseConfig+ objects in an application default to either a +# HashConfig or UrlConfig. You can retrieve your application's config by using +# ActiveRecord::Base.configurations. +# +# If you register a custom handler, objects will be created according to the +# conditions of the handler. See ::register_db_config_handler for more on +# registering custom handlers. # # source://activerecord//lib/active_record/database_configurations/database_config.rb#4 class ActiveRecord::DatabaseConfigurations # @return [DatabaseConfigurations] a new instance of DatabaseConfigurations # - # source://activerecord//lib/active_record/database_configurations.rb#19 + # source://activerecord//lib/active_record/database_configurations.rb#73 def initialize(configurations = T.unsafe(nil)); end - # source://activerecord//lib/active_record/database_configurations.rb#17 + # source://activerecord//lib/active_record/database_configurations.rb#27 def any?(*_arg0, **_arg1, &_arg2); end # Checks if the application's configurations are empty. # - # Aliased to blank? - # # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations.rb#98 + # source://activerecord//lib/active_record/database_configurations.rb#150 def blank?; end # Collects the configs for the environment and optionally the specification # name passed in. To include replica configurations pass include_hidden: true. # - # If a name is provided a single DatabaseConfig object will be - # returned, otherwise an array of DatabaseConfig objects will be + # If a name is provided a single +DatabaseConfig+ object will be + # returned, otherwise an array of +DatabaseConfig+ objects will be # returned that corresponds with the environment and type requested. # # ==== Options @@ -16429,38 +18255,35 @@ class ActiveRecord::DatabaseConfigurations # * name: The db config name (i.e. primary, animals, etc.). Defaults # to +nil+. If no +env_name+ is specified the config for the default env and the # passed +name+ will be returned. - # * include_replicas: Deprecated. Determines whether to include replicas in - # the returned list. Most of the time we're only iterating over the write - # connection (i.e. migrations don't need to run for the write and read connection). - # Defaults to +false+. + # * config_key: Selects configs that contain a particular key in the configuration + # hash. Useful for selecting configs that use a custom db config handler or finding + # configs with hashes that contain a particular key. # * include_hidden: Determines whether to include replicas and configurations - # hidden by +database_tasks: false+ in the returned list. Most of the time we're only + # hidden by database_tasks: false in the returned list. Most of the time we're only # iterating over the primary connections (i.e. migrations don't need to run for the # write and read connection). Defaults to +false+. # - # source://activerecord//lib/active_record/database_configurations.rb#45 - def configs_for(env_name: T.unsafe(nil), name: T.unsafe(nil), include_replicas: T.unsafe(nil), include_hidden: T.unsafe(nil)); end + # source://activerecord//lib/active_record/database_configurations.rb#98 + def configs_for(env_name: T.unsafe(nil), name: T.unsafe(nil), config_key: T.unsafe(nil), include_hidden: T.unsafe(nil)); end # Returns the value of attribute configurations. # - # source://activerecord//lib/active_record/database_configurations.rb#16 + # source://activerecord//lib/active_record/database_configurations.rb#26 def configurations; end # Checks if the application's configurations are empty. # - # Aliased to blank? - # # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations.rb#98 + # source://activerecord//lib/active_record/database_configurations.rb#150 def empty?; end - # Returns a single DatabaseConfig object based on the requested environment. + # Returns a single +DatabaseConfig+ object based on the requested environment. # # If the application has multiple databases +find_db_config+ will return - # the first DatabaseConfig for the environment. + # the first +DatabaseConfig+ for the environment. # - # source://activerecord//lib/active_record/database_configurations.rb#73 + # source://activerecord//lib/active_record/database_configurations.rb#127 def find_db_config(env); end # A primary configuration is one that is named primary or if there is @@ -16472,7 +18295,7 @@ class ActiveRecord::DatabaseConfigurations # # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations.rb#88 + # source://activerecord//lib/active_record/database_configurations.rb#142 def primary?(name); end # Returns fully resolved connection, accepts hash, string or symbol. @@ -16495,46 +18318,87 @@ class ActiveRecord::DatabaseConfigurations # DatabaseConfigurations.new({}).resolve("postgresql://localhost/foo") # # => DatabaseConfigurations::UrlConfig.new(config: {"adapter" => "postgresql", "host" => "localhost", "database" => "foo"}) # - # source://activerecord//lib/active_record/database_configurations.rb#122 + # source://activerecord//lib/active_record/database_configurations.rb#174 def resolve(config); end private - # source://activerecord//lib/active_record/database_configurations.rb#148 + # source://activerecord//lib/active_record/database_configurations.rb#200 def build_configs(configs); end - # source://activerecord//lib/active_record/database_configurations.rb#187 + # source://activerecord//lib/active_record/database_configurations.rb#239 def build_configuration_sentence; end - # source://activerecord//lib/active_record/database_configurations.rb#221 + # source://activerecord//lib/active_record/database_configurations.rb#273 def build_db_config_from_hash(env_name, name, config); end - # source://activerecord//lib/active_record/database_configurations.rb#200 + # source://activerecord//lib/active_record/database_configurations.rb#252 def build_db_config_from_raw_config(env_name, name, config); end - # source://activerecord//lib/active_record/database_configurations.rb#211 + # source://activerecord//lib/active_record/database_configurations.rb#263 def build_db_config_from_string(env_name, name, config); end - # source://activerecord//lib/active_record/database_configurations.rb#136 + # source://activerecord//lib/active_record/database_configurations.rb#188 def default_env; end - # source://activerecord//lib/active_record/database_configurations.rb#140 + # source://activerecord//lib/active_record/database_configurations.rb#192 def env_with_configs(env = T.unsafe(nil)); end - # source://activerecord//lib/active_record/database_configurations.rb#242 + # source://activerecord//lib/active_record/database_configurations.rb#295 def environment_url_config(env, name, config); end - # source://activerecord//lib/active_record/database_configurations.rb#249 + # source://activerecord//lib/active_record/database_configurations.rb#302 def environment_value_for(name); end - # source://activerecord//lib/active_record/database_configurations.rb#233 + # source://activerecord//lib/active_record/database_configurations.rb#286 def merge_db_environment_variables(current_env, configs); end - # source://activerecord//lib/active_record/database_configurations.rb#173 + # source://activerecord//lib/active_record/database_configurations.rb#225 def resolve_symbol_connection(name); end - # source://activerecord//lib/active_record/database_configurations.rb#167 + # source://activerecord//lib/active_record/database_configurations.rb#219 def walk_configs(env_name, config); end + + class << self + # source://activerecord//lib/active_record/database_configurations.rb#29 + def db_config_handlers; end + + # source://activerecord//lib/active_record/database_configurations.rb#29 + def db_config_handlers=(_arg0); end + + # Allows an application to register a custom handler for database configuration + # objects. This is useful for creating a custom handler that responds to + # methods your application needs but Active Record doesn't implement. For + # example if you are using Vitess, you may want your Vitess configurations + # to respond to `sharded?`. To implement this define the following in an + # initializer: + # + # ActiveRecord::DatabaseConfigurations.register_db_config_handler do |env_name, name, url, config| + # next unless config.key?(:vitess) + # VitessConfig.new(env_name, name, config) + # end + # + # Note: applications must handle the condition in which custom config should be + # created in your handler registration otherwise all objects will use the custom + # handler. + # + # Then define your +VitessConfig+ to respond to the methods your application + # needs. It is recommended that you inherit from one of the existing + # database config classes to avoid having to reimplement all methods. Custom + # config handlers should only implement methods Active Record does not. + # + # class VitessConfig < ActiveRecord::DatabaseConfigurations::UrlConfig + # def sharded? + # configuration_hash.fetch("sharded", false) + # end + # end + # + # For configs that have a +:vitess+ key, a +VitessConfig+ object will be + # created instead of a +UrlConfig+. + # + # source://activerecord//lib/active_record/database_configurations.rb#61 + def register_db_config_handler(&block); end + end end # Expands a connection string into a hash. @@ -16563,14 +18427,14 @@ class ActiveRecord::DatabaseConfigurations::ConnectionUrlResolver # Converts the given URL to a full connection hash. # - # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#39 + # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#38 def to_hash; end private # Returns name of the database. # - # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#84 + # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#89 def database_from_path; end # Converts the query parameters of the URI into a hash. @@ -16583,53 +18447,56 @@ class ActiveRecord::DatabaseConfigurations::ConnectionUrlResolver # "localhost" # # => {} # - # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#61 + # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#60 def query_hash; end - # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#65 + # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#64 def raw_config; end + # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#82 + def resolved_adapter; end + # Returns the value of attribute uri. # - # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#46 + # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#45 def uri; end - # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#48 + # source://activerecord//lib/active_record/database_configurations/connection_url_resolver.rb#47 def uri_parser; end end # ActiveRecord::Base.configurations will return either a HashConfig or -# UrlConfig respectively. It will never return a DatabaseConfig object, +# UrlConfig respectively. It will never return a +DatabaseConfig+ object, # as this is the parent class for the types of database configuration objects. # # source://activerecord//lib/active_record/database_configurations/database_config.rb#8 class ActiveRecord::DatabaseConfigurations::DatabaseConfig # @return [DatabaseConfig] a new instance of DatabaseConfig # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#13 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#11 def initialize(env_name, name); end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#30 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#43 def _database=(database); end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#34 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#47 def adapter; end - # source://activerecord//lib/active_record/database_configurations/database_config.rb#18 - def adapter_method; end + # source://activerecord//lib/active_record/database_configurations/database_config.rb#17 + def adapter_class; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#54 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#71 def checkout_timeout; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#26 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#39 def database; end # source://activerecord//lib/active_record/database_configurations/database_config.rb#9 @@ -16637,211 +18504,233 @@ class ActiveRecord::DatabaseConfigurations::DatabaseConfig # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#74 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#91 def for_current_env?; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#22 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#35 def host; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#62 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#79 def idle_timeout; end + # source://activerecord//lib/active_record/database_configurations/database_config.rb#21 + def inspect; end + # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#50 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#63 def max_queue; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#46 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#59 def max_threads; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#70 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#87 def migrations_paths; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#42 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#55 def min_threads; end # source://activerecord//lib/active_record/database_configurations/database_config.rb#9 def name; end - # Returns the value of attribute owner_name. - # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#11 - def owner_name; end + # source://activerecord//lib/active_record/database_configurations/database_config.rb#25 + def new_connection; end - # Sets the attribute owner_name - # - # @param value the value to set the attribute owner_name to. + # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#11 - def owner_name=(_arg0); end + # source://activerecord//lib/active_record/database_configurations/database_config.rb#51 + def pool; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#38 - def pool; end + # source://activerecord//lib/active_record/database_configurations/database_config.rb#67 + def query_cache; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#58 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#75 def reaping_frequency; end # @raise [NotImplementedError] # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#66 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#83 def replica?; end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/database_configurations/database_config.rb#78 + # source://activerecord//lib/active_record/database_configurations/database_config.rb#95 def schema_cache_path; end + + # @raise [NotImplementedError] + # @return [Boolean] + # + # source://activerecord//lib/active_record/database_configurations/database_config.rb#99 + def use_metadata_table?; end + + # source://activerecord//lib/active_record/database_configurations/database_config.rb#29 + def validate!; end end -# A HashConfig object is created for each database configuration entry that -# is created from a hash. +# # Active Record Database Hash Config +# +# A `HashConfig` object is created for each database configuration entry that is +# created from a hash. # # A hash config: # -# { "development" => { "database" => "db_name" } } +# { "development" => { "database" => "db_name" } } # # Becomes: # -# # -# -# ==== Options +# # # -# * :env_name - The Rails environment, i.e. "development". -# * :name - The db config name. In a standard two-tier -# database configuration this will default to "primary". In a multiple -# database three-tier database configuration this corresponds to the name -# used in the second tier, for example "primary_readonly". -# * :config - The config hash. This is the hash that contains the -# database adapter, name, and other important information for database -# connections. +# See ActiveRecord::DatabaseConfigurations for more info. # -# source://activerecord//lib/active_record/database_configurations/hash_config.rb#27 +# source://activerecord//lib/active_record/database_configurations/hash_config.rb#22 class ActiveRecord::DatabaseConfigurations::HashConfig < ::ActiveRecord::DatabaseConfigurations::DatabaseConfig + # Initialize a new `HashConfig` object + # + # #### Parameters + # + # * `env_name` - The Rails environment, i.e. "development". + # * `name` - The db config name. In a standard two-tier database configuration + # this will default to "primary". In a multiple database three-tier database + # configuration this corresponds to the name used in the second tier, for + # example "primary_readonly". + # * `configuration_hash` - The config hash. This is the hash that contains the + # database adapter, name, and other important information for database + # connections. + # # @return [HashConfig] a new instance of HashConfig # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#30 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#38 def initialize(env_name, name, configuration_hash); end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#61 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#68 def _database=(database); end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#96 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#107 def adapter; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#81 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#92 def checkout_timeout; end # Returns the value of attribute configuration_hash. # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#28 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#23 def configuration_hash; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#57 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#64 def database; end # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#139 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#153 def database_tasks?; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#107 - def default_schema_cache_path; end + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#117 + def default_schema_cache_path(db_dir = T.unsafe(nil)); end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#49 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#56 def host; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#91 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#102 def idle_timeout; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#111 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#125 def lazy_schema_cache_path; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#77 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#88 def max_queue; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#73 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#80 def max_threads; end - # The migrations paths for a database configuration. If the - # +migrations_paths+ key is present in the config, +migrations_paths+ - # will return its value. + # The migrations paths for a database configuration. If the `migrations_paths` + # key is present in the config, `migrations_paths` will return its value. # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#45 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#52 def migrations_paths; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#69 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#76 def min_threads; end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#65 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#72 def pool; end # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#115 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#129 def primary?; end - # +reaping_frequency+ is configurable mostly for historical reasons, but it could - # also be useful if someone wants a very low +idle_timeout+. + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#84 + def query_cache; end + + # `reaping_frequency` is configurable mostly for historical reasons, but it + # could also be useful if someone wants a very low `idle_timeout`. # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#87 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#98 def reaping_frequency; end # Determines whether a database configuration is for a replica / readonly - # connection. If the +replica+ key is present in the config, +replica?+ will - # return +true+. + # connection. If the `replica` key is present in the config, `replica?` will + # return `true`. # # @return [Boolean] # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#38 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#46 def replica?; end - # The path to the schema cache dump file for a database. - # If omitted, the filename will be read from ENV or a - # default will be derived. + # The path to the schema cache dump file for a database. If omitted, the + # filename will be read from ENV or a default will be derived. # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#103 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#113 def schema_cache_path; end - # Determines whether to dump the schema/structure files and the - # filename that should be used. + # Determines whether to dump the schema/structure files and the filename that + # should be used. # - # If +configuration_hash[:schema_dump]+ is set to +false+ or +nil+ - # the schema will not be dumped. + # If `configuration_hash[:schema_dump]` is set to `false` or `nil` the schema + # will not be dumped. # - # If the config option is set that will be used. Otherwise Rails - # will generate the filename from the database config name. + # If the config option is set that will be used. Otherwise Rails will generate + # the filename from the database config name. # - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#127 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#141 def schema_dump(format = T.unsafe(nil)); end - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#53 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#60 def socket; end + # @return [Boolean] + # + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#157 + def use_metadata_table?; end + private - # source://activerecord//lib/active_record/database_configurations/hash_config.rb#144 + # source://activerecord//lib/active_record/database_configurations/hash_config.rb#162 def schema_file_type(format); end end -# source://activerecord//lib/active_record/database_configurations.rb#14 +# source://activerecord//lib/active_record/database_configurations.rb#24 class ActiveRecord::DatabaseConfigurations::InvalidConfigurationError < ::StandardError; end -# A UrlConfig object is created for each database configuration +# = Active Record Database Url Config +# +# A +UrlConfig+ object is created for each database configuration # entry that is created from a URL. This can either be a URL string # or a hash with a URL in place of the config hash. # @@ -16856,28 +18745,32 @@ class ActiveRecord::DatabaseConfigurations::InvalidConfigurationError < ::Standa # @config={adapter: "postgresql", database: "foo", host: "localhost"}, # @url="postgres://localhost/foo"> # -# ==== Options -# -# * :env_name - The Rails environment, i.e. "development". -# * :name - The db config name. In a standard two-tier -# database configuration this will default to "primary". In a multiple -# database three-tier database configuration this corresponds to the name -# used in the second tier, for example "primary_readonly". -# * :url - The database URL. -# * :config - The config hash. This is the hash that contains the -# database adapter, name, and other important information for database -# connections. +# See ActiveRecord::DatabaseConfigurations for more info. # -# source://activerecord//lib/active_record/database_configurations/url_config.rb#31 +# source://activerecord//lib/active_record/database_configurations/url_config.rb#24 class ActiveRecord::DatabaseConfigurations::UrlConfig < ::ActiveRecord::DatabaseConfigurations::HashConfig + # Initialize a new +UrlConfig+ object + # + # ==== Options + # + # * :env_name - The \Rails environment, i.e. "development". + # * :name - The db config name. In a standard two-tier + # database configuration this will default to "primary". In a multiple + # database three-tier database configuration this corresponds to the name + # used in the second tier, for example "primary_readonly". + # * :url - The database URL. + # * :config - The config hash. This is the hash that contains the + # database adapter, name, and other important information for database + # connections. + # # @return [UrlConfig] a new instance of UrlConfig # - # source://activerecord//lib/active_record/database_configurations/url_config.rb#34 + # source://activerecord//lib/active_record/database_configurations/url_config.rb#40 def initialize(env_name, name, url, configuration_hash = T.unsafe(nil)); end # Returns the value of attribute url. # - # source://activerecord//lib/active_record/database_configurations/url_config.rb#32 + # source://activerecord//lib/active_record/database_configurations/url_config.rb#25 def url; end private @@ -16885,36 +18778,48 @@ class ActiveRecord::DatabaseConfigurations::UrlConfig < ::ActiveRecord::Database # Return a Hash that can be merged into the main config that represents # the passed in url # - # source://activerecord//lib/active_record/database_configurations/url_config.rb#44 + # source://activerecord//lib/active_record/database_configurations/url_config.rb#69 def build_url_hash; end + + # source://activerecord//lib/active_record/database_configurations/url_config.rb#61 + def to_boolean!(configuration_hash, key); end end # Raised when connection to the database could not been established because it was not # able to connect to the host or when the authorization failed. # -# source://activerecord//lib/active_record/errors.rb#68 +# source://activerecord//lib/active_record/errors.rb#89 class ActiveRecord::DatabaseConnectionError < ::ActiveRecord::ConnectionNotEstablished # @return [DatabaseConnectionError] a new instance of DatabaseConnectionError # - # source://activerecord//lib/active_record/errors.rb#69 + # source://activerecord//lib/active_record/errors.rb#90 def initialize(message = T.unsafe(nil)); end class << self - # source://activerecord//lib/active_record/errors.rb#74 + # source://activerecord//lib/active_record/errors.rb#95 def hostname_error(hostname); end - # source://activerecord//lib/active_record/errors.rb#81 + # source://activerecord//lib/active_record/errors.rb#102 def username_error(username); end end end +# DatabaseVersionError will be raised when the database version is not supported, or when +# the database version cannot be determined. +# +# source://activerecord//lib/active_record/errors.rb#602 +class ActiveRecord::DatabaseVersionError < ::ActiveRecord::ActiveRecordError; end + # Deadlocked will be raised when a transaction is rolled # back by the database when a deadlock is encountered. # -# source://activerecord//lib/active_record/errors.rb#436 +# This is a subclass of TransactionRollbackError, please make sure to check +# its documentation to be aware of its caveats. +# +# source://activerecord//lib/active_record/errors.rb#544 class ActiveRecord::Deadlocked < ::ActiveRecord::TransactionRollbackError; end -# == Delegated types +# = Delegated types # # Class hierarchies can map to relational database tables in many ways. Active Record, for example, offers # purely abstract classes, where the superclass doesn't persist any attributes, and single-table inheritance, @@ -16947,7 +18852,7 @@ class ActiveRecord::Deadlocked < ::ActiveRecord::TransactionRollbackError; end # # Let's look at that entry/message/comment example using delegated types: # -# # Schema: entries[ id, account_id, creator_id, created_at, updated_at, entryable_type, entryable_id ] +# # Schema: entries[ id, account_id, creator_id, entryable_type, entryable_id, created_at, updated_at ] # class Entry < ApplicationRecord # belongs_to :account # belongs_to :creator @@ -16962,12 +18867,12 @@ class ActiveRecord::Deadlocked < ::ActiveRecord::TransactionRollbackError; end # end # end # -# # Schema: messages[ id, subject, body ] +# # Schema: messages[ id, subject, body, created_at, updated_at ] # class Message < ApplicationRecord # include Entryable # end # -# # Schema: comments[ id, content ] +# # Schema: comments[ id, content, created_at, updated_at ] # class Comment < ApplicationRecord # include Entryable # end @@ -17013,17 +18918,37 @@ class ActiveRecord::Deadlocked < ::ActiveRecord::TransactionRollbackError; end # You create a new record that uses delegated typing by creating the delegator and delegatee at the same time, # like so: # -# Entry.create! entryable: Comment.new(content: "Hello!"), creator: Current.user +# Entry.create! entryable: Comment.new(content: "Hello!"), creator: Current.user, account: Current.account # # If you need more complicated composition, or you need to perform dependent validation, you should build a factory # method or class to take care of the complicated needs. This could be as simple as: # # class Entry < ApplicationRecord -# def self.create_with_comment(content, creator: Current.user) -# create! entryable: Comment.new(content: content), creator: creator +# def self.create_with_comment(content, creator: Current.user, account: Current.account) +# create! entryable: Comment.new(content: content), creator: creator, account: account # end # end # +# == Querying across records +# +# A consequence of delegated types is that querying attributes spread across multiple classes becomes slightly more +# tricky, but not impossible. +# +# The simplest method is to join the "superclass" to the "subclass" and apply the query parameters (i.e. #where) +# in appropriate places: +# +# Comment.joins(:entry).where(comments: { content: 'Hello!' }, entry: { creator: Current.user } ) +# +# For convenience, add a scope on the concern. Now all classes that implement the concern will automatically include +# the method: +# +# # app/models/concerns/entryable.rb +# scope :with_entry, ->(attrs) { joins(:entry).where(entry: attrs) } +# +# Now the query can be shortened significantly: +# +# Comment.where(content: 'Hello!').with_entry(creator: Current.user) +# # == Adding further delegation # # The delegated type shouldn't just answer the question of what the underlying class is called. In fact, that's @@ -17049,7 +18974,7 @@ class ActiveRecord::Deadlocked < ::ActiveRecord::TransactionRollbackError; end # # Now you can list a bunch of entries, call Entry#title, and polymorphism will provide you with the answer. # -# == Nested Attributes +# == Nested \Attributes # # Enabling nested attributes on a delegated_type association allows you to # create the entry and message in one go: @@ -17064,7 +18989,7 @@ class ActiveRecord::Deadlocked < ::ActiveRecord::TransactionRollbackError; end # entry.entryable.id # => 2 # entry.entryable.subject # => 'Smiling' # -# source://activerecord//lib/active_record/delegated_type.rb#155 +# source://activerecord//lib/active_record/delegated_type.rb#175 module ActiveRecord::DelegatedType # Defines this as a class that'll delegate its type for the passed +role+ to the class references in +types+. # That'll create a polymorphic +belongs_to+ relationship to that +role+, and it'll add all the delegated @@ -17105,6 +19030,11 @@ module ActiveRecord::DelegatedType # +role+ with an "_id" suffix. So a class that defines a # delegated_type :entryable, types: %w[ Message Comment ] association will use "entryable_id" as # the default :foreign_key. + # [:foreign_type] + # Specify the column used to store the associated object's type. By default this is inferred to be the passed + # +role+ with a "_type" suffix. A class that defines a + # delegated_type :entryable, types: %w[ Message Comment ] association will use "entryable_type" as + # the default :foreign_type. # [:primary_key] # Specify the method that returns the primary key of associated object used for the convenience methods. # By default this is +id+. @@ -17117,122 +19047,142 @@ module ActiveRecord::DelegatedType # Entry#message_uuid # => returns entryable_uuid, when entryable_type == "Message", otherwise nil # Entry#comment_uuid # => returns entryable_uuid, when entryable_type == "Comment", otherwise nil # - # source://activerecord//lib/active_record/delegated_type.rb#206 + # source://activerecord//lib/active_record/delegated_type.rb#231 def delegated_type(role, types:, **options); end private - # source://activerecord//lib/active_record/delegated_type.rb#212 + # source://activerecord//lib/active_record/delegated_type.rb#237 def define_delegated_type_methods(role, types:, options:); end end -# source://activerecord//lib/active_record/relation/delegation.rb#7 +# source://activerecord//lib/active_record/relation/delegation.rb#6 module ActiveRecord::Delegation extend ::ActiveSupport::Concern mixes_in_class_methods ::ActiveRecord::Delegation::ClassMethods - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def &(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def +(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def -(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def [](*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def as_json(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def compact(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#93 + # source://activerecord//lib/active_record/relation/delegation.rb#103 def connection(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def each(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def encode_with(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def in_groups(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def in_groups_of(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def index(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 + def intersect?(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/relation/delegation.rb#98 def join(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#103 + def lease_connection(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/relation/delegation.rb#98 def length(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#93 + # source://activerecord//lib/active_record/relation/delegation.rb#103 def primary_key(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def reverse(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def rindex(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def rotate(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def sample(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def shuffle(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def slice(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def split(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def to_formatted_s(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def to_fs(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def to_sentence(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#98 def to_xml(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation/delegation.rb#88 + # source://activerecord//lib/active_record/relation/delegation.rb#103 + def transaction(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/relation/delegation.rb#103 + def with_connection(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/relation/delegation.rb#98 def |(*_arg0, **_arg1, &_arg2); end private # @return [Boolean] # - # source://activerecord//lib/active_record/relation/delegation.rb#128 + # source://activerecord//lib/active_record/relation/delegation.rb#139 def respond_to_missing?(method, _); end + + class << self + # source://activerecord//lib/active_record/relation/delegation.rb#8 + def delegated_classes; end + + # source://activerecord//lib/active_record/relation/delegation.rb#17 + def uncacheable_methods; end + end end -# source://activerecord//lib/active_record/relation/delegation.rb#116 +# source://activerecord//lib/active_record/relation/delegation.rb#127 module ActiveRecord::Delegation::ClassMethods - # source://activerecord//lib/active_record/relation/delegation.rb#117 + # source://activerecord//lib/active_record/relation/delegation.rb#128 def create(klass, *args, **kwargs); end private - # source://activerecord//lib/active_record/relation/delegation.rb#122 + # source://activerecord//lib/active_record/relation/delegation.rb#133 def relation_class_for(klass); end end -# source://activerecord//lib/active_record/relation/delegation.rb#95 +# source://activerecord//lib/active_record/relation/delegation.rb#105 module ActiveRecord::Delegation::ClassSpecificRelation extend ::ActiveSupport::Concern @@ -17240,98 +19190,86 @@ module ActiveRecord::Delegation::ClassSpecificRelation private - # source://activerecord//lib/active_record/relation/delegation.rb#105 - def method_missing(method, *args, **_arg2, &block); end + # source://activerecord//lib/active_record/relation/delegation.rb#115 + def method_missing(method, *_arg1, **_arg2, &_arg3); end end -# source://activerecord//lib/active_record/relation/delegation.rb#98 +# source://activerecord//lib/active_record/relation/delegation.rb#108 module ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods - # source://activerecord//lib/active_record/relation/delegation.rb#99 + # source://activerecord//lib/active_record/relation/delegation.rb#109 def name; end end -# source://activerecord//lib/active_record/relation/delegation.rb#8 +# source://activerecord//lib/active_record/relation/delegation.rb#24 module ActiveRecord::Delegation::DelegateCache - # source://activerecord//lib/active_record/relation/delegation.rb#38 + # source://activerecord//lib/active_record/relation/delegation.rb#49 def generate_relation_method(method); end - # source://activerecord//lib/active_record/relation/delegation.rb#33 + # source://activerecord//lib/active_record/relation/delegation.rb#44 def inherited(child_class); end - # source://activerecord//lib/active_record/relation/delegation.rb#13 + # source://activerecord//lib/active_record/relation/delegation.rb#29 def initialize_relation_delegate_cache; end - # source://activerecord//lib/active_record/relation/delegation.rb#9 + # source://activerecord//lib/active_record/relation/delegation.rb#25 def relation_delegate_class(klass); end protected - # source://activerecord//lib/active_record/relation/delegation.rb#43 + # source://activerecord//lib/active_record/relation/delegation.rb#54 def include_relation_methods(delegate); end private - # source://activerecord//lib/active_record/relation/delegation.rb#49 + # source://activerecord//lib/active_record/relation/delegation.rb#60 def generated_relation_methods; end end -# source://activerecord//lib/active_record/relation/delegation.rb#57 +# source://activerecord//lib/active_record/relation/delegation.rb#68 class ActiveRecord::Delegation::GeneratedRelationMethods < ::Module - include ::Mutex_m - - # source://activerecord//lib/active_record/relation/delegation.rb#60 + # source://activerecord//lib/active_record/relation/delegation.rb#71 def generate_method(method); end - - # source://mutex_m/0.1.2/mutex_m.rb#93 - def lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#83 - def locked?; end - - # source://mutex_m/0.1.2/mutex_m.rb#78 - def synchronize(&block); end - - # source://mutex_m/0.1.2/mutex_m.rb#88 - def try_lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#98 - def unlock; end end +# source://activerecord//lib/active_record/relation/delegation.rb#69 +ActiveRecord::Delegation::GeneratedRelationMethods::MUTEX = T.let(T.unsafe(nil), Thread::Mutex) + # This error is raised when trying to destroy a parent instance in N:1 or 1:1 associations # (has_many, has_one) when there is at least 1 child associated instance. # ex: if @project.tasks.size > 0, DeleteRestrictionError will be raised when trying to destroy @project # -# source://activerecord//lib/active_record/associations.rb#240 +# source://activerecord//lib/active_record/associations/errors.rb#256 class ActiveRecord::DeleteRestrictionError < ::ActiveRecord::ActiveRecordError # @return [DeleteRestrictionError] a new instance of DeleteRestrictionError # - # source://activerecord//lib/active_record/associations.rb#241 + # source://activerecord//lib/active_record/associations/errors.rb#257 def initialize(name = T.unsafe(nil)); end end # source://activerecord//lib/active_record/destroy_association_async_job.rb#4 class ActiveRecord::DestroyAssociationAsyncError < ::StandardError; end +# = Active Record Destroy Association Async Job +# # Job to destroy the records associated with a destroyed record in background. # -# source://activerecord//lib/active_record/destroy_association_async_job.rb#8 +# source://activerecord//lib/active_record/destroy_association_async_job.rb#10 class ActiveRecord::DestroyAssociationAsyncJob < ::ActiveJob::Base - # source://activerecord//lib/active_record/destroy_association_async_job.rb#13 + # source://activerecord//lib/active_record/destroy_association_async_job.rb#15 def perform(owner_model_name: T.unsafe(nil), owner_id: T.unsafe(nil), association_class: T.unsafe(nil), association_ids: T.unsafe(nil), association_primary_key_column: T.unsafe(nil), ensuring_owner_was_method: T.unsafe(nil)); end private # @return [Boolean] # - # source://activerecord//lib/active_record/destroy_association_async_job.rb#32 + # source://activerecord//lib/active_record/destroy_association_async_job.rb#34 def owner_destroyed?(owner, ensuring_owner_was_method); end class << self - # source://activejob/7.0.5/lib/active_job/queue_name.rb#56 + # source://activejob/7.2.0/lib/active_job/queue_name.rb#55 def queue_name; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end end end @@ -17363,19 +19301,19 @@ class ActiveRecord::DisableJoinsAssociationRelation < ::ActiveRecord::Relation def load; end end -# source://activerecord//lib/active_record/migration.rb#103 +# source://activerecord//lib/active_record/migration.rb#104 class ActiveRecord::DuplicateMigrationNameError < ::ActiveRecord::MigrationError # @return [DuplicateMigrationNameError] a new instance of DuplicateMigrationNameError # - # source://activerecord//lib/active_record/migration.rb#104 + # source://activerecord//lib/active_record/migration.rb#105 def initialize(name = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/migration.rb#93 +# source://activerecord//lib/active_record/migration.rb#94 class ActiveRecord::DuplicateMigrationVersionError < ::ActiveRecord::MigrationError # @return [DuplicateMigrationVersionError] a new instance of DuplicateMigrationVersionError # - # source://activerecord//lib/active_record/migration.rb#94 + # source://activerecord//lib/active_record/migration.rb#95 def initialize(version = T.unsafe(nil)); end end @@ -17384,7 +19322,7 @@ module ActiveRecord::DynamicMatchers private # source://activerecord//lib/active_record/dynamic_matchers.rb#15 - def method_missing(name, *arguments, &block); end + def method_missing(name, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # @@ -17495,11 +19433,11 @@ end # Eager loading polymorphic associations is only possible with # {ActiveRecord::Relation#preload}[rdoc-ref:QueryMethods#preload]. # -# source://activerecord//lib/active_record/associations.rb#227 +# source://activerecord//lib/active_record/associations/errors.rb#243 class ActiveRecord::EagerLoadPolymorphicError < ::ActiveRecord::ActiveRecordError # @return [EagerLoadPolymorphicError] a new instance of EagerLoadPolymorphicError # - # source://activerecord//lib/active_record/associations.rb#228 + # source://activerecord//lib/active_record/associations/errors.rb#244 def initialize(reflection = T.unsafe(nil)); end end @@ -17514,15 +19452,18 @@ module ActiveRecord::Encryption # source://activerecord//lib/active_record/encryption/configurable.rb#10 def config; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#56 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#74 def custom_contexts; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#100 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#116 def custom_contexts=(obj); end # source://activerecord//lib/active_record/encryption/contexts.rb#17 def default_context; end + # source://activerecord//lib/active_record/encryption/contexts.rb#17 + def default_context=(val); end + # source://activerecord//lib/active_record/encryption/configurable.rb#11 def encrypted_attribute_declaration_listeners; end @@ -17533,16 +19474,19 @@ module ActiveRecord::Encryption # source://activerecord//lib/active_record/encryption/configurable.rb#10 def config; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#48 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#49 def custom_contexts; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#92 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#108 def custom_contexts=(obj); end # source://activerecord//lib/active_record/encryption/contexts.rb#17 def default_context; end - # source://activerecord//lib/active_record/encryption.rb#49 + # source://activerecord//lib/active_record/encryption/contexts.rb#17 + def default_context=(val); end + + # source://activerecord//lib/active_record/encryption.rb#50 def eager_load!; end # source://activerecord//lib/active_record/encryption/configurable.rb#11 @@ -17553,6 +19497,49 @@ module ActiveRecord::Encryption end end +# source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#5 +class ActiveRecord::Encryption::AutoFilteredParameters + # @return [AutoFilteredParameters] a new instance of AutoFilteredParameters + # + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#6 + def initialize(app); end + + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#14 + def enable; end + + private + + # Returns the value of attribute app. + # + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#20 + def app; end + + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#36 + def apply_collected_attributes; end + + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#53 + def apply_filter(klass, attribute); end + + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#28 + def attribute_was_declared(klass, attribute); end + + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#48 + def collect_for_later(klass, attribute); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#44 + def collecting?; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#61 + def excluded_from_filter_parameters?(filter_parameter); end + + # source://activerecord//lib/active_record/encryption/auto_filtered_parameters.rb#22 + def install_collecting_hook; end +end + # The algorithm used for encrypting and decrypting +Message+ objects. # # It uses AES-256-GCM. It will generate a random IV for non deterministic encryption (default) @@ -17599,40 +19586,43 @@ end # # See +Encryptor+ # -# source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#15 +# source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#14 class ActiveRecord::Encryption::Cipher::Aes256Gcm # When iv not provided, it will generate a random iv on each encryption operation (default and # recommended operation) # # @return [Aes256Gcm] a new instance of Aes256Gcm # - # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#30 + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#29 def initialize(secret, deterministic: T.unsafe(nil)); end - # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#56 + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#55 def decrypt(encrypted_message); end - # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#35 + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#34 def encrypt(clear_text); end + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#82 + def inspect; end + private - # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#92 + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#95 def generate_deterministic_iv(clear_text); end - # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#84 + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#87 def generate_iv(cipher, clear_text); end class << self - # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#23 + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#22 def iv_length; end - # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#19 + # source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#18 def key_length; end end end -# source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#16 +# source://activerecord//lib/active_record/encryption/cipher/aes256_gcm.rb#15 ActiveRecord::Encryption::Cipher::Aes256Gcm::CIPHER_TYPE = T.let(T.unsafe(nil), String) # source://activerecord//lib/active_record/encryption/cipher.rb#12 @@ -17640,170 +19630,194 @@ ActiveRecord::Encryption::Cipher::DEFAULT_ENCODING = T.let(T.unsafe(nil), Encodi # Container of configuration options # -# source://activerecord//lib/active_record/encryption/config.rb#6 +# source://activerecord//lib/active_record/encryption/config.rb#8 class ActiveRecord::Encryption::Config # @return [Config] a new instance of Config # - # source://activerecord//lib/active_record/encryption/config.rb#11 + # source://activerecord//lib/active_record/encryption/config.rb#13 def initialize; end # Returns the value of attribute add_to_filter_parameters. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def add_to_filter_parameters; end # Sets the attribute add_to_filter_parameters # # @param value the value to set the attribute add_to_filter_parameters to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def add_to_filter_parameters=(_arg0); end # Returns the value of attribute deterministic_key. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#41 def deterministic_key; end # Sets the attribute deterministic_key # # @param value the value to set the attribute deterministic_key to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def deterministic_key=(_arg0); end # Returns the value of attribute encrypt_fixtures. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def encrypt_fixtures; end # Sets the attribute encrypt_fixtures # # @param value the value to set the attribute encrypt_fixtures to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def encrypt_fixtures=(_arg0); end # Returns the value of attribute excluded_from_filter_parameters. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def excluded_from_filter_parameters; end # Sets the attribute excluded_from_filter_parameters # # @param value the value to set the attribute excluded_from_filter_parameters to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def excluded_from_filter_parameters=(_arg0); end # Returns the value of attribute extend_queries. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def extend_queries; end # Sets the attribute extend_queries # # @param value the value to set the attribute extend_queries to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def extend_queries=(_arg0); end # Returns the value of attribute forced_encoding_for_deterministic_encryption. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def forced_encoding_for_deterministic_encryption; end # Sets the attribute forced_encoding_for_deterministic_encryption # # @param value the value to set the attribute forced_encoding_for_deterministic_encryption to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def forced_encoding_for_deterministic_encryption=(_arg0); end + # source://activerecord//lib/active_record/encryption/config.rb#36 + def has_deterministic_key?; end + + # source://activerecord//lib/active_record/encryption/config.rb#36 + def has_key_derivation_salt?; end + + # source://activerecord//lib/active_record/encryption/config.rb#36 + def has_primary_key?; end + + # Returns the value of attribute hash_digest_class. + # + # source://activerecord//lib/active_record/encryption/config.rb#9 + def hash_digest_class; end + + # Sets the attribute hash_digest_class + # + # @param value the value to set the attribute hash_digest_class to. + # + # source://activerecord//lib/active_record/encryption/config.rb#9 + def hash_digest_class=(_arg0); end + # Returns the value of attribute key_derivation_salt. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#41 def key_derivation_salt; end # Sets the attribute key_derivation_salt # # @param value the value to set the attribute key_derivation_salt to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def key_derivation_salt=(_arg0); end # Configure previous encryption schemes. # # config.active_record.encryption.previous = [ { key_provider: MyOldKeyProvider.new } ] # - # source://activerecord//lib/active_record/encryption/config.rb#18 + # source://activerecord//lib/active_record/encryption/config.rb#20 def previous=(previous_schemes_properties); end # Returns the value of attribute previous_schemes. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def previous_schemes; end # Sets the attribute previous_schemes # # @param value the value to set the attribute previous_schemes to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def previous_schemes=(_arg0); end # Returns the value of attribute primary_key. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#41 def primary_key; end # Sets the attribute primary_key # # @param value the value to set the attribute primary_key to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def primary_key=(_arg0); end # Returns the value of attribute store_key_references. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def store_key_references; end # Sets the attribute store_key_references # # @param value the value to set the attribute store_key_references to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def store_key_references=(_arg0); end + # source://activerecord//lib/active_record/encryption/config.rb#26 + def support_sha1_for_non_deterministic_encryption=(value); end + # Returns the value of attribute support_unencrypted_data. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def support_unencrypted_data; end # Sets the attribute support_unencrypted_data # # @param value the value to set the attribute support_unencrypted_data to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def support_unencrypted_data=(_arg0); end # Returns the value of attribute validate_column_size. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def validate_column_size; end # Sets the attribute validate_column_size # # @param value the value to set the attribute validate_column_size to. # - # source://activerecord//lib/active_record/encryption/config.rb#7 + # source://activerecord//lib/active_record/encryption/config.rb#9 def validate_column_size=(_arg0); end private - # source://activerecord//lib/active_record/encryption/config.rb#39 + # source://activerecord//lib/active_record/encryption/config.rb#63 def add_previous_scheme(**properties); end - # source://activerecord//lib/active_record/encryption/config.rb#25 + # source://activerecord//lib/active_record/encryption/config.rb#48 def set_defaults; end end @@ -17822,9 +19836,9 @@ module ActiveRecord::Encryption::Configurable::ClassMethods def cipher(*_arg0, **_arg1, &_arg2); end # source://activerecord//lib/active_record/encryption/configurable.rb#20 - def configure(primary_key:, deterministic_key:, key_derivation_salt:, **properties); end + def configure(primary_key: T.unsafe(nil), deterministic_key: T.unsafe(nil), key_derivation_salt: T.unsafe(nil), **properties); end - # source://activerecord//lib/active_record/encryption/configurable.rb#47 + # source://activerecord//lib/active_record/encryption/configurable.rb#52 def encrypted_attribute_was_declared(klass, name); end # source://activerecord//lib/active_record/encryption/configurable.rb#17 @@ -17833,9 +19847,6 @@ module ActiveRecord::Encryption::Configurable::ClassMethods # source://activerecord//lib/active_record/encryption/configurable.rb#17 def frozen_encryption(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/encryption/configurable.rb#53 - def install_auto_filtered_parameters_hook(application); end - # source://activerecord//lib/active_record/encryption/configurable.rb#17 def key_generator(*_arg0, **_arg1, &_arg2); end @@ -17845,13 +19856,8 @@ module ActiveRecord::Encryption::Configurable::ClassMethods # source://activerecord//lib/active_record/encryption/configurable.rb#17 def message_serializer(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/encryption/configurable.rb#42 + # source://activerecord//lib/active_record/encryption/configurable.rb#47 def on_encrypted_attribute_declared(&block); end - - private - - # source://activerecord//lib/active_record/encryption/configurable.rb#61 - def excluded_from_filter_parameters?(filter_parameter); end end # An encryption context configures the different entities used to perform encryption: @@ -17866,51 +19872,54 @@ end class ActiveRecord::Encryption::Context # @return [Context] a new instance of Context # - # source://activerecord//lib/active_record/encryption/context.rb#19 + # source://activerecord//lib/active_record/encryption/context.rb#17 def initialize; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def cipher; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def cipher=(_arg0); end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def encryptor; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def encryptor=(_arg0); end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def frozen_encryption; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def frozen_encryption=(_arg0); end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def frozen_encryption?; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def key_generator; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def key_generator=(_arg0); end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#24 def key_provider; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def key_provider=(_arg0); end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def message_serializer; end - # source://activerecord//lib/active_record/encryption/context.rb#16 + # source://activerecord//lib/active_record/encryption/context.rb#15 def message_serializer=(_arg0); end private - # source://activerecord//lib/active_record/encryption/context.rb#26 + # source://activerecord//lib/active_record/encryption/context.rb#37 + def build_default_key_provider; end + + # source://activerecord//lib/active_record/encryption/context.rb#29 def set_defaults; end end @@ -17944,6 +19953,9 @@ module ActiveRecord::Encryption::Contexts::ClassMethods # source://activerecord//lib/active_record/encryption/contexts.rb#57 def protecting_encrypted_data(&block); end + # source://activerecord//lib/active_record/encryption/contexts.rb#70 + def reset_default_context; end + # source://activerecord//lib/active_record/encryption/contexts.rb#33 def with_encryption_context(properties); end @@ -17958,7 +19970,12 @@ class ActiveRecord::Encryption::DerivedSecretKeyProvider < ::ActiveRecord::Encry # @return [DerivedSecretKeyProvider] a new instance of DerivedSecretKeyProvider # # source://activerecord//lib/active_record/encryption/derived_secret_key_provider.rb#7 - def initialize(passwords); end + def initialize(passwords, key_generator: T.unsafe(nil)); end + + private + + # source://activerecord//lib/active_record/encryption/derived_secret_key_provider.rb#12 + def derive_key_from(password, using: T.unsafe(nil)); end end # A KeyProvider that derives keys from passwords. @@ -17985,51 +20002,54 @@ module ActiveRecord::Encryption::EncryptableRecord # Returns the ciphertext for +attribute_name+. # - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#146 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#157 def ciphertext_for(attribute_name); end # Decrypts all the encryptable attributes and saves the changes. # - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#156 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#171 def decrypt; end # Encrypts all the encryptable attributes and saves the changes. # - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#151 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#166 def encrypt; end # Returns whether a given attribute is encrypted or not. # # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#141 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#146 def encrypted_attribute?(attribute_name); end private - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#190 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#178 + def _create_record(attribute_names = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#214 def build_decrypt_attribute_assignments; end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#184 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#208 def build_encrypt_attribute_assignments; end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#199 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#223 def cant_modify_encrypted_attributes_when_frozen; end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#169 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#193 def decrypt_attributes; end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#163 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#187 def encrypt_attributes; end # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#180 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#204 def has_encrypted_attributes?; end # @raise [ActiveRecord::Encryption::Errors::Configuration] # - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#176 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#200 def validate_encryption_allowed; end module GeneratedClassMethods @@ -18047,43 +20067,43 @@ end # source://activerecord//lib/active_record/encryption/encryptable_record.rb#0 module ActiveRecord::Encryption::EncryptableRecord::ClassMethods - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#56 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#58 def deterministic_encrypted_attributes; end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#45 - def encrypts(*names, key_provider: T.unsafe(nil), key: T.unsafe(nil), deterministic: T.unsafe(nil), downcase: T.unsafe(nil), ignore_case: T.unsafe(nil), previous: T.unsafe(nil), **context_properties); end + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#49 + def encrypts(*names, key_provider: T.unsafe(nil), key: T.unsafe(nil), deterministic: T.unsafe(nil), support_unencrypted_data: T.unsafe(nil), downcase: T.unsafe(nil), ignore_case: T.unsafe(nil), previous: T.unsafe(nil), **context_properties); end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#63 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#65 def source_attribute_from_preserved_attribute(attribute_name); end private - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#127 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#132 def add_length_validation_for_encrypted_columns; end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#82 - def encrypt_attribute(name, attribute_scheme); end + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#84 + def encrypt_attribute(name, key_provider: T.unsafe(nil), key: T.unsafe(nil), deterministic: T.unsafe(nil), support_unencrypted_data: T.unsafe(nil), downcase: T.unsafe(nil), ignore_case: T.unsafe(nil), previous: T.unsafe(nil), **context_properties); end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#76 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#78 def global_previous_schemes_for(scheme); end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#121 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#126 def load_schema!; end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#104 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#109 def override_accessors_to_preserve_original(name, original_attribute_name); end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#93 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#98 def preserve_original_encrypted(name); end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#68 - def scheme_for(key_provider: T.unsafe(nil), key: T.unsafe(nil), deterministic: T.unsafe(nil), downcase: T.unsafe(nil), ignore_case: T.unsafe(nil), previous: T.unsafe(nil), **context_properties); end + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#70 + def scheme_for(key_provider: T.unsafe(nil), key: T.unsafe(nil), deterministic: T.unsafe(nil), support_unencrypted_data: T.unsafe(nil), downcase: T.unsafe(nil), ignore_case: T.unsafe(nil), previous: T.unsafe(nil), **context_properties); end - # source://activerecord//lib/active_record/encryption/encryptable_record.rb#133 + # source://activerecord//lib/active_record/encryption/encryptable_record.rb#138 def validate_column_size(attribute_name); end end -# source://activerecord//lib/active_record/encryption/encryptable_record.rb#161 +# source://activerecord//lib/active_record/encryption/encryptable_record.rb#176 ActiveRecord::Encryption::EncryptableRecord::ORIGINAL_ATTRIBUTE_PREFIX = T.let(T.unsafe(nil), String) # An ActiveModel::Type::Value that encrypts/decrypts strings of text. @@ -18105,11 +20125,14 @@ class ActiveRecord::Encryption::EncryptedAttributeType < ::ActiveRecord::Type::T # @return [EncryptedAttributeType] a new instance of EncryptedAttributeType # # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#23 - def initialize(scheme:, cast_type: T.unsafe(nil), previous_type: T.unsafe(nil)); end + def initialize(scheme:, cast_type: T.unsafe(nil), previous_type: T.unsafe(nil), default: T.unsafe(nil)); end # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#16 def accessor(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#31 + def cast(value); end + # Returns the value of attribute cast_type. # # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#13 @@ -18117,10 +20140,10 @@ class ActiveRecord::Encryption::EncryptedAttributeType < ::ActiveRecord::Type::T # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#42 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#51 def changed_in_place?(raw_old_value, new_value); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#30 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#35 def deserialize(value); end # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#15 @@ -18129,6 +20152,11 @@ class ActiveRecord::Encryption::EncryptedAttributeType < ::ActiveRecord::Type::T # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#15 def downcase?(*_arg0, **_arg1, &_arg2); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#47 + def encrypted?(value); end + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#15 def fixed?(*_arg0, **_arg1, &_arg2); end @@ -18138,7 +20166,7 @@ class ActiveRecord::Encryption::EncryptedAttributeType < ::ActiveRecord::Type::T # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#15 def previous_schemes(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#47 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#56 def previous_types; end # Returns the value of attribute scheme. @@ -18146,66 +20174,75 @@ class ActiveRecord::Encryption::EncryptedAttributeType < ::ActiveRecord::Type::T # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#13 def scheme; end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#34 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#39 def serialize(value); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#61 + def support_unencrypted_data?; end + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#15 def with_context(*_arg0, **_arg1, &_arg2); end private - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#61 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#74 def build_previous_types_for(schemes); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#135 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#162 def clean_text_scheme; end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#71 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#102 def decrypt(value); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#131 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#84 + def decrypt_as_text(value); end + + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#158 def decryption_options; end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#113 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#146 def encrypt(value); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#127 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#136 + def encrypt_as_text(value); end + + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#154 def encryption_options; end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#119 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#150 def encryptor; end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#91 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#114 def handle_deserialize_error(error, value); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#53 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#66 def previous_schemes_including_clean_text; end # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#67 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#80 def previous_type?; end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#57 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#70 def previous_types_without_clean_text; end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#107 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#130 def serialize_with_current(value); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#103 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#126 def serialize_with_oldest(value); end # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#99 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#122 def serialize_with_oldest?; end - # @return [Boolean] - # - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#123 - def support_unencrypted_data?; end + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#166 + def text_to_database_type(value); end - # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#83 + # source://activerecord//lib/active_record/encryption/encrypted_attribute_type.rb#106 def try_to_deserialize_with_previous_encrypted_types(value); end end @@ -18239,6 +20276,21 @@ end # # source://activerecord//lib/active_record/encryption/encryptor.rb#14 class ActiveRecord::Encryption::Encryptor + # === Options + # + # * :compress - Boolean indicating whether records should be compressed before encryption. + # Defaults to +true+. + # + # @return [Encryptor] a new instance of Encryptor + # + # source://activerecord//lib/active_record/encryption/encryptor.rb#19 + def initialize(compress: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/encryptor.rb#77 + def binary?; end + # Decrypts a +clean_text+ and returns the result as clean text # # === Options @@ -18251,7 +20303,7 @@ class ActiveRecord::Encryption::Encryptor # Cipher-specific options that will be passed to the Cipher configured in # +ActiveRecord::Encryption.cipher+ # - # source://activerecord//lib/active_record/encryption/encryptor.rb#52 + # source://activerecord//lib/active_record/encryption/encryptor.rb#60 def decrypt(encrypted_text, key_provider: T.unsafe(nil), cipher_options: T.unsafe(nil)); end # Encrypts +clean_text+ and returns the encrypted result @@ -18274,67 +20326,72 @@ class ActiveRecord::Encryption::Encryptor # Cipher-specific options that will be passed to the Cipher configured in # +ActiveRecord::Encryption.cipher+ # - # source://activerecord//lib/active_record/encryption/encryptor.rb#34 + # source://activerecord//lib/active_record/encryption/encryptor.rb#42 def encrypt(clear_text, key_provider: T.unsafe(nil), cipher_options: T.unsafe(nil)); end # Returns whether the text is encrypted or not # # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/encryptor.rb#62 + # source://activerecord//lib/active_record/encryption/encryptor.rb#70 def encrypted?(text); end private - # source://activerecord//lib/active_record/encryption/encryptor.rb#88 + # source://activerecord//lib/active_record/encryption/encryptor.rb#100 def build_encrypted_message(clear_text, key_provider:, cipher_options:); end - # source://activerecord//lib/active_record/encryption/encryptor.rb#84 + # source://activerecord//lib/active_record/encryption/encryptor.rb#96 def cipher; end - # source://activerecord//lib/active_record/encryption/encryptor.rb#122 + # source://activerecord//lib/active_record/encryption/encryptor.rb#137 def compress(data); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/encryptor.rb#133 + def compress?; end + # Under certain threshold, ZIP compression is actually worse that not compressing # - # source://activerecord//lib/active_record/encryption/encryptor.rb#114 + # source://activerecord//lib/active_record/encryption/encryptor.rb#125 def compress_if_worth_it(string); end - # source://activerecord//lib/active_record/encryption/encryptor.rb#74 + # source://activerecord//lib/active_record/encryption/encryptor.rb#86 def default_key_provider; end - # source://activerecord//lib/active_record/encryption/encryptor.rb#102 + # source://activerecord//lib/active_record/encryption/encryptor.rb#114 def deserialize_message(message); end - # source://activerecord//lib/active_record/encryption/encryptor.rb#142 + # source://activerecord//lib/active_record/encryption/encryptor.rb#157 def force_encoding_if_needed(value); end - # source://activerecord//lib/active_record/encryption/encryptor.rb#150 + # source://activerecord//lib/active_record/encryption/encryptor.rb#165 def forced_encoding_for_deterministic_encryption; end - # source://activerecord//lib/active_record/encryption/encryptor.rb#98 + # source://activerecord//lib/active_record/encryption/encryptor.rb#110 def serialize_message(message); end - # source://activerecord//lib/active_record/encryption/encryptor.rb#109 + # source://activerecord//lib/active_record/encryption/encryptor.rb#120 def serializer; end - # source://activerecord//lib/active_record/encryption/encryptor.rb#136 + # source://activerecord//lib/active_record/encryption/encryptor.rb#151 def uncompress(data); end - # source://activerecord//lib/active_record/encryption/encryptor.rb#128 + # source://activerecord//lib/active_record/encryption/encryptor.rb#143 def uncompress_if_needed(data, compressed); end - # source://activerecord//lib/active_record/encryption/encryptor.rb#78 + # source://activerecord//lib/active_record/encryption/encryptor.rb#90 def validate_payload_type(clear_text); end end -# source://activerecord//lib/active_record/encryption/encryptor.rb#70 +# source://activerecord//lib/active_record/encryption/encryptor.rb#82 ActiveRecord::Encryption::Encryptor::DECRYPT_ERRORS = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/encryption/encryptor.rb#71 +# source://activerecord//lib/active_record/encryption/encryptor.rb#83 ActiveRecord::Encryption::Encryptor::ENCODING_ERRORS = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/encryption/encryptor.rb#72 +# source://activerecord//lib/active_record/encryption/encryptor.rb#84 ActiveRecord::Encryption::Encryptor::THRESHOLD_TO_JUSTIFY_COMPRESSION = T.let(T.unsafe(nil), Integer) # Implements a simple envelope encryption approach where: @@ -18417,47 +20474,40 @@ class ActiveRecord::Encryption::Errors::ForbiddenClass < ::ActiveRecord::Encrypt # * ActiveRecord::Base - Used in Contact.find_by_email_address(...) # * ActiveRecord::Relation - Used in Contact.internal.find_by_email_address(...) # -# ActiveRecord::Base relies on ActiveRecord::Relation (ActiveRecord::QueryMethods) but it does -# some prepared statements caching. That's why we need to intercept +ActiveRecord::Base+ as soon -# as it's invoked (so that the proper prepared statement is cached). -# -# When modifying this file run performance tests in +test/performance/extended_deterministic_queries_performance_test.rb+ to -# make sure performance overhead is acceptable. -# -# We will extend this to support previous "encryption context" versions in future iterations +# This module is included if `config.active_record.encryption.extend_queries` is `true`. # -# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#33 +# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#23 module ActiveRecord::Encryption::ExtendedDeterministicQueries class << self - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#34 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#24 def install_support; end end end -# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#121 +# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#132 class ActiveRecord::Encryption::ExtendedDeterministicQueries::AdditionalValue # @return [AdditionalValue] a new instance of AdditionalValue # - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#124 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#135 def initialize(value, type); end # Returns the value of attribute type. # - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#122 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#133 def type; end # Returns the value of attribute value. # - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#122 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#133 def value; end private - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#130 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#141 def process(value); end end -# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#108 +# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#122 module ActiveRecord::Encryption::ExtendedDeterministicQueries::CoreQueries extend ::ActiveSupport::Concern @@ -18466,65 +20516,48 @@ end # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#0 module ActiveRecord::Encryption::ExtendedDeterministicQueries::CoreQueries::ClassMethods - include ::ActiveRecord::Encryption::ExtendedDeterministicQueries::EncryptedQueryArgumentProcessor - - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#114 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#126 def find_by(*args); end end +# When modifying this file run performance tests in +# +activerecord/test/cases/encryption/performance/extended_deterministic_queries_performance_test.rb+ +# to make sure performance overhead is acceptable. +# # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#41 -module ActiveRecord::Encryption::ExtendedDeterministicQueries::EncryptedQueryArgumentProcessor - extend ::ActiveSupport::Concern - - private +module ActiveRecord::Encryption::ExtendedDeterministicQueries::EncryptedQuery + class << self + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#43 + def process_arguments(owner, args, check_for_additional_values); end - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#74 - def additional_values_for(value, type); end + private - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#56 - def process_encrypted_query_argument(value, check_for_additional_values, type); end + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#87 + def additional_values_for(value, type); end - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#45 - def process_encrypted_query_arguments(args, check_for_additional_values); end + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#69 + def process_encrypted_query_argument(value, check_for_additional_values, type); end + end end -# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#135 +# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#146 module ActiveRecord::Encryption::ExtendedDeterministicQueries::ExtendedEncryptableType - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#136 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#147 def serialize(data); end end -# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#145 -module ActiveRecord::Encryption::ExtendedDeterministicQueries::InWithAdditionalValues - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#150 - def encryption_aware_type_caster; end - - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#146 - def proc_for_binds; end -end - -# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#81 +# source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#95 module ActiveRecord::Encryption::ExtendedDeterministicQueries::RelationQueries - include ::ActiveRecord::Encryption::ExtendedDeterministicQueries::EncryptedQueryArgumentProcessor - # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#89 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#100 def exists?(*args); end - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#94 - def find_or_create_by(attributes, &block); end - - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#98 - def find_or_create_by!(attributes, &block); end + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#104 + def scope_for_create; end - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#84 + # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#96 def where(*args); end - - private - - # source://activerecord//lib/active_record/encryption/extended_deterministic_queries.rb#103 - def process_encrypted_query_arguments_if_needed(args); end end # source://activerecord//lib/active_record/encryption/extended_deterministic_uniqueness_validator.rb#5 @@ -18577,12 +20610,17 @@ end # # source://activerecord//lib/active_record/encryption/key_generator.rb#8 class ActiveRecord::Encryption::KeyGenerator + # @return [KeyGenerator] a new instance of KeyGenerator + # + # source://activerecord//lib/active_record/encryption/key_generator.rb#11 + def initialize(hash_digest_class: T.unsafe(nil)); end + # Derives a key from the given password. The key will have a size in bytes of +:length+ (configured +Cipher+'s length # by default) # # The generated key will be salted with the value of +ActiveRecord::Encryption.key_derivation_salt+ # - # source://activerecord//lib/active_record/encryption/key_generator.rb#32 + # source://activerecord//lib/active_record/encryption/key_generator.rb#38 def derive_key_from(password, length: T.unsafe(nil)); end # Returns a random key in hexadecimal format. The key will have a size in bytes of +:length+ (configured +Cipher+'s @@ -18596,17 +20634,25 @@ class ActiveRecord::Encryption::KeyGenerator # # [ value ].pack("H*") # - # source://activerecord//lib/active_record/encryption/key_generator.rb#24 + # source://activerecord//lib/active_record/encryption/key_generator.rb#30 def generate_random_hex_key(length: T.unsafe(nil)); end # Returns a random key. The key will have a size in bytes of +:length+ (configured +Cipher+'s length by default) # - # source://activerecord//lib/active_record/encryption/key_generator.rb#10 + # source://activerecord//lib/active_record/encryption/key_generator.rb#16 def generate_random_key(length: T.unsafe(nil)); end + # Returns the value of attribute hash_digest_class. + # + # source://activerecord//lib/active_record/encryption/key_generator.rb#9 + def hash_digest_class; end + private - # source://activerecord//lib/active_record/encryption/key_generator.rb#37 + # source://activerecord//lib/active_record/encryption/key_generator.rb#44 + def key_derivation_salt; end + + # source://activerecord//lib/active_record/encryption/key_generator.rb#48 def key_length; end end @@ -18710,37 +20756,42 @@ end # to prevent JSON parsing errors and encoding issues when # storing the resulting serialized data. # -# source://activerecord//lib/active_record/encryption/message_serializer.rb#21 +# source://activerecord//lib/active_record/encryption/message_serializer.rb#23 class ActiveRecord::Encryption::MessageSerializer + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/message_serializer.rb#36 + def binary?; end + # @raise [ActiveRecord::Encryption::Errors::ForbiddenClass] # - # source://activerecord//lib/active_record/encryption/message_serializer.rb#29 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#31 def dump(message); end - # source://activerecord//lib/active_record/encryption/message_serializer.rb#22 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#24 def load(serialized_content); end private - # source://activerecord//lib/active_record/encryption/message_serializer.rb#79 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#85 def decode_if_needed(value); end - # source://activerecord//lib/active_record/encryption/message_serializer.rb#71 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#77 def encode_if_needed(value); end - # source://activerecord//lib/active_record/encryption/message_serializer.rb#65 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#71 def headers_to_json(headers); end - # source://activerecord//lib/active_record/encryption/message_serializer.rb#58 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#64 def message_to_json(message); end - # source://activerecord//lib/active_record/encryption/message_serializer.rb#35 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#41 def parse_message(data, level); end - # source://activerecord//lib/active_record/encryption/message_serializer.rb#50 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#56 def parse_properties(headers, level); end - # source://activerecord//lib/active_record/encryption/message_serializer.rb#40 + # source://activerecord//lib/active_record/encryption/message_serializer.rb#46 def validate_message_data_format(data, level); end end @@ -18749,6 +20800,11 @@ end # # source://activerecord//lib/active_record/encryption/null_encryptor.rb#7 class ActiveRecord::Encryption::NullEncryptor + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/null_encryptor.rb#20 + def binary?; end + # source://activerecord//lib/active_record/encryption/null_encryptor.rb#12 def decrypt(encrypted_text, key_provider: T.unsafe(nil), cipher_options: T.unsafe(nil)); end @@ -18783,6 +20839,9 @@ class ActiveRecord::Encryption::Properties # source://activerecord//lib/active_record/encryption/properties.rb#20 def ==(arg); end + # source://activerecord//lib/active_record/encryption/properties.rb#20 + def [](*_arg0, **_arg1, &_arg2); end + # Set a value for a given key # # It will raise an +EncryptedContentIntegrity+ if the value exists @@ -18807,6 +20866,9 @@ class ActiveRecord::Encryption::Properties # source://activerecord//lib/active_record/encryption/properties.rb#37 def compressed=(value); end + # source://activerecord//lib/active_record/encryption/properties.rb#20 + def each(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/encryption/properties.rb#33 def encoding; end @@ -18831,8 +20893,11 @@ class ActiveRecord::Encryption::Properties # source://activerecord//lib/active_record/encryption/properties.rb#37 def iv=(value); end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#302 - def method_missing(method, *args, **_arg2, &block); end + # source://activerecord//lib/active_record/encryption/properties.rb#20 + def key?(*_arg0, **_arg1, &_arg2); end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#187 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # source://activerecord//lib/active_record/encryption/properties.rb#68 def to_h; end @@ -18847,7 +20912,7 @@ class ActiveRecord::Encryption::Properties # source://activerecord//lib/active_record/encryption/properties.rb#73 def data; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#294 + # source://activesupport/7.2.0/lib/active_support/delegation.rb#179 def respond_to_missing?(name, include_private = T.unsafe(nil)); end end @@ -18867,6 +20932,11 @@ ActiveRecord::Encryption::Properties::DEFAULT_PROPERTIES = T.let(T.unsafe(nil), # # source://activerecord//lib/active_record/encryption/read_only_null_encryptor.rb#10 class ActiveRecord::Encryption::ReadOnlyNullEncryptor + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/read_only_null_encryptor.rb#23 + def binary?; end + # source://activerecord//lib/active_record/encryption/read_only_null_encryptor.rb#15 def decrypt(encrypted_text, key_provider: T.unsafe(nil), cipher_options: T.unsafe(nil)); end @@ -18892,32 +20962,37 @@ class ActiveRecord::Encryption::Scheme # @return [Scheme] a new instance of Scheme # # source://activerecord//lib/active_record/encryption/scheme.rb#13 - def initialize(key_provider: T.unsafe(nil), key: T.unsafe(nil), deterministic: T.unsafe(nil), downcase: T.unsafe(nil), ignore_case: T.unsafe(nil), previous_schemes: T.unsafe(nil), **context_properties); end + def initialize(key_provider: T.unsafe(nil), key: T.unsafe(nil), deterministic: T.unsafe(nil), support_unencrypted_data: T.unsafe(nil), downcase: T.unsafe(nil), ignore_case: T.unsafe(nil), previous_schemes: T.unsafe(nil), **context_properties); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/scheme.rb#73 + def compatible_with?(other_scheme); end # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/scheme.rb#38 + # source://activerecord//lib/active_record/encryption/scheme.rb#39 def deterministic?; end # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/scheme.rb#34 + # source://activerecord//lib/active_record/encryption/scheme.rb#35 def downcase?; end # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/scheme.rb#42 + # source://activerecord//lib/active_record/encryption/scheme.rb#47 def fixed?; end # @return [Boolean] # - # source://activerecord//lib/active_record/encryption/scheme.rb#30 + # source://activerecord//lib/active_record/encryption/scheme.rb#31 def ignore_case?; end - # source://activerecord//lib/active_record/encryption/scheme.rb#47 + # source://activerecord//lib/active_record/encryption/scheme.rb#52 def key_provider; end - # source://activerecord//lib/active_record/encryption/scheme.rb#54 + # source://activerecord//lib/active_record/encryption/scheme.rb#56 def merge(other_scheme); end # Returns the value of attribute previous_schemes. @@ -18932,27 +21007,32 @@ class ActiveRecord::Encryption::Scheme # source://activerecord//lib/active_record/encryption/scheme.rb#11 def previous_schemes=(_arg0); end - # source://activerecord//lib/active_record/encryption/scheme.rb#58 + # @return [Boolean] + # + # source://activerecord//lib/active_record/encryption/scheme.rb#43 + def support_unencrypted_data?; end + + # source://activerecord//lib/active_record/encryption/scheme.rb#60 def to_h; end - # source://activerecord//lib/active_record/encryption/scheme.rb#63 + # source://activerecord//lib/active_record/encryption/scheme.rb#65 def with_context(&block); end private - # source://activerecord//lib/active_record/encryption/scheme.rb#90 - def build_key_provider; end + # source://activerecord//lib/active_record/encryption/scheme.rb#95 + def default_key_provider; end - # @raise [Errors::Configuration] - # - # source://activerecord//lib/active_record/encryption/scheme.rb#72 - def validate_config!; end + # source://activerecord//lib/active_record/encryption/scheme.rb#89 + def deterministic_key_provider; end # source://activerecord//lib/active_record/encryption/scheme.rb#83 - def validate_credential(key, error_message = T.unsafe(nil)); end + def key_provider_from_key; end - # source://activerecord//lib/active_record/encryption/scheme.rb#77 - def validate_keys!; end + # @raise [Errors::Configuration] + # + # source://activerecord//lib/active_record/encryption/scheme.rb#78 + def validate_config!; end end # Declare an enum attribute where the values map to integers in the database, @@ -19063,130 +21143,181 @@ end # conversation.comments_inactive! # conversation.comments_active? # => false # -# source://activerecord//lib/active_record/enum.rb#114 +# If you want to disable the auto-generated methods on the model, you can do +# so by setting the +:instance_methods+ option to false: +# +# class Conversation < ActiveRecord::Base +# enum :status, [ :active, :archived ], instance_methods: false +# end +# +# If you want the enum value to be validated before saving, use the option +:validate+: +# +# class Conversation < ActiveRecord::Base +# enum :status, [ :active, :archived ], validate: true +# end +# +# conversation = Conversation.new +# +# conversation.status = :unknown +# conversation.valid? # => false +# +# conversation.status = nil +# conversation.valid? # => false +# +# conversation.status = :active +# conversation.valid? # => true +# +# It is also possible to pass additional validation options: +# +# class Conversation < ActiveRecord::Base +# enum :status, [ :active, :archived ], validate: { allow_nil: true } +# end +# +# conversation = Conversation.new +# +# conversation.status = :unknown +# conversation.valid? # => false +# +# conversation.status = nil +# conversation.valid? # => true +# +# conversation.status = :active +# conversation.valid? # => true +# +# Otherwise +ArgumentError+ will raise: +# +# class Conversation < ActiveRecord::Base +# enum :status, [ :active, :archived ] +# end +# +# conversation = Conversation.new +# +# conversation.status = :unknown # 'unknown' is not a valid status (ArgumentError) +# +# source://activerecord//lib/active_record/enum.rb#165 module ActiveRecord::Enum - # source://activerecord//lib/active_record/enum.rb#167 + # source://activerecord//lib/active_record/enum.rb#216 def enum(name = T.unsafe(nil), values = T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/enum.rb#119 - def inherited(base); end - private - # source://activerecord//lib/active_record/enum.rb#180 - def _enum(name, values, prefix: T.unsafe(nil), suffix: T.unsafe(nil), scopes: T.unsafe(nil), **options); end + # source://activerecord//lib/active_record/enum.rb#241 + def _enum(name, values, prefix: T.unsafe(nil), suffix: T.unsafe(nil), scopes: T.unsafe(nil), instance_methods: T.unsafe(nil), validate: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/enum.rb#261 + # source://activerecord//lib/active_record/enum.rb#338 def _enum_methods_module; end - # source://activerecord//lib/active_record/enum.rb#269 + # source://activerecord//lib/active_record/enum.rb#346 def assert_valid_enum_definition_values(values); end - # source://activerecord//lib/active_record/enum.rb#288 + # source://activerecord//lib/active_record/enum.rb#379 def detect_enum_conflict!(enum_name, method_name, klass_method = T.unsafe(nil)); end - # source://activerecord//lib/active_record/enum.rb#310 + # source://activerecord//lib/active_record/enum.rb#403 def detect_negative_enum_conditions!(method_names); end + # source://activerecord//lib/active_record/enum.rb#236 + def inherited(base); end + # @raise [ArgumentError] # - # source://activerecord//lib/active_record/enum.rb#300 + # source://activerecord//lib/active_record/enum.rb#393 def raise_conflict_error(enum_name, method_name, type: T.unsafe(nil), source: T.unsafe(nil)); end class << self - # source://activerecord//lib/active_record/enum.rb#115 + # source://activerecord//lib/active_record/enum.rb#166 def extended(base); end end end -# source://activerecord//lib/active_record/enum.rb#282 +# source://activerecord//lib/active_record/enum.rb#373 ActiveRecord::Enum::ENUM_CONFLICT_MESSAGE = T.let(T.unsafe(nil), String) -# source://activerecord//lib/active_record/enum.rb#231 +# source://activerecord//lib/active_record/enum.rb#306 class ActiveRecord::Enum::EnumMethods < ::Module # @return [EnumMethods] a new instance of EnumMethods # - # source://activerecord//lib/active_record/enum.rb#232 + # source://activerecord//lib/active_record/enum.rb#307 def initialize(klass); end private - # source://activerecord//lib/active_record/enum.rb#239 - def define_enum_methods(name, value_method_name, value, scopes); end + # source://activerecord//lib/active_record/enum.rb#314 + def define_enum_methods(name, value_method_name, value, scopes, instance_methods); end # Returns the value of attribute klass. # - # source://activerecord//lib/active_record/enum.rb#237 + # source://activerecord//lib/active_record/enum.rb#312 def klass; end end -# source://activerecord//lib/active_record/enum.rb#124 +# source://activerecord//lib/active_record/enum.rb#170 class ActiveRecord::Enum::EnumType < ::ActiveModel::Type::Value # @return [EnumType] a new instance of EnumType # - # source://activerecord//lib/active_record/enum.rb#127 - def initialize(name, mapping, subtype); end + # source://activerecord//lib/active_record/enum.rb#173 + def initialize(name, mapping, subtype, raise_on_invalid_values: T.unsafe(nil)); end - # source://activerecord//lib/active_record/enum.rb#155 + # source://activerecord//lib/active_record/enum.rb#202 def assert_valid_value(value); end - # source://activerecord//lib/active_record/enum.rb#133 + # source://activerecord//lib/active_record/enum.rb#180 def cast(value); end - # source://activerecord//lib/active_record/enum.rb#143 + # source://activerecord//lib/active_record/enum.rb#190 def deserialize(value); end # @return [Boolean] # - # source://activerecord//lib/active_record/enum.rb#151 + # source://activerecord//lib/active_record/enum.rb#198 def serializable?(value, &block); end - # source://activerecord//lib/active_record/enum.rb#147 + # source://activerecord//lib/active_record/enum.rb#194 def serialize(value); end # Returns the value of attribute subtype. # - # source://activerecord//lib/active_record/enum.rb#161 + # source://activerecord//lib/active_record/enum.rb#210 def subtype; end - # source://activerecord//lib/active_record/enum.rb#125 + # source://activerecord//lib/active_record/enum.rb#171 def type(*_arg0, **_arg1, &_arg2); end private # Returns the value of attribute mapping. # - # source://activerecord//lib/active_record/enum.rb#164 + # source://activerecord//lib/active_record/enum.rb#213 def mapping; end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/enum.rb#164 + # source://activerecord//lib/active_record/enum.rb#213 def name; end end -# source://activerecord//lib/active_record/migration.rb#197 +# source://activerecord//lib/active_record/migration.rb#219 class ActiveRecord::EnvironmentMismatchError < ::ActiveRecord::ActiveRecordError # @return [EnvironmentMismatchError] a new instance of EnvironmentMismatchError # - # source://activerecord//lib/active_record/migration.rb#198 + # source://activerecord//lib/active_record/migration.rb#220 def initialize(current: T.unsafe(nil), stored: T.unsafe(nil)); end end -# source://activerecord//lib/active_record/migration.rb#211 +# source://activerecord//lib/active_record/migration.rb#233 class ActiveRecord::EnvironmentStorageError < ::ActiveRecord::ActiveRecordError # @return [EnvironmentStorageError] a new instance of EnvironmentStorageError # - # source://activerecord//lib/active_record/migration.rb#212 + # source://activerecord//lib/active_record/migration.rb#234 def initialize; end end # Raised when a pool was unable to get ahold of all its connections # to perform a "group" action such as # {ActiveRecord::Base.connection_pool.disconnect!}[rdoc-ref:ConnectionAdapters::ConnectionPool#disconnect!] -# or {ActiveRecord::Base.clear_reloadable_connections!}[rdoc-ref:ConnectionAdapters::ConnectionHandler#clear_reloadable_connections!]. +# or {ActiveRecord::Base.connection_handler.clear_reloadable_connections!}[rdoc-ref:ConnectionAdapters::ConnectionHandler#clear_reloadable_connections!]. # -# source://activerecord//lib/active_record/errors.rb#94 +# source://activerecord//lib/active_record/errors.rb#115 class ActiveRecord::ExclusiveConnectionTimeoutError < ::ActiveRecord::ConnectionTimeoutError; end # source://activerecord//lib/active_record/explain.rb#6 @@ -19201,12 +21332,15 @@ module ActiveRecord::Explain # Returns a formatted string ready to be logged. # # source://activerecord//lib/active_record/explain.rb#19 - def exec_explain(queries); end + def exec_explain(queries, options = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/explain.rb#39 - def render_bind(attr); end + # source://activerecord//lib/active_record/explain.rb#55 + def build_explain_clause(connection, options = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/explain.rb#40 + def render_bind(connection, attr); end end # This is a thread locals registry for EXPLAIN. For example @@ -19329,7 +21463,7 @@ module ActiveRecord::FinderMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/relation/finder_methods.rb#326 + # source://activerecord//lib/active_record/relation/finder_methods.rb#357 def exists?(conditions = T.unsafe(nil)); end # Find the fifth record. @@ -19339,16 +21473,18 @@ module ActiveRecord::FinderMethods # Person.offset(3).fifth # returns the fifth object from OFFSET 3 (which is OFFSET 7) # Person.where(["user_name = :u", { u: user_name }]).fifth # - # source://activerecord//lib/active_record/relation/finder_methods.rb#240 + # source://activerecord//lib/active_record/relation/finder_methods.rb#271 def fifth; end # Same as #fifth but raises ActiveRecord::RecordNotFound if no record # is found. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#246 + # source://activerecord//lib/active_record/relation/finder_methods.rb#277 def fifth!; end - # Find by id - This can either be a specific id (1), a list of ids (1, 5, 6), or an array of ids ([5, 6, 10]). + # Find by id - This can either be a specific id (ID), a list of ids (ID, ID, ID), or an array of ids ([ID, ID, ID]). + # `ID` refers to an "identifier". For models with a single-column primary key, `ID` will be a single value, + # and for models with a composite primary key, it will be an array of values. # If one or more records cannot be found for the requested ids, then ActiveRecord::RecordNotFound will be raised. # If the primary key is an integer, find by id coerces its arguments by using +to_i+. # @@ -19356,10 +21492,31 @@ module ActiveRecord::FinderMethods # Person.find("1") # returns the object for ID = 1 # Person.find("31-sarah") # returns the object for ID = 31 # Person.find(1, 2, 6) # returns an array for objects with IDs in (1, 2, 6) - # Person.find([7, 17]) # returns an array for objects with IDs in (7, 17) + # Person.find([7, 17]) # returns an array for objects with IDs in (7, 17), or with composite primary key [7, 17] # Person.find([1]) # returns an array for the object with ID = 1 # Person.where("administrator = 1").order("created_on DESC").find(1) # + # ==== Find a record for a composite primary key model + # TravelRoute.primary_key = [:origin, :destination] + # + # TravelRoute.find(["Ottawa", "London"]) + # => # + # + # TravelRoute.find([["Paris", "Montreal"]]) + # => [#] + # + # TravelRoute.find(["New York", "Las Vegas"], ["New York", "Portland"]) + # => [ + # #, + # # + # ] + # + # TravelRoute.find([["Berlin", "London"], ["Barcelona", "Lisbon"]]) + # => [ + # #, + # # + # ] + # # NOTE: The returned records are in the same order as the ids you provide. # If you want the results to be sorted by database, you can use ActiveRecord::QueryMethods#where # method and provide an explicit ActiveRecord::QueryMethods#order option. @@ -19407,7 +21564,15 @@ module ActiveRecord::FinderMethods # Person.where(name: 'Spartacus', rating: 4).pluck(:field1, :field2) # # returns an Array of the required fields. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#67 + # ==== Edge Cases + # + # Person.find(37) # raises ActiveRecord::RecordNotFound exception if the record with the given ID does not exist. + # Person.find([37]) # raises ActiveRecord::RecordNotFound exception if the record with the given ID in the input array does not exist. + # Person.find(nil) # raises ActiveRecord::RecordNotFound exception if the argument is nil. + # Person.find([]) # returns an empty array if the argument is an empty array. + # Person.find # raises ActiveRecord::RecordNotFound exception if the argument is not provided. + # + # source://activerecord//lib/active_record/relation/finder_methods.rb#98 def find(*args); end # Finds the first record matching the specified conditions. There @@ -19419,13 +21584,13 @@ module ActiveRecord::FinderMethods # Post.find_by name: 'Spartacus', rating: 4 # Post.find_by "published_at < ?", 2.weeks.ago # - # source://activerecord//lib/active_record/relation/finder_methods.rb#80 + # source://activerecord//lib/active_record/relation/finder_methods.rb#111 def find_by(arg, *args); end # Like #find_by, except that if no record is found, raises # an ActiveRecord::RecordNotFound error. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#86 + # source://activerecord//lib/active_record/relation/finder_methods.rb#117 def find_by!(arg, *args); end # Finds the sole matching record. Raises ActiveRecord::RecordNotFound if no @@ -19434,7 +21599,7 @@ module ActiveRecord::FinderMethods # # Product.find_sole_by(["price = %?", price]) # - # source://activerecord//lib/active_record/relation/finder_methods.rb#129 + # source://activerecord//lib/active_record/relation/finder_methods.rb#160 def find_sole_by(arg, *args); end # Find the first record (or first N records if a parameter is supplied). @@ -19446,13 +21611,13 @@ module ActiveRecord::FinderMethods # Person.order("created_on DESC").offset(5).first # Person.first(3) # returns the first three objects fetched by SELECT * FROM people ORDER BY people.id LIMIT 3 # - # source://activerecord//lib/active_record/relation/finder_methods.rb#142 + # source://activerecord//lib/active_record/relation/finder_methods.rb#173 def first(limit = T.unsafe(nil)); end # Same as #first but raises ActiveRecord::RecordNotFound if no record # is found. Note that #first! accepts no arguments. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#152 + # source://activerecord//lib/active_record/relation/finder_methods.rb#183 def first!; end # Find the forty-second record. Also known as accessing "the reddit". @@ -19462,13 +21627,13 @@ module ActiveRecord::FinderMethods # Person.offset(3).forty_two # returns the forty-second object from OFFSET 3 (which is OFFSET 44) # Person.where(["user_name = :u", { u: user_name }]).forty_two # - # source://activerecord//lib/active_record/relation/finder_methods.rb#256 + # source://activerecord//lib/active_record/relation/finder_methods.rb#287 def forty_two; end # Same as #forty_two but raises ActiveRecord::RecordNotFound if no record # is found. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#262 + # source://activerecord//lib/active_record/relation/finder_methods.rb#293 def forty_two!; end # Find the fourth record. @@ -19478,13 +21643,13 @@ module ActiveRecord::FinderMethods # Person.offset(3).fourth # returns the fourth object from OFFSET 3 (which is OFFSET 6) # Person.where(["user_name = :u", { u: user_name }]).fourth # - # source://activerecord//lib/active_record/relation/finder_methods.rb#224 + # source://activerecord//lib/active_record/relation/finder_methods.rb#255 def fourth; end # Same as #fourth but raises ActiveRecord::RecordNotFound if no record # is found. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#230 + # source://activerecord//lib/active_record/relation/finder_methods.rb#261 def fourth!; end # Returns true if the relation contains the given record or false otherwise. @@ -19495,7 +21660,7 @@ module ActiveRecord::FinderMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/relation/finder_methods.rb#352 + # source://activerecord//lib/active_record/relation/finder_methods.rb#389 def include?(record); end # Find the last record (or last N records if a parameter is supplied). @@ -19514,13 +21679,13 @@ module ActiveRecord::FinderMethods # # [#, #, #] # - # source://activerecord//lib/active_record/relation/finder_methods.rb#171 + # source://activerecord//lib/active_record/relation/finder_methods.rb#202 def last(limit = T.unsafe(nil)); end # Same as #last but raises ActiveRecord::RecordNotFound if no record # is found. Note that #last! accepts no arguments. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#182 + # source://activerecord//lib/active_record/relation/finder_methods.rb#213 def last!; end # Returns true if the relation contains the given record or false otherwise. @@ -19531,7 +21696,7 @@ module ActiveRecord::FinderMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/relation/finder_methods.rb#352 + # source://activerecord//lib/active_record/relation/finder_methods.rb#389 def member?(record); end # This method is called whenever no records are found with either a single @@ -19543,7 +21708,7 @@ module ActiveRecord::FinderMethods # the expected number of results should be provided in the +expected_size+ # argument. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#370 + # source://activerecord//lib/active_record/relation/finder_methods.rb#417 def raise_record_not_found_exception!(ids = T.unsafe(nil), result_size = T.unsafe(nil), expected_size = T.unsafe(nil), key = T.unsafe(nil), not_found_ids = T.unsafe(nil)); end # Find the second record. @@ -19553,13 +21718,13 @@ module ActiveRecord::FinderMethods # Person.offset(3).second # returns the second object from OFFSET 3 (which is OFFSET 4) # Person.where(["user_name = :u", { u: user_name }]).second # - # source://activerecord//lib/active_record/relation/finder_methods.rb#192 + # source://activerecord//lib/active_record/relation/finder_methods.rb#223 def second; end # Same as #second but raises ActiveRecord::RecordNotFound if no record # is found. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#198 + # source://activerecord//lib/active_record/relation/finder_methods.rb#229 def second!; end # Find the second-to-last record. @@ -19569,13 +21734,13 @@ module ActiveRecord::FinderMethods # Person.offset(3).second_to_last # returns the second-to-last object from OFFSET 3 # Person.where(["user_name = :u", { u: user_name }]).second_to_last # - # source://activerecord//lib/active_record/relation/finder_methods.rb#288 + # source://activerecord//lib/active_record/relation/finder_methods.rb#319 def second_to_last; end # Same as #second_to_last but raises ActiveRecord::RecordNotFound if no record # is found. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#294 + # source://activerecord//lib/active_record/relation/finder_methods.rb#325 def second_to_last!; end # Finds the sole matching record. Raises ActiveRecord::RecordNotFound if no @@ -19584,7 +21749,7 @@ module ActiveRecord::FinderMethods # # Product.where(["price = %?", price]).sole # - # source://activerecord//lib/active_record/relation/finder_methods.rb#112 + # source://activerecord//lib/active_record/relation/finder_methods.rb#143 def sole; end # Gives a record (or N records if a parameter is supplied) without any implied @@ -19595,13 +21760,13 @@ module ActiveRecord::FinderMethods # Person.take(5) # returns 5 objects fetched by SELECT * FROM people LIMIT 5 # Person.where(["name LIKE '%?'", name]).take # - # source://activerecord//lib/active_record/relation/finder_methods.rb#97 + # source://activerecord//lib/active_record/relation/finder_methods.rb#128 def take(limit = T.unsafe(nil)); end # Same as #take but raises ActiveRecord::RecordNotFound if no record # is found. Note that #take! accepts no arguments. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#103 + # source://activerecord//lib/active_record/relation/finder_methods.rb#134 def take!; end # Find the third record. @@ -19611,13 +21776,13 @@ module ActiveRecord::FinderMethods # Person.offset(3).third # returns the third object from OFFSET 3 (which is OFFSET 5) # Person.where(["user_name = :u", { u: user_name }]).third # - # source://activerecord//lib/active_record/relation/finder_methods.rb#208 + # source://activerecord//lib/active_record/relation/finder_methods.rb#239 def third; end # Same as #third but raises ActiveRecord::RecordNotFound if no record # is found. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#214 + # source://activerecord//lib/active_record/relation/finder_methods.rb#245 def third!; end # Find the third-to-last record. @@ -19627,120 +21792,129 @@ module ActiveRecord::FinderMethods # Person.offset(3).third_to_last # returns the third-to-last object from OFFSET 3 # Person.where(["user_name = :u", { u: user_name }]).third_to_last # - # source://activerecord//lib/active_record/relation/finder_methods.rb#272 + # source://activerecord//lib/active_record/relation/finder_methods.rb#303 def third_to_last; end # Same as #third_to_last but raises ActiveRecord::RecordNotFound if no record # is found. # - # source://activerecord//lib/active_record/relation/finder_methods.rb#278 + # source://activerecord//lib/active_record/relation/finder_methods.rb#309 def third_to_last!; end private - # source://activerecord//lib/active_record/relation/finder_methods.rb#410 + # source://activerecord//lib/active_record/relation/finder_methods.rb#648 + def _order_columns; end + + # source://activerecord//lib/active_record/relation/finder_methods.rb#457 def apply_join_dependency(eager_loading: T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#391 + # source://activerecord//lib/active_record/relation/finder_methods.rb#438 def construct_relation_for_exists(conditions); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#570 + # source://activerecord//lib/active_record/relation/finder_methods.rb#636 def find_last(limit); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#532 + # source://activerecord//lib/active_record/relation/finder_methods.rb#598 def find_nth(index); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#556 + # source://activerecord//lib/active_record/relation/finder_methods.rb#622 def find_nth_from_last(index); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#537 + # source://activerecord//lib/active_record/relation/finder_methods.rb#603 def find_nth_with_limit(index, limit); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#464 + # source://activerecord//lib/active_record/relation/finder_methods.rb#520 def find_one(id); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#480 + # source://activerecord//lib/active_record/relation/finder_methods.rb#541 def find_some(ids); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#504 + # source://activerecord//lib/active_record/relation/finder_methods.rb#567 def find_some_ordered(ids); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#516 + # source://activerecord//lib/active_record/relation/finder_methods.rb#582 def find_take; end - # source://activerecord//lib/active_record/relation/finder_methods.rb#524 + # source://activerecord//lib/active_record/relation/finder_methods.rb#590 def find_take_with_limit(limit); end # @raise [UnknownPrimaryKey] # - # source://activerecord//lib/active_record/relation/finder_methods.rb#442 + # source://activerecord//lib/active_record/relation/finder_methods.rb#491 def find_with_ids(*ids); end - # source://activerecord//lib/active_record/relation/finder_methods.rb#574 + # source://activerecord//lib/active_record/relation/finder_methods.rb#640 def ordered_relation; end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/finder_methods.rb#438 + # source://activerecord//lib/active_record/relation/finder_methods.rb#487 def using_limitable_reflections?(reflections); end end # source://activerecord//lib/active_record/relation/finder_methods.rb#7 ActiveRecord::FinderMethods::ONE_AS_ONE = T.let(T.unsafe(nil), String) -# source://activerecord//lib/active_record/fixtures.rb#739 +# source://activerecord//lib/active_record/fixtures.rb#808 class ActiveRecord::Fixture include ::Enumerable # @return [Fixture] a new instance of Fixture # - # source://activerecord//lib/active_record/fixtures.rb#750 + # source://activerecord//lib/active_record/fixtures.rb#819 def initialize(fixture, model_class); end - # source://activerecord//lib/active_record/fixtures.rb#763 + # source://activerecord//lib/active_record/fixtures.rb#832 def [](key); end - # source://activerecord//lib/active_record/fixtures.rb#755 + # source://activerecord//lib/active_record/fixtures.rb#824 def class_name; end - # source://activerecord//lib/active_record/fixtures.rb#759 + # source://activerecord//lib/active_record/fixtures.rb#828 def each(&block); end # @raise [FixtureClassNotFound] # - # source://activerecord//lib/active_record/fixtures.rb#769 + # source://activerecord//lib/active_record/fixtures.rb#838 def find; end # Returns the value of attribute fixture. # - # source://activerecord//lib/active_record/fixtures.rb#748 + # source://activerecord//lib/active_record/fixtures.rb#817 def fixture; end # Returns the value of attribute model_class. # - # source://activerecord//lib/active_record/fixtures.rb#748 + # source://activerecord//lib/active_record/fixtures.rb#817 def model_class; end # Returns the value of attribute fixture. # - # source://activerecord//lib/active_record/fixtures.rb#748 + # source://activerecord//lib/active_record/fixtures.rb#817 def to_hash; end end -# source://activerecord//lib/active_record/fixtures.rb#742 +# source://activerecord//lib/active_record/fixtures.rb#811 class ActiveRecord::Fixture::FixtureError < ::StandardError; end -# source://activerecord//lib/active_record/fixtures.rb#745 +# source://activerecord//lib/active_record/fixtures.rb#814 class ActiveRecord::Fixture::FormatError < ::ActiveRecord::Fixture::FixtureError; end -# source://activerecord//lib/active_record/fixtures.rb#15 +# source://activerecord//lib/active_record/fixtures.rb#12 class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; end +# = Active Record \Fixtures +# # \Fixtures are a way of organizing data that you want to test against; in short, sample data. # -# They are stored in YAML files, one file per model, which are placed in the directory -# appointed by ActiveSupport::TestCase.fixture_path=(path) (this is automatically -# configured for Rails, so you can just put your files in /test/fixtures/). +# They are stored in YAML files, one file per model, which are by default placed in either +# /test/fixtures/ or in the test/fixtures +# folder under any of your application's engines. +# +# The location can also be changed with ActiveSupport::TestCase.fixture_paths=, +# once you have require "rails/test_help" in your +test_helper.rb+. +# # The fixture file ends with the +.yml+ file extension, for example: # /test/fixtures/web_sites.yml). # @@ -19760,10 +21934,17 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # is followed by an indented list of key/value pairs in the "key: value" format. Records are # separated by a blank line for your viewing pleasure. # -# Note: Fixtures are unordered. If you want ordered fixtures, use the omap YAML type. -# See https://yaml.org/type/omap.html -# for the specification. You will need ordered fixtures when you have foreign key constraints -# on keys in the same table. This is commonly needed for tree structures. Example: +# == Ordering +# +# Fixtures by default are unordered. This is because the maps in YAML are unordered. +# +# If you want ordered fixtures, use the omap YAML type. +# See https://yaml.org/type/omap.html for the specification. +# +# You will need ordered fixtures when you have foreign key constraints +# on keys in the same table. This is commonly needed for tree structures. +# +# For example: # # --- !omap # - parent: @@ -19775,7 +21956,7 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # parent_id: 1 # title: Child # -# = Using Fixtures in Test Cases +# == Using Fixtures in Test Cases # # Since fixtures are a testing construct, we use them in our unit and functional tests. There # are two ways to use the fixtures, but first let's take a look at a sample unit test: @@ -19821,6 +22002,12 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # assert_raise(StandardError) { web_sites(:reddit) } # end # +# If the model names conflicts with a +TestCase+ methods, you can use the generic +fixture+ accessor +# +# test "generic find" do +# assert_equal "Ruby on Rails", fixture(:web_sites, :rubyonrails).name +# end +# # Alternatively, you may enable auto-instantiation of the fixture data. For instance, take the # following tests: # @@ -19845,7 +22032,7 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # traversed in the database to create the fixture hash and/or instance variables. This is expensive for # large sets of fixtured data. # -# = Dynamic fixtures with ERB +# == Dynamic fixtures with \ERB # # Sometimes you don't care about the content of the fixtures as much as you care about the volume. # In these cases, you can mix ERB in with your YAML fixtures to create a bunch of fixtures for load @@ -19883,7 +22070,7 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # name: kitten.png # sha: <%= file_sha 'files/kitten.png' %> # -# = Transactional Tests +# == Transactional Tests # # Test cases can use begin+rollback to isolate their changes to the database instead of having to # delete+insert for every test case. @@ -19919,7 +22106,7 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # 2. Your database does not support transactions. Every Active Record database supports transactions except MySQL MyISAM. # Use InnoDB, MaxDB, or NDB instead. # -# = Advanced Fixtures +# == Advanced Fixtures # # Fixtures that don't specify an ID get some extra features: # @@ -19933,7 +22120,7 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # * Fixture label interpolation # * Support for YAML defaults # -# == Stable, Autogenerated IDs +# === Stable, Autogenerated IDs # # Here, have a monkey fixture: # @@ -19962,13 +22149,13 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # The generated ID for a given label is constant, so we can discover # any fixture's ID without loading anything, as long as we know the label. # -# == Label references for associations (+belongs_to+, +has_one+, +has_many+) +# === Label references for associations (+belongs_to+, +has_one+, +has_many+) # # Specifying foreign keys in fixtures can be very fragile, not to # mention difficult to read. Since Active Record can figure out the ID of # any fixture from its label, you can specify FK's by label instead of ID. # -# === +belongs_to+ +# ==== +belongs_to+ # # Let's break out some more monkeys and pirates. # @@ -19979,6 +22166,8 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # name: Reginald the Pirate # monkey_id: 1 # +# +# # ### in monkeys.yml # # george: @@ -19996,6 +22185,8 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # name: Reginald the Pirate # monkey: george # +# +# # ### in monkeys.yml # # george: @@ -20017,6 +22208,8 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # # belongs_to :eater, polymorphic: true # +# +# # ### in fruits.yml # # apple: @@ -20032,9 +22225,9 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # # Just provide the polymorphic target type and Active Record will take care of the rest. # -# === +has_and_belongs_to_many+ or has_many :through +# ==== +has_and_belongs_to_many+ or has_many :through # -# Time to give our monkey some fruit. +# \Time to give our monkey some fruit. # # ### in monkeys.yml # @@ -20042,6 +22235,8 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # id: 1 # name: George the Monkey # +# +# # ### in fruits.yml # # apple: @@ -20056,6 +22251,8 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # id: 3 # name: grape # +# +# # ### in fruits_monkeys.yml # # apple_george: @@ -20079,6 +22276,8 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # name: George the Monkey # fruits: apple, orange, grape # +# +# # ### in fruits.yml # # apple: @@ -20096,7 +22295,7 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # the fixture's model class and discovers the +has_and_belongs_to_many+ # associations. # -# == Autofilled Timestamp Columns +# === Autofilled \Timestamp Columns # # If your table/model specifies any of Active Record's # standard timestamp columns (+created_at+, +created_on+, +updated_at+, +updated_on+), @@ -20104,7 +22303,7 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # # If you've set specific values, they'll be left alone. # -# == Fixture label interpolation +# === Fixture label interpolation # # The label of the current fixture is always available as a column value: # @@ -20121,7 +22320,11 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # monkey_id: <%= ActiveRecord::FixtureSet.identify(:reginald) %> # pirate_id: <%= ActiveRecord::FixtureSet.identify(:george) %> # -# == Support for YAML defaults +# If the model uses UUID values for identifiers, add the +:uuid+ argument: +# +# ActiveRecord::FixtureSet.identify(:boaty_mcboatface, :uuid) +# +# === Support for YAML defaults # # You can set and reuse defaults in your fixtures YAML file. # This is the same technique used in the +database.yml+ file to specify @@ -20163,6 +22366,45 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # In the above example, 'base' will be ignored when creating fixtures. # This can be used for common attributes inheriting. # +# == Composite Primary Key Fixtures +# +# Fixtures for composite primary key tables are fairly similar to normal tables. +# When using an id column, the column may be omitted as usual: +# +# # app/models/book.rb +# class Book < ApplicationRecord +# self.primary_key = [:author_id, :id] +# belongs_to :author +# end +# +# +# +# # books.yml +# alices_adventure_in_wonderland: +# author_id: <%= ActiveRecord::FixtureSet.identify(:lewis_carroll) %> +# title: "Alice's Adventures in Wonderland" +# +# However, in order to support composite primary key relationships, +# you must use the `composite_identify` method: +# +# # app/models/book_orders.rb +# class BookOrder < ApplicationRecord +# self.primary_key = [:shop_id, :id] +# belongs_to :order, foreign_key: [:shop_id, :order_id] +# belongs_to :book, foreign_key: [:author_id, :book_id] +# end +# +# +# +# # book_orders.yml +# alices_adventure_in_wonderland_in_books: +# author: lewis_carroll +# book_id: <%= ActiveRecord::FixtureSet.composite_identify( +# :alices_adventure_in_wonderland, Book.primary_key)[:id] %> +# shop: book_store +# order_id: <%= ActiveRecord::FixtureSet.composite_identify( +# :books, Order.primary_key)[:id] %> +# # == Configure the fixture model class # # It's possible to set the fixture's model class directly in the YAML file. @@ -20177,167 +22419,164 @@ class ActiveRecord::FixtureClassNotFound < ::ActiveRecord::ActiveRecordError; en # # Any fixtures labeled "_fixture" are safely ignored. # -# source://activerecord//lib/active_record/fixture_set/file.rb#6 +# source://activerecord//lib/active_record/fixtures.rb#529 class ActiveRecord::FixtureSet # @return [FixtureSet] a new instance of FixtureSet # - # source://activerecord//lib/active_record/fixtures.rb#650 + # source://activerecord//lib/active_record/fixtures.rb#715 def initialize(_, name, class_name, path, config = T.unsafe(nil)); end - # source://activerecord//lib/active_record/fixtures.rb#662 + # source://activerecord//lib/active_record/fixtures.rb#726 def [](x); end - # source://activerecord//lib/active_record/fixtures.rb#666 + # source://activerecord//lib/active_record/fixtures.rb#730 def []=(k, v); end - # source://activerecord//lib/active_record/fixtures.rb#468 + # source://activerecord//lib/active_record/fixtures.rb#543 def all_loaded_fixtures; end - # source://activerecord//lib/active_record/fixtures.rb#468 + # source://activerecord//lib/active_record/fixtures.rb#543 def all_loaded_fixtures=(val); end # Returns the value of attribute config. # - # source://activerecord//lib/active_record/fixtures.rb#648 + # source://activerecord//lib/active_record/fixtures.rb#713 def config; end - # source://activerecord//lib/active_record/fixtures.rb#670 + # source://activerecord//lib/active_record/fixtures.rb#734 def each(&block); end # Returns the value of attribute fixtures. # - # source://activerecord//lib/active_record/fixtures.rb#648 + # source://activerecord//lib/active_record/fixtures.rb#713 def fixtures; end # Returns the value of attribute ignored_fixtures. # - # source://activerecord//lib/active_record/fixtures.rb#648 + # source://activerecord//lib/active_record/fixtures.rb#713 def ignored_fixtures; end # Returns the value of attribute model_class. # - # source://activerecord//lib/active_record/fixtures.rb#648 + # source://activerecord//lib/active_record/fixtures.rb#713 def model_class; end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/fixtures.rb#648 + # source://activerecord//lib/active_record/fixtures.rb#713 def name; end - # source://activerecord//lib/active_record/fixtures.rb#674 + # source://activerecord//lib/active_record/fixtures.rb#738 def size; end # Returns the value of attribute table_name. # - # source://activerecord//lib/active_record/fixtures.rb#648 + # source://activerecord//lib/active_record/fixtures.rb#713 def table_name; end # Returns a hash of rows to be inserted. The key is the table, the value is # a list of rows to insert to that table. # - # source://activerecord//lib/active_record/fixtures.rb#680 + # source://activerecord//lib/active_record/fixtures.rb#744 def table_rows; end private - # source://activerecord//lib/active_record/fixtures.rb#700 + # source://activerecord//lib/active_record/fixtures.rb#802 + def default_fixture_model_class; end + + # source://activerecord//lib/active_record/fixtures.rb#764 def ignored_fixtures=(base); end - # source://activerecord//lib/active_record/fixtures.rb#692 + # source://activerecord//lib/active_record/fixtures.rb#756 def model_class=(class_name); end # Loads the fixtures from the YAML file at +path+. # If the file sets the +model_class+ and current instance value is not set, # it uses the file value. # - # source://activerecord//lib/active_record/fixtures.rb#718 + # @raise [ArgumentError] + # + # source://activerecord//lib/active_record/fixtures.rb#783 def read_fixture_files(path); end - # source://activerecord//lib/active_record/fixtures.rb#734 - def yaml_file_path(path); end - class << self - # source://activerecord//lib/active_record/fixtures.rb#468 + # source://activerecord//lib/active_record/fixtures.rb#543 def all_loaded_fixtures; end - # source://activerecord//lib/active_record/fixtures.rb#468 + # source://activerecord//lib/active_record/fixtures.rb#543 def all_loaded_fixtures=(val); end - # source://activerecord//lib/active_record/fixtures.rb#536 - def cache_fixtures(connection, fixtures_map); end + # source://activerecord//lib/active_record/fixtures.rb#578 + def cache_fixtures(connection_pool, fixtures_map); end - # source://activerecord//lib/active_record/fixtures.rb#520 - def cache_for_connection(connection); end + # source://activerecord//lib/active_record/fixtures.rb#562 + def cache_for_connection_pool(connection_pool); end - # source://activerecord//lib/active_record/fixtures.rb#528 - def cached_fixtures(connection, keys_to_fetch = T.unsafe(nil)); end + # source://activerecord//lib/active_record/fixtures.rb#570 + def cached_fixtures(connection_pool, keys_to_fetch = T.unsafe(nil)); end - # Superclass for the evaluation contexts used by ERB fixtures. + # Returns a consistent, platform-independent hash representing a mapping + # between the label and the subcomponents of the provided composite key. + # + # Example: # - # source://activerecord//lib/active_record/fixtures.rb#589 + # composite_identify("label", [:a, :b, :c]) # => { a: hash_1, b: hash_2, c: hash_3 } + # + # source://activerecord//lib/active_record/fixtures.rb#635 + def composite_identify(label, key); end + + # Superclass for the evaluation contexts used by \ERB fixtures. + # + # source://activerecord//lib/active_record/fixtures.rb#643 def context_class; end - # source://activerecord//lib/active_record/fixtures.rb#555 - def create_fixtures(fixtures_directory, fixture_set_names, class_names = T.unsafe(nil), config = T.unsafe(nil), &block); end + # source://activerecord//lib/active_record/fixtures.rb#597 + def create_fixtures(fixtures_directories, fixture_set_names, class_names = T.unsafe(nil), config = T.unsafe(nil)); end - # source://activerecord//lib/active_record/fixtures.rb#504 + # source://activerecord//lib/active_record/fixtures.rb#546 def default_fixture_model_name(fixture_set_name, config = T.unsafe(nil)); end - # source://activerecord//lib/active_record/fixtures.rb#510 + # source://activerecord//lib/active_record/fixtures.rb#552 def default_fixture_table_name(fixture_set_name, config = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/active_record/fixtures.rb#524 - def fixture_is_cached?(connection, table_name); end + # source://activerecord//lib/active_record/fixtures.rb#566 + def fixture_is_cached?(connection_pool, table_name); end # Returns a consistent, platform-independent identifier for +label+. - # Integer identifiers are values less than 2^30. UUIDs are RFC 4122 version 5 SHA-1 hashes. # - # source://activerecord//lib/active_record/fixtures.rb#580 + # \Integer identifiers are values less than 2^30. UUIDs are RFC 4122 version 5 SHA-1 hashes. + # + # source://activerecord//lib/active_record/fixtures.rb#621 def identify(label, column_type = T.unsafe(nil)); end - # source://activerecord//lib/active_record/fixtures.rb#549 + # source://activerecord//lib/active_record/fixtures.rb#591 def instantiate_all_loaded_fixtures(object, load_instances = T.unsafe(nil)); end - # source://activerecord//lib/active_record/fixtures.rb#540 + # source://activerecord//lib/active_record/fixtures.rb#582 def instantiate_fixtures(object, fixture_set, load_instances = T.unsafe(nil)); end - # source://activerecord//lib/active_record/fixtures.rb#516 + # source://activerecord//lib/active_record/fixtures.rb#558 def reset_cache; end private - # source://activerecord//lib/active_record/fixtures.rb#612 - def insert(fixture_sets, connection); end + # source://activerecord//lib/active_record/fixtures.rb#698 + def check_all_foreign_keys_valid!(conn); end - # source://activerecord//lib/active_record/fixtures.rb#594 - def read_and_insert(fixtures_directory, fixture_files, class_names, connection); end + # source://activerecord//lib/active_record/fixtures.rb#667 + def insert(fixture_sets, connection_pool); end - # source://activerecord//lib/active_record/fixtures.rb#643 + # source://activerecord//lib/active_record/fixtures.rb#648 + def read_and_insert(fixtures_directories, fixture_files, class_names, connection_pool); end + + # source://activerecord//lib/active_record/fixtures.rb#708 def update_all_loaded_fixtures(fixtures_map); end end end -# source://activerecord//lib/active_record/fixtures.rb#470 -class ActiveRecord::FixtureSet::ClassCache - # @return [ClassCache] a new instance of ClassCache - # - # source://activerecord//lib/active_record/fixtures.rb#471 - def initialize(class_names, config); end - - # source://activerecord//lib/active_record/fixtures.rb#481 - def [](fs_name); end - - private - - # source://activerecord//lib/active_record/fixtures.rb#498 - def default_fixture_model(fs_name, config); end - - # source://activerecord//lib/active_record/fixtures.rb#489 - def insert_class(class_names, name, klass); end -end - # source://activerecord//lib/active_record/fixture_set/file.rb#7 class ActiveRecord::FixtureSet::File include ::Enumerable @@ -20390,7 +22629,7 @@ end # possibly in a folder with the same name. # ++ # -# source://activerecord//lib/active_record/fixtures.rb#464 +# source://activerecord//lib/active_record/fixtures.rb#539 ActiveRecord::FixtureSet::MAX_ID = T.let(T.unsafe(nil), Integer) # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#5 @@ -20400,12 +22639,18 @@ class ActiveRecord::FixtureSet::ModelMetadata # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#6 def initialize(model_class); end + # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#29 + def column_names; end + + # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#18 + def column_type(column_name); end + # @return [Boolean] # - # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#18 - def has_primary_key_column?; end + # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#25 + def has_column?(column_name); end - # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#27 + # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#37 def inheritance_column_name; end # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#10 @@ -20414,17 +22659,17 @@ class ActiveRecord::FixtureSet::ModelMetadata # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#14 def primary_key_type; end - # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#23 + # source://activerecord//lib/active_record/fixture_set/model_metadata.rb#33 def timestamp_column_names; end end # NOTE: This class has to be defined in compact style in # order for rendering context subclassing to work correctly. # -# source://activerecord//lib/active_record/fixture_set/render_context.rb#5 +# source://activerecord//lib/active_record/fixture_set/render_context.rb#7 class ActiveRecord::FixtureSet::RenderContext class << self - # source://activerecord//lib/active_record/fixture_set/render_context.rb#6 + # source://activerecord//lib/active_record/fixture_set/render_context.rb#8 def create_subclass; end end end @@ -20441,15 +22686,23 @@ class ActiveRecord::FixtureSet::TableRow private - # source://activerecord//lib/active_record/fixture_set/table_row.rb#165 + # source://activerecord//lib/active_record/fixture_set/table_row.rb#186 def add_join_records(association); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/fixture_set/table_row.rb#136 + def column_defined?(col); end + # source://activerecord//lib/active_record/fixture_set/table_row.rb#86 def fill_row_model_attributes; end # source://activerecord//lib/active_record/fixture_set/table_row.rb#103 def fill_timestamps; end + # source://activerecord//lib/active_record/fixture_set/table_row.rb#127 + def generate_composite_primary_key; end + # source://activerecord//lib/active_record/fixture_set/table_row.rb#119 def generate_primary_key; end @@ -20465,10 +22718,10 @@ class ActiveRecord::FixtureSet::TableRow # source://activerecord//lib/active_record/fixture_set/table_row.rb#95 def reflection_class; end - # source://activerecord//lib/active_record/fixture_set/table_row.rb#128 + # source://activerecord//lib/active_record/fixture_set/table_row.rb#140 def resolve_enums; end - # source://activerecord//lib/active_record/fixture_set/table_row.rb#136 + # source://activerecord//lib/active_record/fixture_set/table_row.rb#148 def resolve_sti_reflections; end end @@ -20545,197 +22798,222 @@ end class ActiveRecord::FutureResult # @return [FutureResult] a new instance of FutureResult # - # source://activerecord//lib/active_record/future_result.rb#33 + # source://activerecord//lib/active_record/future_result.rb#66 def initialize(pool, *args, **kwargs); end - # source://activerecord//lib/active_record/future_result.rb#57 + # source://activerecord//lib/active_record/future_result.rb#94 def cancel; end - # source://activerecord//lib/active_record/future_result.rb#29 + # @return [Boolean] + # + # source://activerecord//lib/active_record/future_result.rb#135 + def canceled?; end + + # source://activerecord//lib/active_record/future_result.rb#62 def empty?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/future_result.rb#53 + # source://activerecord//lib/active_record/future_result.rb#90 def execute!(connection); end - # source://activerecord//lib/active_record/future_result.rb#63 + # source://activerecord//lib/active_record/future_result.rb#100 def execute_or_skip; end # Returns the value of attribute lock_wait. # - # source://activerecord//lib/active_record/future_result.rb#31 + # source://activerecord//lib/active_record/future_result.rb#64 def lock_wait; end # @return [Boolean] # - # source://activerecord//lib/active_record/future_result.rb#94 + # source://activerecord//lib/active_record/future_result.rb#131 def pending?; end - # source://activerecord//lib/active_record/future_result.rb#81 + # source://activerecord//lib/active_record/future_result.rb#118 def result; end - # source://activerecord//lib/active_record/future_result.rb#48 + # source://activerecord//lib/active_record/future_result.rb#85 def schedule!(session); end - # source://activerecord//lib/active_record/future_result.rb#29 + # source://activerecord//lib/active_record/future_result.rb#81 + def then(&block); end + + # source://activerecord//lib/active_record/future_result.rb#62 def to_a(*_arg0, **_arg1, &_arg2); end private - # @return [Boolean] - # - # source://activerecord//lib/active_record/future_result.rb#99 - def canceled?; end - - # source://activerecord//lib/active_record/future_result.rb#126 + # source://activerecord//lib/active_record/future_result.rb#165 def exec_query(connection, *args, **kwargs); end - # source://activerecord//lib/active_record/future_result.rb#103 + # source://activerecord//lib/active_record/future_result.rb#140 def execute_or_wait; end - # source://activerecord//lib/active_record/future_result.rb#118 + # source://activerecord//lib/active_record/future_result.rb#157 def execute_query(connection, async: T.unsafe(nil)); end + + class << self + # source://activerecord//lib/active_record/future_result.rb#53 + def wrap(result); end + end end -# source://activerecord//lib/active_record/future_result.rb#27 +# source://activerecord//lib/active_record/future_result.rb#51 class ActiveRecord::FutureResult::Canceled < ::ActiveRecord::ActiveRecordError; end # source://activerecord//lib/active_record/future_result.rb#5 +class ActiveRecord::FutureResult::Complete + # @return [Complete] a new instance of Complete + # + # source://activerecord//lib/active_record/future_result.rb#9 + def initialize(result); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/future_result.rb#17 + def canceled?; end + + # source://activerecord//lib/active_record/future_result.rb#7 + def empty?(*_arg0, **_arg1, &_arg2); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/future_result.rb#13 + def pending?; end + + # Returns the value of attribute result. + # + # source://activerecord//lib/active_record/future_result.rb#6 + def result; end + + # source://activerecord//lib/active_record/future_result.rb#21 + def then(&block); end + + # source://activerecord//lib/active_record/future_result.rb#7 + def to_a(*_arg0, **_arg1, &_arg2); end +end + +# source://activerecord//lib/active_record/future_result.rb#26 class ActiveRecord::FutureResult::EventBuffer # @return [EventBuffer] a new instance of EventBuffer # - # source://activerecord//lib/active_record/future_result.rb#6 + # source://activerecord//lib/active_record/future_result.rb#27 def initialize(future_result, instrumenter); end - # source://activerecord//lib/active_record/future_result.rb#18 + # source://activerecord//lib/active_record/future_result.rb#42 def flush; end - # source://activerecord//lib/active_record/future_result.rb#12 + # source://activerecord//lib/active_record/future_result.rb#33 def instrument(name, payload = T.unsafe(nil), &block); end end -# source://activerecord//lib/active_record/future_result.rb#130 +# source://activerecord//lib/active_record/future_result.rb#169 class ActiveRecord::FutureResult::SelectAll < ::ActiveRecord::FutureResult private - # source://activerecord//lib/active_record/future_result.rb#132 + # source://activerecord//lib/active_record/future_result.rb#171 def exec_query(*_arg0, **_arg1); end end -# source://activerecord//lib/active_record/associations.rb#74 +# source://activerecord//lib/active_record/associations/errors.rb#74 class ActiveRecord::HasManyThroughAssociationNotFoundError < ::ActiveRecord::ActiveRecordError include ::DidYouMean::Correctable # @return [HasManyThroughAssociationNotFoundError] a new instance of HasManyThroughAssociationNotFoundError # - # source://activerecord//lib/active_record/associations.rb#77 + # source://activerecord//lib/active_record/associations/errors.rb#77 def initialize(owner_class = T.unsafe(nil), reflection = T.unsafe(nil)); end - # source://activerecord//lib/active_record/associations.rb#90 + # source://activerecord//lib/active_record/associations/errors.rb#90 def corrections; end # Returns the value of attribute owner_class. # - # source://activerecord//lib/active_record/associations.rb#75 + # source://activerecord//lib/active_record/associations/errors.rb#75 def owner_class; end # Returns the value of attribute reflection. # - # source://activerecord//lib/active_record/associations.rb#75 + # source://activerecord//lib/active_record/associations/errors.rb#75 def reflection; end end -# source://activerecord//lib/active_record/associations.rb#124 +# source://activerecord//lib/active_record/associations/errors.rb#124 class ActiveRecord::HasManyThroughAssociationPointlessSourceTypeError < ::ActiveRecord::ActiveRecordError # @return [HasManyThroughAssociationPointlessSourceTypeError] a new instance of HasManyThroughAssociationPointlessSourceTypeError # - # source://activerecord//lib/active_record/associations.rb#125 + # source://activerecord//lib/active_record/associations/errors.rb#125 def initialize(owner_class_name = T.unsafe(nil), reflection = T.unsafe(nil), source_reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#104 +# source://activerecord//lib/active_record/associations/errors.rb#104 class ActiveRecord::HasManyThroughAssociationPolymorphicSourceError < ::ActiveRecord::ActiveRecordError # @return [HasManyThroughAssociationPolymorphicSourceError] a new instance of HasManyThroughAssociationPolymorphicSourceError # - # source://activerecord//lib/active_record/associations.rb#105 + # source://activerecord//lib/active_record/associations/errors.rb#105 def initialize(owner_class_name = T.unsafe(nil), reflection = T.unsafe(nil), source_reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#114 +# source://activerecord//lib/active_record/associations/errors.rb#114 class ActiveRecord::HasManyThroughAssociationPolymorphicThroughError < ::ActiveRecord::ActiveRecordError # @return [HasManyThroughAssociationPolymorphicThroughError] a new instance of HasManyThroughAssociationPolymorphicThroughError # - # source://activerecord//lib/active_record/associations.rb#115 + # source://activerecord//lib/active_record/associations/errors.rb#115 def initialize(owner_class_name = T.unsafe(nil), reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#202 +# source://activerecord//lib/active_record/associations/errors.rb#218 class ActiveRecord::HasManyThroughCantAssociateThroughHasOneOrManyReflection < ::ActiveRecord::ThroughCantAssociateThroughHasOneOrManyReflection; end -# source://activerecord//lib/active_record/associations.rb#218 +# source://activerecord//lib/active_record/associations/errors.rb#234 class ActiveRecord::HasManyThroughNestedAssociationsAreReadonly < ::ActiveRecord::ThroughNestedAssociationsAreReadonly; end -# source://activerecord//lib/active_record/associations.rb#167 +# source://activerecord//lib/active_record/associations/errors.rb#167 class ActiveRecord::HasManyThroughOrderError < ::ActiveRecord::ActiveRecordError # @return [HasManyThroughOrderError] a new instance of HasManyThroughOrderError # - # source://activerecord//lib/active_record/associations.rb#168 + # source://activerecord//lib/active_record/associations/errors.rb#168 def initialize(owner_class_name = T.unsafe(nil), reflection = T.unsafe(nil), through_reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#154 +# source://activerecord//lib/active_record/associations/errors.rb#154 class ActiveRecord::HasManyThroughSourceAssociationNotFoundError < ::ActiveRecord::ActiveRecordError # @return [HasManyThroughSourceAssociationNotFoundError] a new instance of HasManyThroughSourceAssociationNotFoundError # - # source://activerecord//lib/active_record/associations.rb#155 + # source://activerecord//lib/active_record/associations/errors.rb#155 def initialize(reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#144 +# source://activerecord//lib/active_record/associations/errors.rb#144 class ActiveRecord::HasOneAssociationPolymorphicThroughError < ::ActiveRecord::ActiveRecordError # @return [HasOneAssociationPolymorphicThroughError] a new instance of HasOneAssociationPolymorphicThroughError # - # source://activerecord//lib/active_record/associations.rb#145 + # source://activerecord//lib/active_record/associations/errors.rb#145 def initialize(owner_class_name = T.unsafe(nil), reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#134 +# source://activerecord//lib/active_record/associations/errors.rb#134 class ActiveRecord::HasOneThroughCantAssociateThroughCollection < ::ActiveRecord::ActiveRecordError # @return [HasOneThroughCantAssociateThroughCollection] a new instance of HasOneThroughCantAssociateThroughCollection # - # source://activerecord//lib/active_record/associations.rb#135 + # source://activerecord//lib/active_record/associations/errors.rb#135 def initialize(owner_class_name = T.unsafe(nil), reflection = T.unsafe(nil), through_reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#205 +# source://activerecord//lib/active_record/associations/errors.rb#221 class ActiveRecord::HasOneThroughCantAssociateThroughHasOneOrManyReflection < ::ActiveRecord::ThroughCantAssociateThroughHasOneOrManyReflection; end -# source://activerecord//lib/active_record/associations.rb#221 +# source://activerecord//lib/active_record/associations/errors.rb#237 class ActiveRecord::HasOneThroughNestedAssociationsAreReadonly < ::ActiveRecord::ThroughNestedAssociationsAreReadonly; end -# source://activerecord//lib/active_record/migration.rb#123 +# source://activerecord//lib/active_record/migration.rb#124 class ActiveRecord::IllegalMigrationNameError < ::ActiveRecord::MigrationError # @return [IllegalMigrationNameError] a new instance of IllegalMigrationNameError # - # source://activerecord//lib/active_record/migration.rb#124 + # source://activerecord//lib/active_record/migration.rb#125 def initialize(name = T.unsafe(nil)); end end -# Raised when a relation cannot be mutated because it's already loaded. -# -# class Task < ActiveRecord::Base -# end -# -# relation = Task.all -# relation.loaded? # => true -# -# # Methods which try to mutate a loaded relation fail. -# relation.where!(title: 'TODO') # => ActiveRecord::ImmutableRelation -# relation.limit!(5) # => ActiveRecord::ImmutableRelation -# -# source://activerecord//lib/active_record/errors.rb#401 -class ActiveRecord::ImmutableRelation < ::ActiveRecord::ActiveRecordError; end - -# == Single table inheritance +# = Single table inheritance # # Active Record allows inheritance by storing the name of the class in a column that by # default is named "type" (can be changed by overwriting Base.inheritance_column). @@ -20763,10 +23041,11 @@ class ActiveRecord::ImmutableRelation < ::ActiveRecord::ActiveRecordError; end # be triggered. In that case, it'll work just like normal subclasses with no special magic # for differentiating between them or reloading the right type with find. # -# Note, all the attributes for all the cases are kept in the same table. Read more: -# https://www.martinfowler.com/eaaCatalog/singleTableInheritance.html +# Note, all the attributes for all the cases are kept in the same table. +# Read more: +# * https://www.martinfowler.com/eaaCatalog/singleTableInheritance.html # -# source://activerecord//lib/active_record/inheritance.rb#38 +# source://activerecord//lib/active_record/inheritance.rb#39 module ActiveRecord::Inheritance extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -20781,13 +23060,13 @@ module ActiveRecord::Inheritance # do Reply.new without having to set Reply[Reply.inheritance_column] = "Reply" yourself. # No such attribute would be set for objects of the Message class in that example. # - # source://activerecord//lib/active_record/inheritance.rb#343 + # source://activerecord//lib/active_record/inheritance.rb#359 def ensure_proper_type; end - # source://activerecord//lib/active_record/inheritance.rb#327 + # source://activerecord//lib/active_record/inheritance.rb#343 def initialize_dup(other); end - # source://activerecord//lib/active_record/inheritance.rb#333 + # source://activerecord//lib/active_record/inheritance.rb#349 def initialize_internals_callback; end module GeneratedClassMethods @@ -20807,7 +23086,7 @@ module ActiveRecord::Inheritance end end -# source://activerecord//lib/active_record/inheritance.rb#51 +# source://activerecord//lib/active_record/inheritance.rb#52 module ActiveRecord::Inheritance::ClassMethods # Set this to +true+ if this is an abstract class (see # abstract_class?). @@ -20816,7 +23095,7 @@ module ActiveRecord::Inheritance::ClassMethods # true. # +ApplicationRecord+, for example, is generated as an abstract class. # - # Consider the following default behaviour: + # Consider the following default behavior: # # Shape = Class.new(ActiveRecord::Base) # Polygon = Class.new(Shape) @@ -20851,7 +23130,7 @@ module ActiveRecord::Inheritance::ClassMethods # stay in the hierarchy, and Active Record will continue to correctly # derive the table name. # - # source://activerecord//lib/active_record/inheritance.rb#153 + # source://activerecord//lib/active_record/inheritance.rb#164 def abstract_class; end # Set this to +true+ if this is an abstract class (see @@ -20861,7 +23140,7 @@ module ActiveRecord::Inheritance::ClassMethods # true. # +ApplicationRecord+, for example, is generated as an abstract class. # - # Consider the following default behaviour: + # Consider the following default behavior: # # Shape = Class.new(ActiveRecord::Base) # Polygon = Class.new(Shape) @@ -20896,26 +23175,36 @@ module ActiveRecord::Inheritance::ClassMethods # stay in the hierarchy, and Active Record will continue to correctly # derive the table name. # - # source://activerecord//lib/active_record/inheritance.rb#153 + # source://activerecord//lib/active_record/inheritance.rb#164 def abstract_class=(_arg0); end # Returns whether this class is an abstract class or not. # # @return [Boolean] # - # source://activerecord//lib/active_record/inheritance.rb#156 + # source://activerecord//lib/active_record/inheritance.rb#167 def abstract_class?; end - # Returns the class descending directly from ActiveRecord::Base, or - # an abstract class, if any, in the inheritance hierarchy. + # Returns the first class in the inheritance hierarchy that descends from either an + # abstract class or from ActiveRecord::Base. + # + # Consider the following behaviour: # - # If A extends ActiveRecord::Base, A.base_class will return A. If B descends from A - # through some arbitrarily deep hierarchy, B.base_class will return A. + # class ApplicationRecord < ActiveRecord::Base + # self.abstract_class = true + # end + # class Shape < ApplicationRecord + # self.abstract_class = true + # end + # Polygon = Class.new(Shape) + # Square = Class.new(Polygon) # - # If B < A and C < B and if A is an abstract_class then both B.base_class - # and C.base_class would return B as the answer since A is an abstract_class. + # ApplicationRecord.base_class # => ApplicationRecord + # Shape.base_class # => Shape + # Polygon.base_class # => Polygon + # Square.base_class # => Polygon # - # source://activerecord//lib/active_record/inheritance.rb#104 + # source://activerecord//lib/active_record/inheritance.rb#115 def base_class; end # Returns whether the class is a base class. @@ -20923,7 +23212,7 @@ module ActiveRecord::Inheritance::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/inheritance.rb#108 + # source://activerecord//lib/active_record/inheritance.rb#119 def base_class?; end # Returns +true+ if this does not need STI type condition. Returns @@ -20931,37 +23220,34 @@ module ActiveRecord::Inheritance::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/inheritance.rb#81 + # source://activerecord//lib/active_record/inheritance.rb#82 def descends_from_active_record?; end - # source://activerecord//lib/active_record/inheritance.rb#219 + # source://activerecord//lib/active_record/inheritance.rb#226 def dup; end # @return [Boolean] # - # source://activerecord//lib/active_record/inheritance.rb#91 + # source://activerecord//lib/active_record/inheritance.rb#92 def finder_needs_type_condition?; end - # source://activerecord//lib/active_record/inheritance.rb#213 - def inherited(subclass); end - # Determines if one of the attributes passed in is the inheritance column, # and if the inheritance column is attr accessible, it initializes an # instance of the given subclass instead of the base class. # - # source://activerecord//lib/active_record/inheritance.rb#55 + # source://activerecord//lib/active_record/inheritance.rb#56 def new(attributes = T.unsafe(nil), &block); end # Returns the class for the provided +name+. # # It is used to find the class correspondent to the value stored in the polymorphic type column. # - # source://activerecord//lib/active_record/inheritance.rb#205 + # source://activerecord//lib/active_record/inheritance.rb#218 def polymorphic_class_for(name); end # Returns the value to be stored in the polymorphic type column for Polymorphic Associations. # - # source://activerecord//lib/active_record/inheritance.rb#198 + # source://activerecord//lib/active_record/inheritance.rb#211 def polymorphic_name; end # Sets the application record class for Active Record @@ -20971,19 +23257,19 @@ module ActiveRecord::Inheritance::ClassMethods # will share a database connection with Active Record. It is the class # that connects to your primary database. # - # source://activerecord//lib/active_record/inheritance.rb#166 + # source://activerecord//lib/active_record/inheritance.rb#177 def primary_abstract_class; end # Returns the class for the provided +type_name+. # # It is used to find the class correspondent to the value stored in the inheritance column. # - # source://activerecord//lib/active_record/inheritance.rb#183 + # source://activerecord//lib/active_record/inheritance.rb#194 def sti_class_for(type_name); end # Returns the value to be stored in the inheritance column for STI. # - # source://activerecord//lib/active_record/inheritance.rb#176 + # source://activerecord//lib/active_record/inheritance.rb#187 def sti_name; end protected @@ -20991,10 +23277,10 @@ module ActiveRecord::Inheritance::ClassMethods # Returns the class type of the record using the current module as a prefix. So descendants of # MyApp::Business::Account would appear as MyApp::Business::AccountSubclass. # - # source://activerecord//lib/active_record/inheritance.rb#235 + # source://activerecord//lib/active_record/inheritance.rb#242 def compute_type(type_name); end - # source://activerecord//lib/active_record/inheritance.rb#263 + # source://activerecord//lib/active_record/inheritance.rb#270 def set_base_class; end private @@ -21003,44 +23289,46 @@ module ActiveRecord::Inheritance::ClassMethods # record instance. For single-table inheritance, we check the record # for a +type+ column and return the corresponding class. # - # source://activerecord//lib/active_record/inheritance.rb#283 + # source://activerecord//lib/active_record/inheritance.rb#299 def discriminate_class_for_record(record); end - # source://activerecord//lib/active_record/inheritance.rb#295 + # source://activerecord//lib/active_record/inheritance.rb#311 def find_sti_class(type_name); end - # source://activerecord//lib/active_record/inheritance.rb#227 + # source://activerecord//lib/active_record/inheritance.rb#287 + def inherited(subclass); end + + # source://activerecord//lib/active_record/inheritance.rb#234 def initialize_clone(other); end # Detect the subclass from the inheritance column of attrs. If the inheritance column value # is not self or a valid subclass, raises ActiveRecord::SubclassNotFound # - # source://activerecord//lib/active_record/inheritance.rb#315 + # source://activerecord//lib/active_record/inheritance.rb#331 def subclass_from_attributes(attrs); end - # source://activerecord//lib/active_record/inheritance.rb#306 + # source://activerecord//lib/active_record/inheritance.rb#322 def type_condition(table = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/active_record/inheritance.rb#291 + # source://activerecord//lib/active_record/inheritance.rb#307 def using_single_table_inheritance?(record); end end # source://activerecord//lib/active_record/insert_all.rb#6 class ActiveRecord::InsertAll - # @raise [ArgumentError] # @return [InsertAll] a new instance of InsertAll # - # source://activerecord//lib/active_record/insert_all.rb#10 - def initialize(model, inserts, on_duplicate:, update_only: T.unsafe(nil), returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + # source://activerecord//lib/active_record/insert_all.rb#18 + def initialize(relation, connection, inserts, on_duplicate:, update_only: T.unsafe(nil), returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end # Returns the value of attribute connection. # # source://activerecord//lib/active_record/insert_all.rb#7 def connection; end - # source://activerecord//lib/active_record/insert_all.rb#37 + # source://activerecord//lib/active_record/insert_all.rb#48 def execute; end # Returns the value of attribute inserts. @@ -21053,12 +23341,12 @@ class ActiveRecord::InsertAll # source://activerecord//lib/active_record/insert_all.rb#7 def keys; end - # TODO: Consider remaining this method, as it only conditionally extends keys, not always + # TODO: Consider renaming this method, as it only conditionally extends keys, not always # - # source://activerecord//lib/active_record/insert_all.rb#80 + # source://activerecord//lib/active_record/insert_all.rb#92 def keys_including_timestamps; end - # source://activerecord//lib/active_record/insert_all.rb#61 + # source://activerecord//lib/active_record/insert_all.rb#73 def map_key_with_value; end # Returns the value of attribute model. @@ -21071,12 +23359,12 @@ class ActiveRecord::InsertAll # source://activerecord//lib/active_record/insert_all.rb#8 def on_duplicate; end - # source://activerecord//lib/active_record/insert_all.rb#48 + # source://activerecord//lib/active_record/insert_all.rb#61 def primary_keys; end # @return [Boolean] # - # source://activerecord//lib/active_record/insert_all.rb#75 + # source://activerecord//lib/active_record/insert_all.rb#87 def record_timestamps?; end # Returns the value of attribute returning. @@ -21086,7 +23374,7 @@ class ActiveRecord::InsertAll # @return [Boolean] # - # source://activerecord//lib/active_record/insert_all.rb#53 + # source://activerecord//lib/active_record/insert_all.rb#65 def skip_duplicates?; end # Returns the value of attribute unique_by. @@ -21094,12 +23382,12 @@ class ActiveRecord::InsertAll # source://activerecord//lib/active_record/insert_all.rb#8 def unique_by; end - # source://activerecord//lib/active_record/insert_all.rb#44 + # source://activerecord//lib/active_record/insert_all.rb#57 def updatable_columns; end # @return [Boolean] # - # source://activerecord//lib/active_record/insert_all.rb#57 + # source://activerecord//lib/active_record/insert_all.rb#69 def update_duplicates?; end # Returns the value of attribute update_only. @@ -21114,129 +23402,146 @@ class ActiveRecord::InsertAll private - # source://activerecord//lib/active_record/insert_all.rb#91 + # source://activerecord//lib/active_record/insert_all.rb#129 def configure_on_duplicate_update_logic; end # @return [Boolean] # - # source://activerecord//lib/active_record/insert_all.rb#105 + # source://activerecord//lib/active_record/insert_all.rb#145 def custom_update_sql_provided?; end # @raise [ArgumentError] # - # source://activerecord//lib/active_record/insert_all.rb#172 + # source://activerecord//lib/active_record/insert_all.rb#212 def disallow_raw_sql!(value); end - # source://activerecord//lib/active_record/insert_all.rb#133 + # source://activerecord//lib/active_record/insert_all.rb#173 def ensure_valid_options_for_connection!; end - # source://activerecord//lib/active_record/insert_all.rb#109 + # source://activerecord//lib/active_record/insert_all.rb#149 def find_unique_index_for(unique_by); end - # source://activerecord//lib/active_record/insert_all.rb#157 + # @return [Boolean] + # + # source://activerecord//lib/active_record/insert_all.rb#101 + def has_attribute_aliases?(attributes); end + + # source://activerecord//lib/active_record/insert_all.rb#197 def readonly_columns; end - # Returns the value of attribute scope_attributes. - # - # source://activerecord//lib/active_record/insert_all.rb#89 - def scope_attributes; end + # source://activerecord//lib/active_record/insert_all.rb#125 + def resolve_attribute_alias(attribute); end + + # source://activerecord//lib/active_record/insert_all.rb#114 + def resolve_attribute_aliases; end - # source://activerecord//lib/active_record/insert_all.rb#181 + # source://activerecord//lib/active_record/insert_all.rb#105 + def resolve_sti; end + + # source://activerecord//lib/active_record/insert_all.rb#221 def timestamps_for_create; end - # source://activerecord//lib/active_record/insert_all.rb#152 + # source://activerecord//lib/active_record/insert_all.rb#192 def to_sql; end - # source://activerecord//lib/active_record/insert_all.rb#161 + # source://activerecord//lib/active_record/insert_all.rb#201 def unique_by_columns; end - # source://activerecord//lib/active_record/insert_all.rb#128 + # source://activerecord//lib/active_record/insert_all.rb#169 def unique_indexes; end - # source://activerecord//lib/active_record/insert_all.rb#166 + # source://activerecord//lib/active_record/insert_all.rb#206 def verify_attributes(attributes); end + + class << self + # source://activerecord//lib/active_record/insert_all.rb#11 + def execute(relation, *_arg1, **_arg2, &_arg3); end + end end -# source://activerecord//lib/active_record/insert_all.rb#185 +# source://activerecord//lib/active_record/insert_all.rb#225 class ActiveRecord::InsertAll::Builder # @return [Builder] a new instance of Builder # - # source://activerecord//lib/active_record/insert_all.rb#190 + # source://activerecord//lib/active_record/insert_all.rb#230 def initialize(insert_all); end - # source://activerecord//lib/active_record/insert_all.rb#219 + # source://activerecord//lib/active_record/insert_all.rb#265 def conflict_target; end - # source://activerecord//lib/active_record/insert_all.rb#194 + # source://activerecord//lib/active_record/insert_all.rb#234 def into; end - # source://activerecord//lib/active_record/insert_all.rb#188 + # source://activerecord//lib/active_record/insert_all.rb#228 def keys(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/insert_all.rb#188 + # source://activerecord//lib/active_record/insert_all.rb#228 def keys_including_timestamps(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute model. # - # source://activerecord//lib/active_record/insert_all.rb#186 + # source://activerecord//lib/active_record/insert_all.rb#226 def model; end - # source://activerecord//lib/active_record/insert_all.rb#243 + # source://activerecord//lib/active_record/insert_all.rb#289 def raw_update_sql; end - # source://activerecord//lib/active_record/insert_all.rb#243 + # source://activerecord//lib/active_record/insert_all.rb#289 def raw_update_sql?; end - # source://activerecord//lib/active_record/insert_all.rb#188 + # source://activerecord//lib/active_record/insert_all.rb#228 def record_timestamps?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/insert_all.rb#209 + # source://activerecord//lib/active_record/insert_all.rb#249 def returning; end - # source://activerecord//lib/active_record/insert_all.rb#188 + # source://activerecord//lib/active_record/insert_all.rb#228 def skip_duplicates?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/insert_all.rb#233 + # source://activerecord//lib/active_record/insert_all.rb#279 def touch_model_timestamps_unless(&block); end - # source://activerecord//lib/active_record/insert_all.rb#229 + # source://activerecord//lib/active_record/insert_all.rb#275 def updatable_columns; end - # source://activerecord//lib/active_record/insert_all.rb#188 + # source://activerecord//lib/active_record/insert_all.rb#228 def update_duplicates?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/insert_all.rb#198 + # source://activerecord//lib/active_record/insert_all.rb#238 def values_list; end private - # source://activerecord//lib/active_record/insert_all.rb#256 + # source://activerecord//lib/active_record/insert_all.rb#302 def columns_list; end # Returns the value of attribute connection. # - # source://activerecord//lib/active_record/insert_all.rb#250 + # source://activerecord//lib/active_record/insert_all.rb#296 def connection; end # @raise [UnknownAttributeError] # - # source://activerecord//lib/active_record/insert_all.rb#260 + # source://activerecord//lib/active_record/insert_all.rb#306 def extract_types_from_columns_on(table_name, keys:); end - # source://activerecord//lib/active_record/insert_all.rb#269 + # source://activerecord//lib/active_record/insert_all.rb#315 def format_columns(columns); end # Returns the value of attribute insert_all. # - # source://activerecord//lib/active_record/insert_all.rb#250 + # source://activerecord//lib/active_record/insert_all.rb#296 def insert_all; end - # source://activerecord//lib/active_record/insert_all.rb#273 + # source://activerecord//lib/active_record/insert_all.rb#323 + def quote_column(column); end + + # source://activerecord//lib/active_record/insert_all.rb#319 def quote_columns(columns); end # @return [Boolean] # - # source://activerecord//lib/active_record/insert_all.rb#252 + # source://activerecord//lib/active_record/insert_all.rb#298 def touch_timestamp_attribute?(column_name); end end @@ -21253,7 +23558,7 @@ module ActiveRecord::Integration # Product.new.cache_key # => "products/new" # Product.find(5).cache_key # => "products/5" # - # If ActiveRecord::Base.cache_versioning is turned off, as it was in Rails 5.1 and earlier, + # If ActiveRecord::Base.cache_versioning is turned off, as it was in \Rails 5.1 and earlier, # the cache key will also include a version. # # Product.cache_versioning = false @@ -21333,7 +23638,7 @@ module ActiveRecord::Integration # https://github.com/postgres/postgres/commit/3e1beda2cde3495f41290e1ece5d544525810214 # to account for this we pad the output with zeros # - # source://activerecord//lib/active_record/integration.rb#197 + # source://activerecord//lib/active_record/integration.rb#200 def raw_timestamp_to_cache_version(timestamp); end module GeneratedClassMethods @@ -21399,123 +23704,127 @@ end # `use_metadata_table` to false in your database configuration. # # source://activerecord//lib/active_record/internal_metadata.rb#12 -class ActiveRecord::InternalMetadata < ::ActiveRecord::Base - include ::ActiveRecord::InternalMetadata::GeneratedAttributeMethods - include ::ActiveRecord::InternalMetadata::GeneratedAssociationMethods +class ActiveRecord::InternalMetadata + # @return [InternalMetadata] a new instance of InternalMetadata + # + # source://activerecord//lib/active_record/internal_metadata.rb#18 + def initialize(pool); end - class << self - # source://activerecord//lib/active_record/internal_metadata.rb#34 - def [](key); end + # source://activerecord//lib/active_record/internal_metadata.rb#47 + def [](key); end - # source://activerecord//lib/active_record/internal_metadata.rb#28 - def []=(key, value); end + # source://activerecord//lib/active_record/internal_metadata.rb#39 + def []=(key, value); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end + # Returns the value of attribute arel_table. + # + # source://activerecord//lib/active_record/internal_metadata.rb#16 + def arel_table; end - # Creates an internal metadata table with columns +key+ and +value+ - # - # source://activerecord//lib/active_record/internal_metadata.rb#41 - def create_table; end + # source://activerecord//lib/active_record/internal_metadata.rb#65 + def count; end - # source://activerecord//lib/active_record/enum.rb#116 - def defined_enums; end + # Creates an internal metadata table with columns +key+ and +value+ + # + # source://activerecord//lib/active_record/internal_metadata.rb#85 + def create_table; end - # source://activerecord//lib/active_record/internal_metadata.rb#53 - def drop_table; end + # source://activerecord//lib/active_record/internal_metadata.rb#74 + def create_table_and_set_flags(environment, schema_sha1 = T.unsafe(nil)); end - # @return [Boolean] - # - # source://activerecord//lib/active_record/internal_metadata.rb#16 - def enabled?; end + # source://activerecord//lib/active_record/internal_metadata.rb#57 + def delete_all_entries; end - # source://activerecord//lib/active_record/internal_metadata.rb#20 - def primary_key; end + # source://activerecord//lib/active_record/internal_metadata.rb#99 + def drop_table; end - # source://activerecord//lib/active_record/timestamp.rb#47 - def record_timestamps; end + # @return [Boolean] + # + # source://activerecord//lib/active_record/internal_metadata.rb#35 + def enabled?; end - # source://activerecord//lib/active_record/internal_metadata.rb#24 - def table_name; end - end -end + # source://activerecord//lib/active_record/internal_metadata.rb#23 + def primary_key; end -# source://activerecord//lib/active_record/internal_metadata.rb#0 -class ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation < ::ActiveRecord::AssociationRelation - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::InternalMetadata::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods -end + # @return [Boolean] + # + # source://activerecord//lib/active_record/internal_metadata.rb#107 + def table_exists?; end -# source://activerecord//lib/active_record/internal_metadata.rb#0 -class ActiveRecord::InternalMetadata::ActiveRecord_Associations_CollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::InternalMetadata::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods -end + # source://activerecord//lib/active_record/internal_metadata.rb#31 + def table_name; end -# source://activerecord//lib/active_record/internal_metadata.rb#0 -class ActiveRecord::InternalMetadata::ActiveRecord_DisableJoinsAssociationRelation < ::ActiveRecord::DisableJoinsAssociationRelation - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::InternalMetadata::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods -end + # source://activerecord//lib/active_record/internal_metadata.rb#27 + def value_key; end -# source://activerecord//lib/active_record/internal_metadata.rb#0 -class ActiveRecord::InternalMetadata::ActiveRecord_Relation < ::ActiveRecord::Relation - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::InternalMetadata::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods -end + private -# source://activerecord//lib/active_record/internal_metadata.rb#0 -module ActiveRecord::InternalMetadata::GeneratedAssociationMethods; end + # source://activerecord//lib/active_record/internal_metadata.rb#130 + def create_entry(connection, key, value); end -# source://activerecord//lib/active_record/internal_metadata.rb#0 -module ActiveRecord::InternalMetadata::GeneratedAttributeMethods; end + # source://activerecord//lib/active_record/internal_metadata.rb#126 + def current_time(connection); end -# source://activerecord//lib/active_record/internal_metadata.rb#0 -module ActiveRecord::InternalMetadata::GeneratedRelationMethods; end + # source://activerecord//lib/active_record/internal_metadata.rb#154 + def select_entry(connection, key); end + + # source://activerecord//lib/active_record/internal_metadata.rb#142 + def update_entry(connection, key, new_value); end + + # source://activerecord//lib/active_record/internal_metadata.rb#112 + def update_or_create_entry(connection, key, value); end +end + +# source://activerecord//lib/active_record/internal_metadata.rb#13 +class ActiveRecord::InternalMetadata::NullInternalMetadata; end # Raised when a record cannot be inserted or updated because it references a non-existent record, # or when a record cannot be deleted because a parent record references it. # -# source://activerecord//lib/active_record/errors.rb#179 +# source://activerecord//lib/active_record/errors.rb#221 class ActiveRecord::InvalidForeignKey < ::ActiveRecord::WrappedDatabaseException; end -# source://activerecord//lib/active_record/associations.rb#33 +# source://activerecord//lib/active_record/migration.rb#134 +class ActiveRecord::InvalidMigrationTimestampError < ::ActiveRecord::MigrationError + # @return [InvalidMigrationTimestampError] a new instance of InvalidMigrationTimestampError + # + # source://activerecord//lib/active_record/migration.rb#135 + def initialize(version = T.unsafe(nil), name = T.unsafe(nil)); end +end + +# source://activerecord//lib/active_record/associations/errors.rb#33 class ActiveRecord::InverseOfAssociationNotFoundError < ::ActiveRecord::ActiveRecordError include ::DidYouMean::Correctable # @return [InverseOfAssociationNotFoundError] a new instance of InverseOfAssociationNotFoundError # - # source://activerecord//lib/active_record/associations.rb#36 + # source://activerecord//lib/active_record/associations/errors.rb#36 def initialize(reflection = T.unsafe(nil), associated_class = T.unsafe(nil)); end # Returns the value of attribute associated_class. # - # source://activerecord//lib/active_record/associations.rb#34 + # source://activerecord//lib/active_record/associations/errors.rb#34 def associated_class; end - # source://activerecord//lib/active_record/associations.rb#49 + # source://activerecord//lib/active_record/associations/errors.rb#49 def corrections; end # Returns the value of attribute reflection. # - # source://activerecord//lib/active_record/associations.rb#34 + # source://activerecord//lib/active_record/associations/errors.rb#34 def reflection; end end -# source://activerecord//lib/active_record/associations.rb#62 +# source://activerecord//lib/active_record/associations/errors.rb#62 class ActiveRecord::InverseOfAssociationRecursiveError < ::ActiveRecord::ActiveRecordError # @return [InverseOfAssociationRecursiveError] a new instance of InverseOfAssociationRecursiveError # - # source://activerecord//lib/active_record/associations.rb#64 + # source://activerecord//lib/active_record/associations/errors.rb#64 def initialize(reflection = T.unsafe(nil)); end # Returns the value of attribute reflection. # - # source://activerecord//lib/active_record/associations.rb#63 + # source://activerecord//lib/active_record/associations/errors.rb#63 def reflection; end end @@ -21523,7 +23832,7 @@ end # For example the following migration is not reversible. # Rolling back this migration will raise an ActiveRecord::IrreversibleMigration error. # -# class IrreversibleMigrationExample < ActiveRecord::Migration[7.0] +# class IrreversibleMigrationExample < ActiveRecord::Migration[7.2] # def change # create_table :distributors do |t| # t.string :zipcode @@ -21541,7 +23850,7 @@ end # # 1. Define #up and #down methods instead of #change: # -# class ReversibleMigrationExample < ActiveRecord::Migration[7.0] +# class ReversibleMigrationExample < ActiveRecord::Migration[7.2] # def up # create_table :distributors do |t| # t.string :zipcode @@ -21566,7 +23875,7 @@ end # # 2. Use the #reversible method in #change method: # -# class ReversibleMigrationExample < ActiveRecord::Migration[7.0] +# class ReversibleMigrationExample < ActiveRecord::Migration[7.2] # def change # create_table :distributors do |t| # t.string :zipcode @@ -21591,13 +23900,13 @@ end # end # end # -# source://activerecord//lib/active_record/migration.rb#90 +# source://activerecord//lib/active_record/migration.rb#91 class ActiveRecord::IrreversibleMigration < ::ActiveRecord::MigrationError; end # IrreversibleOrderError is raised when a relation's order is too complex for # +reverse_order+ to automatically reverse. # -# source://activerecord//lib/active_record/errors.rb#441 +# source://activerecord//lib/active_record/errors.rb#549 class ActiveRecord::IrreversibleOrderError < ::ActiveRecord::ActiveRecordError; end # source://activerecord//lib/active_record/legacy_yaml_adapter.rb#4 @@ -21610,10 +23919,10 @@ end # LockWaitTimeout will be raised when lock wait timeout exceeded. # -# source://activerecord//lib/active_record/errors.rb#449 +# source://activerecord//lib/active_record/errors.rb#557 class ActiveRecord::LockWaitTimeout < ::ActiveRecord::StatementInvalid; end -# source://activerecord//lib/active_record.rb#134 +# source://activerecord//lib/active_record.rb#147 module ActiveRecord::Locking extend ::ActiveSupport::Autoload end @@ -21622,39 +23931,39 @@ end # `nil` values to `lock_version`, and not result in `ActiveRecord::StaleObjectError` # during update record. # -# source://activerecord//lib/active_record/locking/optimistic.rb#191 +# source://activerecord//lib/active_record/locking/optimistic.rb#206 class ActiveRecord::Locking::LockingType - # source://activerecord//lib/active_record/locking/optimistic.rb#196 + # source://activerecord//lib/active_record/locking/optimistic.rb#211 def deserialize(value); end - # source://activerecord//lib/active_record/locking/optimistic.rb#208 + # source://activerecord//lib/active_record/locking/optimistic.rb#223 def encode_with(coder); end - # source://activerecord//lib/active_record/locking/optimistic.rb#204 + # source://activerecord//lib/active_record/locking/optimistic.rb#219 def init_with(coder); end - # source://activerecord//lib/active_record/locking/optimistic.rb#200 + # source://activerecord//lib/active_record/locking/optimistic.rb#215 def serialize(value); end class << self - # source://activerecord//lib/active_record/locking/optimistic.rb#192 + # source://activerecord//lib/active_record/locking/optimistic.rb#207 def new(subtype); end end end -# == What is Optimistic Locking +# == What is \Optimistic \Locking # # Optimistic locking allows multiple users to access the same record for edits, and assumes a minimum of # conflicts with the data. It does this by checking whether another process has made changes to a record since -# it was opened, an ActiveRecord::StaleObjectError exception is thrown if that has occurred +# it was opened, an ActiveRecord::StaleObjectError exception is thrown if that has occurred # and the update is ignored. # -# Check out ActiveRecord::Locking::Pessimistic for an alternative. +# Check out +ActiveRecord::Locking::Pessimistic+ for an alternative. # # == Usage # # Active Record supports optimistic locking if the +lock_version+ field is present. Each update to the -# record increments the +lock_version+ column and the locking facilities ensure that records instantiated twice +# record increments the integer column +lock_version+ and the locking facilities ensure that records instantiated twice # will let the last one saved raise a +StaleObjectError+ if the first was also updated. Example: # # p1 = Person.find(1) @@ -21707,21 +24016,30 @@ module ActiveRecord::Locking::Optimistic private - # source://activerecord//lib/active_record/locking/optimistic.rb#73 + # source://activerecord//lib/active_record/locking/optimistic.rb#142 + def _clear_locking_column; end + + # source://activerecord//lib/active_record/locking/optimistic.rb#78 def _create_record(attribute_names = T.unsafe(nil)); end - # source://activerecord//lib/active_record/locking/optimistic.rb#137 + # source://activerecord//lib/active_record/locking/optimistic.rb#134 def _lock_value_for_database(locking_column); end - # source://activerecord//lib/active_record/locking/optimistic.rb#82 - def _touch_row(attribute_names, time); end + # source://activerecord//lib/active_record/locking/optimistic.rb#147 + def _query_constraints_hash; end # source://activerecord//lib/active_record/locking/optimistic.rb#87 + def _touch_row(attribute_names, time); end + + # source://activerecord//lib/active_record/locking/optimistic.rb#92 def _update_row(attribute_names, attempted_action = T.unsafe(nil)); end - # source://activerecord//lib/active_record/locking/optimistic.rb#120 + # source://activerecord//lib/active_record/locking/optimistic.rb#124 def destroy_row; end + # source://activerecord//lib/active_record/locking/optimistic.rb#72 + def initialize_dup(other); end + module GeneratedClassMethods def lock_optimistically; end def lock_optimistically=(value); end @@ -21734,19 +24052,16 @@ module ActiveRecord::Locking::Optimistic end end -# source://activerecord//lib/active_record/locking/optimistic.rb#145 +# source://activerecord//lib/active_record/locking/optimistic.rb#154 module ActiveRecord::Locking::Optimistic::ClassMethods - # source://activerecord//lib/active_record/locking/optimistic.rb#179 - def define_attribute(name, cast_type, **_arg2); end - # The version column used for optimistic locking. Defaults to +lock_version+. # - # source://activerecord//lib/active_record/locking/optimistic.rb#162 + # source://activerecord//lib/active_record/locking/optimistic.rb#171 def locking_column; end # Set the column to use for optimistic locking. Defaults to +lock_version+. # - # source://activerecord//lib/active_record/locking/optimistic.rb#156 + # source://activerecord//lib/active_record/locking/optimistic.rb#165 def locking_column=(value); end # Returns true if the +lock_optimistically+ flag is set to true @@ -21755,24 +24070,34 @@ module ActiveRecord::Locking::Optimistic::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/locking/optimistic.rb#151 + # source://activerecord//lib/active_record/locking/optimistic.rb#160 def locking_enabled?; end # Reset the column used for optimistic locking back to the +lock_version+ default. # - # source://activerecord//lib/active_record/locking/optimistic.rb#168 + # source://activerecord//lib/active_record/locking/optimistic.rb#174 def reset_locking_column; end # Make sure the lock version column gets updated when counters are # updated. # - # source://activerecord//lib/active_record/locking/optimistic.rb#174 + # source://activerecord//lib/active_record/locking/optimistic.rb#180 def update_counters(id, counters); end + + private + + # source://activerecord//lib/active_record/locking/optimistic.rb#186 + def hook_attribute_type(name, cast_type); end + + # source://activerecord//lib/active_record/locking/optimistic.rb#194 + def inherited(base); end end -# source://activerecord//lib/active_record/locking/optimistic.rb#146 +# source://activerecord//lib/active_record/locking/optimistic.rb#155 ActiveRecord::Locking::Optimistic::ClassMethods::DEFAULT_LOCKING_COLUMN = T.let(T.unsafe(nil), String) +# = \Pessimistic \Locking +# # Locking::Pessimistic provides support for row-level locking using # SELECT ... FOR UPDATE and other lock types. # @@ -21831,25 +24156,25 @@ ActiveRecord::Locking::Optimistic::ClassMethods::DEFAULT_LOCKING_COLUMN = T.let( # [PostgreSQL] # https://www.postgresql.org/docs/current/interactive/sql-select.html#SQL-FOR-UPDATE-SHARE # -# source://activerecord//lib/active_record/locking/pessimistic.rb#62 +# source://activerecord//lib/active_record/locking/pessimistic.rb#64 module ActiveRecord::Locking::Pessimistic # Obtain a row lock on this record. Reloads the record to obtain the requested # lock. Pass an SQL locking clause to append the end of the SELECT statement # or pass true for "FOR UPDATE" (the default, an exclusive row lock). Returns # the locked record. # - # source://activerecord//lib/active_record/locking/pessimistic.rb#67 + # source://activerecord//lib/active_record/locking/pessimistic.rb#69 def lock!(lock = T.unsafe(nil)); end - # Wraps the passed block in a transaction, locking the object - # before yielding. You can pass the SQL locking clause + # Wraps the passed block in a transaction, reloading the object with a + # lock before yielding. You can pass the SQL locking clause # as an optional argument (see #lock!). # # You can also pass options like requires_new:, isolation:, # and joinable: to the wrapping transaction (see # ActiveRecord::ConnectionAdapters::DatabaseStatements#transaction). # - # source://activerecord//lib/active_record/locking/pessimistic.rb#89 + # source://activerecord//lib/active_record/locking/pessimistic.rb#92 def with_lock(*args); end end @@ -21864,39 +24189,39 @@ class ActiveRecord::LogSubscriber < ::ActiveSupport::LogSubscriber # source://activerecord//lib/active_record/log_subscriber.rb#7 def backtrace_cleaner?; end - # source://activerecord//lib/active_record/log_subscriber.rb#30 + # source://activerecord//lib/active_record/log_subscriber.rb#18 def sql(event); end - # source://activerecord//lib/active_record/log_subscriber.rb#22 + # source://activerecord//lib/active_record/log_subscriber.rb#9 def strict_loading_violation(event); end private - # source://activerecord//lib/active_record/log_subscriber.rb#94 + # source://activerecord//lib/active_record/log_subscriber.rb#80 def colorize_payload_name(name, payload_name); end - # source://activerecord//lib/active_record/log_subscriber.rb#127 + # source://activerecord//lib/active_record/log_subscriber.rb#113 def debug(progname = T.unsafe(nil), &block); end # source://activerecord//lib/active_record/log_subscriber.rb#143 - def extract_query_source_location(locations); end - - # source://activerecord//lib/active_record/log_subscriber.rb#147 def filter(name, value); end - # source://activerecord//lib/active_record/log_subscriber.rb#135 + # source://activerecord//lib/active_record/log_subscriber.rb#121 def log_query_source; end - # source://activerecord//lib/active_record/log_subscriber.rb#123 + # source://activerecord//lib/active_record/log_subscriber.rb#109 def logger; end - # source://activerecord//lib/active_record/log_subscriber.rb#79 + # source://activerecord//lib/active_record/log_subscriber.rb#130 + def query_source_location; end + + # source://activerecord//lib/active_record/log_subscriber.rb#65 def render_bind(attr, value); end - # source://activerecord//lib/active_record/log_subscriber.rb#102 + # source://activerecord//lib/active_record/log_subscriber.rb#88 def sql_color(sql); end - # source://activerecord//lib/active_record/log_subscriber.rb#75 + # source://activerecord//lib/active_record/log_subscriber.rb#61 def type_casted_binds(casted_binds); end class << self @@ -21909,27 +24234,45 @@ class ActiveRecord::LogSubscriber < ::ActiveSupport::LogSubscriber # source://activerecord//lib/active_record/log_subscriber.rb#7 def backtrace_cleaner?; end - # source://activerecord//lib/active_record/log_subscriber.rb#17 - def reset_runtime; end - - # source://activerecord//lib/active_record/log_subscriber.rb#13 - def runtime; end - - # source://activerecord//lib/active_record/log_subscriber.rb#9 - def runtime=(value); end + # source://activesupport/7.2.0/lib/active_support/log_subscriber.rb#84 + def log_levels; end end end # source://activerecord//lib/active_record/log_subscriber.rb#5 ActiveRecord::LogSubscriber::IGNORE_PAYLOAD_NAMES = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record.rb#152 +# source://activerecord//lib/active_record/marshalling.rb#4 +module ActiveRecord::Marshalling + class << self + # Returns the value of attribute format_version. + # + # source://activerecord//lib/active_record/marshalling.rb#8 + def format_version; end + + # source://activerecord//lib/active_record/marshalling.rb#10 + def format_version=(version); end + end +end + +# source://activerecord//lib/active_record/marshalling.rb#23 +module ActiveRecord::Marshalling::Methods + # source://activerecord//lib/active_record/marshalling.rb#24 + def _marshal_dump_7_1; end + + # source://activerecord//lib/active_record/marshalling.rb#40 + def marshal_load(state); end +end + +# source://activerecord//lib/active_record.rb#165 module ActiveRecord::Middleware extend ::ActiveSupport::Autoload end +# = Database Selector \Middleware +# # The DatabaseSelector Middleware provides a framework for automatically -# swapping from the primary to the replica database connection. Rails +# swapping from the primary to the replica database connection. \Rails # provides a basic framework to determine when to swap and allows for # applications to write custom strategy classes to override the default # behavior. @@ -21939,14 +24282,14 @@ end # resolver context class that sets a value that helps the resolver class # decide when to switch. # -# Rails default middleware uses the request's session to set a timestamp +# \Rails default middleware uses the request's session to set a timestamp # that informs the application when to read from a primary or read from a # replica. # # To use the DatabaseSelector in your application with default settings, # run the provided generator. # -# bin/rails g active_record:multi_db +# $ bin/rails g active_record:multi_db # # This will create a file named +config/initializers/multi_db.rb+ with the # following contents: @@ -21975,38 +24318,33 @@ end class ActiveRecord::Middleware::DatabaseSelector # @return [DatabaseSelector] a new instance of DatabaseSelector # - # source://activerecord//lib/active_record/middleware/database_selector.rb#50 + # source://activerecord//lib/active_record/middleware/database_selector.rb#52 def initialize(app, resolver_klass = T.unsafe(nil), context_klass = T.unsafe(nil), options = T.unsafe(nil)); end # Middleware that determines which database connection to use in a multiple # database application. # - # source://activerecord//lib/active_record/middleware/database_selector.rb#61 + # source://activerecord//lib/active_record/middleware/database_selector.rb#63 def call(env); end # Returns the value of attribute context_klass. # - # source://activerecord//lib/active_record/middleware/database_selector.rb#57 + # source://activerecord//lib/active_record/middleware/database_selector.rb#59 def context_klass; end # Returns the value of attribute options. # - # source://activerecord//lib/active_record/middleware/database_selector.rb#57 + # source://activerecord//lib/active_record/middleware/database_selector.rb#59 def options; end # Returns the value of attribute resolver_klass. # - # source://activerecord//lib/active_record/middleware/database_selector.rb#57 + # source://activerecord//lib/active_record/middleware/database_selector.rb#59 def resolver_klass; end private - # @return [Boolean] - # - # source://activerecord//lib/active_record/middleware/database_selector.rb#84 - def reading_request?(request); end - - # source://activerecord//lib/active_record/middleware/database_selector.rb#70 + # source://activerecord//lib/active_record/middleware/database_selector.rb#72 def select_database(request, &blk); end end @@ -22046,6 +24384,11 @@ class ActiveRecord::Middleware::DatabaseSelector::Resolver # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#35 def read(&blk); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#51 + def reading_request?(request); end + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#47 def update_context(response); end @@ -22054,26 +24397,26 @@ class ActiveRecord::Middleware::DatabaseSelector::Resolver private - # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#52 + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#56 def read_from_primary(&blk); end # @return [Boolean] # - # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#74 + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#78 def read_from_primary?; end - # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#58 + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#62 def read_from_replica(&blk); end - # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#78 + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#82 def send_to_replica_delay; end # @return [Boolean] # - # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#82 + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#86 def time_since_last_write_ok?; end - # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#64 + # source://activerecord//lib/active_record/middleware/database_selector/resolver.rb#68 def write_to_primary; end class << self @@ -22129,8 +24472,10 @@ class ActiveRecord::Middleware::DatabaseSelector::Resolver::Session end end +# = Shard Selector \Middleware +# # The ShardSelector Middleware provides a framework for automatically -# swapping shards. Rails provides a basic framework to determine which +# swapping shards. \Rails provides a basic framework to determine which # shard to switch to and allows for applications to write custom strategies # for swapping if needed. # @@ -22154,32 +24499,32 @@ end # tenant.shard # } # -# source://activerecord//lib/active_record/middleware/shard_selector.rb#29 +# source://activerecord//lib/active_record/middleware/shard_selector.rb#31 class ActiveRecord::Middleware::ShardSelector # @return [ShardSelector] a new instance of ShardSelector # - # source://activerecord//lib/active_record/middleware/shard_selector.rb#30 + # source://activerecord//lib/active_record/middleware/shard_selector.rb#32 def initialize(app, resolver, options = T.unsafe(nil)); end - # source://activerecord//lib/active_record/middleware/shard_selector.rb#38 + # source://activerecord//lib/active_record/middleware/shard_selector.rb#40 def call(env); end # Returns the value of attribute options. # - # source://activerecord//lib/active_record/middleware/shard_selector.rb#36 + # source://activerecord//lib/active_record/middleware/shard_selector.rb#38 def options; end # Returns the value of attribute resolver. # - # source://activerecord//lib/active_record/middleware/shard_selector.rb#36 + # source://activerecord//lib/active_record/middleware/shard_selector.rb#38 def resolver; end private - # source://activerecord//lib/active_record/middleware/shard_selector.rb#49 + # source://activerecord//lib/active_record/middleware/shard_selector.rb#51 def selected_shard(request); end - # source://activerecord//lib/active_record/middleware/shard_selector.rb#53 + # source://activerecord//lib/active_record/middleware/shard_selector.rb#55 def set_shard(shard, &block); end end @@ -22195,7 +24540,7 @@ end # # Example of a simple migration: # -# class AddSsl < ActiveRecord::Migration[7.0] +# class AddSsl < ActiveRecord::Migration[7.2] # def up # add_column :accounts, :ssl_enabled, :boolean, default: true # end @@ -22215,7 +24560,7 @@ end # # Example of a more complex migration that also needs to initialize data: # -# class AddSystemSettings < ActiveRecord::Migration[7.0] +# class AddSystemSettings < ActiveRecord::Migration[7.2] # def up # create_table :system_settings do |t| # t.string :name @@ -22323,15 +24668,16 @@ end # == Irreversible transformations # # Some transformations are destructive in a manner that cannot be reversed. -# Migrations of that kind should raise an ActiveRecord::IrreversibleMigration +# Migrations of that kind should raise an ActiveRecord::IrreversibleMigration # exception in their +down+ method. # -# == Running migrations from within Rails +# == Running migrations from within \Rails # -# The Rails package has several tools to help create and apply migrations. +# The \Rails package has several tools to help create and apply migrations. # # To generate a new migration, you can use -# bin/rails generate migration MyNewMigration +# +# $ bin/rails generate migration MyNewMigration # # where MyNewMigration is the name of your migration. The generator will # create an empty migration file timestamp_my_new_migration.rb @@ -22340,10 +24686,10 @@ end # # There is a special syntactic shortcut to generate migrations that add fields to a table. # -# bin/rails generate migration add_fieldname_to_tablename fieldname:string +# $ bin/rails generate migration add_fieldname_to_tablename fieldname:string # # This will generate the file timestamp_add_fieldname_to_tablename.rb, which will look like this: -# class AddFieldnameToTablename < ActiveRecord::Migration[7.0] +# class AddFieldnameToTablename < ActiveRecord::Migration[7.2] # def change # add_column :tablenames, :fieldname, :string # end @@ -22362,14 +24708,14 @@ end # wish to rollback last few migrations. bin/rails db:rollback STEP=2 will rollback # the latest two migrations. # -# If any of the migrations throw an ActiveRecord::IrreversibleMigration exception, +# If any of the migrations throw an ActiveRecord::IrreversibleMigration exception, # that step will fail and you'll have some manual work to do. # # == More examples # # Not all migrations change the schema. Some just fix the data: # -# class RemoveEmptyTags < ActiveRecord::Migration[7.0] +# class RemoveEmptyTags < ActiveRecord::Migration[7.2] # def up # Tag.all.each { |tag| tag.destroy if tag.pages.empty? } # end @@ -22382,7 +24728,7 @@ end # # Others remove columns when they migrate up instead of down: # -# class RemoveUnnecessaryItemAttributes < ActiveRecord::Migration[7.0] +# class RemoveUnnecessaryItemAttributes < ActiveRecord::Migration[7.2] # def up # remove_column :items, :incomplete_items_count # remove_column :items, :completed_items_count @@ -22396,7 +24742,7 @@ end # # And sometimes you need to do something in SQL not abstracted directly by migrations: # -# class MakeJoinUnique < ActiveRecord::Migration[7.0] +# class MakeJoinUnique < ActiveRecord::Migration[7.2] # def up # execute "ALTER TABLE `pages_linked_pages` ADD UNIQUE `page_id_linked_page_id` (`page_id`,`linked_page_id`)" # end @@ -22413,7 +24759,7 @@ end # Base#reset_column_information in order to ensure that the model has the # latest column data from after the new column was added. Example: # -# class AddPeopleSalary < ActiveRecord::Migration[7.0] +# class AddPeopleSalary < ActiveRecord::Migration[7.2] # def up # add_column :people, :salary, :integer # Person.reset_column_information @@ -22429,7 +24775,7 @@ end # them to the console as they happen, along with benchmarks describing how # long each step took. # -# You can quiet them down by setting ActiveRecord::Migration.verbose = false. +# You can quiet them down by setting ActiveRecord::Migration.verbose = false. # # You can also insert your own messages and benchmarks by using the +say_with_time+ # method: @@ -22449,11 +24795,15 @@ end # # == Timestamped Migrations # -# By default, Rails generates migrations that look like: +# By default, \Rails generates migrations that look like: # # 20080717013526_your_migration_name.rb # -# The prefix is a generation timestamp (in UTC). +# The prefix is a generation timestamp (in UTC). Timestamps should not be +# modified manually. To validate that migration timestamps adhere to the +# format Active Record expects, you can use the following configuration option: +# +# config.active_record.validate_migration_timestamps = true # # If you'd prefer to use numeric prefixes, you can turn timestamped migrations # off by setting: @@ -22471,7 +24821,7 @@ end # To define a reversible migration, define the +change+ method in your # migration like this: # -# class TenderloveMigration < ActiveRecord::Migration[7.0] +# class TenderloveMigration < ActiveRecord::Migration[7.2] # def change # create_table(:horses) do |t| # t.column :content, :text @@ -22488,11 +24838,11 @@ end # as before. # # If a command cannot be reversed, an -# ActiveRecord::IrreversibleMigration exception will be raised when +# ActiveRecord::IrreversibleMigration exception will be raised when # the migration is moving down. # # For a list of commands that are reversible, please see -# ActiveRecord::Migration::CommandRecorder. +# +ActiveRecord::Migration::CommandRecorder+. # # == Transactional Migrations # @@ -22501,7 +24851,7 @@ end # can't execute inside a transaction though, and for these situations # you can turn the automatic transactions off. # -# class ChangeEnum < ActiveRecord::Migration[7.0] +# class ChangeEnum < ActiveRecord::Migration[7.2] # disable_ddl_transaction! # # def up @@ -22512,61 +24862,67 @@ end # Remember that you can still open your own transactions, even if you # are in a Migration with self.disable_ddl_transaction!. # -# source://activerecord//lib/active_record/migration.rb#547 +# source://activerecord//lib/active_record/migration.rb#574 class ActiveRecord::Migration # @return [Migration] a new instance of Migration # - # source://activerecord//lib/active_record/migration.rb#684 + # source://activerecord//lib/active_record/migration.rb#803 def initialize(name = T.unsafe(nil), version = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#883 + # source://activerecord//lib/active_record/migration.rb#1008 def announce(message); end - # source://activerecord//lib/active_record/migration.rb#914 + # source://activerecord//lib/active_record/migration.rb#1039 def connection; end - # source://activerecord//lib/active_record/migration.rb#937 + # source://activerecord//lib/active_record/migration.rb#1043 + def connection_pool; end + + # source://activerecord//lib/active_record/migration.rb#1064 def copy(destination, sources, options = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#677 + # source://activerecord//lib/active_record/migration.rb#790 def disable_ddl_transaction; end - # source://activerecord//lib/active_record/migration.rb#836 + # source://activerecord//lib/active_record/migration.rb#960 def down; end - # source://activerecord//lib/active_record/migration.rb#864 + # source://activerecord//lib/active_record/migration.rb#988 def exec_migration(conn, direction); end - # source://activerecord//lib/active_record/migration.rb#918 + # source://activerecord//lib/active_record/migration.rb#810 + def execution_strategy; end + + # source://activerecord//lib/active_record/migration.rb#1047 def method_missing(method, *arguments, **_arg2, &block); end # Execute this migration in the named direction # - # source://activerecord//lib/active_record/migration.rb#843 + # source://activerecord//lib/active_record/migration.rb#967 def migrate(direction); end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/migration.rb#682 + # source://activerecord//lib/active_record/migration.rb#801 def name; end # Sets the attribute name # # @param value the value to set the attribute name to. # - # source://activerecord//lib/active_record/migration.rb#682 + # source://activerecord//lib/active_record/migration.rb#801 def name=(_arg0); end # Determines the version number of the next migration. # - # source://activerecord//lib/active_record/migration.rb#1003 + # source://activerecord//lib/active_record/migration.rb#1131 def next_migration_number(number); end # Finds the correct table name given an Active Record object. # Uses the Active Record object's own table_name, or pre/suffix from the # options passed in. # - # source://activerecord//lib/active_record/migration.rb#994 + # source://activerecord//lib/active_record/migration.rb#1122 def proper_table_name(name, options = T.unsafe(nil)); end # Used to specify an operation that can be run in one direction or another. @@ -22578,7 +24934,7 @@ class ActiveRecord::Migration # when the three columns 'first_name', 'last_name' and 'full_name' exist, # even when migrating down: # - # class SplitNameMigration < ActiveRecord::Migration[7.0] + # class SplitNameMigration < ActiveRecord::Migration[7.2] # def change # add_column :users, :first_name, :string # add_column :users, :last_name, :string @@ -22596,7 +24952,7 @@ class ActiveRecord::Migration # end # end # - # source://activerecord//lib/active_record/migration.rb#788 + # source://activerecord//lib/active_record/migration.rb#912 def reversible; end # Reverses the migration commands for the given block and @@ -22606,7 +24962,7 @@ class ActiveRecord::Migration # and create the table 'apples' on the way up, and the reverse # on the way down. # - # class FixTLMigration < ActiveRecord::Migration[7.0] + # class FixTLMigration < ActiveRecord::Migration[7.2] # def change # revert do # create_table(:horses) do |t| @@ -22625,7 +24981,7 @@ class ActiveRecord::Migration # # require_relative "20121212123456_tenderlove_migration" # - # class FixupTLMigration < ActiveRecord::Migration[7.0] + # class FixupTLMigration < ActiveRecord::Migration[7.2] # def change # revert TenderloveMigration # @@ -22637,12 +24993,12 @@ class ActiveRecord::Migration # # This command can be nested. # - # source://activerecord//lib/active_record/migration.rb#731 + # source://activerecord//lib/active_record/migration.rb#855 def revert(*migration_classes, &block); end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#748 + # source://activerecord//lib/active_record/migration.rb#872 def reverting?; end # Runs the given migration classes. @@ -22651,33 +25007,33 @@ class ActiveRecord::Migration # - +:direction+ - Default is +:up+. # - +:revert+ - Default is +false+. # - # source://activerecord//lib/active_record/migration.rb#816 + # source://activerecord//lib/active_record/migration.rb#940 def run(*migration_classes); end # Takes a message argument and outputs it as is. # A second boolean argument can be passed to specify whether to indent or not. # - # source://activerecord//lib/active_record/migration.rb#891 + # source://activerecord//lib/active_record/migration.rb#1016 def say(message, subitem = T.unsafe(nil)); end # Outputs text along with how long it took to run its block. # If the block returns an integer it assumes it is the number of rows affected. # - # source://activerecord//lib/active_record/migration.rb#897 + # source://activerecord//lib/active_record/migration.rb#1022 def say_with_time(message); end # Takes a block as an argument and suppresses any output generated by the block. # - # source://activerecord//lib/active_record/migration.rb#907 + # source://activerecord//lib/active_record/migration.rb#1032 def suppress_messages; end # Builds a hash for use in ActiveRecord::Migration#proper_table_name using # the Active Record object's table_name prefix and suffix # - # source://activerecord//lib/active_record/migration.rb#1013 + # source://activerecord//lib/active_record/migration.rb#1141 def table_name_options(config = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#830 + # source://activerecord//lib/active_record/migration.rb#954 def up; end # Used to specify an operation that is only run when migrating up @@ -22686,7 +25042,7 @@ class ActiveRecord::Migration # In the following example, the new column +published+ will be given # the value +true+ for all existing records. # - # class AddPublishedToPosts < ActiveRecord::Migration[7.0] + # class AddPublishedToPosts < ActiveRecord::Migration[7.2] # def change # add_column :posts, :published, :boolean, default: false # up_only do @@ -22695,59 +25051,75 @@ class ActiveRecord::Migration # end # end # - # source://activerecord//lib/active_record/migration.rb#807 + # source://activerecord//lib/active_record/migration.rb#931 def up_only(&block); end - # source://activerecord//lib/active_record/migration.rb#681 + # :singleton-method: verbose + # + # Specifies if migrations will write the actions they are taking to the console as they + # happen, along with benchmarks describing how long each step took. Defaults to + # true. + # + # source://activerecord//lib/active_record/migration.rb#800 def verbose; end - # source://activerecord//lib/active_record/migration.rb#681 + # source://activerecord//lib/active_record/migration.rb#800 def verbose=(val); end # Returns the value of attribute version. # - # source://activerecord//lib/active_record/migration.rb#682 + # source://activerecord//lib/active_record/migration.rb#801 def version; end # Sets the attribute version # # @param value the value to set the attribute version to. # - # source://activerecord//lib/active_record/migration.rb#682 + # source://activerecord//lib/active_record/migration.rb#801 def version=(_arg0); end - # source://activerecord//lib/active_record/migration.rb#879 + # source://activerecord//lib/active_record/migration.rb#1004 def write(text = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/migration.rb#1029 + # source://activerecord//lib/active_record/migration.rb#1173 def command_recorder; end - # source://activerecord//lib/active_record/migration.rb#1021 + # source://activerecord//lib/active_record/migration.rb#1149 def execute_block; end + # source://activerecord//lib/active_record/migration.rb#1157 + def format_arguments(arguments); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration.rb#1169 + def internal_option?(option_name); end + class << self - # source://activerecord//lib/active_record/migration.rb#568 + # source://activerecord//lib/active_record/migration.rb#632 def [](version); end - # Raises ActiveRecord::PendingMigrationError error if any migrations are pending. - # - # @raise [ActiveRecord::PendingMigrationError] + # Raises ActiveRecord::PendingMigrationError error if any migrations are pending + # for all database configurations in an environment. # - # source://activerecord//lib/active_record/migration.rb#626 - def check_pending!(connection = T.unsafe(nil)); end + # source://activerecord//lib/active_record/migration.rb#700 + def check_all_pending!; end - # source://activerecord//lib/active_record/migration.rb#572 + # source://activerecord//lib/active_record/migration.rb#752 + def check_pending_migrations; end + + # source://activerecord//lib/active_record/migration.rb#636 def current_version; end - # source://activerecord//lib/active_record/migration.rb#618 + # source://activerecord//lib/active_record/migration.rb#691 def delegate; end - # source://activerecord//lib/active_record/migration.rb#618 + # source://activerecord//lib/active_record/migration.rb#691 def delegate=(_arg0); end - # source://activerecord//lib/active_record/migration.rb#619 + # source://activerecord//lib/active_record/migration.rb#692 def disable_ddl_transaction; end # Disable the transaction wrapping this migration. @@ -22755,67 +25127,92 @@ class ActiveRecord::Migration # # For more details read the {"Transactional Migrations" section above}[rdoc-ref:Migration]. # - # source://activerecord//lib/active_record/migration.rb#672 + # source://activerecord//lib/active_record/migration.rb#748 def disable_ddl_transaction!; end - # source://activerecord//lib/active_record/migration.rb#619 + # source://activerecord//lib/active_record/migration.rb#692 def disable_ddl_transaction=(_arg0); end - # source://activerecord//lib/active_record/migration.rb#556 + # source://activerecord//lib/active_record/migration.rb#620 def inherited(subclass); end - # source://activerecord//lib/active_record/migration.rb#630 + # source://activerecord//lib/active_record/migration.rb#716 def load_schema_if_pending!; end - # source://activerecord//lib/active_record/migration.rb#653 + # source://activerecord//lib/active_record/migration.rb#730 def maintain_test_schema!; end - # source://activerecord//lib/active_record/migration.rb#659 - def method_missing(name, *args, **_arg2, &block); end + # source://activerecord//lib/active_record/migration.rb#736 + def method_missing(name, *_arg1, **_arg2, &_arg3); end - # source://activerecord//lib/active_record/migration.rb#664 + # source://activerecord//lib/active_record/migration.rb#740 def migrate(direction); end - # source://activerecord//lib/active_record/migration.rb#621 + # source://activerecord//lib/active_record/migration.rb#694 def nearest_delegate; end - # source://activerecord//lib/active_record/migration.rb#681 + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration.rb#642 + def valid_version_format?(version_string); end + + # source://activerecord//lib/active_record/migration.rb#800 def verbose; end - # source://activerecord//lib/active_record/migration.rb#681 + # source://activerecord//lib/active_record/migration.rb#800 def verbose=(val); end + + private + + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration.rb#761 + def any_schema_needs_update?; end + + # source://activerecord//lib/active_record/migration.rb#767 + def db_configs_in_current_env; end + + # source://activerecord//lib/active_record/migration.rb#785 + def env; end + + # source://activerecord//lib/active_record/migration.rb#771 + def pending_migrations; end end end # This class is used to verify that all migrations have been run before # loading a web page if config.active_record.migration_error is set to +:page_load+. # -# source://activerecord//lib/active_record/migration.rb#580 +# source://activerecord//lib/active_record/migration.rb#651 class ActiveRecord::Migration::CheckPending # @return [CheckPending] a new instance of CheckPending # - # source://activerecord//lib/active_record/migration.rb#581 + # source://activerecord//lib/active_record/migration.rb#652 def initialize(app, file_watcher: T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#588 + # source://activerecord//lib/active_record/migration.rb#659 def call(env); end private - # source://activerecord//lib/active_record/migration.rb#607 + # source://activerecord//lib/active_record/migration.rb#678 def build_watcher(&block); end - # source://activerecord//lib/active_record/migration.rb#612 + # source://activerecord//lib/active_record/migration.rb#685 def connection; end end -# ActiveRecord::Migration::CommandRecorder records commands done during +# = \Migration Command Recorder +# +# +ActiveRecord::Migration::CommandRecorder+ records commands done during # a migration and knows how to reverse those commands. The CommandRecorder # knows how to invert the following commands: # # * add_column # * add_foreign_key # * add_check_constraint +# * add_exclusion_constraint +# * add_unique_constraint # * add_index # * add_reference # * add_timestamps @@ -22823,9 +25220,11 @@ end # * change_column_null # * change_column_comment (must supply a +:from+ and +:to+ option) # * change_table_comment (must supply a +:from+ and +:to+ option) +# * create_enum # * create_join_table # * create_table # * disable_extension +# * drop_enum (must supply a list of values) # * drop_join_table # * drop_table (must supply a block) # * enable_extension @@ -22833,110 +25232,127 @@ end # * remove_columns (must supply a +:type+ option) # * remove_foreign_key (must supply a second table) # * remove_check_constraint +# * remove_exclusion_constraint +# * remove_unique_constraint # * remove_index # * remove_reference # * remove_timestamps # * rename_column +# * rename_enum (must supply a +:to+ option) +# * rename_enum_value (must supply a +:from+ and +:to+ option) # * rename_index # * rename_table # -# source://activerecord//lib/active_record/migration/command_recorder.rb#35 +# source://activerecord//lib/active_record/migration/command_recorder.rb#45 class ActiveRecord::Migration::CommandRecorder include ::ActiveRecord::Migration::JoinTable include ::ActiveRecord::Migration::CommandRecorder::StraightReversions # @return [CommandRecorder] a new instance of CommandRecorder # - # source://activerecord//lib/active_record/migration/command_recorder.rb#50 + # source://activerecord//lib/active_record/migration/command_recorder.rb#63 def initialize(delegate = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def add_belongs_to(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def add_check_constraint(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def add_column(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def add_enum_value(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def add_exclusion_constraint(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def add_foreign_key(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def add_index(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def add_reference(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def add_timestamps(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def add_unique_constraint(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def change_column(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def change_column_comment(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def change_column_default(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def change_column_null(*args, **_arg1, &block); end - # @yield [delegate.update_table_definition(table_name, self)] - # - # source://activerecord//lib/active_record/migration/command_recorder.rb#119 + # source://activerecord//lib/active_record/migration/command_recorder.rb#132 def change_table(table_name, **options); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def change_table_comment(*args, **_arg1, &block); end # Returns the value of attribute commands. # - # source://activerecord//lib/active_record/migration/command_recorder.rb#48 + # source://activerecord//lib/active_record/migration/command_recorder.rb#61 def commands; end # Sets the attribute commands # # @param value the value to set the attribute commands to. # - # source://activerecord//lib/active_record/migration/command_recorder.rb#48 + # source://activerecord//lib/active_record/migration/command_recorder.rb#61 def commands=(_arg0); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def create_enum(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def create_join_table(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def create_table(*args, **_arg1, &block); end # Returns the value of attribute delegate. # - # source://activerecord//lib/active_record/migration/command_recorder.rb#48 + # source://activerecord//lib/active_record/migration/command_recorder.rb#61 def delegate; end # Sets the attribute delegate # # @param value the value to set the attribute delegate to. # - # source://activerecord//lib/active_record/migration/command_recorder.rb#48 + # source://activerecord//lib/active_record/migration/command_recorder.rb#61 def delegate=(_arg0); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def disable_extension(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def drop_enum(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def drop_join_table(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def drop_table(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def enable_extension(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def execute(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def execute_block(*args, **_arg1, &block); end # Returns the inverse of the given command. For example: @@ -22954,13 +25370,13 @@ class ActiveRecord::Migration::CommandRecorder # # @raise [IrreversibleMigration] # - # source://activerecord//lib/active_record/migration/command_recorder.rb#97 + # source://activerecord//lib/active_record/migration/command_recorder.rb#110 def inverse_of(command, args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_add_belongs_to(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_remove_belongs_to(args, &block); end # Record +command+. +command+ should be a method name and arguments. @@ -22968,43 +25384,55 @@ class ActiveRecord::Migration::CommandRecorder # # recorder.record(:method_name, [:arg1, :arg2]) # - # source://activerecord//lib/active_record/migration/command_recorder.rb#77 + # source://activerecord//lib/active_record/migration/command_recorder.rb#90 def record(*command, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_belongs_to(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_check_constraint(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_column(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_columns(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def remove_exclusion_constraint(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_foreign_key(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_index(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_reference(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def remove_timestamps(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def remove_unique_constraint(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def rename_column(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def rename_enum(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + def rename_enum_value(*args, **_arg1, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def rename_index(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def rename_table(*args, **_arg1, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#123 + # source://activerecord//lib/active_record/migration/command_recorder.rb#144 def replay(migration); end # While executing the given block, the recorded will be in reverting mode. @@ -23015,146 +25443,199 @@ class ActiveRecord::Migration::CommandRecorder # recorder.revert{ recorder.record(:rename_table, [:old, :new]) } # # same effect as recorder.record(:rename_table, [:new, :old]) # - # source://activerecord//lib/active_record/migration/command_recorder.rb#63 + # source://activerecord//lib/active_record/migration/command_recorder.rb#76 def revert; end # Returns the value of attribute reverting. # - # source://activerecord//lib/active_record/migration/command_recorder.rb#48 + # source://activerecord//lib/active_record/migration/command_recorder.rb#61 def reverting; end # Sets the attribute reverting # # @param value the value to set the attribute reverting to. # - # source://activerecord//lib/active_record/migration/command_recorder.rb#48 + # source://activerecord//lib/active_record/migration/command_recorder.rb#61 def reverting=(_arg0); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#110 + # source://activerecord//lib/active_record/migration/command_recorder.rb#123 def transaction(*args, **_arg1, &block); end private - # source://activerecord//lib/active_record/migration/command_recorder.rb#251 + # source://activerecord//lib/active_record/migration/command_recorder.rb#313 + def invert_add_check_constraint(args); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#274 + def invert_add_foreign_key(args); end + + # @raise [ActiveRecord::IrreversibleMigration] + # + # source://activerecord//lib/active_record/migration/command_recorder.rb#335 + def invert_add_unique_constraint(args); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#293 def invert_change_column_comment(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#222 + # source://activerecord//lib/active_record/migration/command_recorder.rb#259 def invert_change_column_default(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#232 + # source://activerecord//lib/active_record/migration/command_recorder.rb#269 def invert_change_column_null(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#261 + # source://activerecord//lib/active_record/migration/command_recorder.rb#303 def invert_change_table_comment(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#167 + # source://activerecord//lib/active_record/migration/command_recorder.rb#191 + def invert_create_table(args, &block); end + + # @raise [ActiveRecord::IrreversibleMigration] + # + # source://activerecord//lib/active_record/migration/command_recorder.rb#349 + def invert_drop_enum(args); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#198 def invert_drop_table(args, &block); end # @raise [ActiveRecord::IrreversibleMigration] # - # source://activerecord//lib/active_record/migration/command_recorder.rb#271 + # source://activerecord//lib/active_record/migration/command_recorder.rb#321 def invert_remove_check_constraint(args); end # @raise [ActiveRecord::IrreversibleMigration] # - # source://activerecord//lib/active_record/migration/command_recorder.rb#178 + # source://activerecord//lib/active_record/migration/command_recorder.rb#215 def invert_remove_column(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#183 + # source://activerecord//lib/active_record/migration/command_recorder.rb#220 def invert_remove_columns(args); end # @raise [ActiveRecord::IrreversibleMigration] # - # source://activerecord//lib/active_record/migration/command_recorder.rb#237 + # source://activerecord//lib/active_record/migration/command_recorder.rb#330 + def invert_remove_exclusion_constraint(args); end + + # @raise [ActiveRecord::IrreversibleMigration] + # + # source://activerecord//lib/active_record/migration/command_recorder.rb#279 def invert_remove_foreign_key(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#201 + # source://activerecord//lib/active_record/migration/command_recorder.rb#238 def invert_remove_index(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#196 + # @raise [ActiveRecord::IrreversibleMigration] + # + # source://activerecord//lib/active_record/migration/command_recorder.rb#342 + def invert_remove_unique_constraint(args); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#233 def invert_rename_column(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#191 + # source://activerecord//lib/active_record/migration/command_recorder.rb#355 + def invert_rename_enum(args); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#365 + def invert_rename_enum_value(args); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#228 def invert_rename_index(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#174 + # source://activerecord//lib/active_record/migration/command_recorder.rb#208 def invert_rename_table(args); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#156 + # source://activerecord//lib/active_record/migration/command_recorder.rb#180 def invert_transaction(args, &block); end # Forwards any missing method call to the \target. # - # source://activerecord//lib/active_record/migration/command_recorder.rb#281 - def method_missing(method, *args, **_arg2, &block); end + # source://activerecord//lib/active_record/migration/command_recorder.rb#380 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://activerecord//lib/active_record/migration/command_recorder.rb#276 + # source://activerecord//lib/active_record/migration/command_recorder.rb#375 def respond_to_missing?(method, _); end end -# source://activerecord//lib/active_record/migration/command_recorder.rb#36 +# source://activerecord//lib/active_record/migration/command_recorder.rb#46 ActiveRecord::Migration::CommandRecorder::ReversibleAndIrreversibleMethods = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/migration/command_recorder.rb#130 +# source://activerecord//lib/active_record/migration/command_recorder.rb#151 module ActiveRecord::Migration::CommandRecorder::StraightReversions - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_add_check_constraint(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_add_column(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 + def invert_add_exclusion_constraint(args, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_add_foreign_key(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_add_index(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_add_reference(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_add_timestamps(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 + def invert_add_unique_constraint(args, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 + def invert_create_enum(args, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_create_join_table(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_create_table(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_disable_extension(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 + def invert_drop_enum(args, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_drop_join_table(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_drop_table(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_enable_extension(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_execute_block(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_remove_check_constraint(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_remove_column(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 + def invert_remove_exclusion_constraint(args, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_remove_foreign_key(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_remove_index(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_remove_reference(args, &block); end - # source://activerecord//lib/active_record/migration/command_recorder.rb#146 + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 def invert_remove_timestamps(args, &block); end + + # source://activerecord//lib/active_record/migration/command_recorder.rb#170 + def invert_remove_unique_constraint(args, &block); end end # source://activerecord//lib/active_record/migration/compatibility.rb#5 @@ -23165,214 +25646,300 @@ module ActiveRecord::Migration::Compatibility end end -# source://activerecord//lib/active_record/migration/compatibility.rb#317 +# source://activerecord//lib/active_record/migration/compatibility.rb#413 class ActiveRecord::Migration::Compatibility::V4_2 < ::ActiveRecord::Migration::Compatibility::V5_0 - # source://activerecord//lib/active_record/migration/compatibility.rb#331 + # source://activerecord//lib/active_record/migration/compatibility.rb#431 def add_belongs_to(table_name, ref_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#331 + # source://activerecord//lib/active_record/migration/compatibility.rb#431 def add_reference(table_name, ref_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#337 + # source://activerecord//lib/active_record/migration/compatibility.rb#437 def add_timestamps(table_name, **options); end # @return [Boolean] # - # source://activerecord//lib/active_record/migration/compatibility.rb#342 + # source://activerecord//lib/active_record/migration/compatibility.rb#442 def index_exists?(table_name, column_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#353 + # source://activerecord//lib/active_record/migration/compatibility.rb#453 def remove_index(table_name, column_name = T.unsafe(nil), **options); end private - # source://activerecord//lib/active_record/migration/compatibility.rb#359 + # source://activerecord//lib/active_record/migration/compatibility.rb#459 def compatible_table_definition(t); end - # source://activerecord//lib/active_record/migration/compatibility.rb#366 + # source://activerecord//lib/active_record/migration/compatibility.rb#466 def index_name_for_remove(table_name, column_name, options); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#318 +# source://activerecord//lib/active_record/migration/compatibility.rb#414 module ActiveRecord::Migration::Compatibility::V4_2::TableDefinition - # source://activerecord//lib/active_record/migration/compatibility.rb#319 + # source://activerecord//lib/active_record/migration/compatibility.rb#415 def belongs_to(*_arg0, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#319 + # source://activerecord//lib/active_record/migration/compatibility.rb#415 def references(*_arg0, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#325 + # source://activerecord//lib/active_record/migration/compatibility.rb#421 def timestamps(**options); end + + private + + # source://activerecord//lib/active_record/migration/compatibility.rb#427 + def raise_on_if_exist_options(options); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#252 +# source://activerecord//lib/active_record/migration/compatibility.rb#344 class ActiveRecord::Migration::Compatibility::V5_0 < ::ActiveRecord::Migration::Compatibility::V5_1 - # source://activerecord//lib/active_record/migration/compatibility.rb#303 + # source://activerecord//lib/active_record/migration/compatibility.rb#399 def add_belongs_to(table_name, ref_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#293 + # source://activerecord//lib/active_record/migration/compatibility.rb#389 def add_column(table_name, column_name, type, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#303 + # source://activerecord//lib/active_record/migration/compatibility.rb#399 def add_reference(table_name, ref_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#288 + # source://activerecord//lib/active_record/migration/compatibility.rb#384 def create_join_table(table_1, table_2, column_options: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#265 + # source://activerecord//lib/active_record/migration/compatibility.rb#361 def create_table(table_name, **options); end private - # source://activerecord//lib/active_record/migration/compatibility.rb#309 + # source://activerecord//lib/active_record/migration/compatibility.rb#405 def compatible_table_definition(t); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#253 +# source://activerecord//lib/active_record/migration/compatibility.rb#345 module ActiveRecord::Migration::Compatibility::V5_0::TableDefinition - # source://activerecord//lib/active_record/migration/compatibility.rb#259 + # source://activerecord//lib/active_record/migration/compatibility.rb#351 def belongs_to(*args, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#254 + # source://activerecord//lib/active_record/migration/compatibility.rb#346 def primary_key(name, type = T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#259 + # source://activerecord//lib/active_record/migration/compatibility.rb#351 def references(*args, **options); end + + private + + # source://activerecord//lib/active_record/migration/compatibility.rb#357 + def raise_on_if_exist_options(options); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#231 +# source://activerecord//lib/active_record/migration/compatibility.rb#323 class ActiveRecord::Migration::Compatibility::V5_1 < ::ActiveRecord::Migration::Compatibility::V5_2 - # source://activerecord//lib/active_record/migration/compatibility.rb#232 + # source://activerecord//lib/active_record/migration/compatibility.rb#324 def change_column(table_name, column_name, type, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#243 + # source://activerecord//lib/active_record/migration/compatibility.rb#335 def create_table(table_name, **options); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#151 +# source://activerecord//lib/active_record/migration/compatibility.rb#267 class ActiveRecord::Migration::Compatibility::V5_2 < ::ActiveRecord::Migration::Compatibility::V6_0 - # source://activerecord//lib/active_record/migration/compatibility.rb#209 + # source://activerecord//lib/active_record/migration/compatibility.rb#301 def add_timestamps(table_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#193 - def change_table(table_name, **options); end - - # source://activerecord//lib/active_record/migration/compatibility.rb#201 - def create_join_table(table_1, table_2, **options); end - - # source://activerecord//lib/active_record/migration/compatibility.rb#185 - def create_table(table_name, **options); end - private - # source://activerecord//lib/active_record/migration/compatibility.rb#222 + # source://activerecord//lib/active_record/migration/compatibility.rb#314 def command_recorder; end - # source://activerecord//lib/active_record/migration/compatibility.rb#215 + # source://activerecord//lib/active_record/migration/compatibility.rb#307 def compatible_table_definition(t); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#171 +# source://activerecord//lib/active_record/migration/compatibility.rb#287 module ActiveRecord::Migration::Compatibility::V5_2::CommandRecorder - # source://activerecord//lib/active_record/migration/compatibility.rb#176 + # source://activerecord//lib/active_record/migration/compatibility.rb#292 def invert_change_column_comment(args); end - # source://activerecord//lib/active_record/migration/compatibility.rb#180 + # source://activerecord//lib/active_record/migration/compatibility.rb#296 def invert_change_table_comment(args); end - # source://activerecord//lib/active_record/migration/compatibility.rb#172 + # source://activerecord//lib/active_record/migration/compatibility.rb#288 def invert_transaction(args, &block); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#152 +# source://activerecord//lib/active_record/migration/compatibility.rb#268 module ActiveRecord::Migration::Compatibility::V5_2::TableDefinition - # source://activerecord//lib/active_record/migration/compatibility.rb#158 + # source://activerecord//lib/active_record/migration/compatibility.rb#274 def column(name, type, index: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#153 + # source://activerecord//lib/active_record/migration/compatibility.rb#269 def timestamps(**options); end private - # source://activerecord//lib/active_record/migration/compatibility.rb#167 + # source://activerecord//lib/active_record/migration/compatibility.rb#283 def raise_on_duplicate_column(name); end - # source://activerecord//lib/active_record/migration/compatibility.rb#164 + # source://activerecord//lib/active_record/migration/compatibility.rb#280 def raise_on_if_exist_options(options); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#88 +# source://activerecord//lib/active_record/migration/compatibility.rb#224 class ActiveRecord::Migration::Compatibility::V6_0 < ::ActiveRecord::Migration::Compatibility::V6_1 - # source://activerecord//lib/active_record/migration/compatibility.rb#132 + # source://activerecord//lib/active_record/migration/compatibility.rb#248 def add_belongs_to(table_name, ref_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#132 + # source://activerecord//lib/active_record/migration/compatibility.rb#248 def add_reference(table_name, ref_name, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#116 - def change_table(table_name, **options); end - - # source://activerecord//lib/active_record/migration/compatibility.rb#124 - def create_join_table(table_1, table_2, **options); end - - # source://activerecord//lib/active_record/migration/compatibility.rb#108 - def create_table(table_name, **options); end - private - # source://activerecord//lib/active_record/migration/compatibility.rb#143 + # source://activerecord//lib/active_record/migration/compatibility.rb#259 def compatible_table_definition(t); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#89 +# source://activerecord//lib/active_record/migration/compatibility.rb#225 class ActiveRecord::Migration::Compatibility::V6_0::ReferenceDefinition < ::ActiveRecord::ConnectionAdapters::ReferenceDefinition - # source://activerecord//lib/active_record/migration/compatibility.rb#90 + # source://activerecord//lib/active_record/migration/compatibility.rb#226 def index_options(table_name); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#95 +# source://activerecord//lib/active_record/migration/compatibility.rb#231 module ActiveRecord::Migration::Compatibility::V6_0::TableDefinition - # source://activerecord//lib/active_record/migration/compatibility.rb#96 + # source://activerecord//lib/active_record/migration/compatibility.rb#232 def belongs_to(*args, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#102 + # source://activerecord//lib/active_record/migration/compatibility.rb#238 def column(name, type, index: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#96 + # source://activerecord//lib/active_record/migration/compatibility.rb#232 def references(*args, **options); end + + private + + # source://activerecord//lib/active_record/migration/compatibility.rb#244 + def raise_on_if_exist_options(options); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#35 -class ActiveRecord::Migration::Compatibility::V6_1 < ::ActiveRecord::Migration::Current - # source://activerecord//lib/active_record/migration/compatibility.rb#50 +# source://activerecord//lib/active_record/migration/compatibility.rb#161 +class ActiveRecord::Migration::Compatibility::V6_1 < ::ActiveRecord::Migration::Compatibility::V7_0 + # source://activerecord//lib/active_record/migration/compatibility.rb#176 def add_column(table_name, column_name, type, **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#59 - def create_table(table_name, **options); end + # source://activerecord//lib/active_record/migration/compatibility.rb#185 + def change_column(table_name, column_name, type, **options); end private - # source://activerecord//lib/active_record/migration/compatibility.rb#80 + # source://activerecord//lib/active_record/migration/compatibility.rb#216 def compatible_table_definition(t); end end -# source://activerecord//lib/active_record/migration/compatibility.rb#36 +# source://activerecord//lib/active_record/migration/compatibility.rb#162 class ActiveRecord::Migration::Compatibility::V6_1::PostgreSQLCompat class << self - # source://activerecord//lib/active_record/migration/compatibility.rb#37 + # source://activerecord//lib/active_record/migration/compatibility.rb#163 def compatible_timestamp_type(type, connection); end end end -# source://activerecord//lib/active_record/migration/compatibility.rb#67 +# source://activerecord//lib/active_record/migration/compatibility.rb#194 module ActiveRecord::Migration::Compatibility::V6_1::TableDefinition - # source://activerecord//lib/active_record/migration/compatibility.rb#73 + # source://activerecord//lib/active_record/migration/compatibility.rb#200 + def change(name, type, index: T.unsafe(nil), **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#205 def column(name, type, index: T.unsafe(nil), **options); end - # source://activerecord//lib/active_record/migration/compatibility.rb#68 + # source://activerecord//lib/active_record/migration/compatibility.rb#195 def new_column_definition(name, type, **options); end + + private + + # source://activerecord//lib/active_record/migration/compatibility.rb#211 + def raise_on_if_exist_options(options); end +end + +# source://activerecord//lib/active_record/migration/compatibility.rb#37 +class ActiveRecord::Migration::Compatibility::V7_0 < ::ActiveRecord::Migration::Compatibility::V7_1 + include ::ActiveRecord::Migration::Compatibility::V7_0::LegacyIndexName + + # source://activerecord//lib/active_record/migration/compatibility.rb#107 + def add_belongs_to(table_name, ref_name, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#97 + def add_column(table_name, column_name, type, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#145 + def add_foreign_key(from_table, to_table, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#102 + def add_index(table_name, column_name, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#107 + def add_reference(table_name, ref_name, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#126 + def change_column(table_name, column_name, type, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#134 + def change_column_null(table_name, column_name, null, default = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#113 + def create_table(table_name, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#138 + def disable_extension(name, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#120 + def rename_table(table_name, new_name, **options); end + + private + + # source://activerecord//lib/active_record/migration/compatibility.rb#153 + def compatible_table_definition(t); end +end + +# source://activerecord//lib/active_record/migration/compatibility.rb#38 +module ActiveRecord::Migration::Compatibility::V7_0::LegacyIndexName + private + + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration/compatibility.rb#62 + def expression_column_name?(column_name); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#54 + def index_name_options(column_names); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#40 + def legacy_index_name(table_name, options); end end +# source://activerecord//lib/active_record/migration/compatibility.rb#67 +module ActiveRecord::Migration::Compatibility::V7_0::TableDefinition + include ::ActiveRecord::Migration::Compatibility::V7_0::LegacyIndexName + + # source://activerecord//lib/active_record/migration/compatibility.rb#75 + def change(name, type, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#70 + def column(name, type, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#80 + def index(column_name, **options); end + + # source://activerecord//lib/active_record/migration/compatibility.rb#85 + def references(*args, **options); end + + private + + # source://activerecord//lib/active_record/migration/compatibility.rb#91 + def raise_on_if_exist_options(options); end +end + +# source://activerecord//lib/active_record/migration/compatibility.rb#34 +class ActiveRecord::Migration::Compatibility::V7_1 < ::ActiveRecord::Migration::Current; end + # This file exists to ensure that old migrations run the same way they did before a Rails upgrade. # e.g. if you write a migration on Rails 6.1, then upgrade to Rails 7, the migration should do the same thing to your # database as it did when you were running Rails 6.1 @@ -23381,8 +25948,7 @@ end # New migration functionality that will never be backward compatible should be added directly to `ActiveRecord::Migration`. # # There are classes for each prior Rails version. Each class descends from the *next* Rails version, so: -# 6.1 < 7.0 -# 5.2 < 6.0 < 6.1 < 7.0 +# 5.2 < 6.0 < 6.1 < 7.0 < 7.1 < 7.2 # # If you are introducing new migration functionality that should only apply from Rails 7 onward, then you should # find the class that immediately precedes it (6.1), and override the relevant migration methods to undo your changes. @@ -23391,13 +25957,68 @@ end # class sets the value of `precision` to `nil` if it's not explicitly provided. This way, the default value will not apply # for migrations written for 5.2, but will for migrations written for 6.0. # -# source://activerecord//lib/active_record/migration/compatibility.rb#33 -ActiveRecord::Migration::Compatibility::V7_0 = ActiveRecord::Migration::Current +# source://activerecord//lib/active_record/migration/compatibility.rb#32 +ActiveRecord::Migration::Compatibility::V7_2 = ActiveRecord::Migration::Current # This must be defined before the inherited hook, below # -# source://activerecord//lib/active_record/migration.rb#553 -class ActiveRecord::Migration::Current < ::ActiveRecord::Migration; end +# source://activerecord//lib/active_record/migration.rb#582 +class ActiveRecord::Migration::Current < ::ActiveRecord::Migration + # source://activerecord//lib/active_record/migration.rb#591 + def change_table(table_name, **options); end + + # source://activerecord//lib/active_record/migration.rb#615 + def compatible_table_definition(t); end + + # source://activerecord//lib/active_record/migration.rb#599 + def create_join_table(table_1, table_2, **options); end + + # source://activerecord//lib/active_record/migration.rb#583 + def create_table(table_name, **options); end + + # source://activerecord//lib/active_record/migration.rb#607 + def drop_table(table_name, **options); end +end + +# The default strategy for executing migrations. Delegates method calls +# to the connection adapter. +# +# source://activerecord//lib/active_record/migration/default_strategy.rb#7 +class ActiveRecord::Migration::DefaultStrategy < ::ActiveRecord::Migration::ExecutionStrategy + private + + # source://activerecord//lib/active_record/migration/default_strategy.rb#17 + def connection; end + + # source://activerecord//lib/active_record/migration/default_strategy.rb#9 + def method_missing(method, *_arg1, **_arg2, &_arg3); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration/default_strategy.rb#13 + def respond_to_missing?(method, include_private = T.unsafe(nil)); end +end + +# ExecutionStrategy is used by the migration to respond to any method calls +# that the migration class does not implement directly. This is the base strategy. +# All strategies should inherit from this class. +# +# The ExecutionStrategy receives the current +migration+ when initialized. +# +# source://activerecord//lib/active_record/migration/execution_strategy.rb#10 +class ActiveRecord::Migration::ExecutionStrategy + # @return [ExecutionStrategy] a new instance of ExecutionStrategy + # + # source://activerecord//lib/active_record/migration/execution_strategy.rb#11 + def initialize(migration); end + + private + + # Returns the value of attribute migration. + # + # source://activerecord//lib/active_record/migration/execution_strategy.rb#16 + def migration; end +end # source://activerecord//lib/active_record/migration/join_table.rb#5 module ActiveRecord::Migration::JoinTable @@ -23410,12 +26031,12 @@ module ActiveRecord::Migration::JoinTable def join_table_name(table_1, table_2); end end -# source://activerecord//lib/active_record/migration.rb#576 +# source://activerecord//lib/active_record/migration.rb#640 ActiveRecord::Migration::MigrationFilenameRegexp = T.let(T.unsafe(nil), Regexp) -# source://activerecord//lib/active_record/migration.rb#752 +# source://activerecord//lib/active_record/migration.rb#876 class ActiveRecord::Migration::ReversibleBlockHelper < ::Struct - # source://activerecord//lib/active_record/migration.rb#757 + # source://activerecord//lib/active_record/migration.rb#881 def down; end # Returns the value of attribute reverting @@ -23429,7 +26050,7 @@ class ActiveRecord::Migration::ReversibleBlockHelper < ::Struct # @return [Object] the newly set value def reverting=(_); end - # source://activerecord//lib/active_record/migration.rb#753 + # source://activerecord//lib/active_record/migration.rb#877 def up; end class << self @@ -23441,39 +26062,46 @@ class ActiveRecord::Migration::ReversibleBlockHelper < ::Struct end end +# = \Migration \Context +# # MigrationContext sets the context in which a migration is run. # # A migration context requires the path to the migrations is set # in the +migrations_paths+ parameter. Optionally a +schema_migration+ -# class can be provided. For most applications, +SchemaMigration+ is -# sufficient. Multiple database applications need a +SchemaMigration+ -# per primary database. +# class can be provided. Multiple database applications will instantiate +# a +SchemaMigration+ object per database. From the Rake tasks, \Rails will +# handle this for you. # -# source://activerecord//lib/active_record/migration.rb#1068 +# source://activerecord//lib/active_record/migration.rb#1214 class ActiveRecord::MigrationContext # @return [MigrationContext] a new instance of MigrationContext # - # source://activerecord//lib/active_record/migration.rb#1071 - def initialize(migrations_paths, schema_migration = T.unsafe(nil)); end + # source://activerecord//lib/active_record/migration.rb#1217 + def initialize(migrations_paths, schema_migration = T.unsafe(nil), internal_metadata = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#1190 + # source://activerecord//lib/active_record/migration.rb#1343 def current_environment; end - # source://activerecord//lib/active_record/migration.rb#1146 + # source://activerecord//lib/active_record/migration.rb#1293 def current_version; end - # source://activerecord//lib/active_record/migration.rb#1120 + # source://activerecord//lib/active_record/migration.rb#1267 def down(target_version = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/migration.rb#1106 + # source://activerecord//lib/active_record/migration.rb#1253 def forward(steps = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#1138 + # source://activerecord//lib/active_record/migration.rb#1285 def get_all_versions; end + # Returns the value of attribute internal_metadata. + # + # source://activerecord//lib/active_record/migration.rb#1215 + def internal_metadata; end + # @raise [NoEnvironmentInSchemaError] # - # source://activerecord//lib/active_record/migration.rb#1198 + # source://activerecord//lib/active_record/migration.rb#1351 def last_stored_environment; end # Runs the migrations in the +migrations_path+. @@ -23490,87 +26118,103 @@ class ActiveRecord::MigrationContext # If none of the conditions are met, +up+ will be run with # the +target_version+. # - # source://activerecord//lib/active_record/migration.rb#1089 + # source://activerecord//lib/active_record/migration.rb#1236 def migrate(target_version = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/migration.rb#1159 + # source://activerecord//lib/active_record/migration.rb#1306 def migrations; end # Returns the value of attribute migrations_paths. # - # source://activerecord//lib/active_record/migration.rb#1069 + # source://activerecord//lib/active_record/migration.rb#1215 def migrations_paths; end - # source://activerecord//lib/active_record/migration.rb#1172 + # source://activerecord//lib/active_record/migration.rb#1322 def migrations_status; end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1151 + # source://activerecord//lib/active_record/migration.rb#1298 def needs_migration?; end - # source://activerecord//lib/active_record/migration.rb#1134 + # source://activerecord//lib/active_record/migration.rb#1281 def open; end - # source://activerecord//lib/active_record/migration.rb#1155 + # source://activerecord//lib/active_record/migration.rb#1302 def pending_migration_versions; end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1194 + # source://activerecord//lib/active_record/migration.rb#1347 def protected_environment?; end - # source://activerecord//lib/active_record/migration.rb#1102 + # source://activerecord//lib/active_record/migration.rb#1249 def rollback(steps = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#1130 + # source://activerecord//lib/active_record/migration.rb#1277 def run(direction, target_version); end # Returns the value of attribute schema_migration. # - # source://activerecord//lib/active_record/migration.rb#1069 + # source://activerecord//lib/active_record/migration.rb#1215 def schema_migration; end - # source://activerecord//lib/active_record/migration.rb#1110 + # source://activerecord//lib/active_record/migration.rb#1257 def up(target_version = T.unsafe(nil), &block); end private - # source://activerecord//lib/active_record/migration.rb#1209 + # source://activerecord//lib/active_record/migration.rb#1363 + def connection; end + + # source://activerecord//lib/active_record/migration.rb#1367 + def connection_pool; end + + # source://activerecord//lib/active_record/migration.rb#1371 def migration_files; end - # source://activerecord//lib/active_record/migration.rb#1218 + # source://activerecord//lib/active_record/migration.rb#1388 def move(direction, steps); end - # source://activerecord//lib/active_record/migration.rb#1214 + # source://activerecord//lib/active_record/migration.rb#1376 def parse_migration_filename(filename); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration.rb#1384 + def valid_migration_timestamp?(version); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration.rb#1380 + def validate_timestamp?; end end -# source://activerecord//lib/active_record/migration.rb#12 +# source://activerecord//lib/active_record/migration.rb#13 class ActiveRecord::MigrationError < ::ActiveRecord::ActiveRecordError # @return [MigrationError] a new instance of MigrationError # - # source://activerecord//lib/active_record/migration.rb#13 + # source://activerecord//lib/active_record/migration.rb#14 def initialize(message = T.unsafe(nil)); end end # MigrationProxy is used to defer loading of the actual migration classes # until they are needed # -# source://activerecord//lib/active_record/migration.rb#1036 +# source://activerecord//lib/active_record/migration.rb#1180 class ActiveRecord::MigrationProxy < ::Struct # @return [MigrationProxy] a new instance of MigrationProxy # - # source://activerecord//lib/active_record/migration.rb#1037 + # source://activerecord//lib/active_record/migration.rb#1181 def initialize(name, version, filename, scope); end - # source://activerecord//lib/active_record/migration.rb#1046 + # source://activerecord//lib/active_record/migration.rb#1190 def announce(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/migration.rb#1042 + # source://activerecord//lib/active_record/migration.rb#1186 def basename; end - # source://activerecord//lib/active_record/migration.rb#1046 + # source://activerecord//lib/active_record/migration.rb#1190 def disable_ddl_transaction(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute filename @@ -23584,7 +26228,7 @@ class ActiveRecord::MigrationProxy < ::Struct # @return [Object] the newly set value def filename=(_); end - # source://activerecord//lib/active_record/migration.rb#1046 + # source://activerecord//lib/active_record/migration.rb#1190 def migrate(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute name @@ -23620,15 +26264,15 @@ class ActiveRecord::MigrationProxy < ::Struct # @return [Object] the newly set value def version=(_); end - # source://activerecord//lib/active_record/migration.rb#1046 + # source://activerecord//lib/active_record/migration.rb#1190 def write(*_arg0, **_arg1, &_arg2); end private - # source://activerecord//lib/active_record/migration.rb#1053 + # source://activerecord//lib/active_record/migration.rb#1197 def load_migration; end - # source://activerecord//lib/active_record/migration.rb#1049 + # source://activerecord//lib/active_record/migration.rb#1193 def migration; end class << self @@ -23640,159 +26284,162 @@ class ActiveRecord::MigrationProxy < ::Struct end end -# source://activerecord//lib/active_record/migration.rb#1238 +# source://activerecord//lib/active_record/migration.rb#1408 class ActiveRecord::Migrator # @return [Migrator] a new instance of Migrator # - # source://activerecord//lib/active_record/migration.rb#1250 - def initialize(direction, migrations, schema_migration, target_version = T.unsafe(nil)); end + # source://activerecord//lib/active_record/migration.rb#1424 + def initialize(direction, migrations, schema_migration, internal_metadata, target_version = T.unsafe(nil)); end - # source://activerecord//lib/active_record/migration.rb#1267 + # source://activerecord//lib/active_record/migration.rb#1442 def current; end - # source://activerecord//lib/active_record/migration.rb#1267 + # source://activerecord//lib/active_record/migration.rb#1442 def current_migration; end - # source://activerecord//lib/active_record/migration.rb#1263 + # source://activerecord//lib/active_record/migration.rb#1438 def current_version; end - # source://activerecord//lib/active_record/migration.rb#1312 + # source://activerecord//lib/active_record/migration.rb#1487 def load_migrated; end - # source://activerecord//lib/active_record/migration.rb#1280 + # source://activerecord//lib/active_record/migration.rb#1455 def migrate; end - # source://activerecord//lib/active_record/migration.rb#1308 + # source://activerecord//lib/active_record/migration.rb#1483 def migrated; end - # source://activerecord//lib/active_record/migration.rb#1299 + # source://activerecord//lib/active_record/migration.rb#1474 def migrations; end - # source://activerecord//lib/active_record/migration.rb#1303 + # source://activerecord//lib/active_record/migration.rb#1478 def pending_migrations; end - # source://activerecord//lib/active_record/migration.rb#1272 + # source://activerecord//lib/active_record/migration.rb#1447 def run; end - # source://activerecord//lib/active_record/migration.rb#1288 + # source://activerecord//lib/active_record/migration.rb#1463 def runnable; end private + # source://activerecord//lib/active_record/migration.rb#1492 + def connection; end + # Wrap the migration in a transaction only if supported by the adapter. # - # source://activerecord//lib/active_record/migration.rb#1409 + # source://activerecord//lib/active_record/migration.rb#1587 def ddl_transaction(migration, &block); end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1404 + # source://activerecord//lib/active_record/migration.rb#1582 def down?; end - # source://activerecord//lib/active_record/migration.rb#1353 + # source://activerecord//lib/active_record/migration.rb#1531 def execute_migration_in_transaction(migration); end - # source://activerecord//lib/active_record/migration.rb#1374 + # source://activerecord//lib/active_record/migration.rb#1552 def finish; end - # source://activerecord//lib/active_record/migration.rb#1453 + # source://activerecord//lib/active_record/migration.rb#1619 def generate_migrator_advisory_lock_id; end # Return true if a valid version is not provided. # # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1349 + # source://activerecord//lib/active_record/migration.rb#1527 def invalid_target?; end # Used for running multiple migrations up to or down to a certain value. # - # source://activerecord//lib/active_record/migration.rb#1328 + # source://activerecord//lib/active_record/migration.rb#1506 def migrate_without_lock; end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1344 + # source://activerecord//lib/active_record/migration.rb#1522 def ran?(migration); end # Stores the current environment in the database. # - # source://activerecord//lib/active_record/migration.rb#1339 + # source://activerecord//lib/active_record/migration.rb#1516 def record_environment; end - # source://activerecord//lib/active_record/migration.rb#1390 + # source://activerecord//lib/active_record/migration.rb#1568 def record_version_state_after_migrating(version); end # Used for running a specific migration. # # @raise [UnknownMigrationVersionError] # - # source://activerecord//lib/active_record/migration.rb#1318 + # source://activerecord//lib/active_record/migration.rb#1497 def run_without_lock; end - # source://activerecord//lib/active_record/migration.rb#1378 + # source://activerecord//lib/active_record/migration.rb#1556 def start; end - # source://activerecord//lib/active_record/migration.rb#1370 + # source://activerecord//lib/active_record/migration.rb#1548 def target; end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1400 + # source://activerecord//lib/active_record/migration.rb#1578 def up?; end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1421 + # source://activerecord//lib/active_record/migration.rb#1599 def use_advisory_lock?; end # @return [Boolean] # - # source://activerecord//lib/active_record/migration.rb#1417 + # source://activerecord//lib/active_record/migration.rb#1595 def use_transaction?(migration); end # @raise [DuplicateMigrationNameError] # - # source://activerecord//lib/active_record/migration.rb#1382 + # source://activerecord//lib/active_record/migration.rb#1560 def validate(migrations); end - # source://activerecord//lib/active_record/migration.rb#1425 + # source://activerecord//lib/active_record/migration.rb#1603 def with_advisory_lock; end - # source://activerecord//lib/active_record/migration.rb#1442 - def with_advisory_lock_connection(&block); end - class << self # For cases where a table doesn't exist like loading from schema cache # - # source://activerecord//lib/active_record/migration.rb#1243 + # source://activerecord//lib/active_record/migration.rb#1413 def current_version; end # Returns the value of attribute migrations_paths. # - # source://activerecord//lib/active_record/migration.rb#1240 + # source://activerecord//lib/active_record/migration.rb#1410 def migrations_paths; end # Sets the attribute migrations_paths # # @param value the value to set the attribute migrations_paths to. # - # source://activerecord//lib/active_record/migration.rb#1240 + # source://activerecord//lib/active_record/migration.rb#1410 def migrations_paths=(_arg0); end end end -# source://activerecord//lib/active_record/migration.rb#1452 +# source://activerecord//lib/active_record/migration.rb#1618 ActiveRecord::Migrator::MIGRATOR_SALT = T.let(T.unsafe(nil), Integer) # Raised when a foreign key constraint cannot be added because the column type does not match the referenced column type. # -# source://activerecord//lib/active_record/errors.rb#183 +# source://activerecord//lib/active_record/errors.rb#225 class ActiveRecord::MismatchedForeignKey < ::ActiveRecord::StatementInvalid # @return [MismatchedForeignKey] a new instance of MismatchedForeignKey # - # source://activerecord//lib/active_record/errors.rb#184 - def initialize(message: T.unsafe(nil), sql: T.unsafe(nil), binds: T.unsafe(nil), table: T.unsafe(nil), foreign_key: T.unsafe(nil), target_table: T.unsafe(nil), primary_key: T.unsafe(nil), primary_key_column: T.unsafe(nil)); end + # source://activerecord//lib/active_record/errors.rb#226 + def initialize(message: T.unsafe(nil), sql: T.unsafe(nil), binds: T.unsafe(nil), table: T.unsafe(nil), foreign_key: T.unsafe(nil), target_table: T.unsafe(nil), primary_key: T.unsafe(nil), primary_key_column: T.unsafe(nil), query_parser: T.unsafe(nil), connection_pool: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/errors.rb#262 + def set_query(sql, binds); end end # source://activerecord//lib/active_record/model_schema.rb#6 @@ -23811,8 +26458,9 @@ module ActiveRecord::ModelSchema # artists, records => artists_records # records, artists => artists_records # music_artists, music_records => music_artists_records + # music.artists, music.records => music.artists_records # - # source://activerecord//lib/active_record/model_schema.rb#183 + # source://activerecord//lib/active_record/model_schema.rb#196 def derive_join_table_name(first_table, second_table); end end @@ -23858,25 +26506,22 @@ module ActiveRecord::ModelSchema end end -# source://activerecord//lib/active_record/model_schema.rb#187 +# source://activerecord//lib/active_record/model_schema.rb#200 module ActiveRecord::ModelSchema::ClassMethods - # source://activerecord//lib/active_record/model_schema.rb#486 - def _default_attributes; end - - # source://activerecord//lib/active_record/model_schema.rb#428 - def attribute_types; end + # source://activerecord//lib/active_record/model_schema.rb#438 + def _returning_columns_for_insert(connection); end - # source://activerecord//lib/active_record/model_schema.rb#410 + # source://activerecord//lib/active_record/model_schema.rb#421 def attributes_builder; end # Returns a hash where the keys are column names and the values are # default values when instantiating the Active Record object for this table. # - # source://activerecord//lib/active_record/model_schema.rb#481 + # source://activerecord//lib/active_record/model_schema.rb#474 def column_defaults; end # Returns the column object for the named attribute. - # Returns an +ActiveRecord::ConnectionAdapters::NullColumn+ if the + # Returns an ActiveRecord::ConnectionAdapters::NullColumn if the # named attribute does not exist. # # class Person < ActiveRecord::Base @@ -23889,36 +26534,36 @@ module ActiveRecord::ModelSchema::ClassMethods # person.column_for_attribute(:nothing) # # => #, ...> # - # source://activerecord//lib/active_record/model_schema.rb#472 + # source://activerecord//lib/active_record/model_schema.rb#465 def column_for_attribute(name); end # Returns an array of column names as strings. # - # source://activerecord//lib/active_record/model_schema.rb#492 + # source://activerecord//lib/active_record/model_schema.rb#480 def column_names; end - # source://activerecord//lib/active_record/model_schema.rb#423 + # source://activerecord//lib/active_record/model_schema.rb#433 def columns; end - # source://activerecord//lib/active_record/model_schema.rb#418 + # source://activerecord//lib/active_record/model_schema.rb#428 def columns_hash; end # Returns an array of column objects where the primary id, all columns ending in "_id" or "_count", # and columns used for single table inheritance have been removed. # - # source://activerecord//lib/active_record/model_schema.rb#503 + # source://activerecord//lib/active_record/model_schema.rb#491 def content_columns; end - # source://activerecord//lib/active_record/model_schema.rb#288 + # source://activerecord//lib/active_record/model_schema.rb#303 def full_table_name_prefix; end - # source://activerecord//lib/active_record/model_schema.rb#292 + # source://activerecord//lib/active_record/model_schema.rb#307 def full_table_name_suffix; end # The list of columns names the model should ignore. Ignored columns won't have attribute # accessors defined, and won't be referenced in SQL queries. # - # source://activerecord//lib/active_record/model_schema.rb#317 + # source://activerecord//lib/active_record/model_schema.rb#332 def ignored_columns; end # Sets the columns names the model should ignore. Ignored columns won't have attribute @@ -23939,7 +26584,7 @@ module ActiveRecord::ModelSchema::ClassMethods # # name :string, limit: 255 # # category :string, limit: 255 # - # self.ignored_columns = [:category] + # self.ignored_columns += [:category] # end # # The schema still contains "category", but now the model omits it, so any meta-driven code or @@ -23953,13 +26598,16 @@ module ActiveRecord::ModelSchema::ClassMethods # user = Project.create!(name: "First Project") # user.category # => raises NoMethodError # - # source://activerecord//lib/active_record/model_schema.rb#356 + # source://activerecord//lib/active_record/model_schema.rb#367 def ignored_columns=(columns); end + # source://activerecord//lib/active_record/model_schema.rb#534 + def load_schema; end + # Returns the next value that will be used as the primary key on # an insert statement. # - # source://activerecord//lib/active_record/model_schema.rb#401 + # source://activerecord//lib/active_record/model_schema.rb#412 def next_sequence_value; end # Determines if the primary key values should be selected from their @@ -23967,26 +26615,26 @@ module ActiveRecord::ModelSchema::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/model_schema.rb#395 + # source://activerecord//lib/active_record/model_schema.rb#406 def prefetch_primary_key?; end # The array of names of environments where destructive actions should be prohibited. By default, # the value is ["production"]. # - # source://activerecord//lib/active_record/model_schema.rb#298 + # source://activerecord//lib/active_record/model_schema.rb#313 def protected_environments; end # Sets an array of names of environments where destructive actions should be prohibited. # - # source://activerecord//lib/active_record/model_schema.rb#307 + # source://activerecord//lib/active_record/model_schema.rb#322 def protected_environments=(environments); end # Returns a quoted version of the table name, used to construct SQL statements. # - # source://activerecord//lib/active_record/model_schema.rb#273 + # source://activerecord//lib/active_record/model_schema.rb#286 def quoted_table_name; end - # source://activerecord//lib/active_record/model_schema.rb#311 + # source://activerecord//lib/active_record/model_schema.rb#326 def real_inheritance_column=(value); end # Resets all the cached information about columns, which will cause them @@ -23996,7 +26644,7 @@ module ActiveRecord::ModelSchema::ClassMethods # when just after creating a table you want to populate it with some default # values, e.g.: # - # class CreateJobLevels < ActiveRecord::Migration[7.0] + # class CreateJobLevels < ActiveRecord::Migration[7.2] # def up # create_table :job_levels do |t| # t.integer :id @@ -24016,18 +26664,18 @@ module ActiveRecord::ModelSchema::ClassMethods # end # end # - # source://activerecord//lib/active_record/model_schema.rb#537 + # source://activerecord//lib/active_record/model_schema.rb#525 def reset_column_information; end - # source://activerecord//lib/active_record/model_schema.rb#369 + # source://activerecord//lib/active_record/model_schema.rb#380 def reset_sequence_name; end # Computes the table name, (re)sets it internally, and returns it. # - # source://activerecord//lib/active_record/model_schema.rb#278 + # source://activerecord//lib/active_record/model_schema.rb#291 def reset_table_name; end - # source://activerecord//lib/active_record/model_schema.rb#361 + # source://activerecord//lib/active_record/model_schema.rb#372 def sequence_name; end # Sets the name of the sequence to use when generating ids to the given @@ -24045,17 +26693,17 @@ module ActiveRecord::ModelSchema::ClassMethods # self.sequence_name = "projectseq" # default would have been "project_seq" # end # - # source://activerecord//lib/active_record/model_schema.rb#388 + # source://activerecord//lib/active_record/model_schema.rb#399 def sequence_name=(value); end - # source://activerecord//lib/active_record/model_schema.rb#496 + # source://activerecord//lib/active_record/model_schema.rb#484 def symbol_column_to_string(name_symbol); end # Indicates whether the table associated with this class exists # # @return [Boolean] # - # source://activerecord//lib/active_record/model_schema.rb#406 + # source://activerecord//lib/active_record/model_schema.rb#417 def table_exists?; end # Guesses the table name (in forced lower-case) based on the name of the class in the @@ -24118,7 +26766,7 @@ module ActiveRecord::ModelSchema::ClassMethods # self.table_name = "mice" # end # - # source://activerecord//lib/active_record/model_schema.rb#247 + # source://activerecord//lib/active_record/model_schema.rb#260 def table_name; end # Sets the table name explicitly. Example: @@ -24127,62 +26775,44 @@ module ActiveRecord::ModelSchema::ClassMethods # self.table_name = "project" # end # - # source://activerecord//lib/active_record/model_schema.rb#257 + # source://activerecord//lib/active_record/model_schema.rb#270 def table_name=(value); end - # Returns the type of the attribute with the given name, after applying - # all modifiers. This method is the only valid source of information for - # anything related to the types of a model's attributes. This method will - # access the database and load the model's schema if it is required. - # - # The return value of this method will implement the interface described - # by ActiveModel::Type::Value (though the object itself may not subclass - # it). - # - # +attr_name+ The name of the attribute to retrieve the type for. Must be - # a string or a symbol. - # # source://activerecord//lib/active_record/model_schema.rb#448 - def type_for_attribute(attr_name, &block); end - - # source://activerecord//lib/active_record/model_schema.rb#433 def yaml_encoder; end protected - # source://activerecord//lib/active_record/model_schema.rb#547 + # source://activerecord//lib/active_record/model_schema.rb#549 def initialize_load_schema_monitor; end - private + # source://activerecord//lib/active_record/model_schema.rb#553 + def reload_schema_from_cache(recursive = T.unsafe(nil)); end - # source://activerecord//lib/active_record/model_schema.rb#637 - def _convert_type_from_options(type); end + private # Computes and returns a table name according to default conventions. # - # source://activerecord//lib/active_record/model_schema.rb#621 + # source://activerecord//lib/active_record/model_schema.rb#604 def compute_table_name; end - # source://activerecord//lib/active_record/model_schema.rb#552 + # source://activerecord//lib/active_record/model_schema.rb#574 def inherited(child_class); end - # source://activerecord//lib/active_record/model_schema.rb#561 - def load_schema; end - - # source://activerecord//lib/active_record/model_schema.rb#575 + # source://activerecord//lib/active_record/model_schema.rb#587 def load_schema!; end - # source://activerecord//lib/active_record/model_schema.rb#595 - def reload_schema_from_cache; end - # @return [Boolean] # - # source://activerecord//lib/active_record/model_schema.rb#557 + # source://activerecord//lib/active_record/model_schema.rb#583 def schema_loaded?; end + # source://activerecord//lib/active_record/model_schema.rb#620 + def type_for_column(connection, column); end + # Guesses the table name, but does not decorate it with prefix and suffix information. # - # source://activerecord//lib/active_record/model_schema.rb#615 + # source://activerecord//lib/active_record/model_schema.rb#598 def undecorated_table_name(model_name); end end @@ -24191,16 +26821,16 @@ end # method. The exception has an +errors+ property that contains an array of AttributeAssignmentError # objects, each corresponding to the error while assigning to an attribute. # -# source://activerecord//lib/active_record/errors.rb#366 +# source://activerecord//lib/active_record/errors.rb#450 class ActiveRecord::MultiparameterAssignmentErrors < ::ActiveRecord::ActiveRecordError # @return [MultiparameterAssignmentErrors] a new instance of MultiparameterAssignmentErrors # - # source://activerecord//lib/active_record/errors.rb#369 + # source://activerecord//lib/active_record/errors.rb#453 def initialize(errors = T.unsafe(nil)); end # Returns the value of attribute errors. # - # source://activerecord//lib/active_record/errors.rb#367 + # source://activerecord//lib/active_record/errors.rb#451 def errors; end end @@ -24212,20 +26842,20 @@ module ActiveRecord::NestedAttributes mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveRecord::NestedAttributes::ClassMethods - # Returns ActiveRecord::AutosaveAssociation::marked_for_destruction? It's + # Returns ActiveRecord::AutosaveAssociation#marked_for_destruction? It's # used in conjunction with fields_for to build a form element for the # destruction of this association. # - # See ActionView::Helpers::FormHelper::fields_for for more info. + # See ActionView::Helpers::FormHelper#fields_for for more info. # - # source://activerecord//lib/active_record/nested_attributes.rb#383 + # source://activerecord//lib/active_record/nested_attributes.rb#401 def _destroy; end private # @return [Boolean] # - # source://activerecord//lib/active_record/nested_attributes.rb#588 + # source://activerecord//lib/active_record/nested_attributes.rb#614 def allow_destroy?(association_name); end # Assigns the given attributes to the collection association. @@ -24256,7 +26886,7 @@ module ActiveRecord::NestedAttributes # { id: '2', _destroy: true } # ]) # - # source://activerecord//lib/active_record/nested_attributes.rb#464 + # source://activerecord//lib/active_record/nested_attributes.rb#487 def assign_nested_attributes_for_collection_association(association_name, attributes_collection); end # Assigns the given attributes to the association. @@ -24273,13 +26903,13 @@ module ActiveRecord::NestedAttributes # update_only is true, and a :_destroy key set to a truthy value, # then the existing record will be marked for destruction. # - # source://activerecord//lib/active_record/nested_attributes.rb#405 + # source://activerecord//lib/active_record/nested_attributes.rb#423 def assign_nested_attributes_for_one_to_one_association(association_name, attributes); end # Updates a record with the +attributes+ or marks it for destruction if # +allow_destroy+ is +true+ and has_destroy_flag? returns +true+. # - # source://activerecord//lib/active_record/nested_attributes.rb#550 + # source://activerecord//lib/active_record/nested_attributes.rb#576 def assign_to_or_mark_for_destruction(record, attributes, allow_destroy); end # Determines if a record with the particular +attributes+ should be @@ -24288,7 +26918,7 @@ module ActiveRecord::NestedAttributes # # Returns false if there is a +destroy_flag+ on the attributes. # - # source://activerecord//lib/active_record/nested_attributes.rb#572 + # source://activerecord//lib/active_record/nested_attributes.rb#598 def call_reject_if(association_name, attributes); end # Takes in a limit and checks if the attributes_collection has too many @@ -24298,19 +26928,19 @@ module ActiveRecord::NestedAttributes # Raises TooManyRecords error if the attributes_collection is # larger than the limit. # - # source://activerecord//lib/active_record/nested_attributes.rb#530 + # source://activerecord//lib/active_record/nested_attributes.rb#556 def check_record_limit!(limit, attributes_collection); end # Determines if a hash contains a truthy _destroy key. # # @return [Boolean] # - # source://activerecord//lib/active_record/nested_attributes.rb#556 + # source://activerecord//lib/active_record/nested_attributes.rb#582 def has_destroy_flag?(hash); end # @raise [RecordNotFound] # - # source://activerecord//lib/active_record/nested_attributes.rb#592 + # source://activerecord//lib/active_record/nested_attributes.rb#618 def raise_nested_attributes_record_not_found!(association_name, record_id); end # Determines if a new record should be rejected by checking @@ -24319,14 +26949,14 @@ module ActiveRecord::NestedAttributes # # @return [Boolean] # - # source://activerecord//lib/active_record/nested_attributes.rb#563 + # source://activerecord//lib/active_record/nested_attributes.rb#589 def reject_new_record?(association_name, attributes); end # Only take into account the destroy flag if :allow_destroy is true # # @return [Boolean] # - # source://activerecord//lib/active_record/nested_attributes.rb#584 + # source://activerecord//lib/active_record/nested_attributes.rb#610 def will_be_destroyed?(association_name, attributes); end module GeneratedClassMethods @@ -24341,7 +26971,7 @@ module ActiveRecord::NestedAttributes end end -# = Active Record Nested Attributes +# = Active Record Nested \Attributes # # Nested attributes allow you to save attributes on associated records # through the parent. By default nested attribute updating is turned off @@ -24607,7 +27237,25 @@ end # member.avatar_attributes = {icon: 'sad'} # member.avatar.width # => 200 # -# source://activerecord//lib/active_record/nested_attributes.rb#283 +# === Creating forms with nested attributes +# +# Use ActionView::Helpers::FormHelper#fields_for to create form elements for +# nested attributes. +# +# Integration test params should reflect the structure of the form. For +# example: +# +# post members_path, params: { +# member: { +# name: 'joe', +# posts_attributes: { +# '0' => { title: 'Foo' }, +# '1' => { title: 'Bar' } +# } +# } +# } +# +# source://activerecord//lib/active_record/nested_attributes.rb#301 module ActiveRecord::NestedAttributes::ClassMethods # Defines an attributes writer for the specified association(s). # @@ -24615,7 +27263,7 @@ module ActiveRecord::NestedAttributes::ClassMethods # [:allow_destroy] # If true, destroys any members from the attributes hash with a # _destroy key and a value that evaluates to +true+ - # (e.g. 1, '1', true, or 'true'). This option is off by default. + # (e.g. 1, '1', true, or 'true'). This option is false by default. # [:reject_if] # Allows you to specify a Proc or a Symbol pointing to a method # that checks whether a record should be built for a certain attribute @@ -24640,11 +27288,11 @@ module ActiveRecord::NestedAttributes::ClassMethods # nested attributes are going to be used when an associated record already # exists. In general, an existing record may either be updated with the # new set of attribute values or be replaced by a wholly new record - # containing those values. By default the +:update_only+ option is +false+ + # containing those values. By default the +:update_only+ option is false # and the nested attributes are used to update the existing record only # if they include the record's :id value. Otherwise a new # record will be instantiated and used to replace the existing one. - # However if the +:update_only+ option is +true+, the nested attributes + # However if the +:update_only+ option is true, the nested attributes # are used to update the record's attributes always, regardless of # whether the :id is present. The option is ignored for collection # associations. @@ -24657,7 +27305,7 @@ module ActiveRecord::NestedAttributes::ClassMethods # # creates avatar_attributes= and posts_attributes= # accepts_nested_attributes_for :avatar, :posts, allow_destroy: true # - # source://activerecord//lib/active_record/nested_attributes.rb#333 + # source://activerecord//lib/active_record/nested_attributes.rb#351 def accepts_nested_attributes_for(*attr_names); end private @@ -24674,11 +27322,11 @@ module ActiveRecord::NestedAttributes::ClassMethods # the helper methods defined below. Makes it seem like the nested # associations are just regular associations. # - # source://activerecord//lib/active_record/nested_attributes.rb#368 + # source://activerecord//lib/active_record/nested_attributes.rb#386 def generate_association_writer(association_name, type); end end -# source://activerecord//lib/active_record/nested_attributes.rb#284 +# source://activerecord//lib/active_record/nested_attributes.rb#302 ActiveRecord::NestedAttributes::ClassMethods::REJECT_ALL_BLANK_PROC = T.let(T.unsafe(nil), Proc) # source://activerecord//lib/active_record/nested_attributes.rb#9 @@ -24687,50 +27335,50 @@ class ActiveRecord::NestedAttributes::TooManyRecords < ::ActiveRecord::ActiveRec # Attribute hash keys that should not be assigned as normal attributes. # These hash keys are nested attributes implementation details. # -# source://activerecord//lib/active_record/nested_attributes.rb#390 +# source://activerecord//lib/active_record/nested_attributes.rb#408 ActiveRecord::NestedAttributes::UNASSIGNABLE_KEYS = T.let(T.unsafe(nil), Array) # Raised when a given database does not exist. # -# source://activerecord//lib/active_record/errors.rb#238 +# source://activerecord//lib/active_record/errors.rb#315 class ActiveRecord::NoDatabaseError < ::ActiveRecord::StatementInvalid include ::ActiveSupport::ActionableError extend ::ActiveSupport::ActionableError::ClassMethods # @return [NoDatabaseError] a new instance of NoDatabaseError # - # source://activerecord//lib/active_record/errors.rb#245 - def initialize(message = T.unsafe(nil)); end + # source://activerecord//lib/active_record/errors.rb#322 + def initialize(message = T.unsafe(nil), connection_pool: T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions; end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions?; end class << self - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions; end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions=(value); end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions?; end - # source://activerecord//lib/active_record/errors.rb#250 + # source://activerecord//lib/active_record/errors.rb#327 def db_error(db_name); end end end -# source://activerecord//lib/active_record/migration.rb#177 +# source://activerecord//lib/active_record/migration.rb#199 class ActiveRecord::NoEnvironmentInSchemaError < ::ActiveRecord::MigrationError # @return [NoEnvironmentInSchemaError] a new instance of NoEnvironmentInSchemaError # - # source://activerecord//lib/active_record/migration.rb#178 + # source://activerecord//lib/active_record/migration.rb#200 def initialize; end end @@ -24796,99 +27444,238 @@ module ActiveRecord::NoTouching::ClassMethods def no_touching(&block); end end -# Raised when a record cannot be inserted or updated because it would violate a not null constraint. -# -# source://activerecord//lib/active_record/errors.rb#216 -class ActiveRecord::NotNullViolation < ::ActiveRecord::StatementInvalid; end +# source://activerecord//lib/active_record/normalization.rb#4 +module ActiveRecord::Normalization + extend ::ActiveSupport::Concern + include GeneratedInstanceMethods -# source://activerecord//lib/active_record/null_relation.rb#4 -module ActiveRecord::NullRelation - # @return [Boolean] + mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActiveRecord::Normalization::ClassMethods + + # Normalizes a specified attribute using its declared normalizations. # - # source://activerecord//lib/active_record/null_relation.rb#29 - def any?; end + # ==== Examples + # + # class User < ActiveRecord::Base + # normalizes :email, with: -> email { email.strip.downcase } + # end + # + # legacy_user = User.find(1) + # legacy_user.email # => " CRUISE-CONTROL@EXAMPLE.COM\n" + # legacy_user.normalize_attribute(:email) + # legacy_user.email # => "cruise-control@example.com" + # legacy_user.save + # + # source://activerecord//lib/active_record/normalization.rb#26 + def normalize_attribute(name); end - # source://activerecord//lib/active_record/null_relation.rb#41 - def calculate(operation, _column_name); end + private - # source://activerecord//lib/active_record/null_relation.rb#17 - def delete(_id_or_array); end + # source://activerecord//lib/active_record/normalization.rb#112 + def normalize_changed_in_place_attributes; end - # source://activerecord//lib/active_record/null_relation.rb#9 - def delete_all; end + module GeneratedClassMethods + def normalized_attributes; end + def normalized_attributes=(value); end + def normalized_attributes?; end + end - # @return [Boolean] + module GeneratedInstanceMethods + def normalized_attributes; end + def normalized_attributes=(value); end + def normalized_attributes?; end + end +end + +# source://activerecord//lib/active_record/normalization.rb#31 +module ActiveRecord::Normalization::ClassMethods + # Normalizes a given +value+ using normalizations declared for +name+. # - # source://activerecord//lib/active_record/null_relation.rb#21 - def empty?; end + # ==== Examples + # + # class User < ActiveRecord::Base + # normalizes :email, with: -> email { email.strip.downcase } + # end + # + # User.normalize_value_for(:email, " CRUISE-CONTROL@EXAMPLE.COM\n") + # # => "cruise-control@example.com" + # + # source://activerecord//lib/active_record/normalization.rb#106 + def normalize_value_for(name, value); end - # @return [Boolean] + # Declares a normalization for one or more attributes. The normalization + # is applied when the attribute is assigned or updated, and the normalized + # value will be persisted to the database. The normalization is also + # applied to the corresponding keyword argument of query methods. This + # allows a record to be created and later queried using unnormalized + # values. + # + # However, to prevent confusion, the normalization will not be applied + # when the attribute is fetched from the database. This means that if a + # record was persisted before the normalization was declared, the record's + # attribute will not be normalized until either it is assigned a new + # value, or it is explicitly migrated via Normalization#normalize_attribute. + # + # Because the normalization may be applied multiple times, it should be + # _idempotent_. In other words, applying the normalization more than once + # should have the same result as applying it only once. + # + # By default, the normalization will not be applied to +nil+ values. This + # behavior can be changed with the +:apply_to_nil+ option. + # + # Be aware that if your app was created before Rails 7.1, and your app + # marshals instances of the targeted model (for example, when caching), + # then you should set ActiveRecord.marshalling_format_version to +7.1+ or + # higher via either config.load_defaults 7.1 or + # config.active_record.marshalling_format_version = 7.1. + # Otherwise, +Marshal+ may attempt to serialize the normalization +Proc+ + # and raise +TypeError+. + # + # ==== Options + # + # * +:with+ - Any callable object that accepts the attribute's value as + # its sole argument, and returns it normalized. + # * +:apply_to_nil+ - Whether to apply the normalization to +nil+ values. + # Defaults to +false+. + # + # ==== Examples + # + # class User < ActiveRecord::Base + # normalizes :email, with: -> email { email.strip.downcase } + # normalizes :phone, with: -> phone { phone.delete("^0-9").delete_prefix("1") } + # end + # + # user = User.create(email: " CRUISE-CONTROL@EXAMPLE.COM\n") + # user.email # => "cruise-control@example.com" + # + # user = User.find_by(email: "\tCRUISE-CONTROL@EXAMPLE.COM ") + # user.email # => "cruise-control@example.com" + # user.email_before_type_cast # => "cruise-control@example.com" + # + # User.where(email: "\tCRUISE-CONTROL@EXAMPLE.COM ").count # => 1 + # User.where(["email = ?", "\tCRUISE-CONTROL@EXAMPLE.COM "]).count # => 0 # - # source://activerecord//lib/active_record/null_relation.rb#50 - def exists?(_conditions = T.unsafe(nil)); end + # User.exists?(email: "\tCRUISE-CONTROL@EXAMPLE.COM ") # => true + # User.exists?(["email = ?", "\tCRUISE-CONTROL@EXAMPLE.COM "]) # => false + # + # User.normalize_value_for(:phone, "+1 (555) 867-5309") # => "5558675309" + # + # source://activerecord//lib/active_record/normalization.rb#88 + def normalizes(*names, with:, apply_to_nil: T.unsafe(nil)); end +end - # @return [Boolean] +# source://activerecord//lib/active_record/normalization.rb#118 +class ActiveRecord::Normalization::NormalizedValueType + include ::ActiveModel::Type::SerializeCastValue + extend ::ActiveModel::Type::SerializeCastValue::ClassMethods + + # @return [NormalizedValueType] a new instance of NormalizedValueType # - # source://activerecord//lib/active_record/null_relation.rb#37 - def many?; end + # source://activerecord//lib/active_record/normalization.rb#124 + def initialize(cast_type:, normalizer:, normalize_nil:); end - # @return [Boolean] + # source://activerecord//lib/active_record/normalization.rb#143 + def ==(other); end + + # source://activerecord//lib/active_record/normalization.rb#131 + def cast(value); end + + # Returns the value of attribute cast_type. # - # source://activerecord//lib/active_record/null_relation.rb#25 - def none?; end + # source://activerecord//lib/active_record/normalization.rb#121 + def cast_type; end - # @return [Boolean] + # source://activerecord//lib/active_record/normalization.rb#143 + def eql?(other); end + + # source://activerecord//lib/active_record/normalization.rb#151 + def hash; end + + def inspect; end + + # Returns the value of attribute normalize_nil. # - # source://activerecord//lib/active_record/null_relation.rb#33 - def one?; end + # source://activerecord//lib/active_record/normalization.rb#121 + def normalize_nil; end - # source://activerecord//lib/active_record/null_relation.rb#54 - def or(other); end + # Returns the value of attribute normalize_nil. + # + # source://activerecord//lib/active_record/normalization.rb#121 + def normalize_nil?; end - # source://activerecord//lib/active_record/null_relation.rb#5 - def pluck(*column_names); end + # Returns the value of attribute normalizer. + # + # source://activerecord//lib/active_record/normalization.rb#121 + def normalizer; end + + # source://activerecord//lib/active_record/normalization.rb#135 + def serialize(value); end - # source://activerecord//lib/active_record/null_relation.rb#13 - def update_all(_updates); end + # source://activerecord//lib/active_record/normalization.rb#139 + def serialize_cast_value(value); end private - # source://activerecord//lib/active_record/null_relation.rb#59 - def exec_main_query(async: T.unsafe(nil)); end + # source://activerecord//lib/active_record/normalization.rb#158 + def normalize(value); end +end + +# Raised when a record cannot be inserted or updated because it would violate a not null constraint. +# +# source://activerecord//lib/active_record/errors.rb#280 +class ActiveRecord::NotNullViolation < ::ActiveRecord::StatementInvalid; end + +# source://activerecord//lib/active_record/migration/pending_migration_connection.rb#4 +class ActiveRecord::PendingMigrationConnection + class << self + # source://activerecord//lib/active_record/migration/pending_migration_connection.rb#17 + def current_preventing_writes; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/migration/pending_migration_connection.rb#13 + def primary_class?; end + + # source://activerecord//lib/active_record/migration/pending_migration_connection.rb#5 + def with_temporary_pool(db_config, &block); end + end end -# source://activerecord//lib/active_record/migration.rb#133 +# source://activerecord//lib/active_record/migration.rb#150 class ActiveRecord::PendingMigrationError < ::ActiveRecord::MigrationError include ::ActiveSupport::ActionableError extend ::ActiveSupport::ActionableError::ClassMethods # @return [PendingMigrationError] a new instance of PendingMigrationError # - # source://activerecord//lib/active_record/migration.rb#146 - def initialize(message = T.unsafe(nil)); end + # source://activerecord//lib/active_record/migration.rb#162 + def initialize(message = T.unsafe(nil), pending_migrations: T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions; end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions?; end private - # source://activerecord//lib/active_record/migration.rb#151 - def detailed_migration_message; end + # source://activerecord//lib/active_record/migration.rb#185 + def connection_pool; end + + # source://activerecord//lib/active_record/migration.rb#171 + def detailed_migration_message(pending_migrations); end class << self - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions; end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions=(value); end - # source://activesupport/7.0.5/lib/active_support/actionable_error.rb#15 + # source://activesupport/7.2.0/lib/active_support/actionable_error.rb#17 def _actions?; end end end @@ -24912,9 +27699,11 @@ module ActiveRecord::Persistence # Note: The new instance will share a link to the same attributes as the original class. # Therefore the STI column value will still be the same. # Any change to the attributes on either instance will affect both instances. + # This includes any attribute initialization done by the new instance. + # # If you want to change the STI column as well, use #becomes! instead. # - # source://activerecord//lib/active_record/persistence.rb#711 + # source://activerecord//lib/active_record/persistence.rb#489 def becomes(klass); end # Wrapper around #becomes that also changes the instance's STI column value. @@ -24924,14 +27713,14 @@ module ActiveRecord::Persistence # Note: The old instance's STI column value will be changed too, as both objects # share the same set of attributes. # - # source://activerecord//lib/active_record/persistence.rb#731 + # source://activerecord//lib/active_record/persistence.rb#510 def becomes!(klass); end # Initializes +attribute+ to zero if +nil+ and subtracts the value passed as +by+ (default is 1). # The decrement is performed directly on the underlying attribute, no setter is invoked. # Only makes sense for number-based attributes. Returns +self+. # - # source://activerecord//lib/active_record/persistence.rb#856 + # source://activerecord//lib/active_record/persistence.rb#657 def decrement(attribute, by = T.unsafe(nil)); end # Wrapper around #decrement that writes the update to the database. @@ -24941,7 +27730,7 @@ module ActiveRecord::Persistence # +update_counters+, see that for more. # Returns +self+. # - # source://activerecord//lib/active_record/persistence.rb#866 + # source://activerecord//lib/active_record/persistence.rb#667 def decrement!(attribute, by = T.unsafe(nil), touch: T.unsafe(nil)); end # Deletes the record in the database and freezes this instance to @@ -24957,7 +27746,7 @@ module ActiveRecord::Persistence # callbacks or any :dependent association # options, use #destroy. # - # source://activerecord//lib/active_record/persistence.rb#663 + # source://activerecord//lib/active_record/persistence.rb#441 def delete; end # Deletes the record in the database and freezes this instance to reflect @@ -24968,7 +27757,7 @@ module ActiveRecord::Persistence # and #destroy returns +false+. # See ActiveRecord::Callbacks for further details. # - # source://activerecord//lib/active_record/persistence.rb#676 + # source://activerecord//lib/active_record/persistence.rb#455 def destroy; end # Deletes the record in the database and freezes this instance to reflect @@ -24979,21 +27768,21 @@ module ActiveRecord::Persistence # and #destroy! raises ActiveRecord::RecordNotDestroyed. # See ActiveRecord::Callbacks for further details. # - # source://activerecord//lib/active_record/persistence.rb#695 + # source://activerecord//lib/active_record/persistence.rb#471 def destroy!; end # Returns true if this object has been destroyed, otherwise returns false. # # @return [Boolean] # - # source://activerecord//lib/active_record/persistence.rb#579 + # source://activerecord//lib/active_record/persistence.rb#357 def destroyed?; end # Initializes +attribute+ to zero if +nil+ and adds the value passed as +by+ (default is 1). # The increment is performed directly on the underlying attribute, no setter is invoked. # Only makes sense for number-based attributes. Returns +self+. # - # source://activerecord//lib/active_record/persistence.rb#833 + # source://activerecord//lib/active_record/persistence.rb#634 def increment(attribute, by = T.unsafe(nil)); end # Wrapper around #increment that writes the update to the database. @@ -25003,7 +27792,7 @@ module ActiveRecord::Persistence # +update_counters+, see that for more. # Returns +self+. # - # source://activerecord//lib/active_record/persistence.rb#845 + # source://activerecord//lib/active_record/persistence.rb#646 def increment!(attribute, by = T.unsafe(nil), touch: T.unsafe(nil)); end # Returns true if this object hasn't been saved yet -- that is, a record @@ -25011,7 +27800,7 @@ module ActiveRecord::Persistence # # @return [Boolean] # - # source://activerecord//lib/active_record/persistence.rb#562 + # source://activerecord//lib/active_record/persistence.rb#340 def new_record?; end # Returns true if the record is persisted, i.e. it's not a new record and it was @@ -25019,23 +27808,23 @@ module ActiveRecord::Persistence # # @return [Boolean] # - # source://activerecord//lib/active_record/persistence.rb#585 + # source://activerecord//lib/active_record/persistence.rb#363 def persisted?; end # Returns true if this object was just created -- that is, prior to the last - # save, the object didn't exist in the database and new_record? would have + # update or delete, the object didn't exist in the database and new_record? would have # returned true. # # @return [Boolean] # - # source://activerecord//lib/active_record/persistence.rb#569 + # source://activerecord//lib/active_record/persistence.rb#347 def previously_new_record?; end # Returns true if this object was previously persisted but now it has been deleted. # # @return [Boolean] # - # source://activerecord//lib/active_record/persistence.rb#574 + # source://activerecord//lib/active_record/persistence.rb#352 def previously_persisted?; end # Reloads the record from the database. @@ -25086,7 +27875,7 @@ module ActiveRecord::Persistence # end # end # - # source://activerecord//lib/active_record/persistence.rb#943 + # source://activerecord//lib/active_record/persistence.rb#744 def reload(options = T.unsafe(nil)); end # :call-seq: @@ -25114,7 +27903,7 @@ module ActiveRecord::Persistence # Attributes marked as readonly are silently ignored if the record is # being updated. # - # source://activerecord//lib/active_record/persistence.rb#614 + # source://activerecord//lib/active_record/persistence.rb#392 def save(**options, &block); end # :call-seq: @@ -25144,7 +27933,7 @@ module ActiveRecord::Persistence # # Unless an error is raised, returns true. # - # source://activerecord//lib/active_record/persistence.rb#647 + # source://activerecord//lib/active_record/persistence.rb#425 def save!(**options, &block); end # Assigns to +attribute+ the boolean opposite of attribute?. So @@ -25159,7 +27948,7 @@ module ActiveRecord::Persistence # user.toggle(:banned) # user.banned? # => true # - # source://activerecord//lib/active_record/persistence.rb#882 + # source://activerecord//lib/active_record/persistence.rb#683 def toggle(attribute); end # Wrapper around #toggle that saves the record. This method differs from @@ -25167,7 +27956,7 @@ module ActiveRecord::Persistence # Saving is not subjected to validation checks. Returns +true+ if the # record could be saved. # - # source://activerecord//lib/active_record/persistence.rb#891 + # source://activerecord//lib/active_record/persistence.rb#692 def toggle!(attribute); end # Saves the record with the updated_at/on attributes set to the current time @@ -25204,20 +27993,20 @@ module ActiveRecord::Persistence # ball = Ball.new # ball.touch(:updated_at) # => raises ActiveRecordError # - # source://activerecord//lib/active_record/persistence.rb#993 + # source://activerecord//lib/active_record/persistence.rb#795 def touch(*names, time: T.unsafe(nil)); end # Updates the attributes of the model from the passed-in hash and saves the # record, all wrapped in a transaction. If the object is invalid, the saving # will fail and false will be returned. # - # source://activerecord//lib/active_record/persistence.rb#764 + # source://activerecord//lib/active_record/persistence.rb#565 def update(attributes); end # Updates its receiver just like #update but calls #save! instead # of +save+, so an exception is raised if the record is invalid and saving will fail. # - # source://activerecord//lib/active_record/persistence.rb#775 + # source://activerecord//lib/active_record/persistence.rb#576 def update!(attributes); end # Updates a single attribute and saves the record. @@ -25228,17 +28017,35 @@ module ActiveRecord::Persistence # * updated_at/updated_on column is updated if that column is available. # * Updates all the attributes that are dirty in this object. # - # This method raises an ActiveRecord::ActiveRecordError if the + # This method raises an ActiveRecord::ActiveRecordError if the # attribute is marked as readonly. # # Also see #update_column. # - # source://activerecord//lib/active_record/persistence.rb#753 + # source://activerecord//lib/active_record/persistence.rb#532 def update_attribute(name, value); end + # Updates a single attribute and saves the record. + # This is especially useful for boolean flags on existing records. Also note that + # + # * Validation is skipped. + # * \Callbacks are invoked. + # * updated_at/updated_on column is updated if that column is available. + # * Updates all the attributes that are dirty in this object. + # + # This method raises an ActiveRecord::ActiveRecordError if the + # attribute is marked as readonly. + # + # If any of the before_* callbacks throws +:abort+ the action is cancelled + # and #update_attribute! raises ActiveRecord::RecordNotSaved. See + # ActiveRecord::Callbacks for further details. + # + # source://activerecord//lib/active_record/persistence.rb#554 + def update_attribute!(name, value); end + # Equivalent to update_columns(name => value). # - # source://activerecord//lib/active_record/persistence.rb#785 + # source://activerecord//lib/active_record/persistence.rb#586 def update_column(name, value); end # Updates the attributes directly in the database issuing an UPDATE SQL @@ -25260,7 +28067,7 @@ module ActiveRecord::Persistence # # @raise [ActiveRecordError] # - # source://activerecord//lib/active_record/persistence.rb#805 + # source://activerecord//lib/active_record/persistence.rb#606 def update_columns(attributes); end private @@ -25271,32 +28078,35 @@ module ActiveRecord::Persistence # @yield [_self] # @yieldparam _self [ActiveRecord::Persistence] the object that the method was called on # - # source://activerecord//lib/active_record/persistence.rb#1093 + # source://activerecord//lib/active_record/persistence.rb#922 def _create_record(attribute_names = T.unsafe(nil)); end - # source://activerecord//lib/active_record/persistence.rb#1043 + # source://activerecord//lib/active_record/persistence.rb#872 def _delete_row; end - # source://activerecord//lib/active_record/persistence.rb#1018 + # source://activerecord//lib/active_record/persistence.rb#828 def _find_record(options); end - # source://activerecord//lib/active_record/persistence.rb#1031 - def _primary_key_constraints_hash; end + # source://activerecord//lib/active_record/persistence.rb#839 + def _in_memory_query_constraints_hash; end + + # source://activerecord//lib/active_record/persistence.rb#854 + def _query_constraints_hash; end # @raise [ReadOnlyRecord] # - # source://activerecord//lib/active_record/persistence.rb#1122 + # source://activerecord//lib/active_record/persistence.rb#959 def _raise_readonly_record_error; end - # source://activerecord//lib/active_record/persistence.rb#1114 + # source://activerecord//lib/active_record/persistence.rb#951 def _raise_record_not_destroyed; end # @raise [ActiveRecordError] # - # source://activerecord//lib/active_record/persistence.rb#1126 + # source://activerecord//lib/active_record/persistence.rb#963 def _raise_record_not_touched_error; end - # source://activerecord//lib/active_record/persistence.rb#1047 + # source://activerecord//lib/active_record/persistence.rb#876 def _touch_row(attribute_names, time); end # Updates the associated record with values matching those of the instance attributes. @@ -25305,54 +28115,84 @@ module ActiveRecord::Persistence # @yield [_self] # @yieldparam _self [ActiveRecord::Persistence] the object that the method was called on # - # source://activerecord//lib/active_record/persistence.rb#1073 + # source://activerecord//lib/active_record/persistence.rb#902 def _update_record(attribute_names = T.unsafe(nil)); end - # source://activerecord//lib/active_record/persistence.rb#1057 + # source://activerecord//lib/active_record/persistence.rb#886 def _update_row(attribute_names, attempted_action = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/active_record/persistence.rb#1026 + # source://activerecord//lib/active_record/persistence.rb#849 def apply_scoping?(options); end - # The name of the method used to touch a +belongs_to+ association when the - # +:touch+ option is used. - # - # source://activerecord//lib/active_record/persistence.rb#1135 - def belongs_to_touch_method; end - - # source://activerecord//lib/active_record/persistence.rb#1064 + # source://activerecord//lib/active_record/persistence.rb#893 def create_or_update(**_arg0, &block); end # A hook to be overridden by association modules. # - # source://activerecord//lib/active_record/persistence.rb#1036 + # source://activerecord//lib/active_record/persistence.rb#865 def destroy_associations; end - # source://activerecord//lib/active_record/persistence.rb#1039 + # source://activerecord//lib/active_record/persistence.rb#868 def destroy_row; end - # source://activerecord//lib/active_record/persistence.rb#1012 + # source://activerecord//lib/active_record/persistence.rb#816 + def init_internals; end + + # source://activerecord//lib/active_record/persistence.rb#822 def strict_loaded_associations; end # @raise [ActiveRecordError] # - # source://activerecord//lib/active_record/persistence.rb#1110 + # source://activerecord//lib/active_record/persistence.rb#947 def verify_readonly_attribute(name); end end # source://activerecord//lib/active_record/persistence.rb#10 module ActiveRecord::Persistence::ClassMethods - # source://activerecord//lib/active_record/persistence.rb#516 + # source://activerecord//lib/active_record/persistence.rb#284 def _delete_record(constraints); end - # source://activerecord//lib/active_record/persistence.rb#477 - def _insert_record(values); end + # source://activerecord//lib/active_record/persistence.rb#238 + def _insert_record(connection, values, returning); end - # source://activerecord//lib/active_record/persistence.rb#499 + # source://activerecord//lib/active_record/persistence.rb#265 def _update_record(values, constraints); end + # Builds an object (or multiple objects) and returns either the built object or a list of built + # objects. + # + # The +attributes+ parameter can be either a Hash or an Array of Hashes. These Hashes describe the + # attributes on the objects that are to be built. + # + # ==== Examples + # # Build a single new object + # User.build(first_name: 'Jamie') + # + # # Build an Array of new objects + # User.build([{ first_name: 'Jamie' }, { first_name: 'Jeremy' }]) + # + # # Build a single object and pass it into a block to set other attributes. + # User.build(first_name: 'Jamie') do |u| + # u.is_admin = false + # end + # + # # Building an Array of new objects using a block, where the block is executed for each object: + # User.build([{ first_name: 'Jamie' }, { first_name: 'Jeremy' }]) do |u| + # u.is_admin = false + # end + # + # source://activerecord//lib/active_record/persistence.rb#82 + def build(attributes = T.unsafe(nil), &block); end + + # Returns an array of column names to be used in queries. The source of column + # names is derived from +query_constraints_list+ or +primary_key+. This method + # is for internal use when the primary key is to be treated as an array. + # + # source://activerecord//lib/active_record/persistence.rb#234 + def composite_query_constraints_list; end + # Creates an object (or multiple objects) and saves it to the database, if validations pass. # The resulting object is returned whether the object was saved successfully to the database or not. # @@ -25390,220 +28230,63 @@ module ActiveRecord::Persistence::ClassMethods # source://activerecord//lib/active_record/persistence.rb#50 def create!(attributes = T.unsafe(nil), &block); end - # Deletes the row with a primary key matching the +id+ argument, using an - # SQL +DELETE+ statement, and returns the number of rows deleted. Active - # Record objects are not instantiated, so the object's callbacks are not - # executed, including any :dependent association options. - # - # You can delete multiple rows at once by passing an Array of ids. - # - # Note: Although it is often much faster than the alternative, #destroy, - # skipping callbacks might bypass business logic in your application - # that ensures referential integrity or performs other essential jobs. - # - # ==== Examples - # - # # Delete a single row - # Todo.delete(1) - # - # # Delete multiple rows - # Todo.delete([2,3,4]) - # - # source://activerecord//lib/active_record/persistence.rb#473 - def delete(id_or_array); end - - # Destroy an object (or multiple objects) that has the given id. The object is instantiated first, - # therefore all callbacks and filters are fired off before the object is deleted. This method is - # less efficient than #delete but allows cleanup methods and other actions to be run. - # - # This essentially finds the object (or multiple objects) with the given id, creates a new object - # from the attributes, and then calls destroy on it. - # - # ==== Parameters - # - # * +id+ - This should be the id or an array of ids to be destroyed. - # - # ==== Examples - # - # # Destroy a single object - # Todo.destroy(1) - # - # # Destroy multiple objects - # todos = [1,2,3] - # Todo.destroy(todos) - # - # source://activerecord//lib/active_record/persistence.rb#447 - def destroy(id); end - - # Inserts a single record into the database in a single SQL INSERT - # statement. It does not instantiate any models nor does it trigger - # Active Record callbacks or validations. Though passed values - # go through Active Record's type casting and serialization. - # - # See #insert_all for documentation. - # - # source://activerecord//lib/active_record/persistence.rb#66 - def insert(attributes, returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end - - # Inserts a single record into the database in a single SQL INSERT - # statement. It does not instantiate any models nor does it trigger - # Active Record callbacks or validations. Though passed values - # go through Active Record's type casting and serialization. - # - # See #insert_all! for more. + # @return [Boolean] # - # source://activerecord//lib/active_record/persistence.rb#155 - def insert!(attributes, returning: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + # source://activerecord//lib/active_record/persistence.rb#219 + def has_query_constraints?; end - # Inserts multiple records into the database in a single SQL INSERT - # statement. It does not instantiate any models nor does it trigger - # Active Record callbacks or validations. Though passed values - # go through Active Record's type casting and serialization. - # - # The +attributes+ parameter is an Array of Hashes. Every Hash determines - # the attributes for a single row and must have the same keys. - # - # Rows are considered to be unique by every unique index on the table. Any - # duplicate rows are skipped. - # Override with :unique_by (see below). - # - # Returns an ActiveRecord::Result with its contents based on - # :returning (see below). - # - # ==== Options - # - # [:returning] - # (PostgreSQL only) An array of attributes to return for all successfully - # inserted records, which by default is the primary key. - # Pass returning: %w[ id name ] for both id and name - # or returning: false to omit the underlying RETURNING SQL - # clause entirely. - # - # You can also pass an SQL string if you need more control on the return values - # (for example, returning: "id, name as new_name"). - # - # [:unique_by] - # (PostgreSQL and SQLite only) By default rows are considered to be unique - # by every unique index on the table. Any duplicate rows are skipped. - # - # To skip rows according to just one unique index pass :unique_by. - # - # Consider a Book model where no duplicate ISBNs make sense, but if any - # row has an existing id, or is not unique by another unique index, - # ActiveRecord::RecordNotUnique is raised. - # - # Unique indexes can be identified by columns or name: - # - # unique_by: :isbn - # unique_by: %i[ author_id name ] - # unique_by: :index_books_on_isbn - # - # [:record_timestamps] - # By default, automatic setting of timestamp columns is controlled by - # the model's record_timestamps config, matching typical - # behavior. - # - # To override this and force automatic setting of timestamp columns one - # way or the other, pass :record_timestamps: - # - # record_timestamps: true # Always set timestamps automatically - # record_timestamps: false # Never set timestamps automatically - # - # Because it relies on the index information from the database - # :unique_by is recommended to be paired with - # Active Record's schema_cache. - # - # ==== Example - # - # # Insert records and skip inserting any duplicates. - # # Here "Eloquent Ruby" is skipped because its id is not unique. - # - # Book.insert_all([ - # { id: 1, title: "Rework", author: "David" }, - # { id: 1, title: "Eloquent Ruby", author: "Russ" } - # ]) + # Given an attributes hash, +instantiate+ returns a new instance of + # the appropriate class. Accepts only keys as strings. # - # # insert_all works on chained scopes, and you can use create_with - # # to set default attributes for all inserted records. + # For example, +Post.all+ may return Comments, Messages, and Emails + # by storing the record's subclass in a +type+ attribute. By calling + # +instantiate+ instead of +new+, finder methods ensure they get new + # instances of the appropriate class for each record. # - # author.books.create_with(created_at: Time.now).insert_all([ - # { id: 1, title: "Rework" }, - # { id: 2, title: "Eloquent Ruby" } - # ]) + # See ActiveRecord::Inheritance#discriminate_class_for_record to see + # how this "single-table" inheritance mapping is implemented. # - # source://activerecord//lib/active_record/persistence.rb#145 - def insert_all(attributes, returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + # source://activerecord//lib/active_record/persistence.rb#100 + def instantiate(attributes, column_types = T.unsafe(nil), &block); end - # Inserts multiple records into the database in a single SQL INSERT - # statement. It does not instantiate any models nor does it trigger - # Active Record callbacks or validations. Though passed values - # go through Active Record's type casting and serialization. + # Accepts a list of attribute names to be used in the WHERE clause + # of SELECT / UPDATE / DELETE queries and in the ORDER BY clause for +#first+ and +#last+ finder methods. # - # The +attributes+ parameter is an Array of Hashes. Every Hash determines - # the attributes for a single row and must have the same keys. + # class Developer < ActiveRecord::Base + # query_constraints :company_id, :id + # end # - # Raises ActiveRecord::RecordNotUnique if any rows violate a - # unique index on the table. In that case, no rows are inserted. + # developer = Developer.first + # # SELECT "developers".* FROM "developers" ORDER BY "developers"."company_id" ASC, "developers"."id" ASC LIMIT 1 + # developer.inspect # => # # - # To skip duplicate rows, see #insert_all. To replace them, see #upsert_all. + # developer.update!(name: "Nikita") + # # UPDATE "developers" SET "name" = 'Nikita' WHERE "developers"."company_id" = 1 AND "developers"."id" = 1 # - # Returns an ActiveRecord::Result with its contents based on - # :returning (see below). + # # It is possible to update an attribute used in the query_constraints clause: + # developer.update!(company_id: 2) + # # UPDATE "developers" SET "company_id" = 2 WHERE "developers"."company_id" = 1 AND "developers"."id" = 1 # - # ==== Options + # developer.name = "Bob" + # developer.save! + # # UPDATE "developers" SET "name" = 'Bob' WHERE "developers"."company_id" = 1 AND "developers"."id" = 1 # - # [:returning] - # (PostgreSQL only) An array of attributes to return for all successfully - # inserted records, which by default is the primary key. - # Pass returning: %w[ id name ] for both id and name - # or returning: false to omit the underlying RETURNING SQL - # clause entirely. + # developer.destroy! + # # DELETE FROM "developers" WHERE "developers"."company_id" = 1 AND "developers"."id" = 1 # - # You can also pass an SQL string if you need more control on the return values - # (for example, returning: "id, name as new_name"). + # developer.delete + # # DELETE FROM "developers" WHERE "developers"."company_id" = 1 AND "developers"."id" = 1 # - # [:record_timestamps] - # By default, automatic setting of timestamp columns is controlled by - # the model's record_timestamps config, matching typical - # behavior. - # - # To override this and force automatic setting of timestamp columns one - # way or the other, pass :record_timestamps: - # - # record_timestamps: true # Always set timestamps automatically - # record_timestamps: false # Never set timestamps automatically - # - # ==== Examples - # - # # Insert multiple records - # Book.insert_all!([ - # { title: "Rework", author: "David" }, - # { title: "Eloquent Ruby", author: "Russ" } - # ]) + # developer.reload + # # SELECT "developers".* FROM "developers" WHERE "developers"."company_id" = 1 AND "developers"."id" = 1 LIMIT 1 # - # # Raises ActiveRecord::RecordNotUnique because "Eloquent Ruby" - # # does not have a unique id. - # Book.insert_all!([ - # { id: 1, title: "Rework", author: "David" }, - # { id: 1, title: "Eloquent Ruby", author: "Russ" } - # ]) + # @raise [ArgumentError] # # source://activerecord//lib/active_record/persistence.rb#212 - def insert_all!(attributes, returning: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + def query_constraints(*columns_list); end - # Given an attributes hash, +instantiate+ returns a new instance of - # the appropriate class. Accepts only keys as strings. - # - # For example, +Post.all+ may return Comments, Messages, and Emails - # by storing the record's subclass in a +type+ attribute. By calling - # +instantiate+ instead of +new+, finder methods ensure they get new - # instances of the appropriate class for each record. - # - # See ActiveRecord::Inheritance#discriminate_class_for_record to see - # how this "single-table" inheritance mapping is implemented. - # - # source://activerecord//lib/active_record/persistence.rb#346 - def instantiate(attributes, column_types = T.unsafe(nil), &block); end + # source://activerecord//lib/active_record/persistence.rb#223 + def query_constraints_list; end # Updates an object (or multiple objects) and saves it to the database, if validations pass. # The resulting object is returned whether the object was saved successfully to the database or not. @@ -25633,142 +28316,22 @@ module ActiveRecord::Persistence::ClassMethods # it is preferred to use {update_all}[rdoc-ref:Relation#update_all] # for updating all records in a single query. # - # source://activerecord//lib/active_record/persistence.rb#378 + # source://activerecord//lib/active_record/persistence.rb#132 def update(id = T.unsafe(nil), attributes); end # Updates the object (or multiple objects) just like #update but calls #update! instead # of +update+, so an exception is raised if the record is invalid and saving will fail. # - # source://activerecord//lib/active_record/persistence.rb#404 + # source://activerecord//lib/active_record/persistence.rb#158 def update!(id = T.unsafe(nil), attributes); end - # Updates or inserts (upserts) a single record into the database in a - # single SQL INSERT statement. It does not instantiate any models nor does - # it trigger Active Record callbacks or validations. Though passed values - # go through Active Record's type casting and serialization. - # - # See #upsert_all for documentation. - # - # source://activerecord//lib/active_record/persistence.rb#222 - def upsert(attributes, on_duplicate: T.unsafe(nil), returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end - - # Updates or inserts (upserts) multiple records into the database in a - # single SQL INSERT statement. It does not instantiate any models nor does - # it trigger Active Record callbacks or validations. Though passed values - # go through Active Record's type casting and serialization. - # - # The +attributes+ parameter is an Array of Hashes. Every Hash determines - # the attributes for a single row and must have the same keys. - # - # Returns an ActiveRecord::Result with its contents based on - # :returning (see below). - # - # By default, +upsert_all+ will update all the columns that can be updated when - # there is a conflict. These are all the columns except primary keys, read-only - # columns, and columns covered by the optional +unique_by+. - # - # ==== Options - # - # [:returning] - # (PostgreSQL only) An array of attributes to return for all successfully - # inserted records, which by default is the primary key. - # Pass returning: %w[ id name ] for both id and name - # or returning: false to omit the underlying RETURNING SQL - # clause entirely. - # - # You can also pass an SQL string if you need more control on the return values - # (for example, returning: "id, name as new_name"). - # - # [:unique_by] - # (PostgreSQL and SQLite only) By default rows are considered to be unique - # by every unique index on the table. Any duplicate rows are skipped. - # - # To skip rows according to just one unique index pass :unique_by. - # - # Consider a Book model where no duplicate ISBNs make sense, but if any - # row has an existing id, or is not unique by another unique index, - # ActiveRecord::RecordNotUnique is raised. - # - # Unique indexes can be identified by columns or name: - # - # unique_by: :isbn - # unique_by: %i[ author_id name ] - # unique_by: :index_books_on_isbn - # - # Because it relies on the index information from the database - # :unique_by is recommended to be paired with - # Active Record's schema_cache. - # - # [:on_duplicate] - # Configure the SQL update sentence that will be used in case of conflict. - # - # NOTE: If you use this option you must provide all the columns you want to update - # by yourself. - # - # Example: - # - # Commodity.upsert_all( - # [ - # { id: 2, name: "Copper", price: 4.84 }, - # { id: 4, name: "Gold", price: 1380.87 }, - # { id: 6, name: "Aluminium", price: 0.35 } - # ], - # on_duplicate: Arel.sql("price = GREATEST(commodities.price, EXCLUDED.price)") - # ) - # - # See the related +:update_only+ option. Both options can't be used at the same time. - # - # [:update_only] - # Provide a list of column names that will be updated in case of conflict. If not provided, - # +upsert_all+ will update all the columns that can be updated. These are all the columns - # except primary keys, read-only columns, and columns covered by the optional +unique_by+ - # - # Example: - # - # Commodity.upsert_all( - # [ - # { id: 2, name: "Copper", price: 4.84 }, - # { id: 4, name: "Gold", price: 1380.87 }, - # { id: 6, name: "Aluminium", price: 0.35 } - # ], - # update_only: [:price] # Only prices will be updated - # ) - # - # See the related +:on_duplicate+ option. Both options can't be used at the same time. - # - # [:record_timestamps] - # By default, automatic setting of timestamp columns is controlled by - # the model's record_timestamps config, matching typical - # behavior. - # - # To override this and force automatic setting of timestamp columns one - # way or the other, pass :record_timestamps: - # - # record_timestamps: true # Always set timestamps automatically - # record_timestamps: false # Never set timestamps automatically - # - # ==== Examples - # - # # Inserts multiple records, performing an upsert when records have duplicate ISBNs. - # # Here "Eloquent Ruby" overwrites "Rework" because its ISBN is duplicate. - # - # Book.upsert_all([ - # { title: "Rework", author: "David", isbn: "1" }, - # { title: "Eloquent Ruby", author: "Russ", isbn: "1" } - # ], unique_by: :isbn) - # - # Book.find_by(isbn: "1").title # => "Eloquent Ruby" - # - # source://activerecord//lib/active_record/persistence.rb#332 - def upsert_all(attributes, on_duplicate: T.unsafe(nil), update_only: T.unsafe(nil), returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end - private # Called by +_update_record+ and +_delete_record+ # to build `where` clause from default scopes. # Skips empty scopes. # - # source://activerecord//lib/active_record/persistence.rb#552 + # source://activerecord//lib/active_record/persistence.rb#330 def build_default_constraint; end # Called by +instantiate+ to decide which class to use for a new @@ -25777,13 +28340,16 @@ module ActiveRecord::Persistence::ClassMethods # See +ActiveRecord::Inheritance#discriminate_class_for_record+ for # the single-table inheritance discriminator. # - # source://activerecord//lib/active_record/persistence.rb#545 + # source://activerecord//lib/active_record/persistence.rb#323 def discriminate_class_for_record(record); end + # source://activerecord//lib/active_record/persistence.rb#303 + def inherited(subclass); end + # Given a class, an attributes hash, +instantiate_instance_of+ returns a # new instance of the class. Accepts only keys as strings. # - # source://activerecord//lib/active_record/persistence.rb#535 + # source://activerecord//lib/active_record/persistence.rb#313 def instantiate_instance_of(klass, attributes, column_types = T.unsafe(nil), &block); end end @@ -25821,28 +28387,28 @@ class ActiveRecord::PredicateBuilder # source://activerecord//lib/active_record/relation/predicate_builder.rb#49 def register_handler(klass, handler); end - # source://activerecord//lib/active_record/relation/predicate_builder.rb#72 + # source://activerecord//lib/active_record/relation/predicate_builder.rb#71 def resolve_arel_attribute(table_name, column_name, &block); end protected - # source://activerecord//lib/active_record/relation/predicate_builder.rb#77 + # source://activerecord//lib/active_record/relation/predicate_builder.rb#76 def expand_from_hash(attributes, &block); end private - # source://activerecord//lib/active_record/relation/predicate_builder.rb#145 + # source://activerecord//lib/active_record/relation/predicate_builder.rb#150 def convert_dot_notation_to_hash(attributes); end - # source://activerecord//lib/active_record/relation/predicate_builder.rb#135 + # source://activerecord//lib/active_record/relation/predicate_builder.rb#140 def grouping_queries(queries); end - # source://activerecord//lib/active_record/relation/predicate_builder.rb#161 + # source://activerecord//lib/active_record/relation/predicate_builder.rb#172 def handler_for(object); end # Returns the value of attribute table. # - # source://activerecord//lib/active_record/relation/predicate_builder.rb#133 + # source://activerecord//lib/active_record/relation/predicate_builder.rb#138 def table; end class << self @@ -25891,21 +28457,37 @@ class ActiveRecord::PredicateBuilder::AssociationQueryValue # Returns the value of attribute associated_table. # - # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#16 + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#23 def associated_table; end - # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#33 + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#59 def convert_to_id(value); end - # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#18 + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#25 def ids; end - # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#29 + # @return [Boolean] + # + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#55 + def polymorphic_clause?; end + + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#47 + def polymorphic_name; end + + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#39 def primary_key; end + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#43 + def primary_type; end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#51 + def select_clause?; end + # Returns the value of attribute value. # - # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#16 + # source://activerecord//lib/active_record/relation/predicate_builder/association_query_value.rb#23 def value; end end @@ -25944,7 +28526,7 @@ class ActiveRecord::PredicateBuilder::PolymorphicArrayValue # source://activerecord//lib/active_record/relation/predicate_builder/polymorphic_array_value.rb#23 def associated_table; end - # source://activerecord//lib/active_record/relation/predicate_builder/polymorphic_array_value.rb#45 + # source://activerecord//lib/active_record/relation/predicate_builder/polymorphic_array_value.rb#44 def convert_to_id(value); end # source://activerecord//lib/active_record/relation/predicate_builder/polymorphic_array_value.rb#36 @@ -26027,7 +28609,7 @@ end # Raised when PostgreSQL returns 'cached plan must not change result type' and # we cannot retry gracefully (e.g. inside a transaction) # -# source://activerecord//lib/active_record/errors.rb#271 +# source://activerecord//lib/active_record/errors.rb#349 class ActiveRecord::PreparedStatementCacheExpired < ::ActiveRecord::StatementInvalid; end # Raised when the number of placeholders in an SQL fragment passed to @@ -26038,20 +28620,94 @@ class ActiveRecord::PreparedStatementCacheExpired < ::ActiveRecord::StatementInv # # Location.where("lat = ? AND lng = ?", 53.7362) # -# source://activerecord//lib/active_record/errors.rb#234 +# source://activerecord//lib/active_record/errors.rb#311 class ActiveRecord::PreparedStatementInvalid < ::ActiveRecord::ActiveRecordError; end -# source://activerecord//lib/active_record/migration.rb#188 +# source://activerecord//lib/active_record/promise.rb#4 +class ActiveRecord::Promise < ::BasicObject + # @return [Promise] a new instance of Promise + # + # source://activerecord//lib/active_record/promise.rb#7 + def initialize(future_result, block); end + + def class; end + + # source://activerecord//lib/active_record/promise.rb#44 + def inspect; end + + def is_a?(_arg0); end + + # Returns whether the associated query is still being executed or not. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/promise.rb#13 + def pending?; end + + # source://activerecord//lib/active_record/promise.rb#48 + def pretty_print(q); end + + def respond_to?(*_arg0); end + + # Returns a new +ActiveRecord::Promise+ that will apply the passed block + # when the value is accessed: + # + # Post.async_pick(:title).then { |title| title.upcase }.value + # # => "POST TITLE" + # + # source://activerecord//lib/active_record/promise.rb#36 + def then(&block); end + + # Returns the query result. + # If the query wasn't completed yet, accessing +#value+ will block until the query completes. + # If the query failed, +#value+ will raise the corresponding error. + # + # source://activerecord//lib/active_record/promise.rb#20 + def value; end + + private + + # source://activerecord//lib/active_record/promise.rb#53 + def status; end +end + +# source://activerecord//lib/active_record/promise.rb#63 +class ActiveRecord::Promise::Complete < ::ActiveRecord::Promise + # @return [Complete] a new instance of Complete + # + # source://activerecord//lib/active_record/promise.rb#66 + def initialize(value); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/promise.rb#74 + def pending?; end + + # source://activerecord//lib/active_record/promise.rb#70 + def then; end + + # Returns the value of attribute value. + # + # source://activerecord//lib/active_record/promise.rb#64 + def value; end + + private + + # source://activerecord//lib/active_record/promise.rb#79 + def status; end +end + +# source://activerecord//lib/active_record/migration.rb#210 class ActiveRecord::ProtectedEnvironmentError < ::ActiveRecord::ActiveRecordError # @return [ProtectedEnvironmentError] a new instance of ProtectedEnvironmentError # - # source://activerecord//lib/active_record/migration.rb#189 + # source://activerecord//lib/active_record/migration.rb#211 def initialize(env = T.unsafe(nil)); end end # Superclass for errors that have been aborted (either by client or server). # -# source://activerecord//lib/active_record/errors.rb#445 +# source://activerecord//lib/active_record/errors.rb#553 class ActiveRecord::QueryAborted < ::ActiveRecord::StatementInvalid; end # = Active Record Query Cache @@ -26059,13 +28715,13 @@ class ActiveRecord::QueryAborted < ::ActiveRecord::StatementInvalid; end # source://activerecord//lib/active_record/query_cache.rb#5 class ActiveRecord::QueryCache class << self - # source://activerecord//lib/active_record/query_cache.rb#42 + # source://activerecord//lib/active_record/query_cache.rb#41 def complete(pools); end - # source://activerecord//lib/active_record/query_cache.rb#58 + # source://activerecord//lib/active_record/query_cache.rb#52 def install_executor_hooks(executor = T.unsafe(nil)); end - # source://activerecord//lib/active_record/query_cache.rb#28 + # source://activerecord//lib/active_record/query_cache.rb#37 def run; end end end @@ -26081,69 +28737,76 @@ module ActiveRecord::QueryCache::ClassMethods # Disable the query cache within the block if Active Record is configured. # If it's not, it will execute the given block. # - # source://activerecord//lib/active_record/query_cache.rb#19 - def uncached(&block); end + # Set dirties: false to prevent query caches on all connections from being cleared by write operations. + # (By default, write operations dirty all connections' query caches in case they are replicas whose cache would now be outdated.) + # + # source://activerecord//lib/active_record/query_cache.rb#28 + def uncached(dirties: T.unsafe(nil), &block); end end # QueryCanceled will be raised when canceling statement due to user request. # -# source://activerecord//lib/active_record/errors.rb#457 +# source://activerecord//lib/active_record/errors.rb#565 class ActiveRecord::QueryCanceled < ::ActiveRecord::QueryAborted; end # = Active Record Query Logs # -# Automatically tag SQL queries with runtime information. +# Automatically append comments to SQL queries with runtime information tags. This can be used to trace troublesome +# SQL statements back to the application code that generated these statements. +# +# Query logs can be enabled via \Rails configuration in config/application.rb or an initializer: +# +# config.active_record.query_log_tags_enabled = true +# +# By default the name of the application, the name and action of the controller, or the name of the job are logged. +# The default format is {SQLCommenter}[https://open-telemetry.github.io/opentelemetry-sqlcommenter/]. +# The tags shown in a query comment can be configured via \Rails configuration: +# +# config.active_record.query_log_tags = [ :application, :controller, :action, :job ] # -# Default tags available for use: +# Active Record defines default tags available for use: # # * +application+ # * +pid+ # * +socket+ # * +db_host+ # * +database+ +# * +source_location+ # -# _Action Controller and Active Job tags are also defined when used in Rails:_ +# Action Controller adds default tags when loaded: # # * +controller+ # * +action+ -# * +job+ -# -# The tags used in a query can be configured directly: +# * +namespaced_controller+ # -# ActiveRecord::QueryLogs.tags = [ :application, :controller, :action, :job ] +# Active Job adds default tags when loaded: # -# or via Rails configuration: -# -# config.active_record.query_log_tags = [ :application, :controller, :action, :job ] +# * +job+ # -# To add new comment tags, add a hash to the tags array containing the keys and values you -# want to add to the comment. Dynamic content can be created by setting a proc or lambda value in a hash, -# and can reference any value stored in the +context+ object. +# New comment tags can be defined by adding them in a +Hash+ to the tags +Array+. Tags can have dynamic content by +# setting a +Proc+ or lambda value in the +Hash+, and can reference any value stored by \Rails in the +context+ object. +# ActiveSupport::CurrentAttributes can be used to store application values. Tags with +nil+ values are +# omitted from the query comment. # # Escaping is performed on the string returned, however untrusted user input should not be used. # # Example: # -# tags = [ -# :application, -# { -# custom_tag: ->(context) { context[:controller]&.controller_name }, -# custom_value: -> { Custom.value }, -# } -# ] -# ActiveRecord::QueryLogs.tags = tags -# -# The QueryLogs +context+ can be manipulated via the +ActiveSupport::ExecutionContext.set+ method. -# -# Temporary updates limited to the execution of a block: -# -# ActiveSupport::ExecutionContext.set(foo: Bar.new) do -# posts = Post.all -# end -# -# Direct updates to a context value: +# config.active_record.query_log_tags = [ +# :namespaced_controller, +# :action, +# :job, +# { +# request_id: ->(context) { context[:controller]&.request&.request_id }, +# job_id: ->(context) { context[:job]&.job_id }, +# tenant_id: -> { Current.tenant&.id }, +# static: "value", +# }, +# ] # -# ActiveSupport::ExecutionContext[:foo] = Bar.new +# By default the name of the application, the name and action of the controller, or the name of the job are logged +# using the {SQLCommenter}[https://open-telemetry.github.io/opentelemetry-sqlcommenter/] format. This can be changed +# via {config.active_record.query_log_tags_format}[https://guides.rubyonrails.org/configuring.html#config-active-record-query-log-tags-format] # # Tag comments can be prepended to the query: # @@ -26152,75 +28815,127 @@ class ActiveRecord::QueryCanceled < ::ActiveRecord::QueryAborted; end # For applications where the content will not change during the lifetime of # the request or job execution, the tags can be cached for reuse in every query: # -# ActiveRecord::QueryLogs.cache_query_log_tags = true -# -# This option can be set during application configuration or in a Rails initializer: -# # config.active_record.cache_query_log_tags = true # -# source://activerecord//lib/active_record/query_logs.rb#73 +# source://activerecord//lib/active_record/query_logs_formatter.rb#4 module ActiveRecord::QueryLogs class << self - # source://activerecord//lib/active_record/query_logs.rb#77 + # source://activerecord//lib/active_record/query_logs.rb#78 def cache_query_log_tags; end - # source://activerecord//lib/active_record/query_logs.rb#77 + # source://activerecord//lib/active_record/query_logs.rb#78 def cache_query_log_tags=(val); end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#48 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#49 def cached_comment; end - # source://activesupport/7.0.5/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#92 + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#108 def cached_comment=(obj); end - # source://activerecord//lib/active_record/query_logs.rb#81 - def call(sql); end + # source://activerecord//lib/active_record/query_logs.rb#83 + def call(sql, connection); end - # source://activerecord//lib/active_record/query_logs.rb#89 + # source://activerecord//lib/active_record/query_logs.rb#95 def clear_cache; end - # source://activerecord//lib/active_record/query_logs.rb#76 + # source://activerecord//lib/active_record/query_logs.rb#77 def prepend_comment; end - # source://activerecord//lib/active_record/query_logs.rb#76 + # source://activerecord//lib/active_record/query_logs.rb#77 def prepend_comment=(val); end - # source://activerecord//lib/active_record/query_logs.rb#74 + # source://activerecord//lib/active_record/query_logs.rb#113 + def query_source_location; end + + # source://activerecord//lib/active_record/query_logs.rb#75 def taggings; end - # source://activerecord//lib/active_record/query_logs.rb#74 + # source://activerecord//lib/active_record/query_logs.rb#75 def taggings=(val); end - # source://activerecord//lib/active_record/query_logs.rb#75 + # source://activerecord//lib/active_record/query_logs.rb#76 def tags; end - # source://activerecord//lib/active_record/query_logs.rb#75 + # source://activerecord//lib/active_record/query_logs.rb#76 def tags=(val); end + # source://activerecord//lib/active_record/query_logs.rb#79 + def tags_formatter; end + + # source://activerecord//lib/active_record/query_logs.rb#79 + def tags_formatter=(val); end + + # Updates the formatter to be what the passed in format is. + # + # source://activerecord//lib/active_record/query_logs.rb#100 + def update_formatter(format); end + private # Returns an SQL comment +String+ containing the query log tags. # Sets and returns a cached comment if cache_query_log_tags is +true+. # - # source://activerecord//lib/active_record/query_logs.rb#98 - def comment; end + # source://activerecord//lib/active_record/query_logs.rb#131 + def comment(connection); end - # source://activerecord//lib/active_record/query_logs.rb#113 + # source://activerecord//lib/active_record/query_logs.rb#151 def escape_sql_comment(content); end - # source://activerecord//lib/active_record/query_logs.rb#126 - def tag_content; end + # source://activerecord//lib/active_record/query_logs.rb#139 + def formatter; end - # source://activerecord//lib/active_record/query_logs.rb#106 - def uncached_comment; end + # source://activerecord//lib/active_record/query_logs.rb#164 + def tag_content(connection); end + + # source://activerecord//lib/active_record/query_logs.rb#143 + def uncached_comment(connection); end end end -# source://activerecord//lib/active_record/relation/query_methods.rb#10 +# source://activerecord//lib/active_record/query_logs_formatter.rb#5 +class ActiveRecord::QueryLogs::LegacyFormatter + # @return [LegacyFormatter] a new instance of LegacyFormatter + # + # source://activerecord//lib/active_record/query_logs_formatter.rb#6 + def initialize; end + + # Formats the key value pairs into a string. + # + # source://activerecord//lib/active_record/query_logs_formatter.rb#11 + def format(pairs); end + + private + + # source://activerecord//lib/active_record/query_logs_formatter.rb#20 + def format_value(value); end + + # Returns the value of attribute key_value_separator. + # + # source://activerecord//lib/active_record/query_logs_formatter.rb#18 + def key_value_separator; end +end + +# source://activerecord//lib/active_record/query_logs_formatter.rb#25 +class ActiveRecord::QueryLogs::SQLCommenter < ::ActiveRecord::QueryLogs::LegacyFormatter + # @return [SQLCommenter] a new instance of SQLCommenter + # + # source://activerecord//lib/active_record/query_logs_formatter.rb#26 + def initialize; end + + # source://activerecord//lib/active_record/query_logs_formatter.rb#30 + def format(pairs); end + + private + + # source://activerecord//lib/active_record/query_logs_formatter.rb#36 + def format_value(value); end +end + +# source://activerecord//lib/active_record/relation/query_methods.rb#9 module ActiveRecord::QueryMethods include ::ActiveModel::ForbiddenAttributesProtection - # source://activerecord//lib/active_record/relation/query_methods.rb#317 + # source://activerecord//lib/active_record/relation/query_methods.rb#421 def _select!(*fields); end # Returns a new relation, which is the logical intersection of this relation and the one passed @@ -26233,10 +28948,10 @@ module ActiveRecord::QueryMethods # Post.where(id: [1, 2]).and(Post.where(id: [2, 3])) # # SELECT `posts`.* FROM `posts` WHERE `posts`.`id` IN (1, 2) AND `posts`.`id` IN (2, 3) # - # source://activerecord//lib/active_record/relation/query_methods.rb#845 + # source://activerecord//lib/active_record/relation/query_methods.rb#1113 def and(other); end - # source://activerecord//lib/active_record/relation/query_methods.rb#853 + # source://activerecord//lib/active_record/relation/query_methods.rb#1121 def and!(other); end # Adds an SQL comment to queries generated from this relation. For example: @@ -26251,26 +28966,26 @@ module ActiveRecord::QueryMethods # # Some escaping is performed, however untrusted user input should not be used. # - # source://activerecord//lib/active_record/relation/query_methods.rb#1221 + # source://activerecord//lib/active_record/relation/query_methods.rb#1507 def annotate(*args); end # Like #annotate, but modifies relation in place. # - # source://activerecord//lib/active_record/relation/query_methods.rb#1227 + # source://activerecord//lib/active_record/relation/query_methods.rb#1513 def annotate!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def annotate_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def annotate_values=(value); end # Returns the Arel object associated with the relation. # - # source://activerecord//lib/active_record/relation/query_methods.rb#1282 + # source://activerecord//lib/active_record/relation/query_methods.rb#1572 def arel(aliases = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1286 + # source://activerecord//lib/active_record/relation/query_methods.rb#1576 def construct_join_dependency(associations, join_type); end # Sets attributes to be used when creating new records from a @@ -26287,16 +29002,16 @@ module ActiveRecord::QueryMethods # users = users.create_with(nil) # users.new.name # => 'Oscar' # - # source://activerecord//lib/active_record/relation/query_methods.rb#1038 + # source://activerecord//lib/active_record/relation/query_methods.rb#1324 def create_with(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1042 + # source://activerecord//lib/active_record/relation/query_methods.rb#1328 def create_with!(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def create_with_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def create_with_value=(value); end # Specifies whether the records should be unique or not. For example: @@ -26310,37 +29025,57 @@ module ActiveRecord::QueryMethods # User.select(:name).distinct.distinct(false) # # You can also remove the uniqueness # - # source://activerecord//lib/active_record/relation/query_methods.rb#1102 + # source://activerecord//lib/active_record/relation/query_methods.rb#1388 def distinct(value = T.unsafe(nil)); end # Like #distinct, but modifies relation in place. # - # source://activerecord//lib/active_record/relation/query_methods.rb#1107 + # source://activerecord//lib/active_record/relation/query_methods.rb#1393 def distinct!(value = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def distinct_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def distinct_value=(value); end - # Forces eager loading by performing a LEFT OUTER JOIN on +args+: + # Specify associations +args+ to be eager loaded using a LEFT OUTER JOIN. + # Performs a single query joining all specified associations. For example: + # + # users = User.eager_load(:address).limit(5) + # users.each do |user| + # user.address.city + # end + # + # # SELECT "users"."id" AS t0_r0, "users"."name" AS t0_r1, ... FROM "users" + # # LEFT OUTER JOIN "addresses" ON "addresses"."id" = "users"."address_id" + # # LIMIT 5 + # + # Instead of loading the 5 addresses with 5 separate queries, all addresses + # are loaded with a single joined query. + # + # Loading multiple and nested associations is possible using Hashes and Arrays, + # similar to #includes: + # + # User.eager_load(:address, friends: [:address, :followers]) + # # SELECT "users"."id" AS t0_r0, "users"."name" AS t0_r1, ... FROM "users" + # # LEFT OUTER JOIN "addresses" ON "addresses"."id" = "users"."address_id" + # # LEFT OUTER JOIN "friends" ON "friends"."user_id" = "users"."id" + # # ... # - # User.eager_load(:posts) - # # SELECT "users"."id" AS t0_r0, "users"."name" AS t0_r1, ... - # # FROM "users" LEFT OUTER JOIN "posts" ON "posts"."user_id" = - # # "users"."id" + # NOTE: Loading the associations in a join can result in many rows that + # contain redundant data and it performs poorly at scale. # - # source://activerecord//lib/active_record/relation/query_methods.rb#207 + # source://activerecord//lib/active_record/relation/query_methods.rb#283 def eager_load(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#212 + # source://activerecord//lib/active_record/relation/query_methods.rb#288 def eager_load!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def eager_load_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def eager_load_values=(value); end # Excludes the specified record (or collection of records) from the resulting @@ -26352,6 +29087,9 @@ module ActiveRecord::QueryMethods # Post.excluding(post_one, post_two) # # SELECT "posts".* FROM "posts" WHERE "posts"."id" NOT IN (1, 2) # + # Post.excluding(Post.drafts) + # # SELECT "posts".* FROM "posts" WHERE "posts"."id" NOT IN (3, 4, 5) + # # This can also be called on associations. As with the above example, either # a single record of collection thereof may be specified: # @@ -26367,10 +29105,10 @@ module ActiveRecord::QueryMethods # is passed in) are not instances of the same model that the relation is # scoping. # - # source://activerecord//lib/active_record/relation/query_methods.rb#1263 + # source://activerecord//lib/active_record/relation/query_methods.rb#1552 def excluding(*records); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1275 + # source://activerecord//lib/active_record/relation/query_methods.rb#1565 def excluding!(records); end # Used to extend a scope with additional methods, either through @@ -26378,7 +29116,7 @@ module ActiveRecord::QueryMethods # # The object returned is a relation, which can be further extended. # - # === Using a module + # === Using a \Module # # module Pagination # def page(number) @@ -26393,7 +29131,7 @@ module ActiveRecord::QueryMethods # # scope = Model.all.extending(Pagination, SomethingElse) # - # === Using a block + # === Using a Block # # scope = Model.all.extending do # def page(number) @@ -26410,19 +29148,19 @@ module ActiveRecord::QueryMethods # end # end # - # source://activerecord//lib/active_record/relation/query_methods.rb#1148 + # source://activerecord//lib/active_record/relation/query_methods.rb#1434 def extending(*modules, &block); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1156 + # source://activerecord//lib/active_record/relation/query_methods.rb#1442 def extending!(*modules, &block); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def extending_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def extending_values=(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def extensions; end # Extracts a named +association+ from the relation. The named association is first preloaded, @@ -26435,7 +29173,7 @@ module ActiveRecord::QueryMethods # # account.memberships.preload(:user).collect(&:user) # - # source://activerecord//lib/active_record/relation/query_methods.rb#240 + # source://activerecord//lib/active_record/relation/query_methods.rb#334 def extract_associated(association); end # Specifies the table from which the records will be fetched. For example: @@ -26469,16 +29207,16 @@ module ActiveRecord::QueryMethods # # FROM colors c, JSONB_ARRAY_ELEMENTS(colored_things) AS colorvalues(colorvalue) # # WHERE (colorvalue->>'color' = 'red') # - # source://activerecord//lib/active_record/relation/query_methods.rb#1083 + # source://activerecord//lib/active_record/relation/query_methods.rb#1369 def from(value, subquery_name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1087 + # source://activerecord//lib/active_record/relation/query_methods.rb#1373 def from!(value, subquery_name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def from_clause; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def from_clause=(value); end # Allows to specify a group attribute: @@ -26502,16 +29240,16 @@ module ActiveRecord::QueryMethods # User.select([:id, :first_name]).group(:id, :first_name).first(3) # # => [#, #, #] # - # source://activerecord//lib/active_record/relation/query_methods.rb#363 + # source://activerecord//lib/active_record/relation/query_methods.rb#564 def group(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#368 + # source://activerecord//lib/active_record/relation/query_methods.rb#569 def group!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def group_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def group_values=(value); end # Allows to specify a HAVING clause. Note that you can't use HAVING @@ -26519,79 +29257,133 @@ module ActiveRecord::QueryMethods # # Order.having('SUM(price) > 30').group('user_id') # - # source://activerecord//lib/active_record/relation/query_methods.rb#903 + # source://activerecord//lib/active_record/relation/query_methods.rb#1175 def having(opts, *rest); end - # source://activerecord//lib/active_record/relation/query_methods.rb#907 + # source://activerecord//lib/active_record/relation/query_methods.rb#1179 def having!(opts, *rest); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def having_clause; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def having_clause=(value); end - # Allows to specify an order by a specific set of values. Depending on your - # adapter this will either use a CASE statement or a built-in function. + # Applies an ORDER BY clause based on a given +column+, + # ordered and filtered by a specific set of +values+. # # User.in_order_of(:id, [1, 5, 3]) # # SELECT "users".* FROM "users" - # # ORDER BY FIELD("users"."id", 1, 5, 3) # # WHERE "users"."id" IN (1, 5, 3) + # # ORDER BY CASE + # # WHEN "users"."id" = 1 THEN 1 + # # WHEN "users"."id" = 5 THEN 2 + # # WHEN "users"."id" = 3 THEN 3 + # # END ASC # - # source://activerecord//lib/active_record/relation/query_methods.rb#447 + # +column+ can point to an enum column; the actual query generated may be different depending + # on the database adapter and the column definition. + # + # class Conversation < ActiveRecord::Base + # enum :status, [ :active, :archived ] + # end + # + # Conversation.in_order_of(:status, [:archived, :active]) + # # SELECT "conversations".* FROM "conversations" + # # WHERE "conversations"."status" IN (1, 0) + # # ORDER BY CASE + # # WHEN "conversations"."status" = 1 THEN 1 + # # WHEN "conversations"."status" = 0 THEN 2 + # # END ASC + # + # +values+ can also include +nil+. + # + # Conversation.in_order_of(:status, [nil, :archived, :active]) + # # SELECT "conversations".* FROM "conversations" + # # WHERE ("conversations"."status" IN (1, 0) OR "conversations"."status" IS NULL) + # # ORDER BY CASE + # # WHEN "conversations"."status" IS NULL THEN 1 + # # WHEN "conversations"."status" = 1 THEN 2 + # # WHEN "conversations"."status" = 0 THEN 3 + # # END ASC + # + # source://activerecord//lib/active_record/relation/query_methods.rb#699 def in_order_of(column, values); end - # Specify relationships to be included in the result set. For - # example: + # Specify associations +args+ to be eager loaded to prevent N + 1 queries. + # A separate query is performed for each association, unless a join is + # required by conditions. + # + # For example: # - # users = User.includes(:address) + # users = User.includes(:address).limit(5) # users.each do |user| # user.address.city # end # - # allows you to access the +address+ attribute of the +User+ model without - # firing an additional query. This will often result in a - # performance improvement over a simple join. + # # SELECT "users".* FROM "users" LIMIT 5 + # # SELECT "addresses".* FROM "addresses" WHERE "addresses"."id" IN (1,2,3,4,5) # - # You can also specify multiple relationships, like this: + # Instead of loading the 5 addresses with 5 separate queries, all addresses + # are loaded with a single query. # - # users = User.includes(:address, :friends) + # Loading the associations in a separate query will often result in a + # performance improvement over a simple join, as a join can result in many + # rows that contain redundant data and it performs poorly at scale. # - # Loading nested relationships is possible using a Hash: + # You can also specify multiple associations. Each association will result + # in an additional query: # - # users = User.includes(:address, friends: [:address, :followers]) + # User.includes(:address, :friends).to_a + # # SELECT "users".* FROM "users" + # # SELECT "addresses".* FROM "addresses" WHERE "addresses"."id" IN (1,2,3,4,5) + # # SELECT "friends".* FROM "friends" WHERE "friends"."user_id" IN (1,2,3,4,5) + # + # Loading nested associations is possible using a Hash: + # + # User.includes(:address, friends: [:address, :followers]) # # === Conditions # # If you want to add string conditions to your included models, you'll have # to explicitly reference them. For example: # - # User.includes(:posts).where('posts.name = ?', 'example') + # User.includes(:posts).where('posts.name = ?', 'example').to_a # # Will throw an error, but this will work: # - # User.includes(:posts).where('posts.name = ?', 'example').references(:posts) + # User.includes(:posts).where('posts.name = ?', 'example').references(:posts).to_a + # # SELECT "users"."id" AS t0_r0, ... FROM "users" + # # LEFT OUTER JOIN "posts" ON "posts"."user_id" = "users"."id" + # # WHERE "posts"."name" = ? [["name", "example"]] + # + # As the LEFT OUTER JOIN already contains the posts, the second query for + # the posts is no longer performed. # # Note that #includes works with association names while #references needs # the actual table name. # - # If you pass the conditions via hash, you don't need to call #references + # If you pass the conditions via a Hash, you don't need to call #references # explicitly, as #where references the tables for you. For example, this # will work correctly: # # User.includes(:posts).where(posts: { name: 'example' }) # - # source://activerecord//lib/active_record/relation/query_methods.rb#191 + # NOTE: Conditions affect both sides of an association. For example, the + # above code will return only users that have a post named "example", + # and will only include posts named "example", even when a + # matching user has other additional posts. + # + # source://activerecord//lib/active_record/relation/query_methods.rb#247 def includes(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#196 + # source://activerecord//lib/active_record/relation/query_methods.rb#252 def includes!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def includes_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def includes_values=(value); end # Allows you to invert an entire where clause instead of manually applying conditions. @@ -26623,10 +29415,10 @@ module ActiveRecord::QueryMethods # User.where(role: 'admin').inactive # # WHERE NOT (`role` = 'admin' AND `accepted` = 1 AND `locked` = 0) # - # source://activerecord//lib/active_record/relation/query_methods.rb#811 + # source://activerecord//lib/active_record/relation/query_methods.rb#1079 def invert_where; end - # source://activerecord//lib/active_record/relation/query_methods.rb#815 + # source://activerecord//lib/active_record/relation/query_methods.rb#1083 def invert_where!; end # Performs JOINs on +args+. The given symbol(s) should match the name of @@ -26658,41 +29450,41 @@ module ActiveRecord::QueryMethods # User.joins("LEFT JOIN bookmarks ON bookmarks.bookmarkable_type = 'Post' AND bookmarks.user_id = users.id") # # SELECT "users".* FROM "users" LEFT JOIN bookmarks ON bookmarks.bookmarkable_type = 'Post' AND bookmarks.user_id = users.id # - # source://activerecord//lib/active_record/relation/query_methods.rb#586 + # source://activerecord//lib/active_record/relation/query_methods.rb#846 def joins(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#591 + # source://activerecord//lib/active_record/relation/query_methods.rb#851 def joins!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def joins_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def joins_values=(value); end # Performs LEFT OUTER JOINs on +args+: # # User.left_outer_joins(:posts) - # => SELECT "users".* FROM "users" LEFT OUTER JOIN "posts" ON "posts"."user_id" = "users"."id" + # # SELECT "users".* FROM "users" LEFT OUTER JOIN "posts" ON "posts"."user_id" = "users"."id" # - # source://activerecord//lib/active_record/relation/query_methods.rb#601 + # source://activerecord//lib/active_record/relation/query_methods.rb#861 def left_joins(*args); end # Performs LEFT OUTER JOINs on +args+: # # User.left_outer_joins(:posts) - # => SELECT "users".* FROM "users" LEFT OUTER JOIN "posts" ON "posts"."user_id" = "users"."id" + # # SELECT "users".* FROM "users" LEFT OUTER JOIN "posts" ON "posts"."user_id" = "users"."id" # - # source://activerecord//lib/active_record/relation/query_methods.rb#601 + # source://activerecord//lib/active_record/relation/query_methods.rb#861 def left_outer_joins(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#607 + # source://activerecord//lib/active_record/relation/query_methods.rb#867 def left_outer_joins!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def left_outer_joins_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def left_outer_joins_values=(value); end # Specifies a limit for the number of records to retrieve. @@ -26701,31 +29493,31 @@ module ActiveRecord::QueryMethods # # User.limit(10).limit(20) # generated SQL has 'LIMIT 20' # - # source://activerecord//lib/active_record/relation/query_methods.rb#917 + # source://activerecord//lib/active_record/relation/query_methods.rb#1189 def limit(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#921 + # source://activerecord//lib/active_record/relation/query_methods.rb#1193 def limit!(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def limit_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def limit_value=(value); end # Specifies locking settings (default to +true+). For more information # on locking, please see ActiveRecord::Locking. # - # source://activerecord//lib/active_record/relation/query_methods.rb#944 + # source://activerecord//lib/active_record/relation/query_methods.rb#1216 def lock(locks = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#948 + # source://activerecord//lib/active_record/relation/query_methods.rb#1220 def lock!(locks = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def lock_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def lock_value=(value); end # Returns a chainable relation with zero records. @@ -26756,12 +29548,17 @@ module ActiveRecord::QueryMethods # end # end # - # source://activerecord//lib/active_record/relation/query_methods.rb#987 + # source://activerecord//lib/active_record/relation/query_methods.rb#1259 def none; end - # source://activerecord//lib/active_record/relation/query_methods.rb#991 + # source://activerecord//lib/active_record/relation/query_methods.rb#1263 def none!; end + # @return [Boolean] + # + # source://activerecord//lib/active_record/relation/query_methods.rb#1271 + def null_relation?; end + # Specifies the number of rows to skip before returning rows. # # User.offset(10) # generated SQL has "OFFSET 10" @@ -26770,16 +29567,16 @@ module ActiveRecord::QueryMethods # # User.offset(10).order("name ASC") # - # source://activerecord//lib/active_record/relation/query_methods.rb#933 + # source://activerecord//lib/active_record/relation/query_methods.rb#1205 def offset(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#937 + # source://activerecord//lib/active_record/relation/query_methods.rb#1209 def offset!(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def offset_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def offset_value=(value); end # Specify optimizer hints to be used in the SELECT statement. @@ -26794,16 +29591,16 @@ module ActiveRecord::QueryMethods # Topic.optimizer_hints("SeqScan(topics)", "Parallel(topics 8)") # # SELECT /*+ SeqScan(topics) Parallel(topics 8) */ "topics".* FROM "topics" # - # source://activerecord//lib/active_record/relation/query_methods.rb#1177 + # source://activerecord//lib/active_record/relation/query_methods.rb#1463 def optimizer_hints(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1182 + # source://activerecord//lib/active_record/relation/query_methods.rb#1468 def optimizer_hints!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def optimizer_hints_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def optimizer_hints_values=(value); end # Returns a new relation, which is the logical union of this relation and the one passed as an @@ -26816,10 +29613,10 @@ module ActiveRecord::QueryMethods # Post.where("id = 1").or(Post.where("author_id = 3")) # # SELECT `posts`.* FROM `posts` WHERE ((id = 1) OR (author_id = 3)) # - # source://activerecord//lib/active_record/relation/query_methods.rb#877 + # source://activerecord//lib/active_record/relation/query_methods.rb#1145 def or(other); end - # source://activerecord//lib/active_record/relation/query_methods.rb#885 + # source://activerecord//lib/active_record/relation/query_methods.rb#1157 def or!(other); end # Applies an ORDER BY clause to a query. @@ -26870,63 +29667,87 @@ module ActiveRecord::QueryMethods # User.order(Arel.sql('end_date - start_date')) # # SELECT "users".* FROM "users" ORDER BY end_date - start_date # - # Custom query syntax, like JSON columns for Postgres, is supported in this way. + # Custom query syntax, like JSON columns for PostgreSQL, is supported in this way. # # User.order(Arel.sql("payload->>'kind'")) # # SELECT "users".* FROM "users" ORDER BY payload->>'kind' # - # source://activerecord//lib/active_record/relation/query_methods.rb#425 + # source://activerecord//lib/active_record/relation/query_methods.rb#647 def order(*args); end # Same as #order but operates on relation in-place instead of copying. # - # source://activerecord//lib/active_record/relation/query_methods.rb#433 + # source://activerecord//lib/active_record/relation/query_methods.rb#655 def order!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def order_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def order_values=(value); end - # Allows preloading of +args+, in the same way that #includes does: + # Specify associations +args+ to be eager loaded using separate queries. + # A separate query is performed for each association. + # + # users = User.preload(:address).limit(5) + # users.each do |user| + # user.address.city + # end # - # User.preload(:posts) - # # SELECT "posts".* FROM "posts" WHERE "posts"."user_id" IN (1, 2, 3) + # # SELECT "users".* FROM "users" LIMIT 5 + # # SELECT "addresses".* FROM "addresses" WHERE "addresses"."id" IN (1,2,3,4,5) + # + # Instead of loading the 5 addresses with 5 separate queries, all addresses + # are loaded with a separate query. + # + # Loading multiple and nested associations is possible using Hashes and Arrays, + # similar to #includes: + # + # User.preload(:address, friends: [:address, :followers]) + # # SELECT "users".* FROM "users" + # # SELECT "addresses".* FROM "addresses" WHERE "addresses"."id" IN (1,2,3,4,5) + # # SELECT "friends".* FROM "friends" WHERE "friends"."user_id" IN (1,2,3,4,5) + # # SELECT ... # - # source://activerecord//lib/active_record/relation/query_methods.rb#221 + # source://activerecord//lib/active_record/relation/query_methods.rb#315 def preload(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#226 + # source://activerecord//lib/active_record/relation/query_methods.rb#320 def preload!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def preload_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def preload_values=(value); end - # Sets readonly attributes for the returned relation. If value is - # true (default), attempting to update a record will result in an error. + # Mark a relation as readonly. Attempting to update a record will result in + # an error. # # users = User.readonly # users.first.save # => ActiveRecord::ReadOnlyRecord: User is marked as readonly # - # source://activerecord//lib/active_record/relation/query_methods.rb#1001 + # To make a readonly relation writable, pass +false+. + # + # users.readonly(false) + # users.first.save + # => true + # + # source://activerecord//lib/active_record/relation/query_methods.rb#1287 def readonly(value = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1005 + # source://activerecord//lib/active_record/relation/query_methods.rb#1291 def readonly!(value = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def readonly_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def readonly_value=(value); end # Use to indicate that the given +table_names+ are referenced by an SQL string, - # and should therefore be JOINed in any query rather than loaded separately. + # and should therefore be +JOIN+ed in any query rather than loaded separately. # This method only works in conjunction with #includes. # See #includes for more details. # @@ -26936,18 +29757,37 @@ module ActiveRecord::QueryMethods # User.includes(:posts).where("posts.name = 'foo'").references(:posts) # # Query now knows the string references posts, so adds a JOIN # - # source://activerecord//lib/active_record/relation/query_methods.rb#254 + # source://activerecord//lib/active_record/relation/query_methods.rb#348 def references(*table_names); end - # source://activerecord//lib/active_record/relation/query_methods.rb#259 + # source://activerecord//lib/active_record/relation/query_methods.rb#353 def references!(*table_names); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def references_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def references_values=(value); end + # Allows you to change a previously set group statement. + # + # Post.group(:title, :body) + # # SELECT `posts`.`*` FROM `posts` GROUP BY `posts`.`title`, `posts`.`body` + # + # Post.group(:title, :body).regroup(:title) + # # SELECT `posts`.`*` FROM `posts` GROUP BY `posts`.`title` + # + # This is short-hand for unscope(:group).group(fields). + # Note that we're unscoping the entire group statement. + # + # source://activerecord//lib/active_record/relation/query_methods.rb#584 + def regroup(*args); end + + # Same as #regroup but operates on relation in-place instead of copying. + # + # source://activerecord//lib/active_record/relation/query_methods.rb#590 + def regroup!(*args); end + # Replaces any existing order defined on the relation with the specified order. # # User.order('email DESC').reorder('id ASC') # generated SQL has 'ORDER BY id ASC' @@ -26956,20 +29796,20 @@ module ActiveRecord::QueryMethods # # User.order('email DESC').reorder('id ASC').order('name ASC') # - # generates a query with 'ORDER BY id ASC, name ASC'. + # generates a query with ORDER BY id ASC, name ASC. # - # source://activerecord//lib/active_record/relation/query_methods.rb#471 + # source://activerecord//lib/active_record/relation/query_methods.rb#730 def reorder(*args); end # Same as #reorder but operates on relation in-place instead of copying. # - # source://activerecord//lib/active_record/relation/query_methods.rb#479 + # source://activerecord//lib/active_record/relation/query_methods.rb#738 def reorder!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def reordering_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def reordering_value=(value); end # Allows you to change a previously set select statement. @@ -26983,28 +29823,28 @@ module ActiveRecord::QueryMethods # This is short-hand for unscope(:select).select(fields). # Note that we're unscoping the entire select statement. # - # source://activerecord//lib/active_record/relation/query_methods.rb#332 + # source://activerecord//lib/active_record/relation/query_methods.rb#532 def reselect(*args); end # Same as #reselect but operates on relation in-place instead of copying. # - # source://activerecord//lib/active_record/relation/query_methods.rb#338 + # source://activerecord//lib/active_record/relation/query_methods.rb#539 def reselect!(*args); end # Reverse the existing order clause on the relation. # # User.order('name ASC').reverse_order # generated SQL has 'ORDER BY name DESC' # - # source://activerecord//lib/active_record/relation/query_methods.rb#1190 + # source://activerecord//lib/active_record/relation/query_methods.rb#1476 def reverse_order; end - # source://activerecord//lib/active_record/relation/query_methods.rb#1194 + # source://activerecord//lib/active_record/relation/query_methods.rb#1480 def reverse_order!; end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def reverse_order_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def reverse_order_value=(value); end # Allows you to change a previously set where condition for a given attribute, instead of appending to that condition. @@ -27021,7 +29861,7 @@ module ActiveRecord::QueryMethods # This is short-hand for unscope(where: conditions.keys).where(conditions). # Note that unlike reorder, we're only unscoping the named conditions -- not the entire where statement. # - # source://activerecord//lib/active_record/relation/query_methods.rb#773 + # source://activerecord//lib/active_record/relation/query_methods.rb#1039 def rewhere(conditions); end # Works in two unique ways. @@ -27049,6 +29889,14 @@ module ActiveRecord::QueryMethods # Model.select(:field, :other_field, :and_one_more) # # => [#] # + # The argument also can be a hash of fields and aliases. + # + # Model.select(models: { field: :alias, other_field: :other_alias }) + # # => [#] + # + # Model.select(models: [:field, :other_field]) + # # => [#] + # # You can also use one or more strings, which will be used unchanged as SELECT fields. # # Model.select('field AS field_one', 'other_field AS field_two') @@ -27063,27 +29911,27 @@ module ActiveRecord::QueryMethods # except +id+ will throw ActiveModel::MissingAttributeError: # # Model.select(:field).first.other_field - # # => ActiveModel::MissingAttributeError: missing attribute: other_field + # # => ActiveModel::MissingAttributeError: missing attribute 'other_field' for Model # - # source://activerecord//lib/active_record/relation/query_methods.rb#304 + # source://activerecord//lib/active_record/relation/query_methods.rb#406 def select(*fields); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def select_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def select_values=(value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1205 + # source://activerecord//lib/active_record/relation/query_methods.rb#1491 def skip_preloading!; end - # source://activerecord//lib/active_record/relation/query_methods.rb#1200 + # source://activerecord//lib/active_record/relation/query_methods.rb#1486 def skip_query_cache!(value = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def skip_query_cache_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def skip_query_cache_value=(value); end # Sets the returned relation to strict_loading mode. This will raise an error @@ -27093,16 +29941,16 @@ module ActiveRecord::QueryMethods # user.comments.to_a # => ActiveRecord::StrictLoadingViolationError # - # source://activerecord//lib/active_record/relation/query_methods.rb#1016 + # source://activerecord//lib/active_record/relation/query_methods.rb#1302 def strict_loading(value = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1020 + # source://activerecord//lib/active_record/relation/query_methods.rb#1306 def strict_loading!(value = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def strict_loading_value; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def strict_loading_value=(value); end # Checks whether the given relation is structurally compatible with this relation, to determine @@ -27118,12 +29966,12 @@ module ActiveRecord::QueryMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/relation/query_methods.rb#831 + # source://activerecord//lib/active_record/relation/query_methods.rb#1099 def structurally_compatible?(other); end # Deduplicate multiple values. # - # source://activerecord//lib/active_record/relation/query_methods.rb#1233 + # source://activerecord//lib/active_record/relation/query_methods.rb#1519 def uniq!(name); end # Removes an unwanted relation that is already defined on a chain of relations. @@ -27159,16 +30007,16 @@ module ActiveRecord::QueryMethods # # has_many :comments, -> { unscope(where: :trashed) } # - # source://activerecord//lib/active_record/relation/query_methods.rb#524 + # source://activerecord//lib/active_record/relation/query_methods.rb#784 def unscope(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#529 + # source://activerecord//lib/active_record/relation/query_methods.rb#789 def unscope!(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def unscope_values; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def unscope_values=(value); end # Returns a new relation, which is the result of filtering the current relation @@ -27178,7 +30026,7 @@ module ActiveRecord::QueryMethods # SQL is given as an illustration; the actual query generated may be different depending # on the database adapter. # - # === string + # === \String # # A single string, without additional arguments, is passed to the query # constructor as an SQL fragment, and used in the where clause of the query. @@ -27190,7 +30038,7 @@ module ActiveRecord::QueryMethods # to injection attacks if not done properly. As an alternative, it is recommended # to use one of the following methods. # - # === array + # === \Array # # If an array is passed, then the first element of the array is treated as a template, and # the remaining elements are inserted into the template to generate the condition. @@ -27230,7 +30078,7 @@ module ActiveRecord::QueryMethods # dependencies on the underlying database. If your code is intended for general consumption, # test with multiple database backends. # - # === hash + # === \Hash # # #where will also accept a hash condition, in which the keys are fields and the values # are values to be searched for. @@ -27264,6 +30112,12 @@ module ActiveRecord::QueryMethods # PriceEstimate.where(estimate_of: treasure) # PriceEstimate.where(estimate_of_type: 'Treasure', estimate_of_id: treasure) # + # Hash conditions may also be specified in a tuple-like syntax. Hash keys may be + # an array of columns with an array of tuples as values. + # + # Article.where([:author_id, :id] => [[15, 1], [15, 2]]) + # # SELECT * FROM articles WHERE author_id = 15 AND id = 1 OR author_id = 15 AND id = 2 + # # === Joins # # If the relation is the result of a join, you may create a condition which uses any of the @@ -27276,7 +30130,7 @@ module ActiveRecord::QueryMethods # User.joins(:posts).where("posts.published" => true) # User.joins(:posts).where(posts: { published: true }) # - # === no argument + # === No Argument # # If no argument is passed, #where returns a new instance of WhereChain, that # can be chained with WhereChain#not, WhereChain#missing, or WhereChain#associated. @@ -27300,23 +30154,121 @@ module ActiveRecord::QueryMethods # # LEFT OUTER JOIN "authors" ON "authors"."id" = "posts"."author_id" # # WHERE "authors"."id" IS NULL # - # === blank condition + # === Blank Condition # # If the condition is any blank-ish object, then #where is a no-op and returns # the current relation. # - # source://activerecord//lib/active_record/relation/query_methods.rb#745 + # source://activerecord//lib/active_record/relation/query_methods.rb#1011 def where(*args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#755 + # source://activerecord//lib/active_record/relation/query_methods.rb#1021 def where!(opts, *rest); end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def where_clause; end - # source://activerecord//lib/active_record/relation/query_methods.rb#143 + # source://activerecord//lib/active_record/relation/query_methods.rb#175 def where_clause=(value); end + # Add a Common Table Expression (CTE) that you can then reference within another SELECT statement. + # + # Note: CTE's are only supported in MySQL for versions 8.0 and above. You will not be able to + # use CTE's with MySQL 5.7. + # + # Post.with(posts_with_tags: Post.where("tags_count > ?", 0)) + # # => ActiveRecord::Relation + # # WITH posts_with_tags AS ( + # # SELECT * FROM posts WHERE (tags_count > 0) + # # ) + # # SELECT * FROM posts + # + # You can also pass an array of sub-queries to be joined in a +UNION ALL+. + # + # Post.with(posts_with_tags_or_comments: [Post.where("tags_count > ?", 0), Post.where("comments_count > ?", 0)]) + # # => ActiveRecord::Relation + # # WITH posts_with_tags_or_comments AS ( + # # (SELECT * FROM posts WHERE (tags_count > 0)) + # # UNION ALL + # # (SELECT * FROM posts WHERE (comments_count > 0)) + # # ) + # # SELECT * FROM posts + # + # Once you define Common Table Expression you can use custom +FROM+ value or +JOIN+ to reference it. + # + # Post.with(posts_with_tags: Post.where("tags_count > ?", 0)).from("posts_with_tags AS posts") + # # => ActiveRecord::Relation + # # WITH posts_with_tags AS ( + # # SELECT * FROM posts WHERE (tags_count > 0) + # # ) + # # SELECT * FROM posts_with_tags AS posts + # + # Post.with(posts_with_tags: Post.where("tags_count > ?", 0)).joins("JOIN posts_with_tags ON posts_with_tags.id = posts.id") + # # => ActiveRecord::Relation + # # WITH posts_with_tags AS ( + # # SELECT * FROM posts WHERE (tags_count > 0) + # # ) + # # SELECT * FROM posts JOIN posts_with_tags ON posts_with_tags.id = posts.id + # + # It is recommended to pass a query as ActiveRecord::Relation. If that is not possible + # and you have verified it is safe for the database, you can pass it as SQL literal + # using +Arel+. + # + # Post.with(popular_posts: Arel.sql("... complex sql to calculate posts popularity ...")) + # + # Great caution should be taken to avoid SQL injection vulnerabilities. This method should not + # be used with unsafe values that include unsanitized input. + # + # To add multiple CTEs just pass multiple key-value pairs + # + # Post.with( + # posts_with_comments: Post.where("comments_count > ?", 0), + # posts_with_tags: Post.where("tags_count > ?", 0) + # ) + # + # or chain multiple +.with+ calls + # + # Post + # .with(posts_with_comments: Post.where("comments_count > ?", 0)) + # .with(posts_with_tags: Post.where("tags_count > ?", 0)) + # + # @raise [ArgumentError] + # + # source://activerecord//lib/active_record/relation/query_methods.rb#486 + def with(*args); end + + # Like #with, but modifies relation in place. + # + # source://activerecord//lib/active_record/relation/query_methods.rb#493 + def with!(*args); end + + # Add a recursive Common Table Expression (CTE) that you can then reference within another SELECT statement. + # + # Post.with_recursive(post_and_replies: [Post.where(id: 42), Post.joins('JOIN post_and_replies ON posts.in_reply_to_id = post_and_replies.id')]) + # # => ActiveRecord::Relation + # # WITH post_and_replies AS ( + # # (SELECT * FROM posts WHERE id = 42) + # # UNION ALL + # # (SELECT * FROM posts JOIN posts_and_replies ON posts.in_reply_to_id = posts_and_replies.id) + # # ) + # # SELECT * FROM posts + # + # See `#with` for more information. + # + # source://activerecord//lib/active_record/relation/query_methods.rb#510 + def with_recursive(*args); end + + # Like #with_recursive but modifies the relation in place. + # + # source://activerecord//lib/active_record/relation/query_methods.rb#516 + def with_recursive!(*args); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#171 + def with_values; end + + # source://activerecord//lib/active_record/relation/query_methods.rb#175 + def with_values=(value); end + # Excludes the specified record (or collection of records) from the resulting # relation. For example: # @@ -27326,6 +30278,9 @@ module ActiveRecord::QueryMethods # Post.excluding(post_one, post_two) # # SELECT "posts".* FROM "posts" WHERE "posts"."id" NOT IN (1, 2) # + # Post.excluding(Post.drafts) + # # SELECT "posts".* FROM "posts" WHERE "posts"."id" NOT IN (3, 4, 5) + # # This can also be called on associations. As with the above example, either # a single record of collection thereof may be specified: # @@ -27341,57 +30296,87 @@ module ActiveRecord::QueryMethods # is passed in) are not instances of the same model that the relation is # scoping. # - # source://activerecord//lib/active_record/relation/query_methods.rb#1263 + # source://activerecord//lib/active_record/relation/query_methods.rb#1552 def without(*records); end protected - # source://activerecord//lib/active_record/relation/query_methods.rb#1301 + # source://activerecord//lib/active_record/relation/query_methods.rb#1634 + def async!; end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1591 def build_having_clause(opts, rest = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1293 + # source://activerecord//lib/active_record/relation/query_methods.rb#1583 def build_subquery(subquery_alias, select_value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1301 + # source://activerecord//lib/active_record/relation/query_methods.rb#1591 def build_where_clause(opts, rest = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/relation/query_methods.rb#1522 + # source://activerecord//lib/active_record/relation/query_methods.rb#1931 def arel_column(field); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1505 + # source://activerecord//lib/active_record/relation/query_methods.rb#1912 def arel_columns(columns); end - # @raise [ImmutableRelation] + # source://activerecord//lib/active_record/relation/query_methods.rb#2171 + def arel_columns_from_hash(fields); end + + # @raise [UnmodifiableRelation] # - # source://activerecord//lib/active_record/relation/query_methods.rb#1353 - def assert_mutability!; end + # source://activerecord//lib/active_record/relation/query_methods.rb#1708 + def assert_modifiable!; end - # source://activerecord//lib/active_record/relation/query_methods.rb#1358 - def build_arel(aliases = T.unsafe(nil)); end + # source://activerecord//lib/active_record/relation/query_methods.rb#1640 + def async; end - # source://activerecord//lib/active_record/relation/query_methods.rb#1386 + # source://activerecord//lib/active_record/relation/query_methods.rb#1712 + def build_arel(connection, aliases = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1664 + def build_bound_sql_literal(statement, values); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#2101 + def build_case_for_value_position(column, values); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1741 def build_cast_value(name, value); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1390 + # source://activerecord//lib/active_record/relation/query_methods.rb#1745 def build_from; end - # source://activerecord//lib/active_record/relation/query_methods.rb#1423 + # source://activerecord//lib/active_record/relation/query_methods.rb#1787 def build_join_buckets; end - # source://activerecord//lib/active_record/relation/query_methods.rb#1342 + # source://activerecord//lib/active_record/relation/query_methods.rb#1697 def build_join_dependencies; end - # source://activerecord//lib/active_record/relation/query_methods.rb#1473 + # source://activerecord//lib/active_record/relation/query_methods.rb#1843 def build_joins(join_sources, aliases = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1584 + # source://activerecord//lib/active_record/relation/query_methods.rb#1644 + def build_named_bound_sql_literal(statement, values); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1993 def build_order(arel); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1495 + # source://activerecord//lib/active_record/relation/query_methods.rb#1865 def build_select(arel); end + # source://activerecord//lib/active_record/relation/query_methods.rb#1875 + def build_with(arel); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1893 + def build_with_expression_from_value(value); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1904 + def build_with_join_node(name, kind = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1887 + def build_with_value_from_hash(hash); end + # Checks to make sure that the arguments are not blank. Note that if some # blank-like object were initially passed into the query method, then this # method will not raise an error. @@ -27409,76 +30394,101 @@ module ActiveRecord::QueryMethods # ... # end # - # source://activerecord//lib/active_record/relation/query_methods.rb#1704 + # source://activerecord//lib/active_record/relation/query_methods.rb#2150 def check_if_method_has_arguments!(method_name, args, message = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1641 + # source://activerecord//lib/active_record/relation/query_methods.rb#2062 def column_references(order_args); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/query_methods.rb#1573 + # source://activerecord//lib/active_record/relation/query_methods.rb#1982 def does_not_support_reverse?(order); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1336 + # source://activerecord//lib/active_record/relation/query_methods.rb#1691 def each_join_dependencies(join_dependencies = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1329 + # source://activerecord//lib/active_record/relation/query_methods.rb#2087 + def extract_table_name_from(string); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#2015 + def flattened_args(args); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#1684 def lookup_table_klass_from_join_dependencies(table_name); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1654 + # source://activerecord//lib/active_record/relation/query_methods.rb#2091 def order_column(field); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1604 + # source://activerecord//lib/active_record/relation/query_methods.rb#2019 def preprocess_order_args(order_args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1664 + # source://activerecord//lib/active_record/relation/query_methods.rb#2161 + def process_select_args(fields); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#2110 def resolve_arel_attributes(attrs); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1544 + # source://activerecord//lib/active_record/relation/query_methods.rb#1953 def reverse_sql_order(order_query); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1635 + # source://activerecord//lib/active_record/relation/query_methods.rb#2056 def sanitize_order_arguments(order_args); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1405 + # source://activerecord//lib/active_record/relation/query_methods.rb#1772 def select_association_list(associations, stashed_joins = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1720 + # source://activerecord//lib/active_record/relation/query_methods.rb#1760 + def select_named_joins(join_names, stashed_joins = T.unsafe(nil), &block); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#2201 def structurally_incompatible_values_for(other); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/query_methods.rb#1538 + # source://activerecord//lib/active_record/relation/query_methods.rb#1947 def table_name_matches?(from); end - # source://activerecord//lib/active_record/relation/query_methods.rb#1592 + # source://activerecord//lib/active_record/relation/query_methods.rb#2001 def validate_order_args(args); end end -# source://activerecord//lib/active_record/relation/query_methods.rb#124 +# A wrapper to distinguish CTE joins from other nodes. +# +# source://activerecord//lib/active_record/relation/query_methods.rb#148 +class ActiveRecord::QueryMethods::CTEJoin + # @return [CTEJoin] a new instance of CTEJoin + # + # source://activerecord//lib/active_record/relation/query_methods.rb#151 + def initialize(name); end + + # source://activerecord//lib/active_record/relation/query_methods.rb#149 + def name; end +end + +# source://activerecord//lib/active_record/relation/query_methods.rb#156 ActiveRecord::QueryMethods::FROZEN_EMPTY_ARRAY = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/relation/query_methods.rb#125 +# source://activerecord//lib/active_record/relation/query_methods.rb#157 ActiveRecord::QueryMethods::FROZEN_EMPTY_HASH = T.let(T.unsafe(nil), Hash) -# source://activerecord//lib/active_record/relation/query_methods.rb#1715 +# source://activerecord//lib/active_record/relation/query_methods.rb#2196 ActiveRecord::QueryMethods::STRUCTURAL_VALUE_METHODS = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/relation/query_methods.rb#1589 +# source://activerecord//lib/active_record/relation/query_methods.rb#1998 ActiveRecord::QueryMethods::VALID_DIRECTIONS = T.let(T.unsafe(nil), Set) -# source://activerecord//lib/active_record/relation/query_methods.rb#487 +# source://activerecord//lib/active_record/relation/query_methods.rb#746 ActiveRecord::QueryMethods::VALID_UNSCOPING_VALUES = T.let(T.unsafe(nil), Set) -# WhereChain objects act as placeholder for queries in which +where+ does not have any parameter. +# +WhereChain+ objects act as placeholder for queries in which +where+ does not have any parameter. # In this case, +where+ can be chained to return a new relation. # -# source://activerecord//lib/active_record/relation/query_methods.rb#15 +# source://activerecord//lib/active_record/relation/query_methods.rb#14 class ActiveRecord::QueryMethods::WhereChain # @return [WhereChain] a new instance of WhereChain # - # source://activerecord//lib/active_record/relation/query_methods.rb#16 + # source://activerecord//lib/active_record/relation/query_methods.rb#15 def initialize(scope); end # Returns a new relation with joins and where clause to identify @@ -27500,7 +30510,20 @@ class ActiveRecord::QueryMethods::WhereChain # # INNER JOIN "comments" ON "comments"."post_id" = "posts"."id" # # WHERE "authors"."id" IS NOT NULL AND "comments"."id" IS NOT NULL # - # source://activerecord//lib/active_record/relation/query_methods.rb#76 + # You can define join type in the scope and +associated+ will not use `JOIN` by default. + # + # Post.left_joins(:author).where.associated(:author) + # # SELECT "posts".* FROM "posts" + # # LEFT OUTER JOIN "authors" "authors"."id" = "posts"."author_id" + # # WHERE "authors"."id" IS NOT NULL + # + # Post.left_joins(:comments).where.associated(:author) + # # SELECT "posts".* FROM "posts" + # # INNER JOIN "authors" ON "authors"."id" = "posts"."author_id" + # # LEFT OUTER JOIN "comments" ON "comments"."post_id" = "posts"."id" + # # WHERE "author"."id" IS NOT NULL + # + # source://activerecord//lib/active_record/relation/query_methods.rb#88 def associated(*associations); end # Returns a new relation with left outer joins and where clause to identify @@ -27522,7 +30545,7 @@ class ActiveRecord::QueryMethods::WhereChain # # LEFT OUTER JOIN "comments" ON "comments"."post_id" = "posts"."id" # # WHERE "authors"."id" IS NULL AND "comments"."id" IS NULL # - # source://activerecord//lib/active_record/relation/query_methods.rb#104 + # source://activerecord//lib/active_record/relation/query_methods.rb#123 def missing(*associations); end # Returns a new relation expressing WHERE + NOT condition according to @@ -27547,7 +30570,7 @@ class ActiveRecord::QueryMethods::WhereChain # # SELECT * FROM users WHERE name NOT IN ('Ko1', 'Nobu') # # User.where.not(name: "Jon", role: "admin") - # # SELECT * FROM users WHERE NOT (name == 'Jon' AND role == 'admin') + # # SELECT * FROM users WHERE NOT (name = 'Jon' AND role = 'admin') # # If there is a non-nil condition on a nullable column in the hash condition, the records that have # nil values on the nullable column won't be returned. @@ -27556,39 +30579,73 @@ class ActiveRecord::QueryMethods::WhereChain # # SELECT * FROM users WHERE NOT (nullable_country = 'UK') # # => [] # - # source://activerecord//lib/active_record/relation/query_methods.rb#50 + # source://activerecord//lib/active_record/relation/query_methods.rb#49 def not(opts, *rest); end private - # source://activerecord//lib/active_record/relation/query_methods.rb#115 + # source://activerecord//lib/active_record/relation/query_methods.rb#138 def scope_association_reflection(association); end end # source://activerecord//lib/active_record/querying.rb#4 module ActiveRecord::Querying - # source://activerecord//lib/active_record/querying.rb#57 + # source://activerecord//lib/active_record/querying.rb#73 def _load_from_sql(result_set, &block); end - # source://activerecord//lib/active_record/querying.rb#53 - def _query_by_sql(sql, binds = T.unsafe(nil), preparable: T.unsafe(nil), async: T.unsafe(nil)); end + # source://activerecord//lib/active_record/querying.rb#69 + def _query_by_sql(connection, sql, binds = T.unsafe(nil), preparable: T.unsafe(nil), async: T.unsafe(nil), allow_retry: T.unsafe(nil)); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def and(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def annotate(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def any?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 + def async_average(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def async_count(*_arg0, **_arg1, &_arg2); end + + # Same as #count_by_sql but perform the query asynchronously and returns an ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/querying.rb#116 + def async_count_by_sql(sql); end + + # Same as #find_by_sql but perform the query asynchronously and returns an ActiveRecord::Promise. + # + # source://activerecord//lib/active_record/querying.rb#59 + def async_find_by_sql(sql, binds = T.unsafe(nil), preparable: T.unsafe(nil), &block); end + + # source://activerecord//lib/active_record/querying.rb#24 + def async_ids(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def async_maximum(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def async_minimum(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def async_pick(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def async_pluck(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def async_sum(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 def average(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def calculate(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def count(*_arg0, **_arg1, &_arg2); end # Returns the result of an SQL statement that should only include a COUNT(*) in the SELECT part. @@ -27604,64 +30661,70 @@ module ActiveRecord::Querying # # * +sql+ - An SQL statement which should return a count query from the database, see the example above. # - # source://activerecord//lib/active_record/querying.rb#93 + # source://activerecord//lib/active_record/querying.rb#109 def count_by_sql(sql); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def create_or_find_by(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def create_or_find_by!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def create_with(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 + def delete(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 def delete_all(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def delete_by(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 + def destroy(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 def destroy_all(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def destroy_by(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def distinct(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def eager_load(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def except(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def excluding(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def exists?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def extending(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def extract_associated(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def fifth(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def fifth!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_by(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_by!(*_arg0, **_arg1, &_arg2); end # Executes a custom SQL query against your database and returns all the results. The results will @@ -27690,214 +30753,241 @@ module ActiveRecord::Querying # Note that building your own SQL query string from user input may expose your application to # injection attacks (https://guides.rubyonrails.org/security.html#sql-injection). # - # source://activerecord//lib/active_record/querying.rb#49 - def find_by_sql(sql, binds = T.unsafe(nil), preparable: T.unsafe(nil), &block); end + # source://activerecord//lib/active_record/querying.rb#51 + def find_by_sql(sql, binds = T.unsafe(nil), preparable: T.unsafe(nil), allow_retry: T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_each(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_in_batches(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_or_create_by(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_or_create_by!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_or_initialize_by(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def find_sole_by(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def first(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def first!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def first_or_create(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def first_or_create!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def first_or_initialize(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def forty_two(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def forty_two!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def fourth(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def fourth!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def from(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def group(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def having(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def ids(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def in_batches(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def in_order_of(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def includes(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 + def insert(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def insert!(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def insert_all(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def insert_all!(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 def invert_where(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def joins(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def last(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def last!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def left_joins(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def left_outer_joins(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def limit(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def lock(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def many?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def maximum(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def merge(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def minimum(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def none(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def none?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def offset(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def one?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def only(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def optimizer_hints(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def or(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def order(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def pick(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def pluck(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def preload(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def readonly(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def references(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 + def regroup(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 def reorder(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def reselect(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def rewhere(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def second(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def second!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def second_to_last(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def second_to_last!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def select(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def sole(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def strict_loading(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def sum(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def take(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def take!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def third(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def third!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def third_to_last(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def third_to_last!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def touch_all(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def unscope(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 def update_all(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 + def upsert(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def upsert_all(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 def where(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/querying.rb#22 + # source://activerecord//lib/active_record/querying.rb#24 + def with(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 + def with_recursive(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/querying.rb#24 def without(*_arg0, **_arg1, &_arg2); end end @@ -27909,25 +30999,25 @@ ActiveRecord::Querying::QUERYING_METHODS = T.let(T.unsafe(nil), Array) # source://activerecord//lib/active_record/railtie.rb#16 class ActiveRecord::Railtie < ::Rails::Railtie; end -# source://activerecord//lib/active_record/railtie.rb#203 -ActiveRecord::Railtie::SQLITE3_PRODUCTION_WARN = T.let(T.unsafe(nil), String) - # Raised when values that executed are out of range. # -# source://activerecord//lib/active_record/errors.rb#224 +# source://activerecord//lib/active_record/errors.rb#288 class ActiveRecord::RangeError < ::ActiveRecord::StatementInvalid; end # Raised when a write to the database is attempted on a read only connection. # -# source://activerecord//lib/active_record/errors.rb#98 +# source://activerecord//lib/active_record/errors.rb#119 class ActiveRecord::ReadOnlyError < ::ActiveRecord::ActiveRecordError; end # Raised on attempt to update record that is instantiated as read only. # -# source://activerecord//lib/active_record/errors.rb#303 +# source://activerecord//lib/active_record/errors.rb#381 class ActiveRecord::ReadOnlyRecord < ::ActiveRecord::ActiveRecordError; end # source://activerecord//lib/active_record/readonly_attributes.rb#4 +class ActiveRecord::ReadonlyAttributeError < ::ActiveRecord::ActiveRecordError; end + +# source://activerecord//lib/active_record/readonly_attributes.rb#7 module ActiveRecord::ReadonlyAttributes extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -27944,12 +31034,13 @@ module ActiveRecord::ReadonlyAttributes module GeneratedInstanceMethods; end end -# source://activerecord//lib/active_record/readonly_attributes.rb#11 +# source://activerecord//lib/active_record/readonly_attributes.rb#14 module ActiveRecord::ReadonlyAttributes::ClassMethods - # Attributes listed as readonly will be used to create a new record but update operations will - # ignore these fields. + # Attributes listed as readonly will be used to create a new record. + # Assigning a new value to a readonly attribute on a persisted record raises an error. # - # You can assign a new value to a readonly attribute, but it will be ignored when the record is updated. + # By setting +config.active_record.raise_on_assign_to_attr_readonly+ to +false+, it will + # not raise. The value will change in memory, but will not be persisted on +save+. # # ==== Examples # @@ -27958,22 +31049,32 @@ module ActiveRecord::ReadonlyAttributes::ClassMethods # end # # post = Post.create!(title: "Introducing Ruby on Rails!") - # post.update(title: "a different title") # change to title will be ignored + # post.title = "a different title" # raises ActiveRecord::ReadonlyAttributeError + # post.update(title: "a different title") # raises ActiveRecord::ReadonlyAttributeError # - # source://activerecord//lib/active_record/readonly_attributes.rb#25 + # source://activerecord//lib/active_record/readonly_attributes.rb#30 def attr_readonly(*attributes); end # @return [Boolean] # - # source://activerecord//lib/active_record/readonly_attributes.rb#34 + # source://activerecord//lib/active_record/readonly_attributes.rb#43 def readonly_attribute?(name); end # Returns an array of all the attributes that have been specified as readonly. # - # source://activerecord//lib/active_record/readonly_attributes.rb#30 + # source://activerecord//lib/active_record/readonly_attributes.rb#39 def readonly_attributes; end end +# source://activerecord//lib/active_record/readonly_attributes.rb#48 +module ActiveRecord::ReadonlyAttributes::HasReadonlyAttributes + # source://activerecord//lib/active_record/readonly_attributes.rb#57 + def _write_attribute(attr_name, value); end + + # source://activerecord//lib/active_record/readonly_attributes.rb#49 + def write_attribute(attr_name, value); end +end + # = Active Record \RecordInvalid # # Raised by {ActiveRecord::Base#save!}[rdoc-ref:Persistence#save!] and @@ -28000,73 +31101,86 @@ class ActiveRecord::RecordInvalid < ::ActiveRecord::ActiveRecordError end # Raised by {ActiveRecord::Base#destroy!}[rdoc-ref:Persistence#destroy!] -# when a call to {#destroy}[rdoc-ref:Persistence#destroy] -# would return false. +# when a record cannot be destroyed due to any of the +# before_destroy callbacks throwing +:abort+. See +# ActiveRecord::Callbacks for further details. # -# begin -# complex_operation_that_internally_calls_destroy! -# rescue ActiveRecord::RecordNotDestroyed => invalid -# puts invalid.record.errors +# class User < ActiveRecord::Base +# before_destroy do +# throw :abort if still_active? +# end # end # -# source://activerecord//lib/active_record/errors.rb#136 +# User.first.destroy! # => raises an ActiveRecord::RecordNotDestroyed +# +# source://activerecord//lib/active_record/errors.rb#169 class ActiveRecord::RecordNotDestroyed < ::ActiveRecord::ActiveRecordError # @return [RecordNotDestroyed] a new instance of RecordNotDestroyed # - # source://activerecord//lib/active_record/errors.rb#139 + # source://activerecord//lib/active_record/errors.rb#172 def initialize(message = T.unsafe(nil), record = T.unsafe(nil)); end # Returns the value of attribute record. # - # source://activerecord//lib/active_record/errors.rb#137 + # source://activerecord//lib/active_record/errors.rb#170 def record; end end # Raised when Active Record cannot find a record by given id or set of ids. # -# source://activerecord//lib/active_record/errors.rb#102 +# source://activerecord//lib/active_record/errors.rb#123 class ActiveRecord::RecordNotFound < ::ActiveRecord::ActiveRecordError # @return [RecordNotFound] a new instance of RecordNotFound # - # source://activerecord//lib/active_record/errors.rb#105 + # source://activerecord//lib/active_record/errors.rb#126 def initialize(message = T.unsafe(nil), model = T.unsafe(nil), primary_key = T.unsafe(nil), id = T.unsafe(nil)); end # Returns the value of attribute id. # - # source://activerecord//lib/active_record/errors.rb#103 + # source://activerecord//lib/active_record/errors.rb#124 def id; end # Returns the value of attribute model. # - # source://activerecord//lib/active_record/errors.rb#103 + # source://activerecord//lib/active_record/errors.rb#124 def model; end # Returns the value of attribute primary_key. # - # source://activerecord//lib/active_record/errors.rb#103 + # source://activerecord//lib/active_record/errors.rb#124 def primary_key; end end # Raised by {ActiveRecord::Base#save!}[rdoc-ref:Persistence#save!] and -# {ActiveRecord::Base.create!}[rdoc-ref:Persistence::ClassMethods#create!] -# methods when a record is invalid and cannot be saved. +# {ActiveRecord::Base.update_attribute!}[rdoc-ref:Persistence#update_attribute!] +# methods when a record failed to validate or cannot be saved due to any of the +# before_* callbacks throwing +:abort+. See +# ActiveRecord::Callbacks for further details. +# +# class Product < ActiveRecord::Base +# before_save do +# throw :abort if price < 0 +# end +# end # -# source://activerecord//lib/active_record/errors.rb#117 +# Product.create! # => raises an ActiveRecord::RecordNotSaved +# +# source://activerecord//lib/active_record/errors.rb#148 class ActiveRecord::RecordNotSaved < ::ActiveRecord::ActiveRecordError # @return [RecordNotSaved] a new instance of RecordNotSaved # - # source://activerecord//lib/active_record/errors.rb#120 + # source://activerecord//lib/active_record/errors.rb#151 def initialize(message = T.unsafe(nil), record = T.unsafe(nil)); end # Returns the value of attribute record. # - # source://activerecord//lib/active_record/errors.rb#118 + # source://activerecord//lib/active_record/errors.rb#149 def record; end end # Raised when a record cannot be inserted or updated because it would violate a uniqueness constraint. # -# source://activerecord//lib/active_record/errors.rb#174 +# source://activerecord//lib/active_record/errors.rb#216 class ActiveRecord::RecordNotUnique < ::ActiveRecord::WrappedDatabaseException; end # = Active Record Reflection @@ -28074,24 +31188,25 @@ class ActiveRecord::RecordNotUnique < ::ActiveRecord::WrappedDatabaseException; # source://activerecord//lib/active_record/reflection.rb#7 module ActiveRecord::Reflection extend ::ActiveSupport::Concern + extend ::ActiveStorage::Reflection::ReflectionExtension include GeneratedInstanceMethods mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::ActiveRecord::Reflection::ClassMethods class << self - # source://activerecord//lib/active_record/reflection.rb#28 + # source://activerecord//lib/active_record/reflection.rb#29 def add_aggregate_reflection(ar, name, reflection); end - # source://activerecord//lib/active_record/reflection.rb#22 + # source://activerecord//lib/active_record/reflection.rb#23 def add_reflection(ar, name, reflection); end - # source://activerecord//lib/active_record/reflection.rb#17 + # source://activerecord//lib/active_record/reflection.rb#18 def create(macro, name, scope, options, ar); end private - # source://activerecord//lib/active_record/reflection.rb#33 + # source://activestorage/7.2.0/lib/active_storage/reflection.rb#37 def reflection_class_for(macro); end end @@ -28105,6 +31220,9 @@ module ActiveRecord::Reflection def automatic_scope_inversing; end def automatic_scope_inversing=(value); end def automatic_scope_inversing?; end + def automatically_invert_plural_associations; end + def automatically_invert_plural_associations=(value); end + def automatically_invert_plural_associations?; end end module GeneratedInstanceMethods @@ -28114,6 +31232,8 @@ module ActiveRecord::Reflection def aggregate_reflections?; end def automatic_scope_inversing; end def automatic_scope_inversing?; end + def automatically_invert_plural_associations; end + def automatically_invert_plural_associations?; end end end @@ -28131,24 +31251,29 @@ end # PolymorphicReflection # RuntimeReflection # -# source://activerecord//lib/active_record/reflection.rb#146 +# source://activerecord//lib/active_record/reflection.rb#163 class ActiveRecord::Reflection::AbstractReflection - # source://activerecord//lib/active_record/reflection.rb#280 + # @return [AbstractReflection] a new instance of AbstractReflection + # + # source://activerecord//lib/active_record/reflection.rb#164 + def initialize; end + + # source://activerecord//lib/active_record/reflection.rb#328 def alias_candidate(name); end # Returns a new, unsaved instance of the associated class. +attributes+ will # be passed to the class's constructor. # - # source://activerecord//lib/active_record/reflection.rb#157 + # source://activerecord//lib/active_record/reflection.rb#182 def build_association(attributes, &block); end - # source://activerecord//lib/active_record/reflection.rb#288 + # source://activerecord//lib/active_record/reflection.rb#336 def build_scope(table, predicate_builder = T.unsafe(nil), klass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#284 + # source://activerecord//lib/active_record/reflection.rb#332 def chain; end - # source://activerecord//lib/active_record/reflection.rb#233 + # source://activerecord//lib/active_record/reflection.rb#264 def check_validity_of_inverse!; end # Returns the class name for the macro. @@ -28156,31 +31281,39 @@ class ActiveRecord::Reflection::AbstractReflection # composed_of :balance, class_name: 'Money' returns 'Money' # has_many :clients returns 'Client' # - # source://activerecord//lib/active_record/reflection.rb#165 + # source://activerecord//lib/active_record/reflection.rb#190 def class_name; end - # source://activerecord//lib/active_record/reflection.rb#211 + # source://activerecord//lib/active_record/reflection.rb#240 def constraints; end - # source://activerecord//lib/active_record/reflection.rb#215 + # source://activerecord//lib/active_record/reflection.rb#244 def counter_cache_column; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#276 + # source://activerecord//lib/active_record/reflection.rb#324 def counter_must_be_updated_by_has_many?; end - # Returns whether a counter cache should be used for this association. + # Returns whether this association has a counter cache and its column values were backfilled + # (and so it is used internally by methods like +size+/+any?+/etc). + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/reflection.rb#315 + def has_active_cached_counter?; end + + # Returns whether this association has a counter cache. # # The counter_cache option must be given on either the owner or inverse # association, and the column must be present on the owner. # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#270 + # source://activerecord//lib/active_record/reflection.rb#307 def has_cached_counter?; end - # source://activerecord//lib/active_record/reflection.rb#227 + # source://activerecord//lib/active_record/reflection.rb#258 def inverse_of; end # We need to avoid the following situation: @@ -28194,12 +31327,12 @@ class ActiveRecord::Reflection::AbstractReflection # # Hence this method. # - # source://activerecord//lib/active_record/reflection.rb#254 + # source://activerecord//lib/active_record/reflection.rb#285 def inverse_updates_counter_cache?; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#262 + # source://activerecord//lib/active_record/reflection.rb#299 def inverse_updates_counter_in_memory?; end # We need to avoid the following situation: @@ -28213,127 +31346,127 @@ class ActiveRecord::Reflection::AbstractReflection # # Hence this method. # - # source://activerecord//lib/active_record/reflection.rb#254 + # source://activerecord//lib/active_record/reflection.rb#285 def inverse_which_updates_counter_cache; end - # source://activerecord//lib/active_record/reflection.rb#175 + # source://activerecord//lib/active_record/reflection.rb#200 def join_scope(table, foreign_table, foreign_klass); end - # source://activerecord//lib/active_record/reflection.rb#198 + # source://activerecord//lib/active_record/reflection.rb#227 def join_scopes(table, predicate_builder, klass = T.unsafe(nil), record = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#206 + # source://activerecord//lib/active_record/reflection.rb#235 def klass_join_scope(table, predicate_builder); end # Returns a list of scopes that should be applied for this Reflection # object when querying the database. # - # source://activerecord//lib/active_record/reflection.rb#171 + # source://activerecord//lib/active_record/reflection.rb#196 def scopes; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#296 + # source://activerecord//lib/active_record/reflection.rb#344 def strict_loading?; end - # source://activerecord//lib/active_record/reflection.rb#300 + # source://activerecord//lib/active_record/reflection.rb#348 def strict_loading_violation_message(owner); end - # source://activerecord//lib/active_record/reflection.rb#151 + # source://activerecord//lib/active_record/reflection.rb#176 def table_name; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#147 + # source://activerecord//lib/active_record/reflection.rb#172 def through_reflection?; end protected # FIXME: this is a horrible name # - # source://activerecord//lib/active_record/reflection.rb#307 + # source://activerecord//lib/active_record/reflection.rb#355 def actual_source_reflection; end private - # source://activerecord//lib/active_record/reflection.rb#320 + # source://activerecord//lib/active_record/reflection.rb#368 def ensure_option_not_given_as_class!(option_name); end - # source://activerecord//lib/active_record/reflection.rb#312 + # source://activerecord//lib/active_record/reflection.rb#360 def predicate_builder(table); end - # source://activerecord//lib/active_record/reflection.rb#316 + # source://activerecord//lib/active_record/reflection.rb#364 def primary_key(klass); end end # Holds all the metadata about an aggregation as it was specified in the # Active Record class. # -# source://activerecord//lib/active_record/reflection.rb#411 +# source://activerecord//lib/active_record/reflection.rb#484 class ActiveRecord::Reflection::AggregateReflection < ::ActiveRecord::Reflection::MacroReflection - # source://activerecord//lib/active_record/reflection.rb#412 + # source://activerecord//lib/active_record/reflection.rb#485 def mapping; end end # Holds all the metadata about an association as it was specified in the # Active Record class. # -# source://activerecord//lib/active_record/reflection.rb#420 +# source://activerecord//lib/active_record/reflection.rb#493 class ActiveRecord::Reflection::AssociationReflection < ::ActiveRecord::Reflection::MacroReflection # @return [AssociationReflection] a new instance of AssociationReflection # - # source://activerecord//lib/active_record/reflection.rb#448 + # source://activerecord//lib/active_record/reflection.rb#521 def initialize(name, scope, options, active_record); end - # source://activerecord//lib/active_record/reflection.rb#480 + # source://activerecord//lib/active_record/reflection.rb#586 def active_record_primary_key; end - # source://activerecord//lib/active_record/reflection.rb#595 + # source://activerecord//lib/active_record/reflection.rb#732 def add_as_polymorphic_through(reflection, seed); end - # source://activerecord//lib/active_record/reflection.rb#591 + # source://activerecord//lib/active_record/reflection.rb#728 def add_as_source(seed); end - # source://activerecord//lib/active_record/reflection.rb#599 + # source://activerecord//lib/active_record/reflection.rb#736 def add_as_through(seed); end # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/reflection.rb#585 + # source://activerecord//lib/active_record/reflection.rb#718 def association_class; end - # source://activerecord//lib/active_record/reflection.rb#472 + # source://activerecord//lib/active_record/reflection.rb#578 def association_foreign_key; end - # source://activerecord//lib/active_record/reflection.rb#476 + # source://activerecord//lib/active_record/reflection.rb#582 def association_primary_key(klass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#456 + # source://activerecord//lib/active_record/reflection.rb#544 def association_scope_cache(klass, owner, &block); end # Returns +true+ if +self+ is a +belongs_to+ reflection. # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#580 + # source://activerecord//lib/active_record/reflection.rb#713 def belongs_to?; end - # source://activerecord//lib/active_record/reflection.rb#496 + # source://activerecord//lib/active_record/reflection.rb#629 def check_eager_loadable!; end - # source://activerecord//lib/active_record/reflection.rb#492 + # source://activerecord//lib/active_record/reflection.rb#617 def check_validity!; end # This is for clearing cache on the reflection. Useful for tests that need to compare # SQL queries on associations. # - # source://activerecord//lib/active_record/reflection.rb#528 + # source://activerecord//lib/active_record/reflection.rb#661 def clear_association_scope_cache; end # A chain of reflections from this one back to the owner. For more see the explanation in # ThroughReflection. # - # source://activerecord//lib/active_record/reflection.rb#522 + # source://activerecord//lib/active_record/reflection.rb#655 def collect_join_chain; end # Returns whether or not this association reflection is for a collection @@ -28342,50 +31475,53 @@ class ActiveRecord::Reflection::AssociationReflection < ::ActiveRecord::Reflecti # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#562 + # source://activerecord//lib/active_record/reflection.rb#695 def collection?; end - # source://activerecord//lib/active_record/reflection.rb#421 + # source://activerecord//lib/active_record/reflection.rb#494 def compute_class(name); end - # source://activerecord//lib/active_record/reflection.rb#603 + # source://activerecord//lib/active_record/reflection.rb#740 def extensions; end - # source://activerecord//lib/active_record/reflection.rb#468 - def foreign_key; end + # source://activerecord//lib/active_record/reflection.rb#558 + def foreign_key(infer_from_inverse_of: T.unsafe(nil)); end # Returns the value of attribute foreign_type. # - # source://activerecord//lib/active_record/reflection.rb#445 + # source://activerecord//lib/active_record/reflection.rb#518 def foreign_type; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#540 + # source://activerecord//lib/active_record/reflection.rb#673 def has_inverse?; end # Returns +true+ if +self+ is a +has_one+ reflection. # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#583 + # source://activerecord//lib/active_record/reflection.rb#716 def has_one?; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#536 + # source://activerecord//lib/active_record/reflection.rb#669 def has_scope?; end - # source://activerecord//lib/active_record/reflection.rb#488 + # source://activerecord//lib/active_record/reflection.rb#613 def join_foreign_key; end - # source://activerecord//lib/active_record/reflection.rb#508 + # source://activerecord//lib/active_record/reflection.rb#641 def join_id_for(owner); end - # source://activerecord//lib/active_record/reflection.rb#484 + # source://activerecord//lib/active_record/reflection.rb#605 def join_primary_key(klass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#464 + # source://activerecord//lib/active_record/reflection.rb#609 + def join_primary_type; end + + # source://activerecord//lib/active_record/reflection.rb#554 def join_table; end # Returns the macro type. @@ -28394,41 +31530,44 @@ class ActiveRecord::Reflection::AssociationReflection < ::ActiveRecord::Reflecti # # @raise [NotImplementedError] # - # source://activerecord//lib/active_record/reflection.rb#557 + # source://activerecord//lib/active_record/reflection.rb#690 def macro; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#532 + # source://activerecord//lib/active_record/reflection.rb#665 def nested?; end # Reflection # - # source://activerecord//lib/active_record/reflection.rb#446 + # source://activerecord//lib/active_record/reflection.rb#519 def parent_reflection; end # Reflection # - # source://activerecord//lib/active_record/reflection.rb#446 + # source://activerecord//lib/active_record/reflection.rb#519 def parent_reflection=(_arg0); end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#587 + # source://activerecord//lib/active_record/reflection.rb#720 def polymorphic?; end - # source://activerecord//lib/active_record/reflection.rb#544 + # source://activerecord//lib/active_record/reflection.rb#677 def polymorphic_inverse_of(associated_class); end - # source://activerecord//lib/active_record/reflection.rb#516 + # source://activerecord//lib/active_record/reflection.rb#724 + def polymorphic_name; end + + # source://activerecord//lib/active_record/reflection.rb#649 def source_reflection; end - # source://activerecord//lib/active_record/reflection.rb#512 + # source://activerecord//lib/active_record/reflection.rb#645 def through_reflection; end # Returns the value of attribute type. # - # source://activerecord//lib/active_record/reflection.rb#445 + # source://activerecord//lib/active_record/reflection.rb#518 def type; end # Returns whether or not the association should be validated as part of @@ -28443,14 +31582,14 @@ class ActiveRecord::Reflection::AssociationReflection < ::ActiveRecord::Reflecti # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#575 + # source://activerecord//lib/active_record/reflection.rb#708 def validate?; end private # returns either +nil+ or the inverse association name that it finds. # - # source://activerecord//lib/active_record/reflection.rb#620 + # source://activerecord//lib/active_record/reflection.rb#757 def automatic_inverse_of; end # Checks to see if the reflection doesn't have any options that prevent @@ -28462,23 +31601,26 @@ class ActiveRecord::Reflection::AssociationReflection < ::ActiveRecord::Reflecti # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#656 + # source://activerecord//lib/active_record/reflection.rb#799 def can_find_inverse_of_automatically?(reflection, inverse_reflection = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#677 + # source://activerecord//lib/active_record/reflection.rb#820 def derive_class_name; end - # source://activerecord//lib/active_record/reflection.rb#683 - def derive_foreign_key; end + # source://activerecord//lib/active_record/reflection.rb#838 + def derive_fk_query_constraints(foreign_key); end - # source://activerecord//lib/active_record/reflection.rb#693 + # source://activerecord//lib/active_record/reflection.rb#826 + def derive_foreign_key(infer_from_inverse_of: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/reflection.rb#878 def derive_join_table; end # Attempts to find the inverse association name automatically. # If it cannot find a suitable inverse association name, it returns # +nil+. # - # source://activerecord//lib/active_record/reflection.rb#611 + # source://activerecord//lib/active_record/reflection.rb#748 def inverse_name; end # Scopes on the potential inverse reflection prevent automatic @@ -28490,7 +31632,7 @@ class ActiveRecord::Reflection::AssociationReflection < ::ActiveRecord::Reflecti # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#669 + # source://activerecord//lib/active_record/reflection.rb#812 def scope_allows_automatic_inverse_of?(reflection, inverse_reflection); end # Checks if the inverse reflection that is returned from the @@ -28500,45 +31642,47 @@ class ActiveRecord::Reflection::AssociationReflection < ::ActiveRecord::Reflecti # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#642 + # source://activerecord//lib/active_record/reflection.rb#785 def valid_inverse_reflection?(reflection); end end -# source://activerecord//lib/active_record/reflection.rb#726 +# source://activerecord//lib/active_record/reflection.rb#911 class ActiveRecord::Reflection::BelongsToReflection < ::ActiveRecord::Reflection::AssociationReflection - # source://activerecord//lib/active_record/reflection.rb#731 + # source://activerecord//lib/active_record/reflection.rb#916 def association_class; end # klass option is necessary to support loading polymorphic associations # - # source://activerecord//lib/active_record/reflection.rb#740 + # source://activerecord//lib/active_record/reflection.rb#925 def association_primary_key(klass = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#729 + # source://activerecord//lib/active_record/reflection.rb#914 def belongs_to?; end - # source://activerecord//lib/active_record/reflection.rb#752 + # source://activerecord//lib/active_record/reflection.rb#947 def join_foreign_key; end - # source://activerecord//lib/active_record/reflection.rb#756 + # source://activerecord//lib/active_record/reflection.rb#951 def join_foreign_type; end - # source://activerecord//lib/active_record/reflection.rb#748 + # source://activerecord//lib/active_record/reflection.rb#943 def join_primary_key(klass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#727 + # source://activerecord//lib/active_record/reflection.rb#912 def macro; end private # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#761 + # source://activerecord//lib/active_record/reflection.rb#956 def can_find_inverse_of_automatically?(*_arg0); end end +# = Active Record Reflection +# # \Reflection enables the ability to examine the associations and aggregations of # Active Record classes and objects. This information, for example, # can be used in a form builder that takes an Active Record object @@ -28548,24 +31692,29 @@ end # MacroReflection class has info for AggregateReflection and AssociationReflection # classes. # -# source://activerecord//lib/active_record/reflection.rb#57 +# source://activerecord//lib/active_record/reflection.rb#60 module ActiveRecord::Reflection::ClassMethods - # source://activerecord//lib/active_record/reflection.rb#119 + # source://activerecord//lib/active_record/reflection.rb#126 def _reflect_on_association(association); end - # source://activerecord//lib/active_record/reflection.rb#128 + # source://activerecord//lib/active_record/reflection.rb#137 def clear_reflections_cache; end + # :nodoc + # + # source://activerecord//lib/active_record/reflection.rb#82 + def normalized_reflections; end + # Returns the AggregateReflection object for the named +aggregation+ (use the symbol). # # Account.reflect_on_aggregation(:balance) # => the balance AggregateReflection # - # source://activerecord//lib/active_record/reflection.rb#67 + # source://activerecord//lib/active_record/reflection.rb#70 def reflect_on_aggregation(aggregation); end # Returns an array of AggregateReflection objects for all the aggregations in the class. # - # source://activerecord//lib/active_record/reflection.rb#59 + # source://activerecord//lib/active_record/reflection.rb#62 def reflect_on_all_aggregations; end # Returns an array of AssociationReflection objects for all the @@ -28578,12 +31727,12 @@ module ActiveRecord::Reflection::ClassMethods # Account.reflect_on_all_associations # returns an array of all associations # Account.reflect_on_all_associations(:has_many) # returns an array of all has_many associations # - # source://activerecord//lib/active_record/reflection.rb#104 + # source://activerecord//lib/active_record/reflection.rb#111 def reflect_on_all_associations(macro = T.unsafe(nil)); end # Returns an array of AssociationReflection objects for all associations which have :autosave enabled. # - # source://activerecord//lib/active_record/reflection.rb#124 + # source://activerecord//lib/active_record/reflection.rb#131 def reflect_on_all_autosave_associations; end # Returns the AssociationReflection object for the +association+ (use the symbol). @@ -28591,83 +31740,91 @@ module ActiveRecord::Reflection::ClassMethods # Account.reflect_on_association(:owner) # returns the owner AssociationReflection # Invoice.reflect_on_association(:line_items).macro # returns :has_many # - # source://activerecord//lib/active_record/reflection.rb#115 + # source://activerecord//lib/active_record/reflection.rb#122 def reflect_on_association(association); end # Returns a Hash of name of the reflection as the key and an AssociationReflection as the value. # # Account.reflections # => {"balance" => AggregateReflection} # - # source://activerecord//lib/active_record/reflection.rb#75 + # source://activerecord//lib/active_record/reflection.rb#78 def reflections; end + + private + + # source://activerecord//lib/active_record/reflection.rb#142 + def inherited(subclass); end end -# source://activerecord//lib/active_record/reflection.rb#766 +# source://activerecord//lib/active_record/reflection.rb#961 class ActiveRecord::Reflection::HasAndBelongsToManyReflection < ::ActiveRecord::Reflection::AssociationReflection # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#769 + # source://activerecord//lib/active_record/reflection.rb#964 def collection?; end - # source://activerecord//lib/active_record/reflection.rb#767 + # source://activerecord//lib/active_record/reflection.rb#962 def macro; end end -# source://activerecord//lib/active_record/reflection.rb#698 +# source://activerecord//lib/active_record/reflection.rb#883 class ActiveRecord::Reflection::HasManyReflection < ::ActiveRecord::Reflection::AssociationReflection - # source://activerecord//lib/active_record/reflection.rb#703 + # source://activerecord//lib/active_record/reflection.rb#888 def association_class; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#701 + # source://activerecord//lib/active_record/reflection.rb#886 def collection?; end - # source://activerecord//lib/active_record/reflection.rb#699 + # source://activerecord//lib/active_record/reflection.rb#884 def macro; end end -# source://activerecord//lib/active_record/reflection.rb#712 +# source://activerecord//lib/active_record/reflection.rb#897 class ActiveRecord::Reflection::HasOneReflection < ::ActiveRecord::Reflection::AssociationReflection - # source://activerecord//lib/active_record/reflection.rb#717 + # source://activerecord//lib/active_record/reflection.rb#902 def association_class; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#715 + # source://activerecord//lib/active_record/reflection.rb#900 def has_one?; end - # source://activerecord//lib/active_record/reflection.rb#713 + # source://activerecord//lib/active_record/reflection.rb#898 def macro; end end # Base class for AggregateReflection and AssociationReflection. Objects of # AggregateReflection and AssociationReflection are returned by the Reflection::ClassMethods. # -# source://activerecord//lib/active_record/reflection.rb#329 +# source://activerecord//lib/active_record/reflection.rb#377 class ActiveRecord::Reflection::MacroReflection < ::ActiveRecord::Reflection::AbstractReflection # @return [MacroReflection] a new instance of MacroReflection # - # source://activerecord//lib/active_record/reflection.rb#348 + # source://activerecord//lib/active_record/reflection.rb#396 def initialize(name, scope, options, active_record); end # Returns +true+ if +self+ and +other_aggregation+ have the same +name+ attribute, +active_record+ attribute, # and +other_aggregation+ has an options hash assigned to it. # - # source://activerecord//lib/active_record/reflection.rb#391 + # source://activerecord//lib/active_record/reflection.rb#444 def ==(other_aggregation); end # Returns the value of attribute active_record. # - # source://activerecord//lib/active_record/reflection.rb#344 + # source://activerecord//lib/active_record/reflection.rb#392 def active_record; end - # source://activerecord//lib/active_record/reflection.rb#358 + # source://activerecord//lib/active_record/reflection.rb#407 def autosave=(autosave); end - # source://activerecord//lib/active_record/reflection.rb#385 + # source://activerecord//lib/active_record/reflection.rb#434 def compute_class(name); end + # source://activerecord//lib/active_record/reflection.rb#438 + def compute_name(name); end + # Returns the class for the macro. # # composed_of :balance, class_name: 'Money' returns the Money class @@ -28684,7 +31841,7 @@ class ActiveRecord::Reflection::MacroReflection < ::ActiveRecord::Reflection::Ab # a new association object. Use +build_association+ or +create_association+ # instead. This allows plugins to hook into association object creation. # - # source://activerecord//lib/active_record/reflection.rb#381 + # source://activerecord//lib/active_record/reflection.rb#430 def klass; end # Returns the name of the macro. @@ -28692,7 +31849,7 @@ class ActiveRecord::Reflection::MacroReflection < ::ActiveRecord::Reflection::Ab # composed_of :balance, class_name: 'Money' returns :balance # has_many :clients returns :clients # - # source://activerecord//lib/active_record/reflection.rb#334 + # source://activerecord//lib/active_record/reflection.rb#382 def name; end # Returns the hash of options used for the macro. @@ -28700,158 +31857,161 @@ class ActiveRecord::Reflection::MacroReflection < ::ActiveRecord::Reflection::Ab # composed_of :balance, class_name: 'Money' returns { class_name: "Money" } # has_many :clients returns {} # - # source://activerecord//lib/active_record/reflection.rb#342 + # source://activerecord//lib/active_record/reflection.rb#390 def options; end - # source://activerecord//lib/active_record/reflection.rb#346 + # source://activerecord//lib/active_record/reflection.rb#394 def plural_name; end # Returns the value of attribute scope. # - # source://activerecord//lib/active_record/reflection.rb#336 + # source://activerecord//lib/active_record/reflection.rb#384 def scope; end - # source://activerecord//lib/active_record/reflection.rb#399 + # source://activerecord//lib/active_record/reflection.rb#452 def scope_for(relation, owner = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/reflection.rb#404 + # source://activerecord//lib/active_record/reflection.rb#457 def derive_class_name; end + + # source://activerecord//lib/active_record/reflection.rb#461 + def normalize_options(options); end end -# source://activerecord//lib/active_record/reflection.rb#1030 +# source://activerecord//lib/active_record/reflection.rb#1227 class ActiveRecord::Reflection::PolymorphicReflection < ::ActiveRecord::Reflection::AbstractReflection # @return [PolymorphicReflection] a new instance of PolymorphicReflection # - # source://activerecord//lib/active_record/reflection.rb#1034 + # source://activerecord//lib/active_record/reflection.rb#1231 def initialize(reflection, previous_reflection); end - # source://activerecord//lib/active_record/reflection.rb#1044 + # source://activerecord//lib/active_record/reflection.rb#1242 def constraints; end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def join_foreign_key(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def join_primary_key(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1039 + # source://activerecord//lib/active_record/reflection.rb#1237 def join_scopes(table, predicate_builder, klass = T.unsafe(nil), record = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def klass(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def name(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def plural_name(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def scope(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def scope_for(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1031 + # source://activerecord//lib/active_record/reflection.rb#1228 def type(*_arg0, **_arg1, &_arg2); end private - # source://activerecord//lib/active_record/reflection.rb#1049 + # source://activerecord//lib/active_record/reflection.rb#1247 def source_type_scope; end end -# source://activerecord//lib/active_record/reflection.rb#1056 +# source://activerecord//lib/active_record/reflection.rb#1254 class ActiveRecord::Reflection::RuntimeReflection < ::ActiveRecord::Reflection::AbstractReflection # @return [RuntimeReflection] a new instance of RuntimeReflection # - # source://activerecord//lib/active_record/reflection.rb#1059 + # source://activerecord//lib/active_record/reflection.rb#1257 def initialize(reflection, association); end - # source://activerecord//lib/active_record/reflection.rb#1068 + # source://activerecord//lib/active_record/reflection.rb#1267 def aliased_table; end - # source://activerecord//lib/active_record/reflection.rb#1076 + # source://activerecord//lib/active_record/reflection.rb#1275 def all_includes; end - # source://activerecord//lib/active_record/reflection.rb#1057 + # source://activerecord//lib/active_record/reflection.rb#1255 def constraints(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1057 + # source://activerecord//lib/active_record/reflection.rb#1255 def join_foreign_key(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1072 + # source://activerecord//lib/active_record/reflection.rb#1271 def join_primary_key(klass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#1064 + # source://activerecord//lib/active_record/reflection.rb#1263 def klass; end - # source://activerecord//lib/active_record/reflection.rb#1057 + # source://activerecord//lib/active_record/reflection.rb#1255 def scope(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1057 + # source://activerecord//lib/active_record/reflection.rb#1255 def type(*_arg0, **_arg1, &_arg2); end end # Holds all the metadata about a :through association as it was specified # in the Active Record class. # -# source://activerecord//lib/active_record/reflection.rb#776 +# source://activerecord//lib/active_record/reflection.rb#971 class ActiveRecord::Reflection::ThroughReflection < ::ActiveRecord::Reflection::AbstractReflection # @return [ThroughReflection] a new instance of ThroughReflection # - # source://activerecord//lib/active_record/reflection.rb#780 + # source://activerecord//lib/active_record/reflection.rb#975 def initialize(delegate_reflection); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def active_record(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#777 + # source://activerecord//lib/active_record/reflection.rb#972 def active_record_primary_key(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#992 + # source://activerecord//lib/active_record/reflection.rb#1189 def add_as_polymorphic_through(reflection, seed); end - # source://activerecord//lib/active_record/reflection.rb#988 + # source://activerecord//lib/active_record/reflection.rb#1185 def add_as_source(seed); end - # source://activerecord//lib/active_record/reflection.rb#996 + # source://activerecord//lib/active_record/reflection.rb#1193 def add_as_through(seed); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def association_class(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#777 + # source://activerecord//lib/active_record/reflection.rb#972 def association_foreign_key(*_arg0, **_arg1, &_arg2); end # We want to use the klass from this reflection, rather than just delegate straight to # the source_reflection, because the source_reflection may be polymorphic. We still # need to respect the source_reflection's :primary_key option, though. # - # source://activerecord//lib/active_record/reflection.rb#884 + # source://activerecord//lib/active_record/reflection.rb#1082 def association_primary_key(klass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def association_scope_cache(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def autosave=(arg); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def belongs_to?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def check_eager_loadable!(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#942 + # source://activerecord//lib/active_record/reflection.rb#1139 def check_validity!; end # This is for clearing cache on the reflection. Useful for tests that need to compare # SQL queries on associations. # - # source://activerecord//lib/active_record/reflection.rb#856 + # source://activerecord//lib/active_record/reflection.rb#1054 def clear_association_scope_cache; end # Returns an array of reflections which are involved in this association. Each item in the @@ -28871,97 +32031,106 @@ class ActiveRecord::Reflection::ThroughReflection < ::ActiveRecord::Reflection:: # # => [, # ] # - # source://activerecord//lib/active_record/reflection.rb#850 + # source://activerecord//lib/active_record/reflection.rb#1048 def collect_join_chain; end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def collection?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def compute_class(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#982 + # source://activerecord//lib/active_record/reflection.rb#1224 + def compute_name(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/reflection.rb#1179 def constraints; end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def extensions(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#777 + # source://activerecord//lib/active_record/reflection.rb#972 def foreign_key(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#777 + # source://activerecord//lib/active_record/reflection.rb#972 def foreign_type(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def has_inverse?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def has_one?(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#870 + # source://activerecord//lib/active_record/reflection.rb#1068 def has_scope?; end - # source://activerecord//lib/active_record/reflection.rb#777 + # source://activerecord//lib/active_record/reflection.rb#972 def join_foreign_key(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#777 + # source://activerecord//lib/active_record/reflection.rb#972 def join_id_for(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#894 + # source://activerecord//lib/active_record/reflection.rb#1092 def join_primary_key(klass = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#866 + # source://activerecord//lib/active_record/reflection.rb#1224 + def join_primary_type(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/reflection.rb#1064 def join_scopes(table, predicate_builder, klass = T.unsafe(nil), record = T.unsafe(nil)); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def join_table(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#792 + # source://activerecord//lib/active_record/reflection.rb#988 def klass; end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def macro(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def name(*_arg0, **_arg1, &_arg2); end # A through association is nested if there would be more than one join table # # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#877 + # source://activerecord//lib/active_record/reflection.rb#1075 def nested?; end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def options(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def parent_reflection(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def parent_reflection=(arg); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def plural_name(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def polymorphic?(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def polymorphic_inverse_of(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 + def polymorphic_name(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/reflection.rb#1224 def scope(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def scope_for(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#862 + # source://activerecord//lib/active_record/reflection.rb#1060 def scopes; end - # source://activerecord//lib/active_record/reflection.rb#934 + # source://activerecord//lib/active_record/reflection.rb#1131 def source_options; end # Returns the source of the through reflection. It checks both a singularized @@ -28981,10 +32150,10 @@ class ActiveRecord::Reflection::ThroughReflection < ::ActiveRecord::Reflection:: # tags_reflection.source_reflection # # => # - # source://activerecord//lib/active_record/reflection.rb#813 + # source://activerecord//lib/active_record/reflection.rb#1009 def source_reflection; end - # source://activerecord//lib/active_record/reflection.rb#913 + # source://activerecord//lib/active_record/reflection.rb#1111 def source_reflection_name; end # Gets an array of possible :through source reflection names in both singular and plural form. @@ -28998,10 +32167,10 @@ class ActiveRecord::Reflection::ThroughReflection < ::ActiveRecord::Reflection:: # tags_reflection.source_reflection_names # # => [:tag, :tags] # - # source://activerecord//lib/active_record/reflection.rb#909 + # source://activerecord//lib/active_record/reflection.rb#1107 def source_reflection_names; end - # source://activerecord//lib/active_record/reflection.rb#938 + # source://activerecord//lib/active_record/reflection.rb#1135 def through_options; end # Returns the AssociationReflection object specified in the :through option @@ -29016,41 +32185,41 @@ class ActiveRecord::Reflection::ThroughReflection < ::ActiveRecord::Reflection:: # tags_reflection.through_reflection # # => # - # source://activerecord//lib/active_record/reflection.rb#829 + # source://activerecord//lib/active_record/reflection.rb#1027 def through_reflection; end # @return [Boolean] # - # source://activerecord//lib/active_record/reflection.rb#788 + # source://activerecord//lib/active_record/reflection.rb#984 def through_reflection?; end - # source://activerecord//lib/active_record/reflection.rb#777 + # source://activerecord//lib/active_record/reflection.rb#972 def type(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/reflection.rb#1027 + # source://activerecord//lib/active_record/reflection.rb#1224 def validate?(*_arg0, **_arg1, &_arg2); end protected # FIXME: this is a horrible name # - # source://activerecord//lib/active_record/reflection.rb#1001 + # source://activerecord//lib/active_record/reflection.rb#1198 def actual_source_reflection; end private - # source://activerecord//lib/active_record/reflection.rb#1008 + # source://activerecord//lib/active_record/reflection.rb#1205 def collect_join_reflections(seed); end # Returns the value of attribute delegate_reflection. # - # source://activerecord//lib/active_record/reflection.rb#1006 + # source://activerecord//lib/active_record/reflection.rb#1203 def delegate_reflection; end - # source://activerecord//lib/active_record/reflection.rb#1019 + # source://activerecord//lib/active_record/reflection.rb#1216 def derive_class_name; end - # source://activerecord//lib/active_record/reflection.rb#1017 + # source://activerecord//lib/active_record/reflection.rb#1214 def inverse_name; end end @@ -29067,41 +32236,48 @@ class ActiveRecord::Relation include ::ActiveRecord::SpawnMethods include ::ActiveRecord::Calculations include ::ActiveRecord::FinderMethods + include ::ActiveRecord::TokenFor::RelationMethods + include ::ActiveRecord::SignedId::RelationMethods extend ::ActiveRecord::Delegation::ClassMethods # @return [Relation] a new instance of Relation # - # source://activerecord//lib/active_record/relation.rb#27 + # source://activerecord//lib/active_record/relation.rb#77 def initialize(klass, table: T.unsafe(nil), predicate_builder: T.unsafe(nil), values: T.unsafe(nil)); end # Compares two relations for equality. # - # source://activerecord//lib/active_record/relation.rb#766 + # source://activerecord//lib/active_record/relation.rb#1239 def ==(other); end - # source://activerecord//lib/active_record/relation.rb#432 + # source://activerecord//lib/active_record/relation.rb#545 def _exec_scope(*_arg0, **_arg1, &_arg2); end - # source://activerecord//lib/active_record/relation.rb#811 + # source://activerecord//lib/active_record/relation.rb#1289 def alias_tracker(joins = T.unsafe(nil), aliases = T.unsafe(nil)); end # Returns true if there are any records. # + # When a pattern argument is given, this method checks whether elements in + # the Enumerable match the pattern via the case-equality operator (===). + # + # posts.any?(Post) # => true or false + # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#284 - def any?; end + # source://activerecord//lib/active_record/relation.rb#384 + def any?(*args); end # @yield [attr, bind] # - # source://activerecord//lib/active_record/relation.rb#43 + # source://activerecord//lib/active_record/relation.rb#95 def bind_attribute(name, value); end # Returns true if relation is blank. # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#782 + # source://activerecord//lib/active_record/relation.rb#1260 def blank?; end # Initializes new record from relation while maintaining the current @@ -29117,7 +32293,7 @@ class ActiveRecord::Relation # user = users.new { |user| user.name = 'Oscar' } # user.name # => Oscar # - # source://activerecord//lib/active_record/relation.rb#66 + # source://activerecord//lib/active_record/relation.rb#118 def build(attributes = T.unsafe(nil), &block); end # Returns a stable cache key that can be used to identify this query. @@ -29127,7 +32303,7 @@ class ActiveRecord::Relation # # => "products/query-1850ab3d302391b85b8693e941286659" # # If ActiveRecord::Base.collection_cache_versioning is turned off, as it was - # in Rails 6.0 and earlier, the cache key will also include a version. + # in \Rails 6.0 and earlier, the cache key will also include a version. # # ActiveRecord::Base.collection_cache_versioning = false # Product.where("name like ?", "%Cosmic Encounter%").cache_key @@ -29138,12 +32314,12 @@ class ActiveRecord::Relation # # Product.where("name like ?", "%Game%").cache_key(:last_reviewed_at) # - # source://activerecord//lib/active_record/relation.rb#320 + # source://activerecord//lib/active_record/relation.rb#431 def cache_key(timestamp_column = T.unsafe(nil)); end # Returns a cache key along with the version. # - # source://activerecord//lib/active_record/relation.rb#399 + # source://activerecord//lib/active_record/relation.rb#512 def cache_key_with_version; end # Returns a cache version that can be used together with the cache key to form @@ -29157,7 +32333,7 @@ class ActiveRecord::Relation # # SELECT COUNT(*), MAX("products"."updated_at") FROM "products" WHERE (name like '%Cosmic Encounter%') # - # source://activerecord//lib/active_record/relation.rb#347 + # source://activerecord//lib/active_record/relation.rb#458 def cache_version(timestamp_column = T.unsafe(nil)); end # Tries to create a new record with the same scoped attributes @@ -29180,7 +32356,7 @@ class ActiveRecord::Relation # users.create(name: nil) # validation on name # # => # # - # source://activerecord//lib/active_record/relation.rb#95 + # source://activerecord//lib/active_record/relation.rb#147 def create(attributes = T.unsafe(nil), &block); end # Similar to #create, but calls @@ -29190,7 +32366,7 @@ class ActiveRecord::Relation # Expects arguments in the same format as # {ActiveRecord::Base.create!}[rdoc-ref:Persistence::ClassMethods#create!]. # - # source://activerecord//lib/active_record/relation.rb#110 + # source://activerecord//lib/active_record/relation.rb#162 def create!(attributes = T.unsafe(nil), &block); end # Attempts to create a record with the given attributes in a table that has a unique database constraint @@ -29198,16 +32374,15 @@ class ActiveRecord::Relation # unique constraints, the exception such an insertion would normally raise is caught, # and the existing record with those attributes is found using #find_by!. # - # This is similar to #find_or_create_by, but avoids the problem of stale reads between the SELECT - # and the INSERT, as that method needs to first query the table, then attempt to insert a row - # if none is found. + # This is similar to #find_or_create_by, but tries to create the record first. As such it is + # better suited for cases where the record is most likely not to exist yet. # # There are several drawbacks to #create_or_find_by, though: # # * The underlying table must have the relevant columns defined with unique database constraints. # * A unique constraint violation may be triggered by only one, or at least less than all, # of the given attributes. This means that the subsequent #find_by! may fail to find a - # matching record, which will then raise an ActiveRecord::RecordNotFound exception, + # matching record, which will then raise an ActiveRecord::RecordNotFound exception, # rather than a record with the given attributes. # * While we avoid the race condition between SELECT -> INSERT from #find_or_create_by, # we actually have another race condition between INSERT -> SELECT, which can be triggered @@ -29216,24 +32391,48 @@ class ActiveRecord::Relation # * It relies on exception handling to handle control flow, which may be marginally slower. # * The primary key may auto-increment on each create, even if it fails. This can accelerate # the problem of running out of integers, if the underlying table is still stuck on a primary - # key of type int (note: All Rails apps since 5.1+ have defaulted to bigint, which is not liable + # key of type int (note: All \Rails apps since 5.1+ have defaulted to bigint, which is not liable # to this problem). + # * Columns with unique database constraints should not have uniqueness validations defined, + # otherwise #create will fail due to validation errors and #find_by will never be called. # # This method will return a record if all given attributes are covered by unique constraints # (unless the INSERT -> DELETE -> SELECT race condition is triggered), but if creation was attempted # and failed due to validation errors it won't be persisted, you get what #create returns in # such situation. # - # source://activerecord//lib/active_record/relation.rb#209 + # source://activerecord//lib/active_record/relation.rb#266 def create_or_find_by(attributes, &block); end # Like #create_or_find_by, but calls # {create!}[rdoc-ref:Persistence::ClassMethods#create!] so an exception # is raised if the created record is invalid. # - # source://activerecord//lib/active_record/relation.rb#218 + # source://activerecord//lib/active_record/relation.rb#281 def create_or_find_by!(attributes, &block); end + # Deletes the row with a primary key matching the +id+ argument, using an + # SQL +DELETE+ statement, and returns the number of rows deleted. Active + # Record objects are not instantiated, so the object's callbacks are not + # executed, including any :dependent association options. + # + # You can delete multiple rows at once by passing an Array of ids. + # + # Note: Although it is often much faster than the alternative, #destroy, + # skipping callbacks might bypass business logic in your application + # that ensures referential integrity or performs other essential jobs. + # + # ==== Examples + # + # # Delete a single row + # Todo.delete(1) + # + # # Delete multiple rows + # Todo.delete([2,3,4]) + # + # source://activerecord//lib/active_record/relation.rb#1050 + def delete(id_or_array); end + # Deletes the records without instantiating the records # first, and hence not calling the {#destroy}[rdoc-ref:Persistence#destroy] # method nor invoking callbacks. @@ -29253,7 +32452,7 @@ class ActiveRecord::Relation # Post.distinct.delete_all # # => ActiveRecord::ActiveRecordError: delete_all doesn't support distinct # - # source://activerecord//lib/active_record/relation.rb#601 + # source://activerecord//lib/active_record/relation.rb#1004 def delete_all; end # Finds and deletes all records matching the specified conditions. @@ -29266,9 +32465,32 @@ class ActiveRecord::Relation # Person.delete_by(name: 'Spartacus', rating: 4) # Person.delete_by("published_at < ?", 2.weeks.ago) # - # source://activerecord//lib/active_record/relation.rb#642 + # source://activerecord//lib/active_record/relation.rb#1112 def delete_by(*args); end + # Destroy an object (or multiple objects) that has the given id. The object is instantiated first, + # therefore all callbacks and filters are fired off before the object is deleted. This method is + # less efficient than #delete but allows cleanup methods and other actions to be run. + # + # This essentially finds the object (or multiple objects) with the given id, creates a new object + # from the attributes, and then calls destroy on it. + # + # ==== Parameters + # + # * +id+ - This should be the id or an array of ids to be destroyed. + # + # ==== Examples + # + # # Destroy a single object + # Todo.destroy(1) + # + # # Destroy multiple objects + # todos = [1,2,3] + # Todo.destroy(todos) + # + # source://activerecord//lib/active_record/relation.rb#1076 + def destroy(id); end + # Destroys the records by instantiating each # record and calling its {#destroy}[rdoc-ref:Persistence#destroy] method. # Each object's callbacks are executed (including :dependent association options). @@ -29286,7 +32508,7 @@ class ActiveRecord::Relation # # Person.where(age: 0..18).destroy_all # - # source://activerecord//lib/active_record/relation.rb#579 + # source://activerecord//lib/active_record/relation.rb#982 def destroy_all; end # Finds and destroys all records matching the specified conditions. @@ -29299,45 +32521,62 @@ class ActiveRecord::Relation # Person.destroy_by(name: 'Spartacus', rating: 4) # Person.destroy_by("published_at < ?", 2.weeks.ago) # - # source://activerecord//lib/active_record/relation.rb#629 + # source://activerecord//lib/active_record/relation.rb#1099 def destroy_by(*args); end # Returns true if relation needs eager loading. # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#751 + # source://activerecord//lib/active_record/relation.rb#1224 def eager_loading?; end # Returns true if there are no records. # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#269 + # source://activerecord//lib/active_record/relation.rb#355 def empty?; end # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#803 + # source://activerecord//lib/active_record/relation.rb#1281 def empty_scope?; end # Serializes the relation objects Array. # - # source://activerecord//lib/active_record/relation.rb#255 + # source://activerecord//lib/active_record/relation.rb#341 def encode_with(coder); end # Runs EXPLAIN on the query or queries triggered by this relation and # returns the result as a string. The string is formatted imitating the # ones printed by the database shell. # + # User.all.explain + # # EXPLAIN SELECT `users`.* FROM `users` + # # ... + # # Note that this method actually runs the queries, since the results of some # are needed by the next ones when eager loading is going on. # + # To run EXPLAIN on queries created by +first+, +pluck+ and +count+, call + # these methods on +explain+: + # + # User.all.explain.count + # # EXPLAIN SELECT COUNT(*) FROM `users` + # # ... + # + # The column name can be passed if required: + # + # User.all.explain.maximum(:id) + # # EXPLAIN SELECT MAX(`users`.`id`) FROM `users` + # # ... + # # Please see further details in the # {Active Record Query Interface guide}[https://guides.rubyonrails.org/active_record_querying.html#running-explain]. # - # source://activerecord//lib/active_record/relation.rb#239 - def explain; end + # source://activerecord//lib/active_record/relation.rb#325 + def explain(*options); end # Finds the first record with the given attributes, or creates a record # with the attributes if one is not found: @@ -29370,44 +32609,204 @@ class ActiveRecord::Relation # failed due to validation errors it won't be persisted, you get what # #create returns in such situation. # - # Please note this method is not atomic, it runs first a SELECT, and if - # there are no results an INSERT is attempted. If there are other threads - # or processes there is a race condition between both calls and it could - # be the case that you end up with two similar records. + # If creation failed because of a unique constraint, this method will + # assume it encountered a race condition and will try finding the record + # once more. If somehow the second find still does not find a record + # because a concurrent DELETE happened, it will then raise an + # ActiveRecord::RecordNotFound exception. # - # If this might be a problem for your application, please see #create_or_find_by. + # Please note this method is not atomic, it runs first a SELECT, + # and if there are no results an INSERT is attempted. So if the table + # doesn't have a relevant unique constraint it could be the case that + # you end up with two or more similar records. # - # source://activerecord//lib/active_record/relation.rb#168 + # source://activerecord//lib/active_record/relation.rb#224 def find_or_create_by(attributes, &block); end # Like #find_or_create_by, but calls # {create!}[rdoc-ref:Persistence::ClassMethods#create!] so an exception # is raised if the created record is invalid. # - # source://activerecord//lib/active_record/relation.rb#175 + # source://activerecord//lib/active_record/relation.rb#231 def find_or_create_by!(attributes, &block); end # Like #find_or_create_by, but calls {new}[rdoc-ref:Core#new] # instead of {create}[rdoc-ref:Persistence::ClassMethods#create]. # - # source://activerecord//lib/active_record/relation.rb#226 + # source://activerecord//lib/active_record/relation.rb#295 def find_or_initialize_by(attributes, &block); end - # source://activerecord//lib/active_record/relation.rb#119 + # source://activerecord//lib/active_record/relation.rb#171 def first_or_create(attributes = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/relation.rb#123 + # source://activerecord//lib/active_record/relation.rb#175 def first_or_create!(attributes = T.unsafe(nil), &block); end - # source://activerecord//lib/active_record/relation.rb#127 + # source://activerecord//lib/active_record/relation.rb#179 def first_or_initialize(attributes = T.unsafe(nil), &block); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#807 + # source://activerecord//lib/active_record/relation.rb#1285 def has_limit_or_offset?; end - # source://activerecord//lib/active_record/relation.rb#794 + # Inserts a single record into the database in a single SQL INSERT + # statement. It does not instantiate any models nor does it trigger + # Active Record callbacks or validations. Though passed values + # go through Active Record's type casting and serialization. + # + # See #insert_all for documentation. + # + # source://activerecord//lib/active_record/relation.rb#637 + def insert(attributes, returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + + # Inserts a single record into the database in a single SQL INSERT + # statement. It does not instantiate any models nor does it trigger + # Active Record callbacks or validations. Though passed values + # go through Active Record's type casting and serialization. + # + # See #insert_all! for more. + # + # source://activerecord//lib/active_record/relation.rb#726 + def insert!(attributes, returning: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + + # Inserts multiple records into the database in a single SQL INSERT + # statement. It does not instantiate any models nor does it trigger + # Active Record callbacks or validations. Though passed values + # go through Active Record's type casting and serialization. + # + # The +attributes+ parameter is an Array of Hashes. Every Hash determines + # the attributes for a single row and must have the same keys. + # + # Rows are considered to be unique by every unique index on the table. Any + # duplicate rows are skipped. + # Override with :unique_by (see below). + # + # Returns an ActiveRecord::Result with its contents based on + # :returning (see below). + # + # ==== Options + # + # [:returning] + # (PostgreSQL, SQLite3, and MariaDB only) An array of attributes to return for all successfully + # inserted records, which by default is the primary key. + # Pass returning: %w[ id name ] for both id and name + # or returning: false to omit the underlying RETURNING SQL + # clause entirely. + # + # You can also pass an SQL string if you need more control on the return values + # (for example, returning: Arel.sql("id, name as new_name")). + # + # [:unique_by] + # (PostgreSQL and SQLite only) By default rows are considered to be unique + # by every unique index on the table. Any duplicate rows are skipped. + # + # To skip rows according to just one unique index pass :unique_by. + # + # Consider a Book model where no duplicate ISBNs make sense, but if any + # row has an existing id, or is not unique by another unique index, + # ActiveRecord::RecordNotUnique is raised. + # + # Unique indexes can be identified by columns or name: + # + # unique_by: :isbn + # unique_by: %i[ author_id name ] + # unique_by: :index_books_on_isbn + # + # [:record_timestamps] + # By default, automatic setting of timestamp columns is controlled by + # the model's record_timestamps config, matching typical + # behavior. + # + # To override this and force automatic setting of timestamp columns one + # way or the other, pass :record_timestamps: + # + # record_timestamps: true # Always set timestamps automatically + # record_timestamps: false # Never set timestamps automatically + # + # Because it relies on the index information from the database + # :unique_by is recommended to be paired with + # Active Record's schema_cache. + # + # ==== Example + # + # # Insert records and skip inserting any duplicates. + # # Here "Eloquent Ruby" is skipped because its id is not unique. + # + # Book.insert_all([ + # { id: 1, title: "Rework", author: "David" }, + # { id: 1, title: "Eloquent Ruby", author: "Russ" } + # ]) + # + # # insert_all works on chained scopes, and you can use create_with + # # to set default attributes for all inserted records. + # + # author.books.create_with(created_at: Time.now).insert_all([ + # { id: 1, title: "Rework" }, + # { id: 2, title: "Eloquent Ruby" } + # ]) + # + # source://activerecord//lib/active_record/relation.rb#716 + def insert_all(attributes, returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + + # Inserts multiple records into the database in a single SQL INSERT + # statement. It does not instantiate any models nor does it trigger + # Active Record callbacks or validations. Though passed values + # go through Active Record's type casting and serialization. + # + # The +attributes+ parameter is an Array of Hashes. Every Hash determines + # the attributes for a single row and must have the same keys. + # + # Raises ActiveRecord::RecordNotUnique if any rows violate a + # unique index on the table. In that case, no rows are inserted. + # + # To skip duplicate rows, see #insert_all. To replace them, see #upsert_all. + # + # Returns an ActiveRecord::Result with its contents based on + # :returning (see below). + # + # ==== Options + # + # [:returning] + # (PostgreSQL, SQLite3, and MariaDB only) An array of attributes to return for all successfully + # inserted records, which by default is the primary key. + # Pass returning: %w[ id name ] for both id and name + # or returning: false to omit the underlying RETURNING SQL + # clause entirely. + # + # You can also pass an SQL string if you need more control on the return values + # (for example, returning: Arel.sql("id, name as new_name")). + # + # [:record_timestamps] + # By default, automatic setting of timestamp columns is controlled by + # the model's record_timestamps config, matching typical + # behavior. + # + # To override this and force automatic setting of timestamp columns one + # way or the other, pass :record_timestamps: + # + # record_timestamps: true # Always set timestamps automatically + # record_timestamps: false # Never set timestamps automatically + # + # ==== Examples + # + # # Insert multiple records + # Book.insert_all!([ + # { title: "Rework", author: "David" }, + # { title: "Eloquent Ruby", author: "Russ" } + # ]) + # + # # Raises ActiveRecord::RecordNotUnique because "Eloquent Ruby" + # # does not have a unique id. + # Book.insert_all!([ + # { id: 1, title: "Rework", author: "David" }, + # { id: 1, title: "Eloquent Ruby", author: "Russ" } + # ]) + # + # source://activerecord//lib/active_record/relation.rb#783 + def insert_all!(attributes, returning: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/relation.rb#1272 def inspect; end # Joins that are also marked for preloading. In which case we should just eager load them. @@ -29415,12 +32814,12 @@ class ActiveRecord::Relation # represent the same association, but that aren't matched by this. Also, we could have # nested hashes which partially match, e.g. { a: :b } & { a: [:b, :c] } # - # source://activerecord//lib/active_record/relation.rb#761 + # source://activerecord//lib/active_record/relation.rb#1234 def joined_includes_values; end # Returns the value of attribute klass. # - # source://activerecord//lib/active_record/relation.rb#21 + # source://activerecord//lib/active_record/relation.rb#71 def klass; end # Causes the records to be loaded from the database if they have not @@ -29430,7 +32829,7 @@ class ActiveRecord::Relation # # Post.where(published: true).load # => # # - # source://activerecord//lib/active_record/relation.rb#693 + # source://activerecord//lib/active_record/relation.rb#1165 def load(&block); end # Schedule the query to be performed from a background thread pool. @@ -29452,32 +32851,32 @@ class ActiveRecord::Relation # # ASYNC Post Load (0.0ms) (db time 2ms) SELECT "posts".* FROM "posts" LIMIT 100 # - # source://activerecord//lib/active_record/relation.rb#664 + # source://activerecord//lib/active_record/relation.rb#1134 def load_async; end # Returns the value of attribute loaded. # - # source://activerecord//lib/active_record/relation.rb#21 + # source://activerecord//lib/active_record/relation.rb#71 def loaded; end # Returns the value of attribute loaded. # - # source://activerecord//lib/active_record/relation.rb#21 + # source://activerecord//lib/active_record/relation.rb#71 def loaded?; end - # source://activerecord//lib/active_record/relation/query_methods.rb#139 + # source://activerecord//lib/active_record/relation/query_methods.rb#171 def locked?; end # Returns true if there is more than one record. # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#297 + # source://activerecord//lib/active_record/relation.rb#406 def many?; end # Returns the value of attribute klass. # - # source://activerecord//lib/active_record/relation.rb#21 + # source://activerecord//lib/active_record/relation.rb#71 def model; end # Initializes new record from relation while maintaining the current @@ -29493,43 +32892,53 @@ class ActiveRecord::Relation # user = users.new { |user| user.name = 'Oscar' } # user.name # => Oscar # - # source://activerecord//lib/active_record/relation.rb#66 + # source://activerecord//lib/active_record/relation.rb#118 def new(attributes = T.unsafe(nil), &block); end # Returns true if there are no records. # + # When a pattern argument is given, this method checks whether elements in + # the Enumerable match the pattern via the case-equality operator (===). + # + # posts.none?(Comment) # => true or false + # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#278 - def none?; end + # source://activerecord//lib/active_record/relation.rb#371 + def none?(*args); end # Returns true if there is exactly one record. # + # When a pattern argument is given, this method checks whether elements in + # the Enumerable match the pattern via the case-equality operator (===). + # + # posts.one?(Post) # => true or false + # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#290 - def one?; end + # source://activerecord//lib/active_record/relation.rb#397 + def one?(*args); end # Returns the value of attribute predicate_builder. # - # source://activerecord//lib/active_record/relation.rb#21 + # source://activerecord//lib/active_record/relation.rb#71 def predicate_builder; end - # source://activerecord//lib/active_record/relation.rb#825 + # source://activerecord//lib/active_record/relation.rb#1303 def preload_associations(records); end - # source://activerecord//lib/active_record/relation.rb#777 - def pretty_print(q); end + # source://activerecord//lib/active_record/relation.rb#1250 + def pretty_print(pp); end - # source://activerecord//lib/active_record/relation.rb#249 + # source://activerecord//lib/active_record/relation.rb#335 def records; end # Forces reloading of relation. # - # source://activerecord//lib/active_record/relation.rb#703 + # source://activerecord//lib/active_record/relation.rb#1175 def reload; end - # source://activerecord//lib/active_record/relation.rb#708 + # source://activerecord//lib/active_record/relation.rb#1180 def reset; end # Returns true if the relation was scheduled on the background @@ -29537,10 +32946,10 @@ class ActiveRecord::Relation # # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#683 + # source://activerecord//lib/active_record/relation.rb#1155 def scheduled?; end - # source://activerecord//lib/active_record/relation.rb#744 + # source://activerecord//lib/active_record/relation.rb#1217 def scope_for_create; end # Scope all queries to the current scope. @@ -29548,7 +32957,7 @@ class ActiveRecord::Relation # Comment.where(post_id: 1).scoping do # Comment.first # end - # # => SELECT "comments".* FROM "comments" WHERE "comments"."post_id" = 1 ORDER BY "comments"."id" ASC LIMIT 1 + # # SELECT "comments".* FROM "comments" WHERE "comments"."post_id" = 1 ORDER BY "comments"."id" ASC LIMIT 1 # # If all_queries: true is passed, scoping will apply to all queries # for the relation including +update+ and +delete+ on instances. @@ -29558,47 +32967,47 @@ class ActiveRecord::Relation # Please check unscoped if you want to remove all previous scopes (including # the default_scope) during the execution of a block. # - # source://activerecord//lib/active_record/relation.rb#421 + # source://activerecord//lib/active_record/relation.rb#534 def scoping(all_queries: T.unsafe(nil), &block); end # Returns size of the records. # - # source://activerecord//lib/active_record/relation.rb#260 + # source://activerecord//lib/active_record/relation.rb#346 def size; end # Returns the value of attribute skip_preloading_value. # - # source://activerecord//lib/active_record/relation.rb#22 + # source://activerecord//lib/active_record/relation.rb#72 def skip_preloading_value; end # Sets the attribute skip_preloading_value # # @param value the value to set the attribute skip_preloading_value to. # - # source://activerecord//lib/active_record/relation.rb#22 + # source://activerecord//lib/active_record/relation.rb#72 def skip_preloading_value=(_arg0); end # Returns the value of attribute table. # - # source://activerecord//lib/active_record/relation.rb#21 + # source://activerecord//lib/active_record/relation.rb#71 def table; end # Converts relation objects to Array. # - # source://activerecord//lib/active_record/relation.rb#244 + # source://activerecord//lib/active_record/relation.rb#330 def to_a; end # Converts relation objects to Array. # - # source://activerecord//lib/active_record/relation.rb#244 + # source://activerecord//lib/active_record/relation.rb#330 def to_ary; end # Returns sql statement for the relation. # # User.where(name: 'Oscar').to_sql - # # => SELECT "users".* FROM "users" WHERE "users"."name" = 'Oscar' + # # SELECT "users".* FROM "users" WHERE "users"."name" = 'Oscar' # - # source://activerecord//lib/active_record/relation.rb#724 + # source://activerecord//lib/active_record/relation.rb#1196 def to_sql; end # Touches all records in the current relation, setting the +updated_at+/+updated_on+ attributes to the current time or the time specified. @@ -29625,13 +33034,13 @@ class ActiveRecord::Relation # Person.where(name: 'David').touch_all # # => "UPDATE \"people\" SET \"updated_at\" = '2018-01-04 22:55:23.132670' WHERE \"people\".\"name\" = 'David'" # - # source://activerecord//lib/active_record/relation.rb#559 + # source://activerecord//lib/active_record/relation.rb#962 def touch_all(*names, time: T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation.rb#488 + # source://activerecord//lib/active_record/relation.rb#614 def update(id = T.unsafe(nil), attributes); end - # source://activerecord//lib/active_record/relation.rb#496 + # source://activerecord//lib/active_record/relation.rb#622 def update!(id = T.unsafe(nil), attributes); end # Updates all records in the current relation with details given. This method constructs a single SQL UPDATE @@ -29643,7 +33052,8 @@ class ActiveRecord::Relation # # ==== Parameters # - # * +updates+ - A string, array, or hash representing the SET part of an SQL statement. + # * +updates+ - A string, array, or hash representing the SET part of an SQL statement. Any strings provided will + # be type cast, unless you use +Arel.sql+. (Don't pass user-provided values to +Arel.sql+.) # # ==== Examples # @@ -29659,9 +33069,12 @@ class ActiveRecord::Relation # # Update all invoices and set the number column to its id value. # Invoice.update_all('number = id') # + # # Update all books with 'Rails' in their title + # Book.where('title LIKE ?', '%Rails%').update_all(title: Arel.sql("title + ' - volume 1'")) + # # @raise [ArgumentError] # - # source://activerecord//lib/active_record/relation.rb#464 + # source://activerecord//lib/active_record/relation.rb#581 def update_all(updates); end # Updates the counters of the records in the current relation. @@ -29677,13 +33090,133 @@ class ActiveRecord::Relation # # For Posts by a given author increment the comment_count by 1. # Post.where(author_id: author.id).update_counters(comment_count: 1) # - # source://activerecord//lib/active_record/relation.rb#516 + # source://activerecord//lib/active_record/relation.rb#919 def update_counters(counters); end - # source://activerecord//lib/active_record/relation.rb#786 + # Updates or inserts (upserts) a single record into the database in a + # single SQL INSERT statement. It does not instantiate any models nor does + # it trigger Active Record callbacks or validations. Though passed values + # go through Active Record's type casting and serialization. + # + # See #upsert_all for documentation. + # + # source://activerecord//lib/active_record/relation.rb#793 + def upsert(attributes, **kwargs); end + + # Updates or inserts (upserts) multiple records into the database in a + # single SQL INSERT statement. It does not instantiate any models nor does + # it trigger Active Record callbacks or validations. Though passed values + # go through Active Record's type casting and serialization. + # + # The +attributes+ parameter is an Array of Hashes. Every Hash determines + # the attributes for a single row and must have the same keys. + # + # Returns an ActiveRecord::Result with its contents based on + # :returning (see below). + # + # By default, +upsert_all+ will update all the columns that can be updated when + # there is a conflict. These are all the columns except primary keys, read-only + # columns, and columns covered by the optional +unique_by+. + # + # ==== Options + # + # [:returning] + # (PostgreSQL, SQLite3, and MariaDB only) An array of attributes to return for all successfully + # inserted records, which by default is the primary key. + # Pass returning: %w[ id name ] for both id and name + # or returning: false to omit the underlying RETURNING SQL + # clause entirely. + # + # You can also pass an SQL string if you need more control on the return values + # (for example, returning: Arel.sql("id, name as new_name")). + # + # [:unique_by] + # (PostgreSQL and SQLite only) By default rows are considered to be unique + # by every unique index on the table. Any duplicate rows are skipped. + # + # To skip rows according to just one unique index pass :unique_by. + # + # Consider a Book model where no duplicate ISBNs make sense, but if any + # row has an existing id, or is not unique by another unique index, + # ActiveRecord::RecordNotUnique is raised. + # + # Unique indexes can be identified by columns or name: + # + # unique_by: :isbn + # unique_by: %i[ author_id name ] + # unique_by: :index_books_on_isbn + # + # Because it relies on the index information from the database + # :unique_by is recommended to be paired with + # Active Record's schema_cache. + # + # [:on_duplicate] + # Configure the SQL update sentence that will be used in case of conflict. + # + # NOTE: If you use this option you must provide all the columns you want to update + # by yourself. + # + # Example: + # + # Commodity.upsert_all( + # [ + # { id: 2, name: "Copper", price: 4.84 }, + # { id: 4, name: "Gold", price: 1380.87 }, + # { id: 6, name: "Aluminium", price: 0.35 } + # ], + # on_duplicate: Arel.sql("price = GREATEST(commodities.price, EXCLUDED.price)") + # ) + # + # See the related +:update_only+ option. Both options can't be used at the same time. + # + # [:update_only] + # Provide a list of column names that will be updated in case of conflict. If not provided, + # +upsert_all+ will update all the columns that can be updated. These are all the columns + # except primary keys, read-only columns, and columns covered by the optional +unique_by+ + # + # Example: + # + # Commodity.upsert_all( + # [ + # { id: 2, name: "Copper", price: 4.84 }, + # { id: 4, name: "Gold", price: 1380.87 }, + # { id: 6, name: "Aluminium", price: 0.35 } + # ], + # update_only: [:price] # Only prices will be updated + # ) + # + # See the related +:on_duplicate+ option. Both options can't be used at the same time. + # + # [:record_timestamps] + # By default, automatic setting of timestamp columns is controlled by + # the model's record_timestamps config, matching typical + # behavior. + # + # To override this and force automatic setting of timestamp columns one + # way or the other, pass :record_timestamps: + # + # record_timestamps: true # Always set timestamps automatically + # record_timestamps: false # Never set timestamps automatically + # + # ==== Examples + # + # # Inserts multiple records, performing an upsert when records have duplicate ISBNs. + # # Here "Eloquent Ruby" overwrites "Rework" because its ISBN is duplicate. + # + # Book.upsert_all([ + # { title: "Rework", author: "David", isbn: "1" }, + # { title: "Eloquent Ruby", author: "Russ", isbn: "1" } + # ], unique_by: :isbn) + # + # Book.find_by(isbn: "1").title # => "Eloquent Ruby" + # + # source://activerecord//lib/active_record/relation.rb#903 + def upsert_all(attributes, on_duplicate: T.unsafe(nil), update_only: T.unsafe(nil), returning: T.unsafe(nil), unique_by: T.unsafe(nil), record_timestamps: T.unsafe(nil)); end + + # source://activerecord//lib/active_record/relation.rb#1264 def values; end - # source://activerecord//lib/active_record/relation.rb#790 + # source://activerecord//lib/active_record/relation.rb#1268 def values_for_queries; end # Returns a hash of where conditions. @@ -29691,88 +33224,123 @@ class ActiveRecord::Relation # User.where(name: 'Oscar').where_values_hash # # => {name: "Oscar"} # - # source://activerecord//lib/active_record/relation.rb#740 + # source://activerecord//lib/active_record/relation.rb#1213 def where_values_hash(relation_table_name = T.unsafe(nil)); end protected - # source://activerecord//lib/active_record/relation.rb#835 + # source://activerecord//lib/active_record/relation.rb#1313 def load_records(records); end - # @return [Boolean] - # - # source://activerecord//lib/active_record/relation.rb#840 - def null_relation?; end - private - # source://activerecord//lib/active_record/relation.rb#865 + # source://activerecord//lib/active_record/relation.rb#1339 def _create(attributes, &block); end - # source://activerecord//lib/active_record/relation.rb#869 + # source://activerecord//lib/active_record/relation.rb#1343 def _create!(attributes, &block); end - # source://activerecord//lib/active_record/relation.rb#900 + # source://activerecord//lib/active_record/relation.rb#1378 def _increment_attribute(attribute, value = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation.rb#861 + # source://activerecord//lib/active_record/relation.rb#1335 def _new(attributes, &block); end - # source://activerecord//lib/active_record/relation.rb#873 + # source://activerecord//lib/active_record/relation.rb#1347 def _scoping(scope, registry, all_queries = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation.rb#889 + # source://activerecord//lib/active_record/relation.rb#1363 def _substitute_values(values); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#845 + # source://activerecord//lib/active_record/relation.rb#1319 def already_in_scope?(registry); end - # source://activerecord//lib/active_record/relation.rb#325 + # source://activerecord//lib/active_record/relation.rb#436 def compute_cache_key(timestamp_column = T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation.rb#354 + # source://activerecord//lib/active_record/relation.rb#465 def compute_cache_version(timestamp_column); end - # source://activerecord//lib/active_record/relation.rb#853 + # source://activerecord//lib/active_record/relation.rb#1327 def current_scope_restoring_block(&block); end - # source://activerecord//lib/active_record/relation.rb#927 + # source://activerecord//lib/active_record/relation.rb#1405 def exec_main_query(async: T.unsafe(nil)); end - # source://activerecord//lib/active_record/relation.rb#907 + # source://activerecord//lib/active_record/relation.rb#1385 def exec_queries(&block); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#849 + # source://activerecord//lib/active_record/relation.rb#1323 def global_scope?(registry); end - # source://activerecord//lib/active_record/relation.rb#38 + # source://activerecord//lib/active_record/relation.rb#90 def initialize_copy(other); end - # source://activerecord//lib/active_record/relation.rb#947 + # source://activerecord//lib/active_record/relation.rb#1437 def instantiate_records(rows, &block); end - # source://activerecord//lib/active_record/relation.rb#990 + # source://activerecord//lib/active_record/relation.rb#1480 def limited_count; end # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#966 + # source://activerecord//lib/active_record/relation.rb#1456 def references_eager_loaded_tables?; end - # source://activerecord//lib/active_record/relation.rb#958 + # source://activerecord//lib/active_record/relation.rb#1448 def skip_query_cache_if_necessary(&block); end - # source://activerecord//lib/active_record/relation.rb#983 + # source://activerecord//lib/active_record/relation.rb#1473 def tables_in_string(string); end end -# source://activerecord//lib/active_record/relation.rb#13 +# source://activerecord//lib/active_record/relation.rb#62 ActiveRecord::Relation::CLAUSE_METHODS = T.let(T.unsafe(nil), Array) +# source://activerecord//lib/active_record/relation.rb#6 +class ActiveRecord::Relation::ExplainProxy + # @return [ExplainProxy] a new instance of ExplainProxy + # + # source://activerecord//lib/active_record/relation.rb#7 + def initialize(relation, options); end + + # source://activerecord//lib/active_record/relation.rb#16 + def average(column_name); end + + # source://activerecord//lib/active_record/relation.rb#20 + def count(column_name = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/relation.rb#24 + def first(limit = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/relation.rb#12 + def inspect; end + + # source://activerecord//lib/active_record/relation.rb#28 + def last(limit = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/relation.rb#32 + def maximum(column_name); end + + # source://activerecord//lib/active_record/relation.rb#36 + def minimum(column_name); end + + # source://activerecord//lib/active_record/relation.rb#40 + def pluck(*column_names); end + + # source://activerecord//lib/active_record/relation.rb#44 + def sum(identity_or_column = T.unsafe(nil)); end + + private + + # source://activerecord//lib/active_record/relation.rb#49 + def exec_explain(&block); end +end + # source://activerecord//lib/active_record/relation/from_clause.rb#5 class ActiveRecord::Relation::FromClause # @return [FromClause] a new instance of FromClause @@ -29812,14 +33380,14 @@ class ActiveRecord::Relation::HashMerger # @return [HashMerger] a new instance of HashMerger # # source://activerecord//lib/active_record/relation/merger.rb#10 - def initialize(relation, hash, rewhere = T.unsafe(nil)); end + def initialize(relation, hash); end # Returns the value of attribute hash. # # source://activerecord//lib/active_record/relation/merger.rb#8 def hash; end - # source://activerecord//lib/active_record/relation/merger.rb#18 + # source://activerecord//lib/active_record/relation/merger.rb#17 def merge; end # Applying values to a relation has some side effects. E.g. @@ -29827,7 +33395,7 @@ class ActiveRecord::Relation::HashMerger # build a relation to merge in rather than directly merging # the values. # - # source://activerecord//lib/active_record/relation/merger.rb#26 + # source://activerecord//lib/active_record/relation/merger.rb#25 def other; end # Returns the value of attribute relation. @@ -29836,35 +33404,35 @@ class ActiveRecord::Relation::HashMerger def relation; end end -# source://activerecord//lib/active_record/relation.rb#14 +# source://activerecord//lib/active_record/relation.rb#63 ActiveRecord::Relation::INVALID_METHODS_FOR_DELETE_ALL = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/relation.rb#6 +# source://activerecord//lib/active_record/relation.rb#54 ActiveRecord::Relation::MULTI_VALUE_METHODS = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/relation/merger.rb#44 +# source://activerecord//lib/active_record/relation/merger.rb#43 class ActiveRecord::Relation::Merger # @return [Merger] a new instance of Merger # - # source://activerecord//lib/active_record/relation/merger.rb#47 - def initialize(relation, other, rewhere = T.unsafe(nil)); end + # source://activerecord//lib/active_record/relation/merger.rb#46 + def initialize(relation, other); end - # source://activerecord//lib/active_record/relation/merger.rb#60 + # source://activerecord//lib/active_record/relation/merger.rb#58 def merge; end # Returns the value of attribute other. # - # source://activerecord//lib/active_record/relation/merger.rb#45 + # source://activerecord//lib/active_record/relation/merger.rb#44 def other; end # Returns the value of attribute relation. # - # source://activerecord//lib/active_record/relation/merger.rb#45 + # source://activerecord//lib/active_record/relation/merger.rb#44 def relation; end # Returns the value of attribute values. # - # source://activerecord//lib/active_record/relation/merger.rb#45 + # source://activerecord//lib/active_record/relation/merger.rb#44 def values; end private @@ -29896,60 +33464,74 @@ class ActiveRecord::Relation::Merger def replace_from_clause?; end end -# source://activerecord//lib/active_record/relation/merger.rb#54 +# source://activerecord//lib/active_record/relation/merger.rb#52 ActiveRecord::Relation::Merger::NORMAL_VALUES = T.let(T.unsafe(nil), Array) # source://activerecord//lib/active_record/relation/query_attribute.rb#7 class ActiveRecord::Relation::QueryAttribute < ::ActiveModel::Attribute + # @return [QueryAttribute] a new instance of QueryAttribute + # + # source://activerecord//lib/active_record/relation/query_attribute.rb#8 + def initialize(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/relation/query_attribute.rb#53 + def ==(other); end + + # source://activerecord//lib/active_record/relation/query_attribute.rb#53 + def eql?(other); end + + # source://activerecord//lib/active_record/relation/query_attribute.rb#58 + def hash; end + # @return [Boolean] # - # source://activerecord//lib/active_record/relation/query_attribute.rb#27 + # source://activerecord//lib/active_record/relation/query_attribute.rb#42 def infinite?; end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/query_attribute.rb#20 + # source://activerecord//lib/active_record/relation/query_attribute.rb#35 def nil?; end - # source://activerecord//lib/active_record/relation/query_attribute.rb#8 + # source://activerecord//lib/active_record/relation/query_attribute.rb#22 def type_cast(value); end # @return [Boolean] # - # source://activerecord//lib/active_record/relation/query_attribute.rb#31 + # source://activerecord//lib/active_record/relation/query_attribute.rb#46 def unboundable?; end - # source://activerecord//lib/active_record/relation/query_attribute.rb#12 + # source://activerecord//lib/active_record/relation/query_attribute.rb#26 def value_for_database; end - # source://activerecord//lib/active_record/relation/query_attribute.rb#16 + # source://activerecord//lib/active_record/relation/query_attribute.rb#31 def with_cast_value(value); end private # @return [Boolean] # - # source://activerecord//lib/active_record/relation/query_attribute.rb#39 + # source://activerecord//lib/active_record/relation/query_attribute.rb#63 def infinity?(value); end end -# source://activerecord//lib/active_record/relation.rb#10 +# source://activerecord//lib/active_record/relation.rb#59 ActiveRecord::Relation::SINGLE_VALUE_METHODS = T.let(T.unsafe(nil), Array) -# source://activerecord//lib/active_record/relation.rb#815 +# source://activerecord//lib/active_record/relation.rb#1293 class ActiveRecord::Relation::StrictLoadingScope class << self # @return [Boolean] # - # source://activerecord//lib/active_record/relation.rb#816 + # source://activerecord//lib/active_record/relation.rb#1294 def empty_scope?; end - # source://activerecord//lib/active_record/relation.rb#820 + # source://activerecord//lib/active_record/relation.rb#1298 def strict_loading_value; end end end -# source://activerecord//lib/active_record/relation.rb#16 +# source://activerecord//lib/active_record/relation.rb#65 ActiveRecord::Relation::VALUE_METHODS = T.let(T.unsafe(nil), Array) # source://activerecord//lib/active_record/relation/where_clause.rb#7 @@ -29985,7 +33567,7 @@ class ActiveRecord::Relation::WhereClause # source://activerecord//lib/active_record/relation/where_clause.rb#75 def eql?(other); end - # source://activerecord//lib/active_record/relation/where_clause.rb#36 + # source://activerecord//lib/active_record/relation/where_clause.rb#32 def except(*columns); end # source://activerecord//lib/active_record/relation/where_clause.rb#110 @@ -29998,9 +33580,9 @@ class ActiveRecord::Relation::WhereClause def invert; end # source://activerecord//lib/active_record/relation/where_clause.rb#26 - def merge(other, rewhere = T.unsafe(nil)); end + def merge(other); end - # source://activerecord//lib/active_record/relation/where_clause.rb#40 + # source://activerecord//lib/active_record/relation/where_clause.rb#36 def or(other); end # source://activerecord//lib/active_record/relation/where_clause.rb#61 @@ -30029,31 +33611,28 @@ class ActiveRecord::Relation::WhereClause # @return [Boolean] # - # source://activerecord//lib/active_record/relation/where_clause.rb#171 + # source://activerecord//lib/active_record/relation/where_clause.rb#159 def equality_node?(node); end - # source://activerecord//lib/active_record/relation/where_clause.rb#186 + # source://activerecord//lib/active_record/relation/where_clause.rb#174 def except_predicates(columns); end # source://activerecord//lib/active_record/relation/where_clause.rb#136 def extract_attribute(node); end - # source://activerecord//lib/active_record/relation/where_clause.rb#221 + # source://activerecord//lib/active_record/relation/where_clause.rb#209 def extract_node_value(node); end - # source://activerecord//lib/active_record/relation/where_clause.rb#175 + # source://activerecord//lib/active_record/relation/where_clause.rb#163 def invert_predicate(node); end - # source://activerecord//lib/active_record/relation/where_clause.rb#210 + # source://activerecord//lib/active_record/relation/where_clause.rb#198 def non_empty_predicates; end - # source://activerecord//lib/active_record/relation/where_clause.rb#159 - def predicates_unreferenced_by(other); end - - # source://activerecord//lib/active_record/relation/where_clause.rb#199 + # source://activerecord//lib/active_record/relation/where_clause.rb#187 def predicates_with_wrapped_sql_literals; end - # source://activerecord//lib/active_record/relation/where_clause.rb#214 + # source://activerecord//lib/active_record/relation/where_clause.rb#202 def wrap_sql_literal(node); end class << self @@ -30062,14 +33641,16 @@ class ActiveRecord::Relation::WhereClause end end -# source://activerecord//lib/active_record/relation/where_clause.rb#209 +# source://activerecord//lib/active_record/relation/where_clause.rb#197 ActiveRecord::Relation::WhereClause::ARRAY_WITH_EMPTY_STRING = T.let(T.unsafe(nil), Array) +# = Active Record \Result +# # This class encapsulates a result returned from calling # {#exec_query}[rdoc-ref:ConnectionAdapters::DatabaseStatements#exec_query] # on any database connection adapter. For example: # -# result = ActiveRecord::Base.connection.exec_query('SELECT id, title, body FROM posts') +# result = ActiveRecord::Base.lease_connection.exec_query('SELECT id, title, body FROM posts') # result # => # # # # Get the column names of the result: @@ -30095,32 +33676,35 @@ ActiveRecord::Relation::WhereClause::ARRAY_WITH_EMPTY_STRING = T.let(T.unsafe(ni # puts row['title'] + " " + row['body'] # end # -# source://activerecord//lib/active_record/result.rb#34 +# source://activerecord//lib/active_record/result.rb#36 class ActiveRecord::Result include ::Enumerable # @return [Result] a new instance of Result # - # source://activerecord//lib/active_record/result.rb#43 + # source://activerecord//lib/active_record/result.rb#49 def initialize(columns, rows, column_types = T.unsafe(nil)); end - # source://activerecord//lib/active_record/result.rb#87 + # source://activerecord//lib/active_record/result.rb#93 def [](idx); end - # source://activerecord//lib/active_record/result.rb#100 + # source://activerecord//lib/active_record/result.rb#106 def cancel; end - # source://activerecord//lib/active_record/result.rb#104 + # source://activerecord//lib/active_record/result.rb#110 def cast_values(type_overrides = T.unsafe(nil)); end + # source://activerecord//lib/active_record/result.rb#148 + def column_indexes; end + # Returns the value of attribute column_types. # - # source://activerecord//lib/active_record/result.rb#37 + # source://activerecord//lib/active_record/result.rb#39 def column_types; end # Returns the value of attribute columns. # - # source://activerecord//lib/active_record/result.rb#37 + # source://activerecord//lib/active_record/result.rb#39 def columns; end # Calls the given block once for each element in row collection, passing @@ -30128,71 +33712,80 @@ class ActiveRecord::Result # # Returns an +Enumerator+ if no block is given. # - # source://activerecord//lib/active_record/result.rb#67 + # source://activerecord//lib/active_record/result.rb#73 def each(&block); end # Returns true if there are no records, otherwise false. # # @return [Boolean] # - # source://activerecord//lib/active_record/result.rb#76 + # source://activerecord//lib/active_record/result.rb#82 def empty?; end + # source://activerecord//lib/active_record/result.rb#143 + def freeze; end + # Returns true if this result set includes the column named +name+ # # @return [Boolean] # - # source://activerecord//lib/active_record/result.rb#54 + # source://activerecord//lib/active_record/result.rb#60 def includes_column?(name); end # Returns the last record from the rows collection. # - # source://activerecord//lib/active_record/result.rb#92 + # source://activerecord//lib/active_record/result.rb#98 def last(n = T.unsafe(nil)); end # Returns the number of elements in the rows array. # - # source://activerecord//lib/active_record/result.rb#59 + # source://activerecord//lib/active_record/result.rb#65 def length; end - # source://activerecord//lib/active_record/result.rb#96 + # source://activerecord//lib/active_record/result.rb#102 def result; end # Returns the value of attribute rows. # - # source://activerecord//lib/active_record/result.rb#37 + # source://activerecord//lib/active_record/result.rb#39 def rows; end # Returns an array of hashes representing each row record. # - # source://activerecord//lib/active_record/result.rb#81 + # source://activerecord//lib/active_record/result.rb#87 def to_a; end # Returns an array of hashes representing each row record. # - # source://activerecord//lib/active_record/result.rb#81 + # source://activerecord//lib/active_record/result.rb#87 def to_ary; end private - # source://activerecord//lib/active_record/result.rb#138 - def column_type(name, type_overrides = T.unsafe(nil)); end + # source://activerecord//lib/active_record/result.rb#162 + def column_type(name, index, type_overrides); end - # source://activerecord//lib/active_record/result.rb#144 + # source://activerecord//lib/active_record/result.rb#170 def hash_rows; end - # source://activerecord//lib/active_record/result.rb#130 + # source://activerecord//lib/active_record/result.rb#136 def initialize_copy(other); end class << self - # source://activerecord//lib/active_record/result.rb#39 - def empty; end + # source://activerecord//lib/active_record/result.rb#41 + def empty(async: T.unsafe(nil)); end end end -# source://activerecord//lib/active_record/result.rb#50 +# source://activerecord//lib/active_record/result.rb#182 ActiveRecord::Result::EMPTY = T.let(T.unsafe(nil), ActiveRecord::Result) +# source://activerecord//lib/active_record/result.rb#185 +ActiveRecord::Result::EMPTY_ASYNC = T.let(T.unsafe(nil), ActiveRecord::FutureResult::Complete) + +# source://activerecord//lib/active_record/result.rb#179 +ActiveRecord::Result::EMPTY_HASH = T.let(T.unsafe(nil), Hash) + # {ActiveRecord::Base.transaction}[rdoc-ref:Transactions::ClassMethods#transaction] # uses this exception to distinguish a deliberate rollback from other exceptional situations. # Normally, raising an exception will cause the @@ -30222,7 +33815,7 @@ ActiveRecord::Result::EMPTY = T.let(T.unsafe(nil), ActiveRecord::Result) # end # end # -# source://activerecord//lib/active_record/errors.rb#338 +# source://activerecord//lib/active_record/errors.rb#422 class ActiveRecord::Rollback < ::ActiveRecord::ActiveRecordError; end # This is a thread locals registry for Active Record. For example: @@ -30235,6 +33828,36 @@ class ActiveRecord::Rollback < ::ActiveRecord::ActiveRecordError; end module ActiveRecord::RuntimeRegistry extend ::ActiveRecord::RuntimeRegistry + # source://activerecord//lib/active_record/runtime_registry.rb#20 + def async_sql_runtime; end + + # source://activerecord//lib/active_record/runtime_registry.rb#24 + def async_sql_runtime=(runtime); end + + # source://activerecord//lib/active_record/runtime_registry.rb#36 + def cached_queries_count; end + + # source://activerecord//lib/active_record/runtime_registry.rb#40 + def cached_queries_count=(count); end + + # source://activerecord//lib/active_record/runtime_registry.rb#28 + def queries_count; end + + # source://activerecord//lib/active_record/runtime_registry.rb#32 + def queries_count=(count); end + + # source://activerecord//lib/active_record/runtime_registry.rb#44 + def reset; end + + # source://activerecord//lib/active_record/runtime_registry.rb#62 + def reset_cached_queries_count; end + + # source://activerecord//lib/active_record/runtime_registry.rb#56 + def reset_queries_count; end + + # source://activerecord//lib/active_record/runtime_registry.rb#50 + def reset_runtimes; end + # source://activerecord//lib/active_record/runtime_registry.rb#12 def sql_runtime; end @@ -30242,6 +33865,38 @@ module ActiveRecord::RuntimeRegistry def sql_runtime=(runtime); end end +# Raised when a statement produces an SQL warning. +# +# source://activerecord//lib/active_record/errors.rb#292 +class ActiveRecord::SQLWarning < ::ActiveRecord::AdapterError + # @return [SQLWarning] a new instance of SQLWarning + # + # source://activerecord//lib/active_record/errors.rb#296 + def initialize(message = T.unsafe(nil), code = T.unsafe(nil), level = T.unsafe(nil), sql = T.unsafe(nil), connection_pool = T.unsafe(nil)); end + + # Returns the value of attribute code. + # + # source://activerecord//lib/active_record/errors.rb#293 + def code; end + + # Returns the value of attribute level. + # + # source://activerecord//lib/active_record/errors.rb#293 + def level; end + + # Returns the value of attribute sql. + # + # source://activerecord//lib/active_record/errors.rb#294 + def sql; end + + # Sets the attribute sql + # + # @param value the value to set the attribute sql to. + # + # source://activerecord//lib/active_record/errors.rb#294 + def sql=(_arg0); end +end + # source://activerecord//lib/active_record/sanitization.rb#4 module ActiveRecord::Sanitization extend ::ActiveSupport::Concern @@ -30251,11 +33906,11 @@ end # source://activerecord//lib/active_record/sanitization.rb#7 module ActiveRecord::Sanitization::ClassMethods - # source://activerecord//lib/active_record/sanitization.rb#138 + # source://activerecord//lib/active_record/sanitization.rb#182 def disallow_raw_sql!(args, permit: T.unsafe(nil)); end - # Accepts an array or string of SQL conditions and sanitizes - # them into a valid SQL fragment for a WHERE clause. + # Accepts an array of SQL conditions and sanitizes them into a valid + # SQL fragment for a WHERE clause. # # sanitize_sql_for_conditions(["name=? and group_id=?", "foo'bar", 4]) # # => "name='foo''bar' and group_id=4" @@ -30266,14 +33921,27 @@ module ActiveRecord::Sanitization::ClassMethods # sanitize_sql_for_conditions(["name='%s' and group_id='%s'", "foo'bar", 4]) # # => "name='foo''bar' and group_id='4'" # + # This method will NOT sanitize an SQL string since it won't contain + # any conditions in it and will return the string as is. + # # sanitize_sql_for_conditions("name='foo''bar' and group_id='4'") # # => "name='foo''bar' and group_id='4'" # - # source://activerecord//lib/active_record/sanitization.rb#22 + # Note that this sanitization method is not schema-aware, hence won't do any type casting + # and will directly use the database adapter's +quote+ method. + # For MySQL specifically this means that numeric parameters will be quoted as strings + # to prevent query manipulation attacks. + # + # sanitize_sql_for_conditions(["role = ?", 0]) + # # => "role = '0'" + # + # source://activerecord//lib/active_record/sanitization.rb#33 def sanitize_sql(condition); end # Accepts an array of conditions. The array has each value - # sanitized and interpolated into the SQL statement. + # sanitized and interpolated into the SQL statement. If using named bind + # variables in SQL statements where a colon is required verbatim use a + # backslash to escape. # # sanitize_sql_array(["name=? and group_id=?", "foo'bar", 4]) # # => "name='foo''bar' and group_id=4" @@ -30281,14 +33949,25 @@ module ActiveRecord::Sanitization::ClassMethods # sanitize_sql_array(["name=:name and group_id=:group_id", name: "foo'bar", group_id: 4]) # # => "name='foo''bar' and group_id=4" # + # sanitize_sql_array(["TO_TIMESTAMP(:date, 'YYYY/MM/DD HH12\\:MI\\:SS')", date: "foo"]) + # # => "TO_TIMESTAMP('foo', 'YYYY/MM/DD HH12:MI:SS')" + # # sanitize_sql_array(["name='%s' and group_id='%s'", "foo'bar", 4]) # # => "name='foo''bar' and group_id='4'" # - # source://activerecord//lib/active_record/sanitization.rb#125 + # Note that this sanitization method is not schema-aware, hence won't do any type casting + # and will directly use the database adapter's +quote+ method. + # For MySQL specifically this means that numeric parameters will be quoted as strings + # to prevent query manipulation attacks. + # + # sanitize_sql_array(["role = ?", 0]) + # # => "role = '0'" + # + # source://activerecord//lib/active_record/sanitization.rb#163 def sanitize_sql_array(ary); end - # Accepts an array, hash, or string of SQL conditions and sanitizes - # them into a valid SQL fragment for a SET clause. + # Accepts an array or hash of SQL conditions and sanitizes them into + # a valid SQL fragment for a SET clause. # # sanitize_sql_for_assignment(["name=? and group_id=?", nil, 4]) # # => "name=NULL and group_id=4" @@ -30299,14 +33978,25 @@ module ActiveRecord::Sanitization::ClassMethods # Post.sanitize_sql_for_assignment({ name: nil, group_id: 4 }) # # => "`posts`.`name` = NULL, `posts`.`group_id` = 4" # + # This method will NOT sanitize an SQL string since it won't contain + # any conditions in it and will return the string as is. + # # sanitize_sql_for_assignment("name=NULL and group_id='4'") # # => "name=NULL and group_id='4'" # - # source://activerecord//lib/active_record/sanitization.rb#46 + # Note that this sanitization method is not schema-aware, hence won't do any type casting + # and will directly use the database adapter's +quote+ method. + # For MySQL specifically this means that numeric parameters will be quoted as strings + # to prevent query manipulation attacks. + # + # sanitize_sql_for_assignment(["role = ?", 0]) + # # => "role = '0'" + # + # source://activerecord//lib/active_record/sanitization.rb#68 def sanitize_sql_for_assignment(assignments, default_table_name = T.unsafe(nil)); end - # Accepts an array or string of SQL conditions and sanitizes - # them into a valid SQL fragment for a WHERE clause. + # Accepts an array of SQL conditions and sanitizes them into a valid + # SQL fragment for a WHERE clause. # # sanitize_sql_for_conditions(["name=? and group_id=?", "foo'bar", 4]) # # => "name='foo''bar' and group_id=4" @@ -30317,10 +34007,21 @@ module ActiveRecord::Sanitization::ClassMethods # sanitize_sql_for_conditions(["name='%s' and group_id='%s'", "foo'bar", 4]) # # => "name='foo''bar' and group_id='4'" # + # This method will NOT sanitize an SQL string since it won't contain + # any conditions in it and will return the string as is. + # # sanitize_sql_for_conditions("name='foo''bar' and group_id='4'") # # => "name='foo''bar' and group_id='4'" # - # source://activerecord//lib/active_record/sanitization.rb#22 + # Note that this sanitization method is not schema-aware, hence won't do any type casting + # and will directly use the database adapter's +quote+ method. + # For MySQL specifically this means that numeric parameters will be quoted as strings + # to prevent query manipulation attacks. + # + # sanitize_sql_for_conditions(["role = ?", 0]) + # # => "role = '0'" + # + # source://activerecord//lib/active_record/sanitization.rb#33 def sanitize_sql_for_conditions(condition); end # Accepts an array, or string of SQL conditions and sanitizes @@ -30332,7 +34033,7 @@ module ActiveRecord::Sanitization::ClassMethods # sanitize_sql_for_order("id ASC") # # => "id ASC" # - # source://activerecord//lib/active_record/sanitization.rb#62 + # source://activerecord//lib/active_record/sanitization.rb#84 def sanitize_sql_for_order(condition); end # Sanitizes a hash of attribute/value pairs into SQL conditions for a SET clause. @@ -30340,7 +34041,7 @@ module ActiveRecord::Sanitization::ClassMethods # sanitize_sql_hash_for_assignment({ status: nil, group_id: 1 }, "posts") # # => "`posts`.`status` = NULL, `posts`.`group_id` = 1" # - # source://activerecord//lib/active_record/sanitization.rb#85 + # source://activerecord//lib/active_record/sanitization.rb#107 def sanitize_sql_hash_for_assignment(attrs, table); end # Sanitizes a +string+ so that it is safe to use within an SQL @@ -30359,25 +34060,25 @@ module ActiveRecord::Sanitization::ClassMethods # sanitize_sql_like("snake_cased_string", "!") # # => "snake!_cased!_string" # - # source://activerecord//lib/active_record/sanitization.rb#109 + # source://activerecord//lib/active_record/sanitization.rb#131 def sanitize_sql_like(string, escape_character = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/sanitization.rb#187 - def quote_bound_value(value, c = T.unsafe(nil)); end + # source://activerecord//lib/active_record/sanitization.rb#232 + def quote_bound_value(connection, value); end - # source://activerecord//lib/active_record/sanitization.rb#201 + # source://activerecord//lib/active_record/sanitization.rb#246 def raise_if_bind_arity_mismatch(statement, expected, provided); end - # source://activerecord//lib/active_record/sanitization.rb#167 - def replace_bind_variable(value, c = T.unsafe(nil)); end + # source://activerecord//lib/active_record/sanitization.rb#210 + def replace_bind_variable(connection, value); end - # source://activerecord//lib/active_record/sanitization.rb#158 - def replace_bind_variables(statement, values); end + # source://activerecord//lib/active_record/sanitization.rb#202 + def replace_bind_variables(connection, statement, values); end - # source://activerecord//lib/active_record/sanitization.rb#175 - def replace_named_bind_variables(statement, bind_vars); end + # source://activerecord//lib/active_record/sanitization.rb#218 + def replace_named_bind_variables(connection, statement, bind_vars); end end # = Active Record \Schema @@ -30415,7 +34116,7 @@ class ActiveRecord::Schema < ::ActiveRecord::Migration::Current extend ::ActiveRecord::Schema::Definition::ClassMethods class << self - # source://activerecord//lib/active_record/schema.rb#69 + # source://activerecord//lib/active_record/schema.rb#70 def [](version); end end end @@ -30458,146 +34159,182 @@ end class ActiveRecord::SchemaDumper # @return [SchemaDumper] a new instance of SchemaDumper # - # source://activerecord//lib/active_record/schema_dumper.rb#59 + # source://activerecord//lib/active_record/schema_dumper.rb#73 def initialize(connection, options = T.unsafe(nil)); end # :singleton-method: # Specify a custom regular expression matching check constraints which name # should not be dumped to db/schema.rb. # - # source://activerecord//lib/active_record/schema_dumper.rb#30 + # source://activerecord//lib/active_record/schema_dumper.rb#29 def chk_ignore_pattern; end - # source://activerecord//lib/active_record/schema_dumper.rb#30 + # source://activerecord//lib/active_record/schema_dumper.rb#29 def chk_ignore_pattern=(val); end - # source://activerecord//lib/active_record/schema_dumper.rb#47 + # source://activerecord//lib/active_record/schema_dumper.rb#60 def dump(stream); end + # :singleton-method: + # Specify a custom regular expression matching exclusion constraints which name + # should not be dumped to db/schema.rb. + # + # source://activerecord//lib/active_record/schema_dumper.rb#35 + def excl_ignore_pattern; end + + # source://activerecord//lib/active_record/schema_dumper.rb#35 + def excl_ignore_pattern=(val); end + # :singleton-method: # Specify a custom regular expression matching foreign keys which name # should not be dumped to db/schema.rb. # - # source://activerecord//lib/active_record/schema_dumper.rb#24 + # source://activerecord//lib/active_record/schema_dumper.rb#23 def fk_ignore_pattern; end - # source://activerecord//lib/active_record/schema_dumper.rb#24 + # source://activerecord//lib/active_record/schema_dumper.rb#23 def fk_ignore_pattern=(val); end # :singleton-method: # A list of tables which should not be dumped to the schema. - # Acceptable values are strings as well as regexp if ActiveRecord.schema_format == :ruby. - # Only strings are accepted if ActiveRecord.schema_format == :sql. + # Acceptable values are strings and regexps. # - # source://activerecord//lib/active_record/schema_dumper.rb#18 + # source://activerecord//lib/active_record/schema_dumper.rb#17 def ignore_tables; end - # source://activerecord//lib/active_record/schema_dumper.rb#18 + # source://activerecord//lib/active_record/schema_dumper.rb#17 def ignore_tables=(val); end + # :singleton-method: + # Specify a custom regular expression matching unique constraints which name + # should not be dumped to db/schema.rb. + # + # source://activerecord//lib/active_record/schema_dumper.rb#41 + def unique_ignore_pattern; end + + # source://activerecord//lib/active_record/schema_dumper.rb#41 + def unique_ignore_pattern=(val); end + private - # source://activerecord//lib/active_record/schema_dumper.rb#227 + # source://activerecord//lib/active_record/schema_dumper.rb#273 def check_constraints_in_create(table, stream); end - # source://activerecord//lib/active_record/schema_dumper.rb#72 + # source://activerecord//lib/active_record/schema_dumper.rb#91 def define_params; end # extensions are only supported by PostgreSQL # - # source://activerecord//lib/active_record/schema_dumper.rb#99 + # source://activerecord//lib/active_record/schema_dumper.rb#118 def extensions(stream); end - # source://activerecord//lib/active_record/schema_dumper.rb#245 + # source://activerecord//lib/active_record/schema_dumper.rb#293 def foreign_keys(table, stream); end - # source://activerecord//lib/active_record/schema_dumper.rb#276 + # source://activerecord//lib/active_record/schema_dumper.rb#325 def format_colspec(colspec); end - # source://activerecord//lib/active_record/schema_dumper.rb#286 + # source://activerecord//lib/active_record/schema_dumper.rb#335 def format_index_parts(options); end - # source://activerecord//lib/active_record/schema_dumper.rb#282 + # source://activerecord//lib/active_record/schema_dumper.rb#331 def format_options(options); end # turns 20170404131909 into "2017_04_04_131909" # - # source://activerecord//lib/active_record/schema_dumper.rb#66 + # source://activerecord//lib/active_record/schema_dumper.rb#85 def formatted_version; end - # source://activerecord//lib/active_record/schema_dumper.rb#76 + # source://activerecord//lib/active_record/schema_dumper.rb#95 def header(stream); end # @return [Boolean] # - # source://activerecord//lib/active_record/schema_dumper.rb#304 + # source://activerecord//lib/active_record/schema_dumper.rb#353 def ignored?(table_name); end - # source://activerecord//lib/active_record/schema_dumper.rb#211 + # source://activerecord//lib/active_record/schema_dumper.rb#255 def index_parts(index); end # Keep it for indexing materialized views # - # source://activerecord//lib/active_record/schema_dumper.rb#190 + # source://activerecord//lib/active_record/schema_dumper.rb#222 def indexes(table, stream); end - # source://activerecord//lib/active_record/schema_dumper.rb#202 + # source://activerecord//lib/active_record/schema_dumper.rb#234 def indexes_in_create(table, stream); end - # source://activerecord//lib/active_record/schema_dumper.rb#294 + # source://activerecord//lib/active_record/schema_dumper.rb#343 def remove_prefix_and_suffix(table); end - # source://activerecord//lib/active_record/schema_dumper.rb#121 + # schemas are only supported by PostgreSQL + # + # source://activerecord//lib/active_record/schema_dumper.rb#126 + def schemas(stream); end + + # source://activerecord//lib/active_record/schema_dumper.rb#153 def table(table, stream); end # Returns the value of attribute table_name. # - # source://activerecord//lib/active_record/schema_dumper.rb#57 + # source://activerecord//lib/active_record/schema_dumper.rb#71 def table_name; end # Sets the attribute table_name # # @param value the value to set the attribute table_name to. # - # source://activerecord//lib/active_record/schema_dumper.rb#57 + # source://activerecord//lib/active_record/schema_dumper.rb#71 def table_name=(_arg0); end - # source://activerecord//lib/active_record/schema_dumper.rb#106 + # source://activerecord//lib/active_record/schema_dumper.rb#129 def tables(stream); end - # source://activerecord//lib/active_record/schema_dumper.rb#94 + # source://activerecord//lib/active_record/schema_dumper.rb#113 def trailer(stream); end # (enum) types are only supported by PostgreSQL # - # source://activerecord//lib/active_record/schema_dumper.rb#103 + # source://activerecord//lib/active_record/schema_dumper.rb#122 def types(stream); end class << self - # source://activerecord//lib/active_record/schema_dumper.rb#30 + # source://activerecord//lib/active_record/schema_dumper.rb#29 def chk_ignore_pattern; end - # source://activerecord//lib/active_record/schema_dumper.rb#30 + # source://activerecord//lib/active_record/schema_dumper.rb#29 def chk_ignore_pattern=(val); end - # source://activerecord//lib/active_record/schema_dumper.rb#33 - def dump(connection = T.unsafe(nil), stream = T.unsafe(nil), config = T.unsafe(nil)); end + # source://activerecord//lib/active_record/schema_dumper.rb#44 + def dump(pool = T.unsafe(nil), stream = T.unsafe(nil), config = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/schema_dumper.rb#35 + def excl_ignore_pattern; end - # source://activerecord//lib/active_record/schema_dumper.rb#24 + # source://activerecord//lib/active_record/schema_dumper.rb#35 + def excl_ignore_pattern=(val); end + + # source://activerecord//lib/active_record/schema_dumper.rb#23 def fk_ignore_pattern; end - # source://activerecord//lib/active_record/schema_dumper.rb#24 + # source://activerecord//lib/active_record/schema_dumper.rb#23 def fk_ignore_pattern=(val); end - # source://activerecord//lib/active_record/schema_dumper.rb#18 + # source://activerecord//lib/active_record/schema_dumper.rb#17 def ignore_tables; end - # source://activerecord//lib/active_record/schema_dumper.rb#18 + # source://activerecord//lib/active_record/schema_dumper.rb#17 def ignore_tables=(val); end + # source://activerecord//lib/active_record/schema_dumper.rb#41 + def unique_ignore_pattern; end + + # source://activerecord//lib/active_record/schema_dumper.rb#41 + def unique_ignore_pattern=(val); end + private - # source://activerecord//lib/active_record/schema_dumper.rb#39 + # source://activerecord//lib/active_record/schema_dumper.rb#52 def generate_options(config); end def new(*_arg0); end @@ -30606,88 +34343,65 @@ end # This class is used to create a table that keeps track of which migrations # have been applied to a given database. When a migration is run, its schema -# number is inserted in to the `SchemaMigration.table_name` so it doesn't need +# number is inserted in to the schema migrations table so it doesn't need # to be executed the next time. # -# source://activerecord//lib/active_record/schema_migration.rb#11 -class ActiveRecord::SchemaMigration < ::ActiveRecord::Base - include ::ActiveRecord::SchemaMigration::GeneratedAttributeMethods - include ::ActiveRecord::SchemaMigration::GeneratedAssociationMethods - - # source://activerecord//lib/active_record/schema_migration.rb#50 - def version; end +# source://activerecord//lib/active_record/schema_migration.rb#8 +class ActiveRecord::SchemaMigration + # @return [SchemaMigration] a new instance of SchemaMigration + # + # source://activerecord//lib/active_record/schema_migration.rb#14 + def initialize(pool); end - class << self - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end + # Returns the value of attribute arel_table. + # + # source://activerecord//lib/active_record/schema_migration.rb#12 + def arel_table; end - # source://activerecord//lib/active_record/schema_migration.rb#41 - def all_versions; end + # source://activerecord//lib/active_record/schema_migration.rb#90 + def count; end - # source://activerecord//lib/active_record/schema_migration.rb#21 - def create_table; end + # source://activerecord//lib/active_record/schema_migration.rb#52 + def create_table; end - # source://activerecord//lib/active_record/enum.rb#116 - def defined_enums; end + # source://activerecord//lib/active_record/schema_migration.rb#19 + def create_version(version); end - # source://activerecord//lib/active_record/schema_migration.rb#29 - def drop_table; end + # source://activerecord//lib/active_record/schema_migration.rb#36 + def delete_all_versions; end - # source://activerecord//lib/active_record/schema_migration.rb#33 - def normalize_migration_number(number); end + # source://activerecord//lib/active_record/schema_migration.rb#27 + def delete_version(version); end - # source://activerecord//lib/active_record/schema_migration.rb#37 - def normalized_versions; end + # source://activerecord//lib/active_record/schema_migration.rb#62 + def drop_table; end - # source://activerecord//lib/active_record/schema_migration.rb#13 - def primary_key; end + # source://activerecord//lib/active_record/schema_migration.rb#86 + def integer_versions; end - # @return [Boolean] - # - # source://activerecord//lib/active_record/schema_migration.rb#45 - def table_exists?; end + # source://activerecord//lib/active_record/schema_migration.rb#68 + def normalize_migration_number(number); end - # source://activerecord//lib/active_record/schema_migration.rb#17 - def table_name; end - end -end + # source://activerecord//lib/active_record/schema_migration.rb#72 + def normalized_versions; end -# source://activerecord//lib/active_record/schema_migration.rb#0 -class ActiveRecord::SchemaMigration::ActiveRecord_AssociationRelation < ::ActiveRecord::AssociationRelation - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::SchemaMigration::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods -end + # source://activerecord//lib/active_record/schema_migration.rb#44 + def primary_key; end -# source://activerecord//lib/active_record/schema_migration.rb#0 -class ActiveRecord::SchemaMigration::ActiveRecord_Associations_CollectionProxy < ::ActiveRecord::Associations::CollectionProxy - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::SchemaMigration::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods -end + # @return [Boolean] + # + # source://activerecord//lib/active_record/schema_migration.rb#99 + def table_exists?; end -# source://activerecord//lib/active_record/schema_migration.rb#0 -class ActiveRecord::SchemaMigration::ActiveRecord_DisableJoinsAssociationRelation < ::ActiveRecord::DisableJoinsAssociationRelation - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::SchemaMigration::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods -end + # source://activerecord//lib/active_record/schema_migration.rb#48 + def table_name; end -# source://activerecord//lib/active_record/schema_migration.rb#0 -class ActiveRecord::SchemaMigration::ActiveRecord_Relation < ::ActiveRecord::Relation - include ::ActiveRecord::Delegation::ClassSpecificRelation - include ::ActiveRecord::SchemaMigration::GeneratedRelationMethods - extend ::ActiveRecord::Delegation::ClassSpecificRelation::ClassMethods + # source://activerecord//lib/active_record/schema_migration.rb#76 + def versions; end end -# source://activerecord//lib/active_record/schema_migration.rb#0 -module ActiveRecord::SchemaMigration::GeneratedAssociationMethods; end - -# source://activerecord//lib/active_record/schema_migration.rb#0 -module ActiveRecord::SchemaMigration::GeneratedAttributeMethods; end - -# source://activerecord//lib/active_record/schema_migration.rb#0 -module ActiveRecord::SchemaMigration::GeneratedRelationMethods; end +# source://activerecord//lib/active_record/schema_migration.rb#9 +class ActiveRecord::SchemaMigration::NullSchemaMigration; end # = Active Record \Named \Scopes # @@ -30783,27 +34497,35 @@ module ActiveRecord::Scoping::Default::ClassMethods # # @return [Boolean] # - # source://activerecord//lib/active_record/scoping/default.rb#54 + # source://activerecord//lib/active_record/scoping/default.rb#62 def default_scopes?(all_queries: T.unsafe(nil)); end # Are there attributes associated with this scope? # # @return [Boolean] # - # source://activerecord//lib/active_record/scoping/default.rb#47 + # source://activerecord//lib/active_record/scoping/default.rb#55 def scope_attributes?; end # Returns a scope for the model without the previously set scopes. # # class Post < ActiveRecord::Base + # belongs_to :user + # # def self.default_scope # where(published: true) # end # end # + # class User < ActiveRecord::Base + # has_many :posts + # end + # # Post.all # Fires "SELECT * FROM posts WHERE published = true" # Post.unscoped.all # Fires "SELECT * FROM posts" # Post.where(published: false).unscoped.all # Fires "SELECT * FROM posts" + # User.find(1).posts # Fires "SELECT * FROM posts WHERE published = true AND posts.user_id = 1" + # User.find(1).posts.unscoped # Fires "SELECT * FROM posts" # # This method also accepts a block. All queries inside the block will # not use the previously set scopes. @@ -30812,12 +34534,12 @@ module ActiveRecord::Scoping::Default::ClassMethods # Post.limit(10) # Fires "SELECT * FROM posts LIMIT 10" # } # - # source://activerecord//lib/active_record/scoping/default.rb#42 + # source://activerecord//lib/active_record/scoping/default.rb#50 def unscoped(&block); end private - # source://activerecord//lib/active_record/scoping/default.rb#135 + # source://activerecord//lib/active_record/scoping/default.rb#145 def build_default_scope(relation = T.unsafe(nil), all_queries: T.unsafe(nil)); end # Use this macro in your model to set a default scope for all operations on @@ -30827,7 +34549,8 @@ module ActiveRecord::Scoping::Default::ClassMethods # default_scope { where(published: true) } # end # - # Article.all # => SELECT * FROM articles WHERE published = true + # Article.all + # # SELECT * FROM articles WHERE published = true # # The #default_scope is also applied while creating/building a record. # It is not applied while updating or deleting a record. @@ -30848,7 +34571,7 @@ module ActiveRecord::Scoping::Default::ClassMethods # queries that return a single object by primary key. # # Article.find(1).destroy - # => DELETE ... FROM `articles` where ID = 1 AND blog_id = 1; + # # DELETE ... FROM `articles` where ID = 1 AND blog_id = 1; # # (You can also pass any object which responds to +call+ to the # +default_scope+ macro, and it will be called when building the @@ -30862,7 +34585,8 @@ module ActiveRecord::Scoping::Default::ClassMethods # default_scope { where(rating: 'G') } # end # - # Article.all # => SELECT * FROM articles WHERE published = true AND rating = 'G' + # Article.all + # # SELECT * FROM articles WHERE published = true AND rating = 'G' # # This is also the case with inheritance and module includes where the # parent or module defines a #default_scope and the child or including @@ -30877,33 +34601,33 @@ module ActiveRecord::Scoping::Default::ClassMethods # end # end # - # source://activerecord//lib/active_record/scoping/default.rb#119 + # source://activerecord//lib/active_record/scoping/default.rb#129 def default_scope(scope = T.unsafe(nil), all_queries: T.unsafe(nil), &block); end # The ignore_default_scope flag is used to prevent an infinite recursion # situation where a default scope references a scope which has a default # scope which references a scope... # - # source://activerecord//lib/active_record/scoping/default.rb#182 + # source://activerecord//lib/active_record/scoping/default.rb#192 def evaluate_default_scope; end # If all_queries is nil, only execute on select and insert queries. # # If all_queries is true, check if the default_scope object has - # all_queries set, then execute on all queries; select, insert, update - # and delete. + # all_queries set, then execute on all queries; select, insert, update, + # delete, and reload. # # @return [Boolean] # - # source://activerecord//lib/active_record/scoping/default.rb#167 + # source://activerecord//lib/active_record/scoping/default.rb#177 def execute_scope?(all_queries, default_scope_obj); end - # source://activerecord//lib/active_record/scoping/default.rb#175 + # source://activerecord//lib/active_record/scoping/default.rb#185 def ignore_default_scope=(ignore); end # @return [Boolean] # - # source://activerecord//lib/active_record/scoping/default.rb#171 + # source://activerecord//lib/active_record/scoping/default.rb#181 def ignore_default_scope?; end end @@ -30948,7 +34672,7 @@ module ActiveRecord::Scoping::Named::ClassMethods # {default_scope}[rdoc-ref:Scoping::Default::ClassMethods#default_scope]. # # source://activerecord//lib/active_record/scoping/named.rb#22 - def all; end + def all(all_queries: T.unsafe(nil)); end # source://activerecord//lib/active_record/scoping/named.rb#49 def default_extensions; end @@ -31115,7 +34839,7 @@ class ActiveRecord::Scoping::ScopeRegistry # Sets the +value+ for a given +scope_type+ and +model+. # - # source://activerecord//lib/active_record/scoping.rb#130 + # source://activerecord//lib/active_record/scoping.rb#131 def set_value_for(scope_type, model, value); end # Obtains the value for a given +scope_type+ and +model+. @@ -31147,6 +34871,55 @@ class ActiveRecord::Scoping::ScopeRegistry end end +# source://activerecord//lib/active_record/secure_password.rb#4 +module ActiveRecord::SecurePassword + extend ::ActiveSupport::Concern + include ::ActiveModel::SecurePassword + + mixes_in_class_methods ::ActiveModel::SecurePassword::ClassMethods + mixes_in_class_methods ::ActiveRecord::SecurePassword::ClassMethods +end + +# source://activerecord//lib/active_record/secure_password.rb#9 +module ActiveRecord::SecurePassword::ClassMethods + # Given a set of attributes, finds a record using the non-password + # attributes, and then authenticates that record using the password + # attributes. Returns the record if authentication succeeds; otherwise, + # returns +nil+. + # + # Regardless of whether a record is found, +authenticate_by+ will + # cryptographically digest the given password attributes. This behavior + # helps mitigate timing-based enumeration attacks, wherein an attacker can + # determine if a passworded record exists even without knowing the + # password. + # + # Raises an ArgumentError if the set of attributes doesn't contain at + # least one password and one non-password attribute. + # + # ==== Examples + # + # class User < ActiveRecord::Base + # has_secure_password + # end + # + # User.create(name: "John Doe", email: "jdoe@example.com", password: "abc123") + # + # User.authenticate_by(email: "jdoe@example.com", password: "abc123").name # => "John Doe" (in 373.4ms) + # User.authenticate_by(email: "jdoe@example.com", password: "wrong") # => nil (in 373.9ms) + # User.authenticate_by(email: "wrong@example.com", password: "abc123") # => nil (in 373.6ms) + # + # User.authenticate_by(email: "jdoe@example.com", password: nil) # => nil (no queries executed) + # User.authenticate_by(email: "jdoe@example.com", password: "") # => nil (no queries executed) + # + # User.authenticate_by(email: "jdoe@example.com") # => ArgumentError + # User.authenticate_by(password: "abc123") # => ArgumentError + # + # @raise [ArgumentError] + # + # source://activerecord//lib/active_record/secure_password.rb#41 + def authenticate_by(attributes); end +end + # source://activerecord//lib/active_record/secure_token.rb#4 module ActiveRecord::SecureToken extend ::ActiveSupport::Concern @@ -31156,7 +34929,7 @@ end # source://activerecord//lib/active_record/secure_token.rb#11 module ActiveRecord::SecureToken::ClassMethods - # source://activerecord//lib/active_record/secure_token.rb#43 + # source://activerecord//lib/active_record/secure_token.rb#61 def generate_unique_secure_token(length: T.unsafe(nil)); end # Example using #has_secure_token @@ -31174,14 +34947,28 @@ module ActiveRecord::SecureToken::ClassMethods # user.regenerate_token # => true # user.regenerate_auth_token # => true # - # SecureRandom::base58 is used to generate at minimum a 24-character unique token, so collisions are highly unlikely. + # +SecureRandom::base58+ is used to generate at minimum a 24-character unique token, so collisions are highly unlikely. # # Note that it's still possible to generate a race condition in the database in the same way that # {validates_uniqueness_of}[rdoc-ref:Validations::ClassMethods#validates_uniqueness_of] can. # You're encouraged to add a unique index in the database to deal with this even more unlikely scenario. # - # source://activerecord//lib/active_record/secure_token.rb#32 - def has_secure_token(attribute = T.unsafe(nil), length: T.unsafe(nil)); end + # === Options + # + # [:length] + # Length of the Secure Random, with a minimum of 24 characters. It will + # default to 24. + # + # [:on] + # The callback when the value is generated. When called with on: + # :initialize, the value is generated in an + # after_initialize callback, otherwise the value will be used + # in a before_ callback. When not specified, +:on+ will use the value of + # config.active_record.generate_secure_token_on, which defaults to +:initialize+ + # starting in \Rails 7.1. + # + # source://activerecord//lib/active_record/secure_token.rb#46 + def has_secure_token(attribute = T.unsafe(nil), length: T.unsafe(nil), on: T.unsafe(nil)); end end # source://activerecord//lib/active_record/secure_token.rb#7 @@ -31224,7 +35011,10 @@ end # SerializationFailure will be raised when a transaction is rolled # back by the database due to a serialization failure. # -# source://activerecord//lib/active_record/errors.rb#431 +# This is a subclass of TransactionRollbackError, please make sure to check +# its documentation to be aware of its caveats. +# +# source://activerecord//lib/active_record/errors.rb#536 class ActiveRecord::SerializationFailure < ::ActiveRecord::TransactionRollbackError; end # Raised when unserialized object's type mismatches one specified for serializable field. @@ -31243,7 +35033,16 @@ module ActiveRecord::SignedId mixes_in_class_methods ::ActiveRecord::SignedId::ClassMethods # Returns a signed id that's generated using a preconfigured +ActiveSupport::MessageVerifier+ instance. + # # This signed id is tamper proof, so it's safe to send in an email or otherwise share with the outside world. + # However, as with any message signed with a +ActiveSupport::MessageVerifier+, + # {the signed id is not encrypted}[link:classes/ActiveSupport/MessageVerifier.html#class-ActiveSupport::MessageVerifier-label-Signing+is+not+encryption]. + # It's just encoded and protected against tampering. + # + # This means that the ID can be decoded by anyone; however, if tampered with (so to point to a different ID), + # the cryptographic signature will no longer match, and the signed id will be considered invalid and return nil + # when passed to +find_signed+ (or raise with +find_signed!+). + # # It can furthermore be set to expire (the default is not to expire), and scoped down with a specific purpose. # If the expiration date has been exceeded before +find_signed+ is called, the id won't find the designated # record. If a purpose is set, this too must match. @@ -31257,8 +35056,10 @@ module ActiveRecord::SignedId # And you then change your +find_signed+ calls to require this new purpose. Any old signed ids that were not # created with the purpose will no longer find the record. # - # source://activerecord//lib/active_record/signed_id.rb#112 - def signed_id(expires_in: T.unsafe(nil), purpose: T.unsafe(nil)); end + # @raise [ArgumentError] + # + # source://activerecord//lib/active_record/signed_id.rb#131 + def signed_id(expires_in: T.unsafe(nil), expires_at: T.unsafe(nil), purpose: T.unsafe(nil)); end module GeneratedClassMethods def signed_id_verifier_secret; end @@ -31272,9 +35073,9 @@ module ActiveRecord::SignedId end end -# source://activerecord//lib/active_record/signed_id.rb#16 +# source://activerecord//lib/active_record/signed_id.rb#26 module ActiveRecord::SignedId::ClassMethods - # source://activerecord//lib/active_record/signed_id.rb#92 + # source://activerecord//lib/active_record/signed_id.rb#102 def combine_signed_id_purposes(purpose); end # Lets you find a record based on a signed id that's safe to put into the world without risk of tampering. @@ -31305,7 +35106,7 @@ module ActiveRecord::SignedId::ClassMethods # # @raise [UnknownPrimaryKey] # - # source://activerecord//lib/active_record/signed_id.rb#42 + # source://activerecord//lib/active_record/signed_id.rb#52 def find_signed(signed_id, purpose: T.unsafe(nil)); end # Works like find_signed, but will raise an +ActiveSupport::MessageVerifier::InvalidSignature+ @@ -31321,36 +35122,45 @@ module ActiveRecord::SignedId::ClassMethods # User.first.destroy # User.find_signed! signed_id # => ActiveRecord::RecordNotFound # - # source://activerecord//lib/active_record/signed_id.rb#62 + # source://activerecord//lib/active_record/signed_id.rb#72 def find_signed!(signed_id, purpose: T.unsafe(nil)); end # The verifier instance that all signed ids are generated and verified from. By default, it'll be initialized - # with the class-level +signed_id_verifier_secret+, which within Rails comes from the + # with the class-level +signed_id_verifier_secret+, which within \Rails comes from the # Rails.application.key_generator. By default, it's SHA256 for the digest and JSON for the serialization. # - # source://activerecord//lib/active_record/signed_id.rb#71 + # source://activerecord//lib/active_record/signed_id.rb#81 def signed_id_verifier; end # Allows you to pass in a custom verifier used for the signed ids. This also allows you to use different # verifiers for different classes. This is also helpful if you need to rotate keys, as you can prepare # your custom verifier for that in advance. See +ActiveSupport::MessageVerifier+ for details. # - # source://activerecord//lib/active_record/signed_id.rb#87 + # source://activerecord//lib/active_record/signed_id.rb#97 def signed_id_verifier=(verifier); end end +# source://activerecord//lib/active_record/signed_id.rb#16 +module ActiveRecord::SignedId::RelationMethods + # source://activerecord//lib/active_record/signed_id.rb#17 + def find_signed(*_arg0, **_arg1, &_arg2); end + + # source://activerecord//lib/active_record/signed_id.rb#21 + def find_signed!(*_arg0, **_arg1, &_arg2); end +end + # Raised when Active Record finds multiple records but only expected one. # -# source://activerecord//lib/active_record/errors.rb#146 +# source://activerecord//lib/active_record/errors.rb#179 class ActiveRecord::SoleRecordExceeded < ::ActiveRecord::ActiveRecordError # @return [SoleRecordExceeded] a new instance of SoleRecordExceeded # - # source://activerecord//lib/active_record/errors.rb#149 + # source://activerecord//lib/active_record/errors.rb#182 def initialize(record = T.unsafe(nil)); end # Returns the value of attribute record. # - # source://activerecord//lib/active_record/errors.rb#147 + # source://activerecord//lib/active_record/errors.rb#180 def record; end end @@ -31361,7 +35171,7 @@ module ActiveRecord::SpawnMethods # Post.order('id asc').except(:order) # discards the order condition # Post.where('id > 10').order('id asc').except(:where) # discards the where condition but keeps the order # - # source://activerecord//lib/active_record/relation/spawn_methods.rb#58 + # source://activerecord//lib/active_record/relation/spawn_methods.rb#59 def except(*skips); end # Merges in the conditions from other, if other is an ActiveRecord::Relation. @@ -31382,10 +35192,13 @@ module ActiveRecord::SpawnMethods # # This is mainly intended for sharing common conditions between multiple associations. # - # source://activerecord//lib/active_record/relation/spawn_methods.rb#31 + # For conditions that exist in both relations, those from other will take precedence. + # To find the intersection of two relations, use QueryMethods#and. + # + # source://activerecord//lib/active_record/relation/spawn_methods.rb#33 def merge(other, *rest); end - # source://activerecord//lib/active_record/relation/spawn_methods.rb#41 + # source://activerecord//lib/active_record/relation/spawn_methods.rb#43 def merge!(other, *rest); end # Removes any condition from the query other than the one(s) specified in +onlies+. @@ -31393,17 +35206,15 @@ module ActiveRecord::SpawnMethods # Post.order('id asc').only(:where) # discards the order condition # Post.order('id asc').only(:where, :order) # uses the specified order # - # source://activerecord//lib/active_record/relation/spawn_methods.rb#66 + # source://activerecord//lib/active_record/relation/spawn_methods.rb#67 def only(*onlies); end - # This is overridden by Associations::CollectionProxy - # - # source://activerecord//lib/active_record/relation/spawn_methods.rb#10 + # source://activerecord//lib/active_record/relation/spawn_methods.rb#9 def spawn; end private - # source://activerecord//lib/active_record/relation/spawn_methods.rb#71 + # source://activerecord//lib/active_record/relation/spawn_methods.rb#72 def relation_with(values); end end @@ -31414,35 +35225,35 @@ end # Read more about optimistic locking in ActiveRecord::Locking module # documentation. # -# source://activerecord//lib/active_record/errors.rb#280 +# source://activerecord//lib/active_record/errors.rb#358 class ActiveRecord::StaleObjectError < ::ActiveRecord::ActiveRecordError # @return [StaleObjectError] a new instance of StaleObjectError # - # source://activerecord//lib/active_record/errors.rb#283 + # source://activerecord//lib/active_record/errors.rb#361 def initialize(record = T.unsafe(nil), attempted_action = T.unsafe(nil)); end # Returns the value of attribute attempted_action. # - # source://activerecord//lib/active_record/errors.rb#281 + # source://activerecord//lib/active_record/errors.rb#359 def attempted_action; end # Returns the value of attribute record. # - # source://activerecord//lib/active_record/errors.rb#281 + # source://activerecord//lib/active_record/errors.rb#359 def record; end end # Statement cache is used to cache a single statement in order to avoid creating the AST again. # Initializing the cache is done by passing the statement in the create block: # -# cache = StatementCache.create(Book.connection) do |params| +# cache = StatementCache.create(ClothingItem.lease_connection) do |params| # Book.where(name: "my book").where("author_id > 3") # end # # The cached statement is executed by using the # {connection.execute}[rdoc-ref:ConnectionAdapters::DatabaseStatements#execute] method: # -# cache.execute([], Book.connection) +# cache.execute([], ClothingItem.lease_connection) # # The relation returned by the block is cached, and for each # {execute}[rdoc-ref:ConnectionAdapters::DatabaseStatements#execute] @@ -31451,13 +35262,13 @@ end # If you want to cache the statement without the values you can use the +bind+ method of the # block parameter. # -# cache = StatementCache.create(Book.connection) do |params| +# cache = StatementCache.create(ClothingItem.lease_connection) do |params| # Book.where(name: params.bind) # end # # And pass the bind values as the first argument of +execute+ call. # -# cache.execute(["my book"], Book.connection) +# cache.execute(["my book"], ClothingItem.lease_connection) # # source://activerecord//lib/active_record/statement_cache.rb#30 class ActiveRecord::StatementCache @@ -31467,7 +35278,7 @@ class ActiveRecord::StatementCache def initialize(query_builder, bind_map, klass); end # source://activerecord//lib/active_record/statement_cache.rb#145 - def execute(params, connection, &block); end + def execute(params, connection, allow_retry: T.unsafe(nil), &block); end private @@ -31562,6 +35373,18 @@ class ActiveRecord::StatementCache::PartialQueryCollector # source://activerecord//lib/active_record/statement_cache.rb#65 def preparable=(_arg0); end + # Returns the value of attribute retryable. + # + # source://activerecord//lib/active_record/statement_cache.rb#65 + def retryable; end + + # Sets the attribute retryable + # + # @param value the value to set the attribute retryable to. + # + # source://activerecord//lib/active_record/statement_cache.rb#65 + def retryable=(_arg0); end + # source://activerecord//lib/active_record/statement_cache.rb#92 def value; end end @@ -31584,29 +35407,34 @@ class ActiveRecord::StatementCache::Substitute; end # # Wraps the underlying database error as +cause+. # -# source://activerecord//lib/active_record/errors.rb#158 -class ActiveRecord::StatementInvalid < ::ActiveRecord::ActiveRecordError +# source://activerecord//lib/active_record/errors.rb#191 +class ActiveRecord::StatementInvalid < ::ActiveRecord::AdapterError # @return [StatementInvalid] a new instance of StatementInvalid # - # source://activerecord//lib/active_record/errors.rb#159 - def initialize(message = T.unsafe(nil), sql: T.unsafe(nil), binds: T.unsafe(nil)); end + # source://activerecord//lib/active_record/errors.rb#192 + def initialize(message = T.unsafe(nil), sql: T.unsafe(nil), binds: T.unsafe(nil), connection_pool: T.unsafe(nil)); end # Returns the value of attribute binds. # - # source://activerecord//lib/active_record/errors.rb#165 + # source://activerecord//lib/active_record/errors.rb#198 def binds; end + # source://activerecord//lib/active_record/errors.rb#200 + def set_query(sql, binds); end + # Returns the value of attribute sql. # - # source://activerecord//lib/active_record/errors.rb#165 + # source://activerecord//lib/active_record/errors.rb#198 def sql; end end # StatementTimeout will be raised when statement timeout exceeded. # -# source://activerecord//lib/active_record/errors.rb#453 +# source://activerecord//lib/active_record/errors.rb#561 class ActiveRecord::StatementTimeout < ::ActiveRecord::QueryAborted; end +# = Active Record \Store +# # Store gives you a thin wrapper around serialize for the purpose of storing hashes in a single column. # It's like a simple key/value store baked into your record when you don't care about being able to # query that store outside the context of a single record. @@ -31696,7 +35524,7 @@ class ActiveRecord::StatementTimeout < ::ActiveRecord::QueryAborted; end # end # end # -# source://activerecord//lib/active_record/store.rb#94 +# source://activerecord//lib/active_record/store.rb#96 module ActiveRecord::Store extend ::ActiveSupport::Concern @@ -31704,41 +35532,41 @@ module ActiveRecord::Store private - # source://activerecord//lib/active_record/store.rb#206 + # source://activerecord//lib/active_record/store.rb#209 def read_store_attribute(store_attribute, key); end - # source://activerecord//lib/active_record/store.rb#216 + # source://activerecord//lib/active_record/store.rb#219 def store_accessor_for(store_attribute); end - # source://activerecord//lib/active_record/store.rb#211 + # source://activerecord//lib/active_record/store.rb#214 def write_store_attribute(store_attribute, key, value); end end -# source://activerecord//lib/active_record/store.rb#103 +# source://activerecord//lib/active_record/store.rb#105 module ActiveRecord::Store::ClassMethods - # source://activerecord//lib/active_record/store.rb#188 + # source://activerecord//lib/active_record/store.rb#191 def _store_accessors_module; end - # source://activerecord//lib/active_record/store.rb#104 + # source://activerecord//lib/active_record/store.rb#106 def store(store_attribute, options = T.unsafe(nil)); end - # source://activerecord//lib/active_record/store.rb#109 + # source://activerecord//lib/active_record/store.rb#112 def store_accessor(store_attribute, *keys, prefix: T.unsafe(nil), suffix: T.unsafe(nil)); end - # source://activerecord//lib/active_record/store.rb#196 + # source://activerecord//lib/active_record/store.rb#199 def stored_attributes; end end -# source://activerecord//lib/active_record/store.rb#220 +# source://activerecord//lib/active_record/store.rb#223 class ActiveRecord::Store::HashAccessor class << self # source://activerecord//lib/active_record/store.rb#234 def prepare(object, attribute); end - # source://activerecord//lib/active_record/store.rb#221 + # source://activerecord//lib/active_record/store.rb#224 def read(object, attribute, key); end - # source://activerecord//lib/active_record/store.rb#226 + # source://activerecord//lib/active_record/store.rb#229 def write(object, attribute, key, value); end end end @@ -31788,7 +35616,13 @@ end # Raised on attempt to lazily load records that are marked as strict loading. # -# source://activerecord//lib/active_record/errors.rb#307 +# You can resolve this error by eager loading marked records before accessing +# them. The +# {Eager Loading Associations}[https://guides.rubyonrails.org/active_record_querying.html#eager-loading-associations] +# guide covers solutions, such as using +# {ActiveRecord::Base.includes}[rdoc-ref:QueryMethods#includes]. +# +# source://activerecord//lib/active_record/errors.rb#391 class ActiveRecord::StrictLoadingViolationError < ::ActiveRecord::ActiveRecordError; end # Raised when the single-table inheritance mechanism fails to locate the subclass @@ -31799,6 +35633,8 @@ class ActiveRecord::StrictLoadingViolationError < ::ActiveRecord::ActiveRecordEr # source://activerecord//lib/active_record/errors.rb#18 class ActiveRecord::SubclassNotFound < ::ActiveRecord::ActiveRecordError; end +# = Active Record \Suppressor +# # ActiveRecord::Suppressor prevents the receiver from being saved during # a given block. # @@ -31826,27 +35662,27 @@ class ActiveRecord::SubclassNotFound < ::ActiveRecord::ActiveRecordError; end # end # end # -# source://activerecord//lib/active_record/suppressor.rb#30 +# source://activerecord//lib/active_record/suppressor.rb#32 module ActiveRecord::Suppressor extend ::ActiveSupport::Concern mixes_in_class_methods ::ActiveRecord::Suppressor::ClassMethods - # source://activerecord//lib/active_record/suppressor.rb#49 + # source://activerecord//lib/active_record/suppressor.rb#51 def save(**_arg0); end - # source://activerecord//lib/active_record/suppressor.rb#53 + # source://activerecord//lib/active_record/suppressor.rb#55 def save!(**_arg0); end class << self - # source://activerecord//lib/active_record/suppressor.rb#34 + # source://activerecord//lib/active_record/suppressor.rb#36 def registry; end end end -# source://activerecord//lib/active_record/suppressor.rb#39 +# source://activerecord//lib/active_record/suppressor.rb#41 module ActiveRecord::Suppressor::ClassMethods - # source://activerecord//lib/active_record/suppressor.rb#40 + # source://activerecord//lib/active_record/suppressor.rb#42 def suppress(&block); end end @@ -31857,12 +35693,12 @@ class ActiveRecord::TableMetadata # source://activerecord//lib/active_record/table_metadata.rb#7 def initialize(klass, arel_table, reflection = T.unsafe(nil)); end - # source://activerecord//lib/active_record/table_metadata.rb#61 + # source://activerecord//lib/active_record/table_metadata.rb#65 def aggregated_with?(aggregation_name); end # Returns the value of attribute arel_table. # - # source://activerecord//lib/active_record/table_metadata.rb#76 + # source://activerecord//lib/active_record/table_metadata.rb#80 def arel_table; end # source://activerecord//lib/active_record/table_metadata.rb#29 @@ -31887,23 +35723,29 @@ class ActiveRecord::TableMetadata # source://activerecord//lib/active_record/table_metadata.rb#5 def join_primary_key(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/table_metadata.rb#5 + def join_primary_type(*_arg0, **_arg1, &_arg2); end + # @return [Boolean] # # source://activerecord//lib/active_record/table_metadata.rb#53 def polymorphic_association?; end - # source://activerecord//lib/active_record/table_metadata.rb#66 + # source://activerecord//lib/active_record/table_metadata.rb#57 + def polymorphic_name_association; end + + # source://activerecord//lib/active_record/table_metadata.rb#70 def predicate_builder; end # source://activerecord//lib/active_record/table_metadata.rb#13 def primary_key; end - # source://activerecord//lib/active_record/table_metadata.rb#61 + # source://activerecord//lib/active_record/table_metadata.rb#65 def reflect_on_aggregation(aggregation_name); end # @return [Boolean] # - # source://activerecord//lib/active_record/table_metadata.rb#57 + # source://activerecord//lib/active_record/table_metadata.rb#61 def through_association?; end # source://activerecord//lib/active_record/table_metadata.rb#17 @@ -31913,12 +35755,12 @@ class ActiveRecord::TableMetadata # Returns the value of attribute klass. # - # source://activerecord//lib/active_record/table_metadata.rb#79 + # source://activerecord//lib/active_record/table_metadata.rb#83 def klass; end # Returns the value of attribute reflection. # - # source://activerecord//lib/active_record/table_metadata.rb#79 + # source://activerecord//lib/active_record/table_metadata.rb#83 def reflection; end end @@ -31927,7 +35769,7 @@ end # source://activerecord//lib/active_record/errors.rb#46 class ActiveRecord::TableNotSpecified < ::ActiveRecord::ActiveRecordError; end -# source://activerecord//lib/active_record.rb#159 +# source://activerecord//lib/active_record.rb#172 module ActiveRecord::Tasks extend ::ActiveSupport::Autoload end @@ -31935,14 +35777,16 @@ end # source://activerecord//lib/active_record/tasks/database_tasks.rb#7 class ActiveRecord::Tasks::DatabaseNotSupported < ::StandardError; end +# = Active Record \DatabaseTasks +# # ActiveRecord::Tasks::DatabaseTasks is a utility class, which encapsulates # logic behind common tasks used to manage database and migrations. # -# The tasks defined here are used with Rails commands provided by Active Record. +# The tasks defined here are used with \Rails commands provided by Active Record. # # In order to use DatabaseTasks, a few config values need to be set. All the needed -# config values are set by Rails already, so it's necessary to do it only if you -# want to change the defaults or when you want to use Active Record outside of Rails +# config values are set by \Rails already, so it's necessary to do it only if you +# want to change the defaults or when you want to use Active Record outside of \Rails # (in such case after configuring the database tasks, you can also use the rake tasks # defined in Active Record). # @@ -31956,7 +35800,7 @@ class ActiveRecord::Tasks::DatabaseNotSupported < ::StandardError; end # * +seed_loader+: an object which will load seeds, it needs to respond to the +load_seed+ method. # * +root+: a path to the root of the application. # -# Example usage of DatabaseTasks outside Rails could look as such: +# Example usage of DatabaseTasks outside \Rails could look as such: # # include ActiveRecord::Tasks # DatabaseTasks.database_configuration = YAML.load_file('my_database_config.yml') @@ -31965,302 +35809,320 @@ class ActiveRecord::Tasks::DatabaseNotSupported < ::StandardError; end # # DatabaseTasks.create_current('production') # -# source://activerecord//lib/active_record/tasks/database_tasks.rb#38 +# source://activerecord//lib/active_record/tasks/database_tasks.rb#40 module ActiveRecord::Tasks::DatabaseTasks extend ::ActiveRecord::Tasks::DatabaseTasks - # source://activerecord//lib/active_record/tasks/database_tasks.rb#470 - def cache_dump_filename(db_config_name, schema_cache_path: T.unsafe(nil)); end + # source://activerecord//lib/active_record/tasks/database_tasks.rb#449 + def cache_dump_filename(db_config_or_name, schema_cache_path: T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#324 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#313 def charset(configuration, *arguments); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#319 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#308 def charset_current(env_name = T.unsafe(nil), db_name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#63 - def check_protected_environments!; end + # source://activerecord//lib/active_record/tasks/database_tasks.rb#65 + def check_protected_environments!(environment = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#487 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#479 def check_schema_file(filename); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#309 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#298 def check_target_version; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#513 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#505 def clear_schema_cache(filename); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#334 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#323 def collation(configuration, *arguments); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#329 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#318 def collation_current(env_name = T.unsafe(nil), db_name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#120 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#115 def create(configuration, *arguments); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#132 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#127 def create_all; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#183 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#170 def create_current(environment = T.unsafe(nil), name = T.unsafe(nil)); end # Returns the value of attribute database_configuration. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#59 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#61 def database_configuration; end # Sets the attribute database_configuration # # @param value the value to set the attribute database_configuration to. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#59 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#61 def database_configuration=(_arg0); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#277 - def db_configs_with_versions(db_configs); end + # source://activerecord//lib/active_record/tasks/database_tasks.rb#266 + def db_configs_with_versions(environment = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#88 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#83 def db_dir; end # Sets the attribute db_dir # # @param value the value to set the attribute db_dir to. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#58 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#60 def db_dir=(_arg0); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#222 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#212 def drop(configuration, *arguments); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#234 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#224 def drop_all; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#238 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#228 def drop_current(environment = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#423 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#412 def dump_schema(db_config, format = T.unsafe(nil)); end # Dumps the schema cache in YAML format for the connection into the file # - # ==== Examples: - # ActiveRecord::Tasks::DatabaseTasks.dump_schema_cache(ActiveRecord::Base.connection, "tmp/schema_dump.yaml") + # ==== Examples + # ActiveRecord::Tasks::DatabaseTasks.dump_schema_cache(ActiveRecord::Base.lease_connection, "tmp/schema_dump.yaml") # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#509 - def dump_schema_cache(conn, filename); end + # source://activerecord//lib/active_record/tasks/database_tasks.rb#501 + def dump_schema_cache(conn_or_pool, filename); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#108 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#103 def env; end # Sets the attribute env # # @param value the value to set the attribute env to. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#58 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#60 def env=(_arg0); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#96 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#91 def fixtures_path; end # Sets the attribute fixtures_path # # @param value the value to set the attribute fixtures_path to. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#58 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#60 def fixtures_path=(_arg0); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#154 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#141 def for_each(databases); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#367 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#357 def load_schema(db_config, format = T.unsafe(nil), file = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#480 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#471 def load_schema_current(format = T.unsafe(nil), file = T.unsafe(nil), environment = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#495 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#487 def load_seed; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#256 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#245 def migrate(version = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#294 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#283 def migrate_status; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#92 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#526 + def migration_class; end + + # source://activerecord//lib/active_record/tasks/database_tasks.rb#530 + def migration_connection; end + + # source://activerecord//lib/active_record/tasks/database_tasks.rb#534 + def migration_connection_pool; end + + # source://activerecord//lib/active_record/tasks/database_tasks.rb#87 def migrations_paths; end # Sets the attribute migrations_paths # # @param value the value to set the attribute migrations_paths to. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#58 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#60 def migrations_paths=(_arg0); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#112 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#107 def name; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#188 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#176 def prepare_all; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#339 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#328 def purge(configuration); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#344 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#333 def purge_all; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#348 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#337 def purge_current(environment = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#169 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#156 def raise_for_multi_db(environment = T.unsafe(nil), command:); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#405 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#394 def reconstruct_from_schema(db_config, format = T.unsafe(nil), file = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#79 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#73 def register_task(pattern, task); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#104 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#99 def root; end # Sets the attribute root # # @param value the value to set the attribute root to. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#58 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#60 def root=(_arg0); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#457 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#436 def schema_dump_path(db_config, format = T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def schema_file_type(*args, **_arg1, &block); end - # @return [Boolean] # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#390 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#378 def schema_up_to_date?(configuration, format = T.unsafe(nil), file = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#116 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#111 def seed_loader; end # Sets the attribute seed_loader # # @param value the value to set the attribute seed_loader to. # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#58 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#60 def seed_loader=(_arg0); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#140 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#135 def setup_initial_database_yaml; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#353 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#343 def structure_dump(configuration, *arguments); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#360 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#350 def structure_load(configuration, *arguments); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#315 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#304 def target_version; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#250 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#239 def truncate_all(environment = T.unsafe(nil)); end + # source://activerecord//lib/active_record/tasks/database_tasks.rb#520 + def with_temporary_connection(db_config, clobber: T.unsafe(nil), &block); end + + # source://activerecord//lib/active_record/tasks/database_tasks.rb#509 + def with_temporary_pool_for_each(env: T.unsafe(nil), name: T.unsafe(nil), clobber: T.unsafe(nil), &block); end + private - # source://activerecord//lib/active_record/tasks/database_tasks.rb#541 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#643 + def check_current_protected_environment!(db_config); end + + # source://activerecord//lib/active_record/tasks/database_tasks.rb#582 def class_for_adapter(adapter); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#518 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#559 def configs_for(**options); end # Create a new instance for the specified db configuration object # For classes that have been converted to use db_config objects, pass a # `DatabaseConfig`, otherwise pass a `Hash` # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#533 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#574 def database_adapter_for(db_config, *arguments); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#549 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#590 def each_current_configuration(environment, name = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#562 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#600 + def each_current_environment(environment, &block); end + + # source://activerecord//lib/active_record/tasks/database_tasks.rb#606 def each_local_configuration; end # @return [Boolean] # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#574 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#618 def local_database?(db_config); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#522 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#563 def resolve_configuration(configuration); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#579 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#539 + def schema_cache_env; end + + # source://activerecord//lib/active_record/tasks/database_tasks.rb#623 def schema_sha1(file); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#583 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#627 def structure_dump_flags_for(adapter); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#591 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#635 def structure_load_flags_for(adapter); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#242 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#232 def truncate_tables(db_config); end # @return [Boolean] # - # source://activerecord//lib/active_record/tasks/database_tasks.rb#526 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#567 def verbose?; end + # source://activerecord//lib/active_record/tasks/database_tasks.rb#550 + def with_temporary_pool(db_config, clobber: T.unsafe(nil)); end + class << self - # source://activerecord//lib/active_record/tasks/database_tasks.rb#48 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#50 def structure_dump_flags; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#48 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#50 def structure_dump_flags=(val); end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#54 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#56 def structure_load_flags; end - # source://activerecord//lib/active_record/tasks/database_tasks.rb#54 + # source://activerecord//lib/active_record/tasks/database_tasks.rb#56 def structure_load_flags=(val); end end end -# source://activerecord//lib/active_record/tasks/database_tasks.rb#61 +# source://activerecord//lib/active_record/tasks/database_tasks.rb#63 ActiveRecord::Tasks::DatabaseTasks::LOCAL_HOSTS = T.let(T.unsafe(nil), Array) # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#5 class ActiveRecord::Tasks::MySQLDatabaseTasks # @return [MySQLDatabaseTasks] a new instance of MySQLDatabaseTasks # - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#14 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#12 def initialize(db_config); end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#35 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#34 def charset; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#39 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#38 def collation; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#8 - def connection(*_arg0, **_arg1, &_arg2); end - - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#19 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#17 def create; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#25 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#23 def drop; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#8 - def establish_connection(*_arg0, **_arg1, &_arg2); end - - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#30 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#28 def purge; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#43 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#42 def structure_dump(filename, extra_flags); end # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#61 @@ -32273,10 +36135,13 @@ class ActiveRecord::Tasks::MySQLDatabaseTasks # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#71 def configuration_hash; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#73 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#81 def configuration_hash_without_database; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#77 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#73 + def connection; end + + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#85 def creation_options; end # Returns the value of attribute db_config. @@ -32284,19 +36149,22 @@ class ActiveRecord::Tasks::MySQLDatabaseTasks # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#71 def db_config; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#84 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#77 + def establish_connection(config = T.unsafe(nil)); end + + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#92 def prepare_command_options; end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#102 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#111 def run_cmd(cmd, args, action); end - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#106 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#115 def run_cmd_error(cmd, args, action); end class << self # @return [Boolean] # - # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#10 + # source://activerecord//lib/active_record/tasks/mysql_database_tasks.rb#8 def using_database_configurations?; end end end @@ -32308,73 +36176,70 @@ ActiveRecord::Tasks::MySQLDatabaseTasks::ER_DB_CREATE_EXISTS = T.let(T.unsafe(ni class ActiveRecord::Tasks::PostgreSQLDatabaseTasks # @return [PostgreSQLDatabaseTasks] a new instance of PostgreSQLDatabaseTasks # - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#19 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#16 def initialize(db_config); end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#35 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#32 def charset; end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#12 - def clear_active_connections!(*_arg0, **_arg1, &_arg2); end - - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#39 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#36 def collation; end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#12 - def connection(*_arg0, **_arg1, &_arg2); end + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#21 + def create(connection_already_established = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#24 - def create(master_established = T.unsafe(nil)); end - - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#30 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#27 def drop; end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#12 - def establish_connection(*_arg0, **_arg1, &_arg2); end - - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#43 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#40 def purge; end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#49 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#46 def structure_dump(filename, extra_flags); end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#82 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#80 def structure_load(filename, extra_flags); end private # Returns the value of attribute configuration_hash. # - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#90 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#88 def configuration_hash; end + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#90 + def connection; end + # Returns the value of attribute db_config. # - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#90 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#88 def db_config; end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#92 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#98 def encoding; end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#96 - def establish_master_connection; end + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#94 + def establish_connection(config = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#103 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#106 def psql_env; end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#127 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#102 + def public_schema_config; end + + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#130 def remove_sql_header_comments(filename); end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#116 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#119 def run_cmd(cmd, args, action); end - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#120 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#123 def run_cmd_error(cmd, args, action); end class << self # @return [Boolean] # - # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#15 + # source://activerecord//lib/active_record/tasks/postgresql_database_tasks.rb#12 def using_database_configurations?; end end end @@ -32392,30 +36257,24 @@ ActiveRecord::Tasks::PostgreSQLDatabaseTasks::SQL_COMMENT_BEGIN = T.let(T.unsafe class ActiveRecord::Tasks::SQLiteDatabaseTasks # @return [SQLiteDatabaseTasks] a new instance of SQLiteDatabaseTasks # - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#12 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#10 def initialize(db_config, root = T.unsafe(nil)); end - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#41 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#40 def charset; end - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#6 - def connection(*_arg0, **_arg1, &_arg2); end - # @raise [DatabaseAlreadyExists] # - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#17 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#15 def create; end - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#24 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#22 def drop; end - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#6 - def establish_connection(*_arg0, **_arg1, &_arg2); end - - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#34 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#31 def purge; end - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#45 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#44 def structure_dump(filename, extra_flags); end # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#60 @@ -32423,26 +36282,32 @@ class ActiveRecord::Tasks::SQLiteDatabaseTasks private + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#68 + def connection; end + # Returns the value of attribute db_config. # # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#66 def db_config; end + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#72 + def establish_connection(config = T.unsafe(nil)); end + # Returns the value of attribute root. # # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#66 def root; end - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#68 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#77 def run_cmd(cmd, args, out); end - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#72 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#81 def run_cmd_error(cmd, args); end class << self # @return [Boolean] # - # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#8 + # source://activerecord//lib/active_record/tasks/sqlite_database_tasks.rb#6 def using_database_configurations?; end end end @@ -32469,33 +36334,52 @@ module ActiveRecord::TestFixtures # source://activerecord//lib/active_record/test_fixtures.rb#9 def before_setup; end - # source://activerecord//lib/active_record/test_fixtures.rb#189 - def enlist_fixture_connections; end - - # @return [Boolean] + # Generic fixture accessor for fixture names that may conflict with other methods. + # + # assert_equal "Ruby on Rails", web_sites(:rubyonrails).name + # assert_equal "Ruby on Rails", fixture(:web_sites, :rubyonrails).name # # source://activerecord//lib/active_record/test_fixtures.rb#103 - def run_in_transaction?; end + def fixture(fixture_set_name, *fixture_names); end - # source://activerecord//lib/active_record/test_fixtures.rb#108 - def setup_fixtures(config = T.unsafe(nil)); end + private - # source://activerecord//lib/active_record/test_fixtures.rb#172 - def teardown_fixtures; end + # source://activerecord//lib/active_record/test_fixtures.rb#288 + def access_fixture(fs_name, *fixture_names); end - private + # source://activerecord//lib/active_record/test_fixtures.rb#280 + def active_record_fixture(fixture_set_name, *fixture_names); end - # source://activerecord//lib/active_record/test_fixtures.rb#278 + # source://activerecord//lib/active_record/test_fixtures.rb#248 def instantiate_fixtures; end - # source://activerecord//lib/active_record/test_fixtures.rb#274 + # source://activerecord//lib/active_record/test_fixtures.rb#157 + def invalidate_already_loaded_fixtures; end + + # source://activerecord//lib/active_record/test_fixtures.rb#244 def load_fixtures(config); end # @return [Boolean] # - # source://activerecord//lib/active_record/test_fixtures.rb#290 + # source://activerecord//lib/active_record/test_fixtures.rb#260 def load_instances?; end + # source://activerecord//lib/active_record/test_fixtures.rb#264 + def method_missing(method, *_arg1, **_arg2, &_arg3); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/test_fixtures.rb#272 + def respond_to_missing?(method, include_private = T.unsafe(nil)); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/test_fixtures.rb#108 + def run_in_transaction?; end + + # source://activerecord//lib/active_record/test_fixtures.rb#113 + def setup_fixtures(config = T.unsafe(nil)); end + # Shares the writing connection pool with connections on # other handlers. # @@ -32503,19 +36387,31 @@ module ActiveRecord::TestFixtures # need to share a connection pool so that the reading connection # can see data in the open transaction on the writing connection. # - # source://activerecord//lib/active_record/test_fixtures.rb#202 + # source://activerecord//lib/active_record/test_fixtures.rb#208 def setup_shared_connection_pool; end - # source://activerecord//lib/active_record/test_fixtures.rb#245 + # source://activerecord//lib/active_record/test_fixtures.rb#161 + def setup_transactional_fixtures; end + + # source://activerecord//lib/active_record/test_fixtures.rb#145 + def teardown_fixtures; end + + # source://activerecord//lib/active_record/test_fixtures.rb#227 def teardown_shared_connection_pool; end + # source://activerecord//lib/active_record/test_fixtures.rb#191 + def teardown_transactional_fixtures; end + module GeneratedClassMethods def fixture_class_names; end def fixture_class_names=(value); end def fixture_class_names?; end - def fixture_path; end - def fixture_path=(value); end - def fixture_path?; end + def fixture_paths; end + def fixture_paths=(value); end + def fixture_paths?; end + def fixture_sets; end + def fixture_sets=(value); end + def fixture_sets?; end def fixture_table_names; end def fixture_table_names=(value); end def fixture_table_names?; end @@ -32537,8 +36433,11 @@ module ActiveRecord::TestFixtures def fixture_class_names; end def fixture_class_names=(value); end def fixture_class_names?; end - def fixture_path; end - def fixture_path?; end + def fixture_paths; end + def fixture_paths?; end + def fixture_sets; end + def fixture_sets=(value); end + def fixture_sets?; end def fixture_table_names; end def fixture_table_names=(value); end def fixture_table_names?; end @@ -32557,9 +36456,9 @@ module ActiveRecord::TestFixtures end end -# source://activerecord//lib/active_record/test_fixtures.rb#29 +# source://activerecord//lib/active_record/test_fixtures.rb#43 module ActiveRecord::TestFixtures::ClassMethods - # source://activerecord//lib/active_record/test_fixtures.rb#42 + # source://activerecord//lib/active_record/test_fixtures.rb#56 def fixtures(*fixture_set_names); end # Sets the model class for a fixture when the class name cannot be inferred from the fixture name. @@ -32571,38 +36470,38 @@ module ActiveRecord::TestFixtures::ClassMethods # # The keys must be the fixture names, that coincide with the short paths to the fixture files. # - # source://activerecord//lib/active_record/test_fixtures.rb#38 + # source://activerecord//lib/active_record/test_fixtures.rb#52 def set_fixture_class(class_names = T.unsafe(nil)); end - # source://activerecord//lib/active_record/test_fixtures.rb#56 + # source://activerecord//lib/active_record/test_fixtures.rb#72 def setup_fixture_accessors(fixture_set_names = T.unsafe(nil)); end # Prevents automatically wrapping each specified test in a transaction, # to allow application logic transactions to be tested in a top-level # (non-nested) context. # - # source://activerecord//lib/active_record/test_fixtures.rb#92 + # source://activerecord//lib/active_record/test_fixtures.rb#88 def uses_transaction(*methods); end # @return [Boolean] # - # source://activerecord//lib/active_record/test_fixtures.rb#97 + # source://activerecord//lib/active_record/test_fixtures.rb#93 def uses_transaction?(method); end end -# source://activerecord//lib/active_record/associations.rb#177 +# source://activerecord//lib/active_record/associations/errors.rb#177 class ActiveRecord::ThroughCantAssociateThroughHasOneOrManyReflection < ::ActiveRecord::ActiveRecordError # @return [ThroughCantAssociateThroughHasOneOrManyReflection] a new instance of ThroughCantAssociateThroughHasOneOrManyReflection # - # source://activerecord//lib/active_record/associations.rb#178 + # source://activerecord//lib/active_record/associations/errors.rb#178 def initialize(owner = T.unsafe(nil), reflection = T.unsafe(nil)); end end -# source://activerecord//lib/active_record/associations.rb#208 +# source://activerecord//lib/active_record/associations/errors.rb#224 class ActiveRecord::ThroughNestedAssociationsAreReadonly < ::ActiveRecord::ActiveRecordError # @return [ThroughNestedAssociationsAreReadonly] a new instance of ThroughNestedAssociationsAreReadonly # - # source://activerecord//lib/active_record/associations.rb#209 + # source://activerecord//lib/active_record/associations/errors.rb#225 def initialize(owner = T.unsafe(nil), reflection = T.unsafe(nil)); end end @@ -32635,7 +36534,7 @@ end # # ActiveRecord::Base.time_zone_aware_types = [:datetime] # -# You can also add database specific timezone aware types. For example, for PostgreSQL: +# You can also add database-specific timezone aware types. For example, for PostgreSQL: # # ActiveRecord::Base.time_zone_aware_types += [:tsrange, :tstzrange] # @@ -32656,41 +36555,47 @@ module ActiveRecord::Timestamp private - # source://activerecord//lib/active_record/timestamp.rb#99 + # source://activerecord//lib/active_record/timestamp.rb#107 def _create_record; end - # source://activerecord//lib/active_record/timestamp.rb#111 + # source://activerecord//lib/active_record/timestamp.rb#119 def _update_record; end - # source://activerecord//lib/active_record/timestamp.rb#141 + # source://activerecord//lib/active_record/timestamp.rb#155 def all_timestamp_attributes_in_model; end # Clear attributes and changed_attributes # - # source://activerecord//lib/active_record/timestamp.rb#156 + # source://activerecord//lib/active_record/timestamp.rb#170 def clear_timestamp_attributes; end - # source://activerecord//lib/active_record/timestamp.rb#124 + # source://activerecord//lib/active_record/timestamp.rb#125 def create_or_update(touch: T.unsafe(nil), **_arg1); end - # source://activerecord//lib/active_record/timestamp.rb#145 + # source://activerecord//lib/active_record/timestamp.rb#159 def current_time_from_proper_timezone; end + # source://activerecord//lib/active_record/timestamp.rb#102 + def init_internals; end + # source://activerecord//lib/active_record/timestamp.rb#50 def initialize_dup(other); end - # source://activerecord//lib/active_record/timestamp.rb#149 + # source://activerecord//lib/active_record/timestamp.rb#163 def max_updated_column_timestamp; end + # source://activerecord//lib/active_record/timestamp.rb#130 + def record_update_timestamps; end + # @return [Boolean] # - # source://activerecord//lib/active_record/timestamp.rb#129 + # source://activerecord//lib/active_record/timestamp.rb#143 def should_record_timestamps?; end - # source://activerecord//lib/active_record/timestamp.rb#133 + # source://activerecord//lib/active_record/timestamp.rb#147 def timestamp_attributes_for_create_in_model; end - # source://activerecord//lib/active_record/timestamp.rb#137 + # source://activerecord//lib/active_record/timestamp.rb#151 def timestamp_attributes_for_update_in_model; end module GeneratedClassMethods @@ -32708,33 +36613,208 @@ end # source://activerecord//lib/active_record/timestamp.rb#55 module ActiveRecord::Timestamp::ClassMethods - # source://activerecord//lib/active_record/timestamp.rb#72 + # source://activerecord//lib/active_record/timestamp.rb#74 def all_timestamp_attributes_in_model; end - # source://activerecord//lib/active_record/timestamp.rb#77 + # source://activerecord//lib/active_record/timestamp.rb#79 def current_time_from_proper_timezone; end - # source://activerecord//lib/active_record/timestamp.rb#62 + # source://activerecord//lib/active_record/timestamp.rb#64 def timestamp_attributes_for_create_in_model; end - # source://activerecord//lib/active_record/timestamp.rb#67 + # source://activerecord//lib/active_record/timestamp.rb#69 def timestamp_attributes_for_update_in_model; end # source://activerecord//lib/active_record/timestamp.rb#56 def touch_attributes_with_time(*names, time: T.unsafe(nil)); end - private + protected - # source://activerecord//lib/active_record/timestamp.rb#90 - def reload_schema_from_cache; end + # source://activerecord//lib/active_record/timestamp.rb#84 + def reload_schema_from_cache(recursive = T.unsafe(nil)); end - # source://activerecord//lib/active_record/timestamp.rb#82 + private + + # source://activerecord//lib/active_record/timestamp.rb#92 def timestamp_attributes_for_create; end - # source://activerecord//lib/active_record/timestamp.rb#86 + # source://activerecord//lib/active_record/timestamp.rb#96 def timestamp_attributes_for_update; end end +# source://activerecord//lib/active_record/token_for.rb#6 +module ActiveRecord::TokenFor + extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActiveRecord::TokenFor::ClassMethods + + # Generates a token for a predefined +purpose+. + # + # Use ClassMethods#generates_token_for to define a token purpose and + # behavior. + # + # source://activerecord//lib/active_record/token_for.rb#119 + def generate_token_for(purpose); end + + module GeneratedClassMethods + def generated_token_verifier; end + def generated_token_verifier=(value); end + def token_definitions; end + def token_definitions=(value); end + end + + module GeneratedInstanceMethods; end +end + +# source://activerecord//lib/active_record/token_for.rb#56 +module ActiveRecord::TokenFor::ClassMethods + # source://activerecord//lib/active_record/token_for.rb#106 + def find_by_token_for(purpose, token); end + + # source://activerecord//lib/active_record/token_for.rb#110 + def find_by_token_for!(purpose, token); end + + # Defines the behavior of tokens generated for a specific +purpose+. + # A token can be generated by calling TokenFor#generate_token_for on a + # record. Later, that record can be fetched by calling #find_by_token_for + # (or #find_by_token_for!) with the same purpose and token. + # + # Tokens are signed so that they are tamper-proof. Thus they can be + # exposed to outside world as, for example, password reset tokens. + # + # By default, tokens do not expire. They can be configured to expire by + # specifying a duration via the +expires_in+ option. The duration becomes + # part of the token's signature, so changing the value of +expires_in+ + # will automatically invalidate previously generated tokens. + # + # A block may also be specified. When generating a token with + # TokenFor#generate_token_for, the block will be evaluated in the context + # of the record, and its return value will be embedded in the token as + # JSON. Later, when fetching the record with #find_by_token_for, the block + # will be evaluated again in the context of the fetched record. If the two + # JSON values do not match, the token will be treated as invalid. Note + # that the value returned by the block should not contain sensitive + # information because it will be embedded in the token as + # human-readable plaintext JSON. + # + # ==== Examples + # + # class User < ActiveRecord::Base + # has_secure_password + # + # generates_token_for :password_reset, expires_in: 15.minutes do + # # Last 10 characters of password salt, which changes when password is updated: + # password_salt&.last(10) + # end + # end + # + # user = User.first + # + # token = user.generate_token_for(:password_reset) + # User.find_by_token_for(:password_reset, token) # => user + # # 16 minutes later... + # User.find_by_token_for(:password_reset, token) # => nil + # + # token = user.generate_token_for(:password_reset) + # User.find_by_token_for(:password_reset, token) # => user + # user.update!(password: "new password") + # User.find_by_token_for(:password_reset, token) # => nil + # + # source://activerecord//lib/active_record/token_for.rb#102 + def generates_token_for(purpose, expires_in: T.unsafe(nil), &block); end +end + +# source://activerecord//lib/active_record/token_for.rb#38 +module ActiveRecord::TokenFor::RelationMethods + # Finds a record using a given +token+ for a predefined +purpose+. Returns + # +nil+ if the token is invalid or the record was not found. + # + # @raise [UnknownPrimaryKey] + # + # source://activerecord//lib/active_record/token_for.rb#41 + def find_by_token_for(purpose, token); end + + # Finds a record using a given +token+ for a predefined +purpose+. Raises + # ActiveSupport::MessageVerifier::InvalidSignature if the token is invalid + # (e.g. expired, bad format, etc). Raises ActiveRecord::RecordNotFound if + # the token is valid but the record was not found. + # + # source://activerecord//lib/active_record/token_for.rb#50 + def find_by_token_for!(purpose, token); end +end + +# source://activerecord//lib/active_record/token_for.rb#14 +class ActiveRecord::TokenFor::TokenDefinition < ::Struct + # Returns the value of attribute block + # + # @return [Object] the current value of block + def block; end + + # Sets the attribute block + # + # @param value [Object] the value to set the attribute block to. + # @return [Object] the newly set value + def block=(_); end + + # Returns the value of attribute defining_class + # + # @return [Object] the current value of defining_class + def defining_class; end + + # Sets the attribute defining_class + # + # @param value [Object] the value to set the attribute defining_class to. + # @return [Object] the newly set value + def defining_class=(_); end + + # Returns the value of attribute expires_in + # + # @return [Object] the current value of expires_in + def expires_in; end + + # Sets the attribute expires_in + # + # @param value [Object] the value to set the attribute expires_in to. + # @return [Object] the newly set value + def expires_in=(_); end + + # source://activerecord//lib/active_record/token_for.rb#15 + def full_purpose; end + + # source://activerecord//lib/active_record/token_for.rb#27 + def generate_token(model); end + + # source://activerecord//lib/active_record/token_for.rb#19 + def message_verifier; end + + # source://activerecord//lib/active_record/token_for.rb#23 + def payload_for(model); end + + # Returns the value of attribute purpose + # + # @return [Object] the current value of purpose + def purpose; end + + # Sets the attribute purpose + # + # @param value [Object] the value to set the attribute purpose to. + # @return [Object] the newly set value + def purpose=(_); end + + # source://activerecord//lib/active_record/token_for.rb#31 + def resolve_token(token); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + # = Active Record Touch Later # # source://activerecord//lib/active_record/touch_later.rb#5 @@ -32742,7 +36822,7 @@ module ActiveRecord::TouchLater # source://activerecord//lib/active_record/touch_later.rb#6 def before_committed!; end - # source://activerecord//lib/active_record/touch_later.rb#34 + # source://activerecord//lib/active_record/touch_later.rb#38 def touch(*names, time: T.unsafe(nil)); end # source://activerecord//lib/active_record/touch_later.rb#11 @@ -32750,41 +36830,187 @@ module ActiveRecord::TouchLater private - # source://activerecord//lib/active_record/touch_later.rb#61 - def belongs_to_touch_method; end - # @return [Boolean] # - # source://activerecord//lib/active_record/touch_later.rb#57 + # source://activerecord//lib/active_record/touch_later.rb#66 def has_defer_touch_attrs?; end - # source://activerecord//lib/active_record/touch_later.rb#45 + # source://activerecord//lib/active_record/touch_later.rb#49 + def init_internals; end + + # source://activerecord//lib/active_record/touch_later.rb#54 def surreptitiously_touch(attr_names); end - # source://activerecord//lib/active_record/touch_later.rb#52 + # source://activerecord//lib/active_record/touch_later.rb#61 def touch_deferred_attributes; end end +# Class specifies the interface to interact with the current transaction state. +# +# It can either map to an actual transaction/savepoint, or represent the +# absence of a transaction. +# +# == State +# +# We say that a transaction is _finalized_ when it wraps a real transaction +# that has been either committed or rolled back. +# +# A transaction is _open_ if it wraps a real transaction that is not finalized. +# +# On the other hand, a transaction is _closed_ when it is not open. That is, +# when it represents absence of transaction, or it wraps a real but finalized +# one. +# +# You can check whether a transaction is open or closed with the +open?+ and +# +closed?+ predicates: +# +# if Article.current_transaction.open? +# # We are inside a real and not finalized transaction. +# end +# +# Closed transactions are `blank?` too. +# +# == Callbacks +# +# After updating the database state, you may sometimes need to perform some extra work, or reflect these +# changes in a remote system like clearing or updating a cache: +# +# def publish_article(article) +# article.update!(published: true) +# NotificationService.article_published(article) +# end +# +# The above code works but has one important flaw, which is that it no longer works properly if called inside +# a transaction, as it will interact with the remote system before the changes are persisted: +# +# Article.transaction do +# article = create_article(article) +# publish_article(article) +# end +# +# The callbacks offered by ActiveRecord::Transaction allow to rewriting this method in a way that is compatible +# with transactions: +# +# def publish_article(article) +# article.update!(published: true) +# Article.current_transaction.after_commit do +# NotificationService.article_published(article) +# end +# end +# +# In the above example, if +publish_article+ is called inside a transaction, the callback will be invoked +# after the transaction is successfully committed, and if called outside a transaction, the callback will be invoked +# immediately. +# +# == Caveats +# +# When using after_commit callbacks, it is important to note that if the callback raises an error, the transaction +# won't be rolled back as it was already committed. Relying solely on these to synchronize state between multiple +# systems may lead to consistency issues. +# +# source://activerecord//lib/active_record/transaction.rb#68 +class ActiveRecord::Transaction + # @return [Transaction] a new instance of Transaction + # + # source://activerecord//lib/active_record/transaction.rb#69 + def initialize(internal_transaction); end + + # Registers a block to be called after the transaction is fully committed. + # + # If there is no currently open transactions, the block is called + # immediately, unless the transaction is finalized, in which case attempting + # to register the callback raises ActiveRecord::ActiveRecordError. + # + # If the transaction has a parent transaction, the callback is transferred to + # the parent when the current transaction commits, or dropped when the current transaction + # is rolled back. This operation is repeated until the outermost transaction is reached. + # + # If the callback raises an error, the transaction remains committed. + # + # source://activerecord//lib/active_record/transaction.rb#85 + def after_commit(&block); end + + # Registers a block to be called after the transaction is rolled back. + # + # If there is no currently open transactions, the block is not called. But + # if the transaction is finalized, attempting to register the callback + # raises ActiveRecord::ActiveRecordError. + # + # If the transaction is successfully committed but has a parent + # transaction, the callback is automatically added to the parent transaction. + # + # If the entire chain of nested transactions are all successfully committed, + # the block is never called. + # + # If the transaction is already finalized, attempting to register a callback + # will raise ActiveRecord::ActiveRecordError. + # + # source://activerecord//lib/active_record/transaction.rb#107 + def after_rollback(&block); end + + # Returns true if the transaction doesn't exist or is finalized. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/transaction.rb#117 + def blank?; end + + # Returns true if the transaction doesn't exist or is finalized. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/transaction.rb#117 + def closed?; end + + # Returns true if the transaction exists and isn't finalized yet. + # + # @return [Boolean] + # + # source://activerecord//lib/active_record/transaction.rb#112 + def open?; end + + # Returns a UUID for this transaction or +nil+ if no transaction is open. + # + # source://activerecord//lib/active_record/transaction.rb#124 + def uuid; end +end + +# source://activerecord//lib/active_record/transaction.rb#130 +ActiveRecord::Transaction::NULL_TRANSACTION = T.let(T.unsafe(nil), ActiveRecord::Transaction) + # TransactionIsolationError will be raised under the following conditions: # # * The adapter does not support setting the isolation level # * You are joining an existing open transaction # * You are creating a nested (savepoint) transaction # -# The mysql2 and postgresql adapters support setting the transaction isolation level. +# The mysql2, trilogy, and postgresql adapters support setting the transaction isolation level. # -# source://activerecord//lib/active_record/errors.rb#411 +# source://activerecord//lib/active_record/errors.rb#500 class ActiveRecord::TransactionIsolationError < ::ActiveRecord::ActiveRecordError; end # TransactionRollbackError will be raised when a transaction is rolled # back by the database due to a serialization failure or a deadlock. # +# These exceptions should not be generally rescued in nested transaction +# blocks, because they have side-effects in the actual enclosing transaction +# and internal Active Record state. They can be rescued if you are above the +# root transaction block, though. +# +# In that case, beware of transactional tests, however, because they run test +# cases in their own umbrella transaction. If you absolutely need to handle +# these exceptions in tests please consider disabling transactional tests in +# the affected test class (self.use_transactional_tests = false). +# +# Due to the aforementioned side-effects, this exception should not be raised +# manually by users. +# # See the following: # # * https://www.postgresql.org/docs/current/static/transaction-iso.html # * https://dev.mysql.com/doc/mysql-errors/en/server-error-reference.html#error_er_lock_deadlock # -# source://activerecord//lib/active_record/errors.rb#421 +# source://activerecord//lib/active_record/errors.rb#523 class ActiveRecord::TransactionRollbackError < ::ActiveRecord::StatementInvalid; end # See ActiveRecord::Transactions::ClassMethods for documentation. @@ -32795,7 +37021,13 @@ module ActiveRecord::Transactions mixes_in_class_methods ::ActiveRecord::Transactions::ClassMethods - # source://activerecord//lib/active_record/transactions.rb#309 + # source://activerecord//lib/active_record/transactions.rb#16 + def _new_record_before_last_commit; end + + # source://activerecord//lib/active_record/transactions.rb#16 + def _new_record_before_last_commit=(_arg0); end + + # source://activerecord//lib/active_record/transactions.rb#373 def before_committed!; end # Call the #after_commit callbacks. @@ -32803,102 +37035,105 @@ module ActiveRecord::Transactions # Ensure that it is not called if the object was never persisted (failed create), # but call it after the commit of a destroyed object. # - # source://activerecord//lib/active_record/transactions.rb#317 + # source://activerecord//lib/active_record/transactions.rb#381 def committed!(should_run_callbacks: T.unsafe(nil)); end - # source://activerecord//lib/active_record/transactions.rb#293 + # source://activerecord//lib/active_record/transactions.rb#357 def destroy; end # Call the #after_rollback callbacks. The +force_restore_state+ argument indicates if the record # state should be rolled back to the beginning or just to the last savepoint. # - # source://activerecord//lib/active_record/transactions.rb#329 + # source://activerecord//lib/active_record/transactions.rb#393 def rolledback!(force_restore_state: T.unsafe(nil), should_run_callbacks: T.unsafe(nil)); end - # source://activerecord//lib/active_record/transactions.rb#297 + # source://activerecord//lib/active_record/transactions.rb#361 def save(**_arg0); end - # source://activerecord//lib/active_record/transactions.rb#301 + # source://activerecord//lib/active_record/transactions.rb#365 def save!(**_arg0); end - # source://activerecord//lib/active_record/transactions.rb#305 + # source://activerecord//lib/active_record/transactions.rb#369 def touch(*_arg0, **_arg1); end # See ActiveRecord::Transactions::ClassMethods for detailed documentation. # - # source://activerecord//lib/active_record/transactions.rb#289 + # source://activerecord//lib/active_record/transactions.rb#353 def transaction(**options, &block); end # @return [Boolean] # - # source://activerecord//lib/active_record/transactions.rb#360 + # source://activerecord//lib/active_record/transactions.rb#425 def trigger_transactional_callbacks?; end - # Executes +method+ within a transaction and captures its return value as a - # status flag. If the status is true the transaction is committed, otherwise - # a ROLLBACK is issued. In any case the status flag is returned. + # Executes a block within a transaction and captures its return value as a + # status flag. If the status is true, the transaction is committed, + # otherwise a ROLLBACK is issued. In any case, the status flag is returned. # # This method is available within the context of an ActiveRecord::Base # instance. # - # source://activerecord//lib/active_record/transactions.rb#345 + # source://activerecord//lib/active_record/transactions.rb#409 def with_transaction_returning_status; end private # Returns the value of attribute _committed_already_called. # - # source://activerecord//lib/active_record/transactions.rb#366 + # source://activerecord//lib/active_record/transactions.rb#431 def _committed_already_called; end # Returns the value of attribute _trigger_destroy_callback. # - # source://activerecord//lib/active_record/transactions.rb#366 + # source://activerecord//lib/active_record/transactions.rb#431 def _trigger_destroy_callback; end # Returns the value of attribute _trigger_update_callback. # - # source://activerecord//lib/active_record/transactions.rb#366 + # source://activerecord//lib/active_record/transactions.rb#431 def _trigger_update_callback; end # Add the record to the current transaction so that the #after_rollback and #after_commit # callbacks can be called. # - # source://activerecord//lib/active_record/transactions.rb#433 + # source://activerecord//lib/active_record/transactions.rb#513 def add_to_transaction(ensure_finalize = T.unsafe(nil)); end # Clear the new record state and id of a record. # - # source://activerecord//lib/active_record/transactions.rb#389 + # source://activerecord//lib/active_record/transactions.rb#461 def clear_transaction_record_state; end # @return [Boolean] # - # source://activerecord//lib/active_record/transactions.rb#437 + # source://activerecord//lib/active_record/transactions.rb#519 def has_transactional_callbacks?; end + # source://activerecord//lib/active_record/transactions.rb#433 + def init_internals; end + # Save the new record state and id of a record so it can be restored later if a transaction fails. # - # source://activerecord//lib/active_record/transactions.rb#369 + # source://activerecord//lib/active_record/transactions.rb#441 def remember_transaction_record_state; end # Restore the new record state and id of a record that was previously saved by a call to save_record_state. # - # source://activerecord//lib/active_record/transactions.rb#396 + # source://activerecord//lib/active_record/transactions.rb#468 def restore_transaction_record_state(force_restore_state = T.unsafe(nil)); end # Determine if a transaction included an action for :create, :update, or :destroy. Used in filtering callbacks. # # @return [Boolean] # - # source://activerecord//lib/active_record/transactions.rb#418 + # source://activerecord//lib/active_record/transactions.rb#498 def transaction_include_any_action?(actions); end end # source://activerecord//lib/active_record/transactions.rb#8 ActiveRecord::Transactions::ACTIONS = T.let(T.unsafe(nil), Array) -# = Active Record Transactions +# = Active Record \Transactions # # \Transactions are protective blocks where SQL statements are only permanent # if they can all succeed as one atomic action. The classic example is a @@ -32983,7 +37218,8 @@ ActiveRecord::Transactions::ACTIONS = T.let(T.unsafe(nil), Array) # catch those in your application code. # # One exception is the ActiveRecord::Rollback exception, which will trigger -# a ROLLBACK when raised, but not be re-raised by the transaction block. +# a ROLLBACK when raised, but not be re-raised by the transaction block. Any +# other exception will be re-raised. # # *Warning*: one should not catch ActiveRecord::StatementInvalid exceptions # inside a transaction block. ActiveRecord::StatementInvalid exceptions indicate that an @@ -33070,6 +37306,27 @@ ActiveRecord::Transactions::ACTIONS = T.let(T.unsafe(nil), Array) # #after_commit is a good spot to put in a hook to clearing a cache since clearing it from # within a transaction could trigger the cache to be regenerated before the database is updated. # +# ==== NOTE: Callbacks are deduplicated per callback by filter. +# +# Trying to define multiple callbacks with the same filter will result in a single callback being run. +# +# For example: +# +# after_commit :do_something +# after_commit :do_something # only the last one will be called +# +# This applies to all variations of after_*_commit callbacks as well. +# +# after_commit :do_something +# after_create_commit :do_something +# after_save_commit :do_something +# +# It is recommended to use the +on:+ option to specify when the callback should be run. +# +# after_commit :do_something, on: [:create, :update] +# +# This is equivalent to using +after_create_commit+ and +after_update_commit+, but will not be deduplicated. +# # === Caveats # # If you're on MySQL, then do not use Data Definition Language (DDL) operations in nested @@ -33080,16 +37337,16 @@ ActiveRecord::Transactions::ACTIONS = T.let(T.unsafe(nil), Array) # database error will occur because the savepoint has already been # automatically released. The following example demonstrates the problem: # -# Model.connection.transaction do # BEGIN -# Model.connection.transaction(requires_new: true) do # CREATE SAVEPOINT active_record_1 -# Model.connection.create_table(...) # active_record_1 now automatically released +# Model.lease_connection.transaction do # BEGIN +# Model.lease_connection.transaction(requires_new: true) do # CREATE SAVEPOINT active_record_1 +# Model.lease_connection.create_table(...) # active_record_1 now automatically released # end # RELEASE SAVEPOINT active_record_1 # # ^^^^ BOOM! database error! # end # # Note that "TRUNCATE" is also a MySQL DDL statement! # -# source://activerecord//lib/active_record/transactions.rb#206 +# source://activerecord//lib/active_record/transactions.rb#230 module ActiveRecord::Transactions::ClassMethods # This callback is called after a record has been created, updated, or destroyed. # @@ -33103,66 +37360,83 @@ module ActiveRecord::Transactions::ClassMethods # after_commit :do_foo_bar, on: [:create, :update] # after_commit :do_bar_baz, on: [:update, :destroy] # - # source://activerecord//lib/active_record/transactions.rb#229 + # source://activerecord//lib/active_record/transactions.rb#266 def after_commit(*args, &block); end # Shortcut for after_commit :hook, on: :create. # - # source://activerecord//lib/active_record/transactions.rb#241 + # source://activerecord//lib/active_record/transactions.rb#278 def after_create_commit(*args, &block); end # Shortcut for after_commit :hook, on: :destroy. # - # source://activerecord//lib/active_record/transactions.rb#253 + # source://activerecord//lib/active_record/transactions.rb#290 def after_destroy_commit(*args, &block); end # This callback is called after a create, update, or destroy are rolled back. # # Please check the documentation of #after_commit for options. # - # source://activerecord//lib/active_record/transactions.rb#261 + # source://activerecord//lib/active_record/transactions.rb#298 def after_rollback(*args, &block); end # Shortcut for after_commit :hook, on: [ :create, :update ]. # - # source://activerecord//lib/active_record/transactions.rb#235 + # source://activerecord//lib/active_record/transactions.rb#272 def after_save_commit(*args, &block); end # Shortcut for after_commit :hook, on: :update. # - # source://activerecord//lib/active_record/transactions.rb#247 + # source://activerecord//lib/active_record/transactions.rb#284 def after_update_commit(*args, &block); end - # source://activerecord//lib/active_record/transactions.rb#212 + # source://activerecord//lib/active_record/transactions.rb#249 def before_commit(*args, &block); end + # Returns a representation of the current transaction state, + # which can be a top level transaction, a savepoint, or the absence of a transaction. + # + # An object is always returned, whether or not a transaction is currently active. + # To check if a transaction was opened, use current_transaction.open?. + # + # See the ActiveRecord::Transaction documentation for detailed behavior. + # + # source://activerecord//lib/active_record/transactions.rb#245 + def current_transaction; end + + # Similar to ActiveSupport::Callbacks::ClassMethods#set_callback, but with + # support for options available on #after_commit and #after_rollback callbacks. + # + # source://activerecord//lib/active_record/transactions.rb#305 + def set_callback(name, *filter_list, &block); end + # See the ConnectionAdapters::DatabaseStatements#transaction API docs. # - # source://activerecord//lib/active_record/transactions.rb#208 + # source://activerecord//lib/active_record/transactions.rb#232 def transaction(**options, &block); end private - # source://activerecord//lib/active_record/transactions.rb#281 + # source://activerecord//lib/active_record/transactions.rb#345 def assert_valid_transaction_action(actions); end - # source://activerecord//lib/active_record/transactions.rb#267 + # source://activerecord//lib/active_record/transactions.rb#323 + def prepend_option; end + + # source://activerecord//lib/active_record/transactions.rb#331 def set_options_for_callbacks!(args, enforced_options = T.unsafe(nil)); end end # source://activerecord//lib/active_record/translation.rb#4 module ActiveRecord::Translation - include ::ActiveModel::Naming - include ::ActiveModel::Translation - # Set the i18n scope to override ActiveModel. # - # source://activerecord//lib/active_record/translation.rb#20 + # source://activerecord//lib/active_record/translation.rb#18 def i18n_scope; end # Set the lookup ancestors for ActiveModel. # - # source://activerecord//lib/active_record/translation.rb#8 + # source://activerecord//lib/active_record/translation.rb#6 def lookup_ancestors; end end @@ -33208,33 +37482,33 @@ module ActiveRecord::Type end end -# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#8 +# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#6 class ActiveRecord::Type::AdapterSpecificRegistry # @return [AdapterSpecificRegistry] a new instance of AdapterSpecificRegistry # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#9 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#7 def initialize; end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#18 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#15 def add_modifier(options, klass, **args); end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#30 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#27 def lookup(symbol, *args, **kwargs); end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#22 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#19 def register(type_name, klass = T.unsafe(nil), **options, &block); end private - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#43 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#40 def find_registration(symbol, *args, **kwargs); end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#13 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#11 def initialize_copy(other); end # Returns the value of attribute registrations. # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#41 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#38 def registrations; end end @@ -33269,39 +37543,39 @@ class ActiveRecord::Type::DecimalWithoutScale < ::ActiveModel::Type::BigInteger def type_cast_for_schema(value); end end -# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#117 +# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#110 class ActiveRecord::Type::DecorationRegistration < ::ActiveRecord::Type::Registration # @return [DecorationRegistration] a new instance of DecorationRegistration # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#118 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#111 def initialize(options, klass, adapter: T.unsafe(nil)); end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#124 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#117 def call(registry, *args, **kwargs); end # @return [Boolean] # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#129 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#122 def matches?(*args, **kwargs); end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#133 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#126 def priority; end private # Returns the value of attribute klass. # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#138 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#131 def klass; end # @return [Boolean] # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#140 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#133 def matches_options?(**kwargs); end # Returns the value of attribute options. # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#138 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#131 def options; end end @@ -33357,12 +37631,15 @@ module ActiveRecord::Type::Internal; end # source://activerecord//lib/active_record/type/internal/timezone.rb#6 module ActiveRecord::Type::Internal::Timezone - # source://activerecord//lib/active_record/type/internal/timezone.rb#11 + # source://activerecord//lib/active_record/type/internal/timezone.rb#7 + def initialize(timezone: T.unsafe(nil), **kwargs); end + + # source://activerecord//lib/active_record/type/internal/timezone.rb#16 def default_timezone; end # @return [Boolean] # - # source://activerecord//lib/active_record/type/internal/timezone.rb#7 + # source://activerecord//lib/active_record/type/internal/timezone.rb#12 def is_utc?; end end @@ -33388,72 +37665,72 @@ class ActiveRecord::Type::Json < ::ActiveModel::Type::Value def type; end end -# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#50 +# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#47 class ActiveRecord::Type::Registration # @return [Registration] a new instance of Registration # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#51 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#48 def initialize(name, block, adapter: T.unsafe(nil), override: T.unsafe(nil)); end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#70 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#63 def <=>(other); end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#58 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#55 def call(_registry, *args, adapter: T.unsafe(nil), **kwargs); end # @return [Boolean] # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#66 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#59 def matches?(type_name, *args, **kwargs); end protected # Returns the value of attribute adapter. # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#80 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#73 def adapter; end # Returns the value of attribute block. # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#80 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#73 def block; end # Returns the value of attribute name. # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#80 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#73 def name; end # Returns the value of attribute override. # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#80 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#73 def override; end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#82 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#75 def priority; end - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#93 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#86 def priority_except_adapter; end private # @return [Boolean] # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#102 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#95 def conflicts_with?(other); end # @return [Boolean] # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#111 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#104 def has_adapter_conflict?(other); end # @return [Boolean] # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#98 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#91 def matches_adapter?(adapter: T.unsafe(nil), **_arg1); end # @return [Boolean] # - # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#107 + # source://activerecord//lib/active_record/type/adapter_specific_registry.rb#100 def same_priority_except_adapter?(other); end end @@ -33466,15 +37743,15 @@ class ActiveRecord::Type::Serialized # source://activerecord//lib/active_record/type/serialized.rb#12 def initialize(subtype, coder); end - # source://activerecord//lib/active_record/type/serialized.rb#44 + # source://activerecord//lib/active_record/type/serialized.rb#42 def accessor; end - # source://activerecord//lib/active_record/type/serialized.rb#48 + # source://activerecord//lib/active_record/type/serialized.rb#46 def assert_valid_value(value); end # @return [Boolean] # - # source://activerecord//lib/active_record/type/serialized.rb#37 + # source://activerecord//lib/active_record/type/serialized.rb#35 def changed_in_place?(raw_old_value, value); end # Returns the value of attribute coder. @@ -33487,15 +37764,19 @@ class ActiveRecord::Type::Serialized # @return [Boolean] # - # source://activerecord//lib/active_record/type/serialized.rb#54 + # source://activerecord//lib/active_record/type/serialized.rb#52 def force_equality?(value); end - # source://activerecord//lib/active_record/type/serialized.rb#33 def inspect; end # source://activerecord//lib/active_record/type/serialized.rb#26 def serialize(value); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/type/serialized.rb#56 + def serialized?; end + # Returns the value of attribute subtype. # # source://activerecord//lib/active_record/type/serialized.rb#10 @@ -33505,10 +37786,10 @@ class ActiveRecord::Type::Serialized # @return [Boolean] # - # source://activerecord//lib/active_record/type/serialized.rb#59 + # source://activerecord//lib/active_record/type/serialized.rb#61 def default_value?(value); end - # source://activerecord//lib/active_record/type/serialized.rb#63 + # source://activerecord//lib/active_record/type/serialized.rb#65 def encoded(value); end end @@ -33528,9 +37809,12 @@ class ActiveRecord::Type::Time < ::ActiveModel::Type::Time # source://activerecord//lib/active_record/type/time.rb#11 def serialize(value); end + # source://activerecord//lib/active_record/type/time.rb#20 + def serialize_cast_value(value); end + private - # source://activerecord//lib/active_record/type/time.rb#21 + # source://activerecord//lib/active_record/type/time.rb#25 def cast_value(value); end end @@ -33596,9 +37880,6 @@ class ActiveRecord::TypeCaster::Connection private - # source://activerecord//lib/active_record/type_caster/connection.rb#27 - def connection(*_arg0, **_arg1, &_arg2); end - # Returns the value of attribute table_name. # # source://activerecord//lib/active_record/type_caster/connection.rb#30 @@ -33626,12 +37907,12 @@ class ActiveRecord::TypeCaster::Map def klass; end end -# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#148 +# source://activerecord//lib/active_record/type/adapter_specific_registry.rb#141 class ActiveRecord::TypeConflictError < ::StandardError; end # Raised when unknown attributes are supplied via mass assignment. # -# source://activerecord//lib/active_record/errors.rb#347 +# source://activerecord//lib/active_record/errors.rb#431 ActiveRecord::UnknownAttributeError = ActiveModel::UnknownAttributeError # UnknownAttributeReference is raised when an unknown and potentially unsafe @@ -33655,32 +37936,47 @@ ActiveRecord::UnknownAttributeError = ActiveModel::UnknownAttributeError # Again, such a workaround should *not* be used when passing user-provided # values, such as request parameters or model attributes to query methods. # -# source://activerecord//lib/active_record/errors.rb#484 +# source://activerecord//lib/active_record/errors.rb#597 class ActiveRecord::UnknownAttributeReference < ::ActiveRecord::ActiveRecordError; end -# source://activerecord//lib/active_record/migration.rb#113 +# source://activerecord//lib/active_record/migration.rb#114 class ActiveRecord::UnknownMigrationVersionError < ::ActiveRecord::MigrationError # @return [UnknownMigrationVersionError] a new instance of UnknownMigrationVersionError # - # source://activerecord//lib/active_record/migration.rb#114 + # source://activerecord//lib/active_record/migration.rb#115 def initialize(version = T.unsafe(nil)); end end # Raised when a primary key is needed, but not specified in the schema or model. # -# source://activerecord//lib/active_record/errors.rb#375 +# source://activerecord//lib/active_record/errors.rb#459 class ActiveRecord::UnknownPrimaryKey < ::ActiveRecord::ActiveRecordError # @return [UnknownPrimaryKey] a new instance of UnknownPrimaryKey # - # source://activerecord//lib/active_record/errors.rb#378 + # source://activerecord//lib/active_record/errors.rb#462 def initialize(model = T.unsafe(nil), description = T.unsafe(nil)); end # Returns the value of attribute model. # - # source://activerecord//lib/active_record/errors.rb#376 + # source://activerecord//lib/active_record/errors.rb#460 def model; end end +# Raised when a relation cannot be mutated because it's already loaded. +# +# class Task < ActiveRecord::Base +# end +# +# relation = Task.all +# relation.loaded? # => true +# +# # Methods which try to mutate a loaded relation fail. +# relation.where!(title: 'TODO') # => ActiveRecord::UnmodifiableRelation +# relation.limit!(5) # => ActiveRecord::UnmodifiableRelation +# +# source://activerecord//lib/active_record/errors.rb#485 +class ActiveRecord::UnmodifiableRelation < ::ActiveRecord::ActiveRecordError; end + # source://activerecord//lib/active_record/gem_version.rb#9 module ActiveRecord::VERSION; end @@ -33701,41 +37997,37 @@ ActiveRecord::VERSION::TINY = T.let(T.unsafe(nil), Integer) # = Active Record \Validations # -# Active Record includes the majority of its validations from ActiveModel::Validations -# all of which accept the :on argument to define the context where the -# validations are active. Active Record will always supply either the context of -# :create or :update dependent on whether the model is a +# Active Record includes the majority of its validations from ActiveModel::Validations. +# +# In Active Record, all validations are performed on save by default. +# Validations accept the :on argument to define the context where +# the validations are active. Active Record will pass either the context of +# :create or :update depending on whether the model is a # {new_record?}[rdoc-ref:Persistence#new_record?]. # -# source://activerecord//lib/active_record/validations.rb#38 +# source://activerecord//lib/active_record/validations.rb#40 module ActiveRecord::Validations extend ::ActiveSupport::Concern - include GeneratedInstanceMethods - include ::ActiveSupport::Callbacks - include ::ActiveModel::Validations::HelperMethods - include ::ActiveModel::Validations - mixes_in_class_methods GeneratedClassMethods - mixes_in_class_methods ::ActiveModel::Validations::ClassMethods - mixes_in_class_methods ::ActiveModel::Callbacks - mixes_in_class_methods ::ActiveSupport::Callbacks::ClassMethods - mixes_in_class_methods ::ActiveSupport::DescendantsTracker - mixes_in_class_methods ::ActiveModel::Translation - mixes_in_class_methods ::ActiveModel::Validations::HelperMethods mixes_in_class_methods ::ActiveRecord::Validations::ClassMethods + # @return [Boolean] + # + # source://activerecord//lib/active_record/validations.rb#77 + def custom_validation_context?; end + # The validation process on save can be skipped by passing validate: false. # The validation context can be changed by passing context: context. # The regular {ActiveRecord::Base#save}[rdoc-ref:Persistence#save] method is replaced # with this when the validations module is mixed in, which it is by default. # - # source://activerecord//lib/active_record/validations.rb#46 + # source://activerecord//lib/active_record/validations.rb#47 def save(**options); end # Attempts to save the record just like {ActiveRecord::Base#save}[rdoc-ref:Base#save] but # will raise an ActiveRecord::RecordInvalid exception instead of returning +false+ if the record is not valid. # - # source://activerecord//lib/active_record/validations.rb#52 + # source://activerecord//lib/active_record/validations.rb#53 def save!(**options); end # Runs all the validations within the specified context. Returns +true+ if @@ -33745,13 +38037,15 @@ module ActiveRecord::Validations # # If the argument is +false+ (default is +nil+), the context is set to :create if # {new_record?}[rdoc-ref:Persistence#new_record?] is +true+, and to :update if it is not. + # If the argument is an array of contexts, post.valid?([:create, :update]), the validations are + # run within multiple contexts. # # \Validations with no :on option will run no matter the context. \Validations with # some :on option will only run in the specified context. # # @return [Boolean] # - # source://activerecord//lib/active_record/validations.rb#66 + # source://activerecord//lib/active_record/validations.rb#69 def valid?(context = T.unsafe(nil)); end # Runs all the validations within the specified context. Returns +true+ if @@ -33761,43 +38055,29 @@ module ActiveRecord::Validations # # If the argument is +false+ (default is +nil+), the context is set to :create if # {new_record?}[rdoc-ref:Persistence#new_record?] is +true+, and to :update if it is not. + # If the argument is an array of contexts, post.valid?([:create, :update]), the validations are + # run within multiple contexts. # # \Validations with no :on option will run no matter the context. \Validations with # some :on option will only run in the specified context. # # @return [Boolean] # - # source://activerecord//lib/active_record/validations.rb#66 + # source://activerecord//lib/active_record/validations.rb#69 def validate(context = T.unsafe(nil)); end private - # source://activerecord//lib/active_record/validations.rb#75 + # source://activerecord//lib/active_record/validations.rb#82 def default_validation_context; end - # source://activerecord//lib/active_record/validations.rb#83 + # source://activerecord//lib/active_record/validations.rb#90 def perform_validations(options = T.unsafe(nil)); end # @raise [RecordInvalid] # - # source://activerecord//lib/active_record/validations.rb#79 + # source://activerecord//lib/active_record/validations.rb#86 def raise_validation_error; end - - module GeneratedClassMethods - def __callbacks; end - def __callbacks=(value); end - def __callbacks?; end - def _validators; end - def _validators=(value); end - def _validators?; end - end - - module GeneratedInstanceMethods - def __callbacks; end - def __callbacks?; end - def _validators; end - def _validators?; end - end end # source://activerecord//lib/active_record/validations/absence.rb#5 @@ -33813,17 +38093,20 @@ class ActiveRecord::Validations::AssociatedValidator < ::ActiveModel::EachValida private + # source://activerecord//lib/active_record/validations/associated.rb#19 + def record_validation_context_for_association(record); end + # @return [Boolean] # - # source://activerecord//lib/active_record/validations/associated.rb#13 - def valid_object?(record); end + # source://activerecord//lib/active_record/validations/associated.rb#15 + def valid_object?(record, context); end end -# source://activerecord//lib/active_record/validations/associated.rb#18 +# source://activerecord//lib/active_record/validations/associated.rb#24 module ActiveRecord::Validations::ClassMethods # Validates that the specified attributes are not present (as defined by # Object#present?). If the attribute is an association, the associated object - # is considered absent if it was marked for destruction. + # is also considered not present if it is marked for destruction. # # See ActiveModel::Validations::HelperMethods.validates_absence_of for more information. # @@ -33866,7 +38149,7 @@ module ActiveRecord::Validations::ClassMethods # method, proc, or string should return or evaluate to a +true+ or +false+ # value. # - # source://activerecord//lib/active_record/validations/associated.rb#54 + # source://activerecord//lib/active_record/validations/associated.rb#60 def validates_associated(*attr_names); end # Validates that the specified attributes match the length restrictions supplied. @@ -33878,20 +38161,20 @@ module ActiveRecord::Validations::ClassMethods def validates_length_of(*attr_names); end # Validates whether the value of the specified attribute is numeric by - # trying to convert it to a float with Kernel.Float (if only_integer - # is +false+) or applying it to the regular expression /\A[\+\-]?\d+\z/ - # (if only_integer is set to +true+). Kernel.Float precision - # defaults to the column's precision value or 15. + # trying to convert it to a float with +Kernel.Float+ (if + # only_integer is +false+) or applying it to the regular + # expression /\A[\+\-]?\d+\z/ (if only_integer is set to + # +true+). +Kernel.Float+ precision defaults to the column's precision + # value or 15. # # See ActiveModel::Validations::HelperMethods.validates_numericality_of for more information. # - # source://activerecord//lib/active_record/validations/numericality.rb#30 + # source://activerecord//lib/active_record/validations/numericality.rb#31 def validates_numericality_of(*attr_names); end # Validates that the specified attributes are not blank (as defined by - # Object#blank?), and, if the attribute is an association, that the - # associated object is not marked for destruction. Happens by default - # on save. + # Object#blank?). If the attribute is an association, the associated object + # is also considered blank if it is marked for destruction. # # class Person < ActiveRecord::Base # has_one :face @@ -33901,43 +38184,21 @@ module ActiveRecord::Validations::ClassMethods # The face attribute must be in the object and it cannot be blank or marked # for destruction. # - # If you want to validate the presence of a boolean field (where the real values - # are true and false), you will want to use - # validates_inclusion_of :field_name, in: [true, false]. - # - # This is due to the way Object#blank? handles boolean values: - # false.blank? # => true. - # # This validator defers to the Active Model validation for presence, adding the # check to see that an associated object is not marked for destruction. This # prevents the parent object from validating successfully and saving, which then # deletes the associated object, thus putting the parent object into an invalid # state. # + # See ActiveModel::Validations::HelperMethods.validates_presence_of for + # more information. + # # NOTE: This validation will not fail while using it with an association # if the latter was assigned but not valid. If you want to ensure that # it is both present and valid, you also need to use # {validates_associated}[rdoc-ref:Validations::ClassMethods#validates_associated]. # - # Configuration options: - # * :message - A custom error message (default is: "can't be blank"). - # * :on - Specifies the contexts where this validation is active. - # Runs in all validation contexts by default +nil+. You can pass a symbol - # or an array of symbols. (e.g. on: :create or - # on: :custom_validation_context or - # on: [:create, :custom_validation_context]) - # * :if - Specifies a method, proc, or string to call to determine if - # the validation should occur (e.g. if: :allow_validation, or - # if: Proc.new { |user| user.signup_step > 2 }). The method, proc - # or string should return or evaluate to a +true+ or +false+ value. - # * :unless - Specifies a method, proc, or string to call to determine - # if the validation should not occur (e.g. unless: :skip_validation, - # or unless: Proc.new { |user| user.signup_step <= 2 }). The method, - # proc or string should return or evaluate to a +true+ or +false+ value. - # * :strict - Specifies whether validation should be strict. - # See ActiveModel::Validations#validates! for more information. - # - # source://activerecord//lib/active_record/validations/presence.rb#63 + # source://activerecord//lib/active_record/validations/presence.rb#40 def validates_presence_of(*attr_names); end # Validates that the specified attributes match the length restrictions supplied. @@ -34066,7 +38327,7 @@ module ActiveRecord::Validations::ClassMethods # When the database catches such a duplicate insertion, # {ActiveRecord::Base#save}[rdoc-ref:Persistence#save] will raise an ActiveRecord::StatementInvalid # exception. You can either choose to let this error propagate (which - # will result in the default Rails exception page being shown), or you + # will result in the default \Rails exception page being shown), or you # can catch it and restart the transaction (e.g. by telling the user # that the title already exists, and asking them to re-enter the title). # This technique is also known as @@ -34081,10 +38342,11 @@ module ActiveRecord::Validations::ClassMethods # The following bundled adapters throw the ActiveRecord::RecordNotUnique exception: # # * ActiveRecord::ConnectionAdapters::Mysql2Adapter. + # * ActiveRecord::ConnectionAdapters::TrilogyAdapter. # * ActiveRecord::ConnectionAdapters::SQLite3Adapter. # * ActiveRecord::ConnectionAdapters::PostgreSQLAdapter. # - # source://activerecord//lib/active_record/validations/uniqueness.rb#241 + # source://activerecord//lib/active_record/validations/uniqueness.rb#290 def validates_uniqueness_of(*attr_names); end end @@ -34126,34 +38388,47 @@ class ActiveRecord::Validations::UniquenessValidator < ::ActiveModel::EachValida private - # source://activerecord//lib/active_record/validations/uniqueness.rb#67 + # source://activerecord//lib/active_record/validations/uniqueness.rb#111 def build_relation(klass, attribute, value); end + # @return [Boolean] + # + # source://activerecord//lib/active_record/validations/uniqueness.rb#82 + def covered_by_unique_index?(klass, record, attribute, scope); end + # The check for an existing value should be run from a class that # isn't abstract. This means working down from the current class # (self), to the first non-abstract class. Since classes don't know # their subclasses, we have to build the hierarchy between self and # the record's class. # - # source://activerecord//lib/active_record/validations/uniqueness.rb#57 + # source://activerecord//lib/active_record/validations/uniqueness.rb#59 def find_finder_class_for(record); end - # source://activerecord//lib/active_record/validations/uniqueness.rb#98 + # source://activerecord//lib/active_record/validations/uniqueness.rb#146 def map_enum_attribute(klass, attribute, value); end - # source://activerecord//lib/active_record/validations/uniqueness.rb#85 + # source://activerecord//lib/active_record/validations/uniqueness.rb#97 + def resolve_attributes(record, attributes); end + + # source://activerecord//lib/active_record/validations/uniqueness.rb#133 def scope_relation(record, relation); end + + # @return [Boolean] + # + # source://activerecord//lib/active_record/validations/uniqueness.rb#69 + def validation_needed?(klass, record, attribute); end end # Raised when a record cannot be inserted or updated because a value too long for a column type. # -# source://activerecord//lib/active_record/errors.rb#220 +# source://activerecord//lib/active_record/errors.rb#284 class ActiveRecord::ValueTooLong < ::ActiveRecord::StatementInvalid; end # Defunct wrapper class kept for compatibility. # StatementInvalid wraps the original exception now. # -# source://activerecord//lib/active_record/errors.rb#170 +# source://activerecord//lib/active_record/errors.rb#212 class ActiveRecord::WrappedDatabaseException < ::ActiveRecord::StatementInvalid; end # source://activerecord//lib/arel/errors.rb#3 @@ -34161,10 +38436,10 @@ module Arel class << self # @return [Boolean] # - # source://activerecord//lib/arel.rb#46 + # source://activerecord//lib/arel.rb#64 def arel_node?(value); end - # source://activerecord//lib/arel.rb#50 + # source://activerecord//lib/arel.rb#68 def fetch_attribute(value, &block); end # Wrap a known-safe SQL string for passing to query methods, e.g. @@ -34175,10 +38450,24 @@ module Arel # This method should not be used with unsafe values such as request # parameters or model attributes. # - # source://activerecord//lib/arel.rb#38 - def sql(raw_sql); end + # Take a look at the {security guide}[https://guides.rubyonrails.org/security.html#sql-injection] + # for more information. + # + # To construct a more complex query fragment, including the possible + # use of user-provided values, the +sql_string+ may contain ? and + # +:key+ placeholders, corresponding to the additional arguments. Note + # that this behavior only applies when bind value parameters are + # supplied in the call; without them, the placeholder tokens have no + # special meaning, and will be passed through to the query as-is. + # + # The +:retryable+ option can be used to mark the SQL as safe to retry. + # Use this option only if the SQL is idempotent, as it could be executed + # more than once. + # + # source://activerecord//lib/arel.rb#52 + def sql(sql_string, *positional_binds, retryable: T.unsafe(nil), **named_binds); end - # source://activerecord//lib/arel.rb#42 + # source://activerecord//lib/arel.rb#60 def star; end end end @@ -34223,6 +38512,14 @@ class Arel::Attributes::Attribute < ::Struct def type_caster; end end +# source://activerecord//lib/arel/errors.rb#10 +class Arel::BindError < ::Arel::ArelError + # @return [BindError] a new instance of BindError + # + # source://activerecord//lib/arel/errors.rb#11 + def initialize(message, sql = T.unsafe(nil)); end +end + # source://activerecord//lib/arel/collectors/plain_string.rb#4 module Arel::Collectors; end @@ -34230,19 +38527,31 @@ module Arel::Collectors; end class Arel::Collectors::Bind # @return [Bind] a new instance of Bind # - # source://activerecord//lib/arel/collectors/bind.rb#6 + # source://activerecord//lib/arel/collectors/bind.rb#8 def initialize; end - # source://activerecord//lib/arel/collectors/bind.rb#10 + # source://activerecord//lib/arel/collectors/bind.rb#12 def <<(str); end - # source://activerecord//lib/arel/collectors/bind.rb#14 + # source://activerecord//lib/arel/collectors/bind.rb#16 def add_bind(bind); end - # source://activerecord//lib/arel/collectors/bind.rb#19 + # source://activerecord//lib/arel/collectors/bind.rb#21 def add_binds(binds, proc_for_binds = T.unsafe(nil)); end - # source://activerecord//lib/arel/collectors/bind.rb#24 + # Returns the value of attribute retryable. + # + # source://activerecord//lib/arel/collectors/bind.rb#6 + def retryable; end + + # Sets the attribute retryable + # + # @param value the value to set the attribute retryable to. + # + # source://activerecord//lib/arel/collectors/bind.rb#6 + def retryable=(_arg0); end + + # source://activerecord//lib/arel/collectors/bind.rb#26 def value; end end @@ -34250,16 +38559,16 @@ end class Arel::Collectors::Composite # @return [Composite] a new instance of Composite # - # source://activerecord//lib/arel/collectors/composite.rb#8 + # source://activerecord//lib/arel/collectors/composite.rb#9 def initialize(left, right); end - # source://activerecord//lib/arel/collectors/composite.rb#13 + # source://activerecord//lib/arel/collectors/composite.rb#20 def <<(str); end - # source://activerecord//lib/arel/collectors/composite.rb#19 + # source://activerecord//lib/arel/collectors/composite.rb#26 def add_bind(bind, &block); end - # source://activerecord//lib/arel/collectors/composite.rb#25 + # source://activerecord//lib/arel/collectors/composite.rb#32 def add_binds(binds, proc_for_binds = T.unsafe(nil), &block); end # Returns the value of attribute preparable. @@ -34274,19 +38583,27 @@ class Arel::Collectors::Composite # source://activerecord//lib/arel/collectors/composite.rb#6 def preparable=(_arg0); end - # source://activerecord//lib/arel/collectors/composite.rb#31 + # Returns the value of attribute retryable. + # + # source://activerecord//lib/arel/collectors/composite.rb#7 + def retryable; end + + # source://activerecord//lib/arel/collectors/composite.rb#14 + def retryable=(retryable); end + + # source://activerecord//lib/arel/collectors/composite.rb#38 def value; end private # Returns the value of attribute left. # - # source://activerecord//lib/arel/collectors/composite.rb#36 + # source://activerecord//lib/arel/collectors/composite.rb#43 def left; end # Returns the value of attribute right. # - # source://activerecord//lib/arel/collectors/composite.rb#36 + # source://activerecord//lib/arel/collectors/composite.rb#43 def right; end end @@ -34328,6 +38645,18 @@ class Arel::Collectors::SQLString < ::Arel::Collectors::PlainString # # source://activerecord//lib/arel/collectors/sql_string.rb#8 def preparable=(_arg0); end + + # Returns the value of attribute retryable. + # + # source://activerecord//lib/arel/collectors/sql_string.rb#8 + def retryable; end + + # Sets the attribute retryable + # + # @param value the value to set the attribute retryable to. + # + # source://activerecord//lib/arel/collectors/sql_string.rb#8 + def retryable=(_arg0); end end # source://activerecord//lib/arel/collectors/substitute_binds.rb#5 @@ -34358,6 +38687,18 @@ class Arel::Collectors::SubstituteBinds # source://activerecord//lib/arel/collectors/substitute_binds.rb#6 def preparable=(_arg0); end + # Returns the value of attribute retryable. + # + # source://activerecord//lib/arel/collectors/substitute_binds.rb#6 + def retryable; end + + # Sets the attribute retryable + # + # @param value the value to set the attribute retryable to. + # + # source://activerecord//lib/arel/collectors/substitute_binds.rb#6 + def retryable=(_arg0); end + # source://activerecord//lib/arel/collectors/substitute_binds.rb#27 def value; end @@ -34438,6 +38779,9 @@ end # # source://activerecord//lib/arel/factory_methods.rb#6 module Arel::FactoryMethods + # source://activerecord//lib/arel/factory_methods.rb#49 + def cast(name, type); end + # source://activerecord//lib/arel/factory_methods.rb#45 def coalesce(*exprs); end @@ -34555,41 +38899,15 @@ class Arel::Nodes::Addition < ::Arel::Nodes::InfixOperation def initialize(left, right); end end -# source://activerecord//lib/arel/nodes/and.rb#5 -class Arel::Nodes::And < ::Arel::Nodes::NodeExpression - # @return [And] a new instance of And - # - # source://activerecord//lib/arel/nodes/and.rb#8 - def initialize(children); end - - # @return [Boolean] - # - # source://activerecord//lib/arel/nodes/and.rb#25 - def ==(other); end - - # Returns the value of attribute children. - # - # source://activerecord//lib/arel/nodes/and.rb#6 - def children; end - - # @return [Boolean] - # - # source://activerecord//lib/arel/nodes/and.rb#25 - def eql?(other); end - - # source://activerecord//lib/arel/nodes/and.rb#21 - def hash; end - - # source://activerecord//lib/arel/nodes/and.rb#13 - def left; end +# source://activerecord//lib/arel/nodes/nary.rb#36 +class Arel::Nodes::And < ::Arel::Nodes::Nary; end - # source://activerecord//lib/arel/nodes/and.rb#17 - def right; end +# source://activerecord//lib/arel/nodes/binary.rb#42 +class Arel::Nodes::As < ::Arel::Nodes::Binary + # source://activerecord//lib/arel/nodes/binary.rb#43 + def to_cte; end end -# source://activerecord//lib/arel/nodes/binary.rb#123 -class Arel::Nodes::As < ::Arel::Nodes::Binary; end - # source://activerecord//lib/arel/nodes/ascending.rb#5 class Arel::Nodes::Ascending < ::Arel::Nodes::Ordering # @return [Boolean] @@ -34609,13 +38927,13 @@ class Arel::Nodes::Ascending < ::Arel::Nodes::Ordering def reverse; end end -# source://activerecord//lib/arel/nodes/binary.rb#123 +# source://activerecord//lib/arel/nodes/binary.rb#122 class Arel::Nodes::Assignment < ::Arel::Nodes::Binary; end # source://activerecord//lib/arel/nodes/function.rb#42 class Arel::Nodes::Avg < ::Arel::Nodes::Function; end -# source://activerecord//lib/arel/nodes/binary.rb#42 +# source://activerecord//lib/arel/nodes/binary.rb#48 class Arel::Nodes::Between < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute end @@ -34765,6 +39083,50 @@ class Arel::Nodes::BitwiseXor < ::Arel::Nodes::InfixOperation def initialize(left, right); end end +# source://activerecord//lib/arel/nodes/bound_sql_literal.rb#5 +class Arel::Nodes::BoundSqlLiteral < ::Arel::Nodes::NodeExpression + # @return [BoundSqlLiteral] a new instance of BoundSqlLiteral + # + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#8 + def initialize(sql_with_placeholders, positional_binds, named_binds); end + + # @raise [ArgumentError] + # + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#54 + def +(other); end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#46 + def ==(other); end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#46 + def eql?(other); end + + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#42 + def hash; end + + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#60 + def inspect; end + + # Returns the value of attribute named_binds. + # + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#6 + def named_binds; end + + # Returns the value of attribute positional_binds. + # + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#6 + def positional_binds; end + + # Returns the value of attribute sql_with_placeholders. + # + # source://activerecord//lib/arel/nodes/bound_sql_literal.rb#6 + def sql_with_placeholders; end +end + # source://activerecord//lib/arel/nodes/case.rb#5 class Arel::Nodes::Case < ::Arel::Nodes::NodeExpression # @return [Case] a new instance of Case @@ -34935,6 +39297,44 @@ class Arel::Nodes::Count < ::Arel::Nodes::Function def initialize(expr, distinct = T.unsafe(nil), aliaz = T.unsafe(nil)); end end +# source://activerecord//lib/arel/nodes/cte.rb#5 +class Arel::Nodes::Cte < ::Arel::Nodes::Binary + # @return [Cte] a new instance of Cte + # + # source://activerecord//lib/arel/nodes/cte.rb#10 + def initialize(name, relation, materialized: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/cte.rb#19 + def ==(other); end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/cte.rb#19 + def eql?(other); end + + # source://activerecord//lib/arel/nodes/cte.rb#15 + def hash; end + + # Returns the value of attribute materialized. + # + # source://activerecord//lib/arel/nodes/cte.rb#8 + def materialized; end + + # source://activerecord//lib/arel/nodes/binary.rb#6 + def name; end + + # source://activerecord//lib/arel/nodes/binary.rb#6 + def relation; end + + # source://activerecord//lib/arel/nodes/cte.rb#27 + def to_cte; end + + # source://activerecord//lib/arel/nodes/cte.rb#31 + def to_table; end +end + # source://activerecord//lib/arel/nodes/unary.rb#41 class Arel::Nodes::Cube < ::Arel::Nodes::Unary; end @@ -35141,7 +39541,7 @@ class Arel::Nodes::Equality < ::Arel::Nodes::Binary def invert; end end -# source://activerecord//lib/arel/nodes/binary.rb#123 +# source://activerecord//lib/arel/nodes/binary.rb#122 class Arel::Nodes::Except < ::Arel::Nodes::Binary; end # source://activerecord//lib/arel/nodes/function.rb#42 @@ -35215,6 +39615,42 @@ class Arel::Nodes::Following < ::Arel::Nodes::Unary def initialize(expr = T.unsafe(nil)); end end +# source://activerecord//lib/arel/nodes/fragments.rb#5 +class Arel::Nodes::Fragments < ::Arel::Nodes::Node + # @return [Fragments] a new instance of Fragments + # + # source://activerecord//lib/arel/nodes/fragments.rb#8 + def initialize(values = T.unsafe(nil)); end + + # @raise [ArgumentError] + # + # source://activerecord//lib/arel/nodes/fragments.rb#22 + def +(other); end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/fragments.rb#28 + def ==(other); end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/fragments.rb#28 + def eql?(other); end + + # source://activerecord//lib/arel/nodes/fragments.rb#18 + def hash; end + + # Returns the value of attribute values. + # + # source://activerecord//lib/arel/nodes/fragments.rb#6 + def values; end + + private + + # source://activerecord//lib/arel/nodes/fragments.rb#13 + def initialize_copy(other); end +end + # source://activerecord//lib/arel/nodes/full_outer_join.rb#5 class Arel::Nodes::FullOuterJoin < ::Arel::Nodes::Join; end @@ -35281,19 +39717,19 @@ class Arel::Nodes::Function < ::Arel::Nodes::NodeExpression def hash; end end -# source://activerecord//lib/arel/nodes/binary.rb#44 +# source://activerecord//lib/arel/nodes/binary.rb#50 class Arel::Nodes::GreaterThan < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#47 + # source://activerecord//lib/arel/nodes/binary.rb#53 def invert; end end -# source://activerecord//lib/arel/nodes/binary.rb#52 +# source://activerecord//lib/arel/nodes/binary.rb#58 class Arel::Nodes::GreaterThanOrEqual < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#55 + # source://activerecord//lib/arel/nodes/binary.rb#61 def invert; end end @@ -35329,12 +39765,9 @@ class Arel::Nodes::HomogeneousIn < ::Arel::Nodes::Node # source://activerecord//lib/arel/nodes/homogeneous_in.rb#6 def attribute; end - # source://activerecord//lib/arel/nodes/homogeneous_in.rb#47 + # source://activerecord//lib/arel/nodes/homogeneous_in.rb#39 def casted_values; end - # source://activerecord//lib/arel/nodes/homogeneous_in.rb#43 - def column_name; end - # @return [Boolean] # # source://activerecord//lib/arel/nodes/homogeneous_in.rb#18 @@ -35345,7 +39778,7 @@ class Arel::Nodes::HomogeneousIn < ::Arel::Nodes::Node # source://activerecord//lib/arel/nodes/homogeneous_in.rb#23 def equality?; end - # source://activerecord//lib/arel/nodes/homogeneous_in.rb#62 + # source://activerecord//lib/arel/nodes/homogeneous_in.rb#54 def fetch_attribute(&block); end # source://activerecord//lib/arel/nodes/homogeneous_in.rb#14 @@ -35357,15 +39790,12 @@ class Arel::Nodes::HomogeneousIn < ::Arel::Nodes::Node # source://activerecord//lib/arel/nodes/homogeneous_in.rb#31 def left; end - # source://activerecord//lib/arel/nodes/homogeneous_in.rb#58 + # source://activerecord//lib/arel/nodes/homogeneous_in.rb#50 def proc_for_binds; end # source://activerecord//lib/arel/nodes/homogeneous_in.rb#35 def right; end - # source://activerecord//lib/arel/nodes/homogeneous_in.rb#39 - def table_name; end - # Returns the value of attribute type. # # source://activerecord//lib/arel/nodes/homogeneous_in.rb#6 @@ -35378,7 +39808,7 @@ class Arel::Nodes::HomogeneousIn < ::Arel::Nodes::Node protected - # source://activerecord//lib/arel/nodes/homogeneous_in.rb#71 + # source://activerecord//lib/arel/nodes/homogeneous_in.rb#63 def ivars; end end @@ -35485,26 +39915,26 @@ class Arel::Nodes::InsertStatement < ::Arel::Nodes::Node def initialize_copy(other); end end -# source://activerecord//lib/arel/nodes/binary.rb#123 +# source://activerecord//lib/arel/nodes/binary.rb#122 class Arel::Nodes::Intersect < ::Arel::Nodes::Binary; end -# source://activerecord//lib/arel/nodes/binary.rb#76 +# source://activerecord//lib/arel/nodes/binary.rb#82 class Arel::Nodes::IsDistinctFrom < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#79 + # source://activerecord//lib/arel/nodes/binary.rb#85 def invert; end end -# source://activerecord//lib/arel/nodes/binary.rb#84 +# source://activerecord//lib/arel/nodes/binary.rb#90 class Arel::Nodes::IsNotDistinctFrom < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#87 + # source://activerecord//lib/arel/nodes/binary.rb#93 def invert; end end -# source://activerecord//lib/arel/nodes/binary.rb#123 +# source://activerecord//lib/arel/nodes/binary.rb#122 class Arel::Nodes::Join < ::Arel::Nodes::Binary; end # Class that represents a join source @@ -35527,22 +39957,22 @@ end # source://activerecord//lib/arel/nodes/unary.rb#41 class Arel::Nodes::Lateral < ::Arel::Nodes::Unary; end -# source://activerecord//lib/active_record/relation/query_methods.rb#1420 +# source://activerecord//lib/arel/nodes/leading_join.rb#5 class Arel::Nodes::LeadingJoin < ::Arel::Nodes::InnerJoin; end -# source://activerecord//lib/arel/nodes/binary.rb#60 +# source://activerecord//lib/arel/nodes/binary.rb#66 class Arel::Nodes::LessThan < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#63 + # source://activerecord//lib/arel/nodes/binary.rb#69 def invert; end end -# source://activerecord//lib/arel/nodes/binary.rb#68 +# source://activerecord//lib/arel/nodes/binary.rb#74 class Arel::Nodes::LessThanOrEqual < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#71 + # source://activerecord//lib/arel/nodes/binary.rb#77 def invert; end end @@ -35662,38 +40092,183 @@ class Arel::Nodes::NamedWindow < ::Arel::Nodes::Window def initialize_copy(other); end end -# Abstract base class for all AST nodes +# source://activerecord//lib/arel/nodes/nary.rb#5 +class Arel::Nodes::Nary < ::Arel::Nodes::NodeExpression + # @return [Nary] a new instance of Nary + # + # source://activerecord//lib/arel/nodes/nary.rb#8 + def initialize(children); end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/nary.rb#29 + def ==(other); end + + # Returns the value of attribute children. + # + # source://activerecord//lib/arel/nodes/nary.rb#6 + def children; end + + # @return [Boolean] + # + # source://activerecord//lib/arel/nodes/nary.rb#29 + def eql?(other); end + + # source://activerecord//lib/arel/nodes/nary.rb#21 + def fetch_attribute(&block); end + + # source://activerecord//lib/arel/nodes/nary.rb#25 + def hash; end + + # source://activerecord//lib/arel/nodes/nary.rb#13 + def left; end + + # source://activerecord//lib/arel/nodes/nary.rb#17 + def right; end +end + +# = Using +Arel::Nodes::Node+ +# +# Active Record uses Arel to compose SQL statements. Instead of building SQL strings directly, it's building an +# abstract syntax tree (AST) of the statement using various types of Arel::Nodes::Node. Each node represents a +# fragment of a SQL statement. +# +# The intermediate representation allows Arel to compile the statement into the database's specific SQL dialect +# only before sending it without having to care about the nuances of each database when building the statement. +# It also allows easier composition of statements without having to resort to (brittle and unsafe) string manipulation. +# +# == Building constraints +# +# One of the most common use cases of Arel is generating constraints for +SELECT+ statements. To help with that, +# most nodes include a couple of useful factory methods to create subtree structures for common constraints. For +# a full list of those, please refer to Arel::Predications. +# +# The following example creates an equality constraint where the value of the name column on the users table +# matches the value DHH. +# +# users = Arel::Table.new(:users) +# constraint = users[:name].eq("DHH") +# +# # => Arel::Nodes::Equality.new( +# # Arel::Attributes::Attribute.new(users, "name"), +# # Arel::Nodes::Casted.new( +# # "DHH", +# # Arel::Attributes::Attribute.new(users, "name") +# # ) +# # ) +# +# The resulting SQL fragment will look like this: +# +# "users"."name" = 'DHH' +# +# The constraint fragments can be used with regular ActiveRecord::Relation objects instead of a Hash. The +# following two examples show two ways of creating the same query. +# +# User.where(name: 'DHH') +# +# # SELECT "users".* FROM "users" WHERE "users"."name" = 'DHH' +# +# users = User.arel_table +# +# User.where(users[:name].eq('DHH')) +# +# # SELECT "users".* FROM "users" WHERE "users"."name" = 'DHH' +# +# == Functions +# +# Arel comes with built-in support for SQL functions like +COUNT+, +SUM+, +MIN+, +MAX+, and +AVG+. The +# Arel::Expressions module includes factory methods for the default functions. +# +# employees = Employee.arel_table +# +# Employee.select(employees[:department_id], employees[:salary].average).group(employees[:department_id]) +# +# # SELECT "employees"."department_id", AVG("employees"."salary") +# # FROM "employees" GROUP BY "employees"."department_id" +# +# It’s also possible to use custom functions by using the Arel::Nodes::NamedFunction node type. It accepts a +# function name and an array of parameters. # -# source://activerecord//lib/arel/nodes/node.rb#7 +# Arel::Nodes::NamedFunction.new('date_trunc', [Arel::Nodes.build_quoted('day'), User.arel_table[:created_at]]) +# +# # date_trunc('day', "users"."created_at") +# +# == Quoting & bind params +# +# Values that you pass to Arel nodes need to be quoted or wrapped in bind params. This ensures they are properly +# converted into the correct format without introducing a possible SQL injection vulnerability. Most factory +# methods (like +eq+, +gt+, +lteq+, …) quote passed values automatically. When not using a factory method, it’s +# possible to convert a value and wrap it in an Arel::Nodes::Quoted node (if necessary) by calling +Arel::Nodes. +# build_quoted+. +# +# Arel::Nodes.build_quoted("foo") # 'foo' +# Arel::Nodes.build_quoted(12.3) # 12.3 +# +# Instead of quoting values and embedding them directly in the SQL statement, it’s also possible to create bind +# params. This keeps the actual values outside of the statement and allows using the prepared statement feature +# of some databases. +# +# attribute = ActiveRecord::Relation::QueryAttribute.new(:name, "DHH", ActiveRecord::Type::String.new) +# Arel::Nodes::BindParam.new(attribute) +# +# When ActiveRecord runs the query, bind params are replaced by placeholders (like +$1+) and the values are passed +# separately. +# +# == SQL Literals +# +# For cases where there is no way to represent a particular SQL fragment using Arel nodes, you can use an SQL +# literal. SQL literals are strings that Arel will treat “as is”. +# +# Arel.sql('LOWER("users"."name")').eq('dhh') +# +# # LOWER("users"."name") = 'dhh' +# +# Please keep in mind that passing data as raw SQL literals might introduce a possible SQL injection. However, +# `Arel.sql` supports binding parameters which will ensure proper quoting. This can be useful when you need to +# control the exact SQL you run, but you still have potentially user-supplied values. +# +# Arel.sql('LOWER("users"."name") = ?', 'dhh') +# +# # LOWER("users"."name") = 'dhh' +# +# You can also combine SQL literals. +# +# sql = Arel.sql('SELECT * FROM "users" WHERE ') +# sql += Arel.sql('LOWER("users"."name") = :name', name: 'dhh') +# sql += Arel.sql('AND "users"."age" > :age', age: 35) +# +# # SELECT * FROM "users" WHERE LOWER("users"."name") = 'dhh' AND "users"."age" > '35' +# +# source://activerecord//lib/arel/nodes/node.rb#116 class Arel::Nodes::Node include ::Arel::FactoryMethods # Factory method to create an Nodes::And node. # - # source://activerecord//lib/arel/nodes/node.rb#26 + # source://activerecord//lib/arel/nodes/node.rb#135 def and(right); end # @return [Boolean] # - # source://activerecord//lib/arel/nodes/node.rb#48 + # source://activerecord//lib/arel/nodes/node.rb#158 def equality?; end - # source://activerecord//lib/arel/nodes/node.rb#45 + # source://activerecord//lib/arel/nodes/node.rb#155 def fetch_attribute; end - # source://activerecord//lib/arel/nodes/node.rb#30 + # source://activerecord//lib/arel/nodes/node.rb#139 def invert; end # Factory method to create a Nodes::Not node that has the recipient of # the caller as a child. # - # source://activerecord//lib/arel/nodes/node.rb#13 + # source://activerecord//lib/arel/nodes/node.rb#122 def not; end # Factory method to create a Nodes::Grouping node that has an Nodes::Or # node as a child. # - # source://activerecord//lib/arel/nodes/node.rb#20 + # source://activerecord//lib/arel/nodes/node.rb#129 def or(right); end # FIXME: this method should go away. I don't like people calling @@ -35702,7 +40277,7 @@ class Arel::Nodes::Node # # Maybe we should just use `Table.engine`? :'( # - # source://activerecord//lib/arel/nodes/node.rb#39 + # source://activerecord//lib/arel/nodes/node.rb#148 def to_sql(engine = T.unsafe(nil)); end end @@ -35718,19 +40293,19 @@ end # source://activerecord//lib/arel/nodes/unary.rb#41 class Arel::Nodes::Not < ::Arel::Nodes::Unary; end -# source://activerecord//lib/arel/nodes/binary.rb#92 +# source://activerecord//lib/arel/nodes/binary.rb#98 class Arel::Nodes::NotEqual < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#95 + # source://activerecord//lib/arel/nodes/binary.rb#101 def invert; end end -# source://activerecord//lib/arel/nodes/binary.rb#100 +# source://activerecord//lib/arel/nodes/binary.rb#106 class Arel::Nodes::NotIn < ::Arel::Nodes::Binary include ::Arel::Nodes::FetchAttribute - # source://activerecord//lib/arel/nodes/binary.rb#103 + # source://activerecord//lib/arel/nodes/binary.rb#109 def invert; end end @@ -35758,11 +40333,8 @@ class Arel::Nodes::On < ::Arel::Nodes::Unary; end # source://activerecord//lib/arel/nodes/unary.rb#41 class Arel::Nodes::OptimizerHints < ::Arel::Nodes::Unary; end -# source://activerecord//lib/arel/nodes/binary.rb#108 -class Arel::Nodes::Or < ::Arel::Nodes::Binary - # source://activerecord//lib/arel/nodes/binary.rb#109 - def fetch_attribute(&block); end -end +# source://activerecord//lib/arel/nodes/nary.rb#37 +class Arel::Nodes::Or < ::Arel::Nodes::Nary; end # source://activerecord//lib/arel/nodes/ordering.rb#5 class Arel::Nodes::Ordering < ::Arel::Nodes::Unary @@ -36108,11 +40680,26 @@ class Arel::Nodes::SqlLiteral < ::String include ::Arel::AliasPredication include ::Arel::OrderPredications - # source://activerecord//lib/arel/nodes/sql_literal.rb#11 + # @return [SqlLiteral] a new instance of SqlLiteral + # + # source://activerecord//lib/arel/nodes/sql_literal.rb#13 + def initialize(string, retryable: T.unsafe(nil)); end + + # @raise [ArgumentError] + # + # source://activerecord//lib/arel/nodes/sql_literal.rb#25 + def +(other); end + + # source://activerecord//lib/arel/nodes/sql_literal.rb#18 def encode_with(coder); end - # source://activerecord//lib/arel/nodes/sql_literal.rb#15 + # source://activerecord//lib/arel/nodes/sql_literal.rb#22 def fetch_attribute; end + + # Returns the value of attribute retryable. + # + # source://activerecord//lib/arel/nodes/sql_literal.rb#11 + def retryable; end end # source://activerecord//lib/arel/nodes/string_join.rb#5 @@ -36156,6 +40743,9 @@ class Arel::Nodes::TableAlias < ::Arel::Nodes::Binary # source://activerecord//lib/arel/nodes/table_alias.rb#14 def table_name; end + # source://activerecord//lib/arel/nodes/table_alias.rb#30 + def to_cte; end + # source://activerecord//lib/arel/nodes/table_alias.rb#18 def type_cast_for_database(attr_name, value); end @@ -36230,10 +40820,10 @@ class Arel::Nodes::UnaryOperation < ::Arel::Nodes::Unary def operator; end end -# source://activerecord//lib/arel/nodes/binary.rb#123 +# source://activerecord//lib/arel/nodes/binary.rb#122 class Arel::Nodes::Union < ::Arel::Nodes::Binary; end -# source://activerecord//lib/arel/nodes/binary.rb#123 +# source://activerecord//lib/arel/nodes/binary.rb#122 class Arel::Nodes::UnionAll < ::Arel::Nodes::Binary; end # source://activerecord//lib/arel/nodes/unqualified_column.rb#5 @@ -36497,22 +41087,22 @@ module Arel::Predications # source://activerecord//lib/arel/predications.rb#37 def between(other); end - # source://activerecord//lib/arel/predications.rb#213 + # source://activerecord//lib/arel/predications.rb#215 def concat(other); end - # source://activerecord//lib/arel/predications.rb#217 + # source://activerecord//lib/arel/predications.rb#219 def contains(other); end - # source://activerecord//lib/arel/predications.rb#145 + # source://activerecord//lib/arel/predications.rb#147 def does_not_match(other, escape = T.unsafe(nil), case_sensitive = T.unsafe(nil)); end - # source://activerecord//lib/arel/predications.rb#157 + # source://activerecord//lib/arel/predications.rb#159 def does_not_match_all(others, escape = T.unsafe(nil)); end - # source://activerecord//lib/arel/predications.rb#153 + # source://activerecord//lib/arel/predications.rb#155 def does_not_match_any(others, escape = T.unsafe(nil)); end - # source://activerecord//lib/arel/predications.rb#149 + # source://activerecord//lib/arel/predications.rb#151 def does_not_match_regexp(other, case_sensitive = T.unsafe(nil)); end # source://activerecord//lib/arel/predications.rb#17 @@ -36524,31 +41114,31 @@ module Arel::Predications # source://activerecord//lib/arel/predications.rb#29 def eq_any(others); end - # source://activerecord//lib/arel/predications.rb#173 + # source://activerecord//lib/arel/predications.rb#175 def gt(right); end - # source://activerecord//lib/arel/predications.rb#181 + # source://activerecord//lib/arel/predications.rb#183 def gt_all(others); end - # source://activerecord//lib/arel/predications.rb#177 + # source://activerecord//lib/arel/predications.rb#179 def gt_any(others); end - # source://activerecord//lib/arel/predications.rb#161 + # source://activerecord//lib/arel/predications.rb#163 def gteq(right); end - # source://activerecord//lib/arel/predications.rb#169 + # source://activerecord//lib/arel/predications.rb#171 def gteq_all(others); end - # source://activerecord//lib/arel/predications.rb#165 + # source://activerecord//lib/arel/predications.rb#167 def gteq_any(others); end - # source://activerecord//lib/arel/predications.rb#63 + # source://activerecord//lib/arel/predications.rb#65 def in(other); end - # source://activerecord//lib/arel/predications.rb#78 + # source://activerecord//lib/arel/predications.rb#80 def in_all(others); end - # source://activerecord//lib/arel/predications.rb#74 + # source://activerecord//lib/arel/predications.rb#76 def in_any(others); end # source://activerecord//lib/arel/predications.rb#25 @@ -36557,37 +41147,37 @@ module Arel::Predications # source://activerecord//lib/arel/predications.rb#21 def is_not_distinct_from(other); end - # source://activerecord//lib/arel/predications.rb#185 + # source://activerecord//lib/arel/predications.rb#187 def lt(right); end - # source://activerecord//lib/arel/predications.rb#193 + # source://activerecord//lib/arel/predications.rb#195 def lt_all(others); end - # source://activerecord//lib/arel/predications.rb#189 + # source://activerecord//lib/arel/predications.rb#191 def lt_any(others); end - # source://activerecord//lib/arel/predications.rb#197 + # source://activerecord//lib/arel/predications.rb#199 def lteq(right); end - # source://activerecord//lib/arel/predications.rb#205 + # source://activerecord//lib/arel/predications.rb#207 def lteq_all(others); end - # source://activerecord//lib/arel/predications.rb#201 + # source://activerecord//lib/arel/predications.rb#203 def lteq_any(others); end - # source://activerecord//lib/arel/predications.rb#129 + # source://activerecord//lib/arel/predications.rb#131 def matches(other, escape = T.unsafe(nil), case_sensitive = T.unsafe(nil)); end - # source://activerecord//lib/arel/predications.rb#141 + # source://activerecord//lib/arel/predications.rb#143 def matches_all(others, escape = T.unsafe(nil), case_sensitive = T.unsafe(nil)); end - # source://activerecord//lib/arel/predications.rb#137 + # source://activerecord//lib/arel/predications.rb#139 def matches_any(others, escape = T.unsafe(nil), case_sensitive = T.unsafe(nil)); end - # source://activerecord//lib/arel/predications.rb#133 + # source://activerecord//lib/arel/predications.rb#135 def matches_regexp(other, case_sensitive = T.unsafe(nil)); end - # source://activerecord//lib/arel/predications.rb#82 + # source://activerecord//lib/arel/predications.rb#84 def not_between(other); end # source://activerecord//lib/arel/predications.rb#5 @@ -36599,48 +41189,48 @@ module Arel::Predications # source://activerecord//lib/arel/predications.rb#9 def not_eq_any(others); end - # source://activerecord//lib/arel/predications.rb#110 + # source://activerecord//lib/arel/predications.rb#112 def not_in(other); end - # source://activerecord//lib/arel/predications.rb#125 + # source://activerecord//lib/arel/predications.rb#127 def not_in_all(others); end - # source://activerecord//lib/arel/predications.rb#121 + # source://activerecord//lib/arel/predications.rb#123 def not_in_any(others); end - # source://activerecord//lib/arel/predications.rb#221 + # source://activerecord//lib/arel/predications.rb#223 def overlaps(other); end - # source://activerecord//lib/arel/predications.rb#225 + # source://activerecord//lib/arel/predications.rb#227 def quoted_array(others); end - # source://activerecord//lib/arel/predications.rb#209 + # source://activerecord//lib/arel/predications.rb#211 def when(right); end private - # source://activerecord//lib/arel/predications.rb#237 + # source://activerecord//lib/arel/predications.rb#239 def grouping_all(method_id, others, *extras); end - # source://activerecord//lib/arel/predications.rb#230 + # source://activerecord//lib/arel/predications.rb#232 def grouping_any(method_id, others, *extras); end # @return [Boolean] # - # source://activerecord//lib/arel/predications.rb#246 + # source://activerecord//lib/arel/predications.rb#248 def infinity?(value); end # @return [Boolean] # - # source://activerecord//lib/arel/predications.rb#254 + # source://activerecord//lib/arel/predications.rb#256 def open_ended?(value); end - # source://activerecord//lib/arel/predications.rb#242 + # source://activerecord//lib/arel/predications.rb#244 def quoted_node(other); end # @return [Boolean] # - # source://activerecord//lib/arel/predications.rb#250 + # source://activerecord//lib/arel/predications.rb#252 def unboundable?(value); end end @@ -36791,43 +41381,43 @@ class Arel::Table # @return [Table] a new instance of Table # - # source://activerecord//lib/arel/table.rb#16 + # source://activerecord//lib/arel/table.rb#14 def initialize(name, as: T.unsafe(nil), klass: T.unsafe(nil), type_caster: T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/arel/table.rb#95 + # source://activerecord//lib/arel/table.rb#99 def ==(other); end - # source://activerecord//lib/arel/table.rb#82 + # source://activerecord//lib/arel/table.rb#86 def [](name, table = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/arel/table.rb#110 + # source://activerecord//lib/arel/table.rb#114 def able_to_type_cast?; end - # source://activerecord//lib/arel/table.rb#30 + # source://activerecord//lib/arel/table.rb#34 def alias(name = T.unsafe(nil)); end # @return [Boolean] # - # source://activerecord//lib/arel/table.rb#95 + # source://activerecord//lib/arel/table.rb#99 def eql?(other); end - # source://activerecord//lib/arel/table.rb#34 + # source://activerecord//lib/arel/table.rb#38 def from; end - # source://activerecord//lib/arel/table.rb#54 + # source://activerecord//lib/arel/table.rb#58 def group(*columns); end - # source://activerecord//lib/arel/table.rb#88 + # source://activerecord//lib/arel/table.rb#92 def hash; end - # source://activerecord//lib/arel/table.rb#78 + # source://activerecord//lib/arel/table.rb#82 def having(expr); end - # source://activerecord//lib/arel/table.rb#38 + # source://activerecord//lib/arel/table.rb#42 def join(relation, klass = T.unsafe(nil)); end # Returns the value of attribute name. @@ -36842,53 +41432,40 @@ class Arel::Table # source://activerecord//lib/arel/table.rb#11 def name=(_arg0); end - # source://activerecord//lib/arel/table.rb#58 + # source://activerecord//lib/arel/table.rb#62 def order(*expr); end - # source://activerecord//lib/arel/table.rb#50 + # source://activerecord//lib/arel/table.rb#54 def outer_join(relation); end - # source://activerecord//lib/arel/table.rb#66 + # source://activerecord//lib/arel/table.rb#70 def project(*things); end - # source://activerecord//lib/arel/table.rb#74 + # source://activerecord//lib/arel/table.rb#78 def skip(amount); end # Returns the value of attribute table_alias. # - # source://activerecord//lib/arel/table.rb#11 + # source://activerecord//lib/arel/table.rb#12 def table_alias; end - # Sets the attribute table_alias - # - # @param value the value to set the attribute table_alias to. - # - # source://activerecord//lib/arel/table.rb#11 - def table_alias=(_arg0); end - - # Returns the value of attribute name. - # TableAlias and Table both have a #table_name which is the name of the underlying table - # - # source://activerecord//lib/arel/table.rb#11 - def table_name; end - - # source://activerecord//lib/arel/table.rb#70 + # source://activerecord//lib/arel/table.rb#74 def take(amount); end - # source://activerecord//lib/arel/table.rb#102 + # source://activerecord//lib/arel/table.rb#106 def type_cast_for_database(attr_name, value); end - # source://activerecord//lib/arel/table.rb#106 + # source://activerecord//lib/arel/table.rb#110 def type_for_attribute(name); end - # source://activerecord//lib/arel/table.rb#62 + # source://activerecord//lib/arel/table.rb#66 def where(condition); end private # Returns the value of attribute type_caster. # - # source://activerecord//lib/arel/table.rb#115 + # source://activerecord//lib/arel/table.rb#119 def type_caster; end class << self @@ -36912,24 +41489,24 @@ class Arel::TreeManager # Returns the value of attribute ast. # - # source://activerecord//lib/arel/tree_manager.rb#41 + # source://activerecord//lib/arel/tree_manager.rb#45 def ast; end - # source://activerecord//lib/arel/tree_manager.rb#43 + # source://activerecord//lib/arel/tree_manager.rb#47 def to_dot; end - # source://activerecord//lib/arel/tree_manager.rb#49 + # source://activerecord//lib/arel/tree_manager.rb#53 def to_sql(engine = T.unsafe(nil)); end private - # source://activerecord//lib/arel/tree_manager.rb#55 + # source://activerecord//lib/arel/tree_manager.rb#60 def initialize_copy(other); end end # source://activerecord//lib/arel/tree_manager.rb#7 module Arel::TreeManager::StatementMethods - # source://activerecord//lib/arel/tree_manager.rb#27 + # source://activerecord//lib/arel/tree_manager.rb#31 def key; end # source://activerecord//lib/arel/tree_manager.rb#23 @@ -36944,10 +41521,10 @@ module Arel::TreeManager::StatementMethods # source://activerecord//lib/arel/tree_manager.rb#8 def take(limit); end - # source://activerecord//lib/arel/tree_manager.rb#35 + # source://activerecord//lib/arel/tree_manager.rb#39 def where(expr); end - # source://activerecord//lib/arel/tree_manager.rb#31 + # source://activerecord//lib/arel/tree_manager.rb#35 def wheres=(exprs); end end @@ -36960,10 +41537,10 @@ class Arel::UpdateManager < ::Arel::TreeManager # source://activerecord//lib/arel/update_manager.rb#7 def initialize(table = T.unsafe(nil)); end - # source://activerecord//lib/arel/update_manager.rb#32 + # source://activerecord//lib/arel/update_manager.rb#33 def group(columns); end - # source://activerecord//lib/arel/update_manager.rb#43 + # source://activerecord//lib/arel/update_manager.rb#44 def having(expr); end # source://activerecord//lib/arel/update_manager.rb#18 @@ -36993,19 +41570,19 @@ class Arel::Visitors::Dot < ::Arel::Visitors::Visitor private - # source://activerecord//lib/arel/visitors/dot.rb#260 + # source://activerecord//lib/arel/visitors/dot.rb#261 def edge(name); end - # source://activerecord//lib/arel/visitors/dot.rb#278 + # source://activerecord//lib/arel/visitors/dot.rb#279 def quote(string); end - # source://activerecord//lib/arel/visitors/dot.rb#282 + # source://activerecord//lib/arel/visitors/dot.rb#283 def to_dot; end - # source://activerecord//lib/arel/visitors/dot.rb#246 + # source://activerecord//lib/arel/visitors/dot.rb#247 def visit(o); end - # source://activerecord//lib/arel/visitors/dot.rb#215 + # source://activerecord//lib/arel/visitors/dot.rb#216 def visit_ActiveModel_Attribute(o); end # source://activerecord//lib/arel/visitors/dot.rb#183 @@ -37017,16 +41594,16 @@ class Arel::Visitors::Dot < ::Arel::Visitors::Visitor # source://activerecord//lib/arel/visitors/dot.rb#44 def visit_Arel_Nodes_Binary(o); end - # source://activerecord//lib/arel/visitors/dot.rb#211 + # source://activerecord//lib/arel/visitors/dot.rb#212 def visit_Arel_Nodes_BindParam(o); end - # source://activerecord//lib/arel/visitors/dot.rb#236 + # source://activerecord//lib/arel/visitors/dot.rb#237 def visit_Arel_Nodes_Case(o); end # source://activerecord//lib/arel/visitors/dot.rb#172 def visit_Arel_Nodes_Casted(o); end - # source://activerecord//lib/arel/visitors/dot.rb#232 + # source://activerecord//lib/arel/visitors/dot.rb#233 def visit_Arel_Nodes_Comment(o); end # source://activerecord//lib/arel/visitors/dot.rb#77 @@ -37067,6 +41644,9 @@ class Arel::Visitors::Dot < ::Arel::Visitors::Visitor # source://activerecord//lib/arel/visitors/dot.rb#60 def visit_Arel_Nodes_NotRegexp(o); end + # source://activerecord//lib/arel/visitors/dot.rb#188 + def visit_Arel_Nodes_Or(o); end + # source://activerecord//lib/arel/visitors/dot.rb#68 def visit_Arel_Nodes_Ordering(o); end @@ -37079,7 +41659,7 @@ class Arel::Visitors::Dot < ::Arel::Visitors::Visitor # source://activerecord//lib/arel/visitors/dot.rb#140 def visit_Arel_Nodes_SelectStatement(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_Arel_Nodes_SqlLiteral(o); end # source://activerecord//lib/arel/visitors/dot.rb#86 @@ -37109,46 +41689,46 @@ class Arel::Visitors::Dot < ::Arel::Visitors::Visitor # source://activerecord//lib/arel/visitors/dot.rb#168 def visit_Arel_Table(o); end - # source://activerecord//lib/arel/visitors/dot.rb#225 + # source://activerecord//lib/arel/visitors/dot.rb#226 def visit_Array(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_BigDecimal(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_Date(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_DateTime(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_FalseClass(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_Float(o); end - # source://activerecord//lib/arel/visitors/dot.rb#219 + # source://activerecord//lib/arel/visitors/dot.rb#220 def visit_Hash(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_Integer(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_NilClass(o); end - # source://activerecord//lib/arel/visitors/dot.rb#225 + # source://activerecord//lib/arel/visitors/dot.rb#226 def visit_Set(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_String(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_Symbol(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_Time(o); end - # source://activerecord//lib/arel/visitors/dot.rb#196 + # source://activerecord//lib/arel/visitors/dot.rb#197 def visit_TrueClass(o); end # source://activerecord//lib/arel/visitors/dot.rb#188 @@ -37160,10 +41740,10 @@ class Arel::Visitors::Dot < ::Arel::Visitors::Visitor # source://activerecord//lib/arel/visitors/dot.rb#60 def visit__regexp(o); end - # source://activerecord//lib/arel/visitors/dot.rb#242 + # source://activerecord//lib/arel/visitors/dot.rb#243 def visit_edge(o, method); end - # source://activerecord//lib/arel/visitors/dot.rb#268 + # source://activerecord//lib/arel/visitors/dot.rb#269 def with_node(node); end end @@ -37221,47 +41801,51 @@ class Arel::Visitors::MySQL < ::Arel::Visitors::ToSql # MySQL doesn't automatically create a temporary table for use subquery, so we have # to give it some prompting in the form of a subsubquery. # - # source://activerecord//lib/arel/visitors/mysql.rb#81 + # source://activerecord//lib/arel/visitors/mysql.rb#93 def build_subselect(key, o); end # In the simple case, MySQL allows us to place JOINs directly into the UPDATE # query. However, this does not allow for LIMIT, OFFSET and ORDER. To support # these, we must use a subquery. # - # source://activerecord//lib/arel/visitors/mysql.rb#69 + # source://activerecord//lib/arel/visitors/mysql.rb#81 def prepare_delete_statement(o); end # In the simple case, MySQL allows us to place JOINs directly into the UPDATE # query. However, this does not allow for LIMIT, OFFSET and ORDER. To support # these, we must use a subquery. # - # source://activerecord//lib/arel/visitors/mysql.rb#69 + # source://activerecord//lib/arel/visitors/mysql.rb#81 def prepare_update_statement(o); end # source://activerecord//lib/arel/visitors/mysql.rb#7 def visit_Arel_Nodes_Bin(o, collector); end - # source://activerecord//lib/arel/visitors/mysql.rb#33 + # source://activerecord//lib/arel/visitors/mysql.rb#34 def visit_Arel_Nodes_Concat(o, collector); end - # source://activerecord//lib/arel/visitors/mysql.rb#48 + # source://activerecord//lib/arel/visitors/mysql.rb#72 + def visit_Arel_Nodes_Cte(o, collector); end + + # source://activerecord//lib/arel/visitors/mysql.rb#49 def visit_Arel_Nodes_IsDistinctFrom(o, collector); end - # source://activerecord//lib/arel/visitors/mysql.rb#42 + # source://activerecord//lib/arel/visitors/mysql.rb#43 def visit_Arel_Nodes_IsNotDistinctFrom(o, collector); end - # source://activerecord//lib/arel/visitors/mysql.rb#57 + # source://activerecord//lib/arel/visitors/mysql.rb#58 def visit_Arel_Nodes_NotRegexp(o, collector); end - # no-op - # # source://activerecord//lib/arel/visitors/mysql.rb#62 def visit_Arel_Nodes_NullsFirst(o, collector); end - # source://activerecord//lib/arel/visitors/mysql.rb#53 + # source://activerecord//lib/arel/visitors/mysql.rb#67 + def visit_Arel_Nodes_NullsLast(o, collector); end + + # source://activerecord//lib/arel/visitors/mysql.rb#54 def visit_Arel_Nodes_Regexp(o, collector); end - # source://activerecord//lib/arel/visitors/mysql.rb#28 + # source://activerecord//lib/arel/visitors/mysql.rb#29 def visit_Arel_Nodes_SelectCore(o, collector); end # :'( @@ -37269,10 +41853,10 @@ class Arel::Visitors::MySQL < ::Arel::Visitors::ToSql # you can use some large number for the second parameter. # https://dev.mysql.com/doc/refman/en/select.html # - # source://activerecord//lib/arel/visitors/mysql.rb#21 + # source://activerecord//lib/arel/visitors/mysql.rb#22 def visit_Arel_Nodes_SelectStatement(o, collector); end - # source://activerecord//lib/arel/visitors/mysql.rb#12 + # source://activerecord//lib/arel/visitors/mysql.rb#13 def visit_Arel_Nodes_UnqualifiedColumn(o, collector); end end @@ -37286,14 +41870,9 @@ class Arel::Visitors::PostgreSQL < ::Arel::Visitors::ToSql # Utilized by GroupingSet, Cube & RollUp visitors to # handle grouping aggregation semantics # - # source://activerecord//lib/arel/visitors/postgresql.rb#99 + # source://activerecord//lib/arel/visitors/postgresql.rb#88 def grouping_array_or_grouping_element(o, collector); end - # Used by Lateral visitor to enclose select queries in parentheses - # - # source://activerecord//lib/arel/visitors/postgresql.rb#87 - def grouping_parentheses(o, collector); end - # source://activerecord//lib/arel/visitors/postgresql.rb#49 def visit_Arel_Nodes_Cube(o, collector); end @@ -37371,162 +41950,178 @@ class Arel::Visitors::ToSql < ::Arel::Visitors::Visitor private - # source://activerecord//lib/arel/visitors/to_sql.rb#906 + # source://activerecord//lib/arel/visitors/to_sql.rb#996 def aggregate(name, o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#740 + # source://activerecord//lib/arel/visitors/to_sql.rb#754 def bind_block; end # FIXME: we should probably have a 2-pass visitor for this # - # source://activerecord//lib/arel/visitors/to_sql.rb#869 + # source://activerecord//lib/arel/visitors/to_sql.rb#943 def build_subselect(key, o); end - # source://activerecord//lib/arel/visitors/to_sql.rb#933 + # source://activerecord//lib/arel/visitors/to_sql.rb#1023 def collect_ctes(children, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#176 + # source://activerecord//lib/arel/visitors/to_sql.rb#179 def collect_nodes_for(nodes, collector, spacer, connector = T.unsafe(nil)); end - # source://activerecord//lib/arel/visitors/to_sql.rb#814 + # source://activerecord//lib/arel/visitors/to_sql.rb#887 def collect_optimizer_hints(o, collector); end + # Used by some visitors to enclose select queries in parentheses + # + # source://activerecord//lib/arel/visitors/to_sql.rb#981 + def grouping_parentheses(o, collector, always_wrap_selects = T.unsafe(nil)); end + # @return [Boolean] # - # source://activerecord//lib/arel/visitors/to_sql.rb#844 + # source://activerecord//lib/arel/visitors/to_sql.rb#917 def has_group_by_and_having?(o); end # @return [Boolean] # - # source://activerecord//lib/arel/visitors/to_sql.rb#836 + # source://activerecord//lib/arel/visitors/to_sql.rb#909 def has_join_sources?(o); end # @return [Boolean] # - # source://activerecord//lib/arel/visitors/to_sql.rb#840 + # source://activerecord//lib/arel/visitors/to_sql.rb#913 def has_limit_or_offset_or_orders?(o); end - # source://activerecord//lib/arel/visitors/to_sql.rb#883 + # source://activerecord//lib/arel/visitors/to_sql.rb#957 def infix_value(o, collector, value); end - # source://activerecord//lib/arel/visitors/to_sql.rb#889 + # source://activerecord//lib/arel/visitors/to_sql.rb#963 def infix_value_with_paren(o, collector, value, suppress_parens = T.unsafe(nil)); end - # source://activerecord//lib/arel/visitors/to_sql.rb#824 + # source://activerecord//lib/arel/visitors/to_sql.rb#897 def inject_join(list, collector, join_str); end - # source://activerecord//lib/arel/visitors/to_sql.rb#920 + # source://activerecord//lib/arel/visitors/to_sql.rb#1010 def is_distinct_from(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#818 + # source://activerecord//lib/arel/visitors/to_sql.rb#891 def maybe_visit(thing, collector); end # The default strategy for an UPDATE with joins is to use a subquery. This doesn't work # on MySQL (even when aliasing the tables), but MySQL allows using JOIN directly in # an UPDATE statement, so in the MySQL visitor we redefine this to do that. # - # source://activerecord//lib/arel/visitors/to_sql.rb#851 + # source://activerecord//lib/arel/visitors/to_sql.rb#924 def prepare_delete_statement(o); end # The default strategy for an UPDATE with joins is to use a subquery. This doesn't work # on MySQL (even when aliasing the tables), but MySQL allows using JOIN directly in # an UPDATE statement, so in the MySQL visitor we redefine this to do that. # - # source://activerecord//lib/arel/visitors/to_sql.rb#851 + # source://activerecord//lib/arel/visitors/to_sql.rb#924 def prepare_update_statement(o); end - # source://activerecord//lib/arel/visitors/to_sql.rb#794 + # source://activerecord//lib/arel/visitors/to_sql.rb#867 def quote(value); end - # source://activerecord//lib/arel/visitors/to_sql.rb#804 + # source://activerecord//lib/arel/visitors/to_sql.rb#877 def quote_column_name(name); end - # source://activerecord//lib/arel/visitors/to_sql.rb#799 + # source://activerecord//lib/arel/visitors/to_sql.rb#872 def quote_table_name(name); end - # source://activerecord//lib/arel/visitors/to_sql.rb#809 + # @return [Boolean] + # + # source://activerecord//lib/arel/visitors/to_sql.rb#992 + def require_parentheses?(o); end + + # source://activerecord//lib/arel/visitors/to_sql.rb#882 def sanitize_as_sql_comment(value); end # @return [Boolean] # - # source://activerecord//lib/arel/visitors/to_sql.rb#832 + # source://activerecord//lib/arel/visitors/to_sql.rb#905 def unboundable?(value); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def unsupported(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#742 + # source://activerecord//lib/arel/visitors/to_sql.rb#756 def visit_ActiveModel_Attribute(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_ActiveSupport_Multibyte_Chars(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_ActiveSupport_StringInquirer(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#732 + # source://activerecord//lib/arel/visitors/to_sql.rb#746 def visit_Arel_Attributes_Attribute(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#611 + # source://activerecord//lib/arel/visitors/to_sql.rb#622 def visit_Arel_Nodes_And(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#693 def visit_Arel_Nodes_As(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#361 + # source://activerecord//lib/arel/visitors/to_sql.rb#363 def visit_Arel_Nodes_Ascending(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#630 def visit_Arel_Nodes_Assignment(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#418 + # source://activerecord//lib/arel/visitors/to_sql.rb#421 def visit_Arel_Nodes_Avg(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#428 + # source://activerecord//lib/arel/visitors/to_sql.rb#431 def visit_Arel_Nodes_Between(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#183 + # source://activerecord//lib/arel/visitors/to_sql.rb#186 def visit_Arel_Nodes_Bin(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#746 + # source://activerecord//lib/arel/visitors/to_sql.rb#760 def visit_Arel_Nodes_BindParam(o, collector); end + # source://activerecord//lib/arel/visitors/to_sql.rb#770 + def visit_Arel_Nodes_BoundSqlLiteral(o, collector); end + # source://activerecord//lib/arel/visitors/to_sql.rb#699 def visit_Arel_Nodes_Case(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#84 + # source://activerecord//lib/arel/visitors/to_sql.rb#87 def visit_Arel_Nodes_Casted(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#172 + # source://activerecord//lib/arel/visitors/to_sql.rb#175 def visit_Arel_Nodes_Comment(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#402 + # source://activerecord//lib/arel/visitors/to_sql.rb#405 def visit_Arel_Nodes_Count(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#293 + # source://activerecord//lib/arel/visitors/to_sql.rb#732 + def visit_Arel_Nodes_Cte(o, collector); end + + # source://activerecord//lib/arel/visitors/to_sql.rb#296 def visit_Arel_Nodes_CurrentRow(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#22 def visit_Arel_Nodes_DeleteStatement(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#365 + # source://activerecord//lib/arel/visitors/to_sql.rb#367 def visit_Arel_Nodes_Descending(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#187 + # source://activerecord//lib/arel/visitors/to_sql.rb#190 def visit_Arel_Nodes_Distinct(o, collector); end # @raise [NotImplementedError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#191 + # source://activerecord//lib/arel/visitors/to_sql.rb#194 def visit_Arel_Nodes_DistinctOn(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#494 + # source://activerecord//lib/arel/visitors/to_sql.rb#497 def visit_Arel_Nodes_DoesNotMatch(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#723 @@ -37535,55 +42130,58 @@ class Arel::Visitors::ToSql < ::Arel::Visitors::Visitor # source://activerecord//lib/arel/visitors/to_sql.rb#643 def visit_Arel_Nodes_Equality(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#218 + # source://activerecord//lib/arel/visitors/to_sql.rb#221 def visit_Arel_Nodes_Except(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#73 + # source://activerecord//lib/arel/visitors/to_sql.rb#76 def visit_Arel_Nodes_Exists(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#397 + # source://activerecord//lib/arel/visitors/to_sql.rb#400 def visit_Arel_Nodes_Extract(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#93 + # source://activerecord//lib/arel/visitors/to_sql.rb#96 def visit_Arel_Nodes_False(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#248 + # source://activerecord//lib/arel/visitors/to_sql.rb#251 def visit_Arel_Nodes_Filter(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#283 + # source://activerecord//lib/arel/visitors/to_sql.rb#286 def visit_Arel_Nodes_Following(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#529 + # source://activerecord//lib/arel/visitors/to_sql.rb#863 + def visit_Arel_Nodes_Fragments(o, collector); end + + # source://activerecord//lib/arel/visitors/to_sql.rb#532 def visit_Arel_Nodes_FullOuterJoin(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#446 + # source://activerecord//lib/arel/visitors/to_sql.rb#449 def visit_Arel_Nodes_GreaterThan(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#434 + # source://activerecord//lib/arel/visitors/to_sql.rb#437 def visit_Arel_Nodes_GreaterThanOrEqual(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#380 + # source://activerecord//lib/arel/visitors/to_sql.rb#382 def visit_Arel_Nodes_Group(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#324 + # source://activerecord//lib/arel/visitors/to_sql.rb#327 def visit_Arel_Nodes_Grouping(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#333 + # source://activerecord//lib/arel/visitors/to_sql.rb#336 def visit_Arel_Nodes_HomogeneousIn(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#579 + # source://activerecord//lib/arel/visitors/to_sql.rb#588 def visit_Arel_Nodes_In(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#778 + # source://activerecord//lib/arel/visitors/to_sql.rb#847 def visit_Arel_Nodes_InfixOperation(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#550 + # source://activerecord//lib/arel/visitors/to_sql.rb#553 def visit_Arel_Nodes_InnerJoin(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#51 + # source://activerecord//lib/arel/visitors/to_sql.rb#53 def visit_Arel_Nodes_InsertStatement(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#213 + # source://activerecord//lib/arel/visitors/to_sql.rb#216 def visit_Arel_Nodes_Intersect(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#668 @@ -37592,230 +42190,230 @@ class Arel::Visitors::ToSql < ::Arel::Visitors::Visitor # source://activerecord//lib/arel/visitors/to_sql.rb#658 def visit_Arel_Nodes_IsNotDistinctFrom(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#506 + # source://activerecord//lib/arel/visitors/to_sql.rb#509 def visit_Arel_Nodes_JoinSource(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#470 + # source://activerecord//lib/arel/visitors/to_sql.rb#473 def visit_Arel_Nodes_LessThan(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#458 + # source://activerecord//lib/arel/visitors/to_sql.rb#461 def visit_Arel_Nodes_LessThanOrEqual(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#315 + # source://activerecord//lib/arel/visitors/to_sql.rb#318 def visit_Arel_Nodes_Limit(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#320 + # source://activerecord//lib/arel/visitors/to_sql.rb#323 def visit_Arel_Nodes_Lock(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#482 + # source://activerecord//lib/arel/visitors/to_sql.rb#485 def visit_Arel_Nodes_Matches(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#410 + # source://activerecord//lib/arel/visitors/to_sql.rb#413 def visit_Arel_Nodes_Max(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#414 + # source://activerecord//lib/arel/visitors/to_sql.rb#417 def visit_Arel_Nodes_Min(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#384 + # source://activerecord//lib/arel/visitors/to_sql.rb#386 def visit_Arel_Nodes_NamedFunction(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#223 + # source://activerecord//lib/arel/visitors/to_sql.rb#226 def visit_Arel_Nodes_NamedWindow(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#566 + # source://activerecord//lib/arel/visitors/to_sql.rb#569 def visit_Arel_Nodes_Not(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#678 def visit_Arel_Nodes_NotEqual(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#595 + # source://activerecord//lib/arel/visitors/to_sql.rb#605 def visit_Arel_Nodes_NotIn(o, collector); end # @raise [NotImplementedError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#521 + # source://activerecord//lib/arel/visitors/to_sql.rb#524 def visit_Arel_Nodes_NotRegexp(o, collector); end # NullsFirst is available on all but MySQL, where it is redefined. # - # source://activerecord//lib/arel/visitors/to_sql.rb#370 + # source://activerecord//lib/arel/visitors/to_sql.rb#372 def visit_Arel_Nodes_NullsFirst(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#375 + # source://activerecord//lib/arel/visitors/to_sql.rb#377 def visit_Arel_Nodes_NullsLast(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#310 + # source://activerecord//lib/arel/visitors/to_sql.rb#313 def visit_Arel_Nodes_Offset(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#561 + # source://activerecord//lib/arel/visitors/to_sql.rb#564 def visit_Arel_Nodes_On(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#167 + # source://activerecord//lib/arel/visitors/to_sql.rb#170 def visit_Arel_Nodes_OptimizerHints(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#615 + # source://activerecord//lib/arel/visitors/to_sql.rb#626 def visit_Arel_Nodes_Or(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#536 + # source://activerecord//lib/arel/visitors/to_sql.rb#539 def visit_Arel_Nodes_OuterJoin(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#297 + # source://activerecord//lib/arel/visitors/to_sql.rb#300 def visit_Arel_Nodes_Over(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#273 + # source://activerecord//lib/arel/visitors/to_sql.rb#276 def visit_Arel_Nodes_Preceding(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#84 + # source://activerecord//lib/arel/visitors/to_sql.rb#87 def visit_Arel_Nodes_Quoted(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#264 + # source://activerecord//lib/arel/visitors/to_sql.rb#267 def visit_Arel_Nodes_Range(o, collector); end # @raise [NotImplementedError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#517 + # source://activerecord//lib/arel/visitors/to_sql.rb#520 def visit_Arel_Nodes_Regexp(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#543 + # source://activerecord//lib/arel/visitors/to_sql.rb#546 def visit_Arel_Nodes_RightOuterJoin(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#255 + # source://activerecord//lib/arel/visitors/to_sql.rb#258 def visit_Arel_Nodes_Rows(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#146 + # source://activerecord//lib/arel/visitors/to_sql.rb#149 def visit_Arel_Nodes_SelectCore(o, collector); end # The Oracle enhanced adapter uses this private method, # see https://github.com/rsim/oracle-enhanced/issues/2186 # - # source://activerecord//lib/arel/visitors/to_sql.rb#140 + # source://activerecord//lib/arel/visitors/to_sql.rb#143 def visit_Arel_Nodes_SelectOptions(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#117 + # source://activerecord//lib/arel/visitors/to_sql.rb#120 def visit_Arel_Nodes_SelectStatement(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#750 + # source://activerecord//lib/arel/visitors/to_sql.rb#764 def visit_Arel_Nodes_SqlLiteral(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#525 + # source://activerecord//lib/arel/visitors/to_sql.rb#528 def visit_Arel_Nodes_StringJoin(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#406 + # source://activerecord//lib/arel/visitors/to_sql.rb#409 def visit_Arel_Nodes_Sum(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#422 + # source://activerecord//lib/arel/visitors/to_sql.rb#425 def visit_Arel_Nodes_TableAlias(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#89 + # source://activerecord//lib/arel/visitors/to_sql.rb#92 def visit_Arel_Nodes_True(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#784 + # source://activerecord//lib/arel/visitors/to_sql.rb#853 def visit_Arel_Nodes_UnaryOperation(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#205 + # source://activerecord//lib/arel/visitors/to_sql.rb#208 def visit_Arel_Nodes_Union(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#209 + # source://activerecord//lib/arel/visitors/to_sql.rb#212 def visit_Arel_Nodes_UnionAll(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#728 def visit_Arel_Nodes_UnqualifiedColumn(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#39 + # source://activerecord//lib/arel/visitors/to_sql.rb#40 def visit_Arel_Nodes_UpdateStatement(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#97 + # source://activerecord//lib/arel/visitors/to_sql.rb#100 def visit_Arel_Nodes_ValuesList(o, collector); end # source://activerecord//lib/arel/visitors/to_sql.rb#716 def visit_Arel_Nodes_When(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#229 + # source://activerecord//lib/arel/visitors/to_sql.rb#232 def visit_Arel_Nodes_Window(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#195 + # source://activerecord//lib/arel/visitors/to_sql.rb#198 def visit_Arel_Nodes_With(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#200 + # source://activerecord//lib/arel/visitors/to_sql.rb#203 def visit_Arel_Nodes_WithRecursive(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#356 + # source://activerecord//lib/arel/visitors/to_sql.rb#358 def visit_Arel_SelectManager(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#571 + # source://activerecord//lib/arel/visitors/to_sql.rb#574 def visit_Arel_Table(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#789 + # source://activerecord//lib/arel/visitors/to_sql.rb#858 def visit_Array(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_BigDecimal(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_Class(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_Date(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_DateTime(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_FalseClass(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_Float(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_Hash(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#755 + # source://activerecord//lib/arel/visitors/to_sql.rb#824 def visit_Integer(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_NilClass(o, collector); end - # source://activerecord//lib/arel/visitors/to_sql.rb#789 + # source://activerecord//lib/arel/visitors/to_sql.rb#858 def visit_Set(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_String(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_Symbol(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_Time(o, collector); end # @raise [UnsupportedVisitError] # - # source://activerecord//lib/arel/visitors/to_sql.rb#759 + # source://activerecord//lib/arel/visitors/to_sql.rb#828 def visit_TrueClass(o, collector); end end -# source://activerecord//lib/arel/visitors/to_sql.rb#737 +# source://activerecord//lib/arel/visitors/to_sql.rb#751 Arel::Visitors::ToSql::BIND_BLOCK = T.let(T.unsafe(nil), Proc) # source://activerecord//lib/arel/visitors/to_sql.rb#5 diff --git a/sorbet/rbi/gems/activestorage@7.0.5.rbi b/sorbet/rbi/gems/activestorage@7.0.5.rbi deleted file mode 100644 index 92c71f270..000000000 --- a/sorbet/rbi/gems/activestorage@7.0.5.rbi +++ /dev/null @@ -1,2127 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `activestorage` gem. -# Please instead update this file by running `bin/tapioca gem activestorage`. - -# source://activestorage//lib/active_storage/gem_version.rb#3 -module ActiveStorage - extend ::ActiveSupport::Autoload - - # source://activestorage//lib/active_storage.rb#52 - def analyzers; end - - # source://activestorage//lib/active_storage.rb#52 - def analyzers=(val); end - - # source://activestorage//lib/active_storage.rb#58 - def binary_content_type; end - - # source://activestorage//lib/active_storage.rb#58 - def binary_content_type=(val); end - - # source://activestorage//lib/active_storage.rb#60 - def content_types_allowed_inline; end - - # source://activestorage//lib/active_storage.rb#60 - def content_types_allowed_inline=(val); end - - # source://activestorage//lib/active_storage.rb#59 - def content_types_to_serve_as_binary; end - - # source://activestorage//lib/active_storage.rb#59 - def content_types_to_serve_as_binary=(val); end - - # source://activestorage//lib/active_storage.rb#357 - def draw_routes; end - - # source://activestorage//lib/active_storage.rb#357 - def draw_routes=(val); end - - # source://activestorage//lib/active_storage.rb#45 - def logger; end - - # source://activestorage//lib/active_storage.rb#45 - def logger=(val); end - - # source://activestorage//lib/active_storage.rb#54 - def paths; end - - # source://activestorage//lib/active_storage.rb#54 - def paths=(val); end - - # source://activestorage//lib/active_storage.rb#51 - def previewers; end - - # source://activestorage//lib/active_storage.rb#51 - def previewers=(val); end - - # source://activestorage//lib/active_storage.rb#49 - def queues; end - - # source://activestorage//lib/active_storage.rb#49 - def queues=(val); end - - # source://activestorage//lib/active_storage.rb#360 - def replace_on_assign_to_many; end - - # source://activestorage//lib/active_storage.rb#360 - def replace_on_assign_to_many=(val); end - - # source://activestorage//lib/active_storage.rb#358 - def resolve_model_to_route; end - - # source://activestorage//lib/active_storage.rb#358 - def resolve_model_to_route=(val); end - - # source://activestorage//lib/active_storage.rb#356 - def routes_prefix; end - - # source://activestorage//lib/active_storage.rb#356 - def routes_prefix=(val); end - - # source://activestorage//lib/active_storage.rb#353 - def service_urls_expire_in; end - - # source://activestorage//lib/active_storage.rb#353 - def service_urls_expire_in=(val); end - - # source://activestorage//lib/active_storage.rb#365 - def silence_invalid_content_types_warning; end - - # source://activestorage//lib/active_storage.rb#365 - def silence_invalid_content_types_warning=(val); end - - # source://activestorage//lib/active_storage.rb#62 - def supported_image_processing_methods; end - - # source://activestorage//lib/active_storage.rb#62 - def supported_image_processing_methods=(val); end - - # source://activestorage//lib/active_storage.rb#361 - def track_variants; end - - # source://activestorage//lib/active_storage.rb#361 - def track_variants=(val); end - - # source://activestorage//lib/active_storage.rb#351 - def unsupported_image_processing_arguments; end - - # source://activestorage//lib/active_storage.rb#351 - def unsupported_image_processing_arguments=(val); end - - # source://activestorage//lib/active_storage.rb#354 - def urls_expire_in; end - - # source://activestorage//lib/active_storage.rb#354 - def urls_expire_in=(val); end - - # source://activestorage//lib/active_storage.rb#56 - def variable_content_types; end - - # source://activestorage//lib/active_storage.rb#56 - def variable_content_types=(val); end - - # source://activestorage//lib/active_storage.rb#47 - def variant_processor; end - - # source://activestorage//lib/active_storage.rb#47 - def variant_processor=(val); end - - # source://activestorage//lib/active_storage.rb#46 - def verifier; end - - # source://activestorage//lib/active_storage.rb#46 - def verifier=(val); end - - # source://activestorage//lib/active_storage.rb#363 - def video_preview_arguments; end - - # source://activestorage//lib/active_storage.rb#363 - def video_preview_arguments=(val); end - - # source://activestorage//lib/active_storage.rb#57 - def web_image_content_types; end - - # source://activestorage//lib/active_storage.rb#57 - def web_image_content_types=(val); end - - class << self - # source://activestorage//lib/active_storage.rb#52 - def analyzers; end - - # source://activestorage//lib/active_storage.rb#52 - def analyzers=(val); end - - # source://activestorage//lib/active_storage.rb#58 - def binary_content_type; end - - # source://activestorage//lib/active_storage.rb#58 - def binary_content_type=(val); end - - # source://activestorage//lib/active_storage.rb#60 - def content_types_allowed_inline; end - - # source://activestorage//lib/active_storage.rb#60 - def content_types_allowed_inline=(val); end - - # source://activestorage//lib/active_storage.rb#59 - def content_types_to_serve_as_binary; end - - # source://activestorage//lib/active_storage.rb#59 - def content_types_to_serve_as_binary=(val); end - - # source://activestorage//lib/active_storage.rb#357 - def draw_routes; end - - # source://activestorage//lib/active_storage.rb#357 - def draw_routes=(val); end - - # Returns the currently loaded version of Active Storage as a Gem::Version. - # - # source://activestorage//lib/active_storage/gem_version.rb#5 - def gem_version; end - - # source://activestorage//lib/active_storage.rb#45 - def logger; end - - # source://activestorage//lib/active_storage.rb#45 - def logger=(val); end - - # source://activestorage//lib/active_storage.rb#54 - def paths; end - - # source://activestorage//lib/active_storage.rb#54 - def paths=(val); end - - # source://activestorage//lib/active_storage.rb#51 - def previewers; end - - # source://activestorage//lib/active_storage.rb#51 - def previewers=(val); end - - # source://activestorage//lib/active_storage.rb#49 - def queues; end - - # source://activestorage//lib/active_storage.rb#49 - def queues=(val); end - - # source://railties/7.0.5/lib/rails/engine.rb#405 - def railtie_helpers_paths; end - - # source://railties/7.0.5/lib/rails/engine.rb#394 - def railtie_namespace; end - - # source://railties/7.0.5/lib/rails/engine.rb#409 - def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end - - # source://activestorage//lib/active_storage.rb#360 - def replace_on_assign_to_many; end - - # source://activestorage//lib/active_storage.rb#360 - def replace_on_assign_to_many=(val); end - - # source://activestorage//lib/active_storage.rb#358 - def resolve_model_to_route; end - - # source://activestorage//lib/active_storage.rb#358 - def resolve_model_to_route=(val); end - - # source://activestorage//lib/active_storage.rb#356 - def routes_prefix; end - - # source://activestorage//lib/active_storage.rb#356 - def routes_prefix=(val); end - - # source://activestorage//lib/active_storage.rb#353 - def service_urls_expire_in; end - - # source://activestorage//lib/active_storage.rb#353 - def service_urls_expire_in=(val); end - - # source://activestorage//lib/active_storage.rb#365 - def silence_invalid_content_types_warning; end - - # source://activestorage//lib/active_storage.rb#365 - def silence_invalid_content_types_warning=(val); end - - # source://activestorage//lib/active_storage.rb#62 - def supported_image_processing_methods; end - - # source://activestorage//lib/active_storage.rb#62 - def supported_image_processing_methods=(val); end - - # source://railties/7.0.5/lib/rails/engine.rb#397 - def table_name_prefix; end - - # source://activestorage//lib/active_storage.rb#361 - def track_variants; end - - # source://activestorage//lib/active_storage.rb#361 - def track_variants=(val); end - - # source://activestorage//lib/active_storage.rb#351 - def unsupported_image_processing_arguments; end - - # source://activestorage//lib/active_storage.rb#351 - def unsupported_image_processing_arguments=(val); end - - # source://activestorage//lib/active_storage.rb#354 - def urls_expire_in; end - - # source://activestorage//lib/active_storage.rb#354 - def urls_expire_in=(val); end - - # source://railties/7.0.5/lib/rails/engine.rb#401 - def use_relative_model_naming?; end - - # source://activestorage//lib/active_storage.rb#56 - def variable_content_types; end - - # source://activestorage//lib/active_storage.rb#56 - def variable_content_types=(val); end - - # source://activestorage//lib/active_storage.rb#47 - def variant_processor; end - - # source://activestorage//lib/active_storage.rb#47 - def variant_processor=(val); end - - # source://activestorage//lib/active_storage.rb#46 - def verifier; end - - # source://activestorage//lib/active_storage.rb#46 - def verifier=(val); end - - # Returns the currently loaded version of Active Storage as a Gem::Version. - # - # source://activestorage//lib/active_storage/version.rb#7 - def version; end - - # source://activestorage//lib/active_storage.rb#363 - def video_preview_arguments; end - - # source://activestorage//lib/active_storage.rb#363 - def video_preview_arguments=(val); end - - # source://activestorage//lib/active_storage.rb#57 - def web_image_content_types; end - - # source://activestorage//lib/active_storage.rb#57 - def web_image_content_types=(val); end - end -end - -class ActiveStorage::AnalyzeJob < ::ActiveStorage::BaseJob - def perform(blob); end - - class << self - # source://activejob/7.0.5/lib/active_job/queue_name.rb#56 - def queue_name; end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers; end - end -end - -# This is an abstract base class for analyzers, which extract metadata from blobs. See -# ActiveStorage::Analyzer::VideoAnalyzer for an example of a concrete subclass. -# -# source://activestorage//lib/active_storage/analyzer.rb#6 -class ActiveStorage::Analyzer - # @return [Analyzer] a new instance of Analyzer - # - # source://activestorage//lib/active_storage/analyzer.rb#21 - def initialize(blob); end - - # Returns the value of attribute blob. - # - # source://activestorage//lib/active_storage/analyzer.rb#7 - def blob; end - - # Override this method in a concrete subclass. Have it return a Hash of metadata. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/analyzer.rb#26 - def metadata; end - - private - - # Downloads the blob to a tempfile on disk. Yields the tempfile. - # - # source://activestorage//lib/active_storage/analyzer.rb#32 - def download_blob_to_tempfile(&block); end - - # source://activestorage//lib/active_storage/analyzer.rb#44 - def instrument(analyzer, &block); end - - # source://activestorage//lib/active_storage/analyzer.rb#36 - def logger; end - - # source://activestorage//lib/active_storage/analyzer.rb#40 - def tmpdir; end - - class << self - # Implement this method in a concrete subclass. Have it return true when given a blob from which - # the analyzer can extract metadata. - # - # @return [Boolean] - # - # source://activestorage//lib/active_storage/analyzer.rb#11 - def accept?(blob); end - - # Implement this method in concrete subclasses. It will determine if blob analysis - # should be done in a job or performed inline. By default, analysis is enqueued in a job. - # - # @return [Boolean] - # - # source://activestorage//lib/active_storage/analyzer.rb#17 - def analyze_later?; end - end -end - -# source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#12 -class ActiveStorage::Analyzer::AudioAnalyzer < ::ActiveStorage::Analyzer - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#17 - def metadata; end - - private - - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#32 - def audio_stream; end - - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#27 - def bit_rate; end - - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#22 - def duration; end - - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#61 - def ffprobe_path; end - - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#40 - def probe; end - - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#44 - def probe_from(file); end - - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#36 - def streams; end - - class << self - # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#13 - def accept?(blob); end - end -end - -# source://activestorage//lib/active_storage/analyzer/image_analyzer.rb#12 -class ActiveStorage::Analyzer::ImageAnalyzer < ::ActiveStorage::Analyzer - # source://activestorage//lib/active_storage/analyzer/image_analyzer.rb#17 - def metadata; end - - class << self - # source://activestorage//lib/active_storage/analyzer/image_analyzer.rb#13 - def accept?(blob); end - end -end - -# source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#6 -class ActiveStorage::Analyzer::ImageAnalyzer::ImageMagick < ::ActiveStorage::Analyzer::ImageAnalyzer - private - - # source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#12 - def read_image; end - - # source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#37 - def rotated_image?(image); end - - class << self - # source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#7 - def accept?(blob); end - end -end - -# source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#6 -class ActiveStorage::Analyzer::ImageAnalyzer::Vips < ::ActiveStorage::Analyzer::ImageAnalyzer - private - - # source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#12 - def read_image; end - - # source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#38 - def rotated_image?(image); end - - # source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#44 - def valid_image?(image); end - - class << self - # source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#7 - def accept?(blob); end - end -end - -# source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#37 -ActiveStorage::Analyzer::ImageAnalyzer::Vips::ROTATIONS = T.let(T.unsafe(nil), Regexp) - -# source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#4 -class ActiveStorage::Analyzer::NullAnalyzer < ::ActiveStorage::Analyzer - # source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#13 - def metadata; end - - class << self - # source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#5 - def accept?(blob); end - - # source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#9 - def analyze_later?; end - end -end - -# source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#22 -class ActiveStorage::Analyzer::VideoAnalyzer < ::ActiveStorage::Analyzer - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#27 - def metadata; end - - private - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#53 - def angle; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#72 - def audio?; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#107 - def audio_stream; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#80 - def computed_height; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#115 - def container; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#57 - def display_aspect_ratio; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#94 - def display_height_scale; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#48 - def duration; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#90 - def encoded_height; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#86 - def encoded_width; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#140 - def ffprobe_path; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#40 - def height; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#119 - def probe; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#123 - def probe_from(file); end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#68 - def rotated?; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#111 - def streams; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#99 - def tags; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#76 - def video?; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#103 - def video_stream; end - - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#32 - def width; end - - class << self - # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#23 - def accept?(blob); end - end -end - -# Abstract base class for the concrete ActiveStorage::Attached::One and ActiveStorage::Attached::Many -# classes that both provide proxy access to the blob association for a record. -# -# source://activestorage//lib/active_storage/attached.rb#8 -class ActiveStorage::Attached - # @return [Attached] a new instance of Attached - # - # source://activestorage//lib/active_storage/attached.rb#11 - def initialize(name, record); end - - # Returns the value of attribute name. - # - # source://activestorage//lib/active_storage/attached.rb#9 - def name; end - - # Returns the value of attribute record. - # - # source://activestorage//lib/active_storage/attached.rb#9 - def record; end - - private - - # source://activestorage//lib/active_storage/attached.rb#16 - def change; end -end - -# source://activestorage//lib/active_storage/attached/changes.rb#4 -module ActiveStorage::Attached::Changes - extend ::ActiveSupport::Autoload -end - -# source://activestorage//lib/active_storage/attached/changes/create_many.rb#4 -class ActiveStorage::Attached::Changes::CreateMany - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#7 - def initialize(name, record, attachables); end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#5 - def attachables; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#13 - def attachments; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#17 - def blobs; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#5 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#5 - def record; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#25 - def save; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#21 - def upload; end - - private - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#39 - def assign_associated_attachments; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#35 - def build_subchange_from(attachable); end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#47 - def persisted_or_new_attachments; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#43 - def reset_associated_blobs; end - - # source://activestorage//lib/active_storage/attached/changes/create_many.rb#31 - def subchanges; end -end - -# source://activestorage//lib/active_storage/attached/changes/create_one.rb#7 -class ActiveStorage::Attached::Changes::CreateOne - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#10 - def initialize(name, record, attachable); end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#8 - def attachable; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#15 - def attachment; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#19 - def blob; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#8 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#8 - def record; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#32 - def save; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#23 - def upload; end - - private - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#78 - def attachment_service_name; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#48 - def build_attachment; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#42 - def find_attachment; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#38 - def find_or_build_attachment; end - - # source://activestorage//lib/active_storage/attached/changes/create_one.rb#52 - def find_or_build_blob; end -end - -# source://activestorage//lib/active_storage/attached/changes/create_one_of_many.rb#4 -class ActiveStorage::Attached::Changes::CreateOneOfMany < ::ActiveStorage::Attached::Changes::CreateOne - private - - # source://activestorage//lib/active_storage/attached/changes/create_one_of_many.rb#6 - def find_attachment; end -end - -# source://activestorage//lib/active_storage/attached/changes/delete_many.rb#4 -class ActiveStorage::Attached::Changes::DeleteMany - # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#7 - def initialize(name, record); end - - # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#11 - def attachables; end - - # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#15 - def attachments; end - - # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#19 - def blobs; end - - # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#5 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#5 - def record; end - - # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#23 - def save; end -end - -# source://activestorage//lib/active_storage/attached/changes/delete_one.rb#4 -class ActiveStorage::Attached::Changes::DeleteOne - # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#7 - def initialize(name, record); end - - # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#11 - def attachment; end - - # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#5 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#5 - def record; end - - # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#15 - def save; end -end - -# source://activestorage//lib/active_storage/attached/changes/detach_many.rb#4 -class ActiveStorage::Attached::Changes::DetachMany - # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#7 - def initialize(name, record, attachments); end - - # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#5 - def attachments; end - - # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#11 - def detach; end - - # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#5 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#5 - def record; end -end - -# source://activestorage//lib/active_storage/attached/changes/detach_one.rb#4 -class ActiveStorage::Attached::Changes::DetachOne - # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#7 - def initialize(name, record, attachment); end - - # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#5 - def attachment; end - - # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#11 - def detach; end - - # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#5 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#5 - def record; end - - private - - # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#19 - def reset; end -end - -# source://activestorage//lib/active_storage/attached/changes/purge_many.rb#4 -class ActiveStorage::Attached::Changes::PurgeMany - # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#7 - def initialize(name, record, attachments); end - - # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#5 - def attachments; end - - # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#5 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#11 - def purge; end - - # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#16 - def purge_later; end - - # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#5 - def record; end - - private - - # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#22 - def reset; end -end - -# source://activestorage//lib/active_storage/attached/changes/purge_one.rb#4 -class ActiveStorage::Attached::Changes::PurgeOne - # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#7 - def initialize(name, record, attachment); end - - # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#5 - def attachment; end - - # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#5 - def name; end - - # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#11 - def purge; end - - # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#16 - def purge_later; end - - # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#5 - def record; end - - private - - # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#22 - def reset; end -end - -# source://activestorage//lib/active_storage/attached/many.rb#5 -class ActiveStorage::Attached::Many < ::ActiveStorage::Attached - # source://activestorage//lib/active_storage/attached/many.rb#49 - def attach(*attachables); end - - # source://activestorage//lib/active_storage/attached/many.rb#65 - def attached?; end - - # source://activestorage//lib/active_storage/attached/many.rb#30 - def attachments; end - - # source://activestorage//lib/active_storage/attached/many.rb#35 - def blobs; end - - # source://activestorage//lib/active_storage/attached/many.rb#23 - def detach(*_arg0, **_arg1, &_arg2); end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#302 - def method_missing(method, *args, **_arg2, &block); end - - # source://activestorage//lib/active_storage/attached/many.rb#11 - def purge(*_arg0, **_arg1, &_arg2); end - - # source://activestorage//lib/active_storage/attached/many.rb#17 - def purge_later(*_arg0, **_arg1, &_arg2); end - - private - - # source://activestorage//lib/active_storage/attached/many.rb#74 - def detach_many; end - - # source://activestorage//lib/active_storage/attached/many.rb#70 - def purge_many; end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#294 - def respond_to_missing?(name, include_private = T.unsafe(nil)); end -end - -# source://activestorage//lib/active_storage/attached/model.rb#7 -module ActiveStorage::Attached::Model - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::ActiveStorage::Attached::Model::ClassMethods - - # source://activestorage//lib/active_storage/attached/model.rb#222 - def attachment_changes; end - - # source://activestorage//lib/active_storage/attached/model.rb#226 - def changed_for_autosave?; end - - # source://activestorage//lib/active_storage/attached/model.rb#236 - def reload(*_arg0); end - - private - - # source://activestorage//lib/active_storage/attached/model.rb#230 - def initialize_dup(*_arg0); end -end - -# source://activestorage//lib/active_storage/attached/model.rb#0 -module ActiveStorage::Attached::Model::ClassMethods - # source://activestorage//lib/active_storage/attached/model.rb#129 - def has_many_attached(name, dependent: T.unsafe(nil), service: T.unsafe(nil), strict_loading: T.unsafe(nil)); end - - # source://activestorage//lib/active_storage/attached/model.rb#50 - def has_one_attached(name, dependent: T.unsafe(nil), service: T.unsafe(nil), strict_loading: T.unsafe(nil)); end - - private - - # source://activestorage//lib/active_storage/attached/model.rb#213 - def validate_service_configuration(association_name, service); end -end - -# source://activestorage//lib/active_storage/attached/one.rb#5 -class ActiveStorage::Attached::One < ::ActiveStorage::Attached - # source://activestorage//lib/active_storage/attached/one.rb#56 - def attach(attachable); end - - # source://activestorage//lib/active_storage/attached/one.rb#72 - def attached?; end - - # source://activestorage//lib/active_storage/attached/one.rb#31 - def attachment; end - - # source://activestorage//lib/active_storage/attached/one.rb#42 - def blank?; end - - # source://activestorage//lib/active_storage/attached/one.rb#23 - def detach(*_arg0, **_arg1, &_arg2); end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#302 - def method_missing(method, *args, **_arg2, &block); end - - # source://activestorage//lib/active_storage/attached/one.rb#11 - def purge(*_arg0, **_arg1, &_arg2); end - - # source://activestorage//lib/active_storage/attached/one.rb#17 - def purge_later(*_arg0, **_arg1, &_arg2); end - - private - - # source://activestorage//lib/active_storage/attached/one.rb#81 - def detach_one; end - - # source://activestorage//lib/active_storage/attached/one.rb#77 - def purge_one; end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#294 - def respond_to_missing?(name, include_private = T.unsafe(nil)); end -end - -class ActiveStorage::Attachment < ::ActiveStorage::Record - include ::ActiveStorage::Attachment::GeneratedAttributeMethods - include ::ActiveStorage::Attachment::GeneratedAssociationMethods - - # source://activerecord/7.0.5/lib/active_record/autosave_association.rb#160 - def autosave_associated_records_for_blob(*args); end - - # source://activerecord/7.0.5/lib/active_record/autosave_association.rb#160 - def autosave_associated_records_for_record(*args); end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#302 - def method_missing(method, *args, **_arg2, &block); end - - def purge; end - def purge_later; end - def signed_id(*_arg0, **_arg1, &_arg2); end - - # source://activerecord/7.0.5/lib/active_record/autosave_association.rb#160 - def validate_associated_records_for_blob(*args); end - - def variant(transformations); end - - private - - def analyze_blob_later; end - def dependent; end - def mirror_blob_later; end - def purge_dependent_blob_later; end - - # source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#294 - def respond_to_missing?(name, include_private = T.unsafe(nil)); end - - def variants; end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activerecord/7.0.5/lib/active_record/reflection.rb#11 - def _reflections; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - - # source://activerecord/7.0.5/lib/active_record/scoping/named.rb#174 - def with_all_variant_records(*args, **_arg1); end - end -end - -module ActiveStorage::Attachment::GeneratedAssociationMethods - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#103 - def blob; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#111 - def blob=(value); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#132 - def blob_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#136 - def blob_previously_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#28 - def build_blob(*args, &block); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#32 - def create_blob(*args, &block); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#36 - def create_blob!(*args, &block); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#103 - def record; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#111 - def record=(value); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#132 - def record_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#136 - def record_previously_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#19 - def reload_blob; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#19 - def reload_record; end -end - -module ActiveStorage::Attachment::GeneratedAttributeMethods; end - -class ActiveStorage::BaseController < ::ActionController::Base - include ::ActiveStorage::SetCurrent - - private - - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 - def _layout(lookup_context, formats); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 - def etag_with_template_digest; end - - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 - def middleware_stack; end - end -end - -class ActiveStorage::BaseJob < ::ActiveJob::Base; end - -class ActiveStorage::Blob < ::ActiveStorage::Record - include ::ActiveStorage::Blob::GeneratedAttributeMethods - include ::ActiveStorage::Blob::GeneratedAssociationMethods - - class << self - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - end -end - -module ActiveStorage::Blob::Analyzable - def analyze; end - def analyze_later; end - def analyzed?; end - - private - - def analyzer; end - def analyzer_class; end - def extract_metadata_via_analyzer; end -end - -module ActiveStorage::Blob::GeneratedAssociationMethods; end -module ActiveStorage::Blob::GeneratedAttributeMethods; end - -module ActiveStorage::Blob::Identifiable - def identified?; end - def identify; end - def identify_without_saving; end - - private - - def download_identifiable_chunk; end - def identify_content_type; end -end - -module ActiveStorage::Blob::Representable - extend ::ActiveSupport::Concern - - def preview(transformations); end - def previewable?; end - def representable?; end - def representation(transformations); end - def variable?; end - def variant(transformations); end - - private - - def default_variant_format; end - def default_variant_transformations; end - def format; end - def variant_class; end -end - -class ActiveStorage::Current < ::ActiveSupport::CurrentAttributes - def host; end - def host=(host); end - - class << self - # source://activesupport/7.0.5/lib/active_support/current_attributes.rb#118 - def url_options; end - - # source://activesupport/7.0.5/lib/active_support/current_attributes.rb#118 - def url_options=(value); end - end -end - -class ActiveStorage::DirectUploadsController < ::ActiveStorage::BaseController - def create; end - - private - - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 - def _layout(lookup_context, formats); end - - def blob_args; end - def direct_upload_json(blob); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 - def middleware_stack; end - end -end - -class ActiveStorage::DiskController < ::ActiveStorage::BaseController - include ::ActiveStorage::FileServer - - def show; end - def update; end - - private - - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 - def _layout(lookup_context, formats); end - - def acceptable_content?(token); end - def decode_verified_key; end - def decode_verified_token; end - def named_disk_service(name); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 - def middleware_stack; end - end -end - -# source://activestorage//lib/active_storage/downloader.rb#4 -class ActiveStorage::Downloader - # @return [Downloader] a new instance of Downloader - # - # source://activestorage//lib/active_storage/downloader.rb#7 - def initialize(service); end - - # source://activestorage//lib/active_storage/downloader.rb#11 - def open(key, checksum: T.unsafe(nil), verify: T.unsafe(nil), name: T.unsafe(nil), tmpdir: T.unsafe(nil)); end - - # Returns the value of attribute service. - # - # source://activestorage//lib/active_storage/downloader.rb#5 - def service; end - - private - - # source://activestorage//lib/active_storage/downloader.rb#30 - def download(key, file); end - - # source://activestorage//lib/active_storage/downloader.rb#20 - def open_tempfile(name, tmpdir = T.unsafe(nil)); end - - # source://activestorage//lib/active_storage/downloader.rb#37 - def verify_integrity_of(file, checksum:); end -end - -# source://activestorage//lib/active_storage/engine.rb#25 -class ActiveStorage::Engine < ::Rails::Engine; end - -# Generic base class for all Active Storage exceptions. -# -# source://activestorage//lib/active_storage/errors.rb#5 -class ActiveStorage::Error < ::StandardError; end - -# Raised when ActiveStorage::Blob#download is called on a blob where the -# backing file is no longer present in its service. -# -# source://activestorage//lib/active_storage/errors.rb#25 -class ActiveStorage::FileNotFoundError < ::ActiveStorage::Error; end - -module ActiveStorage::FileServer - private - - def serve_file(path, content_type:, disposition:); end -end - -class ActiveStorage::Filename - include ::Comparable - - def initialize(filename); end - - def <=>(other); end - def as_json(*_arg0); end - def base; end - def extension; end - def extension_with_delimiter; end - def extension_without_delimiter; end - def sanitized; end - def to_json; end - def to_s; end - - class << self - def wrap(filename); end - end -end - -# Fixtures are a way of organizing data that you want to test against; in -# short, sample data. -# -# To learn more about fixtures, read the ActiveRecord::FixtureSet documentation. -# -# === YAML -# -# Like other Active Record-backed models, ActiveStorage::Attachment and -# ActiveStorage::Blob records inherit from ActiveRecord::Base instances and -# therefore can be populated by fixtures. -# -# Consider a hypothetical Article model class, its related -# fixture data, as well as fixture data for related ActiveStorage::Attachment -# and ActiveStorage::Blob records: -# -# # app/models/article.rb -# class Article < ApplicationRecord -# has_one_attached :thumbnail -# end -# -# # fixtures/active_storage/blobs.yml -# first_thumbnail_blob: <%= ActiveStorage::FixtureSet.blob filename: "first.png" %> -# -# # fixtures/active_storage/attachments.yml -# first_thumbnail_attachment: -# name: thumbnail -# record: first (Article) -# blob: first_thumbnail_blob -# -# When processed, Active Record will insert database records for each fixture -# entry and will ensure the Active Storage relationship is intact. -# -# source://activestorage//lib/active_storage/fixture_set.rb#38 -class ActiveStorage::FixtureSet - include ::ActiveSupport::Testing::FileFixtures - include ::ActiveRecord::SecureToken - extend ::ActiveRecord::SecureToken::ClassMethods - - # source://activesupport/7.0.5/lib/active_support/testing/file_fixtures.rb#20 - def file_fixture_path; end - - # source://activesupport/7.0.5/lib/active_support/testing/file_fixtures.rb#20 - def file_fixture_path?; end - - # source://activestorage//lib/active_storage/fixture_set.rb#64 - def prepare(instance, **attributes); end - - class << self - # Generate a YAML-encoded representation of an ActiveStorage::Blob - # instance's attributes, resolve the file relative to the directory mentioned - # by ActiveSupport::Testing::FileFixtures.file_fixture, and upload - # the file to the Service - # - # === Examples - # - # # tests/fixtures/action_text/blobs.yml - # second_thumbnail_blob: <%= ActiveStorage::FixtureSet.blob( - # filename: "second.svg", - # ) %> - # - # third_thumbnail_blob: <%= ActiveStorage::FixtureSet.blob( - # filename: "third.svg", - # content_type: "image/svg+xml", - # service_name: "public" - # ) %> - # - # source://activestorage//lib/active_storage/fixture_set.rb#60 - def blob(filename:, **attributes); end - - # source://activesupport/7.0.5/lib/active_support/testing/file_fixtures.rb#20 - def file_fixture_path; end - - # source://activesupport/7.0.5/lib/active_support/testing/file_fixtures.rb#20 - def file_fixture_path=(value); end - - # source://activesupport/7.0.5/lib/active_support/testing/file_fixtures.rb#20 - def file_fixture_path?; end - end -end - -# Raised when uploaded or downloaded data does not match a precomputed checksum. -# Indicates that a network error or a software bug caused data corruption. -# -# source://activestorage//lib/active_storage/errors.rb#21 -class ActiveStorage::IntegrityError < ::ActiveStorage::Error; end - -# Raised when ActiveStorage::Blob#variant is called on a blob that isn't variable. -# Use ActiveStorage::Blob#variable? to determine whether a blob is variable. -# -# source://activestorage//lib/active_storage/errors.rb#9 -class ActiveStorage::InvariableError < ::ActiveStorage::Error; end - -# source://activestorage//lib/active_storage/log_subscriber.rb#6 -class ActiveStorage::LogSubscriber < ::ActiveSupport::LogSubscriber - # source://activestorage//lib/active_storage/log_subscriber.rb#41 - def logger; end - - # source://activestorage//lib/active_storage/log_subscriber.rb#19 - def service_delete(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#23 - def service_delete_prefixed(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#13 - def service_download(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#27 - def service_exist(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#35 - def service_mirror(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#13 - def service_streaming_download(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#7 - def service_upload(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#31 - def service_url(event); end - - private - - # source://activestorage//lib/active_storage/log_subscriber.rb#50 - def debug(event, colored_message); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#46 - def info(event, colored_message); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#58 - def key_in(event); end - - # source://activestorage//lib/active_storage/log_subscriber.rb#54 - def log_prefix_for_service(event); end -end - -class ActiveStorage::MirrorJob < ::ActiveStorage::BaseJob - def perform(key, checksum:); end - - class << self - # source://activejob/7.0.5/lib/active_job/queue_name.rb#56 - def queue_name; end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers; end - end -end - -class ActiveStorage::Preview - def initialize(blob, variation_or_variation_key); end - - def blob; end - def download(&block); end - def image; end - def key; end - def processed; end - def url(**options); end - def variation; end - - private - - def previewer; end - def previewer_class; end - def process; end - def processed?; end - def variant; end -end - -class ActiveStorage::Preview::UnprocessedError < ::StandardError; end - -# Raised when a Previewer is unable to generate a preview image. -# -# source://activestorage//lib/active_storage/errors.rb#28 -class ActiveStorage::PreviewError < ::ActiveStorage::Error; end - -# This is an abstract base class for previewers, which generate images from blobs. See -# ActiveStorage::Previewer::MuPDFPreviewer and ActiveStorage::Previewer::VideoPreviewer for -# examples of concrete subclasses. -# -# source://activestorage//lib/active_storage/previewer.rb#7 -class ActiveStorage::Previewer - # @return [Previewer] a new instance of Previewer - # - # source://activestorage//lib/active_storage/previewer.rb#16 - def initialize(blob); end - - # Returns the value of attribute blob. - # - # source://activestorage//lib/active_storage/previewer.rb#8 - def blob; end - - # Override this method in a concrete subclass. Have it yield an attachable preview image (i.e. - # anything accepted by ActiveStorage::Attached::One#attach). Pass the additional options to - # the underlying blob that is created. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/previewer.rb#23 - def preview(**options); end - - private - - # source://activestorage//lib/active_storage/previewer.rb#71 - def capture(*argv, to:); end - - # Downloads the blob to a tempfile on disk. Yields the tempfile. - # - # source://activestorage//lib/active_storage/previewer.rb#29 - def download_blob_to_tempfile(&block); end - - # Executes a system command, capturing its binary output in a tempfile. Yields the tempfile. - # - # Use this method to shell out to a system library (e.g. muPDF or FFmpeg) for preview image - # generation. The resulting tempfile can be used as the +:io+ value in an attachable Hash: - # - # def preview - # download_blob_to_tempfile do |input| - # draw "my-drawing-command", input.path, "--format", "png", "-" do |output| - # yield io: output, filename: "#{blob.filename.base}.png", content_type: "image/png" - # end - # end - # end - # - # The output tempfile is opened in the directory returned by #tmpdir. - # - # source://activestorage//lib/active_storage/previewer.rb#47 - def draw(*argv); end - - # source://activestorage//lib/active_storage/previewer.rb#67 - def instrument(operation, payload = T.unsafe(nil), &block); end - - # source://activestorage//lib/active_storage/previewer.rb#86 - def logger; end - - # source://activestorage//lib/active_storage/previewer.rb#57 - def open_tempfile; end - - # source://activestorage//lib/active_storage/previewer.rb#90 - def tmpdir; end - - class << self - # Implement this method in a concrete subclass. Have it return true when given a blob from which - # the previewer can generate an image. - # - # @return [Boolean] - # - # source://activestorage//lib/active_storage/previewer.rb#12 - def accept?(blob); end - end -end - -# source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#4 -class ActiveStorage::Previewer::MuPDFPreviewer < ::ActiveStorage::Previewer - # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#23 - def preview(**options); end - - private - - # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#32 - def draw_first_page_from(file, &block); end - - class << self - # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#6 - def accept?(blob); end - - # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#14 - def mutool_exists?; end - - # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#10 - def mutool_path; end - end -end - -# source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#4 -class ActiveStorage::Previewer::PopplerPDFPreviewer < ::ActiveStorage::Previewer - # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#21 - def preview(**options); end - - private - - # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#30 - def draw_first_page_from(file, &block); end - - class << self - # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#6 - def accept?(blob); end - - # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#14 - def pdftoppm_exists?; end - - # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#10 - def pdftoppm_path; end - end -end - -# source://activestorage//lib/active_storage/previewer/video_previewer.rb#6 -class ActiveStorage::Previewer::VideoPreviewer < ::ActiveStorage::Previewer - # source://activestorage//lib/active_storage/previewer/video_previewer.rb#23 - def preview(**options); end - - private - - # source://activestorage//lib/active_storage/previewer/video_previewer.rb#32 - def draw_relevant_frame_from(file, &block); end - - class << self - # source://activestorage//lib/active_storage/previewer/video_previewer.rb#8 - def accept?(blob); end - - # source://activestorage//lib/active_storage/previewer/video_previewer.rb#12 - def ffmpeg_exists?; end - - # source://activestorage//lib/active_storage/previewer/video_previewer.rb#18 - def ffmpeg_path; end - end -end - -class ActiveStorage::PurgeJob < ::ActiveStorage::BaseJob - def perform(blob); end - - class << self - # source://activejob/7.0.5/lib/active_job/queue_name.rb#56 - def queue_name; end - - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 - def rescue_handlers; end - end -end - -class ActiveStorage::Record < ::ActiveRecord::Base - include ::ActiveStorage::Record::GeneratedAttributeMethods - include ::ActiveStorage::Record::GeneratedAssociationMethods - - class << self - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - end -end - -module ActiveStorage::Record::GeneratedAssociationMethods; end -module ActiveStorage::Record::GeneratedAttributeMethods; end - -# source://activestorage//lib/active_storage/reflection.rb#4 -module ActiveStorage::Reflection; end - -# source://activestorage//lib/active_storage/reflection.rb#49 -module ActiveStorage::Reflection::ActiveRecordExtensions - extend ::ActiveSupport::Concern - include GeneratedInstanceMethods - - mixes_in_class_methods GeneratedClassMethods - mixes_in_class_methods ::ActiveStorage::Reflection::ActiveRecordExtensions::ClassMethods - - module GeneratedClassMethods - def attachment_reflections; end - def attachment_reflections=(value); end - def attachment_reflections?; end - end - - module GeneratedInstanceMethods - def attachment_reflections; end - def attachment_reflections?; end - end -end - -# source://activestorage//lib/active_storage/reflection.rb#56 -module ActiveStorage::Reflection::ActiveRecordExtensions::ClassMethods - # Returns an array of reflection objects for all the attachments in the - # class. - # - # source://activestorage//lib/active_storage/reflection.rb#59 - def reflect_on_all_attachments; end - - # Returns the reflection object for the named +attachment+. - # - # User.reflect_on_attachment(:avatar) - # # => the avatar reflection - # - # source://activestorage//lib/active_storage/reflection.rb#68 - def reflect_on_attachment(attachment); end -end - -# source://activestorage//lib/active_storage/reflection.rb#5 -class ActiveStorage::Reflection::HasAttachedReflection < ::ActiveRecord::Reflection::MacroReflection - # source://activestorage//lib/active_storage/reflection.rb#6 - def variant(name, transformations); end - - # source://activestorage//lib/active_storage/reflection.rb#10 - def variants; end -end - -# Holds all the metadata about a has_many_attached attachment as it was -# specified in the Active Record class. -# -# source://activestorage//lib/active_storage/reflection.rb#25 -class ActiveStorage::Reflection::HasManyAttachedReflection < ::ActiveStorage::Reflection::HasAttachedReflection - # source://activestorage//lib/active_storage/reflection.rb#26 - def macro; end -end - -# Holds all the metadata about a has_one_attached attachment as it was -# specified in the Active Record class. -# -# source://activestorage//lib/active_storage/reflection.rb#17 -class ActiveStorage::Reflection::HasOneAttachedReflection < ::ActiveStorage::Reflection::HasAttachedReflection - # source://activestorage//lib/active_storage/reflection.rb#18 - def macro; end -end - -# source://activestorage//lib/active_storage/reflection.rb#31 -module ActiveStorage::Reflection::ReflectionExtension - # source://activestorage//lib/active_storage/reflection.rb#32 - def add_attachment_reflection(model, name, reflection); end - - private - - # source://activestorage//lib/active_storage/reflection.rb#37 - def reflection_class_for(macro); end -end - -# Abstract class serving as an interface for concrete services. -# -# The available services are: -# -# * +Disk+, to manage attachments saved directly on the hard drive. -# * +GCS+, to manage attachments through Google Cloud Storage. -# * +S3+, to manage attachments through Amazon S3. -# * +AzureStorage+, to manage attachments through Microsoft Azure Storage. -# * +Mirror+, to be able to use several services to manage attachments. -# -# Inside a Rails application, you can set-up your services through the -# generated config/storage.yml file and reference one -# of the aforementioned constant under the +service+ key. For example: -# -# local: -# service: Disk -# root: <%= Rails.root.join("storage") %> -# -# You can checkout the service's constructor to know which keys are required. -# -# Then, in your application's configuration, you can specify the service to -# use like this: -# -# config.active_storage.service = :local -# -# If you are using Active Storage outside of a Ruby on Rails application, you -# can configure the service to use like this: -# -# ActiveStorage::Blob.service = ActiveStorage::Service.configure( -# :local, -# { local: {service: "Disk", root: Pathname("/tmp/foo/storage") } } -# ) -# -# source://activestorage//lib/active_storage/service.rb#41 -class ActiveStorage::Service - extend ::ActiveSupport::Autoload - - # Concatenate multiple files into a single "composed" file. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#94 - def compose(source_keys, destination_key, filename: T.unsafe(nil), content_type: T.unsafe(nil), disposition: T.unsafe(nil), custom_metadata: T.unsafe(nil)); end - - # Delete the file at the +key+. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#99 - def delete(key); end - - # Delete files at keys starting with the +prefix+. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#104 - def delete_prefixed(prefix); end - - # Return the content of the file at the +key+. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#80 - def download(key); end - - # Return the partial content in the byte +range+ of the file at the +key+. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#85 - def download_chunk(key, range); end - - # Return +true+ if a file exists at the +key+. - # - # @raise [NotImplementedError] - # @return [Boolean] - # - # source://activestorage//lib/active_storage/service.rb#109 - def exist?(key); end - - # Returns a Hash of headers for +url_for_direct_upload+ requests. - # - # source://activestorage//lib/active_storage/service.rb#141 - def headers_for_direct_upload(key, filename:, content_type:, content_length:, checksum:, custom_metadata: T.unsafe(nil)); end - - # Returns the value of attribute name. - # - # source://activestorage//lib/active_storage/service.rb#44 - def name; end - - # Sets the attribute name - # - # @param value the value to set the attribute name to. - # - # source://activestorage//lib/active_storage/service.rb#44 - def name=(_arg0); end - - # source://activestorage//lib/active_storage/service.rb#89 - def open(*args, **options, &block); end - - # @return [Boolean] - # - # source://activestorage//lib/active_storage/service.rb#145 - def public?; end - - # Update metadata for the file identified by +key+ in the service. - # Override in subclasses only if the service needs to store specific - # metadata that has to be updated upon identification. - # - # source://activestorage//lib/active_storage/service.rb#76 - def update_metadata(key, **metadata); end - - # Upload the +io+ to the +key+ specified. If a +checksum+ is provided, the service will - # ensure a match when the upload has completed or raise an ActiveStorage::IntegrityError. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#69 - def upload(key, io, checksum: T.unsafe(nil), **options); end - - # Returns the URL for the file at the +key+. This returns a permanent URL for public files, and returns a - # short-lived URL for private files. For private files you can provide the +disposition+ (+:inline+ or +:attachment+), - # +filename+, and +content_type+ that you wish the file to be served with on request. Additionally, you can also provide - # the amount of seconds the URL will be valid for, specified in +expires_in+. - # - # source://activestorage//lib/active_storage/service.rb#117 - def url(key, **options); end - - # Returns a signed, temporary URL that a direct upload file can be PUT to on the +key+. - # The URL will be valid for the amount of seconds specified in +expires_in+. - # You must also provide the +content_type+, +content_length+, and +checksum+ of the file - # that will be uploaded. All these attributes will be validated by the service upon upload. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#136 - def url_for_direct_upload(key, expires_in:, content_type:, content_length:, checksum:, custom_metadata: T.unsafe(nil)); end - - private - - # source://activestorage//lib/active_storage/service.rb#173 - def content_disposition_with(filename:, type: T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#158 - def custom_metadata_headers(metadata); end - - # source://activestorage//lib/active_storage/service.rb#162 - def instrument(operation, payload = T.unsafe(nil), &block); end - - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#150 - def private_url(key, expires_in:, filename:, disposition:, content_type:, **_arg5); end - - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/service.rb#154 - def public_url(key, **_arg1); end - - # source://activestorage//lib/active_storage/service.rb#168 - def service_name; end - - class << self - # Override in subclasses that stitch together multiple services and hence - # need to build additional services using the configurator. - # - # Passes the configurator and all of the service's config as keyword args. - # - # See MirrorService for an example. - # - # source://activestorage//lib/active_storage/service.rb#60 - def build(configurator:, name:, service: T.unsafe(nil), **service_config); end - - # Configure an Active Storage service by name from a set of configurations, - # typically loaded from a YAML file. The Active Storage engine uses this - # to set the global Active Storage service when the app boots. - # - # source://activestorage//lib/active_storage/service.rb#50 - def configure(service_name, configurations); end - end -end - -# source://activestorage//lib/active_storage/service/configurator.rb#4 -class ActiveStorage::Service::Configurator - # source://activestorage//lib/active_storage/service/configurator.rb#11 - def initialize(configurations); end - - # source://activestorage//lib/active_storage/service/configurator.rb#15 - def build(service_name); end - - # source://activestorage//lib/active_storage/service/configurator.rb#5 - def configurations; end - - private - - # source://activestorage//lib/active_storage/service/configurator.rb#23 - def config_for(name); end - - # source://activestorage//lib/active_storage/service/configurator.rb#29 - def resolve(class_name); end - - class << self - # source://activestorage//lib/active_storage/service/configurator.rb#7 - def build(service_name, configurations); end - end -end - -# source://activestorage//lib/active_storage/service/registry.rb#4 -class ActiveStorage::Service::Registry - # source://activestorage//lib/active_storage/service/registry.rb#5 - def initialize(configurations); end - - # source://activestorage//lib/active_storage/service/registry.rb#10 - def fetch(name); end - - private - - # source://activestorage//lib/active_storage/service/registry.rb#26 - def configurations; end - - # source://activestorage//lib/active_storage/service/registry.rb#28 - def configurator; end - - # source://activestorage//lib/active_storage/service/registry.rb#26 - def services; end -end - -module ActiveStorage::SetBlob - extend ::ActiveSupport::Concern - - private - - def blob_scope; end - def set_blob; end -end - -module ActiveStorage::SetCurrent - extend ::ActiveSupport::Concern -end - -module ActiveStorage::Streaming - extend ::ActiveSupport::Concern - include ::ActionController::Rendering - include ::ActionController::DataStreaming - include ::ActionController::Live - - mixes_in_class_methods ::ActionController::Rendering::ClassMethods - mixes_in_class_methods ::ActionController::Live::ClassMethods - - private - - def send_blob_byte_range_data(blob, range_header, disposition: T.unsafe(nil)); end - def send_blob_stream(blob, disposition: T.unsafe(nil)); end -end - -ActiveStorage::Streaming::DEFAULT_BLOB_STREAMING_DISPOSITION = T.let(T.unsafe(nil), String) - -# source://activestorage//lib/active_storage.rb#367 -module ActiveStorage::Transformers - extend ::ActiveSupport::Autoload -end - -# source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#14 -class ActiveStorage::Transformers::ImageProcessingTransformer < ::ActiveStorage::Transformers::Transformer - private - - # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#32 - def operations; end - - # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#19 - def process(file, format:); end - - # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#28 - def processor; end - - # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#79 - def validate_arg_array(argument); end - - # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#93 - def validate_arg_hash(argument); end - - # @raise [UnsupportedImageProcessingArgument] - # - # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#71 - def validate_arg_string(argument); end - - # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#51 - def validate_transformation(name, argument); end -end - -# source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#17 -class ActiveStorage::Transformers::ImageProcessingTransformer::UnsupportedImageProcessingArgument < ::StandardError; end - -# source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#16 -class ActiveStorage::Transformers::ImageProcessingTransformer::UnsupportedImageProcessingMethod < ::StandardError; end - -# A Transformer applies a set of transformations to an image. -# -# The following concrete subclasses are included in Active Storage: -# -# * ActiveStorage::Transformers::ImageProcessingTransformer: -# backed by ImageProcessing, a common interface for MiniMagick and ruby-vips -# -# source://activestorage//lib/active_storage/transformers/transformer.rb#11 -class ActiveStorage::Transformers::Transformer - # @return [Transformer] a new instance of Transformer - # - # source://activestorage//lib/active_storage/transformers/transformer.rb#14 - def initialize(transformations); end - - # Applies the transformations to the source image in +file+, producing a target image in the - # specified +format+. Yields an open Tempfile containing the target image. Closes and unlinks - # the output tempfile after yielding to the given block. Returns the result of the block. - # - # source://activestorage//lib/active_storage/transformers/transformer.rb#21 - def transform(file, format:); end - - # Returns the value of attribute transformations. - # - # source://activestorage//lib/active_storage/transformers/transformer.rb#12 - def transformations; end - - private - - # Returns an open Tempfile containing a transformed image in the given +format+. - # All subclasses implement this method. - # - # @raise [NotImplementedError] - # - # source://activestorage//lib/active_storage/transformers/transformer.rb#34 - def process(file, format:); end -end - -# Raised when ActiveStorage::Blob#preview is called on a blob that isn't previewable. -# Use ActiveStorage::Blob#previewable? to determine whether a blob is previewable. -# -# source://activestorage//lib/active_storage/errors.rb#13 -class ActiveStorage::UnpreviewableError < ::ActiveStorage::Error; end - -# Raised when ActiveStorage::Blob#representation is called on a blob that isn't representable. -# Use ActiveStorage::Blob#representable? to determine whether a blob is representable. -# -# source://activestorage//lib/active_storage/errors.rb#17 -class ActiveStorage::UnrepresentableError < ::ActiveStorage::Error; end - -# source://activestorage//lib/active_storage/gem_version.rb#9 -module ActiveStorage::VERSION; end - -# source://activestorage//lib/active_storage/gem_version.rb#10 -ActiveStorage::VERSION::MAJOR = T.let(T.unsafe(nil), Integer) - -# source://activestorage//lib/active_storage/gem_version.rb#11 -ActiveStorage::VERSION::MINOR = T.let(T.unsafe(nil), Integer) - -# source://activestorage//lib/active_storage/gem_version.rb#13 -ActiveStorage::VERSION::PRE = T.let(T.unsafe(nil), T.untyped) - -# source://activestorage//lib/active_storage/gem_version.rb#15 -ActiveStorage::VERSION::STRING = T.let(T.unsafe(nil), String) - -# source://activestorage//lib/active_storage/gem_version.rb#12 -ActiveStorage::VERSION::TINY = T.let(T.unsafe(nil), Integer) - -class ActiveStorage::Variant - def initialize(blob, variation_or_variation_key); end - - def blob; end - def content_type(*_arg0, **_arg1, &_arg2); end - def content_type_for_serving(*_arg0, **_arg1, &_arg2); end - def download(&block); end - def filename; end - def forced_disposition_for_serving; end - def image; end - def key; end - def processed; end - def service(*_arg0, **_arg1, &_arg2); end - def url(expires_in: T.unsafe(nil), disposition: T.unsafe(nil)); end - def variation; end - - private - - def process; end - def processed?; end -end - -class ActiveStorage::VariantRecord < ::ActiveStorage::Record - include ::ActiveStorage::VariantRecord::GeneratedAttributeMethods - include ::ActiveStorage::VariantRecord::GeneratedAssociationMethods - - # source://activerecord/7.0.5/lib/active_record/autosave_association.rb#160 - def autosave_associated_records_for_blob(*args); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activerecord/7.0.5/lib/active_record/reflection.rb#11 - def _reflections; end - - # source://activemodel/7.0.5/lib/active_model/validations.rb#52 - def _validators; end - - # source://activerecord/7.0.5/lib/active_record/enum.rb#116 - def defined_enums; end - end -end - -module ActiveStorage::VariantRecord::GeneratedAssociationMethods - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#103 - def blob; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/association.rb#111 - def blob=(value); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#132 - def blob_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/belongs_to.rb#136 - def blob_previously_changed?; end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#28 - def build_blob(*args, &block); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#32 - def create_blob(*args, &block); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#36 - def create_blob!(*args, &block); end - - # source://activerecord/7.0.5/lib/active_record/associations/builder/singular_association.rb#19 - def reload_blob; end -end - -module ActiveStorage::VariantRecord::GeneratedAttributeMethods; end - -class ActiveStorage::VariantWithRecord - def initialize(blob, variation); end - - def blob; end - def download(*_arg0, **_arg1, &_arg2); end - def image; end - def key(*_arg0, **_arg1, &_arg2); end - def process; end - def processed; end - def processed?; end - def service(*_arg0, **_arg1, &_arg2); end - def url(*_arg0, **_arg1, &_arg2); end - def variation; end - - private - - def create_or_find_record(image:); end - def record; end - def transform_blob; end -end - -class ActiveStorage::Variation - def initialize(transformations); end - - def content_type; end - def default_to(defaults); end - def digest; end - def format; end - def key; end - def transform(file, &block); end - def transformations; end - - private - - def transformer; end - - class << self - def decode(key); end - def encode(transformations); end - def wrap(variator); end - end -end diff --git a/sorbet/rbi/gems/activestorage@7.2.0.rbi b/sorbet/rbi/gems/activestorage@7.2.0.rbi new file mode 100644 index 000000000..42f9cf902 --- /dev/null +++ b/sorbet/rbi/gems/activestorage@7.2.0.rbi @@ -0,0 +1,3711 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `activestorage` gem. +# Please instead update this file by running `bin/tapioca gem activestorage`. + + +class ActiveRecord::Base + include ::ActiveModel::ForbiddenAttributesProtection + include ::ActiveModel::AttributeAssignment + include ::ActiveModel::Access + include ::ActiveModel::Serialization + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _before_commit_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _commit_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _create_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _destroy_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _find_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _initialize_callbacks; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _rollback_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_before_commit_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_commit_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_create_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_destroy_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_find_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_initialize_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_rollback_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_save_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_touch_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_update_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_validate_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_validation_callbacks(&block); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _save_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _touch_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _update_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _validate_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _validation_callbacks; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators?; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#12 + def aggregate_reflections; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#12 + def aggregate_reflections?; end + + # source://activestorage//lib/active_storage/reflection.rb#53 + def attachment_reflections; end + + # source://activestorage//lib/active_storage/reflection.rb#53 + def attachment_reflections?; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 + def attribute_aliases; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 + def attribute_aliases?; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns?; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#13 + def automatic_scope_inversing; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#13 + def automatic_scope_inversing?; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations?; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#16 + def cache_timestamp_format; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#16 + def cache_timestamp_format?; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#24 + def cache_versioning; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#24 + def cache_versioning?; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#32 + def collection_cache_versioning; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#32 + def collection_cache_versioning?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#183 + def column_for_attribute(name, &_arg1); end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#10 + def counter_cached_association_names; end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#10 + def counter_cached_association_names?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#97 + def default_connection_handler; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#97 + def default_connection_handler?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#99 + def default_role; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#99 + def default_role?; end + + # source://activerecord/7.2.0/lib/active_record/scoping/default.rb#20 + def default_scope_override; end + + # source://activerecord/7.2.0/lib/active_record/scoping/default.rb#19 + def default_scopes; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#101 + def default_shard; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#101 + def default_shard?; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#47 + def destroy_association_async_batch_size; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#37 + def destroy_association_async_job(&_arg0); end + + # source://activerecord/7.2.0/lib/active_record/encryption/encryptable_record.rb#11 + def encrypted_attributes; end + + # source://activerecord/7.2.0/lib/active_record/encryption/encryptable_record.rb#11 + def encrypted_attributes=(_arg0); end + + # source://activerecord/7.2.0/lib/active_record/encryption/encryptable_record.rb#11 + def encrypted_attributes?; end + + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 + def include_root_in_json; end + + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 + def include_root_in_json?; end + + # source://activerecord/7.2.0/lib/active_record/locking/optimistic.rb#56 + def lock_optimistically; end + + # source://activerecord/7.2.0/lib/active_record/locking/optimistic.rb#56 + def lock_optimistically?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#22 + def logger; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#22 + def logger?; end + + # source://activemodel/7.2.0/lib/active_model/naming.rb#255 + def model_name(&_arg0); end + + # source://activerecord/7.2.0/lib/active_record/nested_attributes.rb#15 + def nested_attributes_options; end + + # source://activerecord/7.2.0/lib/active_record/nested_attributes.rb#15 + def nested_attributes_options?; end + + # source://activerecord/7.2.0/lib/active_record/normalization.rb#8 + def normalized_attributes; end + + # source://activerecord/7.2.0/lib/active_record/normalization.rb#8 + def normalized_attributes=(_arg0); end + + # source://activerecord/7.2.0/lib/active_record/normalization.rb#8 + def normalized_attributes?; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(_arg0); end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#50 + def partial_inserts; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#50 + def partial_inserts?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#49 + def partial_updates; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#49 + def partial_updates?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#168 + def pluralize_table_names; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#168 + def pluralize_table_names?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#163 + def primary_key_prefix_type; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#163 + def primary_key_prefix_type?; end + + # source://activerecord/7.2.0/lib/active_record/timestamp.rb#47 + def record_timestamps; end + + # source://activerecord/7.2.0/lib/active_record/timestamp.rb#47 + def record_timestamps=(_arg0); end + + # source://activerecord/7.2.0/lib/active_record/timestamp.rb#47 + def record_timestamps?; end + + # source://activerecord/7.2.0/lib/active_record/signed_id.rb#13 + def signed_id_verifier_secret; end + + # source://activerecord/7.2.0/lib/active_record/signed_id.rb#13 + def signed_id_verifier_secret?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#67 + def skip_time_zone_conversion_for_attributes; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#67 + def skip_time_zone_conversion_for_attributes?; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#43 + def store_full_class_name; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#43 + def store_full_class_name?; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#47 + def store_full_sti_class; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#47 + def store_full_sti_class?; end + + def suppressed_turbo_broadcasts?(&_arg0); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#164 + def table_name_prefix; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#164 + def table_name_prefix?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#165 + def table_name_suffix; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#165 + def table_name_suffix?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#66 + def time_zone_aware_attributes; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#66 + def time_zone_aware_attributes?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#68 + def time_zone_aware_types; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#68 + def time_zone_aware_types?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#183 + def type_for_attribute(*_arg0, **_arg1, &_arg2); end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 + def validation_context; end + + private + + # source://activemodel/7.2.0/lib/active_model/validations.rb#67 + def validation_context=(_arg0); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activerecord/7.2.0/lib/active_record/readonly_attributes.rb#11 + def _attr_readonly; end + + # source://activerecord/7.2.0/lib/active_record/readonly_attributes.rb#11 + def _attr_readonly=(value); end + + # source://activerecord/7.2.0/lib/active_record/readonly_attributes.rb#11 + def _attr_readonly?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _before_commit_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _before_commit_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _commit_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _commit_callbacks=(value); end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#9 + def _counter_cache_columns; end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#9 + def _counter_cache_columns=(value); end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#9 + def _counter_cache_columns?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _create_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _create_callbacks=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#24 + def _destroy_association_async_job; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#24 + def _destroy_association_async_job=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#24 + def _destroy_association_async_job?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _destroy_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _destroy_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _find_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _find_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _initialize_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _initialize_callbacks=(value); end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections=(value); end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _rollback_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _rollback_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _save_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _save_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _touch_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _touch_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _update_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _update_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _validate_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _validate_callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _validation_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _validation_callbacks=(value); end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators=(value); end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators?; end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 + def after_create(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 + def after_destroy(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 + def after_find(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 + def after_initialize(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 + def after_save(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 + def after_touch(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#144 + def after_update(*args, **options, &block); end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#12 + def aggregate_reflections; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#12 + def aggregate_reflections=(value); end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#12 + def aggregate_reflections?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#108 + def application_record_class?; end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 + def around_create(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 + def around_destroy(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 + def around_save(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#137 + def around_update(*args, **options, &block); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#128 + def asynchronous_queries_session; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#132 + def asynchronous_queries_tracker; end + + # source://activestorage//lib/active_storage/reflection.rb#53 + def attachment_reflections; end + + # source://activestorage//lib/active_storage/reflection.rb#53 + def attachment_reflections=(value); end + + # source://activestorage//lib/active_storage/reflection.rb#53 + def attachment_reflections?; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 + def attribute_aliases; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 + def attribute_aliases=(value); end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#71 + def attribute_aliases?; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns; end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns=(value); end + + # source://activemodel/7.2.0/lib/active_model/attribute_methods.rb#72 + def attribute_method_patterns?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#106 + def attributes_for_inspect; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#106 + def attributes_for_inspect=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#106 + def attributes_for_inspect?; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#13 + def automatic_scope_inversing; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#13 + def automatic_scope_inversing=(value); end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#13 + def automatic_scope_inversing?; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations=(value); end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#14 + def automatically_invert_plural_associations?; end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 + def before_create(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 + def before_destroy(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 + def before_save(*args, **options, &block); end + + # source://activemodel/7.2.0/lib/active_model/callbacks.rb#130 + def before_update(*args, **options, &block); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#89 + def belongs_to_required_by_default; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#89 + def belongs_to_required_by_default=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#89 + def belongs_to_required_by_default?; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#16 + def cache_timestamp_format; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#16 + def cache_timestamp_format=(value); end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#16 + def cache_timestamp_format?; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#24 + def cache_versioning; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#24 + def cache_versioning=(value); end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#24 + def cache_versioning?; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#32 + def collection_cache_versioning; end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#32 + def collection_cache_versioning=(value); end + + # source://activerecord/7.2.0/lib/active_record/integration.rb#32 + def collection_cache_versioning?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#77 + def configurations; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#71 + def configurations=(config); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#192 + def connected_to_stack; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#206 + def connection_class; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#202 + def connection_class=(b); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#210 + def connection_class?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#214 + def connection_class_for_self; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#120 + def connection_handler; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#124 + def connection_handler=(handler); end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#10 + def counter_cached_association_names; end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#10 + def counter_cached_association_names=(value); end + + # source://activerecord/7.2.0/lib/active_record/counter_cache.rb#10 + def counter_cached_association_names?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#183 + def current_preventing_writes; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#146 + def current_role; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#164 + def current_shard; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/serialization.rb#20 + def default_column_serializer; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/serialization.rb#20 + def default_column_serializer=(value); end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/serialization.rb#20 + def default_column_serializer?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#97 + def default_connection_handler; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#97 + def default_connection_handler=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#97 + def default_connection_handler?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#99 + def default_role; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#99 + def default_role=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#99 + def default_role?; end + + # source://activerecord/7.2.0/lib/active_record/scoping/default.rb#20 + def default_scope_override; end + + # source://activerecord/7.2.0/lib/active_record/scoping/default.rb#20 + def default_scope_override=(value); end + + # source://activerecord/7.2.0/lib/active_record/scoping/default.rb#19 + def default_scopes; end + + # source://activerecord/7.2.0/lib/active_record/scoping/default.rb#19 + def default_scopes=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#101 + def default_shard; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#101 + def default_shard=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#101 + def default_shard?; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums=(value); end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#47 + def destroy_association_async_batch_size; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#47 + def destroy_association_async_batch_size=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#27 + def destroy_association_async_job; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#24 + def destroy_association_async_job=(value); end + + # source://activerecord/7.2.0/lib/active_record/encryption/encryptable_record.rb#11 + def encrypted_attributes; end + + # source://activerecord/7.2.0/lib/active_record/encryption/encryptable_record.rb#11 + def encrypted_attributes=(value); end + + # source://activerecord/7.2.0/lib/active_record/encryption/encryptable_record.rb#11 + def encrypted_attributes?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#87 + def enumerate_columns_in_select_statements; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#87 + def enumerate_columns_in_select_statements=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#87 + def enumerate_columns_in_select_statements?; end + + # source://activerecord/7.2.0/lib/active_record/token_for.rb#11 + def generated_token_verifier; end + + # source://activerecord/7.2.0/lib/active_record/token_for.rb#11 + def generated_token_verifier=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#93 + def has_many_inversing; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#93 + def has_many_inversing=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#93 + def has_many_inversing?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#170 + def immutable_strings_by_default; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#170 + def immutable_strings_by_default=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#170 + def immutable_strings_by_default?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#169 + def implicit_order_column; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#169 + def implicit_order_column=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#169 + def implicit_order_column?; end + + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 + def include_root_in_json; end + + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 + def include_root_in_json=(value); end + + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 + def include_root_in_json?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#172 + def inheritance_column; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#326 + def inheritance_column=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#172 + def inheritance_column?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#167 + def internal_metadata_table_name; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#167 + def internal_metadata_table_name=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#167 + def internal_metadata_table_name?; end + + # source://activerecord/7.2.0/lib/active_record/store.rb#101 + def local_stored_attributes; end + + # source://activerecord/7.2.0/lib/active_record/store.rb#101 + def local_stored_attributes=(_arg0); end + + # source://activerecord/7.2.0/lib/active_record/locking/optimistic.rb#56 + def lock_optimistically; end + + # source://activerecord/7.2.0/lib/active_record/locking/optimistic.rb#56 + def lock_optimistically=(value); end + + # source://activerecord/7.2.0/lib/active_record/locking/optimistic.rb#56 + def lock_optimistically?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#22 + def logger; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#22 + def logger=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#22 + def logger?; end + + # source://activerecord/7.2.0/lib/active_record/nested_attributes.rb#15 + def nested_attributes_options; end + + # source://activerecord/7.2.0/lib/active_record/nested_attributes.rb#15 + def nested_attributes_options=(value); end + + # source://activerecord/7.2.0/lib/active_record/nested_attributes.rb#15 + def nested_attributes_options?; end + + # source://activerecord/7.2.0/lib/active_record/normalization.rb#8 + def normalized_attributes; end + + # source://activerecord/7.2.0/lib/active_record/normalization.rb#8 + def normalized_attributes=(value); end + + # source://activerecord/7.2.0/lib/active_record/normalization.rb#8 + def normalized_attributes?; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter; end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter=(value); end + + # source://activemodel/7.2.0/lib/active_model/conversion.rb#32 + def param_delimiter?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#50 + def partial_inserts; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#50 + def partial_inserts=(value); end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#50 + def partial_inserts?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#49 + def partial_updates; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#49 + def partial_updates=(value); end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/dirty.rb#49 + def partial_updates?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#168 + def pluralize_table_names; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#168 + def pluralize_table_names=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#168 + def pluralize_table_names?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#163 + def primary_key_prefix_type; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#163 + def primary_key_prefix_type=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#163 + def primary_key_prefix_type?; end + + # source://activerecord/7.2.0/lib/active_record/timestamp.rb#47 + def record_timestamps; end + + # source://activerecord/7.2.0/lib/active_record/timestamp.rb#47 + def record_timestamps=(value); end + + # source://activerecord/7.2.0/lib/active_record/timestamp.rb#47 + def record_timestamps?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#95 + def run_commit_callbacks_on_first_saved_instances_in_transaction; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#95 + def run_commit_callbacks_on_first_saved_instances_in_transaction=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#95 + def run_commit_callbacks_on_first_saved_instances_in_transaction?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#166 + def schema_migrations_table_name; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#166 + def schema_migrations_table_name=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#166 + def schema_migrations_table_name?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#103 + def shard_selector; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#103 + def shard_selector=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#103 + def shard_selector?; end + + # source://activerecord/7.2.0/lib/active_record/signed_id.rb#13 + def signed_id_verifier_secret; end + + # source://activerecord/7.2.0/lib/active_record/signed_id.rb#13 + def signed_id_verifier_secret=(value); end + + # source://activerecord/7.2.0/lib/active_record/signed_id.rb#13 + def signed_id_verifier_secret?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#67 + def skip_time_zone_conversion_for_attributes; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#67 + def skip_time_zone_conversion_for_attributes=(value); end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#67 + def skip_time_zone_conversion_for_attributes?; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#43 + def store_full_class_name; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#43 + def store_full_class_name=(value); end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#43 + def store_full_class_name?; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#47 + def store_full_sti_class; end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#47 + def store_full_sti_class=(value); end + + # source://activerecord/7.2.0/lib/active_record/inheritance.rb#47 + def store_full_sti_class?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#91 + def strict_loading_by_default; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#91 + def strict_loading_by_default=(value); end + + # source://activerecord/7.2.0/lib/active_record/core.rb#91 + def strict_loading_by_default?; end + + # source://activerecord/7.2.0/lib/active_record/core.rb#229 + def strict_loading_violation!(owner:, reflection:); end + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#49 + def suppressed_turbo_broadcasts; end + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#108 + def suppressed_turbo_broadcasts=(obj); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#164 + def table_name_prefix; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#164 + def table_name_prefix=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#164 + def table_name_prefix?; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#165 + def table_name_suffix; end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#165 + def table_name_suffix=(value); end + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#165 + def table_name_suffix?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#66 + def time_zone_aware_attributes; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#66 + def time_zone_aware_attributes=(value); end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#66 + def time_zone_aware_attributes?; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#68 + def time_zone_aware_types; end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#68 + def time_zone_aware_types=(value); end + + # source://activerecord/7.2.0/lib/active_record/attribute_methods/time_zone_conversion.rb#68 + def time_zone_aware_types?; end + + # source://activerecord/7.2.0/lib/active_record/token_for.rb#10 + def token_definitions; end + + # source://activerecord/7.2.0/lib/active_record/token_for.rb#10 + def token_definitions=(value); end + + private + + # source://activerecord/7.2.0/lib/active_record/model_schema.rb#172 + def _inheritance_column=(value); end + end +end + +# :markup: markdown +# :include: ../README.md +# +# source://activestorage//lib/active_storage/gem_version.rb#3 +module ActiveStorage + extend ::ActiveSupport::Autoload + + # source://activestorage//lib/active_storage.rb#55 + def analyzers; end + + # source://activestorage//lib/active_storage.rb#55 + def analyzers=(val); end + + # source://activestorage//lib/active_storage.rb#61 + def binary_content_type; end + + # source://activestorage//lib/active_storage.rb#61 + def binary_content_type=(val); end + + # source://activestorage//lib/active_storage.rb#63 + def content_types_allowed_inline; end + + # source://activestorage//lib/active_storage.rb#63 + def content_types_allowed_inline=(val); end + + # source://activestorage//lib/active_storage.rb#62 + def content_types_to_serve_as_binary; end + + # source://activestorage//lib/active_storage.rb#62 + def content_types_to_serve_as_binary=(val); end + + # source://activestorage//lib/active_storage.rb#361 + def draw_routes; end + + # source://activestorage//lib/active_storage.rb#361 + def draw_routes=(val); end + + # source://activestorage//lib/active_storage.rb#48 + def logger; end + + # source://activestorage//lib/active_storage.rb#48 + def logger=(val); end + + # source://activestorage//lib/active_storage.rb#57 + def paths; end + + # source://activestorage//lib/active_storage.rb#57 + def paths=(val); end + + # source://activestorage//lib/active_storage.rb#54 + def previewers; end + + # source://activestorage//lib/active_storage.rb#54 + def previewers=(val); end + + # source://activestorage//lib/active_storage.rb#52 + def queues; end + + # source://activestorage//lib/active_storage.rb#52 + def queues=(val); end + + # source://activestorage//lib/active_storage.rb#362 + def resolve_model_to_route; end + + # source://activestorage//lib/active_storage.rb#362 + def resolve_model_to_route=(val); end + + # source://activestorage//lib/active_storage.rb#360 + def routes_prefix; end + + # source://activestorage//lib/active_storage.rb#360 + def routes_prefix=(val); end + + # source://activestorage//lib/active_storage.rb#356 + def service_urls_expire_in; end + + # source://activestorage//lib/active_storage.rb#356 + def service_urls_expire_in=(val); end + + # source://activestorage//lib/active_storage.rb#65 + def supported_image_processing_methods; end + + # source://activestorage//lib/active_storage.rb#65 + def supported_image_processing_methods=(val); end + + # source://activestorage//lib/active_storage.rb#357 + def touch_attachment_records; end + + # source://activestorage//lib/active_storage.rb#357 + def touch_attachment_records=(val); end + + # source://activestorage//lib/active_storage.rb#364 + def track_variants; end + + # source://activestorage//lib/active_storage.rb#364 + def track_variants=(val); end + + # source://activestorage//lib/active_storage.rb#354 + def unsupported_image_processing_arguments; end + + # source://activestorage//lib/active_storage.rb#354 + def unsupported_image_processing_arguments=(val); end + + # source://activestorage//lib/active_storage.rb#358 + def urls_expire_in; end + + # source://activestorage//lib/active_storage.rb#358 + def urls_expire_in=(val); end + + # source://activestorage//lib/active_storage.rb#59 + def variable_content_types; end + + # source://activestorage//lib/active_storage.rb#59 + def variable_content_types=(val); end + + # source://activestorage//lib/active_storage.rb#50 + def variant_processor; end + + # source://activestorage//lib/active_storage.rb#50 + def variant_processor=(val); end + + # source://activestorage//lib/active_storage.rb#49 + def verifier; end + + # source://activestorage//lib/active_storage.rb#49 + def verifier=(val); end + + # source://activestorage//lib/active_storage.rb#366 + def video_preview_arguments; end + + # source://activestorage//lib/active_storage.rb#366 + def video_preview_arguments=(val); end + + # source://activestorage//lib/active_storage.rb#60 + def web_image_content_types; end + + # source://activestorage//lib/active_storage.rb#60 + def web_image_content_types=(val); end + + class << self + # source://activestorage//lib/active_storage.rb#55 + def analyzers; end + + # source://activestorage//lib/active_storage.rb#55 + def analyzers=(val); end + + # source://activestorage//lib/active_storage.rb#61 + def binary_content_type; end + + # source://activestorage//lib/active_storage.rb#61 + def binary_content_type=(val); end + + # source://activestorage//lib/active_storage.rb#63 + def content_types_allowed_inline; end + + # source://activestorage//lib/active_storage.rb#63 + def content_types_allowed_inline=(val); end + + # source://activestorage//lib/active_storage.rb#62 + def content_types_to_serve_as_binary; end + + # source://activestorage//lib/active_storage.rb#62 + def content_types_to_serve_as_binary=(val); end + + # source://activestorage//lib/active_storage/deprecator.rb#4 + def deprecator; end + + # source://activestorage//lib/active_storage.rb#361 + def draw_routes; end + + # source://activestorage//lib/active_storage.rb#361 + def draw_routes=(val); end + + # Returns the currently loaded version of Active Storage as a +Gem::Version+. + # + # source://activestorage//lib/active_storage/gem_version.rb#5 + def gem_version; end + + # source://activestorage//lib/active_storage.rb#48 + def logger; end + + # source://activestorage//lib/active_storage.rb#48 + def logger=(val); end + + # source://activestorage//lib/active_storage.rb#57 + def paths; end + + # source://activestorage//lib/active_storage.rb#57 + def paths=(val); end + + # source://activestorage//lib/active_storage.rb#54 + def previewers; end + + # source://activestorage//lib/active_storage.rb#54 + def previewers=(val); end + + # source://activestorage//lib/active_storage.rb#52 + def queues; end + + # source://activestorage//lib/active_storage.rb#52 + def queues=(val); end + + # source://railties/7.2.0/lib/rails/engine.rb#412 + def railtie_helpers_paths; end + + # source://railties/7.2.0/lib/rails/engine.rb#395 + def railtie_namespace; end + + # source://railties/7.2.0/lib/rails/engine.rb#416 + def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end + + # source://activestorage//lib/active_storage.rb#362 + def resolve_model_to_route; end + + # source://activestorage//lib/active_storage.rb#362 + def resolve_model_to_route=(val); end + + # source://activestorage//lib/active_storage.rb#360 + def routes_prefix; end + + # source://activestorage//lib/active_storage.rb#360 + def routes_prefix=(val); end + + # source://activestorage//lib/active_storage.rb#356 + def service_urls_expire_in; end + + # source://activestorage//lib/active_storage.rb#356 + def service_urls_expire_in=(val); end + + # source://activestorage//lib/active_storage.rb#65 + def supported_image_processing_methods; end + + # source://activestorage//lib/active_storage.rb#65 + def supported_image_processing_methods=(val); end + + # source://railties/7.2.0/lib/rails/engine.rb#401 + def table_name_prefix; end + + # source://activestorage//lib/active_storage.rb#357 + def touch_attachment_records; end + + # source://activestorage//lib/active_storage.rb#357 + def touch_attachment_records=(val); end + + # source://activestorage//lib/active_storage.rb#364 + def track_variants; end + + # source://activestorage//lib/active_storage.rb#364 + def track_variants=(val); end + + # source://activestorage//lib/active_storage.rb#354 + def unsupported_image_processing_arguments; end + + # source://activestorage//lib/active_storage.rb#354 + def unsupported_image_processing_arguments=(val); end + + # source://activestorage//lib/active_storage.rb#358 + def urls_expire_in; end + + # source://activestorage//lib/active_storage.rb#358 + def urls_expire_in=(val); end + + # source://railties/7.2.0/lib/rails/engine.rb#408 + def use_relative_model_naming?; end + + # source://activestorage//lib/active_storage.rb#59 + def variable_content_types; end + + # source://activestorage//lib/active_storage.rb#59 + def variable_content_types=(val); end + + # source://activestorage//lib/active_storage.rb#50 + def variant_processor; end + + # source://activestorage//lib/active_storage.rb#50 + def variant_processor=(val); end + + # source://activestorage//lib/active_storage.rb#49 + def verifier; end + + # source://activestorage//lib/active_storage.rb#49 + def verifier=(val); end + + # Returns the currently loaded version of Active Storage as a +Gem::Version+. + # + # source://activestorage//lib/active_storage/version.rb#7 + def version; end + + # source://activestorage//lib/active_storage.rb#366 + def video_preview_arguments; end + + # source://activestorage//lib/active_storage.rb#366 + def video_preview_arguments=(val); end + + # source://activestorage//lib/active_storage.rb#60 + def web_image_content_types; end + + # source://activestorage//lib/active_storage.rb#60 + def web_image_content_types=(val); end + end +end + +class ActiveStorage::AnalyzeJob < ::ActiveStorage::BaseJob + def perform(blob); end + + class << self + # source://activejob/7.2.0/lib/active_job/queue_name.rb#55 + def queue_name; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +# = Active Storage \Analyzer +# +# This is an abstract base class for analyzers, which extract metadata from blobs. See +# ActiveStorage::Analyzer::VideoAnalyzer for an example of a concrete subclass. +# +# source://activestorage//lib/active_storage/analyzer.rb#8 +class ActiveStorage::Analyzer + # @return [Analyzer] a new instance of Analyzer + # + # source://activestorage//lib/active_storage/analyzer.rb#23 + def initialize(blob); end + + # Returns the value of attribute blob. + # + # source://activestorage//lib/active_storage/analyzer.rb#9 + def blob; end + + # Override this method in a concrete subclass. Have it return a Hash of metadata. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/analyzer.rb#28 + def metadata; end + + private + + # Downloads the blob to a tempfile on disk. Yields the tempfile. + # + # source://activestorage//lib/active_storage/analyzer.rb#34 + def download_blob_to_tempfile(&block); end + + # source://activestorage//lib/active_storage/analyzer.rb#46 + def instrument(analyzer, &block); end + + # source://activestorage//lib/active_storage/analyzer.rb#38 + def logger; end + + # source://activestorage//lib/active_storage/analyzer.rb#42 + def tmpdir; end + + class << self + # Implement this method in a concrete subclass. Have it return true when given a blob from which + # the analyzer can extract metadata. + # + # @return [Boolean] + # + # source://activestorage//lib/active_storage/analyzer.rb#13 + def accept?(blob); end + + # Implement this method in concrete subclasses. It will determine if blob analysis + # should be done in a job or performed inline. By default, analysis is enqueued in a job. + # + # @return [Boolean] + # + # source://activestorage//lib/active_storage/analyzer.rb#19 + def analyze_later?; end + end +end + +# source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#14 +class ActiveStorage::Analyzer::AudioAnalyzer < ::ActiveStorage::Analyzer + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#19 + def metadata; end + + private + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#44 + def audio_stream; end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#29 + def bit_rate; end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#24 + def duration; end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#73 + def ffprobe_path; end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#52 + def probe; end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#56 + def probe_from(file); end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#34 + def sample_rate; end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#48 + def streams; end + + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#39 + def tags; end + + class << self + # source://activestorage//lib/active_storage/analyzer/audio_analyzer.rb#15 + def accept?(blob); end + end +end + +# source://activestorage//lib/active_storage/analyzer/image_analyzer.rb#14 +class ActiveStorage::Analyzer::ImageAnalyzer < ::ActiveStorage::Analyzer + # source://activestorage//lib/active_storage/analyzer/image_analyzer.rb#19 + def metadata; end + + class << self + # source://activestorage//lib/active_storage/analyzer/image_analyzer.rb#15 + def accept?(blob); end + end +end + +# source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#6 +class ActiveStorage::Analyzer::ImageAnalyzer::ImageMagick < ::ActiveStorage::Analyzer::ImageAnalyzer + private + + # source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#12 + def read_image; end + + # source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#37 + def rotated_image?(image); end + + class << self + # source://activestorage//lib/active_storage/analyzer/image_analyzer/image_magick.rb#7 + def accept?(blob); end + end +end + +# source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#6 +class ActiveStorage::Analyzer::ImageAnalyzer::Vips < ::ActiveStorage::Analyzer::ImageAnalyzer + private + + # source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#12 + def read_image; end + + # source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#41 + def rotated_image?(image); end + + class << self + # source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#7 + def accept?(blob); end + end +end + +# source://activestorage//lib/active_storage/analyzer/image_analyzer/vips.rb#40 +ActiveStorage::Analyzer::ImageAnalyzer::Vips::ROTATIONS = T.let(T.unsafe(nil), Regexp) + +# source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#4 +class ActiveStorage::Analyzer::NullAnalyzer < ::ActiveStorage::Analyzer + # source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#13 + def metadata; end + + class << self + # source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#5 + def accept?(blob); end + + # source://activestorage//lib/active_storage/analyzer/null_analyzer.rb#9 + def analyze_later?; end + end +end + +# source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#24 +class ActiveStorage::Analyzer::VideoAnalyzer < ::ActiveStorage::Analyzer + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#29 + def metadata; end + + private + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#55 + def angle; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#82 + def audio?; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#120 + def audio_stream; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#90 + def computed_height; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#128 + def container; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#67 + def display_aspect_ratio; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#104 + def display_height_scale; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#63 + def display_matrix; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#50 + def duration; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#100 + def encoded_height; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#96 + def encoded_width; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#153 + def ffprobe_path; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#42 + def height; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#132 + def probe; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#136 + def probe_from(file); end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#78 + def rotated?; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#112 + def side_data; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#124 + def streams; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#108 + def tags; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#86 + def video?; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#116 + def video_stream; end + + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#34 + def width; end + + class << self + # source://activestorage//lib/active_storage/analyzer/video_analyzer.rb#25 + def accept?(blob); end + end +end + +# = Active Storage \Attached +# +# Abstract base class for the concrete ActiveStorage::Attached::One and ActiveStorage::Attached::Many +# classes that both provide proxy access to the blob association for a record. +# +# source://activestorage//lib/active_storage/attached.rb#10 +class ActiveStorage::Attached + # @return [Attached] a new instance of Attached + # + # source://activestorage//lib/active_storage/attached.rb#13 + def initialize(name, record); end + + # Returns the value of attribute name. + # + # source://activestorage//lib/active_storage/attached.rb#11 + def name; end + + # Returns the value of attribute record. + # + # source://activestorage//lib/active_storage/attached.rb#11 + def record; end + + private + + # source://activestorage//lib/active_storage/attached.rb#18 + def change; end +end + +# source://activestorage//lib/active_storage/attached/changes.rb#4 +module ActiveStorage::Attached::Changes + extend ::ActiveSupport::Autoload +end + +# source://activestorage//lib/active_storage/attached/changes/create_many.rb#4 +class ActiveStorage::Attached::Changes::CreateMany + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#7 + def initialize(name, record, attachables, pending_uploads: T.unsafe(nil)); end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#5 + def attachables; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#14 + def attachments; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#18 + def blobs; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#5 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#5 + def pending_uploads; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#5 + def record; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#26 + def save; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#22 + def upload; end + + private + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#44 + def assign_associated_attachments; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#36 + def build_subchange_from(attachable); end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#52 + def persisted_or_new_attachments; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#48 + def reset_associated_blobs; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#32 + def subchanges; end + + # source://activestorage//lib/active_storage/attached/changes/create_many.rb#40 + def subchanges_without_blobs; end +end + +# source://activestorage//lib/active_storage/attached/changes/create_one.rb#7 +class ActiveStorage::Attached::Changes::CreateOne + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#10 + def initialize(name, record, attachable); end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#8 + def attachable; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#15 + def attachment; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#19 + def blob; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#8 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#8 + def record; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#48 + def save; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#23 + def upload; end + + private + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#120 + def attachment_service_name; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#64 + def build_attachment; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#58 + def find_attachment; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#54 + def find_or_build_attachment; end + + # source://activestorage//lib/active_storage/attached/changes/create_one.rb#68 + def find_or_build_blob; end +end + +# source://activestorage//lib/active_storage/attached/changes/create_one_of_many.rb#4 +class ActiveStorage::Attached::Changes::CreateOneOfMany < ::ActiveStorage::Attached::Changes::CreateOne + private + + # source://activestorage//lib/active_storage/attached/changes/create_one_of_many.rb#6 + def find_attachment; end +end + +# source://activestorage//lib/active_storage/attached/changes/delete_many.rb#4 +class ActiveStorage::Attached::Changes::DeleteMany + # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#7 + def initialize(name, record); end + + # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#11 + def attachables; end + + # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#15 + def attachments; end + + # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#19 + def blobs; end + + # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#5 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#5 + def record; end + + # source://activestorage//lib/active_storage/attached/changes/delete_many.rb#23 + def save; end +end + +# source://activestorage//lib/active_storage/attached/changes/delete_one.rb#4 +class ActiveStorage::Attached::Changes::DeleteOne + # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#7 + def initialize(name, record); end + + # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#11 + def attachment; end + + # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#5 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#5 + def record; end + + # source://activestorage//lib/active_storage/attached/changes/delete_one.rb#15 + def save; end +end + +# source://activestorage//lib/active_storage/attached/changes/detach_many.rb#4 +class ActiveStorage::Attached::Changes::DetachMany + # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#7 + def initialize(name, record, attachments); end + + # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#5 + def attachments; end + + # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#11 + def detach; end + + # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#5 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/detach_many.rb#5 + def record; end +end + +# source://activestorage//lib/active_storage/attached/changes/detach_one.rb#4 +class ActiveStorage::Attached::Changes::DetachOne + # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#7 + def initialize(name, record, attachment); end + + # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#5 + def attachment; end + + # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#11 + def detach; end + + # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#5 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#5 + def record; end + + private + + # source://activestorage//lib/active_storage/attached/changes/detach_one.rb#19 + def reset; end +end + +# source://activestorage//lib/active_storage/attached/changes/purge_many.rb#4 +class ActiveStorage::Attached::Changes::PurgeMany + # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#7 + def initialize(name, record, attachments); end + + # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#5 + def attachments; end + + # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#5 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#11 + def purge; end + + # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#16 + def purge_later; end + + # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#5 + def record; end + + private + + # source://activestorage//lib/active_storage/attached/changes/purge_many.rb#22 + def reset; end +end + +# source://activestorage//lib/active_storage/attached/changes/purge_one.rb#4 +class ActiveStorage::Attached::Changes::PurgeOne + # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#7 + def initialize(name, record, attachment); end + + # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#5 + def attachment; end + + # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#5 + def name; end + + # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#11 + def purge; end + + # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#16 + def purge_later; end + + # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#5 + def record; end + + private + + # source://activestorage//lib/active_storage/attached/changes/purge_one.rb#22 + def reset; end +end + +# source://activestorage//lib/active_storage/attached/many.rb#7 +class ActiveStorage::Attached::Many < ::ActiveStorage::Attached + # source://activestorage//lib/active_storage/attached/many.rb#51 + def attach(*attachables); end + + # source://activestorage//lib/active_storage/attached/many.rb#66 + def attached?; end + + # source://activestorage//lib/active_storage/attached/many.rb#32 + def attachments; end + + # source://activestorage//lib/active_storage/attached/many.rb#37 + def blobs; end + + # source://activestorage//lib/active_storage/attached/many.rb#25 + def detach(*_arg0, **_arg1, &_arg2); end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#187 + def method_missing(method, *_arg1, **_arg2, &_arg3); end + + # source://activestorage//lib/active_storage/attached/many.rb#13 + def purge(*_arg0, **_arg1, &_arg2); end + + # source://activestorage//lib/active_storage/attached/many.rb#19 + def purge_later(*_arg0, **_arg1, &_arg2); end + + private + + # source://activestorage//lib/active_storage/attached/many.rb#75 + def detach_many; end + + # source://activestorage//lib/active_storage/attached/many.rb#71 + def purge_many; end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#179 + def respond_to_missing?(name, include_private = T.unsafe(nil)); end +end + +# source://activestorage//lib/active_storage/attached/model.rb#9 +module ActiveStorage::Attached::Model + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::ActiveStorage::Attached::Model::ClassMethods + + # source://activestorage//lib/active_storage/attached/model.rb#258 + def attachment_changes; end + + # source://activestorage//lib/active_storage/attached/model.rb#262 + def changed_for_autosave?; end + + # source://activestorage//lib/active_storage/attached/model.rb#272 + def reload(*_arg0); end + + private + + # source://activestorage//lib/active_storage/attached/model.rb#266 + def initialize_dup(*_arg0); end +end + +# source://activestorage//lib/active_storage/attached/model.rb#0 +module ActiveStorage::Attached::Model::ClassMethods + # source://activestorage//lib/active_storage/attached/model.rb#206 + def has_many_attached(name, dependent: T.unsafe(nil), service: T.unsafe(nil), strict_loading: T.unsafe(nil)); end + + # source://activestorage//lib/active_storage/attached/model.rb#106 + def has_one_attached(name, dependent: T.unsafe(nil), service: T.unsafe(nil), strict_loading: T.unsafe(nil)); end +end + +# source://activestorage//lib/active_storage/attached/one.rb#7 +class ActiveStorage::Attached::One < ::ActiveStorage::Attached + # source://activestorage//lib/active_storage/attached/one.rb#58 + def attach(attachable); end + + # source://activestorage//lib/active_storage/attached/one.rb#73 + def attached?; end + + # source://activestorage//lib/active_storage/attached/one.rb#33 + def attachment; end + + # source://activestorage//lib/active_storage/attached/one.rb#44 + def blank?; end + + # source://activestorage//lib/active_storage/attached/one.rb#25 + def detach(*_arg0, **_arg1, &_arg2); end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#166 + def method_missing(method, *_arg1, **_arg2, &_arg3); end + + # source://activestorage//lib/active_storage/attached/one.rb#13 + def purge(*_arg0, **_arg1, &_arg2); end + + # source://activestorage//lib/active_storage/attached/one.rb#19 + def purge_later(*_arg0, **_arg1, &_arg2); end + + private + + # source://activestorage//lib/active_storage/attached/one.rb#82 + def detach_one; end + + # source://activestorage//lib/active_storage/attached/one.rb#78 + def purge_one; end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#158 + def respond_to_missing?(name, include_private = T.unsafe(nil)); end +end + +class ActiveStorage::Attachment < ::ActiveStorage::Record + include ::ActiveStorage::Attachment::GeneratedAttributeMethods + include ::ActiveStorage::Attachment::GeneratedAssociationMethods + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_blob(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_record(*args); end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#187 + def method_missing(method, *_arg1, **_arg2, &_arg3); end + + def preview(transformations); end + def purge; end + def purge_later; end + def representation(transformations); end + def signed_id(*_arg0, **_arg1, &_arg2); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def validate_associated_records_for_blob(*args); end + + def variant(transformations); end + + private + + def analyze_blob_later; end + def dependent; end + def mirror_blob_later; end + def named_variants; end + def purge_dependent_blob_later; end + + # source://activesupport/7.2.0/lib/active_support/delegation.rb#179 + def respond_to_missing?(name, include_private = T.unsafe(nil)); end + + def transform_variants_later; end + def transformations_by_name(transformations); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + + # source://activerecord/7.2.0/lib/active_record/scoping/named.rb#174 + def with_all_variant_records(*args, **_arg1); end + end +end + +module ActiveStorage::Attachment::GeneratedAssociationMethods + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def blob=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#146 + def blob_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#150 + def blob_previously_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#32 + def build_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#36 + def create_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#40 + def create_blob!(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def record; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def record=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#146 + def record_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#150 + def record_previously_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_record; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_record; end +end + +module ActiveStorage::Attachment::GeneratedAttributeMethods; end + +class ActiveStorage::BaseController < ::ActionController::Base + include ::ActiveStorage::SetCurrent + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 + def etag_with_template_digest; end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +class ActiveStorage::BaseJob < ::ActiveJob::Base; end + +class ActiveStorage::Blob < ::ActiveStorage::Record + include ::ActiveStorage::Blob::GeneratedAttributeMethods + include ::ActiveStorage::Blob::GeneratedAssociationMethods + include ::ActiveStorage::Blob::Analyzable + include ::ActiveStorage::Blob::Identifiable + include ::ActiveStorage::Blob::Representable + include ::ActiveStorage::Blob::Servable + include ::ActionText::Attachable + extend ::ActionText::Attachable::ClassMethods + + # source://actiontext/7.2.0/lib/action_text/engine.rb#49 + def attachable_plain_text_representation(caption = T.unsafe(nil)); end + + def audio?; end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_attachments(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_preview_image_attachment(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_preview_image_blob(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_variant_records(*args); end + + def compose(keys); end + def custom_metadata; end + def custom_metadata=(metadata); end + def delete; end + def download(&block); end + def download_chunk(range); end + def filename; end + def image?; end + def key; end + def mirror_later; end + def open(tmpdir: T.unsafe(nil), &block); end + + # source://actiontext/7.2.0/lib/action_text/engine.rb#45 + def previewable_attachable?; end + + def purge; end + def purge_later; end + + # source://activerecord/7.2.0/lib/active_record/secure_token.rb#53 + def regenerate_key; end + + def service; end + def service_headers_for_direct_upload; end + def service_url_for_direct_upload(expires_in: T.unsafe(nil)); end + def services; end + def services=(_arg0); end + def services?; end + def signed_id(purpose: T.unsafe(nil), expires_in: T.unsafe(nil), expires_at: T.unsafe(nil)); end + def text?; end + + # source://actiontext/7.2.0/lib/action_text/engine.rb#53 + def to_trix_content_attachment_partial_path; end + + def unfurl(io, identify: T.unsafe(nil)); end + def upload(io, identify: T.unsafe(nil)); end + def upload_without_unfurling(io); end + def url(expires_in: T.unsafe(nil), disposition: T.unsafe(nil), filename: T.unsafe(nil), **options); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def validate_associated_records_for_attachments(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def validate_associated_records_for_variant_records(*args); end + + def video?; end + + private + + def compute_checksum_in_chunks(io); end + def extract_content_type(io); end + def service_metadata; end + def touch_attachments; end + def update_service_metadata; end + def web_image?; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activestorage//lib/active_storage/reflection.rb#53 + def attachment_reflections; end + + def build_after_unfurling(io:, filename:, key: T.unsafe(nil), content_type: T.unsafe(nil), metadata: T.unsafe(nil), service_name: T.unsafe(nil), identify: T.unsafe(nil), record: T.unsafe(nil)); end + def combine_signed_id_purposes(purpose); end + def compose(blobs, filename:, key: T.unsafe(nil), content_type: T.unsafe(nil), metadata: T.unsafe(nil)); end + def create_after_unfurling!(io:, filename:, key: T.unsafe(nil), content_type: T.unsafe(nil), metadata: T.unsafe(nil), service_name: T.unsafe(nil), identify: T.unsafe(nil), record: T.unsafe(nil)); end + def create_and_upload!(io:, filename:, key: T.unsafe(nil), content_type: T.unsafe(nil), metadata: T.unsafe(nil), service_name: T.unsafe(nil), identify: T.unsafe(nil), record: T.unsafe(nil)); end + def create_before_direct_upload!(filename:, byte_size:, checksum:, key: T.unsafe(nil), content_type: T.unsafe(nil), metadata: T.unsafe(nil), service_name: T.unsafe(nil), record: T.unsafe(nil)); end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + + def find_signed(id, record: T.unsafe(nil), purpose: T.unsafe(nil)); end + def find_signed!(id, record: T.unsafe(nil), purpose: T.unsafe(nil)); end + def generate_unique_secure_token(length: T.unsafe(nil)); end + def scope_for_strict_loading; end + def service; end + def service=(value); end + def service?; end + def services; end + def services=(value); end + def services?; end + def signed_id_verifier; end + + # source://activerecord/7.2.0/lib/active_record/scoping/named.rb#174 + def unattached(*args, **_arg1); end + + def validate_global_service_configuration; end + def validate_service_configuration(service_name, model_class, association_name); end + + # source://activerecord/7.2.0/lib/active_record/scoping/named.rb#174 + def with_attached_preview_image(*args, **_arg1); end + end +end + +module ActiveStorage::Blob::Analyzable + def analyze; end + def analyze_later; end + def analyzed?; end + + private + + def analyzer; end + def analyzer_class; end + def extract_metadata_via_analyzer; end +end + +module ActiveStorage::Blob::GeneratedAssociationMethods + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#62 + def attachment_ids; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#72 + def attachment_ids=(ids); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def attachments; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def attachments=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#32 + def build_preview_image_attachment(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#32 + def build_preview_image_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#36 + def create_preview_image_attachment(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#40 + def create_preview_image_attachment!(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#36 + def create_preview_image_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#40 + def create_preview_image_blob!(*args, &block); end + + # source://activestorage//lib/active_storage/attached/model.rb#111 + def preview_image; end + + # source://activestorage//lib/active_storage/attached/model.rb#116 + def preview_image=(attachable); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def preview_image_attachment; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def preview_image_attachment=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def preview_image_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def preview_image_blob=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_preview_image_attachment; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_preview_image_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_preview_image_attachment; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_preview_image_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#62 + def variant_record_ids; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/collection_association.rb#72 + def variant_record_ids=(ids); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def variant_records; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def variant_records=(value); end +end + +module ActiveStorage::Blob::GeneratedAttributeMethods; end + +module ActiveStorage::Blob::Identifiable + def identified?; end + def identify; end + def identify_without_saving; end + + private + + def download_identifiable_chunk; end + def identify_content_type; end +end + +ActiveStorage::Blob::MINIMUM_TOKEN_LENGTH = T.let(T.unsafe(nil), Integer) + +module ActiveStorage::Blob::Representable + extend ::ActiveSupport::Concern + + def create_preview_image_later(variations); end + def preprocessed(transformations); end + def preview(transformations); end + def preview_image_needed_before_processing_variants?; end + def previewable?; end + def representable?; end + def representation(transformations); end + def variable?; end + def variant(transformations); end + + private + + def default_variant_format; end + def default_variant_transformations; end + def format; end + def variant_class; end +end + +module ActiveStorage::Blob::Servable + def content_type_for_serving; end + def forced_disposition_for_serving; end + + private + + def allowed_inline?; end + def forcibly_serve_as_binary?; end +end + +module ActiveStorage::Blobs; end + +class ActiveStorage::Blobs::ProxyController < ::ActiveStorage::BaseController + include ::ActiveStorage::SetBlob + include ::ActionController::Live + include ::ActiveStorage::Streaming + include ::ActiveStorage::DisableSession + extend ::ActionController::Live::ClassMethods + + def show; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +class ActiveStorage::Blobs::RedirectController < ::ActiveStorage::BaseController + include ::ActiveStorage::SetBlob + + def show; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +class ActiveStorage::Current < ::ActiveSupport::CurrentAttributes + class << self + # source://activesupport/7.2.0/lib/active_support/current_attributes.rb#192 + def defaults; end + + # source://activesupport/7.2.0/lib/active_support/current_attributes.rb#135 + def url_options; end + + # source://activesupport/7.2.0/lib/active_support/current_attributes.rb#136 + def url_options=(value); end + end +end + +class ActiveStorage::DirectUploadsController < ::ActiveStorage::BaseController + def create; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + def blob_args; end + def direct_upload_json(blob); end + + class << self + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +module ActiveStorage::DisableSession + extend ::ActiveSupport::Concern +end + +class ActiveStorage::DiskController < ::ActiveStorage::BaseController + include ::ActiveStorage::FileServer + + def show; end + def update; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + def acceptable_content?(token); end + def decode_verified_key; end + def decode_verified_token; end + def named_disk_service(name); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +# source://activestorage//lib/active_storage/downloader.rb#4 +class ActiveStorage::Downloader + # @return [Downloader] a new instance of Downloader + # + # source://activestorage//lib/active_storage/downloader.rb#7 + def initialize(service); end + + # source://activestorage//lib/active_storage/downloader.rb#11 + def open(key, checksum: T.unsafe(nil), verify: T.unsafe(nil), name: T.unsafe(nil), tmpdir: T.unsafe(nil)); end + + # Returns the value of attribute service. + # + # source://activestorage//lib/active_storage/downloader.rb#5 + def service; end + + private + + # source://activestorage//lib/active_storage/downloader.rb#30 + def download(key, file); end + + # source://activestorage//lib/active_storage/downloader.rb#20 + def open_tempfile(name, tmpdir = T.unsafe(nil)); end + + # source://activestorage//lib/active_storage/downloader.rb#37 + def verify_integrity_of(file, checksum:); end +end + +# source://activestorage//lib/active_storage/engine.rb#25 +class ActiveStorage::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end + +# Generic base class for all Active Storage exceptions. +# +# source://activestorage//lib/active_storage/errors.rb#5 +class ActiveStorage::Error < ::StandardError; end + +# Raised when ActiveStorage::Blob#download is called on a blob where the +# backing file is no longer present in its service. +# +# source://activestorage//lib/active_storage/errors.rb#25 +class ActiveStorage::FileNotFoundError < ::ActiveStorage::Error; end + +module ActiveStorage::FileServer + private + + def serve_file(path, content_type:, disposition:); end +end + +class ActiveStorage::Filename + include ::Comparable + + def initialize(filename); end + + def <=>(other); end + def as_json(*_arg0); end + def base; end + def extension; end + def extension_with_delimiter; end + def extension_without_delimiter; end + def sanitized; end + def to_s; end + + class << self + def wrap(filename); end + end +end + +# = Active Storage \FixtureSet +# +# Fixtures are a way of organizing data that you want to test against; in +# short, sample data. +# +# To learn more about fixtures, read the ActiveRecord::FixtureSet documentation. +# +# === YAML +# +# Like other Active Record-backed models, ActiveStorage::Attachment and +# ActiveStorage::Blob records inherit from ActiveRecord::Base instances and +# therefore can be populated by fixtures. +# +# Consider a hypothetical Article model class, its related +# fixture data, as well as fixture data for related ActiveStorage::Attachment +# and ActiveStorage::Blob records: +# +# # app/models/article.rb +# class Article < ApplicationRecord +# has_one_attached :thumbnail +# end +# +# +# +# # fixtures/active_storage/blobs.yml +# first_thumbnail_blob: <%= ActiveStorage::FixtureSet.blob filename: "first.png" %> +# +# +# +# # fixtures/active_storage/attachments.yml +# first_thumbnail_attachment: +# name: thumbnail +# record: first (Article) +# blob: first_thumbnail_blob +# +# When processed, Active Record will insert database records for each fixture +# entry and will ensure the Active Storage relationship is intact. +# +# source://activestorage//lib/active_storage/fixture_set.rb#44 +class ActiveStorage::FixtureSet + include ::ActiveSupport::Testing::FileFixtures + include ::ActiveRecord::SecureToken + extend ::ActiveRecord::SecureToken::ClassMethods + + # source://activesupport/7.2.0/lib/active_support/testing/file_fixtures.rb#20 + def file_fixture_path; end + + # source://activesupport/7.2.0/lib/active_support/testing/file_fixtures.rb#20 + def file_fixture_path?; end + + # source://activestorage//lib/active_storage/fixture_set.rb#70 + def prepare(instance, **attributes); end + + class << self + # Generate a YAML-encoded representation of an ActiveStorage::Blob + # instance's attributes, resolve the file relative to the directory mentioned + # by ActiveSupport::Testing::FileFixtures.file_fixture, and upload + # the file to the Service + # + # === Examples + # + # # tests/fixtures/active_storage/blobs.yml + # second_thumbnail_blob: <%= ActiveStorage::FixtureSet.blob( + # filename: "second.svg", + # ) %> + # + # third_thumbnail_blob: <%= ActiveStorage::FixtureSet.blob( + # filename: "third.svg", + # content_type: "image/svg+xml", + # service_name: "public" + # ) %> + # + # source://activestorage//lib/active_storage/fixture_set.rb#66 + def blob(filename:, **attributes); end + + # source://activesupport/7.2.0/lib/active_support/testing/file_fixtures.rb#20 + def file_fixture_path; end + + # source://activesupport/7.2.0/lib/active_support/testing/file_fixtures.rb#20 + def file_fixture_path=(value); end + + # source://activesupport/7.2.0/lib/active_support/testing/file_fixtures.rb#20 + def file_fixture_path?; end + end +end + +# Raised when uploaded or downloaded data does not match a precomputed checksum. +# Indicates that a network error or a software bug caused data corruption. +# +# source://activestorage//lib/active_storage/errors.rb#21 +class ActiveStorage::IntegrityError < ::ActiveStorage::Error; end + +# Raised when ActiveStorage::Blob#variant is called on a blob that isn't variable. +# Use ActiveStorage::Blob#variable? to determine whether a blob is variable. +# +# source://activestorage//lib/active_storage/errors.rb#9 +class ActiveStorage::InvariableError < ::ActiveStorage::Error; end + +# source://activestorage//lib/active_storage/log_subscriber.rb#6 +class ActiveStorage::LogSubscriber < ::ActiveSupport::LogSubscriber + # source://activestorage//lib/active_storage/log_subscriber.rb#53 + def logger; end + + # source://activestorage//lib/active_storage/log_subscriber.rb#21 + def preview(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#26 + def service_delete(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#31 + def service_delete_prefixed(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#14 + def service_download(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#36 + def service_exist(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#46 + def service_mirror(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#14 + def service_streaming_download(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#7 + def service_upload(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#41 + def service_url(event); end + + private + + # source://activestorage//lib/active_storage/log_subscriber.rb#62 + def debug(event, colored_message); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#58 + def info(event, colored_message); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#70 + def key_in(event); end + + # source://activestorage//lib/active_storage/log_subscriber.rb#66 + def log_prefix_for_service(event); end + + class << self + # source://activesupport/7.2.0/lib/active_support/log_subscriber.rb#84 + def log_levels; end + end +end + +class ActiveStorage::MirrorJob < ::ActiveStorage::BaseJob + def perform(key, checksum:); end + + class << self + # source://activejob/7.2.0/lib/active_job/queue_name.rb#55 + def queue_name; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +class ActiveStorage::NamedVariant + def initialize(transformations); end + + def preprocessed; end + def preprocessed?(record); end + def transformations; end +end + +class ActiveStorage::Preview + include ::ActiveStorage::Blob::Servable + + def initialize(blob, variation_or_variation_key); end + + def blob; end + def content_type(*_arg0, **_arg1, &_arg2); end + def download(&block); end + def filename(*_arg0, **_arg1, &_arg2); end + def image; end + def key; end + def processed; end + def url(**options); end + def variation; end + + private + + def presentation; end + def previewer; end + def previewer_class; end + def process; end + def processed?; end + def variant; end + def variant?; end +end + +class ActiveStorage::Preview::UnprocessedError < ::StandardError; end + +# Raised when a Previewer is unable to generate a preview image. +# +# source://activestorage//lib/active_storage/errors.rb#28 +class ActiveStorage::PreviewError < ::ActiveStorage::Error; end + +class ActiveStorage::PreviewImageJob < ::ActiveStorage::BaseJob + def perform(blob, variations); end + + class << self + # source://activejob/7.2.0/lib/active_job/queue_name.rb#55 + def queue_name; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +# = Active Storage \Previewer +# +# This is an abstract base class for previewers, which generate images from blobs. See +# ActiveStorage::Previewer::MuPDFPreviewer and ActiveStorage::Previewer::VideoPreviewer for +# examples of concrete subclasses. +# +# source://activestorage//lib/active_storage/previewer.rb#9 +class ActiveStorage::Previewer + # @return [Previewer] a new instance of Previewer + # + # source://activestorage//lib/active_storage/previewer.rb#18 + def initialize(blob); end + + # Returns the value of attribute blob. + # + # source://activestorage//lib/active_storage/previewer.rb#10 + def blob; end + + # Override this method in a concrete subclass. Have it yield an attachable preview image (i.e. + # anything accepted by ActiveStorage::Attached::One#attach). Pass the additional options to + # the underlying blob that is created. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/previewer.rb#25 + def preview(**options); end + + private + + # source://activestorage//lib/active_storage/previewer.rb#78 + def capture(*argv, to:); end + + # Downloads the blob to a tempfile on disk. Yields the tempfile. + # + # source://activestorage//lib/active_storage/previewer.rb#31 + def download_blob_to_tempfile(&block); end + + # Executes a system command, capturing its binary output in a tempfile. Yields the tempfile. + # + # Use this method to shell out to a system library (e.g. muPDF or FFmpeg) for preview image + # generation. The resulting tempfile can be used as the +:io+ value in an attachable Hash: + # + # def preview + # download_blob_to_tempfile do |input| + # draw "my-drawing-command", input.path, "--format", "png", "-" do |output| + # yield io: output, filename: "#{blob.filename.base}.png", content_type: "image/png" + # end + # end + # end + # + # The output tempfile is opened in the directory returned by #tmpdir. + # + # source://activestorage//lib/active_storage/previewer.rb#49 + def draw(*argv); end + + # source://activestorage//lib/active_storage/previewer.rb#69 + def instrument(operation, payload = T.unsafe(nil), &block); end + + # source://activestorage//lib/active_storage/previewer.rb#93 + def logger; end + + # source://activestorage//lib/active_storage/previewer.rb#59 + def open_tempfile; end + + # source://activestorage//lib/active_storage/previewer.rb#73 + def service_name; end + + # source://activestorage//lib/active_storage/previewer.rb#97 + def tmpdir; end + + class << self + # Implement this method in a concrete subclass. Have it return true when given a blob from which + # the previewer can generate an image. + # + # @return [Boolean] + # + # source://activestorage//lib/active_storage/previewer.rb#14 + def accept?(blob); end + end +end + +# source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#4 +class ActiveStorage::Previewer::MuPDFPreviewer < ::ActiveStorage::Previewer + # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#27 + def preview(**options); end + + private + + # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#36 + def draw_first_page_from(file, &block); end + + class << self + # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#6 + def accept?(blob); end + + # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#18 + def mutool_exists?; end + + # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#14 + def mutool_path; end + + # source://activestorage//lib/active_storage/previewer/mupdf_previewer.rb#10 + def pdf?(content_type); end + end +end + +# source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#4 +class ActiveStorage::Previewer::PopplerPDFPreviewer < ::ActiveStorage::Previewer + # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#25 + def preview(**options); end + + private + + # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#34 + def draw_first_page_from(file, &block); end + + class << self + # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#6 + def accept?(blob); end + + # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#10 + def pdf?(content_type); end + + # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#18 + def pdftoppm_exists?; end + + # source://activestorage//lib/active_storage/previewer/poppler_pdf_previewer.rb#14 + def pdftoppm_path; end + end +end + +# source://activestorage//lib/active_storage/previewer/video_previewer.rb#6 +class ActiveStorage::Previewer::VideoPreviewer < ::ActiveStorage::Previewer + # source://activestorage//lib/active_storage/previewer/video_previewer.rb#23 + def preview(**options); end + + private + + # source://activestorage//lib/active_storage/previewer/video_previewer.rb#32 + def draw_relevant_frame_from(file, &block); end + + class << self + # source://activestorage//lib/active_storage/previewer/video_previewer.rb#8 + def accept?(blob); end + + # source://activestorage//lib/active_storage/previewer/video_previewer.rb#12 + def ffmpeg_exists?; end + + # source://activestorage//lib/active_storage/previewer/video_previewer.rb#18 + def ffmpeg_path; end + end +end + +class ActiveStorage::PurgeJob < ::ActiveStorage::BaseJob + def perform(blob); end + + class << self + # source://activejob/7.2.0/lib/active_job/queue_name.rb#55 + def queue_name; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +class ActiveStorage::Record < ::ActiveRecord::Base + include ::ActiveStorage::Record::GeneratedAttributeMethods + include ::ActiveStorage::Record::GeneratedAssociationMethods + + class << self + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + end +end + +module ActiveStorage::Record::GeneratedAssociationMethods; end +module ActiveStorage::Record::GeneratedAttributeMethods; end + +# source://activestorage//lib/active_storage/reflection.rb#4 +module ActiveStorage::Reflection; end + +# source://activestorage//lib/active_storage/reflection.rb#49 +module ActiveStorage::Reflection::ActiveRecordExtensions + extend ::ActiveSupport::Concern + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + mixes_in_class_methods ::ActiveStorage::Reflection::ActiveRecordExtensions::ClassMethods + + module GeneratedClassMethods + def attachment_reflections; end + def attachment_reflections=(value); end + def attachment_reflections?; end + end + + module GeneratedInstanceMethods + def attachment_reflections; end + def attachment_reflections?; end + end +end + +# source://activestorage//lib/active_storage/reflection.rb#56 +module ActiveStorage::Reflection::ActiveRecordExtensions::ClassMethods + # Returns an array of reflection objects for all the attachments in the + # class. + # + # source://activestorage//lib/active_storage/reflection.rb#59 + def reflect_on_all_attachments; end + + # Returns the reflection object for the named +attachment+. + # + # User.reflect_on_attachment(:avatar) + # # => the avatar reflection + # + # source://activestorage//lib/active_storage/reflection.rb#68 + def reflect_on_attachment(attachment); end +end + +# source://activestorage//lib/active_storage/reflection.rb#5 +class ActiveStorage::Reflection::HasAttachedReflection < ::ActiveRecord::Reflection::MacroReflection + # source://activestorage//lib/active_storage/reflection.rb#10 + def named_variants; end + + # source://activestorage//lib/active_storage/reflection.rb#6 + def variant(name, transformations); end +end + +# Holds all the metadata about a has_many_attached attachment as it was +# specified in the Active Record class. +# +# source://activestorage//lib/active_storage/reflection.rb#25 +class ActiveStorage::Reflection::HasManyAttachedReflection < ::ActiveStorage::Reflection::HasAttachedReflection + # source://activestorage//lib/active_storage/reflection.rb#26 + def macro; end +end + +# Holds all the metadata about a has_one_attached attachment as it was +# specified in the Active Record class. +# +# source://activestorage//lib/active_storage/reflection.rb#17 +class ActiveStorage::Reflection::HasOneAttachedReflection < ::ActiveStorage::Reflection::HasAttachedReflection + # source://activestorage//lib/active_storage/reflection.rb#18 + def macro; end +end + +# source://activestorage//lib/active_storage/reflection.rb#31 +module ActiveStorage::Reflection::ReflectionExtension + # source://activestorage//lib/active_storage/reflection.rb#32 + def add_attachment_reflection(model, name, reflection); end + + private + + # source://activestorage//lib/active_storage/reflection.rb#37 + def reflection_class_for(macro); end +end + +module ActiveStorage::Representations; end + +class ActiveStorage::Representations::BaseController < ::ActiveStorage::BaseController + include ::ActiveStorage::SetBlob + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + def blob_scope; end + def set_representation; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +class ActiveStorage::Representations::ProxyController < ::ActiveStorage::Representations::BaseController + include ::ActionController::Live + include ::ActiveStorage::Streaming + include ::ActiveStorage::DisableSession + extend ::ActionController::Live::ClassMethods + + def show; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +class ActiveStorage::Representations::RedirectController < ::ActiveStorage::Representations::BaseController + def show; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + class << self + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +# = Active Storage \Service +# +# Abstract class serving as an interface for concrete services. +# +# The available services are: +# +# * +Disk+, to manage attachments saved directly on the hard drive. +# * +GCS+, to manage attachments through Google Cloud Storage. +# * +S3+, to manage attachments through Amazon S3. +# * +AzureStorage+, to manage attachments through Microsoft Azure Storage. +# * +Mirror+, to be able to use several services to manage attachments. +# +# Inside a \Rails application, you can set-up your services through the +# generated config/storage.yml file and reference one +# of the aforementioned constant under the +service+ key. For example: +# +# local: +# service: Disk +# root: <%= Rails.root.join("storage") %> +# +# You can checkout the service's constructor to know which keys are required. +# +# Then, in your application's configuration, you can specify the service to +# use like this: +# +# config.active_storage.service = :local +# +# If you are using Active Storage outside of a Ruby on \Rails application, you +# can configure the service to use like this: +# +# ActiveStorage::Blob.service = ActiveStorage::Service.configure( +# :local, +# { local: {service: "Disk", root: Pathname("/tmp/foo/storage") } } +# ) +# +# source://activestorage//lib/active_storage/service.rb#43 +class ActiveStorage::Service + extend ::ActiveSupport::Autoload + + # Concatenate multiple files into a single "composed" file. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#96 + def compose(source_keys, destination_key, filename: T.unsafe(nil), content_type: T.unsafe(nil), disposition: T.unsafe(nil), custom_metadata: T.unsafe(nil)); end + + # Delete the file at the +key+. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#101 + def delete(key); end + + # Delete files at keys starting with the +prefix+. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#106 + def delete_prefixed(prefix); end + + # Return the content of the file at the +key+. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#82 + def download(key); end + + # Return the partial content in the byte +range+ of the file at the +key+. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#87 + def download_chunk(key, range); end + + # Return +true+ if a file exists at the +key+. + # + # @raise [NotImplementedError] + # @return [Boolean] + # + # source://activestorage//lib/active_storage/service.rb#111 + def exist?(key); end + + # Returns a Hash of headers for +url_for_direct_upload+ requests. + # + # source://activestorage//lib/active_storage/service.rb#143 + def headers_for_direct_upload(key, filename:, content_type:, content_length:, checksum:, custom_metadata: T.unsafe(nil)); end + + # Returns the value of attribute name. + # + # source://activestorage//lib/active_storage/service.rb#46 + def name; end + + # Sets the attribute name + # + # @param value the value to set the attribute name to. + # + # source://activestorage//lib/active_storage/service.rb#46 + def name=(_arg0); end + + # source://activestorage//lib/active_storage/service.rb#91 + def open(*args, **options, &block); end + + # @return [Boolean] + # + # source://activestorage//lib/active_storage/service.rb#147 + def public?; end + + # Update metadata for the file identified by +key+ in the service. + # Override in subclasses only if the service needs to store specific + # metadata that has to be updated upon identification. + # + # source://activestorage//lib/active_storage/service.rb#78 + def update_metadata(key, **metadata); end + + # Upload the +io+ to the +key+ specified. If a +checksum+ is provided, the service will + # ensure a match when the upload has completed or raise an ActiveStorage::IntegrityError. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#71 + def upload(key, io, checksum: T.unsafe(nil), **options); end + + # Returns the URL for the file at the +key+. This returns a permanent URL for public files, and returns a + # short-lived URL for private files. For private files you can provide the +disposition+ (+:inline+ or +:attachment+), + # +filename+, and +content_type+ that you wish the file to be served with on request. Additionally, you can also provide + # the amount of seconds the URL will be valid for, specified in +expires_in+. + # + # source://activestorage//lib/active_storage/service.rb#119 + def url(key, **options); end + + # Returns a signed, temporary URL that a direct upload file can be PUT to on the +key+. + # The URL will be valid for the amount of seconds specified in +expires_in+. + # You must also provide the +content_type+, +content_length+, and +checksum+ of the file + # that will be uploaded. All these attributes will be validated by the service upon upload. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#138 + def url_for_direct_upload(key, expires_in:, content_type:, content_length:, checksum:, custom_metadata: T.unsafe(nil)); end + + private + + # source://activestorage//lib/active_storage/service.rb#175 + def content_disposition_with(filename:, type: T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#160 + def custom_metadata_headers(metadata); end + + # source://activestorage//lib/active_storage/service.rb#164 + def instrument(operation, payload = T.unsafe(nil), &block); end + + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#152 + def private_url(key, expires_in:, filename:, disposition:, content_type:, **_arg5); end + + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/service.rb#156 + def public_url(key, **_arg1); end + + # source://activestorage//lib/active_storage/service.rb#170 + def service_name; end + + class << self + # Override in subclasses that stitch together multiple services and hence + # need to build additional services using the configurator. + # + # Passes the configurator and all of the service's config as keyword args. + # + # See MirrorService for an example. + # + # source://activestorage//lib/active_storage/service.rb#62 + def build(configurator:, name:, service: T.unsafe(nil), **service_config); end + + # Configure an Active Storage service by name from a set of configurations, + # typically loaded from a YAML file. The Active Storage engine uses this + # to set the global Active Storage service when the app boots. + # + # source://activestorage//lib/active_storage/service.rb#52 + def configure(service_name, configurations); end + end +end + +# source://activestorage//lib/active_storage/service/configurator.rb#4 +class ActiveStorage::Service::Configurator + # source://activestorage//lib/active_storage/service/configurator.rb#11 + def initialize(configurations); end + + # source://activestorage//lib/active_storage/service/configurator.rb#15 + def build(service_name); end + + # source://activestorage//lib/active_storage/service/configurator.rb#5 + def configurations; end + + private + + # source://activestorage//lib/active_storage/service/configurator.rb#23 + def config_for(name); end + + # source://activestorage//lib/active_storage/service/configurator.rb#29 + def resolve(class_name); end + + class << self + # source://activestorage//lib/active_storage/service/configurator.rb#7 + def build(service_name, configurations); end + end +end + +# source://activestorage//lib/active_storage/service/disk_service.rb#13 +class ActiveStorage::Service::DiskService < ::ActiveStorage::Service + # source://activestorage//lib/active_storage/service/disk_service.rb#16 + def initialize(root:, public: T.unsafe(nil), **options); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#105 + def compose(source_keys, destination_key, **_arg2); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#53 + def delete(key); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#61 + def delete_prefixed(prefix); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#28 + def download(key, &block); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#42 + def download_chunk(key, range); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#69 + def exist?(key); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#97 + def headers_for_direct_upload(key, content_type:, **_arg2); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#101 + def path_for(key); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#14 + def root; end + + # source://activestorage//lib/active_storage/service/disk_service.rb#14 + def root=(_arg0); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#21 + def upload(key, io, checksum: T.unsafe(nil), **_arg3); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#77 + def url_for_direct_upload(key, expires_in:, content_type:, content_length:, checksum:, custom_metadata: T.unsafe(nil)); end + + private + + # source://activestorage//lib/active_storage/service/disk_service.rb#163 + def ensure_integrity_of(key, checksum); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#155 + def folder_for(key); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#124 + def generate_url(key, expires_in:, filename:, content_type:, disposition:); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#159 + def make_path_for(key); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#116 + def private_url(key, expires_in:, filename:, content_type:, disposition:, **_arg5); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#120 + def public_url(key, filename:, content_type: T.unsafe(nil), disposition: T.unsafe(nil), **_arg4); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#145 + def stream(key); end + + # source://activestorage//lib/active_storage/service/disk_service.rb#170 + def url_helpers; end + + # source://activestorage//lib/active_storage/service/disk_service.rb#174 + def url_options; end +end + +# source://activestorage//lib/active_storage/service/registry.rb#4 +class ActiveStorage::Service::Registry + # source://activestorage//lib/active_storage/service/registry.rb#5 + def initialize(configurations); end + + # source://activestorage//lib/active_storage/service/registry.rb#10 + def fetch(name); end + + private + + # source://activestorage//lib/active_storage/service/registry.rb#26 + def configurations; end + + # source://activestorage//lib/active_storage/service/registry.rb#28 + def configurator; end + + # source://activestorage//lib/active_storage/service/registry.rb#26 + def services; end +end + +module ActiveStorage::SetBlob + extend ::ActiveSupport::Concern + + private + + def blob_scope; end + def set_blob; end +end + +module ActiveStorage::SetCurrent + extend ::ActiveSupport::Concern +end + +module ActiveStorage::Streaming + extend ::ActiveSupport::Concern + include ::ActionController::Rendering + include ::ActionController::DataStreaming + include ::ActionController::Live + + mixes_in_class_methods ::ActionController::Rendering::ClassMethods + mixes_in_class_methods ::ActionController::Live::ClassMethods + + private + + def send_blob_byte_range_data(blob, range_header, disposition: T.unsafe(nil)); end + def send_blob_stream(blob, disposition: T.unsafe(nil)); end +end + +ActiveStorage::Streaming::DEFAULT_BLOB_STREAMING_DISPOSITION = T.let(T.unsafe(nil), String) + +class ActiveStorage::TransformJob < ::ActiveStorage::BaseJob + def perform(blob, transformations); end + + class << self + # source://activejob/7.2.0/lib/active_job/queue_name.rb#55 + def queue_name; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +# source://activestorage//lib/active_storage.rb#368 +module ActiveStorage::Transformers + extend ::ActiveSupport::Autoload +end + +# source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#14 +class ActiveStorage::Transformers::ImageProcessingTransformer < ::ActiveStorage::Transformers::Transformer + private + + # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#32 + def operations; end + + # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#19 + def process(file, format:); end + + # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#28 + def processor; end + + # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#79 + def validate_arg_array(argument); end + + # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#93 + def validate_arg_hash(argument); end + + # @raise [UnsupportedImageProcessingArgument] + # + # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#71 + def validate_arg_string(argument); end + + # source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#51 + def validate_transformation(name, argument); end +end + +# source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#17 +class ActiveStorage::Transformers::ImageProcessingTransformer::UnsupportedImageProcessingArgument < ::StandardError; end + +# source://activestorage//lib/active_storage/transformers/image_processing_transformer.rb#16 +class ActiveStorage::Transformers::ImageProcessingTransformer::UnsupportedImageProcessingMethod < ::StandardError; end + +# = Active Storage \Transformers \Transformer +# +# A Transformer applies a set of transformations to an image. +# +# The following concrete subclasses are included in Active Storage: +# +# * ActiveStorage::Transformers::ImageProcessingTransformer: +# backed by ImageProcessing, a common interface for MiniMagick and ruby-vips +# +# source://activestorage//lib/active_storage/transformers/transformer.rb#13 +class ActiveStorage::Transformers::Transformer + # @return [Transformer] a new instance of Transformer + # + # source://activestorage//lib/active_storage/transformers/transformer.rb#16 + def initialize(transformations); end + + # Applies the transformations to the source image in +file+, producing a target image in the + # specified +format+. Yields an open Tempfile containing the target image. Closes and unlinks + # the output tempfile after yielding to the given block. Returns the result of the block. + # + # source://activestorage//lib/active_storage/transformers/transformer.rb#23 + def transform(file, format:); end + + # Returns the value of attribute transformations. + # + # source://activestorage//lib/active_storage/transformers/transformer.rb#14 + def transformations; end + + private + + # Returns an open Tempfile containing a transformed image in the given +format+. + # All subclasses implement this method. + # + # @raise [NotImplementedError] + # + # source://activestorage//lib/active_storage/transformers/transformer.rb#36 + def process(file, format:); end +end + +# Raised when ActiveStorage::Blob#preview is called on a blob that isn't previewable. +# Use ActiveStorage::Blob#previewable? to determine whether a blob is previewable. +# +# source://activestorage//lib/active_storage/errors.rb#13 +class ActiveStorage::UnpreviewableError < ::ActiveStorage::Error; end + +# Raised when ActiveStorage::Blob#representation is called on a blob that isn't representable. +# Use ActiveStorage::Blob#representable? to determine whether a blob is representable. +# +# source://activestorage//lib/active_storage/errors.rb#17 +class ActiveStorage::UnrepresentableError < ::ActiveStorage::Error; end + +# source://activestorage//lib/active_storage/gem_version.rb#9 +module ActiveStorage::VERSION; end + +# source://activestorage//lib/active_storage/gem_version.rb#10 +ActiveStorage::VERSION::MAJOR = T.let(T.unsafe(nil), Integer) + +# source://activestorage//lib/active_storage/gem_version.rb#11 +ActiveStorage::VERSION::MINOR = T.let(T.unsafe(nil), Integer) + +# source://activestorage//lib/active_storage/gem_version.rb#13 +ActiveStorage::VERSION::PRE = T.let(T.unsafe(nil), T.untyped) + +# source://activestorage//lib/active_storage/gem_version.rb#15 +ActiveStorage::VERSION::STRING = T.let(T.unsafe(nil), String) + +# source://activestorage//lib/active_storage/gem_version.rb#12 +ActiveStorage::VERSION::TINY = T.let(T.unsafe(nil), Integer) + +class ActiveStorage::Variant + include ::ActiveStorage::Blob::Servable + + def initialize(blob, variation_or_variation_key); end + + def blob; end + def content_type(*_arg0, **_arg1, &_arg2); end + def destroy; end + def download(&block); end + def filename; end + def image; end + def key; end + def processed; end + def service(*_arg0, **_arg1, &_arg2); end + def url(expires_in: T.unsafe(nil), disposition: T.unsafe(nil)); end + def variation; end + + private + + def process; end + def processed?; end +end + +class ActiveStorage::VariantRecord < ::ActiveStorage::Record + include ::ActiveStorage::VariantRecord::GeneratedAttributeMethods + include ::ActiveStorage::VariantRecord::GeneratedAssociationMethods + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_blob(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_image_attachment(*args); end + + # source://activerecord/7.2.0/lib/active_record/autosave_association.rb#162 + def autosave_associated_records_for_image_blob(*args); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activerecord/7.2.0/lib/active_record/reflection.rb#11 + def _reflections; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#71 + def _validators; end + + # source://activestorage//lib/active_storage/reflection.rb#53 + def attachment_reflections; end + + # source://activerecord/7.2.0/lib/active_record/enum.rb#167 + def defined_enums; end + + # source://activerecord/7.2.0/lib/active_record/scoping/named.rb#174 + def with_attached_image(*args, **_arg1); end + end +end + +module ActiveStorage::VariantRecord::GeneratedAssociationMethods + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def blob=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#146 + def blob_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/belongs_to.rb#150 + def blob_previously_changed?; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#32 + def build_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#32 + def build_image_attachment(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#32 + def build_image_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#36 + def create_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#40 + def create_blob!(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#36 + def create_image_attachment(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#40 + def create_image_attachment!(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#36 + def create_image_blob(*args, &block); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#40 + def create_image_blob!(*args, &block); end + + # source://activestorage//lib/active_storage/attached/model.rb#111 + def image; end + + # source://activestorage//lib/active_storage/attached/model.rb#116 + def image=(attachable); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def image_attachment; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def image_attachment=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#103 + def image_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/association.rb#111 + def image_blob=(value); end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_image_attachment; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#19 + def reload_image_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_blob; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_image_attachment; end + + # source://activerecord/7.2.0/lib/active_record/associations/builder/singular_association.rb#23 + def reset_image_blob; end +end + +module ActiveStorage::VariantRecord::GeneratedAttributeMethods; end + +class ActiveStorage::VariantWithRecord + include ::ActiveStorage::Blob::Servable + + def initialize(blob, variation); end + + def blob; end + def content_type(*_arg0, **_arg1, &_arg2); end + def destroy; end + def download(*_arg0, **_arg1, &_arg2); end + def filename; end + def image; end + def key(*_arg0, **_arg1, &_arg2); end + def processed; end + def service(*_arg0, **_arg1, &_arg2); end + def url(*_arg0, **_arg1, &_arg2); end + def variation; end + + private + + def create_or_find_record(image:); end + def process; end + def processed?; end + def record; end + def transform_blob; end +end + +class ActiveStorage::Variation + def initialize(transformations); end + + def content_type; end + def default_to(defaults); end + def digest; end + def format; end + def key; end + def transform(file, &block); end + def transformations; end + + private + + def transformer; end + + class << self + def decode(key); end + def encode(transformations); end + def wrap(variator); end + end +end diff --git a/sorbet/rbi/gems/activesupport@7.0.5.rbi b/sorbet/rbi/gems/activesupport@7.2.0.rbi similarity index 76% rename from sorbet/rbi/gems/activesupport@7.0.5.rbi rename to sorbet/rbi/gems/activesupport@7.2.0.rbi index accac2c7e..843f13036 100644 --- a/sorbet/rbi/gems/activesupport@7.0.5.rbi +++ b/sorbet/rbi/gems/activesupport@7.2.0.rbi @@ -4,19 +4,10 @@ # This is an autogenerated file for types exported from the `activesupport` gem. # Please instead update this file by running `bin/tapioca gem activesupport`. -# source://american_date/1.2.0/lib/american_date.rb#16 -::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) -# source://ruby-openid/2.9.2/lib/openid/fetchers.rb#13 -::MAX_RESPONSE_KB = T.let(T.unsafe(nil), Integer) - -# source://yard/0.9.34/lib/yard.rb#61 -::RUBY18 = T.let(T.unsafe(nil), FalseClass) - -# source://yard/0.9.34/lib/yard.rb#62 -::RUBY19 = T.let(T.unsafe(nil), TrueClass) - -# source://activesupport//lib/active_support/lazy_load_hooks.rb#3 +# :include: ../README.rdoc +# +# source://activesupport//lib/active_support/deep_mergeable.rb#3 module ActiveSupport extend ::ActiveSupport::LazyLoadHooks extend ::ActiveSupport::Autoload @@ -27,32 +18,35 @@ module ActiveSupport # source://activesupport//lib/active_support/json/decoding.rb#9 def parse_json_times=(val); end - # source://activesupport//lib/active_support.rb#94 + # source://activesupport//lib/active_support.rb#99 def test_order; end - # source://activesupport//lib/active_support.rb#94 + # source://activesupport//lib/active_support.rb#99 def test_order=(val); end - # source://activesupport//lib/active_support.rb#95 + # source://activesupport//lib/active_support.rb#100 def test_parallelization_threshold; end - # source://activesupport//lib/active_support.rb#95 + # source://activesupport//lib/active_support.rb#100 def test_parallelization_threshold=(val); end class << self - # source://activesupport//lib/active_support.rb#99 + # source://activesupport//lib/active_support.rb#105 def cache_format_version; end - # source://activesupport//lib/active_support.rb#103 + # source://activesupport//lib/active_support.rb#109 def cache_format_version=(value); end - # source://activesupport//lib/active_support.rb#88 + # source://activesupport//lib/active_support/deprecator.rb#4 + def deprecator; end + + # source://activesupport//lib/active_support.rb#93 def eager_load!; end - # source://activesupport//lib/active_support.rb#97 + # source://activesupport//lib/active_support.rb#103 def error_reporter; end - # source://activesupport//lib/active_support.rb#97 + # source://activesupport//lib/active_support.rb#103 def error_reporter=(_arg0); end # source://activesupport//lib/active_support/json/encoding.rb#8 @@ -61,7 +55,7 @@ module ActiveSupport # source://activesupport//lib/active_support/json/encoding.rb#8 def escape_html_entities_in_json=(arg); end - # Returns the currently loaded version of Active Support as a Gem::Version. + # Returns the currently loaded version of Active Support as a +Gem::Version+. # # source://activesupport//lib/active_support/gem_version.rb#5 def gem_version; end @@ -78,16 +72,16 @@ module ActiveSupport # source://activesupport//lib/active_support/json/decoding.rb#9 def parse_json_times=(val); end - # source://activesupport//lib/active_support.rb#94 + # source://activesupport//lib/active_support.rb#99 def test_order; end - # source://activesupport//lib/active_support.rb#94 + # source://activesupport//lib/active_support.rb#99 def test_order=(val); end - # source://activesupport//lib/active_support.rb#95 + # source://activesupport//lib/active_support.rb#100 def test_parallelization_threshold; end - # source://activesupport//lib/active_support.rb#95 + # source://activesupport//lib/active_support.rb#100 def test_parallelization_threshold=(val); end # source://activesupport//lib/active_support/json/encoding.rb#8 @@ -96,10 +90,10 @@ module ActiveSupport # source://activesupport//lib/active_support/json/encoding.rb#8 def time_precision=(arg); end - # source://activesupport//lib/active_support.rb#107 + # source://activesupport//lib/active_support.rb#113 def to_time_preserves_timezone; end - # source://activesupport//lib/active_support.rb#111 + # source://activesupport//lib/active_support.rb#117 def to_time_preserves_timezone=(value); end # source://activesupport//lib/active_support/json/encoding.rb#8 @@ -108,26 +102,28 @@ module ActiveSupport # source://activesupport//lib/active_support/json/encoding.rb#8 def use_standard_json_time_format=(arg); end - # source://activesupport//lib/active_support.rb#115 + # source://activesupport//lib/active_support.rb#127 def utc_to_local_returns_utc_offset_times; end - # source://activesupport//lib/active_support.rb#119 + # source://activesupport//lib/active_support.rb#131 def utc_to_local_returns_utc_offset_times=(value); end - # Returns the currently loaded version of Active Support as a Gem::Version. + # Returns the currently loaded version of Active Support as a +Gem::Version+. # # source://activesupport//lib/active_support/version.rb#7 def version; end end end +# = Actionable Errors +# # Actionable errors lets you define actions to resolve an error. # -# To make an error actionable, include the ActiveSupport::ActionableError +# To make an error actionable, include the +ActiveSupport::ActionableError+ # module and invoke the +action+ class macro to define the action. An action # needs a name and a block to execute. # -# source://activesupport//lib/active_support/actionable_error.rb#9 +# source://activesupport//lib/active_support/actionable_error.rb#11 module ActiveSupport::ActionableError extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -136,10 +132,10 @@ module ActiveSupport::ActionableError mixes_in_class_methods ::ActiveSupport::ActionableError::ClassMethods class << self - # source://activesupport//lib/active_support/actionable_error.rb#18 + # source://activesupport//lib/active_support/actionable_error.rb#20 def actions(error); end - # source://activesupport//lib/active_support/actionable_error.rb#27 + # source://activesupport//lib/active_support/actionable_error.rb#29 def dispatch(error, name); end end @@ -156,7 +152,7 @@ module ActiveSupport::ActionableError end end -# source://activesupport//lib/active_support/actionable_error.rb#33 +# source://activesupport//lib/active_support/actionable_error.rb#35 module ActiveSupport::ActionableError::ClassMethods # Defines an action that can resolve the error. # @@ -168,13 +164,15 @@ module ActiveSupport::ActionableError::ClassMethods # end # end # - # source://activesupport//lib/active_support/actionable_error.rb#43 + # source://activesupport//lib/active_support/actionable_error.rb#45 def action(name, &block); end end -# source://activesupport//lib/active_support/actionable_error.rb#12 +# source://activesupport//lib/active_support/actionable_error.rb#14 class ActiveSupport::ActionableError::NonActionable < ::StandardError; end +# = \Array Inquirer +# # Wrapping an array in an +ArrayInquirer+ gives a friendlier way to check # its string-like contents: # @@ -184,7 +182,7 @@ class ActiveSupport::ActionableError::NonActionable < ::StandardError; end # variants.tablet? # => true # variants.desktop? # => false # -# source://activesupport//lib/active_support/array_inquirer.rb#12 +# source://activesupport//lib/active_support/array_inquirer.rb#14 class ActiveSupport::ArrayInquirer < ::Array # Passes each element of +candidates+ collection to ArrayInquirer collection. # The method returns true if any element from the ArrayInquirer collection @@ -201,24 +199,26 @@ class ActiveSupport::ArrayInquirer < ::Array # # @return [Boolean] # - # source://activesupport//lib/active_support/array_inquirer.rb#25 + # source://activesupport//lib/active_support/array_inquirer.rb#27 def any?(*candidates); end private - # source://activesupport//lib/active_support/array_inquirer.rb#40 - def method_missing(name, *args); end + # source://activesupport//lib/active_support/array_inquirer.rb#42 + def method_missing(name, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://activesupport//lib/active_support/array_inquirer.rb#36 + # source://activesupport//lib/active_support/array_inquirer.rb#38 def respond_to_missing?(name, include_private = T.unsafe(nil)); end end +# = Active Support \Autoload +# # Autoload and eager load conveniences for your library. # # This module allows you to define autoloads based on -# Rails conventions (i.e. no need to define the path +# \Rails conventions (i.e. no need to define the path # it is automatically guessed based on the filename) # and also define a set of constants that needs to be # eager loaded: @@ -237,32 +237,26 @@ end # # MyLib.eager_load! # -# source://activesupport//lib/active_support/dependencies/autoload.rb#27 +# source://activesupport//lib/active_support/dependencies/autoload.rb#29 module ActiveSupport::Autoload - # source://activesupport//lib/active_support/dependencies/autoload.rb#37 + # source://activesupport//lib/active_support/dependencies/autoload.rb#30 def autoload(const_name, path = T.unsafe(nil)); end - # source://activesupport//lib/active_support/dependencies/autoload.rb#57 + # source://activesupport//lib/active_support/dependencies/autoload.rb#51 def autoload_at(path); end - # source://activesupport//lib/active_support/dependencies/autoload.rb#50 + # source://activesupport//lib/active_support/dependencies/autoload.rb#44 def autoload_under(path); end - # source://activesupport//lib/active_support/dependencies/autoload.rb#75 - def autoloads; end - - # source://activesupport//lib/active_support/dependencies/autoload.rb#64 + # source://activesupport//lib/active_support/dependencies/autoload.rb#58 def eager_autoload; end - # source://activesupport//lib/active_support/dependencies/autoload.rb#71 + # source://activesupport//lib/active_support/dependencies/autoload.rb#65 def eager_load!; end - - class << self - # source://activesupport//lib/active_support/dependencies/autoload.rb#28 - def extended(base); end - end end +# = Backtrace Cleaner +# # Backtraces often include many lines that are not relevant for the context # under review. This makes it hard to find the signal amongst the backtrace # noise, and adds debugging time. With a BacktraceCleaner, filters and @@ -277,11 +271,12 @@ end # can focus on the rest. # # bc = ActiveSupport::BacktraceCleaner.new -# bc.add_filter { |line| line.gsub(Rails.root.to_s, '') } # strip the Rails.root prefix +# root = "#{Rails.root}/" +# bc.add_filter { |line| line.start_with?(root) ? line.from(root.size) : line } # strip the Rails.root prefix # bc.add_silencer { |line| /puma|rubygems/.match?(line) } # skip any lines from puma or rubygems # bc.clean(exception.backtrace) # perform the cleanup # -# To reconfigure an existing BacktraceCleaner (like the default one in Rails) +# To reconfigure an existing BacktraceCleaner (like the default one in \Rails) # and show as much data as possible, you can always call # BacktraceCleaner#remove_silencers!, which will restore the # backtrace to a pristine state. If you need to reconfigure an existing @@ -291,20 +286,21 @@ end # # Inspired by the Quiet Backtrace gem by thoughtbot. # -# source://activesupport//lib/active_support/backtrace_cleaner.rb#31 +# source://activesupport//lib/active_support/backtrace_cleaner.rb#34 class ActiveSupport::BacktraceCleaner # @return [BacktraceCleaner] a new instance of BacktraceCleaner # - # source://activesupport//lib/active_support/backtrace_cleaner.rb#32 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#35 def initialize; end # Adds a filter from the block provided. Each line in the backtrace will be # mapped against this filter. # - # # Will turn "/my/rails/root/app/models/person.rb" into "/app/models/person.rb" - # backtrace_cleaner.add_filter { |line| line.gsub(Rails.root, '') } + # # Will turn "/my/rails/root/app/models/person.rb" into "app/models/person.rb" + # root = "#{Rails.root}/" + # backtrace_cleaner.add_filter { |line| line.start_with?(root) ? line.from(root.size) : line } # - # source://activesupport//lib/active_support/backtrace_cleaner.rb#60 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#83 def add_filter(&block); end # Adds a silencer from the block provided. If the silencer returns +true+ @@ -313,60 +309,74 @@ class ActiveSupport::BacktraceCleaner # # Will reject all lines that include the word "puma", like "/gems/puma/server.rb" or "/app/my_puma_server/rb" # backtrace_cleaner.add_silencer { |line| /puma/.match?(line) } # - # source://activesupport//lib/active_support/backtrace_cleaner.rb#69 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#92 def add_silencer(&block); end # Returns the backtrace after all filters and silencers have been run # against it. Filters run first, then silencers. # - # source://activesupport//lib/active_support/backtrace_cleaner.rb#41 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#45 def clean(backtrace, kind = T.unsafe(nil)); end + # Returns the frame with all filters applied. + # returns +nil+ if the frame was silenced. + # + # source://activesupport//lib/active_support/backtrace_cleaner.rb#61 + def clean_frame(frame, kind = T.unsafe(nil)); end + # Returns the backtrace after all filters and silencers have been run # against it. Filters run first, then silencers. # - # source://activesupport//lib/active_support/backtrace_cleaner.rb#41 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#45 def filter(backtrace, kind = T.unsafe(nil)); end # Removes all filters, but leaves in the silencers. Useful if you suddenly # need to see entire filepaths in the backtrace that you had already # filtered out. # - # source://activesupport//lib/active_support/backtrace_cleaner.rb#83 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#106 def remove_filters!; end # Removes all silencers, but leaves in the filters. Useful if your # context of debugging suddenly expands as you suspect a bug in one of # the libraries you use. # - # source://activesupport//lib/active_support/backtrace_cleaner.rb#76 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#99 def remove_silencers!; end private - # source://activesupport//lib/active_support/backtrace_cleaner.rb#90 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#127 + def add_core_silencer; end + + # source://activesupport//lib/active_support/backtrace_cleaner.rb#118 def add_gem_filter; end - # source://activesupport//lib/active_support/backtrace_cleaner.rb#99 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#131 def add_gem_silencer; end - # source://activesupport//lib/active_support/backtrace_cleaner.rb#103 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#135 def add_stdlib_silencer; end - # source://activesupport//lib/active_support/backtrace_cleaner.rb#107 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#139 def filter_backtrace(backtrace); end - # source://activesupport//lib/active_support/backtrace_cleaner.rb#123 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#113 + def initialize_copy(_other); end + + # source://activesupport//lib/active_support/backtrace_cleaner.rb#155 def noise(backtrace); end - # source://activesupport//lib/active_support/backtrace_cleaner.rb#115 + # source://activesupport//lib/active_support/backtrace_cleaner.rb#147 def silence(backtrace); end end -# source://activesupport//lib/active_support/backtrace_cleaner.rb#88 +# source://activesupport//lib/active_support/backtrace_cleaner.rb#111 ActiveSupport::BacktraceCleaner::FORMATTED_GEMS_PATTERN = T.let(T.unsafe(nil), Regexp) -# source://activesupport//lib/active_support/benchmarkable.rb#7 +# = \Benchmarkable +# +# source://activesupport//lib/active_support/benchmarkable.rb#8 module ActiveSupport::Benchmarkable # Allows you to measure the execution time of a block in a template and # records the result to the log. Wrap this block around expensive operations @@ -398,7 +408,7 @@ module ActiveSupport::Benchmarkable # <%= expensive_and_chatty_files_operation %> # <% end %> # - # source://activesupport//lib/active_support/benchmarkable.rb#37 + # source://activesupport//lib/active_support/benchmarkable.rb#38 def benchmark(message = T.unsafe(nil), options = T.unsafe(nil), &block); end end @@ -408,9 +418,272 @@ module ActiveSupport::BigDecimalWithDefaultFormat def to_s(format = T.unsafe(nil)); end end +# = Active Support Broadcast Logger +# +# The Broadcast logger is a logger used to write messages to multiple IO. It is commonly used +# in development to display messages on STDOUT and also write them to a file (development.log). +# With the Broadcast logger, you can broadcast your logs to a unlimited number of sinks. +# +# The BroadcastLogger acts as a standard logger and all methods you are used to are available. +# However, all the methods on this logger will propagate and be delegated to the other loggers +# that are part of the broadcast. +# +# Broadcasting your logs. +# +# stdout_logger = Logger.new(STDOUT) +# file_logger = Logger.new("development.log") +# broadcast = BroadcastLogger.new(stdout_logger, file_logger) +# +# broadcast.info("Hello world!") # Writes the log to STDOUT and the development.log file. +# +# Add a logger to the broadcast. +# +# stdout_logger = Logger.new(STDOUT) +# broadcast = BroadcastLogger.new(stdout_logger) +# file_logger = Logger.new("development.log") +# broadcast.broadcast_to(file_logger) +# +# broadcast.info("Hello world!") # Writes the log to STDOUT and the development.log file. +# +# Modifying the log level for all broadcasted loggers. +# +# stdout_logger = Logger.new(STDOUT) +# file_logger = Logger.new("development.log") +# broadcast = BroadcastLogger.new(stdout_logger, file_logger) +# +# broadcast.level = Logger::FATAL # Modify the log level for the whole broadcast. +# +# Stop broadcasting log to a sink. +# +# stdout_logger = Logger.new(STDOUT) +# file_logger = Logger.new("development.log") +# broadcast = BroadcastLogger.new(stdout_logger, file_logger) +# broadcast.info("Hello world!") # Writes the log to STDOUT and the development.log file. +# +# broadcast.stop_broadcasting_to(file_logger) +# broadcast.info("Hello world!") # Writes the log *only* to STDOUT. +# +# At least one sink has to be part of the broadcast. Otherwise, your logs will not +# be written anywhere. For instance: +# +# broadcast = BroadcastLogger.new +# broadcast.info("Hello world") # The log message will appear nowhere. +# +# If you are adding a custom logger with custom methods to the broadcast, +# the `BroadcastLogger` will proxy them and return the raw value, or an array +# of raw values, depending on how many loggers in the broadcasts responded to +# the method: +# +# class MyLogger < ::Logger +# def loggable? +# true +# end +# end +# +# logger = BroadcastLogger.new +# logger.loggable? # => A NoMethodError exception is raised because no loggers in the broadcasts could respond. +# +# logger.broadcast_to(MyLogger.new(STDOUT)) +# logger.loggable? # => true +# logger.broadcast_to(MyLogger.new(STDOUT)) +# puts logger.broadcasts # => [MyLogger, MyLogger] +# logger.loggable? # [true, true] +# +# source://activesupport//lib/active_support/broadcast_logger.rb#74 +class ActiveSupport::BroadcastLogger + include ::ActiveSupport::LoggerSilence + include ::ActiveSupport::LoggerThreadSafeLevel + + # @return [BroadcastLogger] a new instance of BroadcastLogger + # + # source://activesupport//lib/active_support/broadcast_logger.rb#82 + def initialize(*loggers); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#112 + def <<(message); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#116 + def add(*args, &block); end + + # Add logger(s) to the broadcast. + # + # broadcast_logger = ActiveSupport::BroadcastLogger.new + # broadcast_logger.broadcast_to(Logger.new(STDOUT), Logger.new(STDERR)) + # + # source://activesupport//lib/active_support/broadcast_logger.rb#93 + def broadcast_to(*loggers); end + + # Returns all the logger that are part of this broadcast. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#78 + def broadcasts; end + + # source://activesupport//lib/active_support/broadcast_logger.rb#162 + def close; end + + # source://activesupport//lib/active_support/broadcast_logger.rb#121 + def debug(*args, &block); end + + # Sets the log level to Logger::DEBUG for the whole broadcast. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#173 + def debug!; end + + # +True+ if the log level allows entries with severity Logger::DEBUG to be written + # to at least one broadcast. +False+ otherwise. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/broadcast_logger.rb#168 + def debug?; end + + # source://activesupport//lib/active_support/broadcast_logger.rb#133 + def error(*args, &block); end + + # Sets the log level to Logger::ERROR for the whole broadcast. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#206 + def error!; end + + # +True+ if the log level allows entries with severity Logger::ERROR to be written + # to at least one broadcast. +False+ otherwise. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/broadcast_logger.rb#201 + def error?; end + + # source://activesupport//lib/active_support/broadcast_logger.rb#137 + def fatal(*args, &block); end + + # Sets the log level to Logger::FATAL for the whole broadcast. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#217 + def fatal!; end + + # +True+ if the log level allows entries with severity Logger::FATAL to be written + # to at least one broadcast. +False+ otherwise. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/broadcast_logger.rb#212 + def fatal?; end + + # Returns the value of attribute formatter. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#79 + def formatter; end + + # source://activesupport//lib/active_support/broadcast_logger.rb#145 + def formatter=(formatter); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#125 + def info(*args, &block); end + + # Sets the log level to Logger::INFO for the whole broadcast. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#184 + def info!; end + + # +True+ if the log level allows entries with severity Logger::INFO to be written + # to at least one broadcast. +False+ otherwise. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/broadcast_logger.rb#179 + def info?; end + + # source://activesupport//lib/active_support/broadcast_logger.rb#108 + def level; end + + # source://activesupport//lib/active_support/broadcast_logger.rb#151 + def level=(level); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#156 + def local_level=(level); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#116 + def log(*args, &block); end + + # Returns the value of attribute progname. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#80 + def progname; end + + # Sets the attribute progname + # + # @param value the value to set the attribute progname to. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#80 + def progname=(_arg0); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#151 + def sev_threshold=(level); end + + # source://activesupport//lib/active_support/logger_silence.rb#12 + def silencer; end + + # source://activesupport//lib/active_support/logger_silence.rb#12 + def silencer=(val); end + + # Remove a logger from the broadcast. When a logger is removed, messages sent to + # the broadcast will no longer be written to its sink. + # + # sink = Logger.new(STDOUT) + # broadcast_logger = ActiveSupport::BroadcastLogger.new + # + # broadcast_logger.stop_broadcasting_to(sink) + # + # source://activesupport//lib/active_support/broadcast_logger.rb#104 + def stop_broadcasting_to(logger); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#141 + def unknown(*args, &block); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#129 + def warn(*args, &block); end + + # Sets the log level to Logger::WARN for the whole broadcast. + # + # source://activesupport//lib/active_support/broadcast_logger.rb#195 + def warn!; end + + # +True+ if the log level allows entries with severity Logger::WARN to be written + # to at least one broadcast. +False+ otherwise. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/broadcast_logger.rb#190 + def warn?; end + + private + + # source://activesupport//lib/active_support/broadcast_logger.rb#230 + def dispatch(&block); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#221 + def initialize_copy(other); end + + # source://activesupport//lib/active_support/broadcast_logger.rb#235 + def method_missing(name, *_arg1, **_arg2, &_arg3); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/broadcast_logger.rb#247 + def respond_to_missing?(method, include_all); end + + class << self + # source://activesupport//lib/active_support/logger_silence.rb#12 + def silencer; end + + # source://activesupport//lib/active_support/logger_silence.rb#12 + def silencer=(val); end + end +end + # See ActiveSupport::Cache::Store for documentation. # -# source://activesupport//lib/active_support/cache.rb#16 +# source://activesupport//lib/active_support/cache/entry.rb#6 module ActiveSupport::Cache class << self # Expands out the +key+ argument into a key that can be used for the @@ -426,19 +699,19 @@ module ActiveSupport::Cache # # The +key+ argument can also respond to +cache_key+ or +to_param+. # - # source://activesupport//lib/active_support/cache.rb#100 + # source://activesupport//lib/active_support/cache.rb#111 def expand_cache_key(key, namespace = T.unsafe(nil)); end # Returns the value of attribute format_version. # - # source://activesupport//lib/active_support/cache.rb#41 + # source://activesupport//lib/active_support/cache.rb#58 def format_version; end # Sets the attribute format_version # # @param value the value to set the attribute format_version to. # - # source://activesupport//lib/active_support/cache.rb#41 + # source://activesupport//lib/active_support/cache.rb#58 def format_version=(_arg0); end # Creates a new Store object according to the given options. @@ -467,87 +740,127 @@ module ActiveSupport::Cache # ActiveSupport::Cache.lookup_store(MyOwnCacheStore.new) # # => returns MyOwnCacheStore.new # - # source://activesupport//lib/active_support/cache.rb#68 + # source://activesupport//lib/active_support/cache.rb#85 def lookup_store(store = T.unsafe(nil), *parameters); end private - # source://activesupport//lib/active_support/cache.rb#112 + # source://activesupport//lib/active_support/cache.rb#123 def retrieve_cache_key(key); end # Obtains the specified cache store class, given the name of the +store+. # Raises an error when the store class cannot be found. # - # source://activesupport//lib/active_support/cache.rb#124 + # source://activesupport//lib/active_support/cache.rb#135 def retrieve_store_class(store); end end end -# source://activesupport//lib/active_support/cache.rb#833 -module ActiveSupport::Cache::Coders - class << self - # source://activesupport//lib/active_support/cache.rb#839 - def [](version); end - end -end +# source://activesupport//lib/active_support/cache/coder.rb#7 +class ActiveSupport::Cache::Coder + # @return [Coder] a new instance of Coder + # + # source://activesupport//lib/active_support/cache/coder.rb#8 + def initialize(serializer, compressor, legacy_serializer: T.unsafe(nil)); end -# source://activesupport//lib/active_support/cache.rb#851 -module ActiveSupport::Cache::Coders::Loader - extend ::ActiveSupport::Cache::Coders::Loader + # source://activesupport//lib/active_support/cache/coder.rb#14 + def dump(entry); end - # source://activesupport//lib/active_support/cache.rb#854 - def load(payload); end -end + # source://activesupport//lib/active_support/cache/coder.rb#20 + def dump_compressed(entry, threshold); end -# The one set by Marshal. -# -# source://activesupport//lib/active_support/cache.rb#834 -ActiveSupport::Cache::Coders::MARK_61 = T.let(T.unsafe(nil), String) + # source://activesupport//lib/active_support/cache/coder.rb#48 + def load(dumped); end -# source://activesupport//lib/active_support/cache.rb#836 -ActiveSupport::Cache::Coders::MARK_70_COMPRESSED = T.let(T.unsafe(nil), String) + private -# source://activesupport//lib/active_support/cache.rb#835 -ActiveSupport::Cache::Coders::MARK_70_UNCOMPRESSED = T.let(T.unsafe(nil), String) + # source://activesupport//lib/active_support/cache/coder.rb#136 + def dump_version(version); end -# source://activesupport//lib/active_support/cache.rb#874 -module ActiveSupport::Cache::Coders::Rails61Coder - include ::ActiveSupport::Cache::Coders::Loader - extend ::ActiveSupport::Cache::Coders::Loader - extend ::ActiveSupport::Cache::Coders::Rails61Coder + # source://activesupport//lib/active_support/cache/coder.rb#144 + def load_version(dumped_version); end - # source://activesupport//lib/active_support/cache.rb#878 - def dump(entry); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/coder.rb#121 + def signature?(dumped); end - # source://activesupport//lib/active_support/cache.rb#882 - def dump_compressed(entry, threshold); end + # source://activesupport//lib/active_support/cache/coder.rb#129 + def try_compress(string, threshold); end + + # source://activesupport//lib/active_support/cache/coder.rb#125 + def type_for_string(value); end end -# source://activesupport//lib/active_support/cache.rb#887 -module ActiveSupport::Cache::Coders::Rails70Coder - include ::ActiveSupport::Cache::Coders::Loader - extend ::ActiveSupport::Cache::Coders::Loader - extend ::ActiveSupport::Cache::Coders::Rails70Coder +# source://activesupport//lib/active_support/cache/coder.rb#76 +ActiveSupport::Cache::Coder::COMPRESSED_FLAG = T.let(T.unsafe(nil), Integer) - # source://activesupport//lib/active_support/cache.rb#891 - def dump(entry); end +# source://activesupport//lib/active_support/cache/coder.rb#98 +class ActiveSupport::Cache::Coder::LazyEntry < ::ActiveSupport::Cache::Entry + # @return [LazyEntry] a new instance of LazyEntry + # + # source://activesupport//lib/active_support/cache/coder.rb#99 + def initialize(serializer, compressor, payload, **options); end - # source://activesupport//lib/active_support/cache.rb#895 - def dump_compressed(entry, threshold); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/coder.rb#114 + def mismatched?(version); end + + # source://activesupport//lib/active_support/cache/coder.rb#106 + def value; end end -# source://activesupport//lib/active_support/cache/redis_cache_store.rb#26 -module ActiveSupport::Cache::ConnectionPoolLike - # @yield [_self] - # @yieldparam _self [ActiveSupport::Cache::ConnectionPoolLike] the object that the method was called on +# source://activesupport//lib/active_support/cache/coder.rb#84 +ActiveSupport::Cache::Coder::MARSHAL_SIGNATURE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/coder.rb#68 +ActiveSupport::Cache::Coder::OBJECT_DUMP_TYPE = T.let(T.unsafe(nil), Integer) + +# source://activesupport//lib/active_support/cache/coder.rb#80 +ActiveSupport::Cache::Coder::PACKED_EXPIRES_AT_TEMPLATE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/coder.rb#78 +ActiveSupport::Cache::Coder::PACKED_TEMPLATE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/coder.rb#79 +ActiveSupport::Cache::Coder::PACKED_TYPE_TEMPLATE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/coder.rb#82 +ActiveSupport::Cache::Coder::PACKED_VERSION_INDEX = T.let(T.unsafe(nil), Integer) + +# source://activesupport//lib/active_support/cache/coder.rb#81 +ActiveSupport::Cache::Coder::PACKED_VERSION_LENGTH_TEMPLATE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/coder.rb#66 +ActiveSupport::Cache::Coder::SIGNATURE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/coder.rb#96 +ActiveSupport::Cache::Coder::STRING_DESERIALIZERS = T.let(T.unsafe(nil), Hash) + +# source://activesupport//lib/active_support/cache/coder.rb#70 +ActiveSupport::Cache::Coder::STRING_ENCODINGS = T.let(T.unsafe(nil), Hash) + +# source://activesupport//lib/active_support/cache/coder.rb#86 +class ActiveSupport::Cache::Coder::StringDeserializer + # @return [StringDeserializer] a new instance of StringDeserializer # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#27 - def with; end + # source://activesupport//lib/active_support/cache/coder.rb#87 + def initialize(encoding); end + + # source://activesupport//lib/active_support/cache/coder.rb#91 + def load(payload); end end -# source://activesupport//lib/active_support/cache.rb#27 +# source://activesupport//lib/active_support/cache.rb#45 ActiveSupport::Cache::DEFAULT_COMPRESS_LIMIT = T.let(T.unsafe(nil), Integer) +# Raised by coders when the cache entry can't be deserialized. +# This error is treated as a cache miss. +# +# source://activesupport//lib/active_support/cache.rb#49 +class ActiveSupport::Cache::DeserializationError < ::StandardError; end + # This class is used to represent cache entries. Cache entries have a value, an optional # expiration time, and an optional version. The expiration time is used to support the :race_condition_ttl option # on the cache. The version is used to support the :version option on the cache for rejecting @@ -556,34 +869,34 @@ ActiveSupport::Cache::DEFAULT_COMPRESS_LIMIT = T.let(T.unsafe(nil), Integer) # Since cache entries in most instances will be serialized, the internals of this class are highly optimized # using short instance variable names that are lazily defined. # -# source://activesupport//lib/active_support/cache.rb#916 +# source://activesupport//lib/active_support/cache/entry.rb#14 class ActiveSupport::Cache::Entry # Creates a new cache entry for the specified value. Options supported are # +:compressed+, +:version+, +:expires_at+ and +:expires_in+. # # @return [Entry] a new instance of Entry # - # source://activesupport//lib/active_support/cache.rb#927 + # source://activesupport//lib/active_support/cache/entry.rb#25 def initialize(value, compressed: T.unsafe(nil), version: T.unsafe(nil), expires_in: T.unsafe(nil), expires_at: T.unsafe(nil), **_arg5); end # Returns the size of the cached value. This could be less than # value.bytesize if the data is compressed. # - # source://activesupport//lib/active_support/cache.rb#963 + # source://activesupport//lib/active_support/cache/entry.rb#61 def bytesize; end - # source://activesupport//lib/active_support/cache.rb#978 + # source://activesupport//lib/active_support/cache/entry.rb#76 def compressed(compress_threshold); end # @return [Boolean] # - # source://activesupport//lib/active_support/cache.rb#974 + # source://activesupport//lib/active_support/cache/entry.rb#72 def compressed?; end # Duplicates the value in a class. This is used by cache implementations that don't natively # serialize entries to protect against accidental cache modifications. # - # source://activesupport//lib/active_support/cache.rb#1008 + # source://activesupport//lib/active_support/cache/entry.rb#106 def dup_value!; end # Checks if the entry is expired. The +expires_in+ parameter can override @@ -591,140 +904,162 @@ class ActiveSupport::Cache::Entry # # @return [Boolean] # - # source://activesupport//lib/active_support/cache.rb#945 + # source://activesupport//lib/active_support/cache/entry.rb#43 def expired?; end - # source://activesupport//lib/active_support/cache.rb#949 + # source://activesupport//lib/active_support/cache/entry.rb#47 def expires_at; end - # source://activesupport//lib/active_support/cache.rb#953 + # source://activesupport//lib/active_support/cache/entry.rb#51 def expires_at=(value); end # @return [Boolean] # - # source://activesupport//lib/active_support/cache.rb#1002 + # source://activesupport//lib/active_support/cache/entry.rb#100 def local?; end # @return [Boolean] # - # source://activesupport//lib/active_support/cache.rb#939 + # source://activesupport//lib/active_support/cache/entry.rb#37 def mismatched?(version); end - # source://activesupport//lib/active_support/cache.rb#1018 + # source://activesupport//lib/active_support/cache/entry.rb#116 def pack; end - # source://activesupport//lib/active_support/cache.rb#935 + # source://activesupport//lib/active_support/cache/entry.rb#33 def value; end # Returns the value of attribute version. # - # source://activesupport//lib/active_support/cache.rb#923 + # source://activesupport//lib/active_support/cache/entry.rb#21 def version; end private - # source://activesupport//lib/active_support/cache.rb#1025 + # source://activesupport//lib/active_support/cache/entry.rb#127 + def marshal_load(payload); end + + # source://activesupport//lib/active_support/cache/entry.rb#123 def uncompress(value); end class << self - # source://activesupport//lib/active_support/cache.rb#918 + # source://activesupport//lib/active_support/cache/entry.rb#16 def unpack(members); end end end -# A cache store implementation which stores everything on the filesystem. +# = \File \Cache \Store # -# FileStore implements the Strategy::LocalCache strategy which implements -# an in-memory cache inside of a block. +# A cache store implementation which stores everything on the filesystem. # -# source://activesupport//lib/active_support/cache/file_store.rb#13 +# source://activesupport//lib/active_support/cache/file_store.rb#12 class ActiveSupport::Cache::FileStore < ::ActiveSupport::Cache::Store # @return [FileStore] a new instance of FileStore # - # source://activesupport//lib/active_support/cache/file_store.rb#21 + # source://activesupport//lib/active_support/cache/file_store.rb#20 def initialize(cache_path, **options); end # Returns the value of attribute cache_path. # - # source://activesupport//lib/active_support/cache/file_store.rb#14 + # source://activesupport//lib/active_support/cache/file_store.rb#13 def cache_path; end # Preemptively iterates through all stored keys and removes the ones which have expired. # - # source://activesupport//lib/active_support/cache/file_store.rb#41 + # source://activesupport//lib/active_support/cache/file_store.rb#40 def cleanup(options = T.unsafe(nil)); end # Deletes all items from the cache. In this case it deletes all the entries in the specified # file store directory except for .keep or .gitkeep. Be careful which directory is specified in your # config file when using +FileStore+ because everything in that directory will be deleted. # - # source://activesupport//lib/active_support/cache/file_store.rb#34 + # source://activesupport//lib/active_support/cache/file_store.rb#33 def clear(options = T.unsafe(nil)); end - # Decrements an already existing integer value that is stored in the cache. - # If the key is not found nothing is done. + # Decrement a cached integer value. Returns the updated value. + # + # If the key is unset, it will be set to +-amount+. # - # source://activesupport//lib/active_support/cache/file_store.rb#57 + # cache.decrement("foo") # => -1 + # + # To set a specific value, call #write: + # + # cache.write("baz", 5) + # cache.decrement("baz") # => 4 + # + # source://activesupport//lib/active_support/cache/file_store.rb#75 def decrement(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/file_store.rb#61 + # source://activesupport//lib/active_support/cache/file_store.rb#79 def delete_matched(matcher, options = T.unsafe(nil)); end - # Increments an already existing integer value that is stored in the cache. - # If the key is not found nothing is done. + # Increment a cached integer value. Returns the updated value. + # + # If the key is unset, it starts from +0+: # - # source://activesupport//lib/active_support/cache/file_store.rb#51 + # cache.increment("foo") # => 1 + # cache.increment("bar", 100) # => 100 + # + # To set a specific value, call #write: + # + # cache.write("baz", 5) + # cache.increment("baz") # => 6 + # + # source://activesupport//lib/active_support/cache/file_store.rb#60 def increment(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end + # source://activesupport//lib/active_support/cache/file_store.rb#91 + def inspect; end + private # Delete empty directories in the cache. # - # source://activesupport//lib/active_support/cache/file_store.rb#160 + # source://activesupport//lib/active_support/cache/file_store.rb#185 def delete_empty_directories(dir); end - # source://activesupport//lib/active_support/cache/file_store.rb#98 + # source://activesupport//lib/active_support/cache/file_store.rb#121 def delete_entry(key, **options); end # Make sure a file path's directories exist. # - # source://activesupport//lib/active_support/cache/file_store.rb#169 + # source://activesupport//lib/active_support/cache/file_store.rb#194 def ensure_cache_path(path); end # Translate a file path into a key. # - # source://activesupport//lib/active_support/cache/file_store.rb#154 + # source://activesupport//lib/active_support/cache/file_store.rb#179 def file_path_key(path); end # Lock a file for a block so only one process can modify it at a time. # - # source://activesupport//lib/active_support/cache/file_store.rb#113 + # source://activesupport//lib/active_support/cache/file_store.rb#138 def lock_file(file_name, &block); end - # Modifies the amount of an already existing integer value that is stored in the cache. - # If the key is not found nothing is done. + # Modifies the amount of an integer value that is stored in the cache. + # If the key is not found it is created and set to +amount+. # - # source://activesupport//lib/active_support/cache/file_store.rb#187 + # source://activesupport//lib/active_support/cache/file_store.rb#212 def modify_value(name, amount, options); end # Translate a key into a file path. # - # source://activesupport//lib/active_support/cache/file_store.rb#127 + # source://activesupport//lib/active_support/cache/file_store.rb#152 def normalize_key(key, options); end - # source://activesupport//lib/active_support/cache/file_store.rb#73 + # source://activesupport//lib/active_support/cache/file_store.rb#96 def read_entry(key, **options); end - # source://activesupport//lib/active_support/cache/file_store.rb#80 + # source://activesupport//lib/active_support/cache/file_store.rb#103 def read_serialized_entry(key, **_arg1); end - # source://activesupport//lib/active_support/cache/file_store.rb#173 + # source://activesupport//lib/active_support/cache/file_store.rb#198 def search_dir(dir, &callback); end - # source://activesupport//lib/active_support/cache/file_store.rb#87 + # source://activesupport//lib/active_support/cache/file_store.rb#110 def write_entry(key, entry, **options); end - # source://activesupport//lib/active_support/cache/file_store.rb#91 + # source://activesupport//lib/active_support/cache/file_store.rb#114 def write_serialized_entry(key, payload, **options); end class << self @@ -732,31 +1067,33 @@ class ActiveSupport::Cache::FileStore < ::ActiveSupport::Cache::Store # # @return [Boolean] # - # source://activesupport//lib/active_support/cache/file_store.rb#27 + # source://activesupport//lib/active_support/cache/file_store.rb#26 def supports_cache_versioning?; end end end -# source://activesupport//lib/active_support/cache/file_store.rb#16 +# source://activesupport//lib/active_support/cache/file_store.rb#15 ActiveSupport::Cache::FileStore::DIR_FORMATTER = T.let(T.unsafe(nil), String) # max filename size on file system is 255, minus room for timestamp, pid, and random characters appended by Tempfile (used by atomic write) # -# source://activesupport//lib/active_support/cache/file_store.rb#17 +# source://activesupport//lib/active_support/cache/file_store.rb#16 ActiveSupport::Cache::FileStore::FILENAME_MAX_SIZE = T.let(T.unsafe(nil), Integer) # max is 1024, plus some room # -# source://activesupport//lib/active_support/cache/file_store.rb#18 +# source://activesupport//lib/active_support/cache/file_store.rb#17 ActiveSupport::Cache::FileStore::FILEPATH_MAX_SIZE = T.let(T.unsafe(nil), Integer) -# source://activesupport//lib/active_support/cache/file_store.rb#19 +# source://activesupport//lib/active_support/cache/file_store.rb#18 ActiveSupport::Cache::FileStore::GITKEEP_FILES = T.let(T.unsafe(nil), Array) +# = Memory \Cache \Store +# # A cache store implementation which stores everything into memory in the -# same process. If you're running multiple Ruby on Rails server processes +# same process. If you're running multiple Ruby on \Rails server processes # (which is the case if you're using Phusion Passenger or puma clustered mode), -# then this means that Rails server process instances won't be able +# then this means that \Rails server process instances won't be able # to share cache data with each other and this may not be the most # appropriate cache in that scenario. # @@ -765,86 +1102,105 @@ ActiveSupport::Cache::FileStore::GITKEEP_FILES = T.let(T.unsafe(nil), Array) # a cleanup will occur which tries to prune the cache down to three quarters # of the maximum size by removing the least recently used entries. # -# Unlike other Cache store implementations, MemoryStore does not compress -# values by default. MemoryStore does not benefit from compression as much +# Unlike other Cache store implementations, +MemoryStore+ does not compress +# values by default. +MemoryStore+ does not benefit from compression as much # as other Store implementations, as it does not send data over a network. # However, when compression is enabled, it still pays the full cost of # compression in terms of cpu use. # -# MemoryStore is thread-safe. +# +MemoryStore+ is thread-safe. # -# source://activesupport//lib/active_support/cache/memory_store.rb#26 +# source://activesupport//lib/active_support/cache/memory_store.rb#28 class ActiveSupport::Cache::MemoryStore < ::ActiveSupport::Cache::Store # @return [MemoryStore] a new instance of MemoryStore # - # source://activesupport//lib/active_support/cache/memory_store.rb#48 + # source://activesupport//lib/active_support/cache/memory_store.rb#73 def initialize(options = T.unsafe(nil)); end # Preemptively iterates through all stored keys and removes the ones which have expired. # - # source://activesupport//lib/active_support/cache/memory_store.rb#75 + # source://activesupport//lib/active_support/cache/memory_store.rb#101 def cleanup(options = T.unsafe(nil)); end # Delete all data stored in a given cache store. # - # source://activesupport//lib/active_support/cache/memory_store.rb#67 + # source://activesupport//lib/active_support/cache/memory_store.rb#93 def clear(options = T.unsafe(nil)); end - # Decrement an integer value in the cache. + # Decrement a cached integer value. Returns the updated value. + # + # If the key is unset or has expired, it will be set to +-amount+. + # + # cache.decrement("foo") # => -1 # - # source://activesupport//lib/active_support/cache/memory_store.rb#117 + # To set a specific value, call #write: + # + # cache.write("baz", 5) + # cache.decrement("baz") # => 4 + # + # source://activesupport//lib/active_support/cache/memory_store.rb#164 def decrement(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end # Deletes cache entries if the cache key matches a given pattern. # - # source://activesupport//lib/active_support/cache/memory_store.rb#122 + # source://activesupport//lib/active_support/cache/memory_store.rb#169 def delete_matched(matcher, options = T.unsafe(nil)); end - # Increment an integer value in the cache. + # Increment a cached integer value. Returns the updated value. + # + # If the key is unset, it will be set to +amount+: + # + # cache.increment("foo") # => 1 + # cache.increment("bar", 100) # => 100 # - # source://activesupport//lib/active_support/cache/memory_store.rb#112 + # To set a specific value, call #write: + # + # cache.write("baz", 5) + # cache.increment("baz") # => 6 + # + # source://activesupport//lib/active_support/cache/memory_store.rb#149 def increment(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/memory_store.rb#133 + # source://activesupport//lib/active_support/cache/memory_store.rb#181 def inspect; end # To ensure entries fit within the specified memory prune the cache by removing the least # recently accessed entries. # - # source://activesupport//lib/active_support/cache/memory_store.rb#88 + # source://activesupport//lib/active_support/cache/memory_store.rb#114 def prune(target_size, max_time = T.unsafe(nil)); end # Returns true if the cache is currently being pruned. # # @return [Boolean] # - # source://activesupport//lib/active_support/cache/memory_store.rb#107 + # source://activesupport//lib/active_support/cache/memory_store.rb#133 def pruning?; end # Synchronize calls to the cache. This should be called wherever the underlying cache implementation # is not thread safe. # - # source://activesupport//lib/active_support/cache/memory_store.rb#139 + # source://activesupport//lib/active_support/cache/memory_store.rb#187 def synchronize(&block); end private - # source://activesupport//lib/active_support/cache/memory_store.rb#150 + # source://activesupport//lib/active_support/cache/memory_store.rb#194 def cached_size(key, payload); end - # source://activesupport//lib/active_support/cache/memory_store.rb#146 - def default_coder; end - - # source://activesupport//lib/active_support/cache/memory_store.rb#183 + # source://activesupport//lib/active_support/cache/memory_store.rb#227 def delete_entry(key, **options); end - # source://activesupport//lib/active_support/cache/memory_store.rb#191 + # Modifies the amount of an integer value that is stored in the cache. + # If the key is not found it is created and set to +amount+. + # + # source://activesupport//lib/active_support/cache/memory_store.rb#237 def modify_value(name, amount, options); end - # source://activesupport//lib/active_support/cache/memory_store.rb#154 + # source://activesupport//lib/active_support/cache/memory_store.rb#198 def read_entry(key, **options); end - # source://activesupport//lib/active_support/cache/memory_store.rb#166 + # source://activesupport//lib/active_support/cache/memory_store.rb#210 def write_entry(key, entry, **options); end class << self @@ -852,42 +1208,41 @@ class ActiveSupport::Cache::MemoryStore < ::ActiveSupport::Cache::Store # # @return [Boolean] # - # source://activesupport//lib/active_support/cache/memory_store.rb#62 + # source://activesupport//lib/active_support/cache/memory_store.rb#88 def supports_cache_versioning?; end end end -# source://activesupport//lib/active_support/cache/memory_store.rb#27 +# source://activesupport//lib/active_support/cache/memory_store.rb#29 module ActiveSupport::Cache::MemoryStore::DupCoder extend ::ActiveSupport::Cache::MemoryStore::DupCoder - # source://activesupport//lib/active_support/cache/memory_store.rb#30 + # source://activesupport//lib/active_support/cache/memory_store.rb#32 def dump(entry); end - # source://activesupport//lib/active_support/cache/memory_store.rb#35 + # source://activesupport//lib/active_support/cache/memory_store.rb#40 def dump_compressed(entry, threshold); end - # source://activesupport//lib/active_support/cache/memory_store.rb#41 + # source://activesupport//lib/active_support/cache/memory_store.rb#45 def load(entry); end -end -# source://activesupport//lib/active_support/cache/memory_store.rb#144 -ActiveSupport::Cache::MemoryStore::PER_ENTRY_OVERHEAD = T.let(T.unsafe(nil), Integer) + private -# source://activesupport//lib/active_support/cache.rb#817 -module ActiveSupport::Cache::NullCoder - extend ::ActiveSupport::Cache::NullCoder + # source://activesupport//lib/active_support/cache/memory_store.rb#56 + def dump_value(value); end - # source://activesupport//lib/active_support/cache.rb#820 - def dump(entry); end + # source://activesupport//lib/active_support/cache/memory_store.rb#64 + def load_value(string); end +end - # source://activesupport//lib/active_support/cache.rb#824 - def dump_compressed(entry, threshold); end +# source://activesupport//lib/active_support/cache/memory_store.rb#54 +ActiveSupport::Cache::MemoryStore::DupCoder::MARSHAL_SIGNATURE = T.let(T.unsafe(nil), String) - # source://activesupport//lib/active_support/cache.rb#828 - def load(payload); end -end +# source://activesupport//lib/active_support/cache/memory_store.rb#192 +ActiveSupport::Cache::MemoryStore::PER_ENTRY_OVERHEAD = T.let(T.unsafe(nil), Integer) +# = Null \Cache \Store +# # A cache store implementation which doesn't actually store anything. Useful in # development and test environments where you don't want caching turned on but # need to go through the caching interface. @@ -896,40 +1251,43 @@ end # be cached inside blocks that utilize this strategy. See # ActiveSupport::Cache::Strategy::LocalCache for more details. # -# source://activesupport//lib/active_support/cache/null_store.rb#12 +# source://activesupport//lib/active_support/cache/null_store.rb#14 class ActiveSupport::Cache::NullStore < ::ActiveSupport::Cache::Store include ::ActiveSupport::Cache::Strategy::LocalCache - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#81 - def cleanup(**options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#85 + def cleanup(options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#75 - def clear(**options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#79 + def clear(options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#100 - def decrement(name, amount = T.unsafe(nil), **options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#108 + def decrement(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#87 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#91 def delete_matched(matcher, options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#93 - def increment(name, amount = T.unsafe(nil), **options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#97 + def increment(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://activesupport//lib/active_support/cache/null_store.rb#37 + def inspect; end private - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#147 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#162 def delete_entry(key, **_arg1); end - # source://activesupport//lib/active_support/cache/null_store.rb#36 + # source://activesupport//lib/active_support/cache/null_store.rb#42 def read_entry(key, **s); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#108 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#120 def read_serialized_entry(key, raw: T.unsafe(nil), **options); end - # source://activesupport//lib/active_support/cache/null_store.rb#43 + # source://activesupport//lib/active_support/cache/null_store.rb#49 def write_entry(key, entry, **_arg2); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#138 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#153 def write_serialized_entry(key, payload, **_arg2); end class << self @@ -937,41 +1295,45 @@ class ActiveSupport::Cache::NullStore < ::ActiveSupport::Cache::Store # # @return [Boolean] # - # source://activesupport//lib/active_support/cache/null_store.rb#16 + # source://activesupport//lib/active_support/cache/null_store.rb#18 def supports_cache_versioning?; end end end # Mapping of canonical option names to aliases that a store will recognize. # -# source://activesupport//lib/active_support/cache.rb#30 +# source://activesupport//lib/active_support/cache.rb#41 ActiveSupport::Cache::OPTION_ALIASES = T.let(T.unsafe(nil), Hash) -# Redis cache store. +# = Redis \Cache \Store # -# Deployment note: Take care to use a *dedicated Redis cache* rather -# than pointing this at your existing Redis server. It won't cope well -# with mixed usage patterns and it won't expire cache entries by default. +# Deployment note: Take care to use a dedicated Redis cache rather +# than pointing this at a persistent Redis server (for example, one used as +# an Active Job queue). Redis won't cope well with mixed usage patterns and it +# won't expire cache entries by default. # # Redis cache server setup guide: https://redis.io/topics/lru-cache # -# * Supports vanilla Redis, hiredis, and Redis::Distributed. -# * Supports Memcached-like sharding across Redises with Redis::Distributed. +# * Supports vanilla Redis, hiredis, and +Redis::Distributed+. +# * Supports Memcached-like sharding across Redises with +Redis::Distributed+. # * Fault tolerant. If the Redis server is unavailable, no exceptions are # raised. Cache fetches are all misses and writes are dropped. # * Local cache. Hot in-memory primary cache within block/middleware scope. -# * +read_multi+ and +write_multi+ support for Redis mget/mset. Use Redis::Distributed -# 4.0.1+ for distributed mget support. +# * +read_multi+ and +write_multi+ support for Redis mget/mset. Use +# +Redis::Distributed+ 4.0.1+ for distributed mget support. # * +delete_matched+ support for Redis KEYS globs. # -# source://activesupport//lib/active_support/cache/redis_cache_store.rb#51 +# source://activesupport//lib/active_support/cache/redis_cache_store.rb#37 class ActiveSupport::Cache::RedisCacheStore < ::ActiveSupport::Cache::Store include ::ActiveSupport::Cache::Strategy::LocalCache # Creates a new Redis cache store. # - # Handles four options: :redis block, :redis instance, single :url - # string, and multiple :url strings. + # There are four ways to provide the Redis client used by the cache: the + # +:redis+ param can be a Redis instance or a block that returns a Redis + # instance, or the +:url+ param can be a string or an array of strings + # which will be used to create a Redis instance or a +Redis::Distributed+ + # instance. # # Option Class Result # :redis Proc -> options[:redis].call @@ -996,38 +1358,53 @@ class ActiveSupport::Cache::RedisCacheStore < ::ActiveSupport::Cache::Store # "thundering herd" cache writes when hot cache entries are expired. # See ActiveSupport::Cache::Store#fetch for more. # + # Setting skip_nil: true will not cache nil results: + # + # cache.fetch('foo') { nil } + # cache.fetch('bar', skip_nil: true) { nil } + # cache.exist?('foo') # => true + # cache.exist?('bar') # => false + # # @return [RedisCacheStore] a new instance of RedisCacheStore # # source://activesupport//lib/active_support/cache/redis_cache_store.rb#149 - def initialize(namespace: T.unsafe(nil), compress: T.unsafe(nil), compress_threshold: T.unsafe(nil), coder: T.unsafe(nil), expires_in: T.unsafe(nil), race_condition_ttl: T.unsafe(nil), error_handler: T.unsafe(nil), **redis_options); end + def initialize(error_handler: T.unsafe(nil), **redis_options); end # Cache Store API implementation. # # Removes expired entries. Handled natively by Redis least-recently-/ # least-frequently-used expiry, so manual cleanup is not supported. # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#81 - def cleanup(**options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#85 + def cleanup(options = T.unsafe(nil)); end # Clear the entire cache on all Redis servers. Safe to use on # shared servers if the cache is namespaced. # # Failsafe: Raises errors. # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#75 - def clear(**options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#79 + def clear(options = T.unsafe(nil)); end - # Cache Store API implementation. + # Decrement a cached integer value using the Redis decrby atomic operator. + # Returns the updated value. + # + # If the key is unset or has expired, it will be set to +-amount+: + # + # cache.decrement("foo") # => -1 # - # Decrement a cached value. This method uses the Redis decr atomic - # operator and can only be used on values written with the +:raw+ option. - # Calling it on a value not stored with +:raw+ will initialize that value - # to zero. + # To set a specific value, call #write passing raw: true: + # + # cache.write("baz", 5, raw: true) + # cache.decrement("baz") # => 4 + # + # Decrementing a non-numeric value, or a value written without + # raw: true, will fail and return +nil+. # # Failsafe: Raises errors. # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#100 - def decrement(name, amount = T.unsafe(nil), **options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#108 + def decrement(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end # Cache Store API implementation. # @@ -1045,126 +1422,124 @@ class ActiveSupport::Cache::RedisCacheStore < ::ActiveSupport::Cache::Store # # Failsafe: Raises errors. # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#87 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#91 def delete_matched(matcher, options = T.unsafe(nil)); end - # Cache Store API implementation. + # Increment a cached integer value using the Redis incrby atomic operator. + # Returns the updated value. # - # Increment a cached value. This method uses the Redis incr atomic - # operator and can only be used on values written with the +:raw+ option. - # Calling it on a value not stored with +:raw+ will initialize that value - # to zero. + # If the key is unset or has expired, it will be set to +amount+: # - # Failsafe: Raises errors. + # cache.increment("foo") # => 1 + # cache.increment("bar", 100) # => 100 # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#93 - def increment(name, amount = T.unsafe(nil), **options); end - - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#174 - def inspect; end - - # Returns the value of attribute max_key_bytesize. + # To set a specific value, call #write passing raw: true: # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#120 - def max_key_bytesize; end - - # @return [Boolean] + # cache.write("baz", 5, raw: true) + # cache.increment("baz") # => 6 + # + # Incrementing a non-numeric value, or a value written without + # raw: true, will fail and return +nil+. + # + # Failsafe: Raises errors. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#304 - def mget_capable?; end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#97 + def increment(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end - # @return [Boolean] + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#164 + def inspect; end + + # Returns the value of attribute max_key_bytesize. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#309 - def mset_capable?; end + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#109 + def max_key_bytesize; end # Cache Store API implementation. # # Read multiple values at once. Returns a hash of requested keys -> # fetched values. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#183 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#172 def read_multi(*names); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#161 - def redis; end - - # Returns the value of attribute redis_options. + # Returns the value of attribute redis. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#119 - def redis_options; end + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#110 + def redis; end # Get info from redis servers. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#300 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#298 def stats; end private + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#447 + def change_counter(key, amount, options); end + # Delete an entry from the cache. # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#147 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#162 def delete_entry(key, **_arg1); end # Deletes multiple entries in the cache. Returns the number of entries deleted. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#408 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#389 def delete_multi_entries(entries, **_options); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#443 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#425 def deserialize_entry(payload, raw: T.unsafe(nil), **_arg2); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#465 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#481 def failsafe(method, returning: T.unsafe(nil)); end # Truncate keys that exceed 1kB. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#429 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#411 def normalize_key(key, options); end + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#303 + def pipeline_entries(entries, &block); end + # Store provider interface: # Read an entry from the cache. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#328 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#317 def read_entry(key, **options); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#122 - def read_multi_entries(keys, **options); end - - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#346 - def read_multi_mget(*names); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#134 + def read_multi_entries(names, **options); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#108 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#120 def read_serialized_entry(key, raw: T.unsafe(nil), **options); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#459 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#441 def serialize_entries(entries, **options); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#451 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#433 def serialize_entry(entry, raw: T.unsafe(nil), **options); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#315 - def set_redis_capabilities; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#474 + def supports_expire_nx?; end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#433 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#415 def truncate_key(key); end # Write an entry to the cache. # # Requires Redis 2.6.12+ for extended SET options. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#371 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#354 def write_entry(key, entry, raw: T.unsafe(nil), **options); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#394 - def write_key_expiry(client, key, options); end - # Nonstandard store provider API to write multiple values at once. # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#413 - def write_multi_entries(entries, expires_in: T.unsafe(nil), **options); end + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#396 + def write_multi_entries(entries, **options); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#138 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#153 def write_serialized_entry(key, payload, **_arg2); end class << self @@ -1179,42 +1554,157 @@ class ActiveSupport::Cache::RedisCacheStore < ::ActiveSupport::Cache::Store # :url String -> Redis.new(url: …) # :url Array -> Redis::Distributed.new([{ url: … }, { url: … }, …]) # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#91 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#81 def build_redis(redis: T.unsafe(nil), url: T.unsafe(nil), **redis_options); end # Advertise cache versioning support. # # @return [Boolean] # - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#73 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#63 def supports_cache_versioning?; end private - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#114 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#104 def build_redis_client(**redis_options); end - # source://activesupport//lib/active_support/cache/redis_cache_store.rb#108 + # source://activesupport//lib/active_support/cache/redis_cache_store.rb#98 def build_redis_distributed_client(urls:, **redis_options); end end end -# source://activesupport//lib/active_support/cache/redis_cache_store.rb#62 +# source://activesupport//lib/active_support/cache/redis_cache_store.rb#47 ActiveSupport::Cache::RedisCacheStore::DEFAULT_ERROR_HANDLER = T.let(T.unsafe(nil), Proc) -# source://activesupport//lib/active_support/cache/redis_cache_store.rb#55 +# source://activesupport//lib/active_support/cache/redis_cache_store.rb#41 ActiveSupport::Cache::RedisCacheStore::DEFAULT_REDIS_OPTIONS = T.let(T.unsafe(nil), Hash) -# Keys are truncated with the ActiveSupport digest if they exceed 1kB +# Keys are truncated with the Active Support digest if they exceed 1kB # -# source://activesupport//lib/active_support/cache/redis_cache_store.rb#53 +# source://activesupport//lib/active_support/cache/redis_cache_store.rb#39 ActiveSupport::Cache::RedisCacheStore::MAX_KEY_BYTESIZE = T.let(T.unsafe(nil), Integer) # The maximum number of entries to receive per SCAN call. # -# source://activesupport//lib/active_support/cache/redis_cache_store.rb#69 +# source://activesupport//lib/active_support/cache/redis_cache_store.rb#59 ActiveSupport::Cache::RedisCacheStore::SCAN_BATCH_SIZE = T.let(T.unsafe(nil), Integer) +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#8 +module ActiveSupport::Cache::SerializerWithFallback + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#17 + def load(dumped); end + + private + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#39 + def marshal_load(payload); end + + class << self + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#9 + def [](format); end + end +end + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#66 +module ActiveSupport::Cache::SerializerWithFallback::Marshal70WithFallback + include ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback::Marshal70WithFallback + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#88 + def _load(marked); end + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#73 + def dump(entry); end + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#77 + def dump_compressed(entry, threshold); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#94 + def dumped?(dumped); end +end + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#71 +ActiveSupport::Cache::SerializerWithFallback::Marshal70WithFallback::MARK_COMPRESSED = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#70 +ActiveSupport::Cache::SerializerWithFallback::Marshal70WithFallback::MARK_UNCOMPRESSED = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#99 +module ActiveSupport::Cache::SerializerWithFallback::Marshal71WithFallback + include ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback::Marshal71WithFallback + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#109 + def _load(dumped); end + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#105 + def dump(value); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#113 + def dumped?(dumped); end +end + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#103 +ActiveSupport::Cache::SerializerWithFallback::Marshal71WithFallback::MARSHAL_SIGNATURE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#118 +module ActiveSupport::Cache::SerializerWithFallback::MessagePackWithFallback + include ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback::MessagePackWithFallback + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#126 + def _load(dumped); end + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#122 + def dump(value); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#130 + def dumped?(dumped); end + + private + + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#135 + def available?; end +end + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#45 +module ActiveSupport::Cache::SerializerWithFallback::PassthroughWithFallback + include ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback + extend ::ActiveSupport::Cache::SerializerWithFallback::PassthroughWithFallback + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#57 + def _load(entry); end + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#49 + def dump(entry); end + + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#53 + def dump_compressed(entry, threshold); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#61 + def dumped?(dumped); end +end + +# source://activesupport//lib/active_support/cache/serializer_with_fallback.rb#144 +ActiveSupport::Cache::SerializerWithFallback::SERIALIZERS = T.let(T.unsafe(nil), Hash) + +# = Active Support \Cache \Store +# # An abstract cache store class. There are multiple cache store # implementations, each having its own additional features. See the classes # under the ActiveSupport::Cache module, e.g. @@ -1224,13 +1714,13 @@ ActiveSupport::Cache::RedisCacheStore::SCAN_BATCH_SIZE = T.let(T.unsafe(nil), In # Some implementations may not support all methods beyond the basic cache # methods of #fetch, #write, #read, #exist?, and #delete. # -# ActiveSupport::Cache::Store can store any Ruby object that is supported by -# its +coder+'s +dump+ and +load+ methods. +# +ActiveSupport::Cache::Store+ can store any Ruby object that is supported +# by its +coder+'s +dump+ and +load+ methods. # # cache = ActiveSupport::Cache::MemoryStore.new # # cache.read('city') # => nil -# cache.write('city', "Duckburgh") +# cache.write('city', "Duckburgh") # => true # cache.read('city') # => "Duckburgh" # # cache.write('not serializable', Proc.new {}) # => TypeError @@ -1255,25 +1745,83 @@ ActiveSupport::Cache::RedisCacheStore::SCAN_BATCH_SIZE = T.let(T.unsafe(nil), In # cache.namespace = -> { @last_mod_time } # Set the namespace to a variable # @last_mod_time = Time.now # Invalidate the entire cache by changing namespace # -# source://activesupport//lib/active_support/cache.rb#175 +# source://activesupport//lib/active_support/cache.rb#188 class ActiveSupport::Cache::Store # Creates a new cache. # # ==== Options # - # * +:namespace+ - Sets the namespace for the cache. This option is - # especially useful if your application shares a cache with other - # applications. - # * +:coder+ - Replaces the default cache entry serialization mechanism - # with a custom one. The +coder+ must respond to +dump+ and +load+. - # Using a custom coder disables automatic compression. + # [+:namespace+] + # Sets the namespace for the cache. This option is especially useful if + # your application shares a cache with other applications. + # + # [+:serializer+] + # The serializer for cached values. Must respond to +dump+ and +load+. + # + # The default serializer depends on the cache format version (set via + # +config.active_support.cache_format_version+ when using Rails). The + # default serializer for each format version includes a fallback + # mechanism to deserialize values from any format version. This behavior + # makes it easy to migrate between format versions without invalidating + # the entire cache. + # + # You can also specify serializer: :message_pack to use a + # preconfigured serializer based on ActiveSupport::MessagePack. The + # +:message_pack+ serializer includes the same deserialization fallback + # mechanism, allowing easy migration from (or to) the default + # serializer. The +:message_pack+ serializer may improve performance, + # but it requires the +msgpack+ gem. + # + # [+:compressor+] + # The compressor for serialized cache values. Must respond to +deflate+ + # and +inflate+. + # + # The default compressor is +Zlib+. To define a new custom compressor + # that also decompresses old cache entries, you can check compressed + # values for Zlib's "\x78" signature: + # + # module MyCompressor + # def self.deflate(dumped) + # # compression logic... (make sure result does not start with "\x78"!) + # end + # + # def self.inflate(compressed) + # if compressed.start_with?("\x78") + # Zlib.inflate(compressed) + # else + # # decompression logic... + # end + # end + # end + # + # ActiveSupport::Cache.lookup_store(:redis_cache_store, compressor: MyCompressor) + # + # [+:coder+] + # The coder for serializing and (optionally) compressing cache entries. + # Must respond to +dump+ and +load+. + # + # The default coder composes the serializer and compressor, and includes + # some performance optimizations. If you only need to override the + # serializer or compressor, you should specify the +:serializer+ or + # +:compressor+ options instead. + # + # If the store can handle cache entries directly, you may also specify + # coder: nil to omit the serializer, compressor, and coder. For + # example, if you are using ActiveSupport::Cache::MemoryStore and can + # guarantee that cache values will not be mutated, you can specify + # coder: nil to avoid the overhead of safeguarding against + # mutation. + # + # The +:coder+ option is mutally exclusive with the +:serializer+ and + # +:compressor+ options. Specifying them together will raise an + # +ArgumentError+. # # Any other specified options are treated as default options for the # relevant cache operations, such as #read, #write, and #fetch. # # @return [Store] a new instance of Store # - # source://activesupport//lib/active_support/cache.rb#211 + # source://activesupport//lib/active_support/cache.rb#295 def initialize(options = T.unsafe(nil)); end # Cleans up the cache by removing expired entries. @@ -1284,7 +1832,7 @@ class ActiveSupport::Cache::Store # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#582 + # source://activesupport//lib/active_support/cache.rb#747 def cleanup(options = T.unsafe(nil)); end # Clears the entire cache. Be careful with this method since it could @@ -1296,7 +1844,7 @@ class ActiveSupport::Cache::Store # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#592 + # source://activesupport//lib/active_support/cache.rb#757 def clear(options = T.unsafe(nil)); end # Decrements an integer value in the cache. @@ -1307,14 +1855,15 @@ class ActiveSupport::Cache::Store # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#573 + # source://activesupport//lib/active_support/cache.rb#738 def decrement(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end - # Deletes an entry in the cache. Returns +true+ if an entry is deleted. + # Deletes an entry in the cache. Returns +true+ if an entry is deleted + # and +false+ otherwise. # # Options are passed to the underlying cache implementation. # - # source://activesupport//lib/active_support/cache.rb#514 + # source://activesupport//lib/active_support/cache.rb#674 def delete(name, options = T.unsafe(nil)); end # Deletes all entries with keys matching the pattern. @@ -1325,14 +1874,15 @@ class ActiveSupport::Cache::Store # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#555 + # source://activesupport//lib/active_support/cache.rb#720 def delete_matched(matcher, options = T.unsafe(nil)); end - # Deletes multiple entries in the cache. + # Deletes multiple entries in the cache. Returns the number of deleted + # entries. # # Options are passed to the underlying cache implementation. # - # source://activesupport//lib/active_support/cache.rb#525 + # source://activesupport//lib/active_support/cache.rb#687 def delete_multi(names, options = T.unsafe(nil)); end # Returns +true+ if the cache contains an entry for the given key. @@ -1341,7 +1891,7 @@ class ActiveSupport::Cache::Store # # @return [Boolean] # - # source://activesupport//lib/active_support/cache.rb#537 + # source://activesupport//lib/active_support/cache.rb#701 def exist?(name, options = T.unsafe(nil)); end # Fetches data from the cache, using the given key. If there is data in @@ -1364,8 +1914,8 @@ class ActiveSupport::Cache::Store # # ==== Options # - # Internally, +fetch+ calls #read_entry, and calls #write_entry on a cache - # miss. Thus, +fetch+ supports the same options as #read and #write. + # Internally, +fetch+ calls +read_entry+, and calls +write_entry+ on a + # cache miss. Thus, +fetch+ supports the same options as #read and #write. # Additionally, +fetch+ supports the following options: # # * force: true - Forces a cache "miss," meaning we treat the @@ -1405,33 +1955,61 @@ class ActiveSupport::Cache::Store # has elapsed. # # # Set all values to expire after one minute. - # cache = ActiveSupport::Cache::MemoryStore.new(expires_in: 1.minute) + # cache = ActiveSupport::Cache::MemoryStore.new(expires_in: 1) # - # cache.write('foo', 'original value') + # cache.write("foo", "original value") # val_1 = nil # val_2 = nil - # sleep 60 + # p cache.read("foo") # => "original value" # - # Thread.new do - # val_1 = cache.fetch('foo', race_condition_ttl: 10.seconds) do + # sleep 1 # wait until the cache expires + # + # t1 = Thread.new do + # # fetch does the following: + # # 1. gets an recent expired entry + # # 2. extends the expiry by 2 seconds (race_condition_ttl) + # # 3. regenerates the new value + # val_1 = cache.fetch("foo", race_condition_ttl: 2) do # sleep 1 - # 'new value 1' + # "new value 1" # end # end # - # Thread.new do - # val_2 = cache.fetch('foo', race_condition_ttl: 10.seconds) do - # 'new value 2' - # end + # # Wait until t1 extends the expiry of the entry + # # but before generating the new value + # sleep 0.1 + # + # val_2 = cache.fetch("foo", race_condition_ttl: 2) do + # # This block won't be executed because t1 extended the expiry + # "new value 2" # end # - # cache.fetch('foo') # => "original value" - # sleep 10 # First thread extended the life of cache by another 10 seconds - # cache.fetch('foo') # => "new value 1" - # val_1 # => "new value 1" - # val_2 # => "original value" + # t1.join + # + # p val_1 # => "new value 1" + # p val_2 # => "oritinal value" + # p cache.fetch("foo") # => "new value 1" # - # source://activesupport//lib/active_support/cache.rb#321 + # # The entry requires 3 seconds to expire (expires_in + race_condition_ttl) + # # We have waited 2 seconds already (sleep(1) + t1.join) thus we need to wait 1 + # # more second to see the entry expire. + # sleep 1 + # + # p cache.fetch("foo") # => nil + # + # ==== Dynamic Options + # + # In some cases it may be necessary to dynamically compute options based + # on the cached value. To support this, an ActiveSupport::Cache::WriteOptions + # instance is passed as the second argument to the block. For example: + # + # cache.fetch("authentication-token:#{user.id}") do |key, options| + # token = authenticate_to_service + # options.expires_at = token.expires_at + # token + # end + # + # source://activesupport//lib/active_support/cache.rb#444 def fetch(name, options = T.unsafe(nil), &block); end # Fetches data from the cache, using the given keys. If there is data in @@ -1451,7 +2029,8 @@ class ActiveSupport::Cache::Store # # => { "bim" => "bam", # # "unknown_key" => "Fallback value for key: unknown_key" } # - # Options are passed to the underlying cache implementation. For example: + # You may also specify additional options via the +options+ argument. See #fetch for details. + # Other options are passed to the underlying cache implementation. For example: # # cache.fetch_multi("fizz", expires_in: 5.seconds) do |key| # "buzz" @@ -1465,7 +2044,7 @@ class ActiveSupport::Cache::Store # # @raise [ArgumentError] # - # source://activesupport//lib/active_support/cache.rb#447 + # source://activesupport//lib/active_support/cache.rb#593 def fetch_multi(*names); end # Increments an integer value in the cache. @@ -1476,28 +2055,34 @@ class ActiveSupport::Cache::Store # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#564 + # source://activesupport//lib/active_support/cache.rb#729 def increment(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache.rb#176 + # source://activesupport//lib/active_support/cache.rb#189 def logger; end - # source://activesupport//lib/active_support/cache.rb#176 + # source://activesupport//lib/active_support/cache.rb#189 def logger=(val); end # Silences the logger within a block. # - # source://activesupport//lib/active_support/cache.rb#227 + # source://activesupport//lib/active_support/cache.rb#322 def mute; end - # source://activesupport//lib/active_support/cache.rb#546 + # source://activesupport//lib/active_support/cache.rb#711 def new_entry(value, options = T.unsafe(nil)); end # Returns the value of attribute options. # - # source://activesupport//lib/active_support/cache.rb#178 + # source://activesupport//lib/active_support/cache.rb#192 def options; end + # source://activesupport//lib/active_support/cache.rb#190 + def raise_on_invalid_cache_expiration_time; end + + # source://activesupport//lib/active_support/cache.rb#190 + def raise_on_invalid_cache_expiration_time=(val); end + # Reads data from the cache, using the given key. If there is data in # the cache with the given key, then that data is returned. Otherwise, # +nil+ is returned. @@ -1508,13 +2093,14 @@ class ActiveSupport::Cache::Store # # ==== Options # + # * +:namespace+ - Replace the store namespace for this call. # * +:version+ - Specifies a version for the cache entry. If the cached # version does not match the requested version, the read will be treated # as a cache miss. This feature is used to support recyclable cache keys. # # Other options will be handled by the specific cache store implementation. # - # source://activesupport//lib/active_support/cache.rb#362 + # source://activesupport//lib/active_support/cache.rb#498 def read(name, options = T.unsafe(nil)); end # Reads multiple values at once from the cache. Options can be passed @@ -1524,27 +2110,30 @@ class ActiveSupport::Cache::Store # # Returns a hash mapping the names provided to the values found. # - # source://activesupport//lib/active_support/cache.rb#395 + # source://activesupport//lib/active_support/cache.rb#536 def read_multi(*names); end # Returns the value of attribute silence. # - # source://activesupport//lib/active_support/cache.rb#178 + # source://activesupport//lib/active_support/cache.rb#192 def silence; end # Silences the logger. # - # source://activesupport//lib/active_support/cache.rb#221 + # source://activesupport//lib/active_support/cache.rb#316 def silence!; end # Returns the value of attribute silence. # - # source://activesupport//lib/active_support/cache.rb#178 + # source://activesupport//lib/active_support/cache.rb#192 def silence?; end # Writes the value to the cache with the key. The value must be supported # by the +coder+'s +dump+ and +load+ methods. # + # Returns +true+ if the write succeeded, +nil+ if there was an error talking + # to the cache backend, or +false+ if the write failed for another reason. + # # By default, cache entries larger than 1kB are compressed. Compression # allows more data to be stored in the same memory footprint, leading to # fewer cache evictions and higher hit rates. @@ -1576,66 +2165,75 @@ class ActiveSupport::Cache::Store # # Other options will be handled by the specific cache store implementation. # - # source://activesupport//lib/active_support/cache.rb#502 + # source://activesupport//lib/active_support/cache.rb#660 def write(name, value, options = T.unsafe(nil)); end # Cache Storage API to write multiple values at once. # - # source://activesupport//lib/active_support/cache.rb#407 + # source://activesupport//lib/active_support/cache.rb#550 def write_multi(hash, options = T.unsafe(nil)); end private - # source://activesupport//lib/active_support/cache.rb#597 - def default_coder; end + # source://activesupport//lib/active_support/cache.rb#1005 + def _instrument(operation, multi: T.unsafe(nil), options: T.unsafe(nil), **payload, &block); end + + # source://activesupport//lib/active_support/cache.rb#762 + def default_serializer; end # Deletes an entry from the cache implementation. Subclasses must # implement this method. # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#674 + # source://activesupport//lib/active_support/cache.rb#848 def delete_entry(key, **options); end # Deletes multiples entries in the cache implementation. Subclasses MAY # implement this method. # - # source://activesupport//lib/active_support/cache.rb#680 + # source://activesupport//lib/active_support/cache.rb#854 def delete_multi_entries(entries, **options); end - # source://activesupport//lib/active_support/cache.rb#641 - def deserialize_entry(payload); end + # source://activesupport//lib/active_support/cache.rb#813 + def deserialize_entry(payload, **_arg1); end # Expands key to be a consistent string value. Invokes +cache_key+ if # object responds to +cache_key+. Otherwise, +to_param+ method will be # called. If the key is a Hash, then keys will be sorted alphabetically. # - # source://activesupport//lib/active_support/cache.rb#747 + # source://activesupport//lib/active_support/cache.rb#968 def expanded_key(key); end - # source://activesupport//lib/active_support/cache.rb#768 + # source://activesupport//lib/active_support/cache.rb#989 def expanded_version(key); end - # source://activesupport//lib/active_support/cache.rb#802 + # source://activesupport//lib/active_support/cache.rb#1043 def get_entry_value(entry, name, options); end - # source://activesupport//lib/active_support/cache.rb#786 + # source://activesupport//lib/active_support/cache.rb#1026 def handle_expired_entry(entry, key, options); end - # source://activesupport//lib/active_support/cache.rb#776 - def instrument(operation, key, options = T.unsafe(nil)); end + # source://activesupport//lib/active_support/cache.rb#888 + def handle_invalid_expires_in(message); end + + # source://activesupport//lib/active_support/cache.rb#997 + def instrument(operation, key, options = T.unsafe(nil), &block); end + + # source://activesupport//lib/active_support/cache.rb#1001 + def instrument_multi(operation, keys, options = T.unsafe(nil), &block); end # Adds the namespace defined in the options to a pattern designed to # match keys. Implementations that support delete_matched should call # this method to translate a pattern that matches names into one that # matches namespaced keys. # - # source://activesupport//lib/active_support/cache.rb#605 + # source://activesupport//lib/active_support/cache.rb#777 def key_matcher(pattern, options); end # Merges the default options with ones specific to a method call. # - # source://activesupport//lib/active_support/cache.rb#685 + # source://activesupport//lib/active_support/cache.rb#859 def merged_options(call_options); end # Prefix the key with a namespace string: @@ -1648,21 +2246,24 @@ class ActiveSupport::Cache::Store # namespace_key 'foo', namespace: -> { 'cache' } # # => 'cache:foo' # - # source://activesupport//lib/active_support/cache.rb#725 + # source://activesupport//lib/active_support/cache.rb#946 def namespace_key(key, options = T.unsafe(nil)); end - # Expands and namespaces the cache key. May be overridden by - # cache stores to do additional normalization. + # Expands and namespaces the cache key. + # Raises an exception when the key is +nil+ or an empty string. + # May be overridden by cache stores to do additional normalization. # - # source://activesupport//lib/active_support/cache.rb#712 + # @raise [ArgumentError] + # + # source://activesupport//lib/active_support/cache.rb#930 def normalize_key(key, options = T.unsafe(nil)); end # Normalize aliased options to their canonical form # - # source://activesupport//lib/active_support/cache.rb#699 + # source://activesupport//lib/active_support/cache.rb#899 def normalize_options(options); end - # source://activesupport//lib/active_support/cache.rb#764 + # source://activesupport//lib/active_support/cache.rb#985 def normalize_version(key, options = T.unsafe(nil)); end # Reads an entry from the cache implementation. Subclasses must implement @@ -1670,156 +2271,166 @@ class ActiveSupport::Cache::Store # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#622 + # source://activesupport//lib/active_support/cache.rb#794 def read_entry(key, **options); end # Reads multiple entries from the cache implementation. Subclasses MAY # implement this method. # - # source://activesupport//lib/active_support/cache.rb#647 + # source://activesupport//lib/active_support/cache.rb#821 def read_multi_entries(names, **options); end - # source://activesupport//lib/active_support/cache.rb#807 - def save_block_result_to_cache(name, options); end + # source://activesupport//lib/active_support/cache.rb#1048 + def save_block_result_to_cache(name, key, options); end - # source://activesupport//lib/active_support/cache.rb#632 + # source://activesupport//lib/active_support/cache.rb#804 def serialize_entry(entry, **options); end + # source://activesupport//lib/active_support/cache.rb#910 + def validate_options(options); end + # Writes an entry to the cache implementation. Subclasses must implement # this method. # # @raise [NotImplementedError] # - # source://activesupport//lib/active_support/cache.rb#628 + # source://activesupport//lib/active_support/cache.rb#800 def write_entry(key, entry, **options); end # Writes multiple entries to the cache implementation. Subclasses MAY # implement this method. # - # source://activesupport//lib/active_support/cache.rb#666 + # source://activesupport//lib/active_support/cache.rb#840 def write_multi_entries(hash, **options); end class << self - # source://activesupport//lib/active_support/cache.rb#176 + # source://activesupport//lib/active_support/cache.rb#189 def logger; end - # source://activesupport//lib/active_support/cache.rb#176 + # source://activesupport//lib/active_support/cache.rb#189 def logger=(val); end - private + # source://activesupport//lib/active_support/cache.rb#190 + def raise_on_invalid_cache_expiration_time; end # source://activesupport//lib/active_support/cache.rb#190 - def ensure_connection_pool_added!; end + def raise_on_invalid_cache_expiration_time=(val); end + + private - # source://activesupport//lib/active_support/cache.rb#183 + # source://activesupport//lib/active_support/cache.rb#200 def retrieve_pool_options(options); end end end -# source://activesupport//lib/active_support/cache.rb#34 +# source://activesupport//lib/active_support/cache.rb#51 module ActiveSupport::Cache::Strategy; end +# = Local \Cache \Strategy +# # Caches that implement LocalCache will be backed by an in-memory cache for the # duration of a block. Repeated calls to the cache for the same key will hit the # in-memory cache for faster access. # -# source://activesupport//lib/active_support/cache/strategy/local_cache.rb#11 +# source://activesupport//lib/active_support/cache/strategy/local_cache.rb#13 module ActiveSupport::Cache::Strategy::LocalCache - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#81 - def cleanup(**options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#85 + def cleanup(options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#75 - def clear(**options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#79 + def clear(options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#100 - def decrement(name, amount = T.unsafe(nil), **options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#108 + def decrement(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#87 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#91 def delete_matched(matcher, options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#93 - def increment(name, amount = T.unsafe(nil), **options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#97 + def increment(name, amount = T.unsafe(nil), options = T.unsafe(nil)); end # Middleware class can be inserted as a Rack handler to be local cache for the # duration of request. # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#69 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#73 def middleware; end # Use a local cache for the duration of block. # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#63 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#67 def with_local_cache(&block); end private - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#170 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#185 def bypass_local_cache(&block); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#147 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#162 def delete_entry(key, **_arg1); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#166 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#181 def local_cache; end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#162 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#177 def local_cache_key; end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#122 - def read_multi_entries(keys, **options); end + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#134 + def read_multi_entries(names, **options); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#108 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#120 def read_serialized_entry(key, raw: T.unsafe(nil), **options); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#174 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#189 def use_temporary_local_cache(temporary_cache); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#152 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#167 def write_cache_value(name, value, **options); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#138 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#153 def write_serialized_entry(key, payload, **_arg2); end end # Class for storing and registering the local caches. # -# source://activesupport//lib/active_support/cache/strategy/local_cache.rb#15 +# source://activesupport//lib/active_support/cache/strategy/local_cache.rb#17 module ActiveSupport::Cache::Strategy::LocalCache::LocalCacheRegistry extend ::ActiveSupport::Cache::Strategy::LocalCache::LocalCacheRegistry - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#18 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#20 def cache_for(local_cache_key); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#23 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#25 def set_cache_for(local_cache_key, value); end end +# = Local \Cache \Store +# # Simple memory backed cache. This cache is not thread safe and is intended only # for serving as a temporary memory cache for a single thread. # -# source://activesupport//lib/active_support/cache/strategy/local_cache.rb#31 +# source://activesupport//lib/active_support/cache/strategy/local_cache.rb#35 class ActiveSupport::Cache::Strategy::LocalCache::LocalStore # @return [LocalStore] a new instance of LocalStore # - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#32 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#36 def initialize; end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#36 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#40 def clear(options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#53 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#57 def delete_entry(key); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#57 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#61 def fetch_entry(key); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#40 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#44 def read_entry(key); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#44 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#48 def read_multi_entries(keys); end - # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#48 + # source://activesupport//lib/active_support/cache/strategy/local_cache.rb#52 def write_entry(key, entry); end end @@ -1850,27 +2461,70 @@ end # These options mean something to all cache implementations. Individual cache # implementations may support additional options. # -# source://activesupport//lib/active_support/cache.rb#25 +# source://activesupport//lib/active_support/cache.rb#26 ActiveSupport::Cache::UNIVERSAL_OPTIONS = T.let(T.unsafe(nil), Array) +# Enables the dynamic configuration of Cache entry options while ensuring +# that conflicting options are not both set. When a block is given to +# ActiveSupport::Cache::Store#fetch, the second argument will be an +# instance of +WriteOptions+. +# +# source://activesupport//lib/active_support/cache.rb#1064 +class ActiveSupport::Cache::WriteOptions + # @return [WriteOptions] a new instance of WriteOptions + # + # source://activesupport//lib/active_support/cache.rb#1065 + def initialize(options); end + + # source://activesupport//lib/active_support/cache.rb#1089 + def expires_at; end + + # Sets the Cache entry's +expires_at+ value. If an +expires_in+ option was + # previously set, this will unset it since +expires_at+ and +expires_in+ + # cannot both be set. + # + # source://activesupport//lib/active_support/cache.rb#1096 + def expires_at=(expires_at); end + + # source://activesupport//lib/active_support/cache.rb#1077 + def expires_in; end + + # Sets the Cache entry's +expires_in+ value. If an +expires_at+ option was + # previously set, this will unset it since +expires_in+ and +expires_at+ + # cannot both be set. + # + # source://activesupport//lib/active_support/cache.rb#1084 + def expires_in=(expires_in); end + + # source://activesupport//lib/active_support/cache.rb#1069 + def version; end + + # source://activesupport//lib/active_support/cache.rb#1073 + def version=(version); end +end + +# = Caching Key Generator +# # CachingKeyGenerator is a wrapper around KeyGenerator which allows users to avoid # re-executing the key generation process when it's called using the same +salt+ and # +key_size+. # -# source://activesupport//lib/active_support/key_generator.rb#47 +# source://activesupport//lib/active_support/key_generator.rb#55 class ActiveSupport::CachingKeyGenerator # @return [CachingKeyGenerator] a new instance of CachingKeyGenerator # - # source://activesupport//lib/active_support/key_generator.rb#48 + # source://activesupport//lib/active_support/key_generator.rb#56 def initialize(key_generator); end # Returns a derived key suitable for use. # - # source://activesupport//lib/active_support/key_generator.rb#54 + # source://activesupport//lib/active_support/key_generator.rb#62 def generate_key(*args); end end -# Callbacks are code hooks that are run at key points in an object's life cycle. +# = Active Support \Callbacks +# +# \Callbacks are code hooks that are run at key points in an object's life cycle. # The typical use case is to have a base class define a set of callbacks # relevant to the other functionality it supplies, so that subclasses can # install callbacks that enhance or modify the base functionality without @@ -1922,7 +2576,7 @@ end # - save # saved # -# source://activesupport//lib/active_support/callbacks.rb#63 +# source://activesupport//lib/active_support/callbacks.rb#65 module ActiveSupport::Callbacks extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -1954,8 +2608,8 @@ module ActiveSupport::Callbacks # smoothly through and into the supplied block, we want as little evidence # as possible that we were here. # - # source://activesupport//lib/active_support/callbacks.rb#95 - def run_callbacks(kind); end + # source://activesupport//lib/active_support/callbacks.rb#97 + def run_callbacks(kind, type = T.unsafe(nil)); end private @@ -1963,7 +2617,7 @@ module ActiveSupport::Callbacks # This can be overridden in ActiveSupport::Callbacks implementors in order # to provide better debugging/logging. # - # source://activesupport//lib/active_support/callbacks.rb#147 + # source://activesupport//lib/active_support/callbacks.rb#150 def halted_callback_hook(filter, name); end module GeneratedClassMethods @@ -1978,13 +2632,13 @@ module ActiveSupport::Callbacks end end -# source://activesupport//lib/active_support/callbacks.rb#71 +# source://activesupport//lib/active_support/callbacks.rb#73 ActiveSupport::Callbacks::CALLBACK_FILTER_TYPES = T.let(T.unsafe(nil), Array) # A future invocation of user-supplied code (either as a callback, # or a condition filter). # -# source://activesupport//lib/active_support/callbacks.rb#375 +# source://activesupport//lib/active_support/callbacks.rb#337 module ActiveSupport::Callbacks::CallTemplate class << self # Filters support: @@ -1996,69 +2650,69 @@ module ActiveSupport::Callbacks::CallTemplate # All of these objects are converted into a CallTemplate and handled # the same after this point. # - # source://activesupport//lib/active_support/callbacks.rb#533 + # source://activesupport//lib/active_support/callbacks.rb#495 def build(filter, callback); end end end -# source://activesupport//lib/active_support/callbacks.rb#434 +# source://activesupport//lib/active_support/callbacks.rb#396 class ActiveSupport::Callbacks::CallTemplate::InstanceExec0 # @return [InstanceExec0] a new instance of InstanceExec0 # - # source://activesupport//lib/active_support/callbacks.rb#435 + # source://activesupport//lib/active_support/callbacks.rb#397 def initialize(block); end - # source://activesupport//lib/active_support/callbacks.rb#439 + # source://activesupport//lib/active_support/callbacks.rb#401 def expand(target, value, block); end - # source://activesupport//lib/active_support/callbacks.rb#449 + # source://activesupport//lib/active_support/callbacks.rb#411 def inverted_lambda; end - # source://activesupport//lib/active_support/callbacks.rb#443 + # source://activesupport//lib/active_support/callbacks.rb#405 def make_lambda; end end -# source://activesupport//lib/active_support/callbacks.rb#456 +# source://activesupport//lib/active_support/callbacks.rb#418 class ActiveSupport::Callbacks::CallTemplate::InstanceExec1 # @return [InstanceExec1] a new instance of InstanceExec1 # - # source://activesupport//lib/active_support/callbacks.rb#457 + # source://activesupport//lib/active_support/callbacks.rb#419 def initialize(block); end - # source://activesupport//lib/active_support/callbacks.rb#461 + # source://activesupport//lib/active_support/callbacks.rb#423 def expand(target, value, block); end - # source://activesupport//lib/active_support/callbacks.rb#471 + # source://activesupport//lib/active_support/callbacks.rb#433 def inverted_lambda; end - # source://activesupport//lib/active_support/callbacks.rb#465 + # source://activesupport//lib/active_support/callbacks.rb#427 def make_lambda; end end -# source://activesupport//lib/active_support/callbacks.rb#478 +# source://activesupport//lib/active_support/callbacks.rb#440 class ActiveSupport::Callbacks::CallTemplate::InstanceExec2 # @return [InstanceExec2] a new instance of InstanceExec2 # - # source://activesupport//lib/active_support/callbacks.rb#479 + # source://activesupport//lib/active_support/callbacks.rb#441 def initialize(block); end # @raise [ArgumentError] # - # source://activesupport//lib/active_support/callbacks.rb#483 + # source://activesupport//lib/active_support/callbacks.rb#445 def expand(target, value, block); end - # source://activesupport//lib/active_support/callbacks.rb#495 + # source://activesupport//lib/active_support/callbacks.rb#457 def inverted_lambda; end - # source://activesupport//lib/active_support/callbacks.rb#488 + # source://activesupport//lib/active_support/callbacks.rb#450 def make_lambda; end end -# source://activesupport//lib/active_support/callbacks.rb#376 +# source://activesupport//lib/active_support/callbacks.rb#338 class ActiveSupport::Callbacks::CallTemplate::MethodCall # @return [MethodCall] a new instance of MethodCall # - # source://activesupport//lib/active_support/callbacks.rb#377 + # source://activesupport//lib/active_support/callbacks.rb#339 def initialize(method); end # Return the parts needed to make this call, with the given @@ -2075,199 +2729,202 @@ class ActiveSupport::Callbacks::CallTemplate::MethodCall # The actual invocation is left up to the caller to minimize # call stack pollution. # - # source://activesupport//lib/active_support/callbacks.rb#394 + # source://activesupport//lib/active_support/callbacks.rb#356 def expand(target, value, block); end - # source://activesupport//lib/active_support/callbacks.rb#404 + # source://activesupport//lib/active_support/callbacks.rb#366 def inverted_lambda; end - # source://activesupport//lib/active_support/callbacks.rb#398 + # source://activesupport//lib/active_support/callbacks.rb#360 def make_lambda; end end -# source://activesupport//lib/active_support/callbacks.rb#411 +# source://activesupport//lib/active_support/callbacks.rb#373 class ActiveSupport::Callbacks::CallTemplate::ObjectCall # @return [ObjectCall] a new instance of ObjectCall # - # source://activesupport//lib/active_support/callbacks.rb#412 + # source://activesupport//lib/active_support/callbacks.rb#374 def initialize(target, method); end - # source://activesupport//lib/active_support/callbacks.rb#417 + # source://activesupport//lib/active_support/callbacks.rb#379 def expand(target, value, block); end - # source://activesupport//lib/active_support/callbacks.rb#427 + # source://activesupport//lib/active_support/callbacks.rb#389 def inverted_lambda; end - # source://activesupport//lib/active_support/callbacks.rb#421 + # source://activesupport//lib/active_support/callbacks.rb#383 def make_lambda; end end -# source://activesupport//lib/active_support/callbacks.rb#503 +# source://activesupport//lib/active_support/callbacks.rb#465 class ActiveSupport::Callbacks::CallTemplate::ProcCall # @return [ProcCall] a new instance of ProcCall # - # source://activesupport//lib/active_support/callbacks.rb#504 + # source://activesupport//lib/active_support/callbacks.rb#466 def initialize(target); end - # source://activesupport//lib/active_support/callbacks.rb#508 + # source://activesupport//lib/active_support/callbacks.rb#470 def expand(target, value, block); end - # source://activesupport//lib/active_support/callbacks.rb#518 + # source://activesupport//lib/active_support/callbacks.rb#480 def inverted_lambda; end - # source://activesupport//lib/active_support/callbacks.rb#512 + # source://activesupport//lib/active_support/callbacks.rb#474 def make_lambda; end end -# source://activesupport//lib/active_support/callbacks.rb#280 +# source://activesupport//lib/active_support/callbacks.rb#231 class ActiveSupport::Callbacks::Callback # @return [Callback] a new instance of Callback # - # source://activesupport//lib/active_support/callbacks.rb#295 + # source://activesupport//lib/active_support/callbacks.rb#246 def initialize(name, filter, kind, options, chain_config); end # Wraps code with filter # - # source://activesupport//lib/active_support/callbacks.rb#330 + # source://activesupport//lib/active_support/callbacks.rb#300 def apply(callback_sequence); end # Returns the value of attribute chain_config. # - # source://activesupport//lib/active_support/callbacks.rb#293 + # source://activesupport//lib/active_support/callbacks.rb#244 def chain_config; end - # source://activesupport//lib/active_support/callbacks.rb#344 + # source://activesupport//lib/active_support/callbacks.rb#282 + def compiled; end + + # source://activesupport//lib/active_support/callbacks.rb#304 def current_scopes; end # @return [Boolean] # - # source://activesupport//lib/active_support/callbacks.rb#320 + # source://activesupport//lib/active_support/callbacks.rb#273 def duplicates?(other); end # Returns the value of attribute filter. # - # source://activesupport//lib/active_support/callbacks.rb#293 + # source://activesupport//lib/active_support/callbacks.rb#244 def filter; end # Returns the value of attribute kind. # - # source://activesupport//lib/active_support/callbacks.rb#292 + # source://activesupport//lib/active_support/callbacks.rb#243 def kind; end # Sets the attribute kind # # @param value the value to set the attribute kind to. # - # source://activesupport//lib/active_support/callbacks.rb#292 + # source://activesupport//lib/active_support/callbacks.rb#243 def kind=(_arg0); end # @return [Boolean] # - # source://activesupport//lib/active_support/callbacks.rb#316 + # source://activesupport//lib/active_support/callbacks.rb#269 def matches?(_kind, _filter); end - # source://activesupport//lib/active_support/callbacks.rb#304 + # source://activesupport//lib/active_support/callbacks.rb#257 def merge_conditional_options(chain, if_option:, unless_option:); end # Returns the value of attribute name. # - # source://activesupport//lib/active_support/callbacks.rb#292 + # source://activesupport//lib/active_support/callbacks.rb#243 def name; end # Sets the attribute name # # @param value the value to set the attribute name to. # - # source://activesupport//lib/active_support/callbacks.rb#292 + # source://activesupport//lib/active_support/callbacks.rb#243 def name=(_arg0); end private - # source://activesupport//lib/active_support/callbacks.rb#352 + # source://activesupport//lib/active_support/callbacks.rb#312 def check_conditionals(conditionals); end - # source://activesupport//lib/active_support/callbacks.rb#367 + # source://activesupport//lib/active_support/callbacks.rb#327 def conditions_lambdas; end class << self - # source://activesupport//lib/active_support/callbacks.rb#281 + # source://activesupport//lib/active_support/callbacks.rb#232 def build(chain, filter, kind, options); end end end -# source://activesupport//lib/active_support/callbacks.rb#349 +# source://activesupport//lib/active_support/callbacks.rb#309 ActiveSupport::Callbacks::Callback::EMPTY_ARRAY = T.let(T.unsafe(nil), Array) -# source://activesupport//lib/active_support/callbacks.rb#603 +# source://activesupport//lib/active_support/callbacks.rb#567 class ActiveSupport::Callbacks::CallbackChain include ::Enumerable # @return [CallbackChain] a new instance of CallbackChain # - # source://activesupport//lib/active_support/callbacks.rb#608 + # source://activesupport//lib/active_support/callbacks.rb#572 def initialize(name, config); end - # source://activesupport//lib/active_support/callbacks.rb#654 + # source://activesupport//lib/active_support/callbacks.rb#632 def append(*callbacks); end - # source://activesupport//lib/active_support/callbacks.rb#633 + # source://activesupport//lib/active_support/callbacks.rb#600 def clear; end - # source://activesupport//lib/active_support/callbacks.rb#645 - def compile; end + # source://activesupport//lib/active_support/callbacks.rb#614 + def compile(type); end # Returns the value of attribute config. # - # source://activesupport//lib/active_support/callbacks.rb#606 + # source://activesupport//lib/active_support/callbacks.rb#570 def config; end - # source://activesupport//lib/active_support/callbacks.rb#628 + # source://activesupport//lib/active_support/callbacks.rb#594 def delete(o); end - # source://activesupport//lib/active_support/callbacks.rb#619 + # source://activesupport//lib/active_support/callbacks.rb#584 def each(&block); end # @return [Boolean] # - # source://activesupport//lib/active_support/callbacks.rb#621 + # source://activesupport//lib/active_support/callbacks.rb#586 def empty?; end - # source://activesupport//lib/active_support/callbacks.rb#620 + # source://activesupport//lib/active_support/callbacks.rb#585 def index(o); end - # source://activesupport//lib/active_support/callbacks.rb#623 + # source://activesupport//lib/active_support/callbacks.rb#588 def insert(index, o); end # Returns the value of attribute name. # - # source://activesupport//lib/active_support/callbacks.rb#606 + # source://activesupport//lib/active_support/callbacks.rb#570 def name; end - # source://activesupport//lib/active_support/callbacks.rb#658 + # source://activesupport//lib/active_support/callbacks.rb#636 def prepend(*callbacks); end protected # Returns the value of attribute chain. # - # source://activesupport//lib/active_support/callbacks.rb#663 + # source://activesupport//lib/active_support/callbacks.rb#641 def chain; end private - # source://activesupport//lib/active_support/callbacks.rb#666 + # source://activesupport//lib/active_support/callbacks.rb#644 def append_one(callback); end - # source://activesupport//lib/active_support/callbacks.rb#683 + # source://activesupport//lib/active_support/callbacks.rb#664 def default_terminator; end - # source://activesupport//lib/active_support/callbacks.rb#639 + # source://activesupport//lib/active_support/callbacks.rb#607 def initialize_copy(other); end - # source://activesupport//lib/active_support/callbacks.rb#672 + # source://activesupport//lib/active_support/callbacks.rb#651 def prepend_one(callback); end - # source://activesupport//lib/active_support/callbacks.rb#678 + # source://activesupport//lib/active_support/callbacks.rb#658 def remove_duplicates(callback); end end @@ -2275,53 +2932,53 @@ end # chaining them with nested lambda calls, see: # https://github.com/rails/rails/issues/18011 # -# source://activesupport//lib/active_support/callbacks.rb#556 +# source://activesupport//lib/active_support/callbacks.rb#518 class ActiveSupport::Callbacks::CallbackSequence # @return [CallbackSequence] a new instance of CallbackSequence # - # source://activesupport//lib/active_support/callbacks.rb#557 + # source://activesupport//lib/active_support/callbacks.rb#519 def initialize(nested = T.unsafe(nil), call_template = T.unsafe(nil), user_conditions = T.unsafe(nil)); end - # source://activesupport//lib/active_support/callbacks.rb#571 - def after(&after); end + # source://activesupport//lib/active_support/callbacks.rb#534 + def after(after); end - # source://activesupport//lib/active_support/callbacks.rb#576 + # source://activesupport//lib/active_support/callbacks.rb#540 def around(call_template, user_conditions); end - # source://activesupport//lib/active_support/callbacks.rb#566 - def before(&before); end + # source://activesupport//lib/active_support/callbacks.rb#528 + def before(before); end - # source://activesupport//lib/active_support/callbacks.rb#590 + # source://activesupport//lib/active_support/callbacks.rb#554 def expand_call_template(arg, block); end # @return [Boolean] # - # source://activesupport//lib/active_support/callbacks.rb#586 + # source://activesupport//lib/active_support/callbacks.rb#550 def final?; end - # source://activesupport//lib/active_support/callbacks.rb#598 + # source://activesupport//lib/active_support/callbacks.rb#562 def invoke_after(arg); end - # source://activesupport//lib/active_support/callbacks.rb#594 + # source://activesupport//lib/active_support/callbacks.rb#558 def invoke_before(arg); end # Returns the value of attribute nested. # - # source://activesupport//lib/active_support/callbacks.rb#584 + # source://activesupport//lib/active_support/callbacks.rb#548 def nested; end # @return [Boolean] # - # source://activesupport//lib/active_support/callbacks.rb#580 + # source://activesupport//lib/active_support/callbacks.rb#544 def skip?(arg); end end -# source://activesupport//lib/active_support/callbacks.rb#695 +# source://activesupport//lib/active_support/callbacks.rb#676 module ActiveSupport::Callbacks::ClassMethods # This is used internally to append, prepend and skip callbacks to the # CallbackChain. # - # source://activesupport//lib/active_support/callbacks.rb#705 + # source://activesupport//lib/active_support/callbacks.rb#686 def __update_callbacks(name); end # Define sets of events in the object life cycle that support callbacks. @@ -2401,17 +3058,17 @@ module ActiveSupport::Callbacks::ClassMethods # !, ? or =. # # Calling +define_callbacks+ multiple times with the same +names+ will - # overwrite previous callbacks registered with +set_callback+. + # overwrite previous callbacks registered with #set_callback. # - # source://activesupport//lib/active_support/callbacks.rb#917 + # source://activesupport//lib/active_support/callbacks.rb#901 def define_callbacks(*names); end - # source://activesupport//lib/active_support/callbacks.rb#696 + # source://activesupport//lib/active_support/callbacks.rb#677 def normalize_callback_params(filters, block); end # Remove all set callbacks for the given event. # - # source://activesupport//lib/active_support/callbacks.rb#827 + # source://activesupport//lib/active_support/callbacks.rb#811 def reset_callbacks(name); end # Install a callback for the given event. @@ -2428,7 +3085,7 @@ module ActiveSupport::Callbacks::ClassMethods # # The callback can be specified as a symbol naming an instance method; as a # proc, lambda, or block; or as an object that responds to a certain method - # determined by the :scope argument to +define_callbacks+. + # determined by the :scope argument to #define_callbacks. # # If a proc, lambda, or block is given, its body is evaluated in the context # of the current object. It can also optionally accept the current object as @@ -2459,13 +3116,16 @@ module ActiveSupport::Callbacks::ClassMethods # * :prepend - If +true+, the callback will be prepended to the # existing chain rather than appended. # - # source://activesupport//lib/active_support/callbacks.rb#756 + # source://activesupport//lib/active_support/callbacks.rb#737 def set_callback(name, *filter_list, &block); end - # Skip a previously set callback. Like +set_callback+, :if or + # Skip a previously set callback. Like #set_callback, :if or # :unless options may be passed in order to control when the # callback is skipped. # + # Note: this example uses +PersonRecord+ and +#saving_message+, which you + # can see defined here[rdoc-ref:ActiveSupport::Callbacks] + # # class Writer < PersonRecord # attr_accessor :age # skip_callback :save, :before, :saving_message, if: -> { age > 18 } @@ -2495,74 +3155,115 @@ module ActiveSupport::Callbacks::ClassMethods # An ArgumentError will be raised if the callback has not # already been set (unless the :raise option is set to false). # - # source://activesupport//lib/active_support/callbacks.rb#802 + # source://activesupport//lib/active_support/callbacks.rb#786 def skip_callback(name, *filter_list, &block); end protected - # source://activesupport//lib/active_support/callbacks.rb#948 + # source://activesupport//lib/active_support/callbacks.rb#932 def get_callbacks(name); end - # source://activesupport//lib/active_support/callbacks.rb#952 + # source://activesupport//lib/active_support/callbacks.rb#936 def set_callbacks(name, callbacks); end end -# source://activesupport//lib/active_support/callbacks.rb#150 +# source://activesupport//lib/active_support/callbacks.rb#153 module ActiveSupport::Callbacks::Conditionals; end -# source://activesupport//lib/active_support/callbacks.rb#151 +# source://activesupport//lib/active_support/callbacks.rb#154 class ActiveSupport::Callbacks::Conditionals::Value # @return [Value] a new instance of Value # - # source://activesupport//lib/active_support/callbacks.rb#152 + # source://activesupport//lib/active_support/callbacks.rb#155 def initialize(&block); end - # source://activesupport//lib/active_support/callbacks.rb#155 + # source://activesupport//lib/active_support/callbacks.rb#158 def call(target, value); end end -# source://activesupport//lib/active_support/callbacks.rb#159 +# source://activesupport//lib/active_support/callbacks.rb#162 module ActiveSupport::Callbacks::Filters; end -# source://activesupport//lib/active_support/callbacks.rb#212 +# source://activesupport//lib/active_support/callbacks.rb#194 class ActiveSupport::Callbacks::Filters::After - class << self - # source://activesupport//lib/active_support/callbacks.rb#213 - def build(callback_sequence, user_callback, user_conditions, chain_config); end + # @return [After] a new instance of After + # + # source://activesupport//lib/active_support/callbacks.rb#196 + def initialize(user_callback, user_conditions, chain_config); end - private + # source://activesupport//lib/active_support/callbacks.rb#214 + def apply(callback_sequence); end - # source://activesupport//lib/active_support/callbacks.rb#255 - def conditional(callback_sequence, user_callback, user_conditions); end + # source://activesupport//lib/active_support/callbacks.rb#202 + def call(env); end - # source://activesupport//lib/active_support/callbacks.rb#244 - def halting(callback_sequence, user_callback); end + # Returns the value of attribute halting. + # + # source://activesupport//lib/active_support/callbacks.rb#195 + def halting; end - # source://activesupport//lib/active_support/callbacks.rb#229 - def halting_and_conditional(callback_sequence, user_callback, user_conditions); end + # Returns the value of attribute user_callback. + # + # source://activesupport//lib/active_support/callbacks.rb#195 + def user_callback; end - # source://activesupport//lib/active_support/callbacks.rb#269 - def simple(callback_sequence, user_callback); end - end + # Returns the value of attribute user_conditions. + # + # source://activesupport//lib/active_support/callbacks.rb#195 + def user_conditions; end end -# source://activesupport//lib/active_support/callbacks.rb#162 +# source://activesupport//lib/active_support/callbacks.rb#219 +class ActiveSupport::Callbacks::Filters::Around + # @return [Around] a new instance of Around + # + # source://activesupport//lib/active_support/callbacks.rb#220 + def initialize(user_callback, user_conditions); end + + # source://activesupport//lib/active_support/callbacks.rb#225 + def apply(callback_sequence); end +end + +# source://activesupport//lib/active_support/callbacks.rb#165 class ActiveSupport::Callbacks::Filters::Before - class << self - # source://activesupport//lib/active_support/callbacks.rb#163 - def build(callback_sequence, user_callback, user_conditions, chain_config, filter, name); end + # @return [Before] a new instance of Before + # + # source://activesupport//lib/active_support/callbacks.rb#166 + def initialize(user_callback, user_conditions, chain_config, filter, name); end - private + # source://activesupport//lib/active_support/callbacks.rb#189 + def apply(callback_sequence); end - # source://activesupport//lib/active_support/callbacks.rb#192 - def halting(callback_sequence, user_callback, halted_lambda, filter, name); end + # source://activesupport//lib/active_support/callbacks.rb#173 + def call(env); end - # source://activesupport//lib/active_support/callbacks.rb#173 - def halting_and_conditional(callback_sequence, user_callback, user_conditions, halted_lambda, filter, name); end - end + # Returns the value of attribute filter. + # + # source://activesupport//lib/active_support/callbacks.rb#171 + def filter; end + + # Returns the value of attribute halted_lambda. + # + # source://activesupport//lib/active_support/callbacks.rb#171 + def halted_lambda; end + + # Returns the value of attribute name. + # + # source://activesupport//lib/active_support/callbacks.rb#171 + def name; end + + # Returns the value of attribute user_callback. + # + # source://activesupport//lib/active_support/callbacks.rb#171 + def user_callback; end + + # Returns the value of attribute user_conditions. + # + # source://activesupport//lib/active_support/callbacks.rb#171 + def user_conditions; end end -# source://activesupport//lib/active_support/callbacks.rb#160 +# source://activesupport//lib/active_support/callbacks.rb#163 class ActiveSupport::Callbacks::Filters::Environment < ::Struct # Returns the value of attribute halted # @@ -2610,17 +3311,17 @@ end class ActiveSupport::CodeGenerator # @return [CodeGenerator] a new instance of CodeGenerator # - # source://activesupport//lib/active_support/code_generator.rb#48 + # source://activesupport//lib/active_support/code_generator.rb#53 def initialize(owner, path, line); end - # source://activesupport//lib/active_support/code_generator.rb#55 - def define_cached_method(name, namespace:, as: T.unsafe(nil), &block); end + # source://activesupport//lib/active_support/code_generator.rb#60 + def define_cached_method(canonical_name, namespace:, as: T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/code_generator.rb#59 + # source://activesupport//lib/active_support/code_generator.rb#64 def execute; end class << self - # source://activesupport//lib/active_support/code_generator.rb#36 + # source://activesupport//lib/active_support/code_generator.rb#41 def batch(owner, path, line); end end end @@ -2632,11 +3333,11 @@ class ActiveSupport::CodeGenerator::MethodSet # source://activesupport//lib/active_support/code_generator.rb#8 def initialize(namespace); end - # source://activesupport//lib/active_support/code_generator.rb#25 + # source://activesupport//lib/active_support/code_generator.rb#28 def apply(owner, path, line); end - # source://activesupport//lib/active_support/code_generator.rb#14 - def define_cached_method(name, as: T.unsafe(nil)); end + # source://activesupport//lib/active_support/code_generator.rb#15 + def define_cached_method(canonical_name, as: T.unsafe(nil)); end end # source://activesupport//lib/active_support/code_generator.rb#6 @@ -2677,6 +3378,8 @@ module ActiveSupport::CompareWithRange def include?(value); end end +# = Active Support \Concern +# # A typical module looks like this: # # module M @@ -2692,7 +3395,7 @@ end # end # end # -# By using ActiveSupport::Concern the above module could instead be +# By using +ActiveSupport::Concern+ the above module could instead be # written as: # # require "active_support/concern" @@ -2749,7 +3452,7 @@ end # end # # Unfortunately this won't work, since when +Foo+ is included, its base -# is the +Bar+ module, not the +Host+ class. With ActiveSupport::Concern, +# is the +Bar+ module, not the +Host+ class. With +ActiveSupport::Concern+, # module dependencies are properly resolved: # # require "active_support/concern" @@ -2784,9 +3487,9 @@ end # # prepend is also used for any dependencies. # -# source://activesupport//lib/active_support/concern.rb#110 +# source://activesupport//lib/active_support/concern.rb#112 module ActiveSupport::Concern - # source://activesupport//lib/active_support/concern.rb#127 + # source://activesupport//lib/active_support/concern.rb#129 def append_features(base); end # Define class methods from given block. @@ -2810,45 +3513,45 @@ module ActiveSupport::Concern # Buzz.foo # => "foo" # Buzz.bar # => private method 'bar' called for Buzz:Class(NoMethodError) # - # source://activesupport//lib/active_support/concern.rb#207 + # source://activesupport//lib/active_support/concern.rb#209 def class_methods(&class_methods_module_definition); end # Evaluate given block in context of base class, # so that you can write class macros here. # When you define more than one +included+ block, it raises an exception. # - # source://activesupport//lib/active_support/concern.rb#156 + # source://activesupport//lib/active_support/concern.rb#158 def included(base = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/concern.rb#140 + # source://activesupport//lib/active_support/concern.rb#142 def prepend_features(base); end # Evaluate given block in context of base class, # so that you can write class macros here. # When you define more than one +prepended+ block, it raises an exception. # - # source://activesupport//lib/active_support/concern.rb#173 + # source://activesupport//lib/active_support/concern.rb#175 def prepended(base = T.unsafe(nil), &block); end class << self - # source://activesupport//lib/active_support/concern.rb#123 + # source://activesupport//lib/active_support/concern.rb#125 def extended(base); end end end -# source://activesupport//lib/active_support/concern.rb#111 +# source://activesupport//lib/active_support/concern.rb#113 class ActiveSupport::Concern::MultipleIncludedBlocks < ::StandardError # @return [MultipleIncludedBlocks] a new instance of MultipleIncludedBlocks # - # source://activesupport//lib/active_support/concern.rb#112 + # source://activesupport//lib/active_support/concern.rb#114 def initialize; end end -# source://activesupport//lib/active_support/concern.rb#117 +# source://activesupport//lib/active_support/concern.rb#119 class ActiveSupport::Concern::MultiplePrependBlocks < ::StandardError # @return [MultiplePrependBlocks] a new instance of MultiplePrependBlocks # - # source://activesupport//lib/active_support/concern.rb#118 + # source://activesupport//lib/active_support/concern.rb#120 def initialize; end end @@ -2858,22 +3561,35 @@ module ActiveSupport::Concurrency; end # A monitor that will permit dependency loading while blocked waiting for # the lock. # -# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#9 +# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#32 class ActiveSupport::Concurrency::LoadInterlockAwareMonitor < ::Monitor + include ::ActiveSupport::Concurrency::LoadInterlockAwareMonitorMixin +end + +# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#7 +module ActiveSupport::Concurrency::LoadInterlockAwareMonitorMixin # Enters an exclusive section, but allows dependency loading while blocked # - # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#15 + # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#13 def mon_enter; end - # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#20 + # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#18 def synchronize(&block); end end -# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#11 -ActiveSupport::Concurrency::LoadInterlockAwareMonitor::EXCEPTION_IMMEDIATE = T.let(T.unsafe(nil), Hash) +# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#9 +ActiveSupport::Concurrency::LoadInterlockAwareMonitorMixin::EXCEPTION_IMMEDIATE = T.let(T.unsafe(nil), Hash) + +# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#8 +ActiveSupport::Concurrency::LoadInterlockAwareMonitorMixin::EXCEPTION_NEVER = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#10 -ActiveSupport::Concurrency::LoadInterlockAwareMonitor::EXCEPTION_NEVER = T.let(T.unsafe(nil), Hash) +# source://activesupport//lib/active_support/concurrency/null_lock.rb#5 +module ActiveSupport::Concurrency::NullLock + extend ::ActiveSupport::Concurrency::NullLock + + # source://activesupport//lib/active_support/concurrency/null_lock.rb#8 + def synchronize; end +end # A share/exclusive lock, otherwise known as a read/write lock. # @@ -2970,10 +3686,33 @@ class ActiveSupport::Concurrency::ShareLock def wait_for(method, &block); end end +# source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#36 +class ActiveSupport::Concurrency::ThreadLoadInterlockAwareMonitor + include ::ActiveSupport::Concurrency::LoadInterlockAwareMonitorMixin + + # @return [ThreadLoadInterlockAwareMonitor] a new instance of ThreadLoadInterlockAwareMonitor + # + # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#39 + def initialize; end + + # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#13 + def mon_enter; end + + private + + # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#60 + def mon_exit; end + + # source://activesupport//lib/active_support/concurrency/load_interlock_aware_monitor.rb#46 + def mon_try_enter; end +end + +# = Active Support \Configurable +# # Configurable provides a config method to store and retrieve # configuration options as an OrderedOptions. # -# source://activesupport//lib/active_support/configurable.rb#9 +# source://activesupport//lib/active_support/configurable.rb#11 module ActiveSupport::Configurable extend ::ActiveSupport::Concern @@ -2995,18 +3734,18 @@ module ActiveSupport::Configurable # user.config.allowed_access # => true # user.config.level # => 1 # - # source://activesupport//lib/active_support/configurable.rb#145 + # source://activesupport//lib/active_support/configurable.rb#155 def config; end end -# source://activesupport//lib/active_support/configurable.rb#27 +# source://activesupport//lib/active_support/configurable.rb#29 module ActiveSupport::Configurable::ClassMethods - # source://activesupport//lib/active_support/configurable.rb#28 + # source://activesupport//lib/active_support/configurable.rb#30 def config; end # @yield [config] # - # source://activesupport//lib/active_support/configurable.rb#37 + # source://activesupport//lib/active_support/configurable.rb#39 def configure; end private @@ -3080,19 +3819,22 @@ module ActiveSupport::Configurable::ClassMethods # User.allowed_access # => false # User.hair_colors # => [:brown, :black, :blonde, :red] # - # source://activesupport//lib/active_support/configurable.rb#109 + # source://activesupport//lib/active_support/configurable.rb#111 def config_accessor(*names, instance_reader: T.unsafe(nil), instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil)); end + + # source://activesupport//lib/active_support/configurable.rb#132 + def inherited(subclass); end end -# source://activesupport//lib/active_support/configurable.rb#12 +# source://activesupport//lib/active_support/configurable.rb#14 class ActiveSupport::Configurable::Configuration < ::ActiveSupport::InheritableOptions - # source://activesupport//lib/active_support/configurable.rb#13 + # source://activesupport//lib/active_support/configurable.rb#15 def compile_methods!; end class << self # Compiles reader methods so we don't have to go through method_missing. # - # source://activesupport//lib/active_support/configurable.rb#18 + # source://activesupport//lib/active_support/configurable.rb#20 def compile_methods!(keys); end end end @@ -3130,31 +3872,79 @@ end # source://activesupport//lib/active_support/configuration_file.rb#10 class ActiveSupport::ConfigurationFile::FormatError < ::StandardError; end -# Abstract super class that provides a thread-isolated attributes singleton, which resets automatically -# before and after each request. This allows you to keep all the per-request attributes easily -# available to the whole system. -# -# The following full app-like example demonstrates how to use a Current class to -# facilitate easy access to the global, per-request attributes without passing them deeply -# around everywhere: -# -# # app/models/current.rb -# class Current < ActiveSupport::CurrentAttributes -# attribute :account, :user -# attribute :request_id, :user_agent, :ip_address -# -# resets { Time.zone = nil } -# -# def user=(user) -# super -# self.account = user.account -# Time.zone = user.time_zone -# end -# end -# -# # app/controllers/concerns/authentication.rb -# module Authentication -# extend ActiveSupport::Concern +# source://activesupport//lib/active_support/core_ext/erb/util.rb#6 +module ActiveSupport::CoreExt; end + +# source://activesupport//lib/active_support/core_ext/erb/util.rb#7 +module ActiveSupport::CoreExt::ERBUtil + # A utility method for escaping HTML tag characters. + # This method is also aliased as h. + # + # puts html_escape('is a > 0 & a < 10?') + # # => is a > 0 & a < 10? + # + # source://activesupport//lib/active_support/core_ext/erb/util.rb#25 + def h(s); end + + # A utility method for escaping HTML tag characters. + # This method is also aliased as h. + # + # puts html_escape('is a > 0 & a < 10?') + # # => is a > 0 & a < 10? + # + # source://activesupport//lib/active_support/core_ext/erb/util.rb#25 + def html_escape(s); end + + # HTML escapes strings but doesn't wrap them with an ActiveSupport::SafeBuffer. + # This method is not for public consumption! Seriously! + # + # source://activesupport//lib/active_support/core_ext/erb/util.rb#10 + def unwrapped_html_escape(s); end +end + +# source://activesupport//lib/active_support/core_ext/erb/util.rb#31 +module ActiveSupport::CoreExt::ERBUtilPrivate + include ::ActiveSupport::CoreExt::ERBUtil + + private + + # source://activesupport//lib/active_support/core_ext/erb/util.rb#25 + def h(s); end + + # source://activesupport//lib/active_support/core_ext/erb/util.rb#25 + def html_escape(s); end + + # source://activesupport//lib/active_support/core_ext/erb/util.rb#10 + def unwrapped_html_escape(s); end +end + +# = Current Attributes +# +# Abstract super class that provides a thread-isolated attributes singleton, which resets automatically +# before and after each request. This allows you to keep all the per-request attributes easily +# available to the whole system. +# +# The following full app-like example demonstrates how to use a Current class to +# facilitate easy access to the global, per-request attributes without passing them deeply +# around everywhere: +# +# # app/models/current.rb +# class Current < ActiveSupport::CurrentAttributes +# attribute :account, :user +# attribute :request_id, :user_agent, :ip_address +# +# resets { Time.zone = nil } +# +# def user=(user) +# super +# self.account = user.account +# Time.zone = user.time_zone +# end +# end +# +# # app/controllers/concerns/authentication.rb +# module Authentication +# extend ActiveSupport::Concern # # included do # before_action :authenticate @@ -3212,7 +4002,7 @@ class ActiveSupport::ConfigurationFile::FormatError < ::StandardError; end # The attributes stuck in Current should be used by more or less all actions on all requests. If you start # sticking controller-specific attributes in there, you're going to create a mess. # -# source://activesupport//lib/active_support/current_attributes.rb#89 +# source://activesupport//lib/active_support/current_attributes.rb#92 class ActiveSupport::CurrentAttributes include ::ActiveSupport::Callbacks extend ::ActiveSupport::Callbacks::ClassMethods @@ -3220,36 +4010,42 @@ class ActiveSupport::CurrentAttributes # @return [CurrentAttributes] a new instance of CurrentAttributes # - # source://activesupport//lib/active_support/current_attributes.rb#188 + # source://activesupport//lib/active_support/current_attributes.rb#196 def initialize; end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport//lib/active_support/callbacks.rb#940 + # source://activesupport//lib/active_support/callbacks.rb#924 def _reset_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#928 + # source://activesupport//lib/active_support/callbacks.rb#912 def _run_reset_callbacks(&block); end # Returns the value of attribute attributes. # - # source://activesupport//lib/active_support/current_attributes.rb#186 + # source://activesupport//lib/active_support/current_attributes.rb#194 def attributes; end # Sets the attribute attributes # # @param value the value to set the attribute attributes to. # - # source://activesupport//lib/active_support/current_attributes.rb#186 + # source://activesupport//lib/active_support/current_attributes.rb#194 def attributes=(_arg0); end + # source://activesupport//lib/active_support/current_attributes.rb#192 + def defaults; end + + # source://activesupport//lib/active_support/current_attributes.rb#192 + def defaults?; end + # Reset all attributes. Should be called before and after actions, when used as a per-request singleton. # - # source://activesupport//lib/active_support/current_attributes.rb#211 + # source://activesupport//lib/active_support/current_attributes.rb#215 def reset; end # Expose one or more attributes within a block. Old values are returned after the block concludes. @@ -3263,91 +4059,185 @@ class ActiveSupport::CurrentAttributes # end # end # - # source://activesupport//lib/active_support/current_attributes.rb#202 - def set(set_attributes); end + # source://activesupport//lib/active_support/current_attributes.rb#210 + def set(attributes, &block); end private - # source://activesupport//lib/active_support/current_attributes.rb#218 - def assign_attributes(new_attributes); end - # source://activesupport//lib/active_support/current_attributes.rb#222 - def compute_attributes(keys); end + def resolve_defaults; end class << self - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport//lib/active_support/callbacks.rb#932 + # source://activesupport//lib/active_support/callbacks.rb#916 def _reset_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#936 + # source://activesupport//lib/active_support/callbacks.rb#920 def _reset_callbacks=(value); end - # Calls this block after #reset is called on the instance. Used for resetting external collaborators, like Time.zone. + # Calls this callback after #reset is called on the instance. Used for resetting external collaborators, like Time.zone. # - # source://activesupport//lib/active_support/current_attributes.rb#142 - def after_reset(&block); end + # source://activesupport//lib/active_support/current_attributes.rb#147 + def after_reset(*methods, &block); end # Declares one or more attributes that will be given both class and instance accessor methods. # - # source://activesupport//lib/active_support/current_attributes.rb#100 - def attribute(*names); end + # ==== Options + # + # * :default - The default value for the attributes. If the value + # is a proc or lambda, it will be called whenever an instance is + # constructed. Otherwise, the value will be duplicated with +#dup+. + # Default values are re-assigned when the attributes are reset. + # + # source://activesupport//lib/active_support/current_attributes.rb#112 + def attribute(*names, default: T.unsafe(nil)); end - # Calls this block before #reset is called on the instance. Used for resetting external collaborators that depend on current values. + # Calls this callback before #reset is called on the instance. Used for resetting external collaborators that depend on current values. # - # source://activesupport//lib/active_support/current_attributes.rb#137 - def before_reset(&block); end + # source://activesupport//lib/active_support/current_attributes.rb#142 + def before_reset(*methods, &block); end - # source://activesupport//lib/active_support/current_attributes.rb#153 + # source://activesupport//lib/active_support/current_attributes.rb#158 def clear_all; end + # source://activesupport//lib/active_support/current_attributes.rb#192 + def defaults; end + + # source://activesupport//lib/active_support/current_attributes.rb#192 + def defaults=(value); end + + # source://activesupport//lib/active_support/current_attributes.rb#192 + def defaults?; end + # Returns singleton instance for this class in this thread. If none exists, one is created. # - # source://activesupport//lib/active_support/current_attributes.rb#95 + # source://activesupport//lib/active_support/current_attributes.rb#100 def instance; end - # source://activesupport//lib/active_support/current_attributes.rb#147 + # source://activesupport//lib/active_support/current_attributes.rb#152 def reset(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/current_attributes.rb#149 + # source://activesupport//lib/active_support/current_attributes.rb#154 def reset_all; end - # Calls this block after #reset is called on the instance. Used for resetting external collaborators, like Time.zone. + # Calls this callback after #reset is called on the instance. Used for resetting external collaborators, like Time.zone. # - # source://activesupport//lib/active_support/current_attributes.rb#142 - def resets(&block); end - # source://activesupport//lib/active_support/current_attributes.rb#147 + def resets(*methods, &block); end + + # source://activesupport//lib/active_support/current_attributes.rb#152 def set(*_arg0, **_arg1, &_arg2); end private - # source://activesupport//lib/active_support/current_attributes.rb#163 + # source://activesupport//lib/active_support/current_attributes.rb#168 def current_instances; end - # source://activesupport//lib/active_support/current_attributes.rb#167 + # source://activesupport//lib/active_support/current_attributes.rb#172 def current_instances_key; end - # source://activesupport//lib/active_support/current_attributes.rb#159 + # source://activesupport//lib/active_support/current_attributes.rb#164 def generated_attribute_methods; end - # source://activesupport//lib/active_support/current_attributes.rb#171 - def method_missing(name, *args, **_arg2, &block); end + # @private + # + # source://activesupport//lib/active_support/current_attributes.rb#184 + def method_added(name); end + + # source://activesupport//lib/active_support/current_attributes.rb#176 + def method_missing(name, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://activesupport//lib/active_support/current_attributes.rb#181 + # source://activesupport//lib/active_support/current_attributes.rb#180 def respond_to_missing?(name, _); end end end +# source://activesupport//lib/active_support/current_attributes.rb#96 +ActiveSupport::CurrentAttributes::INVALID_ATTRIBUTE_NAMES = T.let(T.unsafe(nil), Array) + +# Provides +deep_merge+ and +deep_merge!+ methods. Expects the including class +# to provide a merge!(other, &block) method. +# +# source://activesupport//lib/active_support/deep_mergeable.rb#6 +module ActiveSupport::DeepMergeable + # Returns a new instance with the values from +other+ merged recursively. + # + # class Hash + # include ActiveSupport::DeepMergeable + # end + # + # hash_1 = { a: true, b: { c: [1, 2, 3] } } + # hash_2 = { a: false, b: { x: [3, 4, 5] } } + # + # hash_1.deep_merge(hash_2) + # # => { a: false, b: { c: [1, 2, 3], x: [3, 4, 5] } } + # + # A block can be provided to merge non-DeepMergeable values: + # + # hash_1 = { a: 100, b: 200, c: { c1: 100 } } + # hash_2 = { b: 250, c: { c1: 200 } } + # + # hash_1.deep_merge(hash_2) do |key, this_val, other_val| + # this_val + other_val + # end + # # => { a: 100, b: 450, c: { c1: 300 } } + # + # source://activesupport//lib/active_support/deep_mergeable.rb#29 + def deep_merge(other, &block); end + + # Same as #deep_merge, but modifies +self+. + # + # source://activesupport//lib/active_support/deep_mergeable.rb#34 + def deep_merge!(other, &block); end + + # Returns true if +other+ can be deep merged into +self+. Classes may + # override this method to restrict or expand the domain of deep mergeable + # values. Defaults to checking that +other+ is of type +self.class+. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/deep_mergeable.rb#49 + def deep_merge?(other); end +end + +# source://activesupport//lib/active_support/delegation.rb#16 +module ActiveSupport::Delegation + class << self + # source://activesupport//lib/active_support/delegation.rb#23 + def generate(owner, methods, location: T.unsafe(nil), to: T.unsafe(nil), prefix: T.unsafe(nil), allow_nil: T.unsafe(nil), nilable: T.unsafe(nil), private: T.unsafe(nil), as: T.unsafe(nil), signature: T.unsafe(nil)); end + + # source://activesupport//lib/active_support/delegation.rb#152 + def generate_method_missing(owner, target, allow_nil: T.unsafe(nil)); end + end +end + +# source://activesupport//lib/active_support/delegation.rb#20 +ActiveSupport::Delegation::RESERVED_METHOD_NAMES = T.let(T.unsafe(nil), Set) + +# source://activesupport//lib/active_support/delegation.rb#17 +ActiveSupport::Delegation::RUBY_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) + +# Error generated by +delegate+ when a method is called on +nil+ and +allow_nil+ +# option is not used. +# +# source://activesupport//lib/active_support/delegation.rb#8 +class ActiveSupport::DelegationError < ::NoMethodError + class << self + # source://activesupport//lib/active_support/delegation.rb#10 + def nil_target(method_name, target); end + end +end + # source://activesupport//lib/active_support/dependencies/interlock.rb#6 module ActiveSupport::Dependencies class << self @@ -3479,38 +4369,42 @@ module ActiveSupport::Dependencies::RequireDependency def require_dependency(filename); end end -# source://activesupport//lib/active_support/core_ext/numeric/deprecated_conversions.rb#4 -module ActiveSupport::DeprecatedNumericWithFormat - # source://activesupport//lib/active_support/core_ext/numeric/deprecated_conversions.rb#5 - def to_s(format = T.unsafe(nil), options = T.unsafe(nil)); end -end - -# source://activesupport//lib/active_support/core_ext/range/deprecated_conversions.rb#4 -module ActiveSupport::DeprecatedRangeWithFormat - # source://activesupport//lib/active_support/deprecation/method_wrappers.rb#63 - def to_default_s(*args, **_arg1, &block); end - - # source://activesupport//lib/active_support/core_ext/range/deprecated_conversions.rb#6 - def to_s(format = T.unsafe(nil)); end -end - -# source://activesupport//lib/active_support/core_ext/range/deprecated_conversions.rb#5 -ActiveSupport::DeprecatedRangeWithFormat::NOT_SET = T.let(T.unsafe(nil), Object) - -# \Deprecation specifies the API used by Rails to deprecate methods, instance -# variables, objects, and constants. +# = Active Support \Deprecation +# +# \Deprecation specifies the API used by \Rails to deprecate methods, instance variables, objects, and constants. It's +# also available for gems or applications. +# +# For a gem, use Deprecation.new to create a Deprecation object and store it in your module or class (in order for +# users to be able to configure it). +# +# module MyLibrary +# def self.deprecator +# @deprecator ||= ActiveSupport::Deprecation.new("2.0", "MyLibrary") +# end +# end +# +# For a Railtie or Engine, you may also want to add it to the application's deprecators, so that the application's +# configuration can be applied to it. +# +# module MyLibrary +# class Railtie < Rails::Railtie +# initializer "my_library.deprecator" do |app| +# app.deprecators[:my_library] = MyLibrary.deprecator +# end +# end +# end # -# source://activesupport//lib/active_support/deprecation.rb#8 +# With the above initializer, configuration settings like the following will affect +MyLibrary.deprecator+: +# +# # in config/environments/test.rb +# config.active_support.deprecation = :raise +# +# source://activesupport//lib/active_support/deprecation.rb#33 class ActiveSupport::Deprecation - include ::Singleton - include ::ActiveSupport::Deprecation::InstanceDelegator include ::ActiveSupport::Deprecation::Behavior include ::ActiveSupport::Deprecation::Reporting include ::ActiveSupport::Deprecation::Disallowed include ::ActiveSupport::Deprecation::MethodWrapper - extend ::Singleton::SingletonClassMethods - extend ::ActiveSupport::Deprecation::InstanceDelegator::ClassMethods - extend ::ActiveSupport::Deprecation::InstanceDelegator::OverrideDelegators # It accepts two parameters on initialization. The first is a version of library # and the second is a library name. @@ -3519,82 +4413,22 @@ class ActiveSupport::Deprecation # # @return [Deprecation] a new instance of Deprecation # - # source://activesupport//lib/active_support/deprecation.rb#41 + # source://activesupport//lib/active_support/deprecation.rb#71 def initialize(deprecation_horizon = T.unsafe(nil), gem_name = T.unsafe(nil)); end # The version number in which the deprecated behavior will be removed, by default. # - # source://activesupport//lib/active_support/deprecation.rb#35 + # source://activesupport//lib/active_support/deprecation.rb#65 def deprecation_horizon; end # The version number in which the deprecated behavior will be removed, by default. # - # source://activesupport//lib/active_support/deprecation.rb#35 + # source://activesupport//lib/active_support/deprecation.rb#65 def deprecation_horizon=(_arg0); end class << self - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def allow(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def behavior(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def behavior=(arg); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def debug(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def debug=(arg); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def deprecate_methods(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def deprecation_horizon(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def deprecation_horizon=(arg); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#31 - def deprecation_warning(deprecated_method_name, message = T.unsafe(nil), caller_backtrace = T.unsafe(nil)); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def disallowed_behavior(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def disallowed_behavior=(arg); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def disallowed_warnings(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def disallowed_warnings=(arg); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def gem_name(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def gem_name=(arg); end - - def new(*_arg0); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def silence(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def silenced(*_arg0, **_arg1, &_arg2); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#21 - def silenced=(arg); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#26 - def warn(message = T.unsafe(nil), callstack = T.unsafe(nil)); end - - private - - def allocate; end + # source://activesupport//lib/active_support/deprecation.rb#60 + def _instance; end end end @@ -3602,20 +4436,21 @@ end # You can create a custom behavior or set any from the +DEFAULT_BEHAVIORS+ # constant. Available behaviors are: # -# [+raise+] Raise ActiveSupport::DeprecationException. -# [+stderr+] Log all deprecation warnings to $stderr. -# [+log+] Log all deprecation warnings to +Rails.logger+. -# [+notify+] Use +ActiveSupport::Notifications+ to notify +deprecation.rails+. -# [+silence+] Do nothing. On Rails, set config.active_support.report_deprecations = false to disable all behaviors. +# [+:raise+] Raise ActiveSupport::DeprecationException. +# [+:stderr+] Log all deprecation warnings to $stderr. +# [+:log+] Log all deprecation warnings to +Rails.logger+. +# [+:notify+] Use ActiveSupport::Notifications to notify +deprecation.rails+. +# [+:report+] Use ActiveSupport::ErrorReporter to report deprecations. +# [+:silence+] Do nothing. On \Rails, set config.active_support.report_deprecations = false to disable all behaviors. # # Setting behaviors only affects deprecations that happen after boot time. -# For more information you can read the documentation of the +behavior=+ method. +# For more information you can read the documentation of the #behavior= method. # -# source://activesupport//lib/active_support/deprecation/behaviors.rb#61 +# source://activesupport//lib/active_support/deprecation/behaviors.rb#69 module ActiveSupport::Deprecation::Behavior # Returns the current behavior or if one isn't set, defaults to +:stderr+. # - # source://activesupport//lib/active_support/deprecation/behaviors.rb#66 + # source://activesupport//lib/active_support/deprecation/behaviors.rb#74 def behavior; end # Sets the behavior to the specified value. Can be a single value, array, @@ -3623,56 +4458,63 @@ module ActiveSupport::Deprecation::Behavior # # Available behaviors: # - # [+raise+] Raise ActiveSupport::DeprecationException. - # [+stderr+] Log all deprecation warnings to $stderr. - # [+log+] Log all deprecation warnings to +Rails.logger+. - # [+notify+] Use +ActiveSupport::Notifications+ to notify +deprecation.rails+. - # [+silence+] Do nothing. + # [+:raise+] Raise ActiveSupport::DeprecationException. + # [+:stderr+] Log all deprecation warnings to $stderr. + # [+:log+] Log all deprecation warnings to +Rails.logger+. + # [+:notify+] Use ActiveSupport::Notifications to notify +deprecation.rails+. + # [+:report+] Use ActiveSupport::ErrorReporter to report deprecations. + # [+:silence+] Do nothing. # # Setting behaviors only affects deprecations that happen after boot time. # Deprecation warnings raised by gems are not affected by this setting - # because they happen before Rails boots up. + # because they happen before \Rails boots up. # - # ActiveSupport::Deprecation.behavior = :stderr - # ActiveSupport::Deprecation.behavior = [:stderr, :log] - # ActiveSupport::Deprecation.behavior = MyCustomHandler - # ActiveSupport::Deprecation.behavior = ->(message, callstack, deprecation_horizon, gem_name) { + # deprecator = ActiveSupport::Deprecation.new + # deprecator.behavior = :stderr + # deprecator.behavior = [:stderr, :log] + # deprecator.behavior = MyCustomHandler + # deprecator.behavior = ->(message, callstack, deprecation_horizon, gem_name) { # # custom stuff # } # - # If you are using Rails, you can set config.active_support.report_deprecations = false to disable - # all deprecation behaviors. This is similar to the +silence+ option but more performant. + # If you are using \Rails, you can set + # config.active_support.report_deprecations = false to disable + # all deprecation behaviors. This is similar to the +:silence+ option but + # more performant. # - # source://activesupport//lib/active_support/deprecation/behaviors.rb#99 + # source://activesupport//lib/active_support/deprecation/behaviors.rb#111 def behavior=(behavior); end # Whether to print a backtrace along with the warning. # - # source://activesupport//lib/active_support/deprecation/behaviors.rb#63 + # source://activesupport//lib/active_support/deprecation/behaviors.rb#71 def debug; end # Whether to print a backtrace along with the warning. # - # source://activesupport//lib/active_support/deprecation/behaviors.rb#63 + # source://activesupport//lib/active_support/deprecation/behaviors.rb#71 def debug=(_arg0); end # Returns the current behavior for disallowed deprecations or if one isn't set, defaults to +:raise+. # - # source://activesupport//lib/active_support/deprecation/behaviors.rb#71 + # source://activesupport//lib/active_support/deprecation/behaviors.rb#79 def disallowed_behavior; end # Sets the behavior for disallowed deprecations (those configured by - # ActiveSupport::Deprecation.disallowed_warnings=) to the specified - # value. As with +behavior=+, this can be a single value, array, or an + # ActiveSupport::Deprecation#disallowed_warnings=) to the specified + # value. As with #behavior=, this can be a single value, array, or an # object that responds to +call+. # - # source://activesupport//lib/active_support/deprecation/behaviors.rb#107 + # source://activesupport//lib/active_support/deprecation/behaviors.rb#119 def disallowed_behavior=(behavior); end private - # source://activesupport//lib/active_support/deprecation/behaviors.rb#112 + # source://activesupport//lib/active_support/deprecation/behaviors.rb#124 def arity_coerce(behavior); end + + # source://activesupport//lib/active_support/deprecation/behaviors.rb#143 + def arity_of_callable(callable); end end # Default warning behaviors per Rails.env. @@ -3680,64 +4522,41 @@ end # source://activesupport//lib/active_support/deprecation/behaviors.rb#13 ActiveSupport::Deprecation::DEFAULT_BEHAVIORS = T.let(T.unsafe(nil), Hash) -# DeprecatedConstantAccessor transforms a constant into a deprecated one by -# hooking +const_missing+. -# -# It takes the names of an old (deprecated) constant and of a new constant -# (both in string form) and optionally a deprecator. The deprecator defaults -# to +ActiveSupport::Deprecator+ if none is specified. -# -# The deprecated constant now returns the same object as the new one rather -# than a proxy object, so it can be used transparently in +rescue+ blocks -# etc. -# -# PLANETS = %w(mercury venus earth mars jupiter saturn uranus neptune pluto) -# -# # (In a later update, the original implementation of `PLANETS` has been removed.) -# -# PLANETS_POST_2006 = %w(mercury venus earth mars jupiter saturn uranus neptune) -# include ActiveSupport::Deprecation::DeprecatedConstantAccessor -# deprecate_constant 'PLANETS', 'PLANETS_POST_2006' -# -# PLANETS.map { |planet| planet.capitalize } -# # => DEPRECATION WARNING: PLANETS is deprecated! Use PLANETS_POST_2006 instead. -# (Backtrace information…) -# ["Mercury", "Venus", "Earth", "Mars", "Jupiter", "Saturn", "Uranus", "Neptune"] -# -# source://activesupport//lib/active_support/deprecation/constant_accessor.rb#28 +# source://activesupport//lib/active_support/deprecation/constant_accessor.rb#5 module ActiveSupport::Deprecation::DeprecatedConstantAccessor class << self # @private # - # source://activesupport//lib/active_support/deprecation/constant_accessor.rb#29 + # source://activesupport//lib/active_support/deprecation/constant_accessor.rb#6 def included(base); end end end -# DeprecatedConstantProxy transforms a constant into a deprecated one. It -# takes the names of an old (deprecated) constant and of a new constant -# (both in string form) and optionally a deprecator. The deprecator defaults -# to +ActiveSupport::Deprecator+ if none is specified. The deprecated constant -# now returns the value of the new one. +# DeprecatedConstantProxy transforms a constant into a deprecated one. It takes the full names of an old +# (deprecated) constant and of a new constant (both in string form) and a deprecator. The deprecated constant now +# returns the value of the new one. # # PLANETS = %w(mercury venus earth mars jupiter saturn uranus neptune pluto) # # # (In a later update, the original implementation of `PLANETS` has been removed.) # # PLANETS_POST_2006 = %w(mercury venus earth mars jupiter saturn uranus neptune) -# PLANETS = ActiveSupport::Deprecation::DeprecatedConstantProxy.new('PLANETS', 'PLANETS_POST_2006') +# PLANETS = ActiveSupport::Deprecation::DeprecatedConstantProxy.new("PLANETS", "PLANETS_POST_2006", ActiveSupport::Deprecation.new) # # PLANETS.map { |planet| planet.capitalize } # # => DEPRECATION WARNING: PLANETS is deprecated! Use PLANETS_POST_2006 instead. # (Backtrace information…) # ["Mercury", "Venus", "Earth", "Mars", "Jupiter", "Saturn", "Uranus", "Neptune"] # -# source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#123 +# source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#120 class ActiveSupport::Deprecation::DeprecatedConstantProxy < ::Module # @return [DeprecatedConstantProxy] a new instance of DeprecatedConstantProxy # - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#131 - def initialize(old_const, new_const, deprecator = T.unsafe(nil), message: T.unsafe(nil)); end + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#128 + def initialize(old_const, new_const, deprecator, message: T.unsafe(nil)); end + + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#158 + def append_features(base); end # Returns the class of the new constant. # @@ -3745,53 +4564,59 @@ class ActiveSupport::Deprecation::DeprecatedConstantProxy < ::Module # PLANETS = ActiveSupport::Deprecation::DeprecatedConstantProxy.new('PLANETS', 'PLANETS_POST_2006') # PLANETS.class # => Array # - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#157 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#154 def class; end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#150 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#168 + def extended(base); end + + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#147 def hash(*_arg0, **_arg1, &_arg2); end # Don't give a deprecation warning on inspect since test/unit and error # logs rely on it for diagnostics. # - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#144 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#141 def inspect; end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#150 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#147 def instance_methods(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#150 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#147 def name(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#150 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#163 + def prepend_features(base); end + + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#147 def respond_to?(*_arg0, **_arg1, &_arg2); end private - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#166 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#178 def const_missing(name); end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#171 - def method_missing(called, *args, &block); end + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#183 + def method_missing(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#162 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#174 def target; end class << self - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#124 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#121 def new(*args, **options, &block); end end end -# DeprecatedInstanceVariableProxy transforms an instance variable into a -# deprecated one. It takes an instance of a class, a method on that class -# and an instance variable. It optionally takes a deprecator as the last -# argument. The deprecator defaults to +ActiveSupport::Deprecator+ if none -# is specified. +# DeprecatedInstanceVariableProxy transforms an instance variable into a deprecated one. It takes an instance of a +# class, a method on that class, an instance variable, and a deprecator as the last argument. +# +# Trying to use the deprecated instance variable will result in a deprecation warning, pointing to the method as a +# replacement. # # class Example # def initialize -# @request = ActiveSupport::Deprecation::DeprecatedInstanceVariableProxy.new(self, :request, :@request) +# @request = ActiveSupport::Deprecation::DeprecatedInstanceVariableProxy.new(self, :request, :@request, ActiveSupport::Deprecation.new) # @_request = :special_request # end # @@ -3816,27 +4641,26 @@ end # example.request.to_s # # => "special_request" # -# source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#88 +# source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#87 class ActiveSupport::Deprecation::DeprecatedInstanceVariableProxy < ::ActiveSupport::Deprecation::DeprecationProxy # @return [DeprecatedInstanceVariableProxy] a new instance of DeprecatedInstanceVariableProxy # - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#89 - def initialize(instance, method, var = T.unsafe(nil), deprecator = T.unsafe(nil)); end + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#88 + def initialize(instance, method, var = T.unsafe(nil), deprecator:); end private - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#97 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#96 def target; end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#101 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#100 def warn(callstack, called, args); end end -# DeprecatedObjectProxy transforms an object into a deprecated one. It -# takes an object, a deprecation message, and optionally a deprecator. The -# deprecator defaults to +ActiveSupport::Deprecator+ if none is specified. +# DeprecatedObjectProxy transforms an object into a deprecated one. It takes an object, a deprecation message, and +# a deprecator. # -# deprecated_object = ActiveSupport::Deprecation::DeprecatedObjectProxy.new(Object.new, "This object is now deprecated") +# deprecated_object = ActiveSupport::Deprecation::DeprecatedObjectProxy.new(Object.new, "This object is now deprecated", ActiveSupport::Deprecation.new) # # => # # # deprecated_object.to_s @@ -3844,19 +4668,19 @@ end # (Backtrace) # # => "#" # -# source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#39 +# source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#38 class ActiveSupport::Deprecation::DeprecatedObjectProxy < ::ActiveSupport::Deprecation::DeprecationProxy # @return [DeprecatedObjectProxy] a new instance of DeprecatedObjectProxy # - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#40 - def initialize(object, message, deprecator = T.unsafe(nil)); end + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#39 + def initialize(object, message, deprecator); end private - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#47 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#46 def target; end - # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#51 + # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#50 def warn(callstack, called, args); end end @@ -3875,10 +4699,101 @@ class ActiveSupport::Deprecation::DeprecationProxy class << self # source://activesupport//lib/active_support/deprecation/proxy_wrappers.rb#6 - def new(*args, &block); end + def new(*args, **kwargs, &block); end end end +# A managed collection of deprecators. Configuration methods, such as +# #behavior=, affect all deprecators in the collection. Additionally, the +# #silence method silences all deprecators in the collection for the +# duration of a given block. +# +# source://activesupport//lib/active_support/deprecation/deprecators.rb#9 +class ActiveSupport::Deprecation::Deprecators + # @return [Deprecators] a new instance of Deprecators + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#10 + def initialize; end + + # Returns a deprecator added to this collection via #[]=. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#16 + def [](name); end + + # Adds a given +deprecator+ to this collection. The deprecator will be + # immediately configured with any options previously set on this + # collection. + # + # deprecators = ActiveSupport::Deprecation::Deprecators.new + # deprecators.debug = true + # + # foo_deprecator = ActiveSupport::Deprecation.new("2.0", "Foo") + # foo_deprecator.debug # => false + # + # deprecators[:foo] = foo_deprecator + # deprecators[:foo].debug # => true + # foo_deprecator.debug # => true + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#34 + def []=(name, deprecator); end + + # Sets the deprecation warning behavior for all deprecators in this + # collection. + # + # See ActiveSupport::Deprecation#behavior=. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#60 + def behavior=(behavior); end + + # Sets the debug flag for all deprecators in this collection. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#52 + def debug=(debug); end + + # Sets the disallowed deprecation warning behavior for all deprecators in + # this collection. + # + # See ActiveSupport::Deprecation#disallowed_behavior=. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#68 + def disallowed_behavior=(disallowed_behavior); end + + # Sets the disallowed deprecation warnings for all deprecators in this + # collection. + # + # See ActiveSupport::Deprecation#disallowed_warnings=. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#76 + def disallowed_warnings=(disallowed_warnings); end + + # Iterates over all deprecators in this collection. If no block is given, + # returns an +Enumerator+. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#41 + def each(&block); end + + # Silences all deprecators in this collection for the duration of the + # given block. + # + # See ActiveSupport::Deprecation#silence. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#84 + def silence(&block); end + + # Sets the silenced flag for all deprecators in this collection. + # + # source://activesupport//lib/active_support/deprecation/deprecators.rb#47 + def silenced=(silenced); end + + private + + # source://activesupport//lib/active_support/deprecation/deprecators.rb#97 + def apply_options(deprecator); end + + # source://activesupport//lib/active_support/deprecation/deprecators.rb#92 + def set_option(name, value); end +end + # source://activesupport//lib/active_support/deprecation/disallowed.rb#5 module ActiveSupport::Deprecation::Disallowed # Returns the configured criteria used to identify deprecation messages @@ -3911,40 +4826,12 @@ module ActiveSupport::Deprecation::Disallowed # @return [Boolean] # - # source://activesupport//lib/active_support/deprecation/disallowed.rb#40 + # source://activesupport//lib/active_support/deprecation/disallowed.rb#39 def explicitly_allowed?(message); end end -# source://activesupport//lib/active_support/deprecation/instance_delegator.rb#7 -module ActiveSupport::Deprecation::InstanceDelegator - mixes_in_class_methods ::ActiveSupport::Deprecation::InstanceDelegator::ClassMethods - mixes_in_class_methods ::ActiveSupport::Deprecation::InstanceDelegator::OverrideDelegators - - class << self - # @private - # - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#8 - def included(base); end - end -end - -# source://activesupport//lib/active_support/deprecation/instance_delegator.rb#14 -module ActiveSupport::Deprecation::InstanceDelegator::ClassMethods - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#15 - def include(included_module); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#20 - def method_added(method_name); end -end - -# source://activesupport//lib/active_support/deprecation/instance_delegator.rb#25 -module ActiveSupport::Deprecation::InstanceDelegator::OverrideDelegators - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#31 - def deprecation_warning(deprecated_method_name, message = T.unsafe(nil), caller_backtrace = T.unsafe(nil)); end - - # source://activesupport//lib/active_support/deprecation/instance_delegator.rb#26 - def warn(message = T.unsafe(nil), callstack = T.unsafe(nil)); end -end +# source://activesupport//lib/active_support/deprecation.rb#57 +ActiveSupport::Deprecation::MUTEX = T.let(T.unsafe(nil), Thread::Mutex) # source://activesupport//lib/active_support/deprecation/method_wrappers.rb#8 module ActiveSupport::Deprecation::MethodWrapper @@ -3958,41 +4845,24 @@ module ActiveSupport::Deprecation::MethodWrapper # def eee; end # end # - # Using the default deprecator: - # ActiveSupport::Deprecation.deprecate_methods(Fred, :aaa, bbb: :zzz, ccc: 'use Bar#ccc instead') + # deprecator = ActiveSupport::Deprecation.new('next-release', 'MyGem') + # + # deprecator.deprecate_methods(Fred, :aaa, bbb: :zzz, ccc: 'use Bar#ccc instead') # # => Fred # # Fred.new.aaa - # # DEPRECATION WARNING: aaa is deprecated and will be removed from Rails 5.1. (called from irb_binding at (irb):10) + # # DEPRECATION WARNING: aaa is deprecated and will be removed from MyGem next-release. (called from irb_binding at (irb):10) # # => nil # # Fred.new.bbb - # # DEPRECATION WARNING: bbb is deprecated and will be removed from Rails 5.1 (use zzz instead). (called from irb_binding at (irb):11) + # # DEPRECATION WARNING: bbb is deprecated and will be removed from MyGem next-release (use zzz instead). (called from irb_binding at (irb):11) # # => nil # # Fred.new.ccc - # # DEPRECATION WARNING: ccc is deprecated and will be removed from Rails 5.1 (use Bar#ccc instead). (called from irb_binding at (irb):12) - # # => nil - # - # Passing in a custom deprecator: - # custom_deprecator = ActiveSupport::Deprecation.new('next-release', 'MyGem') - # ActiveSupport::Deprecation.deprecate_methods(Fred, ddd: :zzz, deprecator: custom_deprecator) - # # => [:ddd] - # - # Fred.new.ddd - # DEPRECATION WARNING: ddd is deprecated and will be removed from MyGem next-release (use zzz instead). (called from irb_binding at (irb):15) - # # => nil - # - # Using a custom deprecator directly: - # custom_deprecator = ActiveSupport::Deprecation.new('next-release', 'MyGem') - # custom_deprecator.deprecate_methods(Fred, eee: :zzz) - # # => [:eee] - # - # Fred.new.eee - # DEPRECATION WARNING: eee is deprecated and will be removed from MyGem next-release (use zzz instead). (called from irb_binding at (irb):18) + # # DEPRECATION WARNING: ccc is deprecated and will be removed from MyGem next-release (use Bar#ccc instead). (called from irb_binding at (irb):12) # # => nil # - # source://activesupport//lib/active_support/deprecation/method_wrappers.rb#52 + # source://activesupport//lib/active_support/deprecation/method_wrappers.rb#35 def deprecate_methods(target_module, *method_names); end end @@ -4003,36 +4873,43 @@ module ActiveSupport::Deprecation::Reporting # expressions. (Symbols are treated as strings). These are compared against # the text of deprecation warning messages generated within the block. # Matching warnings will be exempt from the rules set by - # +ActiveSupport::Deprecation.disallowed_warnings+ + # ActiveSupport::Deprecation#disallowed_warnings. # # The optional if: argument accepts a truthy/falsy value or an object that # responds to .call. If truthy, then matching warnings will be allowed. # If falsey then the method yields to the block without allowing the warning. # - # ActiveSupport::Deprecation.disallowed_behavior = :raise - # ActiveSupport::Deprecation.disallowed_warnings = [ + # deprecator = ActiveSupport::Deprecation.new + # deprecator.disallowed_behavior = :raise + # deprecator.disallowed_warnings = [ # "something broke" # ] # - # ActiveSupport::Deprecation.warn('something broke!') + # deprecator.warn('something broke!') # # => ActiveSupport::DeprecationException # - # ActiveSupport::Deprecation.allow ['something broke'] do - # ActiveSupport::Deprecation.warn('something broke!') + # deprecator.allow ['something broke'] do + # deprecator.warn('something broke!') # end # # => nil # - # ActiveSupport::Deprecation.allow ['something broke'], if: Rails.env.production? do - # ActiveSupport::Deprecation.warn('something broke!') + # deprecator.allow ['something broke'], if: Rails.env.production? do + # deprecator.warn('something broke!') # end # # => ActiveSupport::DeprecationException for dev/test, nil for production # - # source://activesupport//lib/active_support/deprecation/reporting.rb#72 + # source://activesupport//lib/active_support/deprecation/reporting.rb#89 def allow(allowed_warnings = T.unsafe(nil), if: T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/deprecation/reporting.rb#86 + # source://activesupport//lib/active_support/deprecation/reporting.rb#48 + def begin_silence; end + + # source://activesupport//lib/active_support/deprecation/reporting.rb#99 def deprecation_warning(deprecated_method_name, message = T.unsafe(nil), caller_backtrace = T.unsafe(nil)); end + # source://activesupport//lib/active_support/deprecation/reporting.rb#52 + def end_silence; end + # Name of gem where method is deprecated # # source://activesupport//lib/active_support/deprecation/reporting.rb#11 @@ -4045,18 +4922,19 @@ module ActiveSupport::Deprecation::Reporting # Silence deprecation warnings within the block. # - # ActiveSupport::Deprecation.warn('something broke!') + # deprecator = ActiveSupport::Deprecation.new + # deprecator.warn('something broke!') # # => "DEPRECATION WARNING: something broke! (called from your_code.rb:1)" # - # ActiveSupport::Deprecation.silence do - # ActiveSupport::Deprecation.warn('something broke!') + # deprecator.silence do + # deprecator.warn('something broke!') # end # # => nil # - # source://activesupport//lib/active_support/deprecation/reporting.rb#40 + # source://activesupport//lib/active_support/deprecation/reporting.rb#41 def silence(&block); end - # source://activesupport//lib/active_support/deprecation/reporting.rb#82 + # source://activesupport//lib/active_support/deprecation/reporting.rb#56 def silenced; end # Whether to print a message (silent mode) @@ -4065,9 +4943,9 @@ module ActiveSupport::Deprecation::Reporting def silenced=(_arg0); end # Outputs a deprecation warning to the output configured by - # ActiveSupport::Deprecation.behavior. + # ActiveSupport::Deprecation#behavior. # - # ActiveSupport::Deprecation.warn('something broke!') + # ActiveSupport::Deprecation.new.warn('something broke!') # # => "DEPRECATION WARNING: something broke! (called from your_code.rb:1)" # # source://activesupport//lib/active_support/deprecation/reporting.rb#18 @@ -4075,7 +4953,7 @@ module ActiveSupport::Deprecation::Reporting private - # source://activesupport//lib/active_support/deprecation/reporting.rb#137 + # source://activesupport//lib/active_support/deprecation/reporting.rb#153 def _extract_callstack(callstack); end # Outputs a deprecation warning message @@ -4087,23 +4965,28 @@ module ActiveSupport::Deprecation::Reporting # deprecated_method_warning(:method_name, "Optional message") # # => "method_name is deprecated and will be removed from Rails #{deprecation_horizon} (Optional message)" # - # source://activesupport//lib/active_support/deprecation/reporting.rb#102 + # source://activesupport//lib/active_support/deprecation/reporting.rb#115 def deprecated_method_warning(method_name, message = T.unsafe(nil)); end - # source://activesupport//lib/active_support/deprecation/reporting.rb#116 + # source://activesupport//lib/active_support/deprecation/reporting.rb#129 def deprecation_caller_message(callstack); end - # source://activesupport//lib/active_support/deprecation/reporting.rb#111 + # source://activesupport//lib/active_support/deprecation/reporting.rb#124 def deprecation_message(callstack, message = T.unsafe(nil)); end - # source://activesupport//lib/active_support/deprecation/reporting.rb#127 + # source://activesupport//lib/active_support/deprecation/reporting.rb#140 def extract_callstack(callstack); end - # source://activesupport//lib/active_support/deprecation/reporting.rb#152 - def ignored_callstack(path); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/deprecation/reporting.rb#174 + def ignored_callstack?(path); end end -# source://activesupport//lib/active_support/deprecation/reporting.rb#150 +# source://activesupport//lib/active_support/deprecation/reporting.rb#172 +ActiveSupport::Deprecation::Reporting::LIB_DIR = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/deprecation/reporting.rb#171 ActiveSupport::Deprecation::Reporting::RAILS_GEM_ROOT = T.let(T.unsafe(nil), String) # Raised when ActiveSupport::Deprecation::Behavior#behavior is set with :raise. @@ -4112,43 +4995,61 @@ ActiveSupport::Deprecation::Reporting::RAILS_GEM_ROOT = T.let(T.unsafe(nil), Str # source://activesupport//lib/active_support/deprecation/behaviors.rb#8 class ActiveSupport::DeprecationException < ::StandardError; end +# = Active Support Descendants Tracker +# # This module provides an internal implementation to track descendants -# which is faster than iterating through ObjectSpace. +# which is faster than iterating through +ObjectSpace+. +# +# However Ruby 3.1 provide a fast native +Class#subclasses+ method, +# so if you know your code won't be executed on older rubies, including +# +ActiveSupport::DescendantsTracker+ does not provide any benefit. # -# source://activesupport//lib/active_support/descendants_tracker.rb#9 +# source://activesupport//lib/active_support/descendants_tracker.rb#14 module ActiveSupport::DescendantsTracker - # source://activesupport//lib/active_support/descendants_tracker.rb#88 + # source://activesupport//lib/active_support/descendants_tracker.rb#107 def descendants; end - # source://activesupport//lib/active_support/descendants_tracker.rb#92 - def direct_descendants; end - - # source://activesupport//lib/active_support/descendants_tracker.rb#82 - def subclasses; end - class << self - # source://activesupport//lib/active_support/descendants_tracker.rb#66 + # source://activesupport//lib/active_support/descendants_tracker.rb#78 def clear(classes); end - # source://activesupport//lib/active_support/descendants_tracker.rb#62 + # source://activesupport//lib/active_support/descendants_tracker.rb#102 def descendants(klass); end - # source://activesupport//lib/active_support/descendants_tracker.rb#11 - def direct_descendants(klass); end - - # source://activesupport//lib/active_support/descendants_tracker.rb#50 + # source://activesupport//lib/active_support/descendants_tracker.rb#69 def disable_clear!; end - # @return [Boolean] - # - # source://activesupport//lib/active_support/descendants_tracker.rb#77 - def native?; end + # source://activesupport//lib/active_support/descendants_tracker.rb#89 + def reject!(classes); end - # source://activesupport//lib/active_support/descendants_tracker.rb#58 + # source://activesupport//lib/active_support/descendants_tracker.rb#98 def subclasses(klass); end end end +# source://activesupport//lib/active_support/descendants_tracker.rb#58 +module ActiveSupport::DescendantsTracker::ReloadedClassesFiltering + # source://activesupport//lib/active_support/descendants_tracker.rb#63 + def descendants; end + + # source://activesupport//lib/active_support/descendants_tracker.rb#59 + def subclasses; end +end + +# On TruffleRuby `ObjectSpace::WeakMap` keys are strong references. +# So we use `object_id` as a key and the actual object as a value. +# +# JRuby for now doesn't have Class#descendant, but when it will, it will likely +# have the same WeakMap semantic than Truffle so we future proof this as much as possible. +# +# source://activesupport//lib/active_support/descendants_tracker.rb#20 +class ActiveSupport::DescendantsTracker::WeakSet < ::ObjectSpace::WeakMap + # source://activesupport//lib/active_support/descendants_tracker.rb#23 + def <<(object); end + + def to_a; end +end + # source://activesupport//lib/active_support/digest.rb#6 class ActiveSupport::Digest class << self @@ -4165,92 +5066,97 @@ class ActiveSupport::Digest end end +# = Active Support \Duration +# # Provides accurate date and time measurements using Date#advance and # Time#advance, respectively. It mainly supports the methods on Numeric. # # 1.month.ago # equivalent to Time.now.advance(months: -1) # -# source://activesupport//lib/active_support/duration.rb#13 +# source://activesupport//lib/active_support/duration.rb#14 class ActiveSupport::Duration # @return [Duration] a new instance of Duration # - # source://activesupport//lib/active_support/duration.rb#223 + # source://activesupport//lib/active_support/duration.rb#226 def initialize(value, parts, variable = T.unsafe(nil)); end # Returns the modulo of this Duration by another Duration or Numeric. # Numeric values are treated as seconds. # - # source://activesupport//lib/active_support/duration.rb#306 + # source://activesupport//lib/active_support/duration.rb#312 def %(other); end # Multiplies this Duration by a Numeric and returns a new Duration. # - # source://activesupport//lib/active_support/duration.rb#281 + # source://activesupport//lib/active_support/duration.rb#287 def *(other); end # Adds another Duration or a Numeric to this Duration. Numeric values # are treated as seconds. # - # source://activesupport//lib/active_support/duration.rb#262 + # source://activesupport//lib/active_support/duration.rb#268 def +(other); end - # source://activesupport//lib/active_support/duration.rb#320 + # source://activesupport//lib/active_support/duration.rb#326 def +@; end # Subtracts another Duration or a Numeric from this Duration. Numeric # values are treated as seconds. # - # source://activesupport//lib/active_support/duration.rb#276 + # source://activesupport//lib/active_support/duration.rb#282 def -(other); end - # source://activesupport//lib/active_support/duration.rb#316 + # source://activesupport//lib/active_support/duration.rb#322 def -@; end # Divides this Duration by a Numeric and returns a new Duration. # - # source://activesupport//lib/active_support/duration.rb#292 + # source://activesupport//lib/active_support/duration.rb#298 def /(other); end # Compares one Duration with another or a Numeric to this Duration. # Numeric values are treated as seconds. # - # source://activesupport//lib/active_support/duration.rb#252 + # source://activesupport//lib/active_support/duration.rb#258 def <=>(other); end # Returns +true+ if +other+ is also a Duration instance with the # same +value+, or if other == value. # - # source://activesupport//lib/active_support/duration.rb#335 + # source://activesupport//lib/active_support/duration.rb#341 def ==(other); end - # source://activesupport//lib/active_support/duration.rb#475 + # source://activesupport//lib/active_support/duration.rb#481 def _parts; end + # source://activesupport//lib/active_support/duration.rb#224 + def abs(&_arg0); end + # Calculates a new Time or Date that is as far in the future # as this Duration represents. # - # source://activesupport//lib/active_support/duration.rb#430 + # source://activesupport//lib/active_support/duration.rb#436 def after(time = T.unsafe(nil)); end # Calculates a new Time or Date that is as far in the past # as this Duration represents. # - # source://activesupport//lib/active_support/duration.rb#438 + # source://activesupport//lib/active_support/duration.rb#444 def ago(time = T.unsafe(nil)); end - # source://activesupport//lib/active_support/duration.rb#453 + # source://activesupport//lib/active_support/duration.rb#459 def as_json(options = T.unsafe(nil)); end # Calculates a new Time or Date that is as far in the past # as this Duration represents. # - # source://activesupport//lib/active_support/duration.rb#438 + # source://activesupport//lib/active_support/duration.rb#444 def before(time = T.unsafe(nil)); end - # source://activesupport//lib/active_support/duration.rb#239 + # source://activesupport//lib/active_support/duration.rb#245 def coerce(other); end - # source://activesupport//lib/active_support/duration.rb#461 + # source://activesupport//lib/active_support/duration.rb#467 def encode_with(coder); end # Returns +true+ if +other+ is also a Duration instance, which has the @@ -4258,44 +5164,44 @@ class ActiveSupport::Duration # # @return [Boolean] # - # source://activesupport//lib/active_support/duration.rb#420 + # source://activesupport//lib/active_support/duration.rb#426 def eql?(other); end # Calculates a new Time or Date that is as far in the future # as this Duration represents. # - # source://activesupport//lib/active_support/duration.rb#430 + # source://activesupport//lib/active_support/duration.rb#436 def from_now(time = T.unsafe(nil)); end - # source://activesupport//lib/active_support/duration.rb#424 + # source://activesupport//lib/active_support/duration.rb#430 def hash; end # Returns the amount of days a duration covers as a float # # 12.hours.in_days # => 0.5 # - # source://activesupport//lib/active_support/duration.rb#393 + # source://activesupport//lib/active_support/duration.rb#399 def in_days; end # Returns the amount of hours a duration covers as a float # # 1.day.in_hours # => 24.0 # - # source://activesupport//lib/active_support/duration.rb#386 + # source://activesupport//lib/active_support/duration.rb#392 def in_hours; end # Returns the amount of minutes a duration covers as a float # # 1.day.in_minutes # => 1440.0 # - # source://activesupport//lib/active_support/duration.rb#379 + # source://activesupport//lib/active_support/duration.rb#385 def in_minutes; end # Returns the amount of months a duration covers as a float # # 9.weeks.in_months # => 2.07 # - # source://activesupport//lib/active_support/duration.rb#407 + # source://activesupport//lib/active_support/duration.rb#413 def in_months; end # Returns the number of seconds that this Duration represents. @@ -4315,65 +5221,77 @@ class ActiveSupport::Duration # 1.year.to_i # => 31556952 # # In such cases, Ruby's core - # Date[https://ruby-doc.org/stdlib/libdoc/date/rdoc/Date.html] and - # Time[https://ruby-doc.org/stdlib/libdoc/time/rdoc/Time.html] should be used for precision + # Date[https://docs.ruby-lang.org/en/master/Date.html] and + # Time[https://docs.ruby-lang.org/en/master/Time.html] should be used for precision # date and time arithmetic. # - # source://activesupport//lib/active_support/duration.rb#371 + # source://activesupport//lib/active_support/duration.rb#377 def in_seconds; end # Returns the amount of weeks a duration covers as a float # # 2.months.in_weeks # => 8.696 # - # source://activesupport//lib/active_support/duration.rb#400 + # source://activesupport//lib/active_support/duration.rb#406 def in_weeks; end # Returns the amount of years a duration covers as a float # # 30.days.in_years # => 0.082 # - # source://activesupport//lib/active_support/duration.rb#414 + # source://activesupport//lib/active_support/duration.rb#420 def in_years; end - # source://activesupport//lib/active_support/duration.rb#457 + # source://activesupport//lib/active_support/duration.rb#463 def init_with(coder); end - # source://activesupport//lib/active_support/duration.rb#444 + # source://activesupport//lib/active_support/duration.rb#450 def inspect; end # @return [Boolean] # - # source://activesupport//lib/active_support/duration.rb#329 + # source://activesupport//lib/active_support/duration.rb#335 def instance_of?(klass); end # @return [Boolean] # - # source://activesupport//lib/active_support/duration.rb#324 + # source://activesupport//lib/active_support/duration.rb#330 def is_a?(klass); end # Build ISO 8601 Duration string for this duration. # The +precision+ parameter can be used to limit seconds' precision of duration. # - # source://activesupport//lib/active_support/duration.rb#467 + # source://activesupport//lib/active_support/duration.rb#473 def iso8601(precision: T.unsafe(nil)); end # @return [Boolean] # - # source://activesupport//lib/active_support/duration.rb#324 + # source://activesupport//lib/active_support/duration.rb#330 def kind_of?(klass); end - # Returns a copy of the parts hash that defines the duration + # source://activesupport//lib/active_support/duration.rb#224 + def negative?(&_arg0); end + + # Returns a copy of the parts hash that defines the duration. # - # source://activesupport//lib/active_support/duration.rb#235 + # 5.minutes.parts # => {:minutes=>5} + # 3.years.parts # => {:years=>3} + # + # source://activesupport//lib/active_support/duration.rb#241 def parts; end + # source://activesupport//lib/active_support/duration.rb#224 + def positive?(&_arg0); end + # Calculates a new Time or Date that is as far in the future # as this Duration represents. # - # source://activesupport//lib/active_support/duration.rb#430 + # source://activesupport//lib/active_support/duration.rb#436 def since(time = T.unsafe(nil)); end + # source://activesupport//lib/active_support/duration.rb#224 + def to_f(&_arg0); end + # Returns the number of seconds that this Duration represents. # # 1.minute.to_i # => 60 @@ -4391,11 +5309,11 @@ class ActiveSupport::Duration # 1.year.to_i # => 31556952 # # In such cases, Ruby's core - # Date[https://ruby-doc.org/stdlib/libdoc/date/rdoc/Date.html] and - # Time[https://ruby-doc.org/stdlib/libdoc/time/rdoc/Time.html] should be used for precision + # Date[https://docs.ruby-lang.org/en/master/Date.html] and + # Time[https://docs.ruby-lang.org/en/master/Time.html] should be used for precision # date and time arithmetic. # - # source://activesupport//lib/active_support/duration.rb#371 + # source://activesupport//lib/active_support/duration.rb#377 def to_i; end # Returns the amount of seconds a duration covers as a string. @@ -4403,45 +5321,48 @@ class ActiveSupport::Duration # # 1.day.to_s # => "86400" # - # source://activesupport//lib/active_support/duration.rb#347 + # source://activesupport//lib/active_support/duration.rb#353 def to_s; end # Calculates a new Time or Date that is as far in the past # as this Duration represents. # - # source://activesupport//lib/active_support/duration.rb#438 + # source://activesupport//lib/active_support/duration.rb#444 def until(time = T.unsafe(nil)); end # Returns the value of attribute value. # - # source://activesupport//lib/active_support/duration.rb#132 + # source://activesupport//lib/active_support/duration.rb#133 def value; end # @return [Boolean] # - # source://activesupport//lib/active_support/duration.rb#471 + # source://activesupport//lib/active_support/duration.rb#477 def variable?; end + # source://activesupport//lib/active_support/duration.rb#224 + def zero?(&_arg0); end + private - # source://activesupport//lib/active_support/duration.rb#506 - def method_missing(method, *args, &block); end + # source://activesupport//lib/active_support/duration.rb#512 + def method_missing(*_arg0, **_arg1, &_arg2); end # @raise [TypeError] # - # source://activesupport//lib/active_support/duration.rb#510 + # source://activesupport//lib/active_support/duration.rb#516 def raise_type_error(other); end # @return [Boolean] # - # source://activesupport//lib/active_support/duration.rb#502 + # source://activesupport//lib/active_support/duration.rb#508 def respond_to_missing?(method, _); end - # source://activesupport//lib/active_support/duration.rb#480 + # source://activesupport//lib/active_support/duration.rb#486 def sum(sign, time = T.unsafe(nil)); end class << self - # source://activesupport//lib/active_support/duration.rb#148 + # source://activesupport//lib/active_support/duration.rb#149 def ===(other); end # Creates a new Duration from a seconds value that is converted @@ -4450,19 +5371,19 @@ class ActiveSupport::Duration # ActiveSupport::Duration.build(31556952).parts # => {:years=>1} # ActiveSupport::Duration.build(2716146).parts # => {:months=>1, :days=>1} # - # source://activesupport//lib/active_support/duration.rb#188 + # source://activesupport//lib/active_support/duration.rb#189 def build(value); end - # source://activesupport//lib/active_support/duration.rb#166 + # source://activesupport//lib/active_support/duration.rb#167 def days(value); end - # source://activesupport//lib/active_support/duration.rb#162 + # source://activesupport//lib/active_support/duration.rb#163 def hours(value); end - # source://activesupport//lib/active_support/duration.rb#158 + # source://activesupport//lib/active_support/duration.rb#159 def minutes(value); end - # source://activesupport//lib/active_support/duration.rb#174 + # source://activesupport//lib/active_support/duration.rb#175 def months(value); end # Creates a new Duration from string formatted according to ISO 8601 Duration. @@ -4471,21 +5392,21 @@ class ActiveSupport::Duration # This method allows negative parts to be present in pattern. # If invalid string is provided, it will raise +ActiveSupport::Duration::ISO8601Parser::ParsingError+. # - # source://activesupport//lib/active_support/duration.rb#143 + # source://activesupport//lib/active_support/duration.rb#144 def parse(iso8601duration); end - # source://activesupport//lib/active_support/duration.rb#154 + # source://activesupport//lib/active_support/duration.rb#155 def seconds(value); end - # source://activesupport//lib/active_support/duration.rb#170 + # source://activesupport//lib/active_support/duration.rb#171 def weeks(value); end - # source://activesupport//lib/active_support/duration.rb#178 + # source://activesupport//lib/active_support/duration.rb#179 def years(value); end private - # source://activesupport//lib/active_support/duration.rb#216 + # source://activesupport//lib/active_support/duration.rb#217 def calculate_total_seconds(parts); end end end @@ -4607,130 +5528,129 @@ ActiveSupport::Duration::ISO8601Parser::TIME_TO_PART = T.let(T.unsafe(nil), Hash # Serializes duration to string according to ISO 8601 Duration format. # -# source://activesupport//lib/active_support/duration/iso8601_serializer.rb#8 +# source://activesupport//lib/active_support/duration/iso8601_serializer.rb#6 class ActiveSupport::Duration::ISO8601Serializer # @return [ISO8601Serializer] a new instance of ISO8601Serializer # - # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#11 + # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#9 def initialize(duration, precision: T.unsafe(nil)); end # Builds and returns output string. # - # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#17 + # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#15 def serialize; end private - # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#58 + # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#55 def format_seconds(seconds); end # Return pair of duration's parts and whole duration sign. # Parts are summarized (as they can become repetitive due to addition, etc). # Zero parts are removed as not significant. - # If all parts are negative it will negate all of them and return minus as a sign. # - # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#41 + # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#38 def normalize; end # @return [Boolean] # - # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#54 + # source://activesupport//lib/active_support/duration/iso8601_serializer.rb#51 def week_mixed_with_date?(parts); end end -# source://activesupport//lib/active_support/duration/iso8601_serializer.rb#9 +# source://activesupport//lib/active_support/duration/iso8601_serializer.rb#7 ActiveSupport::Duration::ISO8601Serializer::DATE_COMPONENTS = T.let(T.unsafe(nil), Array) -# source://activesupport//lib/active_support/duration.rb#129 +# source://activesupport//lib/active_support/duration.rb#130 ActiveSupport::Duration::PARTS = T.let(T.unsafe(nil), Array) -# source://activesupport//lib/active_support/duration.rb#119 +# source://activesupport//lib/active_support/duration.rb#120 ActiveSupport::Duration::PARTS_IN_SECONDS = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/duration.rb#114 +# source://activesupport//lib/active_support/duration.rb#115 ActiveSupport::Duration::SECONDS_PER_DAY = T.let(T.unsafe(nil), Integer) -# source://activesupport//lib/active_support/duration.rb#113 +# source://activesupport//lib/active_support/duration.rb#114 ActiveSupport::Duration::SECONDS_PER_HOUR = T.let(T.unsafe(nil), Integer) -# source://activesupport//lib/active_support/duration.rb#112 +# source://activesupport//lib/active_support/duration.rb#113 ActiveSupport::Duration::SECONDS_PER_MINUTE = T.let(T.unsafe(nil), Integer) # 1/12 of a gregorian year # -# source://activesupport//lib/active_support/duration.rb#116 +# source://activesupport//lib/active_support/duration.rb#117 ActiveSupport::Duration::SECONDS_PER_MONTH = T.let(T.unsafe(nil), Integer) -# source://activesupport//lib/active_support/duration.rb#115 +# source://activesupport//lib/active_support/duration.rb#116 ActiveSupport::Duration::SECONDS_PER_WEEK = T.let(T.unsafe(nil), Integer) # length of a gregorian year (365.2425 days) # -# source://activesupport//lib/active_support/duration.rb#117 +# source://activesupport//lib/active_support/duration.rb#118 ActiveSupport::Duration::SECONDS_PER_YEAR = T.let(T.unsafe(nil), Integer) -# source://activesupport//lib/active_support/duration.rb#14 +# source://activesupport//lib/active_support/duration.rb#15 class ActiveSupport::Duration::Scalar < ::Numeric # @return [Scalar] a new instance of Scalar # - # source://activesupport//lib/active_support/duration.rb#18 + # source://activesupport//lib/active_support/duration.rb#19 def initialize(value); end - # source://activesupport//lib/active_support/duration.rb#84 + # source://activesupport//lib/active_support/duration.rb#85 def %(other); end - # source://activesupport//lib/active_support/duration.rb#65 + # source://activesupport//lib/active_support/duration.rb#66 def *(other); end - # source://activesupport//lib/active_support/duration.rb#40 + # source://activesupport//lib/active_support/duration.rb#41 def +(other); end - # source://activesupport//lib/active_support/duration.rb#52 + # source://activesupport//lib/active_support/duration.rb#53 def -(other); end - # source://activesupport//lib/active_support/duration.rb#26 + # source://activesupport//lib/active_support/duration.rb#27 def -@; end - # source://activesupport//lib/active_support/duration.rb#76 + # source://activesupport//lib/active_support/duration.rb#77 def /(other); end - # source://activesupport//lib/active_support/duration.rb#30 + # source://activesupport//lib/active_support/duration.rb#31 def <=>(other); end - # source://activesupport//lib/active_support/duration.rb#22 + # source://activesupport//lib/active_support/duration.rb#23 def coerce(other); end - # source://activesupport//lib/active_support/duration.rb#16 + # source://activesupport//lib/active_support/duration.rb#17 def to_f(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/duration.rb#16 + # source://activesupport//lib/active_support/duration.rb#17 def to_i(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/duration.rb#16 + # source://activesupport//lib/active_support/duration.rb#17 def to_s(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute value. # - # source://activesupport//lib/active_support/duration.rb#15 + # source://activesupport//lib/active_support/duration.rb#16 def value; end # @return [Boolean] # - # source://activesupport//lib/active_support/duration.rb#92 + # source://activesupport//lib/active_support/duration.rb#93 def variable?; end private - # source://activesupport//lib/active_support/duration.rb#97 + # source://activesupport//lib/active_support/duration.rb#98 def calculate(op, other); end # @raise [TypeError] # - # source://activesupport//lib/active_support/duration.rb#107 + # source://activesupport//lib/active_support/duration.rb#108 def raise_type_error(other); end end -# source://activesupport//lib/active_support/duration.rb#130 +# source://activesupport//lib/active_support/duration.rb#131 ActiveSupport::Duration::VARIABLE_PARTS = T.let(T.unsafe(nil), Array) # source://activesupport//lib/active_support/core_ext/range/each.rb#6 @@ -4749,6 +5669,8 @@ module ActiveSupport::EachTimeWithZone def ensure_iteration_allowed; end end +# = Encrypted Configuration +# # Provides convenience methods on top of EncryptedFile to access values stored # as encrypted YAML. # @@ -4771,16 +5693,13 @@ end # my_config.foo! # # => KeyError # -# source://activesupport//lib/active_support/encrypted_configuration.rb#32 +# source://activesupport//lib/active_support/encrypted_configuration.rb#35 class ActiveSupport::EncryptedConfiguration < ::ActiveSupport::EncryptedFile # @return [EncryptedConfiguration] a new instance of EncryptedConfiguration # - # source://activesupport//lib/active_support/encrypted_configuration.rb#36 + # source://activesupport//lib/active_support/encrypted_configuration.rb#48 def initialize(config_path:, key_path:, env_key:, raise_if_missing_key:); end - # source://activesupport//lib/active_support/encrypted_configuration.rb#33 - def [](*_arg0, **_arg1, &_arg2); end - # Returns the decrypted content as a Hash with symbolized keys. # # my_config = ActiveSupport::EncryptedConfiguration.new(...) @@ -4789,38 +5708,49 @@ class ActiveSupport::EncryptedConfiguration < ::ActiveSupport::EncryptedFile # my_config.config # # => { some_secret: 123, some_namespace: { another_secret: 789 } } # - # source://activesupport//lib/active_support/encrypted_configuration.rb#63 + # source://activesupport//lib/active_support/encrypted_configuration.rb#75 def config; end - # source://activesupport//lib/active_support/encrypted_configuration.rb#33 - def fetch(*_arg0, **_arg1, &_arg2); end + # source://activesupport//lib/active_support/encrypted_configuration.rb#79 + def inspect; end - # source://activesupport//lib/active_support/core_ext/module/delegation.rb#302 - def method_missing(method, *args, **_arg2, &block); end + # source://activesupport//lib/active_support/delegation.rb#187 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # Reads the file and returns the decrypted content. See EncryptedFile#read. # - # source://activesupport//lib/active_support/encrypted_configuration.rb#42 + # source://activesupport//lib/active_support/encrypted_configuration.rb#56 def read; end - # source://activesupport//lib/active_support/encrypted_configuration.rb#49 - def write(contents); end + # source://activesupport//lib/active_support/encrypted_configuration.rb#63 + def validate!; end private - # source://activesupport//lib/active_support/encrypted_configuration.rb#68 + # source://activesupport//lib/active_support/encrypted_configuration.rb#84 def deep_transform(hash); end - # source://activesupport//lib/active_support/encrypted_configuration.rb#82 - def deserialize(config); end + # source://activesupport//lib/active_support/encrypted_configuration.rb#98 + def deserialize(content); end - # source://activesupport//lib/active_support/encrypted_configuration.rb#78 + # source://activesupport//lib/active_support/encrypted_configuration.rb#94 def options; end - # source://activesupport//lib/active_support/core_ext/module/delegation.rb#294 + # source://activesupport//lib/active_support/delegation.rb#179 def respond_to_missing?(name, include_private = T.unsafe(nil)); end end +# source://activesupport//lib/active_support/encrypted_configuration.rb#36 +class ActiveSupport::EncryptedConfiguration::InvalidContentError < ::RuntimeError + # @return [InvalidContentError] a new instance of InvalidContentError + # + # source://activesupport//lib/active_support/encrypted_configuration.rb#37 + def initialize(content_path); end + + # source://activesupport//lib/active_support/encrypted_configuration.rb#41 + def message; end +end + # source://activesupport//lib/active_support/encrypted_file.rb#8 class ActiveSupport::EncryptedFile # @return [EncryptedFile] a new instance of EncryptedFile @@ -4828,7 +5758,7 @@ class ActiveSupport::EncryptedFile # source://activesupport//lib/active_support/encrypted_file.rb#42 def initialize(content_path:, key_path:, env_key:, raise_if_missing_key:); end - # source://activesupport//lib/active_support/encrypted_file.rb#77 + # source://activesupport//lib/active_support/encrypted_file.rb#83 def change(&block); end # Returns the value of attribute content_path. @@ -4849,6 +5779,14 @@ class ActiveSupport::EncryptedFile # source://activesupport//lib/active_support/encrypted_file.rb#52 def key; end + # Returns truthy if #key is truthy. Returns falsy otherwise. Unlike #key, + # does not raise MissingKeyError when +raise_if_missing_key+ is true. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/encrypted_file.rb#58 + def key?; end + # Returns the value of attribute key_path. # # source://activesupport//lib/active_support/encrypted_file.rb#40 @@ -4868,40 +5806,40 @@ class ActiveSupport::EncryptedFile # - ActiveSupport::MessageEncryptor::InvalidMessage if the content cannot be # decrypted or verified. # - # source://activesupport//lib/active_support/encrypted_file.rb#64 + # source://activesupport//lib/active_support/encrypted_file.rb#70 def read; end - # source://activesupport//lib/active_support/encrypted_file.rb#72 + # source://activesupport//lib/active_support/encrypted_file.rb#78 def write(contents); end private # @raise [InvalidKeyLengthError] # - # source://activesupport//lib/active_support/encrypted_file.rb#125 + # source://activesupport//lib/active_support/encrypted_file.rb#129 def check_key_length; end - # source://activesupport//lib/active_support/encrypted_file.rb#103 + # source://activesupport//lib/active_support/encrypted_file.rb#108 def decrypt(contents); end - # source://activesupport//lib/active_support/encrypted_file.rb#98 + # source://activesupport//lib/active_support/encrypted_file.rb#103 def encrypt(contents); end - # source://activesupport//lib/active_support/encrypted_file.rb#107 + # source://activesupport//lib/active_support/encrypted_file.rb#112 def encryptor; end # @raise [MissingKeyError] # - # source://activesupport//lib/active_support/encrypted_file.rb#121 + # source://activesupport//lib/active_support/encrypted_file.rb#125 def handle_missing_key; end - # source://activesupport//lib/active_support/encrypted_file.rb#112 + # source://activesupport//lib/active_support/encrypted_file.rb#117 def read_env_key; end - # source://activesupport//lib/active_support/encrypted_file.rb#116 + # source://activesupport//lib/active_support/encrypted_file.rb#121 def read_key_file; end - # source://activesupport//lib/active_support/encrypted_file.rb#83 + # source://activesupport//lib/active_support/encrypted_file.rb#89 def writing(contents); end class << self @@ -4957,24 +5895,47 @@ end # source://activesupport//lib/active_support/core_ext/enumerable.rb#25 ActiveSupport::EnumerableCoreExt::SoleItemExpectedError = Enumerable::SoleItemExpectedError -# source://activesupport//lib/active_support/environment_inquirer.rb#6 +# source://activesupport//lib/active_support/environment_inquirer.rb#9 class ActiveSupport::EnvironmentInquirer < ::ActiveSupport::StringInquirer + # @raise [ArgumentError] # @return [EnvironmentInquirer] a new instance of EnvironmentInquirer # - # source://activesupport//lib/active_support/environment_inquirer.rb#8 + # source://activesupport//lib/active_support/environment_inquirer.rb#15 def initialize(env); end + # source://activesupport//lib/active_support/environment_inquirer.rb#29 def development?; end + + # Returns true if we're in the development or test environment. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/environment_inquirer.rb#36 + def local?; end + + # source://activesupport//lib/active_support/environment_inquirer.rb#29 def production?; end + + # source://activesupport//lib/active_support/environment_inquirer.rb#29 def test?; end end -# source://activesupport//lib/active_support/environment_inquirer.rb#7 +# Optimization for the three default environments, so this inquirer doesn't need to rely on +# the slower delegation through method_missing that StringInquirer would normally entail. +# +# source://activesupport//lib/active_support/environment_inquirer.rb#10 ActiveSupport::EnvironmentInquirer::DEFAULT_ENVIRONMENTS = T.let(T.unsafe(nil), Array) +# Environments that'll respond true for #local? +# +# source://activesupport//lib/active_support/environment_inquirer.rb#13 +ActiveSupport::EnvironmentInquirer::LOCAL_ENVIRONMENTS = T.let(T.unsafe(nil), Array) + +# = Active Support \Error Reporter +# # +ActiveSupport::ErrorReporter+ is a common interface for error reporting services. # -# To rescue and report any unhandled error, you can use the +handle+ method: +# To rescue and report any unhandled error, you can use the #handle method: # # Rails.error.handle do # do_something! @@ -4982,94 +5943,206 @@ ActiveSupport::EnvironmentInquirer::DEFAULT_ENVIRONMENTS = T.let(T.unsafe(nil), # # If an error is raised, it will be reported and swallowed. # -# Alternatively if you want to report the error but not swallow it, you can use +record+ +# Alternatively, if you want to report the error but not swallow it, you can use #record: # # Rails.error.record do # do_something! # end # -# Both methods can be restricted to only handle a specific exception class +# Both methods can be restricted to handle only a specific error class: # # maybe_tags = Rails.error.handle(Redis::BaseError) { redis.get("tags") } # -# You can also pass some extra context information that may be used by the error subscribers: -# -# Rails.error.handle(context: { section: "admin" }) do -# # ... -# end -# -# Additionally a +severity+ can be passed along to communicate how important the error report is. -# +severity+ can be one of +:error+, +:warning+, or +:info+. Handled errors default to the +:warning+ -# severity, and unhandled ones to +:error+. -# -# Both +handle+ and +record+ pass through the return value from the block. In the case of +handle+ -# rescuing an error, a fallback can be provided. The fallback must be a callable whose result will -# be returned when the block raises and is handled: -# -# user = Rails.error.handle(fallback: -> { User.anonymous }) do -# User.find_by(params) -# end -# -# source://activesupport//lib/active_support/error_reporter.rb#41 +# source://activesupport//lib/active_support/error_reporter.rb#26 class ActiveSupport::ErrorReporter # @return [ErrorReporter] a new instance of ErrorReporter # - # source://activesupport//lib/active_support/error_reporter.rb#46 - def initialize(*subscribers, logger: T.unsafe(nil)); end - - # Report any unhandled exception, and swallow it. + # source://activesupport//lib/active_support/error_reporter.rb#35 + def initialize(*subscribers, logger: T.unsafe(nil)); end + + # Returns the value of attribute debug_mode. + # + # source://activesupport//lib/active_support/error_reporter.rb#31 + def debug_mode; end + + # Sets the attribute debug_mode + # + # @param value the value to set the attribute debug_mode to. + # + # source://activesupport//lib/active_support/error_reporter.rb#31 + def debug_mode=(_arg0); end + + # Prevent a subscriber from being notified of errors for the + # duration of the block. You may pass in the subscriber itself, or its class. + # + # This can be helpful for error reporting service integrations, when they wish + # to handle any errors higher in the stack. + # + # source://activesupport//lib/active_support/error_reporter.rb#185 + def disable(subscriber); end + + # Evaluates the given block, reporting and swallowing any unhandled error. + # If no error is raised, returns the return value of the block. Otherwise, + # returns the result of +fallback.call+, or +nil+ if +fallback+ is not + # specified. + # + # # Will report a TypeError to all subscribers and return nil. + # Rails.error.handle do + # 1 + '1' + # end + # + # Can be restricted to handle only specific error classes: + # + # maybe_tags = Rails.error.handle(Redis::BaseError) { redis.get("tags") } + # + # ==== Options + # + # * +:severity+ - This value is passed along to subscribers to indicate how + # important the error report is. Can be +:error+, +:warning+, or +:info+. + # Defaults to +:warning+. + # + # * +:context+ - Extra information that is passed along to subscribers. For + # example: + # + # Rails.error.handle(context: { section: "admin" }) do + # # ... + # end + # + # * +:fallback+ - A callable that provides +handle+'s return value when an + # unhandled error is raised. For example: + # + # user = Rails.error.handle(fallback: -> { User.anonymous }) do + # User.find_by(params) + # end # - # Rails.error.handle do - # 1 + '1' - # end + # * +:source+ - This value is passed along to subscribers to indicate the + # source of the error. Subscribers can use this value to ignore certain + # errors. Defaults to "application". # - # source://activesupport//lib/active_support/error_reporter.rb#57 - def handle(error_class = T.unsafe(nil), severity: T.unsafe(nil), context: T.unsafe(nil), fallback: T.unsafe(nil)); end + # source://activesupport//lib/active_support/error_reporter.rb#78 + def handle(*error_classes, severity: T.unsafe(nil), context: T.unsafe(nil), fallback: T.unsafe(nil), source: T.unsafe(nil)); end # Returns the value of attribute logger. # - # source://activesupport//lib/active_support/error_reporter.rb#44 + # source://activesupport//lib/active_support/error_reporter.rb#31 def logger; end # Sets the attribute logger # # @param value the value to set the attribute logger to. # - # source://activesupport//lib/active_support/error_reporter.rb#44 + # source://activesupport//lib/active_support/error_reporter.rb#31 def logger=(_arg0); end - # source://activesupport//lib/active_support/error_reporter.rb#64 - def record(error_class = T.unsafe(nil), severity: T.unsafe(nil), context: T.unsafe(nil)); end + # Evaluates the given block, reporting and re-raising any unhandled error. + # If no error is raised, returns the return value of the block. + # + # # Will report a TypeError to all subscribers and re-raise it. + # Rails.error.record do + # 1 + '1' + # end + # + # Can be restricted to handle only specific error classes: + # + # tags = Rails.error.record(Redis::BaseError) { redis.get("tags") } + # + # ==== Options + # + # * +:severity+ - This value is passed along to subscribers to indicate how + # important the error report is. Can be +:error+, +:warning+, or +:info+. + # Defaults to +:error+. + # + # * +:context+ - Extra information that is passed along to subscribers. For + # example: + # + # Rails.error.record(context: { section: "admin" }) do + # # ... + # end + # + # * +:source+ - This value is passed along to subscribers to indicate the + # source of the error. Subscribers can use this value to ignore certain + # errors. Defaults to "application". + # + # source://activesupport//lib/active_support/error_reporter.rb#114 + def record(*error_classes, severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil)); end - # When the block based +handle+ and +record+ methods are not suitable, you can directly use +report+ + # Report an error directly to subscribers. You can use this method when the + # block-based #handle and #record methods are not suitable. # - # Rails.error.report(error, handled: true) + # Rails.error.report(error) # - # source://activesupport//lib/active_support/error_reporter.rb#95 - def report(error, handled:, severity: T.unsafe(nil), context: T.unsafe(nil)); end + # source://activesupport//lib/active_support/error_reporter.rb#210 + def report(error, handled: T.unsafe(nil), severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil)); end - # Update the execution context that is accessible to error subscribers + # Update the execution context that is accessible to error subscribers. Any + # context passed to #handle, #record, or #report will be merged with the + # context set here. # # Rails.error.set_context(section: "checkout", user_id: @user.id) # - # See +ActiveSupport::ExecutionContext.set+ - # - # source://activesupport//lib/active_support/error_reporter.rb#88 + # source://activesupport//lib/active_support/error_reporter.rb#201 def set_context(*_arg0, **_arg1, &_arg2); end # Register a new error subscriber. The subscriber must respond to # - # report(Exception, handled: Boolean, context: Hash) + # report(Exception, handled: Boolean, severity: (:error OR :warning OR :info), context: Hash, source: String) # - # The +report+ method +should+ never raise an error. + # The +report+ method should never raise an error. # - # source://activesupport//lib/active_support/error_reporter.rb#76 + # source://activesupport//lib/active_support/error_reporter.rb#161 def subscribe(subscriber); end + + # Either report the given error when in production, or raise it when in development or test. + # + # When called in production, after the error is reported, this method will return + # nil and execution will continue. + # + # When called in development, the original error is wrapped in a different error class to ensure + # it's not being rescued higher in the stack and will be surfaced to the developer. + # + # This method is intended for reporting violated assertions about preconditions, or similar + # cases that can and should be gracefully handled in production, but that aren't supposed to happen. + # + # The error can be either an exception instance or a String. + # + # example: + # + # def edit + # if published? + # Rails.error.unexpected("[BUG] Attempting to edit a published article, that shouldn't be possible") + # return false + # end + # # ... + # end + # + # source://activesupport//lib/active_support/error_reporter.rb#145 + def unexpected(error, severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil)); end + + # Unregister an error subscriber. Accepts either a subscriber or a class. + # + # subscriber = MyErrorSubscriber.new + # Rails.error.subscribe(subscriber) + # + # Rails.error.unsubscribe(subscriber) + # # or + # Rails.error.unsubscribe(MyErrorSubscriber) + # + # source://activesupport//lib/active_support/error_reporter.rb#176 + def unsubscribe(subscriber); end end -# source://activesupport//lib/active_support/error_reporter.rb#42 +# source://activesupport//lib/active_support/error_reporter.rb#29 +ActiveSupport::ErrorReporter::DEFAULT_RESCUE = T.let(T.unsafe(nil), Array) + +# source://activesupport//lib/active_support/error_reporter.rb#28 +ActiveSupport::ErrorReporter::DEFAULT_SOURCE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/error_reporter.rb#27 ActiveSupport::ErrorReporter::SEVERITIES = T.let(T.unsafe(nil), Array) +# source://activesupport//lib/active_support/error_reporter.rb#33 +class ActiveSupport::ErrorReporter::UnexpectedError < ::Exception; end + # source://activesupport//lib/active_support/execution_context.rb#4 module ActiveSupport::ExecutionContext class << self @@ -5098,31 +6171,31 @@ module ActiveSupport::ExecutionContext end end -# source://activesupport//lib/active_support/execution_wrapper.rb#8 +# source://activesupport//lib/active_support/execution_wrapper.rb#7 class ActiveSupport::ExecutionWrapper include ::ActiveSupport::Callbacks extend ::ActiveSupport::Callbacks::ClassMethods extend ::ActiveSupport::DescendantsTracker - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport//lib/active_support/callbacks.rb#940 + # source://activesupport//lib/active_support/callbacks.rb#924 def _complete_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#940 + # source://activesupport//lib/active_support/callbacks.rb#924 def _run_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#928 + # source://activesupport//lib/active_support/callbacks.rb#912 def _run_complete_callbacks(&block); end - # source://activesupport//lib/active_support/callbacks.rb#928 + # source://activesupport//lib/active_support/callbacks.rb#912 def _run_run_callbacks(&block); end - # source://activesupport//lib/active_support/execution_wrapper.rb#142 + # source://activesupport//lib/active_support/execution_wrapper.rb#141 def complete; end # Complete this in-flight execution. This method *must* be called @@ -5130,54 +6203,54 @@ class ActiveSupport::ExecutionWrapper # # Where possible, prefer +wrap+. # - # source://activesupport//lib/active_support/execution_wrapper.rb#136 + # source://activesupport//lib/active_support/execution_wrapper.rb#135 def complete!; end - # source://activesupport//lib/active_support/execution_wrapper.rb#128 + # source://activesupport//lib/active_support/execution_wrapper.rb#127 def run; end - # source://activesupport//lib/active_support/execution_wrapper.rb#123 + # source://activesupport//lib/active_support/execution_wrapper.rb#122 def run!; end private - # source://activesupport//lib/active_support/execution_wrapper.rb#147 + # source://activesupport//lib/active_support/execution_wrapper.rb#146 def hook_state; end class << self - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport//lib/active_support/callbacks.rb#932 + # source://activesupport//lib/active_support/callbacks.rb#916 def _complete_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#936 + # source://activesupport//lib/active_support/callbacks.rb#920 def _complete_callbacks=(value); end - # source://activesupport//lib/active_support/callbacks.rb#932 + # source://activesupport//lib/active_support/callbacks.rb#916 def _run_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#936 + # source://activesupport//lib/active_support/callbacks.rb#920 def _run_callbacks=(value); end # @return [Boolean] # - # source://activesupport//lib/active_support/execution_wrapper.rb#119 + # source://activesupport//lib/active_support/execution_wrapper.rb#118 def active?; end - # source://activesupport//lib/active_support/execution_wrapper.rb#115 + # source://activesupport//lib/active_support/execution_wrapper.rb#114 def active_key; end - # source://activesupport//lib/active_support/execution_wrapper.rb#111 + # source://activesupport//lib/active_support/execution_wrapper.rb#110 def error_reporter; end - # source://activesupport//lib/active_support/execution_wrapper.rb#101 + # source://activesupport//lib/active_support/execution_wrapper.rb#100 def perform; end # Register an object to be invoked during both the +run+ and @@ -5189,7 +6262,7 @@ class ActiveSupport::ExecutionWrapper # a preceding +to_run+ block; all ordinary +to_complete+ blocks are # invoked in that situation.) # - # source://activesupport//lib/active_support/execution_wrapper.rb#51 + # source://activesupport//lib/active_support/execution_wrapper.rb#50 def register_hook(hook, outer: T.unsafe(nil)); end # Run this execution. @@ -5199,28 +6272,28 @@ class ActiveSupport::ExecutionWrapper # # Where possible, prefer +wrap+. # - # source://activesupport//lib/active_support/execution_wrapper.rb#67 + # source://activesupport//lib/active_support/execution_wrapper.rb#66 def run!(reset: T.unsafe(nil)); end - # source://activesupport//lib/active_support/execution_wrapper.rb#22 + # source://activesupport//lib/active_support/execution_wrapper.rb#21 def to_complete(*args, &block); end - # source://activesupport//lib/active_support/execution_wrapper.rb#18 + # source://activesupport//lib/active_support/execution_wrapper.rb#17 def to_run(*args, &block); end # Perform the work in the supplied block as an execution. # - # source://activesupport//lib/active_support/execution_wrapper.rb#87 - def wrap; end + # source://activesupport//lib/active_support/execution_wrapper.rb#86 + def wrap(source: T.unsafe(nil)); end end end -# source://activesupport//lib/active_support/execution_wrapper.rb#33 +# source://activesupport//lib/active_support/execution_wrapper.rb#32 class ActiveSupport::ExecutionWrapper::CompleteHook < ::Struct - # source://activesupport//lib/active_support/execution_wrapper.rb#34 + # source://activesupport//lib/active_support/execution_wrapper.rb#33 def after(target); end - # source://activesupport//lib/active_support/execution_wrapper.rb#34 + # source://activesupport//lib/active_support/execution_wrapper.rb#33 def before(target); end # Returns the value of attribute hook @@ -5243,12 +6316,12 @@ class ActiveSupport::ExecutionWrapper::CompleteHook < ::Struct end end -# source://activesupport//lib/active_support/execution_wrapper.rb#11 +# source://activesupport//lib/active_support/execution_wrapper.rb#10 ActiveSupport::ExecutionWrapper::Null = T.let(T.unsafe(nil), Object) -# source://activesupport//lib/active_support/execution_wrapper.rb#26 +# source://activesupport//lib/active_support/execution_wrapper.rb#25 class ActiveSupport::ExecutionWrapper::RunHook < ::Struct - # source://activesupport//lib/active_support/execution_wrapper.rb#27 + # source://activesupport//lib/active_support/execution_wrapper.rb#26 def before(target); end # Returns the value of attribute hook @@ -5274,7 +6347,9 @@ end # source://activesupport//lib/active_support/executor.rb#6 class ActiveSupport::Executor < ::ActiveSupport::ExecutionWrapper; end -# FileUpdateChecker specifies the API used by Rails to watch files +# = \File Update Checker +# +# FileUpdateChecker specifies the API used by \Rails to watch files # and control reloading. The API depends on four methods: # # * +initialize+ which expects two parameters and one block as @@ -5291,7 +6366,7 @@ class ActiveSupport::Executor < ::ActiveSupport::ExecutionWrapper; end # After initialization, a call to +execute_if_updated+ must execute # the block only if there was really a change in the filesystem. # -# This class is used by Rails to reload the I18n framework whenever +# This class is used by \Rails to reload the I18n framework whenever # they are changed upon a new request. # # i18n_reloader = ActiveSupport::FileUpdateChecker.new(paths) do @@ -5302,7 +6377,7 @@ class ActiveSupport::Executor < ::ActiveSupport::ExecutionWrapper; end # i18n_reloader.execute_if_updated # end # -# source://activesupport//lib/active_support/file_update_checker.rb#33 +# source://activesupport//lib/active_support/file_update_checker.rb#35 class ActiveSupport::FileUpdateChecker # It accepts two parameters on initialization. The first is an array # of files and the second is an optional hash of directories. The hash must @@ -5315,18 +6390,18 @@ class ActiveSupport::FileUpdateChecker # # @return [FileUpdateChecker] a new instance of FileUpdateChecker # - # source://activesupport//lib/active_support/file_update_checker.rb#42 + # source://activesupport//lib/active_support/file_update_checker.rb#44 def initialize(files, dirs = T.unsafe(nil), &block); end # Executes the given block and updates the latest watched files and # timestamp. # - # source://activesupport//lib/active_support/file_update_checker.rb#80 + # source://activesupport//lib/active_support/file_update_checker.rb#82 def execute; end # Execute the block given if updated. # - # source://activesupport//lib/active_support/file_update_checker.rb#90 + # source://activesupport//lib/active_support/file_update_checker.rb#92 def execute_if_updated; end # Check if any of the entries were updated. If so, the watched and/or @@ -5335,18 +6410,18 @@ class ActiveSupport::FileUpdateChecker # # @return [Boolean] # - # source://activesupport//lib/active_support/file_update_checker.rb#61 + # source://activesupport//lib/active_support/file_update_checker.rb#63 def updated?; end private - # source://activesupport//lib/active_support/file_update_checker.rb#156 + # source://activesupport//lib/active_support/file_update_checker.rb#158 def compile_ext(array); end - # source://activesupport//lib/active_support/file_update_checker.rb#142 + # source://activesupport//lib/active_support/file_update_checker.rb#144 def compile_glob(hash); end - # source://activesupport//lib/active_support/file_update_checker.rb#152 + # source://activesupport//lib/active_support/file_update_checker.rb#154 def escape(key); end # This method returns the maximum mtime of the files in +paths+, or +nil+ @@ -5357,55 +6432,41 @@ class ActiveSupport::FileUpdateChecker # healthy to consider this edge case because with mtimes in the future # reloading is not triggered. # - # source://activesupport//lib/active_support/file_update_checker.rb#120 + # source://activesupport//lib/active_support/file_update_checker.rb#122 def max_mtime(paths); end - # source://activesupport//lib/active_support/file_update_checker.rb#109 + # source://activesupport//lib/active_support/file_update_checker.rb#111 def updated_at(paths); end - # source://activesupport//lib/active_support/file_update_checker.rb#101 + # source://activesupport//lib/active_support/file_update_checker.rb#103 def watched; end end # source://activesupport//lib/active_support/fork_tracker.rb#4 module ActiveSupport::ForkTracker class << self - # source://activesupport//lib/active_support/fork_tracker.rb#59 + # source://activesupport//lib/active_support/fork_tracker.rb#31 def after_fork(&block); end - # source://activesupport//lib/active_support/fork_tracker.rb#40 - def check!; end + # source://activesupport//lib/active_support/fork_tracker.rb#19 + def after_fork_callback; end - # source://activesupport//lib/active_support/fork_tracker.rb#48 + # source://activesupport//lib/active_support/fork_tracker.rb#27 def hook!; end - # source://activesupport//lib/active_support/fork_tracker.rb#64 + # source://activesupport//lib/active_support/fork_tracker.rb#36 def unregister(callback); end end end -# source://activesupport//lib/active_support/fork_tracker.rb#15 -module ActiveSupport::ForkTracker::CoreExt - # source://activesupport//lib/active_support/fork_tracker.rb#16 - def fork(*_arg0, **_arg1, &_arg2); end -end - -# source://activesupport//lib/active_support/fork_tracker.rb#31 -module ActiveSupport::ForkTracker::CoreExtPrivate - include ::ActiveSupport::ForkTracker::CoreExt - - private - - # source://activesupport//lib/active_support/fork_tracker.rb#16 - def fork(*_arg0, **_arg1, &_arg2); end -end - # source://activesupport//lib/active_support/fork_tracker.rb#5 -module ActiveSupport::ForkTracker::ModernCoreExt +module ActiveSupport::ForkTracker::CoreExt # source://activesupport//lib/active_support/fork_tracker.rb#6 def _fork; end end +# = Active Support \Gzip +# # A convenient wrapper for the zlib standard library that allows # compression/decompression of strings with gzip. # @@ -5415,32 +6476,34 @@ end # ActiveSupport::Gzip.decompress(gzip) # # => "compress me!" # -# source://activesupport//lib/active_support/gzip.rb#15 +# source://activesupport//lib/active_support/gzip.rb#17 module ActiveSupport::Gzip class << self # Compresses a string using gzip. # - # source://activesupport//lib/active_support/gzip.rb#30 + # source://activesupport//lib/active_support/gzip.rb#32 def compress(source, level = T.unsafe(nil), strategy = T.unsafe(nil)); end # Decompresses a gzipped string. # - # source://activesupport//lib/active_support/gzip.rb#25 + # source://activesupport//lib/active_support/gzip.rb#27 def decompress(source); end end end -# source://activesupport//lib/active_support/gzip.rb#16 +# source://activesupport//lib/active_support/gzip.rb#18 class ActiveSupport::Gzip::Stream < ::StringIO # @return [Stream] a new instance of Stream # - # source://activesupport//lib/active_support/gzip.rb#17 + # source://activesupport//lib/active_support/gzip.rb#19 def initialize(*_arg0); end - # source://activesupport//lib/active_support/gzip.rb#21 + # source://activesupport//lib/active_support/gzip.rb#23 def close; end end +# = \Hash With Indifferent Access +# # Implements a hash where keys :foo and "foo" are considered # to be the same. # @@ -5472,7 +6535,7 @@ end # # but this class is intended for use cases where strings or symbols are the # expected keys and it is convenient to understand both as the same. For -# example the +params+ hash in Ruby on Rails. +# example the +params+ hash in Ruby on \Rails. # # Note that core extensions define Hash#with_indifferent_access: # @@ -5480,17 +6543,17 @@ end # # which may be handy. # -# To access this class outside of Rails, require the core extension with: +# To access this class outside of \Rails, require the core extension with: # # require "active_support/core_ext/hash/indifferent_access" # # which will, in turn, require this file. # -# source://activesupport//lib/active_support/hash_with_indifferent_access.rb#53 +# source://activesupport//lib/active_support/hash_with_indifferent_access.rb#55 class ActiveSupport::HashWithIndifferentAccess < ::Hash # @return [HashWithIndifferentAccess] a new instance of HashWithIndifferentAccess # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#68 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#70 def initialize(constructor = T.unsafe(nil)); end # Same as Hash#[] where the key passed as argument can be @@ -5503,7 +6566,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # counters[:foo] # => 1 # counters[:zoo] # => nil # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#166 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#168 def [](key); end # Assigns a new value to the hash: @@ -5513,7 +6576,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # # This value can be later fetched using either +:key+ or 'key'. # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#96 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#98 def []=(key, value); end # Same as Hash#assoc where the key passed as argument can be @@ -5526,19 +6589,19 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # counters.assoc(:foo) # => ["foo", 1] # counters.assoc(:zoo) # => nil # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#179 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#181 def assoc(key); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#357 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#375 def compact; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#311 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#319 def deep_stringify_keys; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#309 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#317 def deep_stringify_keys!; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#316 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#324 def deep_symbolize_keys; end # Same as Hash#default where the key passed as argument can be @@ -5552,12 +6615,12 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash.default('foo') # => 'foo' # hash.default(:foo) # => 'foo' # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#221 - def default(*args); end + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#223 + def default(key = T.unsafe(nil)); end # Removes the specified key from the hash. # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#295 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#303 def delete(key); end # Same as Hash#dig where the key passed as argument can be @@ -5570,7 +6633,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # counters.dig(:foo, :bar) # => 1 # counters.dig(:zoo) # => nil # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#206 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#208 def dig(*args); end # Returns a shallow copy of the hash. @@ -5582,7 +6645,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash[:a][:c] # => "c" # dup[:a][:c] # => "c" # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#256 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#264 def dup; end # Returns a hash with indifferent access that includes everything except given keys. @@ -5590,7 +6653,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash.except(:a, "b") # => {c: 10}.with_indifferent_access # hash # => { a: "x", b: "y", c: 10 }.with_indifferent_access # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#303 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#311 def except(*keys); end # Returns +true+ so that Array#extract_options! finds members of @@ -5598,7 +6661,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # # @return [Boolean] # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#56 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#58 def extractable_options?; end # Same as Hash#fetch where the key passed as argument can be @@ -5612,7 +6675,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # counters.fetch(:bar) { |key| 0 } # => 0 # counters.fetch(:zoo) # => KeyError: key not found: "zoo" # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#193 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#195 def fetch(key, *extras); end # Returns an array of the values at the specified indices, but also @@ -5625,7 +6688,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash.fetch_values('a', 'c') { |key| 'z' } # => ["x", "z"] # hash.fetch_values('a', 'c') # => KeyError: key not found: "c" # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#244 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#251 def fetch_values(*indices, &block); end # Checks the hash for a key matching the argument passed in: @@ -5637,7 +6700,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # # @return [Boolean] # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#149 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#151 def has_key?(key); end # Checks the hash for a key matching the argument passed in: @@ -5649,7 +6712,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # # @return [Boolean] # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#149 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#151 def include?(key); end # Checks the hash for a key matching the argument passed in: @@ -5661,7 +6724,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # # @return [Boolean] # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#149 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#151 def key?(key); end # Checks the hash for a key matching the argument passed in: @@ -5673,14 +6736,14 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # # @return [Boolean] # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#149 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#151 def member?(key); end # This method has the same semantics of +update+, except it does not # modify the receiver but rather returns a new hash with indifferent # access with the result of the merge. # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#265 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#273 def merge(*hashes, &block); end # Updates the receiver in-place, merging in the hashes passed as arguments: @@ -5697,7 +6760,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash.update({ "a" => 1 }, { "b" => 2 }) # => { "a" => 1, "b" => 2 } # # The arguments can be either an - # ActiveSupport::HashWithIndifferentAccess or a regular +Hash+. + # +ActiveSupport::HashWithIndifferentAccess+ or a regular +Hash+. # In either case the merge respects the semantics of indifferent access. # # If the argument is a regular hash with keys +:key+ and "key" only one @@ -5712,16 +6775,16 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash_2['key'] = 12 # hash_1.update(hash_2) { |key, old, new| old + new } # => {"key"=>22} # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#130 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#132 def merge!(*other_hashes, &block); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#64 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#66 def nested_under_indifferent_access; end def regular_update(*_arg0); end def regular_writer(_arg0, _arg1); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#324 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#332 def reject(*args, &block); end # Replaces the contents of this hash with other_hash. @@ -5729,7 +6792,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # h = { "a" => 100, "b" => 200 } # h.replace({ "c" => 300, "d" => 400 }) # => {"c"=>300, "d"=>400} # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#290 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#298 def replace(other_hash); end # Like +merge+ but the other way around: Merges the receiver into the @@ -5739,21 +6802,21 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash['a'] = nil # hash.reverse_merge(a: 0, b: 1) # => {"a"=>nil, "b"=>1} # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#275 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#283 def reverse_merge(other_hash); end # Same semantics as +reverse_merge+ but modifies the receiver in-place. # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#281 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#289 def reverse_merge!(other_hash); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#319 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#327 def select(*args, &block); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#347 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#365 def slice(*keys); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#352 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#370 def slice!(*keys); end # Assigns a new value to the hash: @@ -5763,37 +6826,40 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # # This value can be later fetched using either +:key+ or 'key'. # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#96 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#98 def store(key, value); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#310 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#318 def stringify_keys; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#308 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#316 def stringify_keys!; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#314 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#322 def symbolize_keys; end # Convert to a regular hash with string keys. # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#362 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#380 def to_hash; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#314 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#322 def to_options; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#317 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#325 def to_options!; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#334 - def transform_keys(*args, &block); end + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#390 + def to_proc; end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#339 - def transform_keys!; end + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#344 + def transform_keys(hash = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#329 - def transform_values(*args, &block); end + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#349 + def transform_keys!(hash = T.unsafe(nil), &block); end + + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#337 + def transform_values(&block); end # Updates the receiver in-place, merging in the hashes passed as arguments: # @@ -5809,7 +6875,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash.update({ "a" => 1 }, { "b" => 2 }) # => { "a" => 1, "b" => 2 } # # The arguments can be either an - # ActiveSupport::HashWithIndifferentAccess or a regular +Hash+. + # +ActiveSupport::HashWithIndifferentAccess+ or a regular +Hash+. # In either case the merge respects the semantics of indifferent access. # # If the argument is a regular hash with keys +:key+ and "key" only one @@ -5824,7 +6890,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash_2['key'] = 12 # hash_1.update(hash_2) { |key, old, new| old + new } # => {"key"=>22} # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#130 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#132 def update(*other_hashes, &block); end # Returns an array of the values at the specified indices: @@ -5834,7 +6900,7 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash[:b] = 'y' # hash.values_at('a', 'b') # => ["x", "y"] # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#231 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#237 def values_at(*keys); end # Like +merge+ but the other way around: Merges the receiver into the @@ -5844,15 +6910,15 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash['a'] = nil # hash.reverse_merge(a: 0, b: 1) # => {"a"=>nil, "b"=>1} # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#275 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#283 def with_defaults(other_hash); end # Same semantics as +reverse_merge+ but modifies the receiver in-place. # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#281 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#289 def with_defaults!(other_hash); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#60 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#62 def with_indifferent_access; end # Returns a hash with indifferent access that includes everything except given keys. @@ -5860,61 +6926,66 @@ class ActiveSupport::HashWithIndifferentAccess < ::Hash # hash.except(:a, "b") # => {c: 10}.with_indifferent_access # hash # => { a: "x", b: "y", c: 10 }.with_indifferent_access # - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#303 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#311 def without(*keys); end private - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#374 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#395 def convert_key(key); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#383 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#399 def convert_value(value, conversion: T.unsafe(nil)); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#400 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#416 def set_defaults(target); end - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#408 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#424 def update_with_single_argument(other_hash, block); end class << self - # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#83 + # source://activesupport//lib/active_support/hash_with_indifferent_access.rb#85 def [](*args); end end end +# source://activesupport//lib/active_support/hash_with_indifferent_access.rb#342 +ActiveSupport::HashWithIndifferentAccess::NOT_GIVEN = T.let(T.unsafe(nil), Object) + # source://activesupport//lib/active_support/html_safe_translation.rb#4 module ActiveSupport::HtmlSafeTranslation extend ::ActiveSupport::HtmlSafeTranslation + # @return [Boolean] + # + # source://activesupport//lib/active_support/html_safe_translation.rb#30 + def html_safe_translation_key?(key); end + # source://activesupport//lib/active_support/html_safe_translation.rb#7 def translate(key, **options); end private - # source://activesupport//lib/active_support/html_safe_translation.rb#22 + # source://activesupport//lib/active_support/html_safe_translation.rb#35 def html_escape_translation_options(options); end - # source://activesupport//lib/active_support/html_safe_translation.rb#35 + # source://activesupport//lib/active_support/html_safe_translation.rb#48 def html_safe_translation(translation); end # @return [Boolean] # - # source://activesupport//lib/active_support/html_safe_translation.rb#18 - def html_safe_translation_key?(key); end - - # @return [Boolean] - # - # source://activesupport//lib/active_support/html_safe_translation.rb#30 + # source://activesupport//lib/active_support/html_safe_translation.rb#43 def i18n_option?(name); end end +# = Active Support \Inflector +# # The Inflector transforms words from singular to plural, class names to table # names, modularized class names to ones without, and class names to foreign # keys. The default inflections for pluralization, singularization, and # uncountable words are kept in inflections.rb. # -# The Rails core team has stated patches for the inflections library will not +# The \Rails core team has stated patches for the inflections library will not # be accepted in order to avoid breaking legacy applications which may be # relying on errant inflections. If you discover an incorrect inflection and # require it for your application or wish to define rules for languages other @@ -5941,10 +7012,10 @@ module ActiveSupport::Inflector # # camelize(underscore('SSLError')) # => "SslError" # - # source://activesupport//lib/active_support/inflector/methods.rb#69 + # source://activesupport//lib/active_support/inflector/methods.rb#70 def camelize(term, uppercase_first_letter = T.unsafe(nil)); end - # Creates a class name from a plural table name like Rails does for table + # Creates a class name from a plural table name like \Rails does for table # names to models. Note that this returns a string and not a Class. (To # convert to an actual class follow +classify+ with #constantize.) # @@ -5955,7 +7026,7 @@ module ActiveSupport::Inflector # # classify('calculus') # => "Calculu" # - # source://activesupport//lib/active_support/inflector/methods.rb#208 + # source://activesupport//lib/active_support/inflector/methods.rb#218 def classify(table_name); end # Tries to find a constant with the name specified in the argument string. @@ -5977,14 +7048,14 @@ module ActiveSupport::Inflector # NameError is raised when the name is not in CamelCase or the constant is # unknown. # - # source://activesupport//lib/active_support/inflector/methods.rb#279 + # source://activesupport//lib/active_support/inflector/methods.rb#289 def constantize(camel_cased_word); end # Replaces underscores with dashes in the string. # # dasherize('puni_puni') # => "puni-puni" # - # source://activesupport//lib/active_support/inflector/methods.rb#216 + # source://activesupport//lib/active_support/inflector/methods.rb#226 def dasherize(underscored_word); end # Removes the rightmost segment from the constant expression in the string. @@ -5997,7 +7068,7 @@ module ActiveSupport::Inflector # # See also #demodulize. # - # source://activesupport//lib/active_support/inflector/methods.rb#246 + # source://activesupport//lib/active_support/inflector/methods.rb#256 def deconstantize(path); end # Removes the module part from the expression in the string. @@ -6009,9 +7080,18 @@ module ActiveSupport::Inflector # # See also #deconstantize. # - # source://activesupport//lib/active_support/inflector/methods.rb#228 + # source://activesupport//lib/active_support/inflector/methods.rb#238 def demodulize(path); end + # Converts the first character in the string to lowercase. + # + # downcase_first('If they enjoyed The Matrix') # => "if they enjoyed The Matrix" + # downcase_first('I') # => "i" + # downcase_first('') # => "" + # + # source://activesupport//lib/active_support/inflector/methods.rb#175 + def downcase_first(string); end + # Creates a foreign key name from a class name. # +separate_class_name_and_id_with_underscore+ sets whether # the method should put '_' between the name and 'id'. @@ -6020,7 +7100,7 @@ module ActiveSupport::Inflector # foreign_key('Message', false) # => "messageid" # foreign_key('Admin::Post') # => "post_id" # - # source://activesupport//lib/active_support/inflector/methods.rb#257 + # source://activesupport//lib/active_support/inflector/methods.rb#267 def foreign_key(class_name, separate_class_name_and_id_with_underscore = T.unsafe(nil)); end # Tweaks an attribute name for display to end users. @@ -6049,7 +7129,7 @@ module ActiveSupport::Inflector # # humanize('ssl_error') # => "SSL error" # - # source://activesupport//lib/active_support/inflector/methods.rb#132 + # source://activesupport//lib/active_support/inflector/methods.rb#135 def humanize(lower_case_and_underscored_word, capitalize: T.unsafe(nil), keep_id_suffix: T.unsafe(nil)); end # Yields a singleton instance of Inflector::Inflections so you can specify @@ -6061,7 +7141,7 @@ module ActiveSupport::Inflector # inflect.uncountable 'rails' # end # - # source://activesupport//lib/active_support/inflector/inflections.rb#263 + # source://activesupport//lib/active_support/inflector/inflections.rb#265 def inflections(locale = T.unsafe(nil)); end # Returns the suffix that should be added to a number to denote the position @@ -6074,7 +7154,7 @@ module ActiveSupport::Inflector # ordinal(-11) # => "th" # ordinal(-1021) # => "st" # - # source://activesupport//lib/active_support/inflector/methods.rb#324 + # source://activesupport//lib/active_support/inflector/methods.rb#334 def ordinal(number); end # Turns a number into an ordinal string used to denote the position in an @@ -6087,7 +7167,7 @@ module ActiveSupport::Inflector # ordinalize(-11) # => "-11th" # ordinalize(-1021) # => "-1021st" # - # source://activesupport//lib/active_support/inflector/methods.rb#337 + # source://activesupport//lib/active_support/inflector/methods.rb#347 def ordinalize(number); end # Replaces special characters in a string so that it may be used as part of @@ -6117,7 +7197,7 @@ module ActiveSupport::Inflector # By default, this parameter is set to nil and it will use # the configured I18n.locale. # - # source://activesupport//lib/active_support/inflector/transliterate.rb#121 + # source://activesupport//lib/active_support/inflector/transliterate.rb#123 def parameterize(string, separator: T.unsafe(nil), preserve_case: T.unsafe(nil), locale: T.unsafe(nil)); end # Returns the plural form of the word in the string. @@ -6133,7 +7213,7 @@ module ActiveSupport::Inflector # pluralize('CamelOctopus') # => "CamelOctopi" # pluralize('ley', :es) # => "leyes" # - # source://activesupport//lib/active_support/inflector/methods.rb#32 + # source://activesupport//lib/active_support/inflector/methods.rb#33 def pluralize(word, locale = T.unsafe(nil)); end # Tries to find a constant with the name specified in the argument string. @@ -6159,7 +7239,7 @@ module ActiveSupport::Inflector # safe_constantize('UnknownModule') # => nil # safe_constantize('UnknownModule::Foo::Bar') # => nil # - # source://activesupport//lib/active_support/inflector/methods.rb#305 + # source://activesupport//lib/active_support/inflector/methods.rb#315 def safe_constantize(camel_cased_word); end # The reverse of #pluralize, returns the singular form of a word in a @@ -6176,36 +7256,34 @@ module ActiveSupport::Inflector # singularize('CamelOctopi') # => "CamelOctopus" # singularize('leyes', :es) # => "ley" # - # source://activesupport//lib/active_support/inflector/methods.rb#49 + # source://activesupport//lib/active_support/inflector/methods.rb#50 def singularize(word, locale = T.unsafe(nil)); end - # Creates the name of a table like Rails does for models to table names. + # Creates the name of a table like \Rails does for models to table names. # This method uses the #pluralize method on the last word in the string. # # tableize('RawScaledScorer') # => "raw_scaled_scorers" # tableize('ham_and_egg') # => "ham_and_eggs" # tableize('fancyCategory') # => "fancy_categories" # - # source://activesupport//lib/active_support/inflector/methods.rb#194 + # source://activesupport//lib/active_support/inflector/methods.rb#204 def tableize(class_name); end # Capitalizes all the words and replaces some characters in the string to # create a nicer looking title. +titleize+ is meant for creating pretty - # output. It is not used in the Rails internals. + # output. It is not used in the \Rails internals. # # The trailing '_id','Id'.. can be kept and capitalized by setting the # optional parameter +keep_id_suffix+ to true. # By default, this parameter is false. # - # +titleize+ is also aliased as +titlecase+. - # # titleize('man from the boondocks') # => "Man From The Boondocks" # titleize('x-men: the last stand') # => "X Men: The Last Stand" # titleize('TheManWithoutAPast') # => "The Man Without A Past" # titleize('raiders_of_the_lost_ark') # => "Raiders Of The Lost Ark" # titleize('string_ending_with_id', keep_id_suffix: true) # => "String Ending With Id" # - # source://activesupport//lib/active_support/inflector/methods.rb#182 + # source://activesupport//lib/active_support/inflector/methods.rb#192 def titleize(word, keep_id_suffix: T.unsafe(nil)); end # Replaces non-ASCII characters with an ASCII approximation, or if none @@ -6280,16 +7358,16 @@ module ActiveSupport::Inflector # # camelize(underscore('SSLError')) # => "SslError" # - # source://activesupport//lib/active_support/inflector/methods.rb#96 + # source://activesupport//lib/active_support/inflector/methods.rb#99 def underscore(camel_cased_word); end - # Converts just the first character to uppercase. + # Converts the first character in the string to uppercase. # # upcase_first('what a Lovely Day') # => "What a Lovely Day" # upcase_first('w') # => "W" # upcase_first('') # => "" # - # source://activesupport//lib/active_support/inflector/methods.rb#163 + # source://activesupport//lib/active_support/inflector/methods.rb#166 def upcase_first(string); end private @@ -6302,7 +7380,7 @@ module ActiveSupport::Inflector # apply_inflections('post', inflections.plurals, :en) # => "posts" # apply_inflections('posts', inflections.singulars, :en) # => "post" # - # source://activesupport//lib/active_support/inflector/methods.rb#366 + # source://activesupport//lib/active_support/inflector/methods.rb#376 def apply_inflections(word, rules, locale = T.unsafe(nil)); end # Mounts a regular expression, returned as a string to ease interpolation, @@ -6311,13 +7389,15 @@ module ActiveSupport::Inflector # const_regexp("Foo::Bar::Baz") # => "Foo(::Bar(::Baz)?)?" # const_regexp("::") # => "::" # - # source://activesupport//lib/active_support/inflector/methods.rb#347 + # source://activesupport//lib/active_support/inflector/methods.rb#357 def const_regexp(camel_cased_word); end end # source://activesupport//lib/active_support/inflector/transliterate.rb#8 ActiveSupport::Inflector::ALLOWED_ENCODINGS_FOR_TRANSLITERATE = T.let(T.unsafe(nil), Array) +# = Active Support \Inflections +# # A singleton instance of this class is yielded by Inflector.inflections, # which can then be used to specify additional inflection rules. If passed # an optional locale, rules for other languages can be specified. The @@ -6337,11 +7417,11 @@ ActiveSupport::Inflector::ALLOWED_ENCODINGS_FOR_TRANSLITERATE = T.let(T.unsafe(n # singularization rules that is runs. This guarantees that your rules run # before any of the rules that may already have been loaded. # -# source://activesupport//lib/active_support/inflector/inflections.rb#28 +# source://activesupport//lib/active_support/inflector/inflections.rb#30 class ActiveSupport::Inflector::Inflections # @return [Inflections] a new instance of Inflections # - # source://activesupport//lib/active_support/inflector/inflections.rb#78 + # source://activesupport//lib/active_support/inflector/inflections.rb#80 def initialize; end # Specifies a new acronym. An acronym must be specified as it will appear @@ -6394,18 +7474,18 @@ class ActiveSupport::Inflector::Inflections # underscore 'McDonald' # => 'mcdonald' # camelize 'mcdonald' # => 'McDonald' # - # source://activesupport//lib/active_support/inflector/inflections.rb#140 + # source://activesupport//lib/active_support/inflector/inflections.rb#142 def acronym(word); end # Returns the value of attribute acronyms. # - # source://activesupport//lib/active_support/inflector/inflections.rb#74 + # source://activesupport//lib/active_support/inflector/inflections.rb#76 def acronyms; end - # source://activesupport//lib/active_support/inflector/inflections.rb#76 + # source://activesupport//lib/active_support/inflector/inflections.rb#78 def acronyms_camelize_regex; end - # source://activesupport//lib/active_support/inflector/inflections.rb#76 + # source://activesupport//lib/active_support/inflector/inflections.rb#78 def acronyms_underscore_regex; end # Clears the loaded inflections within a given scope (default is @@ -6416,7 +7496,7 @@ class ActiveSupport::Inflector::Inflections # clear :all # clear :plurals # - # source://activesupport//lib/active_support/inflector/inflections.rb#229 + # source://activesupport//lib/active_support/inflector/inflections.rb#231 def clear(scope = T.unsafe(nil)); end # Specifies a humanized form of a string by a regular expression rule or @@ -6428,12 +7508,12 @@ class ActiveSupport::Inflector::Inflections # human /_cnt$/i, '\1_count' # human 'legacy_col_person_name', 'Name' # - # source://activesupport//lib/active_support/inflector/inflections.rb#218 + # source://activesupport//lib/active_support/inflector/inflections.rb#220 def human(rule, replacement); end # Returns the value of attribute humans. # - # source://activesupport//lib/active_support/inflector/inflections.rb#74 + # source://activesupport//lib/active_support/inflector/inflections.rb#76 def humans; end # Specifies a new irregular that applies to both pluralization and @@ -6444,7 +7524,7 @@ class ActiveSupport::Inflector::Inflections # irregular 'cactus', 'cacti' # irregular 'person', 'people' # - # source://activesupport//lib/active_support/inflector/inflections.rb#172 + # source://activesupport//lib/active_support/inflector/inflections.rb#174 def irregular(singular, plural); end # Specifies a new pluralization rule and its replacement. The rule can @@ -6452,12 +7532,12 @@ class ActiveSupport::Inflector::Inflections # always be a string that may include references to the matched data from # the rule. # - # source://activesupport//lib/active_support/inflector/inflections.rb#149 + # source://activesupport//lib/active_support/inflector/inflections.rb#151 def plural(rule, replacement); end # Returns the value of attribute plurals. # - # source://activesupport//lib/active_support/inflector/inflections.rb#74 + # source://activesupport//lib/active_support/inflector/inflections.rb#76 def plurals; end # Specifies a new singularization rule and its replacement. The rule can @@ -6465,12 +7545,12 @@ class ActiveSupport::Inflector::Inflections # always be a string that may include references to the matched data from # the rule. # - # source://activesupport//lib/active_support/inflector/inflections.rb#159 + # source://activesupport//lib/active_support/inflector/inflections.rb#161 def singular(rule, replacement); end # Returns the value of attribute singulars. # - # source://activesupport//lib/active_support/inflector/inflections.rb#74 + # source://activesupport//lib/active_support/inflector/inflections.rb#76 def singulars; end # Specifies words that are uncountable and should not be inflected. @@ -6479,60 +7559,62 @@ class ActiveSupport::Inflector::Inflections # uncountable 'money', 'information' # uncountable %w( money information rice ) # - # source://activesupport//lib/active_support/inflector/inflections.rb#206 + # source://activesupport//lib/active_support/inflector/inflections.rb#208 def uncountable(*words); end # Returns the value of attribute uncountables. # - # source://activesupport//lib/active_support/inflector/inflections.rb#74 + # source://activesupport//lib/active_support/inflector/inflections.rb#76 def uncountables; end private - # source://activesupport//lib/active_support/inflector/inflections.rb#248 + # source://activesupport//lib/active_support/inflector/inflections.rb#250 def define_acronym_regex_patterns; end # Private, for the test suite. # - # source://activesupport//lib/active_support/inflector/inflections.rb#84 + # source://activesupport//lib/active_support/inflector/inflections.rb#86 def initialize_dup(orig); end class << self - # source://activesupport//lib/active_support/inflector/inflections.rb#63 + # source://activesupport//lib/active_support/inflector/inflections.rb#65 def instance(locale = T.unsafe(nil)); end - # source://activesupport//lib/active_support/inflector/inflections.rb#67 + # source://activesupport//lib/active_support/inflector/inflections.rb#69 def instance_or_fallback(locale); end end end -# source://activesupport//lib/active_support/inflector/inflections.rb#31 +# source://activesupport//lib/active_support/inflector/inflections.rb#33 class ActiveSupport::Inflector::Inflections::Uncountables < ::Array # @return [Uncountables] a new instance of Uncountables # - # source://activesupport//lib/active_support/inflector/inflections.rb#32 + # source://activesupport//lib/active_support/inflector/inflections.rb#34 def initialize; end - # source://activesupport//lib/active_support/inflector/inflections.rb#42 + # source://activesupport//lib/active_support/inflector/inflections.rb#44 def <<(*word); end - # source://activesupport//lib/active_support/inflector/inflections.rb#46 + # source://activesupport//lib/active_support/inflector/inflections.rb#48 def add(words); end - # source://activesupport//lib/active_support/inflector/inflections.rb#37 + # source://activesupport//lib/active_support/inflector/inflections.rb#39 def delete(entry); end # @return [Boolean] # - # source://activesupport//lib/active_support/inflector/inflections.rb#53 + # source://activesupport//lib/active_support/inflector/inflections.rb#55 def uncountable?(str); end private - # source://activesupport//lib/active_support/inflector/inflections.rb#58 + # source://activesupport//lib/active_support/inflector/inflections.rb#60 def to_regex(string); end end +# = Inheritable Options +# # +InheritableOptions+ provides a constructor to build an OrderedOptions # hash inherited from another hash. # @@ -6542,30 +7624,74 @@ end # h.girl # => 'Mary' # h.boy # => 'John' # -# source://activesupport//lib/active_support/ordered_options.rb#79 +# If the existing hash has string keys, call Hash#symbolize_keys on it. +# +# h = ActiveSupport::InheritableOptions.new({ 'girl' => 'Mary', 'boy' => 'John' }.symbolize_keys) +# h.girl # => 'Mary' +# h.boy # => 'John' +# +# source://activesupport//lib/active_support/ordered_options.rb#89 class ActiveSupport::InheritableOptions < ::ActiveSupport::OrderedOptions # @return [InheritableOptions] a new instance of InheritableOptions # - # source://activesupport//lib/active_support/ordered_options.rb#80 + # source://activesupport//lib/active_support/ordered_options.rb#90 def initialize(parent = T.unsafe(nil)); end - # source://activesupport//lib/active_support/ordered_options.rb#91 + # source://activesupport//lib/active_support/ordered_options.rb#107 + def ==(other); end + + # source://activesupport//lib/active_support/ordered_options.rb#142 + def each(&block); end + + # source://activesupport//lib/active_support/ordered_options.rb#134 def inheritable_copy; end + + # source://activesupport//lib/active_support/ordered_options.rb#111 + def inspect; end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/ordered_options.rb#126 + def key?(key); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/ordered_options.rb#130 + def overridden?(key); end + + # source://activesupport//lib/active_support/ordered_options.rb#119 + def pretty_print(pp); end + + # source://activesupport//lib/active_support/ordered_options.rb#138 + def to_a; end + + # source://activesupport//lib/active_support/ordered_options.rb#103 + def to_h; end + + # source://activesupport//lib/active_support/ordered_options.rb#115 + def to_s; end + + private + + def own_key?(_arg0); end end # source://activesupport//lib/active_support/isolated_execution_state.rb#6 module ActiveSupport::IsolatedExecutionState class << self - # source://activesupport//lib/active_support/isolated_execution_state.rb#32 + # source://activesupport//lib/active_support/isolated_execution_state.rb#37 def [](key); end - # source://activesupport//lib/active_support/isolated_execution_state.rb#36 + # source://activesupport//lib/active_support/isolated_execution_state.rb#41 def []=(key, value); end - # source://activesupport//lib/active_support/isolated_execution_state.rb#48 + # source://activesupport//lib/active_support/isolated_execution_state.rb#53 def clear; end - # source://activesupport//lib/active_support/isolated_execution_state.rb#44 + # source://activesupport//lib/active_support/isolated_execution_state.rb#57 + def context; end + + # source://activesupport//lib/active_support/isolated_execution_state.rb#49 def delete(key); end # Returns the value of attribute isolation_level. @@ -6578,25 +7704,24 @@ module ActiveSupport::IsolatedExecutionState # @return [Boolean] # - # source://activesupport//lib/active_support/isolated_execution_state.rb#40 + # source://activesupport//lib/active_support/isolated_execution_state.rb#45 def key?(key); end - # source://activesupport//lib/active_support/isolated_execution_state.rb#52 + # Returns the value of attribute scope. + # + # source://activesupport//lib/active_support/isolated_execution_state.rb#13 + def scope; end + + # source://activesupport//lib/active_support/isolated_execution_state.rb#61 def share_with(other); end - # source://activesupport//lib/active_support/isolated_execution_state.rb#28 + # source://activesupport//lib/active_support/isolated_execution_state.rb#33 def unique_id; end private - # source://activesupport//lib/active_support/isolated_execution_state.rb#61 - def current; end - - # source://activesupport//lib/active_support/isolated_execution_state.rb#65 - def current_fiber; end - - # source://activesupport//lib/active_support/isolated_execution_state.rb#61 - def current_thread; end + # source://activesupport//lib/active_support/isolated_execution_state.rb#69 + def state; end end end @@ -6612,14 +7737,20 @@ module ActiveSupport::JSON # source://activesupport//lib/active_support/json/decoding.rb#22 def decode(json); end - # Dumps objects in JSON (JavaScript Object Notation). + # source://activesupport//lib/active_support/json/encoding.rb#22 + def dump(value, options = T.unsafe(nil)); end + + # source://activesupport//lib/active_support/json/encoding.rb#22 + def encode(value, options = T.unsafe(nil)); end + + # Parses a JSON string (JavaScript Object Notation) into a hash. # See http://www.json.org for more info. # - # ActiveSupport::JSON.encode({ team: 'rails', players: '36' }) - # # => "{\"team\":\"rails\",\"players\":\"36\"}" + # ActiveSupport::JSON.decode("{\"team\":\"rails\",\"players\":\"36\"}") + # => {"team" => "rails", "players" => "36"} # - # source://activesupport//lib/active_support/json/encoding.rb#21 - def encode(value, options = T.unsafe(nil)); end + # source://activesupport//lib/active_support/json/decoding.rb#22 + def load(json); end # Returns the class of the error that will be raised when there is an # error in decoding JSON. Using this method means you won't directly @@ -6632,12 +7763,12 @@ module ActiveSupport::JSON # Rails.logger.warn("Attempted to decode invalid JSON: #{some_string}") # end # - # source://activesupport//lib/active_support/json/decoding.rb#42 + # source://activesupport//lib/active_support/json/decoding.rb#43 def parse_error; end private - # source://activesupport//lib/active_support/json/decoding.rb#47 + # source://activesupport//lib/active_support/json/decoding.rb#48 def convert_dates_from(data); end end end @@ -6650,80 +7781,80 @@ ActiveSupport::JSON::DATETIME_REGEX = T.let(T.unsafe(nil), Regexp) # source://activesupport//lib/active_support/json/decoding.rb#13 ActiveSupport::JSON::DATE_REGEX = T.let(T.unsafe(nil), Regexp) -# source://activesupport//lib/active_support/json/encoding.rb#25 +# source://activesupport//lib/active_support/json/encoding.rb#28 module ActiveSupport::JSON::Encoding class << self # If true, encode >, <, & as escaped unicode sequences (e.g. > as \u003e) # as a safety measure. # - # source://activesupport//lib/active_support/json/encoding.rb#121 + # source://activesupport//lib/active_support/json/encoding.rb#103 def escape_html_entities_in_json; end # If true, encode >, <, & as escaped unicode sequences (e.g. > as \u003e) # as a safety measure. # - # source://activesupport//lib/active_support/json/encoding.rb#121 + # source://activesupport//lib/active_support/json/encoding.rb#103 def escape_html_entities_in_json=(_arg0); end - # Sets the encoder used by Rails to encode Ruby objects into JSON strings + # Sets the encoder used by \Rails to encode Ruby objects into JSON strings # in +Object#to_json+ and +ActiveSupport::JSON.encode+. # - # source://activesupport//lib/active_support/json/encoding.rb#129 + # source://activesupport//lib/active_support/json/encoding.rb#111 def json_encoder; end - # Sets the encoder used by Rails to encode Ruby objects into JSON strings + # Sets the encoder used by \Rails to encode Ruby objects into JSON strings # in +Object#to_json+ and +ActiveSupport::JSON.encode+. # - # source://activesupport//lib/active_support/json/encoding.rb#129 + # source://activesupport//lib/active_support/json/encoding.rb#111 def json_encoder=(_arg0); end # Sets the precision of encoded time values. # Defaults to 3 (equivalent to millisecond precision) # - # source://activesupport//lib/active_support/json/encoding.rb#125 + # source://activesupport//lib/active_support/json/encoding.rb#107 def time_precision; end # Sets the precision of encoded time values. # Defaults to 3 (equivalent to millisecond precision) # - # source://activesupport//lib/active_support/json/encoding.rb#125 + # source://activesupport//lib/active_support/json/encoding.rb#107 def time_precision=(_arg0); end # If true, use ISO 8601 format for dates and times. Otherwise, fall back # to the Active Support legacy format. # - # source://activesupport//lib/active_support/json/encoding.rb#117 + # source://activesupport//lib/active_support/json/encoding.rb#99 def use_standard_json_time_format; end # If true, use ISO 8601 format for dates and times. Otherwise, fall back # to the Active Support legacy format. # - # source://activesupport//lib/active_support/json/encoding.rb#117 + # source://activesupport//lib/active_support/json/encoding.rb#99 def use_standard_json_time_format=(_arg0); end end end -# source://activesupport//lib/active_support/json/encoding.rb#26 +# source://activesupport//lib/active_support/json/encoding.rb#29 class ActiveSupport::JSON::Encoding::JSONGemEncoder # @return [JSONGemEncoder] a new instance of JSONGemEncoder # - # source://activesupport//lib/active_support/json/encoding.rb#29 + # source://activesupport//lib/active_support/json/encoding.rb#32 def initialize(options = T.unsafe(nil)); end # Encode the given object into a JSON string # - # source://activesupport//lib/active_support/json/encoding.rb#34 + # source://activesupport//lib/active_support/json/encoding.rb#37 def encode(value); end # Returns the value of attribute options. # - # source://activesupport//lib/active_support/json/encoding.rb#27 + # source://activesupport//lib/active_support/json/encoding.rb#30 def options; end private # Convert an object into a "JSON-ready" representation composed of - # primitives like Hash, Array, String, Numeric, + # primitives like Hash, Array, String, Symbol, Numeric, # and +true+/+false+/+nil+. # Recursively calls #as_json to the object to recursively build a # fully JSON-ready object. @@ -6736,72 +7867,55 @@ class ActiveSupport::JSON::Encoding::JSONGemEncoder # to +object.as_json+, not any of this method's recursive +#as_json+ # calls. # - # source://activesupport//lib/active_support/json/encoding.rb#89 + # source://activesupport//lib/active_support/json/encoding.rb#70 def jsonify(value); end # Encode a "jsonified" Ruby data structure using the JSON gem # - # source://activesupport//lib/active_support/json/encoding.rb#109 + # source://activesupport//lib/active_support/json/encoding.rb#91 def stringify(jsonified); end end -# Rails does more escaping than the JSON gem natively does (we -# escape \u2028 and \u2029 and optionally >, <, & to work around -# certain browser problems). +# = Key Generator # -# source://activesupport//lib/active_support/json/encoding.rb#42 -ActiveSupport::JSON::Encoding::JSONGemEncoder::ESCAPED_CHARS = T.let(T.unsafe(nil), Hash) - -# source://activesupport//lib/active_support/json/encoding.rb#51 -ActiveSupport::JSON::Encoding::JSONGemEncoder::ESCAPE_REGEX_WITHOUT_HTML_ENTITIES = T.let(T.unsafe(nil), Regexp) - -# source://activesupport//lib/active_support/json/encoding.rb#50 -ActiveSupport::JSON::Encoding::JSONGemEncoder::ESCAPE_REGEX_WITH_HTML_ENTITIES = T.let(T.unsafe(nil), Regexp) - -# This class wraps all the strings we see and does the extra escaping -# -# source://activesupport//lib/active_support/json/encoding.rb#54 -class ActiveSupport::JSON::Encoding::JSONGemEncoder::EscapedString < ::String - # source://activesupport//lib/active_support/json/encoding.rb#55 - def to_json(*_arg0); end - - # source://activesupport//lib/active_support/json/encoding.rb#67 - def to_s; end -end - # KeyGenerator is a simple wrapper around OpenSSL's implementation of PBKDF2. # It can be used to derive a number of keys for various purposes from a given secret. -# This lets Rails applications have a single secure secret, but avoid reusing that +# This lets \Rails applications have a single secure secret, but avoid reusing that # key in multiple incompatible contexts. # -# source://activesupport//lib/active_support/key_generator.rb#11 +# source://activesupport//lib/active_support/key_generator.rb#13 class ActiveSupport::KeyGenerator # @return [KeyGenerator] a new instance of KeyGenerator # - # source://activesupport//lib/active_support/key_generator.rb#26 + # source://activesupport//lib/active_support/key_generator.rb#28 def initialize(secret, options = T.unsafe(nil)); end # Returns a derived key suitable for use. The default +key_size+ is chosen # to be compatible with the default settings of ActiveSupport::MessageVerifier. # i.e. OpenSSL::Digest::SHA1#block_length # - # source://activesupport//lib/active_support/key_generator.rb#39 + # source://activesupport//lib/active_support/key_generator.rb#41 def generate_key(salt, key_size = T.unsafe(nil)); end + # source://activesupport//lib/active_support/key_generator.rb#45 + def inspect; end + class << self - # source://activesupport//lib/active_support/key_generator.rb#21 + # source://activesupport//lib/active_support/key_generator.rb#23 def hash_digest_class; end - # source://activesupport//lib/active_support/key_generator.rb#13 + # source://activesupport//lib/active_support/key_generator.rb#15 def hash_digest_class=(klass); end end end -# LazyLoadHooks allows Rails to lazily load a lot of components and thus +# = Lazy Load Hooks +# +# LazyLoadHooks allows \Rails to lazily load a lot of components and thus # making the app boot faster. Because of this feature now there is no need to -# require ActiveRecord::Base at boot time purely to apply +# require +ActiveRecord::Base+ at boot time purely to apply # configuration. Instead a hook is registered that applies configuration once -# ActiveRecord::Base is loaded. Here ActiveRecord::Base is +# +ActiveRecord::Base+ is loaded. Here +ActiveRecord::Base+ is # used as example but this feature can be applied elsewhere too. # # Here is an example where on_load method is called to register a hook. @@ -6835,9 +7949,9 @@ end # end # end # -# source://activesupport//lib/active_support/lazy_load_hooks.rb#41 +# source://activesupport//lib/active_support/lazy_load_hooks.rb#43 module ActiveSupport::LazyLoadHooks - # Declares a block that will be executed when a Rails component is fully + # Declares a block that will be executed when a \Rails component is fully # loaded. If the component has already loaded, the block is executed # immediately. # @@ -6846,7 +7960,7 @@ module ActiveSupport::LazyLoadHooks # * :yield - Yields the object that run_load_hooks to +block+. # * :run_once - Given +block+ will run only once. # - # source://activesupport//lib/active_support/lazy_load_hooks.rb#58 + # source://activesupport//lib/active_support/lazy_load_hooks.rb#60 def on_load(name, options = T.unsafe(nil), &block); end # Executes all blocks registered to +name+ via on_load, using +base+ as the @@ -6857,24 +7971,26 @@ module ActiveSupport::LazyLoadHooks # In the case of the above example, it will execute all hooks registered # for +:active_record+ within the class +ActiveRecord::Base+. # - # source://activesupport//lib/active_support/lazy_load_hooks.rb#73 + # source://activesupport//lib/active_support/lazy_load_hooks.rb#75 def run_load_hooks(name, base = T.unsafe(nil)); end private - # source://activesupport//lib/active_support/lazy_load_hooks.rb#89 + # source://activesupport//lib/active_support/lazy_load_hooks.rb#91 def execute_hook(name, base, options, block); end - # source://activesupport//lib/active_support/lazy_load_hooks.rb#81 + # source://activesupport//lib/active_support/lazy_load_hooks.rb#83 def with_execution_control(name, block, once); end class << self - # source://activesupport//lib/active_support/lazy_load_hooks.rb#42 + # source://activesupport//lib/active_support/lazy_load_hooks.rb#44 def extended(base); end end end -# ActiveSupport::LogSubscriber is an object set to consume +# = Active Support Log \Subscriber +# +# +ActiveSupport::LogSubscriber+ is an object set to consume # ActiveSupport::Notifications with the sole purpose of logging them. # The log subscriber dispatches notifications to a registered object based # on its given namespace. @@ -6884,29 +8000,23 @@ end # # module ActiveRecord # class LogSubscriber < ActiveSupport::LogSubscriber +# attach_to :active_record +# # def sql(event) # info "#{event.payload[:name]} (#{event.duration}) #{event.payload[:sql]}" # end # end # end # -# And it's finally registered as: -# -# ActiveRecord::LogSubscriber.attach_to :active_record -# -# Since we need to know all instance methods before attaching the log -# subscriber, the line above should be called after your -# ActiveRecord::LogSubscriber definition. +# ActiveRecord::LogSubscriber.logger must be set as well, but it is assigned +# automatically in a \Rails environment. # -# A logger also needs to be set with ActiveRecord::LogSubscriber.logger=. -# This is assigned automatically in a Rails environment. -# -# After configured, whenever a "sql.active_record" notification is published, -# it will properly dispatch the event -# (ActiveSupport::Notifications::Event) to the sql method. +# After configured, whenever a "sql.active_record" notification is +# published, it will properly dispatch the event +# (ActiveSupport::Notifications::Event) to the +sql+ method. # # Being an ActiveSupport::Notifications consumer, -# ActiveSupport::LogSubscriber exposes a simple interface to check if +# +ActiveSupport::LogSubscriber+ exposes a simple interface to check if # instrumented code raises an exception. It is common to log a different # message in case of an error, and this can be achieved by extending # the previous example: @@ -6928,125 +8038,156 @@ end # end # end # -# Log subscriber also has some helpers to deal with logging and automatically -# flushes all logs when the request finishes -# (via action_dispatch.callback notification) in a Rails environment. +# +ActiveSupport::LogSubscriber+ also has some helpers to deal with +# logging. For example, ActiveSupport::LogSubscriber.flush_all! will ensure +# that all logs are flushed, and it is called in Rails::Rack::Logger after a +# request finishes. # -# source://activesupport//lib/active_support/log_subscriber.rb#65 +# source://activesupport//lib/active_support/log_subscriber.rb#64 class ActiveSupport::LogSubscriber < ::ActiveSupport::Subscriber - # source://activesupport//lib/active_support/log_subscriber.rb#80 + # @return [LogSubscriber] a new instance of LogSubscriber + # + # source://activesupport//lib/active_support/log_subscriber.rb#133 + def initialize; end + + # source://activesupport//lib/active_support/log_subscriber.rb#146 + def call(event); end + + # source://activesupport//lib/active_support/log_subscriber.rb#83 def colorize_logging; end - # source://activesupport//lib/active_support/log_subscriber.rb#80 + # source://activesupport//lib/active_support/log_subscriber.rb#83 def colorize_logging=(val); end - # source://activesupport//lib/active_support/log_subscriber.rb#129 + # source://activesupport//lib/active_support/log_subscriber.rb#163 def debug(progname = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/log_subscriber.rb#129 + # source://activesupport//lib/active_support/log_subscriber.rb#163 def error(progname = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/log_subscriber.rb#129 - def fatal(progname = T.unsafe(nil), &block); end + # source://activesupport//lib/active_support/log_subscriber.rb#158 + def event_levels=(_arg0); end - # source://activesupport//lib/active_support/log_subscriber.rb#114 - def finish(name, id, payload); end + # source://activesupport//lib/active_support/log_subscriber.rb#163 + def fatal(progname = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/log_subscriber.rb#129 + # source://activesupport//lib/active_support/log_subscriber.rb#163 def info(progname = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/log_subscriber.rb#106 + # source://activesupport//lib/active_support/log_subscriber.rb#138 def logger; end - # source://activesupport//lib/active_support/log_subscriber.rb#120 + # source://activesupport//lib/active_support/log_subscriber.rb#152 def publish_event(event); end - # source://activesupport//lib/active_support/log_subscriber.rb#110 - def start(name, id, payload); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/log_subscriber.rb#142 + def silenced?(event); end - # source://activesupport//lib/active_support/log_subscriber.rb#129 + # source://activesupport//lib/active_support/log_subscriber.rb#163 def unknown(progname = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/log_subscriber.rb#129 + # source://activesupport//lib/active_support/log_subscriber.rb#163 def warn(progname = T.unsafe(nil), &block); end private - # Set color by using a symbol or one of the defined constants. If a third - # option is set to +true+, it also adds bold to the string. This is based - # on the Highline implementation and will automatically append CLEAR to the - # end of the returned String. + # Set color by using a symbol or one of the defined constants. Set modes + # by specifying bold, italic, or underline options. Inspired by Highline, + # this method will automatically clear formatting at the end of the returned String. # - # source://activesupport//lib/active_support/log_subscriber.rb#139 - def color(text, color, bold = T.unsafe(nil)); end + # source://activesupport//lib/active_support/log_subscriber.rb#172 + def color(text, color, mode_options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/log_subscriber.rb#146 + # source://activesupport//lib/active_support/log_subscriber.rb#186 def log_exception(name, e); end + # source://activesupport//lib/active_support/log_subscriber.rb#180 + def mode_from(options); end + class << self - # source://activesupport//lib/active_support/log_subscriber.rb#80 + # source://activesupport//lib/active_support/log_subscriber.rb#99 + def attach_to(*_arg0, **_arg1, &_arg2); end + + # source://activesupport//lib/active_support/log_subscriber.rb#83 def colorize_logging; end - # source://activesupport//lib/active_support/log_subscriber.rb#80 + # source://activesupport//lib/active_support/log_subscriber.rb#83 def colorize_logging=(val); end # Flush all log_subscribers' logger. # - # source://activesupport//lib/active_support/log_subscriber.rb#96 + # source://activesupport//lib/active_support/log_subscriber.rb#112 def flush_all!; end - # source://activesupport//lib/active_support/log_subscriber.rb#91 + # source://activesupport//lib/active_support/log_subscriber.rb#84 + def log_levels; end + + # source://activesupport//lib/active_support/log_subscriber.rb#84 + def log_levels=(value); end + + # source://activesupport//lib/active_support/log_subscriber.rb#84 + def log_levels?; end + + # source://activesupport//lib/active_support/log_subscriber.rb#107 def log_subscribers; end - # source://activesupport//lib/active_support/log_subscriber.rb#83 + # source://activesupport//lib/active_support/log_subscriber.rb#93 def logger; end # Sets the attribute logger # # @param value the value to set the attribute logger to. # - # source://activesupport//lib/active_support/log_subscriber.rb#89 + # source://activesupport//lib/active_support/log_subscriber.rb#105 def logger=(_arg0); end private - # source://activesupport//lib/active_support/log_subscriber.rb#101 + # source://activesupport//lib/active_support/log_subscriber.rb#117 def fetch_public_methods(subscriber, inherit_all); end + + # source://activesupport//lib/active_support/log_subscriber.rb#121 + def set_event_levels; end + + # source://activesupport//lib/active_support/log_subscriber.rb#127 + def subscribe_log_level(method, level); end end end -# Colors +# ANSI sequence colors # -# source://activesupport//lib/active_support/log_subscriber.rb#71 +# source://activesupport//lib/active_support/log_subscriber.rb#74 ActiveSupport::LogSubscriber::BLACK = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/log_subscriber.rb#75 +# source://activesupport//lib/active_support/log_subscriber.rb#78 ActiveSupport::LogSubscriber::BLUE = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/log_subscriber.rb#68 -ActiveSupport::LogSubscriber::BOLD = T.let(T.unsafe(nil), String) - -# Embed in a String to clear all previous ANSI sequences. -# -# source://activesupport//lib/active_support/log_subscriber.rb#67 -ActiveSupport::LogSubscriber::CLEAR = T.let(T.unsafe(nil), String) - -# source://activesupport//lib/active_support/log_subscriber.rb#77 +# source://activesupport//lib/active_support/log_subscriber.rb#80 ActiveSupport::LogSubscriber::CYAN = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/log_subscriber.rb#73 +# source://activesupport//lib/active_support/log_subscriber.rb#76 ActiveSupport::LogSubscriber::GREEN = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/log_subscriber.rb#76 +# source://activesupport//lib/active_support/log_subscriber.rb#86 +ActiveSupport::LogSubscriber::LEVEL_CHECKS = T.let(T.unsafe(nil), Hash) + +# source://activesupport//lib/active_support/log_subscriber.rb#79 ActiveSupport::LogSubscriber::MAGENTA = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/log_subscriber.rb#72 +# ANSI sequence modes +# +# source://activesupport//lib/active_support/log_subscriber.rb#66 +ActiveSupport::LogSubscriber::MODES = T.let(T.unsafe(nil), Hash) + +# source://activesupport//lib/active_support/log_subscriber.rb#75 ActiveSupport::LogSubscriber::RED = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/log_subscriber.rb#78 +# source://activesupport//lib/active_support/log_subscriber.rb#81 ActiveSupport::LogSubscriber::WHITE = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/log_subscriber.rb#74 +# source://activesupport//lib/active_support/log_subscriber.rb#77 ActiveSupport::LogSubscriber::YELLOW = T.let(T.unsafe(nil), String) # source://activesupport//lib/active_support/logger.rb#8 @@ -7056,7 +8197,7 @@ class ActiveSupport::Logger < ::Logger # @return [Logger] a new instance of Logger # - # source://activesupport//lib/active_support/logger.rb#80 + # source://activesupport//lib/active_support/logger.rb#33 def initialize(*args, **kwargs); end # source://activesupport//lib/active_support/logger_silence.rb#12 @@ -7066,22 +8207,24 @@ class ActiveSupport::Logger < ::Logger def silencer=(val); end class << self - # Broadcasts logs to multiple loggers. - # - # source://activesupport//lib/active_support/logger.rb#23 - def broadcast(logger); end - # Returns true if the logger destination matches one of the sources # # logger = Logger.new(STDOUT) # ActiveSupport::Logger.logger_outputs_to?(logger, STDOUT) # # => true # + # logger = Logger.new('/var/log/rails.log') + # ActiveSupport::Logger.logger_outputs_to?(logger, '/var/log/rails.log') + # # => true + # # @return [Boolean] # - # source://activesupport//lib/active_support/logger.rb#16 + # source://activesupport//lib/active_support/logger.rb#20 def logger_outputs_to?(logger, *sources); end + # source://activesupport//lib/active_support/logger.rb#47 + def normalize_sources(sources); end + # source://activesupport//lib/active_support/logger_silence.rb#12 def silencer; end @@ -7092,11 +8235,11 @@ end # Simple formatter which only displays the message. # -# source://activesupport//lib/active_support/logger.rb#86 +# source://activesupport//lib/active_support/logger.rb#39 class ActiveSupport::Logger::SimpleFormatter < ::Logger::Formatter # This method is invoked when a log event occurs # - # source://activesupport//lib/active_support/logger.rb#88 + # source://activesupport//lib/active_support/logger.rb#41 def call(severity, timestamp, progname, msg); end end @@ -7111,49 +8254,32 @@ module ActiveSupport::LoggerSilence def silence(severity = T.unsafe(nil)); end end -# source://activesupport//lib/active_support/logger_thread_safe_level.rb#9 +# source://activesupport//lib/active_support/logger_thread_safe_level.rb#7 module ActiveSupport::LoggerThreadSafeLevel extend ::ActiveSupport::Concern - # Redefined to check severity against #level, and thus the thread-local level, rather than +@level+. - # FIXME: Remove when the minimum Ruby version supports overriding Logger#level. - # - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#50 - def add(severity, message = T.unsafe(nil), progname = T.unsafe(nil), &block); end - - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#14 - def debug?; end - - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#14 - def error?; end - - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#14 - def fatal?; end - - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#14 - def info?; end - - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#36 + # source://activesupport//lib/active_support/logger_thread_safe_level.rb#30 def level; end - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#20 + # source://activesupport//lib/active_support/logger_thread_safe_level.rb#10 def local_level; end - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#24 + # source://activesupport//lib/active_support/logger_thread_safe_level.rb#14 def local_level=(level); end # Change the thread-local level for the duration of the given block. # - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#41 + # source://activesupport//lib/active_support/logger_thread_safe_level.rb#35 def log_at(level); end - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#14 - def unknown?; end + private - # source://activesupport//lib/active_support/logger_thread_safe_level.rb#14 - def warn?; end + # source://activesupport//lib/active_support/logger_thread_safe_level.rb#43 + def local_level_key; end end +# = Active Support Message Encryptor +# # MessageEncryptor is a simple way to encrypt values which get stored # somewhere you don't trust. # @@ -7171,7 +8297,7 @@ end # crypt.decrypt_and_verify(encrypted_data) # => "my secret data" # # The +decrypt_and_verify+ method will raise an -# ActiveSupport::MessageEncryptor::InvalidMessage exception if the data +# +ActiveSupport::MessageEncryptor::InvalidMessage+ exception if the data # provided cannot be decrypted or verified. # # crypt.decrypt_and_verify('not encrypted data') # => ActiveSupport::MessageEncryptor::InvalidMessage @@ -7232,10 +8358,9 @@ end # # crypt.rotate old_secret, cipher: "aes-256-cbc" # -# source://activesupport//lib/active_support/message_encryptor.rb#87 -class ActiveSupport::MessageEncryptor +# source://activesupport//lib/active_support/message_encryptor.rb#90 +class ActiveSupport::MessageEncryptor < ::ActiveSupport::Messages::Codec include ::ActiveSupport::Messages::Rotator - include ::ActiveSupport::Messages::Rotator::Encryptor # Initialize a new MessageEncryptor. +secret+ must be at least as long as # the cipher key size. For the default 'aes-256-gcm' cipher, this is 256 @@ -7243,171 +8368,296 @@ class ActiveSupport::MessageEncryptor # key by using ActiveSupport::KeyGenerator or a similar key # derivation function. # - # First additional parameter is used as the signature key for MessageVerifier. - # This allows you to specify keys to encrypt and sign data. + # The first additional parameter is used as the signature key for + # MessageVerifier. This allows you to specify keys to encrypt and sign + # data. Ignored when using an AEAD cipher like 'aes-256-gcm'. # # ActiveSupport::MessageEncryptor.new('secret', 'signature_secret') # - # Options: - # * :cipher - Cipher to use. Can be any cipher returned by - # OpenSSL::Cipher.ciphers. Default is 'aes-256-gcm'. - # * :digest - String of digest to use for signing. Default is - # +SHA1+. Ignored when using an AEAD cipher like 'aes-256-gcm'. - # * :serializer - Object serializer to use. Default is +Marshal+. + # ==== Options + # + # [+:cipher+] + # Cipher to use. Can be any cipher returned by +OpenSSL::Cipher.ciphers+. + # Default is 'aes-256-gcm'. + # + # [+:digest+] + # Digest used for signing. Ignored when using an AEAD cipher like + # 'aes-256-gcm'. + # + # [+:serializer+] + # The serializer used to serialize message data. You can specify any + # object that responds to +dump+ and +load+, or you can choose from + # several preconfigured serializers: +:marshal+, +:json_allow_marshal+, + # +:json+, +:message_pack_allow_marshal+, +:message_pack+. + # + # The preconfigured serializers include a fallback mechanism to support + # multiple deserialization formats. For example, the +:marshal+ serializer + # will serialize using +Marshal+, but can deserialize using +Marshal+, + # ActiveSupport::JSON, or ActiveSupport::MessagePack. This makes it easy + # to migrate between serializers. + # + # The +:marshal+, +:json_allow_marshal+, and +:message_pack_allow_marshal+ + # serializers support deserializing using +Marshal+, but the others do + # not. Beware that +Marshal+ is a potential vector for deserialization + # attacks in cases where a message signing secret has been leaked. If + # possible, choose a serializer that does not support +Marshal+. + # + # The +:message_pack+ and +:message_pack_allow_marshal+ serializers use + # ActiveSupport::MessagePack, which can roundtrip some Ruby types that are + # not supported by JSON, and may provide improved performance. However, + # these require the +msgpack+ gem. + # + # When using \Rails, the default depends on +config.active_support.message_serializer+. + # Otherwise, the default is +:marshal+. + # + # [+:url_safe+] + # By default, MessageEncryptor generates RFC 4648 compliant strings + # which are not URL-safe. In other words, they can contain "+" and "/". + # If you want to generate URL-safe strings (in compliance with "Base 64 + # Encoding with URL and Filename Safe Alphabet" in RFC 4648), you can + # pass +true+. + # + # [+:force_legacy_metadata_serializer+] + # Whether to use the legacy metadata serializer, which serializes the + # message first, then wraps it in an envelope which is also serialized. This + # was the default in \Rails 7.0 and below. + # + # If you don't pass a truthy value, the default is set using + # +config.active_support.use_message_serializer_for_metadata+. # # @return [MessageEncryptor] a new instance of MessageEncryptor # # source://activesupport//lib/active_support/messages/rotator.rb#6 - def initialize(*secrets, on_rotation: T.unsafe(nil), **options); end + def initialize(*args, on_rotation: T.unsafe(nil), **options); end + + # source://activesupport//lib/active_support/message_encryptor.rb#256 + def create_message(value, **options); end # Decrypt and verify a message. We need to verify the message in order to # avoid padding attacks. Reference: https://www.limited-entropy.com/padding-oracle-attacks/. # - # source://activesupport//lib/active_support/messages/rotator.rb#21 - def decrypt_and_verify(*args, on_rotation: T.unsafe(nil), **options); end + # ==== Options + # + # [+:purpose+] + # The purpose that the message was generated with. If the purpose does not + # match, +decrypt_and_verify+ will return +nil+. + # + # message = encryptor.encrypt_and_sign("hello", purpose: "greeting") + # encryptor.decrypt_and_verify(message, purpose: "greeting") # => "hello" + # encryptor.decrypt_and_verify(message) # => nil + # + # message = encryptor.encrypt_and_sign("bye") + # encryptor.decrypt_and_verify(message) # => "bye" + # encryptor.decrypt_and_verify(message, purpose: "greeting") # => nil + # + # source://activesupport//lib/active_support/message_encryptor.rb#241 + def decrypt_and_verify(message, **options); end + + # Encrypt and sign a message. We need to sign the message in order to avoid + # padding attacks. Reference: https://www.limited-entropy.com/padding-oracle-attacks/. + # + # ==== Options + # + # [+:expires_at+] + # The datetime at which the message expires. After this datetime, + # verification of the message will fail. + # + # message = encryptor.encrypt_and_sign("hello", expires_at: Time.now.tomorrow) + # encryptor.decrypt_and_verify(message) # => "hello" + # # 24 hours later... + # encryptor.decrypt_and_verify(message) # => nil + # + # [+:expires_in+] + # The duration for which the message is valid. After this duration has + # elapsed, verification of the message will fail. + # + # message = encryptor.encrypt_and_sign("hello", expires_in: 24.hours) + # encryptor.decrypt_and_verify(message) # => "hello" + # # 24 hours later... + # encryptor.decrypt_and_verify(message) # => nil + # + # [+:purpose+] + # The purpose of the message. If specified, the same purpose must be + # specified when verifying the message; otherwise, verification will fail. + # (See #decrypt_and_verify.) + # + # source://activesupport//lib/active_support/message_encryptor.rb#220 + def encrypt_and_sign(value, **options); end + + # source://activesupport//lib/active_support/message_encryptor.rb#264 + def inspect; end + + # source://activesupport//lib/active_support/messages/rotator.rb#23 + def read_message(message, on_rotation: T.unsafe(nil), **options); end + + private + + # Returns the value of attribute aead_mode. + # + # source://activesupport//lib/active_support/message_encryptor.rb#371 + def aead_mode; end + + # Returns the value of attribute aead_mode. + # + # source://activesupport//lib/active_support/message_encryptor.rb#371 + def aead_mode?; end + + # source://activesupport//lib/active_support/message_encryptor.rb#295 + def decrypt(encrypted_message); end + + # source://activesupport//lib/active_support/message_encryptor.rb#277 + def encrypt(data); end - # Encrypt and sign a message. We need to sign the message in order to avoid - # padding attacks. Reference: https://www.limited-entropy.com/padding-oracle-attacks/. - # - # source://activesupport//lib/active_support/message_encryptor.rb#153 - def encrypt_and_sign(value, expires_at: T.unsafe(nil), expires_in: T.unsafe(nil), purpose: T.unsafe(nil)); end + # source://activesupport//lib/active_support/message_encryptor.rb#340 + def extract_part(encrypted_message, rindex, length); end - private + # source://activesupport//lib/active_support/message_encryptor.rb#350 + def extract_parts(encrypted_message); end - # source://activesupport//lib/active_support/message_encryptor.rb#186 - def _decrypt(encrypted_message, purpose); end + # source://activesupport//lib/active_support/message_encryptor.rb#336 + def join_parts(parts); end - # source://activesupport//lib/active_support/message_encryptor.rb#169 - def _encrypt(value, **metadata_options); end + # source://activesupport//lib/active_support/message_encryptor.rb#320 + def length_after_encode(length_before_encode); end - # @return [Boolean] - # - # source://activesupport//lib/active_support/message_encryptor.rb#218 - def aead_mode?; end + # source://activesupport//lib/active_support/message_encryptor.rb#332 + def length_of_encoded_auth_tag; end + + # source://activesupport//lib/active_support/message_encryptor.rb#328 + def length_of_encoded_iv; end - # source://activesupport//lib/active_support/message_encryptor.rb#212 + # source://activesupport//lib/active_support/message_encryptor.rb#367 def new_cipher; end - # source://activesupport//lib/active_support/message_encryptor.rb#222 - def resolve_verifier; end + # source://activesupport//lib/active_support/message_encryptor.rb#269 + def sign(data); end - # Returns the value of attribute verifier. - # - # source://activesupport//lib/active_support/message_encryptor.rb#216 - def verifier; end + # source://activesupport//lib/active_support/message_encryptor.rb#273 + def verify(data); end class << self - # source://activesupport//lib/active_support/message_encryptor.rb#93 + # source://activesupport//lib/active_support/message_encryptor.rb#96 def default_cipher; end # Given a cipher, returns the key length of the cipher to help generate the key of desired size # - # source://activesupport//lib/active_support/message_encryptor.rb#164 + # source://activesupport//lib/active_support/message_encryptor.rb#252 def key_len(cipher = T.unsafe(nil)); end - # source://activesupport//lib/active_support/message_encryptor.rb#90 + # source://activesupport//lib/active_support/message_encryptor.rb#93 def use_authenticated_message_encryption; end - # source://activesupport//lib/active_support/message_encryptor.rb#90 + # source://activesupport//lib/active_support/message_encryptor.rb#93 def use_authenticated_message_encryption=(val); end end end -# source://activesupport//lib/active_support/message_encryptor.rb#122 +# source://activesupport//lib/active_support/message_encryptor.rb#118 +ActiveSupport::MessageEncryptor::AUTH_TAG_LENGTH = T.let(T.unsafe(nil), Integer) + +# source://activesupport//lib/active_support/message_encryptor.rb#115 class ActiveSupport::MessageEncryptor::InvalidMessage < ::StandardError; end -# source://activesupport//lib/active_support/message_encryptor.rb#102 +# source://activesupport//lib/active_support/message_encryptor.rb#105 module ActiveSupport::MessageEncryptor::NullSerializer class << self - # source://activesupport//lib/active_support/message_encryptor.rb#107 + # source://activesupport//lib/active_support/message_encryptor.rb#110 def dump(value); end - # source://activesupport//lib/active_support/message_encryptor.rb#103 + # source://activesupport//lib/active_support/message_encryptor.rb#106 def load(value); end end end -# source://activesupport//lib/active_support/message_encryptor.rb#112 -module ActiveSupport::MessageEncryptor::NullVerifier - class << self - # source://activesupport//lib/active_support/message_encryptor.rb#117 - def generate(value); end +# source://activesupport//lib/active_support/message_encryptor.rb#116 +ActiveSupport::MessageEncryptor::OpenSSLCipherError = OpenSSL::Cipher::CipherError - # source://activesupport//lib/active_support/message_encryptor.rb#113 - def verify(value); end - end -end +# source://activesupport//lib/active_support/message_encryptor.rb#119 +ActiveSupport::MessageEncryptor::SEPARATOR = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/message_encryptor.rb#123 -ActiveSupport::MessageEncryptor::OpenSSLCipherError = OpenSSL::Cipher::CipherError +# source://activesupport//lib/active_support/message_encryptors.rb#6 +class ActiveSupport::MessageEncryptors < ::ActiveSupport::Messages::RotationCoordinator + private + + # source://activesupport//lib/active_support/message_encryptors.rb#135 + def build(salt, secret_generator:, secret_generator_options:, **options); end +end +# = Active Support Message Verifier +# # +MessageVerifier+ makes it easy to generate and verify messages which are # signed to prevent tampering. # +# In a \Rails application, you can use +Rails.application.message_verifier+ +# to manage unique instances of verifiers for each use case. +# {Learn more}[link:classes/Rails/Application.html#method-i-message_verifier]. +# # This is useful for cases like remember-me tokens and auto-unsubscribe links # where the session store isn't suitable or available. # -# Remember Me: -# cookies[:remember_me] = @verifier.generate([@user.id, 2.weeks.from_now]) +# First, generate a signed message: +# cookies[:remember_me] = Rails.application.message_verifier(:remember_me).generate([@user.id, 2.weeks.from_now]) # -# In the authentication filter: +# Later verify that message: # -# id, time = @verifier.verify(cookies[:remember_me]) -# if Time.now < time +# id, time = Rails.application.message_verifier(:remember_me).verify(cookies[:remember_me]) +# if time.future? # self.current_user = User.find(id) # end # -# By default it uses Marshal to serialize the message. If you want to use -# another serialization method, you can set the serializer in the options -# hash upon initialization: +# === Signing is not encryption # -# @verifier = ActiveSupport::MessageVerifier.new('s3Krit', serializer: YAML) +# The signed messages are not encrypted. The payload is merely encoded (Base64 by default) and can be decoded by +# anyone. The signature is just assuring that the message wasn't tampered with. For example: # -# +MessageVerifier+ creates HMAC signatures using SHA1 hash algorithm by default. -# If you want to use a different hash algorithm, you can change it by providing -# +:digest+ key as an option while initializing the verifier: +# message = Rails.application.message_verifier('my_purpose').generate('never put secrets here') +# # => "BAhJIhtuZXZlciBwdXQgc2VjcmV0cyBoZXJlBjoGRVQ=--a0c1c0827919da5e949e989c971249355735e140" +# Base64.decode64(message.split("--").first) # no key needed +# # => 'never put secrets here' # -# @verifier = ActiveSupport::MessageVerifier.new('s3Krit', digest: 'SHA256') +# If you also need to encrypt the contents, you must use ActiveSupport::MessageEncryptor instead. # -# === Confining messages to a specific purpose +# === Confine messages to a specific purpose # -# By default any message can be used throughout your app. But they can also be -# confined to a specific +:purpose+. +# It's not recommended to use the same verifier for different purposes in your application. +# Doing so could allow a malicious actor to re-use a signed message to perform an unauthorized +# action. +# You can reduce this risk by confining signed messages to a specific +:purpose+. # -# token = @verifier.generate("this is the chair", purpose: :login) +# token = @verifier.generate("signed message", purpose: :login) # # Then that same purpose must be passed when verifying to get the data back out: # -# @verifier.verified(token, purpose: :login) # => "this is the chair" +# @verifier.verified(token, purpose: :login) # => "signed message" # @verifier.verified(token, purpose: :shipping) # => nil # @verifier.verified(token) # => nil # -# @verifier.verify(token, purpose: :login) # => "this is the chair" -# @verifier.verify(token, purpose: :shipping) # => ActiveSupport::MessageVerifier::InvalidSignature -# @verifier.verify(token) # => ActiveSupport::MessageVerifier::InvalidSignature +# @verifier.verify(token, purpose: :login) # => "signed message" +# @verifier.verify(token, purpose: :shipping) # => raises ActiveSupport::MessageVerifier::InvalidSignature +# @verifier.verify(token) # => raises ActiveSupport::MessageVerifier::InvalidSignature # # Likewise, if a message has no purpose it won't be returned when verifying with # a specific purpose. # -# token = @verifier.generate("the conversation is lively") -# @verifier.verified(token, purpose: :scare_tactics) # => nil -# @verifier.verified(token) # => "the conversation is lively" +# token = @verifier.generate("signed message") +# @verifier.verified(token, purpose: :redirect) # => nil +# @verifier.verified(token) # => "signed message" # -# @verifier.verify(token, purpose: :scare_tactics) # => ActiveSupport::MessageVerifier::InvalidSignature -# @verifier.verify(token) # => "the conversation is lively" +# @verifier.verify(token, purpose: :redirect) # => raises ActiveSupport::MessageVerifier::InvalidSignature +# @verifier.verify(token) # => "signed message" # -# === Making messages expire +# === Expiring messages # # By default messages last forever and verifying one year from now will still # return the original value. But messages can be set to expire at a given # time with +:expires_in+ or +:expires_at+. # -# @verifier.generate("parcel", expires_in: 1.month) -# @verifier.generate("doowad", expires_at: Time.now.end_of_year) +# @verifier.generate("signed message", expires_in: 1.month) +# @verifier.generate("signed message", expires_at: Time.now.end_of_year) # -# Then the messages can be verified and returned up to the expire time. +# Messages can then be verified and returned until expiry. # Thereafter, the +verified+ method returns +nil+ while +verify+ raises -# ActiveSupport::MessageVerifier::InvalidSignature. +# +ActiveSupport::MessageVerifier::InvalidSignature+. # # === Rotating keys # @@ -7425,41 +8675,124 @@ ActiveSupport::MessageEncryptor::OpenSSLCipherError = OpenSSL::Cipher::CipherErr # Then gradually rotate the old values out by adding them as fallbacks. Any message # generated with the old values will then work until the rotation is removed. # -# verifier.rotate old_secret # Fallback to an old secret instead of @secret. -# verifier.rotate digest: "SHA256" # Fallback to an old digest instead of SHA512. -# verifier.rotate serializer: Marshal # Fallback to an old serializer instead of JSON. +# verifier.rotate(old_secret) # Fallback to an old secret instead of @secret. +# verifier.rotate(digest: "SHA256") # Fallback to an old digest instead of SHA512. +# verifier.rotate(serializer: Marshal) # Fallback to an old serializer instead of JSON. # # Though the above would most likely be combined into one rotation: # -# verifier.rotate old_secret, digest: "SHA256", serializer: Marshal +# verifier.rotate(old_secret, digest: "SHA256", serializer: Marshal) # -# source://activesupport//lib/active_support/message_verifier.rb#102 -class ActiveSupport::MessageVerifier +# source://activesupport//lib/active_support/message_verifier.rb#110 +class ActiveSupport::MessageVerifier < ::ActiveSupport::Messages::Codec include ::ActiveSupport::Messages::Rotator - include ::ActiveSupport::Messages::Rotator::Verifier + # Initialize a new MessageVerifier with a secret for the signature. + # + # ==== Options + # + # [+:digest+] + # Digest used for signing. The default is "SHA1". See + # +OpenSSL::Digest+ for alternatives. + # + # [+:serializer+] + # The serializer used to serialize message data. You can specify any + # object that responds to +dump+ and +load+, or you can choose from + # several preconfigured serializers: +:marshal+, +:json_allow_marshal+, + # +:json+, +:message_pack_allow_marshal+, +:message_pack+. + # + # The preconfigured serializers include a fallback mechanism to support + # multiple deserialization formats. For example, the +:marshal+ serializer + # will serialize using +Marshal+, but can deserialize using +Marshal+, + # ActiveSupport::JSON, or ActiveSupport::MessagePack. This makes it easy + # to migrate between serializers. + # + # The +:marshal+, +:json_allow_marshal+, and +:message_pack_allow_marshal+ + # serializers support deserializing using +Marshal+, but the others do + # not. Beware that +Marshal+ is a potential vector for deserialization + # attacks in cases where a message signing secret has been leaked. If + # possible, choose a serializer that does not support +Marshal+. + # + # The +:message_pack+ and +:message_pack_allow_marshal+ serializers use + # ActiveSupport::MessagePack, which can roundtrip some Ruby types that are + # not supported by JSON, and may provide improved performance. However, + # these require the +msgpack+ gem. + # + # When using \Rails, the default depends on +config.active_support.message_serializer+. + # Otherwise, the default is +:marshal+. + # + # [+:url_safe+] + # By default, MessageVerifier generates RFC 4648 compliant strings which are + # not URL-safe. In other words, they can contain "+" and "/". If you want to + # generate URL-safe strings (in compliance with "Base 64 Encoding with URL + # and Filename Safe Alphabet" in RFC 4648), you can pass +true+. + # + # [+:force_legacy_metadata_serializer+] + # Whether to use the legacy metadata serializer, which serializes the + # message first, then wraps it in an envelope which is also serialized. This + # was the default in \Rails 7.0 and below. + # + # If you don't pass a truthy value, the default is set using + # +config.active_support.use_message_serializer_for_metadata+. + # # @raise [ArgumentError] # @return [MessageVerifier] a new instance of MessageVerifier # # source://activesupport//lib/active_support/messages/rotator.rb#6 - def initialize(*secrets, on_rotation: T.unsafe(nil), **options); end + def initialize(*args, on_rotation: T.unsafe(nil), **options); end + + # source://activesupport//lib/active_support/message_verifier.rb#308 + def create_message(value, **options); end # Generates a signed message for the provided value. # # The message is signed with the +MessageVerifier+'s secret. # Returns Base64-encoded message joined with the generated signature. # - # verifier = ActiveSupport::MessageVerifier.new 's3Krit' - # verifier.generate 'a private message' # => "BAhJIhRwcml2YXRlLW1lc3NhZ2UGOgZFVA==--e2d724331ebdee96a10fb99b089508d1c72bd772" + # verifier = ActiveSupport::MessageVerifier.new("secret") + # verifier.generate("signed message") # => "BAhJIhNzaWduZWQgbWVzc2FnZQY6BkVU--f67d5f27c3ee0b8483cebf2103757455e947493b" + # + # ==== Options + # + # [+:expires_at+] + # The datetime at which the message expires. After this datetime, + # verification of the message will fail. + # + # message = verifier.generate("hello", expires_at: Time.now.tomorrow) + # verifier.verified(message) # => "hello" + # # 24 hours later... + # verifier.verified(message) # => nil + # verifier.verify(message) # => raises ActiveSupport::MessageVerifier::InvalidSignature + # + # [+:expires_in+] + # The duration for which the message is valid. After this duration has + # elapsed, verification of the message will fail. + # + # message = verifier.generate("hello", expires_in: 24.hours) + # verifier.verified(message) # => "hello" + # # 24 hours later... + # verifier.verified(message) # => nil + # verifier.verify(message) # => raises ActiveSupport::MessageVerifier::InvalidSignature + # + # [+:purpose+] + # The purpose of the message. If specified, the same purpose must be + # specified when verifying the message; otherwise, verification will fail. + # (See #verified and #verify.) # - # source://activesupport//lib/active_support/message_verifier.rb#188 - def generate(value, expires_at: T.unsafe(nil), expires_in: T.unsafe(nil), purpose: T.unsafe(nil)); end + # source://activesupport//lib/active_support/message_verifier.rb#304 + def generate(value, **options); end + + # source://activesupport//lib/active_support/message_verifier.rb#316 + def inspect; end + + # source://activesupport//lib/active_support/messages/rotator.rb#23 + def read_message(message, on_rotation: T.unsafe(nil), **options); end # Checks if a signed message could have been generated by signing an object # with the +MessageVerifier+'s secret. # - # verifier = ActiveSupport::MessageVerifier.new 's3Krit' - # signed_message = verifier.generate 'a private message' + # verifier = ActiveSupport::MessageVerifier.new("secret") + # signed_message = verifier.generate("signed message") # verifier.valid_message?(signed_message) # => true # # tampered_message = signed_message.chop # editing the message invalidates the signature @@ -7467,19 +8800,19 @@ class ActiveSupport::MessageVerifier # # @return [Boolean] # - # source://activesupport//lib/active_support/message_verifier.rb#126 - def valid_message?(signed_message); end + # source://activesupport//lib/active_support/message_verifier.rb#181 + def valid_message?(message); end # Decodes the signed message using the +MessageVerifier+'s secret. # - # verifier = ActiveSupport::MessageVerifier.new 's3Krit' + # verifier = ActiveSupport::MessageVerifier.new("secret") # - # signed_message = verifier.generate 'a private message' - # verifier.verified(signed_message) # => 'a private message' + # signed_message = verifier.generate("signed message") + # verifier.verified(signed_message) # => "signed message" # # Returns +nil+ if the message was not signed with the same secret. # - # other_verifier = ActiveSupport::MessageVerifier.new 'd1ff3r3nt-s3Krit' + # other_verifier = ActiveSupport::MessageVerifier.new("different_secret") # other_verifier.verified(signed_message) # => nil # # Returns +nil+ if the message is not Base64-encoded. @@ -7492,114 +8825,218 @@ class ActiveSupport::MessageVerifier # incompatible_message = "test--dad7b06c94abba8d46a15fafaef56c327665d5ff" # verifier.verified(incompatible_message) # => TypeError: incompatible marshal file format # - # source://activesupport//lib/active_support/messages/rotator.rb#36 - def verified(*args, on_rotation: T.unsafe(nil), **options); end + # ==== Options + # + # [+:purpose+] + # The purpose that the message was generated with. If the purpose does not + # match, +verified+ will return +nil+. + # + # message = verifier.generate("hello", purpose: "greeting") + # verifier.verified(message, purpose: "greeting") # => "hello" + # verifier.verified(message, purpose: "chatting") # => nil + # verifier.verified(message) # => nil + # + # message = verifier.generate("bye") + # verifier.verified(message) # => "bye" + # verifier.verified(message, purpose: "greeting") # => nil + # + # source://activesupport//lib/active_support/message_verifier.rb#222 + def verified(message, **options); end # Decodes the signed message using the +MessageVerifier+'s secret. # - # verifier = ActiveSupport::MessageVerifier.new 's3Krit' - # signed_message = verifier.generate 'a private message' + # verifier = ActiveSupport::MessageVerifier.new("secret") + # signed_message = verifier.generate("signed message") # - # verifier.verify(signed_message) # => 'a private message' + # verifier.verify(signed_message) # => "signed message" # # Raises +InvalidSignature+ if the message was not signed with the same # secret or was not Base64-encoded. # - # other_verifier = ActiveSupport::MessageVerifier.new 'd1ff3r3nt-s3Krit' + # other_verifier = ActiveSupport::MessageVerifier.new("different_secret") # other_verifier.verify(signed_message) # => ActiveSupport::MessageVerifier::InvalidSignature # - # source://activesupport//lib/active_support/message_verifier.rb#177 - def verify(*args, **options); end + # ==== Options + # + # [+:purpose+] + # The purpose that the message was generated with. If the purpose does not + # match, +verify+ will raise ActiveSupport::MessageVerifier::InvalidSignature. + # + # message = verifier.generate("hello", purpose: "greeting") + # verifier.verify(message, purpose: "greeting") # => "hello" + # verifier.verify(message, purpose: "chatting") # => raises InvalidSignature + # verifier.verify(message) # => raises InvalidSignature + # + # message = verifier.generate("bye") + # verifier.verify(message) # => "bye" + # verifier.verify(message, purpose: "greeting") # => raises InvalidSignature + # + # source://activesupport//lib/active_support/message_verifier.rb#260 + def verify(message, **options); end private - # source://activesupport//lib/active_support/message_verifier.rb#198 - def decode(data); end - - # source://activesupport//lib/active_support/message_verifier.rb#206 + # source://activesupport//lib/active_support/message_verifier.rb#347 def digest_length_in_hex; end # @return [Boolean] # - # source://activesupport//lib/active_support/message_verifier.rb#233 + # source://activesupport//lib/active_support/message_verifier.rb#364 def digest_matches_data?(digest, data); end - # source://activesupport//lib/active_support/message_verifier.rb#194 - def encode(data); end + # source://activesupport//lib/active_support/message_verifier.rb#326 + def extract_encoded(signed); end - # source://activesupport//lib/active_support/message_verifier.rb#202 + # source://activesupport//lib/active_support/message_verifier.rb#343 def generate_digest(data); end - # source://activesupport//lib/active_support/message_verifier.rb#221 - def get_data_and_digest_from(signed_message); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/message_verifier.rb#355 + def separator_at?(signed_message, index); end - # source://activesupport//lib/active_support/message_verifier.rb#214 + # source://activesupport//lib/active_support/message_verifier.rb#359 def separator_index_for(signed_message); end + + # source://activesupport//lib/active_support/message_verifier.rb#321 + def sign_encoded(encoded); end end -# source://activesupport//lib/active_support/message_verifier.rb#105 +# source://activesupport//lib/active_support/message_verifier.rb#113 class ActiveSupport::MessageVerifier::InvalidSignature < ::StandardError; end -# source://activesupport//lib/active_support/message_verifier.rb#107 +# source://activesupport//lib/active_support/message_verifier.rb#115 ActiveSupport::MessageVerifier::SEPARATOR = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/message_verifier.rb#108 +# source://activesupport//lib/active_support/message_verifier.rb#116 ActiveSupport::MessageVerifier::SEPARATOR_LENGTH = T.let(T.unsafe(nil), Integer) -# source://activesupport//lib/active_support/messages/metadata.rb#6 +# source://activesupport//lib/active_support/message_verifiers.rb#6 +class ActiveSupport::MessageVerifiers < ::ActiveSupport::Messages::RotationCoordinator + private + + # source://activesupport//lib/active_support/message_verifiers.rb#131 + def build(salt, secret_generator:, secret_generator_options:, **options); end +end + +# source://activesupport//lib/active_support/messages/rotation_coordinator.rb#6 module ActiveSupport::Messages; end -# source://activesupport//lib/active_support/messages/metadata.rb#7 -class ActiveSupport::Messages::Metadata - # @return [Metadata] a new instance of Metadata +# source://activesupport//lib/active_support/messages/codec.rb#9 +class ActiveSupport::Messages::Codec + include ::ActiveSupport::Messages::Metadata + + # @return [Codec] a new instance of Codec # - # source://activesupport//lib/active_support/messages/metadata.rb#8 - def initialize(message, expires_at = T.unsafe(nil), purpose = T.unsafe(nil)); end + # source://activesupport//lib/active_support/messages/codec.rb#15 + def initialize(**options); end - # source://activesupport//lib/active_support/messages/metadata.rb#13 - def as_json(options = T.unsafe(nil)); end + private - # source://activesupport//lib/active_support/messages/metadata.rb#58 - def verify(purpose); end + # source://activesupport//lib/active_support/messages/codec.rb#45 + def catch_and_ignore(throwable, &block); end + # source://activesupport//lib/active_support/messages/codec.rb#52 + def catch_and_raise(throwable, as: T.unsafe(nil), &block); end + + # source://activesupport//lib/active_support/messages/codec.rb#29 + def decode(encoded, url_safe: T.unsafe(nil)); end + + # source://activesupport//lib/active_support/messages/codec.rb#39 + def deserialize(serialized); end + + # source://activesupport//lib/active_support/messages/codec.rb#25 + def encode(data, url_safe: T.unsafe(nil)); end + + # source://activesupport//lib/active_support/messages/codec.rb#35 + def serialize(data); end + + # Returns the value of attribute serializer. + # + # source://activesupport//lib/active_support/messages/codec.rb#23 + def serializer; end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/codec.rb#60 + def use_message_serializer_for_metadata?; end + + class << self + # source://activesupport//lib/active_support/messages/codec.rb#12 + def default_serializer; end + + # source://activesupport//lib/active_support/messages/codec.rb#12 + def default_serializer=(value); end + end +end + +# source://activesupport//lib/active_support/messages/metadata.rb#9 +module ActiveSupport::Messages::Metadata private + # source://activesupport//lib/active_support/messages/metadata.rb#128 + def deserialize_from_json(serialized); end + + # source://activesupport//lib/active_support/messages/metadata.rb#141 + def deserialize_from_json_safe_string(string); end + + # source://activesupport//lib/active_support/messages/metadata.rb#43 + def deserialize_with_metadata(message, **expected_metadata); end + # @return [Boolean] # - # source://activesupport//lib/active_support/messages/metadata.rb#67 - def fresh?; end + # source://activesupport//lib/active_support/messages/metadata.rb#96 + def dual_serialized_metadata_envelope_json?(string); end + + # source://activesupport//lib/active_support/messages/metadata.rb#78 + def extract_from_metadata_envelope(envelope, purpose: T.unsafe(nil)); end # @return [Boolean] # - # source://activesupport//lib/active_support/messages/metadata.rb#63 - def match?(purpose); end + # source://activesupport//lib/active_support/messages/metadata.rb#92 + def metadata_envelope?(object); end - # source://activesupport//lib/active_support/messages/metadata.rb#71 - def parse_expires_at(expires_at); end + # source://activesupport//lib/active_support/messages/metadata.rb#114 + def parse_expiry(expires_at); end - class << self - # source://activesupport//lib/active_support/messages/metadata.rb#26 - def verify(message, purpose); end + # source://activesupport//lib/active_support/messages/metadata.rb#100 + def pick_expiry(expires_at, expires_in); end - # source://activesupport//lib/active_support/messages/metadata.rb#18 - def wrap(message, expires_at: T.unsafe(nil), expires_in: T.unsafe(nil), purpose: T.unsafe(nil)); end + # source://activesupport//lib/active_support/messages/metadata.rb#124 + def serialize_to_json(data); end - private + # source://activesupport//lib/active_support/messages/metadata.rb#137 + def serialize_to_json_safe_string(data); end + + # source://activesupport//lib/active_support/messages/metadata.rb#30 + def serialize_with_metadata(data, **metadata); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/metadata.rb#60 + def use_message_serializer_for_metadata?; end - # source://activesupport//lib/active_support/messages/metadata.rb#53 - def decode(message); end + # source://activesupport//lib/active_support/messages/metadata.rb#64 + def wrap_in_metadata_envelope(hash, expires_at: T.unsafe(nil), expires_in: T.unsafe(nil), purpose: T.unsafe(nil)); end - # source://activesupport//lib/active_support/messages/metadata.rb#49 - def encode(message); end + # source://activesupport//lib/active_support/messages/metadata.rb#71 + def wrap_in_metadata_legacy_envelope(hash, expires_at: T.unsafe(nil), expires_in: T.unsafe(nil), purpose: T.unsafe(nil)); end - # source://activesupport//lib/active_support/messages/metadata.rb#39 - def extract_metadata(message); end + class << self + # source://activesupport//lib/active_support/messages/metadata.rb#10 + def use_message_serializer_for_metadata; end - # source://activesupport//lib/active_support/messages/metadata.rb#31 - def pick_expiry(expires_at, expires_in); end + # source://activesupport//lib/active_support/messages/metadata.rb#10 + def use_message_serializer_for_metadata=(_arg0); end end end +# source://activesupport//lib/active_support/messages/metadata.rb#12 +ActiveSupport::Messages::Metadata::ENVELOPE_SERIALIZERS = T.let(T.unsafe(nil), Array) + +# source://activesupport//lib/active_support/messages/metadata.rb#19 +ActiveSupport::Messages::Metadata::TIMESTAMP_SERIALIZERS = T.let(T.unsafe(nil), Array) + # source://activesupport//lib/active_support/messages/rotation_configuration.rb#5 class ActiveSupport::Messages::RotationConfiguration # @return [RotationConfiguration] a new instance of RotationConfiguration @@ -7621,46 +9058,223 @@ class ActiveSupport::Messages::RotationConfiguration def signed; end end +# source://activesupport//lib/active_support/messages/rotation_coordinator.rb#7 +class ActiveSupport::Messages::RotationCoordinator + # @raise [ArgumentError] + # @return [RotationCoordinator] a new instance of RotationCoordinator + # + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#10 + def initialize(&secret_generator); end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#18 + def [](salt); end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#22 + def []=(salt, codec); end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#39 + def clear_rotations; end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#45 + def on_rotation(&callback); end + + # @raise [ArgumentError] + # + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#26 + def rotate(**options, &block); end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#35 + def rotate_defaults; end + + # Returns the value of attribute transitional. + # + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#8 + def transitional; end + + # Sets the attribute transitional + # + # @param value the value to set the attribute transitional to. + # + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#8 + def transitional=(_arg0); end + + private + + # @raise [NotImplementedError] + # + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#88 + def build(salt, secret_generator:, secret_generator_options:, **options); end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#76 + def build_with_rotations(salt); end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#51 + def changing_configuration!; end + + # source://activesupport//lib/active_support/messages/rotation_coordinator.rb#62 + def normalize_options(options); end +end + # source://activesupport//lib/active_support/messages/rotator.rb#5 module ActiveSupport::Messages::Rotator # source://activesupport//lib/active_support/messages/rotator.rb#6 - def initialize(*secrets, on_rotation: T.unsafe(nil), **options); end + def initialize(*args, on_rotation: T.unsafe(nil), **options); end + + # source://activesupport//lib/active_support/messages/rotator.rb#18 + def fall_back_to(fallback); end + + # source://activesupport//lib/active_support/messages/rotator.rb#23 + def read_message(message, on_rotation: T.unsafe(nil), **options); end # source://activesupport//lib/active_support/messages/rotator.rb#14 - def rotate(*secrets, **options); end + def rotate(*args, **options); end private - # source://activesupport//lib/active_support/messages/rotator.rb#47 - def run_rotations(on_rotation); end + # source://activesupport//lib/active_support/messages/rotator.rb#44 + def build_rotation(*args, **options); end + + # source://activesupport//lib/active_support/messages/rotator.rb#48 + def catch_rotation_error(&block); end end -# source://activesupport//lib/active_support/messages/rotator.rb#18 -module ActiveSupport::Messages::Rotator::Encryptor - include ::ActiveSupport::Messages::Rotator +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#8 +module ActiveSupport::Messages::SerializerWithFallback + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#17 + def load(dumped); end + + private + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#33 + def detect_format(dumped); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#44 + def fallback?(format); end - # source://activesupport//lib/active_support/messages/rotator.rb#21 - def decrypt_and_verify(*args, on_rotation: T.unsafe(nil), **options); end + class << self + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#9 + def [](format); end + end +end +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#48 +module ActiveSupport::Messages::SerializerWithFallback::AllowMarshal private - # source://activesupport//lib/active_support/messages/rotator.rb#28 - def build_rotation(secret = T.unsafe(nil), sign_secret = T.unsafe(nil), options); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#50 + def fallback?(format); end end -# source://activesupport//lib/active_support/messages/rotator.rb#33 -module ActiveSupport::Messages::Rotator::Verifier - include ::ActiveSupport::Messages::Rotator +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#78 +module ActiveSupport::Messages::SerializerWithFallback::JsonWithFallback + include ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback::JsonWithFallback + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#90 + def _load(dumped); end + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#86 + def dump(object); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#96 + def dumped?(dumped); end + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#82 + def format; end + + private + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#101 + def detect_format(dumped); end +end + +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#94 +ActiveSupport::Messages::SerializerWithFallback::JsonWithFallback::JSON_START_WITH = T.let(T.unsafe(nil), Regexp) + +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#107 +module ActiveSupport::Messages::SerializerWithFallback::JsonWithFallbackAllowMarshal + include ::ActiveSupport::Messages::SerializerWithFallback + include ::ActiveSupport::Messages::SerializerWithFallback::JsonWithFallback + include ::ActiveSupport::Messages::SerializerWithFallback::AllowMarshal + extend ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback::JsonWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback::AllowMarshal + extend ::ActiveSupport::Messages::SerializerWithFallback::JsonWithFallbackAllowMarshal +end + +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#55 +module ActiveSupport::Messages::SerializerWithFallback::MarshalWithFallback + include ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback::MarshalWithFallback + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#67 + def _load(dumped); end + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#63 + def dump(object); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#73 + def dumped?(dumped); end + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#59 + def format; end +end + +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#71 +ActiveSupport::Messages::SerializerWithFallback::MarshalWithFallback::MARSHAL_SIGNATURE = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#113 +module ActiveSupport::Messages::SerializerWithFallback::MessagePackWithFallback + include ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback::MessagePackWithFallback - # source://activesupport//lib/active_support/messages/rotator.rb#36 - def verified(*args, on_rotation: T.unsafe(nil), **options); end + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#125 + def _load(dumped); end + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#121 + def dump(object); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#129 + def dumped?(dumped); end + + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#117 + def format; end private - # source://activesupport//lib/active_support/messages/rotator.rb#41 - def build_rotation(secret = T.unsafe(nil), options); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#134 + def available?; end +end + +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#143 +module ActiveSupport::Messages::SerializerWithFallback::MessagePackWithFallbackAllowMarshal + include ::ActiveSupport::Messages::SerializerWithFallback + include ::ActiveSupport::Messages::SerializerWithFallback::MessagePackWithFallback + include ::ActiveSupport::Messages::SerializerWithFallback::AllowMarshal + extend ::ActiveSupport::Messages::SerializerWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback::MessagePackWithFallback + extend ::ActiveSupport::Messages::SerializerWithFallback::AllowMarshal + extend ::ActiveSupport::Messages::SerializerWithFallback::MessagePackWithFallbackAllowMarshal end +# source://activesupport//lib/active_support/messages/serializer_with_fallback.rb#149 +ActiveSupport::Messages::SerializerWithFallback::SERIALIZERS = T.let(T.unsafe(nil), Hash) + # source://activesupport//lib/active_support/multibyte.rb#4 module ActiveSupport::Multibyte class << self @@ -7681,6 +9295,8 @@ module ActiveSupport::Multibyte end end +# = Active Support \Multibyte \Chars +# # Chars enables you to work transparently with UTF-8 encoding in the Ruby # String class without having extensive knowledge about the encoding. A # Chars object accepts a string upon initialization and proxies String @@ -7717,7 +9333,7 @@ end # # ActiveSupport::Multibyte.proxy_class = CharsForUTF32 # -# source://activesupport//lib/active_support/multibyte/chars.rb#45 +# source://activesupport//lib/active_support/multibyte/chars.rb#47 class ActiveSupport::Multibyte::Chars include ::Comparable @@ -7725,19 +9341,19 @@ class ActiveSupport::Multibyte::Chars # # @return [Chars] a new instance of Chars # - # source://activesupport//lib/active_support/multibyte/chars.rb#54 + # source://activesupport//lib/active_support/multibyte/chars.rb#56 def initialize(string); end - # source://activesupport//lib/active_support/multibyte/chars.rb#51 + # source://activesupport//lib/active_support/multibyte/chars.rb#53 def <=>(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/multibyte/chars.rb#51 + # source://activesupport//lib/active_support/multibyte/chars.rb#53 def =~(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/multibyte/chars.rb#51 + # source://activesupport//lib/active_support/multibyte/chars.rb#53 def acts_like_string?(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/multibyte/chars.rb#159 + # source://activesupport//lib/active_support/multibyte/chars.rb#161 def as_json(options = T.unsafe(nil)); end # Performs composition on all the characters. @@ -7745,7 +9361,7 @@ class ActiveSupport::Multibyte::Chars # 'é'.length # => 1 # 'é'.mb_chars.compose.to_s.length # => 1 # - # source://activesupport//lib/active_support/multibyte/chars.rb#138 + # source://activesupport//lib/active_support/multibyte/chars.rb#140 def compose; end # Performs canonical decomposition on all the characters. @@ -7753,7 +9369,7 @@ class ActiveSupport::Multibyte::Chars # 'é'.length # => 1 # 'é'.mb_chars.decompose.to_s.length # => 2 # - # source://activesupport//lib/active_support/multibyte/chars.rb#130 + # source://activesupport//lib/active_support/multibyte/chars.rb#132 def decompose; end # Returns the number of grapheme clusters in the string. @@ -7761,7 +9377,7 @@ class ActiveSupport::Multibyte::Chars # 'क्षि'.mb_chars.length # => 4 # 'क्षि'.mb_chars.grapheme_length # => 2 # - # source://activesupport//lib/active_support/multibyte/chars.rb#146 + # source://activesupport//lib/active_support/multibyte/chars.rb#148 def grapheme_length; end # Limits the byte size of the string to a number of bytes without breaking @@ -7770,25 +9386,25 @@ class ActiveSupport::Multibyte::Chars # # 'こんにちは'.mb_chars.limit(7).to_s # => "こん" # - # source://activesupport//lib/active_support/multibyte/chars.rb#113 + # source://activesupport//lib/active_support/multibyte/chars.rb#115 def limit(limit); end - # source://activesupport//lib/active_support/multibyte/chars.rb#51 + # source://activesupport//lib/active_support/multibyte/chars.rb#53 def match?(*_arg0, **_arg1, &_arg2); end # Forward all undefined methods to the wrapped string. # - # source://activesupport//lib/active_support/multibyte/chars.rb#60 - def method_missing(method, *args, &block); end + # source://activesupport//lib/active_support/multibyte/chars.rb#62 + def method_missing(method, *_arg1, **_arg2, &_arg3); end # Reverses all characters in the string. # # 'Café'.mb_chars.reverse.to_s # => 'éfaC' # - # source://activesupport//lib/active_support/multibyte/chars.rb#104 + # source://activesupport//lib/active_support/multibyte/chars.rb#106 def reverse; end - # source://activesupport//lib/active_support/multibyte/chars.rb#164 + # source://activesupport//lib/active_support/multibyte/chars.rb#166 def reverse!(*args); end # Works like String#slice!, but returns an instance of @@ -7801,7 +9417,7 @@ class ActiveSupport::Multibyte::Chars # string.mb_chars.slice!(0..3) # => # # string # => 'me' # - # source://activesupport//lib/active_support/multibyte/chars.rb#94 + # source://activesupport//lib/active_support/multibyte/chars.rb#96 def slice!(*args); end # Works just like String#split, with the exception that the items @@ -7810,7 +9426,7 @@ class ActiveSupport::Multibyte::Chars # # 'Café périferôl'.mb_chars.split(/é/).map { |part| part.upcase.to_s } # => ["CAF", " P", "RIFERÔL"] # - # source://activesupport//lib/active_support/multibyte/chars.rb#81 + # source://activesupport//lib/active_support/multibyte/chars.rb#83 def split(*args); end # Replaces all ISO-8859-1 or CP1252 characters by their UTF-8 equivalent @@ -7819,10 +9435,10 @@ class ActiveSupport::Multibyte::Chars # Passing +true+ will forcibly tidy all bytes, assuming that the string's # encoding is entirely CP1252 or ISO-8859-1. # - # source://activesupport//lib/active_support/multibyte/chars.rb#155 + # source://activesupport//lib/active_support/multibyte/chars.rb#157 def tidy_bytes(force = T.unsafe(nil)); end - # source://activesupport//lib/active_support/multibyte/chars.rb#164 + # source://activesupport//lib/active_support/multibyte/chars.rb#166 def tidy_bytes!(*args); end # Capitalizes the first letter of every word, when possible. @@ -7830,7 +9446,7 @@ class ActiveSupport::Multibyte::Chars # "ÉL QUE SE ENTERÓ".mb_chars.titleize.to_s # => "Él Que Se Enteró" # "日本語".mb_chars.titleize.to_s # => "日本語" # - # source://activesupport//lib/active_support/multibyte/chars.rb#121 + # source://activesupport//lib/active_support/multibyte/chars.rb#123 def titlecase; end # Capitalizes the first letter of every word, when possible. @@ -7838,27 +9454,27 @@ class ActiveSupport::Multibyte::Chars # "ÉL QUE SE ENTERÓ".mb_chars.titleize.to_s # => "Él Que Se Enteró" # "日本語".mb_chars.titleize.to_s # => "日本語" # - # source://activesupport//lib/active_support/multibyte/chars.rb#121 + # source://activesupport//lib/active_support/multibyte/chars.rb#123 def titleize; end # Returns the value of attribute wrapped_string. # - # source://activesupport//lib/active_support/multibyte/chars.rb#47 + # source://activesupport//lib/active_support/multibyte/chars.rb#49 def to_s; end # Returns the value of attribute wrapped_string. # - # source://activesupport//lib/active_support/multibyte/chars.rb#47 + # source://activesupport//lib/active_support/multibyte/chars.rb#49 def to_str; end # Returns the value of attribute wrapped_string. # - # source://activesupport//lib/active_support/multibyte/chars.rb#47 + # source://activesupport//lib/active_support/multibyte/chars.rb#49 def wrapped_string; end private - # source://activesupport//lib/active_support/multibyte/chars.rb#171 + # source://activesupport//lib/active_support/multibyte/chars.rb#173 def chars(string); end # Returns +true+ if _obj_ responds to the given method. Private methods @@ -7867,7 +9483,7 @@ class ActiveSupport::Multibyte::Chars # # @return [Boolean] # - # source://activesupport//lib/active_support/multibyte/chars.rb#72 + # source://activesupport//lib/active_support/multibyte/chars.rb#74 def respond_to_missing?(method, include_private); end end @@ -7891,12 +9507,12 @@ module ActiveSupport::Multibyte::Unicode # Passing +true+ will forcibly tidy all bytes, assuming that the string's # encoding is entirely CP1252 or ISO-8859-1. # - # source://activesupport//lib/active_support/multibyte/unicode.rb#32 + # source://activesupport//lib/active_support/multibyte/unicode.rb#30 def tidy_bytes(string, force = T.unsafe(nil)); end private - # source://activesupport//lib/active_support/multibyte/unicode.rb#65 + # source://activesupport//lib/active_support/multibyte/unicode.rb#37 def recode_windows1252_chars(string); end end @@ -7907,7 +9523,7 @@ ActiveSupport::Multibyte::Unicode::UNICODE_VERSION = T.let(T.unsafe(nil), String # = \Notifications # -# ActiveSupport::Notifications provides an instrumentation API for +# +ActiveSupport::Notifications+ provides an instrumentation API for # Ruby. # # == Instrumenters @@ -7930,6 +9546,16 @@ ActiveSupport::Multibyte::Unicode::UNICODE_VERSION = T.let(T.unsafe(nil), String # You can consume those events and the information they provide by registering # a subscriber. # +# ActiveSupport::Notifications.subscribe('render') do |event| +# event.name # => "render" +# event.duration # => 10 (in milliseconds) +# event.payload # => { extra: :information } +# event.allocations # => 1826 (objects) +# end +# +# +Event+ objects record CPU time and allocations. If you don't need this +# it's also possible to pass a block that accepts five arguments: +# # ActiveSupport::Notifications.subscribe('render') do |name, start, finish, id, payload| # name # => String, name of the event (such as 'render' from above) # start # => Time, when the instrumented block started execution @@ -7943,20 +9569,18 @@ ActiveSupport::Multibyte::Unicode::UNICODE_VERSION = T.let(T.unsafe(nil), String # # ActiveSupport::Notifications.monotonic_subscribe('render') do |name, start, finish, id, payload| # name # => String, name of the event (such as 'render' from above) -# start # => Monotonic time, when the instrumented block started execution -# finish # => Monotonic time, when the instrumented block ended execution +# start # => Float, monotonic time when the instrumented block started execution +# finish # => Float, monotonic time when the instrumented block ended execution # id # => String, unique ID for the instrumenter that fired the event # payload # => Hash, the payload # end # -# The +start+ and +finish+ values above represent monotonic time. -# # For instance, let's store all "render" events in an array: # # events = [] # -# ActiveSupport::Notifications.subscribe('render') do |*args| -# events << ActiveSupport::Notifications::Event.new(*args) +# ActiveSupport::Notifications.subscribe('render') do |event| +# events << event # end # # That code returns right away, you are just subscribing to "render" events. @@ -7967,14 +9591,10 @@ ActiveSupport::Multibyte::Unicode::UNICODE_VERSION = T.let(T.unsafe(nil), String # end # # event = events.first -# event.name # => "render" -# event.duration # => 10 (in milliseconds) -# event.payload # => { extra: :information } -# -# The block in the subscribe call gets the name of the event, start -# timestamp, end timestamp, a string with a unique identifier for that event's instrumenter -# (something like "535801666f04d0298cd6"), and a hash with the payload, in -# that order. +# event.name # => "render" +# event.duration # => 10 (in milliseconds) +# event.payload # => { extra: :information } +# event.allocations # => 1826 (objects) # # If an exception happens during that particular instrumentation the payload will # have a key :exception with an array of two elements as value: a string with @@ -8039,7 +9659,7 @@ ActiveSupport::Multibyte::Unicode::UNICODE_VERSION = T.let(T.unsafe(nil), String # You can subscribe to some event temporarily while some block runs. For # example, in # -# callback = lambda {|*args| ... } +# callback = lambda {|event| ... } # ActiveSupport::Notifications.subscribed(callback, "sql.active_record") do # ... # end @@ -8062,7 +9682,7 @@ ActiveSupport::Multibyte::Unicode::UNICODE_VERSION = T.let(T.unsafe(nil), String # # The +subscribe+ method returns a subscriber object: # -# subscriber = ActiveSupport::Notifications.subscribe("render") do |*args| +# subscriber = ActiveSupport::Notifications.subscribe("render") do |event| # ... # end # @@ -8090,13 +9710,13 @@ ActiveSupport::Multibyte::Unicode::UNICODE_VERSION = T.let(T.unsafe(nil), String # Notifications ships with a queue implementation that consumes and publishes events # to all log subscribers. You can use any queue implementation you want. # -# source://activesupport//lib/active_support/notifications/instrumenter.rb#6 +# source://activesupport//lib/active_support/notifications/instrumenter.rb#7 module ActiveSupport::Notifications class << self - # source://activesupport//lib/active_support/notifications.rb#204 + # source://activesupport//lib/active_support/notifications.rb#208 def instrument(name, payload = T.unsafe(nil)); end - # source://activesupport//lib/active_support/notifications.rb#268 + # source://activesupport//lib/active_support/notifications.rb#269 def instrumenter; end # Performs the same functionality as #subscribe, but the +start+ and @@ -8106,25 +9726,25 @@ module ActiveSupport::Notifications # duration is important. For example, computing elapsed time between # two events. # - # source://activesupport//lib/active_support/notifications.rb#253 + # source://activesupport//lib/active_support/notifications.rb#254 def monotonic_subscribe(pattern = T.unsafe(nil), callback = T.unsafe(nil), &block); end # Returns the value of attribute notifier. # - # source://activesupport//lib/active_support/notifications.rb#194 + # source://activesupport//lib/active_support/notifications.rb#198 def notifier; end # Sets the attribute notifier # # @param value the value to set the attribute notifier to. # - # source://activesupport//lib/active_support/notifications.rb#194 + # source://activesupport//lib/active_support/notifications.rb#198 def notifier=(_arg0); end - # source://activesupport//lib/active_support/notifications.rb#196 + # source://activesupport//lib/active_support/notifications.rb#200 def publish(name, *args); end - # source://activesupport//lib/active_support/notifications.rb#200 + # source://activesupport//lib/active_support/notifications.rb#204 def publish_event(event); end # Subscribe to a given event name with the passed +block+. @@ -8132,11 +9752,15 @@ module ActiveSupport::Notifications # You can subscribe to events by passing a String to match exact event # names, or by passing a Regexp to match all events that match a pattern. # - # ActiveSupport::Notifications.subscribe(/render/) do |*args| - # @event = ActiveSupport::Notifications::Event.new(*args) + # If the block passed to the method only takes one argument, + # it will yield an +Event+ object to the block: + # + # ActiveSupport::Notifications.subscribe(/render/) do |event| + # @event = event # end # - # The +block+ will receive five parameters with information about the event: + # Otherwise the +block+ will receive five arguments with information + # about the event: # # ActiveSupport::Notifications.subscribe('render') do |name, start, finish, id, payload| # name # => String, name of the event (such as 'render' from above) @@ -8146,66 +9770,51 @@ module ActiveSupport::Notifications # payload # => Hash, the payload # end # - # If the block passed to the method only takes one parameter, - # it will yield an event object to the block: - # - # ActiveSupport::Notifications.subscribe(/render/) do |event| - # @event = event - # end - # # Raises an error if invalid event name type is passed: # - # ActiveSupport::Notifications.subscribe(:render) {|*args| ...} + # ActiveSupport::Notifications.subscribe(:render) {|event| ...} # #=> ArgumentError (pattern must be specified as a String, Regexp or empty) # - # source://activesupport//lib/active_support/notifications.rb#243 + # source://activesupport//lib/active_support/notifications.rb#244 def subscribe(pattern = T.unsafe(nil), callback = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/notifications.rb#257 + # source://activesupport//lib/active_support/notifications.rb#258 def subscribed(callback, pattern = T.unsafe(nil), monotonic: T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/notifications.rb#264 + # source://activesupport//lib/active_support/notifications.rb#265 def unsubscribe(subscriber_or_name); end private - # source://activesupport//lib/active_support/notifications.rb#273 + # source://activesupport//lib/active_support/notifications.rb#274 def registry; end end end -# source://activesupport//lib/active_support/notifications/instrumenter.rb#58 +# source://activesupport//lib/active_support/notifications/instrumenter.rb#106 class ActiveSupport::Notifications::Event # @return [Event] a new instance of Event # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#62 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#110 def initialize(name, start, ending, transaction_id, payload); end - # source://activesupport//lib/active_support/notifications/instrumenter.rb#136 - def <<(event); end - - # Returns the number of allocations made since the call to +start!+ and - # the call to +finish!+ + # Returns the number of allocations made between the call to #start! and + # the call to #finish!. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#116 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#176 def allocations; end - # Returns the value of attribute children. - # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#59 - def children; end - - # Returns the CPU time (in milliseconds) passed since the call to - # +start!+ and the call to +finish!+ + # Returns the CPU time (in milliseconds) passed between the call to + # #start! and the call to #finish!. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#104 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#163 def cpu_time; end # Returns the difference in milliseconds between when the execution of the # event started and when it ended. # - # ActiveSupport::Notifications.subscribe('wait') do |*args| - # @event = ActiveSupport::Notifications::Event.new(*args) + # ActiveSupport::Notifications.subscribe('wait') do |event| + # @event = event # end # # ActiveSupport::Notifications.instrument('wait') do @@ -8214,296 +9823,410 @@ class ActiveSupport::Notifications::Event # # @event.duration # => 1000.138 # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#132 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#198 def duration; end - # Returns the value of attribute end. - # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#59 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#128 def end; end # Record information at the time this event finishes # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#96 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#154 def finish!; end - # Returns the idle time time (in milliseconds) passed since the call to - # +start!+ and the call to +finish!+ + # Returns the time spent in GC (in milliseconds) between the call to #start! + # and the call to #finish! # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#110 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#182 + def gc_time; end + + # Returns the idle time time (in milliseconds) passed between the call to + # #start! and the call to #finish!. + # + # source://activesupport//lib/active_support/notifications/instrumenter.rb#169 def idle_time; end # Returns the value of attribute name. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#59 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#107 def name; end - # @return [Boolean] - # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#140 - def parent_of?(event); end - # Returns the value of attribute payload. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#60 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#108 def payload; end # Sets the attribute payload # # @param value the value to set the attribute payload to. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#60 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#108 def payload=(_arg0); end - # source://activesupport//lib/active_support/notifications/instrumenter.rb#75 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#132 def record; end # Record information at the time this event starts # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#89 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#146 def start!; end - # Returns the value of attribute time. - # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#59 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#124 def time; end # Returns the value of attribute transaction_id. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#59 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#107 def transaction_id; end private - # source://activesupport//lib/active_support/notifications/instrumenter.rb#145 - def now; end + # source://activesupport//lib/active_support/notifications/instrumenter.rb#203 + def now; end + + # Likely on JRuby, TruffleRuby + # + # source://activesupport//lib/active_support/notifications/instrumenter.rb#230 + def now_allocations; end + + # source://activesupport//lib/active_support/notifications/instrumenter.rb#210 + def now_cpu; end + + # source://activesupport//lib/active_support/notifications/instrumenter.rb#220 + def now_gc; end +end + +# This is a default queue implementation that ships with Notifications. +# It just pushes events to all registered log subscribers. +# +# This class is thread safe. All methods are reentrant. +# +# source://activesupport//lib/active_support/notifications/fanout.rb#50 +class ActiveSupport::Notifications::Fanout + include ::ActiveSupport::Notifications::FanoutIteration + + # @return [Fanout] a new instance of Fanout + # + # source://activesupport//lib/active_support/notifications/fanout.rb#51 + def initialize; end + + # source://activesupport//lib/active_support/notifications/fanout.rb#298 + def all_listeners_for(name); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#273 + def build_handle(name, id, payload); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#102 + def clear_cache(key = T.unsafe(nil)); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#284 + def finish(name, id, payload, listeners = T.unsafe(nil)); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#188 + def groups_for(name); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#60 + def inspect; end + + # source://activesupport//lib/active_support/notifications/fanout.rb#307 + def listeners_for(name); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/notifications/fanout.rb#311 + def listening?(name); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#290 + def publish(name, *args); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#294 + def publish_event(event); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#277 + def start(name, id, payload); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#65 + def subscribe(pattern = T.unsafe(nil), callable = T.unsafe(nil), monotonic: T.unsafe(nil), &block); end + + # source://activesupport//lib/active_support/notifications/fanout.rb#82 + def unsubscribe(subscriber_or_name); end + + # This is a sync queue, so there is no waiting. + # + # source://activesupport//lib/active_support/notifications/fanout.rb#316 + def wait; end +end + +# source://activesupport//lib/active_support/notifications/fanout.rb#114 +class ActiveSupport::Notifications::Fanout::BaseGroup + include ::ActiveSupport::Notifications::FanoutIteration - # Likely on JRuby, TruffleRuby + # @return [BaseGroup] a new instance of BaseGroup # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#162 - def now_allocations; end + # source://activesupport//lib/active_support/notifications/fanout.rb#117 + def initialize(listeners, name, id, payload); end - # source://activesupport//lib/active_support/notifications/instrumenter.rb#152 - def now_cpu; end + # source://activesupport//lib/active_support/notifications/fanout.rb#121 + def each(&block); end end -# This is a default queue implementation that ships with Notifications. -# It just pushes events to all registered log subscribers. -# -# This class is thread safe. All methods are reentrant. -# -# source://activesupport//lib/active_support/notifications/fanout.rb#24 -class ActiveSupport::Notifications::Fanout - include ::Mutex_m +# source://activesupport//lib/active_support/notifications/fanout.rb#126 +class ActiveSupport::Notifications::Fanout::BaseTimeGroup < ::ActiveSupport::Notifications::Fanout::BaseGroup + # source://activesupport//lib/active_support/notifications/fanout.rb#131 + def finish(name, id, payload); end - # @return [Fanout] a new instance of Fanout - # - # source://activesupport//lib/active_support/notifications/fanout.rb#27 - def initialize; end + # source://activesupport//lib/active_support/notifications/fanout.rb#127 + def start(name, id, payload); end +end - # source://activesupport//lib/active_support/notifications/fanout.rb#75 - def finish(name, id, payload, listeners = T.unsafe(nil)); end +# source://activesupport//lib/active_support/notifications/fanout.rb#167 +class ActiveSupport::Notifications::Fanout::EventObjectGroup < ::ActiveSupport::Notifications::Fanout::BaseGroup + # source://activesupport//lib/active_support/notifications/fanout.rb#173 + def finish(name, id, payload); end - # source://activesupport//lib/active_support/notifications/fanout.rb#87 - def iterate_guarding_exceptions(listeners); end + # source://activesupport//lib/active_support/notifications/fanout.rb#168 + def start(name, id, payload); end - # source://activesupport//lib/active_support/notifications/fanout.rb#108 - def listeners_for(name); end + private - # @return [Boolean] - # - # source://activesupport//lib/active_support/notifications/fanout.rb#117 - def listening?(name); end + # source://activesupport//lib/active_support/notifications/fanout.rb#183 + def build_event(name, id, payload); end +end - # source://mutex_m/0.1.2/mutex_m.rb#93 - def lock; end +# source://activesupport//lib/active_support/notifications/fanout.rb#153 +class ActiveSupport::Notifications::Fanout::EventedGroup < ::ActiveSupport::Notifications::Fanout::BaseGroup + # source://activesupport//lib/active_support/notifications/fanout.rb#160 + def finish(name, id, payload); end - # source://mutex_m/0.1.2/mutex_m.rb#83 - def locked?; end + # source://activesupport//lib/active_support/notifications/fanout.rb#154 + def start(name, id, payload); end +end - # source://activesupport//lib/active_support/notifications/fanout.rb#79 - def publish(name, *args); end +# A +Handle+ is used to record the start and finish time of event. +# +# Both #start and #finish must each be called exactly once. +# +# Where possible, it's best to use the block form: ActiveSupport::Notifications.instrument. +# +Handle+ is a low-level API intended for cases where the block form can't be used. +# +# handle = ActiveSupport::Notifications.instrumenter.build_handle("my.event", {}) +# begin +# handle.start +# # work to be instrumented +# ensure +# handle.finish +# end +# +# source://activesupport//lib/active_support/notifications/fanout.rb#228 +class ActiveSupport::Notifications::Fanout::Handle + include ::ActiveSupport::Notifications::FanoutIteration - # source://activesupport//lib/active_support/notifications/fanout.rb#83 - def publish_event(event); end + # @return [Handle] a new instance of Handle + # + # source://activesupport//lib/active_support/notifications/fanout.rb#231 + def initialize(notifier, name, id, payload); end - # source://activesupport//lib/active_support/notifications/fanout.rb#71 - def start(name, id, payload); end + # source://activesupport//lib/active_support/notifications/fanout.rb#250 + def finish; end - # source://activesupport//lib/active_support/notifications/fanout.rb#34 - def subscribe(pattern = T.unsafe(nil), callable = T.unsafe(nil), monotonic: T.unsafe(nil), &block); end + # source://activesupport//lib/active_support/notifications/fanout.rb#254 + def finish_with_values(name, id, payload); end - # source://mutex_m/0.1.2/mutex_m.rb#78 - def synchronize(&block); end + # source://activesupport//lib/active_support/notifications/fanout.rb#241 + def start; end - # source://mutex_m/0.1.2/mutex_m.rb#88 - def try_lock; end + private - # source://mutex_m/0.1.2/mutex_m.rb#98 - def unlock; end + # source://activesupport//lib/active_support/notifications/fanout.rb#264 + def ensure_state!(expected); end +end - # source://activesupport//lib/active_support/notifications/fanout.rb#51 - def unsubscribe(subscriber_or_name); end +# source://activesupport//lib/active_support/notifications/fanout.rb#139 +class ActiveSupport::Notifications::Fanout::MonotonicTimedGroup < ::ActiveSupport::Notifications::Fanout::BaseTimeGroup + private - # This is a sync queue, so there is no waiting. - # - # source://activesupport//lib/active_support/notifications/fanout.rb#122 - def wait; end + # source://activesupport//lib/active_support/notifications/fanout.rb#141 + def now; end end -# source://activesupport//lib/active_support/notifications/fanout.rb#125 +# source://activesupport//lib/active_support/notifications/fanout.rb#319 module ActiveSupport::Notifications::Fanout::Subscribers class << self - # source://activesupport//lib/active_support/notifications/fanout.rb#126 + # source://activesupport//lib/active_support/notifications/fanout.rb#320 def new(pattern, listener, monotonic); end end end -# source://activesupport//lib/active_support/notifications/fanout.rb#257 +# source://activesupport//lib/active_support/notifications/fanout.rb#434 class ActiveSupport::Notifications::Fanout::Subscribers::EventObject < ::ActiveSupport::Notifications::Fanout::Subscribers::Evented - # source://activesupport//lib/active_support/notifications/fanout.rb#265 - def finish(name, id, payload); end + # source://activesupport//lib/active_support/notifications/fanout.rb#435 + def group_class; end - # source://activesupport//lib/active_support/notifications/fanout.rb#273 + # source://activesupport//lib/active_support/notifications/fanout.rb#439 def publish_event(event); end - - # source://activesupport//lib/active_support/notifications/fanout.rb#258 - def start(name, id, payload); end - - private - - # source://activesupport//lib/active_support/notifications/fanout.rb#278 - def build_event(name, id, payload); end end -# source://activesupport//lib/active_support/notifications/fanout.rb#182 +# source://activesupport//lib/active_support/notifications/fanout.rb#376 class ActiveSupport::Notifications::Fanout::Subscribers::Evented # @return [Evented] a new instance of Evented # - # source://activesupport//lib/active_support/notifications/fanout.rb#185 + # source://activesupport//lib/active_support/notifications/fanout.rb#379 def initialize(pattern, delegate); end - # source://activesupport//lib/active_support/notifications/fanout.rb#210 - def finish(name, id, payload); end + # Returns the value of attribute delegate. + # + # source://activesupport//lib/active_support/notifications/fanout.rb#377 + def delegate; end + + # source://activesupport//lib/active_support/notifications/fanout.rb#387 + def group_class; end # Returns the value of attribute pattern. # - # source://activesupport//lib/active_support/notifications/fanout.rb#183 + # source://activesupport//lib/active_support/notifications/fanout.rb#377 def pattern; end - # source://activesupport//lib/active_support/notifications/fanout.rb#192 + # source://activesupport//lib/active_support/notifications/fanout.rb#391 def publish(name, *args); end - # source://activesupport//lib/active_support/notifications/fanout.rb#198 + # source://activesupport//lib/active_support/notifications/fanout.rb#397 def publish_event(event); end - # source://activesupport//lib/active_support/notifications/fanout.rb#206 - def start(name, id, payload); end + # Returns the value of attribute silenceable. + # + # source://activesupport//lib/active_support/notifications/fanout.rb#377 + def silenceable; end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/notifications/fanout.rb#405 + def silenced?(name); end # @return [Boolean] # - # source://activesupport//lib/active_support/notifications/fanout.rb#214 + # source://activesupport//lib/active_support/notifications/fanout.rb#409 def subscribed_to?(name); end - # source://activesupport//lib/active_support/notifications/fanout.rb#218 + # source://activesupport//lib/active_support/notifications/fanout.rb#413 def unsubscribe!(name); end end -# source://activesupport//lib/active_support/notifications/fanout.rb#145 +# source://activesupport//lib/active_support/notifications/fanout.rb#339 class ActiveSupport::Notifications::Fanout::Subscribers::Matcher # @return [Matcher] a new instance of Matcher # - # source://activesupport//lib/active_support/notifications/fanout.rb#158 + # source://activesupport//lib/active_support/notifications/fanout.rb#352 def initialize(pattern); end - # source://activesupport//lib/active_support/notifications/fanout.rb#167 + # source://activesupport//lib/active_support/notifications/fanout.rb#361 def ===(name); end # Returns the value of attribute exclusions. # - # source://activesupport//lib/active_support/notifications/fanout.rb#146 + # source://activesupport//lib/active_support/notifications/fanout.rb#340 def exclusions; end # Returns the value of attribute pattern. # - # source://activesupport//lib/active_support/notifications/fanout.rb#146 + # source://activesupport//lib/active_support/notifications/fanout.rb#340 def pattern; end - # source://activesupport//lib/active_support/notifications/fanout.rb#163 + # source://activesupport//lib/active_support/notifications/fanout.rb#357 def unsubscribe!(name); end class << self - # source://activesupport//lib/active_support/notifications/fanout.rb#148 + # source://activesupport//lib/active_support/notifications/fanout.rb#342 def wrap(pattern); end end end -# source://activesupport//lib/active_support/notifications/fanout.rb#171 +# source://activesupport//lib/active_support/notifications/fanout.rb#365 class ActiveSupport::Notifications::Fanout::Subscribers::Matcher::AllMessages - # source://activesupport//lib/active_support/notifications/fanout.rb#172 + # source://activesupport//lib/active_support/notifications/fanout.rb#366 def ===(name); end - # source://activesupport//lib/active_support/notifications/fanout.rb#176 + # source://activesupport//lib/active_support/notifications/fanout.rb#370 def unsubscribe!(*_arg0); end end -# source://activesupport//lib/active_support/notifications/fanout.rb#240 -class ActiveSupport::Notifications::Fanout::Subscribers::MonotonicTimed < ::ActiveSupport::Notifications::Fanout::Subscribers::Evented - # source://activesupport//lib/active_support/notifications/fanout.rb#250 - def finish(name, id, payload); end - - # source://activesupport//lib/active_support/notifications/fanout.rb#241 - def publish(name, *args); end - - # source://activesupport//lib/active_support/notifications/fanout.rb#245 - def start(name, id, payload); end +# source://activesupport//lib/active_support/notifications/fanout.rb#428 +class ActiveSupport::Notifications::Fanout::Subscribers::MonotonicTimed < ::ActiveSupport::Notifications::Fanout::Subscribers::Timed + # source://activesupport//lib/active_support/notifications/fanout.rb#429 + def group_class; end end -# source://activesupport//lib/active_support/notifications/fanout.rb#223 +# source://activesupport//lib/active_support/notifications/fanout.rb#418 class ActiveSupport::Notifications::Fanout::Subscribers::Timed < ::ActiveSupport::Notifications::Fanout::Subscribers::Evented - # source://activesupport//lib/active_support/notifications/fanout.rb#233 - def finish(name, id, payload); end + # source://activesupport//lib/active_support/notifications/fanout.rb#419 + def group_class; end - # source://activesupport//lib/active_support/notifications/fanout.rb#224 + # source://activesupport//lib/active_support/notifications/fanout.rb#423 def publish(name, *args); end +end - # source://activesupport//lib/active_support/notifications/fanout.rb#228 - def start(name, id, payload); end +# source://activesupport//lib/active_support/notifications/fanout.rb#146 +class ActiveSupport::Notifications::Fanout::TimedGroup < ::ActiveSupport::Notifications::Fanout::BaseTimeGroup + private + + # source://activesupport//lib/active_support/notifications/fanout.rb#148 + def now; end +end + +# source://activesupport//lib/active_support/notifications/fanout.rb#19 +module ActiveSupport::Notifications::FanoutIteration + private + + # source://activesupport//lib/active_support/notifications/fanout.rb#21 + def iterate_guarding_exceptions(collection); end end -# source://activesupport//lib/active_support/notifications/fanout.rb#10 +# source://activesupport//lib/active_support/notifications/fanout.rb#9 class ActiveSupport::Notifications::InstrumentationSubscriberError < ::RuntimeError # @return [InstrumentationSubscriberError] a new instance of InstrumentationSubscriberError # - # source://activesupport//lib/active_support/notifications/fanout.rb#13 + # source://activesupport//lib/active_support/notifications/fanout.rb#12 def initialize(exceptions); end # Returns the value of attribute exceptions. # - # source://activesupport//lib/active_support/notifications/fanout.rb#11 + # source://activesupport//lib/active_support/notifications/fanout.rb#10 def exceptions; end end # Instrumenters are stored in a thread local. # -# source://activesupport//lib/active_support/notifications/instrumenter.rb#8 +# source://activesupport//lib/active_support/notifications/instrumenter.rb#9 class ActiveSupport::Notifications::Instrumenter # @return [Instrumenter] a new instance of Instrumenter # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#11 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#12 def initialize(notifier); end + # Returns a "handle" for an event with the given +name+ and +payload+. + # + # #start and #finish must each be called exactly once on the returned object. + # + # Where possible, it's best to use #instrument, which will record the + # start and finish of the event and correctly handle any exceptions. + # +build_handle+ is a low-level API intended for cases where using + # +instrument+ isn't possible. + # + # See ActiveSupport::Notifications::Fanout::Handle. + # + # source://activesupport//lib/active_support/notifications/instrumenter.rb#78 + def build_handle(name, payload); end + # Send a finish notification with +name+ and +payload+. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#44 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#92 def finish(name, payload); end - # source://activesupport//lib/active_support/notifications/instrumenter.rb#48 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#96 def finish_with_state(listeners_state, name, payload); end # Returns the value of attribute id. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#9 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#10 def id; end # Given a block, instrument it by measuring the time taken to execute @@ -8511,495 +10234,578 @@ class ActiveSupport::Notifications::Instrumenter # notifier. Notice that events get sent even if an error occurs in the # passed-in block. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#20 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#54 def instrument(name, payload = T.unsafe(nil)); end - # source://activesupport//lib/active_support/notifications/instrumenter.rb#34 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#82 def new_event(name, payload = T.unsafe(nil)); end # Send a start notification with +name+ and +payload+. # - # source://activesupport//lib/active_support/notifications/instrumenter.rb#39 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#87 def start(name, payload); end private - # source://activesupport//lib/active_support/notifications/instrumenter.rb#53 + # source://activesupport//lib/active_support/notifications/instrumenter.rb#101 def unique_id; end end +# source://activesupport//lib/active_support/notifications/instrumenter.rb#21 +class ActiveSupport::Notifications::Instrumenter::LegacyHandle + # @return [LegacyHandle] a new instance of LegacyHandle + # + # source://activesupport//lib/active_support/notifications/instrumenter.rb#34 + def initialize(notifier, name, id, payload); end + + # source://activesupport//lib/active_support/notifications/instrumenter.rb#45 + def finish; end + + # source://activesupport//lib/active_support/notifications/instrumenter.rb#41 + def start; end +end + +# source://activesupport//lib/active_support/notifications/instrumenter.rb#22 +class ActiveSupport::Notifications::Instrumenter::LegacyHandle::Wrapper + # @return [Wrapper] a new instance of Wrapper + # + # source://activesupport//lib/active_support/notifications/instrumenter.rb#23 + def initialize(notifier); end + + # source://activesupport//lib/active_support/notifications/instrumenter.rb#27 + def build_handle(name, id, payload); end + + # source://activesupport//lib/active_support/notifications/instrumenter.rb#31 + def finish(*_arg0, **_arg1, &_arg2); end + + # source://activesupport//lib/active_support/notifications/instrumenter.rb#31 + def start(*_arg0, **_arg1, &_arg2); end +end + # source://activesupport//lib/active_support/number_helper.rb#4 module ActiveSupport::NumberHelper extend ::ActiveSupport::Autoload extend ::ActiveSupport::NumberHelper - # Formats a +number+ into a currency string (e.g., $13.65). You - # can customize the format in the +options+ hash. + # Formats a +number+ into a currency string. + # + # number_to_currency(1234567890.50) # => "$1,234,567,890.50" + # number_to_currency(1234567890.506) # => "$1,234,567,890.51" + # number_to_currency("12x34") # => "$12x34" + # + # number_to_currency(1234567890.50, unit: "£", separator: ",", delimiter: "") + # # => "£1234567890,50" # # The currency unit and number formatting of the current locale will be used - # unless otherwise specified in the provided options. No currency conversion - # is performed. If the user is given a way to change their locale, they will + # unless otherwise specified via options. No currency conversion is + # performed. If the user is given a way to change their locale, they will # also be able to change the relative value of the currency displayed with # this helper. If your application will ever support multiple locales, you - # may want to specify a constant :locale option or consider - # using a library capable of currency conversion. + # may want to specify a constant +:locale+ option or consider using a + # library capable of currency conversion. # # ==== Options # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the level of precision (defaults - # to 2). - # * :round_mode - Determine how rounding is performed - # (defaults to :default. See BigDecimal::mode) - # * :unit - Sets the denomination of the currency - # (defaults to "$"). - # * :separator - Sets the separator between the units - # (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ","). - # * :format - Sets the format for non-negative numbers - # (defaults to "%u%n"). Fields are %u for the - # currency, and %n for the number. - # * :negative_format - Sets the format for negative - # numbers (defaults to prepending a hyphen to the formatted - # number given by :format). Accepts the same fields - # than :format, except %n is here the - # absolute value of the number. - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +false+). + # [+:locale+] + # The locale to use for formatting. Defaults to the current locale. # - # ==== Examples + # number_to_currency(1234567890.506, locale: :fr) + # # => "1 234 567 890,51 €" # - # number_to_currency(1234567890.50) # => "$1,234,567,890.50" - # number_to_currency(1234567890.506) # => "$1,234,567,890.51" - # number_to_currency(1234567890.506, precision: 3) # => "$1,234,567,890.506" - # number_to_currency(1234567890.506, locale: :fr) # => "1 234 567 890,51 €" - # number_to_currency('123a456') # => "$123a456" - # - # number_to_currency(-0.456789, precision: 0) - # # => "$0" - # number_to_currency(-1234567890.50, negative_format: '(%u%n)') - # # => "($1,234,567,890.50)" - # number_to_currency(1234567890.50, unit: '£', separator: ',', delimiter: '') - # # => "£1234567890,50" - # number_to_currency(1234567890.50, unit: '£', separator: ',', delimiter: '', format: '%n %u') - # # => "1234567890,50 £" - # number_to_currency(1234567890.50, strip_insignificant_zeros: true) - # # => "$1,234,567,890.5" - # number_to_currency(1234567890.50, precision: 0, round_mode: :up) - # # => "$1,234,567,891" - # - # source://activesupport//lib/active_support/number_helper.rb#114 + # [+:precision+] + # The level of precision. Defaults to 2. + # + # number_to_currency(1234567890.123, precision: 3) # => "$1,234,567,890.123" + # number_to_currency(0.456789, precision: 0) # => "$0" + # + # [+:round_mode+] + # Specifies how rounding is performed. See +BigDecimal.mode+. Defaults to + # +:default+. + # + # number_to_currency(1234567890.01, precision: 0, round_mode: :up) + # # => "$1,234,567,891" + # + # [+:unit+] + # The denomination of the currency. Defaults to "$". + # + # [+:separator+] + # The decimal separator. Defaults to ".". + # + # [+:delimiter+] + # The thousands delimiter. Defaults to ",". + # + # [+:format+] + # The format for non-negative numbers. %u represents the currency, + # and %n represents the number. Defaults to "%u%n". + # + # number_to_currency(1234567890.50, format: "%n %u") + # # => "1,234,567,890.50 $" + # + # [+:negative_format+] + # The format for negative numbers. %u and %n behave the + # same as in +:format+, but %n represents the absolute value of + # the number. Defaults to the value of +:format+ prepended with -. + # + # number_to_currency(-1234567890.50, negative_format: "(%u%n)") + # # => "($1,234,567,890.50)" + # + # [+:strip_insignificant_zeros+] + # Whether to remove insignificant zeros after the decimal separator. + # Defaults to false. + # + # number_to_currency(1234567890.50, strip_insignificant_zeros: true) + # # => "$1,234,567,890.5" + # + # source://activesupport//lib/active_support/number_helper.rb#139 def number_to_currency(number, options = T.unsafe(nil)); end - # Formats a +number+ with grouped thousands using +delimiter+ - # (e.g., 12,324). You can customize the format in the +options+ - # hash. + # Formats +number+ by grouping thousands with a delimiter. + # + # number_to_delimited(12345678) # => "12,345,678" + # number_to_delimited("123456") # => "123,456" + # number_to_delimited(12345678.9876) # => "12,345,678.9876" + # number_to_delimited("12x34") # => "12x34" + # + # number_to_delimited(12345678.9876, delimiter: ".", separator: ",") + # # => "12.345.678,9876" # # ==== Options # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :delimiter - Sets the thousands delimiter (defaults - # to ","). - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter_pattern - Sets a custom regular expression used for - # deriving the placement of delimiter. Helpful when using currency formats - # like INR. + # [+:locale+] + # The locale to use for formatting. Defaults to the current locale. # - # ==== Examples + # number_to_delimited(12345678.05, locale: :fr) + # # => "12 345 678,05" + # + # [+:delimiter+] + # The thousands delimiter. Defaults to ",". + # + # number_to_delimited(12345678, delimiter: ".") + # # => "12.345.678" + # + # [+:separator+] + # The decimal separator. Defaults to ".". # - # number_to_delimited(12345678) # => "12,345,678" - # number_to_delimited('123456') # => "123,456" - # number_to_delimited(12345678.05) # => "12,345,678.05" - # number_to_delimited(12345678, delimiter: '.') # => "12.345.678" - # number_to_delimited(12345678, delimiter: ',') # => "12,345,678" - # number_to_delimited(12345678.05, separator: ' ') # => "12,345,678 05" - # number_to_delimited(12345678.05, locale: :fr) # => "12 345 678,05" - # number_to_delimited('112a') # => "112a" - # number_to_delimited(98765432.98, delimiter: ' ', separator: ',') - # # => "98 765 432,98" - # number_to_delimited("123456.78", - # delimiter_pattern: /(\d+?)(?=(\d\d)+(\d)(?!\d))/) - # # => "1,23,456.78" - # - # source://activesupport//lib/active_support/number_helper.rb#189 + # number_to_delimited(12345678.05, separator: " ") + # # => "12,345,678 05" + # + # [+:delimiter_pattern+] + # A regexp to determine the placement of delimiters. Helpful when using + # currency formats like INR. + # + # number_to_delimited("123456.78", delimiter_pattern: /(\d+?)(?=(\d\d)+(\d)(?!\d))/) + # # => "1,23,456.78" + # + # source://activesupport//lib/active_support/number_helper.rb#242 def number_to_delimited(number, options = T.unsafe(nil)); end - # Pretty prints (formats and approximates) a number in a way it - # is more readable by humans (e.g.: 1200000000 becomes "1.2 - # Billion"). This is useful for numbers that can get very large - # (and too hard to read). + # Formats +number+ into a more human-friendly representation. Useful for + # numbers that can become very large and too hard to read. # - # See number_to_human_size if you want to print a file - # size. + # number_to_human(123) # => "123" + # number_to_human(1234) # => "1.23 Thousand" + # number_to_human(12345) # => "12.3 Thousand" + # number_to_human(1234567) # => "1.23 Million" + # number_to_human(1234567890) # => "1.23 Billion" + # number_to_human(1234567890123) # => "1.23 Trillion" + # number_to_human(1234567890123456) # => "1.23 Quadrillion" + # number_to_human(1234567890123456789) # => "1230 Quadrillion" # - # You can also define your own unit-quantifier names if you want - # to use other decimal units (e.g.: 1500 becomes "1.5 - # kilometers", 0.150 becomes "150 milliliters", etc). You may - # define a wide range of unit quantifiers, even fractional ones - # (centi, deci, mili, etc). + # See #number_to_human_size if you want to pretty-print a file size. # # ==== Options # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). - # * :round_mode - Determine how rounding is performed - # (defaults to :default. See BigDecimal::mode) - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +true+) - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +true+) - # * :units - A Hash of unit quantifier names. Or a - # string containing an i18n scope where to find this hash. It - # might have the following keys: - # * *integers*: :unit, :ten, - # :hundred, :thousand, :million, - # :billion, :trillion, - # :quadrillion - # * *fractionals*: :deci, :centi, - # :mili, :micro, :nano, - # :pico, :femto - # * :format - Sets the format of the output string - # (defaults to "%n %u"). The field types are: - # * %u - The quantifier (ex.: 'thousand') - # * %n - The number - # - # ==== Examples - # - # number_to_human(123) # => "123" - # number_to_human(1234) # => "1.23 Thousand" - # number_to_human(12345) # => "12.3 Thousand" - # number_to_human(1234567) # => "1.23 Million" - # number_to_human(1234567890) # => "1.23 Billion" - # number_to_human(1234567890123) # => "1.23 Trillion" - # number_to_human(1234567890123456) # => "1.23 Quadrillion" - # number_to_human(1234567890123456789) # => "1230 Quadrillion" - # number_to_human(489939, precision: 2) # => "490 Thousand" - # number_to_human(489939, precision: 4) # => "489.9 Thousand" - # number_to_human(489939, precision: 2 - # , round_mode: :down) # => "480 Thousand" - # number_to_human(1234567, precision: 4, - # significant: false) # => "1.2346 Million" - # number_to_human(1234567, precision: 1, - # separator: ',', - # significant: false) # => "1,2 Million" - # - # number_to_human(500000000, precision: 5) # => "500 Million" - # number_to_human(12345012345, significant: false) # => "12.345 Billion" - # - # Non-significant zeros after the decimal separator are stripped - # out by default (set :strip_insignificant_zeros to - # +false+ to change that): - # - # number_to_human(12.00001) # => "12" - # number_to_human(12.00001, strip_insignificant_zeros: false) # => "12.0" - # - # ==== Custom Unit Quantifiers - # - # You can also use your own custom unit quantifiers: - # - # number_to_human(500000, units: { unit: 'ml', thousand: 'lt' }) # => "500 lt" - # - # If in your I18n locale you have: - # - # distance: - # centi: - # one: "centimeter" - # other: "centimeters" - # unit: - # one: "meter" - # other: "meters" - # thousand: - # one: "kilometer" - # other: "kilometers" - # billion: "gazillion-distance" - # - # Then you could do: - # - # number_to_human(543934, units: :distance) # => "544 kilometers" - # number_to_human(54393498, units: :distance) # => "54400 kilometers" - # number_to_human(54393498000, units: :distance) # => "54.4 gazillion-distance" - # number_to_human(343, units: :distance, precision: 1) # => "300 meters" - # number_to_human(1, units: :distance) # => "1 meter" - # number_to_human(0.34, units: :distance) # => "34 centimeters" - # - # source://activesupport//lib/active_support/number_helper.rb#392 + # [+:locale+] + # The locale to use for formatting. Defaults to the current locale. + # + # [+:precision+] + # The level of precision. Defaults to 3. + # + # number_to_human(123456, precision: 2) # => "120 Thousand" + # number_to_human(123456, precision: 4) # => "123.5 Thousand" + # + # [+:round_mode+] + # Specifies how rounding is performed. See +BigDecimal.mode+. Defaults to + # +:default+. + # + # number_to_human(123456, precision: 2, round_mode: :up) + # # => "130 Thousand" + # + # [+:significant+] + # Whether +:precision+ should be applied to significant digits instead of + # fractional digits. Defaults to true. + # + # [+:separator+] + # The decimal separator. Defaults to ".". + # + # number_to_human(123456, precision: 4, separator: ",") + # # => "123,5 Thousand" + # + # [+:delimiter+] + # The thousands delimiter. Defaults to ",". + # + # [+:strip_insignificant_zeros+] + # Whether to remove insignificant zeros after the decimal separator. + # Defaults to true. + # + # number_to_human(1000000) # => "1 Million" + # number_to_human(1000000, strip_insignificant_zeros: false) # => "1.00 Million" + # number_to_human(10.01) # => "10" + # number_to_human(10.01, strip_insignificant_zeros: false) # => "10.0" + # + # [+:format+] + # The format of the output. %n represents the number, and + # %u represents the quantifier (e.g., "Thousand"). Defaults to + # "%n %u". + # + # [+:units+] + # A Hash of custom unit quantifier names. + # + # number_to_human(1, units: { unit: "m", thousand: "km" }) # => "1 m" + # number_to_human(100, units: { unit: "m", thousand: "km" }) # => "100 m" + # number_to_human(1000, units: { unit: "m", thousand: "km" }) # => "1 km" + # number_to_human(100000, units: { unit: "m", thousand: "km" }) # => "100 km" + # number_to_human(10000000, units: { unit: "m", thousand: "km" }) # => "10000 km" + # + # The following keys are supported for integer units: +:unit+, +:ten+, + # +:hundred+, +:thousand+, +:million+, +:billion+, +:trillion+, + # +:quadrillion+. Additionally, the following keys are supported for + # fractional units: +:deci+, +:centi+, +:mili+, +:micro+, +:nano+, + # +:pico+, +:femto+. + # + # The Hash can also be defined as a scope in an I18n locale. For example: + # + # en: + # distance: + # centi: + # one: "centimeter" + # other: "centimeters" + # unit: + # one: "meter" + # other: "meters" + # thousand: + # one: "kilometer" + # other: "kilometers" + # + # Then it can be specified by name: + # + # number_to_human(1, units: :distance) # => "1 meter" + # number_to_human(100, units: :distance) # => "100 meters" + # number_to_human(1000, units: :distance) # => "1 kilometer" + # number_to_human(100000, units: :distance) # => "100 kilometers" + # number_to_human(10000000, units: :distance) # => "10000 kilometers" + # number_to_human(0.1, units: :distance) # => "10 centimeters" + # number_to_human(0.01, units: :distance) # => "1 centimeter" + # + # source://activesupport//lib/active_support/number_helper.rb#453 def number_to_human(number, options = T.unsafe(nil)); end - # Formats the bytes in +number+ into a more understandable - # representation (e.g., giving it 1500 yields 1.46 KB). This - # method is useful for reporting file sizes to users. You can - # customize the format in the +options+ hash. + # Formats +number+ as bytes into a more human-friendly representation. + # Useful for reporting file sizes to users. # - # See number_to_human if you want to pretty-print a - # generic number. + # number_to_human_size(123) # => "123 Bytes" + # number_to_human_size(1234) # => "1.21 KB" + # number_to_human_size(12345) # => "12.1 KB" + # number_to_human_size(1234567) # => "1.18 MB" + # number_to_human_size(1234567890) # => "1.15 GB" + # number_to_human_size(1234567890123) # => "1.12 TB" + # number_to_human_size(1234567890123456) # => "1.1 PB" + # number_to_human_size(1234567890123456789) # => "1.07 EB" + # + # See #number_to_human if you want to pretty-print a generic number. # # ==== Options # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). - # * :round_mode - Determine how rounding is performed - # (defaults to :default. See BigDecimal::mode) - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +true+) - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +true+) + # [+:locale+] + # The locale to use for formatting. Defaults to the current locale. # - # ==== Examples + # [+:precision+] + # The level of precision. Defaults to 3. # - # number_to_human_size(123) # => "123 Bytes" - # number_to_human_size(1234) # => "1.21 KB" - # number_to_human_size(12345) # => "12.1 KB" - # number_to_human_size(1234567) # => "1.18 MB" - # number_to_human_size(1234567890) # => "1.15 GB" - # number_to_human_size(1234567890123) # => "1.12 TB" - # number_to_human_size(1234567890123456) # => "1.1 PB" - # number_to_human_size(1234567890123456789) # => "1.07 EB" - # number_to_human_size(1234567, precision: 2) # => "1.2 MB" - # number_to_human_size(483989, precision: 2) # => "470 KB" - # number_to_human_size(483989, precision: 2, round_mode: :up) # => "480 KB" - # number_to_human_size(1234567, precision: 2, separator: ',') # => "1,2 MB" - # number_to_human_size(1234567890123, precision: 5) # => "1.1228 TB" - # number_to_human_size(524288000, precision: 5) # => "500 MB" - # - # source://activesupport//lib/active_support/number_helper.rb#283 + # number_to_human_size(123456, precision: 2) # => "120 KB" + # number_to_human_size(1234567, precision: 2) # => "1.2 MB" + # + # [+:round_mode+] + # Specifies how rounding is performed. See +BigDecimal.mode+. Defaults to + # +:default+. + # + # number_to_human_size(123456, precision: 2, round_mode: :up) + # # => "130 KB" + # + # [+:significant+] + # Whether +:precision+ should be applied to significant digits instead of + # fractional digits. Defaults to true. + # + # [+:separator+] + # The decimal separator. Defaults to ".". + # + # number_to_human_size(1234567, separator: ",") + # # => "1,18 MB" + # + # [+:delimiter+] + # The thousands delimiter. Defaults to ",". + # + # [+:strip_insignificant_zeros+] + # Whether to remove insignificant zeros after the decimal separator. + # Defaults to true. + # + # source://activesupport//lib/active_support/number_helper.rb#351 def number_to_human_size(number, options = T.unsafe(nil)); end - # Formats a +number+ as a percentage string (e.g., 65%). You can - # customize the format in the +options+ hash. + # Formats +number+ as a percentage string. + # + # number_to_percentage(100) # => "100.000%" + # number_to_percentage("99") # => "99.000%" + # number_to_percentage("99x") # => "99x%" + # + # number_to_percentage(12345.6789, delimiter: ".", separator: ",", precision: 2) + # # => "12.345,68%" # # ==== Options # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). Keeps the number's precision if +nil+. - # * :round_mode - Determine how rounding is performed - # (defaults to :default. See BigDecimal::mode) - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +false+). - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +false+). - # * :format - Specifies the format of the percentage - # string The number field is %n (defaults to "%n%"). + # [+:locale+] + # The locale to use for formatting. Defaults to the current locale. # - # ==== Examples + # number_to_percentage(1000, locale: :fr) + # # => "1000,000%" + # + # [+:precision+] + # The level of precision, or +nil+ to preserve +number+'s precision. + # Defaults to 2. + # + # number_to_percentage(12.3456789, precision: 4) # => "12.3457%" + # number_to_percentage(99.999, precision: 0) # => "100%" + # number_to_percentage(99.999, precision: nil) # => "99.999%" + # + # [+:round_mode+] + # Specifies how rounding is performed. See +BigDecimal.mode+. Defaults to + # +:default+. + # + # number_to_percentage(12.3456789, precision: 4, round_mode: :down) + # # => "12.3456%" + # + # [+:significant+] + # Whether +:precision+ should be applied to significant digits instead of + # fractional digits. Defaults to false. # - # number_to_percentage(100) # => "100.000%" - # number_to_percentage('98') # => "98.000%" - # number_to_percentage(100, precision: 0) # => "100%" - # number_to_percentage(1000, delimiter: '.', separator: ',') # => "1.000,000%" - # number_to_percentage(302.24398923423, precision: 5) # => "302.24399%" - # number_to_percentage(1000, locale: :fr) # => "1000,000%" - # number_to_percentage(1000, precision: nil) # => "1000%" - # number_to_percentage('98a') # => "98a%" - # number_to_percentage(100, format: '%n %') # => "100.000 %" - # number_to_percentage(302.24398923423, precision: 5, round_mode: :down) # => "302.24398%" - # - # source://activesupport//lib/active_support/number_helper.rb#154 + # number_to_percentage(12345.6789) # => "12345.679%" + # number_to_percentage(12345.6789, significant: true) # => "12300%" + # number_to_percentage(12345.6789, precision: 2) # => "12345.68%" + # number_to_percentage(12345.6789, precision: 2, significant: true) # => "12000%" + # + # [+:separator+] + # The decimal separator. Defaults to ".". + # + # [+:delimiter+] + # The thousands delimiter. Defaults to ",". + # + # [+:strip_insignificant_zeros+] + # Whether to remove insignificant zeros after the decimal separator. + # Defaults to false. + # + # [+:format+] + # The format of the output. %n represents the number. Defaults to + # "%n%". + # + # number_to_percentage(100, format: "%n %") + # # => "100.000 %" + # + # source://activesupport//lib/active_support/number_helper.rb#201 def number_to_percentage(number, options = T.unsafe(nil)); end - # Formats a +number+ into a phone number (US by default e.g., (555) - # 123-9876). You can customize the format in the +options+ hash. + # Formats +number+ into a phone number. + # + # number_to_phone(5551234) # => "555-1234" + # number_to_phone("5551234") # => "555-1234" + # number_to_phone(1235551234) # => "123-555-1234" + # number_to_phone("12x34") # => "12x34" + # + # number_to_phone(1235551234, delimiter: ".", country_code: 1, extension: 1343) + # # => "+1.123.555.1234 x 1343" # # ==== Options # - # * :area_code - Adds parentheses around the area code. - # * :delimiter - Specifies the delimiter to use - # (defaults to "-"). - # * :extension - Specifies an extension to add to the - # end of the generated number. - # * :country_code - Sets the country code for the phone - # number. - # * :pattern - Specifies how the number is divided into three - # groups with the custom regexp to override the default format. - # ==== Examples + # [+:area_code+] + # Whether to use parentheses for the area code. Defaults to false. # - # number_to_phone(5551234) # => "555-1234" - # number_to_phone('5551234') # => "555-1234" - # number_to_phone(1235551234) # => "123-555-1234" - # number_to_phone(1235551234, area_code: true) # => "(123) 555-1234" - # number_to_phone(1235551234, delimiter: ' ') # => "123 555 1234" - # number_to_phone(1235551234, area_code: true, extension: 555) # => "(123) 555-1234 x 555" - # number_to_phone(1235551234, country_code: 1) # => "+1-123-555-1234" - # number_to_phone('123a456') # => "123a456" + # number_to_phone(1235551234, area_code: true) + # # => "(123) 555-1234" # - # number_to_phone(1235551234, country_code: 1, extension: 1343, delimiter: '.') - # # => "+1.123.555.1234 x 1343" + # [+:delimiter+] + # The digit group delimiter to use. Defaults to "-". + # + # number_to_phone(1235551234, delimiter: " ") + # # => "123 555 1234" + # + # [+:country_code+] + # A country code to prepend. + # + # number_to_phone(1235551234, country_code: 1) + # # => "+1-123-555-1234" + # + # [+:extension+] + # An extension to append. + # + # number_to_phone(1235551234, extension: 555) + # # => "123-555-1234 x 555" # - # number_to_phone(75561234567, pattern: /(\d{1,4})(\d{4})(\d{4})$/, area_code: true) - # # => "(755) 6123-4567" - # number_to_phone(13312345678, pattern: /(\d{3})(\d{4})(\d{4})$/) - # # => "133-1234-5678" + # [+:pattern+] + # A regexp that specifies how the digits should be grouped. The first + # three captures from the regexp are treated as digit groups. # - # source://activesupport//lib/active_support/number_helper.rb#53 + # number_to_phone(13312345678, pattern: /(\d{3})(\d{4})(\d{4})$/) + # # => "133-1234-5678" + # number_to_phone(75561234567, pattern: /(\d{1,4})(\d{4})(\d{4})$/, area_code: true) + # # => "(755) 6123-4567" + # + # source://activesupport//lib/active_support/number_helper.rb#66 def number_to_phone(number, options = T.unsafe(nil)); end - # Formats a +number+ with the specified level of - # :precision (e.g., 112.32 has a precision of 2 if - # +:significant+ is +false+, and 5 if +:significant+ is +true+). - # You can customize the format in the +options+ hash. + # Formats +number+ to a specific level of precision. + # + # number_to_rounded(12345.6789) # => "12345.679" + # number_to_rounded(12345.6789, precision: 2) # => "12345.68" + # number_to_rounded(12345.6789, precision: 0) # => "12345" + # number_to_rounded(12345, precision: 5) # => "12345.00000" # # ==== Options # - # * :locale - Sets the locale to be used for formatting - # (defaults to current locale). - # * :precision - Sets the precision of the number - # (defaults to 3). Keeps the number's precision if +nil+. - # * :round_mode - Determine how rounding is performed - # (defaults to :default. See BigDecimal::mode) - # * :significant - If +true+, precision will be the number - # of significant_digits. If +false+, the number of fractional - # digits (defaults to +false+). - # * :separator - Sets the separator between the - # fractional and integer digits (defaults to "."). - # * :delimiter - Sets the thousands delimiter (defaults - # to ""). - # * :strip_insignificant_zeros - If +true+ removes - # insignificant zeros after the decimal separator (defaults to - # +false+). + # [+:locale+] + # The locale to use for formatting. Defaults to the current locale. # - # ==== Examples + # number_to_rounded(111.234, locale: :fr) + # # => "111,234" + # + # [+:precision+] + # The level of precision, or +nil+ to preserve +number+'s precision. + # Defaults to 3. + # + # number_to_rounded(12345.6789, precision: nil) + # # => "12345.6789" + # + # [+:round_mode+] + # Specifies how rounding is performed. See +BigDecimal.mode+. Defaults to + # +:default+. + # + # number_to_rounded(12.34, precision: 0, round_mode: :up) + # # => "13" + # + # [+:significant+] + # Whether +:precision+ should be applied to significant digits instead of + # fractional digits. Defaults to false. # - # number_to_rounded(111.2345) # => "111.235" - # number_to_rounded(111.2345, precision: 2) # => "111.23" - # number_to_rounded(13, precision: 5) # => "13.00000" - # number_to_rounded(389.32314, precision: 0) # => "389" - # number_to_rounded(111.2345, significant: true) # => "111" - # number_to_rounded(111.2345, precision: 1, significant: true) # => "100" - # number_to_rounded(13, precision: 5, significant: true) # => "13.000" - # number_to_rounded(13, precision: nil) # => "13" - # number_to_rounded(389.32314, precision: 0, round_mode: :up) # => "390" - # number_to_rounded(111.234, locale: :fr) # => "111,234" - # - # number_to_rounded(13, precision: 5, significant: true, strip_insignificant_zeros: true) - # # => "13" - # - # number_to_rounded(389.32314, precision: 4, significant: true) # => "389.3" - # number_to_rounded(1111.2345, precision: 2, separator: ',', delimiter: '.') - # # => "1.111,23" - # - # source://activesupport//lib/active_support/number_helper.rb#236 + # number_to_rounded(12345.6789) # => "12345.679" + # number_to_rounded(12345.6789, significant: true) # => "12300" + # number_to_rounded(12345.6789, precision: 2) # => "12345.68" + # number_to_rounded(12345.6789, precision: 2, significant: true) # => "12000" + # + # [+:separator+] + # The decimal separator. Defaults to ".". + # + # [+:delimiter+] + # The thousands delimiter. Defaults to ",". + # + # [+:strip_insignificant_zeros+] + # Whether to remove insignificant zeros after the decimal separator. + # Defaults to false. + # + # number_to_rounded(12.34, strip_insignificant_zeros: false) # => "12.340" + # number_to_rounded(12.34, strip_insignificant_zeros: true) # => "12.34" + # number_to_rounded(12.3456, strip_insignificant_zeros: true) # => "12.346" + # + # source://activesupport//lib/active_support/number_helper.rb#298 def number_to_rounded(number, options = T.unsafe(nil)); end end -# source://activesupport//lib/active_support/number_helper/number_converter.rb#11 +# source://activesupport//lib/active_support/number_helper/number_converter.rb#12 class ActiveSupport::NumberHelper::NumberConverter # @return [NumberConverter] a new instance of NumberConverter # - # source://activesupport//lib/active_support/number_helper/number_converter.rb#123 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#124 def initialize(number, options); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#128 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#130 def execute; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace=(_arg0); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace?; end # Returns the value of attribute number. # - # source://activesupport//lib/active_support/number_helper/number_converter.rb#18 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#19 def number; end # Returns the value of attribute opts. # - # source://activesupport//lib/active_support/number_helper/number_converter.rb#18 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#19 def opts; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float=(_arg0); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float?; end private - # source://activesupport//lib/active_support/number_helper/number_converter.rb#147 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#149 def default_format_options; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#172 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#174 def default_value(key); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#143 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#145 def format_options; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#153 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#155 def i18n_format_options; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#139 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#141 def options; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#168 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#170 def translate_in_locale(key, **i18n_options); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#164 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#166 def translate_number_value_with_default(key, **i18n_options); end - # @return [Boolean] - # - # source://activesupport//lib/active_support/number_helper/number_converter.rb#176 - def valid_float?; end + # source://activesupport//lib/active_support/number_helper/number_converter.rb#178 + def valid_bigdecimal; end class << self - # source://activesupport//lib/active_support/number_helper/number_converter.rb#119 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#120 def convert(number, options); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace=(value); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace?; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float=(value); end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float?; end end end -# source://activesupport//lib/active_support/number_helper/number_converter.rb#20 +# source://activesupport//lib/active_support/number_helper/number_converter.rb#21 ActiveSupport::NumberHelper::NumberConverter::DEFAULTS = T.let(T.unsafe(nil), Hash) # source://activesupport//lib/active_support/number_helper/number_to_currency_converter.rb#7 @@ -9016,7 +10822,7 @@ class ActiveSupport::NumberHelper::NumberToCurrencyConverter < ::ActiveSupport:: def options; end class << self - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace; end end end @@ -9035,7 +10841,7 @@ class ActiveSupport::NumberHelper::NumberToDelimitedConverter < ::ActiveSupport: def parts; end class << self - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float; end end end @@ -9063,10 +10869,10 @@ class ActiveSupport::NumberHelper::NumberToHumanConverter < ::ActiveSupport::Num def unit_exponents(units); end class << self - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float; end end end @@ -9105,10 +10911,10 @@ class ActiveSupport::NumberHelper::NumberToHumanSizeConverter < ::ActiveSupport: def unit; end class << self - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float; end end end @@ -9122,42 +10928,42 @@ class ActiveSupport::NumberHelper::NumberToPercentageConverter < ::ActiveSupport def convert; end class << self - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace; end end end -# source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#7 +# source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#8 class ActiveSupport::NumberHelper::NumberToPhoneConverter < ::ActiveSupport::NumberHelper::NumberConverter - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#8 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#9 def convert; end private - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#15 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#16 def convert_to_phone_number(number); end - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#23 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#24 def convert_with_area_code(number); end - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#30 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#31 def convert_without_area_code(number); end - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#46 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#47 def country_code(code); end - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#42 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#43 def delimiter; end - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#50 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#51 def phone_ext(ext); end - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#54 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#55 def regexp_pattern(default_pattern); end # @return [Boolean] # - # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#38 + # source://activesupport//lib/active_support/number_helper/number_to_phone_converter.rb#39 def start_with_delimiter?(number); end end @@ -9175,10 +10981,10 @@ class ActiveSupport::NumberHelper::NumberToRoundedConverter < ::ActiveSupport::N def strip_insignificant_zeros; end class << self - # source://activesupport//lib/active_support/number_helper/number_converter.rb#13 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#14 def namespace; end - # source://activesupport//lib/active_support/number_helper/number_converter.rb#16 + # source://activesupport//lib/active_support/number_helper/number_converter.rb#17 def validate_float; end end end @@ -9212,6 +11018,8 @@ end # source://activesupport//lib/active_support/core_ext/numeric/conversions.rb#7 module ActiveSupport::NumericWithFormat + # \Numeric With Format + # # Provides options for converting numbers into formatted strings. # Options are provided for phone numbers, currency, percentage, # precision, positional notation, file size, and pretty printing. @@ -9316,9 +11124,11 @@ module ActiveSupport::NumericWithFormat # separator: ',', # significant: false) # => "1,2 Million" # - # source://activesupport//lib/active_support/core_ext/numeric/conversions.rb#111 + # source://activesupport//lib/active_support/core_ext/numeric/conversions.rb#113 def to_formatted_s(format = T.unsafe(nil), options = T.unsafe(nil)); end + # \Numeric With Format + # # Provides options for converting numbers into formatted strings. # Options are provided for phone numbers, currency, percentage, # precision, positional notation, file size, and pretty printing. @@ -9423,7 +11233,7 @@ module ActiveSupport::NumericWithFormat # separator: ',', # significant: false) # => "1,2 Million" # - # source://activesupport//lib/active_support/core_ext/numeric/conversions.rb#111 + # source://activesupport//lib/active_support/core_ext/numeric/conversions.rb#113 def to_fs(format = T.unsafe(nil), options = T.unsafe(nil)); end end @@ -9442,10 +11252,10 @@ class ActiveSupport::OptionMerger # @return [Boolean] # # source://activesupport//lib/active_support/option_merger.rb#34 - def respond_to_missing?(*arguments); end + def respond_to_missing?(*_arg0, **_arg1, &_arg2); end end -# DEPRECATED: ActiveSupport::OrderedHash implements a hash that preserves +# DEPRECATED: +ActiveSupport::OrderedHash+ implements a hash that preserves # insertion order. # # oh = ActiveSupport::OrderedHash.new @@ -9455,9 +11265,9 @@ end # # Also, maps the +omap+ feature for YAML files # (See https://yaml.org/type/omap.html) to support ordered items -# when loading from yaml. +# when loading from YAML. # -# ActiveSupport::OrderedHash is namespaced to prevent conflicts +# +ActiveSupport::OrderedHash+ is namespaced to prevent conflicts # with other implementations. # # source://activesupport//lib/active_support/ordered_hash.rb#24 @@ -9485,6 +11295,8 @@ class ActiveSupport::OrderedHash < ::Hash def to_yaml_type; end end +# = Ordered Options +# # +OrderedOptions+ inherits from +Hash+ and provides dynamic accessor methods. # # With a +Hash+, key-value pairs are typically managed like this: @@ -9510,24 +11322,27 @@ end # # h.dog! # => raises KeyError: :dog is blank # -# source://activesupport//lib/active_support/ordered_options.rb#31 +# source://activesupport//lib/active_support/ordered_options.rb#33 class ActiveSupport::OrderedOptions < ::Hash - # source://activesupport//lib/active_support/ordered_options.rb#39 + # source://activesupport//lib/active_support/ordered_options.rb#41 def [](key); end - # source://activesupport//lib/active_support/ordered_options.rb#35 + # source://activesupport//lib/active_support/ordered_options.rb#37 def []=(key, value); end + # source://activesupport//lib/active_support/ordered_options.rb#45 + def dig(key, *identifiers); end + # @return [Boolean] # - # source://activesupport//lib/active_support/ordered_options.rb#62 + # source://activesupport//lib/active_support/ordered_options.rb#64 def extractable_options?; end - # source://activesupport//lib/active_support/ordered_options.rb#66 + # source://activesupport//lib/active_support/ordered_options.rb#68 def inspect; end - # source://activesupport//lib/active_support/ordered_options.rb#43 - def method_missing(name, *args); end + # source://activesupport//lib/active_support/ordered_options.rb#49 + def method_missing(method, *args); end protected @@ -9538,10 +11353,12 @@ class ActiveSupport::OrderedOptions < ::Hash # @return [Boolean] # - # source://activesupport//lib/active_support/ordered_options.rb#58 + # source://activesupport//lib/active_support/ordered_options.rb#60 def respond_to_missing?(name, include_private); end end +# = Active Support Parameter Filter +# # +ParameterFilter+ replaces values in a Hash-like object if their # keys match one of the specified filters. # @@ -9569,146 +11386,88 @@ end # # # Reverses values for keys that match /secret/i. # ActiveSupport::ParameterFilter.new([-> (k, v) do -# v.reverse! if /secret/i.match?(k) -# end]) -# -# source://activesupport//lib/active_support/parameter_filter.rb#36 -class ActiveSupport::ParameterFilter - # Create instance with given filters. Supported type of filters are +String+, +Regexp+, and +Proc+. - # Other types of filters are treated as +String+ using +to_s+. - # For +Proc+ filters, key, value, and optional original hash is passed to block arguments. - # - # ==== Options - # - # * :mask - A replaced object when filtered. Defaults to "[FILTERED]". - # - # @return [ParameterFilter] a new instance of ParameterFilter - # - # source://activesupport//lib/active_support/parameter_filter.rb#46 - def initialize(filters = T.unsafe(nil), mask: T.unsafe(nil)); end - - # Mask value of +params+ if key matches one of filters. - # - # source://activesupport//lib/active_support/parameter_filter.rb#52 - def filter(params); end - - # Returns filtered value for given key. For +Proc+ filters, third block argument is not populated. - # - # source://activesupport//lib/active_support/parameter_filter.rb#57 - def filter_param(key, value); end - - private - - # source://activesupport//lib/active_support/parameter_filter.rb#62 - def compiled_filter; end -end - -# source://activesupport//lib/active_support/parameter_filter.rb#66 -class ActiveSupport::ParameterFilter::CompiledFilter - # @return [CompiledFilter] a new instance of CompiledFilter - # - # source://activesupport//lib/active_support/parameter_filter.rb#100 - def initialize(regexps, deep_regexps, blocks, mask:); end - - # Returns the value of attribute blocks. - # - # source://activesupport//lib/active_support/parameter_filter.rb#98 - def blocks; end - - # source://activesupport//lib/active_support/parameter_filter.rb#107 - def call(params, parents = T.unsafe(nil), original_params = T.unsafe(nil)); end - - # Returns the value of attribute deep_regexps. - # - # source://activesupport//lib/active_support/parameter_filter.rb#98 - def deep_regexps; end - - # Returns the value of attribute regexps. - # - # source://activesupport//lib/active_support/parameter_filter.rb#98 - def regexps; end - - # source://activesupport//lib/active_support/parameter_filter.rb#117 - def value_for_key(key, value, parents = T.unsafe(nil), original_params = T.unsafe(nil)); end - - class << self - # source://activesupport//lib/active_support/parameter_filter.rb#67 - def compile(filters, mask:); end - end -end - -# source://activesupport//lib/active_support/parameter_filter.rb#37 -ActiveSupport::ParameterFilter::FILTERED = T.let(T.unsafe(nil), String) - -# NOTE: This approach has been deprecated for end-user code in favor of {thread_mattr_accessor}[rdoc-ref:Module#thread_mattr_accessor] and friends. -# Please use that approach instead. -# -# This module is used to encapsulate access to thread local variables. -# -# Instead of polluting the thread locals namespace: -# -# Thread.current[:connection_handler] -# -# you define a class that extends this module: -# -# module ActiveRecord -# class RuntimeRegistry -# extend ActiveSupport::PerThreadRegistry -# -# attr_accessor :connection_handler -# end -# end -# -# and invoke the declared instance accessors as class methods. So -# -# ActiveRecord::RuntimeRegistry.connection_handler = connection_handler -# -# sets a connection handler local to the current thread, and -# -# ActiveRecord::RuntimeRegistry.connection_handler -# -# returns a connection handler local to the current thread. -# -# This feature is accomplished by instantiating the class and storing the -# instance as a thread local keyed by the class name. In the example above -# a key "ActiveRecord::RuntimeRegistry" is stored in Thread.current. -# The class methods proxy to said thread local instance. -# -# If the class has an initializer, it must accept no arguments. +# v.reverse! if /secret/i.match?(k) +# end]) # -# source://activesupport//lib/active_support/per_thread_registry.rb#41 -module ActiveSupport::PerThreadRegistry - # source://activesupport//lib/active_support/per_thread_registry.rb#50 - def instance; end +# source://activesupport//lib/active_support/parameter_filter.rb#39 +class ActiveSupport::ParameterFilter + # Create instance with given filters. Supported type of filters are +String+, +Regexp+, and +Proc+. + # Other types of filters are treated as +String+ using +to_s+. + # For +Proc+ filters, key, value, and optional original hash is passed to block arguments. + # + # ==== Options + # + # * :mask - A replaced object when filtered. Defaults to "[FILTERED]". + # + # @return [ParameterFilter] a new instance of ParameterFilter + # + # source://activesupport//lib/active_support/parameter_filter.rb#77 + def initialize(filters = T.unsafe(nil), mask: T.unsafe(nil)); end + + # Mask value of +params+ if key matches one of filters. + # + # source://activesupport//lib/active_support/parameter_filter.rb#83 + def filter(params); end + + # Returns filtered value for given key. For +Proc+ filters, third block argument is not populated. + # + # source://activesupport//lib/active_support/parameter_filter.rb#88 + def filter_param(key, value); end private - # source://activesupport//lib/active_support/per_thread_registry.rb#55 - def method_missing(name, *args, **_arg2, &block); end + # source://activesupport//lib/active_support/parameter_filter.rb#125 + def call(params, full_parent_key = T.unsafe(nil), original_params = T.unsafe(nil)); end + + # source://activesupport//lib/active_support/parameter_filter.rb#93 + def compile_filters!(filters); end + + # source://activesupport//lib/active_support/parameter_filter.rb#135 + def value_for_key(key, value, full_parent_key = T.unsafe(nil), original_params = T.unsafe(nil)); end class << self - # @private + # Precompiles an array of filters that otherwise would be passed directly to + # #initialize. Depending on the quantity and types of filters, + # precompilation can improve filtering performance, especially in the case + # where the ParameterFilter instance itself cannot be retained (but the + # precompiled filters can be retained). + # + # filters = [/foo/, :bar, "nested.baz", /nested\.qux/] + # + # precompiled = ActiveSupport::ParameterFilter.precompile_filters(filters) + # # => [/(?-mix:foo)|(?i:bar)/, /(?i:nested\.baz)|(?-mix:nested\.qux)/] + # + # ActiveSupport::ParameterFilter.new(precompiled) # - # source://activesupport//lib/active_support/per_thread_registry.rb#42 - def extended(object); end + # source://activesupport//lib/active_support/parameter_filter.rb#55 + def precompile_filters(filters); end end end -# A class with no predefined methods that behaves similarly to Builder's -# BlankSlate. Used for proxy classes. -# -# source://activesupport//lib/active_support/proxy_object.rb#6 +# source://activesupport//lib/active_support/parameter_filter.rb#40 +ActiveSupport::ParameterFilter::FILTERED = T.let(T.unsafe(nil), String) + +# source://activesupport//lib/active_support/proxy_object.rb#4 class ActiveSupport::ProxyObject < ::BasicObject # Let ActiveSupport::ProxyObject at least raise exceptions. # - # source://activesupport//lib/active_support/proxy_object.rb#11 + # source://activesupport//lib/active_support/proxy_object.rb#9 def raise(*args); end + + class << self + # @private + # + # source://activesupport//lib/active_support/proxy_object.rb#13 + def inherited(_subclass); end + end end # source://activesupport//lib/active_support/railtie.rb#7 class ActiveSupport::Railtie < ::Rails::Railtie; end -# source://activesupport//lib/active_support/core_ext/range/conversions.rb#4 +# = \Range With Format +# +# source://activesupport//lib/active_support/core_ext/range/conversions.rb#5 module ActiveSupport::RangeWithFormat # Convert range to a formatted string. See RANGE_FORMATS for predefined formats. # @@ -9717,16 +11476,22 @@ module ActiveSupport::RangeWithFormat # range = (1..100) # => 1..100 # # range.to_s # => "1..100" - # range.to_fs(:db) # => "BETWEEN '1' AND '100'" + # range.to_fs(:db) # => "BETWEEN '1' AND '100'" + # + # range = (1..) # => 1.. + # range.to_fs(:db) # => ">= '1'" + # + # range = (..100) # => ..100 + # range.to_fs(:db) # => "<= '100'" # - # == Adding your own range formats to to_s + # == Adding your own range formats to to_fs # You can add your own formats to the Range::RANGE_FORMATS hash. # Use the format name as the hash key and a Proc instance. # # # config/initializers/range_formats.rb # Range::RANGE_FORMATS[:short] = ->(start, stop) { "Between #{start.to_fs(:db)} and #{stop.to_fs(:db)}" } # - # source://activesupport//lib/active_support/core_ext/range/conversions.rb#30 + # source://activesupport//lib/active_support/core_ext/range/conversions.rb#51 def to_formatted_s(format = T.unsafe(nil)); end # Convert range to a formatted string. See RANGE_FORMATS for predefined formats. @@ -9736,23 +11501,30 @@ module ActiveSupport::RangeWithFormat # range = (1..100) # => 1..100 # # range.to_s # => "1..100" - # range.to_fs(:db) # => "BETWEEN '1' AND '100'" + # range.to_fs(:db) # => "BETWEEN '1' AND '100'" # - # == Adding your own range formats to to_s + # range = (1..) # => 1.. + # range.to_fs(:db) # => ">= '1'" + # + # range = (..100) # => ..100 + # range.to_fs(:db) # => "<= '100'" + # + # == Adding your own range formats to to_fs # You can add your own formats to the Range::RANGE_FORMATS hash. # Use the format name as the hash key and a Proc instance. # # # config/initializers/range_formats.rb # Range::RANGE_FORMATS[:short] = ->(start, stop) { "Between #{start.to_fs(:db)} and #{stop.to_fs(:db)}" } # - # source://activesupport//lib/active_support/core_ext/range/conversions.rb#30 + # source://activesupport//lib/active_support/core_ext/range/conversions.rb#51 def to_fs(format = T.unsafe(nil)); end end -# source://activesupport//lib/active_support/core_ext/range/conversions.rb#5 +# source://activesupport//lib/active_support/core_ext/range/conversions.rb#6 ActiveSupport::RangeWithFormat::RANGE_FORMATS = T.let(T.unsafe(nil), Hash) -# -- +# = Active Support \Reloader +# # This class defines several callbacks: # # to_prepare -- Run once at application startup, and also from @@ -9772,139 +11544,141 @@ ActiveSupport::RangeWithFormat::RANGE_FORMATS = T.let(T.unsafe(nil), Hash) # after_class_unload -- Run immediately after the classes are # unloaded. # -# source://activesupport//lib/active_support/reloader.rb#27 +# source://activesupport//lib/active_support/reloader.rb#28 class ActiveSupport::Reloader < ::ActiveSupport::ExecutionWrapper # @return [Reloader] a new instance of Reloader # - # source://activesupport//lib/active_support/reloader.rb#91 + # source://activesupport//lib/active_support/reloader.rb#99 def initialize; end - # source://activesupport//lib/active_support/callbacks.rb#940 + # source://activesupport//lib/active_support/callbacks.rb#924 def _class_unload_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#940 + # source://activesupport//lib/active_support/callbacks.rb#924 def _prepare_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#928 + # source://activesupport//lib/active_support/callbacks.rb#912 def _run_class_unload_callbacks(&block); end - # source://activesupport//lib/active_support/callbacks.rb#928 + # source://activesupport//lib/active_support/callbacks.rb#912 def _run_prepare_callbacks(&block); end - # source://activesupport//lib/active_support/reloader.rb#77 + # source://activesupport//lib/active_support/reloader.rb#85 def check; end - # source://activesupport//lib/active_support/reloader.rb#77 + # source://activesupport//lib/active_support/reloader.rb#85 def check=(_arg0); end - # source://activesupport//lib/active_support/reloader.rb#77 + # source://activesupport//lib/active_support/reloader.rb#85 def check?; end - # source://activesupport//lib/active_support/reloader.rb#118 + # source://activesupport//lib/active_support/reloader.rb#126 def class_unload!(&block); end - # source://activesupport//lib/active_support/reloader.rb#123 + # source://activesupport//lib/active_support/reloader.rb#131 def complete!; end - # source://activesupport//lib/active_support/reloader.rb#76 + # source://activesupport//lib/active_support/reloader.rb#84 def executor; end - # source://activesupport//lib/active_support/reloader.rb#76 + # source://activesupport//lib/active_support/reloader.rb#84 def executor=(_arg0); end - # source://activesupport//lib/active_support/reloader.rb#76 + # source://activesupport//lib/active_support/reloader.rb#84 def executor?; end # Release the unload lock if it has been previously obtained # - # source://activesupport//lib/active_support/reloader.rb#106 + # source://activesupport//lib/active_support/reloader.rb#114 def release_unload_lock!; end # Acquire the ActiveSupport::Dependencies::Interlock unload lock, # ensuring it will be released automatically # - # source://activesupport//lib/active_support/reloader.rb#98 + # source://activesupport//lib/active_support/reloader.rb#106 def require_unload_lock!; end - # source://activesupport//lib/active_support/reloader.rb#113 + # source://activesupport//lib/active_support/reloader.rb#121 def run!; end class << self - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#932 + # source://activesupport//lib/active_support/callbacks.rb#916 def _class_unload_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#936 + # source://activesupport//lib/active_support/callbacks.rb#920 def _class_unload_callbacks=(value); end - # source://activesupport//lib/active_support/callbacks.rb#932 + # source://activesupport//lib/active_support/callbacks.rb#916 def _prepare_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#936 + # source://activesupport//lib/active_support/callbacks.rb#920 def _prepare_callbacks=(value); end # Registers a callback that will run immediately after the classes are unloaded. # - # source://activesupport//lib/active_support/reloader.rb#43 + # source://activesupport//lib/active_support/reloader.rb#44 def after_class_unload(*args, &block); end # Registers a callback that will run immediately before the classes are unloaded. # - # source://activesupport//lib/active_support/reloader.rb#38 + # source://activesupport//lib/active_support/reloader.rb#39 def before_class_unload(*args, &block); end - # source://activesupport//lib/active_support/reloader.rb#77 + # source://activesupport//lib/active_support/reloader.rb#85 def check; end - # source://activesupport//lib/active_support/reloader.rb#79 + # source://activesupport//lib/active_support/reloader.rb#87 def check!; end - # source://activesupport//lib/active_support/reloader.rb#77 + # source://activesupport//lib/active_support/reloader.rb#85 def check=(value); end - # source://activesupport//lib/active_support/reloader.rb#77 + # source://activesupport//lib/active_support/reloader.rb#85 def check?; end - # source://activesupport//lib/active_support/reloader.rb#76 + # source://activesupport//lib/active_support/reloader.rb#84 def executor; end - # source://activesupport//lib/active_support/reloader.rb#76 + # source://activesupport//lib/active_support/reloader.rb#84 def executor=(value); end - # source://activesupport//lib/active_support/reloader.rb#76 + # source://activesupport//lib/active_support/reloader.rb#84 def executor?; end - # source://activesupport//lib/active_support/reloader.rb#87 + # source://activesupport//lib/active_support/reloader.rb#95 def prepare!; end # Initiate a manual reload # - # source://activesupport//lib/active_support/reloader.rb#50 + # source://activesupport//lib/active_support/reloader.rb#51 def reload!; end - # source://activesupport//lib/active_support/reloader.rb#83 + # source://activesupport//lib/active_support/reloader.rb#91 def reloaded!; end - # source://activesupport//lib/active_support/reloader.rb#61 + # source://activesupport//lib/active_support/reloader.rb#62 def run!(reset: T.unsafe(nil)); end # Registers a callback that will run once at application startup and every time the code is reloaded. # - # source://activesupport//lib/active_support/reloader.rb#33 + # source://activesupport//lib/active_support/reloader.rb#34 def to_prepare(*args, &block); end # Run the supplied block as a work unit, reloading code as needed # - # source://activesupport//lib/active_support/reloader.rb#70 - def wrap; end + # source://activesupport//lib/active_support/reloader.rb#71 + def wrap(**kwargs); end end end +# = Active Support \Rescuable +# # Rescuable module adds support for easier exception handling. # -# source://activesupport//lib/active_support/rescuable.rb#9 +# source://activesupport//lib/active_support/rescuable.rb#11 module ActiveSupport::Rescuable extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -9915,13 +11689,13 @@ module ActiveSupport::Rescuable # Internal handler lookup. Delegates to class method. Some libraries call # this directly, so keeping it around for compatibility. # - # source://activesupport//lib/active_support/rescuable.rb#170 + # source://activesupport//lib/active_support/rescuable.rb#172 def handler_for_rescue(exception); end # Delegates to the class method, but uses the instance as the subject for # rescue_from handlers (method calls, +instance_exec+ blocks). # - # source://activesupport//lib/active_support/rescuable.rb#164 + # source://activesupport//lib/active_support/rescuable.rb#166 def rescue_with_handler(exception); end module GeneratedClassMethods @@ -9937,9 +11711,9 @@ module ActiveSupport::Rescuable end end -# source://activesupport//lib/active_support/rescuable.rb#16 +# source://activesupport//lib/active_support/rescuable.rb#18 module ActiveSupport::Rescuable::ClassMethods - # source://activesupport//lib/active_support/rescuable.rb#103 + # source://activesupport//lib/active_support/rescuable.rb#105 def handler_for_rescue(exception, object: T.unsafe(nil)); end # Registers exception classes with a handler to be called by rescue_with_handler. @@ -9977,7 +11751,7 @@ module ActiveSupport::Rescuable::ClassMethods # # Exceptions raised inside exception handlers are not propagated up. # - # source://activesupport//lib/active_support/rescuable.rb#51 + # source://activesupport//lib/active_support/rescuable.rb#53 def rescue_from(*klasses, with: T.unsafe(nil), &block); end # Matches an exception to a handler based on the exception class. @@ -9995,259 +11769,256 @@ module ActiveSupport::Rescuable::ClassMethods # # Returns the exception if it was handled and +nil+ if it was not. # - # source://activesupport//lib/active_support/rescuable.rb#88 + # source://activesupport//lib/active_support/rescuable.rb#90 def rescue_with_handler(exception, object: T.unsafe(nil), visited_exceptions: T.unsafe(nil)); end private - # source://activesupport//lib/active_support/rescuable.rb#137 + # source://activesupport//lib/active_support/rescuable.rb#139 def constantize_rescue_handler_class(class_or_name); end - # source://activesupport//lib/active_support/rescuable.rb#122 + # source://activesupport//lib/active_support/rescuable.rb#124 def find_rescue_handler(exception); end end -# source://activesupport//lib/active_support/ruby_features.rb#4 -module ActiveSupport::RubyFeatures; end - -# RUBY_VERSION >= "3.1" -# -# source://activesupport//lib/active_support/ruby_features.rb#5 -ActiveSupport::RubyFeatures::CLASS_SUBCLASSES = T.let(T.unsafe(nil), TrueClass) - -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#162 +# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#19 class ActiveSupport::SafeBuffer < ::String # @return [SafeBuffer] a new instance of SafeBuffer # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#200 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#70 def initialize(str = T.unsafe(nil)); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#257 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#123 def %(args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#250 - def *(*_arg0); end + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#116 + def *(_); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#246 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#112 def +(other); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#214 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#80 def <<(value); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#181 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#38 def [](*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#238 - def []=(*args); end + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#104 + def []=(arg1, arg2, arg3 = T.unsafe(nil)); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#222 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#88 def bytesplice(*args, value); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def capitalize(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def capitalize!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def chomp(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def chomp!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def chop(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def chop!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#210 - def clone_empty; end + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#59 + def chr; end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#214 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#80 def concat(value); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def delete(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def delete!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def delete_prefix(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def delete_prefix!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def delete_suffix(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def delete_suffix!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def downcase(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def downcase!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#280 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#146 def encode_with(coder); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#301 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#167 def gsub(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#312 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#178 def gsub!(*args, &block); end - # @return [Boolean] + # Returns the value of attribute html_safe. # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#268 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#134 def html_safe?; end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#226 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#92 def insert(index, value); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def lstrip(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def lstrip!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def next(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def next!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#230 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#96 def prepend(value); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#234 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#100 def replace(value); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def reverse(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def reverse!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def rstrip(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def rstrip!(*args); end # @raise [SafeConcatError] # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#195 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#65 def safe_concat(value); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def scrub(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def scrub!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 - def slice(*args, &block); end + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#38 + def slice(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#51 def slice!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def squeeze(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def squeeze!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def strip(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def strip!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#301 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#167 def sub(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#312 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#178 def sub!(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def succ(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def succ!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def swapcase(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def swapcase!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#276 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#142 def to_param; end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#272 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#138 def to_s; end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def tr(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def tr!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def tr_s(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def tr_s!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def unicode_normalize(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def unicode_normalize!(*args); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#287 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#153 def upcase(*args, &block); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#291 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#157 def upcase!(*args); end private - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#327 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#193 def explicit_html_escape_interpolated_argument(arg); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#331 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#197 def implicit_html_escape_interpolated_argument(arg); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#205 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#75 def initialize_copy(other); end def original_concat(*_arg0); end - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#354 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#205 def set_block_back_references(block, match_data); end + + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#211 + def string_into_safe_buffer(new_string, is_html_safe); end end # Raised when ActiveSupport::SafeBuffer#safe_concat is called on unsafe buffers. # -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#175 +# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#32 class ActiveSupport::SafeBuffer::SafeConcatError < ::StandardError # @return [SafeConcatError] a new instance of SafeConcatError # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#176 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#33 def initialize; end end -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#163 +# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#20 ActiveSupport::SafeBuffer::UNSAFE_STRING_METHODS = T.let(T.unsafe(nil), Array) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#169 +# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#26 ActiveSupport::SafeBuffer::UNSAFE_STRING_METHODS_WITH_BACKREF = T.let(T.unsafe(nil), Array) +# = Secure Compare Rotator +# # The ActiveSupport::SecureCompareRotator is a wrapper around ActiveSupport::SecurityUtils.secure_compare # and allows you to rotate a previously defined value to a new one. # @@ -10272,26 +12043,23 @@ ActiveSupport::SafeBuffer::UNSAFE_STRING_METHODS_WITH_BACKREF = T.let(T.unsafe(n # end # end # -# source://activesupport//lib/active_support/secure_compare_rotator.rb#30 +# source://activesupport//lib/active_support/secure_compare_rotator.rb#32 class ActiveSupport::SecureCompareRotator - include ::ActiveSupport::Messages::Rotator include ::ActiveSupport::SecurityUtils # @return [SecureCompareRotator] a new instance of SecureCompareRotator # - # source://activesupport//lib/active_support/messages/rotator.rb#6 - def initialize(*secrets, on_rotation: T.unsafe(nil), **options); end - - # source://activesupport//lib/active_support/secure_compare_rotator.rb#40 - def secure_compare!(other_value, on_rotation: T.unsafe(nil)); end + # source://activesupport//lib/active_support/secure_compare_rotator.rb#37 + def initialize(value, on_rotation: T.unsafe(nil)); end - private + # source://activesupport//lib/active_support/secure_compare_rotator.rb#43 + def rotate(previous_value); end # source://activesupport//lib/active_support/secure_compare_rotator.rb#47 - def build_rotation(previous_value, _options); end + def secure_compare!(other_value, on_rotation: T.unsafe(nil)); end end -# source://activesupport//lib/active_support/secure_compare_rotator.rb#34 +# source://activesupport//lib/active_support/secure_compare_rotator.rb#35 class ActiveSupport::SecureCompareRotator::InvalidMatch < ::StandardError; end # source://activesupport//lib/active_support/security_utils.rb#4 @@ -10331,6 +12099,8 @@ module ActiveSupport::SecurityUtils end end +# = \String Inquirer +# # Wrapping a string in this class gives you a prettier way to test # for equality. The value returned by Rails.env is wrapped # in a StringInquirer object, so instead of calling this: @@ -10341,26 +12111,28 @@ end # # Rails.env.production? # -# == Instantiating a new StringInquirer +# == Instantiating a new \StringInquirer # # vehicle = ActiveSupport::StringInquirer.new('car') # vehicle.car? # => true # vehicle.bike? # => false # -# source://activesupport//lib/active_support/string_inquirer.rb#19 +# source://activesupport//lib/active_support/string_inquirer.rb#21 class ActiveSupport::StringInquirer < ::String private - # source://activesupport//lib/active_support/string_inquirer.rb#25 - def method_missing(method_name, *arguments); end + # source://activesupport//lib/active_support/string_inquirer.rb#27 + def method_missing(method_name, *_arg1, **_arg2, &_arg3); end # @return [Boolean] # - # source://activesupport//lib/active_support/string_inquirer.rb#21 + # source://activesupport//lib/active_support/string_inquirer.rb#23 def respond_to_missing?(method_name, include_private = T.unsafe(nil)); end end -# ActiveSupport::Subscriber is an object set to consume +# = Active Support \Subscriber +# +# +ActiveSupport::Subscriber+ is an object set to consume # ActiveSupport::Notifications. The subscriber dispatches notifications to # a registered object based on its given namespace. # @@ -10377,109 +12149,142 @@ end # end # end # -# After configured, whenever a "sql.active_record" notification is published, -# it will properly dispatch the event (ActiveSupport::Notifications::Event) to -# the +sql+ method. +# After configured, whenever a "sql.active_record" notification is +# published, it will properly dispatch the event +# (ActiveSupport::Notifications::Event) to the +sql+ method. # # We can detach a subscriber as well: # # ActiveRecord::StatsSubscriber.detach_from(:active_record) # -# source://activesupport//lib/active_support/subscriber.rb#30 +# source://activesupport//lib/active_support/subscriber.rb#32 class ActiveSupport::Subscriber # @return [Subscriber] a new instance of Subscriber # - # source://activesupport//lib/active_support/subscriber.rb#128 + # source://activesupport//lib/active_support/subscriber.rb#130 def initialize; end - # source://activesupport//lib/active_support/subscriber.rb#143 - def finish(name, id, payload); end + # source://activesupport//lib/active_support/subscriber.rb#135 + def call(event); end - # source://activesupport//lib/active_support/subscriber.rb#126 + # source://activesupport//lib/active_support/subscriber.rb#128 def patterns; end - # source://activesupport//lib/active_support/subscriber.rb#152 + # source://activesupport//lib/active_support/subscriber.rb#140 def publish_event(event); end - # source://activesupport//lib/active_support/subscriber.rb#134 - def start(name, id, payload); end - - private - - # source://activesupport//lib/active_support/subscriber.rb#158 - def event_stack; end - class << self # Attach the subscriber to a namespace. # - # source://activesupport//lib/active_support/subscriber.rb#33 + # source://activesupport//lib/active_support/subscriber.rb#35 def attach_to(namespace, subscriber = T.unsafe(nil), notifier = T.unsafe(nil), inherit_all: T.unsafe(nil)); end # Detach the subscriber from a namespace. # - # source://activesupport//lib/active_support/subscriber.rb#48 + # source://activesupport//lib/active_support/subscriber.rb#50 def detach_from(namespace, notifier = T.unsafe(nil)); end # Adds event subscribers for all new methods added to the class. # - # source://activesupport//lib/active_support/subscriber.rb#67 + # source://activesupport//lib/active_support/subscriber.rb#69 def method_added(event); end - # source://activesupport//lib/active_support/subscriber.rb#76 + # source://activesupport//lib/active_support/subscriber.rb#78 def subscribers; end private - # source://activesupport//lib/active_support/subscriber.rb#83 + # source://activesupport//lib/active_support/subscriber.rb#85 def add_event_subscriber(event); end - # source://activesupport//lib/active_support/subscriber.rb#121 + # source://activesupport//lib/active_support/subscriber.rb#123 def fetch_public_methods(subscriber, inherit_all); end - # source://activesupport//lib/active_support/subscriber.rb#105 + # source://activesupport//lib/active_support/subscriber.rb#107 def find_attached_subscriber; end # @return [Boolean] # - # source://activesupport//lib/active_support/subscriber.rb#109 + # source://activesupport//lib/active_support/subscriber.rb#111 def invalid_event?(event); end # Returns the value of attribute namespace. # - # source://activesupport//lib/active_support/subscriber.rb#81 + # source://activesupport//lib/active_support/subscriber.rb#83 def namespace; end # Returns the value of attribute notifier. # - # source://activesupport//lib/active_support/subscriber.rb#81 + # source://activesupport//lib/active_support/subscriber.rb#83 def notifier; end # @return [Boolean] # - # source://activesupport//lib/active_support/subscriber.rb#117 + # source://activesupport//lib/active_support/subscriber.rb#119 def pattern_subscribed?(pattern); end - # source://activesupport//lib/active_support/subscriber.rb#113 + # source://activesupport//lib/active_support/subscriber.rb#115 def prepare_pattern(event); end - # source://activesupport//lib/active_support/subscriber.rb#94 + # source://activesupport//lib/active_support/subscriber.rb#96 def remove_event_subscriber(event); end # Returns the value of attribute subscriber. # - # source://activesupport//lib/active_support/subscriber.rb#81 + # source://activesupport//lib/active_support/subscriber.rb#83 def subscriber; end end end +# This is a class for wrapping syntax errors. The purpose of this class +# is to enhance the backtraces on SyntaxError exceptions to include the +# source location of the syntax error. That way we can display the error +# source on error pages in development. +# +# source://activesupport//lib/active_support/syntax_error_proxy.rb#10 +class ActiveSupport::SyntaxErrorProxy + # source://activesupport//lib/active_support/syntax_error_proxy.rb#11 + def backtrace; end + + # source://activesupport//lib/active_support/syntax_error_proxy.rb#34 + def backtrace_locations; end + + private + + # source://activesupport//lib/active_support/syntax_error_proxy.rb#47 + def parse_message_for_trace; end +end + +# source://activesupport//lib/active_support/syntax_error_proxy.rb#15 +class ActiveSupport::SyntaxErrorProxy::BacktraceLocation < ::Struct + # source://activesupport//lib/active_support/syntax_error_proxy.rb#19 + def label; end + + # source://activesupport//lib/active_support/syntax_error_proxy.rb#16 + def spot(_); end +end + +# source://activesupport//lib/active_support/syntax_error_proxy.rb#23 +class ActiveSupport::SyntaxErrorProxy::BacktraceLocationProxy + # @return [BacktraceLocationProxy] a new instance of BacktraceLocationProxy + # + # source://activesupport//lib/active_support/syntax_error_proxy.rb#24 + def initialize(loc, ex); end + + # source://activesupport//lib/active_support/syntax_error_proxy.rb#29 + def spot(_); end +end + +# = Active Support Tagged Logging +# # Wraps any standard Logger object to provide tagging capabilities. # # May be called with a block: # # logger = ActiveSupport::TaggedLogging.new(Logger.new(STDOUT)) -# logger.tagged('BCX') { logger.info 'Stuff' } # Logs "[BCX] Stuff" -# logger.tagged('BCX', "Jason") { logger.info 'Stuff' } # Logs "[BCX] [Jason] Stuff" -# logger.tagged('BCX') { logger.tagged('Jason') { logger.info 'Stuff' } } # Logs "[BCX] [Jason] Stuff" +# logger.tagged('BCX') { logger.info 'Stuff' } # Logs "[BCX] Stuff" +# logger.tagged('BCX', "Jason") { |tagged_logger| tagged_logger.info 'Stuff' } # Logs "[BCX] [Jason] Stuff" +# logger.tagged('BCX') { logger.tagged('Jason') { logger.info 'Stuff' } } # Logs "[BCX] [Jason] Stuff" # # If called without a block, a new logger will be returned with applied tags: # @@ -10492,152 +12297,185 @@ end # it easy to stamp log lines with subdomains, request ids, and anything else # to aid debugging of multi-user production applications. # -# source://activesupport//lib/active_support/tagged_logging.rb#28 +# source://activesupport//lib/active_support/tagged_logging.rb#29 module ActiveSupport::TaggedLogging - # source://activesupport//lib/active_support/tagged_logging.rb#95 + # source://activesupport//lib/active_support/tagged_logging.rb#134 def clear_tags!(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/tagged_logging.rb#108 + # source://activesupport//lib/active_support/tagged_logging.rb#147 def flush; end - # source://activesupport//lib/active_support/tagged_logging.rb#95 + # source://activesupport//lib/active_support/tagged_logging.rb#134 def pop_tags(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/tagged_logging.rb#95 + # source://activesupport//lib/active_support/tagged_logging.rb#134 def push_tags(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/tagged_logging.rb#97 + # source://activesupport//lib/active_support/tagged_logging.rb#136 def tagged(*tags); end class << self - # source://activesupport//lib/active_support/tagged_logging.rb#81 + # source://activesupport//lib/active_support/tagged_logging.rb#116 def new(logger); end end end -# source://activesupport//lib/active_support/tagged_logging.rb#29 +# source://activesupport//lib/active_support/tagged_logging.rb#30 module ActiveSupport::TaggedLogging::Formatter # This method is invoked when a log event occurs. # - # source://activesupport//lib/active_support/tagged_logging.rb#31 + # source://activesupport//lib/active_support/tagged_logging.rb#32 def call(severity, timestamp, progname, msg); end - # source://activesupport//lib/active_support/tagged_logging.rb#53 + # source://activesupport//lib/active_support/tagged_logging.rb#51 def clear_tags!; end - # source://activesupport//lib/active_support/tagged_logging.rb#57 + # source://activesupport//lib/active_support/tagged_logging.rb#61 def current_tags; end - # source://activesupport//lib/active_support/tagged_logging.rb#49 - def pop_tags(size = T.unsafe(nil)); end + # source://activesupport//lib/active_support/tagged_logging.rb#47 + def pop_tags(count = T.unsafe(nil)); end - # source://activesupport//lib/active_support/tagged_logging.rb#42 + # source://activesupport//lib/active_support/tagged_logging.rb#43 def push_tags(*tags); end - # source://activesupport//lib/active_support/tagged_logging.rb#35 + # source://activesupport//lib/active_support/tagged_logging.rb#55 + def tag_stack; end + + # source://activesupport//lib/active_support/tagged_logging.rb#36 def tagged(*tags); end - # source://activesupport//lib/active_support/tagged_logging.rb#63 + # source://activesupport//lib/active_support/tagged_logging.rb#65 def tags_text; end end -# source://activesupport//lib/active_support/tagged_logging.rb#73 +# source://activesupport//lib/active_support/tagged_logging.rb#108 module ActiveSupport::TaggedLogging::LocalTagStorage - # Returns the value of attribute current_tags. + # Returns the value of attribute tag_stack. # - # source://activesupport//lib/active_support/tagged_logging.rb#74 - def current_tags; end + # source://activesupport//lib/active_support/tagged_logging.rb#109 + def tag_stack; end - # Sets the attribute current_tags + # Sets the attribute tag_stack # - # @param value the value to set the attribute current_tags to. + # @param value the value to set the attribute tag_stack to. # - # source://activesupport//lib/active_support/tagged_logging.rb#74 - def current_tags=(_arg0); end + # source://activesupport//lib/active_support/tagged_logging.rb#109 + def tag_stack=(_arg0); end class << self # @private # - # source://activesupport//lib/active_support/tagged_logging.rb#76 + # source://activesupport//lib/active_support/tagged_logging.rb#111 def extended(base); end end end -# source://activesupport//lib/active_support/test_case.rb#19 +# source://activesupport//lib/active_support/tagged_logging.rb#70 +class ActiveSupport::TaggedLogging::TagStack + # @return [TagStack] a new instance of TagStack + # + # source://activesupport//lib/active_support/tagged_logging.rb#73 + def initialize; end + + # source://activesupport//lib/active_support/tagged_logging.rb#91 + def clear; end + + # source://activesupport//lib/active_support/tagged_logging.rb#96 + def format_message(message); end + + # source://activesupport//lib/active_support/tagged_logging.rb#86 + def pop_tags(count); end + + # source://activesupport//lib/active_support/tagged_logging.rb#78 + def push_tags(tags); end + + # Returns the value of attribute tags. + # + # source://activesupport//lib/active_support/tagged_logging.rb#71 + def tags; end +end + +# source://activesupport//lib/active_support/test_case.rb#21 class ActiveSupport::TestCase < ::Minitest::Test include ::ActiveSupport::Testing::SetupAndTeardown + include ::ActiveSupport::Testing::TestsWithoutAssertions include ::ActiveSupport::Testing::TaggedLogging include ::ActiveSupport::Callbacks include ::ActiveSupport::Testing::Assertions + include ::ActiveSupport::Testing::ErrorReporterAssertions include ::ActiveSupport::Testing::Deprecation + include ::ActiveSupport::Testing::ConstantStubbing include ::ActiveSupport::Testing::TimeHelpers include ::ActiveSupport::Testing::FileFixtures + include ::Turbo::TestAssertions extend ::ActiveSupport::Callbacks::ClassMethods extend ::ActiveSupport::DescendantsTracker extend ::ActiveSupport::Testing::SetupAndTeardown::ClassMethods extend ::ActiveSupport::Testing::Declarative - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport//lib/active_support/callbacks.rb#928 + # source://activesupport//lib/active_support/callbacks.rb#912 def _run_setup_callbacks(&block); end - # source://activesupport//lib/active_support/callbacks.rb#928 + # source://activesupport//lib/active_support/callbacks.rb#912 def _run_teardown_callbacks(&block); end - # source://activesupport//lib/active_support/callbacks.rb#940 + # source://activesupport//lib/active_support/callbacks.rb#924 def _setup_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#940 + # source://activesupport//lib/active_support/callbacks.rb#924 def _teardown_callbacks; end - # source://minitest/5.18.1/lib/minitest/assertions.rb#735 + # source://minitest/5.25.0/lib/minitest/assertions.rb#731 def assert_no_match(matcher, obj, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#664 + # source://minitest/5.25.0/lib/minitest/assertions.rb#660 def assert_not_empty(obj, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#675 + # source://minitest/5.25.0/lib/minitest/assertions.rb#671 def assert_not_equal(exp, act, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#687 + # source://minitest/5.25.0/lib/minitest/assertions.rb#683 def assert_not_in_delta(exp, act, delta = T.unsafe(nil), msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#699 + # source://minitest/5.25.0/lib/minitest/assertions.rb#695 def assert_not_in_epsilon(a, b, epsilon = T.unsafe(nil), msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#706 + # source://minitest/5.25.0/lib/minitest/assertions.rb#702 def assert_not_includes(collection, obj, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#717 + # source://minitest/5.25.0/lib/minitest/assertions.rb#713 def assert_not_instance_of(cls, obj, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#727 + # source://minitest/5.25.0/lib/minitest/assertions.rb#723 def assert_not_kind_of(cls, obj, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#745 + # source://minitest/5.25.0/lib/minitest/assertions.rb#741 def assert_not_nil(obj, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#780 + # source://minitest/5.25.0/lib/minitest/assertions.rb#776 def assert_not_operator(o1, op, o2 = T.unsafe(nil), msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#803 + # source://minitest/5.25.0/lib/minitest/assertions.rb#799 def assert_not_predicate(o1, op, msg = T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#811 - def assert_not_respond_to(obj, meth, msg = T.unsafe(nil)); end + # source://minitest/5.25.0/lib/minitest/assertions.rb#808 + def assert_not_respond_to(obj, meth, msg = T.unsafe(nil), include_all: T.unsafe(nil)); end - # source://minitest/5.18.1/lib/minitest/assertions.rb#820 + # source://minitest/5.25.0/lib/minitest/assertions.rb#817 def assert_not_same(exp, act, msg = T.unsafe(nil)); end - # test/unit backwards compatibility methods - # - # source://minitest/5.18.1/lib/minitest/assertions.rb#422 - def assert_raise(*exp); end + # source://turbo-rails/2.0.6/lib/turbo/test_assertions.rb#7 + def dom_class(*_arg0, **_arg1, &_arg2); end + + # source://turbo-rails/2.0.6/lib/turbo/test_assertions.rb#7 + def dom_id(*_arg0, **_arg1, &_arg2); end # source://activesupport//lib/active_support/testing/file_fixtures.rb#20 def file_fixture_path; end @@ -10645,32 +12483,32 @@ class ActiveSupport::TestCase < ::Minitest::Test # source://activesupport//lib/active_support/testing/file_fixtures.rb#20 def file_fixture_path?; end - # source://activesupport//lib/active_support/test_case.rb#151 + # source://activesupport//lib/active_support/test_case.rb#300 def inspect; end - # source://minitest/5.18.1/lib/minitest.rb#304 + # source://minitest/5.25.0/lib/minitest.rb#375 def method_name; end class << self - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport//lib/active_support/callbacks.rb#68 + # source://activesupport//lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport//lib/active_support/callbacks.rb#932 + # source://activesupport//lib/active_support/callbacks.rb#916 def _setup_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#936 + # source://activesupport//lib/active_support/callbacks.rb#920 def _setup_callbacks=(value); end - # source://activesupport//lib/active_support/callbacks.rb#932 + # source://activesupport//lib/active_support/callbacks.rb#916 def _teardown_callbacks; end - # source://activesupport//lib/active_support/callbacks.rb#936 + # source://activesupport//lib/active_support/callbacks.rb#920 def _teardown_callbacks=(value); end # source://activesupport//lib/active_support/testing/file_fixtures.rb#20 @@ -10705,7 +12543,7 @@ class ActiveSupport::TestCase < ::Minitest::Test # The default parallelization method is to fork processes. If you'd like to # use threads instead you can pass with: :threads to the +parallelize+ # method. Note the threaded parallelization does not create multiple - # database and will not work with system tests at this time. + # databases and will not work with system tests. # # parallelize(workers: :number_of_processors, with: :threads) # @@ -10716,7 +12554,7 @@ class ActiveSupport::TestCase < ::Minitest::Test # number of tests to run is above the +threshold+ param. The default value is # 50, and it's configurable via +config.active_support.test_parallelization_threshold+. # - # source://activesupport//lib/active_support/test_case.rb#79 + # source://activesupport//lib/active_support/test_case.rb#81 def parallelize(workers: T.unsafe(nil), with: T.unsafe(nil), threshold: T.unsafe(nil)); end # Set up hook for parallel testing. This can be used if you have multiple @@ -10760,7 +12598,7 @@ class ActiveSupport::TestCase < ::Minitest::Test # Possible values are +:random+, +:parallel+, +:alpha+, +:sorted+. # Defaults to +:random+. # - # source://activesupport//lib/active_support/test_case.rb#42 + # source://activesupport//lib/active_support/test_case.rb#44 def test_order; end # Sets the order in which test cases are run. @@ -10773,12 +12611,12 @@ class ActiveSupport::TestCase < ::Minitest::Test # * +:sorted+ (to run tests alphabetically by method name) # * +:alpha+ (equivalent to +:sorted+) # - # source://activesupport//lib/active_support/test_case.rb#32 + # source://activesupport//lib/active_support/test_case.rb#34 def test_order=(new_order); end end end -# source://activesupport//lib/active_support/test_case.rb#20 +# source://activesupport//lib/active_support/test_case.rb#22 ActiveSupport::TestCase::Assertion = Minitest::Assertion # source://activesupport//lib/active_support/testing/tagged_logging.rb#4 @@ -10821,7 +12659,7 @@ module ActiveSupport::Testing::Assertions # post :create, params: { status: { incident: true } } # end # - # source://activesupport//lib/active_support/testing/assertions.rb#175 + # source://activesupport//lib/active_support/testing/assertions.rb#191 def assert_changes(expression, message = T.unsafe(nil), from: T.unsafe(nil), to: T.unsafe(nil), &block); end # Test numeric difference between the return value of an expression as a @@ -10838,7 +12676,7 @@ module ActiveSupport::Testing::Assertions # end # # An arbitrary positive or negative difference can be specified. - # The default is 1. + # The default is +1+. # # assert_difference 'Article.count', -1 do # post :delete, params: { id: ... } @@ -10872,7 +12710,7 @@ module ActiveSupport::Testing::Assertions # post :delete, params: { id: ... } # end # - # source://activesupport//lib/active_support/testing/assertions.rb#86 + # source://activesupport//lib/active_support/testing/assertions.rb#101 def assert_difference(expression, *args, &block); end # Assertion that the result of evaluating an expression is not changed before @@ -10882,7 +12720,7 @@ module ActiveSupport::Testing::Assertions # post :create, params: { status: { ok: true } } # end # - # Provide the optional keyword argument :from to specify the expected + # Provide the optional keyword argument +:from+ to specify the expected # initial value. # # assert_no_changes -> { Status.all_good? }, from: true do @@ -10895,7 +12733,7 @@ module ActiveSupport::Testing::Assertions # post :create, params: { status: { ok: false } } # end # - # source://activesupport//lib/active_support/testing/assertions.rb#222 + # source://activesupport//lib/active_support/testing/assertions.rb#238 def assert_no_changes(expression, message = T.unsafe(nil), from: T.unsafe(nil), &block); end # Assertion that the numeric result of evaluating an expression is not @@ -10923,12 +12761,12 @@ module ActiveSupport::Testing::Assertions # post :create, params: { article: invalid_attributes } # end # - # source://activesupport//lib/active_support/testing/assertions.rb#137 + # source://activesupport//lib/active_support/testing/assertions.rb#153 def assert_no_difference(expression, message = T.unsafe(nil), &block); end - # Asserts that an expression is not truthy. Passes if object is - # +nil+ or +false+. "Truthy" means "considered true in a conditional" - # like if foo. + # Asserts that an expression is not truthy. Passes if +object+ is +nil+ or + # +false+. "Truthy" means "considered true in a conditional" like if + # foo. # # assert_not nil # => true # assert_not false # => true @@ -10949,12 +12787,34 @@ module ActiveSupport::Testing::Assertions # perform_service(param: 'no_exception') # end # - # source://activesupport//lib/active_support/testing/assertions.rb#33 + # source://activesupport//lib/active_support/testing/assertions.rb#48 def assert_nothing_raised; end + # Asserts that a block raises one of +exp+. This is an enhancement of the + # standard Minitest assertion method with the ability to test error + # messages. + # + # assert_raises(ArgumentError, match: /incorrect param/i) do + # perform_service(param: 'exception') + # end + # + # source://activesupport//lib/active_support/testing/assertions.rb#34 + def assert_raise(*exp, match: T.unsafe(nil), &block); end + + # Asserts that a block raises one of +exp+. This is an enhancement of the + # standard Minitest assertion method with the ability to test error + # messages. + # + # assert_raises(ArgumentError, match: /incorrect param/i) do + # perform_service(param: 'exception') + # end + # + # source://activesupport//lib/active_support/testing/assertions.rb#34 + def assert_raises(*exp, match: T.unsafe(nil), &block); end + private - # source://activesupport//lib/active_support/testing/assertions.rb#249 + # source://activesupport//lib/active_support/testing/assertions.rb#265 def _assert_nothing_raised_or_warn(assertion, &block); end end @@ -10999,6 +12859,35 @@ module ActiveSupport::Testing::ConstantLookup::ClassMethods def determine_constant_from_test_name(test_name); end end +# source://activesupport//lib/active_support/testing/constant_stubbing.rb#5 +module ActiveSupport::Testing::ConstantStubbing + # Changes the value of a constant for the duration of a block. Example: + # + # # World::List::Import::LARGE_IMPORT_THRESHOLD = 5000 + # stub_const(World::List::Import, :LARGE_IMPORT_THRESHOLD, 1) do + # assert_equal 1, World::List::Import::LARGE_IMPORT_THRESHOLD + # end + # + # assert_equal 5000, World::List::Import::LARGE_IMPORT_THRESHOLD + # + # Using this method rather than forcing World::List::Import::LARGE_IMPORT_THRESHOLD = 5000 prevents + # warnings from being thrown, and ensures that the old value is returned after the test has completed. + # + # If the constant doesn't already exists, but you need it set for the duration of the block + # you can do so by passing `exists: false`. + # + # stub_const(object, :SOME_CONST, 1, exists: false) do + # assert_equal 1, SOME_CONST + # end + # + # Note: Stubbing a const will stub it across all threads. So if you have concurrent threads + # (like separate test suites running in parallel) that all depend on the same constant, it's possible + # divergent stubbing will trample on each other. + # + # source://activesupport//lib/active_support/testing/constant_stubbing.rb#28 + def stub_const(mod, constant, new_value, exists: T.unsafe(nil)); end +end + # source://activesupport//lib/active_support/testing/declarative.rb#5 module ActiveSupport::Testing::Declarative # Helper to define a test method using a String. Under the hood, it replaces @@ -11014,6 +12903,10 @@ end # source://activesupport//lib/active_support/testing/deprecation.rb#7 module ActiveSupport::Testing::Deprecation + # :call-seq: + # assert_deprecated(deprecator, &block) + # assert_deprecated(match, deprecator, &block) + # # Asserts that a matching deprecation warning was emitted by the given deprecator during the execution of the yielded block. # # assert_deprecated(/foo/, CustomDeprecator) do @@ -11028,17 +12921,11 @@ module ActiveSupport::Testing::Deprecation # # If the +match+ is omitted (or explicitly +nil+), any deprecation warning will match. # - # assert_deprecated(nil, CustomDeprecator) do + # assert_deprecated(CustomDeprecator) do # CustomDeprecator.warn "foo should no longer be used" # end # - # If no +deprecator+ is given, defaults to ActiveSupport::Deprecation. - # - # assert_deprecated do - # ActiveSupport::Deprecation.warn "foo should no longer be used" - # end - # - # source://activesupport//lib/active_support/testing/deprecation.rb#31 + # source://activesupport//lib/active_support/testing/deprecation.rb#30 def assert_deprecated(match = T.unsafe(nil), deprecator = T.unsafe(nil), &block); end # Asserts that no deprecation warnings are emitted by the given deprecator during the execution of the yielded block. @@ -11047,35 +12934,149 @@ module ActiveSupport::Testing::Deprecation # CustomDeprecator.warn "message" # fails assertion # end # - # If no +deprecator+ is given, defaults to ActiveSupport::Deprecation. - # - # assert_not_deprecated do - # ActiveSupport::Deprecation.warn "message" # fails assertion - # end - # - # assert_not_deprecated do - # CustomDeprecator.warn "message" # passes assertion + # assert_not_deprecated(ActiveSupport::Deprecation.new) do + # CustomDeprecator.warn "message" # passes assertion, different deprecator # end # - # source://activesupport//lib/active_support/testing/deprecation.rb#56 - def assert_not_deprecated(deprecator = T.unsafe(nil), &block); end + # source://activesupport//lib/active_support/testing/deprecation.rb#55 + def assert_not_deprecated(deprecator, &block); end - # Returns an array of all the deprecation warnings emitted by the given + # Returns the return value of the block and an array of all the deprecation warnings emitted by the given # +deprecator+ during the execution of the yielded block. # # collect_deprecations(CustomDeprecator) do # CustomDeprecator.warn "message" - # end # => ["message"] + # ActiveSupport::Deprecation.new.warn "other message" + # :result + # end # => [:result, ["message"]] + # + # source://activesupport//lib/active_support/testing/deprecation.rb#69 + def collect_deprecations(deprecator); end +end + +# source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#5 +module ActiveSupport::Testing::ErrorReporterAssertions + # Assertion that the block should cause at least one exception to be reported + # to +Rails.error+. + # + # Passes if the evaluated code in the yielded block reports a matching exception. + # + # assert_error_reported(IOError) do + # Rails.error.report(IOError.new("Oops")) + # end + # + # To test further details about the reported exception, you can use the return + # value. + # + # report = assert_error_reported(IOError) do + # # ... + # end + # assert_equal "Oops", report.error.message + # assert_equal "admin", report.context[:section] + # assert_equal :warning, report.severity + # assert_predicate report, :handled? + # + # source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#88 + def assert_error_reported(error_class = T.unsafe(nil), &block); end + + # Assertion that the block should not cause an exception to be reported + # to +Rails.error+. + # + # Passes if evaluated code in the yielded block reports no exception. + # + # assert_no_error_reported do + # perform_service(param: 'no_exception') + # end + # + # source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#62 + def assert_no_error_reported(&block); end +end + +# source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#6 +module ActiveSupport::Testing::ErrorReporterAssertions::ErrorCollector + class << self + # source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#16 + def record; end + + # source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#29 + def report(error, **kwargs); end + + private + + # source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#38 + def subscribe; end + end +end + +# source://activesupport//lib/active_support/testing/error_reporter_assertions.rb#10 +class ActiveSupport::Testing::ErrorReporterAssertions::ErrorCollector::Report < ::Struct + # Returns the value of attribute context + # + # @return [Object] the current value of context + def context; end + + # Sets the attribute context + # + # @param value [Object] the value to set the attribute context to. + # @return [Object] the newly set value + def context=(_); end + + # Returns the value of attribute error + # + # @return [Object] the current value of error + def error; end + + # Sets the attribute error + # + # @param value [Object] the value to set the attribute error to. + # @return [Object] the newly set value + def error=(_); end + + # Returns the value of attribute handled + # + # @return [Object] the current value of handled + def handled; end + + # Sets the attribute handled # - # If no +deprecator+ is given, defaults to ActiveSupport::Deprecation. + # @param value [Object] the value to set the attribute handled to. + # @return [Object] the newly set value + def handled=(_); end + + # Returns the value of attribute handled + # + # @return [Object] the current value of handled + def handled?; end + + # Returns the value of attribute severity + # + # @return [Object] the current value of severity + def severity; end + + # Sets the attribute severity + # + # @param value [Object] the value to set the attribute severity to. + # @return [Object] the newly set value + def severity=(_); end + + # Returns the value of attribute source # - # collect_deprecations do - # CustomDeprecator.warn "custom message" - # ActiveSupport::Deprecation.warn "message" - # end # => ["message"] + # @return [Object] the current value of source + def source; end + + # Sets the attribute source # - # source://activesupport//lib/active_support/testing/deprecation.rb#75 - def collect_deprecations(deprecator = T.unsafe(nil)); end + # @param value [Object] the value to set the attribute source to. + # @return [Object] the newly set value + def source=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end end # Adds simple access to sample files called file fixtures. @@ -11118,38 +13119,41 @@ end module ActiveSupport::Testing::Isolation include ::ActiveSupport::Testing::Isolation::Forking - # source://activesupport//lib/active_support/testing/isolation.rb#18 + # source://activesupport//lib/active_support/testing/isolation.rb#20 def run; end class << self # @return [Boolean] # - # source://activesupport//lib/active_support/testing/isolation.rb#14 + # source://activesupport//lib/active_support/testing/isolation.rb#16 def forking_env?; end - # source://activesupport//lib/active_support/testing/isolation.rb#8 + # source://activesupport//lib/active_support/testing/isolation.rb#10 def included(klass); end end end -# source://activesupport//lib/active_support/testing/isolation.rb#26 +# source://activesupport//lib/active_support/testing/isolation.rb#35 module ActiveSupport::Testing::Isolation::Forking - # source://activesupport//lib/active_support/testing/isolation.rb#27 + # source://activesupport//lib/active_support/testing/isolation.rb#36 def run_in_isolation(&blk); end end -# source://activesupport//lib/active_support/testing/isolation.rb#64 +# source://activesupport//lib/active_support/testing/isolation.rb#73 module ActiveSupport::Testing::Isolation::Subprocess - # Complicated H4X to get this working in windows / jruby with + # Complicated H4X to get this working in Windows / JRuby with # no forking. # - # source://activesupport//lib/active_support/testing/isolation.rb#69 + # source://activesupport//lib/active_support/testing/isolation.rb#78 def run_in_isolation(&blk); end end -# source://activesupport//lib/active_support/testing/isolation.rb#65 +# source://activesupport//lib/active_support/testing/isolation.rb#74 ActiveSupport::Testing::Isolation::Subprocess::ORIG_ARGV = T.let(T.unsafe(nil), Array) +# source://activesupport//lib/active_support/testing/isolation.rb#8 +class ActiveSupport::Testing::Isolation::SubprocessCrashed < ::StandardError; end + # source://activesupport//lib/active_support/testing/parallelization/server.rb#8 class ActiveSupport::Testing::Parallelization # @return [Parallelization] a new instance of Parallelization @@ -11269,7 +13273,7 @@ class ActiveSupport::Testing::ParallelizeExecutor # source://activesupport//lib/active_support/testing/parallelize_executor.rb#8 def initialize(size:, with:, threshold: T.unsafe(nil)); end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#21 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#22 def <<(work); end # Returns the value of attribute parallelize_with. @@ -11277,7 +13281,7 @@ class ActiveSupport::Testing::ParallelizeExecutor # source://activesupport//lib/active_support/testing/parallelize_executor.rb#6 def parallelize_with; end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#25 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#26 def shutdown; end # Returns the value of attribute size. @@ -11285,7 +13289,7 @@ class ActiveSupport::Testing::ParallelizeExecutor # source://activesupport//lib/active_support/testing/parallelize_executor.rb#6 def size; end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#14 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#15 def start; end # Returns the value of attribute threshold. @@ -11295,32 +13299,37 @@ class ActiveSupport::Testing::ParallelizeExecutor private - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#34 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#35 def build_parallel_executor; end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#67 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#72 def execution_info; end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#30 + # @return [Boolean] + # + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#60 + def many_workers?; end + + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#31 def parallel_executor; end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#46 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#47 def parallelize; end # @return [Boolean] # - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#51 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#52 def parallelized?; end # @return [Boolean] # - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#55 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#56 def should_parallelize?; end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#63 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#68 def show_execution_info; end - # source://activesupport//lib/active_support/testing/parallelize_executor.rb#59 + # source://activesupport//lib/active_support/testing/parallelize_executor.rb#64 def tests_count; end end @@ -11367,11 +13376,11 @@ end # Manages stubs for TimeHelpers # -# source://activesupport//lib/active_support/testing/time_helpers.rb#10 +# source://activesupport//lib/active_support/testing/time_helpers.rb#9 class ActiveSupport::Testing::SimpleStubs # @return [SimpleStubs] a new instance of SimpleStubs # - # source://activesupport//lib/active_support/testing/time_helpers.rb#13 + # source://activesupport//lib/active_support/testing/time_helpers.rb#12 def initialize; end # Stubs object.method_name with the given block @@ -11382,36 +13391,36 @@ class ActiveSupport::Testing::SimpleStubs # simple_stubs.stub_object(Time, :now) { at(target.to_i) } # Time.current # => Wed, 24 Nov 2004 01:04:44 EST -05:00 # - # source://activesupport//lib/active_support/testing/time_helpers.rb#24 + # source://activesupport//lib/active_support/testing/time_helpers.rb#23 def stub_object(object, method_name, &block); end # Returns true if any stubs are set, false if there are none # # @return [Boolean] # - # source://activesupport//lib/active_support/testing/time_helpers.rb#54 + # source://activesupport//lib/active_support/testing/time_helpers.rb#53 def stubbed?; end # Returns the Stub for object#method_name # (nil if it is not stubbed) # - # source://activesupport//lib/active_support/testing/time_helpers.rb#49 + # source://activesupport//lib/active_support/testing/time_helpers.rb#48 def stubbing(object, method_name); end # Remove all object-method stubs held by this instance # - # source://activesupport//lib/active_support/testing/time_helpers.rb#38 + # source://activesupport//lib/active_support/testing/time_helpers.rb#37 def unstub_all!; end private # Restores the original object.method described by the Stub # - # source://activesupport//lib/active_support/testing/time_helpers.rb#60 + # source://activesupport//lib/active_support/testing/time_helpers.rb#59 def unstub_object(stub); end end -# source://activesupport//lib/active_support/testing/time_helpers.rb#11 +# source://activesupport//lib/active_support/testing/time_helpers.rb#10 class ActiveSupport::Testing::SimpleStubs::Stub < ::Struct # Returns the value of attribute method_name # @@ -11486,14 +13495,24 @@ module ActiveSupport::Testing::TaggedLogging def tagged_logger; end end +# Warns when a test case does not perform any assertions. +# +# This is helpful in detecting broken tests that do not perform intended assertions. +# +# source://activesupport//lib/active_support/testing/tests_without_assertions.rb#8 +module ActiveSupport::Testing::TestsWithoutAssertions + # source://activesupport//lib/active_support/testing/tests_without_assertions.rb#9 + def after_teardown; end +end + # Contains helpers that help you test passage of time. # -# source://activesupport//lib/active_support/testing/time_helpers.rb#69 +# source://activesupport//lib/active_support/testing/time_helpers.rb#68 module ActiveSupport::Testing::TimeHelpers - # source://activesupport//lib/active_support/testing/time_helpers.rb#70 + # source://activesupport//lib/active_support/testing/time_helpers.rb#69 def after_teardown; end - # Calls +travel_to+ with +Time.now+. + # Calls +travel_to+ with +Time.now+. Forwards optional with_usec argument. # # Time.current # => Sun, 09 Jul 2017 15:34:49 EST -05:00 # freeze_time @@ -11510,13 +13529,18 @@ module ActiveSupport::Testing::TimeHelpers # end # Time.current # => Sun, 09 Jul 2017 15:34:50 EST -05:00 # - # source://activesupport//lib/active_support/testing/time_helpers.rb#234 - def freeze_time(&block); end + # source://activesupport//lib/active_support/testing/time_helpers.rb#256 + def freeze_time(with_usec: T.unsafe(nil), &block); end # Changes current time to the time in the future or in the past by a given time difference by # stubbing +Time.now+, +Date.today+, and +DateTime.now+. The stubs are automatically removed # at the end of the test. # + # Note that the usec for the resulting time will be set to 0 to prevent rounding + # errors with external services, like MySQL (which will round instead of floor, + # leading to off-by-one-second errors), unless the with_usec argument + # is set to true. + # # Time.current # => Sat, 09 Nov 2013 15:34:49 EST -05:00 # travel 1.day # Time.current # => Sun, 10 Nov 2013 15:34:49 EST -05:00 @@ -11532,8 +13556,8 @@ module ActiveSupport::Testing::TimeHelpers # end # Time.current # => Sat, 09 Nov 2013 15:34:49 EST -05:00 # - # source://activesupport//lib/active_support/testing/time_helpers.rb#93 - def travel(duration, &block); end + # source://activesupport//lib/active_support/testing/time_helpers.rb#97 + def travel(duration, with_usec: T.unsafe(nil), &block); end # Returns the current time back to its original state, by removing the stubs added by # +travel+, +travel_to+, and +freeze_time+. @@ -11559,10 +13583,10 @@ module ActiveSupport::Testing::TimeHelpers # # Time.current # => Wed, 24 Nov 2004 01:04:44 EST -05:00 # - # source://activesupport//lib/active_support/testing/time_helpers.rb#208 + # source://activesupport//lib/active_support/testing/time_helpers.rb#230 def travel_back; end - # Changes current time to the given time by stubbing +Time.now+, + # Changes current time to the given time by stubbing +Time.now+, +Time.new+, # +Date.today+, and +DateTime.now+ to return the time or date passed into this method. # The stubs are automatically removed at the end of the test. # @@ -11583,7 +13607,8 @@ module ActiveSupport::Testing::TimeHelpers # # Note that the usec for the time passed will be set to 0 to prevent rounding # errors with external services, like MySQL (which will round instead of floor, - # leading to off-by-one-second errors). + # leading to off-by-one-second errors), unless the with_usec argument + # is set to true. # # This method also accepts a block, which will return the current time back to its original # state at the end of the block: @@ -11594,8 +13619,8 @@ module ActiveSupport::Testing::TimeHelpers # end # Time.current # => Sat, 09 Nov 2013 15:34:49 EST -05:00 # - # source://activesupport//lib/active_support/testing/time_helpers.rb#128 - def travel_to(date_or_time); end + # source://activesupport//lib/active_support/testing/time_helpers.rb#133 + def travel_to(date_or_time, with_usec: T.unsafe(nil)); end # Returns the current time back to its original state, by removing the stubs added by # +travel+, +travel_to+, and +freeze_time+. @@ -11621,27 +13646,29 @@ module ActiveSupport::Testing::TimeHelpers # # Time.current # => Wed, 24 Nov 2004 01:04:44 EST -05:00 # - # source://activesupport//lib/active_support/testing/time_helpers.rb#208 + # source://activesupport//lib/active_support/testing/time_helpers.rb#230 def unfreeze_time; end private # Returns the value of attribute in_block. # - # source://activesupport//lib/active_support/testing/time_helpers.rb#243 + # source://activesupport//lib/active_support/testing/time_helpers.rb#265 def in_block; end # Sets the attribute in_block # # @param value the value to set the attribute in_block to. # - # source://activesupport//lib/active_support/testing/time_helpers.rb#243 + # source://activesupport//lib/active_support/testing/time_helpers.rb#265 def in_block=(_arg0); end - # source://activesupport//lib/active_support/testing/time_helpers.rb#239 + # source://activesupport//lib/active_support/testing/time_helpers.rb#261 def simple_stubs; end end +# = Active Support \Time With Zone +# # A Time-like class that can represent a time in any time zone. Necessary # because standard Ruby Time instances are limited to UTC and the # system's ENV['TZ'] zone. @@ -11674,14 +13701,14 @@ end # t.is_a?(Time) # => true # t.is_a?(ActiveSupport::TimeWithZone) # => true # -# source://activesupport//lib/active_support/time_with_zone.rb#42 +# source://activesupport//lib/active_support/time_with_zone.rb#44 class ActiveSupport::TimeWithZone include ::DateAndTime::Compatibility include ::Comparable # @return [TimeWithZone] a new instance of TimeWithZone # - # source://activesupport//lib/active_support/time_with_zone.rb#61 + # source://activesupport//lib/active_support/time_with_zone.rb#51 def initialize(utc_time, time_zone, local_time = T.unsafe(nil), period = T.unsafe(nil)); end # Adds an interval of time to the current object's time and returns that @@ -11701,7 +13728,7 @@ class ActiveSupport::TimeWithZone # now + 24.hours # => Mon, 03 Nov 2014 00:26:28.725182881 EST -05:00 # now + 1.day # => Mon, 03 Nov 2014 01:26:28.725182881 EST -05:00 # - # source://activesupport//lib/active_support/time_with_zone.rb#328 + # source://activesupport//lib/active_support/time_with_zone.rb#299 def +(other); end # Subtracts an interval of time and returns a new TimeWithZone object unless @@ -11727,19 +13754,19 @@ class ActiveSupport::TimeWithZone # # Time.zone.now - 1.day.ago # => 86399.999967 # - # source://activesupport//lib/active_support/time_with_zone.rb#362 + # source://activesupport//lib/active_support/time_with_zone.rb#333 def -(other); end # Use the time in UTC for comparisons. # - # source://activesupport//lib/active_support/time_with_zone.rb#261 + # source://activesupport//lib/active_support/time_with_zone.rb#232 def <=>(other); end # So that +self+ acts_like?(:time). # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#523 + # source://activesupport//lib/active_support/time_with_zone.rb#494 def acts_like_time?; end # Uses Date to provide precise Time calculations for years, months, and days @@ -11764,7 +13791,7 @@ class ActiveSupport::TimeWithZone # now.advance(months: 1) # => Tue, 02 Dec 2014 01:26:28.558049687 EST -05:00 # now.advance(years: 1) # => Mon, 02 Nov 2015 01:26:28.558049687 EST -05:00 # - # source://activesupport//lib/active_support/time_with_zone.rb#451 + # source://activesupport//lib/active_support/time_with_zone.rb#422 def advance(options); end def after?(_arg0); end @@ -11787,7 +13814,7 @@ class ActiveSupport::TimeWithZone # now.ago(24.hours) # => Sun, 02 Nov 2014 01:26:28.725182881 EDT -04:00 # now.ago(1.day) # => Sun, 02 Nov 2014 00:26:28.725182881 EDT -04:00 # - # source://activesupport//lib/active_support/time_with_zone.rb#390 + # source://activesupport//lib/active_support/time_with_zone.rb#361 def ago(other); end # Coerces time to a string for JSON encoding. The default format is ISO 8601. @@ -11803,7 +13830,7 @@ class ActiveSupport::TimeWithZone # Time.utc(2005,2,1,15,15,10).in_time_zone("Hawaii").to_json # # => "2005/02/01 05:15:10 -1000" # - # source://activesupport//lib/active_support/time_with_zone.rb#176 + # source://activesupport//lib/active_support/time_with_zone.rb#166 def as_json(options = T.unsafe(nil)); end def before?(_arg0); end @@ -11813,14 +13840,14 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#269 + # source://activesupport//lib/active_support/time_with_zone.rb#240 def between?(min, max); end # An instance of ActiveSupport::TimeWithZone is never blank # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#534 + # source://activesupport//lib/active_support/time_with_zone.rb#505 def blank?; end # Returns a new +ActiveSupport::TimeWithZone+ where one or more of the elements have @@ -11836,20 +13863,20 @@ class ActiveSupport::TimeWithZone # # t = Time.zone.now # => Fri, 14 Apr 2017 11:45:15.116992711 EST -05:00 # t.change(year: 2020) # => Tue, 14 Apr 2020 11:45:15.116992711 EST -05:00 - # t.change(hour: 12) # => Fri, 14 Apr 2017 12:00:00.116992711 EST -05:00 - # t.change(min: 30) # => Fri, 14 Apr 2017 11:30:00.116992711 EST -05:00 + # t.change(hour: 12) # => Fri, 14 Apr 2017 12:00:00.000000000 EST -05:00 + # t.change(min: 30) # => Fri, 14 Apr 2017 11:30:00.000000000 EST -05:00 # t.change(offset: "-10:00") # => Fri, 14 Apr 2017 11:45:15.116992711 HST -10:00 # t.change(zone: "Hawaii") # => Fri, 14 Apr 2017 11:45:15.116992711 HST -10:00 # - # source://activesupport//lib/active_support/time_with_zone.rb#411 + # source://activesupport//lib/active_support/time_with_zone.rb#382 def change(options); end # Returns a Time instance of the simultaneous time in the UTC timezone. # - # source://activesupport//lib/active_support/time_with_zone.rb#73 + # source://activesupport//lib/active_support/time_with_zone.rb#63 def comparable_time; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def day; end # Returns true if the current time is within Daylight Savings Time for the @@ -11861,17 +13888,17 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#104 + # source://activesupport//lib/active_support/time_with_zone.rb#94 def dst?; end - # source://activesupport//lib/active_support/time_with_zone.rb#188 + # source://activesupport//lib/active_support/time_with_zone.rb#178 def encode_with(coder); end # Returns +true+ if +other+ is equal to current object. # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#304 + # source://activesupport//lib/active_support/time_with_zone.rb#275 def eql?(other); end # Returns a formatted string of the offset from UTC, or an alternative @@ -11883,32 +13910,32 @@ class ActiveSupport::TimeWithZone # Time.zone = 'UTC' # => "UTC" # Time.zone.now.formatted_offset(true, "0") # => "0" # - # source://activesupport//lib/active_support/time_with_zone.rb#135 + # source://activesupport//lib/active_support/time_with_zone.rb#125 def formatted_offset(colon = T.unsafe(nil), alternate_utc_string = T.unsafe(nil)); end - # source://activesupport//lib/active_support/time_with_zone.rb#538 + # source://activesupport//lib/active_support/time_with_zone.rb#513 def freeze; end # Returns true if the current object's time is in the future. # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#299 + # source://activesupport//lib/active_support/time_with_zone.rb#270 def future?; end # Returns a Time instance of the simultaneous time in the UTC timezone. # - # source://activesupport//lib/active_support/time_with_zone.rb#73 + # source://activesupport//lib/active_support/time_with_zone.rb#63 def getgm; end # Returns a Time instance of the simultaneous time in the system timezone. # - # source://activesupport//lib/active_support/time_with_zone.rb#93 + # source://activesupport//lib/active_support/time_with_zone.rb#83 def getlocal(utc_offset = T.unsafe(nil)); end # Returns a Time instance of the simultaneous time in the UTC timezone. # - # source://activesupport//lib/active_support/time_with_zone.rb#73 + # source://activesupport//lib/active_support/time_with_zone.rb#63 def getutc; end # Returns true if the current time zone is set to UTC. @@ -11920,28 +13947,28 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#115 + # source://activesupport//lib/active_support/time_with_zone.rb#105 def gmt?; end # Returns the offset from current time to UTC time in seconds. # - # source://activesupport//lib/active_support/time_with_zone.rb#121 + # source://activesupport//lib/active_support/time_with_zone.rb#111 def gmt_offset; end # Returns a Time instance of the simultaneous time in the UTC timezone. # - # source://activesupport//lib/active_support/time_with_zone.rb#73 + # source://activesupport//lib/active_support/time_with_zone.rb#63 def gmtime; end # Returns the offset from current time to UTC time in seconds. # - # source://activesupport//lib/active_support/time_with_zone.rb#121 + # source://activesupport//lib/active_support/time_with_zone.rb#111 def gmtoff; end - # source://activesupport//lib/active_support/time_with_zone.rb#308 + # source://activesupport//lib/active_support/time_with_zone.rb#279 def hash; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def hour; end # Returns a string of the object's date and time in the format used by @@ -11949,7 +13976,7 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.httpdate # => "Tue, 01 Jan 2013 04:39:43 GMT" # - # source://activesupport//lib/active_support/time_with_zone.rb#196 + # source://activesupport//lib/active_support/time_with_zone.rb#186 def httpdate; end # Adds an interval of time to the current object's time and returns that @@ -11969,29 +13996,29 @@ class ActiveSupport::TimeWithZone # now + 24.hours # => Mon, 03 Nov 2014 00:26:28.725182881 EST -05:00 # now + 1.day # => Mon, 03 Nov 2014 01:26:28.725182881 EST -05:00 # - # source://activesupport//lib/active_support/time_with_zone.rb#328 + # source://activesupport//lib/active_support/time_with_zone.rb#299 def in(other); end # Returns the simultaneous time in Time.zone, or the specified zone. # - # source://activesupport//lib/active_support/time_with_zone.rb#87 + # source://activesupport//lib/active_support/time_with_zone.rb#77 def in_time_zone(new_zone = T.unsafe(nil)); end - # source://activesupport//lib/active_support/time_with_zone.rb#184 + # source://activesupport//lib/active_support/time_with_zone.rb#174 def init_with(coder); end # Returns a string of the object's date, time, zone, and offset from UTC. # # Time.zone.now.inspect # => "Thu, 04 Dec 2014 11:00:25.624541392 EST -05:00" # - # source://activesupport//lib/active_support/time_with_zone.rb#150 + # source://activesupport//lib/active_support/time_with_zone.rb#140 def inspect; end # Say we're a Time to thwart type checking. # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#528 + # source://activesupport//lib/active_support/time_with_zone.rb#499 def is_a?(klass); end # Returns true if the current time is within Daylight Savings Time for the @@ -12003,7 +14030,7 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#104 + # source://activesupport//lib/active_support/time_with_zone.rb#94 def isdst; end # Returns a string of the object's date and time in the ISO 8601 standard @@ -12011,43 +14038,43 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.xmlschema # => "2014-12-04T11:02:37-05:00" # - # source://activesupport//lib/active_support/time_with_zone.rb#158 + # source://activesupport//lib/active_support/time_with_zone.rb#148 def iso8601(fraction_digits = T.unsafe(nil)); end # Say we're a Time to thwart type checking. # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#528 + # source://activesupport//lib/active_support/time_with_zone.rb#499 def kind_of?(klass); end # Returns a Time instance of the simultaneous time in the system timezone. # - # source://activesupport//lib/active_support/time_with_zone.rb#93 + # source://activesupport//lib/active_support/time_with_zone.rb#83 def localtime(utc_offset = T.unsafe(nil)); end - # source://activesupport//lib/active_support/time_with_zone.rb#544 + # source://activesupport//lib/active_support/time_with_zone.rb#519 def marshal_dump; end - # source://activesupport//lib/active_support/time_with_zone.rb#548 + # source://activesupport//lib/active_support/time_with_zone.rb#523 def marshal_load(variables); end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def mday; end # Send the missing method to +time+ instance, and wrap result in a new # TimeWithZone with the existing +time_zone+. # - # source://activesupport//lib/active_support/time_with_zone.rb#569 + # source://activesupport//lib/active_support/time_with_zone.rb#544 def method_missing(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def min; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def mon; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def month; end # Returns true if the current object's time falls within @@ -12055,30 +14082,35 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#286 + # source://activesupport//lib/active_support/time_with_zone.rb#257 def next_day?; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def nsec; end # Returns true if the current object's time is in the past. # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#274 + # source://activesupport//lib/active_support/time_with_zone.rb#245 def past?; end - # Returns the underlying TZInfo::TimezonePeriod. + # Returns the underlying +TZInfo::TimezonePeriod+. # - # source://activesupport//lib/active_support/time_with_zone.rb#82 + # source://activesupport//lib/active_support/time_with_zone.rb#72 def period; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/time_with_zone.rb#509 + def present?; end + # Returns true if the current object's time falls within # the previous day (yesterday). # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#293 + # source://activesupport//lib/active_support/time_with_zone.rb#264 def prev_day?; end # respond_to_missing? is not called in some cases, such as when type conversion is @@ -12086,7 +14118,7 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#554 + # source://activesupport//lib/active_support/time_with_zone.rb#529 def respond_to?(sym, include_priv = T.unsafe(nil)); end # Returns a string of the object's date and time in the RFC 2822 standard @@ -12094,7 +14126,7 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.rfc2822 # => "Tue, 01 Jan 2013 04:51:39 +0000" # - # source://activesupport//lib/active_support/time_with_zone.rb#204 + # source://activesupport//lib/active_support/time_with_zone.rb#194 def rfc2822; end # Returns a string of the object's date and time in the ISO 8601 standard @@ -12102,7 +14134,7 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.xmlschema # => "2014-12-04T11:02:37-05:00" # - # source://activesupport//lib/active_support/time_with_zone.rb#158 + # source://activesupport//lib/active_support/time_with_zone.rb#148 def rfc3339(fraction_digits = T.unsafe(nil)); end # Returns a string of the object's date and time in the RFC 2822 standard @@ -12110,10 +14142,10 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.rfc2822 # => "Tue, 01 Jan 2013 04:51:39 +0000" # - # source://activesupport//lib/active_support/time_with_zone.rb#204 + # source://activesupport//lib/active_support/time_with_zone.rb#194 def rfc822; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def sec; end # Adds an interval of time to the current object's time and returns that @@ -12133,23 +14165,23 @@ class ActiveSupport::TimeWithZone # now + 24.hours # => Mon, 03 Nov 2014 00:26:28.725182881 EST -05:00 # now + 1.day # => Mon, 03 Nov 2014 01:26:28.725182881 EST -05:00 # - # source://activesupport//lib/active_support/time_with_zone.rb#328 + # source://activesupport//lib/active_support/time_with_zone.rb#299 def since(other); end # Replaces %Z directive with +zone before passing to Time#strftime, # so that zone information is correct. # - # source://activesupport//lib/active_support/time_with_zone.rb#255 + # source://activesupport//lib/active_support/time_with_zone.rb#226 def strftime(format); end # Returns a Time instance that represents the time in +time_zone+. # - # source://activesupport//lib/active_support/time_with_zone.rb#68 + # source://activesupport//lib/active_support/time_with_zone.rb#58 def time; end # Returns the value of attribute time_zone. # - # source://activesupport//lib/active_support/time_with_zone.rb#59 + # source://activesupport//lib/active_support/time_with_zone.rb#49 def time_zone; end # Returns Array of parts of Time in sequence of @@ -12158,10 +14190,10 @@ class ActiveSupport::TimeWithZone # now = Time.zone.now # => Tue, 18 Aug 2015 02:29:27.485278555 UTC +00:00 # now.to_a # => [27, 29, 2, 18, 8, 2015, 2, 230, false, "UTC"] # - # source://activesupport//lib/active_support/time_with_zone.rb#474 + # source://activesupport//lib/active_support/time_with_zone.rb#445 def to_a; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def to_date; end # Returns an instance of DateTime with the timezone's UTC offset @@ -12169,7 +14201,7 @@ class ActiveSupport::TimeWithZone # Time.zone.now.to_datetime # => Tue, 18 Aug 2015 02:32:20 +0000 # Time.current.in_time_zone('Hawaii').to_datetime # => Mon, 17 Aug 2015 16:32:20 -1000 # - # source://activesupport//lib/active_support/time_with_zone.rb#507 + # source://activesupport//lib/active_support/time_with_zone.rb#478 def to_datetime; end # Returns the object's date and time as a floating-point number of seconds @@ -12177,7 +14209,7 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.to_f # => 1417709320.285418 # - # source://activesupport//lib/active_support/time_with_zone.rb#482 + # source://activesupport//lib/active_support/time_with_zone.rb#453 def to_f; end # Returns a string of the object's date and time. @@ -12187,9 +14219,9 @@ class ActiveSupport::TimeWithZone # Accepts an optional format: # * :default - default value, mimics Ruby Time#to_s format. # * :db - format outputs time in UTC :db time. See Time#to_fs(:db). - # * Any key in Time::DATE_FORMATS can be used. See active_support/core_ext/time/conversions.rb. + # * Any key in +Time::DATE_FORMATS+ can be used. See active_support/core_ext/time/conversions.rb. # - # source://activesupport//lib/active_support/time_with_zone.rb#241 + # source://activesupport//lib/active_support/time_with_zone.rb#212 def to_formatted_s(format = T.unsafe(nil)); end # Returns a string of the object's date and time. @@ -12199,9 +14231,9 @@ class ActiveSupport::TimeWithZone # Accepts an optional format: # * :default - default value, mimics Ruby Time#to_s format. # * :db - format outputs time in UTC :db time. See Time#to_fs(:db). - # * Any key in Time::DATE_FORMATS can be used. See active_support/core_ext/time/conversions.rb. + # * Any key in +Time::DATE_FORMATS+ can be used. See active_support/core_ext/time/conversions.rb. # - # source://activesupport//lib/active_support/time_with_zone.rb#241 + # source://activesupport//lib/active_support/time_with_zone.rb#212 def to_fs(format = T.unsafe(nil)); end # Returns the object's date and time as an integer number of seconds @@ -12209,7 +14241,7 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.to_i # => 1417709320 # - # source://activesupport//lib/active_support/time_with_zone.rb#490 + # source://activesupport//lib/active_support/time_with_zone.rb#461 def to_i; end # Returns the object's date and time as a rational number of seconds @@ -12217,19 +14249,19 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.to_r # => (708854548642709/500000) # - # source://activesupport//lib/active_support/time_with_zone.rb#499 + # source://activesupport//lib/active_support/time_with_zone.rb#470 def to_r; end # Returns a string of the object's date and time. # - # source://activesupport//lib/active_support/time_with_zone.rb#212 - def to_s(format = T.unsafe(nil)); end + # source://activesupport//lib/active_support/time_with_zone.rb#200 + def to_s; end # Returns an instance of +Time+, either with the same UTC offset # as +self+ or in the local system timezone depending on the setting # of +ActiveSupport.to_time_preserves_timezone+. # - # source://activesupport//lib/active_support/time_with_zone.rb#514 + # source://activesupport//lib/active_support/time_with_zone.rb#485 def to_time; end # Returns true if the current object's time falls within @@ -12237,7 +14269,7 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#280 + # source://activesupport//lib/active_support/time_with_zone.rb#251 def today?; end # Returns true if the current object's time falls within @@ -12245,7 +14277,7 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#286 + # source://activesupport//lib/active_support/time_with_zone.rb#257 def tomorrow?; end # Returns the object's date and time as an integer number of seconds @@ -12253,15 +14285,15 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.to_i # => 1417709320 # - # source://activesupport//lib/active_support/time_with_zone.rb#490 + # source://activesupport//lib/active_support/time_with_zone.rb#461 def tv_sec; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def usec; end # Returns a Time instance of the simultaneous time in the UTC timezone. # - # source://activesupport//lib/active_support/time_with_zone.rb#73 + # source://activesupport//lib/active_support/time_with_zone.rb#63 def utc; end # Returns true if the current time zone is set to UTC. @@ -12273,15 +14305,15 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#115 + # source://activesupport//lib/active_support/time_with_zone.rb#105 def utc?; end # Returns the offset from current time to UTC time in seconds. # - # source://activesupport//lib/active_support/time_with_zone.rb#121 + # source://activesupport//lib/active_support/time_with_zone.rb#111 def utc_offset; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def wday; end # Returns a string of the object's date and time in the ISO 8601 standard @@ -12289,13 +14321,13 @@ class ActiveSupport::TimeWithZone # # Time.zone.now.xmlschema # => "2014-12-04T11:02:37-05:00" # - # source://activesupport//lib/active_support/time_with_zone.rb#158 + # source://activesupport//lib/active_support/time_with_zone.rb#148 def xmlschema(fraction_digits = T.unsafe(nil)); end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def yday; end - # source://activesupport//lib/active_support/time_with_zone.rb#463 + # source://activesupport//lib/active_support/time_with_zone.rb#434 def year; end # Returns true if the current object's time falls within @@ -12303,7 +14335,7 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#293 + # source://activesupport//lib/active_support/time_with_zone.rb#264 def yesterday?; end # Returns the time zone abbreviation. @@ -12311,20 +14343,20 @@ class ActiveSupport::TimeWithZone # Time.zone = 'Eastern Time (US & Canada)' # => "Eastern Time (US & Canada)" # Time.zone.now.zone # => "EST" # - # source://activesupport//lib/active_support/time_with_zone.rb#143 + # source://activesupport//lib/active_support/time_with_zone.rb#133 def zone; end private # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#605 + # source://activesupport//lib/active_support/time_with_zone.rb#580 def duration_of_variable_length?(obj); end - # source://activesupport//lib/active_support/time_with_zone.rb#586 + # source://activesupport//lib/active_support/time_with_zone.rb#561 def get_period_and_ensure_valid_local_time(period); end - # source://activesupport//lib/active_support/time_with_zone.rb#578 + # source://activesupport//lib/active_support/time_with_zone.rb#553 def incorporate_utc_offset(time, offset); end # Ensure proxy class responds to all methods that underlying time instance @@ -12332,44 +14364,36 @@ class ActiveSupport::TimeWithZone # # @return [Boolean] # - # source://activesupport//lib/active_support/time_with_zone.rb#562 + # source://activesupport//lib/active_support/time_with_zone.rb#537 def respond_to_missing?(sym, include_priv); end - # source://activesupport//lib/active_support/time_with_zone.rb#599 + # source://activesupport//lib/active_support/time_with_zone.rb#574 def transfer_time_values_to_utc_constructor(time); end - # source://activesupport//lib/active_support/time_with_zone.rb#609 + # source://activesupport//lib/active_support/time_with_zone.rb#584 def wrap_with_time_zone(time); end - - class << self - # Report class name as 'Time' to thwart type checking. - # - # source://activesupport//lib/active_support/time_with_zone.rb#44 - def name; end - end end -# source://activesupport//lib/active_support/time_with_zone.rb#209 -ActiveSupport::TimeWithZone::NOT_SET = T.let(T.unsafe(nil), Object) - -# source://activesupport//lib/active_support/time_with_zone.rb#55 +# source://activesupport//lib/active_support/time_with_zone.rb#45 ActiveSupport::TimeWithZone::PRECISIONS = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/time_with_zone.rb#576 +# source://activesupport//lib/active_support/time_with_zone.rb#551 ActiveSupport::TimeWithZone::SECONDS_PER_DAY = T.let(T.unsafe(nil), Integer) -# The TimeZone class serves as a wrapper around TZInfo::Timezone instances. +# = Active Support \Time Zone +# +# The TimeZone class serves as a wrapper around +TZInfo::Timezone+ instances. # It allows us to do the following: # # * Limit the set of zones provided by TZInfo to a meaningful subset of 134 # zones. # * Retrieve and display zones with a friendlier name # (e.g., "Eastern Time (US & Canada)" instead of "America/New_York"). -# * Lazily load TZInfo::Timezone instances only when they're needed. +# * Lazily load +TZInfo::Timezone+ instances only when they're needed. # * Create ActiveSupport::TimeWithZone instances via TimeZone's +local+, # +parse+, +at+, and +now+ methods. # -# If you set config.time_zone in the Rails Application, you can +# If you set config.time_zone in the \Rails Application, you can # access this TimeZone object via Time.zone: # # # application.rb: @@ -12381,30 +14405,27 @@ ActiveSupport::TimeWithZone::SECONDS_PER_DAY = T.let(T.unsafe(nil), Integer) # Time.zone.name # => "Eastern Time (US & Canada)" # Time.zone.now # => Sun, 18 May 2008 14:30:44 EDT -04:00 # -# source://activesupport//lib/active_support/values/time_zone.rb#29 +# source://activesupport//lib/active_support/values/time_zone.rb#31 class ActiveSupport::TimeZone include ::Comparable - # Create a new TimeZone object with the given name and offset. The - # offset is the number of seconds that this time zone is offset from UTC - # (GMT). Seconds were chosen as the offset unit because that is the unit - # that Ruby uses to represent time zone offsets (see Time#utc_offset). + # :stopdoc: # # @return [TimeZone] a new instance of TimeZone # - # source://activesupport//lib/active_support/values/time_zone.rb#301 + # source://activesupport//lib/active_support/values/time_zone.rb#311 def initialize(name, utc_offset = T.unsafe(nil), tzinfo = T.unsafe(nil)); end # Compare this time zone to the parameter. The two are compared first on # their offsets, and then by name. # - # source://activesupport//lib/active_support/values/time_zone.rb#324 + # source://activesupport//lib/active_support/values/time_zone.rb#335 def <=>(zone); end # Compare #name and TZInfo identifier to a supplied regexp, returning +true+ # if a match is found. # - # source://activesupport//lib/active_support/values/time_zone.rb#333 + # source://activesupport//lib/active_support/values/time_zone.rb#344 def =~(re); end # Method for creating new ActiveSupport::TimeWithZone instance in time zone @@ -12419,10 +14440,10 @@ class ActiveSupport::TimeZone # Time.zone = 'Hawaii' # => "Hawaii" # Time.at(946684800, 123456.789).nsec # => 123456789 # - # source://activesupport//lib/active_support/values/time_zone.rb#370 + # source://activesupport//lib/active_support/values/time_zone.rb#381 def at(*args); end - # source://activesupport//lib/active_support/values/time_zone.rb#566 + # source://activesupport//lib/active_support/values/time_zone.rb#577 def encode_with(coder); end # Returns a formatted string of the offset from UTC, or an alternative @@ -12432,10 +14453,10 @@ class ActiveSupport::TimeZone # zone.formatted_offset # => "-06:00" # zone.formatted_offset(false) # => "-0600" # - # source://activesupport//lib/active_support/values/time_zone.rb#318 + # source://activesupport//lib/active_support/values/time_zone.rb#329 def formatted_offset(colon = T.unsafe(nil), alternate_utc_string = T.unsafe(nil)); end - # source://activesupport//lib/active_support/values/time_zone.rb#562 + # source://activesupport//lib/active_support/values/time_zone.rb#573 def init_with(coder); end # Method for creating new ActiveSupport::TimeWithZone instance in time zone @@ -12452,7 +14473,7 @@ class ActiveSupport::TimeZone # If the string is invalid then an +ArgumentError+ will be raised unlike +parse+ # which usually returns +nil+ when given an invalid date string. # - # source://activesupport//lib/active_support/values/time_zone.rb#387 + # source://activesupport//lib/active_support/values/time_zone.rb#398 def iso8601(str); end # Method for creating new ActiveSupport::TimeWithZone instance in time zone @@ -12461,13 +14482,13 @@ class ActiveSupport::TimeZone # Time.zone = 'Hawaii' # => "Hawaii" # Time.zone.local(2007, 2, 1, 15, 30, 45) # => Thu, 01 Feb 2007 15:30:45 HST -10:00 # - # source://activesupport//lib/active_support/values/time_zone.rb#354 + # source://activesupport//lib/active_support/values/time_zone.rb#365 def local(*args); end # Adjust the given time to the simultaneous time in UTC. Returns a # Time.utc() instance. # - # source://activesupport//lib/active_support/values/time_zone.rb#542 + # source://activesupport//lib/active_support/values/time_zone.rb#553 def local_to_utc(time, dst = T.unsafe(nil)); end # Compare #name and TZInfo identifier to a supplied regexp, returning +true+ @@ -12475,12 +14496,12 @@ class ActiveSupport::TimeZone # # @return [Boolean] # - # source://activesupport//lib/active_support/values/time_zone.rb#339 + # source://activesupport//lib/active_support/values/time_zone.rb#350 def match?(re); end # Returns the value of attribute name. # - # source://activesupport//lib/active_support/values/time_zone.rb#294 + # source://activesupport//lib/active_support/values/time_zone.rb#298 def name; end # Returns an ActiveSupport::TimeWithZone instance representing the current @@ -12489,7 +14510,7 @@ class ActiveSupport::TimeZone # Time.zone = 'Hawaii' # => "Hawaii" # Time.zone.now # => Wed, 23 Jan 2008 20:24:27 HST -10:00 # - # source://activesupport//lib/active_support/values/time_zone.rb#507 + # source://activesupport//lib/active_support/values/time_zone.rb#518 def now; end # Method for creating new ActiveSupport::TimeWithZone instance in time zone @@ -12511,22 +14532,22 @@ class ActiveSupport::TimeZone # # If the string is invalid then an +ArgumentError+ could be raised. # - # source://activesupport//lib/active_support/values/time_zone.rb#444 + # source://activesupport//lib/active_support/values/time_zone.rb#455 def parse(str, now = T.unsafe(nil)); end - # Available so that TimeZone instances respond like TZInfo::Timezone + # Available so that TimeZone instances respond like +TZInfo::Timezone+ # instances. # - # source://activesupport//lib/active_support/values/time_zone.rb#554 + # source://activesupport//lib/active_support/values/time_zone.rb#565 def period_for_local(time, dst = T.unsafe(nil)); end - # Available so that TimeZone instances respond like TZInfo::Timezone + # Available so that TimeZone instances respond like +TZInfo::Timezone+ # instances. # - # source://activesupport//lib/active_support/values/time_zone.rb#548 + # source://activesupport//lib/active_support/values/time_zone.rb#559 def period_for_utc(time); end - # source://activesupport//lib/active_support/values/time_zone.rb#558 + # source://activesupport//lib/active_support/values/time_zone.rb#569 def periods_for_local(time); end # Method for creating new ActiveSupport::TimeWithZone instance in time zone @@ -12544,7 +14565,7 @@ class ActiveSupport::TimeZone # # @raise [ArgumentError] # - # source://activesupport//lib/active_support/values/time_zone.rb#460 + # source://activesupport//lib/active_support/values/time_zone.rb#471 def rfc3339(str); end # Parses +str+ according to +format+ and returns an ActiveSupport::TimeWithZone. @@ -12568,32 +14589,32 @@ class ActiveSupport::TimeZone # # Time.zone.strptime('Mar 2000', '%b %Y') # => Wed, 01 Mar 2000 00:00:00 HST -10:00 # - # source://activesupport//lib/active_support/values/time_zone.rb#498 + # source://activesupport//lib/active_support/values/time_zone.rb#509 def strptime(str, format, now = T.unsafe(nil)); end # Returns a textual representation of this time zone. # - # source://activesupport//lib/active_support/values/time_zone.rb#345 + # source://activesupport//lib/active_support/values/time_zone.rb#356 def to_s; end # Returns the current date in this time zone. # - # source://activesupport//lib/active_support/values/time_zone.rb#512 + # source://activesupport//lib/active_support/values/time_zone.rb#523 def today; end # Returns the next date in this time zone. # - # source://activesupport//lib/active_support/values/time_zone.rb#517 + # source://activesupport//lib/active_support/values/time_zone.rb#528 def tomorrow; end # Returns the value of attribute tzinfo. # - # source://activesupport//lib/active_support/values/time_zone.rb#295 + # source://activesupport//lib/active_support/values/time_zone.rb#299 def tzinfo; end # Returns the offset of this time zone from UTC in seconds. # - # source://activesupport//lib/active_support/values/time_zone.rb#308 + # source://activesupport//lib/active_support/values/time_zone.rb#319 def utc_offset; end # Adjust the given time to the simultaneous time in the time zone @@ -12604,22 +14625,22 @@ class ActiveSupport::TimeZone # As of tzinfo 2, utc_to_local returns a Time with a non-zero utc_offset. # See the +utc_to_local_returns_utc_offset_times+ config for more info. # - # source://activesupport//lib/active_support/values/time_zone.rb#533 + # source://activesupport//lib/active_support/values/time_zone.rb#544 def utc_to_local(time); end # Returns the previous date in this time zone. # - # source://activesupport//lib/active_support/values/time_zone.rb#522 + # source://activesupport//lib/active_support/values/time_zone.rb#533 def yesterday; end private # @raise [ArgumentError] # - # source://activesupport//lib/active_support/values/time_zone.rb#572 + # source://activesupport//lib/active_support/values/time_zone.rb#583 def parts_to_time(parts, now); end - # source://activesupport//lib/active_support/values/time_zone.rb#597 + # source://activesupport//lib/active_support/values/time_zone.rb#608 def time_now; end class << self @@ -12629,35 +14650,36 @@ class ActiveSupport::TimeZone # timezone to find. (The first one with that offset will be returned.) # Returns +nil+ if no such time zone is known to the system. # - # source://activesupport//lib/active_support/values/time_zone.rb#230 + # source://activesupport//lib/active_support/values/time_zone.rb#234 def [](arg); end # Returns an array of all TimeZone objects. There are multiple # TimeZone objects per time zone, in many cases, to make it easier # for users to find their own time zone. # - # source://activesupport//lib/active_support/values/time_zone.rb#221 + # source://activesupport//lib/active_support/values/time_zone.rb#225 def all; end - # source://activesupport//lib/active_support/values/time_zone.rb#263 + # source://activesupport//lib/active_support/values/time_zone.rb#267 def clear; end # A convenience method for returning a collection of TimeZone objects # for time zones in the country specified by its ISO 3166-1 Alpha2 code. # - # source://activesupport//lib/active_support/values/time_zone.rb#258 + # source://activesupport//lib/active_support/values/time_zone.rb#262 def country_zones(country_code); end + # :stopdoc: def create(*_arg0); end - # source://activesupport//lib/active_support/values/time_zone.rb#205 + # source://activesupport//lib/active_support/values/time_zone.rb#207 def find_tzinfo(name); end # Returns a TimeZone instance with the given name, or +nil+ if no # such TimeZone instance exists. (This exists to support the use of # this class with the +composed_of+ macro.) # - # source://activesupport//lib/active_support/values/time_zone.rb#214 + # source://activesupport//lib/active_support/values/time_zone.rb#218 def new(name); end # Assumes self represents an offset from UTC in seconds (as returned from @@ -12665,34 +14687,34 @@ class ActiveSupport::TimeZone # # ActiveSupport::TimeZone.seconds_to_utc_offset(-21_600) # => "-06:00" # - # source://activesupport//lib/active_support/values/time_zone.rb#197 + # source://activesupport//lib/active_support/values/time_zone.rb#199 def seconds_to_utc_offset(seconds, colon = T.unsafe(nil)); end # A convenience method for returning a collection of TimeZone objects # for time zones in the USA. # - # source://activesupport//lib/active_support/values/time_zone.rb#252 + # source://activesupport//lib/active_support/values/time_zone.rb#256 def us_zones; end private - # source://activesupport//lib/active_support/values/time_zone.rb#271 + # source://activesupport//lib/active_support/values/time_zone.rb#275 def load_country_zones(code); end - # source://activesupport//lib/active_support/values/time_zone.rb#285 + # source://activesupport//lib/active_support/values/time_zone.rb#289 def zones_map; end end end -# Keys are Rails TimeZone names, values are TZInfo identifiers. +# Keys are \Rails TimeZone names, values are TZInfo identifiers. # -# source://activesupport//lib/active_support/values/time_zone.rb#31 +# source://activesupport//lib/active_support/values/time_zone.rb#33 ActiveSupport::TimeZone::MAPPING = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/values/time_zone.rb#186 +# source://activesupport//lib/active_support/values/time_zone.rb#188 ActiveSupport::TimeZone::UTC_OFFSET_WITHOUT_COLON = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/values/time_zone.rb#185 +# source://activesupport//lib/active_support/values/time_zone.rb#187 ActiveSupport::TimeZone::UTC_OFFSET_WITH_COLON = T.let(T.unsafe(nil), String) # source://activesupport//lib/active_support/core_ext/object/json.rb#35 @@ -12800,73 +14822,74 @@ class ActiveSupport::XMLConverter::DisallowedType < ::StandardError def initialize(type); end end -# = XmlMini +# = \XmlMini # # To use the much faster libxml parser: -# gem 'libxml-ruby', '=0.9.7' +# gem "libxml-ruby" # XmlMini.backend = 'LibXML' # # source://activesupport//lib/active_support/xml_mini.rb#17 module ActiveSupport::XmlMini extend ::ActiveSupport::XmlMini - # source://activesupport//lib/active_support/xml_mini.rb#97 + # source://activesupport//lib/active_support/xml_mini.rb#101 def backend; end - # source://activesupport//lib/active_support/xml_mini.rb#101 + # source://activesupport//lib/active_support/xml_mini.rb#105 def backend=(name); end # Returns the value of attribute depth. # - # source://activesupport//lib/active_support/xml_mini.rb#92 + # source://activesupport//lib/active_support/xml_mini.rb#96 def depth; end # Sets the attribute depth # # @param value the value to set the attribute depth to. # - # source://activesupport//lib/active_support/xml_mini.rb#92 + # source://activesupport//lib/active_support/xml_mini.rb#96 def depth=(_arg0); end - # source://activesupport//lib/active_support/xml_mini.rb#95 + # source://activesupport//lib/active_support/xml_mini.rb#99 def parse(*_arg0, **_arg1, &_arg2); end - # source://activesupport//lib/active_support/xml_mini.rb#148 + # source://activesupport//lib/active_support/xml_mini.rb#152 def rename_key(key, options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/xml_mini.rb#115 + # source://activesupport//lib/active_support/xml_mini.rb#119 def to_tag(key, value, options); end - # source://activesupport//lib/active_support/xml_mini.rb#107 + # source://activesupport//lib/active_support/xml_mini.rb#111 def with_backend(name); end private - # source://activesupport//lib/active_support/xml_mini.rb#159 + # source://activesupport//lib/active_support/xml_mini.rb#163 def _dasherize(key); end - # TODO: Add support for other encodings - # - # source://activesupport//lib/active_support/xml_mini.rb#166 + # source://activesupport//lib/active_support/xml_mini.rb#169 def _parse_binary(bin, entity); end - # source://activesupport//lib/active_support/xml_mini.rb#175 + # source://activesupport//lib/active_support/xml_mini.rb#180 def _parse_file(file, entity); end - # source://activesupport//lib/active_support/xml_mini.rb#191 + # source://activesupport//lib/active_support/xml_mini.rb#188 + def _parse_hex_binary(bin); end + + # source://activesupport//lib/active_support/xml_mini.rb#200 def cast_backend_name_to_module(name); end - # source://activesupport//lib/active_support/xml_mini.rb#183 + # source://activesupport//lib/active_support/xml_mini.rb#192 def current_thread_backend; end - # source://activesupport//lib/active_support/xml_mini.rb#187 + # source://activesupport//lib/active_support/xml_mini.rb#196 def current_thread_backend=(name); end end # source://activesupport//lib/active_support/xml_mini.rb#34 ActiveSupport::XmlMini::DEFAULT_ENCODINGS = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/xml_mini.rb#55 +# source://activesupport//lib/active_support/xml_mini.rb#56 ActiveSupport::XmlMini::FORMATTING = T.let(T.unsafe(nil), Hash) # This module decorates files deserialized using Hash.from_xml with @@ -12887,7 +14910,7 @@ module ActiveSupport::XmlMini::FileLike def original_filename=(_arg0); end end -# source://activesupport//lib/active_support/xml_mini.rb#65 +# source://activesupport//lib/active_support/xml_mini.rb#67 ActiveSupport::XmlMini::PARSING = T.let(T.unsafe(nil), Hash) # source://activesupport//lib/active_support/xml_mini.rb#39 @@ -12981,11 +15004,11 @@ end # source://activesupport//lib/active_support/xml_mini/rexml.rb#11 ActiveSupport::XmlMini_REXML::CONTENT_KEY = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/core_ext/object/blank.rb#83 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#95 class Array include ::Enumerable - # source://activesupport//lib/active_support/core_ext/object/json.rb#158 + # source://activesupport//lib/active_support/core_ext/object/json.rb#166 def as_json(options = T.unsafe(nil)); end # Removes all blank elements from the +Array+ in place and returns self. @@ -12995,9 +15018,21 @@ class Array # a.compact_blank! # # => [1, 2, true] # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#325 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#258 def compact_blank!; end + # Returns a deep copy of array. + # + # array = [1, [2, 3]] + # dup = array.deep_dup + # dup[1][2] = 4 + # + # array[1][2] # => nil + # dup[1][2] # => 4 + # + # source://activesupport//lib/active_support/core_ext/object/deep_dup.rb#29 + def deep_dup; end + # Returns a copy of the Array excluding the specified elements. # # ["David", "Rafael", "Aaron", "Todd"].excluding("Aaron", "Todd") # => ["David", "Rafael"] @@ -13130,6 +15165,11 @@ class Array # source://activesupport//lib/active_support/core_ext/array/inquiry.rb#16 def inquiry; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#104 + def present?; end + # Equal to self[1]. # # %w( a b c d e ).second # => "b" @@ -13153,9 +15193,6 @@ class Array # source://activesupport//lib/active_support/core_ext/array/grouping.rb#93 def split(value = T.unsafe(nil), &block); end - # source://activesupport//lib/active_support/core_ext/enumerable.rb#310 - def sum(init = T.unsafe(nil), &block); end - # Equal to self[2]. # # %w( a b c d e ).third # => "c" @@ -13220,9 +15257,6 @@ class Array # source://activesupport//lib/active_support/core_ext/object/to_query.rb#50 def to_query(key); end - # source://activesupport//lib/active_support/core_ext/array/deprecated_conversions.rb#5 - def to_s(format = T.unsafe(nil)); end - # Converts the array to a comma-separated sentence where the last element is # joined by the connector word. # @@ -13353,7 +15387,7 @@ class Array # # # - # source://activesupport//lib/active_support/core_ext/array/conversions.rb#184 + # source://activesupport//lib/active_support/core_ext/array/conversions.rb#183 def to_xml(options = T.unsafe(nil)); end # Returns a copy of the Array excluding the specified elements. @@ -13409,14 +15443,10 @@ class Array end end -# source://activesupport//lib/active_support/core_ext/array/deprecated_conversions.rb#4 -Array::NOT_SET = T.let(T.unsafe(nil), Object) - -# source://activesupport//lib/active_support/core_ext/object/json.rb#118 +# source://activesupport//lib/active_support/core_ext/object/json.rb#126 class BigDecimal < ::Numeric include ::ActiveSupport::BigDecimalWithDefaultFormat include ::ActiveSupport::NumericWithFormat - include ::ActiveSupport::DeprecatedNumericWithFormat # A BigDecimal would be naturally represented as a JSON number. Most libraries, # however, parse non-integer JSON numbers directly as floats. Clients using @@ -13428,18 +15458,17 @@ class BigDecimal < ::Numeric # BigDecimal, it still has the chance to post-process the string and get the # real value. # - # source://activesupport//lib/active_support/core_ext/object/json.rb#128 + # source://activesupport//lib/active_support/core_ext/object/json.rb#136 def as_json(options = T.unsafe(nil)); end - # source://activesupport//lib/active_support/core_ext/numeric/deprecated_conversions.rb#5 - def to_s(format = T.unsafe(nil), options = T.unsafe(nil)); end + # source://activesupport//lib/active_support/core_ext/big_decimal/conversions.rb#8 + def to_s(format = T.unsafe(nil)); end end -BigDecimal::EXCEPTION_NaN = T.let(T.unsafe(nil), Integer) -BigDecimal::VERSION = T.let(T.unsafe(nil), String) - # source://activesupport//lib/active_support/core_ext/class/attribute.rb#5 class Class < ::Module + include ::ActiveSupport::DescendantsTracker::ReloadedClassesFiltering + # Declare a class-level attribute whose value is inheritable by subclasses. # Subclasses can change their own value and it will not impact parent class. # @@ -13537,8 +15566,17 @@ class Class < ::Module # class D < C; end # C.descendants # => [B, A, D] # - # source://activesupport//lib/active_support/core_ext/class/subclasses.rb#20 + # source://activesupport//lib/active_support/descendants_tracker.rb#63 def descendants; end + + # source://activesupport//lib/active_support/descendants_tracker.rb#59 + def subclasses; end +end + +# source://activesupport//lib/active_support/core_ext/object/json.rb#69 +class Data + # source://activesupport//lib/active_support/core_ext/object/json.rb#70 + def as_json(options = T.unsafe(nil)); end end # source://activesupport//lib/active_support/core_ext/date/zones.rb#6 @@ -13591,7 +15629,7 @@ class Date # source://activesupport//lib/active_support/core_ext/date/calculations.rb#55 def ago(seconds); end - # source://activesupport//lib/active_support/core_ext/object/json.rb#197 + # source://activesupport//lib/active_support/core_ext/object/json.rb#205 def as_json(options = T.unsafe(nil)); end # Converts Date to a Time (or DateTime if necessary) with the time portion set to the beginning of the day (0:00) @@ -13665,7 +15703,7 @@ class Date # Overrides the default inspect method with a human readable one, e.g., "Mon, 21 Feb 2005" # - # source://activesupport//lib/active_support/core_ext/date/conversions.rb#62 + # source://activesupport//lib/active_support/core_ext/date/conversions.rb#61 def inspect; end # Converts Date to a Time (or DateTime if necessary) with the time portion set to the middle of the day (12:00) @@ -13694,9 +15732,14 @@ class Date # source://activesupport//lib/active_support/core_ext/date/calculations.rb#90 def plus_with_duration(other); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/date/blank.rb#15 + def present?; end + # Overrides the default inspect method with a human readable one, e.g., "Mon, 21 Feb 2005" # - # source://activesupport//lib/active_support/core_ext/date/conversions.rb#62 + # source://activesupport//lib/active_support/core_ext/date/conversions.rb#61 def readable_inspect; end # Converts Date to a Time (or DateTime if necessary) with the time portion set to the beginning of the day (0:00) @@ -13761,9 +15804,6 @@ class Date # source://activesupport//lib/active_support/core_ext/date/conversions.rb#47 def to_fs(format = T.unsafe(nil)); end - # source://activesupport//lib/active_support/core_ext/date/deprecated_conversions.rb#7 - def to_s(format = T.unsafe(nil)); end - # Converts a Date instance to a Time, where the time is set to the beginning of the day. # The timezone can be either +:local+ or +:utc+ (default +:local+). # @@ -13779,7 +15819,7 @@ class Date # # @raise [ArgumentError] # - # source://activesupport//lib/active_support/core_ext/date/conversions.rb#82 + # source://activesupport//lib/active_support/core_ext/date/conversions.rb#81 def to_time(form = T.unsafe(nil)); end # Returns a string which represents the time in used time zone as DateTime @@ -13788,7 +15828,7 @@ class Date # date = Date.new(2015, 05, 23) # => Sat, 23 May 2015 # date.xmlschema # => "2015-05-23T00:00:00+04:00" # - # source://activesupport//lib/active_support/core_ext/date/conversions.rb#94 + # source://activesupport//lib/active_support/core_ext/date/conversions.rb#93 def xmlschema; end class << self @@ -13846,13 +15886,7 @@ end # source://activesupport//lib/active_support/core_ext/date/conversions.rb#9 Date::DATE_FORMATS = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/core_ext/date/deprecated_conversions.rb#6 -Date::NOT_SET = T.let(T.unsafe(nil), Object) - -# source://date/3.3.3/date.rb#7 -Date::VERSION = T.let(T.unsafe(nil), String) - -# source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#5 +# source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#6 module DateAndTime; end # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#7 @@ -13866,28 +15900,28 @@ module DateAndTime::Calculations # Returns a Range representing the whole day of the current date/time. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#300 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#310 def all_day; end # Returns a Range representing the whole month of the current date/time. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#311 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#321 def all_month; end # Returns a Range representing the whole quarter of the current date/time. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#316 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#326 def all_quarter; end # Returns a Range representing the whole week of the current date/time. # Week starts on start_day, default is Date.beginning_of_week or config.beginning_of_week when set. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#306 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#316 def all_week(start_day = T.unsafe(nil)); end # Returns a Range representing the whole year of the current date/time. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#321 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#331 def all_year; end # Returns a new date/time at the start of the month. @@ -13921,7 +15955,7 @@ module DateAndTime::Calculations # +Date.beginning_of_week+ or +config.beginning_of_week+ when set. # +DateTime+ objects have their time set to 0:00. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#257 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#267 def at_beginning_of_week(start_day = T.unsafe(nil)); end # Returns a new date/time at the beginning of the year. @@ -13934,13 +15968,13 @@ module DateAndTime::Calculations # now = DateTime.current # => Fri, 10 Jul 2015 18:41:29 +0000 # now.beginning_of_year # => Thu, 01 Jan 2015 00:00:00 +0000 # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#169 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#179 def at_beginning_of_year; end # Returns a new date/time representing the end of the month. # DateTime objects will have a time set to 23:59:59. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#286 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#296 def at_end_of_month; end # Returns a new date/time at the end of the quarter. @@ -13961,13 +15995,13 @@ module DateAndTime::Calculations # +Date.beginning_of_week+ or +config.beginning_of_week+ when set. # DateTime objects have their time set to 23:59:59. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#273 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#283 def at_end_of_week(start_day = T.unsafe(nil)); end # Returns a new date/time representing the end of the year. # DateTime objects will have a time set to 23:59:59. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#294 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#304 def at_end_of_year; end # Returns true if the date/time falls before date_or_time. @@ -14008,7 +16042,7 @@ module DateAndTime::Calculations # +Date.beginning_of_week+ or +config.beginning_of_week+ when set. # +DateTime+ objects have their time set to 0:00. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#257 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#267 def beginning_of_week(start_day = T.unsafe(nil)); end # Returns a new date/time at the beginning of the year. @@ -14021,7 +16055,7 @@ module DateAndTime::Calculations # now = DateTime.current # => Fri, 10 Jul 2015 18:41:29 +0000 # now.beginning_of_year # => Thu, 01 Jan 2015 00:00:00 +0000 # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#169 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#179 def beginning_of_year; end # Returns a new date/time the specified number of days ago. @@ -14038,13 +16072,13 @@ module DateAndTime::Calculations # Week is assumed to start on +start_day+, default is # +Date.beginning_of_week+ or +config.beginning_of_week+ when set. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#248 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#258 def days_to_week_start(start_day = T.unsafe(nil)); end # Returns a new date/time representing the end of the month. # DateTime objects will have a time set to 23:59:59. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#286 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#296 def end_of_month; end # Returns a new date/time at the end of the quarter. @@ -14065,13 +16099,13 @@ module DateAndTime::Calculations # +Date.beginning_of_week+ or +config.beginning_of_week+ when set. # DateTime objects have their time set to 23:59:59. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#273 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#283 def end_of_week(start_day = T.unsafe(nil)); end # Returns a new date/time representing the end of the year. # DateTime objects will have a time set to 23:59:59. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#294 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#304 def end_of_year; end # Returns true if the date/time is in the future. @@ -14083,12 +16117,12 @@ module DateAndTime::Calculations # Short-hand for months_ago(1). # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#230 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#240 def last_month; end # Short-hand for months_ago(3). # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#235 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#245 def last_quarter; end # Returns a new date/time representing the given day in the previous week. @@ -14096,23 +16130,23 @@ module DateAndTime::Calculations # +Date.beginning_of_week+ or +config.beginning_of_week+ when set. # DateTime objects have their time set to 0:00 unless +same_time+ is true. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#213 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#223 def last_week(start_day = T.unsafe(nil), same_time: T.unsafe(nil)); end # Returns a new date/time representing the previous weekday. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#220 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#230 def last_weekday; end # Short-hand for years_ago(1). # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#241 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#251 def last_year; end # Returns Monday of this week assuming that week starts on Monday. # +DateTime+ objects have their time set to 0:00. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#265 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#275 def monday; end # Returns a new date/time the specified number of months ago. @@ -14138,12 +16172,12 @@ module DateAndTime::Calculations # today.next_occurring(:monday) # => Mon, 18 Dec 2017 # today.next_occurring(:thursday) # => Thu, 21 Dec 2017 # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#330 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#340 def next_occurring(day_of_week); end # Short-hand for months_since(3). # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#205 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#215 def next_quarter; end # Returns a new date/time representing the given day in the next week. @@ -14163,12 +16197,12 @@ module DateAndTime::Calculations # now = DateTime.current # => Thu, 07 May 2015 13:31:16 +0000 # now.next_week # => Mon, 11 May 2015 00:00:00 +0000 # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#190 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#200 def next_week(given_day_in_next_week = T.unsafe(nil), same_time: T.unsafe(nil)); end # Returns a new date/time representing the next weekday. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#196 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#206 def next_weekday; end # Returns true if the date/time does not fall on a Saturday or Sunday. @@ -14205,12 +16239,12 @@ module DateAndTime::Calculations # today.prev_occurring(:monday) # => Mon, 11 Dec 2017 # today.prev_occurring(:thursday) # => Thu, 07 Dec 2017 # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#341 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#351 def prev_occurring(day_of_week); end # Short-hand for months_ago(3). # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#235 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#245 def prev_quarter; end # Returns a new date/time representing the given day in the previous week. @@ -14218,18 +16252,28 @@ module DateAndTime::Calculations # +Date.beginning_of_week+ or +config.beginning_of_week+ when set. # DateTime objects have their time set to 0:00 unless +same_time+ is true. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#213 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#223 def prev_week(start_day = T.unsafe(nil), same_time: T.unsafe(nil)); end # Returns a new date/time representing the previous weekday. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#220 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#230 def prev_weekday; end + # Returns the quarter for a date/time. + # + # Date.new(2010, 1, 31).quarter # => 1 + # Date.new(2010, 4, 12).quarter # => 2 + # Date.new(2010, 9, 15).quarter # => 3 + # Date.new(2010, 12, 25).quarter # => 4 + # + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#166 + def quarter; end + # Returns Sunday of this week assuming that week starts on Monday. # +DateTime+ objects have their time set to 23:59:59. # - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#280 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#290 def sunday; end # Returns true if the date/time is today. @@ -14285,16 +16329,16 @@ module DateAndTime::Calculations private - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#360 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#370 def copy_time_to(other); end - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#356 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#366 def days_span(day); end - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#348 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#358 def first_hour(date_or_time); end - # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#352 + # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#362 def last_hour(date_or_time); end end @@ -14304,25 +16348,31 @@ DateAndTime::Calculations::DAYS_INTO_WEEK = T.let(T.unsafe(nil), Hash) # source://activesupport//lib/active_support/core_ext/date_and_time/calculations.rb#17 DateAndTime::Calculations::WEEKEND_DAYS = T.let(T.unsafe(nil), Array) -# source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#6 +# source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#7 module DateAndTime::Compatibility - # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#14 + # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#39 def preserve_timezone; end - # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#29 + # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#56 def utc_to_local_returns_utc_offset_times; end class << self - # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#14 + # -- + # This re-implements the behaviour of the mattr_reader, instead + # of prepending on to it, to avoid overcomplicating a module that + # is in turn included in several places. This will all go away in + # Rails 8.0 anyway. + # + # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#24 def preserve_timezone; end - # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#14 + # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#15 def preserve_timezone=(val); end - # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#29 + # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#56 def utc_to_local_returns_utc_offset_times; end - # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#29 + # source://activesupport//lib/active_support/core_ext/date_and_time/compatibility.rb#56 def utc_to_local_returns_utc_offset_times=(val); end end end @@ -14396,7 +16446,7 @@ class DateTime < ::Date # source://activesupport//lib/active_support/core_ext/date_time/calculations.rb#109 def ago(seconds); end - # source://activesupport//lib/active_support/core_ext/object/json.rb#207 + # source://activesupport//lib/active_support/core_ext/object/json.rb#215 def as_json(options = T.unsafe(nil)); end # Returns a new DateTime representing the start of the day (0:00). @@ -14586,6 +16636,11 @@ class DateTime < ::Date # source://activesupport//lib/active_support/core_ext/date_time/conversions.rb#94 def nsec; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/date_time/blank.rb#15 + def present?; end + # Overrides the default inspect method with a human readable one, e.g., "Mon, 21 Feb 2005 14:30:00 +0000". # # source://activesupport//lib/active_support/core_ext/date_time/conversions.rb#56 @@ -14691,9 +16746,6 @@ class DateTime < ::Date # source://activesupport//lib/active_support/core_ext/date_time/conversions.rb#84 def to_i; end - # source://activesupport//lib/active_support/core_ext/date_time/deprecated_conversions.rb#7 - def to_s(format = T.unsafe(nil)); end - # Either return an instance of +Time+ with the same UTC offset # as +self+ or an instance of +Time+ representing the same time # in the local system timezone depending on the setting of @@ -14756,9 +16808,6 @@ class DateTime < ::Date end end -# source://activesupport//lib/active_support/core_ext/date_time/deprecated_conversions.rb#6 -DateTime::NOT_SET = T.let(T.unsafe(nil), Object) - # source://activesupport//lib/active_support/core_ext/object/try.rb#117 class Delegator < ::BasicObject include ::ActiveSupport::Tryable @@ -14767,11 +16816,11 @@ end # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#7 module Digest::UUID class << self - # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#13 - def use_rfc4122_namespaced_uuids; end - - # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#13 - def use_rfc4122_namespaced_uuids=(val); end + # Returns the nil UUID. This is a special form of UUID that is specified to + # have all 128 bits set to zero. + # + # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#58 + def nil_uuid; end # Generates a v5 non-random UUID (Universally Unique IDentifier). # @@ -14780,27 +16829,27 @@ module Digest::UUID # # See RFC 4122 for details of UUID at: https://www.ietf.org/rfc/rfc4122.txt # - # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#21 + # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#19 def uuid_from_hash(hash_class, namespace, name); end # Convenience method for uuid_from_hash using OpenSSL::Digest::MD5. # - # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#44 + # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#42 def uuid_v3(uuid_namespace, name); end # Convenience method for SecureRandom.uuid. # - # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#54 + # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#52 def uuid_v4; end # Convenience method for uuid_from_hash using OpenSSL::Digest::SHA1. # - # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#49 + # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#47 def uuid_v5(uuid_namespace, name); end private - # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#58 + # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#62 def pack_uuid_namespace(namespace); end end end @@ -14817,27 +16866,13 @@ Digest::UUID::URL_NAMESPACE = T.let(T.unsafe(nil), String) # source://activesupport//lib/active_support/core_ext/digest/uuid.rb#11 Digest::UUID::X500_NAMESPACE = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#8 +# source://activesupport//lib/active_support/core_ext/erb/util.rb#39 module ERB::Util - private - - # A utility method for escaping HTML tag characters. - # This method is also aliased as h. - # - # puts html_escape('is a > 0 & a < 10?') - # # => is a > 0 & a < 10? - # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#27 - def h(s); end + include ::ActiveSupport::CoreExt::ERBUtil + include ::ActiveSupport::CoreExt::ERBUtilPrivate + extend ::ActiveSupport::CoreExt::ERBUtil - # A utility method for escaping HTML tag characters. - # This method is also aliased as h. - # - # puts html_escape('is a > 0 & a < 10?') - # # => is a > 0 & a < 10? - # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#27 - def html_escape(s); end + private # A utility method for escaping HTML without affecting existing escaped entities. # @@ -14847,7 +16882,7 @@ module ERB::Util # html_escape_once('<< Accept & Checkout') # # => "<< Accept & Checkout" # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#58 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#63 def html_escape_once(s); end # A utility method for escaping HTML entities in JSON strings. Specifically, the @@ -14906,15 +16941,9 @@ module ERB::Util # JSON gem, do not provide this kind of protection by default; also some gems # might override +to_json+ to bypass Active Support's encoder). # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#120 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#124 def json_escape(s); end - # HTML escapes strings but doesn't wrap them with an ActiveSupport::SafeBuffer. - # This method is not for public consumption! Seriously! - # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#41 - def unwrapped_html_escape(s); end - # A utility method for escaping XML names of tags and names of attributes. # # xml_name_escape('1 < 2 & 3') @@ -14922,26 +16951,14 @@ module ERB::Util # # It follows the requirements of the specification: https://www.w3.org/TR/REC-xml/#NT-Name # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#133 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#142 def xml_name_escape(name); end class << self - # A utility method for escaping HTML tag characters. - # This method is also aliased as h. - # - # puts html_escape('is a > 0 & a < 10?') - # # => is a > 0 & a < 10? - # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#27 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#25 def h(s); end - # A utility method for escaping HTML tag characters. - # This method is also aliased as h. - # - # puts html_escape('is a > 0 & a < 10?') - # # => is a > 0 & a < 10? - # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#27 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#25 def html_escape(s); end # A utility method for escaping HTML without affecting existing escaped entities. @@ -14952,7 +16969,7 @@ module ERB::Util # html_escape_once('<< Accept & Checkout') # # => "<< Accept & Checkout" # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#58 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#63 def html_escape_once(s); end # A utility method for escaping HTML entities in JSON strings. Specifically, the @@ -15011,13 +17028,16 @@ module ERB::Util # JSON gem, do not provide this kind of protection by default; also some gems # might override +to_json+ to bypass Active Support's encoder). # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#120 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#124 def json_escape(s); end - # HTML escapes strings but doesn't wrap them with an ActiveSupport::SafeBuffer. - # This method is not for public consumption! Seriously! + # Tokenizes a line of ERB. This is really just for error reporting and + # nobody should use it. # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#41 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#161 + def tokenize(source); end + + # source://activesupport//lib/active_support/core_ext/erb/util.rb#10 def unwrapped_html_escape(s); end # A utility method for escaping XML names of tags and names of attributes. @@ -15027,42 +17047,43 @@ module ERB::Util # # It follows the requirements of the specification: https://www.w3.org/TR/REC-xml/#NT-Name # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#133 + # source://activesupport//lib/active_support/core_ext/erb/util.rb#142 def xml_name_escape(name); end end end -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#9 +# source://activesupport//lib/active_support/core_ext/erb/util.rb#40 ERB::Util::HTML_ESCAPE = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#11 +# source://activesupport//lib/active_support/core_ext/erb/util.rb#41 ERB::Util::HTML_ESCAPE_ONCE_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#10 -ERB::Util::JSON_ESCAPE = T.let(T.unsafe(nil), Hash) +# source://activesupport//lib/active_support/core_ext/erb/util.rb#49 +ERB::Util::INVALID_TAG_NAME_FOLLOWING_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#12 -ERB::Util::JSON_ESCAPE_REGEXP = T.let(T.unsafe(nil), Regexp) +# source://activesupport//lib/active_support/core_ext/erb/util.rb#47 +ERB::Util::INVALID_TAG_NAME_START_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#19 -ERB::Util::TAG_NAME_FOLLOWING_REGEXP = T.let(T.unsafe(nil), Regexp) +# source://activesupport//lib/active_support/core_ext/erb/util.rb#50 +ERB::Util::SAFE_XML_TAG_NAME_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#20 -ERB::Util::TAG_NAME_REPLACEMENT_CHAR = T.let(T.unsafe(nil), String) +# source://activesupport//lib/active_support/core_ext/erb/util.rb#48 +ERB::Util::TAG_NAME_FOLLOWING_CODEPOINTS = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#18 -ERB::Util::TAG_NAME_START_REGEXP = T.let(T.unsafe(nil), Regexp) +# source://activesupport//lib/active_support/core_ext/erb/util.rb#51 +ERB::Util::TAG_NAME_REPLACEMENT_CHAR = T.let(T.unsafe(nil), String) # Following XML requirements: https://www.w3.org/TR/REC-xml/#NT-Name # -# source://activesupport//lib/active_support/core_ext/string/output_safety.rb#15 -ERB::Util::TAG_NAME_START_REGEXP_SET = T.let(T.unsafe(nil), String) +# source://activesupport//lib/active_support/core_ext/erb/util.rb#44 +ERB::Util::TAG_NAME_START_CODEPOINTS = T.let(T.unsafe(nil), String) -# source://activesupport//lib/active_support/core_ext/object/json.rb#139 +# source://activesupport//lib/active_support/core_ext/enumerable.rb#18 module Enumerable + include ::ActiveSupport::ToJsonWithActiveSupportEncoder extend ::ActiveSupport::EnumerableCoreExt::Constants - # source://activesupport//lib/active_support/core_ext/object/json.rb#140 + # source://activesupport//lib/active_support/core_ext/object/json.rb#148 def as_json(options = T.unsafe(nil)); end # Returns a new +Array+ without the blank items. @@ -15079,7 +17100,7 @@ module Enumerable # { a: "", b: 1, c: nil, d: [], e: false, f: true }.compact_blank # # => { b: 1, f: true } # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#235 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#184 def compact_blank; end # The negative of the Enumerable#include?. Returns +true+ if the @@ -15087,7 +17108,7 @@ module Enumerable # # @return [Boolean] # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#169 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#118 def exclude?(object); end # Returns a copy of the enumerable excluding the specified elements. @@ -15101,7 +17122,7 @@ module Enumerable # {foo: 1, bar: 2, baz: 3}.excluding :bar # # => {foo: 1, baz: 3} # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#183 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#132 def excluding(*elements); end # Returns a new +Array+ where the order has been set to that provided in the +series+, based on the +key+ of the @@ -15113,7 +17134,7 @@ module Enumerable # If the +series+ include keys that have no corresponding element in the Enumerable, these are ignored. # If the Enumerable has additional elements that aren't named in the +series+, these are not included in the result. # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#247 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#196 def in_order_of(key, series); end # Returns a new array that includes the passed elements. @@ -15124,7 +17145,7 @@ module Enumerable # ["David", "Rafael"].including %w[ Aaron Todd ] # # => ["David", "Rafael", "Aaron", "Todd"] # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#163 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#112 def including(*elements); end # Convert an enumerable to a hash, using the block result as the key and the @@ -15136,7 +17157,7 @@ module Enumerable # people.index_by { |person| "#{person.first_name} #{person.last_name}" } # # => { "Chade- Fowlersburg-e" => , "David Heinemeier Hansson" => , ...} # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#103 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#52 def index_by; end # Convert an enumerable to a hash, using the element as the key and the block @@ -15153,7 +17174,7 @@ module Enumerable # %i( created_at updated_at ).index_with(Time.now) # # => { created_at: 2020-03-09 22:31:47, updated_at: 2020-03-09 22:31:47 } # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#126 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#75 def index_with(default = T.unsafe(nil)); end # Returns +true+ if the enumerable has more than 1 element. Functionally @@ -15163,7 +17184,7 @@ module Enumerable # # @return [Boolean] # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#144 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#93 def many?; end # Calculates the maximum from the extracted elements. @@ -15171,7 +17192,7 @@ module Enumerable # payments = [Payment.new(5), Payment.new(15), Payment.new(10)] # payments.maximum(:price) # => 15 # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#52 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#40 def maximum(key); end # Calculates the minimum from the extracted elements. @@ -15179,7 +17200,7 @@ module Enumerable # payments = [Payment.new(5), Payment.new(15), Payment.new(10)] # payments.minimum(:price) # => 5 # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#44 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#32 def minimum(key); end # Extract the given key from the first element in the enumerable. @@ -15190,7 +17211,7 @@ module Enumerable # [{ id: 1, name: "David" }, { id: 2, name: "Rafael" }].pick(:id, :name) # # => [1, "David"] # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#212 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#161 def pick(*keys); end # Extract the given key from each element in the enumerable. @@ -15201,7 +17222,7 @@ module Enumerable # [{ id: 1, name: "David" }, { id: 2, name: "Rafael" }].pluck(:id, :name) # # => [[1, "David"], [2, "Rafael"]] # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#196 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#145 def pluck(*keys); end # Returns the sole item in the enumerable. If there are no items, or more @@ -15211,31 +17232,9 @@ module Enumerable # Set.new.sole # => Enumerable::SoleItemExpectedError: no item found # { a: 1, b: 2 }.sole # => Enumerable::SoleItemExpectedError: multiple items found # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#257 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#206 def sole; end - # Calculates a sum from the elements. - # - # payments.sum { |p| p.price * p.tax_rate } - # payments.sum(&:price) - # - # The latter is a shortcut for: - # - # payments.inject(0) { |sum, p| sum + p.price } - # - # It can also calculate the sum without the use of a block. - # - # [5, 15, 10].sum # => 30 - # ['foo', 'bar'].sum('') # => "foobar" - # [[1, 2], [3, 1, 5]].sum([]) # => [1, 2, 3, 1, 5] - # - # The default sum of an empty list is zero. You can override this default: - # - # [].sum(Payment.new(0)) { |i| i.amount } # => Payment.new(0) - # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#74 - def sum(identity = T.unsafe(nil), &block); end - # Returns a copy of the enumerable excluding the specified elements. # # ["David", "Rafael", "Aaron", "Todd"].excluding "Aaron", "Todd" @@ -15247,7 +17246,7 @@ module Enumerable # {foo: 1, bar: 2, baz: 3}.excluding :bar # # => {foo: 1, baz: 3} # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#183 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#132 def without(*elements); end end @@ -15257,15 +17256,15 @@ end # source://activesupport//lib/active_support/core_ext/enumerable.rb#21 class Enumerable::SoleItemExpectedError < ::StandardError; end -# source://activesupport//lib/active_support/core_ext/object/json.rb#240 +# source://activesupport//lib/active_support/core_ext/object/json.rb#248 class Exception - # source://activesupport//lib/active_support/core_ext/object/json.rb#241 + # source://activesupport//lib/active_support/core_ext/object/json.rb#249 def as_json(options = T.unsafe(nil)); end end -# source://activesupport//lib/active_support/core_ext/object/blank.rb#61 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#65 class FalseClass - # source://activesupport//lib/active_support/core_ext/object/json.rb#81 + # source://activesupport//lib/active_support/core_ext/object/json.rb#89 def as_json(options = T.unsafe(nil)); end # +false+ is blank: @@ -15274,9 +17273,14 @@ class FalseClass # # @return [true] # - # source://activesupport//lib/active_support/core_ext/object/blank.rb#67 + # source://activesupport//lib/active_support/core_ext/object/blank.rb#71 def blank?; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#75 + def present?; end + # Returns +self+. # # source://activesupport//lib/active_support/core_ext/object/to_query.rb#34 @@ -15312,32 +17316,23 @@ class File < ::IO end end -# source://yard/0.9.34/lib/yard/core_ext/file.rb#5 -File::RELATIVE_PARENTDIR = T.let(T.unsafe(nil), String) - -# source://yard/0.9.34/lib/yard/core_ext/file.rb#6 -File::RELATIVE_SAMEDIR = T.let(T.unsafe(nil), String) - -# source://activesupport//lib/active_support/core_ext/object/json.rb#110 +# source://activesupport//lib/active_support/core_ext/object/json.rb#118 class Float < ::Numeric include ::ActiveSupport::NumericWithFormat - include ::ActiveSupport::DeprecatedNumericWithFormat # Encoding Infinity or NaN to JSON should return "null". The default returns # "Infinity" or "NaN" which are not valid JSON. # - # source://activesupport//lib/active_support/core_ext/object/json.rb#113 + # source://activesupport//lib/active_support/core_ext/object/json.rb#121 def as_json(options = T.unsafe(nil)); end - - # source://activesupport//lib/active_support/core_ext/numeric/deprecated_conversions.rb#5 - def to_s(format = T.unsafe(nil), options = T.unsafe(nil)); end end -# source://activesupport//lib/active_support/core_ext/hash/deep_merge.rb#3 +# source://activesupport//lib/active_support/core_ext/hash/deep_merge.rb#5 class Hash include ::Enumerable + include ::ActiveSupport::DeepMergeable - # source://activesupport//lib/active_support/core_ext/object/json.rb#164 + # source://activesupport//lib/active_support/core_ext/object/json.rb#172 def as_json(options = T.unsafe(nil)); end # Validates all keys in a hash match *valid_keys, raising @@ -15355,7 +17350,7 @@ class Hash # Hash#reject has its own definition, so this needs one too. # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#268 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#217 def compact_blank; end # Removes all blank values from the +Hash+ in place and returns self. @@ -15365,31 +17360,33 @@ class Hash # h.compact_blank! # # => { b: 1, f: true } # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#278 + # source://activesupport//lib/active_support/core_ext/enumerable.rb#227 def compact_blank!; end - # Returns a new hash with +self+ and +other_hash+ merged recursively. + # Returns a deep copy of hash. + # + # hash = { a: { b: 'b' } } + # dup = hash.deep_dup + # dup[:a][:c] = 'c' # - # h1 = { a: true, b: { c: [1, 2, 3] } } - # h2 = { a: false, b: { x: [3, 4, 5] } } + # hash[:a][:c] # => nil + # dup[:a][:c] # => "c" # - # h1.deep_merge(h2) # => { a: false, b: { c: [1, 2, 3], x: [3, 4, 5] } } + # source://activesupport//lib/active_support/core_ext/object/deep_dup.rb#43 + def deep_dup; end + + # :method: deep_merge! + # :call-seq: deep_merge!(other_hash, &block) # - # Like with Hash#merge in the standard library, a block can be provided - # to merge values: + # Same as #deep_merge, but modifies +self+. # - # h1 = { a: 100, b: 200, c: { c1: 100 } } - # h2 = { b: 250, c: { c1: 200 } } - # h1.deep_merge(h2) { |key, this_val, other_val| this_val + other_val } - # # => { a: 100, b: 450, c: { c1: 300 } } + # -- + # Implemented by ActiveSupport::DeepMergeable#deep_merge!. # - # source://activesupport//lib/active_support/core_ext/hash/deep_merge.rb#18 - def deep_merge(other_hash, &block); end - - # Same as +deep_merge+, but modifies +self+. + # @return [Boolean] # - # source://activesupport//lib/active_support/core_ext/hash/deep_merge.rb#23 - def deep_merge!(other_hash, &block); end + # source://activesupport//lib/active_support/core_ext/hash/deep_merge.rb#39 + def deep_merge?(other); end # Returns a new hash with all keys converted to strings. # This includes the keys from the root hash and from all @@ -15512,6 +17509,11 @@ class Hash # source://activesupport//lib/active_support/core_ext/hash/indifferent_access.rb#9 def nested_under_indifferent_access; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#118 + def present?; end + # Merges the caller into +other_hash+. For example, # # options = options.reverse_merge(size: 25, velocity: 10) @@ -15610,9 +17612,7 @@ class Hash # The string pairs "key=value" that conform the query string # are sorted lexicographically in ascending order. # - # This method is also aliased as +to_param+. - # - # source://activesupport//lib/active_support/core_ext/object/to_query.rb#77 + # source://activesupport//lib/active_support/core_ext/object/to_query.rb#75 def to_param(namespace = T.unsafe(nil)); end # Returns a string representation of the receiver suitable for use as a URL @@ -15629,9 +17629,7 @@ class Hash # The string pairs "key=value" that conform the query string # are sorted lexicographically in ascending order. # - # This method is also aliased as +to_param+. - # - # source://activesupport//lib/active_support/core_ext/object/to_query.rb#77 + # source://activesupport//lib/active_support/core_ext/object/to_query.rb#75 def to_query(namespace = T.unsafe(nil)); end # Returns a string containing an XML representation of its receiver: @@ -15693,7 +17691,7 @@ class Hash # # By default the root node is "hash", but that's configurable via the :root option. # - # The default XML builder is a fresh instance of Builder::XmlMarkup. You can + # The default XML builder is a fresh instance of +Builder::XmlMarkup+. You can # configure your own builder with the :builder option. The method also accepts # options like :dasherize and friends, they are forwarded to the builder. # @@ -15792,7 +17790,7 @@ end # :stopdoc: # -# source://activesupport//lib/active_support/hash_with_indifferent_access.rb#425 +# source://activesupport//lib/active_support/hash_with_indifferent_access.rb#441 HashWithIndifferentAccess = ActiveSupport::HashWithIndifferentAccess # :enddoc: @@ -15800,75 +17798,57 @@ HashWithIndifferentAccess = ActiveSupport::HashWithIndifferentAccess # source://activesupport//lib/active_support/i18n_railtie.rb#8 module I18n class << self - # source://i18n/1.14.1/lib/i18n/backend/cache.rb#64 + # source://i18n/1.14.5/lib/i18n/backend/cache.rb#64 def cache_key_digest; end - # source://i18n/1.14.1/lib/i18n/backend/cache.rb#68 + # source://i18n/1.14.5/lib/i18n/backend/cache.rb#68 def cache_key_digest=(key_digest); end - # source://i18n/1.14.1/lib/i18n/backend/cache.rb#56 + # source://i18n/1.14.5/lib/i18n/backend/cache.rb#56 def cache_namespace; end - # source://i18n/1.14.1/lib/i18n/backend/cache.rb#60 + # source://i18n/1.14.5/lib/i18n/backend/cache.rb#60 def cache_namespace=(namespace); end - # source://i18n/1.14.1/lib/i18n/backend/cache.rb#48 + # source://i18n/1.14.5/lib/i18n/backend/cache.rb#48 def cache_store; end - # source://i18n/1.14.1/lib/i18n/backend/cache.rb#52 + # source://i18n/1.14.5/lib/i18n/backend/cache.rb#52 def cache_store=(store); end - # source://i18n/1.14.1/lib/i18n/backend/fallbacks.rb#17 + # source://i18n/1.14.5/lib/i18n/backend/fallbacks.rb#17 def fallbacks; end - # source://i18n/1.14.1/lib/i18n/backend/fallbacks.rb#23 + # source://i18n/1.14.5/lib/i18n/backend/fallbacks.rb#23 def fallbacks=(fallbacks); end - # source://i18n/1.14.1/lib/i18n/interpolate/ruby.rb#23 + # source://i18n/1.14.5/lib/i18n/interpolate/ruby.rb#23 def interpolate(string, values); end - # source://i18n/1.14.1/lib/i18n/interpolate/ruby.rb#29 + # source://i18n/1.14.5/lib/i18n/interpolate/ruby.rb#29 def interpolate_hash(string, values); end - # source://i18n/1.14.1/lib/i18n.rb#37 + # source://i18n/1.14.5/lib/i18n.rb#37 def new_double_nested_cache; end - # source://i18n/1.14.1/lib/i18n/backend/cache.rb#72 + # source://i18n/1.14.5/lib/i18n/backend/cache.rb#72 def perform_caching?; end - # source://i18n/1.14.1/lib/i18n.rb#45 + # source://i18n/1.14.5/lib/i18n.rb#45 def reserve_key(key); end - # source://i18n/1.14.1/lib/i18n.rb#50 + # source://i18n/1.14.5/lib/i18n.rb#50 def reserved_keys_pattern; end end end -# source://i18n/1.14.1/lib/i18n/interpolate/ruby.rb#7 -I18n::DEFAULT_INTERPOLATION_PATTERNS = T.let(T.unsafe(nil), Array) - -# source://i18n/1.14.1/lib/i18n.rb#35 -I18n::EMPTY_HASH = T.let(T.unsafe(nil), Hash) - -# source://i18n/1.14.1/lib/i18n/interpolate/ruby.rb#12 -I18n::INTERPOLATION_PATTERN = T.let(T.unsafe(nil), Regexp) - -# source://i18n/1.14.1/lib/i18n/backend/key_value.rb#21 -I18n::JSON = ActiveSupport::JSON - -# source://i18n/1.14.1/lib/i18n.rb#19 -I18n::RESERVED_KEYS = T.let(T.unsafe(nil), Array) - # source://activesupport//lib/active_support/i18n_railtie.rb#9 class I18n::Railtie < ::Rails::Railtie class << self - # source://activesupport//lib/active_support/i18n_railtie.rb#78 - def forward_raise_on_missing_translations_config(app); end - - # source://activesupport//lib/active_support/i18n_railtie.rb#88 + # source://activesupport//lib/active_support/i18n_railtie.rb#95 def include_fallbacks_module; end - # source://activesupport//lib/active_support/i18n_railtie.rb#92 + # source://activesupport//lib/active_support/i18n_railtie.rb#99 def init_fallbacks(fallbacks); end # Setup i18n configuration. @@ -15876,23 +17856,23 @@ class I18n::Railtie < ::Rails::Railtie # source://activesupport//lib/active_support/i18n_railtie.rb#32 def initialize_i18n(app); end - # source://activesupport//lib/active_support/i18n_railtie.rb#108 + # source://activesupport//lib/active_support/i18n_railtie.rb#80 + def setup_raise_on_missing_translations_config(app); end + + # source://activesupport//lib/active_support/i18n_railtie.rb#115 def validate_fallbacks(fallbacks); end - # source://activesupport//lib/active_support/i18n_railtie.rb#119 + # source://activesupport//lib/active_support/i18n_railtie.rb#126 def watched_dirs_with_extensions(paths); end end end -# source://i18n/1.14.1/lib/i18n/version.rb#4 -I18n::VERSION = T.let(T.unsafe(nil), String) - -# source://activesupport//lib/active_support/core_ext/object/json.rb#145 +# source://activesupport//lib/active_support/core_ext/object/json.rb#153 class IO include ::Enumerable include ::File::Constants - # source://activesupport//lib/active_support/core_ext/object/json.rb#146 + # source://activesupport//lib/active_support/core_ext/object/json.rb#154 def as_json(options = T.unsafe(nil)); end end @@ -15915,7 +17895,7 @@ class IO::Buffer def get_string(*_arg0); end def get_value(_arg0, _arg1); end def get_values(_arg0, _arg1); end - def hexdump; end + def hexdump(*_arg0); end def inspect; end def internal?; end def locked; end @@ -15925,6 +17905,7 @@ class IO::Buffer def null?; end def or!(_arg0); end def pread(*_arg0); end + def private?; end def pwrite(*_arg0); end def read(*_arg0); end def readonly?; end @@ -15952,6 +17933,7 @@ class IO::Buffer def for(_arg0); end def map(*_arg0); end def size_of(_arg0); end + def string(_arg0); end end end @@ -16007,19 +17989,15 @@ IO::READABLE = T.let(T.unsafe(nil), Integer) class IO::TimeoutError < ::IOError; end IO::WRITABLE = T.let(T.unsafe(nil), Integer) -# source://activesupport//lib/active_support/core_ext/object/json.rb#228 +# source://activesupport//lib/active_support/core_ext/object/json.rb#236 class IPAddr - # source://activesupport//lib/active_support/core_ext/object/json.rb#229 + # source://activesupport//lib/active_support/core_ext/object/json.rb#237 def as_json(options = T.unsafe(nil)); end end -# source://ipaddr/1.2.5/ipaddr.rb#43 -IPAddr::VERSION = T.let(T.unsafe(nil), String) - # source://activesupport//lib/active_support/core_ext/integer/time.rb#6 class Integer < ::Numeric include ::ActiveSupport::NumericWithFormat - include ::ActiveSupport::DeprecatedNumericWithFormat # Returns a Duration instance matching the number of months provided. # @@ -16035,9 +18013,6 @@ class Integer < ::Numeric # source://activesupport//lib/active_support/core_ext/integer/time.rb#10 def months; end - # source://activesupport//lib/active_support/core_ext/numeric/deprecated_conversions.rb#5 - def to_s(format = T.unsafe(nil), options = T.unsafe(nil)); end - # Returns a Duration instance matching the number of years provided. # # 2.years # => 2 years @@ -16134,19 +18109,6 @@ module Kernel end end -# source://activesupport//lib/active_support/core_ext/load_error.rb#3 -class LoadError < ::ScriptError - include ::DidYouMean::Correctable - - # Returns true if the given path name (except perhaps for the ".rb" - # extension) is the missing file which caused the exception to be raised. - # - # @return [Boolean] - # - # source://activesupport//lib/active_support/core_ext/load_error.rb#6 - def is_missing?(location); end -end - # == Attribute Accessors per Thread # # Extends the module object with class/module and instance accessors for @@ -16295,6 +18257,7 @@ class Module # # module HairColors # mattr_accessor :hair_colors, default: [:brown, :black, :blonde, :red] + # mattr_accessor(:hair_styles) { [:long, :short] } # end # # class Person @@ -16302,8 +18265,9 @@ class Module # end # # Person.class_variable_get("@@hair_colors") # => [:brown, :black, :blonde, :red] + # Person.class_variable_get("@@hair_styles") # => [:long, :short] # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#202 + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#208 def cattr_accessor(*syms, instance_reader: T.unsafe(nil), instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil), &blk); end # Defines a class attribute and creates a class and instance reader methods. @@ -16343,6 +18307,7 @@ class Module # # module HairColors # mattr_reader :hair_colors, default: [:brown, :black, :blonde, :red] + # mattr_reader(:hair_styles) { [:long, :short] } # end # # class Person @@ -16350,10 +18315,11 @@ class Module # end # # Person.new.hair_colors # => [:brown, :black, :blonde, :red] + # Person.new.hair_styles # => [:long, :short] # # @raise [TypeError] # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#53 + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#55 def cattr_reader(*syms, instance_reader: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil), location: T.unsafe(nil)); end # Defines a class attribute and creates a class and instance writer methods to @@ -16391,6 +18357,7 @@ class Module # # module HairColors # mattr_writer :hair_colors, default: [:brown, :black, :blonde, :red] + # mattr_writer(:hair_styles) { [:long, :short] } # end # # class Person @@ -16398,19 +18365,30 @@ class Module # end # # Person.class_variable_get("@@hair_colors") # => [:brown, :black, :blonde, :red] + # Person.class_variable_get("@@hair_styles") # => [:long, :short] # # @raise [TypeError] # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#117 + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#121 def cattr_writer(*syms, instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil), location: T.unsafe(nil)); end + # Returns a copy of module or class if it's anonymous. If it's + # named, returns +self+. + # + # Object.deep_dup == Object # => true + # klass = Class.new + # klass.deep_dup == klass # => false + # + # source://activesupport//lib/active_support/core_ext/object/deep_dup.rb#64 + def deep_dup; end + # Provides a +delegate+ class method to easily expose contained objects' # public methods as your own. # # ==== Options # * :to - Specifies the target object name as a symbol or string # * :prefix - Prefixes the new method with the target name or a custom prefix - # * :allow_nil - If set to true, prevents a +Module::DelegationError+ + # * :allow_nil - If set to true, prevents a +ActiveSupport::DelegationError+ # from being raised # * :private - If set to true, changes method visibility to private # @@ -16521,7 +18499,7 @@ class Module # User.new.age # => 2 # # If the target is +nil+ and does not respond to the delegated method a - # +Module::DelegationError+ is raised. If you wish to instead return +nil+, + # +ActiveSupport::DelegationError+ is raised. If you wish to instead return +nil+, # use the :allow_nil option. # # class User < ActiveRecord::Base @@ -16530,7 +18508,7 @@ class Module # end # # User.new.age - # # => Module::DelegationError: User#age delegated to profile.age, but profile is nil + # # => ActiveSupport::DelegationError: User#age delegated to profile.age, but profile is nil # # But if not having a profile yet is fine and should not be an error # condition: @@ -16558,7 +18536,7 @@ class Module # # The target method must be public, otherwise it will raise +NoMethodError+. # - # source://activesupport//lib/active_support/core_ext/module/delegation.rb#171 + # source://activesupport//lib/active_support/core_ext/module/delegation.rb#160 def delegate(*methods, to: T.unsafe(nil), prefix: T.unsafe(nil), allow_nil: T.unsafe(nil), private: T.unsafe(nil)); end # When building decorators, a common pattern may emerge: @@ -16600,7 +18578,7 @@ class Module # variables, methods, constants, etc. # # The delegated method must be public on the target, otherwise it will - # raise +DelegationError+. If you wish to instead return +nil+, + # raise +ActiveSupport::DelegationError+. If you wish to instead return +nil+, # use the :allow_nil option. # # The marshal_dump and _dump methods are exempt from @@ -16608,20 +18586,15 @@ class Module # Marshal.dump(object), should the delegation target method # of object add or remove instance variables. # - # source://activesupport//lib/active_support/core_ext/module/delegation.rb#289 + # source://activesupport//lib/active_support/core_ext/module/delegation.rb#218 def delegate_missing_to(target, allow_nil: T.unsafe(nil)); end - # deprecate :foo - # deprecate bar: 'message' - # deprecate :foo, :bar, baz: 'warning!', qux: 'gone!' - # - # You can also use custom deprecator instance: + # deprecate :foo, deprecator: MyLib.deprecator + # deprecate :foo, bar: "warning!", deprecator: MyLib.deprecator # - # deprecate :foo, deprecator: MyLib::Deprecator.new - # deprecate :foo, bar: "warning!", deprecator: MyLib::Deprecator.new - # - # \Custom deprecators must respond to deprecation_warning(deprecated_method_name, message, caller_backtrace) - # method where you can implement your custom warning behavior. + # A deprecator is typically an instance of ActiveSupport::Deprecation, but you can also pass any object that responds + # to deprecation_warning(deprecated_method_name, message, caller_backtrace) where you can implement your + # custom warning behavior. # # class MyLib::Deprecator # def deprecation_warning(deprecated_method_name, message, caller_backtrace = nil) @@ -16630,8 +18603,8 @@ class Module # end # end # - # source://activesupport//lib/active_support/core_ext/module/deprecation.rb#22 - def deprecate(*method_names); end + # source://activesupport//lib/active_support/core_ext/module/deprecation.rb#17 + def deprecate(*method_names, deprecator:, **options); end # Defines both class and instance accessors for class attributes. # All class and instance methods created will be public, even if @@ -16690,6 +18663,7 @@ class Module # # module HairColors # mattr_accessor :hair_colors, default: [:brown, :black, :blonde, :red] + # mattr_accessor(:hair_styles) { [:long, :short] } # end # # class Person @@ -16697,8 +18671,9 @@ class Module # end # # Person.class_variable_get("@@hair_colors") # => [:brown, :black, :blonde, :red] + # Person.class_variable_get("@@hair_styles") # => [:long, :short] # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#202 + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#208 def mattr_accessor(*syms, instance_reader: T.unsafe(nil), instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil), &blk); end # Defines a class attribute and creates a class and instance reader methods. @@ -16738,6 +18713,7 @@ class Module # # module HairColors # mattr_reader :hair_colors, default: [:brown, :black, :blonde, :red] + # mattr_reader(:hair_styles) { [:long, :short] } # end # # class Person @@ -16745,10 +18721,11 @@ class Module # end # # Person.new.hair_colors # => [:brown, :black, :blonde, :red] + # Person.new.hair_styles # => [:long, :short] # # @raise [TypeError] # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#53 + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#55 def mattr_reader(*syms, instance_reader: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil), location: T.unsafe(nil)); end # Defines a class attribute and creates a class and instance writer methods to @@ -16786,6 +18763,7 @@ class Module # # module HairColors # mattr_writer :hair_colors, default: [:brown, :black, :blonde, :red] + # mattr_writer(:hair_styles) { [:long, :short] } # end # # class Person @@ -16793,10 +18771,11 @@ class Module # end # # Person.class_variable_get("@@hair_colors") # => [:brown, :black, :blonde, :red] + # Person.class_variable_get("@@hair_styles") # => [:long, :short] # # @raise [TypeError] # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#117 + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors.rb#121 def mattr_writer(*syms, instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil), location: T.unsafe(nil)); end # source://activesupport//lib/active_support/core_ext/module/redefine_method.rb#30 @@ -16818,14 +18797,14 @@ class Module # M.module_parent # => Object # Module.new.module_parent # => Object # - # source://activesupport//lib/active_support/core_ext/module/introspection.rb#35 + # source://activesupport//lib/active_support/core_ext/module/introspection.rb#34 def module_parent; end # Returns the name of the module containing this one. # # M::N.module_parent_name # => "M" # - # source://activesupport//lib/active_support/core_ext/module/introspection.rb#10 + # source://activesupport//lib/active_support/core_ext/module/introspection.rb#9 def module_parent_name; end # Returns all the parents of this module according to its name, ordered from @@ -16841,7 +18820,7 @@ class Module # M::N.module_parents # => [M, Object] # X.module_parents # => [M, Object] # - # source://activesupport//lib/active_support/core_ext/module/introspection.rb#51 + # source://activesupport//lib/active_support/core_ext/module/introspection.rb#50 def module_parents; end # Replaces the existing method definition, if there is one, with the passed @@ -16915,7 +18894,11 @@ class Module # Current.new.user = "DHH" # => NoMethodError # Current.new.user # => NoMethodError # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#152 + # A default value may be specified using the +:default+ option. Because + # multiple threads can access the default value, non-frozen default values + # will be duped and frozen. + # + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#170 def thread_cattr_accessor(*syms, instance_reader: T.unsafe(nil), instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil)); end # Defines a per-thread class attribute and creates class and instance reader methods. @@ -16967,8 +18950,8 @@ class Module # # Current.new.user = "DHH" # => NoMethodError # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#85 - def thread_cattr_writer(*syms, instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil)); end + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#101 + def thread_cattr_writer(*syms, instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil)); end # Defines both class and instance accessors for class attributes. # @@ -17012,7 +18995,11 @@ class Module # Current.new.user = "DHH" # => NoMethodError # Current.new.user # => NoMethodError # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#152 + # A default value may be specified using the +:default+ option. Because + # multiple threads can access the default value, non-frozen default values + # will be duped and frozen. + # + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#170 def thread_mattr_accessor(*syms, instance_reader: T.unsafe(nil), instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil)); end # Defines a per-thread class attribute and creates class and instance reader methods. @@ -17064,33 +19051,26 @@ class Module # # Current.new.user = "DHH" # => NoMethodError # - # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#85 - def thread_mattr_writer(*syms, instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil), default: T.unsafe(nil)); end + # source://activesupport//lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#101 + def thread_mattr_writer(*syms, instance_writer: T.unsafe(nil), instance_accessor: T.unsafe(nil)); end private - # source://activesupport//lib/active_support/core_ext/module/attr_internal.rb#30 + # source://activesupport//lib/active_support/core_ext/module/attr_internal.rb#41 def attr_internal_define(attr_name, type); end - # source://activesupport//lib/active_support/core_ext/module/attr_internal.rb#26 - def attr_internal_ivar_name(attr); end - class << self # Returns the value of attribute attr_internal_naming_format. # - # source://activesupport//lib/active_support/core_ext/module/attr_internal.rb#22 + # source://activesupport//lib/active_support/core_ext/module/attr_internal.rb#23 def attr_internal_naming_format; end - # Sets the attribute attr_internal_naming_format - # - # @param value the value to set the attribute attr_internal_naming_format to. - # - # source://activesupport//lib/active_support/core_ext/module/attr_internal.rb#22 - def attr_internal_naming_format=(_arg0); end + # source://activesupport//lib/active_support/core_ext/module/attr_internal.rb#25 + def attr_internal_naming_format=(format); end end end -# = Bite-sized separation of concerns +# == Bite-sized separation of concerns # # We often find ourselves with a medium-sized chunk of behavior that we'd # like to extract, but only mix in to a single class. @@ -17105,9 +19085,9 @@ end # with a comment, as a least-bad alternative. Using modules in separate files # means tedious sifting to get a big-picture view. # -# = Dissatisfying ways to separate small concerns +# == Dissatisfying ways to separate small concerns # -# == Using comments: +# === Using comments: # # class Todo < ApplicationRecord # # Other todo implementation @@ -17124,7 +19104,7 @@ end # end # end # -# == With an inline module: +# === With an inline module: # # Noisy syntax. # @@ -17148,7 +19128,7 @@ end # include EventTracking # end # -# == Mix-in noise exiled to its own file: +# === Mix-in noise exiled to its own file: # # Once our chunk of behavior starts pushing the scroll-to-understand-it # boundary, we give in and move it to a separate file. At this size, the @@ -17162,7 +19142,7 @@ end # include TodoEventTracking # end # -# = Introducing Module#concerning +# == Introducing Module#concerning # # By quieting the mix-in noise, we arrive at a natural, low-ceremony way to # separate bite-sized concerns. @@ -17222,20 +19202,8 @@ module Module::Concerning def concerning(topic, prepend: T.unsafe(nil), &block); end end -# source://activesupport//lib/active_support/core_ext/module/delegation.rb#13 -Module::DELEGATION_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) - -# source://activesupport//lib/active_support/core_ext/module/delegation.rb#14 -Module::DELEGATION_RESERVED_METHOD_NAMES = T.let(T.unsafe(nil), Set) - -# Error generated by +delegate+ when a method is called on +nil+ and +allow_nil+ -# option is not used. -# -# source://activesupport//lib/active_support/core_ext/module/delegation.rb#8 -class Module::DelegationError < ::NoMethodError; end - -# source://activesupport//lib/active_support/core_ext/module/delegation.rb#10 -Module::RUBY_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) +# source://activesupport//lib/active_support/core_ext/module/delegation.rb#5 +Module::DelegationError = ActiveSupport::DelegationError # source://activesupport//lib/active_support/core_ext/name_error.rb#3 class NameError < ::StandardError @@ -17279,7 +19247,7 @@ NameError::UNBOUND_METHOD_MODULE_NAME = T.let(T.unsafe(nil), UnboundMethod) # source://activesupport//lib/active_support/core_ext/object/blank.rb#50 class NilClass - # source://activesupport//lib/active_support/core_ext/object/json.rb#87 + # source://activesupport//lib/active_support/core_ext/object/json.rb#95 def as_json(options = T.unsafe(nil)); end # +nil+ is blank: @@ -17291,6 +19259,11 @@ class NilClass # source://activesupport//lib/active_support/core_ext/object/blank.rb#56 def blank?; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#60 + def present?; end + # Returns +self+. # # source://activesupport//lib/active_support/core_ext/object/to_query.rb#20 @@ -17318,11 +19291,11 @@ class NilClass def try!(*_arg0); end end -# source://activesupport//lib/active_support/core_ext/object/blank.rb#134 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#170 class Numeric include ::Comparable - # source://activesupport//lib/active_support/core_ext/object/json.rb#105 + # source://activesupport//lib/active_support/core_ext/object/json.rb#113 def as_json(options = T.unsafe(nil)); end # No number is blank: @@ -17332,21 +19305,21 @@ class Numeric # # @return [false] # - # source://activesupport//lib/active_support/core_ext/object/blank.rb#141 + # source://activesupport//lib/active_support/core_ext/object/blank.rb#177 def blank?; end # Enables the use of byte calculations and declarations, like 45.bytes + 2.6.megabytes # # 2.bytes # => 2 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#14 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#15 def byte; end # Enables the use of byte calculations and declarations, like 45.bytes + 2.6.megabytes # # 2.bytes # => 2 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#14 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#15 def bytes; end # Returns a Duration instance matching the number of days provided. @@ -17367,14 +19340,14 @@ class Numeric # # 2.exabytes # => 2_305_843_009_213_693_952 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#62 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#63 def exabyte; end # Returns the number of bytes equivalent to the exabytes provided. # # 2.exabytes # => 2_305_843_009_213_693_952 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#62 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#63 def exabytes; end # Returns a Duration instance matching the number of fortnights provided. @@ -17395,14 +19368,14 @@ class Numeric # # 2.gigabytes # => 2_147_483_648 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#38 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#39 def gigabyte; end # Returns the number of bytes equivalent to the gigabytes provided. # # 2.gigabytes # => 2_147_483_648 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#38 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#39 def gigabytes; end # Returns a Duration instance matching the number of hours provided. @@ -17421,7 +19394,7 @@ class Numeric # @return [Boolean] # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#156 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#13 def html_safe?; end # Returns the number of milliseconds equivalent to the seconds provided. @@ -17437,28 +19410,28 @@ class Numeric # # 2.kilobytes # => 2048 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#22 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#23 def kilobyte; end # Returns the number of bytes equivalent to the kilobytes provided. # # 2.kilobytes # => 2048 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#22 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#23 def kilobytes; end # Returns the number of bytes equivalent to the megabytes provided. # # 2.megabytes # => 2_097_152 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#30 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#31 def megabyte; end # Returns the number of bytes equivalent to the megabytes provided. # # 2.megabytes # => 2_097_152 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#30 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#31 def megabytes; end # Returns a Duration instance matching the number of minutes provided. @@ -17479,16 +19452,21 @@ class Numeric # # 2.petabytes # => 2_251_799_813_685_248 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#54 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#55 def petabyte; end # Returns the number of bytes equivalent to the petabytes provided. # # 2.petabytes # => 2_251_799_813_685_248 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#54 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#55 def petabytes; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#181 + def present?; end + # Returns a Duration instance matching the number of seconds provided. # # 2.seconds # => 2 seconds @@ -17507,14 +19485,14 @@ class Numeric # # 2.terabytes # => 2_199_023_255_552 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#46 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#47 def terabyte; end # Returns the number of bytes equivalent to the terabytes provided. # # 2.terabytes # => 2_199_023_255_552 # - # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#46 + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#47 def terabytes; end # Returns a Duration instance matching the number of weeks provided. @@ -17530,6 +19508,20 @@ class Numeric # # source://activesupport//lib/active_support/core_ext/numeric/time.rb#45 def weeks; end + + # Returns the number of bytes equivalent to the zettabytes provided. + # + # 2.zettabytes # => 2_361_183_241_434_822_606_848 + # + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#71 + def zettabyte; end + + # Returns the number of bytes equivalent to the zettabytes provided. + # + # 2.zettabytes # => 2_361_183_241_434_822_606_848 + # + # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#71 + def zettabytes; end end # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#9 @@ -17550,6 +19542,9 @@ Numeric::PETABYTE = T.let(T.unsafe(nil), Integer) # source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#7 Numeric::TERABYTE = T.let(T.unsafe(nil), Integer) +# source://activesupport//lib/active_support/core_ext/numeric/bytes.rb#10 +Numeric::ZETTABYTE = T.let(T.unsafe(nil), Integer) + # -- # Most objects are cloneable, but not all. For example you can't dup methods: # @@ -17571,11 +19566,11 @@ Numeric::TERABYTE = T.let(T.unsafe(nil), Integer) # # source://activesupport//lib/active_support/core_ext/object/blank.rb#5 class Object < ::BasicObject - include ::ActiveSupport::ToJsonWithActiveSupportEncoder include ::ActiveSupport::Dependencies::RequireDependency include ::Kernel include ::PP::ObjectMixin include ::ActiveSupport::Tryable + include ::ActiveSupport::ToJsonWithActiveSupportEncoder # Provides a way to check whether some class acts like some other class based on the existence of # an appropriately-named marker method. @@ -17630,23 +19625,49 @@ class Object < ::BasicObject # source://activesupport//lib/active_support/core_ext/object/blank.rb#18 def blank?; end + # Returns a deep copy of object if it's duplicable. If it's + # not duplicable, returns +self+. + # + # object = Object.new + # dup = object.deep_dup + # dup.instance_variable_set(:@a, 1) + # + # object.instance_variable_defined?(:@a) # => false + # dup.instance_variable_defined?(:@a) # => true + # + # source://activesupport//lib/active_support/core_ext/object/deep_dup.rb#15 + def deep_dup; end + + # Can you safely dup this object? + # + # False for method objects; + # true otherwise. + # + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/duplicable.rb#26 + def duplicable?; end + # @return [Boolean] # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#150 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#7 def html_safe?; end - # Returns true if this object is included in the argument. Argument must be - # any object which responds to +#include?+. Usage: + # Returns true if this object is included in the argument. + # + # When argument is a +Range+, +#cover?+ is used to properly handle inclusion + # check within open ranges. Otherwise, argument must be any object which responds + # to +#include?+. Usage: # # characters = ["Konata", "Kagami", "Tsukasa"] # "Konata".in?(characters) # => true # - # This will throw an +ArgumentError+ if the argument doesn't respond - # to +#include?+. + # For non +Range+ arguments, this will throw an +ArgumentError+ if the argument + # doesn't respond to +#include?+. # # @return [Boolean] # - # source://activesupport//lib/active_support/core_ext/object/inclusion.rb#12 + # source://activesupport//lib/active_support/core_ext/object/inclusion.rb#15 def in?(another_object); end # Returns a hash with string keys that maps instance variable names without "@" to their @@ -17673,7 +19694,7 @@ class Object < ::BasicObject # # C.new(0, 1).instance_variable_names # => ["@y", "@x"] # - # source://activesupport//lib/active_support/core_ext/object/instance_variables.rb#27 + # source://activesupport//lib/active_support/core_ext/object/instance_variables.rb#29 def instance_variable_names; end # Returns the receiver if it's present otherwise returns +nil+. @@ -17705,7 +19726,7 @@ class Object < ::BasicObject # # @return [Object] # - # source://activesupport//lib/active_support/core_ext/object/inclusion.rb#26 + # source://activesupport//lib/active_support/core_ext/object/inclusion.rb#34 def presence_in(another_object); end # An object is present if it's not blank. @@ -17726,11 +19747,37 @@ class Object < ::BasicObject # source://activesupport//lib/active_support/core_ext/object/to_query.rb#13 def to_query(key); end + # Set and restore public attributes around a block. + # + # client.timeout # => 5 + # client.with(timeout: 1) do |c| + # c.timeout # => 1 + # end + # client.timeout # => 5 + # + # The receiver is yielded to the provided block. + # + # This method is a shorthand for the common begin/ensure pattern: + # + # old_value = object.attribute + # begin + # object.attribute = new_value + # # do things + # ensure + # object.attribute = old_value + # end + # + # It can be used on any object as long as both the reader and writer methods + # are public. + # + # source://activesupport//lib/active_support/core_ext/object/with.rb#26 + def with(**attributes); end + # An elegant way to factor duplication out of options passed to a series of # method calls. Each method called in the block, with the block variable as - # the receiver, will have its options merged with the default +options+ hash - # provided. Each method called on the block variable must take an options - # hash as its final argument. + # the receiver, will have its options merged with the default +options+ + # Hash or Hash-like object provided. Each method called on + # the block variable must take an options hash as its final argument. # # Without with_options, this code contains duplication: # @@ -17791,7 +19838,7 @@ class Object < ::BasicObject # You can access these methods using the class name instead: # # class Phone < ActiveRecord::Base - # enum phone_number_type: { home: 0, office: 1, mobile: 2 } + # enum :phone_number_type, { home: 0, office: 1, mobile: 2 } # # with_options presence: true do # validates :phone_number_type, inclusion: { in: Phone.phone_number_types.keys } @@ -17816,15 +19863,16 @@ class Object < ::BasicObject def with_options(options, &block); end end -# source://activesupport//lib/active_support/core_ext/object/json.rb#222 +# source://activesupport//lib/active_support/core_ext/object/json.rb#230 class Pathname - # source://activesupport//lib/active_support/core_ext/object/json.rb#223 + # source://activesupport//lib/active_support/core_ext/object/json.rb#231 def as_json(options = T.unsafe(nil)); end end module Process extend ::ConnectionPool::ForkTracker - extend ::ActiveSupport::ForkTracker::ModernCoreExt + extend ::RedisClient::PIDCache::CoreExt + extend ::ActiveSupport::ForkTracker::CoreExt class << self # source://activesupport//lib/active_support/fork_tracker.rb#6 @@ -17832,18 +19880,15 @@ module Process end end -Process::CLOCK_TAI = T.let(T.unsafe(nil), Integer) - -# source://activesupport//lib/active_support/core_ext/object/json.rb#234 +# source://activesupport//lib/active_support/core_ext/object/json.rb#242 class Process::Status - # source://activesupport//lib/active_support/core_ext/object/json.rb#235 + # source://activesupport//lib/active_support/core_ext/object/json.rb#243 def as_json(options = T.unsafe(nil)); end end -# source://activesupport//lib/active_support/core_ext/object/json.rb#151 +# source://activesupport//lib/active_support/core_ext/enumerable.rb#233 class Range include ::ActiveSupport::RangeWithFormat - include ::ActiveSupport::DeprecatedRangeWithFormat include ::ActiveSupport::CompareWithRange include ::ActiveSupport::EachTimeWithZone include ::Enumerable @@ -17851,7 +19896,7 @@ class Range # source://activesupport//lib/active_support/core_ext/range/compare_range.rb#16 def ===(value); end - # source://activesupport//lib/active_support/core_ext/object/json.rb#152 + # source://activesupport//lib/active_support/core_ext/object/json.rb#160 def as_json(options = T.unsafe(nil)); end # source://activesupport//lib/active_support/core_ext/range/each.rb#7 @@ -17860,55 +19905,19 @@ class Range # source://activesupport//lib/active_support/core_ext/range/compare_range.rb#41 def include?(value); end - # Compare two ranges and see if they overlap each other - # (1..5).overlaps?(4..6) # => true - # (1..5).overlaps?(7..9) # => false - # - # @return [Boolean] - # - # source://activesupport//lib/active_support/core_ext/range/overlaps.rb#7 - def overlaps?(other); end - # source://activesupport//lib/active_support/core_ext/range/each.rb#12 def step(n = T.unsafe(nil), &block); end # Optimize range sum to use arithmetic progression if a block is not given and # we have a range of numeric values. # - # source://activesupport//lib/active_support/core_ext/enumerable.rb#287 - def sum(identity = T.unsafe(nil)); end - - # source://activesupport//lib/active_support/core_ext/range/deprecated_conversions.rb#6 - def to_s(format = T.unsafe(nil)); end -end - -class Redis - include ::Redis::Commands::Bitmaps - include ::Redis::Commands::Cluster - include ::Redis::Commands::Connection - include ::Redis::Commands::Geo - include ::Redis::Commands::Hashes - include ::Redis::Commands::HyperLogLog - include ::Redis::Commands::Keys - include ::Redis::Commands::Lists - include ::Redis::Commands::Pubsub - include ::Redis::Commands::Scripting - include ::Redis::Commands::Server - include ::Redis::Commands::Sets - include ::Redis::Commands::SortedSets - include ::Redis::Commands::Streams - include ::Redis::Commands::Strings - include ::Redis::Commands::Transactions - include ::ActiveSupport::Cache::ConnectionPoolLike -end - -class Redis::Distributed - include ::ActiveSupport::Cache::ConnectionPoolLike + # source://activesupport//lib/active_support/core_ext/enumerable.rb#236 + def sum(initial_value = T.unsafe(nil)); end end -# source://activesupport//lib/active_support/core_ext/object/json.rb#133 +# source://activesupport//lib/active_support/core_ext/object/json.rb#141 class Regexp - # source://activesupport//lib/active_support/core_ext/object/json.rb#134 + # source://activesupport//lib/active_support/core_ext/object/json.rb#142 def as_json(options = T.unsafe(nil)); end # Returns +true+ if the regexp has the multiline flag set. @@ -17925,12 +19934,47 @@ class Regexp def multiline?; end end -# source://regexp_parser/2.8.1/lib/regexp_parser/token.rb#2 -Regexp::TOKEN_KEYS = T.let(T.unsafe(nil), Array) +# source://activesupport//lib/active_support/core_ext/securerandom.rb#5 +module SecureRandom + class << self + # SecureRandom.base36 generates a random base36 string in lowercase. + # + # The argument _n_ specifies the length of the random string to be generated. + # + # If _n_ is not specified or is +nil+, 16 is assumed. It may be larger in the future. + # This method can be used over +base58+ if a deterministic case key is necessary. + # + # The result will contain alphanumeric characters in lowercase. + # + # p SecureRandom.base36 # => "4kugl2pdqmscqtje" + # p SecureRandom.base36(24) # => "77tmhrhjfvfdwodq8w7ev2m7" + # + # source://activesupport//lib/active_support/core_ext/securerandom.rb#34 + def base36(n = T.unsafe(nil)); end + + # SecureRandom.base58 generates a random base58 string. + # + # The argument _n_ specifies the length of the random string to be generated. + # + # If _n_ is not specified or is +nil+, 16 is assumed. It may be larger in the future. + # + # The result may contain alphanumeric characters except 0, O, I, and l. + # + # p SecureRandom.base58 # => "4kUgL2pdQMSCQtjE" + # p SecureRandom.base58(24) # => "77TMHrHJFvFDwodq8w7Ev2m7" + # + # source://activesupport//lib/active_support/core_ext/securerandom.rb#19 + def base58(n = T.unsafe(nil)); end + end +end -class Regexp::TimeoutError < ::RegexpError; end +# source://activesupport//lib/active_support/core_ext/securerandom.rb#7 +SecureRandom::BASE36_ALPHABET = T.let(T.unsafe(nil), Array) -# source://activesupport//lib/active_support/core_ext/object/duplicable.rb#53 +# source://activesupport//lib/active_support/core_ext/securerandom.rb#6 +SecureRandom::BASE58_ALPHABET = T.let(T.unsafe(nil), Array) + +# source://activesupport//lib/active_support/core_ext/object/duplicable.rb#62 module Singleton mixes_in_class_methods ::Singleton::SingletonClassMethods @@ -17940,19 +19984,16 @@ module Singleton # # @return [Boolean] # - # source://activesupport//lib/active_support/core_ext/object/duplicable.rb#57 + # source://activesupport//lib/active_support/core_ext/object/duplicable.rb#66 def duplicable?; end end -# source://singleton/0.1.1/singleton.rb#95 -Singleton::VERSION = T.let(T.unsafe(nil), String) - # String inflections define new methods on the String class to transform names for different purposes. # For instance, you can figure out the name of a table from the name of a class. # # 'ScaleScore'.tableize # => "scale_scores" # -# source://activesupport//lib/active_support/core_ext/object/blank.rb#103 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#135 class String include ::Comparable @@ -17963,7 +20004,7 @@ class String # source://activesupport//lib/active_support/core_ext/string/behavior.rb#5 def acts_like_string?; end - # source://activesupport//lib/active_support/core_ext/object/json.rb#93 + # source://activesupport//lib/active_support/core_ext/object/json.rb#101 def as_json(options = T.unsafe(nil)); end # If you pass a single integer, returns a substring of one character at that @@ -18008,7 +20049,7 @@ class String # # @return [true, false] # - # source://activesupport//lib/active_support/core_ext/object/blank.rb#121 + # source://activesupport//lib/active_support/core_ext/object/blank.rb#153 def blank?; end # By default, +camelize+ converts strings to UpperCamelCase. If the argument to camelize @@ -18021,11 +20062,9 @@ class String # 'active_record/errors'.camelize # => "ActiveRecord::Errors" # 'active_record/errors'.camelize(:lower) # => "activeRecord::Errors" # - # +camelize+ is also aliased as +camelcase+. - # # See ActiveSupport::Inflector.camelize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#103 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#101 def camelcase(first_letter = T.unsafe(nil)); end # By default, +camelize+ converts strings to UpperCamelCase. If the argument to camelize @@ -18038,14 +20077,12 @@ class String # 'active_record/errors'.camelize # => "ActiveRecord::Errors" # 'active_record/errors'.camelize(:lower) # => "activeRecord::Errors" # - # +camelize+ is also aliased as +camelcase+. - # # See ActiveSupport::Inflector.camelize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#103 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#101 def camelize(first_letter = T.unsafe(nil)); end - # Creates a class name from a plural table name like Rails does for table names to models. + # Creates a class name from a plural table name like \Rails does for table names to models. # Note that this returns a string and not a class. (To convert to an actual class # follow +classify+ with +constantize+.) # @@ -18054,7 +20091,7 @@ class String # # See ActiveSupport::Inflector.classify. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#243 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#239 def classify; end # +constantize+ tries to find a declared constant with the name specified @@ -18076,7 +20113,7 @@ class String # # See ActiveSupport::Inflector.dasherize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#152 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#148 def dasherize; end # Removes the rightmost segment from the constant expression in the string. @@ -18091,7 +20128,7 @@ class String # # See also +demodulize+. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#181 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#177 def deconstantize; end # Removes the module part from the constant expression in the string. @@ -18105,9 +20142,20 @@ class String # # See also +deconstantize+. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#166 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#162 def demodulize; end + # Converts the first character to lowercase. + # + # 'If they enjoyed The Matrix'.downcase_first # => "if they enjoyed The Matrix" + # 'I'.downcase_first # => "i" + # ''.downcase_first # => "" + # + # See ActiveSupport::Inflector.downcase_first. + # + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#284 + def downcase_first; end + # Returns the first character. If a limit is supplied, returns a substring # from the beginning of the string until it reaches the limit value. If the # given limit is greater than or equal to the string length, returns a copy of self. @@ -18132,7 +20180,7 @@ class String # # See ActiveSupport::Inflector.foreign_key. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#290 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#297 def foreign_key(separate_class_name_and_id_with_underscore = T.unsafe(nil)); end # Returns a substring from the given position to the end of the string. @@ -18158,10 +20206,10 @@ class String # +raw+ helper in views. It is recommended that you use +sanitize+ instead of # this method. It should never be called on user input. # - # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#368 + # source://activesupport//lib/active_support/core_ext/string/output_safety.rb#225 def html_safe; end - # Capitalizes the first word, turns underscores into spaces, and (by default)strips a + # Capitalizes the first word, turns underscores into spaces, and (by default) strips a # trailing '_id' if present. # Like +titleize+, this is meant for creating pretty output. # @@ -18181,7 +20229,7 @@ class String # # See ActiveSupport::Inflector.humanize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#266 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#262 def humanize(capitalize: T.unsafe(nil), keep_id_suffix: T.unsafe(nil)); end # Converts String to a TimeWithZone in the current zone if Time.zone or Time.zone_default @@ -18204,7 +20252,7 @@ class String # # The second argument, +indent_string+, specifies which indent string to # use. The default is +nil+, which tells the method to make a guess by - # peeking at the first indented line, and fallback to a space if there is + # peeking at the first indented line, and fall back to a space if there is # none. # # " foo".indent(2) # => " foo" @@ -18336,7 +20384,7 @@ class String # # See ActiveSupport::Inflector.parameterize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#219 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#215 def parameterize(separator: T.unsafe(nil), preserve_case: T.unsafe(nil), locale: T.unsafe(nil)); end # Returns the plural form of the word in the string. @@ -18366,6 +20414,11 @@ class String # source://activesupport//lib/active_support/core_ext/string/inflections.rb#35 def pluralize(count = T.unsafe(nil), locale = T.unsafe(nil)); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#165 + def present?; end + # Returns a new string with all occurrences of the patterns removed. # str = "foo bar test" # str.remove(" test") # => "foo bar" @@ -18459,7 +20512,7 @@ class String # source://activesupport//lib/active_support/core_ext/string/strip.rb#22 def strip_heredoc; end - # Creates the name of a table like Rails does for models to table names. This method + # Creates the name of a table like \Rails does for models to table names. This method # uses the +pluralize+ method on the last word in the string. # # 'RawScaledScorer'.tableize # => "raw_scaled_scorers" @@ -18468,12 +20521,12 @@ class String # # See ActiveSupport::Inflector.tableize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#231 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#227 def tableize; end # Capitalizes all the words and replaces some characters in the string to create # a nicer looking title. +titleize+ is meant for creating pretty output. It is not - # used in the Rails internals. + # used in the \Rails internals. # # The trailing '_id','Id'.. can be kept and capitalized by setting the # optional parameter +keep_id_suffix+ to true. @@ -18483,16 +20536,14 @@ class String # 'x-men: the last stand'.titleize # => "X Men: The Last Stand" # 'string_ending_with_id'.titleize(keep_id_suffix: true) # => "String Ending With Id" # - # +titleize+ is also aliased as +titlecase+. - # # See ActiveSupport::Inflector.titleize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#130 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#126 def titlecase(keep_id_suffix: T.unsafe(nil)); end # Capitalizes all the words and replaces some characters in the string to create # a nicer looking title. +titleize+ is meant for creating pretty output. It is not - # used in the Rails internals. + # used in the \Rails internals. # # The trailing '_id','Id'.. can be kept and capitalized by setting the # optional parameter +keep_id_suffix+ to true. @@ -18502,11 +20553,9 @@ class String # 'x-men: the last stand'.titleize # => "X Men: The Last Stand" # 'string_ending_with_id'.titleize(keep_id_suffix: true) # => "String Ending With Id" # - # +titleize+ is also aliased as +titlecase+. - # # See ActiveSupport::Inflector.titleize. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#130 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#126 def titleize(keep_id_suffix: T.unsafe(nil)); end # Returns a substring from the beginning of the string to the given position. @@ -18565,7 +20614,7 @@ class String # source://activesupport//lib/active_support/core_ext/string/conversions.rb#22 def to_time(form = T.unsafe(nil)); end - # Truncates a given +text+ after a given length if +text+ is longer than length: + # Truncates a given +text+ to length truncate_to if +text+ is longer than truncate_to: # # 'Once upon a time in a world far far away'.truncate(27) # # => "Once upon a time in a wo..." @@ -18578,16 +20627,20 @@ class String # 'Once upon a time in a world far far away'.truncate(27, separator: /\s/) # # => "Once upon a time in a..." # - # The last characters will be replaced with the :omission string (defaults to "...") - # for a total length not exceeding length: + # The last characters will be replaced with the :omission string (defaults to "..."). + # The total length will not exceed truncate_to unless both +text+ and :omission + # are longer than truncate_to: # # 'And they found that many people were sleeping better.'.truncate(25, omission: '... (continued)') # # => "And they f... (continued)" # - # source://activesupport//lib/active_support/core_ext/string/filters.rb#66 - def truncate(truncate_at, options = T.unsafe(nil)); end + # 'And they found that many people were sleeping better.'.truncate(4, omission: '... (continued)') + # # => "... (continued)" + # + # source://activesupport//lib/active_support/core_ext/string/filters.rb#70 + def truncate(truncate_to, options = T.unsafe(nil)); end - # Truncates +text+ to at most bytesize bytes in length without + # Truncates +text+ to at most truncate_to bytes in length without # breaking string encoding by splitting multibyte characters or breaking # grapheme clusters ("perceptual characters") by truncating at combining # characters. @@ -18600,10 +20653,12 @@ class String # => "🔪🔪🔪🔪…" # # The truncated text ends with the :omission string, defaulting - # to "…", for a total length not exceeding bytesize. + # to "…", for a total length not exceeding truncate_to. + # + # Raises +ArgumentError+ when the bytesize of :omission exceeds truncate_to. # - # source://activesupport//lib/active_support/core_ext/string/filters.rb#95 - def truncate_bytes(truncate_at, omission: T.unsafe(nil)); end + # source://activesupport//lib/active_support/core_ext/string/filters.rb#101 + def truncate_bytes(truncate_to, omission: T.unsafe(nil)); end # Truncates a given +text+ after a given number of words (words_count): # @@ -18620,7 +20675,7 @@ class String # 'And they found that many people were sleeping better.'.truncate_words(5, omission: '... (continued)') # # => "And they found that many... (continued)" # - # source://activesupport//lib/active_support/core_ext/string/filters.rb#136 + # source://activesupport//lib/active_support/core_ext/string/filters.rb#142 def truncate_words(words_count, options = T.unsafe(nil)); end # The reverse of +camelize+. Makes an underscored, lowercase form from the expression in the string. @@ -18632,10 +20687,10 @@ class String # # See ActiveSupport::Inflector.underscore. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#143 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#139 def underscore; end - # Converts just the first character to uppercase. + # Converts the first character to uppercase. # # 'what a Lovely Day'.upcase_first # => "What a Lovely Day" # 'w'.upcase_first # => "W" @@ -18643,59 +20698,72 @@ class String # # See ActiveSupport::Inflector.upcase_first. # - # source://activesupport//lib/active_support/core_ext/string/inflections.rb#277 + # source://activesupport//lib/active_support/core_ext/string/inflections.rb#273 def upcase_first; end end -# source://activesupport//lib/active_support/core_ext/object/blank.rb#104 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#136 String::BLANK_RE = T.let(T.unsafe(nil), Regexp) -# source://activesupport//lib/active_support/core_ext/object/blank.rb#105 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#137 String::ENCODED_BLANKS = T.let(T.unsafe(nil), Concurrent::Map) -# source://activesupport//lib/active_support/core_ext/object/json.rb#68 +# source://activesupport//lib/active_support/core_ext/object/json.rb#76 class Struct include ::Enumerable - # source://activesupport//lib/active_support/core_ext/object/json.rb#69 + # source://activesupport//lib/active_support/core_ext/object/json.rb#77 def as_json(options = T.unsafe(nil)); end end -# source://nokogiri/1.15.2/lib/nokogiri/html4/element_description_defaults.rb#11 -Struct::HTMLElementDescription = Struct - -# source://sys-uname/1.2.3/lib/sys/unix/uname.rb#109 -Struct::UnameStruct = Struct - -# source://activesupport//lib/active_support/core_ext/object/json.rb#98 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#123 class Symbol include ::Comparable - # source://activesupport//lib/active_support/core_ext/object/json.rb#99 + # source://activesupport//lib/active_support/core_ext/object/json.rb#107 def as_json(options = T.unsafe(nil)); end + + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#130 + def present?; end +end + +class Thread + # source://activesupport//lib/active_support/isolated_execution_state.rb#9 + def active_support_execution_state; end + + # source://activesupport//lib/active_support/isolated_execution_state.rb#9 + def active_support_execution_state=(_arg0); end +end + +# source://activesupport//lib/active_support/core_ext/thread/backtrace/location.rb#3 +class Thread::Backtrace::Location + # source://activesupport//lib/active_support/core_ext/thread/backtrace/location.rb#5 + def spot(ex); end end -# source://activesupport//lib/active_support/core_ext/object/blank.rb#146 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#186 class Time include ::Comparable include ::DateAndTime::Zones include ::DateAndTime::Calculations include ::DateAndTime::Compatibility - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#284 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#285 def +(other); end # Time#- can also be used to determine the number of seconds between two Time instances. # We're layering on additional behavior so that ActiveSupport::TimeWithZone instances # are coerced into values that Time#- will recognize # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#307 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#308 def -(other); end # Layers additional behavior on Time#<=> so that DateTime and ActiveSupport::TimeWithZone instances # can be chronologically compared with a Time # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#316 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#317 def <=>(other); end # Duck-types as a Time-like class. See Object#acts_like?. @@ -18721,80 +20789,80 @@ class Time # largest to smallest. This order can affect the result around the end of a # month. # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#186 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#187 def advance(options); end # Returns a new Time representing the time a number of seconds ago, this is basically a wrapper around the Numeric extension # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#212 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#213 def ago(seconds); end - # source://activesupport//lib/active_support/core_ext/object/json.rb#187 + # source://activesupport//lib/active_support/core_ext/object/json.rb#195 def as_json(options = T.unsafe(nil)); end # Returns a new Time representing the start of the day (0:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#225 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#226 def at_beginning_of_day; end # Returns a new Time representing the start of the hour (x:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#254 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#255 def at_beginning_of_hour; end # Returns a new Time representing the start of the minute (x:xx:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#270 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#271 def at_beginning_of_minute; end # Returns a new Time representing the end of the day, 23:59:59.999999 # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#243 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#244 def at_end_of_day; end # Returns a new Time representing the end of the hour, x:59:59.999999 # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#260 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#261 def at_end_of_hour; end # Returns a new Time representing the end of the minute, x:xx:59.999999 # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#276 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#277 def at_end_of_minute; end # Returns a new Time representing the middle of the day (12:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#233 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#234 def at_midday; end # Returns a new Time representing the middle of the day (12:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#233 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#234 def at_middle_of_day; end # Returns a new Time representing the start of the day (0:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#225 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#226 def at_midnight; end # Returns a new Time representing the middle of the day (12:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#233 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#234 def at_noon; end # Returns a new Time representing the start of the day (0:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#225 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#226 def beginning_of_day; end # Returns a new Time representing the start of the hour (x:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#254 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#255 def beginning_of_hour; end # Returns a new Time representing the start of the minute (x:xx:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#270 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#271 def beginning_of_minute; end # No Time is blank: @@ -18803,7 +20871,7 @@ class Time # # @return [false] # - # source://activesupport//lib/active_support/core_ext/object/blank.rb#152 + # source://activesupport//lib/active_support/core_ext/object/blank.rb#192 def blank?; end # Returns a new Time where one or more of the elements have been changed according @@ -18821,40 +20889,40 @@ class Time # # @raise [ArgumentError] # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#138 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#123 def change(options); end # Layers additional behavior on Time#<=> so that DateTime and ActiveSupport::TimeWithZone instances # can be chronologically compared with a Time # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#316 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#317 def compare_with_coercion(other); end # Returns a new Time representing the end of the day, 23:59:59.999999 # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#243 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#244 def end_of_day; end # Returns a new Time representing the end of the hour, x:59:59.999999 # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#260 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#261 def end_of_hour; end # Returns a new Time representing the end of the minute, x:xx:59.999999 # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#276 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#277 def end_of_minute; end # Layers additional behavior on Time#eql? so that ActiveSupport::TimeWithZone instances # can be eql? to an equivalent Time # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#331 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#337 def eql?(other); end # Layers additional behavior on Time#eql? so that ActiveSupport::TimeWithZone instances # can be eql? to an equivalent Time # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#331 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#337 def eql_with_coercion(other); end # Returns a formatted string of the offset from UTC, or an alternative @@ -18863,78 +20931,86 @@ class Time # Time.local(2000).formatted_offset # => "-06:00" # Time.local(2000).formatted_offset(false) # => "-0600" # - # source://activesupport//lib/active_support/core_ext/time/conversions.rb#69 + # source://activesupport//lib/active_support/core_ext/time/conversions.rb#67 def formatted_offset(colon = T.unsafe(nil), alternate_utc_string = T.unsafe(nil)); end # Returns a new Time representing the time a number of seconds since the instance time # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#217 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#218 def in(seconds); end # Returns a new Time representing the middle of the day (12:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#233 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#234 def midday; end # Returns a new Time representing the middle of the day (12:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#233 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#234 def middle_of_day; end # Returns a new Time representing the start of the day (0:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#225 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#226 def midnight; end # Time#- can also be used to determine the number of seconds between two Time instances. # We're layering on additional behavior so that ActiveSupport::TimeWithZone instances # are coerced into values that Time#- will recognize # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#307 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#308 def minus_with_coercion(other); end - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#294 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#295 def minus_with_duration(other); end - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#294 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#295 def minus_without_coercion(other); end # Returns a new time the specified number of days in the future. # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#345 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#351 def next_day(days = T.unsafe(nil)); end # Returns a new time the specified number of months in the future. # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#355 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#361 def next_month(months = T.unsafe(nil)); end # Returns a new time the specified number of years in the future. # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#365 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#371 def next_year(years = T.unsafe(nil)); end # Returns a new Time representing the middle of the day (12:00) # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#233 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#234 def noon; end - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#284 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#285 def plus_with_duration(other); end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#196 + def present?; end + + # source://activesupport//lib/active_support/core_ext/time/compatibility.rb#17 + def preserve_timezone; end + # Returns a new time the specified number of days ago. # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#340 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#346 def prev_day(days = T.unsafe(nil)); end # Returns a new time the specified number of months ago. # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#350 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#356 def prev_month(months = T.unsafe(nil)); end # Returns a new time the specified number of years ago. # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#360 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#366 def prev_year(years = T.unsafe(nil)); end # Returns the fraction of a second as a +Rational+ @@ -18964,7 +21040,7 @@ class Time # Returns a new Time representing the time a number of seconds since the instance time # - # source://activesupport//lib/active_support/core_ext/time/calculations.rb#217 + # source://activesupport//lib/active_support/core_ext/time/calculations.rb#218 def since(seconds); end # Converts to a formatted string. See DATE_FORMATS for built-in formats. @@ -19025,15 +21101,17 @@ class Time # source://activesupport//lib/active_support/core_ext/time/conversions.rb#53 def to_fs(format = T.unsafe(nil)); end - # source://activesupport//lib/active_support/core_ext/time/deprecated_conversions.rb#7 - def to_s(format = T.unsafe(nil)); end - # Either return +self+ or the time in the local system timezone depending # on the setting of +ActiveSupport.to_time_preserves_timezone+. # # source://activesupport//lib/active_support/core_ext/time/compatibility.rb#13 def to_time; end + private + + # source://activesupport//lib/active_support/core_ext/time/compatibility.rb#24 + def active_support_local_zone; end + class << self # Overriding case equality method so that it returns true for ActiveSupport::TimeWithZone instances # @@ -19044,13 +21122,13 @@ class Time # instances can be used when called with a single argument # # source://activesupport//lib/active_support/core_ext/time/calculations.rb#45 - def at(*args, **kwargs); end + def at(time_or_number, *args, **_arg2); end # Layers additional behavior on Time.at so that ActiveSupport::TimeWithZone and DateTime # instances can be used when called with a single argument # # source://activesupport//lib/active_support/core_ext/time/calculations.rb#45 - def at_with_coercion(*args, **kwargs); end + def at_with_coercion(time_or_number, *args, **_arg2); end # Returns Time.zone.now when Time.zone or config.time_zone are set, otherwise just returns Time.now. # @@ -19136,10 +21214,10 @@ class Time # # This method accepts any of the following: # - # * A Rails TimeZone object. - # * An identifier for a Rails TimeZone object (e.g., "Eastern Time (US & Canada)", -5.hours). - # * A TZInfo::Timezone object. - # * An identifier for a TZInfo::Timezone object (e.g., "America/New_York"). + # * A \Rails TimeZone object. + # * An identifier for a \Rails TimeZone object (e.g., "Eastern Time (US & Canada)", -5.hours). + # * A +TZInfo::Timezone+ object. + # * An identifier for a +TZInfo::Timezone+ object (e.g., "America/New_York"). # # Here's an example of how you might set Time.zone on a per request basis and reset it when the request is done. # current_user.time_zone just needs to return a string identifying the user's preferred time zone: @@ -19179,12 +21257,9 @@ Time::COMMON_YEAR_DAYS_IN_MONTH = T.let(T.unsafe(nil), Array) # source://activesupport//lib/active_support/core_ext/time/conversions.rb#8 Time::DATE_FORMATS = T.let(T.unsafe(nil), Hash) -# source://activesupport//lib/active_support/core_ext/time/deprecated_conversions.rb#6 -Time::NOT_SET = T.let(T.unsafe(nil), Object) - -# source://activesupport//lib/active_support/core_ext/object/blank.rb#72 +# source://activesupport//lib/active_support/core_ext/object/blank.rb#80 class TrueClass - # source://activesupport//lib/active_support/core_ext/object/json.rb#75 + # source://activesupport//lib/active_support/core_ext/object/json.rb#83 def as_json(options = T.unsafe(nil)); end # +true+ is not blank: @@ -19193,32 +21268,24 @@ class TrueClass # # @return [false] # - # source://activesupport//lib/active_support/core_ext/object/blank.rb#78 + # source://activesupport//lib/active_support/core_ext/object/blank.rb#86 def blank?; end + # @return [Boolean] + # + # source://activesupport//lib/active_support/core_ext/object/blank.rb#90 + def present?; end + # Returns +self+. # # source://activesupport//lib/active_support/core_ext/object/to_query.rb#27 def to_param; end end -# source://activesupport//lib/active_support/core_ext/object/json.rb#216 +# source://activesupport//lib/active_support/core_ext/object/json.rb#224 class URI::Generic include ::URI::RFC2396_REGEXP - # source://activesupport//lib/active_support/core_ext/object/json.rb#217 + # source://activesupport//lib/active_support/core_ext/object/json.rb#225 def as_json(options = T.unsafe(nil)); end end - -# source://activesupport//lib/active_support/core_ext/object/duplicable.rb#41 -class UnboundMethod - # Unbound methods are not duplicable: - # - # method(:puts).unbind.duplicable? # => false - # method(:puts).unbind.dup # => TypeError: allocator undefined for UnboundMethod - # - # @return [Boolean] - # - # source://activesupport//lib/active_support/core_ext/object/duplicable.rb#46 - def duplicable?; end -end diff --git a/sorbet/rbi/gems/addressable@2.8.4.rbi b/sorbet/rbi/gems/addressable@2.8.7.rbi similarity index 89% rename from sorbet/rbi/gems/addressable@2.8.4.rbi rename to sorbet/rbi/gems/addressable@2.8.7.rbi index 7d2a47ea0..eb8dae420 100644 --- a/sorbet/rbi/gems/addressable@2.8.4.rbi +++ b/sorbet/rbi/gems/addressable@2.8.7.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `addressable` gem. # Please instead update this file by running `bin/tapioca gem addressable`. + # Addressable is a library for processing links and URIs. # # source://addressable//lib/addressable/version.rb#22 @@ -637,7 +638,7 @@ class Addressable::Template::MatchData # @param key [String, Symbol, Fixnum] Capture index or name. Note that when accessing by with index # of 0, the full URI will be returned. The intention is to mimic # the ::MatchData#[] behavior. - # @param len [#to_int, nil] If provided, an array of values will be returend with the given + # @param len [#to_int, nil] If provided, an array of values will be returned with the given # parameter used as length. # @return [Array, String, nil] The captured value corresponding to the index or name. If the # value was not provided or the key is unknown, nil will be @@ -790,7 +791,7 @@ class Addressable::URI # @param [String, [Hash] a customizable set of options # @return [Addressable::URI] The constructed URI object. # - # source://addressable//lib/addressable/uri.rb#823 + # source://addressable//lib/addressable/uri.rb#830 def initialize(options = T.unsafe(nil)); end # Joins two URIs together. @@ -798,7 +799,7 @@ class Addressable::URI # @param The [String, Addressable::URI, #to_str] URI to join with. # @return [Addressable::URI] The joined URI. # - # source://addressable//lib/addressable/uri.rb#1882 + # source://addressable//lib/addressable/uri.rb#1889 def +(uri); end # Returns true if the URI objects are equal. This method @@ -808,7 +809,7 @@ class Addressable::URI # @return [TrueClass, FalseClass] true if the URIs are equivalent, false # otherwise. # - # source://addressable//lib/addressable/uri.rb#2232 + # source://addressable//lib/addressable/uri.rb#2239 def ==(uri); end # Returns true if the URI objects are equal. This method @@ -819,7 +820,7 @@ class Addressable::URI # @return [TrueClass, FalseClass] true if the URIs are equivalent, false # otherwise. # - # source://addressable//lib/addressable/uri.rb#2210 + # source://addressable//lib/addressable/uri.rb#2217 def ===(uri); end # Determines if the URI is absolute. @@ -827,7 +828,7 @@ class Addressable::URI # @return [TrueClass, FalseClass] true if the URI is absolute. false # otherwise. # - # source://addressable//lib/addressable/uri.rb#1872 + # source://addressable//lib/addressable/uri.rb#1879 def absolute?; end # The authority component for this URI. @@ -835,21 +836,21 @@ class Addressable::URI # # @return [String] The authority component. # - # source://addressable//lib/addressable/uri.rb#1227 + # source://addressable//lib/addressable/uri.rb#1234 def authority; end # Sets the authority component for this URI. # # @param new_authority [String, #to_str] The new authority component. # - # source://addressable//lib/addressable/uri.rb#1267 + # source://addressable//lib/addressable/uri.rb#1274 def authority=(new_authority); end # The basename, if any, of the file in the path component. # # @return [String] The path's basename. # - # source://addressable//lib/addressable/uri.rb#1581 + # source://addressable//lib/addressable/uri.rb#1588 def basename; end # The default port for this URI's scheme. @@ -858,7 +859,7 @@ class Addressable::URI # # @return [Integer] The default port. # - # source://addressable//lib/addressable/uri.rb#1447 + # source://addressable//lib/addressable/uri.rb#1454 def default_port; end # This method allows you to make several changes to a URI simultaneously, @@ -868,7 +869,7 @@ class Addressable::URI # # @param block [Proc] A set of operations to perform on a given URI. # - # source://addressable//lib/addressable/uri.rb#2389 + # source://addressable//lib/addressable/uri.rb#2396 def defer_validation; end # Creates a URI suitable for display to users. If semantic attacks are @@ -878,7 +879,7 @@ class Addressable::URI # # @return [Addressable::URI] A URI suitable for display purposes. # - # source://addressable//lib/addressable/uri.rb#2194 + # source://addressable//lib/addressable/uri.rb#2201 def display_uri; end # Returns the public suffix domain for this host. @@ -886,23 +887,26 @@ class Addressable::URI # @example # Addressable::URI.parse("http://www.example.co.uk").domain # => "example.co.uk" # - # source://addressable//lib/addressable/uri.rb#1218 + # source://addressable//lib/addressable/uri.rb#1225 def domain; end # Clones the URI object. # # @return [Addressable::URI] The cloned URI. # - # source://addressable//lib/addressable/uri.rb#2264 + # source://addressable//lib/addressable/uri.rb#2271 def dup; end # Determines if the URI is an empty string. # # @return [TrueClass, FalseClass] Returns true if empty, false otherwise. # - # source://addressable//lib/addressable/uri.rb#2326 + # source://addressable//lib/addressable/uri.rb#2333 def empty?; end + # source://addressable//lib/addressable/uri.rb#2406 + def encode_with(coder); end + # Returns true if the URI objects are equal. This method # does NOT normalize either URI before doing the comparison. # @@ -910,7 +914,7 @@ class Addressable::URI # @return [TrueClass, FalseClass] true if the URIs are equivalent, false # otherwise. # - # source://addressable//lib/addressable/uri.rb#2246 + # source://addressable//lib/addressable/uri.rb#2253 def eql?(uri); end # The extname, if any, of the file in the path component. @@ -918,28 +922,28 @@ class Addressable::URI # # @return [String] The path's extname. # - # source://addressable//lib/addressable/uri.rb#1591 + # source://addressable//lib/addressable/uri.rb#1598 def extname; end # The fragment component for this URI. # # @return [String] The fragment component. # - # source://addressable//lib/addressable/uri.rb#1803 + # source://addressable//lib/addressable/uri.rb#1810 def fragment; end # Sets the fragment component for this URI. # # @param new_fragment [String, #to_str] The new fragment component. # - # source://addressable//lib/addressable/uri.rb#1828 + # source://addressable//lib/addressable/uri.rb#1835 def fragment=(new_fragment); end # Freeze URI, initializing instance variables. # # @return [Addressable::URI] The frozen URI object. # - # source://addressable//lib/addressable/uri.rb#863 + # source://addressable//lib/addressable/uri.rb#870 def freeze; end # A hash value that will make a URI equivalent to its normalized @@ -947,21 +951,21 @@ class Addressable::URI # # @return [Integer] A hash of the URI. # - # source://addressable//lib/addressable/uri.rb#2256 + # source://addressable//lib/addressable/uri.rb#2263 def hash; end # The host component for this URI. # # @return [String] The host component. # - # source://addressable//lib/addressable/uri.rb#1113 + # source://addressable//lib/addressable/uri.rb#1120 def host; end # Sets the host component for this URI. # # @param new_host [String, #to_str] The new host component. # - # source://addressable//lib/addressable/uri.rb#1149 + # source://addressable//lib/addressable/uri.rb#1156 def host=(new_host); end # This method is same as URI::Generic#host except @@ -970,7 +974,7 @@ class Addressable::URI # @return [String] The hostname for this URI. # @see Addressable::URI#host # - # source://addressable//lib/addressable/uri.rb#1171 + # source://addressable//lib/addressable/uri.rb#1178 def hostname; end # This method is same as URI::Generic#host= except @@ -979,7 +983,7 @@ class Addressable::URI # @param new_hostname [String, #to_str] The new hostname for this URI. # @see Addressable::URI#host= # - # source://addressable//lib/addressable/uri.rb#1183 + # source://addressable//lib/addressable/uri.rb#1190 def hostname=(new_hostname); end # The inferred port component for this URI. @@ -988,14 +992,17 @@ class Addressable::URI # # @return [Integer] The inferred port component. # - # source://addressable//lib/addressable/uri.rb#1433 + # source://addressable//lib/addressable/uri.rb#1440 def inferred_port; end + # source://addressable//lib/addressable/uri.rb#2417 + def init_with(coder); end + # Returns a String representation of the URI object's state. # # @return [String] The URI object's state, as a String. # - # source://addressable//lib/addressable/uri.rb#2377 + # source://addressable//lib/addressable/uri.rb#2384 def inspect; end # Determines if the scheme indicates an IP-based protocol. @@ -1003,7 +1010,7 @@ class Addressable::URI # @return [TrueClass, FalseClass] true if the scheme indicates an IP-based protocol. # false otherwise. # - # source://addressable//lib/addressable/uri.rb#1848 + # source://addressable//lib/addressable/uri.rb#1855 def ip_based?; end # Joins two URIs together. @@ -1011,7 +1018,7 @@ class Addressable::URI # @param The [String, Addressable::URI, #to_str] URI to join with. # @return [Addressable::URI] The joined URI. # - # source://addressable//lib/addressable/uri.rb#1882 + # source://addressable//lib/addressable/uri.rb#1889 def join(uri); end # Destructive form of join. @@ -1020,7 +1027,7 @@ class Addressable::URI # @return [Addressable::URI] The joined URI. # @see Addressable::URI#join # - # source://addressable//lib/addressable/uri.rb#1985 + # source://addressable//lib/addressable/uri.rb#1992 def join!(uri); end # Merges a URI with a Hash of components. @@ -1032,7 +1039,7 @@ class Addressable::URI # @return [Addressable::URI] The merged URI. # @see Hash#merge # - # source://addressable//lib/addressable/uri.rb#2000 + # source://addressable//lib/addressable/uri.rb#2007 def merge(hash); end # Destructive form of merge. @@ -1041,7 +1048,7 @@ class Addressable::URI # @return [Addressable::URI] The merged URI. # @see Addressable::URI#merge # - # source://addressable//lib/addressable/uri.rb#2065 + # source://addressable//lib/addressable/uri.rb#2072 def merge!(uri); end # Returns a normalized URI object. @@ -1054,7 +1061,7 @@ class Addressable::URI # # @return [Addressable::URI] The normalized URI. # - # source://addressable//lib/addressable/uri.rb#2157 + # source://addressable//lib/addressable/uri.rb#2164 def normalize; end # Destructively normalizes this URI object. @@ -1062,63 +1069,63 @@ class Addressable::URI # @return [Addressable::URI] The normalized URI. # @see Addressable::URI#normalize # - # source://addressable//lib/addressable/uri.rb#2183 + # source://addressable//lib/addressable/uri.rb#2190 def normalize!; end # The authority component for this URI, normalized. # # @return [String] The authority component, normalized. # - # source://addressable//lib/addressable/uri.rb#1245 + # source://addressable//lib/addressable/uri.rb#1252 def normalized_authority; end # The fragment component for this URI, normalized. # # @return [String] The fragment component, normalized. # - # source://addressable//lib/addressable/uri.rb#1809 + # source://addressable//lib/addressable/uri.rb#1816 def normalized_fragment; end # The host component for this URI, normalized. # # @return [String] The host component, normalized. # - # source://addressable//lib/addressable/uri.rb#1119 + # source://addressable//lib/addressable/uri.rb#1126 def normalized_host; end # The password component for this URI, normalized. # # @return [String] The password component, normalized. # - # source://addressable//lib/addressable/uri.rb#995 + # source://addressable//lib/addressable/uri.rb#1002 def normalized_password; end # The path component for this URI, normalized. # # @return [String] The path component, normalized. # - # source://addressable//lib/addressable/uri.rb#1528 + # source://addressable//lib/addressable/uri.rb#1535 def normalized_path; end # The port component for this URI, normalized. # # @return [Integer] The port component, normalized. # - # source://addressable//lib/addressable/uri.rb#1385 + # source://addressable//lib/addressable/uri.rb#1392 def normalized_port; end # The query component for this URI, normalized. # # @return [String] The query component, normalized. # - # source://addressable//lib/addressable/uri.rb#1606 + # source://addressable//lib/addressable/uri.rb#1613 def normalized_query(*flags); end # The scheme component for this URI, normalized. # # @return [String] The scheme component, normalized. # - # source://addressable//lib/addressable/uri.rb#889 + # source://addressable//lib/addressable/uri.rb#896 def normalized_scheme; end # The normalized combination of components that represent a site. @@ -1130,21 +1137,21 @@ class Addressable::URI # # @return [String] The normalized components that identify a site. # - # source://addressable//lib/addressable/uri.rb#1478 + # source://addressable//lib/addressable/uri.rb#1485 def normalized_site; end # The user component for this URI, normalized. # # @return [String] The user component, normalized. # - # source://addressable//lib/addressable/uri.rb#940 + # source://addressable//lib/addressable/uri.rb#947 def normalized_user; end # The userinfo component for this URI, normalized. # # @return [String] The userinfo component, normalized. # - # source://addressable//lib/addressable/uri.rb#1061 + # source://addressable//lib/addressable/uri.rb#1068 def normalized_userinfo; end # Omits components from a URI. @@ -1157,7 +1164,7 @@ class Addressable::URI # @param *components [Symbol] The components to be omitted. # @return [Addressable::URI] The URI with components omitted. # - # source://addressable//lib/addressable/uri.rb#2290 + # source://addressable//lib/addressable/uri.rb#2297 def omit(*components); end # Destructive form of omit. @@ -1166,7 +1173,7 @@ class Addressable::URI # @return [Addressable::URI] The URI with components omitted. # @see Addressable::URI#omit # - # source://addressable//lib/addressable/uri.rb#2317 + # source://addressable//lib/addressable/uri.rb#2324 def omit!(*components); end # The origin for this URI, serialized to ASCII, as per @@ -1174,7 +1181,7 @@ class Addressable::URI # # @return [String] The serialized origin. # - # source://addressable//lib/addressable/uri.rb#1307 + # source://addressable//lib/addressable/uri.rb#1314 def origin; end # Sets the origin for this URI, serialized to ASCII, as per @@ -1183,35 +1190,35 @@ class Addressable::URI # # @param new_origin [String, #to_str] The new origin component. # - # source://addressable//lib/addressable/uri.rb#1326 + # source://addressable//lib/addressable/uri.rb#1333 def origin=(new_origin); end # The password component for this URI. # # @return [String] The password component. # - # source://addressable//lib/addressable/uri.rb#989 + # source://addressable//lib/addressable/uri.rb#996 def password; end # Sets the password component for this URI. # # @param new_password [String, #to_str] The new password component. # - # source://addressable//lib/addressable/uri.rb#1018 + # source://addressable//lib/addressable/uri.rb#1025 def password=(new_password); end # The path component for this URI. # # @return [String] The path component. # - # source://addressable//lib/addressable/uri.rb#1521 + # source://addressable//lib/addressable/uri.rb#1528 def path; end # Sets the path component for this URI. # # @param new_path [String, #to_str] The new path component. # - # source://addressable//lib/addressable/uri.rb#1560 + # source://addressable//lib/addressable/uri.rb#1567 def path=(new_path); end # The port component for this URI. @@ -1220,28 +1227,28 @@ class Addressable::URI # # @return [Integer] The port component. # - # source://addressable//lib/addressable/uri.rb#1379 + # source://addressable//lib/addressable/uri.rb#1386 def port; end # Sets the port component for this URI. # # @param new_port [String, Integer, #to_s] The new port component. # - # source://addressable//lib/addressable/uri.rb#1401 + # source://addressable//lib/addressable/uri.rb#1408 def port=(new_port); end # The query component for this URI. # # @return [String] The query component. # - # source://addressable//lib/addressable/uri.rb#1600 + # source://addressable//lib/addressable/uri.rb#1607 def query; end # Sets the query component for this URI. # # @param new_query [String, #to_str] The new query component. # - # source://addressable//lib/addressable/uri.rb#1634 + # source://addressable//lib/addressable/uri.rb#1641 def query=(new_query); end # Converts the query component to a Hash value. @@ -1262,7 +1269,7 @@ class Addressable::URI # @return [Hash, Array, nil] The query string parsed as a Hash or Array # or nil if the query string is blank. # - # source://addressable//lib/addressable/uri.rb#1665 + # source://addressable//lib/addressable/uri.rb#1672 def query_values(return_type = T.unsafe(nil)); end # Sets the query component for this URI from a Hash object. @@ -1283,7 +1290,7 @@ class Addressable::URI # # => "flag&key=value" # @param new_query_values [Hash, #to_hash, Array] The new query values. # - # source://addressable//lib/addressable/uri.rb#1716 + # source://addressable//lib/addressable/uri.rb#1723 def query_values=(new_query_values); end # Determines if the URI is relative. @@ -1291,7 +1298,7 @@ class Addressable::URI # @return [TrueClass, FalseClass] true if the URI is relative. false # otherwise. # - # source://addressable//lib/addressable/uri.rb#1862 + # source://addressable//lib/addressable/uri.rb#1869 def relative?; end # The HTTP request URI for this URI. This is the path and the @@ -1299,14 +1306,14 @@ class Addressable::URI # # @return [String] The request URI required for an HTTP request. # - # source://addressable//lib/addressable/uri.rb#1767 + # source://addressable//lib/addressable/uri.rb#1774 def request_uri; end # Sets the HTTP request URI for this URI. # # @param new_request_uri [String, #to_str] The new HTTP request URI. # - # source://addressable//lib/addressable/uri.rb#1779 + # source://addressable//lib/addressable/uri.rb#1786 def request_uri=(new_request_uri); end # Returns the shortest normalized relative form of this URI that uses the @@ -1316,7 +1323,7 @@ class Addressable::URI # @param uri [String, Addressable::URI, #to_str] The URI to route from. # @return [Addressable::URI] The normalized relative URI that is equivalent to the original URI. # - # source://addressable//lib/addressable/uri.rb#2078 + # source://addressable//lib/addressable/uri.rb#2085 def route_from(uri); end # Returns the shortest normalized relative form of the supplied URI that @@ -1326,21 +1333,21 @@ class Addressable::URI # @param uri [String, Addressable::URI, #to_str] The URI to route to. # @return [Addressable::URI] The normalized relative URI that is equivalent to the supplied URI. # - # source://addressable//lib/addressable/uri.rb#2143 + # source://addressable//lib/addressable/uri.rb#2150 def route_to(uri); end # The scheme component for this URI. # # @return [String] The scheme component. # - # source://addressable//lib/addressable/uri.rb#883 + # source://addressable//lib/addressable/uri.rb#890 def scheme; end # Sets the scheme component for this URI. # # @param new_scheme [String, #to_str] The new scheme component. # - # source://addressable//lib/addressable/uri.rb#910 + # source://addressable//lib/addressable/uri.rb#917 def scheme=(new_scheme); end # The combination of components that represent a site. @@ -1352,14 +1359,14 @@ class Addressable::URI # # @return [String] The components that identify a site. # - # source://addressable//lib/addressable/uri.rb#1460 + # source://addressable//lib/addressable/uri.rb#1467 def site; end # Sets the site value for this URI. # # @param new_site [String, #to_str] The new site value. # - # source://addressable//lib/addressable/uri.rb#1499 + # source://addressable//lib/addressable/uri.rb#1506 def site=(new_site); end # Returns the top-level domain for this host. @@ -1367,28 +1374,28 @@ class Addressable::URI # @example # Addressable::URI.parse("http://www.example.co.uk").tld # => "co.uk" # - # source://addressable//lib/addressable/uri.rb#1200 + # source://addressable//lib/addressable/uri.rb#1207 def tld; end # Sets the top-level domain for this URI. # # @param new_tld [String, #to_str] The new top-level domain. # - # source://addressable//lib/addressable/uri.rb#1208 + # source://addressable//lib/addressable/uri.rb#1215 def tld=(new_tld); end # Returns a Hash of the URI components. # # @return [Hash] The URI as a Hash of components. # - # source://addressable//lib/addressable/uri.rb#2360 + # source://addressable//lib/addressable/uri.rb#2367 def to_hash; end # Converts the URI to a String. # # @return [String] The URI's String representation. # - # source://addressable//lib/addressable/uri.rb#2334 + # source://addressable//lib/addressable/uri.rb#2341 def to_s; end # Converts the URI to a String. @@ -1396,21 +1403,21 @@ class Addressable::URI # # @return [String] The URI's String representation. # - # source://addressable//lib/addressable/uri.rb#2334 + # source://addressable//lib/addressable/uri.rb#2341 def to_str; end # The user component for this URI. # # @return [String] The user component. # - # source://addressable//lib/addressable/uri.rb#934 + # source://addressable//lib/addressable/uri.rb#941 def user; end # Sets the user component for this URI. # # @param new_user [String, #to_str] The new user component. # - # source://addressable//lib/addressable/uri.rb#963 + # source://addressable//lib/addressable/uri.rb#970 def user=(new_user); end # The userinfo component for this URI. @@ -1418,14 +1425,14 @@ class Addressable::URI # # @return [String] The userinfo component. # - # source://addressable//lib/addressable/uri.rb#1045 + # source://addressable//lib/addressable/uri.rb#1052 def userinfo; end # Sets the userinfo component for this URI. # # @param new_userinfo [String, #to_str] The new userinfo component. # - # source://addressable//lib/addressable/uri.rb#1084 + # source://addressable//lib/addressable/uri.rb#1091 def userinfo=(new_userinfo); end protected @@ -1434,14 +1441,14 @@ class Addressable::URI # # @api private # - # source://addressable//lib/addressable/uri.rb#2535 + # source://addressable//lib/addressable/uri.rb#2561 def force_utf8_encoding_if_needed(str); end # Resets composite values for the entire URI # # @api private # - # source://addressable//lib/addressable/uri.rb#2526 + # source://addressable//lib/addressable/uri.rb#2552 def remove_composite_values; end # Replaces the internal state of self with the specified URI's state. @@ -1450,7 +1457,7 @@ class Addressable::URI # @param uri [Addressable::URI] The URI to replace self with. # @return [Addressable::URI] self. # - # source://addressable//lib/addressable/uri.rb#2493 + # source://addressable//lib/addressable/uri.rb#2519 def replace_self(uri); end # Splits path string with "/" (slash). @@ -1460,12 +1467,12 @@ class Addressable::URI # @param path [String] The path to split. # @return [Array] An array of parts of path. # - # source://addressable//lib/addressable/uri.rb#2516 + # source://addressable//lib/addressable/uri.rb#2542 def split_path(path); end # Ensures that the URI is valid. # - # source://addressable//lib/addressable/uri.rb#2450 + # source://addressable//lib/addressable/uri.rb#2476 def validate; end private @@ -1474,7 +1481,7 @@ class Addressable::URI # # @api private # - # source://addressable//lib/addressable/uri.rb#2547 + # source://addressable//lib/addressable/uri.rb#2573 def reset_ivs; end class << self @@ -1503,7 +1510,7 @@ class Addressable::URI # @return [Addressable::URI] The parsed file scheme URI or the original URI if some other URI # scheme was provided. # - # source://addressable//lib/addressable/uri.rb#279 + # source://addressable//lib/addressable/uri.rb#292 def convert_path(path); end # Percent encodes any special characters in the URI. @@ -1517,7 +1524,7 @@ class Addressable::URI # The return type is determined by the return_type # parameter. # - # source://addressable//lib/addressable/uri.rb#609 + # source://addressable//lib/addressable/uri.rb#616 def encode(uri, return_type = T.unsafe(nil)); end # Percent encodes a URI component. @@ -1550,7 +1557,7 @@ class Addressable::URI # character_class. # @return [String] The encoded component. # - # source://addressable//lib/addressable/uri.rb#394 + # source://addressable//lib/addressable/uri.rb#403 def encode_component(component, character_class = T.unsafe(nil), upcase_encoded = T.unsafe(nil)); end # Percent encodes any special characters in the URI. @@ -1564,7 +1571,7 @@ class Addressable::URI # The return type is determined by the return_type # parameter. # - # source://addressable//lib/addressable/uri.rb#609 + # source://addressable//lib/addressable/uri.rb#616 def escape(uri, return_type = T.unsafe(nil)); end # Percent encodes a URI component. @@ -1597,7 +1604,7 @@ class Addressable::URI # character_class. # @return [String] The encoded component. # - # source://addressable//lib/addressable/uri.rb#394 + # source://addressable//lib/addressable/uri.rb#403 def escape_component(component, character_class = T.unsafe(nil), upcase_encoded = T.unsafe(nil)); end # Encodes a set of key/value pairs according to the rules for the @@ -1608,7 +1615,7 @@ class Addressable::URI # Defaults to false. # @return [String] The encoded value. # - # source://addressable//lib/addressable/uri.rb#733 + # source://addressable//lib/addressable/uri.rb#740 def form_encode(form_values, sort = T.unsafe(nil)); end # Decodes a String according to the rules for the @@ -1619,7 +1626,7 @@ class Addressable::URI # This is not a Hash because of the possibility for # duplicate keys. # - # source://addressable//lib/addressable/uri.rb#786 + # source://addressable//lib/addressable/uri.rb#793 def form_unencode(encoded_value); end # Converts an input to a URI. The input does not have to be a valid @@ -1633,14 +1640,14 @@ class Addressable::URI # Defaults to {:scheme => "http"}. # @return [Addressable::URI] The parsed URI. # - # source://addressable//lib/addressable/uri.rb#178 + # source://addressable//lib/addressable/uri.rb#191 def heuristic_parse(uri, hints = T.unsafe(nil)); end # Returns an array of known ip-based schemes. These schemes typically # use a similar URI form: # //:@:/ # - # source://addressable//lib/addressable/uri.rb#1362 + # source://addressable//lib/addressable/uri.rb#1369 def ip_based_schemes; end # Joins several URIs together. @@ -1653,7 +1660,7 @@ class Addressable::URI # @param *uris [String, Addressable::URI, #to_str] The URIs to join. # @return [Addressable::URI] The joined URI. # - # source://addressable//lib/addressable/uri.rb#330 + # source://addressable//lib/addressable/uri.rb#343 def join(*uris); end # Normalizes the encoding of a URI component. @@ -1695,7 +1702,7 @@ class Addressable::URI # normalized to "%2F") but otherwise left alone. # @return [String] The normalized component. # - # source://addressable//lib/addressable/uri.rb#544 + # source://addressable//lib/addressable/uri.rb#552 def normalize_component(component, character_class = T.unsafe(nil), leave_encoded = T.unsafe(nil)); end # Resolves paths to their simplest form. @@ -1703,7 +1710,7 @@ class Addressable::URI # @param path [String] The path to normalize. # @return [String] The normalized path. # - # source://addressable//lib/addressable/uri.rb#2414 + # source://addressable//lib/addressable/uri.rb#2440 def normalize_path(path); end # Normalizes the encoding of a URI. Characters within a hostname are @@ -1718,7 +1725,7 @@ class Addressable::URI # The return type is determined by the return_type # parameter. # - # source://addressable//lib/addressable/uri.rb#664 + # source://addressable//lib/addressable/uri.rb#671 def normalized_encode(uri, return_type = T.unsafe(nil)); end # Returns a URI object based on the parsed string. @@ -1728,14 +1735,14 @@ class Addressable::URI # Addressable::URI. # @return [Addressable::URI] The parsed URI. # - # source://addressable//lib/addressable/uri.rb#101 + # source://addressable//lib/addressable/uri.rb#114 def parse(uri); end # Returns a hash of common IP-based schemes and their default port # numbers. Adding new schemes to this hash, as necessary, will allow # for better URI normalization. # - # source://addressable//lib/addressable/uri.rb#1369 + # source://addressable//lib/addressable/uri.rb#1376 def port_mapping; end # Unencodes any percent encoded characters within a URI component. @@ -1754,7 +1761,7 @@ class Addressable::URI # The return type is determined by the return_type # parameter. # - # source://addressable//lib/addressable/uri.rb#464 + # source://addressable//lib/addressable/uri.rb#472 def unencode(uri, return_type = T.unsafe(nil), leave_encoded = T.unsafe(nil)); end # Unencodes any percent encoded characters within a URI component. @@ -1773,7 +1780,7 @@ class Addressable::URI # The return type is determined by the return_type # parameter. # - # source://addressable//lib/addressable/uri.rb#464 + # source://addressable//lib/addressable/uri.rb#472 def unencode_component(uri, return_type = T.unsafe(nil), leave_encoded = T.unsafe(nil)); end # Unencodes any percent encoded characters within a URI component. @@ -1792,7 +1799,7 @@ class Addressable::URI # The return type is determined by the return_type # parameter. # - # source://addressable//lib/addressable/uri.rb#464 + # source://addressable//lib/addressable/uri.rb#472 def unescape(uri, return_type = T.unsafe(nil), leave_encoded = T.unsafe(nil)); end # Unencodes any percent encoded characters within a URI component. @@ -1811,7 +1818,7 @@ class Addressable::URI # The return type is determined by the return_type # parameter. # - # source://addressable//lib/addressable/uri.rb#464 + # source://addressable//lib/addressable/uri.rb#472 def unescape_component(uri, return_type = T.unsafe(nil), leave_encoded = T.unsafe(nil)); end end end @@ -1831,34 +1838,37 @@ module Addressable::URI::CharacterClasses; end # source://addressable//lib/addressable/uri.rb#47 Addressable::URI::CharacterClasses::ALPHA = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#56 +# source://addressable//lib/addressable/uri.rb#57 Addressable::URI::CharacterClasses::AUTHORITY = T.let(T.unsafe(nil), String) # source://addressable//lib/addressable/uri.rb#48 Addressable::URI::CharacterClasses::DIGIT = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#59 +# source://addressable//lib/addressable/uri.rb#60 Addressable::URI::CharacterClasses::FRAGMENT = T.let(T.unsafe(nil), String) # source://addressable//lib/addressable/uri.rb#49 Addressable::URI::CharacterClasses::GEN_DELIMS = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#55 +# source://addressable//lib/addressable/uri.rb#56 Addressable::URI::CharacterClasses::HOST = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#57 +# source://addressable//lib/addressable/uri.rb#58 Addressable::URI::CharacterClasses::PATH = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#53 +# source://addressable//lib/addressable/uri.rb#54 Addressable::URI::CharacterClasses::PCHAR = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#58 +# source://addressable//lib/addressable/uri.rb#59 Addressable::URI::CharacterClasses::QUERY = T.let(T.unsafe(nil), String) # source://addressable//lib/addressable/uri.rb#51 Addressable::URI::CharacterClasses::RESERVED = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#54 +# source://addressable//lib/addressable/uri.rb#53 +Addressable::URI::CharacterClasses::RESERVED_AND_UNRESERVED = T.let(T.unsafe(nil), String) + +# source://addressable//lib/addressable/uri.rb#55 Addressable::URI::CharacterClasses::SCHEME = T.let(T.unsafe(nil), String) # source://addressable//lib/addressable/uri.rb#50 @@ -1868,6 +1878,36 @@ Addressable::URI::CharacterClasses::SUB_DELIMS = T.let(T.unsafe(nil), String) Addressable::URI::CharacterClasses::UNRESERVED = T.let(T.unsafe(nil), String) # source://addressable//lib/addressable/uri.rb#72 +module Addressable::URI::CharacterClassesRegexps; end + +# source://addressable//lib/addressable/uri.rb#73 +Addressable::URI::CharacterClassesRegexps::AUTHORITY = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#74 +Addressable::URI::CharacterClassesRegexps::FRAGMENT = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#75 +Addressable::URI::CharacterClassesRegexps::HOST = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#76 +Addressable::URI::CharacterClassesRegexps::PATH = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#77 +Addressable::URI::CharacterClassesRegexps::QUERY = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#78 +Addressable::URI::CharacterClassesRegexps::RESERVED = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#79 +Addressable::URI::CharacterClassesRegexps::RESERVED_AND_UNRESERVED = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#80 +Addressable::URI::CharacterClassesRegexps::SCHEME = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#81 +Addressable::URI::CharacterClassesRegexps::UNRESERVED = T.let(T.unsafe(nil), Regexp) + +# source://addressable//lib/addressable/uri.rb#85 Addressable::URI::EMPTY_STR = T.let(T.unsafe(nil), String) # Raised if something other than a uri is supplied. @@ -1875,67 +1915,67 @@ Addressable::URI::EMPTY_STR = T.let(T.unsafe(nil), String) # source://addressable//lib/addressable/uri.rb#34 class Addressable::URI::InvalidURIError < ::StandardError; end -# source://addressable//lib/addressable/uri.rb#2572 -Addressable::URI::NONE = T.let(T.unsafe(nil), Object) +# source://addressable//lib/addressable/uri.rb#2598 +module Addressable::URI::NONE; end -# source://addressable//lib/addressable/uri.rb#1523 +# source://addressable//lib/addressable/uri.rb#1530 Addressable::URI::NORMPATH = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#62 +# source://addressable//lib/addressable/uri.rb#63 module Addressable::URI::NormalizeCharacterClasses; end -# source://addressable//lib/addressable/uri.rb#67 +# source://addressable//lib/addressable/uri.rb#68 Addressable::URI::NormalizeCharacterClasses::FRAGMENT = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#63 +# source://addressable//lib/addressable/uri.rb#64 Addressable::URI::NormalizeCharacterClasses::HOST = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#65 +# source://addressable//lib/addressable/uri.rb#66 Addressable::URI::NormalizeCharacterClasses::PCHAR = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#68 +# source://addressable//lib/addressable/uri.rb#69 Addressable::URI::NormalizeCharacterClasses::QUERY = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#66 +# source://addressable//lib/addressable/uri.rb#67 Addressable::URI::NormalizeCharacterClasses::SCHEME = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#64 +# source://addressable//lib/addressable/uri.rb#65 Addressable::URI::NormalizeCharacterClasses::UNRESERVED = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#2401 +# source://addressable//lib/addressable/uri.rb#2427 Addressable::URI::PARENT = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#76 +# source://addressable//lib/addressable/uri.rb#89 Addressable::URI::PORT_MAPPING = T.let(T.unsafe(nil), Hash) -# source://addressable//lib/addressable/uri.rb#2403 +# source://addressable//lib/addressable/uri.rb#2429 Addressable::URI::RULE_2A = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#2404 +# source://addressable//lib/addressable/uri.rb#2430 Addressable::URI::RULE_2B_2C = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#2405 +# source://addressable//lib/addressable/uri.rb#2431 Addressable::URI::RULE_2D = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#2406 +# source://addressable//lib/addressable/uri.rb#2432 Addressable::URI::RULE_PREFIXED_PARENT = T.let(T.unsafe(nil), Regexp) -# source://addressable//lib/addressable/uri.rb#2400 +# source://addressable//lib/addressable/uri.rb#2426 Addressable::URI::SELF_REF = T.let(T.unsafe(nil), String) # Tables used to optimize encoding operations in `self.encode_component` # and `self.normalize_component` # -# source://addressable//lib/addressable/uri.rb#347 -Addressable::URI::SEQUENCE_ENCODING_TABLE = T.let(T.unsafe(nil), Hash) +# source://addressable//lib/addressable/uri.rb#360 +Addressable::URI::SEQUENCE_ENCODING_TABLE = T.let(T.unsafe(nil), Array) -# source://addressable//lib/addressable/uri.rb#353 -Addressable::URI::SEQUENCE_UPCASED_PERCENT_ENCODING_TABLE = T.let(T.unsafe(nil), Hash) +# source://addressable//lib/addressable/uri.rb#364 +Addressable::URI::SEQUENCE_UPCASED_PERCENT_ENCODING_TABLE = T.let(T.unsafe(nil), Array) -# source://addressable//lib/addressable/uri.rb#71 +# source://addressable//lib/addressable/uri.rb#84 Addressable::URI::SLASH = T.let(T.unsafe(nil), String) -# source://addressable//lib/addressable/uri.rb#74 +# source://addressable//lib/addressable/uri.rb#87 Addressable::URI::URIREGEX = T.let(T.unsafe(nil), Regexp) # source://addressable//lib/addressable/version.rb#23 diff --git a/sorbet/rbi/gems/airbrussh@1.4.1.rbi b/sorbet/rbi/gems/airbrussh@1.5.2.rbi similarity index 99% rename from sorbet/rbi/gems/airbrussh@1.4.1.rbi rename to sorbet/rbi/gems/airbrussh@1.5.2.rbi index f0569fc24..a569c1c92 100644 --- a/sorbet/rbi/gems/airbrussh@1.4.1.rbi +++ b/sorbet/rbi/gems/airbrussh@1.5.2.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `airbrussh` gem. # Please instead update this file by running `bin/tapioca gem airbrussh`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/american_date@1.2.0.rbi b/sorbet/rbi/gems/american_date@1.2.0.rbi deleted file mode 100644 index 09beaf922..000000000 --- a/sorbet/rbi/gems/american_date@1.2.0.rbi +++ /dev/null @@ -1,8 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `american_date` gem. -# Please instead update this file by running `bin/tapioca gem american_date`. - -# source://american_date//lib/american_date.rb#16 -AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) diff --git a/sorbet/rbi/gems/american_date@1.3.0.rbi b/sorbet/rbi/gems/american_date@1.3.0.rbi new file mode 100644 index 000000000..e25a8da55 --- /dev/null +++ b/sorbet/rbi/gems/american_date@1.3.0.rbi @@ -0,0 +1,26 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `american_date` gem. +# Please instead update this file by running `bin/tapioca gem american_date`. + + +class Date + include ::Comparable + + class << self + # source://american_date//lib/american_date.rb#31 + def _parse(string, comp = T.unsafe(nil), limit: T.unsafe(nil)); end + + # source://american_date//lib/american_date.rb#52 + def parse(string, comp = T.unsafe(nil), start = T.unsafe(nil), limit: T.unsafe(nil)); end + + private + + # source://american_date//lib/american_date.rb#69 + def convert_american_to_iso(string); end + end +end + +# source://american_date//lib/american_date.rb#18 +Date::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) diff --git a/sorbet/rbi/gems/ast@2.4.2.rbi b/sorbet/rbi/gems/ast@2.4.2.rbi index 3fc4495da..e0ae88ef3 100644 --- a/sorbet/rbi/gems/ast@2.4.2.rbi +++ b/sorbet/rbi/gems/ast@2.4.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `ast` gem. # Please instead update this file by running `bin/tapioca gem ast`. + # {AST} is a library for manipulating abstract syntax trees. # # It embraces immutability; each AST node is inherently frozen at diff --git a/sorbet/rbi/gems/autoprefixer-rails@10.4.13.0.rbi b/sorbet/rbi/gems/autoprefixer-rails@10.4.19.0.rbi similarity index 99% rename from sorbet/rbi/gems/autoprefixer-rails@10.4.13.0.rbi rename to sorbet/rbi/gems/autoprefixer-rails@10.4.19.0.rbi index f1eaf2410..9e3fbbf9b 100644 --- a/sorbet/rbi/gems/autoprefixer-rails@10.4.13.0.rbi +++ b/sorbet/rbi/gems/autoprefixer-rails@10.4.19.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `autoprefixer-rails` gem. # Please instead update this file by running `bin/tapioca gem autoprefixer-rails`. + # source://autoprefixer-rails//lib/autoprefixer-rails/railtie.rb#10 module AutoprefixedRails; end diff --git a/sorbet/rbi/gems/aws-eventstream@1.3.0.rbi b/sorbet/rbi/gems/aws-eventstream@1.3.0.rbi new file mode 100644 index 000000000..a48530e93 --- /dev/null +++ b/sorbet/rbi/gems/aws-eventstream@1.3.0.rbi @@ -0,0 +1,380 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `aws-eventstream` gem. +# Please instead update this file by running `bin/tapioca gem aws-eventstream`. + + +# source://aws-eventstream//lib/aws-eventstream/decoder.rb#7 +module Aws + class << self + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#138 + def config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#141 + def config=(config); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#200 + def eager_autoload!(*args); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#193 + def empty_connection_pools!; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#150 + def partition(partition_name); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#155 + def partitions; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#131 + def shared_config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#170 + def use_bundled_cert!; end + end +end + +# source://aws-eventstream//lib/aws-eventstream/decoder.rb#8 +module Aws::EventStream; end + +# This class provides method for decoding binary inputs into +# single or multiple messages (Aws::EventStream::Message). +# +# * {#decode} - decodes messages from an IO like object responds +# to #read that containing binary data, returning decoded +# Aws::EventStream::Message along the way or wrapped in an enumerator +# +# ## Examples +# +# decoder = Aws::EventStream::Decoder.new +# +# # decoding from IO +# decoder.decode(io) do |message| +# message.headers +# # => { ... } +# message.payload +# # => StringIO / Tempfile +# end +# +# # alternatively +# message_pool = decoder.decode(io) +# message_pool.next +# # => Aws::EventStream::Message +# +# * {#decode_chunk} - decodes a single message from a chunk of data, +# returning message object followed by boolean(indicating eof status +# of data) in an array object +# +# ## Examples +# +# # chunk containing exactly one message data +# message, chunk_eof = decoder.decode_chunk(chunk_str) +# message +# # => Aws::EventStream::Message +# chunk_eof +# # => true +# +# # chunk containing a partial message +# message, chunk_eof = decoder.decode_chunk(chunk_str) +# message +# # => nil +# chunk_eof +# # => true +# # chunk data is saved at decoder's message_buffer +# +# # chunk containing more that one data message +# message, chunk_eof = decoder.decode_chunk(chunk_str) +# message +# # => Aws::EventStream::Message +# chunk_eof +# # => false +# # extra chunk data is saved at message_buffer of the decoder +# +# source://aws-eventstream//lib/aws-eventstream/decoder.rb#63 +class Aws::EventStream::Decoder + include ::Enumerable + + # @option options + # @param options [Hash] The initialization options. + # @return [Decoder] a new instance of Decoder + # + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#83 + def initialize(options = T.unsafe(nil)); end + + # Decodes messages from a binary stream + # + # @param io [IO#read] An IO-like object + # that responds to `#read` + # @return [Enumerable, nil] Returns a new Enumerable + # containing decoded messages if no block is given + # @yieldparam message [Message] + # + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#96 + def decode(io, &block); end + + # Decodes a single message from a chunk of string + # + # @param chunk [String] A chunk of string to be decoded, + # chunk can contain partial event message to multiple event messages + # When not provided, decode data from #message_buffer + # @return [Array] Returns single decoded message + # and boolean pair, the boolean flag indicates whether this chunk + # has been fully consumed, unused data is tracked at #message_buffer + # + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#114 + def decode_chunk(chunk = T.unsafe(nil)); end + + private + + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#163 + def decode_context(content, header_length); end + + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#130 + def decode_message(raw_message); end + + # @raise [Errors::PreludeChecksumError] + # + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#155 + def decode_prelude(prelude); end + + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#171 + def extract_headers(buffer); end + + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#201 + def extract_payload(encoded); end + + # exposed via object.send for testing + # + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#122 + def message_buffer; end + + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#207 + def payload_stringio(encoded); end + + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#211 + def payload_tempfile(encoded); end + + # source://aws-eventstream//lib/aws-eventstream/decoder.rb#124 + def wrap_as_enumerator(decoded_message); end +end + +# 4 bytes message crc checksum +# +# source://aws-eventstream//lib/aws-eventstream/decoder.rb#76 +Aws::EventStream::Decoder::CRC32_LENGTH = T.let(T.unsafe(nil), Integer) + +# source://aws-eventstream//lib/aws-eventstream/decoder.rb#67 +Aws::EventStream::Decoder::ONE_MEGABYTE = T.let(T.unsafe(nil), Integer) + +# bytes of prelude part, including 4 bytes of +# total message length, headers length and crc checksum of prelude +# +# source://aws-eventstream//lib/aws-eventstream/decoder.rb#72 +Aws::EventStream::Decoder::PRELUDE_LENGTH = T.let(T.unsafe(nil), Integer) + +# This class provides #encode method for encoding +# Aws::EventStream::Message into binary. +# +# * {#encode} - encode Aws::EventStream::Message into binary +# when output IO-like object is provided, binary string +# would be written to IO. If not, the encoded binary string +# would be returned directly +# +# ## Examples +# +# message = Aws::EventStream::Message.new( +# headers: { +# "foo" => Aws::EventStream::HeaderValue.new( +# value: "bar", type: "string" +# ) +# }, +# payload: "payload" +# ) +# encoder = Aws::EventsStream::Encoder.new +# file = Tempfile.new +# +# # encode into IO ouput +# encoder.encode(message, file) +# +# # get encoded binary string +# encoded_message = encoder.encode(message) +# +# file.read == encoded_message +# # => true +# +# source://aws-eventstream//lib/aws-eventstream/encoder.rb#38 +class Aws::EventStream::Encoder + # Encodes Aws::EventStream::Message to output IO when + # provided, else return the encoded binary string + # + # @param message [Aws::EventStream::Message] + # @param io [IO#write, nil] An IO-like object that + # responds to `#write`, encoded message will be + # written to this IO when provided + # @return [nil, String] when output IO is provided, + # encoded message will be written to that IO, nil + # will be returned. Else, encoded binary string is + # returned. + # + # source://aws-eventstream//lib/aws-eventstream/encoder.rb#63 + def encode(message, io = T.unsafe(nil)); end + + # Encodes headers part of an Aws::EventStream::Message + # into String + # + # @param message [Aws::EventStream::Message] + # @return [String] + # + # source://aws-eventstream//lib/aws-eventstream/encoder.rb#110 + def encode_headers(message); end + + # Encodes an Aws::EventStream::Message + # into String + # + # @param message [Aws::EventStream::Message] + # @return [String] + # + # source://aws-eventstream//lib/aws-eventstream/encoder.rb#79 + def encode_message(message); end + + private + + # source://aws-eventstream//lib/aws-eventstream/encoder.rb#135 + def encode_prelude(total_length, headers_length); end +end + +# Maximum header length allowed (after encode) 128kb +# +# source://aws-eventstream//lib/aws-eventstream/encoder.rb#45 +Aws::EventStream::Encoder::MAX_HEADERS_LENGTH = T.let(T.unsafe(nil), Integer) + +# Maximum payload length allowed (after encode) 16mb +# +# source://aws-eventstream//lib/aws-eventstream/encoder.rb#48 +Aws::EventStream::Encoder::MAX_PAYLOAD_LENGTH = T.let(T.unsafe(nil), Integer) + +# bytes of total overhead in a message, including prelude +# and 4 bytes total message crc checksum +# +# source://aws-eventstream//lib/aws-eventstream/encoder.rb#42 +Aws::EventStream::Encoder::OVERHEAD_LENGTH = T.let(T.unsafe(nil), Integer) + +# source://aws-eventstream//lib/aws-eventstream/errors.rb#5 +module Aws::EventStream::Errors; end + +# source://aws-eventstream//lib/aws-eventstream/errors.rb#41 +class Aws::EventStream::Errors::EventHeadersLengthExceedError < ::RuntimeError + # @return [EventHeadersLengthExceedError] a new instance of EventHeadersLengthExceedError + # + # source://aws-eventstream//lib/aws-eventstream/errors.rb#42 + def initialize(*args); end +end + +# source://aws-eventstream//lib/aws-eventstream/errors.rb#35 +class Aws::EventStream::Errors::EventPayloadLengthExceedError < ::RuntimeError + # @return [EventPayloadLengthExceedError] a new instance of EventPayloadLengthExceedError + # + # source://aws-eventstream//lib/aws-eventstream/errors.rb#36 + def initialize(*args); end +end + +# Raise when insufficient bytes of a message is received +# +# source://aws-eventstream//lib/aws-eventstream/errors.rb#17 +class Aws::EventStream::Errors::IncompleteMessageError < ::RuntimeError + # @return [IncompleteMessageError] a new instance of IncompleteMessageError + # + # source://aws-eventstream//lib/aws-eventstream/errors.rb#18 + def initialize(*args); end +end + +# source://aws-eventstream//lib/aws-eventstream/errors.rb#29 +class Aws::EventStream::Errors::MessageChecksumError < ::RuntimeError + # @return [MessageChecksumError] a new instance of MessageChecksumError + # + # source://aws-eventstream//lib/aws-eventstream/errors.rb#30 + def initialize(*args); end +end + +# source://aws-eventstream//lib/aws-eventstream/errors.rb#23 +class Aws::EventStream::Errors::PreludeChecksumError < ::RuntimeError + # @return [PreludeChecksumError] a new instance of PreludeChecksumError + # + # source://aws-eventstream//lib/aws-eventstream/errors.rb#24 + def initialize(*args); end +end + +# Raised when reading bytes exceed buffer total bytes +# +# source://aws-eventstream//lib/aws-eventstream/errors.rb#8 +class Aws::EventStream::Errors::ReadBytesExceedLengthError < ::RuntimeError + # @return [ReadBytesExceedLengthError] a new instance of ReadBytesExceedLengthError + # + # source://aws-eventstream//lib/aws-eventstream/errors.rb#9 + def initialize(target_byte, total_len); end +end + +# source://aws-eventstream//lib/aws-eventstream/header_value.rb#6 +class Aws::EventStream::HeaderValue + # @return [HeaderValue] a new instance of HeaderValue + # + # source://aws-eventstream//lib/aws-eventstream/header_value.rb#8 + def initialize(options); end + + # @return [String] type of the header value + # complete type list see Aws::EventStream::Types + # + # source://aws-eventstream//lib/aws-eventstream/header_value.rb#19 + def type; end + + # Returns the value of attribute value. + # + # source://aws-eventstream//lib/aws-eventstream/header_value.rb#15 + def value; end + + private + + # source://aws-eventstream//lib/aws-eventstream/header_value.rb#40 + def format_timestamp(value); end + + # source://aws-eventstream//lib/aws-eventstream/header_value.rb#32 + def format_uuid(value); end + + # source://aws-eventstream//lib/aws-eventstream/header_value.rb#23 + def format_value(value); end +end + +# source://aws-eventstream//lib/aws-eventstream/message.rb#5 +class Aws::EventStream::Message + # @return [Message] a new instance of Message + # + # source://aws-eventstream//lib/aws-eventstream/message.rb#7 + def initialize(options); end + + # @return [Hash] headers of a message + # + # source://aws-eventstream//lib/aws-eventstream/message.rb#13 + def headers; end + + # @return [IO] payload of a message, size not exceed 16MB. + # StringIO is returned for <= 1MB payload + # Tempfile is returned for > 1MB payload + # + # source://aws-eventstream//lib/aws-eventstream/message.rb#18 + def payload; end +end + +# Message Header Value Types +# +# source://aws-eventstream//lib/aws-eventstream/types.rb#7 +module Aws::EventStream::Types + class << self + # pack/unpack pattern, byte size, type idx + # + # source://aws-eventstream//lib/aws-eventstream/types.rb#25 + def pattern; end + + # source://aws-eventstream//lib/aws-eventstream/types.rb#9 + def types; end + end +end diff --git a/sorbet/rbi/gems/aws-partitions@1.963.0.rbi b/sorbet/rbi/gems/aws-partitions@1.963.0.rbi new file mode 100644 index 000000000..18547cd66 --- /dev/null +++ b/sorbet/rbi/gems/aws-partitions@1.963.0.rbi @@ -0,0 +1,694 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `aws-partitions` gem. +# Please instead update this file by running `bin/tapioca gem aws-partitions`. + + +# source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#3 +module Aws + class << self + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#138 + def config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#141 + def config=(config); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#200 + def eager_autoload!(*args); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#193 + def empty_connection_pools!; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#150 + def partition(partition_name); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#155 + def partitions; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#131 + def shared_config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#170 + def use_bundled_cert!; end + end +end + +# A {Partition} is a group of AWS {Region} and {Service} objects. You +# can use a partition to determine what services are available in a region, +# or what regions a service is available in. +# +# ## Partitions +# +# **AWS accounts are scoped to a single partition**. You can get a partition +# by name. Valid partition names include: +# +# * `"aws"` - Public AWS partition +# * `"aws-cn"` - AWS China +# * `"aws-us-gov"` - AWS GovCloud +# +# To get a partition by name: +# +# aws = Aws::Partitions.partition('aws') +# +# You can also enumerate all partitions: +# +# Aws::Partitions.each do |partition| +# puts partition.name +# end +# +# ## Regions +# +# A {Partition} is divided up into one or more regions. For example, the +# "aws" partition contains, "us-east-1", "us-west-1", etc. You can get +# a region by name. Calling {Partition#region} will return an instance +# of {Region}. +# +# region = Aws::Partitions.partition('aws').region('us-west-2') +# region.name +# #=> "us-west-2" +# +# You can also enumerate all regions within a partition: +# +# Aws::Partitions.partition('aws').regions.each do |region| +# puts region.name +# end +# +# Each {Region} object has a name, description and a list of services +# available to that region: +# +# us_west_2 = Aws::Partitions.partition('aws').region('us-west-2') +# +# us_west_2.name #=> "us-west-2" +# us_west_2.description #=> "US West (Oregon)" +# us_west_2.partition_name "aws" +# us_west_2.services #=> # true/false +# +# The service name should be the service's module name as used by +# the AWS SDK for Ruby. To find the complete list of supported +# service names, see {Partition#services}. +# +# Its also possible to enumerate every service for every region in +# every partition. +# +# Aws::Partitions.partitions.each do |partition| +# partition.regions.each do |region| +# region.services.each do |service_name| +# puts "#{partition.name} -> #{region.name} -> #{service_name}" +# end +# end +# end +# +# ## Services +# +# A {Partition} has a list of services available. You can get a +# single {Service} by name: +# +# Aws::Partitions.partition('aws').service('DynamoDB') +# +# You can also enumerate all services in a partition: +# +# Aws::Partitions.partition('aws').services.each do |service| +# puts service.name +# end +# +# Each {Service} object has a name, and information about regions +# that service is available in. +# +# service.name #=> "DynamoDB" +# service.partition_name #=> "aws" +# service.regions #=> # false +# service.partition_region #=> "aws-global" +# +# Its also possible to enumerate every region for every service in +# every partition. +# +# Aws::Partitions.partitions.each do |partition| +# partition.services.each do |service| +# service.regions.each do |region_name| +# puts "#{partition.name} -> #{region_name} -> #{service.name}" +# end +# end +# end +# +# ## Service Names +# +# {Service} names are those used by the the AWS SDK for Ruby. They +# correspond to the service's module. +# +# source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#4 +module Aws::Partitions + extend ::Enumerable + + class << self + # @api private For internal use only. + # @param new_partitions [Hash] + # + # source://aws-partitions//lib/aws-partitions.rb#191 + def add(new_partitions); end + + # @api private For internal use only. + # + # source://aws-partitions//lib/aws-partitions.rb#205 + def clear; end + + # @api private + # @return [Hash] + # + # source://aws-partitions//lib/aws-partitions.rb#232 + def default_metadata; end + + # @api private + # @return [PartitionList] + # + # source://aws-partitions//lib/aws-partitions.rb#212 + def default_partition_list; end + + # @api private + # @return [Hash] + # + # source://aws-partitions//lib/aws-partitions.rb#222 + def defaults; end + + # @return [Enumerable] + # + # source://aws-partitions//lib/aws-partitions.rb#136 + def each(&block); end + + # @api private For Internal use only + # @param partition_metadata [Hash] + # + # source://aws-partitions//lib/aws-partitions.rb#200 + def merge_metadata(partition_metadata); end + + # Return the partition with the given name. A partition describes + # the services and regions available in that partition. + # + # aws = Aws::Partitions.partition('aws') + # + # puts "Regions available in the aws partition:\n" + # aws.regions.each do |region| + # puts region.name + # end + # + # puts "Services available in the aws partition:\n" + # aws.services.each do |services| + # puts services.name + # end + # + # @param name [String] The name of the partition to return. + # Valid names include "aws", "aws-cn", and "aws-us-gov". + # @raise [ArgumentError] Raises an `ArgumentError` if a partition is + # not found with the given name. The error message contains a list + # of valid partition names. + # @return [Partition] + # + # source://aws-partitions//lib/aws-partitions.rb#163 + def partition(name); end + + # Returns an array with every partitions. A partition describes + # the services and regions available in that partition. + # + # Aws::Partitions.partitions.each do |partition| + # + # puts "Regions available in #{partition.name}:\n" + # partition.regions.each do |region| + # puts region.name + # end + # + # puts "Services available in #{partition.name}:\n" + # partition.services.each do |service| + # puts service.name + # end + # end + # + # @return [Enumerable] Returns an enumerable of all + # known partitions. + # + # source://aws-partitions//lib/aws-partitions.rb#185 + def partitions; end + + # @api private For internal use only. + # @return [Hash] Returns a map of service module names + # to their id as used in the endpoints.json document. + # + # source://aws-partitions//lib/aws-partitions.rb#243 + def service_ids; end + end +end + +# @api private +# +# source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#6 +class Aws::Partitions::EndpointProvider + # Intentionally marked private. The format of the endpoint rules + # is an implementation detail. + # + # @api private + # @return [EndpointProvider] a new instance of EndpointProvider + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#31 + def initialize(rules); end + + # @api private Use the static class methods instead. + # @option variants + # @option variants + # @param region [String] The region used to fetch the partition. + # @param service [String] Used only if dualstack is true. Used to find a + # DNS suffix for a specific service. + # @param variants [Hash] Endpoint variants such as 'fips' or 'dualstack' + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#73 + def dns_suffix_for(region, service, variants); end + + # @api private Use the static class methods instead. + # @option variants + # @option variants + # @param region [String] The region for the client. + # @param service [String] The endpoint prefix for the service, e.g. + # "monitoring" for cloudwatch. + # @param sts_regional_endpoints [String] [STS only] Whether to use + # `legacy` (global endpoint for legacy regions) or `regional` mode for + # using regional endpoint for supported regions except 'aws-global' + # @param variants [Hash] Endpoint variants such as 'fips' or 'dualstack' + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#46 + def resolve(region, service, sts_regional_endpoints, variants); end + + # @api private Use the static class methods instead. + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#51 + def signing_region(region, service, sts_regional_endpoints); end + + # @api private Use the static class methods instead. + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#57 + def signing_service(region, service); end + + private + + # returns a callable that takes a region + # and returns true if the service is global + # + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#178 + def build_is_global_fn(sts_regional_endpoints = T.unsafe(nil)); end + + # @api private + # @return [Boolean] + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#83 + def configured_variants?(variants); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#192 + def credential_scope(region, service, is_global_fn); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#238 + def default_partition; end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#125 + def endpoint_for(region, service, is_global_fn, variants); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#141 + def endpoint_no_variants_for(region, service, is_global_fn); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#133 + def endpoint_with_variants_for(region, service, variants); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#87 + def fetch_variant(cfg, tags); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#212 + def get_partition(region_or_partition); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#219 + def partition_containing_region(region); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#234 + def partition_matching_name(partition_name); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#225 + def partition_matching_region(region); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#92 + def resolve_variant(region, service, config_variants); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#117 + def validate_variant!(config_variants, resolved_variant); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#171 + def warn_deprecation(service, region); end + + class << self + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#256 + def dns_suffix_for(region, service = T.unsafe(nil), variants = T.unsafe(nil)); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#244 + def resolve(region, service, sts_endpoint = T.unsafe(nil), variants = T.unsafe(nil)); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#248 + def signing_region(region, service, sts_regional_endpoints = T.unsafe(nil)); end + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#252 + def signing_service(region, service); end + + private + + # @api private + # + # source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#262 + def default_provider; end + end +end + +# When sts_regional_endpoint is set to `legacy`, the endpoint +# pattern stays global for the following regions: +# +# @api private +# +# source://aws-partitions//lib/aws-partitions/endpoint_provider.rb#9 +Aws::Partitions::EndpointProvider::STS_LEGACY_REGIONS = T.let(T.unsafe(nil), Array) + +# source://aws-partitions//lib/aws-partitions/partition.rb#5 +class Aws::Partitions::Partition + # @api private + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Partition] a new instance of Partition + # + # source://aws-partitions//lib/aws-partitions/partition.rb#10 + def initialize(options = T.unsafe(nil)); end + + # @return [Metadata] The metadata for the partition. + # + # source://aws-partitions//lib/aws-partitions/partition.rb#25 + def metadata; end + + # @return [String] The partition name, e.g. "aws", "aws-cn", "aws-us-gov". + # + # source://aws-partitions//lib/aws-partitions/partition.rb#19 + def name; end + + # @param region_name [String] The name of the region, e.g. "us-east-1". + # @raise [ArgumentError] Raises `ArgumentError` for unknown region name. + # @return [Region] + # + # source://aws-partitions//lib/aws-partitions/partition.rb#30 + def region(region_name); end + + # @param region_name [String] The name of the region, e.g. "us-east-1". + # @return [Boolean] true if the region is in the partition. + # + # source://aws-partitions//lib/aws-partitions/partition.rb#47 + def region?(region_name); end + + # @return [String] The regex representing the region format. + # + # source://aws-partitions//lib/aws-partitions/partition.rb#22 + def region_regex; end + + # @return [Array] + # + # source://aws-partitions//lib/aws-partitions/partition.rb#41 + def regions; end + + # @param service_name [String] The service module name. + # @raise [ArgumentError] Raises `ArgumentError` for unknown service name. + # @return [Service] + # + # source://aws-partitions//lib/aws-partitions/partition.rb#54 + def service(service_name); end + + # @param service_name [String] The service module name. + # @return [Boolean] true if the service is in the partition. + # + # source://aws-partitions//lib/aws-partitions/partition.rb#71 + def service?(service_name); end + + # @return [Array] + # + # source://aws-partitions//lib/aws-partitions/partition.rb#65 + def services; end + + class << self + # @api private + # + # source://aws-partitions//lib/aws-partitions/partition.rb#77 + def build(partition); end + + private + + # @param partition [Hash] + # @return [Hash] + # + # source://aws-partitions//lib/aws-partitions/partition.rb#90 + def build_regions(partition); end + + # @param partition [Hash] + # @return [Hash] + # + # source://aws-partitions//lib/aws-partitions/partition.rb#102 + def build_services(partition); end + end +end + +# source://aws-partitions//lib/aws-partitions/partition_list.rb#5 +class Aws::Partitions::PartitionList + include ::Enumerable + + # @return [PartitionList] a new instance of PartitionList + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#9 + def initialize; end + + # @api private + # @param partition [Partition] + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#37 + def add_partition(partition); end + + # Removed all partitions. + # + # @api private + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#80 + def clear; end + + # @return [Enumerator] + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#14 + def each(&block); end + + # @api private + # @param partitions_metadata [Partition] + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#47 + def merge_metadata(partitions_metadata); end + + # @param partition_name [String] + # @return [Partition] + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#20 + def partition(partition_name); end + + # @return [Array] + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#31 + def partitions; end + + private + + # source://aws-partitions//lib/aws-partitions/partition_list.rb#86 + def build_metadata_regions(partition_name, metadata_regions, existing = T.unsafe(nil)); end + + class << self + # @api private + # + # source://aws-partitions//lib/aws-partitions/partition_list.rb#104 + def build(partitions); end + end +end + +# source://aws-partitions//lib/aws-partitions/region.rb#7 +class Aws::Partitions::Region + # @api private + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Region] a new instance of Region + # + # source://aws-partitions//lib/aws-partitions/region.rb#14 + def initialize(options = T.unsafe(nil)); end + + # @return [String] A short description of this region. + # + # source://aws-partitions//lib/aws-partitions/region.rb#25 + def description; end + + # @return [String] The name of this region, e.g. "us-east-1". + # + # source://aws-partitions//lib/aws-partitions/region.rb#22 + def name; end + + # @return [String] The partition this region exists in, e.g. "aws", + # "aws-cn", "aws-us-gov". + # + # source://aws-partitions//lib/aws-partitions/region.rb#29 + def partition_name; end + + # @return [Set] The list of services available in this region. + # Service names are the module names as used by the AWS SDK + # for Ruby. + # + # source://aws-partitions//lib/aws-partitions/region.rb#34 + def services; end + + class << self + # @api private + # + # source://aws-partitions//lib/aws-partitions/region.rb#39 + def build(region_name, region, partition); end + + private + + # source://aws-partitions//lib/aws-partitions/region.rb#50 + def region_services(region_name, partition); end + + # @return [Boolean] + # + # source://aws-partitions//lib/aws-partitions/region.rb#61 + def service_in_region?(svc, region_name); end + end +end + +# source://aws-partitions//lib/aws-partitions/service.rb#7 +class Aws::Partitions::Service + # @api private + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Service] a new instance of Service + # + # source://aws-partitions//lib/aws-partitions/service.rb#15 + def initialize(options = T.unsafe(nil)); end + + # @return [Set] The Dualstack compatible regions this service is + # available in. Regions are scoped to the partition. + # + # source://aws-partitions//lib/aws-partitions/service.rb#42 + def dualstack_regions; end + + # @return [Set] The FIPS compatible regions this service is + # available in. Regions are scoped to the partition. + # + # source://aws-partitions//lib/aws-partitions/service.rb#38 + def fips_regions; end + + # @return [String] The name of this service. The name is the module + # name as used by the AWS SDK for Ruby. + # + # source://aws-partitions//lib/aws-partitions/service.rb#27 + def name; end + + # @return [String] The partition name, e.g "aws", "aws-cn", "aws-us-gov". + # + # source://aws-partitions//lib/aws-partitions/service.rb#30 + def partition_name; end + + # @return [String, nil] The global patition endpoint for this service. + # May be `nil`. + # + # source://aws-partitions//lib/aws-partitions/service.rb#46 + def partition_region; end + + # Returns `false` if the service operates with a single global + # endpoint for the current partition, returns `true` if the service + # is available in multiple regions. + # + # Some services have both a partition endpoint and regional endpoints. + # + # @return [Boolean] + # + # source://aws-partitions//lib/aws-partitions/service.rb#55 + def regionalized?; end + + # @return [Set] The regions this service is available in. + # Regions are scoped to the partition. + # + # source://aws-partitions//lib/aws-partitions/service.rb#34 + def regions; end + + class << self + # @api private + # + # source://aws-partitions//lib/aws-partitions/service.rb#62 + def build(service_name, service, partition); end + + private + + # source://aws-partitions//lib/aws-partitions/service.rb#97 + def partition_region(service); end + + # source://aws-partitions//lib/aws-partitions/service.rb#76 + def regions(service, partition); end + + # source://aws-partitions//lib/aws-partitions/service.rb#82 + def variant_regions(variant_name, service, partition); end + end +end diff --git a/sorbet/rbi/gems/aws-sdk-core@3.201.4.rbi b/sorbet/rbi/gems/aws-sdk-core@3.201.4.rbi new file mode 100644 index 000000000..768c67f79 --- /dev/null +++ b/sorbet/rbi/gems/aws-sdk-core@3.201.4.rbi @@ -0,0 +1,18475 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `aws-sdk-core` gem. +# Please instead update this file by running `bin/tapioca gem aws-sdk-core`. + + +# source://aws-sdk-core//lib/aws-sdk-core/deprecations.rb#3 +module Aws + class << self + # @return [Hash] Returns a hash of default configuration options shared + # by all constructed clients. + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#138 + def config; end + + # @param config [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#141 + def config=(config); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#200 + def eager_autoload!(*args); end + + # Close any long-lived connections maintained by the SDK's internal + # connection pool. + # + # Applications that rely heavily on the `fork()` system call on POSIX systems + # should call this method in the child process directly after fork to ensure + # there are no race conditions between the parent + # process and its children + # for the pooled TCP connections. + # + # Child processes that make multi-threaded calls to the SDK should block on + # this call before beginning work. + # + # @return [nil] + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#193 + def empty_connection_pools!; end + + # @see (Aws::Partitions.partition) + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#150 + def partition(partition_name); end + + # @see (Aws::Partitions.partitions) + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#155 + def partitions; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#131 + def shared_config; end + + # The SDK ships with a ca certificate bundle to use when verifying SSL + # peer certificates. By default, this cert bundle is *NOT* used. The + # SDK will rely on the default cert available to OpenSSL. This ensures + # the cert provided by your OS is used. + # + # For cases where the default cert is unavailable, e.g. Windows, you + # can call this method. + # + # Aws.use_bundled_cert! + # + # @return [String] Returns the path to the bundled cert. + # + # source://aws-sdk-core//lib/aws-sdk-core.rb#170 + def use_bundled_cert!; end + end +end + +# Create and provide access to components of Amazon Resource Names (ARN). +# +# You can create an ARN and access it's components like the following: +# +# arn = Aws::ARN.new( +# partition: 'aws', +# service: 's3', +# region: 'us-west-2', +# account_id: '12345678910', +# resource: 'foo/bar' +# ) +# # => # +# +# arn.to_s +# # => "arn:aws:s3:us-west-2:12345678910:foo/bar" +# +# arn.partition +# # => 'aws' +# arn.service +# # => 's3' +# arn.resource +# # => foo/bar +# +# # Note: parser available for parsing resource details +# @see Aws::ARNParser#parse_resource +# +# @see https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-arns +# +# source://aws-sdk-core//lib/aws-sdk-core/arn.rb#31 +class Aws::ARN + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [ARN] a new instance of ARN + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#39 + def initialize(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#57 + def account_id; end + + # Return the ARN as JSON + # + # @return [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#95 + def as_json(_options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#48 + def partition; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#54 + def region; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#60 + def resource; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#51 + def service; end + + # Return the ARN as a hash + # + # @return [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#82 + def to_h; end + + # Return the ARN format in string + # + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#75 + def to_s; end + + # Validates ARN contains non-empty required components. + # Region and account_id can be optional. + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn.rb#66 + def valid?; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/arn_parser.rb#4 +module Aws::ARNParser + class << self + # Checks whether a String could be a ARN or not. An ARN starts with 'arn:' + # and has at least 6 segments separated by a colon (:). + # + # @param str [String] + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/arn_parser.rb#36 + def arn?(str); end + + # Parse a string with an ARN format into an {Aws::ARN} object. + # `InvalidARNError` would be raised when encountering a parsing error or the + # ARN object contains invalid components (nil/empty). + # + # @param arn_str [String] + # @raise [Aws::Errors::InvalidARNError] + # @return [Aws::ARN] + # @see https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-arns + # + # source://aws-sdk-core//lib/aws-sdk-core/arn_parser.rb#13 + def parse(arn_str); end + end +end + +# An auto-refreshing credential provider that assumes a role via +# {Aws::STS::Client#assume_role}. +# +# role_credentials = Aws::AssumeRoleCredentials.new( +# client: Aws::STS::Client.new(...), +# role_arn: "linked::account::arn", +# role_session_name: "session-name" +# ) +# ec2 = Aws::EC2::Client.new(credentials: role_credentials) +# +# If you omit `:client` option, a new {Aws::STS::Client} object will be +# constructed with additional options that were provided. +# +# @see Aws::STS::Client#assume_role +# +# source://aws-sdk-core//lib/aws-sdk-core/assume_role_credentials.rb#20 +class Aws::AssumeRoleCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [AssumeRoleCredentials] a new instance of AssumeRoleCredentials + # + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_credentials.rb#41 + def initialize(options = T.unsafe(nil)); end + + # @return [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_credentials.rb#60 + def assume_role_params; end + + # @return [STS::Client] + # + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_credentials.rb#57 + def client; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_credentials.rb#64 + def refresh; end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_credentials.rb#77 + def assume_role_options; end + end +end + +# An auto-refreshing credential provider that assumes a role via +# {Aws::STS::Client#assume_role_with_web_identity}. +# +# role_credentials = Aws::AssumeRoleWebIdentityCredentials.new( +# client: Aws::STS::Client.new(...), +# role_arn: "linked::account::arn", +# web_identity_token_file: "/path/to/token/file", +# role_session_name: "session-name" +# ... +# ) +# ec2 = Aws::EC2::Client.new(credentials: role_credentials) +# +# If you omit `:client` option, a new {Aws::STS::Client} object will be +# constructed with additional options that were provided. +# +# @see Aws::STS::Client#assume_role_with_web_identity +# +# source://aws-sdk-core//lib/aws-sdk-core/assume_role_web_identity_credentials.rb#24 +class Aws::AssumeRoleWebIdentityCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [AssumeRoleWebIdentityCredentials] a new instance of AssumeRoleWebIdentityCredentials + # + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_web_identity_credentials.rb#46 + def initialize(options = T.unsafe(nil)); end + + # @return [STS::Client] + # + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_web_identity_credentials.rb#68 + def client; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_web_identity_credentials.rb#93 + def _session_name; end + + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_web_identity_credentials.rb#86 + def _token_from_file(path); end + + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_web_identity_credentials.rb#72 + def refresh; end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/assume_role_web_identity_credentials.rb#100 + def assume_role_web_identity_options; end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#4 +module Aws::AsyncClientStubs + include ::Aws::ClientStubs + + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#43 + def send_events; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#9 + def setup_stubbing; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#53 +class Aws::AsyncClientStubs::StubStream + # @return [StubStream] a new instance of StubStream + # + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#55 + def initialize; end + + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#77 + def close; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#73 + def closed?; end + + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#63 + def data(bytes, options = T.unsafe(nil)); end + + # Returns the value of attribute send_events. + # + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#59 + def send_events; end + + # Sets the attribute send_events + # + # @param value the value to set the attribute send_events to. + # + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#59 + def send_events=(_arg0); end + + # Returns the value of attribute state. + # + # source://aws-sdk-core//lib/aws-sdk-core/async_client_stubs.rb#61 + def state; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/binary/decode_handler.rb#4 +module Aws::Binary; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/binary/decode_handler.rb#7 +class Aws::Binary::DecodeHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/decode_handler.rb#9 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/decode_handler.rb#24 + def attach_eventstream_listeners(context, rules); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/decode_handler.rb#18 + def eventstream?(ctx); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/binary/encode_handler.rb#7 +class Aws::Binary::EncodeHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/encode_handler.rb#9 + def call(context); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/encode_handler.rb#36 + def eventstream_input?(ctx); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/encode_handler.rb#25 + def signer_for(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/binary/event_builder.rb#6 +class Aws::Binary::EventBuilder + include ::Seahorse::Model::Shapes + + # @api private + # @param serializer_class [Class] + # @param rules [Seahorse::Model::ShapeRef] (of eventstream member) + # @return [EventBuilder] a new instance of EventBuilder + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_builder.rb#12 + def initialize(serializer_class, rules); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_builder.rb#17 + def apply(event_type, params); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_builder.rb#24 + def _event_stream_message(event_ref, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_builder.rb#116 + def build_payload_members(payload_ref, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_builder.rb#87 + def content_type(shape); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_builder.rb#103 + def header_value_type(shape, value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#6 +class Aws::Binary::EventParser + include ::Seahorse::Model::Shapes + + # @api private + # @param parser_class [Class] + # @param rules [Seahorse::Model::ShapeRef] (of eventstream member) + # @param error_refs [Array] array of errors ShapeRef + # @param output_ref [Seahorse::Model::ShapeRef] + # @return [EventParser] a new instance of EventParser + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#14 + def initialize(parser_class, rules, error_refs, output_ref); end + + # Parse raw event message into event struct + # based on its ShapeRef + # + # @api private + # @return [Struct] Event Struct + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#25 + def apply(raw_event); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#125 + def eventpayload_streaming?(ref); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#31 + def parse(raw_event); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#60 + def parse_error_event(raw_event); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#70 + def parse_event(raw_event); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#51 + def parse_exception(raw_event); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_parser.rb#129 + def parse_payload(body, rules); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_decoder.rb#8 +class Aws::Binary::EventStreamDecoder + # that registered with callbacks for processing events when they arrive + # + # @api private + # @param protocol [String] + # @param rules [ShapeRef] ShapeRef of the eventstream member + # @param output_ref [ShapeRef] ShapeRef of output shape + # @param error_refs [Array] array of ShapeRefs for errors + # @param event_stream_handler [EventStream|nil] A Service EventStream object + # @return [EventStreamDecoder] a new instance of EventStreamDecoder + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_decoder.rb#16 + def initialize(protocol, rules, output_ref, error_refs, io, event_stream_handler = T.unsafe(nil)); end + + # @api private + # @return [Array] events Array of arrived event objects + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_decoder.rb#25 + def events; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_decoder.rb#27 + def write(chunk); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_decoder.rb#39 + def emit_event(raw_event); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_decoder.rb#55 + def extract_stream_class(type_class); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_decoder.rb#45 + def parser_class(protocol); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_encoder.rb#8 +class Aws::Binary::EventStreamEncoder + # @api private + # @param protocol [String] + # @param rules [ShapeRef] ShapeRef of the eventstream member + # @param input_ref [ShapeRef] ShapeRef of the input shape + # @param signer [Aws::Sigv4::Signer] + # @return [EventStreamEncoder] a new instance of EventStreamEncoder + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_encoder.rb#14 + def initialize(protocol, rules, input_ref, signer); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_encoder.rb#27 + def encode(event_type, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_encoder.rb#25 + def prior_signature; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_encoder.rb#25 + def prior_signature=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_encoder.rb#23 + def rules; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/binary/event_stream_encoder.rb#44 + def serializer_class(protocol); end +end + +# source://aws-sdk-core//lib/aws-sdk-core.rb#124 +Aws::CORE_GEM_VERSION = T.let(T.unsafe(nil), String) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#5 +module Aws::Cbor + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#74 + def decode(bytes); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#70 + def encode(data); end + + # @api private + # @return [Class] Returns the default engine. + # One of: + # + # * {CborEngine} + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#65 + def engine; end + + # @api private + # @param engine [Symbol, Class] Must be one of the following values: + # + # * :cbor + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#56 + def engine=(engine); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#79 + def set_default_engine; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#91 + def load_engine(name); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#97 + def try_load_engine(name); end + end +end + +# Pure Ruby implementation of CBOR encode and decode +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/cbor_engine.rb#9 +module Aws::Cbor::CborEngine + class << self + # source://aws-sdk-core//lib/aws-sdk-core/cbor/cbor_engine.rb#14 + def decode(bytes); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/cbor_engine.rb#10 + def encode(data); end + end +end + +# Pure Ruby implementation of CBOR Decoder +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#6 +class Aws::Cbor::Decoder + # @return [Decoder] a new instance of Decoder + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#7 + def initialize(bytes); end + + # @raise [ExtraBytesError] + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#12 + def decode; end + + private + + # high level, generic decode. Based on the next type. Consumes and returns + # the next item as a ruby object. + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#31 + def decode_item; end + + # @raise [OutOfBytesError] + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#303 + def peek(n_bytes); end + + # low level streaming interface + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#83 + def peek_type; end + + # returns only the length of the array, caller must read the correct number of values after this + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#142 + def read_array; end + + # A decimal fraction or a bigfloat is represented as a tagged array + # that contains exactly two integer numbers: + # an exponent e and a mantissa m + # See: https://www.rfc-editor.org/rfc/rfc8949.html#name-decimal-fractions-and-bigfl + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#265 + def read_big_decimal; end + + # tag type 2 or 3 + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#244 + def read_bignum(tag_value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#131 + def read_binary_string; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#182 + def read_boolean; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#113 + def read_break_stop_code; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#281 + def read_count(add_info); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#238 + def read_double; end + + # returns nothing but consumes and checks the type/info. + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#160 + def read_end_indefinite_collection; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#233 + def read_float; end + + # 16 bit IEEE 754 half-precision floats + # Support decoding only + # format: + # sign - 1 bit + # exponent - 5 bits + # precision - 10 bits + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#210 + def read_half; end + + # return a tuple of major_type, add_info + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#276 + def read_info; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#118 + def read_integer; end + + # returns only the length of the array, caller must read the correct number of key value pairs after this + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#165 + def read_map; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#194 + def read_nil; end + + # @raise [Error] + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#176 + def read_reserved_undefined; end + + # returns nothing but consumes and checks the type/info. + # Caller must keep reading until encountering the stop sequence + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#149 + def read_start_indefinite_array; end + + # returns nothing but consumes and checks the type/info. + # Caller must keep reading until encountering the stop sequence + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#155 + def read_start_indefinite_map; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#136 + def read_string; end + + # returns only the tag, caller must interpret the tag and read another value as appropriate + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#171 + def read_tag; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#199 + def read_undefined; end + + # @raise [OutOfBytesError] + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#294 + def take(n_bytes); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#23 +Aws::Cbor::Decoder::FIVE_BIT_MASK = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#27 +Aws::Cbor::Decoder::TAG_TYPE_BIGDEC = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#25 +Aws::Cbor::Decoder::TAG_TYPE_BIGNUM = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#24 +Aws::Cbor::Decoder::TAG_TYPE_EPOCH = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-core//lib/aws-sdk-core/cbor/decoder.rb#26 +Aws::Cbor::Decoder::TAG_TYPE_NEG_BIGNUM = T.let(T.unsafe(nil), Integer) + +# Pure ruby implementation of CBOR encoder. +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#8 +class Aws::Cbor::Encoder + # @return [Encoder] a new instance of Encoder + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#9 + def initialize; end + + # generic method for adding generic Ruby data based on its type + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#19 + def add(value); end + + # @return the encoded bytes in CBOR format for all added data + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#14 + def bytes; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#167 + def add_auto_float(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#140 + def add_auto_integer(value); end + + # A decimal fraction or a bigfloat is represented as a tagged array + # that contains exactly two integer numbers: + # an exponent e and a mantissa m + # decimal fractions are always represented with a base of 10 + # See: https://www.rfc-editor.org/rfc/rfc8949.html#name-decimal-fractions-and-bigfl + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#123 + def add_big_decimal(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#104 + def add_bignum(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#184 + def add_boolean(value); end + + # Encoding MUST already be Encoding::BINARY + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#189 + def add_byte_string(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#163 + def add_double(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#159 + def add_float(value); end + + # streaming style, lower level interface + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#93 + def add_integer(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#180 + def add_nil; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#194 + def add_string(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#223 + def add_tag(tag); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#227 + def add_time(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#233 + def bignum_to_bytes(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#218 + def end_indefinite_collection; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#74 + def head(major_type, value); end + + # caller is responsible for adding length values + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#201 + def start_array(length); end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#205 + def start_indefinite_array; end + + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#214 + def start_indefinite_map; end + + # caller is responsible for adding length key/value pairs + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#210 + def start_map(length); end +end + +# 111_ 11011 - Major type 7 (Float) + value: 26 +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#65 +Aws::Cbor::Encoder::DOUBLE_BYTES = T.let(T.unsafe(nil), Integer) + +# 111_11010 - Major type 7 (Float) + value: 26 +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#64 +Aws::Cbor::Encoder::FLOAT_BYTES = T.let(T.unsafe(nil), Integer) + +# 100_00000 - Major Type 4 (Array) +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#59 +Aws::Cbor::Encoder::MAJOR_TYPE_ARRAY = T.let(T.unsafe(nil), Integer) + +# 010_00000 - Major Type 2 (Byte String) +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#57 +Aws::Cbor::Encoder::MAJOR_TYPE_BYTE_STR = T.let(T.unsafe(nil), Integer) + +# 101_00000 - Major Type 5 (Map) +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#60 +Aws::Cbor::Encoder::MAJOR_TYPE_MAP = T.let(T.unsafe(nil), Integer) + +# 001_00000 - Major Type 1 - negative int +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#56 +Aws::Cbor::Encoder::MAJOR_TYPE_NEGATIVE_INT = T.let(T.unsafe(nil), Integer) + +# 111_00000 - Major type 7 (111) + 5 bit 0 +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#62 +Aws::Cbor::Encoder::MAJOR_TYPE_SIMPLE = T.let(T.unsafe(nil), Integer) + +# 011_00000 - Major Type 3 (Text String) +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#58 +Aws::Cbor::Encoder::MAJOR_TYPE_STR = T.let(T.unsafe(nil), Integer) + +# 110_00000 - Major type 6 (Tag) +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#61 +Aws::Cbor::Encoder::MAJOR_TYPE_TAG = T.let(T.unsafe(nil), Integer) + +# 000_00000 - Major Type 0 - unsigned int +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#55 +Aws::Cbor::Encoder::MAJOR_TYPE_UNSIGNED_INT = T.let(T.unsafe(nil), Integer) + +# 2^64 +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#72 +Aws::Cbor::Encoder::MAX_INTEGER = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#69 +Aws::Cbor::Encoder::TAG_BIGNUM_BASE = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#70 +Aws::Cbor::Encoder::TAG_TYPE_BIGDEC = T.let(T.unsafe(nil), Integer) + +# https://www.rfc-editor.org/rfc/rfc8949.html#tags +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor/encoder.rb#68 +Aws::Cbor::Encoder::TAG_TYPE_EPOCH = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#22 +class Aws::Cbor::Error < ::StandardError; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#36 +class Aws::Cbor::ExtraBytesError < ::Aws::Cbor::Error + # @api private + # @return [ExtraBytesError] a new instance of ExtraBytesError + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#37 + def initialize(pos, size); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#24 +class Aws::Cbor::OutOfBytesError < ::Aws::Cbor::Error + # @api private + # @return [OutOfBytesError] a new instance of OutOfBytesError + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#25 + def initialize(n, left); end +end + +# CBOR Tagged data (Major type 6). +# A Tag consists of a tag number and a value. +# In the extended generic data model, a tag number's definition +# describes the additional semantics conveyed with the tag number. +# # @!method initialize(*args) +# @option args [Integer] :tag The tag number. +# @option args [Object] :value The tag's content. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#20 +class Aws::Cbor::Tagged < ::Struct + # The tag number. + # + # @return [Integer] + def tag; end + + # The tag number. + # + # @return [Integer] + def tag=(_); end + + # The tag's content. + # + # @return [Object] + def value; end + + # The tag's content. + # + # @return [Object] + def value=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#44 +class Aws::Cbor::UnexpectedAdditionalInformationError < ::Aws::Cbor::Error + # @api private + # @return [UnexpectedAdditionalInformationError] a new instance of UnexpectedAdditionalInformationError + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#45 + def initialize(add_info); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#42 +class Aws::Cbor::UnexpectedBreakCodeError < ::Aws::Cbor::Error; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#30 +class Aws::Cbor::UnknownTypeError < ::Aws::Cbor::Error + # @api private + # @return [UnknownTypeError] a new instance of UnknownTypeError + # + # source://aws-sdk-core//lib/aws-sdk-core/cbor.rb#31 + def initialize(type); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#4 +module Aws::ClientSideMonitoring; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#9 +class Aws::ClientSideMonitoring::Publisher + # @api private + # @return [Publisher] a new instance of Publisher + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#13 + def initialize(opts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#11 + def agent_host; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#25 + def agent_host=(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#10 + def agent_port; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#19 + def agent_port=(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#31 + def publish(request_metrics); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/publisher.rb#38 + def send_datagram(msg); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#6 +class Aws::ClientSideMonitoring::RequestMetrics + # @api private + # @return [RequestMetrics] a new instance of RequestMetrics + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#22 + def initialize(opts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#54 + def add_call_attempt(attempt); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#7 + def api_call; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#7 + def api_call_attempts; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#33 + def build_call_attempt(opts = T.unsafe(nil)); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#58 +class Aws::ClientSideMonitoring::RequestMetrics::ApiCall + # @api private + # @return [ApiCall] a new instance of ApiCall + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#65 + def initialize(service, api, client_id, version, timestamp, region); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def api; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def attempt_count; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def client_id; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#74 + def complete(opts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def final_aws_exception; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def final_aws_exception_message; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def final_http_status_code; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def final_sdk_exception; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def final_sdk_exception_message; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def latency; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def max_retries_exceeded; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def region; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def service; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def timestamp; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#91 + def to_json(*a); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def user_agent; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#59 + def version; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#115 + def _truncate(document); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#126 +class Aws::ClientSideMonitoring::RequestMetrics::ApiCallAttempt + # @api private + # @return [ApiCallAttempt] a new instance of ApiCallAttempt + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#133 + def initialize(service, api, client_id, version, timestamp, fqdn, region, user_agent, access_key, session_token); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def access_key; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def api; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def aws_exception; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def aws_exception=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def aws_exception_msg; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def aws_exception_msg=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def client_id; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def fqdn; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def fqdn=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def http_status_code; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def http_status_code=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def region; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def region=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def request_latency; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def request_latency=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def sdk_exception; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def sdk_exception=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def sdk_exception_msg; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def sdk_exception_msg=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def service; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def session_token; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def timestamp; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#157 + def to_json(*a); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def user_agent; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#127 + def version; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def x_amz_id_2; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def x_amz_id_2=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def x_amz_request_id; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def x_amz_request_id=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def x_amzn_request_id; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#129 + def x_amzn_request_id=(_arg0); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#186 + def _truncate(document); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/client_side_monitoring/request_metrics.rb#9 +Aws::ClientSideMonitoring::RequestMetrics::FIELD_MAX_LENGTH = T.let(T.unsafe(nil), Hash) + +# This module provides the ability to specify the data and/or errors to +# return when a client is using stubbed responses. Pass +# `:stub_responses => true` to a client constructor to enable this +# behavior. +# +# Also allows you to see the requests made by the client by reading the +# api_requests instance variable +# +# source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#14 +module Aws::ClientStubs + # Allows you to access all of the requests that the stubbed client has made. + # + # @option options + # @param options [Hash] The options for the api requests. + # @raise [NotImplementedError] Raises `NotImplementedError` when the client + # is not stubbed. + # @return [Array] Returns an array of the api requests made. Each request + # object contains the :operation_name, :params, and :context. + # + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#196 + def api_requests(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#235 + def next_stub(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#17 + def setup_stubbing; end + + # Generates and returns stubbed response data from the named operation. + # + # s3 = Aws::S3::Client.new + # s3.stub_data(:list_buckets) + # #=> #> + # + # In addition to generating default stubs, you can provide data to + # apply to the response stub. + # + # s3.stub_data(:list_buckets, buckets:[{name:'aws-sdk'}]) + # #=> #], + # owner=#> + # + # @param operation_name [Symbol] + # @param data [Hash] + # @return [Structure] Returns a stubbed response data structure. The + # actual class returned will depend on the given `operation_name`. + # + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#230 + def stub_data(operation_name, data = T.unsafe(nil)); end + + # Configures what data / errors should be returned from the named operation + # when response stubbing is enabled. + # + # ## Basic usage + # + # When you enable response stubbing, the client will generate fake + # responses and will not make any HTTP requests. + # + # client = Aws::S3::Client.new(stub_responses: true) + # client.list_buckets + # #=> # + # + # You can provide stub data that will be returned by the client. + # + # # stub data in the constructor + # client = Aws::S3::Client.new(stub_responses: { + # list_buckets: { buckets: [{name: 'my-bucket' }] }, + # get_object: { body: 'data' }, + # }) + # + # client.list_buckets.buckets.map(&:name) #=> ['my-bucket'] + # client.get_object(bucket:'name', key:'key').body.read #=> 'data' + # + # You can also specify the stub data using {#stub_responses} + # + # client = Aws::S3::Client.new(stub_responses: true) + # client.stub_responses(:list_buckets, { + # buckets: [{ name: 'my-bucket' }] + # }) + # + # client.list_buckets.buckets.map(&:name) + # #=> ['my-bucket'] + # + # With a Resource class {#stub_responses} on the corresponding client: + # + # s3 = Aws::S3::Resource.new(stub_responses: true) + # s3.client.stub_responses(:list_buckets, { + # buckets: [{ name: 'my-bucket' }] + # }) + # + # s3.buckets.map(&:name) + # #=> ['my-bucket'] + # + # Lastly, default stubs can be configured via `Aws.config`: + # + # Aws.config[:s3] = { + # stub_responses: { + # list_buckets: { buckets: [{name: 'my-bucket' }] } + # } + # } + # + # Aws::S3::Client.new.list_buckets.buckets.map(&:name) + # #=> ['my-bucket'] + # + # Aws::S3::Resource.new.buckets.map(&:name) + # #=> ['my-bucket'] + # + # ## Dynamic Stubbing + # + # In addition to creating static stubs, it's also possible to generate + # stubs dynamically based on the parameters with which operations were + # called, by passing a `Proc` object: + # + # s3 = Aws::S3::Resource.new(stub_responses: true) + # s3.client.stub_responses(:put_object, -> (context) { + # s3.client.stub_responses(:get_object, content_type: context.params[:content_type]) + # }) + # + # The yielded object is an instance of {Seahorse::Client::RequestContext}. + # + # ## Stubbing Errors + # + # When stubbing is enabled, the SDK will default to generate + # fake responses with placeholder values. You can override the data + # returned. You can also specify errors it should raise. + # + # # simulate service errors, give the error code + # client.stub_responses(:get_object, 'NotFound') + # client.get_object(bucket:'aws-sdk', key:'foo') + # #=> raises Aws::S3::Errors::NotFound + # + # # to simulate other errors, give the error class, you must + # # be able to construct an instance with `.new` + # client.stub_responses(:get_object, Timeout::Error) + # client.get_object(bucket:'aws-sdk', key:'foo') + # #=> raises new Timeout::Error + # + # # or you can give an instance of an error class + # client.stub_responses(:get_object, RuntimeError.new('custom message')) + # client.get_object(bucket:'aws-sdk', key:'foo') + # #=> raises the given runtime error object + # + # ## Stubbing HTTP Responses + # + # As an alternative to providing the response data, you can provide + # an HTTP response. + # + # client.stub_responses(:get_object, { + # status_code: 200, + # headers: { 'header-name' => 'header-value' }, + # body: "...", + # }) + # + # To stub a HTTP response, pass a Hash with all three of the following + # keys set: + # + # * **`:status_code`** - - The HTTP status code + # * **`:headers`** - Hash - A hash of HTTP header keys and values + # * **`:body`** - - The HTTP response body. + # + # ## Stubbing Multiple Responses + # + # Calling an operation multiple times will return similar responses. + # You can configure multiple stubs and they will be returned in sequence. + # + # client.stub_responses(:head_object, [ + # 'NotFound', + # { content_length: 150 }, + # ]) + # + # client.head_object(bucket:'aws-sdk', key:'foo') + # #=> raises Aws::S3::Errors::NotFound + # + # resp = client.head_object(bucket:'aws-sdk', key:'foo') + # resp.content_length #=> 150 + # + # @param operation_name [Symbol] + # @param stubs [Mixed] One or more responses to return from the named + # operation. + # @raise [RuntimeError] Raises a runtime error when called + # on a client that has not enabled response stubbing via + # `:stub_responses => true`. + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#177 + def stub_responses(operation_name, *stubs); end + + private + + # This method converts the given stub data and converts it to a + # HTTP response (when possible). This enables the response stubbing + # plugin to provide a HTTP response that triggers all normal events + # during response handling. + # + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#259 + def apply_stubs(operation_name, stubs); end + + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#267 + def convert_stub(operation_name, stub); end + + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#301 + def data_to_http_resp(operation_name, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#250 + def default_stub(operation_name); end + + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#293 + def hash_to_http_resp(data); end + + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#285 + def http_response_stub(operation_name, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#308 + def protocol_helper; end + + # source://aws-sdk-core//lib/aws-sdk-core/client_stubs.rb#281 + def service_error_stub(error_code); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/credential_provider.rb#4 +module Aws::CredentialProvider + # @return [Credentials] + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider.rb#7 + def credentials; end + + # @return [Time] + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider.rb#10 + def expiration; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider.rb#13 + def set?; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#5 +class Aws::CredentialProviderChain + # @api private + # @return [CredentialProviderChain] a new instance of CredentialProviderChain + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#6 + def initialize(config = T.unsafe(nil)); end + + # @api private + # @return [CredentialProvider, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#11 + def resolve; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#137 + def assume_role_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#143 + def assume_role_web_identity_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#172 + def assume_role_with_profile(options, profile_name); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#107 + def determine_profile_name(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#93 + def env_credentials(_options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#100 + def envar(keys); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#162 + def instance_profile_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#118 + def process_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#21 + def providers; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#111 + def shared_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#128 + def sso_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#43 + def static_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#70 + def static_profile_assume_role_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#53 + def static_profile_assume_role_web_identity_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#76 + def static_profile_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#84 + def static_profile_process_credentials(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credential_provider_chain.rb#62 + def static_profile_sso_credentials(options); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#4 +class Aws::Credentials + # @param access_key_id [String] + # @param secret_access_key [String] + # @param session_token [String] (nil) + # @return [Credentials] a new instance of Credentials + # + # source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#9 + def initialize(access_key_id, secret_access_key, session_token = T.unsafe(nil)); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#16 + def access_key_id; end + + # @return [Credentials] + # + # source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#25 + def credentials; end + + # Removing the secret access key from the default inspect string. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#40 + def inspect; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#19 + def secret_access_key; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#22 + def session_token; end + + # @return [Boolean] Returns `true` if the access key id and secret + # access key are both set. + # + # source://aws-sdk-core//lib/aws-sdk-core/credentials.rb#31 + def set?; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#5 +class Aws::DefaultsModeConfigResolver + # @api private + # @return [DefaultsModeConfigResolver] a new instance of DefaultsModeConfigResolver + # + # source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#22 + def initialize(sdk_defaults, cfg); end + + # option_name should be the symbolized ruby name to resolve + # returns the ruby appropriate value or nil if none are resolved + # + # @api private + # + # source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#31 + def resolve(option_name); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#65 + def application_current_region; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#102 + def env_mobile?; end + + # @api private + # + # source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#52 + def resolve_auto_mode; end + + # @api private + # + # source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#88 + def resolve_for_mode(name, mode); end + + # @api private + # + # source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#44 + def resolved_mode; end +end + +# mappings from Ruby SDK configuration names to the +# sdk defaults option names and (optional) scale modifiers +# +# @api private +# +# source://aws-sdk-core//lib/aws-defaults/defaults_mode_config_resolver.rb#13 +Aws::DefaultsModeConfigResolver::CFG_OPTIONS = T.let(T.unsafe(nil), Hash) + +# A defaults mode determines how certain default configuration options are resolved in the SDK. +# +# *Note*: For any mode other than `'legacy'` the vended default values might change as best practices may +# evolve. As a result, it is encouraged to perform testing when upgrading the SDK if you are using a mode other than +# `'legacy'`. While the `'legacy'` defaults mode is specific to Ruby, +# other modes are standardized across all of the AWS SDKs. +# +# The defaults mode can be configured: +# +# * Directly on a client via `:defaults_mode` +# +# * On a configuration profile via the "defaults_mode" profile file property. +# +# * Globally via the "AWS_DEFAULTS_MODE" environment variable. +# +# +# #defaults START - documentation +# The following `:default_mode` values are supported: +# +# * `'standard'` - +# The STANDARD mode provides the latest recommended default values +# that should be safe to run in most scenarios +# +# Note that the default values vended from this mode might change as +# best practices may evolve. As a result, it is encouraged to perform +# tests when upgrading the SDK +# +# * `'in-region'` - +# The IN\_REGION mode builds on the standard mode and includes +# optimization tailored for applications which call AWS services from +# within the same AWS region +# +# Note that the default values vended from this mode might change as +# best practices may evolve. As a result, it is encouraged to perform +# tests when upgrading the SDK +# +# * `'cross-region'` - +# The CROSS\_REGION mode builds on the standard mode and includes +# optimization tailored for applications which call AWS services in a +# different region +# +# Note that the default values vended from this mode might change as +# best practices may evolve. As a result, it is encouraged to perform +# tests when upgrading the SDK +# +# * `'mobile'` - +# The MOBILE mode builds on the standard mode and includes +# optimization tailored for mobile applications +# +# Note that the default values vended from this mode might change as +# best practices may evolve. As a result, it is encouraged to perform +# tests when upgrading the SDK +# +# * `'auto'` - +# The AUTO mode is an experimental mode that builds on the standard +# mode. The SDK will attempt to discover the execution environment to +# determine the appropriate settings automatically. +# +# Note that the auto detection is heuristics-based and does not +# guarantee 100% accuracy. STANDARD mode will be used if the execution +# environment cannot be determined. The auto detection might query +# [EC2 Instance Metadata service][1], which might introduce latency. +# Therefore we recommend choosing an explicit defaults\_mode instead +# if startup latency is critical to your application +# +# * `'legacy'` - +# The LEGACY mode provides default settings that vary per SDK and were +# used prior to establishment of defaults\_mode +# +# Based on the provided mode, the SDK will vend sensible default values +# tailored to the mode for the following settings: +# +# * `:retry_mode` - +# A retry mode specifies how the SDK attempts retries. See [Retry +# Mode][2] +# +# * `:sts_regional_endpoints` - +# Specifies how the SDK determines the AWS service endpoint that it +# uses to talk to the AWS Security Token Service (AWS STS). See +# [Setting STS Regional endpoints][3] +# +# * `:s3_us_east_1_regional_endpoint` - +# Specifies how the SDK determines the AWS service endpoint that it +# uses to talk to the Amazon S3 for the us-east-1 region +# +# * `:http_open_timeout` - +# The amount of time after making an initial connection attempt on a +# socket, where if the client does not receive a completion of the +# connect handshake, the client gives up and fails the operation +# +# * `:ssl_timeout` - +# The maximum amount of time that a TLS handshake is allowed to take +# from the time the CLIENT HELLO message is sent to ethe time the +# client and server have fully negotiated ciphers and exchanged keys +# +# All options above can be configured by users, and the overridden value will take precedence. +# +# [1]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html +# [2]: https://docs.aws.amazon.com/sdkref/latest/guide/setting-global-retry_mode.html +# [3]: https://docs.aws.amazon.com/sdkref/latest/guide/setting-global-sts_regional_endpoints.html +# +# #defaults END - documentation +# +# source://aws-sdk-core//lib/aws-defaults/default_configuration.rb#109 +module Aws::DefaultsModeConfiguration; end + +# #defaults START - configuration +# +# @api private +# +# source://aws-sdk-core//lib/aws-defaults/default_configuration.rb#112 +Aws::DefaultsModeConfiguration::SDK_DEFAULT_CONFIGURATION = T.let(T.unsafe(nil), Hash) + +# A utility module that provides a class method that wraps +# a method such that it generates a deprecation warning when called. +# Given the following class: +# +# class Example +# +# def do_something +# end +# +# end +# +# If you want to deprecate the `#do_something` method, you can extend +# this module and then call `deprecated` on the method (after it +# has been defined). +# +# class Example +# +# extend Aws::Deprecations +# +# def do_something +# end +# +# def do_something_else +# end +# +# deprecated :do_something +# +# end +# +# The `#do_something` method will continue to function, but will +# generate a deprecation warning when called. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/deprecations.rb#38 +module Aws::Deprecations + # @api private + # @option options + # @option options + # @option options + # @param method [Symbol] The name of the deprecated method. + # @param options [Hash] a customizable set of options + # + # source://aws-sdk-core//lib/aws-sdk-core/deprecations.rb#50 + def deprecated(method, options = T.unsafe(nil)); end +end + +# A client that can query version 2 of the EC2 Instance Metadata +# +# source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#8 +class Aws::EC2Metadata + # Creates a client that can query version 2 of the EC2 Instance Metadata + # service (IMDS). + # + # @note Customers using containers may need to increase their hop limit + # to access IMDSv2. + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [EC2Metadata] a new instance of EC2Metadata + # @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/configuring-instance-metadata-service.html#instance-metadata-transition-to-version-2 + # + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#57 + def initialize(options = T.unsafe(nil)); end + + # Fetches a given metadata category using a String path, and returns the + # result as a String. A path starts with the API version (usually + # "/latest/"). See the instance data categories for possible paths. + # + # @example Fetching the instance ID + # + # ec2_metadata = Aws::EC2Metadata.new + # ec2_metadata.get('/latest/meta-data/instance-id') + # => "i-023a25f10a73a0f79" + # @example Fetching and parsing JSON meta-data + # + # require 'json' + # data = ec2_metadata.get('/latest/dynamic/instance-identity/document') + # JSON.parse(data) + # => {"accountId"=>"012345678912", ... } + # @example Fetching and parsing directory listings + # + # listing = ec2_metadata.get('/latest/meta-data') + # listing.split(10.chr) + # => ["ami-id", "ami-launch-index", ...] + # @note This implementation always returns a String and will not parse any + # responses. Parsable responses may include JSON objects or directory + # listings, which are strings separated by line feeds (ASCII 10). + # @note Unlike other services, IMDS does not have a service API model. This + # means that we cannot confidently generate code with methods and + # response structures. This implementation ensures that new IMDS features + # are always supported by being deployed to the instance and does not + # require code changes. + # @param path [String] The full path to the metadata. + # @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instancedata-data-categories.html + # @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-identity-documents.html + # + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#110 + def get(path); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#213 + def backoff(backoff); end + + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#137 + def fetch_token; end + + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#145 + def http_get(connection, path, token); end + + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#163 + def http_put(connection, ttl); end + + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#184 + def open_connection; end + + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#124 + def resolve_endpoint(endpoint, endpoint_mode); end + + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#194 + def retry_errors(options = T.unsafe(nil), &_block); end +end + +# Path for PUT request for token +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#11 +Aws::EC2Metadata::METADATA_TOKEN_PATH = T.let(T.unsafe(nil), String) + +# The requested metadata path does not exist. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#24 +class Aws::EC2Metadata::MetadataNotFoundError < ::RuntimeError; end + +# The request is not allowed or IMDS is turned off. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#28 +class Aws::EC2Metadata::RequestForbiddenError < ::RuntimeError; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#222 +class Aws::EC2Metadata::Token + # @api private + # @return [Token] a new instance of Token + # + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#223 + def initialize(options = T.unsafe(nil)); end + + # [Boolean] Returns true if the token expired. + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#233 + def expired?; end + + # [String] Returns the token value. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#230 + def value; end +end + +# Token has expired, and the request can be retried with a new token. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#20 +class Aws::EC2Metadata::TokenExpiredError < ::RuntimeError; end + +# Raised when the PUT request is not valid. This would be thrown if +# `token_ttl` is not an Integer. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ec2_metadata.rb#16 +class Aws::EC2Metadata::TokenRetrievalError < ::RuntimeError; end + +# An auto-refreshing credential provider that loads credentials from +# instances running in containers. +# +# ecs_credentials = Aws::ECSCredentials.new(retries: 3) +# ec2 = Aws::EC2::Client.new(credentials: ecs_credentials) +# +# source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#13 +class Aws::ECSCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [ECSCredentials] a new instance of ECSCredentials + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#67 + def initialize(options = T.unsafe(nil)); end + + # @return [Integer] The number of times to retry failed attempts to + # fetch credentials from the instance metadata service. Defaults to 0. + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#85 + def retries; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#173 + def backoff(backoff); end + + # Verify that the IP address is a link-local address from ECS or EKS. + # ECS container host (IPv4 `169.254.170.2`) + # EKS container host (IPv4 `169.254.170.23`, IPv6 `fd00:ec2::23`) + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#162 + def ecs_or_eks_ip?(ip_address); end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#215 + def fetch_authorization_token; end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#223 + def fetch_authorization_token_file(path); end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#199 + def get_credentials; end + + # @raise [Non200Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#249 + def http_get(connection, path); end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#109 + def initialize_full_uri(endpoint); end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#102 + def initialize_relative_uri(options, path); end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#89 + def initialize_uri(options, credential_path, endpoint); end + + # loopback? method is available in Ruby 2.5+ + # Replicate the logic here. + # loopback (IPv4 127.0.0.0/8, IPv6 ::1/128) + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#148 + def ip_loopback?(ip_address); end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#239 + def open_connection; end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#181 + def refresh; end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#265 + def retry_errors(error_classes, options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#258 + def set_authorization_token(request); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#141 + def valid_ip_address?(ip_address); end + + # @raise [InvalidTokenError] + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#231 + def validate_authorization_token!(token); end + + # Validate that the full URI is using a loopback address if scheme is http. + # + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#126 + def validate_full_uri!(full_uri); end + + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#119 + def validate_full_uri_scheme!(full_uri); end +end + +# Raised when the token file is invalid. +# +# source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#24 +class Aws::ECSCredentials::InvalidTokenError < ::RuntimeError; end + +# These are the errors we trap when attempting to talk to the +# instance metadata service. Any of these imply the service +# is not present, no responding or some other non-recoverable +# error. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#31 +Aws::ECSCredentials::NETWORK_ERRORS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#18 +class Aws::ECSCredentials::Non200Response < ::RuntimeError; end + +# Raised when the token file cannot be read. +# +# source://aws-sdk-core//lib/aws-sdk-core/ecs_credentials.rb#21 +class Aws::ECSCredentials::TokenFileReadError < ::RuntimeError; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/eager_loader.rb#7 +class Aws::EagerLoader + # @api private + # @return [EagerLoader] a new instance of EagerLoader + # + # source://aws-sdk-core//lib/aws-sdk-core/eager_loader.rb#9 + def initialize; end + + # @api private + # @param klass_or_module [Module] + # @return [self] + # + # source://aws-sdk-core//lib/aws-sdk-core/eager_loader.rb#18 + def load(klass_or_module); end + + # @api private + # @return [Set] + # + # source://aws-sdk-core//lib/aws-sdk-core/eager_loader.rb#14 + def loaded; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/structure.rb#88 +class Aws::EmptyStructure < ::Struct + include ::Aws::Structure +end + +# a LRU cache caching endpoints data +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#6 +class Aws::EndpointCache + # @api private + # @return [EndpointCache] a new instance of EndpointCache + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#14 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @param key [String] + # @return [Endpoint] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#34 + def [](key); end + + # @api private + # @param key [String] + # @param value [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#48 + def []=(key, value); end + + # remove entry only + # + # @api private + # @param key [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#82 + def delete(key); end + + # kill the old polling thread and remove it from pool + # + # @api private + # @param key [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#90 + def delete_polling_thread(key); end + + # extract the key to be used in the cache from request context + # + # @api private + # @param ctx [RequestContext] + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#109 + def extract_key(ctx); end + + # checking whether an unexpired endpoint key exists in cache + # + # @api private + # @param key [String] + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#64 + def key?(key); end + + # @api private + # @return [Integer] Max size limit of cache + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#24 + def max_entries; end + + # @api private + # @return [Integer] Max count of polling threads + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#27 + def max_threads; end + + # return [Hash] Polling threads pool + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#30 + def pool; end + + # kill all polling threads + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#135 + def stop_polling!; end + + # checking whether an polling thread exist for the key + # + # @api private + # @param key [String] + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#76 + def threads_key?(key); end + + # update cache with requests (using service endpoint operation) + # to fetch endpoint list (with identifiers when available) + # + # @api private + # @param key [String] + # @param ctx [RequestContext] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#99 + def update(key, ctx); end + + # update polling threads pool + # param [String] key + # param [Thread] thread + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#126 + def update_polling_pool(key, thread); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#164 + def _endpoint_operation_identifier(ctx); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#142 + def _request_endpoint(ctx); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#172 +class Aws::EndpointCache::Endpoint + # @api private + # @return [Endpoint] a new instance of Endpoint + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#177 + def initialize(options); end + + # [String] valid URI address (with path) + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#184 + def address; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#186 + def expired?; end +end + +# default endpoint cache time, 1 minute +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#175 +Aws::EndpointCache::Endpoint::CACHE_PERIOD = T.let(T.unsafe(nil), Integer) + +# default cache entries limit +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#9 +Aws::EndpointCache::MAX_ENTRIES = T.let(T.unsafe(nil), Integer) + +# default max threads pool size +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoint_cache.rb#12 +Aws::EndpointCache::MAX_THREADS = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule.rb#4 +module Aws::Endpoints + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#27 + def resolve_auth_scheme(context, endpoint); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#93 + def default_api_auth(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#68 + def default_auth_scheme(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#124 + def legacy_default_api_authtype(context); end + + # Legacy auth resolution - looks for deprecated signatureVersion + # and authType traits. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#105 + def legacy_default_auth_scheme(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#42 + def merge_signing_defaults(auth_scheme, config); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#98 + def s3_or_s3v4_signature_version?(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#63 + def sigv4_name(config); end + end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#11 +class Aws::Endpoints::Condition + # @api private + # @return [Condition] a new instance of Condition + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#12 + def initialize(fn:, argv:, assign: T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#19 + def argv; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#20 + def assign; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#22 + def assigned; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#18 + def fn; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#24 + def match?(parameters, assigns); end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/condition.rb#30 + def from_json(conditions_json); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint.rb#5 +class Aws::Endpoints::Endpoint + # @return [Endpoint] a new instance of Endpoint + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint.rb#6 + def initialize(url:, properties: T.unsafe(nil), headers: T.unsafe(nil)); end + + # Returns the value of attribute headers. + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint.rb#14 + def headers; end + + # Returns the value of attribute properties. + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint.rb#13 + def properties; end + + # Returns the value of attribute url. + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint.rb#12 + def url; end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. # @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#10 +class Aws::Endpoints::EndpointRule < ::Aws::Endpoints::Rule + # @return [EndpointRule] a new instance of EndpointRule + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#11 + def initialize(conditions:, endpoint:, type: T.unsafe(nil), documentation: T.unsafe(nil)); end + + # Returns the value of attribute conditions. + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#20 + def conditions; end + + # Returns the value of attribute documentation. + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#22 + def documentation; end + + # Returns the value of attribute endpoint. + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#21 + def endpoint; end + + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#24 + def match(parameters, assigned = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#34 + def resolved_endpoint(parameters, assigns); end + + # Returns the value of attribute type. + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#19 + def type; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#48 + def resolve_headers(parameters, assigns); end + + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/endpoint_rule.rb#57 + def resolve_properties(obj, parameters, assigns); end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#11 +class Aws::Endpoints::ErrorRule < ::Aws::Endpoints::Rule + # @api private + # @return [ErrorRule] a new instance of ErrorRule + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#12 + def initialize(conditions:, type: T.unsafe(nil), error: T.unsafe(nil), documentation: T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#20 + def conditions; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#22 + def documentation; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#21 + def error; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#24 + def match(parameters, assigned = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#19 + def type; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/error_rule.rb#36 + def resolved_error(parameters, assigns); end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/function.rb#11 +class Aws::Endpoints::Function + # @api private + # @return [Function] a new instance of Function + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/function.rb#12 + def initialize(fn:, argv:); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/function.rb#18 + def argv; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/function.rb#20 + def call(parameters, assigns); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/function.rb#17 + def fn; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/function.rb#67 + def build_argv(argv_json); end +end + +# generic matcher functions for service endpoints +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#9 +module Aws::Endpoints::Matchers + class << self + # getAttr(value: Object | Array, path: string) Document + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#26 + def attr(value, path); end + + # aws.parseArn(value: string) Option + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#108 + def aws_parse_arn(value); end + + # aws.partition(value: string) Option + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#96 + def aws_partition(value); end + + # aws.isVirtualHostableS3Bucket(value: string, allowSubDomains: bool) bool + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#120 + def aws_virtual_hostable_s3_bucket?(value, allow_sub_domains = T.unsafe(nil)); end + + # booleanEquals(value1: bool, value2: bool) bool + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#65 + def boolean_equals?(value1, value2); end + + # not(value: bool) bool + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#21 + def not(bool); end + + # parseUrl(value: string) Option + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#75 + def parse_url(value); end + + # isSet(value: Option) bool + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#16 + def set?(value); end + + # stringEquals(value1: string, value2: string) bool + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#60 + def string_equals?(value1, value2); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#47 + def substring(input, start, stop, reverse); end + + # uriEncode(value: string) string + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#70 + def uri_encode(value); end + + # isValidHostLabel(value: string, allowSubDomains: bool) bool + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#82 + def valid_host_label?(value, allow_sub_domains = T.unsafe(nil)); end + end +end + +# Regex that extracts anything in square brackets +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/matchers.rb#11 +Aws::Endpoints::Matchers::BRACKET_REGEX = T.let(T.unsafe(nil), Regexp) + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/reference.rb#11 +class Aws::Endpoints::Reference + # @api private + # @return [Reference] a new instance of Reference + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/reference.rb#12 + def initialize(ref:); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/reference.rb#16 + def ref; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/reference.rb#18 + def resolve(parameters, assigns); end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule.rb#11 +class Aws::Endpoints::Rule + # Resolves a value that is a function, reference, or template string. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule.rb#13 + def resolve_value(value, parameters, assigns); end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule_set.rb#11 +class Aws::Endpoints::RuleSet + # @api private + # @return [RuleSet] a new instance of RuleSet + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule_set.rb#12 + def initialize(version:, service_id:, parameters:, rules:); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule_set.rb#21 + def parameters; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule_set.rb#22 + def rules; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule_set.rb#20 + def service_id; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule_set.rb#19 + def version; end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rule_set.rb#24 + def rules_from_json(rules_json); end + end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/rules_provider.rb#9 +class Aws::Endpoints::RulesProvider + # @api private + # @return [RulesProvider] a new instance of RulesProvider + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rules_provider.rb#10 + def initialize(rule_set); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rules_provider.rb#14 + def resolve_endpoint(parameters); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/rules_provider.rb#28 + def resolve_rules(parameters); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints.rb#24 +Aws::Endpoints::SUPPORTED_AUTH_TRAITS = T.let(T.unsafe(nil), Array) + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/templater.rb#13 +module Aws::Endpoints::Templater + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/templater.rb#15 + def resolve(string, parameters, assigns); end + + private + + # Checks both parameters and assigns hash for the referenced value + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/templater.rb#45 + def extract_value(key, parameters, assigns); end + + # Replaces the captured value with values from parameters or assign + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/templater.rb#27 + def replace(capture, parameters, assigns); end + end +end + +# This class is deprecated. It is used by the Runtime endpoint +# resolution approach. It has been replaced by a code generated +# approach in each service gem. It can be removed in a new +# major version. It has to exist because +# old service gems can use a new core version. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#11 +class Aws::Endpoints::TreeRule + # @api private + # @return [TreeRule] a new instance of TreeRule + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#12 + def initialize(conditions:, rules:, type: T.unsafe(nil), documentation: T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#20 + def conditions; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#22 + def documentation; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#21 + def error; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#24 + def match(parameters, assigned = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#19 + def type; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/tree_rule.rb#36 + def resolve_rules(parameters, assigns); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#9 +class Aws::Endpoints::URL + # @api private + # @raise [ArgumentError] + # @return [URL] a new instance of URL + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#10 + def initialize(url); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#31 + def as_json(_options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#26 + def authority; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#29 + def is_ip; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#28 + def normalized_path; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#27 + def path; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#25 + def scheme; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#43 + def _authority(url, uri); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/endpoints/url.rb#52 + def _is_ip(authority); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/error_handler.rb#4 +class Aws::ErrorHandler < ::Seahorse::Client::Handler + private + + # source://aws-sdk-core//lib/aws-sdk-core/error_handler.rb#18 + def build_error(context, code, message, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/error_handler.rb#8 + def error(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/error_handler.rb#23 + def http_status_error(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/error_handler.rb#27 + def http_status_error_code(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#4 +module Aws::Errors; end + +# Various plugins perform client-side checksums of responses. +# This error indicates a checksum failed. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#163 +class Aws::Errors::ChecksumError < ::RuntimeError; end + +# Raised when a client is constructed with Assume Role credentials, but +# the profile has both source_profile and credential_source. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#179 +class Aws::Errors::CredentialSourceConflictError < ::RuntimeError; end + +# This module is mixed into another module, providing dynamic +# error classes. Error classes all inherit from {ServiceError}. +# +# # creates and returns the class +# Aws::S3::Errors::MyNewErrorClass +# +# Since the complete list of possible AWS errors returned by services +# is not known, this allows us to create them as needed. This also +# allows users to rescue errors by class without them being concrete +# classes beforehand. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#346 +module Aws::Errors::DynamicErrors + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#353 + def const_missing(constant); end + + # Given the name of a service and an error code, this method + # returns an error class (that extends {ServiceError}. + # + # Aws::S3::Errors.error_class('NoSuchBucket').new + # #=> # + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#364 + def error_class(error_code); end + + private + + # Convert an error code to an error class name/constant. + # This requires filtering non-safe characters from the constant + # name and ensuring it begins with an uppercase letter. + # + # @api private + # @param error_code [String] + # @return [Symbol] Returns a symbolized constant name for the given + # `error_code`. + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#385 + def error_class_constant(error_code); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#407 + def error_const_set?(constant); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#394 + def set_error_constant(constant); end + + class << self + # @api private + # @private + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#348 + def extended(submodule); end + end +end + +# Rasied when endpoint discovery failed for operations +# that requires endpoints from endpoint discovery +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#73 +class Aws::Errors::EndpointDiscoveryError < ::RuntimeError + # @return [EndpointDiscoveryError] a new instance of EndpointDiscoveryError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#74 + def initialize(*args); end +end + +# Error event in an event stream which has event_type :error +# error code and error message can be retrieved when available. +# +# example usage: +# +# client.stream_foo(name: 'bar') do |event| +# stream.on_error_event do |event| +# puts "Error #{event.error_code}: #{event.error_message}" +# raise event +# end +# end +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#119 +class Aws::Errors::EventError < ::RuntimeError + # @return [EventError] a new instance of EventError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#121 + def initialize(event_type, code, message); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#131 + def error_code; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#134 + def error_message; end + + # @return [Symbol] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#128 + def event_type; end +end + +# Raise when EventStream Builder failed to build +# an event message with parameters provided +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#105 +class Aws::Errors::EventStreamBuilderError < ::RuntimeError; end + +# Raised when EventStream Parser failed to parse +# a raw event message +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#101 +class Aws::Errors::EventStreamParserError < ::RuntimeError; end + +# Raised when ARN string input doesn't follow the standard: +# https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-arns +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#140 +class Aws::Errors::InvalidARNError < ::RuntimeError; end + +# Raised when the partition of the ARN region is different than the +# partition of the :region configured on the service client. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#153 +class Aws::Errors::InvalidARNPartitionError < ::RuntimeError + # @return [InvalidARNPartitionError] a new instance of InvalidARNPartitionError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#154 + def initialize(*args); end +end + +# Raised when the region from the ARN string is different from the :region +# configured on the service client. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#144 +class Aws::Errors::InvalidARNRegionError < ::RuntimeError + # @return [InvalidARNRegionError] a new instance of InvalidARNRegionError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#145 + def initialize(*args); end +end + +# Raised when a client is constructed with Assume Role credentials using +# a credential_source, and that source type is unsupported. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#175 +class Aws::Errors::InvalidCredentialSourceError < ::RuntimeError; end + +# Raised when a credentials provider process returns a JSON +# payload with either invalid version number or malformed contents +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#208 +class Aws::Errors::InvalidProcessCredentialsPayload < ::RuntimeError; end + +# Raised when a client is contsructed and the region is not valid. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#249 +class Aws::Errors::InvalidRegionError < ::ArgumentError + # @return [InvalidRegionError] a new instance of InvalidRegionError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#250 + def initialize(*args); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#267 + def possible_regions; end +end + +# Raised when a client is constructed and the sigv4a region set is invalid. +# It is invalid when it is empty and/or contains empty strings. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#241 +class Aws::Errors::InvalidRegionSetError < ::ArgumentError + # @return [InvalidRegionSetError] a new instance of InvalidRegionSetError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#242 + def initialize(*args); end +end + +# Raised when SSO Credentials are invalid +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#211 +class Aws::Errors::InvalidSSOCredentials < ::RuntimeError; end + +# Raised when SSO Token is invalid +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#214 +class Aws::Errors::InvalidSSOToken < ::RuntimeError; end + +# Raised when InstanceProfileCredentialsProvider or +# EcsCredentialsProvider fails to parse the metadata response after retries +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#55 +class Aws::Errors::MetadataParserError < ::RuntimeError + # @return [MetadataParserError] a new instance of MetadataParserError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#56 + def initialize(*args); end +end + +# Raised when a client is unable to sign a request because +# the bearer token is not configured or available +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#218 +class Aws::Errors::MissingBearerTokenError < ::RuntimeError + # @return [MissingBearerTokenError] a new instance of MissingBearerTokenError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#219 + def initialize(*args); end +end + +# Raised when a `streaming` operation has `requiresLength` trait +# enabled but request payload size/length cannot be calculated +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#64 +class Aws::Errors::MissingContentLength < ::RuntimeError + # @return [MissingContentLength] a new instance of MissingContentLength + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#65 + def initialize(*args); end +end + +# Raised when a client is constructed and credentials are not +# set, or the set credentials are empty. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#187 +class Aws::Errors::MissingCredentialsError < ::RuntimeError + # @return [MissingCredentialsError] a new instance of MissingCredentialsError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#188 + def initialize(*args); end +end + +# raised when hostLabel member is not provided +# at operation input when endpoint trait is available +# with 'hostPrefix' requirement +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#84 +class Aws::Errors::MissingEndpointHostLabelValue < ::RuntimeError + # @return [MissingEndpointHostLabelValue] a new instance of MissingEndpointHostLabelValue + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#86 + def initialize(name); end +end + +# Raised when a client is constructed and region is not specified. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#231 +class Aws::Errors::MissingRegionError < ::ArgumentError + # @return [MissingRegionError] a new instance of MissingRegionError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#232 + def initialize(*args); end +end + +# Raised when :web_identity_token_file parameter is not +# provided or the file doesn't exist when initializing +# AssumeRoleWebIdentityCredentials credential provider +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#197 +class Aws::Errors::MissingWebIdentityTokenFile < ::RuntimeError + # @return [MissingWebIdentityTokenFile] a new instance of MissingWebIdentityTokenFile + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#198 + def initialize(*args); end +end + +# Raised when a client is constructed with Assume Role credentials using +# a credential_source, and that source doesn't provide credentials. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#183 +class Aws::Errors::NoSourceCredentialsError < ::RuntimeError; end + +# Raised when a client is constructed, where Assume Role credentials are +# expected, and there is no source profile specified. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#171 +class Aws::Errors::NoSourceProfileError < ::RuntimeError; end + +# Raised when attempting to connect to an endpoint and a `SocketError` +# is received from the HTTP client. This error is typically the result +# of configuring an invalid `:region`. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#279 +class Aws::Errors::NoSuchEndpointError < ::RuntimeError + # @return [NoSuchEndpointError] a new instance of NoSuchEndpointError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#281 + def initialize(options = T.unsafe(nil)); end + + # Returns the value of attribute context. + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#308 + def context; end + + # Returns the value of attribute endpoint. + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#310 + def endpoint; end + + # Returns the value of attribute original_error. + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#312 + def original_error; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#316 + def possible_regions; end +end + +# Raised when a client is constructed and the specified shared +# credentials profile does not exist. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#167 +class Aws::Errors::NoSuchProfileError < ::RuntimeError; end + +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#6 +class Aws::Errors::NonSupportedRubyVersionError < ::RuntimeError; end + +# Raised when attempting to retry a request +# and no capacity is available to retry (See adaptive retry_mode) +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#327 +class Aws::Errors::RetryCapacityNotAvailableError < ::RuntimeError + # @return [RetryCapacityNotAvailableError] a new instance of RetryCapacityNotAvailableError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#328 + def initialize(*args); end +end + +# The base class for all errors returned by an Amazon Web Service. +# All ~400 level client errors and ~500 level server errors are raised +# as service errors. This indicates it was an error returned from the +# service and not one generated by the client. +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#12 +class Aws::Errors::ServiceError < ::RuntimeError + # @param context [Seahorse::Client::RequestContext] + # @param message [String, nil] + # @param data [Aws::Structure] + # @return [ServiceError] a new instance of ServiceError + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#17 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#26 + def code; end + + # @return [Seahorse::Client::RequestContext] The context of the request + # that triggered the remote service to return this error. + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#30 + def context; end + + # @return [Aws::Structure] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#33 + def data; end + + # @return [Aws::Structure] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#33 + def data=(_arg0); end + + # @api private undocumented + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#43 + def retryable?; end + + # @api private undocumented + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#48 + def throttling?; end + + class << self + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#38 + def code; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/errors.rb#38 + def code=(_arg0); end + end +end + +# Raised when attempting to #signal an event before +# making an async request +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#97 +class Aws::Errors::SignalEventError < ::RuntimeError; end + +# Raised when there is a circular reference in chained +# source_profiles +# +# source://aws-sdk-core//lib/aws-sdk-core/errors.rb#228 +class Aws::Errors::SourceProfileCircularReferenceError < ::RuntimeError; end + +# source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#4 +class Aws::EventEmitter + # @return [EventEmitter] a new instance of EventEmitter + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#6 + def initialize; end + + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#31 + def emit(type, params); end + + # Returns the value of attribute encoder. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#14 + def encoder; end + + # Sets the attribute encoder + # + # @param value the value to set the attribute encoder to. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#14 + def encoder=(_arg0); end + + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#20 + def on(type, callback); end + + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#24 + def signal(type, event); end + + # Returns the value of attribute signal_queue. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#18 + def signal_queue; end + + # Sets the attribute signal_queue + # + # @param value the value to set the attribute signal_queue to. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#18 + def signal_queue=(_arg0); end + + # Returns the value of attribute stream. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#12 + def stream; end + + # Sets the attribute stream + # + # @param value the value to set the attribute stream to. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#12 + def stream=(_arg0); end + + # Returns the value of attribute validate_event. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#16 + def validate_event; end + + # Sets the attribute validate_event + # + # @param value the value to set the attribute validate_event to. + # + # source://aws-sdk-core//lib/aws-sdk-core/event_emitter.rb#16 + def validate_event=(_arg0); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/ini_parser.rb#5 +class Aws::IniParser + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/ini_parser.rb#8 + def ini_parse(raw); end + end +end + +# An auto-refreshing credential provider that loads credentials from +# EC2 instances. +# +# instance_credentials = Aws::InstanceProfileCredentials.new +# ec2 = Aws::EC2::Client.new(credentials: instance_credentials) +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#12 +class Aws::InstanceProfileCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [InstanceProfileCredentials] a new instance of InstanceProfileCredentials + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#77 + def initialize(options = T.unsafe(nil)); end + + # @return [Integer] Number of times to retry when retrieving credentials + # from the instance metadata service. Defaults to 0 when resolving from + # the default credential chain ({Aws::CredentialProviderChain}). + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#99 + def retries; end + + private + + # token is optional - if nil, uses v1 (insecure) flow + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#243 + def _get_credentials(conn, token); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#259 + def _metadata_disabled?; end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#141 + def backoff(backoff); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#329 + def empty_credentials?(creds); end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#225 + def fetch_token(conn); end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#197 + def get_credentials; end + + # GET request fetch profile and credentials + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#274 + def http_get(connection, path, token = T.unsafe(nil)); end + + # PUT request fetch token with ttl + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#290 + def http_put(connection, path, ttl); end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#263 + def open_connection; end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#149 + def refresh; end + + # Compute an offset for refresh with jitter + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#334 + def refresh_offset; end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#131 + def resolve_disable_v1(options); end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#112 + def resolve_endpoint(options, endpoint_mode); end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#103 + def resolve_endpoint_mode(options); end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#309 + def retry_errors(error_classes, options = T.unsafe(nil), &_block); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#255 + def token_set?; end + + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#323 + def warn_expired_credentials; end +end + +# Path base for GET request for profile and credentials +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#42 +Aws::InstanceProfileCredentials::METADATA_PATH_BASE = T.let(T.unsafe(nil), String) + +# Path for PUT request for token +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#46 +Aws::InstanceProfileCredentials::METADATA_TOKEN_PATH = T.let(T.unsafe(nil), String) + +# These are the errors we trap when attempting to talk to the +# instance metadata service. Any of these imply the service +# is not present, no responding or some other non-recoverable +# error. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#30 +Aws::InstanceProfileCredentials::NETWORK_ERRORS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#17 +class Aws::InstanceProfileCredentials::Non200Response < ::RuntimeError; end + +# Token used to fetch IMDS profile and credentials +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#340 +class Aws::InstanceProfileCredentials::Token + # @api private + # @return [Token] a new instance of Token + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#341 + def initialize(value, ttl, created_time = T.unsafe(nil)); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#350 + def expired?; end + + # [String] token value + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#348 + def value; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#23 +class Aws::InstanceProfileCredentials::TokenExpiredError < ::RuntimeError; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/instance_profile_credentials.rb#20 +class Aws::InstanceProfileCredentials::TokenRetrivalError < ::RuntimeError; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#6 +module Aws::Json + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#46 + def dump(value); end + + # @api private + # @return [Class] Returns the default engine. + # One of: + # + # * {OjEngine} + # * {JsonEngine} + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#37 + def engine; end + + # @api private + # @param engine [Symbol, Class] Must be one of the following values: + # + # * :oj + # * :json + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#27 + def engine=(engine); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#42 + def load(json); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#50 + def set_default_engine; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#63 + def load_engine(name); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#69 + def try_load_engine(name); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#7 +class Aws::Json::Builder + include ::Seahorse::Model::Shapes + + # @return [Builder] a new instance of Builder + # + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#11 + def initialize(rules, _options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#15 + def serialize(params); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#15 + def to_json(params); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#63 + def encode(blob); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#51 + def format(ref, value); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#35 + def list(ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#42 + def map(ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#22 + def structure(ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/builder.rb#67 + def timestamp(ref, value); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#5 +class Aws::Json::ErrorHandler < ::Aws::ErrorHandler + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#7 + def call(context); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#82 + def apply_error_headers(rule, context, data); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#43 + def aws_query_error?(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#26 + def error_code(json, context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#56 + def error_message(code, json); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#16 + def extract_error(body, context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#64 + def parse_error_data(context, body, code); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/error_handler.rb#48 + def remove_prefix(error_code, context); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#5 +class Aws::Json::Handler < ::Seahorse::Client::Handler + # @param context [Seahorse::Client::RequestContext] + # @return [Seahorse::Client::Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#11 + def call(context); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#80 + def apply_request_id(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#27 + def build_body(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#20 + def build_request(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#71 + def content_type(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#39 + def parse_body(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#35 + def parse_response(response); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#88 + def query_compatible?(context); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#84 + def simple_json?(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#75 + def target(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/json/handler.rb#7 +Aws::Json::Handler::CONTENT_TYPE = T.let(T.unsafe(nil), String) + +# source://aws-sdk-core//lib/aws-sdk-core/json/json_engine.rb#7 +module Aws::Json::JsonEngine + class << self + # source://aws-sdk-core//lib/aws-sdk-core/json/json_engine.rb#15 + def dump(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/json_engine.rb#9 + def load(json); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/json.rb#11 +class Aws::Json::ParseError < ::StandardError + # @api private + # @return [ParseError] a new instance of ParseError + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#12 + def initialize(error); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/json.rb#17 + def error; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#8 +class Aws::Json::Parser + include ::Seahorse::Model::Shapes + + # @param rules [Seahorse::Model::ShapeRef] + # @return [Parser] a new instance of Parser + # + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#13 + def initialize(rules, query_compatible: T.unsafe(nil)); end + + # @param json [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#19 + def parse(json, target = T.unsafe(nil)); end + + private + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#104 + def flattened_list?(shape); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#108 + def flattened_map?(shape); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#63 + def list(ref, values, target = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#71 + def map(ref, values, target = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#81 + def parse_ref(ref, value, target = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#27 + def structure(ref, values, target = T.unsafe(nil)); end + + # @param value [String, Integer] + # @return [Time] + # + # source://aws-sdk-core//lib/aws-sdk-core/json/parser.rb#100 + def time(value); end +end + +# A simple thread safe LRU cache +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#6 +class Aws::LRUCache + # @api private + # @option options + # @option options + # @param options [Hash] + # @return [LRUCache] a new instance of LRUCache + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#10 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @param key [String] + # @return [Object] + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#19 + def [](key); end + + # @api private + # @param key [String] + # @param value [Object] + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#32 + def []=(key, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#51 + def clear; end + + # @api private + # @param key [String] + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#44 + def key?(key); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#58 +class Aws::LRUCache::Entry + # @api private + # @return [Entry] a new instance of Entry + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#59 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#68 + def expired?; end + + # @api private + # @return [Object] + # + # source://aws-sdk-core//lib/aws-sdk-core/lru_cache.rb#66 + def value; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#6 +module Aws::Log; end + +# A log formatter generates a string for logging from a response. This +# accomplished with a log pattern string: +# +# pattern = ':operation :http_response_status_code :time' +# formatter = Aws::Log::Formatter.new(pattern) +# formatter.format(response) +# #=> 'get_bucket 200 0.0352' +# +# # Canned Formatters +# +# Instead of providing your own pattern, you can choose a canned log +# formatter. +# +# * {Formatter.default} +# * {Formatter.colored} +# * {Formatter.short} +# +# # Pattern Substitutions +# +# You can put any of these placeholders into you pattern. +# +# * `:region` - The region configured for the client. +# +# * `:client_class` - The name of the client class. +# +# * `:operation` - The name of the client request method. +# +# * `:request_params` - The user provided request parameters. Long +# strings are truncated/summarized if they exceed the +# `:max_string_size`. Other objects are inspected. +# +# * `:time` - The total time in seconds spent on the +# request. This includes client side time spent building +# the request and parsing the response. +# +# * `:retries` - The number of times a client request was retried. +# +# * `:http_request_method` - The http request verb, e.g., `POST`, +# `PUT`, `GET`, etc. +# +# * `:http_request_endpoint` - The request endpoint. This includes +# the scheme, host and port, but not the path. +# +# * `:http_request_scheme` - This is replaced by `http` or `https`. +# +# * `:http_request_host` - The host name of the http request +# endpoint (e.g. 's3.amazon.com'). +# +# * `:http_request_port` - The port number (e.g. '443' or '80'). +# +# * `:http_request_headers` - The http request headers, inspected. +# +# * `:http_request_body` - The http request payload. +# +# * `:http_response_status_code` - The http response status +# code, e.g., `200`, `404`, `500`, etc. +# +# * `:http_response_headers` - The http response headers, inspected. +# +# * `:http_response_body` - The http response body contents. +# +# * `:error_class` +# +# * `:error_message` +# +# source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#73 +class Aws::Log::Formatter + # @option options + # @option options + # @option options + # @param pattern [String] The log format pattern should be a string + # and may contain substitutions. + # @param options [Hash] a customizable set of options + # @return [Formatter] a new instance of Formatter + # + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#93 + def initialize(pattern, options = T.unsafe(nil)); end + + # Given a response, this will format a log message and return it as a + # string according to {#pattern}. + # + # @param response [Seahorse::Client::Response] + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#106 + def format(response); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#111 + def method_missing(method_name, *args); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#100 + def pattern; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#125 + def _client_class(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#195 + def _error_class(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#199 + def _error_message(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#173 + def _http_request_body(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#149 + def _http_request_endpoint(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#169 + def _http_request_headers(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#157 + def _http_request_host(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#165 + def _http_request_method(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#161 + def _http_request_port(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#153 + def _http_request_scheme(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#185 + def _http_response_body(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#181 + def _http_response_headers(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#177 + def _http_response_status_code(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#129 + def _operation(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#121 + def _region(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#133 + def _request_params(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#145 + def _retries(response); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#139 + def _time(response); end + + class << self + # The default log format with ANSI colors. + # + # @example A sample of the colored format (sans the ansi colors). + # + # [ClientClass 200 0.580066 0 retries] list_objects(:bucket_name => 'bucket') + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Formatter] + # + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#249 + def colored(options = T.unsafe(nil)); end + + # The default log format. + # + # @example A sample of the default format. + # + # [ClientClass 200 0.580066 0 retries] list_objects(:bucket_name => 'bucket') + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Formatter] + # + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#212 + def default(options = T.unsafe(nil)); end + + # The short log format. Similar to default, but it does not + # inspect the request params or report on retries. + # + # @example A sample of the short format + # + # [ClientClass 200 0.494532] list_buckets + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Formatter] + # + # source://aws-sdk-core//lib/aws-sdk-core/log/formatter.rb#232 + def short(options = T.unsafe(nil)); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/log/param_filter.rb#8 +class Aws::Log::ParamFilter + # end + # + # @return [ParamFilter] a new instance of ParamFilter + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_filter.rb#22 + def initialize(options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/param_filter.rb#27 + def filter(values, type); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/log/param_filter.rb#64 + def filter_array(values, type); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/param_filter.rb#45 + def filter_hash(values, type); end + + # source://aws-sdk-core//lib/aws-sdk-core/log/param_filter.rb#38 + def filter_struct(values, type); end +end + +# DEPRECATED - This must exist for backwards compatibility. Sensitive +# members are now computed for each request/response type. This can be +# removed in a new major version. This list is no longer updated. +# +# A managed list of sensitive parameters that should be filtered from +# logs. This is updated automatically as part of each release. See the +# `tasks/update-sensitive-params.rake` for more information. +# +# begin +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/log/param_filter.rb#19 +Aws::Log::ParamFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#8 +class Aws::Log::ParamFormatter + # @api private + # @return [ParamFormatter] a new instance of ParamFormatter + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#13 + def initialize(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#17 + def summarize(value); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#64 + def summarize_array(array); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#60 + def summarize_file(path); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#23 + def summarize_hash(hash); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#41 + def summarize_string(str); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#35 + def summarize_string_hash(hash); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#29 + def summarize_symbol_hash(hash); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#49 + def summarize_value(value); end +end + +# String longer than the max string size are truncated +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/log/param_formatter.rb#11 +Aws::Log::ParamFormatter::MAX_STRING_SIZE = T.let(T.unsafe(nil), Integer) + +# Decorates a {Seahorse::Client::Response} with paging convenience methods. +# Some AWS calls provide paged responses to limit the amount of data returned +# with each response. To optimize for latency, some APIs may return an +# inconsistent number of responses per page. You should rely on the values of +# the `next_page?` method or using enumerable methods such as `each` rather +# than the number of items returned to iterate through results. See below for +# examples. +# +# # Paged Responses Are Enumerable +# The simplest way to handle paged response data is to use the built-in +# enumerator in the response object, as shown in the following example. +# +# s3 = Aws::S3::Client.new +# +# s3.list_objects(bucket:'aws-sdk').each do |response| +# puts response.contents.map(&:key) +# end +# +# This yields one response object per API call made, and enumerates objects +# in the named bucket. The SDK retrieves additional pages of data to +# complete the request. +# +# # Handling Paged Responses Manually +# To handle paging yourself, use the response’s `next_page?` method to verify +# there are more pages to retrieve, or use the last_page? method to verify +# there are no more pages to retrieve. +# +# If there are more pages, use the `next_page` method to retrieve the +# next page of results, as shown in the following example. +# +# s3 = Aws::S3::Client.new +# +# # Get the first page of data +# response = s3.list_objects(bucket:'aws-sdk') +# +# # Get additional pages +# while response.next_page? do +# response = response.next_page +# # Use the response data here... +# puts response.contents.map(&:key) +# end +# +# @note Methods such as `to_json` will enumerate all of the responses before +# returning the full response as JSON. +# +# source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#49 +module Aws::PageableResponse + # Yields the current and each following response to the given block. + # + # @return [Enumerable, nil] Returns a new Enumerable if no block is given. + # @yieldparam response [Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#83 + def each(&block); end + + # Yields the current and each following response to the given block. + # Actual implementation is in PageableResponse::Extension + # + # @return [Enumerable, nil] Returns a new Enumerable if no block is given. + # @yieldparam response [Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#83 + def each_page(&block); end + + # Returns `true` if there are no more results. Calling {#next_page} + # when this method returns `false` will raise an error. + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#64 + def last_page?; end + + # @return [Seahorse::Client::Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#76 + def next_page(params = T.unsafe(nil)); end + + # Returns `true` if there are more results. Calling {#next_page} will + # return the next response. + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#71 + def next_page?; end + + # @return [Paging::Pager] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#59 + def pager; end + + # @return [Paging::Pager] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#59 + def pager=(_arg0); end + + private + + # @param params [Hash] A hash of additional request params to + # merge into the next page request. + # @return [Hash] Returns the hash of request parameters for the + # next page, merging any given params. + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#102 + def next_page_params(params); end + + # @param params [Hash] A hash of additional request params to + # merge into the next page request. + # @return [Seahorse::Client::Response] Returns the next page of + # results. + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#94 + def next_response(params); end + + class << self + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#51 + def apply(base); end + end +end + +# The actual decorator module implementation. It is in a distinct module +# so that it can be used to extend objects without busting Ruby's constant cache. +# object.extend(mod) bust the constant cache only if `mod` contains constants of its own. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#162 +module Aws::PageableResponse::Extension + include ::ActiveSupport::ToJsonWithActiveSupportEncoder + include ::Enumerable + include ::Aws::PageableResponse::UnsafeEnumerableMethods + + # @api private + # @yield [response] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#188 + def each(&block); end + + # @api private + # @yield [response] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#188 + def each_page(&block); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#169 + def last_page?; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#180 + def next_page(params = T.unsafe(nil)); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#176 + def next_page?; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#167 + def pager; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#167 + def pager=(_arg0); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#209 + def next_page_params(params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#201 + def next_response(params); end +end + +# Raised when calling {PageableResponse#next_page} on a pager that +# is on the last page of results. You can call {PageableResponse#last_page?} +# or {PageableResponse#next_page?} to know if there are more pages. +# +# source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#109 +class Aws::PageableResponse::LastPageError < ::RuntimeError + # @param response [Seahorse::Client::Response] + # @return [LastPageError] a new instance of LastPageError + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#112 + def initialize(response); end + + # @return [Seahorse::Client::Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#118 + def response; end +end + +# A handful of Enumerable methods, such as #count are not safe +# to call on a pageable response, as this would trigger n api calls +# simply to count the number of response pages, when likely what is +# wanted is to access count on the data. Same for #to_h. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#127 +module Aws::PageableResponse::UnsafeEnumerableMethods + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#149 + def as_json(_options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#129 + def count; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#137 + def respond_to?(method_name, *args); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#145 + def to_h; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pageable_response.rb#153 + def to_json(options = T.unsafe(nil)); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/pager.rb#7 +class Aws::Pager + # @api private + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Pager] a new instance of Pager + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#12 + def initialize(options); end + + # @api private + # @return [Symbol, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#19 + def limit_key; end + + # @api private + # @param response [Seahorse::Client::Response] + # @return [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#26 + def next_tokens(response); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#34 + def prev_tokens(response); end + + # @api private + # @return [Hash, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#22 + def tokens; end + + # @api private + # @param response [Seahorse::Client::Response] + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#43 + def truncated?(response); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#55 + def empty_value?(value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/pager.rb#59 +class Aws::Pager::NullPager + # @api private + # @return [nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#62 + def limit_key; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#64 + def next_tokens; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#68 + def prev_tokens; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/pager.rb#72 + def truncated?(response); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#11 +class Aws::ParamConverter + include ::Seahorse::Model::Shapes + + # @api private + # @return [ParamConverter] a new instance of ParamConverter + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#18 + def initialize(rules); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#36 + def close_opened_files; end + + # @api private + # @param params [Hash] + # @return [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#28 + def convert(params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#24 + def opened_files; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#86 + def c(ref, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#57 + def list(ref, values); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#66 + def map(ref, values); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#77 + def member(ref, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#43 + def structure(ref, values); end + + class << self + # Registers a new value converter. Converters run in the context + # of a shape and value class. + # + # # add a converter that stringifies integers + # shape_class = Seahorse::Model::Shapes::StringShape + # ParamConverter.add(shape_class, Integer) { |i| i.to_s } + # + # @api private + # @param shape_class [Class] + # @param value_class [Class] + # @param converter [#call] (nil) An object that responds to `#call` + # accepting a single argument. This function should perform + # the value conversion if possible, returning the result. + # If the conversion is not possible, the original value should + # be returned. + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#111 + def add(shape_class, value_class, converter = T.unsafe(nil), &block); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#126 + def c(shape, value, instance = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#92 + def convert(shape, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#115 + def ensure_open(file, converter); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#136 + def converter_for(shape_class, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#161 + def each_base_class(shape_class, &block); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_converter.rb#147 + def find(shape_class, value); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#5 +class Aws::ParamValidator + include ::Seahorse::Model::Shapes + + # @api private + # @option options + # @param rules [Seahorse::Model::Shapes::ShapeRef] + # @param options [Hash] a customizable set of options + # @return [ParamValidator] a new instance of ParamValidator + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#20 + def initialize(rules, options = T.unsafe(nil)); end + + # @api private + # @param params [Hash] + # @raise [ArgumentError] + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#32 + def validate!(params); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#202 + def correct_type?(ref, value, errors, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#133 + def document(ref, value, errors, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#227 + def error_messages(errors); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#237 + def expected_got(context, expected, got); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#218 + def io_like?(value, require_size = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#100 + def list(ref, values, errors, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#116 + def map(ref, values, errors, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#153 + def shape(ref, value, errors, context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#223 + def streaming_input?(ref); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#40 + def structure(ref, values, errors, context); end + + class << self + # @api private + # @param rules [Seahorse::Model::Shapes::ShapeRef] + # @param params [Hash] + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#14 + def validate!(rules, params); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/param_validator.rb#9 +Aws::ParamValidator::EXPECTED_GOT = T.let(T.unsafe(nil), String) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/bearer_authorization.rb#5 +module Aws::Plugins; end + +# Deprecated - does not look at new traits like `auth` and `unsignedPayload` +# Necessary to exist after endpoints 2.0 for old service clients + new core +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/bearer_authorization.rb#9 +class Aws::Plugins::BearerAuthorization < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/bearer_authorization.rb#36 + def add_handlers(handlers, cfg); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/bearer_authorization.rb#52 +class Aws::Plugins::BearerAuthorization::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/bearer_authorization.rb#53 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#6 +class Aws::Plugins::ChecksumAlgorithm < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#56 + def add_handlers(handlers, _config); end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#251 + def calculate_checksum(algorithm, body); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#261 + def digest_for_algorithm(algorithm); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#79 + def operation_response_algorithms(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#65 + def request_algorithm_selection(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#72 + def request_validation_mode(context); end + + # The trailer size (in bytes) is the overhead + the trailer name + + # the length of the base64 encoded checksum + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#277 + def trailer_length(algorithm, location_name); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#281 + def update_in_chunks(digest, io); end + end +end + +# Wrapper for request body that implements application-layer +# chunking with Digest computed on chunks + added as a trailer +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#292 +class Aws::Plugins::ChecksumAlgorithm::AwsChunkedTrailerDigestIO + # @api private + # @return [AwsChunkedTrailerDigestIO] a new instance of AwsChunkedTrailerDigestIO + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#295 + def initialize(io, algorithm, location_name); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#320 + def read(length, buf = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#316 + def rewind; end + + # the size of the application layer aws-chunked + trailer body + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#304 + def size; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#293 +Aws::Plugins::ChecksumAlgorithm::AwsChunkedTrailerDigestIO::CHUNK_SIZE = T.let(T.unsafe(nil), Integer) + +# priority order of checksum algorithms to validate responses against +# Remove any algorithms not supported by client (ie, depending on CRT availability) +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#23 +Aws::Plugins::ChecksumAlgorithm::CHECKSUM_ALGORITHM_PRIORITIES = T.let(T.unsafe(nil), Array) + +# byte size of checksums, used in computing the trailer length +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#26 +Aws::Plugins::ChecksumAlgorithm::CHECKSUM_SIZE = T.let(T.unsafe(nil), Hash) + +# one MB +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#7 +Aws::Plugins::ChecksumAlgorithm::CHUNK_SIZE = T.let(T.unsafe(nil), Integer) + +# determine the set of supported client side checksum algorithms +# CRC32c requires aws-crt (optional sdk dependency) for support +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#11 +Aws::Plugins::ChecksumAlgorithm::CLIENT_ALGORITHMS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#116 +class Aws::Plugins::ChecksumAlgorithm::ChecksumHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#118 + def call(context); end + + private + + # Add events to the http_response to verify the checksum as its read + # This prevents the body from being read multiple times + # verification is done only once a successful response has completed + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#194 + def add_verify_response_checksum_handlers(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#166 + def apply_request_trailer_checksum(context, checksum_properties); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#152 + def calculate_request_checksum(context, checksum_properties); end + + # determine where (header vs trailer) a request checksum should be added + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#240 + def checksum_request_in(context); end + + # returns nil if no headers to verify + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#231 + def response_header_to_verify(headers, validation_list); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#142 + def should_calculate_request_checksum?(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#148 + def should_verify_response_checksum?(context); end +end + +# Interface for computing digests on request/response bodies +# which may be files, strings or IO like objects +# Applies only to digest functions that produce 32 bit integer checksums +# (eg CRC32) +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#37 +class Aws::Plugins::ChecksumAlgorithm::Digest32 + # @api private + # @param digest_fn [Object] + # @return [Digest32] a new instance of Digest32 + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#42 + def initialize(digest_fn); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#51 + def base64digest; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#47 + def update(chunk); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#39 + def value; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#87 +class Aws::Plugins::ChecksumAlgorithm::OptionHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/checksum_algorithm.rb#88 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#8 +class Aws::Plugins::ClientMetricsPlugin < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#61 + def add_handlers(handlers, config); end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#115 + def resolve_client_id(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#101 + def resolve_client_side_monitoring(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#88 + def resolve_client_side_monitoring_host(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#75 + def resolve_client_side_monitoring_port(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#71 + def resolve_publisher(cfg); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#123 +class Aws::Plugins::ClientMetricsPlugin::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#124 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#203 + def _calculate_service_id(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_plugin.rb#209 + def _fallback_service_id(id); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#7 +class Aws::Plugins::ClientMetricsSendPlugin < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#9 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#32 +class Aws::Plugins::ClientMetricsSendPlugin::AttemptHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#33 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#73 +class Aws::Plugins::ClientMetricsSendPlugin::ErrorHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#74 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#88 + def _extract_error_name(error); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#21 +class Aws::Plugins::ClientMetricsSendPlugin::LatencyHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb#22 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/credentials_configuration.rb#7 +class Aws::Plugins::CredentialsConfiguration < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/defaults_mode.rb#7 +class Aws::Plugins::DefaultsMode < ::Seahorse::Client::Plugin + class << self + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/defaults_mode.rb#29 + def resolve_defaults_mode(cfg); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#6 +class Aws::Plugins::EndpointDiscovery < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#60 + def add_handlers(handlers, config); end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#162 + def resolve_endpoint_discovery(cfg); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#64 +class Aws::Plugins::EndpointDiscovery::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#66 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#98 + def _apply_endpoint_discovery_user_agent(ctx); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#106 + def _discover_endpoint(ctx, required); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_discovery.rb#89 + def _valid_uri(address); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_pattern.rb#6 +class Aws::Plugins::EndpointPattern < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_pattern.rb#17 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_pattern.rb#21 +class Aws::Plugins::EndpointPattern::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_pattern.rb#23 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_pattern.rb#35 + def _apply_endpoint_trait(context, trait); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/endpoint_pattern.rb#48 + def _replace_label_value(ori, label, input_ref, params); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/event_stream_configuration.rb#6 +class Aws::Plugins::EventStreamConfiguration < ::Seahorse::Client::Plugin; end + +# This plugin provides the ability to provide global configuration for +# all AWS classes or specific ones. +# +# ## Global AWS configuration +# +# You can specify global configuration defaults via `Aws.config` +# +# Aws.config[:region] = 'us-west-2' +# +# Options applied to `Aws.config` are merged with constructed +# service interfaces. +# +# # uses the global configuration +# Aws::EC2.new.config.region #=> 'us-west-2' +# +# # constructor args have priority over global configuration +# Aws::EC2.new(region: 'us-east-1').config.region #=> 'us-east-1' +# +# ## Service Specific Global Configuration +# +# Some services have very specific configuration options that are not +# shared by other services. +# +# # oops, this option is only recognized by Aws::S3 +# Aws.config[:force_path_style] = true +# Aws::EC2.new +# #=> raises ArgumentError: invalid configuration option `:force_path_style' +# +# To avoid this issue, you can nest service specific options +# +# Aws.config[:s3] = { force_path_style: true } +# +# Aws::EC2.new # no error this time +# Aws::S3.new.config.force_path_style #=> true +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/global_configuration.rb#44 +class Aws::Plugins::GlobalConfiguration < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/global_configuration.rb#49 + def before_initialize(client_class, options); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/global_configuration.rb#65 + def apply_aws_defaults(_client_class, options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/global_configuration.rb#57 + def apply_service_defaults(client_class, options); end + + class << self + # Registers an additional service identifier. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/global_configuration.rb#78 + def add_identifier(identifier); end + + # @api private + # @return [Set] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/global_configuration.rb#84 + def identifiers; end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/helpful_socket_errors.rb#6 +class Aws::Plugins::HelpfulSocketErrors < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/helpful_socket_errors.rb#8 +class Aws::Plugins::HelpfulSocketErrors::Handler < ::Seahorse::Client::Handler + # Wrap `SocketError` errors with `Aws::Errors::NoSuchEndpointError` + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/helpful_socket_errors.rb#11 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/helpful_socket_errors.rb#30 + def no_such_endpoint_error(context, error); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/helpful_socket_errors.rb#23 + def socket_endpoint_error?(error); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#8 +class Aws::Plugins::HttpChecksum < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#57 + def add_handlers(handlers, _config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#10 +class Aws::Plugins::HttpChecksum::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#13 + def call(context); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#25 + def checksum_required?(context); end + + # @api private + # @param value [File, Tempfile, IO#read, String] + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#33 + def md5(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#46 + def update_in_chunks(digest, io); end +end + +# one MB +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/http_checksum.rb#11 +Aws::Plugins::HttpChecksum::Handler::CHUNK_SIZE = T.let(T.unsafe(nil), Integer) + +# Provides support for auto filling operation parameters +# that enabled with `idempotencyToken` trait with random UUID v4 +# when no value is provided +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/idempotency_token.rb#12 +class Aws::Plugins::IdempotencyToken < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/idempotency_token.rb#15 +class Aws::Plugins::IdempotencyToken::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/idempotency_token.rb#17 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/idempotency_token.rb#24 + def auto_fill(params, ref); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/invocation_id.rb#9 +class Aws::Plugins::InvocationId < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/invocation_id.rb#12 +class Aws::Plugins::InvocationId::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/invocation_id.rb#14 + def call(context); end +end + +# Converts input value to JSON Syntax for members with jsonvalue trait +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/jsonvalue_converter.rb#7 +class Aws::Plugins::JsonvalueConverter < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/jsonvalue_converter.rb#10 +class Aws::Plugins::JsonvalueConverter::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/jsonvalue_converter.rb#12 + def call(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/jsonvalue_converter.rb#19 + def convert_jsonvalue(m, ref, params, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/jsonvalue_converter.rb#46 + def serialize_jsonvalue(v, context); end +end + +# @api private +# @see Log::Formatter +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/logging.rb#7 +class Aws::Plugins::Logging < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/logging.rb#33 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/logging.rb#37 +class Aws::Plugins::Logging::Handler < ::Seahorse::Client::Handler + # @api private + # @param context [RequestContext] + # @return [Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/logging.rb#41 + def call(context); end + + private + + # @api private + # @param config [Configuration] + # @param response [Response] + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/logging.rb#61 + def format(config, response); end + + # @api private + # @param config [Configuration] + # @param response [Response] + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/logging.rb#54 + def log(config, response); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/param_converter.rb#6 +class Aws::Plugins::ParamConverter < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/param_converter.rb#17 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/param_converter.rb#21 +class Aws::Plugins::ParamConverter::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/param_converter.rb#23 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/param_validator.rb#6 +class Aws::Plugins::ParamValidator < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/param_validator.rb#16 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/param_validator.rb#22 +class Aws::Plugins::ParamValidator::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/param_validator.rb#24 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/protocols/query.rb#5 +module Aws::Plugins::Protocols; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/protocols/json_rpc.rb#6 +class Aws::Plugins::Protocols::JsonRpc < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/protocols/query.rb#6 +class Aws::Plugins::Protocols::Query < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/protocols/rest_json.rb#6 +class Aws::Plugins::Protocols::RestJson < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/protocols/rest_xml.rb#6 +class Aws::Plugins::Protocols::RestXml < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/recursion_detection.rb#6 +class Aws::Plugins::RecursionDetection < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/recursion_detection.rb#9 +class Aws::Plugins::RecursionDetection::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/recursion_detection.rb#10 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/recursion_detection.rb#22 + def validate_header(header_value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#6 +class Aws::Plugins::RegionalEndpoint < ::Seahorse::Client::Plugin + # @api private + # @raise [Errors::MissingRegionError] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#82 + def after_initialize(client); end + + class << self + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#174 + def env_global_endpoint(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#164 + def env_service_endpoint(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#198 + def handle_legacy_pseudo_regions(cfg); end + + # get a custom configured endpoint from ENV or configuration + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#157 + def resolve_custom_config_endpoint(cfg); end + + # NOTE: with Endpoints 2.0, some of this logic is deprecated + # but because new old service gems may depend on new core versions + # we must preserve that behavior. + # Additional behavior controls the setting of the custom SDK::Endpoint + # parameter. + # When the `regional_endpoint` config is set to true - this indicates to + # Endpoints2.0 that a custom endpoint has NOT been configured by the user. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#140 + def resolve_endpoint(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#127 + def resolve_ignore_configured_endpoint_urls(cfg); end + + # set a default endpoint in config using legacy (endpoints.json) resolver + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#209 + def resolve_legacy_endpoint(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#99 + def resolve_region(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#107 + def resolve_sigv4a_signing_region_set(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#113 + def resolve_use_dualstack_endpoint(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#121 + def resolve_use_fips_endpoint(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#182 + def shared_config_endpoint(cfg); end + + # check region is a valid RFC host label + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/regional_endpoint.rb#192 + def validate_region!(region); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#6 +class Aws::Plugins::RequestCompression < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#58 + def add_handlers(handlers, _config); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#35 + def after_initialize(client); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#40 + def validate_disable_request_compression_input(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#48 + def validate_request_min_compression_size_bytes_input(cfg); end + + class << self + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#66 + def resolve_disable_request_compression(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#73 + def resolve_request_min_compression_size_bytes(cfg); end + end +end + +# one MB +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#10 +Aws::Plugins::RequestCompression::CHUNK_SIZE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#82 +class Aws::Plugins::RequestCompression::CompressionHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#83 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#145 + def gzip_compress(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#135 + def process_compression(encoding, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#168 + def process_streaming_compression(encoding, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#108 + def request_encoding_selection(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#122 + def should_compress?(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#127 + def streaming?(input); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#113 + def update_content_encoding(encoding, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#159 + def update_in_chunks(compressor, io); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#99 + def with_metric(encoding, &block); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#211 +class Aws::Plugins::RequestCompression::CompressionHandler::ChunkBuffer + # @api private + # @return [ChunkBuffer] a new instance of ChunkBuffer + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#212 + def initialize; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#216 + def last_chunk; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#218 + def write(data); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#179 +class Aws::Plugins::RequestCompression::CompressionHandler::GzipIO + # @api private + # @return [GzipIO] a new instance of GzipIO + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#180 + def initialize(body); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#186 + def read(length, buff = T.unsafe(nil)); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#7 +Aws::Plugins::RequestCompression::DEFAULT_MIN_COMPRESSION_SIZE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#8 +Aws::Plugins::RequestCompression::MIN_COMPRESSION_SIZE_LIMIT = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/request_compression.rb#9 +Aws::Plugins::RequestCompression::SUPPORTED_ENCODINGS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/response_paging.rb#6 +class Aws::Plugins::ResponsePaging < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/response_paging.rb#8 +class Aws::Plugins::ResponsePaging::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/response_paging.rb#10 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#5 +module Aws::Plugins::Retries; end + +# Used only in 'adaptive' retry mode +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#8 +class Aws::Plugins::Retries::ClientRateLimiter + # @api private + # @return [ClientRateLimiter] a new instance of ClientRateLimiter + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#17 + def initialize; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#32 + def token_bucket_acquire(amount, wait_to_fill = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#50 + def update_sending_rate(is_throttling_error); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#122 + def calculate_time_window; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#128 + def cubic_success(timestamp); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#133 + def cubic_throttle(rate_to_use); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#105 + def enable_token_bucket; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#79 + def token_bucket_refill; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#94 + def token_bucket_update_rate(new_rps); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#109 + def update_measured_rate; end +end + +# How much to scale back after a throttling response +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#13 +Aws::Plugins::Retries::ClientRateLimiter::BETA = T.let(T.unsafe(nil), Float) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#9 +Aws::Plugins::Retries::ClientRateLimiter::MIN_CAPACITY = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#10 +Aws::Plugins::Retries::ClientRateLimiter::MIN_FILL_RATE = T.let(T.unsafe(nil), Float) + +# Controls how aggressively we scale up after being throttled +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#15 +Aws::Plugins::Retries::ClientRateLimiter::SCALE_CONSTANT = T.let(T.unsafe(nil), Float) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/client_rate_limiter.rb#11 +Aws::Plugins::Retries::ClientRateLimiter::SMOOTH = T.let(T.unsafe(nil), Float) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#8 +class Aws::Plugins::Retries::ClockSkew + # @api private + # @return [ClockSkew] a new instance of ClockSkew + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#12 + def initialize; end + + # Gets the clock_correction in seconds to apply to a given endpoint + # + # @api private + # @param endpoint [URI / String] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#26 + def clock_correction(endpoint); end + + # Determines whether a request has clock skew by comparing + # the current time against the server's time in the response + # + # @api private + # @param context [Seahorse::Client::RequestContext] + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#44 + def clock_skewed?(context); end + + # The estimated skew factors in any clock skew from + # the service along with any network latency. + # This provides a more accurate value for the ttl, + # which should represent when the client will stop + # waiting for a request. + # Estimated Skew should not be used to correct clock skew errors + # it should only be used to estimate TTL for a request + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#37 + def estimated_skew(endpoint); end + + # Called only on clock skew related errors + # Update the stored clock skew correction value for an endpoint + # from the server's time in the response + # + # @api private + # @param context [Seahorse::Client::RequestContext] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#54 + def update_clock_correction(context); end + + # Called for every request + # Update our estimated clock skew for the endpoint + # from the servers time in the response + # + # @api private + # @param context [Seahorse::Client::RequestContext] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#67 + def update_estimated_skew(context); end + + private + + # @api private + # @param response [Seahorse::Client::Http::Response:] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#80 + def server_time(response); end + + # Sets the clock correction for an endpoint + # + # @api private + # @param endpoint [URI / String] + # @param correction [Number] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#91 + def set_clock_correction(endpoint, correction); end +end + +# five minutes +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/clock_skew.rb#10 +Aws::Plugins::Retries::ClockSkew::CLOCK_SKEW_THRESHOLD = T.let(T.unsafe(nil), Integer) + +# This class will be obsolete when APIs contain modeled exceptions +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#8 +class Aws::Plugins::Retries::ErrorInspector + # @api private + # @return [ErrorInspector] a new instance of ErrorInspector + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#68 + def initialize(error, http_status_code); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#85 + def checksum?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#115 + def clock_skew?(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#99 + def endpoint_discovery?(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#74 + def expired_credentials?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#107 + def modeled_retryable?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#111 + def modeled_throttling?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#89 + def networking?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#120 + def retryable?(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#95 + def server?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#78 + def throttling_error?; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#137 + def extract_name(error); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#133 + def refreshable_credentials?(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#40 +Aws::Plugins::Retries::ErrorInspector::CHECKSUM_ERRORS = T.let(T.unsafe(nil), Set) + +# See: https://github.com/aws/aws-sdk-net/blob/5810dfe401e0eac2e59d02276d4b479224b4538e/sdk/src/Core/Amazon.Runtime/Pipeline/RetryHandler/RetryPolicy.cs#L78 +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#57 +Aws::Plugins::Retries::ErrorInspector::CLOCK_SKEW_ERRORS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#9 +Aws::Plugins::Retries::ErrorInspector::EXPIRED_CREDS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#47 +Aws::Plugins::Retries::ErrorInspector::NETWORKING_ERRORS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/error_inspector.rb#21 +Aws::Plugins::Retries::ErrorInspector::THROTTLING_ERRORS = T.let(T.unsafe(nil), Set) + +# Used in 'standard' and 'adaptive' retry modes. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#9 +class Aws::Plugins::Retries::RetryQuota + # @api private + # @return [RetryQuota] a new instance of RetryQuota + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#15 + def initialize(opts = T.unsafe(nil)); end + + # check if there is sufficient capacity to retry + # and return it. If there is insufficient capacity + # return 0 + # + # @api private + # @return [Integer] The amount of capacity checked out + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#25 + def checkout_capacity(error_inspector); end + + # capacity_amount refers to the amount of capacity requested from + # the last retry. It can either be RETRY_COST, TIMEOUT_RETRY_COST, + # or unset. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#44 + def release(capacity_amount); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#10 +Aws::Plugins::Retries::RetryQuota::INITIAL_RETRY_TOKENS = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#12 +Aws::Plugins::Retries::RetryQuota::NO_RETRY_INCREMENT = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#11 +Aws::Plugins::Retries::RetryQuota::RETRY_COST = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retries/retry_quota.rb#13 +Aws::Plugins::Retries::RetryQuota::TIMEOUT_RETRY_COST = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#12 +class Aws::Plugins::RetryErrors < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#430 + def add_handlers(handlers, config); end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#199 + def resolve_adaptive_retry_wait_to_fill(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#213 + def resolve_correct_clock_skew(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#185 + def resolve_max_attempts(cfg); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#166 + def resolve_retry_mode(cfg); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#29 +Aws::Plugins::RetryErrors::DEFAULT_BACKOFF = T.let(T.unsafe(nil), Proc) + +# BEGIN LEGACY OPTIONS +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#14 +Aws::Plugins::RetryErrors::EQUAL_JITTER = T.let(T.unsafe(nil), Proc) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#15 +Aws::Plugins::RetryErrors::FULL_JITTER = T.let(T.unsafe(nil), Proc) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#227 +class Aws::Plugins::RetryErrors::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#231 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#332 + def add_retry_headers(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#346 + def compute_request_ttl(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#314 + def exponential_backoff(retries); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#278 + def get_send_token(config); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#327 + def refresh_credentials?(context, error); end + + # maxsendrate is updated if on adaptive mode and based on response + # retry quota is updated if the request is successful (both modes) + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#293 + def request_bookkeeping(context, response, error_inspector); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#319 + def retry_request(context, error); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#307 + def retryable?(context, response, error_inspector); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#274 + def with_metric(retry_mode, &block); end +end + +# Max backoff (in seconds) +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#229 +Aws::Plugins::RetryErrors::Handler::MAX_BACKOFF = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#18 +Aws::Plugins::RetryErrors::JITTERS = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#362 +class Aws::Plugins::RetryErrors::LegacyHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#364 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#406 + def delay_retry(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#416 + def refresh_credentials?(context, error); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#425 + def response_truncatable?(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#388 + def retry_if_possible(response, error_inspector); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#421 + def retry_limit(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#397 + def retry_request(context, error); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#410 + def should_retry?(context, error); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#384 + def with_metric(&block); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/retry_errors.rb#16 +Aws::Plugins::RetryErrors::NO_JITTER = T.let(T.unsafe(nil), Proc) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#8 +class Aws::Plugins::Sign < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#20 + def add_handlers(handlers, cfg); end + + class << self + # Return a signer with the `sign(context)` method + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#27 + def signer_for(auth_scheme, config, sigv4_region_override = T.unsafe(nil), sigv4_credentials_override = T.unsafe(nil)); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#67 +class Aws::Plugins::Sign::Bearer + # @api private + # @return [Bearer] a new instance of Bearer + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#68 + def initialize; end + + # @api private + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#85 + def presign_url(*args); end + + # @api private + # @raise [Errors::MissingBearerTokenError] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#71 + def sign(context); end + + # @api private + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#89 + def sign_event(*args); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#42 +class Aws::Plugins::Sign::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#43 + def call(context); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#59 + def v2_signing?(config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#201 +class Aws::Plugins::Sign::NullSigner + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#206 + def presign_url(*args); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#203 + def sign(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#209 + def sign_event(*args); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#18 +Aws::Plugins::Sign::SUPPORTED_AUTH_TYPES = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#95 +class Aws::Plugins::Sign::SignatureV4 + # @api private + # @return [SignatureV4] a new instance of SignatureV4 + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#96 + def initialize(auth_scheme, config, sigv4_overrides = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#151 + def presign_url(*args); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#124 + def sign(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#155 + def sign_event(*args); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#161 + def apply_authtype(context, req); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#184 + def apply_clock_skew(context, req); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#176 + def reset_signature(req); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/sign.rb#170 + def unsigned_payload?(context, req); end +end + +# Deprecated - does not look at new traits like `auth` and `unsignedPayload` +# Necessary to exist after endpoints 2.0 for old service clients + new core +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#10 +class Aws::Plugins::SignatureV4 < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#53 + def add_handlers(handlers, cfg); end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#142 + def apply_authtype(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#99 + def apply_signature(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#78 + def build_signer(cfg); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#62 +class Aws::Plugins::SignatureV4::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#63 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#69 +class Aws::Plugins::SignatureV4::MissingCredentialsSigner + # @api private + # @raise [Errors::MissingCredentialsError] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#70 + def sign_request(*args); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/signature_v4.rb#12 +Aws::Plugins::SignatureV4::V4_AUTH = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#6 +class Aws::Plugins::StubResponses < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#32 + def add_handlers(handlers, config); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#36 + def after_initialize(client); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#49 +class Aws::Plugins::StubResponses::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#65 + def apply_stub(stub, response, async_mode = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#51 + def call(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#74 + def signal_error(error, http_resp); end + + # @api private + # @param stub [Seahorse::Client::Http::Response] + # @param http_resp [Seahorse::Client::Http::Response | Seahorse::Client::Http::AsyncResponse] + # @param async_mode [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/stub_responses.rb#85 + def signal_http(stub, http_resp, async_mode = T.unsafe(nil)); end +end + +# For Streaming Input Operations, when `requiresLength` is enabled +# checking whether `Content-Length` header can be set, +# for `unsignedPayload` and `v4-unsigned-body` operations, +# set `Transfer-Encoding` header. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/transfer_encoding.rb#10 +class Aws::Plugins::TransferEncoding < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/transfer_encoding.rb#13 +class Aws::Plugins::TransferEncoding::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/transfer_encoding.rb#14 + def call(context); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/transfer_encoding.rb#45 + def requires_length?(ref); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/transfer_encoding.rb#32 + def streaming?(ref); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/transfer_encoding.rb#40 + def unsigned_payload?(operation); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#6 +class Aws::Plugins::UserAgent < ::Seahorse::Client::Plugin + class << self + # Deprecated - must exist for old service gems + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#44 + def feature(_feature, &block); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#48 + def metric(metric, &block); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#60 +class Aws::Plugins::UserAgent::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#61 + def call(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#66 + def set_user_agent(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#70 +class Aws::Plugins::UserAgent::Handler::UserAgent + # @api private + # @return [UserAgent] a new instance of UserAgent + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#71 + def initialize(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#75 + def to_s; end + + private + + # Used to be gem_name/gem_version + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#104 + def api_metadata; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#143 + def app_id_metadata; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#137 + def env_metadata; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#151 + def framework_metadata; end + + # Used to be RUBY_ENGINE/RUBY_VERSION + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#133 + def language_metadata; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#168 + def metric_metadata; end + + # Used to be RUBY_PLATFORM + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#114 + def os_metadata; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/plugins/user_agent.rb#7 +Aws::Plugins::UserAgent::METRICS = T.let(T.unsafe(nil), Hash) + +# A credential provider that executes a given process and attempts +# to read its stdout to receive a JSON payload containing the credentials. +# +# credentials = Aws::ProcessCredentials.new(['/usr/bin/credential_proc']) +# ec2 = Aws::EC2::Client.new(credentials: credentials) +# +# Arguments should be provided as strings in the array, for example: +# +# process = ['/usr/bin/credential_proc', 'arg1', 'arg2'] +# credentials = Aws::ProcessCredentials.new(process) +# ec2 = Aws::EC2::Client.new(credentials: credentials) +# +# Automatically handles refreshing credentials if an Expiration time is +# provided in the credentials payload. +# +# @see https://docs.aws.amazon.com/cli/latest/topic/config-vars.html#sourcing-credentials-from-external-processes +# +# source://aws-sdk-core//lib/aws-sdk-core/process_credentials.rb#20 +class Aws::ProcessCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # Creates a new ProcessCredentials object, which allows an + # external process to be used as a credential provider. + # + # @param process [Array, String] An array of strings including + # the process name and its arguments to execute, or a single string to be + # executed by the shell (deprecated and insecure). + # @return [ProcessCredentials] a new instance of ProcessCredentials + # + # source://aws-sdk-core//lib/aws-sdk-core/process_credentials.rb#31 + def initialize(process); end + + private + + # @raise [Errors::InvalidProcessCredentialsPayload] + # + # source://aws-sdk-core//lib/aws-sdk-core/process_credentials.rb#73 + def _parse_payload_format_v1(creds_json); end + + # @raise [Errors::InvalidProcessCredentialsPayload] + # + # source://aws-sdk-core//lib/aws-sdk-core/process_credentials.rb#45 + def credentials_from_process; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/process_credentials.rb#92 + def near_expiration?(expiration_length); end + + # source://aws-sdk-core//lib/aws-sdk-core/process_credentials.rb#88 + def refresh; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#5 +module Aws::Query; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/ec2_handler.rb#6 +class Aws::Query::EC2Handler < ::Aws::Query::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_handler.rb#8 + def apply_params(param_list, params, rules); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_handler.rb#12 + def parse_xml(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#7 +class Aws::Query::EC2ParamBuilder + include ::Seahorse::Model::Shapes + + # @api private + # @return [EC2ParamBuilder] a new instance of EC2ParamBuilder + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#11 + def initialize(param_list); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#17 + def apply(ref, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#15 + def params; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#66 + def blob(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#42 + def format(ref, value, prefix); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#33 + def list(ref, values, prefix); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#54 + def query_name(ref); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#58 + def set(name, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#23 + def structure(ref, values, prefix); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#71 + def timestamp(ref, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/ec2_param_builder.rb#62 + def ucfirst(str); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#6 +class Aws::Query::Handler < ::Seahorse::Client::Handler + include ::Seahorse::Model::Shapes + + # @api private + # @param context [Seahorse::Client::RequestContext] + # @return [Seahorse::Client::Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#28 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#55 + def apply_params(param_list, params, rules); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#43 + def build_request(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#59 + def parse_xml(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#81 + def remove_wrapper(data, context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#68 + def rules(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#64 + def xml(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#10 +Aws::Query::Handler::CONTENT_TYPE = T.let(T.unsafe(nil), String) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#16 +Aws::Query::Handler::METADATA_REF = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ShapeRef) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#14 +class Aws::Query::Handler::METADATA_STRUCT < ::Struct + # Returns the value of attribute request_id + # + # @return [Object] the current value of request_id + def request_id; end + + # Sets the attribute request_id + # + # @param value [Object] the value to set the attribute request_id to. + # @return [Object] the newly set value + def request_id=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/handler.rb#12 +class Aws::Query::Handler::WRAPPER_STRUCT < ::Struct + # Returns the value of attribute response_metadata + # + # @return [Object] the current value of response_metadata + def response_metadata; end + + # Sets the attribute response_metadata + # + # @param value [Object] the value to set the attribute response_metadata to. + # @return [Object] the newly set value + def response_metadata=(_); end + + # Returns the value of attribute result + # + # @return [Object] the current value of result + def result; end + + # Sets the attribute result + # + # @param value [Object] the value to set the attribute result to. + # @return [Object] the newly set value + def result=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#5 +class Aws::Query::Param + # @api private + # @param name [String] + # @param value [String, nil] (nil) + # @return [Param] a new instance of Param + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#9 + def initialize(name, value = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#33 + def <=>(other); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#26 + def ==(other); end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#15 + def name; end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#21 + def to_s; end + + # @api private + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#18 + def value; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param.rb#39 + def escape(str); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#7 +class Aws::Query::ParamBuilder + include ::Seahorse::Model::Shapes + + # @api private + # @return [ParamBuilder] a new instance of ParamBuilder + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#11 + def initialize(param_list); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#17 + def apply(ref, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#15 + def params; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#98 + def blob(value); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#84 + def flat?(ref); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#65 + def format(ref, value, prefix); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#32 + def list(ref, values, prefix); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#53 + def map(ref, values, prefix); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#76 + def query_name(ref, default = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#80 + def set(name, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#23 + def structure(ref, values, prefix); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_builder.rb#88 + def timestamp(ref, value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#7 +class Aws::Query::ParamList + include ::Enumerable + + # @api private + # @return [ParamList] a new instance of ParamList + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#12 + def initialize; end + + # @api private + # @return [Param, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#27 + def [](param_name); end + + # @api private + # @param param_name [String] + # @param param_value [String, nil] + # @return [Param] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#19 + def []=(param_name, param_value = T.unsafe(nil)); end + + # @api private + # @param param_name [String] + # @return [Param, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#33 + def delete(param_name); end + + # @api private + # @return [Enumerable] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#38 + def each(&block); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#43 + def empty?; end + + # @api private + # @param param_name [String] + # @param param_value [String, nil] + # @return [Param] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#19 + def set(param_name, param_value = T.unsafe(nil)); end + + # @api private + # @return [Array] Returns an array of sorted {Param} objects. + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#48 + def to_a; end + + # @api private + # @return [#read, #rewind, #size] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#58 + def to_io; end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#53 + def to_s; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#63 +class Aws::Query::ParamList::IoWrapper + # @api private + # @param param_list [ParamList] + # @return [IoWrapper] a new instance of IoWrapper + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#66 + def initialize(param_list); end + + # @api private + # @return [ParamList] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#72 + def param_list; end + + # @api private + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#85 + def read(bytes = T.unsafe(nil), output_buffer = T.unsafe(nil)); end + + # @api private + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#80 + def rewind; end + + # @api private + # @return [Integer] + # + # source://aws-sdk-core//lib/aws-sdk-core/query/param_list.rb#75 + def size; end +end + +# Base class used credential classes that can be refreshed. This +# provides basic refresh logic in a thread-safe manner. Classes mixing in +# this module are expected to implement a #refresh method that populates +# the following instance variables: +# +# * `@access_key_id` +# * `@secret_access_key` +# * `@session_token` +# * `@expiration` +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#16 +module Aws::RefreshingCredentials + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#23 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Credentials] + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#32 + def credentials; end + + # Refresh credentials. + # + # @api private + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#39 + def refresh!; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#53 + def async_expiration_length; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#86 + def near_expiration?(expiration_length); end + + # Refreshes credentials asynchronously and synchronously. + # If we are near to expiration, block while getting new credentials. + # Otherwise, if we're approaching expiration, use the existing credentials + # but attempt a refresh in the background. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#61 + def refresh_if_near_expiration!; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#49 + def sync_expiration_length; end +end + +# 10 minutes +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#19 +Aws::RefreshingCredentials::ASYNC_EXPIRATION_LENGTH = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#21 +Aws::RefreshingCredentials::CLIENT_EXCLUDE_OPTIONS = T.let(T.unsafe(nil), Set) + +# 5 minutes +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/refreshing_credentials.rb#18 +Aws::RefreshingCredentials::SYNC_EXPIRATION_LENGTH = T.let(T.unsafe(nil), Integer) + +# Module/mixin used by token provider classes that can be refreshed. This +# provides basic refresh logic in a thread-safe manner. Classes mixing in +# this module are expected to implement a #refresh method that populates +# the following instance variable: +# +# * `@token` [Token] - {Aws::Token} object with the `expiration` and `token` +# fields set. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/refreshing_token.rb#16 +module Aws::RefreshingToken + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_token.rb#18 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Time, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_token.rb#33 + def expiration; end + + # Refresh token. + # + # @api private + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_token.rb#40 + def refresh!; end + + # @api private + # @return [Token] + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_token.rb#27 + def token; end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_token.rb#62 + def near_expiration?; end + + # Refreshes token if it is within + # 5 minutes of expiration. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/refreshing_token.rb#51 + def refresh_if_near_expiration; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#4 +module Aws::Resources; end + +# source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#5 +class Aws::Resources::Collection + include ::Enumerable + extend ::Aws::Deprecations + + # @api private + # @option options + # @option options + # @param batches [Enumerator] + # @param options [Hash] a customizable set of options + # @return [Collection] a new instance of Collection + # + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#14 + def initialize(batches, options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-core//lib/aws-sdk-core/deprecations.rb#65 + def [](*args, &block); end + + # @api private + # @deprecated + # + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#30 + def batches; end + + # @return [Enumerator] + # + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#50 + def each(&block); end + + # @param count [Integer] + # @return [Resource, Collection] + # + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#64 + def first(count = T.unsafe(nil)); end + + # @return [Integer, nil] Returns the size of this collection if known, returns `nil` when + # an API call is necessary to enumerate items in this collection. + # + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#23 + def length; end + + # Returns a new collection that will enumerate a limited number of items. + # + # collection.limit(10).each do |band| + # # yields at most 10 times + # end + # + # @param limit [Integer] + # @return [Collection] + # + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#85 + def limit(limit); end + + # @return [Integer, nil] Returns the size of this collection if known, returns `nil` when + # an API call is necessary to enumerate items in this collection. + # + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#23 + def size; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#91 + def batch_enum; end + + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#107 + def limited_batches; end + + # source://aws-sdk-core//lib/aws-sdk-core/resources/collection.rb#99 + def non_empty_batches; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/handler.rb#5 +module Aws::Rest; end + +# NOTE: headers could be already populated if specified on input shape +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/content_type_handler.rb#6 +class Aws::Rest::ContentTypeHandler < ::Seahorse::Client::Handler + # source://aws-sdk-core//lib/aws-sdk-core/rest/content_type_handler.rb#7 + def call(context); end + + private + + # content-type defaults as noted here: + # rest-json: https://smithy.io/2.0/aws/protocols/aws-restxml-protocol.html#content-type + # rest-xml: https://smithy.io/2.0/aws/protocols/aws-restxml-protocol.html#content-type + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/content_type_handler.rb#46 + def apply_default_content_type(context); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/content_type_handler.rb#36 + def eventstream?(context); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/content_type_handler.rb#32 + def non_empty_body?(body); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/handler.rb#6 +class Aws::Rest::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/handler.rb#8 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/handler.rb#17 + def apply_request_id(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#5 +module Aws::Rest::Request; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#6 +class Aws::Rest::Request::Body + include ::Seahorse::Model::Shapes + + # @api private + # @param serializer_class [Class] + # @param rules [Seahorse::Model::ShapeRef] + # @return [Body] a new instance of Body + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#12 + def initialize(serializer_class, rules); end + + # @api private + # @param http_req [Seahorse::Client::Http::Request] + # @param params [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#19 + def apply(http_req, params); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#93 + def body_params(params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#46 + def build_body(params); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#85 + def json_builder?; end + + # operation is modeled for body when it is modeled for a payload + # either with payload trait or normal members. + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#37 + def modeled_body?; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#69 + def payload_location_name; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#89 + def serialize(rules, params, location_name: T.unsafe(nil)); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#74 + def streaming?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/body.rb#81 + def xml_builder?; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/request/builder.rb#6 +class Aws::Rest::Request::Builder + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/builder.rb#8 + def apply(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/builder.rb#33 + def populate_body(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/builder.rb#21 + def populate_endpoint(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/builder.rb#28 + def populate_headers(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/builder.rb#17 + def populate_http_method(context); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/builder.rb#40 + def serializer_class(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#8 +class Aws::Rest::Request::Endpoint + # @api private + # @param rules [Seahorse::Model::Shapes::ShapeRef] + # @param request_uri_pattern [String] + # @return [Endpoint] a new instance of Endpoint + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#12 + def initialize(rules, request_uri_pattern); end + + # @api private + # @param base_uri [URI::HTTPS, URI::HTTP] + # @param params [Hash, Struct] + # @return [URI::HTTPS, URI::HTTP] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#23 + def uri(base_uri, params); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#32 + def apply_path_params(uri, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#77 + def apply_querystring_params(uri, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#91 + def escape(string); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#61 + def param_name(placeholder); end + + # @api private + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#41 + def param_value_for_placeholder(placeholder, params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/endpoint.rb#67 + def timestamp(ref, value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#9 +class Aws::Rest::Request::Headers + include ::Seahorse::Model::Shapes + + # @api private + # @param rules [Seahorse::Model::ShapeRef] + # @return [Headers] a new instance of Headers + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#14 + def initialize(rules); end + + # @api private + # @param http_req [Seahorse::Client::Http::Request] + # @param params [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#20 + def apply(http_req, params); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#68 + def apply_header_map(headers, ref, values); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#34 + def apply_header_value(headers, ref, value); end + + # With complex headers value in json syntax, + # base64 encodes value to avoid weird characters + # causing potential issues in headers + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#78 + def apply_json_trait(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#53 + def list(headers, ref, values); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/headers.rb#43 + def timestamp(ref, value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#6 +class Aws::Rest::Request::QuerystringBuilder + include ::Seahorse::Model::Shapes + + # Provide shape references and param values: + # + # [ + # [shape_ref1, 123], + # [shape_ref2, "text"] + # ] + # + # Returns a querystring: + # + # "Count=123&Words=text" + # + # @api private + # @param params [Array>] An array of + # model shape references and request parameter value pairs. + # @return [String] Returns a built querystring + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#32 + def build(params); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#50 + def build_part(shape_ref, param_value, query_keys); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#125 + def escape(string); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#85 + def generate_query_list(ref, values); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#93 + def generate_query_map(ref, value, query_keys); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#42 + def query_keys(params); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#105 + def query_map_of_string(hash, query_keys); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#114 + def query_map_of_string_list(hash, query_keys); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#74 + def query_value(ref, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#64 + def timestamp(ref, value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/request/querystring_builder.rb#9 +Aws::Rest::Request::QuerystringBuilder::SUPPORTED_TYPES = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#5 +module Aws::Rest::Response; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#6 +class Aws::Rest::Response::Body + include ::Seahorse::Model::Shapes + + # @api private + # @param parser_class [Class] + # @param rules [Seahorse::Model::ShapeRef] + # @return [Body] a new instance of Body + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#12 + def initialize(parser_class, rules); end + + # @api private + # @param body [IO] + # @param data [Hash, Struct] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#19 + def apply(body, data); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#34 + def empty_blob_payload?(body); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#43 + def empty_body?(body); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#47 + def event_stream?; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#38 + def non_streaming_blob_payload?; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#58 + def parse(body, rules, target = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#62 + def parse_eventstream(body); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/body.rb#51 + def streaming?; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/response/header_list_parser.rb#9 +module Aws::Rest::Response::HeaderListParser + class << self + # parse a list of possibly quoted and escaped string values + # Follows: + # # [RFC-7230's specification of header values](https://datatracker.ietf.org/doc/html/rfc7230#section-3.2.6). + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/header_list_parser.rb#15 + def parse_string_list(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/header_list_parser.rb#24 + def parse_timestamp_list(value, ref); end + + private + + # @api private + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/header_list_parser.rb#64 + def read_quoted_value(buffer); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/header_list_parser.rb#57 + def read_unquoted_value(buffer); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/header_list_parser.rb#39 + def read_value(buffer); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/response/headers.rb#10 +class Aws::Rest::Response::Headers + include ::Seahorse::Model::Shapes + + # @api private + # @param rules [Seahorse::Model::ShapeRef] + # @return [Headers] a new instance of Headers + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/headers.rb#15 + def initialize(rules); end + + # @api private + # @param http_resp [Seahorse::Client::Http::Response] + # @param target [Hash, Struct] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/headers.rb#21 + def apply(http_resp, target); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/headers.rb#37 + def cast_value(ref, value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/headers.rb#66 + def extract_header_map(headers, name, ref, data); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/headers.rb#31 + def extract_header_value(headers, name, ref, data); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/headers.rb#76 + def extract_json_trait(value); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/response/parser.rb#6 +class Aws::Rest::Response::Parser + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/parser.rb#8 + def apply(response); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/parser.rb#32 + def extract_body(rules, response); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/parser.rb#27 + def extract_headers(rules, response); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/parser.rb#22 + def extract_status_code(rules, response); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/parser.rb#40 + def parser_class(response); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/rest/response/status_code.rb#6 +class Aws::Rest::Response::StatusCode + # @api private + # @param rules [Seahorse::Model::Shapes::ShapeRef] + # @return [StatusCode] a new instance of StatusCode + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/status_code.rb#9 + def initialize(rules); end + + # @api private + # @param http_resp [Seahorse::Client::Http::Response] + # @param data [Hash, Struct] + # + # source://aws-sdk-core//lib/aws-sdk-core/rest/response/status_code.rb#15 + def apply(http_resp, data); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#4 +module Aws::RpcV2; end + +# source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#7 +class Aws::RpcV2::Builder + include ::Seahorse::Model::Shapes + + # @return [Builder] a new instance of Builder + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#10 + def initialize(rules, _options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#14 + def serialize(params); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#47 + def blob(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#51 + def format(ref, value); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#35 + def list(ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#40 + def map(ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/builder.rb#24 + def structure(ref, values); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/content_type_handler.rb#5 +class Aws::RpcV2::ContentTypeHandler < ::Seahorse::Client::Handler + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/content_type_handler.rb#6 + def call(context); end + + private + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/content_type_handler.rb#40 + def empty_input_structure?(context); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/content_type_handler.rb#26 + def eventstream_input?(context); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/content_type_handler.rb#33 + def eventstream_output?(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#5 +class Aws::RpcV2::ErrorHandler < ::Aws::ErrorHandler + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#7 + def call(context); end + + private + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#70 + def aws_query_error?(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#39 + def error_code(data, context); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#29 + def extract_error(body, context); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#54 + def parse_error_data(context, body, code); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#75 + def remove_prefix(error_code, context); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/error_handler.rb#23 + def valid_response?(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#5 +class Aws::RpcV2::Handler < ::Seahorse::Client::Handler + # @param context [Seahorse::Client::RequestContext] + # @return [Seahorse::Client::Response] + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#8 + def call(context); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#65 + def apply_request_id(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#31 + def build_body(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#18 + def build_request(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#25 + def build_url(context); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#35 + def parse_body(context); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/handler.rb#69 + def query_compatible?(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/parser.rb#7 +class Aws::RpcV2::Parser + include ::Seahorse::Model::Shapes + + # @param rules [Seahorse::Model::ShapeRef] + # @return [Parser] a new instance of Parser + # + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/parser.rb#11 + def initialize(rules, query_compatible: T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/parser.rb#16 + def parse(cbor, target = T.unsafe(nil)); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/parser.rb#60 + def list(ref, values, target = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/parser.rb#68 + def map(ref, values, target = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/parser.rb#76 + def parse_ref(ref, value, target = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/rpc_v2/parser.rb#24 + def structure(ref, values, target = T.unsafe(nil)); end +end + +# This module provides support for AWS Single Sign-On. This module is available in the +# `aws-sdk-core` gem. +# +# # Client +# +# The {Client} class provides one method for each API operation. Operation +# methods each accept a hash of request parameters and return a response +# structure. +# +# sso = Aws::SSO::Client.new +# resp = sso.get_role_credentials(params) +# +# See {Client} for more information. +# +# # Errors +# +# Errors returned from AWS Single Sign-On are defined in the +# {Errors} module and all extend {Errors::ServiceError}. +# +# begin +# # do stuff +# rescue Aws::SSO::Errors::ServiceError +# # rescues all AWS Single Sign-On API errors +# end +# +# See {Errors} for more information. +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#10 +module Aws::SSO; end + +# An API client for SSO. To construct a client, you need to configure a `:region` and `:credentials`. +# +# client = Aws::SSO::Client.new( +# region: region_name, +# credentials: credentials, +# # ... +# ) +# +# For details on configuring region and credentials see +# the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html). +# +# See {#initialize} for a full list of supported configuration options. +# +# source://aws-sdk-core//lib/aws-sdk-sso/client.rb#53 +class Aws::SSO::Client < ::Seahorse::Client::Base + include ::Aws::ClientStubs + + # @overload initialize + # @return [Client] a new instance of Client + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#422 + def initialize(*args); end + + # @api private + # @param params [{}] + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#636 + def build_request(operation_name, params = T.unsafe(nil)); end + + # Returns the STS short-term credentials for a given role name that is + # assigned to the user. + # + # @example Request syntax with placeholder values + # + # resp = client.get_role_credentials({ + # role_name: "RoleNameType", # required + # account_id: "AccountIdType", # required + # access_token: "AccessTokenType", # required + # }) + # @example Response structure + # + # resp.role_credentials.access_key_id #=> String + # resp.role_credentials.secret_access_key #=> String + # resp.role_credentials.session_token #=> String + # resp.role_credentials.expiration #=> Integer + # @option params + # @option params + # @option params + # @overload get_role_credentials + # @param params [Hash] ({}) + # @return [Types::GetRoleCredentialsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetRoleCredentialsResponse#role_credentials #role_credentials} => Types::RoleCredentials + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/GetRoleCredentials AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#469 + def get_role_credentials(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Lists all roles that are assigned to the user for a given AWS account. + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Request syntax with placeholder values + # + # resp = client.list_account_roles({ + # next_token: "NextTokenType", + # max_results: 1, + # access_token: "AccessTokenType", # required + # account_id: "AccountIdType", # required + # }) + # @example Response structure + # + # resp.next_token #=> String + # resp.role_list #=> Array + # resp.role_list[0].role_name #=> String + # resp.role_list[0].account_id #=> String + # @option params + # @option params + # @option params + # @option params + # @overload list_account_roles + # @param params [Hash] ({}) + # @return [Types::ListAccountRolesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListAccountRolesResponse#next_token #next_token} => String + # * {Types::ListAccountRolesResponse#role_list #role_list} => Array<Types::RoleInfo> + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/ListAccountRoles AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#522 + def list_account_roles(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Lists all AWS accounts assigned to the user. These AWS accounts are + # assigned by the administrator of the account. For more information, + # see [Assign User Access][1] in the *IAM Identity Center User Guide*. + # This operation returns a paginated response. + # + # + # + # [1]: https://docs.aws.amazon.com/singlesignon/latest/userguide/useraccess.html#assignusers + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Request syntax with placeholder values + # + # resp = client.list_accounts({ + # next_token: "NextTokenType", + # max_results: 1, + # access_token: "AccessTokenType", # required + # }) + # @example Response structure + # + # resp.next_token #=> String + # resp.account_list #=> Array + # resp.account_list[0].account_id #=> String + # resp.account_list[0].account_name #=> String + # resp.account_list[0].email_address #=> String + # @option params + # @option params + # @option params + # @overload list_accounts + # @param params [Hash] ({}) + # @return [Types::ListAccountsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListAccountsResponse#next_token #next_token} => String + # * {Types::ListAccountsResponse#account_list #account_list} => Array<Types::AccountInfo> + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/ListAccounts AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#579 + def list_accounts(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Removes the locally stored SSO tokens from the client-side cache and + # sends an API call to the IAM Identity Center service to invalidate the + # corresponding server-side IAM Identity Center sign in session. + # + # If a user uses IAM Identity Center to access the AWS CLI, the user’s + # IAM Identity Center sign in session is used to obtain an IAM session, + # as specified in the corresponding IAM Identity Center permission set. + # More specifically, IAM Identity Center assumes an IAM role in the + # target account on behalf of the user, and the corresponding temporary + # AWS credentials are returned to the client. + # + # After user logout, any existing IAM role sessions that were created by + # using IAM Identity Center permission sets continue based on the + # duration configured in the permission set. For more information, see + # [User authentications][1] in the *IAM Identity Center User Guide*. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/singlesignon/latest/userguide/authconcept.html + # + # @example Request syntax with placeholder values + # + # resp = client.logout({ + # access_token: "AccessTokenType", # required + # }) + # @option params + # @overload logout + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/Logout AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#627 + def logout(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#651 + def waiter_names; end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#661 + def errors_module; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/client.rb#658 + def identifier; end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#12 +module Aws::SSO::ClientApi + include ::Seahorse::Model +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#108 +Aws::SSO::ClientApi::API = T.let(T.unsafe(nil), Seahorse::Model::Api) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#16 +Aws::SSO::ClientApi::AccessKeyType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#17 +Aws::SSO::ClientApi::AccessTokenType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#18 +Aws::SSO::ClientApi::AccountIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#19 +Aws::SSO::ClientApi::AccountInfo = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#20 +Aws::SSO::ClientApi::AccountListType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#21 +Aws::SSO::ClientApi::AccountNameType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#22 +Aws::SSO::ClientApi::EmailAddressType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#23 +Aws::SSO::ClientApi::ErrorDescription = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#24 +Aws::SSO::ClientApi::ExpirationTimestampType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#25 +Aws::SSO::ClientApi::GetRoleCredentialsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#26 +Aws::SSO::ClientApi::GetRoleCredentialsResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#27 +Aws::SSO::ClientApi::InvalidRequestException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#28 +Aws::SSO::ClientApi::ListAccountRolesRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#29 +Aws::SSO::ClientApi::ListAccountRolesResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#30 +Aws::SSO::ClientApi::ListAccountsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#31 +Aws::SSO::ClientApi::ListAccountsResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#32 +Aws::SSO::ClientApi::LogoutRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#33 +Aws::SSO::ClientApi::MaxResultType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#34 +Aws::SSO::ClientApi::NextTokenType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#35 +Aws::SSO::ClientApi::ResourceNotFoundException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#36 +Aws::SSO::ClientApi::RoleCredentials = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#37 +Aws::SSO::ClientApi::RoleInfo = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#38 +Aws::SSO::ClientApi::RoleListType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#39 +Aws::SSO::ClientApi::RoleNameType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#40 +Aws::SSO::ClientApi::SecretAccessKeyType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#41 +Aws::SSO::ClientApi::SessionTokenType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#42 +Aws::SSO::ClientApi::TooManyRequestsException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/client_api.rb#43 +Aws::SSO::ClientApi::UnauthorizedException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# Endpoint parameters used to influence endpoints per request. +# +# source://aws-sdk-core//lib/aws-sdk-sso/endpoint_parameters.rb#33 +class Aws::SSO::EndpointParameters < ::Struct + include ::Aws::Structure + + # @return [EndpointParameters] a new instance of EndpointParameters + # + # source://aws-sdk-core//lib/aws-sdk-sso/endpoint_parameters.rb#51 + def initialize(options = T.unsafe(nil)); end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint; end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint=(_); end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region; end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region=(_); end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack; end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack=(_); end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips; end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-sso/endpoint_provider.rb#11 +class Aws::SSO::EndpointProvider + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-sso/endpoint_provider.rb#12 + def resolve_endpoint(parameters); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#13 +module Aws::SSO::Endpoints; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#15 +class Aws::SSO::Endpoints::GetRoleCredentials + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#16 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#29 +class Aws::SSO::Endpoints::ListAccountRoles + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#30 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#43 +class Aws::SSO::Endpoints::ListAccounts + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#44 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#57 +class Aws::SSO::Endpoints::Logout + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/endpoints.rb#58 + def build(context); end + end +end + +# When SSO returns an error response, the Ruby SDK constructs and raises an error. +# These errors all extend Aws::SSO::Errors::ServiceError < {Aws::Errors::ServiceError} +# +# You can rescue all SSO errors using ServiceError: +# +# begin +# # do stuff +# rescue Aws::SSO::Errors::ServiceError +# # rescues all SSO API errors +# end +# +# +# ## Request Context +# ServiceError objects have a {Aws::Errors::ServiceError#context #context} method that returns +# information about the request that generated the error. +# See {Seahorse::Client::RequestContext} for more information. +# +# ## Error Classes +# * {InvalidRequestException} +# * {ResourceNotFoundException} +# * {TooManyRequestsException} +# * {UnauthorizedException} +# +# Additionally, error classes are dynamically generated for service errors based on the error code +# if they are not defined above. +# +# source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#37 +module Aws::SSO::Errors + extend ::Aws::Errors::DynamicErrors +end + +# source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#41 +class Aws::SSO::Errors::InvalidRequestException < ::Aws::SSO::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSO::Types::InvalidRequestException] + # @return [InvalidRequestException] a new instance of InvalidRequestException + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#46 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#51 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#56 +class Aws::SSO::Errors::ResourceNotFoundException < ::Aws::SSO::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSO::Types::ResourceNotFoundException] + # @return [ResourceNotFoundException] a new instance of ResourceNotFoundException + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#61 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#66 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#0 +class Aws::SSO::Errors::ServiceError < ::Aws::Errors::ServiceError; end + +# source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#71 +class Aws::SSO::Errors::TooManyRequestsException < ::Aws::SSO::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSO::Types::TooManyRequestsException] + # @return [TooManyRequestsException] a new instance of TooManyRequestsException + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#76 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#81 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#86 +class Aws::SSO::Errors::UnauthorizedException < ::Aws::SSO::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSO::Types::UnauthorizedException] + # @return [UnauthorizedException] a new instance of UnauthorizedException + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#91 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sso/errors.rb#96 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sso.rb#57 +Aws::SSO::GEM_VERSION = T.let(T.unsafe(nil), String) + +# source://aws-sdk-core//lib/aws-sdk-sso/plugins/endpoints.rb#12 +module Aws::SSO::Plugins; end + +# source://aws-sdk-core//lib/aws-sdk-sso/plugins/endpoints.rb#13 +class Aws::SSO::Plugins::Endpoints < ::Seahorse::Client::Plugin + # source://aws-sdk-core//lib/aws-sdk-sso/plugins/endpoints.rb#73 + def add_handlers(handlers, _config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sso/plugins/endpoints.rb#27 +class Aws::SSO::Plugins::Endpoints::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/plugins/endpoints.rb#28 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/plugins/endpoints.rb#48 + def apply_endpoint_headers(context, headers); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sso/plugins/endpoints.rb#59 + def parameters_for_operation(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-sso/resource.rb#12 +class Aws::SSO::Resource + # @option options + # @param options [{}] + # @return [Resource] a new instance of Resource + # + # source://aws-sdk-core//lib/aws-sdk-sso/resource.rb#16 + def initialize(options = T.unsafe(nil)); end + + # @return [Client] + # + # source://aws-sdk-core//lib/aws-sdk-sso/resource.rb#21 + def client; end +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#11 +module Aws::SSO::Types; end + +# Provides information about your AWS account. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/AccountInfo AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#32 +class Aws::SSO::Types::AccountInfo < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#33 +Aws::SSO::Types::AccountInfo::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/GetRoleCredentialsRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#60 +class Aws::SSO::Types::GetRoleCredentialsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#61 +Aws::SSO::Types::GetRoleCredentialsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/GetRoleCredentialsResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#72 +class Aws::SSO::Types::GetRoleCredentialsResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#73 +Aws::SSO::Types::GetRoleCredentialsResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that a problem occurred with the input to the request. For +# example, a required parameter might be missing or out of range. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/InvalidRequestException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#86 +class Aws::SSO::Types::InvalidRequestException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#87 +Aws::SSO::Types::InvalidRequestException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/ListAccountRolesRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#120 +class Aws::SSO::Types::ListAccountRolesRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#121 +Aws::SSO::Types::ListAccountRolesRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/ListAccountRolesResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#138 +class Aws::SSO::Types::ListAccountRolesResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#139 +Aws::SSO::Types::ListAccountRolesResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/ListAccountsRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#167 +class Aws::SSO::Types::ListAccountsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#168 +Aws::SSO::Types::ListAccountsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/ListAccountsResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#185 +class Aws::SSO::Types::ListAccountsResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#186 +Aws::SSO::Types::ListAccountsResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/LogoutRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#203 +class Aws::SSO::Types::LogoutRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#204 +Aws::SSO::Types::LogoutRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The specified resource doesn't exist. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/ResourceNotFoundException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#216 +class Aws::SSO::Types::ResourceNotFoundException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#217 +Aws::SSO::Types::ResourceNotFoundException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Provides information about the role credentials that are assigned to +# the user. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/RoleCredentials AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#264 +class Aws::SSO::Types::RoleCredentials < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#265 +Aws::SSO::Types::RoleCredentials::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Provides information about the role that is assigned to the user. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/RoleInfo AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#283 +class Aws::SSO::Types::RoleInfo < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#284 +Aws::SSO::Types::RoleInfo::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the request is being made too frequently and is more +# than what the server can handle. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/TooManyRequestsException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#297 +class Aws::SSO::Types::TooManyRequestsException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#298 +Aws::SSO::Types::TooManyRequestsException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the request is not authorized. This can happen due to +# an invalid access token in the request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-2019-06-10/UnauthorizedException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#311 +class Aws::SSO::Types::UnauthorizedException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sso/types.rb#312 +Aws::SSO::Types::UnauthorizedException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# An auto-refreshing credential provider that assumes a role via +# {Aws::SSO::Client#get_role_credentials} using a cached access +# token. When `sso_session` is specified, token refresh logic from +# {Aws::SSOTokenProvider} will be used to refresh the token if possible. +# This class does NOT implement the SSO login token flow - tokens +# must generated separately by running `aws login` from the +# AWS CLI with the correct profile. The `SSOCredentials` will +# auto-refresh the AWS credentials from SSO. +# +# # You must first run aws sso login --profile your-sso-profile +# sso_credentials = Aws::SSOCredentials.new( +# sso_account_id: '123456789', +# sso_role_name: "role_name", +# sso_region: "us-east-1", +# sso_session: 'my_sso_session' +# ) +# ec2 = Aws::EC2::Client.new(credentials: sso_credentials) +# +# If you omit `:client` option, a new {Aws::SSO::Client} object will be +# constructed with additional options that were provided. +# +# @see Aws::SSO::Client#get_role_credentials +# @see https://docs.aws.amazon.com/singlesignon/latest/userguide/what-is.html +# +# source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#27 +class Aws::SSOCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [SSOCredentials] a new instance of SSOCredentials + # + # source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#69 + def initialize(options = T.unsafe(nil)); end + + # @return [SSO::Client] + # + # source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#121 + def client; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#125 + def read_cached_token; end + + # source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#140 + def refresh; end + + # source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#164 + def sso_cache_file; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#33 +Aws::SSOCredentials::LEGACY_REQUIRED_OPTS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#37 +Aws::SSOCredentials::SSO_LOGIN_GUIDANCE = T.let(T.unsafe(nil), String) + +# source://aws-sdk-core//lib/aws-sdk-core/sso_credentials.rb#34 +Aws::SSOCredentials::TOKEN_PROVIDER_REQUIRED_OPTS = T.let(T.unsafe(nil), Array) + +# This module provides support for AWS SSO OIDC. This module is available in the +# `aws-sdk-core` gem. +# +# # Client +# +# The {Client} class provides one method for each API operation. Operation +# methods each accept a hash of request parameters and return a response +# structure. +# +# ssooidc = Aws::SSOOIDC::Client.new +# resp = ssooidc.create_token(params) +# +# See {Client} for more information. +# +# # Errors +# +# Errors returned from AWS SSO OIDC are defined in the +# {Errors} module and all extend {Errors::ServiceError}. +# +# begin +# # do stuff +# rescue Aws::SSOOIDC::Errors::ServiceError +# # rescues all AWS SSO OIDC API errors +# end +# +# See {Errors} for more information. +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#10 +module Aws::SSOOIDC; end + +# An API client for SSOOIDC. To construct a client, you need to configure a `:region` and `:credentials`. +# +# client = Aws::SSOOIDC::Client.new( +# region: region_name, +# credentials: credentials, +# # ... +# ) +# +# For details on configuring region and credentials see +# the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html). +# +# See {#initialize} for a full list of supported configuration options. +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#53 +class Aws::SSOOIDC::Client < ::Seahorse::Client::Base + include ::Aws::ClientStubs + + # @overload initialize + # @return [Client] a new instance of Client + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#422 + def initialize(*args); end + + # @api private + # @param params [{}] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#989 + def build_request(operation_name, params = T.unsafe(nil)); end + + # Creates and returns access and refresh tokens for clients that are + # authenticated using client secrets. The access token can be used to + # fetch short-term credentials for the assigned AWS accounts or to + # access application APIs using `bearer` authentication. + # + # @example Example: Call OAuth/OIDC /token endpoint for Device Code grant with Secret authentication + # + # resp = client.create_token({ + # client_id: "_yzkThXVzLWVhc3QtMQEXAMPLECLIENTID", + # client_secret: "VERYLONGSECRETeyJraWQiOiJrZXktMTU2NDAyODA5OSIsImFsZyI6IkhTMzg0In0", + # device_code: "yJraWQiOiJrZXktMTU2Njk2ODA4OCIsImFsZyI6IkhTMzIn0EXAMPLEDEVICECODE", + # grant_type: "urn:ietf:params:oauth:grant-type:device-code", + # }) + # + # resp.to_h outputs the following: + # { + # access_token: "aoal-YigITUDiNX1xZwOMXM5MxOWDL0E0jg9P6_C_jKQPxS_SKCP6f0kh1Up4g7TtvQqkMnD-GJiU_S1gvug6SrggAkc0:MGYCMQD3IatVjV7jAJU91kK3PkS/SfA2wtgWzOgZWDOR7sDGN9t0phCZz5It/aes/3C1Zj0CMQCKWOgRaiz6AIhza3DSXQNMLjRKXC8F8ceCsHlgYLMZ7hZidEXAMPLEACCESSTOKEN", + # expires_in: 1579729529, + # refresh_token: "aorvJYubGpU6i91YnH7Mfo-AT2fIVa1zCfA_Rvq9yjVKIP3onFmmykuQ7E93y2I-9Nyj-A_sVvMufaLNL0bqnDRtgAkc0:MGUCMFrRsktMRVlWaOR70XGMFGLL0SlcCw4DiYveIiOVx1uK9BbD0gvAddsW3UTLozXKMgIxAJ3qxUvjpnlLIOaaKOoa/FuNgqJVvr9GMwDtnAtlh9iZzAkEXAMPLEREFRESHTOKEN", + # token_type: "Bearer", + # } + # @example Example: Call OAuth/OIDC /token endpoint for Refresh Token grant with Secret authentication + # + # resp = client.create_token({ + # client_id: "_yzkThXVzLWVhc3QtMQEXAMPLECLIENTID", + # client_secret: "VERYLONGSECRETeyJraWQiOiJrZXktMTU2NDAyODA5OSIsImFsZyI6IkhTMzg0In0", + # grant_type: "refresh_token", + # refresh_token: "aorvJYubGpU6i91YnH7Mfo-AT2fIVa1zCfA_Rvq9yjVKIP3onFmmykuQ7E93y2I-9Nyj-A_sVvMufaLNL0bqnDRtgAkc0:MGUCMFrRsktMRVlWaOR70XGMFGLL0SlcCw4DiYveIiOVx1uK9BbD0gvAddsW3UTLozXKMgIxAJ3qxUvjpnlLIOaaKOoa/FuNgqJVvr9GMwDtnAtlh9iZzAkEXAMPLEREFRESHTOKEN", + # scope: [ + # "codewhisperer:completions", + # ], + # }) + # + # resp.to_h outputs the following: + # { + # access_token: "aoal-YigITUDiNX1xZwOMXM5MxOWDL0E0jg9P6_C_jKQPxS_SKCP6f0kh1Up4g7TtvQqkMnD-GJiU_S1gvug6SrggAkc0:MGYCMQD3IatVjV7jAJU91kK3PkS/SfA2wtgWzOgZWDOR7sDGN9t0phCZz5It/aes/3C1Zj0CMQCKWOgRaiz6AIhza3DSXQNMLjRKXC8F8ceCsHlgYLMZ7hZidEXAMPLEACCESSTOKEN", + # expires_in: 1579729529, + # refresh_token: "aorvJYubGpU6i91YnH7Mfo-AT2fIVa1zCfA_Rvq9yjVKIP3onFmmykuQ7E93y2I-9Nyj-A_sVvMufaLNL0bqnDRtgAkc0:MGUCMFrRsktMRVlWaOR70XGMFGLL0SlcCw4DiYveIiOVx1uK9BbD0gvAddsW3UTLozXKMgIxAJ3qxUvjpnlLIOaaKOoa/FuNgqJVvr9GMwDtnAtlh9iZzAkEXAMPLEREFRESHTOKEN", + # token_type: "Bearer", + # } + # @example Request syntax with placeholder values + # + # resp = client.create_token({ + # client_id: "ClientId", # required + # client_secret: "ClientSecret", # required + # grant_type: "GrantType", # required + # device_code: "DeviceCode", + # code: "AuthCode", + # refresh_token: "RefreshToken", + # scope: ["Scope"], + # redirect_uri: "URI", + # code_verifier: "CodeVerifier", + # }) + # @example Response structure + # + # resp.access_token #=> String + # resp.token_type #=> String + # resp.expires_in #=> Integer + # resp.refresh_token #=> String + # resp.id_token #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload create_token + # @param params [Hash] ({}) + # @return [Types::CreateTokenResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateTokenResponse#access_token #access_token} => String + # * {Types::CreateTokenResponse#token_type #token_type} => String + # * {Types::CreateTokenResponse#expires_in #expires_in} => Integer + # * {Types::CreateTokenResponse#refresh_token #refresh_token} => String + # * {Types::CreateTokenResponse#id_token #id_token} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/CreateToken AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#564 + def create_token(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Creates and returns access and refresh tokens for clients and + # applications that are authenticated using IAM entities. The access + # token can be used to fetch short-term credentials for the assigned + # Amazon Web Services accounts or to access application APIs using + # `bearer` authentication. + # + # @example Example: Call OAuth/OIDC /token endpoint for Authorization Code grant with IAM authentication + # + # resp = client.create_token_with_iam({ + # client_id: "arn:aws:sso::123456789012:application/ssoins-111111111111/apl-222222222222", + # code: "yJraWQiOiJrZXktMTU2Njk2ODA4OCIsImFsZyI6IkhTMzg0In0EXAMPLEAUTHCODE", + # grant_type: "authorization_code", + # redirect_uri: "https://mywebapp.example/redirect", + # scope: [ + # "openid", + # "aws", + # "sts:identity_context", + # ], + # }) + # + # resp.to_h outputs the following: + # { + # access_token: "aoal-YigITUDiNX1xZwOMXM5MxOWDL0E0jg9P6_C_jKQPxS_SKCP6f0kh1Up4g7TtvQqkMnD-GJiU_S1gvug6SrggAkc0:MGYCMQD3IatVjV7jAJU91kK3PkS/SfA2wtgWzOgZWDOR7sDGN9t0phCZz5It/aes/3C1Zj0CMQCKWOgRaiz6AIhza3DSXQNMLjRKXC8F8ceCsHlgYLMZ7hZidEXAMPLEACCESSTOKEN", + # expires_in: 1579729529, + # id_token: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhd3M6aWRlbnRpdHlfc3RvcmVfaWQiOiJkLTMzMzMzMzMzMzMiLCJzdWIiOiI3MzA0NDhmMi1lMGExLTcwYTctYzk1NC0wMDAwMDAwMDAwMDAiLCJhd3M6aW5zdGFuY2VfYWNjb3VudCI6IjExMTExMTExMTExMSIsInN0czppZGVudGl0eV9jb250ZXh0IjoiRVhBTVBMRUlERU5USVRZQ09OVEVYVCIsInN0czphdWRpdF9jb250ZXh0IjoiRVhBTVBMRUFVRElUQ09OVEVYVCIsImlzcyI6Imh0dHBzOi8vaWRlbnRpdHljZW50ZXIuYW1hem9uYXdzLmNvbS9zc29pbnMtMTExMTExMTExMTExIiwiYXdzOmlkZW50aXR5X3N0b3JlX2FybiI6ImFybjphd3M6aWRlbnRpdHlzdG9yZTo6MTExMTExMTExMTExOmlkZW50aXR5c3RvcmUvZC0zMzMzMzMzMzMzIiwiYXVkIjoiYXJuOmF3czpzc286OjEyMzQ1Njc4OTAxMjphcHBsaWNhdGlvbi9zc29pbnMtMTExMTExMTExMTExL2FwbC0yMjIyMjIyMjIyMjIiLCJhd3M6aW5zdGFuY2VfYXJuIjoiYXJuOmF3czpzc286OjppbnN0YW5jZS9zc29pbnMtMTExMTExMTExMTExIiwiYXdzOmNyZWRlbnRpYWxfaWQiOiJfWlIyTjZhVkJqMjdGUEtheWpfcEtwVjc3QVBERl80MXB4ZXRfWWpJdUpONlVJR2RBdkpFWEFNUExFQ1JFRElEIiwiYXV0aF90aW1lIjoiMjAyMC0wMS0yMlQxMjo0NToyOVoiLCJleHAiOjE1Nzk3Mjk1MjksImlhdCI6MTU3OTcyNTkyOX0.Xyah6qbk78qThzJ41iFU2yfGuRqqtKXHrJYwQ8L9Ip0", + # issued_token_type: "urn:ietf:params:oauth:token-type:refresh_token", + # refresh_token: "aorvJYubGpU6i91YnH7Mfo-AT2fIVa1zCfA_Rvq9yjVKIP3onFmmykuQ7E93y2I-9Nyj-A_sVvMufaLNL0bqnDRtgAkc0:MGUCMFrRsktMRVlWaOR70XGMFGLL0SlcCw4DiYveIiOVx1uK9BbD0gvAddsW3UTLozXKMgIxAJ3qxUvjpnlLIOaaKOoa/FuNgqJVvr9GMwDtnAtlh9iZzAkEXAMPLEREFRESHTOKEN", + # scope: [ + # "openid", + # "aws", + # "sts:identity_context", + # ], + # token_type: "Bearer", + # } + # @example Example: Call OAuth/OIDC /token endpoint for Refresh Token grant with IAM authentication + # + # resp = client.create_token_with_iam({ + # client_id: "arn:aws:sso::123456789012:application/ssoins-111111111111/apl-222222222222", + # grant_type: "refresh_token", + # refresh_token: "aorvJYubGpU6i91YnH7Mfo-AT2fIVa1zCfA_Rvq9yjVKIP3onFmmykuQ7E93y2I-9Nyj-A_sVvMufaLNL0bqnDRtgAkc0:MGUCMFrRsktMRVlWaOR70XGMFGLL0SlcCw4DiYveIiOVx1uK9BbD0gvAddsW3UTLozXKMgIxAJ3qxUvjpnlLIOaaKOoa/FuNgqJVvr9GMwDtnAtlh9iZzAkEXAMPLEREFRESHTOKEN", + # }) + # + # resp.to_h outputs the following: + # { + # access_token: "aoal-YigITUDiNX1xZwOMXM5MxOWDL0E0jg9P6_C_jKQPxS_SKCP6f0kh1Up4g7TtvQqkMnD-GJiU_S1gvug6SrggAkc0:MGYCMQD3IatVjV7jAJU91kK3PkS/SfA2wtgWzOgZWDOR7sDGN9t0phCZz5It/aes/3C1Zj0CMQCKWOgRaiz6AIhza3DSXQNMLjRKXC8F8ceCsHlgYLMZ7hZidEXAMPLEACCESSTOKEN", + # expires_in: 1579729529, + # issued_token_type: "urn:ietf:params:oauth:token-type:refresh_token", + # refresh_token: "aorvJYubGpU6i91YnH7Mfo-AT2fIVa1zCfA_Rvq9yjVKIP3onFmmykuQ7E93y2I-9Nyj-A_sVvMufaLNL0bqnDRtgAkc0:MGUCMFrRsktMRVlWaOR70XGMFGLL0SlcCw4DiYveIiOVx1uK9BbD0gvAddsW3UTLozXKMgIxAJ3qxUvjpnlLIOaaKOoa/FuNgqJVvr9GMwDtnAtlh9iZzAkEXAMPLEREFRESHTOKEN", + # scope: [ + # "openid", + # "aws", + # "sts:identity_context", + # ], + # token_type: "Bearer", + # } + # @example Example: Call OAuth/OIDC /token endpoint for JWT Bearer grant with IAM authentication + # + # resp = client.create_token_with_iam({ + # assertion: "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImtpZCI6IjFMVE16YWtpaGlSbGFfOHoyQkVKVlhlV01xbyJ9.eyJ2ZXIiOiIyLjAiLCJpc3MiOiJodHRwczovL2xvZ2luLm1pY3Jvc29mdG9ubGluZS5jb20vOTEyMjA0MGQtNmM2Ny00YzViLWIxMTItMzZhMzA0YjY2ZGFkL3YyLjAiLCJzdWIiOiJBQUFBQUFBQUFBQUFBQUFBQUFBQUFJa3pxRlZyU2FTYUZIeTc4MmJidGFRIiwiYXVkIjoiNmNiMDQwMTgtYTNmNS00NmE3LWI5OTUtOTQwYzc4ZjVhZWYzIiwiZXhwIjoxNTM2MzYxNDExLCJpYXQiOjE1MzYyNzQ3MTEsIm5iZiI6MTUzNjI3NDcxMSwibmFtZSI6IkFiZSBMaW5jb2xuIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiQWJlTGlAbWljcm9zb2Z0LmNvbSIsIm9pZCI6IjAwMDAwMDAwLTAwMDAtMDAwMC02NmYzLTMzMzJlY2E3ZWE4MSIsInRpZCI6IjkxMjIwNDBkLTZjNjctNGM1Yi1iMTEyLTM2YTMwNGI2NmRhZCIsIm5vbmNlIjoiMTIzNTIzIiwiYWlvIjoiRGYyVVZYTDFpeCFsTUNXTVNPSkJjRmF0emNHZnZGR2hqS3Y4cTVnMHg3MzJkUjVNQjVCaXN2R1FPN1lXQnlqZDhpUURMcSFlR2JJRGFreXA1bW5PcmNkcUhlWVNubHRlcFFtUnA2QUlaOGpZIn0.1AFWW-Ck5nROwSlltm7GzZvDwUkqvhSQpm55TQsmVo9Y59cLhRXpvB8n-55HCr9Z6G_31_UbeUkoz612I2j_Sm9FFShSDDjoaLQr54CreGIJvjtmS3EkK9a7SJBbcpL1MpUtlfygow39tFjY7EVNW9plWUvRrTgVk7lYLprvfzw-CIqw3gHC-T7IK_m_xkr08INERBtaecwhTeN4chPC4W3jdmw_lIxzC48YoQ0dB1L9-ImX98Egypfrlbm0IBL5spFzL6JDZIRRJOu8vecJvj1mq-IUhGt0MacxX8jdxYLP-KUu2d9MbNKpCKJuZ7p8gwTL5B7NlUdh_dmSviPWrw", + # client_id: "arn:aws:sso::123456789012:application/ssoins-111111111111/apl-222222222222", + # grant_type: "urn:ietf:params:oauth:grant-type:jwt-bearer", + # }) + # + # resp.to_h outputs the following: + # { + # access_token: "aoal-YigITUDiNX1xZwOMXM5MxOWDL0E0jg9P6_C_jKQPxS_SKCP6f0kh1Up4g7TtvQqkMnD-GJiU_S1gvug6SrggAkc0:MGYCMQD3IatVjV7jAJU91kK3PkS/SfA2wtgWzOgZWDOR7sDGN9t0phCZz5It/aes/3C1Zj0CMQCKWOgRaiz6AIhza3DSXQNMLjRKXC8F8ceCsHlgYLMZ7hZidEXAMPLEACCESSTOKEN", + # expires_in: 1579729529, + # id_token: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhd3M6aWRlbnRpdHlfc3RvcmVfaWQiOiJkLTMzMzMzMzMzMzMiLCJzdWIiOiI3MzA0NDhmMi1lMGExLTcwYTctYzk1NC0wMDAwMDAwMDAwMDAiLCJhd3M6aW5zdGFuY2VfYWNjb3VudCI6IjExMTExMTExMTExMSIsInN0czppZGVudGl0eV9jb250ZXh0IjoiRVhBTVBMRUlERU5USVRZQ09OVEVYVCIsInN0czphdWRpdF9jb250ZXh0IjoiRVhBTVBMRUFVRElUQ09OVEVYVCIsImlzcyI6Imh0dHBzOi8vaWRlbnRpdHljZW50ZXIuYW1hem9uYXdzLmNvbS9zc29pbnMtMTExMTExMTExMTExIiwiYXdzOmlkZW50aXR5X3N0b3JlX2FybiI6ImFybjphd3M6aWRlbnRpdHlzdG9yZTo6MTExMTExMTExMTExOmlkZW50aXR5c3RvcmUvZC0zMzMzMzMzMzMzIiwiYXVkIjoiYXJuOmF3czpzc286OjEyMzQ1Njc4OTAxMjphcHBsaWNhdGlvbi9zc29pbnMtMTExMTExMTExMTExL2FwbC0yMjIyMjIyMjIyMjIiLCJhd3M6aW5zdGFuY2VfYXJuIjoiYXJuOmF3czpzc286OjppbnN0YW5jZS9zc29pbnMtMTExMTExMTExMTExIiwiYXdzOmNyZWRlbnRpYWxfaWQiOiJfWlIyTjZhVkJqMjdGUEtheWpfcEtwVjc3QVBERl80MXB4ZXRfWWpJdUpONlVJR2RBdkpFWEFNUExFQ1JFRElEIiwiYXV0aF90aW1lIjoiMjAyMC0wMS0yMlQxMjo0NToyOVoiLCJleHAiOjE1Nzk3Mjk1MjksImlhdCI6MTU3OTcyNTkyOX0.Xyah6qbk78qThzJ41iFU2yfGuRqqtKXHrJYwQ8L9Ip0", + # issued_token_type: "urn:ietf:params:oauth:token-type:refresh_token", + # refresh_token: "aorvJYubGpU6i91YnH7Mfo-AT2fIVa1zCfA_Rvq9yjVKIP3onFmmykuQ7E93y2I-9Nyj-A_sVvMufaLNL0bqnDRtgAkc0:MGUCMFrRsktMRVlWaOR70XGMFGLL0SlcCw4DiYveIiOVx1uK9BbD0gvAddsW3UTLozXKMgIxAJ3qxUvjpnlLIOaaKOoa/FuNgqJVvr9GMwDtnAtlh9iZzAkEXAMPLEREFRESHTOKEN", + # scope: [ + # "openid", + # "aws", + # "sts:identity_context", + # ], + # token_type: "Bearer", + # } + # @example Example: Call OAuth/OIDC /token endpoint for Token Exchange grant with IAM authentication + # + # resp = client.create_token_with_iam({ + # client_id: "arn:aws:sso::123456789012:application/ssoins-111111111111/apl-222222222222", + # grant_type: "urn:ietf:params:oauth:grant-type:token-exchange", + # requested_token_type: "urn:ietf:params:oauth:token-type:access_token", + # subject_token: "aoak-Hig8TUDPNX1xZwOMXM5MxOWDL0E0jg9P6_C_jKQPxS_SKCP6f0kh1Up4g7TtvQqkMnD-GJiU_S1gvug6SrggAkc0:MGYCMQD3IatVjV7jAJU91kK3PkS/SfA2wtgWzOgZWDOR7sDGN9t0phCZz5It/aes/3C1Zj0CMQCKWOgRaiz6AIhza3DSXQNMLjRKXC8F8ceCsHlgYLMZ7hZDIFFERENTACCESSTOKEN", + # subject_token_type: "urn:ietf:params:oauth:token-type:access_token", + # }) + # + # resp.to_h outputs the following: + # { + # access_token: "aoal-YigITUDiNX1xZwOMXM5MxOWDL0E0jg9P6_C_jKQPxS_SKCP6f0kh1Up4g7TtvQqkMnD-GJiU_S1gvug6SrggAkc0:MGYCMQD3IatVjV7jAJU91kK3PkS/SfA2wtgWzOgZWDOR7sDGN9t0phCZz5It/aes/3C1Zj0CMQCKWOgRaiz6AIhza3DSXQNMLjRKXC8F8ceCsHlgYLMZ7hZidEXAMPLEACCESSTOKEN", + # expires_in: 1579729529, + # id_token: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhd3M6aWRlbnRpdHlfc3RvcmVfaWQiOiJkLTMzMzMzMzMzMzMiLCJzdWIiOiI3MzA0NDhmMi1lMGExLTcwYTctYzk1NC0wMDAwMDAwMDAwMDAiLCJhd3M6aW5zdGFuY2VfYWNjb3VudCI6IjExMTExMTExMTExMSIsInN0czppZGVudGl0eV9jb250ZXh0IjoiRVhBTVBMRUlERU5USVRZQ09OVEVYVCIsImlzcyI6Imh0dHBzOi8vaWRlbnRpdHljZW50ZXIuYW1hem9uYXdzLmNvbS9zc29pbnMtMTExMTExMTExMTExIiwiYXdzOmlkZW50aXR5X3N0b3JlX2FybiI6ImFybjphd3M6aWRlbnRpdHlzdG9yZTo6MTExMTExMTExMTExOmlkZW50aXR5c3RvcmUvZC0zMzMzMzMzMzMzIiwiYXVkIjoiYXJuOmF3czpzc286OjEyMzQ1Njc4OTAxMjphcHBsaWNhdGlvbi9zc29pbnMtMTExMTExMTExMTExL2FwbC0yMjIyMjIyMjIyMjIiLCJhd3M6aW5zdGFuY2VfYXJuIjoiYXJuOmF3czpzc286OjppbnN0YW5jZS9zc29pbnMtMTExMTExMTExMTExIiwiYXdzOmNyZWRlbnRpYWxfaWQiOiJfWlIyTjZhVkJqMjdGUEtheWpfcEtwVjc3QVBERl80MXB4ZXRfWWpJdUpONlVJR2RBdkpFWEFNUExFQ1JFRElEIiwiYXV0aF90aW1lIjoiMjAyMC0wMS0yMlQxMjo0NToyOVoiLCJleHAiOjE1Nzk3Mjk1MjksImlhdCI6MTU3OTcyNTkyOX0.5SYiW1kMsuUr7nna-l5tlakM0GNbMHvIM2_n0QD23jM", + # issued_token_type: "urn:ietf:params:oauth:token-type:access_token", + # scope: [ + # "openid", + # "aws", + # "sts:identity_context", + # ], + # token_type: "Bearer", + # } + # @example Request syntax with placeholder values + # + # resp = client.create_token_with_iam({ + # client_id: "ClientId", # required + # grant_type: "GrantType", # required + # code: "AuthCode", + # refresh_token: "RefreshToken", + # assertion: "Assertion", + # scope: ["Scope"], + # redirect_uri: "URI", + # subject_token: "SubjectToken", + # subject_token_type: "TokenTypeURI", + # requested_token_type: "TokenTypeURI", + # code_verifier: "CodeVerifier", + # }) + # @example Response structure + # + # resp.access_token #=> String + # resp.token_type #=> String + # resp.expires_in #=> Integer + # resp.refresh_token #=> String + # resp.id_token #=> String + # resp.issued_token_type #=> String + # resp.scope #=> Array + # resp.scope[0] #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload create_token_with_iam + # @param params [Hash] ({}) + # @return [Types::CreateTokenWithIAMResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateTokenWithIAMResponse#access_token #access_token} => String + # * {Types::CreateTokenWithIAMResponse#token_type #token_type} => String + # * {Types::CreateTokenWithIAMResponse#expires_in #expires_in} => Integer + # * {Types::CreateTokenWithIAMResponse#refresh_token #refresh_token} => String + # * {Types::CreateTokenWithIAMResponse#id_token #id_token} => String + # * {Types::CreateTokenWithIAMResponse#issued_token_type #issued_token_type} => String + # * {Types::CreateTokenWithIAMResponse#scope #scope} => Array<String> + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/CreateTokenWithIAM AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#799 + def create_token_with_iam(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Registers a client with IAM Identity Center. This allows clients to + # initiate device authorization. The output should be persisted for + # reuse through many authentication requests. + # + # @example Example: Call OAuth/OIDC /register-client endpoint + # + # resp = client.register_client({ + # client_name: "My IDE Plugin", + # client_type: "public", + # entitled_application_arn: "arn:aws:sso::ACCOUNTID:application/ssoins-1111111111111111/apl-1111111111111111", + # grant_types: [ + # "authorization_code", + # "refresh_token", + # ], + # issuer_url: "https://identitycenter.amazonaws.com/ssoins-1111111111111111", + # redirect_uris: [ + # "127.0.0.1:PORT/oauth/callback", + # ], + # scopes: [ + # "sso:account:access", + # "codewhisperer:completions", + # ], + # }) + # + # resp.to_h outputs the following: + # { + # client_id: "_yzkThXVzLWVhc3QtMQEXAMPLECLIENTID", + # client_id_issued_at: 1579725929, + # client_secret: "VERYLONGSECRETeyJraWQiOiJrZXktMTU2NDAyODA5OSIsImFsZyI6IkhTMzg0In0", + # client_secret_expires_at: 1587584729, + # } + # @example Request syntax with placeholder values + # + # resp = client.register_client({ + # client_name: "ClientName", # required + # client_type: "ClientType", # required + # scopes: ["Scope"], + # redirect_uris: ["URI"], + # grant_types: ["GrantType"], + # issuer_url: "URI", + # entitled_application_arn: "ArnType", + # }) + # @example Response structure + # + # resp.client_id #=> String + # resp.client_secret #=> String + # resp.client_id_issued_at #=> Integer + # resp.client_secret_expires_at #=> Integer + # resp.authorization_endpoint #=> String + # resp.token_endpoint #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload register_client + # @param params [Hash] ({}) + # @return [Types::RegisterClientResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::RegisterClientResponse#client_id #client_id} => String + # * {Types::RegisterClientResponse#client_secret #client_secret} => String + # * {Types::RegisterClientResponse#client_id_issued_at #client_id_issued_at} => Integer + # * {Types::RegisterClientResponse#client_secret_expires_at #client_secret_expires_at} => Integer + # * {Types::RegisterClientResponse#authorization_endpoint #authorization_endpoint} => String + # * {Types::RegisterClientResponse#token_endpoint #token_endpoint} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/RegisterClient AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#905 + def register_client(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Initiates device authorization by requesting a pair of verification + # codes from the authorization service. + # + # @example Example: Call OAuth/OIDC /start-device-authorization endpoint + # + # resp = client.start_device_authorization({ + # client_id: "_yzkThXVzLWVhc3QtMQEXAMPLECLIENTID", + # client_secret: "VERYLONGSECRETeyJraWQiOiJrZXktMTU2NDAyODA5OSIsImFsZyI6IkhTMzg0In0", + # start_url: "https://identitycenter.amazonaws.com/ssoins-111111111111", + # }) + # + # resp.to_h outputs the following: + # { + # device_code: "yJraWQiOiJrZXktMTU2Njk2ODA4OCIsImFsZyI6IkhTMzIn0EXAMPLEDEVICECODE", + # expires_in: 1579729529, + # interval: 1, + # user_code: "makdfsk83yJraWQiOiJrZXktMTU2Njk2sImFsZyI6IkhTMzIn0EXAMPLEUSERCODE", + # verification_uri: "https://device.sso.us-west-2.amazonaws.com", + # verification_uri_complete: "https://device.sso.us-west-2.amazonaws.com?user_code=makdfsk83yJraWQiOiJrZXktMTU2Njk2sImFsZyI6IkhTMzIn0EXAMPLEUSERCODE", + # } + # @example Request syntax with placeholder values + # + # resp = client.start_device_authorization({ + # client_id: "ClientId", # required + # client_secret: "ClientSecret", # required + # start_url: "URI", # required + # }) + # @example Response structure + # + # resp.device_code #=> String + # resp.user_code #=> String + # resp.verification_uri #=> String + # resp.verification_uri_complete #=> String + # resp.expires_in #=> Integer + # resp.interval #=> Integer + # @option params + # @option params + # @option params + # @overload start_device_authorization + # @param params [Hash] ({}) + # @return [Types::StartDeviceAuthorizationResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::StartDeviceAuthorizationResponse#device_code #device_code} => String + # * {Types::StartDeviceAuthorizationResponse#user_code #user_code} => String + # * {Types::StartDeviceAuthorizationResponse#verification_uri #verification_uri} => String + # * {Types::StartDeviceAuthorizationResponse#verification_uri_complete #verification_uri_complete} => String + # * {Types::StartDeviceAuthorizationResponse#expires_in #expires_in} => Integer + # * {Types::StartDeviceAuthorizationResponse#interval #interval} => Integer + # @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/StartDeviceAuthorization AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#980 + def start_device_authorization(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#1004 + def waiter_names; end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#1014 + def errors_module; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/client.rb#1011 + def identifier; end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#12 +module Aws::SSOOIDC::ClientApi + include ::Seahorse::Model +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#204 +Aws::SSOOIDC::ClientApi::API = T.let(T.unsafe(nil), Seahorse::Model::Api) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#16 +Aws::SSOOIDC::ClientApi::AccessDeniedException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#17 +Aws::SSOOIDC::ClientApi::AccessToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#18 +Aws::SSOOIDC::ClientApi::ArnType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#19 +Aws::SSOOIDC::ClientApi::Assertion = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#20 +Aws::SSOOIDC::ClientApi::AuthCode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#21 +Aws::SSOOIDC::ClientApi::AuthorizationPendingException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#22 +Aws::SSOOIDC::ClientApi::ClientId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#23 +Aws::SSOOIDC::ClientApi::ClientName = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#24 +Aws::SSOOIDC::ClientApi::ClientSecret = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#25 +Aws::SSOOIDC::ClientApi::ClientType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#26 +Aws::SSOOIDC::ClientApi::CodeVerifier = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#27 +Aws::SSOOIDC::ClientApi::CreateTokenRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#28 +Aws::SSOOIDC::ClientApi::CreateTokenResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#29 +Aws::SSOOIDC::ClientApi::CreateTokenWithIAMRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#30 +Aws::SSOOIDC::ClientApi::CreateTokenWithIAMResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#31 +Aws::SSOOIDC::ClientApi::DeviceCode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#32 +Aws::SSOOIDC::ClientApi::Error = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#33 +Aws::SSOOIDC::ClientApi::ErrorDescription = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#34 +Aws::SSOOIDC::ClientApi::ExpirationInSeconds = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#35 +Aws::SSOOIDC::ClientApi::ExpiredTokenException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#36 +Aws::SSOOIDC::ClientApi::GrantType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#37 +Aws::SSOOIDC::ClientApi::GrantTypes = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#38 +Aws::SSOOIDC::ClientApi::IdToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#39 +Aws::SSOOIDC::ClientApi::InternalServerException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#40 +Aws::SSOOIDC::ClientApi::IntervalInSeconds = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#41 +Aws::SSOOIDC::ClientApi::InvalidClientException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#42 +Aws::SSOOIDC::ClientApi::InvalidClientMetadataException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#43 +Aws::SSOOIDC::ClientApi::InvalidGrantException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#44 +Aws::SSOOIDC::ClientApi::InvalidRedirectUriException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#45 +Aws::SSOOIDC::ClientApi::InvalidRequestException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#46 +Aws::SSOOIDC::ClientApi::InvalidRequestRegionException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#47 +Aws::SSOOIDC::ClientApi::InvalidScopeException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#48 +Aws::SSOOIDC::ClientApi::Location = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#49 +Aws::SSOOIDC::ClientApi::LongTimeStampType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#50 +Aws::SSOOIDC::ClientApi::RedirectUris = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#51 +Aws::SSOOIDC::ClientApi::RefreshToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#52 +Aws::SSOOIDC::ClientApi::Region = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#53 +Aws::SSOOIDC::ClientApi::RegisterClientRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#54 +Aws::SSOOIDC::ClientApi::RegisterClientResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#55 +Aws::SSOOIDC::ClientApi::Scope = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#56 +Aws::SSOOIDC::ClientApi::Scopes = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#57 +Aws::SSOOIDC::ClientApi::SlowDownException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#58 +Aws::SSOOIDC::ClientApi::StartDeviceAuthorizationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#59 +Aws::SSOOIDC::ClientApi::StartDeviceAuthorizationResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#60 +Aws::SSOOIDC::ClientApi::SubjectToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#61 +Aws::SSOOIDC::ClientApi::TokenType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#62 +Aws::SSOOIDC::ClientApi::TokenTypeURI = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#63 +Aws::SSOOIDC::ClientApi::URI = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#64 +Aws::SSOOIDC::ClientApi::UnauthorizedClientException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#65 +Aws::SSOOIDC::ClientApi::UnsupportedGrantTypeException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/client_api.rb#66 +Aws::SSOOIDC::ClientApi::UserCode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# Endpoint parameters used to influence endpoints per request. +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoint_parameters.rb#33 +class Aws::SSOOIDC::EndpointParameters < ::Struct + include ::Aws::Structure + + # @return [EndpointParameters] a new instance of EndpointParameters + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoint_parameters.rb#51 + def initialize(options = T.unsafe(nil)); end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint; end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint=(_); end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region; end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region=(_); end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack; end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack=(_); end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips; end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoint_provider.rb#11 +class Aws::SSOOIDC::EndpointProvider + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoint_provider.rb#12 + def resolve_endpoint(parameters); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#13 +module Aws::SSOOIDC::Endpoints; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#15 +class Aws::SSOOIDC::Endpoints::CreateToken + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#16 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#29 +class Aws::SSOOIDC::Endpoints::CreateTokenWithIAM + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#30 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#43 +class Aws::SSOOIDC::Endpoints::RegisterClient + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#44 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#57 +class Aws::SSOOIDC::Endpoints::StartDeviceAuthorization + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/endpoints.rb#58 + def build(context); end + end +end + +# When SSOOIDC returns an error response, the Ruby SDK constructs and raises an error. +# These errors all extend Aws::SSOOIDC::Errors::ServiceError < {Aws::Errors::ServiceError} +# +# You can rescue all SSOOIDC errors using ServiceError: +# +# begin +# # do stuff +# rescue Aws::SSOOIDC::Errors::ServiceError +# # rescues all SSOOIDC API errors +# end +# +# +# ## Request Context +# ServiceError objects have a {Aws::Errors::ServiceError#context #context} method that returns +# information about the request that generated the error. +# See {Seahorse::Client::RequestContext} for more information. +# +# ## Error Classes +# * {AccessDeniedException} +# * {AuthorizationPendingException} +# * {ExpiredTokenException} +# * {InternalServerException} +# * {InvalidClientException} +# * {InvalidClientMetadataException} +# * {InvalidGrantException} +# * {InvalidRedirectUriException} +# * {InvalidRequestException} +# * {InvalidRequestRegionException} +# * {InvalidScopeException} +# * {SlowDownException} +# * {UnauthorizedClientException} +# * {UnsupportedGrantTypeException} +# +# Additionally, error classes are dynamically generated for service errors based on the error code +# if they are not defined above. +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#47 +module Aws::SSOOIDC::Errors + extend ::Aws::Errors::DynamicErrors +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#51 +class Aws::SSOOIDC::Errors::AccessDeniedException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::AccessDeniedException] + # @return [AccessDeniedException] a new instance of AccessDeniedException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#56 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#61 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#66 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#71 +class Aws::SSOOIDC::Errors::AuthorizationPendingException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::AuthorizationPendingException] + # @return [AuthorizationPendingException] a new instance of AuthorizationPendingException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#76 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#81 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#86 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#91 +class Aws::SSOOIDC::Errors::ExpiredTokenException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::ExpiredTokenException] + # @return [ExpiredTokenException] a new instance of ExpiredTokenException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#96 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#101 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#106 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#111 +class Aws::SSOOIDC::Errors::InternalServerException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InternalServerException] + # @return [InternalServerException] a new instance of InternalServerException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#116 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#121 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#126 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#131 +class Aws::SSOOIDC::Errors::InvalidClientException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InvalidClientException] + # @return [InvalidClientException] a new instance of InvalidClientException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#136 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#141 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#146 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#151 +class Aws::SSOOIDC::Errors::InvalidClientMetadataException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InvalidClientMetadataException] + # @return [InvalidClientMetadataException] a new instance of InvalidClientMetadataException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#156 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#161 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#166 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#171 +class Aws::SSOOIDC::Errors::InvalidGrantException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InvalidGrantException] + # @return [InvalidGrantException] a new instance of InvalidGrantException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#176 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#181 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#186 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#191 +class Aws::SSOOIDC::Errors::InvalidRedirectUriException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InvalidRedirectUriException] + # @return [InvalidRedirectUriException] a new instance of InvalidRedirectUriException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#196 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#201 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#206 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#211 +class Aws::SSOOIDC::Errors::InvalidRequestException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InvalidRequestException] + # @return [InvalidRequestException] a new instance of InvalidRequestException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#216 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#221 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#226 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#231 +class Aws::SSOOIDC::Errors::InvalidRequestRegionException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InvalidRequestRegionException] + # @return [InvalidRequestRegionException] a new instance of InvalidRequestRegionException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#236 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#251 + def endpoint; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#241 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#246 + def error_description; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#256 + def region; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#261 +class Aws::SSOOIDC::Errors::InvalidScopeException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::InvalidScopeException] + # @return [InvalidScopeException] a new instance of InvalidScopeException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#266 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#271 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#276 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#0 +class Aws::SSOOIDC::Errors::ServiceError < ::Aws::Errors::ServiceError; end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#281 +class Aws::SSOOIDC::Errors::SlowDownException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::SlowDownException] + # @return [SlowDownException] a new instance of SlowDownException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#286 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#291 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#296 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#301 +class Aws::SSOOIDC::Errors::UnauthorizedClientException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::UnauthorizedClientException] + # @return [UnauthorizedClientException] a new instance of UnauthorizedClientException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#306 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#311 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#316 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#321 +class Aws::SSOOIDC::Errors::UnsupportedGrantTypeException < ::Aws::SSOOIDC::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::SSOOIDC::Types::UnsupportedGrantTypeException] + # @return [UnsupportedGrantTypeException] a new instance of UnsupportedGrantTypeException + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#326 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#331 + def error; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/errors.rb#336 + def error_description; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc.rb#57 +Aws::SSOOIDC::GEM_VERSION = T.let(T.unsafe(nil), String) + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/plugins/endpoints.rb#12 +module Aws::SSOOIDC::Plugins; end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/plugins/endpoints.rb#13 +class Aws::SSOOIDC::Plugins::Endpoints < ::Seahorse::Client::Plugin + # source://aws-sdk-core//lib/aws-sdk-ssooidc/plugins/endpoints.rb#73 + def add_handlers(handlers, _config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/plugins/endpoints.rb#27 +class Aws::SSOOIDC::Plugins::Endpoints::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/plugins/endpoints.rb#28 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/plugins/endpoints.rb#48 + def apply_endpoint_headers(context, headers); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/plugins/endpoints.rb#59 + def parameters_for_operation(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/resource.rb#12 +class Aws::SSOOIDC::Resource + # @option options + # @param options [{}] + # @return [Resource] a new instance of Resource + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/resource.rb#16 + def initialize(options = T.unsafe(nil)); end + + # @return [Client] + # + # source://aws-sdk-core//lib/aws-sdk-ssooidc/resource.rb#21 + def client; end +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#11 +module Aws::SSOOIDC::Types; end + +# You do not have sufficient access to perform this action. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/AccessDeniedException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#29 +class Aws::SSOOIDC::Types::AccessDeniedException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#30 +Aws::SSOOIDC::Types::AccessDeniedException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that a request to authorize a client with an access user +# session token is pending. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/AuthorizationPendingException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#51 +class Aws::SSOOIDC::Types::AuthorizationPendingException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#52 +Aws::SSOOIDC::Types::AuthorizationPendingException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/CreateTokenRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#139 +class Aws::SSOOIDC::Types::CreateTokenRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#140 +Aws::SSOOIDC::Types::CreateTokenRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/CreateTokenResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#193 +class Aws::SSOOIDC::Types::CreateTokenResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#194 +Aws::SSOOIDC::Types::CreateTokenResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/CreateTokenWithIAMRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#309 +class Aws::SSOOIDC::Types::CreateTokenWithIAMRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#310 +Aws::SSOOIDC::Types::CreateTokenWithIAMRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/CreateTokenWithIAMResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#370 +class Aws::SSOOIDC::Types::CreateTokenWithIAMResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#371 +Aws::SSOOIDC::Types::CreateTokenWithIAMResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the token issued by the service is expired and is no +# longer valid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/ExpiredTokenException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#392 +class Aws::SSOOIDC::Types::ExpiredTokenException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#393 +Aws::SSOOIDC::Types::ExpiredTokenException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that an error from the service occurred while trying to +# process a request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InternalServerException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#414 +class Aws::SSOOIDC::Types::InternalServerException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#415 +Aws::SSOOIDC::Types::InternalServerException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the `clientId` or `clientSecret` in the request is +# invalid. For example, this can occur when a client sends an incorrect +# `clientId` or an expired `clientSecret`. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InvalidClientException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#437 +class Aws::SSOOIDC::Types::InvalidClientException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#438 +Aws::SSOOIDC::Types::InvalidClientException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the client information sent in the request during +# registration is invalid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InvalidClientMetadataException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#459 +class Aws::SSOOIDC::Types::InvalidClientMetadataException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#460 +Aws::SSOOIDC::Types::InvalidClientMetadataException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that a request contains an invalid grant. This can occur if +# a client makes a CreateToken request with an invalid grant type. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InvalidGrantException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#481 +class Aws::SSOOIDC::Types::InvalidGrantException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#482 +Aws::SSOOIDC::Types::InvalidGrantException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that one or more redirect URI in the request is not +# supported for this operation. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InvalidRedirectUriException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#503 +class Aws::SSOOIDC::Types::InvalidRedirectUriException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#504 +Aws::SSOOIDC::Types::InvalidRedirectUriException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that something is wrong with the input to the request. For +# example, a required parameter might be missing or out of range. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InvalidRequestException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#525 +class Aws::SSOOIDC::Types::InvalidRequestException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#526 +Aws::SSOOIDC::Types::InvalidRequestException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that a token provided as input to the request was issued by +# and is only usable by calling IAM Identity Center endpoints in another +# region. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InvalidRequestRegionException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#559 +class Aws::SSOOIDC::Types::InvalidRequestRegionException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#560 +Aws::SSOOIDC::Types::InvalidRequestRegionException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the scope provided in the request is invalid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/InvalidScopeException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#580 +class Aws::SSOOIDC::Types::InvalidScopeException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#581 +Aws::SSOOIDC::Types::InvalidScopeException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/RegisterClientRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#635 +class Aws::SSOOIDC::Types::RegisterClientRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#636 +Aws::SSOOIDC::Types::RegisterClientRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/RegisterClientResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#676 +class Aws::SSOOIDC::Types::RegisterClientResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#677 +Aws::SSOOIDC::Types::RegisterClientResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the client is making the request too frequently and is +# more than the service can handle. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/SlowDownException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#697 +class Aws::SSOOIDC::Types::SlowDownException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#698 +Aws::SSOOIDC::Types::SlowDownException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/StartDeviceAuthorizationRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#728 +class Aws::SSOOIDC::Types::StartDeviceAuthorizationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#729 +Aws::SSOOIDC::Types::StartDeviceAuthorizationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/StartDeviceAuthorizationResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#772 +class Aws::SSOOIDC::Types::StartDeviceAuthorizationResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#773 +Aws::SSOOIDC::Types::StartDeviceAuthorizationResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the client is not currently authorized to make the +# request. This can happen when a `clientId` is not issued for a public +# client. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/UnauthorizedClientException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#795 +class Aws::SSOOIDC::Types::UnauthorizedClientException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#796 +Aws::SSOOIDC::Types::UnauthorizedClientException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Indicates that the grant type in the request is not supported by the +# service. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/UnsupportedGrantTypeException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#817 +class Aws::SSOOIDC::Types::UnsupportedGrantTypeException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-ssooidc/types.rb#818 +Aws::SSOOIDC::Types::UnsupportedGrantTypeException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#4 +class Aws::SSOTokenProvider + include ::Aws::TokenProvider + include ::Aws::RefreshingToken + + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [SSOTokenProvider] a new instance of SSOTokenProvider + # + # source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#30 + def initialize(options = T.unsafe(nil)); end + + # @return [SSOOIDC::Client] + # + # source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#49 + def client; end + + private + + # return true if all required fields are present + # return false if registrationExpiresAt exists and is later than now + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#123 + def can_refresh_token?(token_json); end + + # source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#95 + def read_cached_token; end + + # source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#53 + def refresh; end + + # source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#113 + def sso_cache_file; end + + # source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#107 + def update_token_cache(token_json); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#13 +Aws::SSOTokenProvider::SSO_LOGIN_GUIDANCE = T.let(T.unsafe(nil), String) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/sso_token_provider.rb#10 +Aws::SSOTokenProvider::SSO_REQUIRED_OPTS = T.let(T.unsafe(nil), Array) + +# This module provides support for AWS Security Token Service. This module is available in the +# `aws-sdk-core` gem. +# +# # Client +# +# The {Client} class provides one method for each API operation. Operation +# methods each accept a hash of request parameters and return a response +# structure. +# +# sts = Aws::STS::Client.new +# resp = sts.assume_role(params) +# +# See {Client} for more information. +# +# # Errors +# +# Errors returned from AWS Security Token Service are defined in the +# {Errors} module and all extend {Errors::ServiceError}. +# +# begin +# # do stuff +# rescue Aws::STS::Errors::ServiceError +# # rescues all AWS Security Token Service API errors +# end +# +# See {Errors} for more information. +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#10 +module Aws::STS; end + +# An API client for STS. To construct a client, you need to configure a `:region` and `:credentials`. +# +# client = Aws::STS::Client.new( +# region: region_name, +# credentials: credentials, +# # ... +# ) +# +# For details on configuring region and credentials see +# the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html). +# +# See {#initialize} for a full list of supported configuration options. +# +# source://aws-sdk-core//lib/aws-sdk-sts/client.rb#54 +class Aws::STS::Client < ::Seahorse::Client::Base + include ::Aws::ClientStubs + + # @overload initialize + # @return [Client] a new instance of Client + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#429 + def initialize(*args); end + + # Returns a set of temporary security credentials that you can use to + # access Amazon Web Services resources. These temporary credentials + # consist of an access key ID, a secret access key, and a security + # token. Typically, you use `AssumeRole` within your account or for + # cross-account access. For a comparison of `AssumeRole` with other API + # operations that produce temporary credentials, see [Requesting + # Temporary Security Credentials][1] and [Comparing the Amazon Web + # Services STS API operations][2] in the *IAM User Guide*. + # + # **Permissions** + # + # The temporary security credentials created by `AssumeRole` can be used + # to make API calls to any Amazon Web Services service with the + # following exception: You cannot call the Amazon Web Services STS + # `GetFederationToken` or `GetSessionToken` API operations. + # + # (Optional) You can pass inline or managed [session policies][3] to + # this operation. You can pass a single JSON policy document to use as + # an inline session policy. You can also specify up to 10 managed policy + # Amazon Resource Names (ARNs) to use as managed session policies. The + # plaintext that you use for both inline and managed session policies + # can't exceed 2,048 characters. Passing policies to this operation + # returns new temporary credentials. The resulting session's + # permissions are the intersection of the role's identity-based policy + # and the session policies. You can use the role's temporary + # credentials in subsequent Amazon Web Services API calls to access + # resources in the account that owns the role. You cannot use session + # policies to grant more permissions than those allowed by the + # identity-based policy of the role that is being assumed. For more + # information, see [Session Policies][3] in the *IAM User Guide*. + # + # When you create a role, you create two policies: a role trust policy + # that specifies *who* can assume the role, and a permissions policy + # that specifies *what* can be done with the role. You specify the + # trusted principal that is allowed to assume the role in the role trust + # policy. + # + # To assume a role from a different account, your Amazon Web Services + # account must be trusted by the role. The trust relationship is defined + # in the role's trust policy when the role is created. That trust + # policy states which accounts are allowed to delegate that access to + # users in the account. + # + # A user who wants to access a role in a different account must also + # have permissions that are delegated from the account administrator. + # The administrator must attach a policy that allows the user to call + # `AssumeRole` for the ARN of the role in the other account. + # + # To allow a user to assume a role in the same account, you can do + # either of the following: + # + # * Attach a policy to the user that allows the user to call + # `AssumeRole` (as long as the role's trust policy trusts the + # account). + # + # * Add the user as a principal directly in the role's trust policy. + # + # You can do either because the role’s trust policy acts as an IAM + # resource-based policy. When a resource-based policy grants access to a + # principal in the same account, no additional identity-based policy is + # required. For more information about trust policies and resource-based + # policies, see [IAM Policies][4] in the *IAM User Guide*. + # + # **Tags** + # + # (Optional) You can pass tag key-value pairs to your session. These + # tags are called session tags. For more information about session tags, + # see [Passing Session Tags in STS][5] in the *IAM User Guide*. + # + # An administrator must grant you the permissions necessary to pass + # session tags. The administrator can also create granular permissions + # to allow you to pass only specific session tags. For more information, + # see [Tutorial: Using Tags for Attribute-Based Access Control][6] in + # the *IAM User Guide*. + # + # You can set the session tags as transitive. Transitive tags persist + # during role chaining. For more information, see [Chaining Roles with + # Session Tags][7] in the *IAM User Guide*. + # + # **Using MFA with AssumeRole** + # + # (Optional) You can include multi-factor authentication (MFA) + # information when you call `AssumeRole`. This is useful for + # cross-account scenarios to ensure that the user that assumes the role + # has been authenticated with an Amazon Web Services MFA device. In that + # scenario, the trust policy of the role being assumed includes a + # condition that tests for MFA authentication. If the caller does not + # include valid MFA information, the request to assume the role is + # denied. The condition in a trust policy that tests for MFA + # authentication might look like the following example. + # + # `"Condition": \{"Bool": \{"aws:MultiFactorAuthPresent": true\}\}` + # + # For more information, see [Configuring MFA-Protected API Access][8] in + # the *IAM User Guide* guide. + # + # To use MFA with `AssumeRole`, you pass values for the `SerialNumber` + # and `TokenCode` parameters. The `SerialNumber` value identifies the + # user's hardware or virtual MFA device. The `TokenCode` is the + # time-based one-time password (TOTP) that the MFA device produces. + # + # + # + # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison + # [3]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session + # [4]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html + # [5]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html + # [6]: https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html + # [7]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining + # [8]: https://docs.aws.amazon.com/IAM/latest/UserGuide/MFAProtectedAPI.html + # + # @example Example: To assume a role + # + # resp = client.assume_role({ + # external_id: "123ABC", + # policy: "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Sid\":\"Stmt1\",\"Effect\":\"Allow\",\"Action\":\"s3:ListAllMyBuckets\",\"Resource\":\"*\"}]}", + # role_arn: "arn:aws:iam::123456789012:role/demo", + # role_session_name: "testAssumeRoleSession", + # tags: [ + # { + # key: "Project", + # value: "Unicorn", + # }, + # { + # key: "Team", + # value: "Automation", + # }, + # { + # key: "Cost-Center", + # value: "12345", + # }, + # ], + # transitive_tag_keys: [ + # "Project", + # "Cost-Center", + # ], + # }) + # + # resp.to_h outputs the following: + # { + # assumed_role_user: { + # arn: "arn:aws:sts::123456789012:assumed-role/demo/Bob", + # assumed_role_id: "ARO123EXAMPLE123:Bob", + # }, + # credentials: { + # access_key_id: "AKIAIOSFODNN7EXAMPLE", + # expiration: Time.parse("2011-07-15T23:28:33.359Z"), + # secret_access_key: "wJalrXUtnFEMI/K7MDENG/bPxRfiCYzEXAMPLEKEY", + # session_token: "AQoDYXdzEPT//////////wEXAMPLEtc764bNrC9SAPBSM22wDOk4x4HIZ8j4FZTwdQWLWsKWHGBuFqwAeMicRXmxfpSPfIeoIYRqTflfKD8YUuwthAx7mSEI/qkPpKPi/kMcGdQrmGdeehM4IC1NtBmUpp2wUE8phUZampKsburEDy0KPkyQDYwT7WZ0wq5VSXDvp75YU9HFvlRd8Tx6q6fE8YQcHNVXAkiY9q6d+xo0rKwT38xVqr7ZD0u0iPPkUL64lIZbqBAz+scqKmlzm8FDrypNC9Yjc8fPOLn9FX9KSYvKTr4rvx3iSIlTJabIQwj2ICCR/oLxBA==", + # }, + # packed_policy_size: 8, + # } + # @example Request syntax with placeholder values + # + # resp = client.assume_role({ + # role_arn: "arnType", # required + # role_session_name: "roleSessionNameType", # required + # policy_arns: [ + # { + # arn: "arnType", + # }, + # ], + # policy: "unrestrictedSessionPolicyDocumentType", + # duration_seconds: 1, + # tags: [ + # { + # key: "tagKeyType", # required + # value: "tagValueType", # required + # }, + # ], + # transitive_tag_keys: ["tagKeyType"], + # external_id: "externalIdType", + # serial_number: "serialNumberType", + # token_code: "tokenCodeType", + # source_identity: "sourceIdentityType", + # provided_contexts: [ + # { + # provider_arn: "arnType", + # context_assertion: "contextAssertionType", + # }, + # ], + # }) + # @example Response structure + # + # resp.credentials.access_key_id #=> String + # resp.credentials.secret_access_key #=> String + # resp.credentials.session_token #=> String + # resp.credentials.expiration #=> Time + # resp.assumed_role_user.assumed_role_id #=> String + # resp.assumed_role_user.arn #=> String + # resp.packed_policy_size #=> Integer + # resp.source_identity #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload assume_role + # @param params [Hash] ({}) + # @return [Types::AssumeRoleResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::AssumeRoleResponse#credentials #credentials} => Types::Credentials + # * {Types::AssumeRoleResponse#assumed_role_user #assumed_role_user} => Types::AssumedRoleUser + # * {Types::AssumeRoleResponse#packed_policy_size #packed_policy_size} => Integer + # * {Types::AssumeRoleResponse#source_identity #source_identity} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRole AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#913 + def assume_role(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a set of temporary security credentials for users who have + # been authenticated via a SAML authentication response. This operation + # provides a mechanism for tying an enterprise identity store or + # directory to role-based Amazon Web Services access without + # user-specific credentials or configuration. For a comparison of + # `AssumeRoleWithSAML` with the other API operations that produce + # temporary credentials, see [Requesting Temporary Security + # Credentials][1] and [Comparing the Amazon Web Services STS API + # operations][2] in the *IAM User Guide*. + # + # The temporary security credentials returned by this operation consist + # of an access key ID, a secret access key, and a security token. + # Applications can use these temporary security credentials to sign + # calls to Amazon Web Services services. + # + # **Session Duration** + # + # By default, the temporary security credentials created by + # `AssumeRoleWithSAML` last for one hour. However, you can use the + # optional `DurationSeconds` parameter to specify the duration of your + # session. Your role session lasts for the duration that you specify, or + # until the time specified in the SAML authentication response's + # `SessionNotOnOrAfter` value, whichever is shorter. You can provide a + # `DurationSeconds` value from 900 seconds (15 minutes) up to the + # maximum session duration setting for the role. This setting can have a + # value from 1 hour to 12 hours. To learn how to view the maximum value + # for your role, see [View the Maximum Session Duration Setting for a + # Role][3] in the *IAM User Guide*. The maximum session duration limit + # applies when you use the `AssumeRole*` API operations or the + # `assume-role*` CLI commands. However the limit does not apply when you + # use those operations to create a console URL. For more information, + # see [Using IAM Roles][4] in the *IAM User Guide*. + # + # [Role chaining][5] limits your CLI or Amazon Web Services API role + # session to a maximum of one hour. When you use the `AssumeRole` API + # operation to assume a role, you can specify the duration of your role + # session with the `DurationSeconds` parameter. You can specify a + # parameter value of up to 43200 seconds (12 hours), depending on the + # maximum session duration setting for your role. However, if you assume + # a role using role chaining and provide a `DurationSeconds` parameter + # value greater than one hour, the operation fails. + # + # + # + # **Permissions** + # + # The temporary security credentials created by `AssumeRoleWithSAML` can + # be used to make API calls to any Amazon Web Services service with the + # following exception: you cannot call the STS `GetFederationToken` or + # `GetSessionToken` API operations. + # + # (Optional) You can pass inline or managed [session policies][6] to + # this operation. You can pass a single JSON policy document to use as + # an inline session policy. You can also specify up to 10 managed policy + # Amazon Resource Names (ARNs) to use as managed session policies. The + # plaintext that you use for both inline and managed session policies + # can't exceed 2,048 characters. Passing policies to this operation + # returns new temporary credentials. The resulting session's + # permissions are the intersection of the role's identity-based policy + # and the session policies. You can use the role's temporary + # credentials in subsequent Amazon Web Services API calls to access + # resources in the account that owns the role. You cannot use session + # policies to grant more permissions than those allowed by the + # identity-based policy of the role that is being assumed. For more + # information, see [Session Policies][6] in the *IAM User Guide*. + # + # Calling `AssumeRoleWithSAML` does not require the use of Amazon Web + # Services security credentials. The identity of the caller is validated + # by using keys in the metadata document that is uploaded for the SAML + # provider entity for your identity provider. + # + # Calling `AssumeRoleWithSAML` can result in an entry in your CloudTrail + # logs. The entry includes the value in the `NameID` element of the SAML + # assertion. We recommend that you use a `NameIDType` that is not + # associated with any personally identifiable information (PII). For + # example, you could instead use the persistent identifier + # (`urn:oasis:names:tc:SAML:2.0:nameid-format:persistent`). + # + # **Tags** + # + # (Optional) You can configure your IdP to pass attributes into your + # SAML assertion as session tags. Each session tag consists of a key + # name and an associated value. For more information about session tags, + # see [Passing Session Tags in STS][7] in the *IAM User Guide*. + # + # You can pass up to 50 session tags. The plaintext session tag keys + # can’t exceed 128 characters and the values can’t exceed 256 + # characters. For these and additional limits, see [IAM and STS + # Character Limits][8] in the *IAM User Guide*. + # + # An Amazon Web Services conversion compresses the passed inline session + # policy, managed policy ARNs, and session tags into a packed binary + # format that has a separate limit. Your request can fail for this limit + # even if your plaintext meets the other requirements. The + # `PackedPolicySize` response element indicates by percentage how close + # the policies and tags for your request are to the upper size limit. + # + # + # + # You can pass a session tag with the same key as a tag that is attached + # to the role. When you do, session tags override the role's tags with + # the same key. + # + # An administrator must grant you the permissions necessary to pass + # session tags. The administrator can also create granular permissions + # to allow you to pass only specific session tags. For more information, + # see [Tutorial: Using Tags for Attribute-Based Access Control][9] in + # the *IAM User Guide*. + # + # You can set the session tags as transitive. Transitive tags persist + # during role chaining. For more information, see [Chaining Roles with + # Session Tags][10] in the *IAM User Guide*. + # + # **SAML Configuration** + # + # Before your application can call `AssumeRoleWithSAML`, you must + # configure your SAML identity provider (IdP) to issue the claims + # required by Amazon Web Services. Additionally, you must use Identity + # and Access Management (IAM) to create a SAML provider entity in your + # Amazon Web Services account that represents your identity provider. + # You must also create an IAM role that specifies this SAML provider in + # its trust policy. + # + # For more information, see the following resources: + # + # * [About SAML 2.0-based Federation][11] in the *IAM User Guide*. + # + # * [Creating SAML Identity Providers][12] in the *IAM User Guide*. + # + # * [Configuring a Relying Party and Claims][13] in the *IAM User + # Guide*. + # + # * [Creating a Role for SAML 2.0 Federation][14] in the *IAM User + # Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison + # [3]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session + # [4]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html + # [5]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_terms-and-concepts.html#iam-term-role-chaining + # [6]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session + # [7]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html + # [8]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length + # [9]: https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html + # [10]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining + # [11]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_saml.html + # [12]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml.html + # [13]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml_relying-party.html + # [14]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_saml.html + # + # @example Example: To assume a role using a SAML assertion + # + # resp = client.assume_role_with_saml({ + # duration_seconds: 3600, + # principal_arn: "arn:aws:iam::123456789012:saml-provider/SAML-test", + # role_arn: "arn:aws:iam::123456789012:role/TestSaml", + # saml_assertion: "VERYLONGENCODEDASSERTIONEXAMPLExzYW1sOkF1ZGllbmNlPmJsYW5rPC9zYW1sOkF1ZGllbmNlPjwvc2FtbDpBdWRpZW5jZVJlc3RyaWN0aW9uPjwvc2FtbDpDb25kaXRpb25zPjxzYW1sOlN1YmplY3Q+PHNhbWw6TmFtZUlEIEZvcm1hdD0idXJuOm9hc2lzOm5hbWVzOnRjOlNBTUw6Mi4wOm5hbWVpZC1mb3JtYXQ6dHJhbnNpZW50Ij5TYW1sRXhhbXBsZTwvc2FtbDpOYW1lSUQ+PHNhbWw6U3ViamVjdENvbmZpcm1hdGlvbiBNZXRob2Q9InVybjpvYXNpczpuYW1lczp0YzpTQU1MOjIuMDpjbTpiZWFyZXIiPjxzYW1sOlN1YmplY3RDb25maXJtYXRpb25EYXRhIE5vdE9uT3JBZnRlcj0iMjAxOS0xMS0wMVQyMDoyNTowNS4xNDVaIiBSZWNpcGllbnQ9Imh0dHBzOi8vc2lnbmluLmF3cy5hbWF6b24uY29tL3NhbWwiLz48L3NhbWw6U3ViamVjdENvbmZpcm1hdGlvbj48L3NhbWw6U3ViamVjdD48c2FtbDpBdXRoblN0YXRlbWVudCBBdXRoPD94bWwgdmpSZXNwb25zZT4=", + # }) + # + # resp.to_h outputs the following: + # { + # assumed_role_user: { + # arn: "arn:aws:sts::123456789012:assumed-role/TestSaml", + # assumed_role_id: "ARO456EXAMPLE789:TestSaml", + # }, + # audience: "https://signin.aws.amazon.com/saml", + # credentials: { + # access_key_id: "ASIAV3ZUEFP6EXAMPLE", + # expiration: Time.parse("2019-11-01T20:26:47Z"), + # secret_access_key: "8P+SQvWIuLnKhh8d++jpw0nNmQRBZvNEXAMPLEKEY", + # session_token: "IQoJb3JpZ2luX2VjEOz////////////////////wEXAMPLEtMSJHMEUCIDoKK3JH9uGQE1z0sINr5M4jk+Na8KHDcCYRVjJCZEvOAiEA3OvJGtw1EcViOleS2vhs8VdCKFJQWPQrmGdeehM4IC1NtBmUpp2wUE8phUZampKsburEDy0KPkyQDYwT7WZ0wq5VSXDvp75YU9HFvlRd8Tx6q6fE8YQcHNVXAkiY9q6d+xo0rKwT38xVqr7ZD0u0iPPkUL64lIZbqBAz+scqKmlzm8FDrypNC9Yjc8fPOLn9FX9KSYvKTr4rvx3iSIlTJabIQwj2ICCR/oLxBA==", + # }, + # issuer: "https://integ.example.com/idp/shibboleth", + # name_qualifier: "SbdGOnUkh1i4+EXAMPLExL/jEvs=", + # packed_policy_size: 6, + # subject: "SamlExample", + # subject_type: "transient", + # } + # @example Request syntax with placeholder values + # + # resp = client.assume_role_with_saml({ + # role_arn: "arnType", # required + # principal_arn: "arnType", # required + # saml_assertion: "SAMLAssertionType", # required + # policy_arns: [ + # { + # arn: "arnType", + # }, + # ], + # policy: "sessionPolicyDocumentType", + # duration_seconds: 1, + # }) + # @example Response structure + # + # resp.credentials.access_key_id #=> String + # resp.credentials.secret_access_key #=> String + # resp.credentials.session_token #=> String + # resp.credentials.expiration #=> Time + # resp.assumed_role_user.assumed_role_id #=> String + # resp.assumed_role_user.arn #=> String + # resp.packed_policy_size #=> Integer + # resp.subject #=> String + # resp.subject_type #=> String + # resp.issuer #=> String + # resp.audience #=> String + # resp.name_qualifier #=> String + # resp.source_identity #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload assume_role_with_saml + # @param params [Hash] ({}) + # @return [Types::AssumeRoleWithSAMLResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::AssumeRoleWithSAMLResponse#credentials #credentials} => Types::Credentials + # * {Types::AssumeRoleWithSAMLResponse#assumed_role_user #assumed_role_user} => Types::AssumedRoleUser + # * {Types::AssumeRoleWithSAMLResponse#packed_policy_size #packed_policy_size} => Integer + # * {Types::AssumeRoleWithSAMLResponse#subject #subject} => String + # * {Types::AssumeRoleWithSAMLResponse#subject_type #subject_type} => String + # * {Types::AssumeRoleWithSAMLResponse#issuer #issuer} => String + # * {Types::AssumeRoleWithSAMLResponse#audience #audience} => String + # * {Types::AssumeRoleWithSAMLResponse#name_qualifier #name_qualifier} => String + # * {Types::AssumeRoleWithSAMLResponse#source_identity #source_identity} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithSAML AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#1265 + def assume_role_with_saml(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a set of temporary security credentials for users who have + # been authenticated in a mobile or web application with a web identity + # provider. Example providers include the OAuth 2.0 providers Login with + # Amazon and Facebook, or any OpenID Connect-compatible identity + # provider such as Google or [Amazon Cognito federated identities][1]. + # + # For mobile applications, we recommend that you use Amazon Cognito. You + # can use Amazon Cognito with the [Amazon Web Services SDK for iOS + # Developer Guide][2] and the [Amazon Web Services SDK for Android + # Developer Guide][3] to uniquely identify a user. You can also supply + # the user with a consistent identity throughout the lifetime of an + # application. + # + # To learn more about Amazon Cognito, see [Amazon Cognito identity + # pools][1] in *Amazon Cognito Developer Guide*. + # + # + # + # Calling `AssumeRoleWithWebIdentity` does not require the use of Amazon + # Web Services security credentials. Therefore, you can distribute an + # application (for example, on mobile devices) that requests temporary + # security credentials without including long-term Amazon Web Services + # credentials in the application. You also don't need to deploy + # server-based proxy services that use long-term Amazon Web Services + # credentials. Instead, the identity of the caller is validated by using + # a token from the web identity provider. For a comparison of + # `AssumeRoleWithWebIdentity` with the other API operations that produce + # temporary credentials, see [Requesting Temporary Security + # Credentials][4] and [Comparing the Amazon Web Services STS API + # operations][5] in the *IAM User Guide*. + # + # The temporary security credentials returned by this API consist of an + # access key ID, a secret access key, and a security token. Applications + # can use these temporary security credentials to sign calls to Amazon + # Web Services service API operations. + # + # **Session Duration** + # + # By default, the temporary security credentials created by + # `AssumeRoleWithWebIdentity` last for one hour. However, you can use + # the optional `DurationSeconds` parameter to specify the duration of + # your session. You can provide a value from 900 seconds (15 minutes) up + # to the maximum session duration setting for the role. This setting can + # have a value from 1 hour to 12 hours. To learn how to view the maximum + # value for your role, see [View the Maximum Session Duration Setting + # for a Role][6] in the *IAM User Guide*. The maximum session duration + # limit applies when you use the `AssumeRole*` API operations or the + # `assume-role*` CLI commands. However the limit does not apply when you + # use those operations to create a console URL. For more information, + # see [Using IAM Roles][7] in the *IAM User Guide*. + # + # **Permissions** + # + # The temporary security credentials created by + # `AssumeRoleWithWebIdentity` can be used to make API calls to any + # Amazon Web Services service with the following exception: you cannot + # call the STS `GetFederationToken` or `GetSessionToken` API operations. + # + # (Optional) You can pass inline or managed [session policies][8] to + # this operation. You can pass a single JSON policy document to use as + # an inline session policy. You can also specify up to 10 managed policy + # Amazon Resource Names (ARNs) to use as managed session policies. The + # plaintext that you use for both inline and managed session policies + # can't exceed 2,048 characters. Passing policies to this operation + # returns new temporary credentials. The resulting session's + # permissions are the intersection of the role's identity-based policy + # and the session policies. You can use the role's temporary + # credentials in subsequent Amazon Web Services API calls to access + # resources in the account that owns the role. You cannot use session + # policies to grant more permissions than those allowed by the + # identity-based policy of the role that is being assumed. For more + # information, see [Session Policies][8] in the *IAM User Guide*. + # + # **Tags** + # + # (Optional) You can configure your IdP to pass attributes into your web + # identity token as session tags. Each session tag consists of a key + # name and an associated value. For more information about session tags, + # see [Passing Session Tags in STS][9] in the *IAM User Guide*. + # + # You can pass up to 50 session tags. The plaintext session tag keys + # can’t exceed 128 characters and the values can’t exceed 256 + # characters. For these and additional limits, see [IAM and STS + # Character Limits][10] in the *IAM User Guide*. + # + # An Amazon Web Services conversion compresses the passed inline session + # policy, managed policy ARNs, and session tags into a packed binary + # format that has a separate limit. Your request can fail for this limit + # even if your plaintext meets the other requirements. The + # `PackedPolicySize` response element indicates by percentage how close + # the policies and tags for your request are to the upper size limit. + # + # + # + # You can pass a session tag with the same key as a tag that is attached + # to the role. When you do, the session tag overrides the role tag with + # the same key. + # + # An administrator must grant you the permissions necessary to pass + # session tags. The administrator can also create granular permissions + # to allow you to pass only specific session tags. For more information, + # see [Tutorial: Using Tags for Attribute-Based Access Control][11] in + # the *IAM User Guide*. + # + # You can set the session tags as transitive. Transitive tags persist + # during role chaining. For more information, see [Chaining Roles with + # Session Tags][12] in the *IAM User Guide*. + # + # **Identities** + # + # Before your application can call `AssumeRoleWithWebIdentity`, you must + # have an identity token from a supported identity provider and create a + # role that the application can assume. The role that your application + # assumes must trust the identity provider that is associated with the + # identity token. In other words, the identity provider must be + # specified in the role's trust policy. + # + # Calling `AssumeRoleWithWebIdentity` can result in an entry in your + # CloudTrail logs. The entry includes the [Subject][13] of the provided + # web identity token. We recommend that you avoid using any personally + # identifiable information (PII) in this field. For example, you could + # instead use a GUID or a pairwise identifier, as [suggested in the OIDC + # specification][14]. + # + # For more information about how to use web identity federation and the + # `AssumeRoleWithWebIdentity` API, see the following resources: + # + # * [Using Web Identity Federation API Operations for Mobile Apps][15] + # and [Federation Through a Web-based Identity Provider][16]. + # + # * [ Web Identity Federation Playground][17]. Walk through the process + # of authenticating through Login with Amazon, Facebook, or Google, + # getting temporary security credentials, and then using those + # credentials to make a request to Amazon Web Services. + # + # * [Amazon Web Services SDK for iOS Developer Guide][2] and [Amazon Web + # Services SDK for Android Developer Guide][3]. These toolkits contain + # sample apps that show how to invoke the identity providers. The + # toolkits then show how to use the information from these providers + # to get and use temporary security credentials. + # + # * [Web Identity Federation with Mobile Applications][18]. This article + # discusses web identity federation and shows an example of how to use + # web identity federation to get access to content in Amazon S3. + # + # + # + # [1]: https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-identity.html + # [2]: http://aws.amazon.com/sdkforios/ + # [3]: http://aws.amazon.com/sdkforandroid/ + # [4]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html + # [5]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison + # [6]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session + # [7]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html + # [8]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session + # [9]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html + # [10]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length + # [11]: https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html + # [12]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining + # [13]: http://openid.net/specs/openid-connect-core-1_0.html#Claims + # [14]: http://openid.net/specs/openid-connect-core-1_0.html#SubjectIDTypes + # [15]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_oidc_manual.html + # [16]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity + # [17]: https://aws.amazon.com/blogs/aws/the-aws-web-identity-federation-playground/ + # [18]: http://aws.amazon.com/articles/web-identity-federation-with-mobile-applications + # + # @example Example: To assume a role as an OpenID Connect-federated user + # + # resp = client.assume_role_with_web_identity({ + # duration_seconds: 3600, + # policy: "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Sid\":\"Stmt1\",\"Effect\":\"Allow\",\"Action\":\"s3:ListAllMyBuckets\",\"Resource\":\"*\"}]}", + # provider_id: "www.amazon.com", + # role_arn: "arn:aws:iam::123456789012:role/FederatedWebIdentityRole", + # role_session_name: "app1", + # web_identity_token: "Atza%7CIQEBLjAsAhRFiXuWpUXuRvQ9PZL3GMFcYevydwIUFAHZwXZXXXXXXXXJnrulxKDHwy87oGKPznh0D6bEQZTSCzyoCtL_8S07pLpr0zMbn6w1lfVZKNTBdDansFBmtGnIsIapjI6xKR02Yc_2bQ8LZbUXSGm6Ry6_BG7PrtLZtj_dfCTj92xNGed-CrKqjG7nPBjNIL016GGvuS5gSvPRUxWES3VYfm1wl7WTI7jn-Pcb6M-buCgHhFOzTQxod27L9CqnOLio7N3gZAGpsp6n1-AJBOCJckcyXe2c6uD0srOJeZlKUm2eTDVMf8IehDVI0r1QOnTV6KzzAI3OY87Vd_cVMQ", + # }) + # + # resp.to_h outputs the following: + # { + # assumed_role_user: { + # arn: "arn:aws:sts::123456789012:assumed-role/FederatedWebIdentityRole/app1", + # assumed_role_id: "AROACLKWSDQRAOEXAMPLE:app1", + # }, + # audience: "client.5498841531868486423.1548@apps.example.com", + # credentials: { + # access_key_id: "AKIAIOSFODNN7EXAMPLE", + # expiration: Time.parse("2014-10-24T23:00:23Z"), + # secret_access_key: "wJalrXUtnFEMI/K7MDENG/bPxRfiCYzEXAMPLEKEY", + # session_token: "AQoDYXdzEE0a8ANXXXXXXXXNO1ewxE5TijQyp+IEXAMPLE", + # }, + # packed_policy_size: 123, + # provider: "www.amazon.com", + # subject_from_web_identity_token: "amzn1.account.AF6RHO7KZU5XRVQJGXK6HEXAMPLE", + # } + # @example Request syntax with placeholder values + # + # resp = client.assume_role_with_web_identity({ + # role_arn: "arnType", # required + # role_session_name: "roleSessionNameType", # required + # web_identity_token: "clientTokenType", # required + # provider_id: "urlType", + # policy_arns: [ + # { + # arn: "arnType", + # }, + # ], + # policy: "sessionPolicyDocumentType", + # duration_seconds: 1, + # }) + # @example Response structure + # + # resp.credentials.access_key_id #=> String + # resp.credentials.secret_access_key #=> String + # resp.credentials.session_token #=> String + # resp.credentials.expiration #=> Time + # resp.subject_from_web_identity_token #=> String + # resp.assumed_role_user.assumed_role_id #=> String + # resp.assumed_role_user.arn #=> String + # resp.packed_policy_size #=> Integer + # resp.provider #=> String + # resp.audience #=> String + # resp.source_identity #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload assume_role_with_web_identity + # @param params [Hash] ({}) + # @return [Types::AssumeRoleWithWebIdentityResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::AssumeRoleWithWebIdentityResponse#credentials #credentials} => Types::Credentials + # * {Types::AssumeRoleWithWebIdentityResponse#subject_from_web_identity_token #subject_from_web_identity_token} => String + # * {Types::AssumeRoleWithWebIdentityResponse#assumed_role_user #assumed_role_user} => Types::AssumedRoleUser + # * {Types::AssumeRoleWithWebIdentityResponse#packed_policy_size #packed_policy_size} => Integer + # * {Types::AssumeRoleWithWebIdentityResponse#provider #provider} => String + # * {Types::AssumeRoleWithWebIdentityResponse#audience #audience} => String + # * {Types::AssumeRoleWithWebIdentityResponse#source_identity #source_identity} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithWebIdentity AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#1643 + def assume_role_with_web_identity(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # @api private + # @param params [{}] + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#2383 + def build_request(operation_name, params = T.unsafe(nil)); end + + # Decodes additional information about the authorization status of a + # request from an encoded message returned in response to an Amazon Web + # Services request. + # + # For example, if a user is not authorized to perform an operation that + # he or she has requested, the request returns a + # `Client.UnauthorizedOperation` response (an HTTP 403 response). Some + # Amazon Web Services operations additionally return an encoded message + # that can provide details about this authorization failure. + # + # Only certain Amazon Web Services operations return an encoded + # authorization message. The documentation for an individual operation + # indicates whether that operation returns an encoded message in + # addition to returning an HTTP code. + # + # + # + # The message is encoded because the details of the authorization status + # can contain privileged information that the user who requested the + # operation should not see. To decode an authorization status message, a + # user must be granted permissions through an IAM [policy][1] to request + # the `DecodeAuthorizationMessage` (`sts:DecodeAuthorizationMessage`) + # action. + # + # The decoded message includes the following type of information: + # + # * Whether the request was denied due to an explicit deny or due to the + # absence of an explicit allow. For more information, see [Determining + # Whether a Request is Allowed or Denied][2] in the *IAM User Guide*. + # + # * The principal who made the request. + # + # * The requested action. + # + # * The requested resource. + # + # * The values of condition keys in the context of the user's request. + # + # + # + # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html#policy-eval-denyallow + # + # @example Example: To decode information about an authorization status of a request + # + # resp = client.decode_authorization_message({ + # encoded_message: "", + # }) + # + # resp.to_h outputs the following: + # { + # decoded_message: "{\"allowed\": \"false\",\"explicitDeny\": \"false\",\"matchedStatements\": \"\",\"failures\": \"\",\"context\": {\"principal\": {\"id\": \"AIDACKCEVSQ6C2EXAMPLE\",\"name\": \"Bob\",\"arn\": \"arn:aws:iam::123456789012:user/Bob\"},\"action\": \"ec2:StopInstances\",\"resource\": \"arn:aws:ec2:us-east-1:123456789012:instance/i-dd01c9bd\",\"conditions\": [{\"item\": {\"key\": \"ec2:Tenancy\",\"values\": [\"default\"]},{\"item\": {\"key\": \"ec2:ResourceTag/elasticbeanstalk:environment-name\",\"values\": [\"Default-Environment\"]}},(Additional items ...)]}}", + # } + # @example Request syntax with placeholder values + # + # resp = client.decode_authorization_message({ + # encoded_message: "encodedMessageType", # required + # }) + # @example Response structure + # + # resp.decoded_message #=> String + # @option params + # @overload decode_authorization_message + # @param params [Hash] ({}) + # @return [Types::DecodeAuthorizationMessageResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DecodeAuthorizationMessageResponse#decoded_message #decoded_message} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/DecodeAuthorizationMessage AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#1724 + def decode_authorization_message(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns the account identifier for the specified access key ID. + # + # Access keys consist of two parts: an access key ID (for example, + # `AKIAIOSFODNN7EXAMPLE`) and a secret access key (for example, + # `wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY`). For more information + # about access keys, see [Managing Access Keys for IAM Users][1] in the + # *IAM User Guide*. + # + # When you pass an access key ID to this operation, it returns the ID of + # the Amazon Web Services account to which the keys belong. Access key + # IDs beginning with `AKIA` are long-term credentials for an IAM user or + # the Amazon Web Services account root user. Access key IDs beginning + # with `ASIA` are temporary credentials that are created using STS + # operations. If the account in the response belongs to you, you can + # sign in as the root user and review your root user access keys. Then, + # you can pull a [credentials report][2] to learn which IAM user owns + # the keys. To learn who requested the temporary credentials for an + # `ASIA` access key, view the STS events in your [CloudTrail logs][3] in + # the *IAM User Guide*. + # + # This operation does not indicate the state of the access key. The key + # might be active, inactive, or deleted. Active keys might not have + # permissions to perform an operation. Providing a deleted access key + # might return an error that the key doesn't exist. + # + # + # + # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_getting-report.html + # [3]: https://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-integration.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_access_key_info({ + # access_key_id: "accessKeyIdType", # required + # }) + # @example Response structure + # + # resp.account #=> String + # @option params + # @overload get_access_key_info + # @param params [Hash] ({}) + # @return [Types::GetAccessKeyInfoResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetAccessKeyInfoResponse#account #account} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetAccessKeyInfo AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#1785 + def get_access_key_info(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns details about the IAM user or role whose credentials are used + # to call the operation. + # + # No permissions are required to perform this operation. If an + # administrator attaches a policy to your identity that explicitly + # denies access to the `sts:GetCallerIdentity` action, you can still + # perform this operation. Permissions are not required because the same + # information is returned when access is denied. To view an example + # response, see [I Am Not Authorized to Perform: + # iam:DeleteVirtualMFADevice][1] in the *IAM User Guide*. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_access-denied-delete-mfa + # + # @example Example: To get details about a calling IAM user + # + # # This example shows a request and response made with the credentials for a user named Alice in the AWS account + # # 123456789012. + # + # resp = client.get_caller_identity({ + # }) + # + # resp.to_h outputs the following: + # { + # account: "123456789012", + # arn: "arn:aws:iam::123456789012:user/Alice", + # user_id: "AKIAI44QH8DHBEXAMPLE", + # } + # @example Example: To get details about a calling user federated with AssumeRole + # + # # This example shows a request and response made with temporary credentials created by AssumeRole. The name of the assumed + # # role is my-role-name, and the RoleSessionName is set to my-role-session-name. + # + # resp = client.get_caller_identity({ + # }) + # + # resp.to_h outputs the following: + # { + # account: "123456789012", + # arn: "arn:aws:sts::123456789012:assumed-role/my-role-name/my-role-session-name", + # user_id: "AKIAI44QH8DHBEXAMPLE:my-role-session-name", + # } + # @example Example: To get details about a calling user federated with GetFederationToken + # + # # This example shows a request and response made with temporary credentials created by using GetFederationToken. The Name + # # parameter is set to my-federated-user-name. + # + # resp = client.get_caller_identity({ + # }) + # + # resp.to_h outputs the following: + # { + # account: "123456789012", + # arn: "arn:aws:sts::123456789012:federated-user/my-federated-user-name", + # user_id: "123456789012:my-federated-user-name", + # } + # @example Response structure + # + # resp.user_id #=> String + # resp.account #=> String + # resp.arn #=> String + # @overload get_caller_identity + # @param params [Hash] ({}) + # @return [Types::GetCallerIdentityResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetCallerIdentityResponse#user_id #user_id} => String + # * {Types::GetCallerIdentityResponse#account #account} => String + # * {Types::GetCallerIdentityResponse#arn #arn} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetCallerIdentity AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#1869 + def get_caller_identity(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a set of temporary security credentials (consisting of an + # access key ID, a secret access key, and a security token) for a user. + # A typical use is in a proxy application that gets temporary security + # credentials on behalf of distributed applications inside a corporate + # network. + # + # You must call the `GetFederationToken` operation using the long-term + # security credentials of an IAM user. As a result, this call is + # appropriate in contexts where those credentials can be safeguarded, + # usually in a server-based application. For a comparison of + # `GetFederationToken` with the other API operations that produce + # temporary credentials, see [Requesting Temporary Security + # Credentials][1] and [Comparing the Amazon Web Services STS API + # operations][2] in the *IAM User Guide*. + # + # Although it is possible to call `GetFederationToken` using the + # security credentials of an Amazon Web Services account root user + # rather than an IAM user that you create for the purpose of a proxy + # application, we do not recommend it. For more information, see + # [Safeguard your root user credentials and don't use them for everyday + # tasks][3] in the *IAM User Guide*. + # + # You can create a mobile-based or browser-based app that can + # authenticate users using a web identity provider like Login with + # Amazon, Facebook, Google, or an OpenID Connect-compatible identity + # provider. In this case, we recommend that you use [Amazon Cognito][4] + # or `AssumeRoleWithWebIdentity`. For more information, see [Federation + # Through a Web-based Identity Provider][5] in the *IAM User Guide*. + # + # + # + # **Session duration** + # + # The temporary credentials are valid for the specified duration, from + # 900 seconds (15 minutes) up to a maximum of 129,600 seconds (36 + # hours). The default session duration is 43,200 seconds (12 hours). + # Temporary credentials obtained by using the root user credentials have + # a maximum duration of 3,600 seconds (1 hour). + # + # **Permissions** + # + # You can use the temporary credentials created by `GetFederationToken` + # in any Amazon Web Services service with the following exceptions: + # + # * You cannot call any IAM operations using the CLI or the Amazon Web + # Services API. This limitation does not apply to console sessions. + # + # * You cannot call any STS operations except `GetCallerIdentity`. + # + # You can use temporary credentials for single sign-on (SSO) to the + # console. + # + # You must pass an inline or managed [session policy][6] to this + # operation. You can pass a single JSON policy document to use as an + # inline session policy. You can also specify up to 10 managed policy + # Amazon Resource Names (ARNs) to use as managed session policies. The + # plaintext that you use for both inline and managed session policies + # can't exceed 2,048 characters. + # + # Though the session policy parameters are optional, if you do not pass + # a policy, then the resulting federated user session has no + # permissions. When you pass session policies, the session permissions + # are the intersection of the IAM user policies and the session policies + # that you pass. This gives you a way to further restrict the + # permissions for a federated user. You cannot use session policies to + # grant more permissions than those that are defined in the permissions + # policy of the IAM user. For more information, see [Session + # Policies][6] in the *IAM User Guide*. For information about using + # `GetFederationToken` to create temporary security credentials, see + # [GetFederationToken—Federation Through a Custom Identity Broker][7]. + # + # You can use the credentials to access a resource that has a + # resource-based policy. If that policy specifically references the + # federated user session in the `Principal` element of the policy, the + # session has the permissions allowed by the policy. These permissions + # are granted in addition to the permissions granted by the session + # policies. + # + # **Tags** + # + # (Optional) You can pass tag key-value pairs to your session. These are + # called session tags. For more information about session tags, see + # [Passing Session Tags in STS][8] in the *IAM User Guide*. + # + # You can create a mobile-based or browser-based app that can + # authenticate users using a web identity provider like Login with + # Amazon, Facebook, Google, or an OpenID Connect-compatible identity + # provider. In this case, we recommend that you use [Amazon Cognito][4] + # or `AssumeRoleWithWebIdentity`. For more information, see [Federation + # Through a Web-based Identity Provider][5] in the *IAM User Guide*. + # + # + # + # An administrator must grant you the permissions necessary to pass + # session tags. The administrator can also create granular permissions + # to allow you to pass only specific session tags. For more information, + # see [Tutorial: Using Tags for Attribute-Based Access Control][9] in + # the *IAM User Guide*. + # + # Tag key–value pairs are not case sensitive, but case is preserved. + # This means that you cannot have separate `Department` and `department` + # tag keys. Assume that the user that you are federating has the + # `Department`=`Marketing` tag and you pass the + # `department`=`engineering` session tag. `Department` and `department` + # are not saved as separate tags, and the session tag passed in the + # request takes precedence over the user tag. + # + # + # + # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison + # [3]: https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#lock-away-credentials + # [4]: http://aws.amazon.com/cognito/ + # [5]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity + # [6]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session + # [7]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getfederationtoken + # [8]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html + # [9]: https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html + # + # @example Example: To get temporary credentials for a role by using GetFederationToken + # + # resp = client.get_federation_token({ + # duration_seconds: 3600, + # name: "testFedUserSession", + # policy: "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Sid\":\"Stmt1\",\"Effect\":\"Allow\",\"Action\":\"s3:ListAllMyBuckets\",\"Resource\":\"*\"}]}", + # tags: [ + # { + # key: "Project", + # value: "Pegasus", + # }, + # { + # key: "Cost-Center", + # value: "98765", + # }, + # ], + # }) + # + # resp.to_h outputs the following: + # { + # credentials: { + # access_key_id: "AKIAIOSFODNN7EXAMPLE", + # expiration: Time.parse("2011-07-15T23:28:33.359Z"), + # secret_access_key: "wJalrXUtnFEMI/K7MDENG/bPxRfiCYzEXAMPLEKEY", + # session_token: "AQoDYXdzEPT//////////wEXAMPLEtc764bNrC9SAPBSM22wDOk4x4HIZ8j4FZTwdQWLWsKWHGBuFqwAeMicRXmxfpSPfIeoIYRqTflfKD8YUuwthAx7mSEI/qkPpKPi/kMcGdQrmGdeehM4IC1NtBmUpp2wUE8phUZampKsburEDy0KPkyQDYwT7WZ0wq5VSXDvp75YU9HFvlRd8Tx6q6fE8YQcHNVXAkiY9q6d+xo0rKwT38xVqr7ZD0u0iPPkUL64lIZbqBAz+scqKmlzm8FDrypNC9Yjc8fPOLn9FX9KSYvKTr4rvx3iSIlTJabIQwj2ICCR/oLxBA==", + # }, + # federated_user: { + # arn: "arn:aws:sts::123456789012:federated-user/Bob", + # federated_user_id: "123456789012:Bob", + # }, + # packed_policy_size: 8, + # } + # @example Request syntax with placeholder values + # + # resp = client.get_federation_token({ + # name: "userNameType", # required + # policy: "sessionPolicyDocumentType", + # policy_arns: [ + # { + # arn: "arnType", + # }, + # ], + # duration_seconds: 1, + # tags: [ + # { + # key: "tagKeyType", # required + # value: "tagValueType", # required + # }, + # ], + # }) + # @example Response structure + # + # resp.credentials.access_key_id #=> String + # resp.credentials.secret_access_key #=> String + # resp.credentials.session_token #=> String + # resp.credentials.expiration #=> Time + # resp.federated_user.federated_user_id #=> String + # resp.federated_user.arn #=> String + # resp.packed_policy_size #=> Integer + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_federation_token + # @param params [Hash] ({}) + # @return [Types::GetFederationTokenResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetFederationTokenResponse#credentials #credentials} => Types::Credentials + # * {Types::GetFederationTokenResponse#federated_user #federated_user} => Types::FederatedUser + # * {Types::GetFederationTokenResponse#packed_policy_size #packed_policy_size} => Integer + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetFederationToken AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#2217 + def get_federation_token(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a set of temporary credentials for an Amazon Web Services + # account or IAM user. The credentials consist of an access key ID, a + # secret access key, and a security token. Typically, you use + # `GetSessionToken` if you want to use MFA to protect programmatic calls + # to specific Amazon Web Services API operations like Amazon EC2 + # `StopInstances`. + # + # MFA-enabled IAM users must call `GetSessionToken` and submit an MFA + # code that is associated with their MFA device. Using the temporary + # security credentials that the call returns, IAM users can then make + # programmatic calls to API operations that require MFA authentication. + # An incorrect MFA code causes the API to return an access denied error. + # For a comparison of `GetSessionToken` with the other API operations + # that produce temporary credentials, see [Requesting Temporary Security + # Credentials][1] and [Comparing the Amazon Web Services STS API + # operations][2] in the *IAM User Guide*. + # + # No permissions are required for users to perform this operation. The + # purpose of the `sts:GetSessionToken` operation is to authenticate the + # user using MFA. You cannot use policies to control authentication + # operations. For more information, see [Permissions for + # GetSessionToken][3] in the *IAM User Guide*. + # + # + # + # **Session Duration** + # + # The `GetSessionToken` operation must be called by using the long-term + # Amazon Web Services security credentials of an IAM user. Credentials + # that are created by IAM users are valid for the duration that you + # specify. This duration can range from 900 seconds (15 minutes) up to a + # maximum of 129,600 seconds (36 hours), with a default of 43,200 + # seconds (12 hours). Credentials based on account credentials can range + # from 900 seconds (15 minutes) up to 3,600 seconds (1 hour), with a + # default of 1 hour. + # + # **Permissions** + # + # The temporary security credentials created by `GetSessionToken` can be + # used to make API calls to any Amazon Web Services service with the + # following exceptions: + # + # * You cannot call any IAM API operations unless MFA authentication + # information is included in the request. + # + # * You cannot call any STS API *except* `AssumeRole` or + # `GetCallerIdentity`. + # + # The credentials that `GetSessionToken` returns are based on + # permissions associated with the IAM user whose credentials were used + # to call the operation. The temporary credentials have the same + # permissions as the IAM user. + # + # Although it is possible to call `GetSessionToken` using the security + # credentials of an Amazon Web Services account root user rather than an + # IAM user, we do not recommend it. If `GetSessionToken` is called using + # root user credentials, the temporary credentials have root user + # permissions. For more information, see [Safeguard your root user + # credentials and don't use them for everyday tasks][4] in the *IAM + # User Guide* + # + # + # + # For more information about using `GetSessionToken` to create temporary + # credentials, see [Temporary Credentials for Users in Untrusted + # Environments][5] in the *IAM User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison + # [3]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_getsessiontoken.html + # [4]: https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#lock-away-credentials + # [5]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken + # + # @example Example: To get temporary credentials for an IAM user or an AWS account + # + # resp = client.get_session_token({ + # duration_seconds: 3600, + # serial_number: "YourMFASerialNumber", + # token_code: "123456", + # }) + # + # resp.to_h outputs the following: + # { + # credentials: { + # access_key_id: "AKIAIOSFODNN7EXAMPLE", + # expiration: Time.parse("2011-07-11T19:55:29.611Z"), + # secret_access_key: "wJalrXUtnFEMI/K7MDENG/bPxRfiCYzEXAMPLEKEY", + # session_token: "AQoEXAMPLEH4aoAH0gNCAPyJxz4BlCFFxWNE1OPTgk5TthT+FvwqnKwRcOIfrRh3c/LTo6UDdyJwOOvEVPvLXCrrrUtdnniCEXAMPLE/IvU1dYUg2RVAJBanLiHb4IgRmpRV3zrkuWJOgQs8IZZaIv2BXIa2R4OlgkBN9bkUDNCJiBeb/AXlzBBko7b15fjrBs2+cTQtpZ3CYWFXG8C5zqx37wnOE49mRl/+OtkIKGO7fAE", + # }, + # } + # @example Request syntax with placeholder values + # + # resp = client.get_session_token({ + # duration_seconds: 1, + # serial_number: "serialNumberType", + # token_code: "tokenCodeType", + # }) + # @example Response structure + # + # resp.credentials.access_key_id #=> String + # resp.credentials.secret_access_key #=> String + # resp.credentials.session_token #=> String + # resp.credentials.expiration #=> Time + # @option params + # @option params + # @option params + # @overload get_session_token + # @param params [Hash] ({}) + # @return [Types::GetSessionTokenResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetSessionTokenResponse#credentials #credentials} => Types::Credentials + # @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetSessionToken AWS API Documentation + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#2374 + def get_session_token(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#2398 + def waiter_names; end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#2408 + def errors_module; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/client.rb#2405 + def identifier; end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#12 +module Aws::STS::ClientApi + include ::Seahorse::Model +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#248 +Aws::STS::ClientApi::API = T.let(T.unsafe(nil), Seahorse::Model::Api) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#16 +Aws::STS::ClientApi::AssumeRoleRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#17 +Aws::STS::ClientApi::AssumeRoleResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#18 +Aws::STS::ClientApi::AssumeRoleWithSAMLRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#19 +Aws::STS::ClientApi::AssumeRoleWithSAMLResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#20 +Aws::STS::ClientApi::AssumeRoleWithWebIdentityRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#21 +Aws::STS::ClientApi::AssumeRoleWithWebIdentityResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#22 +Aws::STS::ClientApi::AssumedRoleUser = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#23 +Aws::STS::ClientApi::Audience = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#24 +Aws::STS::ClientApi::Credentials = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#25 +Aws::STS::ClientApi::DecodeAuthorizationMessageRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#26 +Aws::STS::ClientApi::DecodeAuthorizationMessageResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#27 +Aws::STS::ClientApi::ExpiredTokenException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#28 +Aws::STS::ClientApi::FederatedUser = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#29 +Aws::STS::ClientApi::GetAccessKeyInfoRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#30 +Aws::STS::ClientApi::GetAccessKeyInfoResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#31 +Aws::STS::ClientApi::GetCallerIdentityRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#32 +Aws::STS::ClientApi::GetCallerIdentityResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#33 +Aws::STS::ClientApi::GetFederationTokenRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#34 +Aws::STS::ClientApi::GetFederationTokenResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#35 +Aws::STS::ClientApi::GetSessionTokenRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#36 +Aws::STS::ClientApi::GetSessionTokenResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#37 +Aws::STS::ClientApi::IDPCommunicationErrorException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#38 +Aws::STS::ClientApi::IDPRejectedClaimException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#39 +Aws::STS::ClientApi::InvalidAuthorizationMessageException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#40 +Aws::STS::ClientApi::InvalidIdentityTokenException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#41 +Aws::STS::ClientApi::Issuer = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#42 +Aws::STS::ClientApi::MalformedPolicyDocumentException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#43 +Aws::STS::ClientApi::NameQualifier = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#44 +Aws::STS::ClientApi::PackedPolicyTooLargeException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#45 +Aws::STS::ClientApi::PolicyDescriptorType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#46 +Aws::STS::ClientApi::ProvidedContext = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#47 +Aws::STS::ClientApi::ProvidedContextsListType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#48 +Aws::STS::ClientApi::RegionDisabledException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#49 +Aws::STS::ClientApi::SAMLAssertionType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#50 +Aws::STS::ClientApi::Subject = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#51 +Aws::STS::ClientApi::SubjectType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/client_api.rb#52 +Aws::STS::ClientApi::Tag = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# Endpoint parameters used to influence endpoints per request. +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoint_parameters.rb#38 +class Aws::STS::EndpointParameters < ::Struct + include ::Aws::Structure + + # @return [EndpointParameters] a new instance of EndpointParameters + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoint_parameters.rb#58 + def initialize(options = T.unsafe(nil)); end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint; end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint=(_); end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region; end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region=(_); end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack; end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack=(_); end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips; end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips=(_); end + + # Whether the global endpoint should be used, rather then the regional endpoint for us-east-1. + # + # @return [Boolean] + def use_global_endpoint; end + + # Whether the global endpoint should be used, rather then the regional endpoint for us-east-1. + # + # @return [Boolean] + def use_global_endpoint=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/endpoint_provider.rb#11 +class Aws::STS::EndpointProvider + # @raise [ArgumentError] + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoint_provider.rb#12 + def resolve_endpoint(parameters); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#13 +module Aws::STS::Endpoints; end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#15 +class Aws::STS::Endpoints::AssumeRole + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#16 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#30 +class Aws::STS::Endpoints::AssumeRoleWithSAML + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#31 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#45 +class Aws::STS::Endpoints::AssumeRoleWithWebIdentity + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#46 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#60 +class Aws::STS::Endpoints::DecodeAuthorizationMessage + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#61 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#75 +class Aws::STS::Endpoints::GetAccessKeyInfo + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#76 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#90 +class Aws::STS::Endpoints::GetCallerIdentity + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#91 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#105 +class Aws::STS::Endpoints::GetFederationToken + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#106 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#120 +class Aws::STS::Endpoints::GetSessionToken + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/endpoints.rb#121 + def build(context); end + end +end + +# When STS returns an error response, the Ruby SDK constructs and raises an error. +# These errors all extend Aws::STS::Errors::ServiceError < {Aws::Errors::ServiceError} +# +# You can rescue all STS errors using ServiceError: +# +# begin +# # do stuff +# rescue Aws::STS::Errors::ServiceError +# # rescues all STS API errors +# end +# +# +# ## Request Context +# ServiceError objects have a {Aws::Errors::ServiceError#context #context} method that returns +# information about the request that generated the error. +# See {Seahorse::Client::RequestContext} for more information. +# +# ## Error Classes +# * {ExpiredTokenException} +# * {IDPCommunicationErrorException} +# * {IDPRejectedClaimException} +# * {InvalidAuthorizationMessageException} +# * {InvalidIdentityTokenException} +# * {MalformedPolicyDocumentException} +# * {PackedPolicyTooLargeException} +# * {RegionDisabledException} +# +# Additionally, error classes are dynamically generated for service errors based on the error code +# if they are not defined above. +# +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#41 +module Aws::STS::Errors + extend ::Aws::Errors::DynamicErrors +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#45 +class Aws::STS::Errors::ExpiredTokenException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::ExpiredTokenException] + # @return [ExpiredTokenException] a new instance of ExpiredTokenException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#50 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#55 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#60 +class Aws::STS::Errors::IDPCommunicationErrorException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::IDPCommunicationErrorException] + # @return [IDPCommunicationErrorException] a new instance of IDPCommunicationErrorException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#65 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#70 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#75 +class Aws::STS::Errors::IDPRejectedClaimException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::IDPRejectedClaimException] + # @return [IDPRejectedClaimException] a new instance of IDPRejectedClaimException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#80 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#85 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#90 +class Aws::STS::Errors::InvalidAuthorizationMessageException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::InvalidAuthorizationMessageException] + # @return [InvalidAuthorizationMessageException] a new instance of InvalidAuthorizationMessageException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#95 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#100 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#105 +class Aws::STS::Errors::InvalidIdentityTokenException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::InvalidIdentityTokenException] + # @return [InvalidIdentityTokenException] a new instance of InvalidIdentityTokenException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#110 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#115 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#120 +class Aws::STS::Errors::MalformedPolicyDocumentException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::MalformedPolicyDocumentException] + # @return [MalformedPolicyDocumentException] a new instance of MalformedPolicyDocumentException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#125 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#130 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#135 +class Aws::STS::Errors::PackedPolicyTooLargeException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::PackedPolicyTooLargeException] + # @return [PackedPolicyTooLargeException] a new instance of PackedPolicyTooLargeException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#140 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#145 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#150 +class Aws::STS::Errors::RegionDisabledException < ::Aws::STS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::STS::Types::RegionDisabledException] + # @return [RegionDisabledException] a new instance of RegionDisabledException + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#155 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#160 + def message; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/errors.rb#0 +class Aws::STS::Errors::ServiceError < ::Aws::Errors::ServiceError; end + +# source://aws-sdk-core//lib/aws-sdk-sts.rb#57 +Aws::STS::GEM_VERSION = T.let(T.unsafe(nil), String) + +# source://aws-sdk-core//lib/aws-sdk-sts/plugins/endpoints.rb#12 +module Aws::STS::Plugins; end + +# source://aws-sdk-core//lib/aws-sdk-sts/plugins/endpoints.rb#13 +class Aws::STS::Plugins::Endpoints < ::Seahorse::Client::Plugin + # source://aws-sdk-core//lib/aws-sdk-sts/plugins/endpoints.rb#81 + def add_handlers(handlers, _config); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-sts/plugins/endpoints.rb#27 +class Aws::STS::Plugins::Endpoints::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/plugins/endpoints.rb#28 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/plugins/endpoints.rb#48 + def apply_endpoint_headers(context, headers); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-sts/plugins/endpoints.rb#59 + def parameters_for_operation(context); end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/plugins/sts_regional_endpoints.rb#7 +class Aws::STS::Plugins::STSRegionalEndpoints < ::Seahorse::Client::Plugin + class << self + # source://aws-sdk-core//lib/aws-sdk-sts/plugins/sts_regional_endpoints.rb#22 + def resolve_sts_regional_endpoints(cfg); end + end +end + +# Allows you to create presigned URLs for STS operations. +# +# @example +# +# signer = Aws::STS::Presigner.new +# url = signer.get_caller_identity_presigned_url( +# headers: {"X-K8s-Aws-Id" => 'my-eks-cluster'} +# ) +# +# source://aws-sdk-core//lib/aws-sdk-sts/presigner.rb#15 +class Aws::STS::Presigner + # @option options + # @param options [Hash] a customizable set of options + # @return [Presigner] a new instance of Presigner + # + # source://aws-sdk-core//lib/aws-sdk-sts/presigner.rb#18 + def initialize(options = T.unsafe(nil)); end + + # Returns a presigned url for get_caller_identity. + # + # This can be easily converted to a token used by the EKS service: + # {https://docs.ruby-lang.org/en/3.2/Base64.html#method-i-encode64} + # "k8s-aws-v1." + Base64.urlsafe_encode64(url).chomp("==") + # + # @example + # + # url = signer.get_caller_identity_presigned_url( + # headers: {"X-K8s-Aws-Id" => 'my-eks-cluster'}, + # ) + # @option options + # @param options [Hash] a customizable set of options + # @return [String] A presigned url string. + # + # source://aws-sdk-core//lib/aws-sdk-sts/presigner.rb#40 + def get_caller_identity_presigned_url(options = T.unsafe(nil)); end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/resource.rb#12 +class Aws::STS::Resource + # @option options + # @param options [{}] + # @return [Resource] a new instance of Resource + # + # source://aws-sdk-core//lib/aws-sdk-sts/resource.rb#16 + def initialize(options = T.unsafe(nil)); end + + # @return [Client] + # + # source://aws-sdk-core//lib/aws-sdk-sts/resource.rb#21 + def client; end +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#11 +module Aws::STS::Types; end + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#317 +class Aws::STS::Types::AssumeRoleRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#318 +Aws::STS::Types::AssumeRoleRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the response to a successful AssumeRole request, including +# temporary Amazon Web Services credentials that can be used to make +# Amazon Web Services requests. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#383 +class Aws::STS::Types::AssumeRoleResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#384 +Aws::STS::Types::AssumeRoleResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithSAMLRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#524 +class Aws::STS::Types::AssumeRoleWithSAMLRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#525 +Aws::STS::Types::AssumeRoleWithSAMLRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the response to a successful AssumeRoleWithSAML request, +# including temporary Amazon Web Services credentials that can be used +# to make Amazon Web Services requests. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithSAMLResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#640 +class Aws::STS::Types::AssumeRoleWithSAMLResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#641 +Aws::STS::Types::AssumeRoleWithSAMLResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithWebIdentityRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#797 +class Aws::STS::Types::AssumeRoleWithWebIdentityRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#798 +Aws::STS::Types::AssumeRoleWithWebIdentityRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the response to a successful AssumeRoleWithWebIdentity +# request, including temporary Amazon Web Services credentials that can +# be used to make Amazon Web Services requests. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithWebIdentityResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#898 +class Aws::STS::Types::AssumeRoleWithWebIdentityResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#899 +Aws::STS::Types::AssumeRoleWithWebIdentityResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The identifiers for the temporary security credentials that the +# operation returns. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumedRoleUser AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#927 +class Aws::STS::Types::AssumedRoleUser < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#928 +Aws::STS::Types::AssumedRoleUser::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Amazon Web Services credentials for API authentication. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/Credentials AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#958 +class Aws::STS::Types::Credentials < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#959 +Aws::STS::Types::Credentials::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/DecodeAuthorizationMessageRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#970 +class Aws::STS::Types::DecodeAuthorizationMessageRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#971 +Aws::STS::Types::DecodeAuthorizationMessageRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A document that contains additional information about the +# authorization status of a request from an encoded message that is +# returned in response to an Amazon Web Services request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/DecodeAuthorizationMessageResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#986 +class Aws::STS::Types::DecodeAuthorizationMessageResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#987 +Aws::STS::Types::DecodeAuthorizationMessageResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The web identity token that was passed is expired or is not valid. Get +# a new identity token from the identity provider and then retry the +# request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/ExpiredTokenException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1001 +class Aws::STS::Types::ExpiredTokenException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1002 +Aws::STS::Types::ExpiredTokenException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Identifiers for the federated user that is associated with the +# credentials. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/FederatedUser AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1028 +class Aws::STS::Types::FederatedUser < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1029 +Aws::STS::Types::FederatedUser::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetAccessKeyInfoRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1044 +class Aws::STS::Types::GetAccessKeyInfoRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1045 +Aws::STS::Types::GetAccessKeyInfoRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetAccessKeyInfoResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1056 +class Aws::STS::Types::GetAccessKeyInfoResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1057 +Aws::STS::Types::GetAccessKeyInfoResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @api private +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetCallerIdentityRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1065 +class Aws::STS::Types::GetCallerIdentityRequest < ::Aws::EmptyStructure; end + +# Contains the response to a successful GetCallerIdentity request, +# including information about the entity making the request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetCallerIdentityResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1096 +class Aws::STS::Types::GetCallerIdentityResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1097 +Aws::STS::Types::GetCallerIdentityResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetFederationTokenRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1269 +class Aws::STS::Types::GetFederationTokenRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1270 +Aws::STS::Types::GetFederationTokenRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the response to a successful GetFederationToken request, +# including temporary Amazon Web Services credentials that can be used +# to make Amazon Web Services requests. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetFederationTokenResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1308 +class Aws::STS::Types::GetFederationTokenResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1309 +Aws::STS::Types::GetFederationTokenResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetSessionTokenRequest AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1356 +class Aws::STS::Types::GetSessionTokenRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1357 +Aws::STS::Types::GetSessionTokenRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the response to a successful GetSessionToken request, +# including temporary Amazon Web Services credentials that can be used +# to make Amazon Web Services requests. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetSessionTokenResponse AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1379 +class Aws::STS::Types::GetSessionTokenResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1380 +Aws::STS::Types::GetSessionTokenResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request could not be fulfilled because the identity provider (IDP) +# that was asked to verify the incoming identity token could not be +# reached. This is often a transient error caused by network conditions. +# Retry the request a limited number of times so that you don't exceed +# the request rate. If the error persists, the identity provider might +# be down or not responding. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/IDPCommunicationErrorException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1397 +class Aws::STS::Types::IDPCommunicationErrorException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1398 +Aws::STS::Types::IDPCommunicationErrorException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The identity provider (IdP) reported that authentication failed. This +# might be because the claim is invalid. +# +# If this error is returned for the `AssumeRoleWithWebIdentity` +# operation, it can also mean that the claim has expired or has been +# explicitly revoked. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/IDPRejectedClaimException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1415 +class Aws::STS::Types::IDPRejectedClaimException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1416 +Aws::STS::Types::IDPRejectedClaimException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The error returned if the message passed to +# `DecodeAuthorizationMessage` was invalid. This can happen if the token +# contains invalid characters, such as linebreaks. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/InvalidAuthorizationMessageException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1430 +class Aws::STS::Types::InvalidAuthorizationMessageException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1431 +Aws::STS::Types::InvalidAuthorizationMessageException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The web identity token that was passed could not be validated by +# Amazon Web Services. Get a new identity token from the identity +# provider and then retry the request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/InvalidIdentityTokenException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1445 +class Aws::STS::Types::InvalidIdentityTokenException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1446 +Aws::STS::Types::InvalidIdentityTokenException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the policy document was malformed. +# The error message describes the specific error. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/MalformedPolicyDocumentException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1459 +class Aws::STS::Types::MalformedPolicyDocumentException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1460 +Aws::STS::Types::MalformedPolicyDocumentException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the total packed size of the session +# policies and session tags combined was too large. An Amazon Web +# Services conversion compresses the session policy document, session +# policy ARNs, and session tags into a packed binary format that has a +# separate limit. The error message indicates by percentage how close +# the policies and tags are to the upper size limit. For more +# information, see [Passing Session Tags in STS][1] in the *IAM User +# Guide*. +# +# You could receive this error even though you meet other defined +# session policy and session tag limits. For more information, see [IAM +# and STS Entity Character Limits][2] in the *IAM User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html +# [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-quotas.html#reference_iam-limits-entity-length +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/PackedPolicyTooLargeException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1488 +class Aws::STS::Types::PackedPolicyTooLargeException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1489 +Aws::STS::Types::PackedPolicyTooLargeException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A reference to the IAM managed policy that is passed as a session +# policy for a role session or a federated user session. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/PolicyDescriptorType AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1510 +class Aws::STS::Types::PolicyDescriptorType < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1511 +Aws::STS::Types::PolicyDescriptorType::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains information about the provided context. This includes the +# signed and encrypted trusted context assertion and the context +# provider ARN from which the trusted context assertion was generated. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/ProvidedContext AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1534 +class Aws::STS::Types::ProvidedContext < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1535 +Aws::STS::Types::ProvidedContext::SENSITIVE = T.let(T.unsafe(nil), Array) + +# STS is not activated in the requested region for the account that is +# being asked to generate credentials. The account administrator must +# use the IAM console to activate STS in that region. For more +# information, see [Activating and Deactivating Amazon Web Services STS +# in an Amazon Web Services Region][1] in the *IAM User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/RegionDisabledException AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1555 +class Aws::STS::Types::RegionDisabledException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1556 +Aws::STS::Types::RegionDisabledException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# You can pass custom key-value pair attributes when you assume a role +# or federate a user. These are called session tags. You can then use +# the session tags to control access to resources. For more information, +# see [Tagging Amazon Web Services STS Sessions][1] in the *IAM User +# Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/Tag AWS API Documentation +# +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1598 +class Aws::STS::Types::Tag < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-core//lib/aws-sdk-sts/types.rb#1599 +Aws::STS::Types::Tag::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#5 +class Aws::SharedConfig + # Constructs a new SharedConfig provider object. This will load the shared + # credentials file, and optionally the shared configuration file, as ini + # files which support profiles. + # + # By default, the shared credential file (the default path for which is + # `~/.aws/credentials`) and the shared config file (the default path for + # which is `~/.aws/config`) are loaded. However, if you set the + # `ENV['AWS_SDK_CONFIG_OPT_OUT']` environment variable, only the shared + # credential file will be loaded. You can specify the shared credential + # file path with the `ENV['AWS_SHARED_CREDENTIALS_FILE']` environment + # variable or with the `:credentials_path` option. Similarly, you can + # specify the shared config file path with the `ENV['AWS_CONFIG_FILE']` + # environment variable or with the `:config_path` option. + # + # The default profile name is 'default'. You can specify the profile name + # with the `ENV['AWS_PROFILE']` environment variable or with the + # `:profile_name` option. + # + # @api private + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [SharedConfig] a new instance of SharedConfig + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#52 + def initialize(options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def adaptive_retry_wait_to_fill(opts = T.unsafe(nil)); end + + # Attempts to assume a role from shared config or shared credentials file. + # Will always attempt first to assume a role from the shared credentials + # file, if present. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#120 + def assume_role_credentials_from_config(opts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#130 + def assume_role_web_identity_credentials_from_config(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def ca_bundle(opts = T.unsafe(nil)); end + + # @api private + # @return [Boolean] returns `true` if use of the shared config file is + # enabled. + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#96 + def config_enabled?; end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#16 + def config_path; end + + # Source a custom configured endpoint from the shared configuration file + # + # @api private + # @option opts + # @option opts + # @param opts [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#175 + def configured_endpoint(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def correct_clock_skew(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def credential_process(opts = T.unsafe(nil)); end + + # Sources static credentials from shared credential/config files. + # + # @api private + # @option options + # @param opts [Hash] + # @param options [Hash] a customizable set of options + # @return [Aws::Credentials] credentials sourced from configuration values, + # or `nil` if no valid credentials were found. + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#107 + def credentials(opts = T.unsafe(nil)); end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#13 + def credentials_path; end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def csm_client_id(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def csm_enabled(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def csm_host(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def csm_port(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def defaults_mode(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def disable_request_compression(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def ec2_metadata_service_endpoint(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def ec2_metadata_service_endpoint_mode(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def ec2_metadata_v1_disabled(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def endpoint_discovery_enabled(opts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#69 + def fresh(options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def ignore_configured_endpoint_urls(opts = T.unsafe(nil)); end + + # @api private + # @note This method does not indicate if the file found at {#path} + # will be parsable, only if it can be read. + # @return [Boolean] Returns `true` if a credential file + # exists and has appropriate read permissions at {#path}. + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#90 + def loadable?(path); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def max_attempts(opts = T.unsafe(nil)); end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#19 + def profile_name; end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def region(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def request_min_compression_size_bytes(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def retry_mode(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def s3_disable_express_session_auth(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def s3_disable_multiregion_access_points(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def s3_us_east_1_regional_endpoint(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def s3_use_arn_region(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def sdk_ua_app_id(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def sigv4a_signing_region_set(opts = T.unsafe(nil)); end + + # Attempts to load from shared config or shared credentials file. + # Will always attempt first to load from the shared credentials + # file, if present. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#149 + def sso_credentials_from_config(opts = T.unsafe(nil)); end + + # Attempts to load from shared config or shared credentials file. + # Will always attempt first to load from the shared credentials + # file, if present. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#161 + def sso_token_from_config(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def sts_regional_endpoints(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def use_dualstack_endpoint(opts = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#195 + def use_fips_endpoint(opts = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#243 + def assume_role_from_profile(cfg, profile, opts, chain_config); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#336 + def assume_role_process_credentials_from_config(profile); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#351 + def credentials_from_config(profile, _opts); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#413 + def credentials_from_profile(prof_config); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#345 + def credentials_from_shared(profile, _opts); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#321 + def credentials_from_source(credential_source, config); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#440 + def default_shared_config_path(file); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#436 + def determine_config_path; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#432 + def determine_credentials_path; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#456 + def determine_profile(options); end + + # Get a config value from from shared credential/config files. + # Only loads a value when config_enabled is true + # Return a value from credentials preferentially over config + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#235 + def get_config_value(key, opts); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#428 + def load_config_file; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#422 + def load_credentials_file; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#296 + def resolve_source_profile(profile, opts = T.unsafe(nil)); end + + # If any of the sso_ profile values are present, attempt to construct + # SSOCredentials + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#359 + def sso_credentials_from_profile(cfg, profile); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#463 + def sso_session(cfg, profile, sso_session_name); end + + # If the required sso_ profile values are present, attempt to construct + # SSOTokenProvider + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#398 + def sso_token_from_profile(cfg, profile); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#447 + def validate_profile_exists(profile); end + + class << self + # Add an accessor method (similar to attr_reader) to return a configuration value + # Uses the get_config_value below to control where + # values are loaded from + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#193 + def config_reader(*attrs); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#6 +Aws::SharedConfig::SSO_CREDENTIAL_PROFILE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#7 +Aws::SharedConfig::SSO_PROFILE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#9 +Aws::SharedConfig::SSO_SESSION_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/shared_config.rb#8 +Aws::SharedConfig::SSO_TOKEN_PROFILE_KEYS = T.let(T.unsafe(nil), Array) + +# source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#6 +class Aws::SharedCredentials + include ::Aws::CredentialProvider + + # Constructs a new SharedCredentials object. This will load static + # (access_key_id, secret_access_key and session_token) AWS access + # credentials from an ini file, which supports profiles. The default + # profile name is 'default'. You can specify the profile name with the + # `ENV['AWS_PROFILE']` or with the `:profile_name` option. + # + # To use credentials from the default credential resolution chain + # create a client without the credential option specified. + # You may access the resolved credentials through + # `client.config.credentials`. + # + # @option [String] + # @option [String] + # @param [String] [Hash] a customizable set of options + # @return [SharedCredentials] a new instance of SharedCredentials + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#34 + def initialize(options = T.unsafe(nil)); end + + # @return [Credentials] + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#59 + def credentials; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#62 + def inspect; end + + # @deprecated This method is no longer used. + # @note This method does not indicate if the file found at {#path} + # will be parsable, only if it can be read. + # @return [Boolean] Returns `true` if a credential file + # exists and has appropriate read permissions at {#path}. + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#76 + def loadable?; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#53 + def path; end + + # @return [String] + # + # source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#56 + def profile_name; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/shared_credentials.rb#11 +Aws::SharedCredentials::KEY_MAP = T.let(T.unsafe(nil), Hash) + +# source://aws-sdk-core//lib/aws-sdk-core/static_token_provider.rb#4 +class Aws::StaticTokenProvider + include ::Aws::TokenProvider + + # @param token [String] + # @param expiration [Time] + # @return [StaticTokenProvider] a new instance of StaticTokenProvider + # + # source://aws-sdk-core//lib/aws-sdk-core/static_token_provider.rb#10 + def initialize(token, expiration = T.unsafe(nil)); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/structure.rb#5 +module Aws::Structure + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#7 + def initialize(values = T.unsafe(nil)); end + + # @api private + # @return [Boolean] Returns `true` if all of the member values are `nil`. + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#20 + def empty?; end + + # @api private + # @return [Boolean] Returns `true` if this structure has a value + # set for the given member. + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#15 + def key?(member_name); end + + # Deeply converts the Structure into a hash. Structure members that + # are `nil` are omitted from the resultant hash. + # + # You can call #orig_to_h to get vanilla #to_h behavior as defined + # in stdlib Struct. + # + # @api private + # @return [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#31 + def to_h(obj = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deeply converts the Structure into a hash. Structure members that + # are `nil` are omitted from the resultant hash. + # + # You can call #orig_to_h to get vanilla #to_h behavior as defined + # in stdlib Struct. + # + # @api private + # @return [Hash] + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#31 + def to_hash(obj = T.unsafe(nil), options = T.unsafe(nil)); end + + # Wraps the default #to_s logic with filtering of sensitive parameters. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#52 + def to_s(obj = T.unsafe(nil)); end + + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#59 + def new(*args); end + end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/structure.rb#76 +module Aws::Structure::Union + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#77 + def member; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/structure.rb#81 + def value; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/empty_stub.rb#4 +module Aws::Stubbing; end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/data_applicator.rb#5 +class Aws::Stubbing::DataApplicator + include ::Seahorse::Model::Shapes + + # @param rules [Seahorse::Models::Shapes::ShapeRef] + # @return [DataApplicator] a new instance of DataApplicator + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/data_applicator.rb#10 + def initialize(rules); end + + # @param data [Hash] + # @param stub [Structure] + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/data_applicator.rb#16 + def apply_data(data, stub); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/data_applicator.rb#22 + def apply_data_to_struct(ref, data, struct); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/data_applicator.rb#29 + def member_value(ref, value); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/empty_stub.rb#5 +class Aws::Stubbing::EmptyStub + include ::Seahorse::Model::Shapes + + # @param rules [Seahorse::Models::Shapes::ShapeRef] + # @return [EmptyStub] a new instance of EmptyStub + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/empty_stub.rb#10 + def initialize(rules); end + + # @return [Structure] + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/empty_stub.rb#15 + def stub; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/empty_stub.rb#25 + def stub_ref(ref, visited = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/empty_stub.rb#49 + def stub_scalar(ref); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/empty_stub.rb#39 + def stub_structure(ref, visited); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/json.rb#5 +module Aws::Stubbing::Protocols; end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/api_gateway.rb#6 +class Aws::Stubbing::Protocols::ApiGateway < ::Aws::Stubbing::Protocols::RestJson; end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/ec2.rb#6 +class Aws::Stubbing::Protocols::EC2 + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/ec2.rb#8 + def stub_data(api, operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/ec2.rb#18 + def stub_error(error_code); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/ec2.rb#34 + def build_body(api, operation, data); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/json.rb#6 +class Aws::Stubbing::Protocols::Json + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/json.rb#8 + def stub_data(api, operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/json.rb#17 + def stub_error(error_code); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/json.rb#35 + def build_body(operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/json.rb#31 + def content_type(api); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/query.rb#6 +class Aws::Stubbing::Protocols::Query + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/query.rb#8 + def stub_data(api, operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/query.rb#15 + def stub_error(error_code); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/query.rb#24 + def build_body(api, operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/query.rb#39 + def xmlns(api); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#8 +class Aws::Stubbing::Protocols::Rest + include ::Seahorse::Model::Shapes + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#12 + def stub_data(api, operation, data); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#41 + def apply_body(api, operation, resp, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#37 + def apply_headers(operation, resp, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#29 + def apply_status_code(operation, resp, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#45 + def build_body(api, operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#105 + def encode_error(opts, event_data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#185 + def encode_event(opts, rules, event_data, builder); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#85 + def encode_eventstream_response(rules, data, builder); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#135 + def encode_modeled_event(opts, rules, event_type, event_data, builder); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#121 + def encode_unknown_event(opts, event_type, event_data); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#81 + def eventstream?(rules); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#77 + def head_operation(operation); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#22 + def new_http_response; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest.rb#65 + def streaming?(ref); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest_json.rb#6 +class Aws::Stubbing::Protocols::RestJson < ::Aws::Stubbing::Protocols::Rest + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest_json.rb#8 + def body_for(_a, _b, rules, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest_json.rb#16 + def stub_error(error_code); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest_xml.rb#6 +class Aws::Stubbing::Protocols::RestXml < ::Aws::Stubbing::Protocols::Rest + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest_xml.rb#8 + def body_for(api, operation, rules, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest_xml.rb#20 + def stub_error(error_code); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rest_xml.rb#27 + def xmlns(api); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rpc_v2.rb#6 +class Aws::Stubbing::Protocols::RpcV2 + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rpc_v2.rb#8 + def stub_data(api, operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rpc_v2.rb#17 + def stub_error(error_code); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rpc_v2.rb#35 + def build_body(operation, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/protocols/rpc_v2.rb#31 + def content_type(api); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/stub_data.rb#6 +class Aws::Stubbing::StubData + # @api private + # @return [StubData] a new instance of StubData + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/stub_data.rb#8 + def initialize(operation); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/stub_data.rb#13 + def stub(data = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/stub_data.rb#54 + def apply_data(data, stub); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/stub_data.rb#23 + def remove_checksums(stub); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/stub_data.rb#33 + def remove_paging_tokens(stub); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/stubbing/xml_error.rb#5 +class Aws::Stubbing::XmlError + # @api private + # @return [XmlError] a new instance of XmlError + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/xml_error.rb#7 + def initialize(error_code); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/stubbing/xml_error.rb#11 + def to_xml; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/token.rb#4 +class Aws::Token + # @param token [String] + # @param expiration [Time] + # @return [Token] a new instance of Token + # + # source://aws-sdk-core//lib/aws-sdk-core/token.rb#8 + def initialize(token, expiration = T.unsafe(nil)); end + + # @return [Time, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/token.rb#17 + def expiration; end + + # Removing the token from the default inspect string. + # + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/token.rb#26 + def inspect; end + + # @return [Boolean] Returns `true` if token is set + # + # source://aws-sdk-core//lib/aws-sdk-core/token.rb#20 + def set?; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/token.rb#14 + def token; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/token_provider.rb#4 +module Aws::TokenProvider + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider.rb#10 + def set?; end + + # @return [Token] + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider.rb#7 + def token; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/token_provider_chain.rb#5 +class Aws::TokenProviderChain + # @api private + # @return [TokenProviderChain] a new instance of TokenProviderChain + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider_chain.rb#6 + def initialize(config = T.unsafe(nil)); end + + # @api private + # @return [TokenProvider, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider_chain.rb#11 + def resolve; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider_chain.rb#46 + def determine_profile_name(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider_chain.rb#21 + def providers; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider_chain.rb#37 + def sso_token(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/token_provider_chain.rb#28 + def static_profile_sso_token(options); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/type_builder.rb#5 +class Aws::TypeBuilder + # @api private + # @return [TypeBuilder] a new instance of TypeBuilder + # + # source://aws-sdk-core//lib/aws-sdk-core/type_builder.rb#7 + def initialize(svc_module); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/type_builder.rb#11 + def build_type(shape, shapes); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/util.rb#7 +module Aws::Util + class << self + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#18 + def copy_hash(hash); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#26 + def deep_copy(obj); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#10 + def deep_merge(left, right); end + + # @api private + # @param str [String] + # @return [Number] The input as a number + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#83 + def deserialize_number(str); end + + # @api private + # @param value [String] + # @return [Time] + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#95 + def deserialize_time(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#49 + def monotonic_milliseconds; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#57 + def monotonic_seconds; end + + # @api private + # @param input [Number] + # @return [Number, String] The serialized number + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#72 + def serialize_number(input); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/util.rb#61 + def str_2_bool(str); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#4 +module Aws::Waiters; end + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#5 +module Aws::Waiters::Errors; end + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#11 +class Aws::Waiters::Errors::FailureStateError < ::Aws::Waiters::Errors::WaiterFailed + # @return [FailureStateError] a new instance of FailureStateError + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#15 + def initialize(response); end + + # @return [Seahorse::Client::Response] The response that matched + # the failure state. + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#22 + def response; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#13 +Aws::Waiters::Errors::FailureStateError::MSG = T.let(T.unsafe(nil), String) + +# Raised when attempting to get a waiter by name and the waiter has not +# been defined. +# +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#56 +class Aws::Waiters::Errors::NoSuchWaiterError < ::ArgumentError + # @return [NoSuchWaiterError] a new instance of NoSuchWaiterError + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#60 + def initialize(waiter_name, waiter_names); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#58 +Aws::Waiters::Errors::NoSuchWaiterError::MSG = T.let(T.unsafe(nil), String) + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#26 +class Aws::Waiters::Errors::TooManyAttemptsError < ::Aws::Waiters::Errors::WaiterFailed + # @return [TooManyAttemptsError] a new instance of TooManyAttemptsError + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#30 + def initialize(attempts); end + + # @return [Integer] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#36 + def attempts; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#28 +Aws::Waiters::Errors::TooManyAttemptsError::MSG = T.let(T.unsafe(nil), String) + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#40 +class Aws::Waiters::Errors::UnexpectedError < ::Aws::Waiters::Errors::WaiterFailed + # @return [UnexpectedError] a new instance of UnexpectedError + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#44 + def initialize(error); end + + # @return [Exception] The unexpected error. + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#50 + def error; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#42 +Aws::Waiters::Errors::UnexpectedError::MSG = T.let(T.unsafe(nil), String) + +# Raised when a waiter detects a condition where the waiter can never +# succeed. +# +# source://aws-sdk-core//lib/aws-sdk-core/waiters/errors.rb#9 +class Aws::Waiters::Errors::WaiterFailed < ::StandardError; end + +# Polls a single API operation inspecting the response data and/or error +# for states matching one of its acceptors. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#9 +class Aws::Waiters::Poller + # @api private + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Poller] a new instance of Poller + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#17 + def initialize(options = T.unsafe(nil)); end + + # Makes an API call, returning the resultant state and the response. + # + # * `:success` - A success state has been matched. + # * `:failure` - A terminate failure state has been matched. + # * `:retry` - The waiter may be retried. + # * `:error` - The waiter encountered an un-expected error. + # + # @api private + # @example A trivial (bad) example of a waiter that polls indefinetly. + # + # loop do + # + # state, resp = poller.call(client:client, params:{}) + # + # case state + # when :success then return true + # when :failure then return false + # when :retry then next + # when :error then raise 'oops' + # end + # + # end + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Array] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#50 + def call(options = T.unsafe(nil)); end + + # @api private + # @return [Symbol] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#23 + def operation_name; end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#70 + def acceptor_matches?(acceptor, response); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#98 + def matches_error?(acceptor, response); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#74 + def matches_path?(acceptor, response); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#82 + def matches_pathAll?(acceptor, response); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#88 + def matches_pathAny?(acceptor, response); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#94 + def matches_status?(acceptor, response); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#112 + def non_empty_array(acceptor, response, &block); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#108 + def path(acceptor); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#62 + def send_request(options); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/waiters/poller.rb#12 +Aws::Waiters::Poller::RAISE_HANDLER = Seahorse::Client::Plugins::RaiseResponseErrors::Handler + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#6 +class Aws::Waiters::Waiter + # @api private + # @return [Waiter] a new instance of Waiter + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#12 + def initialize(options = T.unsafe(nil)); end + + # Register a callback that is invoked before every polling attempt. + # Yields the number of attempts made so far. + # + # waiter.before_attempt do |attempts| + # puts "#{attempts} made, about to make attempt #{attempts + 1}" + # end + # + # Throwing `:success` or `:failure` from the given block will stop + # the waiter and return or raise. You can pass a custom message to the + # throw: + # + # # raises Aws::Waiters::Errors::WaiterFailed + # waiter.before_attempt do |attempts| + # throw :failure, 'custom-error-message' + # end + # + # # cause the waiter to stop polling and return + # waiter.before_attempt do |attempts| + # throw :success + # end + # + # @api private + # @yieldparam attempts [Integer] The number of attempts made. + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#54 + def before_attempt(&block); end + + # Register a callback that is invoked after an attempt but before + # sleeping. Yields the number of attempts made and the previous response. + # + # waiter.before_wait do |attempts, response| + # puts "#{attempts} made" + # puts response.error.inspect + # puts response.data.inspect + # end + # + # Throwing `:success` or `:failure` from the given block will stop + # the waiter and return or raise. You can pass a custom message to the + # throw: + # + # # raises Aws::Waiters::Errors::WaiterFailed + # waiter.before_attempt do |attempts| + # throw :failure, 'custom-error-message' + # end + # + # # cause the waiter to stop polling and return + # waiter.before_attempt do |attempts| + # throw :success + # end + # + # @api private + # @yieldparam attempts [Integer] The number of attempts already made. + # @yieldparam response [Seahorse::Client::Response] The response from + # the previous polling attempts. + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#85 + def before_wait(&block); end + + # @api private + # @return [Float] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#27 + def delay; end + + # @api private + # @return [Float] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#27 + def delay=(_arg0); end + + # @api private + # @return [Float] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#27 + def interval; end + + # @api private + # @return [Float] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#27 + def interval=(_arg0); end + + # @api private + # @return [Integer] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#24 + def max_attempts; end + + # @api private + # @return [Integer] + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#24 + def max_attempts=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#21 + def poller; end + + # @api private + # @option options + # @option options + # @param options [Hash] a customizable set of options + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#91 + def wait(options); end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#102 + def poll(options); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#124 + def trigger_before_attempt(attempts); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#128 + def trigger_before_wait(attempts, response); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/waiters/waiter.rb#9 +Aws::Waiters::Waiter::RAISE_HANDLER = Seahorse::Client::Plugins::RaiseResponseErrors::Handler + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#6 +module Aws::Xml; end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#7 +class Aws::Xml::Builder + include ::Seahorse::Model::Shapes + + # @return [Builder] a new instance of Builder + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#11 + def initialize(rules, options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#21 + def serialize(params); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#21 + def to_xml(params); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#102 + def blob(value); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#52 + def list(name, ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#67 + def map(name, ref, hash); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#90 + def member(name, ref, value); end + + # The `args` list may contain: + # + # * [] - empty, no value or attributes + # * [value] - inline element, no attributes + # * [value, attributes_hash] - inline element with attributes + # * [attributes_hash] - self closing element with attributes + # + # Pass a block if you want to nest XML nodes inside. When doing this, + # you may *not* pass a value to the `args` list. + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#127 + def node(name, ref, *args, &block); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#134 + def shape_attrs(ref); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#29 + def structure(name, ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#43 + def structure_attrs(ref, values); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#107 + def timestamp(ref, value); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/builder.rb#151 + def xml_attribute?(ref); end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/xml/default_list.rb#6 +class Aws::Xml::DefaultList < ::Array + # @api private + def nil?; end +end + +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/xml/default_map.rb#6 +class Aws::Xml::DefaultMap < ::Hash + # @api private + def nil?; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#5 +class Aws::Xml::DocBuilder + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [DocBuilder] a new instance of DocBuilder + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#10 + def initialize(options = T.unsafe(nil)); end + + # @overload node + # @overload node + # @overload node + # @return [void] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#36 + def node(name, *args, &block); end + + # Returns the value of attribute target. + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#21 + def target; end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#78 + def attributes(attr); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#65 + def close_el(name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#53 + def empty_element(name, attrs); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#69 + def escape(string, text_or_attr); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#88 + def increase_pad(&block); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#57 + def inline_element(name, value, attrs); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/doc_builder.rb#61 + def open_el(name, attrs); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#7 +class Aws::Xml::ErrorHandler < ::Aws::ErrorHandler + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#9 + def call(context); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#59 + def apply_error_headers(rule, context, data); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#64 + def error_code(body, context); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#28 + def error_data(context, body, code); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#80 + def error_message(body); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#18 + def extract_error(body, context); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#48 + def parse_error_data(rule, body); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#72 + def remove_prefix(error_code, context); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#88 + def request_id(body); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/error_handler.rb#94 + def unescape(str); end +end + +# A SAX-style XML parser that uses a shape context to handle types. +# +# @api private +# +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#7 +class Aws::Xml::Parser + include ::Seahorse::Model::Shapes + + # @api private + # @param rules [Seahorse::Model::ShapeRef] + # @return [Parser] a new instance of Parser + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#9 + def initialize(rules, options = T.unsafe(nil)); end + + # Parses the XML document, returning a parsed structure. + # + # If you pass a block, this will yield for XML + # elements that are not modeled in the rules given + # to the constructor. + # + # parser.parse(xml) do |path, value| + # puts "uhandled: #{path.join('/')} - #{value}" + # end + # + # The purpose of the unhandled callback block is to + # allow callers to access values such as the EC2 + # request ID that are part of the XML body but not + # part of the operation result. + # + # @api private + # @param xml [String] An XML document string to parse. + # @param target [Structure] (nil) + # @return [Structure] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#32 + def parse(xml, target = T.unsafe(nil), &unhandled_callback); end + + class << self + # @api private + # @return [Class] Returns the default parsing engine. + # One of: + # + # * {OxEngine} + # * {OgaEngine} + # * {LibxmlEngine} + # * {NokogiriEngine} + # * {RexmlEngine} + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#61 + def engine; end + + # @api private + # @param engine [Symbol, Class] Must be one of the following values: + # + # * :ox + # * :oga + # * :libxml + # * :nokogiri + # * :rexml + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#49 + def engine=(engine); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#66 + def set_default_engine; end + + private + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#79 + def load_engine(name); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser.rb#85 + def try_load_engine(name); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#263 +class Aws::Xml::Parser::BlobFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#264 + def result; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#269 +class Aws::Xml::Parser::BooleanFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#270 + def result; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#301 +Aws::Xml::Parser::FRAME_CLASSES = T.let(T.unsafe(nil), Hash) + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#172 +class Aws::Xml::Parser::FlatListFrame < ::Aws::Xml::Parser::Frame + # @return [FlatListFrame] a new instance of FlatListFrame + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#174 + def initialize(xml_name, *args); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#187 + def child_frame(xml_name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#191 + def consume_child_frame(child); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#179 + def result; end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#183 + def set_text(value); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#275 +class Aws::Xml::Parser::FloatFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#276 + def result; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#9 +class Aws::Xml::Parser::Frame + include ::Seahorse::Model::Shapes + + # @return [Frame] a new instance of Frame + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#40 + def initialize(path, parent, ref, result); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#58 + def child_frame(xml_name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#62 + def consume_child_frame(child); end + + # Returns the value of attribute parent. + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#48 + def parent; end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#65 + def path; end + + # Returns the value of attribute ref. + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#50 + def ref; end + + # Returns the value of attribute result. + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#52 + def result; end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#54 + def set_text(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#74 + def yield_unhandled_value(path, value); end + + class << self + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#15 + def new(path, parent, ref, result = T.unsafe(nil)); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#27 + def frame_class(ref); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#281 +class Aws::Xml::Parser::IntegerFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#282 + def result; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#150 +class Aws::Xml::Parser::ListFrame < ::Aws::Xml::Parser::Frame + # @return [ListFrame] a new instance of ListFrame + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#152 + def initialize(*args); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#158 + def child_frame(xml_name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#166 + def consume_child_frame(child); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#218 +class Aws::Xml::Parser::MapEntryFrame < ::Aws::Xml::Parser::Frame + # @return [MapEntryFrame] a new instance of MapEntryFrame + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#220 + def initialize(xml_name, *args); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#234 + def child_frame(xml_name); end + + # @return [StringFrame] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#229 + def key; end + + # @return [Frame] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#232 + def value; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#197 +class Aws::Xml::Parser::MapFrame < ::Aws::Xml::Parser::Frame + # @return [MapFrame] a new instance of MapFrame + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#199 + def initialize(*args); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#204 + def child_frame(xml_name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#212 + def consume_child_frame(child); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#8 +class Aws::Xml::Parser::NokogiriEngine + # @return [NokogiriEngine] a new instance of NokogiriEngine + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#10 + def initialize(stack); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#32 + def characters(chars); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#21 + def comment(*args); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#20 + def end_document; end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#36 + def end_element_namespace(*ignored); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#40 + def error(msg); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#14 + def parse(xml); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#19 + def start_document; end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#23 + def start_element_namespace(element_name, attributes = T.unsafe(nil), *ignored); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/nokogiri_engine.rb#18 + def xmldecl(*args); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#246 +class Aws::Xml::Parser::NullFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#251 + def set_text(value); end + + class << self + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#247 + def new(xml_name, parent); end + end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/parsing_error.rb#6 +class Aws::Xml::Parser::ParsingError < ::RuntimeError + # @return [ParsingError] a new instance of ParsingError + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/parsing_error.rb#8 + def initialize(msg, line, column); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/parsing_error.rb#16 + def column; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/parsing_error.rb#13 + def line; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#6 +class Aws::Xml::Parser::Stack + # @return [Stack] a new instance of Stack + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#8 + def initialize(ref, result = T.unsafe(nil), &unhandled_callback); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#23 + def attr(name, value); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#52 + def child_frame(name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#56 + def consume_child_frame(frame); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#39 + def end_element(*args); end + + # @raise [ParsingError] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#48 + def error(msg, line = T.unsafe(nil), column = T.unsafe(nil)); end + + # Returns the value of attribute frame. + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#15 + def frame; end + + # Returns the value of attribute result. + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#17 + def result; end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#19 + def start_element(name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#35 + def text(value); end + + # @api private + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/stack.rb#61 + def yield_unhandled_value(path, value); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#287 +class Aws::Xml::Parser::StringFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#288 + def result; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#80 +class Aws::Xml::Parser::StructureFrame < ::Aws::Xml::Parser::Frame + # @return [StructureFrame] a new instance of StructureFrame + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#82 + def initialize(xml_name, parent, ref, result = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#95 + def child_frame(xml_name); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#105 + def consume_child_frame(child); end + + private + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#133 + def apply_default_value(name, ref); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#144 + def flattened_list?(ref); end + + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#140 + def xml_name(ref); end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#293 +class Aws::Xml::Parser::TimestampFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#294 + def result; end +end + +# source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#257 +class Aws::Xml::Parser::UnknownMemberFrame < ::Aws::Xml::Parser::Frame + # source://aws-sdk-core//lib/aws-sdk-core/xml/parser/frame.rb#258 + def result; end +end + +class Net::HTTPGenericRequest + include ::Seahorse::Client::NetHttp::Patches::PatchDefaultContentType +end + +# source://aws-sdk-core//lib/seahorse/util.rb#5 +module Seahorse; end + +# source://aws-sdk-core//lib/seahorse/client/block_io.rb#4 +module Seahorse::Client; end + +# source://aws-sdk-core//lib/seahorse/client/async_base.rb#5 +class Seahorse::Client::AsyncBase < ::Seahorse::Client::Base + # @return [AsyncBase] a new instance of AsyncBase + # + # source://aws-sdk-core//lib/seahorse/client/async_base.rb#14 + def initialize(plugins, options); end + + # Closes the underlying HTTP2 Connection for the client + # + # @return [Symbol] Returns the status of the connection (:closed) + # + # source://aws-sdk-core//lib/seahorse/client/async_base.rb#31 + def close_connection; end + + # @return [H2::Connection] + # + # source://aws-sdk-core//lib/seahorse/client/async_base.rb#21 + def connection; end + + # source://aws-sdk-core//lib/seahorse/client/async_base.rb#45 + def connection_errors; end + + # Creates a new HTTP2 Connection for the client + # + # @return [Seahorse::Client::H2::Connection] + # + # source://aws-sdk-core//lib/seahorse/client/async_base.rb#37 + def new_connection; end + + # @return [Array] Returns a list of valid async request + # operation names. + # + # source://aws-sdk-core//lib/seahorse/client/async_base.rb#25 + def operation_names; end +end + +# source://aws-sdk-core//lib/seahorse/client/async_response.rb#5 +class Seahorse::Client::AsyncResponse + # @return [AsyncResponse] a new instance of AsyncResponse + # + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#7 + def initialize(options = T.unsafe(nil)); end + + # @return [RequestContext] + # + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#16 + def context; end + + # @return [StandardError, nil] + # + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#21 + def error; end + + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#69 + def join!; end + + # @overload on + # @overload on + # @return [self] + # + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#35 + def on(range, &block); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#41 + def on_complete(&block); end + + # @return [Boolean] Returns `true` if the response is complete with + # no error. + # + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#48 + def successful?; end + + # source://aws-sdk-core//lib/seahorse/client/async_response.rb#52 + def wait; end +end + +# source://aws-sdk-core//lib/seahorse/client/base.rb#5 +class Seahorse::Client::Base + include ::Seahorse::Client::HandlerBuilder + + # @api private + # @return [Base] a new instance of Base + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#20 + def initialize(plugins, options); end + + # Builds and returns a {Request} for the named operation. The request + # will not have been sent. + # + # @param operation_name [Symbol, String] + # @return [Request] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#36 + def build_request(operation_name, params = T.unsafe(nil)); end + + # @return [Configuration] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#27 + def config; end + + # @return [HandlerList] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#30 + def handlers; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#43 + def inspect; end + + # @return [Array] Returns a list of valid request operation + # names. These are valid arguments to {#build_request} and are also + # valid methods. + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#50 + def operation_names; end + + private + + # Gives each plugin the opportunity to modify this client. + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#79 + def after_initialize(plugins); end + + # Constructs a {Configuration} object and gives each plugin the + # opportunity to register options with default values. + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#58 + def build_config(plugins, options); end + + # Gives each plugin the opportunity to register handlers for this client. + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#69 + def build_handler_list(plugins); end + + # @return [RequestContext] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#86 + def context_for(operation_name, params); end + + class << self + # Registers a plugin with this client. + # + # @example Register a plugin + # + # ClientClass.add_plugin(PluginClass) + # @example Register a plugin by name + # + # ClientClass.add_plugin('gem-name.PluginClass') + # @example Register a plugin with an object + # + # plugin = MyPluginClass.new(options) + # ClientClass.add_plugin(plugin) + # @param plugin [Class, Symbol, String, Object] + # @return [void] + # @see .clear_plugins + # @see .set_plugins + # @see .remove_plugin + # @see .plugins + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#127 + def add_plugin(plugin); end + + # @return [Model::Api] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#171 + def api; end + + # @return [void] + # @see .set_plugins + # @see .add_plugin + # @see .remove_plugin + # @see .plugins + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#145 + def clear_plugins; end + + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Class] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#187 + def define(options = T.unsafe(nil)); end + + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Class] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#187 + def extend(options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/seahorse/client/base.rb#97 + def new(options = T.unsafe(nil)); end + + # Returns the list of registered plugins for this Client. Plugins are + # inherited from the client super class when the client is defined. + # + # @return [Array] + # @see .clear_plugins + # @see .set_plugins + # @see .add_plugin + # @see .remove_plugin + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#166 + def plugins; end + + # @return [void] + # @see .clear_plugins + # @see .set_plugins + # @see .add_plugin + # @see .plugins + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#136 + def remove_plugin(plugin); end + + # @param api [Model::Api] + # @return [Model::Api] + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#177 + def set_api(api); end + + # @param plugins [Array] + # @return [void] + # @see .clear_plugins + # @see .add_plugin + # @see .remove_plugin + # @see .plugins + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#155 + def set_plugins(plugins); end + + private + + # source://aws-sdk-core//lib/seahorse/client/base.rb#215 + def before_initialize(plugins, options); end + + # source://aws-sdk-core//lib/seahorse/client/base.rb#211 + def build_plugins(plugins); end + + # source://aws-sdk-core//lib/seahorse/client/base.rb#199 + def define_operation_methods; end + + # @private + # + # source://aws-sdk-core//lib/seahorse/client/base.rb#231 + def inherited(subclass); end + end +end + +# source://aws-sdk-core//lib/seahorse/client/block_io.rb#5 +class Seahorse::Client::BlockIO + # @return [BlockIO] a new instance of BlockIO + # + # source://aws-sdk-core//lib/seahorse/client/block_io.rb#7 + def initialize(headers = T.unsafe(nil), &block); end + + # @param bytes [Integer] (nil) + # @param output_buffer [String] (nil) + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/client/block_io.rb#24 + def read(bytes = T.unsafe(nil), output_buffer = T.unsafe(nil)); end + + # @return [Integer] + # + # source://aws-sdk-core//lib/seahorse/client/block_io.rb#30 + def size; end + + # @param chunk [String] + # @return [Integer] + # + # source://aws-sdk-core//lib/seahorse/client/block_io.rb#15 + def write(chunk); end +end + +# Configuration is used to define possible configuration options and +# then build read-only structures with user-supplied data. +# +# ## Adding Configuration Options +# +# Add configuration options with optional default values. These are used +# when building configuration objects. +# +# configuration = Configuration.new +# +# configuration.add_option(:max_retries, 3) +# configuration.add_option(:use_ssl, true) +# +# cfg = configuration.build! +# #=> # +# +# ## Building Configuration Objects +# +# Calling {#build!} on a {Configuration} object causes it to return +# a read-only (frozen) struct. Options passed to {#build!} are merged +# on top of any default options. +# +# configuration = Configuration.new +# configuration.add_option(:color, 'red') +# +# # default +# cfg1 = configuration.build! +# cfg1.color #=> 'red' +# +# # supplied color +# cfg2 = configuration.build!(color: 'blue') +# cfg2.color #=> 'blue' +# +# ## Accepted Options +# +# If you try to {#build!} a {Configuration} object with an unknown +# option, an `ArgumentError` is raised. +# +# configuration = Configuration.new +# configuration.add_option(:color) +# configuration.add_option(:size) +# configuration.add_option(:category) +# +# configuration.build!(price: 100) +# #=> raises an ArgumentError, :price was not added as an option +# +# source://aws-sdk-core//lib/seahorse/client/configuration.rb#54 +class Seahorse::Client::Configuration + # @api private + # @return [Configuration] a new instance of Configuration + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#77 + def initialize; end + + # Adds a getter method that returns the named option or a default + # value. Default values can be passed as a static positional argument + # or via a block. + # + # # defaults to nil + # configuration.add_option(:name) + # + # # with a string default + # configuration.add_option(:name, 'John Doe') + # + # # with a dynamic default value, evaluated once when calling #build! + # configuration.add_option(:name, 'John Doe') + # configuration.add_option(:username) do |config| + # config.name.gsub(/\W+/, '').downcase + # end + # cfg = configuration.build! + # cfg.name #=> 'John Doe' + # cfg.username #=> 'johndoe' + # + # @param name [Symbol] The name of the configuration option. This will + # be used to define a getter by the same name. + # @param default The default value for this option. You can specify + # a default by passing a value, a `Proc` object or a block argument. + # Procs and blocks are evaluated when {#build!} is called. + # @return [self] + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#108 + def add_option(name, default = T.unsafe(nil), &block); end + + # Constructs and returns a configuration structure. + # Values not present in `options` will default to those supplied via + # add option. + # + # configuration = Configuration.new + # configuration.add_option(:enabled, true) + # + # cfg1 = configuration.build! + # cfg1.enabled #=> true + # + # cfg2 = configuration.build!(enabled: false) + # cfg2.enabled #=> false + # + # If you pass in options to `#build!` that have not been defined, + # then an `ArgumentError` will be raised. + # + # configuration = Configuration.new + # configuration.add_option(:enabled, true) + # + # # oops, spelling error for :enabled + # cfg = configuration.build!(enabld: true) + # #=> raises ArgumentError + # + # The object returned is a frozen `Struct`. + # + # configuration = Configuration.new + # configuration.add_option(:enabled, true) + # + # cfg = configuration.build! + # cfg.enabled #=> true + # cfg[:enabled] #=> true + # cfg['enabled'] #=> true + # + # @param options [Hash] ({}) A hash of configuration options. + # @return [Struct] Returns a frozen configuration `Struct`. + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#149 + def build!(options = T.unsafe(nil)); end + + private + + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#173 + def apply_defaults(struct, options); end + + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#162 + def apply_options(struct, options); end + + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#158 + def empty_struct; end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/configuration.rb#183 +class Seahorse::Client::Configuration::DefaultResolver + # @api private + # @return [DefaultResolver] a new instance of DefaultResolver + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#185 + def initialize(struct); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#198 + def override_config(k, v); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#190 + def resolve; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#194 + def respond_to?(method_name, *args); end + + private + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#222 + def method_missing(method_name, *args); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#213 + def resolve_defaults(opt_name, defaults); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#204 + def value_at(opt_name); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/configuration.rb#57 +class Seahorse::Client::Configuration::Defaults < ::Array + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#58 + def each(&block); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/configuration.rb#64 +class Seahorse::Client::Configuration::DynamicDefault + # @api private + # @return [DynamicDefault] a new instance of DynamicDefault + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#67 + def initialize(block = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#65 + def block; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#65 + def block=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/configuration.rb#71 + def call(*args); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#12 +module Seahorse::Client::H2; end + +# H2 Connection build on top of `http/2` gem +# (requires Ruby >= 2.1) +# with TLS layer plus ALPN, requires: +# Ruby >= 2.3 and OpenSSL >= 1.0.2 +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#18 +class Seahorse::Client::H2::Connection + # @api private + # @return [Connection] a new instance of Connection + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#38 + def initialize(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#141 + def close!; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#152 + def closed?; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#75 + def connect(endpoint); end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def connection_read_timeout; end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def connection_timeout; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#156 + def debug_output(msg, type = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def enable_alpn; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#63 + def errors; end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def http_wire_trace; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#65 + def input_signal_thread; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#65 + def input_signal_thread=(_arg0); end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def logger; end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def max_concurrent_streams; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#67 + def new_stream; end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def ssl_ca_bundle; end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def ssl_ca_directory; end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def ssl_ca_store; end + + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def ssl_verify_peer; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#58 + def ssl_verify_peer?; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#105 + def start(stream); end + + private + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#169 + def _debug_entry(str); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#238 + def _default_ca_bundle; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#243 + def _default_ca_directory; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#205 + def _nonblocking_connect(tcp, addr); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#174 + def _register_h2_callbacks; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#195 + def _tcp_socket(endpoint); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#221 + def _tls_context; end +end + +# chunk read size at socket +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#34 +Seahorse::Client::H2::Connection::CHUNKSIZE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#20 +Seahorse::Client::H2::Connection::OPTIONS = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/connection.rb#36 +Seahorse::Client::H2::Connection::SOCKET_FAMILY = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#22 +Seahorse::Client::H2::DNS_ERROR_MESSAGES = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#27 +class Seahorse::Client::H2::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#29 + def call(context); end + + private + + # H2 pseudo headers + # https://http2.github.io/http2-spec/#rfc.section.8.1.2.3 + # + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#127 + def _h2_headers(req); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#85 + def _register_callbacks(resp, stream, stream_mutex, close_condition, sync_queue); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#115 + def _send_initial_data(req, stream); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#106 + def _send_initial_headers(req, stream); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#140 + def error_message(req, error); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/h2/handler.rb#14 +Seahorse::Client::H2::NETWORK_ERRORS = T.let(T.unsafe(nil), Array) + +# source://aws-sdk-core//lib/seahorse/client/handler.rb#5 +class Seahorse::Client::Handler + # @param handler [Handler] (nil) The next handler in the stack that + # should be called from within the {#call} method. This value + # must only be nil for send handlers. + # @return [Handler] a new instance of Handler + # + # source://aws-sdk-core//lib/seahorse/client/handler.rb#10 + def initialize(handler = T.unsafe(nil)); end + + # @param context [RequestContext] + # @return [Seahorse::Response] + # + # source://aws-sdk-core//lib/seahorse/client/handler.rb#19 + def call(context); end + + # @return [Handler, nil] + # + # source://aws-sdk-core//lib/seahorse/client/handler.rb#15 + def handler; end + + # @return [Handler, nil] + # + # source://aws-sdk-core//lib/seahorse/client/handler.rb#15 + def handler=(_arg0); end + + # source://aws-sdk-core//lib/seahorse/client/handler.rb#23 + def inspect; end +end + +# This module provides the ability to add handlers to a class or +# module. The including class or extending module must respond to +# `#handlers`, returning a {HandlerList}. +# +# source://aws-sdk-core//lib/seahorse/client/handler_builder.rb#9 +module Seahorse::Client::HandlerBuilder + # source://aws-sdk-core//lib/seahorse/client/handler_builder.rb#26 + def handle(*args, &block); end + + # source://aws-sdk-core//lib/seahorse/client/handler_builder.rb#11 + def handle_request(*args, &block); end + + # source://aws-sdk-core//lib/seahorse/client/handler_builder.rb#18 + def handle_response(*args, &block); end + + # source://aws-sdk-core//lib/seahorse/client/handler_builder.rb#26 + def handler(*args, &block); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/handler_builder.rb#34 + def handler_for(name = T.unsafe(nil), &block); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/handler_builder.rb#43 + def new_handler(block); end +end + +# source://aws-sdk-core//lib/seahorse/client/handler_list.rb#8 +class Seahorse::Client::HandlerList + include ::Enumerable + + # @api private + # @return [HandlerList] a new instance of HandlerList + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#13 + def initialize(options = T.unsafe(nil)); end + + # Registers a handler. Handlers are used to build a handler stack. + # Handlers default to the `:build` step with default priority of 50. + # The step and priority determine where in the stack a handler + # will be. + # + # ## Handler Stack Ordering + # + # A handler stack is built from the inside-out. The stack is + # seeded with the send handler. Handlers are constructed recursively + # in reverse step and priority order so that the highest priority + # handler is on the outside. + # + # By constructing the stack from the inside-out, this ensures + # that the validate handlers will be called first and the sign handlers + # will be called just before the final and only send handler is called. + # + # ## Steps + # + # Handlers are ordered first by step. These steps represent the + # life-cycle of a request. Valid steps are: + # + # * `:initialize` + # * `:validate` + # * `:build` + # * `:sign` + # * `:send` + # + # Many handlers can be added to the same step, except for `:send`. + # There can be only one `:send` handler. Adding an additional + # `:send` handler replaces the previous one. + # + # ## Priorities + # + # Handlers within a single step are executed in priority order. The + # higher the priority, the earlier in the stack the handler will + # be called. + # + # * Handler priority is an integer between 0 and 99, inclusively. + # * Handler priority defaults to 50. + # * When multiple handlers are added to the same step with the same + # priority, the last one added will have the highest priority and + # the first one added will have the lowest priority. + # + # @note There can be only one `:send` handler. Adding an additional + # send handler replaces the previous. + # @option options + # @option options + # @option options + # @param handler_class [Class] This should be a subclass + # of {Handler}. + # @param options [Hash] a customizable set of options + # @raise [InvalidStepError] + # @raise [InvalidPriorityError] + # @return [Class] Returns the handler class that was added. + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#105 + def add(handler_class, options = T.unsafe(nil)); end + + # Copies handlers from the `source_list` onto the current handler list. + # If a block is given, only the entries that return a `true` value + # from the block will be copied. + # + # @param source_list [HandlerList] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#129 + def copy_from(source_list, &block); end + + # Yields the handlers in stack order, which is reverse priority. + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#151 + def each(&block); end + + # @return [Array] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#22 + def entries; end + + # Returns a handler list for the given operation. The returned + # will have the operation specific handlers merged with the common + # handlers. + # + # @param operation [String] The name of an operation. + # @return [HandlerList] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#146 + def for(operation); end + + # @param handler_class [Class] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#118 + def remove(handler_class); end + + # Constructs the handlers recursively, building a handler stack. + # The `:send` handler will be at the top of the stack and the + # `:validate` handlers will be at the bottom. + # + # @return [Handler] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#161 + def to_stack; end + + private + + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#167 + def add_entries(entries); end + + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#173 + def add_entry(entry); end + + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#178 + def filter(operation); end + + # source://aws-sdk-core//lib/seahorse/client/handler_list.rb#189 + def next_index; end +end + +# A container for an un-constructed handler. A handler entry has the +# handler class, and information about handler priority/order. +# +# This class is an implementation detail of the {HandlerList} class. +# Do not rely on public interfaces of this class. +# +# source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#11 +class Seahorse::Client::HandlerListEntry + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [HandlerListEntry] a new instance of HandlerListEntry + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#28 + def initialize(options); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#62 + def <=>(other); end + + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [HandlerListEntry] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#72 + def copy(options = T.unsafe(nil)); end + + # @return [Handler, Class] Returns the handler. This may + # be a constructed handler object or a handler class. + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#41 + def handler_class; end + + # @return [Integer] The insertion order/position. This is used to + # determine sort order when two entries have the same priority. + # Entries inserted later (with a higher inserted value) have a + # lower priority. + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#47 + def inserted; end + + # @return [Set] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#56 + def operations; end + + # @return [Integer] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#53 + def priority; end + + # @return [Symbol] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#50 + def step; end + + # @return [Integer] + # + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#59 + def weight; end + + private + + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#106 + def compute_weight; end + + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#78 + def option(name, options); end + + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#97 + def set_priority(priority); end + + # source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#87 + def set_step(step); end +end + +# source://aws-sdk-core//lib/seahorse/client/handler_list_entry.rb#13 +Seahorse::Client::HandlerListEntry::STEPS = T.let(T.unsafe(nil), Hash) + +# source://aws-sdk-core//lib/seahorse/client/http/headers.rb#5 +module Seahorse::Client::Http; end + +# Rasied when trying to use an closed connection +# +# source://aws-sdk-core//lib/seahorse/client/networking_error.rb#43 +class Seahorse::Client::Http2ConnectionClosedError < ::StandardError; end + +# Raised when sending initial headers and data failed +# for event stream requests over Http2 +# +# source://aws-sdk-core//lib/seahorse/client/networking_error.rb#19 +class Seahorse::Client::Http2InitialRequestError < ::StandardError + # @return [Http2InitialRequestError] a new instance of Http2InitialRequestError + # + # source://aws-sdk-core//lib/seahorse/client/networking_error.rb#21 + def initialize(error); end + + # @return [HTTP2::Error] + # + # source://aws-sdk-core//lib/seahorse/client/networking_error.rb#26 + def original_error; end +end + +# Raised when connection failed to initialize a new stream +# +# source://aws-sdk-core//lib/seahorse/client/networking_error.rb#31 +class Seahorse::Client::Http2StreamInitializeError < ::StandardError + # @return [Http2StreamInitializeError] a new instance of Http2StreamInitializeError + # + # source://aws-sdk-core//lib/seahorse/client/networking_error.rb#33 + def initialize(error); end + + # @return [HTTP2::Error] + # + # source://aws-sdk-core//lib/seahorse/client/networking_error.rb#38 + def original_error; end +end + +# source://aws-sdk-core//lib/seahorse/client/http/async_response.rb#6 +class Seahorse::Client::Http::AsyncResponse < ::Seahorse::Client::Http::Response + # @return [AsyncResponse] a new instance of AsyncResponse + # + # source://aws-sdk-core//lib/seahorse/client/http/async_response.rb#8 + def initialize(options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/seahorse/client/http/async_response.rb#24 + def signal_done(options = T.unsafe(nil)); end + + # source://aws-sdk-core//lib/seahorse/client/http/async_response.rb#12 + def signal_headers(headers); end +end + +# Provides a Hash-like interface for HTTP headers. Header names +# are treated indifferently as lower-cased strings. Header values +# are cast to strings. +# +# headers = Http::Headers.new +# headers['Content-Length'] = 100 +# headers[:Authorization] = 'Abc' +# +# headers.keys +# #=> ['content-length', 'authorization'] +# +# headers.values +# #=> ['100', 'Abc'] +# +# You can get the header values as a vanilla hash by calling {#to_h}: +# +# headers.to_h +# #=> { 'content-length' => '100', 'authorization' => 'Abc' } +# +# source://aws-sdk-core//lib/seahorse/client/http/headers.rb#26 +class Seahorse::Client::Http::Headers + include ::Enumerable + + # @api private + # @return [Headers] a new instance of Headers + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#31 + def initialize(headers = T.unsafe(nil)); end + + # @param key [String] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#40 + def [](key); end + + # @param key [String] + # @param value [String] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#46 + def []=(key, value); end + + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#64 + def clear; end + + # @param key [String] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#60 + def delete(key); end + + # @return [nil] + # @yield [key, value] + # @yieldparam key [String] + # @yieldparam value [String] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#87 + def each(&block); end + + # @return [nil] + # @yield [key, value] + # @yieldparam key [String] + # @yieldparam value [String] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#87 + def each_pair(&block); end + + # @return [Boolean] Returns `true` if the header is set. + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#100 + def has_key?(key); end + + # @return [Boolean] Returns `true` if the header is set. + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#100 + def include?(key); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#113 + def inspect; end + + # @return [Boolean] Returns `true` if the header is set. + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#100 + def key?(key); end + + # @return [Array] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#69 + def keys; end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#107 + def to_h; end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#107 + def to_hash; end + + # @param headers [Hash] + # @return [Headers] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#52 + def update(headers); end + + # @return [Array] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#74 + def values; end + + # @return [Array] + # + # source://aws-sdk-core//lib/seahorse/client/http/headers.rb#79 + def values_at(*keys); end +end + +# source://aws-sdk-core//lib/seahorse/client/http/request.rb#9 +class Seahorse::Client::Http::Request + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Request] a new instance of Request + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#15 + def initialize(options = T.unsafe(nil)); end + + # @return [IO] + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#46 + def body; end + + # @param io [#read, #size, #rewind] + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#59 + def body=(io); end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#51 + def body_contents; end + + # @return [URI::HTTP, URI::HTTPS, nil] + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#29 + def endpoint; end + + # @param endpoint [String, URI::HTTP, URI::HTTPS, nil] + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#34 + def endpoint=(endpoint); end + + # @return [Headers] The hash of request headers. + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#26 + def headers; end + + # @return [Headers] The hash of request headers. + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#26 + def headers=(_arg0); end + + # @return [String] The HTTP request method, e.g. `GET`, `PUT`, etc. + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#23 + def http_method; end + + # @return [String] The HTTP request method, e.g. `GET`, `PUT`, etc. + # + # source://aws-sdk-core//lib/seahorse/client/http/request.rb#23 + def http_method=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/client/http/response.rb#6 +class Seahorse::Client::Http::Response + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Response] a new instance of Response + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#11 + def initialize(options = T.unsafe(nil)); end + + # @return [IO] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#32 + def body; end + + # @param io [#read, #size, #rewind] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#37 + def body=(io); end + + # @return [String|Array] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#46 + def body_contents; end + + # @return [StandardError, nil] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#29 + def error; end + + # @return [Headers] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#26 + def headers; end + + # @return [Headers] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#26 + def headers=(_arg0); end + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#130 + def on_data(&callback); end + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#134 + def on_done(status_code_range = T.unsafe(nil), &callback); end + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#151 + def on_error(&callback); end + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#126 + def on_headers(status_code_range = T.unsafe(nil), &block); end + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#143 + def on_success(status_code_range = T.unsafe(nil), &callback); end + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#159 + def reset; end + + # @param chunk [string] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#67 + def signal_data(chunk); end + + # Completes the http response. + # + # @example Completing the response in a single call + # + # http_response.signal_done( + # status_code: 200, + # headers: {}, + # body: '' + # ) + # @example Complete the response in parts + # + # # signal headers straight-way + # http_response.signal_headers(200, {}) + # + # # signal data as it is received from the socket + # http_response.signal_data("...") + # http_response.signal_data("...") + # http_response.signal_data("...") + # + # # signal done once the body data is all written + # http_response.signal_done + # @overload signal_done + # @overload signal_done + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#104 + def signal_done(options = T.unsafe(nil)); end + + # @param networking_error [StandardError] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#121 + def signal_error(networking_error); end + + # @param status_code [Integer] + # @param headers [Hash] + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#60 + def signal_headers(status_code, headers); end + + # @return [Integer] Returns `0` if the request failed to generate + # any response. + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#23 + def status_code; end + + # @return [Integer] Returns `0` if the request failed to generate + # any response. + # + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#23 + def status_code=(_arg0); end + + private + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#181 + def emit(event_name, *args); end + + # source://aws-sdk-core//lib/seahorse/client/http/response.rb#168 + def listener(range, callback); end +end + +# @api private +# @deprecated Use Aws::Logging instead. +# +# source://aws-sdk-core//lib/seahorse/client/logging/handler.rb#7 +module Seahorse::Client::Logging; end + +# A log formatter receives a {Response} object and return +# a log message as a string. When you construct a {Formatter}, you provide +# a pattern string with substitutions. +# +# pattern = ':operation :http_response_status_code :time' +# formatter = Seahorse::Client::Logging::Formatter.new(pattern) +# formatter.format(response) +# #=> 'get_bucket 200 0.0352' +# +# # Canned Formatters +# +# Instead of providing your own pattern, you can choose a canned log +# formatter. +# +# * {Formatter.default} +# * {Formatter.colored} +# * {Formatter.short} +# +# # Pattern Substitutions +# +# You can put any of these placeholders into you pattern. +# +# * `:client_class` - The name of the client class. +# +# * `:operation` - The name of the client request method. +# +# * `:request_params` - The user provided request parameters. Long +# strings are truncated/summarized if they exceed the +# {#max_string_size}. Other objects are inspected. +# +# * `:time` - The total time in seconds spent on the +# request. This includes client side time spent building +# the request and parsing the response. +# +# * `:retries` - The number of times a client request was retried. +# +# * `:http_request_method` - The http request verb, e.g., `POST`, +# `PUT`, `GET`, etc. +# +# * `:http_request_endpoint` - The request endpoint. This includes +# the scheme, host and port, but not the path. +# +# * `:http_request_scheme` - This is replaced by `http` or `https`. +# +# * `:http_request_host` - The host name of the http request +# endpoint (e.g. 's3.amazon.com'). +# +# * `:http_request_port` - The port number (e.g. '443' or '80'). +# +# * `:http_request_headers` - The http request headers, inspected. +# +# * `:http_request_body` - The http request payload. +# +# * `:http_response_status_code` - The http response status +# code, e.g., `200`, `404`, `500`, etc. +# +# * `:http_response_headers` - The http response headers, inspected. +# +# * `:http_response_body` - The http response body contents. +# +# * `:error_class` +# +# * `:error_message` +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#75 +class Seahorse::Client::Logging::Formatter + # @api private + # @option options + # @param pattern [String] The log format pattern should be a string + # and may contain substitutions. + # @param options [Hash] a customizable set of options + # @return [Formatter] a new instance of Formatter + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#84 + def initialize(pattern, options = T.unsafe(nil)); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#104 + def ==(other); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#104 + def eql?(other); end + + # Given a {Response}, this will format a log message and return it + # as a string. + # + # @api private + # @param response [Response] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#99 + def format(response); end + + # @api private + # @return [Integer] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#93 + def max_string_size; end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#90 + def pattern; end + + private + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#119 + def _client_class(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#185 + def _error_class(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#189 + def _error_message(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#165 + def _http_request_body(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#141 + def _http_request_endpoint(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#161 + def _http_request_headers(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#149 + def _http_request_host(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#157 + def _http_request_method(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#153 + def _http_request_port(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#145 + def _http_request_scheme(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#177 + def _http_response_body(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#173 + def _http_response_headers(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#169 + def _http_response_status_code(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#123 + def _operation(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#127 + def _request_params(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#137 + def _retries(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#131 + def _time(response); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#111 + def method_missing(method_name, *args); end + + # @api private + # @param array [Array] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#247 + def summarize_array(array); end + + # Given the path to a file on disk, this method returns a summarized + # inspecton string that includes the file size. + # + # @api private + # @param path [String] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#241 + def summarize_file(path); end + + # @api private + # @param hash [Hash] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#195 + def summarize_hash(hash); end + + # @api private + # @param str [String] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#228 + def summarize_string(str); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#207 + def summarize_string_hash(hash); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#201 + def summarize_symbol_hash(hash); end + + # @api private + # @param value [Object] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#215 + def summarize_value(value); end + + class << self + # The default log format with ANSI colors. + # + # @api private + # @example A sample of the colored format (sans the ansi colors). + # + # [ClientClass 200 0.580066 0 retries] list_objects(:bucket_name => 'bucket') + # @return [Formatter] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#300 + def colored; end + + # The default log format. + # + # @api private + # @example A sample of the default format. + # + # [ClientClass 200 0.580066 0 retries] list_objects(:bucket_name => 'bucket') + # @return [Formatter] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#261 + def default; end + + # The short log format. Similar to default, but it does not + # inspect the request params or report on retries. + # + # @api private + # @example A sample of the short format + # + # [ClientClass 200 0.494532] list_buckets + # @return [Formatter] + # + # source://aws-sdk-core//lib/seahorse/client/logging/formatter.rb#282 + def short; end + end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/logging/handler.rb#8 +class Seahorse::Client::Logging::Handler < ::Seahorse::Client::Handler + # @api private + # @param context [RequestContext] + # @return [Response] + # + # source://aws-sdk-core//lib/seahorse/client/logging/handler.rb#12 + def call(context); end + + private + + # @api private + # @param config [Configuration] + # @param response [Response] + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/logging/handler.rb#32 + def format(config, response); end + + # @api private + # @param config [Configuration] + # @param response [Response] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/logging/handler.rb#25 + def log(config, response); end +end + +# This utility class is used to track files opened by Seahorse. +# This allows Seahorse to know what files it needs to close. +# +# source://aws-sdk-core//lib/seahorse/client/managed_file.rb#7 +class Seahorse::Client::ManagedFile < ::File + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/managed_file.rb#10 + def open?; end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/patches.rb#8 +module Seahorse::Client::NetHttp; end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#19 +class Seahorse::Client::NetHttp::ConnectionPool + # @api private + # @return [ConnectionPool] a new instance of ConnectionPool + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#41 + def initialize(options = T.unsafe(nil)); end + + # Removes stale http sessions from the pool (that have exceeded + # the idle timeout). + # + # @api private + # @return [nil] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#129 + def clean!; end + + # Closes and removes all sessions from the pool. + # If empty! is called while there are outstanding requests they may + # get checked back into the pool, leaving the pool in a non-empty + # state. + # + # @api private + # @return [nil] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#139 + def empty!; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def http_continue_timeout; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def http_idle_timeout; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def http_open_timeout; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def http_proxy; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def http_read_timeout; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def http_wire_trace; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def http_wire_trace?; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def logger; end + + # Makes an HTTP request, yielding a Net::HTTPResponse object. + # + # pool.request(URI.parse('http://domain'), Net::HTTP::Get.new('/')) do |resp| + # puts resp.code # status code + # puts resp.to_h.inspect # dump the headers + # puts resp.body + # end + # + # @api private + # @param endpoint [URI::HTTP, URI::HTTPS] The HTTP(S) endpoint + # to connect to (e.g. 'https://domain.com'). + # @param request [Net::HTTPRequest] The request to make. This can be + # any request object from Net::HTTP (e.g. Net::HTTP::Get, + # Net::HTTP::POST, etc). + # @return [nil] + # @yieldparam net_http_response [Net::HTTPResponse] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#75 + def request(endpoint, request, &block); end + + # @api private + # @param endpoint [URI::HTTP, URI::HTTPS] The HTTP(S) endpoint + # to connect to (e.g. 'https://domain.com'). + # @return [nil] + # @yieldparam session [Net::HTTPSession] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#87 + def session_for(endpoint, &block); end + + # @api private + # @return [Integer] Returns the count of sessions currently in the + # pool, not counting those currently in use. + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#120 + def size; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def ssl_ca_bundle; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def ssl_ca_directory; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def ssl_ca_store; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def ssl_timeout; end + + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def ssl_verify_peer; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#51 + def ssl_verify_peer?; end + + private + + # Removes stale sessions from the pool. This method *must* be called + # + # @api private + # @note **Must** be called behind a `@pool_mutex` synchronize block. + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#307 + def _clean; end + + # Extract the parts of the http_proxy URI + # + # @api private + # @return [Array(String)] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#259 + def http_proxy_parts; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#149 + def remove_path_and_query(endpoint); end + + # Starts and returns a new HTTP(S) session. + # + # @api private + # @param endpoint [String] + # @return [Net::HTTPSession] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#271 + def start_session(endpoint); end + + class << self + # Returns a connection pool constructed from the given options. + # Calling this method twice with the same options will return + # the same pool. + # + # @api private + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [ConnectionPool] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#213 + def for(options = T.unsafe(nil)); end + + # @api private + # @return [Array] Returns a list of the + # constructed connection pools. + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#222 + def pools; end + + private + + # Filters an option hash, merging in default values. + # + # @api private + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#232 + def pool_options(options); end + end +end + +# Helper methods extended onto Net::HTTPSession objects opened by the +# connection pool. +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#322 +class Seahorse::Client::NetHttp::ConnectionPool::ExtendedSession + # @api private + # @return [ExtendedSession] a new instance of ExtendedSession + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#324 + def initialize(http); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#332 + def __getobj__; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#336 + def __setobj__(obj); end + + # Attempts to close/finish the session without raising an error. + # + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#347 + def finish; end + + # @api private + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#330 + def last_used; end + + # Sends the request and tracks that this session has been used. + # + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#341 + def request(*args, &block); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/connection_pool.rb#25 +Seahorse::Client::NetHttp::ConnectionPool::OPTIONS = T.let(T.unsafe(nil), Hash) + +# The default HTTP handler for Seahorse::Client. This is based on +# the Ruby's `Net::HTTP`. +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#13 +class Seahorse::Client::NetHttp::Handler < ::Seahorse::Client::Handler + # @api private + # @param context [RequestContext] + # @return [Response] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#44 + def call(context); end + + # @api private + # @param config [Configuration] + # @return [ConnectionPool] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#51 + def pool_for(config); end + + private + + # Constructs and returns a Net::HTTP::Request object from + # a {Http::Request}. + # + # @api private + # @param request [Http::Request] + # @return [Net::HTTP::Request] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#146 + def build_net_request(request); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#100 + def complete_response(req, resp, bytes_received); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#57 + def error_message(req, error); end + + # @api private + # @param response [Net::HTTP::Response] + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#188 + def extract_headers(response); end + + # @api private + # @param request [Http::Request] + # @return [Hash] Returns a vanilla hash of headers to send with the + # HTTP request. + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#172 + def headers(request); end + + # @api private + # @param request [Http::Request] + # @raise [InvalidHttpVerbError] + # @return Returns a base `Net::HTTP::Request` class, e.g., + # `Net::HTTP::Get`, `Net::HTTP::Post`, etc. + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#162 + def net_http_request_class(request); end + + # Extracts the {ConnectionPool} configuration options. + # + # @api private + # @param config [Configuration] + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#135 + def pool_options(config); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#122 + def session(config, req, &block); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#108 + def should_verify_bytes?(req, resp); end + + # @api private + # @param config [Configuration] + # @param req [Http::Request] + # @param resp [Http::Response] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#70 + def transmit(config, req, resp); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#112 + def verify_bytes_received(resp, bytes_received); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#33 +Seahorse::Client::NetHttp::Handler::DNS_ERROR_MESSAGES = T.let(T.unsafe(nil), Array) + +# Raised when a {Handler} cannot construct a `Net::HTTP::Request` +# from the given http verb. +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#40 +class Seahorse::Client::NetHttp::Handler::InvalidHttpVerbError < ::StandardError; end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#24 +Seahorse::Client::NetHttp::Handler::NETWORK_ERRORS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#16 +class Seahorse::Client::NetHttp::Handler::TruncatedBodyError < ::IOError + # @api private + # @return [TruncatedBodyError] a new instance of TruncatedBodyError + # + # source://aws-sdk-core//lib/seahorse/client/net_http/handler.rb#17 + def initialize(bytes_expected, bytes_received); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/patches.rb#11 +module Seahorse::Client::NetHttp::Patches + class << self + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/patches.rb#13 + def apply!; end + end +end + +# For requests with bodies, Net::HTTP sets a default content type of: +# 'application/x-www-form-urlencoded' +# There are cases where we should not send content type at all. +# Even when no body is supplied, Net::HTTP uses a default empty body +# and sets it anyway. This patch disables the behavior when a Thread +# local variable is set. +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/net_http/patches.rb#23 +module Seahorse::Client::NetHttp::Patches::PatchDefaultContentType + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/net_http/patches.rb#24 + def supply_default_content_type; end +end + +# source://aws-sdk-core//lib/seahorse/client/networking_error.rb#5 +class Seahorse::Client::NetworkingError < ::StandardError + # @return [NetworkingError] a new instance of NetworkingError + # + # source://aws-sdk-core//lib/seahorse/client/networking_error.rb#7 + def initialize(error, msg = T.unsafe(nil)); end + + # Returns the value of attribute original_error. + # + # source://aws-sdk-core//lib/seahorse/client/networking_error.rb#13 + def original_error; end +end + +# source://aws-sdk-core//lib/seahorse/client/plugin.rb#5 +class Seahorse::Client::Plugin + extend ::Seahorse::Client::HandlerBuilder + + # @param handlers [HandlerList] + # @param config [Configuration] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#24 + def add_handlers(handlers, config); end + + # @param config [Configuration] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#11 + def add_options(config); end + + # @param client [Client::Base] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#39 + def after_initialize(client); end + + # @param client_class [Class] + # @param options [Hash] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#31 + def before_initialize(client_class, options); end + + class << self + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#71 + def after_initialize(&block); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#91 + def after_initialize_hooks; end + + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#67 + def before_initialize(&block); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#86 + def before_initialize_hooks; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#81 + def handlers; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#96 + def literal(string); end + + # @option options + # @option options + # @option options + # @option options + # @option options + # @overload option + # @param options [Hash] a customizable set of options + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#54 + def option(name, default = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#76 + def options; end + end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugin.rb#110 +class Seahorse::Client::Plugin::PluginOption + # @api private + # @return [PluginOption] a new instance of PluginOption + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#112 + def initialize(name, options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#129 + def default; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#129 + def default=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#130 + def default_block; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#130 + def default_block=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#137 + def doc_default(options); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#133 + def doc_default=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#132 + def doc_type; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#132 + def doc_type=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#134 + def docstring; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#134 + def docstring=(_arg0); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#145 + def documented?; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#128 + def name; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#135 + def rbs_type; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#135 + def rbs_type=(_arg0); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#131 + def required; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin.rb#131 + def required=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#8 +class Seahorse::Client::PluginList + include ::Enumerable + + # @option options + # @param plugins [Array, Set] + # @param options [Hash] a customizable set of options + # @return [PluginList] a new instance of PluginList + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#14 + def initialize(plugins = T.unsafe(nil), options = T.unsafe(nil)); end + + # Adds and returns the `plugin`. + # + # @param plugin [Plugin] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#27 + def add(plugin); end + + # Enumerates the plugins. + # + # @return [Enumerator] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#59 + def each(&block); end + + # Removes and returns the `plugin`. + # + # @param plugin [Plugin] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#37 + def remove(plugin); end + + # Replaces the existing list of plugins. + # + # @param plugins [Array] + # @return [void] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#47 + def set(plugins); end + + private + + # Not safe to call outside the mutex. + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#68 + def _add(plugin); end + + # Yield each PluginDetail behind the mutex + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#73 + def each_plugin(&block); end +end + +# A utility class that computes the canonical name for a plugin +# and defers requiring the plugin until the plugin class is +# required. +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#83 +class Seahorse::Client::PluginList::PluginWrapper + # @api private + # @param plugin [String, Symbol, Module, Class] + # @return [PluginWrapper] a new instance of PluginWrapper + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#86 + def initialize(plugin); end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#103 + def canonical_name; end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#121 + def eql?(other); end + + # @api private + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#127 + def hash; end + + # @api private + # @return [Class] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#106 + def plugin; end + + private + + # @api private + # @return [Class] + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#134 + def require_plugin; end + + class << self + # Returns the given plugin if it is already a PluginWrapper. + # + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugin_list.rb#111 + def new(plugin); end + end +end + +# source://aws-sdk-core//lib/seahorse/client/plugins/content_length.rb#5 +module Seahorse::Client::Plugins; end + +# source://aws-sdk-core//lib/seahorse/client/plugins/content_length.rb#6 +class Seahorse::Client::Plugins::ContentLength < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/content_length.rb#9 +class Seahorse::Client::Plugins::ContentLength::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/content_length.rb#17 + def call(context); end +end + +# https://github.com/ruby/net-http/blob/master/lib/net/http/requests.rb +# Methods without body are forwards compatible, because content-length +# may be set for requests without body but is technically incorrect. +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/content_length.rb#13 +Seahorse::Client::Plugins::ContentLength::Handler::METHODS_WITHOUT_BODY = T.let(T.unsafe(nil), Set) + +# source://aws-sdk-core//lib/seahorse/client/plugins/endpoint.rb#6 +class Seahorse::Client::Plugins::Endpoint < ::Seahorse::Client::Plugin + # source://aws-sdk-core//lib/seahorse/client/plugins/endpoint.rb#22 + def add_handlers(handlers, config); end + + # source://aws-sdk-core//lib/seahorse/client/plugins/endpoint.rb#26 + def after_initialize(client); end +end + +# source://aws-sdk-core//lib/seahorse/client/plugins/endpoint.rb#42 +class Seahorse::Client::Plugins::Endpoint::Handler < ::Seahorse::Client::Handler + # source://aws-sdk-core//lib/seahorse/client/plugins/endpoint.rb#44 + def call(context); end +end + +# source://aws-sdk-core//lib/seahorse/client/plugins/h2.rb#8 +class Seahorse::Client::Plugins::H2 < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/logging.rb#7 +class Seahorse::Client::Plugins::Logging < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/logging.rb#28 + def add_handlers(handlers, config); end +end + +# source://aws-sdk-core//lib/seahorse/client/plugins/net_http.rb#8 +class Seahorse::Client::Plugins::NetHttp < ::Seahorse::Client::Plugin + class << self + # source://aws-sdk-core//lib/seahorse/client/plugins/net_http.rb#77 + def resolve_http_open_timeout(cfg); end + + # source://aws-sdk-core//lib/seahorse/client/plugins/net_http.rb#85 + def resolve_http_read_timeout(cfg); end + + # source://aws-sdk-core//lib/seahorse/client/plugins/net_http.rb#93 + def resolve_ssl_timeout(cfg); end + end +end + +# source://aws-sdk-core//lib/seahorse/client/plugins/raise_response_errors.rb#6 +class Seahorse::Client::Plugins::RaiseResponseErrors < ::Seahorse::Client::Plugin + # source://aws-sdk-core//lib/seahorse/client/plugins/raise_response_errors.rb#22 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/raise_response_errors.rb#14 +class Seahorse::Client::Plugins::RaiseResponseErrors::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/raise_response_errors.rb#15 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#11 +class Seahorse::Client::Plugins::ReadCallbackIO + extend ::Forwardable + + # @api private + # @return [ReadCallbackIO] a new instance of ReadCallbackIO + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#15 + def initialize(io, on_read = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#32 + def io; end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#34 + def read(*args); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def size(*args, **_arg1, &block); end + + private + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#42 + def handle_chunk(chunk); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#50 +class Seahorse::Client::Plugins::RequestCallback < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#74 +class Seahorse::Client::Plugins::RequestCallback::OptionHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#92 + def add_response_events(on_chunk_received, context); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#75 + def call(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#107 +class Seahorse::Client::Plugins::RequestCallback::ReadCallbackHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#108 + def call(context); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/request_callback.rb#122 + def unwrap_callback_body(context); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/response_target.rb#9 +class Seahorse::Client::Plugins::ResponseTarget < ::Seahorse::Client::Plugin; end + +# This handler is responsible for replacing the HTTP response body IO +# object with custom targets, such as a block, or a file. It is important +# to not write data to the custom target in the case of a non-success +# response. We do not want to write an XML error message to someone's +# file. +# +# @api private +# +# source://aws-sdk-core//lib/seahorse/client/plugins/response_target.rb#16 +class Seahorse::Client::Plugins::ResponseTarget::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/response_target.rb#18 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/response_target.rb#29 + def add_event_listeners(context, target); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/plugins/response_target.rb#64 + def io(target, headers); end +end + +# source://aws-sdk-core//lib/seahorse/client/request.rb#5 +class Seahorse::Client::Request + include ::Seahorse::Client::HandlerBuilder + + # @param handlers [HandlerList] + # @param context [RequestContext] + # @return [Request] a new instance of Request + # + # source://aws-sdk-core//lib/seahorse/client/request.rb#11 + def initialize(handlers, context); end + + # @return [RequestContext] + # + # source://aws-sdk-core//lib/seahorse/client/request.rb#20 + def context; end + + # @return [HandlerList] + # + # source://aws-sdk-core//lib/seahorse/client/request.rb#17 + def handlers; end + + # Sends the request, returning a {Response} object. + # + # response = request.send_request + # + # # Streaming Responses + # + # By default, HTTP responses are buffered into memory. This can be + # bad if you are downloading large responses, e.g. large files. + # You can avoid this by streaming the response to a block or some other + # target. + # + # ## Streaming to a File + # + # You can stream the raw HTTP response body to a File, or any IO-like + # object, by passing the `:target` option. + # + # # create a new file at the given path + # request.send_request(target: '/path/to/target/file') + # + # # or provide an IO object to write to + # File.open('photo.jpg', 'wb') do |file| + # request.send_request(target: file) + # end + # + # **Please Note**: The target IO object may receive `#truncate(0)` + # if the request generates a networking error and bytes have already + # been written to the target. + # + # ## Block Streaming + # + # Pass a block to `#send_request` and the response will be yielded in + # chunks to the given block. + # + # # stream the response data + # request.send_request do |chunk| + # file.write(chunk) + # end + # + # **Please Note**: When streaming to a block, it is not possible to + # retry failed requests. + # + # @option options + # @param options [Hash] a customizable set of options + # @return [Response] + # + # source://aws-sdk-core//lib/seahorse/client/request.rb#70 + def send_request(options = T.unsafe(nil), &block); end +end + +# source://aws-sdk-core//lib/seahorse/client/request_context.rb#7 +class Seahorse::Client::RequestContext + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [RequestContext] a new instance of RequestContext + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#17 + def initialize(options = T.unsafe(nil)); end + + # Returns the metadata for the given `key`. + # + # @param key [Symbol] + # @return [Object] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#63 + def [](key); end + + # Sets the request context metadata for the given `key`. Request metadata + # useful for handlers that need to keep state on the request, without + # sending that data with the request over HTTP. + # + # @param key [Symbol] + # @param value [Object] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#72 + def []=(key, value); end + + # @return [Model::Authorizer] APIG SDKs only + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#37 + def authorizer; end + + # @return [Model::Authorizer] APIG SDKs only + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#37 + def authorizer=(_arg0); end + + # @return [Seahorse::Client::Base] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#40 + def client; end + + # @return [Seahorse::Client::Base] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#40 + def client=(_arg0); end + + # @return [Configuration] The client configuration. + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#46 + def config; end + + # @return [Configuration] The client configuration. + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#46 + def config=(_arg0); end + + # @return [Http::Request] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#49 + def http_request; end + + # @return [Http::Request] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#49 + def http_request=(_arg0); end + + # @return [Http::Response] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#52 + def http_response; end + + # @return [Http::Response] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#52 + def http_response=(_arg0); end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#58 + def metadata; end + + # @return [Model::Operation] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#34 + def operation; end + + # @return [Model::Operation] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#34 + def operation=(_arg0); end + + # @return [Symbol] Name of the API operation called. + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#31 + def operation_name; end + + # @return [Symbol] Name of the API operation called. + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#31 + def operation_name=(_arg0); end + + # @return [Hash] The hash of request parameters. + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#43 + def params; end + + # @return [Hash] The hash of request parameters. + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#43 + def params=(_arg0); end + + # @return [Integer] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#55 + def retries; end + + # @return [Integer] + # + # source://aws-sdk-core//lib/seahorse/client/request_context.rb#55 + def retries=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/client/response.rb#7 +class Seahorse::Client::Response + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Response] a new instance of Response + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#12 + def initialize(options = T.unsafe(nil)); end + + # Necessary to define as a subclass of Delegator + # + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#77 + def __getobj__; end + + # Necessary to define as a subclass of Delegator + # + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#83 + def __setobj__(obj); end + + # @return [String, nil] returns the algorithm used to validate + # the response checksum. Returns nil if no verification was done. + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#35 + def checksum_validated; end + + # @return [RequestContext] + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#24 + def context; end + + # @return The response data. This may be `nil` if the response contains + # an {#error}. + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#28 + def data; end + + # @return The response data. This may be `nil` if the response contains + # an {#error}. + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#28 + def data=(_arg0); end + + # @return [StandardError, nil] + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#31 + def error; end + + # @return [StandardError, nil] + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#31 + def error=(_arg0); end + + # @overload on + # @overload on + # @return [self] + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#49 + def on(range, &_block); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#70 + def on_complete(&block); end + + # Yields to the block if the response has a 200 level status code. + # + # @return [self] + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#59 + def on_success(&block); end + + # @return [Boolean] Returns `true` if the response is complete with + # a ~ 200 level http status code. + # + # source://aws-sdk-core//lib/seahorse/client/response.rb#65 + def successful?; end +end + +# source://aws-sdk-core//lib/seahorse/model/api.rb#4 +module Seahorse::Model; end + +# source://aws-sdk-core//lib/seahorse/model/api.rb#5 +class Seahorse::Model::Api + # @return [Api] a new instance of Api + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#7 + def initialize; end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#75 + def add_authorizer(name, authorizer); end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#51 + def add_operation(name, operation); end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#47 + def async_operation_names; end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#63 + def authorizer(name); end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#71 + def authorizer_names; end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#55 + def authorizers(&block); end + + # @return [Symbol|nil] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#22 + def endpoint_operation; end + + # @return [Symbol|nil] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#22 + def endpoint_operation=(_arg0); end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#79 + def inspect(*args); end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#19 + def metadata; end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#19 + def metadata=(_arg0); end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#35 + def operation(name); end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#43 + def operation_names; end + + # source://aws-sdk-core//lib/seahorse/model/api.rb#27 + def operations(&block); end + + # @return [Boolean|nil] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#25 + def require_endpoint_discovery; end + + # @return [Boolean|nil] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#25 + def require_endpoint_discovery=(_arg0); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#16 + def version; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/api.rb#16 + def version=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/authorizer.rb#5 +class Seahorse::Model::Authorizer + # @return [Authorizer] a new instance of Authorizer + # + # source://aws-sdk-core//lib/seahorse/model/authorizer.rb#7 + def initialize; end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/authorizer.rb#13 + def name; end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/authorizer.rb#13 + def name=(_arg0); end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/authorizer.rb#19 + def placement; end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/authorizer.rb#19 + def placement=(_arg0); end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/authorizer.rb#16 + def type; end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/authorizer.rb#16 + def type=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/operation.rb#5 +class Seahorse::Model::Operation + # @return [Operation] a new instance of Operation + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#7 + def initialize; end + + # source://aws-sdk-core//lib/seahorse/model/operation.rb#68 + def [](key); end + + # source://aws-sdk-core//lib/seahorse/model/operation.rb#72 + def []=(key, value); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#66 + def async; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#66 + def async=(_arg0); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#50 + def authorizer; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#50 + def authorizer=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#35 + def deprecated; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#35 + def deprecated=(_arg0); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#44 + def documentation; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#44 + def documentation=(_arg0); end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#41 + def endpoint_discovery; end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#41 + def endpoint_discovery=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#38 + def endpoint_operation; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#38 + def endpoint_operation=(_arg0); end + + # @return [Hash, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#47 + def endpoint_pattern; end + + # @return [Hash, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#47 + def endpoint_pattern=(_arg0); end + + # @return [Array] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#59 + def errors; end + + # @return [Array] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#59 + def errors=(_arg0); end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#29 + def http_checksum; end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#29 + def http_checksum=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#26 + def http_checksum_required; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#26 + def http_checksum_required=(_arg0); end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#20 + def http_method; end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#20 + def http_method=(_arg0); end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#23 + def http_request_uri; end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#23 + def http_request_uri=(_arg0); end + + # @return [ShapeRef, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#53 + def input; end + + # @return [ShapeRef, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#53 + def input=(_arg0); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#17 + def name; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#17 + def name=(_arg0); end + + # @return [ShapeRef, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#56 + def output; end + + # @return [ShapeRef, nil] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#56 + def output=(_arg0); end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#32 + def request_compression; end + + # @return [Hash] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#32 + def request_compression=(_arg0); end + + # APIG only + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#63 + def require_apikey; end + + # APIG only + # + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/operation.rb#63 + def require_apikey=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#7 +module Seahorse::Model::Shapes; end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#135 +class Seahorse::Model::Shapes::BlobShape < ::Seahorse::Model::Shapes::Shape + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#141 + def max; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#141 + def max=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#138 + def min; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#138 + def min=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#145 +class Seahorse::Model::Shapes::BooleanShape < ::Seahorse::Model::Shapes::Shape; end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#292 +class Seahorse::Model::Shapes::DocumentShape < ::Seahorse::Model::Shapes::Shape; end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#147 +class Seahorse::Model::Shapes::FloatShape < ::Seahorse::Model::Shapes::Shape + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#153 + def max; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#153 + def max=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#150 + def min; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#150 + def min=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#157 +class Seahorse::Model::Shapes::IntegerShape < ::Seahorse::Model::Shapes::Shape + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#163 + def max; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#163 + def max=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#160 + def min; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#160 + def min=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#167 +class Seahorse::Model::Shapes::ListShape < ::Seahorse::Model::Shapes::Shape + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#179 + def flattened; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#179 + def flattened=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#176 + def max; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#176 + def max=(_arg0); end + + # @return [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#170 + def member; end + + # @return [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#170 + def member=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#173 + def min; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#173 + def min=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#183 +class Seahorse::Model::Shapes::MapShape < ::Seahorse::Model::Shapes::Shape + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#198 + def flattened; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#198 + def flattened=(_arg0); end + + # @return [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#186 + def key; end + + # @return [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#186 + def key=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#195 + def max; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#195 + def max=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#192 + def min; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#192 + def min=(_arg0); end + + # @return [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#189 + def value; end + + # @return [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#189 + def value=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#101 +class Seahorse::Model::Shapes::Shape + # @return [Shape] a new instance of Shape + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#103 + def initialize(options = T.unsafe(nil)); end + + # Gets metadata for the given `key`. + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#124 + def [](key); end + + # Sets metadata for the given `key`. + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#129 + def []=(key, value); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#118 + def documentation; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#118 + def documentation=(_arg0); end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#115 + def name; end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#115 + def name=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#121 + def union; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#121 + def union=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#9 +class Seahorse::Model::Shapes::ShapeRef + # @return [ShapeRef] a new instance of ShapeRef + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#11 + def initialize(options = T.unsafe(nil)); end + + # Gets metadata for the given `key`. + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#86 + def [](key); end + + # Sets metadata for the given `key`. + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#95 + def []=(key, value); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#44 + def deprecated; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#44 + def deprecated=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#65 + def document; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#65 + def document=(_arg0); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#41 + def documentation; end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#41 + def documentation=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#47 + def event; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#47 + def event=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#56 + def eventheader; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#56 + def eventheader=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#62 + def eventheader_type; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#62 + def eventheader_type=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#53 + def eventpayload; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#53 + def eventpayload=(_arg0); end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#59 + def eventpayload_type; end + + # @return [String] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#59 + def eventpayload_type=(_arg0); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#50 + def eventstream; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#50 + def eventstream=(_arg0); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#68 + def location; end + + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#72 + def location=(location); end + + # @return [String, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#77 + def location_name; end + + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#81 + def location_name=(location_name); end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#38 + def required; end + + # @return [Boolean] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#38 + def required=(_arg0); end + + # @return [Shape] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#35 + def shape; end + + # @return [Shape] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#35 + def shape=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#202 +class Seahorse::Model::Shapes::StringShape < ::Seahorse::Model::Shapes::Shape + # @return [Set, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#205 + def enum; end + + # @return [Set, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#205 + def enum=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#211 + def max; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#211 + def max=(_arg0); end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#208 + def min; end + + # @return [Integer, nil] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#208 + def min=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#215 +class Seahorse::Model::Shapes::StructureShape < ::Seahorse::Model::Shapes::Shape + # @return [StructureShape] a new instance of StructureShape + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#217 + def initialize(options = T.unsafe(nil)); end + + # @param name [Symbol] + # @param shape_ref [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#232 + def add_member(name, shape_ref); end + + # @param name [Symbol] + # @return [ShapeRef] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#258 + def member(name); end + + # @param member_name [Symbol] + # @return [Boolean] Returns `true` if there exists a member with + # the given name. + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#247 + def member?(member_name); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#267 + def member_by_location_name(location_name); end + + # @return [Array] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#240 + def member_names; end + + # @return [Enumerator<[Symbol,ShapeRef]>] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#252 + def members; end + + # @return [Set] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#225 + def required; end + + # @return [Set] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#225 + def required=(_arg0); end + + # @return [Class] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#228 + def struct_class; end + + # @return [Class] + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#228 + def struct_class=(_arg0); end +end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#290 +class Seahorse::Model::Shapes::TimestampShape < ::Seahorse::Model::Shapes::Shape; end + +# source://aws-sdk-core//lib/seahorse/model/shapes.rb#273 +class Seahorse::Model::Shapes::UnionShape < ::Seahorse::Model::Shapes::StructureShape + # @return [UnionShape] a new instance of UnionShape + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#274 + def initialize(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#285 + def add_member_subclass(member, subclass); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/model/shapes.rb#280 + def member_subclass(member); end +end + +# @api private +# +# source://aws-sdk-core//lib/seahorse/util.rb#7 +module Seahorse::Util + class << self + # @api private + # + # source://aws-sdk-core//lib/seahorse/util.rb#17 + def escape_header_list_string(s); end + + # Checks for a valid host label + # + # @api private + # @return [Boolean] + # @see https://tools.ietf.org/html/rfc3986#section-3.2.2 + # @see https://tools.ietf.org/html/rfc1123#page-13 + # + # source://aws-sdk-core//lib/seahorse/util.rb#24 + def host_label?(str); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/util.rb#9 + def uri_escape(string); end + + # @api private + # + # source://aws-sdk-core//lib/seahorse/util.rb#13 + def uri_path_escape(path); end + end +end diff --git a/sorbet/rbi/gems/aws-sdk-kms@1.88.0.rbi b/sorbet/rbi/gems/aws-sdk-kms@1.88.0.rbi new file mode 100644 index 000000000..a46d37cc7 --- /dev/null +++ b/sorbet/rbi/gems/aws-sdk-kms@1.88.0.rbi @@ -0,0 +1,11712 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `aws-sdk-kms` gem. +# Please instead update this file by running `bin/tapioca gem aws-sdk-kms`. + + +# This module provides support for AWS Key Management Service. This module is available in the +# `aws-sdk-kms` gem. +# +# # Client +# +# The {Client} class provides one method for each API operation. Operation +# methods each accept a hash of request parameters and return a response +# structure. +# +# kms = Aws::KMS::Client.new +# resp = kms.cancel_key_deletion(params) +# +# See {Client} for more information. +# +# # Errors +# +# Errors returned from AWS Key Management Service are defined in the +# {Errors} module and all extend {Errors::ServiceError}. +# +# begin +# # do stuff +# rescue Aws::KMS::Errors::ServiceError +# # rescues all AWS Key Management Service API errors +# end +# +# See {Errors} for more information. +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#10 +module Aws::KMS; end + +# An API client for KMS. To construct a client, you need to configure a `:region` and `:credentials`. +# +# client = Aws::KMS::Client.new( +# region: region_name, +# credentials: credentials, +# # ... +# ) +# +# For details on configuring region and credentials see +# the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html). +# +# See {#initialize} for a full list of supported configuration options. +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#53 +class Aws::KMS::Client < ::Seahorse::Client::Base + include ::Aws::ClientStubs + + # @overload initialize + # @return [Client] a new instance of Client + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#429 + def initialize(*args); end + + # @api private + # @param params [{}] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10749 + def build_request(operation_name, params = T.unsafe(nil)); end + + # Cancels the deletion of a KMS key. When this operation succeeds, the + # key state of the KMS key is `Disabled`. To enable the KMS key, use + # EnableKey. + # + # For more information about scheduling and canceling deletion of a KMS + # key, see [Deleting KMS keys][1] in the *Key Management Service + # Developer Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][2] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:CancelKeyDeletion][3] (key policy) + # + # **Related operations**: ScheduleKeyDeletion + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/deleting-keys.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To cancel deletion of a KMS key + # + # # The following example cancels deletion of the specified KMS key. + # + # resp = client.cancel_key_deletion({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose deletion you are canceling. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key whose deletion you canceled. + # } + # @example Request syntax with placeholder values + # + # resp = client.cancel_key_deletion({ + # key_id: "KeyIdType", # required + # }) + # @example Response structure + # + # resp.key_id #=> String + # @option params + # @overload cancel_key_deletion + # @param params [Hash] ({}) + # @return [Types::CancelKeyDeletionResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CancelKeyDeletionResponse#key_id #key_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CancelKeyDeletion AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#511 + def cancel_key_deletion(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Connects or reconnects a [custom key store][1] to its backing key + # store. For an CloudHSM key store, `ConnectCustomKeyStore` connects the + # key store to its associated CloudHSM cluster. For an external key + # store, `ConnectCustomKeyStore` connects the key store to the external + # key store proxy that communicates with your external key manager. + # + # The custom key store must be connected before you can create KMS keys + # in the key store or use the KMS keys it contains. You can disconnect + # and reconnect a custom key store at any time. + # + # The connection process for a custom key store can take an extended + # amount of time to complete. This operation starts the connection + # process, but it does not wait for it to complete. When it succeeds, + # this operation quickly returns an HTTP 200 response and a JSON object + # with no properties. However, this response does not indicate that the + # custom key store is connected. To get the connection state of the + # custom key store, use the DescribeCustomKeyStores operation. + # + # This operation is part of the [custom key stores][1] feature in KMS, + # which combines the convenience and extensive integration of KMS with + # the isolation and control of a key store that you own and manage. + # + # The `ConnectCustomKeyStore` operation might fail for various reasons. + # To find the reason, use the DescribeCustomKeyStores operation and see + # the `ConnectionErrorCode` in the response. For help interpreting the + # `ConnectionErrorCode`, see CustomKeyStoresListEntry. + # + # To fix the failure, use the DisconnectCustomKeyStore operation to + # disconnect the custom key store, correct the error, use the + # UpdateCustomKeyStore operation if necessary, and then use + # `ConnectCustomKeyStore` again. + # + # **CloudHSM key store** + # + # During the connection process for an CloudHSM key store, KMS finds the + # CloudHSM cluster that is associated with the custom key store, creates + # the connection infrastructure, connects to the cluster, logs into the + # CloudHSM client as the `kmsuser` CU, and rotates its password. + # + # To connect an CloudHSM key store, its associated CloudHSM cluster must + # have at least one active HSM. To get the number of active HSMs in a + # cluster, use the [DescribeClusters][2] operation. To add HSMs to the + # cluster, use the [CreateHsm][3] operation. Also, the [ `kmsuser` + # crypto user][4] (CU) must not be logged into the cluster. This + # prevents KMS from using this account to log in. + # + # If you are having trouble connecting or disconnecting a CloudHSM key + # store, see [Troubleshooting an CloudHSM key store][5] in the *Key + # Management Service Developer Guide*. + # + # **External key store** + # + # When you connect an external key store that uses public endpoint + # connectivity, KMS tests its ability to communicate with your external + # key manager by sending a request via the external key store proxy. + # + # When you connect to an external key store that uses VPC endpoint + # service connectivity, KMS establishes the networking elements that it + # needs to communicate with your external key manager via the external + # key store proxy. This includes creating an interface endpoint to the + # VPC endpoint service and a private hosted zone for traffic between KMS + # and the VPC endpoint service. + # + # To connect an external key store, KMS must be able to connect to the + # external key store proxy, the external key store proxy must be able to + # communicate with your external key manager, and the external key + # manager must be available for cryptographic operations. + # + # If you are having trouble connecting or disconnecting an external key + # store, see [Troubleshooting an external key store][6] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a + # custom key store in a different Amazon Web Services account. + # + # **Required permissions**: [kms:ConnectCustomKeyStore][7] (IAM policy) + # + # **Related operations** + # + # * CreateCustomKeyStore + # + # * DeleteCustomKeyStore + # + # * DescribeCustomKeyStores + # + # * DisconnectCustomKeyStore + # + # * UpdateCustomKeyStore + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][8]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [2]: https://docs.aws.amazon.com/cloudhsm/latest/APIReference/API_DescribeClusters.html + # [3]: https://docs.aws.amazon.com/cloudhsm/latest/APIReference/API_CreateHsm.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-store-concepts.html#concept-kmsuser + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/xks-troubleshooting.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To connect a custom key store + # + # # This example connects an AWS KMS custom key store to its backing key store. For an AWS CloudHSM key store, it connects + # # the key store to its AWS CloudHSM cluster. For an external key store, it connects the key store to the external key + # # store proxy that communicates with your external key manager. This operation does not return any data. To verify that + # # the custom key store is connected, use the DescribeCustomKeyStores operation. + # + # resp = client.connect_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the AWS KMS custom key store. + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.connect_custom_key_store({ + # custom_key_store_id: "CustomKeyStoreIdType", # required + # }) + # @option params + # @overload connect_custom_key_store + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ConnectCustomKeyStore AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#652 + def connect_custom_key_store(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Creates a friendly name for a KMS key. + # + # Adding, deleting, or updating an alias can allow or deny permission to + # the KMS key. For details, see [ABAC for KMS][1] in the *Key Management + # Service Developer Guide*. + # + # + # + # You can use an alias to identify a KMS key in the KMS console, in the + # DescribeKey operation and in [cryptographic operations][2], such as + # Encrypt and GenerateDataKey. You can also change the KMS key that's + # associated with the alias (UpdateAlias) or delete the alias + # (DeleteAlias) at any time. These operations don't affect the + # underlying KMS key. + # + # You can associate the alias with any customer managed key in the same + # Amazon Web Services Region. Each alias is associated with only one KMS + # key at a time, but a KMS key can have multiple aliases. A valid KMS + # key is required. You can't create an alias without a KMS key. + # + # The alias must be unique in the account and Region, but you can have + # aliases with the same name in different Regions. For detailed + # information about aliases, see [Using aliases][3] in the *Key + # Management Service Developer Guide*. + # + # This operation does not return a response. To get the alias that you + # created, use the ListAliases operation. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][4] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on an + # alias in a different Amazon Web Services account. + # + # **Required permissions** + # + # * [kms:CreateAlias][5] on the alias (IAM policy). + # + # * [kms:CreateAlias][5] on the KMS key (key policy). + # + # For details, see [Controlling access to aliases][6] in the *Key + # Management Service Developer Guide*. + # + # **Related operations:** + # + # * DeleteAlias + # + # * ListAliases + # + # * UpdateAlias + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][7]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/abac.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To create an alias + # + # # The following example creates an alias for the specified KMS key. + # + # resp = client.create_alias({ + # alias_name: "alias/ExampleAlias", # The alias to create. Aliases must begin with 'alias/'. Do not use aliases that begin with 'alias/aws' because they are reserved for use by AWS. + # target_key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose alias you are creating. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.create_alias({ + # alias_name: "AliasNameType", # required + # target_key_id: "KeyIdType", # required + # }) + # @option params + # @option params + # @overload create_alias + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateAlias AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#790 + def create_alias(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Creates a [custom key store][1] backed by a key store that you own and + # manage. When you use a KMS key in a custom key store for a + # cryptographic operation, the cryptographic operation is actually + # performed in your key store using your keys. KMS supports [CloudHSM + # key stores][2] backed by an [CloudHSM cluster][3] and [external key + # stores][4] backed by an external key store proxy and external key + # manager outside of Amazon Web Services. + # + # This operation is part of the [custom key stores][1] feature in KMS, + # which combines the convenience and extensive integration of KMS with + # the isolation and control of a key store that you own and manage. + # + # Before you create the custom key store, the required elements must be + # in place and operational. We recommend that you use the test tools + # that KMS provides to verify the configuration your external key store + # proxy. For details about the required elements and verification tests, + # see [Assemble the prerequisites (for CloudHSM key stores)][5] or + # [Assemble the prerequisites (for external key stores)][6] in the *Key + # Management Service Developer Guide*. + # + # To create a custom key store, use the following parameters. + # + # * To create an CloudHSM key store, specify the `CustomKeyStoreName`, + # `CloudHsmClusterId`, `KeyStorePassword`, and + # `TrustAnchorCertificate`. The `CustomKeyStoreType` parameter is + # optional for CloudHSM key stores. If you include it, set it to the + # default value, `AWS_CLOUDHSM`. For help with failures, see + # [Troubleshooting an CloudHSM key store][7] in the *Key Management + # Service Developer Guide*. + # + # * To create an external key store, specify the `CustomKeyStoreName` + # and a `CustomKeyStoreType` of `EXTERNAL_KEY_STORE`. Also, specify + # values for `XksProxyConnectivity`, + # `XksProxyAuthenticationCredential`, `XksProxyUriEndpoint`, and + # `XksProxyUriPath`. If your `XksProxyConnectivity` value is + # `VPC_ENDPOINT_SERVICE`, specify the `XksProxyVpcEndpointServiceName` + # parameter. For help with failures, see [Troubleshooting an external + # key store][8] in the *Key Management Service Developer Guide*. + # + # For external key stores: + # + # Some external key managers provide a simpler method for creating an + # external key store. For details, see your external key manager + # documentation. + # + # When creating an external key store in the KMS console, you can upload + # a JSON-based proxy configuration file with the desired values. You + # cannot use a proxy configuration with the `CreateCustomKeyStore` + # operation. However, you can use the values in the file to help you + # determine the correct values for the `CreateCustomKeyStore` + # parameters. + # + # + # + # When the operation completes successfully, it returns the ID of the + # new custom key store. Before you can use your new custom key store, + # you need to use the ConnectCustomKeyStore operation to connect a new + # CloudHSM key store to its CloudHSM cluster, or to connect a new + # external key store to the external key store proxy for your external + # key manager. Even if you are not going to use your custom key store + # immediately, you might want to connect it to verify that all settings + # are correct and then disconnect it until you are ready to use it. + # + # For help with failures, see [Troubleshooting a custom key store][7] in + # the *Key Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a + # custom key store in a different Amazon Web Services account. + # + # **Required permissions**: [kms:CreateCustomKeyStore][9] (IAM policy). + # + # **Related operations:** + # + # * ConnectCustomKeyStore + # + # * DeleteCustomKeyStore + # + # * DescribeCustomKeyStores + # + # * DisconnectCustomKeyStore + # + # * UpdateCustomKeyStore + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][10]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/keystore-cloudhsm.html + # [3]: https://docs.aws.amazon.com/cloudhsm/latest/userguide/clusters.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/keystore-external.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/create-keystore.html#before-keystore + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/create-xks-keystore.html#xks-requirements + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/xks-troubleshooting.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To create an AWS CloudHSM key store + # + # # This example creates a custom key store that is associated with an AWS CloudHSM cluster. + # + # resp = client.create_custom_key_store({ + # cloud_hsm_cluster_id: "cluster-234abcdefABC", # The ID of the CloudHSM cluster. + # custom_key_store_name: "ExampleKeyStore", # A friendly name for the custom key store. + # key_store_password: "kmsPswd", # The password for the kmsuser CU account in the specified cluster. + # trust_anchor_certificate: "", # The content of the customerCA.crt file that you created when you initialized the cluster. + # }) + # + # resp.to_h outputs the following: + # { + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the new custom key store. + # } + # @example Example: To create an external key store with VPC endpoint service connectivity + # + # # This example creates an external key store that uses an Amazon VPC endpoint service to communicate with AWS KMS. + # + # resp = client.create_custom_key_store({ + # custom_key_store_name: "ExampleVPCEndpointKeyStore", # A friendly name for the custom key store + # custom_key_store_type: "EXTERNAL_KEY_STORE", # For external key stores, the value must be EXTERNAL_KEY_STORE + # xks_proxy_authentication_credential: { + # access_key_id: "ABCDE12345670EXAMPLE", + # raw_secret_access_key: "DXjSUawnel2fr6SKC7G25CNxTyWKE5PF9XX6H/u9pSo=", + # }, # The access key ID and secret access key that KMS uses to authenticate to your external key store proxy + # xks_proxy_connectivity: "VPC_ENDPOINT_SERVICE", # Indicates how AWS KMS communicates with the external key store proxy + # xks_proxy_uri_endpoint: "https://myproxy-private.xks.example.com", # The URI that AWS KMS uses to connect to the external key store proxy + # xks_proxy_uri_path: "/example-prefix/kms/xks/v1", # The URI path to the external key store proxy APIs + # xks_proxy_vpc_endpoint_service_name: "com.amazonaws.vpce.us-east-1.vpce-svc-example1", # The VPC endpoint service that KMS uses to communicate with the external key store proxy + # }) + # + # resp.to_h outputs the following: + # { + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the new custom key store. + # } + # @example Example: To create an external key store with public endpoint connectivity + # + # # This example creates an external key store with public endpoint connectivity. + # + # resp = client.create_custom_key_store({ + # custom_key_store_name: "ExamplePublicEndpointKeyStore", # A friendly name for the custom key store + # custom_key_store_type: "EXTERNAL_KEY_STORE", # For external key stores, the value must be EXTERNAL_KEY_STORE + # xks_proxy_authentication_credential: { + # access_key_id: "ABCDE12345670EXAMPLE", + # raw_secret_access_key: "DXjSUawnel2fr6SKC7G25CNxTyWKE5PF9XX6H/u9pSo=", + # }, # The access key ID and secret access key that KMS uses to authenticate to your external key store proxy + # xks_proxy_connectivity: "PUBLIC_ENDPOINT", # Indicates how AWS KMS communicates with the external key store proxy + # xks_proxy_uri_endpoint: "https://myproxy.xks.example.com", # The URI that AWS KMS uses to connect to the external key store proxy + # xks_proxy_uri_path: "/kms/xks/v1", # The URI path to your external key store proxy API + # }) + # + # resp.to_h outputs the following: + # { + # custom_key_store_id: "cks-987654321abcdef0", # The ID of the new custom key store. + # } + # @example Request syntax with placeholder values + # + # resp = client.create_custom_key_store({ + # custom_key_store_name: "CustomKeyStoreNameType", # required + # cloud_hsm_cluster_id: "CloudHsmClusterIdType", + # trust_anchor_certificate: "TrustAnchorCertificateType", + # key_store_password: "KeyStorePasswordType", + # custom_key_store_type: "AWS_CLOUDHSM", # accepts AWS_CLOUDHSM, EXTERNAL_KEY_STORE + # xks_proxy_uri_endpoint: "XksProxyUriEndpointType", + # xks_proxy_uri_path: "XksProxyUriPathType", + # xks_proxy_vpc_endpoint_service_name: "XksProxyVpcEndpointServiceNameType", + # xks_proxy_authentication_credential: { + # access_key_id: "XksProxyAuthenticationAccessKeyIdType", # required + # raw_secret_access_key: "XksProxyAuthenticationRawSecretAccessKeyType", # required + # }, + # xks_proxy_connectivity: "PUBLIC_ENDPOINT", # accepts PUBLIC_ENDPOINT, VPC_ENDPOINT_SERVICE + # }) + # @example Response structure + # + # resp.custom_key_store_id #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload create_custom_key_store + # @param params [Hash] ({}) + # @return [Types::CreateCustomKeyStoreResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateCustomKeyStoreResponse#custom_key_store_id #custom_key_store_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateCustomKeyStore AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#1179 + def create_custom_key_store(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Adds a grant to a KMS key. + # + # A *grant* is a policy instrument that allows Amazon Web Services + # principals to use KMS keys in cryptographic operations. It also can + # allow them to view a KMS key (DescribeKey) and create and manage + # grants. When authorizing access to a KMS key, grants are considered + # along with key policies and IAM policies. Grants are often used for + # temporary permissions because you can create one, use its permissions, + # and delete it without changing your key policies or IAM policies. + # + # For detailed information about grants, including grant terminology, + # see [Grants in KMS][1] in the Key Management Service Developer + # Guide . For examples of working with grants in several + # programming languages, see [Programming grants][2]. + # + # The `CreateGrant` operation returns a `GrantToken` and a `GrantId`. + # + # * When you create, retire, or revoke a grant, there might be a brief + # delay, usually less than five minutes, until the grant is available + # throughout KMS. This state is known as *eventual consistency*. Once + # the grant has achieved eventual consistency, the grantee principal + # can use the permissions in the grant without identifying the grant. + # + # However, to use the permissions in the grant immediately, use the + # `GrantToken` that `CreateGrant` returns. For details, see [Using a + # grant token][3] in the Key Management Service Developer + # Guide . + # + # * The `CreateGrant` operation also returns a `GrantId`. You can use + # the `GrantId` and a key identifier to identify the grant in the + # RetireGrant and RevokeGrant operations. To find the grant ID, use + # the ListGrants or ListRetirableGrants operations. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][4] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation on a KMS key in + # a different Amazon Web Services account, specify the key ARN in the + # value of the `KeyId` parameter. + # + # **Required permissions**: [kms:CreateGrant][5] (key policy) + # + # **Related operations:** + # + # * ListGrants + # + # * ListRetirableGrants + # + # * RetireGrant + # + # * RevokeGrant + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][6]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-grants.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/grant-manage.html#using-grant-token + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To create a grant + # + # # The following example creates a grant that allows the specified IAM role to encrypt data with the specified KMS key. + # + # resp = client.create_grant({ + # grantee_principal: "arn:aws:iam::111122223333:role/ExampleRole", # The identity that is given permission to perform the operations specified in the grant. + # key_id: "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to which the grant applies. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # operations: [ + # "Encrypt", + # "Decrypt", + # ], # A list of operations that the grant allows. + # }) + # + # resp.to_h outputs the following: + # { + # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60", # The unique identifier of the grant. + # grant_token: "AQpAM2RhZTk1MGMyNTk2ZmZmMzEyYWVhOWViN2I1MWM4Mzc0MWFiYjc0ZDE1ODkyNGFlNTIzODZhMzgyZjBlNGY3NiKIAgEBAgB4Pa6VDCWW__MSrqnre1HIN0Grt00ViSSuUjhqOC8OT3YAAADfMIHcBgkqhkiG9w0BBwaggc4wgcsCAQAwgcUGCSqGSIb3DQEHATAeBglghkgBZQMEAS4wEQQMmqLyBTAegIn9XlK5AgEQgIGXZQjkBcl1dykDdqZBUQ6L1OfUivQy7JVYO2-ZJP7m6f1g8GzV47HX5phdtONAP7K_HQIflcgpkoCqd_fUnE114mSmiagWkbQ5sqAVV3ov-VeqgrvMe5ZFEWLMSluvBAqdjHEdMIkHMlhlj4ENZbzBfo9Wxk8b8SnwP4kc4gGivedzFXo-dwN8fxjjq_ZZ9JFOj2ijIbj5FyogDCN0drOfi8RORSEuCEmPvjFRMFAwcmwFkN2NPp89amA", # The grant token. + # } + # @example Request syntax with placeholder values + # + # resp = client.create_grant({ + # key_id: "KeyIdType", # required + # grantee_principal: "PrincipalIdType", # required + # retiring_principal: "PrincipalIdType", + # operations: ["Decrypt"], # required, accepts Decrypt, Encrypt, GenerateDataKey, GenerateDataKeyWithoutPlaintext, ReEncryptFrom, ReEncryptTo, Sign, Verify, GetPublicKey, CreateGrant, RetireGrant, DescribeKey, GenerateDataKeyPair, GenerateDataKeyPairWithoutPlaintext, GenerateMac, VerifyMac, DeriveSharedSecret + # constraints: { + # encryption_context_subset: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # encryption_context_equals: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # }, + # grant_tokens: ["GrantTokenType"], + # name: "GrantNameType", + # dry_run: false, + # }) + # @example Response structure + # + # resp.grant_token #=> String + # resp.grant_id #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload create_grant + # @param params [Hash] ({}) + # @return [Types::CreateGrantResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateGrantResponse#grant_token #grant_token} => String + # * {Types::CreateGrantResponse#grant_id #grant_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateGrant AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#1456 + def create_grant(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Creates a unique customer managed [KMS key][1] in your Amazon Web + # Services account and Region. You can use a KMS key in cryptographic + # operations, such as encryption and signing. Some Amazon Web Services + # services let you use KMS keys that you create and manage to protect + # your service resources. + # + # A KMS key is a logical representation of a cryptographic key. In + # addition to the key material used in cryptographic operations, a KMS + # key includes metadata, such as the key ID, key policy, creation date, + # description, and key state. For details, see [Managing keys][2] in the + # *Key Management Service Developer Guide* + # + # Use the parameters of `CreateKey` to specify the type of KMS key, the + # source of its key material, its key policy, description, tags, and + # other properties. + # + # KMS has replaced the term *customer master key (CMK)* with *KMS key* + # and *KMS key*. The concept has not changed. To prevent breaking + # changes, KMS is keeping some variations of this term. + # + # + # + # To create different types of KMS keys, use the following guidance: + # + # Symmetric encryption KMS key + # + # : By default, `CreateKey` creates a symmetric encryption KMS key with + # key material that KMS generates. This is the basic and most widely + # used type of KMS key, and provides the best performance. + # + # To create a symmetric encryption KMS key, you don't need to specify + # any parameters. The default value for `KeySpec`, + # `SYMMETRIC_DEFAULT`, the default value for `KeyUsage`, + # `ENCRYPT_DECRYPT`, and the default value for `Origin`, `AWS_KMS`, + # create a symmetric encryption KMS key with KMS key material. + # + # If you need a key for basic encryption and decryption or you are + # creating a KMS key to protect your resources in an Amazon Web + # Services service, create a symmetric encryption KMS key. The key + # material in a symmetric encryption key never leaves KMS unencrypted. + # You can use a symmetric encryption KMS key to encrypt and decrypt + # data up to 4,096 bytes, but they are typically used to generate data + # keys and data keys pairs. For details, see GenerateDataKey and + # GenerateDataKeyPair. + # + # + # + # Asymmetric KMS keys + # + # : To create an asymmetric KMS key, use the `KeySpec` parameter to + # specify the type of key material in the KMS key. Then, use the + # `KeyUsage` parameter to determine whether the KMS key will be used + # to encrypt and decrypt or sign and verify. You can't change these + # properties after the KMS key is created. + # + # Asymmetric KMS keys contain an RSA key pair, Elliptic Curve (ECC) + # key pair, or an SM2 key pair (China Regions only). The private key + # in an asymmetric KMS key never leaves KMS unencrypted. However, you + # can use the GetPublicKey operation to download the public key so it + # can be used outside of KMS. Each KMS key can have only one key + # usage. KMS keys with RSA key pairs can be used to encrypt and + # decrypt data or sign and verify messages (but not both). KMS keys + # with NIST-recommended ECC key pairs can be used to sign and verify + # messages or derive shared secrets (but not both). KMS keys with + # `ECC_SECG_P256K1` can be used only to sign and verify messages. KMS + # keys with SM2 key pairs (China Regions only) can be used to either + # encrypt and decrypt data, sign and verify messages, or derive shared + # secrets (you must choose one key usage type). For information about + # asymmetric KMS keys, see [Asymmetric KMS keys][3] in the *Key + # Management Service Developer Guide*. + # + # + # + # HMAC KMS key + # + # : To create an HMAC KMS key, set the `KeySpec` parameter to a key spec + # value for HMAC KMS keys. Then set the `KeyUsage` parameter to + # `GENERATE_VERIFY_MAC`. You must set the key usage even though + # `GENERATE_VERIFY_MAC` is the only valid key usage value for HMAC KMS + # keys. You can't change these properties after the KMS key is + # created. + # + # HMAC KMS keys are symmetric keys that never leave KMS unencrypted. + # You can use HMAC keys to generate (GenerateMac) and verify + # (VerifyMac) HMAC codes for messages up to 4096 bytes. + # + # + # + # Multi-Region primary keys + # Imported key material + # + # : To create a multi-Region *primary key* in the local Amazon Web + # Services Region, use the `MultiRegion` parameter with a value of + # `True`. To create a multi-Region *replica key*, that is, a KMS key + # with the same key ID and key material as a primary key, but in a + # different Amazon Web Services Region, use the ReplicateKey + # operation. To change a replica key to a primary key, and its primary + # key to a replica key, use the UpdatePrimaryRegion operation. + # + # You can create multi-Region KMS keys for all supported KMS key + # types: symmetric encryption KMS keys, HMAC KMS keys, asymmetric + # encryption KMS keys, and asymmetric signing KMS keys. You can also + # create multi-Region keys with imported key material. However, you + # can't create multi-Region keys in a custom key store. + # + # This operation supports *multi-Region keys*, an KMS feature that + # lets you create multiple interoperable KMS keys in different Amazon + # Web Services Regions. Because these KMS keys have the same key ID, + # key material, and other metadata, you can use them interchangeably + # to encrypt data in one Amazon Web Services Region and decrypt it in + # a different Amazon Web Services Region without re-encrypting the + # data or making a cross-Region call. For more information about + # multi-Region keys, see [Multi-Region keys in KMS][4] in the *Key + # Management Service Developer Guide*. + # + # + # + # : To import your own key material into a KMS key, begin by creating a + # KMS key with no key material. To do this, use the `Origin` parameter + # of `CreateKey` with a value of `EXTERNAL`. Next, use + # GetParametersForImport operation to get a public key and import + # token. Use the wrapping public key to encrypt your key material. + # Then, use ImportKeyMaterial with your import token to import the key + # material. For step-by-step instructions, see [Importing Key + # Material][5] in the Key Management Service Developer + # Guide . + # + # You can import key material into KMS keys of all supported KMS key + # types: symmetric encryption KMS keys, HMAC KMS keys, asymmetric + # encryption KMS keys, and asymmetric signing KMS keys. You can also + # create multi-Region keys with imported key material. However, you + # can't import key material into a KMS key in a custom key store. + # + # To create a multi-Region primary key with imported key material, use + # the `Origin` parameter of `CreateKey` with a value of `EXTERNAL` and + # the `MultiRegion` parameter with a value of `True`. To create + # replicas of the multi-Region primary key, use the ReplicateKey + # operation. For instructions, see [Importing key material into + # multi-Region keys][6]. For more information about multi-Region keys, + # see [Multi-Region keys in KMS][4] in the *Key Management Service + # Developer Guide*. + # + # + # + # Custom key store + # + # : A [custom key store][7] lets you protect your Amazon Web Services + # resources using keys in a backing key store that you own and manage. + # When you request a cryptographic operation with a KMS key in a + # custom key store, the operation is performed in the backing key + # store using its cryptographic keys. + # + # KMS supports [CloudHSM key stores][8] backed by an CloudHSM cluster + # and [external key stores][9] backed by an external key manager + # outside of Amazon Web Services. When you create a KMS key in an + # CloudHSM key store, KMS generates an encryption key in the CloudHSM + # cluster and associates it with the KMS key. When you create a KMS + # key in an external key store, you specify an existing encryption key + # in the external key manager. + # + # Some external key managers provide a simpler method for creating a + # KMS key in an external key store. For details, see your external key + # manager documentation. + # + # + # + # Before you create a KMS key in a custom key store, the + # `ConnectionState` of the key store must be `CONNECTED`. To connect + # the custom key store, use the ConnectCustomKeyStore operation. To + # find the `ConnectionState`, use the DescribeCustomKeyStores + # operation. + # + # To create a KMS key in a custom key store, use the + # `CustomKeyStoreId`. Use the default `KeySpec` value, + # `SYMMETRIC_DEFAULT`, and the default `KeyUsage` value, + # `ENCRYPT_DECRYPT` to create a symmetric encryption key. No other key + # type is supported in a custom key store. + # + # To create a KMS key in an [CloudHSM key store][8], use the `Origin` + # parameter with a value of `AWS_CLOUDHSM`. The CloudHSM cluster that + # is associated with the custom key store must have at least two + # active HSMs in different Availability Zones in the Amazon Web + # Services Region. + # + # To create a KMS key in an [external key store][9], use the `Origin` + # parameter with a value of `EXTERNAL_KEY_STORE` and an `XksKeyId` + # parameter that identifies an existing external key. + # + # Some external key managers provide a simpler method for creating a + # KMS key in an external key store. For details, see your external key + # manager documentation. + # + # + # + # **Cross-account use**: No. You cannot use this operation to create a + # KMS key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:CreateKey][10] (IAM policy). To use the + # `Tags` parameter, [kms:TagResource][10] (IAM policy). For examples and + # information about related permissions, see [Allow a user to create KMS + # keys][11] in the *Key Management Service Developer Guide*. + # + # **Related operations:** + # + # * DescribeKey + # + # * ListKeys + # + # * ScheduleKeyDeletion + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][12]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#kms-keys + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/getting-started.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-import.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/keystore-cloudhsm.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/keystore-external.html + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/iam-policies.html#iam-policy-example-create-key + # [12]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To create a KMS key + # + # # The following example creates a symmetric KMS key for encryption and decryption. No parameters are required for this + # # operation. + # + # resp = client.create_key({ + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse("2017-07-05T14:04:55-07:00"), + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "AWS_KMS", + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Example: To create an asymmetric RSA KMS key for encryption and decryption + # + # # This example creates a KMS key that contains an asymmetric RSA key pair for encryption and decryption. The key spec and + # # key usage can't be changed after the key is created. + # + # resp = client.create_key({ + # key_spec: "RSA_4096", # Describes the type of key material in the KMS key. + # key_usage: "ENCRYPT_DECRYPT", # The cryptographic operations for which you can use the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse("2021-04-05T14:04:55-07:00"), + # customer_master_key_spec: "RSA_4096", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "RSAES_OAEP_SHA_1", + # "RSAES_OAEP_SHA_256", + # ], + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "RSA_4096", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "AWS_KMS", + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Example: To create an asymmetric elliptic curve KMS key for signing and verification + # + # # This example creates a KMS key that contains an asymmetric elliptic curve (ECC) key pair for signing and verification. + # # The key usage is required even though "SIGN_VERIFY" is the only valid value for ECC KMS keys. The key spec and key usage + # # can't be changed after the key is created. + # + # resp = client.create_key({ + # key_spec: "ECC_NIST_P521", # Describes the type of key material in the KMS key. + # key_usage: "SIGN_VERIFY", # The cryptographic operations for which you can use the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse("2019-12-02T07:48:55-07:00"), + # customer_master_key_spec: "ECC_NIST_P521", + # description: "", + # enabled: true, + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "ECC_NIST_P521", + # key_state: "Enabled", + # key_usage: "SIGN_VERIFY", + # multi_region: false, + # origin: "AWS_KMS", + # signing_algorithms: [ + # "ECDSA_SHA_512", + # ], + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Example: To create an HMAC KMS key + # + # # This example creates a 384-bit symmetric HMAC KMS key. The GENERATE_VERIFY_MAC key usage value is required even though + # # it's the only valid value for HMAC KMS keys. The key spec and key usage can't be changed after the key is created. + # + # resp = client.create_key({ + # key_spec: "HMAC_384", # Describes the type of key material in the KMS key. + # key_usage: "GENERATE_VERIFY_MAC", # The cryptographic operations for which you can use the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse("2022-04-05T14:04:55-07:00"), + # customer_master_key_spec: "HMAC_384", + # description: "", + # enabled: true, + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "HMAC_384", + # key_state: "Enabled", + # key_usage: "GENERATE_VERIFY_MAC", + # mac_algorithms: [ + # "HMAC_SHA_384", + # ], + # multi_region: false, + # origin: "AWS_KMS", + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Example: To create a multi-Region primary KMS key + # + # # This example creates a multi-Region primary symmetric encryption key. Because the default values for all parameters + # # create a symmetric encryption key, only the MultiRegion parameter is required for this KMS key. + # + # resp = client.create_key({ + # multi_region: true, # Indicates whether the KMS key is a multi-Region (True) or regional (False) key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-west-2:111122223333:key/mrk-1234abcd12ab34cd56ef12345678990ab", + # creation_date: Time.parse("2021-09-02T016:15:21-09:00"), + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "mrk-1234abcd12ab34cd56ef12345678990ab", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: true, + # multi_region_configuration: { + # multi_region_key_type: "PRIMARY", + # primary_key: { + # arn: "arn:aws:kms:us-west-2:111122223333:key/mrk-1234abcd12ab34cd56ef12345678990ab", + # region: "us-west-2", + # }, + # replica_keys: [ + # ], + # }, + # origin: "AWS_KMS", + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Example: To create a KMS key for imported key material + # + # # This example creates a symmetric KMS key with no key material. When the operation is complete, you can import your own + # # key material into the KMS key. To create this KMS key, set the Origin parameter to EXTERNAL. + # + # resp = client.create_key({ + # origin: "EXTERNAL", # The source of the key material for the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse("2019-12-02T07:48:55-07:00"), + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: false, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "PendingImport", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "EXTERNAL", + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Example: To create a KMS key in an AWS CloudHSM key store + # + # # This example creates a KMS key in the specified AWS CloudHSM key store. The operation creates the KMS key and its + # # metadata in AWS KMS and creates the key material in the AWS CloudHSM cluster associated with the custom key store. This + # # example requires the CustomKeyStoreId and Origin parameters. + # + # resp = client.create_key({ + # custom_key_store_id: "cks-1234567890abcdef0", # Identifies the custom key store that hosts the KMS key. + # origin: "AWS_CLOUDHSM", # Indicates the source of the key material for the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # cloud_hsm_cluster_id: "cluster-234abcdefABC", + # creation_date: Time.parse("2019-12-02T07:48:55-07:00"), + # custom_key_store_id: "cks-1234567890abcdef0", + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "AWS_CLOUDHSM", + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Example: To create a KMS key in an external key store + # + # # This example creates a KMS key in the specified external key store. It uses the XksKeyId parameter to associate the KMS + # # key with an existing symmetric encryption key in your external key manager. This CustomKeyStoreId, Origin, and XksKeyId + # # parameters are required in this operation. + # + # resp = client.create_key({ + # custom_key_store_id: "cks-9876543210fedcba9", # Identifies the custom key store that hosts the KMS key. + # origin: "EXTERNAL_KEY_STORE", # Indicates the source of the key material for the KMS key. + # xks_key_id: "bb8562717f809024", # Identifies the encryption key in your external key manager that is associated with the KMS key + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", + # creation_date: Time.parse("2022-02-02T07:48:55-07:00"), + # custom_key_store_id: "cks-9876543210fedcba9", + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "0987dcba-09fe-87dc-65ba-ab0987654321", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "EXTERNAL_KEY_STORE", + # xks_key_configuration: { + # id: "bb8562717f809024", + # }, + # }, # Detailed information about the KMS key that this operation creates. + # } + # @example Request syntax with placeholder values + # + # resp = client.create_key({ + # policy: "PolicyType", + # description: "DescriptionType", + # key_usage: "SIGN_VERIFY", # accepts SIGN_VERIFY, ENCRYPT_DECRYPT, GENERATE_VERIFY_MAC, KEY_AGREEMENT + # customer_master_key_spec: "RSA_2048", # accepts RSA_2048, RSA_3072, RSA_4096, ECC_NIST_P256, ECC_NIST_P384, ECC_NIST_P521, ECC_SECG_P256K1, SYMMETRIC_DEFAULT, HMAC_224, HMAC_256, HMAC_384, HMAC_512, SM2 + # key_spec: "RSA_2048", # accepts RSA_2048, RSA_3072, RSA_4096, ECC_NIST_P256, ECC_NIST_P384, ECC_NIST_P521, ECC_SECG_P256K1, SYMMETRIC_DEFAULT, HMAC_224, HMAC_256, HMAC_384, HMAC_512, SM2 + # origin: "AWS_KMS", # accepts AWS_KMS, EXTERNAL, AWS_CLOUDHSM, EXTERNAL_KEY_STORE + # custom_key_store_id: "CustomKeyStoreIdType", + # bypass_policy_lockout_safety_check: false, + # tags: [ + # { + # tag_key: "TagKeyType", # required + # tag_value: "TagValueType", # required + # }, + # ], + # multi_region: false, + # xks_key_id: "XksKeyIdType", + # }) + # @example Response structure + # + # resp.key_metadata.aws_account_id #=> String + # resp.key_metadata.key_id #=> String + # resp.key_metadata.arn #=> String + # resp.key_metadata.creation_date #=> Time + # resp.key_metadata.enabled #=> Boolean + # resp.key_metadata.description #=> String + # resp.key_metadata.key_usage #=> String, one of "SIGN_VERIFY", "ENCRYPT_DECRYPT", "GENERATE_VERIFY_MAC", "KEY_AGREEMENT" + # resp.key_metadata.key_state #=> String, one of "Creating", "Enabled", "Disabled", "PendingDeletion", "PendingImport", "PendingReplicaDeletion", "Unavailable", "Updating" + # resp.key_metadata.deletion_date #=> Time + # resp.key_metadata.valid_to #=> Time + # resp.key_metadata.origin #=> String, one of "AWS_KMS", "EXTERNAL", "AWS_CLOUDHSM", "EXTERNAL_KEY_STORE" + # resp.key_metadata.custom_key_store_id #=> String + # resp.key_metadata.cloud_hsm_cluster_id #=> String + # resp.key_metadata.expiration_model #=> String, one of "KEY_MATERIAL_EXPIRES", "KEY_MATERIAL_DOES_NOT_EXPIRE" + # resp.key_metadata.key_manager #=> String, one of "AWS", "CUSTOMER" + # resp.key_metadata.customer_master_key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.key_metadata.key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.key_metadata.encryption_algorithms #=> Array + # resp.key_metadata.encryption_algorithms[0] #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # resp.key_metadata.signing_algorithms #=> Array + # resp.key_metadata.signing_algorithms[0] #=> String, one of "RSASSA_PSS_SHA_256", "RSASSA_PSS_SHA_384", "RSASSA_PSS_SHA_512", "RSASSA_PKCS1_V1_5_SHA_256", "RSASSA_PKCS1_V1_5_SHA_384", "RSASSA_PKCS1_V1_5_SHA_512", "ECDSA_SHA_256", "ECDSA_SHA_384", "ECDSA_SHA_512", "SM2DSA" + # resp.key_metadata.key_agreement_algorithms #=> Array + # resp.key_metadata.key_agreement_algorithms[0] #=> String, one of "ECDH" + # resp.key_metadata.multi_region #=> Boolean + # resp.key_metadata.multi_region_configuration.multi_region_key_type #=> String, one of "PRIMARY", "REPLICA" + # resp.key_metadata.multi_region_configuration.primary_key.arn #=> String + # resp.key_metadata.multi_region_configuration.primary_key.region #=> String + # resp.key_metadata.multi_region_configuration.replica_keys #=> Array + # resp.key_metadata.multi_region_configuration.replica_keys[0].arn #=> String + # resp.key_metadata.multi_region_configuration.replica_keys[0].region #=> String + # resp.key_metadata.pending_deletion_window_in_days #=> Integer + # resp.key_metadata.mac_algorithms #=> Array + # resp.key_metadata.mac_algorithms[0] #=> String, one of "HMAC_SHA_224", "HMAC_SHA_256", "HMAC_SHA_384", "HMAC_SHA_512" + # resp.key_metadata.xks_key_configuration.id #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload create_key + # @param params [Hash] ({}) + # @return [Types::CreateKeyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateKeyResponse#key_metadata #key_metadata} => Types::KeyMetadata + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateKey AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#2363 + def create_key(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Decrypts ciphertext that was encrypted by a KMS key using any of the + # following operations: + # + # * Encrypt + # + # * GenerateDataKey + # + # * GenerateDataKeyPair + # + # * GenerateDataKeyWithoutPlaintext + # + # * GenerateDataKeyPairWithoutPlaintext + # + # You can use this operation to decrypt ciphertext that was encrypted + # under a symmetric encryption KMS key or an asymmetric encryption KMS + # key. When the KMS key is asymmetric, you must specify the KMS key and + # the encryption algorithm that was used to encrypt the ciphertext. For + # information about asymmetric KMS keys, see [Asymmetric KMS keys][1] in + # the *Key Management Service Developer Guide*. + # + # The `Decrypt` operation also decrypts ciphertext that was encrypted + # outside of KMS by the public key in an KMS asymmetric KMS key. + # However, it cannot decrypt symmetric ciphertext produced by other + # libraries, such as the [Amazon Web Services Encryption SDK][2] or + # [Amazon S3 client-side encryption][3]. These libraries return a + # ciphertext format that is incompatible with KMS. + # + # If the ciphertext was encrypted under a symmetric encryption KMS key, + # the `KeyId` parameter is optional. KMS can get this information from + # metadata that it adds to the symmetric ciphertext blob. This feature + # adds durability to your implementation by ensuring that authorized + # users can decrypt ciphertext decades after it was encrypted, even if + # they've lost track of the key ID. However, specifying the KMS key is + # always recommended as a best practice. When you use the `KeyId` + # parameter to specify a KMS key, KMS only uses the KMS key you specify. + # If the ciphertext was encrypted under a different KMS key, the + # `Decrypt` operation fails. This practice ensures that you use the KMS + # key that you intend. + # + # Whenever possible, use key policies to give users permission to call + # the `Decrypt` operation on a particular KMS key, instead of using + # &IAM; policies. Otherwise, you might create an &IAM; policy + # that gives the user `Decrypt` permission on all KMS keys. This user + # could decrypt ciphertext that was encrypted by KMS keys in other + # accounts if the key policy for the cross-account KMS key permits it. + # If you must use an IAM policy for `Decrypt` permissions, limit the + # user to particular KMS keys or particular trusted accounts. For + # details, see [Best practices for IAM policies][4] in the *Key + # Management Service Developer Guide*. + # + # `Decrypt` also supports [Amazon Web Services Nitro Enclaves][5], which + # provide an isolated compute environment in Amazon EC2. To call + # `Decrypt` for a Nitro enclave, use the [Amazon Web Services Nitro + # Enclaves SDK][6] or any Amazon Web Services SDK. Use the `Recipient` + # parameter to provide the attestation document for the enclave. Instead + # of the plaintext data, the response includes the plaintext data + # encrypted with the public key from the attestation document + # (`CiphertextForRecipient`). For information about the interaction + # between KMS and Amazon Web Services Nitro Enclaves, see [How Amazon + # Web Services Nitro Enclaves uses KMS][7] in the *Key Management + # Service Developer Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][8] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. If you use the `KeyId` parameter to + # identify a KMS key in a different Amazon Web Services account, specify + # the key ARN or the alias ARN of the KMS key. + # + # **Required permissions**: [kms:Decrypt][9] (key policy) + # + # **Related operations:** + # + # * Encrypt + # + # * GenerateDataKey + # + # * GenerateDataKeyPair + # + # * ReEncrypt + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][10]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [2]: https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/ + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/iam-policies.html#iam-policies-best-practices + # [5]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/nitro-enclave.html + # [6]: https://docs.aws.amazon.com/enclaves/latest/user/developing-applications.html#sdk + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/services-nitro-enclaves.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To decrypt data with a symmetric encryption KMS key + # + # # The following example decrypts data that was encrypted with a symmetric encryption KMS key. The KeyId is not required + # # when decrypting with a symmetric encryption key, but it is a best practice. + # + # resp = client.decrypt({ + # ciphertext_blob: "", # The encrypted data (ciphertext). + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # A key identifier for the KMS key to use to decrypt the data. + # }) + # + # resp.to_h outputs the following: + # { + # encryption_algorithm: "SYMMETRIC_DEFAULT", # The encryption algorithm that was used to decrypt the ciphertext. SYMMETRIC_DEFAULT is the only valid value for symmetric encryption in AWS KMS. + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The Amazon Resource Name (ARN) of the KMS key that was used to decrypt the data. + # plaintext: "", # The decrypted (plaintext) data. + # } + # @example Example: To decrypt data with an asymmetric encryption KMS key + # + # # The following example decrypts data that was encrypted with an asymmetric encryption KMS key. When the KMS encryption + # # key is asymmetric, you must specify the KMS key ID and the encryption algorithm that was used to encrypt the data. + # + # resp = client.decrypt({ + # ciphertext_blob: "", # The encrypted data (ciphertext). + # encryption_algorithm: "RSAES_OAEP_SHA_256", # The encryption algorithm that was used to encrypt the data. This parameter is required to decrypt with an asymmetric KMS key. + # key_id: "0987dcba-09fe-87dc-65ba-ab0987654321", # A key identifier for the KMS key to use to decrypt the data. This parameter is required to decrypt with an asymmetric KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # encryption_algorithm: "RSAES_OAEP_SHA_256", # The encryption algorithm that was used to decrypt the ciphertext. + # key_id: "arn:aws:kms:us-west-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The Amazon Resource Name (ARN) of the KMS key that was used to decrypt the data. + # plaintext: "", # The decrypted (plaintext) data. + # } + # @example Example: To decrypt data for a Nitro enclave + # + # # The following Decrypt example includes the Recipient parameter with a signed attestation document from an AWS Nitro + # # enclave. Instead of returning the decrypted data in plaintext (Plaintext), the operation returns the decrypted data + # # encrypted by the public key from the attestation document (CiphertextForRecipient). + # + # resp = client.decrypt({ + # ciphertext_blob: "", # The encrypted data. This ciphertext was encrypted with the KMS key + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The KMS key to use to decrypt the ciphertext + # recipient: { + # attestation_document: "", + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", + # }, # Specifies the attestation document from the Nitro enclave and the encryption algorithm to use with the public key from the attestation document + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_for_recipient: "", # The decrypted CiphertextBlob encrypted with the public key from the attestation document + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The KMS key that was used to decrypt the encrypted data (CiphertextBlob) + # plaintext: "", # This field is null or empty + # } + # @example Request syntax with placeholder values + # + # resp = client.decrypt({ + # ciphertext_blob: "data", # required + # encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # grant_tokens: ["GrantTokenType"], + # key_id: "KeyIdType", + # encryption_algorithm: "SYMMETRIC_DEFAULT", # accepts SYMMETRIC_DEFAULT, RSAES_OAEP_SHA_1, RSAES_OAEP_SHA_256, SM2PKE + # recipient: { + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", # accepts RSAES_OAEP_SHA_256 + # attestation_document: "data", + # }, + # dry_run: false, + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.plaintext #=> String + # resp.encryption_algorithm #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # resp.ciphertext_for_recipient #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload decrypt + # @param params [Hash] ({}) + # @return [Types::DecryptResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DecryptResponse#key_id #key_id} => String + # * {Types::DecryptResponse#plaintext #plaintext} => String + # * {Types::DecryptResponse#encryption_algorithm #encryption_algorithm} => String + # * {Types::DecryptResponse#ciphertext_for_recipient #ciphertext_for_recipient} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/Decrypt AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#2679 + def decrypt(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes the specified alias. + # + # Adding, deleting, or updating an alias can allow or deny permission to + # the KMS key. For details, see [ABAC for KMS][1] in the *Key Management + # Service Developer Guide*. + # + # + # + # Because an alias is not a property of a KMS key, you can delete and + # change the aliases of a KMS key without affecting the KMS key. Also, + # aliases do not appear in the response from the DescribeKey operation. + # To get the aliases of all KMS keys, use the ListAliases operation. + # + # Each KMS key can have multiple aliases. To change the alias of a KMS + # key, use DeleteAlias to delete the current alias and CreateAlias to + # create a new alias. To associate an existing alias with a different + # KMS key, call UpdateAlias. + # + # **Cross-account use**: No. You cannot perform this operation on an + # alias in a different Amazon Web Services account. + # + # **Required permissions** + # + # * [kms:DeleteAlias][2] on the alias (IAM policy). + # + # * [kms:DeleteAlias][2] on the KMS key (key policy). + # + # For details, see [Controlling access to aliases][3] in the *Key + # Management Service Developer Guide*. + # + # **Related operations:** + # + # * CreateAlias + # + # * ListAliases + # + # * UpdateAlias + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/abac.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To delete an alias + # + # # The following example deletes the specified alias. + # + # resp = client.delete_alias({ + # alias_name: "alias/ExampleAlias", # The alias to delete. + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_alias({ + # alias_name: "AliasNameType", # required + # }) + # @option params + # @overload delete_alias + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeleteAlias AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#2757 + def delete_alias(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes a [custom key store][1]. This operation does not affect any + # backing elements of the custom key store. It does not delete the + # CloudHSM cluster that is associated with an CloudHSM key store, or + # affect any users or keys in the cluster. For an external key store, it + # does not affect the external key store proxy, external key manager, or + # any external keys. + # + # This operation is part of the [custom key stores][1] feature in KMS, + # which combines the convenience and extensive integration of KMS with + # the isolation and control of a key store that you own and manage. + # + # The custom key store that you delete cannot contain any [KMS keys][2]. + # Before deleting the key store, verify that you will never need to use + # any of the KMS keys in the key store for any [cryptographic + # operations][3]. Then, use ScheduleKeyDeletion to delete the KMS keys + # from the key store. After the required waiting period expires and all + # KMS keys are deleted from the custom key store, use + # DisconnectCustomKeyStore to disconnect the key store from KMS. Then, + # you can delete the custom key store. + # + # For keys in an CloudHSM key store, the `ScheduleKeyDeletion` operation + # makes a best effort to delete the key material from the associated + # cluster. However, you might need to manually [delete the orphaned key + # material][4] from the cluster and its backups. KMS never creates, + # manages, or deletes cryptographic keys in the external key manager + # associated with an external key store. You must manage them using your + # external key manager tools. + # + # Instead of deleting the custom key store, consider using the + # DisconnectCustomKeyStore operation to disconnect the custom key store + # from its backing key store. While the key store is disconnected, you + # cannot create or use the KMS keys in the key store. But, you do not + # need to delete KMS keys and you can reconnect a disconnected custom + # key store at any time. + # + # If the operation succeeds, it returns a JSON object with no + # properties. + # + # **Cross-account use**: No. You cannot perform this operation on a + # custom key store in a different Amazon Web Services account. + # + # **Required permissions**: [kms:DeleteCustomKeyStore][5] (IAM policy) + # + # **Related operations:** + # + # * ConnectCustomKeyStore + # + # * CreateCustomKeyStore + # + # * DescribeCustomKeyStores + # + # * DisconnectCustomKeyStore + # + # * UpdateCustomKeyStore + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][6]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#kms_keys + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html#fix-keystore-orphaned-key + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To delete a custom key store from AWS KMS + # + # # This example deletes a custom key store from AWS KMS. This operation does not affect the backing key store, such as a + # # CloudHSM cluster, external key store proxy, or your external key manager. This operation doesn't return any data. To + # # verify that the operation was successful, use the DescribeCustomKeyStores operation. + # + # resp = client.delete_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the custom key store to be deleted. + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.delete_custom_key_store({ + # custom_key_store_id: "CustomKeyStoreIdType", # required + # }) + # @option params + # @overload delete_custom_key_store + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeleteCustomKeyStore AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#2860 + def delete_custom_key_store(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes key material that was previously imported. This operation + # makes the specified KMS key temporarily unusable. To restore the + # usability of the KMS key, reimport the same key material. For more + # information about importing key material into KMS, see [Importing Key + # Material][1] in the *Key Management Service Developer Guide*. + # + # When the specified KMS key is in the `PendingDeletion` state, this + # operation does not change the KMS key's state. Otherwise, it changes + # the KMS key's state to `PendingImport`. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][2] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:DeleteImportedKeyMaterial][3] (key + # policy) + # + # **Related operations:** + # + # * GetParametersForImport + # + # * ImportKeyMaterial + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To delete imported key material + # + # # The following example deletes the imported key material from the specified KMS key. + # + # resp = client.delete_imported_key_material({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose imported key material you are deleting. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_imported_key_material({ + # key_id: "KeyIdType", # required + # }) + # @option params + # @overload delete_imported_key_material + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeleteImportedKeyMaterial AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#2938 + def delete_imported_key_material(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Derives a shared secret using a key agreement algorithm. + # + # You must use an asymmetric NIST-recommended elliptic curve (ECC) or + # SM2 (China Regions only) KMS key pair with a `KeyUsage` value of + # `KEY_AGREEMENT` to call DeriveSharedSecret. + # + # + # + # DeriveSharedSecret uses the [Elliptic Curve Cryptography Cofactor + # Diffie-Hellman Primitive][1] (ECDH) to establish a key agreement + # between two peers by deriving a shared secret from their elliptic + # curve public-private key pairs. You can use the raw shared secret that + # DeriveSharedSecret returns to derive a symmetric key that can encrypt + # and decrypt data that is sent between the two peers, or that can + # generate and verify HMACs. KMS recommends that you follow [NIST + # recommendations for key derivation][2] when using the raw shared + # secret to derive a symmetric key. + # + # The following workflow demonstrates how to establish key agreement + # over an insecure communication channel using DeriveSharedSecret. + # + # 1. **Alice** calls CreateKey to create an asymmetric KMS key pair + # with a `KeyUsage` value of `KEY_AGREEMENT`. + # + # The asymmetric KMS key must use a NIST-recommended elliptic curve + # (ECC) or SM2 (China Regions only) key spec. + # + # 2. **Bob** creates an elliptic curve key pair. + # + # Bob can call CreateKey to create an asymmetric KMS key pair or + # generate a key pair outside of KMS. Bob's key pair must use the + # same NIST-recommended elliptic curve (ECC) or SM2 (China Regions + # ony) curve as Alice. + # + # 3. Alice and Bob **exchange their public keys** through an insecure + # communication channel (like the internet). + # + # Use GetPublicKey to download the public key of your asymmetric KMS + # key pair. + # + # KMS strongly recommends verifying that the public key you receive + # came from the expected party before using it to derive a shared + # secret. + # + # + # + # 4. **Alice** calls DeriveSharedSecret. + # + # KMS uses the private key from the KMS key pair generated in **Step + # 1**, Bob's public key, and the Elliptic Curve Cryptography + # Cofactor Diffie-Hellman Primitive to derive the shared secret. The + # private key in your KMS key pair never leaves KMS unencrypted. + # DeriveSharedSecret returns the raw shared secret. + # + # 5. **Bob** uses the Elliptic Curve Cryptography Cofactor + # Diffie-Hellman Primitive to calculate the same raw secret using + # his private key and Alice's public key. + # + # To derive a shared secret you must provide a key agreement algorithm, + # the private key of the caller's asymmetric NIST-recommended elliptic + # curve or SM2 (China Regions only) KMS key pair, and the public key + # from your peer's NIST-recommended elliptic curve or SM2 (China + # Regions only) key pair. The public key can be from another asymmetric + # KMS key pair or from a key pair generated outside of KMS, but both key + # pairs must be on the same elliptic curve. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][3] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:DeriveSharedSecret][4] (key policy) + # + # **Related operations:** + # + # * CreateKey + # + # * GetPublicKey + # + # * DescribeKey + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-56Ar3.pdf#page=60 + # [2]: https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-56Cr2.pdf + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To derive a shared secret + # + # # The following example derives a shared secret using a key agreement algorithm. + # + # resp = client.derive_shared_secret({ + # key_agreement_algorithm: "ECDH", # The key agreement algorithm used to derive the shared secret. The only valid value is ECDH. + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The key identifier for an asymmetric KMS key pair. The private key in the specified key pair is used to derive the shared secret. + # public_key: "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAvH3Yj0wbkLEpUl95Cv1cJVjsVNSjwGq3tCLnzXfhVwVvmzGN8pYj3U8nKwgouaHbBWNJYjP5VutbbkKS4Kv4GojwZBJyHN17kmxo8yTjRmjR15SKIQ8cqRA2uaERMLnpztIXdZp232PQPbWGxDyXYJ0aJ5EFSag", # The public key in your peer's asymmetric key pair. + # }) + # + # resp.to_h outputs the following: + # { + # key_agreement_algorithm: "ECDH", # The key agreement algorithm used to derive the shared secret. + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The asymmetric KMS key pair used to derive the shared secret. + # key_origin: "AWS_KMS", # The source of the key material for the specified KMS key. + # shared_secret: "MEYCIQCKZLWyTk5runarx6XiAkU9gv3lbwPO/pHa+DXFehzdDwIhANwpsIV2g/9SPWLLsF6p/hiSskuIXMTRwqrMdVKWTMHG", # The raw secret derived from the specified key agreement algorithm, private key in the asymmetric KMS key, and your peer's public key. + # } + # @example Request syntax with placeholder values + # + # resp = client.derive_shared_secret({ + # key_id: "KeyIdType", # required + # key_agreement_algorithm: "ECDH", # required, accepts ECDH + # public_key: "data", # required + # grant_tokens: ["GrantTokenType"], + # dry_run: false, + # recipient: { + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", # accepts RSAES_OAEP_SHA_256 + # attestation_document: "data", + # }, + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.shared_secret #=> String + # resp.ciphertext_for_recipient #=> String + # resp.key_agreement_algorithm #=> String, one of "ECDH" + # resp.key_origin #=> String, one of "AWS_KMS", "EXTERNAL", "AWS_CLOUDHSM", "EXTERNAL_KEY_STORE" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload derive_shared_secret + # @param params [Hash] ({}) + # @return [Types::DeriveSharedSecretResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DeriveSharedSecretResponse#key_id #key_id} => String + # * {Types::DeriveSharedSecretResponse#shared_secret #shared_secret} => String + # * {Types::DeriveSharedSecretResponse#ciphertext_for_recipient #ciphertext_for_recipient} => String + # * {Types::DeriveSharedSecretResponse#key_agreement_algorithm #key_agreement_algorithm} => String + # * {Types::DeriveSharedSecretResponse#key_origin #key_origin} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeriveSharedSecret AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#3202 + def derive_shared_secret(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Gets information about [custom key stores][1] in the account and + # Region. + # + # This operation is part of the [custom key stores][1] feature in KMS, + # which combines the convenience and extensive integration of KMS with + # the isolation and control of a key store that you own and manage. + # + # By default, this operation returns information about all custom key + # stores in the account and Region. To get only information about a + # particular custom key store, use either the `CustomKeyStoreName` or + # `CustomKeyStoreId` parameter (but not both). + # + # To determine whether the custom key store is connected to its CloudHSM + # cluster or external key store proxy, use the `ConnectionState` element + # in the response. If an attempt to connect the custom key store failed, + # the `ConnectionState` value is `FAILED` and the `ConnectionErrorCode` + # element in the response indicates the cause of the failure. For help + # interpreting the `ConnectionErrorCode`, see CustomKeyStoresListEntry. + # + # Custom key stores have a `DISCONNECTED` connection state if the key + # store has never been connected or you used the + # DisconnectCustomKeyStore operation to disconnect it. Otherwise, the + # connection state is CONNECTED. If your custom key store connection + # state is `CONNECTED` but you are having trouble using it, verify that + # the backing store is active and available. For an CloudHSM key store, + # verify that the associated CloudHSM cluster is active and contains the + # minimum number of HSMs required for the operation, if any. For an + # external key store, verify that the external key store proxy and its + # associated external key manager are reachable and enabled. + # + # For help repairing your CloudHSM key store, see the [Troubleshooting + # CloudHSM key stores][2]. For help repairing your external key store, + # see the [Troubleshooting external key stores][3]. Both topics are in + # the *Key Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a + # custom key store in a different Amazon Web Services account. + # + # **Required permissions**: [kms:DescribeCustomKeyStores][4] (IAM + # policy) + # + # **Related operations:** + # + # * ConnectCustomKeyStore + # + # * CreateCustomKeyStore + # + # * DeleteCustomKeyStore + # + # * DisconnectCustomKeyStore + # + # * UpdateCustomKeyStore + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/xks-troubleshooting.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To get detailed information about custom key stores in the account and Region + # + # # This example gets detailed information about all AWS KMS custom key stores in an AWS account and Region. To get all key + # # stores, do not enter a custom key store name or ID. + # + # resp = client.describe_custom_key_stores({ + # }) + # + # resp.to_h outputs the following: + # { + # custom_key_stores: [ + # ], # Details about each custom key store in the account and Region. + # } + # @example Example: To get detailed information about an AWS CloudHSM key store by specifying its friendly name + # + # # This example gets detailed information about a particular AWS CloudHSM key store by specifying its friendly name. To + # # limit the output to a particular custom key store, provide either the custom key store name or ID. + # + # resp = client.describe_custom_key_stores({ + # custom_key_store_name: "ExampleKeyStore", # The friendly name of the custom key store. + # }) + # + # resp.to_h outputs the following: + # { + # custom_key_stores: [ + # { + # cloud_hsm_cluster_id: "cluster-234abcdefABC", + # connection_state: "CONNECTED", + # creation_date: Time.parse("1.499288695918E9"), + # custom_key_store_id: "cks-1234567890abcdef0", + # custom_key_store_name: "ExampleKeyStore", + # custom_key_store_type: "AWS_CLOUDHSM", + # trust_anchor_certificate: "", + # }, + # ], # Detailed information about the specified custom key store. + # } + # @example Example: To get detailed information about an external key store by specifying its ID + # + # # This example gets detailed information about an external key store by specifying its ID. The example external key store + # # proxy uses public endpoint connectivity. + # + # resp = client.describe_custom_key_stores({ + # custom_key_store_id: "cks-9876543210fedcba9", # The ID of the custom key store. + # }) + # + # resp.to_h outputs the following: + # { + # custom_key_stores: [ + # { + # connection_state: "CONNECTED", + # creation_date: Time.parse("1.599288695918E9"), + # custom_key_store_id: "cks-9876543210fedcba9", + # custom_key_store_name: "ExampleExternalKeyStore", + # custom_key_store_type: "EXTERNAL_KEY_STORE", + # xks_proxy_configuration: { + # access_key_id: "ABCDE12345670EXAMPLE", + # connectivity: "PUBLIC_ENDPOINT", + # uri_endpoint: "https://myproxy.xks.example.com", + # uri_path: "/kms/xks/v1", + # }, + # }, + # ], # Detailed information about the specified custom key store. + # } + # @example Example: To get detailed information about an external key store VPC endpoint connectivity by specifying its friendly name + # + # # This example gets detailed information about a particular external key store by specifying its friendly name. To limit + # # the output to a particular custom key store, provide either the custom key store name or ID. The proxy URI path for this + # # external key store includes an optional prefix. Also, because this example external key store uses VPC endpoint + # # connectivity, the response includes the associated VPC endpoint service name. + # + # resp = client.describe_custom_key_stores({ + # custom_key_store_name: "VPCExternalKeystore", + # }) + # + # resp.to_h outputs the following: + # { + # custom_key_stores: [ + # { + # connection_state: "CONNECTED", + # creation_date: Time.parse("1.643057863.842"), + # custom_key_store_id: "cks-876543210fedcba98", + # custom_key_store_name: "ExampleVPCExternalKeyStore", + # custom_key_store_type: "EXTERNAL_KEY_STORE", + # xks_proxy_configuration: { + # access_key_id: "ABCDE12345670EXAMPLE", + # connectivity: "VPC_ENDPOINT_SERVICE", + # uri_endpoint: "https://myproxy-private.xks.example.com", + # uri_path: "/example-prefix/kms/xks/v1", + # vpc_endpoint_service_name: "com.amazonaws.vpce.us-east-1.vpce-svc-example1", + # }, + # }, + # ], # Detailed information about the specified custom key store. + # } + # @example Request syntax with placeholder values + # + # resp = client.describe_custom_key_stores({ + # custom_key_store_id: "CustomKeyStoreIdType", + # custom_key_store_name: "CustomKeyStoreNameType", + # limit: 1, + # marker: "MarkerType", + # }) + # @example Response structure + # + # resp.custom_key_stores #=> Array + # resp.custom_key_stores[0].custom_key_store_id #=> String + # resp.custom_key_stores[0].custom_key_store_name #=> String + # resp.custom_key_stores[0].cloud_hsm_cluster_id #=> String + # resp.custom_key_stores[0].trust_anchor_certificate #=> String + # resp.custom_key_stores[0].connection_state #=> String, one of "CONNECTED", "CONNECTING", "FAILED", "DISCONNECTED", "DISCONNECTING" + # resp.custom_key_stores[0].connection_error_code #=> String, one of "INVALID_CREDENTIALS", "CLUSTER_NOT_FOUND", "NETWORK_ERRORS", "INTERNAL_ERROR", "INSUFFICIENT_CLOUDHSM_HSMS", "USER_LOCKED_OUT", "USER_NOT_FOUND", "USER_LOGGED_IN", "SUBNET_NOT_FOUND", "INSUFFICIENT_FREE_ADDRESSES_IN_SUBNET", "XKS_PROXY_ACCESS_DENIED", "XKS_PROXY_NOT_REACHABLE", "XKS_VPC_ENDPOINT_SERVICE_NOT_FOUND", "XKS_PROXY_INVALID_RESPONSE", "XKS_PROXY_INVALID_CONFIGURATION", "XKS_VPC_ENDPOINT_SERVICE_INVALID_CONFIGURATION", "XKS_PROXY_TIMED_OUT", "XKS_PROXY_INVALID_TLS_CONFIGURATION" + # resp.custom_key_stores[0].creation_date #=> Time + # resp.custom_key_stores[0].custom_key_store_type #=> String, one of "AWS_CLOUDHSM", "EXTERNAL_KEY_STORE" + # resp.custom_key_stores[0].xks_proxy_configuration.connectivity #=> String, one of "PUBLIC_ENDPOINT", "VPC_ENDPOINT_SERVICE" + # resp.custom_key_stores[0].xks_proxy_configuration.access_key_id #=> String + # resp.custom_key_stores[0].xks_proxy_configuration.uri_endpoint #=> String + # resp.custom_key_stores[0].xks_proxy_configuration.uri_path #=> String + # resp.custom_key_stores[0].xks_proxy_configuration.vpc_endpoint_service_name #=> String + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @option params + # @option params + # @overload describe_custom_key_stores + # @param params [Hash] ({}) + # @return [Types::DescribeCustomKeyStoresResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DescribeCustomKeyStoresResponse#custom_key_stores #custom_key_stores} => Array<Types::CustomKeyStoresListEntry> + # * {Types::DescribeCustomKeyStoresResponse#next_marker #next_marker} => String + # * {Types::DescribeCustomKeyStoresResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DescribeCustomKeyStores AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#3437 + def describe_custom_key_stores(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Provides detailed information about a KMS key. You can run + # `DescribeKey` on a [customer managed key][1] or an [Amazon Web + # Services managed key][2]. + # + # This detailed information includes the key ARN, creation date (and + # deletion date, if applicable), the key state, and the origin and + # expiration date (if any) of the key material. It includes fields, like + # `KeySpec`, that help you distinguish different types of KMS keys. It + # also displays the key usage (encryption, signing, or generating and + # verifying MACs) and the algorithms that the KMS key supports. + # + # For [multi-Region keys][3], `DescribeKey` displays the primary key and + # all related replica keys. For KMS keys in [CloudHSM key stores][4], it + # includes information about the key store, such as the key store ID and + # the CloudHSM cluster ID. For KMS keys in [external key stores][5], it + # includes the custom key store ID and the ID of the external key. + # + # `DescribeKey` does not return the following information: + # + # * Aliases associated with the KMS key. To get this information, use + # ListAliases. + # + # * Whether automatic key rotation is enabled on the KMS key. To get + # this information, use GetKeyRotationStatus. Also, some key states + # prevent a KMS key from being automatically rotated. For details, see + # [How Automatic Key Rotation Works][6] in the *Key Management Service + # Developer Guide*. + # + # * Tags on the KMS key. To get this information, use ListResourceTags. + # + # * Key policies and grants on the KMS key. To get this information, use + # GetKeyPolicy and ListGrants. + # + # In general, `DescribeKey` is a non-mutating operation. It returns data + # about KMS keys, but doesn't change them. However, Amazon Web Services + # services use `DescribeKey` to create [Amazon Web Services managed + # keys][2] from a *predefined Amazon Web Services alias* with no key ID. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:DescribeKey][7] (key policy) + # + # **Related operations:** + # + # * GetKeyPolicy + # + # * GetKeyRotationStatus + # + # * ListAliases + # + # * ListGrants + # + # * ListKeys + # + # * ListResourceTags + # + # * ListRetirableGrants + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][8]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/keystore-cloudhsm.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/keystore-external.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html#rotate-keys-how-it-works + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To get details about a KMS key + # + # # The following example gets metadata for a symmetric encryption KMS key. + # + # resp = client.describe_key({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # An identifier for the KMS key. You can use the key ID, key ARN, alias name, alias ARN of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse("2017-07-05T14:04:55-07:00"), + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "AWS_KMS", + # }, # An object that contains information about the specified KMS key. + # } + # @example Example: To get details about an RSA asymmetric KMS key + # + # # The following example gets metadata for an asymmetric RSA KMS key used for signing and verification. + # + # resp = client.describe_key({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # An identifier for the KMS key. You can use the key ID, key ARN, alias name, alias ARN of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse(1571767572.317), + # customer_master_key_spec: "RSA_2048", + # description: "", + # enabled: false, + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "RSA_2048", + # key_state: "Disabled", + # key_usage: "SIGN_VERIFY", + # multi_region: false, + # origin: "AWS_KMS", + # signing_algorithms: [ + # "RSASSA_PKCS1_V1_5_SHA_256", + # "RSASSA_PKCS1_V1_5_SHA_384", + # "RSASSA_PKCS1_V1_5_SHA_512", + # "RSASSA_PSS_SHA_256", + # "RSASSA_PSS_SHA_384", + # "RSASSA_PSS_SHA_512", + # ], + # }, # An object that contains information about the specified KMS key. + # } + # @example Example: To get details about a multi-Region key + # + # # The following example gets metadata for a multi-Region replica key. This multi-Region key is a symmetric encryption key. + # # DescribeKey returns information about the primary key and all of its replicas. + # + # resp = client.describe_key({ + # key_id: "arn:aws:kms:ap-northeast-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", # An identifier for the KMS key. You can use the key ID, key ARN, alias name, alias ARN of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:ap-northeast-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # creation_date: Time.parse(1586329200.918), + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "mrk-1234abcd12ab34cd56ef1234567890ab", + # key_manager: "CUSTOMER", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: true, + # multi_region_configuration: { + # multi_region_key_type: "PRIMARY", + # primary_key: { + # arn: "arn:aws:kms:us-west-2:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # region: "us-west-2", + # }, + # replica_keys: [ + # { + # arn: "arn:aws:kms:eu-west-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # region: "eu-west-1", + # }, + # { + # arn: "arn:aws:kms:ap-northeast-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # region: "ap-northeast-1", + # }, + # { + # arn: "arn:aws:kms:sa-east-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # region: "sa-east-1", + # }, + # ], + # }, + # origin: "AWS_KMS", + # }, # An object that contains information about the specified KMS key. + # } + # @example Example: To get details about an HMAC KMS key + # + # # The following example gets the metadata of an HMAC KMS key. + # + # resp = client.describe_key({ + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # An identifier for the KMS key. You can use the key ID, key ARN, alias name, alias ARN of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "123456789012", + # arn: "arn:aws:kms:us-west-2:123456789012:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse(1566160362.664), + # customer_master_key_spec: "HMAC_256", + # description: "Development test key", + # enabled: true, + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_state: "Enabled", + # key_usage: "GENERATE_VERIFY_MAC", + # mac_algorithms: [ + # "HMAC_SHA_256", + # ], + # multi_region: false, + # origin: "AWS_KMS", + # }, # An object that contains information about the specified KMS key. + # } + # @example Example: To get details about a KMS key in an AWS CloudHSM key store + # + # # The following example gets the metadata of a KMS key in an AWS CloudHSM key store. + # + # resp = client.describe_key({ + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # An identifier for the KMS key. You can use the key ID, key ARN, alias name, alias ARN of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "123456789012", + # arn: "arn:aws:kms:us-west-2:123456789012:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # cloud_hsm_cluster_id: "cluster-234abcdefABC", + # creation_date: Time.parse(1646160362.664), + # custom_key_store_id: "cks-1234567890abcdef0", + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "CloudHSM key store test key", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "AWS_CLOUDHSM", + # }, # An object that contains information about the specified KMS key. + # } + # @example Example: To get details about a KMS key in an external key store + # + # # The following example gets the metadata of a KMS key in an external key store. + # + # resp = client.describe_key({ + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # An identifier for the KMS key. You can use the key ID, key ARN, alias name, alias ARN of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_metadata: { + # aws_account_id: "123456789012", + # arn: "arn:aws:kms:us-west-2:123456789012:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # creation_date: Time.parse(1646160362.664), + # custom_key_store_id: "cks-1234567890abcdef0", + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "External key store test key", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # key_manager: "CUSTOMER", + # key_spec: "SYMMETRIC_DEFAULT", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: false, + # origin: "EXTERNAL_KEY_STORE", + # xks_key_configuration: { + # id: "bb8562717f809024", + # }, + # }, # An object that contains information about the specified KMS key. + # } + # @example Request syntax with placeholder values + # + # resp = client.describe_key({ + # key_id: "KeyIdType", # required + # grant_tokens: ["GrantTokenType"], + # }) + # @example Response structure + # + # resp.key_metadata.aws_account_id #=> String + # resp.key_metadata.key_id #=> String + # resp.key_metadata.arn #=> String + # resp.key_metadata.creation_date #=> Time + # resp.key_metadata.enabled #=> Boolean + # resp.key_metadata.description #=> String + # resp.key_metadata.key_usage #=> String, one of "SIGN_VERIFY", "ENCRYPT_DECRYPT", "GENERATE_VERIFY_MAC", "KEY_AGREEMENT" + # resp.key_metadata.key_state #=> String, one of "Creating", "Enabled", "Disabled", "PendingDeletion", "PendingImport", "PendingReplicaDeletion", "Unavailable", "Updating" + # resp.key_metadata.deletion_date #=> Time + # resp.key_metadata.valid_to #=> Time + # resp.key_metadata.origin #=> String, one of "AWS_KMS", "EXTERNAL", "AWS_CLOUDHSM", "EXTERNAL_KEY_STORE" + # resp.key_metadata.custom_key_store_id #=> String + # resp.key_metadata.cloud_hsm_cluster_id #=> String + # resp.key_metadata.expiration_model #=> String, one of "KEY_MATERIAL_EXPIRES", "KEY_MATERIAL_DOES_NOT_EXPIRE" + # resp.key_metadata.key_manager #=> String, one of "AWS", "CUSTOMER" + # resp.key_metadata.customer_master_key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.key_metadata.key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.key_metadata.encryption_algorithms #=> Array + # resp.key_metadata.encryption_algorithms[0] #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # resp.key_metadata.signing_algorithms #=> Array + # resp.key_metadata.signing_algorithms[0] #=> String, one of "RSASSA_PSS_SHA_256", "RSASSA_PSS_SHA_384", "RSASSA_PSS_SHA_512", "RSASSA_PKCS1_V1_5_SHA_256", "RSASSA_PKCS1_V1_5_SHA_384", "RSASSA_PKCS1_V1_5_SHA_512", "ECDSA_SHA_256", "ECDSA_SHA_384", "ECDSA_SHA_512", "SM2DSA" + # resp.key_metadata.key_agreement_algorithms #=> Array + # resp.key_metadata.key_agreement_algorithms[0] #=> String, one of "ECDH" + # resp.key_metadata.multi_region #=> Boolean + # resp.key_metadata.multi_region_configuration.multi_region_key_type #=> String, one of "PRIMARY", "REPLICA" + # resp.key_metadata.multi_region_configuration.primary_key.arn #=> String + # resp.key_metadata.multi_region_configuration.primary_key.region #=> String + # resp.key_metadata.multi_region_configuration.replica_keys #=> Array + # resp.key_metadata.multi_region_configuration.replica_keys[0].arn #=> String + # resp.key_metadata.multi_region_configuration.replica_keys[0].region #=> String + # resp.key_metadata.pending_deletion_window_in_days #=> Integer + # resp.key_metadata.mac_algorithms #=> Array + # resp.key_metadata.mac_algorithms[0] #=> String, one of "HMAC_SHA_224", "HMAC_SHA_256", "HMAC_SHA_384", "HMAC_SHA_512" + # resp.key_metadata.xks_key_configuration.id #=> String + # @option params + # @option params + # @overload describe_key + # @param params [Hash] ({}) + # @return [Types::DescribeKeyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DescribeKeyResponse#key_metadata #key_metadata} => Types::KeyMetadata + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DescribeKey AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#3824 + def describe_key(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Sets the state of a KMS key to disabled. This change temporarily + # prevents use of the KMS key for [cryptographic operations][1]. + # + # For more information about how key state affects the use of a KMS key, + # see [Key states of KMS keys][2] in the Key Management Service + # Developer Guide . + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][2] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:DisableKey][3] (key policy) + # + # **Related operations**: EnableKey + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To disable a KMS key + # + # # The following example disables the specified KMS key. + # + # resp = client.disable_key({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to disable. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.disable_key({ + # key_id: "KeyIdType", # required + # }) + # @option params + # @overload disable_key + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisableKey AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#3893 + def disable_key(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Disables [automatic rotation of the key material][1] of the specified + # symmetric encryption KMS key. + # + # Automatic key rotation is supported only on symmetric encryption KMS + # keys. You cannot enable automatic rotation of [asymmetric KMS + # keys][2], [HMAC KMS keys][3], KMS keys with [imported key + # material][4], or KMS keys in a [custom key store][5]. To enable or + # disable automatic rotation of a set of related [multi-Region keys][6], + # set the property on the primary key. + # + # You can enable (EnableKeyRotation) and disable automatic rotation of + # the key material in [customer managed KMS keys][7]. Key material + # rotation of [Amazon Web Services managed KMS keys][8] is not + # configurable. KMS always rotates the key material for every year. + # Rotation of [Amazon Web Services owned KMS keys][9] varies. + # + # In May 2022, KMS changed the rotation schedule for Amazon Web Services + # managed keys from every three years to every year. For details, see + # EnableKeyRotation. + # + # + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][10] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:DisableKeyRotation][11] (key policy) + # + # **Related operations:** + # + # * EnableKeyRotation + # + # * GetKeyRotationStatus + # + # * ListKeyRotations + # + # * RotateKeyOnDemand + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][12]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-manage.html#multi-region-rotate + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-owned-cmk + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [12]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To disable automatic rotation of key material + # + # # The following example disables automatic annual rotation of the key material for the specified KMS key. + # + # resp = client.disable_key_rotation({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose key material will no longer be rotated. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.disable_key_rotation({ + # key_id: "KeyIdType", # required + # }) + # @option params + # @overload disable_key_rotation + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisableKeyRotation AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#4003 + def disable_key_rotation(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Disconnects the [custom key store][1] from its backing key store. This + # operation disconnects an CloudHSM key store from its associated + # CloudHSM cluster or disconnects an external key store from the + # external key store proxy that communicates with your external key + # manager. + # + # This operation is part of the [custom key stores][1] feature in KMS, + # which combines the convenience and extensive integration of KMS with + # the isolation and control of a key store that you own and manage. + # + # While a custom key store is disconnected, you can manage the custom + # key store and its KMS keys, but you cannot create or use its KMS keys. + # You can reconnect the custom key store at any time. + # + # While a custom key store is disconnected, all attempts to create KMS + # keys in the custom key store or to use existing KMS keys in + # [cryptographic operations][2] will fail. This action can prevent users + # from storing and accessing sensitive data. + # + # + # + # When you disconnect a custom key store, its `ConnectionState` changes + # to `Disconnected`. To find the connection state of a custom key store, + # use the DescribeCustomKeyStores operation. To reconnect a custom key + # store, use the ConnectCustomKeyStore operation. + # + # If the operation succeeds, it returns a JSON object with no + # properties. + # + # **Cross-account use**: No. You cannot perform this operation on a + # custom key store in a different Amazon Web Services account. + # + # **Required permissions**: [kms:DisconnectCustomKeyStore][3] (IAM + # policy) + # + # **Related operations:** + # + # * ConnectCustomKeyStore + # + # * CreateCustomKeyStore + # + # * DeleteCustomKeyStore + # + # * DescribeCustomKeyStores + # + # * UpdateCustomKeyStore + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To disconnect a custom key store from its CloudHSM cluster + # + # # This example disconnects an AWS KMS custom key store from its backing key store. For an AWS CloudHSM key store, it + # # disconnects the key store from its AWS CloudHSM cluster. For an external key store, it disconnects the key store from + # # the external key store proxy that communicates with your external key manager. This operation doesn't return any data. + # # To verify that the custom key store is disconnected, use the DescribeCustomKeyStores operation. + # + # resp = client.disconnect_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the custom key store. + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.disconnect_custom_key_store({ + # custom_key_store_id: "CustomKeyStoreIdType", # required + # }) + # @option params + # @overload disconnect_custom_key_store + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisconnectCustomKeyStore AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#4098 + def disconnect_custom_key_store(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Sets the key state of a KMS key to enabled. This allows you to use the + # KMS key for [cryptographic operations][1]. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][2] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:EnableKey][3] (key policy) + # + # **Related operations**: DisableKey + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To enable a KMS key + # + # # The following example enables the specified KMS key. + # + # resp = client.enable_key({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to enable. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.enable_key({ + # key_id: "KeyIdType", # required + # }) + # @option params + # @overload enable_key + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/EnableKey AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#4163 + def enable_key(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Enables [automatic rotation of the key material][1] of the specified + # symmetric encryption KMS key. + # + # By default, when you enable automatic rotation of a [customer managed + # KMS key][2], KMS rotates the key material of the KMS key one year + # (approximately 365 days) from the enable date and every year + # thereafter. You can use the optional `RotationPeriodInDays` parameter + # to specify a custom rotation period when you enable key rotation, or + # you can use `RotationPeriodInDays` to modify the rotation period of a + # key that you previously enabled automatic key rotation on. + # + # You can monitor rotation of the key material for your KMS keys in + # CloudTrail and Amazon CloudWatch. To disable rotation of the key + # material in a customer managed KMS key, use the DisableKeyRotation + # operation. You can use the GetKeyRotationStatus operation to identify + # any in progress rotations. You can use the ListKeyRotations operation + # to view the details of completed rotations. + # + # Automatic key rotation is supported only on [symmetric encryption KMS + # keys][3]. You cannot enable automatic rotation of [asymmetric KMS + # keys][4], [HMAC KMS keys][5], KMS keys with [imported key + # material][6], or KMS keys in a [custom key store][7]. To enable or + # disable automatic rotation of a set of related [multi-Region keys][8], + # set the property on the primary key. + # + # You cannot enable or disable automatic rotation of [Amazon Web + # Services managed KMS keys][9]. KMS always rotates the key material of + # Amazon Web Services managed keys every year. Rotation of [Amazon Web + # Services owned KMS keys][10] is managed by the Amazon Web Services + # service that owns the key. + # + # In May 2022, KMS changed the rotation schedule for Amazon Web Services + # managed keys from every three years (approximately 1,095 days) to + # every year (approximately 365 days). + # + # New Amazon Web Services managed keys are automatically rotated one + # year after they are created, and approximately every year thereafter. + # + # Existing Amazon Web Services managed keys are automatically rotated + # one year after their most recent rotation, and every year thereafter. + # + # + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][11] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:EnableKeyRotation][12] (key policy) + # + # **Related operations:** + # + # * DisableKeyRotation + # + # * GetKeyRotationStatus + # + # * ListKeyRotations + # + # * RotateKeyOnDemand + # + # You can perform on-demand (RotateKeyOnDemand) rotation of the key + # material in customer managed KMS keys, regardless of whether or not + # automatic key rotation is enabled. + # + # + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][13]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html#rotating-keys-enable-disable + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#symmetric-cmks + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-manage.html#multi-region-rotate + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-owned-cmk + # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [12]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [13]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To enable automatic rotation of key material + # + # # The following example enables automatic rotation with a rotation period of 365 days for the specified KMS key. + # + # resp = client.enable_key_rotation({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose key material will be automatically rotated. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # rotation_period_in_days: 365, # The number of days between each rotation date. Specify a value between 9 and 2560. If no value is specified, the default value is 365 days. + # }) + # @example Request syntax with placeholder values + # + # resp = client.enable_key_rotation({ + # key_id: "KeyIdType", # required + # rotation_period_in_days: 1, + # }) + # @option params + # @option params + # @overload enable_key_rotation + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/EnableKeyRotation AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#4324 + def enable_key_rotation(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Encrypts plaintext of up to 4,096 bytes using a KMS key. You can use a + # symmetric or asymmetric KMS key with a `KeyUsage` of + # `ENCRYPT_DECRYPT`. + # + # You can use this operation to encrypt small amounts of arbitrary data, + # such as a personal identifier or database password, or other sensitive + # information. You don't need to use the `Encrypt` operation to encrypt + # a data key. The GenerateDataKey and GenerateDataKeyPair operations + # return a plaintext data key and an encrypted copy of that data key. + # + # If you use a symmetric encryption KMS key, you can use an encryption + # context to add additional security to your encryption operation. If + # you specify an `EncryptionContext` when encrypting data, you must + # specify the same encryption context (a case-sensitive exact match) + # when decrypting the data. Otherwise, the request to decrypt fails with + # an `InvalidCiphertextException`. For more information, see [Encryption + # Context][1] in the *Key Management Service Developer Guide*. + # + # If you specify an asymmetric KMS key, you must also specify the + # encryption algorithm. The algorithm must be compatible with the KMS + # key spec. + # + # When you use an asymmetric KMS key to encrypt or reencrypt data, be + # sure to record the KMS key and encryption algorithm that you choose. + # You will be required to provide the same KMS key and encryption + # algorithm when you decrypt the data. If the KMS key and algorithm do + # not match the values used to encrypt the data, the decrypt operation + # fails. + # + # You are not required to supply the key ID and encryption algorithm + # when you decrypt with symmetric encryption KMS keys because KMS stores + # this information in the ciphertext blob. KMS cannot store metadata in + # ciphertext generated with asymmetric keys. The standard format for + # asymmetric key ciphertext does not include configurable fields. + # + # The maximum size of the data that you can encrypt varies with the type + # of KMS key and the encryption algorithm that you choose. + # + # * Symmetric encryption KMS keys + # + # * `SYMMETRIC_DEFAULT`: 4096 bytes + # + # ^ + # + # * `RSA_2048` + # + # * `RSAES_OAEP_SHA_1`: 214 bytes + # + # * `RSAES_OAEP_SHA_256`: 190 bytes + # + # * `RSA_3072` + # + # * `RSAES_OAEP_SHA_1`: 342 bytes + # + # * `RSAES_OAEP_SHA_256`: 318 bytes + # + # * `RSA_4096` + # + # * `RSAES_OAEP_SHA_1`: 470 bytes + # + # * `RSAES_OAEP_SHA_256`: 446 bytes + # + # * `SM2PKE`: 1024 bytes (China Regions only) + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][2] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:Encrypt][3] (key policy) + # + # **Related operations:** + # + # * Decrypt + # + # * GenerateDataKey + # + # * GenerateDataKeyPair + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To encrypt data with a symmetric encryption KMS key + # + # # The following example encrypts data with the specified symmetric encryption KMS key. + # + # resp = client.encrypt({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to use for encryption. You can use the key ID or Amazon Resource Name (ARN) of the KMS key, or the name or ARN of an alias that refers to the KMS key. + # plaintext: "", # The data to encrypt. + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_blob: "", # The encrypted data (ciphertext). + # encryption_algorithm: "SYMMETRIC_DEFAULT", # The encryption algorithm that was used in the operation. For symmetric encryption keys, the encryption algorithm is always SYMMETRIC_DEFAULT. + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that was used to encrypt the data. + # } + # @example Example: To encrypt data with an asymmetric encryption KMS key + # + # # The following example encrypts data with the specified RSA asymmetric KMS key. When you encrypt with an asymmetric key, + # # you must specify the encryption algorithm. + # + # resp = client.encrypt({ + # encryption_algorithm: "RSAES_OAEP_SHA_256", # The encryption algorithm to use in the operation. + # key_id: "0987dcba-09fe-87dc-65ba-ab0987654321", # The identifier of the KMS key to use for encryption. You can use the key ID or Amazon Resource Name (ARN) of the KMS key, or the name or ARN of an alias that refers to the KMS key. + # plaintext: "", # The data to encrypt. + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_blob: "", # The encrypted data (ciphertext). + # encryption_algorithm: "RSAES_OAEP_SHA_256", # The encryption algorithm that was used in the operation. + # key_id: "arn:aws:kms:us-west-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The ARN of the KMS key that was used to encrypt the data. + # } + # @example Request syntax with placeholder values + # + # resp = client.encrypt({ + # key_id: "KeyIdType", # required + # plaintext: "data", # required + # encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # grant_tokens: ["GrantTokenType"], + # encryption_algorithm: "SYMMETRIC_DEFAULT", # accepts SYMMETRIC_DEFAULT, RSAES_OAEP_SHA_1, RSAES_OAEP_SHA_256, SM2PKE + # dry_run: false, + # }) + # @example Response structure + # + # resp.ciphertext_blob #=> String + # resp.key_id #=> String + # resp.encryption_algorithm #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload encrypt + # @param params [Hash] ({}) + # @return [Types::EncryptResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::EncryptResponse#ciphertext_blob #ciphertext_blob} => String + # * {Types::EncryptResponse#key_id #key_id} => String + # * {Types::EncryptResponse#encryption_algorithm #encryption_algorithm} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/Encrypt AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#4575 + def encrypt(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a unique symmetric data key for use outside of KMS. This + # operation returns a plaintext copy of the data key and a copy that is + # encrypted under a symmetric encryption KMS key that you specify. The + # bytes in the plaintext key are random; they are not related to the + # caller or the KMS key. You can use the plaintext key to encrypt your + # data outside of KMS and store the encrypted data key with the + # encrypted data. + # + # To generate a data key, specify the symmetric encryption KMS key that + # will be used to encrypt the data key. You cannot use an asymmetric KMS + # key to encrypt data keys. To get the type of your KMS key, use the + # DescribeKey operation. + # + # You must also specify the length of the data key. Use either the + # `KeySpec` or `NumberOfBytes` parameters (but not both). For 128-bit + # and 256-bit data keys, use the `KeySpec` parameter. + # + # To generate a 128-bit SM4 data key (China Regions only), specify a + # `KeySpec` value of `AES_128` or a `NumberOfBytes` value of `16`. The + # symmetric encryption key used in China Regions to encrypt your data + # key is an SM4 encryption key. + # + # To get only an encrypted copy of the data key, use + # GenerateDataKeyWithoutPlaintext. To generate an asymmetric data key + # pair, use the GenerateDataKeyPair or + # GenerateDataKeyPairWithoutPlaintext operation. To get a + # cryptographically secure random byte string, use GenerateRandom. + # + # You can use an optional encryption context to add additional security + # to the encryption operation. If you specify an `EncryptionContext`, + # you must specify the same encryption context (a case-sensitive exact + # match) when decrypting the encrypted data key. Otherwise, the request + # to decrypt fails with an `InvalidCiphertextException`. For more + # information, see [Encryption Context][1] in the *Key Management + # Service Developer Guide*. + # + # `GenerateDataKey` also supports [Amazon Web Services Nitro + # Enclaves][2], which provide an isolated compute environment in Amazon + # EC2. To call `GenerateDataKey` for an Amazon Web Services Nitro + # enclave, use the [Amazon Web Services Nitro Enclaves SDK][3] or any + # Amazon Web Services SDK. Use the `Recipient` parameter to provide the + # attestation document for the enclave. `GenerateDataKey` returns a copy + # of the data key encrypted under the specified KMS key, as usual. But + # instead of a plaintext copy of the data key, the response includes a + # copy of the data key encrypted under the public key from the + # attestation document (`CiphertextForRecipient`). For information about + # the interaction between KMS and Amazon Web Services Nitro Enclaves, + # see [How Amazon Web Services Nitro Enclaves uses KMS][4] in the *Key + # Management Service Developer Guide*.. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][5] in the *Key + # Management Service Developer Guide*. + # + # **How to use your data key** + # + # We recommend that you use the following pattern to encrypt data + # locally in your application. You can write your own code or use a + # client-side encryption library, such as the [Amazon Web Services + # Encryption SDK][6], the [Amazon DynamoDB Encryption Client][7], or + # [Amazon S3 client-side encryption][8] to do these tasks for you. + # + # To encrypt data outside of KMS: + # + # 1. Use the `GenerateDataKey` operation to get a data key. + # + # 2. Use the plaintext data key (in the `Plaintext` field of the + # response) to encrypt your data outside of KMS. Then erase the + # plaintext data key from memory. + # + # 3. Store the encrypted data key (in the `CiphertextBlob` field of the + # response) with the encrypted data. + # + # To decrypt data outside of KMS: + # + # 1. Use the Decrypt operation to decrypt the encrypted data key. The + # operation returns a plaintext copy of the data key. + # + # 2. Use the plaintext data key to decrypt data outside of KMS, then + # erase the plaintext data key from memory. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:GenerateDataKey][9] (key policy) + # + # **Related operations:** + # + # * Decrypt + # + # * Encrypt + # + # * GenerateDataKeyPair + # + # * GenerateDataKeyPairWithoutPlaintext + # + # * GenerateDataKeyWithoutPlaintext + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][10]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context + # [2]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/nitro-enclave.html + # [3]: https://docs.aws.amazon.com/enclaves/latest/user/developing-applications.html#sdk + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/services-nitro-enclaves.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [6]: https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/ + # [7]: https://docs.aws.amazon.com/dynamodb-encryption-client/latest/devguide/ + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To generate a data key + # + # # The following example generates a 256-bit symmetric data encryption key (data key) in two formats. One is the + # # unencrypted (plainext) data key, and the other is the data key encrypted with the specified KMS key. + # + # resp = client.generate_data_key({ + # key_id: "alias/ExampleAlias", # The identifier of the KMS key to use to encrypt the data key. You can use the key ID or Amazon Resource Name (ARN) of the KMS key, or the name or ARN of an alias that refers to the KMS key. + # key_spec: "AES_256", # Specifies the type of data key to return. + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_blob: "", # The encrypted data key. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that was used to encrypt the data key. + # plaintext: "", # The unencrypted (plaintext) data key. + # } + # @example Example: To generate a data key pair for a Nitro enclave + # + # # The following example includes the Recipient parameter with a signed attestation document from an AWS Nitro enclave. + # # Instead of returning a copy of the data key encrypted by the KMS key and a plaintext copy of the data key, + # # GenerateDataKey returns one copy of the data key encrypted by the KMS key (CiphertextBlob) and one copy of the data key + # # encrypted by the public key from the attestation document (CiphertextForRecipient). The operation doesn't return a + # # plaintext data key. + # + # resp = client.generate_data_key({ + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # Identifies the KMS key used to encrypt the encrypted data key (CiphertextBlob) + # key_spec: "AES_256", # Specifies the type of data key to return + # recipient: { + # attestation_document: "", + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", + # }, # Specifies the attestation document from the Nitro enclave and the encryption algorithm to use with the public key from the attestation document + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_blob: "", # The data key encrypted by the specified KMS key + # ciphertext_for_recipient: "", # The plaintext data key encrypted by the public key from the attestation document + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The KMS key used to encrypt the CiphertextBlob (encrypted data key) + # plaintext: "", # This field is null or empty + # } + # @example Request syntax with placeholder values + # + # resp = client.generate_data_key({ + # key_id: "KeyIdType", # required + # encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # number_of_bytes: 1, + # key_spec: "AES_256", # accepts AES_256, AES_128 + # grant_tokens: ["GrantTokenType"], + # recipient: { + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", # accepts RSAES_OAEP_SHA_256 + # attestation_document: "data", + # }, + # dry_run: false, + # }) + # @example Response structure + # + # resp.ciphertext_blob #=> String + # resp.plaintext #=> String + # resp.key_id #=> String + # resp.ciphertext_for_recipient #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload generate_data_key + # @param params [Hash] ({}) + # @return [Types::GenerateDataKeyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GenerateDataKeyResponse#ciphertext_blob #ciphertext_blob} => String + # * {Types::GenerateDataKeyResponse#plaintext #plaintext} => String + # * {Types::GenerateDataKeyResponse#key_id #key_id} => String + # * {Types::GenerateDataKeyResponse#ciphertext_for_recipient #ciphertext_for_recipient} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKey AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#4890 + def generate_data_key(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a unique asymmetric data key pair for use outside of KMS. This + # operation returns a plaintext public key, a plaintext private key, and + # a copy of the private key that is encrypted under the symmetric + # encryption KMS key you specify. You can use the data key pair to + # perform asymmetric cryptography and implement digital signatures + # outside of KMS. The bytes in the keys are random; they are not related + # to the caller or to the KMS key that is used to encrypt the private + # key. + # + # You can use the public key that `GenerateDataKeyPair` returns to + # encrypt data or verify a signature outside of KMS. Then, store the + # encrypted private key with the data. When you are ready to decrypt + # data or sign a message, you can use the Decrypt operation to decrypt + # the encrypted private key. + # + # To generate a data key pair, you must specify a symmetric encryption + # KMS key to encrypt the private key in a data key pair. You cannot use + # an asymmetric KMS key or a KMS key in a custom key store. To get the + # type and origin of your KMS key, use the DescribeKey operation. + # + # Use the `KeyPairSpec` parameter to choose an RSA or Elliptic Curve + # (ECC) data key pair. In China Regions, you can also choose an SM2 data + # key pair. KMS recommends that you use ECC key pairs for signing, and + # use RSA and SM2 key pairs for either encryption or signing, but not + # both. However, KMS cannot enforce any restrictions on the use of data + # key pairs outside of KMS. + # + # If you are using the data key pair to encrypt data, or for any + # operation where you don't immediately need a private key, consider + # using the GenerateDataKeyPairWithoutPlaintext operation. + # `GenerateDataKeyPairWithoutPlaintext` returns a plaintext public key + # and an encrypted private key, but omits the plaintext private key that + # you need only to decrypt ciphertext or sign a message. Later, when you + # need to decrypt the data or sign a message, use the Decrypt operation + # to decrypt the encrypted private key in the data key pair. + # + # `GenerateDataKeyPair` returns a unique data key pair for each request. + # The bytes in the keys are random; they are not related to the caller + # or the KMS key that is used to encrypt the private key. The public key + # is a DER-encoded X.509 SubjectPublicKeyInfo, as specified in [RFC + # 5280][1]. The private key is a DER-encoded PKCS8 PrivateKeyInfo, as + # specified in [RFC 5958][2]. + # + # `GenerateDataKeyPair` also supports [Amazon Web Services Nitro + # Enclaves][3], which provide an isolated compute environment in Amazon + # EC2. To call `GenerateDataKeyPair` for an Amazon Web Services Nitro + # enclave, use the [Amazon Web Services Nitro Enclaves SDK][4] or any + # Amazon Web Services SDK. Use the `Recipient` parameter to provide the + # attestation document for the enclave. `GenerateDataKeyPair` returns + # the public data key and a copy of the private data key encrypted under + # the specified KMS key, as usual. But instead of a plaintext copy of + # the private data key (`PrivateKeyPlaintext`), the response includes a + # copy of the private data key encrypted under the public key from the + # attestation document (`CiphertextForRecipient`). For information about + # the interaction between KMS and Amazon Web Services Nitro Enclaves, + # see [How Amazon Web Services Nitro Enclaves uses KMS][5] in the *Key + # Management Service Developer Guide*.. + # + # You can use an optional encryption context to add additional security + # to the encryption operation. If you specify an `EncryptionContext`, + # you must specify the same encryption context (a case-sensitive exact + # match) when decrypting the encrypted data key. Otherwise, the request + # to decrypt fails with an `InvalidCiphertextException`. For more + # information, see [Encryption Context][6] in the *Key Management + # Service Developer Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][7] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:GenerateDataKeyPair][8] (key policy) + # + # **Related operations:** + # + # * Decrypt + # + # * Encrypt + # + # * GenerateDataKey + # + # * GenerateDataKeyPairWithoutPlaintext + # + # * GenerateDataKeyWithoutPlaintext + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][9]. + # + # + # + # [1]: https://tools.ietf.org/html/rfc5280 + # [2]: https://tools.ietf.org/html/rfc5958 + # [3]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/nitro-enclave.html + # [4]: https://docs.aws.amazon.com/enclaves/latest/user/developing-applications.html#sdk + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/services-nitro-enclaves.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To generate an RSA key pair for encryption and decryption + # + # # This example generates an RSA data key pair for encryption and decryption. The operation returns a plaintext public key + # # and private key, and a copy of the private key that is encrypted under a symmetric encryption KMS key that you specify. + # + # resp = client.generate_data_key_pair({ + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ID of the symmetric encryption KMS key that encrypts the private RSA key in the data key pair. + # key_pair_spec: "RSA_3072", # The requested key spec of the RSA data key pair. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ARN of the symmetric encryption KMS key that was used to encrypt the private key. + # key_pair_spec: "RSA_3072", # The actual key spec of the RSA data key pair. + # private_key_ciphertext_blob: "", # The encrypted private key of the RSA data key pair. + # private_key_plaintext: "", # The plaintext private key of the RSA data key pair. + # public_key: "", # The public key (plaintext) of the RSA data key pair. + # } + # @example Example: To generate a data key pair for a Nitro enclave + # + # # The following example includes the Recipient parameter with a signed attestation document from an AWS Nitro enclave. + # # Instead of returning a plaintext copy of the private data key, GenerateDataKeyPair returns a copy of the private data + # # key encrypted by the public key from the attestation document (CiphertextForRecipient). It returns the public data key + # # (PublicKey) and a copy of private data key encrypted under the specified KMS key (PrivateKeyCiphertextBlob), as usual, + # # but plaintext private data key field (PrivateKeyPlaintext) is null or empty. + # + # resp = client.generate_data_key_pair({ + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ID of the symmetric encryption KMS key that encrypts the private RSA key in the data key pair. + # key_pair_spec: "RSA_3072", # The requested key spec of the RSA data key pair. + # recipient: { + # attestation_document: "", + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", + # }, # Specifies the attestation document from the Nitro enclave and the encryption algorithm to use with the public key from the attestation document. + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_for_recipient: "", # The private key of the RSA data key pair encrypted by the public key from the attestation document + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ARN of the symmetric encryption KMS key that was used to encrypt the PrivateKeyCiphertextBlob. + # key_pair_spec: "RSA_3072", # The actual key spec of the RSA data key pair. + # private_key_ciphertext_blob: "", # The private key of the RSA data key pair encrypted by the KMS key. + # private_key_plaintext: "", # This field is null or empty + # public_key: "", # The public key (plaintext) of the RSA data key pair. + # } + # @example Request syntax with placeholder values + # + # resp = client.generate_data_key_pair({ + # encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # key_id: "KeyIdType", # required + # key_pair_spec: "RSA_2048", # required, accepts RSA_2048, RSA_3072, RSA_4096, ECC_NIST_P256, ECC_NIST_P384, ECC_NIST_P521, ECC_SECG_P256K1, SM2 + # grant_tokens: ["GrantTokenType"], + # recipient: { + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", # accepts RSAES_OAEP_SHA_256 + # attestation_document: "data", + # }, + # dry_run: false, + # }) + # @example Response structure + # + # resp.private_key_ciphertext_blob #=> String + # resp.private_key_plaintext #=> String + # resp.public_key #=> String + # resp.key_id #=> String + # resp.key_pair_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SM2" + # resp.ciphertext_for_recipient #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload generate_data_key_pair + # @param params [Hash] ({}) + # @return [Types::GenerateDataKeyPairResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GenerateDataKeyPairResponse#private_key_ciphertext_blob #private_key_ciphertext_blob} => String + # * {Types::GenerateDataKeyPairResponse#private_key_plaintext #private_key_plaintext} => String + # * {Types::GenerateDataKeyPairResponse#public_key #public_key} => String + # * {Types::GenerateDataKeyPairResponse#key_id #key_id} => String + # * {Types::GenerateDataKeyPairResponse#key_pair_spec #key_pair_spec} => String + # * {Types::GenerateDataKeyPairResponse#ciphertext_for_recipient #ciphertext_for_recipient} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyPair AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#5196 + def generate_data_key_pair(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a unique asymmetric data key pair for use outside of KMS. This + # operation returns a plaintext public key and a copy of the private key + # that is encrypted under the symmetric encryption KMS key you specify. + # Unlike GenerateDataKeyPair, this operation does not return a plaintext + # private key. The bytes in the keys are random; they are not related to + # the caller or to the KMS key that is used to encrypt the private key. + # + # You can use the public key that `GenerateDataKeyPairWithoutPlaintext` + # returns to encrypt data or verify a signature outside of KMS. Then, + # store the encrypted private key with the data. When you are ready to + # decrypt data or sign a message, you can use the Decrypt operation to + # decrypt the encrypted private key. + # + # To generate a data key pair, you must specify a symmetric encryption + # KMS key to encrypt the private key in a data key pair. You cannot use + # an asymmetric KMS key or a KMS key in a custom key store. To get the + # type and origin of your KMS key, use the DescribeKey operation. + # + # Use the `KeyPairSpec` parameter to choose an RSA or Elliptic Curve + # (ECC) data key pair. In China Regions, you can also choose an SM2 data + # key pair. KMS recommends that you use ECC key pairs for signing, and + # use RSA and SM2 key pairs for either encryption or signing, but not + # both. However, KMS cannot enforce any restrictions on the use of data + # key pairs outside of KMS. + # + # `GenerateDataKeyPairWithoutPlaintext` returns a unique data key pair + # for each request. The bytes in the key are not related to the caller + # or KMS key that is used to encrypt the private key. The public key is + # a DER-encoded X.509 SubjectPublicKeyInfo, as specified in [RFC + # 5280][1]. + # + # You can use an optional encryption context to add additional security + # to the encryption operation. If you specify an `EncryptionContext`, + # you must specify the same encryption context (a case-sensitive exact + # match) when decrypting the encrypted data key. Otherwise, the request + # to decrypt fails with an `InvalidCiphertextException`. For more + # information, see [Encryption Context][2] in the *Key Management + # Service Developer Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][3] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:GenerateDataKeyPairWithoutPlaintext][4] + # (key policy) + # + # **Related operations:** + # + # * Decrypt + # + # * Encrypt + # + # * GenerateDataKey + # + # * GenerateDataKeyPair + # + # * GenerateDataKeyWithoutPlaintext + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://tools.ietf.org/html/rfc5280 + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To generate an asymmetric data key pair without a plaintext key + # + # # This example returns an asymmetric elliptic curve (ECC) data key pair. The private key is encrypted under the symmetric + # # encryption KMS key that you specify. This operation doesn't return a plaintext (unencrypted) private key. + # + # resp = client.generate_data_key_pair_without_plaintext({ + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The symmetric encryption KMS key that encrypts the private key of the ECC data key pair. + # key_pair_spec: "ECC_NIST_P521", # The requested key spec of the ECC asymmetric data key pair. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ARN of the symmetric encryption KMS key that encrypted the private key in the ECC asymmetric data key pair. + # key_pair_spec: "ECC_NIST_P521", # The actual key spec of the ECC asymmetric data key pair. + # private_key_ciphertext_blob: "", # The encrypted private key of the asymmetric ECC data key pair. + # public_key: "", # The public key (plaintext). + # } + # @example Request syntax with placeholder values + # + # resp = client.generate_data_key_pair_without_plaintext({ + # encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # key_id: "KeyIdType", # required + # key_pair_spec: "RSA_2048", # required, accepts RSA_2048, RSA_3072, RSA_4096, ECC_NIST_P256, ECC_NIST_P384, ECC_NIST_P521, ECC_SECG_P256K1, SM2 + # grant_tokens: ["GrantTokenType"], + # dry_run: false, + # }) + # @example Response structure + # + # resp.private_key_ciphertext_blob #=> String + # resp.public_key #=> String + # resp.key_id #=> String + # resp.key_pair_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SM2" + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload generate_data_key_pair_without_plaintext + # @param params [Hash] ({}) + # @return [Types::GenerateDataKeyPairWithoutPlaintextResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GenerateDataKeyPairWithoutPlaintextResponse#private_key_ciphertext_blob #private_key_ciphertext_blob} => String + # * {Types::GenerateDataKeyPairWithoutPlaintextResponse#public_key #public_key} => String + # * {Types::GenerateDataKeyPairWithoutPlaintextResponse#key_id #key_id} => String + # * {Types::GenerateDataKeyPairWithoutPlaintextResponse#key_pair_spec #key_pair_spec} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyPairWithoutPlaintext AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#5404 + def generate_data_key_pair_without_plaintext(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a unique symmetric data key for use outside of KMS. This + # operation returns a data key that is encrypted under a symmetric + # encryption KMS key that you specify. The bytes in the key are random; + # they are not related to the caller or to the KMS key. + # + # `GenerateDataKeyWithoutPlaintext` is identical to the GenerateDataKey + # operation except that it does not return a plaintext copy of the data + # key. + # + # This operation is useful for systems that need to encrypt data at some + # point, but not immediately. When you need to encrypt the data, you + # call the Decrypt operation on the encrypted copy of the key. + # + # It's also useful in distributed systems with different levels of + # trust. For example, you might store encrypted data in containers. One + # component of your system creates new containers and stores an + # encrypted data key with each container. Then, a different component + # puts the data into the containers. That component first decrypts the + # data key, uses the plaintext data key to encrypt data, puts the + # encrypted data into the container, and then destroys the plaintext + # data key. In this system, the component that creates the containers + # never sees the plaintext data key. + # + # To request an asymmetric data key pair, use the GenerateDataKeyPair or + # GenerateDataKeyPairWithoutPlaintext operations. + # + # To generate a data key, you must specify the symmetric encryption KMS + # key that is used to encrypt the data key. You cannot use an asymmetric + # KMS key or a key in a custom key store to generate a data key. To get + # the type of your KMS key, use the DescribeKey operation. + # + # You must also specify the length of the data key. Use either the + # `KeySpec` or `NumberOfBytes` parameters (but not both). For 128-bit + # and 256-bit data keys, use the `KeySpec` parameter. + # + # To generate an SM4 data key (China Regions only), specify a `KeySpec` + # value of `AES_128` or `NumberOfBytes` value of `16`. The symmetric + # encryption key used in China Regions to encrypt your data key is an + # SM4 encryption key. + # + # If the operation succeeds, you will find the encrypted copy of the + # data key in the `CiphertextBlob` field. + # + # You can use an optional encryption context to add additional security + # to the encryption operation. If you specify an `EncryptionContext`, + # you must specify the same encryption context (a case-sensitive exact + # match) when decrypting the encrypted data key. Otherwise, the request + # to decrypt fails with an `InvalidCiphertextException`. For more + # information, see [Encryption Context][1] in the *Key Management + # Service Developer Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][2] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:GenerateDataKeyWithoutPlaintext][3] + # (key policy) + # + # **Related operations:** + # + # * Decrypt + # + # * Encrypt + # + # * GenerateDataKey + # + # * GenerateDataKeyPair + # + # * GenerateDataKeyPairWithoutPlaintext + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To generate an encrypted data key + # + # # The following example generates an encrypted copy of a 256-bit symmetric data encryption key (data key). The data key is + # # encrypted with the specified KMS key. + # + # resp = client.generate_data_key_without_plaintext({ + # key_id: "alias/ExampleAlias", # The identifier of the KMS key to use to encrypt the data key. You can use the key ID or Amazon Resource Name (ARN) of the KMS key, or the name or ARN of an alias that refers to the KMS key. + # key_spec: "AES_256", # Specifies the type of data key to return. + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_blob: "", # The encrypted data key. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that was used to encrypt the data key. + # } + # @example Request syntax with placeholder values + # + # resp = client.generate_data_key_without_plaintext({ + # key_id: "KeyIdType", # required + # encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # key_spec: "AES_256", # accepts AES_256, AES_128 + # number_of_bytes: 1, + # grant_tokens: ["GrantTokenType"], + # dry_run: false, + # }) + # @example Response structure + # + # resp.ciphertext_blob #=> String + # resp.key_id #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload generate_data_key_without_plaintext + # @param params [Hash] ({}) + # @return [Types::GenerateDataKeyWithoutPlaintextResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GenerateDataKeyWithoutPlaintextResponse#ciphertext_blob #ciphertext_blob} => String + # * {Types::GenerateDataKeyWithoutPlaintextResponse#key_id #key_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyWithoutPlaintext AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#5619 + def generate_data_key_without_plaintext(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Generates a hash-based message authentication code (HMAC) for a + # message using an HMAC KMS key and a MAC algorithm that the key + # supports. HMAC KMS keys and the HMAC algorithms that KMS uses conform + # to industry standards defined in [RFC 2104][1]. + # + # You can use value that GenerateMac returns in the VerifyMac operation + # to demonstrate that the original message has not changed. Also, + # because a secret key is used to create the hash, you can verify that + # the party that generated the hash has the required secret key. You can + # also use the raw result to implement HMAC-based algorithms such as key + # derivation functions. This operation is part of KMS support for HMAC + # KMS keys. For details, see [HMAC keys in KMS][2] in the Key + # Management Service Developer Guide . + # + # Best practices recommend that you limit the time during which any + # signing mechanism, including an HMAC, is effective. This deters an + # attack where the actor uses a signed message to establish validity + # repeatedly or long after the message is superseded. HMAC tags do not + # include a timestamp, but you can include a timestamp in the token or + # message to help you detect when its time to refresh the HMAC. + # + # + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][3] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:GenerateMac][4] (key policy) + # + # **Related operations**: VerifyMac + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://datatracker.ietf.org/doc/html/rfc2104 + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To generate an HMAC for a message + # + # # This example generates an HMAC for a message, an HMAC KMS key, and a MAC algorithm. The algorithm must be supported by + # # the specified HMAC KMS key. + # + # resp = client.generate_mac({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The HMAC KMS key input to the HMAC algorithm. + # mac_algorithm: "HMAC_SHA_384", # The HMAC algorithm requested for the operation. + # message: "Hello World", # The message input to the HMAC algorithm. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ARN of the HMAC KMS key used in the operation. + # mac: "", # The HMAC tag that results from this operation. + # mac_algorithm: "HMAC_SHA_384", # The HMAC algorithm used in the operation. + # } + # @example Request syntax with placeholder values + # + # resp = client.generate_mac({ + # message: "data", # required + # key_id: "KeyIdType", # required + # mac_algorithm: "HMAC_SHA_224", # required, accepts HMAC_SHA_224, HMAC_SHA_256, HMAC_SHA_384, HMAC_SHA_512 + # grant_tokens: ["GrantTokenType"], + # dry_run: false, + # }) + # @example Response structure + # + # resp.mac #=> String + # resp.mac_algorithm #=> String, one of "HMAC_SHA_224", "HMAC_SHA_256", "HMAC_SHA_384", "HMAC_SHA_512" + # resp.key_id #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload generate_mac + # @param params [Hash] ({}) + # @return [Types::GenerateMacResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GenerateMacResponse#mac #mac} => String + # * {Types::GenerateMacResponse#mac_algorithm #mac_algorithm} => String + # * {Types::GenerateMacResponse#key_id #key_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateMac AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#5765 + def generate_mac(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a random byte string that is cryptographically secure. + # + # You must use the `NumberOfBytes` parameter to specify the length of + # the random byte string. There is no default value for string length. + # + # By default, the random byte string is generated in KMS. To generate + # the byte string in the CloudHSM cluster associated with an CloudHSM + # key store, use the `CustomKeyStoreId` parameter. + # + # `GenerateRandom` also supports [Amazon Web Services Nitro + # Enclaves][1], which provide an isolated compute environment in Amazon + # EC2. To call `GenerateRandom` for a Nitro enclave, use the [Amazon Web + # Services Nitro Enclaves SDK][2] or any Amazon Web Services SDK. Use + # the `Recipient` parameter to provide the attestation document for the + # enclave. Instead of plaintext bytes, the response includes the + # plaintext bytes encrypted under the public key from the attestation + # document (`CiphertextForRecipient`).For information about the + # interaction between KMS and Amazon Web Services Nitro Enclaves, see + # [How Amazon Web Services Nitro Enclaves uses KMS][3] in the *Key + # Management Service Developer Guide*. + # + # For more information about entropy and random number generation, see + # [Key Management Service Cryptographic Details][4]. + # + # **Cross-account use**: Not applicable. `GenerateRandom` does not use + # any account-specific resources, such as KMS keys. + # + # **Required permissions**: [kms:GenerateRandom][5] (IAM policy) + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][6]. + # + # + # + # [1]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/nitro-enclave.html + # [2]: https://docs.aws.amazon.com/enclaves/latest/user/developing-applications.html#sdk + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/services-nitro-enclaves.html + # [4]: https://docs.aws.amazon.com/kms/latest/cryptographic-details/ + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To generate random data + # + # # The following example generates 32 bytes of random data. + # + # resp = client.generate_random({ + # number_of_bytes: 32, # The length of the random data, specified in number of bytes. + # }) + # + # resp.to_h outputs the following: + # { + # plaintext: "", # The random data. + # } + # @example Example: To generate random data + # + # # The following example includes the Recipient parameter with a signed attestation document from an AWS Nitro enclave. + # # Instead of returning a plaintext (unencrypted) byte string, GenerateRandom returns the byte string encrypted by the + # # public key from the enclave's attestation document. + # + # resp = client.generate_random({ + # number_of_bytes: 1024, # The length of the random byte string + # recipient: { + # attestation_document: "", + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", + # }, # Specifies the attestation document from the Nitro enclave and the encryption algorithm to use with the public key from the attestation document + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_for_recipient: "", # The random data encrypted under the public key from the attestation document + # plaintext: "", # This field is null or empty + # } + # @example Request syntax with placeholder values + # + # resp = client.generate_random({ + # number_of_bytes: 1, + # custom_key_store_id: "CustomKeyStoreIdType", + # recipient: { + # key_encryption_algorithm: "RSAES_OAEP_SHA_256", # accepts RSAES_OAEP_SHA_256 + # attestation_document: "data", + # }, + # }) + # @example Response structure + # + # resp.plaintext #=> String + # resp.ciphertext_for_recipient #=> String + # @option params + # @option params + # @option params + # @overload generate_random + # @param params [Hash] ({}) + # @return [Types::GenerateRandomResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GenerateRandomResponse#plaintext #plaintext} => String + # * {Types::GenerateRandomResponse#ciphertext_for_recipient #ciphertext_for_recipient} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateRandom AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#5908 + def generate_random(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Gets a key policy attached to the specified KMS key. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:GetKeyPolicy][1] (key policy) + # + # **Related operations**: [PutKeyPolicy][2] + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][3]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [2]: https://docs.aws.amazon.com/kms/latest/APIReference/API_PutKeyPolicy.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To retrieve a key policy + # + # # The following example retrieves the key policy for the specified KMS key. + # + # resp = client.get_key_policy({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose key policy you want to retrieve. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # policy_name: "default", # The name of the key policy to retrieve. + # }) + # + # resp.to_h outputs the following: + # { + # policy: "{\n \"Version\" : \"2012-10-17\",\n \"Id\" : \"key-default-1\",\n \"Statement\" : [ {\n \"Sid\" : \"Enable IAM User Permissions\",\n \"Effect\" : \"Allow\",\n \"Principal\" : {\n \"AWS\" : \"arn:aws:iam::111122223333:root\"\n },\n \"Action\" : \"kms:*\",\n \"Resource\" : \"*\"\n } ]\n}", # The key policy document. + # } + # @example Request syntax with placeholder values + # + # resp = client.get_key_policy({ + # key_id: "KeyIdType", # required + # policy_name: "PolicyNameType", + # }) + # @example Response structure + # + # resp.policy #=> String + # resp.policy_name #=> String + # @option params + # @option params + # @overload get_key_policy + # @param params [Hash] ({}) + # @return [Types::GetKeyPolicyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetKeyPolicyResponse#policy #policy} => String + # * {Types::GetKeyPolicyResponse#policy_name #policy_name} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetKeyPolicy AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#5987 + def get_key_policy(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Provides detailed information about the rotation status for a KMS key, + # including whether [automatic rotation of the key material][1] is + # enabled for the specified KMS key, the [rotation period][2], and the + # next scheduled rotation date. + # + # Automatic key rotation is supported only on [symmetric encryption KMS + # keys][3]. You cannot enable automatic rotation of [asymmetric KMS + # keys][4], [HMAC KMS keys][5], KMS keys with [imported key + # material][6], or KMS keys in a [custom key store][7]. To enable or + # disable automatic rotation of a set of related [multi-Region keys][8], + # set the property on the primary key.. + # + # You can enable (EnableKeyRotation) and disable automatic rotation + # (DisableKeyRotation) of the key material in customer managed KMS keys. + # Key material rotation of [Amazon Web Services managed KMS keys][9] is + # not configurable. KMS always rotates the key material in Amazon Web + # Services managed KMS keys every year. The key rotation status for + # Amazon Web Services managed KMS keys is always `true`. + # + # You can perform on-demand (RotateKeyOnDemand) rotation of the key + # material in customer managed KMS keys, regardless of whether or not + # automatic key rotation is enabled. You can use GetKeyRotationStatus to + # identify the date and time that an in progress on-demand rotation was + # initiated. You can use ListKeyRotations to view the details of + # completed rotations. + # + # In May 2022, KMS changed the rotation schedule for Amazon Web Services + # managed keys from every three years to every year. For details, see + # EnableKeyRotation. + # + # + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][10] in the *Key + # Management Service Developer Guide*. + # + # * Disabled: The key rotation status does not change when you disable a + # KMS key. However, while the KMS key is disabled, KMS does not rotate + # the key material. When you re-enable the KMS key, rotation resumes. + # If the key material in the re-enabled KMS key hasn't been rotated + # in one year, KMS rotates it immediately, and every year thereafter. + # If it's been less than a year since the key material in the + # re-enabled KMS key was rotated, the KMS key resumes its prior + # rotation schedule. + # + # * Pending deletion: While a KMS key is pending deletion, its key + # rotation status is `false` and KMS does not rotate the key material. + # If you cancel the deletion, the original key rotation status returns + # to `true`. + # + # **Cross-account use**: Yes. To perform this operation on a KMS key in + # a different Amazon Web Services account, specify the key ARN in the + # value of the `KeyId` parameter. + # + # **Required permissions**: [kms:GetKeyRotationStatus][11] (key policy) + # + # **Related operations:** + # + # * DisableKeyRotation + # + # * EnableKeyRotation + # + # * ListKeyRotations + # + # * RotateKeyOnDemand + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][12]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html#rotation-period + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#symmetric-cmks + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-manage.html#multi-region-rotate + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [12]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To retrieve the rotation status for a KMS key + # + # # The following example retrieves detailed information about the rotation status for a KMS key, including whether + # # automatic key rotation is enabled for the specified KMS key, the rotation period, and the next scheduled rotation date. + # + # resp = client.get_key_rotation_status({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose key material rotation status you want to retrieve. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # Identifies the specified symmetric encryption KMS key. + # key_rotation_enabled: true, # A boolean that indicates the key material rotation status. Returns true when automatic rotation of the key material is enabled, or false when it is not. + # next_rotation_date: Time.parse("2024-04-05T15:14:47.757000+00:00"), # The next date that the key material will be automatically rotated. + # on_demand_rotation_start_date: Time.parse("2024-03-02T10:11:36.564000+00:00"), # Identifies the date and time that an in progress on-demand rotation was initiated. + # rotation_period_in_days: 365, # The number of days between each automatic rotation. The default value is 365 days. + # } + # @example Request syntax with placeholder values + # + # resp = client.get_key_rotation_status({ + # key_id: "KeyIdType", # required + # }) + # @example Response structure + # + # resp.key_rotation_enabled #=> Boolean + # resp.key_id #=> String + # resp.rotation_period_in_days #=> Integer + # resp.next_rotation_date #=> Time + # resp.on_demand_rotation_start_date #=> Time + # @option params + # @overload get_key_rotation_status + # @param params [Hash] ({}) + # @return [Types::GetKeyRotationStatusResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetKeyRotationStatusResponse#key_rotation_enabled #key_rotation_enabled} => Boolean + # * {Types::GetKeyRotationStatusResponse#key_id #key_id} => String + # * {Types::GetKeyRotationStatusResponse#rotation_period_in_days #rotation_period_in_days} => Integer + # * {Types::GetKeyRotationStatusResponse#next_rotation_date #next_rotation_date} => Time + # * {Types::GetKeyRotationStatusResponse#on_demand_rotation_start_date #on_demand_rotation_start_date} => Time + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetKeyRotationStatus AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#6137 + def get_key_rotation_status(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns the public key and an import token you need to import or + # reimport key material for a KMS key. + # + # By default, KMS keys are created with key material that KMS generates. + # This operation supports [Importing key material][1], an advanced + # feature that lets you generate and import the cryptographic key + # material for a KMS key. For more information about importing key + # material into KMS, see [Importing key material][1] in the *Key + # Management Service Developer Guide*. + # + # Before calling `GetParametersForImport`, use the CreateKey operation + # with an `Origin` value of `EXTERNAL` to create a KMS key with no key + # material. You can import key material for a symmetric encryption KMS + # key, HMAC KMS key, asymmetric encryption KMS key, or asymmetric + # signing KMS key. You can also import key material into a [multi-Region + # key][2] of any supported type. However, you can't import key material + # into a KMS key in a [custom key store][3]. You can also use + # `GetParametersForImport` to get a public key and import token to + # [reimport the original key material][4] into a KMS key whose key + # material expired or was deleted. + # + # `GetParametersForImport` returns the items that you need to import + # your key material. + # + # * The public key (or "wrapping key") of an RSA key pair that KMS + # generates. + # + # You will use this public key to encrypt ("wrap") your key material + # while it's in transit to KMS. + # + # * A import token that ensures that KMS can decrypt your key material + # and associate it with the correct KMS key. + # + # The public key and its import token are permanently linked and must be + # used together. Each public key and import token set is valid for 24 + # hours. The expiration date and time appear in the `ParametersValidTo` + # field in the `GetParametersForImport` response. You cannot use an + # expired public key or import token in an ImportKeyMaterial request. If + # your key and token expire, send another `GetParametersForImport` + # request. + # + # `GetParametersForImport` requires the following information: + # + # * The key ID of the KMS key for which you are importing the key + # material. + # + # * The key spec of the public key ("wrapping key") that you will use + # to encrypt your key material during import. + # + # * The wrapping algorithm that you will use with the public key to + # encrypt your key material. + # + # You can use the same or a different public key spec and wrapping + # algorithm each time you import or reimport the same key material. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][5] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:GetParametersForImport][6] (key policy) + # + # **Related operations:** + # + # * ImportKeyMaterial + # + # * DeleteImportedKeyMaterial + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][7]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html#reimport-key-material + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To download the public key and import token for a symmetric encryption KMS key + # + # # The following example downloads a public key and import token to import symmetric encryption key material. It uses the + # # default wrapping key spec and the RSAES_OAEP_SHA_256 wrapping algorithm. + # + # resp = client.get_parameters_for_import({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key that will be associated with the imported key material. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # wrapping_algorithm: "RSAES_OAEP_SHA_1", # The algorithm that you will use to encrypt the key material before importing it. + # wrapping_key_spec: "RSA_2048", # The type of wrapping key (public key) to return in the response. + # }) + # + # resp.to_h outputs the following: + # { + # import_token: "", # The import token to send with a subsequent ImportKeyMaterial request. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that will be associated with the imported key material. + # parameters_valid_to: Time.parse("2023-02-01T14:52:17-08:00"), # The date and time when the import token and public key expire. After this time, call GetParametersForImport again. + # public_key: "", # The public key to use to encrypt the key material before importing it. + # } + # @example Example: To download the public key and import token for an RSA asymmetric KMS key + # + # # The following example downloads a public key and import token to import an RSA private key. It uses a required RSA_AES + # # wrapping algorithm and the largest supported private key. + # + # resp = client.get_parameters_for_import({ + # key_id: "arn:aws:kms:us-east-2:111122223333:key/8888abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key that will be associated with the imported key material. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # wrapping_algorithm: "RSA_AES_KEY_WRAP_SHA_256", # The algorithm that you will use to encrypt the key material before importing it. + # wrapping_key_spec: "RSA_4096", # The type of wrapping key (public key) to return in the response. + # }) + # + # resp.to_h outputs the following: + # { + # import_token: "", # The import token to send with a subsequent ImportKeyMaterial request. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/8888abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that will be associated with the imported key material. + # parameters_valid_to: Time.parse("2023-03-08T13:02:02-07:00"), # The date and time when the import token and public key expire. After this time, call GetParametersForImport again. + # public_key: "", # The public key to use to encrypt the key material before importing it. + # } + # @example Example: To download the public key and import token for an elliptic curve (ECC) asymmetric KMS key + # + # # The following example downloads a public key and import token to import an ECC_NIST_P521 (secp521r1) private key. You + # # cannot directly wrap this ECC key under an RSA_2048 public key, although you can use an RSA_2048 public key with an + # # RSA_AES wrapping algorithm to wrap any supported key material. This example requests an RSA_3072 public key for use with + # # the RSAES_OAEP_SHA_256. + # + # resp = client.get_parameters_for_import({ + # key_id: "arn:aws:kms:us-east-2:111122223333:key/9876abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key that will be associated with the imported key material. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # wrapping_algorithm: "RSAES_OAEP_SHA_256", # The algorithm that you will use to encrypt the key material before importing it. + # wrapping_key_spec: "RSA_3072", # The type of wrapping key (public key) to return in the response. + # }) + # + # resp.to_h outputs the following: + # { + # import_token: "", # The import token to send with a subsequent ImportKeyMaterial request. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/9876abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that will be associated with the imported key material. + # parameters_valid_to: Time.parse("2023-09-12T03:15:01-20:00"), # The date and time when the import token and public key expire. After this time, call GetParametersForImport again. + # public_key: "", # The public key to use to encrypt the key material before importing it. + # } + # @example Example: To download the public key and import token for an HMAC KMS key + # + # # The following example downloads a public key and import token to import an HMAC key. It uses the RSAES_OAEP_SHA_256 + # # wrapping algorithm and an RSA_4096 private key. + # + # resp = client.get_parameters_for_import({ + # key_id: "2468abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key that will be associated with the imported key material. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # wrapping_algorithm: "RSAES_OAEP_SHA_256", # The algorithm that you will use to encrypt the key material before importing it. + # wrapping_key_spec: "RSA_4096", # The type of wrapping key (public key) to return in the response. + # }) + # + # resp.to_h outputs the following: + # { + # import_token: "", # The import token to send with a subsequent ImportKeyMaterial request. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/2468abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that will be associated with the imported key material. + # parameters_valid_to: Time.parse("2023-04-02T13:02:02-07:00"), # The date and time when the import token and public key expire. After this time, call GetParametersForImport again. + # public_key: "", # The public key to use to encrypt the key material before importing it. + # } + # @example Request syntax with placeholder values + # + # resp = client.get_parameters_for_import({ + # key_id: "KeyIdType", # required + # wrapping_algorithm: "RSAES_PKCS1_V1_5", # required, accepts RSAES_PKCS1_V1_5, RSAES_OAEP_SHA_1, RSAES_OAEP_SHA_256, RSA_AES_KEY_WRAP_SHA_1, RSA_AES_KEY_WRAP_SHA_256, SM2PKE + # wrapping_key_spec: "RSA_2048", # required, accepts RSA_2048, RSA_3072, RSA_4096, SM2 + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.import_token #=> String + # resp.public_key #=> String + # resp.parameters_valid_to #=> Time + # @option params + # @option params + # @option params + # @overload get_parameters_for_import + # @param params [Hash] ({}) + # @return [Types::GetParametersForImportResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetParametersForImportResponse#key_id #key_id} => String + # * {Types::GetParametersForImportResponse#import_token #import_token} => String + # * {Types::GetParametersForImportResponse#public_key #public_key} => String + # * {Types::GetParametersForImportResponse#parameters_valid_to #parameters_valid_to} => Time + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetParametersForImport AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#6397 + def get_parameters_for_import(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns the public key of an asymmetric KMS key. Unlike the private + # key of a asymmetric KMS key, which never leaves KMS unencrypted, + # callers with `kms:GetPublicKey` permission can download the public key + # of an asymmetric KMS key. You can share the public key to allow others + # to encrypt messages and verify signatures outside of KMS. For + # information about asymmetric KMS keys, see [Asymmetric KMS keys][1] in + # the *Key Management Service Developer Guide*. + # + # You do not need to download the public key. Instead, you can use the + # public key within KMS by calling the Encrypt, ReEncrypt, or Verify + # operations with the identifier of an asymmetric KMS key. When you use + # the public key within KMS, you benefit from the authentication, + # authorization, and logging that are part of every KMS operation. You + # also reduce of risk of encrypting data that cannot be decrypted. These + # features are not effective outside of KMS. + # + # To help you use the public key safely outside of KMS, `GetPublicKey` + # returns important information about the public key in the response, + # including: + # + # * [KeySpec][2]: The type of key material in the public key, such as + # `RSA_4096` or `ECC_NIST_P521`. + # + # * [KeyUsage][3]: Whether the key is used for encryption, signing, or + # deriving a shared secret. + # + # * [EncryptionAlgorithms][4] or [SigningAlgorithms][5]: A list of the + # encryption algorithms or the signing algorithms for the key. + # + # Although KMS cannot enforce these restrictions on external operations, + # it is crucial that you use this information to prevent the public key + # from being used improperly. For example, you can prevent a public + # signing key from being used encrypt data, or prevent a public key from + # being used with an encryption algorithm that is not supported by KMS. + # You can also avoid errors, such as using the wrong signing algorithm + # in a verification operation. + # + # To verify a signature outside of KMS with an SM2 public key (China + # Regions only), you must specify the distinguishing ID. By default, KMS + # uses `1234567812345678` as the distinguishing ID. For more + # information, see [Offline verification with SM2 key pairs][6]. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][7] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:GetPublicKey][8] (key policy) + # + # **Related operations**: CreateKey + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][9]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [2]: https://docs.aws.amazon.com/kms/latest/APIReference/API_GetPublicKey.html#KMS-GetPublicKey-response-KeySpec + # [3]: https://docs.aws.amazon.com/kms/latest/APIReference/API_GetPublicKey.html#KMS-GetPublicKey-response-KeyUsage + # [4]: https://docs.aws.amazon.com/kms/latest/APIReference/API_GetPublicKey.html#KMS-GetPublicKey-response-EncryptionAlgorithms + # [5]: https://docs.aws.amazon.com/kms/latest/APIReference/API_GetPublicKey.html#KMS-GetPublicKey-response-SigningAlgorithms + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/asymmetric-key-specs.html#key-spec-sm-offline-verification + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To download the public key of an asymmetric KMS key + # + # # This example gets the public key of an asymmetric RSA KMS key used for encryption and decryption. The operation returns + # # the key spec, key usage, and encryption or signing algorithms to help you use the public key correctly outside of AWS + # # KMS. + # + # resp = client.get_public_key({ + # key_id: "arn:aws:kms:us-west-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The key ARN of the asymmetric KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # customer_master_key_spec: "RSA_4096", # The key spec of the asymmetric KMS key from which the public key was downloaded. + # encryption_algorithms: [ + # "RSAES_OAEP_SHA_1", + # "RSAES_OAEP_SHA_256", + # ], # The encryption algorithms supported by the asymmetric KMS key that was downloaded. + # key_id: "arn:aws:kms:us-west-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The key ARN of the asymmetric KMS key from which the public key was downloaded. + # key_usage: "ENCRYPT_DECRYPT", # The key usage of the asymmetric KMS key from which the public key was downloaded. + # public_key: "", # The public key (plaintext) of the asymmetric KMS key. + # } + # @example Request syntax with placeholder values + # + # resp = client.get_public_key({ + # key_id: "KeyIdType", # required + # grant_tokens: ["GrantTokenType"], + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.public_key #=> String + # resp.customer_master_key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.key_usage #=> String, one of "SIGN_VERIFY", "ENCRYPT_DECRYPT", "GENERATE_VERIFY_MAC", "KEY_AGREEMENT" + # resp.encryption_algorithms #=> Array + # resp.encryption_algorithms[0] #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # resp.signing_algorithms #=> Array + # resp.signing_algorithms[0] #=> String, one of "RSASSA_PSS_SHA_256", "RSASSA_PSS_SHA_384", "RSASSA_PSS_SHA_512", "RSASSA_PKCS1_V1_5_SHA_256", "RSASSA_PKCS1_V1_5_SHA_384", "RSASSA_PKCS1_V1_5_SHA_512", "ECDSA_SHA_256", "ECDSA_SHA_384", "ECDSA_SHA_512", "SM2DSA" + # resp.key_agreement_algorithms #=> Array + # resp.key_agreement_algorithms[0] #=> String, one of "ECDH" + # @option params + # @option params + # @overload get_public_key + # @param params [Hash] ({}) + # @return [Types::GetPublicKeyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetPublicKeyResponse#key_id #key_id} => String + # * {Types::GetPublicKeyResponse#public_key #public_key} => String + # * {Types::GetPublicKeyResponse#customer_master_key_spec #customer_master_key_spec} => String + # * {Types::GetPublicKeyResponse#key_spec #key_spec} => String + # * {Types::GetPublicKeyResponse#key_usage #key_usage} => String + # * {Types::GetPublicKeyResponse#encryption_algorithms #encryption_algorithms} => Array<String> + # * {Types::GetPublicKeyResponse#signing_algorithms #signing_algorithms} => Array<String> + # * {Types::GetPublicKeyResponse#key_agreement_algorithms #key_agreement_algorithms} => Array<String> + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetPublicKey AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#6565 + def get_public_key(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Imports or reimports key material into an existing KMS key that was + # created without key material. `ImportKeyMaterial` also sets the + # expiration model and expiration date of the imported key material. + # + # By default, KMS keys are created with key material that KMS generates. + # This operation supports [Importing key material][1], an advanced + # feature that lets you generate and import the cryptographic key + # material for a KMS key. For more information about importing key + # material into KMS, see [Importing key material][1] in the *Key + # Management Service Developer Guide*. + # + # After you successfully import key material into a KMS key, you can + # [reimport the same key material][2] into that KMS key, but you cannot + # import different key material. You might reimport key material to + # replace key material that expired or key material that you deleted. + # You might also reimport key material to change the expiration model or + # expiration date of the key material. + # + # Each time you import key material into KMS, you can determine whether + # (`ExpirationModel`) and when (`ValidTo`) the key material expires. To + # change the expiration of your key material, you must import it again, + # either by calling `ImportKeyMaterial` or using the [import + # features](kms/latest/developerguide/importing-keys-import-key-material.html#importing-keys-import-key-material-console) + # of the KMS console. + # + # Before calling `ImportKeyMaterial`: + # + # * Create or identify a KMS key with no key material. The KMS key must + # have an `Origin` value of `EXTERNAL`, which indicates that the KMS + # key is designed for imported key material. + # + # To create an new KMS key for imported key material, call the + # CreateKey operation with an `Origin` value of `EXTERNAL`. You can + # create a symmetric encryption KMS key, HMAC KMS key, asymmetric + # encryption KMS key, or asymmetric signing KMS key. You can also + # import key material into a [multi-Region + # key](kms/latest/developerguide/multi-region-keys-overview.html) of + # any supported type. However, you can't import key material into a + # KMS key in a [custom key + # store](kms/latest/developerguide/custom-key-store-overview.html). + # + # * Use the DescribeKey operation to verify that the `KeyState` of the + # KMS key is `PendingImport`, which indicates that the KMS key has no + # key material. + # + # If you are reimporting the same key material into an existing KMS + # key, you might need to call the DeleteImportedKeyMaterial to delete + # its existing key material. + # + # * Call the GetParametersForImport operation to get a public key and + # import token set for importing key material. + # + # * Use the public key in the GetParametersForImport response to encrypt + # your key material. + # + # Then, in an `ImportKeyMaterial` request, you submit your encrypted key + # material and import token. When calling this operation, you must + # specify the following values: + # + # * The key ID or key ARN of the KMS key to associate with the imported + # key material. Its `Origin` must be `EXTERNAL` and its `KeyState` + # must be `PendingImport`. You cannot perform this operation on a KMS + # key in a [custom key + # store](kms/latest/developerguide/custom-key-store-overview.html), or + # on a KMS key in a different Amazon Web Services account. To get the + # `Origin` and `KeyState` of a KMS key, call DescribeKey. + # + # * The encrypted key material. + # + # * The import token that GetParametersForImport returned. You must use + # a public key and token from the same `GetParametersForImport` + # response. + # + # * Whether the key material expires (`ExpirationModel`) and, if so, + # when (`ValidTo`). For help with this choice, see [Setting an + # expiration time][3] in the *Key Management Service Developer Guide*. + # + # If you set an expiration date, KMS deletes the key material from the + # KMS key on the specified date, making the KMS key unusable. To use + # the KMS key in cryptographic operations again, you must reimport the + # same key material. However, you can delete and reimport the key + # material at any time, including before the key material expires. + # Each time you reimport, you can eliminate or reset the expiration + # time. + # + # When this operation is successful, the key state of the KMS key + # changes from `PendingImport` to `Enabled`, and you can use the KMS key + # in cryptographic operations. + # + # If this operation fails, use the exception to help determine the + # problem. If the error is related to the key material, the import + # token, or wrapping key, use GetParametersForImport to get a new public + # key and import token for the KMS key and repeat the import procedure. + # For help, see [How To Import Key Material][4] in the *Key Management + # Service Developer Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][5] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:ImportKeyMaterial][6] (key policy) + # + # **Related operations:** + # + # * DeleteImportedKeyMaterial + # + # * GetParametersForImport + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][7]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html#reimport-key-material + # [3]: https://docs.aws.amazon.com/en_us/kms/latest/developerguide/importing-keys.html#importing-keys-expiration + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html#importing-keys-overview + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To import key material into a KMS key + # + # # The following example imports key material into the specified KMS key. + # + # resp = client.import_key_material({ + # encrypted_key_material: "", # The encrypted key material to import. + # expiration_model: "KEY_MATERIAL_DOES_NOT_EXPIRE", # A value that specifies whether the key material expires. + # import_token: "", # The import token that you received in the response to a previous GetParametersForImport request. + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to import the key material into. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Example: To import key material into a KMS key + # + # # The following example imports key material that expires in 3 days. It might be part of an application that frequently + # # reimports the same key material to comply with business rules or regulations. + # + # resp = client.import_key_material({ + # encrypted_key_material: "", # The encrypted key material to import. + # expiration_model: "KEY_MATERIAL_EXPIRES", # A value that specifies whether the key material expires. + # import_token: "", # The import token that you received in the response to a previous GetParametersForImport request. + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to import the key material into. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # valid_to: Time.parse("2023-09-30T00:00:00-00:00"), # Specifies the date and time when the imported key material expires. + # }) + # @example Request syntax with placeholder values + # + # resp = client.import_key_material({ + # key_id: "KeyIdType", # required + # import_token: "data", # required + # encrypted_key_material: "data", # required + # valid_to: Time.now, + # expiration_model: "KEY_MATERIAL_EXPIRES", # accepts KEY_MATERIAL_EXPIRES, KEY_MATERIAL_DOES_NOT_EXPIRE + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload import_key_material + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ImportKeyMaterial AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#6808 + def import_key_material(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Gets a list of aliases in the caller's Amazon Web Services account + # and region. For more information about aliases, see CreateAlias. + # + # By default, the `ListAliases` operation returns all aliases in the + # account and region. To get only the aliases associated with a + # particular KMS key, use the `KeyId` parameter. + # + # The `ListAliases` response can include aliases that you created and + # associated with your customer managed keys, and aliases that Amazon + # Web Services created and associated with Amazon Web Services managed + # keys in your account. You can recognize Amazon Web Services aliases + # because their names have the format `aws/`, such as + # `aws/dynamodb`. + # + # The response might also include aliases that have no `TargetKeyId` + # field. These are predefined aliases that Amazon Web Services has + # created but has not yet associated with a KMS key. Aliases that Amazon + # Web Services creates in your account, including predefined aliases, do + # not count against your [KMS aliases quota][1]. + # + # **Cross-account use**: No. `ListAliases` does not return aliases in + # other Amazon Web Services accounts. + # + # **Required permissions**: [kms:ListAliases][2] (IAM policy) + # + # For details, see [Controlling access to aliases][3] in the *Key + # Management Service Developer Guide*. + # + # **Related operations:** + # + # * CreateAlias + # + # * DeleteAlias + # + # * UpdateAlias + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/limits.html#aliases-limit + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list aliases + # + # # The following example lists aliases. + # + # resp = client.list_aliases({ + # }) + # + # resp.to_h outputs the following: + # { + # aliases: [ + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/acm", + # alias_name: "alias/aws/acm", + # target_key_id: "da03f6f7-d279-427a-9cae-de48d07e5b66", + # }, + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/ebs", + # alias_name: "alias/aws/ebs", + # target_key_id: "25a217e7-7170-4b8c-8bf6-045ea5f70e5b", + # }, + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/rds", + # alias_name: "alias/aws/rds", + # target_key_id: "7ec3104e-c3f2-4b5c-bf42-bfc4772c6685", + # }, + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/redshift", + # alias_name: "alias/aws/redshift", + # target_key_id: "08f7a25a-69e2-4fb5-8f10-393db27326fa", + # }, + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/s3", + # alias_name: "alias/aws/s3", + # target_key_id: "d2b0f1a3-580d-4f79-b836-bc983be8cfa5", + # }, + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/example1", + # alias_name: "alias/example1", + # target_key_id: "4da1e216-62d0-46c5-a7c0-5f3a3d2f8046", + # }, + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/example2", + # alias_name: "alias/example2", + # target_key_id: "f32fef59-2cc2-445b-8573-2d73328acbee", + # }, + # { + # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/example3", + # alias_name: "alias/example3", + # target_key_id: "1374ef38-d34e-4d5f-b2c9-4e0daee38855", + # }, + # ], # A list of aliases, including the key ID of the KMS key that each alias refers to. + # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not. + # } + # @example Request syntax with placeholder values + # + # resp = client.list_aliases({ + # key_id: "KeyIdType", + # limit: 1, + # marker: "MarkerType", + # }) + # @example Response structure + # + # resp.aliases #=> Array + # resp.aliases[0].alias_name #=> String + # resp.aliases[0].alias_arn #=> String + # resp.aliases[0].target_key_id #=> String + # resp.aliases[0].creation_date #=> Time + # resp.aliases[0].last_updated_date #=> Time + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @option params + # @overload list_aliases + # @param params [Hash] ({}) + # @return [Types::ListAliasesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListAliasesResponse#aliases #aliases} => Array<Types::AliasListEntry> + # * {Types::ListAliasesResponse#next_marker #next_marker} => String + # * {Types::ListAliasesResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListAliases AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#6977 + def list_aliases(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Gets a list of all grants for the specified KMS key. + # + # You must specify the KMS key in all requests. You can filter the grant + # list by grant ID or grantee principal. + # + # For detailed information about grants, including grant terminology, + # see [Grants in KMS][1] in the Key Management Service Developer + # Guide . For examples of working with grants in several + # programming languages, see [Programming grants][2]. + # + # The `GranteePrincipal` field in the `ListGrants` response usually + # contains the user or role designated as the grantee principal in the + # grant. However, when the grantee principal in the grant is an Amazon + # Web Services service, the `GranteePrincipal` field contains the + # [service principal][3], which might represent several different + # grantee principals. + # + # + # + # **Cross-account use**: Yes. To perform this operation on a KMS key in + # a different Amazon Web Services account, specify the key ARN in the + # value of the `KeyId` parameter. + # + # **Required permissions**: [kms:ListGrants][4] (key policy) + # + # **Related operations:** + # + # * CreateGrant + # + # * ListRetirableGrants + # + # * RetireGrant + # + # * RevokeGrant + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-grants.html + # [3]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_principal.html#principal-services + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list grants for a KMS key + # + # # The following example lists grants for the specified KMS key. + # + # resp = client.list_grants({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose grants you want to list. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # grants: [ + # { + # creation_date: Time.parse("2016-10-25T14:37:41-07:00"), + # grant_id: "91ad875e49b04a9d1f3bdeb84d821f9db6ea95e1098813f6d47f0c65fbe2a172", + # grantee_principal: "acm.us-east-2.amazonaws.com", + # issuing_account: "arn:aws:iam::111122223333:root", + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # operations: [ + # "Encrypt", + # "ReEncryptFrom", + # "ReEncryptTo", + # ], + # retiring_principal: "acm.us-east-2.amazonaws.com", + # }, + # { + # creation_date: Time.parse("2016-10-25T14:37:41-07:00"), + # grant_id: "a5d67d3e207a8fc1f4928749ee3e52eb0440493a8b9cf05bbfad91655b056200", + # grantee_principal: "acm.us-east-2.amazonaws.com", + # issuing_account: "arn:aws:iam::111122223333:root", + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # operations: [ + # "ReEncryptFrom", + # "ReEncryptTo", + # ], + # retiring_principal: "acm.us-east-2.amazonaws.com", + # }, + # { + # creation_date: Time.parse("2016-10-25T14:37:41-07:00"), + # grant_id: "c541aaf05d90cb78846a73b346fc43e65be28b7163129488c738e0c9e0628f4f", + # grantee_principal: "acm.us-east-2.amazonaws.com", + # issuing_account: "arn:aws:iam::111122223333:root", + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # operations: [ + # "Encrypt", + # "ReEncryptFrom", + # "ReEncryptTo", + # ], + # retiring_principal: "acm.us-east-2.amazonaws.com", + # }, + # { + # creation_date: Time.parse("2016-10-25T14:37:41-07:00"), + # grant_id: "dd2052c67b4c76ee45caf1dc6a1e2d24e8dc744a51b36ae2f067dc540ce0105c", + # grantee_principal: "acm.us-east-2.amazonaws.com", + # issuing_account: "arn:aws:iam::111122223333:root", + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # operations: [ + # "Encrypt", + # "ReEncryptFrom", + # "ReEncryptTo", + # ], + # retiring_principal: "acm.us-east-2.amazonaws.com", + # }, + # ], # A list of grants. + # truncated: true, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not. + # } + # @example Request syntax with placeholder values + # + # resp = client.list_grants({ + # limit: 1, + # marker: "MarkerType", + # key_id: "KeyIdType", # required + # grant_id: "GrantIdType", + # grantee_principal: "PrincipalIdType", + # }) + # @example Response structure + # + # resp.grants #=> Array + # resp.grants[0].key_id #=> String + # resp.grants[0].grant_id #=> String + # resp.grants[0].name #=> String + # resp.grants[0].creation_date #=> Time + # resp.grants[0].grantee_principal #=> String + # resp.grants[0].retiring_principal #=> String + # resp.grants[0].issuing_account #=> String + # resp.grants[0].operations #=> Array + # resp.grants[0].operations[0] #=> String, one of "Decrypt", "Encrypt", "GenerateDataKey", "GenerateDataKeyWithoutPlaintext", "ReEncryptFrom", "ReEncryptTo", "Sign", "Verify", "GetPublicKey", "CreateGrant", "RetireGrant", "DescribeKey", "GenerateDataKeyPair", "GenerateDataKeyPairWithoutPlaintext", "GenerateMac", "VerifyMac", "DeriveSharedSecret" + # resp.grants[0].constraints.encryption_context_subset #=> Hash + # resp.grants[0].constraints.encryption_context_subset["EncryptionContextKey"] #=> String + # resp.grants[0].constraints.encryption_context_equals #=> Hash + # resp.grants[0].constraints.encryption_context_equals["EncryptionContextKey"] #=> String + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload list_grants + # @param params [Hash] ({}) + # @return [Types::ListGrantsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListGrantsResponse#grants #grants} => Array<Types::GrantListEntry> + # * {Types::ListGrantsResponse#next_marker #next_marker} => String + # * {Types::ListGrantsResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListGrants AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#7174 + def list_grants(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Gets the names of the key policies that are attached to a KMS key. + # This operation is designed to get policy names that you can use in a + # GetKeyPolicy operation. However, the only valid policy name is + # `default`. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:ListKeyPolicies][1] (key policy) + # + # **Related operations:** + # + # * GetKeyPolicy + # + # * [PutKeyPolicy][2] + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][3]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [2]: https://docs.aws.amazon.com/kms/latest/APIReference/API_PutKeyPolicy.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list key policies for a KMS key + # + # # The following example lists key policies for the specified KMS key. + # + # resp = client.list_key_policies({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose key policies you want to list. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # policy_names: [ + # "default", + # ], # A list of key policy names. + # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not. + # } + # @example Request syntax with placeholder values + # + # resp = client.list_key_policies({ + # key_id: "KeyIdType", # required + # limit: 1, + # marker: "MarkerType", + # }) + # @example Response structure + # + # resp.policy_names #=> Array + # resp.policy_names[0] #=> String + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @option params + # @overload list_key_policies + # @param params [Hash] ({}) + # @return [Types::ListKeyPoliciesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListKeyPoliciesResponse#policy_names #policy_names} => Array<String> + # * {Types::ListKeyPoliciesResponse#next_marker #next_marker} => String + # * {Types::ListKeyPoliciesResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeyPolicies AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#7279 + def list_key_policies(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns information about all completed key material rotations for the + # specified KMS key. + # + # You must specify the KMS key in all requests. You can refine the key + # rotations list by limiting the number of rotations returned. + # + # For detailed information about automatic and on-demand key rotations, + # see [Rotating KMS keys][1] in the *Key Management Service Developer + # Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:ListKeyRotations][2] (key policy) + # + # **Related operations:** + # + # * EnableKeyRotation + # + # * DisableKeyRotation + # + # * GetKeyRotationStatus + # + # * RotateKeyOnDemand + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][3]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To retrieve information about all completed key material rotations + # + # # The following example returns information about all completed key material rotations for the specified KMS key. + # + # resp = client.list_key_rotations({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # }) + # + # resp.to_h outputs the following: + # { + # rotations: [ + # { + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # rotation_date: Time.parse("2024-03-02T10:11:36.564000+00:00"), + # rotation_type: "AUTOMATIC", + # }, + # { + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", + # rotation_date: Time.parse("2024-04-05T15:14:47.757000+00:00"), + # rotation_type: "ON_DEMAND", + # }, + # ], # A list of key rotations. + # truncated: false, # A flag that indicates whether there are more items in the list. When the value is true, the list in this response is truncated. To get more items, pass the value of the NextMarker element in this response to the Marker parameter in a subsequent request. + # } + # @example Request syntax with placeholder values + # + # resp = client.list_key_rotations({ + # key_id: "KeyIdType", # required + # limit: 1, + # marker: "MarkerType", + # }) + # @example Response structure + # + # resp.rotations #=> Array + # resp.rotations[0].key_id #=> String + # resp.rotations[0].rotation_date #=> Time + # resp.rotations[0].rotation_type #=> String, one of "AUTOMATIC", "ON_DEMAND" + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @option params + # @overload list_key_rotations + # @param params [Hash] ({}) + # @return [Types::ListKeyRotationsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListKeyRotationsResponse#rotations #rotations} => Array<Types::RotationsListEntry> + # * {Types::ListKeyRotationsResponse#next_marker #next_marker} => String + # * {Types::ListKeyRotationsResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeyRotations AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#7402 + def list_key_rotations(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Gets a list of all KMS keys in the caller's Amazon Web Services + # account and Region. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:ListKeys][1] (IAM policy) + # + # **Related operations:** + # + # * CreateKey + # + # * DescribeKey + # + # * ListAliases + # + # * ListResourceTags + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][2]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list KMS keys + # + # # The following example lists KMS keys. + # + # resp = client.list_keys({ + # }) + # + # resp.to_h outputs the following: + # { + # keys: [ + # { + # key_arn: "arn:aws:kms:us-east-2:111122223333:key/0d990263-018e-4e65-a703-eff731de951e", + # key_id: "0d990263-018e-4e65-a703-eff731de951e", + # }, + # { + # key_arn: "arn:aws:kms:us-east-2:111122223333:key/144be297-0ae1-44ac-9c8f-93cd8c82f841", + # key_id: "144be297-0ae1-44ac-9c8f-93cd8c82f841", + # }, + # { + # key_arn: "arn:aws:kms:us-east-2:111122223333:key/21184251-b765-428e-b852-2c7353e72571", + # key_id: "21184251-b765-428e-b852-2c7353e72571", + # }, + # { + # key_arn: "arn:aws:kms:us-east-2:111122223333:key/214fe92f-5b03-4ae1-b350-db2a45dbe10c", + # key_id: "214fe92f-5b03-4ae1-b350-db2a45dbe10c", + # }, + # { + # key_arn: "arn:aws:kms:us-east-2:111122223333:key/339963f2-e523-49d3-af24-a0fe752aa458", + # key_id: "339963f2-e523-49d3-af24-a0fe752aa458", + # }, + # { + # key_arn: "arn:aws:kms:us-east-2:111122223333:key/b776a44b-df37-4438-9be4-a27494e4271a", + # key_id: "b776a44b-df37-4438-9be4-a27494e4271a", + # }, + # { + # key_arn: "arn:aws:kms:us-east-2:111122223333:key/deaf6c9e-cf2c-46a6-bf6d-0b6d487cffbb", + # key_id: "deaf6c9e-cf2c-46a6-bf6d-0b6d487cffbb", + # }, + # ], # A list of KMS keys, including the key ID and Amazon Resource Name (ARN) of each one. + # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not. + # } + # @example Request syntax with placeholder values + # + # resp = client.list_keys({ + # limit: 1, + # marker: "MarkerType", + # }) + # @example Response structure + # + # resp.keys #=> Array + # resp.keys[0].key_id #=> String + # resp.keys[0].key_arn #=> String + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @overload list_keys + # @param params [Hash] ({}) + # @return [Types::ListKeysResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListKeysResponse#keys #keys} => Array<Types::KeyListEntry> + # * {Types::ListKeysResponse#next_marker #next_marker} => String + # * {Types::ListKeysResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeys AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#7517 + def list_keys(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns all tags on the specified KMS key. + # + # For general information about tags, including the format and syntax, + # see [Tagging Amazon Web Services resources][1] in the *Amazon Web + # Services General Reference*. For information about using tags in KMS, + # see [Tagging keys][2]. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:ListResourceTags][3] (key policy) + # + # **Related operations:** + # + # * CreateKey + # + # * ReplicateKey + # + # * TagResource + # + # * UntagResource + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list tags for a KMS key + # + # # The following example lists tags for a KMS key. + # + # resp = client.list_resource_tags({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose tags you are listing. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # tags: [ + # { + # tag_key: "CostCenter", + # tag_value: "87654", + # }, + # { + # tag_key: "CreatedBy", + # tag_value: "ExampleUser", + # }, + # { + # tag_key: "Purpose", + # tag_value: "Test", + # }, + # ], # A list of tags. + # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not. + # } + # @example Request syntax with placeholder values + # + # resp = client.list_resource_tags({ + # key_id: "KeyIdType", # required + # limit: 1, + # marker: "MarkerType", + # }) + # @example Response structure + # + # resp.tags #=> Array + # resp.tags[0].tag_key #=> String + # resp.tags[0].tag_value #=> String + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @option params + # @overload list_resource_tags + # @param params [Hash] ({}) + # @return [Types::ListResourceTagsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListResourceTagsResponse#tags #tags} => Array<Types::Tag> + # * {Types::ListResourceTagsResponse#next_marker #next_marker} => String + # * {Types::ListResourceTagsResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListResourceTags AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#7641 + def list_resource_tags(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns information about all grants in the Amazon Web Services + # account and Region that have the specified retiring principal. + # + # You can specify any principal in your Amazon Web Services account. The + # grants that are returned include grants for KMS keys in your Amazon + # Web Services account and other Amazon Web Services accounts. You might + # use this operation to determine which grants you may retire. To retire + # a grant, use the RetireGrant operation. + # + # For detailed information about grants, including grant terminology, + # see [Grants in KMS][1] in the Key Management Service Developer + # Guide . For examples of working with grants in several + # programming languages, see [Programming grants][2]. + # + # **Cross-account use**: You must specify a principal in your Amazon Web + # Services account. This operation returns a list of grants where the + # retiring principal specified in the `ListRetirableGrants` request is + # the same retiring principal on the grant. This can include grants on + # KMS keys owned by other Amazon Web Services accounts, but you do not + # need `kms:ListRetirableGrants` permission (or any other additional + # permission) in any Amazon Web Services account other than your own. + # + # **Required permissions**: [kms:ListRetirableGrants][3] (IAM policy) in + # your Amazon Web Services account. + # + # KMS authorizes `ListRetirableGrants` requests by evaluating the caller + # account's kms:ListRetirableGrants permissions. The authorized + # resource in `ListRetirableGrants` calls is the retiring principal + # specified in the request. KMS does not evaluate the caller's + # permissions to verify their access to any KMS keys or grants that + # might be returned by the `ListRetirableGrants` call. + # + # + # + # **Related operations:** + # + # * CreateGrant + # + # * ListGrants + # + # * RetireGrant + # + # * RevokeGrant + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][4]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-grants.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list grants that the specified principal can retire + # + # # The following example lists the grants that the specified principal (identity) can retire. + # + # resp = client.list_retirable_grants({ + # retiring_principal: "arn:aws:iam::111122223333:role/ExampleRole", # The retiring principal whose grants you want to list. Use the Amazon Resource Name (ARN) of a principal such as an AWS account (root), IAM user, federated user, or assumed role user. + # }) + # + # resp.to_h outputs the following: + # { + # grants: [ + # { + # creation_date: Time.parse("2016-12-07T11:09:35-08:00"), + # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60", + # grantee_principal: "arn:aws:iam::111122223333:role/ExampleRole", + # issuing_account: "arn:aws:iam::444455556666:root", + # key_id: "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab", + # operations: [ + # "Decrypt", + # "Encrypt", + # ], + # retiring_principal: "arn:aws:iam::111122223333:role/ExampleRole", + # }, + # ], # A list of grants that the specified principal can retire. + # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not. + # } + # @example Request syntax with placeholder values + # + # resp = client.list_retirable_grants({ + # limit: 1, + # marker: "MarkerType", + # retiring_principal: "PrincipalIdType", # required + # }) + # @example Response structure + # + # resp.grants #=> Array + # resp.grants[0].key_id #=> String + # resp.grants[0].grant_id #=> String + # resp.grants[0].name #=> String + # resp.grants[0].creation_date #=> Time + # resp.grants[0].grantee_principal #=> String + # resp.grants[0].retiring_principal #=> String + # resp.grants[0].issuing_account #=> String + # resp.grants[0].operations #=> Array + # resp.grants[0].operations[0] #=> String, one of "Decrypt", "Encrypt", "GenerateDataKey", "GenerateDataKeyWithoutPlaintext", "ReEncryptFrom", "ReEncryptTo", "Sign", "Verify", "GetPublicKey", "CreateGrant", "RetireGrant", "DescribeKey", "GenerateDataKeyPair", "GenerateDataKeyPairWithoutPlaintext", "GenerateMac", "VerifyMac", "DeriveSharedSecret" + # resp.grants[0].constraints.encryption_context_subset #=> Hash + # resp.grants[0].constraints.encryption_context_subset["EncryptionContextKey"] #=> String + # resp.grants[0].constraints.encryption_context_equals #=> Hash + # resp.grants[0].constraints.encryption_context_equals["EncryptionContextKey"] #=> String + # resp.next_marker #=> String + # resp.truncated #=> Boolean + # @option params + # @option params + # @option params + # @overload list_retirable_grants + # @param params [Hash] ({}) + # @return [Types::ListGrantsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListGrantsResponse#grants #grants} => Array<Types::GrantListEntry> + # * {Types::ListGrantsResponse#next_marker #next_marker} => String + # * {Types::ListGrantsResponse#truncated #truncated} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListRetirableGrants AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#7796 + def list_retirable_grants(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Attaches a key policy to the specified KMS key. + # + # For more information about key policies, see [Key Policies][1] in the + # *Key Management Service Developer Guide*. For help writing and + # formatting a JSON policy document, see the [IAM JSON Policy + # Reference][2] in the Identity and Access Management User + # Guide . For examples of adding a key policy in multiple + # programming languages, see [Setting a key policy][3] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:PutKeyPolicy][4] (key policy) + # + # **Related operations**: GetKeyPolicy + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-key-policies.html#put-policy + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To attach a key policy to a KMS key + # + # # The following example attaches a key policy to the specified KMS key. + # + # resp = client.put_key_policy({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to attach the key policy to. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # policy: "{\"Version\":\"2012-10-17\",\"Id\":\"custom-policy-2016-12-07\",\"Statement\":[{\"Sid\":\"EnableIAMUserPermissions\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::111122223333:root\"},\"Action\":\"kms:*\",\"Resource\":\"*\"},{\"Sid\":\"AllowaccessforKeyAdministrators\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":[\"arn:aws:iam::111122223333:user/ExampleAdminUser\",\"arn:aws:iam::111122223333:role/ExampleAdminRole\"]},\"Action\":[\"kms:Create*\",\"kms:Describe*\",\"kms:Enable*\",\"kms:List*\",\"kms:Put*\",\"kms:Update*\",\"kms:Revoke*\",\"kms:Disable*\",\"kms:Get*\",\"kms:Delete*\",\"kms:ScheduleKeyDeletion\",\"kms:CancelKeyDeletion\"],\"Resource\":\"*\"},{\"Sid\":\"Allowuseofthekey\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::111122223333:role/ExamplePowerUserRole\"},\"Action\":[\"kms:Encrypt\",\"kms:Decrypt\",\"kms:ReEncrypt*\",\"kms:GenerateDataKey*\",\"kms:DescribeKey\"],\"Resource\":\"*\"},{\"Sid\":\"Allowattachmentofpersistentresources\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::111122223333:role/ExamplePowerUserRole\"},\"Action\":[\"kms:CreateGrant\",\"kms:ListGrants\",\"kms:RevokeGrant\"],\"Resource\":\"*\",\"Condition\":{\"Bool\":{\"kms:GrantIsForAWSResource\":\"true\"}}}]}", # The key policy document. + # policy_name: "default", # The name of the key policy. + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_key_policy({ + # key_id: "KeyIdType", # required + # policy_name: "PolicyNameType", + # policy: "PolicyType", # required + # bypass_policy_lockout_safety_check: false, + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_key_policy + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/PutKeyPolicy AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#7937 + def put_key_policy(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Decrypts ciphertext and then reencrypts it entirely within KMS. You + # can use this operation to change the KMS key under which data is + # encrypted, such as when you [manually rotate][1] a KMS key or change + # the KMS key that protects a ciphertext. You can also use it to + # reencrypt ciphertext under the same KMS key, such as to change the + # [encryption context][2] of a ciphertext. + # + # The `ReEncrypt` operation can decrypt ciphertext that was encrypted by + # using a KMS key in an KMS operation, such as Encrypt or + # GenerateDataKey. It can also decrypt ciphertext that was encrypted by + # using the public key of an [asymmetric KMS key][3] outside of KMS. + # However, it cannot decrypt ciphertext produced by other libraries, + # such as the [Amazon Web Services Encryption SDK][4] or [Amazon S3 + # client-side encryption][5]. These libraries return a ciphertext format + # that is incompatible with KMS. + # + # When you use the `ReEncrypt` operation, you need to provide + # information for the decrypt operation and the subsequent encrypt + # operation. + # + # * If your ciphertext was encrypted under an asymmetric KMS key, you + # must use the `SourceKeyId` parameter to identify the KMS key that + # encrypted the ciphertext. You must also supply the encryption + # algorithm that was used. This information is required to decrypt the + # data. + # + # * If your ciphertext was encrypted under a symmetric encryption KMS + # key, the `SourceKeyId` parameter is optional. KMS can get this + # information from metadata that it adds to the symmetric ciphertext + # blob. This feature adds durability to your implementation by + # ensuring that authorized users can decrypt ciphertext decades after + # it was encrypted, even if they've lost track of the key ID. + # However, specifying the source KMS key is always recommended as a + # best practice. When you use the `SourceKeyId` parameter to specify a + # KMS key, KMS uses only the KMS key you specify. If the ciphertext + # was encrypted under a different KMS key, the `ReEncrypt` operation + # fails. This practice ensures that you use the KMS key that you + # intend. + # + # * To reencrypt the data, you must use the `DestinationKeyId` parameter + # to specify the KMS key that re-encrypts the data after it is + # decrypted. If the destination KMS key is an asymmetric KMS key, you + # must also provide the encryption algorithm. The algorithm that you + # choose must be compatible with the KMS key. + # + # When you use an asymmetric KMS key to encrypt or reencrypt data, be + # sure to record the KMS key and encryption algorithm that you choose. + # You will be required to provide the same KMS key and encryption + # algorithm when you decrypt the data. If the KMS key and algorithm do + # not match the values used to encrypt the data, the decrypt operation + # fails. + # + # You are not required to supply the key ID and encryption algorithm + # when you decrypt with symmetric encryption KMS keys because KMS + # stores this information in the ciphertext blob. KMS cannot store + # metadata in ciphertext generated with asymmetric keys. The standard + # format for asymmetric key ciphertext does not include configurable + # fields. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][6] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. The source KMS key and destination KMS key + # can be in different Amazon Web Services accounts. Either or both KMS + # keys can be in a different account than the caller. To specify a KMS + # key in a different account, you must use its key ARN or alias ARN. + # + # **Required permissions**: + # + # * [kms:ReEncryptFrom][7] permission on the source KMS key (key policy) + # + # * [kms:ReEncryptTo][7] permission on the destination KMS key (key + # policy) + # + # To permit reencryption from or to a KMS key, include the + # `"kms:ReEncrypt*"` permission in your [key policy][8]. This permission + # is automatically included in the key policy when you use the console + # to create a KMS key. But you must include it manually when you create + # a KMS key programmatically or when you use the PutKeyPolicy operation + # to set a key policy. + # + # **Related operations:** + # + # * Decrypt + # + # * Encrypt + # + # * GenerateDataKey + # + # * GenerateDataKeyPair + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][9]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html#rotate-keys-manually + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/symm-asymm-concepts.html#asymmetric-cmks + # [4]: https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/ + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To reencrypt data + # + # # The following example reencrypts data with the specified KMS key. + # + # resp = client.re_encrypt({ + # ciphertext_blob: "", # The data to reencrypt. + # destination_key_id: "0987dcba-09fe-87dc-65ba-ab0987654321", # The identifier of the KMS key to use to reencrypt the data. You can use any valid key identifier. + # }) + # + # resp.to_h outputs the following: + # { + # ciphertext_blob: "", # The reencrypted data. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The ARN of the KMS key that was used to reencrypt the data. + # source_key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that was originally used to encrypt the data. + # } + # @example Request syntax with placeholder values + # + # resp = client.re_encrypt({ + # ciphertext_blob: "data", # required + # source_encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # source_key_id: "KeyIdType", + # destination_key_id: "KeyIdType", # required + # destination_encryption_context: { + # "EncryptionContextKey" => "EncryptionContextValue", + # }, + # source_encryption_algorithm: "SYMMETRIC_DEFAULT", # accepts SYMMETRIC_DEFAULT, RSAES_OAEP_SHA_1, RSAES_OAEP_SHA_256, SM2PKE + # destination_encryption_algorithm: "SYMMETRIC_DEFAULT", # accepts SYMMETRIC_DEFAULT, RSAES_OAEP_SHA_1, RSAES_OAEP_SHA_256, SM2PKE + # grant_tokens: ["GrantTokenType"], + # dry_run: false, + # }) + # @example Response structure + # + # resp.ciphertext_blob #=> String + # resp.source_key_id #=> String + # resp.key_id #=> String + # resp.source_encryption_algorithm #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # resp.destination_encryption_algorithm #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload re_encrypt + # @param params [Hash] ({}) + # @return [Types::ReEncryptResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ReEncryptResponse#ciphertext_blob #ciphertext_blob} => String + # * {Types::ReEncryptResponse#source_key_id #source_key_id} => String + # * {Types::ReEncryptResponse#key_id #key_id} => String + # * {Types::ReEncryptResponse#source_encryption_algorithm #source_encryption_algorithm} => String + # * {Types::ReEncryptResponse#destination_encryption_algorithm #destination_encryption_algorithm} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ReEncrypt AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#8258 + def re_encrypt(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Replicates a multi-Region key into the specified Region. This + # operation creates a multi-Region replica key based on a multi-Region + # primary key in a different Region of the same Amazon Web Services + # partition. You can create multiple replicas of a primary key, but each + # must be in a different Region. To create a multi-Region primary key, + # use the CreateKey operation. + # + # This operation supports *multi-Region keys*, an KMS feature that lets + # you create multiple interoperable KMS keys in different Amazon Web + # Services Regions. Because these KMS keys have the same key ID, key + # material, and other metadata, you can use them interchangeably to + # encrypt data in one Amazon Web Services Region and decrypt it in a + # different Amazon Web Services Region without re-encrypting the data or + # making a cross-Region call. For more information about multi-Region + # keys, see [Multi-Region keys in KMS][1] in the *Key Management Service + # Developer Guide*. + # + # A *replica key* is a fully-functional KMS key that can be used + # independently of its primary and peer replica keys. A primary key and + # its replica keys share properties that make them interoperable. They + # have the same [key ID][2] and key material. They also have the same + # [key spec][3], [key usage][4], [key material origin][5], and + # [automatic key rotation status][6]. KMS automatically synchronizes + # these shared properties among related multi-Region keys. All other + # properties of a replica key can differ, including its [key policy][7], + # [tags][8], [aliases][9], and [Key states of KMS keys][10]. KMS pricing + # and quotas for KMS keys apply to each primary key and replica key. + # + # When this operation completes, the new replica key has a transient key + # state of `Creating`. This key state changes to `Enabled` (or + # `PendingImport`) after a few seconds when the process of creating the + # new replica key is complete. While the key state is `Creating`, you + # can manage key, but you cannot yet use it in cryptographic operations. + # If you are creating and using the replica key programmatically, retry + # on `KMSInvalidStateException` or call `DescribeKey` to check its + # `KeyState` value before using it. For details about the `Creating` key + # state, see [Key states of KMS keys][10] in the *Key Management Service + # Developer Guide*. + # + # You cannot create more than one replica of a primary key in any + # Region. If the Region already includes a replica of the key you're + # trying to replicate, `ReplicateKey` returns an + # `AlreadyExistsException` error. If the key state of the existing + # replica is `PendingDeletion`, you can cancel the scheduled key + # deletion (CancelKeyDeletion) or wait for the key to be deleted. The + # new replica key you create will have the same [shared properties][11] + # as the original replica key. + # + # The CloudTrail log of a `ReplicateKey` operation records a + # `ReplicateKey` operation in the primary key's Region and a CreateKey + # operation in the replica key's Region. + # + # If you replicate a multi-Region primary key with imported key + # material, the replica key is created with no key material. You must + # import the same key material that you imported into the primary key. + # For details, see [Importing key material into multi-Region keys][12] + # in the *Key Management Service Developer Guide*. + # + # To convert a replica key to a primary key, use the UpdatePrimaryRegion + # operation. + # + # `ReplicateKey` uses different default values for the `KeyPolicy` and + # `Tags` parameters than those used in the KMS console. For details, see + # the parameter descriptions. + # + # + # + # **Cross-account use**: No. You cannot use this operation to create a + # replica key in a different Amazon Web Services account. + # + # **Required permissions**: + # + # * `kms:ReplicateKey` on the primary key (in the primary key's + # Region). Include this permission in the primary key's key policy. + # + # * `kms:CreateKey` in an IAM policy in the replica Region. + # + # * To use the `Tags` parameter, `kms:TagResource` in an IAM policy in + # the replica Region. + # + # **Related operations** + # + # * CreateKey + # + # * UpdatePrimaryRegion + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][13]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-id-key-id + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-spec + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-usage + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-origin + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html#mrk-sync-properties + # [12]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-import.html + # [13]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To replicate a multi-Region key in a different AWS Region + # + # # This example creates a multi-Region replica key in us-west-2 of a multi-Region primary key in us-east-1. + # + # resp = client.replicate_key({ + # key_id: "arn:aws:kms:us-east-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", # The key ID or key ARN of the multi-Region primary key + # replica_region: "us-west-2", # The Region of the new replica. + # }) + # + # resp.to_h outputs the following: + # { + # replica_key_metadata: { + # aws_account_id: "111122223333", + # arn: "arn:aws:kms:us-west-2:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # creation_date: Time.parse(1607472987.918), + # customer_master_key_spec: "SYMMETRIC_DEFAULT", + # description: "", + # enabled: true, + # encryption_algorithms: [ + # "SYMMETRIC_DEFAULT", + # ], + # key_id: "mrk-1234abcd12ab34cd56ef1234567890ab", + # key_manager: "CUSTOMER", + # key_state: "Enabled", + # key_usage: "ENCRYPT_DECRYPT", + # multi_region: true, + # multi_region_configuration: { + # multi_region_key_type: "REPLICA", + # primary_key: { + # arn: "arn:aws:kms:us-east-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # region: "us-east-1", + # }, + # replica_keys: [ + # { + # arn: "arn:aws:kms:us-west-2:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", + # region: "us-west-2", + # }, + # ], + # }, + # origin: "AWS_KMS", + # }, # An object that displays detailed information about the replica key. + # replica_policy: "{\n \"Version\" : \"2012-10-17\",\n \"Id\" : \"key-default-1\",...}", # The key policy of the replica key. If you don't specify a key policy, the replica key gets the default key policy for a KMS key. + # replica_tags: [ + # ], # The tags on the replica key, if any. + # } + # @example Request syntax with placeholder values + # + # resp = client.replicate_key({ + # key_id: "KeyIdType", # required + # replica_region: "RegionType", # required + # policy: "PolicyType", + # bypass_policy_lockout_safety_check: false, + # description: "DescriptionType", + # tags: [ + # { + # tag_key: "TagKeyType", # required + # tag_value: "TagValueType", # required + # }, + # ], + # }) + # @example Response structure + # + # resp.replica_key_metadata.aws_account_id #=> String + # resp.replica_key_metadata.key_id #=> String + # resp.replica_key_metadata.arn #=> String + # resp.replica_key_metadata.creation_date #=> Time + # resp.replica_key_metadata.enabled #=> Boolean + # resp.replica_key_metadata.description #=> String + # resp.replica_key_metadata.key_usage #=> String, one of "SIGN_VERIFY", "ENCRYPT_DECRYPT", "GENERATE_VERIFY_MAC", "KEY_AGREEMENT" + # resp.replica_key_metadata.key_state #=> String, one of "Creating", "Enabled", "Disabled", "PendingDeletion", "PendingImport", "PendingReplicaDeletion", "Unavailable", "Updating" + # resp.replica_key_metadata.deletion_date #=> Time + # resp.replica_key_metadata.valid_to #=> Time + # resp.replica_key_metadata.origin #=> String, one of "AWS_KMS", "EXTERNAL", "AWS_CLOUDHSM", "EXTERNAL_KEY_STORE" + # resp.replica_key_metadata.custom_key_store_id #=> String + # resp.replica_key_metadata.cloud_hsm_cluster_id #=> String + # resp.replica_key_metadata.expiration_model #=> String, one of "KEY_MATERIAL_EXPIRES", "KEY_MATERIAL_DOES_NOT_EXPIRE" + # resp.replica_key_metadata.key_manager #=> String, one of "AWS", "CUSTOMER" + # resp.replica_key_metadata.customer_master_key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.replica_key_metadata.key_spec #=> String, one of "RSA_2048", "RSA_3072", "RSA_4096", "ECC_NIST_P256", "ECC_NIST_P384", "ECC_NIST_P521", "ECC_SECG_P256K1", "SYMMETRIC_DEFAULT", "HMAC_224", "HMAC_256", "HMAC_384", "HMAC_512", "SM2" + # resp.replica_key_metadata.encryption_algorithms #=> Array + # resp.replica_key_metadata.encryption_algorithms[0] #=> String, one of "SYMMETRIC_DEFAULT", "RSAES_OAEP_SHA_1", "RSAES_OAEP_SHA_256", "SM2PKE" + # resp.replica_key_metadata.signing_algorithms #=> Array + # resp.replica_key_metadata.signing_algorithms[0] #=> String, one of "RSASSA_PSS_SHA_256", "RSASSA_PSS_SHA_384", "RSASSA_PSS_SHA_512", "RSASSA_PKCS1_V1_5_SHA_256", "RSASSA_PKCS1_V1_5_SHA_384", "RSASSA_PKCS1_V1_5_SHA_512", "ECDSA_SHA_256", "ECDSA_SHA_384", "ECDSA_SHA_512", "SM2DSA" + # resp.replica_key_metadata.key_agreement_algorithms #=> Array + # resp.replica_key_metadata.key_agreement_algorithms[0] #=> String, one of "ECDH" + # resp.replica_key_metadata.multi_region #=> Boolean + # resp.replica_key_metadata.multi_region_configuration.multi_region_key_type #=> String, one of "PRIMARY", "REPLICA" + # resp.replica_key_metadata.multi_region_configuration.primary_key.arn #=> String + # resp.replica_key_metadata.multi_region_configuration.primary_key.region #=> String + # resp.replica_key_metadata.multi_region_configuration.replica_keys #=> Array + # resp.replica_key_metadata.multi_region_configuration.replica_keys[0].arn #=> String + # resp.replica_key_metadata.multi_region_configuration.replica_keys[0].region #=> String + # resp.replica_key_metadata.pending_deletion_window_in_days #=> Integer + # resp.replica_key_metadata.mac_algorithms #=> Array + # resp.replica_key_metadata.mac_algorithms[0] #=> String, one of "HMAC_SHA_224", "HMAC_SHA_256", "HMAC_SHA_384", "HMAC_SHA_512" + # resp.replica_key_metadata.xks_key_configuration.id #=> String + # resp.replica_policy #=> String + # resp.replica_tags #=> Array + # resp.replica_tags[0].tag_key #=> String + # resp.replica_tags[0].tag_value #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload replicate_key + # @param params [Hash] ({}) + # @return [Types::ReplicateKeyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ReplicateKeyResponse#replica_key_metadata #replica_key_metadata} => Types::KeyMetadata + # * {Types::ReplicateKeyResponse#replica_policy #replica_policy} => String + # * {Types::ReplicateKeyResponse#replica_tags #replica_tags} => Array<Types::Tag> + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ReplicateKey AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#8659 + def replicate_key(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes a grant. Typically, you retire a grant when you no longer need + # its permissions. To identify the grant to retire, use a [grant + # token][1], or both the grant ID and a key identifier (key ID or key + # ARN) of the KMS key. The CreateGrant operation returns both values. + # + # This operation can be called by the *retiring principal* for a grant, + # by the *grantee principal* if the grant allows the `RetireGrant` + # operation, and by the Amazon Web Services account in which the grant + # is created. It can also be called by principals to whom permission for + # retiring a grant is delegated. For details, see [Retiring and revoking + # grants][2] in the *Key Management Service Developer Guide*. + # + # For detailed information about grants, including grant terminology, + # see [Grants in KMS][3] in the Key Management Service Developer + # Guide . For examples of working with grants in several + # programming languages, see [Programming grants][4]. + # + # **Cross-account use**: Yes. You can retire a grant on a KMS key in a + # different Amazon Web Services account. + # + # **Required permissions**: Permission to retire a grant is determined + # primarily by the grant. For details, see [Retiring and revoking + # grants][2] in the *Key Management Service Developer Guide*. + # + # **Related operations:** + # + # * CreateGrant + # + # * ListGrants + # + # * ListRetirableGrants + # + # * RevokeGrant + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html#grant_token + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/grant-manage.html#grant-delete + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-grants.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To retire a grant + # + # # The following example retires a grant. + # + # resp = client.retire_grant({ + # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60", # The identifier of the grant to retire. + # key_id: "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The Amazon Resource Name (ARN) of the KMS key associated with the grant. + # }) + # @example Request syntax with placeholder values + # + # resp = client.retire_grant({ + # grant_token: "GrantTokenType", + # key_id: "KeyIdType", + # grant_id: "GrantIdType", + # dry_run: false, + # }) + # @option params + # @option params + # @option params + # @option params + # @overload retire_grant + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RetireGrant AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#8774 + def retire_grant(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes the specified grant. You revoke a grant to terminate the + # permissions that the grant allows. For more information, see [Retiring + # and revoking grants][1] in the Key Management Service Developer + # Guide . + # + # When you create, retire, or revoke a grant, there might be a brief + # delay, usually less than five minutes, until the grant is available + # throughout KMS. This state is known as *eventual consistency*. For + # details, see [Eventual consistency][2] in the Key Management + # Service Developer Guide . + # + # For detailed information about grants, including grant terminology, + # see [Grants in KMS][3] in the Key Management Service Developer + # Guide . For examples of working with grants in several + # programming languages, see [Programming grants][4]. + # + # **Cross-account use**: Yes. To perform this operation on a KMS key in + # a different Amazon Web Services account, specify the key ARN in the + # value of the `KeyId` parameter. + # + # **Required permissions**: [kms:RevokeGrant][5] (key policy). + # + # **Related operations:** + # + # * CreateGrant + # + # * ListGrants + # + # * ListRetirableGrants + # + # * RetireGrant + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][6]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/grant-manage.html#grant-delete + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html#terms-eventual-consistency + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-grants.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To revoke a grant + # + # # The following example revokes a grant. + # + # resp = client.revoke_grant({ + # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60", # The identifier of the grant to revoke. + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key associated with the grant. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.revoke_grant({ + # key_id: "KeyIdType", # required + # grant_id: "GrantIdType", # required + # dry_run: false, + # }) + # @option params + # @option params + # @option params + # @overload revoke_grant + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RevokeGrant AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#8879 + def revoke_grant(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Immediately initiates rotation of the key material of the specified + # symmetric encryption KMS key. + # + # You can perform [on-demand rotation][1] of the key material in + # customer managed KMS keys, regardless of whether or not [automatic key + # rotation][2] is enabled. On-demand rotations do not change existing + # automatic rotation schedules. For example, consider a KMS key that has + # automatic key rotation enabled with a rotation period of 730 days. If + # the key is scheduled to automatically rotate on April 14, 2024, and + # you perform an on-demand rotation on April 10, 2024, the key will + # automatically rotate, as scheduled, on April 14, 2024 and every 730 + # days thereafter. + # + # You can perform on-demand key rotation a **maximum of 10 times** per + # KMS key. You can use the KMS console to view the number of remaining + # on-demand rotations available for a KMS key. + # + # + # + # You can use GetKeyRotationStatus to identify any in progress on-demand + # rotations. You can use ListKeyRotations to identify the date that + # completed on-demand rotations were performed. You can monitor rotation + # of the key material for your KMS keys in CloudTrail and Amazon + # CloudWatch. + # + # On-demand key rotation is supported only on [symmetric encryption KMS + # keys][3]. You cannot perform on-demand rotation of [asymmetric KMS + # keys][4], [HMAC KMS keys][5], KMS keys with [imported key + # material][6], or KMS keys in a [custom key store][7]. To perform + # on-demand rotation of a set of related [multi-Region keys][8], invoke + # the on-demand rotation on the primary key. + # + # You cannot initiate on-demand rotation of [Amazon Web Services managed + # KMS keys][9]. KMS always rotates the key material of Amazon Web + # Services managed keys every year. Rotation of [Amazon Web Services + # owned KMS keys][10] is managed by the Amazon Web Services service that + # owns the key. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][11] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:RotateKeyOnDemand][12] (key policy) + # + # **Related operations:** + # + # * EnableKeyRotation + # + # * DisableKeyRotation + # + # * GetKeyRotationStatus + # + # * ListKeyRotations + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][13]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html#rotating-keys-on-demand + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html#rotating-keys-enable-disable + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#symmetric-cmks + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-manage.html#multi-region-rotate + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-owned-cmk + # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [12]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [13]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To perform on-demand rotation of key material + # + # # The following example immediately initiates rotation of the key material for the specified KMS key. + # + # resp = client.rotate_key_on_demand({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose key material you want to initiate on-demand rotation on. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The KMS key that you initiated on-demand rotation on. + # } + # @example Request syntax with placeholder values + # + # resp = client.rotate_key_on_demand({ + # key_id: "KeyIdType", # required + # }) + # @example Response structure + # + # resp.key_id #=> String + # @option params + # @overload rotate_key_on_demand + # @param params [Hash] ({}) + # @return [Types::RotateKeyOnDemandResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::RotateKeyOnDemandResponse#key_id #key_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RotateKeyOnDemand AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#9020 + def rotate_key_on_demand(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Schedules the deletion of a KMS key. By default, KMS applies a waiting + # period of 30 days, but you can specify a waiting period of 7-30 days. + # When this operation is successful, the key state of the KMS key + # changes to `PendingDeletion` and the key can't be used in any + # cryptographic operations. It remains in this state for the duration of + # the waiting period. Before the waiting period ends, you can use + # CancelKeyDeletion to cancel the deletion of the KMS key. After the + # waiting period ends, KMS deletes the KMS key, its key material, and + # all KMS data associated with it, including all aliases that refer to + # it. + # + # Deleting a KMS key is a destructive and potentially dangerous + # operation. When a KMS key is deleted, all data that was encrypted + # under the KMS key is unrecoverable. (The only exception is a + # [multi-Region replica key][1], or an [asymmetric or HMAC KMS key with + # imported key + # material](kms/latest/developerguide/importing-keys-managing.html#import-delete-key).) + # To prevent the use of a KMS key without deleting it, use DisableKey. + # + # You can schedule the deletion of a multi-Region primary key and its + # replica keys at any time. However, KMS will not delete a multi-Region + # primary key with existing replica keys. If you schedule the deletion + # of a primary key with replicas, its key state changes to + # `PendingReplicaDeletion` and it cannot be replicated or used in + # cryptographic operations. This status can continue indefinitely. When + # the last of its replicas keys is deleted (not just scheduled), the key + # state of the primary key changes to `PendingDeletion` and its waiting + # period (`PendingWindowInDays`) begins. For details, see [Deleting + # multi-Region keys][1] in the *Key Management Service Developer Guide*. + # + # When KMS [deletes a KMS key from an CloudHSM key store][2], it makes a + # best effort to delete the associated key material from the associated + # CloudHSM cluster. However, you might need to manually [delete the + # orphaned key material][3] from the cluster and its backups. [Deleting + # a KMS key from an external key store][4] has no effect on the + # associated external key. However, for both types of custom key stores, + # deleting a KMS key is destructive and irreversible. You cannot decrypt + # ciphertext encrypted under the KMS key by using only its associated + # external key or CloudHSM key. Also, you cannot recreate a KMS key in + # an external key store by creating a new KMS key with the same key + # material. + # + # For more information about scheduling a KMS key for deletion, see + # [Deleting KMS keys][5] in the *Key Management Service Developer + # Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][6] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: kms:ScheduleKeyDeletion (key policy) + # + # **Related operations** + # + # * CancelKeyDeletion + # + # * DisableKey + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][7]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-delete.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/delete-cmk-keystore.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html#fix-keystore-orphaned-key + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/delete-xks-key.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/deleting-keys.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To schedule a KMS key for deletion + # + # # The following example schedules the specified KMS key for deletion. + # + # resp = client.schedule_key_deletion({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key to schedule for deletion. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # pending_window_in_days: 7, # The waiting period, specified in number of days. After the waiting period ends, KMS deletes the KMS key. + # }) + # + # resp.to_h outputs the following: + # { + # deletion_date: Time.parse("2016-12-17T16:00:00-08:00"), # The date and time after which KMS deletes the KMS key. + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the KMS key that is scheduled for deletion. + # } + # @example Request syntax with placeholder values + # + # resp = client.schedule_key_deletion({ + # key_id: "KeyIdType", # required + # pending_window_in_days: 1, + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.deletion_date #=> Time + # resp.key_state #=> String, one of "Creating", "Enabled", "Disabled", "PendingDeletion", "PendingImport", "PendingReplicaDeletion", "Unavailable", "Updating" + # resp.pending_window_in_days #=> Integer + # @option params + # @option params + # @overload schedule_key_deletion + # @param params [Hash] ({}) + # @return [Types::ScheduleKeyDeletionResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ScheduleKeyDeletionResponse#key_id #key_id} => String + # * {Types::ScheduleKeyDeletionResponse#deletion_date #deletion_date} => Time + # * {Types::ScheduleKeyDeletionResponse#key_state #key_state} => String + # * {Types::ScheduleKeyDeletionResponse#pending_window_in_days #pending_window_in_days} => Integer + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ScheduleKeyDeletion AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#9173 + def schedule_key_deletion(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Creates a [digital signature][1] for a message or message digest by + # using the private key in an asymmetric signing KMS key. To verify the + # signature, use the Verify operation, or use the public key in the same + # asymmetric KMS key outside of KMS. For information about asymmetric + # KMS keys, see [Asymmetric KMS keys][2] in the *Key Management Service + # Developer Guide*. + # + # Digital signatures are generated and verified by using asymmetric key + # pair, such as an RSA or ECC pair that is represented by an asymmetric + # KMS key. The key owner (or an authorized user) uses their private key + # to sign a message. Anyone with the public key can verify that the + # message was signed with that particular private key and that the + # message hasn't changed since it was signed. + # + # To use the `Sign` operation, provide the following information: + # + # * Use the `KeyId` parameter to identify an asymmetric KMS key with a + # `KeyUsage` value of `SIGN_VERIFY`. To get the `KeyUsage` value of a + # KMS key, use the DescribeKey operation. The caller must have + # `kms:Sign` permission on the KMS key. + # + # * Use the `Message` parameter to specify the message or message digest + # to sign. You can submit messages of up to 4096 bytes. To sign a + # larger message, generate a hash digest of the message, and then + # provide the hash digest in the `Message` parameter. To indicate + # whether the message is a full message or a digest, use the + # `MessageType` parameter. + # + # * Choose a signing algorithm that is compatible with the KMS key. + # + # When signing a message, be sure to record the KMS key and the signing + # algorithm. This information is required to verify the signature. + # + # Best practices recommend that you limit the time during which any + # signature is effective. This deters an attack where the actor uses a + # signed message to establish validity repeatedly or long after the + # message is superseded. Signatures do not include a timestamp, but you + # can include a timestamp in the signed message to help you detect when + # its time to refresh the signature. + # + # + # + # To verify the signature that this operation generates, use the Verify + # operation. Or use the GetPublicKey operation to download the public + # key and then use the public key to verify the signature outside of + # KMS. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][3] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:Sign][4] (key policy) + # + # **Related operations**: Verify + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://en.wikipedia.org/wiki/Digital_signature + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To digitally sign a message with an asymmetric KMS key. + # + # # This operation uses the private key in an asymmetric elliptic curve (ECC) KMS key to generate a digital signature for a + # # given message. + # + # resp = client.sign({ + # key_id: "alias/ECC_signing_key", # The asymmetric KMS key to be used to generate the digital signature. This example uses an alias of the KMS key. + # message: "", # Message to be signed. Use Base-64 for the CLI. + # message_type: "RAW", # Indicates whether the message is RAW or a DIGEST. + # signing_algorithm: "ECDSA_SHA_384", # The requested signing algorithm. This must be an algorithm that the KMS key supports. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ARN of the asymmetric KMS key that was used to sign the message. + # signature: "", # The digital signature of the message. + # signing_algorithm: "ECDSA_SHA_384", # The actual signing algorithm that was used to generate the signature. + # } + # @example Example: To digitally sign a message digest with an asymmetric KMS key. + # + # # This operation uses the private key in an asymmetric RSA signing KMS key to generate a digital signature for a message + # # digest. In this example, a large message was hashed and the resulting digest is provided in the Message parameter. To + # # tell KMS not to hash the message again, the MessageType field is set to DIGEST + # + # resp = client.sign({ + # key_id: "alias/RSA_signing_key", # The asymmetric KMS key to be used to generate the digital signature. This example uses an alias of the KMS key. + # message: "", # Message to be signed. Use Base-64 for the CLI. + # message_type: "DIGEST", # Indicates whether the message is RAW or a DIGEST. When it is RAW, KMS hashes the message before signing. When it is DIGEST, KMS skips the hashing step and signs the Message value. + # signing_algorithm: "RSASSA_PKCS1_V1_5_SHA_256", # The requested signing algorithm. This must be an algorithm that the KMS key supports. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-east-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The key ARN of the asymmetric KMS key that was used to sign the message. + # signature: "", # The digital signature of the message. + # signing_algorithm: "RSASSA_PKCS1_V1_5_SHA_256", # The actual signing algorithm that was used to generate the signature. + # } + # @example Request syntax with placeholder values + # + # resp = client.sign({ + # key_id: "KeyIdType", # required + # message: "data", # required + # message_type: "RAW", # accepts RAW, DIGEST + # grant_tokens: ["GrantTokenType"], + # signing_algorithm: "RSASSA_PSS_SHA_256", # required, accepts RSASSA_PSS_SHA_256, RSASSA_PSS_SHA_384, RSASSA_PSS_SHA_512, RSASSA_PKCS1_V1_5_SHA_256, RSASSA_PKCS1_V1_5_SHA_384, RSASSA_PKCS1_V1_5_SHA_512, ECDSA_SHA_256, ECDSA_SHA_384, ECDSA_SHA_512, SM2DSA + # dry_run: false, + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.signature #=> String + # resp.signing_algorithm #=> String, one of "RSASSA_PSS_SHA_256", "RSASSA_PSS_SHA_384", "RSASSA_PSS_SHA_512", "RSASSA_PKCS1_V1_5_SHA_256", "RSASSA_PKCS1_V1_5_SHA_384", "RSASSA_PKCS1_V1_5_SHA_512", "ECDSA_SHA_256", "ECDSA_SHA_384", "ECDSA_SHA_512", "SM2DSA" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload sign + # @param params [Hash] ({}) + # @return [Types::SignResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::SignResponse#key_id #key_id} => String + # * {Types::SignResponse#signature #signature} => String + # * {Types::SignResponse#signing_algorithm #signing_algorithm} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/Sign AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#9421 + def sign(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Adds or edits tags on a [customer managed key][1]. + # + # Tagging or untagging a KMS key can allow or deny permission to the KMS + # key. For details, see [ABAC for KMS][2] in the *Key Management Service + # Developer Guide*. + # + # + # + # Each tag consists of a tag key and a tag value, both of which are + # case-sensitive strings. The tag value can be an empty (null) string. + # To add a tag, specify a new tag key and a tag value. To edit a tag, + # specify an existing tag key and a new tag value. + # + # You can use this operation to tag a [customer managed key][1], but you + # cannot tag an [Amazon Web Services managed key][3], an [Amazon Web + # Services owned key][4], a [custom key store][5], or an [alias][6]. + # + # You can also add tags to a KMS key while creating it (CreateKey) or + # replicating it (ReplicateKey). + # + # For information about using tags in KMS, see [Tagging keys][7]. For + # general information about tags, including the format and syntax, see + # [Tagging Amazon Web Services resources][8] in the *Amazon Web Services + # General Reference*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][9] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:TagResource][10] (key policy) + # + # **Related operations** + # + # * CreateKey + # + # * ListResourceTags + # + # * ReplicateKey + # + # * UntagResource + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][11]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/abac.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-owned-cmk + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#keystore-concept + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#alias-concept + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html + # [8]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To tag a KMS key + # + # # The following example tags a KMS key. + # + # resp = client.tag_resource({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key you are tagging. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # tags: [ + # { + # tag_key: "Purpose", + # tag_value: "Test", + # }, + # ], # A list of tags. + # }) + # @example Request syntax with placeholder values + # + # resp = client.tag_resource({ + # key_id: "KeyIdType", # required + # tags: [ # required + # { + # tag_key: "TagKeyType", # required + # tag_value: "TagValueType", # required + # }, + # ], + # }) + # @option params + # @option params + # @overload tag_resource + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/TagResource AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#9547 + def tag_resource(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes tags from a [customer managed key][1]. To delete a tag, + # specify the tag key and the KMS key. + # + # Tagging or untagging a KMS key can allow or deny permission to the KMS + # key. For details, see [ABAC for KMS][2] in the *Key Management Service + # Developer Guide*. + # + # + # + # When it succeeds, the `UntagResource` operation doesn't return any + # output. Also, if the specified tag key isn't found on the KMS key, it + # doesn't throw an exception or return a response. To confirm that the + # operation worked, use the ListResourceTags operation. + # + # For information about using tags in KMS, see [Tagging keys][3]. For + # general information about tags, including the format and syntax, see + # [Tagging Amazon Web Services resources][4] in the *Amazon Web Services + # General Reference*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][5] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:UntagResource][6] (key policy) + # + # **Related operations** + # + # * CreateKey + # + # * ListResourceTags + # + # * ReplicateKey + # + # * TagResource + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][7]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/abac.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html + # [4]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To remove tags from a KMS key + # + # # The following example removes tags from a KMS key. + # + # resp = client.untag_resource({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose tags you are removing. + # tag_keys: [ + # "Purpose", + # "CostCenter", + # ], # A list of tag keys. Provide only the tag keys, not the tag values. + # }) + # @example Request syntax with placeholder values + # + # resp = client.untag_resource({ + # key_id: "KeyIdType", # required + # tag_keys: ["TagKeyType"], # required + # }) + # @option params + # @option params + # @overload untag_resource + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UntagResource AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#9647 + def untag_resource(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Associates an existing KMS alias with a different KMS key. Each alias + # is associated with only one KMS key at a time, although a KMS key can + # have multiple aliases. The alias and the KMS key must be in the same + # Amazon Web Services account and Region. + # + # Adding, deleting, or updating an alias can allow or deny permission to + # the KMS key. For details, see [ABAC for KMS][1] in the *Key Management + # Service Developer Guide*. + # + # + # + # The current and new KMS key must be the same type (both symmetric or + # both asymmetric or both HMAC), and they must have the same key usage. + # This restriction prevents errors in code that uses aliases. If you + # must assign an alias to a different type of KMS key, use DeleteAlias + # to delete the old alias and CreateAlias to create a new alias. + # + # You cannot use `UpdateAlias` to change an alias name. To change an + # alias name, use DeleteAlias to delete the old alias and CreateAlias to + # create a new alias. + # + # Because an alias is not a property of a KMS key, you can create, + # update, and delete the aliases of a KMS key without affecting the KMS + # key. Also, aliases do not appear in the response from the DescribeKey + # operation. To get the aliases of all KMS keys in the account, use the + # ListAliases operation. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][2] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions** + # + # * [kms:UpdateAlias][3] on the alias (IAM policy). + # + # * [kms:UpdateAlias][3] on the current KMS key (key policy). + # + # * [kms:UpdateAlias][3] on the new KMS key (key policy). + # + # For details, see [Controlling access to aliases][4] in the *Key + # Management Service Developer Guide*. + # + # **Related operations:** + # + # * CreateAlias + # + # * DeleteAlias + # + # * ListAliases + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/abac.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To update an alias + # + # # The following example updates the specified alias to refer to the specified KMS key. + # + # resp = client.update_alias({ + # alias_name: "alias/ExampleAlias", # The alias to update. + # target_key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key that the alias will refer to after this operation succeeds. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.update_alias({ + # alias_name: "AliasNameType", # required + # target_key_id: "KeyIdType", # required + # }) + # @option params + # @option params + # @overload update_alias + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdateAlias AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#9779 + def update_alias(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Changes the properties of a custom key store. You can use this + # operation to change the properties of an CloudHSM key store or an + # external key store. + # + # Use the required `CustomKeyStoreId` parameter to identify the custom + # key store. Use the remaining optional parameters to change its + # properties. This operation does not return any property values. To + # verify the updated property values, use the DescribeCustomKeyStores + # operation. + # + # This operation is part of the [custom key stores][1] feature in KMS, + # which combines the convenience and extensive integration of KMS with + # the isolation and control of a key store that you own and manage. + # + # When updating the properties of an external key store, verify that the + # updated settings connect your key store, via the external key store + # proxy, to the same external key manager as the previous settings, or + # to a backup or snapshot of the external key manager with the same + # cryptographic keys. If the updated connection settings fail, you can + # fix them and retry, although an extended delay might disrupt Amazon + # Web Services services. However, if KMS permanently loses its access to + # cryptographic keys, ciphertext encrypted under those keys is + # unrecoverable. + # + # For external key stores: + # + # Some external key managers provide a simpler method for updating an + # external key store. For details, see your external key manager + # documentation. + # + # When updating an external key store in the KMS console, you can upload + # a JSON-based proxy configuration file with the desired values. You + # cannot upload the proxy configuration file to the + # `UpdateCustomKeyStore` operation. However, you can use the file to + # help you determine the correct values for the `UpdateCustomKeyStore` + # parameters. + # + # + # + # For an CloudHSM key store, you can use this operation to change the + # custom key store friendly name (`NewCustomKeyStoreName`), to tell KMS + # about a change to the `kmsuser` crypto user password + # (`KeyStorePassword`), or to associate the custom key store with a + # different, but related, CloudHSM cluster (`CloudHsmClusterId`). To + # update any property of an CloudHSM key store, the `ConnectionState` of + # the CloudHSM key store must be `DISCONNECTED`. + # + # For an external key store, you can use this operation to change the + # custom key store friendly name (`NewCustomKeyStoreName`), or to tell + # KMS about a change to the external key store proxy authentication + # credentials (`XksProxyAuthenticationCredential`), connection method + # (`XksProxyConnectivity`), external proxy endpoint + # (`XksProxyUriEndpoint`) and path (`XksProxyUriPath`). For external key + # stores with an `XksProxyConnectivity` of `VPC_ENDPOINT_SERVICE`, you + # can also update the Amazon VPC endpoint service name + # (`XksProxyVpcEndpointServiceName`). To update most properties of an + # external key store, the `ConnectionState` of the external key store + # must be `DISCONNECTED`. However, you can update the + # `CustomKeyStoreName`, `XksProxyAuthenticationCredential`, and + # `XksProxyUriPath` of an external key store when it is in the CONNECTED + # or DISCONNECTED state. + # + # If your update requires a `DISCONNECTED` state, before using + # `UpdateCustomKeyStore`, use the DisconnectCustomKeyStore operation to + # disconnect the custom key store. After the `UpdateCustomKeyStore` + # operation completes, use the ConnectCustomKeyStore to reconnect the + # custom key store. To find the `ConnectionState` of the custom key + # store, use the DescribeCustomKeyStores operation. + # + # + # + # Before updating the custom key store, verify that the new values allow + # KMS to connect the custom key store to its backing key store. For + # example, before you change the `XksProxyUriPath` value, verify that + # the external key store proxy is reachable at the new path. + # + # If the operation succeeds, it returns a JSON object with no + # properties. + # + # **Cross-account use**: No. You cannot perform this operation on a + # custom key store in a different Amazon Web Services account. + # + # **Required permissions**: [kms:UpdateCustomKeyStore][2] (IAM policy) + # + # **Related operations:** + # + # * ConnectCustomKeyStore + # + # * CreateCustomKeyStore + # + # * DeleteCustomKeyStore + # + # * DescribeCustomKeyStores + # + # * DisconnectCustomKeyStore + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][3]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To edit the friendly name of a custom key store + # + # # This example changes the friendly name of the AWS KMS custom key store to the name that you specify. This operation does + # # not return any data. To verify that the operation worked, use the DescribeCustomKeyStores operation. + # + # resp = client.update_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the custom key store that you are updating. + # new_custom_key_store_name: "DevelopmentKeys", # A new friendly name for the custom key store. + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Example: To edit the password of an AWS CloudHSM key store + # + # # This example tells AWS KMS the password for the kmsuser crypto user in the AWS CloudHSM cluster that is associated with + # # the AWS KMS custom key store. (It does not change the password in the CloudHSM cluster.) This operation does not return + # # any data. + # + # resp = client.update_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the custom key store that you are updating. + # key_store_password: "ExamplePassword", # The password for the kmsuser crypto user in the CloudHSM cluster. + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Example: To associate the custom key store with a different, but related, AWS CloudHSM cluster. + # + # # This example changes the AWS CloudHSM cluster that is associated with an AWS CloudHSM key store to a related cluster, + # # such as a different backup of the same cluster. This operation does not return any data. To verify that the operation + # # worked, use the DescribeCustomKeyStores operation. + # + # resp = client.update_custom_key_store({ + # cloud_hsm_cluster_id: "cluster-234abcdefABC", # The ID of the AWS CloudHSM cluster that you want to associate with the custom key store. This cluster must be related to the original CloudHSM cluster for this key store. + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the custom key store that you are updating. + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Example: To update the proxy authentication credential of an external key store + # + # # To update the proxy authentication credential for your external key store, specify both the + # # RawSecretAccessKey and the AccessKeyId, even if you are changing only one of the values. You + # # can use this feature to fix an invalid credential or to change the credential when the external key store proxy rotates + # # it. + # + # resp = client.update_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # Identifies the custom key store + # xks_proxy_authentication_credential: { + # access_key_id: "ABCDE12345670EXAMPLE", + # raw_secret_access_key: "DXjSUawnel2fr6SKC7G25CNxTyWKE5PF9XX6H/u9pSo=", + # }, # Specifies the values in the proxy authentication credential + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Example: To edit the proxy URI path of an external key store. + # + # # This example updates the proxy URI path for an external key store + # + # resp = client.update_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # The ID of the custom key store that you are updating + # xks_proxy_uri_path: "/new-path/kms/xks/v1", # The URI path to the external key store proxy APIs + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Example: To update the proxy connectivity of an external key store to VPC_ENDPOINT_SERVICE + # + # # To change the external key store proxy connectivity option from public endpoint connectivity to VPC endpoint service + # # connectivity, in addition to changing the XksProxyConnectivity value, you must change the + # # XksProxyUriEndpoint value to reflect the private DNS name associated with the VPC endpoint service. You + # # must also add an XksProxyVpcEndpointServiceName value. + # + # resp = client.update_custom_key_store({ + # custom_key_store_id: "cks-1234567890abcdef0", # Identifies the custom key store + # xks_proxy_connectivity: "VPC_ENDPOINT_SERVICE", # Specifies the connectivity option + # xks_proxy_uri_endpoint: "https://myproxy-private.xks.example.com", # Specifies the URI endpoint that AWS KMS uses when communicating with the external key store proxy + # xks_proxy_vpc_endpoint_service_name: "com.amazonaws.vpce.us-east-1.vpce-svc-example", # Specifies the name of the VPC endpoint service that the proxy uses for communication + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.update_custom_key_store({ + # custom_key_store_id: "CustomKeyStoreIdType", # required + # new_custom_key_store_name: "CustomKeyStoreNameType", + # key_store_password: "KeyStorePasswordType", + # cloud_hsm_cluster_id: "CloudHsmClusterIdType", + # xks_proxy_uri_endpoint: "XksProxyUriEndpointType", + # xks_proxy_uri_path: "XksProxyUriPathType", + # xks_proxy_vpc_endpoint_service_name: "XksProxyVpcEndpointServiceNameType", + # xks_proxy_authentication_credential: { + # access_key_id: "XksProxyAuthenticationAccessKeyIdType", # required + # raw_secret_access_key: "XksProxyAuthenticationRawSecretAccessKeyType", # required + # }, + # xks_proxy_connectivity: "PUBLIC_ENDPOINT", # accepts PUBLIC_ENDPOINT, VPC_ENDPOINT_SERVICE + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload update_custom_key_store + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdateCustomKeyStore AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10135 + def update_custom_key_store(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Updates the description of a KMS key. To see the description of a KMS + # key, use DescribeKey. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][1] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: No. You cannot perform this operation on a KMS + # key in a different Amazon Web Services account. + # + # **Required permissions**: [kms:UpdateKeyDescription][2] (key policy) + # + # **Related operations** + # + # * CreateKey + # + # * DescribeKey + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][3]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To update the description of a KMS key + # + # # The following example updates the description of the specified KMS key. + # + # resp = client.update_key_description({ + # description: "Example description that indicates the intended use of this KMS key.", # The updated description. + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the KMS key whose description you are updating. You can use the key ID or the Amazon Resource Name (ARN) of the KMS key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.update_key_description({ + # key_id: "KeyIdType", # required + # description: "DescriptionType", # required + # }) + # @option params + # @option params + # @overload update_key_description + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdateKeyDescription AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10212 + def update_key_description(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Changes the primary key of a multi-Region key. + # + # This operation changes the replica key in the specified Region to a + # primary key and changes the former primary key to a replica key. For + # example, suppose you have a primary key in `us-east-1` and a replica + # key in `eu-west-2`. If you run `UpdatePrimaryRegion` with a + # `PrimaryRegion` value of `eu-west-2`, the primary key is now the key + # in `eu-west-2`, and the key in `us-east-1` becomes a replica key. For + # details, see [Updating the primary Region][1] in the *Key Management + # Service Developer Guide*. + # + # This operation supports *multi-Region keys*, an KMS feature that lets + # you create multiple interoperable KMS keys in different Amazon Web + # Services Regions. Because these KMS keys have the same key ID, key + # material, and other metadata, you can use them interchangeably to + # encrypt data in one Amazon Web Services Region and decrypt it in a + # different Amazon Web Services Region without re-encrypting the data or + # making a cross-Region call. For more information about multi-Region + # keys, see [Multi-Region keys in KMS][2] in the *Key Management Service + # Developer Guide*. + # + # The *primary key* of a multi-Region key is the source for properties + # that are always shared by primary and replica keys, including the key + # material, [key ID][3], [key spec][4], [key usage][5], [key material + # origin][6], and [automatic key rotation][7]. It's the only key that + # can be replicated. You cannot [delete the primary key][8] until all + # replica keys are deleted. + # + # The key ID and primary Region that you specify uniquely identify the + # replica key that will become the primary key. The primary Region must + # already have a replica key. This operation does not create a KMS key + # in the specified Region. To find the replica keys, use the DescribeKey + # operation on the primary key or any replica key. To create a replica + # key, use the ReplicateKey operation. + # + # You can run this operation while using the affected multi-Region keys + # in cryptographic operations. This operation should not delay, + # interrupt, or cause failures in cryptographic operations. + # + # Even after this operation completes, the process of updating the + # primary Region might still be in progress for a few more seconds. + # Operations such as `DescribeKey` might display both the old and new + # primary keys as replicas. The old and new primary keys have a + # transient key state of `Updating`. The original key state is restored + # when the update is complete. While the key state is `Updating`, you + # can use the keys in cryptographic operations, but you cannot replicate + # the new primary key or perform certain management operations, such as + # enabling or disabling these keys. For details about the `Updating` key + # state, see [Key states of KMS keys][9] in the *Key Management Service + # Developer Guide*. + # + # This operation does not return any output. To verify that primary key + # is changed, use the DescribeKey operation. + # + # **Cross-account use**: No. You cannot use this operation in a + # different Amazon Web Services account. + # + # **Required permissions**: + # + # * `kms:UpdatePrimaryRegion` on the current primary key (in the primary + # key's Region). Include this permission primary key's key policy. + # + # * `kms:UpdatePrimaryRegion` on the current replica key (in the replica + # key's Region). Include this permission in the replica key's key + # policy. + # + # **Related operations** + # + # * CreateKey + # + # * ReplicateKey + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][10]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-manage.html#multi-region-update + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-id-key-id + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-spec + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-usage + # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-origin + # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html + # [8]: https://docs.aws.amazon.com/kms/latest/APIReference/API_ScheduleKeyDeletion.html + # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To update the primary Region of a multi-Region KMS key + # + # # The following UpdatePrimaryRegion example changes the multi-Region replica key in the eu-central-1 Region to the primary + # # key. The current primary key in the us-west-1 Region becomes a replica key. + # # The KeyId parameter identifies the current primary key in the us-west-1 Region. The PrimaryRegion parameter indicates + # # the Region of the replica key that will become the new primary key. + # # This operation does not return any output. To verify that primary key is changed, use the DescribeKey operation. + # + # resp = client.update_primary_region({ + # key_id: "arn:aws:kms:us-west-1:111122223333:key/mrk-1234abcd12ab34cd56ef1234567890ab", # The current primary key. + # primary_region: "eu-central-1", # The Region of the replica key that will become the primary key. + # }) + # @example Request syntax with placeholder values + # + # resp = client.update_primary_region({ + # key_id: "KeyIdType", # required + # primary_region: "RegionType", # required + # }) + # @option params + # @option params + # @overload update_primary_region + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdatePrimaryRegion AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10356 + def update_primary_region(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Verifies a digital signature that was generated by the Sign operation. + # + # + # + # Verification confirms that an authorized user signed the message with + # the specified KMS key and signing algorithm, and the message hasn't + # changed since it was signed. If the signature is verified, the value + # of the `SignatureValid` field in the response is `True`. If the + # signature verification fails, the `Verify` operation fails with an + # `KMSInvalidSignatureException` exception. + # + # A digital signature is generated by using the private key in an + # asymmetric KMS key. The signature is verified by using the public key + # in the same asymmetric KMS key. For information about asymmetric KMS + # keys, see [Asymmetric KMS keys][1] in the *Key Management Service + # Developer Guide*. + # + # To use the `Verify` operation, specify the same asymmetric KMS key, + # message, and signing algorithm that were used to produce the + # signature. The message type does not need to be the same as the one + # used for signing, but it must indicate whether the value of the + # `Message` parameter should be hashed as part of the verification + # process. + # + # You can also verify the digital signature by using the public key of + # the KMS key outside of KMS. Use the GetPublicKey operation to download + # the public key in the asymmetric KMS key and then use the public key + # to verify the signature outside of KMS. The advantage of using the + # `Verify` operation is that it is performed within KMS. As a result, + # it's easy to call, the operation is performed within the FIPS + # boundary, it is logged in CloudTrail, and you can use key policy and + # IAM policy to determine who is authorized to use the KMS key to verify + # signatures. + # + # To verify a signature outside of KMS with an SM2 public key (China + # Regions only), you must specify the distinguishing ID. By default, KMS + # uses `1234567812345678` as the distinguishing ID. For more + # information, see [Offline verification with SM2 key pairs][2]. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][3] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:Verify][4] (key policy) + # + # **Related operations**: Sign + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/asymmetric-key-specs.html#key-spec-sm-offline-verification + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To use an asymmetric KMS key to verify a digital signature + # + # # This operation uses the public key in an elliptic curve (ECC) asymmetric key to verify a digital signature within AWS + # # KMS. + # + # resp = client.verify({ + # key_id: "alias/ECC_signing_key", # The asymmetric KMS key to be used to verify the digital signature. This example uses an alias to identify the KMS key. + # message: "", # The message that was signed. + # message_type: "RAW", # Indicates whether the message is RAW or a DIGEST. + # signature: "", # The signature to be verified. + # signing_algorithm: "ECDSA_SHA_384", # The signing algorithm to be used to verify the signature. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ARN of the asymmetric KMS key that was used to verify the digital signature. + # signature_valid: true, # A value of 'true' Indicates that the signature was verified. If verification fails, the call to Verify fails. + # signing_algorithm: "ECDSA_SHA_384", # The signing algorithm that was used to verify the signature. + # } + # @example Example: To use an asymmetric KMS key to verify a digital signature on a message digest + # + # # This operation uses the public key in an RSA asymmetric signing key pair to verify the digital signature of a message + # # digest. Hashing a message into a digest before sending it to KMS lets you verify messages that exceed the 4096-byte + # # message size limit. To indicate that the value of Message is a digest, use the MessageType parameter + # + # resp = client.verify({ + # key_id: "arn:aws:kms:us-east-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The asymmetric KMS key to be used to verify the digital signature. This example uses an alias to identify the KMS key. + # message: "", # The message that was signed. + # message_type: "DIGEST", # Indicates whether the message is RAW or a DIGEST. When it is RAW, KMS hashes the message before signing. When it is DIGEST, KMS skips the hashing step and signs the Message value. + # signature: "", # The signature to be verified. + # signing_algorithm: "RSASSA_PSS_SHA_512", # The signing algorithm to be used to verify the signature. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-east-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The key ARN of the asymmetric KMS key that was used to verify the digital signature. + # signature_valid: true, # A value of 'true' Indicates that the signature was verified. If verification fails, the call to Verify fails. + # signing_algorithm: "RSASSA_PSS_SHA_512", # The signing algorithm that was used to verify the signature. + # } + # @example Request syntax with placeholder values + # + # resp = client.verify({ + # key_id: "KeyIdType", # required + # message: "data", # required + # message_type: "RAW", # accepts RAW, DIGEST + # signature: "data", # required + # signing_algorithm: "RSASSA_PSS_SHA_256", # required, accepts RSASSA_PSS_SHA_256, RSASSA_PSS_SHA_384, RSASSA_PSS_SHA_512, RSASSA_PKCS1_V1_5_SHA_256, RSASSA_PKCS1_V1_5_SHA_384, RSASSA_PKCS1_V1_5_SHA_512, ECDSA_SHA_256, ECDSA_SHA_384, ECDSA_SHA_512, SM2DSA + # grant_tokens: ["GrantTokenType"], + # dry_run: false, + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.signature_valid #=> Boolean + # resp.signing_algorithm #=> String, one of "RSASSA_PSS_SHA_256", "RSASSA_PSS_SHA_384", "RSASSA_PSS_SHA_512", "RSASSA_PKCS1_V1_5_SHA_256", "RSASSA_PKCS1_V1_5_SHA_384", "RSASSA_PKCS1_V1_5_SHA_512", "ECDSA_SHA_256", "ECDSA_SHA_384", "ECDSA_SHA_512", "SM2DSA" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload verify + # @param params [Hash] ({}) + # @return [Types::VerifyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::VerifyResponse#key_id #key_id} => String + # * {Types::VerifyResponse#signature_valid #signature_valid} => Boolean + # * {Types::VerifyResponse#signing_algorithm #signing_algorithm} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/Verify AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10600 + def verify(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Verifies the hash-based message authentication code (HMAC) for a + # specified message, HMAC KMS key, and MAC algorithm. To verify the + # HMAC, `VerifyMac` computes an HMAC using the message, HMAC KMS key, + # and MAC algorithm that you specify, and compares the computed HMAC to + # the HMAC that you specify. If the HMACs are identical, the + # verification succeeds; otherwise, it fails. Verification indicates + # that the message hasn't changed since the HMAC was calculated, and + # the specified key was used to generate and verify the HMAC. + # + # HMAC KMS keys and the HMAC algorithms that KMS uses conform to + # industry standards defined in [RFC 2104][1]. + # + # This operation is part of KMS support for HMAC KMS keys. For details, + # see [HMAC keys in KMS][2] in the *Key Management Service Developer + # Guide*. + # + # The KMS key that you use for this operation must be in a compatible + # key state. For details, see [Key states of KMS keys][3] in the *Key + # Management Service Developer Guide*. + # + # **Cross-account use**: Yes. To perform this operation with a KMS key + # in a different Amazon Web Services account, specify the key ARN or + # alias ARN in the value of the `KeyId` parameter. + # + # **Required permissions**: [kms:VerifyMac][4] (key policy) + # + # **Related operations**: GenerateMac + # + # **Eventual consistency**: The KMS API follows an eventual consistency + # model. For more information, see [KMS eventual consistency][5]. + # + # + # + # [1]: https://datatracker.ietf.org/doc/html/rfc2104 + # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html + # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html + # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html + # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-eventual-consistency.html + # + # @example Example: To verify an HMAC + # + # # This example verifies an HMAC for a particular message, HMAC KMS keys, and MAC algorithm. A value of 'true' in the + # # MacValid value in the response indicates that the HMAC is valid. + # + # resp = client.verify_mac({ + # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The HMAC KMS key input to the HMAC algorithm. + # mac: "", # The HMAC to be verified. + # mac_algorithm: "HMAC_SHA_384", # The HMAC algorithm requested for the operation. + # message: "Hello World", # The message input to the HMAC algorithm. + # }) + # + # resp.to_h outputs the following: + # { + # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The key ARN of the HMAC key used in the operation. + # mac_algorithm: "HMAC_SHA_384", # The HMAC algorithm used in the operation. + # mac_valid: true, # A value of 'true' indicates that verification succeeded. If verification fails, the call to VerifyMac fails. + # } + # @example Request syntax with placeholder values + # + # resp = client.verify_mac({ + # message: "data", # required + # key_id: "KeyIdType", # required + # mac_algorithm: "HMAC_SHA_224", # required, accepts HMAC_SHA_224, HMAC_SHA_256, HMAC_SHA_384, HMAC_SHA_512 + # mac: "data", # required + # grant_tokens: ["GrantTokenType"], + # dry_run: false, + # }) + # @example Response structure + # + # resp.key_id #=> String + # resp.mac_valid #=> Boolean + # resp.mac_algorithm #=> String, one of "HMAC_SHA_224", "HMAC_SHA_256", "HMAC_SHA_384", "HMAC_SHA_512" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload verify_mac + # @param params [Hash] ({}) + # @return [Types::VerifyMacResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::VerifyMacResponse#key_id #key_id} => String + # * {Types::VerifyMacResponse#mac_valid #mac_valid} => Boolean + # * {Types::VerifyMacResponse#mac_algorithm #mac_algorithm} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/VerifyMac AWS API Documentation + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10740 + def verify_mac(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10764 + def waiter_names; end + + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10774 + def errors_module; end + + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/client.rb#10771 + def identifier; end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#12 +module Aws::KMS::ClientApi + include ::Seahorse::Model +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#1010 +Aws::KMS::ClientApi::API = T.let(T.unsafe(nil), Seahorse::Model::Api) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#16 +Aws::KMS::ClientApi::AWSAccountIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#17 +Aws::KMS::ClientApi::AlgorithmSpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#18 +Aws::KMS::ClientApi::AliasList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#19 +Aws::KMS::ClientApi::AliasListEntry = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#20 +Aws::KMS::ClientApi::AliasNameType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#21 +Aws::KMS::ClientApi::AlreadyExistsException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#22 +Aws::KMS::ClientApi::ArnType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#23 +Aws::KMS::ClientApi::AttestationDocumentType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BlobShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#24 +Aws::KMS::ClientApi::BooleanType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#25 +Aws::KMS::ClientApi::CancelKeyDeletionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#26 +Aws::KMS::ClientApi::CancelKeyDeletionResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#27 +Aws::KMS::ClientApi::CiphertextType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BlobShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#28 +Aws::KMS::ClientApi::CloudHsmClusterIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#29 +Aws::KMS::ClientApi::CloudHsmClusterInUseException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#30 +Aws::KMS::ClientApi::CloudHsmClusterInvalidConfigurationException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#31 +Aws::KMS::ClientApi::CloudHsmClusterNotActiveException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#32 +Aws::KMS::ClientApi::CloudHsmClusterNotFoundException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#33 +Aws::KMS::ClientApi::CloudHsmClusterNotRelatedException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#34 +Aws::KMS::ClientApi::ConflictException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#35 +Aws::KMS::ClientApi::ConnectCustomKeyStoreRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#36 +Aws::KMS::ClientApi::ConnectCustomKeyStoreResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#37 +Aws::KMS::ClientApi::ConnectionErrorCodeType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#38 +Aws::KMS::ClientApi::ConnectionStateType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#39 +Aws::KMS::ClientApi::CreateAliasRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#40 +Aws::KMS::ClientApi::CreateCustomKeyStoreRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#41 +Aws::KMS::ClientApi::CreateCustomKeyStoreResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#42 +Aws::KMS::ClientApi::CreateGrantRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#43 +Aws::KMS::ClientApi::CreateGrantResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#44 +Aws::KMS::ClientApi::CreateKeyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#45 +Aws::KMS::ClientApi::CreateKeyResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#46 +Aws::KMS::ClientApi::CustomKeyStoreHasCMKsException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#47 +Aws::KMS::ClientApi::CustomKeyStoreIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#48 +Aws::KMS::ClientApi::CustomKeyStoreInvalidStateException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#49 +Aws::KMS::ClientApi::CustomKeyStoreNameInUseException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#50 +Aws::KMS::ClientApi::CustomKeyStoreNameType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#51 +Aws::KMS::ClientApi::CustomKeyStoreNotFoundException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#52 +Aws::KMS::ClientApi::CustomKeyStoreType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#53 +Aws::KMS::ClientApi::CustomKeyStoresList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#54 +Aws::KMS::ClientApi::CustomKeyStoresListEntry = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#55 +Aws::KMS::ClientApi::CustomerMasterKeySpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#56 +Aws::KMS::ClientApi::DataKeyPairSpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#57 +Aws::KMS::ClientApi::DataKeySpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#58 +Aws::KMS::ClientApi::DateType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#59 +Aws::KMS::ClientApi::DecryptRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#60 +Aws::KMS::ClientApi::DecryptResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#61 +Aws::KMS::ClientApi::DeleteAliasRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#62 +Aws::KMS::ClientApi::DeleteCustomKeyStoreRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#63 +Aws::KMS::ClientApi::DeleteCustomKeyStoreResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#64 +Aws::KMS::ClientApi::DeleteImportedKeyMaterialRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#65 +Aws::KMS::ClientApi::DependencyTimeoutException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#66 +Aws::KMS::ClientApi::DeriveSharedSecretRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#67 +Aws::KMS::ClientApi::DeriveSharedSecretResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#68 +Aws::KMS::ClientApi::DescribeCustomKeyStoresRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#69 +Aws::KMS::ClientApi::DescribeCustomKeyStoresResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#70 +Aws::KMS::ClientApi::DescribeKeyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#71 +Aws::KMS::ClientApi::DescribeKeyResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#72 +Aws::KMS::ClientApi::DescriptionType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#73 +Aws::KMS::ClientApi::DisableKeyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#74 +Aws::KMS::ClientApi::DisableKeyRotationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#75 +Aws::KMS::ClientApi::DisabledException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#76 +Aws::KMS::ClientApi::DisconnectCustomKeyStoreRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#77 +Aws::KMS::ClientApi::DisconnectCustomKeyStoreResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#78 +Aws::KMS::ClientApi::DryRunOperationException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#79 +Aws::KMS::ClientApi::EnableKeyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#80 +Aws::KMS::ClientApi::EnableKeyRotationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#81 +Aws::KMS::ClientApi::EncryptRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#82 +Aws::KMS::ClientApi::EncryptResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#83 +Aws::KMS::ClientApi::EncryptionAlgorithmSpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#84 +Aws::KMS::ClientApi::EncryptionAlgorithmSpecList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#85 +Aws::KMS::ClientApi::EncryptionContextKey = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#86 +Aws::KMS::ClientApi::EncryptionContextType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::MapShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#87 +Aws::KMS::ClientApi::EncryptionContextValue = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#88 +Aws::KMS::ClientApi::ErrorMessageType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#89 +Aws::KMS::ClientApi::ExpirationModelType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#90 +Aws::KMS::ClientApi::ExpiredImportTokenException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#91 +Aws::KMS::ClientApi::GenerateDataKeyPairRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#92 +Aws::KMS::ClientApi::GenerateDataKeyPairResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#93 +Aws::KMS::ClientApi::GenerateDataKeyPairWithoutPlaintextRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#94 +Aws::KMS::ClientApi::GenerateDataKeyPairWithoutPlaintextResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#95 +Aws::KMS::ClientApi::GenerateDataKeyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#96 +Aws::KMS::ClientApi::GenerateDataKeyResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#97 +Aws::KMS::ClientApi::GenerateDataKeyWithoutPlaintextRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#98 +Aws::KMS::ClientApi::GenerateDataKeyWithoutPlaintextResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#99 +Aws::KMS::ClientApi::GenerateMacRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#100 +Aws::KMS::ClientApi::GenerateMacResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#101 +Aws::KMS::ClientApi::GenerateRandomRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#102 +Aws::KMS::ClientApi::GenerateRandomResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#103 +Aws::KMS::ClientApi::GetKeyPolicyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#104 +Aws::KMS::ClientApi::GetKeyPolicyResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#105 +Aws::KMS::ClientApi::GetKeyRotationStatusRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#106 +Aws::KMS::ClientApi::GetKeyRotationStatusResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#107 +Aws::KMS::ClientApi::GetParametersForImportRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#108 +Aws::KMS::ClientApi::GetParametersForImportResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#109 +Aws::KMS::ClientApi::GetPublicKeyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#110 +Aws::KMS::ClientApi::GetPublicKeyResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#111 +Aws::KMS::ClientApi::GrantConstraints = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#112 +Aws::KMS::ClientApi::GrantIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#113 +Aws::KMS::ClientApi::GrantList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#114 +Aws::KMS::ClientApi::GrantListEntry = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#115 +Aws::KMS::ClientApi::GrantNameType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#116 +Aws::KMS::ClientApi::GrantOperation = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#117 +Aws::KMS::ClientApi::GrantOperationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#118 +Aws::KMS::ClientApi::GrantTokenList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#119 +Aws::KMS::ClientApi::GrantTokenType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#120 +Aws::KMS::ClientApi::ImportKeyMaterialRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#121 +Aws::KMS::ClientApi::ImportKeyMaterialResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#122 +Aws::KMS::ClientApi::IncorrectKeyException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#123 +Aws::KMS::ClientApi::IncorrectKeyMaterialException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#124 +Aws::KMS::ClientApi::IncorrectTrustAnchorException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#125 +Aws::KMS::ClientApi::InvalidAliasNameException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#126 +Aws::KMS::ClientApi::InvalidArnException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#127 +Aws::KMS::ClientApi::InvalidCiphertextException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#128 +Aws::KMS::ClientApi::InvalidGrantIdException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#129 +Aws::KMS::ClientApi::InvalidGrantTokenException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#130 +Aws::KMS::ClientApi::InvalidImportTokenException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#131 +Aws::KMS::ClientApi::InvalidKeyUsageException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#132 +Aws::KMS::ClientApi::InvalidMarkerException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#133 +Aws::KMS::ClientApi::KMSInternalException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#134 +Aws::KMS::ClientApi::KMSInvalidMacException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#135 +Aws::KMS::ClientApi::KMSInvalidSignatureException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#136 +Aws::KMS::ClientApi::KMSInvalidStateException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#137 +Aws::KMS::ClientApi::KeyAgreementAlgorithmSpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#138 +Aws::KMS::ClientApi::KeyAgreementAlgorithmSpecList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#139 +Aws::KMS::ClientApi::KeyEncryptionMechanism = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#140 +Aws::KMS::ClientApi::KeyIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#141 +Aws::KMS::ClientApi::KeyList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#142 +Aws::KMS::ClientApi::KeyListEntry = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#143 +Aws::KMS::ClientApi::KeyManagerType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#144 +Aws::KMS::ClientApi::KeyMetadata = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#145 +Aws::KMS::ClientApi::KeySpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#146 +Aws::KMS::ClientApi::KeyState = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#147 +Aws::KMS::ClientApi::KeyStorePasswordType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#148 +Aws::KMS::ClientApi::KeyUnavailableException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#149 +Aws::KMS::ClientApi::KeyUsageType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#150 +Aws::KMS::ClientApi::LimitExceededException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#151 +Aws::KMS::ClientApi::LimitType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#152 +Aws::KMS::ClientApi::ListAliasesRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#153 +Aws::KMS::ClientApi::ListAliasesResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#154 +Aws::KMS::ClientApi::ListGrantsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#155 +Aws::KMS::ClientApi::ListGrantsResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#156 +Aws::KMS::ClientApi::ListKeyPoliciesRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#157 +Aws::KMS::ClientApi::ListKeyPoliciesResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#158 +Aws::KMS::ClientApi::ListKeyRotationsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#159 +Aws::KMS::ClientApi::ListKeyRotationsResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#160 +Aws::KMS::ClientApi::ListKeysRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#161 +Aws::KMS::ClientApi::ListKeysResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#162 +Aws::KMS::ClientApi::ListResourceTagsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#163 +Aws::KMS::ClientApi::ListResourceTagsResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#164 +Aws::KMS::ClientApi::ListRetirableGrantsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#165 +Aws::KMS::ClientApi::MacAlgorithmSpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#166 +Aws::KMS::ClientApi::MacAlgorithmSpecList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#167 +Aws::KMS::ClientApi::MalformedPolicyDocumentException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#168 +Aws::KMS::ClientApi::MarkerType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#169 +Aws::KMS::ClientApi::MessageType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#170 +Aws::KMS::ClientApi::MultiRegionConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#171 +Aws::KMS::ClientApi::MultiRegionKey = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#172 +Aws::KMS::ClientApi::MultiRegionKeyList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#173 +Aws::KMS::ClientApi::MultiRegionKeyType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#174 +Aws::KMS::ClientApi::NotFoundException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#175 +Aws::KMS::ClientApi::NullableBooleanType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#176 +Aws::KMS::ClientApi::NumberOfBytesType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#177 +Aws::KMS::ClientApi::OriginType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#178 +Aws::KMS::ClientApi::PendingWindowInDaysType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#179 +Aws::KMS::ClientApi::PlaintextType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BlobShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#180 +Aws::KMS::ClientApi::PolicyNameList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#181 +Aws::KMS::ClientApi::PolicyNameType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#182 +Aws::KMS::ClientApi::PolicyType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#183 +Aws::KMS::ClientApi::PrincipalIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#184 +Aws::KMS::ClientApi::PublicKeyType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BlobShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#185 +Aws::KMS::ClientApi::PutKeyPolicyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#186 +Aws::KMS::ClientApi::ReEncryptRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#187 +Aws::KMS::ClientApi::ReEncryptResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#188 +Aws::KMS::ClientApi::RecipientInfo = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#189 +Aws::KMS::ClientApi::RegionType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#190 +Aws::KMS::ClientApi::ReplicateKeyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#191 +Aws::KMS::ClientApi::ReplicateKeyResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#192 +Aws::KMS::ClientApi::RetireGrantRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#193 +Aws::KMS::ClientApi::RevokeGrantRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#194 +Aws::KMS::ClientApi::RotateKeyOnDemandRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#195 +Aws::KMS::ClientApi::RotateKeyOnDemandResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#196 +Aws::KMS::ClientApi::RotationPeriodInDaysType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#197 +Aws::KMS::ClientApi::RotationType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#198 +Aws::KMS::ClientApi::RotationsList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#199 +Aws::KMS::ClientApi::RotationsListEntry = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#200 +Aws::KMS::ClientApi::ScheduleKeyDeletionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#201 +Aws::KMS::ClientApi::ScheduleKeyDeletionResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#202 +Aws::KMS::ClientApi::SignRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#203 +Aws::KMS::ClientApi::SignResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#204 +Aws::KMS::ClientApi::SigningAlgorithmSpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#205 +Aws::KMS::ClientApi::SigningAlgorithmSpecList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#206 +Aws::KMS::ClientApi::Tag = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#207 +Aws::KMS::ClientApi::TagException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#208 +Aws::KMS::ClientApi::TagKeyList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#209 +Aws::KMS::ClientApi::TagKeyType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#210 +Aws::KMS::ClientApi::TagList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#211 +Aws::KMS::ClientApi::TagResourceRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#212 +Aws::KMS::ClientApi::TagValueType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#213 +Aws::KMS::ClientApi::TrustAnchorCertificateType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#214 +Aws::KMS::ClientApi::UnsupportedOperationException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#215 +Aws::KMS::ClientApi::UntagResourceRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#216 +Aws::KMS::ClientApi::UpdateAliasRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#217 +Aws::KMS::ClientApi::UpdateCustomKeyStoreRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#218 +Aws::KMS::ClientApi::UpdateCustomKeyStoreResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#219 +Aws::KMS::ClientApi::UpdateKeyDescriptionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#220 +Aws::KMS::ClientApi::UpdatePrimaryRegionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#221 +Aws::KMS::ClientApi::VerifyMacRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#222 +Aws::KMS::ClientApi::VerifyMacResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#223 +Aws::KMS::ClientApi::VerifyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#224 +Aws::KMS::ClientApi::VerifyResponse = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#225 +Aws::KMS::ClientApi::WrappingKeySpec = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#226 +Aws::KMS::ClientApi::XksKeyAlreadyInUseException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#227 +Aws::KMS::ClientApi::XksKeyConfigurationType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#228 +Aws::KMS::ClientApi::XksKeyIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#229 +Aws::KMS::ClientApi::XksKeyInvalidConfigurationException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#230 +Aws::KMS::ClientApi::XksKeyNotFoundException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#231 +Aws::KMS::ClientApi::XksProxyAuthenticationAccessKeyIdType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#232 +Aws::KMS::ClientApi::XksProxyAuthenticationCredentialType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#233 +Aws::KMS::ClientApi::XksProxyAuthenticationRawSecretAccessKeyType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#234 +Aws::KMS::ClientApi::XksProxyConfigurationType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#235 +Aws::KMS::ClientApi::XksProxyConnectivityType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#236 +Aws::KMS::ClientApi::XksProxyIncorrectAuthenticationCredentialException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#237 +Aws::KMS::ClientApi::XksProxyInvalidConfigurationException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#238 +Aws::KMS::ClientApi::XksProxyInvalidResponseException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#239 +Aws::KMS::ClientApi::XksProxyUriEndpointInUseException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#240 +Aws::KMS::ClientApi::XksProxyUriEndpointType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#241 +Aws::KMS::ClientApi::XksProxyUriInUseException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#242 +Aws::KMS::ClientApi::XksProxyUriPathType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#243 +Aws::KMS::ClientApi::XksProxyUriUnreachableException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#244 +Aws::KMS::ClientApi::XksProxyVpcEndpointServiceInUseException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#245 +Aws::KMS::ClientApi::XksProxyVpcEndpointServiceInvalidConfigurationException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#246 +Aws::KMS::ClientApi::XksProxyVpcEndpointServiceNameType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/client_api.rb#247 +Aws::KMS::ClientApi::XksProxyVpcEndpointServiceNotFoundException = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# Endpoint parameters used to influence endpoints per request. +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoint_parameters.rb#33 +class Aws::KMS::EndpointParameters < ::Struct + include ::Aws::Structure + + # @return [EndpointParameters] a new instance of EndpointParameters + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoint_parameters.rb#51 + def initialize(options = T.unsafe(nil)); end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint; end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint=(_); end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region; end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region=(_); end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack; end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack=(_); end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips; end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoint_provider.rb#11 +class Aws::KMS::EndpointProvider + # @raise [ArgumentError] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoint_provider.rb#12 + def resolve_endpoint(parameters); end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#13 +module Aws::KMS::Endpoints; end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#15 +class Aws::KMS::Endpoints::CancelKeyDeletion + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#16 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#29 +class Aws::KMS::Endpoints::ConnectCustomKeyStore + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#30 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#43 +class Aws::KMS::Endpoints::CreateAlias + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#44 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#57 +class Aws::KMS::Endpoints::CreateCustomKeyStore + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#58 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#71 +class Aws::KMS::Endpoints::CreateGrant + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#72 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#85 +class Aws::KMS::Endpoints::CreateKey + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#86 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#99 +class Aws::KMS::Endpoints::Decrypt + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#100 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#113 +class Aws::KMS::Endpoints::DeleteAlias + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#114 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#127 +class Aws::KMS::Endpoints::DeleteCustomKeyStore + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#128 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#141 +class Aws::KMS::Endpoints::DeleteImportedKeyMaterial + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#142 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#155 +class Aws::KMS::Endpoints::DeriveSharedSecret + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#156 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#169 +class Aws::KMS::Endpoints::DescribeCustomKeyStores + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#170 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#183 +class Aws::KMS::Endpoints::DescribeKey + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#184 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#197 +class Aws::KMS::Endpoints::DisableKey + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#198 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#211 +class Aws::KMS::Endpoints::DisableKeyRotation + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#212 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#225 +class Aws::KMS::Endpoints::DisconnectCustomKeyStore + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#226 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#239 +class Aws::KMS::Endpoints::EnableKey + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#240 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#253 +class Aws::KMS::Endpoints::EnableKeyRotation + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#254 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#267 +class Aws::KMS::Endpoints::Encrypt + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#268 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#281 +class Aws::KMS::Endpoints::GenerateDataKey + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#282 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#295 +class Aws::KMS::Endpoints::GenerateDataKeyPair + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#296 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#309 +class Aws::KMS::Endpoints::GenerateDataKeyPairWithoutPlaintext + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#310 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#323 +class Aws::KMS::Endpoints::GenerateDataKeyWithoutPlaintext + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#324 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#337 +class Aws::KMS::Endpoints::GenerateMac + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#338 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#351 +class Aws::KMS::Endpoints::GenerateRandom + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#352 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#365 +class Aws::KMS::Endpoints::GetKeyPolicy + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#366 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#379 +class Aws::KMS::Endpoints::GetKeyRotationStatus + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#380 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#393 +class Aws::KMS::Endpoints::GetParametersForImport + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#394 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#407 +class Aws::KMS::Endpoints::GetPublicKey + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#408 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#421 +class Aws::KMS::Endpoints::ImportKeyMaterial + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#422 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#435 +class Aws::KMS::Endpoints::ListAliases + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#436 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#449 +class Aws::KMS::Endpoints::ListGrants + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#450 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#463 +class Aws::KMS::Endpoints::ListKeyPolicies + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#464 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#477 +class Aws::KMS::Endpoints::ListKeyRotations + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#478 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#491 +class Aws::KMS::Endpoints::ListKeys + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#492 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#505 +class Aws::KMS::Endpoints::ListResourceTags + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#506 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#519 +class Aws::KMS::Endpoints::ListRetirableGrants + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#520 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#533 +class Aws::KMS::Endpoints::PutKeyPolicy + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#534 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#547 +class Aws::KMS::Endpoints::ReEncrypt + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#548 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#561 +class Aws::KMS::Endpoints::ReplicateKey + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#562 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#575 +class Aws::KMS::Endpoints::RetireGrant + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#576 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#589 +class Aws::KMS::Endpoints::RevokeGrant + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#590 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#603 +class Aws::KMS::Endpoints::RotateKeyOnDemand + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#604 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#617 +class Aws::KMS::Endpoints::ScheduleKeyDeletion + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#618 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#631 +class Aws::KMS::Endpoints::Sign + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#632 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#645 +class Aws::KMS::Endpoints::TagResource + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#646 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#659 +class Aws::KMS::Endpoints::UntagResource + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#660 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#673 +class Aws::KMS::Endpoints::UpdateAlias + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#674 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#687 +class Aws::KMS::Endpoints::UpdateCustomKeyStore + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#688 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#701 +class Aws::KMS::Endpoints::UpdateKeyDescription + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#702 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#715 +class Aws::KMS::Endpoints::UpdatePrimaryRegion + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#716 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#729 +class Aws::KMS::Endpoints::Verify + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#730 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#743 +class Aws::KMS::Endpoints::VerifyMac + class << self + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/endpoints.rb#744 + def build(context); end + end +end + +# When KMS returns an error response, the Ruby SDK constructs and raises an error. +# These errors all extend Aws::KMS::Errors::ServiceError < {Aws::Errors::ServiceError} +# +# You can rescue all KMS errors using ServiceError: +# +# begin +# # do stuff +# rescue Aws::KMS::Errors::ServiceError +# # rescues all KMS API errors +# end +# +# +# ## Request Context +# ServiceError objects have a {Aws::Errors::ServiceError#context #context} method that returns +# information about the request that generated the error. +# See {Seahorse::Client::RequestContext} for more information. +# +# ## Error Classes +# * {AlreadyExistsException} +# * {CloudHsmClusterInUseException} +# * {CloudHsmClusterInvalidConfigurationException} +# * {CloudHsmClusterNotActiveException} +# * {CloudHsmClusterNotFoundException} +# * {CloudHsmClusterNotRelatedException} +# * {ConflictException} +# * {CustomKeyStoreHasCMKsException} +# * {CustomKeyStoreInvalidStateException} +# * {CustomKeyStoreNameInUseException} +# * {CustomKeyStoreNotFoundException} +# * {DependencyTimeoutException} +# * {DisabledException} +# * {DryRunOperationException} +# * {ExpiredImportTokenException} +# * {IncorrectKeyException} +# * {IncorrectKeyMaterialException} +# * {IncorrectTrustAnchorException} +# * {InvalidAliasNameException} +# * {InvalidArnException} +# * {InvalidCiphertextException} +# * {InvalidGrantIdException} +# * {InvalidGrantTokenException} +# * {InvalidImportTokenException} +# * {InvalidKeyUsageException} +# * {InvalidMarkerException} +# * {KMSInternalException} +# * {KMSInvalidMacException} +# * {KMSInvalidSignatureException} +# * {KMSInvalidStateException} +# * {KeyUnavailableException} +# * {LimitExceededException} +# * {MalformedPolicyDocumentException} +# * {NotFoundException} +# * {TagException} +# * {UnsupportedOperationException} +# * {XksKeyAlreadyInUseException} +# * {XksKeyInvalidConfigurationException} +# * {XksKeyNotFoundException} +# * {XksProxyIncorrectAuthenticationCredentialException} +# * {XksProxyInvalidConfigurationException} +# * {XksProxyInvalidResponseException} +# * {XksProxyUriEndpointInUseException} +# * {XksProxyUriInUseException} +# * {XksProxyUriUnreachableException} +# * {XksProxyVpcEndpointServiceInUseException} +# * {XksProxyVpcEndpointServiceInvalidConfigurationException} +# * {XksProxyVpcEndpointServiceNotFoundException} +# +# Additionally, error classes are dynamically generated for service errors based on the error code +# if they are not defined above. +# +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#81 +module Aws::KMS::Errors + extend ::Aws::Errors::DynamicErrors +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#85 +class Aws::KMS::Errors::AlreadyExistsException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::AlreadyExistsException] + # @return [AlreadyExistsException] a new instance of AlreadyExistsException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#90 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#95 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#100 +class Aws::KMS::Errors::CloudHsmClusterInUseException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CloudHsmClusterInUseException] + # @return [CloudHsmClusterInUseException] a new instance of CloudHsmClusterInUseException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#105 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#110 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#115 +class Aws::KMS::Errors::CloudHsmClusterInvalidConfigurationException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CloudHsmClusterInvalidConfigurationException] + # @return [CloudHsmClusterInvalidConfigurationException] a new instance of CloudHsmClusterInvalidConfigurationException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#120 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#125 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#130 +class Aws::KMS::Errors::CloudHsmClusterNotActiveException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CloudHsmClusterNotActiveException] + # @return [CloudHsmClusterNotActiveException] a new instance of CloudHsmClusterNotActiveException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#135 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#140 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#145 +class Aws::KMS::Errors::CloudHsmClusterNotFoundException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CloudHsmClusterNotFoundException] + # @return [CloudHsmClusterNotFoundException] a new instance of CloudHsmClusterNotFoundException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#150 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#155 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#160 +class Aws::KMS::Errors::CloudHsmClusterNotRelatedException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CloudHsmClusterNotRelatedException] + # @return [CloudHsmClusterNotRelatedException] a new instance of CloudHsmClusterNotRelatedException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#165 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#170 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#175 +class Aws::KMS::Errors::ConflictException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::ConflictException] + # @return [ConflictException] a new instance of ConflictException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#180 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#185 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#190 +class Aws::KMS::Errors::CustomKeyStoreHasCMKsException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CustomKeyStoreHasCMKsException] + # @return [CustomKeyStoreHasCMKsException] a new instance of CustomKeyStoreHasCMKsException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#195 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#200 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#205 +class Aws::KMS::Errors::CustomKeyStoreInvalidStateException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CustomKeyStoreInvalidStateException] + # @return [CustomKeyStoreInvalidStateException] a new instance of CustomKeyStoreInvalidStateException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#210 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#215 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#220 +class Aws::KMS::Errors::CustomKeyStoreNameInUseException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CustomKeyStoreNameInUseException] + # @return [CustomKeyStoreNameInUseException] a new instance of CustomKeyStoreNameInUseException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#225 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#230 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#235 +class Aws::KMS::Errors::CustomKeyStoreNotFoundException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::CustomKeyStoreNotFoundException] + # @return [CustomKeyStoreNotFoundException] a new instance of CustomKeyStoreNotFoundException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#240 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#245 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#250 +class Aws::KMS::Errors::DependencyTimeoutException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::DependencyTimeoutException] + # @return [DependencyTimeoutException] a new instance of DependencyTimeoutException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#255 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#260 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#265 +class Aws::KMS::Errors::DisabledException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::DisabledException] + # @return [DisabledException] a new instance of DisabledException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#270 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#275 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#280 +class Aws::KMS::Errors::DryRunOperationException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::DryRunOperationException] + # @return [DryRunOperationException] a new instance of DryRunOperationException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#285 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#290 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#295 +class Aws::KMS::Errors::ExpiredImportTokenException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::ExpiredImportTokenException] + # @return [ExpiredImportTokenException] a new instance of ExpiredImportTokenException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#300 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#305 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#310 +class Aws::KMS::Errors::IncorrectKeyException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::IncorrectKeyException] + # @return [IncorrectKeyException] a new instance of IncorrectKeyException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#315 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#320 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#325 +class Aws::KMS::Errors::IncorrectKeyMaterialException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::IncorrectKeyMaterialException] + # @return [IncorrectKeyMaterialException] a new instance of IncorrectKeyMaterialException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#330 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#335 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#340 +class Aws::KMS::Errors::IncorrectTrustAnchorException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::IncorrectTrustAnchorException] + # @return [IncorrectTrustAnchorException] a new instance of IncorrectTrustAnchorException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#345 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#350 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#355 +class Aws::KMS::Errors::InvalidAliasNameException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidAliasNameException] + # @return [InvalidAliasNameException] a new instance of InvalidAliasNameException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#360 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#365 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#370 +class Aws::KMS::Errors::InvalidArnException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidArnException] + # @return [InvalidArnException] a new instance of InvalidArnException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#375 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#380 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#385 +class Aws::KMS::Errors::InvalidCiphertextException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidCiphertextException] + # @return [InvalidCiphertextException] a new instance of InvalidCiphertextException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#390 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#395 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#400 +class Aws::KMS::Errors::InvalidGrantIdException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidGrantIdException] + # @return [InvalidGrantIdException] a new instance of InvalidGrantIdException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#405 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#410 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#415 +class Aws::KMS::Errors::InvalidGrantTokenException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidGrantTokenException] + # @return [InvalidGrantTokenException] a new instance of InvalidGrantTokenException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#420 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#425 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#430 +class Aws::KMS::Errors::InvalidImportTokenException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidImportTokenException] + # @return [InvalidImportTokenException] a new instance of InvalidImportTokenException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#435 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#440 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#445 +class Aws::KMS::Errors::InvalidKeyUsageException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidKeyUsageException] + # @return [InvalidKeyUsageException] a new instance of InvalidKeyUsageException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#450 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#455 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#460 +class Aws::KMS::Errors::InvalidMarkerException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::InvalidMarkerException] + # @return [InvalidMarkerException] a new instance of InvalidMarkerException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#465 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#470 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#475 +class Aws::KMS::Errors::KMSInternalException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::KMSInternalException] + # @return [KMSInternalException] a new instance of KMSInternalException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#480 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#485 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#490 +class Aws::KMS::Errors::KMSInvalidMacException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::KMSInvalidMacException] + # @return [KMSInvalidMacException] a new instance of KMSInvalidMacException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#495 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#500 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#505 +class Aws::KMS::Errors::KMSInvalidSignatureException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::KMSInvalidSignatureException] + # @return [KMSInvalidSignatureException] a new instance of KMSInvalidSignatureException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#510 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#515 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#520 +class Aws::KMS::Errors::KMSInvalidStateException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::KMSInvalidStateException] + # @return [KMSInvalidStateException] a new instance of KMSInvalidStateException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#525 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#530 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#535 +class Aws::KMS::Errors::KeyUnavailableException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::KeyUnavailableException] + # @return [KeyUnavailableException] a new instance of KeyUnavailableException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#540 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#545 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#550 +class Aws::KMS::Errors::LimitExceededException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::LimitExceededException] + # @return [LimitExceededException] a new instance of LimitExceededException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#555 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#560 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#565 +class Aws::KMS::Errors::MalformedPolicyDocumentException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::MalformedPolicyDocumentException] + # @return [MalformedPolicyDocumentException] a new instance of MalformedPolicyDocumentException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#570 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#575 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#580 +class Aws::KMS::Errors::NotFoundException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::NotFoundException] + # @return [NotFoundException] a new instance of NotFoundException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#585 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#590 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#0 +class Aws::KMS::Errors::ServiceError < ::Aws::Errors::ServiceError; end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#595 +class Aws::KMS::Errors::TagException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::TagException] + # @return [TagException] a new instance of TagException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#600 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#605 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#610 +class Aws::KMS::Errors::UnsupportedOperationException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::UnsupportedOperationException] + # @return [UnsupportedOperationException] a new instance of UnsupportedOperationException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#615 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#620 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#625 +class Aws::KMS::Errors::XksKeyAlreadyInUseException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksKeyAlreadyInUseException] + # @return [XksKeyAlreadyInUseException] a new instance of XksKeyAlreadyInUseException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#630 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#635 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#640 +class Aws::KMS::Errors::XksKeyInvalidConfigurationException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksKeyInvalidConfigurationException] + # @return [XksKeyInvalidConfigurationException] a new instance of XksKeyInvalidConfigurationException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#645 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#650 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#655 +class Aws::KMS::Errors::XksKeyNotFoundException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksKeyNotFoundException] + # @return [XksKeyNotFoundException] a new instance of XksKeyNotFoundException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#660 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#665 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#670 +class Aws::KMS::Errors::XksProxyIncorrectAuthenticationCredentialException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyIncorrectAuthenticationCredentialException] + # @return [XksProxyIncorrectAuthenticationCredentialException] a new instance of XksProxyIncorrectAuthenticationCredentialException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#675 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#680 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#685 +class Aws::KMS::Errors::XksProxyInvalidConfigurationException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyInvalidConfigurationException] + # @return [XksProxyInvalidConfigurationException] a new instance of XksProxyInvalidConfigurationException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#690 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#695 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#700 +class Aws::KMS::Errors::XksProxyInvalidResponseException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyInvalidResponseException] + # @return [XksProxyInvalidResponseException] a new instance of XksProxyInvalidResponseException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#705 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#710 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#715 +class Aws::KMS::Errors::XksProxyUriEndpointInUseException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyUriEndpointInUseException] + # @return [XksProxyUriEndpointInUseException] a new instance of XksProxyUriEndpointInUseException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#720 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#725 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#730 +class Aws::KMS::Errors::XksProxyUriInUseException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyUriInUseException] + # @return [XksProxyUriInUseException] a new instance of XksProxyUriInUseException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#735 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#740 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#745 +class Aws::KMS::Errors::XksProxyUriUnreachableException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyUriUnreachableException] + # @return [XksProxyUriUnreachableException] a new instance of XksProxyUriUnreachableException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#750 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#755 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#760 +class Aws::KMS::Errors::XksProxyVpcEndpointServiceInUseException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyVpcEndpointServiceInUseException] + # @return [XksProxyVpcEndpointServiceInUseException] a new instance of XksProxyVpcEndpointServiceInUseException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#765 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#770 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#775 +class Aws::KMS::Errors::XksProxyVpcEndpointServiceInvalidConfigurationException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyVpcEndpointServiceInvalidConfigurationException] + # @return [XksProxyVpcEndpointServiceInvalidConfigurationException] a new instance of XksProxyVpcEndpointServiceInvalidConfigurationException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#780 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#785 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#790 +class Aws::KMS::Errors::XksProxyVpcEndpointServiceNotFoundException < ::Aws::KMS::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::KMS::Types::XksProxyVpcEndpointServiceNotFoundException] + # @return [XksProxyVpcEndpointServiceNotFoundException] a new instance of XksProxyVpcEndpointServiceNotFoundException + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#795 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/errors.rb#800 + def message; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms.rb#55 +Aws::KMS::GEM_VERSION = T.let(T.unsafe(nil), String) + +# source://aws-sdk-kms//lib/aws-sdk-kms/plugins/endpoints.rb#12 +module Aws::KMS::Plugins; end + +# source://aws-sdk-kms//lib/aws-sdk-kms/plugins/endpoints.rb#13 +class Aws::KMS::Plugins::Endpoints < ::Seahorse::Client::Plugin + # source://aws-sdk-kms//lib/aws-sdk-kms/plugins/endpoints.rb#171 + def add_handlers(handlers, _config); end +end + +# @api private +# +# source://aws-sdk-kms//lib/aws-sdk-kms/plugins/endpoints.rb#27 +class Aws::KMS::Plugins::Endpoints::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/plugins/endpoints.rb#28 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/plugins/endpoints.rb#48 + def apply_endpoint_headers(context, headers); end + + # @api private + # + # source://aws-sdk-kms//lib/aws-sdk-kms/plugins/endpoints.rb#59 + def parameters_for_operation(context); end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/resource.rb#12 +class Aws::KMS::Resource + # @option options + # @param options [{}] + # @return [Resource] a new instance of Resource + # + # source://aws-sdk-kms//lib/aws-sdk-kms/resource.rb#16 + def initialize(options = T.unsafe(nil)); end + + # @return [Client] + # + # source://aws-sdk-kms//lib/aws-sdk-kms/resource.rb#21 + def client; end +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#11 +module Aws::KMS::Types; end + +# Contains information about an alias. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/AliasListEntry AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#45 +class Aws::KMS::Types::AliasListEntry < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#46 +Aws::KMS::Types::AliasListEntry::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because it attempted to create a resource +# that already exists. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/AlreadyExistsException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#59 +class Aws::KMS::Types::AlreadyExistsException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#60 +Aws::KMS::Types::AlreadyExistsException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CancelKeyDeletionRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#83 +class Aws::KMS::Types::CancelKeyDeletionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#84 +Aws::KMS::Types::CancelKeyDeletionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CancelKeyDeletionResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#100 +class Aws::KMS::Types::CancelKeyDeletionResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#101 +Aws::KMS::Types::CancelKeyDeletionResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified CloudHSM cluster is +# already associated with an CloudHSM key store in the account, or it +# shares a backup history with an CloudHSM key store in the account. +# Each CloudHSM key store in the account must be associated with a +# different CloudHSM cluster. +# +# CloudHSM clusters that share a backup history have the same cluster +# certificate. To view the cluster certificate of an CloudHSM cluster, +# use the [DescribeClusters][1] operation. +# +# +# +# [1]: https://docs.aws.amazon.com/cloudhsm/latest/APIReference/API_DescribeClusters.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CloudHsmClusterInUseException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#125 +class Aws::KMS::Types::CloudHsmClusterInUseException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#126 +Aws::KMS::Types::CloudHsmClusterInUseException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the associated CloudHSM cluster did +# not meet the configuration requirements for an CloudHSM key store. +# +# * The CloudHSM cluster must be configured with private subnets in at +# least two different Availability Zones in the Region. +# +# * The [security group for the cluster][1] +# (cloudhsm-cluster-*<cluster-id>*-sg) must include inbound +# rules and outbound rules that allow TCP traffic on ports 2223-2225. +# The **Source** in the inbound rules and the **Destination** in the +# outbound rules must match the security group ID. These rules are set +# by default when you create the CloudHSM cluster. Do not delete or +# change them. To get information about a particular security group, +# use the [DescribeSecurityGroups][2] operation. +# +# * The CloudHSM cluster must contain at least as many HSMs as the +# operation requires. To add HSMs, use the CloudHSM [CreateHsm][3] +# operation. +# +# For the CreateCustomKeyStore, UpdateCustomKeyStore, and CreateKey +# operations, the CloudHSM cluster must have at least two active HSMs, +# each in a different Availability Zone. For the ConnectCustomKeyStore +# operation, the CloudHSM must contain at least one active HSM. +# +# For information about the requirements for an CloudHSM cluster that is +# associated with an CloudHSM key store, see [Assemble the +# Prerequisites][4] in the *Key Management Service Developer Guide*. For +# information about creating a private subnet for an CloudHSM cluster, +# see [Create a Private Subnet][5] in the *CloudHSM User Guide*. For +# information about cluster security groups, see [Configure a Default +# Security Group][1] in the CloudHSM User Guide . +# +# +# +# [1]: https://docs.aws.amazon.com/cloudhsm/latest/userguide/configure-sg.html +# [2]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSecurityGroups.html +# [3]: https://docs.aws.amazon.com/cloudhsm/latest/APIReference/API_CreateHsm.html +# [4]: https://docs.aws.amazon.com/kms/latest/developerguide/create-keystore.html#before-keystore +# [5]: https://docs.aws.amazon.com/cloudhsm/latest/userguide/create-subnets.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CloudHsmClusterInvalidConfigurationException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#176 +class Aws::KMS::Types::CloudHsmClusterInvalidConfigurationException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#177 +Aws::KMS::Types::CloudHsmClusterInvalidConfigurationException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the CloudHSM cluster associated with +# the CloudHSM key store is not active. Initialize and activate the +# cluster and try the command again. For detailed instructions, see +# [Getting Started][1] in the *CloudHSM User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/cloudhsm/latest/userguide/getting-started.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CloudHsmClusterNotActiveException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#196 +class Aws::KMS::Types::CloudHsmClusterNotActiveException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#197 +Aws::KMS::Types::CloudHsmClusterNotActiveException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because KMS cannot find the CloudHSM cluster +# with the specified cluster ID. Retry the request with a different +# cluster ID. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CloudHsmClusterNotFoundException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#211 +class Aws::KMS::Types::CloudHsmClusterNotFoundException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#212 +Aws::KMS::Types::CloudHsmClusterNotFoundException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified CloudHSM cluster has a +# different cluster certificate than the original cluster. You cannot +# use the operation to specify an unrelated cluster for an CloudHSM key +# store. +# +# Specify an CloudHSM cluster that shares a backup history with the +# original cluster. This includes clusters that were created from a +# backup of the current cluster, and clusters that were created from the +# same backup that produced the current cluster. +# +# CloudHSM clusters that share a backup history have the same cluster +# certificate. To view the cluster certificate of an CloudHSM cluster, +# use the [DescribeClusters][1] operation. +# +# +# +# [1]: https://docs.aws.amazon.com/cloudhsm/latest/APIReference/API_DescribeClusters.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CloudHsmClusterNotRelatedException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#240 +class Aws::KMS::Types::CloudHsmClusterNotRelatedException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#241 +Aws::KMS::Types::CloudHsmClusterNotRelatedException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because an automatic rotation of this key is +# currently in progress or scheduled to begin within the next 20 +# minutes. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ConflictException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#255 +class Aws::KMS::Types::ConflictException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#256 +Aws::KMS::Types::ConflictException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ConnectCustomKeyStoreRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#269 +class Aws::KMS::Types::ConnectCustomKeyStoreRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#270 +Aws::KMS::Types::ConnectCustomKeyStoreRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ConnectCustomKeyStoreResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#276 +class Aws::KMS::Types::ConnectCustomKeyStoreResponse < ::Aws::EmptyStructure; end + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateAliasRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#330 +class Aws::KMS::Types::CreateAliasRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#331 +Aws::KMS::Types::CreateAliasRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateCustomKeyStoreRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#553 +class Aws::KMS::Types::CreateCustomKeyStoreRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#554 +Aws::KMS::Types::CreateCustomKeyStoreRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateCustomKeyStoreResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#565 +class Aws::KMS::Types::CreateCustomKeyStoreResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#566 +Aws::KMS::Types::CreateCustomKeyStoreResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateGrantRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#743 +class Aws::KMS::Types::CreateGrantRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#744 +Aws::KMS::Types::CreateGrantRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateGrantResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#773 +class Aws::KMS::Types::CreateGrantResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#774 +Aws::KMS::Types::CreateGrantResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateKeyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1143 +class Aws::KMS::Types::CreateKeyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1144 +Aws::KMS::Types::CreateKeyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CreateKeyResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1155 +class Aws::KMS::Types::CreateKeyResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1156 +Aws::KMS::Types::CreateKeyResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the custom key store contains KMS +# keys. After verifying that you do not need to use the KMS keys, use +# the ScheduleKeyDeletion operation to delete the KMS keys. After they +# are deleted, you can delete the custom key store. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CustomKeyStoreHasCMKsException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1171 +class Aws::KMS::Types::CustomKeyStoreHasCMKsException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1172 +Aws::KMS::Types::CustomKeyStoreHasCMKsException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because of the `ConnectionState` of the +# custom key store. To get the `ConnectionState` of a custom key store, +# use the DescribeCustomKeyStores operation. +# +# This exception is thrown under the following conditions: +# +# * You requested the ConnectCustomKeyStore operation on a custom key +# store with a `ConnectionState` of `DISCONNECTING` or `FAILED`. This +# operation is valid for all other `ConnectionState` values. To +# reconnect a custom key store in a `FAILED` state, disconnect it +# (DisconnectCustomKeyStore), then connect it +# (`ConnectCustomKeyStore`). +# +# * You requested the CreateKey operation in a custom key store that is +# not connected. This operations is valid only when the custom key +# store `ConnectionState` is `CONNECTED`. +# +# * You requested the DisconnectCustomKeyStore operation on a custom key +# store with a `ConnectionState` of `DISCONNECTING` or `DISCONNECTED`. +# This operation is valid for all other `ConnectionState` values. +# +# * You requested the UpdateCustomKeyStore or DeleteCustomKeyStore +# operation on a custom key store that is not disconnected. This +# operation is valid only when the custom key store `ConnectionState` +# is `DISCONNECTED`. +# +# * You requested the GenerateRandom operation in an CloudHSM key store +# that is not connected. This operation is valid only when the +# CloudHSM key store `ConnectionState` is `CONNECTED`. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CustomKeyStoreInvalidStateException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1212 +class Aws::KMS::Types::CustomKeyStoreInvalidStateException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1213 +Aws::KMS::Types::CustomKeyStoreInvalidStateException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified custom key store name +# is already assigned to another custom key store in the account. Try +# again with a custom key store name that is unique in the account. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CustomKeyStoreNameInUseException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1227 +class Aws::KMS::Types::CustomKeyStoreNameInUseException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1228 +Aws::KMS::Types::CustomKeyStoreNameInUseException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because KMS cannot find a custom key store +# with the specified key store name or ID. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CustomKeyStoreNotFoundException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1241 +class Aws::KMS::Types::CustomKeyStoreNotFoundException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1242 +Aws::KMS::Types::CustomKeyStoreNotFoundException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains information about each custom key store in the custom key +# store list. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/CustomKeyStoresListEntry AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1505 +class Aws::KMS::Types::CustomKeyStoresListEntry < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1506 +Aws::KMS::Types::CustomKeyStoresListEntry::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DecryptRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1648 +class Aws::KMS::Types::DecryptRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1649 +Aws::KMS::Types::DecryptRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DecryptResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1697 +class Aws::KMS::Types::DecryptResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1698 +Aws::KMS::Types::DecryptResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeleteAliasRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1710 +class Aws::KMS::Types::DeleteAliasRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1711 +Aws::KMS::Types::DeleteAliasRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeleteCustomKeyStoreRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1723 +class Aws::KMS::Types::DeleteCustomKeyStoreRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1724 +Aws::KMS::Types::DeleteCustomKeyStoreRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeleteCustomKeyStoreResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1730 +class Aws::KMS::Types::DeleteCustomKeyStoreResponse < ::Aws::EmptyStructure; end + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeleteImportedKeyMaterialRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1752 +class Aws::KMS::Types::DeleteImportedKeyMaterialRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1753 +Aws::KMS::Types::DeleteImportedKeyMaterialRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The system timed out while trying to fulfill the request. You can +# retry the request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DependencyTimeoutException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1766 +class Aws::KMS::Types::DependencyTimeoutException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1767 +Aws::KMS::Types::DependencyTimeoutException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeriveSharedSecretRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1898 +class Aws::KMS::Types::DeriveSharedSecretRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1899 +Aws::KMS::Types::DeriveSharedSecretRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DeriveSharedSecretResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1955 +class Aws::KMS::Types::DeriveSharedSecretResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1956 +Aws::KMS::Types::DeriveSharedSecretResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DescribeCustomKeyStoresRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1998 +class Aws::KMS::Types::DescribeCustomKeyStoresRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#1999 +Aws::KMS::Types::DescribeCustomKeyStoresRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DescribeCustomKeyStoresResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2024 +class Aws::KMS::Types::DescribeCustomKeyStoresResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2025 +Aws::KMS::Types::DescribeCustomKeyStoresResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DescribeKeyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2079 +class Aws::KMS::Types::DescribeKeyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2080 +Aws::KMS::Types::DescribeKeyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DescribeKeyResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2091 +class Aws::KMS::Types::DescribeKeyResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2092 +Aws::KMS::Types::DescribeKeyResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisableKeyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2115 +class Aws::KMS::Types::DisableKeyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2116 +Aws::KMS::Types::DisableKeyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisableKeyRotationRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2149 +class Aws::KMS::Types::DisableKeyRotationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2150 +Aws::KMS::Types::DisableKeyRotationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified KMS key is not enabled. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisabledException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2162 +class Aws::KMS::Types::DisabledException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2163 +Aws::KMS::Types::DisabledException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisconnectCustomKeyStoreRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2176 +class Aws::KMS::Types::DisconnectCustomKeyStoreRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2177 +Aws::KMS::Types::DisconnectCustomKeyStoreRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DisconnectCustomKeyStoreResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2183 +class Aws::KMS::Types::DisconnectCustomKeyStoreResponse < ::Aws::EmptyStructure; end + +# The request was rejected because the DryRun parameter was specified. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/DryRunOperationException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2193 +class Aws::KMS::Types::DryRunOperationException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2194 +Aws::KMS::Types::DryRunOperationException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/EnableKeyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2217 +class Aws::KMS::Types::EnableKeyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2218 +Aws::KMS::Types::EnableKeyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/EnableKeyRotationRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2274 +class Aws::KMS::Types::EnableKeyRotationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2275 +Aws::KMS::Types::EnableKeyRotationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/EncryptRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2384 +class Aws::KMS::Types::EncryptRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2385 +Aws::KMS::Types::EncryptRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/EncryptResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2413 +class Aws::KMS::Types::EncryptResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2414 +Aws::KMS::Types::EncryptResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified import token is +# expired. Use GetParametersForImport to get a new import token and +# public key, use the new public key to encrypt the key material, and +# then try the request again. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ExpiredImportTokenException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2429 +class Aws::KMS::Types::ExpiredImportTokenException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2430 +Aws::KMS::Types::ExpiredImportTokenException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyPairRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2563 +class Aws::KMS::Types::GenerateDataKeyPairRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2564 +Aws::KMS::Types::GenerateDataKeyPairRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyPairResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2627 +class Aws::KMS::Types::GenerateDataKeyPairResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2628 +Aws::KMS::Types::GenerateDataKeyPairResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyPairWithoutPlaintextRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2726 +class Aws::KMS::Types::GenerateDataKeyPairWithoutPlaintextRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2727 +Aws::KMS::Types::GenerateDataKeyPairWithoutPlaintextRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyPairWithoutPlaintextResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2762 +class Aws::KMS::Types::GenerateDataKeyPairWithoutPlaintextResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2763 +Aws::KMS::Types::GenerateDataKeyPairWithoutPlaintextResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2902 +class Aws::KMS::Types::GenerateDataKeyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2903 +Aws::KMS::Types::GenerateDataKeyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2955 +class Aws::KMS::Types::GenerateDataKeyResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#2956 +Aws::KMS::Types::GenerateDataKeyResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyWithoutPlaintextRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3057 +class Aws::KMS::Types::GenerateDataKeyWithoutPlaintextRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3058 +Aws::KMS::Types::GenerateDataKeyWithoutPlaintextRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateDataKeyWithoutPlaintextResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3081 +class Aws::KMS::Types::GenerateDataKeyWithoutPlaintextResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3082 +Aws::KMS::Types::GenerateDataKeyWithoutPlaintextResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateMacRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3148 +class Aws::KMS::Types::GenerateMacRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3149 +Aws::KMS::Types::GenerateMacRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateMacResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3177 +class Aws::KMS::Types::GenerateMacResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3178 +Aws::KMS::Types::GenerateMacResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateRandomRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3229 +class Aws::KMS::Types::GenerateRandomRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3230 +Aws::KMS::Types::GenerateRandomRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GenerateRandomResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3264 +class Aws::KMS::Types::GenerateRandomResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3265 +Aws::KMS::Types::GenerateRandomResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetKeyPolicyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3295 +class Aws::KMS::Types::GetKeyPolicyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3296 +Aws::KMS::Types::GetKeyPolicyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetKeyPolicyResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3312 +class Aws::KMS::Types::GetKeyPolicyResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3313 +Aws::KMS::Types::GetKeyPolicyResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetKeyRotationStatusRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3338 +class Aws::KMS::Types::GetKeyRotationStatusRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3339 +Aws::KMS::Types::GetKeyRotationStatusRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetKeyRotationStatusResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3382 +class Aws::KMS::Types::GetKeyRotationStatusResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3383 +Aws::KMS::Types::GetKeyRotationStatusResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetParametersForImportRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3465 +class Aws::KMS::Types::GetParametersForImportRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3466 +Aws::KMS::Types::GetParametersForImportRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetParametersForImportResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3502 +class Aws::KMS::Types::GetParametersForImportResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3503 +Aws::KMS::Types::GetParametersForImportResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetPublicKeyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3548 +class Aws::KMS::Types::GetPublicKeyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3549 +Aws::KMS::Types::GetPublicKeyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GetPublicKeyResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3632 +class Aws::KMS::Types::GetPublicKeyResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3633 +Aws::KMS::Types::GetPublicKeyResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Use this structure to allow [cryptographic operations][1] in the grant +# only when the operation request includes the specified [encryption +# context][2]. +# +# KMS applies the grant constraints only to cryptographic operations +# that support an encryption context, that is, all cryptographic +# operations with a [symmetric KMS key][3]. Grant constraints are not +# applied to operations that do not support an encryption context, such +# as cryptographic operations with asymmetric KMS keys and management +# operations, such as DescribeKey or RetireGrant. +# +# In a cryptographic operation, the encryption context in the decryption +# operation must be an exact, case-sensitive match for the keys and +# values in the encryption context of the encryption operation. Only the +# order of the pairs can vary. +# +# However, in a grant constraint, the key in each key-value pair is not +# case sensitive, but the value is case sensitive. +# +# To avoid confusion, do not use multiple encryption context pairs that +# differ only by case. To require a fully case-sensitive encryption +# context, use the `kms:EncryptionContext:` and +# `kms:EncryptionContextKeys` conditions in an IAM or key policy. For +# details, see [kms:EncryptionContext:][4] in the Key Management +# Service Developer Guide . +# +# +# +# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations +# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context +# [3]: https://docs.aws.amazon.com/kms/latest/developerguide/symm-asymm-concepts.html#symmetric-cmks +# [4]: https://docs.aws.amazon.com/kms/latest/developerguide/policy-conditions.html#conditions-kms-encryption-context +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GrantConstraints AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3697 +class Aws::KMS::Types::GrantConstraints < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3698 +Aws::KMS::Types::GrantConstraints::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains information about a grant. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/GrantListEntry AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3765 +class Aws::KMS::Types::GrantListEntry < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3766 +Aws::KMS::Types::GrantListEntry::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ImportKeyMaterialRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3857 +class Aws::KMS::Types::ImportKeyMaterialRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3858 +Aws::KMS::Types::ImportKeyMaterialRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ImportKeyMaterialResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3864 +class Aws::KMS::Types::ImportKeyMaterialResponse < ::Aws::EmptyStructure; end + +# The request was rejected because the specified KMS key cannot decrypt +# the data. The `KeyId` in a Decrypt request and the `SourceKeyId` in a +# ReEncrypt request must identify the same KMS key that was used to +# encrypt the ciphertext. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/IncorrectKeyException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3877 +class Aws::KMS::Types::IncorrectKeyException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3878 +Aws::KMS::Types::IncorrectKeyException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the key material in the request is, +# expired, invalid, or is not the same key material that was previously +# imported into this KMS key. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/IncorrectKeyMaterialException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3892 +class Aws::KMS::Types::IncorrectKeyMaterialException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3893 +Aws::KMS::Types::IncorrectKeyMaterialException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the trust anchor certificate in the +# request to create an CloudHSM key store is not the trust anchor +# certificate for the specified CloudHSM cluster. +# +# When you [initialize the CloudHSM cluster][1], you create the trust +# anchor certificate and save it in the `customerCA.crt` file. +# +# +# +# [1]: https://docs.aws.amazon.com/cloudhsm/latest/userguide/initialize-cluster.html#sign-csr +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/IncorrectTrustAnchorException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3914 +class Aws::KMS::Types::IncorrectTrustAnchorException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3915 +Aws::KMS::Types::IncorrectTrustAnchorException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified alias name is not +# valid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidAliasNameException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3928 +class Aws::KMS::Types::InvalidAliasNameException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3929 +Aws::KMS::Types::InvalidAliasNameException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because a specified ARN, or an ARN in a key +# policy, is not valid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidArnException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3942 +class Aws::KMS::Types::InvalidArnException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3943 +Aws::KMS::Types::InvalidArnException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# From the Decrypt or ReEncrypt operation, the request was rejected +# because the specified ciphertext, or additional authenticated data +# incorporated into the ciphertext, such as the encryption context, is +# corrupted, missing, or otherwise invalid. +# +# From the ImportKeyMaterial operation, the request was rejected because +# KMS could not decrypt the encrypted (wrapped) key material. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidCiphertextException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3961 +class Aws::KMS::Types::InvalidCiphertextException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3962 +Aws::KMS::Types::InvalidCiphertextException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified `GrantId` is not valid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidGrantIdException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3974 +class Aws::KMS::Types::InvalidGrantIdException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3975 +Aws::KMS::Types::InvalidGrantIdException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified grant token is not +# valid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidGrantTokenException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3988 +class Aws::KMS::Types::InvalidGrantTokenException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#3989 +Aws::KMS::Types::InvalidGrantTokenException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the provided import token is invalid +# or is associated with a different KMS key. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidImportTokenException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4002 +class Aws::KMS::Types::InvalidImportTokenException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4003 +Aws::KMS::Types::InvalidImportTokenException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected for one of the following reasons: +# +# * The `KeyUsage` value of the KMS key is incompatible with the API +# operation. +# +# * The encryption algorithm or signing algorithm specified for the +# operation is incompatible with the type of key material in the KMS +# key `(KeySpec`). +# +# For encrypting, decrypting, re-encrypting, and generating data keys, +# the `KeyUsage` must be `ENCRYPT_DECRYPT`. For signing and verifying +# messages, the `KeyUsage` must be `SIGN_VERIFY`. For generating and +# verifying message authentication codes (MACs), the `KeyUsage` must be +# `GENERATE_VERIFY_MAC`. For deriving key agreement secrets, the +# `KeyUsage` must be `KEY_AGREEMENT`. To find the `KeyUsage` of a KMS +# key, use the DescribeKey operation. +# +# To find the encryption or signing algorithms supported for a +# particular KMS key, use the DescribeKey operation. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidKeyUsageException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4033 +class Aws::KMS::Types::InvalidKeyUsageException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4034 +Aws::KMS::Types::InvalidKeyUsageException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the marker that specifies where +# pagination should next begin is not valid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/InvalidMarkerException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4047 +class Aws::KMS::Types::InvalidMarkerException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4048 +Aws::KMS::Types::InvalidMarkerException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because an internal exception occurred. The +# request can be retried. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/KMSInternalException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4061 +class Aws::KMS::Types::KMSInternalException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4062 +Aws::KMS::Types::KMSInternalException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the HMAC verification failed. HMAC +# verification fails when the HMAC computed by using the specified +# message, HMAC KMS key, and MAC algorithm does not match the HMAC +# specified in the request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/KMSInvalidMacException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4077 +class Aws::KMS::Types::KMSInvalidMacException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4078 +Aws::KMS::Types::KMSInvalidMacException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the signature verification failed. +# Signature verification fails when it cannot confirm that signature was +# produced by signing the specified message with the specified KMS key +# and signing algorithm. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/KMSInvalidSignatureException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4093 +class Aws::KMS::Types::KMSInvalidSignatureException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4094 +Aws::KMS::Types::KMSInvalidSignatureException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the state of the specified resource +# is not valid for this request. +# +# This exceptions means one of the following: +# +# * The key state of the KMS key is not compatible with the operation. +# +# To find the key state, use the DescribeKey operation. For more +# information about which key states are compatible with each KMS +# operation, see [Key states of KMS keys][1] in the Key +# Management Service Developer Guide . +# +# * For cryptographic operations on KMS keys in custom key stores, this +# exception represents a general failure with many possible causes. To +# identify the cause, see the error message that accompanies the +# exception. +# +# +# +# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/KMSInvalidStateException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4125 +class Aws::KMS::Types::KMSInvalidStateException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4126 +Aws::KMS::Types::KMSInvalidStateException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains information about each entry in the key list. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/KeyListEntry AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4144 +class Aws::KMS::Types::KeyListEntry < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4145 +Aws::KMS::Types::KeyListEntry::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains metadata about a KMS key. +# +# This data type is used as a response element for the CreateKey, +# DescribeKey, and ReplicateKey operations. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/KeyMetadata AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4403 +class Aws::KMS::Types::KeyMetadata < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4404 +Aws::KMS::Types::KeyMetadata::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified KMS key was not +# available. You can retry the request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/KeyUnavailableException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4417 +class Aws::KMS::Types::KeyUnavailableException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4418 +Aws::KMS::Types::KeyUnavailableException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because a quota was exceeded. For more +# information, see [Quotas][1] in the *Key Management Service Developer +# Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/limits.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/LimitExceededException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4436 +class Aws::KMS::Types::LimitExceededException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4437 +Aws::KMS::Types::LimitExceededException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListAliasesRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4482 +class Aws::KMS::Types::ListAliasesRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4483 +Aws::KMS::Types::ListAliasesRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListAliasesResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4508 +class Aws::KMS::Types::ListAliasesResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4509 +Aws::KMS::Types::ListAliasesResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListGrantsRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4565 +class Aws::KMS::Types::ListGrantsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4566 +Aws::KMS::Types::ListGrantsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListGrantsResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4591 +class Aws::KMS::Types::ListGrantsResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4592 +Aws::KMS::Types::ListGrantsResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeyPoliciesRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4635 +class Aws::KMS::Types::ListKeyPoliciesRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4636 +Aws::KMS::Types::ListKeyPoliciesRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeyPoliciesResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4661 +class Aws::KMS::Types::ListKeyPoliciesResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4662 +Aws::KMS::Types::ListKeyPoliciesResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeyRotationsRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4703 +class Aws::KMS::Types::ListKeyRotationsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4704 +Aws::KMS::Types::ListKeyRotationsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeyRotationsResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4729 +class Aws::KMS::Types::ListKeyRotationsResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4730 +Aws::KMS::Types::ListKeyRotationsResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeysRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4754 +class Aws::KMS::Types::ListKeysRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4755 +Aws::KMS::Types::ListKeysRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListKeysResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4780 +class Aws::KMS::Types::ListKeysResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4781 +Aws::KMS::Types::ListKeysResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListResourceTagsRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4824 +class Aws::KMS::Types::ListResourceTagsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4825 +Aws::KMS::Types::ListResourceTagsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListResourceTagsResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4862 +class Aws::KMS::Types::ListResourceTagsResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4863 +Aws::KMS::Types::ListResourceTagsResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ListRetirableGrantsRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4905 +class Aws::KMS::Types::ListRetirableGrantsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4906 +Aws::KMS::Types::ListRetirableGrantsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified policy is not +# syntactically or semantically correct. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/MalformedPolicyDocumentException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4919 +class Aws::KMS::Types::MalformedPolicyDocumentException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4920 +Aws::KMS::Types::MalformedPolicyDocumentException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the configuration of this multi-Region key. This field +# appears only when the KMS key is a primary or replica of a +# multi-Region key. +# +# For more information about any listed KMS key, use the DescribeKey +# operation. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/MultiRegionConfiguration AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4950 +class Aws::KMS::Types::MultiRegionConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4951 +Aws::KMS::Types::MultiRegionConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the primary or replica key in a multi-Region key. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/MultiRegionKey AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4971 +class Aws::KMS::Types::MultiRegionKey < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4972 +Aws::KMS::Types::MultiRegionKey::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified entity or resource +# could not be found. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/NotFoundException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4985 +class Aws::KMS::Types::NotFoundException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#4986 +Aws::KMS::Types::NotFoundException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/PutKeyPolicyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5084 +class Aws::KMS::Types::PutKeyPolicyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5085 +Aws::KMS::Types::PutKeyPolicyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ReEncryptRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5265 +class Aws::KMS::Types::ReEncryptRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5266 +Aws::KMS::Types::ReEncryptRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ReEncryptResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5306 +class Aws::KMS::Types::ReEncryptResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5307 +Aws::KMS::Types::ReEncryptResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains information about the party that receives the response from +# the API operation. +# +# This data type is designed to support Amazon Web Services Nitro +# Enclaves, which lets you create an isolated compute environment in +# Amazon EC2. For information about the interaction between KMS and +# Amazon Web Services Nitro Enclaves, see [How Amazon Web Services Nitro +# Enclaves uses KMS][1] in the *Key Management Service Developer Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/services-nitro-enclaves.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RecipientInfo AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5339 +class Aws::KMS::Types::RecipientInfo < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5340 +Aws::KMS::Types::RecipientInfo::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ReplicateKeyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5538 +class Aws::KMS::Types::ReplicateKeyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5539 +Aws::KMS::Types::ReplicateKeyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ReplicateKeyResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5570 +class Aws::KMS::Types::ReplicateKeyResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5571 +Aws::KMS::Types::ReplicateKeyResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RetireGrantRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5626 +class Aws::KMS::Types::RetireGrantRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5627 +Aws::KMS::Types::RetireGrantRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RevokeGrantRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5673 +class Aws::KMS::Types::RevokeGrantRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5674 +Aws::KMS::Types::RevokeGrantRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RotateKeyOnDemandRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5710 +class Aws::KMS::Types::RotateKeyOnDemandRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5711 +Aws::KMS::Types::RotateKeyOnDemandRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RotateKeyOnDemandResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5723 +class Aws::KMS::Types::RotateKeyOnDemandResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5724 +Aws::KMS::Types::RotateKeyOnDemandResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains information about completed key material rotations. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/RotationsListEntry AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5754 +class Aws::KMS::Types::RotationsListEntry < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5755 +Aws::KMS::Types::RotationsListEntry::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ScheduleKeyDeletionRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5798 +class Aws::KMS::Types::ScheduleKeyDeletionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5799 +Aws::KMS::Types::ScheduleKeyDeletionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/ScheduleKeyDeletionResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5846 +class Aws::KMS::Types::ScheduleKeyDeletionResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5847 +Aws::KMS::Types::ScheduleKeyDeletionResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/SignRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5973 +class Aws::KMS::Types::SignRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#5974 +Aws::KMS::Types::SignRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/SignResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6017 +class Aws::KMS::Types::SignResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6018 +Aws::KMS::Types::SignResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A key-value pair. A tag consists of a tag key and a tag value. Tag +# keys and tag values are both required, but tag values can be empty +# (null) strings. +# +# Do not include confidential or sensitive information in this field. +# This field may be displayed in plaintext in CloudTrail logs and other +# output. +# +# For information about the rules that apply to tag keys and tag values, +# see [User-Defined Tag Restrictions][1] in the *Amazon Web Services +# Billing and Cost Management User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/allocation-tag-restrictions.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/Tag AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6050 +class Aws::KMS::Types::Tag < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6051 +Aws::KMS::Types::Tag::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because one or more tags are not valid. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/TagException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6063 +class Aws::KMS::Types::TagException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6064 +Aws::KMS::Types::TagException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/TagResourceRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6101 +class Aws::KMS::Types::TagResourceRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6102 +Aws::KMS::Types::TagResourceRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because a specified parameter is not +# supported or a specified resource is not valid for this operation. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UnsupportedOperationException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6115 +class Aws::KMS::Types::UnsupportedOperationException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6116 +Aws::KMS::Types::UnsupportedOperationException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UntagResourceRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6144 +class Aws::KMS::Types::UntagResourceRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6145 +Aws::KMS::Types::UntagResourceRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdateAliasRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6195 +class Aws::KMS::Types::UpdateAliasRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6196 +Aws::KMS::Types::UpdateAliasRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdateCustomKeyStoreRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6350 +class Aws::KMS::Types::UpdateCustomKeyStoreRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6351 +Aws::KMS::Types::UpdateCustomKeyStoreRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdateCustomKeyStoreResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6357 +class Aws::KMS::Types::UpdateCustomKeyStoreResponse < ::Aws::EmptyStructure; end + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdateKeyDescriptionRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6387 +class Aws::KMS::Types::UpdateKeyDescriptionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6388 +Aws::KMS::Types::UpdateKeyDescriptionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/UpdatePrimaryRegionRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6422 +class Aws::KMS::Types::UpdatePrimaryRegionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6423 +Aws::KMS::Types::UpdatePrimaryRegionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/VerifyMacRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6490 +class Aws::KMS::Types::VerifyMacRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6491 +Aws::KMS::Types::VerifyMacRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/VerifyMacResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6518 +class Aws::KMS::Types::VerifyMacResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6519 +Aws::KMS::Types::VerifyMacResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/VerifyRequest AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6648 +class Aws::KMS::Types::VerifyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6649 +Aws::KMS::Types::VerifyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/VerifyResponse AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6679 +class Aws::KMS::Types::VerifyResponse < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6680 +Aws::KMS::Types::VerifyResponse::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the (`XksKeyId`) is already +# associated with another KMS key in this external key store. Each KMS +# key in an external key store must be associated with a different +# external key. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksKeyAlreadyInUseException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6695 +class Aws::KMS::Types::XksKeyAlreadyInUseException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6696 +Aws::KMS::Types::XksKeyAlreadyInUseException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Information about the [external key ][1]that is associated with a KMS +# key in an external key store. +# +# This element appears in a CreateKey or DescribeKey response only for a +# KMS key in an external key store. +# +# The *external key* is a symmetric encryption key that is hosted by an +# external key manager outside of Amazon Web Services. When you use the +# KMS key in an external key store in a cryptographic operation, the +# cryptographic operation is performed in the external key manager using +# the specified external key. For more information, see [External +# key][1] in the *Key Management Service Developer Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/keystore-external.html#concept-external-key +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksKeyConfigurationType AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6726 +class Aws::KMS::Types::XksKeyConfigurationType < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6727 +Aws::KMS::Types::XksKeyConfigurationType::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the external key specified by the +# `XksKeyId` parameter did not meet the configuration requirements for +# an external key store. +# +# The external key must be an AES-256 symmetric key that is enabled and +# performs encryption and decryption. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksKeyInvalidConfigurationException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6744 +class Aws::KMS::Types::XksKeyInvalidConfigurationException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6745 +Aws::KMS::Types::XksKeyInvalidConfigurationException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the external key store proxy could +# not find the external key. This exception is thrown when the value of +# the `XksKeyId` parameter doesn't identify a key in the external key +# manager associated with the external key proxy. +# +# Verify that the `XksKeyId` represents an existing key in the external +# key manager. Use the key identifier that the external key store proxy +# uses to identify the key. For details, see the documentation provided +# with your external key store proxy or key manager. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksKeyNotFoundException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6765 +class Aws::KMS::Types::XksKeyNotFoundException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6766 +Aws::KMS::Types::XksKeyNotFoundException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# KMS uses the authentication credential to sign requests that it sends +# to the external key store proxy (XKS proxy) on your behalf. You +# establish these credentials on your external key store proxy and +# report them to KMS. +# +# The `XksProxyAuthenticationCredential` includes two required elements. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyAuthenticationCredentialType AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6790 +class Aws::KMS::Types::XksProxyAuthenticationCredentialType < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6791 +Aws::KMS::Types::XksProxyAuthenticationCredentialType::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Detailed information about the external key store proxy (XKS proxy). +# Your external key store proxy translates KMS requests into a format +# that your external key manager can understand. These fields appear in +# a DescribeCustomKeyStores response only when the `CustomKeyStoreType` +# is `EXTERNAL_KEY_STORE`. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyConfigurationType AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6844 +class Aws::KMS::Types::XksProxyConfigurationType < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6845 +Aws::KMS::Types::XksProxyConfigurationType::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the proxy credentials failed to +# authenticate to the specified external key store proxy. The specified +# external key store proxy rejected a status request from KMS due to +# invalid credentials. This can indicate an error in the credentials or +# in the identification of the external key store proxy. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyIncorrectAuthenticationCredentialException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6861 +class Aws::KMS::Types::XksProxyIncorrectAuthenticationCredentialException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6862 +Aws::KMS::Types::XksProxyIncorrectAuthenticationCredentialException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the external key store proxy is not +# configured correctly. To identify the cause, see the error message +# that accompanies the exception. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyInvalidConfigurationException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6876 +class Aws::KMS::Types::XksProxyInvalidConfigurationException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6877 +Aws::KMS::Types::XksProxyInvalidConfigurationException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# KMS cannot interpret the response it received from the external key +# store proxy. The problem might be a poorly constructed response, but +# it could also be a transient network issue. If you see this error +# repeatedly, report it to the proxy vendor. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyInvalidResponseException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6892 +class Aws::KMS::Types::XksProxyInvalidResponseException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6893 +Aws::KMS::Types::XksProxyInvalidResponseException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the `XksProxyUriEndpoint` is already +# associated with another external key store in this Amazon Web Services +# Region. To identify the cause, see the error message that accompanies +# the exception. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyUriEndpointInUseException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6908 +class Aws::KMS::Types::XksProxyUriEndpointInUseException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6909 +Aws::KMS::Types::XksProxyUriEndpointInUseException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the concatenation of the +# `XksProxyUriEndpoint` and `XksProxyUriPath` is already associated with +# another external key store in this Amazon Web Services Region. Each +# external key store in a Region must use a unique external key store +# proxy API address. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyUriInUseException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6925 +class Aws::KMS::Types::XksProxyUriInUseException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6926 +Aws::KMS::Types::XksProxyUriInUseException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# KMS was unable to reach the specified `XksProxyUriPath`. The path must +# be reachable before you create the external key store or update its +# settings. +# +# This exception is also thrown when the external key store proxy +# response to a `GetHealthStatus` request indicates that all external +# key manager instances are unavailable. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyUriUnreachableException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6944 +class Aws::KMS::Types::XksProxyUriUnreachableException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6945 +Aws::KMS::Types::XksProxyUriUnreachableException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the specified Amazon VPC endpoint +# service is already associated with another external key store in this +# Amazon Web Services Region. Each external key store in a Region must +# use a different Amazon VPC endpoint service. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyVpcEndpointServiceInUseException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6960 +class Aws::KMS::Types::XksProxyVpcEndpointServiceInUseException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6961 +Aws::KMS::Types::XksProxyVpcEndpointServiceInUseException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because the Amazon VPC endpoint service +# configuration does not fulfill the requirements for an external key +# store. To identify the cause, see the error message that accompanies +# the exception and [review the requirements][1] for Amazon VPC endpoint +# service connectivity for an external key store. +# +# +# +# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/vpc-connectivity.html#xks-vpc-requirements +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyVpcEndpointServiceInvalidConfigurationException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6981 +class Aws::KMS::Types::XksProxyVpcEndpointServiceInvalidConfigurationException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6982 +Aws::KMS::Types::XksProxyVpcEndpointServiceInvalidConfigurationException::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The request was rejected because KMS could not find the specified VPC +# endpoint service. Use DescribeCustomKeyStores to verify the VPC +# endpoint service name for the external key store. Also, confirm that +# the `Allow principals` list for the VPC endpoint service includes the +# KMS service principal for the Region, such as +# `cks.kms.us-east-1.amazonaws.com`. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/kms-2014-11-01/XksProxyVpcEndpointServiceNotFoundException AWS API Documentation +# +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#6999 +class Aws::KMS::Types::XksProxyVpcEndpointServiceNotFoundException < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-kms//lib/aws-sdk-kms/types.rb#7000 +Aws::KMS::Types::XksProxyVpcEndpointServiceNotFoundException::SENSITIVE = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/aws-sdk-s3@1.157.0.rbi b/sorbet/rbi/gems/aws-sdk-s3@1.157.0.rbi new file mode 100644 index 000000000..4bf0705b2 --- /dev/null +++ b/sorbet/rbi/gems/aws-sdk-s3@1.157.0.rbi @@ -0,0 +1,32299 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `aws-sdk-s3` gem. +# Please instead update this file by running `bin/tapioca gem aws-sdk-s3`. + + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/accelerate.rb#3 +module Aws + class << self + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#138 + def config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#141 + def config=(config); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#200 + def eager_autoload!(*args); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#193 + def empty_connection_pools!; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#150 + def partition(partition_name); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#155 + def partitions; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#131 + def shared_config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#170 + def use_bundled_cert!; end + end +end + +# This module provides support for Amazon Simple Storage Service. This module is available in the +# `aws-sdk-s3` gem. +# +# # Client +# +# The {Client} class provides one method for each API operation. Operation +# methods each accept a hash of request parameters and return a response +# structure. +# +# s3 = Aws::S3::Client.new +# resp = s3.abort_multipart_upload(params) +# +# See {Client} for more information. +# +# # Errors +# +# Errors returned from Amazon Simple Storage Service are defined in the +# {Errors} module and all extend {Errors::ServiceError}. +# +# begin +# # do stuff +# rescue Aws::S3::Errors::ServiceError +# # rescues all Amazon Simple Storage Service API errors +# end +# +# See {Errors} for more information. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10 +module Aws::S3 + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#11 + def access_grants_account_id_cache; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#6 + def access_grants_credentials_cache; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#8 + def bucket_region_cache; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#6 + def express_credentials_cache; end + end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption.rb#20 +Aws::S3::AES_GCM_TAG_LEN_BYTES = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials.rb#8 +class Aws::S3::AccessGrantsCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # @api private + # @return [AccessGrantsCredentials] a new instance of AccessGrantsCredentials + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials.rb#12 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [S3Control::Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials.rb#25 + def client; end + + # @api private + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials.rb#28 + def matched_grant_target; end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials.rb#32 + def refresh; end + + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials.rb#47 + def get_data_access_options; end + end +end + +# Returns Credentials class for S3 Access Grants. Accepts GetDataAccess +# params and other configuration as options. See +# {Aws::S3Control::Client#get_data_access} for details. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#21 +class Aws::S3::AccessGrantsCredentialsProvider + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [AccessGrantsCredentialsProvider] a new instance of AccessGrantsCredentialsProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#42 + def initialize(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#58 + def access_grants_credentials_for(options = T.unsafe(nil)); end + + # Returns the value of attribute s3_client. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#79 + def s3_client; end + + # Sets the attribute s3_client + # + # @param value the value to set the attribute s3_client to. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#79 + def s3_client=(_arg0); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#156 + def account_id_for_access_grants(target, credentials); end + + # returns the account id for the configured credentials + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#213 + def account_id_for_credentials(region, credentials); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#133 + def broad_search_credentials_cache_characters(target, permission, credentials); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#122 + def broad_search_credentials_cache_prefix(target, permission, credentials); end + + # extracts bucket name from target prefix + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#245 + def bucket_name_from(target); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#185 + def bucket_region_for_access_grants(target); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#164 + def cached_account_id_for(target, credentials); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#191 + def cached_bucket_region_for(bucket); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#95 + def cached_credentials_for(target, permission, credentials); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#239 + def credentials_cache_key(target, permission, credentials); end + + # returns the account id associated with the access grants instance + # + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#175 + def new_account_id_for(target, credentials); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#199 + def new_bucket_region_for(bucket); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#144 + def new_credentials_for(target, permission, credentials); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#83 + def s3_control_client(bucket_region); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/access_grants_credentials_provider.rb#229 + def target_prefix(bucket, key, prefix); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#12 +class Aws::S3::Bucket + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [Bucket] a new instance of Bucket + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#22 + def initialize(*args); end + + # @return [BucketAcl] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#955 + def acl; end + + # Deletes all objects and versioned objects from this bucket + # + # @example + # + # bucket.clear! + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/bucket.rb#15 + def clear!; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#47 + def client; end + + # @return [BucketCors] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#963 + def cors; end + + # @example Request syntax with placeholder values + # + # bucket.create({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read + # create_bucket_configuration: { + # location_constraint: "af-south-1", # accepts af-south-1, ap-east-1, ap-northeast-1, ap-northeast-2, ap-northeast-3, ap-south-1, ap-south-2, ap-southeast-1, ap-southeast-2, ap-southeast-3, ca-central-1, cn-north-1, cn-northwest-1, EU, eu-central-1, eu-north-1, eu-south-1, eu-south-2, eu-west-1, eu-west-2, eu-west-3, me-south-1, sa-east-1, us-east-2, us-gov-east-1, us-gov-west-1, us-west-1, us-west-2 + # location: { + # type: "AvailabilityZone", # accepts AvailabilityZone + # name: "LocationNameAsString", + # }, + # bucket: { + # data_redundancy: "SingleAvailabilityZone", # accepts SingleAvailabilityZone + # type: "Directory", # accepts Directory + # }, + # }, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write: "GrantWrite", + # grant_write_acp: "GrantWriteACP", + # object_lock_enabled_for_bucket: false, + # object_ownership: "BucketOwnerPreferred", # accepts BucketOwnerPreferred, ObjectWriter, BucketOwnerEnforced + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::CreateBucketOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#335 + def create(options = T.unsafe(nil)); end + + # Date the bucket was created. This date can change when making changes + # to your bucket, such as editing its bucket policy. + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#40 + def creation_date; end + + # @raise [NotImplementedError] Raises when {#data_loaded?} is `false`. + # @return [Types::Bucket] Returns the data for this {Bucket}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#62 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#70 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # bucket.delete({ + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#360 + def delete(options = T.unsafe(nil)); end + + # Deletes all objects and versioned objects from this bucket and + # then deletes the bucket. + # + # @example + # + # bucket.delete! + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/bucket.rb#35 + def delete!(options = T.unsafe(nil)); end + + # @example Request syntax with placeholder values + # + # bucket.delete_objects({ + # delete: { # required + # objects: [ # required + # { + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # }, + # ], + # quiet: false, + # }, + # mfa: "MFA", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::DeleteObjectsOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#474 + def delete_objects(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1367 + def deprecated_identifiers; end + + # @param options [Hash] ({}) + # @return [Boolean] Returns `true` if the Bucket exists. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#77 + def exists?(options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # @return [BucketLifecycle] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#971 + def lifecycle; end + + # @return [BucketLifecycleConfiguration] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#979 + def lifecycle_configuration; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/bucket.rb#136 + def load; end + + # @return [BucketLogging] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#987 + def logging; end + + # @example Request syntax with placeholder values + # + # multipart_uploads = bucket.multipart_uploads({ + # delimiter: "Delimiter", + # encoding_type: "url", # accepts url + # key_marker: "KeyMarker", + # prefix: "Prefix", + # upload_id_marker: "UploadIdMarker", + # expected_bucket_owner: "AccountId", + # request_payer: "requester", # accepts requester + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [MultipartUpload::Collection] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1097 + def multipart_uploads(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#33 + def name; end + + # @return [BucketNotification] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1121 + def notification; end + + # @param key [String] + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1130 + def object(key); end + + # @example Request syntax with placeholder values + # + # object_versions = bucket.object_versions({ + # delimiter: "Delimiter", + # encoding_type: "url", # accepts url + # key_marker: "KeyMarker", + # prefix: "Prefix", + # version_id_marker: "VersionIdMarker", + # expected_bucket_owner: "AccountId", + # request_payer: "requester", # accepts requester + # optional_object_attributes: ["RestoreStatus"], # accepts RestoreStatus + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [ObjectVersion::Collection] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1200 + def object_versions(options = T.unsafe(nil)); end + + # @example Request syntax with placeholder values + # + # objects = bucket.objects({ + # delimiter: "Delimiter", + # encoding_type: "url", # accepts url + # prefix: "Prefix", + # fetch_owner: false, + # start_after: "StartAfter", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # optional_object_attributes: ["RestoreStatus"], # accepts RestoreStatus + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [ObjectSummary::Collection] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1303 + def objects(options = T.unsafe(nil)); end + + # @return [BucketPolicy] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1326 + def policy; end + + # Creates a {PresignedPost} that makes it easy to upload a file from + # a web browser direct to Amazon S3 using an HTML post form with + # a file field. + # + # See the {PresignedPost} documentation for more information. + # + # @note You must specify `:key` or `:key_starts_with`. All other options + # are optional. + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @return [PresignedPost] + # @see PresignedPost + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/bucket.rb#126 + def presigned_post(options = T.unsafe(nil)); end + + # @example Request syntax with placeholder values + # + # object = bucket.put_object({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # body: source_file, + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_length: 1, + # content_md5: "ContentMD5", + # content_type: "ContentType", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # key: "ObjectKey", # required + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#940 + def put_object(options = T.unsafe(nil)); end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#53 + def reload; end + + # @return [BucketRequestPayment] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1334 + def request_payment; end + + # @return [BucketTagging] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1342 + def tagging; end + + # Returns a public URL for this bucket. + # + # It will also work when provided an Access Point ARN. + # + # You can pass `virtual_host: true` to use the bucket name as the + # host name. + # + # bucket = s3.bucket('my-bucket.com') + # bucket.url(virtual_host: true) + # #=> "http://my-bucket.com" + # + # @example + # + # bucket = s3.bucket('bucket-name') + # bucket.url + # #=> "https://bucket-name.s3.amazonaws.com" + # @example + # + # bucket = s3.bucket( + # 'arn:aws:s3:us-east-1:123456789012:accesspoint:myendpoint' + # ) + # bucket.url + # #=> "https://myendpoint-123456789012.s3-accesspoint.us-west-2.amazonaws.com" + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [String] the URL for this bucket. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/bucket.rb#88 + def url(options = T.unsafe(nil)); end + + # @return [BucketVersioning] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1350 + def versioning; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#206 + def wait_until(options = T.unsafe(nil), &block); end + + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#94 + def wait_until_exists(options = T.unsafe(nil), &block); end + + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#113 + def wait_until_not_exists(options = T.unsafe(nil), &block); end + + # @return [BucketWebsite] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1358 + def website; end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1374 + def extract_name(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1395 + def separate_params_and_options(options); end + + # @yield [waiter.waiter] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1385 + def yield_waiter_and_warn(waiter, &block); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket.rb#1412 +class Aws::S3::Bucket::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#12 +class Aws::S3::BucketAcl + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketAcl] a new instance of BucketAcl + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#281 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#52 + def client; end + + # @return [Types::GetBucketAclOutput] Returns the data for this {BucketAcl}. Calls + # {Client#get_bucket_acl} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#74 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#82 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#290 + def deprecated_identifiers; end + + # A list of grants. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#45 + def grants; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketAcl}. + # Returns `self` making it possible to chain methods. + # + # bucket_acl.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#62 + def load; end + + # Container for the bucket owner's display name and ID. + # + # @return [Types::Owner] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#39 + def owner; end + + # @example Request syntax with placeholder values + # + # bucket_acl.put({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read + # access_control_policy: { + # grants: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, WRITE, WRITE_ACP, READ, READ_ACP + # }, + # ], + # owner: { + # display_name: "DisplayName", + # id: "ID", + # }, + # }, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write: "GrantWrite", + # grant_write_acp: "GrantWriteACP", + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#270 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketAcl}. + # Returns `self` making it possible to chain methods. + # + # bucket_acl.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#62 + def reload; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#166 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#297 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_acl.rb#308 +class Aws::S3::BucketAcl::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#12 +class Aws::S3::BucketCors + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketCors] a new instance of BucketCors + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#272 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#47 + def client; end + + # A set of origins and methods (cross-origin access that you want to + # allow). You can add up to 100 rules to the configuration. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#40 + def cors_rules; end + + # @return [Types::GetBucketCorsOutput] Returns the data for this {BucketCors}. Calls + # {Client#get_bucket_cors} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#69 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#77 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # bucket_cors.delete({ + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#193 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#281 + def deprecated_identifiers; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketCors}. + # Returns `self` making it possible to chain methods. + # + # bucket_cors.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#57 + def load; end + + # @example Request syntax with placeholder values + # + # bucket_cors.put({ + # cors_configuration: { # required + # cors_rules: [ # required + # { + # id: "ID", + # allowed_headers: ["AllowedHeader"], + # allowed_methods: ["AllowedMethod"], # required + # allowed_origins: ["AllowedOrigin"], # required + # expose_headers: ["ExposeHeader"], + # max_age_seconds: 1, + # }, + # ], + # }, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#261 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketCors}. + # Returns `self` making it possible to chain methods. + # + # bucket_cors.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#57 + def reload; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#161 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#288 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_cors.rb#299 +class Aws::S3::BucketCors::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#12 +class Aws::S3::BucketLifecycle + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketLifecycle] a new instance of BucketLifecycle + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#275 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#46 + def client; end + + # @return [Types::GetBucketLifecycleOutput] Returns the data for this {BucketLifecycle}. Calls + # {Client#get_bucket_lifecycle} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#68 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#76 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # bucket_lifecycle.delete({ + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#192 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#284 + def deprecated_identifiers; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketLifecycle}. + # Returns `self` making it possible to chain methods. + # + # bucket_lifecycle.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#56 + def load; end + + # @example Request syntax with placeholder values + # + # bucket_lifecycle.put({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # lifecycle_configuration: { + # rules: [ # required + # { + # expiration: { + # date: Time.now, + # days: 1, + # expired_object_delete_marker: false, + # }, + # id: "ID", + # prefix: "Prefix", # required + # status: "Enabled", # required, accepts Enabled, Disabled + # transition: { + # date: Time.now, + # days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # }, + # noncurrent_version_transition: { + # noncurrent_days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # newer_noncurrent_versions: 1, + # }, + # noncurrent_version_expiration: { + # noncurrent_days: 1, + # newer_noncurrent_versions: 1, + # }, + # abort_incomplete_multipart_upload: { + # days_after_initiation: 1, + # }, + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#264 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketLifecycle}. + # Returns `self` making it possible to chain methods. + # + # bucket_lifecycle.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#56 + def reload; end + + # Container for a lifecycle rule. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#39 + def rules; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#160 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#291 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle.rb#302 +class Aws::S3::BucketLifecycle::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#12 +class Aws::S3::BucketLifecycleConfiguration + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketLifecycleConfiguration] a new instance of BucketLifecycleConfiguration + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#295 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#46 + def client; end + + # @return [Types::GetBucketLifecycleConfigurationOutput] Returns the data for this {BucketLifecycleConfiguration}. Calls + # {Client#get_bucket_lifecycle_configuration} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#68 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#76 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # bucket_lifecycle_configuration.delete({ + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#192 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#304 + def deprecated_identifiers; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketLifecycleConfiguration}. + # Returns `self` making it possible to chain methods. + # + # bucket_lifecycle_configuration.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#56 + def load; end + + # @example Request syntax with placeholder values + # + # bucket_lifecycle_configuration.put({ + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # lifecycle_configuration: { + # rules: [ # required + # { + # expiration: { + # date: Time.now, + # days: 1, + # expired_object_delete_marker: false, + # }, + # id: "ID", + # prefix: "Prefix", + # filter: { + # prefix: "Prefix", + # tag: { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # object_size_greater_than: 1, + # object_size_less_than: 1, + # and: { + # prefix: "Prefix", + # tags: [ + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # object_size_greater_than: 1, + # object_size_less_than: 1, + # }, + # }, + # status: "Enabled", # required, accepts Enabled, Disabled + # transitions: [ + # { + # date: Time.now, + # days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # }, + # ], + # noncurrent_version_transitions: [ + # { + # noncurrent_days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # newer_noncurrent_versions: 1, + # }, + # ], + # noncurrent_version_expiration: { + # noncurrent_days: 1, + # newer_noncurrent_versions: 1, + # }, + # abort_incomplete_multipart_upload: { + # days_after_initiation: 1, + # }, + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#284 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketLifecycleConfiguration}. + # Returns `self` making it possible to chain methods. + # + # bucket_lifecycle_configuration.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#56 + def reload; end + + # Container for a lifecycle rule. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#39 + def rules; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#160 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#311 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_lifecycle_configuration.rb#322 +class Aws::S3::BucketLifecycleConfiguration::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#12 +class Aws::S3::BucketLogging + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketLogging] a new instance of BucketLogging + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#259 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#52 + def client; end + + # @return [Types::GetBucketLoggingOutput] Returns the data for this {BucketLogging}. Calls + # {Client#get_bucket_logging} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#74 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#82 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#268 + def deprecated_identifiers; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketLogging}. + # Returns `self` making it possible to chain methods. + # + # bucket_logging.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#62 + def load; end + + # Describes where logs are stored and the prefix that Amazon S3 assigns + # to all log object keys for a bucket. For more information, see [PUT + # Bucket logging][1] in the *Amazon S3 API Reference*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTlogging.html + # + # @return [Types::LoggingEnabled] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#45 + def logging_enabled; end + + # @example Request syntax with placeholder values + # + # bucket_logging.put({ + # bucket_logging_status: { # required + # logging_enabled: { + # target_bucket: "TargetBucket", # required + # target_grants: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, READ, WRITE + # }, + # ], + # target_prefix: "TargetPrefix", # required + # target_object_key_format: { + # simple_prefix: { + # }, + # partitioned_prefix: { + # partition_date_source: "EventTime", # accepts EventTime, DeliveryTime + # }, + # }, + # }, + # }, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#248 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketLogging}. + # Returns `self` making it possible to chain methods. + # + # bucket_logging.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#62 + def reload; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#166 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#275 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_logging.rb#286 +class Aws::S3::BucketLogging::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#12 +class Aws::S3::BucketNotification + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketNotification] a new instance of BucketNotification + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#287 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#67 + def client; end + + # @return [Types::NotificationConfiguration] Returns the data for this {BucketNotification}. Calls + # {Client#get_bucket_notification_configuration} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#89 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#97 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#296 + def deprecated_identifiers; end + + # Enables delivery of events to Amazon EventBridge. + # + # @return [Types::EventBridgeConfiguration] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#60 + def event_bridge_configuration; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Describes the Lambda functions to invoke and the events for which to + # invoke them. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#54 + def lambda_function_configurations; end + + # Loads, or reloads {#data} for the current {BucketNotification}. + # Returns `self` making it possible to chain methods. + # + # bucket_notification.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#77 + def load; end + + # @example Request syntax with placeholder values + # + # bucket_notification.put({ + # notification_configuration: { # required + # topic_configurations: [ + # { + # id: "NotificationId", + # topic_arn: "TopicArn", # required + # events: ["s3:ReducedRedundancyLostObject"], # required, accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # filter: { + # key: { + # filter_rules: [ + # { + # name: "prefix", # accepts prefix, suffix + # value: "FilterRuleValue", + # }, + # ], + # }, + # }, + # }, + # ], + # queue_configurations: [ + # { + # id: "NotificationId", + # queue_arn: "QueueArn", # required + # events: ["s3:ReducedRedundancyLostObject"], # required, accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # filter: { + # key: { + # filter_rules: [ + # { + # name: "prefix", # accepts prefix, suffix + # value: "FilterRuleValue", + # }, + # ], + # }, + # }, + # }, + # ], + # lambda_function_configurations: [ + # { + # id: "NotificationId", + # lambda_function_arn: "LambdaFunctionArn", # required + # events: ["s3:ReducedRedundancyLostObject"], # required, accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # filter: { + # key: { + # filter_rules: [ + # { + # name: "prefix", # accepts prefix, suffix + # value: "FilterRuleValue", + # }, + # ], + # }, + # }, + # }, + # ], + # event_bridge_configuration: { + # }, + # }, + # expected_bucket_owner: "AccountId", + # skip_destination_validation: false, + # }) + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#276 + def put(options = T.unsafe(nil)); end + + # The Amazon Simple Queue Service queues to publish messages to and the + # events for which to publish messages. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#47 + def queue_configurations; end + + # Loads, or reloads {#data} for the current {BucketNotification}. + # Returns `self` making it possible to chain methods. + # + # bucket_notification.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#77 + def reload; end + + # The topic to which notifications are sent and the events for which + # notifications are generated. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#40 + def topic_configurations; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#181 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#303 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_notification.rb#314 +class Aws::S3::BucketNotification::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#12 +class Aws::S3::BucketPolicy + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketPolicy] a new instance of BucketPolicy + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#296 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#46 + def client; end + + # @return [Types::GetBucketPolicyOutput] Returns the data for this {BucketPolicy}. Calls + # {Client#get_bucket_policy} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#68 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#76 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # bucket_policy.delete({ + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#198 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#305 + def deprecated_identifiers; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketPolicy}. + # Returns `self` making it possible to chain methods. + # + # bucket_policy.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#56 + def load; end + + # The bucket policy as a JSON document. + # + # @return [IO] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#39 + def policy; end + + # @example Request syntax with placeholder values + # + # bucket_policy.put({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # confirm_remove_self_bucket_access: false, + # policy: "Policy", # required + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#285 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketPolicy}. + # Returns `self` making it possible to chain methods. + # + # bucket_policy.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#56 + def reload; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#160 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#312 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_policy.rb#323 +class Aws::S3::BucketPolicy::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#7 +class Aws::S3::BucketRegionCache + # @return [BucketRegionCache] a new instance of BucketRegionCache + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#9 + def initialize; end + + # @api private + # @param bucket_name [String] + # @return [String, nil] Returns the cached region for the named bucket. + # Returns `nil` if the bucket is not in the cache. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#45 + def [](bucket_name); end + + # Caches a bucket's region. Calling this method will trigger each + # of the {#bucket_added} listener callbacks. + # + # @api private + # @param bucket_name [String] + # @param region_name [String] + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#55 + def []=(bucket_name, region_name); end + + # Registers a block as a callback. This listener is called when a + # new bucket/region pair is added to the cache. + # + # Aws::S3.bucket_region_cache.bucket_added do |bucket_name, region_name| + # # ... + # end + # + # This happens when a request is made against the classic endpoint, + # "s3.amazonaws.com" and an error is returned requiring the request + # to be resent with Signature Version 4. At this point, multiple + # requests are made to discover the bucket region so that a v4 + # signature can be generated. + # + # An application can register listeners here to avoid these extra + # requests in the future. By constructing an {S3::Client} with + # the proper region, a proper signature can be generated and redirects + # avoided. + # + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#33 + def bucket_added(&block); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#71 + def clear; end + + # @param key [String] + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#64 + def key?(key); end + + # @return [Hash] Returns a hash of cached bucket names and region names. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#76 + def to_h; end + + # @return [Hash] Returns a hash of cached bucket names and region names. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_region_cache.rb#76 + def to_hash; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#12 +class Aws::S3::BucketRequestPayment + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketRequestPayment] a new instance of BucketRequestPayment + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#237 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#46 + def client; end + + # @return [Types::GetBucketRequestPaymentOutput] Returns the data for this {BucketRequestPayment}. Calls + # {Client#get_bucket_request_payment} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#68 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#76 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#246 + def deprecated_identifiers; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketRequestPayment}. + # Returns `self` making it possible to chain methods. + # + # bucket_request_payment.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#56 + def load; end + + # Specifies who pays for the download and request fees. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#39 + def payer; end + + # @example Request syntax with placeholder values + # + # bucket_request_payment.put({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # request_payment_configuration: { # required + # payer: "Requester", # required, accepts Requester, BucketOwner + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#226 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketRequestPayment}. + # Returns `self` making it possible to chain methods. + # + # bucket_request_payment.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#56 + def reload; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#160 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#253 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_request_payment.rb#264 +class Aws::S3::BucketRequestPayment::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#12 +class Aws::S3::BucketTagging + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketTagging] a new instance of BucketTagging + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#261 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#46 + def client; end + + # @return [Types::GetBucketTaggingOutput] Returns the data for this {BucketTagging}. Calls + # {Client#get_bucket_tagging} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#68 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#76 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # bucket_tagging.delete({ + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#192 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#270 + def deprecated_identifiers; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketTagging}. + # Returns `self` making it possible to chain methods. + # + # bucket_tagging.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#56 + def load; end + + # @example Request syntax with placeholder values + # + # bucket_tagging.put({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # tagging: { # required + # tag_set: [ # required + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#250 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketTagging}. + # Returns `self` making it possible to chain methods. + # + # bucket_tagging.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#56 + def reload; end + + # Contains the tag set. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#39 + def tag_set; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#160 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#277 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_tagging.rb#288 +class Aws::S3::BucketTagging::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#12 +class Aws::S3::BucketVersioning + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketVersioning] a new instance of BucketVersioning + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#368 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#55 + def client; end + + # @return [Types::GetBucketVersioningOutput] Returns the data for this {BucketVersioning}. Calls + # {Client#get_bucket_versioning} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#77 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#85 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#377 + def deprecated_identifiers; end + + # @example Request syntax with placeholder values + # + # bucket_versioning.enable({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # mfa: "MFA", + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#235 + def enable(options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {BucketVersioning}. + # Returns `self` making it possible to chain methods. + # + # bucket_versioning.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#65 + def load; end + + # Specifies whether MFA delete is enabled in the bucket versioning + # configuration. This element is only returned if the bucket has been + # configured with MFA delete. If the bucket has never been so + # configured, this element is not returned. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#48 + def mfa_delete; end + + # @example Request syntax with placeholder values + # + # bucket_versioning.put({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # mfa: "MFA", + # versioning_configuration: { # required + # mfa_delete: "Enabled", # accepts Enabled, Disabled + # status: "Enabled", # accepts Enabled, Suspended + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#299 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {BucketVersioning}. + # Returns `self` making it possible to chain methods. + # + # bucket_versioning.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#65 + def reload; end + + # The versioning state of the bucket. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#39 + def status; end + + # @example Request syntax with placeholder values + # + # bucket_versioning.suspend({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # mfa: "MFA", + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#352 + def suspend(options = T.unsafe(nil)); end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#169 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#384 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_versioning.rb#395 +class Aws::S3::BucketVersioning::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#12 +class Aws::S3::BucketWebsite + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [BucketWebsite] a new instance of BucketWebsite + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#22 + def initialize(*args); end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#302 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#33 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#68 + def client; end + + # @return [Types::GetBucketWebsiteOutput] Returns the data for this {BucketWebsite}. Calls + # {Client#get_bucket_website} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#90 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#98 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # bucket_website.delete({ + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#214 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#311 + def deprecated_identifiers; end + + # The object key name of the website error document to use for 4XX class + # errors. + # + # @return [Types::ErrorDocument] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#54 + def error_document; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # The name of the index document for the website (for example + # `index.html`). + # + # @return [Types::IndexDocument] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#47 + def index_document; end + + # Loads, or reloads {#data} for the current {BucketWebsite}. + # Returns `self` making it possible to chain methods. + # + # bucket_website.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#78 + def load; end + + # @example Request syntax with placeholder values + # + # bucket_website.put({ + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # website_configuration: { # required + # error_document: { + # key: "ObjectKey", # required + # }, + # index_document: { + # suffix: "Suffix", # required + # }, + # redirect_all_requests_to: { + # host_name: "HostName", # required + # protocol: "http", # accepts http, https + # }, + # routing_rules: [ + # { + # condition: { + # http_error_code_returned_equals: "HttpErrorCodeReturnedEquals", + # key_prefix_equals: "KeyPrefixEquals", + # }, + # redirect: { # required + # host_name: "HostName", + # http_redirect_code: "HttpRedirectCode", + # protocol: "http", # accepts http, https + # replace_key_prefix_with: "ReplaceKeyPrefixWith", + # replace_key_with: "ReplaceKeyWith", + # }, + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [EmptyStructure] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#291 + def put(options = T.unsafe(nil)); end + + # Specifies the redirect behavior of all requests to a website endpoint + # of an Amazon S3 bucket. + # + # @return [Types::RedirectAllRequestsTo] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#40 + def redirect_all_requests_to; end + + # Loads, or reloads {#data} for the current {BucketWebsite}. + # Returns `self` making it possible to chain methods. + # + # bucket_website.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#78 + def reload; end + + # Rules that define when a redirect is applied and the redirect + # behavior. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#61 + def routing_rules; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#182 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#318 + def extract_bucket_name(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/bucket_website.rb#329 +class Aws::S3::BucketWebsite::Collection < ::Aws::Resources::Collection; end + +# An API client for S3. To construct a client, you need to configure a `:region` and `:credentials`. +# +# client = Aws::S3::Client.new( +# region: region_name, +# credentials: credentials, +# # ... +# ) +# +# For details on configuring region and credentials see +# the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html). +# +# See {#initialize} for a full list of supported configuration options. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#74 +class Aws::S3::Client < ::Seahorse::Client::Base + include ::Aws::ClientStubs + + # @overload initialize + # @return [Client] a new instance of Client + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#529 + def initialize(*args); end + + # This operation aborts a multipart upload. After a multipart upload is + # aborted, no additional parts can be uploaded using that upload ID. The + # storage consumed by any previously uploaded parts will be freed. + # However, if any part uploads are currently in progress, those part + # uploads might or might not succeed. As a result, it might be necessary + # to abort a given multipart upload multiple times in order to + # completely free all storage consumed by all parts. + # + # To verify that all parts have been removed and prevent getting charged + # for the part storage, you should call the [ListParts][1] API operation + # and ensure that the parts list is empty. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][2] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - For information about + # permissions required to use the multipart upload, see [Multipart + # Upload and Permissions][3] in the *Amazon S3 User Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][4] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][4]. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `AbortMultipartUpload`: + # + # * [CreateMultipartUpload][5] + # + # * [UploadPart][6] + # + # * [CompleteMultipartUpload][7] + # + # * [ListParts][1] + # + # * [ListMultipartUploads][8] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html + # + # @example Example: To abort a multipart upload + # + # # The following example aborts a multipart upload. + # + # resp = client.abort_multipart_upload({ + # bucket: "examplebucket", + # key: "bigobject", + # upload_id: "xadcOB_7YPBOJuoFiQ9cz4P3Pe6FIZwO4f7wN93uHsNBEw97pl5eNwzExg0LAT2dUN91cOmrEQHDsP3WA60CEg--", + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.abort_multipart_upload({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # upload_id: "MultipartUploadId", # required + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload abort_multipart_upload + # @param params [Hash] ({}) + # @return [Types::AbortMultipartUploadOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::AbortMultipartUploadOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortMultipartUpload AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#713 + def abort_multipart_upload(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # @api private + # @param params [{}] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18857 + def build_request(operation_name, params = T.unsafe(nil)); end + + # Completes a multipart upload by assembling previously uploaded parts. + # + # You first initiate the multipart upload and then upload all parts + # using the [UploadPart][1] operation or the [UploadPartCopy][2] + # operation. After successfully uploading all relevant parts of an + # upload, you call this `CompleteMultipartUpload` operation to complete + # the upload. Upon receiving this request, Amazon S3 concatenates all + # the parts in ascending order by part number to create a new object. In + # the CompleteMultipartUpload request, you must provide the parts list + # and ensure that the parts list is complete. The + # CompleteMultipartUpload API operation concatenates the parts that you + # provide in the list. For each part in the list, you must provide the + # `PartNumber` value and the `ETag` value that are returned after that + # part was uploaded. + # + # The processing of a CompleteMultipartUpload request could take several + # minutes to finalize. After Amazon S3 begins processing the request, it + # sends an HTTP response header that specifies a `200 OK` response. + # While processing is in progress, Amazon S3 periodically sends white + # space characters to keep the connection from timing out. A request + # could fail after the initial `200 OK` response has been sent. This + # means that a `200 OK` response can contain either a success or an + # error. The error response might be embedded in the `200 OK` response. + # If you call this API operation directly, make sure to design your + # application to parse the contents of the response and handle it + # appropriately. If you use Amazon Web Services SDKs, SDKs handle this + # condition. The SDKs detect the embedded error and apply error handling + # per your configuration settings (including automatically retrying the + # request as appropriate). If the condition persists, the SDKs throw an + # exception (or, for the SDKs that don't use exceptions, they return an + # error). + # + # Note that if `CompleteMultipartUpload` fails, applications should be + # prepared to retry any failed requests (including 500 error responses). + # For more information, see [Amazon S3 Error Best Practices][3]. + # + # You can't use `Content-Type: application/x-www-form-urlencoded` for + # the CompleteMultipartUpload requests. Also, if you don't provide a + # `Content-Type` header, `CompleteMultipartUpload` can still return a + # `200 OK` response. + # + # For more information about multipart uploads, see [Uploading Objects + # Using Multipart Upload][4] in the *Amazon S3 User Guide*. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][5] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - For information about + # permissions required to use the multipart upload API, see + # [Multipart Upload and Permissions][6] in the *Amazon S3 User + # Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][7] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][7]. + # + # Special errors + # : * Error Code: `EntityTooSmall` + # + # * Description: Your proposed upload is smaller than the minimum + # allowed object size. Each part must be at least 5 MB in size, + # except the last part. + # + # * HTTP Status Code: 400 Bad Request + # + # * Error Code: `InvalidPart` + # + # * Description: One or more of the specified parts could not be + # found. The part might not have been uploaded, or the specified + # ETag might not have matched the uploaded part's ETag. + # + # * HTTP Status Code: 400 Bad Request + # + # * Error Code: `InvalidPartOrder` + # + # * Description: The list of parts was not in ascending order. The + # parts list must be specified in order by part number. + # + # * HTTP Status Code: 400 Bad Request + # + # * Error Code: `NoSuchUpload` + # + # * Description: The specified multipart upload does not exist. The + # upload ID might be invalid, or the multipart upload might have + # been aborted or completed. + # + # * HTTP Status Code: 404 Not Found + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `CompleteMultipartUpload`: + # + # * [CreateMultipartUpload][8] + # + # * [UploadPart][1] + # + # * [AbortMultipartUpload][9] + # + # * [ListParts][10] + # + # * [ListMultipartUploads][11] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ErrorBestPractices.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/uploadobjusingmpu.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html + # + # @example Example: To complete multipart upload + # + # # The following example completes a multipart upload. + # + # resp = client.complete_multipart_upload({ + # bucket: "examplebucket", + # key: "bigobject", + # multipart_upload: { + # parts: [ + # { + # etag: "\"d8c2eafd90c266e19ab9dcacc479f8af\"", + # part_number: 1, + # }, + # { + # etag: "\"d8c2eafd90c266e19ab9dcacc479f8af\"", + # part_number: 2, + # }, + # ], + # }, + # upload_id: "7YPBOJuoFiQ9cz4P3Pe6FIZwO4f7wN93uHsNBEw97pl5eNwzExg0LAT2dUN91cOmrEQHDsP3WA60CEg--", + # }) + # + # resp.to_h outputs the following: + # { + # bucket: "acexamplebucket", + # etag: "\"4d9031c7644d8081c2829f4ea23c55f7-2\"", + # key: "bigobject", + # location: "https://examplebucket.s3..amazonaws.com/bigobject", + # } + # @example Request syntax with placeholder values + # + # resp = client.complete_multipart_upload({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # multipart_upload: { + # parts: [ + # { + # etag: "ETag", + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # part_number: 1, + # }, + # ], + # }, + # upload_id: "MultipartUploadId", # required + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # }) + # @example Response structure + # + # resp.location #=> String + # resp.bucket #=> String + # resp.key #=> String + # resp.expiration #=> String + # resp.etag #=> String + # resp.checksum_crc32 #=> String + # resp.checksum_crc32c #=> String + # resp.checksum_sha1 #=> String + # resp.checksum_sha256 #=> String + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.version_id #=> String + # resp.ssekms_key_id #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload complete_multipart_upload + # @param params [Hash] ({}) + # @return [Types::CompleteMultipartUploadOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CompleteMultipartUploadOutput#location #location} => String + # * {Types::CompleteMultipartUploadOutput#bucket #bucket} => String + # * {Types::CompleteMultipartUploadOutput#key #key} => String + # * {Types::CompleteMultipartUploadOutput#expiration #expiration} => String + # * {Types::CompleteMultipartUploadOutput#etag #etag} => String + # * {Types::CompleteMultipartUploadOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::CompleteMultipartUploadOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::CompleteMultipartUploadOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::CompleteMultipartUploadOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::CompleteMultipartUploadOutput#server_side_encryption #server_side_encryption} => String + # * {Types::CompleteMultipartUploadOutput#version_id #version_id} => String + # * {Types::CompleteMultipartUploadOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::CompleteMultipartUploadOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::CompleteMultipartUploadOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompleteMultipartUpload AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#1115 + def complete_multipart_upload(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Creates a copy of an object that is already stored in Amazon S3. + # + # You can store individual objects of up to 5 TB in Amazon S3. You + # create a copy of your object up to 5 GB in size in a single atomic + # action using this API. However, to copy an object greater than 5 GB, + # you must use the multipart upload Upload Part - Copy (UploadPartCopy) + # API. For more information, see [Copy Object Using the REST Multipart + # Upload API][1]. + # + # + # + # You can copy individual objects between general purpose buckets, + # between directory buckets, and between general purpose buckets and + # directory buckets. + # + # Directory buckets - For directory buckets, you must make + # requests for this API operation to the Zonal endpoint. These endpoints + # support virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][2] in the *Amazon S3 User Guide*. + # + # + # + # Both the Region that you want to copy the object from and the Region + # that you want to copy the object to must be enabled for your account. + # For more information about how to enable a Region for your account, + # see [Enable or disable a Region for standalone accounts][3] in the + # *Amazon Web Services Account Management Guide*. + # + # Amazon S3 transfer acceleration does not support cross-Region copies. + # If you request a cross-Region copy using a transfer acceleration + # endpoint, you get a `400 Bad Request` error. For more information, see + # [Transfer Acceleration][4]. + # + # Authentication and authorization + # + # : All `CopyObject` requests must be authenticated and signed by using + # IAM credentials (access key ID and secret access key for the IAM + # identities). All headers with the `x-amz-` prefix, including + # `x-amz-copy-source`, must be signed. For more information, see [REST + # Authentication][5]. + # + # **Directory buckets** - You must use the IAM credentials to + # authenticate and authorize your access to the `CopyObject` API + # operation, instead of using the temporary security credentials + # through the `CreateSession` API operation. + # + # Amazon Web Services CLI or SDKs handles authentication and + # authorization on your behalf. + # + # Permissions + # + # : You must have *read* access to the source object and *write* access + # to the destination bucket. + # + # * **General purpose bucket permissions** - You must have permissions + # in an IAM policy based on the source and destination bucket types + # in a `CopyObject` operation. + # + # * If the source object is in a general purpose bucket, you must + # have s3:GetObject permission to read the + # source object that is being copied. + # + # * If the destination bucket is a general purpose bucket, you must + # have s3:PutObject permission to write the + # object copy to the destination bucket. + # + # * **Directory bucket permissions** - You must have permissions in a + # bucket policy or an IAM identity-based policy based on the source + # and destination bucket types in a `CopyObject` operation. + # + # * If the source object that you want to copy is in a directory + # bucket, you must have the + # s3express:CreateSession permission in the + # `Action` element of a policy to read the object. By default, the + # session is in the `ReadWrite` mode. If you want to restrict the + # access, you can explicitly set the `s3express:SessionMode` + # condition key to `ReadOnly` on the copy source bucket. + # + # * If the copy destination is a directory bucket, you must have the + # s3express:CreateSession permission in the + # `Action` element of a policy to write the object to the + # destination. The `s3express:SessionMode` condition key can't be + # set to `ReadOnly` on the copy destination bucket. + # + # For example policies, see [Example bucket policies for S3 Express + # One Zone][6] and [Amazon Web Services Identity and Access + # Management (IAM) identity-based policies for S3 Express One + # Zone][7] in the *Amazon S3 User Guide*. + # + # Response and special errors + # + # : When the request is an HTTP 1.1 request, the response is chunk + # encoded. When the request is not an HTTP 1.1 request, the response + # would not contain the `Content-Length`. You always need to read the + # entire response body to check if the copy succeeds. + # + # * If the copy is successful, you receive a response with information + # about the copied object. + # + # * A copy request might return an error when Amazon S3 receives the + # copy request or while Amazon S3 is copying the files. A `200 OK` + # response can contain either a success or an error. + # + # * If the error occurs before the copy action starts, you receive a + # standard Amazon S3 error. + # + # * If the error occurs during the copy operation, the error + # response is embedded in the `200 OK` response. For example, in a + # cross-region copy, you may encounter throttling and receive a + # `200 OK` response. For more information, see [Resolve the Error + # 200 response when copying objects to Amazon S3][8]. The `200 OK` + # status code means the copy was accepted, but it doesn't mean + # the copy is complete. Another example is when you disconnect + # from Amazon S3 before the copy is complete, Amazon S3 might + # cancel the copy and you may receive a `200 OK` response. You + # must stay connected to Amazon S3 until the entire response is + # successfully received and processed. + # + # If you call this API operation directly, make sure to design + # your application to parse the content of the response and handle + # it appropriately. If you use Amazon Web Services SDKs, SDKs + # handle this condition. The SDKs detect the embedded error and + # apply error handling per your configuration settings (including + # automatically retrying the request as appropriate). If the + # condition persists, the SDKs throw an exception (or, for the + # SDKs that don't use exceptions, they return an error). + # + # Charge + # + # : The copy request charge is based on the storage class and Region + # that you specify for the destination object. The request can also + # result in a data retrieval charge for the source if the source + # storage class bills for data retrieval. If the copy source is in a + # different region, the data transfer is billed to the copy source + # account. For pricing information, see [Amazon S3 pricing][9]. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `CopyObject`: + # + # * [PutObject][10] + # + # * [GetObject][11] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/CopyingObjctsUsingRESTMPUapi.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [3]: https://docs.aws.amazon.com/accounts/latest/reference/manage-acct-regions.html#manage-acct-regions-enable-standalone + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acceleration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-identity-policies.html + # [8]: https://repost.aws/knowledge-center/s3-resolve-200-internalerror + # [9]: http://aws.amazon.com/s3/pricing/ + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # + # @example Example: To copy an object + # + # # The following example copies an object from one bucket to another. + # + # resp = client.copy_object({ + # bucket: "destinationbucket", + # copy_source: "/sourcebucket/HappyFacejpg", + # key: "HappyFaceCopyjpg", + # }) + # + # resp.to_h outputs the following: + # { + # copy_object_result: { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # last_modified: Time.parse("2016-12-15T17:38:53.000Z"), + # }, + # } + # @example Request syntax with placeholder values + # + # resp = client.copy_object({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # bucket: "BucketName", # required + # cache_control: "CacheControl", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_type: "ContentType", + # copy_source: "CopySource", # required + # copy_source_if_match: "CopySourceIfMatch", + # copy_source_if_modified_since: Time.now, + # copy_source_if_none_match: "CopySourceIfNoneMatch", + # copy_source_if_unmodified_since: Time.now, + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # key: "ObjectKey", # required + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # metadata_directive: "COPY", # accepts COPY, REPLACE + # tagging_directive: "COPY", # accepts COPY, REPLACE + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # copy_source_sse_customer_algorithm: "CopySourceSSECustomerAlgorithm", + # copy_source_sse_customer_key: "CopySourceSSECustomerKey", + # copy_source_sse_customer_key_md5: "CopySourceSSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # expected_source_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.copy_object_result.etag #=> String + # resp.copy_object_result.last_modified #=> Time + # resp.copy_object_result.checksum_crc32 #=> String + # resp.copy_object_result.checksum_crc32c #=> String + # resp.copy_object_result.checksum_sha1 #=> String + # resp.copy_object_result.checksum_sha256 #=> String + # resp.expiration #=> String + # resp.copy_source_version_id #=> String + # resp.version_id #=> String + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.sse_customer_algorithm #=> String + # resp.sse_customer_key_md5 #=> String + # resp.ssekms_key_id #=> String + # resp.ssekms_encryption_context #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload copy_object + # @param params [Hash] ({}) + # @return [Types::CopyObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CopyObjectOutput#copy_object_result #copy_object_result} => Types::CopyObjectResult + # * {Types::CopyObjectOutput#expiration #expiration} => String + # * {Types::CopyObjectOutput#copy_source_version_id #copy_source_version_id} => String + # * {Types::CopyObjectOutput#version_id #version_id} => String + # * {Types::CopyObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::CopyObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::CopyObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::CopyObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::CopyObjectOutput#ssekms_encryption_context #ssekms_encryption_context} => String + # * {Types::CopyObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::CopyObjectOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObject AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#2084 + def copy_object(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This action creates an Amazon S3 bucket. To create an Amazon S3 on + # Outposts bucket, see [ `CreateBucket` ][1]. + # + # + # + # Creates a new S3 bucket. To create a bucket, you must set up Amazon S3 + # and have a valid Amazon Web Services Access Key ID to authenticate + # requests. Anonymous requests are never allowed to create buckets. By + # creating the bucket, you become the bucket owner. + # + # There are two types of buckets: general purpose buckets and directory + # buckets. For more information about these bucket types, see [Creating, + # configuring, and working with Amazon S3 buckets][2] in the *Amazon S3 + # User Guide*. + # + # * **General purpose buckets** - If you send your `CreateBucket` + # request to the `s3.amazonaws.com` global endpoint, the request goes + # to the `us-east-1` Region. So the signature calculations in + # Signature Version 4 must use `us-east-1` as the Region, even if the + # location constraint in the request specifies another Region where + # the bucket is to be created. If you create a bucket in a Region + # other than US East (N. Virginia), your application must be able to + # handle 307 redirect. For more information, see [Virtual hosting of + # buckets][3] in the *Amazon S3 User Guide*. + # + # * Directory buckets - For directory buckets, you must make + # requests for this API operation to the Regional endpoint. These + # endpoints support path-style requests in the format + # `https://s3express-control.region_code.amazonaws.com/bucket-name `. + # Virtual-hosted-style requests aren't supported. For more + # information, see [Regional and Zonal endpoints][4] in the *Amazon S3 + # User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - In addition to the + # `s3:CreateBucket` permission, the following permissions are + # required in a policy when your `CreateBucket` request includes + # specific headers: + # + # * **Access control lists (ACLs)** - In your `CreateBucket` + # request, if you specify an access control list (ACL) and set it + # to `public-read`, `public-read-write`, `authenticated-read`, or + # if you explicitly specify any other custom ACLs, both + # `s3:CreateBucket` and `s3:PutBucketAcl` permissions are + # required. In your `CreateBucket` request, if you set the ACL to + # `private`, or if you don't specify any ACLs, only the + # `s3:CreateBucket` permission is required. + # + # * **Object Lock** - In your `CreateBucket` request, if you set + # `x-amz-bucket-object-lock-enabled` to true, the + # `s3:PutBucketObjectLockConfiguration` and + # `s3:PutBucketVersioning` permissions are required. + # + # * **S3 Object Ownership** - If your `CreateBucket` request + # includes the `x-amz-object-ownership` header, then the + # `s3:PutBucketOwnershipControls` permission is required. + # + # To set an ACL on a bucket as part of a `CreateBucket` request, + # you must explicitly set S3 Object Ownership for the bucket to a + # different value than the default, `BucketOwnerEnforced`. + # Additionally, if your desired bucket ACL grants public access, + # you must first create the bucket (without the bucket ACL) and + # then explicitly disable Block Public Access on the bucket before + # using `PutBucketAcl` to set the ACL. If you try to create a + # bucket with a public ACL, the request will fail. + # + # For the majority of modern use cases in S3, we recommend that + # you keep all Block Public Access settings enabled and keep ACLs + # disabled. If you would like to share data with users outside of + # your account, you can use bucket policies as needed. For more + # information, see [Controlling ownership of objects and disabling + # ACLs for your bucket ][5] and [Blocking public access to your + # Amazon S3 storage ][6] in the *Amazon S3 User Guide*. + # + # * **S3 Block Public Access** - If your specific use case requires + # granting public access to your S3 resources, you can disable + # Block Public Access. Specifically, you can create a new bucket + # with Block Public Access enabled, then separately call the [ + # `DeletePublicAccessBlock` ][7] API. To use this operation, you + # must have the `s3:PutBucketPublicAccessBlock` permission. For + # more information about S3 Block Public Access, see [Blocking + # public access to your Amazon S3 storage ][6] in the *Amazon S3 + # User Guide*. + # + # * **Directory bucket permissions** - You must have the + # `s3express:CreateBucket` permission in an IAM identity-based + # policy instead of a bucket policy. Cross-account access to this + # API operation isn't supported. This operation can only be + # performed by the Amazon Web Services account that owns the + # resource. For more information about directory bucket policies and + # permissions, see [Amazon Web Services Identity and Access + # Management (IAM) for S3 Express One Zone][8] in the *Amazon S3 + # User Guide*. + # + # The permissions for ACLs, Object Lock, S3 Object Ownership, and S3 + # Block Public Access are not supported for directory buckets. For + # directory buckets, all Block Public Access settings are enabled at + # the bucket level and S3 Object Ownership is set to Bucket owner + # enforced (ACLs disabled). These settings can't be modified. + # + # For more information about permissions for creating and working + # with directory buckets, see [Directory buckets][9] in the *Amazon + # S3 User Guide*. For more information about supported S3 features + # for directory buckets, see [Features of S3 Express One Zone][10] + # in the *Amazon S3 User Guide*. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is + # `s3express-control.region.amazonaws.com`. + # + # The following operations are related to `CreateBucket`: + # + # * [PutObject][11] + # + # * [DeleteBucket][12] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_control_CreateBucket.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/creating-buckets-s3.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/access-control-block-public-access.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeletePublicAccessBlock.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-one-zone.html#s3-express-features + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucket.html + # + # @example Example: To create a bucket in a specific region + # + # # The following example creates a bucket. The request specifies an AWS region where to create the bucket. + # + # resp = client.create_bucket({ + # bucket: "examplebucket", + # create_bucket_configuration: { + # location_constraint: "eu-west-1", + # }, + # }) + # + # resp.to_h outputs the following: + # { + # location: "http://examplebucket..s3.amazonaws.com/", + # } + # @example Example: To create a bucket + # + # # The following example creates a bucket. + # + # resp = client.create_bucket({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # location: "/examplebucket", + # } + # @example Request syntax with placeholder values + # + # resp = client.create_bucket({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read + # bucket: "BucketName", # required + # create_bucket_configuration: { + # location_constraint: "af-south-1", # accepts af-south-1, ap-east-1, ap-northeast-1, ap-northeast-2, ap-northeast-3, ap-south-1, ap-south-2, ap-southeast-1, ap-southeast-2, ap-southeast-3, ca-central-1, cn-north-1, cn-northwest-1, EU, eu-central-1, eu-north-1, eu-south-1, eu-south-2, eu-west-1, eu-west-2, eu-west-3, me-south-1, sa-east-1, us-east-2, us-gov-east-1, us-gov-west-1, us-west-1, us-west-2 + # location: { + # type: "AvailabilityZone", # accepts AvailabilityZone + # name: "LocationNameAsString", + # }, + # bucket: { + # data_redundancy: "SingleAvailabilityZone", # accepts SingleAvailabilityZone + # type: "Directory", # accepts Directory + # }, + # }, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write: "GrantWrite", + # grant_write_acp: "GrantWriteACP", + # object_lock_enabled_for_bucket: false, + # object_ownership: "BucketOwnerPreferred", # accepts BucketOwnerPreferred, ObjectWriter, BucketOwnerEnforced + # }) + # @example Response structure + # + # resp.location #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload create_bucket + # @param params [Hash] ({}) + # @return [Types::CreateBucketOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateBucketOutput#location #location} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucket AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#2404 + def create_bucket(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This action initiates a multipart upload and returns an upload ID. + # This upload ID is used to associate all of the parts in the specific + # multipart upload. You specify this upload ID in each of your + # subsequent upload part requests (see [UploadPart][1]). You also + # include this upload ID in the final request to either complete or + # abort the multipart upload request. For more information about + # multipart uploads, see [Multipart Upload Overview][2] in the *Amazon + # S3 User Guide*. + # + # After you initiate a multipart upload and upload one or more parts, to + # stop being charged for storing the uploaded parts, you must either + # complete or abort the multipart upload. Amazon S3 frees up the space + # used to store the parts and stops charging you for storing them only + # after you either complete or abort a multipart upload. + # + # + # + # If you have configured a lifecycle rule to abort incomplete multipart + # uploads, the created multipart upload must be completed within the + # number of days specified in the bucket lifecycle configuration. + # Otherwise, the incomplete multipart upload becomes eligible for an + # abort action and Amazon S3 aborts the multipart upload. For more + # information, see [Aborting Incomplete Multipart Uploads Using a Bucket + # Lifecycle Configuration][3]. + # + # * Directory buckets - S3 Lifecycle is not supported by + # directory buckets. + # + # * Directory buckets - For directory buckets, you must make + # requests for this API operation to the Zonal endpoint. These + # endpoints support virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name + # `. Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][4] in the *Amazon S3 User Guide*. + # + # + # + # Request signing + # + # : For request signing, multipart upload is just a series of regular + # requests. You initiate a multipart upload, send one or more requests + # to upload parts, and then complete the multipart upload process. You + # sign each request individually. There is nothing special about + # signing multipart upload requests. For more information about + # signing, see [Authenticating Requests (Amazon Web Services Signature + # Version 4)][5] in the *Amazon S3 User Guide*. + # + # Permissions + # : * **General purpose bucket permissions** - For information about the + # permissions required to use the multipart upload API, see + # [Multipart upload and permissions][6] in the *Amazon S3 User + # Guide*. + # + # To perform a multipart upload with encryption by using an Amazon + # Web Services KMS key, the requester must have permission to the + # `kms:Decrypt` and `kms:GenerateDataKey*` actions on the key. These + # permissions are required because Amazon S3 must decrypt and read + # data from the encrypted file parts before it completes the + # multipart upload. For more information, see [Multipart upload API + # and permissions][7] and [Protecting data using server-side + # encryption with Amazon Web Services KMS][8] in the *Amazon S3 User + # Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][9] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][9]. + # + # Encryption + # : * **General purpose buckets** - Server-side encryption is for data + # encryption at rest. Amazon S3 encrypts your data as it writes it + # to disks in its data centers and decrypts it when you access it. + # Amazon S3 automatically encrypts all new objects that are uploaded + # to an S3 bucket. When doing a multipart upload, if you don't + # specify encryption information in your request, the encryption + # setting of the uploaded parts is set to the default encryption + # configuration of the destination bucket. By default, all buckets + # have a base level of encryption configuration that uses + # server-side encryption with Amazon S3 managed keys (SSE-S3). If + # the destination bucket has a default encryption configuration that + # uses server-side encryption with an Key Management Service (KMS) + # key (SSE-KMS), or a customer-provided encryption key (SSE-C), + # Amazon S3 uses the corresponding KMS key, or a customer-provided + # key to encrypt the uploaded parts. When you perform a + # CreateMultipartUpload operation, if you want to use a different + # type of encryption setting for the uploaded parts, you can request + # that Amazon S3 encrypts the object with a different encryption key + # (such as an Amazon S3 managed key, a KMS key, or a + # customer-provided key). When the encryption setting in your + # request is different from the default encryption configuration of + # the destination bucket, the encryption setting in your request + # takes precedence. If you choose to provide your own encryption + # key, the request headers you provide in [UploadPart][1] and + # [UploadPartCopy][10] requests must match the headers you used in + # the `CreateMultipartUpload` request. + # + # * Use KMS keys (SSE-KMS) that include the Amazon Web Services + # managed key (`aws/s3`) and KMS customer managed keys stored in + # Key Management Service (KMS) – If you want Amazon Web Services + # to manage the keys used to encrypt data, specify the following + # headers in the request. + # + # * `x-amz-server-side-encryption` + # + # * `x-amz-server-side-encryption-aws-kms-key-id` + # + # * `x-amz-server-side-encryption-context` + # + # * If you specify `x-amz-server-side-encryption:aws:kms`, but + # don't provide `x-amz-server-side-encryption-aws-kms-key-id`, + # Amazon S3 uses the Amazon Web Services managed key (`aws/s3` + # key) in KMS to protect the data. + # + # * To perform a multipart upload with encryption by using an + # Amazon Web Services KMS key, the requester must have + # permission to the `kms:Decrypt` and `kms:GenerateDataKey*` + # actions on the key. These permissions are required because + # Amazon S3 must decrypt and read data from the encrypted file + # parts before it completes the multipart upload. For more + # information, see [Multipart upload API and permissions][7] and + # [Protecting data using server-side encryption with Amazon Web + # Services KMS][8] in the *Amazon S3 User Guide*. + # + # * If your Identity and Access Management (IAM) user or role is + # in the same Amazon Web Services account as the KMS key, then + # you must have these permissions on the key policy. If your IAM + # user or role is in a different account from the key, then you + # must have the permissions on both the key policy and your IAM + # user or role. + # + # * All `GET` and `PUT` requests for an object protected by KMS + # fail if you don't make them by using Secure Sockets Layer + # (SSL), Transport Layer Security (TLS), or Signature Version 4. + # For information about configuring any of the officially + # supported Amazon Web Services SDKs and Amazon Web Services + # CLI, see [Specifying the Signature Version in Request + # Authentication][11] in the *Amazon S3 User Guide*. + # + # + # + # For more information about server-side encryption with KMS keys + # (SSE-KMS), see [Protecting Data Using Server-Side Encryption + # with KMS keys][8] in the *Amazon S3 User Guide*. + # + # * Use customer-provided encryption keys (SSE-C) – If you want to + # manage your own encryption keys, provide all the following + # headers in the request. + # + # * `x-amz-server-side-encryption-customer-algorithm` + # + # * `x-amz-server-side-encryption-customer-key` + # + # * `x-amz-server-side-encryption-customer-key-MD5` + # + # For more information about server-side encryption with + # customer-provided encryption keys (SSE-C), see [ Protecting data + # using server-side encryption with customer-provided encryption + # keys (SSE-C)][12] in the *Amazon S3 User Guide*. + # + # * **Directory buckets** -For directory buckets, only server-side + # encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) is + # supported. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `CreateMultipartUpload`: + # + # * [UploadPart][1] + # + # * [CompleteMultipartUpload][13] + # + # * [AbortMultipartUpload][14] + # + # * [ListParts][15] + # + # * [ListMultipartUploads][16] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html#mpu-abort-incomplete-mpu-lifecycle-config + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/mpuoverview.html#mpuAndPermissions + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingAWSSDK.html#specify-signature-version + # [12]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/ServerSideEncryptionCustomerKeys.html + # [13]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html + # [14]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html + # [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # [16]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html + # + # @example Example: To initiate a multipart upload + # + # # The following example initiates a multipart upload. + # + # resp = client.create_multipart_upload({ + # bucket: "examplebucket", + # key: "largeobject", + # }) + # + # resp.to_h outputs the following: + # { + # bucket: "examplebucket", + # key: "largeobject", + # upload_id: "ibZBv_75gd9r8lH_gqXatLdxMVpAlj6ZQjEs.OwyF3953YdwbcQnMA2BLGn8Lx12fQNICtMw5KyteFeHw.Sjng--", + # } + # @example Request syntax with placeholder values + # + # resp = client.create_multipart_upload({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # bucket: "BucketName", # required + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_type: "ContentType", + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # key: "ObjectKey", # required + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @example Response structure + # + # resp.abort_date #=> Time + # resp.abort_rule_id #=> String + # resp.bucket #=> String + # resp.key #=> String + # resp.upload_id #=> String + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.sse_customer_algorithm #=> String + # resp.sse_customer_key_md5 #=> String + # resp.ssekms_key_id #=> String + # resp.ssekms_encryption_context #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.request_charged #=> String, one of "requester" + # resp.checksum_algorithm #=> String, one of "CRC32", "CRC32C", "SHA1", "SHA256" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload create_multipart_upload + # @param params [Hash] ({}) + # @return [Types::CreateMultipartUploadOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateMultipartUploadOutput#abort_date #abort_date} => Time + # * {Types::CreateMultipartUploadOutput#abort_rule_id #abort_rule_id} => String + # * {Types::CreateMultipartUploadOutput#bucket #bucket} => String + # * {Types::CreateMultipartUploadOutput#key #key} => String + # * {Types::CreateMultipartUploadOutput#upload_id #upload_id} => String + # * {Types::CreateMultipartUploadOutput#server_side_encryption #server_side_encryption} => String + # * {Types::CreateMultipartUploadOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::CreateMultipartUploadOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::CreateMultipartUploadOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::CreateMultipartUploadOutput#ssekms_encryption_context #ssekms_encryption_context} => String + # * {Types::CreateMultipartUploadOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::CreateMultipartUploadOutput#request_charged #request_charged} => String + # * {Types::CreateMultipartUploadOutput#checksum_algorithm #checksum_algorithm} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateMultipartUpload AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3222 + def create_multipart_upload(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Creates a session that establishes temporary security credentials to + # support fast authentication and authorization for the Zonal endpoint + # APIs on directory buckets. For more information about Zonal endpoint + # APIs that include the Availability Zone in the request endpoint, see + # [S3 Express One Zone APIs][1] in the *Amazon S3 User Guide*. + # + # To make Zonal endpoint API requests on a directory bucket, use the + # `CreateSession` API operation. Specifically, you grant + # `s3express:CreateSession` permission to a bucket in a bucket policy or + # an IAM identity-based policy. Then, you use IAM credentials to make + # the `CreateSession` API request on the bucket, which returns temporary + # security credentials that include the access key ID, secret access + # key, session token, and expiration. These credentials have associated + # permissions to access the Zonal endpoint APIs. After the session is + # created, you don’t need to use other policies to grant permissions to + # each Zonal endpoint API individually. Instead, in your Zonal endpoint + # API requests, you sign your requests by applying the temporary + # security credentials of the session to the request headers and + # following the SigV4 protocol for authentication. You also apply the + # session token to the `x-amz-s3session-token` request header for + # authorization. Temporary security credentials are scoped to the bucket + # and expire after 5 minutes. After the expiration time, any calls that + # you make with those credentials will fail. You must use IAM + # credentials again to make a `CreateSession` API request that generates + # a new set of temporary credentials for use. Temporary credentials + # cannot be extended or refreshed beyond the original specified + # interval. + # + # If you use Amazon Web Services SDKs, SDKs handle the session token + # refreshes automatically to avoid service interruptions when a session + # expires. We recommend that you use the Amazon Web Services SDKs to + # initiate and manage requests to the CreateSession API. For more + # information, see [Performance guidelines and design patterns][2] in + # the *Amazon S3 User Guide*. + # + # * You must make requests for this API operation to the Zonal endpoint. + # These endpoints support virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com`. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][3] in the *Amazon S3 User Guide*. + # + # * CopyObject API operation - Unlike other Zonal + # endpoint APIs, the `CopyObject` API operation doesn't use the + # temporary security credentials returned from the `CreateSession` API + # operation for authentication and authorization. For information + # about authentication and authorization of the `CopyObject` API + # operation on directory buckets, see [CopyObject][4]. + # + # * HeadBucket API operation - Unlike other Zonal + # endpoint APIs, the `HeadBucket` API operation doesn't use the + # temporary security credentials returned from the `CreateSession` API + # operation for authentication and authorization. For information + # about authentication and authorization of the `HeadBucket` API + # operation on directory buckets, see [HeadBucket][5]. + # + # + # + # Permissions + # + # : To obtain temporary security credentials, you must create a bucket + # policy or an IAM identity-based policy that grants + # `s3express:CreateSession` permission to the bucket. In a policy, you + # can have the `s3express:SessionMode` condition key to control who + # can create a `ReadWrite` or `ReadOnly` session. For more information + # about `ReadWrite` or `ReadOnly` sessions, see [ + # `x-amz-create-session-mode` ][6]. For example policies, see [Example + # bucket policies for S3 Express One Zone][7] and [Amazon Web Services + # Identity and Access Management (IAM) identity-based policies for S3 + # Express One Zone][8] in the *Amazon S3 User Guide*. + # + # To grant cross-account access to Zonal endpoint APIs, the bucket + # policy should also grant both accounts the `s3express:CreateSession` + # permission. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-APIs.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-optimizing-performance-guidelines-design-patterns.html#s3-express-optimizing-performance-session-authentication + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_HeadBucket.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html#API_CreateSession_RequestParameters + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-identity-policies.html + # + # @example Request syntax with placeholder values + # + # resp = client.create_session({ + # session_mode: "ReadOnly", # accepts ReadOnly, ReadWrite + # bucket: "BucketName", # required + # }) + # @example Response structure + # + # resp.credentials.access_key_id #=> String + # resp.credentials.secret_access_key #=> String + # resp.credentials.session_token #=> String + # resp.credentials.expiration #=> Time + # @option params + # @option params + # @overload create_session + # @param params [Hash] ({}) + # @return [Types::CreateSessionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateSessionOutput#credentials #credentials} => Types::SessionCredentials + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateSession AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3351 + def create_session(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes the S3 bucket. All objects (including all object versions and + # delete markers) in the bucket must be deleted before the bucket itself + # can be deleted. + # + # * **Directory buckets** - If multipart uploads in a directory bucket + # are in progress, you can't delete the bucket until all the + # in-progress multipart uploads are aborted or completed. + # + # * Directory buckets - For directory buckets, you must make + # requests for this API operation to the Regional endpoint. These + # endpoints support path-style requests in the format + # `https://s3express-control.region_code.amazonaws.com/bucket-name `. + # Virtual-hosted-style requests aren't supported. For more + # information, see [Regional and Zonal endpoints][1] in the *Amazon S3 + # User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - You must have the + # `s3:DeleteBucket` permission on the specified bucket in a policy. + # + # * **Directory bucket permissions** - You must have the + # `s3express:DeleteBucket` permission in an IAM identity-based + # policy instead of a bucket policy. Cross-account access to this + # API operation isn't supported. This operation can only be + # performed by the Amazon Web Services account that owns the + # resource. For more information about directory bucket policies and + # permissions, see [Amazon Web Services Identity and Access + # Management (IAM) for S3 Express One Zone][2] in the *Amazon S3 + # User Guide*. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is + # `s3express-control.region.amazonaws.com`. + # + # The following operations are related to `DeleteBucket`: + # + # * [CreateBucket][3] + # + # * [DeleteObject][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObject.html + # + # @example Example: To delete a bucket + # + # # The following example deletes the specified bucket. + # + # resp = client.delete_bucket({ + # bucket: "forrandall2", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucket AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3456 + def delete_bucket(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes an analytics configuration for the bucket (specified by the + # analytics configuration ID). + # + # To use this operation, you must have permissions to perform the + # `s3:PutAnalyticsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For information about the Amazon S3 analytics feature, see [Amazon S3 + # Analytics – Storage Class Analysis][3]. + # + # The following operations are related to + # `DeleteBucketAnalyticsConfiguration`: + # + # * [GetBucketAnalyticsConfiguration][4] + # + # * [ListBucketAnalyticsConfigurations][5] + # + # * [PutBucketAnalyticsConfiguration][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/analytics-storage-class.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketAnalyticsConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketAnalyticsConfigurations.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketAnalyticsConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_analytics_configuration({ + # bucket: "BucketName", # required + # id: "AnalyticsId", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @overload delete_bucket_analytics_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketAnalyticsConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3522 + def delete_bucket_analytics_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes the `cors` configuration information set for the bucket. + # + # To use this operation, you must have permission to perform the + # `s3:PutBucketCORS` action. The bucket owner has this permission by + # default and can grant this permission to others. + # + # For information about `cors`, see [Enabling Cross-Origin Resource + # Sharing][1] in the *Amazon S3 User Guide*. + # + # **Related Resources** + # + # * [PutBucketCors][2] + # + # * [RESTOPTIONSobject][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cors.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketCors.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTOPTIONSobject.html + # + # @example Example: To delete cors configuration on a bucket. + # + # # The following example deletes CORS configuration on a bucket. + # + # resp = client.delete_bucket_cors({ + # bucket: "examplebucket", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_cors({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_cors + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketCors AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3582 + def delete_bucket_cors(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This implementation of the DELETE action resets the default encryption + # for the bucket as server-side encryption with Amazon S3 managed keys + # (SSE-S3). For information about the bucket default encryption feature, + # see [Amazon S3 Bucket Default Encryption][1] in the *Amazon S3 User + # Guide*. + # + # To use this operation, you must have permissions to perform the + # `s3:PutEncryptionConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][2] and [Managing Access + # Permissions to your Amazon S3 Resources][3] in the *Amazon S3 User + # Guide*. + # + # The following operations are related to `DeleteBucketEncryption`: + # + # * [PutBucketEncryption][4] + # + # * [GetBucketEncryption][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketEncryption.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketEncryption.html + # + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_encryption({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_encryption + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketEncryption AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3641 + def delete_bucket_encryption(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes the S3 Intelligent-Tiering configuration from the specified + # bucket. + # + # The S3 Intelligent-Tiering storage class is designed to optimize + # storage costs by automatically moving data to the most cost-effective + # storage access tier, without performance impact or operational + # overhead. S3 Intelligent-Tiering delivers automatic cost savings in + # three low latency and high throughput access tiers. To get the lowest + # storage cost on data that can be accessed in minutes to hours, you can + # choose to activate additional archiving capabilities. + # + # The S3 Intelligent-Tiering storage class is the ideal storage class + # for data with unknown, changing, or unpredictable access patterns, + # independent of object size or retention period. If the size of an + # object is less than 128 KB, it is not monitored and not eligible for + # auto-tiering. Smaller objects can be stored, but they are always + # charged at the Frequent Access tier rates in the S3 + # Intelligent-Tiering storage class. + # + # For more information, see [Storage class for automatically optimizing + # frequently and infrequently accessed objects][1]. + # + # Operations related to `DeleteBucketIntelligentTieringConfiguration` + # include: + # + # * [GetBucketIntelligentTieringConfiguration][2] + # + # * [PutBucketIntelligentTieringConfiguration][3] + # + # * [ListBucketIntelligentTieringConfigurations][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html#sc-dynamic-data-access + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketIntelligentTieringConfiguration.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketIntelligentTieringConfiguration.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketIntelligentTieringConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_intelligent_tiering_configuration({ + # bucket: "BucketName", # required + # id: "IntelligentTieringId", # required + # }) + # @option params + # @option params + # @overload delete_bucket_intelligent_tiering_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketIntelligentTieringConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3708 + def delete_bucket_intelligent_tiering_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes an inventory configuration (identified by the inventory ID) + # from the bucket. + # + # To use this operation, you must have permissions to perform the + # `s3:PutInventoryConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For information about the Amazon S3 inventory feature, see [Amazon S3 + # Inventory][3]. + # + # Operations related to `DeleteBucketInventoryConfiguration` include: + # + # * [GetBucketInventoryConfiguration][4] + # + # * [PutBucketInventoryConfiguration][5] + # + # * [ListBucketInventoryConfigurations][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-inventory.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketInventoryConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketInventoryConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketInventoryConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_inventory_configuration({ + # bucket: "BucketName", # required + # id: "InventoryId", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @overload delete_bucket_inventory_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketInventoryConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3773 + def delete_bucket_inventory_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes the lifecycle configuration from the specified bucket. Amazon + # S3 removes all the lifecycle configuration rules in the lifecycle + # subresource associated with the bucket. Your objects never expire, and + # Amazon S3 no longer automatically deletes any objects on the basis of + # rules contained in the deleted lifecycle configuration. + # + # To use this operation, you must have permission to perform the + # `s3:PutLifecycleConfiguration` action. By default, the bucket owner + # has this permission and the bucket owner can grant this permission to + # others. + # + # There is usually some time lag before lifecycle configuration deletion + # is fully propagated to all the Amazon S3 systems. + # + # For more information about the object expiration, see [Elements to + # Describe Lifecycle Actions][1]. + # + # Related actions include: + # + # * [PutBucketLifecycleConfiguration][2] + # + # * [GetBucketLifecycleConfiguration][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/intro-lifecycle-rules.html#intro-lifecycle-rules-actions + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycleConfiguration.html + # + # @example Example: To delete lifecycle configuration on a bucket. + # + # # The following example deletes lifecycle configuration on a bucket. + # + # resp = client.delete_bucket_lifecycle({ + # bucket: "examplebucket", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_lifecycle({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_lifecycle + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketLifecycle AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3841 + def delete_bucket_lifecycle(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes a metrics configuration for the Amazon CloudWatch request + # metrics (specified by the metrics configuration ID) from the bucket. + # Note that this doesn't include the daily storage metrics. + # + # To use this operation, you must have permissions to perform the + # `s3:PutMetricsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For information about CloudWatch request metrics for Amazon S3, see + # [Monitoring Metrics with Amazon CloudWatch][3]. + # + # The following operations are related to + # `DeleteBucketMetricsConfiguration`: + # + # * [GetBucketMetricsConfiguration][4] + # + # * [PutBucketMetricsConfiguration][5] + # + # * [ListBucketMetricsConfigurations][6] + # + # * [Monitoring Metrics with Amazon CloudWatch][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cloudwatch-monitoring.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketMetricsConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketMetricsConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketMetricsConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_metrics_configuration({ + # bucket: "BucketName", # required + # id: "MetricsId", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @overload delete_bucket_metrics_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketMetricsConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3911 + def delete_bucket_metrics_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Removes `OwnershipControls` for an Amazon S3 bucket. To use this + # operation, you must have the `s3:PutBucketOwnershipControls` + # permission. For more information about Amazon S3 permissions, see + # [Specifying Permissions in a Policy][1]. + # + # For information about Amazon S3 Object Ownership, see [Using Object + # Ownership][2]. + # + # The following operations are related to + # `DeleteBucketOwnershipControls`: + # + # * GetBucketOwnershipControls + # + # * PutBucketOwnershipControls + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/about-object-ownership.html + # + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_ownership_controls({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_ownership_controls + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketOwnershipControls AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#3961 + def delete_bucket_ownership_controls(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Deletes the policy of a specified bucket. + # + # Directory buckets - For directory buckets, you must make + # requests for this API operation to the Regional endpoint. These + # endpoints support path-style requests in the format + # `https://s3express-control.region_code.amazonaws.com/bucket-name `. + # Virtual-hosted-style requests aren't supported. For more information, + # see [Regional and Zonal endpoints][1] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # + # : If you are using an identity other than the root user of the Amazon + # Web Services account that owns the bucket, the calling identity must + # both have the `DeleteBucketPolicy` permissions on the specified + # bucket and belong to the bucket owner's account in order to use + # this operation. + # + # If you don't have `DeleteBucketPolicy` permissions, Amazon S3 + # returns a `403 Access Denied` error. If you have the correct + # permissions, but you're not using an identity that belongs to the + # bucket owner's account, Amazon S3 returns a `405 Method Not + # Allowed` error. + # + # To ensure that bucket owners don't inadvertently lock themselves + # out of their own buckets, the root principal in a bucket owner's + # Amazon Web Services account can perform the `GetBucketPolicy`, + # `PutBucketPolicy`, and `DeleteBucketPolicy` API actions, even if + # their bucket policy explicitly denies the root principal's access. + # Bucket owner root principals can only be blocked from performing + # these API actions by VPC endpoint policies and Amazon Web Services + # Organizations policies. + # + # * **General purpose bucket permissions** - The + # `s3:DeleteBucketPolicy` permission is required in a policy. For + # more information about general purpose buckets bucket policies, + # see [Using Bucket Policies and User Policies][2] in the *Amazon S3 + # User Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation, you must have the `s3express:DeleteBucketPolicy` + # permission in an IAM identity-based policy instead of a bucket + # policy. Cross-account access to this API operation isn't + # supported. This operation can only be performed by the Amazon Web + # Services account that owns the resource. For more information + # about directory bucket policies and permissions, see [Amazon Web + # Services Identity and Access Management (IAM) for S3 Express One + # Zone][3] in the *Amazon S3 User Guide*. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is + # `s3express-control.region.amazonaws.com`. + # + # The following operations are related to `DeleteBucketPolicy` + # + # * [CreateBucket][4] + # + # * [DeleteObject][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-iam-policies.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObject.html + # + # @example Example: To delete bucket policy + # + # # The following example deletes bucket policy on the specified bucket. + # + # resp = client.delete_bucket_policy({ + # bucket: "examplebucket", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_policy({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_policy + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketPolicy AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#4085 + def delete_bucket_policy(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes the replication configuration from the bucket. + # + # To use this operation, you must have permissions to perform the + # `s3:PutReplicationConfiguration` action. The bucket owner has these + # permissions by default and can grant it to others. For more + # information about permissions, see [Permissions Related to Bucket + # Subresource Operations][1] and [Managing Access Permissions to Your + # Amazon S3 Resources][2]. + # + # It can take a while for the deletion of a replication configuration to + # fully propagate. + # + # + # + # For information about replication configuration, see [Replication][3] + # in the *Amazon S3 User Guide*. + # + # The following operations are related to `DeleteBucketReplication`: + # + # * [PutBucketReplication][4] + # + # * [GetBucketReplication][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketReplication.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketReplication.html + # + # @example Example: To delete bucket replication configuration + # + # # The following example deletes replication configuration set on bucket. + # + # resp = client.delete_bucket_replication({ + # bucket: "example", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_replication({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_replication + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketReplication AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#4155 + def delete_bucket_replication(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Deletes the tags from the bucket. + # + # To use this operation, you must have permission to perform the + # `s3:PutBucketTagging` action. By default, the bucket owner has this + # permission and can grant this permission to others. + # + # The following operations are related to `DeleteBucketTagging`: + # + # * [GetBucketTagging][1] + # + # * [PutBucketTagging][2] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketTagging.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketTagging.html + # + # @example Example: To delete bucket tags + # + # # The following example deletes bucket tags. + # + # resp = client.delete_bucket_tagging({ + # bucket: "examplebucket", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_tagging({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_tagging + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketTagging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#4211 + def delete_bucket_tagging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This action removes the website configuration for a bucket. Amazon S3 + # returns a `200 OK` response upon successfully deleting a website + # configuration on the specified bucket. You will get a `200 OK` + # response if the website configuration you are trying to delete does + # not exist on the bucket. Amazon S3 returns a `404` response if the + # bucket specified in the request does not exist. + # + # This DELETE action requires the `S3:DeleteBucketWebsite` permission. + # By default, only the bucket owner can delete the website configuration + # attached to a bucket. However, bucket owners can grant other users + # permission to delete the website configuration by writing a bucket + # policy granting them the `S3:DeleteBucketWebsite` permission. + # + # For more information about hosting websites, see [Hosting Websites on + # Amazon S3][1]. + # + # The following operations are related to `DeleteBucketWebsite`: + # + # * [GetBucketWebsite][2] + # + # * [PutBucketWebsite][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketWebsite.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketWebsite.html + # + # @example Example: To delete bucket website configuration + # + # # The following example deletes bucket website configuration. + # + # resp = client.delete_bucket_website({ + # bucket: "examplebucket", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_bucket_website({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_bucket_website + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketWebsite AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#4279 + def delete_bucket_website(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Removes an object from a bucket. The behavior depends on the bucket's + # versioning state: + # + # * If bucket versioning is not enabled, the operation permanently + # deletes the object. + # + # * If bucket versioning is enabled, the operation inserts a delete + # marker, which becomes the current version of the object. To + # permanently delete an object in a versioned bucket, you must include + # the object’s `versionId` in the request. For more information about + # versioning-enabled buckets, see [Deleting object versions from a + # versioning-enabled bucket][1]. + # + # * If bucket versioning is suspended, the operation removes the object + # that has a null `versionId`, if there is one, and inserts a delete + # marker that becomes the current version of the object. If there + # isn't an object with a null `versionId`, and all versions of the + # object have a `versionId`, Amazon S3 does not remove the object and + # only inserts a delete marker. To permanently delete an object that + # has a `versionId`, you must include the object’s `versionId` in the + # request. For more information about versioning-suspended buckets, + # see [Deleting objects from versioning-suspended buckets][2]. + # + # * **Directory buckets** - S3 Versioning isn't enabled and supported + # for directory buckets. For this API operation, only the `null` value + # of the version ID is supported by directory buckets. You can only + # specify `null` to the `versionId` query parameter in the request. + # + # * **Directory buckets** - For directory buckets, you must make + # requests for this API operation to the Zonal endpoint. These + # endpoints support virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name + # `. Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][3] in the *Amazon S3 User Guide*. + # + # + # + # To remove a specific version, you must use the `versionId` query + # parameter. Using this query parameter permanently deletes the version. + # If the object deleted is a delete marker, Amazon S3 sets the response + # header `x-amz-delete-marker` to true. + # + # If the object you want to delete is in a bucket where the bucket + # versioning configuration is MFA Delete enabled, you must include the + # `x-amz-mfa` request header in the DELETE `versionId` request. Requests + # that include `x-amz-mfa` must use HTTPS. For more information about + # MFA Delete, see [Using MFA Delete][4] in the *Amazon S3 User Guide*. + # To see sample requests that use versioning, see [Sample Request][5]. + # + # **Directory buckets** - MFA delete is not supported by directory + # buckets. + # + # + # + # You can delete objects by explicitly calling DELETE Object or calling + # ([PutBucketLifecycle][6]) to enable Amazon S3 to remove them for you. + # If you want to block users or accounts from removing or deleting + # objects from your bucket, you must deny them the `s3:DeleteObject`, + # `s3:DeleteObjectVersion`, and `s3:PutLifeCycleConfiguration` actions. + # + # **Directory buckets** - S3 Lifecycle is not supported by directory + # buckets. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - The following permissions + # are required in your policies when your `DeleteObjects` request + # includes specific headers. + # + # * s3:DeleteObject - To delete an object from + # a bucket, you must always have the `s3:DeleteObject` permission. + # + # * s3:DeleteObjectVersion - To delete a + # specific version of an object from a versioning-enabled bucket, + # you must have the `s3:DeleteObjectVersion` permission. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][7] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][7]. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following action is related to `DeleteObject`: + # + # * [PutObject][8] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/DeletingObjectVersions.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/DeletingObjectsfromVersioningSuspendedBuckets.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingMFADelete.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTObjectDELETE.html#ExampleVersionObjectDelete + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycle.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # + # @example Example: To delete an object + # + # # The following example deletes an object from an S3 bucket. + # + # resp = client.delete_object({ + # bucket: "examplebucket", + # key: "objectkey.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Example: To delete an object (from a non-versioned bucket) + # + # # The following example deletes an object from a non-versioned bucket. + # + # resp = client.delete_object({ + # bucket: "ExampleBucket", + # key: "HappyFace.jpg", + # }) + # @example Request syntax with placeholder values + # + # resp = client.delete_object({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # mfa: "MFA", + # version_id: "ObjectVersionId", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.delete_marker #=> Boolean + # resp.version_id #=> String + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload delete_object + # @param params [Hash] ({}) + # @return [Types::DeleteObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DeleteObjectOutput#delete_marker #delete_marker} => Boolean + # * {Types::DeleteObjectOutput#version_id #version_id} => String + # * {Types::DeleteObjectOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObject AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#4545 + def delete_object(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Removes the entire tag set from the specified object. For more + # information about managing object tags, see [ Object Tagging][1]. + # + # To use this operation, you must have permission to perform the + # `s3:DeleteObjectTagging` action. + # + # To delete tags of a specific object version, add the `versionId` query + # parameter in the request. You will need permission for the + # `s3:DeleteObjectVersionTagging` action. + # + # The following operations are related to `DeleteObjectTagging`: + # + # * [PutObjectTagging][2] + # + # * [GetObjectTagging][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-tagging.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObjectTagging.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectTagging.html + # + # @example Example: To remove tag set from an object version + # + # # The following example removes tag set associated with the specified object version. The request specifies both the + # # object key and object version. + # + # resp = client.delete_object_tagging({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI", + # }) + # + # resp.to_h outputs the following: + # { + # version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI", + # } + # @example Example: To remove tag set from an object + # + # # The following example removes tag set associated with the specified object. If the bucket is versioning enabled, the + # # operation removes tag set from the latest object version. + # + # resp = client.delete_object_tagging({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # version_id: "null", + # } + # @example Request syntax with placeholder values + # + # resp = client.delete_object_tagging({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.version_id #=> String + # @option params + # @option params + # @option params + # @option params + # @overload delete_object_tagging + # @param params [Hash] ({}) + # @return [Types::DeleteObjectTaggingOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DeleteObjectTaggingOutput#version_id #version_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectTagging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#4669 + def delete_object_tagging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation enables you to delete multiple objects from a bucket + # using a single HTTP request. If you know the object keys that you want + # to delete, then this operation provides a suitable alternative to + # sending individual delete requests, reducing per-request overhead. + # + # The request can contain a list of up to 1000 keys that you want to + # delete. In the XML, you provide the object key names, and optionally, + # version IDs if you want to delete a specific version of the object + # from a versioning-enabled bucket. For each key, Amazon S3 performs a + # delete operation and returns the result of that delete, success or + # failure, in the response. Note that if the object specified in the + # request is not found, Amazon S3 returns the result as deleted. + # + # * **Directory buckets** - S3 Versioning isn't enabled and supported + # for directory buckets. + # + # * **Directory buckets** - For directory buckets, you must make + # requests for this API operation to the Zonal endpoint. These + # endpoints support virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name + # `. Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][1] in the *Amazon S3 User Guide*. + # + # + # + # The operation supports two modes for the response: verbose and quiet. + # By default, the operation uses verbose mode in which the response + # includes the result of deletion of each key in your request. In quiet + # mode the response includes only keys where the delete operation + # encountered an error. For a successful deletion in a quiet mode, the + # operation does not return any information about the delete in the + # response body. + # + # When performing this action on an MFA Delete enabled bucket, that + # attempts to delete any versioned objects, you must include an MFA + # token. If you do not provide one, the entire request will fail, even + # if there are non-versioned objects you are trying to delete. If you + # provide an invalid token, whether there are versioned keys in the + # request or not, the entire Multi-Object Delete request will fail. For + # information about MFA Delete, see [MFA Delete][2] in the *Amazon S3 + # User Guide*. + # + # **Directory buckets** - MFA delete is not supported by directory + # buckets. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - The following permissions + # are required in your policies when your `DeleteObjects` request + # includes specific headers. + # + # * s3:DeleteObject - To delete an object from + # a bucket, you must always specify the `s3:DeleteObject` + # permission. + # + # * s3:DeleteObjectVersion - To delete a + # specific version of an object from a versioning-enabled bucket, + # you must specify the `s3:DeleteObjectVersion` permission. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][3] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][3]. + # + # Content-MD5 request header + # : * **General purpose bucket** - The Content-MD5 request header is + # required for all Multi-Object Delete requests. Amazon S3 uses the + # header value to ensure that your request body has not been altered + # in transit. + # + # * **Directory bucket** - The Content-MD5 request header or a + # additional checksum request header (including + # `x-amz-checksum-crc32`, `x-amz-checksum-crc32c`, + # `x-amz-checksum-sha1`, or `x-amz-checksum-sha256`) is required for + # all Multi-Object Delete requests. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `DeleteObjects`: + # + # * [CreateMultipartUpload][4] + # + # * [UploadPart][5] + # + # * [CompleteMultipartUpload][6] + # + # * [ListParts][7] + # + # * [AbortMultipartUpload][8] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/Versioning.html#MultiFactorAuthenticationDelete + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html + # + # @example Example: To delete multiple objects from a versioned bucket + # + # # The following example deletes objects from a bucket. The bucket is versioned, and the request does not specify the + # # object version to delete. In this case, all versions remain in the bucket and S3 adds a delete marker. + # + # resp = client.delete_objects({ + # bucket: "examplebucket", + # delete: { + # objects: [ + # { + # key: "objectkey1", + # }, + # { + # key: "objectkey2", + # }, + # ], + # quiet: false, + # }, + # }) + # + # resp.to_h outputs the following: + # { + # deleted: [ + # { + # delete_marker: true, + # delete_marker_version_id: "A._w1z6EFiCF5uhtQMDal9JDkID9tQ7F", + # key: "objectkey1", + # }, + # { + # delete_marker: true, + # delete_marker_version_id: "iOd_ORxhkKe_e8G8_oSGxt2PjsCZKlkt", + # key: "objectkey2", + # }, + # ], + # } + # @example Example: To delete multiple object versions from a versioned bucket + # + # # The following example deletes objects from a bucket. The request specifies object versions. S3 deletes specific object + # # versions and returns the key and versions of deleted objects in the response. + # + # resp = client.delete_objects({ + # bucket: "examplebucket", + # delete: { + # objects: [ + # { + # key: "HappyFace.jpg", + # version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b", + # }, + # { + # key: "HappyFace.jpg", + # version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd", + # }, + # ], + # quiet: false, + # }, + # }) + # + # resp.to_h outputs the following: + # { + # deleted: [ + # { + # key: "HappyFace.jpg", + # version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd", + # }, + # { + # key: "HappyFace.jpg", + # version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b", + # }, + # ], + # } + # @example Request syntax with placeholder values + # + # resp = client.delete_objects({ + # bucket: "BucketName", # required + # delete: { # required + # objects: [ # required + # { + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # }, + # ], + # quiet: false, + # }, + # mfa: "MFA", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @example Response structure + # + # resp.deleted #=> Array + # resp.deleted[0].key #=> String + # resp.deleted[0].version_id #=> String + # resp.deleted[0].delete_marker #=> Boolean + # resp.deleted[0].delete_marker_version_id #=> String + # resp.request_charged #=> String, one of "requester" + # resp.errors #=> Array + # resp.errors[0].key #=> String + # resp.errors[0].version_id #=> String + # resp.errors[0].code #=> String + # resp.errors[0].message #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload delete_objects + # @param params [Hash] ({}) + # @return [Types::DeleteObjectsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::DeleteObjectsOutput#deleted #deleted} => Array<Types::DeletedObject> + # * {Types::DeleteObjectsOutput#request_charged #request_charged} => String + # * {Types::DeleteObjectsOutput#errors #errors} => Array<Types::Error> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjects AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5042 + def delete_objects(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Removes the `PublicAccessBlock` configuration for an Amazon S3 bucket. + # To use this operation, you must have the + # `s3:PutBucketPublicAccessBlock` permission. For more information about + # permissions, see [Permissions Related to Bucket Subresource + # Operations][1] and [Managing Access Permissions to Your Amazon S3 + # Resources][2]. + # + # The following operations are related to `DeletePublicAccessBlock`: + # + # * [Using Amazon S3 Block Public Access][3] + # + # * [GetPublicAccessBlock][4] + # + # * [PutPublicAccessBlock][5] + # + # * [GetBucketPolicyStatus][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetPublicAccessBlock.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutPublicAccessBlock.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketPolicyStatus.html + # + # @example Request syntax with placeholder values + # + # resp = client.delete_public_access_block({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @overload delete_public_access_block + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeletePublicAccessBlock AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5099 + def delete_public_access_block(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This implementation of the GET action uses the `accelerate` + # subresource to return the Transfer Acceleration state of a bucket, + # which is either `Enabled` or `Suspended`. Amazon S3 Transfer + # Acceleration is a bucket-level feature that enables you to perform + # faster data transfers to and from Amazon S3. + # + # To use this operation, you must have permission to perform the + # `s3:GetAccelerateConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to your Amazon S3 Resources][2] in the *Amazon S3 User + # Guide*. + # + # You set the Transfer Acceleration state of an existing bucket to + # `Enabled` or `Suspended` by using the + # [PutBucketAccelerateConfiguration][3] operation. + # + # A GET `accelerate` request does not return a state value for a bucket + # that has no transfer acceleration state. A bucket has no Transfer + # Acceleration state if a state has never been set on the bucket. + # + # For more information about transfer acceleration, see [Transfer + # Acceleration][4] in the Amazon S3 User Guide. + # + # The following operations are related to + # `GetBucketAccelerateConfiguration`: + # + # * [PutBucketAccelerateConfiguration][3] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketAccelerateConfiguration.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acceleration.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_accelerate_configuration({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # request_payer: "requester", # accepts requester + # }) + # @example Response structure + # + # resp.status #=> String, one of "Enabled", "Suspended" + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @overload get_bucket_accelerate_configuration + # @param params [Hash] ({}) + # @return [Types::GetBucketAccelerateConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketAccelerateConfigurationOutput#status #status} => String + # * {Types::GetBucketAccelerateConfigurationOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAccelerateConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5195 + def get_bucket_accelerate_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This implementation of the `GET` action uses the `acl` subresource to + # return the access control list (ACL) of a bucket. To use `GET` to + # return the ACL of the bucket, you must have the `READ_ACP` access to + # the bucket. If `READ_ACP` permission is granted to the anonymous user, + # you can return the ACL of the bucket without using an authorization + # header. + # + # When you use this API operation with an access point, provide the + # alias of the access point in place of the bucket name. + # + # When you use this API operation with an Object Lambda access point, + # provide the alias of the Object Lambda access point in place of the + # bucket name. If the Object Lambda access point alias in a request is + # not valid, the error code `InvalidAccessPointAliasError` is returned. + # For more information about `InvalidAccessPointAliasError`, see [List + # of Error Codes][1]. + # + # If your bucket uses the bucket owner enforced setting for S3 Object + # Ownership, requests to read ACLs are still supported and return the + # `bucket-owner-full-control` ACL with the owner being the account that + # created the bucket. For more information, see [ Controlling object + # ownership and disabling ACLs][2] in the *Amazon S3 User Guide*. + # + # + # + # The following operations are related to `GetBucketAcl`: + # + # * [ListObjects][3] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#ErrorCodeList + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjects.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_acl({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.owner.display_name #=> String + # resp.owner.id #=> String + # resp.grants #=> Array + # resp.grants[0].grantee.display_name #=> String + # resp.grants[0].grantee.email_address #=> String + # resp.grants[0].grantee.id #=> String + # resp.grants[0].grantee.type #=> String, one of "CanonicalUser", "AmazonCustomerByEmail", "Group" + # resp.grants[0].grantee.uri #=> String + # resp.grants[0].permission #=> String, one of "FULL_CONTROL", "WRITE", "WRITE_ACP", "READ", "READ_ACP" + # @option params + # @option params + # @overload get_bucket_acl + # @param params [Hash] ({}) + # @return [Types::GetBucketAclOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketAclOutput#owner #owner} => Types::Owner + # * {Types::GetBucketAclOutput#grants #grants} => Array<Types::Grant> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAcl AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5291 + def get_bucket_acl(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This implementation of the GET action returns an analytics + # configuration (identified by the analytics configuration ID) from the + # bucket. + # + # To use this operation, you must have permissions to perform the + # `s3:GetAnalyticsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [ Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2] in the *Amazon S3 User + # Guide*. + # + # For information about Amazon S3 analytics feature, see [Amazon S3 + # Analytics – Storage Class Analysis][3] in the *Amazon S3 User Guide*. + # + # The following operations are related to + # `GetBucketAnalyticsConfiguration`: + # + # * [DeleteBucketAnalyticsConfiguration][4] + # + # * [ListBucketAnalyticsConfigurations][5] + # + # * [PutBucketAnalyticsConfiguration][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/analytics-storage-class.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketAnalyticsConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketAnalyticsConfigurations.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketAnalyticsConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_analytics_configuration({ + # bucket: "BucketName", # required + # id: "AnalyticsId", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.analytics_configuration.id #=> String + # resp.analytics_configuration.filter.prefix #=> String + # resp.analytics_configuration.filter.tag.key #=> String + # resp.analytics_configuration.filter.tag.value #=> String + # resp.analytics_configuration.filter.and.prefix #=> String + # resp.analytics_configuration.filter.and.tags #=> Array + # resp.analytics_configuration.filter.and.tags[0].key #=> String + # resp.analytics_configuration.filter.and.tags[0].value #=> String + # resp.analytics_configuration.storage_class_analysis.data_export.output_schema_version #=> String, one of "V_1" + # resp.analytics_configuration.storage_class_analysis.data_export.destination.s3_bucket_destination.format #=> String, one of "CSV" + # resp.analytics_configuration.storage_class_analysis.data_export.destination.s3_bucket_destination.bucket_account_id #=> String + # resp.analytics_configuration.storage_class_analysis.data_export.destination.s3_bucket_destination.bucket #=> String + # resp.analytics_configuration.storage_class_analysis.data_export.destination.s3_bucket_destination.prefix #=> String + # @option params + # @option params + # @option params + # @overload get_bucket_analytics_configuration + # @param params [Hash] ({}) + # @return [Types::GetBucketAnalyticsConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketAnalyticsConfigurationOutput#analytics_configuration #analytics_configuration} => Types::AnalyticsConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAnalyticsConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5377 + def get_bucket_analytics_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the Cross-Origin Resource Sharing (CORS) configuration + # information set for the bucket. + # + # To use this operation, you must have permission to perform the + # `s3:GetBucketCORS` action. By default, the bucket owner has this + # permission and can grant it to others. + # + # When you use this API operation with an access point, provide the + # alias of the access point in place of the bucket name. + # + # When you use this API operation with an Object Lambda access point, + # provide the alias of the Object Lambda access point in place of the + # bucket name. If the Object Lambda access point alias in a request is + # not valid, the error code `InvalidAccessPointAliasError` is returned. + # For more information about `InvalidAccessPointAliasError`, see [List + # of Error Codes][1]. + # + # For more information about CORS, see [ Enabling Cross-Origin Resource + # Sharing][2]. + # + # The following operations are related to `GetBucketCors`: + # + # * [PutBucketCors][3] + # + # * [DeleteBucketCors][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#ErrorCodeList + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cors.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketCors.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketCors.html + # + # @example Example: To get cors configuration set on a bucket + # + # # The following example returns cross-origin resource sharing (CORS) configuration set on a bucket. + # + # resp = client.get_bucket_cors({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # cors_rules: [ + # { + # allowed_headers: [ + # "Authorization", + # ], + # allowed_methods: [ + # "GET", + # ], + # allowed_origins: [ + # "*", + # ], + # max_age_seconds: 3000, + # }, + # ], + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_cors({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.cors_rules #=> Array + # resp.cors_rules[0].id #=> String + # resp.cors_rules[0].allowed_headers #=> Array + # resp.cors_rules[0].allowed_headers[0] #=> String + # resp.cors_rules[0].allowed_methods #=> Array + # resp.cors_rules[0].allowed_methods[0] #=> String + # resp.cors_rules[0].allowed_origins #=> Array + # resp.cors_rules[0].allowed_origins[0] #=> String + # resp.cors_rules[0].expose_headers #=> Array + # resp.cors_rules[0].expose_headers[0] #=> String + # resp.cors_rules[0].max_age_seconds #=> Integer + # @option params + # @option params + # @overload get_bucket_cors + # @param params [Hash] ({}) + # @return [Types::GetBucketCorsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketCorsOutput#cors_rules #cors_rules} => Array<Types::CORSRule> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketCors AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5497 + def get_bucket_cors(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the default encryption configuration for an Amazon S3 bucket. + # By default, all buckets have a default encryption configuration that + # uses server-side encryption with Amazon S3 managed keys (SSE-S3). For + # information about the bucket default encryption feature, see [Amazon + # S3 Bucket Default Encryption][1] in the *Amazon S3 User Guide*. + # + # To use this operation, you must have permission to perform the + # `s3:GetEncryptionConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][2] and [Managing Access + # Permissions to Your Amazon S3 Resources][3]. + # + # The following operations are related to `GetBucketEncryption`: + # + # * [PutBucketEncryption][4] + # + # * [DeleteBucketEncryption][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketEncryption.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketEncryption.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_encryption({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.server_side_encryption_configuration.rules #=> Array + # resp.server_side_encryption_configuration.rules[0].apply_server_side_encryption_by_default.sse_algorithm #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.server_side_encryption_configuration.rules[0].apply_server_side_encryption_by_default.kms_master_key_id #=> String + # resp.server_side_encryption_configuration.rules[0].bucket_key_enabled #=> Boolean + # @option params + # @option params + # @overload get_bucket_encryption + # @param params [Hash] ({}) + # @return [Types::GetBucketEncryptionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketEncryptionOutput#server_side_encryption_configuration #server_side_encryption_configuration} => Types::ServerSideEncryptionConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketEncryption AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5564 + def get_bucket_encryption(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Gets the S3 Intelligent-Tiering configuration from the specified + # bucket. + # + # The S3 Intelligent-Tiering storage class is designed to optimize + # storage costs by automatically moving data to the most cost-effective + # storage access tier, without performance impact or operational + # overhead. S3 Intelligent-Tiering delivers automatic cost savings in + # three low latency and high throughput access tiers. To get the lowest + # storage cost on data that can be accessed in minutes to hours, you can + # choose to activate additional archiving capabilities. + # + # The S3 Intelligent-Tiering storage class is the ideal storage class + # for data with unknown, changing, or unpredictable access patterns, + # independent of object size or retention period. If the size of an + # object is less than 128 KB, it is not monitored and not eligible for + # auto-tiering. Smaller objects can be stored, but they are always + # charged at the Frequent Access tier rates in the S3 + # Intelligent-Tiering storage class. + # + # For more information, see [Storage class for automatically optimizing + # frequently and infrequently accessed objects][1]. + # + # Operations related to `GetBucketIntelligentTieringConfiguration` + # include: + # + # * [DeleteBucketIntelligentTieringConfiguration][2] + # + # * [PutBucketIntelligentTieringConfiguration][3] + # + # * [ListBucketIntelligentTieringConfigurations][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html#sc-dynamic-data-access + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketIntelligentTieringConfiguration.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketIntelligentTieringConfiguration.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketIntelligentTieringConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_intelligent_tiering_configuration({ + # bucket: "BucketName", # required + # id: "IntelligentTieringId", # required + # }) + # @example Response structure + # + # resp.intelligent_tiering_configuration.id #=> String + # resp.intelligent_tiering_configuration.filter.prefix #=> String + # resp.intelligent_tiering_configuration.filter.tag.key #=> String + # resp.intelligent_tiering_configuration.filter.tag.value #=> String + # resp.intelligent_tiering_configuration.filter.and.prefix #=> String + # resp.intelligent_tiering_configuration.filter.and.tags #=> Array + # resp.intelligent_tiering_configuration.filter.and.tags[0].key #=> String + # resp.intelligent_tiering_configuration.filter.and.tags[0].value #=> String + # resp.intelligent_tiering_configuration.status #=> String, one of "Enabled", "Disabled" + # resp.intelligent_tiering_configuration.tierings #=> Array + # resp.intelligent_tiering_configuration.tierings[0].days #=> Integer + # resp.intelligent_tiering_configuration.tierings[0].access_tier #=> String, one of "ARCHIVE_ACCESS", "DEEP_ARCHIVE_ACCESS" + # @option params + # @option params + # @overload get_bucket_intelligent_tiering_configuration + # @param params [Hash] ({}) + # @return [Types::GetBucketIntelligentTieringConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketIntelligentTieringConfigurationOutput#intelligent_tiering_configuration #intelligent_tiering_configuration} => Types::IntelligentTieringConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketIntelligentTieringConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5648 + def get_bucket_intelligent_tiering_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns an inventory configuration (identified by the inventory + # configuration ID) from the bucket. + # + # To use this operation, you must have permissions to perform the + # `s3:GetInventoryConfiguration` action. The bucket owner has this + # permission by default and can grant this permission to others. For + # more information about permissions, see [Permissions Related to Bucket + # Subresource Operations][1] and [Managing Access Permissions to Your + # Amazon S3 Resources][2]. + # + # For information about the Amazon S3 inventory feature, see [Amazon S3 + # Inventory][3]. + # + # The following operations are related to + # `GetBucketInventoryConfiguration`: + # + # * [DeleteBucketInventoryConfiguration][4] + # + # * [ListBucketInventoryConfigurations][5] + # + # * [PutBucketInventoryConfiguration][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-inventory.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketInventoryConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketInventoryConfigurations.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketInventoryConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_inventory_configuration({ + # bucket: "BucketName", # required + # id: "InventoryId", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.inventory_configuration.destination.s3_bucket_destination.account_id #=> String + # resp.inventory_configuration.destination.s3_bucket_destination.bucket #=> String + # resp.inventory_configuration.destination.s3_bucket_destination.format #=> String, one of "CSV", "ORC", "Parquet" + # resp.inventory_configuration.destination.s3_bucket_destination.prefix #=> String + # resp.inventory_configuration.destination.s3_bucket_destination.encryption.ssekms.key_id #=> String + # resp.inventory_configuration.is_enabled #=> Boolean + # resp.inventory_configuration.filter.prefix #=> String + # resp.inventory_configuration.id #=> String + # resp.inventory_configuration.included_object_versions #=> String, one of "All", "Current" + # resp.inventory_configuration.optional_fields #=> Array + # resp.inventory_configuration.optional_fields[0] #=> String, one of "Size", "LastModifiedDate", "StorageClass", "ETag", "IsMultipartUploaded", "ReplicationStatus", "EncryptionStatus", "ObjectLockRetainUntilDate", "ObjectLockMode", "ObjectLockLegalHoldStatus", "IntelligentTieringAccessTier", "BucketKeyStatus", "ChecksumAlgorithm", "ObjectAccessControlList", "ObjectOwner" + # resp.inventory_configuration.schedule.frequency #=> String, one of "Daily", "Weekly" + # @option params + # @option params + # @option params + # @overload get_bucket_inventory_configuration + # @param params [Hash] ({}) + # @return [Types::GetBucketInventoryConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketInventoryConfigurationOutput#inventory_configuration #inventory_configuration} => Types::InventoryConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketInventoryConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5731 + def get_bucket_inventory_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # For an updated version of this API, see + # [GetBucketLifecycleConfiguration][1]. If you configured a bucket + # lifecycle using the `filter` element, you should see the updated + # version of this topic. This topic is provided for backward + # compatibility. + # + # This operation is not supported by directory buckets. + # + # + # + # Returns the lifecycle configuration information set on the bucket. For + # information about lifecycle configuration, see [Object Lifecycle + # Management][2]. + # + # To use this operation, you must have permission to perform the + # `s3:GetLifecycleConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][3] and [Managing Access + # Permissions to Your Amazon S3 Resources][4]. + # + # `GetBucketLifecycle` has the following special error: + # + # * Error code: `NoSuchLifecycleConfiguration` + # + # * Description: The lifecycle configuration does not exist. + # + # * HTTP Status Code: 404 Not Found + # + # * SOAP Fault Code Prefix: Client + # + # The following operations are related to `GetBucketLifecycle`: + # + # * [GetBucketLifecycleConfiguration][1] + # + # * [PutBucketLifecycle][5] + # + # * [DeleteBucketLifecycle][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycleConfiguration.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycle.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketLifecycle.html + # + # @example Example: To get a bucket acl + # + # # The following example gets ACL on the specified bucket. + # + # resp = client.get_bucket_lifecycle({ + # bucket: "acl1", + # }) + # + # resp.to_h outputs the following: + # { + # rules: [ + # { + # expiration: { + # days: 1, + # }, + # id: "delete logs", + # prefix: "123/", + # status: "Enabled", + # }, + # ], + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_lifecycle({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.rules #=> Array + # resp.rules[0].expiration.date #=> Time + # resp.rules[0].expiration.days #=> Integer + # resp.rules[0].expiration.expired_object_delete_marker #=> Boolean + # resp.rules[0].id #=> String + # resp.rules[0].prefix #=> String + # resp.rules[0].status #=> String, one of "Enabled", "Disabled" + # resp.rules[0].transition.date #=> Time + # resp.rules[0].transition.days #=> Integer + # resp.rules[0].transition.storage_class #=> String, one of "GLACIER", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "DEEP_ARCHIVE", "GLACIER_IR" + # resp.rules[0].noncurrent_version_transition.noncurrent_days #=> Integer + # resp.rules[0].noncurrent_version_transition.storage_class #=> String, one of "GLACIER", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "DEEP_ARCHIVE", "GLACIER_IR" + # resp.rules[0].noncurrent_version_transition.newer_noncurrent_versions #=> Integer + # resp.rules[0].noncurrent_version_expiration.noncurrent_days #=> Integer + # resp.rules[0].noncurrent_version_expiration.newer_noncurrent_versions #=> Integer + # resp.rules[0].abort_incomplete_multipart_upload.days_after_initiation #=> Integer + # @option params + # @option params + # @overload get_bucket_lifecycle + # @param params [Hash] ({}) + # @return [Types::GetBucketLifecycleOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketLifecycleOutput#rules #rules} => Array<Types::Rule> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycle AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5849 + def get_bucket_lifecycle(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Bucket lifecycle configuration now supports specifying a lifecycle + # rule using an object key name prefix, one or more object tags, object + # size, or any combination of these. Accordingly, this section describes + # the latest API. The previous version of the API supported filtering + # based only on an object key name prefix, which is supported for + # backward compatibility. For the related API description, see + # [GetBucketLifecycle][1]. Accordingly, this section describes the + # latest API. The response describes the new filter element that you can + # use to specify a filter to select a subset of objects to which the + # rule applies. If you are using a previous version of the lifecycle + # configuration, it still works. For the earlier action, + # + # + # + # Returns the lifecycle configuration information set on the bucket. For + # information about lifecycle configuration, see [Object Lifecycle + # Management][2]. + # + # To use this operation, you must have permission to perform the + # `s3:GetLifecycleConfiguration` action. The bucket owner has this + # permission, by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][3] and [Managing Access + # Permissions to Your Amazon S3 Resources][4]. + # + # `GetBucketLifecycleConfiguration` has the following special error: + # + # * Error code: `NoSuchLifecycleConfiguration` + # + # * Description: The lifecycle configuration does not exist. + # + # * HTTP Status Code: 404 Not Found + # + # * SOAP Fault Code Prefix: Client + # + # The following operations are related to + # `GetBucketLifecycleConfiguration`: + # + # * [GetBucketLifecycle][1] + # + # * [PutBucketLifecycle][5] + # + # * [DeleteBucketLifecycle][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycle.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycle.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketLifecycle.html + # + # @example Example: To get lifecycle configuration on a bucket + # + # # The following example retrieves lifecycle configuration on set on a bucket. + # + # resp = client.get_bucket_lifecycle_configuration({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # rules: [ + # { + # id: "Rule for TaxDocs/", + # prefix: "TaxDocs", + # status: "Enabled", + # transitions: [ + # { + # days: 365, + # storage_class: "STANDARD_IA", + # }, + # ], + # }, + # ], + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_lifecycle_configuration({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.rules #=> Array + # resp.rules[0].expiration.date #=> Time + # resp.rules[0].expiration.days #=> Integer + # resp.rules[0].expiration.expired_object_delete_marker #=> Boolean + # resp.rules[0].id #=> String + # resp.rules[0].prefix #=> String + # resp.rules[0].filter.prefix #=> String + # resp.rules[0].filter.tag.key #=> String + # resp.rules[0].filter.tag.value #=> String + # resp.rules[0].filter.object_size_greater_than #=> Integer + # resp.rules[0].filter.object_size_less_than #=> Integer + # resp.rules[0].filter.and.prefix #=> String + # resp.rules[0].filter.and.tags #=> Array + # resp.rules[0].filter.and.tags[0].key #=> String + # resp.rules[0].filter.and.tags[0].value #=> String + # resp.rules[0].filter.and.object_size_greater_than #=> Integer + # resp.rules[0].filter.and.object_size_less_than #=> Integer + # resp.rules[0].status #=> String, one of "Enabled", "Disabled" + # resp.rules[0].transitions #=> Array + # resp.rules[0].transitions[0].date #=> Time + # resp.rules[0].transitions[0].days #=> Integer + # resp.rules[0].transitions[0].storage_class #=> String, one of "GLACIER", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "DEEP_ARCHIVE", "GLACIER_IR" + # resp.rules[0].noncurrent_version_transitions #=> Array + # resp.rules[0].noncurrent_version_transitions[0].noncurrent_days #=> Integer + # resp.rules[0].noncurrent_version_transitions[0].storage_class #=> String, one of "GLACIER", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "DEEP_ARCHIVE", "GLACIER_IR" + # resp.rules[0].noncurrent_version_transitions[0].newer_noncurrent_versions #=> Integer + # resp.rules[0].noncurrent_version_expiration.noncurrent_days #=> Integer + # resp.rules[0].noncurrent_version_expiration.newer_noncurrent_versions #=> Integer + # resp.rules[0].abort_incomplete_multipart_upload.days_after_initiation #=> Integer + # @option params + # @option params + # @overload get_bucket_lifecycle_configuration + # @param params [Hash] ({}) + # @return [Types::GetBucketLifecycleConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketLifecycleConfigurationOutput#rules #rules} => Array<Types::LifecycleRule> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#5992 + def get_bucket_lifecycle_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the Region the bucket resides in. You set the bucket's Region + # using the `LocationConstraint` request parameter in a `CreateBucket` + # request. For more information, see [CreateBucket][1]. + # + # When you use this API operation with an access point, provide the + # alias of the access point in place of the bucket name. + # + # When you use this API operation with an Object Lambda access point, + # provide the alias of the Object Lambda access point in place of the + # bucket name. If the Object Lambda access point alias in a request is + # not valid, the error code `InvalidAccessPointAliasError` is returned. + # For more information about `InvalidAccessPointAliasError`, see [List + # of Error Codes][2]. + # + # We recommend that you use [HeadBucket][3] to return the Region that a + # bucket resides in. For backward compatibility, Amazon S3 continues to + # support GetBucketLocation. + # + # + # + # The following operations are related to `GetBucketLocation`: + # + # * [GetObject][4] + # + # * [CreateBucket][1] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#ErrorCodeList + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_HeadBucket.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # + # @example Example: To get bucket location + # + # # The following example returns bucket location. + # + # resp = client.get_bucket_location({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # location_constraint: "us-west-2", + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_location({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.location_constraint #=> String, one of "af-south-1", "ap-east-1", "ap-northeast-1", "ap-northeast-2", "ap-northeast-3", "ap-south-1", "ap-south-2", "ap-southeast-1", "ap-southeast-2", "ap-southeast-3", "ca-central-1", "cn-north-1", "cn-northwest-1", "EU", "eu-central-1", "eu-north-1", "eu-south-1", "eu-south-2", "eu-west-1", "eu-west-2", "eu-west-3", "me-south-1", "sa-east-1", "us-east-2", "us-gov-east-1", "us-gov-west-1", "us-west-1", "us-west-2" + # @option params + # @option params + # @overload get_bucket_location + # @param params [Hash] ({}) + # @return [Types::GetBucketLocationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketLocationOutput#location_constraint #location_constraint} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocation AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6089 + def get_bucket_location(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the logging status of a bucket and the permissions users have + # to view and modify that status. + # + # The following operations are related to `GetBucketLogging`: + # + # * [CreateBucket][1] + # + # * [PutBucketLogging][2] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLogging.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_logging({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.logging_enabled.target_bucket #=> String + # resp.logging_enabled.target_grants #=> Array + # resp.logging_enabled.target_grants[0].grantee.display_name #=> String + # resp.logging_enabled.target_grants[0].grantee.email_address #=> String + # resp.logging_enabled.target_grants[0].grantee.id #=> String + # resp.logging_enabled.target_grants[0].grantee.type #=> String, one of "CanonicalUser", "AmazonCustomerByEmail", "Group" + # resp.logging_enabled.target_grants[0].grantee.uri #=> String + # resp.logging_enabled.target_grants[0].permission #=> String, one of "FULL_CONTROL", "READ", "WRITE" + # resp.logging_enabled.target_prefix #=> String + # resp.logging_enabled.target_object_key_format.partitioned_prefix.partition_date_source #=> String, one of "EventTime", "DeliveryTime" + # @option params + # @option params + # @overload get_bucket_logging + # @param params [Hash] ({}) + # @return [Types::GetBucketLoggingOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketLoggingOutput#logging_enabled #logging_enabled} => Types::LoggingEnabled + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLogging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6148 + def get_bucket_logging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Gets a metrics configuration (specified by the metrics configuration + # ID) from the bucket. Note that this doesn't include the daily storage + # metrics. + # + # To use this operation, you must have permissions to perform the + # `s3:GetMetricsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For information about CloudWatch request metrics for Amazon S3, see + # [Monitoring Metrics with Amazon CloudWatch][3]. + # + # The following operations are related to + # `GetBucketMetricsConfiguration`: + # + # * [PutBucketMetricsConfiguration][4] + # + # * [DeleteBucketMetricsConfiguration][5] + # + # * [ListBucketMetricsConfigurations][6] + # + # * [Monitoring Metrics with Amazon CloudWatch][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cloudwatch-monitoring.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketMetricsConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketMetricsConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketMetricsConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_metrics_configuration({ + # bucket: "BucketName", # required + # id: "MetricsId", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.metrics_configuration.id #=> String + # resp.metrics_configuration.filter.prefix #=> String + # resp.metrics_configuration.filter.tag.key #=> String + # resp.metrics_configuration.filter.tag.value #=> String + # resp.metrics_configuration.filter.access_point_arn #=> String + # resp.metrics_configuration.filter.and.prefix #=> String + # resp.metrics_configuration.filter.and.tags #=> Array + # resp.metrics_configuration.filter.and.tags[0].key #=> String + # resp.metrics_configuration.filter.and.tags[0].value #=> String + # resp.metrics_configuration.filter.and.access_point_arn #=> String + # @option params + # @option params + # @option params + # @overload get_bucket_metrics_configuration + # @param params [Hash] ({}) + # @return [Types::GetBucketMetricsConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketMetricsConfigurationOutput#metrics_configuration #metrics_configuration} => Types::MetricsConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketMetricsConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6234 + def get_bucket_metrics_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # No longer used, see [GetBucketNotificationConfiguration][1]. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketNotificationConfiguration.html + # + # @example Example: To get notification configuration set on a bucket + # + # # The following example returns notification configuration set on a bucket. + # + # resp = client.get_bucket_notification({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # queue_configuration: { + # event: "s3:ObjectCreated:Put", + # events: [ + # "s3:ObjectCreated:Put", + # ], + # id: "MDQ2OGQ4NDEtOTBmNi00YTM4LTk0NzYtZDIwN2I3NWQ1NjIx", + # queue: "arn:aws:sqs:us-east-1:acct-id:S3ObjectCreatedEventQueue", + # }, + # topic_configuration: { + # event: "s3:ObjectCreated:Copy", + # events: [ + # "s3:ObjectCreated:Copy", + # ], + # id: "YTVkMWEzZGUtNTY1NS00ZmE2LWJjYjktMmRlY2QwODFkNTJi", + # topic: "arn:aws:sns:us-east-1:acct-id:S3ObjectCreatedEventTopic", + # }, + # } + # @example Example: To get notification configuration set on a bucket + # + # # The following example returns notification configuration set on a bucket. + # + # resp = client.get_bucket_notification({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # queue_configuration: { + # event: "s3:ObjectCreated:Put", + # events: [ + # "s3:ObjectCreated:Put", + # ], + # id: "MDQ2OGQ4NDEtOTBmNi00YTM4LTk0NzYtZDIwN2I3NWQ1NjIx", + # queue: "arn:aws:sqs:us-east-1:acct-id:S3ObjectCreatedEventQueue", + # }, + # topic_configuration: { + # event: "s3:ObjectCreated:Copy", + # events: [ + # "s3:ObjectCreated:Copy", + # ], + # id: "YTVkMWEzZGUtNTY1NS00ZmE2LWJjYjktMmRlY2QwODFkNTJi", + # topic: "arn:aws:sns:us-east-1:acct-id:S3ObjectCreatedEventTopic", + # }, + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_notification({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.topic_configuration.id #=> String + # resp.topic_configuration.events #=> Array + # resp.topic_configuration.events[0] #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.topic_configuration.event #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.topic_configuration.topic #=> String + # resp.queue_configuration.id #=> String + # resp.queue_configuration.event #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.queue_configuration.events #=> Array + # resp.queue_configuration.events[0] #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.queue_configuration.queue #=> String + # resp.cloud_function_configuration.id #=> String + # resp.cloud_function_configuration.event #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.cloud_function_configuration.events #=> Array + # resp.cloud_function_configuration.events[0] #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.cloud_function_configuration.cloud_function #=> String + # resp.cloud_function_configuration.invocation_role #=> String + # @option params + # @option params + # @overload get_bucket_notification + # @param params [Hash] ({}) + # @return [Types::NotificationConfigurationDeprecated] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::NotificationConfigurationDeprecated#topic_configuration #topic_configuration} => Types::TopicConfigurationDeprecated + # * {Types::NotificationConfigurationDeprecated#queue_configuration #queue_configuration} => Types::QueueConfigurationDeprecated + # * {Types::NotificationConfigurationDeprecated#cloud_function_configuration #cloud_function_configuration} => Types::CloudFunctionConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotification AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6365 + def get_bucket_notification(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the notification configuration of a bucket. + # + # If notifications are not enabled on the bucket, the action returns an + # empty `NotificationConfiguration` element. + # + # By default, you must be the bucket owner to read the notification + # configuration of a bucket. However, the bucket owner can use a bucket + # policy to grant permission to other users to read this configuration + # with the `s3:GetBucketNotification` permission. + # + # When you use this API operation with an access point, provide the + # alias of the access point in place of the bucket name. + # + # When you use this API operation with an Object Lambda access point, + # provide the alias of the Object Lambda access point in place of the + # bucket name. If the Object Lambda access point alias in a request is + # not valid, the error code `InvalidAccessPointAliasError` is returned. + # For more information about `InvalidAccessPointAliasError`, see [List + # of Error Codes][1]. + # + # For more information about setting and reading the notification + # configuration on a bucket, see [Setting Up Notification of Bucket + # Events][2]. For more information about bucket policies, see [Using + # Bucket Policies][3]. + # + # The following action is related to `GetBucketNotification`: + # + # * [PutBucketNotification][4] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#ErrorCodeList + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-iam-policies.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketNotification.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_notification_configuration({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.topic_configurations #=> Array + # resp.topic_configurations[0].id #=> String + # resp.topic_configurations[0].topic_arn #=> String + # resp.topic_configurations[0].events #=> Array + # resp.topic_configurations[0].events[0] #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.topic_configurations[0].filter.key.filter_rules #=> Array + # resp.topic_configurations[0].filter.key.filter_rules[0].name #=> String, one of "prefix", "suffix" + # resp.topic_configurations[0].filter.key.filter_rules[0].value #=> String + # resp.queue_configurations #=> Array + # resp.queue_configurations[0].id #=> String + # resp.queue_configurations[0].queue_arn #=> String + # resp.queue_configurations[0].events #=> Array + # resp.queue_configurations[0].events[0] #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.queue_configurations[0].filter.key.filter_rules #=> Array + # resp.queue_configurations[0].filter.key.filter_rules[0].name #=> String, one of "prefix", "suffix" + # resp.queue_configurations[0].filter.key.filter_rules[0].value #=> String + # resp.lambda_function_configurations #=> Array + # resp.lambda_function_configurations[0].id #=> String + # resp.lambda_function_configurations[0].lambda_function_arn #=> String + # resp.lambda_function_configurations[0].events #=> Array + # resp.lambda_function_configurations[0].events[0] #=> String, one of "s3:ReducedRedundancyLostObject", "s3:ObjectCreated:*", "s3:ObjectCreated:Put", "s3:ObjectCreated:Post", "s3:ObjectCreated:Copy", "s3:ObjectCreated:CompleteMultipartUpload", "s3:ObjectRemoved:*", "s3:ObjectRemoved:Delete", "s3:ObjectRemoved:DeleteMarkerCreated", "s3:ObjectRestore:*", "s3:ObjectRestore:Post", "s3:ObjectRestore:Completed", "s3:Replication:*", "s3:Replication:OperationFailedReplication", "s3:Replication:OperationNotTracked", "s3:Replication:OperationMissedThreshold", "s3:Replication:OperationReplicatedAfterThreshold", "s3:ObjectRestore:Delete", "s3:LifecycleTransition", "s3:IntelligentTiering", "s3:ObjectAcl:Put", "s3:LifecycleExpiration:*", "s3:LifecycleExpiration:Delete", "s3:LifecycleExpiration:DeleteMarkerCreated", "s3:ObjectTagging:*", "s3:ObjectTagging:Put", "s3:ObjectTagging:Delete" + # resp.lambda_function_configurations[0].filter.key.filter_rules #=> Array + # resp.lambda_function_configurations[0].filter.key.filter_rules[0].name #=> String, one of "prefix", "suffix" + # resp.lambda_function_configurations[0].filter.key.filter_rules[0].value #=> String + # @option params + # @option params + # @overload get_bucket_notification_configuration + # @param params [Hash] ({}) + # @return [Types::NotificationConfiguration] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::NotificationConfiguration#topic_configurations #topic_configurations} => Array<Types::TopicConfiguration> + # * {Types::NotificationConfiguration#queue_configurations #queue_configurations} => Array<Types::QueueConfiguration> + # * {Types::NotificationConfiguration#lambda_function_configurations #lambda_function_configurations} => Array<Types::LambdaFunctionConfiguration> + # * {Types::NotificationConfiguration#event_bridge_configuration #event_bridge_configuration} => Types::EventBridgeConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotificationConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6480 + def get_bucket_notification_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Retrieves `OwnershipControls` for an Amazon S3 bucket. To use this + # operation, you must have the `s3:GetBucketOwnershipControls` + # permission. For more information about Amazon S3 permissions, see + # [Specifying permissions in a policy][1]. + # + # For information about Amazon S3 Object Ownership, see [Using Object + # Ownership][2]. + # + # The following operations are related to `GetBucketOwnershipControls`: + # + # * PutBucketOwnershipControls + # + # * DeleteBucketOwnershipControls + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_ownership_controls({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.ownership_controls.rules #=> Array + # resp.ownership_controls.rules[0].object_ownership #=> String, one of "BucketOwnerPreferred", "ObjectWriter", "BucketOwnerEnforced" + # @option params + # @option params + # @overload get_bucket_ownership_controls + # @param params [Hash] ({}) + # @return [Types::GetBucketOwnershipControlsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketOwnershipControlsOutput#ownership_controls #ownership_controls} => Types::OwnershipControls + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketOwnershipControls AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6537 + def get_bucket_ownership_controls(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns the policy of a specified bucket. + # + # Directory buckets - For directory buckets, you must make + # requests for this API operation to the Regional endpoint. These + # endpoints support path-style requests in the format + # `https://s3express-control.region_code.amazonaws.com/bucket-name `. + # Virtual-hosted-style requests aren't supported. For more information, + # see [Regional and Zonal endpoints][1] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # + # : If you are using an identity other than the root user of the Amazon + # Web Services account that owns the bucket, the calling identity must + # both have the `GetBucketPolicy` permissions on the specified bucket + # and belong to the bucket owner's account in order to use this + # operation. + # + # If you don't have `GetBucketPolicy` permissions, Amazon S3 returns + # a `403 Access Denied` error. If you have the correct permissions, + # but you're not using an identity that belongs to the bucket + # owner's account, Amazon S3 returns a `405 Method Not Allowed` + # error. + # + # To ensure that bucket owners don't inadvertently lock themselves + # out of their own buckets, the root principal in a bucket owner's + # Amazon Web Services account can perform the `GetBucketPolicy`, + # `PutBucketPolicy`, and `DeleteBucketPolicy` API actions, even if + # their bucket policy explicitly denies the root principal's access. + # Bucket owner root principals can only be blocked from performing + # these API actions by VPC endpoint policies and Amazon Web Services + # Organizations policies. + # + # * **General purpose bucket permissions** - The `s3:GetBucketPolicy` + # permission is required in a policy. For more information about + # general purpose buckets bucket policies, see [Using Bucket + # Policies and User Policies][2] in the *Amazon S3 User Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation, you must have the `s3express:GetBucketPolicy` + # permission in an IAM identity-based policy instead of a bucket + # policy. Cross-account access to this API operation isn't + # supported. This operation can only be performed by the Amazon Web + # Services account that owns the resource. For more information + # about directory bucket policies and permissions, see [Amazon Web + # Services Identity and Access Management (IAM) for S3 Express One + # Zone][3] in the *Amazon S3 User Guide*. + # + # Example bucket policies + # + # : **General purpose buckets example bucket policies** - See [Bucket + # policy examples][4] in the *Amazon S3 User Guide*. + # + # **Directory bucket example bucket policies** - See [Example bucket + # policies for S3 Express One Zone][5] in the *Amazon S3 User Guide*. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is + # `s3express-control.region.amazonaws.com`. + # + # The following action is related to `GetBucketPolicy`: + # + # * [GetObject][6] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-iam-policies.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/example-bucket-policies.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # + # @example Example: To get bucket policy + # + # # The following example returns bucket policy associated with a bucket. + # + # resp = client.get_bucket_policy({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # policy: "{\"Version\":\"2008-10-17\",\"Id\":\"LogPolicy\",\"Statement\":[{\"Sid\":\"Enables the log delivery group to publish logs to your bucket \",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"111122223333\"},\"Action\":[\"s3:GetBucketAcl\",\"s3:GetObjectAcl\",\"s3:PutObject\"],\"Resource\":[\"arn:aws:s3:::policytest1/*\",\"arn:aws:s3:::policytest1\"]}]}", + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_policy({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.policy #=> String + # @option params + # @option params + # @overload get_bucket_policy + # @param params [Hash] ({}) + # @return [Types::GetBucketPolicyOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketPolicyOutput#policy #policy} => IO + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicy AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6697 + def get_bucket_policy(params = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # This operation is not supported by directory buckets. + # + # + # + # Retrieves the policy status for an Amazon S3 bucket, indicating + # whether the bucket is public. In order to use this operation, you must + # have the `s3:GetBucketPolicyStatus` permission. For more information + # about Amazon S3 permissions, see [Specifying Permissions in a + # Policy][1]. + # + # For more information about when Amazon S3 considers a bucket public, + # see [The Meaning of "Public"][2]. + # + # The following operations are related to `GetBucketPolicyStatus`: + # + # * [Using Amazon S3 Block Public Access][3] + # + # * [GetPublicAccessBlock][4] + # + # * [PutPublicAccessBlock][5] + # + # * [DeletePublicAccessBlock][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetPublicAccessBlock.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutPublicAccessBlock.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeletePublicAccessBlock.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_policy_status({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.policy_status.is_public #=> Boolean + # @option params + # @option params + # @overload get_bucket_policy_status + # @param params [Hash] ({}) + # @return [Types::GetBucketPolicyStatusOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketPolicyStatusOutput#policy_status #policy_status} => Types::PolicyStatus + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicyStatus AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6762 + def get_bucket_policy_status(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the replication configuration of a bucket. + # + # It can take a while to propagate the put or delete a replication + # configuration to all Amazon S3 systems. Therefore, a get request soon + # after put or delete can return a wrong result. + # + # + # + # For information about replication configuration, see [Replication][1] + # in the *Amazon S3 User Guide*. + # + # This action requires permissions for the + # `s3:GetReplicationConfiguration` action. For more information about + # permissions, see [Using Bucket Policies and User Policies][2]. + # + # If you include the `Filter` element in a replication configuration, + # you must also include the `DeleteMarkerReplication` and `Priority` + # elements. The response also returns those elements. + # + # For information about `GetBucketReplication` errors, see [List of + # replication-related error codes][3] + # + # The following operations are related to `GetBucketReplication`: + # + # * [PutBucketReplication][4] + # + # * [DeleteBucketReplication][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-iam-policies.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#ReplicationErrorCodeList + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketReplication.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketReplication.html + # + # @example Example: To get replication configuration set on a bucket + # + # # The following example returns replication configuration set on a bucket. + # + # resp = client.get_bucket_replication({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # replication_configuration: { + # role: "arn:aws:iam::acct-id:role/example-role", + # rules: [ + # { + # destination: { + # bucket: "arn:aws:s3:::destination-bucket", + # }, + # id: "MWIwNTkwZmItMTE3MS00ZTc3LWJkZDEtNzRmODQwYzc1OTQy", + # prefix: "Tax", + # status: "Enabled", + # }, + # ], + # }, + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_replication({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.replication_configuration.role #=> String + # resp.replication_configuration.rules #=> Array + # resp.replication_configuration.rules[0].id #=> String + # resp.replication_configuration.rules[0].priority #=> Integer + # resp.replication_configuration.rules[0].prefix #=> String + # resp.replication_configuration.rules[0].filter.prefix #=> String + # resp.replication_configuration.rules[0].filter.tag.key #=> String + # resp.replication_configuration.rules[0].filter.tag.value #=> String + # resp.replication_configuration.rules[0].filter.and.prefix #=> String + # resp.replication_configuration.rules[0].filter.and.tags #=> Array + # resp.replication_configuration.rules[0].filter.and.tags[0].key #=> String + # resp.replication_configuration.rules[0].filter.and.tags[0].value #=> String + # resp.replication_configuration.rules[0].status #=> String, one of "Enabled", "Disabled" + # resp.replication_configuration.rules[0].source_selection_criteria.sse_kms_encrypted_objects.status #=> String, one of "Enabled", "Disabled" + # resp.replication_configuration.rules[0].source_selection_criteria.replica_modifications.status #=> String, one of "Enabled", "Disabled" + # resp.replication_configuration.rules[0].existing_object_replication.status #=> String, one of "Enabled", "Disabled" + # resp.replication_configuration.rules[0].destination.bucket #=> String + # resp.replication_configuration.rules[0].destination.account #=> String + # resp.replication_configuration.rules[0].destination.storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "GLACIER", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.replication_configuration.rules[0].destination.access_control_translation.owner #=> String, one of "Destination" + # resp.replication_configuration.rules[0].destination.encryption_configuration.replica_kms_key_id #=> String + # resp.replication_configuration.rules[0].destination.replication_time.status #=> String, one of "Enabled", "Disabled" + # resp.replication_configuration.rules[0].destination.replication_time.time.minutes #=> Integer + # resp.replication_configuration.rules[0].destination.metrics.status #=> String, one of "Enabled", "Disabled" + # resp.replication_configuration.rules[0].destination.metrics.event_threshold.minutes #=> Integer + # resp.replication_configuration.rules[0].delete_marker_replication.status #=> String, one of "Enabled", "Disabled" + # @option params + # @option params + # @overload get_bucket_replication + # @param params [Hash] ({}) + # @return [Types::GetBucketReplicationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketReplicationOutput#replication_configuration #replication_configuration} => Types::ReplicationConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketReplication AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6885 + def get_bucket_replication(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the request payment configuration of a bucket. To use this + # version of the operation, you must be the bucket owner. For more + # information, see [Requester Pays Buckets][1]. + # + # The following operations are related to `GetBucketRequestPayment`: + # + # * [ListObjects][2] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/RequesterPaysBuckets.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjects.html + # + # @example Example: To get bucket versioning configuration + # + # # The following example retrieves bucket versioning configuration. + # + # resp = client.get_bucket_request_payment({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # payer: "BucketOwner", + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_request_payment({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.payer #=> String, one of "Requester", "BucketOwner" + # @option params + # @option params + # @overload get_bucket_request_payment + # @param params [Hash] ({}) + # @return [Types::GetBucketRequestPaymentOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketRequestPaymentOutput#payer #payer} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketRequestPayment AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#6951 + def get_bucket_request_payment(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the tag set associated with the bucket. + # + # To use this operation, you must have permission to perform the + # `s3:GetBucketTagging` action. By default, the bucket owner has this + # permission and can grant this permission to others. + # + # `GetBucketTagging` has the following special error: + # + # * Error code: `NoSuchTagSet` + # + # * Description: There is no tag set associated with the bucket. + # + # ^ + # + # The following operations are related to `GetBucketTagging`: + # + # * [PutBucketTagging][1] + # + # * [DeleteBucketTagging][2] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketTagging.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketTagging.html + # + # @example Example: To get tag set associated with a bucket + # + # # The following example returns tag set associated with a bucket + # + # resp = client.get_bucket_tagging({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # tag_set: [ + # { + # key: "key1", + # value: "value1", + # }, + # { + # key: "key2", + # value: "value2", + # }, + # ], + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_tagging({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.tag_set #=> Array + # resp.tag_set[0].key #=> String + # resp.tag_set[0].value #=> String + # @option params + # @option params + # @overload get_bucket_tagging + # @param params [Hash] ({}) + # @return [Types::GetBucketTaggingOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketTaggingOutput#tag_set #tag_set} => Array<Types::Tag> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketTagging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#7037 + def get_bucket_tagging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the versioning state of a bucket. + # + # To retrieve the versioning state of a bucket, you must be the bucket + # owner. + # + # This implementation also returns the MFA Delete status of the + # versioning state. If the MFA Delete status is `enabled`, the bucket + # owner must use an authentication device to change the versioning state + # of the bucket. + # + # The following operations are related to `GetBucketVersioning`: + # + # * [GetObject][1] + # + # * [PutObject][2] + # + # * [DeleteObject][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObject.html + # + # @example Example: To get bucket versioning configuration + # + # # The following example retrieves bucket versioning configuration. + # + # resp = client.get_bucket_versioning({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # mfa_delete: "Disabled", + # status: "Enabled", + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_versioning({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.status #=> String, one of "Enabled", "Suspended" + # resp.mfa_delete #=> String, one of "Enabled", "Disabled" + # @option params + # @option params + # @overload get_bucket_versioning + # @param params [Hash] ({}) + # @return [Types::GetBucketVersioningOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketVersioningOutput#status #status} => String + # * {Types::GetBucketVersioningOutput#mfa_delete #mfa_delete} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketVersioning AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#7114 + def get_bucket_versioning(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the website configuration for a bucket. To host website on + # Amazon S3, you can configure a bucket as website by adding a website + # configuration. For more information about hosting websites, see + # [Hosting Websites on Amazon S3][1]. + # + # This GET action requires the `S3:GetBucketWebsite` permission. By + # default, only the bucket owner can read the bucket website + # configuration. However, bucket owners can allow other users to read + # the website configuration by writing a bucket policy granting them the + # `S3:GetBucketWebsite` permission. + # + # The following operations are related to `GetBucketWebsite`: + # + # * [DeleteBucketWebsite][2] + # + # * [PutBucketWebsite][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketWebsite.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketWebsite.html + # + # @example Example: To get bucket website configuration + # + # # The following example retrieves website configuration of a bucket. + # + # resp = client.get_bucket_website({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # error_document: { + # key: "error.html", + # }, + # index_document: { + # suffix: "index.html", + # }, + # } + # @example Request syntax with placeholder values + # + # resp = client.get_bucket_website({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.redirect_all_requests_to.host_name #=> String + # resp.redirect_all_requests_to.protocol #=> String, one of "http", "https" + # resp.index_document.suffix #=> String + # resp.error_document.key #=> String + # resp.routing_rules #=> Array + # resp.routing_rules[0].condition.http_error_code_returned_equals #=> String + # resp.routing_rules[0].condition.key_prefix_equals #=> String + # resp.routing_rules[0].redirect.host_name #=> String + # resp.routing_rules[0].redirect.http_redirect_code #=> String + # resp.routing_rules[0].redirect.protocol #=> String, one of "http", "https" + # resp.routing_rules[0].redirect.replace_key_prefix_with #=> String + # resp.routing_rules[0].redirect.replace_key_with #=> String + # @option params + # @option params + # @overload get_bucket_website + # @param params [Hash] ({}) + # @return [Types::GetBucketWebsiteOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetBucketWebsiteOutput#redirect_all_requests_to #redirect_all_requests_to} => Types::RedirectAllRequestsTo + # * {Types::GetBucketWebsiteOutput#index_document #index_document} => Types::IndexDocument + # * {Types::GetBucketWebsiteOutput#error_document #error_document} => Types::ErrorDocument + # * {Types::GetBucketWebsiteOutput#routing_rules #routing_rules} => Array<Types::RoutingRule> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketWebsite AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#7206 + def get_bucket_website(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Retrieves an object from Amazon S3. + # + # In the `GetObject` request, specify the full key name for the object. + # + # **General purpose buckets** - Both the virtual-hosted-style requests + # and the path-style requests are supported. For a virtual hosted-style + # request example, if you have the object + # `photos/2006/February/sample.jpg`, specify the object key name as + # `/photos/2006/February/sample.jpg`. For a path-style request example, + # if you have the object `photos/2006/February/sample.jpg` in the bucket + # named `examplebucket`, specify the object key name as + # `/examplebucket/photos/2006/February/sample.jpg`. For more information + # about request types, see [HTTP Host Header Bucket Specification][1] in + # the *Amazon S3 User Guide*. + # + # **Directory buckets** - Only virtual-hosted-style requests are + # supported. For a virtual hosted-style request example, if you have the + # object `photos/2006/February/sample.jpg` in the bucket named + # `examplebucket--use1-az5--x-s3`, specify the object key name as + # `/photos/2006/February/sample.jpg`. Also, when you make requests to + # this API operation, your requests are sent to the Zonal endpoint. + # These endpoints support virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][2] in the *Amazon S3 User Guide*. + # + # Permissions + # : * **General purpose bucket permissions** - You must have the + # required permissions in a policy. To use `GetObject`, you must + # have the `READ` access to the object (or version). If you grant + # `READ` access to the anonymous user, the `GetObject` operation + # returns the object without using an authorization header. For more + # information, see [Specifying permissions in a policy][3] in the + # *Amazon S3 User Guide*. + # + # If you include a `versionId` in your request header, you must have + # the `s3:GetObjectVersion` permission to access a specific version + # of an object. The `s3:GetObject` permission is not required in + # this scenario. + # + # If you request the current version of an object without a specific + # `versionId` in the request header, only the `s3:GetObject` + # permission is required. The `s3:GetObjectVersion` permission is + # not required in this scenario. + # + # If the object that you request doesn’t exist, the error that + # Amazon S3 returns depends on whether you also have the + # `s3:ListBucket` permission. + # + # * If you have the `s3:ListBucket` permission on the bucket, Amazon + # S3 returns an HTTP status code `404 Not Found` error. + # + # * If you don’t have the `s3:ListBucket` permission, Amazon S3 + # returns an HTTP status code `403 Access Denied` error. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][4] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][4]. + # + # Storage classes + # + # : If the object you are retrieving is stored in the S3 Glacier + # Flexible Retrieval storage class, the S3 Glacier Deep Archive + # storage class, the S3 Intelligent-Tiering Archive Access tier, or + # the S3 Intelligent-Tiering Deep Archive Access tier, before you can + # retrieve the object you must first restore a copy using + # [RestoreObject][5]. Otherwise, this operation returns an + # `InvalidObjectState` error. For information about restoring archived + # objects, see [Restoring Archived Objects][6] in the *Amazon S3 User + # Guide*. + # + # Directory buckets - For directory buckets, only the S3 + # Express One Zone storage class is supported to store newly created + # objects. Unsupported storage class values won't write a destination + # object and will respond with the HTTP status code `400 Bad Request`. + # + # Encryption + # + # : Encryption request headers, like `x-amz-server-side-encryption`, + # should not be sent for the `GetObject` requests, if your object uses + # server-side encryption with Amazon S3 managed encryption keys + # (SSE-S3), server-side encryption with Key Management Service (KMS) + # keys (SSE-KMS), or dual-layer server-side encryption with Amazon Web + # Services KMS keys (DSSE-KMS). If you include the header in your + # `GetObject` requests for the object that uses these types of keys, + # you’ll get an HTTP `400 Bad Request` error. + # + # Overriding response header values through the request + # + # : There are times when you want to override certain response header + # values of a `GetObject` response. For example, you might override + # the `Content-Disposition` response header value through your + # `GetObject` request. + # + # You can override values for a set of response headers. These + # modified response header values are included only in a successful + # response, that is, when the HTTP status code `200 OK` is returned. + # The headers you can override using the following query parameters in + # the request are a subset of the headers that Amazon S3 accepts when + # you create an object. + # + # The response headers that you can override for the `GetObject` + # response are `Cache-Control`, `Content-Disposition`, + # `Content-Encoding`, `Content-Language`, `Content-Type`, and + # `Expires`. + # + # To override values for a set of response headers in the `GetObject` + # response, you can use the following query parameters in the request. + # + # * `response-cache-control` + # + # * `response-content-disposition` + # + # * `response-content-encoding` + # + # * `response-content-language` + # + # * `response-content-type` + # + # * `response-expires` + # + # When you use these parameters, you must sign the request by using + # either an Authorization header or a presigned URL. These parameters + # cannot be used with an unsigned (anonymous) request. + # + # + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `GetObject`: + # + # * [ListBuckets][7] + # + # * [GetObjectAcl][8] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html#VirtualHostingSpecifyBucket + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/restoring-objects.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBuckets.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html + # + # @example Example: To retrieve a byte range of an object + # + # # The following example retrieves an object for an S3 bucket. The request specifies the range header to retrieve a + # # specific byte range. + # + # resp = client.get_object({ + # bucket: "examplebucket", + # key: "SampleFile.txt", + # range: "bytes=0-9", + # }) + # + # resp.to_h outputs the following: + # { + # accept_ranges: "bytes", + # content_length: 10, + # content_range: "bytes 0-9/43", + # content_type: "text/plain", + # etag: "\"0d94420ffd0bc68cd3d152506b97a9cc\"", + # last_modified: Time.parse("Thu, 09 Oct 2014 22:57:28 GMT"), + # metadata: { + # }, + # version_id: "null", + # } + # @example Example: To retrieve an object + # + # # The following example retrieves an object for an S3 bucket. + # + # resp = client.get_object({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # accept_ranges: "bytes", + # content_length: 3191, + # content_type: "image/jpeg", + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # last_modified: Time.parse("Thu, 15 Dec 2016 01:19:41 GMT"), + # metadata: { + # }, + # tag_count: 2, + # version_id: "null", + # } + # @example Download an object to disk + # # stream object directly to disk + # resp = s3.get_object( + # response_target: '/path/to/file', + # bucket: 'bucket-name', + # key: 'object-key') + # + # # you can still access other response data + # resp.metadata #=> { ... } + # resp.etag #=> "..." + # @example Download object into memory + # # omit :response_target to download to a StringIO in memory + # resp = s3.get_object(bucket: 'bucket-name', key: 'object-key') + # + # # call #read or #string on the response body + # resp.body.read + # #=> '...' + # @example Streaming data to a block + # # WARNING: yielding data to a block disables retries of networking errors + # # However truncation of the body will be retried automatically using a range request + # File.open('/path/to/file', 'wb') do |file| + # s3.get_object(bucket: 'bucket-name', key: 'object-key') do |chunk, headers| + # # headers['content-length'] + # file.write(chunk) + # end + # end + # @example Request syntax with placeholder values + # + # resp = client.get_object({ + # bucket: "BucketName", # required + # if_match: "IfMatch", + # if_modified_since: Time.now, + # if_none_match: "IfNoneMatch", + # if_unmodified_since: Time.now, + # key: "ObjectKey", # required + # range: "Range", + # response_cache_control: "ResponseCacheControl", + # response_content_disposition: "ResponseContentDisposition", + # response_content_encoding: "ResponseContentEncoding", + # response_content_language: "ResponseContentLanguage", + # response_content_type: "ResponseContentType", + # response_expires: Time.now, + # version_id: "ObjectVersionId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # part_number: 1, + # expected_bucket_owner: "AccountId", + # checksum_mode: "ENABLED", # accepts ENABLED + # }) + # @example Response structure + # + # resp.body #=> IO + # resp.delete_marker #=> Boolean + # resp.accept_ranges #=> String + # resp.expiration #=> String + # resp.restore #=> String + # resp.last_modified #=> Time + # resp.content_length #=> Integer + # resp.etag #=> String + # resp.checksum_crc32 #=> String + # resp.checksum_crc32c #=> String + # resp.checksum_sha1 #=> String + # resp.checksum_sha256 #=> String + # resp.missing_meta #=> Integer + # resp.version_id #=> String + # resp.cache_control #=> String + # resp.content_disposition #=> String + # resp.content_encoding #=> String + # resp.content_language #=> String + # resp.content_range #=> String + # resp.content_type #=> String + # resp.expires #=> Time + # resp.expires_string #=> String + # resp.website_redirect_location #=> String + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.metadata #=> Hash + # resp.metadata["MetadataKey"] #=> String + # resp.sse_customer_algorithm #=> String + # resp.sse_customer_key_md5 #=> String + # resp.ssekms_key_id #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "GLACIER", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.request_charged #=> String, one of "requester" + # resp.replication_status #=> String, one of "COMPLETE", "PENDING", "FAILED", "REPLICA", "COMPLETED" + # resp.parts_count #=> Integer + # resp.tag_count #=> Integer + # resp.object_lock_mode #=> String, one of "GOVERNANCE", "COMPLIANCE" + # resp.object_lock_retain_until_date #=> Time + # resp.object_lock_legal_hold_status #=> String, one of "ON", "OFF" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_object + # @param params [Hash] ({}) + # @return [Types::GetObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectOutput#body #body} => IO + # * {Types::GetObjectOutput#delete_marker #delete_marker} => Boolean + # * {Types::GetObjectOutput#accept_ranges #accept_ranges} => String + # * {Types::GetObjectOutput#expiration #expiration} => String + # * {Types::GetObjectOutput#restore #restore} => String + # * {Types::GetObjectOutput#last_modified #last_modified} => Time + # * {Types::GetObjectOutput#content_length #content_length} => Integer + # * {Types::GetObjectOutput#etag #etag} => String + # * {Types::GetObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::GetObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::GetObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::GetObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::GetObjectOutput#missing_meta #missing_meta} => Integer + # * {Types::GetObjectOutput#version_id #version_id} => String + # * {Types::GetObjectOutput#cache_control #cache_control} => String + # * {Types::GetObjectOutput#content_disposition #content_disposition} => String + # * {Types::GetObjectOutput#content_encoding #content_encoding} => String + # * {Types::GetObjectOutput#content_language #content_language} => String + # * {Types::GetObjectOutput#content_range #content_range} => String + # * {Types::GetObjectOutput#content_type #content_type} => String + # * {Types::GetObjectOutput#expires #expires} => Time + # * {Types::GetObjectOutput#expires_string #expires_string} => String + # * {Types::GetObjectOutput#website_redirect_location #website_redirect_location} => String + # * {Types::GetObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::GetObjectOutput#metadata #metadata} => Hash<String,String> + # * {Types::GetObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::GetObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::GetObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::GetObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::GetObjectOutput#storage_class #storage_class} => String + # * {Types::GetObjectOutput#request_charged #request_charged} => String + # * {Types::GetObjectOutput#replication_status #replication_status} => String + # * {Types::GetObjectOutput#parts_count #parts_count} => Integer + # * {Types::GetObjectOutput#tag_count #tag_count} => Integer + # * {Types::GetObjectOutput#object_lock_mode #object_lock_mode} => String + # * {Types::GetObjectOutput#object_lock_retain_until_date #object_lock_retain_until_date} => Time + # * {Types::GetObjectOutput#object_lock_legal_hold_status #object_lock_legal_hold_status} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObject AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#7853 + def get_object(params = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the access control list (ACL) of an object. To use this + # operation, you must have `s3:GetObjectAcl` permissions or `READ_ACP` + # access to the object. For more information, see [Mapping of ACL + # permissions and access policy permissions][1] in the *Amazon S3 User + # Guide* + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # By default, GET returns ACL information about the current version of + # an object. To return ACL information about a different version, use + # the versionId subresource. + # + # If your bucket uses the bucket owner enforced setting for S3 Object + # Ownership, requests to read ACLs are still supported and return the + # `bucket-owner-full-control` ACL with the owner being the account that + # created the bucket. For more information, see [ Controlling object + # ownership and disabling ACLs][2] in the *Amazon S3 User Guide*. + # + # + # + # The following operations are related to `GetObjectAcl`: + # + # * [GetObject][3] + # + # * [GetObjectAttributes][4] + # + # * [DeleteObject][5] + # + # * [PutObject][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/acl-overview.html#acl-access-policy-permission-mapping + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObject.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # + # @example Example: To retrieve object ACL + # + # # The following example retrieves access control list (ACL) of an object. + # + # resp = client.get_object_acl({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # grants: [ + # { + # grantee: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # type: "CanonicalUser", + # }, + # permission: "WRITE", + # }, + # { + # grantee: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # type: "CanonicalUser", + # }, + # permission: "WRITE_ACP", + # }, + # { + # grantee: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # type: "CanonicalUser", + # }, + # permission: "READ", + # }, + # { + # grantee: { + # display_name: "owner-display-name", + # id: "852b113eexamplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # type: "CanonicalUser", + # }, + # permission: "READ_ACP", + # }, + # ], + # owner: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # } + # @example Request syntax with placeholder values + # + # resp = client.get_object_acl({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.owner.display_name #=> String + # resp.owner.id #=> String + # resp.grants #=> Array + # resp.grants[0].grantee.display_name #=> String + # resp.grants[0].grantee.email_address #=> String + # resp.grants[0].grantee.id #=> String + # resp.grants[0].grantee.type #=> String, one of "CanonicalUser", "AmazonCustomerByEmail", "Group" + # resp.grants[0].grantee.uri #=> String + # resp.grants[0].permission #=> String, one of "FULL_CONTROL", "WRITE", "WRITE_ACP", "READ", "READ_ACP" + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_object_acl + # @param params [Hash] ({}) + # @return [Types::GetObjectAclOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectAclOutput#owner #owner} => Types::Owner + # * {Types::GetObjectAclOutput#grants #grants} => Array<Types::Grant> + # * {Types::GetObjectAclOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAcl AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8037 + def get_object_acl(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Retrieves all the metadata from an object without returning the object + # itself. This operation is useful if you're interested only in an + # object's metadata. + # + # `GetObjectAttributes` combines the functionality of `HeadObject` and + # `ListParts`. All of the data returned with each of those individual + # calls can be returned with a single call to `GetObjectAttributes`. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][1] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - To use + # `GetObjectAttributes`, you must have READ access to the object. + # The permissions that you need to use this operation with depend on + # whether the bucket is versioned. If the bucket is versioned, you + # need both the `s3:GetObjectVersion` and + # `s3:GetObjectVersionAttributes` permissions for this operation. If + # the bucket is not versioned, you need the `s3:GetObject` and + # `s3:GetObjectAttributes` permissions. For more information, see + # [Specifying Permissions in a Policy][2] in the *Amazon S3 User + # Guide*. If the object that you request does not exist, the error + # Amazon S3 returns depends on whether you also have the + # `s3:ListBucket` permission. + # + # * If you have the `s3:ListBucket` permission on the bucket, Amazon + # S3 returns an HTTP status code `404 Not Found` ("no such key") + # error. + # + # * If you don't have the `s3:ListBucket` permission, Amazon S3 + # returns an HTTP status code `403 Forbidden` ("access denied") + # error. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][3] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][3]. + # + # Encryption + # : Encryption request headers, like `x-amz-server-side-encryption`, + # should not be sent for `HEAD` requests if your object uses + # server-side encryption with Key Management Service (KMS) keys + # (SSE-KMS), dual-layer server-side encryption with Amazon Web + # Services KMS keys (DSSE-KMS), or server-side encryption with Amazon + # S3 managed encryption keys (SSE-S3). The + # `x-amz-server-side-encryption` header is used when you `PUT` an + # object to S3 and want to specify the encryption method. If you + # include this header in a `GET` request for an object that uses these + # types of keys, you’ll get an HTTP `400 Bad Request` error. It's + # because the encryption method can't be changed when you retrieve + # the object. + # + # + # + # If you encrypt an object by using server-side encryption with + # customer-provided encryption keys (SSE-C) when you store the object + # in Amazon S3, then when you retrieve the metadata from the object, + # you must use the following headers to provide the encryption key for + # the server to be able to retrieve the object's metadata. The + # headers are: + # + # * `x-amz-server-side-encryption-customer-algorithm` + # + # * `x-amz-server-side-encryption-customer-key` + # + # * `x-amz-server-side-encryption-customer-key-MD5` + # + # For more information about SSE-C, see [Server-Side Encryption (Using + # Customer-Provided Encryption Keys)][4] in the *Amazon S3 User + # Guide*. + # + # **Directory bucket permissions** - For directory buckets, only + # server-side encryption with Amazon S3 managed keys (SSE-S3) + # (`AES256`) is supported. + # + # + # + # Versioning + # + # : **Directory buckets** - S3 Versioning isn't enabled and supported + # for directory buckets. For this API operation, only the `null` value + # of the version ID is supported by directory buckets. You can only + # specify `null` to the `versionId` query parameter in the request. + # + # Conditional request headers + # + # : Consider the following when using request headers: + # + # * If both of the `If-Match` and `If-Unmodified-Since` headers are + # present in the request as follows, then Amazon S3 returns the HTTP + # status code `200 OK` and the data requested: + # + # * `If-Match` condition evaluates to `true`. + # + # * `If-Unmodified-Since` condition evaluates to `false`. + # + # For more information about conditional requests, see [RFC + # 7232][5]. + # + # * If both of the `If-None-Match` and `If-Modified-Since` headers are + # present in the request as follows, then Amazon S3 returns the HTTP + # status code `304 Not Modified`: + # + # * `If-None-Match` condition evaluates to `false`. + # + # * `If-Modified-Since` condition evaluates to `true`. + # + # For more information about conditional requests, see [RFC + # 7232][5]. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following actions are related to `GetObjectAttributes`: + # + # * [GetObject][6] + # + # * [GetObjectAcl][7] + # + # * [GetObjectLegalHold][8] + # + # * [GetObjectLockConfiguration][9] + # + # * [GetObjectRetention][10] + # + # * [GetObjectTagging][11] + # + # * [HeadObject][12] + # + # * [ListParts][13] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html + # [5]: https://tools.ietf.org/html/rfc7232 + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectLegalHold.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectLockConfiguration.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectRetention.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectTagging.html + # [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_HeadObject.html + # [13]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_object_attributes({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # max_parts: 1, + # part_number_marker: 1, + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # object_attributes: ["ETag"], # required, accepts ETag, Checksum, ObjectParts, StorageClass, ObjectSize + # }) + # @example Response structure + # + # resp.delete_marker #=> Boolean + # resp.last_modified #=> Time + # resp.version_id #=> String + # resp.request_charged #=> String, one of "requester" + # resp.etag #=> String + # resp.checksum.checksum_crc32 #=> String + # resp.checksum.checksum_crc32c #=> String + # resp.checksum.checksum_sha1 #=> String + # resp.checksum.checksum_sha256 #=> String + # resp.object_parts.total_parts_count #=> Integer + # resp.object_parts.part_number_marker #=> Integer + # resp.object_parts.next_part_number_marker #=> Integer + # resp.object_parts.max_parts #=> Integer + # resp.object_parts.is_truncated #=> Boolean + # resp.object_parts.parts #=> Array + # resp.object_parts.parts[0].part_number #=> Integer + # resp.object_parts.parts[0].size #=> Integer + # resp.object_parts.parts[0].checksum_crc32 #=> String + # resp.object_parts.parts[0].checksum_crc32c #=> String + # resp.object_parts.parts[0].checksum_sha1 #=> String + # resp.object_parts.parts[0].checksum_sha256 #=> String + # resp.storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "GLACIER", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.object_size #=> Integer + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_object_attributes + # @param params [Hash] ({}) + # @return [Types::GetObjectAttributesOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectAttributesOutput#delete_marker #delete_marker} => Boolean + # * {Types::GetObjectAttributesOutput#last_modified #last_modified} => Time + # * {Types::GetObjectAttributesOutput#version_id #version_id} => String + # * {Types::GetObjectAttributesOutput#request_charged #request_charged} => String + # * {Types::GetObjectAttributesOutput#etag #etag} => String + # * {Types::GetObjectAttributesOutput#checksum #checksum} => Types::Checksum + # * {Types::GetObjectAttributesOutput#object_parts #object_parts} => Types::GetObjectAttributesParts + # * {Types::GetObjectAttributesOutput#storage_class #storage_class} => String + # * {Types::GetObjectAttributesOutput#object_size #object_size} => Integer + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAttributes AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8383 + def get_object_attributes(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Gets an object's current legal hold status. For more information, see + # [Locking Objects][1]. + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # The following action is related to `GetObjectLegalHold`: + # + # * [GetObjectAttributes][2] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_object_legal_hold({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.legal_hold.status #=> String, one of "ON", "OFF" + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_object_legal_hold + # @param params [Hash] ({}) + # @return [Types::GetObjectLegalHoldOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectLegalHoldOutput#legal_hold #legal_hold} => Types::ObjectLockLegalHold + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectLegalHold AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8479 + def get_object_legal_hold(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Gets the Object Lock configuration for a bucket. The rule specified in + # the Object Lock configuration will be applied by default to every new + # object placed in the specified bucket. For more information, see + # [Locking Objects][1]. + # + # The following action is related to `GetObjectLockConfiguration`: + # + # * [GetObjectAttributes][2] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_object_lock_configuration({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.object_lock_configuration.object_lock_enabled #=> String, one of "Enabled" + # resp.object_lock_configuration.rule.default_retention.mode #=> String, one of "GOVERNANCE", "COMPLIANCE" + # resp.object_lock_configuration.rule.default_retention.days #=> Integer + # resp.object_lock_configuration.rule.default_retention.years #=> Integer + # @option params + # @option params + # @overload get_object_lock_configuration + # @param params [Hash] ({}) + # @return [Types::GetObjectLockConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectLockConfigurationOutput#object_lock_configuration #object_lock_configuration} => Types::ObjectLockConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectLockConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8549 + def get_object_lock_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Retrieves an object's retention settings. For more information, see + # [Locking Objects][1]. + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # The following action is related to `GetObjectRetention`: + # + # * [GetObjectAttributes][2] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_object_retention({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.retention.mode #=> String, one of "GOVERNANCE", "COMPLIANCE" + # resp.retention.retain_until_date #=> Time + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_object_retention + # @param params [Hash] ({}) + # @return [Types::GetObjectRetentionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectRetentionOutput#retention #retention} => Types::ObjectLockRetention + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectRetention AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8646 + def get_object_retention(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns the tag-set of an object. You send the GET request against the + # tagging subresource associated with the object. + # + # To use this operation, you must have permission to perform the + # `s3:GetObjectTagging` action. By default, the GET action returns + # information about current version of an object. For a versioned + # bucket, you can have multiple versions of an object in your bucket. To + # retrieve tags of any other version, use the versionId query parameter. + # You also need permission for the `s3:GetObjectVersionTagging` action. + # + # By default, the bucket owner has this permission and can grant this + # permission to others. + # + # For information about the Amazon S3 object tagging feature, see + # [Object Tagging][1]. + # + # The following actions are related to `GetObjectTagging`: + # + # * [DeleteObjectTagging][2] + # + # * [GetObjectAttributes][3] + # + # * [PutObjectTagging][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-tagging.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObjectTagging.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObjectTagging.html + # + # @example Example: To retrieve tag set of a specific object version + # + # # The following example retrieves tag set of an object. The request specifies object version. + # + # resp = client.get_object_tagging({ + # bucket: "examplebucket", + # key: "exampleobject", + # version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI", + # }) + # + # resp.to_h outputs the following: + # { + # tag_set: [ + # { + # key: "Key1", + # value: "Value1", + # }, + # ], + # version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI", + # } + # @example Example: To retrieve tag set of an object + # + # # The following example retrieves tag set of an object. + # + # resp = client.get_object_tagging({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # tag_set: [ + # { + # key: "Key4", + # value: "Value4", + # }, + # { + # key: "Key3", + # value: "Value3", + # }, + # ], + # version_id: "null", + # } + # @example Request syntax with placeholder values + # + # resp = client.get_object_tagging({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # expected_bucket_owner: "AccountId", + # request_payer: "requester", # accepts requester + # }) + # @example Response structure + # + # resp.version_id #=> String + # resp.tag_set #=> Array + # resp.tag_set[0].key #=> String + # resp.tag_set[0].value #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_object_tagging + # @param params [Hash] ({}) + # @return [Types::GetObjectTaggingOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectTaggingOutput#version_id #version_id} => String + # * {Types::GetObjectTaggingOutput#tag_set #tag_set} => Array<Types::Tag> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTagging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8815 + def get_object_tagging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns torrent files from a bucket. BitTorrent can save you bandwidth + # when you're distributing large files. + # + # You can get torrent only for objects that are less than 5 GB in size, + # and that are not encrypted using server-side encryption with a + # customer-provided encryption key. + # + # + # + # To use GET, you must have READ access to the object. + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # The following action is related to `GetObjectTorrent`: + # + # * [GetObject][1] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # + # @example Example: To retrieve torrent files for an object + # + # # The following example retrieves torrent files of an object. + # + # resp = client.get_object_torrent({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.get_object_torrent({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.body #=> IO + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload get_object_torrent + # @param params [Hash] ({}) + # @return [Types::GetObjectTorrentOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectTorrentOutput#body #body} => IO + # * {Types::GetObjectTorrentOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTorrent AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8916 + def get_object_torrent(params = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # This operation is not supported by directory buckets. + # + # + # + # Retrieves the `PublicAccessBlock` configuration for an Amazon S3 + # bucket. To use this operation, you must have the + # `s3:GetBucketPublicAccessBlock` permission. For more information about + # Amazon S3 permissions, see [Specifying Permissions in a Policy][1]. + # + # When Amazon S3 evaluates the `PublicAccessBlock` configuration for a + # bucket or an object, it checks the `PublicAccessBlock` configuration + # for both the bucket (or the bucket that contains the object) and the + # bucket owner's account. If the `PublicAccessBlock` settings are + # different between the bucket and the account, Amazon S3 uses the most + # restrictive combination of the bucket-level and account-level + # settings. + # + # For more information about when Amazon S3 considers a bucket or an + # object public, see [The Meaning of "Public"][2]. + # + # The following operations are related to `GetPublicAccessBlock`: + # + # * [Using Amazon S3 Block Public Access][3] + # + # * [PutPublicAccessBlock][4] + # + # * [GetPublicAccessBlock][5] + # + # * [DeletePublicAccessBlock][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutPublicAccessBlock.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetPublicAccessBlock.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeletePublicAccessBlock.html + # + # @example Request syntax with placeholder values + # + # resp = client.get_public_access_block({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.public_access_block_configuration.block_public_acls #=> Boolean + # resp.public_access_block_configuration.ignore_public_acls #=> Boolean + # resp.public_access_block_configuration.block_public_policy #=> Boolean + # resp.public_access_block_configuration.restrict_public_buckets #=> Boolean + # @option params + # @option params + # @overload get_public_access_block + # @param params [Hash] ({}) + # @return [Types::GetPublicAccessBlockOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetPublicAccessBlockOutput#public_access_block_configuration #public_access_block_configuration} => Types::PublicAccessBlockConfiguration + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetPublicAccessBlock AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#8991 + def get_public_access_block(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # You can use this operation to determine if a bucket exists and if you + # have permission to access it. The action returns a `200 OK` if the + # bucket exists and you have permission to access it. + # + # If the bucket does not exist or you do not have permission to access + # it, the `HEAD` request returns a generic `400 Bad Request`, `403 + # Forbidden` or `404 Not Found` code. A message body is not included, so + # you cannot determine the exception beyond these HTTP response codes. + # + # Directory buckets - You must make requests for this API + # operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com`. Path-style + # requests are not supported. For more information, see [Regional and + # Zonal endpoints][1] in the *Amazon S3 User Guide*. + # + # + # + # Authentication and authorization + # + # : All `HeadBucket` requests must be authenticated and signed by using + # IAM credentials (access key ID and secret access key for the IAM + # identities). All headers with the `x-amz-` prefix, including + # `x-amz-copy-source`, must be signed. For more information, see [REST + # Authentication][2]. + # + # **Directory bucket** - You must use IAM credentials to authenticate + # and authorize your access to the `HeadBucket` API operation, instead + # of using the temporary security credentials through the + # `CreateSession` API operation. + # + # Amazon Web Services CLI or SDKs handles authentication and + # authorization on your behalf. + # + # Permissions + # + # : + # + # * **General purpose bucket permissions** - To use this operation, + # you must have permissions to perform the `s3:ListBucket` action. + # The bucket owner has this permission by default and can grant this + # permission to others. For more information about permissions, see + # [Managing access permissions to your Amazon S3 resources][3] in + # the *Amazon S3 User Guide*. + # + # * **Directory bucket permissions** - You must have the + # s3express:CreateSession permission in the + # `Action` element of a policy. By default, the session is in the + # `ReadWrite` mode. If you want to restrict the access, you can + # explicitly set the `s3express:SessionMode` condition key to + # `ReadOnly` on the bucket. + # + # For more information about example bucket policies, see [Example + # bucket policies for S3 Express One Zone][4] and [Amazon Web + # Services Identity and Access Management (IAM) identity-based + # policies for S3 Express One Zone][5] in the *Amazon S3 User + # Guide*. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-identity-policies.html + # + # The following waiters are defined for this operation (see {Client#wait_until} for detailed usage): + # + # * bucket_exists + # * bucket_not_exists + # + # @example Example: To determine if bucket exists + # + # # This operation checks to see if a bucket exists. + # + # resp = client.head_bucket({ + # bucket: "acl1", + # }) + # @example Request syntax with placeholder values + # + # resp = client.head_bucket({ + # bucket: "BucketName", # required + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.bucket_location_type #=> String, one of "AvailabilityZone" + # resp.bucket_location_name #=> String + # resp.bucket_region #=> String + # resp.access_point_alias #=> Boolean + # @option params + # @option params + # @overload head_bucket + # @param params [Hash] ({}) + # @return [Types::HeadBucketOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::HeadBucketOutput#bucket_location_type #bucket_location_type} => String + # * {Types::HeadBucketOutput#bucket_location_name #bucket_location_name} => String + # * {Types::HeadBucketOutput#bucket_region #bucket_region} => String + # * {Types::HeadBucketOutput#access_point_alias #access_point_alias} => Boolean + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadBucket AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#9164 + def head_bucket(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # The `HEAD` operation retrieves metadata from an object without + # returning the object itself. This operation is useful if you're + # interested only in an object's metadata. + # + # A `HEAD` request has the same options as a `GET` operation on an + # object. The response is identical to the `GET` response except that + # there is no response body. Because of this, if the `HEAD` request + # generates an error, it returns a generic code, such as `400 Bad + # Request`, `403 Forbidden`, `404 Not Found`, `405 Method Not Allowed`, + # `412 Precondition Failed`, or `304 Not Modified`. It's not possible + # to retrieve the exact exception of these error codes. + # + # Request headers are limited to 8 KB in size. For more information, see + # [Common Request Headers][1]. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][2] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # + # : + # + # * **General purpose bucket permissions** - To use `HEAD`, you must + # have the `s3:GetObject` permission. You need the relevant read + # object (or version) permission for this operation. For more + # information, see [Actions, resources, and condition keys for + # Amazon S3][3] in the *Amazon S3 User Guide*. + # + # If the object you request doesn't exist, the error that Amazon S3 + # returns depends on whether you also have the `s3:ListBucket` + # permission. + # + # * If you have the `s3:ListBucket` permission on the bucket, Amazon + # S3 returns an HTTP status code `404 Not Found` error. + # + # * If you don’t have the `s3:ListBucket` permission, Amazon S3 + # returns an HTTP status code `403 Forbidden` error. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][4] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][4]. + # + # Encryption + # : Encryption request headers, like `x-amz-server-side-encryption`, + # should not be sent for `HEAD` requests if your object uses + # server-side encryption with Key Management Service (KMS) keys + # (SSE-KMS), dual-layer server-side encryption with Amazon Web + # Services KMS keys (DSSE-KMS), or server-side encryption with Amazon + # S3 managed encryption keys (SSE-S3). The + # `x-amz-server-side-encryption` header is used when you `PUT` an + # object to S3 and want to specify the encryption method. If you + # include this header in a `HEAD` request for an object that uses + # these types of keys, you’ll get an HTTP `400 Bad Request` error. + # It's because the encryption method can't be changed when you + # retrieve the object. + # + # + # + # If you encrypt an object by using server-side encryption with + # customer-provided encryption keys (SSE-C) when you store the object + # in Amazon S3, then when you retrieve the metadata from the object, + # you must use the following headers to provide the encryption key for + # the server to be able to retrieve the object's metadata. The + # headers are: + # + # * `x-amz-server-side-encryption-customer-algorithm` + # + # * `x-amz-server-side-encryption-customer-key` + # + # * `x-amz-server-side-encryption-customer-key-MD5` + # + # For more information about SSE-C, see [Server-Side Encryption (Using + # Customer-Provided Encryption Keys)][5] in the *Amazon S3 User + # Guide*. + # + # **Directory bucket permissions** - For directory buckets, only + # server-side encryption with Amazon S3 managed keys (SSE-S3) + # (`AES256`) is supported. + # + # + # + # Versioning + # : * If the current version of the object is a delete marker, Amazon S3 + # behaves as if the object was deleted and includes + # `x-amz-delete-marker: true` in the response. + # + # * If the specified version is a delete marker, the response returns + # a `405 Method Not Allowed` error and the `Last-Modified: + # timestamp` response header. + # + # * **Directory buckets** - Delete marker is not supported by + # directory buckets. + # + # * **Directory buckets** - S3 Versioning isn't enabled and supported + # for directory buckets. For this API operation, only the `null` + # value of the version ID is supported by directory buckets. You can + # only specify `null` to the `versionId` query parameter in the + # request. + # + # + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following actions are related to `HeadObject`: + # + # * [GetObject][6] + # + # * [GetObjectAttributes][7] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTCommonRequestHeaders.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/list_amazons3.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html + # + # The following waiters are defined for this operation (see {Client#wait_until} for detailed usage): + # + # * object_exists + # * object_not_exists + # + # @example Example: To retrieve metadata of an object without returning the object itself + # + # # The following example retrieves an object metadata. + # + # resp = client.head_object({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # accept_ranges: "bytes", + # content_length: 3191, + # content_type: "image/jpeg", + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # last_modified: Time.parse("Thu, 15 Dec 2016 01:19:41 GMT"), + # metadata: { + # }, + # version_id: "null", + # } + # @example Request syntax with placeholder values + # + # resp = client.head_object({ + # bucket: "BucketName", # required + # if_match: "IfMatch", + # if_modified_since: Time.now, + # if_none_match: "IfNoneMatch", + # if_unmodified_since: Time.now, + # key: "ObjectKey", # required + # range: "Range", + # response_cache_control: "ResponseCacheControl", + # response_content_disposition: "ResponseContentDisposition", + # response_content_encoding: "ResponseContentEncoding", + # response_content_language: "ResponseContentLanguage", + # response_content_type: "ResponseContentType", + # response_expires: Time.now, + # version_id: "ObjectVersionId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # part_number: 1, + # expected_bucket_owner: "AccountId", + # checksum_mode: "ENABLED", # accepts ENABLED + # }) + # @example Response structure + # + # resp.delete_marker #=> Boolean + # resp.accept_ranges #=> String + # resp.expiration #=> String + # resp.restore #=> String + # resp.archive_status #=> String, one of "ARCHIVE_ACCESS", "DEEP_ARCHIVE_ACCESS" + # resp.last_modified #=> Time + # resp.content_length #=> Integer + # resp.checksum_crc32 #=> String + # resp.checksum_crc32c #=> String + # resp.checksum_sha1 #=> String + # resp.checksum_sha256 #=> String + # resp.etag #=> String + # resp.missing_meta #=> Integer + # resp.version_id #=> String + # resp.cache_control #=> String + # resp.content_disposition #=> String + # resp.content_encoding #=> String + # resp.content_language #=> String + # resp.content_type #=> String + # resp.expires #=> Time + # resp.expires_string #=> String + # resp.website_redirect_location #=> String + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.metadata #=> Hash + # resp.metadata["MetadataKey"] #=> String + # resp.sse_customer_algorithm #=> String + # resp.sse_customer_key_md5 #=> String + # resp.ssekms_key_id #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "GLACIER", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.request_charged #=> String, one of "requester" + # resp.replication_status #=> String, one of "COMPLETE", "PENDING", "FAILED", "REPLICA", "COMPLETED" + # resp.parts_count #=> Integer + # resp.object_lock_mode #=> String, one of "GOVERNANCE", "COMPLIANCE" + # resp.object_lock_retain_until_date #=> Time + # resp.object_lock_legal_hold_status #=> String, one of "ON", "OFF" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload head_object + # @param params [Hash] ({}) + # @return [Types::HeadObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::HeadObjectOutput#delete_marker #delete_marker} => Boolean + # * {Types::HeadObjectOutput#accept_ranges #accept_ranges} => String + # * {Types::HeadObjectOutput#expiration #expiration} => String + # * {Types::HeadObjectOutput#restore #restore} => String + # * {Types::HeadObjectOutput#archive_status #archive_status} => String + # * {Types::HeadObjectOutput#last_modified #last_modified} => Time + # * {Types::HeadObjectOutput#content_length #content_length} => Integer + # * {Types::HeadObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::HeadObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::HeadObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::HeadObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::HeadObjectOutput#etag #etag} => String + # * {Types::HeadObjectOutput#missing_meta #missing_meta} => Integer + # * {Types::HeadObjectOutput#version_id #version_id} => String + # * {Types::HeadObjectOutput#cache_control #cache_control} => String + # * {Types::HeadObjectOutput#content_disposition #content_disposition} => String + # * {Types::HeadObjectOutput#content_encoding #content_encoding} => String + # * {Types::HeadObjectOutput#content_language #content_language} => String + # * {Types::HeadObjectOutput#content_type #content_type} => String + # * {Types::HeadObjectOutput#expires #expires} => Time + # * {Types::HeadObjectOutput#expires_string #expires_string} => String + # * {Types::HeadObjectOutput#website_redirect_location #website_redirect_location} => String + # * {Types::HeadObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::HeadObjectOutput#metadata #metadata} => Hash<String,String> + # * {Types::HeadObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::HeadObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::HeadObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::HeadObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::HeadObjectOutput#storage_class #storage_class} => String + # * {Types::HeadObjectOutput#request_charged #request_charged} => String + # * {Types::HeadObjectOutput#replication_status #replication_status} => String + # * {Types::HeadObjectOutput#parts_count #parts_count} => Integer + # * {Types::HeadObjectOutput#object_lock_mode #object_lock_mode} => String + # * {Types::HeadObjectOutput#object_lock_retain_until_date #object_lock_retain_until_date} => Time + # * {Types::HeadObjectOutput#object_lock_legal_hold_status #object_lock_legal_hold_status} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadObject AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#9662 + def head_object(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Lists the analytics configurations for the bucket. You can have up to + # 1,000 analytics configurations per bucket. + # + # This action supports list pagination and does not return more than 100 + # configurations at a time. You should always check the `IsTruncated` + # element in the response. If there are no more configurations to list, + # `IsTruncated` is set to false. If there are more configurations to + # list, `IsTruncated` is set to true, and there will be a value in + # `NextContinuationToken`. You use the `NextContinuationToken` value to + # continue the pagination of the list by passing the value in + # continuation-token in the request to `GET` the next page. + # + # To use this operation, you must have permissions to perform the + # `s3:GetAnalyticsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For information about Amazon S3 analytics feature, see [Amazon S3 + # Analytics – Storage Class Analysis][3]. + # + # The following operations are related to + # `ListBucketAnalyticsConfigurations`: + # + # * [GetBucketAnalyticsConfiguration][4] + # + # * [DeleteBucketAnalyticsConfiguration][5] + # + # * [PutBucketAnalyticsConfiguration][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/analytics-storage-class.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketAnalyticsConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketAnalyticsConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketAnalyticsConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.list_bucket_analytics_configurations({ + # bucket: "BucketName", # required + # continuation_token: "Token", + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.is_truncated #=> Boolean + # resp.continuation_token #=> String + # resp.next_continuation_token #=> String + # resp.analytics_configuration_list #=> Array + # resp.analytics_configuration_list[0].id #=> String + # resp.analytics_configuration_list[0].filter.prefix #=> String + # resp.analytics_configuration_list[0].filter.tag.key #=> String + # resp.analytics_configuration_list[0].filter.tag.value #=> String + # resp.analytics_configuration_list[0].filter.and.prefix #=> String + # resp.analytics_configuration_list[0].filter.and.tags #=> Array + # resp.analytics_configuration_list[0].filter.and.tags[0].key #=> String + # resp.analytics_configuration_list[0].filter.and.tags[0].value #=> String + # resp.analytics_configuration_list[0].storage_class_analysis.data_export.output_schema_version #=> String, one of "V_1" + # resp.analytics_configuration_list[0].storage_class_analysis.data_export.destination.s3_bucket_destination.format #=> String, one of "CSV" + # resp.analytics_configuration_list[0].storage_class_analysis.data_export.destination.s3_bucket_destination.bucket_account_id #=> String + # resp.analytics_configuration_list[0].storage_class_analysis.data_export.destination.s3_bucket_destination.bucket #=> String + # resp.analytics_configuration_list[0].storage_class_analysis.data_export.destination.s3_bucket_destination.prefix #=> String + # @option params + # @option params + # @option params + # @overload list_bucket_analytics_configurations + # @param params [Hash] ({}) + # @return [Types::ListBucketAnalyticsConfigurationsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListBucketAnalyticsConfigurationsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListBucketAnalyticsConfigurationsOutput#continuation_token #continuation_token} => String + # * {Types::ListBucketAnalyticsConfigurationsOutput#next_continuation_token #next_continuation_token} => String + # * {Types::ListBucketAnalyticsConfigurationsOutput#analytics_configuration_list #analytics_configuration_list} => Array<Types::AnalyticsConfiguration> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketAnalyticsConfigurations AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#9763 + def list_bucket_analytics_configurations(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Lists the S3 Intelligent-Tiering configuration from the specified + # bucket. + # + # The S3 Intelligent-Tiering storage class is designed to optimize + # storage costs by automatically moving data to the most cost-effective + # storage access tier, without performance impact or operational + # overhead. S3 Intelligent-Tiering delivers automatic cost savings in + # three low latency and high throughput access tiers. To get the lowest + # storage cost on data that can be accessed in minutes to hours, you can + # choose to activate additional archiving capabilities. + # + # The S3 Intelligent-Tiering storage class is the ideal storage class + # for data with unknown, changing, or unpredictable access patterns, + # independent of object size or retention period. If the size of an + # object is less than 128 KB, it is not monitored and not eligible for + # auto-tiering. Smaller objects can be stored, but they are always + # charged at the Frequent Access tier rates in the S3 + # Intelligent-Tiering storage class. + # + # For more information, see [Storage class for automatically optimizing + # frequently and infrequently accessed objects][1]. + # + # Operations related to `ListBucketIntelligentTieringConfigurations` + # include: + # + # * [DeleteBucketIntelligentTieringConfiguration][2] + # + # * [PutBucketIntelligentTieringConfiguration][3] + # + # * [GetBucketIntelligentTieringConfiguration][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html#sc-dynamic-data-access + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketIntelligentTieringConfiguration.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketIntelligentTieringConfiguration.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketIntelligentTieringConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.list_bucket_intelligent_tiering_configurations({ + # bucket: "BucketName", # required + # continuation_token: "Token", + # }) + # @example Response structure + # + # resp.is_truncated #=> Boolean + # resp.continuation_token #=> String + # resp.next_continuation_token #=> String + # resp.intelligent_tiering_configuration_list #=> Array + # resp.intelligent_tiering_configuration_list[0].id #=> String + # resp.intelligent_tiering_configuration_list[0].filter.prefix #=> String + # resp.intelligent_tiering_configuration_list[0].filter.tag.key #=> String + # resp.intelligent_tiering_configuration_list[0].filter.tag.value #=> String + # resp.intelligent_tiering_configuration_list[0].filter.and.prefix #=> String + # resp.intelligent_tiering_configuration_list[0].filter.and.tags #=> Array + # resp.intelligent_tiering_configuration_list[0].filter.and.tags[0].key #=> String + # resp.intelligent_tiering_configuration_list[0].filter.and.tags[0].value #=> String + # resp.intelligent_tiering_configuration_list[0].status #=> String, one of "Enabled", "Disabled" + # resp.intelligent_tiering_configuration_list[0].tierings #=> Array + # resp.intelligent_tiering_configuration_list[0].tierings[0].days #=> Integer + # resp.intelligent_tiering_configuration_list[0].tierings[0].access_tier #=> String, one of "ARCHIVE_ACCESS", "DEEP_ARCHIVE_ACCESS" + # @option params + # @option params + # @overload list_bucket_intelligent_tiering_configurations + # @param params [Hash] ({}) + # @return [Types::ListBucketIntelligentTieringConfigurationsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListBucketIntelligentTieringConfigurationsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListBucketIntelligentTieringConfigurationsOutput#continuation_token #continuation_token} => String + # * {Types::ListBucketIntelligentTieringConfigurationsOutput#next_continuation_token #next_continuation_token} => String + # * {Types::ListBucketIntelligentTieringConfigurationsOutput#intelligent_tiering_configuration_list #intelligent_tiering_configuration_list} => Array<Types::IntelligentTieringConfiguration> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketIntelligentTieringConfigurations AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#9855 + def list_bucket_intelligent_tiering_configurations(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns a list of inventory configurations for the bucket. You can + # have up to 1,000 analytics configurations per bucket. + # + # This action supports list pagination and does not return more than 100 + # configurations at a time. Always check the `IsTruncated` element in + # the response. If there are no more configurations to list, + # `IsTruncated` is set to false. If there are more configurations to + # list, `IsTruncated` is set to true, and there is a value in + # `NextContinuationToken`. You use the `NextContinuationToken` value to + # continue the pagination of the list by passing the value in + # continuation-token in the request to `GET` the next page. + # + # To use this operation, you must have permissions to perform the + # `s3:GetInventoryConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For information about the Amazon S3 inventory feature, see [Amazon S3 + # Inventory][3] + # + # The following operations are related to + # `ListBucketInventoryConfigurations`: + # + # * [GetBucketInventoryConfiguration][4] + # + # * [DeleteBucketInventoryConfiguration][5] + # + # * [PutBucketInventoryConfiguration][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-inventory.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketInventoryConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketInventoryConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketInventoryConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.list_bucket_inventory_configurations({ + # bucket: "BucketName", # required + # continuation_token: "Token", + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.continuation_token #=> String + # resp.inventory_configuration_list #=> Array + # resp.inventory_configuration_list[0].destination.s3_bucket_destination.account_id #=> String + # resp.inventory_configuration_list[0].destination.s3_bucket_destination.bucket #=> String + # resp.inventory_configuration_list[0].destination.s3_bucket_destination.format #=> String, one of "CSV", "ORC", "Parquet" + # resp.inventory_configuration_list[0].destination.s3_bucket_destination.prefix #=> String + # resp.inventory_configuration_list[0].destination.s3_bucket_destination.encryption.ssekms.key_id #=> String + # resp.inventory_configuration_list[0].is_enabled #=> Boolean + # resp.inventory_configuration_list[0].filter.prefix #=> String + # resp.inventory_configuration_list[0].id #=> String + # resp.inventory_configuration_list[0].included_object_versions #=> String, one of "All", "Current" + # resp.inventory_configuration_list[0].optional_fields #=> Array + # resp.inventory_configuration_list[0].optional_fields[0] #=> String, one of "Size", "LastModifiedDate", "StorageClass", "ETag", "IsMultipartUploaded", "ReplicationStatus", "EncryptionStatus", "ObjectLockRetainUntilDate", "ObjectLockMode", "ObjectLockLegalHoldStatus", "IntelligentTieringAccessTier", "BucketKeyStatus", "ChecksumAlgorithm", "ObjectAccessControlList", "ObjectOwner" + # resp.inventory_configuration_list[0].schedule.frequency #=> String, one of "Daily", "Weekly" + # resp.is_truncated #=> Boolean + # resp.next_continuation_token #=> String + # @option params + # @option params + # @option params + # @overload list_bucket_inventory_configurations + # @param params [Hash] ({}) + # @return [Types::ListBucketInventoryConfigurationsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListBucketInventoryConfigurationsOutput#continuation_token #continuation_token} => String + # * {Types::ListBucketInventoryConfigurationsOutput#inventory_configuration_list #inventory_configuration_list} => Array<Types::InventoryConfiguration> + # * {Types::ListBucketInventoryConfigurationsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListBucketInventoryConfigurationsOutput#next_continuation_token #next_continuation_token} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketInventoryConfigurations AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#9957 + def list_bucket_inventory_configurations(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Lists the metrics configurations for the bucket. The metrics + # configurations are only for the request metrics of the bucket and do + # not provide information on daily storage metrics. You can have up to + # 1,000 configurations per bucket. + # + # This action supports list pagination and does not return more than 100 + # configurations at a time. Always check the `IsTruncated` element in + # the response. If there are no more configurations to list, + # `IsTruncated` is set to false. If there are more configurations to + # list, `IsTruncated` is set to true, and there is a value in + # `NextContinuationToken`. You use the `NextContinuationToken` value to + # continue the pagination of the list by passing the value in + # `continuation-token` in the request to `GET` the next page. + # + # To use this operation, you must have permissions to perform the + # `s3:GetMetricsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For more information about metrics configurations and CloudWatch + # request metrics, see [Monitoring Metrics with Amazon CloudWatch][3]. + # + # The following operations are related to + # `ListBucketMetricsConfigurations`: + # + # * [PutBucketMetricsConfiguration][4] + # + # * [GetBucketMetricsConfiguration][5] + # + # * [DeleteBucketMetricsConfiguration][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cloudwatch-monitoring.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketMetricsConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketMetricsConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketMetricsConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.list_bucket_metrics_configurations({ + # bucket: "BucketName", # required + # continuation_token: "Token", + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.is_truncated #=> Boolean + # resp.continuation_token #=> String + # resp.next_continuation_token #=> String + # resp.metrics_configuration_list #=> Array + # resp.metrics_configuration_list[0].id #=> String + # resp.metrics_configuration_list[0].filter.prefix #=> String + # resp.metrics_configuration_list[0].filter.tag.key #=> String + # resp.metrics_configuration_list[0].filter.tag.value #=> String + # resp.metrics_configuration_list[0].filter.access_point_arn #=> String + # resp.metrics_configuration_list[0].filter.and.prefix #=> String + # resp.metrics_configuration_list[0].filter.and.tags #=> Array + # resp.metrics_configuration_list[0].filter.and.tags[0].key #=> String + # resp.metrics_configuration_list[0].filter.and.tags[0].value #=> String + # resp.metrics_configuration_list[0].filter.and.access_point_arn #=> String + # @option params + # @option params + # @option params + # @overload list_bucket_metrics_configurations + # @param params [Hash] ({}) + # @return [Types::ListBucketMetricsConfigurationsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListBucketMetricsConfigurationsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListBucketMetricsConfigurationsOutput#continuation_token #continuation_token} => String + # * {Types::ListBucketMetricsConfigurationsOutput#next_continuation_token #next_continuation_token} => String + # * {Types::ListBucketMetricsConfigurationsOutput#metrics_configuration_list #metrics_configuration_list} => Array<Types::MetricsConfiguration> + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketMetricsConfigurations AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#10059 + def list_bucket_metrics_configurations(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns a list of all buckets owned by the authenticated sender of the + # request. To use this operation, you must have the + # `s3:ListAllMyBuckets` permission. + # + # For information about Amazon S3 buckets, see [Creating, configuring, + # and working with Amazon S3 buckets][1]. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/creating-buckets-s3.html + # + # @example Example: To list all buckets + # + # # The following example returns all the buckets owned by the sender of this request. + # + # resp = client.list_buckets({ + # }) + # + # resp.to_h outputs the following: + # { + # buckets: [ + # { + # creation_date: Time.parse("2012-02-15T21:03:02.000Z"), + # name: "examplebucket", + # }, + # { + # creation_date: Time.parse("2011-07-24T19:33:50.000Z"), + # name: "examplebucket2", + # }, + # { + # creation_date: Time.parse("2010-12-17T00:56:49.000Z"), + # name: "examplebucket3", + # }, + # ], + # owner: { + # display_name: "own-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31", + # }, + # } + # @example Response structure + # + # resp.buckets #=> Array + # resp.buckets[0].name #=> String + # resp.buckets[0].creation_date #=> Time + # resp.owner.display_name #=> String + # resp.owner.id #=> String + # @overload list_buckets + # @param params [Hash] ({}) + # @return [Types::ListBucketsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListBucketsOutput#buckets #buckets} => Array<Types::Bucket> + # * {Types::ListBucketsOutput#owner #owner} => Types::Owner + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBuckets AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#10126 + def list_buckets(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns a list of all Amazon S3 directory buckets owned by the + # authenticated sender of the request. For more information about + # directory buckets, see [Directory buckets][1] in the *Amazon S3 User + # Guide*. + # + # Directory buckets - For directory buckets, you must make + # requests for this API operation to the Regional endpoint. These + # endpoints support path-style requests in the format + # `https://s3express-control.region_code.amazonaws.com/bucket-name `. + # Virtual-hosted-style requests aren't supported. For more information, + # see [Regional and Zonal endpoints][2] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # + # : You must have the `s3express:ListAllMyDirectoryBuckets` permission + # in an IAM identity-based policy instead of a bucket policy. + # Cross-account access to this API operation isn't supported. This + # operation can only be performed by the Amazon Web Services account + # that owns the resource. For more information about directory bucket + # policies and permissions, see [Amazon Web Services Identity and + # Access Management (IAM) for S3 Express One Zone][3] in the *Amazon + # S3 User Guide*. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is + # `s3express-control.region.amazonaws.com`. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Request syntax with placeholder values + # + # resp = client.list_directory_buckets({ + # continuation_token: "DirectoryBucketToken", + # max_directory_buckets: 1, + # }) + # @example Response structure + # + # resp.buckets #=> Array + # resp.buckets[0].name #=> String + # resp.buckets[0].creation_date #=> Time + # resp.continuation_token #=> String + # @option params + # @option params + # @overload list_directory_buckets + # @param params [Hash] ({}) + # @return [Types::ListDirectoryBucketsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListDirectoryBucketsOutput#buckets #buckets} => Array<Types::Bucket> + # * {Types::ListDirectoryBucketsOutput#continuation_token #continuation_token} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListDirectoryBuckets AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#10203 + def list_directory_buckets(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation lists in-progress multipart uploads in a bucket. An + # in-progress multipart upload is a multipart upload that has been + # initiated by the `CreateMultipartUpload` request, but has not yet been + # completed or aborted. + # + # **Directory buckets** - If multipart uploads in a directory bucket are + # in progress, you can't delete the bucket until all the in-progress + # multipart uploads are aborted or completed. + # + # + # + # The `ListMultipartUploads` operation returns a maximum of 1,000 + # multipart uploads in the response. The limit of 1,000 multipart + # uploads is also the default value. You can further limit the number of + # uploads in a response by specifying the `max-uploads` request + # parameter. If there are more than 1,000 multipart uploads that satisfy + # your `ListMultipartUploads` request, the response returns an + # `IsTruncated` element with the value of `true`, a `NextKeyMarker` + # element, and a `NextUploadIdMarker` element. To list the remaining + # multipart uploads, you need to make subsequent `ListMultipartUploads` + # requests. In these requests, include two query parameters: + # `key-marker` and `upload-id-marker`. Set the value of `key-marker` to + # the `NextKeyMarker` value from the previous response. Similarly, set + # the value of `upload-id-marker` to the `NextUploadIdMarker` value from + # the previous response. + # + # **Directory buckets** - The `upload-id-marker` element and the + # `NextUploadIdMarker` element aren't supported by directory buckets. + # To list the additional multipart uploads, you only need to set the + # value of `key-marker` to the `NextKeyMarker` value from the previous + # response. + # + # + # + # For more information about multipart uploads, see [Uploading Objects + # Using Multipart Upload][1] in the *Amazon S3 User Guide*. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][2] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - For information about + # permissions required to use the multipart upload API, see + # [Multipart Upload and Permissions][3] in the *Amazon S3 User + # Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][4] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][4]. + # + # Sorting of multipart uploads in response + # : * **General purpose bucket** - In the `ListMultipartUploads` + # response, the multipart uploads are sorted based on two criteria: + # + # * Key-based sorting - Multipart uploads are initially sorted in + # ascending order based on their object keys. + # + # * Time-based sorting - For uploads that share the same object key, + # they are further sorted in ascending order based on the upload + # initiation time. Among uploads with the same key, the one that + # was initiated first will appear before the ones that were + # initiated later. + # + # * **Directory bucket** - In the `ListMultipartUploads` response, the + # multipart uploads aren't sorted lexicographically based on the + # object keys. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `ListMultipartUploads`: + # + # * [CreateMultipartUpload][5] + # + # * [UploadPart][6] + # + # * [CompleteMultipartUpload][7] + # + # * [ListParts][8] + # + # * [AbortMultipartUpload][9] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/uploadobjusingmpu.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list in-progress multipart uploads on a bucket + # + # # The following example lists in-progress multipart uploads on a specific bucket. + # + # resp = client.list_multipart_uploads({ + # bucket: "examplebucket", + # }) + # + # resp.to_h outputs the following: + # { + # uploads: [ + # { + # initiated: Time.parse("2014-05-01T05:40:58.000Z"), + # initiator: { + # display_name: "display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # key: "JavaFile", + # owner: { + # display_name: "display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # storage_class: "STANDARD", + # upload_id: "examplelUa.CInXklLQtSMJITdUnoZ1Y5GACB5UckOtspm5zbDMCkPF_qkfZzMiFZ6dksmcnqxJyIBvQMG9X9Q--", + # }, + # { + # initiated: Time.parse("2014-05-01T05:41:27.000Z"), + # initiator: { + # display_name: "display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # key: "JavaFile", + # owner: { + # display_name: "display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # storage_class: "STANDARD", + # upload_id: "examplelo91lv1iwvWpvCiJWugw2xXLPAD7Z8cJyX9.WiIRgNrdG6Ldsn.9FtS63TCl1Uf5faTB.1U5Ckcbmdw--", + # }, + # ], + # } + # @example Example: List next set of multipart uploads when previous result is truncated + # + # # The following example specifies the upload-id-marker and key-marker from previous truncated response to retrieve next + # # setup of multipart uploads. + # + # resp = client.list_multipart_uploads({ + # bucket: "examplebucket", + # key_marker: "nextkeyfrompreviousresponse", + # max_uploads: 2, + # upload_id_marker: "valuefrompreviousresponse", + # }) + # + # resp.to_h outputs the following: + # { + # bucket: "acl1", + # is_truncated: true, + # key_marker: "", + # max_uploads: 2, + # next_key_marker: "someobjectkey", + # next_upload_id_marker: "examplelo91lv1iwvWpvCiJWugw2xXLPAD7Z8cJyX9.WiIRgNrdG6Ldsn.9FtS63TCl1Uf5faTB.1U5Ckcbmdw--", + # upload_id_marker: "", + # uploads: [ + # { + # initiated: Time.parse("2014-05-01T05:40:58.000Z"), + # initiator: { + # display_name: "ownder-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # key: "JavaFile", + # owner: { + # display_name: "mohanataws", + # id: "852b113e7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # storage_class: "STANDARD", + # upload_id: "gZ30jIqlUa.CInXklLQtSMJITdUnoZ1Y5GACB5UckOtspm5zbDMCkPF_qkfZzMiFZ6dksmcnqxJyIBvQMG9X9Q--", + # }, + # { + # initiated: Time.parse("2014-05-01T05:41:27.000Z"), + # initiator: { + # display_name: "ownder-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # key: "JavaFile", + # owner: { + # display_name: "ownder-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # storage_class: "STANDARD", + # upload_id: "b7tZSqIlo91lv1iwvWpvCiJWugw2xXLPAD7Z8cJyX9.WiIRgNrdG6Ldsn.9FtS63TCl1Uf5faTB.1U5Ckcbmdw--", + # }, + # ], + # } + # @example Request syntax with placeholder values + # + # resp = client.list_multipart_uploads({ + # bucket: "BucketName", # required + # delimiter: "Delimiter", + # encoding_type: "url", # accepts url + # key_marker: "KeyMarker", + # max_uploads: 1, + # prefix: "Prefix", + # upload_id_marker: "UploadIdMarker", + # expected_bucket_owner: "AccountId", + # request_payer: "requester", # accepts requester + # }) + # @example Response structure + # + # resp.bucket #=> String + # resp.key_marker #=> String + # resp.upload_id_marker #=> String + # resp.next_key_marker #=> String + # resp.prefix #=> String + # resp.delimiter #=> String + # resp.next_upload_id_marker #=> String + # resp.max_uploads #=> Integer + # resp.is_truncated #=> Boolean + # resp.uploads #=> Array + # resp.uploads[0].upload_id #=> String + # resp.uploads[0].key #=> String + # resp.uploads[0].initiated #=> Time + # resp.uploads[0].storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "GLACIER", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.uploads[0].owner.display_name #=> String + # resp.uploads[0].owner.id #=> String + # resp.uploads[0].initiator.id #=> String + # resp.uploads[0].initiator.display_name #=> String + # resp.uploads[0].checksum_algorithm #=> String, one of "CRC32", "CRC32C", "SHA1", "SHA256" + # resp.common_prefixes #=> Array + # resp.common_prefixes[0].prefix #=> String + # resp.encoding_type #=> String, one of "url" + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload list_multipart_uploads + # @param params [Hash] ({}) + # @return [Types::ListMultipartUploadsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListMultipartUploadsOutput#bucket #bucket} => String + # * {Types::ListMultipartUploadsOutput#key_marker #key_marker} => String + # * {Types::ListMultipartUploadsOutput#upload_id_marker #upload_id_marker} => String + # * {Types::ListMultipartUploadsOutput#next_key_marker #next_key_marker} => String + # * {Types::ListMultipartUploadsOutput#prefix #prefix} => String + # * {Types::ListMultipartUploadsOutput#delimiter #delimiter} => String + # * {Types::ListMultipartUploadsOutput#next_upload_id_marker #next_upload_id_marker} => String + # * {Types::ListMultipartUploadsOutput#max_uploads #max_uploads} => Integer + # * {Types::ListMultipartUploadsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListMultipartUploadsOutput#uploads #uploads} => Array<Types::MultipartUpload> + # * {Types::ListMultipartUploadsOutput#common_prefixes #common_prefixes} => Array<Types::CommonPrefix> + # * {Types::ListMultipartUploadsOutput#encoding_type #encoding_type} => String + # * {Types::ListMultipartUploadsOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListMultipartUploads AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#10625 + def list_multipart_uploads(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns metadata about all versions of the objects in a bucket. You + # can also use request parameters as selection criteria to return + # metadata about a subset of all the object versions. + # + # To use this operation, you must have permission to perform the + # `s3:ListBucketVersions` action. Be aware of the name difference. + # + # A `200 OK` response can contain valid or invalid XML. Make sure to + # design your application to parse the contents of the response and + # handle it appropriately. + # + # + # + # To use this operation, you must have READ access to the bucket. + # + # The following operations are related to `ListObjectVersions`: + # + # * [ListObjectsV2][1] + # + # * [GetObject][2] + # + # * [PutObject][3] + # + # * [DeleteObject][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObject.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list object versions + # + # # The following example returns versions of an object with specific key name prefix. + # + # resp = client.list_object_versions({ + # bucket: "examplebucket", + # prefix: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # versions: [ + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # is_latest: true, + # key: "HappyFace.jpg", + # last_modified: Time.parse("2016-12-15T01:19:41.000Z"), + # owner: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # size: 3191, + # storage_class: "STANDARD", + # version_id: "null", + # }, + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # is_latest: false, + # key: "HappyFace.jpg", + # last_modified: Time.parse("2016-12-13T00:58:26.000Z"), + # owner: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # size: 3191, + # storage_class: "STANDARD", + # version_id: "PHtexPGjH2y.zBgT8LmB7wwLI2mpbz.k", + # }, + # ], + # } + # @example Request syntax with placeholder values + # + # resp = client.list_object_versions({ + # bucket: "BucketName", # required + # delimiter: "Delimiter", + # encoding_type: "url", # accepts url + # key_marker: "KeyMarker", + # max_keys: 1, + # prefix: "Prefix", + # version_id_marker: "VersionIdMarker", + # expected_bucket_owner: "AccountId", + # request_payer: "requester", # accepts requester + # optional_object_attributes: ["RestoreStatus"], # accepts RestoreStatus + # }) + # @example Response structure + # + # resp.is_truncated #=> Boolean + # resp.key_marker #=> String + # resp.version_id_marker #=> String + # resp.next_key_marker #=> String + # resp.next_version_id_marker #=> String + # resp.versions #=> Array + # resp.versions[0].etag #=> String + # resp.versions[0].checksum_algorithm #=> Array + # resp.versions[0].checksum_algorithm[0] #=> String, one of "CRC32", "CRC32C", "SHA1", "SHA256" + # resp.versions[0].size #=> Integer + # resp.versions[0].storage_class #=> String, one of "STANDARD" + # resp.versions[0].key #=> String + # resp.versions[0].version_id #=> String + # resp.versions[0].is_latest #=> Boolean + # resp.versions[0].last_modified #=> Time + # resp.versions[0].owner.display_name #=> String + # resp.versions[0].owner.id #=> String + # resp.versions[0].restore_status.is_restore_in_progress #=> Boolean + # resp.versions[0].restore_status.restore_expiry_date #=> Time + # resp.delete_markers #=> Array + # resp.delete_markers[0].owner.display_name #=> String + # resp.delete_markers[0].owner.id #=> String + # resp.delete_markers[0].key #=> String + # resp.delete_markers[0].version_id #=> String + # resp.delete_markers[0].is_latest #=> Boolean + # resp.delete_markers[0].last_modified #=> Time + # resp.name #=> String + # resp.prefix #=> String + # resp.delimiter #=> String + # resp.max_keys #=> Integer + # resp.common_prefixes #=> Array + # resp.common_prefixes[0].prefix #=> String + # resp.encoding_type #=> String, one of "url" + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload list_object_versions + # @param params [Hash] ({}) + # @return [Types::ListObjectVersionsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListObjectVersionsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListObjectVersionsOutput#key_marker #key_marker} => String + # * {Types::ListObjectVersionsOutput#version_id_marker #version_id_marker} => String + # * {Types::ListObjectVersionsOutput#next_key_marker #next_key_marker} => String + # * {Types::ListObjectVersionsOutput#next_version_id_marker #next_version_id_marker} => String + # * {Types::ListObjectVersionsOutput#versions #versions} => Array<Types::ObjectVersion> + # * {Types::ListObjectVersionsOutput#delete_markers #delete_markers} => Array<Types::DeleteMarkerEntry> + # * {Types::ListObjectVersionsOutput#name #name} => String + # * {Types::ListObjectVersionsOutput#prefix #prefix} => String + # * {Types::ListObjectVersionsOutput#delimiter #delimiter} => String + # * {Types::ListObjectVersionsOutput#max_keys #max_keys} => Integer + # * {Types::ListObjectVersionsOutput#common_prefixes #common_prefixes} => Array<Types::CommonPrefix> + # * {Types::ListObjectVersionsOutput#encoding_type #encoding_type} => String + # * {Types::ListObjectVersionsOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectVersions AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#10850 + def list_object_versions(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Returns some or all (up to 1,000) of the objects in a bucket. You can + # use the request parameters as selection criteria to return a subset of + # the objects in a bucket. A 200 OK response can contain valid or + # invalid XML. Be sure to design your application to parse the contents + # of the response and handle it appropriately. + # + # This action has been revised. We recommend that you use the newer + # version, [ListObjectsV2][1], when developing applications. For + # backward compatibility, Amazon S3 continues to support `ListObjects`. + # + # The following operations are related to `ListObjects`: + # + # * [ListObjectsV2][1] + # + # * [GetObject][2] + # + # * [PutObject][3] + # + # * [CreateBucket][4] + # + # * [ListBuckets][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjectsV2.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBuckets.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list objects in a bucket + # + # # The following example list two objects in a bucket. + # + # resp = client.list_objects({ + # bucket: "examplebucket", + # max_keys: 2, + # }) + # + # resp.to_h outputs the following: + # { + # contents: [ + # { + # etag: "\"70ee1738b6b21e2c8a43f3a5ab0eee71\"", + # key: "example1.jpg", + # last_modified: Time.parse("2014-11-21T19:40:05.000Z"), + # owner: { + # display_name: "myname", + # id: "12345example25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # size: 11, + # storage_class: "STANDARD", + # }, + # { + # etag: "\"9c8af9a76df052144598c115ef33e511\"", + # key: "example2.jpg", + # last_modified: Time.parse("2013-11-15T01:10:49.000Z"), + # owner: { + # display_name: "myname", + # id: "12345example25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # size: 713193, + # storage_class: "STANDARD", + # }, + # ], + # next_marker: "eyJNYXJrZXIiOiBudWxsLCAiYm90b190cnVuY2F0ZV9hbW91bnQiOiAyfQ==", + # } + # @example Request syntax with placeholder values + # + # resp = client.list_objects({ + # bucket: "BucketName", # required + # delimiter: "Delimiter", + # encoding_type: "url", # accepts url + # marker: "Marker", + # max_keys: 1, + # prefix: "Prefix", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # optional_object_attributes: ["RestoreStatus"], # accepts RestoreStatus + # }) + # @example Response structure + # + # resp.is_truncated #=> Boolean + # resp.marker #=> String + # resp.next_marker #=> String + # resp.contents #=> Array + # resp.contents[0].key #=> String + # resp.contents[0].last_modified #=> Time + # resp.contents[0].etag #=> String + # resp.contents[0].checksum_algorithm #=> Array + # resp.contents[0].checksum_algorithm[0] #=> String, one of "CRC32", "CRC32C", "SHA1", "SHA256" + # resp.contents[0].size #=> Integer + # resp.contents[0].storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "GLACIER", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.contents[0].owner.display_name #=> String + # resp.contents[0].owner.id #=> String + # resp.contents[0].restore_status.is_restore_in_progress #=> Boolean + # resp.contents[0].restore_status.restore_expiry_date #=> Time + # resp.name #=> String + # resp.prefix #=> String + # resp.delimiter #=> String + # resp.max_keys #=> Integer + # resp.common_prefixes #=> Array + # resp.common_prefixes[0].prefix #=> String + # resp.encoding_type #=> String, one of "url" + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload list_objects + # @param params [Hash] ({}) + # @return [Types::ListObjectsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListObjectsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListObjectsOutput#marker #marker} => String + # * {Types::ListObjectsOutput#next_marker #next_marker} => String + # * {Types::ListObjectsOutput#contents #contents} => Array<Types::Object> + # * {Types::ListObjectsOutput#name #name} => String + # * {Types::ListObjectsOutput#prefix #prefix} => String + # * {Types::ListObjectsOutput#delimiter #delimiter} => String + # * {Types::ListObjectsOutput#max_keys #max_keys} => Integer + # * {Types::ListObjectsOutput#common_prefixes #common_prefixes} => Array<Types::CommonPrefix> + # * {Types::ListObjectsOutput#encoding_type #encoding_type} => String + # * {Types::ListObjectsOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjects AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#11070 + def list_objects(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Returns some or all (up to 1,000) of the objects in a bucket with each + # request. You can use the request parameters as selection criteria to + # return a subset of the objects in a bucket. A `200 OK` response can + # contain valid or invalid XML. Make sure to design your application to + # parse the contents of the response and handle it appropriately. For + # more information about listing objects, see [Listing object keys + # programmatically][1] in the *Amazon S3 User Guide*. To get a list of + # your buckets, see [ListBuckets][2]. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][3] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - To use this operation, + # you must have READ access to the bucket. You must have permission + # to perform the `s3:ListBucket` action. The bucket owner has this + # permission by default and can grant this permission to others. For + # more information about permissions, see [Permissions Related to + # Bucket Subresource Operations][4] and [Managing Access Permissions + # to Your Amazon S3 Resources][5] in the *Amazon S3 User Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][6] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][6]. + # + # Sorting order of returned objects + # : * **General purpose bucket** - For general purpose buckets, + # `ListObjectsV2` returns objects in lexicographical order based on + # their key names. + # + # * **Directory bucket** - For directory buckets, `ListObjectsV2` does + # not return objects in lexicographical order. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # This section describes the latest revision of this action. We + # recommend that you use this revised API operation for application + # development. For backward compatibility, Amazon S3 continues to + # support the prior version of this API operation, [ListObjects][7]. + # + # The following operations are related to `ListObjectsV2`: + # + # * [GetObject][8] + # + # * [PutObject][9] + # + # * [CreateBucket][10] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/ListingKeysUsingAPIs.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBuckets.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListObjects.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To get object list + # + # # The following example retrieves object list. The request specifies max keys to limit response to include only 2 object + # # keys. + # + # resp = client.list_objects_v2({ + # bucket: "DOC-EXAMPLE-BUCKET", + # max_keys: 2, + # }) + # + # resp.to_h outputs the following: + # { + # contents: [ + # { + # etag: "\"70ee1738b6b21e2c8a43f3a5ab0eee71\"", + # key: "happyface.jpg", + # last_modified: Time.parse("2014-11-21T19:40:05.000Z"), + # size: 11, + # storage_class: "STANDARD", + # }, + # { + # etag: "\"becf17f89c30367a9a44495d62ed521a-1\"", + # key: "test.jpg", + # last_modified: Time.parse("2014-05-02T04:51:50.000Z"), + # size: 4192256, + # storage_class: "STANDARD", + # }, + # ], + # is_truncated: true, + # key_count: 2, + # max_keys: 2, + # name: "DOC-EXAMPLE-BUCKET", + # next_continuation_token: "1w41l63U0xa8q7smH50vCxyTQqdxo69O3EmK28Bi5PcROI4wI/EyIJg==", + # prefix: "", + # } + # @example Request syntax with placeholder values + # + # resp = client.list_objects_v2({ + # bucket: "BucketName", # required + # delimiter: "Delimiter", + # encoding_type: "url", # accepts url + # max_keys: 1, + # prefix: "Prefix", + # continuation_token: "Token", + # fetch_owner: false, + # start_after: "StartAfter", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # optional_object_attributes: ["RestoreStatus"], # accepts RestoreStatus + # }) + # @example Response structure + # + # resp.is_truncated #=> Boolean + # resp.contents #=> Array + # resp.contents[0].key #=> String + # resp.contents[0].last_modified #=> Time + # resp.contents[0].etag #=> String + # resp.contents[0].checksum_algorithm #=> Array + # resp.contents[0].checksum_algorithm[0] #=> String, one of "CRC32", "CRC32C", "SHA1", "SHA256" + # resp.contents[0].size #=> Integer + # resp.contents[0].storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "GLACIER", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.contents[0].owner.display_name #=> String + # resp.contents[0].owner.id #=> String + # resp.contents[0].restore_status.is_restore_in_progress #=> Boolean + # resp.contents[0].restore_status.restore_expiry_date #=> Time + # resp.name #=> String + # resp.prefix #=> String + # resp.delimiter #=> String + # resp.max_keys #=> Integer + # resp.common_prefixes #=> Array + # resp.common_prefixes[0].prefix #=> String + # resp.encoding_type #=> String, one of "url" + # resp.key_count #=> Integer + # resp.continuation_token #=> String + # resp.next_continuation_token #=> String + # resp.start_after #=> String + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload list_objects_v2 + # @param params [Hash] ({}) + # @return [Types::ListObjectsV2Output] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListObjectsV2Output#is_truncated #is_truncated} => Boolean + # * {Types::ListObjectsV2Output#contents #contents} => Array<Types::Object> + # * {Types::ListObjectsV2Output#name #name} => String + # * {Types::ListObjectsV2Output#prefix #prefix} => String + # * {Types::ListObjectsV2Output#delimiter #delimiter} => String + # * {Types::ListObjectsV2Output#max_keys #max_keys} => Integer + # * {Types::ListObjectsV2Output#common_prefixes #common_prefixes} => Array<Types::CommonPrefix> + # * {Types::ListObjectsV2Output#encoding_type #encoding_type} => String + # * {Types::ListObjectsV2Output#key_count #key_count} => Integer + # * {Types::ListObjectsV2Output#continuation_token #continuation_token} => String + # * {Types::ListObjectsV2Output#next_continuation_token #next_continuation_token} => String + # * {Types::ListObjectsV2Output#start_after #start_after} => String + # * {Types::ListObjectsV2Output#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsV2 AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#11386 + def list_objects_v2(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Lists the parts that have been uploaded for a specific multipart + # upload. + # + # To use this operation, you must provide the `upload ID` in the + # request. You obtain this uploadID by sending the initiate multipart + # upload request through [CreateMultipartUpload][1]. + # + # The `ListParts` request returns a maximum of 1,000 uploaded parts. The + # limit of 1,000 parts is also the default value. You can restrict the + # number of parts in a response by specifying the `max-parts` request + # parameter. If your multipart upload consists of more than 1,000 parts, + # the response returns an `IsTruncated` field with the value of `true`, + # and a `NextPartNumberMarker` element. To list remaining uploaded + # parts, in subsequent `ListParts` requests, include the + # `part-number-marker` query string parameter and set its value to the + # `NextPartNumberMarker` field value from the previous response. + # + # For more information on multipart uploads, see [Uploading Objects + # Using Multipart Upload][2] in the *Amazon S3 User Guide*. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][3] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - For information about + # permissions required to use the multipart upload API, see + # [Multipart Upload and Permissions][4] in the *Amazon S3 User + # Guide*. + # + # If the upload was created using server-side encryption with Key + # Management Service (KMS) keys (SSE-KMS) or dual-layer server-side + # encryption with Amazon Web Services KMS keys (DSSE-KMS), you must + # have permission to the `kms:Decrypt` action for the `ListParts` + # request to succeed. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][5] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][5]. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `ListParts`: + # + # * [CreateMultipartUpload][1] + # + # * [UploadPart][6] + # + # * [CompleteMultipartUpload][7] + # + # * [AbortMultipartUpload][8] + # + # * [GetObjectAttributes][9] + # + # * [ListMultipartUploads][10] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/uploadobjusingmpu.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html + # + # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. + # + # @example Example: To list parts of a multipart upload. + # + # # The following example lists parts uploaded for a specific multipart upload. + # + # resp = client.list_parts({ + # bucket: "examplebucket", + # key: "bigobject", + # upload_id: "example7YPBOJuoFiQ9cz4P3Pe6FIZwO4f7wN93uHsNBEw97pl5eNwzExg0LAT2dUN91cOmrEQHDsP3WA60CEg--", + # }) + # + # resp.to_h outputs the following: + # { + # initiator: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # owner: { + # display_name: "owner-display-name", + # id: "examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484be31bebcc", + # }, + # parts: [ + # { + # etag: "\"d8c2eafd90c266e19ab9dcacc479f8af\"", + # last_modified: Time.parse("2016-12-16T00:11:42.000Z"), + # part_number: 1, + # size: 26246026, + # }, + # { + # etag: "\"d8c2eafd90c266e19ab9dcacc479f8af\"", + # last_modified: Time.parse("2016-12-16T00:15:01.000Z"), + # part_number: 2, + # size: 26246026, + # }, + # ], + # storage_class: "STANDARD", + # } + # @example Request syntax with placeholder values + # + # resp = client.list_parts({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # max_parts: 1, + # part_number_marker: 1, + # upload_id: "MultipartUploadId", # required + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # }) + # @example Response structure + # + # resp.abort_date #=> Time + # resp.abort_rule_id #=> String + # resp.bucket #=> String + # resp.key #=> String + # resp.upload_id #=> String + # resp.part_number_marker #=> Integer + # resp.next_part_number_marker #=> Integer + # resp.max_parts #=> Integer + # resp.is_truncated #=> Boolean + # resp.parts #=> Array + # resp.parts[0].part_number #=> Integer + # resp.parts[0].last_modified #=> Time + # resp.parts[0].etag #=> String + # resp.parts[0].size #=> Integer + # resp.parts[0].checksum_crc32 #=> String + # resp.parts[0].checksum_crc32c #=> String + # resp.parts[0].checksum_sha1 #=> String + # resp.parts[0].checksum_sha256 #=> String + # resp.initiator.id #=> String + # resp.initiator.display_name #=> String + # resp.owner.display_name #=> String + # resp.owner.id #=> String + # resp.storage_class #=> String, one of "STANDARD", "REDUCED_REDUNDANCY", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "GLACIER", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW", "EXPRESS_ONEZONE" + # resp.request_charged #=> String, one of "requester" + # resp.checksum_algorithm #=> String, one of "CRC32", "CRC32C", "SHA1", "SHA256" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload list_parts + # @param params [Hash] ({}) + # @return [Types::ListPartsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListPartsOutput#abort_date #abort_date} => Time + # * {Types::ListPartsOutput#abort_rule_id #abort_rule_id} => String + # * {Types::ListPartsOutput#bucket #bucket} => String + # * {Types::ListPartsOutput#key #key} => String + # * {Types::ListPartsOutput#upload_id #upload_id} => String + # * {Types::ListPartsOutput#part_number_marker #part_number_marker} => Integer + # * {Types::ListPartsOutput#next_part_number_marker #next_part_number_marker} => Integer + # * {Types::ListPartsOutput#max_parts #max_parts} => Integer + # * {Types::ListPartsOutput#is_truncated #is_truncated} => Boolean + # * {Types::ListPartsOutput#parts #parts} => Array<Types::Part> + # * {Types::ListPartsOutput#initiator #initiator} => Types::Initiator + # * {Types::ListPartsOutput#owner #owner} => Types::Owner + # * {Types::ListPartsOutput#storage_class #storage_class} => String + # * {Types::ListPartsOutput#request_charged #request_charged} => String + # * {Types::ListPartsOutput#checksum_algorithm #checksum_algorithm} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListParts AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#11706 + def list_parts(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the accelerate configuration of an existing bucket. Amazon S3 + # Transfer Acceleration is a bucket-level feature that enables you to + # perform faster data transfers to Amazon S3. + # + # To use this operation, you must have permission to perform the + # `s3:PutAccelerateConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # The Transfer Acceleration state of a bucket can be set to one of the + # following two values: + # + # * Enabled – Enables accelerated data transfers to the bucket. + # + # * Suspended – Disables accelerated data transfers to the bucket. + # + # The [GetBucketAccelerateConfiguration][3] action returns the transfer + # acceleration state of a bucket. + # + # After setting the Transfer Acceleration state of a bucket to Enabled, + # it might take up to thirty minutes before the data transfer rates to + # the bucket increase. + # + # The name of the bucket used for Transfer Acceleration must be + # DNS-compliant and must not contain periods ("."). + # + # For more information about transfer acceleration, see [Transfer + # Acceleration][4]. + # + # The following operations are related to + # `PutBucketAccelerateConfiguration`: + # + # * [GetBucketAccelerateConfiguration][3] + # + # * [CreateBucket][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketAccelerateConfiguration.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acceleration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_accelerate_configuration({ + # bucket: "BucketName", # required + # accelerate_configuration: { # required + # status: "Enabled", # accepts Enabled, Suspended + # }, + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_accelerate_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAccelerateConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#11805 + def put_bucket_accelerate_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the permissions on an existing bucket using access control lists + # (ACL). For more information, see [Using ACLs][1]. To set the ACL of a + # bucket, you must have the `WRITE_ACP` permission. + # + # You can use one of the following two ways to set a bucket's + # permissions: + # + # * Specify the ACL in the request body + # + # * Specify permissions using request headers + # + # You cannot specify access permission using both the body and the + # request headers. + # + # + # + # Depending on your application needs, you may choose to set the ACL on + # a bucket using either the request body or the headers. For example, if + # you have an existing application that updates a bucket ACL using the + # request body, then you can continue to use that approach. + # + # If your bucket uses the bucket owner enforced setting for S3 Object + # Ownership, ACLs are disabled and no longer affect permissions. You + # must use policies to grant access to your bucket and the objects in + # it. Requests to set ACLs or update ACLs fail and return the + # `AccessControlListNotSupported` error code. Requests to read ACLs are + # still supported. For more information, see [Controlling object + # ownership][2] in the *Amazon S3 User Guide*. + # + # Permissions + # + # : You can set access permissions by using one of the following + # methods: + # + # * Specify a canned ACL with the `x-amz-acl` request header. Amazon + # S3 supports a set of predefined ACLs, known as *canned ACLs*. Each + # canned ACL has a predefined set of grantees and permissions. + # Specify the canned ACL name as the value of `x-amz-acl`. If you + # use this header, you cannot use other access control-specific + # headers in your request. For more information, see [Canned + # ACL][3]. + # + # * Specify access permissions explicitly with the `x-amz-grant-read`, + # `x-amz-grant-read-acp`, `x-amz-grant-write-acp`, and + # `x-amz-grant-full-control` headers. When using these headers, you + # specify explicit access permissions and grantees (Amazon Web + # Services accounts or Amazon S3 groups) who will receive the + # permission. If you use these ACL-specific headers, you cannot use + # the `x-amz-acl` header to set a canned ACL. These parameters map + # to the set of permissions that Amazon S3 supports in an ACL. For + # more information, see [Access Control List (ACL) Overview][4]. + # + # You specify each grantee as a type=value pair, where the type is + # one of the following: + # + # * `id` – if the value specified is the canonical user ID of an + # Amazon Web Services account + # + # * `uri` – if you are granting permissions to a predefined group + # + # * `emailAddress` – if the value specified is the email address of + # an Amazon Web Services account + # + # Using email addresses to specify a grantee is only supported in + # the following Amazon Web Services Regions: + # + # * US East (N. Virginia) + # + # * US West (N. California) + # + # * US West (Oregon) + # + # * Asia Pacific (Singapore) + # + # * Asia Pacific (Sydney) + # + # * Asia Pacific (Tokyo) + # + # * Europe (Ireland) + # + # * South America (São Paulo) + # + # For a list of all the Amazon S3 supported Regions and endpoints, + # see [Regions and Endpoints][5] in the Amazon Web Services + # General Reference. + # + # + # + # For example, the following `x-amz-grant-write` header grants + # create, overwrite, and delete objects permission to LogDelivery + # group predefined by Amazon S3 and two Amazon Web Services accounts + # identified by their email addresses. + # + # `x-amz-grant-write: + # uri="http://acs.amazonaws.com/groups/s3/LogDelivery", + # id="111122223333", id="555566667777" ` + # + # You can use either a canned ACL or specify access permissions + # explicitly. You cannot do both. + # + # Grantee Values + # + # : You can specify the person (grantee) to whom you're assigning + # access rights (using request elements) in the following ways: + # + # * By the person's ID: + # + # `<>ID<><>GranteesEmail<> + # ` + # + # DisplayName is optional and ignored in the request + # + # * By URI: + # + # `<>http://acs.amazonaws.com/groups/global/AuthenticatedUsers<>` + # + # * By Email address: + # + # `<>Grantees@email.com<>&` + # + # The grantee is resolved to the CanonicalUser and, in a response to + # a GET Object acl request, appears as the CanonicalUser. + # + # Using email addresses to specify a grantee is only supported in + # the following Amazon Web Services Regions: + # + # * US East (N. Virginia) + # + # * US West (N. California) + # + # * US West (Oregon) + # + # * Asia Pacific (Singapore) + # + # * Asia Pacific (Sydney) + # + # * Asia Pacific (Tokyo) + # + # * Europe (Ireland) + # + # * South America (São Paulo) + # + # For a list of all the Amazon S3 supported Regions and endpoints, + # see [Regions and Endpoints][5] in the Amazon Web Services General + # Reference. + # + # + # + # The following operations are related to `PutBucketAcl`: + # + # * [CreateBucket][6] + # + # * [DeleteBucket][7] + # + # * [GetObjectAcl][8] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/S3_ACLs_UsingACLs.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html + # [5]: https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_region + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucket.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html + # + # @example Example: Put bucket acl + # + # # The following example replaces existing ACL on a bucket. The ACL grants the bucket owner (specified using the owner ID) + # # and write permission to the LogDelivery group. Because this is a replace operation, you must specify all the grants in + # # your request. To incrementally add or remove ACL grants, you might use the console. + # + # resp = client.put_bucket_acl({ + # bucket: "examplebucket", + # grant_full_control: "id=examplee7a2f25102679df27bb0ae12b3f85be6f290b936c4393484", + # grant_write: "uri=http://acs.amazonaws.com/groups/s3/LogDelivery", + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_acl({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read + # access_control_policy: { + # grants: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, WRITE, WRITE_ACP, READ, READ_ACP + # }, + # ], + # owner: { + # display_name: "DisplayName", + # id: "ID", + # }, + # }, + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write: "GrantWrite", + # grant_write_acp: "GrantWriteACP", + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_acl + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAcl AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#12099 + def put_bucket_acl(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets an analytics configuration for the bucket (specified by the + # analytics configuration ID). You can have up to 1,000 analytics + # configurations per bucket. + # + # You can choose to have storage class analysis export analysis reports + # sent to a comma-separated values (CSV) flat file. See the `DataExport` + # request element. Reports are updated daily and are based on the object + # filters that you configure. When selecting data export, you specify a + # destination bucket and an optional destination prefix where the file + # is written. You can export the data to a destination bucket in a + # different account. However, the destination bucket must be in the same + # Region as the bucket that you are making the PUT analytics + # configuration to. For more information, see [Amazon S3 Analytics – + # Storage Class Analysis][1]. + # + # You must create a bucket policy on the destination bucket where the + # exported file is written to grant permissions to Amazon S3 to write + # objects to the bucket. For an example policy, see [Granting + # Permissions for Amazon S3 Inventory and Storage Class Analysis][2]. + # + # To use this operation, you must have permissions to perform the + # `s3:PutAnalyticsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][3] and [Managing Access + # Permissions to Your Amazon S3 Resources][4]. + # + # `PutBucketAnalyticsConfiguration` has the following special errors: + # + # * * *HTTP Error: HTTP 400 Bad Request* + # + # * *Code: InvalidArgument* + # + # * *Cause: Invalid argument.* + # + # * * *HTTP Error: HTTP 400 Bad Request* + # + # * *Code: TooManyConfigurations* + # + # * *Cause: You are attempting to create a new configuration but have + # already reached the 1,000-configuration limit.* + # + # * * *HTTP Error: HTTP 403 Forbidden* + # + # * *Code: AccessDenied* + # + # * *Cause: You are not the owner of the specified bucket, or you do + # not have the s3:PutAnalyticsConfiguration bucket permission to set + # the configuration on the bucket.* + # + # The following operations are related to + # `PutBucketAnalyticsConfiguration`: + # + # * [GetBucketAnalyticsConfiguration][5] + # + # * [DeleteBucketAnalyticsConfiguration][6] + # + # * [ListBucketAnalyticsConfigurations][7] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/analytics-storage-class.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/example-bucket-policies.html#example-bucket-policies-use-case-9 + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketAnalyticsConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketAnalyticsConfiguration.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketAnalyticsConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_analytics_configuration({ + # bucket: "BucketName", # required + # id: "AnalyticsId", # required + # analytics_configuration: { # required + # id: "AnalyticsId", # required + # filter: { + # prefix: "Prefix", + # tag: { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # and: { + # prefix: "Prefix", + # tags: [ + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # }, + # storage_class_analysis: { # required + # data_export: { + # output_schema_version: "V_1", # required, accepts V_1 + # destination: { # required + # s3_bucket_destination: { # required + # format: "CSV", # required, accepts CSV + # bucket_account_id: "AccountId", + # bucket: "BucketName", # required + # prefix: "Prefix", + # }, + # }, + # }, + # }, + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_analytics_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAnalyticsConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#12237 + def put_bucket_analytics_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the `cors` configuration for your bucket. If the configuration + # exists, Amazon S3 replaces it. + # + # To use this operation, you must be allowed to perform the + # `s3:PutBucketCORS` action. By default, the bucket owner has this + # permission and can grant it to others. + # + # You set this configuration on a bucket so that the bucket can service + # cross-origin requests. For example, you might want to enable a request + # whose origin is `http://www.example.com` to access your Amazon S3 + # bucket at `my.example.bucket.com` by using the browser's + # `XMLHttpRequest` capability. + # + # To enable cross-origin resource sharing (CORS) on a bucket, you add + # the `cors` subresource to the bucket. The `cors` subresource is an XML + # document in which you configure rules that identify origins and the + # HTTP methods that can be executed on your bucket. The document is + # limited to 64 KB in size. + # + # When Amazon S3 receives a cross-origin request (or a pre-flight + # OPTIONS request) against a bucket, it evaluates the `cors` + # configuration on the bucket and uses the first `CORSRule` rule that + # matches the incoming browser request to enable a cross-origin request. + # For a rule to match, the following conditions must be met: + # + # * The request's `Origin` header must match `AllowedOrigin` elements. + # + # * The request method (for example, GET, PUT, HEAD, and so on) or the + # `Access-Control-Request-Method` header in case of a pre-flight + # `OPTIONS` request must be one of the `AllowedMethod` elements. + # + # * Every header specified in the `Access-Control-Request-Headers` + # request header of a pre-flight request must match an `AllowedHeader` + # element. + # + # For more information about CORS, go to [Enabling Cross-Origin Resource + # Sharing][1] in the *Amazon S3 User Guide*. + # + # The following operations are related to `PutBucketCors`: + # + # * [GetBucketCors][2] + # + # * [DeleteBucketCors][3] + # + # * [RESTOPTIONSobject][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cors.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketCors.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketCors.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTOPTIONSobject.html + # + # @example Example: To set cors configuration on a bucket. + # + # # The following example enables PUT, POST, and DELETE requests from www.example.com, and enables GET requests from any + # # domain. + # + # resp = client.put_bucket_cors({ + # bucket: "", + # cors_configuration: { + # cors_rules: [ + # { + # allowed_headers: [ + # "*", + # ], + # allowed_methods: [ + # "PUT", + # "POST", + # "DELETE", + # ], + # allowed_origins: [ + # "http://www.example.com", + # ], + # expose_headers: [ + # "x-amz-server-side-encryption", + # ], + # max_age_seconds: 3000, + # }, + # { + # allowed_headers: [ + # "Authorization", + # ], + # allowed_methods: [ + # "GET", + # ], + # allowed_origins: [ + # "*", + # ], + # max_age_seconds: 3000, + # }, + # ], + # }, + # content_md5: "", + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_cors({ + # bucket: "BucketName", # required + # cors_configuration: { # required + # cors_rules: [ # required + # { + # id: "ID", + # allowed_headers: ["AllowedHeader"], + # allowed_methods: ["AllowedMethod"], # required + # allowed_origins: ["AllowedOrigin"], # required + # expose_headers: ["ExposeHeader"], + # max_age_seconds: 1, + # }, + # ], + # }, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_cors + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketCors AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#12416 + def put_bucket_cors(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This action uses the `encryption` subresource to configure default + # encryption and Amazon S3 Bucket Keys for an existing bucket. + # + # By default, all buckets have a default encryption configuration that + # uses server-side encryption with Amazon S3 managed keys (SSE-S3). You + # can optionally configure default encryption for a bucket by using + # server-side encryption with Key Management Service (KMS) keys + # (SSE-KMS) or dual-layer server-side encryption with Amazon Web + # Services KMS keys (DSSE-KMS). If you specify default encryption by + # using SSE-KMS, you can also configure [Amazon S3 Bucket Keys][1]. If + # you use PutBucketEncryption to set your [default bucket encryption][2] + # to SSE-KMS, you should verify that your KMS key ID is correct. Amazon + # S3 does not validate the KMS key ID provided in PutBucketEncryption + # requests. + # + # This action requires Amazon Web Services Signature Version 4. For more + # information, see [ Authenticating Requests (Amazon Web Services + # Signature Version 4)][3]. + # + # To use this operation, you must have permission to perform the + # `s3:PutEncryptionConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][4] and [Managing Access + # Permissions to Your Amazon S3 Resources][5] in the *Amazon S3 User + # Guide*. + # + # The following operations are related to `PutBucketEncryption`: + # + # * [GetBucketEncryption][6] + # + # * [DeleteBucketEncryption][7] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-key.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketEncryption.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketEncryption.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_encryption({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # server_side_encryption_configuration: { # required + # rules: [ # required + # { + # apply_server_side_encryption_by_default: { + # sse_algorithm: "AES256", # required, accepts AES256, aws:kms, aws:kms:dsse + # kms_master_key_id: "SSEKMSKeyId", + # }, + # bucket_key_enabled: false, + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_encryption + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketEncryption AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#12540 + def put_bucket_encryption(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Puts a S3 Intelligent-Tiering configuration to the specified bucket. + # You can have up to 1,000 S3 Intelligent-Tiering configurations per + # bucket. + # + # The S3 Intelligent-Tiering storage class is designed to optimize + # storage costs by automatically moving data to the most cost-effective + # storage access tier, without performance impact or operational + # overhead. S3 Intelligent-Tiering delivers automatic cost savings in + # three low latency and high throughput access tiers. To get the lowest + # storage cost on data that can be accessed in minutes to hours, you can + # choose to activate additional archiving capabilities. + # + # The S3 Intelligent-Tiering storage class is the ideal storage class + # for data with unknown, changing, or unpredictable access patterns, + # independent of object size or retention period. If the size of an + # object is less than 128 KB, it is not monitored and not eligible for + # auto-tiering. Smaller objects can be stored, but they are always + # charged at the Frequent Access tier rates in the S3 + # Intelligent-Tiering storage class. + # + # For more information, see [Storage class for automatically optimizing + # frequently and infrequently accessed objects][1]. + # + # Operations related to `PutBucketIntelligentTieringConfiguration` + # include: + # + # * [DeleteBucketIntelligentTieringConfiguration][2] + # + # * [GetBucketIntelligentTieringConfiguration][3] + # + # * [ListBucketIntelligentTieringConfigurations][4] + # + # You only need S3 Intelligent-Tiering enabled on a bucket if you want + # to automatically move objects stored in the S3 Intelligent-Tiering + # storage class to the Archive Access or Deep Archive Access tier. + # + # + # + # `PutBucketIntelligentTieringConfiguration` has the following special + # errors: + # + # HTTP 400 Bad Request Error + # + # : *Code:* InvalidArgument + # + # *Cause:* Invalid Argument + # + # HTTP 400 Bad Request Error + # + # : *Code:* TooManyConfigurations + # + # *Cause:* You are attempting to create a new configuration but have + # already reached the 1,000-configuration limit. + # + # HTTP 403 Forbidden Error + # + # : *Cause:* You are not the owner of the specified bucket, or you do + # not have the `s3:PutIntelligentTieringConfiguration` bucket + # permission to set the configuration on the bucket. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html#sc-dynamic-data-access + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketIntelligentTieringConfiguration.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketIntelligentTieringConfiguration.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketIntelligentTieringConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_intelligent_tiering_configuration({ + # bucket: "BucketName", # required + # id: "IntelligentTieringId", # required + # intelligent_tiering_configuration: { # required + # id: "IntelligentTieringId", # required + # filter: { + # prefix: "Prefix", + # tag: { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # and: { + # prefix: "Prefix", + # tags: [ + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # }, + # status: "Enabled", # required, accepts Enabled, Disabled + # tierings: [ # required + # { + # days: 1, # required + # access_tier: "ARCHIVE_ACCESS", # required, accepts ARCHIVE_ACCESS, DEEP_ARCHIVE_ACCESS + # }, + # ], + # }, + # }) + # @option params + # @option params + # @option params + # @overload put_bucket_intelligent_tiering_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketIntelligentTieringConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#12665 + def put_bucket_intelligent_tiering_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This implementation of the `PUT` action adds an inventory + # configuration (identified by the inventory ID) to the bucket. You can + # have up to 1,000 inventory configurations per bucket. + # + # Amazon S3 inventory generates inventories of the objects in the bucket + # on a daily or weekly basis, and the results are published to a flat + # file. The bucket that is inventoried is called the *source* bucket, + # and the bucket where the inventory flat file is stored is called the + # *destination* bucket. The *destination* bucket must be in the same + # Amazon Web Services Region as the *source* bucket. + # + # When you configure an inventory for a *source* bucket, you specify the + # *destination* bucket where you want the inventory to be stored, and + # whether to generate the inventory daily or weekly. You can also + # configure what object metadata to include and whether to inventory all + # object versions or only current versions. For more information, see + # [Amazon S3 Inventory][1] in the Amazon S3 User Guide. + # + # You must create a bucket policy on the *destination* bucket to grant + # permissions to Amazon S3 to write objects to the bucket in the defined + # location. For an example policy, see [ Granting Permissions for Amazon + # S3 Inventory and Storage Class Analysis][2]. + # + # Permissions + # + # : To use this operation, you must have permission to perform the + # `s3:PutInventoryConfiguration` action. The bucket owner has this + # permission by default and can grant this permission to others. + # + # The `s3:PutInventoryConfiguration` permission allows a user to + # create an [S3 Inventory][3] report that includes all object metadata + # fields available and to specify the destination bucket to store the + # inventory. A user with read access to objects in the destination + # bucket can also access all object metadata fields that are available + # in the inventory report. + # + # To restrict access to an inventory report, see [Restricting access + # to an Amazon S3 Inventory report][4] in the *Amazon S3 User Guide*. + # For more information about the metadata fields available in S3 + # Inventory, see [Amazon S3 Inventory lists][5] in the *Amazon S3 User + # Guide*. For more information about permissions, see [Permissions + # related to bucket subresource operations][6] and [Identity and + # access management in Amazon S3][7] in the *Amazon S3 User Guide*. + # + # `PutBucketInventoryConfiguration` has the following special errors: + # + # HTTP 400 Bad Request Error + # + # : *Code:* InvalidArgument + # + # *Cause:* Invalid Argument + # + # HTTP 400 Bad Request Error + # + # : *Code:* TooManyConfigurations + # + # *Cause:* You are attempting to create a new configuration but have + # already reached the 1,000-configuration limit. + # + # HTTP 403 Forbidden Error + # + # : *Cause:* You are not the owner of the specified bucket, or you do + # not have the `s3:PutInventoryConfiguration` bucket permission to set + # the configuration on the bucket. + # + # The following operations are related to + # `PutBucketInventoryConfiguration`: + # + # * [GetBucketInventoryConfiguration][8] + # + # * [DeleteBucketInventoryConfiguration][9] + # + # * [ListBucketInventoryConfigurations][10] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-inventory.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/example-bucket-policies.html#example-bucket-policies-use-case-9 + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/storage-inventory.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/example-bucket-policies.html#example-bucket-policies-use-case-10 + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/storage-inventory.html#storage-inventory-contents + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketInventoryConfiguration.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketInventoryConfiguration.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketInventoryConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_inventory_configuration({ + # bucket: "BucketName", # required + # id: "InventoryId", # required + # inventory_configuration: { # required + # destination: { # required + # s3_bucket_destination: { # required + # account_id: "AccountId", + # bucket: "BucketName", # required + # format: "CSV", # required, accepts CSV, ORC, Parquet + # prefix: "Prefix", + # encryption: { + # sses3: { + # }, + # ssekms: { + # key_id: "SSEKMSKeyId", # required + # }, + # }, + # }, + # }, + # is_enabled: false, # required + # filter: { + # prefix: "Prefix", # required + # }, + # id: "InventoryId", # required + # included_object_versions: "All", # required, accepts All, Current + # optional_fields: ["Size"], # accepts Size, LastModifiedDate, StorageClass, ETag, IsMultipartUploaded, ReplicationStatus, EncryptionStatus, ObjectLockRetainUntilDate, ObjectLockMode, ObjectLockLegalHoldStatus, IntelligentTieringAccessTier, BucketKeyStatus, ChecksumAlgorithm, ObjectAccessControlList, ObjectOwner + # schedule: { # required + # frequency: "Daily", # required, accepts Daily, Weekly + # }, + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_inventory_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketInventoryConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#12817 + def put_bucket_inventory_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # For an updated version of this API, see + # [PutBucketLifecycleConfiguration][1]. This version has been + # deprecated. Existing lifecycle configurations will work. For new + # lifecycle configurations, use the updated API. + # + # Creates a new lifecycle configuration for the bucket or replaces an + # existing lifecycle configuration. For information about lifecycle + # configuration, see [Object Lifecycle Management][2] in the *Amazon S3 + # User Guide*. + # + # By default, all Amazon S3 resources, including buckets, objects, and + # related subresources (for example, lifecycle configuration and website + # configuration) are private. Only the resource owner, the Amazon Web + # Services account that created the resource, can access it. The + # resource owner can optionally grant access permissions to others by + # writing an access policy. For this operation, users must get the + # `s3:PutLifecycleConfiguration` permission. + # + # You can also explicitly deny permissions. Explicit denial also + # supersedes any other permissions. If you want to prevent users or + # accounts from removing or deleting objects from your bucket, you must + # deny them permissions for the following actions: + # + # * `s3:DeleteObject` + # + # * `s3:DeleteObjectVersion` + # + # * `s3:PutLifecycleConfiguration` + # + # For more information about permissions, see [Managing Access + # Permissions to your Amazon S3 Resources][3] in the *Amazon S3 User + # Guide*. + # + # For more examples of transitioning objects to storage classes such as + # STANDARD\_IA or ONEZONE\_IA, see [Examples of Lifecycle + # Configuration][4]. + # + # The following operations are related to `PutBucketLifecycle`: + # + # * [GetBucketLifecycle][5](Deprecated) + # + # * [GetBucketLifecycleConfiguration][6] + # + # * [RestoreObject][7] + # + # * By default, a resource owner—in this case, a bucket owner, which is + # the Amazon Web Services account that created the bucket—can perform + # any of the operations. A resource owner can also grant others + # permission to perform the operation. For more information, see the + # following topics in the Amazon S3 User Guide: + # + # * [Specifying Permissions in a Policy][8] + # + # * [Managing Access Permissions to your Amazon S3 Resources][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/intro-lifecycle-rules.html#lifecycle-configuration-examples + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycle.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycleConfiguration.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_lifecycle({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # lifecycle_configuration: { + # rules: [ # required + # { + # expiration: { + # date: Time.now, + # days: 1, + # expired_object_delete_marker: false, + # }, + # id: "ID", + # prefix: "Prefix", # required + # status: "Enabled", # required, accepts Enabled, Disabled + # transition: { + # date: Time.now, + # days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # }, + # noncurrent_version_transition: { + # noncurrent_days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # newer_noncurrent_versions: 1, + # }, + # noncurrent_version_expiration: { + # noncurrent_days: 1, + # newer_noncurrent_versions: 1, + # }, + # abort_incomplete_multipart_upload: { + # days_after_initiation: 1, + # }, + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_lifecycle + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycle AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#12968 + def put_bucket_lifecycle(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Creates a new lifecycle configuration for the bucket or replaces an + # existing lifecycle configuration. Keep in mind that this will + # overwrite an existing lifecycle configuration, so if you want to + # retain any configuration details, they must be included in the new + # lifecycle configuration. For information about lifecycle + # configuration, see [Managing your storage lifecycle][1]. + # + # Bucket lifecycle configuration now supports specifying a lifecycle + # rule using an object key name prefix, one or more object tags, object + # size, or any combination of these. Accordingly, this section describes + # the latest API. The previous version of the API supported filtering + # based only on an object key name prefix, which is supported for + # backward compatibility. For the related API description, see + # [PutBucketLifecycle][2]. + # + # + # + # Rules + # + # : You specify the lifecycle configuration in your request body. The + # lifecycle configuration is specified as XML consisting of one or + # more rules. An Amazon S3 Lifecycle configuration can have up to + # 1,000 rules. This limit is not adjustable. Each rule consists of the + # following: + # + # * A filter identifying a subset of objects to which the rule + # applies. The filter can be based on a key name prefix, object + # tags, object size, or any combination of these. + # + # * A status indicating whether the rule is in effect. + # + # * One or more lifecycle transition and expiration actions that you + # want Amazon S3 to perform on the objects identified by the filter. + # If the state of your bucket is versioning-enabled or + # versioning-suspended, you can have many versions of the same + # object (one current version and zero or more noncurrent versions). + # Amazon S3 provides predefined actions that you can specify for + # current and noncurrent object versions. + # + # For more information, see [Object Lifecycle Management][3] and + # [Lifecycle Configuration Elements][4]. + # + # Permissions + # + # : By default, all Amazon S3 resources are private, including buckets, + # objects, and related subresources (for example, lifecycle + # configuration and website configuration). Only the resource owner + # (that is, the Amazon Web Services account that created it) can + # access the resource. The resource owner can optionally grant access + # permissions to others by writing an access policy. For this + # operation, a user must get the `s3:PutLifecycleConfiguration` + # permission. + # + # You can also explicitly deny permissions. An explicit deny also + # supersedes any other permissions. If you want to block users or + # accounts from removing or deleting objects from your bucket, you + # must deny them permissions for the following actions: + # + # * `s3:DeleteObject` + # + # * `s3:DeleteObjectVersion` + # + # * `s3:PutLifecycleConfiguration` + # + # For more information about permissions, see [Managing Access + # Permissions to Your Amazon S3 Resources][5]. + # + # The following operations are related to + # `PutBucketLifecycleConfiguration`: + # + # * [Examples of Lifecycle Configuration][6] + # + # * [GetBucketLifecycleConfiguration][7] + # + # * [DeleteBucketLifecycle][8] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lifecycle-mgmt.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycle.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/intro-lifecycle-rules.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/lifecycle-configuration-examples.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycleConfiguration.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketLifecycle.html + # + # @example Example: Put bucket lifecycle + # + # # The following example replaces existing lifecycle configuration, if any, on the specified bucket. + # + # resp = client.put_bucket_lifecycle_configuration({ + # bucket: "examplebucket", + # lifecycle_configuration: { + # rules: [ + # { + # expiration: { + # days: 3650, + # }, + # filter: { + # prefix: "documents/", + # }, + # id: "TestOnly", + # status: "Enabled", + # transitions: [ + # { + # days: 365, + # storage_class: "GLACIER", + # }, + # ], + # }, + # ], + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_lifecycle_configuration({ + # bucket: "BucketName", # required + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # lifecycle_configuration: { + # rules: [ # required + # { + # expiration: { + # date: Time.now, + # days: 1, + # expired_object_delete_marker: false, + # }, + # id: "ID", + # prefix: "Prefix", + # filter: { + # prefix: "Prefix", + # tag: { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # object_size_greater_than: 1, + # object_size_less_than: 1, + # and: { + # prefix: "Prefix", + # tags: [ + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # object_size_greater_than: 1, + # object_size_less_than: 1, + # }, + # }, + # status: "Enabled", # required, accepts Enabled, Disabled + # transitions: [ + # { + # date: Time.now, + # days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # }, + # ], + # noncurrent_version_transitions: [ + # { + # noncurrent_days: 1, + # storage_class: "GLACIER", # accepts GLACIER, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, DEEP_ARCHIVE, GLACIER_IR + # newer_noncurrent_versions: 1, + # }, + # ], + # noncurrent_version_expiration: { + # noncurrent_days: 1, + # newer_noncurrent_versions: 1, + # }, + # abort_incomplete_multipart_upload: { + # days_after_initiation: 1, + # }, + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_lifecycle_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#13189 + def put_bucket_lifecycle_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Set the logging parameters for a bucket and to specify permissions for + # who can view and modify the logging parameters. All logs are saved to + # buckets in the same Amazon Web Services Region as the source bucket. + # To set the logging status of a bucket, you must be the bucket owner. + # + # The bucket owner is automatically granted FULL\_CONTROL to all logs. + # You use the `Grantee` request element to grant access to other people. + # The `Permissions` request element specifies the kind of access the + # grantee has to the logs. + # + # If the target bucket for log delivery uses the bucket owner enforced + # setting for S3 Object Ownership, you can't use the `Grantee` request + # element to grant access to others. Permissions can only be granted + # using policies. For more information, see [Permissions for server + # access log delivery][1] in the *Amazon S3 User Guide*. + # + # Grantee Values + # + # : You can specify the person (grantee) to whom you're assigning + # access rights (by using request elements) in the following ways: + # + # * By the person's ID: + # + # `<>ID<><>GranteesEmail<> + # ` + # + # `DisplayName` is optional and ignored in the request. + # + # * By Email address: + # + # ` <>Grantees@email.com<>` + # + # The grantee is resolved to the `CanonicalUser` and, in a response + # to a `GETObjectAcl` request, appears as the CanonicalUser. + # + # * By URI: + # + # `<>http://acs.amazonaws.com/groups/global/AuthenticatedUsers<>` + # + # To enable logging, you use `LoggingEnabled` and its children request + # elements. To disable logging, you use an empty `BucketLoggingStatus` + # request element: + # + # `` + # + # For more information about server access logging, see [Server Access + # Logging][2] in the *Amazon S3 User Guide*. + # + # For more information about creating a bucket, see [CreateBucket][3]. + # For more information about returning the logging status of a bucket, + # see [GetBucketLogging][4]. + # + # The following operations are related to `PutBucketLogging`: + # + # * [PutObject][5] + # + # * [DeleteBucket][6] + # + # * [CreateBucket][3] + # + # * [GetBucketLogging][4] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/enable-server-access-logging.html#grant-log-delivery-permissions-general + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/ServerLogs.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLogging.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucket.html + # + # @example Example: Set logging configuration for a bucket + # + # # The following example sets logging policy on a bucket. For the Log Delivery group to deliver logs to the destination + # # bucket, it needs permission for the READ_ACP action which the policy grants. + # + # resp = client.put_bucket_logging({ + # bucket: "sourcebucket", + # bucket_logging_status: { + # logging_enabled: { + # target_bucket: "targetbucket", + # target_grants: [ + # { + # grantee: { + # type: "Group", + # uri: "http://acs.amazonaws.com/groups/global/AllUsers", + # }, + # permission: "READ", + # }, + # ], + # target_prefix: "MyBucketLogs/", + # }, + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_logging({ + # bucket: "BucketName", # required + # bucket_logging_status: { # required + # logging_enabled: { + # target_bucket: "TargetBucket", # required + # target_grants: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, READ, WRITE + # }, + # ], + # target_prefix: "TargetPrefix", # required + # target_object_key_format: { + # simple_prefix: { + # }, + # partitioned_prefix: { + # partition_date_source: "EventTime", # accepts EventTime, DeliveryTime + # }, + # }, + # }, + # }, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_logging + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLogging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#13372 + def put_bucket_logging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets a metrics configuration (specified by the metrics configuration + # ID) for the bucket. You can have up to 1,000 metrics configurations + # per bucket. If you're updating an existing metrics configuration, + # note that this is a full replacement of the existing metrics + # configuration. If you don't include the elements you want to keep, + # they are erased. + # + # To use this operation, you must have permissions to perform the + # `s3:PutMetricsConfiguration` action. The bucket owner has this + # permission by default. The bucket owner can grant this permission to + # others. For more information about permissions, see [Permissions + # Related to Bucket Subresource Operations][1] and [Managing Access + # Permissions to Your Amazon S3 Resources][2]. + # + # For information about CloudWatch request metrics for Amazon S3, see + # [Monitoring Metrics with Amazon CloudWatch][3]. + # + # The following operations are related to + # `PutBucketMetricsConfiguration`: + # + # * [DeleteBucketMetricsConfiguration][4] + # + # * [GetBucketMetricsConfiguration][5] + # + # * [ListBucketMetricsConfigurations][6] + # + # `PutBucketMetricsConfiguration` has the following special error: + # + # * Error code: `TooManyConfigurations` + # + # * Description: You are attempting to create a new configuration but + # have already reached the 1,000-configuration limit. + # + # * HTTP Status Code: HTTP 400 Bad Request + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cloudwatch-monitoring.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketMetricsConfiguration.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketMetricsConfiguration.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBucketMetricsConfigurations.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_metrics_configuration({ + # bucket: "BucketName", # required + # id: "MetricsId", # required + # metrics_configuration: { # required + # id: "MetricsId", # required + # filter: { + # prefix: "Prefix", + # tag: { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # access_point_arn: "AccessPointArn", + # and: { + # prefix: "Prefix", + # tags: [ + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # access_point_arn: "AccessPointArn", + # }, + # }, + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_metrics_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketMetricsConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#13476 + def put_bucket_metrics_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # No longer used, see the [PutBucketNotificationConfiguration][1] + # operation. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketNotificationConfiguration.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_notification({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # notification_configuration: { # required + # topic_configuration: { + # id: "NotificationId", + # events: ["s3:ReducedRedundancyLostObject"], # accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # event: "s3:ReducedRedundancyLostObject", # accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # topic: "TopicArn", + # }, + # queue_configuration: { + # id: "NotificationId", + # event: "s3:ReducedRedundancyLostObject", # accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # events: ["s3:ReducedRedundancyLostObject"], # accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # queue: "QueueArn", + # }, + # cloud_function_configuration: { + # id: "NotificationId", + # event: "s3:ReducedRedundancyLostObject", # accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # events: ["s3:ReducedRedundancyLostObject"], # accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # cloud_function: "CloudFunction", + # invocation_role: "CloudFunctionInvocationRole", + # }, + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_notification + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotification AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#13562 + def put_bucket_notification(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Enables notifications of specified events for a bucket. For more + # information about event notifications, see [Configuring Event + # Notifications][1]. + # + # Using this API, you can replace an existing notification + # configuration. The configuration is an XML file that defines the event + # types that you want Amazon S3 to publish and the destination where you + # want Amazon S3 to publish an event notification when it detects an + # event of the specified type. + # + # By default, your bucket has no event notifications configured. That + # is, the notification configuration will be an empty + # `NotificationConfiguration`. + # + # `` + # + # `` + # + # This action replaces the existing notification configuration with the + # configuration you include in the request body. + # + # After Amazon S3 receives this request, it first verifies that any + # Amazon Simple Notification Service (Amazon SNS) or Amazon Simple Queue + # Service (Amazon SQS) destination exists, and that the bucket owner has + # permission to publish to it by sending a test notification. In the + # case of Lambda destinations, Amazon S3 verifies that the Lambda + # function permissions grant Amazon S3 permission to invoke the function + # from the Amazon S3 bucket. For more information, see [Configuring + # Notifications for Amazon S3 Events][1]. + # + # You can disable notifications by adding the empty + # NotificationConfiguration element. + # + # For more information about the number of event notification + # configurations that you can create per bucket, see [Amazon S3 service + # quotas][2] in *Amazon Web Services General Reference*. + # + # By default, only the bucket owner can configure notifications on a + # bucket. However, bucket owners can use a bucket policy to grant + # permission to other users to set this configuration with the required + # `s3:PutBucketNotification` permission. + # + # The PUT notification is an atomic operation. For example, suppose your + # notification configuration includes SNS topic, SQS queue, and Lambda + # function configurations. When you send a PUT request with this + # configuration, Amazon S3 sends test messages to your SNS topic. If the + # message fails, the entire PUT action will fail, and Amazon S3 will not + # add the configuration to your bucket. + # + # + # + # If the configuration in the request body includes only one + # `TopicConfiguration` specifying only the + # `s3:ReducedRedundancyLostObject` event type, the response will also + # include the `x-amz-sns-test-message-id` header containing the message + # ID of the test notification sent to the topic. + # + # The following action is related to + # `PutBucketNotificationConfiguration`: + # + # * [GetBucketNotificationConfiguration][3] + # + # ^ + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html + # [2]: https://docs.aws.amazon.com/general/latest/gr/s3.html#limits_s3 + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketNotificationConfiguration.html + # + # @example Example: Set notification configuration for a bucket + # + # # The following example sets notification configuration on a bucket to publish the object created events to an SNS topic. + # + # resp = client.put_bucket_notification_configuration({ + # bucket: "examplebucket", + # notification_configuration: { + # topic_configurations: [ + # { + # events: [ + # "s3:ObjectCreated:*", + # ], + # topic_arn: "arn:aws:sns:us-west-2:123456789012:s3-notification-topic", + # }, + # ], + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_notification_configuration({ + # bucket: "BucketName", # required + # notification_configuration: { # required + # topic_configurations: [ + # { + # id: "NotificationId", + # topic_arn: "TopicArn", # required + # events: ["s3:ReducedRedundancyLostObject"], # required, accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # filter: { + # key: { + # filter_rules: [ + # { + # name: "prefix", # accepts prefix, suffix + # value: "FilterRuleValue", + # }, + # ], + # }, + # }, + # }, + # ], + # queue_configurations: [ + # { + # id: "NotificationId", + # queue_arn: "QueueArn", # required + # events: ["s3:ReducedRedundancyLostObject"], # required, accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # filter: { + # key: { + # filter_rules: [ + # { + # name: "prefix", # accepts prefix, suffix + # value: "FilterRuleValue", + # }, + # ], + # }, + # }, + # }, + # ], + # lambda_function_configurations: [ + # { + # id: "NotificationId", + # lambda_function_arn: "LambdaFunctionArn", # required + # events: ["s3:ReducedRedundancyLostObject"], # required, accepts s3:ReducedRedundancyLostObject, s3:ObjectCreated:*, s3:ObjectCreated:Put, s3:ObjectCreated:Post, s3:ObjectCreated:Copy, s3:ObjectCreated:CompleteMultipartUpload, s3:ObjectRemoved:*, s3:ObjectRemoved:Delete, s3:ObjectRemoved:DeleteMarkerCreated, s3:ObjectRestore:*, s3:ObjectRestore:Post, s3:ObjectRestore:Completed, s3:Replication:*, s3:Replication:OperationFailedReplication, s3:Replication:OperationNotTracked, s3:Replication:OperationMissedThreshold, s3:Replication:OperationReplicatedAfterThreshold, s3:ObjectRestore:Delete, s3:LifecycleTransition, s3:IntelligentTiering, s3:ObjectAcl:Put, s3:LifecycleExpiration:*, s3:LifecycleExpiration:Delete, s3:LifecycleExpiration:DeleteMarkerCreated, s3:ObjectTagging:*, s3:ObjectTagging:Put, s3:ObjectTagging:Delete + # filter: { + # key: { + # filter_rules: [ + # { + # name: "prefix", # accepts prefix, suffix + # value: "FilterRuleValue", + # }, + # ], + # }, + # }, + # }, + # ], + # event_bridge_configuration: { + # }, + # }, + # expected_bucket_owner: "AccountId", + # skip_destination_validation: false, + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_notification_configuration + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#13746 + def put_bucket_notification_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Creates or modifies `OwnershipControls` for an Amazon S3 bucket. To + # use this operation, you must have the `s3:PutBucketOwnershipControls` + # permission. For more information about Amazon S3 permissions, see + # [Specifying permissions in a policy][1]. + # + # For information about Amazon S3 Object Ownership, see [Using object + # ownership][2]. + # + # The following operations are related to `PutBucketOwnershipControls`: + # + # * GetBucketOwnershipControls + # + # * DeleteBucketOwnershipControls + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/user-guide/using-with-s3-actions.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/user-guide/about-object-ownership.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_ownership_controls({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # expected_bucket_owner: "AccountId", + # ownership_controls: { # required + # rules: [ # required + # { + # object_ownership: "BucketOwnerPreferred", # required, accepts BucketOwnerPreferred, ObjectWriter, BucketOwnerEnforced + # }, + # ], + # }, + # }) + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_ownership_controls + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketOwnershipControls AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#13815 + def put_bucket_ownership_controls(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Applies an Amazon S3 bucket policy to an Amazon S3 bucket. + # + # Directory buckets - For directory buckets, you must make + # requests for this API operation to the Regional endpoint. These + # endpoints support path-style requests in the format + # `https://s3express-control.region_code.amazonaws.com/bucket-name `. + # Virtual-hosted-style requests aren't supported. For more information, + # see [Regional and Zonal endpoints][1] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # + # : If you are using an identity other than the root user of the Amazon + # Web Services account that owns the bucket, the calling identity must + # both have the `PutBucketPolicy` permissions on the specified bucket + # and belong to the bucket owner's account in order to use this + # operation. + # + # If you don't have `PutBucketPolicy` permissions, Amazon S3 returns + # a `403 Access Denied` error. If you have the correct permissions, + # but you're not using an identity that belongs to the bucket + # owner's account, Amazon S3 returns a `405 Method Not Allowed` + # error. + # + # To ensure that bucket owners don't inadvertently lock themselves + # out of their own buckets, the root principal in a bucket owner's + # Amazon Web Services account can perform the `GetBucketPolicy`, + # `PutBucketPolicy`, and `DeleteBucketPolicy` API actions, even if + # their bucket policy explicitly denies the root principal's access. + # Bucket owner root principals can only be blocked from performing + # these API actions by VPC endpoint policies and Amazon Web Services + # Organizations policies. + # + # * **General purpose bucket permissions** - The `s3:PutBucketPolicy` + # permission is required in a policy. For more information about + # general purpose buckets bucket policies, see [Using Bucket + # Policies and User Policies][2] in the *Amazon S3 User Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation, you must have the `s3express:PutBucketPolicy` + # permission in an IAM identity-based policy instead of a bucket + # policy. Cross-account access to this API operation isn't + # supported. This operation can only be performed by the Amazon Web + # Services account that owns the resource. For more information + # about directory bucket policies and permissions, see [Amazon Web + # Services Identity and Access Management (IAM) for S3 Express One + # Zone][3] in the *Amazon S3 User Guide*. + # + # Example bucket policies + # + # : **General purpose buckets example bucket policies** - See [Bucket + # policy examples][4] in the *Amazon S3 User Guide*. + # + # **Directory bucket example bucket policies** - See [Example bucket + # policies for S3 Express One Zone][5] in the *Amazon S3 User Guide*. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is + # `s3express-control.region.amazonaws.com`. + # + # The following operations are related to `PutBucketPolicy`: + # + # * [CreateBucket][6] + # + # * [DeleteBucket][7] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-iam-policies.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/example-bucket-policies.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucket.html + # + # @example Example: Set bucket policy + # + # # The following example sets a permission policy on a bucket. + # + # resp = client.put_bucket_policy({ + # bucket: "examplebucket", + # policy: "{\"Version\": \"2012-10-17\", \"Statement\": [{ \"Sid\": \"id-1\",\"Effect\": \"Allow\",\"Principal\": {\"AWS\": \"arn:aws:iam::123456789012:root\"}, \"Action\": [ \"s3:PutObject\",\"s3:PutObjectAcl\"], \"Resource\": [\"arn:aws:s3:::acl3/*\" ] } ]}", + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_policy({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # confirm_remove_self_bucket_access: false, + # policy: "Policy", # required + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_policy + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketPolicy AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#14015 + def put_bucket_policy(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Creates a replication configuration or replaces an existing one. For + # more information, see [Replication][1] in the *Amazon S3 User Guide*. + # + # Specify the replication configuration in the request body. In the + # replication configuration, you provide the name of the destination + # bucket or buckets where you want Amazon S3 to replicate objects, the + # IAM role that Amazon S3 can assume to replicate objects on your + # behalf, and other relevant information. You can invoke this request + # for a specific Amazon Web Services Region by using the [ + # `aws:RequestedRegion` ][2] condition key. + # + # A replication configuration must include at least one rule, and can + # contain a maximum of 1,000. Each rule identifies a subset of objects + # to replicate by filtering the objects in the source bucket. To choose + # additional subsets of objects to replicate, add a rule for each + # subset. + # + # To specify a subset of the objects in the source bucket to apply a + # replication rule to, add the Filter element as a child of the Rule + # element. You can filter objects based on an object key prefix, one or + # more object tags, or both. When you add the Filter element in the + # configuration, you must also add the following elements: + # `DeleteMarkerReplication`, `Status`, and `Priority`. + # + # If you are using an earlier version of the replication configuration, + # Amazon S3 handles replication of delete markers differently. For more + # information, see [Backward Compatibility][3]. + # + # + # + # For information about enabling versioning on a bucket, see [Using + # Versioning][4]. + # + # Handling Replication of Encrypted Objects + # + # : By default, Amazon S3 doesn't replicate objects that are stored at + # rest using server-side encryption with KMS keys. To replicate Amazon + # Web Services KMS-encrypted objects, add the following: + # `SourceSelectionCriteria`, `SseKmsEncryptedObjects`, `Status`, + # `EncryptionConfiguration`, and `ReplicaKmsKeyID`. For information + # about replication configuration, see [Replicating Objects Created + # with SSE Using KMS keys][5]. + # + # For information on `PutBucketReplication` errors, see [List of + # replication-related error codes][6] + # + # Permissions + # + # : To create a `PutBucketReplication` request, you must have + # `s3:PutReplicationConfiguration` permissions for the bucket. + # + # By default, a resource owner, in this case the Amazon Web Services + # account that created the bucket, can perform this operation. The + # resource owner can also grant others permissions to perform the + # operation. For more information about permissions, see [Specifying + # Permissions in a Policy][7] and [Managing Access Permissions to Your + # Amazon S3 Resources][8]. + # + # To perform this operation, the user or role performing the action + # must have the [iam:PassRole][9] permission. + # + # + # + # The following operations are related to `PutBucketReplication`: + # + # * [GetBucketReplication][10] + # + # * [DeleteBucketReplication][11] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication.html + # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-requestedregion + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication-add-config.html#replication-backward-compat-considerations + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/Versioning.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication-config-for-kms-objects.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#ReplicationErrorCodeList + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [9]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use_passrole.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketReplication.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketReplication.html + # + # @example Example: Set replication configuration on a bucket + # + # # The following example sets replication configuration on a bucket. + # + # resp = client.put_bucket_replication({ + # bucket: "examplebucket", + # replication_configuration: { + # role: "arn:aws:iam::123456789012:role/examplerole", + # rules: [ + # { + # destination: { + # bucket: "arn:aws:s3:::destinationbucket", + # storage_class: "STANDARD", + # }, + # prefix: "", + # status: "Enabled", + # }, + # ], + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_replication({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # replication_configuration: { # required + # role: "Role", # required + # rules: [ # required + # { + # id: "ID", + # priority: 1, + # prefix: "Prefix", + # filter: { + # prefix: "Prefix", + # tag: { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # and: { + # prefix: "Prefix", + # tags: [ + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # }, + # status: "Enabled", # required, accepts Enabled, Disabled + # source_selection_criteria: { + # sse_kms_encrypted_objects: { + # status: "Enabled", # required, accepts Enabled, Disabled + # }, + # replica_modifications: { + # status: "Enabled", # required, accepts Enabled, Disabled + # }, + # }, + # existing_object_replication: { + # status: "Enabled", # required, accepts Enabled, Disabled + # }, + # destination: { # required + # bucket: "BucketName", # required + # account: "AccountId", + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # access_control_translation: { + # owner: "Destination", # required, accepts Destination + # }, + # encryption_configuration: { + # replica_kms_key_id: "ReplicaKmsKeyID", + # }, + # replication_time: { + # status: "Enabled", # required, accepts Enabled, Disabled + # time: { # required + # minutes: 1, + # }, + # }, + # metrics: { + # status: "Enabled", # required, accepts Enabled, Disabled + # event_threshold: { + # minutes: 1, + # }, + # }, + # }, + # delete_marker_replication: { + # status: "Enabled", # accepts Enabled, Disabled + # }, + # }, + # ], + # }, + # token: "ObjectLockToken", + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_replication + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketReplication AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#14253 + def put_bucket_replication(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the request payment configuration for a bucket. By default, the + # bucket owner pays for downloads from the bucket. This configuration + # parameter enables the bucket owner (only) to specify that the person + # requesting the download will be charged for the download. For more + # information, see [Requester Pays Buckets][1]. + # + # The following operations are related to `PutBucketRequestPayment`: + # + # * [CreateBucket][2] + # + # * [GetBucketRequestPayment][3] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/RequesterPaysBuckets.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketRequestPayment.html + # + # @example Example: Set request payment configuration on a bucket. + # + # # The following example sets request payment configuration on a bucket so that person requesting the download is charged. + # + # resp = client.put_bucket_request_payment({ + # bucket: "examplebucket", + # request_payment_configuration: { + # payer: "Requester", + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_request_payment({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # request_payment_configuration: { # required + # payer: "Requester", # required, accepts Requester, BucketOwner + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_request_payment + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketRequestPayment AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#14350 + def put_bucket_request_payment(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the tags for a bucket. + # + # Use tags to organize your Amazon Web Services bill to reflect your own + # cost structure. To do this, sign up to get your Amazon Web Services + # account bill with tag key values included. Then, to see the cost of + # combined resources, organize your billing information according to + # resources with the same tag key values. For example, you can tag + # several resources with a specific application name, and then organize + # your billing information to see the total cost of that application + # across several services. For more information, see [Cost Allocation + # and Tagging][1] and [Using Cost Allocation in Amazon S3 Bucket + # Tags][2]. + # + # When this operation sets the tags for a bucket, it will overwrite any + # current tags the bucket already has. You cannot use this operation to + # add tags to an existing list of tags. + # + # + # + # To use this operation, you must have permissions to perform the + # `s3:PutBucketTagging` action. The bucket owner has this permission by + # default and can grant this permission to others. For more information + # about permissions, see [Permissions Related to Bucket Subresource + # Operations][3] and [Managing Access Permissions to Your Amazon S3 + # Resources][4]. + # + # `PutBucketTagging` has the following special errors. For more Amazon + # S3 errors see, [Error Responses][5]. + # + # * `InvalidTag` - The tag provided was not a valid tag. This error can + # occur if the tag did not pass input validation. For more + # information, see [Using Cost Allocation in Amazon S3 Bucket + # Tags][2]. + # + # * `MalformedXML` - The XML provided does not match the schema. + # + # * `OperationAborted` - A conflicting conditional action is currently + # in progress against this resource. Please try again. + # + # * `InternalError` - The service was unable to apply the provided tag + # to the bucket. + # + # The following operations are related to `PutBucketTagging`: + # + # * [GetBucketTagging][6] + # + # * [DeleteBucketTagging][7] + # + # + # + # [1]: https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/cost-alloc-tags.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/CostAllocTagging.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketTagging.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketTagging.html + # + # @example Example: Set tags on a bucket + # + # # The following example sets tags on a bucket. Any existing tags are replaced. + # + # resp = client.put_bucket_tagging({ + # bucket: "examplebucket", + # tagging: { + # tag_set: [ + # { + # key: "Key1", + # value: "Value1", + # }, + # { + # key: "Key2", + # value: "Value2", + # }, + # ], + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_tagging({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # tagging: { # required + # tag_set: [ # required + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_tagging + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketTagging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#14501 + def put_bucket_tagging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the versioning state of an existing bucket. + # + # You can set the versioning state with one of the following values: + # + # **Enabled**—Enables versioning for the objects in the bucket. All + # objects added to the bucket receive a unique version ID. + # + # **Suspended**—Disables versioning for the objects in the bucket. All + # objects added to the bucket receive the version ID null. + # + # If the versioning state has never been set on a bucket, it has no + # versioning state; a [GetBucketVersioning][1] request does not return a + # versioning state value. + # + # In order to enable MFA Delete, you must be the bucket owner. If you + # are the bucket owner and want to enable MFA Delete in the bucket + # versioning configuration, you must include the `x-amz-mfa request` + # header and the `Status` and the `MfaDelete` request elements in a + # request to set the versioning state of the bucket. + # + # If you have an object expiration lifecycle configuration in your + # non-versioned bucket and you want to maintain the same permanent + # delete behavior when you enable versioning, you must add a noncurrent + # expiration policy. The noncurrent expiration lifecycle configuration + # will manage the deletes of the noncurrent object versions in the + # version-enabled bucket. (A version-enabled bucket maintains one + # current and zero or more noncurrent object versions.) For more + # information, see [Lifecycle and Versioning][2]. + # + # The following operations are related to `PutBucketVersioning`: + # + # * [CreateBucket][3] + # + # * [DeleteBucket][4] + # + # * [GetBucketVersioning][1] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketVersioning.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html#lifecycle-and-other-bucket-config + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucket.html + # + # @example Example: Set versioning configuration on a bucket + # + # # The following example sets versioning configuration on bucket. The configuration enables versioning on the bucket. + # + # resp = client.put_bucket_versioning({ + # bucket: "examplebucket", + # versioning_configuration: { + # mfa_delete: "Disabled", + # status: "Enabled", + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_versioning({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # mfa: "MFA", + # versioning_configuration: { # required + # mfa_delete: "Enabled", # accepts Enabled, Disabled + # status: "Enabled", # accepts Enabled, Suspended + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_versioning + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketVersioning AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#14632 + def put_bucket_versioning(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the configuration of the website that is specified in the + # `website` subresource. To configure a bucket as a website, you can add + # this subresource on the bucket with website configuration information + # such as the file name of the index document and any redirect rules. + # For more information, see [Hosting Websites on Amazon S3][1]. + # + # This PUT action requires the `S3:PutBucketWebsite` permission. By + # default, only the bucket owner can configure the website attached to a + # bucket; however, bucket owners can allow other users to set the + # website configuration by writing a bucket policy that grants them the + # `S3:PutBucketWebsite` permission. + # + # To redirect all website requests sent to the bucket's website + # endpoint, you add a website configuration with the following elements. + # Because all requests are sent to another website, you don't need to + # provide index document name for the bucket. + # + # * `WebsiteConfiguration` + # + # * `RedirectAllRequestsTo` + # + # * `HostName` + # + # * `Protocol` + # + # If you want granular control over redirects, you can use the following + # elements to add routing rules that describe conditions for redirecting + # requests and information about the redirect destination. In this case, + # the website configuration must provide an index document for the + # bucket, because some requests might not be redirected. + # + # * `WebsiteConfiguration` + # + # * `IndexDocument` + # + # * `Suffix` + # + # * `ErrorDocument` + # + # * `Key` + # + # * `RoutingRules` + # + # * `RoutingRule` + # + # * `Condition` + # + # * `HttpErrorCodeReturnedEquals` + # + # * `KeyPrefixEquals` + # + # * `Redirect` + # + # * `Protocol` + # + # * `HostName` + # + # * `ReplaceKeyPrefixWith` + # + # * `ReplaceKeyWith` + # + # * `HttpRedirectCode` + # + # Amazon S3 has a limitation of 50 routing rules per website + # configuration. If you require more than 50 routing rules, you can use + # object redirect. For more information, see [Configuring an Object + # Redirect][2] in the *Amazon S3 User Guide*. + # + # The maximum request length is limited to 128 KB. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html + # + # @example Example: Set website configuration on a bucket + # + # # The following example adds website configuration to a bucket. + # + # resp = client.put_bucket_website({ + # bucket: "examplebucket", + # content_md5: "", + # website_configuration: { + # error_document: { + # key: "error.html", + # }, + # index_document: { + # suffix: "index.html", + # }, + # }, + # }) + # @example Request syntax with placeholder values + # + # resp = client.put_bucket_website({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # website_configuration: { # required + # error_document: { + # key: "ObjectKey", # required + # }, + # index_document: { + # suffix: "Suffix", # required + # }, + # redirect_all_requests_to: { + # host_name: "HostName", # required + # protocol: "http", # accepts http, https + # }, + # routing_rules: [ + # { + # condition: { + # http_error_code_returned_equals: "HttpErrorCodeReturnedEquals", + # key_prefix_equals: "KeyPrefixEquals", + # }, + # redirect: { # required + # host_name: "HostName", + # http_redirect_code: "HttpRedirectCode", + # protocol: "http", # accepts http, https + # replace_key_prefix_with: "ReplaceKeyPrefixWith", + # replace_key_with: "ReplaceKeyWith", + # }, + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_bucket_website + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketWebsite AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#14816 + def put_bucket_website(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Adds an object to a bucket. + # + # * Amazon S3 never adds partial objects; if you receive a success + # response, Amazon S3 added the entire object to the bucket. You + # cannot use `PutObject` to only update a single piece of metadata for + # an existing object. You must put the entire object with updated + # metadata if you want to update some values. + # + # * If your bucket uses the bucket owner enforced setting for Object + # Ownership, ACLs are disabled and no longer affect permissions. All + # objects written to the bucket by any account will be owned by the + # bucket owner. + # + # * **Directory buckets** - For directory buckets, you must make + # requests for this API operation to the Zonal endpoint. These + # endpoints support virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name + # `. Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][1] in the *Amazon S3 User Guide*. + # + # + # + # Amazon S3 is a distributed system. If it receives multiple write + # requests for the same object simultaneously, it overwrites all but the + # last object written. However, Amazon S3 provides features that can + # modify this behavior: + # + # * **S3 Object Lock** - To prevent objects from being deleted or + # overwritten, you can use [Amazon S3 Object Lock][2] in the *Amazon + # S3 User Guide*. + # + # This functionality is not supported for directory buckets. + # + # + # + # * **S3 Versioning** - When you enable versioning for a bucket, if + # Amazon S3 receives multiple write requests for the same object + # simultaneously, it stores all versions of the objects. For each + # write request that is made to the same object, Amazon S3 + # automatically generates a unique version ID of that object being + # stored in Amazon S3. You can retrieve, replace, or delete any + # version of the object. For more information about versioning, see + # [Adding Objects to Versioning-Enabled Buckets][3] in the *Amazon S3 + # User Guide*. For information about returning the versioning state of + # a bucket, see [GetBucketVersioning][4]. + # + # This functionality is not supported for directory buckets. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - The following permissions + # are required in your policies when your `PutObject` request + # includes specific headers. + # + # * s3:PutObject - To successfully complete + # the `PutObject` request, you must always have the `s3:PutObject` + # permission on a bucket to add an object to it. + # + # * s3:PutObjectAcl - To successfully change + # the objects ACL of your `PutObject` request, you must have the + # `s3:PutObjectAcl`. + # + # * s3:PutObjectTagging - To successfully set + # the tag-set with your `PutObject` request, you must have the + # `s3:PutObjectTagging`. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][5] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][5]. + # + # Data integrity with Content-MD5 + # : * **General purpose bucket** - To ensure that data is not corrupted + # traversing the network, use the `Content-MD5` header. When you use + # this header, Amazon S3 checks the object against the provided MD5 + # value and, if they do not match, Amazon S3 returns an error. + # Alternatively, when the object's ETag is its MD5 digest, you can + # calculate the MD5 while putting the object to Amazon S3 and + # compare the returned ETag to the calculated MD5 value. + # + # * **Directory bucket** - This functionality is not supported for + # directory buckets. + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # For more information about related Amazon S3 APIs, see the following: + # + # * [CopyObject][6] + # + # * [DeleteObject][7] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/AddingObjectstoVersioningEnabledBuckets.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketVersioning.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObject.html + # + # @example Example: To upload an object + # + # # The following example uploads an object to a versioning-enabled bucket. The source file is specified using Windows file + # # syntax. S3 returns VersionId of the newly created object. + # + # resp = client.put_object({ + # body: "HappyFace.jpg", + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # version_id: "tpf3zF08nBplQK1XLOefGskR7mGDwcDk", + # } + # @example Example: To upload an object and specify server-side encryption and object tags + # + # # The following example uploads an object. The request specifies the optional server-side encryption option. The request + # # also specifies optional object tags. If the bucket is versioning enabled, S3 returns version ID in response. + # + # resp = client.put_object({ + # body: "filetoupload", + # bucket: "examplebucket", + # key: "exampleobject", + # server_side_encryption: "AES256", + # tagging: "key1=value1&key2=value2", + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # server_side_encryption: "AES256", + # version_id: "Ri.vC6qVlA4dEnjgRV4ZHsHoFIjqEMNt", + # } + # @example Example: To upload an object (specify optional headers) + # + # # The following example uploads an object. The request specifies optional request headers to directs S3 to use specific + # # storage class and use server-side encryption. + # + # resp = client.put_object({ + # body: "HappyFace.jpg", + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # server_side_encryption: "AES256", + # storage_class: "STANDARD_IA", + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # server_side_encryption: "AES256", + # version_id: "CG612hodqujkf8FaaNfp8U..FIhLROcp", + # } + # @example Example: To upload object and specify user-defined metadata + # + # # The following example creates an object. The request also specifies optional metadata. If the bucket is versioning + # # enabled, S3 returns version ID in response. + # + # resp = client.put_object({ + # body: "filetoupload", + # bucket: "examplebucket", + # key: "exampleobject", + # metadata: { + # "metadata1" => "value1", + # "metadata2" => "value2", + # }, + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # version_id: "pSKidl4pHBiNwukdbcPXAIs.sshFFOc0", + # } + # @example Example: To upload an object and specify optional tags + # + # # The following example uploads an object. The request specifies optional object tags. The bucket is versioned, therefore + # # S3 returns version ID of the newly created object. + # + # resp = client.put_object({ + # body: "c:\\HappyFace.jpg", + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # tagging: "key1=value1&key2=value2", + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # version_id: "psM2sYY4.o1501dSx8wMvnkOzSBB.V4a", + # } + # @example Example: To upload an object and specify canned ACL. + # + # # The following example uploads and object. The request specifies optional canned ACL (access control list) to all READ + # # access to authenticated users. If the bucket is versioning enabled, S3 returns version ID in response. + # + # resp = client.put_object({ + # acl: "authenticated-read", + # body: "filetoupload", + # bucket: "examplebucket", + # key: "exampleobject", + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # version_id: "Kirh.unyZwjQ69YxcQLA8z4F5j3kJJKr", + # } + # @example Example: To create an object. + # + # # The following example creates an object. If the bucket is versioning enabled, S3 returns version ID in response. + # + # resp = client.put_object({ + # body: "filetoupload", + # bucket: "examplebucket", + # key: "objectkey", + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"6805f2cfc46c0f04559748bb039d69ae\"", + # version_id: "Bvq0EDKxOcXLJXNo_Lkz37eM3R4pfzyQ", + # } + # @example Streaming a file from disk + # # upload file from disk in a single request, may not exceed 5GB + # File.open('/source/file/path', 'rb') do |file| + # s3.put_object(bucket: 'bucket-name', key: 'object-key', body: file) + # end + # @example Request syntax with placeholder values + # + # resp = client.put_object({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # body: source_file, + # bucket: "BucketName", # required + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_length: 1, + # content_md5: "ContentMD5", + # content_type: "ContentType", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # key: "ObjectKey", # required + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.expiration #=> String + # resp.etag #=> String + # resp.checksum_crc32 #=> String + # resp.checksum_crc32c #=> String + # resp.checksum_sha1 #=> String + # resp.checksum_sha256 #=> String + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.version_id #=> String + # resp.sse_customer_algorithm #=> String + # resp.sse_customer_key_md5 #=> String + # resp.ssekms_key_id #=> String + # resp.ssekms_encryption_context #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_object + # @param params [Hash] ({}) + # @return [Types::PutObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectOutput#expiration #expiration} => String + # * {Types::PutObjectOutput#etag #etag} => String + # * {Types::PutObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::PutObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::PutObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::PutObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::PutObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::PutObjectOutput#version_id #version_id} => String + # * {Types::PutObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::PutObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::PutObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::PutObjectOutput#ssekms_encryption_context #ssekms_encryption_context} => String + # * {Types::PutObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::PutObjectOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObject AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#15649 + def put_object(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Uses the `acl` subresource to set the access control list (ACL) + # permissions for a new or existing object in an S3 bucket. You must + # have the `WRITE_ACP` permission to set the ACL of an object. For more + # information, see [What permissions can I grant?][1] in the *Amazon S3 + # User Guide*. + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # Depending on your application needs, you can choose to set the ACL on + # an object using either the request body or the headers. For example, + # if you have an existing application that updates a bucket ACL using + # the request body, you can continue to use that approach. For more + # information, see [Access Control List (ACL) Overview][2] in the + # *Amazon S3 User Guide*. + # + # If your bucket uses the bucket owner enforced setting for S3 Object + # Ownership, ACLs are disabled and no longer affect permissions. You + # must use policies to grant access to your bucket and the objects in + # it. Requests to set ACLs or update ACLs fail and return the + # `AccessControlListNotSupported` error code. Requests to read ACLs are + # still supported. For more information, see [Controlling object + # ownership][3] in the *Amazon S3 User Guide*. + # + # Permissions + # + # : You can set access permissions using one of the following methods: + # + # * Specify a canned ACL with the `x-amz-acl` request header. Amazon + # S3 supports a set of predefined ACLs, known as canned ACLs. Each + # canned ACL has a predefined set of grantees and permissions. + # Specify the canned ACL name as the value of `x-amz-ac`l. If you + # use this header, you cannot use other access control-specific + # headers in your request. For more information, see [Canned + # ACL][4]. + # + # * Specify access permissions explicitly with the `x-amz-grant-read`, + # `x-amz-grant-read-acp`, `x-amz-grant-write-acp`, and + # `x-amz-grant-full-control` headers. When using these headers, you + # specify explicit access permissions and grantees (Amazon Web + # Services accounts or Amazon S3 groups) who will receive the + # permission. If you use these ACL-specific headers, you cannot use + # `x-amz-acl` header to set a canned ACL. These parameters map to + # the set of permissions that Amazon S3 supports in an ACL. For more + # information, see [Access Control List (ACL) Overview][2]. + # + # You specify each grantee as a type=value pair, where the type is + # one of the following: + # + # * `id` – if the value specified is the canonical user ID of an + # Amazon Web Services account + # + # * `uri` – if you are granting permissions to a predefined group + # + # * `emailAddress` – if the value specified is the email address of + # an Amazon Web Services account + # + # Using email addresses to specify a grantee is only supported in + # the following Amazon Web Services Regions: + # + # * US East (N. Virginia) + # + # * US West (N. California) + # + # * US West (Oregon) + # + # * Asia Pacific (Singapore) + # + # * Asia Pacific (Sydney) + # + # * Asia Pacific (Tokyo) + # + # * Europe (Ireland) + # + # * South America (São Paulo) + # + # For a list of all the Amazon S3 supported Regions and endpoints, + # see [Regions and Endpoints][5] in the Amazon Web Services + # General Reference. + # + # + # + # For example, the following `x-amz-grant-read` header grants list + # objects permission to the two Amazon Web Services accounts + # identified by their email addresses. + # + # `x-amz-grant-read: emailAddress="xyz@amazon.com", + # emailAddress="abc@amazon.com" ` + # + # You can use either a canned ACL or specify access permissions + # explicitly. You cannot do both. + # + # Grantee Values + # + # : You can specify the person (grantee) to whom you're assigning + # access rights (using request elements) in the following ways: + # + # * By the person's ID: + # + # `<>ID<><>GranteesEmail<> + # ` + # + # DisplayName is optional and ignored in the request. + # + # * By URI: + # + # `<>http://acs.amazonaws.com/groups/global/AuthenticatedUsers<>` + # + # * By Email address: + # + # `<>Grantees@email.com<>lt;/Grantee>` + # + # The grantee is resolved to the CanonicalUser and, in a response to + # a GET Object acl request, appears as the CanonicalUser. + # + # Using email addresses to specify a grantee is only supported in + # the following Amazon Web Services Regions: + # + # * US East (N. Virginia) + # + # * US West (N. California) + # + # * US West (Oregon) + # + # * Asia Pacific (Singapore) + # + # * Asia Pacific (Sydney) + # + # * Asia Pacific (Tokyo) + # + # * Europe (Ireland) + # + # * South America (São Paulo) + # + # For a list of all the Amazon S3 supported Regions and endpoints, + # see [Regions and Endpoints][5] in the Amazon Web Services General + # Reference. + # + # + # + # Versioning + # + # : The ACL of an object is set at the object version level. By default, + # PUT sets the ACL of the current version of an object. To set the ACL + # of a different version, use the `versionId` subresource. + # + # The following operations are related to `PutObjectAcl`: + # + # * [CopyObject][6] + # + # * [GetObject][7] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#permissions + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL + # [5]: https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_region + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # + # @example Example: To grant permissions using object ACL + # + # # The following example adds grants to an object ACL. The first permission grants user1 and user2 FULL_CONTROL and the + # # AllUsers group READ permission. + # + # resp = client.put_object_acl({ + # access_control_policy: { + # }, + # bucket: "examplebucket", + # grant_full_control: "emailaddress=user1@example.com,emailaddress=user2@example.com", + # grant_read: "uri=http://acs.amazonaws.com/groups/global/AllUsers", + # key: "HappyFace.jpg", + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.put_object_acl({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # access_control_policy: { + # grants: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, WRITE, WRITE_ACP, READ, READ_ACP + # }, + # ], + # owner: { + # display_name: "DisplayName", + # id: "ID", + # }, + # }, + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write: "GrantWrite", + # grant_write_acp: "GrantWriteACP", + # key: "ObjectKey", # required + # request_payer: "requester", # accepts requester + # version_id: "ObjectVersionId", + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_object_acl + # @param params [Hash] ({}) + # @return [Types::PutObjectAclOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectAclOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectAcl AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#16019 + def put_object_acl(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Applies a legal hold configuration to the specified object. For more + # information, see [Locking Objects][1]. + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_object_legal_hold({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # legal_hold: { + # status: "ON", # accepts ON, OFF + # }, + # request_payer: "requester", # accepts requester + # version_id: "ObjectVersionId", + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_object_legal_hold + # @param params [Hash] ({}) + # @return [Types::PutObjectLegalHoldOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectLegalHoldOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectLegalHold AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#16138 + def put_object_legal_hold(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Places an Object Lock configuration on the specified bucket. The rule + # specified in the Object Lock configuration will be applied by default + # to every new object placed in the specified bucket. For more + # information, see [Locking Objects][1]. + # + # * The `DefaultRetention` settings require both a mode and a period. + # + # * The `DefaultRetention` period can be either `Days` or `Years` but + # you must select one. You cannot specify `Days` and `Years` at the + # same time. + # + # * You can enable Object Lock for new or existing buckets. For more + # information, see [Configuring Object Lock][2]. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-configure.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_object_lock_configuration({ + # bucket: "BucketName", # required + # object_lock_configuration: { + # object_lock_enabled: "Enabled", # accepts Enabled + # rule: { + # default_retention: { + # mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # days: 1, + # years: 1, + # }, + # }, + # }, + # request_payer: "requester", # accepts requester + # token: "ObjectLockToken", + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_object_lock_configuration + # @param params [Hash] ({}) + # @return [Types::PutObjectLockConfigurationOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectLockConfigurationOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectLockConfiguration AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#16257 + def put_object_lock_configuration(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Places an Object Retention configuration on an object. For more + # information, see [Locking Objects][1]. Users or accounts require the + # `s3:PutObjectRetention` permission in order to place an Object + # Retention configuration on objects. Bypassing a Governance Retention + # configuration requires the `s3:BypassGovernanceRetention` permission. + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_object_retention({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # retention: { + # mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # retain_until_date: Time.now, + # }, + # request_payer: "requester", # accepts requester + # version_id: "ObjectVersionId", + # bypass_governance_retention: false, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_object_retention + # @param params [Hash] ({}) + # @return [Types::PutObjectRetentionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectRetentionOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectRetention AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#16386 + def put_object_retention(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Sets the supplied tag-set to an object that already exists in a + # bucket. A tag is a key-value pair. For more information, see [Object + # Tagging][1]. + # + # You can associate tags with an object by sending a PUT request against + # the tagging subresource that is associated with the object. You can + # retrieve tags by sending a GET request. For more information, see + # [GetObjectTagging][2]. + # + # For tagging-related restrictions related to characters and encodings, + # see [Tag Restrictions][3]. Note that Amazon S3 limits the maximum + # number of tags to 10 tags per object. + # + # To use this operation, you must have permission to perform the + # `s3:PutObjectTagging` action. By default, the bucket owner has this + # permission and can grant this permission to others. + # + # To put tags of any other version, use the `versionId` query parameter. + # You also need permission for the `s3:PutObjectVersionTagging` action. + # + # `PutObjectTagging` has the following special errors. For more Amazon + # S3 errors see, [Error Responses][4]. + # + # * `InvalidTag` - The tag provided was not a valid tag. This error can + # occur if the tag did not pass input validation. For more + # information, see [Object Tagging][1]. + # + # * `MalformedXML` - The XML provided does not match the schema. + # + # * `OperationAborted` - A conflicting conditional action is currently + # in progress against this resource. Please try again. + # + # * `InternalError` - The service was unable to apply the provided tag + # to the object. + # + # The following operations are related to `PutObjectTagging`: + # + # * [GetObjectTagging][2] + # + # * [DeleteObjectTagging][5] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-tagging.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectTagging.html + # [3]: https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/allocation-tag-restrictions.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObjectTagging.html + # + # @example Example: To add tags to an existing object + # + # # The following example adds tags to an existing object. + # + # resp = client.put_object_tagging({ + # bucket: "examplebucket", + # key: "HappyFace.jpg", + # tagging: { + # tag_set: [ + # { + # key: "Key3", + # value: "Value3", + # }, + # { + # key: "Key4", + # value: "Value4", + # }, + # ], + # }, + # }) + # + # resp.to_h outputs the following: + # { + # version_id: "null", + # } + # @example Request syntax with placeholder values + # + # resp = client.put_object_tagging({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # tagging: { # required + # tag_set: [ # required + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # expected_bucket_owner: "AccountId", + # request_payer: "requester", # accepts requester + # }) + # @example Response structure + # + # resp.version_id #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_object_tagging + # @param params [Hash] ({}) + # @return [Types::PutObjectTaggingOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectTaggingOutput#version_id #version_id} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectTagging AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#16585 + def put_object_tagging(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Creates or modifies the `PublicAccessBlock` configuration for an + # Amazon S3 bucket. To use this operation, you must have the + # `s3:PutBucketPublicAccessBlock` permission. For more information about + # Amazon S3 permissions, see [Specifying Permissions in a Policy][1]. + # + # When Amazon S3 evaluates the `PublicAccessBlock` configuration for a + # bucket or an object, it checks the `PublicAccessBlock` configuration + # for both the bucket (or the bucket that contains the object) and the + # bucket owner's account. If the `PublicAccessBlock` configurations are + # different between the bucket and the account, Amazon S3 uses the most + # restrictive combination of the bucket-level and account-level + # settings. + # + # For more information about when Amazon S3 considers a bucket or an + # object public, see [The Meaning of "Public"][2]. + # + # The following operations are related to `PutPublicAccessBlock`: + # + # * [GetPublicAccessBlock][3] + # + # * [DeletePublicAccessBlock][4] + # + # * [GetBucketPolicyStatus][5] + # + # * [Using Amazon S3 Block Public Access][6] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetPublicAccessBlock.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeletePublicAccessBlock.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketPolicyStatus.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html + # + # @example Request syntax with placeholder values + # + # resp = client.put_public_access_block({ + # bucket: "BucketName", # required + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # public_access_block_configuration: { # required + # block_public_acls: false, + # ignore_public_acls: false, + # block_public_policy: false, + # restrict_public_buckets: false, + # }, + # expected_bucket_owner: "AccountId", + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload put_public_access_block + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutPublicAccessBlock AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#16693 + def put_public_access_block(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # Restores an archived copy of an object back into Amazon S3 + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # This action performs the following types of requests: + # + # * `restore an archive` - Restore an archived object + # + # ^ + # + # For more information about the `S3` structure in the request body, see + # the following: + # + # * [PutObject][1] + # + # * [Managing Access with ACLs][2] in the *Amazon S3 User Guide* + # + # * [Protecting Data Using Server-Side Encryption][3] in the *Amazon S3 + # User Guide* + # + # Permissions + # + # : To use this operation, you must have permissions to perform the + # `s3:RestoreObject` action. The bucket owner has this permission by + # default and can grant this permission to others. For more + # information about permissions, see [Permissions Related to Bucket + # Subresource Operations][4] and [Managing Access Permissions to Your + # Amazon S3 Resources][5] in the *Amazon S3 User Guide*. + # + # Restoring objects + # + # : Objects that you archive to the S3 Glacier Flexible Retrieval + # Flexible Retrieval or S3 Glacier Deep Archive storage class, and S3 + # Intelligent-Tiering Archive or S3 Intelligent-Tiering Deep Archive + # tiers, are not accessible in real time. For objects in the S3 + # Glacier Flexible Retrieval Flexible Retrieval or S3 Glacier Deep + # Archive storage classes, you must first initiate a restore request, + # and then wait until a temporary copy of the object is available. If + # you want a permanent copy of the object, create a copy of it in the + # Amazon S3 Standard storage class in your S3 bucket. To access an + # archived object, you must restore the object for the duration + # (number of days) that you specify. For objects in the Archive Access + # or Deep Archive Access tiers of S3 Intelligent-Tiering, you must + # first initiate a restore request, and then wait until the object is + # moved into the Frequent Access tier. + # + # To restore a specific object version, you can provide a version ID. + # If you don't provide a version ID, Amazon S3 restores the current + # version. + # + # When restoring an archived object, you can specify one of the + # following data access tier options in the `Tier` element of the + # request body: + # + # * `Expedited` - Expedited retrievals allow you to quickly access + # your data stored in the S3 Glacier Flexible Retrieval Flexible + # Retrieval storage class or S3 Intelligent-Tiering Archive tier + # when occasional urgent requests for restoring archives are + # required. For all but the largest archived objects (250 MB+), data + # accessed using Expedited retrievals is typically made available + # within 1–5 minutes. Provisioned capacity ensures that retrieval + # capacity for Expedited retrievals is available when you need it. + # Expedited retrievals and provisioned capacity are not available + # for objects stored in the S3 Glacier Deep Archive storage class or + # S3 Intelligent-Tiering Deep Archive tier. + # + # * `Standard` - Standard retrievals allow you to access any of your + # archived objects within several hours. This is the default option + # for retrieval requests that do not specify the retrieval option. + # Standard retrievals typically finish within 3–5 hours for objects + # stored in the S3 Glacier Flexible Retrieval Flexible Retrieval + # storage class or S3 Intelligent-Tiering Archive tier. They + # typically finish within 12 hours for objects stored in the S3 + # Glacier Deep Archive storage class or S3 Intelligent-Tiering Deep + # Archive tier. Standard retrievals are free for objects stored in + # S3 Intelligent-Tiering. + # + # * `Bulk` - Bulk retrievals free for objects stored in the S3 Glacier + # Flexible Retrieval and S3 Intelligent-Tiering storage classes, + # enabling you to retrieve large amounts, even petabytes, of data at + # no cost. Bulk retrievals typically finish within 5–12 hours for + # objects stored in the S3 Glacier Flexible Retrieval Flexible + # Retrieval storage class or S3 Intelligent-Tiering Archive tier. + # Bulk retrievals are also the lowest-cost retrieval option when + # restoring objects from S3 Glacier Deep Archive. They typically + # finish within 48 hours for objects stored in the S3 Glacier Deep + # Archive storage class or S3 Intelligent-Tiering Deep Archive tier. + # + # For more information about archive retrieval options and provisioned + # capacity for `Expedited` data access, see [Restoring Archived + # Objects][6] in the *Amazon S3 User Guide*. + # + # You can use Amazon S3 restore speed upgrade to change the restore + # speed to a faster speed while it is in progress. For more + # information, see [ Upgrading the speed of an in-progress restore][7] + # in the *Amazon S3 User Guide*. + # + # To get the status of object restoration, you can send a `HEAD` + # request. Operations return the `x-amz-restore` header, which + # provides information about the restoration status, in the response. + # You can use Amazon S3 event notifications to notify you when a + # restore is initiated or completed. For more information, see + # [Configuring Amazon S3 Event Notifications][8] in the *Amazon S3 + # User Guide*. + # + # After restoring an archived object, you can update the restoration + # period by reissuing the request with a new period. Amazon S3 updates + # the restoration period relative to the current time and charges only + # for the request-there are no data transfer charges. You cannot + # update the restoration period when Amazon S3 is actively processing + # your current restore request for the object. + # + # If your bucket has a lifecycle configuration with a rule that + # includes an expiration action, the object expiration overrides the + # life span that you specify in a restore request. For example, if you + # restore an object copy for 10 days, but the object is scheduled to + # expire in 3 days, Amazon S3 deletes the object in 3 days. For more + # information about lifecycle configuration, see + # [PutBucketLifecycleConfiguration][9] and [Object Lifecycle + # Management][10] in *Amazon S3 User Guide*. + # + # Responses + # + # : A successful action returns either the `200 OK` or `202 Accepted` + # status code. + # + # * If the object is not previously restored, then Amazon S3 returns + # `202 Accepted` in the response. + # + # * If the object is previously restored, Amazon S3 returns `200 OK` + # in the response. + # ^ + # + # * Special errors: + # + # * *Code: RestoreAlreadyInProgress* + # + # * *Cause: Object restore is already in progress.* + # + # * *HTTP Status Code: 409 Conflict* + # + # * *SOAP Fault Code Prefix: Client* + # + # * * *Code: GlacierExpeditedRetrievalNotAvailable* + # + # * *Cause: expedited retrievals are currently not available. Try + # again later. (Returned if there is insufficient capacity to + # process the Expedited request. This error applies only to + # Expedited retrievals and not to S3 Standard or Bulk + # retrievals.)* + # + # * *HTTP Status Code: 503* + # + # * *SOAP Fault Code Prefix: N/A* + # + # The following operations are related to `RestoreObject`: + # + # * [PutBucketLifecycleConfiguration][9] + # + # * [GetBucketNotificationConfiguration][11] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObject.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/S3_ACLs_UsingACLs.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/serv-side-encryption.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/restoring-objects.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/dev/restoring-objects.html#restoring-objects-upgrade-tier.title.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketNotificationConfiguration.html + # + # @example Example: To restore an archived object + # + # # The following example restores for one day an archived copy of an object back into Amazon S3 bucket. + # + # resp = client.restore_object({ + # bucket: "examplebucket", + # key: "archivedobjectkey", + # restore_request: { + # days: 1, + # glacier_job_parameters: { + # tier: "Expedited", + # }, + # }, + # }) + # + # resp.to_h outputs the following: + # { + # } + # @example Request syntax with placeholder values + # + # resp = client.restore_object({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # version_id: "ObjectVersionId", + # restore_request: { + # days: 1, + # glacier_job_parameters: { + # tier: "Standard", # required, accepts Standard, Bulk, Expedited + # }, + # type: "SELECT", # accepts SELECT + # tier: "Standard", # accepts Standard, Bulk, Expedited + # description: "Description", + # select_parameters: { + # input_serialization: { # required + # csv: { + # file_header_info: "USE", # accepts USE, IGNORE, NONE + # comments: "Comments", + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # allow_quoted_record_delimiter: false, + # }, + # compression_type: "NONE", # accepts NONE, GZIP, BZIP2 + # json: { + # type: "DOCUMENT", # accepts DOCUMENT, LINES + # }, + # parquet: { + # }, + # }, + # expression_type: "SQL", # required, accepts SQL + # expression: "Expression", # required + # output_serialization: { # required + # csv: { + # quote_fields: "ALWAYS", # accepts ALWAYS, ASNEEDED + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # }, + # json: { + # record_delimiter: "RecordDelimiter", + # }, + # }, + # }, + # output_location: { + # s3: { + # bucket_name: "BucketName", # required + # prefix: "LocationPrefix", # required + # encryption: { + # encryption_type: "AES256", # required, accepts AES256, aws:kms, aws:kms:dsse + # kms_key_id: "SSEKMSKeyId", + # kms_context: "KMSContext", + # }, + # canned_acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # access_control_list: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, WRITE, WRITE_ACP, READ, READ_ACP + # }, + # ], + # tagging: { + # tag_set: [ # required + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # user_metadata: [ + # { + # name: "MetadataKey", + # value: "MetadataValue", + # }, + # ], + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # }, + # }, + # }, + # request_payer: "requester", # accepts requester + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.request_charged #=> String, one of "requester" + # resp.restore_output_path #=> String + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload restore_object + # @param params [Hash] ({}) + # @return [Types::RestoreObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::RestoreObjectOutput#request_charged #request_charged} => String + # * {Types::RestoreObjectOutput#restore_output_path #restore_output_path} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreObject AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#17078 + def restore_object(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # This operation is not supported by directory buckets. + # + # + # + # This action filters the contents of an Amazon S3 object based on a + # simple structured query language (SQL) statement. In the request, + # along with the SQL expression, you must also specify a data + # serialization format (JSON, CSV, or Apache Parquet) of the object. + # Amazon S3 uses this format to parse object data into records, and + # returns only records that match the specified SQL expression. You must + # also specify the data serialization format for the response. + # + # This functionality is not supported for Amazon S3 on Outposts. + # + # For more information about Amazon S3 Select, see [Selecting Content + # from Objects][1] and [SELECT Command][2] in the *Amazon S3 User + # Guide*. + # + # + # + # Permissions + # + # : You must have the `s3:GetObject` permission for this + # operation. Amazon S3 Select does not support anonymous access. For + # more information about permissions, see [Specifying Permissions in a + # Policy][3] in the *Amazon S3 User Guide*. + # + # Object Data Formats + # + # : You can use Amazon S3 Select to query objects that have the + # following format properties: + # + # * *CSV, JSON, and Parquet* - Objects must be in CSV, JSON, or + # Parquet format. + # + # * *UTF-8* - UTF-8 is the only encoding type Amazon S3 Select + # supports. + # + # * *GZIP or BZIP2* - CSV and JSON files can be compressed using GZIP + # or BZIP2. GZIP and BZIP2 are the only compression formats that + # Amazon S3 Select supports for CSV and JSON files. Amazon S3 Select + # supports columnar compression for Parquet using GZIP or Snappy. + # Amazon S3 Select does not support whole-object compression for + # Parquet objects. + # + # * *Server-side encryption* - Amazon S3 Select supports querying + # objects that are protected with server-side encryption. + # + # For objects that are encrypted with customer-provided encryption + # keys (SSE-C), you must use HTTPS, and you must use the headers + # that are documented in the [GetObject][4]. For more information + # about SSE-C, see [Server-Side Encryption (Using Customer-Provided + # Encryption Keys)][5] in the *Amazon S3 User Guide*. + # + # For objects that are encrypted with Amazon S3 managed keys + # (SSE-S3) and Amazon Web Services KMS keys (SSE-KMS), server-side + # encryption is handled transparently, so you don't need to specify + # anything. For more information about server-side encryption, + # including SSE-S3 and SSE-KMS, see [Protecting Data Using + # Server-Side Encryption][6] in the *Amazon S3 User Guide*. + # + # Working with the Response Body + # + # : Given the response size is unknown, Amazon S3 Select streams the + # response as a series of messages and includes a `Transfer-Encoding` + # header with `chunked` as its value in the response. For more + # information, see [Appendix: SelectObjectContent Response][7]. + # + # GetObject Support + # + # : The `SelectObjectContent` action does not support the following + # `GetObject` functionality. For more information, see [GetObject][4]. + # + # * `Range`: Although you can specify a scan range for an Amazon S3 + # Select request (see [SelectObjectContentRequest - ScanRange][8] in + # the request parameters), you cannot specify the range of bytes of + # an object to return. + # + # * The `GLACIER`, `DEEP_ARCHIVE`, and `REDUCED_REDUNDANCY` storage + # classes, or the `ARCHIVE_ACCESS` and `DEEP_ARCHIVE_ACCESS` access + # tiers of the `INTELLIGENT_TIERING` storage class: You cannot query + # objects in the `GLACIER`, `DEEP_ARCHIVE`, or `REDUCED_REDUNDANCY` + # storage classes, nor objects in the `ARCHIVE_ACCESS` or + # `DEEP_ARCHIVE_ACCESS` access tiers of the `INTELLIGENT_TIERING` + # storage class. For more information about storage classes, see + # [Using Amazon S3 storage classes][9] in the *Amazon S3 User + # Guide*. + # + # Special Errors + # + # : For a list of special errors for this operation, see [List of SELECT + # Object Content Error Codes][10] + # + # The following operations are related to `SelectObjectContent`: + # + # * [GetObject][4] + # + # * [GetBucketLifecycleConfiguration][11] + # + # * [PutBucketLifecycleConfiguration][12] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/selecting-content-from-objects.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-glacier-select-sql-reference-select.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/serv-side-encryption.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTSelectObjectAppendix.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_SelectObjectContent.html#AmazonS3-SelectObjectContent-request-ScanRange + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/storage-class-intro.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#SelectObjectContentErrorCodeList + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycleConfiguration.html + # [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html + # + # @example EventStream Operation Example + # + # You can process the event once it arrives immediately, or wait until the + # full response is complete and iterate through the eventstream enumerator. + # + # To interact with event immediately, you need to register #select_object_content + # with callbacks. Callbacks can be registered for specific events or for all + # events, including error events. + # + # Callbacks can be passed into the `:event_stream_handler` option or within a + # block statement attached to the #select_object_content call directly. Hybrid + # pattern of both is also supported. + # + # `:event_stream_handler` option takes in either a Proc object or + # Aws::S3::EventStreams::SelectObjectContentEventStream object. + # + # Usage pattern a): Callbacks with a block attached to #select_object_content + # Example for registering callbacks for all event types and an error event + # + # client.select_object_content( # params input# ) do |stream| + # stream.on_error_event do |event| + # # catch unmodeled error event in the stream + # raise event + # # => Aws::Errors::EventError + # # event.event_type => :error + # # event.error_code => String + # # event.error_message => String + # end + # + # stream.on_event do |event| + # # process all events arrive + # puts event.event_type + # ... + # end + # + # end + # + # Usage pattern b): Pass in `:event_stream_handler` for #select_object_content + # + # 1) Create a Aws::S3::EventStreams::SelectObjectContentEventStream object + # Example for registering callbacks with specific events + # + # handler = Aws::S3::EventStreams::SelectObjectContentEventStream.new + # handler.on_records_event do |event| + # event # => Aws::S3::Types::Records + # end + # handler.on_stats_event do |event| + # event # => Aws::S3::Types::Stats + # end + # handler.on_progress_event do |event| + # event # => Aws::S3::Types::Progress + # end + # handler.on_cont_event do |event| + # event # => Aws::S3::Types::Cont + # end + # handler.on_end_event do |event| + # event # => Aws::S3::Types::End + # end + # + # client.select_object_content( # params input #, event_stream_handler: handler) + # + # 2) Use a Ruby Proc object + # Example for registering callbacks with specific events + # + # handler = Proc.new do |stream| + # stream.on_records_event do |event| + # event # => Aws::S3::Types::Records + # end + # stream.on_stats_event do |event| + # event # => Aws::S3::Types::Stats + # end + # stream.on_progress_event do |event| + # event # => Aws::S3::Types::Progress + # end + # stream.on_cont_event do |event| + # event # => Aws::S3::Types::Cont + # end + # stream.on_end_event do |event| + # event # => Aws::S3::Types::End + # end + # end + # + # client.select_object_content( # params input #, event_stream_handler: handler) + # + # Usage pattern c): Hybrid pattern of a) and b) + # + # handler = Aws::S3::EventStreams::SelectObjectContentEventStream.new + # handler.on_records_event do |event| + # event # => Aws::S3::Types::Records + # end + # handler.on_stats_event do |event| + # event # => Aws::S3::Types::Stats + # end + # handler.on_progress_event do |event| + # event # => Aws::S3::Types::Progress + # end + # handler.on_cont_event do |event| + # event # => Aws::S3::Types::Cont + # end + # handler.on_end_event do |event| + # event # => Aws::S3::Types::End + # end + # + # client.select_object_content( # params input #, event_stream_handler: handler) do |stream| + # stream.on_error_event do |event| + # # catch unmodeled error event in the stream + # raise event + # # => Aws::Errors::EventError + # # event.event_type => :error + # # event.error_code => String + # # event.error_message => String + # end + # end + # + # You can also iterate through events after the response complete. + # + # Events are available at resp.payload # => Enumerator + # For parameter input example, please refer to following request syntax + # @example Request syntax with placeholder values + # + # resp = client.select_object_content({ + # bucket: "BucketName", # required + # key: "ObjectKey", # required + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # expression: "Expression", # required + # expression_type: "SQL", # required, accepts SQL + # request_progress: { + # enabled: false, + # }, + # input_serialization: { # required + # csv: { + # file_header_info: "USE", # accepts USE, IGNORE, NONE + # comments: "Comments", + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # allow_quoted_record_delimiter: false, + # }, + # compression_type: "NONE", # accepts NONE, GZIP, BZIP2 + # json: { + # type: "DOCUMENT", # accepts DOCUMENT, LINES + # }, + # parquet: { + # }, + # }, + # output_serialization: { # required + # csv: { + # quote_fields: "ALWAYS", # accepts ALWAYS, ASNEEDED + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # }, + # json: { + # record_delimiter: "RecordDelimiter", + # }, + # }, + # scan_range: { + # start: 1, + # end: 1, + # }, + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # All events are available at resp.payload: + # resp.payload #=> Enumerator + # resp.payload.event_types #=> [:records, :stats, :progress, :cont, :end] + # + # For :records event available at #on_records_event callback and response eventstream enumerator: + # event.payload #=> IO + # + # For :stats event available at #on_stats_event callback and response eventstream enumerator: + # event.details.bytes_scanned #=> Integer + # event.details.bytes_processed #=> Integer + # event.details.bytes_returned #=> Integer + # + # For :progress event available at #on_progress_event callback and response eventstream enumerator: + # event.details.bytes_scanned #=> Integer + # event.details.bytes_processed #=> Integer + # event.details.bytes_returned #=> Integer + # + # For :cont event available at #on_cont_event callback and response eventstream enumerator: + # #=> EmptyStruct + # For :end event available at #on_end_event callback and response eventstream enumerator: + # #=> EmptyStruct + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload select_object_content + # @param params [Hash] ({}) + # @return [Types::SelectObjectContentOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::SelectObjectContentOutput#payload #payload} => Types::SelectObjectContentEventStream + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SelectObjectContent AWS API Documentation + # @yield [event_stream_handler] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#17475 + def select_object_content(params = T.unsafe(nil), options = T.unsafe(nil), &block); end + + # Uploads a part in a multipart upload. + # + # In this operation, you provide new data as a part of an object in your + # request. However, you have an option to specify your existing Amazon + # S3 object as a data source for the part you are uploading. To upload a + # part from an existing object, you use the [UploadPartCopy][1] + # operation. + # + # + # + # You must initiate a multipart upload (see [CreateMultipartUpload][2]) + # before you can upload any part. In response to your initiate request, + # Amazon S3 returns an upload ID, a unique identifier that you must + # include in your upload part request. + # + # Part numbers can be any number from 1 to 10,000, inclusive. A part + # number uniquely identifies a part and also defines its position within + # the object being created. If you upload a new part using the same part + # number that was used with a previous part, the previously uploaded + # part is overwritten. + # + # For information about maximum and minimum part sizes and other + # multipart upload specifications, see [Multipart upload limits][3] in + # the *Amazon S3 User Guide*. + # + # After you initiate multipart upload and upload one or more parts, you + # must either complete or abort multipart upload in order to stop + # getting charged for storage of the uploaded parts. Only after you + # either complete or abort multipart upload, Amazon S3 frees up the + # parts storage and stops charging you for the parts storage. + # + # + # + # For more information on multipart uploads, go to [Multipart Upload + # Overview][4] in the Amazon S3 User Guide . + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][5] in the *Amazon S3 User Guide*. + # + # + # + # Permissions + # : * **General purpose bucket permissions** - For information on the + # permissions required to use the multipart upload API, see + # [Multipart Upload and Permissions][6] in the *Amazon S3 User + # Guide*. + # + # * **Directory bucket permissions** - To grant access to this API + # operation on a directory bucket, we recommend that you use the [ + # `CreateSession` ][7] API operation for session-based + # authorization. Specifically, you grant the + # `s3express:CreateSession` permission to the directory bucket in a + # bucket policy or an IAM identity-based policy. Then, you make the + # `CreateSession` API call on the bucket to obtain a session token. + # With the session token in your request header, you can make API + # requests to this operation. After the session token expires, you + # make another `CreateSession` API call to generate a new session + # token for use. Amazon Web Services CLI or SDKs create session and + # refresh the session token automatically to avoid service + # interruptions when a session expires. For more information about + # authorization, see [ `CreateSession` ][7]. + # + # Data integrity + # + # : **General purpose bucket** - To ensure that data is not corrupted + # traversing the network, specify the `Content-MD5` header in the + # upload part request. Amazon S3 checks the part data against the + # provided MD5 value. If they do not match, Amazon S3 returns an + # error. If the upload request is signed with Signature Version 4, + # then Amazon Web Services S3 uses the `x-amz-content-sha256` header + # as a checksum instead of `Content-MD5`. For more information see + # [Authenticating Requests: Using the Authorization Header (Amazon Web + # Services Signature Version 4)][8]. + # + # **Directory buckets** - MD5 is not supported by directory buckets. + # You can use checksum algorithms to check object integrity. + # + # + # + # Encryption + # : * **General purpose bucket** - Server-side encryption is for data + # encryption at rest. Amazon S3 encrypts your data as it writes it + # to disks in its data centers and decrypts it when you access it. + # You have mutually exclusive options to protect data using + # server-side encryption in Amazon S3, depending on how you choose + # to manage the encryption keys. Specifically, the encryption key + # options are Amazon S3 managed keys (SSE-S3), Amazon Web Services + # KMS keys (SSE-KMS), and Customer-Provided Keys (SSE-C). Amazon S3 + # encrypts data with server-side encryption using Amazon S3 managed + # keys (SSE-S3) by default. You can optionally tell Amazon S3 to + # encrypt data at rest using server-side encryption with other key + # options. The option you use depends on whether you want to use KMS + # keys (SSE-KMS) or provide your own encryption key (SSE-C). + # + # Server-side encryption is supported by the S3 Multipart Upload + # operations. Unless you are using a customer-provided encryption + # key (SSE-C), you don't need to specify the encryption parameters + # in each UploadPart request. Instead, you only need to specify the + # server-side encryption parameters in the initial Initiate + # Multipart request. For more information, see + # [CreateMultipartUpload][2]. + # + # If you request server-side encryption using a customer-provided + # encryption key (SSE-C) in your initiate multipart upload request, + # you must provide identical encryption information in each part + # upload using the following request headers. + # + # * x-amz-server-side-encryption-customer-algorithm + # + # * x-amz-server-side-encryption-customer-key + # + # * x-amz-server-side-encryption-customer-key-MD5 + # + # * **Directory bucket** - For directory buckets, only server-side + # encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) is + # supported. + # + # For more information, see [Using Server-Side Encryption][9] in the + # *Amazon S3 User Guide*. + # + # Special errors + # : * Error Code: `NoSuchUpload` + # + # * Description: The specified multipart upload does not exist. The + # upload ID might be invalid, or the multipart upload might have + # been aborted or completed. + # + # * HTTP Status Code: 404 Not Found + # + # * SOAP Fault Code Prefix: Client + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `UploadPart`: + # + # * [CreateMultipartUpload][2] + # + # * [CompleteMultipartUpload][10] + # + # * [AbortMultipartUpload][11] + # + # * [ListParts][12] + # + # * [ListMultipartUploads][13] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/qfacts.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-auth-using-authorization-header.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html + # [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # [13]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html + # + # @example Example: To upload a part + # + # # The following example uploads part 1 of a multipart upload. The example specifies a file name for the part data. The + # # Upload ID is same that is returned by the initiate multipart upload. + # + # resp = client.upload_part({ + # body: "fileToUpload", + # bucket: "examplebucket", + # key: "examplelargeobject", + # part_number: 1, + # upload_id: "xadcOB_7YPBOJuoFiQ9cz4P3Pe6FIZwO4f7wN93uHsNBEw97pl5eNwzExg0LAT2dUN91cOmrEQHDsP3WA60CEg--", + # }) + # + # resp.to_h outputs the following: + # { + # etag: "\"d8c2eafd90c266e19ab9dcacc479f8af\"", + # } + # @example Request syntax with placeholder values + # + # resp = client.upload_part({ + # body: source_file, + # bucket: "BucketName", # required + # content_length: 1, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # key: "ObjectKey", # required + # part_number: 1, # required + # upload_id: "MultipartUploadId", # required + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.etag #=> String + # resp.checksum_crc32 #=> String + # resp.checksum_crc32c #=> String + # resp.checksum_sha1 #=> String + # resp.checksum_sha256 #=> String + # resp.sse_customer_algorithm #=> String + # resp.sse_customer_key_md5 #=> String + # resp.ssekms_key_id #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload upload_part + # @param params [Hash] ({}) + # @return [Types::UploadPartOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::UploadPartOutput#server_side_encryption #server_side_encryption} => String + # * {Types::UploadPartOutput#etag #etag} => String + # * {Types::UploadPartOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::UploadPartOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::UploadPartOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::UploadPartOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::UploadPartOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::UploadPartOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::UploadPartOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::UploadPartOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::UploadPartOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPart AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#17925 + def upload_part(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Uploads a part by copying data from an existing object as data source. + # To specify the data source, you add the request header + # `x-amz-copy-source` in your request. To specify a byte range, you add + # the request header `x-amz-copy-source-range` in your request. + # + # For information about maximum and minimum part sizes and other + # multipart upload specifications, see [Multipart upload limits][1] in + # the *Amazon S3 User Guide*. + # + # Instead of copying data from an existing object as part data, you + # might use the [UploadPart][2] action to upload new data as a part of + # an object in your request. + # + # + # + # You must initiate a multipart upload before you can upload any part. + # In response to your initiate request, Amazon S3 returns the upload ID, + # a unique identifier that you must include in your upload part request. + # + # For conceptual information about multipart uploads, see [Uploading + # Objects Using Multipart Upload][3] in the *Amazon S3 User Guide*. For + # information about copying objects using a single atomic action vs. a + # multipart upload, see [Operations on Objects][4] in the *Amazon S3 + # User Guide*. + # + # **Directory buckets** - For directory buckets, you must make requests + # for this API operation to the Zonal endpoint. These endpoints support + # virtual-hosted-style requests in the format + # `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name `. + # Path-style requests are not supported. For more information, see + # [Regional and Zonal endpoints][5] in the *Amazon S3 User Guide*. + # + # + # + # Authentication and authorization + # + # : All `UploadPartCopy` requests must be authenticated and signed by + # using IAM credentials (access key ID and secret access key for the + # IAM identities). All headers with the `x-amz-` prefix, including + # `x-amz-copy-source`, must be signed. For more information, see [REST + # Authentication][6]. + # + # **Directory buckets** - You must use IAM credentials to authenticate + # and authorize your access to the `UploadPartCopy` API operation, + # instead of using the temporary security credentials through the + # `CreateSession` API operation. + # + # Amazon Web Services CLI or SDKs handles authentication and + # authorization on your behalf. + # + # Permissions + # + # : You must have `READ` access to the source object and `WRITE` access + # to the destination bucket. + # + # * **General purpose bucket permissions** - You must have the + # permissions in a policy based on the bucket types of your source + # bucket and destination bucket in an `UploadPartCopy` operation. + # + # * If the source object is in a general purpose bucket, you must + # have the s3:GetObject permission to read + # the source object that is being copied. + # + # * If the destination bucket is a general purpose bucket, you must + # have the s3:PutObject permission to write + # the object copy to the destination bucket. + # + # For information about permissions required to use the multipart + # upload API, see [Multipart upload API and permissions][7] in the + # *Amazon S3 User Guide*. + # + # * **Directory bucket permissions** - You must have permissions in a + # bucket policy or an IAM identity-based policy based on the source + # and destination bucket types in an `UploadPartCopy` operation. + # + # * If the source object that you want to copy is in a directory + # bucket, you must have the + # s3express:CreateSession permission in the + # `Action` element of a policy to read the object. By default, the + # session is in the `ReadWrite` mode. If you want to restrict the + # access, you can explicitly set the `s3express:SessionMode` + # condition key to `ReadOnly` on the copy source bucket. + # + # * If the copy destination is a directory bucket, you must have the + # s3express:CreateSession permission in the + # `Action` element of a policy to write the object to the + # destination. The `s3express:SessionMode` condition key cannot be + # set to `ReadOnly` on the copy destination. + # + # For example policies, see [Example bucket policies for S3 Express + # One Zone][8] and [Amazon Web Services Identity and Access + # Management (IAM) identity-based policies for S3 Express One + # Zone][9] in the *Amazon S3 User Guide*. + # + # Encryption + # : * General purpose buckets - For information about using + # server-side encryption with customer-provided encryption keys with + # the `UploadPartCopy` operation, see [CopyObject][10] and + # [UploadPart][2]. + # + # * Directory buckets - For directory buckets, only + # server-side encryption with Amazon S3 managed keys (SSE-S3) + # (`AES256`) is supported. + # + # Special errors + # : * Error Code: `NoSuchUpload` + # + # * Description: The specified multipart upload does not exist. The + # upload ID might be invalid, or the multipart upload might have + # been aborted or completed. + # + # * HTTP Status Code: 404 Not Found + # + # * Error Code: `InvalidRequest` + # + # * Description: The specified copy source is not supported as a + # byte-range copy source. + # + # * HTTP Status Code: 400 Bad Request + # + # HTTP Host header syntax + # + # : Directory buckets - The HTTP Host header syntax is ` + # Bucket_name.s3express-az_id.region.amazonaws.com`. + # + # The following operations are related to `UploadPartCopy`: + # + # * [CreateMultipartUpload][11] + # + # * [UploadPart][2] + # + # * [CompleteMultipartUpload][12] + # + # * [AbortMultipartUpload][13] + # + # * [ListParts][14] + # + # * [ListMultipartUploads][15] + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/qfacts.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/uploadobjusingmpu.html + # [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectOperations.html + # [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html + # [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html + # [7]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/mpuoverview.html#mpuAndPermissions + # [8]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html + # [9]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-identity-policies.html + # [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html + # [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html + # [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html + # [13]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html + # [14]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html + # [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html + # + # @example Example: To upload a part by copying data from an existing object as data source + # + # # The following example uploads a part of a multipart upload by copying data from an existing object as data source. + # + # resp = client.upload_part_copy({ + # bucket: "examplebucket", + # copy_source: "/bucketname/sourceobjectkey", + # key: "examplelargeobject", + # part_number: 1, + # upload_id: "exampleuoh_10OhKhT7YukE9bjzTPRiuaCotmZM_pFngJFir9OZNrSr5cWa3cq3LZSUsfjI4FI7PkP91We7Nrw--", + # }) + # + # resp.to_h outputs the following: + # { + # copy_part_result: { + # etag: "\"b0c6f0e7e054ab8fa2536a2677f8734d\"", + # last_modified: Time.parse("2016-12-29T21:24:43.000Z"), + # }, + # } + # @example Example: To upload a part by copying byte range from an existing object as data source + # + # # The following example uploads a part of a multipart upload by copying a specified byte range from an existing object as + # # data source. + # + # resp = client.upload_part_copy({ + # bucket: "examplebucket", + # copy_source: "/bucketname/sourceobjectkey", + # copy_source_range: "bytes=1-100000", + # key: "examplelargeobject", + # part_number: 2, + # upload_id: "exampleuoh_10OhKhT7YukE9bjzTPRiuaCotmZM_pFngJFir9OZNrSr5cWa3cq3LZSUsfjI4FI7PkP91We7Nrw--", + # }) + # + # resp.to_h outputs the following: + # { + # copy_part_result: { + # etag: "\"65d16d19e65a7508a51f043180edcc36\"", + # last_modified: Time.parse("2016-12-29T21:44:28.000Z"), + # }, + # } + # @example Request syntax with placeholder values + # + # resp = client.upload_part_copy({ + # bucket: "BucketName", # required + # copy_source: "CopySource", # required + # copy_source_if_match: "CopySourceIfMatch", + # copy_source_if_modified_since: Time.now, + # copy_source_if_none_match: "CopySourceIfNoneMatch", + # copy_source_if_unmodified_since: Time.now, + # copy_source_range: "CopySourceRange", + # key: "ObjectKey", # required + # part_number: 1, # required + # upload_id: "MultipartUploadId", # required + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # copy_source_sse_customer_algorithm: "CopySourceSSECustomerAlgorithm", + # copy_source_sse_customer_key: "CopySourceSSECustomerKey", + # copy_source_sse_customer_key_md5: "CopySourceSSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # expected_source_bucket_owner: "AccountId", + # }) + # @example Response structure + # + # resp.copy_source_version_id #=> String + # resp.copy_part_result.etag #=> String + # resp.copy_part_result.last_modified #=> Time + # resp.copy_part_result.checksum_crc32 #=> String + # resp.copy_part_result.checksum_crc32c #=> String + # resp.copy_part_result.checksum_sha1 #=> String + # resp.copy_part_result.checksum_sha256 #=> String + # resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse" + # resp.sse_customer_algorithm #=> String + # resp.sse_customer_key_md5 #=> String + # resp.ssekms_key_id #=> String + # resp.bucket_key_enabled #=> Boolean + # resp.request_charged #=> String, one of "requester" + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload upload_part_copy + # @param params [Hash] ({}) + # @return [Types::UploadPartCopyOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::UploadPartCopyOutput#copy_source_version_id #copy_source_version_id} => String + # * {Types::UploadPartCopyOutput#copy_part_result #copy_part_result} => Types::CopyPartResult + # * {Types::UploadPartCopyOutput#server_side_encryption #server_side_encryption} => String + # * {Types::UploadPartCopyOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::UploadPartCopyOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::UploadPartCopyOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::UploadPartCopyOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::UploadPartCopyOutput#request_charged #request_charged} => String + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartCopy AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18457 + def upload_part_copy(params = T.unsafe(nil), options = T.unsafe(nil)); end + + # Polls an API operation until a resource enters a desired state. + # + # ## Basic Usage + # + # A waiter will call an API operation until: + # + # * It is successful + # * It enters a terminal state + # * It makes the maximum number of attempts + # + # In between attempts, the waiter will sleep. + # + # # polls in a loop, sleeping between attempts + # client.wait_until(waiter_name, params) + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. You can pass + # configuration as the final arguments hash. + # + # # poll for ~25 seconds + # client.wait_until(waiter_name, params, { + # max_attempts: 5, + # delay: 5, + # }) + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # client.wait_until(waiter_name, params, { + # + # # disable max attempts + # max_attempts: nil, + # + # # poll for 1 hour, instead of a number of attempts + # before_wait: -> (attempts, response) do + # throw :failure if Time.now - started_at > 3600 + # end + # }) + # + # ## Handling Errors + # + # When a waiter is unsuccessful, it will raise an error. + # All of the failure errors extend from + # {Aws::Waiters::Errors::WaiterFailed}. + # + # begin + # client.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # ## Valid Waiters + # + # The following table lists the valid waiter names, the operations they call, + # and the default `:delay` and `:max_attempts` values. + # + # | waiter_name | params | :delay | :max_attempts | + # | ----------------- | -------------------- | -------- | ------------- | + # | bucket_exists | {Client#head_bucket} | 5 | 20 | + # | bucket_not_exists | {Client#head_bucket} | 5 | 20 | + # | object_exists | {Client#head_object} | 5 | 20 | + # | object_not_exists | {Client#head_object} | 5 | 20 | + # + # @option options + # @option options + # @option options + # @option options + # @param waiter_name [Symbol] + # @param params [Hash] ({}) + # @param options [Hash] ({}) + # @raise [Errors::FailureStateError] Raised when the waiter terminates + # because the waiter has entered a state that it will not transition + # out of, preventing success. + # @raise [Errors::TooManyAttemptsError] Raised when the configured + # maximum number of attempts have been made, and the waiter is not + # yet successful. + # @raise [Errors::UnexpectedError] Raised when an error is encounted + # while polling for a resource that is not expected. + # @raise [Errors::NoSuchWaiterError] Raised when you request to wait + # for an unknown state. + # @return [Boolean] Returns `true` if the waiter was successful. + # @yield [w.waiter] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18961 + def wait_until(waiter_name, params = T.unsafe(nil), options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18969 + def waiter_names; end + + # This operation is not supported by directory buckets. + # + # + # + # Passes transformed objects to a `GetObject` operation when using + # Object Lambda access points. For information about Object Lambda + # access points, see [Transforming objects with Object Lambda access + # points][1] in the *Amazon S3 User Guide*. + # + # This operation supports metadata that can be returned by + # [GetObject][2], in addition to `RequestRoute`, `RequestToken`, + # `StatusCode`, `ErrorCode`, and `ErrorMessage`. The `GetObject` + # response metadata is supported so that the `WriteGetObjectResponse` + # caller, typically an Lambda function, can provide the same metadata + # when it internally invokes `GetObject`. When `WriteGetObjectResponse` + # is called by a customer-owned Lambda function, the metadata returned + # to the end user `GetObject` call might differ from what Amazon S3 + # would normally return. + # + # You can include any number of metadata headers. When including a + # metadata header, it should be prefaced with `x-amz-meta`. For example, + # `x-amz-meta-my-custom-header: MyCustomValue`. The primary use case for + # this is to forward `GetObject` metadata. + # + # Amazon Web Services provides some prebuilt Lambda functions that you + # can use with S3 Object Lambda to detect and redact personally + # identifiable information (PII) and decompress S3 objects. These Lambda + # functions are available in the Amazon Web Services Serverless + # Application Repository, and can be selected through the Amazon Web + # Services Management Console when you create your Object Lambda access + # point. + # + # Example 1: PII Access Control - This Lambda function uses Amazon + # Comprehend, a natural language processing (NLP) service using machine + # learning to find insights and relationships in text. It automatically + # detects personally identifiable information (PII) such as names, + # addresses, dates, credit card numbers, and social security numbers + # from documents in your Amazon S3 bucket. + # + # Example 2: PII Redaction - This Lambda function uses Amazon + # Comprehend, a natural language processing (NLP) service using machine + # learning to find insights and relationships in text. It automatically + # redacts personally identifiable information (PII) such as names, + # addresses, dates, credit card numbers, and social security numbers + # from documents in your Amazon S3 bucket. + # + # Example 3: Decompression - The Lambda function + # S3ObjectLambdaDecompression, is equipped to decompress objects stored + # in S3 in one of six compressed file formats including bzip2, gzip, + # snappy, zlib, zstandard and ZIP. + # + # For information on how to view and use these functions, see [Using + # Amazon Web Services built Lambda functions][3] in the *Amazon S3 User + # Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/transforming-objects.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html + # [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/olap-examples.html + # + # @example Request syntax with placeholder values + # + # resp = client.write_get_object_response({ + # request_route: "RequestRoute", # required + # request_token: "RequestToken", # required + # body: source_file, + # status_code: 1, + # error_code: "ErrorCode", + # error_message: "ErrorMessage", + # accept_ranges: "AcceptRanges", + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_length: 1, + # content_range: "ContentRange", + # content_type: "ContentType", + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # delete_marker: false, + # etag: "ETag", + # expires: Time.now, + # expiration: "Expiration", + # last_modified: Time.now, + # missing_meta: 1, + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # object_lock_retain_until_date: Time.now, + # parts_count: 1, + # replication_status: "COMPLETE", # accepts COMPLETE, PENDING, FAILED, REPLICA, COMPLETED + # request_charged: "requester", # accepts requester + # restore: "Restore", + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # sse_customer_algorithm: "SSECustomerAlgorithm", + # ssekms_key_id: "SSEKMSKeyId", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # tag_count: 1, + # version_id: "ObjectVersionId", + # bucket_key_enabled: false, + # }) + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @overload write_get_object_response + # @param params [Hash] ({}) + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/WriteGetObjectResponse AWS API Documentation + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18848 + def write_get_object_response(params = T.unsafe(nil), options = T.unsafe(nil)); end + + private + + # @param waiter_name [Symbol] + # @param options [Hash] ({}) + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18977 + def waiter(waiter_name, options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18986 + def waiters; end + + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#19001 + def errors_module; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/client.rb#18998 + def identifier; end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#12 +module Aws::S3::ClientApi + include ::Seahorse::Model +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#2763 +Aws::S3::ClientApi::API = T.let(T.unsafe(nil), Seahorse::Model::Api) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#16 +Aws::S3::ClientApi::AbortDate = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#17 +Aws::S3::ClientApi::AbortIncompleteMultipartUpload = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#18 +Aws::S3::ClientApi::AbortMultipartUploadOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#19 +Aws::S3::ClientApi::AbortMultipartUploadRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#20 +Aws::S3::ClientApi::AbortRuleId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#21 +Aws::S3::ClientApi::AccelerateConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#22 +Aws::S3::ClientApi::AcceptRanges = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#23 +Aws::S3::ClientApi::AccessControlPolicy = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#24 +Aws::S3::ClientApi::AccessControlTranslation = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#25 +Aws::S3::ClientApi::AccessKeyIdValue = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#26 +Aws::S3::ClientApi::AccessPointAlias = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#27 +Aws::S3::ClientApi::AccessPointArn = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#28 +Aws::S3::ClientApi::AccountId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#29 +Aws::S3::ClientApi::AllowQuotedRecordDelimiter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#30 +Aws::S3::ClientApi::AllowedHeader = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#31 +Aws::S3::ClientApi::AllowedHeaders = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#32 +Aws::S3::ClientApi::AllowedMethod = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#33 +Aws::S3::ClientApi::AllowedMethods = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#34 +Aws::S3::ClientApi::AllowedOrigin = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#35 +Aws::S3::ClientApi::AllowedOrigins = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#36 +Aws::S3::ClientApi::AnalyticsAndOperator = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#37 +Aws::S3::ClientApi::AnalyticsConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#38 +Aws::S3::ClientApi::AnalyticsConfigurationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#39 +Aws::S3::ClientApi::AnalyticsExportDestination = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#40 +Aws::S3::ClientApi::AnalyticsFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#41 +Aws::S3::ClientApi::AnalyticsId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#42 +Aws::S3::ClientApi::AnalyticsS3BucketDestination = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#43 +Aws::S3::ClientApi::AnalyticsS3ExportFileFormat = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#44 +Aws::S3::ClientApi::ArchiveStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#45 +Aws::S3::ClientApi::Body = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BlobShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#46 +Aws::S3::ClientApi::Bucket = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#47 +Aws::S3::ClientApi::BucketAccelerateStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#48 +Aws::S3::ClientApi::BucketAlreadyExists = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#49 +Aws::S3::ClientApi::BucketAlreadyOwnedByYou = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#50 +Aws::S3::ClientApi::BucketCannedACL = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#51 +Aws::S3::ClientApi::BucketInfo = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#52 +Aws::S3::ClientApi::BucketKeyEnabled = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#53 +Aws::S3::ClientApi::BucketLifecycleConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#54 +Aws::S3::ClientApi::BucketLocationConstraint = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#55 +Aws::S3::ClientApi::BucketLocationName = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#56 +Aws::S3::ClientApi::BucketLoggingStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#57 +Aws::S3::ClientApi::BucketLogsPermission = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#58 +Aws::S3::ClientApi::BucketName = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#59 +Aws::S3::ClientApi::BucketType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#60 +Aws::S3::ClientApi::BucketVersioningStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#61 +Aws::S3::ClientApi::Buckets = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#62 +Aws::S3::ClientApi::BypassGovernanceRetention = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#63 +Aws::S3::ClientApi::BytesProcessed = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#64 +Aws::S3::ClientApi::BytesReturned = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#65 +Aws::S3::ClientApi::BytesScanned = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#66 +Aws::S3::ClientApi::CORSConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#67 +Aws::S3::ClientApi::CORSRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#68 +Aws::S3::ClientApi::CORSRules = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#69 +Aws::S3::ClientApi::CSVInput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#70 +Aws::S3::ClientApi::CSVOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#71 +Aws::S3::ClientApi::CacheControl = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#72 +Aws::S3::ClientApi::Checksum = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#73 +Aws::S3::ClientApi::ChecksumAlgorithm = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#74 +Aws::S3::ClientApi::ChecksumAlgorithmList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#75 +Aws::S3::ClientApi::ChecksumCRC32 = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#76 +Aws::S3::ClientApi::ChecksumCRC32C = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#77 +Aws::S3::ClientApi::ChecksumMode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#78 +Aws::S3::ClientApi::ChecksumSHA1 = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#79 +Aws::S3::ClientApi::ChecksumSHA256 = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#80 +Aws::S3::ClientApi::CloudFunction = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#81 +Aws::S3::ClientApi::CloudFunctionConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#82 +Aws::S3::ClientApi::CloudFunctionInvocationRole = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#83 +Aws::S3::ClientApi::Code = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#84 +Aws::S3::ClientApi::Comments = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#85 +Aws::S3::ClientApi::CommonPrefix = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#86 +Aws::S3::ClientApi::CommonPrefixList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#87 +Aws::S3::ClientApi::CompleteMultipartUploadOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#88 +Aws::S3::ClientApi::CompleteMultipartUploadRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#89 +Aws::S3::ClientApi::CompletedMultipartUpload = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#90 +Aws::S3::ClientApi::CompletedPart = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#91 +Aws::S3::ClientApi::CompletedPartList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#92 +Aws::S3::ClientApi::CompressionType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#93 +Aws::S3::ClientApi::Condition = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#94 +Aws::S3::ClientApi::ConfirmRemoveSelfBucketAccess = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#95 +Aws::S3::ClientApi::ContentDisposition = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#96 +Aws::S3::ClientApi::ContentEncoding = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#97 +Aws::S3::ClientApi::ContentLanguage = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#98 +Aws::S3::ClientApi::ContentLength = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#99 +Aws::S3::ClientApi::ContentMD5 = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#100 +Aws::S3::ClientApi::ContentRange = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#101 +Aws::S3::ClientApi::ContentType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#102 +Aws::S3::ClientApi::ContinuationEvent = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#103 +Aws::S3::ClientApi::CopyObjectOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#104 +Aws::S3::ClientApi::CopyObjectRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#105 +Aws::S3::ClientApi::CopyObjectResult = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#106 +Aws::S3::ClientApi::CopyPartResult = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#107 +Aws::S3::ClientApi::CopySource = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#108 +Aws::S3::ClientApi::CopySourceIfMatch = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#109 +Aws::S3::ClientApi::CopySourceIfModifiedSince = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#110 +Aws::S3::ClientApi::CopySourceIfNoneMatch = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#111 +Aws::S3::ClientApi::CopySourceIfUnmodifiedSince = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#112 +Aws::S3::ClientApi::CopySourceRange = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#113 +Aws::S3::ClientApi::CopySourceSSECustomerAlgorithm = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#114 +Aws::S3::ClientApi::CopySourceSSECustomerKey = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#115 +Aws::S3::ClientApi::CopySourceSSECustomerKeyMD5 = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#116 +Aws::S3::ClientApi::CopySourceVersionId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#117 +Aws::S3::ClientApi::CreateBucketConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#118 +Aws::S3::ClientApi::CreateBucketOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#119 +Aws::S3::ClientApi::CreateBucketRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#120 +Aws::S3::ClientApi::CreateMultipartUploadOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#121 +Aws::S3::ClientApi::CreateMultipartUploadRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#122 +Aws::S3::ClientApi::CreateSessionOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#123 +Aws::S3::ClientApi::CreateSessionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#124 +Aws::S3::ClientApi::CreationDate = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#125 +Aws::S3::ClientApi::DataRedundancy = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#126 +Aws::S3::ClientApi::Date = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#127 +Aws::S3::ClientApi::Days = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#128 +Aws::S3::ClientApi::DaysAfterInitiation = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#129 +Aws::S3::ClientApi::DefaultRetention = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#130 +Aws::S3::ClientApi::Delete = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#131 +Aws::S3::ClientApi::DeleteBucketAnalyticsConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#132 +Aws::S3::ClientApi::DeleteBucketCorsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#133 +Aws::S3::ClientApi::DeleteBucketEncryptionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#134 +Aws::S3::ClientApi::DeleteBucketIntelligentTieringConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#135 +Aws::S3::ClientApi::DeleteBucketInventoryConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#136 +Aws::S3::ClientApi::DeleteBucketLifecycleRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#137 +Aws::S3::ClientApi::DeleteBucketMetricsConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#138 +Aws::S3::ClientApi::DeleteBucketOwnershipControlsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#139 +Aws::S3::ClientApi::DeleteBucketPolicyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#140 +Aws::S3::ClientApi::DeleteBucketReplicationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#141 +Aws::S3::ClientApi::DeleteBucketRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#142 +Aws::S3::ClientApi::DeleteBucketTaggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#143 +Aws::S3::ClientApi::DeleteBucketWebsiteRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#144 +Aws::S3::ClientApi::DeleteMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#145 +Aws::S3::ClientApi::DeleteMarkerEntry = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#146 +Aws::S3::ClientApi::DeleteMarkerReplication = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#147 +Aws::S3::ClientApi::DeleteMarkerReplicationStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#148 +Aws::S3::ClientApi::DeleteMarkerVersionId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#149 +Aws::S3::ClientApi::DeleteMarkers = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#150 +Aws::S3::ClientApi::DeleteObjectOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#151 +Aws::S3::ClientApi::DeleteObjectRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#152 +Aws::S3::ClientApi::DeleteObjectTaggingOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#153 +Aws::S3::ClientApi::DeleteObjectTaggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#154 +Aws::S3::ClientApi::DeleteObjectsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#155 +Aws::S3::ClientApi::DeleteObjectsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#156 +Aws::S3::ClientApi::DeletePublicAccessBlockRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#157 +Aws::S3::ClientApi::DeletedObject = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#158 +Aws::S3::ClientApi::DeletedObjects = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#159 +Aws::S3::ClientApi::Delimiter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#160 +Aws::S3::ClientApi::Description = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#161 +Aws::S3::ClientApi::Destination = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#162 +Aws::S3::ClientApi::DirectoryBucketToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#163 +Aws::S3::ClientApi::DisplayName = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#164 +Aws::S3::ClientApi::ETag = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#165 +Aws::S3::ClientApi::EmailAddress = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#166 +Aws::S3::ClientApi::EnableRequestProgress = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#167 +Aws::S3::ClientApi::EncodingType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#168 +Aws::S3::ClientApi::Encryption = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#169 +Aws::S3::ClientApi::EncryptionConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#170 +Aws::S3::ClientApi::End = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#171 +Aws::S3::ClientApi::EndEvent = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#172 +Aws::S3::ClientApi::Error = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#173 +Aws::S3::ClientApi::ErrorCode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#174 +Aws::S3::ClientApi::ErrorDocument = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#175 +Aws::S3::ClientApi::ErrorMessage = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#176 +Aws::S3::ClientApi::Errors = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#177 +Aws::S3::ClientApi::Event = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#178 +Aws::S3::ClientApi::EventBridgeConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#179 +Aws::S3::ClientApi::EventList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#180 +Aws::S3::ClientApi::ExistingObjectReplication = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#181 +Aws::S3::ClientApi::ExistingObjectReplicationStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#182 +Aws::S3::ClientApi::Expiration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#183 +Aws::S3::ClientApi::ExpirationStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#184 +Aws::S3::ClientApi::ExpiredObjectDeleteMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#185 +Aws::S3::ClientApi::Expires = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#186 +Aws::S3::ClientApi::ExpiresString = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#187 +Aws::S3::ClientApi::ExposeHeader = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#188 +Aws::S3::ClientApi::ExposeHeaders = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#189 +Aws::S3::ClientApi::Expression = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#190 +Aws::S3::ClientApi::ExpressionType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#191 +Aws::S3::ClientApi::FetchOwner = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#192 +Aws::S3::ClientApi::FieldDelimiter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#193 +Aws::S3::ClientApi::FileHeaderInfo = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#194 +Aws::S3::ClientApi::FilterRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#195 +Aws::S3::ClientApi::FilterRuleList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#196 +Aws::S3::ClientApi::FilterRuleName = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#197 +Aws::S3::ClientApi::FilterRuleValue = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#198 +Aws::S3::ClientApi::GetBucketAccelerateConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#199 +Aws::S3::ClientApi::GetBucketAccelerateConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#200 +Aws::S3::ClientApi::GetBucketAclOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#201 +Aws::S3::ClientApi::GetBucketAclRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#202 +Aws::S3::ClientApi::GetBucketAnalyticsConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#203 +Aws::S3::ClientApi::GetBucketAnalyticsConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#204 +Aws::S3::ClientApi::GetBucketCorsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#205 +Aws::S3::ClientApi::GetBucketCorsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#206 +Aws::S3::ClientApi::GetBucketEncryptionOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#207 +Aws::S3::ClientApi::GetBucketEncryptionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#208 +Aws::S3::ClientApi::GetBucketIntelligentTieringConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#209 +Aws::S3::ClientApi::GetBucketIntelligentTieringConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#210 +Aws::S3::ClientApi::GetBucketInventoryConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#211 +Aws::S3::ClientApi::GetBucketInventoryConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#212 +Aws::S3::ClientApi::GetBucketLifecycleConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#213 +Aws::S3::ClientApi::GetBucketLifecycleConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#214 +Aws::S3::ClientApi::GetBucketLifecycleOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#215 +Aws::S3::ClientApi::GetBucketLifecycleRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#216 +Aws::S3::ClientApi::GetBucketLocationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#217 +Aws::S3::ClientApi::GetBucketLocationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#218 +Aws::S3::ClientApi::GetBucketLoggingOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#219 +Aws::S3::ClientApi::GetBucketLoggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#220 +Aws::S3::ClientApi::GetBucketMetricsConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#221 +Aws::S3::ClientApi::GetBucketMetricsConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#222 +Aws::S3::ClientApi::GetBucketNotificationConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#223 +Aws::S3::ClientApi::GetBucketOwnershipControlsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#224 +Aws::S3::ClientApi::GetBucketOwnershipControlsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#225 +Aws::S3::ClientApi::GetBucketPolicyOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#226 +Aws::S3::ClientApi::GetBucketPolicyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#227 +Aws::S3::ClientApi::GetBucketPolicyStatusOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#228 +Aws::S3::ClientApi::GetBucketPolicyStatusRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#229 +Aws::S3::ClientApi::GetBucketReplicationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#230 +Aws::S3::ClientApi::GetBucketReplicationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#231 +Aws::S3::ClientApi::GetBucketRequestPaymentOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#232 +Aws::S3::ClientApi::GetBucketRequestPaymentRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#233 +Aws::S3::ClientApi::GetBucketTaggingOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#234 +Aws::S3::ClientApi::GetBucketTaggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#235 +Aws::S3::ClientApi::GetBucketVersioningOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#236 +Aws::S3::ClientApi::GetBucketVersioningRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#237 +Aws::S3::ClientApi::GetBucketWebsiteOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#238 +Aws::S3::ClientApi::GetBucketWebsiteRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#239 +Aws::S3::ClientApi::GetObjectAclOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#240 +Aws::S3::ClientApi::GetObjectAclRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#241 +Aws::S3::ClientApi::GetObjectAttributesOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#242 +Aws::S3::ClientApi::GetObjectAttributesParts = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#243 +Aws::S3::ClientApi::GetObjectAttributesRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#244 +Aws::S3::ClientApi::GetObjectLegalHoldOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#245 +Aws::S3::ClientApi::GetObjectLegalHoldRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#246 +Aws::S3::ClientApi::GetObjectLockConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#247 +Aws::S3::ClientApi::GetObjectLockConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#248 +Aws::S3::ClientApi::GetObjectOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#249 +Aws::S3::ClientApi::GetObjectRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#250 +Aws::S3::ClientApi::GetObjectResponseStatusCode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#251 +Aws::S3::ClientApi::GetObjectRetentionOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#252 +Aws::S3::ClientApi::GetObjectRetentionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#253 +Aws::S3::ClientApi::GetObjectTaggingOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#254 +Aws::S3::ClientApi::GetObjectTaggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#255 +Aws::S3::ClientApi::GetObjectTorrentOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#256 +Aws::S3::ClientApi::GetObjectTorrentRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#257 +Aws::S3::ClientApi::GetPublicAccessBlockOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#258 +Aws::S3::ClientApi::GetPublicAccessBlockRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#259 +Aws::S3::ClientApi::GlacierJobParameters = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#260 +Aws::S3::ClientApi::Grant = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#261 +Aws::S3::ClientApi::GrantFullControl = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#262 +Aws::S3::ClientApi::GrantRead = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#263 +Aws::S3::ClientApi::GrantReadACP = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#264 +Aws::S3::ClientApi::GrantWrite = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#265 +Aws::S3::ClientApi::GrantWriteACP = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#266 +Aws::S3::ClientApi::Grantee = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#267 +Aws::S3::ClientApi::Grants = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#268 +Aws::S3::ClientApi::HeadBucketOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#269 +Aws::S3::ClientApi::HeadBucketRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#270 +Aws::S3::ClientApi::HeadObjectOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#271 +Aws::S3::ClientApi::HeadObjectRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#272 +Aws::S3::ClientApi::HostName = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#273 +Aws::S3::ClientApi::HttpErrorCodeReturnedEquals = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#274 +Aws::S3::ClientApi::HttpRedirectCode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#275 +Aws::S3::ClientApi::ID = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#276 +Aws::S3::ClientApi::IfMatch = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#277 +Aws::S3::ClientApi::IfModifiedSince = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#278 +Aws::S3::ClientApi::IfNoneMatch = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#279 +Aws::S3::ClientApi::IfUnmodifiedSince = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#280 +Aws::S3::ClientApi::IndexDocument = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#281 +Aws::S3::ClientApi::Initiated = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#282 +Aws::S3::ClientApi::Initiator = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#283 +Aws::S3::ClientApi::InputSerialization = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#284 +Aws::S3::ClientApi::IntelligentTieringAccessTier = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#285 +Aws::S3::ClientApi::IntelligentTieringAndOperator = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#286 +Aws::S3::ClientApi::IntelligentTieringConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#287 +Aws::S3::ClientApi::IntelligentTieringConfigurationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#288 +Aws::S3::ClientApi::IntelligentTieringDays = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#289 +Aws::S3::ClientApi::IntelligentTieringFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#290 +Aws::S3::ClientApi::IntelligentTieringId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#291 +Aws::S3::ClientApi::IntelligentTieringStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#292 +Aws::S3::ClientApi::InvalidObjectState = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#293 +Aws::S3::ClientApi::InventoryConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#294 +Aws::S3::ClientApi::InventoryConfigurationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#295 +Aws::S3::ClientApi::InventoryDestination = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#296 +Aws::S3::ClientApi::InventoryEncryption = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#297 +Aws::S3::ClientApi::InventoryFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#298 +Aws::S3::ClientApi::InventoryFormat = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#299 +Aws::S3::ClientApi::InventoryFrequency = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#300 +Aws::S3::ClientApi::InventoryId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#301 +Aws::S3::ClientApi::InventoryIncludedObjectVersions = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#302 +Aws::S3::ClientApi::InventoryOptionalField = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#303 +Aws::S3::ClientApi::InventoryOptionalFields = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#304 +Aws::S3::ClientApi::InventoryS3BucketDestination = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#305 +Aws::S3::ClientApi::InventorySchedule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#306 +Aws::S3::ClientApi::IsEnabled = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#307 +Aws::S3::ClientApi::IsLatest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#308 +Aws::S3::ClientApi::IsPublic = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#309 +Aws::S3::ClientApi::IsRestoreInProgress = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#310 +Aws::S3::ClientApi::IsTruncated = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#311 +Aws::S3::ClientApi::JSONInput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#312 +Aws::S3::ClientApi::JSONOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#313 +Aws::S3::ClientApi::JSONType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#314 +Aws::S3::ClientApi::KMSContext = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#315 +Aws::S3::ClientApi::KeyCount = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#316 +Aws::S3::ClientApi::KeyMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#317 +Aws::S3::ClientApi::KeyPrefixEquals = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#318 +Aws::S3::ClientApi::LambdaFunctionArn = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#319 +Aws::S3::ClientApi::LambdaFunctionConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#320 +Aws::S3::ClientApi::LambdaFunctionConfigurationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#321 +Aws::S3::ClientApi::LastModified = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#322 +Aws::S3::ClientApi::LifecycleConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#323 +Aws::S3::ClientApi::LifecycleExpiration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#324 +Aws::S3::ClientApi::LifecycleRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#325 +Aws::S3::ClientApi::LifecycleRuleAndOperator = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#326 +Aws::S3::ClientApi::LifecycleRuleFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#327 +Aws::S3::ClientApi::LifecycleRules = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#328 +Aws::S3::ClientApi::ListBucketAnalyticsConfigurationsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#329 +Aws::S3::ClientApi::ListBucketAnalyticsConfigurationsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#330 +Aws::S3::ClientApi::ListBucketIntelligentTieringConfigurationsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#331 +Aws::S3::ClientApi::ListBucketIntelligentTieringConfigurationsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#332 +Aws::S3::ClientApi::ListBucketInventoryConfigurationsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#333 +Aws::S3::ClientApi::ListBucketInventoryConfigurationsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#334 +Aws::S3::ClientApi::ListBucketMetricsConfigurationsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#335 +Aws::S3::ClientApi::ListBucketMetricsConfigurationsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#336 +Aws::S3::ClientApi::ListBucketsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#337 +Aws::S3::ClientApi::ListDirectoryBucketsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#338 +Aws::S3::ClientApi::ListDirectoryBucketsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#339 +Aws::S3::ClientApi::ListMultipartUploadsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#340 +Aws::S3::ClientApi::ListMultipartUploadsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#341 +Aws::S3::ClientApi::ListObjectVersionsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#342 +Aws::S3::ClientApi::ListObjectVersionsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#343 +Aws::S3::ClientApi::ListObjectsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#344 +Aws::S3::ClientApi::ListObjectsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#345 +Aws::S3::ClientApi::ListObjectsV2Output = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#346 +Aws::S3::ClientApi::ListObjectsV2Request = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#347 +Aws::S3::ClientApi::ListPartsOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#348 +Aws::S3::ClientApi::ListPartsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#349 +Aws::S3::ClientApi::Location = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#350 +Aws::S3::ClientApi::LocationInfo = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#351 +Aws::S3::ClientApi::LocationNameAsString = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#352 +Aws::S3::ClientApi::LocationPrefix = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#353 +Aws::S3::ClientApi::LocationType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#354 +Aws::S3::ClientApi::LoggingEnabled = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#355 +Aws::S3::ClientApi::MFA = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#356 +Aws::S3::ClientApi::MFADelete = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#357 +Aws::S3::ClientApi::MFADeleteStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#358 +Aws::S3::ClientApi::Marker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#359 +Aws::S3::ClientApi::MaxAgeSeconds = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#360 +Aws::S3::ClientApi::MaxDirectoryBuckets = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#361 +Aws::S3::ClientApi::MaxKeys = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#362 +Aws::S3::ClientApi::MaxParts = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#363 +Aws::S3::ClientApi::MaxUploads = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#364 +Aws::S3::ClientApi::Message = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#365 +Aws::S3::ClientApi::Metadata = T.let(T.unsafe(nil), Seahorse::Model::Shapes::MapShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#366 +Aws::S3::ClientApi::MetadataDirective = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#367 +Aws::S3::ClientApi::MetadataEntry = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#368 +Aws::S3::ClientApi::MetadataKey = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#369 +Aws::S3::ClientApi::MetadataValue = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#370 +Aws::S3::ClientApi::Metrics = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#371 +Aws::S3::ClientApi::MetricsAndOperator = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#372 +Aws::S3::ClientApi::MetricsConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#373 +Aws::S3::ClientApi::MetricsConfigurationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#374 +Aws::S3::ClientApi::MetricsFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#375 +Aws::S3::ClientApi::MetricsId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#376 +Aws::S3::ClientApi::MetricsStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#377 +Aws::S3::ClientApi::Minutes = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#378 +Aws::S3::ClientApi::MissingMeta = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#379 +Aws::S3::ClientApi::MultipartUpload = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#380 +Aws::S3::ClientApi::MultipartUploadId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#381 +Aws::S3::ClientApi::MultipartUploadList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#382 +Aws::S3::ClientApi::NextKeyMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#383 +Aws::S3::ClientApi::NextMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#384 +Aws::S3::ClientApi::NextPartNumberMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#385 +Aws::S3::ClientApi::NextToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#386 +Aws::S3::ClientApi::NextUploadIdMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#387 +Aws::S3::ClientApi::NextVersionIdMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#388 +Aws::S3::ClientApi::NoSuchBucket = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#389 +Aws::S3::ClientApi::NoSuchKey = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#390 +Aws::S3::ClientApi::NoSuchUpload = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#391 +Aws::S3::ClientApi::NoncurrentVersionExpiration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#392 +Aws::S3::ClientApi::NoncurrentVersionTransition = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#393 +Aws::S3::ClientApi::NoncurrentVersionTransitionList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#394 +Aws::S3::ClientApi::NotificationConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#395 +Aws::S3::ClientApi::NotificationConfigurationDeprecated = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#396 +Aws::S3::ClientApi::NotificationConfigurationFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#397 +Aws::S3::ClientApi::NotificationId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#398 +Aws::S3::ClientApi::Object = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#399 +Aws::S3::ClientApi::ObjectAlreadyInActiveTierError = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#400 +Aws::S3::ClientApi::ObjectAttributes = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#401 +Aws::S3::ClientApi::ObjectAttributesList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#402 +Aws::S3::ClientApi::ObjectCannedACL = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#403 +Aws::S3::ClientApi::ObjectIdentifier = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#404 +Aws::S3::ClientApi::ObjectIdentifierList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#405 +Aws::S3::ClientApi::ObjectKey = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#406 +Aws::S3::ClientApi::ObjectList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#407 +Aws::S3::ClientApi::ObjectLockConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#408 +Aws::S3::ClientApi::ObjectLockEnabled = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#409 +Aws::S3::ClientApi::ObjectLockEnabledForBucket = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#410 +Aws::S3::ClientApi::ObjectLockLegalHold = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#411 +Aws::S3::ClientApi::ObjectLockLegalHoldStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#412 +Aws::S3::ClientApi::ObjectLockMode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#413 +Aws::S3::ClientApi::ObjectLockRetainUntilDate = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#414 +Aws::S3::ClientApi::ObjectLockRetention = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#415 +Aws::S3::ClientApi::ObjectLockRetentionMode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#416 +Aws::S3::ClientApi::ObjectLockRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#417 +Aws::S3::ClientApi::ObjectLockToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#418 +Aws::S3::ClientApi::ObjectNotInActiveTierError = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#419 +Aws::S3::ClientApi::ObjectOwnership = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#420 +Aws::S3::ClientApi::ObjectPart = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#421 +Aws::S3::ClientApi::ObjectSize = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#422 +Aws::S3::ClientApi::ObjectSizeGreaterThanBytes = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#423 +Aws::S3::ClientApi::ObjectSizeLessThanBytes = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#424 +Aws::S3::ClientApi::ObjectStorageClass = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#425 +Aws::S3::ClientApi::ObjectVersion = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#426 +Aws::S3::ClientApi::ObjectVersionId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#427 +Aws::S3::ClientApi::ObjectVersionList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#428 +Aws::S3::ClientApi::ObjectVersionStorageClass = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#429 +Aws::S3::ClientApi::OptionalObjectAttributes = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#430 +Aws::S3::ClientApi::OptionalObjectAttributesList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#431 +Aws::S3::ClientApi::OutputLocation = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#432 +Aws::S3::ClientApi::OutputSerialization = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#433 +Aws::S3::ClientApi::Owner = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#434 +Aws::S3::ClientApi::OwnerOverride = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#435 +Aws::S3::ClientApi::OwnershipControls = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#436 +Aws::S3::ClientApi::OwnershipControlsRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#437 +Aws::S3::ClientApi::OwnershipControlsRules = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#438 +Aws::S3::ClientApi::ParquetInput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#439 +Aws::S3::ClientApi::Part = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#440 +Aws::S3::ClientApi::PartNumber = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#441 +Aws::S3::ClientApi::PartNumberMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#442 +Aws::S3::ClientApi::PartitionDateSource = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#443 +Aws::S3::ClientApi::PartitionedPrefix = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#444 +Aws::S3::ClientApi::Parts = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#445 +Aws::S3::ClientApi::PartsCount = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#446 +Aws::S3::ClientApi::PartsList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#447 +Aws::S3::ClientApi::Payer = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#448 +Aws::S3::ClientApi::Permission = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#449 +Aws::S3::ClientApi::Policy = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#450 +Aws::S3::ClientApi::PolicyStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#451 +Aws::S3::ClientApi::Prefix = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#452 +Aws::S3::ClientApi::Priority = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#453 +Aws::S3::ClientApi::Progress = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#454 +Aws::S3::ClientApi::ProgressEvent = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#455 +Aws::S3::ClientApi::Protocol = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#456 +Aws::S3::ClientApi::PublicAccessBlockConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#457 +Aws::S3::ClientApi::PutBucketAccelerateConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#458 +Aws::S3::ClientApi::PutBucketAclRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#459 +Aws::S3::ClientApi::PutBucketAnalyticsConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#460 +Aws::S3::ClientApi::PutBucketCorsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#461 +Aws::S3::ClientApi::PutBucketEncryptionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#462 +Aws::S3::ClientApi::PutBucketIntelligentTieringConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#463 +Aws::S3::ClientApi::PutBucketInventoryConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#464 +Aws::S3::ClientApi::PutBucketLifecycleConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#465 +Aws::S3::ClientApi::PutBucketLifecycleRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#466 +Aws::S3::ClientApi::PutBucketLoggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#467 +Aws::S3::ClientApi::PutBucketMetricsConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#468 +Aws::S3::ClientApi::PutBucketNotificationConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#469 +Aws::S3::ClientApi::PutBucketNotificationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#470 +Aws::S3::ClientApi::PutBucketOwnershipControlsRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#471 +Aws::S3::ClientApi::PutBucketPolicyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#472 +Aws::S3::ClientApi::PutBucketReplicationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#473 +Aws::S3::ClientApi::PutBucketRequestPaymentRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#474 +Aws::S3::ClientApi::PutBucketTaggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#475 +Aws::S3::ClientApi::PutBucketVersioningRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#476 +Aws::S3::ClientApi::PutBucketWebsiteRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#477 +Aws::S3::ClientApi::PutObjectAclOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#478 +Aws::S3::ClientApi::PutObjectAclRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#479 +Aws::S3::ClientApi::PutObjectLegalHoldOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#480 +Aws::S3::ClientApi::PutObjectLegalHoldRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#481 +Aws::S3::ClientApi::PutObjectLockConfigurationOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#482 +Aws::S3::ClientApi::PutObjectLockConfigurationRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#483 +Aws::S3::ClientApi::PutObjectOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#484 +Aws::S3::ClientApi::PutObjectRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#485 +Aws::S3::ClientApi::PutObjectRetentionOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#486 +Aws::S3::ClientApi::PutObjectRetentionRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#487 +Aws::S3::ClientApi::PutObjectTaggingOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#488 +Aws::S3::ClientApi::PutObjectTaggingRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#489 +Aws::S3::ClientApi::PutPublicAccessBlockRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#490 +Aws::S3::ClientApi::QueueArn = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#491 +Aws::S3::ClientApi::QueueConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#492 +Aws::S3::ClientApi::QueueConfigurationDeprecated = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#493 +Aws::S3::ClientApi::QueueConfigurationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#494 +Aws::S3::ClientApi::Quiet = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#495 +Aws::S3::ClientApi::QuoteCharacter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#496 +Aws::S3::ClientApi::QuoteEscapeCharacter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#497 +Aws::S3::ClientApi::QuoteFields = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#498 +Aws::S3::ClientApi::Range = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#499 +Aws::S3::ClientApi::RecordDelimiter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#500 +Aws::S3::ClientApi::RecordsEvent = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#501 +Aws::S3::ClientApi::Redirect = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#502 +Aws::S3::ClientApi::RedirectAllRequestsTo = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#503 +Aws::S3::ClientApi::Region = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#504 +Aws::S3::ClientApi::ReplaceKeyPrefixWith = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#505 +Aws::S3::ClientApi::ReplaceKeyWith = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#506 +Aws::S3::ClientApi::ReplicaKmsKeyID = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#507 +Aws::S3::ClientApi::ReplicaModifications = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#508 +Aws::S3::ClientApi::ReplicaModificationsStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#509 +Aws::S3::ClientApi::ReplicationConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#510 +Aws::S3::ClientApi::ReplicationRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#511 +Aws::S3::ClientApi::ReplicationRuleAndOperator = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#512 +Aws::S3::ClientApi::ReplicationRuleFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#513 +Aws::S3::ClientApi::ReplicationRuleStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#514 +Aws::S3::ClientApi::ReplicationRules = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#515 +Aws::S3::ClientApi::ReplicationStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#516 +Aws::S3::ClientApi::ReplicationTime = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#517 +Aws::S3::ClientApi::ReplicationTimeStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#518 +Aws::S3::ClientApi::ReplicationTimeValue = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#519 +Aws::S3::ClientApi::RequestCharged = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#520 +Aws::S3::ClientApi::RequestPayer = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#521 +Aws::S3::ClientApi::RequestPaymentConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#522 +Aws::S3::ClientApi::RequestProgress = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#523 +Aws::S3::ClientApi::RequestRoute = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#524 +Aws::S3::ClientApi::RequestToken = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#525 +Aws::S3::ClientApi::ResponseCacheControl = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#526 +Aws::S3::ClientApi::ResponseContentDisposition = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#527 +Aws::S3::ClientApi::ResponseContentEncoding = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#528 +Aws::S3::ClientApi::ResponseContentLanguage = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#529 +Aws::S3::ClientApi::ResponseContentType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#530 +Aws::S3::ClientApi::ResponseExpires = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#531 +Aws::S3::ClientApi::Restore = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#532 +Aws::S3::ClientApi::RestoreExpiryDate = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#533 +Aws::S3::ClientApi::RestoreObjectOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#534 +Aws::S3::ClientApi::RestoreObjectRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#535 +Aws::S3::ClientApi::RestoreOutputPath = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#536 +Aws::S3::ClientApi::RestoreRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#537 +Aws::S3::ClientApi::RestoreRequestType = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#538 +Aws::S3::ClientApi::RestoreStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#539 +Aws::S3::ClientApi::Role = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#540 +Aws::S3::ClientApi::RoutingRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#541 +Aws::S3::ClientApi::RoutingRules = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#542 +Aws::S3::ClientApi::Rule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#543 +Aws::S3::ClientApi::Rules = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#544 +Aws::S3::ClientApi::S3KeyFilter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#545 +Aws::S3::ClientApi::S3Location = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#546 +Aws::S3::ClientApi::SSECustomerAlgorithm = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#547 +Aws::S3::ClientApi::SSECustomerKey = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#548 +Aws::S3::ClientApi::SSECustomerKeyMD5 = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#549 +Aws::S3::ClientApi::SSEKMS = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#550 +Aws::S3::ClientApi::SSEKMSEncryptionContext = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#551 +Aws::S3::ClientApi::SSEKMSKeyId = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#552 +Aws::S3::ClientApi::SSES3 = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#553 +Aws::S3::ClientApi::ScanRange = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#554 +Aws::S3::ClientApi::SelectObjectContentEventStream = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#555 +Aws::S3::ClientApi::SelectObjectContentOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#556 +Aws::S3::ClientApi::SelectObjectContentRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#557 +Aws::S3::ClientApi::SelectParameters = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#558 +Aws::S3::ClientApi::ServerSideEncryption = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#559 +Aws::S3::ClientApi::ServerSideEncryptionByDefault = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#560 +Aws::S3::ClientApi::ServerSideEncryptionConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#561 +Aws::S3::ClientApi::ServerSideEncryptionRule = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#562 +Aws::S3::ClientApi::ServerSideEncryptionRules = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#563 +Aws::S3::ClientApi::SessionCredentialValue = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#564 +Aws::S3::ClientApi::SessionCredentials = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#565 +Aws::S3::ClientApi::SessionExpiration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::TimestampShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#566 +Aws::S3::ClientApi::SessionMode = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#567 +Aws::S3::ClientApi::Setting = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#568 +Aws::S3::ClientApi::SimplePrefix = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#569 +Aws::S3::ClientApi::Size = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#570 +Aws::S3::ClientApi::SkipValidation = T.let(T.unsafe(nil), Seahorse::Model::Shapes::BooleanShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#571 +Aws::S3::ClientApi::SourceSelectionCriteria = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#572 +Aws::S3::ClientApi::SseKmsEncryptedObjects = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#573 +Aws::S3::ClientApi::SseKmsEncryptedObjectsStatus = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#574 +Aws::S3::ClientApi::Start = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#575 +Aws::S3::ClientApi::StartAfter = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#576 +Aws::S3::ClientApi::Stats = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#577 +Aws::S3::ClientApi::StatsEvent = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#578 +Aws::S3::ClientApi::StorageClass = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#579 +Aws::S3::ClientApi::StorageClassAnalysis = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#580 +Aws::S3::ClientApi::StorageClassAnalysisDataExport = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#581 +Aws::S3::ClientApi::StorageClassAnalysisSchemaVersion = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#582 +Aws::S3::ClientApi::Suffix = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#583 +Aws::S3::ClientApi::Tag = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#584 +Aws::S3::ClientApi::TagCount = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#585 +Aws::S3::ClientApi::TagSet = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#586 +Aws::S3::ClientApi::Tagging = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#587 +Aws::S3::ClientApi::TaggingDirective = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#588 +Aws::S3::ClientApi::TaggingHeader = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#589 +Aws::S3::ClientApi::TargetBucket = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#590 +Aws::S3::ClientApi::TargetGrant = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#591 +Aws::S3::ClientApi::TargetGrants = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#592 +Aws::S3::ClientApi::TargetObjectKeyFormat = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#593 +Aws::S3::ClientApi::TargetPrefix = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#594 +Aws::S3::ClientApi::Tier = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#595 +Aws::S3::ClientApi::Tiering = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#596 +Aws::S3::ClientApi::TieringList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#597 +Aws::S3::ClientApi::Token = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#598 +Aws::S3::ClientApi::TopicArn = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#599 +Aws::S3::ClientApi::TopicConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#600 +Aws::S3::ClientApi::TopicConfigurationDeprecated = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#601 +Aws::S3::ClientApi::TopicConfigurationList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#602 +Aws::S3::ClientApi::Transition = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#603 +Aws::S3::ClientApi::TransitionList = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#604 +Aws::S3::ClientApi::TransitionStorageClass = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#605 +Aws::S3::ClientApi::Type = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#606 +Aws::S3::ClientApi::URI = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#607 +Aws::S3::ClientApi::UploadIdMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#608 +Aws::S3::ClientApi::UploadPartCopyOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#609 +Aws::S3::ClientApi::UploadPartCopyRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#610 +Aws::S3::ClientApi::UploadPartOutput = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#611 +Aws::S3::ClientApi::UploadPartRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#612 +Aws::S3::ClientApi::UserMetadata = T.let(T.unsafe(nil), Seahorse::Model::Shapes::ListShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#613 +Aws::S3::ClientApi::Value = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#614 +Aws::S3::ClientApi::VersionCount = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#615 +Aws::S3::ClientApi::VersionIdMarker = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#616 +Aws::S3::ClientApi::VersioningConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#617 +Aws::S3::ClientApi::WebsiteConfiguration = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#618 +Aws::S3::ClientApi::WebsiteRedirectLocation = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StringShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#619 +Aws::S3::ClientApi::WriteGetObjectResponseRequest = T.let(T.unsafe(nil), Seahorse::Model::Shapes::StructureShape) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/client_api.rb#620 +Aws::S3::ClientApi::Years = T.let(T.unsafe(nil), Seahorse::Model::Shapes::IntegerShape) + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption.rb#21 +Aws::S3::EC_USER_AGENT = T.let(T.unsafe(nil), String) + +# [MAINTENANCE MODE] There is a new version of the Encryption Client. +# AWS strongly recommends upgrading to the {Aws::S3::EncryptionV2::Client}, +# which provides updated data security best practices. +# See documentation for {Aws::S3::EncryptionV2::Client}. +# Provides an encryption client that encrypts and decrypts data client-side, +# storing the encrypted data in Amazon S3. +# +# This client uses a process called "envelope encryption". Your private +# encryption keys and your data's plain-text are **never** sent to +# Amazon S3. **If you lose you encryption keys, you will not be able to +# decrypt your data.** +# +# ## Envelope Encryption Overview +# +# The goal of envelope encryption is to combine the performance of +# fast symmetric encryption while maintaining the secure key management +# that asymmetric keys provide. +# +# A one-time-use symmetric key (envelope key) is generated client-side. +# This is used to encrypt the data client-side. This key is then +# encrypted by your master key and stored alongside your data in Amazon +# S3. +# +# When accessing your encrypted data with the encryption client, +# the encrypted envelope key is retrieved and decrypted client-side +# with your master key. The envelope key is then used to decrypt the +# data client-side. +# +# One of the benefits of envelope encryption is that if your master key +# is compromised, you have the option of just re-encrypting the stored +# envelope symmetric keys, instead of re-encrypting all of the +# data in your account. +# +# ## Basic Usage +# +# The encryption client requires an {Aws::S3::Client}. If you do not +# provide a `:client`, then a client will be constructed for you. +# +# require 'openssl' +# key = OpenSSL::PKey::RSA.new(1024) +# +# # encryption client +# s3 = Aws::S3::Encryption::Client.new(encryption_key: key) +# +# # round-trip an object, encrypted/decrypted locally +# s3.put_object(bucket:'aws-sdk', key:'secret', body:'handshake') +# s3.get_object(bucket:'aws-sdk', key:'secret').body.read +# #=> 'handshake' +# +# # reading encrypted object without the encryption client +# # results in the getting the cipher text +# Aws::S3::Client.new.get_object(bucket:'aws-sdk', key:'secret').body.read +# #=> "... cipher text ..." +# +# ## Keys +# +# For client-side encryption to work, you must provide one of the following: +# +# * An encryption key +# * A {KeyProvider} +# * A KMS encryption key id +# +# ### An Encryption Key +# +# You can pass a single encryption key. This is used as a master key +# encrypting and decrypting all object keys. +# +# key = OpenSSL::Cipher.new("AES-256-ECB").random_key # symmetric key +# key = OpenSSL::PKey::RSA.new(1024) # asymmetric key pair +# +# s3 = Aws::S3::Encryption::Client.new(encryption_key: key) +# +# ### Key Provider +# +# Alternatively, you can use a {KeyProvider}. A key provider makes +# it easy to work with multiple keys and simplifies key rotation. +# +# ### KMS Encryption Key Id +# +# If you pass the id to an AWS Key Management Service (KMS) key, +# then KMS will be used to generate, encrypt and decrypt object keys. +# +# # keep track of the kms key id +# kms = Aws::KMS::Client.new +# key_id = kms.create_key.key_metadata.key_id +# +# Aws::S3::Encryption::Client.new( +# kms_key_id: key_id, +# kms_client: kms, +# ) +# +# ## Custom Key Providers +# +# A {KeyProvider} is any object that responds to: +# +# * `#encryption_materials` +# * `#key_for(materials_description)` +# +# Here is a trivial implementation of an in-memory key provider. +# This is provided as a demonstration of the key provider interface, +# and should not be used in production: +# +# class KeyProvider +# +# def initialize(default_key_name, keys) +# @keys = keys +# @encryption_materials = Aws::S3::Encryption::Materials.new( +# key: @keys[default_key_name], +# description: JSON.dump(key: default_key_name), +# ) +# end +# +# attr_reader :encryption_materials +# +# def key_for(matdesc) +# key_name = JSON.parse(matdesc)['key'] +# if key = @keys[key_name] +# key +# else +# raise "encryption key not found for: #{matdesc.inspect}" +# end +# end +# end +# +# Given the above key provider, you can create an encryption client that +# chooses the key to use based on the materials description stored with +# the encrypted object. This makes it possible to use multiple keys +# and simplifies key rotation. +# +# # uses "new-key" for encrypting objects, uses either for decrypting +# keys = KeyProvider.new('new-key', { +# "old-key" => Base64.decode64("kM5UVbhE/4rtMZJfsadYEdm2vaKFsmV2f5+URSeUCV4="), +# "new-key" => Base64.decode64("w1WLio3agRWRTSJK/Ouh8NHoqRQ6fn5WbSXDTHjXMSo="), +# }), +# +# # chooses the key based on the materials description stored +# # with the encrypted object +# s3 = Aws::S3::Encryption::Client.new(key_provider: keys) +# +# ## Materials Description +# +# A materials description is JSON document string that is stored +# in the metadata (or instruction file) of an encrypted object. +# The {DefaultKeyProvider} uses the empty JSON document `"{}"`. +# +# When building a key provider, you are free to store whatever +# information you need to identify the master key that was used +# to encrypt the object. +# +# ## Envelope Location +# +# By default, the encryption client store the encryption envelope +# with the object, as metadata. You can choose to have the envelope +# stored in a separate "instruction file". An instruction file +# is an object, with the key of the encrypted object, suffixed with +# `".instruction"`. +# +# Specify the `:envelope_location` option as `:instruction_file` to +# use an instruction file for storing the envelope. +# +# # default behavior +# s3 = Aws::S3::Encryption::Client.new( +# key_provider: ..., +# envelope_location: :metadata, +# ) +# +# # store envelope in a separate object +# s3 = Aws::S3::Encryption::Client.new( +# key_provider: ..., +# envelope_location: :instruction_file, +# instruction_file_suffix: '.instruction' # default +# ) +# +# When using an instruction file, multiple requests are made when +# putting and getting the object. **This may cause issues if you are +# issuing concurrent PUT and GET requests to an encrypted object.** +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#185 +module Aws::S3::Encryption; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#186 +class Aws::S3::Encryption::Client + extend ::Aws::Deprecations + extend ::Forwardable + + # Creates a new encryption client. You must provide one of the following + # options: + # + # * `:encryption_key` + # * `:kms_key_id` + # * `:key_provider` + # + # You may also pass any other options accepted by `Client#initialize`. + # + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Client] a new instance of Client + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def initialize(*args, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def build_request(*args, **_arg1, &block); end + + # @return [S3::Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#245 + def client; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def config(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def delete_object(*args, **_arg1, &block); end + + # @return [Symbol<:metadata, :instruction_file>] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#252 + def envelope_location; end + + # Gets an object from Amazon S3, decrypting data locally. + # See {S3::Client#get_object} for documentation on accepted + # request parameters. + # + # @note The `:range` request parameter is not yet supported. + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param params [Hash] a customizable set of options + # @return [Types::GetObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectOutput#body #body} => IO + # * {Types::GetObjectOutput#delete_marker #delete_marker} => Boolean + # * {Types::GetObjectOutput#accept_ranges #accept_ranges} => String + # * {Types::GetObjectOutput#expiration #expiration} => String + # * {Types::GetObjectOutput#restore #restore} => String + # * {Types::GetObjectOutput#last_modified #last_modified} => Time + # * {Types::GetObjectOutput#content_length #content_length} => Integer + # * {Types::GetObjectOutput#etag #etag} => String + # * {Types::GetObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::GetObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::GetObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::GetObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::GetObjectOutput#missing_meta #missing_meta} => Integer + # * {Types::GetObjectOutput#version_id #version_id} => String + # * {Types::GetObjectOutput#cache_control #cache_control} => String + # * {Types::GetObjectOutput#content_disposition #content_disposition} => String + # * {Types::GetObjectOutput#content_encoding #content_encoding} => String + # * {Types::GetObjectOutput#content_language #content_language} => String + # * {Types::GetObjectOutput#content_range #content_range} => String + # * {Types::GetObjectOutput#content_type #content_type} => String + # * {Types::GetObjectOutput#expires #expires} => Time + # * {Types::GetObjectOutput#expires_string #expires_string} => String + # * {Types::GetObjectOutput#website_redirect_location #website_redirect_location} => String + # * {Types::GetObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::GetObjectOutput#metadata #metadata} => Hash<String,String> + # * {Types::GetObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::GetObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::GetObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::GetObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::GetObjectOutput#storage_class #storage_class} => String + # * {Types::GetObjectOutput#request_charged #request_charged} => String + # * {Types::GetObjectOutput#replication_status #replication_status} => String + # * {Types::GetObjectOutput#parts_count #parts_count} => Integer + # * {Types::GetObjectOutput#tag_count #tag_count} => Integer + # * {Types::GetObjectOutput#object_lock_mode #object_lock_mode} => String + # * {Types::GetObjectOutput#object_lock_retain_until_date #object_lock_retain_until_date} => Time + # * {Types::GetObjectOutput#object_lock_legal_hold_status #object_lock_legal_hold_status} => String + # @see S3::Client#get_object + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#291 + def get_object(params = T.unsafe(nil), &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def head_object(*args, **_arg1, &block); end + + # @return [String] When {#envelope_location} is `:instruction_file`, + # the envelope is stored in the object with the object key suffixed + # by this string. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#257 + def instruction_file_suffix; end + + # @return [KeyProvider, nil] Returns `nil` if you are using + # AWS Key Management Service (KMS). + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#249 + def key_provider; end + + # Uploads an object to Amazon S3, encrypting data client-side. + # See {S3::Client#put_object} for documentation on accepted + # request parameters. + # + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param params [Hash] a customizable set of options + # @return [Types::PutObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectOutput#expiration #expiration} => String + # * {Types::PutObjectOutput#etag #etag} => String + # * {Types::PutObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::PutObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::PutObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::PutObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::PutObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::PutObjectOutput#version_id #version_id} => String + # * {Types::PutObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::PutObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::PutObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::PutObjectOutput#ssekms_encryption_context #ssekms_encryption_context} => String + # * {Types::PutObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::PutObjectOutput#request_charged #request_charged} => String + # @see S3::Client#put_object + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#265 + def put_object(params = T.unsafe(nil)); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#332 + def cipher_provider(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#230 + def deprecated_initialize(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#356 + def envelope_options(params); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#310 + def extract_client(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#345 + def extract_key_provider(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#366 + def extract_location(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#377 + def extract_suffix(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/client.rb#323 + def kms_client(options); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#9 +class Aws::S3::Encryption::DecryptHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#46 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#210 + def apply_cse_user_agent(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#64 + def attach_http_event_listeners(context); end + + # Determine the auth tag length from the algorithm + # Validate it against the value provided in the x-amz-tag-len + # Return the tag length in bytes + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#196 + def auth_tag_length(envelope); end + + # This method fetches the tag from the end of the object by + # making a GET Object w/range request. This auth tag is used + # to initialize the cipher, and the decrypter truncates the + # auth tag from the body when writing the final bytes. + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#167 + def authenticated_decrypter(context, cipher, envelope); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#189 + def body_contains_auth_tag?(envelope); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#88 + def decryption_cipher(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#119 + def envelope_from_instr_file(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#109 + def envelope_from_metadata(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#130 + def extract_envelope(hash); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#101 + def get_encryption_envelope(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#140 + def v1_envelope(envelope); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#144 + def v2_envelope(envelope); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#44 +Aws::S3::Encryption::DecryptHandler::AUTH_REQUIRED_CEK_ALGS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#38 +Aws::S3::Encryption::DecryptHandler::POSSIBLE_ENCRYPTION_FORMATS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#28 +Aws::S3::Encryption::DecryptHandler::POSSIBLE_ENVELOPE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#31 +Aws::S3::Encryption::DecryptHandler::POSSIBLE_WRAPPING_FORMATS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#12 +Aws::S3::Encryption::DecryptHandler::V1_ENVELOPE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#18 +Aws::S3::Encryption::DecryptHandler::V2_ENVELOPE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/decrypt_handler.rb#26 +Aws::S3::Encryption::DecryptHandler::V2_OPTIONAL_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#9 +class Aws::S3::Encryption::DefaultCipherProvider + # @api private + # @return [DefaultCipherProvider] a new instance of DefaultCipherProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#11 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Cipher] Given an encryption envelope, returns a + # decryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#29 + def decryption_cipher(envelope, options = T.unsafe(nil)); end + + # @api private + # @return [Array] Creates an returns a new encryption + # envelope and encryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#17 + def encryption_cipher; end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#95 + def decode64(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#91 + def encode64(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#83 + def encrypt(data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#79 + def envelope_iv(cipher); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#75 + def envelope_key(cipher); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_cipher_provider.rb#87 + def materials_description; end +end + +# The default key provider is constructed with a single key +# that is used for both encryption and decryption, ignoring +# the possible per-object envelope encryption materials description. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_key_provider.rb#11 +class Aws::S3::Encryption::DefaultKeyProvider + include ::Aws::S3::Encryption::KeyProvider + + # @api private + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [DefaultKeyProvider] a new instance of DefaultKeyProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_key_provider.rb#19 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Materials] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_key_provider.rb#27 + def encryption_materials; end + + # @api private + # @param materials_description [String] + # @return Returns the key given in the constructor. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/default_key_provider.rb#33 + def key_for(materials_description); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/encrypt_handler.rb#9 +class Aws::S3::Encryption::EncryptHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/encrypt_handler.rb#11 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/encrypt_handler.rb#50 + def apply_cse_user_agent(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/encrypt_handler.rb#36 + def apply_encryption_cipher(context, cipher); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/encrypt_handler.rb#21 + def apply_encryption_envelope(context, envelope, cipher); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/errors.rb#6 +module Aws::S3::Encryption::Errors; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/errors.rb#8 +class Aws::S3::Encryption::Errors::DecryptionError < ::RuntimeError; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/errors.rb#10 +class Aws::S3::Encryption::Errors::EncryptionError < ::RuntimeError; end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_auth_decrypter.rb#7 +class Aws::S3::Encryption::IOAuthDecrypter + # @api private + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [IOAuthDecrypter] a new instance of IOAuthDecrypter + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_auth_decrypter.rb#19 + def initialize(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_auth_decrypter.rb#33 + def finalize; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_auth_decrypter.rb#37 + def io; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_auth_decrypter.rb#25 + def write(chunk); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_auth_decrypter.rb#43 + def truncate_chunk(chunk); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_decrypter.rb#7 +class Aws::S3::Encryption::IODecrypter + # @api private + # @param cipher [OpenSSL::Cipher] + # @param io [IO#write] An IO-like object that responds to `#write`. + # @return [IODecrypter] a new instance of IODecrypter + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_decrypter.rb#11 + def initialize(cipher, io); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_decrypter.rb#30 + def finalize; end + + # @api private + # @return [#write] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_decrypter.rb#19 + def io; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_decrypter.rb#21 + def write(chunk); end +end + +# Provides an IO wrapper encrpyting a stream of data. +# It is possible to use this same object for decrypting. You must +# initialize it with a decryptiion cipher in that case and the +# IO object must contain cipher text instead of plain text. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#15 +class Aws::S3::Encryption::IOEncrypter + # @api private + # @return [IOEncrypter] a new instance of IOEncrypter + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#20 + def initialize(cipher, io); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#43 + def close; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#30 + def read(bytes = T.unsafe(nil), output_buffer = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#38 + def rewind; end + + # @api private + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#28 + def size; end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#49 + def encrypt_to_stringio(cipher, plain_text); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#57 + def encrypt_to_tempfile(cipher, io); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/io_encrypter.rb#18 +Aws::S3::Encryption::IOEncrypter::ONE_MEGABYTE = T.let(T.unsafe(nil), Integer) + +# This module defines the interface required for a {Client#key_provider}. +# A key provider is any object that: +# +# * Responds to {#encryption_materials} with an {Materials} object. +# +# * Responds to {#key_for}, receiving a JSON document String, +# returning an encryption key. The returned encryption key +# must be one of: +# +# * `OpenSSL::PKey::RSA` - for asymmetric encryption +# * `String` - 32, 24, or 16 bytes long, for symmetric encryption +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/key_provider.rb#19 +module Aws::S3::Encryption::KeyProvider + # @return [Materials] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/key_provider.rb#22 + def encryption_materials; end + + # @param materials_description [String] + # @return [OpenSSL::PKey::RSA, String] encryption_key + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/key_provider.rb#26 + def key_for(materials_description); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/kms_cipher_provider.rb#9 +class Aws::S3::Encryption::KmsCipherProvider + # @api private + # @return [KmsCipherProvider] a new instance of KmsCipherProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/kms_cipher_provider.rb#11 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Cipher] Given an encryption envelope, returns a + # decryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/kms_cipher_provider.rb#41 + def decryption_cipher(envelope, options = T.unsafe(nil)); end + + # @api private + # @return [Array] Creates an returns a new encryption + # envelope and encryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/kms_cipher_provider.rb#18 + def encryption_cipher; end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/kms_cipher_provider.rb#89 + def build_encryption_context(cek_alg, options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/kms_cipher_provider.rb#101 + def decode64(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/kms_cipher_provider.rb#97 + def encode64(str); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/materials.rb#8 +class Aws::S3::Encryption::Materials + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Materials] a new instance of Materials + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/materials.rb#17 + def initialize(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/materials.rb#26 + def description; end + + # @return [OpenSSL::PKey::RSA, String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/materials.rb#23 + def key; end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/materials.rb#49 + def validate_desc(description); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/materials.rb#30 + def validate_key(key); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#9 +module Aws::S3::Encryption::Utils + class << self + # @api private + # @param mode [String] "encrypt" or "decrypt" + # @param block_mode [String] "CBC" or "ECB" + # @param key [OpenSSL::PKey::RSA, String, nil] + # @param iv [String, nil] The initialization vector + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#83 + def aes_cipher(mode, block_mode, key, iv); end + + # @api private + # @param block_mode [String] "CBC" or "ECB" + # @param key [OpenSSL::PKey::RSA, String, nil] + # @param iv [String, nil] The initialization vector + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#75 + def aes_decryption_cipher(block_mode, key = T.unsafe(nil), iv = T.unsafe(nil)); end + + # @api private + # @param block_mode [String] "CBC" or "ECB" + # @param key [OpenSSL::PKey::RSA, String, nil] + # @param iv [String, nil] The initialization vector + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#68 + def aes_encryption_cipher(block_mode, key = T.unsafe(nil), iv = T.unsafe(nil)); end + + # @api private + # @param key [String] + # @raise ArgumentError + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#96 + def cipher_size(key); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#27 + def decrypt(key, data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#43 + def decrypt_aes_gcm(key, data, auth_data); end + + # returns the decrypted data + auth_data + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#56 + def decrypt_rsa(key, enc_data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#15 + def encrypt(key, data); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption/utils.rb#11 +Aws::S3::Encryption::Utils::UNSAFE_MSG = T.let(T.unsafe(nil), String) + +# Provides an encryption client that encrypts and decrypts data client-side, +# storing the encrypted data in Amazon S3. The `EncryptionV2::Client` (V2 Client) +# provides improved security over the `Encryption::Client` (V1 Client) +# by using more modern and secure algorithms. You can use the V2 Client +# to continue decrypting objects encrypted using deprecated algorithms +# by setting security_profile: :v2_and_legacy. The latest V1 Client also +# supports reading and decrypting objects encrypted by the V2 Client. +# +# This client uses a process called "envelope encryption". Your private +# encryption keys and your data's plain-text are **never** sent to +# Amazon S3. **If you lose you encryption keys, you will not be able to +# decrypt your data.** +# +# ## Envelope Encryption Overview +# +# The goal of envelope encryption is to combine the performance of +# fast symmetric encryption while maintaining the secure key management +# that asymmetric keys provide. +# +# A one-time-use symmetric key (envelope key) is generated client-side. +# This is used to encrypt the data client-side. This key is then +# encrypted by your master key and stored alongside your data in Amazon +# S3. +# +# When accessing your encrypted data with the encryption client, +# the encrypted envelope key is retrieved and decrypted client-side +# with your master key. The envelope key is then used to decrypt the +# data client-side. +# +# One of the benefits of envelope encryption is that if your master key +# is compromised, you have the option of just re-encrypting the stored +# envelope symmetric keys, instead of re-encrypting all of the +# data in your account. +# +# ## Basic Usage +# +# The encryption client requires an {Aws::S3::Client}. If you do not +# provide a `:client`, then a client will be constructed for you. +# +# require 'openssl' +# key = OpenSSL::PKey::RSA.new(1024) +# +# # encryption client +# s3 = Aws::S3::EncryptionV2::Client.new( +# encryption_key: key, +# key_wrap_schema: :rsa_oaep_sha1, # the key_wrap_schema must be rsa_oaep_sha1 for asymmetric keys +# content_encryption_schema: :aes_gcm_no_padding, +# security_profile: :v2 # use :v2_and_legacy to allow reading/decrypting objects encrypted by the V1 encryption client +# ) +# +# # round-trip an object, encrypted/decrypted locally +# s3.put_object(bucket:'aws-sdk', key:'secret', body:'handshake') +# s3.get_object(bucket:'aws-sdk', key:'secret').body.read +# #=> 'handshake' +# +# # reading encrypted object without the encryption client +# # results in the getting the cipher text +# Aws::S3::Client.new.get_object(bucket:'aws-sdk', key:'secret').body.read +# #=> "... cipher text ..." +# +# ## Required Configuration +# +# You must configure all of the following: +# +# * a key or key provider - See the Keys section below. The key provided determines +# the key wrapping schema(s) supported for both encryption and decryption. +# * `key_wrap_schema` - The key wrapping schema. It must match the type of key configured. +# * `content_encryption_schema` - The only supported value currently is `:aes_gcm_no_padding`. +# More options will be added in future releases. +# * `security_profile` - Determines the support for reading objects written +# using older key wrap or content encryption schemas. If you need to read +# legacy objects encrypted by an existing V1 Client, then set this to `:v2_and_legacy`. +# Otherwise, set it to `:v2` +# +# ## Keys +# +# For client-side encryption to work, you must provide one of the following: +# +# * An encryption key +# * A {KeyProvider} +# * A KMS encryption key id +# +# Additionally, the key wrapping schema must agree with the type of the key: +# * :aes_gcm: An AES encryption key or a key provider. +# * :rsa_oaep_sha1: An RSA encryption key or key provider. +# * :kms_context: A KMS encryption key id +# +# ### An Encryption Key +# +# You can pass a single encryption key. This is used as a master key +# encrypting and decrypting all object keys. +# +# key = OpenSSL::Cipher.new("AES-256-ECB").random_key # symmetric key - used with `key_wrap_schema: :aes_gcm` +# key = OpenSSL::PKey::RSA.new(1024) # asymmetric key pair - used with `key_wrap_schema: :rsa_oaep_sha1` +# +# s3 = Aws::S3::EncryptionV2::Client.new( +# encryption_key: key, +# key_wrap_schema: :aes_gcm, # or :rsa_oaep_sha1 if using RSA +# content_encryption_schema: :aes_gcm_no_padding, +# security_profile: :v2 +# ) +# +# ### Key Provider +# +# Alternatively, you can use a {KeyProvider}. A key provider makes +# it easy to work with multiple keys and simplifies key rotation. +# +# ### KMS Encryption Key Id +# +# If you pass the id of an AWS Key Management Service (KMS) key and +# use :kms_content for the key_wrap_schema, then KMS will be used to +# generate, encrypt and decrypt object keys. +# +# # keep track of the kms key id +# kms = Aws::KMS::Client.new +# key_id = kms.create_key.key_metadata.key_id +# +# Aws::S3::EncryptionV2::Client.new( +# kms_key_id: key_id, +# kms_client: kms, +# key_wrap_schema: :kms_context, +# content_encryption_schema: :aes_gcm_no_padding, +# security_profile: :v2 +# ) +# +# ## Custom Key Providers +# +# A {KeyProvider} is any object that responds to: +# +# * `#encryption_materials` +# * `#key_for(materials_description)` +# +# Here is a trivial implementation of an in-memory key provider. +# This is provided as a demonstration of the key provider interface, +# and should not be used in production: +# +# class KeyProvider +# +# def initialize(default_key_name, keys) +# @keys = keys +# @encryption_materials = Aws::S3::EncryptionV2::Materials.new( +# key: @keys[default_key_name], +# description: JSON.dump(key: default_key_name), +# ) +# end +# +# attr_reader :encryption_materials +# +# def key_for(matdesc) +# key_name = JSON.parse(matdesc)['key'] +# if key = @keys[key_name] +# key +# else +# raise "encryption key not found for: #{matdesc.inspect}" +# end +# end +# end +# +# Given the above key provider, you can create an encryption client that +# chooses the key to use based on the materials description stored with +# the encrypted object. This makes it possible to use multiple keys +# and simplifies key rotation. +# +# # uses "new-key" for encrypting objects, uses either for decrypting +# keys = KeyProvider.new('new-key', { +# "old-key" => Base64.decode64("kM5UVbhE/4rtMZJfsadYEdm2vaKFsmV2f5+URSeUCV4="), +# "new-key" => Base64.decode64("w1WLio3agRWRTSJK/Ouh8NHoqRQ6fn5WbSXDTHjXMSo="), +# }), +# +# # chooses the key based on the materials description stored +# # with the encrypted object +# s3 = Aws::S3::EncryptionV2::Client.new( +# key_provider: keys, +# key_wrap_schema: ..., +# content_encryption_schema: :aes_gcm_no_padding, +# security_profile: :v2 +# ) +# +# ## Materials Description +# +# A materials description is JSON document string that is stored +# in the metadata (or instruction file) of an encrypted object. +# The {DefaultKeyProvider} uses the empty JSON document `"{}"`. +# +# When building a key provider, you are free to store whatever +# information you need to identify the master key that was used +# to encrypt the object. +# +# ## Envelope Location +# +# By default, the encryption client store the encryption envelope +# with the object, as metadata. You can choose to have the envelope +# stored in a separate "instruction file". An instruction file +# is an object, with the key of the encrypted object, suffixed with +# `".instruction"`. +# +# Specify the `:envelope_location` option as `:instruction_file` to +# use an instruction file for storing the envelope. +# +# # default behavior +# s3 = Aws::S3::EncryptionV2::Client.new( +# key_provider: ..., +# envelope_location: :metadata, +# ) +# +# # store envelope in a separate object +# s3 = Aws::S3::EncryptionV2::Client.new( +# key_provider: ..., +# envelope_location: :instruction_file, +# instruction_file_suffix: '.instruction' # default +# key_wrap_schema: ..., +# content_encryption_schema: :aes_gcm_no_padding, +# security_profile: :v2 +# ) +# +# When using an instruction file, multiple requests are made when +# putting and getting the object. **This may cause issues if you are +# issuing concurrent PUT and GET requests to an encrypted object.** +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#230 +module Aws::S3::EncryptionV2; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption_v2.rb#18 +Aws::S3::EncryptionV2::AES_GCM_TAG_LEN_BYTES = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#231 +class Aws::S3::EncryptionV2::Client + extend ::Aws::Deprecations + extend ::Forwardable + + # Creates a new encryption client. You must configure all of the following: + # + # * a key or key provider - The key provided also determines the key wrapping + # schema(s) supported for both encryption and decryption. + # * `key_wrap_schema` - The key wrapping schema. It must match the type of key configured. + # * `content_encryption_schema` - The only supported value currently is `:aes_gcm_no_padding` + # More options will be added in future releases. + # * `security_profile` - Determines the support for reading objects written + # using older key wrap or content encryption schemas. If you need to read + # legacy objects encrypted by an existing V1 Client, then set this to `:v2_and_legacy`. + # Otherwise, set it to `:v2` + # + # To configure the key you must provide one of the following set of options: + # + # * `:encryption_key` + # * `:kms_key_id` + # * `:key_provider` + # + # You may also pass any other options accepted by `Client#initialize`. + # + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Client] a new instance of Client + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#310 + def initialize(options = T.unsafe(nil)); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def build_request(*args, **_arg1, &block); end + + # @return [S3::Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#322 + def client; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def config(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def delete_object(*args, **_arg1, &block); end + + # @return [Symbol<:metadata, :instruction_file>] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#337 + def envelope_location; end + + # Gets an object from Amazon S3, decrypting data locally. + # See {S3::Client#get_object} for documentation on accepted + # request parameters. + # Warning: If you provide a block to get_object or set the request + # parameter :response_target to a Proc, then read the entire object to the + # end before you start using the decrypted data. This is to verify that + # the object has not been modified since it was encrypted. + # + # @note The `:range` request parameter is not supported. + # @option options + # @option params + # @option params + # @option options + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param options [Hash] a customizable set of options + # @param params [Hash] a customizable set of options + # @return [Types::GetObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetObjectOutput#body #body} => IO + # * {Types::GetObjectOutput#delete_marker #delete_marker} => Boolean + # * {Types::GetObjectOutput#accept_ranges #accept_ranges} => String + # * {Types::GetObjectOutput#expiration #expiration} => String + # * {Types::GetObjectOutput#restore #restore} => String + # * {Types::GetObjectOutput#last_modified #last_modified} => Time + # * {Types::GetObjectOutput#content_length #content_length} => Integer + # * {Types::GetObjectOutput#etag #etag} => String + # * {Types::GetObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::GetObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::GetObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::GetObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::GetObjectOutput#missing_meta #missing_meta} => Integer + # * {Types::GetObjectOutput#version_id #version_id} => String + # * {Types::GetObjectOutput#cache_control #cache_control} => String + # * {Types::GetObjectOutput#content_disposition #content_disposition} => String + # * {Types::GetObjectOutput#content_encoding #content_encoding} => String + # * {Types::GetObjectOutput#content_language #content_language} => String + # * {Types::GetObjectOutput#content_range #content_range} => String + # * {Types::GetObjectOutput#content_type #content_type} => String + # * {Types::GetObjectOutput#expires #expires} => Time + # * {Types::GetObjectOutput#expires_string #expires_string} => String + # * {Types::GetObjectOutput#website_redirect_location #website_redirect_location} => String + # * {Types::GetObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::GetObjectOutput#metadata #metadata} => Hash<String,String> + # * {Types::GetObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::GetObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::GetObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::GetObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::GetObjectOutput#storage_class #storage_class} => String + # * {Types::GetObjectOutput#request_charged #request_charged} => String + # * {Types::GetObjectOutput#replication_status #replication_status} => String + # * {Types::GetObjectOutput#parts_count #parts_count} => Integer + # * {Types::GetObjectOutput#tag_count #tag_count} => Integer + # * {Types::GetObjectOutput#object_lock_mode #object_lock_mode} => String + # * {Types::GetObjectOutput#object_lock_retain_until_date #object_lock_retain_until_date} => Time + # * {Types::GetObjectOutput#object_lock_legal_hold_status #object_lock_legal_hold_status} => String + # @see S3::Client#get_object + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#400 + def get_object(params = T.unsafe(nil), &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def head_object(*args, **_arg1, &block); end + + # @return [String] When {#envelope_location} is `:instruction_file`, + # the envelope is stored in the object with the object key suffixed + # by this string. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#342 + def instruction_file_suffix; end + + # @return [KeyProvider, nil] Returns `nil` if you are using + # AWS Key Management Service (KMS). + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#326 + def key_provider; end + + # @return [Boolean] If true the provided KMS key_id will not be used + # during decrypt, allowing decryption with the key_id from the object. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#334 + def kms_allow_decrypt_with_any_cmk; end + + # Uploads an object to Amazon S3, encrypting data client-side. + # See {S3::Client#put_object} for documentation on accepted + # request parameters. + # + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param params [Hash] a customizable set of options + # @return [Types::PutObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::PutObjectOutput#expiration #expiration} => String + # * {Types::PutObjectOutput#etag #etag} => String + # * {Types::PutObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::PutObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::PutObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::PutObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::PutObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::PutObjectOutput#version_id #version_id} => String + # * {Types::PutObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::PutObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::PutObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::PutObjectOutput#ssekms_encryption_context #ssekms_encryption_context} => String + # * {Types::PutObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::PutObjectOutput#request_charged #request_charged} => String + # @see S3::Client#put_object + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#354 + def put_object(params = T.unsafe(nil)); end + + # @return [Symbol] Determines the support for reading objects written + # using older key wrap or content encryption schemas. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#330 + def security_profile; end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#469 + def cipher_provider(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#498 + def envelope_options(params); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#446 + def extract_client(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#487 + def extract_key_provider(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#508 + def extract_location(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#537 + def extract_security_profile(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#519 + def extract_suffix(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#529 + def kms_any_cmk_mode(params); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#460 + def kms_client(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#541 + def security_profile_from_params(params); end + + # Validate required parameters exist and don't conflict. + # The cek_alg and wrap_alg are passed on to the CipherProviders + # and further validated there + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#429 + def validate_params(options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#551 + def validate_security_profile(security_profile); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#9 +class Aws::S3::EncryptionV2::DecryptHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#46 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#212 + def apply_cse_user_agent(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#65 + def attach_http_event_listeners(context); end + + # Determine the auth tag length from the algorithm + # Validate it against the value provided in the x-amz-tag-len + # Return the tag length in bytes + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#198 + def auth_tag_length(envelope); end + + # This method fetches the tag from the end of the object by + # making a GET Object w/range request. This auth tag is used + # to initialize the cipher, and the decrypter truncates the + # auth tag from the body when writing the final bytes. + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#168 + def authenticated_decrypter(context, cipher, envelope); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#191 + def body_contains_auth_tag?(envelope); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#89 + def decryption_cipher(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#120 + def envelope_from_instr_file(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#110 + def envelope_from_metadata(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#131 + def extract_envelope(hash); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#102 + def get_encryption_envelope(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#141 + def v1_envelope(envelope); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#145 + def v2_envelope(envelope); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#44 +Aws::S3::EncryptionV2::DecryptHandler::AUTH_REQUIRED_CEK_ALGS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#38 +Aws::S3::EncryptionV2::DecryptHandler::POSSIBLE_ENCRYPTION_FORMATS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#28 +Aws::S3::EncryptionV2::DecryptHandler::POSSIBLE_ENVELOPE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#31 +Aws::S3::EncryptionV2::DecryptHandler::POSSIBLE_WRAPPING_FORMATS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#12 +Aws::S3::EncryptionV2::DecryptHandler::V1_ENVELOPE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#18 +Aws::S3::EncryptionV2::DecryptHandler::V2_ENVELOPE_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb#26 +Aws::S3::EncryptionV2::DecryptHandler::V2_OPTIONAL_KEYS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#9 +class Aws::S3::EncryptionV2::DefaultCipherProvider + # @api private + # @return [DefaultCipherProvider] a new instance of DefaultCipherProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#11 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Cipher] Given an encryption envelope, returns a + # decryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#50 + def decryption_cipher(envelope, options = T.unsafe(nil)); end + + # @api private + # @return [Array] Creates an returns a new encryption + # envelope and encryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#24 + def encryption_cipher(options = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#157 + def decode64(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#153 + def encode64(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#141 + def encrypt_aes_gcm(data, auth_data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#145 + def encrypt_rsa(data, auth_data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#137 + def envelope_iv(cipher); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#133 + def envelope_key(cipher); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#149 + def materials_description; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#124 + def validate_cek(content_encryption_schema); end + + # Validate that the key_wrap_schema + # is valid, supported and matches the provided key. + # Returns the string version for the x-amz-key-wrap-alg + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#103 + def validate_key_wrap(key_wrap_schema, key); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb#161 + def validate_options(options); end +end + +# The default key provider is constructed with a single key +# that is used for both encryption and decryption, ignoring +# the possible per-object envelope encryption materials description. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_key_provider.rb#11 +class Aws::S3::EncryptionV2::DefaultKeyProvider + include ::Aws::S3::EncryptionV2::KeyProvider + + # @api private + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [DefaultKeyProvider] a new instance of DefaultKeyProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_key_provider.rb#19 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Materials] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_key_provider.rb#27 + def encryption_materials; end + + # @api private + # @param materials_description [String] + # @return Returns the key given in the constructor. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/default_key_provider.rb#33 + def key_for(materials_description); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryption_v2.rb#19 +Aws::S3::EncryptionV2::EC_USER_AGENT = T.let(T.unsafe(nil), String) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb#9 +class Aws::S3::EncryptionV2::EncryptHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb#11 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb#54 + def apply_cse_user_agent(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb#39 + def apply_encryption_cipher(context, cipher); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb#25 + def apply_encryption_envelope(context, envelope); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/errors.rb#6 +module Aws::S3::EncryptionV2::Errors; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/errors.rb#25 +class Aws::S3::EncryptionV2::Errors::CEKAlgMismatchError < ::Aws::S3::EncryptionV2::Errors::DecryptionError + # @return [CEKAlgMismatchError] a new instance of CEKAlgMismatchError + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/errors.rb#26 + def initialize(*args); end +end + +# Generic DecryptionError +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/errors.rb#9 +class Aws::S3::EncryptionV2::Errors::DecryptionError < ::RuntimeError; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/errors.rb#11 +class Aws::S3::EncryptionV2::Errors::EncryptionError < ::RuntimeError; end + +# Raised when attempting to decrypt a legacy (V1) encrypted object +# when using a security_profile that does not support it. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/errors.rb#15 +class Aws::S3::EncryptionV2::Errors::LegacyDecryptionError < ::Aws::S3::EncryptionV2::Errors::DecryptionError + # @return [LegacyDecryptionError] a new instance of LegacyDecryptionError + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/errors.rb#16 + def initialize(*args); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb#7 +class Aws::S3::EncryptionV2::IOAuthDecrypter + # @api private + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [IOAuthDecrypter] a new instance of IOAuthDecrypter + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb#19 + def initialize(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb#33 + def finalize; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb#37 + def io; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb#25 + def write(chunk); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb#43 + def truncate_chunk(chunk); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_decrypter.rb#7 +class Aws::S3::EncryptionV2::IODecrypter + # @api private + # @param cipher [OpenSSL::Cipher] + # @param io [IO#write] An IO-like object that responds to `#write`. + # @return [IODecrypter] a new instance of IODecrypter + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_decrypter.rb#11 + def initialize(cipher, io); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_decrypter.rb#30 + def finalize; end + + # @api private + # @return [#write] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_decrypter.rb#19 + def io; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_decrypter.rb#21 + def write(chunk); end +end + +# Provides an IO wrapper encrypting a stream of data. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#12 +class Aws::S3::EncryptionV2::IOEncrypter + # @api private + # @return [IOEncrypter] a new instance of IOEncrypter + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#17 + def initialize(cipher, io); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#40 + def close; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#27 + def read(bytes = T.unsafe(nil), output_buffer = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#35 + def rewind; end + + # @api private + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#25 + def size; end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#46 + def encrypt_to_stringio(cipher, plain_text); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#54 + def encrypt_to_tempfile(cipher, io); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/io_encrypter.rb#15 +Aws::S3::EncryptionV2::IOEncrypter::ONE_MEGABYTE = T.let(T.unsafe(nil), Integer) + +# This module defines the interface required for a {Client#key_provider}. +# A key provider is any object that: +# +# * Responds to {#encryption_materials} with an {Materials} object. +# +# * Responds to {#key_for}, receiving a JSON document String, +# returning an encryption key. The returned encryption key +# must be one of: +# +# * `OpenSSL::PKey::RSA` - for asymmetric encryption +# * `String` - 32, 24, or 16 bytes long, for symmetric encryption +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/key_provider.rb#19 +module Aws::S3::EncryptionV2::KeyProvider + # @return [Materials] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/key_provider.rb#22 + def encryption_materials; end + + # @param materials_description [String] + # @return [OpenSSL::PKey::RSA, String] encryption_key + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/key_provider.rb#26 + def key_for(materials_description); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#9 +class Aws::S3::EncryptionV2::KmsCipherProvider + # @api private + # @return [KmsCipherProvider] a new instance of KmsCipherProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#11 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Cipher] Given an encryption envelope, returns a + # decryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#50 + def decryption_cipher(envelope, options = T.unsafe(nil)); end + + # @api private + # @return [Array] Creates and returns a new encryption + # envelope and encryption cipher. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#24 + def encryption_cipher(options = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#142 + def build_encryption_context(cek_alg, options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#159 + def decode64(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#155 + def encode64(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#118 + def validate_cek(content_encryption_schema); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#163 + def validate_key_for_encryption; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#110 + def validate_key_wrap(key_wrap_schema); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb#127 + def validate_kms_key(kms_key_id); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/materials.rb#8 +class Aws::S3::EncryptionV2::Materials + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Materials] a new instance of Materials + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/materials.rb#17 + def initialize(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/materials.rb#26 + def description; end + + # @return [OpenSSL::PKey::RSA, String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/materials.rb#23 + def key; end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/materials.rb#49 + def validate_desc(description); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/materials.rb#30 + def validate_key(key); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#9 +module Aws::S3::EncryptionV2::Utils + class << self + # @api private + # @param mode [String] "encrypt" or "decrypt" + # @param block_mode [String] "CBC" or "ECB" + # @param key [OpenSSL::PKey::RSA, String, nil] + # @param iv [String, nil] The initialization vector + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#82 + def aes_cipher(mode, block_mode, key, iv); end + + # @api private + # @param block_mode [String] "CBC" or "ECB" + # @param key [OpenSSL::PKey::RSA, String, nil] + # @param iv [String, nil] The initialization vector + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#74 + def aes_decryption_cipher(block_mode, key = T.unsafe(nil), iv = T.unsafe(nil)); end + + # @api private + # @param block_mode [String] "CBC" or "ECB" + # @param key [OpenSSL::PKey::RSA, String, nil] + # @param iv [String, nil] The initialization vector + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#67 + def aes_encryption_cipher(block_mode, key = T.unsafe(nil), iv = T.unsafe(nil)); end + + # @api private + # @param key [String] + # @raise ArgumentError + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#95 + def cipher_size(key); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#27 + def decrypt(key, data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#42 + def decrypt_aes_gcm(key, data, auth_data); end + + # returns the decrypted data + auth_data + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#55 + def decrypt_rsa(key, enc_data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#13 + def encrypt_aes_gcm(key, data, auth_data); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/utils.rb#21 + def encrypt_rsa(key, data, auth_data); end + end +end + +# Endpoint parameters used to influence endpoints per request. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoint_parameters.rb#98 +class Aws::S3::EndpointParameters < ::Struct + include ::Aws::Structure + + # @return [EndpointParameters] a new instance of EndpointParameters + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoint_parameters.rb#142 + def initialize(options = T.unsafe(nil)); end + + # When true, use S3 Accelerate. NOTE: Not all regions support S3 accelerate. + # + # @return [Boolean] + def accelerate; end + + # When true, use S3 Accelerate. NOTE: Not all regions support S3 accelerate. + # + # @return [Boolean] + def accelerate=(_); end + + # The S3 bucket used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 bucket. + # + # @return [String] + def bucket; end + + # The S3 bucket used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 bucket. + # + # @return [String] + def bucket=(_); end + + # The Copy Source used for Copy Object request. This is an optional parameter that will be set automatically for operations that are scoped to Copy Source. + # + # @return [String] + def copy_source; end + + # The Copy Source used for Copy Object request. This is an optional parameter that will be set automatically for operations that are scoped to Copy Source. + # + # @return [String] + def copy_source=(_); end + + # Internal parameter to disable Access Point Buckets + # + # @return [Boolean] + def disable_access_points; end + + # Internal parameter to disable Access Point Buckets + # + # @return [Boolean] + def disable_access_points=(_); end + + # Whether multi-region access points (MRAP) should be disabled. + # + # @return [Boolean] + def disable_multi_region_access_points; end + + # Whether multi-region access points (MRAP) should be disabled. + # + # @return [Boolean] + def disable_multi_region_access_points=(_); end + + # Parameter to indicate whether S3Express session auth should be disabled + # + # @return [Boolean] + def disable_s3_express_session_auth; end + + # Parameter to indicate whether S3Express session auth should be disabled + # + # @return [Boolean] + def disable_s3_express_session_auth=(_); end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint; end + + # Override the endpoint used to send this request + # + # @return [String] + def endpoint=(_); end + + # When true, force a path-style endpoint to be used where the bucket name is part of the path. + # + # @return [Boolean] + def force_path_style; end + + # When true, force a path-style endpoint to be used where the bucket name is part of the path. + # + # @return [Boolean] + def force_path_style=(_); end + + # The S3 Key used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 Key. + # + # @return [String] + def key; end + + # The S3 Key used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 Key. + # + # @return [String] + def key=(_); end + + # The S3 Prefix used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 Prefix. + # + # @return [String] + def prefix; end + + # The S3 Prefix used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 Prefix. + # + # @return [String] + def prefix=(_); end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region; end + + # The AWS region used to dispatch the request. + # + # @return [String] + def region=(_); end + + # When an Access Point ARN is provided and this flag is enabled, the SDK MUST use the ARN's region when constructing the endpoint instead of the client's configured region. + # + # @return [Boolean] + def use_arn_region; end + + # When an Access Point ARN is provided and this flag is enabled, the SDK MUST use the ARN's region when constructing the endpoint instead of the client's configured region. + # + # @return [Boolean] + def use_arn_region=(_); end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack; end + + # When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error. + # + # @return [Boolean] + def use_dual_stack=(_); end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips; end + + # When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error. + # + # @return [Boolean] + def use_fips=(_); end + + # Whether the global endpoint should be used, rather then the regional endpoint for us-east-1. + # + # @return [Boolean] + def use_global_endpoint; end + + # Whether the global endpoint should be used, rather then the regional endpoint for us-east-1. + # + # @return [Boolean] + def use_global_endpoint=(_); end + + # Internal parameter to use object lambda endpoint for an operation (eg: WriteGetObjectResponse) + # + # @return [Boolean] + def use_object_lambda_endpoint; end + + # Internal parameter to use object lambda endpoint for an operation (eg: WriteGetObjectResponse) + # + # @return [Boolean] + def use_object_lambda_endpoint=(_); end + + # Internal parameter to indicate whether S3Express operation should use control plane, (ex. CreateBucket) + # + # @return [Boolean] + def use_s3_express_control_endpoint; end + + # Internal parameter to indicate whether S3Express operation should use control plane, (ex. CreateBucket) + # + # @return [Boolean] + def use_s3_express_control_endpoint=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoint_provider.rb#11 +class Aws::S3::EndpointProvider + # @raise [ArgumentError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoint_provider.rb#12 + def resolve_endpoint(parameters); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#13 +module Aws::S3::Endpoints; end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#15 +class Aws::S3::Endpoints::AbortMultipartUpload + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#16 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#42 +class Aws::S3::Endpoints::CompleteMultipartUpload + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#43 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#69 +class Aws::S3::Endpoints::CopyObject + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#70 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#96 +class Aws::S3::Endpoints::CreateBucket + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#97 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#123 +class Aws::S3::Endpoints::CreateMultipartUpload + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#124 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#150 +class Aws::S3::Endpoints::CreateSession + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#151 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#177 +class Aws::S3::Endpoints::DeleteBucket + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#178 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#204 +class Aws::S3::Endpoints::DeleteBucketAnalyticsConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#205 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#231 +class Aws::S3::Endpoints::DeleteBucketCors + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#232 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#258 +class Aws::S3::Endpoints::DeleteBucketEncryption + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#259 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#285 +class Aws::S3::Endpoints::DeleteBucketIntelligentTieringConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#286 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#312 +class Aws::S3::Endpoints::DeleteBucketInventoryConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#313 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#339 +class Aws::S3::Endpoints::DeleteBucketLifecycle + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#340 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#366 +class Aws::S3::Endpoints::DeleteBucketMetricsConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#367 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#393 +class Aws::S3::Endpoints::DeleteBucketOwnershipControls + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#394 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#420 +class Aws::S3::Endpoints::DeleteBucketPolicy + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#421 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#447 +class Aws::S3::Endpoints::DeleteBucketReplication + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#448 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#474 +class Aws::S3::Endpoints::DeleteBucketTagging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#475 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#501 +class Aws::S3::Endpoints::DeleteBucketWebsite + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#502 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#528 +class Aws::S3::Endpoints::DeleteObject + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#529 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#555 +class Aws::S3::Endpoints::DeleteObjectTagging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#556 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#582 +class Aws::S3::Endpoints::DeleteObjects + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#583 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#609 +class Aws::S3::Endpoints::DeletePublicAccessBlock + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#610 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#636 +class Aws::S3::Endpoints::GetBucketAccelerateConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#637 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#663 +class Aws::S3::Endpoints::GetBucketAcl + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#664 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#690 +class Aws::S3::Endpoints::GetBucketAnalyticsConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#691 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#717 +class Aws::S3::Endpoints::GetBucketCors + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#718 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#744 +class Aws::S3::Endpoints::GetBucketEncryption + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#745 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#771 +class Aws::S3::Endpoints::GetBucketIntelligentTieringConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#772 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#798 +class Aws::S3::Endpoints::GetBucketInventoryConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#799 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#825 +class Aws::S3::Endpoints::GetBucketLifecycle + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#826 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#852 +class Aws::S3::Endpoints::GetBucketLifecycleConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#853 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#879 +class Aws::S3::Endpoints::GetBucketLocation + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#880 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#906 +class Aws::S3::Endpoints::GetBucketLogging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#907 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#933 +class Aws::S3::Endpoints::GetBucketMetricsConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#934 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#960 +class Aws::S3::Endpoints::GetBucketNotification + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#961 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#987 +class Aws::S3::Endpoints::GetBucketNotificationConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#988 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1014 +class Aws::S3::Endpoints::GetBucketOwnershipControls + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1015 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1041 +class Aws::S3::Endpoints::GetBucketPolicy + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1042 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1068 +class Aws::S3::Endpoints::GetBucketPolicyStatus + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1069 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1095 +class Aws::S3::Endpoints::GetBucketReplication + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1096 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1122 +class Aws::S3::Endpoints::GetBucketRequestPayment + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1123 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1149 +class Aws::S3::Endpoints::GetBucketTagging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1150 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1176 +class Aws::S3::Endpoints::GetBucketVersioning + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1177 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1203 +class Aws::S3::Endpoints::GetBucketWebsite + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1204 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1230 +class Aws::S3::Endpoints::GetObject + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1231 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1257 +class Aws::S3::Endpoints::GetObjectAcl + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1258 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1284 +class Aws::S3::Endpoints::GetObjectAttributes + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1285 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1311 +class Aws::S3::Endpoints::GetObjectLegalHold + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1312 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1338 +class Aws::S3::Endpoints::GetObjectLockConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1339 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1365 +class Aws::S3::Endpoints::GetObjectRetention + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1366 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1392 +class Aws::S3::Endpoints::GetObjectTagging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1393 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1419 +class Aws::S3::Endpoints::GetObjectTorrent + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1420 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1446 +class Aws::S3::Endpoints::GetPublicAccessBlock + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1447 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1473 +class Aws::S3::Endpoints::HeadBucket + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1474 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1500 +class Aws::S3::Endpoints::HeadObject + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1501 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1527 +class Aws::S3::Endpoints::ListBucketAnalyticsConfigurations + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1528 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1554 +class Aws::S3::Endpoints::ListBucketIntelligentTieringConfigurations + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1555 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1581 +class Aws::S3::Endpoints::ListBucketInventoryConfigurations + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1582 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1608 +class Aws::S3::Endpoints::ListBucketMetricsConfigurations + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1609 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1635 +class Aws::S3::Endpoints::ListBuckets + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1636 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1662 +class Aws::S3::Endpoints::ListDirectoryBuckets + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1663 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1689 +class Aws::S3::Endpoints::ListMultipartUploads + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1690 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1716 +class Aws::S3::Endpoints::ListObjectVersions + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1717 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1743 +class Aws::S3::Endpoints::ListObjects + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1744 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1770 +class Aws::S3::Endpoints::ListObjectsV2 + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1771 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1797 +class Aws::S3::Endpoints::ListParts + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1798 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1824 +class Aws::S3::Endpoints::PutBucketAccelerateConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1825 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1851 +class Aws::S3::Endpoints::PutBucketAcl + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1852 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1878 +class Aws::S3::Endpoints::PutBucketAnalyticsConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1879 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1905 +class Aws::S3::Endpoints::PutBucketCors + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1906 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1932 +class Aws::S3::Endpoints::PutBucketEncryption + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1933 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1959 +class Aws::S3::Endpoints::PutBucketIntelligentTieringConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1960 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1986 +class Aws::S3::Endpoints::PutBucketInventoryConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#1987 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2013 +class Aws::S3::Endpoints::PutBucketLifecycle + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2014 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2040 +class Aws::S3::Endpoints::PutBucketLifecycleConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2041 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2067 +class Aws::S3::Endpoints::PutBucketLogging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2068 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2094 +class Aws::S3::Endpoints::PutBucketMetricsConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2095 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2121 +class Aws::S3::Endpoints::PutBucketNotification + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2122 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2148 +class Aws::S3::Endpoints::PutBucketNotificationConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2149 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2175 +class Aws::S3::Endpoints::PutBucketOwnershipControls + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2176 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2202 +class Aws::S3::Endpoints::PutBucketPolicy + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2203 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2229 +class Aws::S3::Endpoints::PutBucketReplication + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2230 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2256 +class Aws::S3::Endpoints::PutBucketRequestPayment + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2257 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2283 +class Aws::S3::Endpoints::PutBucketTagging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2284 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2310 +class Aws::S3::Endpoints::PutBucketVersioning + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2311 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2337 +class Aws::S3::Endpoints::PutBucketWebsite + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2338 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2364 +class Aws::S3::Endpoints::PutObject + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2365 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2391 +class Aws::S3::Endpoints::PutObjectAcl + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2392 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2418 +class Aws::S3::Endpoints::PutObjectLegalHold + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2419 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2445 +class Aws::S3::Endpoints::PutObjectLockConfiguration + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2446 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2472 +class Aws::S3::Endpoints::PutObjectRetention + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2473 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2499 +class Aws::S3::Endpoints::PutObjectTagging + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2500 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2526 +class Aws::S3::Endpoints::PutPublicAccessBlock + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2527 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2553 +class Aws::S3::Endpoints::RestoreObject + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2554 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2580 +class Aws::S3::Endpoints::SelectObjectContent + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2581 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2607 +class Aws::S3::Endpoints::UploadPart + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2608 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2634 +class Aws::S3::Endpoints::UploadPartCopy + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2635 + def build(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2661 +class Aws::S3::Endpoints::WriteGetObjectResponse + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/endpoints.rb#2662 + def build(context); end + end +end + +# When S3 returns an error response, the Ruby SDK constructs and raises an error. +# These errors all extend Aws::S3::Errors::ServiceError < {Aws::Errors::ServiceError} +# +# You can rescue all S3 errors using ServiceError: +# +# begin +# # do stuff +# rescue Aws::S3::Errors::ServiceError +# # rescues all S3 API errors +# end +# +# +# ## Request Context +# ServiceError objects have a {Aws::Errors::ServiceError#context #context} method that returns +# information about the request that generated the error. +# See {Seahorse::Client::RequestContext} for more information. +# +# ## Error Classes +# * {BucketAlreadyExists} +# * {BucketAlreadyOwnedByYou} +# * {InvalidObjectState} +# * {NoSuchBucket} +# * {NoSuchKey} +# * {NoSuchUpload} +# * {ObjectAlreadyInActiveTierError} +# * {ObjectNotInActiveTierError} +# +# Additionally, error classes are dynamically generated for service errors based on the error code +# if they are not defined above. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#41 +module Aws::S3::Errors + extend ::Aws::Errors::DynamicErrors +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#45 +class Aws::S3::Errors::BucketAlreadyExists < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::BucketAlreadyExists] + # @return [BucketAlreadyExists] a new instance of BucketAlreadyExists + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#50 + def initialize(context, message, data = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#55 +class Aws::S3::Errors::BucketAlreadyOwnedByYou < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::BucketAlreadyOwnedByYou] + # @return [BucketAlreadyOwnedByYou] a new instance of BucketAlreadyOwnedByYou + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#60 + def initialize(context, message, data = T.unsafe(nil)); end +end + +# Hijack PermanentRedirect (HeadBucket case - no body) dynamic error to +# include the region. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/customizations/errors.rb#28 +class Aws::S3::Errors::Http301Error < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param _data [Aws::S3::Types::PermanentRedirect] + # @return [Http301Error] a new instance of Http301Error + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/errors.rb#32 + def initialize(context, message, _data = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#65 +class Aws::S3::Errors::InvalidObjectState < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::InvalidObjectState] + # @return [InvalidObjectState] a new instance of InvalidObjectState + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#70 + def initialize(context, message, data = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#80 + def access_tier; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#75 + def storage_class; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#85 +class Aws::S3::Errors::NoSuchBucket < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::NoSuchBucket] + # @return [NoSuchBucket] a new instance of NoSuchBucket + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#90 + def initialize(context, message, data = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#95 +class Aws::S3::Errors::NoSuchKey < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::NoSuchKey] + # @return [NoSuchKey] a new instance of NoSuchKey + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#100 + def initialize(context, message, data = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#105 +class Aws::S3::Errors::NoSuchUpload < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::NoSuchUpload] + # @return [NoSuchUpload] a new instance of NoSuchUpload + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#110 + def initialize(context, message, data = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#115 +class Aws::S3::Errors::ObjectAlreadyInActiveTierError < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::ObjectAlreadyInActiveTierError] + # @return [ObjectAlreadyInActiveTierError] a new instance of ObjectAlreadyInActiveTierError + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#120 + def initialize(context, message, data = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#125 +class Aws::S3::Errors::ObjectNotInActiveTierError < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param data [Aws::S3::Types::ObjectNotInActiveTierError] + # @return [ObjectNotInActiveTierError] a new instance of ObjectNotInActiveTierError + # + # source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#130 + def initialize(context, message, data = T.unsafe(nil)); end +end + +# Hijack PermanentRedirect dynamic error to include the bucket, region, +# and endpoint. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/customizations/errors.rb#8 +class Aws::S3::Errors::PermanentRedirect < ::Aws::S3::Errors::ServiceError + # @param context [Seahorse::Client::RequestContext] + # @param message [String] + # @param _data [Aws::S3::Types::PermanentRedirect] + # @return [PermanentRedirect] a new instance of PermanentRedirect + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/errors.rb#12 + def initialize(context, message, _data = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/errors.rb#0 +class Aws::S3::Errors::ServiceError < ::Aws::Errors::ServiceError; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#11 +module Aws::S3::EventStreams; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#12 +class Aws::S3::EventStreams::SelectObjectContentEventStream + # @return [SelectObjectContentEventStream] a new instance of SelectObjectContentEventStream + # + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#14 + def initialize; end + + # @api private + # @return Aws::EventEmitter + # + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#63 + def event_emitter; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#30 + def on_cont_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#34 + def on_end_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#38 + def on_error_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#50 + def on_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#42 + def on_initial_response_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#26 + def on_progress_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#18 + def on_records_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#22 + def on_stats_event(&block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/event_streams.rb#46 + def on_unknown_event(&block); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials.rb#8 +class Aws::S3::ExpressCredentials + include ::Aws::CredentialProvider + include ::Aws::RefreshingCredentials + + # @api private + # @return [ExpressCredentials] a new instance of ExpressCredentials + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials.rb#15 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [S3::Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials.rb#28 + def client; end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials.rb#32 + def refresh; end + + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials.rb#45 + def create_session_options; end + end +end + +# 2 minutes +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials.rb#13 +Aws::S3::ExpressCredentials::ASYNC_EXPIRATION_LENGTH = T.let(T.unsafe(nil), Integer) + +# 1 minute +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials.rb#12 +Aws::S3::ExpressCredentials::SYNC_EXPIRATION_LENGTH = T.let(T.unsafe(nil), Integer) + +# Returns Credentials class for S3 Express. Accepts CreateSession +# params as options. See {Client#create_session} for details. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#12 +class Aws::S3::ExpressCredentialsProvider + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [ExpressCredentialsProvider] a new instance of ExpressCredentialsProvider + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#21 + def initialize(options = T.unsafe(nil)); end + + # Returns the value of attribute client. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#38 + def client; end + + # Sets the attribute client + # + # @param value the value to set the attribute client to. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#38 + def client=(_arg0); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#30 + def express_credentials_for(bucket); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#42 + def cached_credentials_for(bucket); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/express_credentials_provider.rb#50 + def new_credentials_for(bucket); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#11 +class Aws::S3::FileDownloader + # @api private + # @return [FileDownloader] a new instance of FileDownloader + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#17 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#22 + def client; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#24 + def download(destination, options = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#133 + def batches(chunks, mode); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#123 + def compute_chunk(file_size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#100 + def compute_mode(file_size, count); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#110 + def construct_chunks(file_size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#165 + def download_in_threads(pending, total_size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#80 + def multipart_download; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#158 + def multithreaded_get_by_parts(n_parts, total_size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#138 + def multithreaded_get_by_ranges(file_size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#218 + def single_part_progress; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#204 + def single_request; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#69 + def validate!; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#198 + def write(resp); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#14 +Aws::S3::FileDownloader::MAX_PARTS = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#13 +Aws::S3::FileDownloader::MIN_CHUNK_SIZE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#254 +class Aws::S3::FileDownloader::MultipartProgress + # @api private + # @return [MultipartProgress] a new instance of MultipartProgress + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#255 + def initialize(parts, total_size, progress_callback); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#262 + def call(part_number, bytes_received, total); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#224 +class Aws::S3::FileDownloader::Part < ::Struct + include ::Aws::Structure +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#229 +class Aws::S3::FileDownloader::PartList + include ::Enumerable + + # @api private + # @return [PartList] a new instance of PartList + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#231 + def initialize(parts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#244 + def clear!; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#248 + def each(&block); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#236 + def shift; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#240 + def size; end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_downloader.rb#15 +Aws::S3::FileDownloader::THREAD_COUNT = T.let(T.unsafe(nil), Integer) + +# A utility class that provides an IO-like interface to a portion of a file +# on disk. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#9 +class Aws::S3::FilePart + # @api private + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [FilePart] a new instance of FilePart + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#19 + def initialize(options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#52 + def close; end + + # @api private + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#31 + def first_byte; end + + # @api private + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#34 + def last_byte; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#39 + def read(bytes = T.unsafe(nil), output_buffer = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#44 + def rewind; end + + # @api private + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#37 + def size; end + + # @api private + # @return [String, Pathname, File, Tempfile] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#28 + def source; end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#58 + def open_file; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#63 + def read_from_file(bytes, output_buffer); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_part.rb#72 + def remaining_bytes; end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#8 +class Aws::S3::FileUploader + # @api private + # @option options + # @option options + # @param options [Hash] + # @return [FileUploader] a new instance of FileUploader + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#15 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#23 + def client; end + + # @api private + # @return [Integer] Files larger than or equal to this in bytes are uploaded + # using a {MultipartFileUploader}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#27 + def multipart_threshold; end + + # @api private + # @option options + # @option options + # @option options + # @option options + # @param source [String, Pathname, File, Tempfile] The file to upload. + # @param options [Hash] a customizable set of options + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#39 + def upload(source, options = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#53 + def open_file(source); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#61 + def put_object(source, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#70 + def single_part_progress(progress_callback); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/file_uploader.rb#10 +Aws::S3::FileUploader::ONE_HUNDRED_MEGABYTES = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-s3//lib/aws-sdk-s3.rb#76 +Aws::S3::GEM_VERSION = T.let(T.unsafe(nil), String) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#12 +class Aws::S3::LegacySigner + # @api private + # @param credentials [CredentialProvider] + # @return [LegacySigner] a new instance of LegacySigner + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#36 + def initialize(credentials, params, force_path_style); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#54 + def authorization(request); end + + # CanonicalizedAmzHeaders + # + # See the developer guide for more information on how this element + # is generated. + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#106 + def canonicalized_headers(request); end + + # From the S3 developer guide + # + # CanonicalizedResource = + # [ "/" ` Bucket ] ` + # + + # [ sub-resource, if present. e.g. "?acl", "?location", + # "?logging", or "?torrent"]; + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#123 + def canonicalized_resource(endpoint); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#45 + def credentials; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#64 + def digest(secret, string_to_sign); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#68 + def hmac(key, value); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#45 + def params; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#47 + def sign(request); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#58 + def signature(request); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#152 + def signed_querystring_params(endpoint); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#91 + def signing_string_date(request); end + + # From the S3 developer guide: + # + # StringToSign = + # HTTP-Verb ` "\n" ` + # content-md5 ` "\n" ` + # content-type ` "\n" ` + # date ` "\n" ` + # CanonicalizedAmzHeaders + CanonicalizedResource; + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#81 + def string_to_sign(request); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#158 + def uri_escape(s); end + + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#27 + def sign(context); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/legacy_signer.rb#14 +Aws::S3::LegacySigner::SIGNED_QUERYSTRING_PARAMS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#9 +class Aws::S3::MultipartFileUploader + # @api private + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [MultipartFileUploader] a new instance of MultipartFileUploader + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#35 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#41 + def client; end + + # @api private + # @option options + # @option options + # @option options + # @param source [String, Pathname, File, Tempfile] The file to upload. + # @param options [Hash] a customizable set of options + # @return [Seahorse::Client::Response] - the CompleteMultipartUploadResponse + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#50 + def upload(source, options = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#86 + def abort_upload(upload_id, options, errors); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#131 + def complete_opts(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#66 + def complete_upload(upload_id, parts, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#184 + def compute_default_part_size(source_size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#102 + def compute_parts(upload_id, source, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#124 + def create_opts(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#62 + def initiate_upload(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#188 + def part_size(total_size, part_size, offset); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#145 + def upload_in_threads(pending, completed, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#138 + def upload_part_opts(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#75 + def upload_parts(upload_id, source, options); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#24 +Aws::S3::MultipartFileUploader::COMPLETE_OPTIONS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#20 +Aws::S3::MultipartFileUploader::CREATE_OPTIONS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#13 +Aws::S3::MultipartFileUploader::FILE_TOO_SMALL = T.let(T.unsafe(nil), String) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#15 +Aws::S3::MultipartFileUploader::MAX_PARTS = T.let(T.unsafe(nil), Integer) + +# 5MB +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#11 +Aws::S3::MultipartFileUploader::MIN_PART_SIZE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#231 +class Aws::S3::MultipartFileUploader::MultipartProgress + # @api private + # @return [MultipartProgress] a new instance of MultipartProgress + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#232 + def initialize(parts, progress_callback); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#238 + def call(part_number, bytes_read); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#197 +class Aws::S3::MultipartFileUploader::PartList + # @api private + # @return [PartList] a new instance of PartList + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#199 + def initialize(parts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#212 + def clear!; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#220 + def part_sizes; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#204 + def push(part); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#208 + def shift; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#216 + def size; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#224 + def to_a; end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#17 +Aws::S3::MultipartFileUploader::THREAD_COUNT = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_file_uploader.rb#29 +Aws::S3::MultipartFileUploader::UPLOAD_PART_OPTIONS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#11 +class Aws::S3::MultipartStreamUploader + # @api private + # @option options + # @param options [Hash] a customizable set of options + # @return [MultipartStreamUploader] a new instance of MultipartStreamUploader + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#34 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#42 + def client; end + + # @api private + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Seahorse::Client::Response] - the CompleteMultipartUploadResponse + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#48 + def upload(options = T.unsafe(nil), &block); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#99 + def abort_upload(upload_id, options, errors); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#129 + def complete_opts(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#62 + def complete_upload(upload_id, parts, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#115 + def create_opts(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#58 + def initiate_upload(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#136 + def read_to_part_body(read_pipe); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#153 + def upload_in_threads(read_pipe, completed, options, thread_errors); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#122 + def upload_part_opts(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#71 + def upload_parts(upload_id, options, &block); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#30 +Aws::S3::MultipartStreamUploader::COMPLETE_UPLOAD_OPTIONS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#22 +Aws::S3::MultipartStreamUploader::CREATE_OPTIONS = T.let(T.unsafe(nil), Set) + +# api private +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#13 +Aws::S3::MultipartStreamUploader::PART_SIZE = T.let(T.unsafe(nil), Integer) + +# api private +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#19 +Aws::S3::MultipartStreamUploader::TEMPFILE_PREIX = T.let(T.unsafe(nil), String) + +# api private +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#16 +Aws::S3::MultipartStreamUploader::THREAD_COUNT = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_stream_uploader.rb#26 +Aws::S3::MultipartStreamUploader::UPLOAD_PART_OPTIONS = T.let(T.unsafe(nil), Set) + +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#12 +class Aws::S3::MultipartUpload + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [MultipartUpload] a new instance of MultipartUpload + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#26 + def initialize(*args); end + + # @example Request syntax with placeholder values + # + # multipart_upload.abort({ + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::AbortMultipartUploadOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#265 + def abort(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#406 + def basic_complete(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#39 + def bucket_name; end + + # The algorithm that was used to create a checksum of the object. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#102 + def checksum_algorithm; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#109 + def client; end + + # @example Request syntax with placeholder values + # + # object = multipart_upload.complete({ + # multipart_upload: { + # parts: [ + # { + # etag: "ETag", + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # part_number: 1, + # }, + # ], + # }, + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/multipart_upload.rb#27 + def complete(options = T.unsafe(nil)); end + + # @raise [NotImplementedError] Raises when {#data_loaded?} is `false`. + # @return [Types::MultipartUpload] Returns the data for this {MultipartUpload}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#124 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#132 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#545 + def deprecated_identifiers; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#49 + def id; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Date and time at which the multipart upload was initiated. + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#67 + def initiated; end + + # Identifies who initiated the multipart upload. + # + # @return [Types::Initiator] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#96 + def initiator; end + + # Key of the object for which the multipart upload was initiated. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#61 + def key; end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#115 + def load; end + + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#425 + def object; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#44 + def object_key; end + + # Specifies the owner of the object that is part of the multipart + # upload. + # + # **Directory buckets** - The bucket owner is returned as the object + # owner for all the objects. + # + # + # + # @return [Types::Owner] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#90 + def owner; end + + # @param part_number [String] + # @return [MultipartUploadPart] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#435 + def part(part_number); end + + # @example Request syntax with placeholder values + # + # parts = multipart_upload.parts({ + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [MultipartUploadPart::Collection] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#515 + def parts(options = T.unsafe(nil)); end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#115 + def reload; end + + # The class of storage used to store the object. + # + # **Directory buckets** - Only the S3 Express One Zone storage class is + # supported by directory buckets to store objects. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#78 + def storage_class; end + + # Upload ID that identifies the multipart upload. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#55 + def upload_id; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#216 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/multipart_upload.rb#36 + def compute_parts; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#556 + def extract_bucket_name(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#578 + def extract_id(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#567 + def extract_object_key(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload.rb#589 +class Aws::S3::MultipartUpload::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_error.rb#5 +class Aws::S3::MultipartUploadError < ::StandardError + # @return [MultipartUploadError] a new instance of MultipartUploadError + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_error.rb#7 + def initialize(message, errors); end + + # @return [Array] The list of errors encountered + # when uploading or aborting the upload. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_error.rb#14 + def errors; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#12 +class Aws::S3::MultipartUploadPart + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [MultipartUploadPart] a new instance of MultipartUploadPart + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#28 + def initialize(*args); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#42 + def bucket_name; end + + # This header can be used as a data integrity check to verify that the + # data received is the same data that was originally sent. This header + # specifies the base64-encoded, 32-bit CRC32 checksum of the object. For + # more information, see [Checking object integrity][1] in the *Amazon S3 + # User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#89 + def checksum_crc32; end + + # The base64-encoded, 32-bit CRC32C checksum of the object. This will + # only be present if it was uploaded with the object. When you use an + # API operation on an object that was uploaded using multipart uploads, + # this value may not be a direct checksum value of the full object. + # Instead, it's a calculation based on the checksum values of each + # individual part. For more information about how checksums are + # calculated with multipart uploads, see [ Checking object integrity][1] + # in the *Amazon S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#106 + def checksum_crc32c; end + + # The base64-encoded, 160-bit SHA-1 digest of the object. This will only + # be present if it was uploaded with the object. When you use the API + # operation on an object that was uploaded using multipart uploads, this + # value may not be a direct checksum value of the full object. Instead, + # it's a calculation based on the checksum values of each individual + # part. For more information about how checksums are calculated with + # multipart uploads, see [ Checking object integrity][1] in the *Amazon + # S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#123 + def checksum_sha1; end + + # This header can be used as a data integrity check to verify that the + # data received is the same data that was originally sent. This header + # specifies the base64-encoded, 256-bit SHA-256 digest of the object. + # For more information, see [Checking object integrity][1] in the + # *Amazon S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#137 + def checksum_sha256; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#144 + def client; end + + # @example Request syntax with placeholder values + # + # multipart_upload_part.copy_from({ + # copy_source: "CopySource", # required + # copy_source_if_match: "CopySourceIfMatch", + # copy_source_if_modified_since: Time.now, + # copy_source_if_none_match: "CopySourceIfNoneMatch", + # copy_source_if_unmodified_since: Time.now, + # copy_source_range: "CopySourceRange", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # copy_source_sse_customer_algorithm: "CopySourceSSECustomerAlgorithm", + # copy_source_sse_customer_key: "CopySourceSSECustomerKey", + # copy_source_sse_customer_key_md5: "CopySourceSSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # expected_source_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::UploadPartCopyOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#496 + def copy_from(options = T.unsafe(nil)); end + + # @raise [NotImplementedError] Raises when {#data_loaded?} is `false`. + # @return [Types::Part] Returns the data for this {MultipartUploadPart}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#159 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#167 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#673 + def deprecated_identifiers; end + + # Entity tag returned when the part was uploaded. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#69 + def etag; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Date and time at which the part was uploaded. + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#63 + def last_modified; end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#150 + def load; end + + # @return [MultipartUpload] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#662 + def multipart_upload; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#52 + def multipart_upload_id; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#47 + def object_key; end + + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#57 + def part_number; end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#150 + def reload; end + + # Size in bytes of the uploaded part data. + # + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#75 + def size; end + + # @example Request syntax with placeholder values + # + # multipart_upload_part.upload({ + # body: source_file, + # content_length: 1, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::UploadPartOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#646 + def upload(options = T.unsafe(nil)); end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#251 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#685 + def extract_bucket_name(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#707 + def extract_multipart_upload_id(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#696 + def extract_object_key(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#718 + def extract_part_number(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/multipart_upload_part.rb#729 +class Aws::S3::MultipartUploadPart::Collection < ::Aws::Resources::Collection; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#12 +class Aws::S3::Object + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [Object] a new instance of Object + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#24 + def initialize(*args); end + + # Indicates that a range of bytes was specified. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#59 + def accept_ranges; end + + # @return [ObjectAcl] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2966 + def acl; end + + # The archive state of the head object. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#119 + def archive_status; end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2975 + def bucket; end + + # Indicates whether the object uses an S3 Bucket Key for server-side + # encryption with Key Management Service (KMS) keys (SSE-KMS). + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#351 + def bucket_key_enabled; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#36 + def bucket_name; end + + # Specifies caching behavior along the request/reply chain. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#236 + def cache_control; end + + # The base64-encoded, 32-bit CRC32 checksum of the object. This will + # only be present if it was uploaded with the object. When you use an + # API operation on an object that was uploaded using multipart uploads, + # this value may not be a direct checksum value of the full object. + # Instead, it's a calculation based on the checksum values of each + # individual part. For more information about how checksums are + # calculated with multipart uploads, see [ Checking object integrity][1] + # in the *Amazon S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#148 + def checksum_crc32; end + + # The base64-encoded, 32-bit CRC32C checksum of the object. This will + # only be present if it was uploaded with the object. When you use an + # API operation on an object that was uploaded using multipart uploads, + # this value may not be a direct checksum value of the full object. + # Instead, it's a calculation based on the checksum values of each + # individual part. For more information about how checksums are + # calculated with multipart uploads, see [ Checking object integrity][1] + # in the *Amazon S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#165 + def checksum_crc32c; end + + # The base64-encoded, 160-bit SHA-1 digest of the object. This will only + # be present if it was uploaded with the object. When you use the API + # operation on an object that was uploaded using multipart uploads, this + # value may not be a direct checksum value of the full object. Instead, + # it's a calculation based on the checksum values of each individual + # part. For more information about how checksums are calculated with + # multipart uploads, see [ Checking object integrity][1] in the *Amazon + # S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#182 + def checksum_sha1; end + + # The base64-encoded, 256-bit SHA-256 digest of the object. This will + # only be present if it was uploaded with the object. When you use an + # API operation on an object that was uploaded using multipart uploads, + # this value may not be a direct checksum value of the full object. + # Instead, it's a calculation based on the checksum values of each + # individual part. For more information about how checksums are + # calculated with multipart uploads, see [ Checking object integrity][1] + # in the *Amazon S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#199 + def checksum_sha256; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#492 + def client; end + + # Specifies presentational information for the object. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#242 + def content_disposition; end + + # Indicates what content encodings have been applied to the object and + # thus what decoding mechanisms must be applied to obtain the media-type + # referenced by the Content-Type header field. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#250 + def content_encoding; end + + # The language the content is in. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#256 + def content_language; end + + # Size of the body in bytes. + # + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#131 + def content_length; end + + # A standard MIME type describing the format of the object data. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#262 + def content_type; end + + # @example Request syntax with placeholder values + # + # object.copy_from({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # cache_control: "CacheControl", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_type: "ContentType", + # copy_source: "CopySource", # required + # copy_source_if_match: "CopySourceIfMatch", + # copy_source_if_modified_since: Time.now, + # copy_source_if_none_match: "CopySourceIfNoneMatch", + # copy_source_if_unmodified_since: Time.now, + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # metadata_directive: "COPY", # accepts COPY, REPLACE + # tagging_directive: "COPY", # accepts COPY, REPLACE + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # copy_source_sse_customer_algorithm: "CopySourceSSECustomerAlgorithm", + # copy_source_sse_customer_key: "CopySourceSSECustomerKey", + # copy_source_sse_customer_key_md5: "CopySourceSSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # expected_source_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::CopyObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#78 + def copy_from(source, options = T.unsafe(nil)); end + + # Copies this object to another object. Use `multipart_copy: true` + # for large objects. This is required for objects that exceed 5GB. + # + # @example Basic object copy + # + # bucket = Aws::S3::Bucket.new('source-bucket') + # object = bucket.object('source-key') + # + # # target as String + # object.copy_to('target-bucket/target-key') + # + # # target as Hash + # object.copy_to(bucket: 'target-bucket', key: 'target-key') + # + # # target as Aws::S3::Object + # object.copy_to(bucket.object('target-key')) + # @example Managed copy of large objects + # + # # uses multipart upload APIs to copy object + # object.copy_to('src-bucket/src-key', multipart_copy: true) + # @note If you need to copy to a bucket in a different region, use + # {#copy_from}. + # @param target [S3::Object, String, Hash] Where to copy the object + # data to. `target` must be one of the following: + # + # * {Aws::S3::Object} + # * Hash - with `:bucket` and `:key` + # * String - formatted like `"target-bucket-name/target-key"` + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#121 + def copy_to(target, options = T.unsafe(nil)); end + + # @return [Types::HeadObjectOutput] Returns the data for this {Object}. Calls + # {Client#head_object} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#517 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#525 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # object.delete({ + # mfa: "MFA", + # version_id: "ObjectVersionId", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::DeleteObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#1410 + def delete(options = T.unsafe(nil)); end + + # Specifies whether the object retrieved was (true) or was not (false) a + # Delete Marker. If false, this response header does not appear in the + # response. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#53 + def delete_marker; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3006 + def deprecated_identifiers; end + + # Downloads a file in S3 to a path on disk. + # + # # small files (< 5MB) are downloaded in a single API call + # obj.download_file('/path/to/file') + # + # Files larger than 5MB are downloaded using multipart method + # + # # large files are split into parts + # # and the parts are downloaded in parallel + # obj.download_file('/path/to/very_large_file') + # + # You can provide a callback to monitor progress of the download: + # + # # bytes and part_sizes are each an array with 1 entry per part + # # part_sizes may not be known until the first bytes are retrieved + # progress = Proc.new do |bytes, part_sizes, file_size| + # puts bytes.map.with_index { |b, i| "Part #{i+1}: #{b} / #{part_sizes[i]}"}.join(' ') + "Total: #{100.0 * bytes.sum / file_size}%" } + # end + # obj.download_file('/path/to/file', progress_callback: progress) + # + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param destination [String] Where to download the file to. + # @param options [Hash] Additional options for {Client#get_object} and #{Client#head_object} + # may be provided. + # @return [Boolean] Returns `true` when the file is downloaded without + # any errors. + # @see Client#get_object + # @see Client#head_object + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#552 + def download_file(destination, options = T.unsafe(nil)); end + + # An entity tag (ETag) is an opaque identifier assigned by a web server + # to a specific version of a resource found at a URL. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#206 + def etag; end + + # @param options [Hash] ({}) + # @return [Boolean] Returns `true` if the Object exists. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#532 + def exists?(options = T.unsafe(nil)); end + + # If the object expiration is configured (see [ + # `PutBucketLifecycleConfiguration` ][1]), the response includes this + # header. It includes the `expiry-date` and `rule-id` key-value pairs + # providing object expiration information. The value of the `rule-id` is + # URL-encoded. + # + # This functionality is not supported for directory buckets. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#77 + def expiration; end + + # The date and time at which the object is no longer cacheable. + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#268 + def expires; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#273 + def expires_string; end + + # @example Request syntax with placeholder values + # + # object.get({ + # if_match: "IfMatch", + # if_modified_since: Time.now, + # if_none_match: "IfNoneMatch", + # if_unmodified_since: Time.now, + # range: "Range", + # response_cache_control: "ResponseCacheControl", + # response_content_disposition: "ResponseContentDisposition", + # response_content_encoding: "ResponseContentEncoding", + # response_content_language: "ResponseContentLanguage", + # response_content_type: "ResponseContentType", + # response_expires: Time.now, + # version_id: "ObjectVersionId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # part_number: 1, + # expected_bucket_owner: "AccountId", + # checksum_mode: "ENABLED", # accepts ENABLED + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::GetObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#1666 + def get(options = T.unsafe(nil), &block); end + + # @example Request syntax with placeholder values + # + # object.head({ + # if_match: "IfMatch", + # if_modified_since: Time.now, + # if_none_match: "IfNoneMatch", + # if_unmodified_since: Time.now, + # range: "Range", + # response_cache_control: "ResponseCacheControl", + # response_content_disposition: "ResponseContentDisposition", + # response_content_encoding: "ResponseContentEncoding", + # response_content_language: "ResponseContentLanguage", + # response_content_type: "ResponseContentType", + # response_expires: Time.now, + # version_id: "ObjectVersionId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # part_number: 1, + # expected_bucket_owner: "AccountId", + # checksum_mode: "ENABLED", # accepts ENABLED + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::HeadObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2952 + def head(options = T.unsafe(nil)); end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # @example Request syntax with placeholder values + # + # multipartupload = object.initiate_multipart_upload({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_type: "ContentType", + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [MultipartUpload] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2151 + def initiate_multipart_upload(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#41 + def key; end + + # Date and time when the object was last modified. + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#125 + def last_modified; end + + # Loads, or reloads {#data} for the current {Object}. + # Returns `self` making it possible to chain methods. + # + # object.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#502 + def load; end + + # A map of metadata to store with the object in S3. + # + # @return [Hash] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#303 + def metadata; end + + # This is set to the number of metadata entries not returned in + # `x-amz-meta` headers. This can happen if you create metadata using an + # API like SOAP that supports more flexible metadata than the REST API. + # For example, using SOAP, you can create metadata whose values are not + # legal HTTP headers. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#220 + def missing_meta; end + + # Copies and deletes the current object. The object will only be deleted + # if the copy operation succeeds. + # + # @param target [S3::Object, String, Hash] Where to copy the object + # data to. `target` must be one of the following: + # + # * {Aws::S3::Object} + # * Hash - with `:bucket` and `:key` + # * String - formatted like `"target-bucket-name/target-key"` + # @return [void] + # @see Object#copy_to + # @see Object#delete + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#135 + def move_to(target, options = T.unsafe(nil)); end + + # @param id [String] + # @return [MultipartUpload] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2984 + def multipart_upload(id); end + + # Specifies whether a legal hold is in effect for this object. This + # header is only returned if the requester has the + # `s3:GetObjectLegalHold` permission. This header is not returned if the + # specified version of this object has never had a legal hold applied. + # For more information about S3 Object Lock, see [Object Lock][1]. + # + # This functionality is not supported for directory buckets. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#485 + def object_lock_legal_hold_status; end + + # The Object Lock mode, if any, that's in effect for this object. This + # header is only returned if the requester has the + # `s3:GetObjectRetention` permission. For more information about S3 + # Object Lock, see [Object Lock][1]. + # + # This functionality is not supported for directory buckets. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#455 + def object_lock_mode; end + + # The date and time when the Object Lock retention period expires. This + # header is only returned if the requester has the + # `s3:GetObjectRetention` permission. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#467 + def object_lock_retain_until_date; end + + # The count of parts this object has. This value is only returned if you + # specify `partNumber` in your request and the object was uploaded as a + # multipart upload. + # + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#438 + def parts_count; end + + # Creates a {PresignedPost} that makes it easy to upload a file from + # a web browser direct to Amazon S3 using an HTML post form with + # a file field. + # + # See the {PresignedPost} documentation for more information. + # + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @return [PresignedPost] + # @see PresignedPost + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#149 + def presigned_post(options = T.unsafe(nil)); end + + # Allows you to create presigned URL requests for S3 operations. This + # method returns a tuple containing the URL and the signed X-amz-* headers + # to be used with the presigned url. + # + # @example Pre-signed GET URL, valid for one hour + # + # obj.presigned_request(:get, expires_in: 3600) + # #=> ["https://bucket-name.s3.amazonaws.com/object-key?...", {}] + # @example Pre-signed PUT with a canned ACL + # + # # the object uploaded using this URL will be publicly accessible + # obj.presigned_request(:put, acl: 'public-read') + # #=> ["https://bucket-name.s3.amazonaws.com/object-key?...", + # {"x-amz-acl"=>"public-read"}] + # @option params + # @option params + # @param method [Symbol] The S3 operation to generate a presigned request for. Valid values + # are `:get`, `:put`, `:head`, `:delete`, `:create_multipart_upload`, + # `:list_multipart_uploads`, `:complete_multipart_upload`, + # `:abort_multipart_upload`, `:list_parts`, and `:upload_part`. + # @param params [Hash] Additional request parameters to use when generating the pre-signed + # request. See the related documentation in {Client} for accepted + # params. + # + # | Method | Client Method | + # |------------------------------|------------------------------------| + # | `:get` | {Client#get_object} | + # | `:put` | {Client#put_object} | + # | `:head` | {Client#head_object} | + # | `:delete` | {Client#delete_object} | + # | `:create_multipart_upload` | {Client#create_multipart_upload} | + # | `:list_multipart_uploads` | {Client#list_multipart_uploads} | + # | `:complete_multipart_upload` | {Client#complete_multipart_upload} | + # | `:abort_multipart_upload` | {Client#abort_multipart_upload} | + # | `:list_parts` | {Client#list_parts} | + # | `:upload_part` | {Client#upload_part} | + # @raise [ArgumentError] Raised if `:expires_in` exceeds one week + # (604800 seconds). + # @return [String, Hash] A tuple with a presigned URL and headers that + # should be included with the request. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#293 + def presigned_request(method, params = T.unsafe(nil)); end + + # Generates a pre-signed URL for this object. + # + # @example Pre-signed GET URL, valid for one hour + # + # obj.presigned_url(:get, expires_in: 3600) + # #=> "https://bucket-name.s3.amazonaws.com/object-key?..." + # @example Pre-signed PUT with a canned ACL + # + # # the object uploaded using this URL will be publicly accessible + # obj.presigned_url(:put, acl: 'public-read') + # #=> "https://bucket-name.s3.amazonaws.com/object-key?..." + # @example Pre-signed UploadPart PUT + # + # # the object uploaded using this URL will be publicly accessible + # obj.presigned_url(:upload_part, part_number: 1, upload_id: 'uploadIdToken') + # #=> "https://bucket-name.s3.amazonaws.com/object-key?..." + # @option params + # @option params + # @param method [Symbol] The S3 operation to generate a presigned URL for. Valid values + # are `:get`, `:put`, `:head`, `:delete`, `:create_multipart_upload`, + # `:list_multipart_uploads`, `:complete_multipart_upload`, + # `:abort_multipart_upload`, `:list_parts`, and `:upload_part`. + # @param params [Hash] Additional request parameters to use when generating the pre-signed + # URL. See the related documentation in {Client} for accepted + # params. + # + # | Method | Client Method | + # |------------------------------|------------------------------------| + # | `:get` | {Client#get_object} | + # | `:put` | {Client#put_object} | + # | `:head` | {Client#head_object} | + # | `:delete` | {Client#delete_object} | + # | `:create_multipart_upload` | {Client#create_multipart_upload} | + # | `:list_multipart_uploads` | {Client#list_multipart_uploads} | + # | `:complete_multipart_upload` | {Client#complete_multipart_upload} | + # | `:abort_multipart_upload` | {Client#abort_multipart_upload} | + # | `:list_parts` | {Client#list_parts} | + # | `:upload_part` | {Client#upload_part} | + # @raise [ArgumentError] Raised if `:expires_in` exceeds one week + # (604800 seconds). + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#220 + def presigned_url(method, params = T.unsafe(nil)); end + + # Returns the public (un-signed) URL for this object. + # + # s3.bucket('bucket-name').object('obj-key').public_url + # #=> "https://bucket-name.s3.amazonaws.com/obj-key" + # + # To use virtual hosted bucket url. + # Uses https unless secure: false is set. If the bucket + # name contains dots (.) then you will need to set secure: false. + # + # s3.bucket('my-bucket.com').object('key') + # .public_url(virtual_host: true) + # #=> "https://my-bucket.com/key" + # + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#328 + def public_url(options = T.unsafe(nil)); end + + # @example Request syntax with placeholder values + # + # object.put({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # body: source_file, + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_length: 1, + # content_md5: "ContentMD5", + # content_type: "ContentType", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::PutObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2622 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {Object}. + # Returns `self` making it possible to chain methods. + # + # object.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#502 + def reload; end + + # Amazon S3 can return this header if your request involves a bucket + # that is either a source or a destination in a replication rule. + # + # In replication, you have a source bucket on which you configure + # replication and destination bucket or buckets where Amazon S3 stores + # object replicas. When you request an object (`GetObject`) or object + # metadata (`HeadObject`) from these buckets, Amazon S3 will return the + # `x-amz-replication-status` header in the response as follows: + # + # * **If requesting an object from the source bucket**, Amazon S3 will + # return the `x-amz-replication-status` header if the object in your + # request is eligible for replication. + # + # For example, suppose that in your replication configuration, you + # specify object prefix `TaxDocs` requesting Amazon S3 to replicate + # objects with key prefix `TaxDocs`. Any objects you upload with this + # key name prefix, for example `TaxDocs/document1.pdf`, are eligible + # for replication. For any object request with this key name prefix, + # Amazon S3 will return the `x-amz-replication-status` header with + # value PENDING, COMPLETED or FAILED indicating object replication + # status. + # + # * **If requesting an object from a destination bucket**, Amazon S3 + # will return the `x-amz-replication-status` header with value REPLICA + # if the object in your request is a replica that Amazon S3 created + # and there is no replica modification replication in progress. + # + # * **When replicating objects to multiple destination buckets**, the + # `x-amz-replication-status` header acts differently. The header of + # the source object will only return a value of COMPLETED when + # replication is successful to all destinations. The header will + # remain at value PENDING until replication has completed for all + # destinations. If one or more destinations fails replication the + # header will return FAILED. + # + # For more information, see [Replication][1]. + # + # This functionality is not supported for directory buckets. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#430 + def replication_status; end + + # If present, indicates that the requester was successfully charged for + # the request. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#381 + def request_charged; end + + # If the object is an archived object (an object whose storage class is + # GLACIER), the response includes this header if either the archive + # restoration is in progress (see [RestoreObject][1] or an archive copy + # is already restored. + # + # If an archive copy is already restored, the header value indicates + # when Amazon S3 is scheduled to delete the object copy. For example: + # + # `x-amz-restore: ongoing-request="false", expiry-date="Fri, 21 Dec 2012 + # 00:00:00 GMT"` + # + # If the object restoration is in progress, the header returns the value + # `ongoing-request="true"`. + # + # For more information about archiving objects, see [Transitioning + # Objects: General Considerations][2]. + # + # This functionality is not supported for directory buckets. Only the S3 + # Express One Zone storage class is supported by directory buckets to + # store objects. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html + # [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html#lifecycle-transition-general-considerations + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#109 + def restore; end + + # @example Request syntax with placeholder values + # + # object.restore_object({ + # version_id: "ObjectVersionId", + # restore_request: { + # days: 1, + # glacier_job_parameters: { + # tier: "Standard", # required, accepts Standard, Bulk, Expedited + # }, + # type: "SELECT", # accepts SELECT + # tier: "Standard", # accepts Standard, Bulk, Expedited + # description: "Description", + # select_parameters: { + # input_serialization: { # required + # csv: { + # file_header_info: "USE", # accepts USE, IGNORE, NONE + # comments: "Comments", + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # allow_quoted_record_delimiter: false, + # }, + # compression_type: "NONE", # accepts NONE, GZIP, BZIP2 + # json: { + # type: "DOCUMENT", # accepts DOCUMENT, LINES + # }, + # parquet: { + # }, + # }, + # expression_type: "SQL", # required, accepts SQL + # expression: "Expression", # required + # output_serialization: { # required + # csv: { + # quote_fields: "ALWAYS", # accepts ALWAYS, ASNEEDED + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # }, + # json: { + # record_delimiter: "RecordDelimiter", + # }, + # }, + # }, + # output_location: { + # s3: { + # bucket_name: "BucketName", # required + # prefix: "LocationPrefix", # required + # encryption: { + # encryption_type: "AES256", # required, accepts AES256, aws:kms, aws:kms:dsse + # kms_key_id: "SSEKMSKeyId", + # kms_context: "KMSContext", + # }, + # canned_acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # access_control_list: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, WRITE, WRITE_ACP, READ, READ_ACP + # }, + # ], + # tagging: { + # tag_set: [ # required + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # user_metadata: [ + # { + # name: "MetadataKey", + # value: "MetadataValue", + # }, + # ], + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # }, + # }, + # }, + # request_payer: "requester", # accepts requester + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::RestoreObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2763 + def restore_object(options = T.unsafe(nil)); end + + # The server-side encryption algorithm used when you store this object + # in Amazon S3 (for example, `AES256`, `aws:kms`, `aws:kms:dsse`). + # + # For directory buckets, only server-side encryption with Amazon S3 + # managed keys (SSE-S3) (`AES256`) is supported. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#297 + def server_side_encryption; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#131 + def size; end + + # If server-side encryption with a customer-provided encryption key was + # requested, the response will include this header to confirm the + # encryption algorithm that's used. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#315 + def sse_customer_algorithm; end + + # If server-side encryption with a customer-provided encryption key was + # requested, the response will include this header to provide the + # round-trip message integrity verification of the customer-provided + # encryption key. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#328 + def sse_customer_key_md5; end + + # If present, indicates the ID of the Key Management Service (KMS) + # symmetric encryption customer managed key that was used for the + # object. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#340 + def ssekms_key_id; end + + # Provides storage class information of the object. Amazon S3 returns + # this header for all objects except for S3 Standard storage class + # objects. + # + # For more information, see [Storage Classes][1]. + # + # Directory buckets - Only the S3 Express One Zone storage class + # is supported by directory buckets to store objects. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#370 + def storage_class; end + + # Uploads a file from disk to the current object in S3. + # + # # small files are uploaded in a single API call + # obj.upload_file('/path/to/file') + # + # Files larger than or equal to `:multipart_threshold` are uploaded + # using the Amazon S3 multipart upload APIs. + # + # # large files are automatically split into parts + # # and the parts are uploaded in parallel + # obj.upload_file('/path/to/very_large_file') + # + # The response of the S3 upload API is yielded if a block given. + # + # # API response will have etag value of the file + # obj.upload_file('/path/to/file') do |response| + # etag = response.etag + # end + # + # You can provide a callback to monitor progress of the upload: + # + # # bytes and totals are each an array with 1 entry per part + # progress = Proc.new do |bytes, totals| + # puts bytes.map.with_index { |b, i| "Part #{i+1}: #{b} / #{totals[i]}"}.join(' ') + "Total: #{100.0 * bytes.sum / totals.sum }%" } + # end + # obj.upload_file('/path/to/file', progress_callback: progress) + # + # @option options + # @option options + # @option options + # @param source [String, Pathname, File, Tempfile] A file on the local + # file system that will be uploaded as this object. This can either be + # a String or Pathname to the file, an open File object, or an open + # Tempfile object. If you pass an open File or Tempfile object, then + # you are responsible for closing it after the upload completes. When + # using an open Tempfile, rewind it before uploading or else the object + # will be empty. + # @param options [Hash] Additional options for {Client#put_object} + # when file sizes below the multipart threshold. For files larger than + # the multipart threshold, options for {Client#create_multipart_upload}, + # {Client#complete_multipart_upload}, + # and {Client#upload_part} can be provided. + # @raise [MultipartUploadError] If an object is being uploaded in + # parts, and the upload can not be completed, then the upload is + # aborted and this error is raised. The raised error has a `#errors` + # method that returns the failures that caused the upload to be + # aborted. + # @return [Boolean] Returns `true` when the object is uploaded + # without any errors. + # @see Client#put_object + # @see Client#create_multipart_upload + # @see Client#complete_multipart_upload + # @see Client#upload_part + # @yield [response] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#470 + def upload_file(source, options = T.unsafe(nil)); end + + # Uploads a stream in a streaming fashion to the current object in S3. + # + # Passed chunks automatically split into multipart upload parts and the + # parts are uploaded in parallel. This allows for streaming uploads that + # never touch the disk. + # + # Note that this is known to have issues in JRuby until jruby-9.1.15.0, + # so avoid using this with older versions of JRuby. + # + # @example Streaming chunks of data + # obj.upload_stream do |write_stream| + # 10.times { write_stream << 'foo' } + # end + # @example Streaming chunks of data + # obj.upload_stream do |write_stream| + # IO.copy_stream(IO.popen('ls'), write_stream) + # end + # @example Streaming chunks of data + # obj.upload_stream do |write_stream| + # IO.copy_stream(STDIN, write_stream) + # end + # @option options + # @option options + # @option options + # @param options [Hash] Additional options for {Client#create_multipart_upload}, + # {Client#complete_multipart_upload}, + # and {Client#upload_part} can be provided. + # @raise [MultipartUploadError] If an object is being uploaded in + # parts, and the upload can not be completed, then the upload is + # aborted and this error is raised. The raised error has a `#errors` + # method that returns the failures that caused the upload to be + # aborted. + # @return [Boolean] Returns `true` when the object is uploaded + # without any errors. + # @see Client#create_multipart_upload + # @see Client#complete_multipart_upload + # @see Client#upload_part + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object.rb#385 + def upload_stream(options = T.unsafe(nil), &block); end + + # @param id [String] + # @return [ObjectVersion] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#2995 + def version(id); end + + # Version ID of the object. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#230 + def version_id; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#665 + def wait_until(options = T.unsafe(nil), &block); end + + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#549 + def wait_until_exists(options = T.unsafe(nil), &block); end + + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#570 + def wait_until_not_exists(options = T.unsafe(nil), &block); end + + # If the bucket is configured as a website, redirects requests for this + # object to another object in the same bucket or to an external URL. + # Amazon S3 stores the value of this header in the object metadata. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#285 + def website_redirect_location; end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3016 + def extract_bucket_name(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3027 + def extract_key(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3048 + def separate_params_and_options(options); end + + # @yield [waiter.waiter] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3038 + def yield_waiter_and_warn(waiter, &block); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3065 +class Aws::S3::Object::Collection < ::Aws::Resources::Collection + # @example Request syntax with placeholder values + # + # object.batch_delete!({ + # mfa: "MFA", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [{}] + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3164 + def batch_delete!(options = T.unsafe(nil)); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def delete(*args, &block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object.rb#3164 + def deprecated_delete(options = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#12 +class Aws::S3::ObjectAcl + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [ObjectAcl] a new instance of ObjectAcl + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#24 + def initialize(*args); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#36 + def bucket_name; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#71 + def client; end + + # @return [Types::GetObjectAclOutput] Returns the data for this {ObjectAcl}. Calls + # {Client#get_object_acl} if {#data_loaded?} is `false`. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#96 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#104 + def data_loaded?; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#354 + def deprecated_identifiers; end + + # A list of grants. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#53 + def grants; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Loads, or reloads {#data} for the current {ObjectAcl}. + # Returns `self` making it possible to chain methods. + # + # object_acl.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#81 + def load; end + + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#344 + def object; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#41 + def object_key; end + + # Container for the bucket owner's display name and ID. + # + # @return [Types::Owner] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#47 + def owner; end + + # @example Request syntax with placeholder values + # + # object_acl.put({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # access_control_policy: { + # grants: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, WRITE, WRITE_ACP, READ, READ_ACP + # }, + # ], + # owner: { + # display_name: "DisplayName", + # id: "ID", + # }, + # }, + # content_md5: "ContentMD5", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write: "GrantWrite", + # grant_write_acp: "GrantWriteACP", + # request_payer: "requester", # accepts requester + # version_id: "ObjectVersionId", + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::PutObjectAclOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#330 + def put(options = T.unsafe(nil)); end + + # Loads, or reloads {#data} for the current {ObjectAcl}. + # Returns `self` making it possible to chain methods. + # + # object_acl.reload.data + # + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#81 + def reload; end + + # If present, indicates that the requester was successfully charged for + # the request. + # + # This functionality is not supported for directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#64 + def request_charged; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#188 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#364 + def extract_bucket_name(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#375 + def extract_object_key(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object_acl.rb#386 +class Aws::S3::ObjectAcl::Collection < ::Aws::Resources::Collection; end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#8 +class Aws::S3::ObjectCopier + # @api private + # @param object [S3::Object] + # @return [ObjectCopier] a new instance of ObjectCopier + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#11 + def initialize(object, options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#16 + def copy_from(source, options = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#20 + def copy_to(target, options = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#80 + def apply_source_client(source, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#26 + def copy_object(source, target, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#41 + def copy_source(source); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#58 + def copy_target(target); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#97 + def escape(str); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_copier.rb#69 + def merge_options(source_or_target, options); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#9 +class Aws::S3::ObjectMultipartCopier + # @api private + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [ObjectMultipartCopier] a new instance of ObjectMultipartCopier + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#28 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#36 + def client; end + + # @api private + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param params [Hash] a customizable set of options + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#39 + def copy(options = T.unsafe(nil)); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#95 + def abort_upload(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#120 + def byte_range(offset, part_size, size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#128 + def calculate_part_size(part_number, default_part_size, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#89 + def complete_upload(parts, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#103 + def compute_parts(size, default_part_size, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#83 + def copy_part(part); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#68 + def copy_part_thread(queue); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#59 + def copy_parts(size, default_part_size, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#162 + def default_part_size(source_size); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#54 + def initiate_upload(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#170 + def options_for(operation_name, options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#136 + def source_has_parts(options); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#140 + def source_metadata(options); end + + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#178 + def options_for(shape_name); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#182 +Aws::S3::ObjectMultipartCopier::API_OPTIONS = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#13 +Aws::S3::ObjectMultipartCopier::FILE_TOO_SMALL = T.let(T.unsafe(nil), String) + +# 5MB +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#11 +Aws::S3::ObjectMultipartCopier::FIVE_MB = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#15 +Aws::S3::ObjectMultipartCopier::MAX_PARTS = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#188 +class Aws::S3::ObjectMultipartCopier::PartQueue + # @api private + # @return [PartQueue] a new instance of PartQueue + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#190 + def initialize(parts = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#199 + def clear!; end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_multipart_copier.rb#195 + def shift; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#12 +class Aws::S3::ObjectSummary + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [ObjectSummary] a new instance of ObjectSummary + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#24 + def initialize(*args); end + + # @return [ObjectAcl] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2413 + def acl; end + + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2422 + def bucket; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#36 + def bucket_name; end + + # The algorithm that was used to create a checksum of the object. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#83 + def checksum_algorithm; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#138 + def client; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#89 + def content_length; end + + # @example Request syntax with placeholder values + # + # object_summary.copy_from({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # cache_control: "CacheControl", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_type: "ContentType", + # copy_source: "CopySource", # required + # copy_source_if_match: "CopySourceIfMatch", + # copy_source_if_modified_since: Time.now, + # copy_source_if_none_match: "CopySourceIfNoneMatch", + # copy_source_if_unmodified_since: Time.now, + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # metadata_directive: "COPY", # accepts COPY, REPLACE + # tagging_directive: "COPY", # accepts COPY, REPLACE + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # copy_source_sse_customer_algorithm: "CopySourceSSECustomerAlgorithm", + # copy_source_sse_customer_key: "CopySourceSSECustomerKey", + # copy_source_sse_customer_key_md5: "CopySourceSSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # expected_source_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::CopyObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#16 + def copy_from(source, options = T.unsafe(nil)); end + + # @param target [S3::Object, String, Hash] Where to copy the object + # data to. `target` must be one of the following: + # + # * {Aws::S3::Object} + # * Hash - with `:bucket` and `:key` + # * String - formatted like `"target-bucket-name/target-key"` + # @see Object#copy_to + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#24 + def copy_to(target, options = T.unsafe(nil)); end + + # @raise [NotImplementedError] Raises when {#data_loaded?} is `false`. + # @return [Types::Object] Returns the data for this {ObjectSummary}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#153 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#161 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # object_summary.delete({ + # mfa: "MFA", + # version_id: "ObjectVersionId", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::DeleteObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#1046 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2462 + def deprecated_identifiers; end + + # @param destination [String] Where to download the file to. + # @param options [Hash] Additional options for {Client#get_object} and #{Client#head_object} + # may be provided. + # @return [Boolean] Returns `true` when the file is downloaded without + # any errors. + # @see Object#download_file + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#79 + def download_file(destination, options = T.unsafe(nil)); end + + # The entity tag is a hash of the object. The ETag reflects changes only + # to the contents of an object, not its metadata. The ETag may or may + # not be an MD5 digest of the object data. Whether or not it is depends + # on how the object was created and how it is encrypted as described + # below: + # + # * Objects created by the PUT Object, POST Object, or Copy operation, + # or through the Amazon Web Services Management Console, and are + # encrypted by SSE-S3 or plaintext, have ETags that are an MD5 digest + # of their object data. + # + # * Objects created by the PUT Object, POST Object, or Copy operation, + # or through the Amazon Web Services Management Console, and are + # encrypted by SSE-C or SSE-KMS, have ETags that are not an MD5 digest + # of their object data. + # + # * If an object is created by either the Multipart Upload or Part Copy + # operation, the ETag is not an MD5 digest, regardless of the method + # of encryption. If an object is larger than 16 MB, the Amazon Web + # Services Management Console will upload or copy that object as a + # Multipart Upload, and therefore the ETag will not be an MD5 digest. + # + # **Directory buckets** - MD5 is not supported by directory buckets. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#77 + def etag; end + + # @param options [Hash] ({}) + # @return [Boolean] Returns `true` if the ObjectSummary exists. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#168 + def exists?(options = T.unsafe(nil)); end + + # @example Request syntax with placeholder values + # + # object_summary.get({ + # if_match: "IfMatch", + # if_modified_since: Time.now, + # if_none_match: "IfNoneMatch", + # if_unmodified_since: Time.now, + # range: "Range", + # response_cache_control: "ResponseCacheControl", + # response_content_disposition: "ResponseContentDisposition", + # response_content_encoding: "ResponseContentEncoding", + # response_content_language: "ResponseContentLanguage", + # response_content_type: "ResponseContentType", + # response_expires: Time.now, + # version_id: "ObjectVersionId", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # part_number: 1, + # expected_bucket_owner: "AccountId", + # checksum_mode: "ENABLED", # accepts ENABLED + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::GetObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#1302 + def get(options = T.unsafe(nil), &block); end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # @example Request syntax with placeholder values + # + # multipartupload = object_summary.initiate_multipart_upload({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_type: "ContentType", + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [MultipartUpload] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#1787 + def initiate_multipart_upload(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#41 + def key; end + + # Creation date of the object. + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#47 + def last_modified; end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#144 + def load; end + + # @param target [S3::Object, String, Hash] Where to copy the object + # data to. `target` must be one of the following: + # + # * {Aws::S3::Object} + # * Hash - with `:bucket` and `:key` + # * String - formatted like `"target-bucket-name/target-key"` + # @return [void] + # @see Object#move_to + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#32 + def move_to(target, options = T.unsafe(nil)); end + + # @param id [String] + # @return [MultipartUpload] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2431 + def multipart_upload(id); end + + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2441 + def object; end + + # The owner of the object + # + # **Directory buckets** - The bucket owner is returned as the object + # owner. + # + # + # + # @return [Types::Owner] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#111 + def owner; end + + # @return [PresignedPost] + # @see Object#presigned_post + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#40 + def presigned_post(options = T.unsafe(nil)); end + + # @param method [Symbol] The S3 operation to generate a presigned URL for. Valid values + # are `:get`, `:put`, `:head`, `:delete`, `:create_multipart_upload`, + # `:list_multipart_uploads`, `:complete_multipart_upload`, + # `:abort_multipart_upload`, `:list_parts`, and `:upload_part`. + # @param params [Hash] Additional request parameters to use when generating the pre-signed + # URL. See the related documentation in {Client} for accepted + # params. + # + # | Method | Client Method | + # |------------------------------|------------------------------------| + # | `:get` | {Client#get_object} | + # | `:put` | {Client#put_object} | + # | `:head` | {Client#head_object} | + # | `:delete` | {Client#delete_object} | + # | `:create_multipart_upload` | {Client#create_multipart_upload} | + # | `:list_multipart_uploads` | {Client#list_multipart_uploads} | + # | `:complete_multipart_upload` | {Client#complete_multipart_upload} | + # | `:abort_multipart_upload` | {Client#abort_multipart_upload} | + # | `:list_parts` | {Client#list_parts} | + # | `:upload_part` | {Client#upload_part} | + # @return [String] + # @see Object#presigned_url + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#48 + def presigned_url(http_method, params = T.unsafe(nil)); end + + # @param options [Hash] a customizable set of options + # @return [String] + # @see Object#public_url + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#56 + def public_url(options = T.unsafe(nil)); end + + # @example Request syntax with placeholder values + # + # object_summary.put({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # body: source_file, + # cache_control: "CacheControl", + # content_disposition: "ContentDisposition", + # content_encoding: "ContentEncoding", + # content_language: "ContentLanguage", + # content_length: 1, + # content_md5: "ContentMD5", + # content_type: "ContentType", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # checksum_crc32: "ChecksumCRC32", + # checksum_crc32c: "ChecksumCRC32C", + # checksum_sha1: "ChecksumSHA1", + # checksum_sha256: "ChecksumSHA256", + # expires: Time.now, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write_acp: "GrantWriteACP", + # metadata: { + # "MetadataKey" => "MetadataValue", + # }, + # server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # website_redirect_location: "WebsiteRedirectLocation", + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # ssekms_key_id: "SSEKMSKeyId", + # ssekms_encryption_context: "SSEKMSEncryptionContext", + # bucket_key_enabled: false, + # request_payer: "requester", # accepts requester + # tagging: "TaggingHeader", + # object_lock_mode: "GOVERNANCE", # accepts GOVERNANCE, COMPLIANCE + # object_lock_retain_until_date: Time.now, + # object_lock_legal_hold_status: "ON", # accepts ON, OFF + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::PutObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2258 + def put(options = T.unsafe(nil)); end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#144 + def reload; end + + # @example Request syntax with placeholder values + # + # object_summary.restore_object({ + # version_id: "ObjectVersionId", + # restore_request: { + # days: 1, + # glacier_job_parameters: { + # tier: "Standard", # required, accepts Standard, Bulk, Expedited + # }, + # type: "SELECT", # accepts SELECT + # tier: "Standard", # accepts Standard, Bulk, Expedited + # description: "Description", + # select_parameters: { + # input_serialization: { # required + # csv: { + # file_header_info: "USE", # accepts USE, IGNORE, NONE + # comments: "Comments", + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # allow_quoted_record_delimiter: false, + # }, + # compression_type: "NONE", # accepts NONE, GZIP, BZIP2 + # json: { + # type: "DOCUMENT", # accepts DOCUMENT, LINES + # }, + # parquet: { + # }, + # }, + # expression_type: "SQL", # required, accepts SQL + # expression: "Expression", # required + # output_serialization: { # required + # csv: { + # quote_fields: "ALWAYS", # accepts ALWAYS, ASNEEDED + # quote_escape_character: "QuoteEscapeCharacter", + # record_delimiter: "RecordDelimiter", + # field_delimiter: "FieldDelimiter", + # quote_character: "QuoteCharacter", + # }, + # json: { + # record_delimiter: "RecordDelimiter", + # }, + # }, + # }, + # output_location: { + # s3: { + # bucket_name: "BucketName", # required + # prefix: "LocationPrefix", # required + # encryption: { + # encryption_type: "AES256", # required, accepts AES256, aws:kms, aws:kms:dsse + # kms_key_id: "SSEKMSKeyId", + # kms_context: "KMSContext", + # }, + # canned_acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control + # access_control_list: [ + # { + # grantee: { + # display_name: "DisplayName", + # email_address: "EmailAddress", + # id: "ID", + # type: "CanonicalUser", # required, accepts CanonicalUser, AmazonCustomerByEmail, Group + # uri: "URI", + # }, + # permission: "FULL_CONTROL", # accepts FULL_CONTROL, WRITE, WRITE_ACP, READ, READ_ACP + # }, + # ], + # tagging: { + # tag_set: [ # required + # { + # key: "ObjectKey", # required + # value: "Value", # required + # }, + # ], + # }, + # user_metadata: [ + # { + # name: "MetadataKey", + # value: "MetadataValue", + # }, + # ], + # storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE + # }, + # }, + # }, + # request_payer: "requester", # accepts requester + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::RestoreObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2399 + def restore_object(options = T.unsafe(nil)); end + + # Specifies the restoration status of an object. Objects in certain + # storage classes must be restored before they can be retrieved. For + # more information about these storage classes and how to work with + # archived objects, see [ Working with archived objects][1] in the + # *Amazon S3 User Guide*. + # + # This functionality is not supported for directory buckets. Only the S3 + # Express One Zone storage class is supported by directory buckets to + # store objects. + # + # + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/archived-objects.html + # + # @return [Types::RestoreStatus] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#131 + def restore_status; end + + # Size in bytes of the object + # + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#89 + def size; end + + # The class of storage used to store the object. + # + # **Directory buckets** - Only the S3 Express One Zone storage class is + # supported by directory buckets to store objects. + # + # + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#100 + def storage_class; end + + # @param source [String, Pathname, File, Tempfile] A file on the local + # file system that will be uploaded as this object. This can either be + # a String or Pathname to the file, an open File object, or an open + # Tempfile object. If you pass an open File or Tempfile object, then + # you are responsible for closing it after the upload completes. When + # using an open Tempfile, rewind it before uploading or else the object + # will be empty. + # @param options [Hash] Additional options for {Client#put_object} + # when file sizes below the multipart threshold. For files larger than + # the multipart threshold, options for {Client#create_multipart_upload}, + # {Client#complete_multipart_upload}, + # and {Client#upload_part} can be provided. + # @return [Boolean] Returns `true` when the object is uploaded + # without any errors. + # @see Object#upload_file + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#64 + def upload_file(source, options = T.unsafe(nil)); end + + # @return [Boolean] Returns `true` when the object is uploaded + # without any errors. + # @see Object#upload_stream + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/object_summary.rb#71 + def upload_stream(options = T.unsafe(nil), &block); end + + # @param id [String] + # @return [ObjectVersion] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2451 + def version(id); end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#301 + def wait_until(options = T.unsafe(nil), &block); end + + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [ObjectSummary] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#185 + def wait_until_exists(options = T.unsafe(nil), &block); end + + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [ObjectSummary] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#206 + def wait_until_not_exists(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2472 + def extract_bucket_name(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2483 + def extract_key(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2504 + def separate_params_and_options(options); end + + # @yield [waiter.waiter] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2494 + def yield_waiter_and_warn(waiter, &block); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2521 +class Aws::S3::ObjectSummary::Collection < ::Aws::Resources::Collection + # @example Request syntax with placeholder values + # + # object_summary.batch_delete!({ + # mfa: "MFA", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [{}] + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2620 + def batch_delete!(options = T.unsafe(nil)); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def delete(*args, &block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_summary.rb#2620 + def deprecated_delete(options = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#12 +class Aws::S3::ObjectVersion + extend ::Aws::Deprecations + + # @overload initialize + # @overload initialize + # @return [ObjectVersion] a new instance of ObjectVersion + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#26 + def initialize(*args); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#39 + def bucket_name; end + + # The algorithm that was used to create a checksum of the object. + # + # @return [Array] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#61 + def checksum_algorithm; end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#125 + def client; end + + # @raise [NotImplementedError] Raises when {#data_loaded?} is `false`. + # @return [Types::ObjectVersion] Returns the data for this {ObjectVersion}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#140 + def data; end + + # @return [Boolean] Returns `true` if this resource is loaded. Accessing attributes or + # {#data} on an unloaded resource will trigger a call to {#load}. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#148 + def data_loaded?; end + + # @example Request syntax with placeholder values + # + # object_version.delete({ + # mfa: "MFA", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # }) + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::DeleteObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#300 + def delete(options = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#734 + def deprecated_identifiers; end + + # The entity tag is an MD5 hash of that version of the object. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#55 + def etag; end + + # @example Request syntax with placeholder values + # + # object_version.get({ + # if_match: "IfMatch", + # if_modified_since: Time.now, + # if_none_match: "IfNoneMatch", + # if_unmodified_since: Time.now, + # range: "Range", + # response_cache_control: "ResponseCacheControl", + # response_content_disposition: "ResponseContentDisposition", + # response_content_encoding: "ResponseContentEncoding", + # response_content_language: "ResponseContentLanguage", + # response_content_type: "ResponseContentType", + # response_expires: Time.now, + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # part_number: 1, + # expected_bucket_owner: "AccountId", + # checksum_mode: "ENABLED", # accepts ENABLED + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::GetObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#527 + def get(options = T.unsafe(nil), &block); end + + # @example Request syntax with placeholder values + # + # object_version.head({ + # if_match: "IfMatch", + # if_modified_since: Time.now, + # if_none_match: "IfNoneMatch", + # if_unmodified_since: Time.now, + # range: "Range", + # response_cache_control: "ResponseCacheControl", + # response_content_disposition: "ResponseContentDisposition", + # response_content_encoding: "ResponseContentEncoding", + # response_content_language: "ResponseContentLanguage", + # response_content_type: "ResponseContentType", + # response_expires: Time.now, + # sse_customer_algorithm: "SSECustomerAlgorithm", + # sse_customer_key: "SSECustomerKey", + # sse_customer_key_md5: "SSECustomerKeyMD5", + # request_payer: "requester", # accepts requester + # part_number: 1, + # expected_bucket_owner: "AccountId", + # checksum_mode: "ENABLED", # accepts ENABLED + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Types::HeadObjectOutput] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#709 + def head(options = T.unsafe(nil)); end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#49 + def id; end + + # @api private + # @deprecated + # + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def identifiers(*args, &block); end + + # Specifies whether the object is (true) or is not (false) the latest + # version of an object. + # + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#92 + def is_latest; end + + # The object key. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#79 + def key; end + + # Date and time when the object was last modified. + # + # @return [Time] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#98 + def last_modified; end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#131 + def load; end + + # @return [Object] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#724 + def object; end + + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#44 + def object_key; end + + # Specifies the owner of the object. + # + # @return [Types::Owner] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#104 + def owner; end + + # @api private + # @raise [NotImplementedError] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#131 + def reload; end + + # Specifies the restoration status of an object. Objects in certain + # storage classes must be restored before they can be retrieved. For + # more information about these storage classes and how to work with + # archived objects, see [ Working with archived objects][1] in the + # *Amazon S3 User Guide*. + # + # + # + # [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/archived-objects.html + # + # @return [Types::RestoreStatus] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#118 + def restore_status; end + + # Size in bytes of the object. + # + # @return [Integer] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#67 + def size; end + + # The class of storage used to store the object. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#73 + def storage_class; end + + # Version ID of an object. + # + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#85 + def version_id; end + + # Waiter polls an API operation until a resource enters a desired + # state. + # + # ## Basic Usage + # + # Waiter will polls until it is successful, it fails by + # entering a terminal state, or until a maximum number of attempts + # are made. + # + # # polls in a loop until condition is true + # resource.wait_until(options) {|resource| condition} + # + # ## Example + # + # instance.wait_until(max_attempts:10, delay:5) do |instance| + # instance.state.name == 'running' + # end + # + # ## Configuration + # + # You can configure the maximum number of polling attempts, and the + # delay (in seconds) between each polling attempt. The waiting condition is + # set by passing a block to {#wait_until}: + # + # # poll for ~25 seconds + # resource.wait_until(max_attempts:5,delay:5) {|resource|...} + # + # ## Callbacks + # + # You can be notified before each polling attempt and before each + # delay. If you throw `:success` or `:failure` from these callbacks, + # it will terminate the waiter. + # + # started_at = Time.now + # # poll for 1 hour, instead of a number of attempts + # proc = Proc.new do |attempts, response| + # throw :failure if Time.now - started_at > 3600 + # end + # + # # disable max attempts + # instance.wait_until(before_wait:proc, max_attempts:nil) {...} + # + # ## Handling Errors + # + # When a waiter is successful, it returns the Resource. When a waiter + # fails, it raises an error. + # + # begin + # resource.wait_until(...) + # rescue Aws::Waiters::Errors::WaiterFailed + # # resource did not enter the desired state in time + # end + # + # attempts + # attempt in seconds + # invoked before each attempt + # invoked before each wait + # + # @deprecated Use [Aws::S3::Client] #wait_until instead + # @note The waiting operation is performed on a copy. The original resource + # remains unchanged. + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter + # terminates because the waiter has entered a state that it will not + # transition out of, preventing success. + # + # yet successful. + # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is + # encountered while polling for a resource that is not expected. + # @raise [NotImplementedError] Raised when the resource does not + # @return [Resource] if the waiter was successful + # @yieldparam resource [Resource] to be used in the waiting condition. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#232 + def wait_until(options = T.unsafe(nil), &block); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#745 + def extract_bucket_name(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#767 + def extract_id(args, options); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#756 + def extract_object_key(args, options); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#778 +class Aws::S3::ObjectVersion::Collection < ::Aws::Resources::Collection + # @example Request syntax with placeholder values + # + # object_version.batch_delete!({ + # mfa: "MFA", + # request_payer: "requester", # accepts requester + # bypass_governance_retention: false, + # expected_bucket_owner: "AccountId", + # checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256 + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [{}] + # @return [void] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#877 + def batch_delete!(options = T.unsafe(nil)); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core/deprecations.rb#65 + def delete(*args, &block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/object_version.rb#877 + def deprecated_delete(options = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/endpoints.rb#12 +module Aws::S3::Plugins; end + +# When an accesspoint ARN is provided for :bucket in S3 operations, this +# plugin resolves the request endpoint from the ARN when possible. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/arn.rb#9 +class Aws::S3::Plugins::ARN < ::Seahorse::Client::Plugin + class << self + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/arn.rb#52 + def resolve_s3_disable_multiregion_access_points(cfg); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/arn.rb#37 + def resolve_s3_use_arn_region(cfg); end + end +end + +# Provides support for using `Aws::S3::Client` with Amazon S3 Transfer +# Acceleration. +# +# Go here for more information about transfer acceleration: +# [http://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acceleration.html](http://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acceleration.html) +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/accelerate.rb#11 +class Aws::S3::Plugins::Accelerate < ::Seahorse::Client::Plugin + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/accelerate.rb#22 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/accelerate.rb#32 +class Aws::S3::Plugins::Accelerate::OptionHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/accelerate.rb#33 + def call(context); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#7 +class Aws::S3::Plugins::AccessGrants < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#157 + def add_handlers(handlers, config); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#163 + def after_initialize(client); end + + class << self + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#171 + def s3control?; end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#38 +class Aws::S3::Plugins::AccessGrants::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#60 + def call(context); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#111 + def access_grants_operation?(context); end + + # Return the common prefix of the keys, regardless of the delimiter. + # For example, given keys ['foo/bar', 'foo/baz'], the common prefix + # is 'foo/ba'. + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#123 + def common_prefixes(keys); end + + # HeadBucket is a supported call. When fetching credentials, + # this plugin is executed again, and becomes recursive. + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#107 + def credentials_head_bucket_call?(provider); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#116 + def s3_express_endpoint?(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#99 + def with_metric(credentials, &block); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/access_grants.rb#39 +Aws::S3::Plugins::AccessGrants::Handler::PERMISSION_MAP = T.let(T.unsafe(nil), Hash) + +# Amazon S3 requires DNS style addressing for buckets outside of +# the classic region when possible. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/bucket_dns.rb#9 +class Aws::S3::Plugins::BucketDns < ::Seahorse::Client::Plugin + class << self + # @param bucket_name [String] + # @param ssl [Boolean] + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/bucket_dns.rb#33 + def dns_compatible?(bucket_name, ssl); end + + # @param bucket_name [String] + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/bucket_dns.rb#43 + def valid_subdomain?(bucket_name); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/bucket_name_restrictions.rb#7 +class Aws::S3::Plugins::BucketNameRestrictions < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/bucket_name_restrictions.rb#8 +class Aws::S3::Plugins::BucketNameRestrictions::Handler < ::Seahorse::Client::Handler + # Useful because Aws::S3::Errors::SignatureDoesNotMatch is thrown + # when passed a bucket with a forward slash. Instead provide a more + # helpful error. Ideally should not be a plugin? + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/bucket_name_restrictions.rb#13 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/bucket_name_restrictions.rb#26 + def _bucket_member(input); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/dualstack.rb#7 +class Aws::S3::Plugins::Dualstack < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/dualstack.rb#8 + def add_handlers(handlers, _config); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/dualstack.rb#13 +class Aws::S3::Plugins::Dualstack::OptionHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/dualstack.rb#14 + def call(context); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/endpoints.rb#13 +class Aws::S3::Plugins::Endpoints < ::Seahorse::Client::Plugin + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/endpoints.rb#269 + def add_handlers(handlers, _config); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/endpoints.rb#33 +class Aws::S3::Plugins::Endpoints::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/endpoints.rb#34 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/endpoints.rb#54 + def apply_endpoint_headers(context, headers); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/endpoints.rb#65 + def parameters_for_operation(context); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/expect_100_continue.rb#6 +class Aws::S3::Plugins::Expect100Continue < ::Seahorse::Client::Plugin + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/expect_100_continue.rb#8 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/expect_100_continue.rb#15 +class Aws::S3::Plugins::Expect100Continue::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/expect_100_continue.rb#17 + def call(context); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/express_session_auth.rb#7 +class Aws::S3::Plugins::ExpressSessionAuth < ::Seahorse::Client::Plugin + # Optimization - sets this client as the client to create sessions. + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/express_session_auth.rb#71 + def after_initialize(client); end + + class << self + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/express_session_auth.rb#79 + def resolve_disable_s3_express_session_auth(cfg); end + end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/express_session_auth.rb#30 +class Aws::S3::Plugins::ExpressSessionAuth::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/express_session_auth.rb#31 + def call(context); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/express_session_auth.rb#61 + def checksum_required?(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/express_session_auth.rb#55 + def with_metric(credentials, &block); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/get_bucket_location_fix.rb#6 +class Aws::S3::Plugins::GetBucketLocationFix < ::Seahorse::Client::Plugin; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/get_bucket_location_fix.rb#8 +class Aws::S3::Plugins::GetBucketLocationFix::Handler < ::Seahorse::Client::Handler + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/get_bucket_location_fix.rb#10 + def call(context); end +end + +# A handful of Amazon S3 operations will respond with a 200 status +# code but will send an error in the response body. This plugin +# injects a handler that will parse 200 response bodies for potential +# errors, allowing them to be retried. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#12 +class Aws::S3::Plugins::Http200Errors < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#14 +class Aws::S3::Plugins::Http200Errors::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#16 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#72 + def check_for_error(context); end + + # Must have a member in the body and have the start of an XML Tag. + # Other incomplete xml bodies will result in an XML ParsingError. + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#68 + def incomplete_xml_body?(xml, output); end + + # Checks if the output shape is a structure shape and has members that + # are in the body for the case of a payload and a normal structure. A + # non-structure shape will not have members in the body. In the case + # of a string or blob, the body contents would have been checked first + # before this method is called in incomplete_xml_body?. + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#47 + def members_in_body?(output); end + + # Streaming outputs are not subject to 200 errors. + # + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#32 + def streaming_output?(output); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/http_200_errors.rb#62 + def structure_shape?(shape); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/iad_regional_endpoint.rb#7 +class Aws::S3::Plugins::IADRegionalEndpoint < ::Seahorse::Client::Plugin + class << self + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/iad_regional_endpoint.rb#21 + def resolve_iad_regional_endpoint(cfg); end + end +end + +# When making calls to {S3::Client#create_bucket} outside the +# "classic" region, the bucket location constraint must be specified. +# This plugin auto populates the constraint to the configured region. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/location_constraint.rb#10 +class Aws::S3::Plugins::LocationConstraint < ::Seahorse::Client::Plugin; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/location_constraint.rb#12 +class Aws::S3::Plugins::LocationConstraint::Handler < ::Seahorse::Client::Handler + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/location_constraint.rb#14 + def call(context); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/location_constraint.rb#23 + def populate_location_constraint(params, region); end +end + +# This plugin is effectively deprecated in favor of modeled +# httpChecksumRequired traits. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#11 +class Aws::S3::Plugins::Md5s < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#73 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#20 +class Aws::S3::Plugins::Md5s::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#24 + def call(context); end + + private + + # @api private + # @param value [File, Tempfile, IO#read, String] + # @return [String] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#39 + def md5(value); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#51 + def update_in_chunks(digest, io); end +end + +# one MB +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#22 +Aws::S3::Plugins::Md5s::Handler::CHUNK_SIZE = T.let(T.unsafe(nil), Integer) + +# These operations allow Content MD5 but are not required by +# httpChecksumRequired. This list should not grow. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/md5s.rb#14 +Aws::S3::Plugins::Md5s::OPTIONAL_OPERATIONS = T.let(T.unsafe(nil), Array) + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#39 +class Aws::S3::Plugins::NonRetryableStreamingError < ::StandardError + # @return [NonRetryableStreamingError] a new instance of NonRetryableStreamingError + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#41 + def initialize(error); end + + # Returns the value of attribute original_error. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#47 + def original_error; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/redirects.rb#6 +class Aws::S3::Plugins::Redirects < ::Seahorse::Client::Plugin + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/redirects.rb#35 + def add_handlers(handlers, config); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/redirects.rb#17 +class Aws::S3::Plugins::Redirects::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/redirects.rb#19 + def call(context); end +end + +# A wrapper around BlockIO that adds no-ops for truncate and rewind +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#11 +class Aws::S3::Plugins::RetryableBlockIO + extend ::Forwardable + + # @api private + # @return [RetryableBlockIO] a new instance of RetryableBlockIO + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#15 + def initialize(block_io); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def read(*args, **_arg1, &block); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#21 + def rewind; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def size(*args, **_arg1, &block); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#19 + def truncate(_integer); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def write(*args, **_arg1, &block); end +end + +# A wrapper around ManagedFile that adds no-ops for truncate and rewind +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#26 +class Aws::S3::Plugins::RetryableManagedFile + extend ::Forwardable + + # @api private + # @return [RetryableManagedFile] a new instance of RetryableManagedFile + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#30 + def initialize(managed_file); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def close(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def open?(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def read(*args, **_arg1, &block); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#36 + def rewind; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def size(*args, **_arg1, &block); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#34 + def truncate(_integer); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def write(*args, **_arg1, &block); end +end + +# Support S3 host id, more information, see: +# http://docs.aws.amazon.com/AmazonS3/latest/dev/troubleshooting.html#sdk-request-ids +# +# This plugin adds :host_id for s3 responses when available +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_host_id.rb#12 +class Aws::S3::Plugins::S3HostId < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_host_id.rb#14 +class Aws::S3::Plugins::S3HostId::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_host_id.rb#16 + def call(context); end +end + +# This plugin used to have a V4 signer but it was removed in favor of +# generic Sign plugin that uses endpoint auth scheme. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#17 +class Aws::S3::Plugins::S3Signer < ::Seahorse::Client::Plugin + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#20 + def add_handlers(handlers, cfg); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#35 + def add_legacy_handler(handlers); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#30 + def add_v4_handlers(handlers); end + + class << self + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#170 + def custom_endpoint?(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#161 + def new_hostname(context, region); end + end +end + +# This handler detects when a request fails because of a mismatched bucket +# region. It follows up by making a request to determine the correct +# region, then finally a version 4 signed request against the correct +# regional endpoint. This is intended for s3's global endpoint which +# will return 400 if the bucket is not in region. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#76 +class Aws::S3::Plugins::S3Signer::BucketRegionErrorHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#77 + def call(context); end + + private + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#112 + def expired_credentials?(resp); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#108 + def fips_region?(resp); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#95 + def get_region_and_retry(context); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#84 + def handle_region_errors(response); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#147 + def log_warning(context, actual_region); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#138 + def region_from_body(body); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#122 + def resign_with_new_region(context, actual_region); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#104 + def update_bucket_cache(context, actual_region); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#116 + def wrong_sigv4_region?(resp); end +end + +# This handler will update the http endpoint when the bucket region +# is known/cached. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#49 +class Aws::S3::Plugins::S3Signer::CachedBucketRegionHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#50 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#58 + def check_for_cached_region(context, bucket); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#40 +class Aws::S3::Plugins::S3Signer::LegacyHandler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/s3_signer.rb#41 + def call(context); end +end + +# S3 GetObject results for whole Multipart Objects contain a checksum +# that cannot be validated. These should be skipped by the +# ChecksumAlgorithm plugin. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/skip_whole_multipart_get_checksums.rb#10 +class Aws::S3::Plugins::SkipWholeMultipartGetChecksums < ::Seahorse::Client::Plugin; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/skip_whole_multipart_get_checksums.rb#12 +class Aws::S3::Plugins::SkipWholeMultipartGetChecksums::Handler < ::Seahorse::Client::Handler + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/skip_whole_multipart_get_checksums.rb#14 + def call(context); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/sse_cpk.rb#9 +class Aws::S3::Plugins::SseCpk < ::Seahorse::Client::Plugin; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/sse_cpk.rb#20 +class Aws::S3::Plugins::SseCpk::Handler < ::Seahorse::Client::Handler + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/sse_cpk.rb#22 + def call(context); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/sse_cpk.rb#59 + def base64(str); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/sse_cpk.rb#29 + def compute_key_md5(context); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/sse_cpk.rb#55 + def md5(str); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/sse_cpk.rb#43 + def require_https(context); end +end + +# This handler works with the ResponseTarget plugin to provide smart +# retries of S3 streaming operations that support the range parameter +# (currently only: get_object). When a 200 OK with a TruncatedBodyError +# is received this handler will add a range header that excludes the +# data that has already been processed (written to file or sent to +# the target Proc). +# It is important to not write data to the custom target in the case of +# a non-success response. We do not want to write an XML error +# message to someone's file or pass it to a user's Proc. +# +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#60 +class Aws::S3::Plugins::StreamingRetry < ::Seahorse::Client::Plugin; end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#62 +class Aws::S3::Plugins::StreamingRetry::Handler < ::Seahorse::Client::Handler + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#64 + def call(context); end + + private + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#76 + def add_event_listeners(context, target); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#121 + def retryable_body?(context); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#126 + def supported_target?(target); end + + # @api private + # @return [Boolean] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/streaming_retry.rb#114 + def truncated_body?(error); end +end + +# This plugin auto-populates the `:encoding_type` request parameter +# to all calls made to Amazon S3 that accept it. +# +# This enables Amazon S3 to return object keys that might contain +# invalid XML characters as URL encoded strings. This plugin also +# automatically decodes these keys so that the key management is +# transparent to the user. +# +# If you specify the `:encoding_type` parameter, then this plugin +# will be disabled, and you will need to decode the keys yourself. +# +# The following operations are managed: +# +# * {S3::Client#list_objects} +# * {S3::Client#list_multipart_uploads} +# * {S3::Client#list_object_versions} +# +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#27 +class Aws::S3::Plugins::UrlEncodedKeys < ::Seahorse::Client::Plugin; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#29 +class Aws::S3::Plugins::UrlEncodedKeys::Handler < ::Seahorse::Client::Handler + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#31 + def call(context); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#76 + def decode(member, struct); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#67 + def decode_list_multipart_uploads_keys(data); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#57 + def decode_list_object_versions_keys(data); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#48 + def decode_list_objects_keys(data); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/plugins/url_encoded_keys.rb#41 + def manage_keys(context); end +end + +# ## Basic Usage +# +# To generate a presigned post, you need AWS credentials, the region +# your bucket is in, and the name of your bucket. You can apply constraints +# to the post object as options to {#initialize} or by calling +# methods such as {#key} and {#content_length_range}. +# +# The following two examples are equivalent. +# +# ```ruby +# post = Aws::S3::PresignedPost.new(creds, region, bucket, { +# key: '/uploaded/object/key', +# content_length_range: 0..1024, +# acl: 'public-read', +# metadata: { +# 'original-filename' => '${filename}' +# } +# }) +# post.fields +# #=> { ... } +# +# post = Aws::S3::PresignedPost.new(creds, region, bucket). +# key('/uploaded/object/key'). +# content_length_range(0..1024). +# acl('public-read'). +# metadata('original-filename' => '${filename}'). +# fields +# #=> { ... } +# ``` +# +# ## HTML Forms +# +# You can use a {PresignedPost} object to build an HTML form. It is +# recommended to use some helper to build the form tag and input +# tags that properly escapes values. +# +# ### Form Tag +# +# To upload a file to Amazon S3 using a browser, you need to create +# a post form. The {#url} method returns the value you should use +# as the form action. +# +# ```erb +#
+# ... +#
+# ``` +# +# The follow attributes must be set on the form: +# +# * `action` - This must be the {#url}. +# * `method` - This must be `post`. +# * `enctype` - This must be `multipart/form-data`. +# +# ### Form Fields +# +# The {#fields} method returns a hash of form fields to render inside +# the form. Typically these are rendered as hidden input fields. +# +# ```erb +# <% @post.fields.each do |name, value| %> +# +# <% end %> +# ``` +# +# Lastly, the form must have a file field with the name `file`. +# +# ```erb +# +# ``` +# +# ## Post Policy +# +# When you construct a {PresignedPost}, you must specify every form +# field name that will be posted by the browser. If you omit a form +# field sent by the browser, Amazon S3 will reject the request. +# You can specify accepted form field values three ways: +# +# * Specify exactly what the value must be. +# * Specify what value the field starts with. +# * Specify the field may have any value. +# +# ### Field Equals +# +# You can specify that a form field must be a certain value. +# Simply pass an option like `:content_type` to the constructor, +# or call the associated method. +# +# ```ruby +# post = Aws::S3::PresignedPost.new(creds, region, bucket) +# post.content_type('text/plain') +# ``` +# +# If any of the given values are changed by the user in the form, then +# Amazon S3 will reject the POST request. +# +# ### Field Starts With +# +# You can specify prefix values for many of the POST form fields. +# To specify a required prefix, use the `:_starts_with` +# option or call the associated `#_starts_with` method. +# +# ```ruby +# post = Aws::S3::PresignedPost.new(creds, region, bucket, { +# key_starts_with: '/images/', +# content_type_starts_with: 'image/', +# # ... +# }) +# ``` +# +# When using starts with, the form must contain a field where the +# user can specify the value. The {PresignedPost} will not add +# a value for these fields. +# +# ### Any Field Value +# +# To white-list a form field to send any value, you can name that +# field with `:allow_any` or {#allow_any}. +# +# ```ruby +# post = Aws::S3::PresignedPost.new(creds, region, bucket, { +# key: 'object-key', +# allow_any: ['Filename'], +# # ... +# }) +# ``` +# +# ### Metadata +# +# You can add rules for metadata fields using `:metadata`, {#metadata}, +# `:metadata_starts_with` and {#metadata_starts_with}. Unlike other +# form fields, you pass a hash value to these options/methods: +# +# ```ruby +# post = Aws::S3::PresignedPost.new(creds, region, bucket). +# key('/fixed/key'). +# metadata(foo: 'bar') +# +# post.fields['x-amz-meta-foo'] +# #=> 'bar' +# ``` +# +# ### The `${filename}` Variable +# +# The string `${filename}` is automatically replaced with the name of the +# file provided by the user and is recognized by all form fields. It is +# not supported with `starts_with` conditions. +# +# If the browser or client provides a full or partial path to the file, +# only the text following the last slash (/) or backslash (\) will be used +# (e.g., "C:\Program Files\directory1\file.txt" will be interpreted +# as "file.txt"). If no file or file name is provided, the variable is +# replaced with an empty string. +# +# In the following example, we use `${filename}` to store the original +# filename in the `x-amz-meta-` hash with the uploaded object. +# +# ```ruby +# post = Aws::S3::PresignedPost.new(creds, region, bucket, { +# key: '/fixed/key', +# metadata: { +# 'original-filename': '${filename}' +# } +# }) +# ``` +# +# @note Normally you do not need to construct a {PresignedPost} yourself. +# See {Bucket#presigned_post} and {Object#presigned_post}. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#178 +class Aws::S3::PresignedPost + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param credentials [Credentials] Security credentials for signing + # the post policy. + # @param bucket_region [String] Region of the target bucket. + # @param bucket_name [String] Name of the target bucket. + # @param options [Hash] a customizable set of options + # @return [PresignedPost] a new instance of PresignedPost + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#243 + def initialize(credentials, bucket_region, bucket_name, options = T.unsafe(nil)); end + + # Specify the cannedl ACL (access control list) for the object. + # May be one of the following values: + # + # * `private` + # * `public-read` + # * `public-read-write` + # * `authenticated-read` + # * `bucket-owner-read` + # * `bucket-owner-full-control` + # + # @param canned_acl [String] + # @return [self] + # @see http://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def acl(value); end + + # @param prefix [String] + # @return [self] + # @see #acl + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#309 + def acl_starts_with(value); end + + # A list of form fields to white-list with any value. + # + # @param field_names [Sting, Array] + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#286 + def allow_any(*field_names); end + + # Specify caching behavior along the request/reply chain. + # + # @param value [String] + # @return [self] + # @see http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def cache_control(value); end + + # @param prefix [String] + # @return [self] + # @see #cache_control + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#309 + def cache_control_starts_with(value); end + + # Specifies presentational information for the object. + # + # @param value [String] + # @return [self] + # @see http://www.w3.org/Protocols/rfc2616/rfc2616-sec19.html#sec19.5.1 + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def content_disposition(value); end + + # @param prefix [String] + # @return [self] + # @see #content_disposition + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#309 + def content_disposition_starts_with(value); end + + # Specifies what content encodings have been applied to the object + # and thus what decoding mechanisms must be applied to obtain the + # media-type referenced by the Content-Type header field. + # + # @param value [String] + # @return [self] + # @see http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.11 + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def content_encoding(value); end + + # @param prefix [String] + # @return [self] + # @see #content_encoding + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#309 + def content_encoding_starts_with(value); end + + # The minimum and maximum allowable size for the uploaded content. + # + # @param byte_range [Range] + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#440 + def content_length_range(byte_range); end + + # A standard MIME type describing the format of the contents. + # + # @param value [String] + # @return [self] + # @see http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.21 + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def content_type(value); end + + # @param prefix [String] + # @return [self] + # @see #content_type + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#309 + def content_type_starts_with(value); end + + # The date and time at which the object is no longer cacheable. + # + # @note This does not affect the expiration of the presigned post + # signature. + # @param time [Time] + # @return [self] + # @see http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.21 + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#424 + def expires(time); end + + # @param prefix [String] + # @return [self] + # @see #expires + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#432 + def expires_starts_with(prefix); end + + # @return [Hash] A hash of fields to render in an HTML form + # as hidden input fields. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#274 + def fields; end + + # The key to use for the uploaded object. You can use `${filename}` + # as a variable in the key. This will be replaced with the name + # of the file as provided by the user. + # + # For example, if the key is given as `/user/betty/${filename}` and + # the file uploaded is named `lolcatz.jpg`, the resultant key will + # be `/user/betty/lolcatz.jpg`. + # + # @param key [String] + # @return [self] + # @see http://docs.aws.amazon.com/AmazonS3/latest/dev/UsingMetadata.html) + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#330 + def key(key); end + + # Specify a prefix the uploaded + # + # @param prefix [String] + # @return [self] + # @see #key + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#340 + def key_starts_with(prefix); end + + # Metadata hash to store with the uploaded object. Hash keys will be + # prefixed with "x-amz-meta-". + # + # @param hash [Hash] + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#520 + def metadata(hash); end + + # Specify allowable prefix for each key in the metadata hash. + # + # @param hash [Hash] + # @return [self] + # @see #metadata + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#532 + def metadata_starts_with(hash); end + + # Specifies a server-side encryption algorithm to use when Amazon + # S3 creates an object. Valid values include: + # + # * `aws:kms` + # * `AES256` + # + # @param value [String] + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def server_side_encryption(value); end + + # If {#server_side_encryption} is called with the value of `aws:kms`, + # this method specifies the ID of the AWS Key Management Service + # (KMS) master encryption key to use for the object. + # + # @param value [String] + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def server_side_encryption_aws_kms_key_id(value); end + + # Specifies the algorithm to use to when encrypting the object. + # Must be set to `AES256` when using customer-provided encryption + # keys. Must also call {#server_side_encryption_customer_key}. + # + # @param value [String] + # @return [self] + # @see #server_side_encryption_customer_key + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def server_side_encryption_customer_algorithm(value); end + + # Specifies the customer-provided encryption key for Amazon S3 to use + # in encrypting data. This value is used to store the object and then + # it is discarded; Amazon does not store the encryption key. + # + # You must also call {#server_side_encryption_customer_algorithm}. + # + # @param value [String] + # @return [self] + # @see #server_side_encryption_customer_algorithm + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#591 + def server_side_encryption_customer_key(value); end + + # @param prefix [String] + # @return [self] + # @see #server_side_encryption_customer_key + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#601 + def server_side_encryption_customer_key_starts_with(prefix); end + + # Storage class to use for storing the object. Defaults to + # `STANDARD`. Must be one of: + # + # * `STANDARD` + # * `REDUCED_REDUNDANCY` + # + # You cannot specify `GLACIER` as the storage class. To transition + # objects to the GLACIER storage class you can use lifecycle + # configuration. + # + # @param value [String] Storage class to use for storing the + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def storage_class(value); end + + # The URL to which the client is redirected + # upon successful upload. If {#success_action_redirect} is not + # specified, Amazon S3 returns the empty document type specified + # by {#success_action_status}. + # + # If Amazon S3 cannot interpret the URL, it acts as if the field + # is not present. If the upload fails, Amazon S3 displays an error + # and does not redirect the user to a URL. + # + # @param value [String] + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def success_action_redirect(value); end + + # @param prefix [String] + # @return [self] + # @see #success_action_redirect + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#309 + def success_action_redirect_starts_with(value); end + + # The status code returned to the client upon + # successful upload if {#success_action_redirect} is not + # specified. + # + # Accepts the values `200`, `201`, or `204` (default). + # + # If the value is set to 200 or 204, Amazon S3 returns an empty + # document with a 200 or 204 status code. If the value is set to 201, + # Amazon S3 returns an XML document with a 201 status code. + # + # If the value is not set or if it is set to an invalid value, Amazon + # S3 returns an empty document with a 204 status code. + # + # @param value [String] The status code returned to the client upon + # @return [self] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def success_action_status(value); end + + # @return [String] The URL to post a file upload to. This should be + # the form action. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#270 + def url; end + + # If the bucket is configured as a website, + # redirects requests for this object to another object in the + # same bucket or to an external URL. Amazon S3 stores this value + # in the object metadata. + # + # The value must be prefixed by, "/", "http://" or "https://". + # The length of the value is limited to 2K. + # + # @param value [String] + # @return [self] + # @see http://docs.aws.amazon.com/AmazonS3/latest/dev/UsingMetadata.html + # @see http://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html + # @see http://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#303 + def website_redirect_location(value); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#702 + def base64(str); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#640 + def bucket_url; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#632 + def check_required_values!; end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#692 + def credential_scope(datetime); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#688 + def hexhmac(key, value); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#684 + def hmac(key, value); end + + # @return [Hash] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#653 + def policy(datetime); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#675 + def signature(datetime, string_to_sign); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#664 + def signature_fields(datetime); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#627 + def starts_with(field_name, value, &block); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#610 + def with(field_name, value); end + + class << self + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigned_post.rb#295 + def define_field(field, *args, &block); end + end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#5 +class Aws::S3::Presigner + # @option options + # @param options [Hash] a customizable set of options + # @return [Presigner] a new instance of Presigner + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#35 + def initialize(options = T.unsafe(nil)); end + + # Allows you to create presigned URL requests for S3 operations. This + # method returns a tuple containing the URL and the signed X-amz-* headers + # to be used with the presigned url. + # + # @example + # signer = Aws::S3::Presigner.new + # url, headers = signer.presigned_request( + # :get_object, bucket: "bucket", key: "key" + # ) + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param method [Symbol] Symbolized method name of the operation you want + # to presign. + # @param params [Hash] a customizable set of options + # @raise [ArgumentError] Raises an ArgumentError if `:expires_in` + # exceeds one week. + # @return [String, Hash] A tuple with a presigned URL and headers that + # should be included with the request. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#128 + def presigned_request(method, params = T.unsafe(nil)); end + + # Create presigned URLs for S3 operations. + # + # @example + # signer = Aws::S3::Presigner.new + # url = signer.presigned_url(:get_object, bucket: "bucket", key: "key") + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param method [Symbol] Symbolized method name of the operation you want + # to presign. + # @param params [Hash] a customizable set of options + # @raise [ArgumentError] Raises an ArgumentError if `:expires_in` + # exceeds one week. + # @return [String] a presigned url + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#78 + def presigned_url(method, params = T.unsafe(nil)); end + + private + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#134 + def _presigned_request(method, params, hoist = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#156 + def expires_in(params); end + + # Used for excluding presigned_urls from API request count. + # + # Store context information as early as possible, to allow + # handlers to perform decisions based on this flag if need. + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#184 + def handle_presigned_url_context(req); end + + # @param req [Seahorse::Client::Request] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#192 + def sign_but_dont_send(req, expires_in, secure, time, unsigned_headers, hoist = T.unsafe(nil)); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#151 + def unsigned_headers(params); end + + # source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#171 + def use_bucket_as_hostname(req); end +end + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#13 +Aws::S3::Presigner::BLACKLISTED_HEADERS = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#10 +Aws::S3::Presigner::FIFTEEN_MINUTES = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://aws-sdk-s3//lib/aws-sdk-s3/presigner.rb#7 +Aws::S3::Presigner::ONE_WEEK = T.let(T.unsafe(nil), Integer) + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#8 +Aws::S3::REQUIRED_PARAMS = T.let(T.unsafe(nil), Array) + +# This class provides a resource oriented interface for S3. +# To create a resource object: +# +# resource = Aws::S3::Resource.new(region: 'us-west-2') +# +# You can supply a client object with custom configuration that will be used for all resource operations. +# If you do not pass `:client`, a default client will be constructed. +# +# client = Aws::S3::Client.new(region: 'us-west-2') +# resource = Aws::S3::Resource.new(client: client) +# +# source://aws-sdk-s3//lib/aws-sdk-s3/resource.rb#23 +class Aws::S3::Resource + # @option options + # @param options [{}] + # @return [Resource] a new instance of Resource + # + # source://aws-sdk-s3//lib/aws-sdk-s3/resource.rb#27 + def initialize(options = T.unsafe(nil)); end + + # @param name [String] + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/resource.rb#182 + def bucket(name); end + + # @example Request syntax with placeholder values + # + # s3.buckets() + # @param options [Hash] ({}) + # @return [Bucket::Collection] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/resource.rb#194 + def buckets(options = T.unsafe(nil)); end + + # @return [Client] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/resource.rb#32 + def client; end + + # @example Request syntax with placeholder values + # + # bucket = s3.create_bucket({ + # acl: "private", # accepts private, public-read, public-read-write, authenticated-read + # bucket: "BucketName", # required + # create_bucket_configuration: { + # location_constraint: "af-south-1", # accepts af-south-1, ap-east-1, ap-northeast-1, ap-northeast-2, ap-northeast-3, ap-south-1, ap-south-2, ap-southeast-1, ap-southeast-2, ap-southeast-3, ca-central-1, cn-north-1, cn-northwest-1, EU, eu-central-1, eu-north-1, eu-south-1, eu-south-2, eu-west-1, eu-west-2, eu-west-3, me-south-1, sa-east-1, us-east-2, us-gov-east-1, us-gov-west-1, us-west-1, us-west-2 + # location: { + # type: "AvailabilityZone", # accepts AvailabilityZone + # name: "LocationNameAsString", + # }, + # bucket: { + # data_redundancy: "SingleAvailabilityZone", # accepts SingleAvailabilityZone + # type: "Directory", # accepts Directory + # }, + # }, + # grant_full_control: "GrantFullControl", + # grant_read: "GrantRead", + # grant_read_acp: "GrantReadACP", + # grant_write: "GrantWrite", + # grant_write_acp: "GrantWriteACP", + # object_lock_enabled_for_bucket: false, + # object_ownership: "BucketOwnerPreferred", # accepts BucketOwnerPreferred, ObjectWriter, BucketOwnerEnforced + # }) + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] ({}) + # @return [Bucket] + # + # source://aws-sdk-s3//lib/aws-sdk-s3/resource.rb#168 + def create_bucket(options = T.unsafe(nil)); end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/encryptionV2/client.rb#9 +Aws::S3::SUPPORTED_SECURITY_PROFILES = T.let(T.unsafe(nil), Array) + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11 +module Aws::S3::Types; end + +# Specifies the days since the initiation of an incomplete multipart +# upload that Amazon S3 will wait before permanently removing all parts +# of the upload. For more information, see [ Aborting Incomplete +# Multipart Uploads Using a Bucket Lifecycle Configuration][1] in the +# *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html#mpu-abort-incomplete-mpu-lifecycle-config +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortIncompleteMultipartUpload AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#31 +class Aws::S3::Types::AbortIncompleteMultipartUpload < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#32 +Aws::S3::Types::AbortIncompleteMultipartUpload::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortMultipartUploadOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#48 +class Aws::S3::Types::AbortMultipartUploadOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#49 +Aws::S3::Types::AbortMultipartUploadOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortMultipartUploadRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#138 +class Aws::S3::Types::AbortMultipartUploadRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#139 +Aws::S3::Types::AbortMultipartUploadRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Configures the transfer acceleration state for an Amazon S3 bucket. +# For more information, see [Amazon S3 Transfer Acceleration][1] in the +# *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acceleration.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AccelerateConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#158 +class Aws::S3::Types::AccelerateConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#159 +Aws::S3::Types::AccelerateConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the elements that set the ACL permissions for an object per +# grantee. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AccessControlPolicy AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#178 +class Aws::S3::Types::AccessControlPolicy < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#179 +Aws::S3::Types::AccessControlPolicy::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for information about access control for replicas. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AccessControlTranslation AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#197 +class Aws::S3::Types::AccessControlTranslation < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#198 +Aws::S3::Types::AccessControlTranslation::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A conjunction (logical AND) of predicates, which is used in evaluating +# a metrics filter. The operator must have at least two predicates in +# any combination, and an object must match all of the predicates for +# the filter to apply. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsAndOperator AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#220 +class Aws::S3::Types::AnalyticsAndOperator < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#221 +Aws::S3::Types::AnalyticsAndOperator::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the configuration and any analyses for the analytics filter +# of an Amazon S3 bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#250 +class Aws::S3::Types::AnalyticsConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#251 +Aws::S3::Types::AnalyticsConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Where to publish the analytics results. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsExportDestination AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#264 +class Aws::S3::Types::AnalyticsExportDestination < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#265 +Aws::S3::Types::AnalyticsExportDestination::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The filter used to describe a set of objects for analyses. A filter +# must have exactly one prefix, one tag, or one conjunction +# (AnalyticsAndOperator). If no filter is provided, all objects will be +# considered in any analysis. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#293 +class Aws::S3::Types::AnalyticsFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#294 +Aws::S3::Types::AnalyticsFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains information about where to publish the analytics results. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsS3BucketDestination AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#331 +class Aws::S3::Types::AnalyticsS3BucketDestination < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#332 +Aws::S3::Types::AnalyticsS3BucketDestination::SENSITIVE = T.let(T.unsafe(nil), Array) + +# In terms of implementation, a Bucket is a resource. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Bucket AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#351 +class Aws::S3::Types::Bucket < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#352 +Aws::S3::Types::Bucket::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The requested bucket name is not available. The bucket namespace is +# shared by all users of the system. Select a different name and try +# again. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/BucketAlreadyExists AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#362 +class Aws::S3::Types::BucketAlreadyExists < ::Aws::EmptyStructure; end + +# The bucket you tried to create already exists, and you own it. Amazon +# S3 returns this error in all Amazon Web Services Regions except in the +# North Virginia Region. For legacy compatibility, if you re-create an +# existing bucket that you already own in the North Virginia Region, +# Amazon S3 returns 200 OK and resets the bucket access control lists +# (ACLs). +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/BucketAlreadyOwnedByYou AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#373 +class Aws::S3::Types::BucketAlreadyOwnedByYou < ::Aws::EmptyStructure; end + +# Specifies the information about the bucket that will be created. For +# more information about directory buckets, see [Directory buckets][1] +# in the *Amazon S3 User Guide*. +# +# This functionality is only supported by directory buckets. +# +# +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/BucketInfo AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#400 +class Aws::S3::Types::BucketInfo < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#401 +Aws::S3::Types::BucketInfo::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the lifecycle configuration for objects in an Amazon S3 +# bucket. For more information, see [Object Lifecycle Management][1] in +# the *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/BucketLifecycleConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#420 +class Aws::S3::Types::BucketLifecycleConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#421 +Aws::S3::Types::BucketLifecycleConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for logging status information. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/BucketLoggingStatus AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#440 +class Aws::S3::Types::BucketLoggingStatus < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#441 +Aws::S3::Types::BucketLoggingStatus::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the cross-origin access configuration for objects in an +# Amazon S3 bucket. For more information, see [Enabling Cross-Origin +# Resource Sharing][1] in the *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/cors.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CORSConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#461 +class Aws::S3::Types::CORSConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#462 +Aws::S3::Types::CORSConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies a cross-origin access rule for an Amazon S3 bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CORSRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#509 +class Aws::S3::Types::CORSRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#510 +Aws::S3::Types::CORSRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes how an uncompressed comma-separated values (CSV)-formatted +# input object is formatted. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CSVInput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#584 +class Aws::S3::Types::CSVInput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#585 +Aws::S3::Types::CSVInput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes how uncompressed comma-separated values (CSV)-formatted +# results are formatted. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CSVOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#629 +class Aws::S3::Types::CSVOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#630 +Aws::S3::Types::CSVOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains all the possible checksum or digest values for an object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Checksum AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#702 +class Aws::S3::Types::Checksum < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#703 +Aws::S3::Types::Checksum::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for specifying the Lambda notification configuration. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CloudFunctionConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#739 +class Aws::S3::Types::CloudFunctionConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#740 +Aws::S3::Types::CloudFunctionConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for all (if there are any) keys between Prefix and the next +# occurrence of the string specified by a delimiter. CommonPrefixes +# lists keys that act like subdirectories in the directory specified by +# Prefix. For example, if the prefix is notes/ and the delimiter is a +# slash (/) as in notes/summer/july, the common prefix is notes/summer/. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CommonPrefix AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#757 +class Aws::S3::Types::CommonPrefix < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#758 +Aws::S3::Types::CommonPrefix::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompleteMultipartUploadOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#929 +class Aws::S3::Types::CompleteMultipartUploadOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#930 +Aws::S3::Types::CompleteMultipartUploadOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompleteMultipartUploadRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1125 +class Aws::S3::Types::CompleteMultipartUploadRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1126 +Aws::S3::Types::CompleteMultipartUploadRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container for the completed multipart upload details. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompletedMultipartUpload AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1142 +class Aws::S3::Types::CompletedMultipartUpload < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1143 +Aws::S3::Types::CompletedMultipartUpload::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Details of the parts that were uploaded. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompletedPart AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1240 +class Aws::S3::Types::CompletedPart < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1241 +Aws::S3::Types::CompletedPart::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for describing a condition that must be met for the +# specified redirect to apply. For example, 1. If request is for pages +# in the `/docs` folder, redirect to the `/documents` folder. 2. If +# request results in HTTP error 4xx, redirect request to another host +# where you might process the error. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Condition AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1283 +class Aws::S3::Types::Condition < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1284 +Aws::S3::Types::Condition::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ContinuationEvent AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1291 +class Aws::S3::Types::ContinuationEvent < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1292 +Aws::S3::Types::ContinuationEvent::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObjectOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1410 +class Aws::S3::Types::CopyObjectOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#1411 +Aws::S3::Types::CopyObjectOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObjectRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2211 +class Aws::S3::Types::CopyObjectRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2212 +Aws::S3::Types::CopyObjectRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for all response elements. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObjectResult AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2279 +class Aws::S3::Types::CopyObjectResult < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2280 +Aws::S3::Types::CopyObjectResult::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for all response elements. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyPartResult AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2362 +class Aws::S3::Types::CopyPartResult < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2363 +Aws::S3::Types::CopyPartResult::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The configuration information for the bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucketConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2412 +class Aws::S3::Types::CreateBucketConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2413 +Aws::S3::Types::CreateBucketConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucketOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2424 +class Aws::S3::Types::CreateBucketOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2425 +Aws::S3::Types::CreateBucketOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucketRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2566 +class Aws::S3::Types::CreateBucketRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2567 +Aws::S3::Types::CreateBucketRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateMultipartUploadOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2710 +class Aws::S3::Types::CreateMultipartUploadOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#2711 +Aws::S3::Types::CreateMultipartUploadOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateMultipartUploadRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3295 +class Aws::S3::Types::CreateMultipartUploadRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3296 +Aws::S3::Types::CreateMultipartUploadRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateSessionOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3308 +class Aws::S3::Types::CreateSessionOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3309 +Aws::S3::Types::CreateSessionOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateSessionRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3331 +class Aws::S3::Types::CreateSessionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3332 +Aws::S3::Types::CreateSessionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container element for specifying the default Object Lock retention +# settings for new objects placed in the specified bucket. +# +# * The `DefaultRetention` settings require both a mode and a period. +# +# * The `DefaultRetention` period can be either `Days` or `Years` but +# you must select one. You cannot specify `Days` and `Years` at the +# same time. +# +# +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DefaultRetention AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3368 +class Aws::S3::Types::DefaultRetention < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3369 +Aws::S3::Types::DefaultRetention::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the objects to delete. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Delete AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3396 +class Aws::S3::Types::Delete < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3397 +Aws::S3::Types::Delete::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketAnalyticsConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3422 +class Aws::S3::Types::DeleteBucketAnalyticsConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3423 +Aws::S3::Types::DeleteBucketAnalyticsConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketCorsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3442 +class Aws::S3::Types::DeleteBucketCorsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3443 +Aws::S3::Types::DeleteBucketCorsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketEncryptionRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3463 +class Aws::S3::Types::DeleteBucketEncryptionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3464 +Aws::S3::Types::DeleteBucketEncryptionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketIntelligentTieringConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3481 +class Aws::S3::Types::DeleteBucketIntelligentTieringConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3482 +Aws::S3::Types::DeleteBucketIntelligentTieringConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketInventoryConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3507 +class Aws::S3::Types::DeleteBucketInventoryConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3508 +Aws::S3::Types::DeleteBucketInventoryConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketLifecycleRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3527 +class Aws::S3::Types::DeleteBucketLifecycleRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3528 +Aws::S3::Types::DeleteBucketLifecycleRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketMetricsConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3555 +class Aws::S3::Types::DeleteBucketMetricsConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3556 +Aws::S3::Types::DeleteBucketMetricsConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketOwnershipControlsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3575 +class Aws::S3::Types::DeleteBucketOwnershipControlsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3576 +Aws::S3::Types::DeleteBucketOwnershipControlsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketPolicyRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3615 +class Aws::S3::Types::DeleteBucketPolicyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3616 +Aws::S3::Types::DeleteBucketPolicyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketReplicationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3635 +class Aws::S3::Types::DeleteBucketReplicationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3636 +Aws::S3::Types::DeleteBucketReplicationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3675 +class Aws::S3::Types::DeleteBucketRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3676 +Aws::S3::Types::DeleteBucketRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketTaggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3695 +class Aws::S3::Types::DeleteBucketTaggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3696 +Aws::S3::Types::DeleteBucketTaggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketWebsiteRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3716 +class Aws::S3::Types::DeleteBucketWebsiteRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3717 +Aws::S3::Types::DeleteBucketWebsiteRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Information about the delete marker. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteMarkerEntry AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3751 +class Aws::S3::Types::DeleteMarkerEntry < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3752 +Aws::S3::Types::DeleteMarkerEntry::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies whether Amazon S3 replicates delete markers. If you specify +# a `Filter` in your replication configuration, you must also include a +# `DeleteMarkerReplication` element. If your `Filter` includes a `Tag` +# element, the `DeleteMarkerReplication` `Status` must be set to +# Disabled, because Amazon S3 does not support replicating delete +# markers for tag-based rules. For an example configuration, see [Basic +# Rule Configuration][1]. +# +# For more information about delete marker replication, see [Basic Rule +# Configuration][2]. +# +# If you are using an earlier version of the replication configuration, +# Amazon S3 handles replication of delete markers differently. For more +# information, see [Backward Compatibility][3]. +# +# +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication-add-config.html#replication-config-min-rule-config +# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/delete-marker-replication.html +# [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication-add-config.html#replication-backward-compat-considerations +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteMarkerReplication AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3790 +class Aws::S3::Types::DeleteMarkerReplication < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3791 +Aws::S3::Types::DeleteMarkerReplication::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3829 +class Aws::S3::Types::DeleteObjectOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3830 +Aws::S3::Types::DeleteObjectOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3947 +class Aws::S3::Types::DeleteObjectRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3948 +Aws::S3::Types::DeleteObjectRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectTaggingOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3959 +class Aws::S3::Types::DeleteObjectTaggingOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#3960 +Aws::S3::Types::DeleteObjectTaggingOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectTaggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4016 +class Aws::S3::Types::DeleteObjectTaggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4017 +Aws::S3::Types::DeleteObjectTaggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4045 +class Aws::S3::Types::DeleteObjectsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4046 +Aws::S3::Types::DeleteObjectsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4205 +class Aws::S3::Types::DeleteObjectsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4206 +Aws::S3::Types::DeleteObjectsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeletePublicAccessBlockRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4226 +class Aws::S3::Types::DeletePublicAccessBlockRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4227 +Aws::S3::Types::DeletePublicAccessBlockRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Information about the deleted object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeletedObject AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4273 +class Aws::S3::Types::DeletedObject < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4274 +Aws::S3::Types::DeletedObject::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies information about where to publish analysis or configuration +# results for an Amazon S3 bucket and S3 Replication Time Control (S3 +# RTC). +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Destination AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4350 +class Aws::S3::Types::Destination < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4351 +Aws::S3::Types::Destination::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the type of server-side encryption used. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Encryption AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4385 +class Aws::S3::Types::Encryption < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4386 +Aws::S3::Types::Encryption::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies encryption-related information for an Amazon S3 bucket that +# is a destination for replicated objects. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/EncryptionConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4410 +class Aws::S3::Types::EncryptionConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4411 +Aws::S3::Types::EncryptionConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A message that indicates the request is complete and no more messages +# will be sent. You should not assume that the request is complete until +# the client receives an `EndEvent`. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/EndEvent AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4422 +class Aws::S3::Types::EndEvent < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#4423 +Aws::S3::Types::EndEvent::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for all error elements. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Error AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5262 +class Aws::S3::Types::Error < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5263 +Aws::S3::Types::Error::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The error information. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ErrorDocument AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5284 +class Aws::S3::Types::ErrorDocument < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5285 +Aws::S3::Types::ErrorDocument::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for specifying the configuration for Amazon EventBridge. +# +# @api private +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/EventBridgeConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5295 +class Aws::S3::Types::EventBridgeConfiguration < ::Aws::EmptyStructure; end + +# Optional configuration to replicate existing source bucket objects. +# For more information, see [Replicating Existing Objects][1] in the +# *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/replication-what-is-isnot-replicated.html#existing-object-replication +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ExistingObjectReplication AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5313 +class Aws::S3::Types::ExistingObjectReplication < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5314 +Aws::S3::Types::ExistingObjectReplication::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the Amazon S3 object key name to filter on. An object key +# name is the name assigned to an object in your Amazon S3 bucket. You +# specify whether to filter on the suffix or prefix of the object key +# name. A prefix is a specific string of characters at the beginning of +# an object key name, which you can use to organize objects. For +# example, you can start the key names of related objects with a prefix, +# such as `2023-` or `engineering/`. Then, you can use `FilterRule` to +# find objects in a bucket with key names that have the same prefix. A +# suffix is similar to a prefix, but it is at the end of the object key +# name instead of at the beginning. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/FilterRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5349 +class Aws::S3::Types::FilterRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5350 +Aws::S3::Types::FilterRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAccelerateConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5371 +class Aws::S3::Types::GetBucketAccelerateConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5372 +Aws::S3::Types::GetBucketAccelerateConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAccelerateConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5411 +class Aws::S3::Types::GetBucketAccelerateConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5412 +Aws::S3::Types::GetBucketAccelerateConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAclOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5428 +class Aws::S3::Types::GetBucketAclOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5429 +Aws::S3::Types::GetBucketAclOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAclRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5462 +class Aws::S3::Types::GetBucketAclRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5463 +Aws::S3::Types::GetBucketAclRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAnalyticsConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5474 +class Aws::S3::Types::GetBucketAnalyticsConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5475 +Aws::S3::Types::GetBucketAnalyticsConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAnalyticsConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5500 +class Aws::S3::Types::GetBucketAnalyticsConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5501 +Aws::S3::Types::GetBucketAnalyticsConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketCorsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5513 +class Aws::S3::Types::GetBucketCorsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5514 +Aws::S3::Types::GetBucketCorsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketCorsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5547 +class Aws::S3::Types::GetBucketCorsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5548 +Aws::S3::Types::GetBucketCorsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketEncryptionOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5559 +class Aws::S3::Types::GetBucketEncryptionOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5560 +Aws::S3::Types::GetBucketEncryptionOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketEncryptionRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5580 +class Aws::S3::Types::GetBucketEncryptionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5581 +Aws::S3::Types::GetBucketEncryptionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketIntelligentTieringConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5592 +class Aws::S3::Types::GetBucketIntelligentTieringConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5593 +Aws::S3::Types::GetBucketIntelligentTieringConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketIntelligentTieringConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5610 +class Aws::S3::Types::GetBucketIntelligentTieringConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5611 +Aws::S3::Types::GetBucketIntelligentTieringConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketInventoryConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5622 +class Aws::S3::Types::GetBucketInventoryConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5623 +Aws::S3::Types::GetBucketInventoryConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketInventoryConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5648 +class Aws::S3::Types::GetBucketInventoryConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5649 +Aws::S3::Types::GetBucketInventoryConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5660 +class Aws::S3::Types::GetBucketLifecycleConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5661 +Aws::S3::Types::GetBucketLifecycleConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5680 +class Aws::S3::Types::GetBucketLifecycleConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5681 +Aws::S3::Types::GetBucketLifecycleConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5692 +class Aws::S3::Types::GetBucketLifecycleOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5693 +Aws::S3::Types::GetBucketLifecycleOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5712 +class Aws::S3::Types::GetBucketLifecycleRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5713 +Aws::S3::Types::GetBucketLifecycleRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5731 +class Aws::S3::Types::GetBucketLocationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5732 +Aws::S3::Types::GetBucketLocationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5765 +class Aws::S3::Types::GetBucketLocationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5766 +Aws::S3::Types::GetBucketLocationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLoggingOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5783 +class Aws::S3::Types::GetBucketLoggingOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5784 +Aws::S3::Types::GetBucketLoggingOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLoggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5803 +class Aws::S3::Types::GetBucketLoggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5804 +Aws::S3::Types::GetBucketLoggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketMetricsConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5815 +class Aws::S3::Types::GetBucketMetricsConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5816 +Aws::S3::Types::GetBucketMetricsConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketMetricsConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5843 +class Aws::S3::Types::GetBucketMetricsConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5844 +Aws::S3::Types::GetBucketMetricsConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotificationConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5878 +class Aws::S3::Types::GetBucketNotificationConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5879 +Aws::S3::Types::GetBucketNotificationConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketOwnershipControlsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5891 +class Aws::S3::Types::GetBucketOwnershipControlsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5892 +Aws::S3::Types::GetBucketOwnershipControlsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketOwnershipControlsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5912 +class Aws::S3::Types::GetBucketOwnershipControlsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5913 +Aws::S3::Types::GetBucketOwnershipControlsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicyOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5924 +class Aws::S3::Types::GetBucketPolicyOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5925 +Aws::S3::Types::GetBucketPolicyOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicyRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5981 +class Aws::S3::Types::GetBucketPolicyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5982 +Aws::S3::Types::GetBucketPolicyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicyStatusOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5993 +class Aws::S3::Types::GetBucketPolicyStatusOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#5994 +Aws::S3::Types::GetBucketPolicyStatusOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicyStatusRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6014 +class Aws::S3::Types::GetBucketPolicyStatusRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6015 +Aws::S3::Types::GetBucketPolicyStatusRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketReplicationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6027 +class Aws::S3::Types::GetBucketReplicationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6028 +Aws::S3::Types::GetBucketReplicationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketReplicationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6047 +class Aws::S3::Types::GetBucketReplicationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6048 +Aws::S3::Types::GetBucketReplicationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketRequestPaymentOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6059 +class Aws::S3::Types::GetBucketRequestPaymentOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6060 +Aws::S3::Types::GetBucketRequestPaymentOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketRequestPaymentRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6080 +class Aws::S3::Types::GetBucketRequestPaymentRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6081 +Aws::S3::Types::GetBucketRequestPaymentRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketTaggingOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6092 +class Aws::S3::Types::GetBucketTaggingOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6093 +Aws::S3::Types::GetBucketTaggingOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketTaggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6112 +class Aws::S3::Types::GetBucketTaggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6113 +Aws::S3::Types::GetBucketTaggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketVersioningOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6132 +class Aws::S3::Types::GetBucketVersioningOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6133 +Aws::S3::Types::GetBucketVersioningOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketVersioningRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6152 +class Aws::S3::Types::GetBucketVersioningRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6153 +Aws::S3::Types::GetBucketVersioningRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketWebsiteOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6183 +class Aws::S3::Types::GetBucketWebsiteOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6184 +Aws::S3::Types::GetBucketWebsiteOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketWebsiteRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6203 +class Aws::S3::Types::GetBucketWebsiteRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6204 +Aws::S3::Types::GetBucketWebsiteRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAclOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6230 +class Aws::S3::Types::GetObjectAclOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6231 +Aws::S3::Types::GetObjectAclOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAclRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6299 +class Aws::S3::Types::GetObjectAclRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6300 +Aws::S3::Types::GetObjectAclRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAttributesOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6380 +class Aws::S3::Types::GetObjectAttributesOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6381 +Aws::S3::Types::GetObjectAttributesOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A collection of parts associated with a multipart upload. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAttributesParts AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6437 +class Aws::S3::Types::GetObjectAttributesParts < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6438 +Aws::S3::Types::GetObjectAttributesParts::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAttributesRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6585 +class Aws::S3::Types::GetObjectAttributesRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6586 +Aws::S3::Types::GetObjectAttributesRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectLegalHoldOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6597 +class Aws::S3::Types::GetObjectLegalHoldOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6598 +Aws::S3::Types::GetObjectLegalHoldOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectLegalHoldRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6664 +class Aws::S3::Types::GetObjectLegalHoldRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6665 +Aws::S3::Types::GetObjectLegalHoldRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectLockConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6676 +class Aws::S3::Types::GetObjectLockConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6677 +Aws::S3::Types::GetObjectLockConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectLockConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6711 +class Aws::S3::Types::GetObjectLockConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#6712 +Aws::S3::Types::GetObjectLockConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7063 +class Aws::S3::Types::GetObjectOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7064 +Aws::S3::Types::GetObjectOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7409 +class Aws::S3::Types::GetObjectRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7410 +Aws::S3::Types::GetObjectRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectRetentionOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7421 +class Aws::S3::Types::GetObjectRetentionOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7422 +Aws::S3::Types::GetObjectRetentionOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectRetentionRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7488 +class Aws::S3::Types::GetObjectRetentionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7489 +Aws::S3::Types::GetObjectRetentionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTaggingOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7506 +class Aws::S3::Types::GetObjectTaggingOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7507 +Aws::S3::Types::GetObjectTaggingOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTaggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7582 +class Aws::S3::Types::GetObjectTaggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7583 +Aws::S3::Types::GetObjectTaggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTorrentOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7604 +class Aws::S3::Types::GetObjectTorrentOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7605 +Aws::S3::Types::GetObjectTorrentOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTorrentRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7649 +class Aws::S3::Types::GetObjectTorrentRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7650 +Aws::S3::Types::GetObjectTorrentRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetPublicAccessBlockOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7662 +class Aws::S3::Types::GetPublicAccessBlockOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7663 +Aws::S3::Types::GetPublicAccessBlockOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetPublicAccessBlockRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7683 +class Aws::S3::Types::GetPublicAccessBlockRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7684 +Aws::S3::Types::GetPublicAccessBlockRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for S3 Glacier job parameters. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GlacierJobParameters AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7697 +class Aws::S3::Types::GlacierJobParameters < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7698 +Aws::S3::Types::GlacierJobParameters::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for grant information. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Grant AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7716 +class Aws::S3::Types::Grant < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7717 +Aws::S3::Types::Grant::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the person being granted permissions. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Grantee AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7779 +class Aws::S3::Types::Grantee < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7780 +Aws::S3::Types::Grantee::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadBucketOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7826 +class Aws::S3::Types::HeadBucketOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7827 +Aws::S3::Types::HeadBucketOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadBucketRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7895 +class Aws::S3::Types::HeadBucketRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#7896 +Aws::S3::Types::HeadBucketRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadObjectOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8314 +class Aws::S3::Types::HeadObjectOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8315 +Aws::S3::Types::HeadObjectOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadObjectRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8583 +class Aws::S3::Types::HeadObjectRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8584 +Aws::S3::Types::HeadObjectRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the `Suffix` element. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/IndexDocument AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8610 +class Aws::S3::Types::IndexDocument < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8611 +Aws::S3::Types::IndexDocument::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container element that identifies who initiated the multipart upload. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Initiator AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8641 +class Aws::S3::Types::Initiator < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8642 +Aws::S3::Types::Initiator::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the serialization format of the object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InputSerialization AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8671 +class Aws::S3::Types::InputSerialization < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8672 +Aws::S3::Types::InputSerialization::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for specifying S3 Intelligent-Tiering filters. The filters +# determine the subset of objects to which the rule applies. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/IntelligentTieringAndOperator AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8693 +class Aws::S3::Types::IntelligentTieringAndOperator < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8694 +Aws::S3::Types::IntelligentTieringAndOperator::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the S3 Intelligent-Tiering configuration for an Amazon S3 +# bucket. +# +# For information about the S3 Intelligent-Tiering storage class, see +# [Storage class for automatically optimizing frequently and +# infrequently accessed objects][1]. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html#sc-dynamic-data-access +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/IntelligentTieringConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8733 +class Aws::S3::Types::IntelligentTieringConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8734 +Aws::S3::Types::IntelligentTieringConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The `Filter` is used to identify objects that the S3 +# Intelligent-Tiering configuration applies to. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/IntelligentTieringFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8770 +class Aws::S3::Types::IntelligentTieringFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8771 +Aws::S3::Types::IntelligentTieringFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Object is archived and inaccessible until restored. +# +# If the object you are retrieving is stored in the S3 Glacier Flexible +# Retrieval storage class, the S3 Glacier Deep Archive storage class, +# the S3 Intelligent-Tiering Archive Access tier, or the S3 +# Intelligent-Tiering Deep Archive Access tier, before you can retrieve +# the object you must first restore a copy using [RestoreObject][1]. +# Otherwise, this operation returns an `InvalidObjectState` error. For +# information about restoring archived objects, see [Restoring Archived +# Objects][2] in the *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html +# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/restoring-objects.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InvalidObjectState AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8801 +class Aws::S3::Types::InvalidObjectState < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8802 +Aws::S3::Types::InvalidObjectState::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the inventory configuration for an Amazon S3 bucket. For +# more information, see [GET Bucket inventory][1] in the *Amazon S3 API +# Reference*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketGETInventoryConfig.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8859 +class Aws::S3::Types::InventoryConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8860 +Aws::S3::Types::InventoryConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the inventory configuration for an Amazon S3 bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryDestination AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8874 +class Aws::S3::Types::InventoryDestination < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8875 +Aws::S3::Types::InventoryDestination::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the type of server-side encryption used to encrypt the +# inventory results. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryEncryption AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8894 +class Aws::S3::Types::InventoryEncryption < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8895 +Aws::S3::Types::InventoryEncryption::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies an inventory filter. The inventory only includes objects +# that meet the filter's criteria. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8910 +class Aws::S3::Types::InventoryFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8911 +Aws::S3::Types::InventoryFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Contains the bucket name, file format, bucket owner (optional), and +# prefix (optional) where inventory results are published. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryS3BucketDestination AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8954 +class Aws::S3::Types::InventoryS3BucketDestination < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8955 +Aws::S3::Types::InventoryS3BucketDestination::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the schedule for generating inventory results. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventorySchedule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8968 +class Aws::S3::Types::InventorySchedule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8969 +Aws::S3::Types::InventorySchedule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies JSON as object's input serialization format. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/JSONInput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8982 +class Aws::S3::Types::JSONInput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8983 +Aws::S3::Types::JSONInput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies JSON as request's output serialization format. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/JSONOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8997 +class Aws::S3::Types::JSONOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#8998 +Aws::S3::Types::JSONOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for specifying the configuration for Lambda notifications. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LambdaFunctionConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9041 +class Aws::S3::Types::LambdaFunctionConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9042 +Aws::S3::Types::LambdaFunctionConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for lifecycle rules. You can add as many as 1000 rules. +# +# For more information see, [Managing your storage lifecycle][1] in the +# *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lifecycle-mgmt.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9062 +class Aws::S3::Types::LifecycleConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9063 +Aws::S3::Types::LifecycleConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the expiration for the lifecycle of the object. +# +# For more information see, [Managing your storage lifecycle][1] in the +# *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lifecycle-mgmt.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleExpiration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9099 +class Aws::S3::Types::LifecycleExpiration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9100 +Aws::S3::Types::LifecycleExpiration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A lifecycle rule for individual objects in an Amazon S3 bucket. +# +# For more information see, [Managing your storage lifecycle][1] in the +# *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lifecycle-mgmt.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9194 +class Aws::S3::Types::LifecycleRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9195 +Aws::S3::Types::LifecycleRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# This is used in a Lifecycle Rule Filter to apply a logical AND to two +# or more predicates. The Lifecycle Rule will apply to any object +# matching all of the predicates configured inside the And operator. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleRuleAndOperator AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9226 +class Aws::S3::Types::LifecycleRuleAndOperator < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9227 +Aws::S3::Types::LifecycleRuleAndOperator::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The `Filter` is used to identify objects that a Lifecycle Rule applies +# to. A `Filter` can have exactly one of `Prefix`, `Tag`, +# `ObjectSizeGreaterThan`, `ObjectSizeLessThan`, or `And` specified. If +# the `Filter` element is left empty, the Lifecycle Rule applies to all +# objects in the bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleRuleFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9275 +class Aws::S3::Types::LifecycleRuleFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9276 +Aws::S3::Types::LifecycleRuleFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketAnalyticsConfigurationsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9310 +class Aws::S3::Types::ListBucketAnalyticsConfigurationsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9311 +Aws::S3::Types::ListBucketAnalyticsConfigurationsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketAnalyticsConfigurationsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9337 +class Aws::S3::Types::ListBucketAnalyticsConfigurationsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9338 +Aws::S3::Types::ListBucketAnalyticsConfigurationsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketIntelligentTieringConfigurationsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9371 +class Aws::S3::Types::ListBucketIntelligentTieringConfigurationsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9372 +Aws::S3::Types::ListBucketIntelligentTieringConfigurationsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketIntelligentTieringConfigurationsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9390 +class Aws::S3::Types::ListBucketIntelligentTieringConfigurationsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9391 +Aws::S3::Types::ListBucketIntelligentTieringConfigurationsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketInventoryConfigurationsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9423 +class Aws::S3::Types::ListBucketInventoryConfigurationsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9424 +Aws::S3::Types::ListBucketInventoryConfigurationsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketInventoryConfigurationsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9452 +class Aws::S3::Types::ListBucketInventoryConfigurationsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9453 +Aws::S3::Types::ListBucketInventoryConfigurationsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketMetricsConfigurationsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9487 +class Aws::S3::Types::ListBucketMetricsConfigurationsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9488 +Aws::S3::Types::ListBucketMetricsConfigurationsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketMetricsConfigurationsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9516 +class Aws::S3::Types::ListBucketMetricsConfigurationsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9517 +Aws::S3::Types::ListBucketMetricsConfigurationsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9533 +class Aws::S3::Types::ListBucketsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9534 +Aws::S3::Types::ListBucketsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListDirectoryBucketsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9552 +class Aws::S3::Types::ListDirectoryBucketsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9553 +Aws::S3::Types::ListDirectoryBucketsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListDirectoryBucketsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9574 +class Aws::S3::Types::ListDirectoryBucketsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9575 +Aws::S3::Types::ListDirectoryBucketsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListMultipartUploadsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9703 +class Aws::S3::Types::ListMultipartUploadsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9704 +Aws::S3::Types::ListMultipartUploadsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListMultipartUploadsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9876 +class Aws::S3::Types::ListMultipartUploadsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9877 +Aws::S3::Types::ListMultipartUploadsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectVersionsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9982 +class Aws::S3::Types::ListObjectVersionsOutput < ::Struct + include ::Aws::Structure + + # TODO : Remove this customization once the resource code + # generator correct handles the JMESPath || expression. + # Only used by the Bucket#object_versions collection. + # + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/customizations/types/list_object_versions_output.rb#9 + def versions_delete_markers; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#9983 +Aws::S3::Types::ListObjectVersionsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectVersionsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10078 +class Aws::S3::Types::ListObjectVersionsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10079 +Aws::S3::Types::ListObjectVersionsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10181 +class Aws::S3::Types::ListObjectsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10182 +Aws::S3::Types::ListObjectsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10289 +class Aws::S3::Types::ListObjectsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10290 +Aws::S3::Types::ListObjectsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsV2Output AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10440 +class Aws::S3::Types::ListObjectsV2Output < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10441 +Aws::S3::Types::ListObjectsV2Output::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsV2Request AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10597 +class Aws::S3::Types::ListObjectsV2Request < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10598 +Aws::S3::Types::ListObjectsV2Request::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListPartsOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10733 +class Aws::S3::Types::ListPartsOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10734 +Aws::S3::Types::ListPartsOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListPartsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10883 +class Aws::S3::Types::ListPartsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10884 +Aws::S3::Types::ListPartsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the location where the bucket will be created. +# +# For directory buckets, the location type is Availability Zone. For +# more information about directory buckets, see [Directory buckets][1] +# in the *Amazon S3 User Guide*. +# +# This functionality is only supported by directory buckets. +# +# +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LocationInfo AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10918 +class Aws::S3::Types::LocationInfo < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10919 +Aws::S3::Types::LocationInfo::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes where logs are stored and the prefix that Amazon S3 assigns +# to all log object keys for a bucket. For more information, see [PUT +# Bucket logging][1] in the *Amazon S3 API Reference*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTlogging.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LoggingEnabled AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10970 +class Aws::S3::Types::LoggingEnabled < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10971 +Aws::S3::Types::LoggingEnabled::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A metadata key-value pair to store with an object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetadataEntry AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10989 +class Aws::S3::Types::MetadataEntry < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#10990 +Aws::S3::Types::MetadataEntry::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container specifying replication metrics-related settings enabling +# replication metrics and events. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Metrics AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11010 +class Aws::S3::Types::Metrics < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11011 +Aws::S3::Types::Metrics::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A conjunction (logical AND) of predicates, which is used in evaluating +# a metrics filter. The operator must have at least two predicates, and +# an object must match all of the predicates in order for the filter to +# apply. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetricsAndOperator AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11037 +class Aws::S3::Types::MetricsAndOperator < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11038 +Aws::S3::Types::MetricsAndOperator::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies a metrics configuration for the CloudWatch request metrics +# (specified by the metrics configuration ID) from an Amazon S3 bucket. +# If you're updating an existing metrics configuration, note that this +# is a full replacement of the existing metrics configuration. If you +# don't include the elements you want to keep, they are erased. For +# more information, see [PutBucketMetricsConfiguration][1]. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTMetricConfiguration.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetricsConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11070 +class Aws::S3::Types::MetricsConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11071 +Aws::S3::Types::MetricsConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies a metrics configuration filter. The metrics configuration +# only includes objects that meet the filter's criteria. A filter must +# be a prefix, an object tag, an access point ARN, or a conjunction +# (MetricsAndOperator). For more information, see +# [PutBucketMetricsConfiguration][1]. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketMetricsConfiguration.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetricsFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11110 +class Aws::S3::Types::MetricsFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11111 +Aws::S3::Types::MetricsFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the `MultipartUpload` for the Amazon S3 object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MultipartUpload AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11165 +class Aws::S3::Types::MultipartUpload < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11166 +Aws::S3::Types::MultipartUpload::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The specified bucket does not exist. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NoSuchBucket AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11174 +class Aws::S3::Types::NoSuchBucket < ::Aws::EmptyStructure; end + +# The specified key does not exist. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NoSuchKey AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11180 +class Aws::S3::Types::NoSuchKey < ::Aws::EmptyStructure; end + +# The specified multipart upload does not exist. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NoSuchUpload AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11186 +class Aws::S3::Types::NoSuchUpload < ::Aws::EmptyStructure; end + +# Specifies when noncurrent object versions expire. Upon expiration, +# Amazon S3 permanently deletes the noncurrent object versions. You set +# this lifecycle configuration action on a bucket that has versioning +# enabled (or suspended) to request that Amazon S3 delete noncurrent +# object versions at a specific period in the object's lifetime. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NoncurrentVersionExpiration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11223 +class Aws::S3::Types::NoncurrentVersionExpiration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11224 +Aws::S3::Types::NoncurrentVersionExpiration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the transition rule that describes when noncurrent +# objects transition to the `STANDARD_IA`, `ONEZONE_IA`, +# `INTELLIGENT_TIERING`, `GLACIER_IR`, `GLACIER`, or `DEEP_ARCHIVE` +# storage class. If your bucket is versioning-enabled (or versioning is +# suspended), you can set this action to request that Amazon S3 +# transition noncurrent object versions to the `STANDARD_IA`, +# `ONEZONE_IA`, `INTELLIGENT_TIERING`, `GLACIER_IR`, `GLACIER`, or +# `DEEP_ARCHIVE` storage class at a specific period in the object's +# lifetime. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NoncurrentVersionTransition AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11271 +class Aws::S3::Types::NoncurrentVersionTransition < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11272 +Aws::S3::Types::NoncurrentVersionTransition::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for specifying the notification configuration of the +# bucket. If this element is empty, notifications are turned off for the +# bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NotificationConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11305 +class Aws::S3::Types::NotificationConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11306 +Aws::S3::Types::NotificationConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NotificationConfigurationDeprecated AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11332 +class Aws::S3::Types::NotificationConfigurationDeprecated < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11333 +Aws::S3::Types::NotificationConfigurationDeprecated::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies object key name filtering rules. For information about key +# name filtering, see [Configuring event notifications using object key +# name filtering][1] in the *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/notification-how-to-filtering.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NotificationConfigurationFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11352 +class Aws::S3::Types::NotificationConfigurationFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11353 +Aws::S3::Types::NotificationConfigurationFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# An object consists of data and its descriptive metadata. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Object AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11451 +class Aws::S3::Types::Object < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11452 +Aws::S3::Types::Object::SENSITIVE = T.let(T.unsafe(nil), Array) + +# This action is not allowed against this storage tier. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectAlreadyInActiveTierError AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11460 +class Aws::S3::Types::ObjectAlreadyInActiveTierError < ::Aws::EmptyStructure; end + +# Object Identifier is unique value to identify objects. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectIdentifier AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11488 +class Aws::S3::Types::ObjectIdentifier < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11489 +Aws::S3::Types::ObjectIdentifier::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container element for Object Lock configuration parameters. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectLockConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11513 +class Aws::S3::Types::ObjectLockConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11514 +Aws::S3::Types::ObjectLockConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A legal hold configuration for an object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectLockLegalHold AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11527 +class Aws::S3::Types::ObjectLockLegalHold < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11528 +Aws::S3::Types::ObjectLockLegalHold::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A Retention configuration for an object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectLockRetention AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11546 +class Aws::S3::Types::ObjectLockRetention < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11547 +Aws::S3::Types::ObjectLockRetention::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container element for an Object Lock rule. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectLockRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11564 +class Aws::S3::Types::ObjectLockRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11565 +Aws::S3::Types::ObjectLockRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The source object of the COPY action is not in the active tier and is +# only stored in Amazon S3 Glacier. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectNotInActiveTierError AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11574 +class Aws::S3::Types::ObjectNotInActiveTierError < ::Aws::EmptyStructure; end + +# A container for elements related to an individual part. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectPart AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11652 +class Aws::S3::Types::ObjectPart < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11653 +Aws::S3::Types::ObjectPart::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The version of an object. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectVersion AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11720 +class Aws::S3::Types::ObjectVersion < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11721 +Aws::S3::Types::ObjectVersion::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the location where the restore job's output is stored. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/OutputLocation AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11735 +class Aws::S3::Types::OutputLocation < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11736 +Aws::S3::Types::OutputLocation::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes how results of the Select job are serialized. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/OutputSerialization AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11754 +class Aws::S3::Types::OutputSerialization < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11755 +Aws::S3::Types::OutputSerialization::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the owner's display name and ID. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Owner AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11794 +class Aws::S3::Types::Owner < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11795 +Aws::S3::Types::Owner::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container element for a bucket's ownership controls. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/OwnershipControls AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11808 +class Aws::S3::Types::OwnershipControls < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11809 +Aws::S3::Types::OwnershipControls::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container element for an ownership control rule. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/OwnershipControlsRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11855 +class Aws::S3::Types::OwnershipControlsRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11856 +Aws::S3::Types::OwnershipControlsRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for Parquet. +# +# @api private +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ParquetInput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11866 +class Aws::S3::Types::ParquetInput < ::Aws::EmptyStructure; end + +# Container for elements related to a part. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Part AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11951 +class Aws::S3::Types::Part < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11952 +Aws::S3::Types::Part::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Amazon S3 keys for log objects are partitioned in the following +# format: +# +# `[DestinationPrefix][SourceAccountId]/[SourceRegion]/[SourceBucket]/[YYYY]/[MM]/[DD]/[YYYY]-[MM]-[DD]-[hh]-[mm]-[ss]-[UniqueString]` +# +# PartitionedPrefix defaults to EventTime delivery when server access +# logs are delivered. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PartitionedPrefix AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11972 +class Aws::S3::Types::PartitionedPrefix < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11973 +Aws::S3::Types::PartitionedPrefix::SENSITIVE = T.let(T.unsafe(nil), Array) + +# This error is not modeled. +# +# The bucket you are attempting to access must be addressed using the +# specified endpoint. Please send all future requests to this endpoint. +# +# source://aws-sdk-s3//lib/aws-sdk-s3/customizations/types/permanent_redirect.rb#20 +class Aws::S3::Types::PermanentRedirect < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/customizations/types/permanent_redirect.rb#21 +Aws::S3::Types::PermanentRedirect::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container element for a bucket's policy status. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PolicyStatus AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11987 +class Aws::S3::Types::PolicyStatus < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#11988 +Aws::S3::Types::PolicyStatus::SENSITIVE = T.let(T.unsafe(nil), Array) + +# This data type contains information about progress of an operation. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Progress AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12011 +class Aws::S3::Types::Progress < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12012 +Aws::S3::Types::Progress::SENSITIVE = T.let(T.unsafe(nil), Array) + +# This data type contains information about the progress event of an +# operation. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ProgressEvent AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12027 +class Aws::S3::Types::ProgressEvent < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12028 +Aws::S3::Types::ProgressEvent::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The PublicAccessBlock configuration that you want to apply to this +# Amazon S3 bucket. You can enable the configuration options in any +# combination. For more information about when Amazon S3 considers a +# bucket or object public, see [The Meaning of "Public"][1] in the +# *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PublicAccessBlockConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12094 +class Aws::S3::Types::PublicAccessBlockConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12095 +Aws::S3::Types::PublicAccessBlockConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAccelerateConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12138 +class Aws::S3::Types::PutBucketAccelerateConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12139 +Aws::S3::Types::PutBucketAccelerateConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAclRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12232 +class Aws::S3::Types::PutBucketAclRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12233 +Aws::S3::Types::PutBucketAclRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAnalyticsConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12263 +class Aws::S3::Types::PutBucketAnalyticsConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12264 +Aws::S3::Types::PutBucketAnalyticsConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketCorsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12328 +class Aws::S3::Types::PutBucketCorsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12329 +Aws::S3::Types::PutBucketCorsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketEncryptionRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12393 +class Aws::S3::Types::PutBucketEncryptionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12394 +Aws::S3::Types::PutBucketEncryptionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketIntelligentTieringConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12416 +class Aws::S3::Types::PutBucketIntelligentTieringConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12417 +Aws::S3::Types::PutBucketIntelligentTieringConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketInventoryConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12447 +class Aws::S3::Types::PutBucketInventoryConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12448 +Aws::S3::Types::PutBucketInventoryConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12490 +class Aws::S3::Types::PutBucketLifecycleConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12491 +Aws::S3::Types::PutBucketLifecycleConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12538 +class Aws::S3::Types::PutBucketLifecycleRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12539 +Aws::S3::Types::PutBucketLifecycleRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLoggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12590 +class Aws::S3::Types::PutBucketLoggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12591 +Aws::S3::Types::PutBucketLoggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketMetricsConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12622 +class Aws::S3::Types::PutBucketMetricsConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12623 +Aws::S3::Types::PutBucketMetricsConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12655 +class Aws::S3::Types::PutBucketNotificationConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12656 +Aws::S3::Types::PutBucketNotificationConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12707 +class Aws::S3::Types::PutBucketNotificationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12708 +Aws::S3::Types::PutBucketNotificationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketOwnershipControlsRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12743 +class Aws::S3::Types::PutBucketOwnershipControlsRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12744 +Aws::S3::Types::PutBucketOwnershipControlsRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketPolicyRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12855 +class Aws::S3::Types::PutBucketPolicyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12856 +Aws::S3::Types::PutBucketPolicyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketReplicationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12920 +class Aws::S3::Types::PutBucketReplicationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12921 +Aws::S3::Types::PutBucketReplicationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketRequestPaymentRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12979 +class Aws::S3::Types::PutBucketRequestPaymentRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#12980 +Aws::S3::Types::PutBucketRequestPaymentRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketTaggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13038 +class Aws::S3::Types::PutBucketTaggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13039 +Aws::S3::Types::PutBucketTaggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketVersioningRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13104 +class Aws::S3::Types::PutBucketVersioningRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13105 +Aws::S3::Types::PutBucketVersioningRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketWebsiteRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13163 +class Aws::S3::Types::PutBucketWebsiteRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13164 +Aws::S3::Types::PutBucketWebsiteRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectAclOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13180 +class Aws::S3::Types::PutObjectAclOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13181 +Aws::S3::Types::PutObjectAclOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectAclRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13346 +class Aws::S3::Types::PutObjectAclRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13347 +Aws::S3::Types::PutObjectAclRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectLegalHoldOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13363 +class Aws::S3::Types::PutObjectLegalHoldOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13364 +Aws::S3::Types::PutObjectLegalHoldOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectLegalHoldRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13461 +class Aws::S3::Types::PutObjectLegalHoldRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13462 +Aws::S3::Types::PutObjectLegalHoldRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectLockConfigurationOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13478 +class Aws::S3::Types::PutObjectLockConfigurationOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13479 +Aws::S3::Types::PutObjectLockConfigurationOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectLockConfigurationRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13556 +class Aws::S3::Types::PutObjectLockConfigurationRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13557 +Aws::S3::Types::PutObjectLockConfigurationRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13763 +class Aws::S3::Types::PutObjectOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#13764 +Aws::S3::Types::PutObjectOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14343 +class Aws::S3::Types::PutObjectRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14344 +Aws::S3::Types::PutObjectRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectRetentionOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14360 +class Aws::S3::Types::PutObjectRetentionOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14361 +Aws::S3::Types::PutObjectRetentionOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectRetentionRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14465 +class Aws::S3::Types::PutObjectRetentionRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14466 +Aws::S3::Types::PutObjectRetentionRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectTaggingOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14477 +class Aws::S3::Types::PutObjectTaggingOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14478 +Aws::S3::Types::PutObjectTaggingOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectTaggingRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14583 +class Aws::S3::Types::PutObjectTaggingRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14584 +Aws::S3::Types::PutObjectTaggingRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutPublicAccessBlockRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14644 +class Aws::S3::Types::PutPublicAccessBlockRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14645 +Aws::S3::Types::PutPublicAccessBlockRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the configuration for publishing messages to an Amazon +# Simple Queue Service (Amazon SQS) queue when Amazon S3 detects +# specified events. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/QueueConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14685 +class Aws::S3::Types::QueueConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14686 +Aws::S3::Types::QueueConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# This data type is deprecated. Use [QueueConfiguration][1] for the same +# purposes. This data type specifies the configuration for publishing +# messages to an Amazon Simple Queue Service (Amazon SQS) queue when +# Amazon S3 detects specified events. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_QueueConfiguration.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/QueueConfigurationDeprecated AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14725 +class Aws::S3::Types::QueueConfigurationDeprecated < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14726 +Aws::S3::Types::QueueConfigurationDeprecated::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container for the records event. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RecordsEvent AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14740 +class Aws::S3::Types::RecordsEvent < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14741 +Aws::S3::Types::RecordsEvent::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies how requests are redirected. In the event of an error, you +# can specify a different error code to return. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Redirect AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14802 +class Aws::S3::Types::Redirect < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14803 +Aws::S3::Types::Redirect::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the redirect behavior of all requests to a website endpoint +# of an Amazon S3 bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RedirectAllRequestsTo AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14823 +class Aws::S3::Types::RedirectAllRequestsTo < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14824 +Aws::S3::Types::RedirectAllRequestsTo::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A filter that you can specify for selection for modifications on +# replicas. Amazon S3 doesn't replicate replica modifications by +# default. In the latest version of replication configuration (when +# `Filter` is specified), you can specify this element and set the +# status to `Enabled` to replicate modifications on replicas. +# +# If you don't specify the `Filter` element, Amazon S3 assumes that the +# replication configuration is the earlier version, V1. In the earlier +# version, this element is not allowed. +# +# +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicaModifications AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14847 +class Aws::S3::Types::ReplicaModifications < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14848 +Aws::S3::Types::ReplicaModifications::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for replication rules. You can add up to 1,000 rules. The +# maximum size of a replication configuration is 2 MB. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14876 +class Aws::S3::Types::ReplicationConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14877 +Aws::S3::Types::ReplicationConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies which Amazon S3 objects to replicate and where to store the +# replicas. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14991 +class Aws::S3::Types::ReplicationRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#14992 +Aws::S3::Types::ReplicationRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for specifying rule filters. The filters determine the +# subset of objects to which the rule applies. This element is required +# only if you specify more than one filter. +# +# For example: +# +# * If you specify both a `Prefix` and a `Tag` filter, wrap these +# filters in an `And` tag. +# +# * If you specify a filter based on multiple tags, wrap the `Tag` +# elements in an `And` tag. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationRuleAndOperator AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15021 +class Aws::S3::Types::ReplicationRuleAndOperator < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15022 +Aws::S3::Types::ReplicationRuleAndOperator::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A filter that identifies the subset of objects to which the +# replication rule applies. A `Filter` must specify exactly one +# `Prefix`, `Tag`, or an `And` child element. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationRuleFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15066 +class Aws::S3::Types::ReplicationRuleFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15067 +Aws::S3::Types::ReplicationRuleFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container specifying S3 Replication Time Control (S3 RTC) related +# information, including whether S3 RTC is enabled and the time when all +# objects and operations on objects must be replicated. Must be +# specified together with a `Metrics` block. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationTime AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15089 +class Aws::S3::Types::ReplicationTime < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15090 +Aws::S3::Types::ReplicationTime::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container specifying the time value for S3 Replication Time Control +# (S3 RTC) and replication metrics `EventThreshold`. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationTimeValue AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15106 +class Aws::S3::Types::ReplicationTimeValue < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15107 +Aws::S3::Types::ReplicationTimeValue::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for Payer. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RequestPaymentConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15120 +class Aws::S3::Types::RequestPaymentConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15121 +Aws::S3::Types::RequestPaymentConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for specifying if periodic `QueryProgress` messages should +# be sent. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RequestProgress AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15136 +class Aws::S3::Types::RequestProgress < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15137 +Aws::S3::Types::RequestProgress::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreObjectOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15159 +class Aws::S3::Types::RestoreObjectOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15160 +Aws::S3::Types::RestoreObjectOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreObjectRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15256 +class Aws::S3::Types::RestoreObjectRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15257 +Aws::S3::Types::RestoreObjectRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for restore job parameters. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15305 +class Aws::S3::Types::RestoreRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15306 +Aws::S3::Types::RestoreRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the restoration status of an object. Objects in certain +# storage classes must be restored before they can be retrieved. For +# more information about these storage classes and how to work with +# archived objects, see [ Working with archived objects][1] in the +# *Amazon S3 User Guide*. +# +# This functionality is not supported for directory buckets. Only the S3 +# Express One Zone storage class is supported by directory buckets to +# store objects. +# +# +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/archived-objects.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreStatus AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15354 +class Aws::S3::Types::RestoreStatus < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15355 +Aws::S3::Types::RestoreStatus::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the redirect behavior and when a redirect is applied. For +# more information about routing rules, see [Configuring advanced +# conditional redirects][1] in the *Amazon S3 User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html#advanced-conditional-redirects +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RoutingRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15385 +class Aws::S3::Types::RoutingRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15386 +Aws::S3::Types::RoutingRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies lifecycle rules for an Amazon S3 bucket. For more +# information, see [Put Bucket Lifecycle Configuration][1] in the +# *Amazon S3 API Reference*. For examples, see [Put Bucket Lifecycle +# Configuration Examples][2]. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTlifecycle.html +# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html#API_PutBucketLifecycleConfiguration_Examples +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Rule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15481 +class Aws::S3::Types::Rule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15482 +Aws::S3::Types::Rule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for object key name prefix and suffix filtering rules. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/S3KeyFilter AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15496 +class Aws::S3::Types::S3KeyFilter < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15497 +Aws::S3::Types::S3KeyFilter::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes an Amazon S3 location that will receive the results of the +# restore request. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/S3Location AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15547 +class Aws::S3::Types::S3Location < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15548 +Aws::S3::Types::S3Location::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the use of SSE-KMS to encrypt delivered inventory reports. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SSEKMS AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15563 +class Aws::S3::Types::SSEKMS < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15564 +Aws::S3::Types::SSEKMS::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the use of SSE-S3 to encrypt delivered inventory reports. +# +# @api private +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SSES3 AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15574 +class Aws::S3::Types::SSES3 < ::Aws::EmptyStructure; end + +# Specifies the byte range of the object to get the records from. A +# record is processed when its first byte is contained by the range. +# This parameter is optional, but when specified, it must not be empty. +# See RFC 2616, Section 14.35.1 about how to specify the start and end +# of the range. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ScanRange AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15603 +class Aws::S3::Types::ScanRange < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15604 +Aws::S3::Types::ScanRange::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The container for selecting objects from a content event stream. +# +# EventStream is an Enumerator of Events. +# #event_types #=> Array, returns all modeled event types in the stream +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SelectObjectContentEventStream AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17510 +class Aws::S3::Types::SelectObjectContentEventStream < ::Enumerator + # source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17512 + def event_types; end +end + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SelectObjectContentOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15615 +class Aws::S3::Types::SelectObjectContentOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15616 +Aws::S3::Types::SelectObjectContentOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Request to filter the contents of an Amazon S3 object based on a +# simple Structured Query Language (SQL) statement. In the request, +# along with the SQL expression, you must specify a data serialization +# format (JSON or CSV) of the object. Amazon S3 uses this to parse +# object data into records. It returns only records that match the +# specified SQL expression. You must also specify the data serialization +# format for the response. For more information, see [S3Select API +# Documentation][1]. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTObjectSELECTContent.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SelectObjectContentRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15738 +class Aws::S3::Types::SelectObjectContentRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15739 +Aws::S3::Types::SelectObjectContentRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the parameters for Select job types. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SelectParameters AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15767 +class Aws::S3::Types::SelectParameters < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15768 +Aws::S3::Types::SelectParameters::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the default server-side encryption to apply to new objects +# in the bucket. If a PUT Object request doesn't specify any +# server-side encryption, this default encryption will be applied. If +# you don't specify a customer managed key at configuration, Amazon S3 +# automatically creates an Amazon Web Services KMS key in your Amazon +# Web Services account the first time that you add an object encrypted +# with SSE-KMS to a bucket. By default, Amazon S3 uses this KMS key for +# SSE-KMS. For more information, see [PUT Bucket encryption][1] in the +# *Amazon S3 API Reference*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTencryption.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ServerSideEncryptionByDefault AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15828 +class Aws::S3::Types::ServerSideEncryptionByDefault < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15829 +Aws::S3::Types::ServerSideEncryptionByDefault::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the default server-side-encryption configuration. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ServerSideEncryptionConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15843 +class Aws::S3::Types::ServerSideEncryptionConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15844 +Aws::S3::Types::ServerSideEncryptionConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies the default server-side encryption configuration. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ServerSideEncryptionRule AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15875 +class Aws::S3::Types::ServerSideEncryptionRule < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15876 +Aws::S3::Types::ServerSideEncryptionRule::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The established temporary security credentials of the session. +# +# **Directory buckets** - These session credentials are only supported +# for the authentication and authorization of Zonal endpoint APIs on +# directory buckets. +# +# +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SessionCredentials AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15919 +class Aws::S3::Types::SessionCredentials < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15920 +Aws::S3::Types::SessionCredentials::SENSITIVE = T.let(T.unsafe(nil), Array) + +# To use simple format for S3 keys for log objects, set SimplePrefix to +# an empty object. +# +# `[DestinationPrefix][YYYY]-[MM]-[DD]-[hh]-[mm]-[ss]-[UniqueString]` +# +# @api private +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SimplePrefix AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15933 +class Aws::S3::Types::SimplePrefix < ::Aws::EmptyStructure; end + +# A container that describes additional filters for identifying the +# source objects that you want to replicate. You can choose to enable or +# disable the replication of these objects. Currently, Amazon S3 +# supports only the filter that you can specify for objects created with +# server-side encryption using a customer managed key stored in Amazon +# Web Services Key Management Service (SSE-KMS). +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SourceSelectionCriteria AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15967 +class Aws::S3::Types::SourceSelectionCriteria < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15968 +Aws::S3::Types::SourceSelectionCriteria::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for filter information for the selection of S3 objects +# encrypted with Amazon Web Services KMS. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SseKmsEncryptedObjects AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15984 +class Aws::S3::Types::SseKmsEncryptedObjects < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#15985 +Aws::S3::Types::SseKmsEncryptedObjects::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the stats details. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Stats AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16008 +class Aws::S3::Types::Stats < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16009 +Aws::S3::Types::Stats::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for the Stats Event. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/StatsEvent AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16023 +class Aws::S3::Types::StatsEvent < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16024 +Aws::S3::Types::StatsEvent::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies data related to access patterns to be collected and made +# available to analyze the tradeoffs between different storage classes +# for an Amazon S3 bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/StorageClassAnalysis AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16040 +class Aws::S3::Types::StorageClassAnalysis < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16041 +Aws::S3::Types::StorageClassAnalysis::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for data related to the storage class analysis for an Amazon +# S3 bucket for export. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/StorageClassAnalysisDataExport AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16061 +class Aws::S3::Types::StorageClassAnalysisDataExport < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16062 +Aws::S3::Types::StorageClassAnalysisDataExport::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container of a key value name pair. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Tag AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16080 +class Aws::S3::Types::Tag < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16081 +Aws::S3::Types::Tag::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for `TagSet` elements. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Tagging AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16094 +class Aws::S3::Types::Tagging < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16095 +Aws::S3::Types::Tagging::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Container for granting information. +# +# Buckets that use the bucket owner enforced setting for Object +# Ownership don't support target grants. For more information, see +# [Permissions server access log delivery][1] in the *Amazon S3 User +# Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/enable-server-access-logging.html#grant-log-delivery-permissions-general +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/TargetGrant AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16122 +class Aws::S3::Types::TargetGrant < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16123 +Aws::S3::Types::TargetGrant::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Amazon S3 key format for log objects. Only one format, +# PartitionedPrefix or SimplePrefix, is allowed. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/TargetObjectKeyFormat AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16143 +class Aws::S3::Types::TargetObjectKeyFormat < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16144 +Aws::S3::Types::TargetObjectKeyFormat::SENSITIVE = T.let(T.unsafe(nil), Array) + +# The S3 Intelligent-Tiering storage class is designed to optimize +# storage costs by automatically moving data to the most cost-effective +# storage access tier, without additional operational overhead. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Tiering AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16175 +class Aws::S3::Types::Tiering < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16176 +Aws::S3::Types::Tiering::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for specifying the configuration for publication of +# messages to an Amazon Simple Notification Service (Amazon SNS) topic +# when Amazon S3 detects specified events. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/TopicConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16222 +class Aws::S3::Types::TopicConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16223 +Aws::S3::Types::TopicConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# A container for specifying the configuration for publication of +# messages to an Amazon Simple Notification Service (Amazon SNS) topic +# when Amazon S3 detects specified events. This data type is deprecated. +# Use [TopicConfiguration][1] instead. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_TopicConfiguration.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/TopicConfigurationDeprecated AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16261 +class Aws::S3::Types::TopicConfigurationDeprecated < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16262 +Aws::S3::Types::TopicConfigurationDeprecated::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies when an object transitions to a specified storage class. For +# more information about Amazon S3 lifecycle configuration rules, see +# [Transitioning Objects Using Amazon S3 Lifecycle][1] in the *Amazon S3 +# User Guide*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/lifecycle-transition-general-considerations.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Transition AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16296 +class Aws::S3::Types::Transition < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16297 +Aws::S3::Types::Transition::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartCopyOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16385 +class Aws::S3::Types::UploadPartCopyOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16386 +Aws::S3::Types::UploadPartCopyOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartCopyRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16706 +class Aws::S3::Types::UploadPartCopyRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16707 +Aws::S3::Types::UploadPartCopyRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartOutput AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16848 +class Aws::S3::Types::UploadPartOutput < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#16849 +Aws::S3::Types::UploadPartOutput::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17076 +class Aws::S3::Types::UploadPartRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17077 +Aws::S3::Types::UploadPartRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Describes the versioning state of an Amazon S3 bucket. For more +# information, see [PUT Bucket versioning][1] in the *Amazon S3 API +# Reference*. +# +# +# +# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTVersioningStatus.html +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/VersioningConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17104 +class Aws::S3::Types::VersioningConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17105 +Aws::S3::Types::VersioningConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Specifies website configuration parameters for an Amazon S3 bucket. +# +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/WebsiteConfiguration AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17137 +class Aws::S3::Types::WebsiteConfiguration < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17138 +Aws::S3::Types::WebsiteConfiguration::SENSITIVE = T.let(T.unsafe(nil), Array) + +# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/WriteGetObjectResponseRequest AWS API Documentation +# +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17498 +class Aws::S3::Types::WriteGetObjectResponseRequest < ::Struct + include ::Aws::Structure +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/types.rb#17499 +Aws::S3::Types::WriteGetObjectResponseRequest::SENSITIVE = T.let(T.unsafe(nil), Array) + +# Waiters are utility methods that poll for a particular state to occur +# on a client. Waiters can fail after a number of attempts at a polling +# interval defined for the service client. +# +# For a list of operations that can be waited for and the +# client methods called for each operation, see the table below or the +# {Client#wait_until} field documentation for the {Client}. +# +# # Invoking a Waiter +# To invoke a waiter, call #wait_until on a {Client}. The first parameter +# is the waiter name, which is specific to the service client and indicates +# which operation is being waited for. The second parameter is a hash of +# parameters that are passed to the client method called by the waiter, +# which varies according to the waiter name. +# +# # Wait Failures +# To catch errors in a waiter, use WaiterFailed, +# as shown in the following example. +# +# rescue rescue Aws::Waiters::Errors::WaiterFailed => error +# puts "failed waiting for instance running: #{error.message} +# end +# +# # Configuring a Waiter +# Each waiter has a default polling interval and a maximum number of +# attempts it will make before returning control to your program. +# To set these values, use the `max_attempts` and `delay` parameters +# in your `#wait_until` call. +# The following example waits for up to 25 seconds, polling every five seconds. +# +# client.wait_until(...) do |w| +# w.max_attempts = 5 +# w.delay = 5 +# end +# +# To disable wait failures, set the value of either of these parameters +# to `nil`. +# +# # Extending a Waiter +# To modify the behavior of waiters, you can register callbacks that are +# triggered before each polling attempt and before waiting. +# +# The following example implements an exponential backoff in a waiter +# by doubling the amount of time to wait on every attempt. +# +# client.wait_until(...) do |w| +# w.interval = 0 # disable normal sleep +# w.before_wait do |n, resp| +# sleep(n ** 2) +# end +# end +# +# # Available Waiters +# +# The following table lists the valid waiter names, the operations they call, +# and the default `:delay` and `:max_attempts` values. +# +# | waiter_name | params | :delay | :max_attempts | +# | ----------------- | -------------------- | -------- | ------------- | +# | bucket_exists | {Client#head_bucket} | 5 | 20 | +# | bucket_not_exists | {Client#head_bucket} | 5 | 20 | +# | object_exists | {Client#head_object} | 5 | 20 | +# | object_not_exists | {Client#head_object} | 5 | 20 | +# +# source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#77 +module Aws::S3::Waiters; end + +# source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#79 +class Aws::S3::Waiters::BucketExists + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [BucketExists] a new instance of BucketExists + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#87 + def initialize(options); end + + # @option params + # @option params + # @param params [Hash] a customizable set of options + # @return [Types::HeadBucketOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::HeadBucketOutput#bucket_location_type #bucket_location_type} => String + # * {Types::HeadBucketOutput#bucket_location_name #bucket_location_name} => String + # * {Types::HeadBucketOutput#bucket_region #bucket_region} => String + # * {Types::HeadBucketOutput#access_point_alias #access_point_alias} => Boolean + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#122 + def wait(params = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#127 + def waiter; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#131 +class Aws::S3::Waiters::BucketNotExists + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [BucketNotExists] a new instance of BucketNotExists + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#139 + def initialize(options); end + + # @option params + # @option params + # @param params [Hash] a customizable set of options + # @return [Types::HeadBucketOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::HeadBucketOutput#bucket_location_type #bucket_location_type} => String + # * {Types::HeadBucketOutput#bucket_location_name #bucket_location_name} => String + # * {Types::HeadBucketOutput#bucket_region #bucket_region} => String + # * {Types::HeadBucketOutput#access_point_alias #access_point_alias} => Boolean + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#157 + def wait(params = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#162 + def waiter; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#166 +class Aws::S3::Waiters::ObjectExists + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [ObjectExists] a new instance of ObjectExists + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#174 + def initialize(options); end + + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param params [Hash] a customizable set of options + # @return [Types::HeadObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::HeadObjectOutput#delete_marker #delete_marker} => Boolean + # * {Types::HeadObjectOutput#accept_ranges #accept_ranges} => String + # * {Types::HeadObjectOutput#expiration #expiration} => String + # * {Types::HeadObjectOutput#restore #restore} => String + # * {Types::HeadObjectOutput#archive_status #archive_status} => String + # * {Types::HeadObjectOutput#last_modified #last_modified} => Time + # * {Types::HeadObjectOutput#content_length #content_length} => Integer + # * {Types::HeadObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::HeadObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::HeadObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::HeadObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::HeadObjectOutput#etag #etag} => String + # * {Types::HeadObjectOutput#missing_meta #missing_meta} => Integer + # * {Types::HeadObjectOutput#version_id #version_id} => String + # * {Types::HeadObjectOutput#cache_control #cache_control} => String + # * {Types::HeadObjectOutput#content_disposition #content_disposition} => String + # * {Types::HeadObjectOutput#content_encoding #content_encoding} => String + # * {Types::HeadObjectOutput#content_language #content_language} => String + # * {Types::HeadObjectOutput#content_type #content_type} => String + # * {Types::HeadObjectOutput#expires #expires} => Time + # * {Types::HeadObjectOutput#expires_string #expires_string} => String + # * {Types::HeadObjectOutput#website_redirect_location #website_redirect_location} => String + # * {Types::HeadObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::HeadObjectOutput#metadata #metadata} => Hash<String,String> + # * {Types::HeadObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::HeadObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::HeadObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::HeadObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::HeadObjectOutput#storage_class #storage_class} => String + # * {Types::HeadObjectOutput#request_charged #request_charged} => String + # * {Types::HeadObjectOutput#replication_status #replication_status} => String + # * {Types::HeadObjectOutput#parts_count #parts_count} => Integer + # * {Types::HeadObjectOutput#object_lock_mode #object_lock_mode} => String + # * {Types::HeadObjectOutput#object_lock_retain_until_date #object_lock_retain_until_date} => Time + # * {Types::HeadObjectOutput#object_lock_legal_hold_status #object_lock_legal_hold_status} => String + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#199 + def wait(params = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#204 + def waiter; end +end + +# source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#208 +class Aws::S3::Waiters::ObjectNotExists + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] + # @return [ObjectNotExists] a new instance of ObjectNotExists + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#216 + def initialize(options); end + + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @option params + # @param params [Hash] a customizable set of options + # @return [Types::HeadObjectOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::HeadObjectOutput#delete_marker #delete_marker} => Boolean + # * {Types::HeadObjectOutput#accept_ranges #accept_ranges} => String + # * {Types::HeadObjectOutput#expiration #expiration} => String + # * {Types::HeadObjectOutput#restore #restore} => String + # * {Types::HeadObjectOutput#archive_status #archive_status} => String + # * {Types::HeadObjectOutput#last_modified #last_modified} => Time + # * {Types::HeadObjectOutput#content_length #content_length} => Integer + # * {Types::HeadObjectOutput#checksum_crc32 #checksum_crc32} => String + # * {Types::HeadObjectOutput#checksum_crc32c #checksum_crc32c} => String + # * {Types::HeadObjectOutput#checksum_sha1 #checksum_sha1} => String + # * {Types::HeadObjectOutput#checksum_sha256 #checksum_sha256} => String + # * {Types::HeadObjectOutput#etag #etag} => String + # * {Types::HeadObjectOutput#missing_meta #missing_meta} => Integer + # * {Types::HeadObjectOutput#version_id #version_id} => String + # * {Types::HeadObjectOutput#cache_control #cache_control} => String + # * {Types::HeadObjectOutput#content_disposition #content_disposition} => String + # * {Types::HeadObjectOutput#content_encoding #content_encoding} => String + # * {Types::HeadObjectOutput#content_language #content_language} => String + # * {Types::HeadObjectOutput#content_type #content_type} => String + # * {Types::HeadObjectOutput#expires #expires} => Time + # * {Types::HeadObjectOutput#expires_string #expires_string} => String + # * {Types::HeadObjectOutput#website_redirect_location #website_redirect_location} => String + # * {Types::HeadObjectOutput#server_side_encryption #server_side_encryption} => String + # * {Types::HeadObjectOutput#metadata #metadata} => Hash<String,String> + # * {Types::HeadObjectOutput#sse_customer_algorithm #sse_customer_algorithm} => String + # * {Types::HeadObjectOutput#sse_customer_key_md5 #sse_customer_key_md5} => String + # * {Types::HeadObjectOutput#ssekms_key_id #ssekms_key_id} => String + # * {Types::HeadObjectOutput#bucket_key_enabled #bucket_key_enabled} => Boolean + # * {Types::HeadObjectOutput#storage_class #storage_class} => String + # * {Types::HeadObjectOutput#request_charged #request_charged} => String + # * {Types::HeadObjectOutput#replication_status #replication_status} => String + # * {Types::HeadObjectOutput#parts_count #parts_count} => Integer + # * {Types::HeadObjectOutput#object_lock_mode #object_lock_mode} => String + # * {Types::HeadObjectOutput#object_lock_retain_until_date #object_lock_retain_until_date} => Time + # * {Types::HeadObjectOutput#object_lock_legal_hold_status #object_lock_legal_hold_status} => String + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#234 + def wait(params = T.unsafe(nil)); end + + # @api private + # + # source://aws-sdk-s3//lib/aws-sdk-s3/waiters.rb#239 + def waiter; end +end diff --git a/sorbet/rbi/gems/aws-sigv4@1.9.1.rbi b/sorbet/rbi/gems/aws-sigv4@1.9.1.rbi new file mode 100644 index 000000000..4bf628a32 --- /dev/null +++ b/sorbet/rbi/gems/aws-sigv4@1.9.1.rbi @@ -0,0 +1,664 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `aws-sigv4` gem. +# Please instead update this file by running `bin/tapioca gem aws-sigv4`. + + +# source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#3 +module Aws + class << self + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#138 + def config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#141 + def config=(config); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#200 + def eager_autoload!(*args); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#193 + def empty_connection_pools!; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#150 + def partition(partition_name); end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#155 + def partitions; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#131 + def shared_config; end + + # source://aws-sdk-core/3.201.4/lib/aws-sdk-core.rb#170 + def use_bundled_cert!; end + end +end + +# source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#4 +module Aws::Sigv4; end + +# To make it easier to support mixed mode, we have created an asymmetric +# key derivation mechanism. This module derives +# asymmetric keys from the current secret for use with +# Asymmetric signatures. +# +# @api private +# +# source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#10 +module Aws::Sigv4::AsymmetricCredentials + class << self + # unsigned integer. + # + # @api private + # @return [Number] The value of the bytes interpreted as a big-endian + # + # source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#57 + def be_bytes_to_num(bytes); end + + # @api private + # + # source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#80 + def check_openssl_support!; end + + # @api private + # @param :access_key_id [String] + # @param :secret_access_key [String] + # @return [OpenSSL::PKey::EC, Hash] + # + # source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#17 + def derive_asymmetric_key(access_key_id, secret_access_key); end + + # Prior to openssl3 we could directly set public and private key on EC + # However, openssl3 deprecated those methods and we must now construct + # a der with the keys and load the EC from it. + # + # @api private + # + # source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#66 + def generate_ec(public_key, d); end + end +end + +# @api private +# +# source://aws-sigv4//lib/aws-sigv4/asymmetric_credentials.rb#12 +Aws::Sigv4::AsymmetricCredentials::N_MINUS_2 = T.let(T.unsafe(nil), Integer) + +# Users that wish to configure static credentials can use the +# `:access_key_id` and `:secret_access_key` constructor options. +# +# @api private +# +# source://aws-sigv4//lib/aws-sigv4/credentials.rb#8 +class Aws::Sigv4::Credentials + # @api private + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Credentials] a new instance of Credentials + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#13 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [String] + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#25 + def access_key_id; end + + # @api private + # @return [String] + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#28 + def secret_access_key; end + + # @api private + # @return [String, nil] + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#31 + def session_token; end + + # @api private + # @return [Boolean] Returns `true` if the access key id and secret + # access key are both set. + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#35 + def set?; end +end + +# source://aws-sigv4//lib/aws-sigv4/errors.rb#5 +module Aws::Sigv4::Errors; end + +# source://aws-sigv4//lib/aws-sigv4/errors.rb#7 +class Aws::Sigv4::Errors::MissingCredentialsError < ::ArgumentError + # @return [MissingCredentialsError] a new instance of MissingCredentialsError + # + # source://aws-sigv4//lib/aws-sigv4/errors.rb#8 + def initialize(msg = T.unsafe(nil)); end +end + +# source://aws-sigv4//lib/aws-sigv4/errors.rb#18 +class Aws::Sigv4::Errors::MissingRegionError < ::ArgumentError + # @return [MissingRegionError] a new instance of MissingRegionError + # + # source://aws-sigv4//lib/aws-sigv4/errors.rb#19 + def initialize(*args); end +end + +# source://aws-sigv4//lib/aws-sigv4/signature.rb#5 +class Aws::Sigv4::Signature + # @api private + # @return [Signature] a new instance of Signature + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#8 + def initialize(options); end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#27 + def canonical_request; end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#27 + def canonical_request=(_arg0); end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#33 + def content_sha256; end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#33 + def content_sha256=(_arg0); end + + # @return [Hash] Internal data for debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#39 + def extra; end + + # @return [Hash] Internal data for debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#39 + def extra=(_arg0); end + + # @return [Hash] A hash of headers that should + # be applied to the HTTP request. Header keys are lower + # cased strings and may include the following: + # + # * 'host' + # * 'x-amz-date' + # * 'x-amz-security-token' + # * 'x-amz-content-sha256' + # * 'authorization' + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#24 + def headers; end + + # @return [Hash] A hash of headers that should + # be applied to the HTTP request. Header keys are lower + # cased strings and may include the following: + # + # * 'host' + # * 'x-amz-date' + # * 'x-amz-security-token' + # * 'x-amz-content-sha256' + # * 'authorization' + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#24 + def headers=(_arg0); end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#36 + def signature; end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#36 + def signature=(_arg0); end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#30 + def string_to_sign; end + + # @return [String] For debugging purposes. + # + # source://aws-sigv4//lib/aws-sigv4/signature.rb#30 + def string_to_sign=(_arg0); end +end + +# Utility class for creating AWS signature version 4 signature. This class +# provides two methods for generating signatures: +# +# * {#sign_request} - Computes a signature of the given request, returning +# the hash of headers that should be applied to the request. +# +# * {#presign_url} - Computes a presigned request with an expiration. +# By default, the body of this request is not signed and the request +# expires in 15 minutes. +# +# ## Configuration +# +# To use the signer, you need to specify the service, region, and credentials. +# The service name is normally the endpoint prefix to an AWS service. For +# example: +# +# ec2.us-west-1.amazonaws.com => ec2 +# +# The region is normally the second portion of the endpoint, following +# the service name. +# +# ec2.us-west-1.amazonaws.com => us-west-1 +# +# It is important to have the correct service and region name, or the +# signature will be invalid. +# +# ## Credentials +# +# The signer requires credentials. You can configure the signer +# with static credentials: +# +# signer = Aws::Sigv4::Signer.new( +# service: 's3', +# region: 'us-east-1', +# # static credentials +# access_key_id: 'akid', +# secret_access_key: 'secret' +# ) +# +# You can also provide refreshing credentials via the `:credentials_provider`. +# If you are using the AWS SDK for Ruby, you can use any of the credential +# classes: +# +# signer = Aws::Sigv4::Signer.new( +# service: 's3', +# region: 'us-east-1', +# credentials_provider: Aws::InstanceProfileCredentials.new +# ) +# +# Other AWS SDK for Ruby classes that can be provided via `:credentials_provider`: +# +# * `Aws::Credentials` +# * `Aws::SharedCredentials` +# * `Aws::InstanceProfileCredentials` +# * `Aws::AssumeRoleCredentials` +# * `Aws::ECSCredentials` +# +# A credential provider is any object that responds to `#credentials` +# returning another object that responds to `#access_key_id`, `#secret_access_key`, +# and `#session_token`. +# +# source://aws-sigv4//lib/aws-sigv4/signer.rb#76 +class Aws::Sigv4::Signer + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @overload initialize + # @overload initialize + # @overload initialize + # @param options [Hash] a customizable set of options + # @return [Signer] a new instance of Signer + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#144 + def initialize(options = T.unsafe(nil)); end + + # @return [Boolean] When `true` the `x-amz-content-sha256` header will be signed and + # returned in the signature headers. + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#189 + def apply_checksum_header; end + + # @return [#credentials] Returns an object that responds to + # `#credentials`, returning an object that responds to the following + # methods: + # + # * `#access_key_id` => String + # * `#secret_access_key` => String + # * `#session_token` => String, nil + # * `#set?` => Boolean + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#181 + def credentials_provider; end + + # Signs a URL with query authentication. Using query parameters + # to authenticate requests is useful when you want to express a + # request entirely in a URL. This method is also referred as + # presigning a URL. + # + # See [Authenticating Requests: Using Query Parameters (AWS Signature Version 4)](http://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-query-string-auth.html) for more information. + # + # To generate a presigned URL, you must provide a HTTP URI and + # the http method. + # + # url = signer.presign_url( + # http_method: 'GET', + # url: 'https://my-bucket.s3-us-east-1.amazonaws.com/key', + # expires_in: 60 + # ) + # + # By default, signatures are valid for 15 minutes. You can specify + # the number of seconds for the URL to expire in. + # + # url = signer.presign_url( + # http_method: 'GET', + # url: 'https://my-bucket.s3-us-east-1.amazonaws.com/key', + # expires_in: 3600 # one hour + # ) + # + # You can provide a hash of headers that you plan to send with the + # request. Every 'X-Amz-*' header you plan to send with the request + # **must** be provided, or the signature is invalid. Other headers + # are optional, but should be provided for security reasons. + # + # url = signer.presign_url( + # http_method: 'PUT', + # url: 'https://my-bucket.s3-us-east-1.amazonaws.com/key', + # headers: { + # 'X-Amz-Meta-Custom' => 'metadata' + # } + # ) + # + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [HTTPS::URI, HTTP::URI] + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#433 + def presign_url(options); end + + # @return [String] + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#170 + def region; end + + # @return [String] + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#167 + def service; end + + # Signs a event and returns signature headers and prior signature + # used for next event signing. + # + # Headers of a sigv4 signed event message only contains 2 headers + # * ':chunk-signature' + # * computed signature of the event, binary string, 'bytes' type + # * ':date' + # * millisecond since epoch, 'timestamp' type + # + # Payload of the sigv4 signed event message contains eventstream encoded message + # which is serialized based on input and protocol + # + # To sign events + # + # headers_0, signature_0 = signer.sign_event( + # prior_signature, # hex-encoded string + # payload_0, # binary string (eventstream encoded event 0) + # encoder, # Aws::EventStreamEncoder + # ) + # + # headers_1, signature_1 = signer.sign_event( + # signature_0, + # payload_1, # binary string (eventstream encoded event 1) + # encoder + # ) + # + # The initial prior_signature should be using the signature computed at initial request + # + # Note: + # + # Since ':chunk-signature' header value has bytes type, the signature value provided + # needs to be a binary string instead of a hex-encoded string (like original signature + # V4 algorithm). Thus, when returning signature value used for next event siging, the + # signature value (a binary string) used at ':chunk-signature' needs to converted to + # hex-encoded string using #unpack + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#346 + def sign_event(prior_signature, payload, encoder); end + + # Computes a version 4 signature signature. Returns the resultant + # signature as a hash of headers to apply to your HTTP request. The given + # request is not modified. + # + # signature = signer.sign_request( + # http_method: 'PUT', + # url: 'https://domain.com', + # headers: { + # 'Abc' => 'xyz', + # }, + # body: 'body' # String or IO object + # ) + # + # # Apply the following hash of headers to your HTTP request + # signature.headers['host'] + # signature.headers['x-amz-date'] + # signature.headers['x-amz-security-token'] + # signature.headers['x-amz-content-sha256'] + # signature.headers['authorization'] + # + # In addition to computing the signature headers, the canonicalized + # request, string to sign and content sha256 checksum are also available. + # These values are useful for debugging signature errors returned by AWS. + # + # signature.canonical_request #=> "..." + # signature.string_to_sign #=> "..." + # signature.content_sha256 #=> "..." + # + # @option request + # @option request + # @option request + # @option request + # @param request [Hash] + # @return [Signature] Return an instance of {Signature} that has + # a `#headers` method. The headers must be applied to your request. + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#238 + def sign_request(request); end + + # @return [Set] Returns a set of header names that should not be signed. + # All header names have been downcased. + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#185 + def unsigned_headers; end + + private + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#566 + def asymmetric_signature(creds, string_to_sign); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#654 + def canonical_header_value(value); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#642 + def canonical_headers(headers); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#502 + def canonical_request(http_method, url, headers, content_sha256); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#554 + def credential(credentials, date); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#545 + def credential_scope(date); end + + # Returns true if credentials are set (not nil or empty) + # Credentials may not implement the Credentials interface + # and may just be credential like Client response objects + # (eg those returned by sts#assume_role) + # + # @return [Boolean] + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#782 + def credentials_set?(credentials); end + + # the credentials used by CRT must be a + # CRT StaticCredentialsProvider object + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#808 + def crt_fetch_credentials; end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#877 + def crt_presign_url(options); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#818 + def crt_sign_request(request); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#739 + def downcase_headers(headers); end + + # Comparing to original signature v4 algorithm, + # returned signature is a binary string instread of + # hex-encoded string. (Since ':chunk-signature' requires + # 'bytes' type) + # + # Note: + # converting signature from binary string to hex-encoded + # string is handled at #sign_event instead. (Will be used + # as next prior signature for event signing) + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#585 + def event_signature(secret_access_key, date, string_to_sign); end + + # Compared to original #string_to_sign at signature v4 algorithm + # there is no canonical_request concept for an eventstream event, + # instead, an event contains headers and payload two parts, and + # they will be used for computing digest in #event_string_to_sign + # + # Note: + # While headers need to be encoded under eventstream format, + # payload used is already eventstream encoded (event without signature), + # thus no extra encoding is needed. + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#531 + def event_string_to_sign(datetime, headers, payload, prior_signature, encoder); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#711 + def extract_credentials_provider(options); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#746 + def extract_expires_in(options); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#721 + def extract_http_method(request); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#703 + def extract_region(options); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#694 + def extract_service(options); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#730 + def extract_url(request); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#764 + def fetch_credentials; end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#690 + def hexhmac(key, value); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#686 + def hmac(key, value); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#658 + def host(uri); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#603 + def normalized_querystring(querystring); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#593 + def path(url); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#789 + def presigned_url_expiration(options, expiration, datetime); end + + # @param value [File, Tempfile, IO#read, String] + # @return [String] + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#669 + def sha256_hexdigest(value); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#558 + def signature(secret_access_key, date, string_to_sign); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#632 + def signed_headers(headers); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#513 + def string_to_sign(datetime, canonical_request, algorithm); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#498 + def sts_algorithm; end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#756 + def uri_escape(string); end + + # source://aws-sigv4//lib/aws-sigv4/signer.rb#760 + def uri_escape_path(string); end + + class << self + # @api private + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#944 + def normalize_path(uri); end + + # @api private + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#935 + def uri_escape(string); end + + # @api private + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#930 + def uri_escape_path(path); end + + # @return [Boolean] + # + # source://aws-sigv4//lib/aws-sigv4/signer.rb#925 + def use_crt?; end + end +end + +# Users that wish to configure static credentials can use the +# `:access_key_id` and `:secret_access_key` constructor options. +# +# @api private +# +# source://aws-sigv4//lib/aws-sigv4/credentials.rb#46 +class Aws::Sigv4::StaticCredentialsProvider + # @api private + # @option options + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [StaticCredentialsProvider] a new instance of StaticCredentialsProvider + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#52 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Credentials] + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#59 + def credentials; end + + # @api private + # @return [Boolean] + # + # source://aws-sigv4//lib/aws-sigv4/credentials.rb#62 + def set?; end +end + +# source://aws-sigv4//lib/aws-sigv4.rb#11 +Aws::Sigv4::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/backport@1.2.0.rbi b/sorbet/rbi/gems/backport@1.2.0.rbi index b670d6b96..1e40a3f53 100644 --- a/sorbet/rbi/gems/backport@1.2.0.rbi +++ b/sorbet/rbi/gems/backport@1.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `backport` gem. # Please instead update this file by running `bin/tapioca gem backport`. + # An event-driven IO library. # # source://backport//lib/backport/version.rb#1 diff --git a/sorbet/rbi/gems/base32_pure@0.1.0.rbi b/sorbet/rbi/gems/base32_pure@0.1.0.rbi index 35703d8b6..2d841d309 100644 --- a/sorbet/rbi/gems/base32_pure@0.1.0.rbi +++ b/sorbet/rbi/gems/base32_pure@0.1.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `base32_pure` gem. # Please instead update this file by running `bin/tapioca gem base32_pure`. + # Extend fixnum with an each_byte method # # source://base32_pure//lib/base32/crockford.rb#3 diff --git a/sorbet/rbi/gems/base64@0.2.0.rbi b/sorbet/rbi/gems/base64@0.2.0.rbi new file mode 100644 index 000000000..087b64e5a --- /dev/null +++ b/sorbet/rbi/gems/base64@0.2.0.rbi @@ -0,0 +1,507 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `base64` gem. +# Please instead update this file by running `bin/tapioca gem base64`. + + +# \Module \Base64 provides methods for: +# +# - Encoding a binary string (containing non-ASCII characters) +# as a string of printable ASCII characters. +# - Decoding such an encoded string. +# +# \Base64 is commonly used in contexts where binary data +# is not allowed or supported: +# +# - Images in HTML or CSS files, or in URLs. +# - Email attachments. +# +# A \Base64-encoded string is about one-third larger that its source. +# See the {Wikipedia article}[https://en.wikipedia.org/wiki/Base64] +# for more information. +# +# This module provides three pairs of encode/decode methods. +# Your choices among these methods should depend on: +# +# - Which character set is to be used for encoding and decoding. +# - Whether "padding" is to be used. +# - Whether encoded strings are to contain newlines. +# +# Note: Examples on this page assume that the including program has executed: +# +# require 'base64' +# +# == Encoding Character Sets +# +# A \Base64-encoded string consists only of characters from a 64-character set: +# +# - ('A'..'Z'). +# - ('a'..'z'). +# - ('0'..'9'). +# - =, the 'padding' character. +# - Either: +# - %w[+ /]: +# {RFC-2045-compliant}[https://datatracker.ietf.org/doc/html/rfc2045]; +# _not_ safe for URLs. +# - %w[- _]: +# {RFC-4648-compliant}[https://datatracker.ietf.org/doc/html/rfc4648]; +# safe for URLs. +# +# If you are working with \Base64-encoded strings that will come from +# or be put into URLs, you should choose this encoder-decoder pair +# of RFC-4648-compliant methods: +# +# - Base64.urlsafe_encode64 and Base64.urlsafe_decode64. +# +# Otherwise, you may choose any of the pairs in this module, +# including the pair above, or the RFC-2045-compliant pairs: +# +# - Base64.encode64 and Base64.decode64. +# - Base64.strict_encode64 and Base64.strict_decode64. +# +# == Padding +# +# \Base64-encoding changes a triplet of input bytes +# into a quartet of output characters. +# +# Padding in Encode Methods +# +# Padding -- extending an encoded string with zero, one, or two trailing +# = characters -- is performed by methods Base64.encode64, +# Base64.strict_encode64, and, by default, Base64.urlsafe_encode64: +# +# Base64.encode64('s') # => "cw==\n" +# Base64.strict_encode64('s') # => "cw==" +# Base64.urlsafe_encode64('s') # => "cw==" +# Base64.urlsafe_encode64('s', padding: false) # => "cw" +# +# When padding is performed, the encoded string is always of length 4n, +# where +n+ is a non-negative integer: +# +# - Input bytes of length 3n generate unpadded output characters +# of length 4n: +# +# # n = 1: 3 bytes => 4 characters. +# Base64.strict_encode64('123') # => "MDEy" +# # n = 2: 6 bytes => 8 characters. +# Base64.strict_encode64('123456') # => "MDEyMzQ1" +# +# - Input bytes of length 3n+1 generate padded output characters +# of length 4(n+1), with two padding characters at the end: +# +# # n = 1: 4 bytes => 8 characters. +# Base64.strict_encode64('1234') # => "MDEyMw==" +# # n = 2: 7 bytes => 12 characters. +# Base64.strict_encode64('1234567') # => "MDEyMzQ1Ng==" +# +# - Input bytes of length 3n+2 generate padded output characters +# of length 4(n+1), with one padding character at the end: +# +# # n = 1: 5 bytes => 8 characters. +# Base64.strict_encode64('12345') # => "MDEyMzQ=" +# # n = 2: 8 bytes => 12 characters. +# Base64.strict_encode64('12345678') # => "MDEyMzQ1Njc=" +# +# When padding is suppressed, for a positive integer n: +# +# - Input bytes of length 3n generate unpadded output characters +# of length 4n: +# +# # n = 1: 3 bytes => 4 characters. +# Base64.urlsafe_encode64('123', padding: false) # => "MDEy" +# # n = 2: 6 bytes => 8 characters. +# Base64.urlsafe_encode64('123456', padding: false) # => "MDEyMzQ1" +# +# - Input bytes of length 3n+1 generate unpadded output characters +# of length 4n+2, with two padding characters at the end: +# +# # n = 1: 4 bytes => 6 characters. +# Base64.urlsafe_encode64('1234', padding: false) # => "MDEyMw" +# # n = 2: 7 bytes => 10 characters. +# Base64.urlsafe_encode64('1234567', padding: false) # => "MDEyMzQ1Ng" +# +# - Input bytes of length 3n+2 generate unpadded output characters +# of length 4n+3, with one padding character at the end: +# +# # n = 1: 5 bytes => 7 characters. +# Base64.urlsafe_encode64('12345', padding: false) # => "MDEyMzQ" +# # m = 2: 8 bytes => 11 characters. +# Base64.urlsafe_encode64('12345678', padding: false) # => "MDEyMzQ1Njc" +# +# Padding in Decode Methods +# +# All of the \Base64 decode methods support (but do not require) padding. +# +# \Method Base64.decode64 does not check the size of the padding: +# +# Base64.decode64("MDEyMzQ1Njc") # => "01234567" +# Base64.decode64("MDEyMzQ1Njc=") # => "01234567" +# Base64.decode64("MDEyMzQ1Njc==") # => "01234567" +# +# \Method Base64.strict_decode64 strictly enforces padding size: +# +# Base64.strict_decode64("MDEyMzQ1Njc") # Raises ArgumentError +# Base64.strict_decode64("MDEyMzQ1Njc=") # => "01234567" +# Base64.strict_decode64("MDEyMzQ1Njc==") # Raises ArgumentError +# +# \Method Base64.urlsafe_decode64 allows padding in +str+, +# which if present, must be correct: +# see {Padding}[Base64.html#module-Base64-label-Padding], above: +# +# Base64.urlsafe_decode64("MDEyMzQ1Njc") # => "01234567" +# Base64.urlsafe_decode64("MDEyMzQ1Njc=") # => "01234567" +# Base64.urlsafe_decode64("MDEyMzQ1Njc==") # Raises ArgumentError. +# +# == Newlines +# +# An encoded string returned by Base64.encode64 or Base64.urlsafe_encode64 +# has an embedded newline character +# after each 60-character sequence, and, if non-empty, at the end: +# +# # No newline if empty. +# encoded = Base64.encode64("\x00" * 0) +# encoded.index("\n") # => nil +# +# # Newline at end of short output. +# encoded = Base64.encode64("\x00" * 1) +# encoded.size # => 4 +# encoded.index("\n") # => 4 +# +# # Newline at end of longer output. +# encoded = Base64.encode64("\x00" * 45) +# encoded.size # => 60 +# encoded.index("\n") # => 60 +# +# # Newlines embedded and at end of still longer output. +# encoded = Base64.encode64("\x00" * 46) +# encoded.size # => 65 +# encoded.rindex("\n") # => 65 +# encoded.split("\n").map {|s| s.size } # => [60, 4] +# +# The string to be encoded may itself contain newlines, +# which are encoded as \Base64: +# +# # Base64.encode64("\n\n\n") # => "CgoK\n" +# s = "This is line 1\nThis is line 2\n" +# Base64.encode64(s) # => "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK\n" +module Base64 + private + + # Returns a string containing the decoding of an RFC-2045-compliant + # \Base64-encoded string +str+: + # + # s = "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK\n" + # Base64.decode64(s) # => "This is line 1\nThis is line 2\n" + # + # Non-\Base64 characters in +str+ are ignored; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # these include newline characters and characters - and /: + # + # Base64.decode64("\x00\n-_") # => "" + # + # Padding in +str+ (even if incorrect) is ignored: + # + # Base64.decode64("MDEyMzQ1Njc") # => "01234567" + # Base64.decode64("MDEyMzQ1Njc=") # => "01234567" + # Base64.decode64("MDEyMzQ1Njc==") # => "01234567" + # + # source://base64//base64.rb#241 + def decode64(str); end + + # Returns a string containing the RFC-2045-compliant \Base64-encoding of +bin+. + # + # Per RFC 2045, the returned string may contain the URL-unsafe characters + # + or /; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.encode64("\xFB\xEF\xBE") # => "++++\n" + # Base64.encode64("\xFF\xFF\xFF") # => "////\n" + # + # The returned string may include padding; + # see {Padding}[Base64.html#module-Base64-label-Padding] above. + # + # Base64.encode64('*') # => "Kg==\n" + # + # The returned string ends with a newline character, and if sufficiently long + # will have one or more embedded newline characters; + # see {Newlines}[Base64.html#module-Base64-label-Newlines] above: + # + # Base64.encode64('*') # => "Kg==\n" + # Base64.encode64('*' * 46) + # # => "KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq\nKg==\n" + # + # The string to be encoded may itself contain newlines, + # which will be encoded as ordinary \Base64: + # + # Base64.encode64("\n\n\n") # => "CgoK\n" + # s = "This is line 1\nThis is line 2\n" + # Base64.encode64(s) # => "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK\n" + # + # source://base64//base64.rb#219 + def encode64(bin); end + + # Returns a string containing the decoding of an RFC-2045-compliant + # \Base64-encoded string +str+: + # + # s = "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK" + # Base64.strict_decode64(s) # => "This is line 1\nThis is line 2\n" + # + # Non-\Base64 characters in +str+ not allowed; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # these include newline characters and characters - and /: + # + # Base64.strict_decode64("\n") # Raises ArgumentError + # Base64.strict_decode64('-') # Raises ArgumentError + # Base64.strict_decode64('_') # Raises ArgumentError + # + # Padding in +str+, if present, must be correct: + # + # Base64.strict_decode64("MDEyMzQ1Njc") # Raises ArgumentError + # Base64.strict_decode64("MDEyMzQ1Njc=") # => "01234567" + # Base64.strict_decode64("MDEyMzQ1Njc==") # Raises ArgumentError + # + # source://base64//base64.rb#297 + def strict_decode64(str); end + + # Returns a string containing the RFC-2045-compliant \Base64-encoding of +bin+. + # + # Per RFC 2045, the returned string may contain the URL-unsafe characters + # + or /; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.strict_encode64("\xFB\xEF\xBE") # => "++++\n" + # Base64.strict_encode64("\xFF\xFF\xFF") # => "////\n" + # + # The returned string may include padding; + # see {Padding}[Base64.html#module-Base64-label-Padding] above. + # + # Base64.strict_encode64('*') # => "Kg==\n" + # + # The returned string will have no newline characters, regardless of its length; + # see {Newlines}[Base64.html#module-Base64-label-Newlines] above: + # + # Base64.strict_encode64('*') # => "Kg==" + # Base64.strict_encode64('*' * 46) + # # => "KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKg==" + # + # The string to be encoded may itself contain newlines, + # which will be encoded as ordinary \Base64: + # + # Base64.strict_encode64("\n\n\n") # => "CgoK" + # s = "This is line 1\nThis is line 2\n" + # Base64.strict_encode64(s) # => "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK" + # + # source://base64//base64.rb#273 + def strict_encode64(bin); end + + # Returns the decoding of an RFC-4648-compliant \Base64-encoded string +str+: + # + # +str+ may not contain non-Base64 characters; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.urlsafe_decode64('+') # Raises ArgumentError. + # Base64.urlsafe_decode64('/') # Raises ArgumentError. + # Base64.urlsafe_decode64("\n") # Raises ArgumentError. + # + # Padding in +str+, if present, must be correct: + # see {Padding}[Base64.html#module-Base64-label-Padding], above: + # + # Base64.urlsafe_decode64("MDEyMzQ1Njc") # => "01234567" + # Base64.urlsafe_decode64("MDEyMzQ1Njc=") # => "01234567" + # Base64.urlsafe_decode64("MDEyMzQ1Njc==") # Raises ArgumentError. + # + # source://base64//base64.rb#351 + def urlsafe_decode64(str); end + + # Returns the RFC-4648-compliant \Base64-encoding of +bin+. + # + # Per RFC 4648, the returned string will not contain the URL-unsafe characters + # + or /, + # but instead may contain the URL-safe characters + # - and _; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.urlsafe_encode64("\xFB\xEF\xBE") # => "----" + # Base64.urlsafe_encode64("\xFF\xFF\xFF") # => "____" + # + # By default, the returned string may have padding; + # see {Padding}[Base64.html#module-Base64-label-Padding], above: + # + # Base64.urlsafe_encode64('*') # => "Kg==" + # + # Optionally, you can suppress padding: + # + # Base64.urlsafe_encode64('*', padding: false) # => "Kg" + # + # The returned string will have no newline characters, regardless of its length; + # see {Newlines}[Base64.html#module-Base64-label-Newlines] above: + # + # Base64.urlsafe_encode64('*') # => "Kg==" + # Base64.urlsafe_encode64('*' * 46) + # # => "KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKg==" + # + # source://base64//base64.rb#328 + def urlsafe_encode64(bin, padding: T.unsafe(nil)); end + + class << self + # Returns a string containing the decoding of an RFC-2045-compliant + # \Base64-encoded string +str+: + # + # s = "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK\n" + # Base64.decode64(s) # => "This is line 1\nThis is line 2\n" + # + # Non-\Base64 characters in +str+ are ignored; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # these include newline characters and characters - and /: + # + # Base64.decode64("\x00\n-_") # => "" + # + # Padding in +str+ (even if incorrect) is ignored: + # + # Base64.decode64("MDEyMzQ1Njc") # => "01234567" + # Base64.decode64("MDEyMzQ1Njc=") # => "01234567" + # Base64.decode64("MDEyMzQ1Njc==") # => "01234567" + # + # source://base64//base64.rb#241 + def decode64(str); end + + # Returns a string containing the RFC-2045-compliant \Base64-encoding of +bin+. + # + # Per RFC 2045, the returned string may contain the URL-unsafe characters + # + or /; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.encode64("\xFB\xEF\xBE") # => "++++\n" + # Base64.encode64("\xFF\xFF\xFF") # => "////\n" + # + # The returned string may include padding; + # see {Padding}[Base64.html#module-Base64-label-Padding] above. + # + # Base64.encode64('*') # => "Kg==\n" + # + # The returned string ends with a newline character, and if sufficiently long + # will have one or more embedded newline characters; + # see {Newlines}[Base64.html#module-Base64-label-Newlines] above: + # + # Base64.encode64('*') # => "Kg==\n" + # Base64.encode64('*' * 46) + # # => "KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq\nKg==\n" + # + # The string to be encoded may itself contain newlines, + # which will be encoded as ordinary \Base64: + # + # Base64.encode64("\n\n\n") # => "CgoK\n" + # s = "This is line 1\nThis is line 2\n" + # Base64.encode64(s) # => "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK\n" + # + # source://base64//base64.rb#219 + def encode64(bin); end + + # Returns a string containing the decoding of an RFC-2045-compliant + # \Base64-encoded string +str+: + # + # s = "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK" + # Base64.strict_decode64(s) # => "This is line 1\nThis is line 2\n" + # + # Non-\Base64 characters in +str+ not allowed; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # these include newline characters and characters - and /: + # + # Base64.strict_decode64("\n") # Raises ArgumentError + # Base64.strict_decode64('-') # Raises ArgumentError + # Base64.strict_decode64('_') # Raises ArgumentError + # + # Padding in +str+, if present, must be correct: + # + # Base64.strict_decode64("MDEyMzQ1Njc") # Raises ArgumentError + # Base64.strict_decode64("MDEyMzQ1Njc=") # => "01234567" + # Base64.strict_decode64("MDEyMzQ1Njc==") # Raises ArgumentError + # + # source://base64//base64.rb#297 + def strict_decode64(str); end + + # Returns a string containing the RFC-2045-compliant \Base64-encoding of +bin+. + # + # Per RFC 2045, the returned string may contain the URL-unsafe characters + # + or /; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.strict_encode64("\xFB\xEF\xBE") # => "++++\n" + # Base64.strict_encode64("\xFF\xFF\xFF") # => "////\n" + # + # The returned string may include padding; + # see {Padding}[Base64.html#module-Base64-label-Padding] above. + # + # Base64.strict_encode64('*') # => "Kg==\n" + # + # The returned string will have no newline characters, regardless of its length; + # see {Newlines}[Base64.html#module-Base64-label-Newlines] above: + # + # Base64.strict_encode64('*') # => "Kg==" + # Base64.strict_encode64('*' * 46) + # # => "KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKg==" + # + # The string to be encoded may itself contain newlines, + # which will be encoded as ordinary \Base64: + # + # Base64.strict_encode64("\n\n\n") # => "CgoK" + # s = "This is line 1\nThis is line 2\n" + # Base64.strict_encode64(s) # => "VGhpcyBpcyBsaW5lIDEKVGhpcyBpcyBsaW5lIDIK" + # + # source://base64//base64.rb#273 + def strict_encode64(bin); end + + # Returns the decoding of an RFC-4648-compliant \Base64-encoded string +str+: + # + # +str+ may not contain non-Base64 characters; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.urlsafe_decode64('+') # Raises ArgumentError. + # Base64.urlsafe_decode64('/') # Raises ArgumentError. + # Base64.urlsafe_decode64("\n") # Raises ArgumentError. + # + # Padding in +str+, if present, must be correct: + # see {Padding}[Base64.html#module-Base64-label-Padding], above: + # + # Base64.urlsafe_decode64("MDEyMzQ1Njc") # => "01234567" + # Base64.urlsafe_decode64("MDEyMzQ1Njc=") # => "01234567" + # Base64.urlsafe_decode64("MDEyMzQ1Njc==") # Raises ArgumentError. + # + # source://base64//base64.rb#351 + def urlsafe_decode64(str); end + + # Returns the RFC-4648-compliant \Base64-encoding of +bin+. + # + # Per RFC 4648, the returned string will not contain the URL-unsafe characters + # + or /, + # but instead may contain the URL-safe characters + # - and _; + # see {Encoding Character Set}[Base64.html#module-Base64-label-Encoding+Character+Sets] above: + # + # Base64.urlsafe_encode64("\xFB\xEF\xBE") # => "----" + # Base64.urlsafe_encode64("\xFF\xFF\xFF") # => "____" + # + # By default, the returned string may have padding; + # see {Padding}[Base64.html#module-Base64-label-Padding], above: + # + # Base64.urlsafe_encode64('*') # => "Kg==" + # + # Optionally, you can suppress padding: + # + # Base64.urlsafe_encode64('*', padding: false) # => "Kg" + # + # The returned string will have no newline characters, regardless of its length; + # see {Newlines}[Base64.html#module-Base64-label-Newlines] above: + # + # Base64.urlsafe_encode64('*') # => "Kg==" + # Base64.urlsafe_encode64('*' * 46) + # # => "KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKg==" + # + # source://base64//base64.rb#328 + def urlsafe_encode64(bin, padding: T.unsafe(nil)); end + end +end + +# source://base64//base64.rb#186 +Base64::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/bcrypt@3.1.18.rbi b/sorbet/rbi/gems/bcrypt@3.1.20.rbi similarity index 97% rename from sorbet/rbi/gems/bcrypt@3.1.18.rbi rename to sorbet/rbi/gems/bcrypt@3.1.20.rbi index c670598b8..a40921b8a 100644 --- a/sorbet/rbi/gems/bcrypt@3.1.18.rbi +++ b/sorbet/rbi/gems/bcrypt@3.1.20.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `bcrypt` gem. # Please instead update this file by running `bin/tapioca gem bcrypt`. + # A Ruby library implementing OpenBSD's bcrypt()/crypt_blowfish algorithm for # hashing passwords. # @@ -17,7 +18,7 @@ class BCrypt::Engine class << self # Autodetects the cost from the salt string. # - # source://bcrypt//lib/bcrypt/engine.rb#122 + # source://bcrypt//lib/bcrypt/engine.rb#129 def autodetect_cost(salt); end # Returns the cost factor which will result in computation times less than +upper_time_limit_in_ms+. @@ -33,7 +34,7 @@ class BCrypt::Engine # # should take less than 1000ms # BCrypt::Password.create("woo", :cost => 12) # - # source://bcrypt//lib/bcrypt/engine.rb#112 + # source://bcrypt//lib/bcrypt/engine.rb#119 def calibrate(upper_time_limit_in_ms); end # Returns the cost factor that will be used if one is not specified when @@ -61,7 +62,7 @@ class BCrypt::Engine # Generates a random salt with a given computational cost. # - # source://bcrypt//lib/bcrypt/engine.rb#74 + # source://bcrypt//lib/bcrypt/engine.rb#81 def generate_salt(cost = T.unsafe(nil)); end # Given a secret and a valid salt (see BCrypt::Engine.generate_salt) calculates @@ -74,14 +75,14 @@ class BCrypt::Engine # # @return [Boolean] # - # source://bcrypt//lib/bcrypt/engine.rb#91 + # source://bcrypt//lib/bcrypt/engine.rb#98 def valid_salt?(salt); end # Returns true if +secret+ is a valid bcrypt() secret, false if not. # # @return [Boolean] # - # source://bcrypt//lib/bcrypt/engine.rb#96 + # source://bcrypt//lib/bcrypt/engine.rb#103 def valid_secret?(secret); end private diff --git a/sorbet/rbi/gems/bcrypt_pbkdf@1.1.0.rbi b/sorbet/rbi/gems/bcrypt_pbkdf@1.1.1.rbi similarity index 99% rename from sorbet/rbi/gems/bcrypt_pbkdf@1.1.0.rbi rename to sorbet/rbi/gems/bcrypt_pbkdf@1.1.1.rbi index 509187e33..d036136e2 100644 --- a/sorbet/rbi/gems/bcrypt_pbkdf@1.1.0.rbi +++ b/sorbet/rbi/gems/bcrypt_pbkdf@1.1.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `bcrypt_pbkdf` gem. # Please instead update this file by running `bin/tapioca gem bcrypt_pbkdf`. + # source://bcrypt_pbkdf//lib/bcrypt_pbkdf.rb#8 module BCryptPbkdf class << self diff --git a/sorbet/rbi/gems/benchmark@0.2.1.rbi b/sorbet/rbi/gems/benchmark@0.3.0.rbi similarity index 92% rename from sorbet/rbi/gems/benchmark@0.2.1.rbi rename to sorbet/rbi/gems/benchmark@0.3.0.rbi index d859e946b..c5d84c801 100644 --- a/sorbet/rbi/gems/benchmark@0.2.1.rbi +++ b/sorbet/rbi/gems/benchmark@0.3.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `benchmark` gem. # Please instead update this file by running `bin/tapioca gem benchmark`. + # The Benchmark module provides methods to measure and report the time # used to execute Ruby code. # @@ -150,7 +151,7 @@ module Benchmark # >total: 2.930000 0.000000 2.930000 ( 2.932889) # >avg: 0.976667 0.000000 0.976667 ( 0.977630) # - # source://benchmark//benchmark.rb#168 + # source://benchmark//benchmark.rb#170 def benchmark(caption = T.unsafe(nil), label_width = T.unsafe(nil), format = T.unsafe(nil), *labels); end # A simple interface to the #benchmark method, #bm generates sequential @@ -173,7 +174,7 @@ module Benchmark # times: 0.960000 0.000000 0.960000 ( 0.960423) # upto: 0.950000 0.000000 0.950000 ( 0.954864) # - # source://benchmark//benchmark.rb#207 + # source://benchmark//benchmark.rb#209 def bm(label_width = T.unsafe(nil), *labels, &blk); end # Sometimes benchmark results are skewed because code executed @@ -213,7 +214,7 @@ module Benchmark # #bmbm yields a Benchmark::Job object and returns an array of # Benchmark::Tms objects. # - # source://benchmark//benchmark.rb#249 + # source://benchmark//benchmark.rb#251 def bmbm(width = T.unsafe(nil)); end # Returns the time used to execute the given block as a @@ -232,12 +233,12 @@ module Benchmark # # 0.220000 0.000000 0.220000 ( 0.227313) # - # source://benchmark//benchmark.rb#294 + # source://benchmark//benchmark.rb#296 def measure(label = T.unsafe(nil)); end # Returns the elapsed real time used to execute the given block. # - # source://benchmark//benchmark.rb#309 + # source://benchmark//benchmark.rb#311 def realtime; end class << self @@ -282,7 +283,7 @@ module Benchmark # >total: 2.930000 0.000000 2.930000 ( 2.932889) # >avg: 0.976667 0.000000 0.976667 ( 0.977630) # - # source://benchmark//benchmark.rb#168 + # source://benchmark//benchmark.rb#170 def benchmark(caption = T.unsafe(nil), label_width = T.unsafe(nil), format = T.unsafe(nil), *labels); end # A simple interface to the #benchmark method, #bm generates sequential @@ -305,7 +306,7 @@ module Benchmark # times: 0.960000 0.000000 0.960000 ( 0.960423) # upto: 0.950000 0.000000 0.950000 ( 0.954864) # - # source://benchmark//benchmark.rb#207 + # source://benchmark//benchmark.rb#209 def bm(label_width = T.unsafe(nil), *labels, &blk); end # Sometimes benchmark results are skewed because code executed @@ -345,7 +346,7 @@ module Benchmark # #bmbm yields a Benchmark::Job object and returns an array of # Benchmark::Tms objects. # - # source://benchmark//benchmark.rb#249 + # source://benchmark//benchmark.rb#251 def bmbm(width = T.unsafe(nil)); end # Returns the time used to execute the given block as a @@ -364,12 +365,12 @@ module Benchmark # # 0.220000 0.000000 0.220000 ( 0.227313) # - # source://benchmark//benchmark.rb#294 + # source://benchmark//benchmark.rb#296 def measure(label = T.unsafe(nil)); end # Returns the elapsed real time used to execute the given block. # - # source://benchmark//benchmark.rb#309 + # source://benchmark//benchmark.rb#311 def realtime; end end end @@ -385,31 +386,31 @@ class Benchmark::Job # # @return [Job] a new instance of Job # - # source://benchmark//benchmark.rb#329 + # source://benchmark//benchmark.rb#331 def initialize(width); end # Registers the given label and block pair in the job list. # # @raise [ArgumentError] # - # source://benchmark//benchmark.rb#337 + # source://benchmark//benchmark.rb#339 def item(label = T.unsafe(nil), &blk); end # An array of 2-element arrays, consisting of label and block pairs. # - # source://benchmark//benchmark.rb#349 + # source://benchmark//benchmark.rb#351 def list; end # Registers the given label and block pair in the job list. # # @raise [ArgumentError] # - # source://benchmark//benchmark.rb#337 + # source://benchmark//benchmark.rb#339 def report(label = T.unsafe(nil), &blk); end # Length of the widest label in the #list. # - # source://benchmark//benchmark.rb#352 + # source://benchmark//benchmark.rb#354 def width; end end @@ -424,26 +425,26 @@ class Benchmark::Report # # @return [Report] a new instance of Report # - # source://benchmark//benchmark.rb#367 + # source://benchmark//benchmark.rb#369 def initialize(width = T.unsafe(nil), format = T.unsafe(nil)); end # Prints the +label+ and measured time for the block, # formatted by +format+. See Tms#format for the # formatting rules. # - # source://benchmark//benchmark.rb#376 + # source://benchmark//benchmark.rb#378 def item(label = T.unsafe(nil), *format, &blk); end # An array of Benchmark::Tms objects representing each item. # - # source://benchmark//benchmark.rb#386 + # source://benchmark//benchmark.rb#388 def list; end # Prints the +label+ and measured time for the block, # formatted by +format+. See Tms#format for the # formatting rules. # - # source://benchmark//benchmark.rb#376 + # source://benchmark//benchmark.rb#378 def report(label = T.unsafe(nil), *format, &blk); end end @@ -457,13 +458,13 @@ class Benchmark::Tms # # @return [Tms] a new instance of Tms # - # source://benchmark//benchmark.rb#430 + # source://benchmark//benchmark.rb#432 def initialize(utime = T.unsafe(nil), stime = T.unsafe(nil), cutime = T.unsafe(nil), cstime = T.unsafe(nil), real = T.unsafe(nil), label = T.unsafe(nil)); end # Returns a new Tms object obtained by memberwise multiplication # of the individual times for this Tms object by +x+. # - # source://benchmark//benchmark.rb#478 + # source://benchmark//benchmark.rb#480 def *(x); end # Returns a new Tms object obtained by memberwise summation @@ -471,27 +472,27 @@ class Benchmark::Tms # Tms object. # This method and #/() are useful for taking statistics. # - # source://benchmark//benchmark.rb#465 + # source://benchmark//benchmark.rb#467 def +(other); end # Returns a new Tms object obtained by memberwise subtraction # of the individual times for the +other+ Tms object from those of this # Tms object. # - # source://benchmark//benchmark.rb#472 + # source://benchmark//benchmark.rb#474 def -(other); end # Returns a new Tms object obtained by memberwise division # of the individual times for this Tms object by +x+. # This method and #+() are useful for taking statistics. # - # source://benchmark//benchmark.rb#485 + # source://benchmark//benchmark.rb#487 def /(x); end # Returns a new Tms object whose times are the sum of the times for this # Tms object, plus the time required to execute the code block (+blk+). # - # source://benchmark//benchmark.rb#439 + # source://benchmark//benchmark.rb#441 def add(&blk); end # An in-place version of #add. @@ -499,17 +500,17 @@ class Benchmark::Tms # for this Tms object, plus the time required to execute # the code block (+blk+). # - # source://benchmark//benchmark.rb#449 + # source://benchmark//benchmark.rb#451 def add!(&blk); end # System CPU time of children # - # source://benchmark//benchmark.rb#413 + # source://benchmark//benchmark.rb#415 def cstime; end # User CPU time of children # - # source://benchmark//benchmark.rb#410 + # source://benchmark//benchmark.rb#412 def cutime; end # Returns the contents of this Tms object as @@ -528,22 +529,22 @@ class Benchmark::Tms # If +format+ is not given, FORMAT is used as default value, detailing the # user, system and real elapsed time. # - # source://benchmark//benchmark.rb#504 + # source://benchmark//benchmark.rb#506 def format(format = T.unsafe(nil), *args); end # Label # - # source://benchmark//benchmark.rb#422 + # source://benchmark//benchmark.rb#424 def label; end # Elapsed real time # - # source://benchmark//benchmark.rb#416 + # source://benchmark//benchmark.rb#418 def real; end # System CPU time # - # source://benchmark//benchmark.rb#407 + # source://benchmark//benchmark.rb#409 def stime; end # Returns a new 6-element array, consisting of the @@ -551,27 +552,27 @@ class Benchmark::Tms # user CPU time, children's system CPU time and elapsed # real time. # - # source://benchmark//benchmark.rb#529 + # source://benchmark//benchmark.rb#531 def to_a; end # Returns a hash containing the same data as `to_a`. # - # source://benchmark//benchmark.rb#536 + # source://benchmark//benchmark.rb#538 def to_h; end # Same as #format. # - # source://benchmark//benchmark.rb#519 + # source://benchmark//benchmark.rb#521 def to_s; end # Total time, that is +utime+ + +stime+ + +cutime+ + +cstime+ # - # source://benchmark//benchmark.rb#419 + # source://benchmark//benchmark.rb#421 def total; end # User CPU time # - # source://benchmark//benchmark.rb#404 + # source://benchmark//benchmark.rb#406 def utime; end protected @@ -583,6 +584,9 @@ class Benchmark::Tms # +op+ can be a mathematical operation such as +, -, # *, / # - # source://benchmark//benchmark.rb#557 + # source://benchmark//benchmark.rb#559 def memberwise(op, x); end end + +# source://benchmark//benchmark.rb#124 +Benchmark::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/better_errors@2.10.1.rbi b/sorbet/rbi/gems/better_errors@2.10.1.rbi index 7694c4f32..f40c9679a 100644 --- a/sorbet/rbi/gems/better_errors@2.10.1.rbi +++ b/sorbet/rbi/gems/better_errors@2.10.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `better_errors` gem. # Please instead update this file by running `bin/tapioca gem better_errors`. + # @private # # source://better_errors//lib/better_errors/version.rb#1 diff --git a/sorbet/rbi/gems/bigdecimal@3.1.8.rbi b/sorbet/rbi/gems/bigdecimal@3.1.8.rbi new file mode 100644 index 000000000..c275b2f77 --- /dev/null +++ b/sorbet/rbi/gems/bigdecimal@3.1.8.rbi @@ -0,0 +1,78 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `bigdecimal` gem. +# Please instead update this file by running `bin/tapioca gem bigdecimal`. + + +# source://bigdecimal//lib/bigdecimal/util.rb#78 +class BigDecimal < ::Numeric + # call-seq: + # a.to_d -> bigdecimal + # + # Returns self. + # + # require 'bigdecimal/util' + # + # d = BigDecimal("3.14") + # d.to_d # => 0.314e1 + # + # source://bigdecimal//lib/bigdecimal/util.rb#110 + def to_d; end + + # call-seq: + # a.to_digits -> string + # + # Converts a BigDecimal to a String of the form "nnnnnn.mmm". + # This method is deprecated; use BigDecimal#to_s("F") instead. + # + # require 'bigdecimal/util' + # + # d = BigDecimal("3.14") + # d.to_digits # => "3.14" + # + # source://bigdecimal//lib/bigdecimal/util.rb#90 + def to_digits; end +end + +BigDecimal::VERSION = T.let(T.unsafe(nil), String) + +# source://bigdecimal//lib/bigdecimal/util.rb#138 +class Complex < ::Numeric + # call-seq: + # cmp.to_d -> bigdecimal + # cmp.to_d(precision) -> bigdecimal + # + # Returns the value as a BigDecimal. + # + # The +precision+ parameter is required for a rational complex number. + # This parameter is used to determine the number of significant digits + # for the result. + # + # require 'bigdecimal' + # require 'bigdecimal/util' + # + # Complex(0.1234567, 0).to_d(4) # => 0.1235e0 + # Complex(Rational(22, 7), 0).to_d(3) # => 0.314e1 + # + # See also Kernel.BigDecimal. + # + # source://bigdecimal//lib/bigdecimal/util.rb#157 + def to_d(*args); end +end + +# source://bigdecimal//lib/bigdecimal/util.rb#171 +class NilClass + # call-seq: + # nil.to_d -> bigdecimal + # + # Returns nil represented as a BigDecimal. + # + # require 'bigdecimal' + # require 'bigdecimal/util' + # + # nil.to_d # => 0.0 + # + # source://bigdecimal//lib/bigdecimal/util.rb#182 + def to_d; end +end diff --git a/sorbet/rbi/gems/binding_of_caller@1.0.0.rbi b/sorbet/rbi/gems/binding_of_caller@1.0.1.rbi similarity index 99% rename from sorbet/rbi/gems/binding_of_caller@1.0.0.rbi rename to sorbet/rbi/gems/binding_of_caller@1.0.1.rbi index 848934ed0..24d9f6dcf 100644 --- a/sorbet/rbi/gems/binding_of_caller@1.0.0.rbi +++ b/sorbet/rbi/gems/binding_of_caller@1.0.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `binding_of_caller` gem. # Please instead update this file by running `bin/tapioca gem binding_of_caller`. + # source://binding_of_caller//lib/binding_of_caller/mri.rb#61 class Binding include ::BindingOfCaller::BindingExtensions diff --git a/sorbet/rbi/gems/bootsnap@1.18.4.rbi b/sorbet/rbi/gems/bootsnap@1.18.4.rbi new file mode 100644 index 000000000..5d43b5801 --- /dev/null +++ b/sorbet/rbi/gems/bootsnap@1.18.4.rbi @@ -0,0 +1,970 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `bootsnap` gem. +# Please instead update this file by running `bin/tapioca gem bootsnap`. + + +# source://bootsnap//lib/bootsnap/version.rb#3 +module Bootsnap + extend ::Bootsnap + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/bundler.rb#6 + def bundler?; end + + private + + def instrumentation_enabled=(_arg0); end + + class << self + # source://bootsnap//lib/bootsnap.rb#44 + def _instrument(event, path); end + + # source://bootsnap//lib/bootsnap.rb#137 + def absolute_path?(path); end + + # source://bootsnap//lib/bootsnap.rb#82 + def default_setup; end + + # source://bootsnap//lib/bootsnap.rb#37 + def instrumentation=(callback); end + + def instrumentation_enabled=(_arg0); end + + # source://bootsnap//lib/bootsnap.rb#24 + def log!; end + + # source://bootsnap//lib/bootsnap.rb#14 + def log_stats!; end + + # Returns the value of attribute logger. + # + # source://bootsnap//lib/bootsnap.rb#12 + def logger; end + + # source://bootsnap//lib/bootsnap.rb#28 + def logger=(logger); end + + # Allow the C extension to redefine `rb_get_path` without warning. + # Allow the C extension to redefine `rb_get_path` without warning. + def rb_get_path(_arg0); end + + # source://bootsnap//lib/bootsnap.rb#48 + def setup(cache_dir:, development_mode: T.unsafe(nil), load_path_cache: T.unsafe(nil), ignore_directories: T.unsafe(nil), readonly: T.unsafe(nil), revalidation: T.unsafe(nil), compile_cache_iseq: T.unsafe(nil), compile_cache_yaml: T.unsafe(nil), compile_cache_json: T.unsafe(nil)); end + + # source://bootsnap//lib/bootsnap.rb#78 + def unload_cache!; end + + private + + # source://bootsnap//lib/bootsnap.rb#159 + def bool_env(key, default: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap.rb#155 + def enabled?(key); end + end +end + +# source://bootsnap//lib/bootsnap/compile_cache.rb#4 +module Bootsnap::CompileCache + class << self + # source://bootsnap//lib/bootsnap/compile_cache.rb#12 + def setup(cache_dir:, iseq:, yaml:, json:, readonly: T.unsafe(nil), revalidation: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/compile_cache.rb#46 + def supported?; end + end +end + +# source://bootsnap//lib/bootsnap/compile_cache.rb#10 +class Bootsnap::CompileCache::Error < ::StandardError; end + +# source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#8 +module Bootsnap::CompileCache::ISeq + class << self + # Returns the value of attribute cache_dir. + # + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#10 + def cache_dir; end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#12 + def cache_dir=(cache_dir); end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#103 + def compile_option_updated; end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#63 + def fetch(path, cache_dir: T.unsafe(nil)); end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#80 + def input_to_output(_data, _kwargs); end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#45 + def input_to_storage(_, path); end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#110 + def install!(cache_dir); end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#72 + def precompile(path); end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#52 + def storage_to_output(binary, _args); end + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#16 + def supported?; end + end +end + +# source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#84 +module Bootsnap::CompileCache::ISeq::InstructionSequenceMixin + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#97 + def compile_option=(hash); end + + # source://bootsnap//lib/bootsnap/compile_cache/iseq.rb#85 + def load_iseq(path); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/json.rb#7 +module Bootsnap::CompileCache::JSON + class << self + # Returns the value of attribute cache_dir. + # + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#10 + def cache_dir; end + + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#12 + def cache_dir=(cache_dir); end + + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#48 + def init!; end + + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#28 + def input_to_output(data, kwargs); end + + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#16 + def input_to_storage(payload, _); end + + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#40 + def install!(cache_dir); end + + # Returns the value of attribute msgpack_factory. + # + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#9 + def msgpack_factory; end + + # Sets the attribute msgpack_factory + # + # @param value the value to set the attribute msgpack_factory to. + # + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#9 + def msgpack_factory=(_arg0); end + + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#32 + def precompile(path); end + + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#21 + def storage_to_output(data, kwargs); end + + # Returns the value of attribute supported_options. + # + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#9 + def supported_options; end + + # Sets the attribute supported_options + # + # @param value the value to set the attribute supported_options to. + # + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#9 + def supported_options=(_arg0); end + + private + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#62 + def supports_freeze?; end + end +end + +# source://bootsnap//lib/bootsnap/compile_cache/json.rb#68 +module Bootsnap::CompileCache::JSON::Patch + # source://bootsnap//lib/bootsnap/compile_cache/json.rb#69 + def load_file(path, *args, **_arg2); end +end + +module Bootsnap::CompileCache::Native + private + + def compile_option_crc32=(_arg0); end + def fetch(_arg0, _arg1, _arg2, _arg3); end + def precompile(_arg0, _arg1, _arg2); end + def readonly=(_arg0); end + def revalidation=(_arg0); end + + class << self + def compile_option_crc32=(_arg0); end + def fetch(_arg0, _arg1, _arg2, _arg3); end + def precompile(_arg0, _arg1, _arg2); end + def readonly=(_arg0); end + def revalidation=(_arg0); end + end +end + +# source://bootsnap//lib/bootsnap/compile_cache.rb#5 +Bootsnap::CompileCache::UNCOMPILABLE = T.let(T.unsafe(nil), BasicObject) + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#7 +module Bootsnap::CompileCache::YAML + class << self + # Returns the value of attribute cache_dir. + # + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#20 + def cache_dir; end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#22 + def cache_dir=(cache_dir); end + + # Returns the value of attribute implementation. + # + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#20 + def implementation; end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#57 + def init!; end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#36 + def install!(cache_dir); end + + # Returns the value of attribute msgpack_factory. + # + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#19 + def msgpack_factory; end + + # Sets the attribute msgpack_factory + # + # @param value the value to set the attribute msgpack_factory to. + # + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#19 + def msgpack_factory=(_arg0); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#124 + def patch; end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#26 + def precompile(path); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#128 + def strict_load(payload); end + + # Psych coerce strings to `Encoding.default_internal` but Message Pack only support + # UTF-8, US-ASCII and BINARY. So if Encoding.default_internal is set to anything else + # we can't safely use the cache + # + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#45 + def supported_internal_encoding?; end + + # Returns the value of attribute supported_options. + # + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#19 + def supported_options; end + + # Sets the attribute supported_options + # + # @param value the value to set the attribute supported_options to. + # + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#19 + def supported_options=(_arg0); end + end +end + +# source://bootsnap//lib/bootsnap/setup.rb#0 +class Bootsnap::CompileCache::YAML::NoTagsVisitor < ::Psych::Visitors::NoAliasRuby + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#69 + def visit(target); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#264 +module Bootsnap::CompileCache::YAML::Psych3 + extend ::Bootsnap::CompileCache::YAML::Psych3 + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#289 + def input_to_output(data, kwargs); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#267 + def input_to_storage(contents, _); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#279 + def storage_to_output(data, kwargs); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#293 +module Bootsnap::CompileCache::YAML::Psych3::Patch + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#294 + def load_file(path, *args, **_arg2); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#314 + def unsafe_load_file(path, *args, **_arg2); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#139 +module Bootsnap::CompileCache::YAML::Psych4 + extend ::Bootsnap::CompileCache::YAML::Psych4 + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#142 + def input_to_storage(contents, _); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#221 +module Bootsnap::CompileCache::YAML::Psych4::Patch + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#222 + def load_file(path, *args, **_arg2); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#242 + def unsafe_load_file(path, *args, **_arg2); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#181 +module Bootsnap::CompileCache::YAML::Psych4::SafeLoad + extend ::Bootsnap::CompileCache::YAML::Psych4::SafeLoad + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#216 + def input_to_output(data, kwargs); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#184 + def input_to_storage(contents, _); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#201 + def storage_to_output(data, kwargs); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#150 +module Bootsnap::CompileCache::YAML::Psych4::UnsafeLoad + extend ::Bootsnap::CompileCache::YAML::Psych4::UnsafeLoad + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#176 + def input_to_output(data, kwargs); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#153 + def input_to_storage(contents, _); end + + # source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#165 + def storage_to_output(data, kwargs); end +end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#11 +Bootsnap::CompileCache::YAML::SUPPORTED_INTERNAL_ENCODINGS = T.let(T.unsafe(nil), Array) + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#8 +class Bootsnap::CompileCache::YAML::Uncompilable < ::StandardError; end + +# source://bootsnap//lib/bootsnap/compile_cache/yaml.rb#9 +class Bootsnap::CompileCache::YAML::UnsupportedTags < ::Bootsnap::CompileCache::YAML::Uncompilable; end + +# source://bootsnap//lib/bootsnap/explicit_require.rb#4 +module Bootsnap::ExplicitRequire + class << self + # source://bootsnap//lib/bootsnap/explicit_require.rb#17 + def from_archdir(feature); end + + # source://bootsnap//lib/bootsnap/explicit_require.rb#13 + def from_rubylibdir(feature); end + + # source://bootsnap//lib/bootsnap/explicit_require.rb#9 + def from_self(feature); end + + # Given a set of gems, run a block with the LOAD_PATH narrowed to include + # only core ruby source paths and these gems -- that is, roughly, + # temporarily remove all gems not listed in this call from the LOAD_PATH. + # + # This is useful before bootsnap is fully-initialized to load gems that it + # depends on, without forcing full LOAD_PATH traversals. + # + # source://bootsnap//lib/bootsnap/explicit_require.rb#27 + def with_gems(*gems); end + end +end + +# source://bootsnap//lib/bootsnap/explicit_require.rb#5 +Bootsnap::ExplicitRequire::ARCHDIR = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/explicit_require.rb#7 +Bootsnap::ExplicitRequire::DLEXT = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/explicit_require.rb#6 +Bootsnap::ExplicitRequire::RUBYLIBDIR = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap.rb#9 +class Bootsnap::InvalidConfiguration < ::StandardError; end + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#4 +module Bootsnap::LoadPathCache + class << self + # Returns the value of attribute enabled. + # + # source://bootsnap//lib/bootsnap/load_path_cache.rb#27 + def enabled?; end + + # Returns the value of attribute load_path_cache. + # + # source://bootsnap//lib/bootsnap/load_path_cache.rb#27 + def load_path_cache; end + + # Returns the value of attribute loaded_features_index. + # + # source://bootsnap//lib/bootsnap/load_path_cache.rb#27 + def loaded_features_index; end + + # source://bootsnap//lib/bootsnap/load_path_cache.rb#31 + def setup(cache_path:, development_mode:, ignore_directories:, readonly: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache.rb#56 + def supported?; end + + # source://bootsnap//lib/bootsnap/load_path_cache.rb#48 + def unload!; end + end +end + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#22 +Bootsnap::LoadPathCache::CACHED_EXTENSIONS = T.let(T.unsafe(nil), Array) + +# source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#7 +class Bootsnap::LoadPathCache::Cache + # @return [Cache] a new instance of Cache + # + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#10 + def initialize(store, path_obj, development_mode: T.unsafe(nil)); end + + # Try to resolve this feature to an absolute path without traversing the + # loadpath. + # + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#56 + def find(feature); end + + # What is the path item that contains the dir as child? + # e.g. given "/a/b/c/d" exists, and the path is ["/a/b"], load_dir("c/d") + # is "/a/b". + # + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#22 + def load_dir(dir); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#116 + def push_paths(sender, *paths); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#122 + def reinitialize(path_obj = T.unsafe(nil)); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#110 + def unshift_paths(sender, *paths); end + + private + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#135 + def dir_changed?; end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#180 + def expand_path(feature); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#211 + def maybe_append_extension(feature); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#188 + def now; end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#145 + def push_paths_locked(*paths); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#207 + def search_index(feature); end + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#184 + def stale?; end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#239 + def try_ext(feature); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#219 + def try_index(feature); end + + # source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#163 + def unshift_paths_locked(*paths); end +end + +# seconds +# +# source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#8 +Bootsnap::LoadPathCache::Cache::AGE_THRESHOLD = T.let(T.unsafe(nil), Integer) + +# { 'enumerator' => nil, 'enumerator.so' => nil, ... } +# +# source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#32 +Bootsnap::LoadPathCache::Cache::BUILTIN_FEATURES = T.let(T.unsafe(nil), Hash) + +# source://bootsnap//lib/bootsnap/load_path_cache/cache.rb#27 +Bootsnap::LoadPathCache::Cache::TRUFFLERUBY_LIB_DIR_PREFIX = T.let(T.unsafe(nil), T.untyped) + +# source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#5 +module Bootsnap::LoadPathCache::ChangeObserver + class << self + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#65 + def register(arr, observer); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#74 + def unregister(arr); end + end +end + +# source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#6 +module Bootsnap::LoadPathCache::ChangeObserver::ArrayMixin + # For each method that adds items to one end or another of the array + # (<<, push, unshift, concat), override that method to also notify the + # observer of the change. + # + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#10 + def <<(entry); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def []=(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#15 + def append(*entries); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def clear(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#58 + def clone; end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def collect!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def compact!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#27 + def concat(entries); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def delete(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def delete_at(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def delete_if(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#58 + def dup; end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def fill(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def flatten!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def insert(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def keep_if(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def map!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def pop(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#21 + def prepend(*entries); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#15 + def push(*entries); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def reject!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def replace(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def reverse!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def rotate!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def select!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def shift(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def shuffle!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def slice!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def sort!(*args, &block); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#51 + def sort_by!(*args, &block); end + + # uniq! keeps the first occurrence of each path, otherwise preserving + # order, preserving the effective load path + # + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#34 + def uniq!(*args); end + + # source://bootsnap//lib/bootsnap/load_path_cache/change_observer.rb#21 + def unshift(*entries); end +end + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#16 +Bootsnap::LoadPathCache::DLEXT = T.let(T.unsafe(nil), String) + +# This is nil on linux and darwin, but I think it's '.o' on some other +# platform. I'm not really sure which, but it seems better to replicate +# ruby's semantics as faithfully as possible. +# +# source://bootsnap//lib/bootsnap/load_path_cache.rb#20 +Bootsnap::LoadPathCache::DLEXT2 = T.let(T.unsafe(nil), T.untyped) + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#11 +Bootsnap::LoadPathCache::DL_EXTENSIONS = T.let(T.unsafe(nil), Array) + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#7 +Bootsnap::LoadPathCache::DOT_RB = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#8 +Bootsnap::LoadPathCache::DOT_SO = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#5 +Bootsnap::LoadPathCache::FALLBACK_SCAN = T.let(T.unsafe(nil), BasicObject) + +# LoadedFeaturesIndex partially mirrors an internal structure in ruby that +# we can't easily obtain an interface to. +# +# This works around an issue where, without bootsnap, *ruby* knows that it +# has already required a file by its short name (e.g. require 'bundler') if +# a new instance of bundler is added to the $LOAD_PATH which resolves to a +# different absolute path. This class makes bootsnap smart enough to +# realize that it has already loaded 'bundler', and not just +# '/path/to/bundler'. +# +# If you disable LoadedFeaturesIndex, you can see the problem this solves by: +# +# 1. `require 'a'` +# 2. Prepend a new $LOAD_PATH element containing an `a.rb` +# 3. `require 'a'` +# +# Ruby returns false from step 3. +# With bootsnap but with no LoadedFeaturesIndex, this loads two different +# `a.rb`s. +# With bootsnap and with LoadedFeaturesIndex, this skips the second load, +# returning false like ruby. +# +# source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#26 +class Bootsnap::LoadPathCache::LoadedFeaturesIndex + # @return [LoadedFeaturesIndex] a new instance of LoadedFeaturesIndex + # + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#27 + def initialize; end + + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#72 + def cursor(short); end + + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#78 + def identify(short, cursor); end + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#68 + def key?(feature); end + + # We've optimized for initialize and register to be fast, and purge to be tolerable. + # If access patterns make this not-okay, we can lazy-invert the LFI on + # first purge and work from there. + # + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#54 + def purge(feature); end + + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#61 + def purge_multi(features); end + + # There is a relatively uncommon case where we could miss adding an + # entry: + # + # If the user asked for e.g. `require 'bundler'`, and we went through the + # `FALLBACK_SCAN` pathway in `kernel_require.rb` and therefore did not + # pass `long` (the full expanded absolute path), then we did are not able + # to confidently add the `bundler.rb` form to @lfi. + # + # We could either: + # + # 1. Just add `bundler.rb`, `bundler.so`, and so on, which is close but + # not quite right; or + # 2. Inspect $LOADED_FEATURES upon return from yield to find the matching + # entry. + # + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#105 + def register(short, long); end + + private + + # Might Ruby automatically search for this extension if + # someone tries to 'require' the file without it? E.g. Ruby + # will implicitly try 'x.rb' if you ask for 'x'. + # + # This is complex and platform-dependent, and the Ruby docs are a little + # handwavy about what will be tried when and in what order. + # So optimistically pretend that all known elidable extensions + # will be tried on all platforms, and that people are unlikely + # to name files in a way that assumes otherwise. + # (E.g. It's unlikely that someone will know that their code + # will _never_ run on MacOS, and therefore think they can get away + # with calling a Ruby file 'x.dylib.rb' and then requiring it as 'x.dylib'.) + # + # See . + # + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#146 + def extension_elidable?(feature); end + + # source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#150 + def strip_extension_if_elidable(feature); end +end + +# source://bootsnap//lib/bootsnap/load_path_cache/loaded_features_index.rb#129 +Bootsnap::LoadPathCache::LoadedFeaturesIndex::STRIP_EXTENSION = T.let(T.unsafe(nil), Regexp) + +# source://bootsnap//lib/bootsnap/load_path_cache/path.rb#7 +class Bootsnap::LoadPathCache::Path + # @return [Path] a new instance of Path + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#24 + def initialize(path, real: T.unsafe(nil)); end + + # Return a list of all the requirable files and all of the subdirectories + # of this +Path+. + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#59 + def entries_and_dirs(store); end + + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#82 + def expanded_path; end + + # True if the path exists, but represents a non-directory object + # + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#47 + def non_directory?; end + + # Returns the value of attribute path. + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#22 + def path; end + + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#53 + def relative?; end + + # A path is considered 'stable' if it is part of a Gem.path or the ruby + # distribution. When adding or removing files in these paths, the cache + # must be cleared before the change will be noticed. + # + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#11 + def stable?; end + + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#29 + def to_realpath; end + + # A path is considered volatile if it doesn't live under a Gem.path or + # the ruby distribution root. These paths are scanned for new additions + # more frequently. + # + # @return [Boolean] + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#18 + def volatile?; end + + private + + # last time a directory was modified in this subtree. +dirs+ should be a + # list of relative paths to directories under +path+. e.g. for /a/b and + # /a/b/c, pass ('/a/b', ['c']) + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#99 + def latest_mtime(path, dirs); end + + # (expensive) returns [entries, dirs] + # + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#92 + def scan!; end + + # source://bootsnap//lib/bootsnap/load_path_cache/path.rb#123 + def stability; end +end + +# Built-in ruby lib stuff doesn't change, but things can occasionally be +# installed into sitedir, which generally lives under rubylibdir. +# +# source://bootsnap//lib/bootsnap/load_path_cache/path.rb#120 +Bootsnap::LoadPathCache::Path::RUBY_LIBDIR = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/load_path_cache/path.rb#121 +Bootsnap::LoadPathCache::Path::RUBY_SITEDIR = T.let(T.unsafe(nil), String) + +# a Path can be either stable of volatile, depending on how frequently we +# expect its contents may change. Stable paths aren't rescanned nearly as +# often. +# +# source://bootsnap//lib/bootsnap/load_path_cache/path.rb#115 +Bootsnap::LoadPathCache::Path::STABLE = T.let(T.unsafe(nil), Symbol) + +# source://bootsnap//lib/bootsnap/load_path_cache/path.rb#116 +Bootsnap::LoadPathCache::Path::VOLATILE = T.let(T.unsafe(nil), Symbol) + +# source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#7 +module Bootsnap::LoadPathCache::PathScanner + class << self + # source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#23 + def call(path); end + + # Returns the value of attribute ignored_directories. + # + # source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#21 + def ignored_directories; end + + # Sets the attribute ignored_directories + # + # @param value the value to set the attribute ignored_directories to. + # + # source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#21 + def ignored_directories=(_arg0); end + + # source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#69 + def os_path(path); end + + # source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#49 + def walk(absolute_dir_path, relative_dir_path, &block); end + end +end + +# source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#10 +Bootsnap::LoadPathCache::PathScanner::ALTERNATIVE_NATIVE_EXTENSIONS_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#12 +Bootsnap::LoadPathCache::PathScanner::BUNDLE_PATH = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#9 +Bootsnap::LoadPathCache::PathScanner::NORMALIZE_NATIVE_EXTENSIONS = T.let(T.unsafe(nil), FalseClass) + +# source://bootsnap//lib/bootsnap/load_path_cache/path_scanner.rb#8 +Bootsnap::LoadPathCache::PathScanner::REQUIRABLE_EXTENSIONS = T.let(T.unsafe(nil), Array) + +# source://bootsnap//lib/bootsnap/load_path_cache.rb#9 +Bootsnap::LoadPathCache::SLASH = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/load_path_cache/store.rb#9 +class Bootsnap::LoadPathCache::Store + # @return [Store] a new instance of Store + # + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#16 + def initialize(store_path, readonly: T.unsafe(nil)); end + + # @raise [SetOutsideTransactionNotAllowed] + # + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#28 + def fetch(key); end + + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#24 + def get(key); end + + # @raise [SetOutsideTransactionNotAllowed] + # + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#40 + def set(key, value); end + + # @raise [NestedTransactionError] + # + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#49 + def transaction; end + + private + + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#66 + def commit_transaction; end + + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#112 + def default_data; end + + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#95 + def dump_data; end + + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#73 + def load_data; end + + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#61 + def mark_for_mutation!; end + + # source://bootsnap//lib/bootsnap/load_path_cache/store.rb#116 + def mkdir_p(path); end +end + +# source://bootsnap//lib/bootsnap/load_path_cache/store.rb#11 +Bootsnap::LoadPathCache::Store::CURRENT_VERSION = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/load_path_cache/store.rb#13 +class Bootsnap::LoadPathCache::Store::NestedTransactionError < ::StandardError; end + +# source://bootsnap//lib/bootsnap/load_path_cache/store.rb#14 +class Bootsnap::LoadPathCache::Store::SetOutsideTransactionNotAllowed < ::StandardError; end + +# source://bootsnap//lib/bootsnap/load_path_cache/store.rb#10 +Bootsnap::LoadPathCache::Store::VERSION_KEY = T.let(T.unsafe(nil), String) + +# source://bootsnap//lib/bootsnap/version.rb#4 +Bootsnap::VERSION = T.let(T.unsafe(nil), String) + +module JSON + extend ::Bootsnap::CompileCache::JSON::Patch +end + +# source://bootsnap//lib/bootsnap/load_path_cache/core_ext/kernel_require.rb#3 +module Kernel + private + + # source://bootsnap//lib/bootsnap/load_path_cache/core_ext/kernel_require.rb#8 + def zeitwerk_original_require(path); end +end + +module Psych + extend ::Bootsnap::CompileCache::YAML::Psych4::Patch +end + +class RubyVM::InstructionSequence + extend ::Bootsnap::CompileCache::ISeq::InstructionSequenceMixin +end diff --git a/sorbet/rbi/gems/bootstrap@4.6.2.rbi b/sorbet/rbi/gems/bootstrap@4.6.2.rbi index 273181553..cec26c1b3 100644 --- a/sorbet/rbi/gems/bootstrap@4.6.2.rbi +++ b/sorbet/rbi/gems/bootstrap@4.6.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `bootstrap` gem. # Please instead update this file by running `bin/tapioca gem bootstrap`. + # source://bootstrap//lib/bootstrap/version.rb#3 module Bootstrap class << self @@ -63,7 +64,12 @@ Bootstrap::BOOTSTRAP_SHA = T.let(T.unsafe(nil), String) module Bootstrap::Rails; end # source://bootstrap//lib/bootstrap/engine.rb#8 -class Bootstrap::Rails::Engine < ::Rails::Engine; end +class Bootstrap::Rails::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # source://bootstrap//lib/bootstrap/version.rb#4 Bootstrap::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/builder@3.2.4.rbi b/sorbet/rbi/gems/builder@3.3.0.rbi similarity index 93% rename from sorbet/rbi/gems/builder@3.2.4.rbi rename to sorbet/rbi/gems/builder@3.3.0.rbi index f99d49237..6b1256f0c 100644 --- a/sorbet/rbi/gems/builder@3.2.4.rbi +++ b/sorbet/rbi/gems/builder@3.3.0.rbi @@ -4,10 +4,11 @@ # This is an autogenerated file for types exported from the `builder` gem. # Please instead update this file by running `bin/tapioca gem builder`. + # If the Builder::XChar module is not currently defined, fail on any # name clashes in standard library classes. # -# source://builder//lib/builder/blankslate.rb#17 +# source://builder//lib/builder/xmlbase.rb#4 module Builder class << self # source://builder//lib/builder/xchar.rb#13 @@ -15,12 +16,9 @@ module Builder end end -# source://builder//lib/builder/blankslate.rb#19 -Builder::BlankSlate = BasicObject - # Generic error for builder # -# source://builder//lib/builder/xmlbase.rb#9 +# source://builder//lib/builder/xmlbase.rb#7 class Builder::IllegalBlockError < ::RuntimeError; end # source://builder//lib/builder/xchar.rb#33 @@ -85,7 +83,7 @@ Builder::XChar::XML_PREDEFINED = T.let(T.unsafe(nil), Regexp) # XmlBase is a base class for building XML builders. See # Builder::XmlMarkup and Builder::XmlEvents for examples. # -# source://builder//lib/builder/xmlbase.rb#13 +# source://builder//lib/builder/xmlbase.rb#11 class Builder::XmlBase < ::BasicObject # Create an XML markup builder. # @@ -100,7 +98,7 @@ class Builder::XmlBase < ::BasicObject # # @return [XmlBase] a new instance of XmlBase # - # source://builder//lib/builder/xmlbase.rb#29 + # source://builder//lib/builder/xmlbase.rb#27 def initialize(indent = T.unsafe(nil), initial = T.unsafe(nil), encoding = T.unsafe(nil)); end # Append text to the output target without escaping any markup. @@ -117,19 +115,19 @@ class Builder::XmlBase < ::BasicObject # method/operation builders can use other builders as their # targets. # - # source://builder//lib/builder/xmlbase.rb#118 + # source://builder//lib/builder/xmlbase.rb#116 def <<(text); end # @return [Boolean] # - # source://builder//lib/builder/xmlbase.rb#35 + # source://builder//lib/builder/xmlbase.rb#33 def explicit_nil_handling?; end # Create XML markup based on the name of the method. This method # is never invoked directly, but is called for each markup method # in the markup block that isn't cached. # - # source://builder//lib/builder/xmlbase.rb#92 + # source://builder//lib/builder/xmlbase.rb#90 def method_missing(sym, *args, &block); end # For some reason, nil? is sent to the XmlMarkup object. If nil? @@ -141,14 +139,14 @@ class Builder::XmlBase < ::BasicObject # # @return [Boolean] # - # source://builder//lib/builder/xmlbase.rb#128 + # source://builder//lib/builder/xmlbase.rb#126 def nil?; end # Create a tag named +sym+. Other than the first argument which # is the tag name, the arguments are the same as the tags # implemented via method_missing. # - # source://builder//lib/builder/xmlbase.rb#42 + # source://builder//lib/builder/xmlbase.rb#40 def tag!(sym, *args, &block); end # Append text to the output target. Escape any markup. May be @@ -156,24 +154,24 @@ class Builder::XmlBase < ::BasicObject # # builder.p { |b| b.br; b.text! "HI" } #=>


HI

# - # source://builder//lib/builder/xmlbase.rb#101 + # source://builder//lib/builder/xmlbase.rb#99 def text!(text); end private - # source://builder//lib/builder/xmlbase.rb#136 + # source://builder//lib/builder/xmlbase.rb#134 def _escape(text); end - # source://builder//lib/builder/xmlbase.rb#159 + # source://builder//lib/builder/xmlbase.rb#157 def _escape_attribute(text); end - # source://builder//lib/builder/xmlbase.rb#169 + # source://builder//lib/builder/xmlbase.rb#167 def _indent; end - # source://builder//lib/builder/xmlbase.rb#174 + # source://builder//lib/builder/xmlbase.rb#172 def _nested_structures(block); end - # source://builder//lib/builder/xmlbase.rb#164 + # source://builder//lib/builder/xmlbase.rb#162 def _newline; end # If XmlBase.cache_method_calls = true, we dynamicly create the method @@ -183,20 +181,20 @@ class Builder::XmlBase < ::BasicObject # method_missing is very slow, this speeds up document generation # significantly. # - # source://builder//lib/builder/xmlbase.rb#187 + # source://builder//lib/builder/xmlbase.rb#185 def cache_method_call(sym); end class << self # Returns the value of attribute cache_method_calls. # - # source://builder//lib/builder/xmlbase.rb#16 + # source://builder//lib/builder/xmlbase.rb#14 def cache_method_calls; end # Sets the attribute cache_method_calls # # @param value the value to set the attribute cache_method_calls to. # - # source://builder//lib/builder/xmlbase.rb#16 + # source://builder//lib/builder/xmlbase.rb#14 def cache_method_calls=(_arg0); end end end @@ -347,15 +345,15 @@ end # # Example: # -# xm = Builder.new(:indent=>2) +# xm = Builder::XmlMarkup.new(:indent=>2) # # xm will produce nicely formatted and indented XML. # -# xm = Builder.new(:indent=>2, :margin=>4) +# xm = Builder::XmlMarkup.new(:indent=>2, :margin=>4) # # xm will produce nicely formatted and indented XML with 2 # # spaces per indent and an over all indentation level of 4. # # builder = Builder::XmlMarkup.new(:target=>$stdout, :indent=>2) -# builder.name { |b| b.first("Jim"); b.last("Weirich) } +# builder.name { |b| b.first("Jim"); b.last("Weirich") } # # prints: # # # # Jim @@ -384,7 +382,7 @@ end # # xml_builder = Builder::XmlMarkup.new # xml_builder.div { |xml| -# xml.stong("text") +# xml.strong("text") # } # # source://builder//lib/builder/xmlmarkup.rb#161 diff --git a/sorbet/rbi/gems/capistrano-bundler@2.1.0.rbi b/sorbet/rbi/gems/capistrano-bundler@2.1.1.rbi similarity index 99% rename from sorbet/rbi/gems/capistrano-bundler@2.1.0.rbi rename to sorbet/rbi/gems/capistrano-bundler@2.1.1.rbi index 1ded8e06e..7b27a600f 100644 --- a/sorbet/rbi/gems/capistrano-bundler@2.1.0.rbi +++ b/sorbet/rbi/gems/capistrano-bundler@2.1.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano-bundler` gem. # Please instead update this file by running `bin/tapioca gem capistrano-bundler`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano-ext@1.2.1.rbi b/sorbet/rbi/gems/capistrano-ext@1.2.1.rbi index a77f07c10..4ba74e1ce 100644 --- a/sorbet/rbi/gems/capistrano-ext@1.2.1.rbi +++ b/sorbet/rbi/gems/capistrano-ext@1.2.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano-ext` gem. # Please instead update this file by running `bin/tapioca gem capistrano-ext`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano-faster-assets@1.1.0.rbi b/sorbet/rbi/gems/capistrano-faster-assets@1.1.0.rbi index a0712013e..5fd1d5d36 100644 --- a/sorbet/rbi/gems/capistrano-faster-assets@1.1.0.rbi +++ b/sorbet/rbi/gems/capistrano-faster-assets@1.1.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano-faster-assets` gem. # Please instead update this file by running `bin/tapioca gem capistrano-faster-assets`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano-maintenance@1.2.1.rbi b/sorbet/rbi/gems/capistrano-maintenance@1.2.1.rbi index 2a2f8a793..ae39b5c3c 100644 --- a/sorbet/rbi/gems/capistrano-maintenance@1.2.1.rbi +++ b/sorbet/rbi/gems/capistrano-maintenance@1.2.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano-maintenance` gem. # Please instead update this file by running `bin/tapioca gem capistrano-maintenance`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano-rails@1.6.2.rbi b/sorbet/rbi/gems/capistrano-rails@1.6.3.rbi similarity index 99% rename from sorbet/rbi/gems/capistrano-rails@1.6.2.rbi rename to sorbet/rbi/gems/capistrano-rails@1.6.3.rbi index 588246fe2..62a4570c9 100644 --- a/sorbet/rbi/gems/capistrano-rails@1.6.2.rbi +++ b/sorbet/rbi/gems/capistrano-rails@1.6.3.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano-rails` gem. # Please instead update this file by running `bin/tapioca gem capistrano-rails`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano-rvm@0.1.2.rbi b/sorbet/rbi/gems/capistrano-rvm@0.1.2.rbi index 38e5c3864..ad64fc9a7 100644 --- a/sorbet/rbi/gems/capistrano-rvm@0.1.2.rbi +++ b/sorbet/rbi/gems/capistrano-rvm@0.1.2.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano-rvm` gem. # Please instead update this file by running `bin/tapioca gem capistrano-rvm`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano-sidekiq@2.3.0-fc20388544468d7fedbd89d06df9ea8225c8e6a0.rbi b/sorbet/rbi/gems/capistrano-sidekiq@2.3.0-fc20388544468d7fedbd89d06df9ea8225c8e6a0.rbi index 06790d83c..9ed871986 100644 --- a/sorbet/rbi/gems/capistrano-sidekiq@2.3.0-fc20388544468d7fedbd89d06df9ea8225c8e6a0.rbi +++ b/sorbet/rbi/gems/capistrano-sidekiq@2.3.0-fc20388544468d7fedbd89d06df9ea8225c8e6a0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano-sidekiq` gem. # Please instead update this file by running `bin/tapioca gem capistrano-sidekiq`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano3-puma@5.2.0.rbi b/sorbet/rbi/gems/capistrano3-puma@5.2.0.rbi index 3668eda28..50ec46233 100644 --- a/sorbet/rbi/gems/capistrano3-puma@5.2.0.rbi +++ b/sorbet/rbi/gems/capistrano3-puma@5.2.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano3-puma` gem. # Please instead update this file by running `bin/tapioca gem capistrano3-puma`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capistrano@3.17.3.rbi b/sorbet/rbi/gems/capistrano@3.19.1.rbi similarity index 99% rename from sorbet/rbi/gems/capistrano@3.17.3.rbi rename to sorbet/rbi/gems/capistrano@3.19.1.rbi index 1fbb4fb6d..3eabdecca 100644 --- a/sorbet/rbi/gems/capistrano@3.17.3.rbi +++ b/sorbet/rbi/gems/capistrano@3.19.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `capistrano` gem. # Please instead update this file by running `bin/tapioca gem capistrano`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/capybara@3.39.2.rbi b/sorbet/rbi/gems/capybara@3.40.0.rbi similarity index 89% rename from sorbet/rbi/gems/capybara@3.39.2.rbi rename to sorbet/rbi/gems/capybara@3.40.0.rbi index b0fb714a3..28894b36f 100644 --- a/sorbet/rbi/gems/capybara@3.39.2.rbi +++ b/sorbet/rbi/gems/capybara@3.40.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `capybara` gem. # Please instead update this file by running `bin/tapioca gem capybara`. + # source://capybara//lib/capybara/session/config.rb#5 module Capybara extend ::Capybara::DSL @@ -14,7 +15,7 @@ module Capybara # @param html [String] The raw html # @return [Nokogiri::HTML::Document] HTML document # - # source://capybara//lib/capybara.rb#389 + # source://capybara//lib/capybara.rb#390 def HTML(html); end # Add a new selector to Capybara. Selectors can be used by various methods in Capybara @@ -405,10 +406,10 @@ module Capybara # source://capybara//lib/capybara.rb#337 def session_name; end - # source://capybara//lib/capybara.rb#345 + # source://capybara//lib/capybara.rb#346 def session_name=(name); end - # source://capybara//lib/capybara.rb#409 + # source://capybara//lib/capybara.rb#410 def session_options; end # Wraps the given string, which should contain an HTML document or fragment @@ -474,7 +475,7 @@ module Capybara # Yield a block using a specific session name or {Capybara::Session} instance. # - # source://capybara//lib/capybara.rb#357 + # source://capybara//lib/capybara.rb#358 def using_session(name_or_session, &block); end # Yield a block using a specific wait time @@ -496,16 +497,16 @@ module Capybara private - # source://capybara//lib/capybara.rb#415 + # source://capybara//lib/capybara.rb#416 def config; end - # source://capybara//lib/capybara.rb#419 + # source://capybara//lib/capybara.rb#420 def session_pool; end - # source://capybara//lib/capybara.rb#425 + # source://capybara//lib/capybara.rb#426 def specified_session; end - # source://capybara//lib/capybara.rb#433 + # source://capybara//lib/capybara.rb#434 def specified_session=(session); end end end @@ -942,6 +943,9 @@ module Capybara::DSL # source://capybara//lib/capybara/dsl.rb#51 def has_current_path?(*_arg0, **_arg1, &_arg2); end + # source://capybara//lib/capybara/dsl.rb#51 + def has_element?(*_arg0, **_arg1, &_arg2); end + # source://capybara//lib/capybara/dsl.rb#51 def has_field?(*_arg0, **_arg1, &_arg2); end @@ -963,6 +967,9 @@ module Capybara::DSL # source://capybara//lib/capybara/dsl.rb#51 def has_no_current_path?(*_arg0, **_arg1, &_arg2); end + # source://capybara//lib/capybara/dsl.rb#51 + def has_no_element?(*_arg0, **_arg1, &_arg2); end + # source://capybara//lib/capybara/dsl.rb#51 def has_no_field?(*_arg0, **_arg1, &_arg2); end @@ -1149,7 +1156,7 @@ module Capybara::DSL end end -# source://capybara//lib/capybara.rb#446 +# source://capybara//lib/capybara.rb#447 module Capybara::Driver; end # source://capybara//lib/capybara/driver/base.rb#3 @@ -1745,12 +1752,12 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_button?} # - # source://capybara//lib/capybara/minitest.rb#285 + # source://capybara//lib/capybara/minitest.rb#298 def assert_button(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_checked_field?} # - # source://capybara//lib/capybara/minitest.rb#302 + # source://capybara//lib/capybara/minitest.rb#315 def assert_checked_field(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_text} @@ -1760,7 +1767,7 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_css?} # - # source://capybara//lib/capybara/minitest.rb#285 + # source://capybara//lib/capybara/minitest.rb#298 def assert_css(*args, &optional_filter_block); end # See {Capybara::SessionMatchers#assert_current_path} @@ -1768,19 +1775,24 @@ module Capybara::Minitest::Assertions # source://capybara//lib/capybara/minitest.rb#53 def assert_current_path(*args, **kwargs, &optional_filter_block); end + # See {Capybara::Node::Matchers#has_element?} + # + # source://capybara//lib/capybara/minitest.rb#298 + def assert_element(*args, &optional_filter_block); end + # See {Capybara::Node::Matchers#has_field?} # - # source://capybara//lib/capybara/minitest.rb#285 + # source://capybara//lib/capybara/minitest.rb#298 def assert_field(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_link?} # - # source://capybara//lib/capybara/minitest.rb#285 + # source://capybara//lib/capybara/minitest.rb#298 def assert_link(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#matches_css?} # - # source://capybara//lib/capybara/minitest.rb#351 + # source://capybara//lib/capybara/minitest.rb#364 def assert_matches_css(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_matches_selector} @@ -1795,7 +1807,7 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#matches_xpath?} # - # source://capybara//lib/capybara/minitest.rb#351 + # source://capybara//lib/capybara/minitest.rb#364 def assert_matches_xpath(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_ancestor} @@ -1805,12 +1817,12 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_no_button?} # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def assert_no_button(*args, &optional_filter_block); end # Assert that provided checked_field does not exist # - # source://capybara//lib/capybara/minitest.rb#309 + # source://capybara//lib/capybara/minitest.rb#322 def assert_no_checked_field(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_text} @@ -1820,7 +1832,7 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_no_css?} # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def assert_no_css(*args, &optional_filter_block); end # See {Capybara::SessionMatchers#assert_no_current_path} @@ -1828,19 +1840,24 @@ module Capybara::Minitest::Assertions # source://capybara//lib/capybara/minitest.rb#53 def assert_no_current_path(*args, **kwargs, &optional_filter_block); end + # Assert that provided element does not exist + # + # source://capybara//lib/capybara/minitest.rb#305 + def assert_no_element(*args, &optional_filter_block); end + # See {Capybara::Node::Matchers#has_no_field?} # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def assert_no_field(*args, &optional_filter_block); end # Assert that provided link does not exist # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def assert_no_link(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_no_select?} # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def assert_no_select(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_selector} @@ -1855,7 +1872,7 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_no_table?} # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def assert_no_table(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_text} @@ -1870,12 +1887,12 @@ module Capybara::Minitest::Assertions # Assert that provided unchecked field does not exist # - # source://capybara//lib/capybara/minitest.rb#309 + # source://capybara//lib/capybara/minitest.rb#322 def assert_no_unchecked_field(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_no_xpath?} # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def assert_no_xpath(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_none_of_selectors} @@ -1885,7 +1902,7 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#not_matches_css?} # - # source://capybara//lib/capybara/minitest.rb#357 + # source://capybara//lib/capybara/minitest.rb#370 def assert_not_matches_css(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_not_matches_selector} @@ -1895,12 +1912,12 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#not_matches_xpath?} # - # source://capybara//lib/capybara/minitest.rb#357 + # source://capybara//lib/capybara/minitest.rb#370 def assert_not_matches_xpath(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_select?} # - # source://capybara//lib/capybara/minitest.rb#285 + # source://capybara//lib/capybara/minitest.rb#298 def assert_select(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_selector} @@ -1915,7 +1932,7 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_table?} # - # source://capybara//lib/capybara/minitest.rb#285 + # source://capybara//lib/capybara/minitest.rb#298 def assert_table(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_text} @@ -1930,12 +1947,12 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_unchecked_field?} # - # source://capybara//lib/capybara/minitest.rb#302 + # source://capybara//lib/capybara/minitest.rb#315 def assert_unchecked_field(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_xpath?} # - # source://capybara//lib/capybara/minitest.rb#285 + # source://capybara//lib/capybara/minitest.rb#298 def assert_xpath(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_ancestor} @@ -1945,12 +1962,12 @@ module Capybara::Minitest::Assertions # Assert that provided button does not exist # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def refute_button(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_no_checked_field?} # - # source://capybara//lib/capybara/minitest.rb#309 + # source://capybara//lib/capybara/minitest.rb#322 def refute_checked_field(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_text} @@ -1960,7 +1977,7 @@ module Capybara::Minitest::Assertions # Assert that provided css does not exist # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def refute_css(*args, &optional_filter_block); end # See {Capybara::SessionMatchers#assert_no_current_path} @@ -1968,19 +1985,24 @@ module Capybara::Minitest::Assertions # source://capybara//lib/capybara/minitest.rb#53 def refute_current_path(*args, **kwargs, &optional_filter_block); end + # See {Capybara::Node::Matchers#has_no_element?} + # + # source://capybara//lib/capybara/minitest.rb#305 + def refute_element(*args, &optional_filter_block); end + # Assert that provided field does not exist # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def refute_field(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#has_no_link?} # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def refute_link(*args, &optional_filter_block); end # Assert that element matches css # - # source://capybara//lib/capybara/minitest.rb#357 + # source://capybara//lib/capybara/minitest.rb#370 def refute_matches_css(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_not_matches_selector} @@ -1990,12 +2012,12 @@ module Capybara::Minitest::Assertions # Assert that element does not match xpath # - # source://capybara//lib/capybara/minitest.rb#357 + # source://capybara//lib/capybara/minitest.rb#370 def refute_matches_xpath(*args, &optional_filter_block); end # Assert that provided select does not exist # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def refute_select(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_selector} @@ -2010,7 +2032,7 @@ module Capybara::Minitest::Assertions # Assert that provided table does not exist # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def refute_table(*args, &optional_filter_block); end # See {Capybara::Node::Matchers#assert_no_text} @@ -2025,20 +2047,20 @@ module Capybara::Minitest::Assertions # See {Capybara::Node::Matchers#has_no_unchecked_field?} # - # source://capybara//lib/capybara/minitest.rb#309 + # source://capybara//lib/capybara/minitest.rb#322 def refute_unchecked_field(*args, &optional_filter_block); end # Assert that provide xpath does not exist # - # source://capybara//lib/capybara/minitest.rb#292 + # source://capybara//lib/capybara/minitest.rb#305 def refute_xpath(*args, &optional_filter_block); end private - # source://capybara//lib/capybara/minitest.rb#367 + # source://capybara//lib/capybara/minitest.rb#380 def determine_subject(args); end - # source://capybara//lib/capybara/minitest.rb#378 + # source://capybara//lib/capybara/minitest.rb#391 def extract_locator(args); end end @@ -3157,7 +3179,7 @@ end # source://capybara//lib/capybara/node/matchers.rb#5 module Capybara::Node::Matchers - # source://capybara//lib/capybara/node/matchers.rb#816 + # source://capybara//lib/capybara/node/matchers.rb#841 def ==(other); end # Asserts that all of the provided selectors are present on the given page @@ -3190,7 +3212,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @raise [Capybara::ExpectationNotMet] If the selector does not exist # - # source://capybara//lib/capybara/node/matchers.rb#741 + # source://capybara//lib/capybara/node/matchers.rb#766 def assert_ancestor(*args, &optional_filter_block); end # Asserts that any of the provided selectors are present on the given page @@ -3227,7 +3249,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @raise [Capybara::ExpectationNotMet] If the selector does not match # - # source://capybara//lib/capybara/node/matchers.rb#561 + # source://capybara//lib/capybara/node/matchers.rb#586 def assert_matches_selector(*args, &optional_filter_block); end # Asserts that an element has the specified CSS styles. @@ -3240,7 +3262,7 @@ module Capybara::Node::Matchers # source://capybara//lib/capybara/node/matchers.rb#126 def assert_matches_style(styles = T.unsafe(nil), **options); end - # source://capybara//lib/capybara/node/matchers.rb#749 + # source://capybara//lib/capybara/node/matchers.rb#774 def assert_no_ancestor(*args, &optional_filter_block); end # Asserts that a given selector is not on the page or a descendant of the current node. @@ -3262,7 +3284,7 @@ module Capybara::Node::Matchers # source://capybara//lib/capybara/node/matchers.rb#233 def assert_no_selector(*args, &optional_filter_block); end - # source://capybara//lib/capybara/node/matchers.rb#792 + # source://capybara//lib/capybara/node/matchers.rb#817 def assert_no_sibling(*args, &optional_filter_block); end # Asserts that the page or current node doesn't have the given text content, @@ -3273,7 +3295,7 @@ module Capybara::Node::Matchers # @raise [Capybara::ExpectationNotMet] if the assertion hasn't succeeded during wait time # @return [true] # - # source://capybara//lib/capybara/node/matchers.rb#691 + # source://capybara//lib/capybara/node/matchers.rb#716 def assert_no_text(type_or_text, *args, **opts); end # Asserts that none of the provided selectors are present on the given page @@ -3302,7 +3324,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @raise [Capybara::ExpectationNotMet] If the selector matches # - # source://capybara//lib/capybara/node/matchers.rb#575 + # source://capybara//lib/capybara/node/matchers.rb#600 def assert_not_matches_selector(*args, &optional_filter_block); end # Asserts that a given selector is on the page or a descendant of the current node. @@ -3353,7 +3375,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @raise [Capybara::ExpectationNotMet] If the selector does not exist # - # source://capybara//lib/capybara/node/matchers.rb#784 + # source://capybara//lib/capybara/node/matchers.rb#809 def assert_sibling(*args, &optional_filter_block); end # @deprecated Use {#assert_matches_style} instead. @@ -3369,14 +3391,14 @@ module Capybara::Node::Matchers # @raise [Capybara::ExpectationNotMet] if the assertion hasn't succeeded during wait time # @return [true] # - # source://capybara//lib/capybara/node/matchers.rb#675 + # source://capybara//lib/capybara/node/matchers.rb#700 def assert_text(type_or_text, *args, **opts); end # Predicate version of {#assert_ancestor} # # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#761 + # source://capybara//lib/capybara/node/matchers.rb#786 def has_ancestor?(*args, **options, &optional_filter_block); end # Checks if the page or current node has a button with the given @@ -3385,7 +3407,7 @@ module Capybara::Node::Matchers # @param locator [String] The text, value or id of a button to check for # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#358 + # source://capybara//lib/capybara/node/matchers.rb#383 def has_button?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node has a radio button or @@ -3395,7 +3417,7 @@ module Capybara::Node::Matchers # @param locator [String] The label, name or id of a checked field # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#423 + # source://capybara//lib/capybara/node/matchers.rb#448 def has_checked_field?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node has the given text content, @@ -3412,7 +3434,7 @@ module Capybara::Node::Matchers # @overload has_text? # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#713 + # source://capybara//lib/capybara/node/matchers.rb#738 def has_content?(*args, **options); end # Checks if a given CSS selector is on the page or a descendant of the current node. @@ -3439,6 +3461,17 @@ module Capybara::Node::Matchers # source://capybara//lib/capybara/node/matchers.rb#309 def has_css?(path, **options, &optional_filter_block); end + # Checks if the page or current node has a element with the given + # local name. + # + # @option options + # @param locator [String] The local name of a element to check for + # @param options [Hash] a customizable set of options + # @return [Boolean] Whether it exists + # + # source://capybara//lib/capybara/node/matchers.rb#334 + def has_element?(locator = T.unsafe(nil), **options, &optional_filter_block); end + # Checks if the page or current node has a form field with the given # label, name or id. # @@ -3460,7 +3493,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#396 + # source://capybara//lib/capybara/node/matchers.rb#421 def has_field?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node has a link with the given @@ -3471,14 +3504,14 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#334 + # source://capybara//lib/capybara/node/matchers.rb#359 def has_link?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Predicate version of {#assert_no_ancestor} # # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#769 + # source://capybara//lib/capybara/node/matchers.rb#794 def has_no_ancestor?(*args, **options, &optional_filter_block); end # Checks if the page or current node has no button with the given @@ -3487,7 +3520,7 @@ module Capybara::Node::Matchers # @param locator [String] The text, value or id of a button to check for # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#370 + # source://capybara//lib/capybara/node/matchers.rb#395 def has_no_button?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node has no radio button or @@ -3497,7 +3530,7 @@ module Capybara::Node::Matchers # @param locator [String] The label, name or id of a checked field # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#436 + # source://capybara//lib/capybara/node/matchers.rb#461 def has_no_checked_field?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node does not have the given text @@ -3507,7 +3540,7 @@ module Capybara::Node::Matchers # @overload has_no_text? # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#725 + # source://capybara//lib/capybara/node/matchers.rb#750 def has_no_content?(*args, **options); end # Checks if a given CSS selector is not on the page or a descendant of the current node. @@ -3520,6 +3553,16 @@ module Capybara::Node::Matchers # source://capybara//lib/capybara/node/matchers.rb#321 def has_no_css?(path, **options, &optional_filter_block); end + # Checks if the page or current node has no element with the given + # local name. + # + # @param locator [String] The local name of a element to check for + # @param options [Hash] a customizable set of options + # @return [Boolean] Whether it doesn't exist + # + # source://capybara//lib/capybara/node/matchers.rb#346 + def has_no_element?(locator = T.unsafe(nil), **options, &optional_filter_block); end + # Checks if the page or current node has no form field with the given # label, name or id. See {#has_field?}. # @@ -3529,7 +3572,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#410 + # source://capybara//lib/capybara/node/matchers.rb#435 def has_no_field?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node has no link with the given @@ -3539,7 +3582,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#346 + # source://capybara//lib/capybara/node/matchers.rb#371 def has_no_link?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node has no select field with the @@ -3549,7 +3592,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#507 + # source://capybara//lib/capybara/node/matchers.rb#532 def has_no_select?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if a given selector is not on the page or a descendant of the current node. @@ -3567,7 +3610,7 @@ module Capybara::Node::Matchers # # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#812 + # source://capybara//lib/capybara/node/matchers.rb#837 def has_no_sibling?(*args, **options, &optional_filter_block); end # Checks if the page or current node has no table with the given id @@ -3577,7 +3620,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#541 + # source://capybara//lib/capybara/node/matchers.rb#566 def has_no_table?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node does not have the given text @@ -3587,7 +3630,7 @@ module Capybara::Node::Matchers # @overload has_no_text? # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#725 + # source://capybara//lib/capybara/node/matchers.rb#750 def has_no_text?(*args, **options); end # Checks if the page or current node has no radio button or @@ -3597,7 +3640,7 @@ module Capybara::Node::Matchers # @param locator [String] The label, name or id of an unchecked field # @return [Boolean] Whether it doesn't exist # - # source://capybara//lib/capybara/node/matchers.rb#462 + # source://capybara//lib/capybara/node/matchers.rb#487 def has_no_unchecked_field?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if a given XPath expression is not on the page or a descendant of the current node. @@ -3638,7 +3681,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#495 + # source://capybara//lib/capybara/node/matchers.rb#520 def has_select?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if a given selector is on the page or a descendant of the current node. @@ -3680,7 +3723,7 @@ module Capybara::Node::Matchers # # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#804 + # source://capybara//lib/capybara/node/matchers.rb#829 def has_sibling?(*args, **options, &optional_filter_block); end # @deprecated Use {#matches_style?} instead. @@ -3702,7 +3745,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#529 + # source://capybara//lib/capybara/node/matchers.rb#554 def has_table?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if the page or current node has the given text content, @@ -3719,7 +3762,7 @@ module Capybara::Node::Matchers # @overload has_text? # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#713 + # source://capybara//lib/capybara/node/matchers.rb#738 def has_text?(*args, **options); end # Checks if the page or current node has a radio button or @@ -3729,7 +3772,7 @@ module Capybara::Node::Matchers # @param locator [String] The label, name or id of an unchecked field # @return [Boolean] Whether it exists # - # source://capybara//lib/capybara/node/matchers.rb#449 + # source://capybara//lib/capybara/node/matchers.rb#474 def has_unchecked_field?(locator = T.unsafe(nil), **options, &optional_filter_block); end # Checks if a given XPath expression is on the page or a descendant of the current node. @@ -3767,7 +3810,7 @@ module Capybara::Node::Matchers # @param css [String] The CSS selector to match against the current code # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#610 + # source://capybara//lib/capybara/node/matchers.rb#635 def matches_css?(css, **options, &optional_filter_block); end # Checks if the current node matches given selector. @@ -3777,7 +3820,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#588 + # source://capybara//lib/capybara/node/matchers.rb#613 def matches_selector?(*args, **options, &optional_filter_block); end # Checks if a an element has the specified CSS styles. @@ -3795,7 +3838,7 @@ module Capybara::Node::Matchers # @param xpath [String, XPath::Expression] The XPath expression to match against the current code # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#599 + # source://capybara//lib/capybara/node/matchers.rb#624 def matches_xpath?(xpath, **options, &optional_filter_block); end # Checks if the current node does not match given CSS selector. @@ -3803,7 +3846,7 @@ module Capybara::Node::Matchers # @param css [String] The CSS selector to match against the current code # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#644 + # source://capybara//lib/capybara/node/matchers.rb#669 def not_matches_css?(css, **options, &optional_filter_block); end # Checks if the current node does not match given selector. @@ -3814,7 +3857,7 @@ module Capybara::Node::Matchers # @param options [Hash] a customizable set of options # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#622 + # source://capybara//lib/capybara/node/matchers.rb#647 def not_matches_selector?(*args, **options, &optional_filter_block); end # Checks if the current node does not match given XPath expression. @@ -3822,30 +3865,30 @@ module Capybara::Node::Matchers # @param xpath [String, XPath::Expression] The XPath expression to match against the current code # @return [Boolean] # - # source://capybara//lib/capybara/node/matchers.rb#633 + # source://capybara//lib/capybara/node/matchers.rb#658 def not_matches_xpath?(xpath, **options, &optional_filter_block); end private - # source://capybara//lib/capybara/node/matchers.rb#867 + # source://capybara//lib/capybara/node/matchers.rb#892 def _set_query_session_options(*query_args); end - # source://capybara//lib/capybara/node/matchers.rb#849 + # source://capybara//lib/capybara/node/matchers.rb#874 def _verify_match_result(query_args, optional_filter_block); end - # source://capybara//lib/capybara/node/matchers.rb#826 + # source://capybara//lib/capybara/node/matchers.rb#851 def _verify_multiple(*args, wait: T.unsafe(nil), **options); end - # source://capybara//lib/capybara/node/matchers.rb#834 + # source://capybara//lib/capybara/node/matchers.rb#859 def _verify_selector_result(query_args, optional_filter_block, query_type = T.unsafe(nil)); end - # source://capybara//lib/capybara/node/matchers.rb#858 + # source://capybara//lib/capybara/node/matchers.rb#883 def _verify_text(type = T.unsafe(nil), expected_text, **query_options); end - # source://capybara//lib/capybara/node/matchers.rb#822 + # source://capybara//lib/capybara/node/matchers.rb#847 def extract_selector(args); end - # source://capybara//lib/capybara/node/matchers.rb#875 + # source://capybara//lib/capybara/node/matchers.rb#900 def make_predicate(options); end end @@ -4292,12 +4335,12 @@ class Capybara::Queries::SelectorQuery < ::Capybara::Queries::BaseQuery # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#113 + # source://capybara//lib/capybara/queries/selector_query.rb#114 def applied_description; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#154 + # source://capybara//lib/capybara/queries/selector_query.rb#155 def css; end # @api private @@ -4308,7 +4351,7 @@ class Capybara::Queries::SelectorQuery < ::Capybara::Queries::BaseQuery # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#137 + # source://capybara//lib/capybara/queries/selector_query.rb#138 def exact?; end # @api private @@ -4318,7 +4361,7 @@ class Capybara::Queries::SelectorQuery < ::Capybara::Queries::BaseQuery # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#178 + # source://capybara//lib/capybara/queries/selector_query.rb#179 def failure_message; end # @api private @@ -4333,13 +4376,13 @@ class Capybara::Queries::SelectorQuery < ::Capybara::Queries::BaseQuery # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#141 + # source://capybara//lib/capybara/queries/selector_query.rb#142 def match; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#117 + # source://capybara//lib/capybara/queries/selector_query.rb#118 def matches_filters?(node, node_filter_errors = T.unsafe(nil)); end # @api private @@ -4349,7 +4392,7 @@ class Capybara::Queries::SelectorQuery < ::Capybara::Queries::BaseQuery # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#182 + # source://capybara//lib/capybara/queries/selector_query.rb#183 def negative_failure_message; end # @api private @@ -4359,7 +4402,7 @@ class Capybara::Queries::SelectorQuery < ::Capybara::Queries::BaseQuery # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#159 + # source://capybara//lib/capybara/queries/selector_query.rb#160 def resolve_for(node, exact = T.unsafe(nil)); end # @api private @@ -4370,392 +4413,392 @@ class Capybara::Queries::SelectorQuery < ::Capybara::Queries::BaseQuery # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#172 + # source://capybara//lib/capybara/queries/selector_query.rb#173 def supports_exact?; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#129 + # source://capybara//lib/capybara/queries/selector_query.rb#130 def visible; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#145 + # source://capybara//lib/capybara/queries/selector_query.rb#146 def xpath(exact = T.unsafe(nil)); end private # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#230 + # source://capybara//lib/capybara/queries/selector_query.rb#231 def applied_filters; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#390 + # source://capybara//lib/capybara/queries/selector_query.rb#391 def apply_expression_filters(expression); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#433 + # source://capybara//lib/capybara/queries/selector_query.rb#434 def apply_filter?(filter); end # @api private # @raise [ArgumentError] # - # source://capybara//lib/capybara/queries/selector_query.rb#344 + # source://capybara//lib/capybara/queries/selector_query.rb#345 def assert_valid_keys; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#613 + # source://capybara//lib/capybara/queries/selector_query.rb#614 def builder(expr); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#340 + # source://capybara//lib/capybara/queries/selector_query.rb#341 def custom_keys; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#609 + # source://capybara//lib/capybara/queries/selector_query.rb#610 def default_visibility; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#421 + # source://capybara//lib/capybara/queries/selector_query.rb#422 def describe_within?; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#425 + # source://capybara//lib/capybara/queries/selector_query.rb#426 def document?(node); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#417 + # source://capybara//lib/capybara/queries/selector_query.rb#418 def exact_text; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#325 + # source://capybara//lib/capybara/queries/selector_query.rb#326 def expression_filters; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#313 + # source://capybara//lib/capybara/queries/selector_query.rb#314 def filter_set(name); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#362 + # source://capybara//lib/capybara/queries/selector_query.rb#363 def filtered_expression(expr); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#241 + # source://capybara//lib/capybara/queries/selector_query.rb#242 def find_nodes_by_selector_format(node, exact); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#234 + # source://capybara//lib/capybara/queries/selector_query.rb#235 def find_selector(locator); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#220 + # source://capybara//lib/capybara/queries/selector_query.rb#221 def first_try?; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#497 + # source://capybara//lib/capybara/queries/selector_query.rb#498 def matches_class_filter?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#556 + # source://capybara//lib/capybara/queries/selector_query.rb#557 def matches_exact_text_filter?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#303 + # source://capybara//lib/capybara/queries/selector_query.rb#304 def matches_filter_block?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#510 + # source://capybara//lib/capybara/queries/selector_query.rb#511 def matches_focused_filter?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#491 + # source://capybara//lib/capybara/queries/selector_query.rb#492 def matches_id_filter?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#437 + # source://capybara//lib/capybara/queries/selector_query.rb#438 def matches_locator_filter?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#278 + # source://capybara//lib/capybara/queries/selector_query.rb#279 def matches_node_filters?(node, errors); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#455 + # source://capybara//lib/capybara/queries/selector_query.rb#456 def matches_spatial_filters?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#536 + # source://capybara//lib/capybara/queries/selector_query.rb#537 def matches_style?(node, styles); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#525 + # source://capybara//lib/capybara/queries/selector_query.rb#526 def matches_style_filter?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#443 + # source://capybara//lib/capybara/queries/selector_query.rb#444 def matches_system_filters?(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#590 + # source://capybara//lib/capybara/queries/selector_query.rb#591 def matches_text_exactly?(node, value); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#547 + # source://capybara//lib/capybara/queries/selector_query.rb#548 def matches_text_filter?(node); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#599 + # source://capybara//lib/capybara/queries/selector_query.rb#600 def matches_text_regexp(node, regexp); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#605 + # source://capybara//lib/capybara/queries/selector_query.rb#606 def matches_text_regexp?(node, regexp); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#565 + # source://capybara//lib/capybara/queries/selector_query.rb#566 def matches_visibility_filters?(node); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#192 + # source://capybara//lib/capybara/queries/selector_query.rb#193 def matching_text; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#516 + # source://capybara//lib/capybara/queries/selector_query.rb#517 def need_to_process_classes?; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#317 + # source://capybara//lib/capybara/queries/selector_query.rb#318 def node_filters; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#595 + # source://capybara//lib/capybara/queries/selector_query.rb#596 def normalize_ws; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#331 + # source://capybara//lib/capybara/queries/selector_query.rb#332 def ordered_results(results); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#617 + # source://capybara//lib/capybara/queries/selector_query.rb#618 def position_cache(key); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#621 + # source://capybara//lib/capybara/queries/selector_query.rb#622 def rect_cache(key); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#188 + # source://capybara//lib/capybara/queries/selector_query.rb#189 def selector_format; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#224 + # source://capybara//lib/capybara/queries/selector_query.rb#225 def show_for_stage(only_applied); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#429 + # source://capybara//lib/capybara/queries/selector_query.rb#430 def simple_root?(node); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#196 + # source://capybara//lib/capybara/queries/selector_query.rb#197 def text_fragments; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#266 + # source://capybara//lib/capybara/queries/selector_query.rb#267 def to_element(node); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#213 + # source://capybara//lib/capybara/queries/selector_query.rb#214 def try_text_match_in_expression?; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#374 + # source://capybara//lib/capybara/queries/selector_query.rb#375 def use_default_class_filter?; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#382 + # source://capybara//lib/capybara/queries/selector_query.rb#383 def use_default_focused_filter?; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#370 + # source://capybara//lib/capybara/queries/selector_query.rb#371 def use_default_id_filter?; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#378 + # source://capybara//lib/capybara/queries/selector_query.rb#379 def use_default_style_filter?; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#386 + # source://capybara//lib/capybara/queries/selector_query.rb#387 def use_spatial_filter?; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#274 + # source://capybara//lib/capybara/queries/selector_query.rb#275 def valid_keys; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#411 + # source://capybara//lib/capybara/queries/selector_query.rb#412 def warn_exact_usage; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#200 + # source://capybara//lib/capybara/queries/selector_query.rb#201 def xpath_text_conditions; end end # @api private # -# source://capybara//lib/capybara/queries/selector_query.rb#625 +# source://capybara//lib/capybara/queries/selector_query.rb#626 class Capybara::Queries::SelectorQuery::Rectangle # @api private # @return [Rectangle] a new instance of Rectangle # - # source://capybara//lib/capybara/queries/selector_query.rb#628 + # source://capybara//lib/capybara/queries/selector_query.rb#629 def initialize(position); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#652 + # source://capybara//lib/capybara/queries/selector_query.rb#653 def above?(other); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#656 + # source://capybara//lib/capybara/queries/selector_query.rb#657 def below?(other); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#626 + # source://capybara//lib/capybara/queries/selector_query.rb#627 def bottom; end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#637 + # source://capybara//lib/capybara/queries/selector_query.rb#638 def distance(other); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#626 + # source://capybara//lib/capybara/queries/selector_query.rb#627 def left; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#660 + # source://capybara//lib/capybara/queries/selector_query.rb#661 def left_of?(other); end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#668 + # source://capybara//lib/capybara/queries/selector_query.rb#669 def near?(other); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#626 + # source://capybara//lib/capybara/queries/selector_query.rb#627 def right; end # @api private # @return [Boolean] # - # source://capybara//lib/capybara/queries/selector_query.rb#664 + # source://capybara//lib/capybara/queries/selector_query.rb#665 def right_of?(other); end # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#626 + # source://capybara//lib/capybara/queries/selector_query.rb#627 def top; end protected # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#674 + # source://capybara//lib/capybara/queries/selector_query.rb#675 def line_segments; end private # @api private # - # source://capybara//lib/capybara/queries/selector_query.rb#685 + # source://capybara//lib/capybara/queries/selector_query.rb#686 def distance_segment_segment(l1p1, l1p2, l2p1, l2p2); end end @@ -4949,7 +4992,7 @@ class Capybara::Queries::TitleQuery < ::Capybara::Queries::BaseQuery def valid_keys; end end -# source://capybara//lib/capybara.rb#447 +# source://capybara//lib/capybara.rb#448 module Capybara::RackTest; end # source://capybara//lib/capybara/rack_test/browser.rb#3 @@ -4964,7 +5007,7 @@ class Capybara::RackTest::Browser # source://capybara//lib/capybara/rack_test/browser.rb#14 def app; end - # source://capybara//lib/capybara/rack_test/browser.rb#83 + # source://capybara//lib/capybara/rack_test/browser.rb#84 def build_uri(path); end # Returns the value of attribute current_host. @@ -4979,10 +5022,10 @@ class Capybara::RackTest::Browser # source://capybara//lib/capybara/rack_test/browser.rb#7 def current_host=(_arg0); end - # source://capybara//lib/capybara/rack_test/browser.rb#99 + # source://capybara//lib/capybara/rack_test/browser.rb#100 def current_url; end - # source://capybara//lib/capybara/rack_test/browser.rb#116 + # source://capybara//lib/capybara/rack_test/browser.rb#117 def dom; end # Returns the value of attribute driver. @@ -4990,47 +5033,47 @@ class Capybara::RackTest::Browser # source://capybara//lib/capybara/rack_test/browser.rb#6 def driver; end - # source://capybara//lib/capybara/rack_test/browser.rb#120 + # source://capybara//lib/capybara/rack_test/browser.rb#121 def find(format, selector); end - # source://capybara//lib/capybara/rack_test/browser.rb#47 + # source://capybara//lib/capybara/rack_test/browser.rb#48 def follow(method, path, **attributes); end - # source://capybara//lib/capybara/rack_test/browser.rb#128 + # source://capybara//lib/capybara/rack_test/browser.rb#129 def html; end # @raise [Rack::Test::Error] # - # source://capybara//lib/capybara/rack_test/browser.rb#138 + # source://capybara//lib/capybara/rack_test/browser.rb#139 def last_request; end # @raise [Rack::Test::Error] # - # source://capybara//lib/capybara/rack_test/browser.rb#144 + # source://capybara//lib/capybara/rack_test/browser.rb#145 def last_response; end # source://capybara//lib/capybara/rack_test/browser.rb#18 def options; end - # source://capybara//lib/capybara/rack_test/browser.rb#73 + # source://capybara//lib/capybara/rack_test/browser.rb#74 def process(method, path, attributes = T.unsafe(nil), env = T.unsafe(nil)); end - # source://capybara//lib/capybara/rack_test/browser.rb#53 + # source://capybara//lib/capybara/rack_test/browser.rb#54 def process_and_follow_redirects(method, path, attributes = T.unsafe(nil), env = T.unsafe(nil)); end # source://capybara//lib/capybara/rack_test/browser.rb#29 def refresh; end - # source://capybara//lib/capybara/rack_test/browser.rb#112 + # source://capybara//lib/capybara/rack_test/browser.rb#113 def reset_cache!; end - # source://capybara//lib/capybara/rack_test/browser.rb#107 + # source://capybara//lib/capybara/rack_test/browser.rb#108 def reset_host!; end # source://capybara//lib/capybara/rack_test/browser.rb#34 def submit(method, path, attributes, content_type: T.unsafe(nil)); end - # source://capybara//lib/capybara/rack_test/browser.rb#134 + # source://capybara//lib/capybara/rack_test/browser.rb#135 def title; end # source://capybara//lib/capybara/rack_test/browser.rb#22 @@ -5038,29 +5081,29 @@ class Capybara::RackTest::Browser protected - # source://capybara//lib/capybara/rack_test/browser.rb#152 + # source://capybara//lib/capybara/rack_test/browser.rb#153 def base_href; end - # source://capybara//lib/capybara/rack_test/browser.rb#156 + # source://capybara//lib/capybara/rack_test/browser.rb#157 def base_relative_uri_for(uri); end - # source://capybara//lib/capybara/rack_test/browser.rb#171 + # source://capybara//lib/capybara/rack_test/browser.rb#172 def build_rack_mock_session; end - # source://capybara//lib/capybara/rack_test/browser.rb#176 + # source://capybara//lib/capybara/rack_test/browser.rb#177 def request_path; end - # source://capybara//lib/capybara/rack_test/browser.rb#182 + # source://capybara//lib/capybara/rack_test/browser.rb#183 def safe_last_request; end private # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/browser.rb#190 + # source://capybara//lib/capybara/rack_test/browser.rb#191 def fragment_or_script?(path); end - # source://capybara//lib/capybara/rack_test/browser.rb#194 + # source://capybara//lib/capybara/rack_test/browser.rb#195 def referer_url; end end @@ -5263,181 +5306,181 @@ end class Capybara::RackTest::Node < ::Capybara::Driver::Node include ::Capybara::Node::WhitespaceNormalizer - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def [](*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def all_text(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def checked?(*_arg0, **_arg1, &_arg2); end # @raise [ArgumentError] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def click(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def disabled?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def find_css(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def find_xpath(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def path(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def readonly?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def select_option(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def selected?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def set(*_arg0, **_arg1, &_arg2); end # @raise [NotImplementedError] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def style(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def tag_name(*_arg0, **_arg1, &_arg2); end # @raise [Capybara::UnselectNotAllowed] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def unselect_option(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def value(*_arg0, **_arg1, &_arg2); end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def visible?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/rack_test/node.rb#130 + # source://capybara//lib/capybara/rack_test/node.rb#129 def visible_text(*_arg0, **_arg1, &_arg2); end protected # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#294 + # source://capybara//lib/capybara/rack_test/node.rb#287 def checkbox?; end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#290 + # source://capybara//lib/capybara/rack_test/node.rb#283 def checkbox_or_radio?(field = T.unsafe(nil)); end # @api private # - # source://capybara//lib/capybara/rack_test/node.rb#146 + # source://capybara//lib/capybara/rack_test/node.rb#139 def displayed_text(check_ancestor: T.unsafe(nil)); end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#306 + # source://capybara//lib/capybara/rack_test/node.rb#299 def input_field?; end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#298 + # source://capybara//lib/capybara/rack_test/node.rb#291 def radio?; end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#314 + # source://capybara//lib/capybara/rack_test/node.rb#307 def range?; end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#302 + # source://capybara//lib/capybara/rack_test/node.rb#295 def text_or_password?; end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#310 + # source://capybara//lib/capybara/rack_test/node.rb#303 def textarea?; end private # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#245 + # source://capybara//lib/capybara/rack_test/node.rb#238 def attribute_is_not_blank?(attribute); end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#284 + # source://capybara//lib/capybara/rack_test/node.rb#277 def checkable?; end - # source://capybara//lib/capybara/rack_test/node.rb#255 + # source://capybara//lib/capybara/rack_test/node.rb#248 def click_label; end - # source://capybara//lib/capybara/rack_test/node.rb#172 + # source://capybara//lib/capybara/rack_test/node.rb#165 def deselect_options; end - # source://capybara//lib/capybara/rack_test/node.rb#249 + # source://capybara//lib/capybara/rack_test/node.rb#242 def follow_link; end - # source://capybara//lib/capybara/rack_test/node.rb#189 + # source://capybara//lib/capybara/rack_test/node.rb#182 def form; end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#276 + # source://capybara//lib/capybara/rack_test/node.rb#269 def link?; end # a reference to the select node if this is an option node # - # source://capybara//lib/capybara/rack_test/node.rb#181 + # source://capybara//lib/capybara/rack_test/node.rb#174 def select_node; end - # source://capybara//lib/capybara/rack_test/node.rb#203 + # source://capybara//lib/capybara/rack_test/node.rb#196 def set_checkbox(value); end - # source://capybara//lib/capybara/rack_test/node.rb#219 + # source://capybara//lib/capybara/rack_test/node.rb#212 def set_input(value); end - # source://capybara//lib/capybara/rack_test/node.rb#197 + # source://capybara//lib/capybara/rack_test/node.rb#190 def set_radio(_value); end - # source://capybara//lib/capybara/rack_test/node.rb#211 + # source://capybara//lib/capybara/rack_test/node.rb#204 def set_range(value); end # @raise [Capybara::RackTest::Errors::StaleElementReferenceError] # - # source://capybara//lib/capybara/rack_test/node.rb#168 + # source://capybara//lib/capybara/rack_test/node.rb#161 def stale_check; end - # source://capybara//lib/capybara/rack_test/node.rb#176 + # source://capybara//lib/capybara/rack_test/node.rb#169 def string_node; end # @return [Boolean] # - # source://capybara//lib/capybara/rack_test/node.rb#280 + # source://capybara//lib/capybara/rack_test/node.rb#273 def submits?; end - # source://capybara//lib/capybara/rack_test/node.rb#265 + # source://capybara//lib/capybara/rack_test/node.rb#258 def toggle_details(details = T.unsafe(nil)); end - # source://capybara//lib/capybara/rack_test/node.rb#185 + # source://capybara//lib/capybara/rack_test/node.rb#178 def type; end # source://capybara//lib/capybara/rack_test/node.rb#11 @@ -5495,10 +5538,10 @@ end # source://capybara//lib/capybara/rack_test/node.rb#9 Capybara::RackTest::Node::BLOCK_ELEMENTS = T.let(T.unsafe(nil), Array) -# source://capybara//lib/capybara/rack_test/node.rb#319 +# source://capybara//lib/capybara/rack_test/node.rb#312 Capybara::RackTest::Node::DISABLED_BY_FIELDSET_XPATH = T.let(T.unsafe(nil), String) -# source://capybara//lib/capybara/rack_test/node.rb#318 +# source://capybara//lib/capybara/rack_test/node.rb#311 Capybara::RackTest::Node::OPTION_OWNER_XPATH = T.let(T.unsafe(nil), String) # source://capybara//lib/capybara.rb#24 @@ -5614,7 +5657,7 @@ class Capybara::RegistrationContainer # @api private # # source://capybara//lib/capybara/registration_container.rb#19 - def method_missing(method_name, *args, **options, &block); end + def method_missing(method_name, *_arg1, **_arg2, &_arg3); end # @api private # @@ -5712,6 +5755,9 @@ class Capybara::Result # source://forwardable/1.3.3/forwardable.rb#231 def size(*args, **_arg1, &block); end + # source://forwardable/1.3.3/forwardable.rb#231 + def to_ary(*args, **_arg1, &block); end + # source://capybara//lib/capybara/result.rb#133 def unfiltered_size; end @@ -5762,12 +5808,30 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * **:xpath** - Select elements by XPath expression # * Locator: An XPath expression # +# ```ruby +# page.html # => '' +# +# page.find :xpath, './/input' +# ``` +# # * **:css** - Select elements by CSS selector # * Locator: A CSS selector # +# ```ruby +# page.html # => '' +# +# page.find :css, 'input' +# ``` +# # * **:id** - Select element by id # * Locator: (String, Regexp, XPath::Expression) The id of the element to match # +# ```ruby +# page.html # => '' +# +# page.find :id, 'content' +# ``` +# # * **:field** - Select field elements (input [not of type submit, image, or hidden], textarea, select) # * Locator: Matches against the id, {Capybara.configure test_id} attribute, name, placeholder, or # associated label text @@ -5784,12 +5848,30 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :valid (Boolean) - Match fields that are valid/invalid according to HTML5 form validation # * :validation_message (String, Regexp) - Matches the elements current validationMessage # +# ```ruby +# page.html # => ' +# ' +# +# page.find :field, 'article_title' +# page.find :field, 'article[title]' +# page.find :field, 'Title' +# page.find :field, 'Title', type: 'text', with: 'Hello world' +# ``` +# # * **:fieldset** - Select fieldset elements # * Locator: Matches id, {Capybara.configure test_id}, or contents of wrapped legend # * Filters: # * :legend (String) - Matches contents of wrapped legend # * :disabled (Boolean) - Match disabled fieldset? # +# ```ruby +# page.html # => '
+# Fields (disabled) +#
' +# +# page.find :fieldset, 'Fields (disabled)', disabled: true +# ``` +# # * **:link** - Find links (`` elements with an href attribute) # * Locator: Matches the id, {Capybara.configure test_id}, or title attributes, or the string content of the link, # or the alt attribute of a contained img element. By default this selector requires a link to have an href attribute. @@ -5798,6 +5880,17 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :alt (String) - Matches the alt attribute of a contained img element # * :href (String, Regexp, nil, false) - Matches the normalized href of the link, if nil will find `` elements with no href attribute, if false ignores href presence # +# ```ruby +# page.html # => 'Home' +# +# page.find :link, 'Home', href: '/' +# +# page.html # => 'The logo' +# +# page.find :link, 'The logo', href: '/' +# page.find :link, alt: 'The logo', href: '/' +# ``` +# # * **:button** - Find buttons ( input [of type submit, reset, image, button] or button elements ) # * Locator: Matches the id, {Capybara.configure test_id} attribute, name, value, or title attributes, string content of a button, or the alt attribute of an image type button or of a descendant image of a button # * Filters: @@ -5807,11 +5900,31 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :type (String) - Matches the type attribute # * :disabled (Boolean, :all) - Match disabled buttons (Default: false) # +# ```ruby +# page.html # => '' +# +# page.find :button, 'Submit' +# +# page.html # => '' +# +# page.find :button, 'Save as draft', name: 'article[state]', value: 'draft' +# ``` +# # * **:link_or_button** - Find links or buttons # * Locator: See :link and :button selectors # * Filters: # * :disabled (Boolean, :all) - Match disabled buttons? (Default: false) # +# ```ruby +# page.html # => 'Home' +# +# page.find :link_or_button, 'Home' +# +# page.html # => '' +# +# page.find :link_or_button, 'Submit' +# ``` +# # * **:fillable_field** - Find text fillable fields ( textarea, input [not of type submit, image, radio, checkbox, hidden, file] ) # * Locator: Matches against the id, {Capybara.configure test_id} attribute, name, placeholder, or associated label text # * Filters: @@ -5824,6 +5937,16 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :valid (Boolean) - Match fields that are valid/invalid according to HTML5 form validation # * :validation_message (String, Regexp) - Matches the elements current validationMessage # +# ```ruby +# page.html # => ' +# ' +# +# page.find :fillable_field, 'article_body' +# page.find :fillable_field, 'article[body]' +# page.find :fillable_field, 'Body' +# page.find :field, 'Body', type: 'textarea' +# ``` +# # * **:radio_button** - Find radio buttons # * Locator: Match id, {Capybara.configure test_id} attribute, name, or associated label text # * Filters: @@ -5834,6 +5957,18 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :option (String, Regexp) - Match the current value # * :with - Alias of :option # +# ```ruby +# page.html # => ' +# +# +# ' +# +# page.find :radio_button, 'article_state_published' +# page.find :radio_button, 'article[state]', option: 'published' +# page.find :radio_button, 'Published', checked: true +# page.find :radio_button, 'Draft', unchecked: true +# ``` +# # * **:checkbox** - Find checkboxes # * Locator: Match id, {Capybara.configure test_id} attribute, name, or associated label text # * Filters: @@ -5844,6 +5979,15 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :with (String, Regexp) - Match the current value # * :option - Alias of :with # +# ```ruby +# page.html # => ' +# ' +# +# page.find :checkbox, 'registration_terms' +# page.find :checkbox, 'registration[terms]' +# page.find :checkbox, 'I agree to terms and conditions', unchecked: true +# ``` +# # * **:select** - Find select elements # * Locator: Match id, {Capybara.configure test_id} attribute, name, placeholder, or associated label text # * Filters: @@ -5858,12 +6002,40 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :selected (String, Array) - Match the selection(s) # * :with_selected (String, Array) - Partial match the selection(s) # +# ```ruby +# page.html # => ' +# ' +# +# page.find :select, 'article_category' +# page.find :select, 'article[category]' +# page.find :select, 'Category' +# page.find :select, 'Category', selected: 'General' +# page.find :select, with_options: ['General'] +# page.find :select, with_options: ['Other'] +# page.find :select, options: ['General', 'Other'] +# page.find :select, options: ['General'] # => raises Capybara::ElementNotFound +# ``` +# # * **:option** - Find option elements # * Locator: Match text of option # * Filters: # * :disabled (Boolean) - Match disabled option # * :selected (Boolean) - Match selected option # +# ```ruby +# page.html # => ' +# +# ' +# +# page.find :option, 'General' +# page.find :option, 'General', selected: true +# page.find :option, 'Disabled', disabled: true +# page.find :option, 'Other', selected: false +# ``` +# # * **:datalist_input** - Find input field with datalist completion # * Locator: Matches against the id, {Capybara.configure test_id} attribute, name, # placeholder, or associated label text @@ -5874,11 +6046,42 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :options (Array) - Exact match options # * :with_options (Array) - Partial match options # +# ```ruby +# page.html # => ' +# +# +# +# +# +# ' +# +# page.find :datalist_input, 'ice_cream_flavor' +# page.find :datalist_input, 'ice_cream[flavor]' +# page.find :datalist_input, 'Flavor' +# page.find :datalist_input, with_options: ['Chocolate', 'Strawberry'] +# page.find :datalist_input, options: ['Chocolate', 'Strawberry', 'Vanilla'] +# page.find :datalist_input, options: ['Chocolate'] # => raises Capybara::ElementNotFound +# ``` +# # * **:datalist_option** - Find datalist option # * Locator: Match text or value of option # * Filters: # * :disabled (Boolean) - Match disabled option # +# ```ruby +# page.html # => ' +# +# +# +# +# ' +# +# page.find :datalist_option, 'Chocolate' +# page.find :datalist_option, 'Strawberry' +# page.find :datalist_option, 'Vanilla' +# page.find :datalist_option, 'Forbidden', disabled: true +# ``` +# # * **:file_field** - Find file input elements # * Locator: Match id, {Capybara.configure test_id} attribute, name, or associated label text # * Filters: @@ -5886,11 +6089,31 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :disabled (Boolean, :all) - Match disabled field? (Default: false) # * :multiple (Boolean) - Match field that accepts multiple values # +# ```ruby +# page.html # => ' +# ' +# +# page.find :file_field, 'article_banner_image' +# page.find :file_field, 'article[banner_image]' +# page.find :file_field, 'Banner Image' +# page.find :file_field, 'Banner Image', name: 'article[banner_image]' +# page.find :field, 'Banner Image', type: 'file' +# ``` +# # * **:label** - Find label elements # * Locator: Match id, {Capybara.configure test_id}, or text contents # * Filters: # * :for (Element, String, Regexp) - The element or id of the element associated with the label # +# ```ruby +# page.html # => ' +# ' +# +# page.find :label, 'Title' +# page.find :label, 'Title', for: 'article_title' +# page.find :label, 'Title', for: page.find('article[title]') +# ``` +# # * **:table** - Find table elements # * Locator: id, {Capybara.configure test_id}, or caption text of table # * Filters: @@ -5900,19 +6123,93 @@ class Capybara::ScopeError < ::Capybara::CapybaraError; end # * :with_cols (Array>, Array>) - Partial match `` data - visibility of `` elements is not considered # * :cols (Array>) - Match all ``s - visibility of `` elements is not considered # +# ```ruby +# page.html # => ' +# +# +# +# +# +# +# +# +# +# +# +# +# +#
A table
AB
12
34
' +# +# page.find :table, 'A table' +# page.find :table, with_rows: [ +# { 'A' => '1', 'B' => '2' }, +# { 'A' => '3', 'B' => '4' }, +# ] +# page.find :table, with_rows: [ +# ['1', '2'], +# ['3', '4'], +# ] +# page.find :table, rows: [ +# { 'A' => '1', 'B' => '2' }, +# { 'A' => '3', 'B' => '4' }, +# ] +# page.find :table, rows: [ +# ['1', '2'], +# ['3', '4'], +# ] +# page.find :table, rows: [ ['1', '2'] ] # => raises Capybara::ElementNotFound +# ``` +# # * **:table_row** - Find table row # * Locator: Array, Hash table row `` contents - visibility of `` elements is not considered # +# ```ruby +# page.html # => ' +# +# +# +# +# +# +# +# +# +# +# +# +#
AB
12
34
' +# +# page.find :table_row, 'A' => '1', 'B' => '2' +# page.find :table_row, 'A' => '3', 'B' => '4' +# ``` +# # * **:frame** - Find frame/iframe elements # * Locator: Match id, {Capybara.configure test_id} attribute, or name # * Filters: # * :name (String) - Match name attribute # +# ```ruby +# page.html # => '' +# +# page.find :frame, 'embed_frame' +# page.find :frame, 'embed' +# page.find :frame, name: 'embed' +# ``` +# # * **:element** # * Locator: Type of element ('div', 'a', etc) - if not specified defaults to '*' # * Filters: # * :\ (String, Regexp) - Match on any specified element attribute # +# ```ruby +# page.html # => ' +# +# page.find :element, 'button' +# page.find :element, type: 'button', text: 'Check me' +# page.find :element, role: 'menuitemcheckbox' +# page.find :element, role: /checkbox/, 'aria-checked': 'true' +# ``` +# # source://capybara//lib/capybara/selector/selector.rb#4 class Capybara::Selector < ::SimpleDelegator # @return [Selector] a new instance of Selector @@ -6659,7 +6956,7 @@ class Capybara::Selector::XPathBuilder def regexp_to_xpath_conditions(regexp); end end -# source://capybara//lib/capybara.rb#448 +# source://capybara//lib/capybara.rb#449 module Capybara::Selenium; end # source://capybara//lib/capybara/selenium/patches/logs.rb#5 @@ -6685,21 +6982,21 @@ class Capybara::Selenium::ChromeNode < ::Capybara::Selenium::Node include ::Capybara::Selenium::Node::Html5Drag include ::Capybara::Selenium::Node::FileInputClickEmulation - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#39 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#33 def click(*_arg0, **_arg1); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#52 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#46 def disabled?; end - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#35 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#29 def drop(*args); end - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#56 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#50 def select_option; end - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#76 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#70 def send_keys(*args); end # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#17 @@ -6710,38 +7007,35 @@ class Capybara::Selenium::ChromeNode < ::Capybara::Selenium::Node # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#64 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#58 def visible?; end private - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#117 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#101 def browser_version(to_float: T.unsafe(nil)); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#124 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#108 def chromedriver_fixed_actions_key_state?; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#128 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#112 def chromedriver_supports_displayed_endpoint?; end - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#132 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#116 def chromedriver_version; end - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#107 - def file_errors; end - # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#136 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#120 def native_displayed?; end # @raise [ArgumentError] # - # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#96 + # source://capybara//lib/capybara/selenium/nodes/chrome_node.rb#90 def perform_legacy_drag(element, drop_modifiers); end end @@ -6751,13 +7045,13 @@ class Capybara::Selenium::Driver < ::Capybara::Driver::Base # @return [Driver] a new instance of Driver # - # source://capybara//lib/capybara/selenium/driver.rb#92 + # source://capybara//lib/capybara/selenium/driver.rb#83 def initialize(app, **options); end - # source://capybara//lib/capybara/selenium/driver.rb#273 + # source://capybara//lib/capybara/selenium/driver.rb#264 def accept_modal(_type, **options); end - # source://capybara//lib/capybara/selenium/driver.rb#151 + # source://capybara//lib/capybara/selenium/driver.rb#142 def active_element; end # Returns the value of attribute app. @@ -6765,64 +7059,64 @@ class Capybara::Selenium::Driver < ::Capybara::Driver::Base # source://capybara//lib/capybara/selenium/driver.rb#17 def app; end - # source://capybara//lib/capybara/selenium/driver.rb#65 + # source://capybara//lib/capybara/selenium/driver.rb#63 def browser; end # @raise [ArgumentError] # - # source://capybara//lib/capybara/selenium/driver.rb#244 + # source://capybara//lib/capybara/selenium/driver.rb#235 def close_window(handle); end - # source://capybara//lib/capybara/selenium/driver.rb#129 + # source://capybara//lib/capybara/selenium/driver.rb#120 def current_url; end - # source://capybara//lib/capybara/selenium/driver.rb#214 + # source://capybara//lib/capybara/selenium/driver.rb#205 def current_window_handle; end - # source://capybara//lib/capybara/selenium/driver.rb#284 + # source://capybara//lib/capybara/selenium/driver.rb#275 def dismiss_modal(_type, **options); end - # source://capybara//lib/capybara/selenium/driver.rb#145 + # source://capybara//lib/capybara/selenium/driver.rb#136 def evaluate_async_script(script, *args); end - # source://capybara//lib/capybara/selenium/driver.rb#140 + # source://capybara//lib/capybara/selenium/driver.rb#131 def evaluate_script(script, *args); end - # source://capybara//lib/capybara/selenium/driver.rb#136 + # source://capybara//lib/capybara/selenium/driver.rb#127 def execute_script(script, *args); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/driver.rb#187 + # source://capybara//lib/capybara/selenium/driver.rb#178 def frame_obscured_at?(x:, y:); end - # source://capybara//lib/capybara/selenium/driver.rb#238 + # source://capybara//lib/capybara/selenium/driver.rb#229 def fullscreen_window(handle); end - # source://capybara//lib/capybara/selenium/driver.rb#111 + # source://capybara//lib/capybara/selenium/driver.rb#102 def go_back; end - # source://capybara//lib/capybara/selenium/driver.rb#115 + # source://capybara//lib/capybara/selenium/driver.rb#106 def go_forward; end - # source://capybara//lib/capybara/selenium/driver.rb#119 + # source://capybara//lib/capybara/selenium/driver.rb#110 def html; end - # source://capybara//lib/capybara/selenium/driver.rb#306 + # source://capybara//lib/capybara/selenium/driver.rb#297 def invalid_element_errors; end - # source://capybara//lib/capybara/selenium/driver.rb#231 + # source://capybara//lib/capybara/selenium/driver.rb#222 def maximize_window(handle); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/driver.rb#134 + # source://capybara//lib/capybara/selenium/driver.rb#125 def needs_server?; end - # source://capybara//lib/capybara/selenium/driver.rb#332 + # source://capybara//lib/capybara/selenium/driver.rb#313 def no_such_window_error; end - # source://capybara//lib/capybara/selenium/driver.rb#256 + # source://capybara//lib/capybara/selenium/driver.rb#247 def open_new_window(kind = T.unsafe(nil)); end # Returns the value of attribute options. @@ -6830,139 +7124,131 @@ class Capybara::Selenium::Driver < ::Capybara::Driver::Base # source://capybara//lib/capybara/selenium/driver.rb#17 def options; end - # source://capybara//lib/capybara/selenium/driver.rb#292 + # source://capybara//lib/capybara/selenium/driver.rb#283 def quit; end - # source://capybara//lib/capybara/selenium/driver.rb#107 + # source://capybara//lib/capybara/selenium/driver.rb#98 def refresh; end - # source://capybara//lib/capybara/selenium/driver.rb#164 + # source://capybara//lib/capybara/selenium/driver.rb#155 def reset!; end - # source://capybara//lib/capybara/selenium/driver.rb#225 + # source://capybara//lib/capybara/selenium/driver.rb#216 def resize_window_to(handle, width, height); end - # source://capybara//lib/capybara/selenium/driver.rb#160 - def save_screenshot(path, **_options); end + # source://capybara//lib/capybara/selenium/driver.rb#151 + def save_screenshot(path, **options); end - # source://capybara//lib/capybara/selenium/driver.rb#155 + # source://capybara//lib/capybara/selenium/driver.rb#146 def send_keys(*args); end - # source://capybara//lib/capybara/selenium/driver.rb#199 + # source://capybara//lib/capybara/selenium/driver.rb#190 def switch_to_frame(frame); end - # source://capybara//lib/capybara/selenium/driver.rb#269 + # source://capybara//lib/capybara/selenium/driver.rb#260 def switch_to_window(handle); end - # source://capybara//lib/capybara/selenium/driver.rb#125 + # source://capybara//lib/capybara/selenium/driver.rb#116 def title; end - # source://capybara//lib/capybara/selenium/driver.rb#103 + # source://capybara//lib/capybara/selenium/driver.rb#94 def visit(path); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/driver.rb#133 + # source://capybara//lib/capybara/selenium/driver.rb#124 def wait?; end - # source://capybara//lib/capybara/selenium/driver.rb#252 + # source://capybara//lib/capybara/selenium/driver.rb#243 def window_handles; end - # source://capybara//lib/capybara/selenium/driver.rb#218 + # source://capybara//lib/capybara/selenium/driver.rb#209 def window_size(handle); end private - # source://capybara//lib/capybara/selenium/driver.rb#542 + # source://capybara//lib/capybara/selenium/driver.rb#502 def accept_unhandled_reset_alert; end - # source://capybara//lib/capybara/selenium/driver.rb#503 + # source://capybara//lib/capybara/selenium/driver.rb#463 def bridge; end - # source://capybara//lib/capybara/selenium/driver.rb#499 + # source://capybara//lib/capybara/selenium/driver.rb#459 def build_node(native_node, initial_cache = T.unsafe(nil)); end - # source://capybara//lib/capybara/selenium/driver.rb#350 + # source://capybara//lib/capybara/selenium/driver.rb#327 def clear_browser_state; end - # source://capybara//lib/capybara/selenium/driver.rb#359 + # source://capybara//lib/capybara/selenium/driver.rb#336 def clear_browser_state_errors; end - # source://capybara//lib/capybara/selenium/driver.rb#395 + # source://capybara//lib/capybara/selenium/driver.rb#369 def clear_local_storage; end - # source://capybara//lib/capybara/selenium/driver.rb#381 + # source://capybara//lib/capybara/selenium/driver.rb#355 def clear_session_storage; end - # source://capybara//lib/capybara/selenium/driver.rb#374 + # source://capybara//lib/capybara/selenium/driver.rb#348 def clear_storage; end - # source://capybara//lib/capybara/selenium/driver.rb#370 + # source://capybara//lib/capybara/selenium/driver.rb#344 def delete_all_cookies; end - # source://capybara//lib/capybara/selenium/driver.rb#495 + # source://capybara//lib/capybara/selenium/driver.rb#455 def find_context; end - # source://capybara//lib/capybara/selenium/driver.rb#433 + # source://capybara//lib/capybara/selenium/driver.rb#407 def find_modal(text: T.unsafe(nil), **options); end - # source://capybara//lib/capybara/selenium/driver.rb#456 + # source://capybara//lib/capybara/selenium/driver.rb#430 def find_modal_errors; end - # source://capybara//lib/capybara/selenium/driver.rb#417 + # source://capybara//lib/capybara/selenium/driver.rb#391 def modal_error; end - # source://capybara//lib/capybara/selenium/driver.rb#346 + # source://capybara//lib/capybara/selenium/driver.rb#323 def native_active_element; end - # source://capybara//lib/capybara/selenium/driver.rb#342 + # source://capybara//lib/capybara/selenium/driver.rb#319 def native_args(args); end - # source://capybara//lib/capybara/selenium/driver.rb#409 + # source://capybara//lib/capybara/selenium/driver.rb#383 def navigate_with_accept(url); end - # source://capybara//lib/capybara/selenium/driver.rb#524 + # source://capybara//lib/capybara/selenium/driver.rb#484 def reset_browser_state; end - # @return [Boolean] - # - # source://capybara//lib/capybara/selenium/driver.rb#338 - def selenium_4?; end - - # source://capybara//lib/capybara/selenium/driver.rb#514 + # source://capybara//lib/capybara/selenium/driver.rb#474 def setup_exit_handler; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/driver.rb#470 + # source://capybara//lib/capybara/selenium/driver.rb#434 def silenced_unknown_error_message?(msg); end - # source://capybara//lib/capybara/selenium/driver.rb#474 + # source://capybara//lib/capybara/selenium/driver.rb#438 def silenced_unknown_error_messages; end - # source://capybara//lib/capybara/selenium/driver.rb#507 + # source://capybara//lib/capybara/selenium/driver.rb#467 def specialize_driver; end - # source://capybara//lib/capybara/selenium/driver.rb#363 + # source://capybara//lib/capybara/selenium/driver.rb#340 def unhandled_alert_errors; end - # source://capybara//lib/capybara/selenium/driver.rb#478 + # source://capybara//lib/capybara/selenium/driver.rb#442 def unwrap_script_result(arg); end - # source://capybara//lib/capybara/selenium/driver.rb#529 + # source://capybara//lib/capybara/selenium/driver.rb#489 def wait_for_empty_page(timer); end - # source://capybara//lib/capybara/selenium/driver.rb#460 - def with_legacy_error(errors, legacy_error); end - - # source://capybara//lib/capybara/selenium/driver.rb#421 + # source://capybara//lib/capybara/selenium/driver.rb#395 def within_given_window(handle); end class << self # source://capybara//lib/capybara/selenium/driver.rb#22 def load_selenium; end - # source://capybara//lib/capybara/selenium/driver.rb#59 + # source://capybara//lib/capybara/selenium/driver.rb#57 def register_specialization(browser_name, specialization); end # Returns the value of attribute selenium_webdriver_version. @@ -6972,7 +7258,7 @@ class Capybara::Selenium::Driver < ::Capybara::Driver::Base # Returns the value of attribute specializations. # - # source://capybara//lib/capybara/selenium/driver.rb#57 + # source://capybara//lib/capybara/selenium/driver.rb#55 def specializations; end end end @@ -7103,11 +7389,6 @@ module Capybara::Selenium::Driver::FirefoxDriver # # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#6 def extended(driver); end - - # @return [Boolean] - # - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#12 - def w3c?(driver); end end end @@ -7136,37 +7417,37 @@ module Capybara::Selenium::Driver::SafariDriver def build_node(native_node, initial_cache = T.unsafe(nil)); end end -# source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#18 +# source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#13 module Capybara::Selenium::Driver::W3CFirefoxDriver - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#59 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#54 def refresh; end - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#41 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#36 def reset!; end - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#30 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#25 def resize_window_to(handle, width, height); end - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#68 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#63 def switch_to_frame(frame); end private - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#84 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#79 def browser_version; end - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#80 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#75 def build_node(native_node, initial_cache = T.unsafe(nil)); end class << self # @private # - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#20 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#15 def extended(driver); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#25 + # source://capybara//lib/capybara/selenium/driver_specializations/firefox_driver.rb#20 def pause_broken?(sel_driver); end end end @@ -7175,21 +7456,21 @@ end class Capybara::Selenium::EdgeNode < ::Capybara::Selenium::Node include ::Capybara::Selenium::Node::Html5Drag - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#41 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#35 def click(*_arg0, **_arg1); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#52 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#46 def disabled?; end - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#35 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#29 def drop(*args); end - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#58 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#52 def select_option; end - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#80 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#74 def send_keys(*args); end # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#17 @@ -7200,25 +7481,22 @@ class Capybara::Selenium::EdgeNode < ::Capybara::Selenium::Node # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#68 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#62 def visible?; end private - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#110 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#94 def browser_version; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#117 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#101 def chrome_edge?; end - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#100 - def file_errors; end - # @return [Boolean] # - # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#121 + # source://capybara//lib/capybara/selenium/nodes/edge_node.rb#105 def native_displayed?; end end @@ -7333,7 +7611,7 @@ class Capybara::Selenium::Node < ::Capybara::Driver::Node # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#192 + # source://capybara//lib/capybara/selenium/node.rb#190 def checked?; end # source://capybara//lib/capybara/selenium/node.rb#106 @@ -7341,49 +7619,49 @@ class Capybara::Selenium::Node < ::Capybara::Driver::Node # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#202 + # source://capybara//lib/capybara/selenium/node.rb#200 def content_editable?; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#195 + # source://capybara//lib/capybara/selenium/node.rb#193 def disabled?; end # @raise [ArgumentError] # - # source://capybara//lib/capybara/selenium/node.rb#146 + # source://capybara//lib/capybara/selenium/node.rb#144 def double_click(keys = T.unsafe(nil), **options); end - # source://capybara//lib/capybara/selenium/node.rb#163 + # source://capybara//lib/capybara/selenium/node.rb#161 def drag_to(element, drop_modifiers: T.unsafe(nil), **_arg2); end # @raise [NotImplementedError] # - # source://capybara//lib/capybara/selenium/node.rb#176 + # source://capybara//lib/capybara/selenium/node.rb#174 def drop(*_); end - # source://capybara//lib/capybara/selenium/node.rb#159 + # source://capybara//lib/capybara/selenium/node.rb#157 def hover; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#191 + # source://capybara//lib/capybara/selenium/node.rb#189 def multiple?; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#210 + # source://capybara//lib/capybara/selenium/node.rb#208 def obscured?(x: T.unsafe(nil), y: T.unsafe(nil)); end - # source://capybara//lib/capybara/selenium/node.rb#206 + # source://capybara//lib/capybara/selenium/node.rb#204 def path; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#190 + # source://capybara//lib/capybara/selenium/node.rb#188 def readonly?; end - # source://capybara//lib/capybara/selenium/node.rb#217 + # source://capybara//lib/capybara/selenium/node.rb#215 def rect; end # source://capybara//lib/capybara/selenium/node.rb#129 @@ -7394,10 +7672,10 @@ class Capybara::Selenium::Node < ::Capybara::Driver::Node # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#192 + # source://capybara//lib/capybara/selenium/node.rb#190 def selected?; end - # source://capybara//lib/capybara/selenium/node.rb#155 + # source://capybara//lib/capybara/selenium/node.rb#153 def send_keys(*args); end # Set the value of the form element to the given value. @@ -7410,13 +7688,13 @@ class Capybara::Selenium::Node < ::Capybara::Driver::Node # source://capybara//lib/capybara/selenium/node.rb#59 def set(value, **options); end - # source://capybara//lib/capybara/selenium/node.rb#221 + # source://capybara//lib/capybara/selenium/node.rb#219 def shadow_root; end # source://capybara//lib/capybara/selenium/node.rb#39 def style(styles); end - # source://capybara//lib/capybara/selenium/node.rb#180 + # source://capybara//lib/capybara/selenium/node.rb#178 def tag_name; end # @raise [Capybara::UnselectNotAllowed] @@ -7429,7 +7707,7 @@ class Capybara::Selenium::Node < ::Capybara::Driver::Node # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#189 + # source://capybara//lib/capybara/selenium/node.rb#187 def visible?; end # @raise [NotImplementedError] @@ -7439,154 +7717,149 @@ class Capybara::Selenium::Node < ::Capybara::Driver::Node protected - # source://capybara//lib/capybara/selenium/node.rb#230 + # source://capybara//lib/capybara/selenium/node.rb#226 def scroll_if_needed; end - # source://capybara//lib/capybara/selenium/node.rb#237 + # source://capybara//lib/capybara/selenium/node.rb#233 def scroll_to_center; end private - # source://capybara//lib/capybara/selenium/node.rb#483 + # source://capybara//lib/capybara/selenium/node.rb#464 def action_pause(action, duration); end - # source://capybara//lib/capybara/selenium/node.rb#415 + # source://capybara//lib/capybara/selenium/node.rb#411 def action_with_modifiers(click_options); end - # source://capybara//lib/capybara/selenium/node.rb#518 + # source://capybara//lib/capybara/selenium/node.rb#491 def attrs(*attr_names); end - # source://capybara//lib/capybara/selenium/node.rb#299 + # source://capybara//lib/capybara/selenium/node.rb#295 def auto_rapid_set_length; end - # source://capybara//lib/capybara/selenium/node.rb#268 + # source://capybara//lib/capybara/selenium/node.rb#264 def boolean_attr(val); end - # source://capybara//lib/capybara/selenium/node.rb#466 + # source://capybara//lib/capybara/selenium/node.rb#452 def bridge; end - # source://capybara//lib/capybara/selenium/node.rb#462 + # source://capybara//lib/capybara/selenium/node.rb#448 def browser; end - # source://capybara//lib/capybara/selenium/node.rb#470 + # source://capybara//lib/capybara/selenium/node.rb#456 def browser_action; end - # source://capybara//lib/capybara/selenium/node.rb#514 + # source://capybara//lib/capybara/selenium/node.rb#487 def build_node(native_node, initial_cache = T.unsafe(nil)); end - # source://capybara//lib/capybara/selenium/node.rb#474 + # source://capybara//lib/capybara/selenium/node.rb#460 def capabilities; end - # source://capybara//lib/capybara/selenium/node.rb#506 + # source://capybara//lib/capybara/selenium/node.rb#479 def each_key(keys, &block); end - # source://capybara//lib/capybara/selenium/node.rb#510 + # source://capybara//lib/capybara/selenium/node.rb#483 def find_context; end - # source://capybara//lib/capybara/selenium/node.rb#452 + # source://capybara//lib/capybara/selenium/node.rb#438 def modifiers_down(actions, keys); end - # source://capybara//lib/capybara/selenium/node.rb#457 + # source://capybara//lib/capybara/selenium/node.rb#443 def modifiers_up(actions, keys); end - # source://capybara//lib/capybara/selenium/node.rb#530 + # source://capybara//lib/capybara/selenium/node.rb#503 def native_id; end - # source://capybara//lib/capybara/selenium/node.rb#495 + # source://capybara//lib/capybara/selenium/node.rb#468 def normalize_keys(keys); end # @raise [ArgumentError] # - # source://capybara//lib/capybara/selenium/node.rb#303 + # source://capybara//lib/capybara/selenium/node.rb#299 def perform_with_options(click_options, &block); end # a reference to the select node if this is an option node # - # source://capybara//lib/capybara/selenium/node.rb#273 + # source://capybara//lib/capybara/selenium/node.rb#269 def select_node; end - # source://capybara//lib/capybara/selenium/node.rb#341 + # source://capybara//lib/capybara/selenium/node.rb#337 def set_color(value); end - # source://capybara//lib/capybara/selenium/node.rb#391 + # source://capybara//lib/capybara/selenium/node.rb#387 def set_content_editable(value); end - # source://capybara//lib/capybara/selenium/node.rb#317 + # source://capybara//lib/capybara/selenium/node.rb#313 def set_date(value); end - # source://capybara//lib/capybara/selenium/node.rb#333 + # source://capybara//lib/capybara/selenium/node.rb#329 def set_datetime_local(value); end - # source://capybara//lib/capybara/selenium/node.rb#363 + # source://capybara//lib/capybara/selenium/node.rb#359 def set_file(value); end - # source://capybara//lib/capybara/selenium/node.rb#345 + # source://capybara//lib/capybara/selenium/node.rb#341 def set_range(value); end - # source://capybara//lib/capybara/selenium/node.rb#277 + # source://capybara//lib/capybara/selenium/node.rb#273 def set_text(value, clear: T.unsafe(nil), rapid: T.unsafe(nil), **_unused); end - # source://capybara//lib/capybara/selenium/node.rb#325 + # source://capybara//lib/capybara/selenium/node.rb#321 def set_time(value); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#536 + # source://capybara//lib/capybara/selenium/node.rb#509 def shadow_root?; end - # source://capybara//lib/capybara/selenium/node.rb#254 + # source://capybara//lib/capybara/selenium/node.rb#250 def sibling_index(parent, node, selector); end - # source://capybara//lib/capybara/selenium/node.rb#349 + # source://capybara//lib/capybara/selenium/node.rb#345 def update_value_js(value); end - # @return [Boolean] - # - # source://capybara//lib/capybara/selenium/node.rb#478 - def w3c?; end - - # source://capybara//lib/capybara/selenium/node.rb#373 + # source://capybara//lib/capybara/selenium/node.rb#369 def with_file_detector; end end # ClickOptions encapsulates click option logic # -# source://capybara//lib/capybara/selenium/node.rb#634 +# source://capybara//lib/capybara/selenium/node.rb#607 class Capybara::Selenium::Node::ClickOptions # @return [ClickOptions] a new instance of ClickOptions # - # source://capybara//lib/capybara/selenium/node.rb#637 + # source://capybara//lib/capybara/selenium/node.rb#610 def initialize(keys, options); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#650 + # source://capybara//lib/capybara/selenium/node.rb#623 def center_offset?; end - # source://capybara//lib/capybara/selenium/node.rb#646 + # source://capybara//lib/capybara/selenium/node.rb#619 def coords; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#642 + # source://capybara//lib/capybara/selenium/node.rb#615 def coords?; end - # source://capybara//lib/capybara/selenium/node.rb#658 + # source://capybara//lib/capybara/selenium/node.rb#631 def delay; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#654 + # source://capybara//lib/capybara/selenium/node.rb#627 def empty?; end # Returns the value of attribute keys. # - # source://capybara//lib/capybara/selenium/node.rb#635 + # source://capybara//lib/capybara/selenium/node.rb#608 def keys; end # Returns the value of attribute options. # - # source://capybara//lib/capybara/selenium/node.rb#635 + # source://capybara//lib/capybara/selenium/node.rb#608 def options; end end @@ -7611,7 +7884,7 @@ module Capybara::Selenium::Node::FileInputClickEmulation def visible_file_field?; end end -# source://capybara//lib/capybara/selenium/node.rb#540 +# source://capybara//lib/capybara/selenium/node.rb#513 Capybara::Selenium::Node::GET_XPATH_SCRIPT = T.let(T.unsafe(nil), String) # source://capybara//lib/capybara/selenium/extensions/html5_drag.rb#4 @@ -7683,46 +7956,46 @@ class Capybara::Selenium::Node::ModifierKeysStack def push; end end -# source://capybara//lib/capybara/selenium/node.rb#572 +# source://capybara//lib/capybara/selenium/node.rb#545 Capybara::Selenium::Node::OBSCURED_OR_OFFSET_SCRIPT = T.let(T.unsafe(nil), String) -# source://capybara//lib/capybara/selenium/node.rb#589 +# source://capybara//lib/capybara/selenium/node.rb#562 Capybara::Selenium::Node::RAPID_APPEND_TEXT = T.let(T.unsafe(nil), String) # SettableValue encapsulates time/date field formatting # -# source://capybara//lib/capybara/selenium/node.rb#600 +# source://capybara//lib/capybara/selenium/node.rb#573 class Capybara::Selenium::Node::SettableValue # @return [SettableValue] a new instance of SettableValue # - # source://capybara//lib/capybara/selenium/node.rb#603 + # source://capybara//lib/capybara/selenium/node.rb#576 def initialize(value); end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#611 + # source://capybara//lib/capybara/selenium/node.rb#584 def dateable?; end # @return [Boolean] # - # source://capybara//lib/capybara/selenium/node.rb#619 + # source://capybara//lib/capybara/selenium/node.rb#592 def timeable?; end - # source://capybara//lib/capybara/selenium/node.rb#615 + # source://capybara//lib/capybara/selenium/node.rb#588 def to_date_str; end - # source://capybara//lib/capybara/selenium/node.rb#627 + # source://capybara//lib/capybara/selenium/node.rb#600 def to_datetime_str; end - # source://capybara//lib/capybara/selenium/node.rb#607 + # source://capybara//lib/capybara/selenium/node.rb#580 def to_s; end - # source://capybara//lib/capybara/selenium/node.rb#623 + # source://capybara//lib/capybara/selenium/node.rb#596 def to_time_str; end # Returns the value of attribute value. # - # source://capybara//lib/capybara/selenium/node.rb#601 + # source://capybara//lib/capybara/selenium/node.rb#574 def value; end end @@ -8046,7 +8319,7 @@ class Capybara::Session # @return [Session] a new instance of Session # - # source://capybara//lib/capybara/session.rb#78 + # source://capybara//lib/capybara/session.rb#79 def initialize(mode, app = T.unsafe(nil)); end # Execute the block, accepting a alert. @@ -8062,7 +8335,7 @@ class Capybara::Session # @raise [Capybara::ModalNotFound] if modal dialog hasn't been found # @return [String] the message shown in the modal # - # source://capybara//lib/capybara/session.rb#658 + # source://capybara//lib/capybara/session.rb#659 def accept_alert(text = T.unsafe(nil), **options, &blk); end # Execute the block, accepting a confirm. @@ -8078,7 +8351,7 @@ class Capybara::Session # @raise [Capybara::ModalNotFound] if modal dialog hasn't been found # @return [String] the message shown in the modal # - # source://capybara//lib/capybara/session.rb#668 + # source://capybara//lib/capybara/session.rb#669 def accept_confirm(text = T.unsafe(nil), **options, &blk); end # Execute the block, accepting a prompt, optionally responding to the prompt. @@ -8096,63 +8369,63 @@ class Capybara::Session # @raise [Capybara::ModalNotFound] if modal dialog hasn't been found # @return [String] the message shown in the modal # - # source://capybara//lib/capybara/session.rb#689 + # source://capybara//lib/capybara/session.rb#690 def accept_prompt(text = T.unsafe(nil), **options, &blk); end # Returns the element with focus. # # Not supported by Rack Test # - # source://capybara//lib/capybara/session.rb#322 + # source://capybara//lib/capybara/session.rb#323 def active_element; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def all(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute app. # - # source://capybara//lib/capybara/session.rb#75 + # source://capybara//lib/capybara/session.rb#76 def app; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def assert_all_of_selectors(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def assert_any_of_selectors(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def assert_no_selector(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def assert_no_text(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#780 + # source://capybara//lib/capybara/session.rb#781 def assert_no_title(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def assert_none_of_selectors(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def assert_selector(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def assert_text(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#780 + # source://capybara//lib/capybara/session.rb#781 def assert_title(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def attach_file(*_arg0, **_arg1, &_arg2); end # @return [String] A snapshot of the DOM of the current document, as it looks right now (potentially modified by JavaScript). # - # source://capybara//lib/capybara/session.rb#196 + # source://capybara//lib/capybara/session.rb#197 def body; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def check(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def choose(*_arg0, **_arg1, &_arg2); end # Reset the session (i.e. remove cookies and navigate to blank page). @@ -8171,25 +8444,25 @@ class Capybara::Session # * monkeypatch this method # * use Ruby's `prepend` method # - # source://capybara//lib/capybara/session.rb#129 + # source://capybara//lib/capybara/session.rb#130 def cleanup!; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def click(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def click_button(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def click_link(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def click_link_or_button(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def click_on(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#828 + # source://capybara//lib/capybara/session.rb#829 def config; end # Accepts a block to set the configuration options if {Capybara.configure threadsafe} is `true`. Note that some options only have an effect @@ -8197,30 +8470,30 @@ class Capybara::Session # # @yield [config] # - # source://capybara//lib/capybara/session.rb#818 + # source://capybara//lib/capybara/session.rb#819 def configure; end # @return [String] Host of the current page # - # source://capybara//lib/capybara/session.rb#221 + # source://capybara//lib/capybara/session.rb#222 def current_host; end # @return [String] Path of the current page, without any domain information # - # source://capybara//lib/capybara/session.rb#206 + # source://capybara//lib/capybara/session.rb#207 def current_path; end - # source://capybara//lib/capybara/session.rb#790 + # source://capybara//lib/capybara/session.rb#791 def current_scope; end # @return [String] Fully qualified URL of the current page # - # source://capybara//lib/capybara/session.rb#230 + # source://capybara//lib/capybara/session.rb#231 def current_url; end # @return [Capybara::Window] current window # - # source://capybara//lib/capybara/session.rb#459 + # source://capybara//lib/capybara/session.rb#460 def current_window; end # Execute the block, dismissing a confirm. @@ -8236,7 +8509,7 @@ class Capybara::Session # @raise [Capybara::ModalNotFound] if modal dialog hasn't been found # @return [String] the message shown in the modal # - # source://capybara//lib/capybara/session.rb#678 + # source://capybara//lib/capybara/session.rb#679 def dismiss_confirm(text = T.unsafe(nil), **options, &blk); end # Execute the block, dismissing a prompt. @@ -8252,16 +8525,16 @@ class Capybara::Session # @raise [Capybara::ModalNotFound] if modal dialog hasn't been found # @return [String] the message shown in the modal # - # source://capybara//lib/capybara/session.rb#699 + # source://capybara//lib/capybara/session.rb#700 def dismiss_prompt(text = T.unsafe(nil), **options, &blk); end - # source://capybara//lib/capybara/session.rb#765 + # source://capybara//lib/capybara/session.rb#766 def document; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def double_click(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#99 + # source://capybara//lib/capybara/session.rb#100 def driver; end # Evaluate the given JavaScript and obtain the result from a callback function which will be passed as the last argument to the script. @@ -8270,7 +8543,7 @@ class Capybara::Session # @param args Optional arguments that will be passed to the script # @return [Object] The result of the evaluated JavaScript (may be driver specific) # - # source://capybara//lib/capybara/session.rb#632 + # source://capybara//lib/capybara/session.rb#633 def evaluate_async_script(script, *args); end # Evaluate the given JavaScript and return the result. Be careful when using this with @@ -8281,7 +8554,7 @@ class Capybara::Session # @param args Optional arguments that will be passed to the script # @return [Object] The result of the evaluated JavaScript (may be driver specific) # - # source://capybara//lib/capybara/session.rb#618 + # source://capybara//lib/capybara/session.rb#619 def evaluate_script(script, *args); end # Execute the given script, not returning a result. This is useful for scripts that return @@ -8291,132 +8564,138 @@ class Capybara::Session # @param script [String] A string of JavaScript to execute # @param args Optional arguments that will be passed to the script. Driver support for this is optional and types of objects supported may differ between drivers # - # source://capybara//lib/capybara/session.rb#603 + # source://capybara//lib/capybara/session.rb#604 def execute_script(script, *args); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def fill_in(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def find(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def find_all(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def find_button(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def find_by_id(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def find_field(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def find_link(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def first(*_arg0, **_arg1, &_arg2); end # Move back a single entry in the browser's history. # - # source://capybara//lib/capybara/session.rb#296 + # source://capybara//lib/capybara/session.rb#297 def go_back; end # Move forward a single entry in the browser's history. # - # source://capybara//lib/capybara/session.rb#304 + # source://capybara//lib/capybara/session.rb#305 def go_forward; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_button?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_checked_field?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_content?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_css?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 + def has_element?(*_arg0, **_arg1, &_arg2); end + + # source://capybara//lib/capybara/session.rb#772 def has_field?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_link?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_button?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_checked_field?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_content?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_css?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 + def has_no_element?(*_arg0, **_arg1, &_arg2); end + + # source://capybara//lib/capybara/session.rb#772 def has_no_field?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_link?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_select?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_selector?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_table?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_text?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#780 + # source://capybara//lib/capybara/session.rb#781 def has_no_title?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_unchecked_field?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_no_xpath?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_select?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_selector?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_table?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_text?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#780 + # source://capybara//lib/capybara/session.rb#781 def has_title?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_unchecked_field?(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def has_xpath?(*_arg0, **_arg1, &_arg2); end # @return [String] A snapshot of the DOM of the current document, as it looks right now (potentially modified by JavaScript). # - # source://capybara//lib/capybara/session.rb#196 + # source://capybara//lib/capybara/session.rb#197 def html; end - # source://capybara//lib/capybara/session.rb#786 + # source://capybara//lib/capybara/session.rb#787 def inspect; end # Returns the value of attribute mode. # - # source://capybara//lib/capybara/session.rb#75 + # source://capybara//lib/capybara/session.rb#76 def mode; end # Open a new window. @@ -8425,28 +8704,28 @@ class Capybara::Session # # @return [Capybara::Window] window that has been opened # - # source://capybara//lib/capybara/session.rb#483 + # source://capybara//lib/capybara/session.rb#484 def open_new_window(kind = T.unsafe(nil)); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def query(*_arg0, **_arg1, &_arg2); end # Disconnect from the current driver. A new driver will be instantiated on the next interaction. # - # source://capybara//lib/capybara/session.rb#146 + # source://capybara//lib/capybara/session.rb#147 def quit; end # Raise errors encountered in the server. # - # source://capybara//lib/capybara/session.rb#157 + # source://capybara//lib/capybara/session.rb#158 def raise_server_error!; end # Refresh the page. # - # source://capybara//lib/capybara/session.rb#287 + # source://capybara//lib/capybara/session.rb#288 def refresh; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def refute_selector(*_arg0, **_arg1, &_arg2); end # Reset the session (i.e. remove cookies and navigate to blank page). @@ -8465,7 +8744,7 @@ class Capybara::Session # * monkeypatch this method # * use Ruby's `prepend` method # - # source://capybara//lib/capybara/session.rb#129 + # source://capybara//lib/capybara/session.rb#130 def reset!; end # Reset the session (i.e. remove cookies and navigate to blank page). @@ -8484,17 +8763,17 @@ class Capybara::Session # * monkeypatch this method # * use Ruby's `prepend` method # - # source://capybara//lib/capybara/session.rb#129 + # source://capybara//lib/capybara/session.rb#130 def reset_session!; end # Returns a hash of response headers. Not supported by all drivers (e.g. Selenium). # # @return [Hash] A hash of response headers. # - # source://capybara//lib/capybara/session.rb#178 + # source://capybara//lib/capybara/session.rb#179 def response_headers; end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def right_click(*_arg0, **_arg1, &_arg2); end # Save a snapshot of the page and open it in a browser for inspection. @@ -8505,7 +8784,7 @@ class Capybara::Session # # @param path [String] the path to where it should be saved # - # source://capybara//lib/capybara/session.rb#731 + # source://capybara//lib/capybara/session.rb#732 def save_and_open_page(path = T.unsafe(nil)); end # Save a screenshot of the page and open it for inspection. @@ -8517,7 +8796,7 @@ class Capybara::Session # @param path [String] the path to where it should be saved # @param options [Hash] a customizable set of options # - # source://capybara//lib/capybara/session.rb#761 + # source://capybara//lib/capybara/session.rb#762 def save_and_open_screenshot(path = T.unsafe(nil), **options); end # Save a snapshot of the page. If {Capybara.configure asset_host} is set it will inject `base` tag @@ -8530,7 +8809,7 @@ class Capybara::Session # @param path [String] the path to where it should be saved # @return [String] the path to which the file was saved # - # source://capybara//lib/capybara/session.rb#715 + # source://capybara//lib/capybara/session.rb#716 def save_page(path = T.unsafe(nil)); end # Save a screenshot of page. @@ -8543,39 +8822,39 @@ class Capybara::Session # @param options [Hash] a customizable set of options # @return [String] the path to which the file was saved # - # source://capybara//lib/capybara/session.rb#746 + # source://capybara//lib/capybara/session.rb#747 def save_screenshot(path = T.unsafe(nil), **options); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def scroll_by(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def scroll_to(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def select(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#312 - def send_keys(*args, **kw_args); end + # source://capybara//lib/capybara/session.rb#313 + def send_keys(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute server. # - # source://capybara//lib/capybara/session.rb#75 + # source://capybara//lib/capybara/session.rb#76 def server; end - # source://capybara//lib/capybara/session.rb#836 + # source://capybara//lib/capybara/session.rb#837 def server_url; end # @return [String] A snapshot of the DOM of the current document, as it looks right now (potentially modified by JavaScript). # - # source://capybara//lib/capybara/session.rb#196 + # source://capybara//lib/capybara/session.rb#197 def source; end # Returns the current HTTP status code as an integer. Not supported by all drivers (e.g. Selenium). # # @return [Integer] Current HTTP status code # - # source://capybara//lib/capybara/session.rb#188 + # source://capybara//lib/capybara/session.rb#189 def status_code; end # Switch to the given frame. @@ -8587,7 +8866,7 @@ class Capybara::Session # @overload switch_to_frame # @overload switch_to_frame # - # source://capybara//lib/capybara/session.rb#407 + # source://capybara//lib/capybara/session.rb#408 def switch_to_frame(frame); end # Switch to the given window. @@ -8599,36 +8878,36 @@ class Capybara::Session # @raise [ArgumentError] if both or neither arguments were provided # @return [Capybara::Window] window that has been switched to # - # source://capybara//lib/capybara/session.rb#511 + # source://capybara//lib/capybara/session.rb#512 def switch_to_window(window = T.unsafe(nil), **options, &window_locator); end # Returns the value of attribute synchronized. # - # source://capybara//lib/capybara/session.rb#76 + # source://capybara//lib/capybara/session.rb#77 def synchronized; end # Sets the attribute synchronized # # @param value the value to set the attribute synchronized to. # - # source://capybara//lib/capybara/session.rb#76 + # source://capybara//lib/capybara/session.rb#77 def synchronized=(_arg0); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def text(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#780 + # source://capybara//lib/capybara/session.rb#781 def title(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def uncheck(*_arg0, **_arg1, &_arg2); end - # source://capybara//lib/capybara/session.rb#771 + # source://capybara//lib/capybara/session.rb#772 def unselect(*_arg0, **_arg1, &_arg2); end # Yield a block using a specific maximum wait time. # - # source://capybara//lib/capybara/session.rb#799 + # source://capybara//lib/capybara/session.rb#800 def using_wait_time(seconds, &block); end # Navigate to the given URL. The URL can either be a relative URL or an absolute URL @@ -8655,7 +8934,7 @@ class Capybara::Session # # @param visit_uri [#to_s] The URL to navigate to. The parameter will be cast to a String. # - # source://capybara//lib/capybara/session.rb#260 + # source://capybara//lib/capybara/session.rb#261 def visit(visit_uri); end # Get the window that has been opened by the passed block. @@ -8665,7 +8944,7 @@ class Capybara::Session # # @overload window_opened_by # - # source://capybara//lib/capybara/session.rb#580 + # source://capybara//lib/capybara/session.rb#581 def window_opened_by(**options); end # Get all opened windows. @@ -8674,7 +8953,7 @@ class Capybara::Session # # @return [Array] an array of all windows # - # source://capybara//lib/capybara/session.rb#470 + # source://capybara//lib/capybara/session.rb#471 def windows; end # Executes the given block within the context of a node. {#within} takes the @@ -8706,7 +8985,7 @@ class Capybara::Session # @overload within # @raise [Capybara::ElementNotFound] If the scope can't be found before time expires # - # source://capybara//lib/capybara/session.rb#361 + # source://capybara//lib/capybara/session.rb#362 def within(*args, **kw_args); end # Executes the given block within the context of a node. {#within} takes the @@ -8738,14 +9017,14 @@ class Capybara::Session # @overload within # @raise [Capybara::ElementNotFound] If the scope can't be found before time expires # - # source://capybara//lib/capybara/session.rb#361 + # source://capybara//lib/capybara/session.rb#362 def within_element(*args, **kw_args); end # Execute the given block within the a specific fieldset given the id or legend of that fieldset. # # @param locator [String] Id or legend of the fieldset # - # source://capybara//lib/capybara/session.rb#378 + # source://capybara//lib/capybara/session.rb#379 def within_fieldset(locator, &block); end # Execute the given block within the given iframe using given frame, frame name/id or index. @@ -8755,14 +9034,14 @@ class Capybara::Session # @overload within_frame # @overload within_frame # - # source://capybara//lib/capybara/session.rb#447 + # source://capybara//lib/capybara/session.rb#448 def within_frame(*args, **kw_args); end # Execute the given block within the a specific table given the id or caption of that table. # # @param locator [String] Id or caption of the table # - # source://capybara//lib/capybara/session.rb#388 + # source://capybara//lib/capybara/session.rb#389 def within_table(locator, &block); end # This method does the following: @@ -8776,80 +9055,80 @@ class Capybara::Session # @raise [Capybara::ScopeError] if this method is invoked inside {#within_frame} method # @return value returned by the block # - # source://capybara//lib/capybara/session.rb#544 + # source://capybara//lib/capybara/session.rb#545 def within_window(window_or_proc); end private - # source://capybara//lib/capybara/session.rb#901 + # source://capybara//lib/capybara/session.rb#902 def _find_frame(*args, **kw_args); end # @raise [Capybara::ScopeError] # - # source://capybara//lib/capybara/session.rb#917 + # source://capybara//lib/capybara/session.rb#918 def _switch_to_window(window = T.unsafe(nil), **options, &window_locator); end # @raise [Capybara::WindowError] # - # source://capybara//lib/capybara/session.rb#937 + # source://capybara//lib/capybara/session.rb#938 def _switch_to_window_by_locator; end - # source://capybara//lib/capybara/session.rb#848 + # source://capybara//lib/capybara/session.rb#849 def accept_modal(type, text_or_options, options, &blk); end - # source://capybara//lib/capybara/session.rb#897 + # source://capybara//lib/capybara/session.rb#898 def adjust_server_port(uri); end - # source://capybara//lib/capybara/session.rb#875 + # source://capybara//lib/capybara/session.rb#876 def default_fn(extension); end - # source://capybara//lib/capybara/session.rb#852 + # source://capybara//lib/capybara/session.rb#853 def dismiss_modal(type, text_or_options, options, &blk); end - # source://capybara//lib/capybara/session.rb#844 + # source://capybara//lib/capybara/session.rb#845 def driver_args(args); end - # source://capybara//lib/capybara/session.rb#884 + # source://capybara//lib/capybara/session.rb#885 def element_script_result(arg); end - # source://capybara//lib/capybara/session.rb#856 + # source://capybara//lib/capybara/session.rb#857 def modal_options(text = T.unsafe(nil), **options); end - # source://capybara//lib/capybara/session.rb#862 + # source://capybara//lib/capybara/session.rb#863 def open_file(path); end - # source://capybara//lib/capybara/session.rb#869 + # source://capybara//lib/capybara/session.rb#870 def prepare_path(path, extension); end - # source://capybara//lib/capybara/session.rb#880 + # source://capybara//lib/capybara/session.rb#881 def scopes; end - # source://capybara//lib/capybara/session.rb#945 + # source://capybara//lib/capybara/session.rb#946 def synchronize_windows(options, &block); end class << self # @return [Boolean] # - # source://capybara//lib/capybara/session.rb#824 + # source://capybara//lib/capybara/session.rb#825 def instance_created?; end end end # @api private # -# source://capybara//lib/capybara/session.rb#57 +# source://capybara//lib/capybara/session.rb#58 Capybara::Session::DOCUMENT_METHODS = T.let(T.unsafe(nil), Array) -# source://capybara//lib/capybara/session.rb#73 +# source://capybara//lib/capybara/session.rb#74 Capybara::Session::DSL_METHODS = T.let(T.unsafe(nil), Array) -# source://capybara//lib/capybara/session.rb#70 +# source://capybara//lib/capybara/session.rb#71 Capybara::Session::MODAL_METHODS = T.let(T.unsafe(nil), Array) # source://capybara//lib/capybara/session.rb#41 Capybara::Session::NODE_METHODS = T.let(T.unsafe(nil), Array) -# source://capybara//lib/capybara/session.rb#60 +# source://capybara//lib/capybara/session.rb#61 Capybara::Session::SESSION_METHODS = T.let(T.unsafe(nil), Array) # source://capybara//lib/capybara/session/config.rb#6 @@ -9590,21 +9869,6 @@ module XPath::DSL def ~(*args); end end -# source://xpath/3.2.0/lib/xpath/dsl.rb#128 -XPath::DSL::AXES = T.let(T.unsafe(nil), Array) - -# source://xpath/3.2.0/lib/xpath/dsl.rb#152 -XPath::DSL::LOWERCASE_LETTERS = T.let(T.unsafe(nil), String) - -# source://xpath/3.2.0/lib/xpath/dsl.rb#75 -XPath::DSL::METHODS = T.let(T.unsafe(nil), Array) - -# source://xpath/3.2.0/lib/xpath/dsl.rb#105 -XPath::DSL::OPERATORS = T.let(T.unsafe(nil), Array) - -# source://xpath/3.2.0/lib/xpath/dsl.rb#151 -XPath::DSL::UPPERCASE_LETTERS = T.let(T.unsafe(nil), String) - # source://capybara//lib/capybara/selector/xpath_extensions.rb#4 class XPath::Renderer # source://xpath/3.2.0/lib/xpath/renderer.rb#9 diff --git a/sorbet/rbi/gems/carrierwave@2.2.4.rbi b/sorbet/rbi/gems/carrierwave@3.0.7.rbi similarity index 85% rename from sorbet/rbi/gems/carrierwave@2.2.4.rbi rename to sorbet/rbi/gems/carrierwave@3.0.7.rbi index 63203ea37..fbbbf80af 100644 --- a/sorbet/rbi/gems/carrierwave@2.2.4.rbi +++ b/sorbet/rbi/gems/carrierwave@3.0.7.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `carrierwave` gem. # Please instead update this file by running `bin/tapioca gem carrierwave`. + # source://carrierwave//lib/carrierwave.rb#7 module CarrierWave class << self @@ -77,24 +78,24 @@ module CarrierWave::Compatibility::Paperclip mixes_in_class_methods GeneratedClassMethods mixes_in_class_methods ::CarrierWave::Compatibility::Paperclip::ClassMethods - # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#78 + # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#79 def paperclip_default_style; end - # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#82 + # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#83 def paperclip_path; end - # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#85 + # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#86 def paperclip_style; end - # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#74 + # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#75 def store_dir; end - # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#67 + # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#68 def store_path(for_file = T.unsafe(nil)); end private - # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#96 + # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#98 def interpolate_paperclip_path(path); end module GeneratedClassMethods @@ -110,9 +111,9 @@ module CarrierWave::Compatibility::Paperclip end end -# source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#89 +# source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#90 module CarrierWave::Compatibility::Paperclip::ClassMethods - # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#90 + # source://carrierwave//lib/carrierwave/compatibility/paperclip.rb#91 def interpolate(sym, &block); end end @@ -127,9 +128,11 @@ module CarrierWave::Downloader; end # source://carrierwave//lib/carrierwave/downloader/base.rb#8 class CarrierWave::Downloader::Base + include ::CarrierWave::Utilities::Uri + # @return [Base] a new instance of Base # - # source://carrierwave//lib/carrierwave/downloader/base.rb#11 + # source://carrierwave//lib/carrierwave/downloader/base.rb#13 def initialize(uploader); end # Downloads a file from given URL and returns a RemoteFile. @@ -139,7 +142,7 @@ class CarrierWave::Downloader::Base # [url (String)] The URL where the remote file is stored # [remote_headers (Hash)] Request headers # - # source://carrierwave//lib/carrierwave/downloader/base.rb#23 + # source://carrierwave//lib/carrierwave/downloader/base.rb#25 def download(url, remote_headers = T.unsafe(nil)); end # Processes the given URL by parsing it, and escaping if necessary. Public to allow overriding. @@ -148,8 +151,8 @@ class CarrierWave::Downloader::Base # # [url (String)] The URL where the remote file is stored # - # source://carrierwave//lib/carrierwave/downloader/base.rb#57 - def process_uri(uri); end + # source://carrierwave//lib/carrierwave/downloader/base.rb#66 + def process_uri(source); end # If this returns true, SSRF protection will be bypassed. # You can override this if you want to allow accessing specific local URIs that are not SSRF exploitable. @@ -170,12 +173,12 @@ class CarrierWave::Downloader::Base # # @return [Boolean] # - # source://carrierwave//lib/carrierwave/downloader/base.rb#88 + # source://carrierwave//lib/carrierwave/downloader/base.rb#96 def skip_ssrf_protection?(uri); end # Returns the value of attribute uploader. # - # source://carrierwave//lib/carrierwave/downloader/base.rb#9 + # source://carrierwave//lib/carrierwave/downloader/base.rb#11 def uploader; end end @@ -186,7 +189,7 @@ class CarrierWave::Downloader::RemoteFile # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#6 def initialize(file); end - # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#23 + # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#26 def content_type; end # Returns the value of attribute file. @@ -194,17 +197,12 @@ class CarrierWave::Downloader::RemoteFile # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#4 def file; end - # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#27 + # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#30 def headers; end - # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#31 + # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#34 def original_filename; end - # @return [Boolean] - # - # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#40 - def respond_to?(*args); end - # Returns the value of attribute uri. # # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#4 @@ -220,6 +218,11 @@ class CarrierWave::Downloader::RemoteFile # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#59 def method_missing(*args, &block); end + + # @return [Boolean] + # + # source://carrierwave//lib/carrierwave/downloader/remote_file.rb#63 + def respond_to_missing?(*args); end end # source://carrierwave//lib/carrierwave/uploader/cache.rb#5 @@ -296,7 +299,7 @@ module CarrierWave::MiniMagick # # === Parameters # - # [format (#to_s)] an abreviation of the format + # [format (#to_s)] an abbreviation of the format # # === Yields # @@ -362,7 +365,7 @@ module CarrierWave::MiniMagick # # [CarrierWave::ProcessingError] if processing failed. # - # source://carrierwave//lib/carrierwave/processing/mini_magick.rb#291 + # source://carrierwave//lib/carrierwave/processing/mini_magick.rb#292 def minimagick!(block = T.unsafe(nil)); end # Resize the image to fit within the specified dimensions while retaining @@ -452,10 +455,10 @@ module CarrierWave::MiniMagick private - # source://carrierwave//lib/carrierwave/processing/mini_magick.rb#326 + # source://carrierwave//lib/carrierwave/processing/mini_magick.rb#328 def mini_magick_image; end - # source://carrierwave//lib/carrierwave/processing/mini_magick.rb#319 + # source://carrierwave//lib/carrierwave/processing/mini_magick.rb#321 def resolve_dimensions(*dimensions); end end @@ -663,7 +666,7 @@ module CarrierWave::Mount # end # end # - # source://carrierwave//lib/carrierwave/mount.rb#297 + # source://carrierwave//lib/carrierwave/mount.rb#279 def mount_uploaders(column, uploader = T.unsafe(nil), options = T.unsafe(nil), &block); end # Return a particular option for a particular uploader @@ -692,29 +695,32 @@ module CarrierWave::Mount private - # source://carrierwave//lib/carrierwave/mount.rb#422 - def build_uploader(uploader, &block); end + # source://carrierwave//lib/carrierwave/mount.rb#405 + def build_uploader(uploader, column, &block); end - # source://carrierwave//lib/carrierwave/mount.rb#362 + # source://carrierwave//lib/carrierwave/mount.rb#327 def mount_base(column, uploader = T.unsafe(nil), options = T.unsafe(nil), &block); end end -# source://carrierwave//lib/carrierwave/mount.rb#436 +# source://carrierwave//lib/carrierwave/mount.rb#417 module CarrierWave::Mount::Extension # overwrite this to read from a serialized attribute # - # source://carrierwave//lib/carrierwave/mount.rb#441 + # source://carrierwave//lib/carrierwave/mount.rb#422 def read_uploader(column); end # overwrite this to write to a serialized attribute # - # source://carrierwave//lib/carrierwave/mount.rb#446 + # source://carrierwave//lib/carrierwave/mount.rb#427 def write_uploader(column, identifier); end private - # source://carrierwave//lib/carrierwave/mount.rb#450 + # source://carrierwave//lib/carrierwave/mount.rb#436 def _mounter(column); end + + # source://carrierwave//lib/carrierwave/mount.rb#431 + def initialize_dup(other); end end # this is an internal class, used by CarrierWave::Mount so that @@ -724,128 +730,178 @@ end class CarrierWave::Mounter # @return [Mounter] a new instance of Mounter # - # source://carrierwave//lib/carrierwave/mounter.rb#10 - def initialize(record, column, options = T.unsafe(nil)); end + # source://carrierwave//lib/carrierwave/mounter.rb#38 + def initialize(record, column); end # @return [Boolean] # - # source://carrierwave//lib/carrierwave/mounter.rb#112 + # source://carrierwave//lib/carrierwave/mounter.rb#165 def blank?; end - # source://carrierwave//lib/carrierwave/mounter.rb#23 + # source://carrierwave//lib/carrierwave/mounter.rb#54 def blank_uploader; end - # source://carrierwave//lib/carrierwave/mounter.rb#43 + # source://carrierwave//lib/carrierwave/mounter.rb#74 def cache(new_files); end - # source://carrierwave//lib/carrierwave/mounter.rb#70 + # source://carrierwave//lib/carrierwave/mounter.rb#103 def cache_names; end - # source://carrierwave//lib/carrierwave/mounter.rb#74 + # source://carrierwave//lib/carrierwave/mounter.rb#107 def cache_names=(cache_names); end - # source://carrierwave//lib/carrierwave/mounter.rb#125 + # source://carrierwave//lib/carrierwave/mounter.rb#183 def clear!; end - # source://carrierwave//lib/carrierwave/mounter.rb#6 + # Returns the value of attribute column. + # + # source://carrierwave//lib/carrierwave/mounter.rb#34 def column; end - # source://carrierwave//lib/carrierwave/mounter.rb#6 + # Returns the value of attribute download_errors. + # + # source://carrierwave//lib/carrierwave/mounter.rb#34 def download_errors; end - # source://carrierwave//lib/carrierwave/mounter.rb#27 + # source://carrierwave//lib/carrierwave/mounter.rb#58 def identifiers; end - # source://carrierwave//lib/carrierwave/mounter.rb#6 + # Returns the value of attribute integrity_errors. + # + # source://carrierwave//lib/carrierwave/mounter.rb#34 def integrity_errors; end - # source://carrierwave//lib/carrierwave/mounter.rb#6 + # Returns the value of attribute processing_errors. + # + # source://carrierwave//lib/carrierwave/mounter.rb#34 def processing_errors; end - # source://carrierwave//lib/carrierwave/mounter.rb#31 + # source://carrierwave//lib/carrierwave/mounter.rb#62 def read_identifiers; end - # source://carrierwave//lib/carrierwave/mounter.rb#6 + # Returns the value of attribute record. + # + # source://carrierwave//lib/carrierwave/mounter.rb#34 def record; end # Returns the value of attribute remote_request_headers. # - # source://carrierwave//lib/carrierwave/mounter.rb#8 + # source://carrierwave//lib/carrierwave/mounter.rb#36 def remote_request_headers; end # Sets the attribute remote_request_headers # # @param value the value to set the attribute remote_request_headers to. # - # source://carrierwave//lib/carrierwave/mounter.rb#8 + # source://carrierwave//lib/carrierwave/mounter.rb#36 def remote_request_headers=(_arg0); end - # source://carrierwave//lib/carrierwave/mounter.rb#6 + # Returns the value of attribute remote_urls. + # + # source://carrierwave//lib/carrierwave/mounter.rb#34 def remote_urls; end - # source://carrierwave//lib/carrierwave/mounter.rb#89 + # source://carrierwave//lib/carrierwave/mounter.rb#121 def remote_urls=(urls); end # Returns the value of attribute remove. # - # source://carrierwave//lib/carrierwave/mounter.rb#8 + # source://carrierwave//lib/carrierwave/mounter.rb#34 def remove; end - # source://carrierwave//lib/carrierwave/mounter.rb#120 + # source://carrierwave//lib/carrierwave/mounter.rb#178 def remove!; end - # Sets the attribute remove - # - # @param value the value to set the attribute remove to. - # - # source://carrierwave//lib/carrierwave/mounter.rb#8 - def remove=(_arg0); end + # source://carrierwave//lib/carrierwave/mounter.rb#169 + def remove=(value); end # @return [Boolean] # - # source://carrierwave//lib/carrierwave/mounter.rb#116 + # source://carrierwave//lib/carrierwave/mounter.rb#174 def remove?; end - # source://carrierwave//lib/carrierwave/mounter.rb#133 - def remove_previous(before = T.unsafe(nil), after = T.unsafe(nil)); end + # source://carrierwave//lib/carrierwave/mounter.rb#206 + def remove_added; end + + # source://carrierwave//lib/carrierwave/mounter.rb#198 + def remove_previous; end - # source://carrierwave//lib/carrierwave/mounter.rb#129 + # source://carrierwave//lib/carrierwave/mounter.rb#189 + def reset_changes!; end + + # source://carrierwave//lib/carrierwave/mounter.rb#194 def serialization_column; end - # source://carrierwave//lib/carrierwave/mounter.rb#104 + # source://carrierwave//lib/carrierwave/mounter.rb#141 def store!; end - # source://carrierwave//lib/carrierwave/mounter.rb#19 + # source://carrierwave//lib/carrierwave/mounter.rb#50 def uploader_class; end # Returns the value of attribute uploader_options. # - # source://carrierwave//lib/carrierwave/mounter.rb#161 + # source://carrierwave//lib/carrierwave/mounter.rb#36 def uploader_options; end # Sets the attribute uploader_options # # @param value the value to set the attribute uploader_options to. # - # source://carrierwave//lib/carrierwave/mounter.rb#161 + # source://carrierwave//lib/carrierwave/mounter.rb#36 def uploader_options=(_arg0); end - # source://carrierwave//lib/carrierwave/mounter.rb#35 + # source://carrierwave//lib/carrierwave/mounter.rb#66 def uploaders; end - # source://carrierwave//lib/carrierwave/mounter.rb#108 + # source://carrierwave//lib/carrierwave/mounter.rb#161 def urls(*args); end + # source://carrierwave//lib/carrierwave/mounter.rb#145 + def write_identifier; end + private - # source://carrierwave//lib/carrierwave/mounter.rb#170 + # source://carrierwave//lib/carrierwave/mounter.rb#221 def clear_unstaged; end - # source://carrierwave//lib/carrierwave/mounter.rb#175 + # source://carrierwave//lib/carrierwave/mounter.rb#228 def handle_error; end - # source://carrierwave//lib/carrierwave/mounter.rb#165 + # source://carrierwave//lib/carrierwave/mounter.rb#216 def option(name); end + + # source://carrierwave//lib/carrierwave/mounter.rb#247 + def temporary_identifiers; end + + # source://carrierwave//lib/carrierwave/mounter.rb#241 + def write_temporary_identifier; end + + class << self + # source://carrierwave//lib/carrierwave/mounter.rb#26 + def build(record, column); end + end +end + +# :nodoc +# +# source://carrierwave//lib/carrierwave/mounter.rb#16 +class CarrierWave::Mounter::Multiple < ::CarrierWave::Mounter + # source://carrierwave//lib/carrierwave/mounter.rb#17 + def identifier; end + + # source://carrierwave//lib/carrierwave/mounter.rb#21 + def temporary_identifier; end +end + +# source://carrierwave//lib/carrierwave/mounter.rb#6 +class CarrierWave::Mounter::Single < ::CarrierWave::Mounter + # :nodoc + # + # source://carrierwave//lib/carrierwave/mounter.rb#7 + def identifier; end + + # source://carrierwave//lib/carrierwave/mounter.rb#11 + def temporary_identifier; end end # source://carrierwave//lib/carrierwave/error.rb#5 @@ -915,7 +971,7 @@ module CarrierWave::RMagick # # === Parameters # - # [format (#to_s)] an abreviation of the format + # [format (#to_s)] an abbreviation of the format # # === Yields # @@ -925,7 +981,7 @@ module CarrierWave::RMagick # # image.convert(:png) # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#122 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#124 def convert(format); end # Returns the height of the image. @@ -934,7 +990,7 @@ module CarrierWave::RMagick # # [Integer] the image's height in pixels # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#285 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#281 def height; end # Manipulate the image with RMagick. This method will load up an image @@ -995,7 +1051,7 @@ module CarrierWave::RMagick # # [CarrierWave::ProcessingError] if manipulation failed. # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#348 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#344 def manipulate!(options = T.unsafe(nil), &block); end # Resize the image to fit within the specified dimensions while retaining @@ -1014,7 +1070,7 @@ module CarrierWave::RMagick # # [Magick::Image] additional manipulations to perform # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#226 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#228 def resize_and_pad(width, height, background = T.unsafe(nil), gravity = T.unsafe(nil)); end # From the RMagick documentation: "Resize the image to fit within the @@ -1032,7 +1088,7 @@ module CarrierWave::RMagick # # [Magick::Image] additional manipulations to perform # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#199 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#201 def resize_to_fill(width, height, gravity = T.unsafe(nil)); end # From the RMagick documentation: "Resize the image to fit within the @@ -1051,7 +1107,7 @@ module CarrierWave::RMagick # # [Magick::Image] additional manipulations to perform # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#173 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#175 def resize_to_fit(width, height); end # Resize the image per the provided geometry string. @@ -1064,7 +1120,7 @@ module CarrierWave::RMagick # # [Magick::Image] additional manipulations to perform # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#256 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#252 def resize_to_geometry_string(geometry_string); end # Resize the image to fit within the specified dimensions while retaining @@ -1081,7 +1137,7 @@ module CarrierWave::RMagick # # [Magick::Image] additional manipulations to perform # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#142 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#144 def resize_to_limit(width, height); end # Returns the width of the image. @@ -1090,46 +1146,46 @@ module CarrierWave::RMagick # # [Integer] the image's width in pixels # - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#274 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#270 def width; end private - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#379 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#375 def create_info_block(options); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#392 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#388 def destroy_image(image); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#396 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#392 def dimension_from(value); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#401 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#397 def rmagick_image; end end -# source://carrierwave//lib/carrierwave/processing/rmagick.rb#79 +# source://carrierwave//lib/carrierwave/processing/rmagick.rb#81 module CarrierWave::RMagick::ClassMethods - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#80 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#82 def convert(format); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#96 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#98 def resize_and_pad(width, height, background = T.unsafe(nil), gravity = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#92 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#94 def resize_to_fill(width, height, gravity = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#88 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#90 def resize_to_fit(width, height); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#100 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#102 def resize_to_geometry_string(geometry_string); end - # source://carrierwave//lib/carrierwave/processing/rmagick.rb#84 + # source://carrierwave//lib/carrierwave/processing/rmagick.rb#86 def resize_to_limit(width, height); end end -# source://carrierwave//lib/carrierwave.rb#60 +# source://carrierwave//lib/carrierwave.rb#51 class CarrierWave::Railtie < ::Rails::Railtie; end # SanitizedFile is a base class which provides a common API around all @@ -1139,30 +1195,22 @@ class CarrierWave::Railtie < ::Rails::Railtie; end # # It's probably needlessly comprehensive and complex. Help is appreciated. # -# source://carrierwave//lib/carrierwave/sanitized_file.rb#16 +# source://carrierwave//lib/carrierwave/sanitized_file.rb#15 class CarrierWave::SanitizedFile + include ::CarrierWave::Utilities::FileName + # @return [SanitizedFile] a new instance of SanitizedFile # # source://carrierwave//lib/carrierwave/sanitized_file.rb#28 def initialize(file); end - # Returns the part of the filename before the extension. So if a file is called 'test.jpeg' - # this would return 'test' - # - # === Returns - # - # [String] the first part of the filename - # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#70 - def basename; end - # Returns the content type of the file. # # === Returns # # [String] the content type of the file # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#261 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#241 def content_type; end # Sets the content type of the file. @@ -1171,12 +1219,12 @@ class CarrierWave::SanitizedFile # # [String] the content type of the file # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#275 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#256 def content_type=(type); end # Helper to create copy of file in new path. # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#227 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#207 def copy!(new_path); end # Creates a copy of this file and moves it to the given path. Returns the copy. @@ -1191,12 +1239,12 @@ class CarrierWave::SanitizedFile # # @return [CarrierWave::SanitizedFile] the location where the file will be stored. # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#214 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#194 def copy_to(new_path, permissions = T.unsafe(nil), directory_permissions = T.unsafe(nil)); end # Removes the file from the filesystem. # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#238 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#218 def delete; end # === Returns @@ -1205,7 +1253,7 @@ class CarrierWave::SanitizedFile # # @return [Boolean] # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#134 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#111 def empty?; end # === Returns @@ -1214,18 +1262,9 @@ class CarrierWave::SanitizedFile # # @return [Boolean] # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#143 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#120 def exists?; end - # Returns the file extension - # - # === Returns - # - # [String] the extension - # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#81 - def extension; end - # Returns the value of attribute file. # # source://carrierwave//lib/carrierwave/sanitized_file.rb#18 @@ -1255,12 +1294,12 @@ class CarrierWave::SanitizedFile # # @return [Boolean] # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#125 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#102 def is_path?; end # Helper to move file to new path. # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#193 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#173 def move!(new_path); end # Moves the file to the given path @@ -1271,7 +1310,7 @@ class CarrierWave::SanitizedFile # [permissions (Integer)] permissions to set on the file in its new location. # [directory_permissions (Integer)] permissions to set on created directories. # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#176 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#159 def move_to(new_path, permissions = T.unsafe(nil), directory_permissions = T.unsafe(nil), keep_filename = T.unsafe(nil)); end # Returns the filename as is, without sanitizing it. @@ -1289,7 +1328,7 @@ class CarrierWave::SanitizedFile # # [String, nil] the path where the file is located. # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#111 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#88 def path; end # Returns the contents of the file. @@ -1298,8 +1337,8 @@ class CarrierWave::SanitizedFile # # [String] contents of the file # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#154 - def read; end + # source://carrierwave//lib/carrierwave/sanitized_file.rb#131 + def read(*args); end # Used to sanitize the file name. Public to allow overriding for non-latin characters. # @@ -1307,7 +1346,7 @@ class CarrierWave::SanitizedFile # # [Regexp] the regexp for sanitizing the file name # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#286 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#267 def sanitize_regexp; end # Returns the file's size. @@ -1316,7 +1355,7 @@ class CarrierWave::SanitizedFile # # [Integer] the file's size in bytes. # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#92 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#69 def size; end # Returns a File object, or nil if it does not exist. @@ -1325,38 +1364,40 @@ class CarrierWave::SanitizedFile # # [File] a File object representing the SanitizedFile # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#249 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#229 def to_file; end private - # source://carrierwave//lib/carrierwave/sanitized_file.rb#311 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#292 def chmod!(path, permissions); end - # source://carrierwave//lib/carrierwave/sanitized_file.rb#325 - def existing_content_type; end + # source://carrierwave//lib/carrierwave/sanitized_file.rb#307 + def declared_content_type; end - # source://carrierwave//lib/carrierwave/sanitized_file.rb#292 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#273 def file=(file); end - # source://carrierwave//lib/carrierwave/sanitized_file.rb#331 - def marcel_magic_content_type; end + # Guess content type from its file extension. Limit what to be returned to prevent spoofing. + # + # source://carrierwave//lib/carrierwave/sanitized_file.rb#315 + def guessed_safe_content_type; end - # source://carrierwave//lib/carrierwave/sanitized_file.rb#348 - def mini_mime_content_type; end + # source://carrierwave//lib/carrierwave/sanitized_file.rb#322 + def identified_content_type; end # create the directory if it doesn't exist # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#305 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#286 def mkdir!(path, directory_permissions); end # Sanitize the filename, to prevent hacking # - # source://carrierwave//lib/carrierwave/sanitized_file.rb#316 + # source://carrierwave//lib/carrierwave/sanitized_file.rb#297 def sanitize(name); end - # source://carrierwave//lib/carrierwave/sanitized_file.rb#354 - def split_extension(filename); end + # source://carrierwave//lib/carrierwave/sanitized_file.rb#330 + def with_io(&block); end class << self # source://carrierwave//lib/carrierwave/sanitized_file.rb#23 @@ -1481,7 +1522,7 @@ class CarrierWave::Storage::File < ::CarrierWave::Storage::Abstract # # By default, store!() uses copy_to(), which operates by copying the file # from the cache to the store, then deleting the file from the cache. - # If move_to_store() is overriden to return true, then store!() uses move_to(), + # If move_to_store() is overridden to return true, then store!() uses move_to(), # which simply moves the file from cache to store. Useful for large files. # # === Parameters @@ -1626,10 +1667,11 @@ end # source://carrierwave//lib/carrierwave/storage/fog.rb#164 class CarrierWave::Storage::Fog::File include ::CarrierWave::Utilities::Uri + include ::CarrierWave::Utilities::FileName # @return [File] a new instance of File # - # source://carrierwave//lib/carrierwave/storage/fog.rb#288 + # source://carrierwave//lib/carrierwave/storage/fog.rb#277 def initialize(uploader, base, path); end # Return all attributes from file @@ -1638,7 +1680,7 @@ class CarrierWave::Storage::Fog::File # # [Hash] attributes from file # - # source://carrierwave//lib/carrierwave/storage/fog.rb#185 + # source://carrierwave//lib/carrierwave/storage/fog.rb#186 def attributes; end # Return a temporary authenticated url to a private file, if available @@ -1650,7 +1692,7 @@ class CarrierWave::Storage::Fog::File # or # [NilClass] no authenticated url available # - # source://carrierwave//lib/carrierwave/storage/fog.rb#199 + # source://carrierwave//lib/carrierwave/storage/fog.rb#200 def authenticated_url(options = T.unsafe(nil)); end # Lookup value for file content-type header @@ -1659,7 +1701,7 @@ class CarrierWave::Storage::Fog::File # # [String] value of content-type # - # source://carrierwave//lib/carrierwave/storage/fog.rb#232 + # source://carrierwave//lib/carrierwave/storage/fog.rb#233 def content_type; end # Set non-default content-type header (default is file.content_type) @@ -1668,7 +1710,7 @@ class CarrierWave::Storage::Fog::File # # [String] returns new content type value # - # source://carrierwave//lib/carrierwave/storage/fog.rb#243 + # source://carrierwave//lib/carrierwave/storage/fog.rb#244 def content_type=(new_content_type); end # Creates a copy of this file and returns it. @@ -1681,7 +1723,7 @@ class CarrierWave::Storage::Fog::File # # @return [CarrierWave::Storage::Fog::File] the location where the file will be stored. # - # source://carrierwave//lib/carrierwave/storage/fog.rb#453 + # source://carrierwave//lib/carrierwave/storage/fog.rb#443 def copy_to(new_path); end # Remove the file from service @@ -1690,7 +1732,7 @@ class CarrierWave::Storage::Fog::File # # [Boolean] true for success or raises error # - # source://carrierwave//lib/carrierwave/storage/fog.rb#254 + # source://carrierwave//lib/carrierwave/storage/fog.rb#255 def delete; end # Check if the file exists on the remote service @@ -1701,18 +1743,9 @@ class CarrierWave::Storage::Fog::File # # @return [Boolean] # - # source://carrierwave//lib/carrierwave/storage/fog.rb#329 + # source://carrierwave//lib/carrierwave/storage/fog.rb#318 def exists?; end - # Return extension of file - # - # === Returns - # - # [String] extension of file or nil if the file has no extension - # - # source://carrierwave//lib/carrierwave/storage/fog.rb#268 - def extension; end - # Return file name, if available # # === Returns @@ -1721,7 +1754,7 @@ class CarrierWave::Storage::Fog::File # or # [NilClass] no file name available # - # source://carrierwave//lib/carrierwave/storage/fog.rb#437 + # source://carrierwave//lib/carrierwave/storage/fog.rb#427 def filename(options = T.unsafe(nil)); end # deprecated: All attributes from file (includes headers) @@ -1730,7 +1763,7 @@ class CarrierWave::Storage::Fog::File # # [Hash] attributes from file # - # source://carrierwave//lib/carrierwave/storage/fog.rb#280 + # source://carrierwave//lib/carrierwave/storage/fog.rb#269 def headers; end # Current local path to file @@ -1739,7 +1772,7 @@ class CarrierWave::Storage::Fog::File # # [String] a path to file # - # source://carrierwave//lib/carrierwave/storage/fog.rb#176 + # source://carrierwave//lib/carrierwave/storage/fog.rb#177 def path; end # Return a url to a public file, if available @@ -1750,7 +1783,7 @@ class CarrierWave::Storage::Fog::File # or # [NilClass] no public url available # - # source://carrierwave//lib/carrierwave/storage/fog.rb#365 + # source://carrierwave//lib/carrierwave/storage/fog.rb#354 def public_url; end # Read content of file from service @@ -1759,7 +1792,7 @@ class CarrierWave::Storage::Fog::File # # [String] contents of file # - # source://carrierwave//lib/carrierwave/storage/fog.rb#298 + # source://carrierwave//lib/carrierwave/storage/fog.rb#287 def read; end # Return size of file body @@ -1768,7 +1801,7 @@ class CarrierWave::Storage::Fog::File # # [Integer] size of file body # - # source://carrierwave//lib/carrierwave/storage/fog.rb#319 + # source://carrierwave//lib/carrierwave/storage/fog.rb#308 def size; end # Write file to service @@ -1777,10 +1810,21 @@ class CarrierWave::Storage::Fog::File # # [Boolean] true on success or raises error # - # source://carrierwave//lib/carrierwave/storage/fog.rb#339 + # source://carrierwave//lib/carrierwave/storage/fog.rb#328 def store(new_file); end - # Return url to file, if avaliable + # Return the local file + # + # === Returns + # + # [File] The local file as Ruby's File class + # or + # [NilClass] When there's no file, or the file is remotely stored + # + # source://carrierwave//lib/carrierwave/storage/fog.rb#457 + def to_file; end + + # Return url to file, if available # # === Returns # @@ -1788,12 +1832,12 @@ class CarrierWave::Storage::Fog::File # or # [NilClass] no url available # - # source://carrierwave//lib/carrierwave/storage/fog.rb#420 + # source://carrierwave//lib/carrierwave/storage/fog.rb#410 def url(options = T.unsafe(nil)); end private - # source://carrierwave//lib/carrierwave/storage/fog.rb#505 + # source://carrierwave//lib/carrierwave/storage/fog.rb#512 def acl_header; end # connection to service @@ -1802,10 +1846,10 @@ class CarrierWave::Storage::Fog::File # # [Fog::#{provider}::Storage] connection to service # - # source://carrierwave//lib/carrierwave/storage/fog.rb#467 + # source://carrierwave//lib/carrierwave/storage/fog.rb#476 def connection; end - # source://carrierwave//lib/carrierwave/storage/fog.rb#498 + # source://carrierwave//lib/carrierwave/storage/fog.rb#505 def copy_options; end # local reference to directory containing file @@ -1814,7 +1858,7 @@ class CarrierWave::Storage::Fog::File # # [Fog::#{provider}::Directory] containing directory # - # source://carrierwave//lib/carrierwave/storage/fog.rb#478 + # source://carrierwave//lib/carrierwave/storage/fog.rb#487 def directory; end # lookup file @@ -1823,18 +1867,18 @@ class CarrierWave::Storage::Fog::File # # [Fog::#{provider}::File] file data from remote service # - # source://carrierwave//lib/carrierwave/storage/fog.rb#494 + # source://carrierwave//lib/carrierwave/storage/fog.rb#501 def file; end - # source://carrierwave//lib/carrierwave/storage/fog.rb#515 + # source://carrierwave//lib/carrierwave/storage/fog.rb#523 def fog_provider; end - # source://carrierwave//lib/carrierwave/storage/fog.rb#519 - def read_source_file(file_body); end + # source://carrierwave//lib/carrierwave/storage/fog.rb#527 + def read_source_file; end # @return [Boolean] # - # source://carrierwave//lib/carrierwave/storage/fog.rb#530 + # source://carrierwave//lib/carrierwave/storage/fog.rb#538 def url_options_supported?(local_file); end end @@ -2158,47 +2202,47 @@ class CarrierWave::Test::Matchers::ImageLoader end end -# source://carrierwave//lib/carrierwave/test/matchers.rb#354 +# source://carrierwave//lib/carrierwave/test/matchers.rb#356 class CarrierWave::Test::Matchers::MagickWrapper # @return [MagickWrapper] a new instance of MagickWrapper # - # source://carrierwave//lib/carrierwave/test/matchers.rb#368 + # source://carrierwave//lib/carrierwave/test/matchers.rb#371 def initialize(filename); end - # source://carrierwave//lib/carrierwave/test/matchers.rb#364 + # source://carrierwave//lib/carrierwave/test/matchers.rb#367 def format; end - # source://carrierwave//lib/carrierwave/test/matchers.rb#360 + # source://carrierwave//lib/carrierwave/test/matchers.rb#363 def height; end # Returns the value of attribute image. # - # source://carrierwave//lib/carrierwave/test/matchers.rb#355 + # source://carrierwave//lib/carrierwave/test/matchers.rb#357 def image; end - # source://carrierwave//lib/carrierwave/test/matchers.rb#356 + # source://carrierwave//lib/carrierwave/test/matchers.rb#359 def width; end end -# source://carrierwave//lib/carrierwave/test/matchers.rb#373 +# source://carrierwave//lib/carrierwave/test/matchers.rb#376 class CarrierWave::Test::Matchers::MiniMagickWrapper # @return [MiniMagickWrapper] a new instance of MiniMagickWrapper # - # source://carrierwave//lib/carrierwave/test/matchers.rb#387 + # source://carrierwave//lib/carrierwave/test/matchers.rb#391 def initialize(filename); end - # source://carrierwave//lib/carrierwave/test/matchers.rb#383 + # source://carrierwave//lib/carrierwave/test/matchers.rb#387 def format; end - # source://carrierwave//lib/carrierwave/test/matchers.rb#379 + # source://carrierwave//lib/carrierwave/test/matchers.rb#383 def height; end # Returns the value of attribute image. # - # source://carrierwave//lib/carrierwave/test/matchers.rb#374 + # source://carrierwave//lib/carrierwave/test/matchers.rb#377 def image; end - # source://carrierwave//lib/carrierwave/test/matchers.rb#375 + # source://carrierwave//lib/carrierwave/test/matchers.rb#379 def width; end end @@ -2227,7 +2271,7 @@ module CarrierWave::Uploader; end # these are *very* simple (they are only a dozen lines of code), so adding your own should # be trivial. # -# source://carrierwave//lib/carrierwave/uploader.rb#43 +# source://carrierwave//lib/carrierwave/uploader.rb#44 class CarrierWave::Uploader::Base include ::CarrierWave::Uploader::Configuration include ::CarrierWave::Uploader::Callbacks @@ -2239,11 +2283,12 @@ class CarrierWave::Uploader::Base include ::CarrierWave::Uploader::Store include ::CarrierWave::Uploader::Download include ::CarrierWave::Uploader::Remove - include ::CarrierWave::Uploader::ExtensionWhitelist - include ::CarrierWave::Uploader::ExtensionBlacklist - include ::CarrierWave::Uploader::ContentTypeWhitelist - include ::CarrierWave::Uploader::ContentTypeBlacklist + include ::CarrierWave::Uploader::ExtensionAllowlist + include ::CarrierWave::Uploader::ExtensionDenylist + include ::CarrierWave::Uploader::ContentTypeAllowlist + include ::CarrierWave::Uploader::ContentTypeDenylist include ::CarrierWave::Uploader::FileSize + include ::CarrierWave::Uploader::Dimension include ::CarrierWave::Uploader::Processing include ::CarrierWave::Uploader::Versions include ::CarrierWave::Uploader::DefaultUrl @@ -2278,165 +2323,177 @@ class CarrierWave::Uploader::Base # source://carrierwave//lib/carrierwave/uploader/configuration.rb#10 def _storage?; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def asset_host; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def asset_host=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def base_path; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def base_path=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def cache_dir; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def cache_dir=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def cache_only; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def cache_only=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def delete_tmp_file_after_storage; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def delete_tmp_file_after_storage=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def directory_permissions; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def directory_permissions=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 + def download_retry_count; end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 + def download_retry_count=(value); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 + def download_retry_wait_time; end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 + def download_retry_wait_time=(value); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def downloader; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def downloader=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def enable_processing; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def enable_processing=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def ensure_multipart_form; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def ensure_multipart_form=(value); end # Returns the value of attribute file. # - # source://carrierwave//lib/carrierwave/uploader.rb#44 + # source://carrierwave//lib/carrierwave/uploader.rb#45 def file; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def fog_attributes; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def fog_attributes=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def fog_authenticated_url_expiration; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def fog_authenticated_url_expiration=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def fog_aws_accelerate; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def fog_aws_accelerate=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def fog_credentials; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def fog_credentials=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def fog_directory; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def fog_directory=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#167 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#170 def fog_provider; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#163 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#166 def fog_provider=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def fog_public; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def fog_public=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def fog_use_ssl_for_aws; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def fog_use_ssl_for_aws=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 + def force_extension; end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 + def force_extension=(value); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def ignore_download_errors; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def ignore_download_errors=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def ignore_integrity_errors; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def ignore_integrity_errors=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def ignore_processing_errors; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def ignore_processing_errors=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def mount_on; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def mount_on=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def move_to_cache; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def move_to_cache=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def move_to_store; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def move_to_store=(value); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#14 - def parent_cache_id; end - - # source://carrierwave//lib/carrierwave/uploader/versions.rb#14 - def parent_cache_id=(_arg0); end - - # source://carrierwave//lib/carrierwave/uploader/versions.rb#14 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#97 def parent_version; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#14 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#97 def parent_version=(_arg0); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def permissions; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def permissions=(value); end # source://carrierwave//lib/carrierwave/uploader/processing.rb#9 @@ -2445,52 +2502,52 @@ class CarrierWave::Uploader::Base # source://carrierwave//lib/carrierwave/uploader/processing.rb#9 def processors?; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def remove_previously_stored_files_after_update; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def remove_previously_stored_files_after_update=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def root; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def root=(value); end - # source://carrierwave//lib/carrierwave/uploader/cache.rb#48 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#49 def staged; end - # source://carrierwave//lib/carrierwave/uploader/cache.rb#48 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#49 def staged=(_arg0); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def storage_engines; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def storage_engines=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def store_dir; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def store_dir=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def validate_download; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def validate_download=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def validate_integrity; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def validate_integrity=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#141 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#144 def validate_processing; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#137 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#140 def validate_processing=(value); end class << self @@ -2530,148 +2587,166 @@ class CarrierWave::Uploader::Base # source://carrierwave//lib/carrierwave/uploader/configuration.rb#10 def _storage?; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def asset_host(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def asset_host=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def base_path(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def base_path=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def cache_dir(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def cache_dir=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def cache_only(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def cache_only=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def delete_tmp_file_after_storage(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def delete_tmp_file_after_storage=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def directory_permissions(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def directory_permissions=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 + def download_retry_count(value = T.unsafe(nil)); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 + def download_retry_count=(value); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 + def download_retry_wait_time(value = T.unsafe(nil)); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 + def download_retry_wait_time=(value); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def downloader(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def downloader=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def enable_processing(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def enable_processing=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def ensure_multipart_form(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def ensure_multipart_form=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def fog_attributes(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def fog_attributes=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def fog_authenticated_url_expiration(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def fog_authenticated_url_expiration=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def fog_aws_accelerate(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def fog_aws_accelerate=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def fog_credentials(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def fog_credentials=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def fog_directory(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def fog_directory=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#155 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#158 def fog_provider(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#159 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#162 def fog_provider=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def fog_public(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def fog_public=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def fog_use_ssl_for_aws(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def fog_use_ssl_for_aws=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 + def force_extension(value = T.unsafe(nil)); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 + def force_extension=(value); end + + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def ignore_download_errors(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def ignore_download_errors=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def ignore_integrity_errors(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def ignore_integrity_errors=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def ignore_processing_errors(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def ignore_processing_errors=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def mount_on(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def mount_on=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def move_to_cache(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def move_to_cache=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def move_to_store(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def move_to_store=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def permissions(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def permissions=(value); end # source://carrierwave//lib/carrierwave/uploader/processing.rb#9 @@ -2683,78 +2758,78 @@ class CarrierWave::Uploader::Base # source://carrierwave//lib/carrierwave/uploader/processing.rb#9 def processors?; end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def remove_previously_stored_files_after_update(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def remove_previously_stored_files_after_update=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def root(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def root=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def storage_engines(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def storage_engines=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def store_dir(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def store_dir=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def validate_download(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def validate_download=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def validate_integrity(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def validate_integrity=(value); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#125 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#128 def validate_processing(value = T.unsafe(nil)); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#133 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#136 def validate_processing=(value); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def version_names; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def version_names=(value); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def version_names?; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def version_options; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def version_options=(value); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def version_options?; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def versions; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def versions=(value); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#9 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#92 def versions?; end end end -# source://carrierwave//lib/carrierwave/uploader/cache.rb#35 +# source://carrierwave//lib/carrierwave/uploader/cache.rb#36 module CarrierWave::Uploader::Cache extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -2770,7 +2845,7 @@ module CarrierWave::Uploader::Cache # # By default, cache!() uses copy_to(), which operates by copying the file # to the cache, then deleting the original file. If move_to_cache() is - # overriden to return true, then cache!() uses move_to(), which simply + # overridden to return true, then cache!() uses move_to(), which simply # moves the file to the cache. Useful for large files. # # === Parameters @@ -2783,7 +2858,7 @@ module CarrierWave::Uploader::Cache # # @raise [CarrierWave::FormNotMultipart] # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#124 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#125 def cache!(new_file = T.unsafe(nil)); end # Returns a String which uniquely identifies the currently cached file for later retrieval @@ -2792,7 +2867,7 @@ module CarrierWave::Uploader::Cache # # [String] a cache name, in the format TIMEINT-PID-COUNTER-RND/filename.txt # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#104 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#105 def cache_name; end # Calculates the path where the cache file should be stored. @@ -2805,7 +2880,7 @@ module CarrierWave::Uploader::Cache # # [String] the cache path # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#183 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#185 def cache_path(for_file = T.unsafe(nil)); end # Caches the remotely stored file @@ -2813,7 +2888,7 @@ module CarrierWave::Uploader::Cache # This is useful when about to process images. Most processing solutions # require the file to be stored on the local filesystem. # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#88 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#89 def cache_stored_file!; end # Returns true if the uploader has been cached @@ -2824,7 +2899,7 @@ module CarrierWave::Uploader::Cache # # @return [Boolean] # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#78 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#79 def cached?; end # Retrieves the file with the given cache_name from the cache. @@ -2837,42 +2912,45 @@ module CarrierWave::Uploader::Cache # # [CarrierWave::InvalidParameter] if the cache_name is incorrectly formatted. # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#163 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#165 def retrieve_from_cache!(cache_name); end - # source://carrierwave//lib/carrierwave/uploader/cache.rb#92 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#93 def sanitized_file; end - private + protected # Returns the value of attribute cache_id. # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#193 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#191 def cache_id; end + private + # @raise [CarrierWave::InvalidParameter] # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#198 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#201 def cache_id=(cache_id); end - # source://carrierwave//lib/carrierwave/uploader/cache.rb#210 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#213 def cache_storage; end - # Returns the value of attribute original_filename. # We can override the full_original_filename method in other modules + # + # source://carrierwave//lib/carrierwave/uploader/cache.rb#218 def full_original_filename; end # Returns the value of attribute original_filename. # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#193 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#199 def original_filename; end # @raise [CarrierWave::InvalidParameter] # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#205 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#208 def original_filename=(filename); end - # source://carrierwave//lib/carrierwave/uploader/cache.rb#189 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#195 def workfile_path(for_file = T.unsafe(nil)); end module GeneratedClassMethods @@ -2902,7 +2980,7 @@ module CarrierWave::Uploader::Cache end end -# source://carrierwave//lib/carrierwave/uploader/cache.rb#51 +# source://carrierwave//lib/carrierwave/uploader/cache.rb#52 module CarrierWave::Uploader::Cache::ClassMethods # Removes cached files which are older than one day. You could call this method # from a rake task to clean out old cached files. @@ -2916,7 +2994,7 @@ module CarrierWave::Uploader::Cache::ClassMethods # This only works as long as you haven't done anything funky with your cache_dir. # It's recommended that you keep cache files in one place only. # - # source://carrierwave//lib/carrierwave/uploader/cache.rb#66 + # source://carrierwave//lib/carrierwave/uploader/cache.rb#67 def clean_cached_files!(seconds = T.unsafe(nil)); end end @@ -2982,12 +3060,12 @@ module CarrierWave::Uploader::Configuration end end -# source://carrierwave//lib/carrierwave/uploader/configuration.rb#52 +# source://carrierwave//lib/carrierwave/uploader/configuration.rb#55 module CarrierWave::Uploader::Configuration::ClassMethods - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#121 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#124 def add_config(name); end - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#153 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#156 def add_deprecated_config(name); end # Sets the cache storage engine to be used when storing cache files with this uploader. @@ -3008,7 +3086,7 @@ module CarrierWave::Uploader::Configuration::ClassMethods # cache_storage CarrierWave::Storage::File # cache_storage MyCustomStorageEngine # - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#113 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#116 def cache_storage(storage = T.unsafe(nil)); end # Sets the cache storage engine to be used when storing cache files with this uploader. @@ -3029,18 +3107,18 @@ module CarrierWave::Uploader::Configuration::ClassMethods # cache_storage CarrierWave::Storage::File # cache_storage MyCustomStorageEngine # - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#113 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#116 def cache_storage=(storage = T.unsafe(nil)); end # @yield [_self] # @yieldparam _self [CarrierWave::Uploader::Configuration::ClassMethods] the object that the method was called on # - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#173 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#176 def configure; end # sets configuration back to default # - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#180 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#183 def reset_config; end # Sets the storage engine to be used when storing files with this uploader. @@ -3065,7 +3143,7 @@ module CarrierWave::Uploader::Configuration::ClassMethods # storage CarrierWave::Storage::File # storage MyCustomStorageEngine # - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#77 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#80 def storage(storage = T.unsafe(nil)); end # Sets the storage engine to be used when storing files with this uploader. @@ -3090,84 +3168,84 @@ module CarrierWave::Uploader::Configuration::ClassMethods # storage CarrierWave::Storage::File # storage MyCustomStorageEngine # - # source://carrierwave//lib/carrierwave/uploader/configuration.rb#77 + # source://carrierwave//lib/carrierwave/uploader/configuration.rb#80 def storage=(storage = T.unsafe(nil)); end end -# source://carrierwave//lib/carrierwave/uploader/content_type_blacklist.rb#3 -module CarrierWave::Uploader::ContentTypeBlacklist +# source://carrierwave//lib/carrierwave/uploader/content_type_allowlist.rb#3 +module CarrierWave::Uploader::ContentTypeAllowlist extend ::ActiveSupport::Concern - # Override this method in your uploader to provide a denylist of files content types - # which are not allowed to be uploaded. + # Override this method in your uploader to provide an allowlist of files content types + # which are allowed to be uploaded. # Not only strings but Regexp are allowed as well. # # === Returns # - # [NilClass, String, Regexp, Array[String, Regexp]] a denylist of content types which are not allowed to be uploaded + # [NilClass, String, Regexp, Array[String, Regexp]] an allowlist of content types which are allowed to be uploaded # # === Examples # - # def content_type_denylist + # def content_type_allowlist # %w(text/json application/json) # end # # Basically the same, but using a Regexp: # - # def content_type_denylist + # def content_type_allowlist # [/(text|application)\/json/] # end # - # source://carrierwave//lib/carrierwave/uploader/content_type_blacklist.rb#31 - def content_type_denylist; end + # source://carrierwave//lib/carrierwave/uploader/content_type_allowlist.rb#31 + def content_type_allowlist; end private # @return [Boolean] # - # source://carrierwave//lib/carrierwave/uploader/content_type_blacklist.rb#51 - def blacklisted_content_type?(content_type); end + # source://carrierwave//lib/carrierwave/uploader/content_type_allowlist.rb#53 + def allowlisted_content_type?(allowlist, content_type); end - # source://carrierwave//lib/carrierwave/uploader/content_type_blacklist.rb#41 - def check_content_type_blacklist!(new_file); end + # source://carrierwave//lib/carrierwave/uploader/content_type_allowlist.rb#36 + def check_content_type_allowlist!(new_file); end end -# source://carrierwave//lib/carrierwave/uploader/content_type_whitelist.rb#3 -module CarrierWave::Uploader::ContentTypeWhitelist +# source://carrierwave//lib/carrierwave/uploader/content_type_denylist.rb#3 +module CarrierWave::Uploader::ContentTypeDenylist extend ::ActiveSupport::Concern - # Override this method in your uploader to provide an allowlist of files content types - # which are allowed to be uploaded. + # Override this method in your uploader to provide a denylist of files content types + # which are not allowed to be uploaded. # Not only strings but Regexp are allowed as well. # # === Returns # - # [NilClass, String, Regexp, Array[String, Regexp]] an allowlist of content types which are allowed to be uploaded + # [NilClass, String, Regexp, Array[String, Regexp]] a denylist of content types which are not allowed to be uploaded # # === Examples # - # def content_type_allowlist + # def content_type_denylist # %w(text/json application/json) # end # # Basically the same, but using a Regexp: # - # def content_type_allowlist + # def content_type_denylist # [/(text|application)\/json/] # end # - # source://carrierwave//lib/carrierwave/uploader/content_type_whitelist.rb#31 - def content_type_allowlist; end + # source://carrierwave//lib/carrierwave/uploader/content_type_denylist.rb#31 + def content_type_denylist; end private - # source://carrierwave//lib/carrierwave/uploader/content_type_whitelist.rb#41 - def check_content_type_whitelist!(new_file); end + # source://carrierwave//lib/carrierwave/uploader/content_type_denylist.rb#36 + def check_content_type_denylist!(new_file); end # @return [Boolean] # - # source://carrierwave//lib/carrierwave/uploader/content_type_whitelist.rb#51 - def whitelisted_content_type?(content_type); end + # source://carrierwave//lib/carrierwave/uploader/content_type_denylist.rb#56 + def denylisted_content_type?(denylist, content_type); end end # source://carrierwave//lib/carrierwave/uploader/default_url.rb#3 @@ -3182,6 +3260,46 @@ module CarrierWave::Uploader::DefaultUrl def url(*args); end end +# source://carrierwave//lib/carrierwave/uploader/dimension.rb#5 +module CarrierWave::Uploader::Dimension + extend ::ActiveSupport::Concern + + # Override this method in your uploader to provide a Range of height which + # are allowed to be uploaded. + # === Returns + # + # [NilClass, Range] a height range which are permitted to be uploaded + # + # === Examples + # + # def height_range + # 1000.. + # end + # + # source://carrierwave//lib/carrierwave/uploader/dimension.rb#40 + def height_range; end + + # Override this method in your uploader to provide a Range of width which + # are allowed to be uploaded. + # === Returns + # + # [NilClass, Range] a width range which are permitted to be uploaded + # + # === Examples + # + # def width_range + # 1000..2000 + # end + # + # source://carrierwave//lib/carrierwave/uploader/dimension.rb#25 + def width_range; end + + private + + # source://carrierwave//lib/carrierwave/uploader/dimension.rb#44 + def check_dimensions!(new_file); end +end + # source://carrierwave//lib/carrierwave/uploader/download.rb#3 module CarrierWave::Uploader::Download extend ::ActiveSupport::Concern @@ -3232,77 +3350,77 @@ module CarrierWave::Uploader::Download end end -# source://carrierwave//lib/carrierwave/uploader/extension_blacklist.rb#3 -module CarrierWave::Uploader::ExtensionBlacklist +# source://carrierwave//lib/carrierwave/uploader/extension_allowlist.rb#3 +module CarrierWave::Uploader::ExtensionAllowlist extend ::ActiveSupport::Concern - # [NilClass, String, Regexp, Array[String, Regexp]] a deny list of extensions which are prohibited to be uploaded + # Override this method in your uploader to provide an allowlist of extensions which + # are allowed to be uploaded. Compares the file's extension case insensitive. + # Furthermore, not only strings but Regexp are allowed as well. + # + # When using a Regexp in the allowlist, `\A` and `\z` are automatically added to + # the Regexp expression, also case insensitive. + # + # === Returns + # + # [NilClass, String, Regexp, Array[String, Regexp]] an allowlist of extensions which are allowed to be uploaded # # === Examples # - # def extension_denylist - # %w(swf tiff) + # def extension_allowlist + # %w(jpg jpeg gif png) # end # # Basically the same, but using a Regexp: # - # def extension_denylist - # [/swf/, 'tiff'] + # def extension_allowlist + # [/jpe?g/, 'gif', 'png'] # end # - # source://carrierwave//lib/carrierwave/uploader/extension_blacklist.rb#34 - def extension_denylist; end + # source://carrierwave//lib/carrierwave/uploader/extension_allowlist.rb#34 + def extension_allowlist; end private # @return [Boolean] # - # source://carrierwave//lib/carrierwave/uploader/extension_blacklist.rb#54 - def blacklisted_extension?(extension); end + # source://carrierwave//lib/carrierwave/uploader/extension_allowlist.rb#57 + def allowlisted_extension?(allowlist, extension); end - # source://carrierwave//lib/carrierwave/uploader/extension_blacklist.rb#44 - def check_extension_blacklist!(new_file); end + # source://carrierwave//lib/carrierwave/uploader/extension_allowlist.rb#39 + def check_extension_allowlist!(new_file); end end -# source://carrierwave//lib/carrierwave/uploader/extension_whitelist.rb#3 -module CarrierWave::Uploader::ExtensionWhitelist +# source://carrierwave//lib/carrierwave/uploader/extension_denylist.rb#3 +module CarrierWave::Uploader::ExtensionDenylist extend ::ActiveSupport::Concern - # Override this method in your uploader to provide an allowlist of extensions which - # are allowed to be uploaded. Compares the file's extension case insensitive. - # Furthermore, not only strings but Regexp are allowed as well. - # - # When using a Regexp in the allowlist, `\A` and `\z` are automatically added to - # the Regexp expression, also case insensitive. - # - # === Returns - # - # [NilClass, String, Regexp, Array[String, Regexp]] an allowlist of extensions which are allowed to be uploaded + # [NilClass, String, Regexp, Array[String, Regexp]] a deny list of extensions which are prohibited to be uploaded # # === Examples # - # def extension_allowlist - # %w(jpg jpeg gif png) + # def extension_denylist + # %w(swf tiff) # end # # Basically the same, but using a Regexp: # - # def extension_allowlist - # [/jpe?g/, 'gif', 'png'] + # def extension_denylist + # [/swf/, 'tiff'] # end # - # source://carrierwave//lib/carrierwave/uploader/extension_whitelist.rb#34 - def extension_allowlist; end + # source://carrierwave//lib/carrierwave/uploader/extension_denylist.rb#34 + def extension_denylist; end private - # source://carrierwave//lib/carrierwave/uploader/extension_whitelist.rb#44 - def check_extension_whitelist!(new_file); end + # source://carrierwave//lib/carrierwave/uploader/extension_denylist.rb#39 + def check_extension_denylist!(new_file); end # @return [Boolean] # - # source://carrierwave//lib/carrierwave/uploader/extension_whitelist.rb#55 - def whitelisted_extension?(extension); end + # source://carrierwave//lib/carrierwave/uploader/extension_denylist.rb#59 + def denylisted_extension?(denylist, extension); end end # source://carrierwave//lib/carrierwave/uploader/file_size.rb#5 @@ -3313,7 +3431,7 @@ module CarrierWave::Uploader::FileSize # are allowed to be uploaded. # === Returns # - # [NilClass, Range] a size range which are permitted to be uploaded + # [NilClass, Range] a size range (in bytes) which are permitted to be uploaded # # === Examples # @@ -3386,9 +3504,14 @@ module CarrierWave::Uploader::Processing # Apply all process callbacks added through CarrierWave.process # - # source://carrierwave//lib/carrierwave/uploader/processing.rb#71 + # source://carrierwave//lib/carrierwave/uploader/processing.rb#81 def process!(new_file = T.unsafe(nil)); end + private + + # source://carrierwave//lib/carrierwave/uploader/processing.rb#116 + def forcing_extension(filename); end + module GeneratedClassMethods def _after_callbacks; end def _after_callbacks=(value); end @@ -3416,7 +3539,7 @@ module CarrierWave::Uploader::Processing::ClassMethods # Adds a processor callback which applies operations as a file is uploaded. # The argument may be the name of any method of the uploader, expressed as a symbol, # or a list of such methods, or a hash where the key is a method and the value is - # an array of arguments to call the method with + # an array of arguments to call the method with. Also accepts an :if or :unless condition # # === Parameters # @@ -3429,6 +3552,7 @@ module CarrierWave::Uploader::Processing::ClassMethods # process :sepiatone, :vignette # process :scale => [200, 200] # process :scale => [200, 200], :if => :image? + # process :scale => [200, 200], :unless => :disallowed_image_type? # process :sepiatone, :if => :image? # # def sepiatone @@ -3447,9 +3571,13 @@ module CarrierWave::Uploader::Processing::ClassMethods # ... # end # + # def disallowed_image_type? + # ... + # end + # # end # - # source://carrierwave//lib/carrierwave/uploader/processing.rb#54 + # source://carrierwave//lib/carrierwave/uploader/processing.rb#59 def process(*args); end end @@ -3470,7 +3598,7 @@ module CarrierWave::Uploader::Proxy # # [String] content type of the file # - # source://carrierwave//lib/carrierwave/uploader/proxy.rb#80 + # source://carrierwave//lib/carrierwave/uploader/proxy.rb#93 def content_type; end # === Returns @@ -3499,7 +3627,7 @@ module CarrierWave::Uploader::Proxy # # This was added because of the way Rails handles length/size validations in 3.0.6 and above. # - # source://carrierwave//lib/carrierwave/uploader/proxy.rb#69 + # source://carrierwave//lib/carrierwave/uploader/proxy.rb#82 def length; end # === Returns @@ -3515,8 +3643,8 @@ module CarrierWave::Uploader::Proxy # # [String] contents of the file # - # source://carrierwave//lib/carrierwave/uploader/proxy.rb#43 - def read; end + # source://carrierwave//lib/carrierwave/uploader/proxy.rb#56 + def read(*args); end # Fetches the size of the currently stored/cached file # @@ -3524,8 +3652,19 @@ module CarrierWave::Uploader::Proxy # # [Integer] size of the file # - # source://carrierwave//lib/carrierwave/uploader/proxy.rb#54 + # source://carrierwave//lib/carrierwave/uploader/proxy.rb#67 def size; end + + # Returns a String which is to be used as a temporary value which gets assigned to the column. + # The purpose is to mark the column that it will be updated. Finally before the save it will be + # overwritten by the #identifier value, which is usually #filename. + # + # === Returns + # + # [String] a temporary_identifier, by default the value of #cache_name is used + # + # source://carrierwave//lib/carrierwave/uploader/proxy.rb#45 + def temporary_identifier; end end # source://carrierwave//lib/carrierwave/uploader/remove.rb#3 @@ -3589,6 +3728,27 @@ module CarrierWave::Uploader::Store mixes_in_class_methods ::CarrierWave::Uploader::Configuration::ClassMethods mixes_in_class_methods ::CarrierWave::Uploader::Cache::ClassMethods + # Look for an identifier which doesn't collide with the given already-stored identifiers. + # It is done by adding a index number as the suffix. + # For example, if there's 'image.jpg' and the @deduplication_index is set to 2, + # The stored file will be named as 'image(2).jpg'. + # + # === Parameters + # + # [current_identifiers (Array[String])] List of identifiers for already-stored files + # + # source://carrierwave//lib/carrierwave/uploader/store.rb#120 + def deduplicate(current_identifiers); end + + # Returns a filename which doesn't conflict with already-stored files. + # + # === Returns + # + # [String] the filename with suffix added for deduplication + # + # source://carrierwave//lib/carrierwave/uploader/store.rb#44 + def deduplicated_filename; end + # Override this in your Uploader to change the filename. # # Be careful using record ids as filenames. If the filename is stored in the database @@ -3611,7 +3771,7 @@ module CarrierWave::Uploader::Store # # [identifier (String)] uniquely identifies the file to retrieve # - # source://carrierwave//lib/carrierwave/uploader/store.rb#85 + # source://carrierwave//lib/carrierwave/uploader/store.rb#103 def retrieve_from_store!(identifier); end # Stores the file by passing it to this Uploader's storage engine. @@ -3622,11 +3782,11 @@ module CarrierWave::Uploader::Store # # [new_file (File, IOString, Tempfile)] any kind of file object # - # source://carrierwave//lib/carrierwave/uploader/store.rb#62 + # source://carrierwave//lib/carrierwave/uploader/store.rb#79 def store!(new_file = T.unsafe(nil)); end # Calculates the path where the file should be stored. If +for_file+ is given, it will be - # used as the filename, otherwise +CarrierWave::Uploader#filename+ is assumed. + # used as the identifier, otherwise +CarrierWave::Uploader#identifier+ is assumed. # # === Parameters # @@ -3636,15 +3796,15 @@ module CarrierWave::Uploader::Store # # [String] the store path # - # source://carrierwave//lib/carrierwave/uploader/store.rb#49 + # source://carrierwave//lib/carrierwave/uploader/store.rb#66 def store_path(for_file = T.unsafe(nil)); end private - # source://carrierwave//lib/carrierwave/uploader/store.rb#94 + # source://carrierwave//lib/carrierwave/uploader/store.rb#132 def full_filename(for_file); end - # source://carrierwave//lib/carrierwave/uploader/store.rb#98 + # source://carrierwave//lib/carrierwave/uploader/store.rb#136 def storage; end module GeneratedClassMethods @@ -3715,7 +3875,7 @@ module CarrierWave::Uploader::Url end end -# source://carrierwave//lib/carrierwave/uploader/versions.rb#3 +# source://carrierwave//lib/carrierwave/uploader/versions.rb#5 module CarrierWave::Uploader::Versions extend ::ActiveSupport::Concern include GeneratedInstanceMethods @@ -3725,10 +3885,17 @@ module CarrierWave::Uploader::Versions mixes_in_class_methods ::CarrierWave::Uploader::Callbacks::ClassMethods mixes_in_class_methods ::CarrierWave::Uploader::Versions::ClassMethods + # Copies the parent's cache_id when caching a version file. + # This behavior is not essential but it makes easier to understand + # that the cached files are generated by the single upload attempt. + # + # source://carrierwave//lib/carrierwave/uploader/versions.rb#231 + def cache!(*args); end + # Recreate versions and reprocess them. This can be used to recreate # versions if their parameters somehow have changed. # - # source://carrierwave//lib/carrierwave/uploader/versions.rb#223 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#277 def recreate_versions!(*names); end # When given a version name as a parameter, will return the url for that version @@ -3754,7 +3921,7 @@ module CarrierWave::Uploader::Versions # # [String] the location where this file is accessible via a url # - # source://carrierwave//lib/carrierwave/uploader/versions.rb#207 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#261 def url(*args); end # === Parameters @@ -3763,18 +3930,18 @@ module CarrierWave::Uploader::Versions # # === Returns # - # [Boolean] True when the version exists according to its :if condition + # [Boolean] True when the version exists according to its :if or :unless condition # # @return [Boolean] # - # source://carrierwave//lib/carrierwave/uploader/versions.rb#166 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#201 def version_exists?(name); end # === Returns # # [String] the name of this version of the uploader # - # source://carrierwave//lib/carrierwave/uploader/versions.rb#152 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#187 def version_name; end # Returns a hash mapping the name of each version of the uploader to an instance of it @@ -3783,62 +3950,46 @@ module CarrierWave::Uploader::Versions # # [Hash{Symbol => CarrierWave::Uploader}] a list of uploader instances # - # source://carrierwave//lib/carrierwave/uploader/versions.rb#137 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#172 def versions; end - private + protected - # source://carrierwave//lib/carrierwave/uploader/versions.rb#281 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#300 def active_versions; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#269 - def active_versions_with_names_in(names); end + # source://carrierwave//lib/carrierwave/uploader/versions.rb#294 + def descendant_version_names; end + + private - # source://carrierwave//lib/carrierwave/uploader/versions.rb#275 - def assign_parent_cache_id(file); end + # source://carrierwave//lib/carrierwave/uploader/versions.rb#316 + def active_sibling_versions; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#307 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#328 def cache_versions!(new_file); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#287 - def dependent_versions; end + # source://carrierwave//lib/carrierwave/uploader/versions.rb#308 + def derived_versions; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#299 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#320 def full_filename(for_file); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#303 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#324 def full_original_filename; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#318 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#336 def remove_versions!; end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#248 - def reset_versions_to_cache_and_store; end - - # source://carrierwave//lib/carrierwave/uploader/versions.rb#322 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#340 def retrieve_versions_from_cache!(cache_name); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#326 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#344 def retrieve_versions_from_store!(identifier); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#243 - def set_versions_to_cache_and_store(names); end - - # source://carrierwave//lib/carrierwave/uploader/versions.rb#295 - def sibling_versions; end - - # source://carrierwave//lib/carrierwave/uploader/versions.rb#260 - def source_versions_of(requested_names); end - - # source://carrierwave//lib/carrierwave/uploader/versions.rb#314 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#332 def store_versions!(new_file); end - # source://carrierwave//lib/carrierwave/uploader/versions.rb#252 - def versions_to_cache; end - - # source://carrierwave//lib/carrierwave/uploader/versions.rb#256 - def versions_to_store; end - module GeneratedClassMethods def _after_callbacks; end def _after_callbacks=(value); end @@ -3865,11 +4016,35 @@ module CarrierWave::Uploader::Versions end end -# source://carrierwave//lib/carrierwave/uploader/versions.rb#31 -module CarrierWave::Uploader::Versions::ClassMethods - # source://carrierwave//lib/carrierwave/uploader/versions.rb#64 - def recursively_apply_block_to_versions(&block); end +# source://carrierwave//lib/carrierwave/uploader/versions.rb#6 +class CarrierWave::Uploader::Versions::Builder + # @return [Builder] a new instance of Builder + # + # source://carrierwave//lib/carrierwave/uploader/versions.rb#7 + def initialize(name); end + + # source://carrierwave//lib/carrierwave/uploader/versions.rb#20 + def build(superclass); end + # source://carrierwave//lib/carrierwave/uploader/versions.rb#14 + def configure(options, &block); end + + # source://carrierwave//lib/carrierwave/uploader/versions.rb#67 + def deep_dup; end + + # source://carrierwave//lib/carrierwave/uploader/versions.rb#73 + def method_missing(name, *args); end + + private + + # @return [Boolean] + # + # source://carrierwave//lib/carrierwave/uploader/versions.rb#82 + def respond_to_missing?(*_arg0); end +end + +# source://carrierwave//lib/carrierwave/uploader/versions.rb#113 +module CarrierWave::Uploader::Versions::ClassMethods # Adds a new version to this uploader # # === Parameters @@ -3890,35 +4065,75 @@ module CarrierWave::Uploader::Versions::ClassMethods # process :scale => [200, 200] # end # + # version :square, :unless => :invalid_image_type? do + # process :scale => [100, 100] + # end + # # end # - # source://carrierwave//lib/carrierwave/uploader/versions.rb#56 + # source://carrierwave//lib/carrierwave/uploader/versions.rb#142 def version(name, options = T.unsafe(nil), &block); end private - # source://carrierwave//lib/carrierwave/uploader/versions.rb#73 - def build_version(name, options); end + # source://carrierwave//lib/carrierwave/uploader/versions.rb#158 + def inherited(subclass); end end # source://carrierwave//lib/carrierwave/utilities/uri.rb#4 module CarrierWave::Utilities; end +# source://carrierwave//lib/carrierwave/utilities/file_name.rb#3 +module CarrierWave::Utilities::FileName + # Returns the part of the filename before the extension. So if a file is called 'test.jpeg' + # this would return 'test' + # + # === Returns + # + # [String] the first part of the filename + # + # source://carrierwave//lib/carrierwave/utilities/file_name.rb#13 + def basename; end + + # Returns the file extension + # + # === Returns + # + # [String] extension of file or "" if the file has no extension + # + # source://carrierwave//lib/carrierwave/utilities/file_name.rb#24 + def extension; end + + private + + # source://carrierwave//lib/carrierwave/utilities/file_name.rb#30 + def split_extension(filename); end +end + # source://carrierwave//lib/carrierwave/utilities/uri.rb#5 module CarrierWave::Utilities::Uri private - # source://carrierwave//lib/carrierwave/utilities/uri.rb#11 + # source://carrierwave//lib/carrierwave/utilities/uri.rb#21 + def decode_uri(str); end + + # source://carrierwave//lib/carrierwave/utilities/uri.rb#17 + def encode_non_ascii(str); end + + # source://carrierwave//lib/carrierwave/utilities/uri.rb#13 def encode_path(path); end end +# source://carrierwave//lib/carrierwave/utilities/uri.rb#9 +CarrierWave::Utilities::Uri::NON_ASCII = T.let(T.unsafe(nil), Regexp) + # based on Ruby < 2.0's URI.encode # # source://carrierwave//lib/carrierwave/utilities/uri.rb#7 -CarrierWave::Utilities::Uri::SAFE_STRING = T.let(T.unsafe(nil), String) +CarrierWave::Utilities::Uri::PATH_SAFE = T.let(T.unsafe(nil), String) # source://carrierwave//lib/carrierwave/utilities/uri.rb#8 -CarrierWave::Utilities::Uri::UNSAFE = T.let(T.unsafe(nil), Regexp) +CarrierWave::Utilities::Uri::PATH_UNSAFE = T.let(T.unsafe(nil), Regexp) # source://carrierwave//lib/carrierwave/version.rb#2 CarrierWave::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/childprocess@5.1.0.rbi b/sorbet/rbi/gems/childprocess@5.1.0.rbi new file mode 100644 index 000000000..aac0c93e6 --- /dev/null +++ b/sorbet/rbi/gems/childprocess@5.1.0.rbi @@ -0,0 +1,383 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `childprocess` gem. +# Please instead update this file by running `bin/tapioca gem childprocess`. + + +# source://childprocess//lib/childprocess/version.rb#1 +module ChildProcess + class << self + # source://childprocess//lib/childprocess.rb#105 + def arch; end + + # source://childprocess//lib/childprocess.rb#16 + def build(*args); end + + # By default, a child process will inherit open file descriptors from the + # parent process. This helper provides a cross-platform way of making sure + # that doesn't happen for the given file/io. + # + # source://childprocess//lib/childprocess.rb#132 + def close_on_exec(file); end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess.rb#53 + def jruby?; end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess.rb#49 + def linux?; end + + # source://childprocess//lib/childprocess.rb#28 + def logger; end + + # Sets the attribute logger + # + # @param value the value to set the attribute logger to. + # + # source://childprocess//lib/childprocess.rb#14 + def logger=(_arg0); end + + # source://childprocess//lib/childprocess.rb#16 + def new(*args); end + + # source://childprocess//lib/childprocess.rb#77 + def os; end + + # source://childprocess//lib/childprocess.rb#37 + def platform; end + + # source://childprocess//lib/childprocess.rb#41 + def platform_name; end + + # Set this to true to enable experimental use of posix_spawn. + # + # source://childprocess//lib/childprocess.rb#73 + def posix_spawn=(bool); end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess.rb#65 + def posix_spawn?; end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess.rb#61 + def posix_spawn_chosen_explicitly?; end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess.rb#45 + def unix?; end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess.rb#57 + def windows?; end + + private + + # @return [Boolean] `true` if this Ruby represents `1` in 64 bits (8 bytes). + # + # source://childprocess//lib/childprocess.rb#162 + def is_64_bit?; end + + # source://childprocess//lib/childprocess.rb#142 + def warn_once(msg); end + + # Workaround: detect the situation that an older Darwin Ruby is actually + # 64-bit, but is misreporting cpu as i686, which would imply 32-bit. + # + # @return [Boolean] `true` if: + # (a) on Mac OS X + # (b) actually running in 64-bit mode + # + # source://childprocess//lib/childprocess.rb#157 + def workaround_older_macosx_misreported_cpu?; end + end +end + +# source://childprocess//lib/childprocess/abstract_io.rb#2 +class ChildProcess::AbstractIO + # @api private + # + # source://childprocess//lib/childprocess/abstract_io.rb#24 + def _stdin=(io); end + + # source://childprocess//lib/childprocess/abstract_io.rb#5 + def inherit!; end + + # Returns the value of attribute stderr. + # + # source://childprocess//lib/childprocess/abstract_io.rb#3 + def stderr; end + + # source://childprocess//lib/childprocess/abstract_io.rb#10 + def stderr=(io); end + + # Returns the value of attribute stdin. + # + # source://childprocess//lib/childprocess/abstract_io.rb#3 + def stdin; end + + # Returns the value of attribute stdout. + # + # source://childprocess//lib/childprocess/abstract_io.rb#3 + def stdout; end + + # source://childprocess//lib/childprocess/abstract_io.rb#15 + def stdout=(io); end + + private + + # @raise [SubclassResponsibility] + # + # source://childprocess//lib/childprocess/abstract_io.rb#31 + def check_type(io); end +end + +# source://childprocess//lib/childprocess/abstract_process.rb#2 +class ChildProcess::AbstractProcess + # Create a new process with the given args. + # + # @api private + # @return [AbstractProcess] a new instance of AbstractProcess + # @see ChildProcess.build + # + # source://childprocess//lib/childprocess/abstract_process.rb#42 + def initialize(*args); end + + # Is this process running? + # + # @return [Boolean] + # + # source://childprocess//lib/childprocess/abstract_process.rb#133 + def alive?; end + + # Returns true if the process has exited and the exit code was not 0. + # + # @return [Boolean] + # + # source://childprocess//lib/childprocess/abstract_process.rb#143 + def crashed?; end + + # Set the child's current working directory. + # + # source://childprocess//lib/childprocess/abstract_process.rb#25 + def cwd; end + + # Set the child's current working directory. + # + # source://childprocess//lib/childprocess/abstract_process.rb#25 + def cwd=(_arg0); end + + # Set this to true if you do not care about when or if the process quits. + # + # source://childprocess//lib/childprocess/abstract_process.rb#10 + def detach; end + + # Set this to true if you do not care about when or if the process quits. + # + # source://childprocess//lib/childprocess/abstract_process.rb#10 + def detach=(_arg0); end + + # Set this to true if you want to write to the process' stdin (process.io.stdin) + # + # source://childprocess//lib/childprocess/abstract_process.rb#15 + def duplex; end + + # Set this to true if you want to write to the process' stdin (process.io.stdin) + # + # source://childprocess//lib/childprocess/abstract_process.rb#15 + def duplex=(_arg0); end + + # Modify the child's environment variables + # + # source://childprocess//lib/childprocess/abstract_process.rb#20 + def environment; end + + # Returns the value of attribute exit_code. + # + # source://childprocess//lib/childprocess/abstract_process.rb#5 + def exit_code; end + + # Did the process exit? + # + # @raise [SubclassResponsibility] + # @return [Boolean] + # + # source://childprocess//lib/childprocess/abstract_process.rb#113 + def exited?; end + + # Returns a ChildProcess::AbstractIO subclass to configure the child's IO streams. + # + # @raise [SubclassResponsibility] + # + # source://childprocess//lib/childprocess/abstract_process.rb#62 + def io; end + + # Set this to true to make the child process the leader of a new process group + # + # This can be used to make sure that all grandchildren are killed + # when the child process dies. + # + # source://childprocess//lib/childprocess/abstract_process.rb#33 + def leader; end + + # Set this to true to make the child process the leader of a new process group + # + # This can be used to make sure that all grandchildren are killed + # when the child process dies. + # + # source://childprocess//lib/childprocess/abstract_process.rb#33 + def leader=(_arg0); end + + # @raise [SubclassResponsibility] + # @return [Integer] the pid of the process after it has started + # + # source://childprocess//lib/childprocess/abstract_process.rb#70 + def pid; end + + # Wait for the process to exit, raising a ChildProcess::TimeoutError if + # the timeout expires. + # + # source://childprocess//lib/childprocess/abstract_process.rb#152 + def poll_for_exit(timeout); end + + # Launch the child process + # + # @return [AbstractProcess] self + # + # source://childprocess//lib/childprocess/abstract_process.rb#80 + def start; end + + # Has the process started? + # + # @return [Boolean] + # + # source://childprocess//lib/childprocess/abstract_process.rb#123 + def started?; end + + # Forcibly terminate the process, using increasingly harsher methods if possible. + # + # @param timeout [Integer] (3) Seconds to wait before trying the next method. + # @raise [SubclassResponsibility] + # + # source://childprocess//lib/childprocess/abstract_process.rb#93 + def stop(timeout = T.unsafe(nil)); end + + # Block until the process has been terminated. + # + # @raise [SubclassResponsibility] + # @return [Integer] The exit status of the process + # + # source://childprocess//lib/childprocess/abstract_process.rb#103 + def wait; end + + private + + # @raise [Error] + # + # source://childprocess//lib/childprocess/abstract_process.rb#187 + def assert_started; end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess/abstract_process.rb#171 + def detach?; end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess/abstract_process.rb#175 + def duplex?; end + + # @raise [SubclassResponsibility] + # + # source://childprocess//lib/childprocess/abstract_process.rb#167 + def launch_process; end + + # @return [Boolean] + # + # source://childprocess//lib/childprocess/abstract_process.rb#179 + def leader?; end + + # source://childprocess//lib/childprocess/abstract_process.rb#183 + def log(*args); end +end + +# source://childprocess//lib/childprocess/abstract_process.rb#3 +ChildProcess::AbstractProcess::POLL_INTERVAL = T.let(T.unsafe(nil), Float) + +# source://childprocess//lib/childprocess/errors.rb#2 +class ChildProcess::Error < ::StandardError; end + +# source://childprocess//lib/childprocess/errors.rb#11 +class ChildProcess::InvalidEnvironmentVariable < ::ChildProcess::Error; end + +# source://childprocess//lib/childprocess/errors.rb#14 +class ChildProcess::LaunchError < ::ChildProcess::Error; end + +# source://childprocess//lib/childprocess/process_spawn_process.rb#4 +class ChildProcess::ProcessSpawnProcess < ::ChildProcess::AbstractProcess + # @return [Boolean] + # + # source://childprocess//lib/childprocess/process_spawn_process.rb#7 + def exited?; end + + # Returns the value of attribute pid. + # + # source://childprocess//lib/childprocess/process_spawn_process.rb#5 + def pid; end + + # source://childprocess//lib/childprocess/process_spawn_process.rb#26 + def wait; end + + private + + # source://childprocess//lib/childprocess/process_spawn_process.rb#40 + def launch_process; end + + # source://childprocess//lib/childprocess/process_spawn_process.rb#107 + def send_kill; end + + # source://childprocess//lib/childprocess/process_spawn_process.rb#111 + def send_signal(sig); end + + # source://childprocess//lib/childprocess/process_spawn_process.rb#103 + def send_term; end + + # source://childprocess//lib/childprocess/process_spawn_process.rb#99 + def set_exit_code(status); end +end + +# source://childprocess//lib/childprocess/errors.rb#8 +class ChildProcess::SubclassResponsibility < ::ChildProcess::Error; end + +# source://childprocess//lib/childprocess/errors.rb#5 +class ChildProcess::TimeoutError < ::ChildProcess::Error; end + +# source://childprocess//lib/childprocess/unix.rb#2 +module ChildProcess::Unix; end + +# source://childprocess//lib/childprocess/unix/io.rb#3 +class ChildProcess::Unix::IO < ::ChildProcess::AbstractIO + private + + # source://childprocess//lib/childprocess/unix/io.rb#6 + def check_type(io); end +end + +# source://childprocess//lib/childprocess/unix/process.rb#5 +class ChildProcess::Unix::Process < ::ChildProcess::ProcessSpawnProcess + # source://childprocess//lib/childprocess/unix/process.rb#6 + def io; end + + # source://childprocess//lib/childprocess/unix/process.rb#10 + def stop(timeout = T.unsafe(nil)); end +end + +# source://childprocess//lib/childprocess/version.rb#2 +ChildProcess::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/chronic@0.10.2.rbi b/sorbet/rbi/gems/chronic@0.10.2.rbi index 67860e04d..d829d3cc7 100644 --- a/sorbet/rbi/gems/chronic@0.10.2.rbi +++ b/sorbet/rbi/gems/chronic@0.10.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `chronic` gem. # Please instead update this file by running `bin/tapioca gem chronic`. + # Parse natural language dates and times into Time or Chronic::Span objects. # # Examples: diff --git a/sorbet/rbi/gems/chunky_png@1.3.15.rbi b/sorbet/rbi/gems/chunky_png@1.3.15.rbi index eb3efa6e6..b416930ea 100644 --- a/sorbet/rbi/gems/chunky_png@1.3.15.rbi +++ b/sorbet/rbi/gems/chunky_png@1.3.15.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `chunky_png` gem. # Please instead update this file by running `bin/tapioca gem chunky_png`. + # ChunkyPNG - the pure ruby library to access PNG files. # # The ChunkyPNG module defines some constants that are used in the diff --git a/sorbet/rbi/gems/clipboard-rails@1.7.1.rbi b/sorbet/rbi/gems/clipboard-rails@1.7.1.rbi deleted file mode 100644 index 0cd9f49fa..000000000 --- a/sorbet/rbi/gems/clipboard-rails@1.7.1.rbi +++ /dev/null @@ -1,17 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `clipboard-rails` gem. -# Please instead update this file by running `bin/tapioca gem clipboard-rails`. - -# source://clipboard-rails//lib/clipboard/rails/version.rb#1 -module Clipboard; end - -# source://clipboard-rails//lib/clipboard/rails/version.rb#2 -module Clipboard::Rails; end - -# source://clipboard-rails//lib/clipboard/rails.rb#5 -class Clipboard::Rails::Engine < ::Rails::Engine; end - -# source://clipboard-rails//lib/clipboard/rails/version.rb#3 -Clipboard::Rails::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/coderay@1.1.3.rbi b/sorbet/rbi/gems/coderay@1.1.3.rbi index 76870c112..f09572430 100644 --- a/sorbet/rbi/gems/coderay@1.1.3.rbi +++ b/sorbet/rbi/gems/coderay@1.1.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `coderay` gem. # Please instead update this file by running `bin/tapioca gem coderay`. + # = CodeRay Library # # CodeRay is a Ruby library for syntax highlighting. diff --git a/sorbet/rbi/gems/coffee-rails@5.0.0.rbi b/sorbet/rbi/gems/coffee-rails@5.0.0.rbi index fbe57ef37..1ee2b917f 100644 --- a/sorbet/rbi/gems/coffee-rails@5.0.0.rbi +++ b/sorbet/rbi/gems/coffee-rails@5.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `coffee-rails` gem. # Please instead update this file by running `bin/tapioca gem coffee-rails`. + # source://coffee-rails//lib/coffee/rails/js_hook.rb#1 module Coffee; end @@ -11,7 +12,12 @@ module Coffee; end module Coffee::Rails; end # source://coffee-rails//lib/coffee/rails/engine.rb#7 -class Coffee::Rails::Engine < ::Rails::Engine; end +class Coffee::Rails::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # source://coffee-rails//lib/coffee/rails/js_hook.rb#3 module Coffee::Rails::JsHook diff --git a/sorbet/rbi/gems/coffee-script-source@1.12.2.rbi b/sorbet/rbi/gems/coffee-script-source@1.12.2.rbi index 9b4e1d193..b39fdd760 100644 --- a/sorbet/rbi/gems/coffee-script-source@1.12.2.rbi +++ b/sorbet/rbi/gems/coffee-script-source@1.12.2.rbi @@ -4,11 +4,10 @@ # This is an autogenerated file for types exported from the `coffee-script-source` gem. # Please instead update this file by running `bin/tapioca gem coffee-script-source`. + # source://coffee-script-source//lib/coffee_script/source.rb#1 module CoffeeScript class << self - # Compile a script (String or IO) to JavaScript. - # # source://coffee-script/2.4.1/lib/coffee_script.rb#66 def compile(script, options = T.unsafe(nil)); end @@ -23,15 +22,6 @@ module CoffeeScript end end -# source://coffee-script/2.4.1/lib/coffee_script.rb#7 -CoffeeScript::CompilationError = ExecJS::ProgramError - -# source://coffee-script/2.4.1/lib/coffee_script.rb#6 -CoffeeScript::EngineError = ExecJS::RuntimeError - -# source://coffee-script/2.4.1/lib/coffee_script.rb#5 -CoffeeScript::Error = ExecJS::Error - # source://coffee-script-source//lib/coffee_script/source.rb#2 module CoffeeScript::Source class << self @@ -57,6 +47,3 @@ module CoffeeScript::Source def version; end end end - -# source://coffee-script/2.4.1/lib/coffee_script.rb#19 -CoffeeScript::Source::COMPILE_FUNCTION_SOURCE = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/coffee-script@2.4.1.rbi b/sorbet/rbi/gems/coffee-script@2.4.1.rbi index ceddb54ea..d456fa9b7 100644 --- a/sorbet/rbi/gems/coffee-script@2.4.1.rbi +++ b/sorbet/rbi/gems/coffee-script@2.4.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `coffee-script` gem. # Please instead update this file by running `bin/tapioca gem coffee-script`. + # source://coffee-script//lib/coffee_script.rb#4 module CoffeeScript class << self diff --git a/sorbet/rbi/gems/concurrent-ruby@1.2.2.rbi b/sorbet/rbi/gems/concurrent-ruby@1.3.4.rbi similarity index 97% rename from sorbet/rbi/gems/concurrent-ruby@1.2.2.rbi rename to sorbet/rbi/gems/concurrent-ruby@1.3.4.rbi index 6c849d14f..e6a82d005 100644 --- a/sorbet/rbi/gems/concurrent-ruby@1.2.2.rbi +++ b/sorbet/rbi/gems/concurrent-ruby@1.3.4.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `concurrent-ruby` gem. # Please instead update this file by running `bin/tapioca gem concurrent-ruby`. + # {include:file:README.md} # # source://concurrent-ruby//lib/concurrent-ruby/concurrent/constants.rb#1 @@ -147,11 +148,47 @@ module Concurrent # source://concurrent-ruby//lib/concurrent-ruby/concurrent/tvar.rb#82 def atomically; end + # Number of processors cores available for process scheduling. + # This method takes in account the CPU quota if the process is inside a cgroup with a + # dedicated CPU quota (typically Docker). + # Otherwise it returns the same value as #processor_count but as a Float. + # + # For performance reasons the calculated value will be memoized on the first + # call. + # + # @return [Float] number of available processors + # + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#194 + def available_processor_count; end + # @raise [ArgumentError] # # source://concurrent-ruby//lib/concurrent-ruby/concurrent/dataflow.rb#56 def call_dataflow(method, executor, *inputs, &block); end + # The maximum number of processors cores available for process scheduling. + # Returns `nil` if there is no enforced limit, or a `Float` if the + # process is inside a cgroup with a dedicated CPU quota (typically Docker). + # + # Note that nothing prevents setting a CPU quota higher than the actual number of + # cores on the system. + # + # For performance reasons the calculated value will be memoized on the first + # call. + # + # @return [nil, Float] Maximum number of available processors as set by a cgroup CPU quota, or nil if none set + # + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#209 + def cpu_quota; end + + # The CPU shares requested by the process. For performance reasons the calculated + # value will be memoized on the first call. + # + # @return [Float, nil] CPU shares requested by the process, or nil if not set + # + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#217 + def cpu_shares; end + # @return [Logger] Logger with provided level and output. # # source://concurrent-ruby//lib/concurrent-ruby/concurrent/concern/logging.rb#37 @@ -290,7 +327,7 @@ module Concurrent # @see http://www.unix.com/man-page/osx/1/HWPREFS/ # @see http://linux.die.net/man/8/sysctl # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#107 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#181 def physical_processor_count; end # Number of processors seen by the OS and used for process scheduling. For @@ -301,18 +338,18 @@ module Concurrent # `java.lang.Runtime.getRuntime.availableProcessors` will be used. According # to the Java documentation this "value may change during a particular # invocation of the virtual machine... [applications] should therefore - # occasionally poll this property." Subsequently the result will NOT be - # memoized under JRuby. + # occasionally poll this property." We still memoize this value once under + # JRuby. # # Otherwise Ruby's Etc.nprocessors will be used. # # @return [Integer] number of processors seen by the OS or Java runtime # @see http://docs.oracle.com/javase/6/docs/api/java/lang/Runtime.html#availableProcessors() # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#86 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#160 def processor_count; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#68 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#142 def processor_counter; end # Use logger created by #create_simple_logger to log concurrent-ruby messages. @@ -4131,7 +4168,7 @@ end # @see http://docs.oracle.com/javase/8/docs/api/java/util/concurrent/ExecutorService.html Java ExecutorService interface # @see https://docs.oracle.com/javase/8/docs/api/java/lang/Thread.html#setDaemon-boolean- # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/fixed_thread_pool.rb#197 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/fixed_thread_pool.rb#201 class Concurrent::FixedThreadPool < ::Concurrent::ThreadPoolExecutor # Create a new thread pool. # @@ -4143,7 +4180,7 @@ class Concurrent::FixedThreadPool < ::Concurrent::ThreadPoolExecutor # @return [FixedThreadPool] a new instance of FixedThreadPool # @see http://docs.oracle.com/javase/8/docs/api/java/util/concurrent/Executors.html#newFixedThreadPool-int- # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/fixed_thread_pool.rb#211 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/fixed_thread_pool.rb#215 def initialize(num_threads, opts = T.unsafe(nil)); end end @@ -4257,7 +4294,7 @@ Concurrent::GLOBAL_TIMER_SET = T.let(T.unsafe(nil), Concurrent::Delay) # # @see http://ruby-doc.org/core/Hash.html Ruby standard library `Hash` # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/hash.rb#47 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/hash.rb#49 class Concurrent::Hash < ::Hash; end # source://concurrent-ruby//lib/concurrent-ruby/concurrent/hash.rb#16 @@ -6476,7 +6513,7 @@ class Concurrent::PromiseExecutionError < ::StandardError; end # {include:file:docs-source/promises-main.md} # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#12 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#13 module Concurrent::Promises extend ::Concurrent::Promises::FactoryMethods::Configuration extend ::Concurrent::Promises::FactoryMethods @@ -6484,40 +6521,40 @@ end # @abstract # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2037 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2047 class Concurrent::Promises::AbstractAnyPromise < ::Concurrent::Promises::BlockedPromise; end # Common ancestor of {Event} and {Future} classes, many shared methods are defined here. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#512 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#513 class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization::Object include ::Concurrent::Promises::InternalStates extend ::Concurrent::Synchronization::SafeInitialization # @return [AbstractEventFuture] a new instance of AbstractEventFuture # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#521 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#522 def initialize(promise, default_executor); end # source://concurrent-ruby//lib/concurrent-ruby/concurrent/synchronization/object.rb#137 def __initialize_atomic_fields__; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#737 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#738 def add_callback_clear_delayed_node(node); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#732 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#733 def add_callback_notify_blocked(promise, index); end # For inspection. # # @return [Array] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#701 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#702 def blocks; end # For inspection. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#709 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#710 def callbacks; end # Shortcut of {#chain_on} with default `:io` executor supplied. @@ -6525,7 +6562,7 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @return [Future] # @see #chain_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#595 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#596 def chain(*args, &task); end # Chains the task to be executed asynchronously on executor after it is resolved. @@ -6535,13 +6572,13 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @param executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. The task is executed on it, default executor remains unchanged. # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [Future] # @yieldreturn will become result of the returned Future. # Its returned value becomes {Future#value} fulfilling it, # raised exception becomes {Future#reason} rejecting it. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#613 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#614 def chain_on(executor, *args, &task); end # Resolves the resolvable when receiver is resolved. @@ -6549,7 +6586,7 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @param resolvable [Resolvable] # @return [self] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#628 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#629 def chain_resolvable(resolvable); end # Returns default executor. @@ -6561,12 +6598,12 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @see FactoryMethods#any_fulfilled_future_on # @see similar # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#589 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#590 def default_executor; end # @return [String] Short string representation. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#618 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#619 def inspect; end # source://concurrent-ruby//lib/concurrent-ruby/concurrent/synchronization/object.rb#93 @@ -6577,7 +6614,7 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @return [self] # @see #on_resolution_using # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#636 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#637 def on_resolution(*args, &callback); end # Stores the callback to be executed synchronously on resolving thread after it is @@ -6586,11 +6623,11 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @overload an_event.on_resolution! # @overload a_future.on_resolution! # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [self] # @yieldreturn is forgotten. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#654 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#655 def on_resolution!(*args, &callback); end # Stores the callback to be executed asynchronously on executor after it is resolved. @@ -6600,33 +6637,33 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @param executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. The task is executed on it, default executor remains unchanged. # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [self] # @yieldreturn is forgotten. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#672 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#673 def on_resolution_using(executor, *args, &callback); end # Is it in pending state? # # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#548 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#549 def pending?; end # For inspection. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#715 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#716 def promise; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#687 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#688 def resolve_with(state, raise_on_reassign = T.unsafe(nil), reserved = T.unsafe(nil)); end # Is it in resolved state? # # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#554 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#555 def resolved?; end # Returns its state. @@ -6635,7 +6672,7 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @overload a_future.state # @return [Symbol] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#542 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#543 def state; end # Resolves the resolvable when receiver is resolved. @@ -6643,12 +6680,12 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @param resolvable [Resolvable] # @return [self] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#628 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#629 def tangle(resolvable); end # @return [String] Short string representation. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#618 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#619 def to_s; end # Propagates touch. Requests all the delayed futures, which it depends on, to be @@ -6656,14 +6693,14 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # # @return [self] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#561 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#562 def touch; end # For inspection. # # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#721 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#722 def touched?; end # Wait (block the Thread) until receiver is {#resolved?}. @@ -6675,12 +6712,12 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @return [self, true, false] self implies timeout was not used, true implies timeout was used # and it was resolved, false implies it was not resolved within timeout. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#577 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#578 def wait(timeout = T.unsafe(nil)); end # For inspection. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#727 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#728 def waiting_threads; end # Crates new object with same class with the executor set as its new default executor. @@ -6692,30 +6729,30 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @see Event#with_default_executor # @see Future#with_default_executor # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#682 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#683 def with_default_executor(executor); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#742 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#743 def with_hidden_resolvable; end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#749 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#750 def add_callback(method, *args); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#802 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#812 def async_callback_on_resolution(state, executor, args, callback); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#786 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#796 def call_callback(method, state, args); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#790 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#800 def call_callbacks(state); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#762 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#763 def callback_clear_delayed_node(state, node); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#808 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#818 def callback_notify_blocked(state, promise, index); end # source://concurrent-ruby//lib/concurrent-ruby/concurrent/synchronization/object.rb#105 @@ -6732,188 +6769,188 @@ class Concurrent::Promises::AbstractEventFuture < ::Concurrent::Synchronization: # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#767 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#768 def wait_until_resolved(timeout); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#798 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#808 def with_async(executor, *args, &block); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1786 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1796 class Concurrent::Promises::AbstractFlatPromise < ::Concurrent::Promises::BlockedPromise # @return [AbstractFlatPromise] a new instance of AbstractFlatPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1788 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1798 def initialize(delayed_because, blockers_count, event_or_future); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1798 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1808 def touch; end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1818 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1828 def add_delayed_of(future); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1810 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1820 def on_resolvable(resolved_future, index); end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1814 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1824 def resolvable?(countdown, future, index); end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1806 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1816 def touched?; end end # @abstract # @private # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1539 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1549 class Concurrent::Promises::AbstractPromise < ::Concurrent::Synchronization::Object include ::Concurrent::Promises::InternalStates extend ::Concurrent::Synchronization::SafeInitialization # @return [AbstractPromise] a new instance of AbstractPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1543 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1553 def initialize(future); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1554 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1564 def default_executor; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1571 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1581 def delayed_because; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1548 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1558 def event; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1548 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1558 def future; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1565 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1575 def inspect; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1558 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1568 def state; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1565 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1575 def to_s; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1562 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1572 def touch; end private # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1582 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1592 def evaluate_to(*args, block); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1577 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1587 def resolve_with(new_state, raise_on_reassign = T.unsafe(nil)); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2074 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2084 class Concurrent::Promises::AnyFulfilledFuturePromise < ::Concurrent::Promises::AnyResolvedFuturePromise private # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2078 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2088 def resolvable?(countdown, event_or_future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2040 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2050 class Concurrent::Promises::AnyResolvedEventPromise < ::Concurrent::Promises::AbstractAnyPromise # @return [AnyResolvedEventPromise] a new instance of AnyResolvedEventPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2044 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2054 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2052 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2062 def on_resolvable(resolved_future, index); end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2048 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2058 def resolvable?(countdown, future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2057 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2067 class Concurrent::Promises::AnyResolvedFuturePromise < ::Concurrent::Promises::AbstractAnyPromise # @return [AnyResolvedFuturePromise] a new instance of AnyResolvedFuturePromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2061 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2071 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2069 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2079 def on_resolvable(resolved_future, index); end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2065 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2075 def resolvable?(countdown, future, index); end end # @abstract # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1609 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1619 class Concurrent::Promises::BlockedPromise < ::Concurrent::Promises::InnerPromise # @return [BlockedPromise] a new instance of BlockedPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1651 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1661 def initialize(delayed, blockers_count, future); end # for inspection only # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1673 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1683 def blocked_by; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1664 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1674 def delayed_because; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1657 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1667 def on_blocker_resolution(future, index); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1668 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1678 def touch; end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1681 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1691 def clear_and_propagate_touch(stack_or_element = T.unsafe(nil)); end # @raise [NotImplementedError] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1700 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1710 def on_resolvable(resolved_future, index); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1696 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1706 def process_on_blocker_resolution(future, index); end # @return [true, false] if resolvable # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1692 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1702 def resolvable?(countdown, future, index); end class << self - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1642 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1652 def add_delayed(delayed1, delayed2); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1635 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1645 def new_blocked_by(blockers, *args, &block); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1613 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1623 def new_blocked_by1(blocker, *args, &block); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1620 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1630 def new_blocked_by2(blocker1, blocker2, *args, &block); end private @@ -6925,37 +6962,37 @@ end # @abstract # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1706 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1716 class Concurrent::Promises::BlockedTaskPromise < ::Concurrent::Promises::BlockedPromise # @raise [ArgumentError] # @return [BlockedTaskPromise] a new instance of BlockedTaskPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1707 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1717 def initialize(delayed, blockers_count, default_executor, executor, args, &task); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1715 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1725 def executor; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1756 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1766 class Concurrent::Promises::ChainPromise < ::Concurrent::Promises::BlockedTaskPromise private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1759 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1769 def on_resolvable(resolved_future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2085 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2095 class Concurrent::Promises::DelayPromise < ::Concurrent::Promises::InnerPromise # @return [DelayPromise] a new instance of DelayPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2087 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2097 def initialize(default_executor); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2098 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2108 def delayed_because; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2094 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2104 def touch; end end @@ -6963,7 +7000,7 @@ end # pending or resolved. It should be always resolved. Use {Future} to communicate rejections and # cancellation. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#816 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#826 class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # Creates a new event or a future which will be resolved when receiver and other are. # Returns an event if receiver and other are events, otherwise returns a future. @@ -6973,7 +7010,7 @@ class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # # @return [Future, Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#829 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#839 def &(other); end # Creates a new event which will be resolved when the first of receiver, `event_or_future` @@ -6981,7 +7018,7 @@ class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#843 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#853 def any(event_or_future); end # Creates new event dependent on receiver which will not evaluate until touched, see {#touch}. @@ -6989,7 +7026,7 @@ class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#853 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#863 def delay; end # Creates new event dependent on receiver scheduled to execute on/in intended_time. @@ -7000,24 +7037,24 @@ class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # `Time` means to run on `intended_time`. # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#865 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#875 def schedule(intended_time); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#595 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#596 def then(*args, &task); end # Returns self, since this is event # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#883 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#893 def to_event; end # Converts event to a future. The future is fulfilled when the event is resolved, the future may never fail. # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#875 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#885 def to_future; end # Crates new object with same class with the executor set as its new default executor. @@ -7025,7 +7062,7 @@ class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#889 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#899 def with_default_executor(executor); end # Creates a new event or a future which will be resolved when receiver and other are. @@ -7036,7 +7073,7 @@ class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # # @return [Future, Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#829 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#839 def zip(other); end # Creates a new event which will be resolved when the first of receiver, `event_or_future` @@ -7044,37 +7081,37 @@ class Concurrent::Promises::Event < ::Concurrent::Promises::AbstractEventFuture # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#843 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#853 def |(event_or_future); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#900 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#910 def callback_on_resolution(state, args, callback); end # @raise [Concurrent::MultipleAssignmentError] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#895 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#905 def rejected_resolution(raise_on_reassign, state); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1962 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1972 class Concurrent::Promises::EventWrapperPromise < ::Concurrent::Promises::BlockedPromise # @return [EventWrapperPromise] a new instance of EventWrapperPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1963 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1973 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1969 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1979 def on_resolvable(resolved_future, index); end end # Container of all {Future}, {Event} factory methods. They are never constructed directly with # new. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#45 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#46 module Concurrent::Promises::FactoryMethods include ::Concurrent::Promises::FactoryMethods::Configuration extend ::Concurrent::ReInclude @@ -7086,7 +7123,7 @@ module Concurrent::Promises::FactoryMethods # @return [Future] # @see #any_resolved_future_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#277 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#278 def any(*futures_and_or_events); end # Shortcut of {#any_event_on} with default `:io` executor supplied. @@ -7094,10 +7131,10 @@ module Concurrent::Promises::FactoryMethods # @return [Event] # @see #any_event_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#318 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#319 def any_event(*futures_and_or_events); end - # Creates new event which becomes resolved after first of the futures_and_or_events resolves. + # Creates a new event which becomes resolved after the first futures_and_or_events resolves. # If resolved it does not propagate {Concurrent::AbstractEventFuture#touch}, leaving delayed # futures un-executed if they are not required any more. # @@ -7107,7 +7144,7 @@ module Concurrent::Promises::FactoryMethods # @param futures_and_or_events [AbstractEventFuture] # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#328 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#329 def any_event_on(default_executor, *futures_and_or_events); end # Shortcut of {#any_fulfilled_future_on} with default `:io` executor supplied. @@ -7115,12 +7152,12 @@ module Concurrent::Promises::FactoryMethods # @return [Future] # @see #any_fulfilled_future_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#299 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#300 def any_fulfilled_future(*futures_and_or_events); end - # Creates new future which is resolved after first of futures_and_or_events is fulfilled. - # Its result equals result of the first resolved future or if all futures_and_or_events reject, - # it has reason of the last resolved future. + # Creates a new future which is resolved after the first futures_and_or_events is fulfilled. + # Its result equals the result of the first resolved future or if all futures_and_or_events reject, + # it has reason of the last rejected future. # If resolved it does not propagate {Concurrent::AbstractEventFuture#touch}, leaving delayed # futures un-executed if they are not required any more. # If event is supplied, which does not have value and can be only resolved, it's @@ -7132,7 +7169,7 @@ module Concurrent::Promises::FactoryMethods # @param futures_and_or_events [AbstractEventFuture] # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#312 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#313 def any_fulfilled_future_on(default_executor, *futures_and_or_events); end # Shortcut of {#any_resolved_future_on} with default `:io` executor supplied. @@ -7140,11 +7177,11 @@ module Concurrent::Promises::FactoryMethods # @return [Future] # @see #any_resolved_future_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#277 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#278 def any_resolved_future(*futures_and_or_events); end - # Creates new future which is resolved after first futures_and_or_events is resolved. - # Its result equals result of the first resolved future. + # Creates a new future which is resolved after the first futures_and_or_events is resolved. + # Its result equals the result of the first resolved future. # If resolved it does not propagate {Concurrent::AbstractEventFuture#touch}, leaving delayed # futures un-executed if they are not required any more. # If event is supplied, which does not have value and can be only resolved, it's @@ -7156,7 +7193,7 @@ module Concurrent::Promises::FactoryMethods # @param futures_and_or_events [AbstractEventFuture] # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#293 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#294 def any_resolved_future_on(default_executor, *futures_and_or_events); end # Shortcut of {#delay_on} with default `:io` executor supplied. @@ -7164,10 +7201,10 @@ module Concurrent::Promises::FactoryMethods # @return [Future, Event] # @see #delay_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#189 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#190 def delay(*args, &task); end - # Creates new event or future which is resolved only after it is touched, + # Creates a new event or future which is resolved only after it is touched, # see {Concurrent::AbstractEventFuture#touch}. # # @overload delay_on @@ -7176,10 +7213,10 @@ module Concurrent::Promises::FactoryMethods # global executor. Default executor propagates to chained futures unless overridden with # executor parameter or changed with {AbstractEventFuture#with_default_executor}. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#206 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#207 def delay_on(default_executor, *args, &task); end - # Creates resolved future with will be fulfilled with the given value. + # Creates a resolved future which will be fulfilled with the given value. # # @param default_executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. Default executor propagates to chained futures unless overridden with @@ -7187,7 +7224,7 @@ module Concurrent::Promises::FactoryMethods # @param value [Object] # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#126 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#127 def fulfilled_future(value, default_executor = T.unsafe(nil)); end # Shortcut of {#future_on} with default `:io` executor supplied. @@ -7195,24 +7232,24 @@ module Concurrent::Promises::FactoryMethods # @return [Future] # @see #future_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#93 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#94 def future(*args, &task); end - # Constructs new Future which will be resolved after block is evaluated on default executor. + # Constructs a new Future which will be resolved after block is evaluated on default executor. # Evaluation begins immediately. # # @param default_executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. Default executor propagates to chained futures unless overridden with # executor parameter or changed with {AbstractEventFuture#with_default_executor}. # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [Future] # @yield [*args] to the task. # @yieldreturn will become result of the returned Future. # Its returned value becomes {Future#value} fulfilling it, # raised exception becomes {Future#reason} rejecting it. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#105 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#106 def future_on(default_executor, *args, &task); end # General constructor. Behaves differently based on the argument's type. It's provided for convenience @@ -7229,10 +7266,10 @@ module Concurrent::Promises::FactoryMethods # @return [Event, Future] # @see rejected_future, resolved_event, fulfilled_future # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#173 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#174 def make_future(argument = T.unsafe(nil), default_executor = T.unsafe(nil)); end - # Creates resolved future with will be rejected with the given reason. + # Creates a resolved future which will be rejected with the given reason. # # @param default_executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. Default executor propagates to chained futures unless overridden with @@ -7240,7 +7277,7 @@ module Concurrent::Promises::FactoryMethods # @param reason [Object] # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#135 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#136 def rejected_future(reason, default_executor = T.unsafe(nil)); end # Shortcut of {#resolvable_event_on} with default `:io` executor supplied. @@ -7248,18 +7285,18 @@ module Concurrent::Promises::FactoryMethods # @return [ResolvableEvent] # @see #resolvable_event_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#62 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#63 def resolvable_event; end - # Created resolvable event, user is responsible for resolving the event once by - # {Promises::ResolvableEvent#resolve}. + # Creates a resolvable event, user is responsible for resolving the event once + # by calling {Promises::ResolvableEvent#resolve}. # # @param default_executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. Default executor propagates to chained futures unless overridden with # executor parameter or changed with {AbstractEventFuture#with_default_executor}. # @return [ResolvableEvent] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#71 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#72 def resolvable_event_on(default_executor = T.unsafe(nil)); end # Shortcut of {#resolvable_future_on} with default `:io` executor supplied. @@ -7267,7 +7304,7 @@ module Concurrent::Promises::FactoryMethods # @return [ResolvableFuture] # @see #resolvable_future_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#77 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#78 def resolvable_future; end # Creates resolvable future, user is responsible for resolving the future once by @@ -7279,7 +7316,7 @@ module Concurrent::Promises::FactoryMethods # executor parameter or changed with {AbstractEventFuture#with_default_executor}. # @return [ResolvableFuture] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#87 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#88 def resolvable_future_on(default_executor = T.unsafe(nil)); end # Creates resolved event. @@ -7289,10 +7326,10 @@ module Concurrent::Promises::FactoryMethods # executor parameter or changed with {AbstractEventFuture#with_default_executor}. # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#143 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#144 def resolved_event(default_executor = T.unsafe(nil)); end - # Creates resolved future with will be either fulfilled with the given value or rejection with + # Creates a resolved future with will be either fulfilled with the given value or rejected with # the given reason. # # @param fulfilled [true, false] @@ -7303,7 +7340,7 @@ module Concurrent::Promises::FactoryMethods # executor parameter or changed with {AbstractEventFuture#with_default_executor}. # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#117 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#118 def resolved_future(fulfilled, value, reason, default_executor = T.unsafe(nil)); end # Shortcut of {#schedule_on} with default `:io` executor supplied. @@ -7311,10 +7348,10 @@ module Concurrent::Promises::FactoryMethods # @return [Future, Event] # @see #schedule_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#213 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#214 def schedule(intended_time, *args, &task); end - # Creates new event or future which is resolved in intended_time. + # Creates a new event or future which is resolved in intended_time. # # @overload schedule_on # @overload schedule_on @@ -7324,7 +7361,7 @@ module Concurrent::Promises::FactoryMethods # @param intended_time [Numeric, Time] `Numeric` means to run in `intended_time` seconds. # `Time` means to run on `intended_time`. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#232 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#233 def schedule_on(default_executor, intended_time, *args, &task); end # Shortcut of {#zip_futures_on} with default `:io` executor supplied. @@ -7332,7 +7369,7 @@ module Concurrent::Promises::FactoryMethods # @return [Future] # @see #zip_futures_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#239 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#240 def zip(*futures_and_or_events); end # Shortcut of {#zip_events_on} with default `:io` executor supplied. @@ -7340,10 +7377,10 @@ module Concurrent::Promises::FactoryMethods # @return [Event] # @see #zip_events_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#261 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#262 def zip_events(*futures_and_or_events); end - # Creates new event which is resolved after all futures_and_or_events are resolved. + # Creates a new event which is resolved after all futures_and_or_events are resolved. # (Future is resolved when fulfilled or rejected.) # # @param default_executor [Executor, :io, :fast] Instance of an executor or a name of the @@ -7352,7 +7389,7 @@ module Concurrent::Promises::FactoryMethods # @param futures_and_or_events [AbstractEventFuture] # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#271 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#272 def zip_events_on(default_executor, *futures_and_or_events); end # Shortcut of {#zip_futures_on} with default `:io` executor supplied. @@ -7360,11 +7397,11 @@ module Concurrent::Promises::FactoryMethods # @return [Future] # @see #zip_futures_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#239 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#240 def zip_futures(*futures_and_or_events); end - # Creates new future which is resolved after all futures_and_or_events are resolved. - # Its value is array of zipped future values. Its reason is array of reasons for rejection. + # Creates a new future which is resolved after all futures_and_or_events are resolved. + # Its value is an array of zipped future values. Its reason is an array of reasons for rejection. # If there is an error it rejects. # If event is supplied, which does not have value and can be only resolved, it's # represented as `:fulfilled` with value `nil`. @@ -7375,51 +7412,51 @@ module Concurrent::Promises::FactoryMethods # @param futures_and_or_events [AbstractEventFuture] # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#253 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#254 def zip_futures_on(default_executor, *futures_and_or_events); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#49 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#50 module Concurrent::Promises::FactoryMethods::Configuration # @return [Executor, :io, :fast] the executor which is used when none is supplied # to a factory method. The method can be overridden in the receivers of # `include FactoryMethod` # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#53 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#54 def default_executor; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1830 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1840 class Concurrent::Promises::FlatEventPromise < ::Concurrent::Promises::AbstractFlatPromise # @return [FlatEventPromise] a new instance of FlatEventPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1834 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1844 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1838 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1848 def process_on_blocker_resolution(future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1863 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1873 class Concurrent::Promises::FlatFuturePromise < ::Concurrent::Promises::AbstractFlatPromise # @raise [ArgumentError] # @return [FlatFuturePromise] a new instance of FlatFuturePromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1867 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1877 def initialize(delayed, blockers_count, levels, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1874 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1884 def process_on_blocker_resolution(future, index); end end # Represents a value which will become available in future. May reject with a reason instead, # e.g. when the tasks raises an exception. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#907 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#917 class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # Creates a new event or a future which will be resolved when receiver and other are. # Returns an event if receiver and other are events, otherwise returns a future. @@ -7429,7 +7466,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1060 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1070 def &(other); end # Creates a new event which will be resolved when the first of receiver, `event_or_future` @@ -7438,10 +7475,10 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1075 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1085 def any(event_or_future); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1205 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1215 def apply(args, block); end # Creates new future dependent on receiver which will not evaluate until touched, see {#touch}. @@ -7449,7 +7486,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1085 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1095 def delay; end # Allows rejected Future to be risen with `raise` method. @@ -7461,7 +7498,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @raise [Concurrent::Error] when raising not rejected future # @return [Exception] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1003 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1013 def exception(*args); end # Creates new future which will have result of the future returned by receiver. If receiver @@ -7470,7 +7507,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @param level [Integer] how many levels of futures should flatten # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1110 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1120 def flat(level = T.unsafe(nil)); end # Creates new event which will be resolved when the returned event by receiver is. @@ -7478,7 +7515,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1120 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1130 def flat_event; end # Creates new future which will have result of the future returned by receiver. If receiver @@ -7487,19 +7524,19 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @param level [Integer] how many levels of futures should flatten # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1110 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1120 def flat_future(level = T.unsafe(nil)); end # Is it in fulfilled state? # # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#911 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#921 def fulfilled?; end # @return [String] Short string representation. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1225 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1235 def inspect; end # Shortcut of {#on_fulfillment_using} with default `:io` executor supplied. @@ -7507,19 +7544,19 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @return [self] # @see #on_fulfillment_using # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1126 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1136 def on_fulfillment(*args, &callback); end # Stores the callback to be executed synchronously on resolving thread after it is # fulfilled. Does nothing on rejection. # # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [self] # @yield [value, *args] to the callback. # @yieldreturn is forgotten. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1137 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1147 def on_fulfillment!(*args, &callback); end # Stores the callback to be executed asynchronously on executor after it is @@ -7528,12 +7565,12 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @param executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. The task is executed on it, default executor remains unchanged. # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [self] # @yield [value, *args] to the callback. # @yieldreturn is forgotten. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1149 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1159 def on_fulfillment_using(executor, *args, &callback); end # Shortcut of {#on_rejection_using} with default `:io` executor supplied. @@ -7541,19 +7578,19 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @return [self] # @see #on_rejection_using # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1155 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1165 def on_rejection(*args, &callback); end # Stores the callback to be executed synchronously on resolving thread after it is # rejected. Does nothing on fulfillment. # # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [self] # @yield [reason, *args] to the callback. # @yieldreturn is forgotten. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1166 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1176 def on_rejection!(*args, &callback); end # Stores the callback to be executed asynchronously on executor after it is @@ -7562,12 +7599,12 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @param executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. The task is executed on it, default executor remains unchanged. # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [self] # @yield [reason, *args] to the callback. # @yieldreturn is forgotten. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1178 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1188 def on_rejection_using(executor, *args, &callback); end # Returns reason of future's rejection. @@ -7582,14 +7619,14 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @param timeout_value [Object] a value returned by the method when it times out # @return [Object, timeout_value] the reason, or timeout_value on timeout, or nil on fulfillment. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#956 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#966 def reason(timeout = T.unsafe(nil), timeout_value = T.unsafe(nil)); end # Is it in rejected state? # # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#918 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#928 def rejected?; end # Shortcut of {#rescue_on} with default `:io` executor supplied. @@ -7597,7 +7634,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @return [Future] # @see #rescue_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1042 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1052 def rescue(*args, &task); end # Chains the task to be executed asynchronously on executor after it rejects. Does not run @@ -7606,14 +7643,14 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @param executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. The task is executed on it, default executor remains unchanged. # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [Future] # @yield [reason, *args] to the task. # @yieldreturn will become result of the returned Future. # Its returned value becomes {Future#value} fulfilling it, # raised exception becomes {Future#reason} rejecting it. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1054 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1064 def rescue_on(executor, *args, &task); end # Returns triplet fulfilled?, value, reason. @@ -7625,7 +7662,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @return [Array(Boolean, Object, Object), nil] triplet of fulfilled?, value, reason, or nil # on timeout. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#971 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#981 def result(timeout = T.unsafe(nil)); end # Allows to use futures as green threads. The receiver has to evaluate to a future which @@ -7646,7 +7683,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # which is suppose to continue running. # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1200 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1210 def run(run_test = T.unsafe(nil)); end # Creates new event dependent on receiver scheduled to execute on/in intended_time. @@ -7657,7 +7694,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # `Time` means to run on `intended_time`. # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1092 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1102 def schedule(intended_time); end # Shortcut of {#then_on} with default `:io` executor supplied. @@ -7665,7 +7702,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @return [Future] # @see #then_on # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1024 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1034 def then(*args, &task); end # Chains the task to be executed asynchronously on executor after it fulfills. Does not run @@ -7674,33 +7711,33 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @param executor [Executor, :io, :fast] Instance of an executor or a name of the # global executor. The task is executed on it, default executor remains unchanged. # @param args [Object] arguments which are passed to the task when it's executed. - # (It might be prepended with other arguments, see the @yeild section). + # (It might be prepended with other arguments, see the @yield section). # @return [Future] # @yield [value, *args] to the task. # @yieldreturn will become result of the returned Future. # Its returned value becomes {Future#value} fulfilling it, # raised exception becomes {Future#reason} rejecting it. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1036 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1046 def then_on(executor, *args, &task); end # Converts future to event which is resolved when future is resolved by fulfillment or rejection. # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1212 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1222 def to_event; end # Returns self, since this is a future # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1220 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1230 def to_future; end # @return [String] Short string representation. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1225 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1235 def to_s; end # Return value of the future. @@ -7717,7 +7754,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # timeout_value on timeout, # nil on rejection. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#940 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#950 def value(timeout = T.unsafe(nil), timeout_value = T.unsafe(nil)); end # Return value of the future. @@ -7735,7 +7772,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # or nil on rejection, # or timeout_value on timeout. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#987 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#997 def value!(timeout = T.unsafe(nil), timeout_value = T.unsafe(nil)); end # Wait (block the Thread) until receiver is {#resolved?}. @@ -7748,7 +7785,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # @return [self, true, false] self implies timeout was not used, true implies timeout was used # and it was resolved, false implies it was not resolved within timeout. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#977 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#987 def wait!(timeout = T.unsafe(nil)); end # Crates new object with same class with the executor set as its new default executor. @@ -7756,7 +7793,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1101 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1111 def with_default_executor(executor); end # Creates a new event or a future which will be resolved when receiver and other are. @@ -7767,7 +7804,7 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1060 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1070 def zip(other); end # Creates a new event which will be resolved when the first of receiver, `event_or_future` @@ -7776,253 +7813,253 @@ class Concurrent::Promises::Future < ::Concurrent::Promises::AbstractEventFuture # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1075 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1085 def |(event_or_future); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1262 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1272 def async_callback_on_fulfillment(state, executor, args, callback); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1268 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1278 def async_callback_on_rejection(state, executor, args, callback); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1274 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1284 def callback_on_fulfillment(state, args, callback); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1278 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1288 def callback_on_rejection(state, args, callback); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1282 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1292 def callback_on_resolution(state, args, callback); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1241 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1251 def rejected_resolution(raise_on_reassign, state); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1237 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1247 def run_test(v); end # @raise [self] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1256 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1266 def wait_until_resolved!(timeout = T.unsafe(nil)); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1974 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1984 class Concurrent::Promises::FutureWrapperPromise < ::Concurrent::Promises::BlockedPromise # @return [FutureWrapperPromise] a new instance of FutureWrapperPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1975 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1985 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1981 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1991 def on_resolvable(resolved_future, index); end end # will be immediately resolved # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1773 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1783 class Concurrent::Promises::ImmediateEventPromise < ::Concurrent::Promises::InnerPromise # @return [ImmediateEventPromise] a new instance of ImmediateEventPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1774 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1784 def initialize(default_executor); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1779 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1789 class Concurrent::Promises::ImmediateFuturePromise < ::Concurrent::Promises::InnerPromise # @return [ImmediateFuturePromise] a new instance of ImmediateFuturePromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1780 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1790 def initialize(default_executor, fulfilled, value, reason); end end # @abstract # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1605 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1615 class Concurrent::Promises::InnerPromise < ::Concurrent::Promises::AbstractPromise; end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#337 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#338 module Concurrent::Promises::InternalStates; end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#396 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#397 class Concurrent::Promises::InternalStates::Fulfilled < ::Concurrent::Promises::InternalStates::ResolvedWithResult # @return [Fulfilled] a new instance of Fulfilled # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#398 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#399 def initialize(value); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#406 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#407 def apply(args, block); end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#402 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#403 def fulfilled?; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#414 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#415 def reason; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#418 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#419 def to_sym; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#410 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#411 def value; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#424 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#425 class Concurrent::Promises::InternalStates::FulfilledArray < ::Concurrent::Promises::InternalStates::Fulfilled - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#425 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#426 def apply(args, block); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#487 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#488 Concurrent::Promises::InternalStates::PENDING = T.let(T.unsafe(nil), Concurrent::Promises::InternalStates::Pending) -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#458 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#459 class Concurrent::Promises::InternalStates::PartiallyRejected < ::Concurrent::Promises::InternalStates::ResolvedWithResult # @return [PartiallyRejected] a new instance of PartiallyRejected # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#459 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#460 def initialize(value, reason); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#481 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#482 def apply(args, block); end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#465 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#466 def fulfilled?; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#477 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#478 def reason; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#469 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#470 def to_sym; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#473 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#474 def value; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#350 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#351 class Concurrent::Promises::InternalStates::Pending < ::Concurrent::Promises::InternalStates::State # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#351 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#352 def resolved?; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#355 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#356 def to_sym; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#489 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#490 Concurrent::Promises::InternalStates::RESERVED = T.let(T.unsafe(nil), Concurrent::Promises::InternalStates::Reserved) -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#491 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#492 Concurrent::Promises::InternalStates::RESOLVED = T.let(T.unsafe(nil), Concurrent::Promises::InternalStates::Fulfilled) -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#431 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#432 class Concurrent::Promises::InternalStates::Rejected < ::Concurrent::Promises::InternalStates::ResolvedWithResult # @return [Rejected] a new instance of Rejected # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#432 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#433 def initialize(reason); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#452 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#453 def apply(args, block); end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#436 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#437 def fulfilled?; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#444 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#445 def reason; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#448 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#449 def to_sym; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#440 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#441 def value; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#361 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#362 class Concurrent::Promises::InternalStates::Reserved < ::Concurrent::Promises::InternalStates::Pending; end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#365 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#366 class Concurrent::Promises::InternalStates::ResolvedWithResult < ::Concurrent::Promises::InternalStates::State # @raise [NotImplementedError] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#390 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#391 def apply; end # @raise [NotImplementedError] # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#378 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#379 def fulfilled?; end # @raise [NotImplementedError] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#386 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#387 def reason; end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#366 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#367 def resolved?; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#374 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#375 def result; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#370 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#371 def to_sym; end # @raise [NotImplementedError] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#382 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#383 def value; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#339 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#340 class Concurrent::Promises::InternalStates::State # @raise [NotImplementedError] # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#340 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#341 def resolved?; end # @raise [NotImplementedError] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#344 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#345 def to_sym; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1738 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1748 class Concurrent::Promises::RescuePromise < ::Concurrent::Promises::BlockedTaskPromise # @return [RescuePromise] a new instance of RescuePromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1741 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1751 def initialize(delayed, blockers_count, default_executor, executor, args, &task); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1745 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1755 def on_resolvable(resolved_future, index); end end # Marker module of Future, Event resolved manually. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1289 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1299 module Concurrent::Promises::Resolvable include ::Concurrent::Promises::InternalStates end # A Event which can be resolved by user. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1294 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1304 class Concurrent::Promises::ResolvableEvent < ::Concurrent::Promises::Event include ::Concurrent::Promises::Resolvable @@ -8035,7 +8072,7 @@ class Concurrent::Promises::ResolvableEvent < ::Concurrent::Promises::Event # @return [self, false] false is returned when raise_on_reassign is false and the receiver # is already resolved. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1314 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1324 def resolve(raise_on_reassign = T.unsafe(nil), reserved = T.unsafe(nil)); end # Behaves as {AbstractEventFuture#wait} but has one additional optional argument @@ -8045,28 +8082,28 @@ class Concurrent::Promises::ResolvableEvent < ::Concurrent::Promises::Event # @return [self, true, false] # @see AbstractEventFuture#wait # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1332 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1342 def wait(timeout = T.unsafe(nil), resolve_on_timeout = T.unsafe(nil)); end # Creates new event wrapping receiver, effectively hiding the resolve method. # # @return [Event] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1321 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1331 def with_hidden_resolvable; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1590 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1600 class Concurrent::Promises::ResolvableEventPromise < ::Concurrent::Promises::AbstractPromise # @return [ResolvableEventPromise] a new instance of ResolvableEventPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1591 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1601 def initialize(default_executor); end end # A Future which can be resolved by user. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1344 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1354 class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future include ::Concurrent::Promises::Resolvable @@ -8077,7 +8114,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @yield [*args] to the block. # @yieldreturn [Object] value # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1385 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1395 def evaluate_to(*args, &block); end # Evaluates the block and sets its result as future's value fulfilling, if the block raises @@ -8088,7 +8125,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @yield [*args] to the block. # @yieldreturn [Object] value # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1396 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1406 def evaluate_to!(*args, &block); end # Makes the future fulfilled with `value`, @@ -8102,7 +8139,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [self, false] false is returned when raise_on_reassign is false and the receiver # is already resolved. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1365 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1375 def fulfill(value, raise_on_reassign = T.unsafe(nil), reserved = T.unsafe(nil)); end # Behaves as {Future#reason} but has one additional optional argument @@ -8113,7 +8150,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [Exception, timeout_value, nil] # @see Future#reason # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1493 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1503 def reason(timeout = T.unsafe(nil), timeout_value = T.unsafe(nil), resolve_on_timeout = T.unsafe(nil)); end # Makes the future rejected with `reason`, @@ -8127,7 +8164,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [self, false] false is returned when raise_on_reassign is false and the receiver # is already resolved. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1375 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1385 def reject(reason, raise_on_reassign = T.unsafe(nil), reserved = T.unsafe(nil)); end # Makes the future resolved with result of triplet `fulfilled?`, `value`, `reason`, @@ -8143,7 +8180,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [self, false] false is returned when raise_on_reassign is false and the receiver # is already resolved. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1355 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1365 def resolve(fulfilled = T.unsafe(nil), value = T.unsafe(nil), reason = T.unsafe(nil), raise_on_reassign = T.unsafe(nil), reserved = T.unsafe(nil)); end # Behaves as {Future#result} but has one additional optional argument @@ -8154,7 +8191,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [::Array(Boolean, Object, Exception), nil] # @see Future#result # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1514 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1524 def result(timeout = T.unsafe(nil), resolve_on_timeout = T.unsafe(nil)); end # Behaves as {Future#value} but has one additional optional argument @@ -8165,7 +8202,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [Object, timeout_value, nil] # @see Future#value # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1449 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1459 def value(timeout = T.unsafe(nil), timeout_value = T.unsafe(nil), resolve_on_timeout = T.unsafe(nil)); end # Behaves as {Future#value!} but has one additional optional argument @@ -8177,7 +8214,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [Object, timeout_value, nil] # @see Future#value! # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1471 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1481 def value!(timeout = T.unsafe(nil), timeout_value = T.unsafe(nil), resolve_on_timeout = T.unsafe(nil)); end # Behaves as {AbstractEventFuture#wait} but has one additional optional argument @@ -8188,7 +8225,7 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [self, true, false] # @see AbstractEventFuture#wait # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1411 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1421 def wait(timeout = T.unsafe(nil), resolve_on_timeout = T.unsafe(nil)); end # Behaves as {Future#wait!} but has one additional optional argument @@ -8200,123 +8237,123 @@ class Concurrent::Promises::ResolvableFuture < ::Concurrent::Promises::Future # @return [self, true, false] # @see Future#wait! # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1428 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1438 def wait!(timeout = T.unsafe(nil), resolve_on_timeout = T.unsafe(nil)); end # Creates new future wrapping receiver, effectively hiding the resolve method and similar. # # @return [Future] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1532 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1542 def with_hidden_resolvable; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1596 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1606 class Concurrent::Promises::ResolvableFuturePromise < ::Concurrent::Promises::AbstractPromise # @return [ResolvableFuturePromise] a new instance of ResolvableFuturePromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1597 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1607 def initialize(default_executor); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1582 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1592 def evaluate_to(*args, block); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1899 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1909 class Concurrent::Promises::RunFuturePromise < ::Concurrent::Promises::AbstractFlatPromise # @return [RunFuturePromise] a new instance of RunFuturePromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1903 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1913 def initialize(delayed, blockers_count, default_executor, run_test); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1908 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1918 def process_on_blocker_resolution(future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2104 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2114 class Concurrent::Promises::ScheduledPromise < ::Concurrent::Promises::InnerPromise # @return [ScheduledPromise] a new instance of ScheduledPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2115 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2125 def initialize(default_executor, intended_time); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2109 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2119 def inspect; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2105 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2115 def intended_time; end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1720 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1730 class Concurrent::Promises::ThenPromise < ::Concurrent::Promises::BlockedTaskPromise # @return [ThenPromise] a new instance of ThenPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1723 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1733 def initialize(delayed, blockers_count, default_executor, executor, args, &task); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1727 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1737 def on_resolvable(resolved_future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1930 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1940 class Concurrent::Promises::ZipEventEventPromise < ::Concurrent::Promises::BlockedPromise # @return [ZipEventEventPromise] a new instance of ZipEventEventPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1931 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1941 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1937 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1947 def on_resolvable(resolved_future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2021 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2031 class Concurrent::Promises::ZipEventsPromise < ::Concurrent::Promises::BlockedPromise # @return [ZipEventsPromise] a new instance of ZipEventsPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2025 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2035 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2031 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2041 def on_resolvable(resolved_future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1942 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1952 class Concurrent::Promises::ZipFutureEventPromise < ::Concurrent::Promises::BlockedPromise # @return [ZipFutureEventPromise] a new instance of ZipFutureEventPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1943 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1953 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1957 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1967 def on_resolvable(resolved_future, index); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1950 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1960 def process_on_blocker_resolution(future, index); end end -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1986 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1996 class Concurrent::Promises::ZipFuturesPromise < ::Concurrent::Promises::BlockedPromise # @return [ZipFuturesPromise] a new instance of ZipFuturesPromise # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1990 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2000 def initialize(delayed, blockers_count, default_executor); end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2003 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2013 def on_resolvable(resolved_future, index); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#1997 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/promises.rb#2007 def process_on_blocker_resolution(future, index); end end @@ -8926,11 +8963,18 @@ class Concurrent::RubyThreadPoolExecutor < ::Concurrent::RubyExecutorService # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#45 def initialize(opts = T.unsafe(nil)); end + # The number of threads that are actively executing tasks. + # + # @return [Integer] The number of threads that are actively executing tasks. + # + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#65 + def active_count; end + # Does the task queue have a maximum size? # # @return [Boolean] True if the task queue has a maximum size else false. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#65 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#72 def can_overflow?; end # The number of tasks that have been completed by the pool since construction. @@ -8958,7 +9002,7 @@ class Concurrent::RubyThreadPoolExecutor < ::Concurrent::RubyExecutorService # # @return [Integer] The number of threads currently in the pool. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#70 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#77 def length; end # The maximum number of threads that may be created in the pool. @@ -8996,17 +9040,17 @@ class Concurrent::RubyThreadPoolExecutor < ::Concurrent::RubyExecutorService # this method explicitely in case your application post jobs in bursts (a # lot of jobs and then nothing for long periods) # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#111 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#118 def prune_pool; end # The number of tasks in the queue awaiting execution. # # @return [Integer] The number of tasks in the queue awaiting execution. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#75 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#82 def queue_length; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#96 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#103 def ready_worker(worker, last_message); end # Number of tasks that may be enqueued before reaching `max_queue` and rejecting @@ -9015,10 +9059,10 @@ class Concurrent::RubyThreadPoolExecutor < ::Concurrent::RubyExecutorService # @return [Integer] Number of tasks that may be enqueued before reaching `max_queue` and rejecting # new tasks. A value of -1 indicates that the queue may grow without bound. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#80 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#87 def remaining_capacity; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#91 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#98 def remove_busy_worker(worker); end # The number of tasks that have been scheduled for execution on the pool since construction. @@ -9035,10 +9079,10 @@ class Concurrent::RubyThreadPoolExecutor < ::Concurrent::RubyExecutorService # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#42 def synchronous; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#101 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#108 def worker_died(worker); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#106 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#113 def worker_task_completed; end private @@ -9047,61 +9091,61 @@ class Concurrent::RubyThreadPoolExecutor < ::Concurrent::RubyExecutorService # # @return [nil, Worker] nil of max capacity is reached # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#234 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#241 def ns_add_busy_worker; end # tries to assign task to a worker, tries to get one from @ready or to create new one # # @return [true, false] if task is assigned to a worker # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#194 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#201 def ns_assign_worker(*args, &task); end # tries to enqueue task # # @return [true, false] if enqueued # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#212 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#219 def ns_enqueue(*args, &task); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#153 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#160 def ns_execute(*args, &task); end # @raise [ArgumentError] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#118 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#125 def ns_initialize(opts); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#182 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#189 def ns_kill_execution; end # @return [Boolean] # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#148 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#155 def ns_limited_queue?; end # try oldest worker if it is idle for enough time, it's returned back at the start # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#273 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#280 def ns_prune_pool; end # handle ready worker, giving it new job or assigning back to @ready # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#246 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#253 def ns_ready_worker(worker, last_message, success = T.unsafe(nil)); end # removes a worker which is not in not tracked in @ready # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#264 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#271 def ns_remove_busy_worker(worker); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#289 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#296 def ns_reset_if_forked; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#167 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#174 def ns_shutdown_execution; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#224 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#231 def ns_worker_died(worker); end end @@ -9131,31 +9175,31 @@ Concurrent::RubyThreadPoolExecutor::DEFAULT_SYNCHRONOUS = T.let(T.unsafe(nil), F # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#24 Concurrent::RubyThreadPoolExecutor::DEFAULT_THREAD_IDLETIMEOUT = T.let(T.unsafe(nil), Integer) -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#303 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#310 class Concurrent::RubyThreadPoolExecutor::Worker include ::Logger::Severity include ::Concurrent::Concern::Logging # @return [Worker] a new instance of Worker # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#306 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#313 def initialize(pool, id); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#317 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#324 def <<(message); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#325 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#332 def kill; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#321 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#328 def stop; end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#331 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#338 def create_worker(queue, pool, idletime); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#351 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_thread_pool_executor.rb#358 def run_task(pool, task, args); end end @@ -11010,6 +11054,17 @@ end # be tested separately then passed to the `TimerTask` for scheduling and # running. # +# A `TimerTask` supports two different types of interval calculations. +# A fixed delay will always wait the same amount of time between the +# completion of one task and the start of the next. A fixed rate will +# attempt to maintain a constant rate of execution regardless of the +# duration of the task. For example, if a fixed rate task is scheduled +# to run every 60 seconds but the task itself takes 10 seconds to +# complete, the next task will be scheduled to run 50 seconds after +# the start of the previous task. If the task takes 70 seconds to +# complete, the next task will be start immediately after the previous +# task completes. Tasks will not be executed concurrently. +# # In some cases it may be necessary for a `TimerTask` to affect its own # execution cycle. To facilitate this, a reference to the TimerTask instance # is passed as an argument to the provided block every time the task is @@ -11047,6 +11102,11 @@ end # task.execute # # #=> 'Boom!' +# @example Configuring `:interval_type` with either :fixed_delay or :fixed_rate, default is :fixed_delay +# task = Concurrent::TimerTask.new(execution_interval: 5, interval_type: :fixed_rate) do +# puts 'Boom!' +# end +# task.interval_type #=> :fixed_rate # @example Last `#value` and `Dereferenceable` mixin # task = Concurrent::TimerTask.new( # dup_on_deref: true, @@ -11059,7 +11119,7 @@ end # task.value #=> 2013-11-07 18:06:55 -0500 # @example Controlling execution from within the block # timer_task = Concurrent::TimerTask.new(execution_interval: 1) do |task| -# task.execution_interval.times{ print 'Boom! ' } +# task.execution_interval.to_i.times{ print 'Boom! ' } # print "\n" # task.execution_interval += 1 # if task.execution_interval > 5 @@ -11068,7 +11128,7 @@ end # end # end # -# timer_task.execute # blocking call - this task will stop itself +# timer_task.execute # #=> Boom! # #=> Boom! Boom! # #=> Boom! Boom! Boom! @@ -11116,7 +11176,7 @@ end # @see http://ruby-doc.org/stdlib-2.0/libdoc/observer/rdoc/Observable.html # @see http://docs.oracle.com/javase/7/docs/api/java/util/TimerTask.html # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#148 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#165 class Concurrent::TimerTask < ::Concurrent::RubyExecutorService include ::Concurrent::Concern::Dereferenceable include ::Concurrent::Concern::Observable @@ -11125,6 +11185,7 @@ class Concurrent::TimerTask < ::Concurrent::RubyExecutorService # # @option opts # @option opts + # @option opts # @param opts [Hash] the options defining task execution. # @raise ArgumentError when no block is given. # @return [TimerTask] the new `TimerTask` @@ -11135,7 +11196,7 @@ class Concurrent::TimerTask < ::Concurrent::RubyExecutorService # refer to the execution context of the block rather than the running # `TimerTask`. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#180 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#209 def initialize(opts = T.unsafe(nil), &task); end # Execute a previously created `TimerTask`. @@ -11150,38 +11211,43 @@ class Concurrent::TimerTask < ::Concurrent::RubyExecutorService # task.running? #=> true # @return [TimerTask] a reference to `self` # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#206 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#235 def execute; end # @return [Fixnum] Number of seconds after the task completes before the # task is performed again. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#230 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#259 def execution_interval; end # @return [Fixnum] Number of seconds after the task completes before the # task is performed again. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#237 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#266 def execution_interval=(value); end + # @return [Symbol] method to calculate the interval between executions + # + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#276 + def interval_type; end + # Is the executor running? # # @return [Boolean] `true` when running, `false` when shutting down or shutdown # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#189 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#218 def running?; end # @return [Fixnum] Number of seconds the task can run before it is # considered to have failed. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#248 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#281 def timeout_interval; end # @return [Fixnum] Number of seconds the task can run before it is # considered to have failed. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#255 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#288 def timeout_interval=(value); end private @@ -11189,22 +11255,25 @@ class Concurrent::TimerTask < ::Concurrent::RubyExecutorService # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/executor_service.rb#166 def <<(task); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#297 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#352 + def calculate_next_interval(start_time); end + + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#336 def execute_task(completion); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#263 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#296 def ns_initialize(opts, &task); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#285 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#324 def ns_kill_execution; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#279 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#318 def ns_shutdown_execution; end # source://concurrent-ruby//lib/concurrent-ruby/concurrent/executor/ruby_executor_service.rb#17 def post(*args, &task); end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#291 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#330 def schedule_next_task(interval = T.unsafe(nil)); end class << self @@ -11215,6 +11284,7 @@ class Concurrent::TimerTask < ::Concurrent::RubyExecutorService # task.running? #=> true # @option opts # @option opts + # @option opts # @param opts [Hash] the options defining task execution. # @raise ArgumentError when no block is given. # @return [TimerTask] the new `TimerTask` @@ -11225,20 +11295,32 @@ class Concurrent::TimerTask < ::Concurrent::RubyExecutorService # refer to the execution context of the block rather than the running # `TimerTask`. # - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#223 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#252 def execute(opts = T.unsafe(nil), &task); end end end +# Default `:interval_type` +# +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#181 +Concurrent::TimerTask::DEFAULT_INTERVAL_TYPE = T.let(T.unsafe(nil), Symbol) + # Default `:execution_interval` in seconds. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#153 +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#170 Concurrent::TimerTask::EXECUTION_INTERVAL = T.let(T.unsafe(nil), Integer) -# Default `:timeout_interval` in seconds. +# Maintain the interval between the end of one execution and the start of the next execution. +# +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#173 +Concurrent::TimerTask::FIXED_DELAY = T.let(T.unsafe(nil), Symbol) + +# Maintain the interval between the start of one execution and the start of the next. +# If execution time exceeds the interval, the next execution will start immediately +# after the previous execution finishes. Executions will not run concurrently. # -# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#156 -Concurrent::TimerTask::TIMEOUT_INTERVAL = T.let(T.unsafe(nil), Integer) +# source://concurrent-ruby//lib/concurrent-ruby/concurrent/timer_task.rb#178 +Concurrent::TimerTask::FIXED_RATE = T.let(T.unsafe(nil), Symbol) # source://concurrent-ruby//lib/concurrent-ruby/concurrent/tvar.rb#153 class Concurrent::Transaction @@ -11526,19 +11608,37 @@ class Concurrent::Utility::ProcessorCounter # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#11 def initialize; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#20 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#26 + def available_processor_count; end + + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#41 + def cpu_quota; end + + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#45 + def cpu_shares; end + + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#22 def physical_processor_count; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#16 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#18 def processor_count; end private - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#34 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#104 + def compute_cpu_quota; end + + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#124 + def compute_cpu_shares; end + + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#59 def compute_physical_processor_count; end - # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#26 + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#51 def compute_processor_count; end + + # source://concurrent-ruby//lib/concurrent-ruby/concurrent/utility/processor_counter.rb#99 + def run(command); end end # source://concurrent-ruby//lib/concurrent-ruby/concurrent/version.rb#2 diff --git a/sorbet/rbi/gems/connection_pool@2.4.1.rbi b/sorbet/rbi/gems/connection_pool@2.4.1.rbi index 09e29ca41..f0730c7d8 100644 --- a/sorbet/rbi/gems/connection_pool@2.4.1.rbi +++ b/sorbet/rbi/gems/connection_pool@2.4.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `connection_pool` gem. # Please instead update this file by running `bin/tapioca gem connection_pool`. + # Generic connection pool class for sharing a limited number of objects or network connections # among many threads. Note: pool elements are lazily created. # @@ -269,5 +270,6 @@ ConnectionPool::Wrapper::METHODS = T.let(T.unsafe(nil), Array) module Process extend ::ConnectionPool::ForkTracker - extend ::ActiveSupport::ForkTracker::ModernCoreExt + extend ::RedisClient::PIDCache::CoreExt + extend ::ActiveSupport::ForkTracker::CoreExt end diff --git a/sorbet/rbi/gems/coveralls@0.8.23.rbi b/sorbet/rbi/gems/coveralls@0.8.23.rbi index 5db169b37..ab3729fad 100644 --- a/sorbet/rbi/gems/coveralls@0.8.23.rbi +++ b/sorbet/rbi/gems/coveralls@0.8.23.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `coveralls` gem. # Please instead update this file by running `bin/tapioca gem coveralls`. + # source://coveralls//lib/coveralls/version.rb#1 module Coveralls extend ::Coveralls diff --git a/sorbet/rbi/gems/crack@0.4.5.rbi b/sorbet/rbi/gems/crack@1.0.0.rbi similarity index 99% rename from sorbet/rbi/gems/crack@0.4.5.rbi rename to sorbet/rbi/gems/crack@1.0.0.rbi index e248ecc64..9e1f7b094 100644 --- a/sorbet/rbi/gems/crack@0.4.5.rbi +++ b/sorbet/rbi/gems/crack@1.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `crack` gem. # Please instead update this file by running `bin/tapioca gem crack`. + # source://crack//lib/crack/xml.rb#196 module Crack; end diff --git a/sorbet/rbi/gems/crass@1.0.6.rbi b/sorbet/rbi/gems/crass@1.0.6.rbi index 4d267c089..0979e2f46 100644 --- a/sorbet/rbi/gems/crass@1.0.6.rbi +++ b/sorbet/rbi/gems/crass@1.0.6.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `crass` gem. # Please instead update this file by running `bin/tapioca gem crass`. + # A CSS parser based on the CSS Syntax Module Level 3 spec. # # source://crass//lib/crass/token-scanner.rb#3 diff --git a/sorbet/rbi/gems/csv@3.3.0.rbi b/sorbet/rbi/gems/csv@3.3.0.rbi new file mode 100644 index 000000000..fcafb7d2d --- /dev/null +++ b/sorbet/rbi/gems/csv@3.3.0.rbi @@ -0,0 +1,4696 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `csv` gem. +# Please instead update this file by running `bin/tapioca gem csv`. + + +# source://csv//lib/csv/core_ext/array.rb#1 +class Array + include ::Enumerable + + # Equivalent to CSV::generate_line(self, options) + # + # ["CSV", "data"].to_csv + # #=> "CSV,data\n" + # + # source://csv//lib/csv/core_ext/array.rb#6 + def to_csv(**options); end +end + +# == \CSV +# +# === \CSV Data +# +# \CSV (comma-separated values) data is a text representation of a table: +# - A _row_ _separator_ delimits table rows. +# A common row separator is the newline character "\n". +# - A _column_ _separator_ delimits fields in a row. +# A common column separator is the comma character ",". +# +# This \CSV \String, with row separator "\n" +# and column separator ",", +# has three rows and two columns: +# "foo,0\nbar,1\nbaz,2\n" +# +# Despite the name \CSV, a \CSV representation can use different separators. +# +# For more about tables, see the Wikipedia article +# "{Table (information)}[https://en.wikipedia.org/wiki/Table_(information)]", +# especially its section +# "{Simple table}[https://en.wikipedia.org/wiki/Table_(information)#Simple_table]" +# +# == \Class \CSV +# +# Class \CSV provides methods for: +# - Parsing \CSV data from a \String object, a \File (via its file path), or an \IO object. +# - Generating \CSV data to a \String object. +# +# To make \CSV available: +# require 'csv' +# +# All examples here assume that this has been done. +# +# == Keeping It Simple +# +# A \CSV object has dozens of instance methods that offer fine-grained control +# of parsing and generating \CSV data. +# For many needs, though, simpler approaches will do. +# +# This section summarizes the singleton methods in \CSV +# that allow you to parse and generate without explicitly +# creating \CSV objects. +# For details, follow the links. +# +# === Simple Parsing +# +# Parsing methods commonly return either of: +# - An \Array of Arrays of Strings: +# - The outer \Array is the entire "table". +# - Each inner \Array is a row. +# - Each \String is a field. +# - A CSV::Table object. For details, see +# {\CSV with Headers}[#class-CSV-label-CSV+with+Headers]. +# +# ==== Parsing a \String +# +# The input to be parsed can be a string: +# string = "foo,0\nbar,1\nbaz,2\n" +# +# \Method CSV.parse returns the entire \CSV data: +# CSV.parse(string) # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# \Method CSV.parse_line returns only the first row: +# CSV.parse_line(string) # => ["foo", "0"] +# +# \CSV extends class \String with instance method String#parse_csv, +# which also returns only the first row: +# string.parse_csv # => ["foo", "0"] +# +# ==== Parsing Via a \File Path +# +# The input to be parsed can be in a file: +# string = "foo,0\nbar,1\nbaz,2\n" +# path = 't.csv' +# File.write(path, string) +# +# \Method CSV.read returns the entire \CSV data: +# CSV.read(path) # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# \Method CSV.foreach iterates, passing each row to the given block: +# CSV.foreach(path) do |row| +# p row +# end +# Output: +# ["foo", "0"] +# ["bar", "1"] +# ["baz", "2"] +# +# \Method CSV.table returns the entire \CSV data as a CSV::Table object: +# CSV.table(path) # => # +# +# ==== Parsing from an Open \IO Stream +# +# The input to be parsed can be in an open \IO stream: +# +# \Method CSV.read returns the entire \CSV data: +# File.open(path) do |file| +# CSV.read(file) +# end # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# As does method CSV.parse: +# File.open(path) do |file| +# CSV.parse(file) +# end # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# \Method CSV.parse_line returns only the first row: +# File.open(path) do |file| +# CSV.parse_line(file) +# end # => ["foo", "0"] +# +# \Method CSV.foreach iterates, passing each row to the given block: +# File.open(path) do |file| +# CSV.foreach(file) do |row| +# p row +# end +# end +# Output: +# ["foo", "0"] +# ["bar", "1"] +# ["baz", "2"] +# +# \Method CSV.table returns the entire \CSV data as a CSV::Table object: +# File.open(path) do |file| +# CSV.table(file) +# end # => # +# +# === Simple Generating +# +# \Method CSV.generate returns a \String; +# this example uses method CSV#<< to append the rows +# that are to be generated: +# output_string = CSV.generate do |csv| +# csv << ['foo', 0] +# csv << ['bar', 1] +# csv << ['baz', 2] +# end +# output_string # => "foo,0\nbar,1\nbaz,2\n" +# +# \Method CSV.generate_line returns a \String containing the single row +# constructed from an \Array: +# CSV.generate_line(['foo', '0']) # => "foo,0\n" +# +# \CSV extends class \Array with instance method Array#to_csv, +# which forms an \Array into a \String: +# ['foo', '0'].to_csv # => "foo,0\n" +# +# === "Filtering" \CSV +# +# \Method CSV.filter provides a Unix-style filter for \CSV data. +# The input data is processed to form the output data: +# in_string = "foo,0\nbar,1\nbaz,2\n" +# out_string = '' +# CSV.filter(in_string, out_string) do |row| +# row[0] = row[0].upcase +# row[1] *= 4 +# end +# out_string # => "FOO,0000\nBAR,1111\nBAZ,2222\n" +# +# == \CSV Objects +# +# There are three ways to create a \CSV object: +# - \Method CSV.new returns a new \CSV object. +# - \Method CSV.instance returns a new or cached \CSV object. +# - \Method \CSV() also returns a new or cached \CSV object. +# +# === Instance Methods +# +# \CSV has three groups of instance methods: +# - Its own internally defined instance methods. +# - Methods included by module Enumerable. +# - Methods delegated to class IO. See below. +# +# ==== Delegated Methods +# +# For convenience, a CSV object will delegate to many methods in class IO. +# (A few have wrapper "guard code" in \CSV.) You may call: +# * IO#binmode +# * #binmode? +# * IO#close +# * IO#close_read +# * IO#close_write +# * IO#closed? +# * #eof +# * #eof? +# * IO#external_encoding +# * IO#fcntl +# * IO#fileno +# * #flock +# * IO#flush +# * IO#fsync +# * IO#internal_encoding +# * #ioctl +# * IO#isatty +# * #path +# * IO#pid +# * IO#pos +# * IO#pos= +# * IO#reopen +# * #rewind +# * IO#seek +# * #stat +# * IO#string +# * IO#sync +# * IO#sync= +# * IO#tell +# * #to_i +# * #to_io +# * IO#truncate +# * IO#tty? +# +# === Options +# +# The default values for options are: +# DEFAULT_OPTIONS = { +# # For both parsing and generating. +# col_sep: ",", +# row_sep: :auto, +# quote_char: '"', +# # For parsing. +# field_size_limit: nil, +# converters: nil, +# unconverted_fields: nil, +# headers: false, +# return_headers: false, +# header_converters: nil, +# skip_blanks: false, +# skip_lines: nil, +# liberal_parsing: false, +# nil_value: nil, +# empty_value: "", +# strip: false, +# # For generating. +# write_headers: nil, +# quote_empty: true, +# force_quotes: false, +# write_converters: nil, +# write_nil_value: nil, +# write_empty_value: "", +# } +# +# ==== Options for Parsing +# +# Options for parsing, described in detail below, include: +# - +row_sep+: Specifies the row separator; used to delimit rows. +# - +col_sep+: Specifies the column separator; used to delimit fields. +# - +quote_char+: Specifies the quote character; used to quote fields. +# - +field_size_limit+: Specifies the maximum field size + 1 allowed. +# Deprecated since 3.2.3. Use +max_field_size+ instead. +# - +max_field_size+: Specifies the maximum field size allowed. +# - +converters+: Specifies the field converters to be used. +# - +unconverted_fields+: Specifies whether unconverted fields are to be available. +# - +headers+: Specifies whether data contains headers, +# or specifies the headers themselves. +# - +return_headers+: Specifies whether headers are to be returned. +# - +header_converters+: Specifies the header converters to be used. +# - +skip_blanks+: Specifies whether blanks lines are to be ignored. +# - +skip_lines+: Specifies how comments lines are to be recognized. +# - +strip+: Specifies whether leading and trailing whitespace are to be +# stripped from fields. This must be compatible with +col_sep+; if it is not, +# then an +ArgumentError+ exception will be raised. +# - +liberal_parsing+: Specifies whether \CSV should attempt to parse +# non-compliant data. +# - +nil_value+: Specifies the object that is to be substituted for each null (no-text) field. +# - +empty_value+: Specifies the object that is to be substituted for each empty field. +# +# :include: ../doc/csv/options/common/row_sep.rdoc +# +# :include: ../doc/csv/options/common/col_sep.rdoc +# +# :include: ../doc/csv/options/common/quote_char.rdoc +# +# :include: ../doc/csv/options/parsing/field_size_limit.rdoc +# +# :include: ../doc/csv/options/parsing/converters.rdoc +# +# :include: ../doc/csv/options/parsing/unconverted_fields.rdoc +# +# :include: ../doc/csv/options/parsing/headers.rdoc +# +# :include: ../doc/csv/options/parsing/return_headers.rdoc +# +# :include: ../doc/csv/options/parsing/header_converters.rdoc +# +# :include: ../doc/csv/options/parsing/skip_blanks.rdoc +# +# :include: ../doc/csv/options/parsing/skip_lines.rdoc +# +# :include: ../doc/csv/options/parsing/strip.rdoc +# +# :include: ../doc/csv/options/parsing/liberal_parsing.rdoc +# +# :include: ../doc/csv/options/parsing/nil_value.rdoc +# +# :include: ../doc/csv/options/parsing/empty_value.rdoc +# +# ==== Options for Generating +# +# Options for generating, described in detail below, include: +# - +row_sep+: Specifies the row separator; used to delimit rows. +# - +col_sep+: Specifies the column separator; used to delimit fields. +# - +quote_char+: Specifies the quote character; used to quote fields. +# - +write_headers+: Specifies whether headers are to be written. +# - +force_quotes+: Specifies whether each output field is to be quoted. +# - +quote_empty+: Specifies whether each empty output field is to be quoted. +# - +write_converters+: Specifies the field converters to be used in writing. +# - +write_nil_value+: Specifies the object that is to be substituted for each +nil+-valued field. +# - +write_empty_value+: Specifies the object that is to be substituted for each empty field. +# +# :include: ../doc/csv/options/common/row_sep.rdoc +# +# :include: ../doc/csv/options/common/col_sep.rdoc +# +# :include: ../doc/csv/options/common/quote_char.rdoc +# +# :include: ../doc/csv/options/generating/write_headers.rdoc +# +# :include: ../doc/csv/options/generating/force_quotes.rdoc +# +# :include: ../doc/csv/options/generating/quote_empty.rdoc +# +# :include: ../doc/csv/options/generating/write_converters.rdoc +# +# :include: ../doc/csv/options/generating/write_nil_value.rdoc +# +# :include: ../doc/csv/options/generating/write_empty_value.rdoc +# +# === \CSV with Headers +# +# CSV allows to specify column names of CSV file, whether they are in data, or +# provided separately. If headers are specified, reading methods return an instance +# of CSV::Table, consisting of CSV::Row. +# +# # Headers are part of data +# data = CSV.parse(<<~ROWS, headers: true) +# Name,Department,Salary +# Bob,Engineering,1000 +# Jane,Sales,2000 +# John,Management,5000 +# ROWS +# +# data.class #=> CSV::Table +# data.first #=> # +# data.first.to_h #=> {"Name"=>"Bob", "Department"=>"Engineering", "Salary"=>"1000"} +# +# # Headers provided by developer +# data = CSV.parse('Bob,Engineering,1000', headers: %i[name department salary]) +# data.first #=> # +# +# === \Converters +# +# By default, each value (field or header) parsed by \CSV is formed into a \String. +# You can use a _field_ _converter_ or _header_ _converter_ +# to intercept and modify the parsed values: +# - See {Field Converters}[#class-CSV-label-Field+Converters]. +# - See {Header Converters}[#class-CSV-label-Header+Converters]. +# +# Also by default, each value to be written during generation is written 'as-is'. +# You can use a _write_ _converter_ to modify values before writing. +# - See {Write Converters}[#class-CSV-label-Write+Converters]. +# +# ==== Specifying \Converters +# +# You can specify converters for parsing or generating in the +options+ +# argument to various \CSV methods: +# - Option +converters+ for converting parsed field values. +# - Option +header_converters+ for converting parsed header values. +# - Option +write_converters+ for converting values to be written (generated). +# +# There are three forms for specifying converters: +# - A converter proc: executable code to be used for conversion. +# - A converter name: the name of a stored converter. +# - A converter list: an array of converter procs, converter names, and converter lists. +# +# ===== Converter Procs +# +# This converter proc, +strip_converter+, accepts a value +field+ +# and returns field.strip: +# strip_converter = proc {|field| field.strip } +# In this call to CSV.parse, +# the keyword argument converters: string_converter +# specifies that: +# - \Proc +string_converter+ is to be called for each parsed field. +# - The converter's return value is to replace the +field+ value. +# Example: +# string = " foo , 0 \n bar , 1 \n baz , 2 \n" +# array = CSV.parse(string, converters: strip_converter) +# array # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# A converter proc can receive a second argument, +field_info+, +# that contains details about the field. +# This modified +strip_converter+ displays its arguments: +# strip_converter = proc do |field, field_info| +# p [field, field_info] +# field.strip +# end +# string = " foo , 0 \n bar , 1 \n baz , 2 \n" +# array = CSV.parse(string, converters: strip_converter) +# array # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# Output: +# [" foo ", #] +# [" 0 ", #] +# [" bar ", #] +# [" 1 ", #] +# [" baz ", #] +# [" 2 ", #] +# Each CSV::FieldInfo object shows: +# - The 0-based field index. +# - The 1-based line index. +# - The field header, if any. +# +# ===== Stored \Converters +# +# A converter may be given a name and stored in a structure where +# the parsing methods can find it by name. +# +# The storage structure for field converters is the \Hash CSV::Converters. +# It has several built-in converter procs: +# - :integer: converts each \String-embedded integer into a true \Integer. +# - :float: converts each \String-embedded float into a true \Float. +# - :date: converts each \String-embedded date into a true \Date. +# - :date_time: converts each \String-embedded date-time into a true \DateTime +# . +# This example creates a converter proc, then stores it: +# strip_converter = proc {|field| field.strip } +# CSV::Converters[:strip] = strip_converter +# Then the parsing method call can refer to the converter +# by its name, :strip: +# string = " foo , 0 \n bar , 1 \n baz , 2 \n" +# array = CSV.parse(string, converters: :strip) +# array # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# The storage structure for header converters is the \Hash CSV::HeaderConverters, +# which works in the same way. +# It also has built-in converter procs: +# - :downcase: Downcases each header. +# - :symbol: Converts each header to a \Symbol. +# +# There is no such storage structure for write headers. +# +# In order for the parsing methods to access stored converters in non-main-Ractors, the +# storage structure must be made shareable first. +# Therefore, Ractor.make_shareable(CSV::Converters) and +# Ractor.make_shareable(CSV::HeaderConverters) must be called before the creation +# of Ractors that use the converters stored in these structures. (Since making the storage +# structures shareable involves freezing them, any custom converters that are to be used +# must be added first.) +# +# ===== Converter Lists +# +# A _converter_ _list_ is an \Array that may include any assortment of: +# - Converter procs. +# - Names of stored converters. +# - Nested converter lists. +# +# Examples: +# numeric_converters = [:integer, :float] +# date_converters = [:date, :date_time] +# [numeric_converters, strip_converter] +# [strip_converter, date_converters, :float] +# +# Like a converter proc, a converter list may be named and stored in either +# \CSV::Converters or CSV::HeaderConverters: +# CSV::Converters[:custom] = [strip_converter, date_converters, :float] +# CSV::HeaderConverters[:custom] = [:downcase, :symbol] +# +# There are two built-in converter lists: +# CSV::Converters[:numeric] # => [:integer, :float] +# CSV::Converters[:all] # => [:date_time, :numeric] +# +# ==== Field \Converters +# +# With no conversion, all parsed fields in all rows become Strings: +# string = "foo,0\nbar,1\nbaz,2\n" +# ary = CSV.parse(string) +# ary # => # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# When you specify a field converter, each parsed field is passed to the converter; +# its return value becomes the stored value for the field. +# A converter might, for example, convert an integer embedded in a \String +# into a true \Integer. +# (In fact, that's what built-in field converter +:integer+ does.) +# +# There are three ways to use field \converters. +# +# - Using option {converters}[#class-CSV-label-Option+converters] with a parsing method: +# ary = CSV.parse(string, converters: :integer) +# ary # => [0, 1, 2] # => [["foo", 0], ["bar", 1], ["baz", 2]] +# - Using option {converters}[#class-CSV-label-Option+converters] with a new \CSV instance: +# csv = CSV.new(string, converters: :integer) +# # Field converters in effect: +# csv.converters # => [:integer] +# csv.read # => [["foo", 0], ["bar", 1], ["baz", 2]] +# - Using method #convert to add a field converter to a \CSV instance: +# csv = CSV.new(string) +# # Add a converter. +# csv.convert(:integer) +# csv.converters # => [:integer] +# csv.read # => [["foo", 0], ["bar", 1], ["baz", 2]] +# +# Installing a field converter does not affect already-read rows: +# csv = CSV.new(string) +# csv.shift # => ["foo", "0"] +# # Add a converter. +# csv.convert(:integer) +# csv.converters # => [:integer] +# csv.read # => [["bar", 1], ["baz", 2]] +# +# There are additional built-in \converters, and custom \converters are also supported. +# +# ===== Built-In Field \Converters +# +# The built-in field converters are in \Hash CSV::Converters: +# - Each key is a field converter name. +# - Each value is one of: +# - A \Proc field converter. +# - An \Array of field converter names. +# +# Display: +# CSV::Converters.each_pair do |name, value| +# if value.kind_of?(Proc) +# p [name, value.class] +# else +# p [name, value] +# end +# end +# Output: +# [:integer, Proc] +# [:float, Proc] +# [:numeric, [:integer, :float]] +# [:date, Proc] +# [:date_time, Proc] +# [:all, [:date_time, :numeric]] +# +# Each of these converters transcodes values to UTF-8 before attempting conversion. +# If a value cannot be transcoded to UTF-8 the conversion will +# fail and the value will remain unconverted. +# +# Converter +:integer+ converts each field that Integer() accepts: +# data = '0,1,2,x' +# # Without the converter +# csv = CSV.parse_line(data) +# csv # => ["0", "1", "2", "x"] +# # With the converter +# csv = CSV.parse_line(data, converters: :integer) +# csv # => [0, 1, 2, "x"] +# +# Converter +:float+ converts each field that Float() accepts: +# data = '1.0,3.14159,x' +# # Without the converter +# csv = CSV.parse_line(data) +# csv # => ["1.0", "3.14159", "x"] +# # With the converter +# csv = CSV.parse_line(data, converters: :float) +# csv # => [1.0, 3.14159, "x"] +# +# Converter +:numeric+ converts with both +:integer+ and +:float+.. +# +# Converter +:date+ converts each field that Date::parse accepts: +# data = '2001-02-03,x' +# # Without the converter +# csv = CSV.parse_line(data) +# csv # => ["2001-02-03", "x"] +# # With the converter +# csv = CSV.parse_line(data, converters: :date) +# csv # => [#, "x"] +# +# Converter +:date_time+ converts each field that DateTime::parse accepts: +# data = '2020-05-07T14:59:00-05:00,x' +# # Without the converter +# csv = CSV.parse_line(data) +# csv # => ["2020-05-07T14:59:00-05:00", "x"] +# # With the converter +# csv = CSV.parse_line(data, converters: :date_time) +# csv # => [#, "x"] +# +# Converter +:numeric+ converts with both +:date_time+ and +:numeric+.. +# +# As seen above, method #convert adds \converters to a \CSV instance, +# and method #converters returns an \Array of the \converters in effect: +# csv = CSV.new('0,1,2') +# csv.converters # => [] +# csv.convert(:integer) +# csv.converters # => [:integer] +# csv.convert(:date) +# csv.converters # => [:integer, :date] +# +# ===== Custom Field \Converters +# +# You can define a custom field converter: +# strip_converter = proc {|field| field.strip } +# string = " foo , 0 \n bar , 1 \n baz , 2 \n" +# array = CSV.parse(string, converters: strip_converter) +# array # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# You can register the converter in \Converters \Hash, +# which allows you to refer to it by name: +# CSV::Converters[:strip] = strip_converter +# string = " foo , 0 \n bar , 1 \n baz , 2 \n" +# array = CSV.parse(string, converters: :strip) +# array # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] +# +# ==== Header \Converters +# +# Header converters operate only on headers (and not on other rows). +# +# There are three ways to use header \converters; +# these examples use built-in header converter +:downcase+, +# which downcases each parsed header. +# +# - Option +header_converters+ with a singleton parsing method: +# string = "Name,Count\nFoo,0\n,Bar,1\nBaz,2" +# tbl = CSV.parse(string, headers: true, header_converters: :downcase) +# tbl.class # => CSV::Table +# tbl.headers # => ["name", "count"] +# +# - Option +header_converters+ with a new \CSV instance: +# csv = CSV.new(string, header_converters: :downcase) +# # Header converters in effect: +# csv.header_converters # => [:downcase] +# tbl = CSV.parse(string, headers: true) +# tbl.headers # => ["Name", "Count"] +# +# - Method #header_convert adds a header converter to a \CSV instance: +# csv = CSV.new(string) +# # Add a header converter. +# csv.header_convert(:downcase) +# csv.header_converters # => [:downcase] +# tbl = CSV.parse(string, headers: true) +# tbl.headers # => ["Name", "Count"] +# +# ===== Built-In Header \Converters +# +# The built-in header \converters are in \Hash CSV::HeaderConverters. +# The keys there are the names of the \converters: +# CSV::HeaderConverters.keys # => [:downcase, :symbol] +# +# Converter +:downcase+ converts each header by downcasing it: +# string = "Name,Count\nFoo,0\n,Bar,1\nBaz,2" +# tbl = CSV.parse(string, headers: true, header_converters: :downcase) +# tbl.class # => CSV::Table +# tbl.headers # => ["name", "count"] +# +# Converter +:symbol+ converts each header by making it into a \Symbol: +# string = "Name,Count\nFoo,0\n,Bar,1\nBaz,2" +# tbl = CSV.parse(string, headers: true, header_converters: :symbol) +# tbl.headers # => [:name, :count] +# Details: +# - Strips leading and trailing whitespace. +# - Downcases the header. +# - Replaces embedded spaces with underscores. +# - Removes non-word characters. +# - Makes the string into a \Symbol. +# +# ===== Custom Header \Converters +# +# You can define a custom header converter: +# upcase_converter = proc {|header| header.upcase } +# string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(string, headers: true, header_converters: upcase_converter) +# table # => # +# table.headers # => ["NAME", "VALUE"] +# You can register the converter in \HeaderConverters \Hash, +# which allows you to refer to it by name: +# CSV::HeaderConverters[:upcase] = upcase_converter +# table = CSV.parse(string, headers: true, header_converters: :upcase) +# table # => # +# table.headers # => ["NAME", "VALUE"] +# +# ===== Write \Converters +# +# When you specify a write converter for generating \CSV, +# each field to be written is passed to the converter; +# its return value becomes the new value for the field. +# A converter might, for example, strip whitespace from a field. +# +# Using no write converter (all fields unmodified): +# output_string = CSV.generate do |csv| +# csv << [' foo ', 0] +# csv << [' bar ', 1] +# csv << [' baz ', 2] +# end +# output_string # => " foo ,0\n bar ,1\n baz ,2\n" +# Using option +write_converters+ with two custom write converters: +# strip_converter = proc {|field| field.respond_to?(:strip) ? field.strip : field } +# upcase_converter = proc {|field| field.respond_to?(:upcase) ? field.upcase : field } +# write_converters = [strip_converter, upcase_converter] +# output_string = CSV.generate(write_converters: write_converters) do |csv| +# csv << [' foo ', 0] +# csv << [' bar ', 1] +# csv << [' baz ', 2] +# end +# output_string # => "FOO,0\nBAR,1\nBAZ,2\n" +# +# === Character Encodings (M17n or Multilingualization) +# +# This new CSV parser is m17n savvy. The parser works in the Encoding of the IO +# or String object being read from or written to. Your data is never transcoded +# (unless you ask Ruby to transcode it for you) and will literally be parsed in +# the Encoding it is in. Thus CSV will return Arrays or Rows of Strings in the +# Encoding of your data. This is accomplished by transcoding the parser itself +# into your Encoding. +# +# Some transcoding must take place, of course, to accomplish this multiencoding +# support. For example, :col_sep, :row_sep, and +# :quote_char must be transcoded to match your data. Hopefully this +# makes the entire process feel transparent, since CSV's defaults should just +# magically work for your data. However, you can set these values manually in +# the target Encoding to avoid the translation. +# +# It's also important to note that while all of CSV's core parser is now +# Encoding agnostic, some features are not. For example, the built-in +# converters will try to transcode data to UTF-8 before making conversions. +# Again, you can provide custom converters that are aware of your Encodings to +# avoid this translation. It's just too hard for me to support native +# conversions in all of Ruby's Encodings. +# +# Anyway, the practical side of this is simple: make sure IO and String objects +# passed into CSV have the proper Encoding set and everything should just work. +# CSV methods that allow you to open IO objects (CSV::foreach(), CSV::open(), +# CSV::read(), and CSV::readlines()) do allow you to specify the Encoding. +# +# One minor exception comes when generating CSV into a String with an Encoding +# that is not ASCII compatible. There's no existing data for CSV to use to +# prepare itself and thus you will probably need to manually specify the desired +# Encoding for most of those cases. It will try to guess using the fields in a +# row of output though, when using CSV::generate_line() or Array#to_csv(). +# +# I try to point out any other Encoding issues in the documentation of methods +# as they come up. +# +# This has been tested to the best of my ability with all non-"dummy" Encodings +# Ruby ships with. However, it is brave new code and may have some bugs. +# Please feel free to {report}[mailto:james@grayproductions.net] any issues you +# find with it. +# +# source://csv//lib/csv/fields_converter.rb#3 +class CSV + include ::Enumerable + extend ::Forwardable + + # :call-seq: + # CSV.new(string) + # CSV.new(io) + # CSV.new(string, **options) + # CSV.new(io, **options) + # + # Returns the new \CSV object created using +string+ or +io+ + # and the specified +options+. + # + # - Argument +string+ should be a \String object; + # it will be put into a new StringIO object positioned at the beginning. + # :include: ../doc/csv/arguments/io.rdoc + # - Argument +options+: See: + # * {Options for Parsing}[#class-CSV-label-Options+for+Parsing] + # * {Options for Generating}[#class-CSV-label-Options+for+Generating] + # For performance reasons, the options cannot be overridden + # in a \CSV object, so those specified here will endure. + # + # In addition to the \CSV instance methods, several \IO methods are delegated. + # See {Delegated Methods}[#class-CSV-label-Delegated+Methods]. + # + # --- + # + # Create a \CSV object from a \String object: + # csv = CSV.new('foo,0') + # + # Create a \CSV object from a \File object: + # File.write('t.csv', 'foo,0') + # csv = CSV.new(File.open('t.csv')) + # + # --- + # + # Raises an exception if the argument is +nil+: + # # Raises ArgumentError (Cannot parse nil as CSV): + # CSV.new(nil) + # + # @raise [ArgumentError] + # @return [CSV] a new instance of CSV + # + # source://csv//lib/csv.rb#1905 + def initialize(data, col_sep: T.unsafe(nil), row_sep: T.unsafe(nil), quote_char: T.unsafe(nil), field_size_limit: T.unsafe(nil), max_field_size: T.unsafe(nil), converters: T.unsafe(nil), unconverted_fields: T.unsafe(nil), headers: T.unsafe(nil), return_headers: T.unsafe(nil), write_headers: T.unsafe(nil), header_converters: T.unsafe(nil), skip_blanks: T.unsafe(nil), force_quotes: T.unsafe(nil), skip_lines: T.unsafe(nil), liberal_parsing: T.unsafe(nil), internal_encoding: T.unsafe(nil), external_encoding: T.unsafe(nil), encoding: T.unsafe(nil), nil_value: T.unsafe(nil), empty_value: T.unsafe(nil), strip: T.unsafe(nil), quote_empty: T.unsafe(nil), write_converters: T.unsafe(nil), write_nil_value: T.unsafe(nil), write_empty_value: T.unsafe(nil)); end + + # :call-seq: + # csv << row -> self + # + # Appends a row to +self+. + # + # - Argument +row+ must be an \Array object or a CSV::Row object. + # - The output stream must be open for writing. + # + # --- + # + # Append Arrays: + # CSV.generate do |csv| + # csv << ['foo', 0] + # csv << ['bar', 1] + # csv << ['baz', 2] + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # Append CSV::Rows: + # headers = [] + # CSV.generate do |csv| + # csv << CSV::Row.new(headers, ['foo', 0]) + # csv << CSV::Row.new(headers, ['bar', 1]) + # csv << CSV::Row.new(headers, ['baz', 2]) + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # Headers in CSV::Row objects are not appended: + # headers = ['Name', 'Count'] + # CSV.generate do |csv| + # csv << CSV::Row.new(headers, ['foo', 0]) + # csv << CSV::Row.new(headers, ['bar', 1]) + # csv << CSV::Row.new(headers, ['baz', 2]) + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # --- + # + # Raises an exception if +row+ is not an \Array or \CSV::Row: + # CSV.generate do |csv| + # # Raises NoMethodError (undefined method `collect' for :foo:Symbol) + # csv << :foo + # end + # + # Raises an exception if the output stream is not opened for writing: + # path = 't.csv' + # File.write(path, '') + # File.open(path) do |file| + # CSV.open(file) do |csv| + # # Raises IOError (not opened for writing) + # csv << ['foo', 0] + # end + # end + # + # source://csv//lib/csv.rb#2372 + def <<(row); end + + # :call-seq: + # csv << row -> self + # + # Appends a row to +self+. + # + # - Argument +row+ must be an \Array object or a CSV::Row object. + # - The output stream must be open for writing. + # + # --- + # + # Append Arrays: + # CSV.generate do |csv| + # csv << ['foo', 0] + # csv << ['bar', 1] + # csv << ['baz', 2] + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # Append CSV::Rows: + # headers = [] + # CSV.generate do |csv| + # csv << CSV::Row.new(headers, ['foo', 0]) + # csv << CSV::Row.new(headers, ['bar', 1]) + # csv << CSV::Row.new(headers, ['baz', 2]) + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # Headers in CSV::Row objects are not appended: + # headers = ['Name', 'Count'] + # CSV.generate do |csv| + # csv << CSV::Row.new(headers, ['foo', 0]) + # csv << CSV::Row.new(headers, ['bar', 1]) + # csv << CSV::Row.new(headers, ['baz', 2]) + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # --- + # + # Raises an exception if +row+ is not an \Array or \CSV::Row: + # CSV.generate do |csv| + # # Raises NoMethodError (undefined method `collect' for :foo:Symbol) + # csv << :foo + # end + # + # Raises an exception if the output stream is not opened for writing: + # path = 't.csv' + # File.write(path, '') + # File.open(path) do |file| + # CSV.open(file) do |csv| + # # Raises IOError (not opened for writing) + # csv << ['foo', 0] + # end + # end + # + # source://csv//lib/csv.rb#2372 + def add_row(row); end + + # @return [Boolean] + # + # source://csv//lib/csv.rb#2261 + def binmode?; end + + # :call-seq: + # csv.col_sep -> string + # + # Returns the encoded column separator; used for parsing and writing; + # see {Option +col_sep+}[#class-CSV-label-Option+col_sep]: + # CSV.new('').col_sep # => "," + # + # source://csv//lib/csv.rb#2009 + def col_sep; end + + # :call-seq: + # convert(converter_name) -> array_of_procs + # convert {|field, field_info| ... } -> array_of_procs + # + # - With no block, installs a field converter (a \Proc). + # - With a block, defines and installs a custom field converter. + # - Returns the \Array of installed field converters. + # + # - Argument +converter_name+, if given, should be the name + # of an existing field converter. + # + # See {Field Converters}[#class-CSV-label-Field+Converters]. + # --- + # + # With no block, installs a field converter: + # csv = CSV.new('') + # csv.convert(:integer) + # csv.convert(:float) + # csv.convert(:date) + # csv.converters # => [:integer, :float, :date] + # + # --- + # + # The block, if given, is called for each field: + # - Argument +field+ is the field value. + # - Argument +field_info+ is a CSV::FieldInfo object + # containing details about the field. + # + # The examples here assume the prior execution of: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # + # Example giving a block: + # csv = CSV.open(path) + # csv.convert {|field, field_info| p [field, field_info]; field.upcase } + # csv.read # => [["FOO", "0"], ["BAR", "1"], ["BAZ", "2"]] + # + # Output: + # ["foo", #] + # ["0", #] + # ["bar", #] + # ["1", #] + # ["baz", #] + # ["2", #] + # + # The block need not return a \String object: + # csv = CSV.open(path) + # csv.convert {|field, field_info| field.to_sym } + # csv.read # => [[:foo, :"0"], [:bar, :"1"], [:baz, :"2"]] + # + # If +converter_name+ is given, the block is not called: + # csv = CSV.open(path) + # csv.convert(:integer) {|field, field_info| fail 'Cannot happen' } + # csv.read # => [["foo", 0], ["bar", 1], ["baz", 2]] + # + # --- + # + # Raises a parse-time exception if +converter_name+ is not the name of a built-in + # field converter: + # csv = CSV.open(path) + # csv.convert(:nosuch) => [nil] + # # Raises NoMethodError (undefined method `arity' for nil:NilClass) + # csv.read + # + # source://csv//lib/csv.rb#2443 + def convert(name = T.unsafe(nil), &converter); end + + # :call-seq: + # csv.converters -> array + # + # Returns an \Array containing field converters; + # see {Field Converters}[#class-CSV-label-Field+Converters]: + # csv = CSV.new('') + # csv.converters # => [] + # csv.convert(:integer) + # csv.converters # => [:integer] + # csv.convert(proc {|x| x.to_s }) + # csv.converters + # + # Notes that you need to call + # +Ractor.make_shareable(CSV::Converters)+ on the main Ractor to use + # this method. + # + # source://csv//lib/csv.rb#2082 + def converters; end + + # :call-seq: + # csv.each -> enumerator + # csv.each {|row| ...} + # + # Calls the block with each successive row. + # The data source must be opened for reading. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.each do |row| + # p row + # end + # Output: + # ["foo", "0"] + # ["bar", "1"] + # ["baz", "2"] + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string, headers: true) + # csv.each do |row| + # p row + # end + # Output: + # + # + # + # + # --- + # + # Raises an exception if the source is not opened for reading: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.close + # # Raises IOError (not opened for reading) + # csv.each do |row| + # p row + # end + # + # source://csv//lib/csv.rb#2554 + def each(&block); end + + # :call-seq: + # csv.encoding -> encoding + # + # Returns the encoding used for parsing and generating; + # see {Character Encodings (M17n or Multilingualization)}[#class-CSV-label-Character+Encodings+-28M17n+or+Multilingualization-29]: + # CSV.new('').encoding # => # + # + # source://csv//lib/csv.rb#2192 + def encoding; end + + # @return [Boolean] + # + # source://csv//lib/csv.rb#2297 + def eof; end + + # @return [Boolean] + # + # source://csv//lib/csv.rb#2297 + def eof?; end + + # :call-seq: + # csv.field_size_limit -> integer or nil + # + # Returns the limit for field size; used for parsing; + # see {Option +field_size_limit+}[#class-CSV-label-Option+field_size_limit]: + # CSV.new('').field_size_limit # => nil + # + # Deprecated since 3.2.3. Use +max_field_size+ instead. + # + # source://csv//lib/csv.rb#2041 + def field_size_limit; end + + # @raise [NotImplementedError] + # + # source://csv//lib/csv.rb#2269 + def flock(*args); end + + # :call-seq: + # csv.force_quotes? -> true or false + # + # Returns the value that determines whether all output fields are to be quoted; + # used for generating; + # see {Option +force_quotes+}[#class-CSV-label-Option+force_quotes]: + # CSV.new('').force_quotes? # => false + # + # @return [Boolean] + # + # source://csv//lib/csv.rb#2172 + def force_quotes?; end + + # :call-seq: + # csv.shift -> array, csv_row, or nil + # + # Returns the next row of data as: + # - An \Array if no headers are used. + # - A CSV::Row object if headers are used. + # + # The data source must be opened for reading. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.shift # => ["foo", "0"] + # csv.shift # => ["bar", "1"] + # csv.shift # => ["baz", "2"] + # csv.shift # => nil + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string, headers: true) + # csv.shift # => # + # csv.shift # => # + # csv.shift # => # + # csv.shift # => nil + # + # --- + # + # Raises an exception if the source is not opened for reading: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.close + # # Raises IOError (not opened for reading) + # csv.shift + # + # source://csv//lib/csv.rb#2668 + def gets; end + + # The block need not return a \String object: + # csv = CSV.open(path, headers: true) + # csv.header_convert {|header, field_info| header.to_sym } + # table = csv.read + # table.headers # => [:Name, :Value] + # + # If +converter_name+ is given, the block is not called: + # csv = CSV.open(path, headers: true) + # csv.header_convert(:downcase) {|header, field_info| fail 'Cannot happen' } + # table = csv.read + # table.headers # => ["name", "value"] + # --- + # + # Raises a parse-time exception if +converter_name+ is not the name of a built-in + # field converter: + # csv = CSV.open(path, headers: true) + # csv.header_convert(:nosuch) + # # Raises NoMethodError (undefined method `arity' for nil:NilClass) + # csv.read + # + # source://csv//lib/csv.rb#2509 + def header_convert(name = T.unsafe(nil), &converter); end + + # :call-seq: + # csv.header_converters -> array + # + # Returns an \Array containing header converters; used for parsing; + # see {Header Converters}[#class-CSV-label-Header+Converters]: + # CSV.new('').header_converters # => [] + # + # Notes that you need to call + # +Ractor.make_shareable(CSV::HeaderConverters)+ on the main Ractor + # to use this method. + # + # source://csv//lib/csv.rb#2148 + def header_converters; end + + # :call-seq: + # csv.header_row? -> true or false + # + # Returns +true+ if the next row to be read is a header row\; + # +false+ otherwise. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.header_row? # => false + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string, headers: true) + # csv.header_row? # => true + # csv.shift # => # + # csv.header_row? # => false + # + # --- + # + # Raises an exception if the source is not opened for reading: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.close + # # Raises IOError (not opened for reading) + # csv.header_row? + # + # @return [Boolean] + # + # source://csv//lib/csv.rb#2631 + def header_row?; end + + # :call-seq: + # csv.headers -> object + # + # Returns the value that determines whether headers are used; used for parsing; + # see {Option +headers+}[#class-CSV-label-Option+headers]: + # CSV.new('').headers # => nil + # + # source://csv//lib/csv.rb#2106 + def headers; end + + # :call-seq: + # csv.inspect -> string + # + # Returns a \String showing certain properties of +self+: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string, headers: true) + # s = csv.inspect + # + # source://csv//lib/csv.rb#2690 + def inspect; end + + # @raise [NotImplementedError] + # + # source://csv//lib/csv.rb#2274 + def ioctl(*args); end + + # :call-seq: + # csv.liberal_parsing? -> true or false + # + # Returns the value that determines whether illegal input is to be handled; used for parsing; + # see {Option +liberal_parsing+}[#class-CSV-label-Option+liberal_parsing]: + # CSV.new('').liberal_parsing? # => false + # + # @return [Boolean] + # + # source://csv//lib/csv.rb#2182 + def liberal_parsing?; end + + # :call-seq: + # csv.line -> array + # + # Returns the line most recently read: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # CSV.open(path) do |csv| + # csv.each do |row| + # p [csv.lineno, csv.line] + # end + # end + # Output: + # [1, "foo,0\n"] + # [2, "bar,1\n"] + # [3, "baz,2\n"] + # + # source://csv//lib/csv.rb#2247 + def line; end + + # :call-seq: + # csv.line_no -> integer + # + # Returns the count of the rows parsed or generated. + # + # Parsing: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # CSV.open(path) do |csv| + # csv.each do |row| + # p [csv.lineno, row] + # end + # end + # Output: + # [1, ["foo", "0"]] + # [2, ["bar", "1"]] + # [3, ["baz", "2"]] + # + # Generating: + # CSV.generate do |csv| + # p csv.lineno; csv << ['foo', 0] + # p csv.lineno; csv << ['bar', 1] + # p csv.lineno; csv << ['baz', 2] + # end + # Output: + # 0 + # 1 + # 2 + # + # source://csv//lib/csv.rb#2223 + def lineno; end + + # :call-seq: + # csv.max_field_size -> integer or nil + # + # Returns the limit for field size; used for parsing; + # see {Option +max_field_size+}[#class-CSV-label-Option+max_field_size]: + # CSV.new('').max_field_size # => nil + # + # Since 3.2.3. + # + # source://csv//lib/csv.rb#2053 + def max_field_size; end + + # source://csv//lib/csv.rb#2279 + def path; end + + # :call-seq: + # csv << row -> self + # + # Appends a row to +self+. + # + # - Argument +row+ must be an \Array object or a CSV::Row object. + # - The output stream must be open for writing. + # + # --- + # + # Append Arrays: + # CSV.generate do |csv| + # csv << ['foo', 0] + # csv << ['bar', 1] + # csv << ['baz', 2] + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # Append CSV::Rows: + # headers = [] + # CSV.generate do |csv| + # csv << CSV::Row.new(headers, ['foo', 0]) + # csv << CSV::Row.new(headers, ['bar', 1]) + # csv << CSV::Row.new(headers, ['baz', 2]) + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # Headers in CSV::Row objects are not appended: + # headers = ['Name', 'Count'] + # CSV.generate do |csv| + # csv << CSV::Row.new(headers, ['foo', 0]) + # csv << CSV::Row.new(headers, ['bar', 1]) + # csv << CSV::Row.new(headers, ['baz', 2]) + # end # => "foo,0\nbar,1\nbaz,2\n" + # + # --- + # + # Raises an exception if +row+ is not an \Array or \CSV::Row: + # CSV.generate do |csv| + # # Raises NoMethodError (undefined method `collect' for :foo:Symbol) + # csv << :foo + # end + # + # Raises an exception if the output stream is not opened for writing: + # path = 't.csv' + # File.write(path, '') + # File.open(path) do |file| + # CSV.open(file) do |csv| + # # Raises IOError (not opened for writing) + # csv << ['foo', 0] + # end + # end + # + # source://csv//lib/csv.rb#2372 + def puts(row); end + + # :call-seq: + # csv.quote_char -> character + # + # Returns the encoded quote character; used for parsing and writing; + # see {Option +quote_char+}[#class-CSV-label-Option+quote_char]: + # CSV.new('').quote_char # => "\"" + # + # source://csv//lib/csv.rb#2029 + def quote_char; end + + # :call-seq: + # csv.read -> array or csv_table + # + # Forms the remaining rows from +self+ into: + # - A CSV::Table object, if headers are in use. + # - An \Array of Arrays, otherwise. + # + # The data source must be opened for reading. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # csv = CSV.open(path) + # csv.read # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # csv = CSV.open(path, headers: true) + # csv.read # => # + # + # --- + # + # Raises an exception if the source is not opened for reading: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.close + # # Raises IOError (not opened for reading) + # csv.read + # + # source://csv//lib/csv.rb#2595 + def read; end + + # :call-seq: + # csv.shift -> array, csv_row, or nil + # + # Returns the next row of data as: + # - An \Array if no headers are used. + # - A CSV::Row object if headers are used. + # + # The data source must be opened for reading. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.shift # => ["foo", "0"] + # csv.shift # => ["bar", "1"] + # csv.shift # => ["baz", "2"] + # csv.shift # => nil + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string, headers: true) + # csv.shift # => # + # csv.shift # => # + # csv.shift # => # + # csv.shift # => nil + # + # --- + # + # Raises an exception if the source is not opened for reading: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.close + # # Raises IOError (not opened for reading) + # csv.shift + # + # source://csv//lib/csv.rb#2668 + def readline; end + + # :call-seq: + # csv.read -> array or csv_table + # + # Forms the remaining rows from +self+ into: + # - A CSV::Table object, if headers are in use. + # - An \Array of Arrays, otherwise. + # + # The data source must be opened for reading. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # csv = CSV.open(path) + # csv.read # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # csv = CSV.open(path, headers: true) + # csv.read # => # + # + # --- + # + # Raises an exception if the source is not opened for reading: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.close + # # Raises IOError (not opened for reading) + # csv.read + # + # source://csv//lib/csv.rb#2595 + def readlines; end + + # :call-seq: + # csv.return_headers? -> true or false + # + # Returns the value that determines whether headers are to be returned; used for parsing; + # see {Option +return_headers+}[#class-CSV-label-Option+return_headers]: + # CSV.new('').return_headers? # => false + # + # @return [Boolean] + # + # source://csv//lib/csv.rb#2124 + def return_headers?; end + + # Rewinds the underlying IO object and resets CSV's lineno() counter. + # + # source://csv//lib/csv.rb#2312 + def rewind; end + + # :call-seq: + # csv.row_sep -> string + # + # Returns the encoded row separator; used for parsing and writing; + # see {Option +row_sep+}[#class-CSV-label-Option+row_sep]: + # CSV.new('').row_sep # => "\n" + # + # source://csv//lib/csv.rb#2019 + def row_sep; end + + # :call-seq: + # csv.shift -> array, csv_row, or nil + # + # Returns the next row of data as: + # - An \Array if no headers are used. + # - A CSV::Row object if headers are used. + # + # The data source must be opened for reading. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.shift # => ["foo", "0"] + # csv.shift # => ["bar", "1"] + # csv.shift # => ["baz", "2"] + # csv.shift # => nil + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string, headers: true) + # csv.shift # => # + # csv.shift # => # + # csv.shift # => # + # csv.shift # => nil + # + # --- + # + # Raises an exception if the source is not opened for reading: + # string = "foo,0\nbar,1\nbaz,2\n" + # csv = CSV.new(string) + # csv.close + # # Raises IOError (not opened for reading) + # csv.shift + # + # source://csv//lib/csv.rb#2668 + def shift; end + + # :call-seq: + # csv.skip_blanks? -> true or false + # + # Returns the value that determines whether blank lines are to be ignored; used for parsing; + # see {Option +skip_blanks+}[#class-CSV-label-Option+skip_blanks]: + # CSV.new('').skip_blanks? # => false + # + # @return [Boolean] + # + # source://csv//lib/csv.rb#2161 + def skip_blanks?; end + + # :call-seq: + # csv.skip_lines -> regexp or nil + # + # Returns the \Regexp used to identify comment lines; used for parsing; + # see {Option +skip_lines+}[#class-CSV-label-Option+skip_lines]: + # CSV.new('').skip_lines # => nil + # + # source://csv//lib/csv.rb#2063 + def skip_lines; end + + # @raise [NotImplementedError] + # + # source://csv//lib/csv.rb#2283 + def stat(*args); end + + # @raise [NotImplementedError] + # + # source://csv//lib/csv.rb#2288 + def to_i; end + + # source://csv//lib/csv.rb#2293 + def to_io; end + + # :call-seq: + # csv.unconverted_fields? -> object + # + # Returns the value that determines whether unconverted fields are to be + # available; used for parsing; + # see {Option +unconverted_fields+}[#class-CSV-label-Option+unconverted_fields]: + # CSV.new('').unconverted_fields? # => nil + # + # @return [Boolean] + # + # source://csv//lib/csv.rb#2096 + def unconverted_fields?; end + + # :call-seq: + # csv.write_headers? -> true or false + # + # Returns the value that determines whether headers are to be written; used for generating; + # see {Option +write_headers+}[#class-CSV-label-Option+write_headers]: + # CSV.new('').write_headers? # => nil + # + # @return [Boolean] + # + # source://csv//lib/csv.rb#2134 + def write_headers?; end + + private + + # source://csv//lib/csv.rb#2822 + def build_fields_converter(initial_converters, options); end + + # source://csv//lib/csv.rb#2804 + def build_header_fields_converter; end + + # source://csv//lib/csv.rb#2792 + def build_parser_fields_converter; end + + # source://csv//lib/csv.rb#2817 + def build_writer_fields_converter; end + + # Processes +fields+ with @converters, or @header_converters + # if +headers+ is passed as +true+, returning the converted field set. Any + # converter that changes the field into something other than a String halts + # the pipeline of conversion for that field. This is primarily an efficiency + # shortcut. + # + # source://csv//lib/csv.rb#2767 + def convert_fields(fields, headers = T.unsafe(nil)); end + + # source://csv//lib/csv.rb#2730 + def determine_encoding(encoding, internal_encoding); end + + # source://csv//lib/csv.rb#2800 + def header_fields_converter; end + + # source://csv//lib/csv.rb#2745 + def normalize_converters(converters); end + + # source://csv//lib/csv.rb#2830 + def parser; end + + # source://csv//lib/csv.rb#2839 + def parser_enumerator; end + + # source://csv//lib/csv.rb#2788 + def parser_fields_converter; end + + # source://csv//lib/csv.rb#2834 + def parser_options; end + + # Returns the encoding of the internal IO object. + # + # source://csv//lib/csv.rb#2778 + def raw_encoding; end + + # source://csv//lib/csv.rb#2843 + def writer; end + + # source://csv//lib/csv.rb#2813 + def writer_fields_converter; end + + # source://csv//lib/csv.rb#2847 + def writer_options; end + + class << self + # :call-seq: + # filter(in_string_or_io, **options) {|row| ... } -> array_of_arrays or csv_table + # filter(in_string_or_io, out_string_or_io, **options) {|row| ... } -> array_of_arrays or csv_table + # filter(**options) {|row| ... } -> array_of_arrays or csv_table + # + # - Parses \CSV from a source (\String, \IO stream, or ARGF). + # - Calls the given block with each parsed row: + # - Without headers, each row is an \Array. + # - With headers, each row is a CSV::Row. + # - Generates \CSV to an output (\String, \IO stream, or STDOUT). + # - Returns the parsed source: + # - Without headers, an \Array of \Arrays. + # - With headers, a CSV::Table. + # + # When +in_string_or_io+ is given, but not +out_string_or_io+, + # parses from the given +in_string_or_io+ + # and generates to STDOUT. + # + # \String input without headers: + # + # in_string = "foo,0\nbar,1\nbaz,2" + # CSV.filter(in_string) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end # => [["FOO", 0], ["BAR", -1], ["BAZ", -2]] + # + # Output (to STDOUT): + # + # FOO,0 + # BAR,-1 + # BAZ,-2 + # + # \String input with headers: + # + # in_string = "Name,Value\nfoo,0\nbar,1\nbaz,2" + # CSV.filter(in_string, headers: true) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end # => # + # + # Output (to STDOUT): + # + # Name,Value + # FOO,0 + # BAR,-1 + # BAZ,-2 + # + # \IO stream input without headers: + # + # File.write('t.csv', "foo,0\nbar,1\nbaz,2") + # File.open('t.csv') do |in_io| + # CSV.filter(in_io) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end + # end # => [["FOO", 0], ["BAR", -1], ["BAZ", -2]] + # + # Output (to STDOUT): + # + # FOO,0 + # BAR,-1 + # BAZ,-2 + # + # \IO stream input with headers: + # + # File.write('t.csv', "Name,Value\nfoo,0\nbar,1\nbaz,2") + # File.open('t.csv') do |in_io| + # CSV.filter(in_io, headers: true) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end + # end # => # + # + # Output (to STDOUT): + # + # Name,Value + # FOO,0 + # BAR,-1 + # BAZ,-2 + # + # When both +in_string_or_io+ and +out_string_or_io+ are given, + # parses from +in_string_or_io+ and generates to +out_string_or_io+. + # + # \String output without headers: + # + # in_string = "foo,0\nbar,1\nbaz,2" + # out_string = '' + # CSV.filter(in_string, out_string) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end # => [["FOO", 0], ["BAR", -1], ["BAZ", -2]] + # out_string # => "FOO,0\nBAR,-1\nBAZ,-2\n" + # + # \String output with headers: + # + # in_string = "Name,Value\nfoo,0\nbar,1\nbaz,2" + # out_string = '' + # CSV.filter(in_string, out_string, headers: true) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end # => # + # out_string # => "Name,Value\nFOO,0\nBAR,-1\nBAZ,-2\n" + # + # \IO stream output without headers: + # + # in_string = "foo,0\nbar,1\nbaz,2" + # File.open('t.csv', 'w') do |out_io| + # CSV.filter(in_string, out_io) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end + # end # => [["FOO", 0], ["BAR", -1], ["BAZ", -2]] + # File.read('t.csv') # => "FOO,0\nBAR,-1\nBAZ,-2\n" + # + # \IO stream output with headers: + # + # in_string = "Name,Value\nfoo,0\nbar,1\nbaz,2" + # File.open('t.csv', 'w') do |out_io| + # CSV.filter(in_string, out_io, headers: true) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end + # end # => # + # File.read('t.csv') # => "Name,Value\nFOO,0\nBAR,-1\nBAZ,-2\n" + # + # When neither +in_string_or_io+ nor +out_string_or_io+ given, + # parses from {ARGF}[rdoc-ref:ARGF] + # and generates to STDOUT. + # + # Without headers: + # + # # Put Ruby code into a file. + # ruby = <<-EOT + # require 'csv' + # CSV.filter do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end + # EOT + # File.write('t.rb', ruby) + # # Put some CSV into a file. + # File.write('t.csv', "foo,0\nbar,1\nbaz,2") + # # Run the Ruby code with CSV filename as argument. + # system(Gem.ruby, "t.rb", "t.csv") + # + # Output (to STDOUT): + # + # FOO,0 + # BAR,-1 + # BAZ,-2 + # + # With headers: + # + # # Put Ruby code into a file. + # ruby = <<-EOT + # require 'csv' + # CSV.filter(headers: true) do |row| + # row[0].upcase! + # row[1] = - row[1].to_i + # end + # EOT + # File.write('t.rb', ruby) + # # Put some CSV into a file. + # File.write('t.csv', "Name,Value\nfoo,0\nbar,1\nbaz,2") + # # Run the Ruby code with CSV filename as argument. + # system(Gem.ruby, "t.rb", "t.csv") + # + # Output (to STDOUT): + # + # Name,Value + # FOO,0 + # BAR,-1 + # BAZ,-2 + # + # Arguments: + # + # * Argument +in_string_or_io+ must be a \String or an \IO stream. + # * Argument +out_string_or_io+ must be a \String or an \IO stream. + # * Arguments **options must be keyword options. + # See {Options for Parsing}[#class-CSV-label-Options+for+Parsing]. + # + # source://csv//lib/csv.rb#1202 + def filter(input = T.unsafe(nil), output = T.unsafe(nil), **options); end + + # :call-seq: + # foreach(path_or_io, mode='r', **options) {|row| ... ) + # foreach(path_or_io, mode='r', **options) -> new_enumerator + # + # Calls the block with each row read from source +path_or_io+. + # + # \Path input without headers: + # + # string = "foo,0\nbar,1\nbaz,2\n" + # in_path = 't.csv' + # File.write(in_path, string) + # CSV.foreach(in_path) {|row| p row } + # + # Output: + # + # ["foo", "0"] + # ["bar", "1"] + # ["baz", "2"] + # + # \Path input with headers: + # + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # in_path = 't.csv' + # File.write(in_path, string) + # CSV.foreach(in_path, headers: true) {|row| p row } + # + # Output: + # + # + # + # + # + # \IO stream input without headers: + # + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # File.open('t.csv') do |in_io| + # CSV.foreach(in_io) {|row| p row } + # end + # + # Output: + # + # ["foo", "0"] + # ["bar", "1"] + # ["baz", "2"] + # + # \IO stream input with headers: + # + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # File.open('t.csv') do |in_io| + # CSV.foreach(in_io, headers: true) {|row| p row } + # end + # + # Output: + # + # + # + # + # + # With no block given, returns an \Enumerator: + # + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # CSV.foreach(path) # => # + # + # Arguments: + # * Argument +path_or_io+ must be a file path or an \IO stream. + # * Argument +mode+, if given, must be a \File mode. + # See {Access Modes}[https://docs.ruby-lang.org/en/master/File.html#class-File-label-Access+Modes]. + # * Arguments **options must be keyword options. + # See {Options for Parsing}[#class-CSV-label-Options+for+Parsing]. + # * This method optionally accepts an additional :encoding option + # that you can use to specify the Encoding of the data read from +path+ or +io+. + # You must provide this unless your data is in the encoding + # given by Encoding::default_external. + # Parsing will use this to determine how to parse the data. + # You may provide a second Encoding to + # have the data transcoded as it is read. For example, + # would read +UTF-32BE+ data from the file + # but transcode it to +UTF-8+ before parsing. + # + # source://csv//lib/csv.rb#1332 + def foreach(path, mode = T.unsafe(nil), **options, &block); end + + # :call-seq: + # generate(csv_string, **options) {|csv| ... } + # generate(**options) {|csv| ... } + # + # * Argument +csv_string+, if given, must be a \String object; + # defaults to a new empty \String. + # * Arguments +options+, if given, should be generating options. + # See {Options for Generating}[#class-CSV-label-Options+for+Generating]. + # + # --- + # + # Creates a new \CSV object via CSV.new(csv_string, **options); + # calls the block with the \CSV object, which the block may modify; + # returns the \String generated from the \CSV object. + # + # Note that a passed \String *is* modified by this method. + # Pass csv_string.dup if the \String must be preserved. + # + # This method has one additional option: :encoding, + # which sets the base Encoding for the output if no no +str+ is specified. + # CSV needs this hint if you plan to output non-ASCII compatible data. + # + # --- + # + # Add lines: + # input_string = "foo,0\nbar,1\nbaz,2\n" + # output_string = CSV.generate(input_string) do |csv| + # csv << ['bat', 3] + # csv << ['bam', 4] + # end + # output_string # => "foo,0\nbar,1\nbaz,2\nbat,3\nbam,4\n" + # input_string # => "foo,0\nbar,1\nbaz,2\nbat,3\nbam,4\n" + # output_string.equal?(input_string) # => true # Same string, modified + # + # Add lines into new string, preserving old string: + # input_string = "foo,0\nbar,1\nbaz,2\n" + # output_string = CSV.generate(input_string.dup) do |csv| + # csv << ['bat', 3] + # csv << ['bam', 4] + # end + # output_string # => "foo,0\nbar,1\nbaz,2\nbat,3\nbam,4\n" + # input_string # => "foo,0\nbar,1\nbaz,2\n" + # output_string.equal?(input_string) # => false # Different strings + # + # Create lines from nothing: + # output_string = CSV.generate do |csv| + # csv << ['foo', 0] + # csv << ['bar', 1] + # csv << ['baz', 2] + # end + # output_string # => "foo,0\nbar,1\nbaz,2\n" + # + # --- + # + # Raises an exception if +csv_string+ is not a \String object: + # # Raises TypeError (no implicit conversion of Integer into String) + # CSV.generate(0) + # + # @yield [csv] + # + # source://csv//lib/csv.rb#1398 + def generate(str = T.unsafe(nil), **options); end + + # :call-seq: + # CSV.generate_line(ary) + # CSV.generate_line(ary, **options) + # + # Returns the \String created by generating \CSV from +ary+ + # using the specified +options+. + # + # Argument +ary+ must be an \Array. + # + # Special options: + # * Option :row_sep defaults to "\n"> on Ruby 3.0 or later + # and $INPUT_RECORD_SEPARATOR ($/) otherwise.: + # $INPUT_RECORD_SEPARATOR # => "\n" + # * This method accepts an additional option, :encoding, which sets the base + # Encoding for the output. This method will try to guess your Encoding from + # the first non-+nil+ field in +row+, if possible, but you may need to use + # this parameter as a backup plan. + # + # For other +options+, + # see {Options for Generating}[#class-CSV-label-Options+for+Generating]. + # + # --- + # + # Returns the \String generated from an \Array: + # CSV.generate_line(['foo', '0']) # => "foo,0\n" + # + # --- + # + # Raises an exception if +ary+ is not an \Array: + # # Raises NoMethodError (undefined method `find' for :foo:Symbol) + # CSV.generate_line(:foo) + # + # source://csv//lib/csv.rb#1446 + def generate_line(row, **options); end + + # :call-seq: + # CSV.generate_lines(rows) + # CSV.generate_lines(rows, **options) + # + # Returns the \String created by generating \CSV from + # using the specified +options+. + # + # Argument +rows+ must be an \Array of row. Row is \Array of \String or \CSV::Row. + # + # Special options: + # * Option :row_sep defaults to "\n" on Ruby 3.0 or later + # and $INPUT_RECORD_SEPARATOR ($/) otherwise.: + # $INPUT_RECORD_SEPARATOR # => "\n" + # * This method accepts an additional option, :encoding, which sets the base + # Encoding for the output. This method will try to guess your Encoding from + # the first non-+nil+ field in +row+, if possible, but you may need to use + # this parameter as a backup plan. + # + # For other +options+, + # see {Options for Generating}[#class-CSV-label-Options+for+Generating]. + # + # --- + # + # Returns the \String generated from an + # CSV.generate_lines([['foo', '0'], ['bar', '1'], ['baz', '2']]) # => "foo,0\nbar,1\nbaz,2\n" + # + # --- + # + # Raises an exception + # # Raises NoMethodError (undefined method `each' for :foo:Symbol) + # CSV.generate_lines(:foo) + # + # source://csv//lib/csv.rb#1501 + def generate_lines(rows, **options); end + + # :call-seq: + # instance(string, **options) + # instance(io = $stdout, **options) + # instance(string, **options) {|csv| ... } + # instance(io = $stdout, **options) {|csv| ... } + # + # Creates or retrieves cached \CSV objects. + # For arguments and options, see CSV.new. + # + # This API is not Ractor-safe. + # + # --- + # + # With no block given, returns a \CSV object. + # + # The first call to +instance+ creates and caches a \CSV object: + # s0 = 's0' + # csv0 = CSV.instance(s0) + # csv0.class # => CSV + # + # Subsequent calls to +instance+ with that _same_ +string+ or +io+ + # retrieve that same cached object: + # csv1 = CSV.instance(s0) + # csv1.class # => CSV + # csv1.equal?(csv0) # => true # Same CSV object + # + # A subsequent call to +instance+ with a _different_ +string+ or +io+ + # creates and caches a _different_ \CSV object. + # s1 = 's1' + # csv2 = CSV.instance(s1) + # csv2.equal?(csv0) # => false # Different CSV object + # + # All the cached objects remains available: + # csv3 = CSV.instance(s0) + # csv3.equal?(csv0) # true # Same CSV object + # csv4 = CSV.instance(s1) + # csv4.equal?(csv2) # true # Same CSV object + # + # --- + # + # When a block is given, calls the block with the created or retrieved + # \CSV object; returns the block's return value: + # CSV.instance(s0) {|csv| :foo } # => :foo + # + # source://csv//lib/csv.rb#1006 + def instance(data = T.unsafe(nil), **options); end + + # :call-seq: + # open(file_path, mode = "rb", **options ) -> new_csv + # open(io, mode = "rb", **options ) -> new_csv + # open(file_path, mode = "rb", **options ) { |csv| ... } -> object + # open(io, mode = "rb", **options ) { |csv| ... } -> object + # + # possible options elements: + # keyword form: + # :invalid => nil # raise error on invalid byte sequence (default) + # :invalid => :replace # replace invalid byte sequence + # :undef => :replace # replace undefined conversion + # :replace => string # replacement string ("?" or "\uFFFD" if not specified) + # + # * Argument +path+, if given, must be the path to a file. + # :include: ../doc/csv/arguments/io.rdoc + # * Argument +mode+, if given, must be a \File mode. + # See {Access Modes}[https://docs.ruby-lang.org/en/master/File.html#class-File-label-Access+Modes]. + # * Arguments **options must be keyword options. + # See {Options for Generating}[#class-CSV-label-Options+for+Generating]. + # * This method optionally accepts an additional :encoding option + # that you can use to specify the Encoding of the data read from +path+ or +io+. + # You must provide this unless your data is in the encoding + # given by Encoding::default_external. + # Parsing will use this to determine how to parse the data. + # You may provide a second Encoding to + # have the data transcoded as it is read. For example, + # would read +UTF-32BE+ data from the file + # but transcode it to +UTF-8+ before parsing. + # + # --- + # + # These examples assume prior execution of: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # + # --- + # + # With no block given, returns a new \CSV object. + # + # Create a \CSV object using a file path: + # csv = CSV.open(path) + # + # Create a \CSV object using an open \File: + # csv = CSV.open(File.open(path)) + # + # --- + # + # With a block given, calls the block with the created \CSV object; + # returns the block's return value: + # + # Using a file path: + # csv = CSV.open(path) {|csv| p csv} + # Output: + # + # Using an open \File: + # csv = CSV.open(File.open(path)) {|csv| p csv} + # Output: + # + # --- + # + # Raises an exception if the argument is not a \String object or \IO object: + # # Raises TypeError (no implicit conversion of Symbol into String) + # CSV.open(:foo) + # + # source://csv//lib/csv.rb#1581 + def open(filename, mode = T.unsafe(nil), **options); end + + # :call-seq: + # parse(string) -> array_of_arrays + # parse(io) -> array_of_arrays + # parse(string, headers: ..., **options) -> csv_table + # parse(io, headers: ..., **options) -> csv_table + # parse(string, **options) {|row| ... } + # parse(io, **options) {|row| ... } + # + # Parses +string+ or +io+ using the specified +options+. + # + # - Argument +string+ should be a \String object; + # it will be put into a new StringIO object positioned at the beginning. + # :include: ../doc/csv/arguments/io.rdoc + # - Argument +options+: see {Options for Parsing}[#class-CSV-label-Options+for+Parsing] + # + # ====== Without Option +headers+ + # + # Without {option +headers+}[#class-CSV-label-Option+headers] case. + # + # These examples assume prior execution of: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # + # --- + # + # With no block given, returns an \Array of Arrays formed from the source. + # + # Parse a \String: + # a_of_a = CSV.parse(string) + # a_of_a # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # Parse an open \File: + # a_of_a = File.open(path) do |file| + # CSV.parse(file) + # end + # a_of_a # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # --- + # + # With a block given, calls the block with each parsed row: + # + # Parse a \String: + # CSV.parse(string) {|row| p row } + # + # Output: + # ["foo", "0"] + # ["bar", "1"] + # ["baz", "2"] + # + # Parse an open \File: + # File.open(path) do |file| + # CSV.parse(file) {|row| p row } + # end + # + # Output: + # ["foo", "0"] + # ["bar", "1"] + # ["baz", "2"] + # + # ====== With Option +headers+ + # + # With {option +headers+}[#class-CSV-label-Option+headers] case. + # + # These examples assume prior execution of: + # string = "Name,Count\nfoo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # + # --- + # + # With no block given, returns a CSV::Table object formed from the source. + # + # Parse a \String: + # csv_table = CSV.parse(string, headers: ['Name', 'Count']) + # csv_table # => # + # + # Parse an open \File: + # csv_table = File.open(path) do |file| + # CSV.parse(file, headers: ['Name', 'Count']) + # end + # csv_table # => # + # + # --- + # + # With a block given, calls the block with each parsed row, + # which has been formed into a CSV::Row object: + # + # Parse a \String: + # CSV.parse(string, headers: ['Name', 'Count']) {|row| p row } + # + # Output: + # # + # # + # # + # + # Parse an open \File: + # File.open(path) do |file| + # CSV.parse(file, headers: ['Name', 'Count']) {|row| p row } + # end + # + # Output: + # # + # # + # # + # + # --- + # + # Raises an exception if the argument is not a \String object or \IO object: + # # Raises NoMethodError (undefined method `close' for :foo:Symbol) + # CSV.parse(:foo) + # + # source://csv//lib/csv.rb#1732 + def parse(str, **options, &block); end + + # :call-seq: + # CSV.parse_line(string) -> new_array or nil + # CSV.parse_line(io) -> new_array or nil + # CSV.parse_line(string, **options) -> new_array or nil + # CSV.parse_line(io, **options) -> new_array or nil + # CSV.parse_line(string, headers: true, **options) -> csv_row or nil + # CSV.parse_line(io, headers: true, **options) -> csv_row or nil + # + # Returns the data created by parsing the first line of +string+ or +io+ + # using the specified +options+. + # + # - Argument +string+ should be a \String object; + # it will be put into a new StringIO object positioned at the beginning. + # :include: ../doc/csv/arguments/io.rdoc + # - Argument +options+: see {Options for Parsing}[#class-CSV-label-Options+for+Parsing] + # + # ====== Without Option +headers+ + # + # Without option +headers+, returns the first row as a new \Array. + # + # These examples assume prior execution of: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # + # Parse the first line from a \String object: + # CSV.parse_line(string) # => ["foo", "0"] + # + # Parse the first line from a File object: + # File.open(path) do |file| + # CSV.parse_line(file) # => ["foo", "0"] + # end # => ["foo", "0"] + # + # Returns +nil+ if the argument is an empty \String: + # CSV.parse_line('') # => nil + # + # ====== With Option +headers+ + # + # With {option +headers+}[#class-CSV-label-Option+headers], + # returns the first row as a CSV::Row object. + # + # These examples assume prior execution of: + # string = "Name,Count\nfoo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # + # Parse the first line from a \String object: + # CSV.parse_line(string, headers: true) # => # + # + # Parse the first line from a File object: + # File.open(path) do |file| + # CSV.parse_line(file, headers: true) + # end # => # + # + # --- + # + # Raises an exception if the argument is +nil+: + # # Raises ArgumentError (Cannot parse nil as CSV): + # CSV.parse_line(nil) + # + # source://csv//lib/csv.rb#1805 + def parse_line(line, **options); end + + # :call-seq: + # read(source, **options) -> array_of_arrays + # read(source, headers: true, **options) -> csv_table + # + # Opens the given +source+ with the given +options+ (see CSV.open), + # reads the source (see CSV#read), and returns the result, + # which will be either an \Array of Arrays or a CSV::Table. + # + # Without headers: + # string = "foo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # CSV.read(path) # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # With headers: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # CSV.read(path, headers: true) # => # + # + # source://csv//lib/csv.rb#1829 + def read(path, **options); end + + # :call-seq: + # CSV.readlines(source, **options) + # + # Alias for CSV.read. + # + # source://csv//lib/csv.rb#1837 + def readlines(path, **options); end + + # :call-seq: + # CSV.table(source, **options) + # + # Calls CSV.read with +source+, +options+, and certain default options: + # - +headers+: +true+ + # - +converters+: +:numeric+ + # - +header_converters+: +:symbol+ + # + # Returns a CSV::Table object. + # + # Example: + # string = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # path = 't.csv' + # File.write(path, string) + # CSV.table(path) # => # + # + # source://csv//lib/csv.rb#1856 + def table(path, **options); end + end +end + +# The encoding used by all converters. +# +# source://csv//lib/csv.rb#883 +CSV::ConverterEncoding = T.let(T.unsafe(nil), Encoding) + +# A \Hash containing the names and \Procs for the built-in field converters. +# See {Built-In Field Converters}[#class-CSV-label-Built-In+Field+Converters]. +# +# This \Hash is intentionally left unfrozen, and may be extended with +# custom field converters. +# See {Custom Field Converters}[#class-CSV-label-Custom+Field+Converters]. +# +# source://csv//lib/csv.rb#891 +CSV::Converters = T.let(T.unsafe(nil), Hash) + +# A Regexp used to find and convert some common Date formats. +# +# source://csv//lib/csv.rb#872 +CSV::DateMatcher = T.let(T.unsafe(nil), Regexp) + +# A Regexp used to find and convert some common DateTime formats. +# +# source://csv//lib/csv.rb#875 +CSV::DateTimeMatcher = T.let(T.unsafe(nil), Regexp) + +# Note: Don't use this class directly. This is an internal class. +# +# source://csv//lib/csv/fields_converter.rb#5 +class CSV::FieldsConverter + include ::Enumerable + + # A CSV::FieldsConverter is a data structure for storing the + # fields converter properties to be passed as a parameter + # when parsing a new file (e.g. CSV::Parser.new(@io, parser_options)) + # + # @return [FieldsConverter] a new instance of FieldsConverter + # + # source://csv//lib/csv/fields_converter.rb#13 + def initialize(options = T.unsafe(nil)); end + + # source://csv//lib/csv/fields_converter.rb#23 + def add_converter(name = T.unsafe(nil), &converter); end + + # source://csv//lib/csv/fields_converter.rb#47 + def convert(fields, headers, lineno, quoted_fields); end + + # source://csv//lib/csv/fields_converter.rb#39 + def each(&block); end + + # @return [Boolean] + # + # source://csv//lib/csv/fields_converter.rb#43 + def empty?; end + + private + + # source://csv//lib/csv/fields_converter.rb#85 + def builtin_converters; end + + # @return [Boolean] + # + # source://csv//lib/csv/fields_converter.rb#80 + def need_convert?; end + + # @return [Boolean] + # + # source://csv//lib/csv/fields_converter.rb#76 + def need_static_convert?; end +end + +# A \Hash containing the names and \Procs for the built-in header converters. +# See {Built-In Header Converters}[#class-CSV-label-Built-In+Header+Converters]. +# +# This \Hash is intentionally left unfrozen, and may be extended with +# custom field converters. +# See {Custom Header Converters}[#class-CSV-label-Custom+Header+Converters]. +# +# source://csv//lib/csv.rb#924 +CSV::HeaderConverters = T.let(T.unsafe(nil), Hash) + +# source://csv//lib/csv/input_record_separator.rb#5 +module CSV::InputRecordSeparator + class << self + # source://csv//lib/csv/input_record_separator.rb#8 + def value; end + end +end + +# The error thrown when the parser encounters invalid encoding in CSV. +# +# source://csv//lib/csv.rb#850 +class CSV::InvalidEncodingError < ::CSV::MalformedCSVError + # @return [InvalidEncodingError] a new instance of InvalidEncodingError + # + # source://csv//lib/csv.rb#852 + def initialize(encoding, line_number); end + + # Returns the value of attribute encoding. + # + # source://csv//lib/csv.rb#851 + def encoding; end +end + +# The error thrown when the parser encounters illegal CSV formatting. +# +# source://csv//lib/csv.rb#840 +class CSV::MalformedCSVError < ::RuntimeError + # @return [MalformedCSVError] a new instance of MalformedCSVError + # + # source://csv//lib/csv.rb#843 + def initialize(message, line_number); end + + # Returns the value of attribute line_number. + # + # source://csv//lib/csv.rb#841 + def line_number; end + + # Returns the value of attribute line_number. + # + # source://csv//lib/csv.rb#841 + def lineno; end +end + +# Note: Don't use this class directly. This is an internal class. +# +# source://csv//lib/csv/parser.rb#11 +class CSV::Parser + # @return [Parser] a new instance of Parser + # + # source://csv//lib/csv/parser.rb#335 + def initialize(input, options); end + + # source://csv//lib/csv/parser.rb#343 + def column_separator; end + + # source://csv//lib/csv/parser.rb#355 + def field_size_limit; end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#375 + def header_row?; end + + # source://csv//lib/csv/parser.rb#371 + def headers; end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#387 + def liberal_parsing?; end + + # source://csv//lib/csv/parser.rb#395 + def line; end + + # source://csv//lib/csv/parser.rb#391 + def lineno; end + + # source://csv//lib/csv/parser.rb#359 + def max_field_size; end + + # source://csv//lib/csv/parser.rb#399 + def parse(&block); end + + # source://csv//lib/csv/parser.rb#351 + def quote_character; end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#379 + def return_headers?; end + + # source://csv//lib/csv/parser.rb#347 + def row_separator; end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#383 + def skip_blanks?; end + + # source://csv//lib/csv/parser.rb#363 + def skip_lines; end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#367 + def unconverted_fields?; end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#440 + def use_headers?; end + + private + + # This method injects an instance variable unconverted_fields into + # +row+ and an accessor method for +row+ called unconverted_fields(). The + # variable is set to the contents of +fields+. + # + # source://csv//lib/csv/parser.rb#1289 + def add_unconverted_fields(row, fields); end + + # source://csv//lib/csv/parser.rb#803 + def adjust_headers(headers, quoted_fields); end + + # source://csv//lib/csv/parser.rb#871 + def build_scanner; end + + # source://csv//lib/csv/parser.rb#725 + def detect_row_separator(sample, cr, lf); end + + # @yield [row] + # + # source://csv//lib/csv/parser.rb#1260 + def emit_row(row, quoted_fields, &block); end + + # source://csv//lib/csv/parser.rb#1245 + def ignore_broken_line; end + + # source://csv//lib/csv/parser.rb#755 + def last_line; end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#813 + def may_quoted?; end + + # source://csv//lib/csv/parser.rb#1200 + def parse_column_end; end + + # source://csv//lib/csv/parser.rb#1100 + def parse_column_value; end + + # source://csv//lib/csv/parser.rb#789 + def parse_headers(row); end + + # source://csv//lib/csv/parser.rb#938 + def parse_no_quote(&block); end + + # source://csv//lib/csv/parser.rb#969 + def parse_quotable_loose(&block); end + + # source://csv//lib/csv/parser.rb#1030 + def parse_quotable_robust(&block); end + + # source://csv//lib/csv/parser.rb#1158 + def parse_quoted_column_value; end + + # source://csv//lib/csv/parser.rb#1214 + def parse_row_end; end + + # source://csv//lib/csv/parser.rb#1130 + def parse_unquoted_column_value; end + + # A set of tasks to prepare the file in order to parse it + # + # source://csv//lib/csv/parser.rb#446 + def prepare; end + + # source://csv//lib/csv/parser.rb#503 + def prepare_backslash; end + + # source://csv//lib/csv/parser.rb#763 + def prepare_header; end + + # source://csv//lib/csv/parser.rb#749 + def prepare_line; end + + # source://csv//lib/csv/parser.rb#809 + def prepare_parser; end + + # source://csv//lib/csv/parser.rb#487 + def prepare_quote_character; end + + # source://csv//lib/csv/parser.rb#645 + def prepare_quoted; end + + # source://csv//lib/csv/parser.rb#577 + def prepare_separators; end + + # source://csv//lib/csv/parser.rb#518 + def prepare_skip_lines; end + + # source://csv//lib/csv/parser.rb#535 + def prepare_strip; end + + # source://csv//lib/csv/parser.rb#672 + def prepare_unquoted; end + + # source://csv//lib/csv/parser.rb#461 + def prepare_variable; end + + # source://csv//lib/csv/parser.rb#685 + def resolve_row_separator(separator); end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#918 + def skip_line?(line); end + + # source://csv//lib/csv/parser.rb#901 + def skip_needless_lines; end + + # source://csv//lib/csv/parser.rb#1251 + def start_row; end + + # source://csv//lib/csv/parser.rb#1227 + def strip_value(value); end + + # @raise [MalformedCSVError] + # + # source://csv//lib/csv/parser.rb#930 + def validate_field_size(field); end + + # This method verifies that there are no (obvious) ambiguities with the + # provided +col_sep+ and +strip+ parsing options. For example, if +col_sep+ + # and +strip+ were both equal to +\t+, then there would be no clear way to + # parse the input. + # + # source://csv//lib/csv/parser.rb#627 + def validate_strip_and_col_sep_options; end +end + +# CSV::InputsScanner receives IO inputs, encoding and the chunk_size. +# It also controls the life cycle of the object with its methods +keep_start+, +# +keep_end+, +keep_back+, +keep_drop+. +# +# CSV::InputsScanner.scan() tries to match with pattern at the current position. +# If there's a match, the scanner advances the "scan pointer" and returns the matched string. +# Otherwise, the scanner returns nil. +# +# CSV::InputsScanner.rest() returns the "rest" of the string (i.e. everything after the scan pointer). +# If there is no more data (eos? = true), it returns "". +# +# source://csv//lib/csv/parser.rb#86 +class CSV::Parser::InputsScanner + # @return [InputsScanner] a new instance of InputsScanner + # + # source://csv//lib/csv/parser.rb#87 + def initialize(inputs, encoding, row_separator, chunk_size: T.unsafe(nil)); end + + # source://csv//lib/csv/parser.rb#257 + def check(pattern); end + + # @yield [buffer] + # + # source://csv//lib/csv/parser.rb#97 + def each_line(row_separator); end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#170 + def eos?; end + + # source://csv//lib/csv/parser.rb#197 + def keep_back; end + + # source://csv//lib/csv/parser.rb#236 + def keep_drop; end + + # source://csv//lib/csv/parser.rb#181 + def keep_end; end + + # source://csv//lib/csv/parser.rb#174 + def keep_start; end + + # source://csv//lib/csv/parser.rb#253 + def rest; end + + # source://csv//lib/csv/parser.rb#143 + def scan(pattern); end + + # source://csv//lib/csv/parser.rb#154 + def scan_all(pattern); end + + private + + # source://csv//lib/csv/parser.rb#266 + def adjust_last_keep; end + + # source://csv//lib/csv/parser.rb#294 + def read_chunk; end + + # source://csv//lib/csv/parser.rb#262 + def trace(*args); end +end + +# Raised when encoding is invalid. +# +# source://csv//lib/csv/parser.rb#22 +class CSV::Parser::InvalidEncoding < ::StandardError; end + +# source://csv//lib/csv/parser.rb#845 +CSV::Parser::SCANNER_TEST = T.let(T.unsafe(nil), FalseClass) + +# source://csv//lib/csv/parser.rb#574 +CSV::Parser::STRING_SCANNER_SCAN_ACCEPT_STRING = T.let(T.unsafe(nil), TrueClass) + +# CSV::Scanner receives a CSV output, scans it and return the content. +# It also controls the life cycle of the object with its methods +keep_start+, +# +keep_end+, +keep_back+, +keep_drop+. +# +# Uses StringScanner (the official strscan gem). Strscan provides lexical +# scanning operations on a String. We inherit its object and take advantage +# on the methods. For more information, please visit: +# https://ruby-doc.org/stdlib-2.6.1/libdoc/strscan/rdoc/StringScanner.html +# +# source://csv//lib/csv/parser.rb#39 +class CSV::Parser::Scanner < ::StringScanner + # @return [Scanner] a new instance of Scanner + # + # source://csv//lib/csv/parser.rb#42 + def initialize(*args); end + + # source://csv//lib/csv/parser.rb#47 + def each_line(row_separator); end + + # source://csv//lib/csv/parser.rb#65 + def keep_back; end + + # source://csv//lib/csv/parser.rb#69 + def keep_drop; end + + # source://csv//lib/csv/parser.rb#60 + def keep_end; end + + # source://csv//lib/csv/parser.rb#56 + def keep_start; end + + def scan_all(_arg0); end +end + +# Raised when unexpected case is happen. +# +# source://csv//lib/csv/parser.rb#26 +class CSV::Parser::UnexpectedError < ::StandardError; end + +# source://csv//lib/csv/parser.rb#827 +class CSV::Parser::UnoptimizedStringIO + # @return [UnoptimizedStringIO] a new instance of UnoptimizedStringIO + # + # source://csv//lib/csv/parser.rb#828 + def initialize(string); end + + # source://csv//lib/csv/parser.rb#836 + def each_line(*args, &block); end + + # @return [Boolean] + # + # source://csv//lib/csv/parser.rb#840 + def eof?; end + + # source://csv//lib/csv/parser.rb#832 + def gets(*args); end +end + +# = \CSV::Row +# A \CSV::Row instance represents a \CSV table row. +# (see {class CSV}[../CSV.html]). +# +# The instance may have: +# - Fields: each is an object, not necessarily a \String. +# - Headers: each serves a key, and also need not be a \String. +# +# === Instance Methods +# +# \CSV::Row has three groups of instance methods: +# - Its own internally defined instance methods. +# - Methods included by module Enumerable. +# - Methods delegated to class Array.: +# * Array#empty? +# * Array#length +# * Array#size +# +# == Creating a \CSV::Row Instance +# +# Commonly, a new \CSV::Row instance is created by parsing \CSV source +# that has headers: +# source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(source, headers: true) +# table.each {|row| p row } +# Output: +# # +# # +# # +# +# You can also create a row directly. See ::new. +# +# == Headers +# +# Like a \CSV::Table, a \CSV::Row has headers. +# +# A \CSV::Row that was created by parsing \CSV source +# inherits its headers from the table: +# source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(source, headers: true) +# row = table.first +# row.headers # => ["Name", "Value"] +# +# You can also create a new row with headers; +# like the keys in a \Hash, the headers need not be Strings: +# row = CSV::Row.new([:name, :value], ['foo', 0]) +# row.headers # => [:name, :value] +# +# The new row retains its headers even if added to a table +# that has headers: +# table << row # => # +# row.headers # => [:name, :value] +# row[:name] # => "foo" +# row['Name'] # => nil +# +# +# +# == Accessing Fields +# +# You may access a field in a \CSV::Row with either its \Integer index +# (\Array-style) or its header (\Hash-style). +# +# Fetch a field using method #[]: +# row = CSV::Row.new(['Name', 'Value'], ['foo', 0]) +# row[1] # => 0 +# row['Value'] # => 0 +# +# Set a field using method #[]=: +# row = CSV::Row.new(['Name', 'Value'], ['foo', 0]) +# row # => # +# row[0] = 'bar' +# row['Value'] = 1 +# row # => # +# +# source://csv//lib/csv/row.rb#80 +class CSV::Row + include ::Enumerable + extend ::Forwardable + + # :call-seq: + # CSV::Row.new(headers, fields, header_row = false) -> csv_row + # + # Returns the new \CSV::Row instance constructed from + # arguments +headers+ and +fields+; both should be Arrays; + # note that the fields need not be Strings: + # row = CSV::Row.new(['Name', 'Value'], ['foo', 0]) + # row # => # + # + # If the \Array lengths are different, the shorter is +nil+-filled: + # row = CSV::Row.new(['Name', 'Value', 'Date', 'Size'], ['foo', 0]) + # row # => # + # + # Each \CSV::Row object is either a field row or a header row; + # by default, a new row is a field row; for the row created above: + # row.field_row? # => true + # row.header_row? # => false + # + # If the optional argument +header_row+ is given as +true+, + # the created row is a header row: + # row = CSV::Row.new(['Name', 'Value'], ['foo', 0], header_row = true) + # row # => # + # row.field_row? # => false + # row.header_row? # => true + # + # @return [Row] a new instance of Row + # + # source://csv//lib/csv/row.rb#105 + def initialize(headers, fields, header_row = T.unsafe(nil)); end + + # :call-seq: + # row << [header, value] -> self + # row << hash -> self + # row << value -> self + # + # Adds a field to +self+; returns +self+: + # + # If the argument is a 2-element \Array [header, value], + # a field is added with the given +header+ and +value+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row << ['NAME', 'Bat'] + # row # => # + # + # If the argument is a \Hash, each key-value pair is added + # as a field with header +key+ and value +value+. + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row << {NAME: 'Bat', name: 'Bam'} + # row # => # + # + # Otherwise, the given +value+ is added as a field with no header. + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row << 'Bag' + # row # => # + # + # source://csv//lib/csv/row.rb#389 + def <<(arg); end + + # :call-seq: + # row == other -> true or false + # + # Returns +true+ if +other+ is a /CSV::Row that has the same + # fields (headers and values) in the same order as +self+; + # otherwise returns +false+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # other_row = table[0] + # row == other_row # => true + # other_row = table[1] + # row == other_row # => false + # + # source://csv//lib/csv/row.rb#633 + def ==(other); end + + # :call-seq: + # field(index) -> value + # field(header) -> value + # field(header, offset) -> value + # + # Returns the field value for the given +index+ or +header+. + # + # --- + # + # Fetch field value by \Integer index: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.field(0) # => "foo" + # row.field(1) # => "bar" + # + # Counts backward from the last column if +index+ is negative: + # row.field(-1) # => "0" + # row.field(-2) # => "foo" + # + # Returns +nil+ if +index+ is out of range: + # row.field(2) # => nil + # row.field(-3) # => nil + # + # --- + # + # Fetch field value by header (first found): + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.field('Name') # => "Foo" + # + # Fetch field value by header, ignoring +offset+ leading fields: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.field('Name', 2) # => "Baz" + # + # Returns +nil+ if the header does not exist. + # + # source://csv//lib/csv/row.rb#203 + def [](header_or_index, minimum_index = T.unsafe(nil)); end + + # :call-seq: + # row[index] = value -> value + # row[header, offset] = value -> value + # row[header] = value -> value + # + # Assigns the field value for the given +index+ or +header+; + # returns +value+. + # + # --- + # + # Assign field value by \Integer index: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row[0] = 'Bat' + # row[1] = 3 + # row # => # + # + # Counts backward from the last column if +index+ is negative: + # row[-1] = 4 + # row[-2] = 'Bam' + # row # => # + # + # Extends the row with nil:nil if positive +index+ is not in the row: + # row[4] = 5 + # row # => # + # + # Raises IndexError if negative +index+ is too small (too far from zero). + # + # --- + # + # Assign field value by header (first found): + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row['Name'] = 'Bat' + # row # => # + # + # Assign field value by header, ignoring +offset+ leading fields: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row['Name', 2] = 4 + # row # => # + # + # Append new field by (new) header: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row['New'] = 6 + # row# => # + # + # source://csv//lib/csv/row.rb#339 + def []=(*args); end + + # :call-seq: + # row.deconstruct -> array + # + # Returns the new \Array suitable for pattern matching containing the values + # of the row. + # + # source://csv//lib/csv/row.rb#682 + def deconstruct; end + + # :call-seq: + # row.deconstruct_keys(keys) -> hash + # + # Returns the new \Hash suitable for pattern matching containing only the + # keys specified as an argument. + # + # source://csv//lib/csv/row.rb#667 + def deconstruct_keys(keys); end + + # :call-seq: + # delete(index) -> [header, value] or nil + # delete(header) -> [header, value] or empty_array + # delete(header, offset) -> [header, value] or empty_array + # + # Removes a specified field from +self+; returns the 2-element \Array + # [header, value] if the field exists. + # + # If an \Integer argument +index+ is given, + # removes and returns the field at offset +index+, + # or returns +nil+ if the field does not exist: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.delete(1) # => ["Name", "Bar"] + # row.delete(50) # => nil + # + # Otherwise, if the single argument +header+ is given, + # removes and returns the first-found field with the given header, + # of returns a new empty \Array if the field does not exist: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.delete('Name') # => ["Name", "Foo"] + # row.delete('NAME') # => [] + # + # If argument +header+ and \Integer argument +offset+ are given, + # removes and returns the first-found field with the given header + # whose +index+ is at least as large as +offset+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.delete('Name', 1) # => ["Name", "Bar"] + # row.delete('NAME', 1) # => [] + # + # source://csv//lib/csv/row.rb#451 + def delete(header_or_index, minimum_index = T.unsafe(nil)); end + + # :call-seq: + # row.delete_if {|header, value| ... } -> self + # + # Removes fields from +self+ as selected by the block; returns +self+. + # + # Removes each field for which the block returns a truthy value: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.delete_if {|header, value| value.start_with?('B') } # => true + # row # => # + # row.delete_if {|header, value| header.start_with?('B') } # => false + # + # If no block is given, returns a new Enumerator: + # row.delete_if # => #:delete_if> + # + # source://csv//lib/csv/row.rb#476 + def delete_if(&block); end + + # :call-seq: + # row.dig(index_or_header, *identifiers) -> object + # + # Finds and returns the object in nested object that is specified + # by +index_or_header+ and +specifiers+. + # + # The nested objects may be instances of various classes. + # See {Dig Methods}[rdoc-ref:dig_methods.rdoc]. + # + # Examples: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.dig(1) # => "0" + # row.dig('Value') # => "0" + # row.dig(5) # => nil + # + # source://csv//lib/csv/row.rb#715 + def dig(index_or_header, *indexes); end + + # :call-seq: + # row.each {|header, value| ... } -> self + # + # Calls the block with each header-value pair; returns +self+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.each {|header, value| p [header, value] } + # Output: + # ["Name", "Foo"] + # ["Name", "Bar"] + # ["Name", "Baz"] + # + # If no block is given, returns a new Enumerator: + # row.each # => #:each> + # + # source://csv//lib/csv/row.rb#610 + def each(&block); end + + # :call-seq: + # row.each {|header, value| ... } -> self + # + # Calls the block with each header-value pair; returns +self+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.each {|header, value| p [header, value] } + # Output: + # ["Name", "Foo"] + # ["Name", "Bar"] + # ["Name", "Baz"] + # + # If no block is given, returns a new Enumerator: + # row.each # => #:each> + # + # source://csv//lib/csv/row.rb#610 + def each_pair(&block); end + + # :call-seq: + # fetch(header) -> value + # fetch(header, default) -> value + # fetch(header) {|row| ... } -> value + # + # Returns the field value as specified by +header+. + # + # --- + # + # With the single argument +header+, returns the field value + # for that header (first found): + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.fetch('Name') # => "Foo" + # + # Raises exception +KeyError+ if the header does not exist. + # + # --- + # + # With arguments +header+ and +default+ given, + # returns the field value for the header (first found) + # if the header exists, otherwise returns +default+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.fetch('Name', '') # => "Foo" + # row.fetch(:nosuch, '') # => "" + # + # --- + # + # With argument +header+ and a block given, + # returns the field value for the header (first found) + # if the header exists; otherwise calls the block + # and returns its return value: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.fetch('Name') {|header| fail 'Cannot happen' } # => "Foo" + # row.fetch(:nosuch) {|header| "Header '#{header} not found'" } # => "Header 'nosuch not found'" + # + # @raise [ArgumentError] + # + # source://csv//lib/csv/row.rb#258 + def fetch(header, *varargs); end + + # :call-seq: + # field(index) -> value + # field(header) -> value + # field(header, offset) -> value + # + # Returns the field value for the given +index+ or +header+. + # + # --- + # + # Fetch field value by \Integer index: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.field(0) # => "foo" + # row.field(1) # => "bar" + # + # Counts backward from the last column if +index+ is negative: + # row.field(-1) # => "0" + # row.field(-2) # => "foo" + # + # Returns +nil+ if +index+ is out of range: + # row.field(2) # => nil + # row.field(-3) # => nil + # + # --- + # + # Fetch field value by header (first found): + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.field('Name') # => "Foo" + # + # Fetch field value by header, ignoring +offset+ leading fields: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.field('Name', 2) # => "Baz" + # + # Returns +nil+ if the header does not exist. + # + # source://csv//lib/csv/row.rb#203 + def field(header_or_index, minimum_index = T.unsafe(nil)); end + + # :call-seq: + # row.field?(value) -> true or false + # + # Returns +true+ if +value+ is a field in this row, +false+ otherwise: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.field?('Bar') # => true + # row.field?('BAR') # => false + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#589 + def field?(data); end + + # :call-seq: + # row.field_row? -> true or false + # + # Returns +true+ if this is a field row, +false+ otherwise. + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#148 + def field_row?; end + + # :call-seq: + # self.fields(*specifiers) -> array_of_fields + # + # Returns field values per the given +specifiers+, which may be any mixture of: + # - \Integer index. + # - \Range of \Integer indexes. + # - 2-element \Array containing a header and offset. + # - Header. + # - \Range of headers. + # + # For +specifier+ in one of the first four cases above, + # returns the result of self.field(specifier); see #field. + # + # Although there may be any number of +specifiers+, + # the examples here will illustrate one at a time. + # + # When the specifier is an \Integer +index+, + # returns self.field(index)L + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.fields(1) # => ["Bar"] + # + # When the specifier is a \Range of \Integers +range+, + # returns self.field(range): + # row.fields(1..2) # => ["Bar", "Baz"] + # + # When the specifier is a 2-element \Array +array+, + # returns self.field(array)L + # row.fields('Name', 1) # => ["Foo", "Bar"] + # + # When the specifier is a header +header+, + # returns self.field(header)L + # row.fields('Name') # => ["Foo"] + # + # When the specifier is a \Range of headers +range+, + # forms a new \Range +new_range+ from the indexes of + # range.start and range.end, + # and returns self.field(new_range): + # source = "Name,NAME,name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.fields('Name'..'NAME') # => ["Foo", "Bar"] + # + # Returns all fields if no argument given: + # row.fields # => ["Foo", "Bar", "Baz"] + # + # source://csv//lib/csv/row.rb#530 + def fields(*headers_and_or_indices); end + + # :call-seq: + # row.has_key?(header) -> true or false + # + # Returns +true+ if there is a field with the given +header+, + # +false+ otherwise. + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#279 + def has_key?(header); end + + # :call-seq: + # row.has_key?(header) -> true or false + # + # Returns +true+ if there is a field with the given +header+, + # +false+ otherwise. + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#279 + def header?(header); end + + # :call-seq: + # row.header_row? -> true or false + # + # Returns +true+ if this is a header row, +false+ otherwise. + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#140 + def header_row?; end + + # :call-seq: + # row.headers -> array_of_headers + # + # Returns the headers for this row: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table.first + # row.headers # => ["Name", "Value"] + # + # source://csv//lib/csv/row.rb#160 + def headers; end + + # :call-seq: + # row.has_key?(header) -> true or false + # + # Returns +true+ if there is a field with the given +header+, + # +false+ otherwise. + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#279 + def include?(header); end + + # :call-seq: + # index(header) -> index + # index(header, offset) -> index + # + # Returns the index for the given header, if it exists; + # otherwise returns +nil+. + # + # With the single argument +header+, returns the index + # of the first-found field with the given +header+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.index('Name') # => 0 + # row.index('NAME') # => nil + # + # With arguments +header+ and +offset+, + # returns the index of the first-found field with given +header+, + # but ignoring the first +offset+ fields: + # row.index('Name', 1) # => 1 + # row.index('Name', 3) # => nil + # + # source://csv//lib/csv/row.rb#573 + def index(header, minimum_index = T.unsafe(nil)); end + + # :call-seq: + # row.inspect -> string + # + # Returns an ASCII-compatible \String showing: + # - Class \CSV::Row. + # - Header-value pairs. + # Example: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.inspect # => "#" + # + # source://csv//lib/csv/row.rb#740 + def inspect; end + + # :call-seq: + # row.has_key?(header) -> true or false + # + # Returns +true+ if there is a field with the given +header+, + # +false+ otherwise. + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#279 + def key?(header); end + + # :call-seq: + # row.has_key?(header) -> true or false + # + # Returns +true+ if there is a field with the given +header+, + # +false+ otherwise. + # + # @return [Boolean] + # + # source://csv//lib/csv/row.rb#279 + def member?(header); end + + # :call-seq: + # row.push(*values) -> self + # + # Appends each of the given +values+ to +self+ as a field; returns +self+: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.push('Bat', 'Bam') + # row # => # + # + # source://csv//lib/csv/row.rb#410 + def push(*args); end + + # :call-seq: + # row.to_csv -> csv_string + # + # Returns the row as a \CSV String. Headers are not included: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.to_csv # => "foo,0\n" + # + # source://csv//lib/csv/row.rb#694 + def to_csv(**options); end + + # :call-seq: + # row.to_h -> hash + # + # Returns the new \Hash formed by adding each header-value pair in +self+ + # as a key-value pair in the \Hash. + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.to_h # => {"Name"=>"foo", "Value"=>"0"} + # + # Header order is preserved, but repeated headers are ignored: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.to_h # => {"Name"=>"Foo"} + # + # source://csv//lib/csv/row.rb#653 + def to_h; end + + # :call-seq: + # row.to_h -> hash + # + # Returns the new \Hash formed by adding each header-value pair in +self+ + # as a key-value pair in the \Hash. + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.to_h # => {"Name"=>"foo", "Value"=>"0"} + # + # Header order is preserved, but repeated headers are ignored: + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.to_h # => {"Name"=>"Foo"} + # + # source://csv//lib/csv/row.rb#653 + def to_hash; end + + # :call-seq: + # row.to_csv -> csv_string + # + # Returns the row as a \CSV String. Headers are not included: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.to_csv # => "foo,0\n" + # + # source://csv//lib/csv/row.rb#694 + def to_s(**options); end + + # :call-seq: + # self.fields(*specifiers) -> array_of_fields + # + # Returns field values per the given +specifiers+, which may be any mixture of: + # - \Integer index. + # - \Range of \Integer indexes. + # - 2-element \Array containing a header and offset. + # - Header. + # - \Range of headers. + # + # For +specifier+ in one of the first four cases above, + # returns the result of self.field(specifier); see #field. + # + # Although there may be any number of +specifiers+, + # the examples here will illustrate one at a time. + # + # When the specifier is an \Integer +index+, + # returns self.field(index)L + # source = "Name,Name,Name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.fields(1) # => ["Bar"] + # + # When the specifier is a \Range of \Integers +range+, + # returns self.field(range): + # row.fields(1..2) # => ["Bar", "Baz"] + # + # When the specifier is a 2-element \Array +array+, + # returns self.field(array)L + # row.fields('Name', 1) # => ["Foo", "Bar"] + # + # When the specifier is a header +header+, + # returns self.field(header)L + # row.fields('Name') # => ["Foo"] + # + # When the specifier is a \Range of headers +range+, + # forms a new \Range +new_range+ from the indexes of + # range.start and range.end, + # and returns self.field(new_range): + # source = "Name,NAME,name\nFoo,Bar,Baz\n" + # table = CSV.parse(source, headers: true) + # row = table[0] + # row.fields('Name'..'NAME') # => ["Foo", "Bar"] + # + # Returns all fields if no argument given: + # row.fields # => ["Foo", "Bar", "Baz"] + # + # source://csv//lib/csv/row.rb#530 + def values_at(*headers_and_or_indices); end + + protected + + # Internal data format used to compare equality. + # + # source://csv//lib/csv/row.rb#118 + def row; end + + private + + # :call-seq: + # row.initialize_copy(other_row) -> self + # + # Calls superclass method. + # + # source://csv//lib/csv/row.rb#130 + def initialize_copy(other); end +end + +# = \CSV::Table +# A \CSV::Table instance represents \CSV data. +# (see {class CSV}[../CSV.html]). +# +# The instance may have: +# - Rows: each is a Table::Row object. +# - Headers: names for the columns. +# +# === Instance Methods +# +# \CSV::Table has three groups of instance methods: +# - Its own internally defined instance methods. +# - Methods included by module Enumerable. +# - Methods delegated to class Array.: +# * Array#empty? +# * Array#length +# * Array#size +# +# == Creating a \CSV::Table Instance +# +# Commonly, a new \CSV::Table instance is created by parsing \CSV source +# using headers: +# source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(source, headers: true) +# table.class # => CSV::Table +# +# You can also create an instance directly. See ::new. +# +# == Headers +# +# If a table has headers, the headers serve as labels for the columns of data. +# Each header serves as the label for its column. +# +# The headers for a \CSV::Table object are stored as an \Array of Strings. +# +# Commonly, headers are defined in the first row of \CSV source: +# source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(source, headers: true) +# table.headers # => ["Name", "Value"] +# +# If no headers are defined, the \Array is empty: +# table = CSV::Table.new([]) +# table.headers # => [] +# +# == Access Modes +# +# \CSV::Table provides three modes for accessing table data: +# - \Row mode. +# - Column mode. +# - Mixed mode (the default for a new table). +# +# The access mode for a\CSV::Table instance affects the behavior +# of some of its instance methods: +# - #[] +# - #[]= +# - #delete +# - #delete_if +# - #each +# - #values_at +# +# === \Row Mode +# +# Set a table to row mode with method #by_row!: +# source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(source, headers: true) +# table.by_row! # => # +# +# Specify a single row by an \Integer index: +# # Get a row. +# table[1] # => # +# # Set a row, then get it. +# table[1] = CSV::Row.new(['Name', 'Value'], ['bam', 3]) +# table[1] # => # +# +# Specify a sequence of rows by a \Range: +# # Get rows. +# table[1..2] # => [#, #] +# # Set rows, then get them. +# table[1..2] = [ +# CSV::Row.new(['Name', 'Value'], ['bat', 4]), +# CSV::Row.new(['Name', 'Value'], ['bad', 5]), +# ] +# table[1..2] # => [["Name", #], ["Value", #]] +# +# === Column Mode +# +# Set a table to column mode with method #by_col!: +# source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(source, headers: true) +# table.by_col! # => # +# +# Specify a column by an \Integer index: +# # Get a column. +# table[0] +# # Set a column, then get it. +# table[0] = ['FOO', 'BAR', 'BAZ'] +# table[0] # => ["FOO", "BAR", "BAZ"] +# +# Specify a column by its \String header: +# # Get a column. +# table['Name'] # => ["FOO", "BAR", "BAZ"] +# # Set a column, then get it. +# table['Name'] = ['Foo', 'Bar', 'Baz'] +# table['Name'] # => ["Foo", "Bar", "Baz"] +# +# === Mixed Mode +# +# In mixed mode, you can refer to either rows or columns: +# - An \Integer index refers to a row. +# - A \Range index refers to multiple rows. +# - A \String index refers to a column. +# +# Set a table to mixed mode with method #by_col_or_row!: +# source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" +# table = CSV.parse(source, headers: true) +# table.by_col_or_row! # => # +# +# Specify a single row by an \Integer index: +# # Get a row. +# table[1] # => # +# # Set a row, then get it. +# table[1] = CSV::Row.new(['Name', 'Value'], ['bam', 3]) +# table[1] # => # +# +# Specify a sequence of rows by a \Range: +# # Get rows. +# table[1..2] # => [#, #] +# # Set rows, then get them. +# table[1] = CSV::Row.new(['Name', 'Value'], ['bat', 4]) +# table[2] = CSV::Row.new(['Name', 'Value'], ['bad', 5]) +# table[1..2] # => [["Name", #], ["Value", #]] +# +# Specify a column by its \String header: +# # Get a column. +# table['Name'] # => ["foo", "bat", "bad"] +# # Set a column, then get it. +# table['Name'] = ['Foo', 'Bar', 'Baz'] +# table['Name'] # => ["Foo", "Bar", "Baz"] +# +# source://csv//lib/csv/table.rb#144 +class CSV::Table + include ::Enumerable + extend ::Forwardable + + # :call-seq: + # CSV::Table.new(array_of_rows, headers = nil) -> csv_table + # + # Returns a new \CSV::Table object. + # + # - Argument +array_of_rows+ must be an \Array of CSV::Row objects. + # - Argument +headers+, if given, may be an \Array of Strings. + # + # --- + # + # Create an empty \CSV::Table object: + # table = CSV::Table.new([]) + # table # => # + # + # Create a non-empty \CSV::Table object: + # rows = [ + # CSV::Row.new([], []), + # CSV::Row.new([], []), + # CSV::Row.new([], []), + # ] + # table = CSV::Table.new(rows) + # table # => # + # + # --- + # + # If argument +headers+ is an \Array of Strings, + # those Strings become the table's headers: + # table = CSV::Table.new([], headers: ['Name', 'Age']) + # table.headers # => ["Name", "Age"] + # + # If argument +headers+ is not given and the table has rows, + # the headers are taken from the first row: + # rows = [ + # CSV::Row.new(['Foo', 'Bar'], []), + # CSV::Row.new(['foo', 'bar'], []), + # CSV::Row.new(['FOO', 'BAR'], []), + # ] + # table = CSV::Table.new(rows) + # table.headers # => ["Foo", "Bar"] + # + # If argument +headers+ is not given and the table is empty (has no rows), + # the headers are also empty: + # table = CSV::Table.new([]) + # table.headers # => [] + # + # --- + # + # Raises an exception if argument +array_of_rows+ is not an \Array object: + # # Raises NoMethodError (undefined method `first' for :foo:Symbol): + # CSV::Table.new(:foo) + # + # Raises an exception if an element of +array_of_rows+ is not a \CSV::Table object: + # # Raises NoMethodError (undefined method `headers' for :foo:Symbol): + # CSV::Table.new([:foo]) + # + # @return [Table] a new instance of Table + # + # source://csv//lib/csv/table.rb#199 + def initialize(array_of_rows, headers: T.unsafe(nil)); end + + # :call-seq: + # table << row_or_array -> self + # + # If +row_or_array+ is a \CSV::Row object, + # it is appended to the table: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table << CSV::Row.new(table.headers, ['bat', 3]) + # table[3] # => # + # + # If +row_or_array+ is an \Array, it is used to create a new + # \CSV::Row object which is then appended to the table: + # table << ['bam', 4] + # table[4] # => # + # + # source://csv//lib/csv/table.rb#762 + def <<(row_or_array); end + + # :call-seq: + # table == other_table -> true or false + # + # Returns +true+ if all each row of +self+ == + # the corresponding row of +other_table+, otherwise, +false+. + # + # The access mode does no affect the result. + # + # Equal tables: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # other_table = CSV.parse(source, headers: true) + # table == other_table # => true + # + # Different row count: + # other_table.delete(2) + # table == other_table # => false + # + # Different last row: + # other_table << ['bat', 3] + # table == other_table # => false + # + # source://csv//lib/csv/table.rb#965 + def ==(other); end + + # :call-seq: + # table[n] -> row or column_data + # table[range] -> array_of_rows or array_of_column_data + # table[header] -> array_of_column_data + # + # Returns data from the table; does not modify the table. + # + # --- + # + # Fetch a \Row by Its \Integer Index:: + # - Form: table[n], +n+ an integer. + # - Access mode: :row or :col_or_row. + # - Return value: _nth_ row of the table, if that row exists; + # otherwise +nil+. + # + # Returns the _nth_ row of the table if that row exists: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_row! # => # + # table[1] # => # + # table.by_col_or_row! # => # + # table[1] # => # + # + # Counts backward from the last row if +n+ is negative: + # table[-1] # => # + # + # Returns +nil+ if +n+ is too large or too small: + # table[4] # => nil + # table[-4] # => nil + # + # Raises an exception if the access mode is :row + # and +n+ is not an \Integer: + # table.by_row! # => # + # # Raises TypeError (no implicit conversion of String into Integer): + # table['Name'] + # + # --- + # + # Fetch a Column by Its \Integer Index:: + # - Form: table[n], +n+ an \Integer. + # - Access mode: :col. + # - Return value: _nth_ column of the table, if that column exists; + # otherwise an \Array of +nil+ fields of length self.size. + # + # Returns the _nth_ column of the table if that column exists: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_col! # => # + # table[1] # => ["0", "1", "2"] + # + # Counts backward from the last column if +n+ is negative: + # table[-2] # => ["foo", "bar", "baz"] + # + # Returns an \Array of +nil+ fields if +n+ is too large or too small: + # table[4] # => [nil, nil, nil] + # table[-4] # => [nil, nil, nil] + # + # --- + # + # Fetch Rows by \Range:: + # - Form: table[range], +range+ a \Range object. + # - Access mode: :row or :col_or_row. + # - Return value: rows from the table, beginning at row range.start, + # if those rows exists. + # + # Returns rows from the table, beginning at row range.first, + # if those rows exist: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_row! # => # + # rows = table[1..2] # => # + # rows # => [#, #] + # table.by_col_or_row! # => # + # rows = table[1..2] # => # + # rows # => [#, #] + # + # If there are too few rows, returns all from range.start to the end: + # rows = table[1..50] # => # + # rows # => [#, #] + # + # Special case: if range.start == table.size, returns an empty \Array: + # table[table.size..50] # => [] + # + # If range.end is negative, calculates the ending index from the end: + # rows = table[0..-1] + # rows # => [#, #, #] + # + # If range.start is negative, calculates the starting index from the end: + # rows = table[-1..2] + # rows # => [#] + # + # If range.start is larger than table.size, returns +nil+: + # table[4..4] # => nil + # + # --- + # + # Fetch Columns by \Range:: + # - Form: table[range], +range+ a \Range object. + # - Access mode: :col. + # - Return value: column data from the table, beginning at column range.start, + # if those columns exist. + # + # Returns column values from the table, if the column exists; + # the values are arranged by row: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_col! + # table[0..1] # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # Special case: if range.start == headers.size, + # returns an \Array (size: table.size) of empty \Arrays: + # table[table.headers.size..50] # => [[], [], []] + # + # If range.end is negative, calculates the ending index from the end: + # table[0..-1] # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # If range.start is negative, calculates the starting index from the end: + # table[-2..2] # => [["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # If range.start is larger than table.size, + # returns an \Array of +nil+ values: + # table[4..4] # => [nil, nil, nil] + # + # --- + # + # Fetch a Column by Its \String Header:: + # - Form: table[header], +header+ a \String header. + # - Access mode: :col or :col_or_row + # - Return value: column data from the table, if that +header+ exists. + # + # Returns column values from the table, if the column exists: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_col! # => # + # table['Name'] # => ["foo", "bar", "baz"] + # table.by_col_or_row! # => # + # col = table['Name'] + # col # => ["foo", "bar", "baz"] + # + # Modifying the returned column values does not modify the table: + # col[0] = 'bat' + # col # => ["bat", "bar", "baz"] + # table['Name'] # => ["foo", "bar", "baz"] + # + # Returns an \Array of +nil+ values if there is no such column: + # table['Nosuch'] # => [nil, nil, nil] + # + # source://csv//lib/csv/table.rb#514 + def [](index_or_header); end + + # :call-seq: + # table[n] = row -> row + # table[n] = field_or_array_of_fields -> field_or_array_of_fields + # table[header] = field_or_array_of_fields -> field_or_array_of_fields + # + # Puts data onto the table. + # + # --- + # + # Set a \Row by Its \Integer Index:: + # - Form: table[n] = row, +n+ an \Integer, + # +row+ a \CSV::Row instance or an \Array of fields. + # - Access mode: :row or :col_or_row. + # - Return value: +row+. + # + # If the row exists, it is replaced: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # new_row = CSV::Row.new(['Name', 'Value'], ['bat', 3]) + # table.by_row! # => # + # return_value = table[0] = new_row + # return_value.equal?(new_row) # => true # Returned the row + # table[0].to_h # => {"Name"=>"bat", "Value"=>3} + # + # With access mode :col_or_row: + # table.by_col_or_row! # => # + # table[0] = CSV::Row.new(['Name', 'Value'], ['bam', 4]) + # table[0].to_h # => {"Name"=>"bam", "Value"=>4} + # + # With an \Array instead of a \CSV::Row, inherits headers from the table: + # array = ['bad', 5] + # return_value = table[0] = array + # return_value.equal?(array) # => true # Returned the array + # table[0].to_h # => {"Name"=>"bad", "Value"=>5} + # + # If the row does not exist, extends the table by adding rows: + # assigns rows with +nil+ as needed: + # table.size # => 3 + # table[5] = ['bag', 6] + # table.size # => 6 + # table[3] # => nil + # table[4]# => nil + # table[5].to_h # => {"Name"=>"bag", "Value"=>6} + # + # Note that the +nil+ rows are actually +nil+, not a row of +nil+ fields. + # + # --- + # + # Set a Column by Its \Integer Index:: + # - Form: table[n] = array_of_fields, +n+ an \Integer, + # +array_of_fields+ an \Array of \String fields. + # - Access mode: :col. + # - Return value: +array_of_fields+. + # + # If the column exists, it is replaced: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # new_col = [3, 4, 5] + # table.by_col! # => # + # return_value = table[1] = new_col + # return_value.equal?(new_col) # => true # Returned the column + # table[1] # => [3, 4, 5] + # # The rows, as revised: + # table.by_row! # => # + # table[0].to_h # => {"Name"=>"foo", "Value"=>3} + # table[1].to_h # => {"Name"=>"bar", "Value"=>4} + # table[2].to_h # => {"Name"=>"baz", "Value"=>5} + # table.by_col! # => # + # + # If there are too few values, fills with +nil+ values: + # table[1] = [0] + # table[1] # => [0, nil, nil] + # + # If there are too many values, ignores the extra values: + # table[1] = [0, 1, 2, 3, 4] + # table[1] # => [0, 1, 2] + # + # If a single value is given, replaces all fields in the column with that value: + # table[1] = 'bat' + # table[1] # => ["bat", "bat", "bat"] + # + # --- + # + # Set a Column by Its \String Header:: + # - Form: table[header] = field_or_array_of_fields, + # +header+ a \String header, +field_or_array_of_fields+ a field value + # or an \Array of \String fields. + # - Access mode: :col or :col_or_row. + # - Return value: +field_or_array_of_fields+. + # + # If the column exists, it is replaced: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # new_col = [3, 4, 5] + # table.by_col! # => # + # return_value = table['Value'] = new_col + # return_value.equal?(new_col) # => true # Returned the column + # table['Value'] # => [3, 4, 5] + # # The rows, as revised: + # table.by_row! # => # + # table[0].to_h # => {"Name"=>"foo", "Value"=>3} + # table[1].to_h # => {"Name"=>"bar", "Value"=>4} + # table[2].to_h # => {"Name"=>"baz", "Value"=>5} + # table.by_col! # => # + # + # If there are too few values, fills with +nil+ values: + # table['Value'] = [0] + # table['Value'] # => [0, nil, nil] + # + # If there are too many values, ignores the extra values: + # table['Value'] = [0, 1, 2, 3, 4] + # table['Value'] # => [0, 1, 2] + # + # If the column does not exist, extends the table by adding columns: + # table['Note'] = ['x', 'y', 'z'] + # table['Note'] # => ["x", "y", "z"] + # # The rows, as revised: + # table.by_row! + # table[0].to_h # => {"Name"=>"foo", "Value"=>0, "Note"=>"x"} + # table[1].to_h # => {"Name"=>"bar", "Value"=>1, "Note"=>"y"} + # table[2].to_h # => {"Name"=>"baz", "Value"=>2, "Note"=>"z"} + # table.by_col! + # + # If a single value is given, replaces all fields in the column with that value: + # table['Value'] = 'bat' + # table['Value'] # => ["bat", "bat", "bat"] + # + # source://csv//lib/csv/table.rb#649 + def []=(index_or_header, value); end + + # :call-seq: + # table.by_col -> table_dup + # + # Returns a duplicate of +self+, in column mode + # (see {Column Mode}[#class-CSV::Table-label-Column+Mode]): + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.mode # => :col_or_row + # dup_table = table.by_col + # dup_table.mode # => :col + # dup_table.equal?(table) # => false # It's a dup + # + # This may be used to chain method calls without changing the mode + # (but also will affect performance and memory usage): + # dup_table.by_col['Name'] + # + # Also note that changes to the duplicate table will not affect the original. + # + # source://csv//lib/csv/table.rb#242 + def by_col; end + + # :call-seq: + # table.by_col! -> self + # + # Sets the mode for +self+ to column mode + # (see {Column Mode}[#class-CSV::Table-label-Column+Mode]); returns +self+: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.mode # => :col_or_row + # table1 = table.by_col! + # table.mode # => :col + # table1.equal?(table) # => true # Returned self + # + # source://csv//lib/csv/table.rb#257 + def by_col!; end + + # :call-seq: + # table.by_col_or_row -> table_dup + # + # Returns a duplicate of +self+, in mixed mode + # (see {Mixed Mode}[#class-CSV::Table-label-Mixed+Mode]): + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true).by_col! + # table.mode # => :col + # dup_table = table.by_col_or_row + # dup_table.mode # => :col_or_row + # dup_table.equal?(table) # => false # It's a dup + # + # This may be used to chain method calls without changing the mode + # (but also will affect performance and memory usage): + # dup_table.by_col_or_row['Name'] + # + # Also note that changes to the duplicate table will not affect the original. + # + # source://csv//lib/csv/table.rb#280 + def by_col_or_row; end + + # :call-seq: + # table.by_col_or_row! -> self + # + # Sets the mode for +self+ to mixed mode + # (see {Mixed Mode}[#class-CSV::Table-label-Mixed+Mode]); returns +self+: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true).by_col! + # table.mode # => :col + # table1 = table.by_col_or_row! + # table.mode # => :col_or_row + # table1.equal?(table) # => true # Returned self + # + # source://csv//lib/csv/table.rb#295 + def by_col_or_row!; end + + # :call-seq: + # table.by_row -> table_dup + # + # Returns a duplicate of +self+, in row mode + # (see {Row Mode}[#class-CSV::Table-label-Row+Mode]): + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.mode # => :col_or_row + # dup_table = table.by_row + # dup_table.mode # => :row + # dup_table.equal?(table) # => false # It's a dup + # + # This may be used to chain method calls without changing the mode + # (but also will affect performance and memory usage): + # dup_table.by_row[1] + # + # Also note that changes to the duplicate table will not affect the original. + # + # source://csv//lib/csv/table.rb#318 + def by_row; end + + # :call-seq: + # table.by_row! -> self + # + # Sets the mode for +self+ to row mode + # (see {Row Mode}[#class-CSV::Table-label-Row+Mode]); returns +self+: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.mode # => :col_or_row + # table1 = table.by_row! + # table.mode # => :row + # table1.equal?(table) # => true # Returned self + # + # source://csv//lib/csv/table.rb#333 + def by_row!; end + + # :call-seq: + # table.delete(*indexes) -> deleted_values + # table.delete(*headers) -> deleted_values + # + # If the access mode is :row or :col_or_row, + # and each argument is either an \Integer or a \Range, + # returns deleted rows. + # Otherwise, returns deleted columns data. + # + # In either case, the returned values are in the order + # specified by the arguments. Arguments may be repeated. + # + # --- + # + # Returns rows as an \Array of \CSV::Row objects. + # + # One index: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # deleted_values = table.delete(0) + # deleted_values # => [#] + # + # Two indexes: + # table = CSV.parse(source, headers: true) + # deleted_values = table.delete(2, 0) + # deleted_values # => [#, #] + # + # --- + # + # Returns columns data as column Arrays. + # + # One header: + # table = CSV.parse(source, headers: true) + # deleted_values = table.delete('Name') + # deleted_values # => ["foo", "bar", "baz"] + # + # Two headers: + # table = CSV.parse(source, headers: true) + # deleted_values = table.delete('Value', 'Name') + # deleted_values # => [["0", "1", "2"], ["foo", "bar", "baz"]] + # + # source://csv//lib/csv/table.rb#834 + def delete(*indexes_or_headers); end + + # :call-seq: + # table.delete_if {|row_or_column| ... } -> self + # + # Removes rows or columns for which the block returns a truthy value; + # returns +self+. + # + # Removes rows when the access mode is :row or :col_or_row; + # calls the block with each \CSV::Row object: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_row! # => # + # table.size # => 3 + # table.delete_if {|row| row['Name'].start_with?('b') } + # table.size # => 1 + # + # Removes columns when the access mode is :col; + # calls the block with each column as a 2-element array + # containing the header and an \Array of column fields: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_col! # => # + # table.headers.size # => 2 + # table.delete_if {|column_data| column_data[1].include?('2') } + # table.headers.size # => 1 + # + # Returns a new \Enumerator if no block is given: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.delete_if # => #:delete_if> + # + # source://csv//lib/csv/table.rb#887 + def delete_if(&block); end + + # Extracts the nested value specified by the sequence of +index+ or +header+ objects by calling dig at each step, + # returning nil if any intermediate step is nil. + # + # source://csv//lib/csv/table.rb#1021 + def dig(index_or_header, *index_or_headers); end + + # :call-seq: + # table.each {|row_or_column| ... ) -> self + # + # Calls the block with each row or column; returns +self+. + # + # When the access mode is :row or :col_or_row, + # calls the block with each \CSV::Row object: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.by_row! # => # + # table.each {|row| p row } + # Output: + # # + # # + # # + # + # When the access mode is :col, + # calls the block with each column as a 2-element array + # containing the header and an \Array of column fields: + # table.by_col! # => # + # table.each {|column_data| p column_data } + # Output: + # ["Name", ["foo", "bar", "baz"]] + # ["Value", ["0", "1", "2"]] + # + # Returns a new \Enumerator if no block is given: + # table.each # => #:each> + # + # source://csv//lib/csv/table.rb#930 + def each(&block); end + + # :call-seq: + # table.headers -> array_of_headers + # + # Returns a new \Array containing the \String headers for the table. + # + # If the table is not empty, returns the headers from the first row: + # rows = [ + # CSV::Row.new(['Foo', 'Bar'], []), + # CSV::Row.new(['FOO', 'BAR'], []), + # CSV::Row.new(['foo', 'bar'], []), + # ] + # table = CSV::Table.new(rows) + # table.headers # => ["Foo", "Bar"] + # table.delete(0) + # table.headers # => ["FOO", "BAR"] + # table.delete(0) + # table.headers # => ["foo", "bar"] + # + # If the table is empty, returns a copy of the headers in the table itself: + # table.delete(0) + # table.headers # => ["Foo", "Bar"] + # + # source://csv//lib/csv/table.rb#360 + def headers; end + + # :call-seq: + # table.inspect => string + # + # Returns a US-ASCII-encoded \String showing table: + # - Class: CSV::Table. + # - Access mode: :row, :col, or :col_or_row. + # - Size: Row count, including the header row. + # + # Example: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.inspect # => "#\nName,Value\nfoo,0\nbar,1\nbaz,2\n" + # + # source://csv//lib/csv/table.rb#1048 + def inspect; end + + # The current access mode for indexing and iteration. + # + # source://csv//lib/csv/table.rb#214 + def mode; end + + # :call-seq: + # table.push(*rows_or_arrays) -> self + # + # A shortcut for appending multiple rows. Equivalent to: + # rows.each {|row| self << row } + # + # Each argument may be either a \CSV::Row object or an \Array: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # rows = [ + # CSV::Row.new(table.headers, ['bat', 3]), + # ['bam', 4] + # ] + # table.push(*rows) + # table[3..4] # => [#, #] + # + # source://csv//lib/csv/table.rb#788 + def push(*rows); end + + # :call-seq: + # table.to_a -> array_of_arrays + # + # Returns the table as an \Array of \Arrays; + # the headers are in the first row: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.to_a # => [["Name", "Value"], ["foo", "0"], ["bar", "1"], ["baz", "2"]] + # + # source://csv//lib/csv/table.rb#978 + def to_a; end + + # :call-seq: + # table.to_csv(**options) -> csv_string + # + # Returns the table as \CSV string. + # See {Options for Generating}[../CSV.html#class-CSV-label-Options+for+Generating]. + # + # Defaults option +write_headers+ to +true+: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.to_csv # => "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # + # Omits the headers if option +write_headers+ is given as +false+ + # (see {Option +write_headers+}[../CSV.html#class-CSV-label-Option+write_headers]): + # table.to_csv(write_headers: false) # => "foo,0\nbar,1\nbaz,2\n" + # + # Limit rows if option +limit+ is given like +2+: + # table.to_csv(limit: 2) # => "Name,Value\nfoo,0\nbar,1\n" + # + # source://csv//lib/csv/table.rb#1004 + def to_csv(write_headers: T.unsafe(nil), limit: T.unsafe(nil), **options); end + + # :call-seq: + # table.to_csv(**options) -> csv_string + # + # Returns the table as \CSV string. + # See {Options for Generating}[../CSV.html#class-CSV-label-Options+for+Generating]. + # + # Defaults option +write_headers+ to +true+: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.to_csv # => "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # + # Omits the headers if option +write_headers+ is given as +false+ + # (see {Option +write_headers+}[../CSV.html#class-CSV-label-Option+write_headers]): + # table.to_csv(write_headers: false) # => "foo,0\nbar,1\nbaz,2\n" + # + # Limit rows if option +limit+ is given like +2+: + # table.to_csv(limit: 2) # => "Name,Value\nfoo,0\nbar,1\n" + # + # source://csv//lib/csv/table.rb#1004 + def to_s(write_headers: T.unsafe(nil), limit: T.unsafe(nil), **options); end + + # :call-seq: + # table.values_at(*indexes) -> array_of_rows + # table.values_at(*headers) -> array_of_columns_data + # + # If the access mode is :row or :col_or_row, + # and each argument is either an \Integer or a \Range, + # returns rows. + # Otherwise, returns columns data. + # + # In either case, the returned values are in the order + # specified by the arguments. Arguments may be repeated. + # + # --- + # + # Returns rows as an \Array of \CSV::Row objects. + # + # No argument: + # source = "Name,Value\nfoo,0\nbar,1\nbaz,2\n" + # table = CSV.parse(source, headers: true) + # table.values_at # => [] + # + # One index: + # values = table.values_at(0) + # values # => [#] + # + # Two indexes: + # values = table.values_at(2, 0) + # values # => [#, #] + # + # One \Range: + # values = table.values_at(1..2) + # values # => [#, #] + # + # \Ranges and indexes: + # values = table.values_at(0..1, 1..2, 0, 2) + # pp values + # Output: + # [#, + # #, + # #, + # #, + # #, + # #] + # + # --- + # + # Returns columns data as row Arrays, + # each consisting of the specified columns data for that row: + # values = table.values_at('Name') + # values # => [["foo"], ["bar"], ["baz"]] + # values = table.values_at('Value', 'Name') + # values # => [["0", "foo"], ["1", "bar"], ["2", "baz"]] + # + # source://csv//lib/csv/table.rb#734 + def values_at(*indices_or_headers); end + + protected + + # Internal data format used to compare equality. + # + # source://csv//lib/csv/table.rb#217 + def table; end +end + +# Note: Don't use this class directly. This is an internal class. +# +# source://csv//lib/csv/writer.rb#8 +class CSV::Writer + # @return [Writer] a new instance of Writer + # + # source://csv//lib/csv/writer.rb#16 + def initialize(output, options); end + + # Adds a new row + # + # source://csv//lib/csv/writer.rb#31 + def <<(row); end + + # Returns the value of attribute headers. + # + # source://csv//lib/csv/writer.rb#14 + def headers; end + + # A CSV::Writer receives an output, prepares the header, format and output. + # It allows us to write new rows in the object and rewind it. + # + # source://csv//lib/csv/writer.rb#13 + def lineno; end + + # Winds back to the beginning + # + # source://csv//lib/csv/writer.rb#64 + def rewind; end + + private + + # source://csv//lib/csv/writer.rb#70 + def prepare; end + + # source://csv//lib/csv/writer.rb#106 + def prepare_force_quotes_fields(force_quotes); end + + # source://csv//lib/csv/writer.rb#133 + def prepare_format; end + + # source://csv//lib/csv/writer.rb#78 + def prepare_header; end + + # source://csv//lib/csv/writer.rb#163 + def prepare_output; end + + # source://csv//lib/csv/writer.rb#190 + def quote(field, i); end + + # source://csv//lib/csv/writer.rb#181 + def quote_field(field); end +end + +class Object < ::BasicObject + include ::Kernel + include ::PP::ObjectMixin + + private + + # source://csv//lib/csv.rb#2876 + def CSV(*args, **options, &block); end +end + +# source://csv//lib/csv/core_ext/string.rb#1 +class String + include ::Comparable + + # Equivalent to CSV::parse_line(self, options) + # + # "CSV,data".parse_csv + # #=> ["CSV", "data"] + # + # source://csv//lib/csv/core_ext/string.rb#6 + def parse_csv(**options); end +end diff --git a/sorbet/rbi/gems/cucumber-ci-environment@9.2.0.rbi b/sorbet/rbi/gems/cucumber-ci-environment@10.0.1.rbi similarity index 56% rename from sorbet/rbi/gems/cucumber-ci-environment@9.2.0.rbi rename to sorbet/rbi/gems/cucumber-ci-environment@10.0.1.rbi index d33b69f7d..312d9e837 100644 --- a/sorbet/rbi/gems/cucumber-ci-environment@9.2.0.rbi +++ b/sorbet/rbi/gems/cucumber-ci-environment@10.0.1.rbi @@ -4,44 +4,42 @@ # This is an autogenerated file for types exported from the `cucumber-ci-environment` gem. # Please instead update this file by running `bin/tapioca gem cucumber-ci-environment`. + # source://cucumber-ci-environment//lib/cucumber/ci_environment/variable_expression.rb#1 module Cucumber class << self - # source://cucumber/8.0.0/lib/cucumber/deprecate.rb#52 - def deprecate(*args); end + # source://cucumber/9.2.0/lib/cucumber/deprecate.rb#7 + def deprecate(message, method, remove_after_version); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#21 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#17 def file_mode(mode, encoding = T.unsafe(nil)); end - # source://cucumber/8.0.0/lib/cucumber.rb#15 + # source://cucumber/9.2.0/lib/cucumber.rb#15 def logger; end - # source://cucumber/8.0.0/lib/cucumber.rb#23 + # source://cucumber/9.2.0/lib/cucumber.rb#23 def logger=(logger); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace; end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit=(_arg0); end end end -# source://cucumber/8.0.0/lib/cucumber/platform.rb#11 -Cucumber::BINARY = T.let(T.unsafe(nil), String) - # source://cucumber-ci-environment//lib/cucumber/ci_environment/variable_expression.rb#2 module Cucumber::CiEnvironment extend ::Cucumber::CiEnvironment::VariableExpression @@ -92,39 +90,3 @@ module Cucumber::CiEnvironment::VariableExpression # source://cucumber-ci-environment//lib/cucumber/ci_environment/variable_expression.rb#31 def get_value(variable, env); end end - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#9 -Cucumber::IRONRUBY = T.let(T.unsafe(nil), FalseClass) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#8 -Cucumber::JRUBY = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#12 -Cucumber::LIBDIR = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#11 -Cucumber::OS_X = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#13 -Cucumber::RAILS = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#15 -Cucumber::RUBY = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#14 -Cucumber::RUBY_1_9 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#13 -Cucumber::RUBY_2_0 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#14 -Cucumber::RUBY_BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#10 -Cucumber::VERSION = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#10 -Cucumber::WINDOWS = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#12 -Cucumber::WINDOWS_MRI = T.let(T.unsafe(nil), T.untyped) diff --git a/sorbet/rbi/gems/cucumber-core@11.0.0.rbi b/sorbet/rbi/gems/cucumber-core@13.0.3.rbi similarity index 65% rename from sorbet/rbi/gems/cucumber-core@11.0.0.rbi rename to sorbet/rbi/gems/cucumber-core@13.0.3.rbi index 5c992f536..7b247ee0b 100644 --- a/sorbet/rbi/gems/cucumber-core@11.0.0.rbi +++ b/sorbet/rbi/gems/cucumber-core@13.0.3.rbi @@ -4,45 +4,43 @@ # This is an autogenerated file for types exported from the `cucumber-core` gem. # Please instead update this file by running `bin/tapioca gem cucumber-core`. -# source://cucumber-core//lib/cucumber/core/platform.rb#6 + +# source://cucumber-core//lib/cucumber/core/platform.rb#7 module Cucumber class << self - # source://cucumber/8.0.0/lib/cucumber/deprecate.rb#52 - def deprecate(*args); end + # source://cucumber/9.2.0/lib/cucumber/deprecate.rb#7 + def deprecate(message, method, remove_after_version); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#21 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#17 def file_mode(mode, encoding = T.unsafe(nil)); end - # source://cucumber/8.0.0/lib/cucumber.rb#15 + # source://cucumber/9.2.0/lib/cucumber.rb#15 def logger; end - # source://cucumber/8.0.0/lib/cucumber.rb#23 + # source://cucumber/9.2.0/lib/cucumber.rb#23 def logger=(logger); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace; end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit=(_arg0); end end end -# source://cucumber/8.0.0/lib/cucumber/platform.rb#11 -Cucumber::BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber-core//lib/cucumber/core/event.rb#2 +# source://cucumber-core//lib/cucumber/core/event.rb#4 module Cucumber::Core # source://cucumber-core//lib/cucumber/core.rb#20 def compile(gherkin_documents, last_receiver, filters = T.unsafe(nil), event_bus = T.unsafe(nil)); end @@ -63,76 +61,84 @@ end # Compiles the Pickles into test cases # -# source://cucumber-core//lib/cucumber/core/compiler.rb#14 +# source://cucumber-core//lib/cucumber/core/compiler.rb#15 class Cucumber::Core::Compiler # @return [Compiler] a new instance of Compiler # - # source://cucumber-core//lib/cucumber/core/compiler.rb#18 + # source://cucumber-core//lib/cucumber/core/compiler.rb#19 def initialize(receiver, gherkin_query, event_bus = T.unsafe(nil)); end - # source://cucumber-core//lib/cucumber/core/compiler.rb#30 + # source://cucumber-core//lib/cucumber/core/compiler.rb#31 def done; end - # source://cucumber-core//lib/cucumber/core/compiler.rb#25 + # source://cucumber-core//lib/cucumber/core/compiler.rb#26 def pickle(pickle); end private - # source://cucumber-core//lib/cucumber/core/compiler.rb#55 + # source://cucumber-core//lib/cucumber/core/compiler.rb#57 def create_multiline_arg(pickle_step, _uri); end - # source://cucumber-core//lib/cucumber/core/compiler.rb#37 + # source://cucumber-core//lib/cucumber/core/compiler.rb#38 def create_test_case(pickle); end - # source://cucumber-core//lib/cucumber/core/compiler.rb#47 + # source://cucumber-core//lib/cucumber/core/compiler.rb#49 def create_test_step(pickle_step, uri); end + # source://cucumber-core//lib/cucumber/core/compiler.rb#103 + def data_table_from_pickle_step(pickle_step); end + + # source://cucumber-core//lib/cucumber/core/compiler.rb#95 + def doc_string_from_pickle_step(pickle_step); end + # Returns the value of attribute gherkin_query. # - # source://cucumber-core//lib/cucumber/core/compiler.rb#15 + # source://cucumber-core//lib/cucumber/core/compiler.rb#16 def gherkin_query; end # Returns the value of attribute id_generator. # - # source://cucumber-core//lib/cucumber/core/compiler.rb#15 + # source://cucumber-core//lib/cucumber/core/compiler.rb#16 def id_generator; end + # source://cucumber-core//lib/cucumber/core/compiler.rb#69 + def location_from_pickle(pickle); end + + # source://cucumber-core//lib/cucumber/core/compiler.rb#79 + def location_from_pickle_step(pickle_step, uri); end + + # source://cucumber-core//lib/cucumber/core/compiler.rb#74 + def parent_locations_from_pickle(pickle); end + # Returns the value of attribute receiver. # - # source://cucumber-core//lib/cucumber/core/compiler.rb#15 + # source://cucumber-core//lib/cucumber/core/compiler.rb#16 def receiver; end - # source://cucumber-core//lib/cucumber/core/compiler.rb#86 + # source://cucumber-core//lib/cucumber/core/compiler.rb#91 def source_line(id); end - # source://cucumber-core//lib/cucumber/core/compiler.rb#82 - def source_line_for_pickle_tag(tag); end - - # source://cucumber-core//lib/cucumber/core/compiler.rb#74 - def source_lines_for_pickle(pickle); end - - # source://cucumber-core//lib/cucumber/core/compiler.rb#78 - def source_lines_for_pickle_step(pickle_step); end + # source://cucumber-core//lib/cucumber/core/compiler.rb#84 + def tags_from_pickle(pickle, uri); end end -# source://cucumber-core//lib/cucumber/core/event.rb#3 +# source://cucumber-core//lib/cucumber/core/event.rb#5 class Cucumber::Core::Event class << self - #  @return [Symbol] the underscored name of the class to be used - #   as the key in an event registry. + # @return [Symbol] the underscored name of the class to be used as the key in an event registry # - # source://cucumber-core//lib/cucumber/core/event.rb#43 + # source://cucumber-core//lib/cucumber/core/event.rb#42 def event_id; end # Macro to generate new sub-classes of {Event} with # attribute readers. # - # source://cucumber-core//lib/cucumber/core/event.rb#7 - def new(*attributes); end + # source://cucumber-core//lib/cucumber/core/event.rb#8 + def new(*events); end private - # source://cucumber-core//lib/cucumber/core/event.rb#49 + # source://cucumber-core//lib/cucumber/core/event.rb#48 def underscore(string); end end end @@ -150,11 +156,9 @@ class Cucumber::Core::EventBus # source://cucumber-core//lib/cucumber/core/event_bus.rb#15 def initialize(registry = T.unsafe(nil)); end - #  Broadcast an event - # # @raise [ArgumentError] # - # source://cucumber-core//lib/cucumber/core/event_bus.rb#32 + # source://cucumber-core//lib/cucumber/core/event_bus.rb#30 def broadcast(event); end # Returns the value of attribute event_types. @@ -162,40 +166,44 @@ class Cucumber::Core::EventBus # source://cucumber-core//lib/cucumber/core/event_bus.rb#12 def event_types; end - # source://cucumber-core//lib/cucumber/core/event_bus.rb#38 + # source://cucumber-core//lib/cucumber/core/event_bus.rb#37 def method_missing(event_id, *args); end - #  Register for an event. The handler proc will be called back with each of the attributes - # of the event. + # Register for an event. The handler proc will be called back with each of the attributes of the event # - # source://cucumber-core//lib/cucumber/core/event_bus.rb#23 + # source://cucumber-core//lib/cucumber/core/event_bus.rb#22 def on(event_id, handler_object = T.unsafe(nil), &handler_proc); end private - # source://cucumber-core//lib/cucumber/core/event_bus.rb#45 + # source://cucumber-core//lib/cucumber/core/event_bus.rb#48 def broadcast_queued_events_to(handler, event_type); end - # source://cucumber-core//lib/cucumber/core/event_bus.rb#53 + # source://cucumber-core//lib/cucumber/core/event_bus.rb#52 def handlers_for(event_class); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/event_bus.rb#57 - def is_registered_id?(event_id); end + # source://cucumber-core//lib/cucumber/core/event_bus.rb#60 + def registered_id?(event_id); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/event_bus.rb#61 - def is_registered_type?(event_type); end + # source://cucumber-core//lib/cucumber/core/event_bus.rb#56 + def registered_type?(event_type); end + + # @return [Boolean] + # + # source://cucumber-core//lib/cucumber/core/event_bus.rb#42 + def respond_to_missing?(event_id, *args); end # @raise [ArgumentError] # - # source://cucumber-core//lib/cucumber/core/event_bus.rb#65 + # source://cucumber-core//lib/cucumber/core/event_bus.rb#64 def validate_handler_and_event_id!(handler, event_id); end end -# source://cucumber-core//lib/cucumber/core/events.rb#6 +# source://cucumber-core//lib/cucumber/core/events.rb#8 module Cucumber::Core::Events class << self # Build an event registry to be passed to the {EventBus} @@ -206,32 +214,32 @@ module Cucumber::Core::Events # # @return [Hash{Symbol => Class}] # - # source://cucumber-core//lib/cucumber/core/events.rb#97 + # source://cucumber-core//lib/cucumber/core/events.rb#89 def build_registry(*types); end # The registry contains all the events registered in the core, # that will be used by the {EventBus} by default. # - # source://cucumber-core//lib/cucumber/core/events.rb#77 + # source://cucumber-core//lib/cucumber/core/events.rb#69 def registry; end end end -# source://cucumber-core//lib/cucumber/core/events.rb#8 +# source://cucumber-core//lib/cucumber/core/events.rb#9 class Cucumber::Core::Events::Envelope < ::Cucumber::Core::Event # Returns the value of attribute envelope. # - # source://cucumber-core//lib/cucumber/core/events.rb#9 + # source://cucumber-core//lib/cucumber/core/events.rb#10 def envelope; end end # Signals that a gherkin source has been parsed # -# source://cucumber-core//lib/cucumber/core/events.rb#13 +# source://cucumber-core//lib/cucumber/core/events.rb#14 class Cucumber::Core::Events::GherkinSourceParsed < ::Cucumber::Core::Event # @return [GherkinDocument] the GherkinDocument Ast Node # - # source://cucumber-core//lib/cucumber/core/events.rb#15 + # source://cucumber-core//lib/cucumber/core/events.rb#16 def gherkin_document; end end @@ -252,16 +260,16 @@ end # Signals that a {Test::Case} has finished executing # -# source://cucumber-core//lib/cucumber/core/events.rb#65 +# source://cucumber-core//lib/cucumber/core/events.rb#59 class Cucumber::Core::Events::TestCaseFinished < ::Cucumber::Core::Event # @return [Test::Result] the result of running the {Test::Step} # - # source://cucumber-core//lib/cucumber/core/events.rb#71 + # source://cucumber-core//lib/cucumber/core/events.rb#64 def result; end # @return [Test::Case] that was executed # - # source://cucumber-core//lib/cucumber/core/events.rb#68 + # source://cucumber-core//lib/cucumber/core/events.rb#61 def test_case; end end @@ -271,7 +279,7 @@ end class Cucumber::Core::Events::TestCaseStarted < ::Cucumber::Core::Event # @return [Test::Case] the test case to be executed # - # source://cucumber-core//lib/cucumber/core/events.rb#41 + # source://cucumber-core//lib/cucumber/core/events.rb#40 def test_case; end end @@ -292,26 +300,26 @@ end # Signals that a {Test::Step} has finished executing # -# source://cucumber-core//lib/cucumber/core/events.rb#54 +# source://cucumber-core//lib/cucumber/core/events.rb#50 class Cucumber::Core::Events::TestStepFinished < ::Cucumber::Core::Event # @return [Test::Result] the result of running the {Test::Step} # - # source://cucumber-core//lib/cucumber/core/events.rb#60 + # source://cucumber-core//lib/cucumber/core/events.rb#55 def result; end # @return [Test::Step] the test step that was executed # - # source://cucumber-core//lib/cucumber/core/events.rb#57 + # source://cucumber-core//lib/cucumber/core/events.rb#52 def test_step; end end -#  Signals that a {Test::Step} is about to be executed +# Signals that a {Test::Step} is about to be executed # -# source://cucumber-core//lib/cucumber/core/events.rb#46 +# source://cucumber-core//lib/cucumber/core/events.rb#44 class Cucumber::Core::Events::TestStepStarted < ::Cucumber::Core::Event # @return [Test::Step] the test step to be executed # - # source://cucumber-core//lib/cucumber/core/events.rb#49 + # source://cucumber-core//lib/cucumber/core/events.rb#46 def test_step; end end @@ -354,12 +362,12 @@ module Cucumber::Core::Filter # end # end # - # source://cucumber-core//lib/cucumber/core/filter.rb#43 + # source://cucumber-core//lib/cucumber/core/filter.rb#42 def new(*attributes, &block); end end end -# source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#6 +# source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#7 module Cucumber::Core::Gherkin; end # source://cucumber-core//lib/cucumber/core/gherkin/document.rb#6 @@ -391,130 +399,153 @@ class Cucumber::Core::Gherkin::Document def uri; end end -# source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#7 +# source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#8 class Cucumber::Core::Gherkin::ParseError < ::StandardError; end -# source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#9 +# source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#10 class Cucumber::Core::Gherkin::Parser # @return [Parser] a new instance of Parser # - # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#13 + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#14 def initialize(receiver, event_bus, gherkin_query); end - # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#19 + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#20 def document(document); end - # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#45 + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#35 def done; end - # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#36 + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#26 def gherkin_options(document); end private # Returns the value of attribute event_bus. # - # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#10 + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#11 def event_bus; end + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#58 + def generate_envelope(message); end + # Returns the value of attribute gherkin_query. # - # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#10 + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#11 def gherkin_query; end + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#46 + def process(message, document); end + # Returns the value of attribute receiver. # - # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#10 + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#11 def receiver; end + + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#42 + def source_messages(document); end + + # @return [Boolean] + # + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#66 + def type?(message); end + + # source://cucumber-core//lib/cucumber/core/gherkin/parser.rb#62 + def update_gherkin_query(message); end end -# source://cucumber-core//lib/cucumber/core/report/summary.rb#4 +# source://cucumber-core//lib/cucumber/core/report/summary.rb#5 module Cucumber::Core::Report; end -# source://cucumber-core//lib/cucumber/core/report/summary.rb#5 +# source://cucumber-core//lib/cucumber/core/report/summary.rb#6 class Cucumber::Core::Report::Summary # @return [Summary] a new instance of Summary # - # source://cucumber-core//lib/cucumber/core/report/summary.rb#8 + # source://cucumber-core//lib/cucumber/core/report/summary.rb#9 def initialize(event_bus); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/report/summary.rb#15 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/report/summary.rb#16 + def ok?(strict: T.unsafe(nil)); end # Returns the value of attribute test_cases. # - # source://cucumber-core//lib/cucumber/core/report/summary.rb#6 + # source://cucumber-core//lib/cucumber/core/report/summary.rb#7 def test_cases; end # Returns the value of attribute test_steps. # - # source://cucumber-core//lib/cucumber/core/report/summary.rb#6 + # source://cucumber-core//lib/cucumber/core/report/summary.rb#7 def test_steps; end private - # source://cucumber-core//lib/cucumber/core/report/summary.rb#21 + # source://cucumber-core//lib/cucumber/core/report/summary.rb#28 + def register_test_case_finished_listener(event_bus); end + + # source://cucumber-core//lib/cucumber/core/report/summary.rb#40 + def register_test_step_finished_listener(event_bus); end + + # source://cucumber-core//lib/cucumber/core/report/summary.rb#22 def subscribe_to(event_bus); end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#8 +# source://cucumber-core//lib/cucumber/core/test/result.rb#9 module Cucumber::Core::Test; end -# source://cucumber-core//lib/cucumber/core/test/action.rb#9 +# source://cucumber-core//lib/cucumber/core/test/actions/action.rb#10 class Cucumber::Core::Test::Action # @raise [ArgumentError] # @return [Action] a new instance of Action # - # source://cucumber-core//lib/cucumber/core/test/action.rb#10 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#11 def initialize(location = T.unsafe(nil), &block); end - # source://cucumber-core//lib/cucumber/core/test/action.rb#21 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#23 def execute(*args); end - # source://cucumber-core//lib/cucumber/core/test/action.rb#35 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#37 def inspect; end - # source://cucumber-core//lib/cucumber/core/test/action.rb#31 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#33 def location; end - # source://cucumber-core//lib/cucumber/core/test/action.rb#17 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#19 def skip(*_arg0); end private - # source://cucumber-core//lib/cucumber/core/test/action.rb#45 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#47 def failed(exception); end - # source://cucumber-core//lib/cucumber/core/test/action.rb#41 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#43 def passed; end - # source://cucumber-core//lib/cucumber/core/test/action.rb#49 + # source://cucumber-core//lib/cucumber/core/test/actions/action.rb#51 def skipped; end end -# source://cucumber-core//lib/cucumber/core/test/around_hook.rb#5 +# source://cucumber-core//lib/cucumber/core/test/around_hook.rb#6 class Cucumber::Core::Test::AroundHook # @return [AroundHook] a new instance of AroundHook # - # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#6 + # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#7 def initialize(&block); end - # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#11 + # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#12 def describe_to(visitor, *args, &continue); end - # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#19 - def execute(*args, &continue); end + # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#20 + def execute(*_args, &continue); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#15 + # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#16 def hook?; end private - # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#30 + # source://cucumber-core//lib/cucumber/core/test/around_hook.rb#32 def failed(exception); end end @@ -524,9 +555,9 @@ class Cucumber::Core::Test::Case # @return [Case] a new instance of Case # # source://cucumber-core//lib/cucumber/core/test/case.rb#12 - def initialize(id, name, test_steps, location, tags, language, around_hooks = T.unsafe(nil)); end + def initialize(id, name, test_steps, location, parent_locations, tags, language, around_hooks = T.unsafe(nil)); end - # source://cucumber-core//lib/cucumber/core/test/case.rb#72 + # source://cucumber-core//lib/cucumber/core/test/case.rb#85 def ==(other); end # Returns the value of attribute around_hooks. @@ -534,15 +565,15 @@ class Cucumber::Core::Test::Case # source://cucumber-core//lib/cucumber/core/test/case.rb#10 def around_hooks; end - # source://cucumber-core//lib/cucumber/core/test/case.rb#27 + # source://cucumber-core//lib/cucumber/core/test/case.rb#29 def describe_to(visitor, *args); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/case.rb#68 + # source://cucumber-core//lib/cucumber/core/test/case.rb#81 def eql?(other); end - # source://cucumber-core//lib/cucumber/core/test/case.rb#64 + # source://cucumber-core//lib/cucumber/core/test/case.rb#77 def hash; end # Returns the value of attribute id. @@ -550,7 +581,7 @@ class Cucumber::Core::Test::Case # source://cucumber-core//lib/cucumber/core/test/case.rb#10 def id; end - # source://cucumber-core//lib/cucumber/core/test/case.rb#60 + # source://cucumber-core//lib/cucumber/core/test/case.rb#73 def inspect; end # Returns the value of attribute language. @@ -565,25 +596,33 @@ class Cucumber::Core::Test::Case # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/case.rb#54 + # source://cucumber-core//lib/cucumber/core/test/case.rb#56 def match_locations?(queried_locations); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/case.rb#50 + # source://cucumber-core//lib/cucumber/core/test/case.rb#52 def match_name?(name_regexp); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/case.rb#46 + # source://cucumber-core//lib/cucumber/core/test/case.rb#48 def match_tags?(*expressions); end + # source://cucumber-core//lib/cucumber/core/test/case.rb#64 + def matching_locations; end + # Returns the value of attribute name. # # source://cucumber-core//lib/cucumber/core/test/case.rb#10 def name; end - # source://cucumber-core//lib/cucumber/core/test/case.rb#23 + # Returns the value of attribute parent_locations. + # + # source://cucumber-core//lib/cucumber/core/test/case.rb#10 + def parent_locations; end + + # source://cucumber-core//lib/cucumber/core/test/case.rb#25 def step_count; end # Returns the value of attribute tags. @@ -596,20 +635,20 @@ class Cucumber::Core::Test::Case # source://cucumber-core//lib/cucumber/core/test/case.rb#10 def test_steps; end - # source://cucumber-core//lib/cucumber/core/test/case.rb#42 + # source://cucumber-core//lib/cucumber/core/test/case.rb#44 def with_around_hooks(around_hooks); end - # source://cucumber-core//lib/cucumber/core/test/case.rb#38 + # source://cucumber-core//lib/cucumber/core/test/case.rb#40 def with_steps(test_steps); end private - # source://cucumber-core//lib/cucumber/core/test/case.rb#78 + # source://cucumber-core//lib/cucumber/core/test/case.rb#91 def compose_around_hooks(visitor, *args, &block); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/case.rb#84 + # source://cucumber-core//lib/cucumber/core/test/case.rb#97 def match_single_tag_expression?(expression); end end @@ -644,7 +683,7 @@ class Cucumber::Core::Test::DataTable # source://cucumber-core//lib/cucumber/core/test/data_table.rb#31 def initialize(rows); end - # source://cucumber-core//lib/cucumber/core/test/data_table.rb#83 + # source://cucumber-core//lib/cucumber/core/test/data_table.rb#87 def ==(other); end # @return [Boolean] @@ -665,9 +704,12 @@ class Cucumber::Core::Test::DataTable # source://cucumber-core//lib/cucumber/core/test/data_table.rb#56 def dup; end - # source://cucumber-core//lib/cucumber/core/test/data_table.rb#87 + # source://cucumber-core//lib/cucumber/core/test/data_table.rb#91 def inspect; end + # source://cucumber-core//lib/cucumber/core/test/data_table.rb#83 + def lines_count; end + # source://cucumber-core//lib/cucumber/core/test/data_table.rb#75 def map(&block); end @@ -695,13 +737,13 @@ class Cucumber::Core::Test::DataTable private - # source://cucumber-core//lib/cucumber/core/test/data_table.rb#101 + # source://cucumber-core//lib/cucumber/core/test/data_table.rb#103 def ensure_array_of_array(array); end - # source://cucumber-core//lib/cucumber/core/test/data_table.rb#105 + # source://cucumber-core//lib/cucumber/core/test/data_table.rb#107 def hashes_to_array(hashes); end - # source://cucumber-core//lib/cucumber/core/test/data_table.rb#93 + # source://cucumber-core//lib/cucumber/core/test/data_table.rb#97 def verify_rows_are_same_length(raw); end end @@ -721,120 +763,123 @@ end # # Note how the indentation from the source is stripped away. # -# source://cucumber-core//lib/cucumber/core/test/doc_string.rb#22 +# source://cucumber-core//lib/cucumber/core/test/doc_string.rb#23 class Cucumber::Core::Test::DocString < ::SimpleDelegator # @return [DocString] a new instance of DocString # - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#25 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#26 def initialize(content, content_type); end - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#53 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#59 def ==(other); end # Returns the value of attribute content. # - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#23 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#24 def content; end # Returns the value of attribute content_type. # - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#23 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#24 def content_type; end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#35 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#36 def data_table?; end - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#31 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#32 def describe_to(visitor, *args); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#39 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#40 def doc_string?; end - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#63 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#70 def inspect; end + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#55 + def lines_count; end + # @raise [ArgumentError] # - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#43 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#44 def map; end - # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#49 + # source://cucumber-core//lib/cucumber/core/test/doc_string.rb#51 def to_step_definition_arg; end end -# source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#5 +# source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#6 class Cucumber::Core::Test::EmptyMultilineArgument - # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#22 - def all_locations; end - # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#10 + # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#11 def data_table?; end - # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#6 + # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#7 def describe_to(*_arg0); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#14 + # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#15 def doc_string?; end - # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#26 + # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#27 def inspect; end - # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#18 - def map(&block); end + # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#23 + def lines_count; end + + # source://cucumber-core//lib/cucumber/core/test/empty_multiline_argument.rb#19 + def map; end end -# source://cucumber-core//lib/cucumber/core/test/location.rb#139 +# source://cucumber-core//lib/cucumber/core/test/location.rb#146 module Cucumber::Core::Test::HasLocation - # source://cucumber-core//lib/cucumber/core/test/location.rb#158 + # source://cucumber-core//lib/cucumber/core/test/location.rb#165 def attributes; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#167 + # source://cucumber-core//lib/cucumber/core/test/location.rb#174 def comments; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#144 + # source://cucumber-core//lib/cucumber/core/test/location.rb#151 def file; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#140 + # source://cucumber-core//lib/cucumber/core/test/location.rb#147 def file_colon_line; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#148 + # source://cucumber-core//lib/cucumber/core/test/location.rb#155 def line; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#152 + # source://cucumber-core//lib/cucumber/core/test/location.rb#159 def location; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#172 + # source://cucumber-core//lib/cucumber/core/test/location.rb#179 def multiline_arg; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#162 + # source://cucumber-core//lib/cucumber/core/test/location.rb#169 def tags; end end -# source://cucumber-core//lib/cucumber/core/test/step.rb#59 +# source://cucumber-core//lib/cucumber/core/test/hook_step.rb#8 class Cucumber::Core::Test::HookStep < ::Cucumber::Core::Test::Step # @return [HookStep] a new instance of HookStep # - # source://cucumber-core//lib/cucumber/core/test/step.rb#60 + # source://cucumber-core//lib/cucumber/core/test/hook_step.rb#9 def initialize(id, text, location, action); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/step.rb#64 + # source://cucumber-core//lib/cucumber/core/test/hook_step.rb#13 def hook?; end end -# source://cucumber-core//lib/cucumber/core/test/location.rb#7 +# source://cucumber-core//lib/cucumber/core/test/location.rb#8 class Cucumber::Core::Test::IncompatibleLocations < ::StandardError; end -# source://cucumber-core//lib/cucumber/core/test/location.rb#9 +# source://cucumber-core//lib/cucumber/core/test/location.rb#10 module Cucumber::Core::Test::Location class << self # source://cucumber-core//lib/cucumber/core/test/location.rb#15 @@ -851,34 +896,34 @@ module Cucumber::Core::Test::Location end end -# source://cucumber-core//lib/cucumber/core/test/location.rb#92 +# source://cucumber-core//lib/cucumber/core/test/location.rb#99 class Cucumber::Core::Test::Location::Lines < ::Struct # @return [Lines] a new instance of Lines # - # source://cucumber-core//lib/cucumber/core/test/location.rb#95 + # source://cucumber-core//lib/cucumber/core/test/location.rb#102 def initialize(raw_data); end - # source://cucumber-core//lib/cucumber/core/test/location.rb#115 + # source://cucumber-core//lib/cucumber/core/test/location.rb#122 def +(other); end - # source://cucumber-core//lib/cucumber/core/test/location.rb#99 + # source://cucumber-core//lib/cucumber/core/test/location.rb#106 def first; end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/location.rb#111 + # source://cucumber-core//lib/cucumber/core/test/location.rb#118 def include?(other); end - # source://cucumber-core//lib/cucumber/core/test/location.rb#127 + # source://cucumber-core//lib/cucumber/core/test/location.rb#134 def inspect; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#107 + # source://cucumber-core//lib/cucumber/core/test/location.rb#114 def max; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#103 + # source://cucumber-core//lib/cucumber/core/test/location.rb#110 def min; end - # source://cucumber-core//lib/cucumber/core/test/location.rb#120 + # source://cucumber-core//lib/cucumber/core/test/location.rb#127 def to_s; end protected @@ -890,7 +935,7 @@ class Cucumber::Core::Test::Location::Lines < ::Struct # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/location.rb#133 + # source://cucumber-core//lib/cucumber/core/test/location.rb#140 def range?; end end @@ -904,7 +949,7 @@ class Cucumber::Core::Test::Location::Precise < ::Struct # source://cucumber-core//lib/cucumber/core/test/location.rb#56 def include?(other_lines); end - # source://cucumber-core//lib/cucumber/core/test/location.rb#86 + # source://cucumber-core//lib/cucumber/core/test/location.rb#93 def inspect; end # source://cucumber-core//lib/cucumber/core/test/location.rb#60 @@ -916,6 +961,9 @@ class Cucumber::Core::Test::Location::Precise < ::Struct def match?(other); end # source://cucumber-core//lib/cucumber/core/test/location.rb#82 + def merge(multiline_arg); end + + # source://cucumber-core//lib/cucumber/core/test/location.rb#89 def on_line(new_line); end # source://cucumber-core//lib/cucumber/core/test/location.rb#70 @@ -930,7 +978,7 @@ class Cucumber::Core::Test::Location::Wildcard < ::Struct # @return [Boolean] # # source://cucumber-core//lib/cucumber/core/test/location.rb#50 - def include?(lines); end + def include?(_lines); end # @return [Boolean] # @@ -945,22 +993,22 @@ end # # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#9 class Cucumber::Core::Test::LocationsFilter - # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#16 + # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#15 def done; end - # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#11 + # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#10 def test_case(test_case); end private - # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#26 + # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#25 def sorted_test_cases; end - # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#34 + # source://cucumber-core//lib/cucumber/core/test/filters/locations_filter.rb#33 def test_cases; end end -# source://cucumber-core//lib/cucumber/core/test/filters/name_filter.rb#7 +# source://cucumber-core//lib/cucumber/core/test/filters/name_filter.rb#8 class Cucumber::Core::Test::NameFilter # source://cucumber-core//lib/cucumber/core/test/filters/name_filter.rb#9 def test_case(test_case); end @@ -973,88 +1021,88 @@ class Cucumber::Core::Test::NameFilter def accept?(test_case); end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#9 +# source://cucumber-core//lib/cucumber/core/test/result.rb#10 module Cucumber::Core::Test::Result class << self # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#13 - def ok?(type, be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#14 + def ok?(type, strict: T.unsafe(nil)); end # Defines to_sym on a result class for the given result type # # Defines predicate methods on a result class with only the given one # returning true # - # source://cucumber-core//lib/cucumber/core/test/result.rb#22 + # source://cucumber-core//lib/cucumber/core/test/result.rb#23 def query_methods(result_type); end end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#397 +# source://cucumber-core//lib/cucumber/core/test/result.rb#406 class Cucumber::Core::Test::Result::Duration include ::Cucumber::Messages::TimeConversion # @return [Duration] a new instance of Duration # - # source://cucumber-core//lib/cucumber/core/test/result.rb#402 + # source://cucumber-core//lib/cucumber/core/test/result.rb#411 def initialize(nanoseconds); end # Returns the value of attribute nanoseconds. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#400 + # source://cucumber-core//lib/cucumber/core/test/result.rb#409 def nanoseconds; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#406 + # source://cucumber-core//lib/cucumber/core/test/result.rb#415 def to_message_duration; end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#99 +# source://cucumber-core//lib/cucumber/core/test/result.rb#101 class Cucumber::Core::Test::Result::Failed # @raise [ArgumentError] # @return [Failed] a new instance of Failed # - # source://cucumber-core//lib/cucumber/core/test/result.rb#108 + # source://cucumber-core//lib/cucumber/core/test/result.rb#110 def initialize(duration, exception); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#115 + # source://cucumber-core//lib/cucumber/core/test/result.rb#118 def describe_to(visitor, *args); end # Returns the value of attribute duration. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#102 + # source://cucumber-core//lib/cucumber/core/test/result.rb#104 def duration; end # Returns the value of attribute exception. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#102 + # source://cucumber-core//lib/cucumber/core/test/result.rb#104 def exception; end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#140 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#143 + def ok?(*_arg0); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#126 + # source://cucumber-core//lib/cucumber/core/test/result.rb#129 def to_message; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#122 + # source://cucumber-core//lib/cucumber/core/test/result.rb#125 def to_s; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#148 + # source://cucumber-core//lib/cucumber/core/test/result.rb#151 def with_appended_backtrace(step); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#144 + # source://cucumber-core//lib/cucumber/core/test/result.rb#147 def with_duration(new_duration); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#153 + # source://cucumber-core//lib/cucumber/core/test/result.rb#156 def with_filtered_backtrace(filter); end class << self # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#104 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#106 + def ok?(*_arg0); end end end @@ -1062,186 +1110,185 @@ end # reporting result type for test cases that fails and the passes on # retry, therefore only the class method self.ok? is needed. # -# source://cucumber-core//lib/cucumber/core/test/result.rb#161 +# source://cucumber-core//lib/cucumber/core/test/result.rb#164 class Cucumber::Core::Test::Result::Flaky class << self # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#162 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#165 + def ok?(strict: T.unsafe(nil)); end end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#56 +# source://cucumber-core//lib/cucumber/core/test/result.rb#57 class Cucumber::Core::Test::Result::Passed # @raise [ArgumentError] # @return [Passed] a new instance of Passed # - # source://cucumber-core//lib/cucumber/core/test/result.rb#64 + # source://cucumber-core//lib/cucumber/core/test/result.rb#65 def initialize(duration); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#69 + # source://cucumber-core//lib/cucumber/core/test/result.rb#71 def describe_to(visitor, *args); end # Returns the value of attribute duration. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#58 + # source://cucumber-core//lib/cucumber/core/test/result.rb#59 def duration; end # Sets the attribute duration # # @param value the value to set the attribute duration to. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#58 + # source://cucumber-core//lib/cucumber/core/test/result.rb#59 def duration=(_arg0); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#86 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#88 + def ok?(*_arg0); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#79 + # source://cucumber-core//lib/cucumber/core/test/result.rb#81 def to_message; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#75 + # source://cucumber-core//lib/cucumber/core/test/result.rb#77 def to_s; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#90 - def with_appended_backtrace(step); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#92 + def with_appended_backtrace(_step); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#94 - def with_filtered_backtrace(filter); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#96 + def with_filtered_backtrace(_filter); end class << self # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#60 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#61 + def ok?(*_arg0); end end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#253 +# source://cucumber-core//lib/cucumber/core/test/result.rb#258 class Cucumber::Core::Test::Result::Pending < ::Cucumber::Core::Test::Result::Raisable - # source://cucumber-core//lib/cucumber/core/test/result.rb#260 + # source://cucumber-core//lib/cucumber/core/test/result.rb#265 def describe_to(visitor, *args); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#270 + # source://cucumber-core//lib/cucumber/core/test/result.rb#275 def to_message; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#266 + # source://cucumber-core//lib/cucumber/core/test/result.rb#271 def to_s; end class << self # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#256 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#261 + def ok?(strict: T.unsafe(nil)); end end end # Base class for exceptions that can be raised in a step definition causing # the step to have that result. # -# source://cucumber-core//lib/cucumber/core/test/result.rb#169 +# source://cucumber-core//lib/cucumber/core/test/result.rb#172 class Cucumber::Core::Test::Result::Raisable < ::StandardError # @return [Raisable] a new instance of Raisable # - # source://cucumber-core//lib/cucumber/core/test/result.rb#172 + # source://cucumber-core//lib/cucumber/core/test/result.rb#175 def initialize(message = T.unsafe(nil), duration = T.unsafe(nil), backtrace = T.unsafe(nil)); end # Returns the value of attribute duration. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#170 + # source://cucumber-core//lib/cucumber/core/test/result.rb#173 def duration; end # Returns the value of attribute message. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#170 + # source://cucumber-core//lib/cucumber/core/test/result.rb#173 def message; end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#198 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#203 + def ok?(strict: T.unsafe(nil)); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#186 + # source://cucumber-core//lib/cucumber/core/test/result.rb#189 def with_appended_backtrace(step); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#182 + # source://cucumber-core//lib/cucumber/core/test/result.rb#185 def with_duration(new_duration); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#193 + # source://cucumber-core//lib/cucumber/core/test/result.rb#197 def with_filtered_backtrace(filter); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#178 + # source://cucumber-core//lib/cucumber/core/test/result.rb#181 def with_message(new_message); end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#11 +# source://cucumber-core//lib/cucumber/core/test/result.rb#12 Cucumber::Core::Test::Result::STRICT_AFFECTED_TYPES = T.let(T.unsafe(nil), Array) -# source://cucumber-core//lib/cucumber/core/test/result.rb#228 +# source://cucumber-core//lib/cucumber/core/test/result.rb#233 class Cucumber::Core::Test::Result::Skipped < ::Cucumber::Core::Test::Result::Raisable - # source://cucumber-core//lib/cucumber/core/test/result.rb#235 + # source://cucumber-core//lib/cucumber/core/test/result.rb#240 def describe_to(visitor, *args); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#245 + # source://cucumber-core//lib/cucumber/core/test/result.rb#250 def to_message; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#241 + # source://cucumber-core//lib/cucumber/core/test/result.rb#246 def to_s; end class << self # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#231 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#236 + def ok?(*_arg0); end end end # Handles the strict settings for the result types that are # affected by the strict options (that is the STRICT_AFFECTED_TYPES). # -# source://cucumber-core//lib/cucumber/core/test/result.rb#280 +# source://cucumber-core//lib/cucumber/core/test/result.rb#285 class Cucumber::Core::Test::Result::StrictConfiguration # @return [StrictConfiguration] a new instance of StrictConfiguration # - # source://cucumber-core//lib/cucumber/core/test/result.rb#284 + # source://cucumber-core//lib/cucumber/core/test/result.rb#289 def initialize(strict_types = T.unsafe(nil)); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#314 + # source://cucumber-core//lib/cucumber/core/test/result.rb#320 def merge!(other); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#321 + # source://cucumber-core//lib/cucumber/core/test/result.rb#327 def set?(type); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#304 + # source://cucumber-core//lib/cucumber/core/test/result.rb#310 def set_strict(setting, type = T.unsafe(nil)); end # Sets the attribute settings # # @param value the value to set the attribute settings to. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#281 + # source://cucumber-core//lib/cucumber/core/test/result.rb#286 def settings=(_arg0); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#291 + # source://cucumber-core//lib/cucumber/core/test/result.rb#296 def strict?(type = T.unsafe(nil)); end private # Returns the value of attribute settings. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#281 + # source://cucumber-core//lib/cucumber/core/test/result.rb#286 def settings; end end -#  An object that responds to the description protocol from the results -# and collects summary information. +# An object that responds to the description protocol from the results and collects summary information. # # e.g. # summary = Result::Summary.new @@ -1249,235 +1296,240 @@ end # puts summary.total_passed # => 1 # -# source://cucumber-core//lib/cucumber/core/test/result.rb#336 +# source://cucumber-core//lib/cucumber/core/test/result.rb#341 class Cucumber::Core::Test::Result::Summary # @return [Summary] a new instance of Summary # - # source://cucumber-core//lib/cucumber/core/test/result.rb#339 + # source://cucumber-core//lib/cucumber/core/test/result.rb#344 def initialize; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#380 + # source://cucumber-core//lib/cucumber/core/test/result.rb#389 def decrement_failed; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#367 + # source://cucumber-core//lib/cucumber/core/test/result.rb#376 def duration(duration); end # Returns the value of attribute durations. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#337 + # source://cucumber-core//lib/cucumber/core/test/result.rb#342 def durations; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#362 + # source://cucumber-core//lib/cucumber/core/test/result.rb#371 def exception(exception); end # Returns the value of attribute exceptions. # - # source://cucumber-core//lib/cucumber/core/test/result.rb#337 + # source://cucumber-core//lib/cucumber/core/test/result.rb#342 def exceptions; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#345 - def method_missing(name, *args); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#350 + def method_missing(name, *_args); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#353 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#362 + def ok?(strict: T.unsafe(nil)); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#372 + # source://cucumber-core//lib/cucumber/core/test/result.rb#381 def total(for_status = T.unsafe(nil)); end private - # source://cucumber-core//lib/cucumber/core/test/result.rb#386 + # source://cucumber-core//lib/cucumber/core/test/result.rb#395 def get_total(method_name); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#391 + # source://cucumber-core//lib/cucumber/core/test/result.rb#400 def increment_total(status); end + + # @return [Boolean] + # + # source://cucumber-core//lib/cucumber/core/test/result.rb#358 + def respond_to_missing?(*_arg0); end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#10 +# source://cucumber-core//lib/cucumber/core/test/result.rb#11 Cucumber::Core::Test::Result::TYPES = T.let(T.unsafe(nil), Array) -# source://cucumber-core//lib/cucumber/core/test/result.rb#203 +# source://cucumber-core//lib/cucumber/core/test/result.rb#208 class Cucumber::Core::Test::Result::Undefined < ::Cucumber::Core::Test::Result::Raisable - # source://cucumber-core//lib/cucumber/core/test/result.rb#210 + # source://cucumber-core//lib/cucumber/core/test/result.rb#215 def describe_to(visitor, *args); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#220 + # source://cucumber-core//lib/cucumber/core/test/result.rb#225 def to_message; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#216 + # source://cucumber-core//lib/cucumber/core/test/result.rb#221 def to_s; end class << self # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/result.rb#206 - def ok?(be_strict = T.unsafe(nil)); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#211 + def ok?(strict: T.unsafe(nil)); end end end # Null object for results. Represents the state where we haven't run anything yet # -# source://cucumber-core//lib/cucumber/core/test/result.rb#37 +# source://cucumber-core//lib/cucumber/core/test/result.rb#38 class Cucumber::Core::Test::Result::Unknown - # source://cucumber-core//lib/cucumber/core/test/result.rb#40 - def describe_to(visitor, *args); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#41 + def describe_to(_visitor, *_args); end - # source://cucumber-core//lib/cucumber/core/test/result.rb#48 + # source://cucumber-core//lib/cucumber/core/test/result.rb#49 def to_message; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#44 - def with_filtered_backtrace(filter); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#45 + def with_filtered_backtrace(_filter); end end -# source://cucumber-core//lib/cucumber/core/test/result.rb#418 +# source://cucumber-core//lib/cucumber/core/test/result.rb#427 class Cucumber::Core::Test::Result::UnknownDuration include ::Cucumber::Messages::TimeConversion - # source://cucumber-core//lib/cucumber/core/test/result.rb#425 + # source://cucumber-core//lib/cucumber/core/test/result.rb#434 def nanoseconds; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#421 - def tap(&block); end + # source://cucumber-core//lib/cucumber/core/test/result.rb#430 + def tap; end - # source://cucumber-core//lib/cucumber/core/test/result.rb#429 + # source://cucumber-core//lib/cucumber/core/test/result.rb#438 def to_message_duration; end end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#7 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#8 class Cucumber::Core::Test::Runner # @return [Runner] a new instance of Runner # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#11 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#12 def initialize(event_bus); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#35 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#36 def around_hook(hook, &continue); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#42 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#43 def done; end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#15 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#16 def test_case(test_case, &descend); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#26 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#27 def test_step(test_step); end private # Returns the value of attribute event_bus. # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#8 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#9 def event_bus; end # Returns the value of attribute running_test_case. # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#8 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#9 def running_test_case; end # Returns the value of attribute running_test_step. # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#8 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#9 def running_test_step; end end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#46 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#47 class Cucumber::Core::Test::Runner::RunningTestCase # @return [RunningTestCase] a new instance of RunningTestCase # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#47 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#48 def initialize; end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#89 - def duration(step_duration, step_result); end + # source://cucumber-core//lib/cucumber/core/test/runner.rb#90 + def duration(_step_duration, _step_result); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#85 - def exception(step_exception, step_result); end + # source://cucumber-core//lib/cucumber/core/test/runner.rb#86 + def exception(_step_exception, _step_result); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#52 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#53 def execute(test_step, &continue); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#60 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#61 def failed(step_result); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#65 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#66 def passed(step_result); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#70 - def pending(message, step_result); end + # source://cucumber-core//lib/cucumber/core/test/runner.rb#71 + def pending(_message, step_result); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#56 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#57 def result; end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#75 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#76 def skipped(step_result); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#80 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#81 def undefined(step_result); end private # Returns the value of attribute status. # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#93 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#94 def status; end end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#96 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#97 module Cucumber::Core::Test::Runner::RunningTestCase::Status; end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#97 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#98 class Cucumber::Core::Test::Runner::RunningTestCase::Status::Base # @return [Base] a new instance of Base # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#101 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#102 def initialize(step_result); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#105 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#106 def execute(test_step, monitor, &continue); end # @raise [NoMethodError] # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#112 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#113 def result; end private # Returns the value of attribute step_result. # - # source://cucumber-core//lib/cucumber/core/test/runner.rb#98 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#99 def step_result; end end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#129 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#130 class Cucumber::Core::Test::Runner::RunningTestCase::Status::Failing < ::Cucumber::Core::Test::Runner::RunningTestCase::Status::Base - # source://cucumber-core//lib/cucumber/core/test/runner.rb#130 - def execute(test_step, monitor, &continue); end + # source://cucumber-core//lib/cucumber/core/test/runner.rb#131 + def execute(test_step, monitor); end - # source://cucumber-core//lib/cucumber/core/test/runner.rb#139 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#140 def result(duration); end end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#123 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#124 class Cucumber::Core::Test::Runner::RunningTestCase::Status::Passing < ::Cucumber::Core::Test::Runner::RunningTestCase::Status::Base - # source://cucumber-core//lib/cucumber/core/test/runner.rb#124 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#125 def result(duration); end end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#144 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#145 class Cucumber::Core::Test::Runner::RunningTestCase::Status::Pending < ::Cucumber::Core::Test::Runner::RunningTestCase::Status::Failing; end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#146 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#147 class Cucumber::Core::Test::Runner::RunningTestCase::Status::Skipping < ::Cucumber::Core::Test::Runner::RunningTestCase::Status::Failing - # source://cucumber-core//lib/cucumber/core/test/runner.rb#147 + # source://cucumber-core//lib/cucumber/core/test/runner.rb#148 def result(duration); end end -# source://cucumber-core//lib/cucumber/core/test/runner.rb#117 +# source://cucumber-core//lib/cucumber/core/test/runner.rb#118 class Cucumber::Core::Test::Runner::RunningTestCase::Status::Unknown < ::Cucumber::Core::Test::Runner::RunningTestCase::Status::Base - # source://cucumber-core//lib/cucumber/core/test/runner.rb#118 - def result(duration); end + # source://cucumber-core//lib/cucumber/core/test/runner.rb#119 + def result(_duration); end end # source://cucumber-core//lib/cucumber/core/test/step.rb#10 @@ -1488,21 +1540,21 @@ class Cucumber::Core::Test::Step # source://cucumber-core//lib/cucumber/core/test/step.rb#13 def initialize(id, text, location, multiline_arg = T.unsafe(nil), action = T.unsafe(nil)); end - # source://cucumber-core//lib/cucumber/core/test/step.rb#50 + # source://cucumber-core//lib/cucumber/core/test/step.rb#51 def action_location; end - # source://cucumber-core//lib/cucumber/core/test/step.rb#42 + # source://cucumber-core//lib/cucumber/core/test/step.rb#43 def backtrace_line; end - # source://cucumber-core//lib/cucumber/core/test/step.rb#22 + # source://cucumber-core//lib/cucumber/core/test/step.rb#23 def describe_to(visitor, *args); end - # source://cucumber-core//lib/cucumber/core/test/step.rb#34 + # source://cucumber-core//lib/cucumber/core/test/step.rb#35 def execute(*args); end # @return [Boolean] # - # source://cucumber-core//lib/cucumber/core/test/step.rb#26 + # source://cucumber-core//lib/cucumber/core/test/step.rb#27 def hook?; end # Returns the value of attribute id. @@ -1510,7 +1562,7 @@ class Cucumber::Core::Test::Step # source://cucumber-core//lib/cucumber/core/test/step.rb#11 def id; end - # source://cucumber-core//lib/cucumber/core/test/step.rb#54 + # source://cucumber-core//lib/cucumber/core/test/step.rb#59 def inspect; end # Returns the value of attribute location. @@ -1518,12 +1570,15 @@ class Cucumber::Core::Test::Step # source://cucumber-core//lib/cucumber/core/test/step.rb#11 def location; end + # source://cucumber-core//lib/cucumber/core/test/step.rb#55 + def matching_locations; end + # Returns the value of attribute multiline_arg. # # source://cucumber-core//lib/cucumber/core/test/step.rb#11 def multiline_arg; end - # source://cucumber-core//lib/cucumber/core/test/step.rb#30 + # source://cucumber-core//lib/cucumber/core/test/step.rb#31 def skip(*args); end # Returns the value of attribute text. @@ -1531,32 +1586,32 @@ class Cucumber::Core::Test::Step # source://cucumber-core//lib/cucumber/core/test/step.rb#11 def text; end - # source://cucumber-core//lib/cucumber/core/test/step.rb#46 + # source://cucumber-core//lib/cucumber/core/test/step.rb#47 def to_s; end - # source://cucumber-core//lib/cucumber/core/test/step.rb#38 + # source://cucumber-core//lib/cucumber/core/test/step.rb#39 def with_action(action_location = T.unsafe(nil), &block); end end -# source://cucumber-core//lib/cucumber/core/test/tag.rb#5 +# source://cucumber-core//lib/cucumber/core/test/tag.rb#6 class Cucumber::Core::Test::Tag include ::Cucumber::Core::Test::HasLocation # @return [Tag] a new instance of Tag # - # source://cucumber-core//lib/cucumber/core/test/tag.rb#10 + # source://cucumber-core//lib/cucumber/core/test/tag.rb#11 def initialize(location, name); end - # source://cucumber-core//lib/cucumber/core/test/tag.rb#15 + # source://cucumber-core//lib/cucumber/core/test/tag.rb#16 def inspect; end # Returns the value of attribute name. # - # source://cucumber-core//lib/cucumber/core/test/tag.rb#8 + # source://cucumber-core//lib/cucumber/core/test/tag.rb#9 def name; end end -# source://cucumber-core//lib/cucumber/core/test/filters/tag_filter.rb#7 +# source://cucumber-core//lib/cucumber/core/test/filters/tag_filter.rb#8 class Cucumber::Core::Test::TagFilter # source://cucumber-core//lib/cucumber/core/test/filters/tag_filter.rb#17 def done; end @@ -1591,101 +1646,86 @@ class Cucumber::Core::Test::TagFilter::TestCases def test_cases_by_tag_name; end end -# source://cucumber-core//lib/cucumber/core/test/timer.rb#7 +# source://cucumber-core//lib/cucumber/core/test/timer.rb#8 class Cucumber::Core::Test::Timer - # source://cucumber-core//lib/cucumber/core/test/timer.rb#13 + # source://cucumber-core//lib/cucumber/core/test/timer.rb#14 def duration; end - # source://cucumber-core//lib/cucumber/core/test/timer.rb#17 + # source://cucumber-core//lib/cucumber/core/test/timer.rb#18 def nsec; end - # source://cucumber-core//lib/cucumber/core/test/timer.rb#21 + # source://cucumber-core//lib/cucumber/core/test/timer.rb#22 def sec; end - # source://cucumber-core//lib/cucumber/core/test/timer.rb#8 + # source://cucumber-core//lib/cucumber/core/test/timer.rb#9 def start; end private - # source://cucumber-core//lib/cucumber/core/test/timer.rb#27 + # source://cucumber-core//lib/cucumber/core/test/timer.rb#28 def time_in_nanoseconds; end end -# source://cucumber-core//lib/cucumber/core/test/timer.rb#31 +# source://cucumber-core//lib/cucumber/core/test/timer.rb#32 module Cucumber::Core::Test::Timer::MonotonicTime private - # source://cucumber-core//lib/cucumber/core/test/timer.rb#35 + # source://cucumber-core//lib/cucumber/core/test/timer.rb#36 def time_in_nanoseconds; end class << self - # source://cucumber-core//lib/cucumber/core/test/timer.rb#35 + # source://cucumber-core//lib/cucumber/core/test/timer.rb#36 def time_in_nanoseconds; end end end -# source://cucumber-core//lib/cucumber/core/test/action.rb#60 +# source://cucumber-core//lib/cucumber/core/test/actions/undefined_action.rb#8 class Cucumber::Core::Test::UndefinedAction # @return [UndefinedAction] a new instance of UndefinedAction # - # source://cucumber-core//lib/cucumber/core/test/action.rb#63 + # source://cucumber-core//lib/cucumber/core/test/actions/undefined_action.rb#11 def initialize(source_location); end - # source://cucumber-core//lib/cucumber/core/test/action.rb#67 + # source://cucumber-core//lib/cucumber/core/test/actions/undefined_action.rb#15 def execute(*_arg0); end # Returns the value of attribute location. # - # source://cucumber-core//lib/cucumber/core/test/action.rb#61 + # source://cucumber-core//lib/cucumber/core/test/actions/undefined_action.rb#9 def location; end - # source://cucumber-core//lib/cucumber/core/test/action.rb#71 + # source://cucumber-core//lib/cucumber/core/test/actions/undefined_action.rb#19 def skip(*_arg0); end private - # source://cucumber-core//lib/cucumber/core/test/action.rb#77 + # source://cucumber-core//lib/cucumber/core/test/actions/undefined_action.rb#25 def undefined; end end -# source://cucumber-core//lib/cucumber/core/test/action.rb#54 +# source://cucumber-core//lib/cucumber/core/test/actions/unskippable_action.rb#9 class Cucumber::Core::Test::UnskippableAction < ::Cucumber::Core::Test::Action - # source://cucumber-core//lib/cucumber/core/test/action.rb#55 + # source://cucumber-core//lib/cucumber/core/test/actions/unskippable_action.rb#10 def skip(*args); end end -# source://cucumber-core//lib/cucumber/core/platform.rb#9 +# source://cucumber-core//lib/cucumber/core/platform.rb#10 Cucumber::IRONRUBY = T.let(T.unsafe(nil), FalseClass) -# source://cucumber-core//lib/cucumber/core/platform.rb#8 +# source://cucumber-core//lib/cucumber/core/platform.rb#9 Cucumber::JRUBY = T.let(T.unsafe(nil), T.untyped) -# source://cucumber/8.0.0/lib/cucumber/platform.rb#12 -Cucumber::LIBDIR = T.let(T.unsafe(nil), String) - -# source://cucumber-core//lib/cucumber/core/platform.rb#11 +# source://cucumber-core//lib/cucumber/core/platform.rb#12 Cucumber::OS_X = T.let(T.unsafe(nil), T.untyped) -# source://cucumber/8.0.0/lib/cucumber/platform.rb#13 -Cucumber::RAILS = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#15 -Cucumber::RUBY = T.let(T.unsafe(nil), String) - -# source://cucumber-core//lib/cucumber/core/platform.rb#14 +# source://cucumber-core//lib/cucumber/core/platform.rb#15 Cucumber::RUBY_1_9 = T.let(T.unsafe(nil), T.untyped) -# source://cucumber-core//lib/cucumber/core/platform.rb#13 +# source://cucumber-core//lib/cucumber/core/platform.rb#14 Cucumber::RUBY_2_0 = T.let(T.unsafe(nil), T.untyped) -# source://cucumber/8.0.0/lib/cucumber/platform.rb#14 -Cucumber::RUBY_BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#10 -Cucumber::VERSION = T.let(T.unsafe(nil), String) - -# source://cucumber-core//lib/cucumber/core/platform.rb#10 +# source://cucumber-core//lib/cucumber/core/platform.rb#11 Cucumber::WINDOWS = T.let(T.unsafe(nil), T.untyped) -# source://cucumber-core//lib/cucumber/core/platform.rb#12 +# source://cucumber-core//lib/cucumber/core/platform.rb#13 Cucumber::WINDOWS_MRI = T.let(T.unsafe(nil), T.untyped) diff --git a/sorbet/rbi/gems/cucumber-cucumber-expressions@15.2.0.rbi b/sorbet/rbi/gems/cucumber-cucumber-expressions@17.1.0.rbi similarity index 78% rename from sorbet/rbi/gems/cucumber-cucumber-expressions@15.2.0.rbi rename to sorbet/rbi/gems/cucumber-cucumber-expressions@17.1.0.rbi index 934279814..e5eb95c98 100644 --- a/sorbet/rbi/gems/cucumber-cucumber-expressions@15.2.0.rbi +++ b/sorbet/rbi/gems/cucumber-cucumber-expressions@17.1.0.rbi @@ -4,272 +4,272 @@ # This is an autogenerated file for types exported from the `cucumber-cucumber-expressions` gem. # Please instead update this file by running `bin/tapioca gem cucumber-cucumber-expressions`. -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#1 + +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#3 module Cucumber class << self - # source://cucumber/8.0.0/lib/cucumber/deprecate.rb#52 - def deprecate(*args); end + # source://cucumber/9.2.0/lib/cucumber/deprecate.rb#7 + def deprecate(message, method, remove_after_version); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#21 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#17 def file_mode(mode, encoding = T.unsafe(nil)); end - # source://cucumber/8.0.0/lib/cucumber.rb#15 + # source://cucumber/9.2.0/lib/cucumber.rb#15 def logger; end - # source://cucumber/8.0.0/lib/cucumber.rb#23 + # source://cucumber/9.2.0/lib/cucumber.rb#23 def logger=(logger); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace; end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit=(_arg0); end end end -# source://cucumber/8.0.0/lib/cucumber/platform.rb#11 -Cucumber::BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#2 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#4 module Cucumber::CucumberExpressions; end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#4 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#6 Cucumber::CucumberExpressions::ALTERNATION_CHARACTER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#141 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#153 class Cucumber::CucumberExpressions::AlternationNotAllowedInOptional < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [AlternationNotAllowedInOptional] a new instance of AlternationNotAllowedInOptional # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#142 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#154 def initialize(expression, current); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#53 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#50 class Cucumber::CucumberExpressions::AlternativeMayNotBeEmpty < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [AlternativeMayNotBeEmpty] a new instance of AlternativeMayNotBeEmpty # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#54 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#51 def initialize(node, expression); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#41 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#36 class Cucumber::CucumberExpressions::AlternativeMayNotExclusivelyContainOptionals < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [AlternativeMayNotExclusivelyContainOptionals] a new instance of AlternativeMayNotExclusivelyContainOptionals # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#42 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#37 def initialize(node, expression); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#186 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#204 class Cucumber::CucumberExpressions::AmbiguousParameterTypeError < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [AmbiguousParameterTypeError] a new instance of AmbiguousParameterTypeError # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#187 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#205 def initialize(parameter_type_regexp, expression_regexp, parameter_types, generated_expressions); end private - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#209 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#227 def expressions(generated_expressions); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#205 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#223 def parameter_type_names(parameter_types); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#6 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#8 class Cucumber::CucumberExpressions::Argument # @return [Argument] a new instance of Argument # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#26 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#29 def initialize(group, parameter_type); end # Returns the value of attribute group. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#7 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#9 def group; end # Returns the value of attribute parameter_type. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#7 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#9 def parameter_type; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#30 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#33 def value(self_obj = T.unsafe(nil)); end class << self - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#9 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/argument.rb#11 def build(tree_regexp, text, parameter_types); end end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#7 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#9 Cucumber::CucumberExpressions::BEGIN_OPTIONAL_CHARACTER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#5 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#7 Cucumber::CucumberExpressions::BEGIN_PARAMETER_CHARACTER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#65 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#64 class Cucumber::CucumberExpressions::CantEscape < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [CantEscape] a new instance of CantEscape # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#66 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#65 def initialize(expression, index); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#6 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#7 class Cucumber::CucumberExpressions::CombinatorialGeneratedExpressionFactory # @return [CombinatorialGeneratedExpressionFactory] a new instance of CombinatorialGeneratedExpressionFactory # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#7 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#8 def initialize(expression_template, parameter_type_combinations); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#12 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#13 def generate_expressions; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#21 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#22 def generate_permutations(generated_expressions, depth, current_parameter_types); end end # 256 generated expressions ought to be enough for anybody # -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#19 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/combinatorial_generated_expression_factory.rb#20 Cucumber::CucumberExpressions::CombinatorialGeneratedExpressionFactory::MAX_EXPRESSIONS = T.let(T.unsafe(nil), Integer) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#8 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#10 class Cucumber::CucumberExpressions::CucumberExpression # @return [CucumberExpression] a new instance of CucumberExpression # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#12 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#13 def initialize(expression, parameter_type_registry); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#22 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#23 def match(text); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#30 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#31 def regexp; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#26 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#27 def source; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#34 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#35 def to_s; end private - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#117 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#115 def assert_no_optionals(node, &raise_error); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#112 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#110 def assert_no_parameters(node, &raise_error); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#107 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#105 def assert_not_empty(node, &raise_error); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#60 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#61 def escape_regex(expression); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#72 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#73 def rewrite_alternation(node); end # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#84 def rewrite_alternative(node); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#102 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#100 def rewrite_expression(node); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#64 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#65 def rewrite_optional(node); end + # @raise [UndefinedParameterTypeError] + # # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#88 def rewrite_parameter(node); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#40 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#41 def rewrite_to_regex(node); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#10 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression.rb#11 Cucumber::CucumberExpressions::CucumberExpression::ESCAPE_PATTERN = T.let(T.unsafe(nil), Regexp) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#5 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#7 class Cucumber::CucumberExpressions::CucumberExpressionError < ::StandardError - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#7 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#8 def build_message(index, expression, pointer, problem, solution); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#25 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#20 def point_at(index); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#29 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#24 def point_at_located(node); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#7 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#9 class Cucumber::CucumberExpressions::CucumberExpressionGenerator # @return [CucumberExpressionGenerator] a new instance of CucumberExpressionGenerator # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#8 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#10 def initialize(parameter_type_registry); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#12 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#14 def generate_expressions(text); end private - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#71 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#69 def create_parameter_type_matchers(text); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#81 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#77 def create_parameter_type_matchers2(parameter_type, text); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#89 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_generator.rb#85 def escape(s); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#7 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#9 class Cucumber::CucumberExpressions::CucumberExpressionParser - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#8 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#10 def parse(expression); end private - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#202 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#186 def create_alternative_nodes(start, _end, separators, alternatives); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#173 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#158 def looking_at(tokens, at, token); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#169 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#154 def looking_at_any(tokens, at, token_types); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#118 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#105 def parse_between(type, begin_token, end_token, parsers); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#140 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#125 def parse_token(expression, parsers, tokens, start_at); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#149 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#134 def parse_tokens_until(expression, parsers, tokens, start_at, end_tokens); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#185 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_parser.rb#169 def split_alternatives(start, _end, alternation); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_tokenizer.rb#6 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_tokenizer.rb#8 class Cucumber::CucumberExpressions::CucumberExpressionTokenizer # @raise [TheEndOfLineCannotBeEscaped] # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_tokenizer.rb#7 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_tokenizer.rb#9 def tokenize(expression); end private @@ -281,7 +281,7 @@ class Cucumber::CucumberExpressions::CucumberExpressionTokenizer # @return [Boolean] # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_tokenizer.rb#89 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/cucumber_expression_tokenizer.rb#84 def should_create_new_token?(previous_token_type, current_token_type); end # @raise [CantEscape] @@ -290,209 +290,219 @@ class Cucumber::CucumberExpressions::CucumberExpressionTokenizer def token_type_of(codepoint, treat_as_text); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#8 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#10 Cucumber::CucumberExpressions::END_OPTIONAL_CHARACTER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#6 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#8 Cucumber::CucumberExpressions::END_PARAMETER_CHARACTER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#3 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#5 Cucumber::CucumberExpressions::ESCAPE_CHARACTER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#3 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#5 class Cucumber::CucumberExpressions::GeneratedExpression # @return [GeneratedExpression] a new instance of GeneratedExpression # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#6 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#8 def initialize(expression_template, parameters_types); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#14 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#16 def parameter_names; end # Returns the value of attribute parameter_types. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#4 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#6 def parameter_types; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#10 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#12 def source; end private - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#23 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/generated_expression.rb#25 def get_parameter_name(type_name, usage_by_type_name); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#3 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#5 class Cucumber::CucumberExpressions::Group # @return [Group] a new instance of Group # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#6 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#8 def initialize(value, start, _end, children); end # Returns the value of attribute children. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#4 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#6 def children; end # Returns the value of attribute end. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#4 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#6 def end; end # Returns the value of attribute start. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#4 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#6 def start; end # Returns the value of attribute value. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#4 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#6 def value; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#13 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group.rb#15 def values; end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#5 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#7 class Cucumber::CucumberExpressions::GroupBuilder # @return [GroupBuilder] a new instance of GroupBuilder # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#8 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#10 def initialize; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#13 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#15 def add(group_builder); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#17 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#19 def build(match, group_indices); end # @return [Boolean] # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#27 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#29 def capturing?; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#37 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#39 def children; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#31 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#33 def move_children_to(group_builder); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#23 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#25 def set_non_capturing!; end # Returns the value of attribute source. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#6 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#8 def source; end # Sets the attribute source # # @param value the value to set the attribute source to. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#6 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/group_builder.rb#8 def source=(_arg0); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#153 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#167 class Cucumber::CucumberExpressions::InvalidParameterTypeName < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [InvalidParameterTypeName] a new instance of InvalidParameterTypeName # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#154 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#168 def initialize(type_name); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#161 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#173 class Cucumber::CucumberExpressions::InvalidParameterTypeNameInNode < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [InvalidParameterTypeNameInNode] a new instance of InvalidParameterTypeNameInNode # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#162 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#174 def initialize(expression, token); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#126 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#135 class Cucumber::CucumberExpressions::MissingEndToken < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [MissingEndToken] a new instance of MissingEndToken # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#127 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#136 def initialize(expression, begin_token, end_token, current); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#10 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#12 class Cucumber::CucumberExpressions::Node # @return [Node] a new instance of Node # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#11 - def initialize(type, nodes, token, start, _end); end + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#15 + def initialize(type, nodes, token, start, ending); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#38 + # Returns the value of attribute end. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#13 def end; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#26 + # Returns the value of attribute nodes. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#13 def nodes; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#34 + # Returns the value of attribute start. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#13 def start; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#42 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#25 def text; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#49 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#31 def to_hash; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#30 + # Returns the value of attribute token. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#13 def token; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#22 + # Returns the value of attribute type. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#13 def type; end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#64 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#42 module Cucumber::CucumberExpressions::NodeType; end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#67 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#45 Cucumber::CucumberExpressions::NodeType::ALTERNATION = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#68 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#46 Cucumber::CucumberExpressions::NodeType::ALTERNATIVE = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#70 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#48 Cucumber::CucumberExpressions::NodeType::EXPRESSION = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#66 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#44 Cucumber::CucumberExpressions::NodeType::OPTIONAL = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#69 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#47 Cucumber::CucumberExpressions::NodeType::PARAMETER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#65 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#43 Cucumber::CucumberExpressions::NodeType::TEXT = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#101 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#106 class Cucumber::CucumberExpressions::OptionalIsNotAllowedInOptional < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [OptionalIsNotAllowedInOptional] a new instance of OptionalIsNotAllowedInOptional # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#102 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#107 def initialize(node, expression); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#77 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#78 class Cucumber::CucumberExpressions::OptionalMayNotBeEmpty < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [OptionalMayNotBeEmpty] a new instance of OptionalMayNotBeEmpty # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#78 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#79 def initialize(node, expression); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#89 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#92 class Cucumber::CucumberExpressions::ParameterIsNotAllowedInOptional < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [ParameterIsNotAllowedInOptional] a new instance of ParameterIsNotAllowedInOptional # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#90 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#93 def initialize(node, expression); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#5 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#7 class Cucumber::CucumberExpressions::ParameterType # Create a new Parameter # @@ -504,50 +514,57 @@ class Cucumber::CucumberExpressions::ParameterType # @param prefer_for_regexp_match true if this should be preferred over similar types # @return [ParameterType] a new instance of ParameterType # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#41 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#31 def initialize(name, regexp, type, transformer, use_for_snippets, prefer_for_regexp_match); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#57 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#47 def <=>(other); end # Returns the value of attribute name. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#9 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#11 def name; end - # @return [Boolean] + # Returns the value of attribute prefer_for_regexp_match. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#24 - def prefer_for_regexp_match?; end + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#11 + def prefer_for_regexp_match; end # Returns the value of attribute regexps. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#9 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#11 def regexps; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#53 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#43 def transform(self_obj, group_values); end + # Returns the value of attribute transformer. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#11 + def transformer; end + # Returns the value of attribute type. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#9 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#11 def type; end - # @return [Boolean] + # Returns the value of attribute use_for_snippets. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#28 - def use_for_snippets?; end + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#11 + def use_for_snippets; end private - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#71 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#61 def regexp_source(regexp); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#66 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#56 def string_array(regexps); end class << self - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#11 + # @raise [CucumberExpressionError] + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#13 def check_parameter_type_name(type_name); end # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#17 @@ -555,23 +572,23 @@ class Cucumber::CucumberExpressions::ParameterType end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#6 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#8 Cucumber::CucumberExpressions::ParameterType::ILLEGAL_PARAMETER_NAME_PATTERN = T.let(T.unsafe(nil), Regexp) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#7 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type.rb#9 Cucumber::CucumberExpressions::ParameterType::UNESCAPE_PATTERN = T.let(T.unsafe(nil), Regexp) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#3 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#5 class Cucumber::CucumberExpressions::ParameterTypeMatcher # @return [ParameterTypeMatcher] a new instance of ParameterTypeMatcher # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#6 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#8 def initialize(parameter_type, regexp, text, match_position = T.unsafe(nil)); end # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#38 def <=>(other); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#11 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#13 def advance_to(new_match_position); end # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#22 @@ -587,7 +604,7 @@ class Cucumber::CucumberExpressions::ParameterTypeMatcher # Returns the value of attribute parameter_type. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#4 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#6 def parameter_type; end # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#30 @@ -597,224 +614,196 @@ class Cucumber::CucumberExpressions::ParameterTypeMatcher # @return [Boolean] # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#53 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#55 def space_after_match_or_sentence_end?; end # @return [Boolean] # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#48 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_matcher.rb#50 def space_before_match_or_sentence_start?; end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#8 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#10 class Cucumber::CucumberExpressions::ParameterTypeRegistry # @return [ParameterTypeRegistry] a new instance of ParameterTypeRegistry # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#15 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#17 def initialize; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#53 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#56 def define_parameter_type(parameter_type); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#36 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#38 def lookup_by_regexp(parameter_type_regexp, expression_regexp, text); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#32 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#34 def lookup_by_type_name(name); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#49 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#52 def parameter_types; end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#13 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#15 Cucumber::CucumberExpressions::ParameterTypeRegistry::ANONYMOUS_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#10 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#12 Cucumber::CucumberExpressions::ParameterTypeRegistry::FLOAT_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#9 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#11 Cucumber::CucumberExpressions::ParameterTypeRegistry::INTEGER_REGEXPS = T.let(T.unsafe(nil), Array) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#12 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#14 Cucumber::CucumberExpressions::ParameterTypeRegistry::STRING_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#11 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/parameter_type_registry.rb#13 Cucumber::CucumberExpressions::ParameterTypeRegistry::WORD_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#7 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#9 class Cucumber::CucumberExpressions::RegularExpression # @return [RegularExpression] a new instance of RegularExpression # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#9 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#10 def initialize(expression_regexp, parameter_type_registry); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#15 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#16 def match(text); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#35 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#36 def regexp; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#39 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#40 def source; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#43 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/regular_expression.rb#44 def to_s; end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#113 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#120 class Cucumber::CucumberExpressions::TheEndOfLineCannotBeEscaped < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [TheEndOfLineCannotBeEscaped] a new instance of TheEndOfLineCannotBeEscaped # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#114 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#121 def initialize(expression); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#74 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#51 class Cucumber::CucumberExpressions::Token # @return [Token] a new instance of Token # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#75 - def initialize(type, text, start, _end); end + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#54 + def initialize(type, text, start, ending); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#91 + # Returns the value of attribute end. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#52 def end; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#87 + # Returns the value of attribute start. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#52 def start; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#83 + # Returns the value of attribute text. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#52 def text; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#179 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#144 def to_hash; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#79 + # Returns the value of attribute type. + # + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#52 def type; end class << self - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#99 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#62 def can_escape(codepoint); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#95 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#58 def is_escape_character(codepoint); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#162 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#127 def purpose_of(token); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#145 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#110 def symbol_of(token); end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#123 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#87 def type_of(codepoint); end end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#189 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#154 module Cucumber::CucumberExpressions::TokenType; end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#197 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#162 Cucumber::CucumberExpressions::TokenType::ALTERNATION = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#193 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#158 Cucumber::CucumberExpressions::TokenType::BEGIN_OPTIONAL = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#195 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#160 Cucumber::CucumberExpressions::TokenType::BEGIN_PARAMETER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#191 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#156 Cucumber::CucumberExpressions::TokenType::END_OF_LINE = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#194 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#159 Cucumber::CucumberExpressions::TokenType::END_OPTIONAL = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#196 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#161 Cucumber::CucumberExpressions::TokenType::END_PARAMETER = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#190 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#155 Cucumber::CucumberExpressions::TokenType::START_OF_LINE = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#198 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#163 Cucumber::CucumberExpressions::TokenType::TEXT = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#192 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/ast.rb#157 Cucumber::CucumberExpressions::TokenType::WHITE_SPACE = T.let(T.unsafe(nil), String) -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#6 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#8 class Cucumber::CucumberExpressions::TreeRegexp # @return [TreeRegexp] a new instance of TreeRegexp # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#9 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#11 def initialize(regexp); end # Returns the value of attribute group_builder. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#7 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#9 def group_builder; end - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#14 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#16 def match(s); end # Returns the value of attribute regexp. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#7 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#9 def regexp; end private - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#48 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#51 def create_group_builder(regexp); end # @raise [CucumberExpressionError] # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#21 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/tree_regexp.rb#24 def is_non_capturing(source, i); end end -# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#173 +# source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#187 class Cucumber::CucumberExpressions::UndefinedParameterTypeError < ::Cucumber::CucumberExpressions::CucumberExpressionError # @return [UndefinedParameterTypeError] a new instance of UndefinedParameterTypeError # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#176 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#190 def initialize(node, expression, undefined_parameter_type_name); end # Returns the value of attribute undefined_parameter_type_name. # - # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#174 + # source://cucumber-cucumber-expressions//lib/cucumber/cucumber_expressions/errors.rb#188 def undefined_parameter_type_name; end end - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#9 -Cucumber::IRONRUBY = T.let(T.unsafe(nil), FalseClass) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#8 -Cucumber::JRUBY = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#12 -Cucumber::LIBDIR = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#11 -Cucumber::OS_X = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#13 -Cucumber::RAILS = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#15 -Cucumber::RUBY = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#14 -Cucumber::RUBY_1_9 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#13 -Cucumber::RUBY_2_0 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#14 -Cucumber::RUBY_BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#10 -Cucumber::VERSION = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#10 -Cucumber::WINDOWS = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#12 -Cucumber::WINDOWS_MRI = T.let(T.unsafe(nil), T.untyped) diff --git a/sorbet/rbi/gems/cucumber-gherkin@23.0.1.rbi b/sorbet/rbi/gems/cucumber-gherkin@27.0.0.rbi similarity index 88% rename from sorbet/rbi/gems/cucumber-gherkin@23.0.1.rbi rename to sorbet/rbi/gems/cucumber-gherkin@27.0.0.rbi index 8f2899d3b..da8070b19 100644 --- a/sorbet/rbi/gems/cucumber-gherkin@23.0.1.rbi +++ b/sorbet/rbi/gems/cucumber-gherkin@27.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `cucumber-gherkin` gem. # Please instead update this file by running `bin/tapioca gem cucumber-gherkin`. + # source://cucumber-gherkin//lib/gherkin/ast_node.rb#1 module Gherkin class << self @@ -121,54 +122,54 @@ end # source://cucumber-gherkin//lib/gherkin.rb#4 Gherkin::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash) -# source://cucumber-gherkin//lib/gherkin/dialect.rb#5 +# source://cucumber-gherkin//lib/gherkin/dialect.rb#6 Gherkin::DIALECTS = T.let(T.unsafe(nil), Hash) -# source://cucumber-gherkin//lib/gherkin/dialect.rb#4 +# source://cucumber-gherkin//lib/gherkin/dialect.rb#5 Gherkin::DIALECT_FILE_PATH = T.let(T.unsafe(nil), String) -# source://cucumber-gherkin//lib/gherkin/dialect.rb#7 +# source://cucumber-gherkin//lib/gherkin/dialect.rb#8 class Gherkin::Dialect # @return [Dialect] a new instance of Dialect # - # source://cucumber-gherkin//lib/gherkin/dialect.rb#14 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#15 def initialize(spec); end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#54 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#55 def and_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#38 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#39 def background_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#58 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#59 def but_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#34 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#35 def examples_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#18 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#19 def feature_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#42 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#43 def given_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#22 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#23 def rule_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#26 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#27 def scenario_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#30 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#31 def scenario_outline_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#50 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#51 def then_keywords; end - # source://cucumber-gherkin//lib/gherkin/dialect.rb#46 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#47 def when_keywords; end class << self - # source://cucumber-gherkin//lib/gherkin/dialect.rb#8 + # source://cucumber-gherkin//lib/gherkin/dialect.rb#9 def for(name); end end end @@ -633,55 +634,49 @@ class Gherkin::ParserException < ::Gherkin::ParserError def location; end end -# source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#2 +# source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#4 module Gherkin::Pickles; end -# source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#3 +# source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#5 class Gherkin::Pickles::Compiler # @return [Compiler] a new instance of Compiler # - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#4 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#6 def initialize(id_generator); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#8 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#10 def compile(gherkin_document, source); end private - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#22 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#24 def compile_feature(pickles, language, tags, feature, source); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#40 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#42 def compile_rule(pickles, language, feature_tags, feature_background_steps, rule, source); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#58 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#60 def compile_scenario(inherited_tags, background_steps, scenario, language, pickles, source); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#79 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#86 def compile_scenario_outline(inherited_tags, background_steps, scenario, language, pickles, source); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#110 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#130 def interpolate(name, variable_cells, value_cells); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#154 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#165 def pickle_data_table(data_table, variable_cells, value_cells); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#168 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#179 def pickle_doc_string(doc_string, variable_cells, value_cells); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#124 - def pickle_step(step); end + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#138 + def pickle_step_props(step, variable_cells, values_row, keyword_type); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#128 - def pickle_step_props(step, variable_cells, values_row); end - - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#118 - def pickle_steps(steps); end - - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#182 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#193 def pickle_tag(tag); end - # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#178 + # source://cucumber-gherkin//lib/gherkin/pickles/compiler.rb#189 def pickle_tags(tags); end end @@ -694,33 +689,38 @@ class Gherkin::Query # @raise [AstNodeNotLocatedException] # - # source://cucumber-gherkin//lib/gherkin/query.rb#11 + # source://cucumber-gherkin//lib/gherkin/query.rb#18 def location(ast_node_id); end - # source://cucumber-gherkin//lib/gherkin/query.rb#7 + # @raise [AstNodeNotLocatedException] + # + # source://cucumber-gherkin//lib/gherkin/query.rb#13 + def scenario_parent_locations(scenario_node_id); end + + # source://cucumber-gherkin//lib/gherkin/query.rb#9 def update(message); end private - # source://cucumber-gherkin//lib/gherkin/query.rb#61 + # source://cucumber-gherkin//lib/gherkin/query.rb#75 def store_node_location(node); end - # source://cucumber-gherkin//lib/gherkin/query.rb#57 + # source://cucumber-gherkin//lib/gherkin/query.rb#71 def store_nodes_location(nodes); end - # source://cucumber-gherkin//lib/gherkin/query.rb#39 - def update_background(background); end + # source://cucumber-gherkin//lib/gherkin/query.rb#45 + def update_background(parent, background); end - # source://cucumber-gherkin//lib/gherkin/query.rb#18 + # source://cucumber-gherkin//lib/gherkin/query.rb#25 def update_feature(feature); end - # source://cucumber-gherkin//lib/gherkin/query.rb#29 - def update_rule(rule); end + # source://cucumber-gherkin//lib/gherkin/query.rb#36 + def update_rule(feature, rule); end - # source://cucumber-gherkin//lib/gherkin/query.rb#43 - def update_scenario(scenario); end + # source://cucumber-gherkin//lib/gherkin/query.rb#50 + def update_scenario(feature, rule, scenario); end - # source://cucumber-gherkin//lib/gherkin/query.rb#53 + # source://cucumber-gherkin//lib/gherkin/query.rb#67 def update_steps(steps); end end @@ -810,6 +810,18 @@ class Gherkin::Token < ::Struct # source://cucumber-gherkin//lib/gherkin/token.rb#3 def matched_keyword=(_arg0); end + # Returns the value of attribute matched_keyword_type. + # + # source://cucumber-gherkin//lib/gherkin/token.rb#3 + def matched_keyword_type; end + + # Sets the attribute matched_keyword_type + # + # @param value the value to set the attribute matched_keyword_type to. + # + # source://cucumber-gherkin//lib/gherkin/token.rb#3 + def matched_keyword_type=(_arg0); end + # Returns the value of attribute matched_text. # # source://cucumber-gherkin//lib/gherkin/token.rb#3 @@ -838,79 +850,82 @@ class Gherkin::Token < ::Struct def token_value; end end -# source://cucumber-gherkin//lib/gherkin/token_matcher.rb#5 +# source://cucumber-gherkin//lib/gherkin/token_matcher.rb#6 class Gherkin::TokenMatcher # @return [TokenMatcher] a new instance of TokenMatcher # - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#8 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#9 def initialize(dialect_name = T.unsafe(nil)); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#90 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#92 def _match_DocStringSeparator(token, separator, is_open); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#40 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#41 def match_BackgroundLine(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#61 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#63 def match_Comment(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#79 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#81 def match_DocStringSeparator(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#107 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#109 def match_EOF(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#55 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#57 def match_Empty(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#44 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#45 def match_ExamplesLine(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#27 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#28 def match_FeatureLine(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#68 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#70 def match_Language(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#113 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#115 def match_Other(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#31 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#32 def match_RuleLine(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#35 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#36 def match_ScenarioLine(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#119 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#121 def match_StepLine(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#48 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#49 def match_TableRow(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#20 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#21 def match_TagLine(token); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#14 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#15 def reset; end private + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#146 + def add_keyword_type_mappings(keywords, type); end + # @raise [NoSuchLanguageException] # - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#137 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#155 def change_dialect(dialect_name, location); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#145 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#169 def match_title_line(token, token_type, keywords); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#155 - def set_token_matched(token, matched_type, text = T.unsafe(nil), keyword = T.unsafe(nil), indent = T.unsafe(nil), items = T.unsafe(nil)); end + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#179 + def set_token_matched(token, matched_type, text = T.unsafe(nil), keyword = T.unsafe(nil), indent = T.unsafe(nil), keyword_type = T.unsafe(nil), items = T.unsafe(nil)); end - # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#165 + # source://cucumber-gherkin//lib/gherkin/token_matcher.rb#190 def unescape_docstring(text); end end -# source://cucumber-gherkin//lib/gherkin/token_matcher.rb#6 +# source://cucumber-gherkin//lib/gherkin/token_matcher.rb#7 Gherkin::TokenMatcher::LANGUAGE_PATTERN = T.let(T.unsafe(nil), Regexp) # The scanner reads a gherkin doc (typically read from a .feature file) and diff --git a/sorbet/rbi/gems/cucumber-html-formatter@19.2.0.rbi b/sorbet/rbi/gems/cucumber-html-formatter@21.7.0.rbi similarity index 99% rename from sorbet/rbi/gems/cucumber-html-formatter@19.2.0.rbi rename to sorbet/rbi/gems/cucumber-html-formatter@21.7.0.rbi index 93b021a35..201c91bda 100644 --- a/sorbet/rbi/gems/cucumber-html-formatter@19.2.0.rbi +++ b/sorbet/rbi/gems/cucumber-html-formatter@21.7.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `cucumber-html-formatter` gem. # Please instead update this file by running `bin/tapioca gem cucumber-html-formatter`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/cucumber-messages@18.0.0.rbi b/sorbet/rbi/gems/cucumber-messages@22.0.0.rbi similarity index 82% rename from sorbet/rbi/gems/cucumber-messages@18.0.0.rbi rename to sorbet/rbi/gems/cucumber-messages@22.0.0.rbi index f720acd26..5ae60f3c9 100644 --- a/sorbet/rbi/gems/cucumber-messages@18.0.0.rbi +++ b/sorbet/rbi/gems/cucumber-messages@22.0.0.rbi @@ -4,59 +4,48 @@ # This is an autogenerated file for types exported from the `cucumber-messages` gem. # Please instead update this file by running `bin/tapioca gem cucumber-messages`. -# The code was auto-generated by {this script}[https://github.com/cucumber/common/blob/main/messages/jsonschema/scripts/codegen.rb] + +# The code was auto-generated by {this script}[https://github.com/cucumber/messages/blob/main/jsonschema/scripts/codegen.rb] # # source://cucumber-messages//lib/cucumber/messages/message/utils.rb#1 module Cucumber class << self - # source://cucumber/8.0.0/lib/cucumber/deprecate.rb#52 - def deprecate(*args); end + # source://cucumber/9.2.0/lib/cucumber/deprecate.rb#7 + def deprecate(message, method, remove_after_version); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#21 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#17 def file_mode(mode, encoding = T.unsafe(nil)); end - # source://cucumber/8.0.0/lib/cucumber.rb#15 + # source://cucumber/9.2.0/lib/cucumber.rb#15 def logger; end - # source://cucumber/8.0.0/lib/cucumber.rb#23 + # source://cucumber/9.2.0/lib/cucumber.rb#23 def logger=(logger); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace; end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit=(_arg0); end end end -# source://cucumber/8.0.0/lib/cucumber/platform.rb#11 -Cucumber::BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#9 -Cucumber::IRONRUBY = T.let(T.unsafe(nil), FalseClass) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#8 -Cucumber::JRUBY = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#12 -Cucumber::LIBDIR = T.let(T.unsafe(nil), String) - # source://cucumber-messages//lib/cucumber/messages/message/utils.rb#2 module Cucumber::Messages; end -# Represents the Attachment message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Attachment message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # //// Attachments (parse errors, execution errors, screenshots, links...) # @@ -92,9 +81,9 @@ class Cucumber::Messages::Attachment < ::Cucumber::Messages::Message # Content encoding is *not* determined by the media type, but rather by the type # of the object being attached: # - # - string => IDENTITY - # - byte array => BASE64 - # - stream => BASE64 + # - string: IDENTITY + # - byte array: BASE64 + # - stream: BASE64 # # source://cucumber-messages//lib/cucumber/messages.dtos.rb#48 def content_encoding; end @@ -157,50 +146,50 @@ class Cucumber::Messages::Attachment < ::Cucumber::Messages::Message end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1890 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1961 class Cucumber::Messages::AttachmentContentEncoding; end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1892 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1963 Cucumber::Messages::AttachmentContentEncoding::BASE64 = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1891 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1962 Cucumber::Messages::AttachmentContentEncoding::IDENTITY = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#272 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#300 class Cucumber::Messages::Background < ::Cucumber::Messages::Message # @return [Background] a new instance of Background # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#289 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#317 def initialize(location: T.unsafe(nil), keyword: T.unsafe(nil), name: T.unsafe(nil), description: T.unsafe(nil), steps: T.unsafe(nil), id: T.unsafe(nil)); end # Returns the value of attribute description. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#283 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#311 def description; end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#287 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#315 def id; end # Returns the value of attribute keyword. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#279 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#307 def keyword; end # The location of the `Background` keyword # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#277 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#305 def location; end # Returns the value of attribute name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#281 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#309 def name; end # Returns the value of attribute steps. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#285 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#313 def steps; end class << self @@ -210,40 +199,40 @@ class Cucumber::Messages::Background < ::Cucumber::Messages::Message # # Cucumber::Messages::Background.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#122 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#142 def from_h(hash); end end end -# Represents the Ci message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Ci message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # CI environment # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#902 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#940 class Cucumber::Messages::Ci < ::Cucumber::Messages::Message # @return [Ci] a new instance of Ci # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#921 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#959 def initialize(name: T.unsafe(nil), url: T.unsafe(nil), build_number: T.unsafe(nil), git: T.unsafe(nil)); end # The build number. Some CI servers use non-numeric build numbers, which is why this is a string # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#917 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#955 def build_number; end # Returns the value of attribute git. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#919 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#957 def git; end # Name of the CI product, e.g. "Jenkins", "CircleCI" etc. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#907 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#945 def name; end # Link to the build # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#912 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#950 def url; end class << self @@ -253,31 +242,31 @@ class Cucumber::Messages::Ci < ::Cucumber::Messages::Message # # Cucumber::Messages::Ci.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#503 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#524 def from_h(hash); end end end -# Represents the Comment message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Comment message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # A comment in a Gherkin document # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#314 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#342 class Cucumber::Messages::Comment < ::Cucumber::Messages::Message # @return [Comment] a new instance of Comment # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#326 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#354 def initialize(location: T.unsafe(nil), text: T.unsafe(nil)); end # The location of the comment # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#319 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#347 def location; end # The text of the comment # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#324 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#352 def text; end class << self @@ -287,26 +276,26 @@ class Cucumber::Messages::Comment < ::Cucumber::Messages::Message # # Cucumber::Messages::Comment.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#146 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#166 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#342 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#370 class Cucumber::Messages::DataTable < ::Cucumber::Messages::Message # @return [DataTable] a new instance of DataTable # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#348 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#376 def initialize(location: T.unsafe(nil), rows: T.unsafe(nil)); end # Returns the value of attribute location. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#344 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#372 def location; end # Returns the value of attribute rows. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#346 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#374 def rows; end class << self @@ -316,36 +305,36 @@ class Cucumber::Messages::DataTable < ::Cucumber::Messages::Message # # Cucumber::Messages::DataTable.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#166 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#186 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#364 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#392 class Cucumber::Messages::DocString < ::Cucumber::Messages::Message # @return [DocString] a new instance of DocString # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#374 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#402 def initialize(location: T.unsafe(nil), media_type: T.unsafe(nil), content: T.unsafe(nil), delimiter: T.unsafe(nil)); end # Returns the value of attribute content. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#370 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#398 def content; end # Returns the value of attribute delimiter. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#372 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#400 def delimiter; end # Returns the value of attribute location. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#366 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#394 def location; end # Returns the value of attribute media_type. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#368 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#396 def media_type; end class << self @@ -355,12 +344,12 @@ class Cucumber::Messages::DocString < ::Cucumber::Messages::Message # # Cucumber::Messages::DocString.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#186 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#206 def from_h(hash); end end end -# Represents the Duration message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Duration message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # The structure is pretty close of the Timestamp one. For clarity, a second type # of message is used. @@ -397,7 +386,7 @@ class Cucumber::Messages::Duration < ::Cucumber::Messages::Message end end -# Represents the Envelope message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Envelope message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # When removing a field, replace it with reserved, rather than deleting the line. # When adding a field, add it to the end and increment the number by one. @@ -511,51 +500,51 @@ class Cucumber::Messages::Envelope < ::Cucumber::Messages::Message end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#394 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#422 class Cucumber::Messages::Examples < ::Cucumber::Messages::Message # @return [Examples] a new instance of Examples # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#415 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#443 def initialize(location: T.unsafe(nil), tags: T.unsafe(nil), keyword: T.unsafe(nil), name: T.unsafe(nil), description: T.unsafe(nil), table_header: T.unsafe(nil), table_body: T.unsafe(nil), id: T.unsafe(nil)); end # Returns the value of attribute description. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#407 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#435 def description; end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#413 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#441 def id; end # Returns the value of attribute keyword. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#403 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#431 def keyword; end # The location of the `Examples` keyword # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#399 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#427 def location; end # Returns the value of attribute name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#405 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#433 def name; end # Returns the value of attribute table_body. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#411 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#439 def table_body; end # Returns the value of attribute table_header. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#409 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#437 def table_header; end # Returns the value of attribute tags. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#401 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#429 def tags; end class << self @@ -565,51 +554,84 @@ class Cucumber::Messages::Examples < ::Cucumber::Messages::Message # # Cucumber::Messages::Examples.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#208 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#228 + def from_h(hash); end + end +end + +# Represents the Exception message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. +# +# A simplified representation of an exception +# +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#232 +class Cucumber::Messages::Exception < ::Cucumber::Messages::Message + # @return [Exception] a new instance of Exception + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#244 + def initialize(type: T.unsafe(nil), message: T.unsafe(nil)); end + + # The message of exception that caused this result. E.g. expected: "a" but was: "b" + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#242 + def message; end + + # The type of the exception that caused this result. E.g. "Error" or "org.opentest4j.AssertionFailedError" + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#237 + def type; end + + class << self + # Returns a new Exception from the given hash. + # If the hash keys are camelCased, they are properly assigned to the + # corresponding snake_cased attributes. + # + # Cucumber::Messages::Exception.from_h(some_hash) # => # + # + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#101 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#443 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#471 class Cucumber::Messages::Feature < ::Cucumber::Messages::Message # @return [Feature] a new instance of Feature # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#480 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#508 def initialize(location: T.unsafe(nil), tags: T.unsafe(nil), language: T.unsafe(nil), keyword: T.unsafe(nil), name: T.unsafe(nil), description: T.unsafe(nil), children: T.unsafe(nil)); end # Zero or more children # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#478 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#506 def children; end # The line(s) underneath the line with the `keyword` that are used as description # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#473 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#501 def description; end # The text of the `Feature` keyword (in the language specified by `language`) # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#463 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#491 def keyword; end # The [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1) language code of the Gherkin document # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#458 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#486 def language; end # The location of the `Feature` keyword # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#448 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#476 def location; end # The name of the feature (the text following the `keyword`) # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#468 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#496 def name; end # All the tags placed above the `Feature` keyword # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#453 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#481 def tags; end class << self @@ -619,36 +641,36 @@ class Cucumber::Messages::Feature < ::Cucumber::Messages::Message # # Cucumber::Messages::Feature.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#234 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#254 def from_h(hash); end end end -# Represents the FeatureChild message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the FeatureChild message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # A child node of a `Feature` node # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#507 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#535 class Cucumber::Messages::FeatureChild < ::Cucumber::Messages::Message # @return [FeatureChild] a new instance of FeatureChild # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#515 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#543 def initialize(rule: T.unsafe(nil), background: T.unsafe(nil), scenario: T.unsafe(nil)); end # Returns the value of attribute background. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#511 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#539 def background; end # Returns the value of attribute rule. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#509 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#537 def rule; end # Returns the value of attribute scenario. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#513 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#541 def scenario; end class << self @@ -658,12 +680,12 @@ class Cucumber::Messages::FeatureChild < ::Cucumber::Messages::Message # # Cucumber::Messages::FeatureChild.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#259 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#279 def from_h(hash); end end end -# Represents the GherkinDocument message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the GherkinDocument message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # The [AST](https://en.wikipedia.org/wiki/Abstract_syntax_tree) of a Gherkin document. @@ -673,28 +695,28 @@ end # The only consumers of `GherkinDocument` should only be formatters that produce # "rich" output, resembling the original Gherkin document. # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#238 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#266 class Cucumber::Messages::GherkinDocument < ::Cucumber::Messages::Message # @return [GherkinDocument] a new instance of GherkinDocument # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#254 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#282 def initialize(uri: T.unsafe(nil), feature: T.unsafe(nil), comments: T.unsafe(nil)); end # All the comments in the Gherkin document # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#252 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#280 def comments; end # Returns the value of attribute feature. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#247 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#275 def feature; end # * # The [URI](https://en.wikipedia.org/wiki/Uniform_Resource_Identifier) # of the source, typically a file path relative to the root directory # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#245 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#273 def uri; end class << self @@ -704,41 +726,41 @@ class Cucumber::Messages::GherkinDocument < ::Cucumber::Messages::Message # # Cucumber::Messages::GherkinDocument.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#101 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#121 def from_h(hash); end end end -# Represents the Git message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Git message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # Information about Git, provided by the Build/CI server as environment # variables. # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#942 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#980 class Cucumber::Messages::Git < ::Cucumber::Messages::Message # @return [Git] a new instance of Git # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#952 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#990 def initialize(remote: T.unsafe(nil), revision: T.unsafe(nil), branch: T.unsafe(nil), tag: T.unsafe(nil)); end # Returns the value of attribute branch. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#948 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#986 def branch; end # Returns the value of attribute remote. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#944 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#982 def remote; end # Returns the value of attribute revision. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#946 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#984 def revision; end # Returns the value of attribute tag. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#950 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#988 def tag; end class << self @@ -748,31 +770,31 @@ class Cucumber::Messages::Git < ::Cucumber::Messages::Message # # Cucumber::Messages::Git.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#525 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#546 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1507 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1558 class Cucumber::Messages::Group < ::Cucumber::Messages::Message # @return [Group] a new instance of Group # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1515 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1566 def initialize(children: T.unsafe(nil), start: T.unsafe(nil), value: T.unsafe(nil)); end # Returns the value of attribute children. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1509 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1560 def children; end # Returns the value of attribute start. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1511 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1562 def start; end # Returns the value of attribute value. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1513 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1564 def value; end class << self @@ -782,36 +804,36 @@ class Cucumber::Messages::Group < ::Cucumber::Messages::Message # # Cucumber::Messages::Group.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#921 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#944 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#793 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#831 class Cucumber::Messages::Hook < ::Cucumber::Messages::Message # @return [Hook] a new instance of Hook # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#803 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#841 def initialize(id: T.unsafe(nil), name: T.unsafe(nil), source_reference: T.unsafe(nil), tag_expression: T.unsafe(nil)); end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#795 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#833 def id; end # Returns the value of attribute name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#797 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#835 def name; end # Returns the value of attribute source_reference. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#799 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#837 def source_reference; end # Returns the value of attribute tag_expression. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#801 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#839 def tag_expression; end class << self @@ -821,7 +843,7 @@ class Cucumber::Messages::Hook < ::Cucumber::Messages::Message # # Cucumber::Messages::Hook.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#437 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#458 def from_h(hash); end end end @@ -846,26 +868,26 @@ class Cucumber::Messages::IdGenerator::UUID def new_id; end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1375 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1426 class Cucumber::Messages::JavaMethod < ::Cucumber::Messages::Message # @return [JavaMethod] a new instance of JavaMethod # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1383 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1434 def initialize(class_name: T.unsafe(nil), method_name: T.unsafe(nil), method_parameter_types: T.unsafe(nil)); end # Returns the value of attribute class_name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1377 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1428 def class_name; end # Returns the value of attribute method_name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1379 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1430 def method_name; end # Returns the value of attribute method_parameter_types. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1381 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1432 def method_parameter_types; end class << self @@ -875,31 +897,31 @@ class Cucumber::Messages::JavaMethod < ::Cucumber::Messages::Message # # Cucumber::Messages::JavaMethod.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#817 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#840 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1401 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1452 class Cucumber::Messages::JavaStackTraceElement < ::Cucumber::Messages::Message # @return [JavaStackTraceElement] a new instance of JavaStackTraceElement # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1409 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1460 def initialize(class_name: T.unsafe(nil), file_name: T.unsafe(nil), method_name: T.unsafe(nil)); end # Returns the value of attribute class_name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1403 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1454 def class_name; end # Returns the value of attribute file_name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1405 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1456 def file_name; end # Returns the value of attribute method_name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1407 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1458 def method_name; end class << self @@ -909,31 +931,31 @@ class Cucumber::Messages::JavaStackTraceElement < ::Cucumber::Messages::Message # # Cucumber::Messages::JavaStackTraceElement.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#838 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#861 def from_h(hash); end end end -# Represents the Location message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Location message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # Points to a line and a column in a text file # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#824 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#862 class Cucumber::Messages::Location < ::Cucumber::Messages::Message # @return [Location] a new instance of Location # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#830 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#868 def initialize(line: T.unsafe(nil), column: T.unsafe(nil)); end # Returns the value of attribute column. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#828 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#866 def column; end # Returns the value of attribute line. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#826 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#864 def line; end class << self @@ -943,7 +965,7 @@ class Cucumber::Messages::Location < ::Cucumber::Messages::Message # # Cucumber::Messages::Location.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#459 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#480 def from_h(hash); end end end @@ -1063,48 +1085,48 @@ module Cucumber::Messages::Message::Utils::ClassMethods def underscore(term); end end -# Represents the Meta message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Meta message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # This message contains meta information about the environment. Consumers can use # this for various purposes. # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#848 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#886 class Cucumber::Messages::Meta < ::Cucumber::Messages::Message # @return [Meta] a new instance of Meta # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#878 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#916 def initialize(protocol_version: T.unsafe(nil), implementation: T.unsafe(nil), runtime: T.unsafe(nil), os: T.unsafe(nil), cpu: T.unsafe(nil), ci: T.unsafe(nil)); end # Returns the value of attribute ci. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#876 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#914 def ci; end # 386, arm, amd64 etc # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#874 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#912 def cpu; end # SpecFlow, Cucumber-JVM, Cucumber.js, Cucumber-Ruby, Behat etc. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#859 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#897 def implementation; end # Windows, Linux, MacOS etc # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#869 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#907 def os; end # * # The [SEMVER](https://semver.org/) version number of the protocol # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#854 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#892 def protocol_version; end # Java, Ruby, Node.js etc # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#864 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#902 def runtime; end class << self @@ -1114,7 +1136,7 @@ class Cucumber::Messages::Meta < ::Cucumber::Messages::Message # # Cucumber::Messages::Meta.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#479 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#500 def from_h(hash); end end end @@ -1127,36 +1149,41 @@ class Cucumber::Messages::NdjsonToMessageEnumerator < ::Enumerator def initialize(io); end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1000 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1038 class Cucumber::Messages::ParameterType < ::Cucumber::Messages::Message # @return [ParameterType] a new instance of ParameterType # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1015 - def initialize(name: T.unsafe(nil), regular_expressions: T.unsafe(nil), prefer_for_regular_expression_match: T.unsafe(nil), use_for_snippets: T.unsafe(nil), id: T.unsafe(nil)); end + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1055 + def initialize(name: T.unsafe(nil), regular_expressions: T.unsafe(nil), prefer_for_regular_expression_match: T.unsafe(nil), use_for_snippets: T.unsafe(nil), id: T.unsafe(nil), source_reference: T.unsafe(nil)); end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1013 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1051 def id; end # The name is unique, so we don't need an id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1005 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1043 def name; end # Returns the value of attribute prefer_for_regular_expression_match. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1009 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1047 def prefer_for_regular_expression_match; end # Returns the value of attribute regular_expressions. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1007 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1045 def regular_expressions; end + # Returns the value of attribute source_reference. + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1053 + def source_reference; end + # Returns the value of attribute use_for_snippets. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1011 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1049 def use_for_snippets; end class << self @@ -1166,26 +1193,26 @@ class Cucumber::Messages::ParameterType < ::Cucumber::Messages::Message # # Cucumber::Messages::ParameterType.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#567 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#588 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1037 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1079 class Cucumber::Messages::ParseError < ::Cucumber::Messages::Message # @return [ParseError] a new instance of ParseError # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1043 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1085 def initialize(source: T.unsafe(nil), message: T.unsafe(nil)); end # Returns the value of attribute message. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1041 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1083 def message; end # Returns the value of attribute source. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1039 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1081 def source; end class << self @@ -1195,12 +1222,12 @@ class Cucumber::Messages::ParseError < ::Cucumber::Messages::Message # # Cucumber::Messages::ParseError.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#590 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#612 def from_h(hash); end end end -# Represents the Pickle message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Pickle message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # //// Pickles # @@ -1216,11 +1243,11 @@ end # # Each `PickleStep` of a `Pickle` is matched with a `StepDefinition` to create a `TestCase` # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1071 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1113 class Cucumber::Messages::Pickle < ::Cucumber::Messages::Message # @return [Pickle] a new instance of Pickle # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1114 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1156 def initialize(id: T.unsafe(nil), uri: T.unsafe(nil), name: T.unsafe(nil), language: T.unsafe(nil), steps: T.unsafe(nil), tags: T.unsafe(nil), ast_node_ids: T.unsafe(nil)); end # * @@ -1228,40 +1255,40 @@ class Cucumber::Messages::Pickle < ::Cucumber::Messages::Message # id of the pickle. A pickle constructed from `Examples` will have the first # id originating from the `Scenario` AST node, and the second from the `TableRow` AST node. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1112 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1154 def ast_node_ids; end # * # A unique id for the pickle # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1077 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1119 def id; end # The language of the pickle # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1092 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1134 def language; end # The name of the pickle # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1087 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1129 def name; end # One or more steps # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1097 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1139 def steps; end # * # One or more tags. If this pickle is constructed from a Gherkin document, # It includes inherited tags from the `Feature` as well. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1104 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1146 def tags; end # The uri of the source file # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1082 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1124 def uri; end class << self @@ -1271,26 +1298,26 @@ class Cucumber::Messages::Pickle < ::Cucumber::Messages::Message # # Cucumber::Messages::Pickle.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#610 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#632 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1140 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1182 class Cucumber::Messages::PickleDocString < ::Cucumber::Messages::Message # @return [PickleDocString] a new instance of PickleDocString # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1146 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1188 def initialize(media_type: T.unsafe(nil), content: T.unsafe(nil)); end # Returns the value of attribute content. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1144 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1186 def content; end # Returns the value of attribute media_type. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1142 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1184 def media_type; end class << self @@ -1300,44 +1327,51 @@ class Cucumber::Messages::PickleDocString < ::Cucumber::Messages::Message # # Cucumber::Messages::PickleDocString.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#635 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#657 def from_h(hash); end end end -# Represents the PickleStep message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the PickleStep message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # An executable step # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1163 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1205 class Cucumber::Messages::PickleStep < ::Cucumber::Messages::Message # @return [PickleStep] a new instance of PickleStep # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1180 - def initialize(argument: T.unsafe(nil), ast_node_ids: T.unsafe(nil), id: T.unsafe(nil), text: T.unsafe(nil)); end + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1229 + def initialize(argument: T.unsafe(nil), ast_node_ids: T.unsafe(nil), id: T.unsafe(nil), type: T.unsafe(nil), text: T.unsafe(nil)); end # Returns the value of attribute argument. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1165 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1207 def argument; end # References the IDs of the source of the step. For Gherkin, this can be # the ID of a Step, and possibly also the ID of a TableRow # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1171 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1213 def ast_node_ids; end # A unique ID for the PickleStep # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1176 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1218 def id; end # Returns the value of attribute text. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1178 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1227 def text; end + # The context in which the step was specified: context (Given), action (When) or outcome (Then). + # + # Note that the keywords `But` and `And` inherit their meaning from prior steps and the `*` 'keyword' doesn't have specific meaning (hence Unknown) + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1225 + def type; end + class << self # Returns a new PickleStep from the given hash. # If the hash keys are camelCased, they are properly assigned to the @@ -1345,30 +1379,30 @@ class Cucumber::Messages::PickleStep < ::Cucumber::Messages::Message # # Cucumber::Messages::PickleStep.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#655 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#677 def from_h(hash); end end end -# Represents the PickleStepArgument message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the PickleStepArgument message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # An optional argument # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1200 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1251 class Cucumber::Messages::PickleStepArgument < ::Cucumber::Messages::Message # @return [PickleStepArgument] a new instance of PickleStepArgument # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1206 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1257 def initialize(doc_string: T.unsafe(nil), data_table: T.unsafe(nil)); end # Returns the value of attribute data_table. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1204 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1255 def data_table; end # Returns the value of attribute doc_string. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1202 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1253 def doc_string; end class << self @@ -1378,21 +1412,36 @@ class Cucumber::Messages::PickleStepArgument < ::Cucumber::Messages::Message # # Cucumber::Messages::PickleStepArgument.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#677 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#700 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1222 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1966 +class Cucumber::Messages::PickleStepType; end + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1969 +Cucumber::Messages::PickleStepType::ACTION = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1968 +Cucumber::Messages::PickleStepType::CONTEXT = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1970 +Cucumber::Messages::PickleStepType::OUTCOME = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1967 +Cucumber::Messages::PickleStepType::UNKNOWN = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1273 class Cucumber::Messages::PickleTable < ::Cucumber::Messages::Message # @return [PickleTable] a new instance of PickleTable # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1226 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1277 def initialize(rows: T.unsafe(nil)); end # Returns the value of attribute rows. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1224 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1275 def rows; end class << self @@ -1402,21 +1451,21 @@ class Cucumber::Messages::PickleTable < ::Cucumber::Messages::Message # # Cucumber::Messages::PickleTable.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#697 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#720 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1240 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1291 class Cucumber::Messages::PickleTableCell < ::Cucumber::Messages::Message # @return [PickleTableCell] a new instance of PickleTableCell # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1244 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1295 def initialize(value: T.unsafe(nil)); end # Returns the value of attribute value. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1242 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1293 def value; end class << self @@ -1426,21 +1475,21 @@ class Cucumber::Messages::PickleTableCell < ::Cucumber::Messages::Message # # Cucumber::Messages::PickleTableCell.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#716 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#739 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1258 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1309 class Cucumber::Messages::PickleTableRow < ::Cucumber::Messages::Message # @return [PickleTableRow] a new instance of PickleTableRow # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1262 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1313 def initialize(cells: T.unsafe(nil)); end # Returns the value of attribute cells. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1260 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1311 def cells; end class << self @@ -1450,31 +1499,31 @@ class Cucumber::Messages::PickleTableRow < ::Cucumber::Messages::Message # # Cucumber::Messages::PickleTableRow.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#735 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#758 def from_h(hash); end end end -# Represents the PickleTag message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the PickleTag message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # A tag # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1277 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1328 class Cucumber::Messages::PickleTag < ::Cucumber::Messages::Message # @return [PickleTag] a new instance of PickleTag # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1286 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1337 def initialize(name: T.unsafe(nil), ast_node_id: T.unsafe(nil)); end # Points to the AST node this was created from # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1284 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1335 def ast_node_id; end # Returns the value of attribute name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1279 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1330 def name; end class << self @@ -1484,30 +1533,30 @@ class Cucumber::Messages::PickleTag < ::Cucumber::Messages::Message # # Cucumber::Messages::PickleTag.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#754 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#777 def from_h(hash); end end end -# Represents the Product message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Product message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # Used to describe various properties of Meta # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#972 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1010 class Cucumber::Messages::Product < ::Cucumber::Messages::Message # @return [Product] a new instance of Product # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#984 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1022 def initialize(name: T.unsafe(nil), version: T.unsafe(nil)); end # The product name # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#977 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1015 def name; end # The product version # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#982 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1020 def version; end class << self @@ -1517,51 +1566,51 @@ class Cucumber::Messages::Product < ::Cucumber::Messages::Message # # Cucumber::Messages::Product.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#547 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#568 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#533 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#561 class Cucumber::Messages::Rule < ::Cucumber::Messages::Message # @return [Rule] a new instance of Rule # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#555 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#583 def initialize(location: T.unsafe(nil), tags: T.unsafe(nil), keyword: T.unsafe(nil), name: T.unsafe(nil), description: T.unsafe(nil), children: T.unsafe(nil), id: T.unsafe(nil)); end # Returns the value of attribute children. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#551 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#579 def children; end # Returns the value of attribute description. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#549 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#577 def description; end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#553 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#581 def id; end # Returns the value of attribute keyword. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#545 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#573 def keyword; end # The location of the `Rule` keyword # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#538 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#566 def location; end # Returns the value of attribute name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#547 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#575 def name; end # All the tags placed above the `Rule` keyword # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#543 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#571 def tags; end class << self @@ -1571,31 +1620,31 @@ class Cucumber::Messages::Rule < ::Cucumber::Messages::Message # # Cucumber::Messages::Rule.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#280 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#300 def from_h(hash); end end end -# Represents the RuleChild message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the RuleChild message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # A child node of a `Rule` node # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#582 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#610 class Cucumber::Messages::RuleChild < ::Cucumber::Messages::Message # @return [RuleChild] a new instance of RuleChild # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#588 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#616 def initialize(background: T.unsafe(nil), scenario: T.unsafe(nil)); end # Returns the value of attribute background. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#584 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#612 def background; end # Returns the value of attribute scenario. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#586 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#614 def scenario; end class << self @@ -1605,56 +1654,56 @@ class Cucumber::Messages::RuleChild < ::Cucumber::Messages::Message # # Cucumber::Messages::RuleChild.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#305 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#325 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#604 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#632 class Cucumber::Messages::Scenario < ::Cucumber::Messages::Message # @return [Scenario] a new instance of Scenario # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#625 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#653 def initialize(location: T.unsafe(nil), tags: T.unsafe(nil), keyword: T.unsafe(nil), name: T.unsafe(nil), description: T.unsafe(nil), steps: T.unsafe(nil), examples: T.unsafe(nil), id: T.unsafe(nil)); end # Returns the value of attribute description. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#617 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#645 def description; end # Returns the value of attribute examples. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#621 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#649 def examples; end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#623 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#651 def id; end # Returns the value of attribute keyword. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#613 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#641 def keyword; end # The location of the `Scenario` keyword # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#609 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#637 def location; end # Returns the value of attribute name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#615 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#643 def name; end # Returns the value of attribute steps. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#619 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#647 def steps; end # Returns the value of attribute tags. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#611 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#639 def tags; end class << self @@ -1664,41 +1713,41 @@ class Cucumber::Messages::Scenario < ::Cucumber::Messages::Message # # Cucumber::Messages::Scenario.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#325 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#345 def from_h(hash); end end end -# Represents the Source message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Source message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # //// Source # # * # A source file, typically a Gherkin document or Java/Ruby/JavaScript source code # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1305 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1356 class Cucumber::Messages::Source < ::Cucumber::Messages::Message # @return [Source] a new instance of Source # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1325 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1376 def initialize(uri: T.unsafe(nil), data: T.unsafe(nil), media_type: T.unsafe(nil)); end # The contents of the file # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1317 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1368 def data; end # The media type of the file. Can be used to specify custom types, such as # text/x.cucumber.gherkin+plain # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1323 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1374 def media_type; end # * # The [URI](https://en.wikipedia.org/wiki/Uniform_Resource_Identifier) # of the source, typically a file path relative to the root directory # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1312 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1363 def uri; end class << self @@ -1708,51 +1757,51 @@ class Cucumber::Messages::Source < ::Cucumber::Messages::Message # # Cucumber::Messages::Source.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#774 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#797 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1895 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1973 class Cucumber::Messages::SourceMediaType; end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1897 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1975 Cucumber::Messages::SourceMediaType::TEXT_X_CUCUMBER_GHERKIN_MARKDOWN = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1896 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1974 Cucumber::Messages::SourceMediaType::TEXT_X_CUCUMBER_GHERKIN_PLAIN = T.let(T.unsafe(nil), String) -# Represents the SourceReference message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the SourceReference message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # Points to a [Source](#io.cucumber.messages.Source) identified by `uri` and a # [Location](#io.cucumber.messages.Location) within that file. # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1345 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1396 class Cucumber::Messages::SourceReference < ::Cucumber::Messages::Message # @return [SourceReference] a new instance of SourceReference # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1355 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1406 def initialize(uri: T.unsafe(nil), java_method: T.unsafe(nil), java_stack_trace_element: T.unsafe(nil), location: T.unsafe(nil)); end # Returns the value of attribute java_method. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1349 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1400 def java_method; end # Returns the value of attribute java_stack_trace_element. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1351 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1402 def java_stack_trace_element; end # Returns the value of attribute location. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1353 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1404 def location; end # Returns the value of attribute uri. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1347 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1398 def uri; end class << self @@ -1762,50 +1811,55 @@ class Cucumber::Messages::SourceReference < ::Cucumber::Messages::Message # # Cucumber::Messages::SourceReference.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#795 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#818 def from_h(hash); end end end -# Represents the Step message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Step message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # A step # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#653 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#681 class Cucumber::Messages::Step < ::Cucumber::Messages::Message # @return [Step] a new instance of Step # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#673 - def initialize(location: T.unsafe(nil), keyword: T.unsafe(nil), text: T.unsafe(nil), doc_string: T.unsafe(nil), data_table: T.unsafe(nil), id: T.unsafe(nil)); end + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#709 + def initialize(location: T.unsafe(nil), keyword: T.unsafe(nil), keyword_type: T.unsafe(nil), text: T.unsafe(nil), doc_string: T.unsafe(nil), data_table: T.unsafe(nil), id: T.unsafe(nil)); end # Returns the value of attribute data_table. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#666 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#702 def data_table; end # Returns the value of attribute doc_string. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#664 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#700 def doc_string; end # Unique ID to be able to reference the Step from PickleStep # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#671 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#707 def id; end - # Returns the value of attribute keyword. + # The actual keyword as it appeared in the source. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#660 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#691 def keyword; end + # The test phase signalled by the keyword: Context definition (Given), Action performance (When), Outcome assertion (Then). Other keywords signal Continuation (And and But) from a prior keyword. Please note that all translations which a dialect maps to multiple keywords (`*` is in this category for all dialects), map to 'Unknown'. + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#696 + def keyword_type; end + # The location of the steps' `keyword` # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#658 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#686 def location; end # Returns the value of attribute text. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#662 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#698 def text; end class << self @@ -1815,31 +1869,31 @@ class Cucumber::Messages::Step < ::Cucumber::Messages::Message # # Cucumber::Messages::Step.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#351 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#371 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1427 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1478 class Cucumber::Messages::StepDefinition < ::Cucumber::Messages::Message # @return [StepDefinition] a new instance of StepDefinition # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1435 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1486 def initialize(id: T.unsafe(nil), pattern: T.unsafe(nil), source_reference: T.unsafe(nil)); end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1429 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1480 def id; end # Returns the value of attribute pattern. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1431 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1482 def pattern; end # Returns the value of attribute source_reference. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1433 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1484 def source_reference; end class << self @@ -1849,26 +1903,26 @@ class Cucumber::Messages::StepDefinition < ::Cucumber::Messages::Message # # Cucumber::Messages::StepDefinition.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#859 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#882 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1453 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1504 class Cucumber::Messages::StepDefinitionPattern < ::Cucumber::Messages::Message # @return [StepDefinitionPattern] a new instance of StepDefinitionPattern # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1459 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1510 def initialize(source: T.unsafe(nil), type: T.unsafe(nil)); end # Returns the value of attribute source. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1455 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1506 def source; end # Returns the value of attribute type. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1457 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1508 def type; end class << self @@ -1878,21 +1932,39 @@ class Cucumber::Messages::StepDefinitionPattern < ::Cucumber::Messages::Message # # Cucumber::Messages::StepDefinitionPattern.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#880 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#903 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1900 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1978 class Cucumber::Messages::StepDefinitionPatternType; end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1901 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1979 Cucumber::Messages::StepDefinitionPatternType::CUCUMBER_EXPRESSION = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1902 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1980 Cucumber::Messages::StepDefinitionPatternType::REGULAR_EXPRESSION = T.let(T.unsafe(nil), String) -# Represents the StepMatchArgument message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1983 +class Cucumber::Messages::StepKeywordType; end + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1986 +Cucumber::Messages::StepKeywordType::ACTION = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1988 +Cucumber::Messages::StepKeywordType::CONJUNCTION = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1985 +Cucumber::Messages::StepKeywordType::CONTEXT = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1987 +Cucumber::Messages::StepKeywordType::OUTCOME = T.let(T.unsafe(nil), String) + +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1984 +Cucumber::Messages::StepKeywordType::UNKNOWN = T.let(T.unsafe(nil), String) + +# Represents the StepMatchArgument message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # Represents a single argument extracted from a step match and passed to a step definition. @@ -1902,23 +1974,23 @@ Cucumber::Messages::StepDefinitionPatternType::REGULAR_EXPRESSION = T.let(T.unsa # # This message closely matches the `Argument` class in the `cucumber-expressions` library. # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1539 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1590 class Cucumber::Messages::StepMatchArgument < ::Cucumber::Messages::Message # @return [StepMatchArgument] a new instance of StepMatchArgument # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1550 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1601 def initialize(group: T.unsafe(nil), parameter_type_name: T.unsafe(nil)); end # * # Represents the outermost capture group of an argument. This message closely matches the # `Group` class in the `cucumber-expressions` library. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1546 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1597 def group; end # Returns the value of attribute parameter_type_name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1548 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1599 def parameter_type_name; end class << self @@ -1928,21 +2000,21 @@ class Cucumber::Messages::StepMatchArgument < ::Cucumber::Messages::Message # # Cucumber::Messages::StepMatchArgument.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#942 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#965 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1566 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1617 class Cucumber::Messages::StepMatchArgumentsList < ::Cucumber::Messages::Message # @return [StepMatchArgumentsList] a new instance of StepMatchArgumentsList # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1570 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1621 def initialize(step_match_arguments: T.unsafe(nil)); end # Returns the value of attribute step_match_arguments. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1568 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1619 def step_match_arguments; end class << self @@ -1952,30 +2024,30 @@ class Cucumber::Messages::StepMatchArgumentsList < ::Cucumber::Messages::Message # # Cucumber::Messages::StepMatchArgumentsList.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#962 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#985 def from_h(hash); end end end -# Represents the TableCell message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the TableCell message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # A cell in a `TableRow` # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#697 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#735 class Cucumber::Messages::TableCell < ::Cucumber::Messages::Message # @return [TableCell] a new instance of TableCell # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#709 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#747 def initialize(location: T.unsafe(nil), value: T.unsafe(nil)); end # The location of the cell # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#702 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#740 def location; end # The value of the cell # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#707 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#745 def value; end class << self @@ -1985,35 +2057,35 @@ class Cucumber::Messages::TableCell < ::Cucumber::Messages::Message # # Cucumber::Messages::TableCell.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#375 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#396 def from_h(hash); end end end -# Represents the TableRow message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the TableRow message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # A row in a table # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#725 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#763 class Cucumber::Messages::TableRow < ::Cucumber::Messages::Message # @return [TableRow] a new instance of TableRow # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#739 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#777 def initialize(location: T.unsafe(nil), cells: T.unsafe(nil), id: T.unsafe(nil)); end # Cells in the row # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#735 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#773 def cells; end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#737 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#775 def id; end # The location of the first cell in the row # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#730 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#768 def location; end class << self @@ -2023,36 +2095,36 @@ class Cucumber::Messages::TableRow < ::Cucumber::Messages::Message # # Cucumber::Messages::TableRow.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#395 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#416 def from_h(hash); end end end -# Represents the Tag message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the Tag message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # A tag # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#758 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#796 class Cucumber::Messages::Tag < ::Cucumber::Messages::Message # @return [Tag] a new instance of Tag # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#775 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#813 def initialize(location: T.unsafe(nil), name: T.unsafe(nil), id: T.unsafe(nil)); end # Unique ID to be able to reference the Tag from PickleTag # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#773 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#811 def id; end # Location of the tag # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#763 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#801 def location; end # The name of the tag (including the leading `@`) # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#768 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#806 def name; end class << self @@ -2062,38 +2134,38 @@ class Cucumber::Messages::Tag < ::Cucumber::Messages::Message # # Cucumber::Messages::Tag.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#416 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#437 def from_h(hash); end end end -# Represents the TestCase message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the TestCase message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # //// TestCases # # * # A `TestCase` contains a sequence of `TestStep`s. # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1478 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1529 class Cucumber::Messages::TestCase < ::Cucumber::Messages::Message # @return [TestCase] a new instance of TestCase # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1489 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1540 def initialize(id: T.unsafe(nil), pickle_id: T.unsafe(nil), test_steps: T.unsafe(nil)); end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1480 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1531 def id; end # The ID of the `Pickle` this `TestCase` is derived from. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1485 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1536 def pickle_id; end # Returns the value of attribute test_steps. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1487 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1538 def test_steps; end class << self @@ -2103,31 +2175,31 @@ class Cucumber::Messages::TestCase < ::Cucumber::Messages::Message # # Cucumber::Messages::TestCase.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#900 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#923 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1634 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1685 class Cucumber::Messages::TestCaseFinished < ::Cucumber::Messages::Message # @return [TestCaseFinished] a new instance of TestCaseFinished # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1642 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1693 def initialize(test_case_started_id: T.unsafe(nil), timestamp: T.unsafe(nil), will_be_retried: T.unsafe(nil)); end # Returns the value of attribute test_case_started_id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1636 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1687 def test_case_started_id; end # Returns the value of attribute timestamp. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1638 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1689 def timestamp; end # Returns the value of attribute will_be_retried. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1640 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1691 def will_be_retried; end class << self @@ -2137,42 +2209,47 @@ class Cucumber::Messages::TestCaseFinished < ::Cucumber::Messages::Message # # Cucumber::Messages::TestCaseFinished.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1004 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1027 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1660 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1711 class Cucumber::Messages::TestCaseStarted < ::Cucumber::Messages::Message # @return [TestCaseStarted] a new instance of TestCaseStarted # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1680 - def initialize(attempt: T.unsafe(nil), id: T.unsafe(nil), test_case_id: T.unsafe(nil), timestamp: T.unsafe(nil)); end + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1736 + def initialize(attempt: T.unsafe(nil), id: T.unsafe(nil), test_case_id: T.unsafe(nil), worker_id: T.unsafe(nil), timestamp: T.unsafe(nil)); end # * # The first attempt should have value 0, and for each retry the value # should increase by 1. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1667 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1718 def attempt; end # * # Because a `TestCase` can be run multiple times (in case of a retry), # we use this field to group messages relating to the same attempt. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1674 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1725 def id; end # Returns the value of attribute test_case_id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1676 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1727 def test_case_id; end # Returns the value of attribute timestamp. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1678 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1734 def timestamp; end + # An identifier for the worker process running this test case, if test cases are being run in parallel. The identifier will be unique per worker, but no particular format is defined - it could be an index, uuid, machine name etc - and as such should be assumed that it's not human readable. + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1732 + def worker_id; end + class << self # Returns a new TestCaseStarted from the given hash. # If the hash keys are camelCased, they are properly assigned to the @@ -2180,35 +2257,36 @@ class Cucumber::Messages::TestCaseStarted < ::Cucumber::Messages::Message # # Cucumber::Messages::TestCaseStarted.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1025 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1048 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1700 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1758 class Cucumber::Messages::TestRunFinished < ::Cucumber::Messages::Message # @return [TestRunFinished] a new instance of TestRunFinished # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1721 - def initialize(message: T.unsafe(nil), success: T.unsafe(nil), timestamp: T.unsafe(nil)); end + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1780 + def initialize(message: T.unsafe(nil), success: T.unsafe(nil), timestamp: T.unsafe(nil), exception: T.unsafe(nil)); end - # Error message. Can be a stack trace from a failed `BeforeAll` or `AfterAll`. - # If there are undefined parameter types, the message is simply - # "The following parameter type(s() are not defined: xxx, yyy". - # The independent `UndefinedParameterType` messages can be used to generate - # snippets for those parameter types. + # Any exception thrown during the test run, if any. Does not include exceptions thrown while executing steps. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1709 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1778 + def exception; end + + # An informative message about the test run. Typically additional information about failure, but not necessarily. + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1763 def message; end - # success = StrictModeEnabled ? (failed_count == 0 && ambiguous_count == 0 && undefined_count == 0 && pending_count == 0) : (failed_count == 0 && ambiguous_count == 0) + # A test run is successful if all steps are either passed or skipped, all before/after hooks passed and no other exceptions where thrown. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1714 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1768 def success; end # Timestamp when the TestRun is finished # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1719 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1773 def timestamp; end class << self @@ -2218,21 +2296,21 @@ class Cucumber::Messages::TestRunFinished < ::Cucumber::Messages::Message # # Cucumber::Messages::TestRunFinished.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1047 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1071 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1739 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1800 class Cucumber::Messages::TestRunStarted < ::Cucumber::Messages::Message # @return [TestRunStarted] a new instance of TestRunStarted # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1743 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1804 def initialize(timestamp: T.unsafe(nil)); end # Returns the value of attribute timestamp. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1741 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1802 def timestamp; end class << self @@ -2242,49 +2320,49 @@ class Cucumber::Messages::TestRunStarted < ::Cucumber::Messages::Message # # Cucumber::Messages::TestRunStarted.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1068 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1093 def from_h(hash); end end end -# Represents the TestStep message in Cucumber's {message protocol}[https://github.com/cucumber/common/tree/main/messages#readme]. +# Represents the TestStep message in Cucumber's {message protocol}[https://github.com/cucumber/messages]. # # * # A `TestStep` is derived from either a `PickleStep` # combined with a `StepDefinition`, or from a `Hook`. # -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1586 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1637 class Cucumber::Messages::TestStep < ::Cucumber::Messages::Message # @return [TestStep] a new instance of TestStep # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1612 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1663 def initialize(hook_id: T.unsafe(nil), id: T.unsafe(nil), pickle_step_id: T.unsafe(nil), step_definition_ids: T.unsafe(nil), step_match_arguments_lists: T.unsafe(nil)); end # Pointer to the `Hook` (if derived from a Hook) # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1591 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1642 def hook_id; end # Returns the value of attribute id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1593 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1644 def id; end # Pointer to the `PickleStep` (if derived from a `PickleStep`) # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1598 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1649 def pickle_step_id; end # Pointer to all the matching `StepDefinition`s (if derived from a `PickleStep`) # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1603 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1654 def step_definition_ids; end # A list of list of StepMatchArgument (if derived from a `PickleStep`). # Each element represents a matching step definition. A size of 0 means `UNDEFINED`, # and a size of 2+ means `AMBIGUOUS` # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1610 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1661 def step_match_arguments_lists; end class << self @@ -2294,36 +2372,36 @@ class Cucumber::Messages::TestStep < ::Cucumber::Messages::Message # # Cucumber::Messages::TestStep.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#981 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1004 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1757 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1818 class Cucumber::Messages::TestStepFinished < ::Cucumber::Messages::Message # @return [TestStepFinished] a new instance of TestStepFinished # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1767 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1828 def initialize(test_case_started_id: T.unsafe(nil), test_step_id: T.unsafe(nil), test_step_result: T.unsafe(nil), timestamp: T.unsafe(nil)); end # Returns the value of attribute test_case_started_id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1759 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1820 def test_case_started_id; end # Returns the value of attribute test_step_id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1761 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1822 def test_step_id; end # Returns the value of attribute test_step_result. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1763 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1824 def test_step_result; end # Returns the value of attribute timestamp. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1765 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1826 def timestamp; end class << self @@ -2333,31 +2411,36 @@ class Cucumber::Messages::TestStepFinished < ::Cucumber::Messages::Message # # Cucumber::Messages::TestStepFinished.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1087 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1112 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1787 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1848 class Cucumber::Messages::TestStepResult < ::Cucumber::Messages::Message # @return [TestStepResult] a new instance of TestStepResult # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1795 - def initialize(duration: T.unsafe(nil), message: T.unsafe(nil), status: T.unsafe(nil)); end + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1864 + def initialize(duration: T.unsafe(nil), message: T.unsafe(nil), status: T.unsafe(nil), exception: T.unsafe(nil)); end # Returns the value of attribute duration. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1789 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1850 def duration; end - # Returns the value of attribute message. + # Exception thrown while executing this step, if any. + # + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1862 + def exception; end + + # An arbitrary bit of information that explains this result. This can be a stack trace of anything else. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1791 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1855 def message; end # Returns the value of attribute status. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1793 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1857 def status; end class << self @@ -2367,55 +2450,55 @@ class Cucumber::Messages::TestStepResult < ::Cucumber::Messages::Message # # Cucumber::Messages::TestStepResult.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1109 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1134 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1905 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1991 class Cucumber::Messages::TestStepResultStatus; end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1911 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1997 Cucumber::Messages::TestStepResultStatus::AMBIGUOUS = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1912 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1998 Cucumber::Messages::TestStepResultStatus::FAILED = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1907 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1993 Cucumber::Messages::TestStepResultStatus::PASSED = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1909 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1995 Cucumber::Messages::TestStepResultStatus::PENDING = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1908 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1994 Cucumber::Messages::TestStepResultStatus::SKIPPED = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1910 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1996 Cucumber::Messages::TestStepResultStatus::UNDEFINED = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1906 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1992 Cucumber::Messages::TestStepResultStatus::UNKNOWN = T.let(T.unsafe(nil), String) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1813 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1884 class Cucumber::Messages::TestStepStarted < ::Cucumber::Messages::Message # @return [TestStepStarted] a new instance of TestStepStarted # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1821 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1892 def initialize(test_case_started_id: T.unsafe(nil), test_step_id: T.unsafe(nil), timestamp: T.unsafe(nil)); end # Returns the value of attribute test_case_started_id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1815 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1886 def test_case_started_id; end # Returns the value of attribute test_step_id. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1817 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1888 def test_step_id; end # Returns the value of attribute timestamp. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1819 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1890 def timestamp; end class << self @@ -2425,7 +2508,7 @@ class Cucumber::Messages::TestStepStarted < ::Cucumber::Messages::Message # # Cucumber::Messages::TestStepStarted.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1130 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1156 def from_h(hash); end end end @@ -2448,11 +2531,11 @@ end # source://cucumber-messages//lib/cucumber/messages/time_conversion.rb#4 Cucumber::Messages::TimeConversion::NANOSECONDS_PER_SECOND = T.let(T.unsafe(nil), Integer) -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1839 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1910 class Cucumber::Messages::Timestamp < ::Cucumber::Messages::Message # @return [Timestamp] a new instance of Timestamp # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1856 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1927 def initialize(seconds: T.unsafe(nil), nanos: T.unsafe(nil)); end # Non-negative fractions of a second at nanosecond resolution. Negative @@ -2460,14 +2543,14 @@ class Cucumber::Messages::Timestamp < ::Cucumber::Messages::Message # that count forward in time. Must be from 0 to 999,999,999 # inclusive. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1854 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1925 def nanos; end # Represents seconds of UTC time since Unix epoch # 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to # 9999-12-31T23:59:59Z inclusive. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1846 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1917 def seconds; end class << self @@ -2477,26 +2560,26 @@ class Cucumber::Messages::Timestamp < ::Cucumber::Messages::Message # # Cucumber::Messages::Timestamp.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1151 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1177 def from_h(hash); end end end -# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1872 +# source://cucumber-messages//lib/cucumber/messages.dtos.rb#1943 class Cucumber::Messages::UndefinedParameterType < ::Cucumber::Messages::Message # @return [UndefinedParameterType] a new instance of UndefinedParameterType # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1878 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1949 def initialize(expression: T.unsafe(nil), name: T.unsafe(nil)); end # Returns the value of attribute expression. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1874 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1945 def expression; end # Returns the value of attribute name. # - # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1876 + # source://cucumber-messages//lib/cucumber/messages.dtos.rb#1947 def name; end class << self @@ -2506,37 +2589,10 @@ class Cucumber::Messages::UndefinedParameterType < ::Cucumber::Messages::Message # # Cucumber::Messages::UndefinedParameterType.from_h(some_hash) # => # # - # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1171 + # source://cucumber-messages//lib/cucumber/messages.deserializers.rb#1197 def from_h(hash); end end end # source://cucumber-messages//lib/cucumber/messages.rb#8 Cucumber::Messages::VERSION = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#11 -Cucumber::OS_X = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#13 -Cucumber::RAILS = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#15 -Cucumber::RUBY = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#14 -Cucumber::RUBY_1_9 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#13 -Cucumber::RUBY_2_0 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#14 -Cucumber::RUBY_BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#10 -Cucumber::VERSION = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#10 -Cucumber::WINDOWS = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#12 -Cucumber::WINDOWS_MRI = T.let(T.unsafe(nil), T.untyped) diff --git a/sorbet/rbi/gems/cucumber-rails@2.6.1.rbi b/sorbet/rbi/gems/cucumber-rails@3.0.0.rbi similarity index 99% rename from sorbet/rbi/gems/cucumber-rails@2.6.1.rbi rename to sorbet/rbi/gems/cucumber-rails@3.0.0.rbi index f212394bb..579bfc9bf 100644 --- a/sorbet/rbi/gems/cucumber-rails@2.6.1.rbi +++ b/sorbet/rbi/gems/cucumber-rails@3.0.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `cucumber-rails` gem. # Please instead update this file by running `bin/tapioca gem cucumber-rails`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/cucumber-tag-expressions@4.1.0.rbi b/sorbet/rbi/gems/cucumber-tag-expressions@6.1.0.rbi similarity index 56% rename from sorbet/rbi/gems/cucumber-tag-expressions@4.1.0.rbi rename to sorbet/rbi/gems/cucumber-tag-expressions@6.1.0.rbi index d24bff985..b49a712ef 100644 --- a/sorbet/rbi/gems/cucumber-tag-expressions@4.1.0.rbi +++ b/sorbet/rbi/gems/cucumber-tag-expressions@6.1.0.rbi @@ -4,208 +4,175 @@ # This is an autogenerated file for types exported from the `cucumber-tag-expressions` gem. # Please instead update this file by running `bin/tapioca gem cucumber-tag-expressions`. -# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#1 + +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#3 module Cucumber class << self - # source://cucumber/8.0.0/lib/cucumber/deprecate.rb#52 - def deprecate(*args); end + # source://cucumber/9.2.0/lib/cucumber/deprecate.rb#7 + def deprecate(message, method, remove_after_version); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#21 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#17 def file_mode(mode, encoding = T.unsafe(nil)); end - # source://cucumber/8.0.0/lib/cucumber.rb#15 + # source://cucumber/9.2.0/lib/cucumber.rb#15 def logger; end - # source://cucumber/8.0.0/lib/cucumber.rb#23 + # source://cucumber/9.2.0/lib/cucumber.rb#23 def logger=(logger); end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace; end - # source://cucumber/8.0.0/lib/cucumber/platform.rb#18 + # source://cucumber/9.2.0/lib/cucumber/platform.rb#14 def use_full_backtrace=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def use_legacy_autoloader=(_arg0); end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit; end - # source://cucumber/8.0.0/lib/cucumber.rb#13 + # source://cucumber/9.2.0/lib/cucumber.rb#13 def wants_to_quit=(_arg0); end end end -# source://cucumber/8.0.0/lib/cucumber/platform.rb#11 -Cucumber::BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#9 -Cucumber::IRONRUBY = T.let(T.unsafe(nil), FalseClass) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#8 -Cucumber::JRUBY = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#12 -Cucumber::LIBDIR = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#11 -Cucumber::OS_X = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#13 -Cucumber::RAILS = T.let(T.unsafe(nil), String) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#15 -Cucumber::RUBY = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#14 -Cucumber::RUBY_1_9 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#13 -Cucumber::RUBY_2_0 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber/8.0.0/lib/cucumber/platform.rb#14 -Cucumber::RUBY_BINARY = T.let(T.unsafe(nil), String) - -# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#2 +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#4 module Cucumber::TagExpressions; end # And expression node # -# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#50 +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#61 class Cucumber::TagExpressions::And # @return [And] a new instance of And # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#51 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#62 def initialize(left, right); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#56 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#67 def evaluate(variables); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#60 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#71 def to_s; end end # Literal expression node # -# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#4 +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#6 class Cucumber::TagExpressions::Literal # @return [Literal] a new instance of Literal # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#5 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#7 def initialize(value); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#9 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#11 def evaluate(variables); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#13 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#15 def to_s; end end # Not expression node # -# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#19 +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#25 class Cucumber::TagExpressions::Not # @return [Not] a new instance of Not # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#20 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#26 def initialize(expression); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#24 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#30 def evaluate(variables); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#28 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#34 def to_s; end end # Or expression node # -# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#34 +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#45 class Cucumber::TagExpressions::Or # @return [Or] a new instance of Or # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#35 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#46 def initialize(left, right); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#40 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#51 def evaluate(variables); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#44 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#55 def to_s; end end -# Ruby tag expression parser -# -# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#6 +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#7 class Cucumber::TagExpressions::Parser # @return [Parser] a new instance of Parser # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#7 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#8 def initialize; end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#20 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#21 def parse(infix_expression); end private - # Helpers - # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#35 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#45 def assoc_of(token, value); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#153 - def check(expected_token_type, token_type); end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#133 + def check(infix_expression, expected_token_type, token_type); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#121 - def handle_binary_operator(token, expected_token_type); end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#105 + def handle_binary_operator(infix_expression, token, expected_token_type); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#137 - def handle_close_paren(_token, expected_token_type); end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#118 + def handle_close_paren(infix_expression, _token, expected_token_type); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#147 - def handle_literal(token, expected_token_type); end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#127 + def handle_literal(infix_expression, token, expected_token_type); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#131 - def handle_open_paren(token, expected_token_type); end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#112 + def handle_open_paren(infix_expression, token, expected_token_type); end - # Handlers - # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#115 - def handle_unary_operator(token, expected_token_type); end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#99 + def handle_unary_operator(infix_expression, token, expected_token_type); end # @return [Boolean] # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#39 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#49 def lower_precedence?(operation); end # @return [Boolean] # - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#46 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#54 def operator?(token); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#159 - def pop(array, n = T.unsafe(nil)); end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#139 + def pop(array, amount = T.unsafe(nil)); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#51 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#58 def precedence(token); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#88 - def process_tokens!(infix_expression); end - - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#99 + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#90 def push_expression(token); end - # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#55 - def tokens(infix_expression); end -end + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#62 + def tokenize(infix_expression); end -# source://cucumber/8.0.0/lib/cucumber/platform.rb#10 -Cucumber::VERSION = T.let(T.unsafe(nil), String) + # @return [Boolean] + # + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/parser.rb#146 + def whitespace?(char); end +end -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#10 -Cucumber::WINDOWS = T.let(T.unsafe(nil), T.untyped) +# source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#76 +class Cucumber::TagExpressions::True + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#77 + def evaluate(_variables); end -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#12 -Cucumber::WINDOWS_MRI = T.let(T.unsafe(nil), T.untyped) + # source://cucumber-tag-expressions//lib/cucumber/tag_expressions/expressions.rb#81 + def to_s; end +end diff --git a/sorbet/rbi/gems/cucumber@8.0.0.rbi b/sorbet/rbi/gems/cucumber@9.2.0.rbi similarity index 90% rename from sorbet/rbi/gems/cucumber@8.0.0.rbi rename to sorbet/rbi/gems/cucumber@9.2.0.rbi index 65ee3f90a..9b6f75726 100644 --- a/sorbet/rbi/gems/cucumber@8.0.0.rbi +++ b/sorbet/rbi/gems/cucumber@9.2.0.rbi @@ -4,15 +4,16 @@ # This is an autogenerated file for types exported from the `cucumber` gem. # Please instead update this file by running `bin/tapioca gem cucumber`. -# source://cucumber//lib/cucumber/platform.rb#8 + +# source://cucumber//lib/cucumber/platform.rb#7 module Cucumber class << self - # source://cucumber//lib/cucumber/deprecate.rb#52 - def deprecate(*args); end + # source://cucumber//lib/cucumber/deprecate.rb#7 + def deprecate(message, method, remove_after_version); end # @private # - # source://cucumber//lib/cucumber/platform.rb#21 + # source://cucumber//lib/cucumber/platform.rb#17 def file_mode(mode, encoding = T.unsafe(nil)); end # source://cucumber//lib/cucumber.rb#15 @@ -23,14 +24,14 @@ module Cucumber # Returns the value of attribute use_full_backtrace. # - # source://cucumber//lib/cucumber/platform.rb#18 + # source://cucumber//lib/cucumber/platform.rb#14 def use_full_backtrace; end # Sets the attribute use_full_backtrace # # @param value the value to set the attribute use_full_backtrace to. # - # source://cucumber//lib/cucumber/platform.rb#18 + # source://cucumber//lib/cucumber/platform.rb#14 def use_full_backtrace=(_arg0); end # Returns the value of attribute use_legacy_autoloader. @@ -80,7 +81,7 @@ class Cucumber::AmbiguousStepMatch def activate(test_step); end end -# source://cucumber//lib/cucumber/platform.rb#11 +# source://cucumber//lib/cucumber/platform.rb#9 Cucumber::BINARY = T.let(T.unsafe(nil), String) # source://cucumber//lib/cucumber/cli/rerun_file.rb#4 @@ -252,222 +253,220 @@ end class Cucumber::Cli::Options # @return [Options] a new instance of Options # - # source://cucumber//lib/cucumber/cli/options.rb#72 + # source://cucumber//lib/cucumber/cli/options.rb#73 def initialize(out_stream = T.unsafe(nil), error_stream = T.unsafe(nil), options = T.unsafe(nil)); end - # source://cucumber//lib/cucumber/cli/options.rb#86 + # source://cucumber//lib/cucumber/cli/options.rb#87 def [](key); end - # source://cucumber//lib/cucumber/cli/options.rb#90 + # source://cucumber//lib/cucumber/cli/options.rb#91 def []=(key, value); end - # source://cucumber//lib/cucumber/cli/options.rb#180 + # source://cucumber//lib/cucumber/cli/options.rb#182 def check_formatter_stream_conflicts; end - # source://cucumber//lib/cucumber/cli/options.rb#172 + # source://cucumber//lib/cucumber/cli/options.rb#174 def custom_profiles; end - # source://cucumber//lib/cucumber/cli/options.rb#176 + # source://cucumber//lib/cucumber/cli/options.rb#178 def filters; end - # source://cucumber//lib/cucumber/cli/options.rb#94 + # source://cucumber//lib/cucumber/cli/options.rb#95 def parse!(args); end - # source://cucumber//lib/cucumber/cli/options.rb#187 + # source://cucumber//lib/cucumber/cli/options.rb#189 def to_hash; end protected # Returns the value of attribute expanded_args. # - # source://cucumber//lib/cucumber/cli/options.rb#193 + # source://cucumber//lib/cucumber/cli/options.rb#195 def expanded_args; end # Returns the value of attribute options. # - # source://cucumber//lib/cucumber/cli/options.rb#193 + # source://cucumber//lib/cucumber/cli/options.rb#195 def options; end # Returns the value of attribute profiles. # - # source://cucumber//lib/cucumber/cli/options.rb#193 + # source://cucumber//lib/cucumber/cli/options.rb#195 def profiles; end private - # source://cucumber//lib/cucumber/cli/options.rb#403 + # source://cucumber//lib/cucumber/cli/options.rb#412 def add_option(option, value); end - # source://cucumber//lib/cucumber/cli/options.rb#435 - def add_profile(p); end + # source://cucumber//lib/cucumber/cli/options.rb#444 + def add_profile(profile); end - # source://cucumber//lib/cucumber/cli/options.rb#407 + # source://cucumber//lib/cucumber/cli/options.rb#416 def add_tag(value); end - # source://cucumber//lib/cucumber/cli/options.rb#421 + # source://cucumber//lib/cucumber/cli/options.rb#430 def add_tag_limit(tag_limits, tag_name, limit); end - # source://cucumber//lib/cucumber/cli/options.rb#415 + # source://cucumber//lib/cucumber/cli/options.rb#424 def add_tag_limits(value); end - # source://cucumber//lib/cucumber/cli/options.rb#358 + # source://cucumber//lib/cucumber/cli/options.rb#367 def banner; end - # source://cucumber//lib/cucumber/cli/options.rb#427 + # source://cucumber//lib/cucumber/cli/options.rb#436 def color(color); end - # source://cucumber//lib/cucumber/cli/options.rb#211 + # source://cucumber//lib/cucumber/cli/options.rb#213 def color_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#604 + # source://cucumber//lib/cucumber/cli/options.rb#603 def default_options; end # @return [Boolean] # - # source://cucumber//lib/cucumber/cli/options.rb#506 + # source://cucumber//lib/cucumber/cli/options.rb#504 def default_profile_should_be_used?; end - # source://cucumber//lib/cucumber/cli/options.rb#395 + # source://cucumber//lib/cucumber/cli/options.rb#404 def disable_profile_loading; end - # @return [Boolean] - # - # source://cucumber//lib/cucumber/cli/options.rb#477 - def disable_profile_loading?; end - - # source://cucumber//lib/cucumber/cli/options.rb#218 + # source://cucumber//lib/cucumber/cli/options.rb#220 def dry_run_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#222 + # source://cucumber//lib/cucumber/cli/options.rb#224 def exclude_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#448 + # source://cucumber//lib/cucumber/cli/options.rb#457 def exit_ok(text); end - # source://cucumber//lib/cucumber/cli/options.rb#468 + # source://cucumber//lib/cucumber/cli/options.rb#477 def extract_environment_variables; end - # source://cucumber//lib/cucumber/cli/options.rb#226 + # source://cucumber//lib/cucumber/cli/options.rb#228 def format_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#236 + # source://cucumber//lib/cucumber/cli/options.rb#238 def i18n_keywords_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#230 + # source://cucumber//lib/cucumber/cli/options.rb#232 def i18n_languages_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#554 + # source://cucumber//lib/cucumber/cli/options.rb#553 def indicate_invalid_language_and_exit(lang); end - # source://cucumber//lib/cucumber/cli/options.rb#243 + # source://cucumber//lib/cucumber/cli/options.rb#245 def init_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#431 + # source://cucumber//lib/cucumber/cli/options.rb#440 def initialize_project; end - # source://cucumber//lib/cucumber/cli/options.rb#387 + # source://cucumber//lib/cucumber/cli/options.rb#396 def language(lang); end - # source://cucumber//lib/cucumber/cli/options.rb#250 + # source://cucumber//lib/cucumber/cli/options.rb#252 def lines_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#559 + # source://cucumber//lib/cucumber/cli/options.rb#558 def list_keywords_and_exit(lang); end - # source://cucumber//lib/cucumber/cli/options.rb#585 + # source://cucumber//lib/cucumber/cli/options.rb#584 def list_languages_and_exit; end - # source://cucumber//lib/cucumber/cli/options.rb#481 + # source://cucumber//lib/cucumber/cli/options.rb#486 def merge_profiles; end - # source://cucumber//lib/cucumber/cli/options.rb#550 + # source://cucumber//lib/cucumber/cli/options.rb#549 def merge_tag_limits(option_limits, other_limits); end - # source://cucumber//lib/cucumber/cli/options.rb#496 + # source://cucumber//lib/cucumber/cli/options.rb#494 def merge_with_profile(profile); end - # source://cucumber//lib/cucumber/cli/options.rb#274 + # source://cucumber//lib/cucumber/cli/options.rb#283 def name_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#254 + # source://cucumber//lib/cucumber/cli/options.rb#256 def no_profile_short_flag_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#399 + # source://cucumber//lib/cucumber/cli/options.rb#408 def non_stdout_formats; end - # source://cucumber//lib/cucumber/cli/options.rb#323 + # source://cucumber//lib/cucumber/cli/options.rb#332 def out_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#295 - def out_stream(v); end + # source://cucumber//lib/cucumber/cli/options.rb#304 + def out_stream(value); end - # source://cucumber//lib/cucumber/cli/options.rb#289 - def parse_formats(v); end + # source://cucumber//lib/cucumber/cli/options.rb#298 + def parse_formats(value); end - # source://cucumber//lib/cucumber/cli/options.rb#198 + # source://cucumber//lib/cucumber/cli/options.rb#200 def process_publish_options; end - # source://cucumber//lib/cucumber/cli/options.rb#512 + # source://cucumber//lib/cucumber/cli/options.rb#510 def profile_loader; end - # source://cucumber//lib/cucumber/cli/options.rb#260 + # source://cucumber//lib/cucumber/cli/options.rb#262 def profile_short_flag_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#381 + # source://cucumber//lib/cucumber/cli/options.rb#390 def publisher; end - # source://cucumber//lib/cucumber/cli/options.rb#369 - def require_files(v); end + # source://cucumber//lib/cucumber/cli/options.rb#378 + def require_files(filenames); end - # source://cucumber//lib/cucumber/cli/options.rb#336 + # source://cucumber//lib/cucumber/cli/options.rb#345 def require_files_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#377 + # source://cucumber//lib/cucumber/cli/options.rb#386 def require_jars(jars); end - # source://cucumber//lib/cucumber/cli/options.rb#270 + # source://cucumber//lib/cucumber/cli/options.rb#272 def retry_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#516 + # source://cucumber//lib/cucumber/cli/options.rb#276 + def retry_total_msg; end + + # source://cucumber//lib/cucumber/cli/options.rb#514 def reverse_merge(other_options); end - # source://cucumber//lib/cucumber/cli/options.rb#443 + # source://cucumber//lib/cucumber/cli/options.rb#452 def set_dry_run_and_duration; end - # source://cucumber//lib/cucumber/cli/options.rb#439 + # source://cucumber//lib/cucumber/cli/options.rb#448 def set_option(option, value = T.unsafe(nil)); end - # source://cucumber//lib/cucumber/cli/options.rb#460 + # source://cucumber//lib/cucumber/cli/options.rb#469 def set_strict(setting, type = T.unsafe(nil)); end - # source://cucumber//lib/cucumber/cli/options.rb#453 + # source://cucumber//lib/cucumber/cli/options.rb#462 def shut_up; end - # source://cucumber//lib/cucumber/cli/options.rb#351 + # source://cucumber//lib/cucumber/cli/options.rb#360 def snippet_type_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#464 + # source://cucumber//lib/cucumber/cli/options.rb#473 def stdout_formats; end - # source://cucumber//lib/cucumber/cli/options.rb#282 + # source://cucumber//lib/cucumber/cli/options.rb#291 def strict_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#300 + # source://cucumber//lib/cucumber/cli/options.rb#309 def tags_msg; end - # source://cucumber//lib/cucumber/cli/options.rb#600 + # source://cucumber//lib/cucumber/cli/options.rb#599 def to_code_keywords_string(list); end - # source://cucumber//lib/cucumber/cli/options.rb#596 + # source://cucumber//lib/cucumber/cli/options.rb#595 def to_keywords_string(list); end # @return [Boolean] # - # source://cucumber//lib/cucumber/cli/options.rb#205 + # source://cucumber//lib/cucumber/cli/options.rb#207 def truthy_string?(str); end class << self - # source://cucumber//lib/cucumber/cli/options.rb#68 + # source://cucumber//lib/cucumber/cli/options.rb#69 def parse(args, out_stream, error_stream, options = T.unsafe(nil)); end end end @@ -496,10 +495,10 @@ Cucumber::Cli::Options::NO_PROFILE_LONG_FLAG = T.let(T.unsafe(nil), String) # source://cucumber//lib/cucumber/cli/options.rb#54 Cucumber::Cli::Options::NO_PROFILE_SHORT_FLAG = T.let(T.unsafe(nil), String) -# source://cucumber//lib/cucumber/cli/options.rb#59 +# source://cucumber//lib/cucumber/cli/options.rb#60 Cucumber::Cli::Options::OPTIONS_WITH_ARGS = T.let(T.unsafe(nil), Array) -# source://cucumber//lib/cucumber/cli/options.rb#65 +# source://cucumber//lib/cucumber/cli/options.rb#66 Cucumber::Cli::Options::ORDER_TYPES = T.let(T.unsafe(nil), Array) # source://cucumber//lib/cucumber/cli/options.rb#55 @@ -511,7 +510,10 @@ Cucumber::Cli::Options::PROFILE_SHORT_FLAG = T.let(T.unsafe(nil), String) # source://cucumber//lib/cucumber/cli/options.rb#58 Cucumber::Cli::Options::RETRY_FLAG = T.let(T.unsafe(nil), String) -# source://cucumber//lib/cucumber/cli/options.rb#66 +# source://cucumber//lib/cucumber/cli/options.rb#59 +Cucumber::Cli::Options::RETRY_TOTAL_FLAG = T.let(T.unsafe(nil), String) + +# source://cucumber//lib/cucumber/cli/options.rb#67 Cucumber::Cli::Options::TAG_LIMIT_MATCHER = T.let(T.unsafe(nil), Regexp) # source://cucumber//lib/cucumber/cli/profile_loader.rb#7 @@ -615,13 +617,13 @@ class Cucumber::Configuration # source://cucumber//lib/cucumber/configuration.rb#37 def initialize(user_options = T.unsafe(nil)); end - # source://cucumber//lib/cucumber/configuration.rb#189 + # source://cucumber//lib/cucumber/configuration.rb#193 def all_files_to_load; end - # source://cucumber//lib/cucumber/configuration.rb#129 + # source://cucumber//lib/cucumber/configuration.rb#133 def autoload_code_paths; end - # source://cucumber//lib/cucumber/configuration.rb#117 + # source://cucumber//lib/cucumber/configuration.rb#121 def custom_profiles; end # @return [Boolean] @@ -631,18 +633,18 @@ class Cucumber::Configuration # @return [Boolean] # - # source://cucumber//lib/cucumber/configuration.rb#101 + # source://cucumber//lib/cucumber/configuration.rb#105 def duration?; end # source://cucumber//lib/cucumber/configuration.rb#49 def error_stream; end - # source://cucumber//lib/cucumber/configuration.rb#248 + # source://cucumber//lib/cucumber/configuration.rb#252 def event_bus; end # @return [Boolean] # - # source://cucumber//lib/cucumber/configuration.rb#93 + # source://cucumber//lib/cucumber/configuration.rb#97 def expand?; end # @return [Boolean] @@ -650,33 +652,33 @@ class Cucumber::Configuration # source://cucumber//lib/cucumber/configuration.rb#73 def fail_fast?; end - # source://cucumber//lib/cucumber/configuration.rb#137 + # source://cucumber//lib/cucumber/configuration.rb#141 def feature_dirs; end - # source://cucumber//lib/cucumber/configuration.rb#159 + # source://cucumber//lib/cucumber/configuration.rb#163 def feature_files; end - # source://cucumber//lib/cucumber/configuration.rb#155 + # source://cucumber//lib/cucumber/configuration.rb#159 def filters; end - # source://cucumber//lib/cucumber/configuration.rb#125 + # source://cucumber//lib/cucumber/configuration.rb#129 def formats; end - # source://cucumber//lib/cucumber/configuration.rb#217 + # source://cucumber//lib/cucumber/configuration.rb#221 def formatter_class(format); end - # source://cucumber//lib/cucumber/configuration.rb#206 + # source://cucumber//lib/cucumber/configuration.rb#210 def formatter_factories; end # @return [Boolean] # - # source://cucumber//lib/cucumber/configuration.rb#81 + # source://cucumber//lib/cucumber/configuration.rb#85 def guess?; end - # source://cucumber//lib/cucumber/configuration.rb#252 + # source://cucumber//lib/cucumber/configuration.rb#256 def id_generator; end - # source://cucumber//lib/cucumber/configuration.rb#151 + # source://cucumber//lib/cucumber/configuration.rb#155 def name_regexps; end # @private @@ -698,10 +700,10 @@ class Cucumber::Configuration # source://cucumber//lib/cucumber/configuration.rb#45 def out_stream; end - # source://cucumber//lib/cucumber/configuration.rb#121 + # source://cucumber//lib/cucumber/configuration.rb#125 def paths; end - # source://cucumber//lib/cucumber/configuration.rb#113 + # source://cucumber//lib/cucumber/configuration.rb#117 def profiles; end # @return [Boolean] @@ -719,18 +721,21 @@ class Cucumber::Configuration # source://cucumber//lib/cucumber/configuration.rb#53 def randomize?; end - # source://cucumber//lib/cucumber/configuration.rb#243 + # source://cucumber//lib/cucumber/configuration.rb#247 def register_snippet_generator(generator); end # source://cucumber//lib/cucumber/configuration.rb#77 def retry_attempts; end + # source://cucumber//lib/cucumber/configuration.rb#81 + def retry_total_tests; end + # source://cucumber//lib/cucumber/configuration.rb#57 def seed; end # @return [Boolean] # - # source://cucumber//lib/cucumber/configuration.rb#109 + # source://cucumber//lib/cucumber/configuration.rb#113 def skip_profile_information?; end # An array of procs that can generate snippets for undefined steps. These procs may be called if a @@ -743,43 +748,43 @@ class Cucumber::Configuration # - multiline argument # - snippet type # - # source://cucumber//lib/cucumber/configuration.rb#239 + # source://cucumber//lib/cucumber/configuration.rb#243 def snippet_generators; end - # source://cucumber//lib/cucumber/configuration.rb#133 + # source://cucumber//lib/cucumber/configuration.rb#137 def snippet_type; end # @return [Boolean] # - # source://cucumber//lib/cucumber/configuration.rb#105 + # source://cucumber//lib/cucumber/configuration.rb#109 def snippets?; end # @return [Boolean] # - # source://cucumber//lib/cucumber/configuration.rb#97 + # source://cucumber//lib/cucumber/configuration.rb#101 def source?; end - # source://cucumber//lib/cucumber/configuration.rb#202 + # source://cucumber//lib/cucumber/configuration.rb#206 def step_defs_to_load; end - # source://cucumber//lib/cucumber/configuration.rb#85 + # source://cucumber//lib/cucumber/configuration.rb#89 def strict; end - # source://cucumber//lib/cucumber/configuration.rb#178 + # source://cucumber//lib/cucumber/configuration.rb#182 def support_to_load; end - # source://cucumber//lib/cucumber/configuration.rb#147 + # source://cucumber//lib/cucumber/configuration.rb#151 def tag_expressions; end - # source://cucumber//lib/cucumber/configuration.rb#143 + # source://cucumber//lib/cucumber/configuration.rb#147 def tag_limits; end - # source://cucumber//lib/cucumber/configuration.rb#225 + # source://cucumber//lib/cucumber/configuration.rb#229 def to_hash; end # @return [Boolean] # - # source://cucumber//lib/cucumber/configuration.rb#89 + # source://cucumber//lib/cucumber/configuration.rb#93 def wip?; end # source://cucumber//lib/cucumber/configuration.rb#41 @@ -787,19 +792,19 @@ class Cucumber::Configuration private - # source://cucumber//lib/cucumber/configuration.rb#280 + # source://cucumber//lib/cucumber/configuration.rb#285 def default_features_paths; end - # source://cucumber//lib/cucumber/configuration.rb#258 + # source://cucumber//lib/cucumber/configuration.rb#262 def default_options; end - # source://cucumber//lib/cucumber/configuration.rb#290 + # source://cucumber//lib/cucumber/configuration.rb#295 def remove_excluded_files_from(files); end - # source://cucumber//lib/cucumber/configuration.rb#294 + # source://cucumber//lib/cucumber/configuration.rb#299 def require_dirs; end - # source://cucumber//lib/cucumber/configuration.rb#284 + # source://cucumber//lib/cucumber/configuration.rb#289 def with_default_features_path(paths); end class << self @@ -824,49 +829,6 @@ module Cucumber::Constantize def constantize_name(constant, name); end end -# source://cucumber//lib/cucumber/deprecate.rb#7 -module Cucumber::Deprecate; end - -# source://cucumber//lib/cucumber/deprecate.rb#8 -class Cucumber::Deprecate::AnsiString - include ::Cucumber::Gherkin::Formatter::AnsiEscapes - - # source://cucumber//lib/cucumber/deprecate.rb#15 - def failure_message(message); end - - class << self - # source://cucumber//lib/cucumber/deprecate.rb#11 - def failure_message(message); end - end -end - -# source://cucumber//lib/cucumber/deprecate.rb#20 -class Cucumber::Deprecate::CliOption - class << self - # source://cucumber//lib/cucumber/deprecate.rb#21 - def deprecate(stream, option, message, remove_after_version); end - end -end - -# source://cucumber//lib/cucumber/deprecate.rb#43 -module Cucumber::Deprecate::ForDevelopers - class << self - # source://cucumber//lib/cucumber/deprecate.rb#44 - def call(_message, _method, remove_after_version); end - end -end - -# source://cucumber//lib/cucumber/deprecate.rb#33 -module Cucumber::Deprecate::ForUsers - class << self - # source://cucumber//lib/cucumber/deprecate.rb#34 - def call(message, method, remove_after_version); end - end -end - -# source://cucumber//lib/cucumber/deprecate.rb#49 -Cucumber::Deprecate::STRATEGY = Cucumber::Deprecate::ForUsers - # Events tell you what's happening while Cucumber runs your features. # # They're designed to be read-only, appropriate for writing formatters and other @@ -881,7 +843,7 @@ Cucumber::Deprecate::STRATEGY = Cucumber::Deprecate::ForUsers # end # end # -# source://cucumber//lib/cucumber/events/envelope.rb#4 +# source://cucumber//lib/cucumber/events/envelope.rb#6 module Cucumber::Events class << self # source://cucumber//lib/cucumber/events.rb#21 @@ -892,36 +854,36 @@ module Cucumber::Events end end -# source://cucumber//lib/cucumber/events/envelope.rb#5 +# source://cucumber//lib/cucumber/events/envelope.rb#7 class Cucumber::Events::Envelope < ::Cucumber::Core::Event # Returns the value of attribute envelope. # - # source://cucumber//lib/cucumber/events/envelope.rb#6 + # source://cucumber//lib/cucumber/events/envelope.rb#8 def envelope; end end # Fired after we've parsed the contents of a feature file # -# source://cucumber//lib/cucumber/events/gherkin_source_parsed.rb#6 +# source://cucumber//lib/cucumber/events/gherkin_source_parsed.rb#8 class Cucumber::Events::GherkinSourceParsed < ::Cucumber::Core::Event # The Gherkin Ast # - # source://cucumber//lib/cucumber/events/gherkin_source_parsed.rb#8 + # source://cucumber//lib/cucumber/events/gherkin_source_parsed.rb#10 def gherkin_document; end end # Fired after we've read in the contents of a feature file # -# source://cucumber//lib/cucumber/events/gherkin_source_read.rb#6 +# source://cucumber//lib/cucumber/events/gherkin_source_read.rb#8 class Cucumber::Events::GherkinSourceRead < ::Cucumber::Core::Event # The raw Gherkin source # - # source://cucumber//lib/cucumber/events/gherkin_source_read.rb#11 + # source://cucumber//lib/cucumber/events/gherkin_source_read.rb#13 def body; end # The path to the file # - # source://cucumber//lib/cucumber/events/gherkin_source_read.rb#8 + # source://cucumber//lib/cucumber/events/gherkin_source_read.rb#10 def path; end end @@ -988,16 +950,16 @@ end # Signals that a {Cucumber::Core::Test::Case} has finished executing # -# source://cucumber//lib/cucumber/events/test_case_finished.rb#6 +# source://cucumber//lib/cucumber/events/test_case_finished.rb#8 class Cucumber::Events::TestCaseFinished < ::Cucumber::Core::Events::TestCaseFinished # @return [Cucumber::Core::Test::Result] the result of running the {Cucumber::Core::Test::Case} # - # source://cucumber//lib/cucumber/events/test_case_finished.rb#11 + # source://cucumber//lib/cucumber/events/test_case_finished.rb#13 def result; end # @return [Cucumber::Core::Test::Case] that was executed # - # source://cucumber//lib/cucumber/events/test_case_finished.rb#8 + # source://cucumber//lib/cucumber/events/test_case_finished.rb#10 def test_case; end end @@ -1013,11 +975,11 @@ end # Signals that a {Cucumber::Core::Test::Case} is about to be executed # -# source://cucumber//lib/cucumber/events/test_case_started.rb#6 +# source://cucumber//lib/cucumber/events/test_case_started.rb#8 class Cucumber::Events::TestCaseStarted < ::Cucumber::Core::Events::TestCaseStarted # @return [Cucumber::Core::Test::Case] the test case to be executed # - # source://cucumber//lib/cucumber/events/test_case_started.rb#8 + # source://cucumber//lib/cucumber/events/test_case_started.rb#10 def test_case; end end @@ -1059,39 +1021,39 @@ end # Signals that a {Cucumber::Core::Test::Step} has finished executing # -# source://cucumber//lib/cucumber/events/test_step_finished.rb#6 +# source://cucumber//lib/cucumber/events/test_step_finished.rb#8 class Cucumber::Events::TestStepFinished < ::Cucumber::Core::Events::TestStepFinished # @return [Cucumber::Core::Test::Result] the result of running the {Cucumber::Core::Test::Step} # - # source://cucumber//lib/cucumber/events/test_step_finished.rb#11 + # source://cucumber//lib/cucumber/events/test_step_finished.rb#13 def result; end # @return [Cucumber::Core::Test::Step] the test step that was executed # - # source://cucumber//lib/cucumber/events/test_step_finished.rb#8 + # source://cucumber//lib/cucumber/events/test_step_finished.rb#10 def test_step; end end # Signals that a {Cucumber::Core::Test::Step} is about to be executed # -# source://cucumber//lib/cucumber/events/test_step_started.rb#6 +# source://cucumber//lib/cucumber/events/test_step_started.rb#8 class Cucumber::Events::TestStepStarted < ::Cucumber::Core::Events::TestStepStarted # @return [Cucumber::Core::Test::Step] the test step to be executed # - # source://cucumber//lib/cucumber/events/test_step_started.rb#8 + # source://cucumber//lib/cucumber/events/test_step_started.rb#10 def test_step; end end -# source://cucumber//lib/cucumber/events/undefined_parameter_type.rb#5 +# source://cucumber//lib/cucumber/events/undefined_parameter_type.rb#7 class Cucumber::Events::UndefinedParameterType < ::Cucumber::Core::Event # Returns the value of attribute expression. # - # source://cucumber//lib/cucumber/events/undefined_parameter_type.rb#6 + # source://cucumber//lib/cucumber/events/undefined_parameter_type.rb#8 def expression; end # Returns the value of attribute type_name. # - # source://cucumber//lib/cucumber/events/undefined_parameter_type.rb#6 + # source://cucumber//lib/cucumber/events/undefined_parameter_type.rb#8 def type_name; end end @@ -1351,17 +1313,22 @@ end # source://cucumber//lib/cucumber/filters/retry.rb#9 class Cucumber::Filters::Retry + # @return [Retry] a new instance of Retry + # # source://cucumber//lib/cucumber/filters/retry.rb#10 + def initialize(*_args); end + + # source://cucumber//lib/cucumber/filters/retry.rb#15 def test_case(test_case); end private # @return [Boolean] # - # source://cucumber//lib/cucumber/filters/retry.rb#23 + # source://cucumber//lib/cucumber/filters/retry.rb#28 def retry_required?(test_case, event); end - # source://cucumber//lib/cucumber/filters/retry.rb#27 + # source://cucumber//lib/cucumber/filters/retry.rb#46 def test_case_counts; end end @@ -1561,92 +1528,86 @@ module Cucumber::Formatter; end module Cucumber::Formatter::ANSIColor include ::Cucumber::Term::ANSIColor - # Apply the custom color scheme - # - # example: - # - # apply_custom_colors('passed=white') - # - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#89 - def apply_custom_colors(colors); end - - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def comment(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def comment_param(text = T.unsafe(nil), &proc); end - # :stopdoc: - # - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#121 - def cukes(n); end + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#114 + def cukes(amount); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def failed(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def failed_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def flaky(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def flaky_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#125 - def green_cukes(n); end + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#118 + def green_cukes(amount); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def outline(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def outline_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def passed(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def passed_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def pending(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def pending_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#129 - def red_cukes(n); end + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#122 + def red_cukes(amount); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def skipped(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def skipped_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def tag(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def tag_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#111 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#105 def undefined(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#115 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#109 def undefined_param(text = T.unsafe(nil), &proc); end - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#133 - def yellow_cukes(n); end + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#126 + def yellow_cukes(amount); end private - # source://cucumber//lib/cucumber/formatter/ansicolor.rb#140 + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#132 def apply_styles(styles, text = T.unsafe(nil), &proc); end + + class << self + # Apply the custom color scheme -> i.e. apply_custom_colors('passed=white') + # + # source://cucumber//lib/cucumber/formatter/ansicolor.rb#83 + def apply_custom_colors(colors); end + end end -# :stopdoc: -# -# source://cucumber//lib/cucumber/formatter/ansicolor.rb#67 +# source://cucumber//lib/cucumber/formatter/ansicolor.rb#66 Cucumber::Formatter::ANSIColor::ALIASES = T.let(T.unsafe(nil), Hash) # This module contains helper methods that are used by formatters that @@ -1669,120 +1630,122 @@ Cucumber::Formatter::ANSIColor::ALIASES = T.let(T.unsafe(nil), Hash) # During output, each line is processed by passing it to the formatter Proc # which returns the formatted (e.g. colored) string. # -# source://cucumber//lib/cucumber/formatter/console.rb#31 +# source://cucumber//lib/cucumber/formatter/console.rb#29 module Cucumber::Formatter::Console include ::Cucumber::Formatter::Duration extend ::Cucumber::Term::ANSIColor extend ::Cucumber::Formatter::ANSIColor - # source://cucumber//lib/cucumber/formatter/console.rb#174 - def attach(src, media_type); end + # source://cucumber//lib/cucumber/formatter/console.rb#172 + def attach(src, media_type, filename); end - # source://cucumber//lib/cucumber/formatter/console.rb#118 + # source://cucumber//lib/cucumber/formatter/console.rb#116 def collect_snippet_data(test_step, ast_lookup); end - # source://cucumber//lib/cucumber/formatter/console.rb#124 + # source://cucumber//lib/cucumber/formatter/console.rb#122 def collect_undefined_parameter_type_names(undefined_parameter_type); end - # source://cucumber//lib/cucumber/formatter/console.rb#165 + # source://cucumber//lib/cucumber/formatter/console.rb#163 def do_print_passing_wip(passed_messages); end - # source://cucumber//lib/cucumber/formatter/console.rb#189 + # source://cucumber//lib/cucumber/formatter/console.rb#192 def do_print_profile_information(profiles); end - # source://cucumber//lib/cucumber/formatter/console.rb#141 + # source://cucumber//lib/cucumber/formatter/console.rb#139 def do_print_snippets(snippet_text_proc); end - # source://cucumber//lib/cucumber/formatter/console.rb#199 + # source://cucumber//lib/cucumber/formatter/console.rb#202 def do_print_undefined_parameter_type_snippet(type_name); end - # source://cucumber//lib/cucumber/formatter/console.rb#102 - def exception_message_string(e, indent_amount); end + # source://cucumber//lib/cucumber/formatter/console.rb#100 + def exception_message_string(exception, indent_amount); end - # source://cucumber//lib/cucumber/formatter/console.rb#35 + # source://cucumber//lib/cucumber/formatter/console.rb#33 def format_step(keyword, step_match, status, source_indent); end - # source://cucumber//lib/cucumber/formatter/console.rb#48 - def format_string(o, status); end + # source://cucumber//lib/cucumber/formatter/console.rb#46 + def format_string(input, status); end - # source://cucumber//lib/cucumber/formatter/console.rb#217 + # source://cucumber//lib/cucumber/formatter/console.rb#220 def indent(string, padding); end # http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/10655 # - # source://cucumber//lib/cucumber/formatter/console.rb#110 + # source://cucumber//lib/cucumber/formatter/console.rb#108 def linebreaks(msg, max); end - # source://cucumber//lib/cucumber/formatter/console.rb#66 + # source://cucumber//lib/cucumber/formatter/console.rb#64 def print_element_messages(element_messages, status, kind); end - # source://cucumber//lib/cucumber/formatter/console.rb#59 + # source://cucumber//lib/cucumber/formatter/console.rb#57 def print_elements(elements, status, kind); end - # source://cucumber//lib/cucumber/formatter/console.rb#97 - def print_exception(e, status, indent); end + # source://cucumber//lib/cucumber/formatter/console.rb#95 + def print_exception(exception, status, indent); end - # source://cucumber//lib/cucumber/formatter/console.rb#154 + # source://cucumber//lib/cucumber/formatter/console.rb#152 def print_passing_wip(config, passed_test_cases, ast_lookup); end - # source://cucumber//lib/cucumber/formatter/console.rb#183 + # source://cucumber//lib/cucumber/formatter/console.rb#186 def print_profile_information; end - # source://cucumber//lib/cucumber/formatter/console.rb#128 + # source://cucumber//lib/cucumber/formatter/console.rb#126 def print_snippets(options); end - # source://cucumber//lib/cucumber/formatter/console.rb#80 + # source://cucumber//lib/cucumber/formatter/console.rb#78 def print_statistics(duration, config, counts, issues); end private - # source://cucumber//lib/cucumber/formatter/console.rb#237 + # source://cucumber//lib/cucumber/formatter/console.rb#240 def element_messages(elements, status); end - # source://cucumber//lib/cucumber/formatter/console.rb#229 + # source://cucumber//lib/cucumber/formatter/console.rb#232 def format_for(*keys); end - # source://cucumber//lib/cucumber/formatter/console.rb#247 + # source://cucumber//lib/cucumber/formatter/console.rb#250 def snippet_text(step_keyword, step_name, multiline_arg); end end -# source://cucumber//lib/cucumber/formatter/console.rb#227 +# source://cucumber//lib/cucumber/formatter/console.rb#230 Cucumber::Formatter::Console::FORMATS = T.let(T.unsafe(nil), Hash) -# source://cucumber//lib/cucumber/formatter/console.rb#254 +# source://cucumber//lib/cucumber/formatter/console.rb#257 class Cucumber::Formatter::Console::SnippetData # @return [SnippetData] a new instance of SnippetData # - # source://cucumber//lib/cucumber/formatter/console.rb#257 + # source://cucumber//lib/cucumber/formatter/console.rb#260 def initialize(actual_keyword, step); end # Returns the value of attribute actual_keyword. # - # source://cucumber//lib/cucumber/formatter/console.rb#255 + # source://cucumber//lib/cucumber/formatter/console.rb#258 def actual_keyword; end # Returns the value of attribute step. # - # source://cucumber//lib/cucumber/formatter/console.rb#255 + # source://cucumber//lib/cucumber/formatter/console.rb#258 def step; end end -# source://cucumber//lib/cucumber/formatter/http_io.rb#20 +# source://cucumber//lib/cucumber/formatter/curl_option_parser.rb#7 class Cucumber::Formatter::CurlOptionParser class << self # @raise [StandardError] # - # source://cucumber//lib/cucumber/formatter/http_io.rb#21 + # source://cucumber//lib/cucumber/formatter/curl_option_parser.rb#8 def parse(options); end # @raise [StandardError] # - # source://cucumber//lib/cucumber/formatter/http_io.rb#57 + # source://cucumber//lib/cucumber/formatter/curl_option_parser.rb#41 def parse_header(header_arg); end + # TODO: [LH] -> Switch below methods to private + # # @raise [StandardError] # - # source://cucumber//lib/cucumber/formatter/http_io.rb#51 + # source://cucumber//lib/cucumber/formatter/curl_option_parser.rb#35 def remove_arg_for(args, arg); end end end @@ -1831,68 +1794,71 @@ class Cucumber::Formatter::Fanout < ::BasicObject def respond_to_missing?(name, include_private = T.unsafe(nil)); end end -# source://cucumber//lib/cucumber/formatter/http_io.rb#7 +# source://cucumber//lib/cucumber/formatter/http_io.rb#10 class Cucumber::Formatter::HTTPIO class << self # Returns an IO that will write to a HTTP request's body # https_verify_mode can be set to OpenSSL::SSL::VERIFY_NONE # to ignore unsigned certificate - setting to nil will verify the certificate # - # source://cucumber//lib/cucumber/formatter/http_io.rb#12 + # source://cucumber//lib/cucumber/formatter/http_io.rb#14 def open(url, https_verify_mode = T.unsafe(nil), reporter = T.unsafe(nil)); end end end -# source://cucumber//lib/cucumber/formatter/http_io.rb#65 +# source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#5 class Cucumber::Formatter::IOHTTPBuffer # @return [IOHTTPBuffer] a new instance of IOHTTPBuffer # - # source://cucumber//lib/cucumber/formatter/http_io.rb#68 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#8 def initialize(uri, method, headers = T.unsafe(nil), https_verify_mode = T.unsafe(nil), reporter = T.unsafe(nil)); end # @raise [StandardError] # - # source://cucumber//lib/cucumber/formatter/http_io.rb#77 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#17 def close; end # @return [Boolean] # - # source://cucumber//lib/cucumber/formatter/http_io.rb#94 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#33 def closed?; end - # source://cucumber//lib/cucumber/formatter/http_io.rb#90 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#29 def flush; end # Returns the value of attribute headers. # - # source://cucumber//lib/cucumber/formatter/http_io.rb#66 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#6 def headers; end # Returns the value of attribute method. # - # source://cucumber//lib/cucumber/formatter/http_io.rb#66 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#6 def method; end # Returns the value of attribute uri. # - # source://cucumber//lib/cucumber/formatter/http_io.rb#66 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#6 def uri; end - # source://cucumber//lib/cucumber/formatter/http_io.rb#86 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#25 def write(data); end private - # source://cucumber//lib/cucumber/formatter/http_io.rb#142 - def build_client(uri, https_verify_mode); end + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#78 + def build_client(uri); end - # source://cucumber//lib/cucumber/formatter/http_io.rb#133 + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#69 def build_request(uri, method, headers); end + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#39 + def response; end + # @raise [StandardError] # - # source://cucumber//lib/cucumber/formatter/http_io.rb#100 - def send_content(uri, method, headers, attempt = T.unsafe(nil)); end + # source://cucumber//lib/cucumber/formatter/io_http_buffer.rb#43 + def send_content(uri, method, headers, attempts_remaining = T.unsafe(nil)); end end # source://cucumber//lib/cucumber/formatter/ignore_missing_messages.rb#5 @@ -1967,10 +1933,10 @@ module Cucumber::Formatter::Io::ClassMethods def new(*args, &block); end end -# source://cucumber//lib/cucumber/formatter/url_reporter.rb#13 +# source://cucumber//lib/cucumber/formatter/url_reporter.rb#15 class Cucumber::Formatter::NoReporter - # source://cucumber//lib/cucumber/formatter/url_reporter.rb#14 - def report(banner); end + # source://cucumber//lib/cucumber/formatter/url_reporter.rb#16 + def report(_banner); end end # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#7 @@ -1982,27 +1948,27 @@ class Cucumber::Formatter::PublishBannerPrinter # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#10 def initialize(configuration); end - # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#19 + # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#18 def display_publish_ad(io); end - # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#64 + # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#62 def highlight(text); end - # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#68 + # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#66 def link(text); end - # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#72 + # source://cucumber//lib/cucumber/formatter/publish_banner_printer.rb#70 def pre(text); end end -# source://cucumber//lib/cucumber/formatter/url_reporter.rb#3 +# source://cucumber//lib/cucumber/formatter/url_reporter.rb#5 class Cucumber::Formatter::URLReporter # @return [URLReporter] a new instance of URLReporter # - # source://cucumber//lib/cucumber/formatter/url_reporter.rb#4 + # source://cucumber//lib/cucumber/formatter/url_reporter.rb#6 def initialize(io); end - # source://cucumber//lib/cucumber/formatter/url_reporter.rb#8 + # source://cucumber//lib/cucumber/formatter/url_reporter.rb#10 def report(banner); end end @@ -2031,8 +1997,7 @@ module Cucumber::Gherkin::Formatter; end # Defines aliases for ANSI coloured output. Default colours can be overridden by defining # a GHERKIN_COLORS variable in your shell, very much like how you can -# tweak the familiar POSIX command ls with -# $LSCOLORS: http://linux-sxs.org/housekeeping/lscolors.html +# tweak the familiar POSIX command ls with $LSCOLORS: http://linux-sxs.org/housekeeping/lscolors.html # # The colours that you can change are: # @@ -2066,73 +2031,73 @@ module Cucumber::Gherkin::Formatter; end # # Although not listed, you can also use grey # -# source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#42 +# source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#41 module Cucumber::Gherkin::Formatter::AnsiEscapes - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def comments; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def comments_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def executing; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def executing_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def failed; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def failed_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def outline; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def outline_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def passed; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def passed_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def pending; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def pending_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#87 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#85 def reset; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def skipped; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def skipped_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def tag; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def tag_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#78 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#76 def undefined; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#82 + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#80 def undefined_arg; end - # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#91 - def up(n); end + # source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#89 + def up(amount); end end -# source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#56 +# source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#55 Cucumber::Gherkin::Formatter::AnsiEscapes::ALIASES = T.let(T.unsafe(nil), Hash) -# source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#43 +# source://cucumber//lib/cucumber/gherkin/formatter/ansi_escapes.rb#42 Cucumber::Gherkin::Formatter::AnsiEscapes::COLORS = T.let(T.unsafe(nil), Hash) # source://cucumber//lib/cucumber/gherkin/formatter/escaping.rb#6 @@ -2179,7 +2144,7 @@ end # source://cucumber//lib/cucumber/glue/registry_wrapper.rb#4 module Cucumber::Glue class << self - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#227 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#231 def backtrace_line(proc, name); end end end @@ -2363,6 +2328,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#117 def BeforeAll(name: T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Belgilangan(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Bet(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -2384,6 +2352,15 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def ButattheendofthedayIreckon(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Bæþsealf(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Bæþsealfa(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Bæþsealfe(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Cal(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -2399,6 +2376,15 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Cho(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Ciricæw(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Ciricæwa(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Ciricæwe(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Comehellorhighwater(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -2549,6 +2535,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def E(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Ed(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Eeldades(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3269,6 +3258,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def І(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Інакш(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def А(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3308,12 +3300,18 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Дадено(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Дадзена(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Дано(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Допустим(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Ды(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Если(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3341,6 +3339,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Када(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Калі(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Кога(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3371,6 +3372,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Но(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Няхай(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Нәтиҗәдә(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3389,9 +3393,15 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Та(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Тады(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def Также(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def Таксама(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def То(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3536,6 +3546,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def अगर(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def अनि(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def अनी(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3695,6 +3708,21 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def ಸ್ಥಿತಿಯನ್ನು(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def എപ്പോൾ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def ഒപ്പം(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def നൽകിയത്(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def പക്ഷേ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def പിന്നെ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def กำหนดให้(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3710,11 +3738,23 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def และ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def ასევე(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def და(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end # source://cucumber//lib/cucumber/glue/dsl.rb#142 - def მაგ­რამ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + def ვთქვათ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def თუ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def თუმცა(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def მაგრამ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end # source://cucumber//lib/cucumber/glue/dsl.rb#142 def მაშინ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3722,9 +3762,33 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def მოცემული(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def მოცემულია(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def როგორცკი(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def როდესაც(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def როცა(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def መቼ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def እና(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def ከዚያ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def የተሰጠ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def ግን(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def かつ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3740,6 +3804,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def もし(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def 且つ(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def 並且(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3776,6 +3843,9 @@ module Cucumber::Glue::Dsl # source://cucumber//lib/cucumber/glue/dsl.rb#142 def 当(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 + def 然し(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end + # source://cucumber//lib/cucumber/glue/dsl.rb#142 def 當(regexp, symbol = T.unsafe(nil), options = T.unsafe(nil), &proc); end @@ -3942,7 +4012,7 @@ class Cucumber::Glue::NilWorld < ::StandardError def initialize; end end -# Defines the basic API methods availlable in all Cucumber step definitions. +# Defines the basic API methods available in all Cucumber step definitions. # # You can, and probably should, extend this API with your own methods that # make sense in your domain. For more on that, see {Cucumber::Glue::Dsl#World} @@ -3957,17 +4027,19 @@ module Cucumber::Glue::ProtoWorld # Attach a file to the output # # @param file [string|io] the file to attach. - # It can be a string containing the file content itself, - # the file path, or an IO ready to be read. - # @param media_type [string] the media type. If file is a valid path, - # media_type can be ommitted, it will then be inferred from the file name. + # It can be a string containing the file content itself, the file path, or an IO ready to be read. + # @param media_type [string] the media type. + # If file is a valid path, media_type can be omitted, it will then be inferred from the file name. + # @param filename [string] the name of the file you wish to specify. + # This is only needed in situations where you want to rename a PDF download e.t.c. - In most situations + # you should not need to pass a filename # - # source://cucumber//lib/cucumber/glue/proto_world.rb#91 - def attach(file, media_type = T.unsafe(nil)); end + # source://cucumber//lib/cucumber/glue/proto_world.rb#93 + def attach(file, media_type = T.unsafe(nil), filename = T.unsafe(nil)); end # Prints the list of modules that are included in the World # - # source://cucumber//lib/cucumber/glue/proto_world.rb#120 + # source://cucumber//lib/cucumber/glue/proto_world.rb#119 def inspect; end # source://cucumber//lib/cucumber/glue/proto_world.rb#81 @@ -3975,16 +4047,14 @@ module Cucumber::Glue::ProtoWorld # Mark the matched step as pending. # - # @raise [Pending] - # - # source://cucumber//lib/cucumber/glue/proto_world.rb#103 + # source://cucumber//lib/cucumber/glue/proto_world.rb#105 def pending(message = T.unsafe(nil)); end # Skips this step and the remaining steps in the scenario # # @raise [Core::Test::Result::Skipped] # - # source://cucumber//lib/cucumber/glue/proto_world.rb#115 + # source://cucumber//lib/cucumber/glue/proto_world.rb#114 def skip_this_scenario(message = T.unsafe(nil)); end # Run a single Gherkin step @@ -4002,7 +4072,7 @@ module Cucumber::Glue::ProtoWorld # @example Passing a multiline string # step "the email should contain:", "Dear sir,\nYou've won a prize!\n" # @param name [String] The name of the step - # @param multiline_argument [String, Cucumber::Test::DocString, Cucumber::Ast::Table] + # @param raw_multiline_arg [String, Cucumber::Test::DocString, Cucumber::Ast::Table] # # source://cucumber//lib/cucumber/glue/proto_world.rb#30 def step(name, raw_multiline_arg = T.unsafe(nil)); end @@ -4052,113 +4122,111 @@ module Cucumber::Glue::ProtoWorld # see {#inspect} # - # source://cucumber//lib/cucumber/glue/proto_world.rb#125 + # source://cucumber//lib/cucumber/glue/proto_world.rb#124 def to_s; end class << self - # Dynamially generate the API module, closuring the dependencies + # Dynamically generate the API module, closuring the dependencies # - # source://cucumber//lib/cucumber/glue/proto_world.rb#130 + # source://cucumber//lib/cucumber/glue/proto_world.rb#129 def for(runtime, language); end end end -# @private -# -# source://cucumber//lib/cucumber/glue/proto_world.rb#212 +# source://cucumber//lib/cucumber/glue/proto_world.rb#207 Cucumber::Glue::ProtoWorld::AnsiEscapes = Cucumber::Gherkin::Formatter::AnsiEscapes # TODO: This class has too many responsibilities, split off # -# source://cucumber//lib/cucumber/glue/registry_and_more.rb#44 +# source://cucumber//lib/cucumber/glue/registry_and_more.rb#45 class Cucumber::Glue::RegistryAndMore # @return [RegistryAndMore] a new instance of RegistryAndMore # - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#56 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#57 def initialize(runtime, configuration); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#157 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#158 def add_hook(phase, hook); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#151 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#152 def after_all; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#174 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#175 def available_step_definition(regexp_source, file_colon_line); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#145 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#146 def before_all; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#127 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#128 def begin_scenario(test_case); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#100 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#101 def build_rb_world_factory(world_modules, namespaced_world_modules, proc); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#162 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#163 def clear_hooks; end # @raise [ArgumentError] # - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#182 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#183 def create_expression(string_or_regexp); end # Returns the value of attribute current_world. # - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#45 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#46 def current_world; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#81 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#82 def define_parameter_type(parameter_type); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#135 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#136 def end_scenario; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#166 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#167 def hooks_for(phase, scenario); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#139 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#140 def install_plugin(configuration, registry); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#178 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#179 def invoked_step_definition(regexp_source, file_colon_line); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#115 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#116 def load_code_file(code_file); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#75 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#76 def register_rb_hook(phase, tag_expressions, proc, name: T.unsafe(nil)); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#87 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#88 def register_rb_step_definition(string_or_regexp, proc_or_sym, options); end # Returns the value of attribute step_definitions. # - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#45 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#46 def step_definitions; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#67 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#68 def step_matches(name_to_match); end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#170 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#171 def unmatched_step_definitions; end private - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#214 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#218 def available_step_definition_hash; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#222 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#226 def hooks; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#218 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#222 def invoked_step_definition_hash; end - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#199 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#200 def parameter_type_envelope(parameter_type); end class << self - # source://cucumber//lib/cucumber/glue/registry_and_more.rb#189 + # source://cucumber//lib/cucumber/glue/registry_and_more.rb#190 def cli_snippet_type_options; end end end @@ -4233,7 +4301,7 @@ class Cucumber::Glue::Snippet::BaseSnippet # source://cucumber//lib/cucumber/glue/snippet.rb#50 def number_of_arguments; end - # source://cucumber//lib/cucumber/glue/snippet.rb#72 + # source://cucumber//lib/cucumber/glue/snippet.rb#73 def parameters; end # Returns the value of attribute pattern. @@ -4250,35 +4318,35 @@ class Cucumber::Glue::Snippet::BaseSnippet private - # source://cucumber//lib/cucumber/glue/snippet.rb#81 + # source://cucumber//lib/cucumber/glue/snippet.rb#82 def example(cucumber_expression_generator); end end end -# source://cucumber//lib/cucumber/glue/snippet.rb#127 +# source://cucumber//lib/cucumber/glue/snippet.rb#129 class Cucumber::Glue::Snippet::Classic < ::Cucumber::Glue::Snippet::BaseSnippet - # source://cucumber//lib/cucumber/glue/snippet.rb#128 + # source://cucumber//lib/cucumber/glue/snippet.rb#130 def typed_pattern; end class << self - # source://cucumber//lib/cucumber/glue/snippet.rb#132 + # source://cucumber//lib/cucumber/glue/snippet.rb#134 def description; end end end -# source://cucumber//lib/cucumber/glue/snippet.rb#87 +# source://cucumber//lib/cucumber/glue/snippet.rb#88 class Cucumber::Glue::Snippet::CucumberExpression < ::Cucumber::Glue::Snippet::BaseSnippet - # source://cucumber//lib/cucumber/glue/snippet.rb#106 + # source://cucumber//lib/cucumber/glue/snippet.rb#108 def parameters(expr); end - # source://cucumber//lib/cucumber/glue/snippet.rb#92 + # source://cucumber//lib/cucumber/glue/snippet.rb#93 def to_s; end - # source://cucumber//lib/cucumber/glue/snippet.rb#88 + # source://cucumber//lib/cucumber/glue/snippet.rb#89 def typed_pattern; end class << self - # source://cucumber//lib/cucumber/glue/snippet.rb#112 + # source://cucumber//lib/cucumber/glue/snippet.rb#114 def description; end end end @@ -4302,81 +4370,81 @@ class Cucumber::Glue::Snippet::Generator end end -# source://cucumber//lib/cucumber/glue/snippet.rb#154 +# source://cucumber//lib/cucumber/glue/snippet.rb#156 module Cucumber::Glue::Snippet::MultilineArgumentSnippet class << self - # source://cucumber//lib/cucumber/glue/snippet.rb#155 + # source://cucumber//lib/cucumber/glue/snippet.rb#157 def new(multiline_argument); end end end -# source://cucumber//lib/cucumber/glue/snippet.rb#161 +# source://cucumber//lib/cucumber/glue/snippet.rb#163 class Cucumber::Glue::Snippet::MultilineArgumentSnippet::Builder - # source://cucumber//lib/cucumber/glue/snippet.rb#166 + # source://cucumber//lib/cucumber/glue/snippet.rb#168 def data_table(table, *_args); end - # source://cucumber//lib/cucumber/glue/snippet.rb#162 + # source://cucumber//lib/cucumber/glue/snippet.rb#164 def doc_string(*_args); end - # source://cucumber//lib/cucumber/glue/snippet.rb#170 + # source://cucumber//lib/cucumber/glue/snippet.rb#172 def result; end end -# source://cucumber//lib/cucumber/glue/snippet.rb#183 +# source://cucumber//lib/cucumber/glue/snippet.rb#185 class Cucumber::Glue::Snippet::MultilineArgumentSnippet::DataTable # @return [DataTable] a new instance of DataTable # - # source://cucumber//lib/cucumber/glue/snippet.rb#184 + # source://cucumber//lib/cucumber/glue/snippet.rb#186 def initialize(table); end - # source://cucumber//lib/cucumber/glue/snippet.rb#188 + # source://cucumber//lib/cucumber/glue/snippet.rb#190 def append_block_parameter_to(array); end - # source://cucumber//lib/cucumber/glue/snippet.rb#192 + # source://cucumber//lib/cucumber/glue/snippet.rb#194 def append_comment_to(string); end end -# source://cucumber//lib/cucumber/glue/snippet.rb#175 +# source://cucumber//lib/cucumber/glue/snippet.rb#177 class Cucumber::Glue::Snippet::MultilineArgumentSnippet::DocString - # source://cucumber//lib/cucumber/glue/snippet.rb#176 + # source://cucumber//lib/cucumber/glue/snippet.rb#178 def append_block_parameter_to(array); end - # source://cucumber//lib/cucumber/glue/snippet.rb#180 + # source://cucumber//lib/cucumber/glue/snippet.rb#182 def append_comment_to(string); end end -# source://cucumber//lib/cucumber/glue/snippet.rb#197 +# source://cucumber//lib/cucumber/glue/snippet.rb#199 class Cucumber::Glue::Snippet::MultilineArgumentSnippet::None - # source://cucumber//lib/cucumber/glue/snippet.rb#198 + # source://cucumber//lib/cucumber/glue/snippet.rb#200 def append_block_parameter_to(array); end - # source://cucumber//lib/cucumber/glue/snippet.rb#200 + # source://cucumber//lib/cucumber/glue/snippet.rb#202 def append_comment_to(string); end end -# source://cucumber//lib/cucumber/glue/snippet.rb#137 +# source://cucumber//lib/cucumber/glue/snippet.rb#139 class Cucumber::Glue::Snippet::Percent < ::Cucumber::Glue::Snippet::BaseSnippet - # source://cucumber//lib/cucumber/glue/snippet.rb#138 + # source://cucumber//lib/cucumber/glue/snippet.rb#140 def typed_pattern; end class << self - # source://cucumber//lib/cucumber/glue/snippet.rb#142 + # source://cucumber//lib/cucumber/glue/snippet.rb#144 def description; end end end -# source://cucumber//lib/cucumber/glue/snippet.rb#117 +# source://cucumber//lib/cucumber/glue/snippet.rb#119 class Cucumber::Glue::Snippet::Regexp < ::Cucumber::Glue::Snippet::BaseSnippet - # source://cucumber//lib/cucumber/glue/snippet.rb#118 + # source://cucumber//lib/cucumber/glue/snippet.rb#120 def typed_pattern; end class << self - # source://cucumber//lib/cucumber/glue/snippet.rb#122 + # source://cucumber//lib/cucumber/glue/snippet.rb#124 def description; end end end -# source://cucumber//lib/cucumber/glue/snippet.rb#147 +# source://cucumber//lib/cucumber/glue/snippet.rb#149 Cucumber::Glue::Snippet::SNIPPET_TYPES = T.let(T.unsafe(nil), Hash) # A Step Definition holds a Regexp pattern and a Proc, and is @@ -4486,17 +4554,17 @@ class Cucumber::Glue::StepDefinition::MissingProc < ::StandardError def message; end end -# source://cucumber//lib/cucumber/glue/world_factory.rb#3 +# source://cucumber//lib/cucumber/glue/world_factory.rb#5 class Cucumber::Glue::WorldFactory # @return [WorldFactory] a new instance of WorldFactory # - # source://cucumber//lib/cucumber/glue/world_factory.rb#4 + # source://cucumber//lib/cucumber/glue/world_factory.rb#6 def initialize(proc); end - # source://cucumber//lib/cucumber/glue/world_factory.rb#8 + # source://cucumber//lib/cucumber/glue/world_factory.rb#10 def create_world; end - # source://cucumber//lib/cucumber/glue/world_factory.rb#12 + # source://cucumber//lib/cucumber/glue/world_factory.rb#14 def raise_nil_world; end end @@ -4608,13 +4676,7 @@ class Cucumber::Hooks::BeforeHook def to_s; end end -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#9 -Cucumber::IRONRUBY = T.let(T.unsafe(nil), FalseClass) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#8 -Cucumber::JRUBY = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber//lib/cucumber/platform.rb#12 +# source://cucumber//lib/cucumber/platform.rb#10 Cucumber::LIBDIR = T.let(T.unsafe(nil), String) # source://cucumber//lib/cucumber/load_path.rb#4 @@ -4630,7 +4692,7 @@ module Cucumber::LoadPath end end -# source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#2 +# source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#4 module Cucumber::MultilineArgument class << self # source://cucumber//lib/cucumber/multiline_argument.rb#14 @@ -4665,7 +4727,7 @@ end # # This will store [['a', 'b'], ['c', 'd']] in the data variable. # -# source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#3 +# source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#5 class Cucumber::MultilineArgument::DataTable # @param data [Core::Test::DataTable] the data for the table # @param conversion_procs [Hash] see map_column @@ -4997,64 +5059,64 @@ class Cucumber::MultilineArgument::DataTable::Builder def rows; end end -# source://cucumber//lib/cucumber/multiline_argument/data_table.rb#579 +# source://cucumber//lib/cucumber/multiline_argument/data_table.rb#578 class Cucumber::MultilineArgument::DataTable::Cell # @return [Cell] a new instance of Cell # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#583 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#582 def initialize(value, table, line); end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#593 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#592 def ==(other); end # @return [Boolean] # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#597 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#596 def eql?(other); end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#601 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#600 def hash; end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#589 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#588 def inspect!; end # Returns the value of attribute line. # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#580 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#579 def line; end # Returns the value of attribute status. # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#581 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#580 def status; end # Sets the attribute status # # @param value the value to set the attribute status to. # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#581 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#580 def status=(_arg0); end # Returns the value of attribute table. # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#580 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#579 def table; end # For testing only # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#606 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#605 def to_sexp; end # Returns the value of attribute value. # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#581 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#580 def value; end # Sets the attribute value # # @param value the value to set the attribute value to. # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#581 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#580 def value=(_arg0); end end @@ -5070,16 +5132,16 @@ class Cucumber::MultilineArgument::DataTable::Cells # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#525 def initialize(table, cells); end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#552 - def [](n); end + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#551 + def [](index); end # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#530 def accept(visitor); end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#560 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#559 def dom_id; end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#564 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#563 def each(&proc); end # Returns the value of attribute exception. @@ -5087,26 +5149,24 @@ class Cucumber::MultilineArgument::DataTable::Cells # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#523 def exception; end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#556 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#555 def line; end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#544 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#543 def to_hash; end - # For testing only - # - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#540 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#539 def to_sexp; end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#548 - def value(n); end + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#547 + def value(index); end private - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#570 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#569 def index; end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#574 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#573 def width; end end @@ -5146,127 +5206,127 @@ class Cucumber::MultilineArgument::DataTable::DataTablePrinter def prefixes; end end -# source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#4 +# source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#6 class Cucumber::MultilineArgument::DataTable::DiffMatrices # @return [DiffMatrices] a new instance of DiffMatrices # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#7 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#9 def initialize(cell_matrix, other_table_cell_matrix, options); end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#13 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#15 def call; end # Returns the value of attribute cell_matrix. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#5 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#7 def cell_matrix; end # Sets the attribute cell_matrix # # @param value the value to set the attribute cell_matrix to. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#5 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#7 def cell_matrix=(_arg0); end # Returns the value of attribute options. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#5 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#7 def options; end # Sets the attribute options # # @param value the value to set the attribute options to. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#5 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#7 def options=(_arg0); end # Returns the value of attribute other_table_cell_matrix. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#5 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#7 def other_table_cell_matrix; end # Sets the attribute other_table_cell_matrix # # @param value the value to set the attribute other_table_cell_matrix to. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#5 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#7 def other_table_cell_matrix=(_arg0); end private - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#95 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#97 def changes; end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#67 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#69 def ensure_2d(array); end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#111 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#113 def fill_in_missing_values; end # Returns the value of attribute insert_row_pos. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#22 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#24 def insert_row_pos; end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#101 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#103 def inspect_rows(missing_row, inserted_row); end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#61 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#63 def mark_as_missing(col); end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#132 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#134 def misplaced_col; end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#124 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#126 def missing_col; end # Returns the value of attribute missing_row_pos. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#22 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#24 def missing_row_pos; end # Returns the value of attribute original_header. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#22 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#24 def original_header; end # Returns the value of attribute original_width. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#22 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#24 def original_width; end # Pads two cell matrices to same column width and matches columns according to header value. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#33 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#35 def pad_and_match; end # Returns the value of attribute padded_width. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#22 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#24 def padded_width; end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#71 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#73 def perform_diff; end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#24 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#26 def prepare_diff; end # @raise [Different] # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#136 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#138 def raise_error; end # Returns the value of attribute row_indices. # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#22 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#24 def row_indices; end # @return [Boolean] # - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#142 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#144 def should_raise?; end - # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#128 + # source://cucumber//lib/cucumber/multiline_argument/data_table/diff_matrices.rb#130 def surplus_col; end end @@ -5286,15 +5346,15 @@ end # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#78 Cucumber::MultilineArgument::DataTable::NULL_CONVERSIONS = T.let(T.unsafe(nil), Hash) -# source://cucumber//lib/cucumber/multiline_argument/data_table.rb#611 +# source://cucumber//lib/cucumber/multiline_argument/data_table.rb#610 class Cucumber::MultilineArgument::DataTable::SurplusCell < ::Cucumber::MultilineArgument::DataTable::Cell - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#616 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#615 def ==(_other); end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#620 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#619 def hash; end - # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#612 + # source://cucumber//lib/cucumber/multiline_argument/data_table.rb#611 def status; end end @@ -5355,9 +5415,6 @@ class Cucumber::NoStepMatch def text_length; end end -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#11 -Cucumber::OS_X = T.let(T.unsafe(nil), T.untyped) - # Raised when a StepDefinition's block invokes World#pending # # source://cucumber//lib/cucumber/errors.rb#32 @@ -5388,19 +5445,7 @@ class Cucumber::ProjectInitializer def report_exists(file); end end -# source://cucumber//lib/cucumber/platform.rb#13 -Cucumber::RAILS = T.let(T.unsafe(nil), String) - -# source://cucumber//lib/cucumber/platform.rb#15 -Cucumber::RUBY = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#14 -Cucumber::RUBY_1_9 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#13 -Cucumber::RUBY_2_0 = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber//lib/cucumber/platform.rb#14 +# source://cucumber//lib/cucumber/platform.rb#11 Cucumber::RUBY_BINARY = T.let(T.unsafe(nil), String) # Represents the current status of a running test case. @@ -5458,7 +5503,7 @@ class Cucumber::RunningTestCase::TestCase < ::SimpleDelegator def with_result(result); end end -# source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#5 +# source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#7 class Cucumber::Runtime include ::Cucumber::Core include ::Cucumber::Formatter::Duration @@ -5609,16 +5654,15 @@ end # This is what a programming language will consider to be a runtime. # -# It's a thin class that directs the handul of methods needed by the -# programming languages to the right place. +# It's a thin class that directs the handful of methods needed by the programming languages to the right place # -# source://cucumber//lib/cucumber/runtime/for_programming_languages.rb#12 +# source://cucumber//lib/cucumber/runtime/for_programming_languages.rb#11 class Cucumber::Runtime::ForProgrammingLanguages extend ::Forwardable # @return [ForProgrammingLanguages] a new instance of ForProgrammingLanguages # - # source://cucumber//lib/cucumber/runtime/for_programming_languages.rb#17 + # source://cucumber//lib/cucumber/runtime/for_programming_languages.rb#16 def initialize(support_code, user_interface); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -5647,18 +5691,18 @@ class Cucumber::Runtime::ForProgrammingLanguages # Returns the value of attribute support_code. # - # source://cucumber//lib/cucumber/runtime/for_programming_languages.rb#15 + # source://cucumber//lib/cucumber/runtime/for_programming_languages.rb#14 def support_code; end end -# Builder to instanciate a Cucumber::Messages::Meta message filled-in with +# Builder to instantiate a Cucumber::Messages::Meta message filled-in with # the runtime meta-data: # - protocol version: the version of the Cucumber::Messages protocol # - implementation: the name and version of the implementation (e.g. cucumber-ruby 8.0.0) # - runtime: the name and version of the runtime (e.g. ruby 3.0.1) # - os: the name and version of the operating system (e.g. linux 3.13.0-45-generic) # - cpu: the name of the CPU (e.g. x86_64) -# - ci: informtion about the CI environment if any, including: +# - ci: information about the CI environment if any, including: # - name: the name of the CI environment (e.g. Jenkins) # - url: the URL of the CI environment (e.g. https://ci.example.com) # - build_number: the build number of the CI environment (e.g. 123) @@ -5668,7 +5712,7 @@ end # - branch: the name of the git branch (e.g. main) # - tag: the name of the git tag (e.g. v1.0.0) # -# source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#22 +# source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#24 class Cucumber::Runtime::MetaMessageBuilder class << self # Builds a Cucumber::Messages::Meta filled-in with the runtime meta-data @@ -5681,30 +5725,30 @@ class Cucumber::Runtime::MetaMessageBuilder # @return [Cucumber::Messages::Meta] the meta message # @see Cucumber::Runtime::MetaMessageBuilder # - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#37 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#39 def build_meta_message(env = T.unsafe(nil)); end private - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#81 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#83 def ci(env); end - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#75 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#77 def cpu; end - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#93 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#95 def git_info(ci_data); end - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#54 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#56 def implementation; end - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#68 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#70 def os; end - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#50 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#52 def protocol_version; end - # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#61 + # source://cucumber//lib/cucumber/runtime/meta_message_builder.rb#63 def runtime; end end end @@ -5870,7 +5914,7 @@ module Cucumber::Runtime::UserInterface # The embedded data may or may not be ignored, depending on what kind of formatter(s) are active. # # source://cucumber//lib/cucumber/runtime/user_interface.rb#44 - def attach(src, media_type); end + def attach(src, media_type, filename); end # Sets the attribute visitor # @@ -6040,11 +6084,11 @@ class Cucumber::StepMatchSearch::CachesStepMatch < ::SimpleDelegator def call(step_name); end end -# source://cucumber//lib/cucumber/errors.rb#47 +# source://cucumber//lib/cucumber/errors.rb#48 class Cucumber::TagExcess < ::StandardError # @return [TagExcess] a new instance of TagExcess # - # source://cucumber//lib/cucumber/errors.rb#48 + # source://cucumber//lib/cucumber/errors.rb#49 def initialize(messages); end end @@ -6226,34 +6270,34 @@ Cucumber::Term::ANSIColor::ATTRIBUTE_NAMES = T.let(T.unsafe(nil), Array) # source://cucumber//lib/cucumber/term/ansicolor.rb#66 Cucumber::Term::ANSIColor::COLORED_REGEXP = T.let(T.unsafe(nil), Regexp) -# source://cucumber//lib/cucumber/term/banner.rb#5 +# source://cucumber//lib/cucumber/term/banner.rb#7 module Cucumber::Term::Banner - # source://cucumber//lib/cucumber/term/banner.rb#6 + # source://cucumber//lib/cucumber/term/banner.rb#8 def display_banner(lines, io, border_modifiers = T.unsafe(nil)); end end -# source://cucumber//lib/cucumber/term/banner.rb#10 +# source://cucumber//lib/cucumber/term/banner.rb#12 class Cucumber::Term::Banner::BannerMaker include ::Cucumber::Term::ANSIColor - # source://cucumber//lib/cucumber/term/banner.rb#13 + # source://cucumber//lib/cucumber/term/banner.rb#15 def display_banner(lines, io, border_modifiers); end private - # source://cucumber//lib/cucumber/term/banner.rb#37 + # source://cucumber//lib/cucumber/term/banner.rb#39 def apply_modifiers(str, modifiers); end - # source://cucumber//lib/cucumber/term/banner.rb#27 + # source://cucumber//lib/cucumber/term/banner.rb#29 def display_line(line); end - # source://cucumber//lib/cucumber/term/banner.rb#31 + # source://cucumber//lib/cucumber/term/banner.rb#33 def display_span(span); end - # source://cucumber//lib/cucumber/term/banner.rb#43 + # source://cucumber//lib/cucumber/term/banner.rb#45 def line_length(line); end - # source://cucumber//lib/cucumber/term/banner.rb#51 + # source://cucumber//lib/cucumber/term/banner.rb#53 def span_length(span); end end @@ -6281,11 +6325,5 @@ class Cucumber::UndefinedDynamicStep < ::StandardError def initialize(step_name); end end -# source://cucumber//lib/cucumber/platform.rb#10 +# source://cucumber//lib/cucumber/platform.rb#8 Cucumber::VERSION = T.let(T.unsafe(nil), String) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#10 -Cucumber::WINDOWS = T.let(T.unsafe(nil), T.untyped) - -# source://cucumber-core/11.0.0/lib/cucumber/core/platform.rb#12 -Cucumber::WINDOWS_MRI = T.let(T.unsafe(nil), T.untyped) diff --git a/sorbet/rbi/gems/dante@0.2.0.rbi b/sorbet/rbi/gems/dante@0.2.0.rbi index 9899f2551..42e1af644 100644 --- a/sorbet/rbi/gems/dante@0.2.0.rbi +++ b/sorbet/rbi/gems/dante@0.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `dante` gem. # Please instead update this file by running `bin/tapioca gem dante`. + # Dante.run("process-name") do # begin # # ...something here diff --git a/sorbet/rbi/gems/database_cleaner-active_record@2.1.0.rbi b/sorbet/rbi/gems/database_cleaner-active_record@2.2.0.rbi similarity index 86% rename from sorbet/rbi/gems/database_cleaner-active_record@2.1.0.rbi rename to sorbet/rbi/gems/database_cleaner-active_record@2.2.0.rbi index 1d50ea5f4..0c2813187 100644 --- a/sorbet/rbi/gems/database_cleaner-active_record@2.1.0.rbi +++ b/sorbet/rbi/gems/database_cleaner-active_record@2.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `database_cleaner-active_record` gem. # Please instead update this file by running `bin/tapioca gem database_cleaner-active_record`. + # source://database_cleaner-active_record//lib/database_cleaner/active_record/version.rb#1 module DatabaseCleaner class << self @@ -70,46 +71,46 @@ end # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#16 class DatabaseCleaner::ActiveRecord::Base < ::DatabaseCleaner::Strategy - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#39 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#41 def connection_class; end # Returns the value of attribute connection_hash. # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#37 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#39 def connection_hash; end # Sets the attribute connection_hash # # @param value the value to set the attribute connection_hash to. # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#37 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#39 def connection_hash=(_arg0); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#32 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#34 def db=(*_arg0); end private - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#69 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#71 def active_record_config_hash_for(db); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#91 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#93 def database_for(model); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#86 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#88 def establish_connection; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#51 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#53 def load_config; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#77 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#79 def lookup_from_connection_pool; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#63 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#65 def valid_config(connection_file, db); end class << self - # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#25 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#27 def exclusion_condition(column_name); end # source://database_cleaner-active_record//lib/database_cleaner/active_record/base.rb#17 @@ -117,46 +118,46 @@ class DatabaseCleaner::ActiveRecord::Base < ::DatabaseCleaner::Strategy end end -# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#61 +# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#67 class DatabaseCleaner::ActiveRecord::ConnectionWrapper < ::SimpleDelegator # @return [ConnectionWrapper] a new instance of ConnectionWrapper # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#62 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#68 def initialize(connection); end end -# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#77 +# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#83 module DatabaseCleaner::ActiveRecord::ConnectionWrapper::AbstractAdapter - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#84 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#90 def database_cleaner_table_cache; end # used to be called views but that can clash with gems like schema_plus # this gem is not meant to be exposing such an extra interface any way # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#80 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#86 def database_cleaner_view_cache; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#89 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#95 def database_tables; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#93 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#99 def truncate_table(table_name); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#99 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#105 def truncate_tables(tables); end end -# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#104 +# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#110 module DatabaseCleaner::ActiveRecord::ConnectionWrapper::AbstractMysqlAdapter - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#109 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#115 def pre_count_tables(tables); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#105 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#111 def pre_count_truncate_tables(tables); end private - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#119 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#125 def auto_increment_value(table); end # This method tells us if the given table has been inserted into since its @@ -166,33 +167,33 @@ module DatabaseCleaner::ActiveRecord::ConnectionWrapper::AbstractMysqlAdapter # # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#132 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#138 def has_been_used?(table); end # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#136 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#142 def has_rows?(table); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#115 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#121 def row_count(table); end end -# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#185 +# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#191 module DatabaseCleaner::ActiveRecord::ConnectionWrapper::PostgreSQLAdapter - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#203 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#209 def database_cleaner_table_cache; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#186 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#192 def database_tables; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#199 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#205 def pre_count_tables(tables); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#195 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#201 def pre_count_truncate_tables(tables); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#190 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#196 def truncate_tables(table_names); end private @@ -204,55 +205,55 @@ module DatabaseCleaner::ActiveRecord::ConnectionWrapper::PostgreSQLAdapter # # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#218 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#224 def has_been_used?(table); end # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#229 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#235 def has_rows?(table); end # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#225 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#231 def has_sequence?(table); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#233 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#239 def tables_with_schema; end end -# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#141 +# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#147 module DatabaseCleaner::ActiveRecord::ConnectionWrapper::SQLiteAdapter - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#157 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#163 def pre_count_tables(tables); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#153 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#159 def pre_count_truncate_tables(tables); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#142 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#148 def truncate_table(table_name); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#149 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#155 def truncate_tables(tables); end private - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#164 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#170 def fetch_sequences; end # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#170 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#176 def has_been_used?(table, sequences); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#175 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#181 def row_count(table); end # Returns a boolean indicating if the SQLite database is using the sqlite_sequence table. # # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#180 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#186 def uses_sequence?; end end @@ -263,10 +264,10 @@ class DatabaseCleaner::ActiveRecord::Deletion < ::DatabaseCleaner::ActiveRecord: private - # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#53 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#67 def build_table_stats_query(connection); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#25 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#26 def delete_table(connection, table_name); end # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#19 @@ -274,33 +275,36 @@ class DatabaseCleaner::ActiveRecord::Deletion < ::DatabaseCleaner::ActiveRecord: # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#66 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#80 def information_schema_exists?(connection); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#47 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#30 + def reset_id_sequence(connection, table_name); end + + # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#61 def table_stats_query(connection); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#29 - def tables_to_truncate(connection); end + # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#43 + def tables_to_clean(connection); end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#38 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/deletion.rb#52 def tables_with_new_rows(connection); end end # source://database_cleaner-active_record//lib/database_cleaner/active_record/transaction.rb#5 class DatabaseCleaner::ActiveRecord::Transaction < ::DatabaseCleaner::ActiveRecord::Base - # source://database_cleaner-active_record//lib/database_cleaner/active_record/transaction.rb#14 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/transaction.rb#20 def clean; end # source://database_cleaner-active_record//lib/database_cleaner/active_record/transaction.rb#6 def start; end end -# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#7 +# source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#6 class DatabaseCleaner::ActiveRecord::Truncation < ::DatabaseCleaner::ActiveRecord::Base # @return [Truncation] a new instance of Truncation # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#8 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#7 def initialize(opts = T.unsafe(nil)); end # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#20 @@ -310,26 +314,23 @@ class DatabaseCleaner::ActiveRecord::Truncation < ::DatabaseCleaner::ActiveRecor # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#52 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#58 def cache_tables?; end # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#32 def connection; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#45 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#51 def migration_storage_names; end # @return [Boolean] # - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#56 + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#62 def pre_count?; end - # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#36 - def tables_to_truncate(connection); end + # source://database_cleaner-active_record//lib/database_cleaner/active_record/truncation.rb#42 + def tables_to_clean(connection); end end # source://database_cleaner-active_record//lib/database_cleaner/active_record/version.rb#3 DatabaseCleaner::ActiveRecord::VERSION = T.let(T.unsafe(nil), String) - -# source://database_cleaner-core/2.0.1/lib/database_cleaner/version.rb#2 -DatabaseCleaner::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/database_cleaner-core@2.0.1.rbi b/sorbet/rbi/gems/database_cleaner-core@2.0.1.rbi index 49fa93992..9e91a6531 100644 --- a/sorbet/rbi/gems/database_cleaner-core@2.0.1.rbi +++ b/sorbet/rbi/gems/database_cleaner-core@2.0.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `database_cleaner-core` gem. # Please instead update this file by running `bin/tapioca gem database_cleaner-core`. + # Abstract strategy class for orm adapter gems to subclass # # source://database_cleaner-core//lib/database_cleaner/version.rb#1 diff --git a/sorbet/rbi/gems/database_cleaner@2.0.2.rbi b/sorbet/rbi/gems/database_cleaner@2.0.2.rbi index 6c794966d..6d5c6e4a9 100644 --- a/sorbet/rbi/gems/database_cleaner@2.0.2.rbi +++ b/sorbet/rbi/gems/database_cleaner@2.0.2.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `database_cleaner` gem. # Please instead update this file by running `bin/tapioca gem database_cleaner`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/date@3.3.3.rbi b/sorbet/rbi/gems/date@3.3.4.rbi similarity index 82% rename from sorbet/rbi/gems/date@3.3.3.rbi rename to sorbet/rbi/gems/date@3.3.4.rbi index 88f88094b..8da235219 100644 --- a/sorbet/rbi/gems/date@3.3.3.rbi +++ b/sorbet/rbi/gems/date@3.3.4.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `date` gem. # Please instead update this file by running `bin/tapioca gem date`. + class Date include ::Comparable @@ -18,9 +19,6 @@ class Date def infinite?; end end -# source://activesupport/7.0.5/lib/active_support/core_ext/date/conversions.rb#9 -Date::DATE_FORMATS = T.let(T.unsafe(nil), Hash) - class Date::Infinity < ::Numeric # @return [Infinity] a new instance of Infinity # @@ -71,8 +69,5 @@ class Date::Infinity < ::Numeric def d; end end -# source://activesupport/7.0.5/lib/active_support/core_ext/date/deprecated_conversions.rb#6 -Date::NOT_SET = T.let(T.unsafe(nil), Object) - # source://date//date.rb#7 Date::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/debug_inspector@1.1.0.rbi b/sorbet/rbi/gems/debug_inspector@1.2.0.rbi similarity index 61% rename from sorbet/rbi/gems/debug_inspector@1.1.0.rbi rename to sorbet/rbi/gems/debug_inspector@1.2.0.rbi index 038b54345..d4e06545e 100644 --- a/sorbet/rbi/gems/debug_inspector@1.1.0.rbi +++ b/sorbet/rbi/gems/debug_inspector@1.2.0.rbi @@ -4,8 +4,9 @@ # This is an autogenerated file for types exported from the `debug_inspector` gem. # Please instead update this file by running `bin/tapioca gem debug_inspector`. -# source://debug_inspector//lib/rubyvm/debug_inspector/version.rb#1 -class RubyVM::DebugInspector + +# source://debug_inspector//lib/debug_inspector/version.rb#1 +class DebugInspector def backtrace_locations; end def frame_binding(_arg0); end def frame_class(_arg0); end @@ -19,5 +20,8 @@ end # Don't forget to update the version string in the gemspec file. # -# source://debug_inspector//lib/rubyvm/debug_inspector/version.rb#3 -RubyVM::DebugInspector::VERSION = T.let(T.unsafe(nil), String) +# source://debug_inspector//lib/debug_inspector/version.rb#3 +DebugInspector::VERSION = T.let(T.unsafe(nil), String) + +# source://debug_inspector//lib/debug_inspector.rb#20 +RubyVM::DebugInspector = DebugInspector diff --git a/sorbet/rbi/gems/delorean@2.1.0.rbi b/sorbet/rbi/gems/delorean@2.1.0.rbi index 2c19258e8..ea9249a4b 100644 --- a/sorbet/rbi/gems/delorean@2.1.0.rbi +++ b/sorbet/rbi/gems/delorean@2.1.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `delorean` gem. # Please instead update this file by running `bin/tapioca gem delorean`. + # source://delorean//lib/flux_capacitor.rb#1 module Delorean include ::Delorean::FluxCapacitor diff --git a/sorbet/rbi/gems/devise@4.9.2.rbi b/sorbet/rbi/gems/devise@4.9.4.rbi similarity index 93% rename from sorbet/rbi/gems/devise@4.9.2.rbi rename to sorbet/rbi/gems/devise@4.9.4.rbi index 67d2d3df2..4470c0648 100644 --- a/sorbet/rbi/gems/devise@4.9.2.rbi +++ b/sorbet/rbi/gems/devise@4.9.4.rbi @@ -4,15 +4,13 @@ # This is an autogenerated file for types exported from the `devise` gem. # Please instead update this file by running `bin/tapioca gem devise`. + # source://devise//lib/devise/rails/routes.rb#28 module ActionDispatch::Routing; end -# source://actionpack/7.0.5/lib/action_dispatch/routing.rb#258 -ActionDispatch::Routing::HTTP_METHODS = T.let(T.unsafe(nil), Array) - # source://devise//lib/devise/rails/routes.rb#35 class ActionDispatch::Routing::Mapper - # source://actionpack/7.0.5/lib/action_dispatch/routing/mapper.rb#2302 + # source://actionpack/7.2.0/lib/action_dispatch/routing/mapper.rb#2348 def initialize(set); end # Sets the devise scope to be used in the controller. If you have custom routes, @@ -350,205 +348,202 @@ class ActionDispatch::Routing::Mapper def with_devise_exclusive_scope(new_path, new_as, options); end class << self - # source://actionpack/7.0.5/lib/action_dispatch/routing/mapper.rb#381 + # source://actionpack/7.2.0/lib/action_dispatch/routing/mapper.rb#27 + def backtrace_cleaner; end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/mapper.rb#27 + def backtrace_cleaner=(val); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/mapper.rb#429 def normalize_name(name); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/mapper.rb#364 + # source://actionpack/7.2.0/lib/action_dispatch/routing/mapper.rb#414 def normalize_path(path); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/mapper.rb#26 + def route_source_locations; end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/mapper.rb#26 + def route_source_locations=(val); end end end -# source://actionpack/7.0.5/lib/action_dispatch/routing/mapper.rb#13 -ActionDispatch::Routing::Mapper::URL_OPTIONS = T.let(T.unsafe(nil), Array) - # source://devise//lib/devise/rails/routes.rb#29 class ActionDispatch::Routing::RouteSet include ::Devise::RouteSet - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#366 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#384 def initialize(config = T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#615 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#664 def add_polymorphic_mapping(klass, options, &block); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#584 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#633 def add_route(mapping, name); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#619 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#668 def add_url_helper(name, options, &block); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#395 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#415 def api_only?; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#415 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#454 def append(&block); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#849 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#893 def call(env); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#439 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#478 def clear!; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#428 + def default_env; end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def default_scope; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def default_scope=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#356 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#356 def default_url_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#461 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#499 def define_mounted_helper(name, script_namer = T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#355 def disable_clear_and_finalize; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#355 def disable_clear_and_finalize=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#408 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#447 def draw(&block); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#356 def draw_paths; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#338 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#356 def draw_paths=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#385 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#404 def eager_load!; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#580 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#629 def empty?; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#339 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#357 def env_key; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#760 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#808 def extra_keys(options, recall = T.unsafe(nil)); end # source://devise//lib/devise/rails/routes.rb#8 def finalize!; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#792 - def find_relative_url_root(options); end - - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#788 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#836 def find_script_name(options); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def formatter; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def formatter=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#764 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#29 + def from_requirements(requirements); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#812 def generate_extras(options, recall = T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#488 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#526 def generate_url_helpers(supports_path); end def inspect; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#457 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#495 def mounted_helpers; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def named_routes; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def named_routes=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#784 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#832 def optimize_routes_generation?; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#796 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#840 def path_for(options, route_name = T.unsafe(nil), reserved = T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#339 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#357 def polymorphic_mappings; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#419 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#458 def prepend(&block); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#855 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#899 def recognize_path(path, environment = T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#870 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#914 def recognize_path_with_request(req, path, extras, raise_on_missing: T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#391 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#411 def relative_url_root; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#399 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#419 def request_class; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#355 def resources_path_names; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#337 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#355 def resources_path_names=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def router; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def router=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def routes; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def set; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#336 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#354 def set=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#801 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#845 def url_for(options, route_name = T.unsafe(nil), url_strategy = T.unsafe(nil), method_name = T.unsafe(nil), reserved = T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#480 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#518 def url_helpers(supports_path = T.unsafe(nil)); end private - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#423 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#462 def eval_block(block); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#775 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#823 def generate(route_name, options, recall = T.unsafe(nil), method_name = T.unsafe(nil)); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#403 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#423 def make_request(env); end class << self - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#343 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#361 def default_resources_path_names; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#347 + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#365 def new_with_config(config); end end end -# source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#364 -ActionDispatch::Routing::RouteSet::DEFAULT_CONFIG = T.let(T.unsafe(nil), ActionDispatch::Routing::RouteSet::Config) - -# source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#333 -ActionDispatch::Routing::RouteSet::PATH = T.let(T.unsafe(nil), Proc) - -# source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#780 -ActionDispatch::Routing::RouteSet::RESERVED_OPTIONS = T.let(T.unsafe(nil), Array) - -# source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#334 -ActionDispatch::Routing::RouteSet::UNKNOWN = T.let(T.unsafe(nil), Proc) - -# source://actionpack/7.0.5/lib/action_dispatch/routing.rb#257 -ActionDispatch::Routing::SEPARATORS = T.let(T.unsafe(nil), Array) - # source://devise//lib/devise.rb#11 module Devise # source://devise//lib/devise.rb#138 @@ -875,7 +870,7 @@ module Devise class << self # @return [Boolean] # - # source://devise//lib/devise.rb#524 + # source://devise//lib/devise.rb#528 def activerecord51?; end # Small method that adds a mapping to Devise. @@ -962,6 +957,9 @@ module Devise # source://devise//lib/devise.rb#209 def default_scope=(val); end + # source://devise//lib/devise.rb#524 + def deprecator; end + # source://devise//lib/devise.rb#117 def email_regexp; end @@ -1360,7 +1358,7 @@ module Devise::Controllers::Helpers # end # end # - # source://devise//lib/devise/controllers/helpers.rb#215 + # source://devise//lib/devise/controllers/helpers.rb#217 def after_sign_in_path_for(resource_or_scope); end # Method used by sessions controller to sign out a user. You can overwrite @@ -1370,12 +1368,12 @@ module Devise::Controllers::Helpers # # By default it is the root_path. # - # source://devise//lib/devise/controllers/helpers.rb#225 + # source://devise//lib/devise/controllers/helpers.rb#227 def after_sign_out_path_for(resource_or_scope); end # Tell warden that params authentication is allowed for that specific page. # - # source://devise//lib/devise/controllers/helpers.rb#163 + # source://devise//lib/devise/controllers/helpers.rb#165 def allow_params_authentication!; end # Return true if it's a devise_controller. false to all controllers unless @@ -1386,20 +1384,20 @@ module Devise::Controllers::Helpers # # @return [Boolean] # - # source://devise//lib/devise/controllers/helpers.rb#151 + # source://devise//lib/devise/controllers/helpers.rb#153 def devise_controller?; end # Set up a param sanitizer to filter parameters using strong_parameters. See # lib/devise/parameter_sanitizer.rb for more info. Override this # method in your application controller to use your own parameter sanitizer. # - # source://devise//lib/devise/controllers/helpers.rb#158 + # source://devise//lib/devise/controllers/helpers.rb#160 def devise_parameter_sanitizer; end # Overwrite Rails' handle unverified request to sign out all scopes, # clear run strategies and remove cached variables. # - # source://devise//lib/devise/controllers/helpers.rb#254 + # source://devise//lib/devise/controllers/helpers.rb#256 def handle_unverified_request; end # Check if flash messages should be emitted. Default is to do it on @@ -1407,44 +1405,44 @@ module Devise::Controllers::Helpers # # @return [Boolean] # - # source://devise//lib/devise/controllers/helpers.rb#270 + # source://devise//lib/devise/controllers/helpers.rb#272 def is_flashing_format?; end # @return [Boolean] # - # source://devise//lib/devise/controllers/helpers.rb#264 + # source://devise//lib/devise/controllers/helpers.rb#266 def is_navigational_format?; end - # source://devise//lib/devise/controllers/helpers.rb#260 + # source://devise//lib/devise/controllers/helpers.rb#262 def request_format; end # Sign in a user and tries to redirect first to the stored location and # then to the url specified by after_sign_in_path_for. It accepts the same # parameters as the sign_in method. # - # source://devise//lib/devise/controllers/helpers.rb#235 + # source://devise//lib/devise/controllers/helpers.rb#237 def sign_in_and_redirect(resource_or_scope, *args); end # Sign out a user and tries to redirect to the url specified by # after_sign_out_path_for. # - # source://devise//lib/devise/controllers/helpers.rb#245 + # source://devise//lib/devise/controllers/helpers.rb#247 def sign_out_and_redirect(resource_or_scope); end # The scope root url to be used when they're signed in. By default, it first # tries to find a resource_root_path, otherwise it uses the root_path. # - # source://devise//lib/devise/controllers/helpers.rb#169 + # source://devise//lib/devise/controllers/helpers.rb#171 def signed_in_root_path(resource_or_scope); end # The main accessor for the warden proxy instance # - # source://devise//lib/devise/controllers/helpers.rb#142 + # source://devise//lib/devise/controllers/helpers.rb#144 def warden; end private - # source://devise//lib/devise/controllers/helpers.rb#276 + # source://devise//lib/devise/controllers/helpers.rb#278 def expire_data_after_sign_out!; end class << self @@ -1472,7 +1470,7 @@ module Devise::Controllers::Helpers # before_action :authenticate_user! # Tell devise to use :user map # before_action :authenticate_admin! # Tell devise to use :admin map # - # source://devise//lib/devise/controllers/helpers.rb#112 + # source://devise//lib/devise/controllers/helpers.rb#113 def define_helpers(mapping); end end end @@ -1503,7 +1501,7 @@ module Devise::Controllers::Helpers::ClassMethods # source://devise//lib/devise/controllers/helpers.rb#39 def devise_group(group_name, opts = T.unsafe(nil)); end - # source://devise//lib/devise/controllers/helpers.rb#82 + # source://devise//lib/devise/controllers/helpers.rb#83 def log_process_action(payload); end end @@ -1557,10 +1555,10 @@ class Devise::Controllers::Responder < ::ActionController::Responder # and/or responders. It won't allow configuring a custom response, but it allows Devise # to use these methods and defaults across the implementation more easily. # - # source://responders/3.1.0/lib/action_controller/responder.rb#123 + # source://responders/3.1.1/lib/action_controller/responder.rb#123 def error_status; end - # source://responders/3.1.0/lib/action_controller/responder.rb#124 + # source://responders/3.1.1/lib/action_controller/responder.rb#124 def redirect_status; end end end @@ -1852,7 +1850,12 @@ module Devise::Encryptor end # source://devise//lib/devise/rails.rb#7 -class Devise::Engine < ::Rails::Engine; end +class Devise::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # Failure application that will be called every time :warden is thrown from # any strategy or hook. It is responsible for redirecting the user to the sign @@ -1870,47 +1873,69 @@ class Devise::FailureApp < ::ActionController::Metal include ::ActionController::Redirecting include ::ActionDispatch::Routing::RouteSet::MountedHelpers include ::Devise::Controllers::StoreLocation + include ::ActiveSupport::Callbacks + include ::AbstractController::Callbacks extend ::AbstractController::UrlFor::ClassMethods + extend ::ActiveSupport::Callbacks::ClassMethods + extend ::AbstractController::Callbacks::ClassMethods + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _process_action_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_process_action_callbacks(&block); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end # source://devise//lib/devise/failure_app.rb#19 def flash(*_arg0, **_arg1, &_arg2); end - # source://devise//lib/devise/failure_app.rb#47 + # source://devise//lib/devise/failure_app.rb#52 def http_auth; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://devise//lib/devise/failure_app.rb#54 + # source://devise//lib/devise/failure_app.rb#59 def recall; end - # source://devise//lib/devise/failure_app.rb#81 + # source://devise//lib/devise/failure_app.rb#86 def redirect; end - # source://devise//lib/devise/failure_app.rb#37 + # source://devise//lib/devise/failure_app.rb#42 def respond; end protected - # source://devise//lib/devise/failure_app.rb#238 + # source://devise//lib/devise/failure_app.rb#247 def attempted_path; end # Choose whether we should respond in an HTTP authentication fashion, @@ -1924,10 +1949,10 @@ class Devise::FailureApp < ::ActionController::Metal # # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#185 + # source://devise//lib/devise/failure_app.rb#194 def http_auth?; end - # source://devise//lib/devise/failure_app.rb#199 + # source://devise//lib/devise/failure_app.rb#208 def http_auth_body; end # It doesn't make sense to send authenticate headers in AJAX requests @@ -1935,13 +1960,16 @@ class Devise::FailureApp < ::ActionController::Metal # # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#195 + # source://devise//lib/devise/failure_app.rb#204 def http_auth_header?; end - # source://devise//lib/devise/failure_app.rb#100 + # source://devise//lib/devise/failure_app.rb#124 + def i18n_locale; end + + # source://devise//lib/devise/failure_app.rb#105 def i18n_message(default = T.unsafe(nil)); end - # source://devise//lib/devise/failure_app.rb#96 + # source://devise//lib/devise/failure_app.rb#101 def i18n_options(options); end # Check if flash messages should be emitted. Default is to do it on @@ -1949,46 +1977,46 @@ class Devise::FailureApp < ::ActionController::Metal # # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#256 + # source://devise//lib/devise/failure_app.rb#265 def is_flashing_format?; end # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#250 + # source://devise//lib/devise/failure_app.rb#259 def is_navigational_format?; end - # source://devise//lib/devise/failure_app.rb#211 + # source://devise//lib/devise/failure_app.rb#220 def recall_app(app); end - # source://devise//lib/devise/failure_app.rb#119 + # source://devise//lib/devise/failure_app.rb#128 def redirect_url; end - # source://devise//lib/devise/failure_app.rb#264 + # source://devise//lib/devise/failure_app.rb#273 def relative_url_root; end # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#272 + # source://devise//lib/devise/failure_app.rb#281 def relative_url_root?; end - # source://devise//lib/devise/failure_app.rb#260 + # source://devise//lib/devise/failure_app.rb#269 def request_format; end - # source://devise//lib/devise/failure_app.rb#135 + # source://devise//lib/devise/failure_app.rb#144 def route(scope); end - # source://devise//lib/devise/failure_app.rb#230 + # source://devise//lib/devise/failure_app.rb#239 def scope; end - # source://devise//lib/devise/failure_app.rb#234 + # source://devise//lib/devise/failure_app.rb#243 def scope_class; end - # source://devise//lib/devise/failure_app.rb#139 + # source://devise//lib/devise/failure_app.rb#148 def scope_url; end # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#173 + # source://devise//lib/devise/failure_app.rb#182 def skip_format?; end # Stores requested URI to redirect the user after signing in. We can't use @@ -1996,63 +2024,84 @@ class Devise::FailureApp < ::ActionController::Metal # authenticated yet, but we still need to store the URI based on scope, so # different scopes would never use the same URI to redirect. # - # source://devise//lib/devise/failure_app.rb#246 + # source://devise//lib/devise/failure_app.rb#255 def store_location!; end - # source://devise//lib/devise/failure_app.rb#218 + # source://devise//lib/devise/failure_app.rb#227 def warden; end - # source://devise//lib/devise/failure_app.rb#226 + # source://devise//lib/devise/failure_app.rb#235 def warden_message; end - # source://devise//lib/devise/failure_app.rb#222 + # source://devise//lib/devise/failure_app.rb#231 def warden_options; end private # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#284 + # source://devise//lib/devise/failure_app.rb#293 def rails_51_and_up?; end # @return [Boolean] # - # source://devise//lib/devise/failure_app.rb#280 + # source://devise//lib/devise/failure_app.rb#289 def root_path_defined?(context); end class << self - # source://actionpack/7.0.5/lib/action_dispatch/routing/route_set.rb#564 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _process_action_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _process_action_callbacks=(value); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/route_set.rb#600 def _routes; end - # source://devise//lib/devise/failure_app.rb#21 + # source://devise//lib/devise/failure_app.rb#26 def call(env); end # Try retrieving the URL options from the parent controller (usually # ApplicationController). Instance methods are not supported at the moment, # so only the class-level attribute is used. # - # source://devise//lib/devise/failure_app.rb#29 + # source://devise//lib/devise/failure_app.rb#34 def default_url_options(*args); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end end end @@ -2112,7 +2161,7 @@ class Devise::Mailer < ::ActionMailer::Base private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end end @@ -2355,11 +2404,11 @@ class Devise::Mapping end end -# source://devise//lib/devise/controllers/helpers.rb#283 +# source://devise//lib/devise/controllers/helpers.rb#285 class Devise::MissingWarden < ::StandardError # @return [MissingWarden] a new instance of MissingWarden # - # source://devise//lib/devise/controllers/helpers.rb#284 + # source://devise//lib/devise/controllers/helpers.rb#286 def initialize; end end diff --git a/sorbet/rbi/gems/diff-lcs@1.5.0.rbi b/sorbet/rbi/gems/diff-lcs@1.5.1.rbi similarity index 91% rename from sorbet/rbi/gems/diff-lcs@1.5.0.rbi rename to sorbet/rbi/gems/diff-lcs@1.5.1.rbi index 4e1f79154..aa5aa3c28 100644 --- a/sorbet/rbi/gems/diff-lcs@1.5.0.rbi +++ b/sorbet/rbi/gems/diff-lcs@1.5.1.rbi @@ -4,9 +4,57 @@ # This is an autogenerated file for types exported from the `diff-lcs` gem. # Please instead update this file by running `bin/tapioca gem diff-lcs`. + # source://diff-lcs//lib/diff/lcs.rb#3 module Diff; end +# == How Diff Works (by Mark-Jason Dominus) +# +# I once read an article written by the authors of +diff+; they said that they +# hard worked very hard on the algorithm until they found the right one. +# +# I think what they ended up using (and I hope someone will correct me, because +# I am not very confident about this) was the `longest common subsequence' +# method. In the LCS problem, you have two sequences of items: +# +# a b c d f g h j q z +# a b c d e f g i j k r x y z +# +# and you want to find the longest sequence of items that is present in both +# original sequences in the same order. That is, you want to find a new +# sequence *S* which can be obtained from the first sequence by deleting some +# items, and from the second sequence by deleting other items. You also want +# *S* to be as long as possible. In this case *S* is: +# +# a b c d f g j z +# +# From there it's only a small step to get diff-like output: +# +# e h i k q r x y +# + - + + - + + + +# +# This module solves the LCS problem. It also includes a canned function to +# generate +diff+-like output. +# +# It might seem from the example above that the LCS of two sequences is always +# pretty obvious, but that's not always the case, especially when the two +# sequences have many repeated elements. For example, consider +# +# a x b y c z p d q +# a b c a x b y c z +# +# A naive approach might start by matching up the +a+ and +b+ that appear at +# the beginning of each sequence, like this: +# +# a x b y c z p d q +# a b c a b y c z +# +# This finds the common subsequence +a b c z+. But actually, the LCS is +a x b +# y c z+: +# +# a x b y c z p d q +# a b c a x b y c z +# # source://diff-lcs//lib/diff/lcs.rb#51 module Diff::LCS # Returns the difference set between +self+ and +other+. See Diff::LCS#diff. @@ -91,7 +139,7 @@ module Diff::LCS def unpatch_me(patchset); end class << self - # :yields seq1[i] for each matched: + # :yields: seq1[i] for each matched # # source://diff-lcs//lib/diff/lcs.rb#144 def LCS(seq1, seq2, &block); end @@ -112,7 +160,7 @@ module Diff::LCS # source://diff-lcs//lib/diff/lcs.rb#168 def diff(seq1, seq2, callbacks = T.unsafe(nil), &block); end - # :yields seq1[i] for each matched: + # :yields: seq1[i] for each matched # # source://diff-lcs//lib/diff/lcs.rb#144 def lcs(seq1, seq2, &block); end @@ -158,13 +206,13 @@ module Diff::LCS # representations of those objects. Prior to application, array # representations of Diff::LCS::Change objects will be reified. # - # source://diff-lcs//lib/diff/lcs.rb#624 + # source://diff-lcs//lib/diff/lcs.rb#626 def patch(src, patchset, direction = T.unsafe(nil)); end # Given a set of patchset, convert the current version to the next version. # Does no auto-discovery. # - # source://diff-lcs//lib/diff/lcs.rb#734 + # source://diff-lcs//lib/diff/lcs.rb#736 def patch!(src, patchset); end # #sdiff computes all necessary components to show two sequences and their @@ -372,7 +420,7 @@ module Diff::LCS # Given a set of patchset, convert the current version to the prior version. # Does no auto-discovery. # - # source://diff-lcs//lib/diff/lcs.rb#728 + # source://diff-lcs//lib/diff/lcs.rb#730 def unpatch!(src, patchset); end private @@ -649,15 +697,15 @@ end # require 'pp' # pp diffs.map { |e| e.map { |f| f.to_a } } # -# source://diff-lcs//lib/diff/lcs/callbacks.rb#223 +# source://diff-lcs//lib/diff/lcs/callbacks.rb#225 class Diff::LCS::ContextDiffCallbacks < ::Diff::LCS::DiffCallbacks - # source://diff-lcs//lib/diff/lcs/callbacks.rb#232 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#234 def change(event); end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#224 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#226 def discard_a(event); end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#228 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#230 def discard_b(event); end end @@ -749,38 +797,38 @@ end # require 'pp' # pp diffs.map { |e| e.map { |f| f.to_a } } # -# source://diff-lcs//lib/diff/lcs/callbacks.rb#106 +# source://diff-lcs//lib/diff/lcs/callbacks.rb#108 class Diff::LCS::DiffCallbacks - # :yields self: + # :yields: self # # @return [DiffCallbacks] a new instance of DiffCallbacks # - # source://diff-lcs//lib/diff/lcs/callbacks.rb#110 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#112 def initialize; end # Returns the difference set collected during the diff process. # - # source://diff-lcs//lib/diff/lcs/callbacks.rb#108 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#110 def diffs; end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#133 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#135 def discard_a(event); end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#137 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#139 def discard_b(event); end # Finalizes the diff process. If an unprocessed hunk still exists, then it # is appended to the diff list. # - # source://diff-lcs//lib/diff/lcs/callbacks.rb#125 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#127 def finish; end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#129 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#131 def match(_event); end private - # source://diff-lcs//lib/diff/lcs/callbacks.rb#141 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#143 def finish_hunk; end end @@ -800,48 +848,48 @@ class Diff::LCS::Hunk # Returns the value of attribute blocks. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#63 + # source://diff-lcs//lib/diff/lcs/hunk.rb#62 def blocks; end # Returns a diff string based on a format. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#116 + # source://diff-lcs//lib/diff/lcs/hunk.rb#115 def diff(format, last = T.unsafe(nil)); end # Returns the value of attribute end_new. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#65 + # source://diff-lcs//lib/diff/lcs/hunk.rb#64 def end_new; end # Returns the value of attribute end_old. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#65 + # source://diff-lcs//lib/diff/lcs/hunk.rb#64 def end_old; end # Returns the value of attribute file_length_difference. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#66 + # source://diff-lcs//lib/diff/lcs/hunk.rb#65 def file_length_difference; end # Change the "start" and "end" fields to note that context should be added # to this hunk. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#70 + # source://diff-lcs//lib/diff/lcs/hunk.rb#69 def flag_context; end - # source://diff-lcs//lib/diff/lcs/hunk.rb#72 + # source://diff-lcs//lib/diff/lcs/hunk.rb#71 def flag_context=(context); end # Merges this hunk and the provided hunk together if they overlap. Returns # a truthy value so that if there is no overlap, you can know the merge # was skipped. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#98 + # source://diff-lcs//lib/diff/lcs/hunk.rb#97 def merge(hunk); end # @return [Boolean] # - # source://diff-lcs//lib/diff/lcs/hunk.rb#326 + # source://diff-lcs//lib/diff/lcs/hunk.rb#331 def missing_last_newline?(data); end # Determines whether there is an overlap between this hunk and the @@ -850,60 +898,60 @@ class Diff::LCS::Hunk # # @return [Boolean] # - # source://diff-lcs//lib/diff/lcs/hunk.rb#110 + # source://diff-lcs//lib/diff/lcs/hunk.rb#109 def overlaps?(hunk); end # Returns the value of attribute start_new. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#64 + # source://diff-lcs//lib/diff/lcs/hunk.rb#63 def start_new; end # Returns the value of attribute start_old. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#64 + # source://diff-lcs//lib/diff/lcs/hunk.rb#63 def start_old; end # Merges this hunk and the provided hunk together if they overlap. Returns # a truthy value so that if there is no overlap, you can know the merge # was skipped. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#98 + # source://diff-lcs//lib/diff/lcs/hunk.rb#97 def unshift(hunk); end private - # source://diff-lcs//lib/diff/lcs/hunk.rb#213 + # source://diff-lcs//lib/diff/lcs/hunk.rb#214 def context_diff(last = T.unsafe(nil)); end # Generate a range of item numbers to print. Only print 1 number if the # range has only one item in it. Otherwise, it's 'start,end' # - # source://diff-lcs//lib/diff/lcs/hunk.rb#293 + # source://diff-lcs//lib/diff/lcs/hunk.rb#298 def context_range(mode, op, last = T.unsafe(nil)); end - # source://diff-lcs//lib/diff/lcs/hunk.rb#271 + # source://diff-lcs//lib/diff/lcs/hunk.rb#276 def ed_diff(format, _last = T.unsafe(nil)); end - # source://diff-lcs//lib/diff/lcs/hunk.rb#339 + # source://diff-lcs//lib/diff/lcs/hunk.rb#344 def encode(literal, target_encoding = T.unsafe(nil)); end - # source://diff-lcs//lib/diff/lcs/hunk.rb#343 + # source://diff-lcs//lib/diff/lcs/hunk.rb#348 def encode_as(string, *args); end # Note that an old diff can't have any context. Therefore, we know that # there's only one block in the hunk. # - # source://diff-lcs//lib/diff/lcs/hunk.rb#135 + # source://diff-lcs//lib/diff/lcs/hunk.rb#134 def old_diff(_last = T.unsafe(nil)); end - # source://diff-lcs//lib/diff/lcs/hunk.rb#160 + # source://diff-lcs//lib/diff/lcs/hunk.rb#159 def unified_diff(last = T.unsafe(nil)); end # Generate a range of item numbers to print for unified diff. Print number # where block starts, followed by number of lines in the block # (don't print number of lines if it's 1) # - # source://diff-lcs//lib/diff/lcs/hunk.rb#311 + # source://diff-lcs//lib/diff/lcs/hunk.rb#316 def unified_range(mode, last); end end @@ -1042,32 +1090,32 @@ end # require 'pp' # pp diffs.map { |e| e.to_a } # -# source://diff-lcs//lib/diff/lcs/callbacks.rb#301 +# source://diff-lcs//lib/diff/lcs/callbacks.rb#303 class Diff::LCS::SDiffCallbacks - # :yields self: + # :yields: self # # @return [SDiffCallbacks] a new instance of SDiffCallbacks # @yield [_self] # @yieldparam _self [Diff::LCS::SDiffCallbacks] the object that the method was called on # - # source://diff-lcs//lib/diff/lcs/callbacks.rb#305 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#307 def initialize; end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#322 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#324 def change(event); end # Returns the difference set collected during the diff process. # - # source://diff-lcs//lib/diff/lcs/callbacks.rb#303 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#305 def diffs; end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#314 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#316 def discard_a(event); end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#318 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#320 def discard_b(event); end - # source://diff-lcs//lib/diff/lcs/callbacks.rb#310 + # source://diff-lcs//lib/diff/lcs/callbacks.rb#312 def match(event); end end diff --git a/sorbet/rbi/gems/docile@1.4.0.rbi b/sorbet/rbi/gems/docile@1.4.1.rbi similarity index 99% rename from sorbet/rbi/gems/docile@1.4.0.rbi rename to sorbet/rbi/gems/docile@1.4.1.rbi index bdc59407e..091d1b113 100644 --- a/sorbet/rbi/gems/docile@1.4.0.rbi +++ b/sorbet/rbi/gems/docile@1.4.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `docile` gem. # Please instead update this file by running `bin/tapioca gem docile`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/domain_name@0.5.20190701.rbi b/sorbet/rbi/gems/domain_name@0.6.20240107.rbi similarity index 81% rename from sorbet/rbi/gems/domain_name@0.5.20190701.rbi rename to sorbet/rbi/gems/domain_name@0.6.20240107.rbi index aef1384cc..017cf7672 100644 --- a/sorbet/rbi/gems/domain_name@0.5.20190701.rbi +++ b/sorbet/rbi/gems/domain_name@0.6.20240107.rbi @@ -4,17 +4,6 @@ # This is an autogenerated file for types exported from the `domain_name` gem. # Please instead update this file by running `bin/tapioca gem domain_name`. -# source://american_date/1.2.0/lib/american_date.rb#16 -::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) - -# source://ruby-openid/2.9.2/lib/openid/fetchers.rb#13 -::MAX_RESPONSE_KB = T.let(T.unsafe(nil), Integer) - -# source://yard/0.9.34/lib/yard.rb#61 -::RUBY18 = T.let(T.unsafe(nil), FalseClass) - -# source://yard/0.9.34/lib/yard.rb#62 -::RUBY19 = T.let(T.unsafe(nil), TrueClass) # Represents a domain name ready for extracting its registered domain # and TLD. @@ -26,25 +15,25 @@ class DomainName # # @return [DomainName] a new instance of DomainName # - # source://domain_name//lib/domain_name.rb#78 + # source://domain_name//lib/domain_name.rb#77 def initialize(hostname); end - # source://domain_name//lib/domain_name.rb#195 + # source://domain_name//lib/domain_name.rb#194 def <(other); end - # source://domain_name//lib/domain_name.rb#217 + # source://domain_name//lib/domain_name.rb#216 def <=(other); end - # source://domain_name//lib/domain_name.rb#179 + # source://domain_name//lib/domain_name.rb#178 def <=>(other); end - # source://domain_name//lib/domain_name.rb#174 + # source://domain_name//lib/domain_name.rb#173 def ==(other); end - # source://domain_name//lib/domain_name.rb#206 + # source://domain_name//lib/domain_name.rb#205 def >(other); end - # source://domain_name//lib/domain_name.rb#228 + # source://domain_name//lib/domain_name.rb#227 def >=(other); end # Returns true if this domain name has a canonical registered @@ -52,14 +41,14 @@ class DomainName # # @return [Boolean] # - # source://domain_name//lib/domain_name.rb#70 + # source://domain_name//lib/domain_name.rb#69 def canonical?; end # Returns true if this domain name has a canonical TLD. # # @return [Boolean] # - # source://domain_name//lib/domain_name.rb#64 + # source://domain_name//lib/domain_name.rb#63 def canonical_tld?; end # Checks if the server represented by this domain is qualified to @@ -70,7 +59,7 @@ class DomainName # # @return [Boolean] # - # source://domain_name//lib/domain_name.rb#150 + # source://domain_name//lib/domain_name.rb#149 def cookie_domain?(domain, host_only = T.unsafe(nil)); end # The least "universally original" domain part of this domain name. @@ -79,10 +68,10 @@ class DomainName # IP address, an effective TLD or higher itself, or of a # non-canonical domain. # - # source://domain_name//lib/domain_name.rb#32 + # source://domain_name//lib/domain_name.rb#31 def domain; end - # source://domain_name//lib/domain_name.rb#256 + # source://domain_name//lib/domain_name.rb#255 def domain_idn; end # The full host name normalized, ASCII-ized and downcased using the @@ -90,21 +79,21 @@ class DomainName # an IP address, the string representation of the IP address # suitable for opening a connection to. # - # source://domain_name//lib/domain_name.rb#21 + # source://domain_name//lib/domain_name.rb#20 def hostname; end - # source://domain_name//lib/domain_name.rb#245 + # source://domain_name//lib/domain_name.rb#244 def hostname_idn; end - # source://domain_name//lib/domain_name.rb#245 + # source://domain_name//lib/domain_name.rb#244 def idn; end - # source://domain_name//lib/domain_name.rb#274 + # source://domain_name//lib/domain_name.rb#273 def inspect; end # Returns an IPAddr object if this is an IP address. # - # source://domain_name//lib/domain_name.rb#50 + # source://domain_name//lib/domain_name.rb#49 def ipaddr; end # Returns true if this is an IP address, such as "192.168.0.1" and @@ -112,12 +101,12 @@ class DomainName # # @return [Boolean] # - # source://domain_name//lib/domain_name.rb#54 + # source://domain_name//lib/domain_name.rb#53 def ipaddr?; end # Returns the superdomain of this domain name. # - # source://domain_name//lib/domain_name.rb#168 + # source://domain_name//lib/domain_name.rb#167 def superdomain; end # The TLD part of this domain name. For example, if the hostname is @@ -126,30 +115,31 @@ class DomainName # does not have one, like when it is an IP address or of a # non-canonical domain. # - # source://domain_name//lib/domain_name.rb#43 + # source://domain_name//lib/domain_name.rb#42 def tld; end - # source://domain_name//lib/domain_name.rb#265 + # source://domain_name//lib/domain_name.rb#264 def tld_idn; end - # source://domain_name//lib/domain_name.rb#239 + # source://domain_name//lib/domain_name.rb#238 def to_s; end - # source://domain_name//lib/domain_name.rb#239 + # source://domain_name//lib/domain_name.rb#238 def to_str; end # Returns a host name representation suitable for use in the host # name part of a URI. A host name, an IPv4 address, or a IPv6 # address enclosed in square brackets. # - # source://domain_name//lib/domain_name.rb#61 + # source://domain_name//lib/domain_name.rb#60 def uri_host; end class << self - # source://domain_name//lib/domain_name/etld_data.rb#8784 + # source://domain_name//lib/domain_name/etld_data.rb#9572 def etld_data; end # Normalizes a _domain_ using the Punycode algorithm as necessary. + # Input must be strictly ASCII-only or unicode. # The result will be a downcased, ASCII-only string. # # source://domain_name//lib/domain_name.rb#288 @@ -157,7 +147,7 @@ class DomainName end end -# source://domain_name//lib/domain_name.rb#74 +# source://domain_name//lib/domain_name.rb#73 DomainName::DOT = T.let(T.unsafe(nil), String) # source://domain_name//lib/domain_name/etld_data.rb#4 @@ -267,6 +257,6 @@ class Object < ::BasicObject private - # source://domain_name//lib/domain_name.rb#295 + # source://domain_name//lib/domain_name.rb#298 def DomainName(hostname); end end diff --git a/sorbet/rbi/gems/down@5.4.2.rbi b/sorbet/rbi/gems/down@5.4.2.rbi new file mode 100644 index 000000000..6eb1aa336 --- /dev/null +++ b/sorbet/rbi/gems/down@5.4.2.rbi @@ -0,0 +1,479 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `down` gem. +# Please instead update this file by running `bin/tapioca gem down`. + + +# source://down//lib/down/version.rb#3 +module Down + private + + # Allows setting a backend via a symbol or a downloader object. + # + # source://down//lib/down.rb#18 + def backend(value = T.unsafe(nil)); end + + # source://down//lib/down.rb#9 + def download(*args, **options, &block); end + + # source://down//lib/down.rb#13 + def open(*args, **options, &block); end + + class << self + # Allows setting a backend via a symbol or a downloader object. + # + # source://down//lib/down.rb#18 + def backend(value = T.unsafe(nil)); end + + # source://down//lib/down.rb#9 + def download(*args, **options, &block); end + + # source://down//lib/down.rb#13 + def open(*args, **options, &block); end + end +end + +# source://down//lib/down/backend.rb#11 +class Down::Backend + private + + # If destination path is defined, move tempfile to the destination, + # otherwise return the tempfile unchanged. + # + # source://down//lib/down/backend.rb#24 + def download_result(tempfile, destination); end + + # source://down//lib/down/backend.rb#33 + def normalize_headers(response_headers); end + + class << self + # source://down//lib/down/backend.rb#12 + def download(*args, **options, &block); end + + # source://down//lib/down/backend.rb#16 + def open(*args, **options, &block); end + end +end + +# Wraps an enumerator that yields chunks of content into an IO object. It +# implements some essential IO methods: +# +# * IO#read +# * IO#readpartial +# * IO#gets +# * IO#size +# * IO#pos +# * IO#eof? +# * IO#rewind +# * IO#close +# +# By default the Down::ChunkedIO caches all read content into a tempfile, +# allowing it to be rewindable. If rewindability won't be used, it can be +# disabled by setting `:rewindable` to false, which eliminates any disk I/O. +# +# Any cleanup code (i.e. ensure block) that the given enumerator carries is +# guaranteed to get executed, either when all content has been retrieved or +# when Down::ChunkedIO is closed. One can also specify an `:on_close` +# callback that will also get executed in those situations. +# +# source://down//lib/down/chunked_io.rb#27 +class Down::ChunkedIO + # @return [ChunkedIO] a new instance of ChunkedIO + # + # source://down//lib/down/chunked_io.rb#30 + def initialize(chunks:, size: T.unsafe(nil), on_close: T.unsafe(nil), data: T.unsafe(nil), rewindable: T.unsafe(nil), encoding: T.unsafe(nil)); end + + # Implements IO#close semantics. Closes the Down::ChunkedIO by terminating + # chunk retrieval and deleting the cached content. + # + # source://down//lib/down/chunked_io.rb#255 + def close; end + + # Returns whether the Down::ChunkedIO has been closed. + # + # @return [Boolean] + # + # source://down//lib/down/chunked_io.rb#265 + def closed?; end + + # Returns the value of attribute data. + # + # source://down//lib/down/chunked_io.rb#28 + def data; end + + # Sets the attribute data + # + # @param value the value to set the attribute data to. + # + # source://down//lib/down/chunked_io.rb#28 + def data=(_arg0); end + + # Yields elements of the underlying enumerator. + # + # source://down//lib/down/chunked_io.rb#46 + def each_chunk; end + + # Returns the value of attribute encoding. + # + # source://down//lib/down/chunked_io.rb#28 + def encoding; end + + # Sets the attribute encoding + # + # @param value the value to set the attribute encoding to. + # + # source://down//lib/down/chunked_io.rb#28 + def encoding=(_arg0); end + + # Implements IO#eof? semantics. Returns whether we've reached end of file. + # It returns true if cache is at the end and there is no more content to + # retrieve. Raises IOError if closed. + # + # @return [Boolean] + # + # source://down//lib/down/chunked_io.rb#235 + def eof?; end + + # Implements IO#gets semantics. Without arguments it retrieves lines of + # content separated by newlines. + # + # With `separator` argument it does the following: + # + # * if `separator` is a nonempty string returns chunks of content + # surrounded with that sequence of bytes + # * if `separator` is an empty string returns paragraphs of content + # (content delimited by two newlines) + # * if `separator` is nil and `limit` is nil returns all content + # + # With `limit` argument returns maximum of that amount of bytes. + # + # Returns nil if end of file is reached. Raises IOError if closed. + # + # source://down//lib/down/chunked_io.rb#98 + def gets(separator_or_limit = T.unsafe(nil), limit = T.unsafe(nil)); end + + # Returns useful information about the Down::ChunkedIO object. + # + # source://down//lib/down/chunked_io.rb#275 + def inspect; end + + # Implements IO#pos semantics. Returns the current position of the + # Down::ChunkedIO. + # + # source://down//lib/down/chunked_io.rb#227 + def pos; end + + # Implements IO#read semantics. Without arguments it retrieves and returns + # all content. + # + # With `length` argument returns exactly that number of bytes if they're + # available. + # + # With `outbuf` argument each call will return that same string object, + # where the value is replaced with retrieved content. + # + # If end of file is reached, returns empty string if called without + # arguments, or nil if called with arguments. Raises IOError if closed. + # + # source://down//lib/down/chunked_io.rb#65 + def read(length = T.unsafe(nil), outbuf = T.unsafe(nil)); end + + # Implements IO#readpartial semantics. If there is any content readily + # available reads from it, otherwise fetches and reads from the next chunk. + # It writes to and reads from the cache when needed. + # + # Without arguments it either returns all content that's readily available, + # or the next chunk. This is useful when you don't care about the size of + # chunks and you want to minimize string allocations. + # + # With `maxlen` argument returns maximum of that amount of bytes (default + # is 16KB). + # + # With `outbuf` argument each call will return that same string object, + # where the value is replaced with retrieved content. + # + # Raises EOFError if end of file is reached. Raises IOError if closed. + # + # source://down//lib/down/chunked_io.rb#156 + def readpartial(maxlen = T.unsafe(nil), outbuf = T.unsafe(nil)); end + + # Implements IO#rewind semantics. Rewinds the Down::ChunkedIO by rewinding + # the cache and setting the position to the beginning of the file. Raises + # IOError if closed or not rewindable. + # + # source://down//lib/down/chunked_io.rb#245 + def rewind; end + + # Returns whether the Down::ChunkedIO was specified as rewindable. + # + # @return [Boolean] + # + # source://down//lib/down/chunked_io.rb#270 + def rewindable?; end + + # Implements IO#seek semantics. + # + # source://down//lib/down/chunked_io.rb#196 + def seek(amount, whence = T.unsafe(nil)); end + + # Returns the value of attribute size. + # + # source://down//lib/down/chunked_io.rb#28 + def size; end + + # Sets the attribute size + # + # @param value the value to set the attribute size to. + # + # source://down//lib/down/chunked_io.rb#28 + def size=(_arg0); end + + # Implements IO#pos semantics. Returns the current position of the + # Down::ChunkedIO. + # + # source://down//lib/down/chunked_io.rb#227 + def tell; end + + private + + # If Down::ChunkedIO is specified as rewindable, returns a new Tempfile for + # writing read content to. This allows the Down::ChunkedIO to be rewinded. + # + # source://down//lib/down/chunked_io.rb#292 + def cache; end + + # Returns whether there is any content left to retrieve. + # + # @return [Boolean] + # + # source://down//lib/down/chunked_io.rb#312 + def chunks_depleted?; end + + # Creates a Fiber wrapper around the underlying enumerator. The advantage + # of using a Fiber here is that we can terminate the chunk retrieval, in a + # way that executes any cleanup code that the enumerator potentially + # carries. At the end of iteration the :on_close callback is executed. + # + # source://down//lib/down/chunked_io.rb#320 + def chunks_fiber; end + + # Finds encoding by name. If the encoding couldn't be find, falls back to + # the generic binary encoding. + # + # source://down//lib/down/chunked_io.rb#335 + def find_encoding(encoding); end + + # Returns whether the filesystem has POSIX semantics. + # + # @return [Boolean] + # + # source://down//lib/down/chunked_io.rb#342 + def posix?; end + + # Returns current chunk and retrieves the next chunk. If next chunk is nil, + # we know we've reached EOF. + # + # source://down//lib/down/chunked_io.rb#305 + def retrieve_chunk; end +end + +# raised when response returned 4xx response +# +# source://down//lib/down/errors.rb#30 +class Down::ClientError < ::Down::ResponseError; end + +# raised when there was an error connecting to the server +# +# source://down//lib/down/errors.rb#39 +class Down::ConnectionError < ::Down::Error; end + +# generic error which is a superclass to all other errors +# +# source://down//lib/down/errors.rb#5 +class Down::Error < ::StandardError; end + +# raised when the given URL couldn't be parsed +# +# source://down//lib/down/errors.rb#11 +class Down::InvalidUrl < ::Down::Error; end + +# Provides streaming downloads implemented with Net::HTTP and open-uri. +# +# source://down//lib/down/net_http.rb#14 +class Down::NetHttp < ::Down::Backend + # Initializes the backend with common defaults. + # + # @return [NetHttp] a new instance of NetHttp + # + # source://down//lib/down/net_http.rb#21 + def initialize(*args, **options); end + + # Downloads a remote file to disk using open-uri. Accepts any open-uri + # options, and a few more. + # + # source://down//lib/down/net_http.rb#33 + def download(url, *args, **options); end + + # Starts retrieving the remote file using Net::HTTP and returns an IO-like + # object which downloads the response body on-demand. + # + # source://down//lib/down/net_http.rb#107 + def open(url, *args, **options); end + + private + + # Build a Net::HTTP object for making a request. + # + # source://down//lib/down/net_http.rb#242 + def create_net_http(uri, options); end + + # Converts the given IO into a Tempfile if it isn't one already (open-uri + # returns a StringIO when there is less than 10KB of content), and gives + # it the specified file extension. + # + # source://down//lib/down/net_http.rb#185 + def ensure_tempfile(io, extension); end + + # Checks that the url is a valid URI and that its scheme is http or https. + # + # source://down//lib/down/net_http.rb#289 + def ensure_uri(url, allow_relative: T.unsafe(nil)); end + + # Merge default and ad-hoc options, merging nested headers. + # + # source://down//lib/down/net_http.rb#363 + def merge_options(options, headers = T.unsafe(nil), **new_options); end + + # Makes a Net::HTTP request and follows redirects. + # + # source://down//lib/down/net_http.rb#203 + def net_http_request(uri, options, follows_remaining:, &block); end + + # Makes sure that the URL is properly encoded. + # + # source://down//lib/down/net_http.rb#304 + def normalize_uri(url, uri_normalizer:); end + + # Calls open-uri's URI::HTTP#open method. Additionally handles redirects. + # + # source://down//lib/down/net_http.rb#144 + def open_uri(uri, options, follows_remaining:); end + + # When open-uri raises an exception, it doesn't expose the response object. + # Fortunately, the exception object holds response data that can be used to + # rebuild the Net::HTTP response object. + # + # source://down//lib/down/net_http.rb#313 + def rebuild_response_from_open_uri_exception(exception); end + + # Re-raise Net::HTTP exceptions as Down::Error exceptions. + # + # source://down//lib/down/net_http.rb#347 + def request_error!(exception); end + + # Raises non-sucessful response as a Down::ResponseError. + # + # source://down//lib/down/net_http.rb#332 + def response_error!(response); end + + # Yields chunks of the response body to the block. + # + # source://down//lib/down/net_http.rb#282 + def stream_body(response, &block); end +end + +# Defines some additional attributes for the returned Tempfile (on top of what +# OpenURI::Meta already defines). +# +# source://down//lib/down/net_http.rb#382 +module Down::NetHttp::DownloadedFile + # source://down//lib/down/net_http.rb#388 + def content_type; end + + # source://down//lib/down/net_http.rb#383 + def original_filename; end +end + +# source://down//lib/down/net_http.rb#15 +Down::NetHttp::URI_NORMALIZER = T.let(T.unsafe(nil), Proc) + +# raised when response returned 404 response +# +# source://down//lib/down/errors.rb#33 +class Down::NotFound < ::Down::ClientError; end + +# raised when the requested resource has not been modified +# +# source://down//lib/down/errors.rb#17 +class Down::NotModified < ::Down::Error; end + +# raised when response returned 4xx or 5xx response +# +# source://down//lib/down/errors.rb#20 +class Down::ResponseError < ::Down::Error + # @return [ResponseError] a new instance of ResponseError + # + # source://down//lib/down/errors.rb#23 + def initialize(message, response = T.unsafe(nil)); end + + # Returns the value of attribute response. + # + # source://down//lib/down/errors.rb#21 + def response; end +end + +# raised when an SSL error was raised +# +# source://down//lib/down/errors.rb#45 +class Down::SSLError < ::Down::Error; end + +# raised when response returned 5xx response +# +# source://down//lib/down/errors.rb#36 +class Down::ServerError < ::Down::ResponseError; end + +# raised when connecting to the server too longer than the specified timeout +# +# source://down//lib/down/errors.rb#42 +class Down::TimeoutError < ::Down::ConnectionError; end + +# raised when the file is larger than the specified maximum size +# +# source://down//lib/down/errors.rb#8 +class Down::TooLarge < ::Down::Error; end + +# raised when the number of redirects was larger than the specified maximum +# +# source://down//lib/down/errors.rb#14 +class Down::TooManyRedirects < ::Down::Error; end + +# source://down//lib/down/utils.rb#4 +module Down::Utils + private + + # Retrieves potential filename from the "Content-Disposition" header. + # + # source://down//lib/down/utils.rb#8 + def filename_from_content_disposition(content_disposition); end + + # Retrieves potential filename from the URL path. + # + # source://down//lib/down/utils.rb#22 + def filename_from_path(path); end + + class << self + # Retrieves potential filename from the "Content-Disposition" header. + # + # source://down//lib/down/utils.rb#8 + def filename_from_content_disposition(content_disposition); end + + # Retrieves potential filename from the URL path. + # + # source://down//lib/down/utils.rb#22 + def filename_from_path(path); end + end +end + +# source://down//lib/down/version.rb#4 +Down::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/draper@4.0.2.rbi b/sorbet/rbi/gems/draper@4.0.2.rbi index b80105dd5..5f19003e0 100644 --- a/sorbet/rbi/gems/draper@4.0.2.rbi +++ b/sorbet/rbi/gems/draper@4.0.2.rbi @@ -4,16 +4,20 @@ # This is an autogenerated file for types exported from the `draper` gem. # Please instead update this file by running `bin/tapioca gem draper`. + # source://draper//lib/draper/railtie.rb#3 module ActiveModel class << self - # source://activemodel/7.0.5/lib/active_model.rb#72 + # source://activemodel/7.2.0/lib/active_model/deprecator.rb#4 + def deprecator; end + + # source://activemodel/7.2.0/lib/active_model.rb#76 def eager_load!; end - # source://activemodel/7.0.5/lib/active_model/gem_version.rb#5 + # source://activemodel/7.2.0/lib/active_model/gem_version.rb#5 def gem_version; end - # source://activemodel/7.0.5/lib/active_model/version.rb#7 + # source://activemodel/7.2.0/lib/active_model/version.rb#7 def version; end end end @@ -617,9 +621,6 @@ class Draper::CollectionDecorator # source://draper//lib/draper/delegation.rb#10 def to_ary(*_arg0, **_arg1, &_arg2); end - # source://draper//lib/draper/delegation.rb#10 - def to_default_s(*_arg0, **_arg1, &_arg2); end - # source://draper//lib/draper/delegation.rb#10 def to_formatted_s(*_arg0, **_arg1, &_arg2); end @@ -629,6 +630,9 @@ class Draper::CollectionDecorator # source://draper//lib/draper/delegation.rb#10 def to_h(*_arg0, **_arg1, &_arg2); end + # source://draper//lib/draper/delegation.rb#10 + def to_msgpack(*_arg0, **_arg1, &_arg2); end + # source://draper//lib/draper/collection_decorator.rb#48 def to_s; end @@ -989,10 +993,10 @@ class Draper::Decorator # source://draper//lib/draper/decorator.rb#184 def hash; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json?; end # Checks if `self.instance_of?(klass)` or `object.instance_of?(klass)` @@ -1025,7 +1029,7 @@ class Draper::Decorator def model; end # source://draper//lib/draper/delegation.rb#10 - def model_name(*_arg0, **_arg1, &_arg2); end + def model_name(&_arg0); end # @return the object being decorated. # @@ -1140,13 +1144,13 @@ class Draper::Decorator # source://draper//lib/draper/decorator.rb#47 def delegate_all; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json; end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json=(value); end - # source://activemodel/7.0.5/lib/active_model/serializers/json.rb#15 + # source://activemodel/7.2.0/lib/active_model/serializers/json.rb#15 def include_root_in_json?; end # @raise [Draper::UninferrableObjectError] diff --git a/sorbet/rbi/gems/drb@2.2.1.rbi b/sorbet/rbi/gems/drb@2.2.1.rbi new file mode 100644 index 000000000..d97695d9a --- /dev/null +++ b/sorbet/rbi/gems/drb@2.2.1.rbi @@ -0,0 +1,1347 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `drb` gem. +# Please instead update this file by running `bin/tapioca gem drb`. + + +# for ruby-1.8.0 +# +# source://drb//lib/drb/eq.rb#2 +module DRb + private + + # Get the configuration of the current server. + # + # If there is no current server, this returns the default configuration. + # See #current_server and DRbServer::make_config. + # + # source://drb//lib/drb/drb.rb#1832 + def config; end + + # Get the 'current' server. + # + # In the context of execution taking place within the main + # thread of a dRuby server (typically, as a result of a remote + # call on the server or one of its objects), the current + # server is that server. Otherwise, the current server is + # the primary server. + # + # If the above rule fails to find a server, a DRbServerNotFound + # error is raised. + # + # @raise [DRbServerNotFound] + # + # source://drb//lib/drb/drb.rb#1789 + def current_server; end + + # Retrieves the server with the given +uri+. + # + # See also regist_server and remove_server. + # + # source://drb//lib/drb/drb.rb#1934 + def fetch_server(uri); end + + # Get the front object of the current server. + # + # This raises a DRbServerNotFound error if there is no current server. + # See #current_server. + # + # source://drb//lib/drb/drb.rb#1843 + def front; end + + # Is +uri+ the URI for the current local server? + # + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1822 + def here?(uri); end + + # Set the default ACL to +acl+. + # + # See DRb::DRbServer.default_acl. + # + # source://drb//lib/drb/drb.rb#1888 + def install_acl(acl); end + + # Set the default id conversion object. + # + # This is expected to be an instance such as DRb::DRbIdConv that responds to + # #to_id and #to_obj that can convert objects to and from DRb references. + # + # See DRbServer#default_id_conv. + # + # source://drb//lib/drb/drb.rb#1880 + def install_id_conv(idconv); end + + # source://drb//lib/drb/drb.rb#1894 + def mutex; end + + # The primary local dRuby server. + # + # This is the server created by the #start_service call. + # + # source://drb//lib/drb/drb.rb#1776 + def primary_server; end + + # The primary local dRuby server. + # + # This is the server created by the #start_service call. + # + # source://drb//lib/drb/drb.rb#1776 + def primary_server=(_arg0); end + + # Registers +server+ with DRb. + # + # This is called when a new DRb::DRbServer is created. + # + # If there is no primary server then +server+ becomes the primary server. + # + # Example: + # + # require 'drb' + # + # s = DRb::DRbServer.new # automatically calls regist_server + # DRb.fetch_server s.uri #=> # + # + # source://drb//lib/drb/drb.rb#1912 + def regist_server(server); end + + # Removes +server+ from the list of registered servers. + # + # source://drb//lib/drb/drb.rb#1921 + def remove_server(server); end + + # Start a dRuby server locally. + # + # The new dRuby server will become the primary server, even + # if another server is currently the primary server. + # + # +uri+ is the URI for the server to bind to. If nil, + # the server will bind to random port on the default local host + # name and use the default dRuby protocol. + # + # +front+ is the server's front object. This may be nil. + # + # +config+ is the configuration for the new server. This may + # be nil. + # + # See DRbServer::new. + # + # source://drb//lib/drb/drb.rb#1768 + def start_service(uri = T.unsafe(nil), front = T.unsafe(nil), config = T.unsafe(nil)); end + + # Stop the local dRuby server. + # + # This operates on the primary server. If there is no primary + # server currently running, it is a noop. + # + # source://drb//lib/drb/drb.rb#1801 + def stop_service; end + + # Get the thread of the primary server. + # + # This returns nil if there is no primary server. See #primary_server. + # + # source://drb//lib/drb/drb.rb#1869 + def thread; end + + # Get a reference id for an object using the current server. + # + # This raises a DRbServerNotFound error if there is no current server. + # See #current_server. + # + # source://drb//lib/drb/drb.rb#1860 + def to_id(obj); end + + # Convert a reference into an object using the current server. + # + # This raises a DRbServerNotFound error if there is no current server. + # See #current_server. + # + # source://drb//lib/drb/drb.rb#1852 + def to_obj(ref); end + + # Get the URI defining the local dRuby space. + # + # This is the URI of the current server. See #current_server. + # + # source://drb//lib/drb/drb.rb#1810 + def uri; end + + class << self + # Get the configuration of the current server. + # + # If there is no current server, this returns the default configuration. + # See #current_server and DRbServer::make_config. + # + # source://drb//lib/drb/drb.rb#1832 + def config; end + + # Get the 'current' server. + # + # In the context of execution taking place within the main + # thread of a dRuby server (typically, as a result of a remote + # call on the server or one of its objects), the current + # server is that server. Otherwise, the current server is + # the primary server. + # + # If the above rule fails to find a server, a DRbServerNotFound + # error is raised. + # + # @raise [DRbServerNotFound] + # + # source://drb//lib/drb/drb.rb#1789 + def current_server; end + + # Retrieves the server with the given +uri+. + # + # See also regist_server and remove_server. + # + # source://drb//lib/drb/drb.rb#1934 + def fetch_server(uri); end + + # Get the front object of the current server. + # + # This raises a DRbServerNotFound error if there is no current server. + # See #current_server. + # + # source://drb//lib/drb/drb.rb#1843 + def front; end + + # Is +uri+ the URI for the current local server? + # + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1822 + def here?(uri); end + + # Set the default ACL to +acl+. + # + # See DRb::DRbServer.default_acl. + # + # source://drb//lib/drb/drb.rb#1888 + def install_acl(acl); end + + # Set the default id conversion object. + # + # This is expected to be an instance such as DRb::DRbIdConv that responds to + # #to_id and #to_obj that can convert objects to and from DRb references. + # + # See DRbServer#default_id_conv. + # + # source://drb//lib/drb/drb.rb#1880 + def install_id_conv(idconv); end + + # source://drb//lib/drb/drb.rb#1894 + def mutex; end + + # The primary local dRuby server. + # + # This is the server created by the #start_service call. + # + # source://drb//lib/drb/drb.rb#1776 + def primary_server; end + + # The primary local dRuby server. + # + # This is the server created by the #start_service call. + # + # source://drb//lib/drb/drb.rb#1776 + def primary_server=(_arg0); end + + # Registers +server+ with DRb. + # + # This is called when a new DRb::DRbServer is created. + # + # If there is no primary server then +server+ becomes the primary server. + # + # Example: + # + # require 'drb' + # + # s = DRb::DRbServer.new # automatically calls regist_server + # DRb.fetch_server s.uri #=> # + # + # source://drb//lib/drb/drb.rb#1912 + def regist_server(server); end + + # Removes +server+ from the list of registered servers. + # + # source://drb//lib/drb/drb.rb#1921 + def remove_server(server); end + + # Start a dRuby server locally. + # + # The new dRuby server will become the primary server, even + # if another server is currently the primary server. + # + # +uri+ is the URI for the server to bind to. If nil, + # the server will bind to random port on the default local host + # name and use the default dRuby protocol. + # + # +front+ is the server's front object. This may be nil. + # + # +config+ is the configuration for the new server. This may + # be nil. + # + # See DRbServer::new. + # + # source://drb//lib/drb/drb.rb#1768 + def start_service(uri = T.unsafe(nil), front = T.unsafe(nil), config = T.unsafe(nil)); end + + # Stop the local dRuby server. + # + # This operates on the primary server. If there is no primary + # server currently running, it is a noop. + # + # source://drb//lib/drb/drb.rb#1801 + def stop_service; end + + # Get the thread of the primary server. + # + # This returns nil if there is no primary server. See #primary_server. + # + # source://drb//lib/drb/drb.rb#1869 + def thread; end + + # Get a reference id for an object using the current server. + # + # This raises a DRbServerNotFound error if there is no current server. + # See #current_server. + # + # source://drb//lib/drb/drb.rb#1860 + def to_id(obj); end + + # Convert a reference into an object using the current server. + # + # This raises a DRbServerNotFound error if there is no current server. + # See #current_server. + # + # source://drb//lib/drb/drb.rb#1852 + def to_obj(ref); end + + # Get the URI defining the local dRuby space. + # + # This is the URI of the current server. See #current_server. + # + # source://drb//lib/drb/drb.rb#1810 + def uri; end + end +end + +# An Array wrapper that can be sent to another server via DRb. +# +# All entries in the array will be dumped or be references that point to +# the local server. +# +# source://drb//lib/drb/drb.rb#518 +class DRb::DRbArray + # Creates a new DRbArray that either dumps or wraps all the items in the + # Array +ary+ so they can be loaded by a remote DRb server. + # + # @return [DRbArray] a new instance of DRbArray + # + # source://drb//lib/drb/drb.rb#523 + def initialize(ary); end + + # source://drb//lib/drb/drb.rb#542 + def _dump(lv); end + + class << self + # source://drb//lib/drb/drb.rb#538 + def _load(s); end + end +end + +# Class handling the connection between a DRbObject and the +# server the real object lives on. +# +# This class maintains a pool of connections, to reduce the +# overhead of starting and closing down connections for each +# method call. +# +# This class is used internally by DRbObject. The user does +# not normally need to deal with it directly. +# +# source://drb//lib/drb/drb.rb#1256 +class DRb::DRbConn + # @return [DRbConn] a new instance of DRbConn + # + # source://drb//lib/drb/drb.rb#1317 + def initialize(remote_uri); end + + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1333 + def alive?; end + + # source://drb//lib/drb/drb.rb#1328 + def close; end + + # source://drb//lib/drb/drb.rb#1323 + def send_message(ref, msg_id, arg, block); end + + # source://drb//lib/drb/drb.rb#1321 + def uri; end + + class << self + # source://drb//lib/drb/drb.rb#1259 + def make_pool; end + + # source://drb//lib/drb/drb.rb#1297 + def open(remote_uri); end + + # source://drb//lib/drb/drb.rb#1292 + def stop_pool; end + end +end + +# Class responsible for converting between an object and its id. +# +# This, the default implementation, uses an object's local ObjectSpace +# __id__ as its id. This means that an object's identification over +# drb remains valid only while that object instance remains alive +# within the server runtime. +# +# For alternative mechanisms, see DRb::TimerIdConv in drb/timeridconv.rb +# and DRbNameIdConv in sample/name.rb in the full drb distribution. +# +# source://drb//lib/drb/drb.rb#360 +class DRb::DRbIdConv + # Convert an object into a reference id. + # + # This implementation returns the object's __id__ in the local + # object space. + # + # source://drb//lib/drb/drb.rb#374 + def to_id(obj); end + + # Convert an object reference id to an object. + # + # This implementation looks up the reference id in the local object + # space and returns the object it refers to. + # + # source://drb//lib/drb/drb.rb#366 + def to_obj(ref); end +end + +# Handler for sending and receiving drb messages. +# +# This takes care of the low-level marshalling and unmarshalling +# of drb requests and responses sent over the wire between server +# and client. This relieves the implementor of a new drb +# protocol layer with having to deal with these details. +# +# The user does not have to directly deal with this object in +# normal use. +# +# source://drb//lib/drb/drb.rb#556 +class DRb::DRbMessage + # @return [DRbMessage] a new instance of DRbMessage + # + # source://drb//lib/drb/drb.rb#557 + def initialize(config); end + + # source://drb//lib/drb/drb.rb#562 + def dump(obj, error = T.unsafe(nil)); end + + # @raise [DRbConnError] + # + # source://drb//lib/drb/drb.rb#579 + def load(soc); end + + # source://drb//lib/drb/drb.rb#639 + def recv_reply(stream); end + + # @raise [DRbConnError] + # + # source://drb//lib/drb/drb.rb#619 + def recv_request(stream); end + + # source://drb//lib/drb/drb.rb#633 + def send_reply(stream, succ, result); end + + # source://drb//lib/drb/drb.rb#605 + def send_request(stream, ref, msg_id, arg, b); end + + private + + # source://drb//lib/drb/drb.rb#646 + def make_proxy(obj, error = T.unsafe(nil)); end +end + +# source://drb//lib/drb/eq.rb#3 +class DRb::DRbObject + # Create a new remote object stub. + # + # +obj+ is the (local) object we want to create a stub for. Normally + # this is +nil+. +uri+ is the URI of the remote object that this + # will be a stub for. + # + # @return [DRbObject] a new instance of DRbObject + # + # source://drb//lib/drb/drb.rb#1089 + def initialize(obj, uri = T.unsafe(nil)); end + + # source://drb//lib/drb/eq.rb#4 + def ==(other); end + + # Get the reference of the object, if local. + # + # source://drb//lib/drb/drb.rb#1115 + def __drbref; end + + # Get the URI of the remote object. + # + # source://drb//lib/drb/drb.rb#1110 + def __drburi; end + + # Marshall this object. + # + # The URI and ref of the object are marshalled. + # + # source://drb//lib/drb/drb.rb#1080 + def _dump(lv); end + + # source://drb//lib/drb/eq.rb#4 + def eql?(other); end + + # source://drb//lib/drb/eq.rb#9 + def hash; end + + # source://drb//lib/drb/drb.rb#1135 + def method_missing(msg_id, *a, **_arg2, &b); end + + # source://drb//lib/drb/drb.rb#1187 + def pretty_print(q); end + + # source://drb//lib/drb/drb.rb#1191 + def pretty_print_cycle(q); end + + # Routes respond_to? to the referenced remote object. + # + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1123 + def respond_to?(msg_id, priv = T.unsafe(nil)); end + + class << self + # Unmarshall a marshalled DRbObject. + # + # If the referenced object is located within the local server, then + # the object itself is returned. Otherwise, a new DRbObject is + # created to act as a stub for the remote referenced object. + # + # source://drb//lib/drb/drb.rb#1051 + def _load(s); end + + # Creates a DRb::DRbObject given the reference information to the remote + # host +uri+ and object +ref+. + # + # source://drb//lib/drb/drb.rb#1065 + def new_with(uri, ref); end + + # Create a new DRbObject from a URI alone. + # + # source://drb//lib/drb/drb.rb#1073 + def new_with_uri(uri); end + + # Returns a modified backtrace from +result+ with the +uri+ where each call + # in the backtrace came from. + # + # source://drb//lib/drb/drb.rb#1173 + def prepare_backtrace(uri, result); end + + # Given the +uri+ of another host executes the block provided. + # + # source://drb//lib/drb/drb.rb#1160 + def with_friend(uri); end + end +end + +# Module managing the underlying network protocol(s) used by drb. +# +# By default, drb uses the DRbTCPSocket protocol. Other protocols +# can be defined. A protocol must define the following class methods: +# +# [open(uri, config)] Open a client connection to the server at +uri+, +# using configuration +config+. Return a protocol +# instance for this connection. +# [open_server(uri, config)] Open a server listening at +uri+, +# using configuration +config+. Return a +# protocol instance for this listener. +# [uri_option(uri, config)] Take a URI, possibly containing an option +# component (e.g. a trailing '?param=val'), +# and return a [uri, option] tuple. +# +# All of these methods should raise a DRbBadScheme error if the URI +# does not identify the protocol they support (e.g. "druby:" for +# the standard Ruby protocol). This is how the DRbProtocol module, +# given a URI, determines which protocol implementation serves that +# protocol. +# +# The protocol instance returned by #open_server must have the +# following methods: +# +# [accept] Accept a new connection to the server. Returns a protocol +# instance capable of communicating with the client. +# [close] Close the server connection. +# [uri] Get the URI for this server. +# +# The protocol instance returned by #open must have the following methods: +# +# [send_request (ref, msg_id, arg, b)] +# Send a request to +ref+ with the given message id and arguments. +# This is most easily implemented by calling DRbMessage.send_request, +# providing a stream that sits on top of the current protocol. +# [recv_reply] +# Receive a reply from the server and return it as a [success-boolean, +# reply-value] pair. This is most easily implemented by calling +# DRb.recv_reply, providing a stream that sits on top of the +# current protocol. +# [alive?] +# Is this connection still alive? +# [close] +# Close this connection. +# +# The protocol instance returned by #open_server().accept() must have +# the following methods: +# +# [recv_request] +# Receive a request from the client and return a [object, message, +# args, block] tuple. This is most easily implemented by calling +# DRbMessage.recv_request, providing a stream that sits on top of +# the current protocol. +# [send_reply(succ, result)] +# Send a reply to the client. This is most easily implemented +# by calling DRbMessage.send_reply, providing a stream that sits +# on top of the current protocol. +# [close] +# Close this connection. +# +# A new protocol is registered with the DRbProtocol module using +# the add_protocol method. +# +# For examples of other protocols, see DRbUNIXSocket in drb/unix.rb, +# and HTTP0 in sample/http0.rb and sample/http0serv.rb in the full +# drb distribution. +# +# source://drb//lib/drb/drb.rb#721 +module DRb::DRbProtocol + private + + # Add a new protocol to the DRbProtocol module. + # + # source://drb//lib/drb/drb.rb#724 + def add_protocol(prot); end + + # source://drb//lib/drb/drb.rb#802 + def auto_load(uri); end + + # Open a client connection to +uri+ with the configuration +config+. + # + # The DRbProtocol module asks each registered protocol in turn to + # try to open the URI. Each protocol signals that it does not handle that + # URI by raising a DRbBadScheme error. If no protocol recognises the + # URI, then a DRbBadURI error is raised. If a protocol accepts the + # URI, but an error occurs in opening it, a DRbConnError is raised. + # + # @raise [DRbBadURI] + # + # source://drb//lib/drb/drb.rb#736 + def open(uri, config, first = T.unsafe(nil)); end + + # Open a server listening for connections at +uri+ with + # configuration +config+. + # + # The DRbProtocol module asks each registered protocol in turn to + # try to open a server at the URI. Each protocol signals that it does + # not handle that URI by raising a DRbBadScheme error. If no protocol + # recognises the URI, then a DRbBadURI error is raised. If a protocol + # accepts the URI, but an error occurs in opening it, the underlying + # error is passed on to the caller. + # + # @raise [DRbBadURI] + # + # source://drb//lib/drb/drb.rb#764 + def open_server(uri, config, first = T.unsafe(nil)); end + + # Parse +uri+ into a [uri, option] pair. + # + # The DRbProtocol module asks each registered protocol in turn to + # try to parse the URI. Each protocol signals that it does not handle that + # URI by raising a DRbBadScheme error. If no protocol recognises the + # URI, then a DRbBadURI error is raised. + # + # @raise [DRbBadURI] + # + # source://drb//lib/drb/drb.rb#785 + def uri_option(uri, config, first = T.unsafe(nil)); end + + class << self + # Add a new protocol to the DRbProtocol module. + # + # source://drb//lib/drb/drb.rb#724 + def add_protocol(prot); end + + # source://drb//lib/drb/drb.rb#802 + def auto_load(uri); end + + # Open a client connection to +uri+ with the configuration +config+. + # + # The DRbProtocol module asks each registered protocol in turn to + # try to open the URI. Each protocol signals that it does not handle that + # URI by raising a DRbBadScheme error. If no protocol recognises the + # URI, then a DRbBadURI error is raised. If a protocol accepts the + # URI, but an error occurs in opening it, a DRbConnError is raised. + # + # @raise [DRbBadURI] + # + # source://drb//lib/drb/drb.rb#736 + def open(uri, config, first = T.unsafe(nil)); end + + # Open a server listening for connections at +uri+ with + # configuration +config+. + # + # The DRbProtocol module asks each registered protocol in turn to + # try to open a server at the URI. Each protocol signals that it does + # not handle that URI by raising a DRbBadScheme error. If no protocol + # recognises the URI, then a DRbBadURI error is raised. If a protocol + # accepts the URI, but an error occurs in opening it, the underlying + # error is passed on to the caller. + # + # @raise [DRbBadURI] + # + # source://drb//lib/drb/drb.rb#764 + def open_server(uri, config, first = T.unsafe(nil)); end + + # Parse +uri+ into a [uri, option] pair. + # + # The DRbProtocol module asks each registered protocol in turn to + # try to parse the URI. Each protocol signals that it does not handle that + # URI by raising a DRbBadScheme error. If no protocol recognises the + # URI, then a DRbBadURI error is raised. + # + # @raise [DRbBadURI] + # + # source://drb//lib/drb/drb.rb#785 + def uri_option(uri, config, first = T.unsafe(nil)); end + end +end + +# An exception wrapping an error object +# +# source://drb//lib/drb/drb.rb#431 +class DRb::DRbRemoteError < ::DRb::DRbError + # Creates a new remote error that wraps the Exception +error+ + # + # @return [DRbRemoteError] a new instance of DRbRemoteError + # + # source://drb//lib/drb/drb.rb#434 + def initialize(error); end + + # the class of the error, as a string. + # + # source://drb//lib/drb/drb.rb#441 + def reason; end +end + +# source://drb//lib/drb/drb.rb#1350 +class DRb::DRbServer + # Create a new DRbServer instance. + # + # +uri+ is the URI to bind to. This is normally of the form + # 'druby://:' where is a hostname of + # the local machine. If nil, then the system's default hostname + # will be bound to, on a port selected by the system; these value + # can be retrieved from the +uri+ attribute. 'druby:' specifies + # the default dRuby transport protocol: another protocol, such + # as 'drbunix:', can be specified instead. + # + # +front+ is the front object for the server, that is, the object + # to which remote method calls on the server will be passed. If + # nil, then the server will not accept remote method calls. + # + # If +config_or_acl+ is a hash, it is the configuration to + # use for this server. The following options are recognised: + # + # :idconv :: an id-to-object conversion object. This defaults + # to an instance of the class DRb::DRbIdConv. + # :verbose :: if true, all unsuccessful remote calls on objects + # in the server will be logged to $stdout. false + # by default. + # :tcp_acl :: the access control list for this server. See + # the ACL class from the main dRuby distribution. + # :load_limit :: the maximum message size in bytes accepted by + # the server. Defaults to 25 MB (26214400). + # :argc_limit :: the maximum number of arguments to a remote + # method accepted by the server. Defaults to + # 256. + # The default values of these options can be modified on + # a class-wide basis by the class methods #default_argc_limit, + # #default_load_limit, #default_acl, #default_id_conv, + # and #verbose= + # + # If +config_or_acl+ is not a hash, but is not nil, it is + # assumed to be the access control list for this server. + # See the :tcp_acl option for more details. + # + # If no other server is currently set as the primary server, + # this will become the primary server. + # + # The server will immediately start running in its own thread. + # + # @return [DRbServer] a new instance of DRbServer + # + # source://drb//lib/drb/drb.rb#1451 + def initialize(uri = T.unsafe(nil), front = T.unsafe(nil), config_or_acl = T.unsafe(nil)); end + + # Is this server alive? + # + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1506 + def alive?; end + + # Check that a method is callable via dRuby. + # + # +obj+ is the object we want to invoke the method on. +msg_id+ is the + # method name, as a Symbol. + # + # If the method is an insecure method (see #insecure_method?) a + # SecurityError is thrown. If the method is private or undefined, + # a NameError is thrown. + # + # @raise [ArgumentError] + # + # source://drb//lib/drb/drb.rb#1594 + def check_insecure_method(obj, msg_id); end + + # The configuration of this DRbServer + # + # source://drb//lib/drb/drb.rb#1493 + def config; end + + # The front object of the DRbServer. + # + # This object receives remote method calls made on the server's + # URI alone, with an object id. + # + # source://drb//lib/drb/drb.rb#1490 + def front; end + + # Is +uri+ the URI for this server? + # + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1511 + def here?(uri); end + + # Stop this server. + # + # source://drb//lib/drb/drb.rb#1516 + def stop_service; end + + # The main thread of this DRbServer. + # + # This is the thread that listens for and accepts connections + # from clients, not that handles each client's request-response + # session. + # + # source://drb//lib/drb/drb.rb#1484 + def thread; end + + # Convert a local object to a dRuby reference. + # + # source://drb//lib/drb/drb.rb#1533 + def to_id(obj); end + + # Convert a dRuby reference to the local object it refers to. + # + # source://drb//lib/drb/drb.rb#1526 + def to_obj(ref); end + + # The URI of this DRbServer. + # + # source://drb//lib/drb/drb.rb#1477 + def uri; end + + # Get whether the server is in verbose mode. + # + # In verbose mode, failed calls are logged to stdout. + # + # source://drb//lib/drb/drb.rb#1503 + def verbose; end + + # Set whether to operate in verbose mode. + # + # In verbose mode, failed calls are logged to stdout. + # + # source://drb//lib/drb/drb.rb#1498 + def verbose=(v); end + + private + + # Coerce an object to a string, providing our own representation if + # to_s is not defined for the object. + # + # source://drb//lib/drb/drb.rb#1580 + def any_to_s(obj); end + + # source://drb//lib/drb/drb.rb#1696 + def error_print(exception); end + + # Has a method been included in the list of insecure methods? + # + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1574 + def insecure_method?(msg_id); end + + # The main loop performed by a DRbServer's internal thread. + # + # Accepts a connection from a client, and starts up its own + # thread to handle it. This thread loops, receiving requests + # from the client, invoking them on a local object, and + # returning responses, until the client closes the connection + # or a local method call fails. + # + # source://drb//lib/drb/drb.rb#1714 + def main_loop; end + + # Starts the DRb main loop in a new thread. + # + # source://drb//lib/drb/drb.rb#1555 + def run; end + + # source://drb//lib/drb/drb.rb#1540 + def shutdown; end + + class << self + # Set the default access control list to +acl+. The default ACL is +nil+. + # + # See also DRb::ACL and #new() + # + # source://drb//lib/drb/drb.rb#1375 + def default_acl(acl); end + + # Set the default value for the :argc_limit option. + # + # See #new(). The initial default value is 256. + # + # source://drb//lib/drb/drb.rb#1361 + def default_argc_limit(argc); end + + # Set the default value for the :id_conv option. + # + # See #new(). The initial default value is a DRbIdConv instance. + # + # source://drb//lib/drb/drb.rb#1382 + def default_id_conv(idconv); end + + # Set the default value for the :load_limit option. + # + # See #new(). The initial default value is 25 MB. + # + # source://drb//lib/drb/drb.rb#1368 + def default_load_limit(sz); end + + # source://drb//lib/drb/drb.rb#1398 + def make_config(hash = T.unsafe(nil)); end + + # Get the default value of the :verbose option. + # + # source://drb//lib/drb/drb.rb#1394 + def verbose; end + + # Set the default value of the :verbose option. + # + # See #new(). The initial default value is false. + # + # source://drb//lib/drb/drb.rb#1389 + def verbose=(on); end + end +end + +# source://drb//lib/drb/drb.rb#1624 +class DRb::DRbServer::InvokeMethod + include ::DRb::DRbServer::InvokeMethod18Mixin + + # @return [InvokeMethod] a new instance of InvokeMethod + # + # source://drb//lib/drb/drb.rb#1625 + def initialize(drb_server, client); end + + # source://drb//lib/drb/drb.rb#1630 + def perform; end + + private + + # source://drb//lib/drb/drb.rb#1667 + def check_insecure_method; end + + # source://drb//lib/drb/drb.rb#1659 + def init_with_client; end + + # source://drb//lib/drb/drb.rb#1676 + def perform_without_block; end + + # source://drb//lib/drb/drb.rb#1671 + def setup_message; end +end + +# source://drb//lib/drb/invokemethod.rb#6 +module DRb::DRbServer::InvokeMethod18Mixin + # source://drb//lib/drb/invokemethod.rb#7 + def block_yield(x); end + + # source://drb//lib/drb/invokemethod.rb#14 + def perform_with_block; end +end + +# The default drb protocol which communicates over a TCP socket. +# +# The DRb TCP protocol URI looks like: +# druby://:?. The option is optional. +# +# source://drb//lib/drb/drb.rb#815 +class DRb::DRbTCPSocket + # Create a new DRbTCPSocket instance. + # + # +uri+ is the URI we are connected to. + # +soc+ is the tcp socket we are bound to. +config+ is our + # configuration. + # + # @return [DRbTCPSocket] a new instance of DRbTCPSocket + # + # source://drb//lib/drb/drb.rb#903 + def initialize(uri, soc, config = T.unsafe(nil)); end + + # On the server side, for an instance returned by #open_server, + # accept a client connection and return a new instance to handle + # the server's side of this client-server session. + # + # source://drb//lib/drb/drb.rb#971 + def accept; end + + # Check to see if this connection is alive. + # + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1001 + def alive?; end + + # Close the connection. + # + # If this is an instance returned by #open_server, then this stops + # listening for new connections altogether. If this is an instance + # returned by #open or by #accept, then it closes this particular + # client-server session. + # + # source://drb//lib/drb/drb.rb#953 + def close; end + + # Get the address of our TCP peer (the other end of the socket + # we are bound to. + # + # source://drb//lib/drb/drb.rb#918 + def peeraddr; end + + # On the client side, receive a reply from the server. + # + # source://drb//lib/drb/drb.rb#941 + def recv_reply; end + + # On the server side, receive a request from the client. + # + # source://drb//lib/drb/drb.rb#931 + def recv_request; end + + # On the server side, send a reply to the client. + # + # source://drb//lib/drb/drb.rb#936 + def send_reply(succ, result); end + + # On the client side, send a request to the server. + # + # source://drb//lib/drb/drb.rb#926 + def send_request(ref, msg_id, arg, b); end + + # source://drb//lib/drb/drb.rb#1010 + def set_sockopt(soc); end + + # Graceful shutdown + # + # source://drb//lib/drb/drb.rb#996 + def shutdown; end + + # Get the socket. + # + # source://drb//lib/drb/drb.rb#923 + def stream; end + + # Get the URI that we are connected to. + # + # source://drb//lib/drb/drb.rb#914 + def uri; end + + private + + # source://drb//lib/drb/drb.rb#986 + def accept_or_shutdown; end + + # source://drb//lib/drb/drb.rb#962 + def close_shutdown_pipe; end + + class << self + # Returns the hostname of this server + # + # source://drb//lib/drb/drb.rb#845 + def getservername; end + + # Open a client connection to +uri+ (DRb URI string) using configuration + # +config+. + # + # This can raise DRb::DRbBadScheme or DRb::DRbBadURI if +uri+ is not for a + # recognized protocol. See DRb::DRbServer.new for information on built-in + # URI protocols. + # + # source://drb//lib/drb/drb.rb#838 + def open(uri, config); end + + # Open a server listening for connections at +uri+ using + # configuration +config+. + # + # source://drb//lib/drb/drb.rb#876 + def open_server(uri, config); end + + # For the families available for +host+, returns a TCPServer on +port+. + # If +port+ is 0 the first available port is used. IPv4 servers are + # preferred over IPv6 servers. + # + # source://drb//lib/drb/drb.rb#861 + def open_server_inaddr_any(host, port); end + + # source://drb//lib/drb/drb.rb#818 + def parse_uri(uri); end + + # Parse +uri+ into a [uri, option] pair. + # + # source://drb//lib/drb/drb.rb#893 + def uri_option(uri, config); end + end +end + +# Implements DRb over a UNIX socket +# +# DRb UNIX socket URIs look like drbunix:?. The +# option is optional. +# +# source://drb//lib/drb/unix.rb#15 +class DRb::DRbUNIXSocket < ::DRb::DRbTCPSocket + # @return [DRbUNIXSocket] a new instance of DRbUNIXSocket + # + # source://drb//lib/drb/unix.rb#62 + def initialize(uri, soc, config = T.unsafe(nil), server_mode = T.unsafe(nil)); end + + # source://drb//lib/drb/unix.rb#105 + def accept; end + + # source://drb//lib/drb/unix.rb#95 + def close; end + + # source://drb//lib/drb/unix.rb#111 + def set_sockopt(soc); end + + class << self + # source://drb//lib/drb/unix.rb#28 + def open(uri, config); end + + # source://drb//lib/drb/unix.rb#34 + def open_server(uri, config); end + + # :stopdoc: + # + # source://drb//lib/drb/unix.rb#17 + def parse_uri(uri); end + + # source://drb//lib/drb/unix.rb#72 + def temp_server; end + + # source://drb//lib/drb/unix.rb#57 + def uri_option(uri, config); end + end +end + +# import from tempfile.rb +# +# source://drb//lib/drb/unix.rb#70 +DRb::DRbUNIXSocket::Max_try = T.let(T.unsafe(nil), Integer) + +# source://drb//lib/drb/drb.rb#1021 +class DRb::DRbURIOption + # @return [DRbURIOption] a new instance of DRbURIOption + # + # source://drb//lib/drb/drb.rb#1022 + def initialize(option); end + + # source://drb//lib/drb/drb.rb#1028 + def ==(other); end + + # source://drb//lib/drb/drb.rb#1028 + def eql?(other); end + + # source://drb//lib/drb/drb.rb#1033 + def hash; end + + # Returns the value of attribute option. + # + # source://drb//lib/drb/drb.rb#1025 + def option; end + + # source://drb//lib/drb/drb.rb#1026 + def to_s; end +end + +# Mixin module making an object undumpable or unmarshallable. +# +# If an object which includes this module is returned by method +# called over drb, then the object remains in the server space +# and a reference to the object is returned, rather than the +# object being marshalled and moved into the client space. +# +# source://drb//lib/drb/drb.rb#390 +module DRb::DRbUndumped + # @raise [TypeError] + # + # source://drb//lib/drb/drb.rb#391 + def _dump(dummy); end +end + +# Class wrapping a marshalled object whose type is unknown locally. +# +# If an object is returned by a method invoked over drb, but the +# class of the object is unknown in the client namespace, or +# the object is a constant unknown in the client namespace, then +# the still-marshalled object is returned wrapped in a DRbUnknown instance. +# +# If this object is passed as an argument to a method invoked over +# drb, then the wrapped object is passed instead. +# +# The class or constant name of the object can be read from the +# +name+ attribute. The marshalled object is held in the +buf+ +# attribute. +# +# source://drb//lib/drb/drb.rb#457 +class DRb::DRbUnknown + # Create a new DRbUnknown object. + # + # +buf+ is a string containing a marshalled object that could not + # be unmarshalled. +err+ is the error message that was raised + # when the unmarshalling failed. It is used to determine the + # name of the unmarshalled object. + # + # @return [DRbUnknown] a new instance of DRbUnknown + # + # source://drb//lib/drb/drb.rb#465 + def initialize(err, buf); end + + # source://drb//lib/drb/drb.rb#494 + def _dump(lv); end + + # Buffer contained the marshalled, unknown object. + # + # source://drb//lib/drb/drb.rb#484 + def buf; end + + # Create a DRbUnknownError exception containing this object. + # + # source://drb//lib/drb/drb.rb#508 + def exception; end + + # The name of the unknown thing. + # + # Class name for unknown objects; variable name for unknown + # constants. + # + # source://drb//lib/drb/drb.rb#481 + def name; end + + # Attempt to load the wrapped marshalled object again. + # + # If the class of the object is now known locally, the object + # will be unmarshalled and returned. Otherwise, a new + # but identical DRbUnknown object will be returned. + # + # source://drb//lib/drb/drb.rb#503 + def reload; end + + class << self + # source://drb//lib/drb/drb.rb#486 + def _load(s); end + end +end + +# An exception wrapping a DRb::DRbUnknown object +# +# source://drb//lib/drb/drb.rb#410 +class DRb::DRbUnknownError < ::DRb::DRbError + # Create a new DRbUnknownError for the DRb::DRbUnknown object +unknown+ + # + # @return [DRbUnknownError] a new instance of DRbUnknownError + # + # source://drb//lib/drb/drb.rb#413 + def initialize(unknown); end + + # source://drb//lib/drb/drb.rb#425 + def _dump(lv); end + + # Get the wrapped DRb::DRbUnknown object. + # + # source://drb//lib/drb/drb.rb#419 + def unknown; end + + class << self + # source://drb//lib/drb/drb.rb#421 + def _load(s); end + end +end + +# source://drb//lib/drb/drb.rb#1199 +class DRb::ThreadObject + include ::MonitorMixin + + # @return [ThreadObject] a new instance of ThreadObject + # + # source://drb//lib/drb/drb.rb#1202 + def initialize(&blk); end + + # source://drb//lib/drb/drb.rb#1237 + def _execute; end + + # @return [Boolean] + # + # source://drb//lib/drb/drb.rb#1213 + def alive?; end + + # source://drb//lib/drb/drb.rb#1217 + def kill; end + + # source://drb//lib/drb/drb.rb#1222 + def method_missing(msg, *arg, &blk); end +end + +# source://drb//lib/drb/version.rb#2 +DRb::VERSION = T.let(T.unsafe(nil), String) + +# source://drb//lib/drb/drb.rb#1943 +DRbIdConv = DRb::DRbIdConv + +# :stopdoc: +# +# source://drb//lib/drb/drb.rb#1941 +DRbObject = DRb::DRbObject + +# source://drb//lib/drb/drb.rb#1942 +DRbUndumped = DRb::DRbUndumped diff --git a/sorbet/rbi/gems/e2mmap@0.1.0.rbi b/sorbet/rbi/gems/e2mmap@0.1.0.rbi index 378360e89..658412d36 100644 --- a/sorbet/rbi/gems/e2mmap@0.1.0.rbi +++ b/sorbet/rbi/gems/e2mmap@0.1.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `e2mmap` gem. # Please instead update this file by running `bin/tapioca gem e2mmap`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/ed25519@1.3.0.rbi b/sorbet/rbi/gems/ed25519@1.3.0.rbi index 6d79fe3d7..b97e7ed35 100644 --- a/sorbet/rbi/gems/ed25519@1.3.0.rbi +++ b/sorbet/rbi/gems/ed25519@1.3.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `ed25519` gem. # Please instead update this file by running `bin/tapioca gem ed25519`. + # The Ed25519 digital signatre algorithm # # source://ed25519//lib/ed25519/version.rb#3 diff --git a/sorbet/rbi/gems/erubi@1.12.0.rbi b/sorbet/rbi/gems/erubi@1.13.0.rbi similarity index 91% rename from sorbet/rbi/gems/erubi@1.12.0.rbi rename to sorbet/rbi/gems/erubi@1.13.0.rbi index c52738faa..16d45faf0 100644 --- a/sorbet/rbi/gems/erubi@1.12.0.rbi +++ b/sorbet/rbi/gems/erubi@1.13.0.rbi @@ -4,14 +4,19 @@ # This is an autogenerated file for types exported from the `erubi` gem. # Please instead update this file by running `bin/tapioca gem erubi`. + # source://erubi//lib/erubi.rb#3 module Erubi + private + + def h(_arg0); end + class << self def h(_arg0); end end end -# source://erubi//lib/erubi.rb#54 +# source://erubi//lib/erubi.rb#51 class Erubi::Engine # Initialize a new Erubi::Engine. Options: # +:bufval+ :: The value to use for the buffer variable, as a string (default '::String.new'). @@ -42,64 +47,64 @@ class Erubi::Engine # # @return [Engine] a new instance of Engine # - # source://erubi//lib/erubi.rb#94 + # source://erubi//lib/erubi.rb#91 def initialize(input, properties = T.unsafe(nil)); end # The variable name used for the buffer variable. # - # source://erubi//lib/erubi.rb#65 + # source://erubi//lib/erubi.rb#62 def bufvar; end # The filename of the template, if one was given. # - # source://erubi//lib/erubi.rb#62 + # source://erubi//lib/erubi.rb#59 def filename; end # The frozen ruby source code generated from the template, which can be evaled. # - # source://erubi//lib/erubi.rb#59 + # source://erubi//lib/erubi.rb#56 def src; end private # Add ruby code to the template # - # source://erubi//lib/erubi.rb#226 + # source://erubi//lib/erubi.rb#223 def add_code(code); end # Add the given ruby expression result to the template, # escaping it based on the indicator given and escape flag. # - # source://erubi//lib/erubi.rb#235 + # source://erubi//lib/erubi.rb#232 def add_expression(indicator, code); end # Add the result of Ruby expression to the template # - # source://erubi//lib/erubi.rb#244 + # source://erubi//lib/erubi.rb#241 def add_expression_result(code); end # Add the escaped result of Ruby expression to the template # - # source://erubi//lib/erubi.rb#249 + # source://erubi//lib/erubi.rb#246 def add_expression_result_escaped(code); end # Add the given postamble to the src. Can be overridden in subclasses # to make additional changes to src that depend on the current state. # - # source://erubi//lib/erubi.rb#255 + # source://erubi//lib/erubi.rb#252 def add_postamble(postamble); end # Add raw text to the template. Modifies argument if argument is mutable as a memory optimization. # Must be called with a string, cannot be called with nil (Rails's subclass depends on it). # - # source://erubi//lib/erubi.rb#213 + # source://erubi//lib/erubi.rb#210 def add_text(text); end # Raise an exception, as the base engine class does not support handling other indicators. # # @raise [ArgumentError] # - # source://erubi//lib/erubi.rb#261 + # source://erubi//lib/erubi.rb#258 def handle(indicator, code, tailch, rspace, lspace); end # Make sure that any current expression has been terminated. @@ -107,7 +112,7 @@ class Erubi::Engine # the chain_appends option is used, expressions may not be # terminated. # - # source://erubi//lib/erubi.rb#289 + # source://erubi//lib/erubi.rb#286 def terminate_expression; end # Make sure the buffer variable is the target of the next append @@ -117,13 +122,13 @@ class Erubi::Engine # This method should only be called if the block will result in # code where << will append to the bufvar. # - # source://erubi//lib/erubi.rb#271 + # source://erubi//lib/erubi.rb#268 def with_buffer; end end # The default regular expression used for scanning. # -# source://erubi//lib/erubi.rb#56 +# source://erubi//lib/erubi.rb#53 Erubi::Engine::DEFAULT_REGEXP = T.let(T.unsafe(nil), Regexp) # source://erubi//lib/erubi.rb#17 diff --git a/sorbet/rbi/gems/et-orbi@1.2.7.rbi b/sorbet/rbi/gems/et-orbi@1.2.11.rbi similarity index 77% rename from sorbet/rbi/gems/et-orbi@1.2.7.rbi rename to sorbet/rbi/gems/et-orbi@1.2.11.rbi index 8b736e7e0..5608eaee3 100644 --- a/sorbet/rbi/gems/et-orbi@1.2.7.rbi +++ b/sorbet/rbi/gems/et-orbi@1.2.11.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `et-orbi` gem. # Please instead update this file by running `bin/tapioca gem et-orbi`. + # source://et-orbi//lib/et-orbi/info.rb#2 module EtOrbi class << self @@ -183,22 +184,22 @@ class EtOrbi::EoTime # source://et-orbi//lib/et-orbi/time.rb#67 def initialize(s, zone); end - # source://et-orbi//lib/et-orbi/time.rb#236 + # source://et-orbi//lib/et-orbi/time.rb#251 def +(t); end - # source://et-orbi//lib/et-orbi/time.rb#237 + # source://et-orbi//lib/et-orbi/time.rb#252 def -(t); end - # source://et-orbi//lib/et-orbi/time.rb#229 + # source://et-orbi//lib/et-orbi/time.rb#244 def <(o); end - # source://et-orbi//lib/et-orbi/time.rb#230 + # source://et-orbi//lib/et-orbi/time.rb#245 def <=(o); end - # source://et-orbi//lib/et-orbi/time.rb#231 + # source://et-orbi//lib/et-orbi/time.rb#246 def <=>(o); end - # source://et-orbi//lib/et-orbi/time.rb#206 + # source://et-orbi//lib/et-orbi/time.rb#221 def ==(o); end # Nota Bene: @@ -210,13 +211,13 @@ class EtOrbi::EoTime # The eql? method returns true if obj and other refer to the same hash key. # This is used by Hash to test members for equality. # - # source://et-orbi//lib/et-orbi/time.rb#227 + # source://et-orbi//lib/et-orbi/time.rb#242 def >(o); end - # source://et-orbi//lib/et-orbi/time.rb#228 + # source://et-orbi//lib/et-orbi/time.rb#243 def >=(o); end - # source://et-orbi//lib/et-orbi/time.rb#233 + # source://et-orbi//lib/et-orbi/time.rb#248 def add(t); end # Returns true if this EoTime instance corresponds to 2 different UTC @@ -227,71 +228,78 @@ class EtOrbi::EoTime # # @return [Boolean] # - # source://et-orbi//lib/et-orbi/time.rb#113 + # source://et-orbi//lib/et-orbi/time.rb#128 def ambiguous?; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def asctime; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#409 + def clone; end + + # source://et-orbi//lib/et-orbi/time.rb#218 def day; end # Returns this ::EtOrbi::EoTime as a ::Time instance # in the current UTC timezone. # - # source://et-orbi//lib/et-orbi/time.rb#127 + # source://et-orbi//lib/et-orbi/time.rb#142 def getgm; end # Returns this ::EtOrbi::EoTime as a ::Time instance # in the current UTC timezone. # - # source://et-orbi//lib/et-orbi/time.rb#127 + # source://et-orbi//lib/et-orbi/time.rb#142 def getutc; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def hour; end - # source://et-orbi//lib/et-orbi/time.rb#319 + # source://et-orbi//lib/et-orbi/time.rb#339 def in_time_zone(zone = T.unsafe(nil)); end - # source://et-orbi//lib/et-orbi/time.rb#302 + # source://et-orbi//lib/et-orbi/time.rb#317 def inc(t, dir = T.unsafe(nil)); end # @return [Boolean] # - # source://et-orbi//lib/et-orbi/time.rb#174 + # source://et-orbi//lib/et-orbi/time.rb#189 def is_dst?; end # @return [Boolean] # - # source://et-orbi//lib/et-orbi/time.rb#174 + # source://et-orbi//lib/et-orbi/time.rb#189 def isdst; end - # source://et-orbi//lib/et-orbi/time.rb#277 + # source://et-orbi//lib/et-orbi/time.rb#292 def iso8601(fraction_digits = T.unsafe(nil)); end - # source://et-orbi//lib/et-orbi/time.rb#319 + # source://et-orbi//lib/et-orbi/time.rb#339 def localtime(zone = T.unsafe(nil)); end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def min; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def month; end - # source://et-orbi//lib/et-orbi/time.rb#242 + # source://et-orbi//lib/et-orbi/time.rb#257 def monthdays; end - # source://et-orbi//lib/et-orbi/time.rb#339 + # "reference week", used in fugit for cron modulo notation + # + # source://et-orbi//lib/et-orbi/time.rb#367 def rday; end - # source://et-orbi//lib/et-orbi/time.rb#345 + # source://et-orbi//lib/et-orbi/time.rb#377 def reach(points); end - # source://et-orbi//lib/et-orbi/time.rb#333 + # "reference week", used in fugit for cron modulo notation + # + # source://et-orbi//lib/et-orbi/time.rb#355 def rweek; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def sec; end # instance methods @@ -299,22 +307,22 @@ class EtOrbi::EoTime # source://et-orbi//lib/et-orbi/time.rb#64 def seconds; end - # source://et-orbi//lib/et-orbi/time.rb#95 + # source://et-orbi//lib/et-orbi/time.rb#103 def seconds=(f); end - # source://et-orbi//lib/et-orbi/time.rb#155 + # source://et-orbi//lib/et-orbi/time.rb#170 def strftime(format); end - # source://et-orbi//lib/et-orbi/time.rb#234 + # source://et-orbi//lib/et-orbi/time.rb#249 def subtract(t); end - # source://et-orbi//lib/et-orbi/time.rb#180 + # source://et-orbi//lib/et-orbi/time.rb#195 def to_debug_s; end - # source://et-orbi//lib/et-orbi/time.rb#145 + # source://et-orbi//lib/et-orbi/time.rb#160 def to_f; end - # source://et-orbi//lib/et-orbi/time.rb#150 + # source://et-orbi//lib/et-orbi/time.rb#165 def to_i; end # Returns this ::EtOrbi::EoTime as a ::Time instance @@ -322,10 +330,10 @@ class EtOrbi::EoTime # # Has a #to_t alias. # - # source://et-orbi//lib/et-orbi/time.rb#167 + # source://et-orbi//lib/et-orbi/time.rb#182 def to_local_time; end - # source://et-orbi//lib/et-orbi/time.rb#267 + # source://et-orbi//lib/et-orbi/time.rb#282 def to_s; end # Returns this ::EtOrbi::EoTime as a ::Time instance @@ -333,37 +341,42 @@ class EtOrbi::EoTime # # Has a #to_t alias. # - # source://et-orbi//lib/et-orbi/time.rb#167 + # source://et-orbi//lib/et-orbi/time.rb#182 def to_t; end - # source://et-orbi//lib/et-orbi/time.rb#297 + # source://et-orbi//lib/et-orbi/time.rb#312 def to_time_s; end # Debug current time by showing local time / delta / utc time # for example: "0120-7(0820)" # - # source://et-orbi//lib/et-orbi/time.rb#286 + # source://et-orbi//lib/et-orbi/time.rb#301 def to_utc_comparison_s; end # Returns this ::EtOrbi::EoTime as a ::Time instance # in the current UTC timezone. # - # source://et-orbi//lib/et-orbi/time.rb#127 + # source://et-orbi//lib/et-orbi/time.rb#142 def to_utc_time; end - # source://et-orbi//lib/et-orbi/time.rb#272 + # source://et-orbi//lib/et-orbi/time.rb#287 def to_zs; end - # source://et-orbi//lib/et-orbi/time.rb#319 + # Nullify the "caches" used by #to_time, #rweek, and others + # + # source://et-orbi//lib/et-orbi/time.rb#96 + def touch; end + + # source://et-orbi//lib/et-orbi/time.rb#339 def translate(zone = T.unsafe(nil)); end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def usec; end # Returns this ::EtOrbi::EoTime as a ::Time instance # in the current UTC timezone. # - # source://et-orbi//lib/et-orbi/time.rb#127 + # source://et-orbi//lib/et-orbi/time.rb#142 def utc; end # Returns true if this ::EtOrbi::EoTime instance timezone is UTC. @@ -371,22 +384,22 @@ class EtOrbi::EoTime # # @return [Boolean] # - # source://et-orbi//lib/et-orbi/time.rb#135 + # source://et-orbi//lib/et-orbi/time.rb#150 def utc?; end - # source://et-orbi//lib/et-orbi/time.rb#195 + # source://et-orbi//lib/et-orbi/time.rb#210 def utc_offset; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def wday; end - # source://et-orbi//lib/et-orbi/time.rb#327 + # source://et-orbi//lib/et-orbi/time.rb#347 def wday_in_month; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def yday; end - # source://et-orbi//lib/et-orbi/time.rb#203 + # source://et-orbi//lib/et-orbi/time.rb#218 def year; end # Returns the value of attribute zone. @@ -394,18 +407,18 @@ class EtOrbi::EoTime # source://et-orbi//lib/et-orbi/time.rb#65 def zone; end - # source://et-orbi//lib/et-orbi/time.rb#101 + # source://et-orbi//lib/et-orbi/time.rb#112 def zone=(z); end protected - # source://et-orbi//lib/et-orbi/time.rb#428 + # source://et-orbi//lib/et-orbi/time.rb#465 def _to_f(o); end - # source://et-orbi//lib/et-orbi/time.rb#389 + # source://et-orbi//lib/et-orbi/time.rb#426 def count_weeks(start, dir); end - # source://et-orbi//lib/et-orbi/time.rb#402 + # source://et-orbi//lib/et-orbi/time.rb#439 def strfz(code); end # Returns a Ruby Time instance. @@ -413,7 +426,7 @@ class EtOrbi::EoTime # Warning: the timezone of that Time instance will be UTC when used with # TZInfo < 2.0.0. # - # source://et-orbi//lib/et-orbi/time.rb#384 + # source://et-orbi//lib/et-orbi/time.rb#421 def to_time; end class << self @@ -443,10 +456,10 @@ class EtOrbi::EoTime end end -# source://et-orbi//lib/et-orbi/time.rb#239 +# source://et-orbi//lib/et-orbi/time.rb#254 EtOrbi::EoTime::DAY_S = T.let(T.unsafe(nil), Integer) -# source://et-orbi//lib/et-orbi/time.rb#240 +# source://et-orbi//lib/et-orbi/time.rb#255 EtOrbi::EoTime::WEEK_S = T.let(T.unsafe(nil), Integer) # source://et-orbi//lib/et-orbi.rb#16 diff --git a/sorbet/rbi/gems/eventmachine@1.2.7.rbi b/sorbet/rbi/gems/eventmachine@1.2.7.rbi index 676266703..9f8e78594 100644 --- a/sorbet/rbi/gems/eventmachine@1.2.7.rbi +++ b/sorbet/rbi/gems/eventmachine@1.2.7.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `eventmachine` gem. # Please instead update this file by running `bin/tapioca gem eventmachine`. + # BufferedTokenizer takes a delimiter upon instantiation, or acts line-based # by default. It allows input to be spoon-fed from some outside source which # receives arbitrary length datagrams which may-or-may-not contain the token diff --git a/sorbet/rbi/gems/execjs@2.8.1.rbi b/sorbet/rbi/gems/execjs@2.9.1.rbi similarity index 67% rename from sorbet/rbi/gems/execjs@2.8.1.rbi rename to sorbet/rbi/gems/execjs@2.9.1.rbi index 236cc3a8b..ac37e0e14 100644 --- a/sorbet/rbi/gems/execjs@2.8.1.rbi +++ b/sorbet/rbi/gems/execjs@2.9.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `execjs` gem. # Please instead update this file by running `bin/tapioca gem execjs`. + # source://execjs//lib/execjs/version.rb#1 module ExecJS class << self @@ -34,7 +35,7 @@ module ExecJS # source://execjs//lib/execjs/module.rb#13 def runtime=(runtime); end - # source://execjs//lib/execjs/runtimes.rb#96 + # source://execjs//lib/execjs/runtimes.rb#108 def runtimes; end # @return [Boolean] @@ -108,104 +109,134 @@ class ExecJS::DuktapeRuntime::Context < ::ExecJS::Runtime::Context def wrap_error(e); end end -# Encodes strings as UTF-8 -# -# source://execjs//lib/execjs/encoding.rb#3 -module ExecJS::Encoding - # workaround for jruby bug http://jira.codehaus.org/browse/JRUBY-6588 - # workaround for rbx bug https://github.com/rubinius/rubinius/issues/1729 - # - # source://execjs//lib/execjs/encoding.rb#21 - def encode(string); end -end - # source://execjs//lib/execjs/module.rb#5 class ExecJS::Error < ::StandardError; end -# source://execjs//lib/execjs/external_runtime.rb#5 +# source://execjs//lib/execjs/external_runtime.rb#6 class ExecJS::ExternalRuntime < ::ExecJS::Runtime # @return [ExternalRuntime] a new instance of ExternalRuntime # - # source://execjs//lib/execjs/external_runtime.rb#92 + # source://execjs//lib/execjs/external_runtime.rb#93 def initialize(options); end # @return [Boolean] # - # source://execjs//lib/execjs/external_runtime.rb#109 + # source://execjs//lib/execjs/external_runtime.rb#116 def available?; end # @return [Boolean] # - # source://execjs//lib/execjs/external_runtime.rb#114 + # source://execjs//lib/execjs/external_runtime.rb#121 def deprecated?; end - # source://execjs//lib/execjs/external_runtime.rb#211 + # source://execjs//lib/execjs/external_runtime.rb#209 def exec_runtime(filename); end # Returns the value of attribute name. # - # source://execjs//lib/execjs/external_runtime.rb#90 + # source://execjs//lib/execjs/external_runtime.rb#91 def name; end protected - # source://execjs//lib/execjs/external_runtime.rb#159 + # source://execjs//lib/execjs/external_runtime.rb#157 def encode_source(source); end - # source://execjs//lib/execjs/external_runtime.rb#164 + # source://execjs//lib/execjs/external_runtime.rb#162 def encode_unicode_codepoints(str); end - # source://execjs//lib/execjs/external_runtime.rb#226 + # source://execjs//lib/execjs/external_runtime.rb#224 def exec_runtime_error(output); end - # source://execjs//lib/execjs/external_runtime.rb#145 - def generate_compile_method(path); end - - # source://execjs//lib/execjs/external_runtime.rb#155 + # source://execjs//lib/execjs/external_runtime.rb#153 def json2_source; end - # source://execjs//lib/execjs/external_runtime.rb#235 + # source://execjs//lib/execjs/external_runtime.rb#233 def which(command); end private - # source://execjs//lib/execjs/external_runtime.rb#119 + # source://execjs//lib/execjs/external_runtime.rb#126 def binary; end - # source://execjs//lib/execjs/external_runtime.rb#123 + # source://execjs//lib/execjs/external_runtime.rb#130 def locate_executable(command); end end -# source://execjs//lib/execjs/external_runtime.rb#6 +# source://execjs//lib/execjs/external_runtime.rb#7 class ExecJS::ExternalRuntime::Context < ::ExecJS::Runtime::Context # @return [Context] a new instance of Context # - # source://execjs//lib/execjs/external_runtime.rb#7 + # source://execjs//lib/execjs/external_runtime.rb#8 def initialize(runtime, source = T.unsafe(nil), options = T.unsafe(nil)); end - # source://execjs//lib/execjs/external_runtime.rb#45 + # source://execjs//lib/execjs/external_runtime.rb#46 def call(identifier, *args); end - # source://execjs//lib/execjs/external_runtime.rb#17 + # source://execjs//lib/execjs/external_runtime.rb#18 def eval(source, options = T.unsafe(nil)); end - # source://execjs//lib/execjs/external_runtime.rb#25 + # source://execjs//lib/execjs/external_runtime.rb#26 def exec(source, options = T.unsafe(nil)); end protected # See Tempfile.create on Ruby 2.1 # - # source://execjs//lib/execjs/external_runtime.rb#51 + # source://execjs//lib/execjs/external_runtime.rb#52 def create_tempfile(basename); end - # source://execjs//lib/execjs/external_runtime.rb#67 + # source://execjs//lib/execjs/external_runtime.rb#68 def extract_result(output, filename); end - # source://execjs//lib/execjs/external_runtime.rb#60 + # source://execjs//lib/execjs/external_runtime.rb#61 def write_to_tempfile(contents); end end +# source://execjs//lib/execjs/graaljs_runtime.rb#4 +class ExecJS::GraalJSRuntime < ::ExecJS::Runtime + # @return [Boolean] + # + # source://execjs//lib/execjs/graaljs_runtime.rb#125 + def available?; end + + # source://execjs//lib/execjs/graaljs_runtime.rb#121 + def name; end +end + +# source://execjs//lib/execjs/graaljs_runtime.rb#5 +class ExecJS::GraalJSRuntime::Context < ::ExecJS::Runtime::Context + # @return [Context] a new instance of Context + # + # source://execjs//lib/execjs/graaljs_runtime.rb#6 + def initialize(runtime, source = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://execjs//lib/execjs/graaljs_runtime.rb#37 + def call(source, *args); end + + # source://execjs//lib/execjs/graaljs_runtime.rb#28 + def eval(source, options = T.unsafe(nil)); end + + def eval_in_context(code); end + + # source://execjs//lib/execjs/graaljs_runtime.rb#19 + def exec(source, options = T.unsafe(nil)); end + + private + + # source://execjs//lib/execjs/graaljs_runtime.rb#64 + def convert_js_to_ruby(value); end + + # source://execjs//lib/execjs/graaljs_runtime.rb#97 + def convert_ruby_to_js(value); end + + # source://execjs//lib/execjs/graaljs_runtime.rb#51 + def translate; end +end + +# source://execjs//lib/execjs/graaljs_runtime.rb#49 +ExecJS::GraalJSRuntime::Context::ForeignException = RuntimeError + # source://execjs//lib/execjs/mini_racer_runtime.rb#4 class ExecJS::MiniRacerRuntime < ::ExecJS::Runtime # @return [Boolean] @@ -245,87 +276,85 @@ end # source://execjs//lib/execjs/module.rb#7 class ExecJS::ProgramError < ::ExecJS::Error; end -# source://execjs//lib/execjs/ruby_rhino_runtime.rb#4 +# source://execjs//lib/execjs/ruby_rhino_runtime.rb#5 class ExecJS::RubyRhinoRuntime < ::ExecJS::Runtime # @return [Boolean] # - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#90 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#95 def available?; end - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#86 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#91 def name; end end -# source://execjs//lib/execjs/ruby_rhino_runtime.rb#5 +# source://execjs//lib/execjs/ruby_rhino_runtime.rb#6 class ExecJS::RubyRhinoRuntime::Context < ::ExecJS::Runtime::Context # @return [Context] a new instance of Context # - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#6 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#7 def initialize(runtime, source = T.unsafe(nil), options = T.unsafe(nil)); end - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#34 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#35 def call(properties, *args); end - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#24 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#25 def eval(source, options = T.unsafe(nil)); end - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#16 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#17 def exec(source, options = T.unsafe(nil)); end - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#40 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#45 def unbox(value); end - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#61 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#66 def wrap_error(e); end private # Disables bytecode compiling which limits you to 64K scripts # - # source://execjs//lib/execjs/ruby_rhino_runtime.rb#77 + # source://execjs//lib/execjs/ruby_rhino_runtime.rb#82 def fix_memory_limit!(context); end end # Abstract base class for runtimes # -# source://execjs//lib/execjs/runtime.rb#5 +# source://execjs//lib/execjs/runtime.rb#3 class ExecJS::Runtime # @raise [NotImplementedError] # @return [Boolean] # - # source://execjs//lib/execjs/runtime.rb#80 + # source://execjs//lib/execjs/runtime.rb#76 def available?; end - # source://execjs//lib/execjs/runtime.rb#68 + # source://execjs//lib/execjs/runtime.rb#64 def compile(source, options = T.unsafe(nil)); end - # source://execjs//lib/execjs/runtime.rb#44 + # source://execjs//lib/execjs/runtime.rb#40 def context_class; end # @return [Boolean] # - # source://execjs//lib/execjs/runtime.rb#76 + # source://execjs//lib/execjs/runtime.rb#72 def deprecated?; end - # source://execjs//lib/execjs/runtime.rb#58 + # source://execjs//lib/execjs/runtime.rb#54 def eval(source, options = T.unsafe(nil)); end - # source://execjs//lib/execjs/runtime.rb#48 + # source://execjs//lib/execjs/runtime.rb#44 def exec(source, options = T.unsafe(nil)); end # @raise [NotImplementedError] # - # source://execjs//lib/execjs/runtime.rb#40 + # source://execjs//lib/execjs/runtime.rb#36 def name; end end -# source://execjs//lib/execjs/runtime.rb#6 +# source://execjs//lib/execjs/runtime.rb#4 class ExecJS::Runtime::Context - include ::ExecJS::Encoding - # @return [Context] a new instance of Context # - # source://execjs//lib/execjs/runtime.rb#9 + # source://execjs//lib/execjs/runtime.rb#5 def initialize(runtime, source = T.unsafe(nil), options = T.unsafe(nil)); end # Evaluates +source+ as an expression (which should be of type @@ -337,7 +366,7 @@ class ExecJS::Runtime::Context # # @raise [NotImplementedError] # - # source://execjs//lib/execjs/runtime.rb#35 + # source://execjs//lib/execjs/runtime.rb#31 def call(source, *args); end # Evaluates the +source+ as an expression and returns the result. @@ -347,7 +376,7 @@ class ExecJS::Runtime::Context # # @raise [NotImplementedError] # - # source://execjs//lib/execjs/runtime.rb#25 + # source://execjs//lib/execjs/runtime.rb#21 def eval(source, options = T.unsafe(nil)); end # Evaluates the +source+ in the context of a function body and returns the @@ -358,7 +387,7 @@ class ExecJS::Runtime::Context # # @raise [NotImplementedError] # - # source://execjs//lib/execjs/runtime.rb#17 + # source://execjs//lib/execjs/runtime.rb#13 def exec(source, options = T.unsafe(nil)); end end @@ -368,54 +397,60 @@ class ExecJS::RuntimeError < ::ExecJS::Error; end # source://execjs//lib/execjs/module.rb#8 class ExecJS::RuntimeUnavailable < ::ExecJS::RuntimeError; end -# source://execjs//lib/execjs/runtimes.rb#9 +# source://execjs//lib/execjs/runtimes.rb#10 module ExecJS::Runtimes class << self - # source://execjs//lib/execjs/runtimes.rb#56 + # source://execjs//lib/execjs/runtimes.rb#66 def autodetect; end - # source://execjs//lib/execjs/runtimes.rb#62 + # source://execjs//lib/execjs/runtimes.rb#72 def best_available; end - # source://execjs//lib/execjs/runtimes.rb#66 + # source://execjs//lib/execjs/runtimes.rb#76 def from_environment; end - # source://execjs//lib/execjs/runtimes.rb#78 + # source://execjs//lib/execjs/runtimes.rb#88 def names; end - # source://execjs//lib/execjs/runtimes.rb#82 + # source://execjs//lib/execjs/runtimes.rb#92 def runtimes; end end end -# source://execjs//lib/execjs/runtimes.rb#10 +# source://execjs//lib/execjs/runtimes.rb#28 +ExecJS::Runtimes::Bun = T.let(T.unsafe(nil), ExecJS::ExternalRuntime) + +# source://execjs//lib/execjs/runtimes.rb#11 ExecJS::Runtimes::Disabled = T.let(T.unsafe(nil), ExecJS::DisabledRuntime) -# source://execjs//lib/execjs/runtimes.rb#12 +# source://execjs//lib/execjs/runtimes.rb#13 ExecJS::Runtimes::Duktape = T.let(T.unsafe(nil), ExecJS::DuktapeRuntime) -# source://execjs//lib/execjs/runtimes.rb#41 +# source://execjs//lib/execjs/runtimes.rb#17 +ExecJS::Runtimes::GraalJS = T.let(T.unsafe(nil), ExecJS::GraalJSRuntime) + +# source://execjs//lib/execjs/runtimes.rb#51 ExecJS::Runtimes::JScript = T.let(T.unsafe(nil), ExecJS::ExternalRuntime) -# source://execjs//lib/execjs/runtimes.rb#25 +# source://execjs//lib/execjs/runtimes.rb#35 ExecJS::Runtimes::JavaScriptCore = T.let(T.unsafe(nil), ExecJS::ExternalRuntime) -# source://execjs//lib/execjs/runtimes.rb#16 +# source://execjs//lib/execjs/runtimes.rb#19 ExecJS::Runtimes::MiniRacer = T.let(T.unsafe(nil), ExecJS::MiniRacerRuntime) -# source://execjs//lib/execjs/runtimes.rb#18 +# source://execjs//lib/execjs/runtimes.rb#21 ExecJS::Runtimes::Node = T.let(T.unsafe(nil), ExecJS::ExternalRuntime) -# source://execjs//lib/execjs/runtimes.rb#14 +# source://execjs//lib/execjs/runtimes.rb#15 ExecJS::Runtimes::RubyRhino = T.let(T.unsafe(nil), ExecJS::RubyRhinoRuntime) -# source://execjs//lib/execjs/runtimes.rb#34 +# source://execjs//lib/execjs/runtimes.rb#44 ExecJS::Runtimes::SpiderMonkey = T.let(T.unsafe(nil), ExecJS::ExternalRuntime) -# source://execjs//lib/execjs/runtimes.rb#34 +# source://execjs//lib/execjs/runtimes.rb#44 ExecJS::Runtimes::Spidermonkey = T.let(T.unsafe(nil), ExecJS::ExternalRuntime) -# source://execjs//lib/execjs/runtimes.rb#48 +# source://execjs//lib/execjs/runtimes.rb#58 ExecJS::Runtimes::V8 = T.let(T.unsafe(nil), ExecJS::ExternalRuntime) # source://execjs//lib/execjs/version.rb#2 diff --git a/sorbet/rbi/gems/factory_bot@6.2.1.rbi b/sorbet/rbi/gems/factory_bot@6.4.6.rbi similarity index 93% rename from sorbet/rbi/gems/factory_bot@6.2.1.rbi rename to sorbet/rbi/gems/factory_bot@6.4.6.rbi index 782f060f8..fae431df5 100644 --- a/sorbet/rbi/gems/factory_bot@6.2.1.rbi +++ b/sorbet/rbi/gems/factory_bot@6.4.6.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `factory_bot` gem. # Please instead update this file by running `bin/tapioca gem factory_bot`. + # source://factory_bot//lib/factory_bot/internal.rb#1 module FactoryBot extend ::FactoryBot::Syntax::Methods @@ -74,16 +75,16 @@ module FactoryBot def lint(*args); end # source://factory_bot//lib/factory_bot.rb#83 - def register_strategy(*_arg0, **_arg1, &_arg2); end + def register_strategy(strategy_name, strategy_class, &_arg2); end # source://factory_bot//lib/factory_bot/reload.rb#2 def reload; end # source://factory_bot//lib/factory_bot.rb#83 - def rewind_sequences(*_arg0, **_arg1, &_arg2); end + def rewind_sequences(&_arg0); end # source://factory_bot//lib/factory_bot.rb#83 - def strategy_by_name(*_arg0, **_arg1, &_arg2); end + def strategy_by_name(name, &_arg1); end # source://factory_bot//lib/factory_bot.rb#54 def use_parent_strategy; end @@ -692,21 +693,21 @@ class FactoryBot::Decorator < ::BasicObject # source://factory_bot//lib/factory_bot/decorator.rb#5 def initialize(component); end - # source://factory_bot//lib/factory_bot/decorator.rb#11 + # source://factory_bot//lib/factory_bot/decorator.rb#9 def method_missing(*_arg0, **_arg1, &_arg2); end - # source://factory_bot//lib/factory_bot/decorator.rb#15 + # source://factory_bot//lib/factory_bot/decorator.rb#13 def send(*_arg0, **_arg1, &_arg2); end private # @return [Boolean] # - # source://factory_bot//lib/factory_bot/decorator.rb#29 + # source://factory_bot//lib/factory_bot/decorator.rb#17 def respond_to_missing?(name, include_private = T.unsafe(nil)); end class << self - # source://factory_bot//lib/factory_bot/decorator.rb#33 + # source://factory_bot//lib/factory_bot/decorator.rb#21 def const_missing(name); end end end @@ -760,52 +761,52 @@ class FactoryBot::Definition # @api private # @return [Definition] a new instance of Definition # - # source://factory_bot//lib/factory_bot/definition.rb#6 + # source://factory_bot//lib/factory_bot/definition.rb#7 def initialize(name, base_traits = T.unsafe(nil)); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#76 + # source://factory_bot//lib/factory_bot/definition.rb#86 def add_callback(callback); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#100 + # source://factory_bot//lib/factory_bot/definition.rb#110 def after(*names, &block); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#72 + # source://factory_bot//lib/factory_bot/definition.rb#82 def append_traits(new_traits); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#23 + # source://factory_bot//lib/factory_bot/definition.rb#24 def attributes; end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#96 + # source://factory_bot//lib/factory_bot/definition.rb#106 def before(*names, &block); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#104 + # source://factory_bot//lib/factory_bot/definition.rb#114 def callback(*names, &block); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#44 + # source://factory_bot//lib/factory_bot/definition.rb#45 def callbacks; end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#48 + # source://factory_bot//lib/factory_bot/definition.rb#49 def compile(klass = T.unsafe(nil)); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#40 + # source://factory_bot//lib/factory_bot/definition.rb#41 def constructor; end # @api private @@ -813,17 +814,17 @@ class FactoryBot::Definition # source://factory_bot//lib/factory_bot/definition.rb#4 def declarations; end - # source://factory_bot//lib/factory_bot/definition.rb#21 + # source://factory_bot//lib/factory_bot/definition.rb#22 def declare_attribute(*_arg0, **_arg1, &_arg2); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#92 + # source://factory_bot//lib/factory_bot/definition.rb#102 def define_constructor(&block); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#84 + # source://factory_bot//lib/factory_bot/definition.rb#94 def define_trait(trait); end # @api private @@ -833,9 +834,19 @@ class FactoryBot::Definition # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#68 + # source://factory_bot//lib/factory_bot/definition.rb#78 def inherit_traits(new_traits); end + # @api private + # + # source://factory_bot//lib/factory_bot/definition.rb#5 + def klass; end + + # @api private + # + # source://factory_bot//lib/factory_bot/definition.rb#5 + def klass=(_arg0); end + # @api private # # source://factory_bot//lib/factory_bot/definition.rb#4 @@ -843,12 +854,12 @@ class FactoryBot::Definition # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#63 + # source://factory_bot//lib/factory_bot/definition.rb#73 def overridable; end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#88 + # source://factory_bot//lib/factory_bot/definition.rb#98 def register_enum(enum); end # @api private @@ -858,65 +869,65 @@ class FactoryBot::Definition # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#80 + # source://factory_bot//lib/factory_bot/definition.rb#90 def skip_create; end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#32 + # source://factory_bot//lib/factory_bot/definition.rb#33 def to_create(&block); end private # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#130 + # source://factory_bot//lib/factory_bot/definition.rb#151 def additional_traits; end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#150 + # source://factory_bot//lib/factory_bot/definition.rb#171 def aggregate_from_traits_and_self(method_name, &block); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#175 + # source://factory_bot//lib/factory_bot/definition.rb#196 def automatically_register_defined_enums(klass); end # @api private # @return [Boolean] # - # source://factory_bot//lib/factory_bot/definition.rb#179 + # source://factory_bot//lib/factory_bot/definition.rb#200 def automatically_register_defined_enums?(klass); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#112 + # source://factory_bot//lib/factory_bot/definition.rb#122 def base_traits; end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#118 + # source://factory_bot//lib/factory_bot/definition.rb#131 def error_with_definition_name(error); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#160 + # source://factory_bot//lib/factory_bot/definition.rb#181 def expand_enum_traits(klass); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#143 + # source://factory_bot//lib/factory_bot/definition.rb#164 def initialize_copy(source); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#134 + # source://factory_bot//lib/factory_bot/definition.rb#155 def trait_by_name(name); end # @api private # - # source://factory_bot//lib/factory_bot/definition.rb#138 + # source://factory_bot//lib/factory_bot/definition.rb#159 def trait_for(name); end end @@ -1072,7 +1083,7 @@ class FactoryBot::DefinitionProxy # Except that no globally available sequence will be defined. # # source://factory_bot//lib/factory_bot/definition_proxy.rb#122 - def sequence(name, *args, &block); end + def sequence(name, *_arg1, **_arg2, &_arg3); end # @raise [FactoryBot::MethodDefinitionError] # @@ -1199,25 +1210,23 @@ class FactoryBot::Enum def enum_values(klass); end end -# source://factory_bot//lib/factory_bot/evaluation.rb#4 +# source://factory_bot//lib/factory_bot/evaluation.rb#2 class FactoryBot::Evaluation - include ::Observable - # @return [Evaluation] a new instance of Evaluation # - # source://factory_bot//lib/factory_bot/evaluation.rb#7 - def initialize(evaluator, attribute_assigner, to_create); end + # source://factory_bot//lib/factory_bot/evaluation.rb#3 + def initialize(evaluator, attribute_assigner, to_create, observer); end - # source://factory_bot//lib/factory_bot/evaluation.rb#15 + # source://factory_bot//lib/factory_bot/evaluation.rb#12 def create(result_instance); end - # source://factory_bot//lib/factory_bot/evaluation.rb#13 + # source://factory_bot//lib/factory_bot/evaluation.rb#10 def hash(*_arg0, **_arg1, &_arg2); end - # source://factory_bot//lib/factory_bot/evaluation.rb#22 + # source://factory_bot//lib/factory_bot/evaluation.rb#19 def notify(name, result_instance); end - # source://factory_bot//lib/factory_bot/evaluation.rb#13 + # source://factory_bot//lib/factory_bot/evaluation.rb#10 def object(*_arg0, **_arg1, &_arg2); end end @@ -1233,7 +1242,7 @@ class FactoryBot::Evaluator # @api private # - # source://factory_bot//lib/factory_bot/evaluator.rb#51 + # source://factory_bot//lib/factory_bot/evaluator.rb#50 def __override_names__; end # @api private @@ -1252,7 +1261,7 @@ class FactoryBot::Evaluator # @api private # - # source://factory_bot//lib/factory_bot/evaluator.rb#55 + # source://factory_bot//lib/factory_bot/evaluator.rb#54 def increment_sequence(sequence); end # @api private @@ -1268,20 +1277,20 @@ class FactoryBot::Evaluator # @api private # # source://factory_bot//lib/factory_bot/evaluator.rb#38 - def method_missing(method_name, *args, **_arg2, &block); end + def method_missing(method_name, *_arg1, **_arg2, &_arg3); end private # @api private # @return [Boolean] # - # source://factory_bot//lib/factory_bot/evaluator.rb#47 + # source://factory_bot//lib/factory_bot/evaluator.rb#46 def respond_to_missing?(method_name, _include_private = T.unsafe(nil)); end class << self # @api private # - # source://factory_bot//lib/factory_bot/evaluator.rb#59 + # source://factory_bot//lib/factory_bot/evaluator.rb#58 def attribute_list; end # source://factory_bot//lib/factory_bot/evaluator.rb#7 @@ -1295,7 +1304,7 @@ class FactoryBot::Evaluator # @api private # - # source://factory_bot//lib/factory_bot/evaluator.rb#67 + # source://factory_bot//lib/factory_bot/evaluator.rb#66 def define_attribute(name, &block); end end end @@ -1603,7 +1612,7 @@ module FactoryBot::Internal # @api private # # source://factory_bot//lib/factory_bot/internal.rb#42 - def trait_by_name(name); end + def trait_by_name(name, klass); end # source://factory_bot//lib/factory_bot/internal.rb#5 def traits(*_arg0, **_arg1, &_arg2); end @@ -1810,6 +1819,9 @@ class FactoryBot::Registry # source://factory_bot//lib/factory_bot/registry.rb#40 def key_error_with_custom_message(key_error); end + + # source://factory_bot//lib/factory_bot/registry.rb#50 + def new_key_error(message, key_error); end end # Sequences are defined using sequence within a FactoryBot.define block. @@ -1953,33 +1965,38 @@ class FactoryBot::Strategy::Stub private - # source://factory_bot//lib/factory_bot/strategy/stub.rb#86 + # source://factory_bot//lib/factory_bot/strategy/stub.rb#98 def clear_changes_information(result_instance); end # @return [Boolean] # - # source://factory_bot//lib/factory_bot/strategy/stub.rb#81 + # source://factory_bot//lib/factory_bot/strategy/stub.rb#85 def has_settable_id?(result_instance); end # @return [Boolean] # - # source://factory_bot//lib/factory_bot/strategy/stub.rb#102 + # source://factory_bot//lib/factory_bot/strategy/stub.rb#114 def missing_created_at?(result_instance); end # @return [Boolean] # - # source://factory_bot//lib/factory_bot/strategy/stub.rb#108 + # source://factory_bot//lib/factory_bot/strategy/stub.rb#120 def missing_updated_at?(result_instance); end # source://factory_bot//lib/factory_bot/strategy/stub.rb#50 - def next_id; end + def next_id(result_instance); end - # source://factory_bot//lib/factory_bot/strategy/stub.rb#92 + # source://factory_bot//lib/factory_bot/strategy/stub.rb#104 def set_timestamps(result_instance); end - # source://factory_bot//lib/factory_bot/strategy/stub.rb#54 + # source://factory_bot//lib/factory_bot/strategy/stub.rb#58 def stub_database_interaction_on_result(result_instance); end + # @return [Boolean] + # + # source://factory_bot//lib/factory_bot/strategy/stub.rb#91 + def uuid_primary_key?(result_instance); end + class << self # source://factory_bot//lib/factory_bot/strategy/stub.rb#27 def next_id=(id); end @@ -2095,7 +2112,7 @@ class FactoryBot::Syntax::Default::DSL def initialize_with(*_arg0, **_arg1, &_arg2); end # source://factory_bot//lib/factory_bot/syntax/default.rb#28 - def sequence(name, *args, &block); end + def sequence(name, *_arg1, **_arg2, &_arg3); end # source://factory_bot//lib/factory_bot/syntax/default.rb#40 def skip_create(*_arg0, **_arg1, &_arg2); end @@ -2324,6 +2341,12 @@ class FactoryBot::Trait # source://factory_bot//lib/factory_bot/trait.rb#4 def definition; end + # source://factory_bot//lib/factory_bot/trait.rb#17 + def klass(*_arg0, **_arg1, &_arg2); end + + # source://factory_bot//lib/factory_bot/trait.rb#17 + def klass=(arg); end + # @api private # # source://factory_bot//lib/factory_bot/trait.rb#4 diff --git a/sorbet/rbi/gems/factory_bot_rails@6.2.0.rbi b/sorbet/rbi/gems/factory_bot_rails@6.4.3.rbi similarity index 85% rename from sorbet/rbi/gems/factory_bot_rails@6.2.0.rbi rename to sorbet/rbi/gems/factory_bot_rails@6.4.3.rbi index 268407d20..95fc73e31 100644 --- a/sorbet/rbi/gems/factory_bot_rails@6.2.0.rbi +++ b/sorbet/rbi/gems/factory_bot_rails@6.4.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `factory_bot_rails` gem. # Please instead update this file by running `bin/tapioca gem factory_bot_rails`. + # source://factory_bot_rails//lib/factory_bot_rails/generators/rspec_generator.rb#1 module FactoryBotRails; end @@ -26,6 +27,25 @@ class FactoryBotRails::DefinitionFilePaths def files; end end +# source://factory_bot_rails//lib/factory_bot_rails/factory_validator.rb#2 +class FactoryBotRails::FactoryValidator + # @return [FactoryValidator] a new instance of FactoryValidator + # + # source://factory_bot_rails//lib/factory_bot_rails/factory_validator.rb#3 + def initialize(validators = T.unsafe(nil)); end + + # source://factory_bot_rails//lib/factory_bot_rails/factory_validator.rb#7 + def add_validator(validator); end + + # source://factory_bot_rails//lib/factory_bot_rails/factory_validator.rb#11 + def run; end + + private + + # source://factory_bot_rails//lib/factory_bot_rails/factory_validator.rb#17 + def validate_compiled_factory; end +end + # source://factory_bot_rails//lib/factory_bot_rails/generator.rb#6 class FactoryBotRails::Generator # @return [Generator] a new instance of Generator @@ -75,7 +95,7 @@ class FactoryBotRails::Generators::NullGenerator # @return [NullGenerator] a new instance of NullGenerator # # source://factory_bot_rails//lib/factory_bot_rails/generators/null_generator.rb#4 - def initialize(generators); end + def initialize(*_arg0); end # source://factory_bot_rails//lib/factory_bot_rails/generators/null_generator.rb#7 def run; end @@ -103,11 +123,11 @@ class FactoryBotRails::Generators::RSpecGenerator def fixture_replacement_setting; end end -# source://factory_bot_rails//lib/factory_bot_rails/railtie.rb#9 +# source://factory_bot_rails//lib/factory_bot_rails/railtie.rb#10 class FactoryBotRails::Railtie < ::Rails::Railtie private - # source://factory_bot_rails//lib/factory_bot_rails/railtie.rb#28 + # source://factory_bot_rails//lib/factory_bot_rails/railtie.rb#31 def definition_file_paths; end end diff --git a/sorbet/rbi/gems/faraday-em_http@1.0.0.rbi b/sorbet/rbi/gems/faraday-em_http@1.0.0.rbi index 85ae7f9eb..ec8be2bb3 100644 --- a/sorbet/rbi/gems/faraday-em_http@1.0.0.rbi +++ b/sorbet/rbi/gems/faraday-em_http@1.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-em_http` gem. # Please instead update this file by running `bin/tapioca gem faraday-em_http`. + # source://faraday-em_http//lib/faraday/adapter/em_http.rb#3 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # EventMachine adapter. This adapter is useful for either asynchronous # requests when in an EM reactor loop, or for making parallel requests in # synchronous code. @@ -215,15 +213,6 @@ module Faraday::Adapter::EMHttp::Options def request_options(env); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - # Main Faraday::EmHttp module # # source://faraday-em_http//lib/faraday/em_http/version.rb#4 @@ -231,27 +220,3 @@ module Faraday::EmHttp; end # source://faraday-em_http//lib/faraday/em_http/version.rb#5 Faraday::EmHttp::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-em_synchrony@1.0.0.rbi b/sorbet/rbi/gems/faraday-em_synchrony@1.0.0.rbi index 48c58f60d..4fc9a7712 100644 --- a/sorbet/rbi/gems/faraday-em_synchrony@1.0.0.rbi +++ b/sorbet/rbi/gems/faraday-em_synchrony@1.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-em_synchrony` gem. # Please instead update this file by running `bin/tapioca gem faraday-em_synchrony`. + # source://faraday-em_synchrony//lib/faraday/adapter/em_synchrony.rb#5 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # EventMachine Synchrony adapter. # # source://faraday-em_synchrony//lib/faraday/adapter/em_synchrony.rb#8 @@ -119,15 +117,6 @@ class Faraday::Adapter::EMSynchrony < ::Faraday::Adapter end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - # Main Faraday::EmSynchrony module # # source://faraday-em_synchrony//lib/faraday/em_synchrony/version.rb#4 @@ -135,27 +124,3 @@ module Faraday::EmSynchrony; end # source://faraday-em_synchrony//lib/faraday/em_synchrony/version.rb#5 Faraday::EmSynchrony::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-excon@1.1.0.rbi b/sorbet/rbi/gems/faraday-excon@1.1.0.rbi index c49d1f1f7..9b9aae583 100644 --- a/sorbet/rbi/gems/faraday-excon@1.1.0.rbi +++ b/sorbet/rbi/gems/faraday-excon@1.1.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-excon` gem. # Please instead update this file by running `bin/tapioca gem faraday-excon`. + # source://faraday-excon//lib/faraday/adapter/excon.rb#3 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # Excon adapter. # # source://faraday-excon//lib/faraday/adapter/excon.rb#6 @@ -129,15 +127,6 @@ end # source://faraday-excon//lib/faraday/adapter/excon.rb#69 Faraday::Adapter::Excon::OPTS_KEYS = T.let(T.unsafe(nil), Array) -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - # Main Faraday::Excon module # # source://faraday-excon//lib/faraday/excon/version.rb#4 @@ -145,27 +134,3 @@ module Faraday::Excon; end # source://faraday-excon//lib/faraday/excon/version.rb#5 Faraday::Excon::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-httpclient@1.0.1.rbi b/sorbet/rbi/gems/faraday-httpclient@1.0.1.rbi index 61124b293..3b652c2ab 100644 --- a/sorbet/rbi/gems/faraday-httpclient@1.0.1.rbi +++ b/sorbet/rbi/gems/faraday-httpclient@1.0.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-httpclient` gem. # Please instead update this file by running `bin/tapioca gem faraday-httpclient`. + # source://faraday-httpclient//lib/faraday/adapter/httpclient.rb#3 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # This class provides the main implementation for your adapter. # There are some key responsibilities that your adapter should satisfy: # * Initialize and store internally the client you chose (e.g. Net::HTTP) @@ -138,18 +136,6 @@ class Faraday::Adapter::HTTPClient < ::Faraday::Adapter def ssl_verify_mode(ssl); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - # Main Faraday::HTTPClient module # # source://faraday-httpclient//lib/faraday/httpclient/version.rb#4 @@ -157,24 +143,3 @@ module Faraday::HTTPClient; end # source://faraday-httpclient//lib/faraday/httpclient/version.rb#5 Faraday::HTTPClient::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-multipart@1.0.4.rbi b/sorbet/rbi/gems/faraday-multipart@1.0.4.rbi index 1d6f4f68d..b487c10e8 100644 --- a/sorbet/rbi/gems/faraday-multipart@1.0.4.rbi +++ b/sorbet/rbi/gems/faraday-multipart@1.0.4.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-multipart` gem. # Please instead update this file by running `bin/tapioca gem faraday-multipart`. + # source://faraday-multipart//lib/faraday/multipart/version.rb#3 module Faraday class << self @@ -62,9 +63,6 @@ module Faraday end end -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - # source://faraday-multipart//lib/faraday/multipart.rb#18 Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO @@ -73,12 +71,6 @@ Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO # source://faraday-multipart//lib/faraday/multipart.rb#15 Faraday::FilePart = Multipart::Post::UploadIO -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - # Main Faraday::Multipart module. # # source://faraday-multipart//lib/faraday/multipart/version.rb#5 @@ -260,14 +252,8 @@ Faraday::ParamPart = Faraday::Multipart::ParamPart # source://faraday-multipart//lib/faraday/multipart.rb#17 Faraday::Parts = Multipart::Post::Parts -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - # multipart-post v2.2.0 introduces a new class hierarchy for classes like Parts and UploadIO # For backwards compatibility, detect the gem version and use the right class # # source://faraday-multipart//lib/faraday/multipart.rb#21 Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-net_http@1.0.1.rbi b/sorbet/rbi/gems/faraday-net_http@1.0.2.rbi similarity index 76% rename from sorbet/rbi/gems/faraday-net_http@1.0.1.rbi rename to sorbet/rbi/gems/faraday-net_http@1.0.2.rbi index 406e7404e..a3714def7 100644 --- a/sorbet/rbi/gems/faraday-net_http@1.0.1.rbi +++ b/sorbet/rbi/gems/faraday-net_http@1.0.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-net_http` gem. # Please instead update this file by running `bin/tapioca gem faraday-net_http`. + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#12 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#14 class Faraday::Adapter::NetHttp < ::Faraday::Adapter # @return [NetHttp] a new instance of NetHttp @@ -98,80 +96,47 @@ class Faraday::Adapter::NetHttp < ::Faraday::Adapter # source://faraday-net_http//lib/faraday/adapter/net_http.rb#42 def build_connection(env); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#62 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#61 def call(env); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#50 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#49 def net_http_connection(env); end private - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#173 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#172 def configure_request(http, req); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#157 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#156 def configure_ssl(http, ssl); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#89 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#88 def create_request(env); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#105 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#104 def perform_request(http, env); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#135 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#134 def request_via_get_method(http, env, &block); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#143 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#142 def request_via_request_method(http, env, &block); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#126 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#125 def request_with_wrapped_block(http, env, &block); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#193 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#192 def ssl_cert_store(ssl); end - # source://faraday-net_http//lib/faraday/adapter/net_http.rb#202 + # source://faraday-net_http//lib/faraday/adapter/net_http.rb#201 def ssl_verify_mode(ssl); end end # source://faraday-net_http//lib/faraday/adapter/net_http.rb#35 Faraday::Adapter::NetHttp::NET_HTTP_EXCEPTIONS = T.let(T.unsafe(nil), Array) -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - # source://faraday-net_http//lib/faraday/net_http/version.rb#4 module Faraday::NetHttp; end # source://faraday-net_http//lib/faraday/net_http/version.rb#5 Faraday::NetHttp::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-net_http_persistent@1.2.0.rbi b/sorbet/rbi/gems/faraday-net_http_persistent@1.2.0.rbi index 5770e316e..70768476b 100644 --- a/sorbet/rbi/gems/faraday-net_http_persistent@1.2.0.rbi +++ b/sorbet/rbi/gems/faraday-net_http_persistent@1.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-net_http_persistent` gem. # Please instead update this file by running `bin/tapioca gem faraday-net_http_persistent`. + # source://faraday-net_http_persistent//lib/faraday/adapter/net_http_persistent.rb#3 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # Net::HTTP::Persistent adapter. # # source://faraday-net_http_persistent//lib/faraday/adapter/net_http_persistent.rb#6 @@ -113,41 +111,8 @@ end # source://faraday-net_http_persistent//lib/faraday/adapter/net_http_persistent.rb#85 Faraday::Adapter::NetHttpPersistent::SSL_CONFIGURATIONS = T.let(T.unsafe(nil), Hash) -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - # source://faraday-net_http_persistent//lib/faraday/net_http_persistent/version.rb#4 module Faraday::NetHttpPersistent; end # source://faraday-net_http_persistent//lib/faraday/net_http_persistent/version.rb#5 Faraday::NetHttpPersistent::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-patron@1.0.0.rbi b/sorbet/rbi/gems/faraday-patron@1.0.0.rbi index 8af8e93b8..2064f7b69 100644 --- a/sorbet/rbi/gems/faraday-patron@1.0.0.rbi +++ b/sorbet/rbi/gems/faraday-patron@1.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-patron` gem. # Please instead update this file by running `bin/tapioca gem faraday-patron`. + # source://faraday-patron//lib/faraday/adapter/patron.rb#3 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # Patron adapter # # source://faraday-patron//lib/faraday/adapter/patron.rb#6 @@ -118,30 +116,6 @@ end # source://faraday-patron//lib/faraday/adapter/patron.rb#114 Faraday::Adapter::Patron::CURL_TIMEOUT_MESSAGES = T.let(T.unsafe(nil), Array) -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - # Main Faraday::Patron module # # source://faraday-patron//lib/faraday/patron/version.rb#4 @@ -149,12 +123,3 @@ module Faraday::Patron; end # source://faraday-patron//lib/faraday/patron/version.rb#5 Faraday::Patron::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-rack@1.0.0.rbi b/sorbet/rbi/gems/faraday-rack@1.0.0.rbi index c2a52b606..8d26c1777 100644 --- a/sorbet/rbi/gems/faraday-rack@1.0.0.rbi +++ b/sorbet/rbi/gems/faraday-rack@1.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-rack` gem. # Please instead update this file by running `bin/tapioca gem faraday-rack`. + # source://faraday-rack//lib/faraday/adapter/rack.rb#3 module Faraday class << self @@ -85,9 +86,6 @@ class Faraday::Adapter def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil)); end end -# source://faraday/1.10.3/lib/faraday/adapter.rb#10 -Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - # Sends requests to a Rack app. # # @example @@ -126,30 +124,6 @@ end # source://faraday-rack//lib/faraday/adapter/rack.rb#22 Faraday::Adapter::Rack::SPECIAL_HEADERS = T.let(T.unsafe(nil), Array) -# source://faraday/1.10.3/lib/faraday/adapter.rb#99 -Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash) - -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - # Main Faraday::Rack module # # source://faraday-rack//lib/faraday/rack/version.rb#4 @@ -157,12 +131,3 @@ module Faraday::Rack; end # source://faraday-rack//lib/faraday/rack/version.rb#5 Faraday::Rack::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday-retry@1.0.3.rbi b/sorbet/rbi/gems/faraday-retry@1.0.3.rbi index 826a49e48..fb82fc86d 100644 --- a/sorbet/rbi/gems/faraday-retry@1.0.3.rbi +++ b/sorbet/rbi/gems/faraday-retry@1.0.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday-retry` gem. # Please instead update this file by running `bin/tapioca gem faraday-retry`. + # Faraday namespace. # # source://faraday-retry//lib/faraday/retriable_response.rb#4 @@ -64,27 +65,6 @@ module Faraday end end -# source://faraday/1.10.3/lib/faraday.rb#60 -Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/methods.rb#5 -Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array) - -# source://faraday/1.10.3/lib/faraday/methods.rb#4 -Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array) - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - # Exception used to control the Retry middleware. # # source://faraday-retry//lib/faraday/retriable_response.rb#6 @@ -216,12 +196,3 @@ Faraday::Retry::Middleware::Options::DEFAULT_CHECK = T.let(T.unsafe(nil), Proc) # source://faraday-retry//lib/faraday/retry/version.rb#5 Faraday::Retry::VERSION = T.let(T.unsafe(nil), String) - -# source://faraday/1.10.3/lib/faraday.rb#12 -Faraday::Timer = Timeout - -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - -# source://faraday/1.10.3/lib/faraday/version.rb#4 -Faraday::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/faraday@1.10.3.rbi b/sorbet/rbi/gems/faraday@1.10.3.rbi index 5df81c37a..65411ca9c 100644 --- a/sorbet/rbi/gems/faraday@1.10.3.rbi +++ b/sorbet/rbi/gems/faraday@1.10.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `faraday` gem. # Please instead update this file by running `bin/tapioca gem faraday`. + # This is the main namespace for Faraday. # # It provides methods to create {Connection} objects, and HTTP-related @@ -501,9 +502,6 @@ Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String) # source://faraday//lib/faraday/error.rb#85 class Faraday::ClientError < ::Faraday::Error; end -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#18 -Faraday::CompositeReadIO = Faraday::Multipart::CompositeReadIO - # Raised by Faraday::Response::RaiseError in case of a 409 response. # # source://faraday//lib/faraday/error.rb#109 @@ -1278,9 +1276,6 @@ class Faraday::Error < ::StandardError def exc_msg_and_response!(exc, response = T.unsafe(nil)); end end -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#15 -Faraday::FilePart = Multipart::Post::UploadIO - # FlatParamsEncoder manages URI params as a flat hash. Any Array values repeat # the parameter multiple times. # @@ -1730,17 +1725,11 @@ class Faraday::Options < ::Struct end end -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#16 -Faraday::ParamPart = Faraday::Multipart::ParamPart - # Raised by FaradayMiddleware::ResponseMiddleware # # source://faraday//lib/faraday/error.rb#144 class Faraday::ParsingError < ::Faraday::Error; end -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#17 -Faraday::Parts = Multipart::Post::Parts - # Raised by Faraday::Response::RaiseError in case of a 407 response. # # source://faraday//lib/faraday/error.rb#105 @@ -2432,9 +2421,6 @@ class Faraday::UnauthorizedError < ::Faraday::ClientError; end # source://faraday//lib/faraday/error.rb#113 class Faraday::UnprocessableEntityError < ::Faraday::ClientError; end -# source://faraday-multipart/1.0.4/lib/faraday/multipart.rb#21 -Faraday::UploadIO = Multipart::Post::UploadIO - # Utils contains various static helper methods. # # source://faraday//lib/faraday/utils/headers.rb#4 diff --git a/sorbet/rbi/gems/ffi-compiler@1.0.1.rbi b/sorbet/rbi/gems/ffi-compiler@1.0.1.rbi deleted file mode 100644 index aa99ef141..000000000 --- a/sorbet/rbi/gems/ffi-compiler@1.0.1.rbi +++ /dev/null @@ -1,320 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `ffi-compiler` gem. -# Please instead update this file by running `bin/tapioca gem ffi-compiler`. - -# source://ffi-compiler//lib/ffi-compiler/loader.rb#5 -module FFI - class << self - # source://ffi/1.15.5/lib/ffi/types.rb#45 - def add_typedef(old, add); end - - # source://ffi/1.15.5/lib/ffi/errno.rb#34 - def errno; end - - # source://ffi/1.15.5/lib/ffi/errno.rb#40 - def errno=(error); end - - # @raise [TypeError] - # - # source://ffi/1.15.5/lib/ffi/types.rb#56 - def find_type(name, type_map = T.unsafe(nil)); end - - # source://ffi/1.15.5/lib/ffi/library.rb#44 - def map_library_name(lib); end - - # source://ffi/1.15.5/lib/ffi/types.rb#176 - def type_size(type); end - - # source://ffi/1.15.5/lib/ffi/types.rb#40 - def typedef(old, add); end - end -end - -class FFI::ArrayType < ::FFI::Type - def initialize(_arg0, _arg1); end - - def elem_type; end - def length; end -end - -class FFI::Buffer < ::FFI::AbstractMemory - def initialize(*_arg0); end - - def +(_arg0); end - def inspect; end - def length; end - def order(*_arg0); end - def slice(_arg0, _arg1); end - - private - - def initialize_copy(_arg0); end - - class << self - def alloc_in(*_arg0); end - def alloc_inout(*_arg0); end - def alloc_out(*_arg0); end - def new_in(*_arg0); end - def new_inout(*_arg0); end - def new_out(*_arg0); end - end -end - -# source://ffi/1.15.5/lib/ffi/library.rb#32 -FFI::CURRENT_PROCESS = T.let(T.unsafe(nil), Object) - -FFI::CallbackInfo = FFI::FunctionType - -# source://ffi-compiler//lib/ffi-compiler/platform.rb#1 -module FFI::Compiler; end - -# source://ffi-compiler//lib/ffi-compiler/loader.rb#7 -module FFI::Compiler::Loader - class << self - # source://ffi-compiler//lib/ffi-compiler/loader.rb#24 - def caller_path(line = T.unsafe(nil)); end - - # @raise [LoadError] - # - # source://ffi-compiler//lib/ffi-compiler/loader.rb#8 - def find(name, start_path = T.unsafe(nil)); end - end -end - -# source://ffi-compiler//lib/ffi-compiler/platform.rb#2 -class FFI::Compiler::Platform - # source://ffi-compiler//lib/ffi-compiler/platform.rb#13 - def arch; end - - # @return [Boolean] - # - # source://ffi-compiler//lib/ffi-compiler/platform.rb#25 - def mac?; end - - # source://ffi-compiler//lib/ffi-compiler/platform.rb#9 - def map_library_name(name); end - - # source://ffi-compiler//lib/ffi-compiler/platform.rb#21 - def name; end - - # source://ffi-compiler//lib/ffi-compiler/platform.rb#17 - def os; end - - class << self - # source://ffi-compiler//lib/ffi-compiler/platform.rb#5 - def system; end - end -end - -# source://ffi-compiler//lib/ffi-compiler/platform.rb#3 -FFI::Compiler::Platform::LIBSUFFIX = T.let(T.unsafe(nil), String) - -class FFI::DynamicLibrary - def initialize(_arg0, _arg1); end - - def find_function(_arg0); end - def find_symbol(_arg0); end - def find_variable(_arg0); end - def last_error; end - def name; end - - class << self - def last_error; end - def open(_arg0, _arg1); end - end -end - -FFI::DynamicLibrary::RTLD_ALL_MASK = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_BINDING_MASK = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_DEEPBIND = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_FIRST = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_GLOBAL = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_LAZY = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_LOCAL = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_LOCATION_MASK = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_MEMBER = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_NODELETE = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_NOLOAD = T.let(T.unsafe(nil), Integer) -FFI::DynamicLibrary::RTLD_NOW = T.let(T.unsafe(nil), Integer) - -class FFI::DynamicLibrary::Symbol < ::FFI::Pointer - def inspect; end - - private - - def initialize_copy(_arg0); end -end - -class FFI::Function < ::FFI::Pointer - # @return [Function] a new instance of Function - def initialize(*_arg0); end - - def attach(_arg0, _arg1); end - def autorelease; end - def autorelease=(_arg0); end - def autorelease?; end - def call(*_arg0); end - def free; end - - private - - def initialize_copy(_arg0); end -end - -FFI::FunctionInfo = FFI::FunctionType - -class FFI::FunctionType < ::FFI::Type - def initialize(*_arg0); end - - def param_types; end - def result_type; end -end - -module FFI::LastError - private - - def error; end - def error=(_arg0); end - - class << self - def error; end - def error=(_arg0); end - end -end - -class FFI::MemoryPointer < ::FFI::Pointer - def initialize(*_arg0); end - - class << self - def from_string(_arg0); end - end -end - -FFI::NativeLibrary = FFI::DynamicLibrary -module FFI::NativeType; end -FFI::NativeType::BOOL = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::BUFFER_IN = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::BUFFER_INOUT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::BUFFER_OUT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::FLOAT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::FLOAT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::INT16 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::INT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::INT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::INT8 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::LONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::LONGDOUBLE = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::POINTER = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::STRING = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::UINT16 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::UINT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::UINT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::UINT8 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::ULONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::VARARGS = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::NativeType::VOID = T.let(T.unsafe(nil), FFI::Type::Builtin) -class FFI::NullPointerError < ::RuntimeError; end -FFI::SizeTypes = T.let(T.unsafe(nil), Hash) - -class FFI::StructByValue < ::FFI::Type - # @return [StructByValue] a new instance of StructByValue - def initialize(_arg0); end - - def layout; end - def struct_class; end -end - -FFI::TYPE_BOOL = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_BUFFER_IN = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_BUFFER_INOUT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_BUFFER_OUT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_FLOAT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_FLOAT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_INT16 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_INT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_INT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_INT8 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_LONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_LONGDOUBLE = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_POINTER = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_STRING = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_UINT16 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_UINT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_UINT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_UINT8 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_ULONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_VARARGS = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TYPE_VOID = T.let(T.unsafe(nil), FFI::Type::Builtin) - -class FFI::Type - # @return [Type] a new instance of Type - def initialize(_arg0); end - - def alignment; end - def inspect; end - def size; end -end - -FFI::Type::Array = FFI::ArrayType -FFI::Type::BOOL = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::BUFFER_IN = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::BUFFER_INOUT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::BUFFER_OUT = T.let(T.unsafe(nil), FFI::Type::Builtin) - -class FFI::Type::Builtin < ::FFI::Type - def inspect; end -end - -FFI::Type::CHAR = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::DOUBLE = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::FLOAT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::FLOAT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::FLOAT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::Function = FFI::FunctionType -FFI::Type::INT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::INT16 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::INT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::INT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::INT8 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::LONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::LONGDOUBLE = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::LONG_LONG = T.let(T.unsafe(nil), FFI::Type::Builtin) - -class FFI::Type::Mapped < ::FFI::Type - def initialize(_arg0); end - - def from_native(*_arg0); end - def native_type; end - def to_native(*_arg0); end - def type; end -end - -FFI::Type::POINTER = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::SCHAR = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::SHORT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::SINT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::SLONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::SLONG_LONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::SSHORT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::STRING = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::Struct = FFI::StructByValue -FFI::Type::UCHAR = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::UINT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::UINT16 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::UINT32 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::UINT64 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::UINT8 = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::ULONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::ULONG_LONG = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::USHORT = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::VARARGS = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::Type::VOID = T.let(T.unsafe(nil), FFI::Type::Builtin) -FFI::TypeDefs = T.let(T.unsafe(nil), Hash) - -# source://ffi/1.15.5/lib/ffi/library.rb#32 -FFI::USE_THIS_PROCESS_AS_LIBRARY = T.let(T.unsafe(nil), Object) - -# source://ffi/1.15.5/lib/ffi/version.rb#2 -FFI::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/ffi-compiler@1.3.2.rbi b/sorbet/rbi/gems/ffi-compiler@1.3.2.rbi new file mode 100644 index 000000000..fdf625f8e --- /dev/null +++ b/sorbet/rbi/gems/ffi-compiler@1.3.2.rbi @@ -0,0 +1,183 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `ffi-compiler` gem. +# Please instead update this file by running `bin/tapioca gem ffi-compiler`. + + +# source://ffi-compiler//lib/ffi-compiler/loader.rb#5 +module FFI + private + + def custom_typedefs; end + + class << self + # source://ffi/1.17.0/lib/ffi/types.rb#62 + def add_typedef(old, add); end + + # source://ffi/1.17.0/lib/ffi/errno.rb#34 + def errno; end + + # source://ffi/1.17.0/lib/ffi/errno.rb#40 + def errno=(error); end + + # @raise [TypeError] + # + # source://ffi/1.17.0/lib/ffi/types.rb#76 + def find_type(name, type_map = T.unsafe(nil)); end + + # source://ffi/1.17.0/lib/ffi/compat.rb#35 + def make_shareable(obj); end + + # source://ffi/1.17.0/lib/ffi/library.rb#46 + def map_library_name(lib); end + + # source://ffi/1.17.0/lib/ffi/types.rb#101 + def type_size(type); end + + # source://ffi/1.17.0/lib/ffi/types.rb#56 + def typedef(old, add); end + + private + + # source://ffi/1.17.0/lib/ffi/types.rb#66 + def __typedef(old, add); end + + def custom_typedefs; end + end +end + +class FFI::ArrayType < ::FFI::Type + def initialize(_arg0, _arg1); end + + def elem_type; end + def length; end +end + +class FFI::Buffer < ::FFI::AbstractMemory + def initialize(*_arg0); end + + def +(_arg0); end + def inspect; end + def length; end + def order(*_arg0); end + def slice(_arg0, _arg1); end + + private + + def initialize_copy(_arg0); end + + class << self + def alloc_in(*_arg0); end + def alloc_inout(*_arg0); end + def alloc_out(*_arg0); end + def new_in(*_arg0); end + def new_inout(*_arg0); end + def new_out(*_arg0); end + end +end + +# source://ffi-compiler//lib/ffi-compiler/platform.rb#1 +module FFI::Compiler; end + +# source://ffi-compiler//lib/ffi-compiler/loader.rb#7 +module FFI::Compiler::Loader + class << self + # source://ffi-compiler//lib/ffi-compiler/loader.rb#28 + def caller_path(line = T.unsafe(nil)); end + + # @raise [LoadError] + # + # source://ffi-compiler//lib/ffi-compiler/loader.rb#8 + def find(name, start_path = T.unsafe(nil)); end + end +end + +# source://ffi-compiler//lib/ffi-compiler/platform.rb#2 +class FFI::Compiler::Platform + # source://ffi-compiler//lib/ffi-compiler/platform.rb#13 + def arch; end + + # @return [Boolean] + # + # source://ffi-compiler//lib/ffi-compiler/platform.rb#25 + def mac?; end + + # source://ffi-compiler//lib/ffi-compiler/platform.rb#9 + def map_library_name(name); end + + # source://ffi-compiler//lib/ffi-compiler/platform.rb#21 + def name; end + + # source://ffi-compiler//lib/ffi-compiler/platform.rb#17 + def os; end + + class << self + # source://ffi-compiler//lib/ffi-compiler/platform.rb#5 + def system; end + end +end + +# source://ffi-compiler//lib/ffi-compiler/platform.rb#3 +FFI::Compiler::Platform::LIBSUFFIX = T.let(T.unsafe(nil), String) + +class FFI::FunctionType < ::FFI::Type + def initialize(*_arg0); end + + def param_types; end + def return_type; end +end + +module FFI::LastError + private + + def error; end + def error=(_arg0); end + + class << self + def error; end + def error=(_arg0); end + end +end + +class FFI::MemoryPointer < ::FFI::Pointer + def initialize(*_arg0); end + + class << self + def from_string(_arg0); end + end +end + +module FFI::NativeType; end +class FFI::NullPointerError < ::RuntimeError; end + +class FFI::StructByValue < ::FFI::Type + # @return [StructByValue] a new instance of StructByValue + def initialize(_arg0); end + + def layout; end + def struct_class; end +end + +class FFI::Type + # @return [Type] a new instance of Type + def initialize(_arg0); end + + def alignment; end + def inspect; end + def size; end +end + +class FFI::Type::Builtin < ::FFI::Type + def inspect; end +end + +class FFI::Type::Mapped < ::FFI::Type + def initialize(_arg0); end + + def converter; end + def from_native(*_arg0); end + def native_type; end + def to_native(*_arg0); end + def type; end +end diff --git a/sorbet/rbi/gems/ffi@1.15.5.rbi b/sorbet/rbi/gems/ffi@1.17.0.rbi similarity index 83% rename from sorbet/rbi/gems/ffi@1.15.5.rbi rename to sorbet/rbi/gems/ffi@1.17.0.rbi index 88c49a3b8..7c957af93 100644 --- a/sorbet/rbi/gems/ffi@1.15.5.rbi +++ b/sorbet/rbi/gems/ffi@1.17.0.rbi @@ -4,16 +4,23 @@ # This is an autogenerated file for types exported from the `ffi` gem. # Please instead update this file by running `bin/tapioca gem ffi`. -# source://ffi//lib/ffi/platform.rb#32 + +# source://ffi//lib/ffi/compat.rb#32 module FFI + private + + def custom_typedefs; end + class << self # Add a definition type to type definitions. # + # The type definition is local per Ractor. + # # @param old [Type, DataConverter, Symbol] type definition used by {FFI.find_type} # @param add [Symbol] new type definition's name to add # @return [Type] # - # source://ffi//lib/ffi/types.rb#45 + # source://ffi//lib/ffi/types.rb#62 def add_typedef(old, add); end # @see FFI::LastError.error @@ -34,9 +41,14 @@ module FFI # @param type_map [Hash] if nil, {FFI::TypeDefs} is used # @return [Type] # - # source://ffi//lib/ffi/types.rb#56 + # source://ffi//lib/ffi/types.rb#76 def find_type(name, type_map = T.unsafe(nil)); end + # This is for FFI internal use only. + # + # source://ffi//lib/ffi/compat.rb#35 + def make_shareable(obj); end + # Transform a generic library name to a platform library name # # @example @@ -46,28 +58,39 @@ module FFI # # Windows # FFI.map_library_name 'c' # -> "msvcrt.dll" # FFI.map_library_name 'jpeg' # -> "jpeg.dll" - # @param lib [#to_s] library name + # @param lib [String, FFI::LibraryPath] library name or LibraryPath object # @return [String] library name formatted for current platform # - # source://ffi//lib/ffi/library.rb#44 + # source://ffi//lib/ffi/library.rb#46 def map_library_name(lib); end # Get +type+ size, in bytes. # # @param type +type+ is an instance of class accepted by {FFI.find_type} - # @return [Numeric] + # @return [Integer] # - # source://ffi//lib/ffi/types.rb#176 + # source://ffi//lib/ffi/types.rb#101 def type_size(type); end # Add a definition type to type definitions. # + # The type definition is local per Ractor. + # # @param old [Type, DataConverter, Symbol] type definition used by {FFI.find_type} # @param add [Symbol] new type definition's name to add # @return [Type] # - # source://ffi//lib/ffi/types.rb#40 + # source://ffi//lib/ffi/types.rb#56 def typedef(old, add); end + + private + + # source://ffi//lib/ffi/types.rb#66 + def __typedef(old, add); end + + # Truffleruby and JRuby don't support Ractor so far. + # So they don't need separation between builtin and custom types. + def custom_typedefs; end end end @@ -76,6 +99,7 @@ class FFI::AbstractMemory def [](_arg0); end def __copy_from__(_arg0, _arg1); end def clear; end + def freeze; end def get(_arg0, _arg1); end def get_array_of_char(_arg0, _arg1); end def get_array_of_double(_arg0, _arg1); end @@ -187,6 +211,7 @@ class FFI::AbstractMemory def read_array_of_long_long(_arg0); end def read_array_of_pointer(_arg0); end def read_array_of_short(_arg0); end + def read_array_of_string(*_arg0); end def read_array_of_uchar(_arg0); end def read_array_of_uint(_arg0); end def read_array_of_uint16(_arg0); end @@ -306,33 +331,33 @@ class FFI::AutoPointer < ::FFI::Pointer # @overload initialize # @overload initialize # @overload initialize - # @overload initialize # @raise [TypeError] # @return [AutoPointer] a new instance of AutoPointer # - # source://ffi//lib/ffi/autopointer.rb#78 - def initialize(ptr, proc = T.unsafe(nil), &block); end + # source://ffi//lib/ffi/autopointer.rb#70 + def initialize(ptr, proc = T.unsafe(nil)); end # Set +autorelease+ property. See {Pointer Autorelease section at Pointer}. # # @param autorelease [Boolean] + # @raise [FrozenError] # @return [Boolean] +autorelease+ # - # source://ffi//lib/ffi/autopointer.rb#109 + # source://ffi//lib/ffi/autopointer.rb#101 def autorelease=(autorelease); end # Get +autorelease+ property. See {Pointer Autorelease section at Pointer}. # # @return [Boolean] +autorelease+ # - # source://ffi//lib/ffi/autopointer.rb#115 + # source://ffi//lib/ffi/autopointer.rb#108 def autorelease?; end # Free the pointer. # # @return [nil] # - # source://ffi//lib/ffi/autopointer.rb#102 + # source://ffi//lib/ffi/autopointer.rb#94 def free; end class << self @@ -343,7 +368,7 @@ class FFI::AutoPointer < ::FFI::Pointer # @overload self.from_native # @return [AutoPointer] # - # source://ffi//lib/ffi/autopointer.rb#198 + # source://ffi//lib/ffi/autopointer.rb#175 def from_native(val, ctx); end # Return native type of AutoPointer. @@ -353,48 +378,18 @@ class FFI::AutoPointer < ::FFI::Pointer # @raise [RuntimeError] if class does not implement a +#release+ method # @return [Type::POINTER] # - # source://ffi//lib/ffi/autopointer.rb#184 + # source://ffi//lib/ffi/autopointer.rb#161 def native_type; end end end -# CallableReleaser is a {Releaser} used when an {AutoPointer} is defined with a -# Proc or a Method. -# -# source://ffi//lib/ffi/autopointer.rb#168 -class FFI::AutoPointer::CallableReleaser < ::FFI::AutoPointer::Releaser - # Release +ptr+ by using Proc or Method defined at +ptr+ - # {AutoPointer#initialize initialization}. - # - # @param ptr [Pointer] - # @return [nil] - # - # source://ffi//lib/ffi/autopointer.rb#174 - def release(ptr); end -end - -# DefaultReleaser is a {Releaser} used when an {AutoPointer} is defined -# without Proc or Method. In this case, the pointer to release must be of -# a class derived from AutoPointer with a {release} class method. -# -# source://ffi//lib/ffi/autopointer.rb#157 -class FFI::AutoPointer::DefaultReleaser < ::FFI::AutoPointer::Releaser - # Release +ptr+ using the {release} class method of its class. - # - # @param ptr [Pointer] - # @return [nil] - # - # source://ffi//lib/ffi/autopointer.rb#161 - def release(ptr); end -end - # A releaser is an object in charge of release an {AutoPointer}. # # @abstract Base class for {AutoPointer}'s releasers. # # All subclasses of Releaser should define a +#release(ptr)+ method. # -# source://ffi//lib/ffi/autopointer.rb#123 +# source://ffi//lib/ffi/autopointer.rb#116 class FFI::AutoPointer::Releaser # A new instance of Releaser. # @@ -402,34 +397,43 @@ class FFI::AutoPointer::Releaser # @param proc [#call] # @return [nil] # - # source://ffi//lib/ffi/autopointer.rb#130 + # source://ffi//lib/ffi/autopointer.rb#123 def initialize(ptr, proc); end # Returns the value of attribute autorelease. # - # source://ffi//lib/ffi/autopointer.rb#124 + # source://ffi//lib/ffi/autopointer.rb#117 def autorelease; end # Sets the attribute autorelease # # @param value the value to set the attribute autorelease to. # - # source://ffi//lib/ffi/autopointer.rb#124 + # source://ffi//lib/ffi/autopointer.rb#117 def autorelease=(_arg0); end # Release pointer if +autorelease+ is set. # # @param args # - # source://ffi//lib/ffi/autopointer.rb#149 + # source://ffi//lib/ffi/autopointer.rb#142 def call(*args); end # Free pointer. # # @return [nil] # - # source://ffi//lib/ffi/autopointer.rb#138 + # source://ffi//lib/ffi/autopointer.rb#131 def free; end + + # Release +ptr+ by using Proc or Method defined at +ptr+ + # {AutoPointer#initialize initialization}. + # + # @param ptr [Pointer] + # @return [nil] + # + # source://ffi//lib/ffi/autopointer.rb#151 + def release(ptr); end end # Represents a C enum whose values are power of 2 @@ -444,13 +448,13 @@ end # blue = (1<<2) # } # -# source://ffi//lib/ffi/enum.rb#184 +# source://ffi//lib/ffi/enum.rb#183 class FFI::Bitmask < ::FFI::Enum # @overload initialize # @overload initialize # @return [Bitmask] a new instance of Bitmask # - # source://ffi//lib/ffi/enum.rb#193 + # source://ffi//lib/ffi/enum.rb#192 def initialize(*args); end # Get a symbol list or a value from the bitmask @@ -468,7 +472,7 @@ class FFI::Bitmask < ::FFI::Enum # @param ctx unused # @return [Array] list of symbol names corresponding to val, plus an optional remainder if some bits don't match any constant # - # source://ffi//lib/ffi/enum.rb#282 + # source://ffi//lib/ffi/enum.rb#288 def from_native(val, ctx); end # Get the native value of a bitmask @@ -503,14 +507,14 @@ class FFI::Buffer < ::FFI::AbstractMemory end end -# source://ffi//lib/ffi/library.rb#32 +# source://ffi//lib/ffi/library.rb#34 FFI::CURRENT_PROCESS = T.let(T.unsafe(nil), Object) FFI::CallbackInfo = FFI::FunctionType # This module is used to extend somes classes and give then a common API. # -# Most of methods defined here must be overriden. +# Most of methods defined here must be overridden. # # source://ffi//lib/ffi/data_converter.rb#35 module FFI::DataConverter @@ -533,6 +537,7 @@ module FFI::DataConverter def to_native(value, ctx); end end +# source://ffi//lib/ffi/dynamic_library.rb#32 class FFI::DynamicLibrary def initialize(_arg0, _arg1); end @@ -545,6 +550,14 @@ class FFI::DynamicLibrary class << self def last_error; end def open(_arg0, _arg1); end + + private + + # source://ffi//lib/ffi/dynamic_library.rb#69 + def load_library(name, flags); end + + # source://ffi//lib/ffi/dynamic_library.rb#99 + def try_load(libname, flags, errors); end end end @@ -561,6 +574,12 @@ FFI::DynamicLibrary::RTLD_NODELETE = T.let(T.unsafe(nil), Integer) FFI::DynamicLibrary::RTLD_NOLOAD = T.let(T.unsafe(nil), Integer) FFI::DynamicLibrary::RTLD_NOW = T.let(T.unsafe(nil), Integer) +# source://ffi//lib/ffi/dynamic_library.rb#33 +FFI::DynamicLibrary::SEARCH_PATH = T.let(T.unsafe(nil), Array) + +# source://ffi//lib/ffi/dynamic_library.rb#67 +FFI::DynamicLibrary::SEARCH_PATH_MESSAGE = T.let(T.unsafe(nil), String) + class FFI::DynamicLibrary::Symbol < ::FFI::Pointer def inspect; end @@ -582,7 +601,7 @@ end # * a _symbol_ is a word from the enumeration (ie. _apple_, by example); # * a _value_ is the value of a symbol in the enumeration (by example, apple has value _0_ and banana _1_). # -# source://ffi//lib/ffi/enum.rb#84 +# source://ffi//lib/ffi/enum.rb#83 class FFI::Enum include ::FFI::DataConverter @@ -590,7 +609,7 @@ class FFI::Enum # @overload initialize # @return [Enum] a new instance of Enum # - # source://ffi//lib/ffi/enum.rb#97 + # source://ffi//lib/ffi/enum.rb#96 def initialize(*args); end # Get a symbol or a value from the enum. @@ -598,7 +617,7 @@ class FFI::Enum # @overload [] # @overload [] # - # source://ffi//lib/ffi/enum.rb#134 + # source://ffi//lib/ffi/enum.rb#133 def [](query); end # Get a symbol or a value from the enum. @@ -606,56 +625,56 @@ class FFI::Enum # @overload [] # @overload [] # - # source://ffi//lib/ffi/enum.rb#134 + # source://ffi//lib/ffi/enum.rb#133 def find(query); end # @param val # @return symbol name if it exists for +val+. # - # source://ffi//lib/ffi/enum.rb#168 + # source://ffi//lib/ffi/enum.rb#167 def from_native(val, ctx); end # Returns the value of attribute native_type. # - # source://ffi//lib/ffi/enum.rb#88 + # source://ffi//lib/ffi/enum.rb#87 def native_type; end # Get the symbol map. # # @return [Hash] # - # source://ffi//lib/ffi/enum.rb#146 + # source://ffi//lib/ffi/enum.rb#145 def symbol_map; end # @return [Array] enum symbol names # - # source://ffi//lib/ffi/enum.rb#121 + # source://ffi//lib/ffi/enum.rb#120 def symbols; end # Returns the value of attribute tag. # - # source://ffi//lib/ffi/enum.rb#87 + # source://ffi//lib/ffi/enum.rb#86 def tag; end # Get the symbol map. # # @return [Hash] # - # source://ffi//lib/ffi/enum.rb#146 + # source://ffi//lib/ffi/enum.rb#145 def to_h; end # Get the symbol map. # # @return [Hash] # - # source://ffi//lib/ffi/enum.rb#146 + # source://ffi//lib/ffi/enum.rb#145 def to_hash; end # @param val [Symbol, Integer, #to_int] # @param ctx unused # @return [Integer] value of a enum symbol # - # source://ffi//lib/ffi/enum.rb#156 + # source://ffi//lib/ffi/enum.rb#155 def to_native(val, ctx); end end @@ -663,22 +682,22 @@ end # # source://ffi//lib/ffi/enum.rb#36 class FFI::Enums - # @return [nil] + # @return [Enums] a new instance of Enums # - # source://ffi//lib/ffi/enum.rb#39 + # source://ffi//lib/ffi/enum.rb#38 def initialize; end # Add an {Enum} to the collection. # # @param enum [Enum] # - # source://ffi//lib/ffi/enum.rb#47 + # source://ffi//lib/ffi/enum.rb#46 def <<(enum); end # @param symbol a symbol to find in merge symbol maps of all enums. # @return a symbol # - # source://ffi//lib/ffi/enum.rb#66 + # source://ffi//lib/ffi/enum.rb#65 def __map_symbol(symbol); end # Find a {Enum} in collection. @@ -686,23 +705,56 @@ class FFI::Enums # @param query enum tag or part of an enum name # @return [Enum] # - # source://ffi//lib/ffi/enum.rb#56 + # source://ffi//lib/ffi/enum.rb#55 def find(query); end end +# source://ffi//lib/ffi/function.rb#32 class FFI::Function < ::FFI::Pointer + include ::FFI::Function::RegisterAttach + def initialize(*_arg0); end - def attach(_arg0, _arg1); end + # source://ffi//lib/ffi/function.rb#57 + def attach(mod, name); end + def autorelease; end def autorelease=(_arg0); end def autorelease?; end def call(*_arg0); end def free; end + # Retrieve Array of parameter types + # + # This method returns an Array of FFI types accepted as function parameters. + # + # @return [Array] + # + # source://ffi//lib/ffi/function.rb#49 + def param_types; end + + # Retrieve the return type of the function + # + # This method returns FFI type returned by the function. + # + # @return [FFI::Type] + # + # source://ffi//lib/ffi/function.rb#40 + def return_type; end + private def initialize_copy(_arg0); end + def type; end +end + +# Stash the Function in a module variable so it can be inspected by attached_functions. +# On CRuby it also ensures that it does not get garbage collected. +# +# source://ffi//lib/ffi/function.rb#56 +module FFI::Function::RegisterAttach + # source://ffi//lib/ffi/function.rb#57 + def attach(mod, name); end end FFI::FunctionInfo = FFI::FunctionType @@ -711,7 +763,7 @@ class FFI::FunctionType < ::FFI::Type def initialize(*_arg0); end def param_types; end - def result_type; end + def return_type; end end # This module implements a couple of class methods to play with IO. @@ -734,9 +786,9 @@ module FFI::IO # # @param io [#read] io to read from # @param buf [AbstractMemory] destination for data read from +io+ - # @param len [nil, Numeric] maximul number of bytes to read from +io+. If +nil+, + # @param len [nil, Integer] maximul number of bytes to read from +io+. If +nil+, # read until end of file. - # @return [Numeric] length really read, in bytes + # @return [Integer] length really read, in bytes # # source://ffi//lib/ffi/io.rb#53 def native_read(io, buf, len); end @@ -768,7 +820,7 @@ end # # Hello.puts("Hello, World") # -# source://ffi//lib/ffi/library.rb#78 +# source://ffi//lib/ffi/library.rb#72 module FFI::Library # Attach C function +func+ to this module. # @@ -786,7 +838,7 @@ module FFI::Library # @raise [FFI::NotFoundError] if +func+ cannot be found in the attached libraries (see {#ffi_lib}) # @return [FFI::VariadicInvoker] # - # source://ffi//lib/ffi/library.rb#234 + # source://ffi//lib/ffi/library.rb#177 def attach_function(name, func, args, returns = T.unsafe(nil), options = T.unsafe(nil)); end # Attach C variable +cname+ to this module. @@ -796,9 +848,28 @@ module FFI::Library # @raise [FFI::NotFoundError] if +cname+ cannot be found in libraries # @return [DynamicLibrary::Symbol] # - # source://ffi//lib/ffi/library.rb#331 + # source://ffi//lib/ffi/library.rb#274 def attach_variable(mname, a1, a2 = T.unsafe(nil)); end + # Retrieve all attached functions and their function signature + # + # This method returns a Hash of method names of attached functions connected by #attach_function and the corresponding function type. + # The function type responds to #return_type and #param_types which return the FFI types of the function signature. + # + # @return [Hash< Symbol => [FFI::Function, FFI::VariadicInvoker] >] + # + # source://ffi//lib/ffi/library.rb#544 + def attached_functions; end + + # Retrieve all attached variables and their type + # + # This method returns a Hash of variable names and the corresponding type or variables connected by #attach_variable . + # + # @return [Hash< Symbol => ffi_type >] + # + # source://ffi//lib/ffi/library.rb#553 + def attached_variables; end + # Create a new FFI::Bitmask # # @overload bitmask @@ -809,7 +880,7 @@ module FFI::Library # @overload bitmask # @return [FFI::Bitmask] # - # source://ffi//lib/ffi/library.rb#554 + # source://ffi//lib/ffi/library.rb#520 def bitmask(*args); end # @overload callback @@ -817,7 +888,7 @@ module FFI::Library # @raise [ArgumentError] # @return [FFI::CallbackInfo] # - # source://ffi//lib/ffi/library.rb#384 + # source://ffi//lib/ffi/library.rb#330 def callback(*args); end # Create a new {FFI::Enum}. @@ -830,7 +901,7 @@ module FFI::Library # @overload enum # @return [FFI::Enum] # - # source://ffi//lib/ffi/library.rb#511 + # source://ffi//lib/ffi/library.rb#477 def enum(*args); end # Find an enum by name. @@ -838,7 +909,7 @@ module FFI::Library # @param name # @return [FFI::Enum] # - # source://ffi//lib/ffi/library.rb#561 + # source://ffi//lib/ffi/library.rb#527 def enum_type(name); end # Find an enum by a symbol it contains. @@ -846,7 +917,7 @@ module FFI::Library # @param symbol # @return [FFI::Enum] # - # source://ffi//lib/ffi/library.rb#568 + # source://ffi//lib/ffi/library.rb#534 def enum_value(symbol); end # Set the calling convention for {#attach_function} and {#callback} @@ -856,7 +927,7 @@ module FFI::Library # @return [Symbol] the new calling convention # @see http://en.wikipedia.org/wiki/Stdcall#stdcall # - # source://ffi//lib/ffi/library.rb#163 + # source://ffi//lib/ffi/library.rb#106 def ffi_convention(convention = T.unsafe(nil)); end # Load native libraries. @@ -865,7 +936,7 @@ module FFI::Library # @raise [LoadError] if a library cannot be opened # @return [Array] # - # source://ffi//lib/ffi/library.rb#95 + # source://ffi//lib/ffi/library.rb#89 def ffi_lib(*names); end # Sets library flags for {#ffi_lib}. @@ -873,9 +944,9 @@ module FFI::Library # @example # ffi_lib_flags(:lazy, :local) # => 5 # @param flags [Symbol, …] (see {FlagsMap}) - # @return [Fixnum] the new value + # @return [Integer] the new value # - # source://ffi//lib/ffi/library.rb#196 + # source://ffi//lib/ffi/library.rb#139 def ffi_lib_flags(*flags); end # Get FFI libraries loaded using {#ffi_lib}. @@ -884,7 +955,7 @@ module FFI::Library # @return [Array] array of currently loaded FFI libraries # @see #ffi_lib # - # source://ffi//lib/ffi/library.rb#173 + # source://ffi//lib/ffi/library.rb#116 def ffi_libraries; end # Find a type definition. @@ -892,9 +963,17 @@ module FFI::Library # @param t [DataConverter, Type, Struct, Symbol] type to find # @return [Type] # - # source://ffi//lib/ffi/library.rb#575 + # source://ffi//lib/ffi/library.rb#401 def find_type(t); end + # Freeze all definitions of the module + # + # This freezes the module's definitions, so that it can be used in a Ractor. + # No further methods or variables can be attached and no further enums or typedefs can be created in this module afterwards. + # + # source://ffi//lib/ffi/library.rb#568 + def freeze; end + # This function returns a list of possible names to lookup. # # @note Function names on windows may be decorated if they are using stdcall. See @@ -907,7 +986,7 @@ module FFI::Library # @param arg_types [Array] function's argument types # @return [Array] # - # source://ffi//lib/ffi/library.rb#289 + # source://ffi//lib/ffi/library.rb#232 def function_names(name, arg_types); end # Register or get an already registered type definition. @@ -928,7 +1007,7 @@ module FFI::Library # @param info [Symbol] # @return [FFI::Enum, FFI::Type] # - # source://ffi//lib/ffi/library.rb#428 + # source://ffi//lib/ffi/library.rb#374 def typedef(old, add, info = T.unsafe(nil)); end private @@ -937,7 +1016,7 @@ module FFI::Library # @param [Class] klass can be one of FFI::Enum or FFI::Bitmask # @param args (see #enum or #bitmask) # - # source://ffi//lib/ffi/library.rb#456 + # source://ffi//lib/ffi/library.rb#422 def generic_enum(klass, *args); end class << self @@ -947,12 +1026,12 @@ module FFI::Library # @raise [RuntimeError] if +mod+ is not a Module # @return [nil] # - # source://ffi//lib/ffi/library.rb#86 + # source://ffi//lib/ffi/library.rb#80 def extended(mod); end end end -# source://ffi//lib/ffi/library.rb#79 +# source://ffi//lib/ffi/library.rb#73 FFI::Library::CURRENT_PROCESS = T.let(T.unsafe(nil), Object) # Flags used in {#ffi_lib}. @@ -960,12 +1039,67 @@ FFI::Library::CURRENT_PROCESS = T.let(T.unsafe(nil), Object) # This map allows you to supply symbols to {#ffi_lib_flags} instead of # the actual constants. # -# source://ffi//lib/ffi/library.rb#182 +# source://ffi//lib/ffi/library.rb#125 FFI::Library::FlagsMap = T.let(T.unsafe(nil), Hash) -# source://ffi//lib/ffi/library.rb#80 +# source://ffi//lib/ffi/library.rb#74 FFI::Library::LIBC = T.let(T.unsafe(nil), String) +# Transform a generic library name and ABI number to a platform library name +# +# Example: +# module LibVips +# extend FFI::Library +# ffi_lib LibraryPath.new("vips", abi_number: 42) +# end +# +# This translates to the following library file names: +# libvips-42.dll on Windows +# libvips.so.42 on Linux +# libvips.42.dylib on Macos +# +# See https://packaging.ubuntu.com/html/libraries.html for more information about library naming. +# +# source://ffi//lib/ffi/library_path.rb#46 +class FFI::LibraryPath + # Build a new library path + # + # * name : The name of the library without file prefix or suffix. + # * abi_number : The ABI number of the library. + # * root : An optional base path prepended to the library name. + # + # @return [LibraryPath] a new instance of LibraryPath + # + # source://ffi//lib/ffi/library_path.rb#56 + def initialize(name, abi_number: T.unsafe(nil), root: T.unsafe(nil)); end + + # Returns the value of attribute abi_number. + # + # source://ffi//lib/ffi/library_path.rb#48 + def abi_number; end + + # source://ffi//lib/ffi/library_path.rb#78 + def full_name; end + + # Returns the value of attribute name. + # + # source://ffi//lib/ffi/library_path.rb#47 + def name; end + + # Returns the value of attribute root. + # + # source://ffi//lib/ffi/library_path.rb#49 + def root; end + + # source://ffi//lib/ffi/library_path.rb#100 + def to_s; end + + class << self + # source://ffi//lib/ffi/library_path.rb#62 + def wrap(value); end + end +end + # FFI::ManagedStruct allows custom garbage-collection of your FFI::Structs. # # The typical use case would be when interacting with a library @@ -1050,11 +1184,11 @@ FFI::NativeType::VOID = T.let(T.unsafe(nil), FFI::Type::Builtin) # Exception raised when a function is not found in libraries # -# source://ffi//lib/ffi/library.rb#58 +# source://ffi//lib/ffi/library.rb#52 class FFI::NotFoundError < ::LoadError # @return [NotFoundError] a new instance of NotFoundError # - # source://ffi//lib/ffi/library.rb#59 + # source://ffi//lib/ffi/library.rb#53 def initialize(function, *libraries); end end @@ -1063,14 +1197,14 @@ class FFI::NullPointerError < ::RuntimeError; end # This module defines different constants and class methods to play with # various platforms. # -# source://ffi//lib/ffi/platform.rb#37 +# source://ffi//lib/ffi/platform.rb#39 module FFI::Platform class << self # Test if current OS is a *BSD (include MAC) # # @return [Boolean] # - # source://ffi//lib/ffi/platform.rb#156 + # source://ffi//lib/ffi/platform.rb#158 def bsd?; end # Test if current OS is +os+. @@ -1078,35 +1212,35 @@ module FFI::Platform # @param os [String] # @return [Boolean] # - # source://ffi//lib/ffi/platform.rb#90 + # source://ffi//lib/ffi/platform.rb#92 def is_os(os); end # Test if current OS is Mac OS # # @return [Boolean] # - # source://ffi//lib/ffi/platform.rb#168 + # source://ffi//lib/ffi/platform.rb#170 def mac?; end # Test if current OS is Solaris (Sun OS) # # @return [Boolean] # - # source://ffi//lib/ffi/platform.rb#174 + # source://ffi//lib/ffi/platform.rb#176 def solaris?; end # Test if current OS is a unix OS # # @return [Boolean] # - # source://ffi//lib/ffi/platform.rb#180 + # source://ffi//lib/ffi/platform.rb#182 def unix?; end # Test if current OS is Windows # # @return [Boolean] # - # source://ffi//lib/ffi/platform.rb#162 + # source://ffi//lib/ffi/platform.rb#164 def windows?; end end end @@ -1114,16 +1248,16 @@ end FFI::Platform::ADDRESS_ALIGN = T.let(T.unsafe(nil), Integer) FFI::Platform::ADDRESS_SIZE = T.let(T.unsafe(nil), Integer) -# source://ffi//lib/ffi/platform.rb#63 +# source://ffi//lib/ffi/platform.rb#65 FFI::Platform::ARCH = T.let(T.unsafe(nil), String) FFI::Platform::BIG_ENDIAN = T.let(T.unsafe(nil), Integer) FFI::Platform::BYTE_ORDER = T.let(T.unsafe(nil), Integer) -# source://ffi//lib/ffi/platform.rb#109 +# source://ffi//lib/ffi/platform.rb#111 FFI::Platform::CONF_DIR = T.let(T.unsafe(nil), String) -# source://ffi//lib/ffi/platform.rb#61 +# source://ffi//lib/ffi/platform.rb#63 FFI::Platform::CPU = T.let(T.unsafe(nil), String) FFI::Platform::DOUBLE_ALIGN = T.let(T.unsafe(nil), Integer) @@ -1140,43 +1274,43 @@ FFI::Platform::INT64_SIZE = T.let(T.unsafe(nil), Integer) FFI::Platform::INT8_ALIGN = T.let(T.unsafe(nil), Integer) FFI::Platform::INT8_SIZE = T.let(T.unsafe(nil), Integer) -# source://ffi//lib/ffi/platform.rb#103 +# source://ffi//lib/ffi/platform.rb#105 FFI::Platform::IS_BSD = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#100 +# source://ffi//lib/ffi/platform.rb#102 FFI::Platform::IS_DRAGONFLYBSD = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#97 +# source://ffi//lib/ffi/platform.rb#99 FFI::Platform::IS_FREEBSD = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#94 +# source://ffi//lib/ffi/platform.rb#96 FFI::Platform::IS_GNU = T.let(T.unsafe(nil), String) -# source://ffi//lib/ffi/platform.rb#95 +# source://ffi//lib/ffi/platform.rb#97 FFI::Platform::IS_LINUX = T.let(T.unsafe(nil), TrueClass) -# source://ffi//lib/ffi/platform.rb#96 +# source://ffi//lib/ffi/platform.rb#98 FFI::Platform::IS_MAC = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#98 +# source://ffi//lib/ffi/platform.rb#100 FFI::Platform::IS_NETBSD = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#99 +# source://ffi//lib/ffi/platform.rb#101 FFI::Platform::IS_OPENBSD = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#101 +# source://ffi//lib/ffi/platform.rb#103 FFI::Platform::IS_SOLARIS = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#102 +# source://ffi//lib/ffi/platform.rb#104 FFI::Platform::IS_WINDOWS = T.let(T.unsafe(nil), FalseClass) -# source://ffi//lib/ffi/platform.rb#134 +# source://ffi//lib/ffi/platform.rb#136 FFI::Platform::LIBC = T.let(T.unsafe(nil), String) -# source://ffi//lib/ffi/platform.rb#113 +# source://ffi//lib/ffi/platform.rb#115 FFI::Platform::LIBPREFIX = T.let(T.unsafe(nil), String) -# source://ffi//lib/ffi/platform.rb#122 +# source://ffi//lib/ffi/platform.rb#124 FFI::Platform::LIBSUFFIX = T.let(T.unsafe(nil), String) FFI::Platform::LITTLE_ENDIAN = T.let(T.unsafe(nil), Integer) @@ -1187,16 +1321,16 @@ FFI::Platform::LONG_SIZE = T.let(T.unsafe(nil), Integer) # 64-bit inodes # -# source://ffi//lib/ffi/platform.rb#108 +# source://ffi//lib/ffi/platform.rb#110 FFI::Platform::NAME = T.let(T.unsafe(nil), String) -# source://ffi//lib/ffi/platform.rb#38 +# source://ffi//lib/ffi/platform.rb#40 FFI::Platform::OS = T.let(T.unsafe(nil), String) -# source://ffi//lib/ffi/platform.rb#59 +# source://ffi//lib/ffi/platform.rb#61 FFI::Platform::OSVERSION = T.let(T.unsafe(nil), Integer) -# source://ffi//lib/ffi/platform.rb#33 +# source://ffi//lib/ffi/platform.rb#35 class FFI::PlatformError < ::LoadError; end # source://ffi//lib/ffi/pointer.rb#42 @@ -1230,7 +1364,7 @@ class FFI::Pointer < ::FFI::AbstractMemory # ptr.read_array_of_type(TYPE_UINT8, :read_uint8, 4) # -> [1, 2, 3, 4] # @param type [Type] type of data to read from pointer's contents # @param reader [Symbol] method to send to +self+ to read +type+ - # @param length [Numeric] + # @param length [Integer] # @return [Array] # # source://ffi//lib/ffi/pointer.rb#114 @@ -1239,7 +1373,7 @@ class FFI::Pointer < ::FFI::AbstractMemory # Read pointer's contents as a string, or the first +len+ bytes of the # equivalent string if +len+ is not +nil+. # - # @param len [nil, Numeric] length of string to return + # @param len [nil, Integer] length of string to return # @return [String] # # source://ffi//lib/ffi/pointer.rb#57 @@ -1250,7 +1384,7 @@ class FFI::Pointer < ::FFI::AbstractMemory # Same as: # ptr.read_string(len) # with len not nil # - # @param len [Numeric] length of string to return + # @param len [Integer] length of string to return # @return [String] # # source://ffi//lib/ffi/pointer.rb#72 @@ -1305,7 +1439,7 @@ class FFI::Pointer < ::FFI::AbstractMemory # +len+ is not +nil+. # # @param str [String] string to write - # @param len [Numeric] length of string to return + # @param len [Integer] length of string to return # @return [self] # # source://ffi//lib/ffi/pointer.rb#101 @@ -1317,7 +1451,7 @@ class FFI::Pointer < ::FFI::AbstractMemory # ptr.write_string(str, len) # with len not nil # # @param str [String] string to write - # @param len [Numeric] length of string to return + # @param len [Integer] length of string to return # @return [self] # # source://ffi//lib/ffi/pointer.rb#92 @@ -1330,7 +1464,7 @@ class FFI::Pointer < ::FFI::AbstractMemory class << self # Return the size of a pointer on the current platform, in bytes # - # @return [Numeric] + # @return [Integer] # # source://ffi//lib/ffi/pointer.rb#49 def size; end @@ -1344,8 +1478,6 @@ FFI::Pointer::NULL = T.let(T.unsafe(nil), FFI::Pointer) # source://ffi//lib/ffi/pointer.rb#45 FFI::Pointer::SIZE = T.let(T.unsafe(nil), Integer) -FFI::SizeTypes = T.let(T.unsafe(nil), Hash) - # This will convert a pointer to a Ruby string (just like `:string`), but # also allow to work with the pointer itself. This is useful when you want # a Ruby string already containing a copy of the data, but also the pointer @@ -1354,7 +1486,7 @@ FFI::SizeTypes = T.let(T.unsafe(nil), Hash) # # It's {typedef}'d as +:strptr+. # -# source://ffi//lib/ffi/types.rb#158 +# source://ffi//lib/ffi/types.rb#191 class FFI::StrPtrConverter extend ::FFI::DataConverter @@ -1365,7 +1497,7 @@ class FFI::StrPtrConverter # @param ctx not used # @return [Array(String, Pointer)] # - # source://ffi//lib/ffi/types.rb#166 + # source://ffi//lib/ffi/types.rb#199 def from_native(val, ctx); end end end @@ -1377,12 +1509,12 @@ class FFI::Struct def [](_arg0); end def []=(_arg0, _arg1); end - # @return [Fixnum] Struct alignment + # @return [Integer] Struct alignment # # source://ffi//lib/ffi/struct.rb#50 def align; end - # @return [Fixnum] Struct alignment + # @return [Integer] Struct alignment # # source://ffi//lib/ffi/struct.rb#50 def alignment; end @@ -1403,14 +1535,14 @@ class FFI::Struct # Get the offset of a field. # - # @return [Numeric] + # @return [Integer] # # source://ffi//lib/ffi/struct.rb#56 def offset_of(name); end # Get an array of tuples (field name, offset of the field). # - # @return [Array] Array + # @return [Array] Array # # source://ffi//lib/ffi/struct.rb#72 def offsets; end @@ -1420,7 +1552,7 @@ class FFI::Struct # Get struct size # - # @return [Numeric] + # @return [Integer] # # source://ffi//lib/ffi/struct.rb#45 def size; end @@ -1446,7 +1578,7 @@ class FFI::Struct def pointer=(_arg0); end class << self - # @return [Fixnum] Struct alignment + # @return [Integer] Struct alignment # # source://ffi//lib/ffi/struct.rb#104 def alignment; end @@ -1483,14 +1615,14 @@ class FFI::Struct # Get the offset of a field. # - # @return [Numeric] + # @return [Integer] # # source://ffi//lib/ffi/struct.rb#119 def offset_of(name); end # Get an array of tuples (field name, offset of the field). # - # @return [Array] Array + # @return [Array] Array # # source://ffi//lib/ffi/struct.rb#114 def offsets; end @@ -1503,14 +1635,14 @@ class FFI::Struct # Get struct size # - # @return [Numeric] + # @return [Integer] # # source://ffi//lib/ffi/struct.rb#91 def size; end # set struct size # - # @param size [Numeric] + # @param size [Integer] # @raise [ArgumentError] # @return [size] # @@ -1522,28 +1654,28 @@ class FFI::Struct protected - # source://ffi//lib/ffi/struct.rb#243 + # source://ffi//lib/ffi/struct.rb#244 def align(alignment = T.unsafe(nil)); end - # source://ffi//lib/ffi/struct.rb#243 + # source://ffi//lib/ffi/struct.rb#244 def aligned(alignment = T.unsafe(nil)); end - # source://ffi//lib/ffi/struct.rb#229 + # source://ffi//lib/ffi/struct.rb#230 def callback(params, ret); end - # source://ffi//lib/ffi/struct.rb#248 + # source://ffi//lib/ffi/struct.rb#249 def enclosing_module; end - # source://ffi//lib/ffi/struct.rb#260 + # source://ffi//lib/ffi/struct.rb#261 def find_field_type(type, mod = T.unsafe(nil)); end - # source://ffi//lib/ffi/struct.rb#275 + # source://ffi//lib/ffi/struct.rb#276 def find_type(type, mod = T.unsafe(nil)); end - # source://ffi//lib/ffi/struct.rb#238 + # source://ffi//lib/ffi/struct.rb#239 def pack(packed = T.unsafe(nil)); end - # source://ffi//lib/ffi/struct.rb#238 + # source://ffi//lib/ffi/struct.rb#239 def packed(packed = T.unsafe(nil)); end private @@ -1554,7 +1686,7 @@ class FFI::Struct # @param spec [Array] # @return [builder] # - # source://ffi//lib/ffi/struct.rb#297 + # source://ffi//lib/ffi/struct.rb#298 def array_layout(builder, spec); end # Add hash +spec+ to +builder+. @@ -1563,7 +1695,7 @@ class FFI::Struct # @param spec [Hash] # @return [builder] # - # source://ffi//lib/ffi/struct.rb#287 + # source://ffi//lib/ffi/struct.rb#288 def hash_layout(builder, spec); end end end @@ -1655,14 +1787,14 @@ class FFI::StructLayout < ::FFI::Type # Get the offset of a field. # - # @return [Numeric] + # @return [Integer] # # source://ffi//lib/ffi/struct_layout.rb#46 def offset_of(field_name); end # Get an array of tuples (field name, offset of the field). # - # @return [Array] Array + # @return [Array] Array # # source://ffi//lib/ffi/struct_layout.rb#40 def offsets; end @@ -1762,7 +1894,7 @@ class FFI::StructLayoutBuilder # @note Setting +offset+ to +nil+ or +-1+ is equivalent to +0+. # @param name [String, Symbol] name of the field # @param type [Array, DataConverter, Struct, StructLayout::Field, Symbol, Type] type of the field - # @param offset [Numeric, nil] + # @param offset [Integer, nil] # @return [self] # # source://ffi//lib/ffi/struct_layout_builder.rb#123 @@ -1770,10 +1902,10 @@ class FFI::StructLayoutBuilder # Add an array as a field to the builder. # - # @param count [Numeric] array length + # @param count [Integer] array length # @param name [String, Symbol] name of the field # @param type [Array, DataConverter, Struct, StructLayout::Field, Symbol, Type] type of the field - # @param offset [Numeric, nil] + # @param offset [Integer, nil] # @return [self] # # source://ffi//lib/ffi/struct_layout_builder.rb#161 @@ -1783,7 +1915,7 @@ class FFI::StructLayoutBuilder # # @param name [String, Symbol] name of the field # @param type [Array, DataConverter, Struct, StructLayout::Field, Symbol, Type] type of the field - # @param offset [Numeric, nil] + # @param offset [Integer, nil] # @return [self] # @see #add # @@ -1794,7 +1926,7 @@ class FFI::StructLayoutBuilder # # @param name [String, Symbol] name of the field # @param type [Array, DataConverter, Struct, StructLayout::Field, Symbol, Type] type of the field - # @param offset [Numeric, nil] + # @param offset [Integer, nil] # @return [self] # # source://ffi//lib/ffi/struct_layout_builder.rb#151 @@ -1807,7 +1939,7 @@ class FFI::StructLayoutBuilder # Set alignment attribute with +align+ only if it is greater than attribute value. # - # @param align [Numeric] + # @param align [Integer] # # source://ffi//lib/ffi/struct_layout_builder.rb#56 def alignment=(align); end @@ -1834,7 +1966,7 @@ class FFI::StructLayoutBuilder # Set size attribute with +size+ only if +size+ is greater than attribute value. # - # @param size [Numeric] + # @param size [Integer] # # source://ffi//lib/ffi/struct_layout_builder.rb#50 def size=(size); end @@ -1857,16 +1989,16 @@ class FFI::StructLayoutBuilder private - # @param offset [Numeric] - # @param align [Numeric] - # @return [Numeric] + # @param offset [Integer] + # @param align [Integer] + # @return [Integer] # # source://ffi//lib/ffi/struct_layout_builder.rb#181 def align(offset, align); end # @param name [String, Symbol] name of the field # @param type [Array, DataConverter, Struct, StructLayout::Field, Symbol, Type] type of the field - # @param offset [Numeric, nil] + # @param offset [Integer, nil] # @return [StructLayout::Field] # # source://ffi//lib/ffi/struct_layout_builder.rb#187 @@ -1936,6 +2068,7 @@ FFI::Type::LONG_LONG = T.let(T.unsafe(nil), FFI::Type::Builtin) class FFI::Type::Mapped < ::FFI::Type def initialize(_arg0); end + def converter; end def from_native(*_arg0); end def native_type; end def to_native(*_arg0); end @@ -1964,7 +2097,7 @@ FFI::Type::VARARGS = T.let(T.unsafe(nil), FFI::Type::Builtin) FFI::Type::VOID = T.let(T.unsafe(nil), FFI::Type::Builtin) FFI::TypeDefs = T.let(T.unsafe(nil), Hash) -# source://ffi//lib/ffi/library.rb#32 +# source://ffi//lib/ffi/library.rb#34 FFI::USE_THIS_PROCESS_AS_LIBRARY = T.let(T.unsafe(nil), Object) # source://ffi//lib/ffi/union.rb#36 @@ -1991,4 +2124,15 @@ class FFI::VariadicInvoker def call(*args, &block); end def invoke(_arg0, _arg1); end + + # Retrieve Array of parameter types + # + # This method returns an Array of FFI types accepted as function parameters. + # + # @return [Array] + # + # source://ffi//lib/ffi/variadic.rb#76 + def param_types; end + + def return_type; end end diff --git a/sorbet/rbi/gems/font-awesome-rails@4.7.0.8.rbi b/sorbet/rbi/gems/font-awesome-rails@4.7.0.8.rbi index 26b792739..37540aca4 100644 --- a/sorbet/rbi/gems/font-awesome-rails@4.7.0.8.rbi +++ b/sorbet/rbi/gems/font-awesome-rails@4.7.0.8.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `font-awesome-rails` gem. # Please instead update this file by running `bin/tapioca gem font-awesome-rails`. + # source://font-awesome-rails//lib/font-awesome-rails/version.rb#1 module FontAwesome; end @@ -11,7 +12,12 @@ module FontAwesome; end module FontAwesome::Rails; end # source://font-awesome-rails//lib/font-awesome-rails/engine.rb#3 -class FontAwesome::Rails::Engine < ::Rails::Engine; end +class FontAwesome::Rails::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # source://font-awesome-rails//lib/font-awesome-rails/version.rb#3 FontAwesome::Rails::FA_VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/fugit@1.8.1.rbi b/sorbet/rbi/gems/fugit@1.11.0.rbi similarity index 79% rename from sorbet/rbi/gems/fugit@1.8.1.rbi rename to sorbet/rbi/gems/fugit@1.11.0.rbi index cda7024af..2105eff52 100644 --- a/sorbet/rbi/gems/fugit@1.8.1.rbi +++ b/sorbet/rbi/gems/fugit@1.11.0.rbi @@ -4,10 +4,11 @@ # This is an autogenerated file for types exported from the `fugit` gem. # Please instead update this file by running `bin/tapioca gem fugit`. + # source://fugit//lib/fugit.rb#4 module Fugit class << self - # source://fugit//lib/fugit/parse.rb#49 + # source://fugit//lib/fugit/parse.rb#66 def determine_type(s); end # source://fugit//lib/fugit/parse.rb#30 @@ -19,7 +20,7 @@ module Fugit # source://fugit//lib/fugit/parse.rb#13 def do_parse_cron(s); end - # source://fugit//lib/fugit/parse.rb#43 + # source://fugit//lib/fugit/parse.rb#60 def do_parse_cronish(s, opts = T.unsafe(nil)); end # source://fugit//lib/fugit/parse.rb#14 @@ -43,7 +44,7 @@ module Fugit # source://fugit//lib/fugit/parse.rb#7 def parse_cron(s); end - # source://fugit//lib/fugit/parse.rb#36 + # source://fugit//lib/fugit/parse.rb#53 def parse_cronish(s, opts = T.unsafe(nil)); end # source://fugit//lib/fugit/parse.rb#8 @@ -79,7 +80,7 @@ end # source://fugit//lib/fugit/cron.rb#5 class Fugit::Cron - # source://fugit//lib/fugit/cron.rb#433 + # source://fugit//lib/fugit/cron.rb#489 def ==(o); end # Mostly used as a #next_time sanity check. @@ -90,23 +91,23 @@ class Fugit::Cron # # Nota bene: cron with seconds are not supported. # - # source://fugit//lib/fugit/cron.rb#331 + # source://fugit//lib/fugit/cron.rb#387 def brute_frequency(year = T.unsafe(nil)); end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#200 + # source://fugit//lib/fugit/cron.rb#198 def day_match?(nt); end - # source://fugit//lib/fugit/cron.rb#433 + # source://fugit//lib/fugit/cron.rb#489 def eql?(o); end - # source://fugit//lib/fugit/cron.rb#439 + # source://fugit//lib/fugit/cron.rb#495 def hash; end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#153 + # source://fugit//lib/fugit/cron.rb#151 def hour_match?(nt); end # Returns the value of attribute hours. @@ -116,12 +117,12 @@ class Fugit::Cron # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#230 + # source://fugit//lib/fugit/cron.rb#228 def match?(t); end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#154 + # source://fugit//lib/fugit/cron.rb#152 def min_match?(nt); end # Returns the value of attribute minutes. @@ -131,12 +132,12 @@ class Fugit::Cron # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#152 + # source://fugit//lib/fugit/cron.rb#150 def month_match?(nt); end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#189 + # source://fugit//lib/fugit/cron.rb#187 def monthday_match?(nt); end # Returns the value of attribute monthdays. @@ -149,6 +150,12 @@ class Fugit::Cron # source://fugit//lib/fugit/cron.rb#22 def months; end + # Returns an ::Enumerable instance that yields each "next time" in + # succession + # + # source://fugit//lib/fugit/cron.rb#352 + def next(from = T.unsafe(nil)); end + # See gh-15 and tst/iteration_count.rb # # Initially set to 1024 after seeing the worst case for #next_time @@ -156,7 +163,7 @@ class Fugit::Cron # gh-18 and noticing some > 1024 for some experiments. 2048 should # be ok. # - # source://fugit//lib/fugit/cron.rb#247 + # source://fugit//lib/fugit/cron.rb#245 def next_time(from = T.unsafe(nil)); end # Returns the value of attribute original. @@ -164,15 +171,21 @@ class Fugit::Cron # source://fugit//lib/fugit/cron.rb#20 def original; end + # Returns an ::Enumerable instance that yields each "previous time" in + # succession + # + # source://fugit//lib/fugit/cron.rb#360 + def prev(from = T.unsafe(nil)); end + # source://fugit//lib/fugit/cron.rb#297 def previous_time(from = T.unsafe(nil)); end - # source://fugit//lib/fugit/cron.rb#361 + # source://fugit//lib/fugit/cron.rb#417 def rough_frequency; end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#155 + # source://fugit//lib/fugit/cron.rb#153 def sec_match?(nt); end # Returns the value of attribute seconds. @@ -185,28 +198,28 @@ class Fugit::Cron # source://fugit//lib/fugit/cron.rb#22 def timezone; end - # source://fugit//lib/fugit/cron.rb#418 + # source://fugit//lib/fugit/cron.rb#474 def to_a; end - # source://fugit//lib/fugit/cron.rb#55 + # source://fugit//lib/fugit/cron.rb#53 def to_cron_s; end - # source://fugit//lib/fugit/cron.rb#423 + # source://fugit//lib/fugit/cron.rb#479 def to_h; end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#157 + # source://fugit//lib/fugit/cron.rb#155 def weekday_hash_match?(nt, hsh); end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#173 + # source://fugit//lib/fugit/cron.rb#171 def weekday_match?(nt); end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#168 + # source://fugit//lib/fugit/cron.rb#166 def weekday_modulo_match?(nt, mod); end # Returns the value of attribute weekdays. @@ -214,6 +227,12 @@ class Fugit::Cron # source://fugit//lib/fugit/cron.rb#22 def weekdays; end + # Returns an array of EtOrbi::EoTime instances that correspond to + # the occurrences of the cron within the given time range + # + # source://fugit//lib/fugit/cron.rb#368 + def within(time_range, time_end = T.unsafe(nil)); end + # Returns the value of attribute zone. # # source://fugit//lib/fugit/cron.rb#20 @@ -221,50 +240,50 @@ class Fugit::Cron protected - # source://fugit//lib/fugit/cron.rb#566 - def compact(key); end - - # source://fugit//lib/fugit/cron.rb#446 + # source://fugit//lib/fugit/cron.rb#502 def compact_month_days; end - # source://fugit//lib/fugit/cron.rb#587 + # source://fugit//lib/fugit/cron.rb#656 def determine_hours(arr); end - # source://fugit//lib/fugit/cron.rb#582 + # source://fugit//lib/fugit/cron.rb#652 def determine_minutes(arr); end - # source://fugit//lib/fugit/cron.rb#594 + # source://fugit//lib/fugit/cron.rb#660 def determine_monthdays(arr); end - # source://fugit//lib/fugit/cron.rb#599 + # source://fugit//lib/fugit/cron.rb#664 def determine_months(arr); end - # source://fugit//lib/fugit/cron.rb#577 + # source://fugit//lib/fugit/cron.rb#648 def determine_seconds(arr); end - # source://fugit//lib/fugit/cron.rb#629 + # source://fugit//lib/fugit/cron.rb#695 def determine_timezone(z); end - # source://fugit//lib/fugit/cron.rb#604 + # source://fugit//lib/fugit/cron.rb#668 def determine_weekdays(arr); end - # source://fugit//lib/fugit/cron.rb#508 + # source://fugit//lib/fugit/cron.rb#631 + def do_determine(key, arr, min, max); end + + # source://fugit//lib/fugit/cron.rb#568 def expand(min, max, r); end - # source://fugit//lib/fugit/cron.rb#489 + # source://fugit//lib/fugit/cron.rb#545 def init(original, h); end - # source://fugit//lib/fugit/cron.rb#524 + # source://fugit//lib/fugit/cron.rb#589 def range(min, max, sta, edn, sla); end - # source://fugit//lib/fugit/cron.rb#462 + # source://fugit//lib/fugit/cron.rb#518 def rough_days; end - # source://fugit//lib/fugit/cron.rb#634 + # source://fugit//lib/fugit/cron.rb#702 def weekdays_to_cron_s; end class << self - # source://fugit//lib/fugit/cron.rb#48 + # source://fugit//lib/fugit/cron.rb#46 def do_parse(s); end # source://fugit//lib/fugit/cron.rb#27 @@ -275,381 +294,416 @@ class Fugit::Cron end end -# source://fugit//lib/fugit/cron.rb#487 +# Used by Fugit::Cron#next and Fugit::Cron#prev +# +# source://fugit//lib/fugit/cron.rb#327 +class Fugit::Cron::CronIterator + include ::Enumerable + + # @return [CronIterator] a new instance of CronIterator + # + # source://fugit//lib/fugit/cron.rb#332 + def initialize(cron, direction, start); end + + # Returns the value of attribute cron. + # + # source://fugit//lib/fugit/cron.rb#330 + def cron; end + + # Returns the value of attribute current. + # + # source://fugit//lib/fugit/cron.rb#330 + def current; end + + # Returns the value of attribute direction. + # + # source://fugit//lib/fugit/cron.rb#330 + def direction; end + + # source://fugit//lib/fugit/cron.rb#340 + def each; end + + # Returns the value of attribute start. + # + # source://fugit//lib/fugit/cron.rb#330 + def start; end +end + +# source://fugit//lib/fugit/cron.rb#543 Fugit::Cron::FREQUENCY_CACHE = T.let(T.unsafe(nil), Hash) -# source://fugit//lib/fugit/cron.rb#390 +# source://fugit//lib/fugit/cron.rb#446 class Fugit::Cron::Frequency # @return [Frequency] a new instance of Frequency # - # source://fugit//lib/fugit/cron.rb#395 + # source://fugit//lib/fugit/cron.rb#451 def initialize(deltas, span); end # Returns the value of attribute delta_max. # - # source://fugit//lib/fugit/cron.rb#392 + # source://fugit//lib/fugit/cron.rb#448 def delta_max; end # Returns the value of attribute delta_min. # - # source://fugit//lib/fugit/cron.rb#392 + # source://fugit//lib/fugit/cron.rb#448 def delta_min; end # Returns the value of attribute occurrences. # - # source://fugit//lib/fugit/cron.rb#392 + # source://fugit//lib/fugit/cron.rb#448 def occurrences; end # Returns the value of attribute span. # - # source://fugit//lib/fugit/cron.rb#392 + # source://fugit//lib/fugit/cron.rb#448 def span; end # Returns the value of attribute span_years. # - # source://fugit//lib/fugit/cron.rb#393 + # source://fugit//lib/fugit/cron.rb#449 def span_years; end - # source://fugit//lib/fugit/cron.rb#405 + # source://fugit//lib/fugit/cron.rb#461 def to_debug_s; end # Returns the value of attribute yearly_occurrences. # - # source://fugit//lib/fugit/cron.rb#393 + # source://fugit//lib/fugit/cron.rb#449 def yearly_occurrences; end end # source://fugit//lib/fugit/cron.rb#17 Fugit::Cron::MAXDAYS = T.let(T.unsafe(nil), Array) -# source://fugit//lib/fugit/cron.rb#238 +# source://fugit//lib/fugit/cron.rb#236 Fugit::Cron::MAX_ITERATION_COUNT = T.let(T.unsafe(nil), Integer) -# source://fugit//lib/fugit/cron.rb#652 +# source://fugit//lib/fugit/cron.rb#720 module Fugit::Cron::Parser include ::Raabro extend ::Raabro::ModuleMethods extend ::Raabro extend ::Fugit::Cron::Parser - # source://fugit//lib/fugit/cron.rb#688 + # source://fugit//lib/fugit/cron.rb#756 def _dom(i); end - # source://fugit//lib/fugit/cron.rb#690 + # source://fugit//lib/fugit/cron.rb#758 def _dow(i); end - # source://fugit//lib/fugit/cron.rb#687 + # source://fugit//lib/fugit/cron.rb#755 def _hou(i); end - # source://fugit//lib/fugit/cron.rb#689 + # source://fugit//lib/fugit/cron.rb#757 def _mon(i); end - # source://fugit//lib/fugit/cron.rb#686 + # source://fugit//lib/fugit/cron.rb#754 def _mos(i); end - # source://fugit//lib/fugit/cron.rb#747 + # source://fugit//lib/fugit/cron.rb#815 def _tz(i); end - # source://fugit//lib/fugit/cron.rb#744 + # source://fugit//lib/fugit/cron.rb#812 def _tz_delta(i); end - # source://fugit//lib/fugit/cron.rb#741 + # source://fugit//lib/fugit/cron.rb#809 def _tz_name(i); end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#674 + # source://fugit//lib/fugit/cron.rb#742 def and?(i); end - # source://fugit//lib/fugit/cron.rb#749 + # source://fugit//lib/fugit/cron.rb#817 def classic_cron(i); end - # source://fugit//lib/fugit/cron.rb#672 + # source://fugit//lib/fugit/cron.rb#740 def comma(i); end # @return [Boolean] # - # source://fugit//lib/fugit/cron.rb#673 + # source://fugit//lib/fugit/cron.rb#741 def comma?(i); end - # source://fugit//lib/fugit/cron.rb#758 + # source://fugit//lib/fugit/cron.rb#826 def cron(i); end - # source://fugit//lib/fugit/cron.rb#680 + # source://fugit//lib/fugit/cron.rb#748 def dom(i); end - # source://fugit//lib/fugit/cron.rb#716 + # source://fugit//lib/fugit/cron.rb#784 def dom_elt(i); end - # source://fugit//lib/fugit/cron.rb#682 + # source://fugit//lib/fugit/cron.rb#750 def dow(i); end - # source://fugit//lib/fugit/cron.rb#718 + # source://fugit//lib/fugit/cron.rb#786 def dow_elt(i); end - # source://fugit//lib/fugit/cron.rb#725 + # source://fugit//lib/fugit/cron.rb#793 def dow_elt_(i); end - # source://fugit//lib/fugit/cron.rb#684 + # source://fugit//lib/fugit/cron.rb#752 def dow_hash(i); end - # source://fugit//lib/fugit/cron.rb#723 + # source://fugit//lib/fugit/cron.rb#791 def h_dow(i); end - # source://fugit//lib/fugit/cron.rb#679 + # source://fugit//lib/fugit/cron.rb#747 def hou(i); end - # source://fugit//lib/fugit/cron.rb#715 + # source://fugit//lib/fugit/cron.rb#783 def hou_elt(i); end - # source://fugit//lib/fugit/cron.rb#671 + # source://fugit//lib/fugit/cron.rb#739 def hyphen(i); end - # source://fugit//lib/fugit/cron.rb#737 + # source://fugit//lib/fugit/cron.rb#805 def ldom_(i); end - # source://fugit//lib/fugit/cron.rb#739 + # source://fugit//lib/fugit/cron.rb#807 def ldow(i); end - # source://fugit//lib/fugit/cron.rb#736 + # source://fugit//lib/fugit/cron.rb#804 def lhou_(i); end - # source://fugit//lib/fugit/cron.rb#730 + # source://fugit//lib/fugit/cron.rb#798 def list_dom(i); end - # source://fugit//lib/fugit/cron.rb#732 + # source://fugit//lib/fugit/cron.rb#800 def list_dow(i); end - # source://fugit//lib/fugit/cron.rb#729 + # source://fugit//lib/fugit/cron.rb#797 def list_hou(i); end - # source://fugit//lib/fugit/cron.rb#728 + # source://fugit//lib/fugit/cron.rb#796 def list_min(i); end - # source://fugit//lib/fugit/cron.rb#731 + # source://fugit//lib/fugit/cron.rb#799 def list_mon(i); end - # source://fugit//lib/fugit/cron.rb#727 + # source://fugit//lib/fugit/cron.rb#795 def list_sec(i); end - # source://fugit//lib/fugit/cron.rb#735 + # source://fugit//lib/fugit/cron.rb#803 def lmin_(i); end - # source://fugit//lib/fugit/cron.rb#738 + # source://fugit//lib/fugit/cron.rb#806 def lmon_(i); end - # source://fugit//lib/fugit/cron.rb#734 + # source://fugit//lib/fugit/cron.rb#802 def lsec_(i); end - # source://fugit//lib/fugit/cron.rb#720 + # source://fugit//lib/fugit/cron.rb#788 def mod(i); end - # source://fugit//lib/fugit/cron.rb#722 + # source://fugit//lib/fugit/cron.rb#790 def mod_dow(i); end - # source://fugit//lib/fugit/cron.rb#681 + # source://fugit//lib/fugit/cron.rb#749 def mon(i); end - # source://fugit//lib/fugit/cron.rb#717 + # source://fugit//lib/fugit/cron.rb#785 def mon_elt(i); end # min or sec # - # source://fugit//lib/fugit/cron.rb#678 + # source://fugit//lib/fugit/cron.rb#746 def mos(i); end # ssws: slash or sorws # - # source://fugit//lib/fugit/cron.rb#714 + # source://fugit//lib/fugit/cron.rb#782 def mos_elt(i); end - # source://fugit//lib/fugit/cron.rb#695 + # source://fugit//lib/fugit/cron.rb#763 def r_dom(i); end - # source://fugit//lib/fugit/cron.rb#697 + # source://fugit//lib/fugit/cron.rb#765 def r_dow(i); end - # source://fugit//lib/fugit/cron.rb#694 + # source://fugit//lib/fugit/cron.rb#762 def r_hou(i); end - # source://fugit//lib/fugit/cron.rb#696 + # source://fugit//lib/fugit/cron.rb#764 def r_mon(i); end # r: range # - # source://fugit//lib/fugit/cron.rb#693 + # source://fugit//lib/fugit/cron.rb#761 def r_mos(i); end # rewriting the parsed tree # - # source://fugit//lib/fugit/cron.rb#764 + # source://fugit//lib/fugit/cron.rb#832 def rewrite_bound(k, t); end - # source://fugit//lib/fugit/cron.rb#825 + # source://fugit//lib/fugit/cron.rb#893 def rewrite_cron(t); end - # source://fugit//lib/fugit/cron.rb#782 + # source://fugit//lib/fugit/cron.rb#850 def rewrite_elt(k, t); end - # source://fugit//lib/fugit/cron.rb#810 + # source://fugit//lib/fugit/cron.rb#878 def rewrite_entry(t); end - # source://fugit//lib/fugit/cron.rb#774 + # source://fugit//lib/fugit/cron.rb#842 def rewrite_mod(k, t); end - # source://fugit//lib/fugit/cron.rb#817 + # source://fugit//lib/fugit/cron.rb#885 def rewrite_tz(t); end # piece parsers bottom to top # - # source://fugit//lib/fugit/cron.rb#669 + # source://fugit//lib/fugit/cron.rb#737 def s(i); end - # source://fugit//lib/fugit/cron.rb#753 + # source://fugit//lib/fugit/cron.rb#821 def second_cron(i); end - # source://fugit//lib/fugit/cron.rb#676 + # source://fugit//lib/fugit/cron.rb#744 def slash(i); end - # source://fugit//lib/fugit/cron.rb#702 + # source://fugit//lib/fugit/cron.rb#770 def sor_dom(i); end - # source://fugit//lib/fugit/cron.rb#704 + # source://fugit//lib/fugit/cron.rb#772 def sor_dow(i); end - # source://fugit//lib/fugit/cron.rb#701 + # source://fugit//lib/fugit/cron.rb#769 def sor_hou(i); end - # source://fugit//lib/fugit/cron.rb#703 + # source://fugit//lib/fugit/cron.rb#771 def sor_mon(i); end # sor: star or range # - # source://fugit//lib/fugit/cron.rb#700 + # source://fugit//lib/fugit/cron.rb#768 def sor_mos(i); end - # source://fugit//lib/fugit/cron.rb#709 + # source://fugit//lib/fugit/cron.rb#777 def sorws_dom(i); end - # source://fugit//lib/fugit/cron.rb#711 + # source://fugit//lib/fugit/cron.rb#779 def sorws_dow(i); end - # source://fugit//lib/fugit/cron.rb#708 + # source://fugit//lib/fugit/cron.rb#776 def sorws_hou(i); end - # source://fugit//lib/fugit/cron.rb#710 + # source://fugit//lib/fugit/cron.rb#778 def sorws_mon(i); end # sorws: star or range with[out] slash # - # source://fugit//lib/fugit/cron.rb#707 + # source://fugit//lib/fugit/cron.rb#775 def sorws_mos(i); end - # source://fugit//lib/fugit/cron.rb#670 + # source://fugit//lib/fugit/cron.rb#738 def star(i); end end -# source://fugit//lib/fugit/cron.rb#659 +# source://fugit//lib/fugit/cron.rb#727 Fugit::Cron::Parser::DOW_REX = T.let(T.unsafe(nil), Regexp) -# source://fugit//lib/fugit/cron.rb#662 +# source://fugit//lib/fugit/cron.rb#730 Fugit::Cron::Parser::MONTHS = T.let(T.unsafe(nil), Array) -# source://fugit//lib/fugit/cron.rb#664 +# source://fugit//lib/fugit/cron.rb#732 Fugit::Cron::Parser::MONTH_REX = T.let(T.unsafe(nil), Regexp) -# source://fugit//lib/fugit/cron.rb#654 +# source://fugit//lib/fugit/cron.rb#722 Fugit::Cron::Parser::WEEKDAYS = T.let(T.unsafe(nil), Array) -# source://fugit//lib/fugit/cron.rb#657 +# source://fugit//lib/fugit/cron.rb#725 Fugit::Cron::Parser::WEEKDS = T.let(T.unsafe(nil), Array) -# source://fugit//lib/fugit/cron.rb#355 +# source://fugit//lib/fugit/cron.rb#411 Fugit::Cron::SLOTS = T.let(T.unsafe(nil), Array) # source://fugit//lib/fugit/cron.rb#7 Fugit::Cron::SPECIALS = T.let(T.unsafe(nil), Hash) -# source://fugit//lib/fugit/cron.rb#68 +# source://fugit//lib/fugit/cron.rb#66 class Fugit::Cron::TimeCursor # @return [TimeCursor] a new instance of TimeCursor # - # source://fugit//lib/fugit/cron.rb#70 + # source://fugit//lib/fugit/cron.rb#68 def initialize(cron, t); end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def day; end - # source://fugit//lib/fugit/cron.rb#85 + # source://fugit//lib/fugit/cron.rb#83 def dec(i); end - # source://fugit//lib/fugit/cron.rb#134 + # source://fugit//lib/fugit/cron.rb#132 def dec_day; end - # source://fugit//lib/fugit/cron.rb#137 + # source://fugit//lib/fugit/cron.rb#135 def dec_hour; end - # source://fugit//lib/fugit/cron.rb#140 + # source://fugit//lib/fugit/cron.rb#138 def dec_min; end - # source://fugit//lib/fugit/cron.rb#130 + # source://fugit//lib/fugit/cron.rb#128 def dec_month; end - # source://fugit//lib/fugit/cron.rb#144 + # source://fugit//lib/fugit/cron.rb#142 def dec_sec; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def hour; end - # source://fugit//lib/fugit/cron.rb#84 + # source://fugit//lib/fugit/cron.rb#82 def inc(i); end - # source://fugit//lib/fugit/cron.rb#98 + # source://fugit//lib/fugit/cron.rb#96 def inc_day; end - # source://fugit//lib/fugit/cron.rb#115 + # source://fugit//lib/fugit/cron.rb#113 def inc_hour; end - # source://fugit//lib/fugit/cron.rb#118 + # source://fugit//lib/fugit/cron.rb#116 def inc_min; end - # source://fugit//lib/fugit/cron.rb#87 + # source://fugit//lib/fugit/cron.rb#85 def inc_month; end - # source://fugit//lib/fugit/cron.rb#122 + # source://fugit//lib/fugit/cron.rb#120 def inc_sec; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def min; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def month; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def rday; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def rweek; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def sec; end - # source://fugit//lib/fugit/cron.rb#76 + # source://fugit//lib/fugit/cron.rb#74 def time; end - # source://fugit//lib/fugit/cron.rb#79 + # source://fugit//lib/fugit/cron.rb#77 def to_i; end - # source://fugit//lib/fugit/cron.rb#77 + # source://fugit//lib/fugit/cron.rb#75 def to_t; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def wday; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def wday_in_month; end - # source://fugit//lib/fugit/cron.rb#82 + # source://fugit//lib/fugit/cron.rb#80 def year; end end @@ -1414,9 +1468,20 @@ class Fugit::Nat::SlotGroup def make_slot(key, data0, data1 = T.unsafe(nil)); end # source://fugit//lib/fugit/nat.rb#681 - def parse_cron(hm); end + def parse_cron(hm, opts); end + + # Return nil if the cron is "not strict" + # + # For example, "0 0/17 * * *" (gh-86) is a perfectly valid + # cron string, but makes not much sense when derived via `.parse_nat` + # from "every 17 hours". + # + # It happens here because it's nat being strict, not cron. + # + # source://fugit//lib/fugit/nat.rb#718 + def restrict(a, cron); end - # source://fugit//lib/fugit/nat.rb#701 + # source://fugit//lib/fugit/nat.rb#729 def slot(key, default); end end diff --git a/sorbet/rbi/gems/geocoder@1.8.1.rbi b/sorbet/rbi/gems/geocoder@1.8.3.rbi similarity index 98% rename from sorbet/rbi/gems/geocoder@1.8.1.rbi rename to sorbet/rbi/gems/geocoder@1.8.3.rbi index d52335e0e..fd5222676 100644 --- a/sorbet/rbi/gems/geocoder@1.8.1.rbi +++ b/sorbet/rbi/gems/geocoder@1.8.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `geocoder` gem. # Please instead update this file by running `bin/tapioca gem geocoder`. + class ActionDispatch::Request include ::Geocoder::Request end @@ -640,22 +641,22 @@ class Geocoder::IpAddress < ::String # @return [Boolean] # - # source://geocoder//lib/geocoder/ip_address.rb#16 + # source://geocoder//lib/geocoder/ip_address.rb#19 def internal?; end # @return [Boolean] # - # source://geocoder//lib/geocoder/ip_address.rb#20 + # source://geocoder//lib/geocoder/ip_address.rb#23 def loopback?; end # @return [Boolean] # - # source://geocoder//lib/geocoder/ip_address.rb#24 + # source://geocoder//lib/geocoder/ip_address.rb#27 def private?; end # @return [Boolean] # - # source://geocoder//lib/geocoder/ip_address.rb#28 + # source://geocoder//lib/geocoder/ip_address.rb#31 def valid?; end end @@ -738,19 +739,19 @@ module Geocoder::Lookup # Use this instead of Geocoder::Lookup::X.new to get an # already-configured Lookup object. # - # source://geocoder//lib/geocoder/lookup.rb#107 + # source://geocoder//lib/geocoder/lookup.rb#110 def get(name); end # All IP address lookup services, default first. # - # source://geocoder//lib/geocoder/lookup.rb#76 + # source://geocoder//lib/geocoder/lookup.rb#77 def ip_services; end # Sets the attribute ip_services # # @param value the value to set the attribute ip_services to. # - # source://geocoder//lib/geocoder/lookup.rb#100 + # source://geocoder//lib/geocoder/lookup.rb#103 def ip_services=(_arg0); end # All street address lookup services, default first. @@ -762,24 +763,24 @@ module Geocoder::Lookup # # @param value the value to set the attribute street_services to. # - # source://geocoder//lib/geocoder/lookup.rb#100 + # source://geocoder//lib/geocoder/lookup.rb#103 def street_services=(_arg0); end private # Convert an "underscore" version of a name into a "class" version. # - # source://geocoder//lib/geocoder/lookup.rb#133 + # source://geocoder//lib/geocoder/lookup.rb#136 def classify_name(filename); end # Safely instantiate Lookup # - # source://geocoder//lib/geocoder/lookup.rb#140 + # source://geocoder//lib/geocoder/lookup.rb#143 def instantiate_lookup(name); end # Spawn a Lookup of the given name. # - # source://geocoder//lib/geocoder/lookup.rb#119 + # source://geocoder//lib/geocoder/lookup.rb#122 def spawn(name); end end diff --git a/sorbet/rbi/gems/globalid@1.1.0.rbi b/sorbet/rbi/gems/globalid@1.2.1.rbi similarity index 52% rename from sorbet/rbi/gems/globalid@1.1.0.rbi rename to sorbet/rbi/gems/globalid@1.2.1.rbi index 401a2bf78..5b22464c7 100644 --- a/sorbet/rbi/gems/globalid@1.1.0.rbi +++ b/sorbet/rbi/gems/globalid@1.2.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `globalid` gem. # Please instead update this file by running `bin/tapioca gem globalid`. + # source://globalid//lib/global_id/global_id.rb#7 class GlobalID extend ::ActiveSupport::Autoload @@ -13,25 +14,25 @@ class GlobalID # source://globalid//lib/global_id/global_id.rb#44 def initialize(gid, options = T.unsafe(nil)); end - # source://globalid//lib/global_id/global_id.rb#62 + # source://globalid//lib/global_id/global_id.rb#63 def ==(other); end # source://globalid//lib/global_id/global_id.rb#42 def app(*_arg0, **_arg1, &_arg2); end - # source://globalid//lib/global_id/global_id.rb#75 + # source://globalid//lib/global_id/global_id.rb#76 def as_json(*_arg0); end # source://globalid//lib/global_id/global_id.rb#42 def deconstruct_keys(*_arg0, **_arg1, &_arg2); end - # source://globalid//lib/global_id/global_id.rb#62 + # source://globalid//lib/global_id/global_id.rb#63 def eql?(other); end # source://globalid//lib/global_id/global_id.rb#48 def find(options = T.unsafe(nil)); end - # source://globalid//lib/global_id/global_id.rb#67 + # source://globalid//lib/global_id/global_id.rb#68 def hash; end # source://globalid//lib/global_id/global_id.rb#52 @@ -46,7 +47,7 @@ class GlobalID # source://globalid//lib/global_id/global_id.rb#42 def params(*_arg0, **_arg1, &_arg2); end - # source://globalid//lib/global_id/global_id.rb#71 + # source://globalid//lib/global_id/global_id.rb#72 def to_param; end # source://globalid//lib/global_id/global_id.rb#42 @@ -69,6 +70,9 @@ class GlobalID # source://globalid//lib/global_id/global_id.rb#11 def create(model, options = T.unsafe(nil)); end + # source://globalid//lib/global_id.rb#20 + def deprecator; end + # source://globalid//lib/global_id.rb#15 def eager_load!; end @@ -85,24 +89,193 @@ class GlobalID end end -# source://globalid//lib/global_id/identification.rb#2 +# Mix `GlobalID::Identification` into any model with a `#find(id)` class +# method. Support is automatically included in Active Record. +# +# class Person +# include ActiveModel::Model +# include GlobalID::Identification +# +# attr_accessor :id +# +# def self.find(id) +# new id: id +# end +# +# def ==(other) +# id == other.try(:id) +# end +# end +# +# person_gid = Person.find(1).to_global_id +# # => # # "gid://app/Person/1" +# GlobalID::Locator.locate person_gid +# # => # +# +# source://globalid//lib/global_id/identification.rb#28 module GlobalID::Identification - # source://globalid//lib/global_id/identification.rb#3 + # Returns the Global ID of the model. + # + # model = Person.new id: 1 + # global_id = model.to_global_id + # global_id.modal_class # => Person + # global_id.modal_id # => "1" + # global_id.to_param # => "Z2lkOi8vYm9yZGZvbGlvL1BlcnNvbi8x" + # + # source://globalid//lib/global_id/identification.rb#37 def to_gid(options = T.unsafe(nil)); end - # source://globalid//lib/global_id/identification.rb#8 + # Returns the Global ID parameter of the model. + # + # model = Person.new id: 1 + # model.to_gid_param # => ""Z2lkOi8vYm9yZGZvbGlvL1BlcnNvbi8x" + # + # source://globalid//lib/global_id/identification.rb#46 def to_gid_param(options = T.unsafe(nil)); end - # source://globalid//lib/global_id/identification.rb#3 + # Returns the Global ID of the model. + # + # model = Person.new id: 1 + # global_id = model.to_global_id + # global_id.modal_class # => Person + # global_id.modal_id # => "1" + # global_id.to_param # => "Z2lkOi8vYm9yZGZvbGlvL1BlcnNvbi8x" + # + # source://globalid//lib/global_id/identification.rb#37 def to_global_id(options = T.unsafe(nil)); end - # source://globalid//lib/global_id/identification.rb#12 + # Returns the Signed Global ID of the model. + # Signed Global IDs ensure that the data hasn't been tampered with. + # + # model = Person.new id: 1 + # signed_global_id = model.to_signed_global_id + # signed_global_id.modal_class # => Person + # signed_global_id.modal_id # => "1" + # signed_global_id.to_param # => "BAh7CEkiCGdpZAY6BkVUSSIiZ2..." + # + # ==== Expiration + # + # Signed Global IDs can expire some time in the future. This is useful if + # there's a resource people shouldn't have indefinite access to, like a + # share link. + # + # expiring_sgid = Document.find(5).to_sgid(expires_in: 2.hours, for: 'sharing') + # # => # + # # Within 2 hours... + # GlobalID::Locator.locate_signed(expiring_sgid.to_s, for: 'sharing') + # # => # + # # More than 2 hours later... + # GlobalID::Locator.locate_signed(expiring_sgid.to_s, for: 'sharing') + # # => nil + # + # In Rails, an auto-expiry of 1 month is set by default. + # + # You need to explicitly pass `expires_in: nil` to generate a permanent + # SGID that will not expire, + # + # never_expiring_sgid = Document.find(5).to_sgid(expires_in: nil) + # # => # + # + # # Any time later... + # GlobalID::Locator.locate_signed never_expiring_sgid + # # => # + # + # It's also possible to pass a specific expiry time + # + # explicit_expiring_sgid = SecretAgentMessage.find(5).to_sgid(expires_at: Time.now.advance(hours: 1)) + # # => # + # + # # 1 hour later... + # GlobalID::Locator.locate_signed explicit_expiring_sgid.to_s + # # => nil + # + # Note that an explicit `:expires_at` takes precedence over a relative `:expires_in`. + # + # ==== Purpose + # + # You can even bump the security up some more by explaining what purpose a + # Signed Global ID is for. In this way evildoers can't reuse a sign-up + # form's SGID on the login page. For example. + # + # signup_person_sgid = Person.find(1).to_sgid(for: 'signup_form') + # # => # # + # + # source://globalid//lib/global_id/identification.rb#107 def to_sgid(options = T.unsafe(nil)); end - # source://globalid//lib/global_id/identification.rb#17 + # Returns the Signed Global ID parameter. + # + # model = Person.new id: 1 + # model.to_sgid_param # => "BAh7CEkiCGdpZAY6BkVUSSIiZ2..." + # + # source://globalid//lib/global_id/identification.rb#116 def to_sgid_param(options = T.unsafe(nil)); end - # source://globalid//lib/global_id/identification.rb#12 + # Returns the Signed Global ID of the model. + # Signed Global IDs ensure that the data hasn't been tampered with. + # + # model = Person.new id: 1 + # signed_global_id = model.to_signed_global_id + # signed_global_id.modal_class # => Person + # signed_global_id.modal_id # => "1" + # signed_global_id.to_param # => "BAh7CEkiCGdpZAY6BkVUSSIiZ2..." + # + # ==== Expiration + # + # Signed Global IDs can expire some time in the future. This is useful if + # there's a resource people shouldn't have indefinite access to, like a + # share link. + # + # expiring_sgid = Document.find(5).to_sgid(expires_in: 2.hours, for: 'sharing') + # # => # + # # Within 2 hours... + # GlobalID::Locator.locate_signed(expiring_sgid.to_s, for: 'sharing') + # # => # + # # More than 2 hours later... + # GlobalID::Locator.locate_signed(expiring_sgid.to_s, for: 'sharing') + # # => nil + # + # In Rails, an auto-expiry of 1 month is set by default. + # + # You need to explicitly pass `expires_in: nil` to generate a permanent + # SGID that will not expire, + # + # never_expiring_sgid = Document.find(5).to_sgid(expires_in: nil) + # # => # + # + # # Any time later... + # GlobalID::Locator.locate_signed never_expiring_sgid + # # => # + # + # It's also possible to pass a specific expiry time + # + # explicit_expiring_sgid = SecretAgentMessage.find(5).to_sgid(expires_at: Time.now.advance(hours: 1)) + # # => # + # + # # 1 hour later... + # GlobalID::Locator.locate_signed explicit_expiring_sgid.to_s + # # => nil + # + # Note that an explicit `:expires_at` takes precedence over a relative `:expires_in`. + # + # ==== Purpose + # + # You can even bump the security up some more by explaining what purpose a + # Signed Global ID is for. In this way evildoers can't reuse a sign-up + # form's SGID on the login page. For example. + # + # signup_person_sgid = Person.find(1).to_sgid(for: 'signup_form') + # # => # # + # + # source://globalid//lib/global_id/identification.rb#107 def to_signed_global_id(options = T.unsafe(nil)); end end @@ -112,13 +285,17 @@ module GlobalID::Locator # Takes either a GlobalID or a string that can be turned into a GlobalID # # Options: + # * :includes - A Symbol, Array, Hash or combination of them. + # The same structure you would pass into a +includes+ method of Active Record. + # If present, locate will load all the relationships specified here. + # See https://guides.rubyonrails.org/active_record_querying.html#eager-loading-associations. # * :only - A class, module or Array of classes and/or modules that are # allowed to be located. Passing one or more classes limits instances of returned # classes to those classes or their subclasses. Passing one or more modules in limits # instances of returned classes to those including that module. If no classes or # modules match, +nil+ is returned. # - # source://globalid//lib/global_id/locator.rb#14 + # source://globalid//lib/global_id/locator.rb#20 def locate(gid, options = T.unsafe(nil)); end # Takes an array of GlobalIDs or strings that can be turned into a GlobalIDs. @@ -132,6 +309,11 @@ module GlobalID::Locator # per model class, but still interpolate the results to match the order in which the gids were passed. # # Options: + # * :includes - A Symbol, Array, Hash or combination of them + # The same structure you would pass into a includes method of Active Record. + # @see https://guides.rubyonrails.org/active_record_querying.html#eager-loading-associations + # If present, locate_many will load all the relationships specified here. + # Note: It only works if all the gids models have that relationships. # * :only - A class, module or Array of classes and/or modules that are # allowed to be located. Passing one or more classes limits instances of returned # classes to those classes or their subclasses. Passing one or more modules in limits @@ -142,7 +324,7 @@ module GlobalID::Locator # #find will raise an exception if a named ID can't be found. When you set this option to true, # we will use #where(id: ids) instead, which does not raise on missing records. # - # source://globalid//lib/global_id/locator.rb#40 + # source://globalid//lib/global_id/locator.rb#60 def locate_many(gids, options = T.unsafe(nil)); end # Takes an array of SignedGlobalIDs or strings that can be turned into a SignedGlobalIDs. @@ -153,25 +335,34 @@ module GlobalID::Locator # the results to match the order in which the gids were passed. # # Options: + # * :includes - A Symbol, Array, Hash or combination of them + # The same structure you would pass into a includes method of Active Record. + # @see https://guides.rubyonrails.org/active_record_querying.html#eager-loading-associations + # If present, locate_many_signed will load all the relationships specified here. + # Note: It only works if all the gids models have that relationships. # * :only - A class, module or Array of classes and/or modules that are # allowed to be located. Passing one or more classes limits instances of returned # classes to those classes or their subclasses. Passing one or more modules in limits # instances of returned classes to those including that module. If no classes or # modules match, +nil+ is returned. # - # source://globalid//lib/global_id/locator.rb#74 + # source://globalid//lib/global_id/locator.rb#103 def locate_many_signed(sgids, options = T.unsafe(nil)); end # Takes either a SignedGlobalID or a string that can be turned into a SignedGlobalID # # Options: + # * :includes - A Symbol, Array, Hash or combination of them + # The same structure you would pass into a includes method of Active Record. + # @see https://guides.rubyonrails.org/active_record_querying.html#eager-loading-associations + # If present, locate_signed will load all the relationships specified here. # * :only - A class, module or Array of classes and/or modules that are # allowed to be located. Passing one or more classes limits instances of returned # classes to those classes or their subclasses. Passing one or more modules in limits # instances of returned classes to those including that module. If no classes or # modules match, +nil+ is returned. # - # source://globalid//lib/global_id/locator.rb#57 + # source://globalid//lib/global_id/locator.rb#81 def locate_signed(sgid, options = T.unsafe(nil)); end # Tie a locator to an app. @@ -181,7 +372,7 @@ module GlobalID::Locator # # Using a block: # - # GlobalID::Locator.use :foo do |gid| + # GlobalID::Locator.use :foo do |gid, options| # FooRemote.const_get(gid.model_name).find(gid.model_id) # end # @@ -190,76 +381,87 @@ module GlobalID::Locator # GlobalID::Locator.use :bar, BarLocator.new # # class BarLocator - # def locate(gid) + # def locate(gid, options = {}) # @search_client.search name: gid.model_name, id: gid.model_id # end # end # # @raise [ArgumentError] # - # source://globalid//lib/global_id/locator.rb#98 + # source://globalid//lib/global_id/locator.rb#127 def use(app, locator = T.unsafe(nil), &locator_block); end private # @return [Boolean] # - # source://globalid//lib/global_id/locator.rb#111 + # source://globalid//lib/global_id/locator.rb#140 def find_allowed?(model_class, only = T.unsafe(nil)); end - # source://globalid//lib/global_id/locator.rb#107 + # source://globalid//lib/global_id/locator.rb#136 def locator_for(gid); end - # source://globalid//lib/global_id/locator.rb#119 + # source://globalid//lib/global_id/locator.rb#148 def normalize_app(app); end - # source://globalid//lib/global_id/locator.rb#115 + # source://globalid//lib/global_id/locator.rb#144 def parse_allowed(gids, only = T.unsafe(nil)); end end end -# source://globalid//lib/global_id/locator.rb#127 +# source://globalid//lib/global_id/locator.rb#156 class GlobalID::Locator::BaseLocator - # source://globalid//lib/global_id/locator.rb#128 - def locate(gid); end + # source://globalid//lib/global_id/locator.rb#157 + def locate(gid, options = T.unsafe(nil)); end - # source://globalid//lib/global_id/locator.rb#132 + # source://globalid//lib/global_id/locator.rb#165 def locate_many(gids, options = T.unsafe(nil)); end private - # source://globalid//lib/global_id/locator.rb#143 + # source://globalid//lib/global_id/locator.rb#189 def find_records(model_class, ids, options); end + + # @return [Boolean] + # + # source://globalid//lib/global_id/locator.rb#199 + def model_id_is_valid?(gid); end + + # source://globalid//lib/global_id/locator.rb#203 + def primary_key(model_class); end end -# source://globalid//lib/global_id/locator.rb#172 +# source://globalid//lib/global_id/locator.rb#228 class GlobalID::Locator::BlockLocator # @return [BlockLocator] a new instance of BlockLocator # - # source://globalid//lib/global_id/locator.rb#173 + # source://globalid//lib/global_id/locator.rb#229 def initialize(block); end - # source://globalid//lib/global_id/locator.rb#177 - def locate(gid); end + # source://globalid//lib/global_id/locator.rb#233 + def locate(gid, options = T.unsafe(nil)); end - # source://globalid//lib/global_id/locator.rb#181 + # source://globalid//lib/global_id/locator.rb#237 def locate_many(gids, options = T.unsafe(nil)); end end -# source://globalid//lib/global_id/locator.rb#170 +# source://globalid//lib/global_id/locator.rb#226 GlobalID::Locator::DEFAULT_LOCATOR = T.let(T.unsafe(nil), GlobalID::Locator::UnscopedLocator) -# source://globalid//lib/global_id/locator.rb#152 +# source://globalid//lib/global_id/locator.rb#5 +class GlobalID::Locator::InvalidModelIdError < ::StandardError; end + +# source://globalid//lib/global_id/locator.rb#208 class GlobalID::Locator::UnscopedLocator < ::GlobalID::Locator::BaseLocator - # source://globalid//lib/global_id/locator.rb#153 - def locate(gid); end + # source://globalid//lib/global_id/locator.rb#209 + def locate(gid, options = T.unsafe(nil)); end private - # source://globalid//lib/global_id/locator.rb#158 + # source://globalid//lib/global_id/locator.rb#214 def find_records(model_class, ids, options); end - # source://globalid//lib/global_id/locator.rb#162 + # source://globalid//lib/global_id/locator.rb#218 def unscoped(model_class); end end @@ -271,71 +473,68 @@ class GlobalID::Verifier < ::ActiveSupport::MessageVerifier private # source://globalid//lib/global_id/verifier.rb#10 - def decode(data); end + def decode(data, **_arg1); end # source://globalid//lib/global_id/verifier.rb#6 - def encode(data); end + def encode(data, **_arg1); end end # source://globalid//lib/global_id/signed_global_id.rb#4 class SignedGlobalID < ::GlobalID # @return [SignedGlobalID] a new instance of SignedGlobalID # - # source://globalid//lib/global_id/signed_global_id.rb#50 + # source://globalid//lib/global_id/signed_global_id.rb#59 def initialize(gid, options = T.unsafe(nil)); end - # source://globalid//lib/global_id/signed_global_id.rb#68 + # source://globalid//lib/global_id/signed_global_id.rb#71 def ==(other); end # Returns the value of attribute expires_at. # - # source://globalid//lib/global_id/signed_global_id.rb#48 + # source://globalid//lib/global_id/signed_global_id.rb#57 def expires_at; end + # source://globalid//lib/global_id/signed_global_id.rb#75 + def inspect; end + # Returns the value of attribute purpose. # - # source://globalid//lib/global_id/signed_global_id.rb#48 + # source://globalid//lib/global_id/signed_global_id.rb#57 def purpose; end - # source://globalid//lib/global_id/signed_global_id.rb#62 - def to_h; end - - # source://globalid//lib/global_id/signed_global_id.rb#57 + # source://globalid//lib/global_id/signed_global_id.rb#66 def to_param; end - # source://globalid//lib/global_id/signed_global_id.rb#57 + # source://globalid//lib/global_id/signed_global_id.rb#66 def to_s; end # Returns the value of attribute verifier. # - # source://globalid//lib/global_id/signed_global_id.rb#48 + # source://globalid//lib/global_id/signed_global_id.rb#57 def verifier; end private - # source://globalid//lib/global_id/signed_global_id.rb#73 - def encoded_expiration; end - - # source://globalid//lib/global_id/signed_global_id.rb#77 + # source://globalid//lib/global_id/signed_global_id.rb#80 def pick_expiration(options); end class << self # Returns the value of attribute expires_in. # - # source://globalid//lib/global_id/signed_global_id.rb#22 + # source://globalid//lib/global_id/signed_global_id.rb#8 def expires_in; end # Sets the attribute expires_in # # @param value the value to set the attribute expires_in to. # - # source://globalid//lib/global_id/signed_global_id.rb#22 + # source://globalid//lib/global_id/signed_global_id.rb#8 def expires_in=(_arg0); end # source://globalid//lib/global_id/signed_global_id.rb#10 def parse(sgid, options = T.unsafe(nil)); end - # source://globalid//lib/global_id/signed_global_id.rb#26 + # source://globalid//lib/global_id/signed_global_id.rb#24 def pick_purpose(options); end # Grab the verifier from options and fall back to SignedGlobalID.verifier. @@ -358,11 +557,17 @@ class SignedGlobalID < ::GlobalID private - # source://globalid//lib/global_id/signed_global_id.rb#41 + # source://globalid//lib/global_id/signed_global_id.rb#50 def raise_if_expired(expires_at); end - # source://globalid//lib/global_id/signed_global_id.rb#31 + # source://globalid//lib/global_id/signed_global_id.rb#29 def verify(sgid, options); end + + # source://globalid//lib/global_id/signed_global_id.rb#40 + def verify_with_legacy_self_validated_metadata(sgid, options); end + + # source://globalid//lib/global_id/signed_global_id.rb#34 + def verify_with_verifier_validated_metadata(sgid, options); end end end @@ -392,10 +597,10 @@ class URI::GID < ::URI::Generic # # Read the documentation for +parse+, +create+ and +build+ for more. # - # source://uri/0.12.0/uri/generic.rb#243 + # source://uri/0.13.0/uri/generic.rb#243 def app; end - # source://globalid//lib/global_id/uri/gid.rb#101 + # source://globalid//lib/global_id/uri/gid.rb#107 def deconstruct_keys(_keys); end # Returns the value of attribute model_id. @@ -413,53 +618,58 @@ class URI::GID < ::URI::Generic # source://globalid//lib/global_id/uri/gid.rb#29 def params; end - # source://globalid//lib/global_id/uri/gid.rb#96 + # source://globalid//lib/global_id/uri/gid.rb#102 def to_s; end protected # Ruby 2.2 uses #query= instead of #set_query # - # source://globalid//lib/global_id/uri/gid.rb#112 + # source://globalid//lib/global_id/uri/gid.rb#118 def query=(query); end - # source://globalid//lib/global_id/uri/gid.rb#123 + # source://globalid//lib/global_id/uri/gid.rb#129 def set_params(params); end - # source://globalid//lib/global_id/uri/gid.rb#106 + # source://globalid//lib/global_id/uri/gid.rb#112 def set_path(path); end # Ruby 2.1 or less uses #set_query to assign the query # - # source://globalid//lib/global_id/uri/gid.rb#118 + # source://globalid//lib/global_id/uri/gid.rb#124 def set_query(query); end private - # source://globalid//lib/global_id/uri/gid.rb#130 + # source://globalid//lib/global_id/uri/gid.rb#136 def check_host(host); end - # source://globalid//lib/global_id/uri/gid.rb#135 + # source://globalid//lib/global_id/uri/gid.rb#141 def check_path(path); end - # source://globalid//lib/global_id/uri/gid.rb#140 + # source://globalid//lib/global_id/uri/gid.rb#146 def check_scheme(scheme); end - # source://globalid//lib/global_id/uri/gid.rb#172 + # source://globalid//lib/global_id/uri/gid.rb#195 def parse_query_params(query); end - # source://globalid//lib/global_id/uri/gid.rb#148 + # source://globalid//lib/global_id/uri/gid.rb#154 def set_model_components(path, validate = T.unsafe(nil)); end # @raise [URI::InvalidComponentError] # - # source://globalid//lib/global_id/uri/gid.rb#158 + # source://globalid//lib/global_id/uri/gid.rb#174 def validate_component(component); end + # @raise [InvalidModelIdError] + # + # source://globalid//lib/global_id/uri/gid.rb#188 + def validate_model_id(model_id_part); end + # @raise [MissingModelIdError] # - # source://globalid//lib/global_id/uri/gid.rb#165 - def validate_model_id(model_id, model_name); end + # source://globalid//lib/global_id/uri/gid.rb#181 + def validate_model_id_section(model_id, model_name); end class << self # Create a new URI::GID from components with argument check. @@ -475,14 +685,14 @@ class URI::GID < ::URI::Generic # # URI::GID.build(['bcx', 'Person', '1', key: 'value']) # - # source://globalid//lib/global_id/uri/gid.rb#83 + # source://globalid//lib/global_id/uri/gid.rb#88 def build(args); end # Shorthand to build a URI::GID from an app, a model and optional params. # # URI::GID.create('bcx', Person.find(5), database: 'superhumans') # - # source://globalid//lib/global_id/uri/gid.rb#67 + # source://globalid//lib/global_id/uri/gid.rb#72 def create(app, model, params = T.unsafe(nil)); end # Create a new URI::GID by parsing a gid string with argument check. @@ -495,7 +705,7 @@ class URI::GID < ::URI::Generic # URI.parse('gid://bcx') # => URI::GID instance # URI::GID.parse('gid://bcx/') # => raises URI::InvalidComponentError # - # source://globalid//lib/global_id/uri/gid.rb#59 + # source://globalid//lib/global_id/uri/gid.rb#64 def parse(uri); end # Validates +app+'s as URI hostnames containing only alphanumeric characters @@ -507,14 +717,25 @@ class URI::GID < ::URI::Generic # URI::GID.validate_app(nil) # => ArgumentError # URI::GID.validate_app('foo/bar') # => ArgumentError # - # source://globalid//lib/global_id/uri/gid.rb#43 + # source://globalid//lib/global_id/uri/gid.rb#48 def validate_app(app); end end end -# source://globalid//lib/global_id/uri/gid.rb#128 +# source://globalid//lib/global_id/uri/gid.rb#134 URI::GID::COMPONENT = T.let(T.unsafe(nil), Array) +# source://globalid//lib/global_id/uri/gid.rb#37 +URI::GID::COMPOSITE_MODEL_ID_DELIMITER = T.let(T.unsafe(nil), String) + +# Maximum size of a model id segment +# +# source://globalid//lib/global_id/uri/gid.rb#36 +URI::GID::COMPOSITE_MODEL_ID_MAX_SIZE = T.let(T.unsafe(nil), Integer) + +# source://globalid//lib/global_id/uri/gid.rb#33 +class URI::GID::InvalidModelIdError < ::URI::InvalidComponentError; end + # Raised when creating a Global ID for a model without an id # # source://globalid//lib/global_id/uri/gid.rb#32 diff --git a/sorbet/rbi/gems/google_visualr@2.1.6-c6d34b87721639cb79235a6828585d604a49ced0.rbi b/sorbet/rbi/gems/google_visualr@2.1.6-c6d34b87721639cb79235a6828585d604a49ced0.rbi index 30a0a090d..2ffe31d8b 100644 --- a/sorbet/rbi/gems/google_visualr@2.1.6-c6d34b87721639cb79235a6828585d604a49ced0.rbi +++ b/sorbet/rbi/gems/google_visualr@2.1.6-c6d34b87721639cb79235a6828585d604a49ced0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `google_visualr` gem. # Please instead update this file by running `bin/tapioca gem google_visualr`. + # source://google_visualr//lib/google_visualr/param_helpers.rb#1 module GoogleVisualr; end diff --git a/sorbet/rbi/gems/haml@6.1.1.rbi b/sorbet/rbi/gems/haml@6.3.0.rbi similarity index 94% rename from sorbet/rbi/gems/haml@6.1.1.rbi rename to sorbet/rbi/gems/haml@6.3.0.rbi index ea1aaf8b3..b61262ca5 100644 --- a/sorbet/rbi/gems/haml@6.1.1.rbi +++ b/sorbet/rbi/gems/haml@6.3.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `haml` gem. # Please instead update this file by running `bin/tapioca gem haml`. + # There are only helpers that depend on ActionView internals. # # source://haml//lib/haml/error.rb#2 @@ -23,54 +24,77 @@ end # source://haml//lib/haml/attribute_builder.rb#4 module Haml::AttributeBuilder class << self - def build(*_arg0); end - def build_aria(*_arg0); end - def build_class(*_arg0); end - def build_data(*_arg0); end - def build_id(*_arg0); end + # source://haml//lib/haml/attribute_builder.rb#6 + def build(escape_attrs, quote, format, object_ref, *hashes); end + + # source://haml//lib/haml/attribute_builder.rb#69 + def build_aria(escape_attrs, quote, *hashes); end + + # source://haml//lib/haml/attribute_builder.rb#35 + def build_class(escape_attrs, *values); end + + # source://haml//lib/haml/attribute_builder.rb#65 + def build_data(escape_attrs, quote, *hashes); end + + # source://haml//lib/haml/attribute_builder.rb#31 + def build_id(escape_attrs, *values); end + + private + + # source://haml//lib/haml/attribute_builder.rb#138 + def build_boolean!(escape_attrs, quote, format, buf, key, value); end + + # source://haml//lib/haml/attribute_builder.rb#75 + def build_data_attribute(key, escape_attrs, quote, *hashes); end + + # source://haml//lib/haml/attribute_builder.rb#154 + def escape_html(escape_attrs, str); end + + # source://haml//lib/haml/attribute_builder.rb#97 + def flatten_attributes(attributes); end + + # source://haml//lib/haml/attribute_builder.rb#118 + def merge_all_attrs(hashes); end end end -# source://haml//lib/haml/attribute_builder.rb#5 -Haml::AttributeBuilder::BOOLEAN_ATTRIBUTES = T.let(T.unsafe(nil), Array) - -# source://haml//lib/haml/attribute_compiler.rb#7 +# source://haml//lib/haml/attribute_compiler.rb#15 class Haml::AttributeCompiler # @return [AttributeCompiler] a new instance of AttributeCompiler # - # source://haml//lib/haml/attribute_compiler.rb#8 + # source://haml//lib/haml/attribute_compiler.rb#16 def initialize(identity, options); end - # source://haml//lib/haml/attribute_compiler.rb#15 + # source://haml//lib/haml/attribute_compiler.rb#23 def compile(node); end private - # source://haml//lib/haml/attribute_compiler.rb#118 + # source://haml//lib/haml/attribute_compiler.rb#123 def attribute_builder(type, values); end - # source://haml//lib/haml/attribute_compiler.rb#93 + # source://haml//lib/haml/attribute_compiler.rb#98 def compile_boolean!(temple, key, values); end - # source://haml//lib/haml/attribute_compiler.rb#73 + # source://haml//lib/haml/attribute_compiler.rb#78 def compile_class!(temple, key, values); end - # source://haml//lib/haml/attribute_compiler.rb#114 + # source://haml//lib/haml/attribute_compiler.rb#119 def compile_common!(temple, key, values); end - # source://haml//lib/haml/attribute_compiler.rb#82 + # source://haml//lib/haml/attribute_compiler.rb#87 def compile_data!(temple, key, values); end - # source://haml//lib/haml/attribute_compiler.rb#64 + # source://haml//lib/haml/attribute_compiler.rb#69 def compile_id!(temple, key, values); end - # source://haml//lib/haml/attribute_compiler.rb#123 + # source://haml//lib/haml/attribute_compiler.rb#128 def literal_for(value); end - # source://haml//lib/haml/attribute_compiler.rb#30 + # source://haml//lib/haml/attribute_compiler.rb#38 def runtime_compile(node); end - # source://haml//lib/haml/attribute_compiler.rb#41 + # source://haml//lib/haml/attribute_compiler.rb#46 def static_compile(static_hash, dynamic_hashes); end end @@ -114,6 +138,11 @@ end # source://haml//lib/haml/attribute_parser.rb#6 class Haml::AttributeParser::ParseSkip < ::StandardError; end +# The list of boolean attributes. You may add custom attributes to this constant. +# +# source://haml//lib/haml/attribute_compiler.rb#8 +Haml::BOOLEAN_ATTRIBUTES = T.let(T.unsafe(nil), Array) + # source://haml//lib/haml/compiler/children_compiler.rb#5 class Haml::Compiler # @return [Compiler] a new instance of Compiler @@ -236,10 +265,13 @@ class Haml::Compiler::DoctypeCompiler private - # source://haml//lib/haml/compiler/doctype_compiler.rb#22 + # source://haml//lib/haml/compiler/doctype_compiler.rb#24 def html_doctype(node); end - # source://haml//lib/haml/compiler/doctype_compiler.rb#36 + # source://haml//lib/haml/compiler/doctype_compiler.rb#47 + def rdfa_doctype; end + + # source://haml//lib/haml/compiler/doctype_compiler.rb#38 def xml_doctype; end end @@ -391,7 +423,7 @@ class Haml::EscapeAny < ::Haml::Escape # source://haml//lib/haml/escape_any.rb#17 def on_dynamic(value); end - # source://temple/0.10.2/lib/temple/filters/escapable.rb#24 + # source://temple/0.10.3/lib/temple/filters/escapable.rb#24 def on_escapeany(flag, exp); end end @@ -624,7 +656,7 @@ class Haml::ForceEscape < ::Haml::Escape # source://haml//lib/haml/force_escape.rb#25 def on_escape(flag, exp); end - # source://temple/0.10.2/lib/temple/filters/escapable.rb#24 + # source://temple/0.10.3/lib/temple/filters/escapable.rb#24 def on_fescape(flag, exp); end end @@ -1452,7 +1484,7 @@ module Haml::Util # and the rest of the string. # `["Foo (Bar (Baz bang) bop)", " (Bang (bop bip))"]` in the example above. # - # source://haml//lib/haml/util.rb#171 + # source://haml//lib/haml/util.rb#172 def balance(scanner, start, finish, count = T.unsafe(nil)); end # Checks that the encoding of a string is valid @@ -1466,7 +1498,7 @@ module Haml::Util # Only yields if there is an encoding error # @yieldparam msg [String] The error message to be raised # - # source://haml//lib/haml/util.rb#65 + # source://haml//lib/haml/util.rb#66 def check_encoding(str); end # Like {\#check\_encoding}, but also checks for a Ruby-style `-# coding:` comment @@ -1489,12 +1521,12 @@ module Haml::Util # Only yields if there is an encoding error # @yieldparam msg [String] The error message to be raised # - # source://haml//lib/haml/util.rb#112 + # source://haml//lib/haml/util.rb#113 def check_haml_encoding(str, &block); end # @return [Boolean] # - # source://haml//lib/haml/util.rb#200 + # source://haml//lib/haml/util.rb#201 def contains_interpolation?(str); end # Scans through a string looking for the interoplation-opening `#{` @@ -1508,7 +1540,7 @@ module Haml::Util # @return [String] The text remaining in the scanner after all `#{`s have been processed # @yieldparam scan [StringScanner] The scanner scanning through the string # - # source://haml//lib/haml/util.rb#150 + # source://haml//lib/haml/util.rb#151 def handle_interpolation(str); end # Formats a string for use in error messages about indentation. @@ -1516,7 +1548,7 @@ module Haml::Util # @param indentation [String] The string used for indentation # @return [String] The name of the indentation (e.g. `"12 spaces"`, `"1 tab"`) # - # source://haml//lib/haml/util.rb#187 + # source://haml//lib/haml/util.rb#188 def human_indentation(indentation); end # Like `Object#inspect`, but preserves non-ASCII characters rather than escaping them. @@ -1526,7 +1558,7 @@ module Haml::Util # @param obj [Object] # @return [String] # - # source://haml//lib/haml/util.rb#129 + # source://haml//lib/haml/util.rb#130 def inspect_obj(obj); end # Whether or not ActionView's XSS protection is available and enabled, @@ -1535,17 +1567,17 @@ module Haml::Util # # @return [Boolean] # - # source://haml//lib/haml/util.rb#51 + # source://haml//lib/haml/util.rb#52 def rails_xss_safe?; end # Silence all output to STDERR within a block. # # @yield A block in which no output will be printed to STDERR # - # source://haml//lib/haml/util.rb#37 + # source://haml//lib/haml/util.rb#38 def silence_warnings; end - # source://haml//lib/haml/util.rb#204 + # source://haml//lib/haml/util.rb#205 def unescape_interpolation(str, escape_html = T.unsafe(nil)); end private @@ -1556,10 +1588,10 @@ module Haml::Util # @return [(Boolean, String or nil)] Whether the document begins with a UTF-8 BOM, # and the declared encoding of the document (or nil if none is declared) # - # source://haml//lib/haml/util.rb#236 + # source://haml//lib/haml/util.rb#237 def parse_haml_magic_comment(str); end - # source://haml//lib/haml/util.rb#248 + # source://haml//lib/haml/util.rb#249 def try_parse_haml_emacs_magic_comment(scanner); end class << self @@ -1567,7 +1599,7 @@ module Haml::Util # TODO: Remove unescape_interpolation's workaround and get rid of `respond_to?`. # - # source://haml//lib/haml/util.rb#29 + # source://haml//lib/haml/util.rb#30 def escape_html_safe(html); end end end diff --git a/sorbet/rbi/gems/hashdiff@1.0.1.rbi b/sorbet/rbi/gems/hashdiff@1.1.1.rbi similarity index 96% rename from sorbet/rbi/gems/hashdiff@1.0.1.rbi rename to sorbet/rbi/gems/hashdiff@1.1.1.rbi index dd7e6df97..7cdfa9c99 100644 --- a/sorbet/rbi/gems/hashdiff@1.0.1.rbi +++ b/sorbet/rbi/gems/hashdiff@1.1.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `hashdiff` gem. # Please instead update this file by running `bin/tapioca gem hashdiff`. + # This module provides methods to diff two hash, patch and unpatch hash # # source://hashdiff//lib/hashdiff/util.rb#3 @@ -22,6 +23,7 @@ module Hashdiff # @param obj2 [Array, Hash] # @param options [Hash] the options to use when comparing # * :strict (Boolean) [true] whether numeric values will be compared on type as well as value. Set to false to allow comparing Integer, Float, BigDecimal to each other + # * :ignore_keys (Symbol, String or Array) [[]] a list of keys to ignore. No comparison is made for the specified key(s) in either hash # * :indifferent (Boolean) [false] whether to treat hash keys indifferently. Set to true to ignore differences between symbol keys (ie. {a: 1} ~= {'a' => 1}) # * :delimiter (String) ['.'] the delimiter used when returning nested key references # * :numeric_tolerance (Numeric) [0] should be a positive numeric value. Value by which numeric differences must be greater than. By default, numeric values are compared exactly; with the :tolerance option, the difference between numeric values must be greater than the given value. @@ -33,7 +35,7 @@ module Hashdiff # @since 0.0.1 # @yield [path, value1, value2] Optional block is used to compare each value, instead of default #==. If the block returns value other than true of false, then other specified comparison options will be used to do the comparison. # - # source://hashdiff//lib/hashdiff/diff.rb#31 + # source://hashdiff//lib/hashdiff/diff.rb#32 def best_diff(obj1, obj2, options = T.unsafe(nil), &block); end # check if objects are comparable @@ -94,6 +96,7 @@ module Hashdiff # @param obj2 [Array, Hash] # @param options [Hash] the options to use when comparing # * :strict (Boolean) [true] whether numeric values will be compared on type as well as value. Set to false to allow comparing Integer, Float, BigDecimal to each other + # * :ignore_keys (Symbol, String or Array) [[]] a list of keys to ignore. No comparison is made for the specified key(s) in either hash # * :indifferent (Boolean) [false] whether to treat hash keys indifferently. Set to true to ignore differences between symbol keys (ie. {a: 1} ~= {'a' => 1}) # * :similarity (Numeric) [0.8] should be between (0, 1]. Meaningful if there are similar hashes in arrays. See {best_diff}. # * :delimiter (String) ['.'] the delimiter used when returning nested key references @@ -106,7 +109,7 @@ module Hashdiff # @since 0.0.1 # @yield [path, value1, value2] Optional block is used to compare each value, instead of default #==. If the block returns value other than true of false, then other specified comparison options will be used to do the comparison. # - # source://hashdiff//lib/hashdiff/diff.rb#78 + # source://hashdiff//lib/hashdiff/diff.rb#80 def diff(obj1, obj2, options = T.unsafe(nil), &block); end # diff array using LCS algorithm @@ -114,7 +117,7 @@ module Hashdiff # @private # @yield [links] # - # source://hashdiff//lib/hashdiff/diff.rb#119 + # source://hashdiff//lib/hashdiff/diff.rb#124 def diff_array_lcs(arraya, arrayb, options = T.unsafe(nil)); end # caculate array difference using LCS algorithm diff --git a/sorbet/rbi/gems/hashie@5.0.0.rbi b/sorbet/rbi/gems/hashie@5.0.0.rbi index 14a4fd361..1861f8330 100644 --- a/sorbet/rbi/gems/hashie@5.0.0.rbi +++ b/sorbet/rbi/gems/hashie@5.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `hashie` gem. # Please instead update this file by running `bin/tapioca gem hashie`. + # source://hashie//lib/hashie/logger.rb#3 module Hashie extend ::Hashie::Extensions::StringifyKeys::ClassMethods diff --git a/sorbet/rbi/gems/hiredis@0.6.3.rbi b/sorbet/rbi/gems/hiredis@0.6.3.rbi index c3f56af8d..014dd0a14 100644 --- a/sorbet/rbi/gems/hiredis@0.6.3.rbi +++ b/sorbet/rbi/gems/hiredis@0.6.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `hiredis` gem. # Please instead update this file by running `bin/tapioca gem hiredis`. + # source://hiredis//lib/hiredis/version.rb#1 module Hiredis; end diff --git a/sorbet/rbi/gems/hive_geoip2@0.1.2.rbi b/sorbet/rbi/gems/hive_geoip2@0.1.3.rbi similarity index 99% rename from sorbet/rbi/gems/hive_geoip2@0.1.2.rbi rename to sorbet/rbi/gems/hive_geoip2@0.1.3.rbi index e34feef93..06eb72938 100644 --- a/sorbet/rbi/gems/hive_geoip2@0.1.2.rbi +++ b/sorbet/rbi/gems/hive_geoip2@0.1.3.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `hive_geoip2` gem. # Please instead update this file by running `bin/tapioca gem hive_geoip2`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/hotwire-rails@0.1.3.rbi b/sorbet/rbi/gems/hotwire-rails@0.1.3.rbi index c82f0fc6f..8a9ea11af 100644 --- a/sorbet/rbi/gems/hotwire-rails@0.1.3.rbi +++ b/sorbet/rbi/gems/hotwire-rails@0.1.3.rbi @@ -4,11 +4,17 @@ # This is an autogenerated file for types exported from the `hotwire-rails` gem. # Please instead update this file by running `bin/tapioca gem hotwire-rails`. + # source://hotwire-rails//lib/hotwire-rails.rb#1 module Hotwire; end # source://hotwire-rails//lib/hotwire/engine.rb#2 -class Hotwire::Engine < ::Rails::Engine; end +class Hotwire::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # source://hotwire-rails//lib/hotwire/version.rb#2 Hotwire::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/http-cookie@1.0.5.rbi b/sorbet/rbi/gems/http-cookie@1.0.7.rbi similarity index 87% rename from sorbet/rbi/gems/http-cookie@1.0.5.rbi rename to sorbet/rbi/gems/http-cookie@1.0.7.rbi index 9fc5bc540..b0fa1951d 100644 --- a/sorbet/rbi/gems/http-cookie@1.0.5.rbi +++ b/sorbet/rbi/gems/http-cookie@1.0.7.rbi @@ -4,10 +4,11 @@ # This is an autogenerated file for types exported from the `http-cookie` gem. # Please instead update this file by running `bin/tapioca gem http-cookie`. + # source://http-cookie//lib/http/cookie/version.rb#1 module HTTP class << self - # source://http/5.1.1/lib/http/chainable.rb#182 + # source://http/5.2.0/lib/http/chainable.rb#182 def [](headers); end end end @@ -45,13 +46,13 @@ class HTTP::Cookie # # @return [Cookie] a new instance of Cookie # - # source://http-cookie//lib/http/cookie.rb#130 + # source://http-cookie//lib/http/cookie.rb#133 def initialize(*args); end # Compares the cookie with another. When there are many cookies with # the same name for a URL, the value of the smallest must be used. # - # source://http-cookie//lib/http/cookie.rb#643 + # source://http-cookie//lib/http/cookie.rb#646 def <=>(other); end # Tests if it is OK to accept this cookie considering its origin. @@ -60,7 +61,7 @@ class HTTP::Cookie # # @return [Boolean] # - # source://http-cookie//lib/http/cookie.rb#569 + # source://http-cookie//lib/http/cookie.rb#572 def acceptable?; end # Tests if it is OK to accept this cookie if it is sent from a given @@ -68,90 +69,90 @@ class HTTP::Cookie # # @return [Boolean] # - # source://http-cookie//lib/http/cookie.rb#550 + # source://http-cookie//lib/http/cookie.rb#553 def acceptable_from_uri?(uri); end # The time this cookie was last accessed at. # - # source://http-cookie//lib/http/cookie.rb#546 + # source://http-cookie//lib/http/cookie.rb#549 def accessed_at; end # The time this cookie was last accessed at. # - # source://http-cookie//lib/http/cookie.rb#546 + # source://http-cookie//lib/http/cookie.rb#549 def accessed_at=(_arg0); end # Returns a string for use in the Cookie header, i.e. `name=value` # or `name="value"`. # - # source://http-cookie//lib/http/cookie.rb#596 + # source://http-cookie//lib/http/cookie.rb#599 def cookie_value; end # The time this cookie was created at. This value is used as a base # date for interpreting the Max-Age attribute value. See #expires. # - # source://http-cookie//lib/http/cookie.rb#543 + # source://http-cookie//lib/http/cookie.rb#546 def created_at; end # The time this cookie was created at. This value is used as a base # date for interpreting the Max-Age attribute value. See #expires. # - # source://http-cookie//lib/http/cookie.rb#543 + # source://http-cookie//lib/http/cookie.rb#546 def created_at=(_arg0); end # Returns the value of attribute domain. # - # source://http-cookie//lib/http/cookie.rb#383 + # source://http-cookie//lib/http/cookie.rb#386 def domain; end # See #domain. # - # source://http-cookie//lib/http/cookie.rb#386 + # source://http-cookie//lib/http/cookie.rb#389 def domain=(domain); end # Returns the domain attribute value as a DomainName object. # - # source://http-cookie//lib/http/cookie.rb#431 + # source://http-cookie//lib/http/cookie.rb#434 def domain_name; end # Returns the domain, with a dot prefixed only if the domain flag is # on. # - # source://http-cookie//lib/http/cookie.rb#426 + # source://http-cookie//lib/http/cookie.rb#429 def dot_domain; end # YAML serialization helper for Psych. # - # source://http-cookie//lib/http/cookie.rb#659 + # source://http-cookie//lib/http/cookie.rb#662 def encode_with(coder); end # Expires this cookie by setting the expires attribute value to a # past date. # - # source://http-cookie//lib/http/cookie.rb#536 + # source://http-cookie//lib/http/cookie.rb#539 def expire!; end # Tests if this cookie is expired by now, or by a given time. # # @return [Boolean] # - # source://http-cookie//lib/http/cookie.rb#526 + # source://http-cookie//lib/http/cookie.rb#529 def expired?(time = T.unsafe(nil)); end - # source://http-cookie//lib/http/cookie.rb#485 + # source://http-cookie//lib/http/cookie.rb#488 def expires; end # See #expires. # - # source://http-cookie//lib/http/cookie.rb#490 + # source://http-cookie//lib/http/cookie.rb#493 def expires=(t); end - # source://http-cookie//lib/http/cookie.rb#485 + # source://http-cookie//lib/http/cookie.rb#488 def expires_at; end # See #expires. # - # source://http-cookie//lib/http/cookie.rb#490 + # source://http-cookie//lib/http/cookie.rb#493 def expires_at=(t); end # The domain flag. (the opposite of host-only-flag) @@ -160,7 +161,7 @@ class HTTP::Cookie # \#domain, including the host domain itself. If it is false, this # cookie will be sent only to the host indicated by the #domain. # - # source://http-cookie//lib/http/cookie.rb#438 + # source://http-cookie//lib/http/cookie.rb#441 def for_domain; end # The domain flag. (the opposite of host-only-flag) @@ -169,7 +170,7 @@ class HTTP::Cookie # \#domain, including the host domain itself. If it is false, this # cookie will be sent only to the host indicated by the #domain. # - # source://http-cookie//lib/http/cookie.rb#438 + # source://http-cookie//lib/http/cookie.rb#441 def for_domain=(_arg0); end # The domain flag. (the opposite of host-only-flag) @@ -178,76 +179,76 @@ class HTTP::Cookie # \#domain, including the host domain itself. If it is false, this # cookie will be sent only to the host indicated by the #domain. # - # source://http-cookie//lib/http/cookie.rb#438 + # source://http-cookie//lib/http/cookie.rb#441 def for_domain?; end # The HttpOnly flag. (http-only-flag) # # A cookie with this flag on should be hidden from a client script. # - # source://http-cookie//lib/http/cookie.rb#476 + # source://http-cookie//lib/http/cookie.rb#479 def httponly; end # The HttpOnly flag. (http-only-flag) # # A cookie with this flag on should be hidden from a client script. # - # source://http-cookie//lib/http/cookie.rb#476 + # source://http-cookie//lib/http/cookie.rb#479 def httponly=(_arg0); end # The HttpOnly flag. (http-only-flag) # # A cookie with this flag on should be hidden from a client script. # - # source://http-cookie//lib/http/cookie.rb#476 + # source://http-cookie//lib/http/cookie.rb#479 def httponly?; end # YAML deserialization helper for Syck. # - # source://http-cookie//lib/http/cookie.rb#666 + # source://http-cookie//lib/http/cookie.rb#669 def init_with(coder); end - # source://http-cookie//lib/http/cookie.rb#635 + # source://http-cookie//lib/http/cookie.rb#638 def inspect; end # Returns the value of attribute max_age. # - # source://http-cookie//lib/http/cookie.rb#504 + # source://http-cookie//lib/http/cookie.rb#507 def max_age; end # See #max_age. # - # source://http-cookie//lib/http/cookie.rb#507 + # source://http-cookie//lib/http/cookie.rb#510 def max_age=(sec); end # Returns the value of attribute name. # - # source://http-cookie//lib/http/cookie.rb#347 + # source://http-cookie//lib/http/cookie.rb#350 def name; end # See #name. # - # source://http-cookie//lib/http/cookie.rb#350 + # source://http-cookie//lib/http/cookie.rb#353 def name=(name); end # Returns the value of attribute origin. # - # source://http-cookie//lib/http/cookie.rb#450 + # source://http-cookie//lib/http/cookie.rb#453 def origin; end # See #origin. # - # source://http-cookie//lib/http/cookie.rb#453 + # source://http-cookie//lib/http/cookie.rb#456 def origin=(origin); end # Returns the value of attribute path. # - # source://http-cookie//lib/http/cookie.rb#441 + # source://http-cookie//lib/http/cookie.rb#444 def path; end # See #path. # - # source://http-cookie//lib/http/cookie.rb#444 + # source://http-cookie//lib/http/cookie.rb#447 def path=(path); end # The secure flag. (secure-only-flag) @@ -255,7 +256,7 @@ class HTTP::Cookie # A cookie with this flag on should only be sent via a secure # protocol like HTTPS. # - # source://http-cookie//lib/http/cookie.rb#470 + # source://http-cookie//lib/http/cookie.rb#473 def secure; end # The secure flag. (secure-only-flag) @@ -263,7 +264,7 @@ class HTTP::Cookie # A cookie with this flag on should only be sent via a secure # protocol like HTTPS. # - # source://http-cookie//lib/http/cookie.rb#470 + # source://http-cookie//lib/http/cookie.rb#473 def secure=(_arg0); end # The secure flag. (secure-only-flag) @@ -271,21 +272,21 @@ class HTTP::Cookie # A cookie with this flag on should only be sent via a secure # protocol like HTTPS. # - # source://http-cookie//lib/http/cookie.rb#470 + # source://http-cookie//lib/http/cookie.rb#473 def secure?; end # The session flag. (the opposite of persistent-flag) # # A cookie with this flag on should be hidden from a client script. # - # source://http-cookie//lib/http/cookie.rb#482 + # source://http-cookie//lib/http/cookie.rb#485 def session; end # The session flag. (the opposite of persistent-flag) # # A cookie with this flag on should be hidden from a client script. # - # source://http-cookie//lib/http/cookie.rb#482 + # source://http-cookie//lib/http/cookie.rb#485 def session?; end # Returns a string for use in the Set-Cookie header. If necessary @@ -293,18 +294,18 @@ class HTTP::Cookie # missing, RuntimeError is raised. It is always the best to set an # origin before calling this method. # - # source://http-cookie//lib/http/cookie.rb#605 + # source://http-cookie//lib/http/cookie.rb#608 def set_cookie_value; end # Returns a string for use in the Cookie header, i.e. `name=value` # or `name="value"`. # - # source://http-cookie//lib/http/cookie.rb#596 + # source://http-cookie//lib/http/cookie.rb#599 def to_s; end # YAML serialization helper for Syck. # - # source://http-cookie//lib/http/cookie.rb#654 + # source://http-cookie//lib/http/cookie.rb#657 def to_yaml_properties; end # Tests if it is OK to send this cookie to a given `uri`. A @@ -312,36 +313,36 @@ class HTTP::Cookie # # @return [Boolean] # - # source://http-cookie//lib/http/cookie.rb#584 + # source://http-cookie//lib/http/cookie.rb#587 def valid_for_uri?(uri); end # Returns the value of attribute value. # - # source://http-cookie//lib/http/cookie.rb#364 + # source://http-cookie//lib/http/cookie.rb#367 def value; end # See #value. # - # source://http-cookie//lib/http/cookie.rb#367 + # source://http-cookie//lib/http/cookie.rb#370 def value=(value); end # YAML deserialization helper for Psych. # - # source://http-cookie//lib/http/cookie.rb#671 + # source://http-cookie//lib/http/cookie.rb#674 def yaml_initialize(tag, map); end class << self # Takes an array of cookies and returns a string for use in the # Cookie header, like "name1=value2; name2=value2". # - # source://http-cookie//lib/http/cookie.rb#331 + # source://http-cookie//lib/http/cookie.rb#334 def cookie_value(cookies); end # Parses a Cookie header value into a hash of name-value string # pairs. The first appearance takes precedence if multiple pairs # with the same name occur. # - # source://http-cookie//lib/http/cookie.rb#338 + # source://http-cookie//lib/http/cookie.rb#341 def cookie_value_to_hash(cookie_value); end # Parses a Set-Cookie header value `set_cookie` assuming that it @@ -378,7 +379,7 @@ class HTTP::Cookie # cookie definitions containing double-quotes just as naturally # expected. # - # source://mechanize/2.9.1/lib/mechanize/cookie.rb#32 + # source://mechanize/2.12.0/lib/mechanize/cookie.rb#32 def parse(arg1, arg2, arg3 = T.unsafe(nil), &block); end # Tests if +target_path+ is under +base_path+ as described in RFC @@ -401,7 +402,7 @@ class HTTP::Cookie # # @return [Boolean] # - # source://http-cookie//lib/http/cookie.rb#229 + # source://http-cookie//lib/http/cookie.rb#232 def path_match?(base_path, target_path); end end end @@ -409,90 +410,124 @@ end # Maximum number of cookies per domain (RFC 6265 6.1 requires 50 at # least) # -# source://http-cookie//lib/http/cookie.rb#19 +# source://http-cookie//lib/http/cookie.rb#22 HTTP::Cookie::MAX_COOKIES_PER_DOMAIN = T.let(T.unsafe(nil), Integer) # Maximum number of cookies total (RFC 6265 6.1 requires 3000 at # least) # -# source://http-cookie//lib/http/cookie.rb#22 +# source://http-cookie//lib/http/cookie.rb#25 HTTP::Cookie::MAX_COOKIES_TOTAL = T.let(T.unsafe(nil), Integer) # Maximum number of bytes per cookie (RFC 6265 6.1 requires 4096 at # least) # -# source://http-cookie//lib/http/cookie.rb#16 +# source://http-cookie//lib/http/cookie.rb#19 HTTP::Cookie::MAX_LENGTH = T.let(T.unsafe(nil), Integer) -# source://http-cookie//lib/http/cookie.rb#27 +# source://http-cookie//lib/http/cookie.rb#30 HTTP::Cookie::PERSISTENT_PROPERTIES = T.let(T.unsafe(nil), Array) -# source://http-cookie//lib/http/cookie/scanner.rb#5 +# source://http-cookie//lib/http/cookie/scanner.rb#6 class HTTP::Cookie::Scanner < ::StringScanner # @return [Scanner] a new instance of Scanner # - # source://http-cookie//lib/http/cookie/scanner.rb#18 + # source://http-cookie//lib/http/cookie/scanner.rb#19 def initialize(string, logger = T.unsafe(nil)); end - # source://http-cookie//lib/http/cookie/scanner.rb#104 + # source://http-cookie//lib/http/cookie/scanner.rb#105 def parse_cookie_date(s); end - # source://http-cookie//lib/http/cookie/scanner.rb#218 + # source://http-cookie//lib/http/cookie/scanner.rb#219 def scan_cookie; end - # source://http-cookie//lib/http/cookie/scanner.rb#34 + # source://http-cookie//lib/http/cookie/scanner.rb#35 def scan_dquoted; end - # source://http-cookie//lib/http/cookie/scanner.rb#47 + # source://http-cookie//lib/http/cookie/scanner.rb#48 def scan_name; end - # source://http-cookie//lib/http/cookie/scanner.rb#73 + # source://http-cookie//lib/http/cookie/scanner.rb#74 def scan_name_value(comma_as_separator = T.unsafe(nil)); end - # source://http-cookie//lib/http/cookie/scanner.rb#156 + # source://http-cookie//lib/http/cookie/scanner.rb#157 def scan_set_cookie; end - # source://http-cookie//lib/http/cookie/scanner.rb#53 + # source://http-cookie//lib/http/cookie/scanner.rb#54 def scan_value(comma_as_separator = T.unsafe(nil)); end - # source://http-cookie//lib/http/cookie/scanner.rb#30 + # source://http-cookie//lib/http/cookie/scanner.rb#31 def skip_wsp; end private - # source://http-cookie//lib/http/cookie/scanner.rb#85 + # source://http-cookie//lib/http/cookie/scanner.rb#86 def tuple_to_time(day_of_month, month, year, time); end class << self - # source://http-cookie//lib/http/cookie/scanner.rb#24 + # source://http-cookie//lib/http/cookie/scanner.rb#25 def quote(s); end end end -# source://http-cookie//lib/http/cookie/scanner.rb#13 +# source://http-cookie//lib/http/cookie/scanner.rb#14 HTTP::Cookie::Scanner::RE_BAD_CHAR = T.let(T.unsafe(nil), Regexp) # A pattern that matches the comma in a (typically date) value. # -# source://http-cookie//lib/http/cookie/scanner.rb#16 +# source://http-cookie//lib/http/cookie/scanner.rb#17 HTTP::Cookie::Scanner::RE_COOKIE_COMMA = T.let(T.unsafe(nil), Regexp) # A pattern that matches a cookie name or attribute name which may # be empty, capturing trailing whitespace. # -# source://http-cookie//lib/http/cookie/scanner.rb#11 +# source://http-cookie//lib/http/cookie/scanner.rb#12 HTTP::Cookie::Scanner::RE_NAME = T.let(T.unsafe(nil), Regexp) # Whitespace. # -# source://http-cookie//lib/http/cookie/scanner.rb#7 +# source://http-cookie//lib/http/cookie/scanner.rb#8 HTTP::Cookie::Scanner::RE_WSP = T.let(T.unsafe(nil), Regexp) # :stopdoc: # -# source://http-cookie//lib/http/cookie.rb#25 +# source://http-cookie//lib/http/cookie.rb#28 HTTP::Cookie::UNIX_EPOCH = T.let(T.unsafe(nil), Time) +# source://http-cookie//lib/http/cookie/uri_parser.rb#1 +module HTTP::Cookie::URIParser + private + + # Escape RFC 3986 "reserved" characters minus valid characters for path + # More specifically, gen-delims minus "/" / "?" / "#" + # + # source://http-cookie//lib/http/cookie/uri_parser.rb#17 + def escape_path(path); end + + # Parse a URI string or object, relaxing the constraints on the path component + # + # source://http-cookie//lib/http/cookie/uri_parser.rb#22 + def parse(uri); end + + class << self + # Escape RFC 3986 "reserved" characters minus valid characters for path + # More specifically, gen-delims minus "/" / "?" / "#" + # + # source://http-cookie//lib/http/cookie/uri_parser.rb#17 + def escape_path(path); end + + # Parse a URI string or object, relaxing the constraints on the path component + # + # source://http-cookie//lib/http/cookie/uri_parser.rb#22 + def parse(uri); end + end +end + +# Regular Expression taken from RFC 3986 Appendix B +# +# source://http-cookie//lib/http/cookie/uri_parser.rb#5 +HTTP::Cookie::URIParser::URIREGEX = T.let(T.unsafe(nil), Regexp) + # source://http-cookie//lib/http/cookie/version.rb#3 HTTP::Cookie::VERSION = T.let(T.unsafe(nil), String) @@ -576,7 +611,7 @@ class HTTP::CookieJar # jar.origin = origin # jar.add(cookie) # acceptance check is performed # - # source://mechanize/2.9.1/lib/mechanize/cookie_jar.rb#12 + # source://mechanize/2.12.0/lib/mechanize/cookie_jar.rb#12 def add(arg1, arg2 = T.unsafe(nil)); end # Removes expired cookies and returns self. If `session` is true, @@ -1000,6 +1035,3 @@ class HTTP::CookieJar::YAMLSaver < ::HTTP::CookieJar::AbstractSaver # source://http-cookie//lib/http/cookie_jar/yaml_saver.rb#78 def load_yaml(yaml); end end - -# source://http/5.1.1/lib/http/version.rb#4 -HTTP::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/http-form_data@2.3.0.rbi b/sorbet/rbi/gems/http-form_data@2.3.0.rbi index c4ec11876..ae74f3c28 100644 --- a/sorbet/rbi/gems/http-form_data@2.3.0.rbi +++ b/sorbet/rbi/gems/http-form_data@2.3.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `http-form_data` gem. # Please instead update this file by running `bin/tapioca gem http-form_data`. + # http gem namespace. # # @see https://github.com/httprb/http @@ -11,7 +12,7 @@ # source://http-form_data//lib/http/form_data/readable.rb#3 module HTTP class << self - # source://http/5.1.1/lib/http/chainable.rb#182 + # source://http/5.2.0/lib/http/chainable.rb#182 def [](headers); end end end @@ -432,6 +433,3 @@ end # # source://http-form_data//lib/http/form_data/version.rb#6 HTTP::FormData::VERSION = T.let(T.unsafe(nil), String) - -# source://http/5.1.1/lib/http/version.rb#4 -HTTP::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/http@5.1.1.rbi b/sorbet/rbi/gems/http@5.2.0.rbi similarity index 94% rename from sorbet/rbi/gems/http@5.1.1.rbi rename to sorbet/rbi/gems/http@5.2.0.rbi index dfe3e5847..e14fb0a52 100644 --- a/sorbet/rbi/gems/http@5.1.1.rbi +++ b/sorbet/rbi/gems/http@5.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `http` gem. # Please instead update this file by running `bin/tapioca gem http`. + # HTTP should be easy # # source://http//lib/http/errors.rb#3 @@ -252,7 +253,7 @@ class HTTP::Client # Perform a single (no follow) HTTP request # - # source://webmock/3.18.1/lib/webmock/http_lib_adapters/http_rb/client.rb#5 + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/client.rb#7 def perform(request, options); end # @return [Boolean] whenever client is persistent @@ -266,7 +267,7 @@ class HTTP::Client # source://http//lib/http/client.rb#28 def request(verb, uri, opts = T.unsafe(nil)); end - # source://webmock/3.18.1/lib/webmock/http_lib_adapters/http_rb/client.rb#11 + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/client.rb#13 def webmock_enabled?; end private @@ -330,28 +331,33 @@ class HTTP::Connection # # @return [void] # - # source://http//lib/http/connection.rb#128 + # source://http//lib/http/connection.rb#131 def close; end # Whether our connection has expired # # @return [Boolean] # - # source://http//lib/http/connection.rb#143 + # source://http//lib/http/connection.rb#150 def expired?; end # @return [Boolean] whenever proxy connect failed # - # source://http//lib/http/connection.rb#61 + # source://http//lib/http/connection.rb#64 def failed_proxy_connect?; end # Callback for when we've reached the end of a response # # @return [void] # - # source://http//lib/http/connection.rb#116 + # source://http//lib/http/connection.rb#119 def finish_response; end + # @return [Boolean] + # + # source://http//lib/http/connection.rb#138 + def finished_request?; end + # source://forwardable/1.3.3/forwardable.rb#231 def headers(*args, **_arg1, &block); end @@ -362,7 +368,7 @@ class HTTP::Connection # # @return [Boolean] # - # source://http//lib/http/connection.rb#137 + # source://http//lib/http/connection.rb#144 def keep_alive?; end # Returned after HTTP CONNECT (via proxy) @@ -374,7 +380,7 @@ class HTTP::Connection # # @return [void] # - # source://http//lib/http/connection.rb#105 + # source://http//lib/http/connection.rb#108 def read_headers!; end # Read a chunk of the body @@ -382,7 +388,7 @@ class HTTP::Connection # @return [String] data chunk # @return [nil] when no more data left # - # source://http//lib/http/connection.rb#90 + # source://http//lib/http/connection.rb#93 def readpartial(size = T.unsafe(nil)); end # Send a request to the server @@ -390,7 +396,7 @@ class HTTP::Connection # @param req [Request] Request to send to the server # @return [nil] # - # source://http//lib/http/connection.rb#69 + # source://http//lib/http/connection.rb#72 def send_request(req); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -402,19 +408,19 @@ class HTTP::Connection # # @return [void] # - # source://http//lib/http/connection.rb#213 + # source://http//lib/http/connection.rb#220 def read_more(size); end # Resets expiration of persistent connection. # # @return [void] # - # source://http//lib/http/connection.rb#190 + # source://http//lib/http/connection.rb#197 def reset_timer; end # Open tunnel through proxy # - # source://http//lib/http/connection.rb#166 + # source://http//lib/http/connection.rb#173 def send_proxy_connect_request(req); end # Store whether the connection should be kept alive. @@ -422,7 +428,7 @@ class HTTP::Connection # # @return [void] # - # source://http//lib/http/connection.rb#197 + # source://http//lib/http/connection.rb#204 def set_keep_alive; end # Sets up SSL context and starts TLS if needed. @@ -431,7 +437,7 @@ class HTTP::Connection # @param options [HTTP::Options] # @return [void] # - # source://http//lib/http/connection.rb#152 + # source://http//lib/http/connection.rb#159 def start_tls(req, options); end end @@ -648,6 +654,11 @@ class HTTP::Features::Instrumentation < ::HTTP::Feature # source://http//lib/http/features/instrumentation.rb#24 def initialize(instrumenter: T.unsafe(nil), namespace: T.unsafe(nil)); end + # Returns the value of attribute error_name. + # + # source://http//lib/http/features/instrumentation.rb#22 + def error_name; end + # Returns the value of attribute instrumenter. # # source://http//lib/http/features/instrumentation.rb#22 @@ -658,22 +669,25 @@ class HTTP::Features::Instrumentation < ::HTTP::Feature # source://http//lib/http/features/instrumentation.rb#22 def name; end - # source://http//lib/http/features/instrumentation.rb#29 + # source://http//lib/http/features/instrumentation.rb#43 + def on_error(request, error); end + + # source://http//lib/http/features/instrumentation.rb#30 def wrap_request(request); end - # source://http//lib/http/features/instrumentation.rb#37 + # source://http//lib/http/features/instrumentation.rb#38 def wrap_response(response); end end -# source://http//lib/http/features/instrumentation.rb#44 +# source://http//lib/http/features/instrumentation.rb#49 class HTTP::Features::Instrumentation::NullInstrumenter - # source://http//lib/http/features/instrumentation.rb#58 + # source://http//lib/http/features/instrumentation.rb#63 def finish(_name, _payload); end - # source://http//lib/http/features/instrumentation.rb#45 + # source://http//lib/http/features/instrumentation.rb#50 def instrument(name, payload = T.unsafe(nil)); end - # source://http//lib/http/features/instrumentation.rb#54 + # source://http//lib/http/features/instrumentation.rb#59 def start(_name, _payload); end end @@ -1650,22 +1664,24 @@ class HTTP::Request # @raise [UnsupportedMethodError] # @return [Request] a new instance of Request # - # source://http//lib/http/request.rb#86 + # source://http//lib/http/request.rb#89 def initialize(opts); end # Returns the value of attribute body. # - # source://http//lib/http/request.rb#77 + # source://http//lib/http/request.rb#80 def body; end # Setup tunnel through proxy for SSL request # - # source://http//lib/http/request.rb#164 + # source://http//lib/http/request.rb#167 def connect_using_proxy(socket); end # Compute HTTP request header for direct or proxy request # - # source://http//lib/http/request.rb#169 + # @raise [RequestError] + # + # source://http//lib/http/request.rb#172 def headline; end # @return [String] @@ -1675,10 +1691,10 @@ class HTTP::Request # Compute and add the Proxy-Authorization header # - # source://http//lib/http/request.rb#154 + # source://http//lib/http/request.rb#157 def include_proxy_authorization_header; end - # source://http//lib/http/request.rb#148 + # source://http//lib/http/request.rb#151 def include_proxy_headers; end # Human-readable representation of base request info. @@ -1689,104 +1705,105 @@ class HTTP::Request # # => # # @return [String] # - # source://http//lib/http/request.rb#215 + # source://http//lib/http/request.rb#220 def inspect; end # Returns the value of attribute proxy. # - # source://http//lib/http/request.rb#77 + # source://http//lib/http/request.rb#80 def proxy; end - # source://http//lib/http/request.rb#158 + # source://http//lib/http/request.rb#161 def proxy_authorization_header; end # Compute HTTP request header SSL proxy connection # - # source://http//lib/http/request.rb#181 + # source://http//lib/http/request.rb#186 def proxy_connect_header; end # Headers to send with proxy connect request # - # source://http//lib/http/request.rb#186 + # source://http//lib/http/request.rb#191 def proxy_connect_headers; end # Returns new Request with updated uri # - # source://http//lib/http/request.rb#103 + # source://http//lib/http/request.rb#106 def redirect(uri, verb = T.unsafe(nil)); end # Scheme is normalized to be a lowercase symbol e.g. :http, :https # - # source://http//lib/http/request.rb#70 + # source://http//lib/http/request.rb#73 def scheme; end # Host for tcp socket # - # source://http//lib/http/request.rb#198 + # source://http//lib/http/request.rb#203 def socket_host; end # Port for tcp socket # - # source://http//lib/http/request.rb#203 + # source://http//lib/http/request.rb#208 def socket_port; end # Stream the request to a socket # - # source://http//lib/http/request.rb#133 + # source://http//lib/http/request.rb#136 def stream(socket); end # "Request URI" as per RFC 2616 # http://www.w3.org/Protocols/rfc2616/rfc2616-sec5.html # - # source://http//lib/http/request.rb#76 + # source://http//lib/http/request.rb#79 def uri; end # Returns the value of attribute uri_normalizer. # - # source://http//lib/http/request.rb#72 + # source://http//lib/http/request.rb#75 def uri_normalizer; end # Is this request using an authenticated proxy? # # @return [Boolean] # - # source://http//lib/http/request.rb#144 + # source://http//lib/http/request.rb#147 def using_authenticated_proxy?; end # Is this request using a proxy? # # @return [Boolean] # - # source://http//lib/http/request.rb#139 + # source://http//lib/http/request.rb#142 def using_proxy?; end # Method is given as a lowercase symbol e.g. :get, :post # - # source://http//lib/http/request.rb#67 + # source://http//lib/http/request.rb#70 def verb; end # Returns the value of attribute version. # - # source://http//lib/http/request.rb#77 + # source://http//lib/http/request.rb#80 def version; end - # source://webmock/3.18.1/lib/webmock/http_lib_adapters/http_rb/request.rb#3 + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/request.rb#5 def webmock_signature; end private + # @raise [RequestError] # @return [String] Default host (with port if needed) header value. # - # source://http//lib/http/request.rb#232 + # source://http//lib/http/request.rb#237 def default_host_header_value; end - # source://http//lib/http/request.rb#227 + # source://http//lib/http/request.rb#232 def port; end - # source://http//lib/http/request.rb#236 + # source://http//lib/http/request.rb#245 def prepare_body(body); end - # source://http//lib/http/request.rb#240 + # source://http//lib/http/request.rb#249 def prepare_headers(headers); end end @@ -1852,12 +1869,12 @@ HTTP::Request::METHODS = T.let(T.unsafe(nil), Array) # Default ports of supported schemes # -# source://http//lib/http/request.rb#59 +# source://http//lib/http/request.rb#62 HTTP::Request::PORTS = T.let(T.unsafe(nil), Hash) # Allowed schemes # -# source://http//lib/http/request.rb#56 +# source://http//lib/http/request.rb#59 HTTP::Request::SCHEMES = T.let(T.unsafe(nil), Array) # Default User-Agent header value @@ -2107,7 +2124,7 @@ class HTTP::Response # source://forwardable/1.3.3/forwardable.rb#231 def to_str(*args, **_arg1, &block); end - # source://webmock/3.18.1/lib/webmock/http_lib_adapters/http_rb/response.rb#3 + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/response.rb#5 def to_webmock; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2131,13 +2148,17 @@ class HTTP::Response # source://http//lib/http/response.rb#180 def init_request(opts); end + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/response.rb#83 + def reset_body_to_allow_it_to_be_streamed!(webmock_response); end + class << self - # source://webmock/3.18.1/lib/webmock/http_lib_adapters/http_rb/response.rb#14 - def from_webmock(request, webmock_response, request_signature = T.unsafe(nil)); end + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/response.rb#58 + def build_http_rb_response_body_from_webmock_response(webmock_response); end - private + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/response.rb#26 + def from_webmock(request, webmock_response, request_signature = T.unsafe(nil)); end - # source://webmock/3.18.1/lib/webmock/http_lib_adapters/http_rb/response.rb#57 + # source://webmock/3.23.1/lib/webmock/http_lib_adapters/http_rb/response.rb#71 def normalize_uri(uri); end end end @@ -2700,7 +2721,7 @@ class HTTP::ResponseError < ::HTTP::Error; end # source://http//lib/http/errors.rb#17 class HTTP::StateError < ::HTTP::ResponseError; end -# source://http//lib/http/timeout/null.rb#7 +# source://http//lib/http/timeout/null.rb#6 module HTTP::Timeout; end # source://http//lib/http/timeout/global.rb#10 @@ -2771,71 +2792,71 @@ class HTTP::Timeout::Global < ::HTTP::Timeout::Null def write_nonblock(data); end end -# source://http//lib/http/timeout/null.rb#8 +# source://http//lib/http/timeout/null.rb#7 class HTTP::Timeout::Null - extend ::Forwardable - # @return [Null] a new instance of Null # - # source://http//lib/http/timeout/null.rb#15 + # source://http//lib/http/timeout/null.rb#10 def initialize(options = T.unsafe(nil)); end # Write to the socket # - # source://http//lib/http/timeout/null.rb#52 + # source://http//lib/http/timeout/null.rb#55 def <<(data); end - # source://forwardable/1.3.3/forwardable.rb#231 - def close(*args, **_arg1, &block); end + # source://http//lib/http/timeout/null.rb#25 + def close; end - # source://forwardable/1.3.3/forwardable.rb#231 - def closed?(*args, **_arg1, &block); end + # @return [Boolean] + # + # source://http//lib/http/timeout/null.rb#29 + def closed?; end # Connects to a socket # - # source://http//lib/http/timeout/null.rb#20 + # source://http//lib/http/timeout/null.rb#15 def connect(socket_class, host, port, nodelay = T.unsafe(nil)); end # Starts a SSL connection on a socket # - # source://http//lib/http/timeout/null.rb#26 + # source://http//lib/http/timeout/null.rb#21 def connect_ssl; end # Returns the value of attribute options. # - # source://http//lib/http/timeout/null.rb#13 + # source://http//lib/http/timeout/null.rb#8 def options; end # Read from the socket # - # source://http//lib/http/timeout/null.rb#45 + # source://http//lib/http/timeout/null.rb#48 def readpartial(size, buffer = T.unsafe(nil)); end # Returns the value of attribute socket. # - # source://http//lib/http/timeout/null.rb#13 + # source://http//lib/http/timeout/null.rb#8 def socket; end # Configures the SSL connection and starts the connection # - # source://http//lib/http/timeout/null.rb#31 + # source://http//lib/http/timeout/null.rb#34 def start_tls(host, ssl_socket_class, ssl_context); end # Write to the socket # - # source://http//lib/http/timeout/null.rb#52 + # source://http//lib/http/timeout/null.rb#55 def write(data); end private # Retry reading # - # source://http//lib/http/timeout/null.rb#60 + # source://http//lib/http/timeout/null.rb#63 def rescue_readable(timeout = T.unsafe(nil)); end # Retry writing # - # source://http//lib/http/timeout/null.rb#68 + # source://http//lib/http/timeout/null.rb#71 def rescue_writable(timeout = T.unsafe(nil)); end end @@ -2894,7 +2915,7 @@ class HTTP::URI # @param options_or_uri [Hash, Addressable::URI] # @return [HTTP::URI] new URI instance # - # source://http//lib/http/uri.rb#88 + # source://http//lib/http/uri.rb#104 def initialize(options_or_uri = T.unsafe(nil)); end # Are these URI objects equal? Normalizes both URIs prior to comparison @@ -2902,7 +2923,7 @@ class HTTP::URI # @param other [Object] URI to compare this one with # @return [TrueClass, FalseClass] are the URIs equivalent (after normalization)? # - # source://http//lib/http/uri.rb#107 + # source://http//lib/http/uri.rb#123 def ==(other); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2913,7 +2934,7 @@ class HTTP::URI # @return [Object] duplicated URI # - # source://http//lib/http/uri.rb#158 + # source://http//lib/http/uri.rb#174 def dup; end # Are these URI objects equal? Does NOT normalizes both URIs prior to comparison @@ -2921,7 +2942,7 @@ class HTTP::URI # @param other [Object] URI to compare this one with # @return [TrueClass, FalseClass] are the URIs equivalent? # - # source://http//lib/http/uri.rb#116 + # source://http//lib/http/uri.rb#132 def eql?(other); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2934,7 +2955,7 @@ class HTTP::URI # # @return [Integer] A hash of the URI # - # source://http//lib/http/uri.rb#123 + # source://http//lib/http/uri.rb#139 def hash; end # Host, either a domain name or IP address. If the host is an IPv6 address, it will be returned @@ -2950,24 +2971,24 @@ class HTTP::URI # @param new_host [String, #to_str] The new host component. # @return [void] # - # source://http//lib/http/uri.rb#131 + # source://http//lib/http/uri.rb#147 def host=(new_host); end # @return [True] if URI is HTTP # @return [False] otherwise # - # source://http//lib/http/uri.rb#147 + # source://http//lib/http/uri.rb#163 def http?; end # @return [True] if URI is HTTPS # @return [False] otherwise # - # source://http//lib/http/uri.rb#153 + # source://http//lib/http/uri.rb#169 def https?; end # @return [String] human-readable representation of URI # - # source://http//lib/http/uri.rb#171 + # source://http//lib/http/uri.rb#187 def inspect; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -3033,7 +3054,7 @@ class HTTP::URI # # @return [Integer] port number # - # source://http//lib/http/uri.rb#141 + # source://http//lib/http/uri.rb#157 def port; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -3067,14 +3088,14 @@ class HTTP::URI # # @return [String] URI serialized as a String # - # source://http//lib/http/uri.rb#165 + # source://http//lib/http/uri.rb#181 def to_s; end # Convert an HTTP::URI to a String # # @return [String] URI serialized as a String # - # source://http//lib/http/uri.rb#165 + # source://http//lib/http/uri.rb#181 def to_str; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -3091,7 +3112,7 @@ class HTTP::URI # false, they will be removed if present. # @return [String] Host with IPv6 address brackets added or removed # - # source://http//lib/http/uri.rb#183 + # source://http//lib/http/uri.rb#199 def process_ipv6_brackets(raw_host, brackets: T.unsafe(nil)); end class << self @@ -3101,7 +3122,7 @@ class HTTP::URI # @param sort [TrueClass, FalseClass] should key/value pairs be sorted first? # @return [String] encoded value # - # source://http//lib/http/uri.rb#70 + # source://http//lib/http/uri.rb#73 def form_encode(form_values, sort = T.unsafe(nil)); end # Parse the given URI string, returning an HTTP::URI object @@ -3109,8 +3130,17 @@ class HTTP::URI # @param uri [HTTP::URI, String, #to_str] to parse # @return [HTTP::URI] new URI instance # - # source://http//lib/http/uri.rb#58 + # source://http//lib/http/uri.rb#61 def parse(uri); end + + # Percent-encode all characters matching a regular expression. + # + # @param string [String] raw string + # @private + # @return [String] encoded value + # + # source://http//lib/http/uri.rb#84 + def percent_encode(string); end end end @@ -3126,8 +3156,13 @@ HTTP::URI::HTTP_SCHEME = T.let(T.unsafe(nil), String) # @private # -# source://http//lib/http/uri.rb#41 +# source://http//lib/http/uri.rb#44 HTTP::URI::NORMALIZER = T.let(T.unsafe(nil), Proc) +# @private +# +# source://http//lib/http/uri.rb#41 +HTTP::URI::PERCENT_ENCODE = T.let(T.unsafe(nil), Regexp) + # source://http//lib/http/version.rb#4 HTTP::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/i18n@1.14.1.rbi b/sorbet/rbi/gems/i18n@1.14.5.rbi similarity index 95% rename from sorbet/rbi/gems/i18n@1.14.1.rbi rename to sorbet/rbi/gems/i18n@1.14.5.rbi index e6c7fbd41..e371e30b4 100644 --- a/sorbet/rbi/gems/i18n@1.14.1.rbi +++ b/sorbet/rbi/gems/i18n@1.14.5.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `i18n` gem. # Please instead update this file by running `bin/tapioca gem i18n`. + # source://i18n//lib/i18n/gettext/po_parser.rb#15 module GetText; end @@ -123,15 +124,15 @@ module I18n::Backend::Base # # @raise [NotImplementedError] # - # source://i18n//lib/i18n/backend/base.rb#94 + # source://i18n//lib/i18n/backend/base.rb#96 def available_locales; end - # source://i18n//lib/i18n/backend/base.rb#102 + # source://i18n//lib/i18n/backend/base.rb#104 def eager_load!; end # @return [Boolean] # - # source://i18n//lib/i18n/backend/base.rb#68 + # source://i18n//lib/i18n/backend/base.rb#70 def exists?(locale, key, options = T.unsafe(nil)); end # Accepts a list of paths to translation files. Loads translations from @@ -147,10 +148,10 @@ module I18n::Backend::Base # # @raise [ArgumentError] # - # source://i18n//lib/i18n/backend/base.rb#75 + # source://i18n//lib/i18n/backend/base.rb#77 def localize(locale, object, format = T.unsafe(nil), options = T.unsafe(nil)); end - # source://i18n//lib/i18n/backend/base.rb#98 + # source://i18n//lib/i18n/backend/base.rb#100 def reload!; end # This method receives a locale, a data hash and options for storing translations. @@ -174,7 +175,7 @@ module I18n::Backend::Base # ann: 'good', john: 'big' # #=> { people: { ann: "Ann is good", john: "John is big" } } # - # source://i18n//lib/i18n/backend/base.rb#207 + # source://i18n//lib/i18n/backend/base.rb#209 def deep_interpolate(locale, data, values = T.unsafe(nil)); end # Evaluates defaults. @@ -182,12 +183,12 @@ module I18n::Backend::Base # first translation that can be resolved. Otherwise it tries to resolve # the translation directly. # - # source://i18n//lib/i18n/backend/base.rb#125 + # source://i18n//lib/i18n/backend/base.rb#127 def default(locale, object, subject, options = T.unsafe(nil)); end # @return [Boolean] # - # source://i18n//lib/i18n/backend/base.rb#108 + # source://i18n//lib/i18n/backend/base.rb#110 def eager_loaded?; end # Interpolates values into a given subject. @@ -198,10 +199,10 @@ module I18n::Backend::Base # # if the given subject is an array then: # each element of the array is recursively interpolated (until it finds a string) - # method interpolates ["yes, %{user}", ["maybe no, %{user}, "no, %{user}"]], :user => "bartuz" - # # => "["yes, bartuz",["maybe no, bartuz", "no, bartuz"]]" + # method interpolates ["yes, %{user}", ["maybe no, %{user}", "no, %{user}"]], :user => "bartuz" + # # => ["yes, bartuz", ["maybe no, bartuz", "no, bartuz"]] # - # source://i18n//lib/i18n/backend/base.rb#191 + # source://i18n//lib/i18n/backend/base.rb#193 def interpolate(locale, subject, values = T.unsafe(nil)); end # Loads a single translations file by delegating to #load_rb or @@ -211,41 +212,41 @@ module I18n::Backend::Base # # @raise [UnknownFileType] # - # source://i18n//lib/i18n/backend/base.rb#230 + # source://i18n//lib/i18n/backend/base.rb#232 def load_file(filename); end # Loads a JSON translations file. The data must have locales as # toplevel keys. # - # source://i18n//lib/i18n/backend/base.rb#266 + # source://i18n//lib/i18n/backend/base.rb#268 def load_json(filename); end # Loads a plain Ruby translations file. eval'ing the file must yield # a Hash containing translation data with locales as toplevel keys. # - # source://i18n//lib/i18n/backend/base.rb#244 + # source://i18n//lib/i18n/backend/base.rb#246 def load_rb(filename); end # Loads a YAML translations file. The data must have locales as # toplevel keys. # - # source://i18n//lib/i18n/backend/base.rb#251 + # source://i18n//lib/i18n/backend/base.rb#253 def load_yaml(filename); end # Loads a YAML translations file. The data must have locales as # toplevel keys. # - # source://i18n//lib/i18n/backend/base.rb#251 + # source://i18n//lib/i18n/backend/base.rb#253 def load_yml(filename); end # The method which actually looks up for the translation in the store. # # @raise [NotImplementedError] # - # source://i18n//lib/i18n/backend/base.rb#113 + # source://i18n//lib/i18n/backend/base.rb#115 def lookup(locale, key, scope = T.unsafe(nil), options = T.unsafe(nil)); end - # source://i18n//lib/i18n/backend/base.rb#298 + # source://i18n//lib/i18n/backend/base.rb#300 def pluralization_key(entry, count); end # Picks a translation from a pluralized mnemonic subkey according to English @@ -259,7 +260,7 @@ module I18n::Backend::Base # # @raise [InvalidPluralizationData] # - # source://i18n//lib/i18n/backend/base.rb#172 + # source://i18n//lib/i18n/backend/base.rb#174 def pluralize(locale, entry, count); end # Resolves a translation. @@ -267,7 +268,7 @@ module I18n::Backend::Base # given options. If it is a Proc then it will be evaluated. All other # subjects will be returned directly. # - # source://i18n//lib/i18n/backend/base.rb#147 + # source://i18n//lib/i18n/backend/base.rb#149 def resolve(locale, object, subject, options = T.unsafe(nil)); end # Resolves a translation. @@ -275,15 +276,15 @@ module I18n::Backend::Base # given options. If it is a Proc then it will be evaluated. All other # subjects will be returned directly. # - # source://i18n//lib/i18n/backend/base.rb#147 + # source://i18n//lib/i18n/backend/base.rb#149 def resolve_entry(locale, object, subject, options = T.unsafe(nil)); end # @return [Boolean] # - # source://i18n//lib/i18n/backend/base.rb#117 + # source://i18n//lib/i18n/backend/base.rb#119 def subtrees?; end - # source://i18n//lib/i18n/backend/base.rb#279 + # source://i18n//lib/i18n/backend/base.rb#281 def translate_localization_format(locale, object, format, options); end end @@ -603,15 +604,15 @@ end # source://i18n//lib/i18n/backend/interpolation_compiler.rb#20 module I18n::Backend::InterpolationCompiler - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#99 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#97 def interpolate(locale, string, values); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#109 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#107 def store_translations(locale, data, options = T.unsafe(nil)); end protected - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#115 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#113 def compile_all_strings_in(data); end end @@ -619,58 +620,55 @@ end module I18n::Backend::InterpolationCompiler::Compiler extend ::I18n::Backend::InterpolationCompiler::Compiler - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#27 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#26 def compile_if_an_interpolation(string); end # @return [Boolean] # - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#39 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#38 def interpolated_str?(str); end protected - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#60 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#58 def compile_interpolation_token(key); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#49 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#48 def compiled_interpolation_body(str); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#73 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#71 def direct_key(key); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#93 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#91 def escape_key_sym(key); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#89 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#87 def escape_plain_str(str); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#55 - def handle_interpolation_token(interpolation, matchdata); end + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#54 + def handle_interpolation_token(token); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#69 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#67 def interpolate_key(key); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#64 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#62 def interpolate_or_raise_missing(key); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#81 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#79 def missing_key(key); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#77 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#75 def nil_key(key); end - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#85 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#83 def reserved_key(key); end # tokenize("foo %{bar} baz %%{buz}") # => ["foo ", "%{bar}", " baz ", "%%{buz}"] # - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#45 + # source://i18n//lib/i18n/backend/interpolation_compiler.rb#44 def tokenize(str); end end -# source://i18n//lib/i18n/backend/interpolation_compiler.rb#25 -I18n::Backend::InterpolationCompiler::Compiler::INTERPOLATION_SYNTAX_PATTERN = T.let(T.unsafe(nil), Regexp) - # source://i18n//lib/i18n/backend/interpolation_compiler.rb#24 I18n::Backend::InterpolationCompiler::Compiler::TOKENIZER = T.let(T.unsafe(nil), Regexp) @@ -1205,7 +1203,7 @@ module I18n::Base # @return [Boolean] # - # source://i18n//lib/i18n.rb#355 + # source://i18n//lib/i18n.rb#384 def available_locales_initialized?; end # source://i18n//lib/i18n.rb#69 @@ -1248,7 +1246,7 @@ module I18n::Base # Raises an InvalidLocale exception when the passed locale is not available. # - # source://i18n//lib/i18n.rb#349 + # source://i18n//lib/i18n.rb#378 def enforce_available_locales!(locale); end # source://i18n//lib/i18n.rb#73 @@ -1265,14 +1263,39 @@ module I18n::Base # @raise [Disabled] # @return [Boolean] # - # source://i18n//lib/i18n.rb#235 + # source://i18n//lib/i18n.rb#264 def exists?(key, _locale = T.unsafe(nil), locale: T.unsafe(nil), **options); end + # Returns an array of interpolation keys for the given translation key + # + # *Examples* + # + # Suppose we have the following: + # I18n.t 'example.zero' == 'Zero interpolations' + # I18n.t 'example.one' == 'One interpolation %{foo}' + # I18n.t 'example.two' == 'Two interpolations %{foo} %{bar}' + # I18n.t 'example.three' == ['One %{foo}', 'Two %{bar}', 'Three %{baz}'] + # I18n.t 'example.one', locale: :other == 'One interpolation %{baz}' + # + # Then we can expect the following results: + # I18n.interpolation_keys('example.zero') #=> [] + # I18n.interpolation_keys('example.one') #=> ['foo'] + # I18n.interpolation_keys('example.two') #=> ['foo', 'bar'] + # I18n.interpolation_keys('example.three') #=> ['foo', 'bar', 'baz'] + # I18n.interpolation_keys('one', scope: 'example', locale: :other) #=> ['baz'] + # I18n.interpolation_keys('does-not-exist') #=> [] + # I18n.interpolation_keys('example') #=> [] + # + # @raise [I18n::ArgumentError] + # + # source://i18n//lib/i18n.rb#253 + def interpolation_keys(key, **options); end + # Localizes certain objects, such as dates and numbers to local formatting. # # @raise [Disabled] # - # source://i18n//lib/i18n.rb#304 + # source://i18n//lib/i18n.rb#333 def l(object, locale: T.unsafe(nil), format: T.unsafe(nil), **options); end # source://i18n//lib/i18n.rb#69 @@ -1292,21 +1315,21 @@ module I18n::Base # # @return [Boolean] # - # source://i18n//lib/i18n.rb#344 + # source://i18n//lib/i18n.rb#373 def locale_available?(locale); end # Localizes certain objects, such as dates and numbers to local formatting. # # @raise [Disabled] # - # source://i18n//lib/i18n.rb#304 + # source://i18n//lib/i18n.rb#333 def localize(object, locale: T.unsafe(nil), format: T.unsafe(nil), **options); end # Merges the given locale, key and scope into a single array of keys. # Splits keys that contain dots into multiple keys. Makes sure all # keys are Symbols. # - # source://i18n//lib/i18n.rb#332 + # source://i18n//lib/i18n.rb#361 def normalize_keys(locale, key, scope, separator = T.unsafe(nil)); end # Tells the backend to reload translations. Used in situations like the @@ -1622,12 +1645,12 @@ module I18n::Base # I18n.transliterate("Jürgen", :locale => :en) # => "Jurgen" # I18n.transliterate("Jürgen", :locale => :de) # => "Juergen" # - # source://i18n//lib/i18n.rb#293 + # source://i18n//lib/i18n.rb#322 def transliterate(key, throw: T.unsafe(nil), raise: T.unsafe(nil), locale: T.unsafe(nil), replacement: T.unsafe(nil), **options); end # Executes block with given I18n.locale set. # - # source://i18n//lib/i18n.rb#315 + # source://i18n//lib/i18n.rb#344 def with_locale(tmp_locale = T.unsafe(nil)); end private @@ -1651,13 +1674,16 @@ module I18n::Base # I18n.exception_handler = I18nExceptionHandler.new # an object # I18n.exception_handler.call(exception, locale, key, options) # will be called like this # - # source://i18n//lib/i18n.rb#391 + # source://i18n//lib/i18n.rb#420 def handle_exception(handling, exception, locale, key, options); end - # source://i18n//lib/i18n.rb#409 + # source://i18n//lib/i18n.rb#462 + def interpolation_keys_from_translation(translation); end + + # source://i18n//lib/i18n.rb#438 def normalize_key(key, separator); end - # source://i18n//lib/i18n.rb#361 + # source://i18n//lib/i18n.rb#390 def translate_key(key, throw, raise, locale, backend, options); end end @@ -2011,12 +2037,20 @@ class I18n::Locale::Fallbacks < ::Hash # source://i18n//lib/i18n/locale/fallbacks.rb#55 def defaults=(defaults); end + # @return [Boolean] + # + # source://i18n//lib/i18n/locale/fallbacks.rb#82 + def empty?; end + + # source://i18n//lib/i18n/locale/fallbacks.rb#86 + def inspect; end + # source://i18n//lib/i18n/locale/fallbacks.rb#67 def map(*args, &block); end protected - # source://i18n//lib/i18n/locale/fallbacks.rb#84 + # source://i18n//lib/i18n/locale/fallbacks.rb#92 def compute(tags, include_defaults = T.unsafe(nil), exclude = T.unsafe(nil)); end end diff --git a/sorbet/rbi/gems/image_processing@1.12.2.rbi b/sorbet/rbi/gems/image_processing@1.13.0.rbi similarity index 97% rename from sorbet/rbi/gems/image_processing@1.12.2.rbi rename to sorbet/rbi/gems/image_processing@1.13.0.rbi index b8594555c..0fb0b705b 100644 --- a/sorbet/rbi/gems/image_processing@1.12.2.rbi +++ b/sorbet/rbi/gems/image_processing@1.13.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `image_processing` gem. # Please instead update this file by running `bin/tapioca gem image_processing`. + # source://image_processing//lib/image_processing/chainable.rb#1 module ImageProcessing; end @@ -124,7 +125,7 @@ end class ImageProcessing::MiniMagick::Processor < ::ImageProcessing::Processor # Appends a raw ImageMagick command-line argument to the command. # - # source://image_processing//lib/image_processing/mini_magick.rb#153 + # source://image_processing//lib/image_processing/mini_magick.rb#159 def append(*args); end # Overlays the specified image over the current one. Supports specifying @@ -133,22 +134,22 @@ class ImageProcessing::MiniMagick::Processor < ::ImageProcessing::Processor # # @yield [magick] # - # source://image_processing//lib/image_processing/mini_magick.rb#109 + # source://image_processing//lib/image_processing/mini_magick.rb#115 def composite(overlay = T.unsafe(nil), mask: T.unsafe(nil), mode: T.unsafe(nil), gravity: T.unsafe(nil), offset: T.unsafe(nil), args: T.unsafe(nil), **options, &block); end # Crops the image with the specified crop points. # - # source://image_processing//lib/image_processing/mini_magick.rb#90 + # source://image_processing//lib/image_processing/mini_magick.rb#96 def crop(*args); end # Defines settings from the provided hash. # - # source://image_processing//lib/image_processing/mini_magick.rb#141 + # source://image_processing//lib/image_processing/mini_magick.rb#147 def define(options); end # Specifies resource limits from the provided hash. # - # source://image_processing//lib/image_processing/mini_magick.rb#147 + # source://image_processing//lib/image_processing/mini_magick.rb#153 def limits(options); end # Resizes the image to fit within the specified dimensions and fills @@ -157,6 +158,12 @@ class ImageProcessing::MiniMagick::Processor < ::ImageProcessing::Processor # source://image_processing//lib/image_processing/mini_magick.rb#82 def resize_and_pad(width, height, background: T.unsafe(nil), gravity: T.unsafe(nil), **options); end + # Resizes the image to cover the specified dimensions, without + # cropping the excess. + # + # source://image_processing//lib/image_processing/mini_magick.rb#91 + def resize_to_cover(width, height, **options); end + # Resizes the image to fill the specified dimensions, applying any # necessary cropping. # @@ -177,7 +184,7 @@ class ImageProcessing::MiniMagick::Processor < ::ImageProcessing::Processor # multiple of 90 degrees an optional background color can be specified to # fill in the gaps. # - # source://image_processing//lib/image_processing/mini_magick.rb#101 + # source://image_processing//lib/image_processing/mini_magick.rb#107 def rotate(degrees, background: T.unsafe(nil)); end protected @@ -193,18 +200,18 @@ class ImageProcessing::MiniMagick::Processor < ::ImageProcessing::Processor # # @raise [ArgumentError] # - # source://image_processing//lib/image_processing/mini_magick.rb#162 + # source://image_processing//lib/image_processing/mini_magick.rb#172 def color(value); end # Converts the image on disk in various forms into a path. # - # source://image_processing//lib/image_processing/mini_magick.rb#185 + # source://image_processing//lib/image_processing/mini_magick.rb#195 def convert_to_path(file, name); end # Resizes the image using the specified geometry, and sharpens the # resulting thumbnail. # - # source://image_processing//lib/image_processing/mini_magick.rb#173 + # source://image_processing//lib/image_processing/mini_magick.rb#183 def thumbnail(geometry, sharpen: T.unsafe(nil)); end class << self @@ -232,43 +239,43 @@ ImageProcessing::MiniMagick::Processor::ACCUMULATOR_CLASS = MiniMagick::Tool # source://image_processing//lib/image_processing/mini_magick.rb#23 ImageProcessing::MiniMagick::Processor::SHARPEN_PARAMETERS = T.let(T.unsafe(nil), Hash) -# source://image_processing//lib/image_processing/mini_magick.rb#197 +# source://image_processing//lib/image_processing/mini_magick.rb#207 module ImageProcessing::MiniMagick::Processor::Utils private # Applies settings from the provided (nested) hash. # - # source://image_processing//lib/image_processing/mini_magick.rb#226 + # source://image_processing//lib/image_processing/mini_magick.rb#236 def apply_define(magick, options); end # Applies options from the provided hash. # - # source://image_processing//lib/image_processing/mini_magick.rb#213 + # source://image_processing//lib/image_processing/mini_magick.rb#223 def apply_options(magick, define: T.unsafe(nil), **options); end # When a multi-layer format is being converted into a single-layer # format, ImageMagick will create multiple images, one for each layer. # We want to warn the user that this is probably not what they wanted. # - # source://image_processing//lib/image_processing/mini_magick.rb#203 + # source://image_processing//lib/image_processing/mini_magick.rb#213 def disallow_split_layers!(destination_path); end class << self # Applies settings from the provided (nested) hash. # - # source://image_processing//lib/image_processing/mini_magick.rb#226 + # source://image_processing//lib/image_processing/mini_magick.rb#236 def apply_define(magick, options); end # Applies options from the provided hash. # - # source://image_processing//lib/image_processing/mini_magick.rb#213 + # source://image_processing//lib/image_processing/mini_magick.rb#223 def apply_options(magick, define: T.unsafe(nil), **options); end # When a multi-layer format is being converted into a single-layer # format, ImageMagick will create multiple images, one for each layer. # We want to warn the user that this is probably not what they wanted. # - # source://image_processing//lib/image_processing/mini_magick.rb#203 + # source://image_processing//lib/image_processing/mini_magick.rb#213 def disallow_split_layers!(destination_path); end end end diff --git a/sorbet/rbi/gems/importmap-rails@1.2.1.rbi b/sorbet/rbi/gems/importmap-rails@2.0.1.rbi similarity index 90% rename from sorbet/rbi/gems/importmap-rails@1.2.1.rbi rename to sorbet/rbi/gems/importmap-rails@2.0.1.rbi index d429ad136..182e1431e 100644 --- a/sorbet/rbi/gems/importmap-rails@1.2.1.rbi +++ b/sorbet/rbi/gems/importmap-rails@2.0.1.rbi @@ -4,18 +4,22 @@ # This is an autogenerated file for types exported from the `importmap-rails` gem. # Please instead update this file by running `bin/tapioca gem importmap-rails`. + # source://importmap-rails//lib/importmap-rails.rb#1 module Importmap; end # source://importmap-rails//lib/importmap/engine.rb#7 -class Importmap::Engine < ::Rails::Engine; end +class Importmap::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end module Importmap::ImportmapTagsHelper def javascript_import_module_tag(*module_names); end def javascript_importmap_module_preload_tags(importmap = T.unsafe(nil)); end - def javascript_importmap_shim_nonce_configuration_tag; end - def javascript_importmap_shim_tag(minimized: T.unsafe(nil)); end - def javascript_importmap_tags(entry_point = T.unsafe(nil), shim: T.unsafe(nil), importmap: T.unsafe(nil)); end + def javascript_importmap_tags(entry_point = T.unsafe(nil), importmap: T.unsafe(nil)); end def javascript_inline_importmap_tag(importmap_json = T.unsafe(nil)); end def javascript_module_preload_tag(*paths); end end @@ -223,29 +227,29 @@ class Importmap::Map::MappedFile < ::Struct end end -# source://importmap-rails//lib/importmap/reloader.rb#1 +# source://importmap-rails//lib/importmap/reloader.rb#4 class Importmap::Reloader - # source://importmap-rails//lib/importmap/reloader.rb#2 + # source://importmap-rails//lib/importmap/reloader.rb#5 def execute(*_arg0, **_arg1, &_arg2); end - # source://importmap-rails//lib/importmap/reloader.rb#2 + # source://importmap-rails//lib/importmap/reloader.rb#5 def execute_if_updated(*_arg0, **_arg1, &_arg2); end - # source://importmap-rails//lib/importmap/reloader.rb#4 + # source://importmap-rails//lib/importmap/reloader.rb#7 def reload!; end - # source://importmap-rails//lib/importmap/reloader.rb#2 + # source://importmap-rails//lib/importmap/reloader.rb#5 def updated?(*_arg0, **_arg1, &_arg2); end private - # source://importmap-rails//lib/importmap/reloader.rb#17 + # source://importmap-rails//lib/importmap/reloader.rb#20 def config; end - # source://importmap-rails//lib/importmap/reloader.rb#13 + # source://importmap-rails//lib/importmap/reloader.rb#16 def import_map_paths; end - # source://importmap-rails//lib/importmap/reloader.rb#9 + # source://importmap-rails//lib/importmap/reloader.rb#12 def updater; end end diff --git a/sorbet/rbi/gems/io-console@0.6.0.rbi b/sorbet/rbi/gems/io-console@0.7.2.rbi similarity index 99% rename from sorbet/rbi/gems/io-console@0.6.0.rbi rename to sorbet/rbi/gems/io-console@0.7.2.rbi index ffc1f7aa9..73616ab0e 100644 --- a/sorbet/rbi/gems/io-console@0.6.0.rbi +++ b/sorbet/rbi/gems/io-console@0.7.2.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `io-console` gem. # Please instead update this file by running `bin/tapioca gem io-console`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/irb@1.7.0.rbi b/sorbet/rbi/gems/irb@1.7.0.rbi deleted file mode 100644 index 6fc2c4e70..000000000 --- a/sorbet/rbi/gems/irb@1.7.0.rbi +++ /dev/null @@ -1,2701 +0,0 @@ -# typed: false - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `irb` gem. -# Please instead update this file by running `bin/tapioca gem irb`. - -# source://irb//lib/irb.rb#919 -class Binding - # Opens an IRB session where +binding.irb+ is called which allows for - # interactive debugging. You can call any methods or variables available in - # the current scope, and mutate state if you need to. - # - # - # Given a Ruby file called +potato.rb+ containing the following code: - # - # class Potato - # def initialize - # @cooked = false - # binding.irb - # puts "Cooked potato: #{@cooked}" - # end - # end - # - # Potato.new - # - # Running ruby potato.rb will open an IRB session where - # +binding.irb+ is called, and you will see the following: - # - # $ ruby potato.rb - # - # From: potato.rb @ line 4 : - # - # 1: class Potato - # 2: def initialize - # 3: @cooked = false - # => 4: binding.irb - # 5: puts "Cooked potato: #{@cooked}" - # 6: end - # 7: end - # 8: - # 9: Potato.new - # - # irb(#):001:0> - # - # You can type any valid Ruby code and it will be evaluated in the current - # context. This allows you to debug without having to run your code repeatedly: - # - # irb(#):001:0> @cooked - # => false - # irb(#):002:0> self.class - # => Potato - # irb(#):003:0> caller.first - # => ".../2.5.1/lib/ruby/2.5.0/irb/workspace.rb:85:in `eval'" - # irb(#):004:0> @cooked = true - # => true - # - # You can exit the IRB session with the +exit+ command. Note that exiting will - # resume execution where +binding.irb+ had paused it, as you can see from the - # output printed to standard output in this example: - # - # irb(#):005:0> exit - # Cooked potato: true - # - # - # See IRB@IRB+Usage for more information. - # - # source://irb//lib/irb.rb#977 - def irb(show_code: T.unsafe(nil)); end -end - -# IRB stands for "interactive Ruby" and is a tool to interactively execute Ruby -# expressions read from the standard input. -# -# The +irb+ command from your shell will start the interpreter. -# -# == Usage -# -# Use of irb is easy if you know Ruby. -# -# When executing irb, prompts are displayed as follows. Then, enter the Ruby -# expression. An input is executed when it is syntactically complete. -# -# $ irb -# irb(main):001:0> 1+2 -# #=> 3 -# irb(main):002:0> class Foo -# irb(main):003:1> def foo -# irb(main):004:2> print 1 -# irb(main):005:2> end -# irb(main):006:1> end -# #=> nil -# -# The singleline editor module or multiline editor module can be used with irb. -# Use of multiline editor is default if it's installed. -# -# == Command line options -# -# :include: ./irb/lc/help-message -# -# == Commands -# -# The following commands are available on IRB. -# -# * cwws -# * Show the current workspace. -# * cb, cws, chws -# * Change the current workspace to an object. -# * bindings, workspaces -# * Show workspaces. -# * pushb, pushws -# * Push an object to the workspace stack. -# * popb, popws -# * Pop a workspace from the workspace stack. -# * load -# * Load a Ruby file. -# * require -# * Require a Ruby file. -# * source -# * Loads a given file in the current session. -# * irb -# * Start a child IRB. -# * jobs -# * List of current sessions. -# * fg -# * Switches to the session of the given number. -# * kill -# * Kills the session with the given number. -# * help -# * Enter the mode to look up RI documents. -# * irb_info -# * Show information about IRB. -# * ls -# * Show methods, constants, and variables. -# -g [query] or -G [query] allows you to filter out the output. -# * measure -# * measure enables the mode to measure processing time. measure :off disables it. -# * $, show_source -# * Show the source code of a given method or constant. -# * @, whereami -# * Show the source code around binding.irb again. -# * debug -# * Start the debugger of debug.gem. -# * break, delete, next, step, continue, finish, backtrace, info, catch -# * Start the debugger of debug.gem and run the command on it. -# -# == Configuration -# -# IRB reads a personal initialization file when it's invoked. -# IRB searches a file in the following order and loads the first one found. -# -# * $IRBRC (if $IRBRC is set) -# * $XDG_CONFIG_HOME/irb/irbrc (if $XDG_CONFIG_HOME is set) -# * ~/.irbrc -# * +.config/irb/irbrc+ -# * +.irbrc+ -# * +irb.rc+ -# * +_irbrc+ -# * $irbrc -# -# The following are alternatives to the command line options. To use them type -# as follows in an +irb+ session: -# -# IRB.conf[:IRB_NAME]="irb" -# IRB.conf[:INSPECT_MODE]=nil -# IRB.conf[:IRB_RC] = nil -# IRB.conf[:BACK_TRACE_LIMIT]=16 -# IRB.conf[:USE_LOADER] = false -# IRB.conf[:USE_MULTILINE] = nil -# IRB.conf[:USE_SINGLELINE] = nil -# IRB.conf[:USE_COLORIZE] = true -# IRB.conf[:USE_TRACER] = false -# IRB.conf[:USE_AUTOCOMPLETE] = true -# IRB.conf[:IGNORE_SIGINT] = true -# IRB.conf[:IGNORE_EOF] = false -# IRB.conf[:PROMPT_MODE] = :DEFAULT -# IRB.conf[:PROMPT] = {...} -# -# === Auto indentation -# -# To disable auto-indent mode in irb, add the following to your +.irbrc+: -# -# IRB.conf[:AUTO_INDENT] = false -# -# === Autocompletion -# -# To disable autocompletion for irb, add the following to your +.irbrc+: -# -# IRB.conf[:USE_AUTOCOMPLETE] = false -# -# === History -# -# By default, irb will store the last 1000 commands you used in -# IRB.conf[:HISTORY_FILE] (~/.irb_history by default). -# -# If you want to disable history, add the following to your +.irbrc+: -# -# IRB.conf[:SAVE_HISTORY] = nil -# -# See IRB::Context#save_history= for more information. -# -# The history of _results_ of commands evaluated is not stored by default, -# but can be turned on to be stored with this +.irbrc+ setting: -# -# IRB.conf[:EVAL_HISTORY] = -# -# See IRB::Context#eval_history= and History class. The history of command -# results is not permanently saved in any file. -# -# == Customizing the IRB Prompt -# -# In order to customize the prompt, you can change the following Hash: -# -# IRB.conf[:PROMPT] -# -# This example can be used in your +.irbrc+ -# -# IRB.conf[:PROMPT][:MY_PROMPT] = { # name of prompt mode -# :AUTO_INDENT => false, # disables auto-indent mode -# :PROMPT_I => ">> ", # simple prompt -# :PROMPT_S => nil, # prompt for continuated strings -# :PROMPT_C => nil, # prompt for continuated statement -# :RETURN => " ==>%s\n" # format to return value -# } -# -# IRB.conf[:PROMPT_MODE] = :MY_PROMPT -# -# Or, invoke irb with the above prompt mode by: -# -# irb --prompt my-prompt -# -# Constants +PROMPT_I+, +PROMPT_S+ and +PROMPT_C+ specify the format. In the -# prompt specification, some special strings are available: -# -# %N # command name which is running -# %m # to_s of main object (self) -# %M # inspect of main object (self) -# %l # type of string(", ', /, ]), `]' is inner %w[...] -# %NNi # indent level. NN is digits and means as same as printf("%NNd"). -# # It can be omitted -# %NNn # line number. -# %% # % -# -# For instance, the default prompt mode is defined as follows: -# -# IRB.conf[:PROMPT_MODE][:DEFAULT] = { -# :PROMPT_I => "%N(%m):%03n:%i> ", -# :PROMPT_N => "%N(%m):%03n:%i> ", -# :PROMPT_S => "%N(%m):%03n:%i%l ", -# :PROMPT_C => "%N(%m):%03n:%i* ", -# :RETURN => "%s\n" # used to printf -# } -# -# irb comes with a number of available modes: -# -# # :NULL: -# # :PROMPT_I: -# # :PROMPT_N: -# # :PROMPT_S: -# # :PROMPT_C: -# # :RETURN: | -# # %s -# # :DEFAULT: -# # :PROMPT_I: ! '%N(%m):%03n:%i> ' -# # :PROMPT_N: ! '%N(%m):%03n:%i> ' -# # :PROMPT_S: ! '%N(%m):%03n:%i%l ' -# # :PROMPT_C: ! '%N(%m):%03n:%i* ' -# # :RETURN: | -# # => %s -# # :CLASSIC: -# # :PROMPT_I: ! '%N(%m):%03n:%i> ' -# # :PROMPT_N: ! '%N(%m):%03n:%i> ' -# # :PROMPT_S: ! '%N(%m):%03n:%i%l ' -# # :PROMPT_C: ! '%N(%m):%03n:%i* ' -# # :RETURN: | -# # %s -# # :SIMPLE: -# # :PROMPT_I: ! '>> ' -# # :PROMPT_N: ! '>> ' -# # :PROMPT_S: -# # :PROMPT_C: ! '?> ' -# # :RETURN: | -# # => %s -# # :INF_RUBY: -# # :PROMPT_I: ! '%N(%m):%03n:%i> ' -# # :PROMPT_N: -# # :PROMPT_S: -# # :PROMPT_C: -# # :RETURN: | -# # %s -# # :AUTO_INDENT: true -# # :XMP: -# # :PROMPT_I: -# # :PROMPT_N: -# # :PROMPT_S: -# # :PROMPT_C: -# # :RETURN: |2 -# # ==>%s -# -# == Restrictions -# -# Because irb evaluates input immediately after it is syntactically complete, -# the results may be slightly different than directly using Ruby. -# -# == IRB Sessions -# -# IRB has a special feature, that allows you to manage many sessions at once. -# -# You can create new sessions with Irb.irb, and get a list of current sessions -# with the +jobs+ command in the prompt. -# -# === Commands -# -# JobManager provides commands to handle the current sessions: -# -# jobs # List of current sessions -# fg # Switches to the session of the given number -# kill # Kills the session with the given number -# -# The +exit+ command, or ::irb_exit, will quit the current session and call any -# exit hooks with IRB.irb_at_exit. -# -# A few commands for loading files within the session are also available: -# -# +source+:: -# Loads a given file in the current session and displays the source lines, -# see IrbLoader#source_file -# +irb_load+:: -# Loads the given file similarly to Kernel#load, see IrbLoader#irb_load -# +irb_require+:: -# Loads the given file similarly to Kernel#require -# -# === Configuration -# -# The command line options, or IRB.conf, specify the default behavior of -# Irb.irb. -# -# On the other hand, each conf in IRB@Command+line+options is used to -# individually configure IRB.irb. -# -# If a proc is set for IRB.conf[:IRB_RC], its will be invoked after execution -# of that proc with the context of the current session as its argument. Each -# session can be configured using this mechanism. -# -# === Session variables -# -# There are a few variables in every Irb session that can come in handy: -# -# _:: -# The value command executed, as a local variable -# __:: -# The history of evaluated commands. Available only if -# IRB.conf[:EVAL_HISTORY] is not +nil+ (which is the default). -# See also IRB::Context#eval_history= and IRB::History. -# __[line_no]:: -# Returns the evaluation value at the given line number, +line_no+. -# If +line_no+ is a negative, the return value +line_no+ many lines before -# the most recent return value. -# -# === Example using IRB Sessions -# -# # invoke a new session -# irb(main):001:0> irb -# # list open sessions -# irb.1(main):001:0> jobs -# #0->irb on main (# : stop) -# #1->irb#1 on main (# : running) -# -# # change the active session -# irb.1(main):002:0> fg 0 -# # define class Foo in top-level session -# irb(main):002:0> class Foo;end -# # invoke a new session with the context of Foo -# irb(main):003:0> irb Foo -# # define Foo#foo -# irb.2(Foo):001:0> def foo -# irb.2(Foo):002:1> print 1 -# irb.2(Foo):003:1> end -# -# # change the active session -# irb.2(Foo):004:0> fg 0 -# # list open sessions -# irb(main):004:0> jobs -# #0->irb on main (# : running) -# #1->irb#1 on main (# : stop) -# #2->irb#2 on Foo (# : stop) -# # check if Foo#foo is available -# irb(main):005:0> Foo.instance_methods #=> [:foo, ...] -# -# # change the active session -# irb(main):006:0> fg 2 -# # define Foo#bar in the context of Foo -# irb.2(Foo):005:0> def bar -# irb.2(Foo):006:1> print "bar" -# irb.2(Foo):007:1> end -# irb.2(Foo):010:0> Foo.instance_methods #=> [:bar, :foo, ...] -# -# # change the active session -# irb.2(Foo):011:0> fg 0 -# irb(main):007:0> f = Foo.new #=> # -# # invoke a new session with the context of f (instance of Foo) -# irb(main):008:0> irb f -# # list open sessions -# irb.3():001:0> jobs -# #0->irb on main (# : stop) -# #1->irb#1 on main (# : stop) -# #2->irb#2 on Foo (# : stop) -# #3->irb#3 on # (# : running) -# # evaluate f.foo -# irb.3():002:0> foo #=> 1 => nil -# # evaluate f.bar -# irb.3():003:0> bar #=> bar => nil -# # kill jobs 1, 2, and 3 -# irb.3():004:0> kill 1, 2, 3 -# # list open sessions, should only include main session -# irb(main):009:0> jobs -# #0->irb on main (# : running) -# # quit irb -# irb(main):010:0> exit -# -# source://irb//lib/irb/init.rb#7 -module IRB - class << self - # The current IRB::Context of the session, see IRB.conf - # - # irb - # irb(main):001:0> IRB.CurrentContext.irb_name = "foo" - # foo(main):002:0> IRB.conf[:MAIN_CONTEXT].irb_name #=> "foo" - # - # source://irb//lib/irb.rb#400 - def CurrentContext; end - - # Convenience method to create a new Inspector, using the given +inspect+ - # proc, and optional +init+ proc and passes them to Inspector.new - # - # irb(main):001:0> ins = IRB::Inspector(proc{ |v| "omg! #{v}" }) - # irb(main):001:0> IRB.CurrentContext.inspect_mode = ins # => omg! # - # irb(main):001:0> "what?" #=> omg! what? - # - # source://irb//lib/irb/inspector.rb#17 - def Inspector(inspect, init = T.unsafe(nil)); end - - # Displays current configuration. - # - # Modifying the configuration is achieved by sending a message to IRB.conf. - # - # See IRB@Configuration for more information. - # - # source://irb//lib/irb.rb#383 - def conf; end - - # source://irb//lib/irb/src_encoding.rb#4 - def default_src_encoding; end - - # source://irb//lib/irb/init.rb#23 - def init_config(ap_path); end - - # source://irb//lib/irb/init.rb#212 - def init_error; end - - # Aborts then interrupts irb. - # - # Will raise an Abort exception, or the given +exception+. - # - # source://irb//lib/irb.rb#427 - def irb_abort(irb, exception = T.unsafe(nil)); end - - # Quits irb - # - # source://irb//lib/irb.rb#420 - def irb_exit(irb, ret); end - - # loading modules - # - # source://irb//lib/irb/init.rb#414 - def load_modules; end - - # option analyzing - # - # source://irb//lib/irb/init.rb#217 - def parse_opts(argv: T.unsafe(nil)); end - - # source://irb//lib/irb/init.rb#373 - def rc_file(ext = T.unsafe(nil)); end - - # enumerate possible rc-file base name generators - # - # @yield [proc{|rc| current_dir+"/.irb#{rc}"}] - # - # source://irb//lib/irb/init.rb#392 - def rc_file_generators; end - - # running config - # - # source://irb//lib/irb/init.rb#357 - def run_config; end - - # source://irb//lib/irb/init.rb#167 - def set_measure_callback(type = T.unsafe(nil), arg = T.unsafe(nil), &block); end - - # initialize config - # - # source://irb//lib/irb/init.rb#10 - def setup(ap_path, argv: T.unsafe(nil)); end - - # Initializes IRB and creates a new Irb.irb object at the +TOPLEVEL_BINDING+ - # - # source://irb//lib/irb.rb#405 - def start(ap_path = T.unsafe(nil)); end - - # source://irb//lib/irb/init.rb#203 - def unset_measure_callback(type = T.unsafe(nil)); end - - # Returns the current version of IRB, including release version and last - # updated date. - # - # source://irb//lib/irb.rb#389 - def version; end - - private - - # source://irb//lib/irb/easter-egg.rb#101 - def easter_egg(type = T.unsafe(nil)); end - - # source://irb//lib/irb/init.rb#426 - def set_encoding(extern, intern = T.unsafe(nil), override: T.unsafe(nil)); end - end -end - -# source://irb//lib/irb/color.rb#7 -module IRB::Color - class << self - # source://irb//lib/irb/color.rb#112 - def clear(colorable: T.unsafe(nil)); end - - # @return [Boolean] - # - # source://irb//lib/irb/color.rb#79 - def colorable?; end - - # source://irb//lib/irb/color.rb#117 - def colorize(text, seq, colorable: T.unsafe(nil)); end - - # If `complete` is false (code is incomplete), this does not warn compile_error. - # This option is needed to avoid warning a user when the compile_error is happening - # because the input is not wrong but just incomplete. - # - # source://irb//lib/irb/color.rb#126 - def colorize_code(code, complete: T.unsafe(nil), ignore_error: T.unsafe(nil), colorable: T.unsafe(nil), local_variables: T.unsafe(nil)); end - - # @return [Boolean] - # - # source://irb//lib/irb/color.rb#91 - def inspect_colorable?(obj, seen: T.unsafe(nil)); end - - private - - # source://irb//lib/irb/color.rb#211 - def dispatch_seq(token, expr, str, in_symbol:); end - - # source://irb//lib/irb/color.rb#175 - def scan(code, allow_last_error:); end - - # source://irb//lib/irb/color.rb#167 - def without_circular_ref(obj, seen:, &block); end - end -end - -# A constant of all-bit 1 to match any Ripper's state in #dispatch_seq -# -# source://irb//lib/irb/color.rb#26 -IRB::Color::ALL = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#15 -IRB::Color::BLUE = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#9 -IRB::Color::BOLD = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#8 -IRB::Color::CLEAR = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#17 -IRB::Color::CYAN = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#75 -IRB::Color::ERROR_TOKENS = T.let(T.unsafe(nil), Array) - -# source://irb//lib/irb/color.rb#13 -IRB::Color::GREEN = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#16 -IRB::Color::MAGENTA = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#12 -IRB::Color::RED = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#11 -IRB::Color::REVERSE = T.let(T.unsafe(nil), Integer) - -# A class to manage a state to know whether the current token is for Symbol or not. -# -# source://irb//lib/irb/color.rb#227 -class IRB::Color::SymbolState - # @return [SymbolState] a new instance of SymbolState - # - # source://irb//lib/irb/color.rb#228 - def initialize; end - - # Return true if the token is a part of Symbol. - # - # source://irb//lib/irb/color.rb#234 - def scan_token(token); end -end - -# source://irb//lib/irb/color.rb#19 -IRB::Color::TOKEN_KEYWORDS = T.let(T.unsafe(nil), Hash) - -# source://irb//lib/irb/color.rb#32 -IRB::Color::TOKEN_SEQ_EXPRS = T.let(T.unsafe(nil), Hash) - -# source://irb//lib/irb/color.rb#10 -IRB::Color::UNDERLINE = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/color.rb#14 -IRB::Color::YELLOW = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb/context.rb#15 -class IRB::Context - # Creates a new IRB context. - # - # The optional +input_method+ argument: - # - # +nil+:: uses stdin or Reline or Readline - # +String+:: uses a File - # +other+:: uses this as InputMethod - # - # @return [Context] a new instance of Context - # - # source://irb//lib/irb/context.rb#23 - def initialize(irb, workspace = T.unsafe(nil), input_method = T.unsafe(nil)); end - - # A copy of the default IRB.conf[:AP_NAME] - # - # source://irb//lib/irb/context.rb#175 - def ap_name; end - - # A copy of the default IRB.conf[:AP_NAME] - # - # source://irb//lib/irb/context.rb#175 - def ap_name=(_arg0); end - - # Can be either the default IRB.conf[:AUTO_INDENT], or the - # mode set by #prompt_mode= - # - # To disable auto-indentation in irb: - # - # IRB.conf[:AUTO_INDENT] = false - # - # or - # - # irb_context.auto_indent_mode = false - # - # or - # - # IRB.CurrentContext.auto_indent_mode = false - # - # See IRB@Configuration for more information. - # - # source://irb//lib/irb/context.rb#234 - def auto_indent_mode; end - - # Can be either the default IRB.conf[:AUTO_INDENT], or the - # mode set by #prompt_mode= - # - # To disable auto-indentation in irb: - # - # IRB.conf[:AUTO_INDENT] = false - # - # or - # - # irb_context.auto_indent_mode = false - # - # or - # - # IRB.CurrentContext.auto_indent_mode = false - # - # See IRB@Configuration for more information. - # - # source://irb//lib/irb/context.rb#234 - def auto_indent_mode=(_arg0); end - - # The limit of backtrace lines displayed as top +n+ and tail +n+. - # - # The default value is 16. - # - # Can also be set using the +--back-trace-limit+ command line option. - # - # See IRB@Command+line+options for more command line options. - # - # source://irb//lib/irb/context.rb#327 - def back_trace_limit; end - - # The limit of backtrace lines displayed as top +n+ and tail +n+. - # - # The default value is 16. - # - # Can also be set using the +--back-trace-limit+ command line option. - # - # See IRB@Command+line+options for more command line options. - # - # source://irb//lib/irb/context.rb#327 - def back_trace_limit=(_arg0); end - - # User-defined IRB command aliases - # - # source://irb//lib/irb/context.rb#330 - def command_aliases; end - - # User-defined IRB command aliases - # - # source://irb//lib/irb/context.rb#330 - def command_aliases=(_arg0); end - - # Whether to echo the return value to output or not. - # - # Uses IRB.conf[:ECHO] if available, or defaults to +true+. - # - # puts "hello" - # # hello - # #=> nil - # IRB.CurrentContext.echo = false - # puts "omg" - # # omg - # - # source://irb//lib/irb/context.rb#265 - def echo; end - - # Whether to echo the return value to output or not. - # - # Uses IRB.conf[:ECHO] if available, or defaults to +true+. - # - # puts "hello" - # # hello - # #=> nil - # IRB.CurrentContext.echo = false - # puts "omg" - # # omg - # - # source://irb//lib/irb/context.rb#265 - def echo=(_arg0); end - - # Whether to echo the return value to output or not. - # - # Uses IRB.conf[:ECHO] if available, or defaults to +true+. - # - # puts "hello" - # # hello - # #=> nil - # IRB.CurrentContext.echo = false - # puts "omg" - # # omg - # - # source://irb//lib/irb/context.rb#265 - def echo?; end - - # Whether to echo for assignment expressions. - # - # If set to +false+, the value of assignment will not be shown. - # - # If set to +true+, the value of assignment will be shown. - # - # If set to +:truncate+, the value of assignment will be shown and truncated. - # - # It defaults to +:truncate+. - # - # a = "omg" - # #=> omg - # - # a = "omg" * 10 - # #=> omgomgomgomgomgomgomg... - # - # IRB.CurrentContext.echo_on_assignment = false - # a = "omg" - # - # IRB.CurrentContext.echo_on_assignment = true - # a = "omg" * 10 - # #=> omgomgomgomgomgomgomgomgomgomg - # - # To set the behaviour of showing on assignment in irb: - # - # IRB.conf[:ECHO_ON_ASSIGNMENT] = :truncate or true or false - # - # or - # - # irb_context.echo_on_assignment = :truncate or true or false - # - # or - # - # IRB.CurrentContext.echo_on_assignment = :truncate or true or false - # - # source://irb//lib/irb/context.rb#300 - def echo_on_assignment; end - - # Whether to echo for assignment expressions. - # - # If set to +false+, the value of assignment will not be shown. - # - # If set to +true+, the value of assignment will be shown. - # - # If set to +:truncate+, the value of assignment will be shown and truncated. - # - # It defaults to +:truncate+. - # - # a = "omg" - # #=> omg - # - # a = "omg" * 10 - # #=> omgomgomgomgomgomgomg... - # - # IRB.CurrentContext.echo_on_assignment = false - # a = "omg" - # - # IRB.CurrentContext.echo_on_assignment = true - # a = "omg" * 10 - # #=> omgomgomgomgomgomgomgomgomgomg - # - # To set the behaviour of showing on assignment in irb: - # - # IRB.conf[:ECHO_ON_ASSIGNMENT] = :truncate or true or false - # - # or - # - # irb_context.echo_on_assignment = :truncate or true or false - # - # or - # - # IRB.CurrentContext.echo_on_assignment = :truncate or true or false - # - # source://irb//lib/irb/context.rb#300 - def echo_on_assignment=(_arg0); end - - # Whether to echo for assignment expressions. - # - # If set to +false+, the value of assignment will not be shown. - # - # If set to +true+, the value of assignment will be shown. - # - # If set to +:truncate+, the value of assignment will be shown and truncated. - # - # It defaults to +:truncate+. - # - # a = "omg" - # #=> omg - # - # a = "omg" * 10 - # #=> omgomgomgomgomgomgomg... - # - # IRB.CurrentContext.echo_on_assignment = false - # a = "omg" - # - # IRB.CurrentContext.echo_on_assignment = true - # a = "omg" * 10 - # #=> omgomgomgomgomgomgomgomgomgomg - # - # To set the behaviour of showing on assignment in irb: - # - # IRB.conf[:ECHO_ON_ASSIGNMENT] = :truncate or true or false - # - # or - # - # irb_context.echo_on_assignment = :truncate or true or false - # - # or - # - # IRB.CurrentContext.echo_on_assignment = :truncate or true or false - # - # source://irb//lib/irb/context.rb#300 - def echo_on_assignment?; end - - # Sets command result history limit. Default value is set from - # IRB.conf[:EVAL_HISTORY]. - # - # +no+ is an Integer or +nil+. - # - # Returns +no+ of history items if greater than 0. - # - # If +no+ is 0, the number of history items is unlimited. - # - # If +no+ is +nil+, execution result history isn't used (default). - # - # History values are available via __ variable, see - # IRB::History. - # - # source://irb//lib/irb/extend-command.rb#343 - def eval_history=(*opts, &b); end - - # source://irb//lib/irb/context.rb#476 - def evaluate(line, line_no, exception: T.unsafe(nil)); end - - # Exits the current session, see IRB.irb_exit - # - # source://irb//lib/irb/context.rb#506 - def exit(ret = T.unsafe(nil)); end - - # Specify the installation locations of the ri file to be displayed in the - # document dialog. - # - # source://irb//lib/irb/context.rb#254 - def extra_doc_dirs; end - - # Specify the installation locations of the ri file to be displayed in the - # document dialog. - # - # source://irb//lib/irb/context.rb#254 - def extra_doc_dirs=(_arg0); end - - # Whether #io uses a File for the +input_method+ passed when creating the - # current context, see ::new - # - # @return [Boolean] - # - # source://irb//lib/irb/context.rb#416 - def file_input?; end - - # Whether ^D (+control-d+) will be ignored or not. - # - # If set to +false+, ^D will quit irb. - # - # source://irb//lib/irb/context.rb#251 - def ignore_eof; end - - # Whether ^D (+control-d+) will be ignored or not. - # - # If set to +false+, ^D will quit irb. - # - # source://irb//lib/irb/context.rb#251 - def ignore_eof=(_arg0); end - - # Whether ^D (+control-d+) will be ignored or not. - # - # If set to +false+, ^D will quit irb. - # - # source://irb//lib/irb/context.rb#251 - def ignore_eof?; end - - # Whether ^C (+control-c+) will be ignored or not. - # - # If set to +false+, ^C will quit irb. - # - # If set to +true+, - # - # * during input: cancel input then return to top level. - # * during execute: abandon current execution. - # - # source://irb//lib/irb/context.rb#247 - def ignore_sigint; end - - # Whether ^C (+control-c+) will be ignored or not. - # - # If set to +false+, ^C will quit irb. - # - # If set to +true+, - # - # * during input: cancel input then return to top level. - # * during execute: abandon current execution. - # - # source://irb//lib/irb/context.rb#247 - def ignore_sigint=(_arg0); end - - # Whether ^C (+control-c+) will be ignored or not. - # - # If set to +false+, ^C will quit irb. - # - # If set to +true+, - # - # * during input: cancel input then return to top level. - # * during execute: abandon current execution. - # - # source://irb//lib/irb/context.rb#247 - def ignore_sigint?; end - - # source://irb//lib/irb/context.rb#517 - def inspect; end - - # Whether #inspect_mode is set or not, see #inspect_mode= for more detail. - # - # @return [Boolean] - # - # source://irb//lib/irb/context.rb#410 - def inspect?; end - - # source://irb//lib/irb/context.rb#500 - def inspect_last_value; end - - # A copy of the default IRB.conf[:INSPECT_MODE] - # - # source://irb//lib/irb/context.rb#200 - def inspect_mode; end - - # Specifies the inspect mode with +opt+: - # - # +true+:: display +inspect+ - # +false+:: display +to_s+ - # +nil+:: inspect mode in non-math mode, - # non-inspect mode in math mode - # - # See IRB::Inspector for more information. - # - # Can also be set using the +--inspect+ and +--noinspect+ command line - # options. - # - # See IRB@Command+line+options for more command line options. - # - # source://irb//lib/irb/context.rb#433 - def inspect_mode=(opt); end - - # The current input method. - # - # Can be either StdioInputMethod, ReadlineInputMethod, - # RelineInputMethod, FileInputMethod or other specified when the - # context is created. See ::new for more # information on +input_method+. - # - # source://irb//lib/irb/context.rb#170 - def io; end - - # The current input method. - # - # Can be either StdioInputMethod, ReadlineInputMethod, - # RelineInputMethod, FileInputMethod or other specified when the - # context is created. See ::new for more # information on +input_method+. - # - # source://irb//lib/irb/context.rb#170 - def io=(_arg0); end - - # Current irb session. - # - # source://irb//lib/irb/context.rb#173 - def irb; end - - # Current irb session. - # - # source://irb//lib/irb/context.rb#173 - def irb=(_arg0); end - - # Can be either name from IRB.conf[:IRB_NAME], or the number of - # the current job set by JobManager, such as irb#2 - # - # source://irb//lib/irb/context.rb#182 - def irb_name; end - - # Can be either name from IRB.conf[:IRB_NAME], or the number of - # the current job set by JobManager, such as irb#2 - # - # source://irb//lib/irb/context.rb#182 - def irb_name=(_arg0); end - - # Can be either the #irb_name surrounded by parenthesis, or the - # +input_method+ passed to Context.new - # - # source://irb//lib/irb/context.rb#185 - def irb_path; end - - # Can be either the #irb_name surrounded by parenthesis, or the - # +input_method+ passed to Context.new - # - # source://irb//lib/irb/context.rb#185 - def irb_path=(_arg0); end - - # The return value of the last statement evaluated. - # - # source://irb//lib/irb/context.rb#381 - def last_value; end - - # A copy of the default IRB.conf[:LOAD_MODULES] - # - # source://irb//lib/irb/context.rb#179 - def load_modules; end - - # A copy of the default IRB.conf[:LOAD_MODULES] - # - # source://irb//lib/irb/context.rb#179 - def load_modules=(_arg0); end - - # source://irb//lib/irb/context.rb#539 - def local_variables; end - - # The top-level workspace, see WorkSpace#main - # - # source://irb//lib/irb/context.rb#155 - def main; end - - # Whether a newline is put before multiline output. - # - # Uses IRB.conf[:NEWLINE_BEFORE_MULTILINE_OUTPUT] if available, - # or defaults to +true+. - # - # "abc\ndef" - # #=> - # abc - # def - # IRB.CurrentContext.newline_before_multiline_output = false - # "abc\ndef" - # #=> abc - # def - # - # source://irb//lib/irb/context.rb#314 - def newline_before_multiline_output; end - - # Whether a newline is put before multiline output. - # - # Uses IRB.conf[:NEWLINE_BEFORE_MULTILINE_OUTPUT] if available, - # or defaults to +true+. - # - # "abc\ndef" - # #=> - # abc - # def - # IRB.CurrentContext.newline_before_multiline_output = false - # "abc\ndef" - # #=> abc - # def - # - # source://irb//lib/irb/context.rb#314 - def newline_before_multiline_output=(_arg0); end - - # Whether a newline is put before multiline output. - # - # Uses IRB.conf[:NEWLINE_BEFORE_MULTILINE_OUTPUT] if available, - # or defaults to +true+. - # - # "abc\ndef" - # #=> - # abc - # def - # IRB.CurrentContext.newline_before_multiline_output = false - # "abc\ndef" - # #=> abc - # def - # - # source://irb//lib/irb/context.rb#314 - def newline_before_multiline_output?; end - - # IRB prompt for continuated statement. (e.g. immediately after an +if+) - # - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#215 - def prompt_c; end - - # IRB prompt for continuated statement. (e.g. immediately after an +if+) - # - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#215 - def prompt_c=(_arg0); end - - # Standard IRB prompt. - # - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#207 - def prompt_i; end - - # Standard IRB prompt. - # - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#207 - def prompt_i=(_arg0); end - - # A copy of the default IRB.conf[:PROMPT_MODE] - # - # source://irb//lib/irb/context.rb#203 - def prompt_mode; end - - # Sets the +mode+ of the prompt in this context. - # - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#393 - def prompt_mode=(mode); end - - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#217 - def prompt_n; end - - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#217 - def prompt_n=(_arg0); end - - # IRB prompt for continuated strings. - # - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#211 - def prompt_s; end - - # IRB prompt for continuated strings. - # - # See IRB@Customizing+the+IRB+Prompt for more information. - # - # source://irb//lib/irb/context.rb#211 - def prompt_s=(_arg0); end - - # Whether #verbose? is +true+, and +input_method+ is either - # StdioInputMethod or RelineInputMethod or ReadlineInputMethod, see #io - # for more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/context.rb#374 - def prompting?; end - - # A copy of the default IRB.conf[:RC] - # - # source://irb//lib/irb/context.rb#177 - def rc; end - - # A copy of the default IRB.conf[:RC] - # - # source://irb//lib/irb/context.rb#177 - def rc=(_arg0); end - - # A copy of the default IRB.conf[:RC] - # Alias for #rc - # - # source://irb//lib/irb/context.rb#177 - def rc?; end - - # The format of the return statement, set by #prompt_mode= using the - # +:RETURN+ of the +mode+ passed to set the current #prompt_mode. - # - # source://irb//lib/irb/context.rb#237 - def return_format; end - - # The format of the return statement, set by #prompt_mode= using the - # +:RETURN+ of the +mode+ passed to set the current #prompt_mode. - # - # source://irb//lib/irb/context.rb#237 - def return_format=(_arg0); end - - # Sets IRB.conf[:SAVE_HISTORY] to the given +val+ and calls - # #init_save_history with this context. - # - # Will store the number of +val+ entries of history in the #history_file - # - # Add the following to your +.irbrc+ to change the number of history - # entries stored to 1000: - # - # IRB.conf[:SAVE_HISTORY] = 1000 - # - # source://irb//lib/irb/extend-command.rb#343 - def save_history=(*opts, &b); end - - # Sets the return value from the last statement evaluated in this context - # to #last_value. - # - # source://irb//lib/irb/context.rb#385 - def set_last_value(value); end - - # Return true if it's aliased from the argument and it's not an identifier. - # - # @return [Boolean] - # - # source://irb//lib/irb/context.rb#544 - def symbol_alias?(command); end - - # The current thread in this context. - # - # source://irb//lib/irb/context.rb#164 - def thread; end - - # source://irb//lib/irb/context.rb#517 - def to_s; end - - # Return true if the command supports transforming args - # - # @return [Boolean] - # - # source://irb//lib/irb/context.rb#550 - def transform_args?(command); end - - # Whether colorization is enabled or not. - # - # A copy of the default IRB.conf[:USE_AUTOCOMPLETE] - # - # source://irb//lib/irb/context.rb#198 - def use_autocomplete; end - - # Whether colorization is enabled or not. - # - # A copy of the default IRB.conf[:USE_AUTOCOMPLETE] - # Alias for #use_autocomplete - # - # source://irb//lib/irb/context.rb#198 - def use_autocomplete?; end - - # Sets IRB.conf[:USE_LOADER] - # - # See #use_loader for more information. - # - # source://irb//lib/irb/extend-command.rb#343 - def use_loader=(*opts, &b); end - - # Whether multiline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_MULTILINE] - # - # source://irb//lib/irb/context.rb#190 - def use_multiline; end - - # Whether multiline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_MULTILINE] - # Alias for #use_multiline - # - # source://irb//lib/irb/context.rb#190 - def use_multiline?; end - - # Whether singleline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_SINGLELINE] - # backward compatibility - # - # source://irb//lib/irb/context.rb#194 - def use_readline; end - - # Whether singleline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_SINGLELINE] - # backward compatibility - # - # source://irb//lib/irb/context.rb#194 - def use_readline?; end - - # Whether multiline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_MULTILINE] - # backward compatibility - # - # source://irb//lib/irb/context.rb#190 - def use_reline; end - - # Whether multiline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_MULTILINE] - # backward compatibility - # - # source://irb//lib/irb/context.rb#190 - def use_reline?; end - - # Whether singleline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_SINGLELINE] - # - # source://irb//lib/irb/context.rb#194 - def use_singleline; end - - # Whether singleline editor mode is enabled or not. - # - # A copy of the default IRB.conf[:USE_SINGLELINE] - # Alias for #use_singleline - # - # source://irb//lib/irb/context.rb#194 - def use_singleline?; end - - # Sets whether or not to use the Tracer library when evaluating statements - # in this context. - # - # See +lib/tracer.rb+ for more information. - # - # source://irb//lib/irb/extend-command.rb#343 - def use_tracer=(*opts, &b); end - - # Whether verbose messages are displayed or not. - # - # A copy of the default IRB.conf[:VERBOSE] - # - # source://irb//lib/irb/context.rb#318 - def verbose; end - - # Whether verbose messages are displayed or not. - # - # A copy of the default IRB.conf[:VERBOSE] - # - # source://irb//lib/irb/context.rb#318 - def verbose=(_arg0); end - - # Returns whether messages are displayed or not. - # - # @return [Boolean] - # - # source://irb//lib/irb/context.rb#355 - def verbose?; end - - # WorkSpace in the current context. - # - # source://irb//lib/irb/context.rb#162 - def workspace; end - - # WorkSpace in the current context. - # - # source://irb//lib/irb/context.rb#162 - def workspace=(_arg0); end - - # The toplevel workspace, see #home_workspace - # - # source://irb//lib/irb/context.rb#160 - def workspace_home; end -end - -# source://irb//lib/irb/context.rb#514 -IRB::Context::IDNAME_IVARS = T.let(T.unsafe(nil), Array) - -# source://irb//lib/irb/context.rb#512 -IRB::Context::NOPRINTING_IVARS = T.let(T.unsafe(nil), Array) - -# source://irb//lib/irb/context.rb#513 -IRB::Context::NO_INSPECTING_IVARS = T.let(T.unsafe(nil), Array) - -# Extends methods for the Context module -# -# source://irb//lib/irb/extend-command.rb#315 -module IRB::ContextExtender - class << self - # Evaluate the given +command+ from the given +load_file+ on the Context - # module. - # - # Will also define any given +aliases+ for the method. - # - # source://irb//lib/irb/extend-command.rb#341 - def def_extend_command(cmd_name, load_file, *aliases); end - - # Installs the default context extensions as irb commands: - # - # Context#eval_history=:: +irb/ext/history.rb+ - # Context#use_tracer=:: +irb/ext/tracer.rb+ - # Context#use_loader=:: +irb/ext/use-loader.rb+ - # Context#save_history=:: +irb/ext/save-history.rb+ - # - # source://irb//lib/irb/extend-command.rb#331 - def install_extend_commands; end - end -end - -# Installs the default irb extensions command bundle. -# -# source://irb//lib/irb/extend-command.rb#9 -module IRB::ExtendCommandBundle - # Installs alias methods for the default irb commands, see - # ::install_extend_commands. - # - # source://irb//lib/irb/extend-command.rb#276 - def install_alias_method(to, from, override = T.unsafe(nil)); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_backtrace(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_break(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_catch(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_change_workspace(*opts, **kwargs, &b); end - - # Displays current configuration. - # - # Modifying the configuration is achieved by sending a message to IRB.conf. - # - # source://irb//lib/irb/extend-command.rb#31 - def irb_context; end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_continue(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_current_working_workspace(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_debug(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_debug_info(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_delete(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_edit(*opts, **kwargs, &b); end - - # Quits the current irb context - # - # +ret+ is the optional signal or message to send to Context#exit - # - # Same as IRB.CurrentContext.exit. - # - # source://irb//lib/irb/extend-command.rb#24 - def irb_exit(ret = T.unsafe(nil)); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_fg(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_finish(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_help(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_info(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_jobs(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_kill(*opts, **kwargs, &b); end - - # Loads the given file similarly to Kernel#load, see IrbLoader#irb_load - # - # source://irb//lib/irb/extend-command.rb#263 - def irb_load(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_ls(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_measure(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_next(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_pop_workspace(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_push_workspace(*opts, **kwargs, &b); end - - # Loads the given file similarly to Kernel#require - # - # source://irb//lib/irb/extend-command.rb#263 - def irb_require(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_show_cmds(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_show_doc(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_show_source(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_source(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_step(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_whereami(*opts, **kwargs, &b); end - - # source://irb//lib/irb/extend-command.rb#263 - def irb_workspaces(*opts, **kwargs, &b); end - - class << self - # source://irb//lib/irb/extend-command.rb#200 - def all_commands_info; end - - # Evaluate the given +cmd_name+ on the given +cmd_class+ Class. - # - # Will also define any given +aliases+ for the method. - # - # The optional +load_file+ parameter will be required within the method - # definition. - # - # source://irb//lib/irb/extend-command.rb#253 - def def_extend_command(cmd_name, cmd_class, load_file, *aliases); end - - # Installs alias methods for the default irb commands on the given object - # using #install_alias_method. - # - # source://irb//lib/irb/extend-command.rb#302 - def extend_object(obj); end - - # Installs the default irb commands. - # - # source://irb//lib/irb/extend-command.rb#241 - def install_extend_commands; end - - # source://irb//lib/irb/extend-command.rb#296 - def irb_original_method_name(method_name); end - - # Convert a command name to its implementation class if such command exists - # - # source://irb//lib/irb/extend-command.rb#227 - def load_command(command); end - end -end - -# source://irb//lib/irb/extend-command.rb#10 -IRB::ExtendCommandBundle::EXCB = IRB::ExtendCommandBundle - -# Use a File for IO with irb, see InputMethod -# -# source://irb//lib/irb/input-method.rb#119 -class IRB::FileInputMethod < ::IRB::InputMethod - # Creates a new input method object - # - # @return [FileInputMethod] a new instance of FileInputMethod - # - # source://irb//lib/irb/input-method.rb#132 - def initialize(file); end - - # source://irb//lib/irb/input-method.rb#166 - def close; end - - # The external encoding for standard input. - # - # source://irb//lib/irb/input-method.rb#157 - def encoding; end - - # Whether the end of this input method has been reached, returns +true+ if - # there is no more data to read. - # - # See IO#eof? for more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/input-method.rb#144 - def eof?; end - - # The file name of this input method, usually given during initialization. - # - # source://irb//lib/irb/input-method.rb#138 - def file_name; end - - # Reads the next line from this input method. - # - # See IO#gets for more information. - # - # source://irb//lib/irb/input-method.rb#151 - def gets; end - - # For debug message - # - # source://irb//lib/irb/input-method.rb#162 - def inspect; end - - class << self - # source://irb//lib/irb/input-method.rb#121 - def open(file, &block); end - end -end - -# source://irb//lib/irb/init.rb#372 -IRB::IRBRC_EXT = T.let(T.unsafe(nil), String) - -# source://irb//lib/irb/completion.rb#11 -module IRB::InputCompletor - class << self - # source://irb//lib/irb/completion.rb#159 - def retrieve_completion_data(input, bind: T.unsafe(nil), doc_namespace: T.unsafe(nil)); end - - # source://irb//lib/irb/completion.rb#87 - def retrieve_files_to_require_from_load_path; end - - # source://irb//lib/irb/completion.rb#106 - def retrieve_files_to_require_relative_from_current_dir; end - - # source://irb//lib/irb/completion.rb#76 - def retrieve_gem_and_system_load_path; end - - # source://irb//lib/irb/completion.rb#434 - def select_message(receiver, message, candidates, sep = T.unsafe(nil)); end - end -end - -# source://irb//lib/irb/completion.rb#59 -IRB::InputCompletor::BASIC_WORD_BREAK_CHARACTERS = T.let(T.unsafe(nil), String) - -# source://irb//lib/irb/completion.rb#147 -IRB::InputCompletor::CompletionProc = T.let(T.unsafe(nil), Proc) - -# source://irb//lib/irb/completion.rb#112 -IRB::InputCompletor::CompletionRequireProc = T.let(T.unsafe(nil), Proc) - -# source://irb//lib/irb/completion.rb#61 -IRB::InputCompletor::GEM_PATHS = T.let(T.unsafe(nil), Array) - -# Set of available operators in Ruby -# -# source://irb//lib/irb/completion.rb#432 -IRB::InputCompletor::Operators = T.let(T.unsafe(nil), Array) - -# source://irb//lib/irb/completion.rb#397 -IRB::InputCompletor::PerfectMatchedProc = T.let(T.unsafe(nil), Proc) - -# Set of reserved words used by Ruby, you should not use these for -# constants or variables -# -# source://irb//lib/irb/completion.rb#38 -IRB::InputCompletor::ReservedWords = T.let(T.unsafe(nil), Array) - -# source://irb//lib/irb/input-method.rb#14 -class IRB::InputMethod - # Creates a new input method object - # - # @return [InputMethod] a new instance of InputMethod - # - # source://irb//lib/irb/input-method.rb#17 - def initialize(file = T.unsafe(nil)); end - - # The file name of this input method, usually given during initialization. - # - # source://irb//lib/irb/input-method.rb#21 - def file_name; end - - # Reads the next line from this input method. - # - # See IO#gets for more information. - # - # source://irb//lib/irb/input-method.rb#29 - def gets; end - - # For debug message - # - # source://irb//lib/irb/input-method.rb#51 - def inspect; end - - # The irb prompt associated with this input method - # - # source://irb//lib/irb/input-method.rb#24 - def prompt; end - - # The irb prompt associated with this input method - # - # source://irb//lib/irb/input-method.rb#24 - def prompt=(_arg0); end - - # Whether this input method is still readable when there is no more data to - # read. - # - # See IO#eof for more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/input-method.rb#46 - def readable_after_eof?; end - - # source://irb//lib/irb/input-method.rb#34 - def winsize; end -end - -# An irb inspector -# -# In order to create your own custom inspector there are two things you -# should be aware of: -# -# Inspector uses #inspect_value, or +inspect_proc+, for output of return values. -# -# This also allows for an optional #init+, or +init_proc+, which is called -# when the inspector is activated. -# -# Knowing this, you can create a rudimentary inspector as follows: -# -# irb(main):001:0> ins = IRB::Inspector.new(proc{ |v| "omg! #{v}" }) -# irb(main):001:0> IRB.CurrentContext.inspect_mode = ins # => omg! # -# irb(main):001:0> "what?" #=> omg! what? -# -# source://irb//lib/irb/inspector.rb#37 -class IRB::Inspector - # Creates a new inspector object, using the given +inspect_proc+ when - # output return values in irb. - # - # @return [Inspector] a new instance of Inspector - # - # source://irb//lib/irb/inspector.rb#83 - def initialize(inspect_proc, init_proc = T.unsafe(nil)); end - - # Proc to call when the inspector is activated, good for requiring - # dependent libraries. - # - # source://irb//lib/irb/inspector.rb#90 - def init; end - - # Proc to call when the input is evaluated and output in irb. - # - # source://irb//lib/irb/inspector.rb#95 - def inspect_value(v); end - - class << self - # Example - # - # Inspector.def_inspector(key, init_p=nil){|v| v.inspect} - # Inspector.def_inspector([key1,..], init_p=nil){|v| v.inspect} - # Inspector.def_inspector(key, inspector) - # Inspector.def_inspector([key1,...], inspector) - # - # source://irb//lib/irb/inspector.rb#58 - def def_inspector(key, arg = T.unsafe(nil), &block); end - - # Determines the inspector to use where +inspector+ is one of the keys passed - # during inspector definition. - # - # source://irb//lib/irb/inspector.rb#48 - def keys_with_inspector(inspector); end - end -end - -# source://irb//lib/irb/inspector.rb#38 -IRB::Inspector::KERNEL_INSPECT = T.let(T.unsafe(nil), UnboundMethod) - -# source://irb//lib/irb.rb#431 -class IRB::Irb - # Creates a new irb session - # - # @return [Irb] a new instance of Irb - # - # source://irb//lib/irb.rb#466 - def initialize(workspace = T.unsafe(nil), input_method = T.unsafe(nil)); end - - # @return [Boolean] - # - # source://irb//lib/irb.rb#877 - def assignment_expression?(line); end - - # Returns the current context of this irb session - # - # source://irb//lib/irb.rb#503 - def context; end - - # source://irb//lib/irb.rb#607 - def convert_invalid_byte_sequence(str, enc); end - - # A hook point for `debug` command's TracePoint after :IRB_EXIT as well as its clean-up - # - # source://irb//lib/irb.rb#474 - def debug_break; end - - # source://irb//lib/irb.rb#614 - def encode_with_invalid_byte_sequence(str, enc); end - - # Evaluates input for this session. - # - # source://irb//lib/irb.rb#508 - def eval_input; end - - # source://irb//lib/irb.rb#636 - def handle_exception(exc); end - - # Outputs the local variables to this current session, including - # #signal_status and #context, using IRB::Locale. - # - # source://irb//lib/irb.rb#862 - def inspect; end - - # source://irb//lib/irb.rb#824 - def output_value(omit = T.unsafe(nil)); end - - # source://irb//lib/irb.rb#785 - def prompt(prompt, ltype, indent, line_no); end - - # source://irb//lib/irb.rb#484 - def run(conf = T.unsafe(nil)); end - - # The lexer used by this irb session - # - # source://irb//lib/irb.rb#505 - def scanner; end - - # The lexer used by this irb session - # - # source://irb//lib/irb.rb#505 - def scanner=(_arg0); end - - # Handler for the signal SIGINT, see Kernel#trap for more information. - # - # source://irb//lib/irb.rb#742 - def signal_handle; end - - # Evaluates the given block using the given +status+. - # - # source://irb//lib/irb.rb#764 - def signal_status(status); end - - # Evaluates the given block using the given +context+ as the Context. - # - # source://irb//lib/irb.rb#732 - def suspend_context(context); end - - # Evaluates the given block using the given +input_method+ as the - # Context#io. - # - # Used by the irb commands +source+ and +irb_load+, see IRB@IRB+Sessions - # for more information. - # - # source://irb//lib/irb.rb#721 - def suspend_input_method(input_method); end - - # Evaluates the given block using the given +path+ as the Context#irb_path - # and +name+ as the Context#irb_name. - # - # Used by the irb command +source+, see IRB@IRB+Sessions for more - # information. - # - # source://irb//lib/irb.rb#691 - def suspend_name(path = T.unsafe(nil), name = T.unsafe(nil)); end - - # Evaluates the given block using the given +workspace+ as the - # Context#workspace. - # - # Used by the irb command +irb_load+, see IRB@IRB+Sessions for more - # information. - # - # source://irb//lib/irb.rb#707 - def suspend_workspace(workspace); end - - # source://irb//lib/irb.rb#776 - def truncate_prompt_main(str); end -end - -# source://irb//lib/irb.rb#432 -IRB::Irb::ASSIGNMENT_NODE_TYPES = T.let(T.unsafe(nil), Array) - -# source://irb//lib/irb.rb#463 -IRB::Irb::CONTROL_CHARACTERS_PATTERN = T.let(T.unsafe(nil), String) - -# Note: instance and index assignment expressions could also be written like: -# "foo.bar=(1)" and "foo.[]=(1, bar)", when expressed that way, the former -# be parsed as :assign and echo will be suppressed, but the latter is -# parsed as a :method_add_arg and the output won't be suppressed -# -# source://irb//lib/irb.rb#461 -IRB::Irb::PROMPT_MAIN_TRUNCATE_LENGTH = T.let(T.unsafe(nil), Integer) - -# source://irb//lib/irb.rb#462 -IRB::Irb::PROMPT_MAIN_TRUNCATE_OMISSION = T.let(T.unsafe(nil), String) - -# source://irb//lib/irb/locale.rb#8 -class IRB::Locale - # @return [Locale] a new instance of Locale - # - # source://irb//lib/irb/locale.rb#25 - def initialize(locale = T.unsafe(nil)); end - - # source://irb//lib/irb/locale.rb#49 - def String(mes); end - - # source://irb//lib/irb/locale.rb#126 - def each_localized_path(dir, file); end - - # @yield [nil] - # - # source://irb//lib/irb/locale.rb#133 - def each_sublocale; end - - # source://irb//lib/irb/locale.rb#45 - def encoding; end - - # source://irb//lib/irb/locale.rb#97 - def find(file, paths = T.unsafe(nil)); end - - # source://irb//lib/irb/locale.rb#58 - def format(*opts); end - - # source://irb//lib/irb/locale.rb#62 - def gets(*rs); end - - # Returns the value of attribute lang. - # - # source://irb//lib/irb/locale.rb#43 - def lang; end - - # source://irb//lib/irb/locale.rb#85 - def load(file); end - - # Returns the value of attribute modifier. - # - # source://irb//lib/irb/locale.rb#43 - def modifier; end - - # source://irb//lib/irb/locale.rb#70 - def print(*opts); end - - # source://irb//lib/irb/locale.rb#75 - def printf(*opts); end - - # source://irb//lib/irb/locale.rb#80 - def puts(*opts); end - - # source://irb//lib/irb/locale.rb#66 - def readline(*rs); end - - # typically, for the parameters and a in paths, it searches - # /
// - # - # @param paths load paths in which IRB find a localized file. - # @param dir directory - # @param file basename to be localized - # - # source://irb//lib/irb/locale.rb#115 - def search_file(lib_paths, dir, file); end - - # Returns the value of attribute territory. - # - # source://irb//lib/irb/locale.rb#43 - def territory; end -end - -# source://irb//lib/irb/locale.rb#18 -IRB::Locale::LEGACY_ENCODING_ALIAS_MAP = T.let(T.unsafe(nil), Hash) - -# source://irb//lib/irb/locale.rb#16 -IRB::Locale::LOCALE_DIR = T.let(T.unsafe(nil), String) - -# source://irb//lib/irb/locale.rb#10 -IRB::Locale::LOCALE_NAME_RE = T.let(T.unsafe(nil), Regexp) - -# An output formatter used internally by the lexer. -# -# source://irb//lib/irb/notifier.rb#11 -module IRB::Notifier - private - - # Define a new Notifier output source, returning a new CompositeNotifier - # with the given +prefix+ and +output_method+. - # - # The optional +prefix+ will be appended to all objects being inspected - # during output, using the given +output_method+ as the output source. If - # no +output_method+ is given, StdioOutputMethod will be used, and all - # expressions will be sent directly to STDOUT without any additional - # formatting. - # - # source://irb//lib/irb/notifier.rb#31 - def def_notifier(prefix = T.unsafe(nil), output_method = T.unsafe(nil)); end - - class << self - # Define a new Notifier output source, returning a new CompositeNotifier - # with the given +prefix+ and +output_method+. - # - # The optional +prefix+ will be appended to all objects being inspected - # during output, using the given +output_method+ as the output source. If - # no +output_method+ is given, StdioOutputMethod will be used, and all - # expressions will be sent directly to STDOUT without any additional - # formatting. - # - # source://irb//lib/irb/notifier.rb#31 - def def_notifier(prefix = T.unsafe(nil), output_method = T.unsafe(nil)); end - end -end - -# An abstract class, or superclass, for CompositeNotifier and -# LeveledNotifier to inherit. It provides several wrapper methods for the -# OutputMethod object used by the Notifier. -# -# source://irb//lib/irb/notifier.rb#39 -class IRB::Notifier::AbstractNotifier - # Creates a new Notifier object - # - # @return [AbstractNotifier] a new instance of AbstractNotifier - # - # source://irb//lib/irb/notifier.rb#41 - def initialize(prefix, base_notifier); end - - # Execute the given block if notifications are enabled. - # - # @yield [@base_notifier] - # - # source://irb//lib/irb/notifier.rb#99 - def exec_if; end - - # A wrapper method used to determine whether notifications are enabled. - # - # Defaults to +true+. - # - # @return [Boolean] - # - # source://irb//lib/irb/notifier.rb#53 - def notify?; end - - # Same as #ppx, except it uses the #prefix given during object - # initialization. - # See OutputMethod#ppx for more detail. - # - # source://irb//lib/irb/notifier.rb#82 - def pp(*objs); end - - # Same as #pp, except it concatenates the given +prefix+ with the #prefix - # given during object initialization. - # - # See OutputMethod#ppx for more detail. - # - # source://irb//lib/irb/notifier.rb#92 - def ppx(prefix, *objs); end - - # The +prefix+ for this Notifier, which is appended to all objects being - # inspected during output. - # - # source://irb//lib/irb/notifier.rb#48 - def prefix; end - - # See OutputMethod#print for more detail. - # - # source://irb//lib/irb/notifier.rb#58 - def print(*opts); end - - # See OutputMethod#printf for more detail. - # - # source://irb//lib/irb/notifier.rb#68 - def printf(format, *opts); end - - # See OutputMethod#printn for more detail. - # - # source://irb//lib/irb/notifier.rb#63 - def printn(*opts); end - - # See OutputMethod#puts for more detail. - # - # source://irb//lib/irb/notifier.rb#73 - def puts(*objs); end -end - -# A class that can be used to create a group of notifier objects with the -# intent of representing a leveled notification system for irb. -# -# This class will allow you to generate other notifiers, and assign them -# the appropriate level for output. -# -# The Notifier class provides a class-method Notifier.def_notifier to -# create a new composite notifier. Using the first composite notifier -# object you create, sibling notifiers can be initialized with -# #def_notifier. -# -# source://irb//lib/irb/notifier.rb#114 -class IRB::Notifier::CompositeNotifier < ::IRB::Notifier::AbstractNotifier - # Create a new composite notifier object with the given +prefix+, and - # +base_notifier+ to use for output. - # - # @return [CompositeNotifier] a new instance of CompositeNotifier - # - # source://irb//lib/irb/notifier.rb#117 - def initialize(prefix, base_notifier); end - - # Creates a new LeveledNotifier in the composite #notifiers group. - # - # The given +prefix+ will be assigned to the notifier, and +level+ will - # be used as the index of the #notifiers Array. - # - # This method returns the newly created instance. - # - # source://irb//lib/irb/notifier.rb#133 - def def_notifier(level, prefix = T.unsafe(nil)); end - - # Returns the leveled notifier for this object - # - # source://irb//lib/irb/notifier.rb#140 - def level; end - - # Sets the leveled notifier for this object. - # - # When the given +value+ is an instance of AbstractNotifier, - # #level_notifier is set to the given object. - # - # When an Integer is given, #level_notifier is set to the notifier at the - # index +value+ in the #notifiers Array. - # - # If no notifier exists at the index +value+ in the #notifiers Array, an - # ErrUndefinedNotifier exception is raised. - # - # An ErrUnrecognizedLevel exception is raised if the given +value+ is not - # found in the existing #notifiers Array, or an instance of - # AbstractNotifier - # - # source://irb//lib/irb/notifier.rb#157 - def level=(value); end - - # Returns the leveled notifier for this object - # - # source://irb//lib/irb/notifier.rb#140 - def level_notifier; end - - # Sets the leveled notifier for this object. - # - # When the given +value+ is an instance of AbstractNotifier, - # #level_notifier is set to the given object. - # - # When an Integer is given, #level_notifier is set to the notifier at the - # index +value+ in the #notifiers Array. - # - # If no notifier exists at the index +value+ in the #notifiers Array, an - # ErrUndefinedNotifier exception is raised. - # - # An ErrUnrecognizedLevel exception is raised if the given +value+ is not - # found in the existing #notifiers Array, or an instance of - # AbstractNotifier - # - # source://irb//lib/irb/notifier.rb#157 - def level_notifier=(value); end - - # List of notifiers in the group - # - # source://irb//lib/irb/notifier.rb#125 - def notifiers; end -end - -# source://irb//lib/irb/notifier.rb#12 -class IRB::Notifier::ErrUndefinedNotifier < ::StandardError - # @return [ErrUndefinedNotifier] a new instance of ErrUndefinedNotifier - # - # source://irb//lib/irb/notifier.rb#13 - def initialize(val); end -end - -# source://irb//lib/irb/notifier.rb#17 -class IRB::Notifier::ErrUnrecognizedLevel < ::StandardError - # @return [ErrUnrecognizedLevel] a new instance of ErrUnrecognizedLevel - # - # source://irb//lib/irb/notifier.rb#18 - def initialize(val); end -end - -# A leveled notifier is comparable to the composite group from -# CompositeNotifier#notifiers. -# -# source://irb//lib/irb/notifier.rb#175 -class IRB::Notifier::LeveledNotifier < ::IRB::Notifier::AbstractNotifier - include ::Comparable - - # Create a new leveled notifier with the given +base+, and +prefix+ to - # send to AbstractNotifier.new - # - # The given +level+ is used to compare other leveled notifiers in the - # CompositeNotifier group to determine whether or not to output - # notifications. - # - # @return [LeveledNotifier] a new instance of LeveledNotifier - # - # source://irb//lib/irb/notifier.rb#184 - def initialize(base, level, prefix); end - - # Compares the level of this notifier object with the given +other+ - # notifier. - # - # See the Comparable module for more information. - # - # source://irb//lib/irb/notifier.rb#197 - def <=>(other); end - - # The current level of this notifier object - # - # source://irb//lib/irb/notifier.rb#191 - def level; end - - # Whether to output messages to the output method, depending on the level - # of this notifier object. - # - # @return [Boolean] - # - # source://irb//lib/irb/notifier.rb#203 - def notify?; end -end - -# NoMsgNotifier is a LeveledNotifier that's used as the default notifier -# when creating a new CompositeNotifier. -# -# This notifier is used as the +zero+ index, or level +0+, for -# CompositeNotifier#notifiers, and will not output messages of any sort. -# -# source://irb//lib/irb/notifier.rb#213 -class IRB::Notifier::NoMsgNotifier < ::IRB::Notifier::LeveledNotifier - # Creates a new notifier that should not be used to output messages. - # - # @return [NoMsgNotifier] a new instance of NoMsgNotifier - # - # source://irb//lib/irb/notifier.rb#215 - def initialize; end - - # Ensures notifications are ignored, see AbstractNotifier#notify? for - # more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/notifier.rb#223 - def notify?; end -end - -# An abstract output class for IO in irb. This is mainly used internally by -# IRB::Notifier. You can define your own output method to use with Irb.new, -# or Context.new -# -# source://irb//lib/irb/output-method.rb#11 -class IRB::OutputMethod - # Returns an array of the given +format+ and +opts+ to be used by - # Kernel#sprintf, if there was a successful Regexp match in the given - # +format+ from #printf - # - # % - # [#0- +] - # (\*|\*[1-9][0-9]*\$|[1-9][0-9]*) - # .(\*|\*[1-9][0-9]*\$|[1-9][0-9]*|)? - # #(hh|h|l|ll|L|q|j|z|t) - # [diouxXeEfgGcsb%] - # - # source://irb//lib/irb/output-method.rb#48 - def parse_printf_format(format, opts); end - - # Prints the given +objs+ calling Object#inspect on each. - # - # See #puts for more detail. - # - # source://irb//lib/irb/output-method.rb#64 - def pp(*objs); end - - # Prints the given +objs+ calling Object#inspect on each and appending the - # given +prefix+. - # - # See #puts for more detail. - # - # source://irb//lib/irb/output-method.rb#72 - def ppx(prefix, *objs); end - - # Open this method to implement your own output method, raises a - # NotImplementedError if you don't define #print in your own class. - # - # @raise [NotImplementedError] - # - # source://irb//lib/irb/output-method.rb#20 - def print(*opts); end - - # Extends IO#printf to format the given +opts+ for Kernel#sprintf using - # #parse_printf_format - # - # source://irb//lib/irb/output-method.rb#31 - def printf(format, *opts); end - - # Prints the given +opts+, with a newline delimiter. - # - # source://irb//lib/irb/output-method.rb#25 - def printn(*opts); end - - # Calls #print on each element in the given +objs+, followed by a newline - # character. - # - # source://irb//lib/irb/output-method.rb#54 - def puts(*objs); end -end - -# source://irb//lib/irb/output-method.rb#12 -class IRB::OutputMethod::NotImplementedError < ::StandardError - # @return [NotImplementedError] a new instance of NotImplementedError - # - # source://irb//lib/irb/output-method.rb#13 - def initialize(val); end -end - -# source://irb//lib/irb/input-method.rb#172 -class IRB::ReadlineInputMethod < ::IRB::InputMethod - # source://irb//lib/irb/input-method.rb#181 - def initialize; end - - # source://irb//lib/irb/input-method.rb#243 - def encoding; end - - # source://irb//lib/irb/input-method.rb#221 - def eof?; end - - # source://irb//lib/irb/input-method.rb#205 - def gets; end - - # source://irb//lib/irb/input-method.rb#248 - def inspect; end - - # source://irb//lib/irb/input-method.rb#238 - def line(line_no); end - - # source://irb//lib/irb/input-method.rb#229 - def readable_after_eof?; end - - class << self - # source://irb//lib/irb/input-method.rb#173 - def initialize_readline; end - end -end - -# source://irb//lib/irb/input-method.rb#471 -class IRB::ReidlineInputMethod < ::IRB::RelineInputMethod - # @return [ReidlineInputMethod] a new instance of ReidlineInputMethod - # - # source://irb//lib/irb/input-method.rb#472 - def initialize; end -end - -# source://irb//lib/irb/input-method.rb#258 -class IRB::RelineInputMethod < ::IRB::InputMethod - include ::Reline - - # Creates a new input method object using Reline - # - # @return [RelineInputMethod] a new instance of RelineInputMethod - # - # source://irb//lib/irb/input-method.rb#262 - def initialize; end - - # source://irb//lib/irb/input-method.rb#311 - def auto_indent(&block); end - - # source://irb//lib/irb/input-method.rb#303 - def check_termination(&block); end - - # source://irb//lib/irb/input-method.rb#307 - def dynamic_prompt(&block); end - - # The external encoding for standard input. - # - # source://irb//lib/irb/input-method.rb#453 - def encoding; end - - # Whether the end of this input method has been reached, returns +true+ - # if there is no more data to read. - # - # See IO#eof? for more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/input-method.rb#431 - def eof?; end - - # Reads the next line from this input method. - # - # See IO#gets for more information. - # - # source://irb//lib/irb/input-method.rb#413 - def gets; end - - # For debug message - # - # source://irb//lib/irb/input-method.rb#458 - def inspect; end - - # Returns the current line number for #io. - # - # #line counts the number of times #gets is called. - # - # See IO#lineno for more information. - # - # source://irb//lib/irb/input-method.rb#448 - def line(line_no); end - - # Whether this input method is still readable when there is no more data to - # read. - # - # See IO#eof for more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/input-method.rb#439 - def readable_after_eof?; end -end - -# source://irb//lib/irb/input-method.rb#315 -IRB::RelineInputMethod::SHOW_DOC_DIALOG = T.let(T.unsafe(nil), Proc) - -# source://irb//lib/irb/input-method.rb#13 -IRB::STDIN_FILE_NAME = T.let(T.unsafe(nil), String) - -# source://irb//lib/irb/input-method.rb#56 -class IRB::StdioInputMethod < ::IRB::InputMethod - # Creates a new input method object - # - # @return [StdioInputMethod] a new instance of StdioInputMethod - # - # source://irb//lib/irb/input-method.rb#58 - def initialize; end - - # The external encoding for standard input. - # - # source://irb//lib/irb/input-method.rb#108 - def encoding; end - - # Whether the end of this input method has been reached, returns +true+ if - # there is no more data to read. - # - # See IO#eof? for more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/input-method.rb#79 - def eof?; end - - # Reads the next line from this input method. - # - # See IO#gets for more information. - # - # source://irb//lib/irb/input-method.rb#69 - def gets; end - - # For debug message - # - # source://irb//lib/irb/input-method.rb#113 - def inspect; end - - # Returns the current line number for #io. - # - # #line counts the number of times #gets is called. - # - # See IO#lineno for more information. - # - # source://irb//lib/irb/input-method.rb#103 - def line(line_no); end - - # Whether this input method is still readable when there is no more data to - # read. - # - # See IO#eof for more information. - # - # @return [Boolean] - # - # source://irb//lib/irb/input-method.rb#94 - def readable_after_eof?; end -end - -# A standard output printer -# -# source://irb//lib/irb/output-method.rb#79 -class IRB::StdioOutputMethod < ::IRB::OutputMethod - # Prints the given +opts+ to standard output, see IO#print for more - # information. - # - # source://irb//lib/irb/output-method.rb#82 - def print(*opts); end -end - -# source://irb//lib/irb/workspace.rb#9 -IRB::TOPLEVEL_BINDING = T.let(T.unsafe(nil), Binding) - -# source://irb//lib/irb/version.rb#8 -IRB::VERSION = T.let(T.unsafe(nil), String) - -# source://irb//lib/irb/workspace.rb#11 -class IRB::WorkSpace - # Creates a new workspace. - # - # set self to main if specified, otherwise - # inherit main from TOPLEVEL_BINDING. - # - # @return [WorkSpace] a new instance of WorkSpace - # - # source://irb//lib/irb/workspace.rb#16 - def initialize(*main); end - - # The Binding of this workspace - # - # source://irb//lib/irb/workspace.rb#106 - def binding; end - - # source://irb//lib/irb/workspace.rb#140 - def code_around_binding; end - - # Evaluate the given +statements+ within the context of this workspace. - # - # source://irb//lib/irb/workspace.rb#112 - def evaluate(statements, file = T.unsafe(nil), line = T.unsafe(nil)); end - - # error message manipulator - # WARN: Rails patches this method to filter its own backtrace. Be cautious when changing it. - # See: https://github.com/rails/rails/blob/main/railties/lib/rails/commands/console/console_command.rb#L8:~:text=def,filter_backtrace - # - # source://irb//lib/irb/workspace.rb#127 - def filter_backtrace(bt); end - - # source://irb//lib/irb/workspace.rb#120 - def local_variable_get(name); end - - # source://irb//lib/irb/workspace.rb#116 - def local_variable_set(name, value); end - - # The top-level workspace of this context, also available as - # IRB.conf[:__MAIN__] - # - # source://irb//lib/irb/workspace.rb#109 - def main; end -end - -# :stopdoc: -# -# source://irb//lib/irb/ruby-lex.rb#11 -class RubyLex - # @return [RubyLex] a new instance of RubyLex - # - # source://irb//lib/irb/ruby-lex.rb#19 - def initialize(context); end - - # source://irb//lib/irb/ruby-lex.rb#283 - def check_code_block(code, tokens); end - - # source://irb//lib/irb/ruby-lex.rb#210 - def check_code_state(code); end - - # source://irb//lib/irb/ruby-lex.rb#572 - def check_corresponding_token_depth(lines, line_index); end - - # source://irb//lib/irb/ruby-lex.rb#502 - def check_newline_depth_difference; end - - # source://irb//lib/irb/ruby-lex.rb#200 - def check_state(code, tokens); end - - # source://irb//lib/irb/ruby-lex.rb#680 - def check_string_literal(tokens); end - - # source://irb//lib/irb/ruby-lex.rb#759 - def check_termination_in_prev_line(code); end - - # source://irb//lib/irb/ruby-lex.rb#52 - def configure_io(io); end - - # source://irb//lib/irb/ruby-lex.rb#248 - def each_top_level_statement; end - - # source://irb//lib/irb/ruby-lex.rb#179 - def find_prev_spaces(line_index); end - - # @return [Boolean] - # - # source://irb//lib/irb/ruby-lex.rb#425 - def is_method_calling?(tokens, index); end - - # source://irb//lib/irb/ruby-lex.rb#474 - def is_the_in_correspond_to_a_for(tokens, index); end - - # source://irb//lib/irb/ruby-lex.rb#262 - def process_continue(tokens); end - - # source://irb//lib/irb/ruby-lex.rb#731 - def process_literal_type(tokens); end - - # source://irb//lib/irb/ruby-lex.rb#375 - def process_nesting_level(tokens); end - - # source://irb//lib/irb/ruby-lex.rb#221 - def readmultiline; end - - # source://irb//lib/irb/ruby-lex.rb#216 - def save_prompt_to_context_io(ltype, indent, continue, line_num_offset); end - - # io functions - # - # source://irb//lib/irb/ruby-lex.rb#48 - def set_input(&block); end - - # source://irb//lib/irb/ruby-lex.rb#135 - def set_prompt(&block); end - - # @return [Boolean] - # - # source://irb//lib/irb/ruby-lex.rb#42 - def single_line_command?(code); end - - # source://irb//lib/irb/ruby-lex.rb#443 - def take_corresponding_syntax_to_kw_do(tokens, index); end - - private - - # @return [Boolean] - # - # source://irb//lib/irb/ruby-lex.rb#808 - def heredoc_scope?; end - - # @return [Boolean] - # - # source://irb//lib/irb/ruby-lex.rb#813 - def in_keyword_case_scope?; end - - class << self - # source://irb//lib/irb/ruby-lex.rb#25 - def compile_with_errors_suppressed(code, line_no: T.unsafe(nil)); end - - # source://irb//lib/irb/ruby-lex.rb#148 - def generate_local_variables_assign_code(local_variables); end - - # source://irb//lib/irb/ruby-lex.rb#152 - def ripper_lex_without_warning(code, context: T.unsafe(nil)); end - end -end - -# source://irb//lib/irb/ruby-lex.rb#139 -RubyLex::ERROR_TOKENS = T.let(T.unsafe(nil), Array) - -# source://irb//lib/irb/ruby-lex.rb#13 -class RubyLex::TerminateLineInput < ::StandardError - # @return [TerminateLineInput] a new instance of TerminateLineInput - # - # source://irb//lib/irb/ruby-lex.rb#14 - def initialize; end -end diff --git a/sorbet/rbi/gems/jaro_winkler@1.5.6.rbi b/sorbet/rbi/gems/jaro_winkler@1.6.0.rbi similarity index 89% rename from sorbet/rbi/gems/jaro_winkler@1.5.6.rbi rename to sorbet/rbi/gems/jaro_winkler@1.6.0.rbi index 97aee8cff..f538cc3c8 100644 --- a/sorbet/rbi/gems/jaro_winkler@1.5.6.rbi +++ b/sorbet/rbi/gems/jaro_winkler@1.6.0.rbi @@ -4,11 +4,14 @@ # This is an autogenerated file for types exported from the `jaro_winkler` gem. # Please instead update this file by running `bin/tapioca gem jaro_winkler`. + # source://jaro_winkler//lib/jaro_winkler/version.rb#3 module JaroWinkler class << self def distance(*_arg0); end def jaro_distance(*_arg0); end + def jaro_similarity(*_arg0); end + def similarity(*_arg0); end end end diff --git a/sorbet/rbi/gems/jbuilder@2.11.5.rbi b/sorbet/rbi/gems/jbuilder@2.12.0.rbi similarity index 83% rename from sorbet/rbi/gems/jbuilder@2.11.5.rbi rename to sorbet/rbi/gems/jbuilder@2.12.0.rbi index 4c2268b40..4817b71bf 100644 --- a/sorbet/rbi/gems/jbuilder@2.11.5.rbi +++ b/sorbet/rbi/gems/jbuilder@2.12.0.rbi @@ -4,13 +4,14 @@ # This is an autogenerated file for types exported from the `jbuilder` gem. # Please instead update this file by running `bin/tapioca gem jbuilder`. + # source://jbuilder//lib/jbuilder/jbuilder.rb#1 -class Jbuilder < ::ActiveSupport::ProxyObject +class Jbuilder < ::BasicObject # @return [Jbuilder] a new instance of Jbuilder # @yield [_self] # @yieldparam _self [Jbuilder] the object that the method was called on # - # source://jbuilder//lib/jbuilder.rb#15 + # source://jbuilder//lib/jbuilder.rb#18 def initialize(options = T.unsafe(nil)); end # Turns the current element into an array and iterates over the passed collection, adding each iteration as @@ -44,15 +45,15 @@ class Jbuilder < ::ActiveSupport::ProxyObject # # [1,2,3] # - # source://jbuilder//lib/jbuilder.rb#213 + # source://jbuilder//lib/jbuilder.rb#216 def array!(collection = T.unsafe(nil), *attributes, &block); end # Returns the attributes of the current builder. # - # source://jbuilder//lib/jbuilder.rb#268 + # source://jbuilder//lib/jbuilder.rb#271 def attributes!; end - # source://jbuilder//lib/jbuilder.rb#252 + # source://jbuilder//lib/jbuilder.rb#255 def call(object, *attributes, &block); end # Turns the current element into an array and yields a builder to add a hash. @@ -72,7 +73,7 @@ class Jbuilder < ::ActiveSupport::ProxyObject # json.content comment.formatted_content # end # - # source://jbuilder//lib/jbuilder.rb#178 + # source://jbuilder//lib/jbuilder.rb#181 def child!; end # Deeply apply key format to nested hashes and arrays passed to @@ -91,7 +92,7 @@ class Jbuilder < ::ActiveSupport::ProxyObject # # { "settings": { "someValue": "abc" }} # - # source://jbuilder//lib/jbuilder.rb#153 + # source://jbuilder//lib/jbuilder.rb#156 def deep_format_keys!(value = T.unsafe(nil)); end # Extracts the mentioned attributes or hash elements from the passed object and turns them into attributes of the JSON. @@ -112,7 +113,7 @@ class Jbuilder < ::ActiveSupport::ProxyObject # # json.(@person, :name, :age) # - # source://jbuilder//lib/jbuilder.rb#244 + # source://jbuilder//lib/jbuilder.rb#247 def extract!(object, *attributes); end # If you want to skip adding nil values to your JSON hash. This is useful @@ -130,7 +131,7 @@ class Jbuilder < ::ActiveSupport::ProxyObject # # {} # - # source://jbuilder//lib/jbuilder.rb#128 + # source://jbuilder//lib/jbuilder.rb#131 def ignore_nil!(value = T.unsafe(nil)); end # Specifies formatting to be applied to the key. Passing in a name of a function @@ -161,98 +162,98 @@ class Jbuilder < ::ActiveSupport::ProxyObject # # { "_first_name": "David" } # - # source://jbuilder//lib/jbuilder.rb#104 + # source://jbuilder//lib/jbuilder.rb#107 def key_format!(*args); end # Merges hash, array, or Jbuilder instance into current builder. # - # source://jbuilder//lib/jbuilder.rb#273 + # source://jbuilder//lib/jbuilder.rb#276 def merge!(object); end - # source://jbuilder//lib/jbuilder.rb#68 + # source://jbuilder//lib/jbuilder.rb#71 def method_missing(*args, &block); end # Returns the nil JSON. # - # source://jbuilder//lib/jbuilder.rb#261 + # source://jbuilder//lib/jbuilder.rb#264 def nil!; end # Returns the nil JSON. # - # source://jbuilder//lib/jbuilder.rb#261 + # source://jbuilder//lib/jbuilder.rb#264 def null!; end - # source://jbuilder//lib/jbuilder.rb#33 + # source://jbuilder//lib/jbuilder.rb#36 def set!(key, value = T.unsafe(nil), *args, &block); end # Encodes the current builder as JSON. # - # source://jbuilder//lib/jbuilder.rb#279 + # source://jbuilder//lib/jbuilder.rb#282 def target!; end private # @return [Boolean] # - # source://jbuilder//lib/jbuilder.rb#357 + # source://jbuilder//lib/jbuilder.rb#360 def _blank?(value = T.unsafe(nil)); end - # source://jbuilder//lib/jbuilder.rb#285 + # source://jbuilder//lib/jbuilder.rb#288 def _extract_hash_values(object, attributes); end - # source://jbuilder//lib/jbuilder.rb#289 + # source://jbuilder//lib/jbuilder.rb#292 def _extract_method_values(object, attributes); end - # source://jbuilder//lib/jbuilder.rb#318 + # source://jbuilder//lib/jbuilder.rb#321 def _format_keys(hash_or_array); end # @return [Boolean] # - # source://jbuilder//lib/jbuilder.rb#353 + # source://jbuilder//lib/jbuilder.rb#356 def _is_collection?(object); end - # source://jbuilder//lib/jbuilder.rb#314 + # source://jbuilder//lib/jbuilder.rb#317 def _key(key); end - # source://jbuilder//lib/jbuilder.rb#338 + # source://jbuilder//lib/jbuilder.rb#341 def _map_collection(collection); end - # source://jbuilder//lib/jbuilder.rb#293 + # source://jbuilder//lib/jbuilder.rb#296 def _merge_block(key); end - # source://jbuilder//lib/jbuilder.rb#300 + # source://jbuilder//lib/jbuilder.rb#303 def _merge_values(current_value, updates); end # @return [Boolean] # - # source://jbuilder//lib/jbuilder.rb#361 + # source://jbuilder//lib/jbuilder.rb#364 def _object_respond_to?(object, *methods); end - # source://jbuilder//lib/jbuilder.rb#344 + # source://jbuilder//lib/jbuilder.rb#347 def _scope; end - # source://jbuilder//lib/jbuilder.rb#330 + # source://jbuilder//lib/jbuilder.rb#333 def _set_value(key, value); end class << self # Same as instance method deep_format_keys! except sets the default. # - # source://jbuilder//lib/jbuilder.rb#158 + # source://jbuilder//lib/jbuilder.rb#161 def deep_format_keys(value = T.unsafe(nil)); end # Yields a builder and automatically turns the result into a JSON string # - # source://jbuilder//lib/jbuilder.rb#26 + # source://jbuilder//lib/jbuilder.rb#29 def encode(*args, &block); end # Same as instance method ignore_nil! except sets the default. # - # source://jbuilder//lib/jbuilder.rb#133 + # source://jbuilder//lib/jbuilder.rb#136 def ignore_nil(value = T.unsafe(nil)); end # Same as the instance method key_format! except sets the default. # - # source://jbuilder//lib/jbuilder.rb#109 + # source://jbuilder//lib/jbuilder.rb#112 def key_format(*args); end end end @@ -265,7 +266,7 @@ class Jbuilder::ArrayError < ::StandardError end end -# source://jbuilder//lib/jbuilder.rb#30 +# source://jbuilder//lib/jbuilder.rb#33 Jbuilder::BLANK = T.let(T.unsafe(nil), Jbuilder::Blank) # source://jbuilder//lib/jbuilder/blank.rb#2 @@ -305,8 +306,8 @@ end # source://jbuilder//lib/jbuilder/collection_renderer.rb#35 class Jbuilder::CollectionRenderable::ScopedIterator < ::SimpleDelegator - include ::Enumerable include ::ActiveSupport::ToJsonWithActiveSupportEncoder + include ::Enumerable # @return [ScopedIterator] a new instance of ScopedIterator # @@ -342,6 +343,14 @@ class Jbuilder::CollectionRenderer < ::ActionView::CollectionRenderer def collection_with_template(view, template, layout, collection); end end +# source://jbuilder//lib/jbuilder/collection_renderer.rb#110 +class Jbuilder::EnumerableCompat < ::SimpleDelegator + # Rails 6.1 requires this. + # + # source://jbuilder//lib/jbuilder/collection_renderer.rb#112 + def size(*args, &block); end +end + # source://jbuilder//lib/jbuilder/key_formatter.rb#5 class Jbuilder::KeyFormatter # @return [KeyFormatter] a new instance of KeyFormatter @@ -366,7 +375,7 @@ class Jbuilder::MergeError < ::StandardError end end -# source://jbuilder//lib/jbuilder.rb#31 +# source://jbuilder//lib/jbuilder.rb#34 Jbuilder::NON_ENUMERABLES = T.let(T.unsafe(nil), Set) # source://jbuilder//lib/jbuilder/errors.rb#4 @@ -380,22 +389,22 @@ end # source://jbuilder//lib/jbuilder/railtie.rb#5 class Jbuilder::Railtie < ::Rails::Railtie; end -# source://jbuilder//lib/jbuilder/jbuilder_template.rb#270 +# source://jbuilder//lib/jbuilder/jbuilder_template.rb#271 class JbuilderHandler - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#271 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#272 def default_format; end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#271 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#272 def default_format=(val); end class << self - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#274 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#275 def call(template, source = T.unsafe(nil)); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#271 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#272 def default_format; end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#271 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#272 def default_format=(val); end end end @@ -493,44 +502,44 @@ class JbuilderTemplate < ::Jbuilder private - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#183 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#184 def _cache_fragment_for(key, options, &block); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#202 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#203 def _cache_key(key, options); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#215 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#216 def _fragment_name_with_digest(key, options); end # @return [Boolean] # - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#227 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#228 def _is_active_model?(object); end # @return [Boolean] # - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#223 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#224 def _partial_options?(options); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#188 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#189 def _read_fragment_cache(key, options = T.unsafe(nil)); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#265 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#266 def _render_active_model_partial(object); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#244 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#245 def _render_explicit_partial(name_or_options, locals = T.unsafe(nil)); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#178 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#179 def _render_partial(options); end # source://jbuilder//lib/jbuilder/jbuilder_template.rb#139 def _render_partial_with_options(options); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#231 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#232 def _set_inline_partial(name, object, options); end - # source://jbuilder//lib/jbuilder/jbuilder_template.rb#194 + # source://jbuilder//lib/jbuilder/jbuilder_template.rb#195 def _write_fragment_cache(key, options = T.unsafe(nil)); end class << self diff --git a/sorbet/rbi/gems/jmespath@1.6.2.rbi b/sorbet/rbi/gems/jmespath@1.6.2.rbi new file mode 100644 index 000000000..e98ca2506 --- /dev/null +++ b/sorbet/rbi/gems/jmespath@1.6.2.rbi @@ -0,0 +1,1921 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `jmespath` gem. +# Please instead update this file by running `bin/tapioca gem jmespath`. + + +# source://jmespath//lib/jmespath.rb#6 +module JMESPath + class << self + # @api private + # + # source://jmespath//lib/jmespath.rb#35 + def load_json(path); end + + # @param expression [String] A valid + # [JMESPath](https://github.com/boto/jmespath) expression. + # @param data [Hash] + # @return [Mixed, nil] Returns the matched values. Returns `nil` if the + # expression does not resolve inside `data`. + # + # source://jmespath//lib/jmespath.rb#24 + def search(expression, data, runtime_options = T.unsafe(nil)); end + end +end + +# source://jmespath//lib/jmespath/caching_parser.rb#5 +class JMESPath::CachingParser + # @return [CachingParser] a new instance of CachingParser + # + # source://jmespath//lib/jmespath/caching_parser.rb#6 + def initialize(options = T.unsafe(nil)); end + + # source://jmespath//lib/jmespath/caching_parser.rb#12 + def parse(expression); end + + private + + # source://jmespath//lib/jmespath/caching_parser.rb#22 + def cache_expression(expression); end +end + +# source://jmespath//lib/jmespath/errors.rb#4 +module JMESPath::Errors; end + +# source://jmespath//lib/jmespath/errors.rb#5 +class JMESPath::Errors::Error < ::StandardError; end + +# source://jmespath//lib/jmespath/errors.rb#15 +class JMESPath::Errors::InvalidArityError < ::JMESPath::Errors::Error; end + +# source://jmespath//lib/jmespath/errors.rb#11 +class JMESPath::Errors::InvalidTypeError < ::JMESPath::Errors::Error; end + +# source://jmespath//lib/jmespath/errors.rb#13 +class JMESPath::Errors::InvalidValueError < ::JMESPath::Errors::Error; end + +# source://jmespath//lib/jmespath/errors.rb#7 +class JMESPath::Errors::RuntimeError < ::JMESPath::Errors::Error; end + +# source://jmespath//lib/jmespath/errors.rb#9 +class JMESPath::Errors::SyntaxError < ::JMESPath::Errors::Error; end + +# source://jmespath//lib/jmespath/errors.rb#17 +class JMESPath::Errors::UnknownFunctionError < ::JMESPath::Errors::Error; end + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#7 +class JMESPath::Lexer + # @api private + # @param expression [String] + # @return [Array] + # + # source://jmespath//lib/jmespath/lexer.rb#163 + def tokenize(expression); end + + private + + # @api private + # + # source://jmespath//lib/jmespath/lexer.rb#277 + def inside(chars, delim, type); end + + # @api private + # + # source://jmespath//lib/jmespath/lexer.rb#268 + def match_or(chars, current, expected, type, or_type); end + + # @api private + # + # source://jmespath//lib/jmespath/lexer.rb#346 + def parse_json(token, quoted = T.unsafe(nil)); end + + class << self + # Certain versions of Ruby and of the pure_json gem not support loading + # scalar JSON values, such a numbers, booleans, strings, etc. These + # simple values must be first wrapped inside a JSON object before calling + # `JSON.parse`. + # + # # works in most JSON versions, raises in some versions + # JSON.parse("true") + # JSON.parse("123") + # JSON.parse("\"abc\"") + # + # This is an known issue for: + # + # * Ruby 1.9.3 bundled v1.5.5 of json; Ruby 1.9.3 defaults to bundled + # version despite newer versions being available. + # + # * json_pure v2.0.0+ + # + # It is not possible to change the version of JSON loaded in the + # user's application. Adding an explicit dependency on json gem + # causes issues in environments that cannot compile the gem. We previously + # had a direct dependency on `json_pure`, but this broke with the v2 update. + # + # This method allows us to detect how the `JSON.parse` behaves so we know + # if we have to wrap scalar JSON values to parse them or not. + # + # @api private + # @return [Boolean] + # + # source://jmespath//lib/jmespath/lexer.rb#322 + def requires_wrapping?; end + end +end + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#364 +class JMESPath::Lexer::CharacterStream + # @api private + # @return [CharacterStream] a new instance of CharacterStream + # + # source://jmespath//lib/jmespath/lexer.rb#365 + def initialize(chars); end + + # @api private + # + # source://jmespath//lib/jmespath/lexer.rb#370 + def current; end + + # @api private + # + # source://jmespath//lib/jmespath/lexer.rb#374 + def next; end + + # @api private + # + # source://jmespath//lib/jmespath/lexer.rb#379 + def position; end +end + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#146 +JMESPath::Lexer::NUMBERS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#148 +JMESPath::Lexer::SIMPLE_TOKENS = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#47 +JMESPath::Lexer::STATE_AND = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#45 +JMESPath::Lexer::STATE_EQ = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#44 +JMESPath::Lexer::STATE_GT = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#34 +JMESPath::Lexer::STATE_IDENTIFIER = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#40 +JMESPath::Lexer::STATE_JSON_LITERAL = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#41 +JMESPath::Lexer::STATE_LBRACKET = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#43 +JMESPath::Lexer::STATE_LT = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#46 +JMESPath::Lexer::STATE_NOT = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#35 +JMESPath::Lexer::STATE_NUMBER = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#42 +JMESPath::Lexer::STATE_PIPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#39 +JMESPath::Lexer::STATE_QUOTED_STRING = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#36 +JMESPath::Lexer::STATE_SINGLE_CHAR = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#38 +JMESPath::Lexer::STATE_STRING_LITERAL = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#37 +JMESPath::Lexer::STATE_WHITESPACE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#49 +JMESPath::Lexer::TRANSLATION_TABLE = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#27 +JMESPath::Lexer::T_AND = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#11 +JMESPath::Lexer::T_COLON = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#10 +JMESPath::Lexer::T_COMMA = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#32 +JMESPath::Lexer::T_COMPARATOR = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#12 +JMESPath::Lexer::T_CURRENT = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#8 +JMESPath::Lexer::T_DOT = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#31 +JMESPath::Lexer::T_EOF = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#13 +JMESPath::Lexer::T_EXPREF = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#29 +JMESPath::Lexer::T_FILTER = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#20 +JMESPath::Lexer::T_FLATTEN = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#21 +JMESPath::Lexer::T_IDENTIFIER = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#16 +JMESPath::Lexer::T_LBRACE = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#18 +JMESPath::Lexer::T_LBRACKET = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#30 +JMESPath::Lexer::T_LITERAL = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#14 +JMESPath::Lexer::T_LPAREN = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#28 +JMESPath::Lexer::T_NOT = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#22 +JMESPath::Lexer::T_NUMBER = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#26 +JMESPath::Lexer::T_OR = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#25 +JMESPath::Lexer::T_PIPE = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#23 +JMESPath::Lexer::T_QUOTED_IDENTIFIER = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#17 +JMESPath::Lexer::T_RBRACE = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#19 +JMESPath::Lexer::T_RBRACKET = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#15 +JMESPath::Lexer::T_RPAREN = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#9 +JMESPath::Lexer::T_STAR = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#24 +JMESPath::Lexer::T_UNKNOWN = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://jmespath//lib/jmespath/lexer.rb#140 +JMESPath::Lexer::VALID_IDENTIFIERS = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://jmespath//lib/jmespath/nodes.rb#4 +module JMESPath::Nodes; end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#87 +class JMESPath::Nodes::AbsFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#90 + def call(args); end +end + +# source://jmespath//lib/jmespath/nodes/and.rb#4 +class JMESPath::Nodes::And < ::JMESPath::Nodes::Node + # @return [And] a new instance of And + # + # source://jmespath//lib/jmespath/nodes/and.rb#5 + def initialize(left, right); end + + # source://jmespath//lib/jmespath/nodes/and.rb#19 + def optimize; end + + # source://jmespath//lib/jmespath/nodes/and.rb#10 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/projection.rb#45 +class JMESPath::Nodes::ArrayProjection < ::JMESPath::Nodes::Projection + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#46 + def extract_targets(target); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#50 + def fast_instance; end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#104 +class JMESPath::Nodes::AvgFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#107 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#129 +class JMESPath::Nodes::CeilFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#132 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/subexpression.rb#38 +class JMESPath::Nodes::Chain + # @api private + # @return [Chain] a new instance of Chain + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#39 + def initialize(children); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#49 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#43 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/field.rb#41 +class JMESPath::Nodes::ChainedField < ::JMESPath::Nodes::Field + # @api private + # @return [ChainedField] a new instance of ChainedField + # + # source://jmespath//lib/jmespath/nodes/field.rb#42 + def initialize(keys); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/field.rb#66 + def chain(other); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/field.rb#49 + def visit(obj); end + + private + + # @api private + # + # source://jmespath//lib/jmespath/nodes/field.rb#72 + def keys; end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#5 +class JMESPath::Nodes::Comparator < ::JMESPath::Nodes::Node + # @api private + # @return [Comparator] a new instance of Comparator + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#10 + def initialize(left, right); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#8 + def left; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#33 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#8 + def right; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#29 + def visit(value); end + + private + + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#39 + def check(_left_value, _right_value); end + + # @api private + # @return [Boolean] + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#43 + def comparable?(left_value, right_value); end + + class << self + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#15 + def create(relation, left, right); end + end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#6 +JMESPath::Nodes::Comparator::COMPARABLE_TYPES = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#29 +class JMESPath::Nodes::ComparatorCondition < ::JMESPath::Nodes::Node + # @api private + # @return [ComparatorCondition] a new instance of ComparatorCondition + # + # source://jmespath//lib/jmespath/nodes/condition.rb#33 + def initialize(left, right, child); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#39 + def visit(_value); end + + private + + # @api private + # @return [Boolean] + # + # source://jmespath//lib/jmespath/nodes/condition.rb#45 + def comparable?(left_value, right_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#31 +JMESPath::Nodes::ComparatorCondition::COMPARABLE_TYPES = T.let(T.unsafe(nil), Array) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#30 +JMESPath::Nodes::ComparatorCondition::COMPARATOR_TO_CONDITION = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#50 +module JMESPath::Nodes::Comparators; end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#51 +class JMESPath::Nodes::Comparators::Eq < ::JMESPath::Nodes::Comparator + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#52 + def check(left_value, right_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#63 +class JMESPath::Nodes::Comparators::Gt < ::JMESPath::Nodes::Comparator + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#64 + def check(left_value, right_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#69 +class JMESPath::Nodes::Comparators::Gte < ::JMESPath::Nodes::Comparator + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#70 + def check(left_value, right_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#75 +class JMESPath::Nodes::Comparators::Lt < ::JMESPath::Nodes::Comparator + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#76 + def check(left_value, right_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#81 +class JMESPath::Nodes::Comparators::Lte < ::JMESPath::Nodes::Comparator + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#82 + def check(left_value, right_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/comparator.rb#57 +class JMESPath::Nodes::Comparators::Neq < ::JMESPath::Nodes::Comparator + # @api private + # + # source://jmespath//lib/jmespath/nodes/comparator.rb#58 + def check(left_value, right_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#503 +module JMESPath::Nodes::CompareBy + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#506 + def compare_by(mode, *args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#5 +class JMESPath::Nodes::Condition < ::JMESPath::Nodes::Node + # @api private + # @return [Condition] a new instance of Condition + # + # source://jmespath//lib/jmespath/nodes/condition.rb#6 + def initialize(test, child); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#19 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#11 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#146 +class JMESPath::Nodes::ContainsFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#149 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/current.rb#5 +class JMESPath::Nodes::Current < ::JMESPath::Nodes::Node + # @api private + # + # source://jmespath//lib/jmespath/nodes/current.rb#6 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#558 +class JMESPath::Nodes::EndsWithFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#563 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#52 +class JMESPath::Nodes::EqCondition < ::JMESPath::Nodes::ComparatorCondition + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#59 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#55 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/expression.rb#5 +class JMESPath::Nodes::Expression < ::JMESPath::Nodes::Node + # @api private + # @return [Expression] a new instance of Expression + # + # source://jmespath//lib/jmespath/nodes/expression.rb#8 + def initialize(expression); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/expression.rb#16 + def eval(value); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/expression.rb#6 + def expression; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/expression.rb#20 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/expression.rb#12 + def visit(_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/projection.rb#55 +class JMESPath::Nodes::FastArrayProjection < ::JMESPath::Nodes::ArrayProjection + include ::JMESPath::Nodes::FastProjector +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/projection.rb#73 +class JMESPath::Nodes::FastObjectProjection < ::JMESPath::Nodes::ObjectProjection + include ::JMESPath::Nodes::FastProjector +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/projection.rb#37 +module JMESPath::Nodes::FastProjector + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#38 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/field.rb#5 +class JMESPath::Nodes::Field < ::JMESPath::Nodes::Node + # @api private + # @return [Field] a new instance of Field + # + # source://jmespath//lib/jmespath/nodes/field.rb#6 + def initialize(key); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/field.rb#30 + def chain(other); end + + # @api private + # @return [Boolean] + # + # source://jmespath//lib/jmespath/nodes/field.rb#26 + def chains_with?(other); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/field.rb#11 + def visit(value); end + + protected + + # @api private + # + # source://jmespath//lib/jmespath/nodes/field.rb#36 + def keys; end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/flatten.rb#5 +class JMESPath::Nodes::Flatten < ::JMESPath::Nodes::Node + # @api private + # @return [Flatten] a new instance of Flatten + # + # source://jmespath//lib/jmespath/nodes/flatten.rb#6 + def initialize(child); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/flatten.rb#23 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/flatten.rb#10 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#166 +class JMESPath::Nodes::FloorFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#169 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#5 +class JMESPath::Nodes::Function < ::JMESPath::Nodes::Node + # @api private + # @return [Function] a new instance of Function + # + # source://jmespath//lib/jmespath/nodes/function.rb#8 + def initialize(children, options = T.unsafe(nil)); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#26 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#22 + def visit(value); end + + private + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#44 + def call(_args); end + + # @api private + # @raise [error_type] + # + # source://jmespath//lib/jmespath/nodes/function.rb#40 + def maybe_raise(error_type, message); end + + class << self + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#14 + def create(name, children, options = T.unsafe(nil)); end + end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#6 +JMESPath::Nodes::Function::FUNCTIONS = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#30 +class JMESPath::Nodes::Function::FunctionName + # @api private + # @return [FunctionName] a new instance of FunctionName + # + # source://jmespath//lib/jmespath/nodes/function.rb#33 + def initialize(name); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#31 + def name; end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#106 +class JMESPath::Nodes::GtCondition < ::JMESPath::Nodes::ComparatorCondition + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#109 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#116 +class JMESPath::Nodes::GteCondition < ::JMESPath::Nodes::ComparatorCondition + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#119 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/index.rb#5 +JMESPath::Nodes::Index = JMESPath::Nodes::Field + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#351 +class JMESPath::Nodes::JoinFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#354 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#311 +class JMESPath::Nodes::KeysFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#314 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#183 +class JMESPath::Nodes::LengthFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#186 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/literal.rb#5 +class JMESPath::Nodes::Literal < ::JMESPath::Nodes::Node + # @api private + # @return [Literal] a new instance of Literal + # + # source://jmespath//lib/jmespath/nodes/literal.rb#8 + def initialize(value); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/literal.rb#6 + def value; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/literal.rb#12 + def visit(_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#68 +class JMESPath::Nodes::LiteralRightEqCondition < ::JMESPath::Nodes::EqCondition + # @api private + # @return [LiteralRightEqCondition] a new instance of LiteralRightEqCondition + # + # source://jmespath//lib/jmespath/nodes/condition.rb#69 + def initialize(left, right, child); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#74 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#95 +class JMESPath::Nodes::LiteralRightNeqCondition < ::JMESPath::Nodes::NeqCondition + # @api private + # @return [LiteralRightNeqCondition] a new instance of LiteralRightNeqCondition + # + # source://jmespath//lib/jmespath/nodes/condition.rb#96 + def initialize(left, right, child); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#101 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#126 +class JMESPath::Nodes::LtCondition < ::JMESPath::Nodes::ComparatorCondition + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#129 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#136 +class JMESPath::Nodes::LteCondition < ::JMESPath::Nodes::ComparatorCondition + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#139 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#204 +class JMESPath::Nodes::Map < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#207 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#538 +class JMESPath::Nodes::MaxByFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + include ::JMESPath::Nodes::CompareBy + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#543 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#225 +class JMESPath::Nodes::MaxFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#230 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#610 +class JMESPath::Nodes::MergeFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#613 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#548 +class JMESPath::Nodes::MinByFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + include ::JMESPath::Nodes::CompareBy + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#553 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#261 +class JMESPath::Nodes::MinFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#266 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#5 +class JMESPath::Nodes::MultiSelectHash < ::JMESPath::Nodes::Node + # @api private + # @return [MultiSelectHash] a new instance of MultiSelectHash + # + # source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#6 + def initialize(kv_pairs); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#20 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#10 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#24 +class JMESPath::Nodes::MultiSelectHash::KeyValuePair + # @api private + # @return [KeyValuePair] a new instance of KeyValuePair + # + # source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#27 + def initialize(key, value); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#25 + def key; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#32 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/multi_select_hash.rb#25 + def value; end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/multi_select_list.rb#5 +class JMESPath::Nodes::MultiSelectList < ::JMESPath::Nodes::Node + # @api private + # @return [MultiSelectList] a new instance of MultiSelectList + # + # source://jmespath//lib/jmespath/nodes/multi_select_list.rb#6 + def initialize(children); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/multi_select_list.rb#18 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/multi_select_list.rb#10 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/condition.rb#79 +class JMESPath::Nodes::NeqCondition < ::JMESPath::Nodes::ComparatorCondition + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#86 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/condition.rb#82 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes.rb#5 +class JMESPath::Nodes::Node + # @api private + # @return [Boolean] + # + # source://jmespath//lib/jmespath/nodes.rb#13 + def chains_with?(_other); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes.rb#9 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes.rb#6 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/not.rb#4 +class JMESPath::Nodes::Not < ::JMESPath::Nodes::Node + # @api private + # @return [Not] a new instance of Not + # + # source://jmespath//lib/jmespath/nodes/not.rb#5 + def initialize(expression); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/not.rb#13 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/not.rb#9 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#419 +class JMESPath::Nodes::NotNullFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#422 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/projection.rb#59 +class JMESPath::Nodes::ObjectProjection < ::JMESPath::Nodes::Projection + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#60 + def extract_targets(target); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#68 + def fast_instance; end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/or.rb#5 +class JMESPath::Nodes::Or < ::JMESPath::Nodes::Node + # @api private + # @return [Or] a new instance of Or + # + # source://jmespath//lib/jmespath/nodes/or.rb#6 + def initialize(left, right); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/or.rb#20 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/or.rb#11 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/pipe.rb#5 +JMESPath::Nodes::Pipe = JMESPath::Nodes::Subexpression + +# @api private +# +# source://jmespath//lib/jmespath/nodes/projection.rb#5 +class JMESPath::Nodes::Projection < ::JMESPath::Nodes::Node + # @api private + # @return [Projection] a new instance of Projection + # + # source://jmespath//lib/jmespath/nodes/projection.rb#6 + def initialize(target, projection); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#22 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#11 + def visit(value); end + + private + + # @api private + # + # source://jmespath//lib/jmespath/nodes/projection.rb#32 + def extract_targets(_left_value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#624 +class JMESPath::Nodes::ReverseFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#627 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/slice.rb#74 +class JMESPath::Nodes::SimpleSlice < ::JMESPath::Nodes::Slice + # @api private + # @return [SimpleSlice] a new instance of SimpleSlice + # + # source://jmespath//lib/jmespath/nodes/slice.rb#75 + def initialize(start, stop); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/slice.rb#79 + def visit(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/slice.rb#5 +class JMESPath::Nodes::Slice < ::JMESPath::Nodes::Node + # @api private + # @raise [Errors::InvalidValueError] + # @return [Slice] a new instance of Slice + # + # source://jmespath//lib/jmespath/nodes/slice.rb#6 + def initialize(start, stop, step); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/slice.rb#34 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/slice.rb#13 + def visit(value); end + + private + + # @api private + # + # source://jmespath//lib/jmespath/nodes/slice.rb#61 + def adjust_endpoint(length, endpoint, step); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/slice.rb#44 + def adjust_slice(length, start, stop, step); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#467 +class JMESPath::Nodes::SortByFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#472 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#431 +class JMESPath::Nodes::SortFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#436 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#584 +class JMESPath::Nodes::StartsWithFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#589 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/subexpression.rb#5 +class JMESPath::Nodes::Subexpression < ::JMESPath::Nodes::Node + # @api private + # @return [Subexpression] a new instance of Subexpression + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#6 + def initialize(left, right); end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#15 + def optimize; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#11 + def visit(value); end + + protected + + # @api private + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#23 + def flatten; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#21 + def left; end + + # @api private + # + # source://jmespath//lib/jmespath/nodes/subexpression.rb#21 + def right; end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#401 +class JMESPath::Nodes::SumFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#404 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#644 +class JMESPath::Nodes::ToArrayFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#647 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#384 +class JMESPath::Nodes::ToNumberFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#387 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#371 +class JMESPath::Nodes::ToStringFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#374 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#49 +module JMESPath::Nodes::TypeChecker + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#50 + def get_type(value); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#68 +JMESPath::Nodes::TypeChecker::ARRAY_TYPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#69 +JMESPath::Nodes::TypeChecker::BOOLEAN_TYPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#70 +JMESPath::Nodes::TypeChecker::EXPRESSION_TYPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#71 +JMESPath::Nodes::TypeChecker::NULL_TYPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#72 +JMESPath::Nodes::TypeChecker::NUMBER_TYPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#73 +JMESPath::Nodes::TypeChecker::OBJECT_TYPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#74 +JMESPath::Nodes::TypeChecker::STRING_TYPE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#76 +JMESPath::Nodes::TypeChecker::TYPE_NAMES = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#297 +class JMESPath::Nodes::TypeFunction < ::JMESPath::Nodes::Function + include ::JMESPath::Nodes::TypeChecker + + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#302 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/nodes/function.rb#330 +class JMESPath::Nodes::ValuesFunction < ::JMESPath::Nodes::Function + # @api private + # + # source://jmespath//lib/jmespath/nodes/function.rb#333 + def call(args); end +end + +# @api private +# +# source://jmespath//lib/jmespath/parser.rb#6 +class JMESPath::Parser + # @api private + # @option options + # @param options [Hash] a customizable set of options + # @return [Parser] a new instance of Parser + # + # source://jmespath//lib/jmespath/parser.rb#30 + def initialize(options = T.unsafe(nil)); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#48 + def method_missing(method_name, *args); end + + # @api private + # @param expression [String] + # + # source://jmespath//lib/jmespath/parser.rb#36 + def parse(expression); end + + private + + # @api private + # @param stream [TokenStream] + # @param rbp [Integer] Right binding power + # + # source://jmespath//lib/jmespath/parser.rb#60 + def expr(stream, rbp = T.unsafe(nil)); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#230 + def led_and(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#160 + def led_comparator(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#167 + def led_dot(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#177 + def led_filter(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#190 + def led_flatten(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#197 + def led_lbracket(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#208 + def led_lparen(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#224 + def led_or(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#236 + def led_pipe(stream, left); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#68 + def nud_current(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#73 + def nud_expref(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#93 + def nud_filter(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#97 + def nud_flatten(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#101 + def nud_identifier(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#111 + def nud_lbrace(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#123 + def nud_lbracket(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#135 + def nud_literal(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#83 + def nud_lparen(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#78 + def nud_not(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#141 + def nud_quoted_identifier(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#152 + def nud_star(stream); end + + # @api private + # @raise [Errors::SyntaxError] + # + # source://jmespath//lib/jmespath/parser.rb#156 + def nud_unknown(stream); end + + # parse array index expressions, for example [0], [1:2:3], etc. + # + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#243 + def parse_array_index_expression(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#274 + def parse_dot(stream, binding_power); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#283 + def parse_key_value_pair(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#290 + def parse_multi_select_list(stream); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#305 + def parse_projection(stream, binding_power); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#319 + def parse_wildcard_array(stream, left = T.unsafe(nil)); end + + # @api private + # + # source://jmespath//lib/jmespath/parser.rb#327 + def parse_wildcard_object(stream, left = T.unsafe(nil)); end +end + +# @api private +# +# source://jmespath//lib/jmespath/parser.rb#7 +JMESPath::Parser::AFTER_DOT = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://jmespath//lib/jmespath/parser.rb#22 +JMESPath::Parser::COLON_RBRACKET = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://jmespath//lib/jmespath/parser.rb#27 +JMESPath::Parser::CURRENT_NODE = T.let(T.unsafe(nil), JMESPath::Nodes::Current) + +# @api private +# +# source://jmespath//lib/jmespath/parser.rb#16 +JMESPath::Parser::NUM_COLON_RBRACKET = T.let(T.unsafe(nil), Set) + +# @api private +# +# source://jmespath//lib/jmespath/runtime.rb#4 +class JMESPath::Runtime + # Constructs a new runtime object for evaluating JMESPath expressions. + # + # runtime = JMESPath::Runtime.new + # runtime.search(expression, data) + # #=> ... + # + # ## Caching + # + # When constructing a {Runtime}, the default parser caches expressions. + # This significantly speeds up calls to {#search} multiple times + # with the same expression but different data. To disable caching, pass + # `:cache_expressions => false` to the constructor or pass a custom + # `:parser`. + # + # @api private + # @example Re-use a Runtime, caching enabled by default + # + # runtime = JMESPath::Runtime.new + # runtime.parser + # #=> # + # @example Disable caching + # + # runtime = JMESPath::Runtime.new(cache_expressions: false) + # runtime.parser + # #=> # + # @option options + # @option options + # @option options + # @param options [Hash] a customizable set of options + # @return [Runtime] a new instance of Runtime + # + # source://jmespath//lib/jmespath/runtime.rb#45 + def initialize(options = T.unsafe(nil)); end + + # @api private + # @return [Parser, CachingParser] + # + # source://jmespath//lib/jmespath/runtime.rb#50 + def parser; end + + # @api private + # @param expression [String] + # @param data [Hash] + # @return [Mixed, nil] + # + # source://jmespath//lib/jmespath/runtime.rb#55 + def search(expression, data); end + + private + + # @api private + # + # source://jmespath//lib/jmespath/runtime.rb#62 + def default_parser(options); end +end + +# @api private +# +# source://jmespath//lib/jmespath/runtime.rb#6 +JMESPath::Runtime::DEFAULT_PARSER = JMESPath::CachingParser + +# @api private +# +# source://jmespath//lib/jmespath/token.rb#4 +class JMESPath::Token < ::Struct + # @api private + # @param type [Symbol] + # @param value [Mixed] + # @param position [Integer] + # @return [Token] a new instance of Token + # + # source://jmespath//lib/jmespath/token.rb#37 + def initialize(type, value, position); end +end + +# @api private +# +# source://jmespath//lib/jmespath/token.rb#7 +JMESPath::Token::BINDING_POWER = T.let(T.unsafe(nil), Hash) + +# @api private +# +# source://jmespath//lib/jmespath/token.rb#5 +JMESPath::Token::NULL_TOKEN = T.let(T.unsafe(nil), JMESPath::Token) + +# @api private +# +# source://jmespath//lib/jmespath/token_stream.rb#4 +class JMESPath::TokenStream + # @api private + # @param expression [String] + # @param tokens [Array] + # @return [TokenStream] a new instance of TokenStream + # + # source://jmespath//lib/jmespath/token_stream.rb#7 + def initialize(expression, tokens); end + + # @api private + # @return [String] + # + # source://jmespath//lib/jmespath/token_stream.rb#16 + def expression; end + + # @api private + # + # source://jmespath//lib/jmespath/token_stream.rb#35 + def inspect; end + + # @api private + # + # source://jmespath//lib/jmespath/token_stream.rb#30 + def lookahead(count); end + + # @api private + # @option options + # @param options [Hash] a customizable set of options + # + # source://jmespath//lib/jmespath/token_stream.rb#26 + def next(options = T.unsafe(nil)); end + + # @api private + # @return [Integer] + # + # source://jmespath//lib/jmespath/token_stream.rb#22 + def position; end + + # @api private + # @return [Token] + # + # source://jmespath//lib/jmespath/token_stream.rb#19 + def token; end + + private + + # @api private + # + # source://jmespath//lib/jmespath/token_stream.rb#46 + def _next; end + + # @api private + # + # source://jmespath//lib/jmespath/token_stream.rb#51 + def validate_match(token, match); end +end + +# @api private +# +# source://jmespath//lib/jmespath/util.rb#4 +module JMESPath::Util + class << self + # @api private + # + # source://jmespath//lib/jmespath/util.rb#19 + def as_json(value); end + + # Determines if a value is false as defined by JMESPath: + # + # https://github.com/jmespath/jmespath.site/blob/master/docs/proposals/improved-filters.rst#and-expressions-1 + # + # @api private + # @return [Boolean] + # + # source://jmespath//lib/jmespath/util.rb#10 + def falsey?(value); end + end +end + +# source://jmespath//lib/jmespath/version.rb#3 +JMESPath::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/jquery-rails@4.5.1.rbi b/sorbet/rbi/gems/jquery-rails@4.6.0.rbi similarity index 85% rename from sorbet/rbi/gems/jquery-rails@4.5.1.rbi rename to sorbet/rbi/gems/jquery-rails@4.6.0.rbi index 2bf0c0543..cbe616335 100644 --- a/sorbet/rbi/gems/jquery-rails@4.5.1.rbi +++ b/sorbet/rbi/gems/jquery-rails@4.6.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `jquery-rails` gem. # Please instead update this file by running `bin/tapioca gem jquery-rails`. + # source://jquery-rails//lib/jquery/rails/engine.rb#1 module Jquery; end @@ -11,7 +12,12 @@ module Jquery; end module Jquery::Rails; end # source://jquery-rails//lib/jquery/rails/engine.rb#3 -class Jquery::Rails::Engine < ::Rails::Engine; end +class Jquery::Rails::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # source://jquery-rails//lib/jquery/rails/version.rb#5 Jquery::Rails::JQUERY_2_VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/json@2.6.3.rbi b/sorbet/rbi/gems/json@2.7.2.rbi similarity index 92% rename from sorbet/rbi/gems/json@2.6.3.rbi rename to sorbet/rbi/gems/json@2.7.2.rbi index 259116aa0..ce4a9b24c 100644 --- a/sorbet/rbi/gems/json@2.6.3.rbi +++ b/sorbet/rbi/gems/json@2.7.2.rbi @@ -1,10 +1,13 @@ -# typed: true +# typed: false # DO NOT EDIT MANUALLY # This is an autogenerated file for types exported from the `json` gem. # Please instead update this file by running `bin/tapioca gem json`. + # Extends any Class to include _json_creatable?_ method. +# +# source://json//lib/json/common.rb#690 class Class < ::Module # Returns true if this class can be used to create an instance # from a serialised JSON string. The class has to implement a class @@ -13,7 +16,7 @@ class Class < ::Module # # @return [Boolean] # - # source://json//json/common.rb#700 + # source://json//lib/json/common.rb#695 def json_creatable?; end end @@ -300,6 +303,15 @@ end # # Raises JSON::NestingError (nesting of 2 is too deep): # JSON.generate(obj, max_nesting: 2) # +# ====== Escaping Options +# +# Options +script_safe+ (boolean) specifies wether '\u2028', '\u2029' +# and '/' should be escaped as to make the JSON object safe to interpolate in script +# tags. +# +# Options +ascii_only+ (boolean) specifies wether all characters outside the ASCII range +# should be escaped. +# # ====== Output Options # # The default formatting options generate the most compact @@ -586,7 +598,11 @@ end # Parsed JSON: # Without custom addition: "#" (String) # With custom addition: # (Foo) +# +# source://json//lib/json/version.rb#2 module JSON + extend ::Bootsnap::CompileCache::JSON::Patch + private # :call-seq: @@ -617,8 +633,8 @@ module JSON # Output: # {"foo":[0,1],"bar":{"baz":2,"bat":3},"bam":"bad"} # - # source://json//json/common.rb#631 - def dump(obj, anIO = T.unsafe(nil), limit = T.unsafe(nil)); end + # source://json//lib/json/common.rb#615 + def dump(obj, anIO = T.unsafe(nil), limit = T.unsafe(nil), kwargs = T.unsafe(nil)); end # :call-seq: # JSON.fast_generate(obj, opts) -> new_string @@ -634,13 +650,13 @@ module JSON # # Raises SystemStackError (stack level too deep): # JSON.fast_generate(a) # - # source://json//json/common.rb#335 + # source://json//lib/json/common.rb#329 def fast_generate(obj, opts = T.unsafe(nil)); end # :stopdoc: # I want to deprecate these later, so I'll first be silent about them, and later delete them. # - # source://json//json/common.rb#335 + # source://json//lib/json/common.rb#329 def fast_unparse(obj, opts = T.unsafe(nil)); end # :call-seq: @@ -679,7 +695,7 @@ module JSON # # Raises JSON::NestingError (nesting of 100 is too deep): # JSON.generate(a) # - # source://json//json/common.rb#296 + # source://json//lib/json/common.rb#300 def generate(obj, opts = T.unsafe(nil)); end # :call-seq: @@ -810,7 +826,7 @@ module JSON # #"Admin", "password"=>"0wn3d"}>} # - # source://json//json/common.rb#557 + # source://json//lib/json/common.rb#541 def load(source, proc = T.unsafe(nil), options = T.unsafe(nil)); end # :call-seq: @@ -821,7 +837,7 @@ module JSON # # See method #parse. # - # source://json//json/common.rb#245 + # source://json//lib/json/common.rb#249 def load_file(filespec, opts = T.unsafe(nil)); end # :call-seq: @@ -832,9 +848,12 @@ module JSON # # See method #parse! # - # source://json//json/common.rb#256 + # source://json//lib/json/common.rb#260 def load_file!(filespec, opts = T.unsafe(nil)); end + # source://json//lib/json/common.rb#643 + def merge_dump_options(opts, strict: T.unsafe(nil)); end + # :call-seq: # JSON.parse(source, opts) -> object # @@ -883,7 +902,7 @@ module JSON # # Raises JSON::ParserError (783: unexpected token at ''): # JSON.parse('') # - # source://json//json/common.rb#215 + # source://json//lib/json/common.rb#219 def parse(source, opts = T.unsafe(nil)); end # :call-seq: @@ -898,7 +917,7 @@ module JSON # which disables checking for nesting depth. # - Option +allow_nan+, if not provided, defaults to +true+. # - # source://json//json/common.rb#230 + # source://json//lib/json/common.rb#234 def parse!(source, opts = T.unsafe(nil)); end # :call-seq: @@ -931,28 +950,28 @@ module JSON # } # } # - # source://json//json/common.rb#390 + # source://json//lib/json/common.rb#374 def pretty_generate(obj, opts = T.unsafe(nil)); end # :stopdoc: # I want to deprecate these later, so I'll first be silent about them, and later delete them. # - # source://json//json/common.rb#390 + # source://json//lib/json/common.rb#374 def pretty_unparse(obj, opts = T.unsafe(nil)); end # Recursively calls passed _Proc_ if the parsed data structure is an _Array_ or _Hash_ # - # source://json//json/common.rb#575 + # source://json//lib/json/common.rb#559 def recurse_proc(result, &proc); end - # source://json//json/common.rb#557 + # source://json//lib/json/common.rb#541 def restore(source, proc = T.unsafe(nil), options = T.unsafe(nil)); end # :stopdoc: # I want to deprecate these later, so I'll first be silent about them, and # later delete them. # - # source://json//json/common.rb#296 + # source://json//lib/json/common.rb#300 def unparse(obj, opts = T.unsafe(nil)); end class << self @@ -968,26 +987,26 @@ module JSON # ruby = [0, 1, nil] # JSON[ruby] # => '[0,1,null]' # - # source://json//json/common.rb#18 + # source://json//lib/json/common.rb#22 def [](object, opts = T.unsafe(nil)); end - # source://json//json/common.rb#81 + # source://json//lib/json/common.rb#85 def create_fast_state; end # Returns the current create identifier. # See also JSON.create_id=. # - # source://json//json/common.rb#126 + # source://json//lib/json/common.rb#130 def create_id; end # Sets create identifier, which is used to decide if the _json_create_ # hook of a class should be called; initial value is +json_class+: # JSON.create_id # => 'json_class' # - # source://json//json/common.rb#120 + # source://json//lib/json/common.rb#124 def create_id=(new_value); end - # source://json//json/common.rb#91 + # source://json//lib/json/common.rb#95 def create_pretty_state; end # Return the constant located at _path_. The format of _path_ has to be @@ -995,7 +1014,7 @@ module JSON # level (absolute namespace path?). If there doesn't exist a constant at # the given path, an ArgumentError is raised. # - # source://json//json/common.rb#42 + # source://json//lib/json/common.rb#46 def deep_const_get(path); end # :call-seq: @@ -1026,23 +1045,23 @@ module JSON # Output: # {"foo":[0,1],"bar":{"baz":2,"bat":3},"bam":"bad"} # - # source://json//json/common.rb#631 - def dump(obj, anIO = T.unsafe(nil), limit = T.unsafe(nil)); end + # source://json//lib/json/common.rb#615 + def dump(obj, anIO = T.unsafe(nil), limit = T.unsafe(nil), kwargs = T.unsafe(nil)); end # Sets or returns the default options for the JSON.dump method. # Initially: # opts = JSON.dump_default_options - # opts # => {:max_nesting=>false, :allow_nan=>true, :escape_slash=>false} + # opts # => {:max_nesting=>false, :allow_nan=>true, :script_safe=>false} # - # source://json//json/common.rb#596 + # source://json//lib/json/common.rb#580 def dump_default_options; end # Sets or returns the default options for the JSON.dump method. # Initially: # opts = JSON.dump_default_options - # opts # => {:max_nesting=>false, :allow_nan=>true, :escape_slash=>false} + # opts # => {:max_nesting=>false, :allow_nan=>true, :script_safe=>false} # - # source://json//json/common.rb#596 + # source://json//lib/json/common.rb#580 def dump_default_options=(_arg0); end # :call-seq: @@ -1059,13 +1078,13 @@ module JSON # # Raises SystemStackError (stack level too deep): # JSON.fast_generate(a) # - # source://json//json/common.rb#335 + # source://json//lib/json/common.rb#329 def fast_generate(obj, opts = T.unsafe(nil)); end # :stopdoc: # I want to deprecate these later, so I'll first be silent about them, and later delete them. # - # source://json//json/common.rb#335 + # source://json//lib/json/common.rb#329 def fast_unparse(obj, opts = T.unsafe(nil)); end # :call-seq: @@ -1104,24 +1123,24 @@ module JSON # # Raises JSON::NestingError (nesting of 100 is too deep): # JSON.generate(a) # - # source://json//json/common.rb#296 + # source://json//lib/json/common.rb#300 def generate(obj, opts = T.unsafe(nil)); end # Returns the JSON generator module that is used by JSON. This is # either JSON::Ext::Generator or JSON::Pure::Generator: # JSON.generator # => JSON::Ext::Generator # - # source://json//json/common.rb#103 + # source://json//lib/json/common.rb#107 def generator; end # Set the module _generator_ to be used by JSON. # - # source://json//json/common.rb#58 + # source://json//lib/json/common.rb#62 def generator=(generator); end # Encodes string using String.encode. # - # source://json//json/common.rb#653 + # source://json//lib/json/common.rb#639 def iconv(to, from, string); end # :call-seq: @@ -1252,7 +1271,7 @@ module JSON # #"Admin", "password"=>"0wn3d"}>} # - # source://json//json/common.rb#557 + # source://json//lib/json/common.rb#541 def load(source, proc = T.unsafe(nil), options = T.unsafe(nil)); end # Sets or returns default options for the JSON.load method. @@ -1260,7 +1279,7 @@ module JSON # opts = JSON.load_default_options # opts # => {:max_nesting=>false, :allow_nan=>true, :allow_blank=>true, :create_additions=>true} # - # source://json//json/common.rb#420 + # source://json//lib/json/common.rb#404 def load_default_options; end # Sets or returns default options for the JSON.load method. @@ -1268,20 +1287,9 @@ module JSON # opts = JSON.load_default_options # opts # => {:max_nesting=>false, :allow_nan=>true, :allow_blank=>true, :create_additions=>true} # - # source://json//json/common.rb#420 + # source://json//lib/json/common.rb#404 def load_default_options=(_arg0); end - # :call-seq: - # JSON.load_file(path, opts={}) -> object - # - # Calls: - # parse(File.read(path), opts) - # - # See method #parse. - # - # source://json//json/common.rb#245 - def load_file(filespec, opts = T.unsafe(nil)); end - # :call-seq: # JSON.load_file!(path, opts = {}) # @@ -1290,7 +1298,7 @@ module JSON # # See method #parse! # - # source://json//json/common.rb#256 + # source://json//lib/json/common.rb#260 def load_file!(filespec, opts = T.unsafe(nil)); end # :call-seq: @@ -1341,7 +1349,7 @@ module JSON # # Raises JSON::ParserError (783: unexpected token at ''): # JSON.parse('') # - # source://json//json/common.rb#215 + # source://json//lib/json/common.rb#219 def parse(source, opts = T.unsafe(nil)); end # :call-seq: @@ -1356,19 +1364,19 @@ module JSON # which disables checking for nesting depth. # - Option +allow_nan+, if not provided, defaults to +true+. # - # source://json//json/common.rb#230 + # source://json//lib/json/common.rb#234 def parse!(source, opts = T.unsafe(nil)); end # Returns the JSON parser class that is used by JSON. This is either # JSON::Ext::Parser or JSON::Pure::Parser: # JSON.parser # => JSON::Ext::Parser # - # source://json//json/common.rb#29 + # source://json//lib/json/common.rb#33 def parser; end # Set the JSON parser class _parser_ to be used by JSON. # - # source://json//json/common.rb#32 + # source://json//lib/json/common.rb#36 def parser=(parser); end # :call-seq: @@ -1401,111 +1409,123 @@ module JSON # } # } # - # source://json//json/common.rb#390 + # source://json//lib/json/common.rb#374 def pretty_generate(obj, opts = T.unsafe(nil)); end # :stopdoc: # I want to deprecate these later, so I'll first be silent about them, and later delete them. # - # source://json//json/common.rb#390 + # source://json//lib/json/common.rb#374 def pretty_unparse(obj, opts = T.unsafe(nil)); end # Recursively calls passed _Proc_ if the parsed data structure is an _Array_ or _Hash_ # - # source://json//json/common.rb#575 + # source://json//lib/json/common.rb#559 def recurse_proc(result, &proc); end - # source://json//json/common.rb#557 + # source://json//lib/json/common.rb#541 def restore(source, proc = T.unsafe(nil), options = T.unsafe(nil)); end # Sets or Returns the JSON generator state class that is used by JSON. This is # either JSON::Ext::Generator::State or JSON::Pure::Generator::State: # JSON.state # => JSON::Ext::Generator::State # - # source://json//json/common.rb#108 + # source://json//lib/json/common.rb#112 def state; end # Sets or Returns the JSON generator state class that is used by JSON. This is # either JSON::Ext::Generator::State or JSON::Pure::Generator::State: # JSON.state # => JSON::Ext::Generator::State # - # source://json//json/common.rb#108 + # source://json//lib/json/common.rb#112 def state=(_arg0); end # :stopdoc: # I want to deprecate these later, so I'll first be silent about them, and # later delete them. # - # source://json//json/common.rb#296 + # source://json//lib/json/common.rb#300 def unparse(obj, opts = T.unsafe(nil)); end + + private + + # source://json//lib/json/common.rb#643 + def merge_dump_options(opts, strict: T.unsafe(nil)); end end end -# source://json//json/common.rb#114 +# source://json//lib/json/common.rb#118 JSON::CREATE_ID_TLS_KEY = T.let(T.unsafe(nil), String) -# source://json//json/common.rb#111 +# source://json//lib/json/common.rb#115 JSON::DEFAULT_CREATE_ID = T.let(T.unsafe(nil), String) +# source://json//lib/json/generic_object.rb#9 class JSON::GenericObject < ::OpenStruct - # source://json//json/generic_object.rb#63 + # source://json//lib/json/generic_object.rb#67 def as_json(*_arg0); end - # source://json//json/generic_object.rb#47 + # source://json//lib/json/generic_object.rb#51 def to_hash; end - # source://json//json/generic_object.rb#67 + # source://json//lib/json/generic_object.rb#71 def to_json(*a); end - # source://json//json/generic_object.rb#59 + # source://json//lib/json/generic_object.rb#63 def |(other); end class << self - # source://json//json/generic_object.rb#41 + # source://json//lib/json/generic_object.rb#45 def dump(obj, *args); end - # source://json//json/generic_object.rb#21 + # source://json//lib/json/generic_object.rb#25 def from_hash(object); end # Sets the attribute json_creatable # # @param value the value to set the attribute json_creatable to. # - # source://json//json/generic_object.rb#13 + # source://json//lib/json/generic_object.rb#17 def json_creatable=(_arg0); end # @return [Boolean] # - # source://json//json/generic_object.rb#9 + # source://json//lib/json/generic_object.rb#13 def json_creatable?; end - # source://json//json/generic_object.rb#15 + # source://json//lib/json/generic_object.rb#19 def json_create(data); end - # source://json//json/generic_object.rb#36 + # source://json//lib/json/generic_object.rb#40 def load(source, proc = T.unsafe(nil), opts = T.unsafe(nil)); end end end # The base exception for JSON errors. +# +# source://json//lib/json/common.rb#141 class JSON::JSONError < ::StandardError class << self - # source://json//json/common.rb#138 + # source://json//lib/json/common.rb#142 def wrap(exception); end end end -# source://json//json/common.rb#35 +# source://json//lib/json/common.rb#7 +JSON::NOT_SET = T.let(T.unsafe(nil), Object) + +# source://json//lib/json/common.rb#39 JSON::Parser = JSON::Ext::Parser -# source://json//json/common.rb#73 +# source://json//lib/json/common.rb#77 JSON::State = JSON::Ext::Generator::State # For backwards compatibility # -# source://json//json/common.rb#159 +# source://json//lib/json/common.rb#163 JSON::UnparserError = JSON::GeneratorError +# source://json//lib/json/common.rb#653 module Kernel private @@ -1516,18 +1536,18 @@ module Kernel # The _opts_ argument is passed through to generate/parse respectively. See # generate and parse for their documentation. # - # source://json//json/common.rb#685 + # source://json//lib/json/common.rb#680 def JSON(object, *args); end # Outputs _objs_ to STDOUT as JSON strings in the shortest form, that is in # one line. # - # source://json//json/common.rb#663 + # source://json//lib/json/common.rb#658 def j(*objs); end # Outputs _objs_ to STDOUT as JSON strings in a pretty format, with # indentation and over many lines. # - # source://json//json/common.rb#672 + # source://json//lib/json/common.rb#667 def jj(*objs); end end diff --git a/sorbet/rbi/gems/json_expressions@0.9.0.rbi b/sorbet/rbi/gems/json_expressions@0.9.0.rbi index 80efc2537..7e5e637f1 100644 --- a/sorbet/rbi/gems/json_expressions@0.9.0.rbi +++ b/sorbet/rbi/gems/json_expressions@0.9.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `json_expressions` gem. # Please instead update this file by running `bin/tapioca gem json_expressions`. + # source://json_expressions//lib/json_expressions/core_extensions.rb#82 class Array include ::Enumerable @@ -22,9 +23,6 @@ class Array def reject_extra_values!; end end -# source://activesupport/7.0.5/lib/active_support/core_ext/array/deprecated_conversions.rb#4 -Array::NOT_SET = T.let(T.unsafe(nil), Object) - # source://json_expressions//lib/json_expressions/core_extensions.rb#74 class Hash include ::Enumerable diff --git a/sorbet/rbi/gems/kramdown-parser-gfm@1.1.0.rbi b/sorbet/rbi/gems/kramdown-parser-gfm@1.1.0.rbi index 78e55f409..3c9d0660b 100644 --- a/sorbet/rbi/gems/kramdown-parser-gfm@1.1.0.rbi +++ b/sorbet/rbi/gems/kramdown-parser-gfm@1.1.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `kramdown-parser-gfm` gem. # Please instead update this file by running `bin/tapioca gem kramdown-parser-gfm`. + # source://kramdown-parser-gfm//lib/kramdown/parser/gfm/options.rb#10 module Kramdown class << self @@ -44,9 +45,6 @@ module Kramdown::Options end end -# source://kramdown/2.4.0/lib/kramdown/options.rb#39 -Kramdown::Options::ALLOWED_TYPES = T.let(T.unsafe(nil), Array) - # source://kramdown-parser-gfm//lib/kramdown/parser/gfm.rb#16 module Kramdown::Parser; end @@ -128,6 +126,3 @@ Kramdown::Parser::GFM::STRIKETHROUGH_MATCH = T.let(T.unsafe(nil), Regexp) # source://kramdown-parser-gfm//lib/kramdown/parser/gfm.rb#21 Kramdown::Parser::GFM::VERSION = T.let(T.unsafe(nil), String) - -# source://kramdown/2.4.0/lib/kramdown/version.rb#13 -Kramdown::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/kramdown@2.4.0.rbi b/sorbet/rbi/gems/kramdown@2.4.0.rbi index 9b2edd525..ee2bcd8de 100644 --- a/sorbet/rbi/gems/kramdown@2.4.0.rbi +++ b/sorbet/rbi/gems/kramdown@2.4.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `kramdown` gem. # Please instead update this file by running `bin/tapioca gem kramdown`. + # source://kramdown//lib/kramdown/version.rb#10 module Kramdown class << self diff --git a/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi b/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi index 317fd1a2f..a0375c0fa 100644 --- a/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi +++ b/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi @@ -4,5 +4,14235 @@ # This is an autogenerated file for types exported from the `language_server-protocol` gem. # Please instead update this file by running `bin/tapioca gem language_server-protocol`. -# THIS IS AN EMPTY RBI FILE. -# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem + +# source://language_server-protocol//lib/language_server/protocol/version.rb#1 +module LanguageServer; end + +# source://language_server-protocol//lib/language_server/protocol/version.rb#2 +module LanguageServer::Protocol; end + +# source://language_server-protocol//lib/language_server/protocol/constant.rb#3 +module LanguageServer::Protocol::Constant; end + +# The kind of a code action. +# +# Kinds are a hierarchical list of identifiers separated by `.`, +# e.g. `"refactor.extract.function"`. +# +# The set of kinds is open and client needs to announce the kinds it supports +# to the server during initialization. +# A set of predefined code action kinds. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#14 +module LanguageServer::Protocol::Constant::CodeActionKind; end + +# Empty kind. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#18 +LanguageServer::Protocol::Constant::CodeActionKind::EMPTY = T.let(T.unsafe(nil), String) + +# Base kind for quickfix actions: 'quickfix'. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#22 +LanguageServer::Protocol::Constant::CodeActionKind::QUICK_FIX = T.let(T.unsafe(nil), String) + +# Base kind for refactoring actions: 'refactor'. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#26 +LanguageServer::Protocol::Constant::CodeActionKind::REFACTOR = T.let(T.unsafe(nil), String) + +# Base kind for refactoring extraction actions: 'refactor.extract'. +# +# Example extract actions: +# +# - Extract method +# - Extract function +# - Extract variable +# - Extract interface from class +# - ... +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#38 +LanguageServer::Protocol::Constant::CodeActionKind::REFACTOR_EXTRACT = T.let(T.unsafe(nil), String) + +# Base kind for refactoring inline actions: 'refactor.inline'. +# +# Example inline actions: +# +# - Inline function +# - Inline variable +# - Inline constant +# - ... +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#49 +LanguageServer::Protocol::Constant::CodeActionKind::REFACTOR_INLINE = T.let(T.unsafe(nil), String) + +# Base kind for refactoring rewrite actions: 'refactor.rewrite'. +# +# Example rewrite actions: +# +# - Convert JavaScript function to class +# - Add or remove parameter +# - Encapsulate field +# - Make method static +# - Move method to base class +# - ... +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#62 +LanguageServer::Protocol::Constant::CodeActionKind::REFACTOR_REWRITE = T.let(T.unsafe(nil), String) + +# Base kind for source actions: `source`. +# +# Source code actions apply to the entire file. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#68 +LanguageServer::Protocol::Constant::CodeActionKind::SOURCE = T.let(T.unsafe(nil), String) + +# Base kind for a 'fix all' source action: `source.fixAll`. +# +# 'Fix all' actions automatically fix errors that have a clear fix that +# do not require user input. They should not suppress errors or perform +# unsafe fixes such as generating new types or classes. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#81 +LanguageServer::Protocol::Constant::CodeActionKind::SOURCE_FIX_ALL = T.let(T.unsafe(nil), String) + +# Base kind for an organize imports source action: +# `source.organizeImports`. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_kind.rb#73 +LanguageServer::Protocol::Constant::CodeActionKind::SOURCE_ORGANIZE_IMPORTS = T.let(T.unsafe(nil), String) + +# The reason why code actions were requested. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_trigger_kind.rb#7 +module LanguageServer::Protocol::Constant::CodeActionTriggerKind; end + +# Code actions were requested automatically. +# +# This typically happens when current selection in a file changes, but can +# also be triggered when file content changes. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_trigger_kind.rb#18 +LanguageServer::Protocol::Constant::CodeActionTriggerKind::AUTOMATIC = T.let(T.unsafe(nil), Integer) + +# Code actions were explicitly requested by the user or by an extension. +# +# source://language_server-protocol//lib/language_server/protocol/constant/code_action_trigger_kind.rb#11 +LanguageServer::Protocol::Constant::CodeActionTriggerKind::INVOKED = T.let(T.unsafe(nil), Integer) + +# The kind of a completion entry. +# +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#7 +module LanguageServer::Protocol::Constant::CompletionItemKind; end + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#14 +LanguageServer::Protocol::Constant::CompletionItemKind::CLASS = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#23 +LanguageServer::Protocol::Constant::CompletionItemKind::COLOR = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#28 +LanguageServer::Protocol::Constant::CompletionItemKind::CONSTANT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#11 +LanguageServer::Protocol::Constant::CompletionItemKind::CONSTRUCTOR = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#20 +LanguageServer::Protocol::Constant::CompletionItemKind::ENUM = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#27 +LanguageServer::Protocol::Constant::CompletionItemKind::ENUM_MEMBER = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#30 +LanguageServer::Protocol::Constant::CompletionItemKind::EVENT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#12 +LanguageServer::Protocol::Constant::CompletionItemKind::FIELD = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#24 +LanguageServer::Protocol::Constant::CompletionItemKind::FILE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#26 +LanguageServer::Protocol::Constant::CompletionItemKind::FOLDER = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#10 +LanguageServer::Protocol::Constant::CompletionItemKind::FUNCTION = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#15 +LanguageServer::Protocol::Constant::CompletionItemKind::INTERFACE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#21 +LanguageServer::Protocol::Constant::CompletionItemKind::KEYWORD = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#9 +LanguageServer::Protocol::Constant::CompletionItemKind::METHOD = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#16 +LanguageServer::Protocol::Constant::CompletionItemKind::MODULE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#31 +LanguageServer::Protocol::Constant::CompletionItemKind::OPERATOR = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#17 +LanguageServer::Protocol::Constant::CompletionItemKind::PROPERTY = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#25 +LanguageServer::Protocol::Constant::CompletionItemKind::REFERENCE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#22 +LanguageServer::Protocol::Constant::CompletionItemKind::SNIPPET = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#29 +LanguageServer::Protocol::Constant::CompletionItemKind::STRUCT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#8 +LanguageServer::Protocol::Constant::CompletionItemKind::TEXT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#32 +LanguageServer::Protocol::Constant::CompletionItemKind::TYPE_PARAMETER = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#18 +LanguageServer::Protocol::Constant::CompletionItemKind::UNIT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#19 +LanguageServer::Protocol::Constant::CompletionItemKind::VALUE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_kind.rb#13 +LanguageServer::Protocol::Constant::CompletionItemKind::VARIABLE = T.let(T.unsafe(nil), Integer) + +# Completion item tags are extra annotations that tweak the rendering of a +# completion item. +# +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_tag.rb#8 +module LanguageServer::Protocol::Constant::CompletionItemTag; end + +# Render a completion as obsolete, usually using a strike-out. +# +# source://language_server-protocol//lib/language_server/protocol/constant/completion_item_tag.rb#12 +LanguageServer::Protocol::Constant::CompletionItemTag::DEPRECATED = T.let(T.unsafe(nil), Integer) + +# How a completion was triggered +# +# source://language_server-protocol//lib/language_server/protocol/constant/completion_trigger_kind.rb#7 +module LanguageServer::Protocol::Constant::CompletionTriggerKind; end + +# Completion was triggered by typing an identifier (24x7 code +# complete), manual invocation (e.g Ctrl+Space) or via API. +# +# source://language_server-protocol//lib/language_server/protocol/constant/completion_trigger_kind.rb#12 +LanguageServer::Protocol::Constant::CompletionTriggerKind::INVOKED = T.let(T.unsafe(nil), Integer) + +# Completion was triggered by a trigger character specified by +# the `triggerCharacters` properties of the +# `CompletionRegistrationOptions`. +# +# source://language_server-protocol//lib/language_server/protocol/constant/completion_trigger_kind.rb#18 +LanguageServer::Protocol::Constant::CompletionTriggerKind::TRIGGER_CHARACTER = T.let(T.unsafe(nil), Integer) + +# Completion was re-triggered as the current completion list is incomplete. +# +# source://language_server-protocol//lib/language_server/protocol/constant/completion_trigger_kind.rb#22 +LanguageServer::Protocol::Constant::CompletionTriggerKind::TRIGGER_FOR_INCOMPLETE_COMPLETIONS = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_severity.rb#4 +module LanguageServer::Protocol::Constant::DiagnosticSeverity; end + +# Reports an error. +# +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_severity.rb#8 +LanguageServer::Protocol::Constant::DiagnosticSeverity::ERROR = T.let(T.unsafe(nil), Integer) + +# Reports a hint. +# +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_severity.rb#20 +LanguageServer::Protocol::Constant::DiagnosticSeverity::HINT = T.let(T.unsafe(nil), Integer) + +# Reports an information. +# +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_severity.rb#16 +LanguageServer::Protocol::Constant::DiagnosticSeverity::INFORMATION = T.let(T.unsafe(nil), Integer) + +# Reports a warning. +# +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_severity.rb#12 +LanguageServer::Protocol::Constant::DiagnosticSeverity::WARNING = T.let(T.unsafe(nil), Integer) + +# The diagnostic tags. +# +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_tag.rb#7 +module LanguageServer::Protocol::Constant::DiagnosticTag; end + +# Deprecated or obsolete code. +# +# Clients are allowed to rendered diagnostics with this tag strike through. +# +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_tag.rb#20 +LanguageServer::Protocol::Constant::DiagnosticTag::DEPRECATED = T.let(T.unsafe(nil), Integer) + +# Unused or unnecessary code. +# +# Clients are allowed to render diagnostics with this tag faded out +# instead of having an error squiggle. +# +# source://language_server-protocol//lib/language_server/protocol/constant/diagnostic_tag.rb#14 +LanguageServer::Protocol::Constant::DiagnosticTag::UNNECESSARY = T.let(T.unsafe(nil), Integer) + +# The document diagnostic report kinds. +# +# source://language_server-protocol//lib/language_server/protocol/constant/document_diagnostic_report_kind.rb#7 +module LanguageServer::Protocol::Constant::DocumentDiagnosticReportKind; end + +# A diagnostic report with a full +# set of problems. +# +# source://language_server-protocol//lib/language_server/protocol/constant/document_diagnostic_report_kind.rb#12 +LanguageServer::Protocol::Constant::DocumentDiagnosticReportKind::FULL = T.let(T.unsafe(nil), String) + +# A report indicating that the last +# returned report is still accurate. +# +# source://language_server-protocol//lib/language_server/protocol/constant/document_diagnostic_report_kind.rb#17 +LanguageServer::Protocol::Constant::DocumentDiagnosticReportKind::UNCHANGED = T.let(T.unsafe(nil), String) + +# A document highlight kind. +# +# source://language_server-protocol//lib/language_server/protocol/constant/document_highlight_kind.rb#7 +module LanguageServer::Protocol::Constant::DocumentHighlightKind; end + +# Read-access of a symbol, like reading a variable. +# +# source://language_server-protocol//lib/language_server/protocol/constant/document_highlight_kind.rb#15 +LanguageServer::Protocol::Constant::DocumentHighlightKind::READ = T.let(T.unsafe(nil), Integer) + +# A textual occurrence. +# +# source://language_server-protocol//lib/language_server/protocol/constant/document_highlight_kind.rb#11 +LanguageServer::Protocol::Constant::DocumentHighlightKind::TEXT = T.let(T.unsafe(nil), Integer) + +# Write-access of a symbol, like writing to a variable. +# +# source://language_server-protocol//lib/language_server/protocol/constant/document_highlight_kind.rb#19 +LanguageServer::Protocol::Constant::DocumentHighlightKind::WRITE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#4 +module LanguageServer::Protocol::Constant::ErrorCodes; end + +# The server detected that the content of a document got +# modified outside normal conditions. A server should +# NOT send this error code if it detects a content change +# in it unprocessed messages. The result even computed +# on an older state might still be useful for the client. +# +# If a client decides that a result is not of any use anymore +# the client should cancel the request. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#59 +LanguageServer::Protocol::Constant::ErrorCodes::CONTENT_MODIFIED = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#9 +LanguageServer::Protocol::Constant::ErrorCodes::INTERNAL_ERROR = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#8 +LanguageServer::Protocol::Constant::ErrorCodes::INVALID_PARAMS = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#6 +LanguageServer::Protocol::Constant::ErrorCodes::INVALID_REQUEST = T.let(T.unsafe(nil), Integer) + +# This is the end range of JSON-RPC reserved error codes. +# It doesn't denote a real error code. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#29 +LanguageServer::Protocol::Constant::ErrorCodes::JSONRPC_RESERVED_ERROR_RANGE_END = T.let(T.unsafe(nil), Integer) + +# This is the start range of JSON-RPC reserved error codes. +# It doesn't denote a real error code. No LSP error codes should +# be defined between the start and end range. For backwards +# compatibility the `ServerNotInitialized` and the `UnknownErrorCode` +# are left in the range. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#17 +LanguageServer::Protocol::Constant::ErrorCodes::JSONRPC_RESERVED_ERROR_RANGE_START = T.let(T.unsafe(nil), Integer) + +# This is the end range of LSP reserved error codes. +# It doesn't denote a real error code. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#69 +LanguageServer::Protocol::Constant::ErrorCodes::LSP_RESERVED_ERROR_RANGE_END = T.let(T.unsafe(nil), Integer) + +# This is the start range of LSP reserved error codes. +# It doesn't denote a real error code. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#35 +LanguageServer::Protocol::Constant::ErrorCodes::LSP_RESERVED_ERROR_RANGE_START = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#7 +LanguageServer::Protocol::Constant::ErrorCodes::METHOD_NOT_FOUND = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#5 +LanguageServer::Protocol::Constant::ErrorCodes::PARSE_ERROR = T.let(T.unsafe(nil), Integer) + +# The client has canceled a request and a server as detected +# the cancel. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#64 +LanguageServer::Protocol::Constant::ErrorCodes::REQUEST_CANCELLED = T.let(T.unsafe(nil), Integer) + +# A request failed but it was syntactically correct, e.g the +# method name was known and the parameters were valid. The error +# message should contain human readable information about why +# the request failed. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#42 +LanguageServer::Protocol::Constant::ErrorCodes::REQUEST_FAILED = T.let(T.unsafe(nil), Integer) + +# The server cancelled the request. This error code should +# only be used for requests that explicitly support being +# server cancellable. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#48 +LanguageServer::Protocol::Constant::ErrorCodes::SERVER_CANCELLED = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#30 +LanguageServer::Protocol::Constant::ErrorCodes::SERVER_ERROR_END = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#18 +LanguageServer::Protocol::Constant::ErrorCodes::SERVER_ERROR_START = T.let(T.unsafe(nil), Integer) + +# Error code indicating that a server received a notification or +# request before the server has received the `initialize` request. +# +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#23 +LanguageServer::Protocol::Constant::ErrorCodes::SERVER_NOT_INITIALIZED = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/error_codes.rb#24 +LanguageServer::Protocol::Constant::ErrorCodes::UNKNOWN_ERROR_CODE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/failure_handling_kind.rb#4 +module LanguageServer::Protocol::Constant::FailureHandlingKind; end + +# Applying the workspace change is simply aborted if one of the changes +# provided fails. All operations executed before the failing operation +# stay executed. +# +# source://language_server-protocol//lib/language_server/protocol/constant/failure_handling_kind.rb#10 +LanguageServer::Protocol::Constant::FailureHandlingKind::ABORT = T.let(T.unsafe(nil), String) + +# If the workspace edit contains only textual file changes they are +# executed transactional. If resource changes (create, rename or delete +# file) are part of the change the failure handling strategy is abort. +# +# source://language_server-protocol//lib/language_server/protocol/constant/failure_handling_kind.rb#21 +LanguageServer::Protocol::Constant::FailureHandlingKind::TEXT_ONLY_TRANSACTIONAL = T.let(T.unsafe(nil), String) + +# All operations are executed transactional. That means they either all +# succeed or no changes at all are applied to the workspace. +# +# source://language_server-protocol//lib/language_server/protocol/constant/failure_handling_kind.rb#15 +LanguageServer::Protocol::Constant::FailureHandlingKind::TRANSACTIONAL = T.let(T.unsafe(nil), String) + +# The client tries to undo the operations already executed. But there is no +# guarantee that this is succeeding. +# +# source://language_server-protocol//lib/language_server/protocol/constant/failure_handling_kind.rb#26 +LanguageServer::Protocol::Constant::FailureHandlingKind::UNDO = T.let(T.unsafe(nil), String) + +# The file event type. +# +# source://language_server-protocol//lib/language_server/protocol/constant/file_change_type.rb#7 +module LanguageServer::Protocol::Constant::FileChangeType; end + +# The file got changed. +# +# source://language_server-protocol//lib/language_server/protocol/constant/file_change_type.rb#15 +LanguageServer::Protocol::Constant::FileChangeType::CHANGED = T.let(T.unsafe(nil), Integer) + +# The file got created. +# +# source://language_server-protocol//lib/language_server/protocol/constant/file_change_type.rb#11 +LanguageServer::Protocol::Constant::FileChangeType::CREATED = T.let(T.unsafe(nil), Integer) + +# The file got deleted. +# +# source://language_server-protocol//lib/language_server/protocol/constant/file_change_type.rb#19 +LanguageServer::Protocol::Constant::FileChangeType::DELETED = T.let(T.unsafe(nil), Integer) + +# A pattern kind describing if a glob pattern matches a file a folder or +# both. +# +# source://language_server-protocol//lib/language_server/protocol/constant/file_operation_pattern_kind.rb#8 +module LanguageServer::Protocol::Constant::FileOperationPatternKind; end + +# The pattern matches a file only. +# +# source://language_server-protocol//lib/language_server/protocol/constant/file_operation_pattern_kind.rb#12 +LanguageServer::Protocol::Constant::FileOperationPatternKind::FILE = T.let(T.unsafe(nil), String) + +# The pattern matches a folder only. +# +# source://language_server-protocol//lib/language_server/protocol/constant/file_operation_pattern_kind.rb#16 +LanguageServer::Protocol::Constant::FileOperationPatternKind::FOLDER = T.let(T.unsafe(nil), String) + +# A set of predefined range kinds. +# The type is a string since the value set is extensible +# +# source://language_server-protocol//lib/language_server/protocol/constant/folding_range_kind.rb#8 +module LanguageServer::Protocol::Constant::FoldingRangeKind; end + +# Folding range for a comment +# +# source://language_server-protocol//lib/language_server/protocol/constant/folding_range_kind.rb#12 +LanguageServer::Protocol::Constant::FoldingRangeKind::COMMENT = T.let(T.unsafe(nil), String) + +# Folding range for imports or includes +# +# source://language_server-protocol//lib/language_server/protocol/constant/folding_range_kind.rb#16 +LanguageServer::Protocol::Constant::FoldingRangeKind::IMPORTS = T.let(T.unsafe(nil), String) + +# Folding range for a region (e.g. `#region`) +# +# source://language_server-protocol//lib/language_server/protocol/constant/folding_range_kind.rb#20 +LanguageServer::Protocol::Constant::FoldingRangeKind::REGION = T.let(T.unsafe(nil), String) + +# Known error codes for an `InitializeErrorCodes`; +# +# source://language_server-protocol//lib/language_server/protocol/constant/initialize_error_codes.rb#7 +module LanguageServer::Protocol::Constant::InitializeErrorCodes; end + +# If the protocol version provided by the client can't be handled by +# the server. +# +# source://language_server-protocol//lib/language_server/protocol/constant/initialize_error_codes.rb#12 +LanguageServer::Protocol::Constant::InitializeErrorCodes::UNKNOWN_PROTOCOL_VERSION = T.let(T.unsafe(nil), Integer) + +# Inlay hint kinds. +# +# source://language_server-protocol//lib/language_server/protocol/constant/inlay_hint_kind.rb#7 +module LanguageServer::Protocol::Constant::InlayHintKind; end + +# An inlay hint that is for a parameter. +# +# source://language_server-protocol//lib/language_server/protocol/constant/inlay_hint_kind.rb#15 +LanguageServer::Protocol::Constant::InlayHintKind::PARAMETER = T.let(T.unsafe(nil), Integer) + +# An inlay hint that for a type annotation. +# +# source://language_server-protocol//lib/language_server/protocol/constant/inlay_hint_kind.rb#11 +LanguageServer::Protocol::Constant::InlayHintKind::TYPE = T.let(T.unsafe(nil), Integer) + +# Defines whether the insert text in a completion item should be interpreted as +# plain text or a snippet. +# +# source://language_server-protocol//lib/language_server/protocol/constant/insert_text_format.rb#8 +module LanguageServer::Protocol::Constant::InsertTextFormat; end + +# The primary text to be inserted is treated as a plain string. +# +# source://language_server-protocol//lib/language_server/protocol/constant/insert_text_format.rb#12 +LanguageServer::Protocol::Constant::InsertTextFormat::PLAIN_TEXT = T.let(T.unsafe(nil), Integer) + +# The primary text to be inserted is treated as a snippet. +# +# A snippet can define tab stops and placeholders with `$1`, `$2` +# and `${3:foo}`. `$0` defines the final tab stop, it defaults to +# the end of the snippet. Placeholders with equal identifiers are linked, +# that is typing in one will update others too. +# +# source://language_server-protocol//lib/language_server/protocol/constant/insert_text_format.rb#21 +LanguageServer::Protocol::Constant::InsertTextFormat::SNIPPET = T.let(T.unsafe(nil), Integer) + +# How whitespace and indentation is handled during completion +# item insertion. +# +# source://language_server-protocol//lib/language_server/protocol/constant/insert_text_mode.rb#8 +module LanguageServer::Protocol::Constant::InsertTextMode; end + +# The editor adjusts leading whitespace of new lines so that +# they match the indentation up to the cursor of the line for +# which the item is accepted. +# +# Consider a line like this: <2tabs><3tabs>foo. Accepting a +# multi line completion item is indented using 2 tabs and all +# following lines inserted will be indented using 2 tabs as well. +# +# source://language_server-protocol//lib/language_server/protocol/constant/insert_text_mode.rb#26 +LanguageServer::Protocol::Constant::InsertTextMode::ADJUST_INDENTATION = T.let(T.unsafe(nil), Integer) + +# The insertion or replace strings is taken as it is. If the +# value is multi line the lines below the cursor will be +# inserted using the indentation defined in the string value. +# The client will not apply any kind of adjustments to the +# string. +# +# source://language_server-protocol//lib/language_server/protocol/constant/insert_text_mode.rb#16 +LanguageServer::Protocol::Constant::InsertTextMode::AS_IS = T.let(T.unsafe(nil), Integer) + +# Describes the content type that a client supports in various +# result literals like `Hover`, `ParameterInfo` or `CompletionItem`. +# +# Please note that `MarkupKinds` must not start with a `$`. This kinds +# are reserved for internal usage. +# +# source://language_server-protocol//lib/language_server/protocol/constant/markup_kind.rb#11 +module LanguageServer::Protocol::Constant::MarkupKind; end + +# Markdown is supported as a content format +# +# source://language_server-protocol//lib/language_server/protocol/constant/markup_kind.rb#19 +LanguageServer::Protocol::Constant::MarkupKind::MARKDOWN = T.let(T.unsafe(nil), String) + +# Plain text is supported as a content format +# +# source://language_server-protocol//lib/language_server/protocol/constant/markup_kind.rb#15 +LanguageServer::Protocol::Constant::MarkupKind::PLAIN_TEXT = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/message_type.rb#4 +module LanguageServer::Protocol::Constant::MessageType; end + +# An error message. +# +# source://language_server-protocol//lib/language_server/protocol/constant/message_type.rb#8 +LanguageServer::Protocol::Constant::MessageType::ERROR = T.let(T.unsafe(nil), Integer) + +# An information message. +# +# source://language_server-protocol//lib/language_server/protocol/constant/message_type.rb#16 +LanguageServer::Protocol::Constant::MessageType::INFO = T.let(T.unsafe(nil), Integer) + +# A log message. +# +# source://language_server-protocol//lib/language_server/protocol/constant/message_type.rb#20 +LanguageServer::Protocol::Constant::MessageType::LOG = T.let(T.unsafe(nil), Integer) + +# A warning message. +# +# source://language_server-protocol//lib/language_server/protocol/constant/message_type.rb#12 +LanguageServer::Protocol::Constant::MessageType::WARNING = T.let(T.unsafe(nil), Integer) + +# The moniker kind. +# +# source://language_server-protocol//lib/language_server/protocol/constant/moniker_kind.rb#7 +module LanguageServer::Protocol::Constant::MonikerKind; end + +# The moniker represents a symbol that is exported from a project +# +# source://language_server-protocol//lib/language_server/protocol/constant/moniker_kind.rb#15 +LanguageServer::Protocol::Constant::MonikerKind::EXPORT = T.let(T.unsafe(nil), String) + +# The moniker represent a symbol that is imported into a project +# +# source://language_server-protocol//lib/language_server/protocol/constant/moniker_kind.rb#11 +LanguageServer::Protocol::Constant::MonikerKind::IMPORT = T.let(T.unsafe(nil), String) + +# The moniker represents a symbol that is local to a project (e.g. a local +# variable of a function, a class not visible outside the project, ...) +# +# source://language_server-protocol//lib/language_server/protocol/constant/moniker_kind.rb#20 +LanguageServer::Protocol::Constant::MonikerKind::LOCAL = T.let(T.unsafe(nil), String) + +# A notebook cell kind. +# +# source://language_server-protocol//lib/language_server/protocol/constant/notebook_cell_kind.rb#7 +module LanguageServer::Protocol::Constant::NotebookCellKind; end + +# A code-cell is source code. +# +# source://language_server-protocol//lib/language_server/protocol/constant/notebook_cell_kind.rb#15 +LanguageServer::Protocol::Constant::NotebookCellKind::CODE = T.let(T.unsafe(nil), Integer) + +# A markup-cell is formatted source that is used for display. +# +# source://language_server-protocol//lib/language_server/protocol/constant/notebook_cell_kind.rb#11 +LanguageServer::Protocol::Constant::NotebookCellKind::MARKUP = T.let(T.unsafe(nil), Integer) + +# A type indicating how positions are encoded, +# specifically what column offsets mean. +# A set of predefined position encoding kinds. +# +# source://language_server-protocol//lib/language_server/protocol/constant/position_encoding_kind.rb#9 +module LanguageServer::Protocol::Constant::PositionEncodingKind; end + +# Character offsets count UTF-16 code units. +# +# This is the default and must always be supported +# by servers +# +# source://language_server-protocol//lib/language_server/protocol/constant/position_encoding_kind.rb#20 +LanguageServer::Protocol::Constant::PositionEncodingKind::UTF16 = T.let(T.unsafe(nil), String) + +# Character offsets count UTF-32 code units. +# +# Implementation note: these are the same as Unicode code points, +# so this `PositionEncodingKind` may also be used for an +# encoding-agnostic representation of character offsets. +# +# source://language_server-protocol//lib/language_server/protocol/constant/position_encoding_kind.rb#28 +LanguageServer::Protocol::Constant::PositionEncodingKind::UTF32 = T.let(T.unsafe(nil), String) + +# Character offsets count UTF-8 code units (e.g bytes). +# +# source://language_server-protocol//lib/language_server/protocol/constant/position_encoding_kind.rb#13 +LanguageServer::Protocol::Constant::PositionEncodingKind::UTF8 = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/prepare_support_default_behavior.rb#4 +module LanguageServer::Protocol::Constant::PrepareSupportDefaultBehavior; end + +# The client's default behavior is to select the identifier +# according to the language's syntax rule. +# +# source://language_server-protocol//lib/language_server/protocol/constant/prepare_support_default_behavior.rb#9 +LanguageServer::Protocol::Constant::PrepareSupportDefaultBehavior::IDENTIFIER = T.let(T.unsafe(nil), Integer) + +# The kind of resource operations supported by the client. +# +# source://language_server-protocol//lib/language_server/protocol/constant/resource_operation_kind.rb#7 +module LanguageServer::Protocol::Constant::ResourceOperationKind; end + +# Supports creating new files and folders. +# +# source://language_server-protocol//lib/language_server/protocol/constant/resource_operation_kind.rb#11 +LanguageServer::Protocol::Constant::ResourceOperationKind::CREATE = T.let(T.unsafe(nil), String) + +# Supports deleting existing files and folders. +# +# source://language_server-protocol//lib/language_server/protocol/constant/resource_operation_kind.rb#19 +LanguageServer::Protocol::Constant::ResourceOperationKind::DELETE = T.let(T.unsafe(nil), String) + +# Supports renaming existing files and folders. +# +# source://language_server-protocol//lib/language_server/protocol/constant/resource_operation_kind.rb#15 +LanguageServer::Protocol::Constant::ResourceOperationKind::RENAME = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#4 +module LanguageServer::Protocol::Constant::SemanticTokenModifiers; end + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#10 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::ABSTRACT = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#11 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::ASYNC = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#5 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::DECLARATION = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#14 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::DEFAULT_LIBRARY = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#6 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::DEFINITION = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#9 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::DEPRECATED = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#13 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::DOCUMENTATION = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#12 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::MODIFICATION = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#7 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::READONLY = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_modifiers.rb#8 +LanguageServer::Protocol::Constant::SemanticTokenModifiers::STATIC = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#4 +module LanguageServer::Protocol::Constant::SemanticTokenTypes; end + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#11 +LanguageServer::Protocol::Constant::SemanticTokenTypes::CLASS = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#26 +LanguageServer::Protocol::Constant::SemanticTokenTypes::COMMENT = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#31 +LanguageServer::Protocol::Constant::SemanticTokenTypes::DECORATOR = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#12 +LanguageServer::Protocol::Constant::SemanticTokenTypes::ENUM = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#19 +LanguageServer::Protocol::Constant::SemanticTokenTypes::ENUM_MEMBER = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#20 +LanguageServer::Protocol::Constant::SemanticTokenTypes::EVENT = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#21 +LanguageServer::Protocol::Constant::SemanticTokenTypes::FUNCTION = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#13 +LanguageServer::Protocol::Constant::SemanticTokenTypes::INTERFACE = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#24 +LanguageServer::Protocol::Constant::SemanticTokenTypes::KEYWORD = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#23 +LanguageServer::Protocol::Constant::SemanticTokenTypes::MACRO = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#22 +LanguageServer::Protocol::Constant::SemanticTokenTypes::METHOD = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#25 +LanguageServer::Protocol::Constant::SemanticTokenTypes::MODIFIER = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#5 +LanguageServer::Protocol::Constant::SemanticTokenTypes::NAMESPACE = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#28 +LanguageServer::Protocol::Constant::SemanticTokenTypes::NUMBER = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#30 +LanguageServer::Protocol::Constant::SemanticTokenTypes::OPERATOR = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#16 +LanguageServer::Protocol::Constant::SemanticTokenTypes::PARAMETER = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#18 +LanguageServer::Protocol::Constant::SemanticTokenTypes::PROPERTY = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#29 +LanguageServer::Protocol::Constant::SemanticTokenTypes::REGEXP = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#27 +LanguageServer::Protocol::Constant::SemanticTokenTypes::STRING = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#14 +LanguageServer::Protocol::Constant::SemanticTokenTypes::STRUCT = T.let(T.unsafe(nil), String) + +# Represents a generic type. Acts as a fallback for types which +# can't be mapped to a specific type like class or enum. +# +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#10 +LanguageServer::Protocol::Constant::SemanticTokenTypes::TYPE = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#15 +LanguageServer::Protocol::Constant::SemanticTokenTypes::TYPE_PARAMETER = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/semantic_token_types.rb#17 +LanguageServer::Protocol::Constant::SemanticTokenTypes::VARIABLE = T.let(T.unsafe(nil), String) + +# How a signature help was triggered. +# +# source://language_server-protocol//lib/language_server/protocol/constant/signature_help_trigger_kind.rb#7 +module LanguageServer::Protocol::Constant::SignatureHelpTriggerKind; end + +# Signature help was triggered by the cursor moving or by the document +# content changing. +# +# source://language_server-protocol//lib/language_server/protocol/constant/signature_help_trigger_kind.rb#20 +LanguageServer::Protocol::Constant::SignatureHelpTriggerKind::CONTENT_CHANGE = T.let(T.unsafe(nil), Integer) + +# Signature help was invoked manually by the user or by a command. +# +# source://language_server-protocol//lib/language_server/protocol/constant/signature_help_trigger_kind.rb#11 +LanguageServer::Protocol::Constant::SignatureHelpTriggerKind::INVOKED = T.let(T.unsafe(nil), Integer) + +# Signature help was triggered by a trigger character. +# +# source://language_server-protocol//lib/language_server/protocol/constant/signature_help_trigger_kind.rb#15 +LanguageServer::Protocol::Constant::SignatureHelpTriggerKind::TRIGGER_CHARACTER = T.let(T.unsafe(nil), Integer) + +# A symbol kind. +# +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#7 +module LanguageServer::Protocol::Constant::SymbolKind; end + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#25 +LanguageServer::Protocol::Constant::SymbolKind::ARRAY = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#24 +LanguageServer::Protocol::Constant::SymbolKind::BOOLEAN = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#12 +LanguageServer::Protocol::Constant::SymbolKind::CLASS = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#21 +LanguageServer::Protocol::Constant::SymbolKind::CONSTANT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#16 +LanguageServer::Protocol::Constant::SymbolKind::CONSTRUCTOR = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#17 +LanguageServer::Protocol::Constant::SymbolKind::ENUM = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#29 +LanguageServer::Protocol::Constant::SymbolKind::ENUM_MEMBER = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#31 +LanguageServer::Protocol::Constant::SymbolKind::EVENT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#15 +LanguageServer::Protocol::Constant::SymbolKind::FIELD = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#8 +LanguageServer::Protocol::Constant::SymbolKind::FILE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#19 +LanguageServer::Protocol::Constant::SymbolKind::FUNCTION = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#18 +LanguageServer::Protocol::Constant::SymbolKind::INTERFACE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#27 +LanguageServer::Protocol::Constant::SymbolKind::KEY = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#13 +LanguageServer::Protocol::Constant::SymbolKind::METHOD = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#9 +LanguageServer::Protocol::Constant::SymbolKind::MODULE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#10 +LanguageServer::Protocol::Constant::SymbolKind::NAMESPACE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#28 +LanguageServer::Protocol::Constant::SymbolKind::NULL = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#23 +LanguageServer::Protocol::Constant::SymbolKind::NUMBER = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#26 +LanguageServer::Protocol::Constant::SymbolKind::OBJECT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#32 +LanguageServer::Protocol::Constant::SymbolKind::OPERATOR = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#11 +LanguageServer::Protocol::Constant::SymbolKind::PACKAGE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#14 +LanguageServer::Protocol::Constant::SymbolKind::PROPERTY = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#22 +LanguageServer::Protocol::Constant::SymbolKind::STRING = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#30 +LanguageServer::Protocol::Constant::SymbolKind::STRUCT = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#33 +LanguageServer::Protocol::Constant::SymbolKind::TYPE_PARAMETER = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_kind.rb#20 +LanguageServer::Protocol::Constant::SymbolKind::VARIABLE = T.let(T.unsafe(nil), Integer) + +# Symbol tags are extra annotations that tweak the rendering of a symbol. +# +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_tag.rb#7 +module LanguageServer::Protocol::Constant::SymbolTag; end + +# Render a symbol as obsolete, usually using a strike-out. +# +# source://language_server-protocol//lib/language_server/protocol/constant/symbol_tag.rb#11 +LanguageServer::Protocol::Constant::SymbolTag::DEPRECATED = T.let(T.unsafe(nil), Integer) + +# Represents reasons why a text document is saved. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_save_reason.rb#7 +module LanguageServer::Protocol::Constant::TextDocumentSaveReason; end + +# Automatic after a delay. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_save_reason.rb#16 +LanguageServer::Protocol::Constant::TextDocumentSaveReason::AFTER_DELAY = T.let(T.unsafe(nil), Integer) + +# When the editor lost focus. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_save_reason.rb#20 +LanguageServer::Protocol::Constant::TextDocumentSaveReason::FOCUS_OUT = T.let(T.unsafe(nil), Integer) + +# Manually triggered, e.g. by the user pressing save, by starting +# debugging, or by an API call. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_save_reason.rb#12 +LanguageServer::Protocol::Constant::TextDocumentSaveReason::MANUAL = T.let(T.unsafe(nil), Integer) + +# Defines how the host (editor) should sync document changes to the language +# server. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_sync_kind.rb#8 +module LanguageServer::Protocol::Constant::TextDocumentSyncKind; end + +# Documents are synced by always sending the full content +# of the document. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_sync_kind.rb#17 +LanguageServer::Protocol::Constant::TextDocumentSyncKind::FULL = T.let(T.unsafe(nil), Integer) + +# Documents are synced by sending the full content on open. +# After that only incremental updates to the document are +# sent. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_sync_kind.rb#23 +LanguageServer::Protocol::Constant::TextDocumentSyncKind::INCREMENTAL = T.let(T.unsafe(nil), Integer) + +# Documents should not be synced at all. +# +# source://language_server-protocol//lib/language_server/protocol/constant/text_document_sync_kind.rb#12 +LanguageServer::Protocol::Constant::TextDocumentSyncKind::NONE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/constant/token_format.rb#4 +module LanguageServer::Protocol::Constant::TokenFormat; end + +# source://language_server-protocol//lib/language_server/protocol/constant/token_format.rb#5 +LanguageServer::Protocol::Constant::TokenFormat::RELATIVE = T.let(T.unsafe(nil), String) + +# Moniker uniqueness level to define scope of the moniker. +# +# source://language_server-protocol//lib/language_server/protocol/constant/uniqueness_level.rb#7 +module LanguageServer::Protocol::Constant::UniquenessLevel; end + +# The moniker is only unique inside a document +# +# source://language_server-protocol//lib/language_server/protocol/constant/uniqueness_level.rb#11 +LanguageServer::Protocol::Constant::UniquenessLevel::DOCUMENT = T.let(T.unsafe(nil), String) + +# The moniker is globally unique +# +# source://language_server-protocol//lib/language_server/protocol/constant/uniqueness_level.rb#27 +LanguageServer::Protocol::Constant::UniquenessLevel::GLOBAL = T.let(T.unsafe(nil), String) + +# The moniker is unique inside the group to which a project belongs +# +# source://language_server-protocol//lib/language_server/protocol/constant/uniqueness_level.rb#19 +LanguageServer::Protocol::Constant::UniquenessLevel::GROUP = T.let(T.unsafe(nil), String) + +# The moniker is unique inside a project for which a dump got created +# +# source://language_server-protocol//lib/language_server/protocol/constant/uniqueness_level.rb#15 +LanguageServer::Protocol::Constant::UniquenessLevel::PROJECT = T.let(T.unsafe(nil), String) + +# The moniker is unique inside the moniker scheme. +# +# source://language_server-protocol//lib/language_server/protocol/constant/uniqueness_level.rb#23 +LanguageServer::Protocol::Constant::UniquenessLevel::SCHEME = T.let(T.unsafe(nil), String) + +# source://language_server-protocol//lib/language_server/protocol/constant/watch_kind.rb#4 +module LanguageServer::Protocol::Constant::WatchKind; end + +# Interested in change events +# +# source://language_server-protocol//lib/language_server/protocol/constant/watch_kind.rb#12 +LanguageServer::Protocol::Constant::WatchKind::CHANGE = T.let(T.unsafe(nil), Integer) + +# Interested in create events. +# +# source://language_server-protocol//lib/language_server/protocol/constant/watch_kind.rb#8 +LanguageServer::Protocol::Constant::WatchKind::CREATE = T.let(T.unsafe(nil), Integer) + +# Interested in delete events +# +# source://language_server-protocol//lib/language_server/protocol/constant/watch_kind.rb#16 +LanguageServer::Protocol::Constant::WatchKind::DELETE = T.let(T.unsafe(nil), Integer) + +# source://language_server-protocol//lib/language_server/protocol/interface.rb#3 +module LanguageServer::Protocol::Interface; end + +# A special text edit with an additional change annotation. +# +# source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#7 +class LanguageServer::Protocol::Interface::AnnotatedTextEdit + # @return [AnnotatedTextEdit] a new instance of AnnotatedTextEdit + # + # source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#8 + def initialize(range:, new_text:, annotation_id:); end + + # The actual annotation identifier. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#40 + def annotation_id; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#44 + def attributes; end + + # The string to be inserted. For delete operations use an + # empty string. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#32 + def new_text; end + + # The range of the text document to be manipulated. To insert + # text into a document create a range where start === end. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#23 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/annotated_text_edit.rb#50 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_params.rb#4 +class LanguageServer::Protocol::Interface::ApplyWorkspaceEditParams + # @return [ApplyWorkspaceEditParams] a new instance of ApplyWorkspaceEditParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_params.rb#5 + def initialize(edit:, label: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_params.rb#32 + def attributes; end + + # The edits to apply. + # + # @return [WorkspaceEdit] + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_params.rb#28 + def edit; end + + # An optional label of the workspace edit. This label is + # presented in the user interface for example on an undo + # stack to undo the workspace edit. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_params.rb#20 + def label; end + + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_params.rb#34 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_params.rb#38 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#4 +class LanguageServer::Protocol::Interface::ApplyWorkspaceEditResult + # @return [ApplyWorkspaceEditResult] a new instance of ApplyWorkspaceEditResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#5 + def initialize(applied:, failure_reason: T.unsafe(nil), failed_change: T.unsafe(nil)); end + + # Indicates whether the edit was applied or not. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#19 + def applied; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#44 + def attributes; end + + # Depending on the client's failure handling strategy `failedChange` + # might contain the index of the change that failed. This property is + # only available if the client signals a `failureHandling` strategy + # in its client capabilities. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#40 + def failed_change; end + + # An optional textual description for why the edit was not applied. + # This may be used by the server for diagnostic logging or to provide + # a suitable error for a request that triggered the edit. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#29 + def failure_reason; end + + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/apply_workspace_edit_result.rb#50 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyClientCapabilities + # @return [CallHierarchyClientCapabilities] a new instance of CallHierarchyClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_client_capabilities.rb#24 + def attributes; end + + # Whether implementation supports dynamic registration. If this is set to + # `true` the client supports the new `(TextDocumentRegistrationOptions & + # StaticRegistrationOptions)` return value for the corresponding server + # capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_client_capabilities.rb#20 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_client_capabilities.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_client_capabilities.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyIncomingCall + # @return [CallHierarchyIncomingCall] a new instance of CallHierarchyIncomingCall + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb#5 + def initialize(from:, from_ranges:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb#31 + def attributes; end + + # The item that makes the call. + # + # @return [CallHierarchyItem] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb#18 + def from; end + + # The ranges at which the calls appear. This is relative to the caller + # denoted by [`this.from`](#CallHierarchyIncomingCall.from). + # + # @return [Range[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb#27 + def from_ranges; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_call.rb#37 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyIncomingCallsParams + # @return [CallHierarchyIncomingCallsParams] a new instance of CallHierarchyIncomingCallsParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#5 + def initialize(item:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#37 + def attributes; end + + # @return [CallHierarchyItem] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#33 + def item; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#28 + def partial_result_token; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#43 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_incoming_calls_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyItem + # @return [CallHierarchyItem] a new instance of CallHierarchyItem + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#5 + def initialize(name:, kind:, uri:, range:, selection_range:, tags: T.unsafe(nil), detail: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#88 + def attributes; end + + # A data entry field that is preserved between a call hierarchy prepare and + # incoming calls or outgoing calls requests. + # + # @return [unknown] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#84 + def data; end + + # More detail for this item, e.g. the signature of a function. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#48 + def detail; end + + # The kind of this item. + # + # @return [SymbolKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#32 + def kind; end + + # The name of this item. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#24 + def name; end + + # The range enclosing this symbol not including leading/trailing whitespace + # but everything else, e.g. comments and code. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#65 + def range; end + + # The range that should be selected and revealed when this symbol is being + # picked, e.g. the name of a function. Must be contained by the + # [`range`](#CallHierarchyItem.range). + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#75 + def selection_range; end + + # Tags for this item. + # + # @return [1[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#40 + def tags; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#90 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#94 + def to_json(*args); end + + # The resource identifier of this item. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_item.rb#56 + def uri; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_options.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyOptions + # @return [CallHierarchyOptions] a new instance of CallHierarchyOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyOutgoingCall + # @return [CallHierarchyOutgoingCall] a new instance of CallHierarchyOutgoingCall + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb#5 + def initialize(to:, from_ranges:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb#31 + def attributes; end + + # The range at which this item is called. This is the range relative to + # the caller, e.g the item passed to `callHierarchy/outgoingCalls` request. + # + # @return [Range[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb#27 + def from_ranges; end + + # The item that is called. + # + # @return [CallHierarchyItem] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb#18 + def to; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_call.rb#37 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyOutgoingCallsParams + # @return [CallHierarchyOutgoingCallsParams] a new instance of CallHierarchyOutgoingCallsParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#5 + def initialize(item:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#37 + def attributes; end + + # @return [CallHierarchyItem] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#33 + def item; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#28 + def partial_result_token; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#43 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_outgoing_calls_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyPrepareParams + # @return [CallHierarchyPrepareParams] a new instance of CallHierarchyPrepareParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#39 + def attributes; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#27 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#19 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#45 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_prepare_params.rb#35 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#4 +class LanguageServer::Protocol::Interface::CallHierarchyRegistrationOptions + # @return [CallHierarchyRegistrationOptions] a new instance of CallHierarchyRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#20 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/call_hierarchy_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/cancel_params.rb#4 +class LanguageServer::Protocol::Interface::CancelParams + # @return [CancelParams] a new instance of CancelParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/cancel_params.rb#5 + def initialize(id:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/cancel_params.rb#21 + def attributes; end + + # The request id to cancel. + # + # @return [string | number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/cancel_params.rb#17 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/cancel_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/cancel_params.rb#27 + def to_json(*args); end +end + +# Additional information that describes document changes. +# +# source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#7 +class LanguageServer::Protocol::Interface::ChangeAnnotation + # @return [ChangeAnnotation] a new instance of ChangeAnnotation + # + # source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#8 + def initialize(label:, needs_confirmation: T.unsafe(nil), description: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#45 + def attributes; end + + # A human-readable string which is rendered less prominent in + # the user interface. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#41 + def description; end + + # A human-readable string describing the actual change. The string + # is rendered prominent in the user interface. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#23 + def label; end + + # A flag which indicates that user confirmation is needed + # before applying the change. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#32 + def needs_confirmation; end + + # source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#47 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/change_annotation.rb#51 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::ClientCapabilities + # @return [ClientCapabilities] a new instance of ClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#5 + def initialize(workspace: T.unsafe(nil), text_document: T.unsafe(nil), notebook_document: T.unsafe(nil), window: T.unsafe(nil), general: T.unsafe(nil), experimental: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#66 + def attributes; end + + # Experimental client capabilities. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#62 + def experimental; end + + # General client capabilities. + # + # @return [{ staleRequestSupport?: { cancel: boolean; retryOnContentModified: string[]; }; regularExpressions?: RegularExpressionsClientCapabilities; markdown?: any; positionEncodings?: string[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#54 + def general; end + + # Capabilities specific to the notebook document support. + # + # @return [NotebookDocumentClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#38 + def notebook_document; end + + # Text document specific client capabilities. + # + # @return [TextDocumentClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#30 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#68 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#72 + def to_json(*args); end + + # Window specific client capabilities. + # + # @return [{ workDoneProgress?: boolean; showMessage?: ShowMessageRequestClientCapabilities; showDocument?: ShowDocumentClientCapabilities; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#46 + def window; end + + # Workspace specific client capabilities. + # + # @return [{ applyEdit?: boolean; workspaceEdit?: WorkspaceEditClientCapabilities; didChangeConfiguration?: DidChangeConfigurationClientCapabilities; ... 10 more ...; diagnostics?: DiagnosticWorkspaceClientCapabilities; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/client_capabilities.rb#22 + def workspace; end +end + +# A code action represents a change that can be performed in code, e.g. to fix +# a problem or to refactor code. +# +# A CodeAction must set either `edit` and/or a `command`. If both are supplied, +# the `edit` is applied first, then the `command` is executed. +# +# source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#11 +class LanguageServer::Protocol::Interface::CodeAction + # @return [CodeAction] a new instance of CodeAction + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#12 + def initialize(title:, kind: T.unsafe(nil), diagnostics: T.unsafe(nil), is_preferred: T.unsafe(nil), disabled: T.unsafe(nil), edit: T.unsafe(nil), command: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#115 + def attributes; end + + # A command this code action executes. If a code action + # provides an edit and a command, first the edit is + # executed and then the command. + # + # @return [Command] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#102 + def command; end + + # A data entry field that is preserved on a code action between + # a `textDocument/codeAction` and a `codeAction/resolve` request. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#111 + def data; end + + # The diagnostics that this code action resolves. + # + # @return [Diagnostic[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#49 + def diagnostics; end + + # Marks that the code action cannot currently be applied. + # + # Clients should follow the following guidelines regarding disabled code + # actions: + # + # - Disabled code actions are not shown in automatic lightbulbs code + # action menus. + # + # - Disabled actions are shown as faded out in the code action menu when + # the user request a more specific type of code action, such as + # refactorings. + # + # - If the user has a keybinding that auto applies a code action and only + # a disabled code actions are returned, the client should show the user + # an error message with `reason` in the editor. + # + # @return [{ reason: string; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#84 + def disabled; end + + # The workspace edit this code action performs. + # + # @return [WorkspaceEdit] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#92 + def edit; end + + # Marks this as a preferred action. Preferred actions are used by the + # `auto fix` command and can be targeted by keybindings. + # + # A quick fix should be marked preferred if it properly addresses the + # underlying error. A refactoring should be marked preferred if it is the + # most reasonable choice of actions to take. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#62 + def is_preferred; end + + # The kind of the code action. + # + # Used to filter code actions. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#41 + def kind; end + + # A short, human-readable, title for this code action. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#31 + def title; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#117 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action.rb#121 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::CodeActionClientCapabilities + # @return [CodeActionClientCapabilities] a new instance of CodeActionClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), code_action_literal_support: T.unsafe(nil), is_preferred_support: T.unsafe(nil), disabled_support: T.unsafe(nil), data_support: T.unsafe(nil), resolve_support: T.unsafe(nil), honors_change_annotations: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#83 + def attributes; end + + # The client supports code action literals as a valid + # response of the `textDocument/codeAction` request. + # + # @return [{ codeActionKind: { valueSet: string[]; }; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#32 + def code_action_literal_support; end + + # Whether code action supports the `data` property which is + # preserved between a `textDocument/codeAction` and a + # `codeAction/resolve` request. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#58 + def data_support; end + + # Whether code action supports the `disabled` property. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#48 + def disabled_support; end + + # Whether code action supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#23 + def dynamic_registration; end + + # Whether the client honors the change annotations in + # text edits and resource operations returned via the + # `CodeAction#edit` property by for example presenting + # the workspace edit in the user interface and asking + # for confirmation. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#79 + def honors_change_annotations; end + + # Whether code action supports the `isPreferred` property. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#40 + def is_preferred_support; end + + # Whether the client supports resolving additional code action + # properties via a separate `codeAction/resolve` request. + # + # @return [{ properties: string[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#67 + def resolve_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#85 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_client_capabilities.rb#89 + def to_json(*args); end +end + +# Contains additional diagnostic information about the context in which +# a code action is run. +# +# source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#8 +class LanguageServer::Protocol::Interface::CodeActionContext + # @return [CodeActionContext] a new instance of CodeActionContext + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#9 + def initialize(diagnostics:, only: T.unsafe(nil), trigger_kind: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#51 + def attributes; end + + # An array of diagnostics known on the client side overlapping the range + # provided to the `textDocument/codeAction` request. They are provided so + # that the server knows which errors are currently presented to the user + # for the given range. There is no guarantee that these accurately reflect + # the error state of the resource. The primary parameter + # to compute code actions is the provided range. + # + # @return [Diagnostic[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#28 + def diagnostics; end + + # Requested kind of actions to return. + # + # Actions not of this kind are filtered out by the client before being + # shown. So servers can omit computing them. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#39 + def only; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#53 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#57 + def to_json(*args); end + + # The reason why code actions were requested. + # + # @return [CodeActionTriggerKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_context.rb#47 + def trigger_kind; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#4 +class LanguageServer::Protocol::Interface::CodeActionOptions + # @return [CodeActionOptions] a new instance of CodeActionOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), code_action_kinds: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#40 + def attributes; end + + # CodeActionKinds that this server may return. + # + # The list of kinds may be generic, such as `CodeActionKind.Refactor`, + # or the server may list out every specific kind they provide. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#27 + def code_action_kinds; end + + # The server provides support to resolve additional + # information for a code action. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#36 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#46 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_options.rb#16 + def work_done_progress; end +end + +# Params for the CodeActionRequest +# +# source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#7 +class LanguageServer::Protocol::Interface::CodeActionParams + # @return [CodeActionParams] a new instance of CodeActionParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#8 + def initialize(text_document:, range:, context:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#61 + def attributes; end + + # Context carrying additional information. + # + # @return [CodeActionContext] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#57 + def context; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#33 + def partial_result_token; end + + # The range for which the command was invoked. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#49 + def range; end + + # The document in which the command was invoked. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#41 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#63 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#67 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_params.rb#24 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#4 +class LanguageServer::Protocol::Interface::CodeActionRegistrationOptions + # @return [CodeActionRegistrationOptions] a new instance of CodeActionRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), code_action_kinds: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#50 + def attributes; end + + # CodeActionKinds that this server may return. + # + # The list of kinds may be generic, such as `CodeActionKind.Refactor`, + # or the server may list out every specific kind they provide. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#37 + def code_action_kinds; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#21 + def document_selector; end + + # The server provides support to resolve additional + # information for a code action. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#46 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#52 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#56 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_action_registration_options.rb#26 + def work_done_progress; end +end + +# Structure to capture a description for an error code. +# +# source://language_server-protocol//lib/language_server/protocol/interface/code_description.rb#7 +class LanguageServer::Protocol::Interface::CodeDescription + # @return [CodeDescription] a new instance of CodeDescription + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_description.rb#8 + def initialize(href:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_description.rb#24 + def attributes; end + + # An URI to open with more information about the diagnostic error. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_description.rb#20 + def href; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_description.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_description.rb#30 + def to_json(*args); end +end + +# A code lens represents a command that should be shown along with +# source text, like the number of references, a way to run tests, etc. +# +# A code lens is _unresolved_ when no command is associated to it. For +# performance reasons the creation of a code lens and resolving should be done +# in two stages. +# +# source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#12 +class LanguageServer::Protocol::Interface::CodeLens + # @return [CodeLens] a new instance of CodeLens + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#13 + def initialize(range:, command: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#49 + def attributes; end + + # The command this code lens represents. + # + # @return [Command] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#36 + def command; end + + # A data entry field that is preserved on a code lens item between + # a code lens and a code lens resolve request. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#45 + def data; end + + # The range in which this code lens is valid. Should only span a single + # line. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#28 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens.rb#55 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_lens_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::CodeLensClientCapabilities + # @return [CodeLensClientCapabilities] a new instance of CodeLensClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_client_capabilities.rb#21 + def attributes; end + + # Whether code lens supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_lens_options.rb#4 +class LanguageServer::Protocol::Interface::CodeLensOptions + # @return [CodeLensOptions] a new instance of CodeLensOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_options.rb#27 + def attributes; end + + # Code lens has a resolve provider as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_options.rb#23 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_options.rb#29 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_options.rb#33 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_options.rb#15 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#4 +class LanguageServer::Protocol::Interface::CodeLensParams + # @return [CodeLensParams] a new instance of CodeLensParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#5 + def initialize(text_document:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#40 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#28 + def partial_result_token; end + + # The document to request code lens for. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#36 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#46 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#4 +class LanguageServer::Protocol::Interface::CodeLensRegistrationOptions + # @return [CodeLensRegistrationOptions] a new instance of CodeLensRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#37 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#20 + def document_selector; end + + # Code lens has a resolve provider as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#33 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#43 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/code_lens_workspace_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::CodeLensWorkspaceClientCapabilities + # @return [CodeLensWorkspaceClientCapabilities] a new instance of CodeLensWorkspaceClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_workspace_client_capabilities.rb#5 + def initialize(refresh_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_workspace_client_capabilities.rb#27 + def attributes; end + + # Whether the client implementation supports a refresh request sent from the + # server to the client. + # + # Note that this event is global and will force the client to refresh all + # code lenses currently shown. It should be used with absolute care and is + # useful for situation where a server for example detect a project wide + # change that requires such a calculation. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_workspace_client_capabilities.rb#23 + def refresh_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_workspace_client_capabilities.rb#29 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/code_lens_workspace_client_capabilities.rb#33 + def to_json(*args); end +end + +# Represents a color in RGBA space. +# +# source://language_server-protocol//lib/language_server/protocol/interface/color.rb#7 +class LanguageServer::Protocol::Interface::Color + # @return [Color] a new instance of Color + # + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#8 + def initialize(red:, green:, blue:, alpha:); end + + # The alpha component of this color in the range [0-1]. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#47 + def alpha; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#51 + def attributes; end + + # The blue component of this color in the range [0-1]. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#39 + def blue; end + + # The green component of this color in the range [0-1]. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#31 + def green; end + + # The red component of this color in the range [0-1]. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#23 + def red; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#53 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color.rb#57 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/color_information.rb#4 +class LanguageServer::Protocol::Interface::ColorInformation + # @return [ColorInformation] a new instance of ColorInformation + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_information.rb#5 + def initialize(range:, color:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_information.rb#30 + def attributes; end + + # The actual color value for this color range. + # + # @return [Color] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_information.rb#26 + def color; end + + # The range in the document where this color appears. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_information.rb#18 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color_information.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color_information.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#4 +class LanguageServer::Protocol::Interface::ColorPresentation + # @return [ColorPresentation] a new instance of ColorPresentation + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#5 + def initialize(label:, text_edit: T.unsafe(nil), additional_text_edits: T.unsafe(nil)); end + + # An optional array of additional [text edits](#TextEdit) that are applied + # when selecting this color presentation. Edits must not overlap with the + # main [edit](#ColorPresentation.textEdit) nor with themselves. + # + # @return [TextEdit[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#41 + def additional_text_edits; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#45 + def attributes; end + + # The label of this color presentation. It will be shown on the color + # picker header. By default this is also the text that is inserted when + # selecting this color presentation. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#21 + def label; end + + # An [edit](#TextEdit) which is applied to a document when selecting + # this presentation for the color. When `falsy` the + # [label](#ColorPresentation.label) is used. + # + # @return [TextEdit] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#31 + def text_edit; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#47 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation.rb#51 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#4 +class LanguageServer::Protocol::Interface::ColorPresentationParams + # @return [ColorPresentationParams] a new instance of ColorPresentationParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#5 + def initialize(text_document:, color:, range:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#58 + def attributes; end + + # The color information to request presentations for. + # + # @return [Color] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#46 + def color; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#30 + def partial_result_token; end + + # The range where the color would be inserted. Serves as a context. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#54 + def range; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#38 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#60 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#64 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/color_presentation_params.rb#21 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/command.rb#4 +class LanguageServer::Protocol::Interface::Command + # @return [Command] a new instance of Command + # + # source://language_server-protocol//lib/language_server/protocol/interface/command.rb#5 + def initialize(title:, command:, arguments: T.unsafe(nil)); end + + # Arguments that the command handler should be + # invoked with. + # + # @return [LSPAny[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/command.rb#36 + def arguments; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/command.rb#40 + def attributes; end + + # The identifier of the actual command handler. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/command.rb#27 + def command; end + + # Title of the command, like `save`. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/command.rb#19 + def title; end + + # source://language_server-protocol//lib/language_server/protocol/interface/command.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/command.rb#46 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::CompletionClientCapabilities + # @return [CompletionClientCapabilities] a new instance of CompletionClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), completion_item: T.unsafe(nil), completion_item_kind: T.unsafe(nil), context_support: T.unsafe(nil), insert_text_mode: T.unsafe(nil), completion_list: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#67 + def attributes; end + + # The client supports the following `CompletionItem` specific + # capabilities. + # + # @return [{ snippetSupport?: boolean; commitCharactersSupport?: boolean; documentationFormat?: MarkupKind[]; deprecatedSupport?: boolean; preselectSupport?: boolean; tagSupport?: { valueSet: 1[]; }; insertReplaceSupport?: boolean; resolveSupport?: { ...; }; insertTextModeSupport?: { ...; }; labelDetailsSupport?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#31 + def completion_item; end + + # @return [{ valueSet?: CompletionItemKind[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#36 + def completion_item_kind; end + + # The client supports the following `CompletionList` specific + # capabilities. + # + # @return [{ itemDefaults?: string[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#63 + def completion_list; end + + # The client supports to send additional context information for a + # `textDocument/completion` request. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#45 + def context_support; end + + # Whether completion supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#22 + def dynamic_registration; end + + # The client's default when the completion item doesn't provide a + # `insertTextMode` property. + # + # @return [InsertTextMode] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#54 + def insert_text_mode; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#69 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_client_capabilities.rb#73 + def to_json(*args); end +end + +# Contains additional information about the context in which a completion +# request is triggered. +# +# source://language_server-protocol//lib/language_server/protocol/interface/completion_context.rb#8 +class LanguageServer::Protocol::Interface::CompletionContext + # @return [CompletionContext] a new instance of CompletionContext + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_context.rb#9 + def initialize(trigger_kind:, trigger_character: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_context.rb#36 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_context.rb#38 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_context.rb#42 + def to_json(*args); end + + # The trigger character (a single character) that has trigger code + # complete. Is undefined if + # `triggerKind !== CompletionTriggerKind.TriggerCharacter` + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_context.rb#32 + def trigger_character; end + + # How the completion was triggered. + # + # @return [CompletionTriggerKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_context.rb#22 + def trigger_kind; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#4 +class LanguageServer::Protocol::Interface::CompletionItem + # @return [CompletionItem] a new instance of CompletionItem + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#5 + def initialize(label:, label_details: T.unsafe(nil), kind: T.unsafe(nil), tags: T.unsafe(nil), detail: T.unsafe(nil), documentation: T.unsafe(nil), deprecated: T.unsafe(nil), preselect: T.unsafe(nil), sort_text: T.unsafe(nil), filter_text: T.unsafe(nil), insert_text: T.unsafe(nil), insert_text_format: T.unsafe(nil), insert_text_mode: T.unsafe(nil), text_edit: T.unsafe(nil), text_edit_text: T.unsafe(nil), additional_text_edits: T.unsafe(nil), commit_characters: T.unsafe(nil), command: T.unsafe(nil), data: T.unsafe(nil)); end + + # An optional array of additional text edits that are applied when + # selecting this completion. Edits must not overlap (including the same + # insert position) with the main edit nor with themselves. + # + # Additional text edits should be used to change text unrelated to the + # current cursor position (for example adding an import statement at the + # top of the file if the completion item will insert an unqualified type). + # + # @return [TextEdit[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#221 + def additional_text_edits; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#255 + def attributes; end + + # An optional command that is executed *after* inserting this completion. + # *Note* that additional modifications to the current document should be + # described with the additionalTextEdits-property. + # + # @return [Command] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#242 + def command; end + + # An optional set of characters that when pressed while this completion is + # active will accept it first and then type that character. *Note* that all + # commit characters should have `length=1` and that superfluous characters + # will be ignored. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#232 + def commit_characters; end + + # A data entry field that is preserved on a completion item between + # a completion and a completion resolve request. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#251 + def data; end + + # Indicates if this item is deprecated. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#92 + def deprecated; end + + # A human-readable string with additional information + # about this item, like type or symbol information. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#76 + def detail; end + + # A human-readable string that represents a doc-comment. + # + # @return [string | MarkupContent] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#84 + def documentation; end + + # A string that should be used when filtering a set of + # completion items. When `falsy` the label is used as the + # filter text for this item. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#124 + def filter_text; end + + # A string that should be inserted into a document when selecting + # this completion. When `falsy` the label is used as the insert text + # for this item. + # + # The `insertText` is subject to interpretation by the client side. + # Some tools might not take the string literally. For example + # VS Code when code complete is requested in this example + # `con` and a completion item with an `insertText` of + # `console` is provided it will only insert `sole`. Therefore it is + # recommended to use `textEdit` instead since it avoids additional client + # side interpretation. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#142 + def insert_text; end + + # The format of the insert text. The format applies to both the + # `insertText` property and the `newText` property of a provided + # `textEdit`. If omitted defaults to `InsertTextFormat.PlainText`. + # + # Please note that the insertTextFormat doesn't apply to + # `additionalTextEdits`. + # + # @return [InsertTextFormat] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#155 + def insert_text_format; end + + # How whitespace and indentation is handled during completion + # item insertion. If not provided the client's default value depends on + # the `textDocument.completion.insertTextMode` client capability. + # + # @return [InsertTextMode] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#165 + def insert_text_mode; end + + # The kind of this completion item. Based of the kind + # an icon is chosen by the editor. The standardized set + # of available values is defined in `CompletionItemKind`. + # + # @return [CompletionItemKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#59 + def kind; end + + # The label of this completion item. + # + # The label property is also by default the text that + # is inserted when selecting this completion. + # + # If label details are provided the label itself should + # be an unqualified name of the completion item. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#41 + def label; end + + # Additional details for the label + # + # @return [CompletionItemLabelDetails] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#49 + def label_details; end + + # Select this item when showing. + # + # *Note* that only one completion item can be selected and that the + # tool / client decides which item that is. The rule is that the *first* + # item of those that match best is selected. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#104 + def preselect; end + + # A string that should be used when comparing this item + # with other items. When `falsy` the label is used + # as the sort text for this item. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#114 + def sort_text; end + + # Tags for this completion item. + # + # @return [1[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#67 + def tags; end + + # An edit which is applied to a document when selecting this completion. + # When an edit is provided the value of `insertText` is ignored. + # + # *Note:* The range of the edit must be a single line range and it must + # contain the position at which completion has been requested. + # + # Most editors support two different operations when accepting a completion + # item. One is to insert a completion text and the other is to replace an + # existing text with a completion text. Since this can usually not be + # predetermined by a server it can report both ranges. Clients need to + # signal support for `InsertReplaceEdit`s via the + # `textDocument.completion.completionItem.insertReplaceSupport` client + # capability property. + # + # *Note 1:* The text edit's range as well as both ranges from an insert + # replace edit must be a [single line] and they must contain the position + # at which completion has been requested. + # *Note 2:* If an `InsertReplaceEdit` is returned the edit's insert range + # must be a prefix of the edit's replace range, that means it must be + # contained and starting at the same position. + # + # @return [TextEdit | InsertReplaceEdit] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#192 + def text_edit; end + + # The edit text used if the completion item is part of a CompletionList and + # CompletionList defines an item default for the text edit range. + # + # Clients will only honor this property if they opt into completion list + # item defaults using the capability `completionList.itemDefaults`. + # + # If not provided and a list's default range is provided the label + # property is used as a text. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#207 + def text_edit_text; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#257 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item.rb#261 + def to_json(*args); end +end + +# Additional details for a completion item label. +# +# source://language_server-protocol//lib/language_server/protocol/interface/completion_item_label_details.rb#7 +class LanguageServer::Protocol::Interface::CompletionItemLabelDetails + # @return [CompletionItemLabelDetails] a new instance of CompletionItemLabelDetails + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item_label_details.rb#8 + def initialize(detail: T.unsafe(nil), description: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item_label_details.rb#37 + def attributes; end + + # An optional string which is rendered less prominently after + # {@link CompletionItemLabelDetails.detail}. Should be used for fully qualified + # names or file path. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item_label_details.rb#33 + def description; end + + # An optional string which is rendered less prominently directly after + # {@link CompletionItem.label label}, without any spacing. Should be + # used for function signatures or type annotations. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item_label_details.rb#23 + def detail; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item_label_details.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_item_label_details.rb#43 + def to_json(*args); end +end + +# Represents a collection of [completion items](#CompletionItem) to be +# presented in the editor. +# +# source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#8 +class LanguageServer::Protocol::Interface::CompletionList + # @return [CompletionList] a new instance of CompletionList + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#9 + def initialize(is_incomplete:, items:, item_defaults: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#57 + def attributes; end + + # This list is not complete. Further typing should result in recomputing + # this list. + # + # Recomputed lists have all their items replaced (not appended) in the + # incomplete completion sessions. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#27 + def is_incomplete; end + + # In many cases the items of an actual completion result share the same + # value for properties like `commitCharacters` or the range of a text + # edit. A completion list can therefore define item defaults which will + # be used if a completion item itself doesn't specify the value. + # + # If a completion list specifies a default value and a completion item + # also specifies a corresponding value the one from the item is used. + # + # Servers are only allowed to return default values if the client + # signals support for this via the `completionList.itemDefaults` + # capability. + # + # @return [{ commitCharacters?: string[]; editRange?: Range | { insert: Range; replace: Range; }; insertTextFormat?: InsertTextFormat; insertTextMode?: InsertTextMode; data?: LSPAny; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#45 + def item_defaults; end + + # The completion items. + # + # @return [CompletionItem[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#53 + def items; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#59 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_list.rb#63 + def to_json(*args); end +end + +# Completion options. +# +# source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#7 +class LanguageServer::Protocol::Interface::CompletionOptions + # @return [CompletionOptions] a new instance of CompletionOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#8 + def initialize(work_done_progress: T.unsafe(nil), trigger_characters: T.unsafe(nil), all_commit_characters: T.unsafe(nil), resolve_provider: T.unsafe(nil), completion_item: T.unsafe(nil)); end + + # The list of all possible characters that commit a completion. This field + # can be used if clients don't support individual commit characters per + # completion item. See client capability + # `completion.completionItem.commitCharactersSupport`. + # + # If a server provides both `allCommitCharacters` and commit characters on + # an individual completion item the ones on the completion item win. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#53 + def all_commit_characters; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#75 + def attributes; end + + # The server supports the following `CompletionItem` specific + # capabilities. + # + # @return [{ labelDetailsSupport?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#71 + def completion_item; end + + # The server provides support to resolve additional + # information for a completion item. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#62 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#77 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#81 + def to_json(*args); end + + # The additional characters, beyond the defaults provided by the client (typically + # [a-zA-Z]), that should automatically trigger a completion request. For example + # `.` in JavaScript represents the beginning of an object property or method and is + # thus a good candidate for triggering a completion request. + # + # Most tools trigger a completion request automatically without explicitly + # requesting it using a keyboard shortcut (e.g. Ctrl+Space). Typically they + # do so when the user starts to type an identifier. For example if the user + # types `c` in a JavaScript file code complete will automatically pop up + # present `console` besides others as a completion item. Characters that + # make up identifiers don't need to be listed here. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#39 + def trigger_characters; end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_options.rb#21 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#4 +class LanguageServer::Protocol::Interface::CompletionParams + # @return [CompletionParams] a new instance of CompletionParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil), context: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#60 + def attributes; end + + # The completion context. This is only available if the client specifies + # to send this using the client capability + # `completion.contextSupport === true` + # + # @return [CompletionContext] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#56 + def context; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#46 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#29 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#21 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#62 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#66 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_params.rb#37 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#4 +class LanguageServer::Protocol::Interface::CompletionRegistrationOptions + # @return [CompletionRegistrationOptions] a new instance of CompletionRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), trigger_characters: T.unsafe(nil), all_commit_characters: T.unsafe(nil), resolve_provider: T.unsafe(nil), completion_item: T.unsafe(nil)); end + + # The list of all possible characters that commit a completion. This field + # can be used if clients don't support individual commit characters per + # completion item. See client capability + # `completion.completionItem.commitCharactersSupport`. + # + # If a server provides both `allCommitCharacters` and commit characters on + # an individual completion item the ones on the completion item win. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#60 + def all_commit_characters; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#82 + def attributes; end + + # The server supports the following `CompletionItem` specific + # capabilities. + # + # @return [{ labelDetailsSupport?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#78 + def completion_item; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#23 + def document_selector; end + + # The server provides support to resolve additional + # information for a completion item. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#69 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#84 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#88 + def to_json(*args); end + + # The additional characters, beyond the defaults provided by the client (typically + # [a-zA-Z]), that should automatically trigger a completion request. For example + # `.` in JavaScript represents the beginning of an object property or method and is + # thus a good candidate for triggering a completion request. + # + # Most tools trigger a completion request automatically without explicitly + # requesting it using a keyboard shortcut (e.g. Ctrl+Space). Typically they + # do so when the user starts to type an identifier. For example if the user + # types `c` in a JavaScript file code complete will automatically pop up + # present `console` besides others as a completion item. Characters that + # make up identifiers don't need to be listed here. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#46 + def trigger_characters; end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/completion_registration_options.rb#28 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/configuration_item.rb#4 +class LanguageServer::Protocol::Interface::ConfigurationItem + # @return [ConfigurationItem] a new instance of ConfigurationItem + # + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_item.rb#5 + def initialize(scope_uri: T.unsafe(nil), section: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_item.rb#30 + def attributes; end + + # The scope to get the configuration section for. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_item.rb#18 + def scope_uri; end + + # The configuration section asked for. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_item.rb#26 + def section; end + + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_item.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_item.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/configuration_params.rb#4 +class LanguageServer::Protocol::Interface::ConfigurationParams + # @return [ConfigurationParams] a new instance of ConfigurationParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_params.rb#5 + def initialize(items:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_params.rb#18 + def attributes; end + + # @return [ConfigurationItem[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_params.rb#14 + def items; end + + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_params.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/configuration_params.rb#24 + def to_json(*args); end +end + +# Create file operation +# +# source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#7 +class LanguageServer::Protocol::Interface::CreateFile + # @return [CreateFile] a new instance of CreateFile + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#8 + def initialize(kind:, uri:, options: T.unsafe(nil), annotation_id: T.unsafe(nil)); end + + # An optional annotation identifier describing the operation. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#47 + def annotation_id; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#51 + def attributes; end + + # A create + # + # @return ["create"] + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#23 + def kind; end + + # Additional options + # + # @return [CreateFileOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#39 + def options; end + + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#53 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#57 + def to_json(*args); end + + # The resource to create. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file.rb#31 + def uri; end +end + +# Options to create a file. +# +# source://language_server-protocol//lib/language_server/protocol/interface/create_file_options.rb#7 +class LanguageServer::Protocol::Interface::CreateFileOptions + # @return [CreateFileOptions] a new instance of CreateFileOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file_options.rb#8 + def initialize(overwrite: T.unsafe(nil), ignore_if_exists: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file_options.rb#33 + def attributes; end + + # Ignore if exists. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file_options.rb#29 + def ignore_if_exists; end + + # Overwrite existing file. Overwrite wins over `ignoreIfExists` + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_file_options.rb#21 + def overwrite; end + + # source://language_server-protocol//lib/language_server/protocol/interface/create_file_options.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/create_file_options.rb#39 + def to_json(*args); end +end + +# The parameters sent in notifications/requests for user-initiated creation +# of files. +# +# source://language_server-protocol//lib/language_server/protocol/interface/create_files_params.rb#8 +class LanguageServer::Protocol::Interface::CreateFilesParams + # @return [CreateFilesParams] a new instance of CreateFilesParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_files_params.rb#9 + def initialize(files:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_files_params.rb#25 + def attributes; end + + # An array of all files/folders created in this operation. + # + # @return [FileCreate[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/create_files_params.rb#21 + def files; end + + # source://language_server-protocol//lib/language_server/protocol/interface/create_files_params.rb#27 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/create_files_params.rb#31 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/declaration_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DeclarationClientCapabilities + # @return [DeclarationClientCapabilities] a new instance of DeclarationClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), link_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_client_capabilities.rb#32 + def attributes; end + + # Whether declaration supports dynamic registration. If this is set to + # `true` the client supports the new `DeclarationRegistrationOptions` + # return value for the corresponding server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_client_capabilities.rb#20 + def dynamic_registration; end + + # The client supports additional metadata in the form of declaration links. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_client_capabilities.rb#28 + def link_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_client_capabilities.rb#34 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_client_capabilities.rb#38 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/declaration_options.rb#4 +class LanguageServer::Protocol::Interface::DeclarationOptions + # @return [DeclarationOptions] a new instance of DeclarationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#4 +class LanguageServer::Protocol::Interface::DeclarationParams + # @return [DeclarationParams] a new instance of DeclarationParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#45 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DeclarationRegistrationOptions + # @return [DeclarationRegistrationOptions] a new instance of DeclarationRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#25 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/declaration_registration_options.rb#16 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/definition_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DefinitionClientCapabilities + # @return [DefinitionClientCapabilities] a new instance of DefinitionClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), link_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_client_capabilities.rb#30 + def attributes; end + + # Whether definition supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_client_capabilities.rb#18 + def dynamic_registration; end + + # The client supports additional metadata in the form of definition links. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_client_capabilities.rb#26 + def link_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_client_capabilities.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_client_capabilities.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/definition_options.rb#4 +class LanguageServer::Protocol::Interface::DefinitionOptions + # @return [DefinitionOptions] a new instance of DefinitionOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#4 +class LanguageServer::Protocol::Interface::DefinitionParams + # @return [DefinitionParams] a new instance of DefinitionParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#45 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/definition_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DefinitionRegistrationOptions + # @return [DefinitionRegistrationOptions] a new instance of DefinitionRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_registration_options.rb#28 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_registration_options.rb#19 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/definition_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/definition_registration_options.rb#24 + def work_done_progress; end +end + +# Delete file operation +# +# source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#7 +class LanguageServer::Protocol::Interface::DeleteFile + # @return [DeleteFile] a new instance of DeleteFile + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#8 + def initialize(kind:, uri:, options: T.unsafe(nil), annotation_id: T.unsafe(nil)); end + + # An optional annotation identifier describing the operation. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#47 + def annotation_id; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#51 + def attributes; end + + # A delete + # + # @return ["delete"] + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#23 + def kind; end + + # Delete options. + # + # @return [DeleteFileOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#39 + def options; end + + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#53 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#57 + def to_json(*args); end + + # The file to delete. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file.rb#31 + def uri; end +end + +# Delete file options +# +# source://language_server-protocol//lib/language_server/protocol/interface/delete_file_options.rb#7 +class LanguageServer::Protocol::Interface::DeleteFileOptions + # @return [DeleteFileOptions] a new instance of DeleteFileOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file_options.rb#8 + def initialize(recursive: T.unsafe(nil), ignore_if_not_exists: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file_options.rb#33 + def attributes; end + + # Ignore the operation if the file doesn't exist. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file_options.rb#29 + def ignore_if_not_exists; end + + # Delete the content recursively if a folder is denoted. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file_options.rb#21 + def recursive; end + + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file_options.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/delete_file_options.rb#39 + def to_json(*args); end +end + +# The parameters sent in notifications/requests for user-initiated deletes +# of files. +# +# source://language_server-protocol//lib/language_server/protocol/interface/delete_files_params.rb#8 +class LanguageServer::Protocol::Interface::DeleteFilesParams + # @return [DeleteFilesParams] a new instance of DeleteFilesParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_files_params.rb#9 + def initialize(files:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_files_params.rb#25 + def attributes; end + + # An array of all files/folders deleted in this operation. + # + # @return [FileDelete[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/delete_files_params.rb#21 + def files; end + + # source://language_server-protocol//lib/language_server/protocol/interface/delete_files_params.rb#27 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/delete_files_params.rb#31 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#4 +class LanguageServer::Protocol::Interface::Diagnostic + # @return [Diagnostic] a new instance of Diagnostic + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#5 + def initialize(range:, message:, severity: T.unsafe(nil), code: T.unsafe(nil), code_description: T.unsafe(nil), source: T.unsafe(nil), tags: T.unsafe(nil), related_information: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#98 + def attributes; end + + # The diagnostic's code, which might appear in the user interface. + # + # @return [string | number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#42 + def code; end + + # An optional property to describe the error code. + # + # @return [CodeDescription] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#50 + def code_description; end + + # A data entry field that is preserved between a + # `textDocument/publishDiagnostics` notification and + # `textDocument/codeAction` request. + # + # @return [unknown] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#94 + def data; end + + # The diagnostic's message. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#67 + def message; end + + # The range at which the message applies. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#25 + def range; end + + # An array of related diagnostic information, e.g. when symbol-names within + # a scope collide all definitions can be marked via this property. + # + # @return [DiagnosticRelatedInformation[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#84 + def related_information; end + + # The diagnostic's severity. Can be omitted. If omitted it is up to the + # client to interpret diagnostics as error, warning, info or hint. + # + # @return [DiagnosticSeverity] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#34 + def severity; end + + # A human-readable string describing the source of this + # diagnostic, e.g. 'typescript' or 'super lint'. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#59 + def source; end + + # Additional metadata about the diagnostic. + # + # @return [DiagnosticTag[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#75 + def tags; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#100 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic.rb#104 + def to_json(*args); end +end + +# Client capabilities specific to diagnostic pull requests. +# +# source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::DiagnosticClientCapabilities + # @return [DiagnosticClientCapabilities] a new instance of DiagnosticClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_client_capabilities.rb#8 + def initialize(dynamic_registration: T.unsafe(nil), related_document_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_client_capabilities.rb#37 + def attributes; end + + # Whether implementation supports dynamic registration. If this is set to + # `true` the client supports the new + # `(TextDocumentRegistrationOptions & StaticRegistrationOptions)` + # return value for the corresponding server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_client_capabilities.rb#24 + def dynamic_registration; end + + # Whether the clients supports related documents for document diagnostic + # pulls. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_client_capabilities.rb#33 + def related_document_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_client_capabilities.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_client_capabilities.rb#43 + def to_json(*args); end +end + +# Diagnostic options. +# +# source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#7 +class LanguageServer::Protocol::Interface::DiagnosticOptions + # @return [DiagnosticOptions] a new instance of DiagnosticOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#8 + def initialize(inter_file_dependencies:, workspace_diagnostics:, work_done_progress: T.unsafe(nil), identifier: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#52 + def attributes; end + + # An optional identifier under which the diagnostics are + # managed by the client. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#29 + def identifier; end + + # Whether the language has inter file dependencies meaning that + # editing code in one file can result in a different diagnostic + # set in another file. Inter file dependencies are common for + # most programming languages and typically uncommon for linters. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#40 + def inter_file_dependencies; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#54 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#58 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#20 + def work_done_progress; end + + # The server provides support for workspace diagnostics as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_options.rb#48 + def workspace_diagnostics; end +end + +# Diagnostic registration options. +# +# source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#7 +class LanguageServer::Protocol::Interface::DiagnosticRegistrationOptions + # @return [DiagnosticRegistrationOptions] a new instance of DiagnosticRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#8 + def initialize(document_selector:, inter_file_dependencies:, workspace_diagnostics:, work_done_progress: T.unsafe(nil), identifier: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#72 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#26 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#68 + def id; end + + # An optional identifier under which the diagnostics are + # managed by the client. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#40 + def identifier; end + + # Whether the language has inter file dependencies meaning that + # editing code in one file can result in a different diagnostic + # set in another file. Inter file dependencies are common for + # most programming languages and typically uncommon for linters. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#51 + def inter_file_dependencies; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#74 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#78 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#31 + def work_done_progress; end + + # The server provides support for workspace diagnostics as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_registration_options.rb#59 + def workspace_diagnostics; end +end + +# Represents a related message and source code location for a diagnostic. +# This should be used to point to code locations that cause or are related to +# a diagnostics, e.g when duplicating a symbol in a scope. +# +# source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_related_information.rb#9 +class LanguageServer::Protocol::Interface::DiagnosticRelatedInformation + # @return [DiagnosticRelatedInformation] a new instance of DiagnosticRelatedInformation + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_related_information.rb#10 + def initialize(location:, message:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_related_information.rb#35 + def attributes; end + + # The location of this related diagnostic information. + # + # @return [Location] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_related_information.rb#23 + def location; end + + # The message of this related diagnostic information. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_related_information.rb#31 + def message; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_related_information.rb#37 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_related_information.rb#41 + def to_json(*args); end +end + +# Cancellation data returned from a diagnostic request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_server_cancellation_data.rb#7 +class LanguageServer::Protocol::Interface::DiagnosticServerCancellationData + # @return [DiagnosticServerCancellationData] a new instance of DiagnosticServerCancellationData + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_server_cancellation_data.rb#8 + def initialize(retrigger_request:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_server_cancellation_data.rb#21 + def attributes; end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_server_cancellation_data.rb#17 + def retrigger_request; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_server_cancellation_data.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_server_cancellation_data.rb#27 + def to_json(*args); end +end + +# Workspace client capabilities specific to diagnostic pull requests. +# +# source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_workspace_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::DiagnosticWorkspaceClientCapabilities + # @return [DiagnosticWorkspaceClientCapabilities] a new instance of DiagnosticWorkspaceClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_workspace_client_capabilities.rb#8 + def initialize(refresh_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_workspace_client_capabilities.rb#30 + def attributes; end + + # Whether the client implementation supports a refresh request sent from + # the server to the client. + # + # Note that this event is global and will force the client to refresh all + # pulled diagnostics currently shown. It should be used with absolute care + # and is useful for situation where a server for example detects a project + # wide change that requires such a calculation. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_workspace_client_capabilities.rb#26 + def refresh_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_workspace_client_capabilities.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/diagnostic_workspace_client_capabilities.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DidChangeConfigurationClientCapabilities + # @return [DidChangeConfigurationClientCapabilities] a new instance of DidChangeConfigurationClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_client_capabilities.rb#21 + def attributes; end + + # Did change configuration notification supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_params.rb#4 +class LanguageServer::Protocol::Interface::DidChangeConfigurationParams + # @return [DidChangeConfigurationParams] a new instance of DidChangeConfigurationParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_params.rb#5 + def initialize(settings:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_params.rb#21 + def attributes; end + + # The actual changed settings + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_params.rb#17 + def settings; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_configuration_params.rb#27 + def to_json(*args); end +end + +# The params sent in a change notebook document notification. +# +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_notebook_document_params.rb#7 +class LanguageServer::Protocol::Interface::DidChangeNotebookDocumentParams + # @return [DidChangeNotebookDocumentParams] a new instance of DidChangeNotebookDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_notebook_document_params.rb#8 + def initialize(notebook_document:, change:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_notebook_document_params.rb#44 + def attributes; end + + # The actual changes to the notebook document. + # + # The change describes single state change to the notebook document. + # So it moves a notebook document, its cells and its cell text document + # contents from state S to S'. + # + # To mirror the content of a notebook using change events use the + # following approach: + # - start with the same initial content + # - apply the 'notebookDocument/didChange' notifications in the order + # you receive them. + # + # @return [NotebookDocumentChangeEvent] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_notebook_document_params.rb#40 + def change; end + + # The notebook document that did change. The version number points + # to the version after all provided changes have been applied. + # + # @return [VersionedNotebookDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_notebook_document_params.rb#22 + def notebook_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_notebook_document_params.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_notebook_document_params.rb#50 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_text_document_params.rb#4 +class LanguageServer::Protocol::Interface::DidChangeTextDocumentParams + # @return [DidChangeTextDocumentParams] a new instance of DidChangeTextDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_text_document_params.rb#5 + def initialize(text_document:, content_changes:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_text_document_params.rb#44 + def attributes; end + + # The actual content changes. The content changes describe single state + # changes to the document. So if there are two content changes c1 (at + # array index 0) and c2 (at array index 1) for a document in state S then + # c1 moves the document from S to S' and c2 from S' to S''. So c1 is + # computed on the state S and c2 is computed on the state S'. + # + # To mirror the content of a document using change events use the following + # approach: + # - start with the same initial content + # - apply the 'textDocument/didChange' notifications in the order you + # receive them. + # - apply the `TextDocumentContentChangeEvent`s in a single notification + # in the order you receive them. + # + # @return [TextDocumentContentChangeEvent[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_text_document_params.rb#40 + def content_changes; end + + # The document that did change. The version number points + # to the version after all provided content changes have + # been applied. + # + # @return [VersionedTextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_text_document_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_text_document_params.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_text_document_params.rb#50 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DidChangeWatchedFilesClientCapabilities + # @return [DidChangeWatchedFilesClientCapabilities] a new instance of DidChangeWatchedFilesClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), relative_pattern_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb#33 + def attributes; end + + # Did change watched files notification supports dynamic registration. + # Please note that the current protocol doesn't support static + # configuration for file changes from the server side. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb#20 + def dynamic_registration; end + + # Whether the client has support for relative patterns + # or not. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb#29 + def relative_pattern_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_client_capabilities.rb#39 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_params.rb#4 +class LanguageServer::Protocol::Interface::DidChangeWatchedFilesParams + # @return [DidChangeWatchedFilesParams] a new instance of DidChangeWatchedFilesParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_params.rb#5 + def initialize(changes:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_params.rb#21 + def attributes; end + + # The actual file events. + # + # @return [FileEvent[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_params.rb#17 + def changes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_params.rb#27 + def to_json(*args); end +end + +# Describe options to be used when registering for file system change events. +# +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_registration_options.rb#7 +class LanguageServer::Protocol::Interface::DidChangeWatchedFilesRegistrationOptions + # @return [DidChangeWatchedFilesRegistrationOptions] a new instance of DidChangeWatchedFilesRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_registration_options.rb#8 + def initialize(watchers:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_registration_options.rb#24 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_registration_options.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_registration_options.rb#30 + def to_json(*args); end + + # The watchers to register. + # + # @return [FileSystemWatcher[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_watched_files_registration_options.rb#20 + def watchers; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_change_workspace_folders_params.rb#4 +class LanguageServer::Protocol::Interface::DidChangeWorkspaceFoldersParams + # @return [DidChangeWorkspaceFoldersParams] a new instance of DidChangeWorkspaceFoldersParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_workspace_folders_params.rb#5 + def initialize(event:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_workspace_folders_params.rb#21 + def attributes; end + + # The actual workspace folder change event. + # + # @return [WorkspaceFoldersChangeEvent] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_workspace_folders_params.rb#17 + def event; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_workspace_folders_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_change_workspace_folders_params.rb#27 + def to_json(*args); end +end + +# The params sent in a close notebook document notification. +# +# source://language_server-protocol//lib/language_server/protocol/interface/did_close_notebook_document_params.rb#7 +class LanguageServer::Protocol::Interface::DidCloseNotebookDocumentParams + # @return [DidCloseNotebookDocumentParams] a new instance of DidCloseNotebookDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_notebook_document_params.rb#8 + def initialize(notebook_document:, cell_text_documents:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_notebook_document_params.rb#34 + def attributes; end + + # The text documents that represent the content + # of a notebook cell that got closed. + # + # @return [TextDocumentIdentifier[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_notebook_document_params.rb#30 + def cell_text_documents; end + + # The notebook document that got closed. + # + # @return [NotebookDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_notebook_document_params.rb#21 + def notebook_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_notebook_document_params.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_notebook_document_params.rb#40 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_close_text_document_params.rb#4 +class LanguageServer::Protocol::Interface::DidCloseTextDocumentParams + # @return [DidCloseTextDocumentParams] a new instance of DidCloseTextDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_text_document_params.rb#5 + def initialize(text_document:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_text_document_params.rb#21 + def attributes; end + + # The document that was closed. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_text_document_params.rb#17 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_text_document_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_close_text_document_params.rb#27 + def to_json(*args); end +end + +# The params sent in an open notebook document notification. +# +# source://language_server-protocol//lib/language_server/protocol/interface/did_open_notebook_document_params.rb#7 +class LanguageServer::Protocol::Interface::DidOpenNotebookDocumentParams + # @return [DidOpenNotebookDocumentParams] a new instance of DidOpenNotebookDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_notebook_document_params.rb#8 + def initialize(notebook_document:, cell_text_documents:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_notebook_document_params.rb#34 + def attributes; end + + # The text documents that represent the content + # of a notebook cell. + # + # @return [TextDocumentItem[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_notebook_document_params.rb#30 + def cell_text_documents; end + + # The notebook document that got opened. + # + # @return [NotebookDocument] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_notebook_document_params.rb#21 + def notebook_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_notebook_document_params.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_notebook_document_params.rb#40 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_open_text_document_params.rb#4 +class LanguageServer::Protocol::Interface::DidOpenTextDocumentParams + # @return [DidOpenTextDocumentParams] a new instance of DidOpenTextDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_text_document_params.rb#5 + def initialize(text_document:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_text_document_params.rb#21 + def attributes; end + + # The document that was opened. + # + # @return [TextDocumentItem] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_text_document_params.rb#17 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_text_document_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_open_text_document_params.rb#27 + def to_json(*args); end +end + +# The params sent in a save notebook document notification. +# +# source://language_server-protocol//lib/language_server/protocol/interface/did_save_notebook_document_params.rb#7 +class LanguageServer::Protocol::Interface::DidSaveNotebookDocumentParams + # @return [DidSaveNotebookDocumentParams] a new instance of DidSaveNotebookDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_notebook_document_params.rb#8 + def initialize(notebook_document:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_notebook_document_params.rb#24 + def attributes; end + + # The notebook document that got saved. + # + # @return [NotebookDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_notebook_document_params.rb#20 + def notebook_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_notebook_document_params.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_notebook_document_params.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/did_save_text_document_params.rb#4 +class LanguageServer::Protocol::Interface::DidSaveTextDocumentParams + # @return [DidSaveTextDocumentParams] a new instance of DidSaveTextDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_text_document_params.rb#5 + def initialize(text_document:, text: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_text_document_params.rb#31 + def attributes; end + + # Optional the content when saved. Depends on the includeText value + # when the save notification was requested. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_text_document_params.rb#27 + def text; end + + # The document that was saved. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_text_document_params.rb#18 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_text_document_params.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/did_save_text_document_params.rb#37 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_color_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DocumentColorClientCapabilities + # @return [DocumentColorClientCapabilities] a new instance of DocumentColorClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_client_capabilities.rb#21 + def attributes; end + + # Whether document color supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_color_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentColorOptions + # @return [DocumentColorOptions] a new instance of DocumentColorOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#4 +class LanguageServer::Protocol::Interface::DocumentColorParams + # @return [DocumentColorParams] a new instance of DocumentColorParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#5 + def initialize(text_document:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#40 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#28 + def partial_result_token; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#36 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#46 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentColorRegistrationOptions + # @return [DocumentColorRegistrationOptions] a new instance of DocumentColorRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#5 + def initialize(document_selector:, id: T.unsafe(nil), work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#20 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#29 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_color_registration_options.rb#34 + def work_done_progress; end +end + +# Parameters of the document diagnostic request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#7 +class LanguageServer::Protocol::Interface::DocumentDiagnosticParams + # @return [DocumentDiagnosticParams] a new instance of DocumentDiagnosticParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#8 + def initialize(text_document:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil), identifier: T.unsafe(nil), previous_result_id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#61 + def attributes; end + + # The additional identifier provided during registration. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#49 + def identifier; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#33 + def partial_result_token; end + + # The result id of a previous response if provided. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#57 + def previous_result_id; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#41 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#63 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#67 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_params.rb#24 + def work_done_token; end +end + +# A partial result for a document diagnostic report. +# +# source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_report_partial_result.rb#7 +class LanguageServer::Protocol::Interface::DocumentDiagnosticReportPartialResult + # @return [DocumentDiagnosticReportPartialResult] a new instance of DocumentDiagnosticReportPartialResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_report_partial_result.rb#8 + def initialize(related_documents:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_report_partial_result.rb#21 + def attributes; end + + # @return [{ [uri: string]: FullDocumentDiagnosticReport | UnchangedDocumentDiagnosticReport; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_report_partial_result.rb#17 + def related_documents; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_report_partial_result.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_diagnostic_report_partial_result.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#4 +class LanguageServer::Protocol::Interface::DocumentFilter + # @return [DocumentFilter] a new instance of DocumentFilter + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#5 + def initialize(language: T.unsafe(nil), scheme: T.unsafe(nil), pattern: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#51 + def attributes; end + + # A language id, like `typescript`. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#19 + def language; end + + # A glob pattern, like `*.{ts,js}`. + # + # Glob patterns can have the following syntax: + # - `*` to match one or more characters in a path segment + # - `?` to match on one character in a path segment + # - `**` to match any number of path segments, including none + # - `{}` to group sub patterns into an OR expression. (e.g. `**​/*.{ts,js}` + # matches all TypeScript and JavaScript files) + # - `[]` to declare a range of characters to match in a path segment + # (e.g., `example.[0-9]` to match on `example.0`, `example.1`, …) + # - `[!...]` to negate a range of characters to match in a path segment + # (e.g., `example.[!0-9]` to match on `example.a`, `example.b`, but + # not `example.0`) + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#47 + def pattern; end + + # A Uri [scheme](#Uri.scheme), like `file` or `untitled`. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#27 + def scheme; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#53 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_filter.rb#57 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DocumentFormattingClientCapabilities + # @return [DocumentFormattingClientCapabilities] a new instance of DocumentFormattingClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_client_capabilities.rb#21 + def attributes; end + + # Whether formatting supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentFormattingOptions + # @return [DocumentFormattingOptions] a new instance of DocumentFormattingOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#4 +class LanguageServer::Protocol::Interface::DocumentFormattingParams + # @return [DocumentFormattingParams] a new instance of DocumentFormattingParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#5 + def initialize(text_document:, options:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#39 + def attributes; end + + # The format options. + # + # @return [FormattingOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#35 + def options; end + + # The document to format. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#27 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#45 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentFormattingRegistrationOptions + # @return [DocumentFormattingRegistrationOptions] a new instance of DocumentFormattingRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_registration_options.rb#28 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_registration_options.rb#19 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_formatting_registration_options.rb#24 + def work_done_progress; end +end + +# A document highlight is a range inside a text document which deserves +# special attention. Usually a document highlight is visualized by changing +# the background color of its range. +# +# source://language_server-protocol//lib/language_server/protocol/interface/document_highlight.rb#9 +class LanguageServer::Protocol::Interface::DocumentHighlight + # @return [DocumentHighlight] a new instance of DocumentHighlight + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight.rb#10 + def initialize(range:, kind: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight.rb#35 + def attributes; end + + # The highlight kind, default is DocumentHighlightKind.Text. + # + # @return [DocumentHighlightKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight.rb#31 + def kind; end + + # The range this highlight applies to. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight.rb#23 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight.rb#37 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight.rb#41 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DocumentHighlightClientCapabilities + # @return [DocumentHighlightClientCapabilities] a new instance of DocumentHighlightClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_client_capabilities.rb#21 + def attributes; end + + # Whether document highlight supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentHighlightOptions + # @return [DocumentHighlightOptions] a new instance of DocumentHighlightOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#4 +class LanguageServer::Protocol::Interface::DocumentHighlightParams + # @return [DocumentHighlightParams] a new instance of DocumentHighlightParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#45 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentHighlightRegistrationOptions + # @return [DocumentHighlightRegistrationOptions] a new instance of DocumentHighlightRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_registration_options.rb#28 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_registration_options.rb#19 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_highlight_registration_options.rb#24 + def work_done_progress; end +end + +# A document link is a range in a text document that links to an internal or +# external resource, like another text document or a web site. +# +# source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#8 +class LanguageServer::Protocol::Interface::DocumentLink + # @return [DocumentLink] a new instance of DocumentLink + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#9 + def initialize(range:, target: T.unsafe(nil), tooltip: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#58 + def attributes; end + + # A data entry field that is preserved on a document link between a + # DocumentLinkRequest and a DocumentLinkResolveRequest. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#54 + def data; end + + # The range this link applies to. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#24 + def range; end + + # The uri this link points to. If missing a resolve request is sent later. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#32 + def target; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#60 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#64 + def to_json(*args); end + + # The tooltip text when you hover over this link. + # + # If a tooltip is provided, is will be displayed in a string that includes + # instructions on how to trigger the link, such as `{0} (ctrl + click)`. + # The specific instructions vary depending on OS, user settings, and + # localization. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link.rb#45 + def tooltip; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_link_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DocumentLinkClientCapabilities + # @return [DocumentLinkClientCapabilities] a new instance of DocumentLinkClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), tooltip_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_client_capabilities.rb#30 + def attributes; end + + # Whether document link supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_client_capabilities.rb#18 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_client_capabilities.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_client_capabilities.rb#36 + def to_json(*args); end + + # Whether the client supports the `tooltip` property on `DocumentLink`. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_client_capabilities.rb#26 + def tooltip_support; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_link_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentLinkOptions + # @return [DocumentLinkOptions] a new instance of DocumentLinkOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_options.rb#27 + def attributes; end + + # Document links have a resolve provider as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_options.rb#23 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_options.rb#29 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_options.rb#33 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_options.rb#15 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#4 +class LanguageServer::Protocol::Interface::DocumentLinkParams + # @return [DocumentLinkParams] a new instance of DocumentLinkParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#5 + def initialize(text_document:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#40 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#28 + def partial_result_token; end + + # The document to provide document links for. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#36 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#46 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentLinkRegistrationOptions + # @return [DocumentLinkRegistrationOptions] a new instance of DocumentLinkRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#37 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#20 + def document_selector; end + + # Document links have a resolve provider as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#33 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#43 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_link_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DocumentOnTypeFormattingClientCapabilities + # @return [DocumentOnTypeFormattingClientCapabilities] a new instance of DocumentOnTypeFormattingClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_client_capabilities.rb#21 + def attributes; end + + # Whether on type formatting supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentOnTypeFormattingOptions + # @return [DocumentOnTypeFormattingOptions] a new instance of DocumentOnTypeFormattingOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_options.rb#5 + def initialize(first_trigger_character:, more_trigger_character: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_options.rb#30 + def attributes; end + + # A character on which formatting should be triggered, like `{`. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_options.rb#18 + def first_trigger_character; end + + # More trigger characters. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_options.rb#26 + def more_trigger_character; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_options.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_options.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#4 +class LanguageServer::Protocol::Interface::DocumentOnTypeFormattingParams + # @return [DocumentOnTypeFormattingParams] a new instance of DocumentOnTypeFormattingParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#5 + def initialize(text_document:, position:, ch:, options:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#53 + def attributes; end + + # The character that has been typed that triggered the formatting + # on type request. That is not necessarily the last character that + # got inserted into the document since the client could auto insert + # characters as well (e.g. like automatic brace completion). + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#41 + def ch; end + + # The formatting options. + # + # @return [FormattingOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#49 + def options; end + + # The position around which the on type formatting should happen. + # This is not necessarily the exact position where the character denoted + # by the property `ch` got typed. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#30 + def position; end + + # The document to format. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#55 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_params.rb#59 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentOnTypeFormattingRegistrationOptions + # @return [DocumentOnTypeFormattingRegistrationOptions] a new instance of DocumentOnTypeFormattingRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#5 + def initialize(document_selector:, first_trigger_character:, more_trigger_character: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#40 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#20 + def document_selector; end + + # A character on which formatting should be triggered, like `{`. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#28 + def first_trigger_character; end + + # More trigger characters. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#36 + def more_trigger_character; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_on_type_formatting_registration_options.rb#46 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DocumentRangeFormattingClientCapabilities + # @return [DocumentRangeFormattingClientCapabilities] a new instance of DocumentRangeFormattingClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_client_capabilities.rb#21 + def attributes; end + + # Whether formatting supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentRangeFormattingOptions + # @return [DocumentRangeFormattingOptions] a new instance of DocumentRangeFormattingOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#4 +class LanguageServer::Protocol::Interface::DocumentRangeFormattingParams + # @return [DocumentRangeFormattingParams] a new instance of DocumentRangeFormattingParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#5 + def initialize(text_document:, range:, options:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#48 + def attributes; end + + # The format options + # + # @return [FormattingOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#44 + def options; end + + # The range to format + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#36 + def range; end + + # The document to format. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#28 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#50 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#54 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_params.rb#20 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentRangeFormattingRegistrationOptions + # @return [DocumentRangeFormattingRegistrationOptions] a new instance of DocumentRangeFormattingRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_registration_options.rb#28 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_registration_options.rb#19 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_range_formatting_registration_options.rb#24 + def work_done_progress; end +end + +# Represents programming constructs like variables, classes, interfaces etc. +# that appear in a document. Document symbols can be hierarchical and they +# have two ranges: one that encloses its definition and one that points to its +# most interesting range, e.g. the range of an identifier. +# +# source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#10 +class LanguageServer::Protocol::Interface::DocumentSymbol + # @return [DocumentSymbol] a new instance of DocumentSymbol + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#11 + def initialize(name:, kind:, range:, selection_range:, detail: T.unsafe(nil), tags: T.unsafe(nil), deprecated: T.unsafe(nil), children: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#96 + def attributes; end + + # Children of this symbol, e.g. properties of a class. + # + # @return [DocumentSymbol[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#92 + def children; end + + # Indicates if this symbol is deprecated. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#64 + def deprecated; end + + # More detail for this symbol, e.g the signature of a function. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#40 + def detail; end + + # The kind of this symbol. + # + # @return [SymbolKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#48 + def kind; end + + # The name of this symbol. Will be displayed in the user interface and + # therefore must not be an empty string or a string only consisting of + # white spaces. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#32 + def name; end + + # The range enclosing this symbol not including leading/trailing whitespace + # but everything else like comments. This information is typically used to + # determine if the clients cursor is inside the symbol to reveal in the + # symbol in the UI. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#75 + def range; end + + # The range that should be selected and revealed when this symbol is being + # picked, e.g. the name of a function. Must be contained by the `range`. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#84 + def selection_range; end + + # Tags for this document symbol. + # + # @return [1[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#56 + def tags; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#98 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol.rb#102 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::DocumentSymbolClientCapabilities + # @return [DocumentSymbolClientCapabilities] a new instance of DocumentSymbolClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), symbol_kind: T.unsafe(nil), hierarchical_document_symbol_support: T.unsafe(nil), tag_support: T.unsafe(nil), label_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#61 + def attributes; end + + # Whether document symbol supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#21 + def dynamic_registration; end + + # The client supports hierarchical document symbols. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#38 + def hierarchical_document_symbol_support; end + + # The client supports an additional label presented in the UI when + # registering a document symbol provider. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#57 + def label_support; end + + # Specific capabilities for the `SymbolKind` in the + # `textDocument/documentSymbol` request. + # + # @return [{ valueSet?: SymbolKind[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#30 + def symbol_kind; end + + # The client supports tags on `SymbolInformation`. Tags are supported on + # `DocumentSymbol` if `hierarchicalDocumentSymbolSupport` is set to true. + # Clients supporting tags have to handle unknown tags gracefully. + # + # @return [{ valueSet: 1[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#48 + def tag_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#63 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_client_capabilities.rb#67 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentSymbolOptions + # @return [DocumentSymbolOptions] a new instance of DocumentSymbolOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), label: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_options.rb#28 + def attributes; end + + # A human-readable string that is shown when multiple outlines trees + # are shown for the same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_options.rb#24 + def label; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_options.rb#15 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#4 +class LanguageServer::Protocol::Interface::DocumentSymbolParams + # @return [DocumentSymbolParams] a new instance of DocumentSymbolParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#5 + def initialize(text_document:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#40 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#28 + def partial_result_token; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#36 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#46 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#4 +class LanguageServer::Protocol::Interface::DocumentSymbolRegistrationOptions + # @return [DocumentSymbolRegistrationOptions] a new instance of DocumentSymbolRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), label: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#20 + def document_selector; end + + # A human-readable string that is shown when multiple outlines trees + # are shown for the same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#34 + def label; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/document_symbol_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/execute_command_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::ExecuteCommandClientCapabilities + # @return [ExecuteCommandClientCapabilities] a new instance of ExecuteCommandClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_client_capabilities.rb#21 + def attributes; end + + # Execute command supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/execute_command_options.rb#4 +class LanguageServer::Protocol::Interface::ExecuteCommandOptions + # @return [ExecuteCommandOptions] a new instance of ExecuteCommandOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_options.rb#5 + def initialize(commands:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_options.rb#27 + def attributes; end + + # The commands to be executed on the server + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_options.rb#23 + def commands; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_options.rb#29 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_options.rb#33 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_options.rb#15 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#4 +class LanguageServer::Protocol::Interface::ExecuteCommandParams + # @return [ExecuteCommandParams] a new instance of ExecuteCommandParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#5 + def initialize(command:, work_done_token: T.unsafe(nil), arguments: T.unsafe(nil)); end + + # Arguments that the command should be invoked with. + # + # @return [LSPAny[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#35 + def arguments; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#39 + def attributes; end + + # The identifier of the actual command handler. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#27 + def command; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#45 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_params.rb#19 + def work_done_token; end +end + +# Execute command registration options. +# +# source://language_server-protocol//lib/language_server/protocol/interface/execute_command_registration_options.rb#7 +class LanguageServer::Protocol::Interface::ExecuteCommandRegistrationOptions + # @return [ExecuteCommandRegistrationOptions] a new instance of ExecuteCommandRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_registration_options.rb#8 + def initialize(commands:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_registration_options.rb#30 + def attributes; end + + # The commands to be executed on the server + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_registration_options.rb#26 + def commands; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_registration_options.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_registration_options.rb#36 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execute_command_registration_options.rb#18 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/execution_summary.rb#4 +class LanguageServer::Protocol::Interface::ExecutionSummary + # @return [ExecutionSummary] a new instance of ExecutionSummary + # + # source://language_server-protocol//lib/language_server/protocol/interface/execution_summary.rb#5 + def initialize(execution_order:, success: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/execution_summary.rb#33 + def attributes; end + + # A strict monotonically increasing value + # indicating the execution order of a cell + # inside a notebook. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execution_summary.rb#20 + def execution_order; end + + # Whether the execution was successful or + # not if known by the client. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/execution_summary.rb#29 + def success; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execution_summary.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/execution_summary.rb#39 + def to_json(*args); end +end + +# Represents information on a file/folder create. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_create.rb#7 +class LanguageServer::Protocol::Interface::FileCreate + # @return [FileCreate] a new instance of FileCreate + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_create.rb#8 + def initialize(uri:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_create.rb#24 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_create.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_create.rb#30 + def to_json(*args); end + + # A file:// URI for the location of the file/folder being created. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_create.rb#20 + def uri; end +end + +# Represents information on a file/folder delete. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_delete.rb#7 +class LanguageServer::Protocol::Interface::FileDelete + # @return [FileDelete] a new instance of FileDelete + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_delete.rb#8 + def initialize(uri:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_delete.rb#24 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_delete.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_delete.rb#30 + def to_json(*args); end + + # A file:// URI for the location of the file/folder being deleted. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_delete.rb#20 + def uri; end +end + +# An event describing a file change. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_event.rb#7 +class LanguageServer::Protocol::Interface::FileEvent + # @return [FileEvent] a new instance of FileEvent + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_event.rb#8 + def initialize(uri:, type:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_event.rb#33 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_event.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_event.rb#39 + def to_json(*args); end + + # The change type. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_event.rb#29 + def type; end + + # The file's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_event.rb#21 + def uri; end +end + +# A filter to describe in which file operation requests or notifications +# the server is interested in. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_operation_filter.rb#8 +class LanguageServer::Protocol::Interface::FileOperationFilter + # @return [FileOperationFilter] a new instance of FileOperationFilter + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_filter.rb#9 + def initialize(pattern:, scheme: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_filter.rb#34 + def attributes; end + + # The actual file operation pattern. + # + # @return [FileOperationPattern] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_filter.rb#30 + def pattern; end + + # A Uri like `file` or `untitled`. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_filter.rb#22 + def scheme; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_filter.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_filter.rb#40 + def to_json(*args); end +end + +# A pattern to describe in which file operation requests or notifications +# the server is interested in. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#8 +class LanguageServer::Protocol::Interface::FileOperationPattern + # @return [FileOperationPattern] a new instance of FileOperationPattern + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#9 + def initialize(glob:, matches: T.unsafe(nil), options: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#55 + def attributes; end + + # The glob pattern to match. Glob patterns can have the following syntax: + # - `*` to match one or more characters in a path segment + # - `?` to match on one character in a path segment + # - `**` to match any number of path segments, including none + # - `{}` to group sub patterns into an OR expression. (e.g. `**​/*.{ts,js}` + # matches all TypeScript and JavaScript files) + # - `[]` to declare a range of characters to match in a path segment + # (e.g., `example.[0-9]` to match on `example.0`, `example.1`, …) + # - `[!...]` to negate a range of characters to match in a path segment + # (e.g., `example.[!0-9]` to match on `example.a`, `example.b`, but + # not `example.0`) + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#33 + def glob; end + + # Whether to match files or folders with this pattern. + # + # Matches both if undefined. + # + # @return [FileOperationPatternKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#43 + def matches; end + + # Additional options used during matching. + # + # @return [FileOperationPatternOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#51 + def options; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#57 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern.rb#61 + def to_json(*args); end +end + +# Matching options for the file operation pattern. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern_options.rb#7 +class LanguageServer::Protocol::Interface::FileOperationPatternOptions + # @return [FileOperationPatternOptions] a new instance of FileOperationPatternOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern_options.rb#8 + def initialize(ignore_case: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern_options.rb#24 + def attributes; end + + # The pattern should be matched ignoring casing. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern_options.rb#20 + def ignore_case; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern_options.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_pattern_options.rb#30 + def to_json(*args); end +end + +# The options to register for file operations. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_operation_registration_options.rb#7 +class LanguageServer::Protocol::Interface::FileOperationRegistrationOptions + # @return [FileOperationRegistrationOptions] a new instance of FileOperationRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_registration_options.rb#8 + def initialize(filters:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_registration_options.rb#24 + def attributes; end + + # The actual filters. + # + # @return [FileOperationFilter[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_registration_options.rb#20 + def filters; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_registration_options.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_operation_registration_options.rb#30 + def to_json(*args); end +end + +# Represents information on a file/folder rename. +# +# source://language_server-protocol//lib/language_server/protocol/interface/file_rename.rb#7 +class LanguageServer::Protocol::Interface::FileRename + # @return [FileRename] a new instance of FileRename + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_rename.rb#8 + def initialize(old_uri:, new_uri:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_rename.rb#33 + def attributes; end + + # A file:// URI for the new location of the file/folder being renamed. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_rename.rb#29 + def new_uri; end + + # A file:// URI for the original location of the file/folder being renamed. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_rename.rb#21 + def old_uri; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_rename.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_rename.rb#39 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/file_system_watcher.rb#4 +class LanguageServer::Protocol::Interface::FileSystemWatcher + # @return [FileSystemWatcher] a new instance of FileSystemWatcher + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_system_watcher.rb#5 + def initialize(glob_pattern:, kind: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_system_watcher.rb#33 + def attributes; end + + # The glob pattern to watch. See {@link GlobPattern glob pattern} + # for more detail. + # + # @return [GlobPattern] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_system_watcher.rb#19 + def glob_pattern; end + + # The kind of events of interest. If omitted it defaults + # to WatchKind.Create | WatchKind.Change | WatchKind.Delete + # which is 7. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/file_system_watcher.rb#29 + def kind; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_system_watcher.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/file_system_watcher.rb#39 + def to_json(*args); end +end + +# Represents a folding range. To be valid, start and end line must be bigger +# than zero and smaller than the number of lines in the document. Clients +# are free to ignore invalid ranges. +# +# source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#9 +class LanguageServer::Protocol::Interface::FoldingRange + # @return [FoldingRange] a new instance of FoldingRange + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#10 + def initialize(start_line:, end_line:, start_character: T.unsafe(nil), end_character: T.unsafe(nil), kind: T.unsafe(nil), collapsed_text: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#82 + def attributes; end + + # The text that the client should show when the specified range is + # collapsed. If not defined or not supported by the client, a default + # will be chosen by the client. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#78 + def collapsed_text; end + + # The zero-based character offset before the folded range ends. If not + # defined, defaults to the length of the end line. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#57 + def end_character; end + + # The zero-based end line of the range to fold. The folded area ends with + # the line's last character. To be valid, the end must be zero or larger + # and smaller than the number of lines in the document. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#48 + def end_line; end + + # Describes the kind of the folding range such as `comment` or `region`. + # The kind is used to categorize folding ranges and used by commands like + # 'Fold all comments'. See [FoldingRangeKind](#FoldingRangeKind) for an + # enumeration of standardized kinds. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#68 + def kind; end + + # The zero-based character offset from where the folded range starts. If + # not defined, defaults to the length of the start line. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#38 + def start_character; end + + # The zero-based start line of the range to fold. The folded area starts + # after the line's last character. To be valid, the end must be zero or + # larger and smaller than the number of lines in the document. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#29 + def start_line; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#84 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range.rb#88 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::FoldingRangeClientCapabilities + # @return [FoldingRangeClientCapabilities] a new instance of FoldingRangeClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), range_limit: T.unsafe(nil), line_folding_only: T.unsafe(nil), folding_range_kind: T.unsafe(nil), folding_range: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#64 + def attributes; end + + # Whether implementation supports dynamic registration for folding range + # providers. If this is set to `true` the client supports the new + # `FoldingRangeRegistrationOptions` return value for the corresponding + # server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#24 + def dynamic_registration; end + + # Specific options for the folding range. + # + # @return [{ collapsedText?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#60 + def folding_range; end + + # Specific options for the folding range kind. + # + # @return [{ valueSet?: string[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#52 + def folding_range_kind; end + + # If set, the client signals that it only supports folding complete lines. + # If set, client will ignore specified `startCharacter` and `endCharacter` + # properties in a FoldingRange. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#44 + def line_folding_only; end + + # The maximum number of folding ranges that the client prefers to receive + # per document. The value serves as a hint, servers are free to follow the + # limit. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#34 + def range_limit; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#66 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_client_capabilities.rb#70 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/folding_range_options.rb#4 +class LanguageServer::Protocol::Interface::FoldingRangeOptions + # @return [FoldingRangeOptions] a new instance of FoldingRangeOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#4 +class LanguageServer::Protocol::Interface::FoldingRangeParams + # @return [FoldingRangeParams] a new instance of FoldingRangeParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#5 + def initialize(text_document:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#40 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#28 + def partial_result_token; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#36 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#46 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#4 +class LanguageServer::Protocol::Interface::FoldingRangeRegistrationOptions + # @return [FoldingRangeRegistrationOptions] a new instance of FoldingRangeRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#20 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/folding_range_registration_options.rb#25 + def work_done_progress; end +end + +# Value-object describing what options formatting should use. +# +# source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#7 +class LanguageServer::Protocol::Interface::FormattingOptions + # @return [FormattingOptions] a new instance of FormattingOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#8 + def initialize(tab_size:, insert_spaces:, trim_trailing_whitespace: T.unsafe(nil), insert_final_newline: T.unsafe(nil), trim_final_newlines: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#60 + def attributes; end + + # Insert a newline character at the end of the file if one does not exist. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#48 + def insert_final_newline; end + + # Prefer spaces over tabs. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#32 + def insert_spaces; end + + # Size of a tab in spaces. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#24 + def tab_size; end + + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#62 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#66 + def to_json(*args); end + + # Trim all newlines after the final newline at the end of the file. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#56 + def trim_final_newlines; end + + # Trim trailing whitespace on a line. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/formatting_options.rb#40 + def trim_trailing_whitespace; end +end + +# A diagnostic report with a full set of problems. +# +# source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#7 +class LanguageServer::Protocol::Interface::FullDocumentDiagnosticReport + # @return [FullDocumentDiagnosticReport] a new instance of FullDocumentDiagnosticReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#8 + def initialize(kind:, items:, result_id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#44 + def attributes; end + + # The actual items. + # + # @return [Diagnostic[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#40 + def items; end + + # A full document diagnostic report. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#22 + def kind; end + + # An optional result id. If provided it will + # be sent on the next diagnostic request for the + # same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#32 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/full_document_diagnostic_report.rb#50 + def to_json(*args); end +end + +# The result of a hover request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/hover.rb#7 +class LanguageServer::Protocol::Interface::Hover + # @return [Hover] a new instance of Hover + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover.rb#8 + def initialize(contents:, range: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover.rb#34 + def attributes; end + + # The hover's content + # + # @return [MarkupContent | MarkedString | MarkedString[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover.rb#21 + def contents; end + + # An optional range is a range inside a text document + # that is used to visualize a hover, e.g. by changing the background color. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover.rb#30 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover.rb#40 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/hover_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::HoverClientCapabilities + # @return [HoverClientCapabilities] a new instance of HoverClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), content_format: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_client_capabilities.rb#32 + def attributes; end + + # Client supports the follow content formats if the content + # property refers to a `literal of type MarkupContent`. + # The order describes the preferred format of the client. + # + # @return [MarkupKind[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_client_capabilities.rb#28 + def content_format; end + + # Whether hover supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_client_capabilities.rb#18 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_client_capabilities.rb#34 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_client_capabilities.rb#38 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/hover_options.rb#4 +class LanguageServer::Protocol::Interface::HoverOptions + # @return [HoverOptions] a new instance of HoverOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#4 +class LanguageServer::Protocol::Interface::HoverParams + # @return [HoverParams] a new instance of HoverParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#39 + def attributes; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#27 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#19 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#45 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_params.rb#35 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/hover_registration_options.rb#4 +class LanguageServer::Protocol::Interface::HoverRegistrationOptions + # @return [HoverRegistrationOptions] a new instance of HoverRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_registration_options.rb#28 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_registration_options.rb#19 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_registration_options.rb#24 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/hover_result.rb#4 +class LanguageServer::Protocol::Interface::HoverResult + # @return [HoverResult] a new instance of HoverResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_result.rb#5 + def initialize(value:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_result.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_result.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/hover_result.rb#24 + def to_json(*args); end + + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/hover_result.rb#14 + def value; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/implementation_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::ImplementationClientCapabilities + # @return [ImplementationClientCapabilities] a new instance of ImplementationClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), link_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_client_capabilities.rb#32 + def attributes; end + + # Whether implementation supports dynamic registration. If this is set to + # `true` the client supports the new `ImplementationRegistrationOptions` + # return value for the corresponding server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_client_capabilities.rb#20 + def dynamic_registration; end + + # The client supports additional metadata in the form of definition links. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_client_capabilities.rb#28 + def link_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_client_capabilities.rb#34 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_client_capabilities.rb#38 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/implementation_options.rb#4 +class LanguageServer::Protocol::Interface::ImplementationOptions + # @return [ImplementationOptions] a new instance of ImplementationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#4 +class LanguageServer::Protocol::Interface::ImplementationParams + # @return [ImplementationParams] a new instance of ImplementationParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#45 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#4 +class LanguageServer::Protocol::Interface::ImplementationRegistrationOptions + # @return [ImplementationRegistrationOptions] a new instance of ImplementationRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#20 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/implementation_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/initialize_error.rb#4 +class LanguageServer::Protocol::Interface::InitializeError + # @return [InitializeError] a new instance of InitializeError + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_error.rb#5 + def initialize(retry:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_error.rb#24 + def attributes; end + + # Indicates whether the client execute the following retry logic: + # (1) show the message provided by the ResponseError to the user + # (2) user selects retry or cancel + # (3) if user selected retry the initialize method is sent again. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_error.rb#20 + def retry; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_error.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_error.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#4 +class LanguageServer::Protocol::Interface::InitializeParams + # @return [InitializeParams] a new instance of InitializeParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#5 + def initialize(process_id:, root_uri:, capabilities:, work_done_token: T.unsafe(nil), client_info: T.unsafe(nil), locale: T.unsafe(nil), root_path: T.unsafe(nil), initialization_options: T.unsafe(nil), trace: T.unsafe(nil), workspace_folders: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#116 + def attributes; end + + # The capabilities provided by the client (editor or tool) + # + # @return [ClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#93 + def capabilities; end + + # Information about the client + # + # @return [{ name: string; version?: string; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#45 + def client_info; end + + # User provided initialization options. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#85 + def initialization_options; end + + # The locale the client is currently showing the user interface + # in. This must not necessarily be the locale of the operating + # system. + # + # Uses IETF language tags as the value's syntax + # (See https://en.wikipedia.org/wiki/IETF_language_tag) + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#58 + def locale; end + + # The process Id of the parent process that started the server. Is null if + # the process has not been started by another process. If the parent + # process is not alive then the server should exit (see exit notification) + # its process. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#37 + def process_id; end + + # The rootPath of the workspace. Is null + # if no folder is open. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#67 + def root_path; end + + # The rootUri of the workspace. Is null if no + # folder is open. If both `rootPath` and `rootUri` are set + # `rootUri` wins. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#77 + def root_uri; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#118 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#122 + def to_json(*args); end + + # The initial trace setting. If omitted trace is disabled ('off'). + # + # @return [TraceValue] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#101 + def trace; end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#26 + def work_done_token; end + + # The workspace folders configured in the client when the server starts. + # This property is only available if the client supports workspace folders. + # It can be `null` if the client supports workspace folders but none are + # configured. + # + # @return [WorkspaceFolder[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_params.rb#112 + def workspace_folders; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/initialize_result.rb#4 +class LanguageServer::Protocol::Interface::InitializeResult + # @return [InitializeResult] a new instance of InitializeResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_result.rb#5 + def initialize(capabilities:, server_info: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_result.rb#30 + def attributes; end + + # The capabilities the language server provides. + # + # @return [ServerCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_result.rb#18 + def capabilities; end + + # Information about the server. + # + # @return [{ name: string; version?: string; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_result.rb#26 + def server_info; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_result.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialize_result.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/initialized_params.rb#4 +class LanguageServer::Protocol::Interface::InitializedParams + # @return [InitializedParams] a new instance of InitializedParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialized_params.rb#5 + def initialize; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/initialized_params.rb#12 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialized_params.rb#14 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/initialized_params.rb#18 + def to_json(*args); end +end + +# Inlay hint information. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#7 +class LanguageServer::Protocol::Interface::InlayHint + # @return [InlayHint] a new instance of InlayHint + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#8 + def initialize(position:, label:, kind: T.unsafe(nil), text_edits: T.unsafe(nil), tooltip: T.unsafe(nil), padding_left: T.unsafe(nil), padding_right: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#110 + def attributes; end + + # A data entry field that is preserved on an inlay hint between + # a `textDocument/inlayHint` and a `inlayHint/resolve` request. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#106 + def data; end + + # The kind of this hint. Can be omitted in which case the client + # should fall back to a reasonable default. + # + # @return [InlayHintKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#47 + def kind; end + + # The label of this hint. A human readable string or an array of + # InlayHintLabelPart label parts. + # + # *Note* that neither the string nor the label part can be empty. + # + # @return [string | InlayHintLabelPart[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#38 + def label; end + + # Render padding before the hint. + # + # Note: Padding should use the editor's background color, not the + # background color of the hint itself. That means padding can be used + # to visually align/separate an inlay hint. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#85 + def padding_left; end + + # Render padding after the hint. + # + # Note: Padding should use the editor's background color, not the + # background color of the hint itself. That means padding can be used + # to visually align/separate an inlay hint. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#97 + def padding_right; end + + # The position of this hint. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#27 + def position; end + + # Optional text edits that are performed when accepting this inlay hint. + # + # *Note* that edits are expected to change the document so that the inlay + # hint (or its nearest variant) is now part of the document and the inlay + # hint itself is now obsolete. + # + # Depending on the client capability `inlayHint.resolveSupport` clients + # might resolve this property late using the resolve request. + # + # @return [TextEdit[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#62 + def text_edits; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#112 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#116 + def to_json(*args); end + + # The tooltip text when you hover over this item. + # + # Depending on the client capability `inlayHint.resolveSupport` clients + # might resolve this property late using the resolve request. + # + # @return [string | MarkupContent] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint.rb#73 + def tooltip; end +end + +# Inlay hint client capabilities. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::InlayHintClientCapabilities + # @return [InlayHintClientCapabilities] a new instance of InlayHintClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb#8 + def initialize(dynamic_registration: T.unsafe(nil), resolve_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb#34 + def attributes; end + + # Whether inlay hints support dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb#21 + def dynamic_registration; end + + # Indicates which properties a client can resolve lazily on an inlay + # hint. + # + # @return [{ properties: string[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb#30 + def resolve_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_client_capabilities.rb#40 + def to_json(*args); end +end + +# An inlay hint label part allows for interactive and composite labels +# of inlay hints. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#8 +class LanguageServer::Protocol::Interface::InlayHintLabelPart + # @return [InlayHintLabelPart] a new instance of InlayHintLabelPart + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#9 + def initialize(value:, tooltip: T.unsafe(nil), location: T.unsafe(nil), command: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#67 + def attributes; end + + # An optional command for this label part. + # + # Depending on the client capability `inlayHint.resolveSupport` clients + # might resolve this property late using the resolve request. + # + # @return [Command] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#63 + def command; end + + # An optional source code location that represents this + # label part. + # + # The editor will use this location for the hover and for code navigation + # features: This part will become a clickable link that resolves to the + # definition of the symbol at the given location (not necessarily the + # location itself), it shows the hover that shows at the given location, + # and it shows a context menu with further code navigation commands. + # + # Depending on the client capability `inlayHint.resolveSupport` clients + # might resolve this property late using the resolve request. + # + # @return [Location] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#52 + def location; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#69 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#73 + def to_json(*args); end + + # The tooltip text when you hover over this label part. Depending on + # the client capability `inlayHint.resolveSupport` clients might resolve + # this property late using the resolve request. + # + # @return [string | MarkupContent] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#34 + def tooltip; end + + # The value of this label part. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_label_part.rb#24 + def value; end +end + +# Inlay hint options used during static registration. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_options.rb#7 +class LanguageServer::Protocol::Interface::InlayHintOptions + # @return [InlayHintOptions] a new instance of InlayHintOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_options.rb#8 + def initialize(work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_options.rb#31 + def attributes; end + + # The server provides support to resolve additional + # information for an inlay hint item. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_options.rb#27 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_options.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_options.rb#37 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_options.rb#18 + def work_done_progress; end +end + +# A parameter literal used in inlay hint requests. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#7 +class LanguageServer::Protocol::Interface::InlayHintParams + # @return [InlayHintParams] a new instance of InlayHintParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#8 + def initialize(text_document:, range:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#42 + def attributes; end + + # The visible document range for which inlay hints should be computed. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#38 + def range; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#30 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#44 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#48 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_params.rb#22 + def work_done_token; end +end + +# Inlay hint options used during static or dynamic registration. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#7 +class LanguageServer::Protocol::Interface::InlayHintRegistrationOptions + # @return [InlayHintRegistrationOptions] a new instance of InlayHintRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#8 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#51 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#38 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#47 + def id; end + + # The server provides support to resolve additional + # information for an inlay hint item. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#29 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#53 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#57 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_registration_options.rb#20 + def work_done_progress; end +end + +# Client workspace capabilities specific to inlay hints. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_workspace_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::InlayHintWorkspaceClientCapabilities + # @return [InlayHintWorkspaceClientCapabilities] a new instance of InlayHintWorkspaceClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_workspace_client_capabilities.rb#8 + def initialize(refresh_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_workspace_client_capabilities.rb#30 + def attributes; end + + # Whether the client implementation supports a refresh request sent from + # the server to the client. + # + # Note that this event is global and will force the client to refresh all + # inlay hints currently shown. It should be used with absolute care and + # is useful for situation where a server for example detects a project wide + # change that requires such a calculation. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_workspace_client_capabilities.rb#26 + def refresh_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_workspace_client_capabilities.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inlay_hint_workspace_client_capabilities.rb#36 + def to_json(*args); end +end + +# Client capabilities specific to inline values. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::InlineValueClientCapabilities + # @return [InlineValueClientCapabilities] a new instance of InlineValueClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_client_capabilities.rb#8 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_client_capabilities.rb#25 + def attributes; end + + # Whether implementation supports dynamic registration for inline + # value providers. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_client_capabilities.rb#21 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_client_capabilities.rb#27 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_client_capabilities.rb#31 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_context.rb#4 +class LanguageServer::Protocol::Interface::InlineValueContext + # @return [InlineValueContext] a new instance of InlineValueContext + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_context.rb#5 + def initialize(frame_id:, stopped_location:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_context.rb#32 + def attributes; end + + # The stack frame (as a DAP Id) where the execution has stopped. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_context.rb#18 + def frame_id; end + + # The document range where execution has stopped. + # Typically the end position of the range denotes the line where the + # inline values are shown. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_context.rb#28 + def stopped_location; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_context.rb#34 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_context.rb#38 + def to_json(*args); end +end + +# Provide an inline value through an expression evaluation. +# +# If only a range is specified, the expression will be extracted from the +# underlying document. +# +# An optional expression can be used to override the extracted expression. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb#12 +class LanguageServer::Protocol::Interface::InlineValueEvaluatableExpression + # @return [InlineValueEvaluatableExpression] a new instance of InlineValueEvaluatableExpression + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb#13 + def initialize(range:, expression: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb#40 + def attributes; end + + # If specified the expression overrides the extracted expression. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb#36 + def expression; end + + # The document range for which the inline value applies. + # The range is used to extract the evaluatable expression from the + # underlying document. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb#28 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_evaluatable_expression.rb#46 + def to_json(*args); end +end + +# Inline value options used during static registration. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_options.rb#7 +class LanguageServer::Protocol::Interface::InlineValueOptions + # @return [InlineValueOptions] a new instance of InlineValueOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_options.rb#8 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_options.rb#21 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_options.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_options.rb#27 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_options.rb#17 + def work_done_progress; end +end + +# A parameter literal used in inline value requests. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#7 +class LanguageServer::Protocol::Interface::InlineValueParams + # @return [InlineValueParams] a new instance of InlineValueParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#8 + def initialize(text_document:, range:, context:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#52 + def attributes; end + + # Additional information about the context in which inline values were + # requested. + # + # @return [InlineValueContext] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#48 + def context; end + + # The document range for which inline values should be computed. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#39 + def range; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#31 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#54 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#58 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_params.rb#23 + def work_done_token; end +end + +# Inline value options used during static or dynamic registration. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#7 +class LanguageServer::Protocol::Interface::InlineValueRegistrationOptions + # @return [InlineValueRegistrationOptions] a new instance of InlineValueRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#8 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#41 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#28 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#37 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#43 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#47 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_registration_options.rb#19 + def work_done_progress; end +end + +# Provide inline value as text. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_text.rb#7 +class LanguageServer::Protocol::Interface::InlineValueText + # @return [InlineValueText] a new instance of InlineValueText + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_text.rb#8 + def initialize(range:, text:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_text.rb#33 + def attributes; end + + # The document range for which the inline value applies. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_text.rb#21 + def range; end + + # The text of the inline value. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_text.rb#29 + def text; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_text.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_text.rb#39 + def to_json(*args); end +end + +# Provide inline value through a variable lookup. +# +# If only a range is specified, the variable name will be extracted from +# the underlying document. +# +# An optional variable name can be used to override the extracted name. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#12 +class LanguageServer::Protocol::Interface::InlineValueVariableLookup + # @return [InlineValueVariableLookup] a new instance of InlineValueVariableLookup + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#13 + def initialize(range:, case_sensitive_lookup:, variable_name: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#49 + def attributes; end + + # How to perform the lookup. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#45 + def case_sensitive_lookup; end + + # The document range for which the inline value applies. + # The range is used to extract the variable name from the underlying + # document. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#29 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#55 + def to_json(*args); end + + # If specified the name of the variable to look up. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_variable_lookup.rb#37 + def variable_name; end +end + +# Client workspace capabilities specific to inline values. +# +# source://language_server-protocol//lib/language_server/protocol/interface/inline_value_workspace_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::InlineValueWorkspaceClientCapabilities + # @return [InlineValueWorkspaceClientCapabilities] a new instance of InlineValueWorkspaceClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_workspace_client_capabilities.rb#8 + def initialize(refresh_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_workspace_client_capabilities.rb#30 + def attributes; end + + # Whether the client implementation supports a refresh request sent from + # the server to the client. + # + # Note that this event is global and will force the client to refresh all + # inline values currently shown. It should be used with absolute care and + # is useful for situation where a server for example detect a project wide + # change that requires such a calculation. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_workspace_client_capabilities.rb#26 + def refresh_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_workspace_client_capabilities.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/inline_value_workspace_client_capabilities.rb#36 + def to_json(*args); end +end + +# A special text edit to provide an insert and a replace operation. +# +# source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#7 +class LanguageServer::Protocol::Interface::InsertReplaceEdit + # @return [InsertReplaceEdit] a new instance of InsertReplaceEdit + # + # source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#8 + def initialize(new_text:, insert:, replace:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#42 + def attributes; end + + # The range if the insert is requested + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#30 + def insert; end + + # The string to be inserted. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#22 + def new_text; end + + # The range if the replace is requested. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#38 + def replace; end + + # source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#44 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/insert_replace_edit.rb#48 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::LinkedEditingRangeClientCapabilities + # @return [LinkedEditingRangeClientCapabilities] a new instance of LinkedEditingRangeClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_client_capabilities.rb#24 + def attributes; end + + # Whether the implementation supports dynamic registration. + # If this is set to `true` the client supports the new + # `(TextDocumentRegistrationOptions & StaticRegistrationOptions)` + # return value for the corresponding server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_client_capabilities.rb#20 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_client_capabilities.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_client_capabilities.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_options.rb#4 +class LanguageServer::Protocol::Interface::LinkedEditingRangeOptions + # @return [LinkedEditingRangeOptions] a new instance of LinkedEditingRangeOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#4 +class LanguageServer::Protocol::Interface::LinkedEditingRangeParams + # @return [LinkedEditingRangeParams] a new instance of LinkedEditingRangeParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#39 + def attributes; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#27 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#19 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#45 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_params.rb#35 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#4 +class LanguageServer::Protocol::Interface::LinkedEditingRangeRegistrationOptions + # @return [LinkedEditingRangeRegistrationOptions] a new instance of LinkedEditingRangeRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#20 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_range_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_ranges.rb#4 +class LanguageServer::Protocol::Interface::LinkedEditingRanges + # @return [LinkedEditingRanges] a new instance of LinkedEditingRanges + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_ranges.rb#5 + def initialize(ranges:, word_pattern: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_ranges.rb#34 + def attributes; end + + # A list of ranges that can be renamed together. The ranges must have + # identical length and contain identical text content. The ranges cannot + # overlap. + # + # @return [Range[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_ranges.rb#20 + def ranges; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_ranges.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_ranges.rb#40 + def to_json(*args); end + + # An optional word pattern (regular expression) that describes valid + # contents for the given ranges. If no pattern is provided, the client + # configuration's word pattern will be used. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/linked_editing_ranges.rb#30 + def word_pattern; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/location.rb#4 +class LanguageServer::Protocol::Interface::Location + # @return [Location] a new instance of Location + # + # source://language_server-protocol//lib/language_server/protocol/interface/location.rb#5 + def initialize(uri:, range:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/location.rb#24 + def attributes; end + + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/location.rb#20 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/location.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/location.rb#30 + def to_json(*args); end + + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/location.rb#15 + def uri; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#4 +class LanguageServer::Protocol::Interface::LocationLink + # @return [LocationLink] a new instance of LocationLink + # + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#5 + def initialize(target_uri:, target_range:, target_selection_range:, origin_selection_range: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#56 + def attributes; end + + # Span of the origin of this link. + # + # Used as the underlined span for mouse interaction. Defaults to the word + # range at the mouse position. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#23 + def origin_selection_range; end + + # The full target range of this link. If the target for example is a symbol + # then target range is the range enclosing this symbol not including + # leading/trailing whitespace but everything else like comments. This + # information is typically used to highlight the range in the editor. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#42 + def target_range; end + + # The range that should be selected and revealed when this link is being + # followed, e.g the name of a function. Must be contained by the + # `targetRange`. See also `DocumentSymbol#range` + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#52 + def target_selection_range; end + + # The target resource identifier of this link. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#31 + def target_uri; end + + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#58 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/location_link.rb#62 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/log_message_params.rb#4 +class LanguageServer::Protocol::Interface::LogMessageParams + # @return [LogMessageParams] a new instance of LogMessageParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_message_params.rb#5 + def initialize(type:, message:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_message_params.rb#30 + def attributes; end + + # The actual message + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_message_params.rb#26 + def message; end + + # source://language_server-protocol//lib/language_server/protocol/interface/log_message_params.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/log_message_params.rb#36 + def to_json(*args); end + + # The message type. See {@link MessageType} + # + # @return [MessageType] + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_message_params.rb#18 + def type; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/log_trace_params.rb#4 +class LanguageServer::Protocol::Interface::LogTraceParams + # @return [LogTraceParams] a new instance of LogTraceParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_trace_params.rb#5 + def initialize(message:, verbose: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_trace_params.rb#31 + def attributes; end + + # The message to be logged. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_trace_params.rb#18 + def message; end + + # source://language_server-protocol//lib/language_server/protocol/interface/log_trace_params.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/log_trace_params.rb#37 + def to_json(*args); end + + # Additional information that can be computed if the `trace` configuration + # is set to `'verbose'` + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/log_trace_params.rb#27 + def verbose; end +end + +# A `MarkupContent` literal represents a string value which content is +# interpreted base on its kind flag. Currently the protocol supports +# `plaintext` and `markdown` as markup kinds. +# +# If the kind is `markdown` then the value can contain fenced code blocks like +# in GitHub issues. +# +# Here is an example how such a string can be constructed using +# JavaScript / TypeScript: +# ```typescript +# let markdown: MarkdownContent = { +# kind: MarkupKind.Markdown, +# value: [ +# '# Header', +# 'Some text', +# '```typescript', +# 'someCode();', +# '```' +# ].join('\n') +# }; +# ``` +# +# *Please Note* that clients might sanitize the return markdown. A client could +# decide to remove HTML from the markdown to avoid script execution. +# +# source://language_server-protocol//lib/language_server/protocol/interface/markup_content.rb#30 +class LanguageServer::Protocol::Interface::MarkupContent + # @return [MarkupContent] a new instance of MarkupContent + # + # source://language_server-protocol//lib/language_server/protocol/interface/markup_content.rb#31 + def initialize(kind:, value:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/markup_content.rb#56 + def attributes; end + + # The type of the Markup + # + # @return [MarkupKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/markup_content.rb#44 + def kind; end + + # source://language_server-protocol//lib/language_server/protocol/interface/markup_content.rb#58 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/markup_content.rb#62 + def to_json(*args); end + + # The content itself + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/markup_content.rb#52 + def value; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/message.rb#4 +class LanguageServer::Protocol::Interface::Message + # @return [Message] a new instance of Message + # + # source://language_server-protocol//lib/language_server/protocol/interface/message.rb#5 + def initialize(jsonrpc:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/message.rb#18 + def attributes; end + + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/message.rb#14 + def jsonrpc; end + + # source://language_server-protocol//lib/language_server/protocol/interface/message.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/message.rb#24 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/message_action_item.rb#4 +class LanguageServer::Protocol::Interface::MessageActionItem + # @return [MessageActionItem] a new instance of MessageActionItem + # + # source://language_server-protocol//lib/language_server/protocol/interface/message_action_item.rb#5 + def initialize(title:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/message_action_item.rb#21 + def attributes; end + + # A short title like 'Retry', 'Open Log' etc. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/message_action_item.rb#17 + def title; end + + # source://language_server-protocol//lib/language_server/protocol/interface/message_action_item.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/message_action_item.rb#27 + def to_json(*args); end +end + +# Moniker definition to match LSIF 0.5 moniker definition. +# +# source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#7 +class LanguageServer::Protocol::Interface::Moniker + # @return [Moniker] a new instance of Moniker + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#8 + def initialize(scheme:, identifier:, unique:, kind: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#52 + def attributes; end + + # The identifier of the moniker. The value is opaque in LSIF however + # schema owners are allowed to define the structure if they want. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#32 + def identifier; end + + # The moniker kind if known. + # + # @return [MonikerKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#48 + def kind; end + + # The scheme of the moniker. For example tsc or .Net + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#23 + def scheme; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#54 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#58 + def to_json(*args); end + + # The scope in which the moniker is unique + # + # @return [UniquenessLevel] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker.rb#40 + def unique; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/moniker_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::MonikerClientCapabilities + # @return [MonikerClientCapabilities] a new instance of MonikerClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_client_capabilities.rb#24 + def attributes; end + + # Whether implementation supports dynamic registration. If this is set to + # `true` the client supports the new `(TextDocumentRegistrationOptions & + # StaticRegistrationOptions)` return value for the corresponding server + # capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_client_capabilities.rb#20 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_client_capabilities.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_client_capabilities.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/moniker_options.rb#4 +class LanguageServer::Protocol::Interface::MonikerOptions + # @return [MonikerOptions] a new instance of MonikerOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#4 +class LanguageServer::Protocol::Interface::MonikerParams + # @return [MonikerParams] a new instance of MonikerParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#45 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/moniker_registration_options.rb#4 +class LanguageServer::Protocol::Interface::MonikerRegistrationOptions + # @return [MonikerRegistrationOptions] a new instance of MonikerRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_registration_options.rb#28 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_registration_options.rb#19 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/moniker_registration_options.rb#24 + def work_done_progress; end +end + +# A notebook cell. +# +# A cell's document URI must be unique across ALL notebook +# cells and can therefore be used to uniquely identify a +# notebook cell or the cell's text document. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#11 +class LanguageServer::Protocol::Interface::NotebookCell + # @return [NotebookCell] a new instance of NotebookCell + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#12 + def initialize(kind:, document:, metadata: T.unsafe(nil), execution_summary: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#57 + def attributes; end + + # The URI of the cell's text document + # content. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#36 + def document; end + + # Additional execution summary information + # if supported by the client. + # + # @return [ExecutionSummary] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#53 + def execution_summary; end + + # The cell's kind + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#27 + def kind; end + + # Additional metadata stored with the cell. + # + # @return [LSPObject] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#44 + def metadata; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#59 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell.rb#63 + def to_json(*args); end +end + +# A change describing how to move a `NotebookCell` +# array from state S to S'. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#8 +class LanguageServer::Protocol::Interface::NotebookCellArrayChange + # @return [NotebookCellArrayChange] a new instance of NotebookCellArrayChange + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#9 + def initialize(start:, delete_count:, cells: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#43 + def attributes; end + + # The new cells, if any + # + # @return [NotebookCell[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#39 + def cells; end + + # The deleted cells + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#31 + def delete_count; end + + # The start offset of the cell that changed. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#23 + def start; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#45 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_array_change.rb#49 + def to_json(*args); end +end + +# A notebook cell text document filter denotes a cell text +# document by different properties. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb#8 +class LanguageServer::Protocol::Interface::NotebookCellTextDocumentFilter + # @return [NotebookCellTextDocumentFilter] a new instance of NotebookCellTextDocumentFilter + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb#9 + def initialize(notebook:, language: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb#40 + def attributes; end + + # A language id like `python`. + # + # Will be matched against the language id of the + # notebook cell document. '*' matches every language. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb#36 + def language; end + + # A filter that matches against the notebook + # containing the notebook cell. If a string + # value is provided it matches against the + # notebook type. '*' matches every notebook. + # + # @return [string | NotebookDocumentFilter] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb#25 + def notebook; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_cell_text_document_filter.rb#46 + def to_json(*args); end +end + +# A notebook document. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#7 +class LanguageServer::Protocol::Interface::NotebookDocument + # @return [NotebookDocument] a new instance of NotebookDocument + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#8 + def initialize(uri:, notebook_type:, version:, cells:, metadata: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#62 + def attributes; end + + # The cells of a notebook. + # + # @return [NotebookCell[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#58 + def cells; end + + # Additional metadata stored with the notebook + # document. + # + # @return [LSPObject] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#50 + def metadata; end + + # The type of the notebook. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#32 + def notebook_type; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#64 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#68 + def to_json(*args); end + + # The notebook document's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#24 + def uri; end + + # The version number of this document (it will increase after each + # change, including undo/redo). + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document.rb#41 + def version; end +end + +# A change event for a notebook document. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_change_event.rb#7 +class LanguageServer::Protocol::Interface::NotebookDocumentChangeEvent + # @return [NotebookDocumentChangeEvent] a new instance of NotebookDocumentChangeEvent + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_change_event.rb#8 + def initialize(metadata: T.unsafe(nil), cells: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_change_event.rb#33 + def attributes; end + + # Changes to cells + # + # @return [{ structure?: { array: NotebookCellArrayChange; didOpen?: TextDocumentItem[]; didClose?: TextDocumentIdentifier[]; }; data?: NotebookCell[]; textContent?: { ...; }[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_change_event.rb#29 + def cells; end + + # The changed meta data if any. + # + # @return [LSPObject] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_change_event.rb#21 + def metadata; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_change_event.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_change_event.rb#39 + def to_json(*args); end +end + +# Capabilities specific to the notebook document support. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::NotebookDocumentClientCapabilities + # @return [NotebookDocumentClientCapabilities] a new instance of NotebookDocumentClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_client_capabilities.rb#8 + def initialize(synchronization:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_client_capabilities.rb#24 + def attributes; end + + # Capabilities specific to notebook document synchronization + # + # @return [NotebookDocumentSyncClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_client_capabilities.rb#20 + def synchronization; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_client_capabilities.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_client_capabilities.rb#30 + def to_json(*args); end +end + +# A notebook document filter denotes a notebook document by +# different properties. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#8 +class LanguageServer::Protocol::Interface::NotebookDocumentFilter + # @return [NotebookDocumentFilter] a new instance of NotebookDocumentFilter + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#9 + def initialize(notebook_type: T.unsafe(nil), scheme: T.unsafe(nil), pattern: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#67 + def attributes; end + + # The type of the enclosing notebook. + # + # --- OR --- + # + # The type of the enclosing notebook. + # + # --- OR --- + # + # The type of the enclosing notebook. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#31 + def notebook_type; end + + # A glob pattern. + # + # --- OR --- + # + # A glob pattern. + # + # --- OR --- + # + # A glob pattern. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#63 + def pattern; end + + # A Uri [scheme](#Uri.scheme), like `file` or `untitled`. + # + # --- OR --- + # + # A Uri [scheme](#Uri.scheme), like `file` or `untitled`. + # + # --- OR --- + # + # A Uri [scheme](#Uri.scheme), like `file` or `untitled`. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#47 + def scheme; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#69 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_filter.rb#73 + def to_json(*args); end +end + +# A literal to identify a notebook document in the client. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_identifier.rb#7 +class LanguageServer::Protocol::Interface::NotebookDocumentIdentifier + # @return [NotebookDocumentIdentifier] a new instance of NotebookDocumentIdentifier + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_identifier.rb#8 + def initialize(uri:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_identifier.rb#24 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_identifier.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_identifier.rb#30 + def to_json(*args); end + + # The notebook document's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_identifier.rb#20 + def uri; end +end + +# Notebook specific client capabilities. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::NotebookDocumentSyncClientCapabilities + # @return [NotebookDocumentSyncClientCapabilities] a new instance of NotebookDocumentSyncClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb#8 + def initialize(dynamic_registration: T.unsafe(nil), execution_summary_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb#36 + def attributes; end + + # Whether implementation supports dynamic registration. If this is + # set to `true` the client supports the new + # `(TextDocumentRegistrationOptions & StaticRegistrationOptions)` + # return value for the corresponding server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb#24 + def dynamic_registration; end + + # The client supports sending execution summary data per cell. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb#32 + def execution_summary_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb#38 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_client_capabilities.rb#42 + def to_json(*args); end +end + +# Options specific to a notebook plus its cells +# to be synced to the server. +# +# If a selector provides a notebook document +# filter but no cell selector all cells of a +# matching notebook document will be synced. +# +# If a selector provides no notebook document +# filter but only a cell selector all notebook +# documents that contain at least one matching +# cell will be synced. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_options.rb#17 +class LanguageServer::Protocol::Interface::NotebookDocumentSyncOptions + # @return [NotebookDocumentSyncOptions] a new instance of NotebookDocumentSyncOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_options.rb#18 + def initialize(notebook_selector:, save: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_options.rb#44 + def attributes; end + + # The notebooks to be synced + # + # @return [({ notebook: string | NotebookDocumentFilter; cells?: { language: string; }[]; } | { notebook?: string | NotebookDocumentFilter; cells: { ...; }[]; })[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_options.rb#31 + def notebook_selector; end + + # Whether save notification should be forwarded to + # the server. Will only be honored if mode === `notebook`. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_options.rb#40 + def save; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_options.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_options.rb#50 + def to_json(*args); end +end + +# Registration options specific to a notebook. +# +# source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#7 +class LanguageServer::Protocol::Interface::NotebookDocumentSyncRegistrationOptions + # @return [NotebookDocumentSyncRegistrationOptions] a new instance of NotebookDocumentSyncRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#8 + def initialize(notebook_selector:, save: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#44 + def attributes; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#40 + def id; end + + # The notebooks to be synced + # + # @return [({ notebook: string | NotebookDocumentFilter; cells?: { language: string; }[]; } | { notebook?: string | NotebookDocumentFilter; cells: { ...; }[]; })[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#22 + def notebook_selector; end + + # Whether save notification should be forwarded to + # the server. Will only be honored if mode === `notebook`. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#31 + def save; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notebook_document_sync_registration_options.rb#50 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#4 +class LanguageServer::Protocol::Interface::NotificationMessage + # @return [NotificationMessage] a new instance of NotificationMessage + # + # source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#5 + def initialize(jsonrpc:, method:, params: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#36 + def attributes; end + + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#16 + def jsonrpc; end + + # The method to be invoked. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#24 + def method; end + + # The notification's params. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#32 + def params; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#38 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/notification_message.rb#42 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb#4 +class LanguageServer::Protocol::Interface::OptionalVersionedTextDocumentIdentifier + # @return [OptionalVersionedTextDocumentIdentifier] a new instance of OptionalVersionedTextDocumentIdentifier + # + # source://language_server-protocol//lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb#5 + def initialize(uri:, version:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb#38 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb#44 + def to_json(*args); end + + # The text document's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb#18 + def uri; end + + # The version number of this document. If an optional versioned text document + # identifier is sent from the server to the client and the file is not + # open in the editor (the server has not received an open notification + # before) the server can send `null` to indicate that the version is + # known and the content on disk is the master (as specified with document + # content ownership). + # + # The version number of a document will increase after each change, + # including undo/redo. The number doesn't need to be consecutive. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/optional_versioned_text_document_identifier.rb#34 + def version; end +end + +# Represents a parameter of a callable-signature. A parameter can +# have a label and a doc-comment. +# +# source://language_server-protocol//lib/language_server/protocol/interface/parameter_information.rb#8 +class LanguageServer::Protocol::Interface::ParameterInformation + # @return [ParameterInformation] a new instance of ParameterInformation + # + # source://language_server-protocol//lib/language_server/protocol/interface/parameter_information.rb#9 + def initialize(label:, documentation: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/parameter_information.rb#44 + def attributes; end + + # The human-readable doc-comment of this parameter. Will be shown + # in the UI but can be omitted. + # + # @return [string | MarkupContent] + # + # source://language_server-protocol//lib/language_server/protocol/interface/parameter_information.rb#40 + def documentation; end + + # The label of this parameter information. + # + # Either a string or an inclusive start and exclusive end offsets within + # its containing signature label. (see SignatureInformation.label). The + # offsets are based on a UTF-16 string representation as `Position` and + # `Range` does. + # + # *Note*: a label of type string should be a substring of its containing + # signature label. Its intended use case is to highlight the parameter + # label part in the `SignatureInformation.label`. + # + # @return [string | [number, number]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/parameter_information.rb#31 + def label; end + + # source://language_server-protocol//lib/language_server/protocol/interface/parameter_information.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/parameter_information.rb#50 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/partial_result_params.rb#4 +class LanguageServer::Protocol::Interface::PartialResultParams + # @return [PartialResultParams] a new instance of PartialResultParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/partial_result_params.rb#5 + def initialize(partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/partial_result_params.rb#22 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/partial_result_params.rb#18 + def partial_result_token; end + + # source://language_server-protocol//lib/language_server/protocol/interface/partial_result_params.rb#24 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/partial_result_params.rb#28 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/position.rb#4 +class LanguageServer::Protocol::Interface::Position + # @return [Position] a new instance of Position + # + # source://language_server-protocol//lib/language_server/protocol/interface/position.rb#5 + def initialize(line:, character:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/position.rb#34 + def attributes; end + + # Character offset on a line in a document (zero-based). The meaning of this + # offset is determined by the negotiated `PositionEncodingKind`. + # + # If the character value is greater than the line length it defaults back + # to the line length. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/position.rb#30 + def character; end + + # Line position in a document (zero-based). + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/position.rb#18 + def line; end + + # source://language_server-protocol//lib/language_server/protocol/interface/position.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/position.rb#40 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#4 +class LanguageServer::Protocol::Interface::PrepareRenameParams + # @return [PrepareRenameParams] a new instance of PrepareRenameParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#39 + def attributes; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#27 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#19 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#45 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/prepare_rename_params.rb#35 + def work_done_token; end +end + +# A previous result id in a workspace pull request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/previous_result_id.rb#7 +class LanguageServer::Protocol::Interface::PreviousResultId + # @return [PreviousResultId] a new instance of PreviousResultId + # + # source://language_server-protocol//lib/language_server/protocol/interface/previous_result_id.rb#8 + def initialize(uri:, value:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/previous_result_id.rb#34 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/previous_result_id.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/previous_result_id.rb#40 + def to_json(*args); end + + # The URI for which the client knows a + # result id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/previous_result_id.rb#22 + def uri; end + + # The value of the previous result id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/previous_result_id.rb#30 + def value; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/progress_params.rb#4 +class LanguageServer::Protocol::Interface::ProgressParams + # @return [ProgressParams] a new instance of ProgressParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/progress_params.rb#5 + def initialize(token:, value:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/progress_params.rb#30 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/progress_params.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/progress_params.rb#36 + def to_json(*args); end + + # The progress token provided by the client or server. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/progress_params.rb#18 + def token; end + + # The progress data. + # + # @return [T] + # + # source://language_server-protocol//lib/language_server/protocol/interface/progress_params.rb#26 + def value; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::PublishDiagnosticsClientCapabilities + # @return [PublishDiagnosticsClientCapabilities] a new instance of PublishDiagnosticsClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#5 + def initialize(related_information: T.unsafe(nil), tag_support: T.unsafe(nil), version_support: T.unsafe(nil), code_description_support: T.unsafe(nil), data_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#61 + def attributes; end + + # Client supports a codeDescription property + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#47 + def code_description_support; end + + # Whether code action supports the `data` property which is + # preserved between a `textDocument/publishDiagnostics` and + # `textDocument/codeAction` request. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#57 + def data_support; end + + # Whether the clients accepts diagnostics with related information. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#21 + def related_information; end + + # Client supports the tag property to provide meta data about a diagnostic. + # Clients supporting tags have to handle unknown tags gracefully. + # + # @return [{ valueSet: DiagnosticTag[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#30 + def tag_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#63 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#67 + def to_json(*args); end + + # Whether the client interprets the version property of the + # `textDocument/publishDiagnostics` notification's parameter. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_client_capabilities.rb#39 + def version_support; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#4 +class LanguageServer::Protocol::Interface::PublishDiagnosticsParams + # @return [PublishDiagnosticsParams] a new instance of PublishDiagnosticsParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#5 + def initialize(uri:, diagnostics:, version: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#40 + def attributes; end + + # An array of diagnostic information items. + # + # @return [Diagnostic[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#36 + def diagnostics; end + + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#46 + def to_json(*args); end + + # The URI for which diagnostic information is reported. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#19 + def uri; end + + # Optional the version number of the document the diagnostics are published + # for. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/publish_diagnostics_params.rb#28 + def version; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/range.rb#4 +class LanguageServer::Protocol::Interface::Range + # @return [Range] a new instance of Range + # + # source://language_server-protocol//lib/language_server/protocol/interface/range.rb#5 + def initialize(start:, end:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/range.rb#30 + def attributes; end + + # The range's end position. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/range.rb#26 + def end; end + + # The range's start position. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/range.rb#18 + def start; end + + # source://language_server-protocol//lib/language_server/protocol/interface/range.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/range.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/reference_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::ReferenceClientCapabilities + # @return [ReferenceClientCapabilities] a new instance of ReferenceClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_client_capabilities.rb#21 + def attributes; end + + # Whether references supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_client_capabilities.rb#17 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_client_capabilities.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_client_capabilities.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/reference_context.rb#4 +class LanguageServer::Protocol::Interface::ReferenceContext + # @return [ReferenceContext] a new instance of ReferenceContext + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_context.rb#5 + def initialize(include_declaration:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_context.rb#21 + def attributes; end + + # Include the declaration of the current symbol. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_context.rb#17 + def include_declaration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_context.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_context.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/reference_options.rb#4 +class LanguageServer::Protocol::Interface::ReferenceOptions + # @return [ReferenceOptions] a new instance of ReferenceOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#4 +class LanguageServer::Protocol::Interface::ReferenceParams + # @return [ReferenceParams] a new instance of ReferenceParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#5 + def initialize(text_document:, position:, context:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#55 + def attributes; end + + # @return [ReferenceContext] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#51 + def context; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#46 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#29 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#21 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#57 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#61 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_params.rb#37 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/reference_registration_options.rb#4 +class LanguageServer::Protocol::Interface::ReferenceRegistrationOptions + # @return [ReferenceRegistrationOptions] a new instance of ReferenceRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_registration_options.rb#28 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_registration_options.rb#19 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/reference_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/reference_registration_options.rb#24 + def work_done_progress; end +end + +# General parameters to register for a capability. +# +# source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#7 +class LanguageServer::Protocol::Interface::Registration + # @return [Registration] a new instance of Registration + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#8 + def initialize(id:, method:, register_options: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#43 + def attributes; end + + # The id used to register the request. The id can be used to deregister + # the request again. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#23 + def id; end + + # The method / capability to register for. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#31 + def method; end + + # Options necessary for the registration. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#39 + def register_options; end + + # source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#45 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/registration.rb#49 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/registration_params.rb#4 +class LanguageServer::Protocol::Interface::RegistrationParams + # @return [RegistrationParams] a new instance of RegistrationParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration_params.rb#5 + def initialize(registrations:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration_params.rb#18 + def attributes; end + + # @return [Registration[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/registration_params.rb#14 + def registrations; end + + # source://language_server-protocol//lib/language_server/protocol/interface/registration_params.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/registration_params.rb#24 + def to_json(*args); end +end + +# Client capabilities specific to regular expressions. +# +# source://language_server-protocol//lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::RegularExpressionsClientCapabilities + # @return [RegularExpressionsClientCapabilities] a new instance of RegularExpressionsClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb#8 + def initialize(engine:, version: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb#33 + def attributes; end + + # The engine's name. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb#21 + def engine; end + + # source://language_server-protocol//lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb#39 + def to_json(*args); end + + # The engine's version. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/regular_expressions_client_capabilities.rb#29 + def version; end +end + +# A full diagnostic report with a set of related documents. +# +# source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#7 +class LanguageServer::Protocol::Interface::RelatedFullDocumentDiagnosticReport + # @return [RelatedFullDocumentDiagnosticReport] a new instance of RelatedFullDocumentDiagnosticReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#8 + def initialize(kind:, items:, result_id: T.unsafe(nil), related_documents: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#57 + def attributes; end + + # The actual items. + # + # @return [Diagnostic[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#41 + def items; end + + # A full document diagnostic report. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#23 + def kind; end + + # Diagnostics of related documents. This information is useful + # in programming languages where code in a file A can generate + # diagnostics in a file B which A depends on. An example of + # such a language is C/C++ where marco definitions in a file + # a.cpp and result in errors in a header file b.hpp. + # + # @return [{ [uri: string]: FullDocumentDiagnosticReport | UnchangedDocumentDiagnosticReport; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#53 + def related_documents; end + + # An optional result id. If provided it will + # be sent on the next diagnostic request for the + # same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#33 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#59 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/related_full_document_diagnostic_report.rb#63 + def to_json(*args); end +end + +# An unchanged diagnostic report with a set of related documents. +# +# source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#7 +class LanguageServer::Protocol::Interface::RelatedUnchangedDocumentDiagnosticReport + # @return [RelatedUnchangedDocumentDiagnosticReport] a new instance of RelatedUnchangedDocumentDiagnosticReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#8 + def initialize(kind:, result_id:, related_documents: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#50 + def attributes; end + + # A document diagnostic report indicating + # no changes to the last result. A server can + # only return `unchanged` if result ids are + # provided. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#25 + def kind; end + + # Diagnostics of related documents. This information is useful + # in programming languages where code in a file A can generate + # diagnostics in a file B which A depends on. An example of + # such a language is C/C++ where marco definitions in a file + # a.cpp and result in errors in a header file b.hpp. + # + # @return [{ [uri: string]: FullDocumentDiagnosticReport | UnchangedDocumentDiagnosticReport; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#46 + def related_documents; end + + # A result id which will be sent on the next + # diagnostic request for the same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#34 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#52 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/related_unchanged_document_diagnostic_report.rb#56 + def to_json(*args); end +end + +# A relative pattern is a helper to construct glob patterns that are matched +# relatively to a base URI. The common value for a `baseUri` is a workspace +# folder root, but it can be another absolute URI as well. +# +# source://language_server-protocol//lib/language_server/protocol/interface/relative_pattern.rb#9 +class LanguageServer::Protocol::Interface::RelativePattern + # @return [RelativePattern] a new instance of RelativePattern + # + # source://language_server-protocol//lib/language_server/protocol/interface/relative_pattern.rb#10 + def initialize(base_uri:, pattern:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/relative_pattern.rb#36 + def attributes; end + + # A workspace folder or a base URI to which this pattern will be matched + # against relatively. + # + # @return [string | WorkspaceFolder] + # + # source://language_server-protocol//lib/language_server/protocol/interface/relative_pattern.rb#24 + def base_uri; end + + # The actual glob pattern; + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/relative_pattern.rb#32 + def pattern; end + + # source://language_server-protocol//lib/language_server/protocol/interface/relative_pattern.rb#38 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/relative_pattern.rb#42 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::RenameClientCapabilities + # @return [RenameClientCapabilities] a new instance of RenameClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), prepare_support: T.unsafe(nil), prepare_support_default_behavior: T.unsafe(nil), honors_change_annotations: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#57 + def attributes; end + + # Whether rename supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#20 + def dynamic_registration; end + + # Whether the client honors the change annotations in + # text edits and resource operations returned via the + # rename request's workspace edit by for example presenting + # the workspace edit in the user interface and asking + # for confirmation. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#53 + def honors_change_annotations; end + + # Client supports testing for validity of rename operations + # before execution. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#29 + def prepare_support; end + + # Client supports the default behavior result + # (`{ defaultBehavior: boolean }`). + # + # The value indicates the default behavior used by the + # client. + # + # @return [1] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#41 + def prepare_support_default_behavior; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#59 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_client_capabilities.rb#63 + def to_json(*args); end +end + +# Rename file operation +# +# source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#7 +class LanguageServer::Protocol::Interface::RenameFile + # @return [RenameFile] a new instance of RenameFile + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#8 + def initialize(kind:, old_uri:, new_uri:, options: T.unsafe(nil), annotation_id: T.unsafe(nil)); end + + # An optional annotation identifier describing the operation. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#56 + def annotation_id; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#60 + def attributes; end + + # A rename + # + # @return ["rename"] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#24 + def kind; end + + # The new location. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#40 + def new_uri; end + + # The old (existing) location. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#32 + def old_uri; end + + # Rename options. + # + # @return [RenameFileOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#48 + def options; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#62 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file.rb#66 + def to_json(*args); end +end + +# Rename file options +# +# source://language_server-protocol//lib/language_server/protocol/interface/rename_file_options.rb#7 +class LanguageServer::Protocol::Interface::RenameFileOptions + # @return [RenameFileOptions] a new instance of RenameFileOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file_options.rb#8 + def initialize(overwrite: T.unsafe(nil), ignore_if_exists: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file_options.rb#33 + def attributes; end + + # Ignores if target exists. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file_options.rb#29 + def ignore_if_exists; end + + # Overwrite target if existing. Overwrite wins over `ignoreIfExists` + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file_options.rb#21 + def overwrite; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file_options.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_file_options.rb#39 + def to_json(*args); end +end + +# The parameters sent in notifications/requests for user-initiated renames +# of files. +# +# source://language_server-protocol//lib/language_server/protocol/interface/rename_files_params.rb#8 +class LanguageServer::Protocol::Interface::RenameFilesParams + # @return [RenameFilesParams] a new instance of RenameFilesParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_files_params.rb#9 + def initialize(files:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_files_params.rb#26 + def attributes; end + + # An array of all files/folders renamed in this operation. When a folder + # is renamed, only the folder will be included, and not its children. + # + # @return [FileRename[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_files_params.rb#22 + def files; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_files_params.rb#28 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_files_params.rb#32 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/rename_options.rb#4 +class LanguageServer::Protocol::Interface::RenameOptions + # @return [RenameOptions] a new instance of RenameOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), prepare_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_options.rb#27 + def attributes; end + + # Renames should be checked and tested before being executed. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_options.rb#23 + def prepare_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_options.rb#29 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_options.rb#33 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_options.rb#15 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#4 +class LanguageServer::Protocol::Interface::RenameParams + # @return [RenameParams] a new instance of RenameParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#5 + def initialize(text_document:, position:, new_name:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#50 + def attributes; end + + # The new name of the symbol. If the given name is not valid the + # request must return a [ResponseError](#ResponseError) with an + # appropriate message set. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#46 + def new_name; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#52 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#56 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#4 +class LanguageServer::Protocol::Interface::RenameRegistrationOptions + # @return [RenameRegistrationOptions] a new instance of RenameRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), prepare_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#37 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#20 + def document_selector; end + + # Renames should be checked and tested before being executed. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#33 + def prepare_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#43 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/rename_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#4 +class LanguageServer::Protocol::Interface::RequestMessage + # @return [RequestMessage] a new instance of RequestMessage + # + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#5 + def initialize(jsonrpc:, id:, method:, params: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#45 + def attributes; end + + # The request id. + # + # @return [string | number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#25 + def id; end + + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#17 + def jsonrpc; end + + # The method to be invoked. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#33 + def method; end + + # The method's params. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#41 + def params; end + + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#47 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/request_message.rb#51 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#4 +class LanguageServer::Protocol::Interface::ResponseError + # @return [ResponseError] a new instance of ResponseError + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#5 + def initialize(code:, message:, data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#40 + def attributes; end + + # A number indicating the error type that occurred. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#19 + def code; end + + # A primitive or structured value that contains additional + # information about the error. Can be omitted. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#36 + def data; end + + # A string providing a short description of the error. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#27 + def message; end + + # source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/response_error.rb#46 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#4 +class LanguageServer::Protocol::Interface::ResponseMessage + # @return [ResponseMessage] a new instance of ResponseMessage + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#5 + def initialize(jsonrpc:, id:, result: T.unsafe(nil), error: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#46 + def attributes; end + + # The error object in case a request fails. + # + # @return [ResponseError] + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#42 + def error; end + + # The request id. + # + # @return [string | number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#25 + def id; end + + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#17 + def jsonrpc; end + + # The result of a request. This member is REQUIRED on success. + # This member MUST NOT exist if there was an error invoking the method. + # + # @return [string | number | boolean | object] + # + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#34 + def result; end + + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#48 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/response_message.rb#52 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/save_options.rb#4 +class LanguageServer::Protocol::Interface::SaveOptions + # @return [SaveOptions] a new instance of SaveOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/save_options.rb#5 + def initialize(include_text: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/save_options.rb#21 + def attributes; end + + # The client is supposed to include the content on save. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/save_options.rb#17 + def include_text; end + + # source://language_server-protocol//lib/language_server/protocol/interface/save_options.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/save_options.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/selection_range.rb#4 +class LanguageServer::Protocol::Interface::SelectionRange + # @return [SelectionRange] a new instance of SelectionRange + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range.rb#5 + def initialize(range:, parent: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range.rb#31 + def attributes; end + + # The parent selection range containing this range. Therefore + # `parent.range` must contain `this.range`. + # + # @return [SelectionRange] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range.rb#27 + def parent; end + + # The [range](#Range) of this selection range. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range.rb#18 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range.rb#37 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/selection_range_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::SelectionRangeClientCapabilities + # @return [SelectionRangeClientCapabilities] a new instance of SelectionRangeClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_client_capabilities.rb#24 + def attributes; end + + # Whether implementation supports dynamic registration for selection range + # providers. If this is set to `true` the client supports the new + # `SelectionRangeRegistrationOptions` return value for the corresponding + # server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_client_capabilities.rb#20 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_client_capabilities.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_client_capabilities.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/selection_range_options.rb#4 +class LanguageServer::Protocol::Interface::SelectionRangeOptions + # @return [SelectionRangeOptions] a new instance of SelectionRangeOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#4 +class LanguageServer::Protocol::Interface::SelectionRangeParams + # @return [SelectionRangeParams] a new instance of SelectionRangeParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#5 + def initialize(text_document:, positions:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#29 + def partial_result_token; end + + # The positions inside the text document. + # + # @return [Position[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#45 + def positions; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#37 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_params.rb#20 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#4 +class LanguageServer::Protocol::Interface::SelectionRangeRegistrationOptions + # @return [SelectionRangeRegistrationOptions] a new instance of SelectionRangeRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#25 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/selection_range_registration_options.rb#16 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokens + # @return [SemanticTokens] a new instance of SemanticTokens + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens.rb#5 + def initialize(data:, result_id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens.rb#33 + def attributes; end + + # The actual tokens. + # + # @return [number[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens.rb#29 + def data; end + + # An optional result id. If provided and clients support delta updating + # the client will include the result id in the next semantic token request. + # A server can then instead of computing all semantic tokens again simply + # send a delta. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens.rb#21 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens.rb#39 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensClientCapabilities + # @return [SemanticTokensClientCapabilities] a new instance of SemanticTokensClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#5 + def initialize(requests:, token_types:, token_modifiers:, formats:, dynamic_registration: T.unsafe(nil), overlapping_token_support: T.unsafe(nil), multiline_token_support: T.unsafe(nil), server_cancel_support: T.unsafe(nil), augments_syntax_tokens: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#113 + def attributes; end + + # Whether the client uses semantic tokens to augment existing + # syntax tokens. If set to `true` client side created syntax + # tokens and semantic tokens are both used for colorization. If + # set to `false` the client only uses the returned semantic tokens + # for colorization. + # + # If the value is `undefined` then the client behavior is not + # specified. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#109 + def augments_syntax_tokens; end + + # Whether implementation supports dynamic registration. If this is set to + # `true` the client supports the new `(TextDocumentRegistrationOptions & + # StaticRegistrationOptions)` return value for the corresponding server + # capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#28 + def dynamic_registration; end + + # The formats the clients supports. + # + # @return ["relative"[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#67 + def formats; end + + # Whether the client supports tokens that can span multiple lines. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#83 + def multiline_token_support; end + + # Whether the client supports tokens that can overlap each other. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#75 + def overlapping_token_support; end + + # Which requests the client supports and might send to the server + # depending on the server's capability. Please note that clients might not + # show semantic tokens or degrade some of the user experience if a range + # or full request is advertised by the client but not provided by the + # server. If for example the client capability `requests.full` and + # `request.range` are both set to true but the server only provides a + # range provider the client might not render a minimap correctly or might + # even decide to not show any semantic tokens at all. + # + # @return [{ range?: boolean | {}; full?: boolean | { delta?: boolean; }; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#43 + def requests; end + + # Whether the client allows the server to actively cancel a + # semantic token request, e.g. supports returning + # ErrorCodes.ServerCancelled. If a server does the client + # needs to retrigger the request. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#94 + def server_cancel_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#115 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#119 + def to_json(*args); end + + # The token modifiers that the client supports. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#59 + def token_modifiers; end + + # The token types that the client supports. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_client_capabilities.rb#51 + def token_types; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensDelta + # @return [SemanticTokensDelta] a new instance of SemanticTokensDelta + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta.rb#5 + def initialize(edits:, result_id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta.rb#28 + def attributes; end + + # The semantic token edits to transform a previous result into a new + # result. + # + # @return [SemanticTokensEdit[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta.rb#24 + def edits; end + + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta.rb#15 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta.rb#34 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensDeltaParams + # @return [SemanticTokensDeltaParams] a new instance of SemanticTokensDeltaParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#5 + def initialize(text_document:, previous_result_id:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#50 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#29 + def partial_result_token; end + + # The result id of a previous response. The result Id can either point to + # a full response or a delta response depending on what was received last. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#46 + def previous_result_id; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#37 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#52 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#56 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_params.rb#20 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_partial_result.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensDeltaPartialResult + # @return [SemanticTokensDeltaPartialResult] a new instance of SemanticTokensDeltaPartialResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_partial_result.rb#5 + def initialize(edits:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_partial_result.rb#18 + def attributes; end + + # @return [SemanticTokensEdit[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_partial_result.rb#14 + def edits; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_partial_result.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_delta_partial_result.rb#24 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensEdit + # @return [SemanticTokensEdit] a new instance of SemanticTokensEdit + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#5 + def initialize(start:, delete_count:, data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#39 + def attributes; end + + # The elements to insert. + # + # @return [number[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#35 + def data; end + + # The count of elements to remove. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#27 + def delete_count; end + + # The start offset of the edit. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#19 + def start; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_edit.rb#45 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_legend.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensLegend + # @return [SemanticTokensLegend] a new instance of SemanticTokensLegend + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_legend.rb#5 + def initialize(token_types:, token_modifiers:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_legend.rb#30 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_legend.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_legend.rb#36 + def to_json(*args); end + + # The token modifiers a server uses. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_legend.rb#26 + def token_modifiers; end + + # The token types a server uses. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_legend.rb#18 + def token_types; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensOptions + # @return [SemanticTokensOptions] a new instance of SemanticTokensOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#5 + def initialize(legend:, work_done_progress: T.unsafe(nil), range: T.unsafe(nil), full: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#46 + def attributes; end + + # Server supports providing semantic tokens for a full document. + # + # @return [boolean | { delta?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#42 + def full; end + + # The legend used by the server + # + # @return [SemanticTokensLegend] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#25 + def legend; end + + # Server supports providing semantic tokens for a specific range + # of a document. + # + # @return [boolean | {}] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#34 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#48 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#52 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_options.rb#17 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensParams + # @return [SemanticTokensParams] a new instance of SemanticTokensParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#5 + def initialize(text_document:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#40 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#28 + def partial_result_token; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#36 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#42 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#46 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_partial_result.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensPartialResult + # @return [SemanticTokensPartialResult] a new instance of SemanticTokensPartialResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_partial_result.rb#5 + def initialize(data:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_partial_result.rb#18 + def attributes; end + + # @return [number[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_partial_result.rb#14 + def data; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_partial_result.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_partial_result.rb#24 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensRangeParams + # @return [SemanticTokensRangeParams] a new instance of SemanticTokensRangeParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#5 + def initialize(text_document:, range:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#29 + def partial_result_token; end + + # The range the semantic tokens are requested for. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#45 + def range; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#37 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_range_params.rb#20 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensRegistrationOptions + # @return [SemanticTokensRegistrationOptions] a new instance of SemanticTokensRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#5 + def initialize(document_selector:, legend:, work_done_progress: T.unsafe(nil), range: T.unsafe(nil), full: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#66 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#23 + def document_selector; end + + # Server supports providing semantic tokens for a full document. + # + # @return [boolean | { delta?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#53 + def full; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#62 + def id; end + + # The legend used by the server + # + # @return [SemanticTokensLegend] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#36 + def legend; end + + # Server supports providing semantic tokens for a specific range + # of a document. + # + # @return [boolean | {}] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#45 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#68 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#72 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_registration_options.rb#28 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_workspace_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::SemanticTokensWorkspaceClientCapabilities + # @return [SemanticTokensWorkspaceClientCapabilities] a new instance of SemanticTokensWorkspaceClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_workspace_client_capabilities.rb#5 + def initialize(refresh_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_workspace_client_capabilities.rb#27 + def attributes; end + + # Whether the client implementation supports a refresh request sent from + # the server to the client. + # + # Note that this event is global and will force the client to refresh all + # semantic tokens currently shown. It should be used with absolute care + # and is useful for situation where a server for example detect a project + # wide change that requires such a calculation. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_workspace_client_capabilities.rb#23 + def refresh_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_workspace_client_capabilities.rb#29 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/semantic_tokens_workspace_client_capabilities.rb#33 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#4 +class LanguageServer::Protocol::Interface::ServerCapabilities + # @return [ServerCapabilities] a new instance of ServerCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#5 + def initialize(position_encoding: T.unsafe(nil), text_document_sync: T.unsafe(nil), notebook_document_sync: T.unsafe(nil), completion_provider: T.unsafe(nil), hover_provider: T.unsafe(nil), signature_help_provider: T.unsafe(nil), declaration_provider: T.unsafe(nil), definition_provider: T.unsafe(nil), type_definition_provider: T.unsafe(nil), implementation_provider: T.unsafe(nil), references_provider: T.unsafe(nil), document_highlight_provider: T.unsafe(nil), document_symbol_provider: T.unsafe(nil), code_action_provider: T.unsafe(nil), code_lens_provider: T.unsafe(nil), document_link_provider: T.unsafe(nil), color_provider: T.unsafe(nil), document_formatting_provider: T.unsafe(nil), document_range_formatting_provider: T.unsafe(nil), document_on_type_formatting_provider: T.unsafe(nil), rename_provider: T.unsafe(nil), folding_range_provider: T.unsafe(nil), execute_command_provider: T.unsafe(nil), selection_range_provider: T.unsafe(nil), linked_editing_range_provider: T.unsafe(nil), call_hierarchy_provider: T.unsafe(nil), semantic_tokens_provider: T.unsafe(nil), moniker_provider: T.unsafe(nil), type_hierarchy_provider: T.unsafe(nil), inline_value_provider: T.unsafe(nil), inlay_hint_provider: T.unsafe(nil), diagnostic_provider: T.unsafe(nil), workspace_symbol_provider: T.unsafe(nil), workspace: T.unsafe(nil), experimental: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#340 + def attributes; end + + # The server provides call hierarchy support. + # + # @return [boolean | CallHierarchyOptions | CallHierarchyRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#264 + def call_hierarchy_provider; end + + # The server provides code actions. The `CodeActionOptions` return type is + # only valid if the client signals code action literal support via the + # property `textDocument.codeAction.codeActionLiteralSupport`. + # + # @return [boolean | CodeActionOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#166 + def code_action_provider; end + + # The server provides code lens. + # + # @return [CodeLensOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#174 + def code_lens_provider; end + + # The server provides color provider support. + # + # @return [boolean | DocumentColorOptions | DocumentColorRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#190 + def color_provider; end + + # The server provides completion support. + # + # @return [CompletionOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#84 + def completion_provider; end + + # The server provides go to declaration support. + # + # @return [boolean | DeclarationOptions | DeclarationRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#108 + def declaration_provider; end + + # The server provides goto definition support. + # + # @return [boolean | DefinitionOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#116 + def definition_provider; end + + # The server has support for pull model diagnostics. + # + # @return [DiagnosticOptions | DiagnosticRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#312 + def diagnostic_provider; end + + # The server provides document formatting. + # + # @return [boolean | DocumentFormattingOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#198 + def document_formatting_provider; end + + # The server provides document highlight support. + # + # @return [boolean | DocumentHighlightOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#148 + def document_highlight_provider; end + + # The server provides document link support. + # + # @return [DocumentLinkOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#182 + def document_link_provider; end + + # The server provides document formatting on typing. + # + # @return [DocumentOnTypeFormattingOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#214 + def document_on_type_formatting_provider; end + + # The server provides document range formatting. + # + # @return [boolean | DocumentRangeFormattingOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#206 + def document_range_formatting_provider; end + + # The server provides document symbol support. + # + # @return [boolean | DocumentSymbolOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#156 + def document_symbol_provider; end + + # The server provides execute command support. + # + # @return [ExecuteCommandOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#240 + def execute_command_provider; end + + # Experimental server capabilities. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#336 + def experimental; end + + # The server provides folding provider support. + # + # @return [boolean | FoldingRangeOptions | FoldingRangeRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#232 + def folding_range_provider; end + + # The server provides hover support. + # + # @return [boolean | HoverOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#92 + def hover_provider; end + + # The server provides goto implementation support. + # + # @return [boolean | ImplementationOptions | ImplementationRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#132 + def implementation_provider; end + + # The server provides inlay hints. + # + # @return [boolean | InlayHintOptions | InlayHintRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#304 + def inlay_hint_provider; end + + # The server provides inline values. + # + # @return [boolean | InlineValueOptions | InlineValueRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#296 + def inline_value_provider; end + + # The server provides linked editing range support. + # + # @return [boolean | LinkedEditingRangeOptions | LinkedEditingRangeRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#256 + def linked_editing_range_provider; end + + # Whether server provides moniker support. + # + # @return [boolean | MonikerOptions | MonikerRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#280 + def moniker_provider; end + + # Defines how notebook documents are synced. + # + # @return [NotebookDocumentSyncOptions | NotebookDocumentSyncRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#76 + def notebook_document_sync; end + + # The position encoding the server picked from the encodings offered + # by the client via the client capability `general.positionEncodings`. + # + # If the client didn't provide any position encodings the only valid + # value that a server can return is 'utf-16'. + # + # If omitted it defaults to 'utf-16'. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#57 + def position_encoding; end + + # The server provides find references support. + # + # @return [boolean | ReferenceOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#140 + def references_provider; end + + # The server provides rename support. RenameOptions may only be + # specified if the client states that it supports + # `prepareSupport` in its initial `initialize` request. + # + # @return [boolean | RenameOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#224 + def rename_provider; end + + # The server provides selection range support. + # + # @return [boolean | SelectionRangeOptions | SelectionRangeRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#248 + def selection_range_provider; end + + # The server provides semantic tokens support. + # + # @return [SemanticTokensOptions | SemanticTokensRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#272 + def semantic_tokens_provider; end + + # The server provides signature help support. + # + # @return [SignatureHelpOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#100 + def signature_help_provider; end + + # Defines how text documents are synced. Is either a detailed structure + # defining each notification or for backwards compatibility the + # TextDocumentSyncKind number. If omitted it defaults to + # `TextDocumentSyncKind.None`. + # + # @return [TextDocumentSyncOptions | TextDocumentSyncKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#68 + def text_document_sync; end + + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#342 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#346 + def to_json(*args); end + + # The server provides goto type definition support. + # + # @return [boolean | TypeDefinitionOptions | TypeDefinitionRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#124 + def type_definition_provider; end + + # The server provides type hierarchy support. + # + # @return [boolean | TypeHierarchyOptions | TypeHierarchyRegistrationOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#288 + def type_hierarchy_provider; end + + # Workspace specific server capabilities + # + # @return [{ workspaceFolders?: WorkspaceFoldersServerCapabilities; fileOperations?: { didCreate?: FileOperationRegistrationOptions; ... 4 more ...; willDelete?: FileOperationRegistrationOptions; }; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#328 + def workspace; end + + # The server provides workspace symbol support. + # + # @return [boolean | WorkspaceSymbolOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/server_capabilities.rb#320 + def workspace_symbol_provider; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/set_trace_params.rb#4 +class LanguageServer::Protocol::Interface::SetTraceParams + # @return [SetTraceParams] a new instance of SetTraceParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/set_trace_params.rb#5 + def initialize(value:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/set_trace_params.rb#21 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/set_trace_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/set_trace_params.rb#27 + def to_json(*args); end + + # The new value that should be assigned to the trace setting. + # + # @return [TraceValue] + # + # source://language_server-protocol//lib/language_server/protocol/interface/set_trace_params.rb#17 + def value; end +end + +# Client capabilities for the show document request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/show_document_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::ShowDocumentClientCapabilities + # @return [ShowDocumentClientCapabilities] a new instance of ShowDocumentClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_client_capabilities.rb#8 + def initialize(support:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_client_capabilities.rb#25 + def attributes; end + + # The client has support for the show document + # request. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_client_capabilities.rb#21 + def support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_client_capabilities.rb#27 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_client_capabilities.rb#31 + def to_json(*args); end +end + +# Params to show a resource. +# +# source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#7 +class LanguageServer::Protocol::Interface::ShowDocumentParams + # @return [ShowDocumentParams] a new instance of ShowDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#8 + def initialize(uri:, external: T.unsafe(nil), take_focus: T.unsafe(nil), selection: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#59 + def attributes; end + + # Indicates to show the resource in an external program. + # To show, for example, `https://code.visualstudio.com/` + # in the default WEB browser set `external` to `true`. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#33 + def external; end + + # An optional selection range if the document is a text + # document. Clients might ignore the property if an + # external program is started or the file is not a text + # file. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#55 + def selection; end + + # An optional property to indicate whether the editor + # showing the document should take focus or not. + # Clients might ignore this property if an external + # program is started. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#44 + def take_focus; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#61 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#65 + def to_json(*args); end + + # The uri to show. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_params.rb#23 + def uri; end +end + +# The result of an show document request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/show_document_result.rb#7 +class LanguageServer::Protocol::Interface::ShowDocumentResult + # @return [ShowDocumentResult] a new instance of ShowDocumentResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_result.rb#8 + def initialize(success:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_result.rb#24 + def attributes; end + + # A boolean indicating if the show was successful. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_result.rb#20 + def success; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_result.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_document_result.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/show_message_params.rb#4 +class LanguageServer::Protocol::Interface::ShowMessageParams + # @return [ShowMessageParams] a new instance of ShowMessageParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_params.rb#5 + def initialize(type:, message:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_params.rb#30 + def attributes; end + + # The actual message. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_params.rb#26 + def message; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_params.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_params.rb#36 + def to_json(*args); end + + # The message type. See {@link MessageType}. + # + # @return [MessageType] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_params.rb#18 + def type; end +end + +# Show message request client capabilities +# +# source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::ShowMessageRequestClientCapabilities + # @return [ShowMessageRequestClientCapabilities] a new instance of ShowMessageRequestClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_client_capabilities.rb#8 + def initialize(message_action_item: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_client_capabilities.rb#24 + def attributes; end + + # Capabilities specific to the `MessageActionItem` type. + # + # @return [{ additionalPropertiesSupport?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_client_capabilities.rb#20 + def message_action_item; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_client_capabilities.rb#26 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_client_capabilities.rb#30 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#4 +class LanguageServer::Protocol::Interface::ShowMessageRequestParams + # @return [ShowMessageRequestParams] a new instance of ShowMessageRequestParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#5 + def initialize(type:, message:, actions: T.unsafe(nil)); end + + # The message action items to present. + # + # @return [MessageActionItem[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#35 + def actions; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#39 + def attributes; end + + # The actual message + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#27 + def message; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#45 + def to_json(*args); end + + # The message type. See {@link MessageType} + # + # @return [MessageType] + # + # source://language_server-protocol//lib/language_server/protocol/interface/show_message_request_params.rb#19 + def type; end +end + +# Signature help represents the signature of something +# callable. There can be multiple signature but only one +# active and only one active parameter. +# +# source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#9 +class LanguageServer::Protocol::Interface::SignatureHelp + # @return [SignatureHelp] a new instance of SignatureHelp + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#10 + def initialize(signatures:, active_signature: T.unsafe(nil), active_parameter: T.unsafe(nil)); end + + # The active parameter of the active signature. If omitted or the value + # lies outside the range of `signatures[activeSignature].parameters` + # defaults to 0 if the active signature has parameters. If + # the active signature has no parameters it is ignored. + # In future version of the protocol this property might become + # mandatory to better express the active parameter if the + # active signature does have any. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#55 + def active_parameter; end + + # The active signature. If omitted or the value lies outside the + # range of `signatures` the value defaults to zero or is ignore if + # the `SignatureHelp` as no signatures. + # + # Whenever possible implementors should make an active decision about + # the active signature and shouldn't rely on a default value. + # + # In future version of the protocol this property might become + # mandatory to better express this. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#41 + def active_signature; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#59 + def attributes; end + + # One or more signatures. If no signatures are available the signature help + # request should return `null`. + # + # @return [SignatureInformation[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#25 + def signatures; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#61 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help.rb#65 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::SignatureHelpClientCapabilities + # @return [SignatureHelpClientCapabilities] a new instance of SignatureHelpClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), signature_information: T.unsafe(nil), context_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#43 + def attributes; end + + # The client supports to send additional context information for a + # `textDocument/signatureHelp` request. A client that opts into + # contextSupport will also support the `retriggerCharacters` on + # `SignatureHelpOptions`. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#39 + def context_support; end + + # Whether signature help supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#19 + def dynamic_registration; end + + # The client supports the following `SignatureInformation` + # specific properties. + # + # @return [{ documentationFormat?: MarkupKind[]; parameterInformation?: { labelOffsetSupport?: boolean; }; activeParameterSupport?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#28 + def signature_information; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#45 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_client_capabilities.rb#49 + def to_json(*args); end +end + +# Additional information about the context in which a signature help request +# was triggered. +# +# source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#8 +class LanguageServer::Protocol::Interface::SignatureHelpContext + # @return [SignatureHelpContext] a new instance of SignatureHelpContext + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#9 + def initialize(trigger_kind:, is_retrigger:, trigger_character: T.unsafe(nil), active_signature_help: T.unsafe(nil)); end + + # The currently active `SignatureHelp`. + # + # The `activeSignatureHelp` has its `SignatureHelp.activeSignature` field + # updated based on the user navigating through available signatures. + # + # @return [SignatureHelp] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#58 + def active_signature_help; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#62 + def attributes; end + + # `true` if signature help was already showing when it was triggered. + # + # Retriggers occur when the signature help is already active and can be + # caused by actions such as typing a trigger character, a cursor move, or + # document content changes. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#47 + def is_retrigger; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#64 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#68 + def to_json(*args); end + + # Character that caused signature help to be triggered. + # + # This is undefined when triggerKind !== + # SignatureHelpTriggerKind.TriggerCharacter + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#35 + def trigger_character; end + + # Action that caused signature help to be triggered. + # + # @return [SignatureHelpTriggerKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_context.rb#24 + def trigger_kind; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#4 +class LanguageServer::Protocol::Interface::SignatureHelpOptions + # @return [SignatureHelpOptions] a new instance of SignatureHelpOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), trigger_characters: T.unsafe(nil), retrigger_characters: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#41 + def attributes; end + + # List of characters that re-trigger signature help. + # + # These trigger characters are only active when signature help is already + # showing. All trigger characters are also counted as re-trigger + # characters. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#37 + def retrigger_characters; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#43 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#47 + def to_json(*args); end + + # The characters that trigger signature help + # automatically. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#25 + def trigger_characters; end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_options.rb#16 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#4 +class LanguageServer::Protocol::Interface::SignatureHelpParams + # @return [SignatureHelpParams] a new instance of SignatureHelpParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), context: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#50 + def attributes; end + + # The signature help context. This is only available if the client + # specifies to send this using the client capability + # `textDocument.signatureHelp.contextSupport === true` + # + # @return [SignatureHelpContext] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#46 + def context; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#52 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#56 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#4 +class LanguageServer::Protocol::Interface::SignatureHelpRegistrationOptions + # @return [SignatureHelpRegistrationOptions] a new instance of SignatureHelpRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), trigger_characters: T.unsafe(nil), retrigger_characters: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#51 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#21 + def document_selector; end + + # List of characters that re-trigger signature help. + # + # These trigger characters are only active when signature help is already + # showing. All trigger characters are also counted as re-trigger + # characters. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#47 + def retrigger_characters; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#53 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#57 + def to_json(*args); end + + # The characters that trigger signature help + # automatically. + # + # @return [string[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#35 + def trigger_characters; end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_help_registration_options.rb#26 + def work_done_progress; end +end + +# Represents the signature of something callable. A signature +# can have a label, like a function-name, a doc-comment, and +# a set of parameters. +# +# source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#9 +class LanguageServer::Protocol::Interface::SignatureInformation + # @return [SignatureInformation] a new instance of SignatureInformation + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#10 + def initialize(label:, documentation: T.unsafe(nil), parameters: T.unsafe(nil), active_parameter: T.unsafe(nil)); end + + # The index of the active parameter. + # + # If provided, this is used in place of `SignatureHelp.activeParameter`. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#53 + def active_parameter; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#57 + def attributes; end + + # The human-readable doc-comment of this signature. Will be shown + # in the UI but can be omitted. + # + # @return [string | MarkupContent] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#35 + def documentation; end + + # The label of this signature. Will be shown in + # the UI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#26 + def label; end + + # The parameters of this signature. + # + # @return [ParameterInformation[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#43 + def parameters; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#59 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/signature_information.rb#63 + def to_json(*args); end +end + +# Static registration options to be returned in the initialize request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/static_registration_options.rb#7 +class LanguageServer::Protocol::Interface::StaticRegistrationOptions + # @return [StaticRegistrationOptions] a new instance of StaticRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/static_registration_options.rb#8 + def initialize(id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/static_registration_options.rb#25 + def attributes; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/static_registration_options.rb#21 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/static_registration_options.rb#27 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/static_registration_options.rb#31 + def to_json(*args); end +end + +# Represents information about programming constructs like variables, classes, +# interfaces etc. +# +# source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#8 +class LanguageServer::Protocol::Interface::SymbolInformation + # @return [SymbolInformation] a new instance of SymbolInformation + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#9 + def initialize(name:, kind:, location:, tags: T.unsafe(nil), deprecated: T.unsafe(nil), container_name: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#81 + def attributes; end + + # The name of the symbol containing this symbol. This information is for + # user interface purposes (e.g. to render a qualifier in the user interface + # if necessary). It can't be used to re-infer a hierarchy for the document + # symbols. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#77 + def container_name; end + + # Indicates if this symbol is deprecated. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#50 + def deprecated; end + + # The kind of this symbol. + # + # @return [SymbolKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#34 + def kind; end + + # The location of this symbol. The location's range is used by a tool + # to reveal the location in the editor. If the symbol is selected in the + # tool the range's start information is used to position the cursor. So + # the range usually spans more then the actual symbol's name and does + # normally include things like visibility modifiers. + # + # The range doesn't have to denote a node range in the sense of an abstract + # syntax tree. It can therefore not be used to re-construct a hierarchy of + # the symbols. + # + # @return [Location] + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#66 + def location; end + + # The name of this symbol. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#26 + def name; end + + # Tags for this symbol. + # + # @return [1[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#42 + def tags; end + + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#83 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/symbol_information.rb#87 + def to_json(*args); end +end + +# Describe options to be used when registering for text document change events. +# +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_change_registration_options.rb#7 +class LanguageServer::Protocol::Interface::TextDocumentChangeRegistrationOptions + # @return [TextDocumentChangeRegistrationOptions] a new instance of TextDocumentChangeRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_change_registration_options.rb#8 + def initialize(document_selector:, sync_kind:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_change_registration_options.rb#35 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_change_registration_options.rb#22 + def document_selector; end + + # How documents are synced to the server. See TextDocumentSyncKind.Full + # and TextDocumentSyncKind.Incremental. + # + # @return [TextDocumentSyncKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_change_registration_options.rb#31 + def sync_kind; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_change_registration_options.rb#37 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_change_registration_options.rb#41 + def to_json(*args); end +end + +# Text document specific client capabilities. +# +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#7 +class LanguageServer::Protocol::Interface::TextDocumentClientCapabilities + # @return [TextDocumentClientCapabilities] a new instance of TextDocumentClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#8 + def initialize(synchronization: T.unsafe(nil), completion: T.unsafe(nil), hover: T.unsafe(nil), signature_help: T.unsafe(nil), declaration: T.unsafe(nil), definition: T.unsafe(nil), type_definition: T.unsafe(nil), implementation: T.unsafe(nil), references: T.unsafe(nil), document_highlight: T.unsafe(nil), document_symbol: T.unsafe(nil), code_action: T.unsafe(nil), code_lens: T.unsafe(nil), document_link: T.unsafe(nil), color_provider: T.unsafe(nil), formatting: T.unsafe(nil), range_formatting: T.unsafe(nil), on_type_formatting: T.unsafe(nil), rename: T.unsafe(nil), publish_diagnostics: T.unsafe(nil), folding_range: T.unsafe(nil), selection_range: T.unsafe(nil), linked_editing_range: T.unsafe(nil), call_hierarchy: T.unsafe(nil), semantic_tokens: T.unsafe(nil), moniker: T.unsafe(nil), type_hierarchy: T.unsafe(nil), inline_value: T.unsafe(nil), inlay_hint: T.unsafe(nil), diagnostic: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#285 + def attributes; end + + # Capabilities specific to the various call hierarchy requests. + # + # @return [CallHierarchyClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#233 + def call_hierarchy; end + + # Capabilities specific to the `textDocument/codeAction` request. + # + # @return [CodeActionClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#134 + def code_action; end + + # Capabilities specific to the `textDocument/codeLens` request. + # + # @return [CodeLensClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#142 + def code_lens; end + + # Capabilities specific to the `textDocument/documentColor` and the + # `textDocument/colorPresentation` request. + # + # @return [DocumentColorClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#159 + def color_provider; end + + # Capabilities specific to the `textDocument/completion` request. + # + # @return [CompletionClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#54 + def completion; end + + # Capabilities specific to the `textDocument/declaration` request. + # + # @return [DeclarationClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#78 + def declaration; end + + # Capabilities specific to the `textDocument/definition` request. + # + # @return [DefinitionClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#86 + def definition; end + + # Capabilities specific to the diagnostic pull model. + # + # @return [DiagnosticClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#281 + def diagnostic; end + + # Capabilities specific to the `textDocument/documentHighlight` request. + # + # @return [DocumentHighlightClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#118 + def document_highlight; end + + # Capabilities specific to the `textDocument/documentLink` request. + # + # @return [DocumentLinkClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#150 + def document_link; end + + # Capabilities specific to the `textDocument/documentSymbol` request. + # + # @return [DocumentSymbolClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#126 + def document_symbol; end + + # Capabilities specific to the `textDocument/foldingRange` request. + # + # @return [FoldingRangeClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#209 + def folding_range; end + + # Capabilities specific to the `textDocument/formatting` request. + # + # @return [DocumentFormattingClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#167 + def formatting; end + + # Capabilities specific to the `textDocument/hover` request. + # + # @return [HoverClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#62 + def hover; end + + # Capabilities specific to the `textDocument/implementation` request. + # + # @return [ImplementationClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#102 + def implementation; end + + # Capabilities specific to the `textDocument/inlayHint` request. + # + # @return [InlayHintClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#273 + def inlay_hint; end + + # Capabilities specific to the `textDocument/inlineValue` request. + # + # @return [InlineValueClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#265 + def inline_value; end + + # Capabilities specific to the `textDocument/linkedEditingRange` request. + # + # @return [LinkedEditingRangeClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#225 + def linked_editing_range; end + + # Capabilities specific to the `textDocument/moniker` request. + # + # @return [MonikerClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#249 + def moniker; end + + # request. + # Capabilities specific to the `textDocument/onTypeFormatting` request. + # + # @return [DocumentOnTypeFormattingClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#184 + def on_type_formatting; end + + # Capabilities specific to the `textDocument/publishDiagnostics` + # notification. + # + # @return [PublishDiagnosticsClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#201 + def publish_diagnostics; end + + # Capabilities specific to the `textDocument/rangeFormatting` request. + # + # @return [DocumentRangeFormattingClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#175 + def range_formatting; end + + # Capabilities specific to the `textDocument/references` request. + # + # @return [ReferenceClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#110 + def references; end + + # Capabilities specific to the `textDocument/rename` request. + # + # @return [RenameClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#192 + def rename; end + + # Capabilities specific to the `textDocument/selectionRange` request. + # + # @return [SelectionRangeClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#217 + def selection_range; end + + # Capabilities specific to the various semantic token requests. + # + # @return [SemanticTokensClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#241 + def semantic_tokens; end + + # Capabilities specific to the `textDocument/signatureHelp` request. + # + # @return [SignatureHelpClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#70 + def signature_help; end + + # @return [TextDocumentSyncClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#46 + def synchronization; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#287 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#291 + def to_json(*args); end + + # Capabilities specific to the `textDocument/typeDefinition` request. + # + # @return [TypeDefinitionClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#94 + def type_definition; end + + # Capabilities specific to the various type hierarchy requests. + # + # @return [TypeHierarchyClientCapabilities] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_client_capabilities.rb#257 + def type_hierarchy; end +end + +# An event describing a change to a text document. If only a text is provided +# it is considered to be the full content of the document. +# +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#8 +class LanguageServer::Protocol::Interface::TextDocumentContentChangeEvent + # @return [TextDocumentContentChangeEvent] a new instance of TextDocumentContentChangeEvent + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#9 + def initialize(text:, range: T.unsafe(nil), range_length: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#47 + def attributes; end + + # The range of the document that changed. + # + # @return [Range, nil] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#23 + def range; end + + # The optional length of the range that got replaced. + # + # @return [number, nil] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#31 + def range_length; end + + # The new text for the provided range. + # + # --- OR --- + # + # The new text of the whole document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#43 + def text; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#49 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_content_change_event.rb#53 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_edit.rb#4 +class LanguageServer::Protocol::Interface::TextDocumentEdit + # @return [TextDocumentEdit] a new instance of TextDocumentEdit + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_edit.rb#5 + def initialize(text_document:, edits:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_edit.rb#30 + def attributes; end + + # The edits to be applied. + # + # @return [(TextEdit | AnnotatedTextEdit)[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_edit.rb#26 + def edits; end + + # The text document to change. + # + # @return [OptionalVersionedTextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_edit.rb#18 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_edit.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_edit.rb#36 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_identifier.rb#4 +class LanguageServer::Protocol::Interface::TextDocumentIdentifier + # @return [TextDocumentIdentifier] a new instance of TextDocumentIdentifier + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_identifier.rb#5 + def initialize(uri:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_identifier.rb#21 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_identifier.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_identifier.rb#27 + def to_json(*args); end + + # The text document's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_identifier.rb#17 + def uri; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#4 +class LanguageServer::Protocol::Interface::TextDocumentItem + # @return [TextDocumentItem] a new instance of TextDocumentItem + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#5 + def initialize(uri:, language_id:, version:, text:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#49 + def attributes; end + + # The text document's language identifier. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#28 + def language_id; end + + # The content of the opened text document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#45 + def text; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#55 + def to_json(*args); end + + # The text document's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#20 + def uri; end + + # The version number of this document (it will increase after each + # change, including undo/redo). + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_item.rb#37 + def version; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_position_params.rb#4 +class LanguageServer::Protocol::Interface::TextDocumentPositionParams + # @return [TextDocumentPositionParams] a new instance of TextDocumentPositionParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_position_params.rb#5 + def initialize(text_document:, position:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_position_params.rb#30 + def attributes; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_position_params.rb#26 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_position_params.rb#18 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_position_params.rb#32 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_position_params.rb#36 + def to_json(*args); end +end + +# General text document registration options. +# +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_registration_options.rb#7 +class LanguageServer::Protocol::Interface::TextDocumentRegistrationOptions + # @return [TextDocumentRegistrationOptions] a new instance of TextDocumentRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_registration_options.rb#8 + def initialize(document_selector:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_registration_options.rb#25 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_registration_options.rb#21 + def document_selector; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_registration_options.rb#27 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_registration_options.rb#31 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_save_registration_options.rb#4 +class LanguageServer::Protocol::Interface::TextDocumentSaveRegistrationOptions + # @return [TextDocumentSaveRegistrationOptions] a new instance of TextDocumentSaveRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_save_registration_options.rb#5 + def initialize(document_selector:, include_text: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_save_registration_options.rb#31 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_save_registration_options.rb#19 + def document_selector; end + + # The client is supposed to include the content on save. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_save_registration_options.rb#27 + def include_text; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_save_registration_options.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_save_registration_options.rb#37 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::TextDocumentSyncClientCapabilities + # @return [TextDocumentSyncClientCapabilities] a new instance of TextDocumentSyncClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), will_save: T.unsafe(nil), will_save_wait_until: T.unsafe(nil), did_save: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#50 + def attributes; end + + # The client supports did save notifications. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#46 + def did_save; end + + # Whether text document synchronization supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#20 + def dynamic_registration; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#52 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#56 + def to_json(*args); end + + # The client supports sending will save notifications. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#28 + def will_save; end + + # The client supports sending a will save request and + # waits for a response providing text edits which will + # be applied to the document before it is saved. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_client_capabilities.rb#38 + def will_save_wait_until; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#4 +class LanguageServer::Protocol::Interface::TextDocumentSyncOptions + # @return [TextDocumentSyncOptions] a new instance of TextDocumentSyncOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#5 + def initialize(open_close: T.unsafe(nil), change: T.unsafe(nil), will_save: T.unsafe(nil), will_save_wait_until: T.unsafe(nil), save: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#66 + def attributes; end + + # Change notifications are sent to the server. See + # TextDocumentSyncKind.None, TextDocumentSyncKind.Full and + # TextDocumentSyncKind.Incremental. If omitted it defaults to + # TextDocumentSyncKind.None. + # + # @return [TextDocumentSyncKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#35 + def change; end + + # Open and close notifications are sent to the server. If omitted open + # close notifications should not be sent. + # Open and close notifications are sent to the server. If omitted open + # close notification should not be sent. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#24 + def open_close; end + + # If present save notifications are sent to the server. If omitted the + # notification should not be sent. + # + # @return [boolean | SaveOptions] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#62 + def save; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#68 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#72 + def to_json(*args); end + + # If present will save notifications are sent to the server. If omitted + # the notification should not be sent. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#44 + def will_save; end + + # If present will save wait until requests are sent to the server. If + # omitted the request should not be sent. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_document_sync_options.rb#53 + def will_save_wait_until; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/text_edit.rb#4 +class LanguageServer::Protocol::Interface::TextEdit + # @return [TextEdit] a new instance of TextEdit + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_edit.rb#5 + def initialize(range:, new_text:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_edit.rb#32 + def attributes; end + + # The string to be inserted. For delete operations use an + # empty string. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_edit.rb#28 + def new_text; end + + # The range of the text document to be manipulated. To insert + # text into a document create a range where start === end. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/text_edit.rb#19 + def range; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_edit.rb#34 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/text_edit.rb#38 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_definition_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::TypeDefinitionClientCapabilities + # @return [TypeDefinitionClientCapabilities] a new instance of TypeDefinitionClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), link_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_client_capabilities.rb#32 + def attributes; end + + # Whether implementation supports dynamic registration. If this is set to + # `true` the client supports the new `TypeDefinitionRegistrationOptions` + # return value for the corresponding server capability as well. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_client_capabilities.rb#20 + def dynamic_registration; end + + # The client supports additional metadata in the form of definition links. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_client_capabilities.rb#28 + def link_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_client_capabilities.rb#34 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_client_capabilities.rb#38 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_definition_options.rb#4 +class LanguageServer::Protocol::Interface::TypeDefinitionOptions + # @return [TypeDefinitionOptions] a new instance of TypeDefinitionOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#4 +class LanguageServer::Protocol::Interface::TypeDefinitionParams + # @return [TypeDefinitionParams] a new instance of TypeDefinitionParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#49 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#45 + def partial_result_token; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#28 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#20 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#51 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#55 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_params.rb#36 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#4 +class LanguageServer::Protocol::Interface::TypeDefinitionRegistrationOptions + # @return [TypeDefinitionRegistrationOptions] a new instance of TypeDefinitionRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#20 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_definition_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#4 +class LanguageServer::Protocol::Interface::TypeHierarchyItem + # @return [TypeHierarchyItem] a new instance of TypeHierarchyItem + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#5 + def initialize(name:, kind:, uri:, range:, selection_range:, tags: T.unsafe(nil), detail: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#90 + def attributes; end + + # A data entry field that is preserved between a type hierarchy prepare and + # supertypes or subtypes requests. It could also be used to identify the + # type hierarchy in the server, helping improve the performance on + # resolving supertypes and subtypes. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#86 + def data; end + + # More detail for this item, e.g. the signature of a function. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#48 + def detail; end + + # The kind of this item. + # + # @return [SymbolKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#32 + def kind; end + + # The name of this item. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#24 + def name; end + + # The range enclosing this symbol not including leading/trailing whitespace + # but everything else, e.g. comments and code. + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#65 + def range; end + + # The range that should be selected and revealed when this symbol is being + # picked, e.g. the name of a function. Must be contained by the + # [`range`](#TypeHierarchyItem.range). + # + # @return [Range] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#75 + def selection_range; end + + # Tags for this item. + # + # @return [1[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#40 + def tags; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#92 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#96 + def to_json(*args); end + + # The resource identifier of this item. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_item.rb#56 + def uri; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_options.rb#4 +class LanguageServer::Protocol::Interface::TypeHierarchyOptions + # @return [TypeHierarchyOptions] a new instance of TypeHierarchyOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#4 +class LanguageServer::Protocol::Interface::TypeHierarchyPrepareParams + # @return [TypeHierarchyPrepareParams] a new instance of TypeHierarchyPrepareParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#5 + def initialize(text_document:, position:, work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#39 + def attributes; end + + # The position inside the text document. + # + # @return [Position] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#27 + def position; end + + # The text document. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#19 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#41 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#45 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_prepare_params.rb#35 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#4 +class LanguageServer::Protocol::Interface::TypeHierarchyRegistrationOptions + # @return [TypeHierarchyRegistrationOptions] a new instance of TypeHierarchyRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#5 + def initialize(document_selector:, work_done_progress: T.unsafe(nil), id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#38 + def attributes; end + + # A document selector to identify the scope of the registration. If set to + # null the document selector provided on the client side will be used. + # + # @return [DocumentSelector] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#20 + def document_selector; end + + # The id used to register the request. The id can be used to deregister + # the request again. See also Registration#id. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#34 + def id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#44 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_registration_options.rb#25 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#4 +class LanguageServer::Protocol::Interface::TypeHierarchySubtypesParams + # @return [TypeHierarchySubtypesParams] a new instance of TypeHierarchySubtypesParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#5 + def initialize(item:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#37 + def attributes; end + + # @return [TypeHierarchyItem] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#33 + def item; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#28 + def partial_result_token; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#43 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_subtypes_params.rb#19 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#4 +class LanguageServer::Protocol::Interface::TypeHierarchySupertypesParams + # @return [TypeHierarchySupertypesParams] a new instance of TypeHierarchySupertypesParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#5 + def initialize(item:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#37 + def attributes; end + + # @return [TypeHierarchyItem] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#33 + def item; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#28 + def partial_result_token; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#39 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#43 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/type_hierarchy_supertypes_params.rb#19 + def work_done_token; end +end + +# A diagnostic report indicating that the last returned +# report is still accurate. +# +# source://language_server-protocol//lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb#8 +class LanguageServer::Protocol::Interface::UnchangedDocumentDiagnosticReport + # @return [UnchangedDocumentDiagnosticReport] a new instance of UnchangedDocumentDiagnosticReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb#9 + def initialize(kind:, result_id:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb#38 + def attributes; end + + # A document diagnostic report indicating + # no changes to the last result. A server can + # only return `unchanged` if result ids are + # provided. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb#25 + def kind; end + + # A result id which will be sent on the next + # diagnostic request for the same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb#34 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb#40 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/unchanged_document_diagnostic_report.rb#44 + def to_json(*args); end +end + +# General parameters to unregister a capability. +# +# source://language_server-protocol//lib/language_server/protocol/interface/unregistration.rb#7 +class LanguageServer::Protocol::Interface::Unregistration + # @return [Unregistration] a new instance of Unregistration + # + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration.rb#8 + def initialize(id:, method:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration.rb#34 + def attributes; end + + # The id used to unregister the request or notification. Usually an id + # provided during the register request. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration.rb#22 + def id; end + + # The method / capability to unregister for. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration.rb#30 + def method; end + + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration.rb#36 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration.rb#40 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/unregistration_params.rb#4 +class LanguageServer::Protocol::Interface::UnregistrationParams + # @return [UnregistrationParams] a new instance of UnregistrationParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration_params.rb#5 + def initialize(unregisterations:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration_params.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration_params.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration_params.rb#24 + def to_json(*args); end + + # @return [Unregistration[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/unregistration_params.rb#14 + def unregisterations; end +end + +# A versioned notebook document identifier. +# +# source://language_server-protocol//lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb#7 +class LanguageServer::Protocol::Interface::VersionedNotebookDocumentIdentifier + # @return [VersionedNotebookDocumentIdentifier] a new instance of VersionedNotebookDocumentIdentifier + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb#8 + def initialize(version:, uri:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb#33 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb#39 + def to_json(*args); end + + # The notebook document's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb#29 + def uri; end + + # The version number of this notebook document. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_notebook_document_identifier.rb#21 + def version; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/versioned_text_document_identifier.rb#4 +class LanguageServer::Protocol::Interface::VersionedTextDocumentIdentifier + # @return [VersionedTextDocumentIdentifier] a new instance of VersionedTextDocumentIdentifier + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_text_document_identifier.rb#5 + def initialize(uri:, version:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_text_document_identifier.rb#33 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_text_document_identifier.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_text_document_identifier.rb#39 + def to_json(*args); end + + # The text document's URI. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_text_document_identifier.rb#18 + def uri; end + + # The version number of this document. + # + # The version number of a document will increase after each change, + # including undo/redo. The number doesn't need to be consecutive. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/versioned_text_document_identifier.rb#29 + def version; end +end + +# The parameters send in a will save text document notification. +# +# source://language_server-protocol//lib/language_server/protocol/interface/will_save_text_document_params.rb#7 +class LanguageServer::Protocol::Interface::WillSaveTextDocumentParams + # @return [WillSaveTextDocumentParams] a new instance of WillSaveTextDocumentParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/will_save_text_document_params.rb#8 + def initialize(text_document:, reason:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/will_save_text_document_params.rb#33 + def attributes; end + + # The 'TextDocumentSaveReason'. + # + # @return [TextDocumentSaveReason] + # + # source://language_server-protocol//lib/language_server/protocol/interface/will_save_text_document_params.rb#29 + def reason; end + + # The document that will be saved. + # + # @return [TextDocumentIdentifier] + # + # source://language_server-protocol//lib/language_server/protocol/interface/will_save_text_document_params.rb#21 + def text_document; end + + # source://language_server-protocol//lib/language_server/protocol/interface/will_save_text_document_params.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/will_save_text_document_params.rb#39 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#4 +class LanguageServer::Protocol::Interface::WorkDoneProgressBegin + # @return [WorkDoneProgressBegin] a new instance of WorkDoneProgressBegin + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#5 + def initialize(kind:, title:, cancellable: T.unsafe(nil), message: T.unsafe(nil), percentage: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#68 + def attributes; end + + # Controls if a cancel button should show to allow the user to cancel the + # long running operation. Clients that don't support cancellation are + # allowed to ignore the setting. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#39 + def cancellable; end + + # @return ["begin"] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#18 + def kind; end + + # Optional, more detailed associated progress message. Contains + # complementary information to the `title`. + # + # Examples: "3/25 files", "project/src/module2", "node_modules/some_dep". + # If unset, the previous progress message (if any) is still valid. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#51 + def message; end + + # Optional progress percentage to display (value 100 is considered 100%). + # If not provided infinite progress is assumed and clients are allowed + # to ignore the `percentage` value in subsequent in report notifications. + # + # The value should be steadily rising. Clients are free to ignore values + # that are not following this rule. The value range is [0, 100] + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#64 + def percentage; end + + # Mandatory title of the progress operation. Used to briefly inform about + # the kind of operation being performed. + # + # Examples: "Indexing" or "Linking dependencies". + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#29 + def title; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#70 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_begin.rb#74 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_cancel_params.rb#4 +class LanguageServer::Protocol::Interface::WorkDoneProgressCancelParams + # @return [WorkDoneProgressCancelParams] a new instance of WorkDoneProgressCancelParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_cancel_params.rb#5 + def initialize(token:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_cancel_params.rb#21 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_cancel_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_cancel_params.rb#27 + def to_json(*args); end + + # The token to be used to report progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_cancel_params.rb#17 + def token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_create_params.rb#4 +class LanguageServer::Protocol::Interface::WorkDoneProgressCreateParams + # @return [WorkDoneProgressCreateParams] a new instance of WorkDoneProgressCreateParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_create_params.rb#5 + def initialize(token:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_create_params.rb#21 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_create_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_create_params.rb#27 + def to_json(*args); end + + # The token to be used to report progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_create_params.rb#17 + def token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_end.rb#4 +class LanguageServer::Protocol::Interface::WorkDoneProgressEnd + # @return [WorkDoneProgressEnd] a new instance of WorkDoneProgressEnd + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_end.rb#5 + def initialize(kind:, message: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_end.rb#28 + def attributes; end + + # @return ["end"] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_end.rb#15 + def kind; end + + # Optional, a final message indicating to for example indicate the outcome + # of the operation. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_end.rb#24 + def message; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_end.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_end.rb#34 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_options.rb#4 +class LanguageServer::Protocol::Interface::WorkDoneProgressOptions + # @return [WorkDoneProgressOptions] a new instance of WorkDoneProgressOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_options.rb#18 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_options.rb#20 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_options.rb#24 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_options.rb#14 + def work_done_progress; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_params.rb#4 +class LanguageServer::Protocol::Interface::WorkDoneProgressParams + # @return [WorkDoneProgressParams] a new instance of WorkDoneProgressParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_params.rb#5 + def initialize(work_done_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_params.rb#21 + def attributes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_params.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_params.rb#27 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_params.rb#17 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#4 +class LanguageServer::Protocol::Interface::WorkDoneProgressReport + # @return [WorkDoneProgressReport] a new instance of WorkDoneProgressReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#5 + def initialize(kind:, cancellable: T.unsafe(nil), message: T.unsafe(nil), percentage: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#58 + def attributes; end + + # Controls enablement state of a cancel button. This property is only valid + # if a cancel button got requested in the `WorkDoneProgressBegin` payload. + # + # Clients that don't support cancellation or don't support control the + # button's enablement state are allowed to ignore the setting. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#29 + def cancellable; end + + # @return ["report"] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#17 + def kind; end + + # Optional, more detailed associated progress message. Contains + # complementary information to the `title`. + # + # Examples: "3/25 files", "project/src/module2", "node_modules/some_dep". + # If unset, the previous progress message (if any) is still valid. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#41 + def message; end + + # Optional progress percentage to display (value 100 is considered 100%). + # If not provided infinite progress is assumed and clients are allowed + # to ignore the `percentage` value in subsequent in report notifications. + # + # The value should be steadily rising. Clients are free to ignore values + # that are not following this rule. The value range is [0, 100] + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#54 + def percentage; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#60 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/work_done_progress_report.rb#64 + def to_json(*args); end +end + +# Parameters of the workspace diagnostic request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceDiagnosticParams + # @return [WorkspaceDiagnosticParams] a new instance of WorkspaceDiagnosticParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#8 + def initialize(previous_result_ids:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil), identifier: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#53 + def attributes; end + + # The additional identifier provided during registration. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#40 + def identifier; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#32 + def partial_result_token; end + + # The currently known diagnostic reports with their + # previous result ids. + # + # @return [PreviousResultId[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#49 + def previous_result_ids; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#55 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#59 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_params.rb#23 + def work_done_token; end +end + +# A workspace diagnostic report. +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceDiagnosticReport + # @return [WorkspaceDiagnosticReport] a new instance of WorkspaceDiagnosticReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report.rb#8 + def initialize(items:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report.rb#21 + def attributes; end + + # @return [WorkspaceDocumentDiagnosticReport[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report.rb#17 + def items; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report.rb#27 + def to_json(*args); end +end + +# A partial result for a workspace diagnostic report. +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report_partial_result.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceDiagnosticReportPartialResult + # @return [WorkspaceDiagnosticReportPartialResult] a new instance of WorkspaceDiagnosticReportPartialResult + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report_partial_result.rb#8 + def initialize(items:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report_partial_result.rb#21 + def attributes; end + + # @return [WorkspaceDocumentDiagnosticReport[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report_partial_result.rb#17 + def items; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report_partial_result.rb#23 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_diagnostic_report_partial_result.rb#27 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#4 +class LanguageServer::Protocol::Interface::WorkspaceEdit + # @return [WorkspaceEdit] a new instance of WorkspaceEdit + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#5 + def initialize(changes: T.unsafe(nil), document_changes: T.unsafe(nil), change_annotations: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#56 + def attributes; end + + # A map of change annotations that can be referenced in + # `AnnotatedTextEdit`s or create, rename and delete file / folder + # operations. + # + # Whether clients honor this property depends on the client capability + # `workspace.changeAnnotationSupport`. + # + # @return [{ [id: string]: ChangeAnnotation; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#52 + def change_annotations; end + + # Holds changes to existing resources. + # + # @return [{}] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#19 + def changes; end + + # Depending on the client capability + # `workspace.workspaceEdit.resourceOperations` document changes are either + # an array of `TextDocumentEdit`s to express changes to n different text + # documents where each text document edit addresses a specific version of + # a text document. Or it can contain above `TextDocumentEdit`s mixed with + # create, rename and delete file / folder operations. + # + # Whether a client supports versioned document edits is expressed via + # `workspace.workspaceEdit.documentChanges` client capability. + # + # If a client neither supports `documentChanges` nor + # `workspace.workspaceEdit.resourceOperations` then only plain `TextEdit`s + # using the `changes` property are supported. + # + # @return [TextDocumentEdit[] | (TextDocumentEdit | CreateFile | RenameFile | DeleteFile)[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#39 + def document_changes; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#58 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit.rb#62 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::WorkspaceEditClientCapabilities + # @return [WorkspaceEditClientCapabilities] a new instance of WorkspaceEditClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#5 + def initialize(document_changes: T.unsafe(nil), resource_operations: T.unsafe(nil), failure_handling: T.unsafe(nil), normalizes_line_endings: T.unsafe(nil), change_annotation_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#63 + def attributes; end + + # Whether the client in general supports change annotations on text edits, + # create file, rename file and delete file changes. + # + # @return [{ groupsOnLabel?: boolean; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#59 + def change_annotation_support; end + + # The client supports versioned document changes in `WorkspaceEdit`s + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#21 + def document_changes; end + + # The failure handling strategy of a client if applying the workspace edit + # fails. + # + # @return [FailureHandlingKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#39 + def failure_handling; end + + # Whether the client normalizes line endings to the client specific + # setting. + # If set to `true` the client will normalize line ending characters + # in a workspace edit to the client specific new line character(s). + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#50 + def normalizes_line_endings; end + + # The resource operations the client supports. Clients should at least + # support 'create', 'rename' and 'delete' files and folders. + # + # @return [ResourceOperationKind[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#30 + def resource_operations; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#65 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_edit_client_capabilities.rb#69 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_folder.rb#4 +class LanguageServer::Protocol::Interface::WorkspaceFolder + # @return [WorkspaceFolder] a new instance of WorkspaceFolder + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folder.rb#5 + def initialize(uri:, name:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folder.rb#31 + def attributes; end + + # The name of the workspace folder. Used to refer to this + # workspace folder in the user interface. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folder.rb#27 + def name; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folder.rb#33 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folder.rb#37 + def to_json(*args); end + + # The associated URI for this workspace folder. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folder.rb#18 + def uri; end +end + +# The workspace folder change event. +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_change_event.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceFoldersChangeEvent + # @return [WorkspaceFoldersChangeEvent] a new instance of WorkspaceFoldersChangeEvent + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_change_event.rb#8 + def initialize(added:, removed:); end + + # The array of added workspace folders + # + # @return [WorkspaceFolder[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_change_event.rb#21 + def added; end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_change_event.rb#33 + def attributes; end + + # The array of the removed workspace folders + # + # @return [WorkspaceFolder[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_change_event.rb#29 + def removed; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_change_event.rb#35 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_change_event.rb#39 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb#4 +class LanguageServer::Protocol::Interface::WorkspaceFoldersServerCapabilities + # @return [WorkspaceFoldersServerCapabilities] a new instance of WorkspaceFoldersServerCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb#5 + def initialize(supported: T.unsafe(nil), change_notifications: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb#36 + def attributes; end + + # Whether the server wants to receive workspace folder + # change notifications. + # + # If a string is provided, the string is treated as an ID + # under which the notification is registered on the client + # side. The ID can be used to unregister for these events + # using the `client/unregisterCapability` request. + # + # @return [string | boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb#32 + def change_notifications; end + + # The server has support for workspace folders + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb#18 + def supported; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb#38 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb#42 + def to_json(*args); end +end + +# A full document diagnostic report for a workspace diagnostic result. +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceFullDocumentDiagnosticReport + # @return [WorkspaceFullDocumentDiagnosticReport] a new instance of WorkspaceFullDocumentDiagnosticReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#8 + def initialize(kind:, items:, uri:, version:, result_id: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#63 + def attributes; end + + # The actual items. + # + # @return [Diagnostic[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#42 + def items; end + + # A full document diagnostic report. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#24 + def kind; end + + # An optional result id. If provided it will + # be sent on the next diagnostic request for the + # same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#34 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#65 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#69 + def to_json(*args); end + + # The URI for which diagnostic information is reported. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#50 + def uri; end + + # The version number for which the diagnostics are reported. + # If the document is not marked as open `null` can be provided. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_full_document_diagnostic_report.rb#59 + def version; end +end + +# A special workspace symbol that supports locations without a range +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceSymbol + # @return [WorkspaceSymbol] a new instance of WorkspaceSymbol + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#8 + def initialize(name:, kind:, location:, tags: T.unsafe(nil), container_name: T.unsafe(nil), data: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#77 + def attributes; end + + # The name of the symbol containing this symbol. This information is for + # user interface purposes (e.g. to render a qualifier in the user interface + # if necessary). It can't be used to re-infer a hierarchy for the document + # symbols. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#52 + def container_name; end + + # A data entry field that is preserved on a workspace symbol between a + # workspace symbol request and a workspace symbol resolve request. + # + # @return [LSPAny] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#73 + def data; end + + # The kind of this symbol. + # + # @return [SymbolKind] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#33 + def kind; end + + # The location of this symbol. Whether a server is allowed to + # return a location without a range depends on the client + # capability `workspace.symbol.resolveSupport`. + # + # See also `SymbolInformation.location`. + # + # @return [Location | { uri: string; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#64 + def location; end + + # The name of this symbol. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#25 + def name; end + + # Tags for this completion item. + # + # @return [1[]] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#41 + def tags; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#79 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol.rb#83 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#4 +class LanguageServer::Protocol::Interface::WorkspaceSymbolClientCapabilities + # @return [WorkspaceSymbolClientCapabilities] a new instance of WorkspaceSymbolClientCapabilities + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#5 + def initialize(dynamic_registration: T.unsafe(nil), symbol_kind: T.unsafe(nil), tag_support: T.unsafe(nil), resolve_support: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#52 + def attributes; end + + # Symbol request supports dynamic registration. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#20 + def dynamic_registration; end + + # The client support partial workspace symbols. The client will send the + # request `workspaceSymbol/resolve` to the server to resolve additional + # properties. + # + # @return [{ properties: string[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#48 + def resolve_support; end + + # Specific capabilities for the `SymbolKind` in the `workspace/symbol` + # request. + # + # @return [{ valueSet?: SymbolKind[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#29 + def symbol_kind; end + + # The client supports tags on `SymbolInformation` and `WorkspaceSymbol`. + # Clients supporting tags have to handle unknown tags gracefully. + # + # @return [{ valueSet: 1[]; }] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#38 + def tag_support; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#54 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_client_capabilities.rb#58 + def to_json(*args); end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_options.rb#4 +class LanguageServer::Protocol::Interface::WorkspaceSymbolOptions + # @return [WorkspaceSymbolOptions] a new instance of WorkspaceSymbolOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_options.rb#28 + def attributes; end + + # The server provides support to resolve additional + # information for a workspace symbol. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_options.rb#24 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_options.rb#15 + def work_done_progress; end +end + +# The parameters of a Workspace Symbol Request. +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceSymbolParams + # @return [WorkspaceSymbolParams] a new instance of WorkspaceSymbolParams + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#8 + def initialize(query:, work_done_token: T.unsafe(nil), partial_result_token: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#44 + def attributes; end + + # An optional token that a server can use to report partial results (e.g. + # streaming) to the client. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#31 + def partial_result_token; end + + # A query string to filter symbols by. Clients may send an empty + # string here to request all symbols. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#40 + def query; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#46 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#50 + def to_json(*args); end + + # An optional token that a server can use to report work done progress. + # + # @return [ProgressToken] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_params.rb#22 + def work_done_token; end +end + +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_registration_options.rb#4 +class LanguageServer::Protocol::Interface::WorkspaceSymbolRegistrationOptions + # @return [WorkspaceSymbolRegistrationOptions] a new instance of WorkspaceSymbolRegistrationOptions + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_registration_options.rb#5 + def initialize(work_done_progress: T.unsafe(nil), resolve_provider: T.unsafe(nil)); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_registration_options.rb#28 + def attributes; end + + # The server provides support to resolve additional + # information for a workspace symbol. + # + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_registration_options.rb#24 + def resolve_provider; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_registration_options.rb#30 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_registration_options.rb#34 + def to_json(*args); end + + # @return [boolean] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_symbol_registration_options.rb#15 + def work_done_progress; end +end + +# An unchanged document diagnostic report for a workspace diagnostic result. +# +# source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#7 +class LanguageServer::Protocol::Interface::WorkspaceUnchangedDocumentDiagnosticReport + # @return [WorkspaceUnchangedDocumentDiagnosticReport] a new instance of WorkspaceUnchangedDocumentDiagnosticReport + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#8 + def initialize(kind:, result_id:, uri:, version:); end + + # Returns the value of attribute attributes. + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#56 + def attributes; end + + # A document diagnostic report indicating + # no changes to the last result. A server can + # only return `unchanged` if result ids are + # provided. + # + # @return [any] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#26 + def kind; end + + # A result id which will be sent on the next + # diagnostic request for the same document. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#35 + def result_id; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#58 + def to_hash; end + + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#62 + def to_json(*args); end + + # The URI for which diagnostic information is reported. + # + # @return [string] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#43 + def uri; end + + # The version number for which the diagnostics are reported. + # If the document is not marked as open `null` can be provided. + # + # @return [number] + # + # source://language_server-protocol//lib/language_server/protocol/interface/workspace_unchanged_document_diagnostic_report.rb#52 + def version; end +end + +# source://language_server-protocol//lib/language_server/protocol/transport/io/reader.rb#7 +module LanguageServer::Protocol::Transport; end + +# source://language_server-protocol//lib/language_server/protocol/transport/io/reader.rb#8 +module LanguageServer::Protocol::Transport::Io; end + +# source://language_server-protocol//lib/language_server/protocol/transport/io/reader.rb#9 +class LanguageServer::Protocol::Transport::Io::Reader + # @return [Reader] a new instance of Reader + # + # source://language_server-protocol//lib/language_server/protocol/transport/io/reader.rb#10 + def initialize(io); end + + # source://language_server-protocol//lib/language_server/protocol/transport/io/reader.rb#15 + def read(&block); end + + private + + # Returns the value of attribute io. + # + # source://language_server-protocol//lib/language_server/protocol/transport/io/reader.rb#26 + def io; end +end + +# source://language_server-protocol//lib/language_server/protocol/transport/io/writer.rb#5 +class LanguageServer::Protocol::Transport::Io::Writer + # @return [Writer] a new instance of Writer + # + # source://language_server-protocol//lib/language_server/protocol/transport/io/writer.rb#8 + def initialize(io); end + + # Returns the value of attribute io. + # + # source://language_server-protocol//lib/language_server/protocol/transport/io/writer.rb#6 + def io; end + + # source://language_server-protocol//lib/language_server/protocol/transport/io/writer.rb#13 + def write(response); end +end + +# source://language_server-protocol//lib/language_server/protocol/transport/stdio/reader.rb#4 +module LanguageServer::Protocol::Transport::Stdio; end + +# source://language_server-protocol//lib/language_server/protocol/transport/stdio/reader.rb#5 +class LanguageServer::Protocol::Transport::Stdio::Reader < ::LanguageServer::Protocol::Transport::Io::Reader + # @return [Reader] a new instance of Reader + # + # source://language_server-protocol//lib/language_server/protocol/transport/stdio/reader.rb#6 + def initialize; end +end + +# source://language_server-protocol//lib/language_server/protocol/transport/stdio/writer.rb#5 +class LanguageServer::Protocol::Transport::Stdio::Writer < ::LanguageServer::Protocol::Transport::Io::Writer + # @return [Writer] a new instance of Writer + # + # source://language_server-protocol//lib/language_server/protocol/transport/stdio/writer.rb#6 + def initialize; end +end + +# source://language_server-protocol//lib/language_server/protocol/version.rb#3 +LanguageServer::Protocol::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/launchy@2.5.2.rbi b/sorbet/rbi/gems/launchy@2.5.2.rbi deleted file mode 100644 index be3b110e4..000000000 --- a/sorbet/rbi/gems/launchy@2.5.2.rbi +++ /dev/null @@ -1,833 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `launchy` gem. -# Please instead update this file by running `bin/tapioca gem launchy`. - -# The entry point into Launchy. This is the sole supported public API. -# -# Launchy.open( uri, options = {} ) -# -# The currently defined global options are: -# -# :debug Turn on debugging output -# :application Explicitly state what application class is going to be used. -# This must be a child class of Launchy::Application -# :host_os Explicitly state what host operating system to pretend to be -# :ruby_engine Explicitly state what ruby engine to pretend to be under -# :dry_run Do nothing and print the command that would be executed on $stdout -# -# Other options may be used, and those will be passed directly to the -# application class -# -# source://launchy//lib/launchy.rb#20 -module Launchy - class << self - # source://launchy//lib/launchy.rb#43 - def app_for_uri(uri); end - - # source://launchy//lib/launchy.rb#47 - def app_for_uri_string(s); end - - # source://launchy//lib/launchy.rb#95 - def application; end - - # source://launchy//lib/launchy.rb#91 - def application=(app); end - - # source://launchy//lib/launchy.rb#123 - def bug_report_message; end - - # source://launchy//lib/launchy.rb#81 - def debug=(d); end - - # we may do logging before a call to 'open', hence the need to check - # LAUNCHY_DEBUG here - # - # @return [Boolean] - # - # source://launchy//lib/launchy.rb#87 - def debug?; end - - # source://launchy//lib/launchy.rb#115 - def dry_run=(dry_run); end - - # @return [Boolean] - # - # source://launchy//lib/launchy.rb#119 - def dry_run?; end - - # source://launchy//lib/launchy.rb#72 - def extract_global_options(options); end - - # source://launchy//lib/launchy.rb#103 - def host_os; end - - # source://launchy//lib/launchy.rb#99 - def host_os=(host_os); end - - # source://launchy//lib/launchy.rb#127 - def log(msg); end - - # Launch an application for the given uri string - # - # source://launchy//lib/launchy.rb#26 - def open(uri_s, options = T.unsafe(nil), &error_block); end - - # source://launchy//lib/launchy.rb#131 - def path; end - - # source://launchy//lib/launchy.rb#135 - def path=(path); end - - # source://launchy//lib/launchy.rb#63 - def reset_global_options; end - - # source://launchy//lib/launchy.rb#111 - def ruby_engine; end - - # source://launchy//lib/launchy.rb#107 - def ruby_engine=(ruby_engine); end - - # @raise [Launchy::ArgumentError] - # - # source://launchy//lib/launchy.rb#51 - def string_to_uri(s); end - - private - - # source://launchy//lib/launchy.rb#140 - def to_bool(arg); end - end -end - -# Application is the base class of all the application types that launchy may -# invoke. It essentially defines the public api of the launchy system. -# -# Every class that inherits from Application must define: -# -# 1. A constructor taking no parameters -# 2. An instance method 'open' taking a string or URI as the first parameter and a -# hash as the second -# 3. A class method 'handles?' that takes a String and returns true if that -# class can handle the input. -# -# source://launchy//lib/launchy/application.rb#14 -class Launchy::Application - extend ::Launchy::DescendantTracker - - # @return [Application] a new instance of Application - # - # source://launchy//lib/launchy/application.rb#47 - def initialize; end - - # source://launchy//lib/launchy/application.rb#53 - def find_executable(bin, *paths); end - - # Returns the value of attribute host_os_family. - # - # source://launchy//lib/launchy/application.rb#43 - def host_os_family; end - - # Returns the value of attribute ruby_engine. - # - # source://launchy//lib/launchy/application.rb#44 - def ruby_engine; end - - # source://launchy//lib/launchy/application.rb#57 - def run(cmd, *args); end - - # Returns the value of attribute runner. - # - # source://launchy//lib/launchy/application.rb#45 - def runner; end - - class << self - # Find the given executable in the available paths - # - # source://launchy//lib/launchy/application.rb#29 - def find_executable(bin, *paths); end - - # Find the application that handles the given uri. - # - # returns the Class that can handle the uri - # - # @raise [ApplicationNotFoundError] - # - # source://launchy//lib/launchy/application.rb#21 - def handling(uri); end - end -end - -# The class handling the browser application and all of its schemes -# -# source://launchy//lib/launchy/applications/browser.rb#5 -class Launchy::Application::Browser < ::Launchy::Application - # use a call back mechanism to get the right app_list that is decided by the - # host_os_family class. - # - # source://launchy//lib/launchy/applications/browser.rb#36 - def app_list; end - - # Get the full commandline of what we are going to add the uri to - # - # @raise [Launchy::CommandNotFoundError] - # - # source://launchy//lib/launchy/applications/browser.rb#49 - def browser_cmdline; end - - # source://launchy//lib/launchy/applications/browser.rb#40 - def browser_env; end - - # source://launchy//lib/launchy/applications/browser.rb#66 - def cmd_and_args(uri, options = T.unsafe(nil)); end - - # source://launchy//lib/launchy/applications/browser.rb#19 - def cygwin_app_list; end - - # hardcode this to open? - # - # source://launchy//lib/launchy/applications/browser.rb#24 - def darwin_app_list; end - - # source://launchy//lib/launchy/applications/browser.rb#28 - def nix_app_list; end - - # final assembly of the command and do %s substitution - # http://www.catb.org/~esr/BROWSER/index.html - # - # source://launchy//lib/launchy/applications/browser.rb#77 - def open(uri, options = T.unsafe(nil)); end - - # source://launchy//lib/launchy/applications/browser.rb#15 - def windows_app_list; end - - class << self - # @return [Boolean] - # - # source://launchy//lib/launchy/applications/browser.rb#10 - def handles?(uri); end - - # source://launchy//lib/launchy/applications/browser.rb#6 - def schemes; end - end -end - -# source://launchy//lib/launchy/error.rb#3 -class Launchy::ApplicationNotFoundError < ::Launchy::Error; end - -# source://launchy//lib/launchy/error.rb#5 -class Launchy::ArgumentError < ::Launchy::Error; end - -# source://launchy//lib/launchy/argv.rb#2 -class Launchy::Argv - # @return [Argv] a new instance of Argv - # - # source://launchy//lib/launchy/argv.rb#4 - def initialize(*args); end - - # source://launchy//lib/launchy/argv.rb#32 - def ==(other); end - - # source://launchy//lib/launchy/argv.rb#16 - def [](idx); end - - # Returns the value of attribute argv. - # - # source://launchy//lib/launchy/argv.rb#3 - def argv; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/argv.rb#24 - def blank?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/argv.rb#28 - def executable?; end - - # source://launchy//lib/launchy/argv.rb#8 - def to_s; end - - # source://launchy//lib/launchy/argv.rb#12 - def to_str; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/argv.rb#20 - def valid?; end -end - -# This class is deprecated and will be removed -# -# source://launchy//lib/launchy/deprecated.rb#5 -class Launchy::Browser - # source://launchy//lib/launchy/deprecated.rb#10 - def visit(url); end - - private - - # source://launchy//lib/launchy/deprecated.rb#48 - def _warn(msg = T.unsafe(nil)); end - - # source://launchy//lib/launchy/deprecated.rb#19 - def find_caller_context(stack); end - - # source://launchy//lib/launchy/deprecated.rb#35 - def report_caller_context(stack); end - - class << self - # source://launchy//lib/launchy/deprecated.rb#6 - def run(*args); end - end -end - -# source://launchy//lib/launchy/cli.rb#4 -class Launchy::Cli - # @return [Cli] a new instance of Cli - # - # source://launchy//lib/launchy/cli.rb#7 - def initialize; end - - # source://launchy//lib/launchy/cli.rb#75 - def error_output(error); end - - # source://launchy//lib/launchy/cli.rb#66 - def good_run(argv, env); end - - # Returns the value of attribute options. - # - # source://launchy//lib/launchy/cli.rb#6 - def options; end - - # source://launchy//lib/launchy/cli.rb#59 - def parse(argv, env); end - - # source://launchy//lib/launchy/cli.rb#11 - def parser; end - - # source://launchy//lib/launchy/cli.rb#85 - def run(argv = T.unsafe(nil), env = T.unsafe(nil)); end -end - -# source://launchy//lib/launchy/error.rb#4 -class Launchy::CommandNotFoundError < ::Launchy::Error; end - -# Use by either -# -# class Foo -# extend DescendantTracker -# end -# -# or -# -# class Foo -# class << self -# include DescendantTracker -# end -# end -# -# It will track all the classes that inherit from the extended class and keep -# them in a Set that is available via the 'children' method. -# -# source://launchy//lib/launchy/descendant_tracker.rb#22 -module Launchy::DescendantTracker - # The list of children that are registered - # - # source://launchy//lib/launchy/descendant_tracker.rb#31 - def children; end - - # Find one of the child classes by calling the given method - # and passing all the rest of the parameters to that method in - # each child - # - # source://launchy//lib/launchy/descendant_tracker.rb#42 - def find_child(method, *args); end - - # source://launchy//lib/launchy/descendant_tracker.rb#23 - def inherited(klass); end -end - -# source://launchy//lib/launchy/detect.rb#2 -module Launchy::Detect; end - -# source://launchy//lib/launchy/detect/host_os.rb#4 -class Launchy::Detect::HostOs - # @return [HostOs] a new instance of HostOs - # - # source://launchy//lib/launchy/detect/host_os.rb#10 - def initialize(host_os = T.unsafe(nil)); end - - # source://launchy//lib/launchy/detect/host_os.rb#22 - def default_host_os; end - - # Returns the value of attribute host_os. - # - # source://launchy//lib/launchy/detect/host_os.rb#6 - def host_os; end - - # source://launchy//lib/launchy/detect/host_os.rb#26 - def override_host_os; end - - # Returns the value of attribute host_os. - # - # source://launchy//lib/launchy/detect/host_os.rb#6 - def to_s; end - - # Returns the value of attribute host_os. - # - # source://launchy//lib/launchy/detect/host_os.rb#6 - def to_str; end -end - -# Detect the current host os family -# -# If the current host familiy cannot be detected then return -# HostOsFamily::Unknown -# -# source://launchy//lib/launchy/detect/host_os_family.rb#6 -class Launchy::Detect::HostOsFamily - extend ::Launchy::DescendantTracker - - # @return [HostOsFamily] a new instance of HostOsFamily - # - # source://launchy//lib/launchy/detect/host_os_family.rb#30 - def initialize(host_os = T.unsafe(nil)); end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#37 - def cygwin?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#35 - def darwin?; end - - # Returns the value of attribute host_os. - # - # source://launchy//lib/launchy/detect/host_os_family.rb#29 - def host_os; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#36 - def nix?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#34 - def windows?; end - - class << self - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#25 - def cygwin?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#23 - def darwin?; end - - # @raise [NotFoundError] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#12 - def detect(host_os = T.unsafe(nil)); end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#18 - def matches?(host_os); end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#24 - def nix?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/host_os_family.rb#22 - def windows?; end - end -end - -# source://launchy//lib/launchy/detect/host_os_family.rb#64 -class Launchy::Detect::HostOsFamily::Cygwin < ::Launchy::Detect::HostOsFamily - # source://launchy//lib/launchy/detect/host_os_family.rb#68 - def app_list(app); end - - class << self - # source://launchy//lib/launchy/detect/host_os_family.rb#65 - def matching_regex; end - end -end - -# source://launchy//lib/launchy/detect/host_os_family.rb#50 -class Launchy::Detect::HostOsFamily::Darwin < ::Launchy::Detect::HostOsFamily - # source://launchy//lib/launchy/detect/host_os_family.rb#54 - def app_list(app); end - - class << self - # source://launchy//lib/launchy/detect/host_os_family.rb#51 - def matching_regex; end - end -end - -# source://launchy//lib/launchy/detect/host_os_family.rb#57 -class Launchy::Detect::HostOsFamily::Nix < ::Launchy::Detect::HostOsFamily - # source://launchy//lib/launchy/detect/host_os_family.rb#61 - def app_list(app); end - - class << self - # source://launchy//lib/launchy/detect/host_os_family.rb#58 - def matching_regex; end - end -end - -# source://launchy//lib/launchy/detect/host_os_family.rb#7 -class Launchy::Detect::HostOsFamily::NotFoundError < ::Launchy::Error; end - -# --------------------------- -# All known host os families -# --------------------------- -# -# source://launchy//lib/launchy/detect/host_os_family.rb#43 -class Launchy::Detect::HostOsFamily::Windows < ::Launchy::Detect::HostOsFamily - # source://launchy//lib/launchy/detect/host_os_family.rb#47 - def app_list(app); end - - class << self - # source://launchy//lib/launchy/detect/host_os_family.rb#44 - def matching_regex; end - end -end - -# Detect the current desktop environment for *nix machines -# Currently this is Linux centric. The detection is based upon the detection -# used by xdg-open from http://portland.freedesktop.org/ -# -# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#6 -class Launchy::Detect::NixDesktopEnvironment - extend ::Launchy::DescendantTracker - - class << self - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#25 - def browsers; end - - # Detect the current *nix desktop environment - # - # If the current dekstop environment be detected, the return - # NixDekstopEnvironment::Unknown - # - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#15 - def detect; end - - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#21 - def fallback_browsers; end - end -end - -# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#44 -class Launchy::Detect::NixDesktopEnvironment::Gnome < ::Launchy::Detect::NixDesktopEnvironment - class << self - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#50 - def browser; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#45 - def is_current_desktop_environment?; end - end -end - -# --------------------------------------- -# The list of known desktop environments -# --------------------------------------- -# -# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#33 -class Launchy::Detect::NixDesktopEnvironment::Kde < ::Launchy::Detect::NixDesktopEnvironment - class << self - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#39 - def browser; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#34 - def is_current_desktop_environment?; end - end -end - -# The one that is found when all else fails. And this must be declared last -# -# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#81 -class Launchy::Detect::NixDesktopEnvironment::NotFound < ::Launchy::Detect::NixDesktopEnvironment - class << self - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#86 - def browser; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#82 - def is_current_desktop_environment?; end - end -end - -# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#7 -class Launchy::Detect::NixDesktopEnvironment::NotFoundError < ::Launchy::Error; end - -# Fall back environment as the last case -# -# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#70 -class Launchy::Detect::NixDesktopEnvironment::Xdg < ::Launchy::Detect::NixDesktopEnvironment - class << self - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#75 - def browser; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#71 - def is_current_desktop_environment?; end - end -end - -# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#55 -class Launchy::Detect::NixDesktopEnvironment::Xfce < ::Launchy::Detect::NixDesktopEnvironment - class << self - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#64 - def browser; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#56 - def is_current_desktop_environment?; end - end -end - -# source://launchy//lib/launchy/detect/ruby_engine.rb#2 -class Launchy::Detect::RubyEngine - extend ::Launchy::DescendantTracker - - # @return [RubyEngine] a new instance of RubyEngine - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#40 - def initialize(ruby_engine = T.unsafe(nil)); end - - # Returns the value of attribute ruby_engine. - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#38 - def ruby_engine; end - - # Returns the value of attribute ruby_engine. - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#38 - def to_s; end - - class << self - # Detect the current ruby engine. - # - # If the current ruby engine cannot be detected, the return - # RubyEngine::Unknown - # - # @raise [NotFoundError] - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#11 - def detect(ruby_engine = T.unsafe(nil)); end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#29 - def is_current_engine?(ruby_engine); end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#34 - def jruby?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#36 - def macruby?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#33 - def mri?; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#35 - def rbx?; end - - # source://launchy//lib/launchy/detect/ruby_engine.rb#17 - def ruby_engine_error_message(ruby_engine); end - end -end - -# source://launchy//lib/launchy/detect/ruby_engine.rb#66 -class Launchy::Detect::RubyEngine::Jruby < ::Launchy::Detect::RubyEngine - class << self - # source://launchy//lib/launchy/detect/ruby_engine.rb#67 - def engine_name; end - end -end - -# source://launchy//lib/launchy/detect/ruby_engine.rb#74 -class Launchy::Detect::RubyEngine::MacRuby < ::Launchy::Detect::RubyEngine - class << self - # source://launchy//lib/launchy/detect/ruby_engine.rb#75 - def engine_name; end - end -end - -# This is the ruby engine if the RUBY_ENGINE constant is not defined -# -# source://launchy//lib/launchy/detect/ruby_engine.rb#55 -class Launchy::Detect::RubyEngine::Mri < ::Launchy::Detect::RubyEngine - class << self - # source://launchy//lib/launchy/detect/ruby_engine.rb#56 - def engine_name; end - - # @return [Boolean] - # - # source://launchy//lib/launchy/detect/ruby_engine.rb#57 - def is_current_engine?(ruby_engine); end - end -end - -# source://launchy//lib/launchy/detect/ruby_engine.rb#3 -class Launchy::Detect::RubyEngine::NotFoundError < ::Launchy::Error; end - -# source://launchy//lib/launchy/detect/ruby_engine.rb#70 -class Launchy::Detect::RubyEngine::Rbx < ::Launchy::Detect::RubyEngine - class << self - # source://launchy//lib/launchy/detect/ruby_engine.rb#71 - def engine_name; end - end -end - -# source://launchy//lib/launchy/detect/runner.rb#5 -class Launchy::Detect::Runner - extend ::Launchy::DescendantTracker - - # source://launchy//lib/launchy/detect/runner.rb#46 - def commandline_normalize(cmdline); end - - # source://launchy//lib/launchy/detect/runner.rb#53 - def dry_run(cmd, *args); end - - # @raise [Launchy::CommandNotFoundError] - # - # source://launchy//lib/launchy/detect/runner.rb#57 - def run(cmd, *args); end - - # cut it down to just the shell commands that will be passed to exec or - # posix_spawn. The cmd argument is split according to shell rules and the - # args are not escaped because they whole set is passed to system as *args - # and in that case system shell escaping rules are not done. - # - # source://launchy//lib/launchy/detect/runner.rb#40 - def shell_commands(cmd, args); end - - class << self - # Detect the current command runner - # - # This will return an instance of the Runner to be used to do the - # application launching. - # - # If a runner cannot be detected then raise Runner::NotFoundError - # - # The runner rules are, in order: - # - # 1) If you are on windows, you use the Windows Runner no matter what - # 2) If you are using the jruby engine, use the Jruby Runner. Unless rule - # (1) took effect - # 3) Use Forkable (barring rules (1) and (2)) - # - # source://launchy//lib/launchy/detect/runner.rb#23 - def detect; end - end -end - -# source://launchy//lib/launchy/detect/runner.rb#116 -class Launchy::Detect::Runner::Forkable < ::Launchy::Detect::Runner - # Returns the value of attribute child_pid. - # - # source://launchy//lib/launchy/detect/runner.rb#117 - def child_pid; end - - # source://launchy//lib/launchy/detect/runner.rb#119 - def wet_run(cmd, *args); end - - private - - # attaching to a StringIO instead of reopening so we don't loose the - # STDERR, needed for exec_or_raise. - # - # source://launchy//lib/launchy/detect/runner.rb#133 - def close_file_descriptors; end - - # source://launchy//lib/launchy/detect/runner.rb#143 - def exec_or_raise(cmd, *args); end -end - -# source://launchy//lib/launchy/detect/runner.rb#109 -class Launchy::Detect::Runner::Jruby < ::Launchy::Detect::Runner - # source://launchy//lib/launchy/detect/runner.rb#110 - def wet_run(cmd, *args); end -end - -# source://launchy//lib/launchy/detect/runner.rb#6 -class Launchy::Detect::Runner::NotFoundError < ::Launchy::Error; end - -# --------------------------------------- -# The list of known runners -# --------------------------------------- -# -# source://launchy//lib/launchy/detect/runner.rb#71 -class Launchy::Detect::Runner::Windows < ::Launchy::Detect::Runner - # source://launchy//lib/launchy/detect/runner.rb#73 - def all_args(cmd, *args); end - - # source://launchy//lib/launchy/detect/runner.rb#79 - def dry_run(cmd, *args); end - - # escape the reserved shell characters in windows command shell - # http://technet.microsoft.com/en-us/library/cc723564.aspx - # - # Also make sure that the item after 'start' is guaranteed to be quoted. - # https://github.com/copiousfreetime/launchy/issues/62 - # - # source://launchy//lib/launchy/detect/runner.rb#88 - def shell_commands(cmd, *args); end - - # source://launchy//lib/launchy/detect/runner.rb#104 - def wet_run(cmd, *args); end -end - -# source://launchy//lib/launchy/error.rb#2 -class Launchy::Error < ::StandardError; end - -# source://launchy//lib/launchy/version.rb#2 -Launchy::VERSION = T.let(T.unsafe(nil), String) - -# source://launchy//lib/launchy/version.rb#4 -module Launchy::Version - class << self - # source://launchy//lib/launchy/version.rb#10 - def to_a; end - - # source://launchy//lib/launchy/version.rb#14 - def to_s; end - end -end - -# source://launchy//lib/launchy/version.rb#6 -Launchy::Version::MAJOR = T.let(T.unsafe(nil), Integer) - -# source://launchy//lib/launchy/version.rb#7 -Launchy::Version::MINOR = T.let(T.unsafe(nil), Integer) - -# source://launchy//lib/launchy/version.rb#8 -Launchy::Version::PATCH = T.let(T.unsafe(nil), Integer) diff --git a/sorbet/rbi/gems/launchy@3.0.1.rbi b/sorbet/rbi/gems/launchy@3.0.1.rbi new file mode 100644 index 000000000..06f0b4b1b --- /dev/null +++ b/sorbet/rbi/gems/launchy@3.0.1.rbi @@ -0,0 +1,663 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `launchy` gem. +# Please instead update this file by running `bin/tapioca gem launchy`. + + +# The entry point into Launchy. This is the sole supported public API. +# +# Launchy.open( uri, options = {} ) +# +# The currently defined global options are: +# +# :debug Turn on debugging output +# :application Explicitly state what application class is going to be used. +# This must be a child class of Launchy::Application +# :host_os Explicitly state what host operating system to pretend to be +# :dry_run Do nothing and print the command that would be executed on $stdout +# +# Other options may be used, and those will be passed directly to the +# application class +# +# source://launchy//lib/launchy.rb#24 +module Launchy + class << self + # source://launchy//lib/launchy.rb#60 + def app_for_name(name); end + + # source://launchy//lib/launchy.rb#56 + def app_for_uri(uri); end + + # source://launchy//lib/launchy.rb#66 + def app_for_uri_string(str); end + + # source://launchy//lib/launchy.rb#113 + def application; end + + # source://launchy//lib/launchy.rb#109 + def application=(app); end + + # source://launchy//lib/launchy.rb#133 + def bug_report_message; end + + # source://launchy//lib/launchy.rb#99 + def debug=(enabled); end + + # we may do logging before a call to 'open', hence the need to check + # LAUNCHY_DEBUG here + # + # @return [Boolean] + # + # source://launchy//lib/launchy.rb#105 + def debug?; end + + # source://launchy//lib/launchy.rb#125 + def dry_run=(dry_run); end + + # @return [Boolean] + # + # source://launchy//lib/launchy.rb#129 + def dry_run?; end + + # source://launchy//lib/launchy.rb#91 + def extract_global_options(options); end + + # source://launchy//lib/launchy.rb#121 + def host_os; end + + # source://launchy//lib/launchy.rb#117 + def host_os=(host_os); end + + # source://launchy//lib/launchy.rb#137 + def log(msg); end + + # Launch an application for the given uri string + # + # source://launchy//lib/launchy.rb#29 + def open(uri_s, options = T.unsafe(nil)); end + + # source://launchy//lib/launchy.rb#141 + def path; end + + # source://launchy//lib/launchy.rb#145 + def path=(path); end + + # source://launchy//lib/launchy.rb#83 + def reset_global_options; end + + # @raise [Launchy::ArgumentError] + # + # source://launchy//lib/launchy.rb#70 + def string_to_uri(str); end + + private + + # source://launchy//lib/launchy.rb#151 + def to_bool(arg); end + end +end + +# Application is the base class of all the application types that launchy may +# invoke. It essentially defines the public api of the launchy system. +# +# Every class that inherits from Application must define: +# +# 1. A constructor taking no parameters +# 2. An instance method 'open' taking a string or URI as the first parameter and a +# hash as the second +# 3. A class method 'handles?' that takes a String and returns true if that +# class can handle the input. +# +# source://launchy//lib/launchy/application.rb#16 +class Launchy::Application + extend ::Launchy::DescendantTracker + + # @return [Application] a new instance of Application + # + # source://launchy//lib/launchy/application.rb#66 + def initialize; end + + # source://launchy//lib/launchy/application.rb#71 + def find_executable(bin, *paths); end + + # Returns the value of attribute host_os_family. + # + # source://launchy//lib/launchy/application.rb#64 + def host_os_family; end + + # source://launchy//lib/launchy/application.rb#75 + def run(cmd, *args); end + + # Returns the value of attribute runner. + # + # source://launchy//lib/launchy/application.rb#64 + def runner; end + + class << self + # Find the given executable in the available paths + # + # returns the path to the executable or nil if not found + # + # source://launchy//lib/launchy/application.rb#43 + def find_executable(bin, *paths); end + + # Find the application with the given name + # + # returns the Class that has the given name + # + # @raise [ApplicationNotFoundError] + # + # source://launchy//lib/launchy/application.rb#33 + def for_name(name); end + + # Find the application that handles the given uri. + # + # returns the Class that can handle the uri + # + # @raise [ApplicationNotFoundError] + # + # source://launchy//lib/launchy/application.rb#23 + def handling(uri); end + + # Does this class have the given name-like string? + # + # returns true if the class has the given name + # + # @return [Boolean] + # + # source://launchy//lib/launchy/application.rb#59 + def has_name?(qname); end + end +end + +# The class handling the browser application and all of its schemes +# +# source://launchy//lib/launchy/applications/browser.rb#8 +class Launchy::Application::Browser < ::Launchy::Application + # use a call back mechanism to get the right app_list that is decided by the + # host_os_family class. + # + # source://launchy//lib/launchy/applications/browser.rb#40 + def app_list; end + + # Get the full commandline of what we are going to add the uri to + # + # @raise [Launchy::CommandNotFoundError] + # + # source://launchy//lib/launchy/applications/browser.rb#54 + def browser_cmdline; end + + # source://launchy//lib/launchy/applications/browser.rb#44 + def browser_env; end + + # source://launchy//lib/launchy/applications/browser.rb#72 + def cmd_and_args(uri, _options = T.unsafe(nil)); end + + # source://launchy//lib/launchy/applications/browser.rb#23 + def cygwin_app_list; end + + # hardcode this to open? + # + # source://launchy//lib/launchy/applications/browser.rb#28 + def darwin_app_list; end + + # source://launchy//lib/launchy/applications/browser.rb#32 + def nix_app_list; end + + # final assembly of the command and do %s substitution + # http://www.catb.org/~esr/BROWSER/index.html + # + # source://launchy//lib/launchy/applications/browser.rb#81 + def open(uri, options = T.unsafe(nil)); end + + # source://launchy//lib/launchy/applications/browser.rb#19 + def windows_app_list; end + + class << self + # @return [Boolean] + # + # source://launchy//lib/launchy/applications/browser.rb#13 + def handles?(uri); end + + # source://launchy//lib/launchy/applications/browser.rb#9 + def schemes; end + end +end + +# source://launchy//lib/launchy/error.rb#5 +class Launchy::ApplicationNotFoundError < ::Launchy::Error; end + +# source://launchy//lib/launchy/error.rb#7 +class Launchy::ArgumentError < ::Launchy::Error; end + +# Internal: Ecapsulate the commandline argumens passed to Launchy +# +# source://launchy//lib/launchy/argv.rb#6 +class Launchy::Argv + # @return [Argv] a new instance of Argv + # + # source://launchy//lib/launchy/argv.rb#9 + def initialize(*args); end + + # source://launchy//lib/launchy/argv.rb#37 + def ==(other); end + + # source://launchy//lib/launchy/argv.rb#21 + def [](idx); end + + # Returns the value of attribute argv. + # + # source://launchy//lib/launchy/argv.rb#7 + def argv; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/argv.rb#29 + def blank?; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/argv.rb#33 + def executable?; end + + # source://launchy//lib/launchy/argv.rb#13 + def to_s; end + + # source://launchy//lib/launchy/argv.rb#17 + def to_str; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/argv.rb#25 + def valid?; end +end + +# Internal: Command line interface for Launchy +# +# source://launchy//lib/launchy/cli.rb#8 +class Launchy::Cli + # @return [Cli] a new instance of Cli + # + # source://launchy//lib/launchy/cli.rb#11 + def initialize; end + + # source://launchy//lib/launchy/cli.rb#70 + def error_output(error); end + + # source://launchy//lib/launchy/cli.rb#63 + def good_run(argv, env); end + + # Returns the value of attribute options. + # + # source://launchy//lib/launchy/cli.rb#9 + def options; end + + # source://launchy//lib/launchy/cli.rb#56 + def parse(argv, _env); end + + # source://launchy//lib/launchy/cli.rb#15 + def parser; end + + # source://launchy//lib/launchy/cli.rb#80 + def run(argv = T.unsafe(nil), env = T.unsafe(nil)); end +end + +# source://launchy//lib/launchy/error.rb#6 +class Launchy::CommandNotFoundError < ::Launchy::Error; end + +# Use by either +# +# class Foo +# extend DescendantTracker +# end +# +# or +# +# class Foo +# class << self +# include DescendantTracker +# end +# end +# +# It will track all the classes that inherit from the extended class and keep +# them in a Set that is available via the 'children' method. +# +# source://launchy//lib/launchy/descendant_tracker.rb#24 +module Launchy::DescendantTracker + # The list of children that are registered + # + # source://launchy//lib/launchy/descendant_tracker.rb#35 + def children; end + + # Find one of the child classes by calling the given method + # and passing all the rest of the parameters to that method in + # each child + # + # source://launchy//lib/launchy/descendant_tracker.rb#44 + def find_child(method, *args); end + + # source://launchy//lib/launchy/descendant_tracker.rb#25 + def inherited(klass); end +end + +# Internal: Namespace for detecting the environment that Launchy is running in +# +# source://launchy//lib/launchy/detect.rb#6 +module Launchy::Detect; end + +# Internal: Determine the host operating system that Launchy is running on +# +# source://launchy//lib/launchy/detect/host_os.rb#9 +class Launchy::Detect::HostOs + # @return [HostOs] a new instance of HostOs + # + # source://launchy//lib/launchy/detect/host_os.rb#14 + def initialize(host_os = T.unsafe(nil)); end + + # source://launchy//lib/launchy/detect/host_os.rb#26 + def default_host_os; end + + # Returns the value of attribute host_os. + # + # source://launchy//lib/launchy/detect/host_os.rb#10 + def host_os; end + + # source://launchy//lib/launchy/detect/host_os.rb#30 + def override_host_os; end + + # Returns the value of attribute host_os. + # + # source://launchy//lib/launchy/detect/host_os.rb#10 + def to_s; end + + # Returns the value of attribute host_os. + # + # source://launchy//lib/launchy/detect/host_os.rb#10 + def to_str; end +end + +# Detect the current host os family +# +# If the current host familiy cannot be detected then return +# HostOsFamily::Unknown +# +# source://launchy//lib/launchy/detect/host_os_family.rb#9 +class Launchy::Detect::HostOsFamily + extend ::Launchy::DescendantTracker + + # @return [HostOsFamily] a new instance of HostOsFamily + # + # source://launchy//lib/launchy/detect/host_os_family.rb#44 + def initialize(host_os = T.unsafe(nil)); end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#60 + def cygwin?; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#52 + def darwin?; end + + # Returns the value of attribute host_os. + # + # source://launchy//lib/launchy/detect/host_os_family.rb#42 + def host_os; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#56 + def nix?; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#48 + def windows?; end + + class << self + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#37 + def cygwin?; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#29 + def darwin?; end + + # @raise [NotFoundError] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#14 + def detect(host_os = T.unsafe(nil)); end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#21 + def matches?(host_os); end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#33 + def nix?; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/host_os_family.rb#25 + def windows?; end + end +end + +# Cygwin - if anyone is still using that +# +# source://launchy//lib/launchy/detect/host_os_family.rb#101 +class Launchy::Detect::HostOsFamily::Cygwin < ::Launchy::Detect::HostOsFamily + # source://launchy//lib/launchy/detect/host_os_family.rb#106 + def app_list(app); end + + class << self + # source://launchy//lib/launchy/detect/host_os_family.rb#102 + def matching_regex; end + end +end + +# Mac OS X family +# +# source://launchy//lib/launchy/detect/host_os_family.rb#79 +class Launchy::Detect::HostOsFamily::Darwin < ::Launchy::Detect::HostOsFamily + # source://launchy//lib/launchy/detect/host_os_family.rb#84 + def app_list(app); end + + class << self + # source://launchy//lib/launchy/detect/host_os_family.rb#80 + def matching_regex; end + end +end + +# All the *nix family of operating systems, and BSDs +# +# source://launchy//lib/launchy/detect/host_os_family.rb#90 +class Launchy::Detect::HostOsFamily::Nix < ::Launchy::Detect::HostOsFamily + # source://launchy//lib/launchy/detect/host_os_family.rb#95 + def app_list(app); end + + class << self + # source://launchy//lib/launchy/detect/host_os_family.rb#91 + def matching_regex; end + end +end + +# source://launchy//lib/launchy/detect/host_os_family.rb#10 +class Launchy::Detect::HostOsFamily::NotFoundError < ::Launchy::Error; end + +# --------------------------- +# All known host os families +# --------------------------- +# +# source://launchy//lib/launchy/detect/host_os_family.rb#68 +class Launchy::Detect::HostOsFamily::Windows < ::Launchy::Detect::HostOsFamily + # source://launchy//lib/launchy/detect/host_os_family.rb#73 + def app_list(app); end + + class << self + # source://launchy//lib/launchy/detect/host_os_family.rb#69 + def matching_regex; end + end +end + +# Detect the current desktop environment for *nix machines +# Currently this is Linux centric. The detection is based upon the detection +# used by xdg-open from http://portland.freedesktop.org/ +# +# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#9 +class Launchy::Detect::NixDesktopEnvironment + extend ::Launchy::DescendantTracker + + class << self + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#28 + def browsers; end + + # Detect the current *nix desktop environment + # + # If the current dekstop environment be detected, the return + # NixDekstopEnvironment::Unknown + # + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#18 + def detect; end + + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#24 + def fallback_browsers; end + end +end + +# Gnome desktop environment +# +# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#49 +class Launchy::Detect::NixDesktopEnvironment::Gnome < ::Launchy::Detect::NixDesktopEnvironment + class << self + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#55 + def browser; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#50 + def is_current_desktop_environment?; end + end +end + +# KDE desktop environment +# +# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#37 +class Launchy::Detect::NixDesktopEnvironment::Kde < ::Launchy::Detect::NixDesktopEnvironment + class << self + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#43 + def browser; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#38 + def is_current_desktop_environment?; end + end +end + +# The one that is found when all else fails. And this must be declared last +# +# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#87 +class Launchy::Detect::NixDesktopEnvironment::NotFound < ::Launchy::Detect::NixDesktopEnvironment + class << self + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#92 + def browser; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#88 + def is_current_desktop_environment?; end + end +end + +# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#10 +class Launchy::Detect::NixDesktopEnvironment::NotFoundError < ::Launchy::Error; end + +# Fall back environment as the last case +# +# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#76 +class Launchy::Detect::NixDesktopEnvironment::Xdg < ::Launchy::Detect::NixDesktopEnvironment + class << self + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#81 + def browser; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#77 + def is_current_desktop_environment?; end + end +end + +# Xfce desktop environment +# +# source://launchy//lib/launchy/detect/nix_desktop_environment.rb#61 +class Launchy::Detect::NixDesktopEnvironment::Xfce < ::Launchy::Detect::NixDesktopEnvironment + class << self + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#70 + def browser; end + + # @return [Boolean] + # + # source://launchy//lib/launchy/detect/nix_desktop_environment.rb#62 + def is_current_desktop_environment?; end + end +end + +# source://launchy//lib/launchy/error.rb#4 +class Launchy::Error < ::StandardError; end + +# Internal: Run a command in a child process +# +# source://launchy//lib/launchy/runner.rb#7 +class Launchy::Runner + # source://launchy//lib/launchy/runner.rb#47 + def commandline_normalize(cmdline); end + + # source://launchy//lib/launchy/runner.rb#32 + def dry_run(cmd, *args); end + + # source://launchy//lib/launchy/runner.rb#8 + def run(cmd, *args); end + + # cut it down to just the shell commands that will be passed to exec or + # posix_spawn. The cmd argument is split according to shell rules and the + # args are not escaped because the whole set is passed to system as *args + # and in that case system shell escaping rules are not done. + # + # source://launchy//lib/launchy/runner.rb#41 + def shell_commands(cmd, args); end + + # source://launchy//lib/launchy/runner.rb#21 + def wet_run(cmd, *args); end +end + +# source://launchy//lib/launchy/version.rb#4 +Launchy::VERSION = T.let(T.unsafe(nil), String) + +# Internal: Version number of Launchy +# +# source://launchy//lib/launchy/version.rb#7 +module Launchy::Version + class << self + # source://launchy//lib/launchy/version.rb#12 + def to_a; end + + # source://launchy//lib/launchy/version.rb#16 + def to_s; end + end +end + +# source://launchy//lib/launchy/version.rb#8 +Launchy::Version::MAJOR = T.let(T.unsafe(nil), Integer) + +# source://launchy//lib/launchy/version.rb#9 +Launchy::Version::MINOR = T.let(T.unsafe(nil), Integer) + +# source://launchy//lib/launchy/version.rb#10 +Launchy::Version::PATCH = T.let(T.unsafe(nil), Integer) diff --git a/sorbet/rbi/gems/libv8-node@18.16.0.0.rbi b/sorbet/rbi/gems/libv8-node@18.16.0.0.rbi deleted file mode 100644 index bc36b758f..000000000 --- a/sorbet/rbi/gems/libv8-node@18.16.0.0.rbi +++ /dev/null @@ -1,107 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `libv8-node` gem. -# Please instead update this file by running `bin/tapioca gem libv8-node`. - -# source://libv8-node//lib/libv8/node/version.rb#1 -module Libv8; end - -# source://libv8-node//lib/libv8/node/version.rb#3 -module Libv8::Node - class << self - # source://libv8-node//lib/libv8/node.rb#7 - def configure_makefile; end - end -end - -# from v8/include/v8-version.h -# -# source://libv8-node//lib/libv8/node/version.rb#6 -Libv8::Node::LIBV8_VERSION = T.let(T.unsafe(nil), String) - -# source://libv8-node//ext/libv8-node/location.rb#10 -class Libv8::Node::Location - # source://libv8-node//ext/libv8-node/location.rb#11 - def install!; end - - class << self - # source://libv8-node//ext/libv8-node/location.rb#19 - def load!; end - end -end - -# source://libv8-node//ext/libv8-node/location.rb#66 -class Libv8::Node::Location::MkmfContext - # source://libv8-node//ext/libv8-node/location.rb#67 - def incflags; end - - # source://libv8-node//ext/libv8-node/location.rb#71 - def ldflags; end -end - -# source://libv8-node//ext/libv8-node/location.rb#25 -class Libv8::Node::Location::Vendor < ::Libv8::Node::Location - # source://libv8-node//ext/libv8-node/location.rb#40 - def configure(context = T.unsafe(nil)); end - - # source://libv8-node//ext/libv8-node/location.rb#26 - def install!; end - - # source://libv8-node//ext/libv8-node/location.rb#45 - def verify_installation!; end -end - -# source://libv8-node//ext/libv8-node/location.rb#59 -class Libv8::Node::Location::Vendor::ArchiveNotFound < ::StandardError - # @return [ArchiveNotFound] a new instance of ArchiveNotFound - # - # source://libv8-node//ext/libv8-node/location.rb#60 - def initialize(filename); end -end - -# source://libv8-node//ext/libv8-node/location.rb#57 -class Libv8::Node::Location::Vendor::HeaderNotFound < ::StandardError; end - -# source://libv8-node//lib/libv8/node/version.rb#5 -Libv8::Node::NODE_VERSION = T.let(T.unsafe(nil), String) - -# source://libv8-node//ext/libv8-node/paths.rb#7 -module Libv8::Node::Paths - private - - # source://libv8-node//ext/libv8-node/paths.rb#26 - def config; end - - # source://libv8-node//ext/libv8-node/paths.rb#10 - def include_paths; end - - # source://libv8-node//ext/libv8-node/paths.rb#14 - def object_paths; end - - # source://libv8-node//ext/libv8-node/paths.rb#22 - def platform; end - - # source://libv8-node//ext/libv8-node/paths.rb#30 - def vendored_source_path; end - - class << self - # source://libv8-node//ext/libv8-node/paths.rb#26 - def config; end - - # source://libv8-node//ext/libv8-node/paths.rb#10 - def include_paths; end - - # source://libv8-node//ext/libv8-node/paths.rb#14 - def object_paths; end - - # source://libv8-node//ext/libv8-node/paths.rb#22 - def platform; end - - # source://libv8-node//ext/libv8-node/paths.rb#30 - def vendored_source_path; end - end -end - -# source://libv8-node//lib/libv8/node/version.rb#4 -Libv8::Node::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/libv8-node@18.19.0.0.rbi b/sorbet/rbi/gems/libv8-node@18.19.0.0.rbi new file mode 100644 index 000000000..6e74cd38f --- /dev/null +++ b/sorbet/rbi/gems/libv8-node@18.19.0.0.rbi @@ -0,0 +1,9 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `libv8-node` gem. +# Please instead update this file by running `bin/tapioca gem libv8-node`. + + +# THIS IS AN EMPTY RBI FILE. +# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/llhttp-ffi@0.4.0.rbi b/sorbet/rbi/gems/llhttp-ffi@0.5.0.rbi similarity index 99% rename from sorbet/rbi/gems/llhttp-ffi@0.4.0.rbi rename to sorbet/rbi/gems/llhttp-ffi@0.5.0.rbi index 46cc824d2..2b117c7e8 100644 --- a/sorbet/rbi/gems/llhttp-ffi@0.4.0.rbi +++ b/sorbet/rbi/gems/llhttp-ffi@0.5.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `llhttp-ffi` gem. # Please instead update this file by running `bin/tapioca gem llhttp-ffi`. + # source://llhttp-ffi//lib/llhttp.rb#6 module LLHttp extend ::FFI::Library diff --git a/sorbet/rbi/gems/logger@1.6.0.rbi b/sorbet/rbi/gems/logger@1.6.0.rbi new file mode 100644 index 000000000..5b699ff01 --- /dev/null +++ b/sorbet/rbi/gems/logger@1.6.0.rbi @@ -0,0 +1,903 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `logger` gem. +# Please instead update this file by running `bin/tapioca gem logger`. + + +# \Class \Logger provides a simple but sophisticated logging utility that +# you can use to create one or more +# {event logs}[https://en.wikipedia.org/wiki/Logging_(software)#Event_logs] +# for your program. +# Each such log contains a chronological sequence of entries +# that provides a record of the program's activities. +# +# == About the Examples +# +# All examples on this page assume that \Logger has been required: +# +# require 'logger' +# +# == Synopsis +# +# Create a log with Logger.new: +# +# # Single log file. +# logger = Logger.new('t.log') +# # Size-based rotated logging: 3 10-megabyte files. +# logger = Logger.new('t.log', 3, 10485760) +# # Period-based rotated logging: daily (also allowed: 'weekly', 'monthly'). +# logger = Logger.new('t.log', 'daily') +# # Log to an IO stream. +# logger = Logger.new($stdout) +# +# Add entries (level, message) with Logger#add: +# +# logger.add(Logger::DEBUG, 'Maximal debugging info') +# logger.add(Logger::INFO, 'Non-error information') +# logger.add(Logger::WARN, 'Non-error warning') +# logger.add(Logger::ERROR, 'Non-fatal error') +# logger.add(Logger::FATAL, 'Fatal error') +# logger.add(Logger::UNKNOWN, 'Most severe') +# +# Close the log with Logger#close: +# +# logger.close +# +# == Entries +# +# You can add entries with method Logger#add: +# +# logger.add(Logger::DEBUG, 'Maximal debugging info') +# logger.add(Logger::INFO, 'Non-error information') +# logger.add(Logger::WARN, 'Non-error warning') +# logger.add(Logger::ERROR, 'Non-fatal error') +# logger.add(Logger::FATAL, 'Fatal error') +# logger.add(Logger::UNKNOWN, 'Most severe') +# +# These shorthand methods also add entries: +# +# logger.debug('Maximal debugging info') +# logger.info('Non-error information') +# logger.warn('Non-error warning') +# logger.error('Non-fatal error') +# logger.fatal('Fatal error') +# logger.unknown('Most severe') +# +# When you call any of these methods, +# the entry may or may not be written to the log, +# depending on the entry's severity and on the log level; +# see {Log Level}[rdoc-ref:Logger@Log+Level] +# +# An entry always has: +# +# - A severity (the required argument to #add). +# - An automatically created timestamp. +# +# And may also have: +# +# - A message. +# - A program name. +# +# Example: +# +# logger = Logger.new($stdout) +# logger.add(Logger::INFO, 'My message.', 'mung') +# # => I, [2022-05-07T17:21:46.536234 #20536] INFO -- mung: My message. +# +# The default format for an entry is: +# +# "%s, [%s #%d] %5s -- %s: %s\n" +# +# where the values to be formatted are: +# +# - \Severity (one letter). +# - Timestamp. +# - Process id. +# - \Severity (word). +# - Program name. +# - Message. +# +# You can use a different entry format by: +# +# - Setting a custom format proc (affects following entries); +# see {formatter=}[Logger.html#attribute-i-formatter]. +# - Calling any of the methods above with a block +# (affects only the one entry). +# Doing so can have two benefits: +# +# - Context: the block can evaluate the entire program context +# and create a context-dependent message. +# - Performance: the block is not evaluated unless the log level +# permits the entry actually to be written: +# +# logger.error { my_slow_message_generator } +# +# Contrast this with the string form, where the string is +# always evaluated, regardless of the log level: +# +# logger.error("#{my_slow_message_generator}") +# +# === \Severity +# +# The severity of a log entry has two effects: +# +# - Determines whether the entry is selected for inclusion in the log; +# see {Log Level}[rdoc-ref:Logger@Log+Level]. +# - Indicates to any log reader (whether a person or a program) +# the relative importance of the entry. +# +# === Timestamp +# +# The timestamp for a log entry is generated automatically +# when the entry is created. +# +# The logged timestamp is formatted by method +# {Time#strftime}[rdoc-ref:Time#strftime] +# using this format string: +# +# '%Y-%m-%dT%H:%M:%S.%6N' +# +# Example: +# +# logger = Logger.new($stdout) +# logger.add(Logger::INFO) +# # => I, [2022-05-07T17:04:32.318331 #20536] INFO -- : nil +# +# You can set a different format using method #datetime_format=. +# +# === Message +# +# The message is an optional argument to an entry method: +# +# logger = Logger.new($stdout) +# logger.add(Logger::INFO, 'My message') +# # => I, [2022-05-07T18:15:37.647581 #20536] INFO -- : My message +# +# For the default entry formatter, Logger::Formatter, +# the message object may be: +# +# - A string: used as-is. +# - An Exception: message.message is used. +# - Anything else: message.inspect is used. +# +# *Note*: Logger::Formatter does not escape or sanitize +# the message passed to it. +# Developers should be aware that malicious data (user input) +# may be in the message, and should explicitly escape untrusted data. +# +# You can use a custom formatter to escape message data; +# see the example at {formatter=}[Logger.html#attribute-i-formatter]. +# +# === Program Name +# +# The program name is an optional argument to an entry method: +# +# logger = Logger.new($stdout) +# logger.add(Logger::INFO, 'My message', 'mung') +# # => I, [2022-05-07T18:17:38.084716 #20536] INFO -- mung: My message +# +# The default program name for a new logger may be set in the call to +# Logger.new via optional keyword argument +progname+: +# +# logger = Logger.new('t.log', progname: 'mung') +# +# The default program name for an existing logger may be set +# by a call to method #progname=: +# +# logger.progname = 'mung' +# +# The current program name may be retrieved with method +# {progname}[Logger.html#attribute-i-progname]: +# +# logger.progname # => "mung" +# +# == Log Level +# +# The log level setting determines whether an entry is actually +# written to the log, based on the entry's severity. +# +# These are the defined severities (least severe to most severe): +# +# logger = Logger.new($stdout) +# logger.add(Logger::DEBUG, 'Maximal debugging info') +# # => D, [2022-05-07T17:57:41.776220 #20536] DEBUG -- : Maximal debugging info +# logger.add(Logger::INFO, 'Non-error information') +# # => I, [2022-05-07T17:59:14.349167 #20536] INFO -- : Non-error information +# logger.add(Logger::WARN, 'Non-error warning') +# # => W, [2022-05-07T18:00:45.337538 #20536] WARN -- : Non-error warning +# logger.add(Logger::ERROR, 'Non-fatal error') +# # => E, [2022-05-07T18:02:41.592912 #20536] ERROR -- : Non-fatal error +# logger.add(Logger::FATAL, 'Fatal error') +# # => F, [2022-05-07T18:05:24.703931 #20536] FATAL -- : Fatal error +# logger.add(Logger::UNKNOWN, 'Most severe') +# # => A, [2022-05-07T18:07:54.657491 #20536] ANY -- : Most severe +# +# The default initial level setting is Logger::DEBUG, the lowest level, +# which means that all entries are to be written, regardless of severity: +# +# logger = Logger.new($stdout) +# logger.level # => 0 +# logger.add(0, "My message") +# # => D, [2022-05-11T15:10:59.773668 #20536] DEBUG -- : My message +# +# You can specify a different setting in a new logger +# using keyword argument +level+ with an appropriate value: +# +# logger = Logger.new($stdout, level: Logger::ERROR) +# logger = Logger.new($stdout, level: 'error') +# logger = Logger.new($stdout, level: :error) +# logger.level # => 3 +# +# With this level, entries with severity Logger::ERROR and higher +# are written, while those with lower severities are not written: +# +# logger = Logger.new($stdout, level: Logger::ERROR) +# logger.add(3) +# # => E, [2022-05-11T15:17:20.933362 #20536] ERROR -- : nil +# logger.add(2) # Silent. +# +# You can set the log level for an existing logger +# with method #level=: +# +# logger.level = Logger::ERROR +# +# These shorthand methods also set the level: +# +# logger.debug! # => 0 +# logger.info! # => 1 +# logger.warn! # => 2 +# logger.error! # => 3 +# logger.fatal! # => 4 +# +# You can retrieve the log level with method #level. +# +# logger.level = Logger::ERROR +# logger.level # => 3 +# +# These methods return whether a given +# level is to be written: +# +# logger.level = Logger::ERROR +# logger.debug? # => false +# logger.info? # => false +# logger.warn? # => false +# logger.error? # => true +# logger.fatal? # => true +# +# == Log File Rotation +# +# By default, a log file is a single file that grows indefinitely +# (until explicitly closed); there is no file rotation. +# +# To keep log files to a manageable size, +# you can use _log_ _file_ _rotation_, which uses multiple log files: +# +# - Each log file has entries for a non-overlapping +# time interval. +# - Only the most recent log file is open and active; +# the others are closed and inactive. +# +# === Size-Based Rotation +# +# For size-based log file rotation, call Logger.new with: +# +# - Argument +logdev+ as a file path. +# - Argument +shift_age+ with a positive integer: +# the number of log files to be in the rotation. +# - Argument +shift_size+ as a positive integer: +# the maximum size (in bytes) of each log file; +# defaults to 1048576 (1 megabyte). +# +# Examples: +# +# logger = Logger.new('t.log', 3) # Three 1-megabyte files. +# logger = Logger.new('t.log', 5, 10485760) # Five 10-megabyte files. +# +# For these examples, suppose: +# +# logger = Logger.new('t.log', 3) +# +# Logging begins in the new log file, +t.log+; +# the log file is "full" and ready for rotation +# when a new entry would cause its size to exceed +shift_size+. +# +# The first time +t.log+ is full: +# +# - +t.log+ is closed and renamed to +t.log.0+. +# - A new file +t.log+ is opened. +# +# The second time +t.log+ is full: +# +# - +t.log.0 is renamed as +t.log.1+. +# - +t.log+ is closed and renamed to +t.log.0+. +# - A new file +t.log+ is opened. +# +# Each subsequent time that +t.log+ is full, +# the log files are rotated: +# +# - +t.log.1+ is removed. +# - +t.log.0 is renamed as +t.log.1+. +# - +t.log+ is closed and renamed to +t.log.0+. +# - A new file +t.log+ is opened. +# +# === Periodic Rotation +# +# For periodic rotation, call Logger.new with: +# +# - Argument +logdev+ as a file path. +# - Argument +shift_age+ as a string period indicator. +# +# Examples: +# +# logger = Logger.new('t.log', 'daily') # Rotate log files daily. +# logger = Logger.new('t.log', 'weekly') # Rotate log files weekly. +# logger = Logger.new('t.log', 'monthly') # Rotate log files monthly. +# +# Example: +# +# logger = Logger.new('t.log', 'daily') +# +# When the given period expires: +# +# - The base log file, +t.log+ is closed and renamed +# with a date-based suffix such as +t.log.20220509+. +# - A new log file +t.log+ is opened. +# - Nothing is removed. +# +# The default format for the suffix is '%Y%m%d', +# which produces a suffix similar to the one above. +# You can set a different format using create-time option +# +shift_period_suffix+; +# see details and suggestions at +# {Time#strftime}[rdoc-ref:Time#strftime]. +class Logger + include ::Logger::Severity + + # :call-seq: + # Logger.new(logdev, shift_age = 0, shift_size = 1048576, **options) + # + # With the single argument +logdev+, + # returns a new logger with all default options: + # + # Logger.new('t.log') # => # + # + # Argument +logdev+ must be one of: + # + # - A string filepath: entries are to be written + # to the file at that path; if the file at that path exists, + # new entries are appended. + # - An IO stream (typically +$stdout+, +$stderr+. or an open file): + # entries are to be written to the given stream. + # - +nil+ or +File::NULL+: no entries are to be written. + # + # Examples: + # + # Logger.new('t.log') + # Logger.new($stdout) + # + # The keyword options are: + # + # - +level+: sets the log level; default value is Logger::DEBUG. + # See {Log Level}[rdoc-ref:Logger@Log+Level]: + # + # Logger.new('t.log', level: Logger::ERROR) + # + # - +progname+: sets the default program name; default is +nil+. + # See {Program Name}[rdoc-ref:Logger@Program+Name]: + # + # Logger.new('t.log', progname: 'mung') + # + # - +formatter+: sets the entry formatter; default is +nil+. + # See {formatter=}[Logger.html#attribute-i-formatter]. + # - +datetime_format+: sets the format for entry timestamp; + # default is +nil+. + # See #datetime_format=. + # - +binmode+: sets whether the logger writes in binary mode; + # default is +false+. + # - +shift_period_suffix+: sets the format for the filename suffix + # for periodic log file rotation; default is '%Y%m%d'. + # See {Periodic Rotation}[rdoc-ref:Logger@Periodic+Rotation]. + # + # @return [Logger] a new instance of Logger + # + # source://logger//logger.rb#578 + def initialize(logdev, shift_age = T.unsafe(nil), shift_size = T.unsafe(nil), level: T.unsafe(nil), progname: T.unsafe(nil), formatter: T.unsafe(nil), datetime_format: T.unsafe(nil), binmode: T.unsafe(nil), shift_period_suffix: T.unsafe(nil)); end + + # Writes the given +msg+ to the log with no formatting; + # returns the number of characters written, + # or +nil+ if no log device exists: + # + # logger = Logger.new($stdout) + # logger << 'My message.' # => 10 + # + # Output: + # + # My message. + # + # source://logger//logger.rb#684 + def <<(msg); end + + # Creates a log entry, which may or may not be written to the log, + # depending on the entry's severity and on the log level. + # See {Log Level}[rdoc-ref:Logger@Log+Level] + # and {Entries}[rdoc-ref:Logger@Entries] for details. + # + # Examples: + # + # logger = Logger.new($stdout, progname: 'mung') + # logger.add(Logger::INFO) + # logger.add(Logger::ERROR, 'No good') + # logger.add(Logger::ERROR, 'No good', 'gnum') + # + # Output: + # + # I, [2022-05-12T16:25:31.469726 #36328] INFO -- mung: mung + # E, [2022-05-12T16:25:55.349414 #36328] ERROR -- mung: No good + # E, [2022-05-12T16:26:35.841134 #36328] ERROR -- gnum: No good + # + # These convenience methods have implicit severity: + # + # - #debug. + # - #info. + # - #warn. + # - #error. + # - #fatal. + # - #unknown. + # + # source://logger//logger.rb#651 + def add(severity, message = T.unsafe(nil), progname = T.unsafe(nil)); end + + # Closes the logger; returns +nil+: + # + # logger = Logger.new('t.log') + # logger.close # => nil + # logger.info('foo') # Prints "log writing failed. closed stream" + # + # Related: Logger#reopen. + # + # source://logger//logger.rb#731 + def close; end + + # Returns the date-time format; see #datetime_format=. + # + # source://logger//logger.rb#438 + def datetime_format; end + + # Sets the date-time format. + # + # Argument +datetime_format+ should be either of these: + # + # - A string suitable for use as a format for method + # {Time#strftime}[rdoc-ref:Time#strftime]. + # - +nil+: the logger uses '%Y-%m-%dT%H:%M:%S.%6N'. + # + # source://logger//logger.rb#432 + def datetime_format=(datetime_format); end + + # Equivalent to calling #add with severity Logger::DEBUG. + # + # source://logger//logger.rb#690 + def debug(progname = T.unsafe(nil), &block); end + + # Sets the log level to Logger::DEBUG. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # source://logger//logger.rb#487 + def debug!; end + + # Returns +true+ if the log level allows entries with severity + # Logger::DEBUG to be written, +false+ otherwise. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # @return [Boolean] + # + # source://logger//logger.rb#482 + def debug?; end + + # Equivalent to calling #add with severity Logger::ERROR. + # + # source://logger//logger.rb#708 + def error(progname = T.unsafe(nil), &block); end + + # Sets the log level to Logger::ERROR. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # source://logger//logger.rb#520 + def error!; end + + # Returns +true+ if the log level allows entries with severity + # Logger::ERROR to be written, +false+ otherwise. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # @return [Boolean] + # + # source://logger//logger.rb#515 + def error?; end + + # Equivalent to calling #add with severity Logger::FATAL. + # + # source://logger//logger.rb#714 + def fatal(progname = T.unsafe(nil), &block); end + + # Sets the log level to Logger::FATAL. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # source://logger//logger.rb#531 + def fatal!; end + + # Returns +true+ if the log level allows entries with severity + # Logger::FATAL to be written, +false+ otherwise. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # @return [Boolean] + # + # source://logger//logger.rb#526 + def fatal?; end + + # Sets or retrieves the logger entry formatter proc. + # + # When +formatter+ is +nil+, the logger uses Logger::Formatter. + # + # When +formatter+ is a proc, a new entry is formatted by the proc, + # which is called with four arguments: + # + # - +severity+: The severity of the entry. + # - +time+: A Time object representing the entry's timestamp. + # - +progname+: The program name for the entry. + # - +msg+: The message for the entry (string or string-convertible object). + # + # The proc should return a string containing the formatted entry. + # + # This custom formatter uses + # {String#dump}[rdoc-ref:String#dump] + # to escape the message string: + # + # logger = Logger.new($stdout, progname: 'mung') + # original_formatter = logger.formatter || Logger::Formatter.new + # logger.formatter = proc { |severity, time, progname, msg| + # original_formatter.call(severity, time, progname, msg.dump) + # } + # logger.add(Logger::INFO, "hello \n ''") + # logger.add(Logger::INFO, "\f\x00\xff\\\"") + # + # Output: + # + # I, [2022-05-13T13:16:29.637488 #8492] INFO -- mung: "hello \n ''" + # I, [2022-05-13T13:16:29.637610 #8492] INFO -- mung: "\f\x00\xFF\\\"" + # + # source://logger//logger.rb#473 + def formatter; end + + # Sets or retrieves the logger entry formatter proc. + # + # When +formatter+ is +nil+, the logger uses Logger::Formatter. + # + # When +formatter+ is a proc, a new entry is formatted by the proc, + # which is called with four arguments: + # + # - +severity+: The severity of the entry. + # - +time+: A Time object representing the entry's timestamp. + # - +progname+: The program name for the entry. + # - +msg+: The message for the entry (string or string-convertible object). + # + # The proc should return a string containing the formatted entry. + # + # This custom formatter uses + # {String#dump}[rdoc-ref:String#dump] + # to escape the message string: + # + # logger = Logger.new($stdout, progname: 'mung') + # original_formatter = logger.formatter || Logger::Formatter.new + # logger.formatter = proc { |severity, time, progname, msg| + # original_formatter.call(severity, time, progname, msg.dump) + # } + # logger.add(Logger::INFO, "hello \n ''") + # logger.add(Logger::INFO, "\f\x00\xff\\\"") + # + # Output: + # + # I, [2022-05-13T13:16:29.637488 #8492] INFO -- mung: "hello \n ''" + # I, [2022-05-13T13:16:29.637610 #8492] INFO -- mung: "\f\x00\xFF\\\"" + # + # source://logger//logger.rb#473 + def formatter=(_arg0); end + + # Equivalent to calling #add with severity Logger::INFO. + # + # source://logger//logger.rb#696 + def info(progname = T.unsafe(nil), &block); end + + # Sets the log level to Logger::INFO. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # source://logger//logger.rb#498 + def info!; end + + # Returns +true+ if the log level allows entries with severity + # Logger::INFO to be written, +false+ otherwise. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # @return [Boolean] + # + # source://logger//logger.rb#493 + def info?; end + + # Logging severity threshold (e.g. Logger::INFO). + # + # source://logger//logger.rb#383 + def level; end + + # Sets the log level; returns +severity+. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # Argument +severity+ may be an integer, a string, or a symbol: + # + # logger.level = Logger::ERROR # => 3 + # logger.level = 3 # => 3 + # logger.level = 'error' # => "error" + # logger.level = :error # => :error + # + # Logger#sev_threshold= is an alias for Logger#level=. + # + # source://logger//logger.rb#399 + def level=(severity); end + + # Creates a log entry, which may or may not be written to the log, + # depending on the entry's severity and on the log level. + # See {Log Level}[rdoc-ref:Logger@Log+Level] + # and {Entries}[rdoc-ref:Logger@Entries] for details. + # + # Examples: + # + # logger = Logger.new($stdout, progname: 'mung') + # logger.add(Logger::INFO) + # logger.add(Logger::ERROR, 'No good') + # logger.add(Logger::ERROR, 'No good', 'gnum') + # + # Output: + # + # I, [2022-05-12T16:25:31.469726 #36328] INFO -- mung: mung + # E, [2022-05-12T16:25:55.349414 #36328] ERROR -- mung: No good + # E, [2022-05-12T16:26:35.841134 #36328] ERROR -- gnum: No good + # + # These convenience methods have implicit severity: + # + # - #debug. + # - #info. + # - #warn. + # - #error. + # - #fatal. + # - #unknown. + # + # source://logger//logger.rb#651 + def log(severity, message = T.unsafe(nil), progname = T.unsafe(nil)); end + + # Program name to include in log messages. + # + # source://logger//logger.rb#422 + def progname; end + + # Program name to include in log messages. + # + # source://logger//logger.rb#422 + def progname=(_arg0); end + + # Sets the logger's output stream: + # + # - If +logdev+ is +nil+, reopens the current output stream. + # - If +logdev+ is a filepath, opens the indicated file for append. + # - If +logdev+ is an IO stream + # (usually $stdout, $stderr, or an open File object), + # opens the stream for append. + # + # Example: + # + # logger = Logger.new('t.log') + # logger.add(Logger::ERROR, 'one') + # logger.close + # logger.add(Logger::ERROR, 'two') # Prints 'log writing failed. closed stream' + # logger.reopen + # logger.add(Logger::ERROR, 'three') + # logger.close + # File.readlines('t.log') + # # => + # # ["# Logfile created on 2022-05-12 14:21:19 -0500 by logger.rb/v1.5.0\n", + # # "E, [2022-05-12T14:21:27.596726 #22428] ERROR -- : one\n", + # # "E, [2022-05-12T14:23:05.847241 #22428] ERROR -- : three\n"] + # + # source://logger//logger.rb#619 + def reopen(logdev = T.unsafe(nil)); end + + # Logging severity threshold (e.g. Logger::INFO). + # + # source://logger//logger.rb#383 + def sev_threshold; end + + # Sets the log level; returns +severity+. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # Argument +severity+ may be an integer, a string, or a symbol: + # + # logger.level = Logger::ERROR # => 3 + # logger.level = 3 # => 3 + # logger.level = 'error' # => "error" + # logger.level = :error # => :error + # + # Logger#sev_threshold= is an alias for Logger#level=. + # + # source://logger//logger.rb#399 + def sev_threshold=(severity); end + + # Equivalent to calling #add with severity Logger::UNKNOWN. + # + # source://logger//logger.rb#720 + def unknown(progname = T.unsafe(nil), &block); end + + # Equivalent to calling #add with severity Logger::WARN. + # + # source://logger//logger.rb#702 + def warn(progname = T.unsafe(nil), &block); end + + # Sets the log level to Logger::WARN. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # source://logger//logger.rb#509 + def warn!; end + + # Returns +true+ if the log level allows entries with severity + # Logger::WARN to be written, +false+ otherwise. + # See {Log Level}[rdoc-ref:Logger@Log+Level]. + # + # @return [Boolean] + # + # source://logger//logger.rb#504 + def warn?; end + + # Adjust the log level during the block execution for the current Fiber only + # + # logger.with_level(:debug) do + # logger.debug { "Hello" } + # end + # + # source://logger//logger.rb#408 + def with_level(severity); end + + private + + # source://logger//logger.rb#744 + def format_message(severity, datetime, progname, msg); end + + # source://logger//logger.rb#740 + def format_severity(severity); end +end + +# Default formatter for log messages. +class Logger::Formatter + # @return [Formatter] a new instance of Formatter + # + # source://logger//logger/formatter.rb#11 + def initialize; end + + # source://logger//logger/formatter.rb#15 + def call(severity, time, progname, msg); end + + # Returns the value of attribute datetime_format. + # + # source://logger//logger/formatter.rb#9 + def datetime_format; end + + # Sets the attribute datetime_format + # + # @param value the value to set the attribute datetime_format to. + # + # source://logger//logger/formatter.rb#9 + def datetime_format=(_arg0); end + + private + + # source://logger//logger/formatter.rb#21 + def format_datetime(time); end + + # source://logger//logger/formatter.rb#25 + def msg2str(msg); end +end + +# source://logger//logger/formatter.rb#7 +Logger::Formatter::DatetimeFormat = T.let(T.unsafe(nil), String) + +# source://logger//logger/formatter.rb#6 +Logger::Formatter::Format = T.let(T.unsafe(nil), String) + +# Device used for logging messages. +class Logger::LogDevice + include ::Logger::Period + include ::MonitorMixin + + # @return [LogDevice] a new instance of LogDevice + # + # source://logger//logger/log_device.rb#14 + def initialize(log = T.unsafe(nil), shift_age: T.unsafe(nil), shift_size: T.unsafe(nil), shift_period_suffix: T.unsafe(nil), binmode: T.unsafe(nil)); end + + # source://logger//logger/log_device.rb#52 + def close; end + + # Returns the value of attribute dev. + # + # source://logger//logger/log_device.rb#10 + def dev; end + + # Returns the value of attribute filename. + # + # source://logger//logger/log_device.rb#11 + def filename; end + + # source://logger//logger/log_device.rb#62 + def reopen(log = T.unsafe(nil)); end + + # source://logger//logger/log_device.rb#31 + def write(message); end + + private + + # source://logger//logger/log_device.rb#119 + def add_log_header(file); end + + # source://logger//logger/log_device.rb#125 + def check_shift_log; end + + # source://logger//logger/log_device.rb#103 + def create_logfile(filename); end + + # source://logger//logger/log_device.rb#145 + def lock_shift_log; end + + # source://logger//logger/log_device.rb#95 + def open_logfile(filename); end + + # source://logger//logger/log_device.rb#79 + def set_dev(log); end + + # source://logger//logger/log_device.rb#176 + def shift_log_age; end + + # source://logger//logger/log_device.rb#188 + def shift_log_period(period_end); end +end + +module Logger::Period + private + + # source://logger//logger/period.rb#9 + def next_rotate_time(now, shift_age); end + + # source://logger//logger/period.rb#31 + def previous_period_end(now, shift_age); end + + class << self + # source://logger//logger/period.rb#9 + def next_rotate_time(now, shift_age); end + + # source://logger//logger/period.rb#31 + def previous_period_end(now, shift_age); end + end +end + +# source://logger//logger/period.rb#7 +Logger::Period::SiD = T.let(T.unsafe(nil), Integer) + +# \Severity label for logging (max 5 chars). +# +# source://logger//logger.rb#738 +Logger::SEV_LABEL = T.let(T.unsafe(nil), Array) + +# Logging severity. +module Logger::Severity + class << self + # source://logger//logger/severity.rb#29 + def coerce(severity); end + end +end + +# source://logger//logger/severity.rb#19 +Logger::Severity::LEVELS = T.let(T.unsafe(nil), Hash) diff --git a/sorbet/rbi/gems/lograge@0.12.0.rbi b/sorbet/rbi/gems/lograge@0.14.0.rbi similarity index 72% rename from sorbet/rbi/gems/lograge@0.12.0.rbi rename to sorbet/rbi/gems/lograge@0.14.0.rbi index b644e0958..9f73a7f5f 100644 --- a/sorbet/rbi/gems/lograge@0.12.0.rbi +++ b/sorbet/rbi/gems/lograge@0.14.0.rbi @@ -4,68 +4,72 @@ # This is an autogenerated file for types exported from the `lograge` gem. # Please instead update this file by running `bin/tapioca gem lograge`. + # source://lograge//lib/lograge/version.rb#3 module Lograge - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def application; end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def application=(val); end - # source://lograge//lib/lograge.rb#49 + # source://lograge//lib/lograge.rb#50 def before_format=(val); end - # source://lograge//lib/lograge.rb#35 + # source://lograge//lib/lograge.rb#36 def custom_options=(val); end - # source://lograge//lib/lograge.rb#106 + # source://lograge//lib/lograge.rb#107 def formatter; end - # source://lograge//lib/lograge.rb#106 + # source://lograge//lib/lograge.rb#107 def formatter=(val); end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def ignore_tests=(val); end - # source://lograge//lib/lograge.rb#98 + # source://lograge//lib/lograge.rb#99 def log_level; end - # source://lograge//lib/lograge.rb#98 + # source://lograge//lib/lograge.rb#99 def log_level=(val); end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def logger; end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def logger=(val); end private - # source://lograge//lib/lograge.rb#156 + # source://lograge//lib/lograge.rb#157 def attach_to_action_cable; end - # source://lograge//lib/lograge.rb#152 + # source://lograge//lib/lograge.rb#153 def attach_to_action_controller; end - # source://lograge//lib/lograge.rb#52 + # source://lograge//lib/lograge.rb#53 def before_format(data, payload); end - # source://lograge//lib/lograge.rb#77 + # source://lograge//lib/lograge.rb#78 def controller_field(params); end - # source://lograge//lib/lograge.rb#38 + # source://lograge//lib/lograge.rb#39 def custom_options(event); end - # source://lograge//lib/lograge.rb#192 + # source://lograge//lib/lograge.rb#228 + def deprecator; end + + # source://lograge//lib/lograge.rb#193 def disable_rack_cache_verbose_output; end - # source://lograge//lib/lograge.rb#175 + # source://lograge//lib/lograge.rb#176 def extend_base_class(klass); end - # source://lograge//lib/lograge.rb#85 + # source://lograge//lib/lograge.rb#86 def ignore(test); end - # source://lograge//lib/lograge.rb#93 + # source://lograge//lib/lograge.rb#94 def ignore?(event); end # Set conditions for events that should be ignored @@ -80,96 +84,102 @@ module Lograge # are given to 'ignore'. Both methods can be called multiple times, which # just adds more ignore conditions to a list that is checked before logging. # - # source://lograge//lib/lograge.rb#70 + # source://lograge//lib/lograge.rb#71 def ignore_actions(actions); end - # source://lograge//lib/lograge.rb#89 + # source://lograge//lib/lograge.rb#90 def ignore_nothing; end - # source://lograge//lib/lograge.rb#81 + # source://lograge//lib/lograge.rb#82 def ignore_tests; end - # source://lograge//lib/lograge.rb#196 + # source://lograge//lib/lograge.rb#197 def keep_original_rails_log; end - # source://lograge//lib/lograge.rb#223 + # source://lograge//lib/lograge.rb#224 def lograge_config; end - # source://lograge//lib/lograge.rb#206 + # source://lograge//lib/lograge.rb#234 + def notification_listeners_for(name); end + + # source://lograge//lib/lograge.rb#207 def rack_cache_hashlike?(app); end - # source://lograge//lib/lograge.rb#108 + # source://lograge//lib/lograge.rb#109 def remove_existing_log_subscriptions; end - # source://lograge//lib/lograge.rb#148 + # source://lograge//lib/lograge.rb#149 def set_formatter; end - # source://lograge//lib/lograge.rb#143 + # source://lograge//lib/lograge.rb#144 def set_ignores; end - # source://lograge//lib/lograge.rb#185 + # source://lograge//lib/lograge.rb#186 def set_lograge_log_options; end - # source://lograge//lib/lograge.rb#128 + # source://lograge//lib/lograge.rb#129 def setup(app); end - # source://lograge//lib/lograge.rb#163 + # source://lograge//lib/lograge.rb#164 def setup_custom_payload; end # TODO: Remove with version 1.0 # - # source://lograge//lib/lograge.rb#213 + # source://lograge//lib/lograge.rb#214 def support_deprecated_config; end - # source://lograge//lib/lograge.rb#119 + # source://lograge//lib/lograge.rb#120 def unsubscribe(component, subscriber); end class << self - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def application; end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def application=(val); end - # source://lograge//lib/lograge.rb#156 + # source://lograge//lib/lograge.rb#157 def attach_to_action_cable; end - # source://lograge//lib/lograge.rb#152 + # source://lograge//lib/lograge.rb#153 def attach_to_action_controller; end - # source://lograge//lib/lograge.rb#52 + # source://lograge//lib/lograge.rb#53 def before_format(data, payload); end - # source://lograge//lib/lograge.rb#49 + # source://lograge//lib/lograge.rb#50 def before_format=(val); end - # source://lograge//lib/lograge.rb#77 + # source://lograge//lib/lograge.rb#78 def controller_field(params); end - # source://lograge//lib/lograge.rb#38 + # source://lograge//lib/lograge.rb#39 def custom_options(event); end - # source://lograge//lib/lograge.rb#35 + # source://lograge//lib/lograge.rb#36 def custom_options=(val); end - # source://lograge//lib/lograge.rb#192 + # source://lograge//lib/lograge.rb#228 + def deprecator; end + + # source://lograge//lib/lograge.rb#193 def disable_rack_cache_verbose_output; end - # source://lograge//lib/lograge.rb#175 + # source://lograge//lib/lograge.rb#176 def extend_base_class(klass); end - # source://lograge//lib/lograge.rb#106 + # source://lograge//lib/lograge.rb#107 def formatter; end - # source://lograge//lib/lograge.rb#106 + # source://lograge//lib/lograge.rb#107 def formatter=(val); end - # source://lograge//lib/lograge.rb#85 + # source://lograge//lib/lograge.rb#86 def ignore(test); end # @return [Boolean] # - # source://lograge//lib/lograge.rb#93 + # source://lograge//lib/lograge.rb#94 def ignore?(event); end # Set conditions for events that should be ignored @@ -184,67 +194,70 @@ module Lograge # are given to 'ignore'. Both methods can be called multiple times, which # just adds more ignore conditions to a list that is checked before logging. # - # source://lograge//lib/lograge.rb#70 + # source://lograge//lib/lograge.rb#71 def ignore_actions(actions); end - # source://lograge//lib/lograge.rb#89 + # source://lograge//lib/lograge.rb#90 def ignore_nothing; end - # source://lograge//lib/lograge.rb#81 + # source://lograge//lib/lograge.rb#82 def ignore_tests; end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def ignore_tests=(val); end - # source://lograge//lib/lograge.rb#196 + # source://lograge//lib/lograge.rb#197 def keep_original_rails_log; end - # source://lograge//lib/lograge.rb#98 + # source://lograge//lib/lograge.rb#99 def log_level; end - # source://lograge//lib/lograge.rb#98 + # source://lograge//lib/lograge.rb#99 def log_level=(val); end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def logger; end - # source://lograge//lib/lograge.rb#27 + # source://lograge//lib/lograge.rb#28 def logger=(val); end - # source://lograge//lib/lograge.rb#223 + # source://lograge//lib/lograge.rb#224 def lograge_config; end - # source://lograge//lib/lograge.rb#108 + # source://lograge//lib/lograge.rb#234 + def notification_listeners_for(name); end + + # source://lograge//lib/lograge.rb#109 def remove_existing_log_subscriptions; end - # source://lograge//lib/lograge.rb#148 + # source://lograge//lib/lograge.rb#149 def set_formatter; end - # source://lograge//lib/lograge.rb#143 + # source://lograge//lib/lograge.rb#144 def set_ignores; end - # source://lograge//lib/lograge.rb#185 + # source://lograge//lib/lograge.rb#186 def set_lograge_log_options; end - # source://lograge//lib/lograge.rb#128 + # source://lograge//lib/lograge.rb#129 def setup(app); end - # source://lograge//lib/lograge.rb#163 + # source://lograge//lib/lograge.rb#164 def setup_custom_payload; end # TODO: Remove with version 1.0 # - # source://lograge//lib/lograge.rb#213 + # source://lograge//lib/lograge.rb#214 def support_deprecated_config; end - # source://lograge//lib/lograge.rb#119 + # source://lograge//lib/lograge.rb#120 def unsubscribe(component, subscriber); end private # @return [Boolean] # - # source://lograge//lib/lograge.rb#206 + # source://lograge//lib/lograge.rb#207 def rack_cache_hashlike?(app); end end end @@ -304,6 +317,23 @@ class Lograge::Formatters::KeyValue def parse_value(key, value); end end +# source://lograge//lib/lograge/formatters/key_value_deep.rb#5 +class Lograge::Formatters::KeyValueDeep < ::Lograge::Formatters::KeyValue + # source://lograge//lib/lograge/formatters/key_value_deep.rb#6 + def call(data); end + + protected + + # source://lograge//lib/lograge/formatters/key_value_deep.rb#12 + def flatten_keys(data, prefix = T.unsafe(nil)); end + + # source://lograge//lib/lograge/formatters/key_value_deep.rb#18 + def flatten_object(data, prefix); end + + # source://lograge//lib/lograge/formatters/key_value_deep.rb#31 + def loop_on_object(data, &block); end +end + # source://lograge//lib/lograge/formatters/l2met.rb#7 class Lograge::Formatters::L2met < ::Lograge::Formatters::KeyValue # source://lograge//lib/lograge/formatters/l2met.rb#26 @@ -450,34 +480,37 @@ class Lograge::LogSubscribers::Base < ::ActiveSupport::LogSubscriber private - # source://lograge//lib/lograge/log_subscribers/base.rb#67 + # source://lograge//lib/lograge/log_subscribers/base.rb#76 def before_format(data, payload); end - # source://lograge//lib/lograge/log_subscribers/base.rb#62 + # source://lograge//lib/lograge/log_subscribers/base.rb#71 def custom_options(event); end - # source://lograge//lib/lograge/log_subscribers/base.rb#54 + # source://lograge//lib/lograge/log_subscribers/base.rb#55 def default_status; end - # source://lograge//lib/lograge/log_subscribers/base.rb#40 + # source://lograge//lib/lograge/log_subscribers/base.rb#63 + def extract_allocations(event); end + + # source://lograge//lib/lograge/log_subscribers/base.rb#41 def extract_location(*_arg); end # source://lograge//lib/lograge/log_subscribers/base.rb#29 def extract_request(event, payload); end - # source://lograge//lib/lograge/log_subscribers/base.rb#40 + # source://lograge//lib/lograge/log_subscribers/base.rb#41 def extract_runtimes(*_arg); end - # source://lograge//lib/lograge/log_subscribers/base.rb#43 + # source://lograge//lib/lograge/log_subscribers/base.rb#44 def extract_status(payload); end - # source://lograge//lib/lograge/log_subscribers/base.rb#40 + # source://lograge//lib/lograge/log_subscribers/base.rb#41 def extract_unpermitted_params(*_arg); end - # source://lograge//lib/lograge/log_subscribers/base.rb#58 + # source://lograge//lib/lograge/log_subscribers/base.rb#59 def get_error_status_code(exception_class_name); end - # source://lograge//lib/lograge/log_subscribers/base.rb#40 + # source://lograge//lib/lograge/log_subscribers/base.rb#41 def initial_data(*_arg); end # source://lograge//lib/lograge/log_subscribers/base.rb#19 diff --git a/sorbet/rbi/gems/logs_tf@0.0.5.rbi b/sorbet/rbi/gems/logs_tf@0.0.5.rbi index b223051da..d12e1de26 100644 --- a/sorbet/rbi/gems/logs_tf@0.0.5.rbi +++ b/sorbet/rbi/gems/logs_tf@0.0.5.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `logs_tf` gem. # Please instead update this file by running `bin/tapioca gem logs_tf`. + # source://logs_tf//lib/logs_tf/version.rb#1 module LogsTF; end diff --git a/sorbet/rbi/gems/loofah@2.21.3.rbi b/sorbet/rbi/gems/loofah@2.22.0.rbi similarity index 88% rename from sorbet/rbi/gems/loofah@2.21.3.rbi rename to sorbet/rbi/gems/loofah@2.22.0.rbi index e43c8957f..58c1bb312 100644 --- a/sorbet/rbi/gems/loofah@2.21.3.rbi +++ b/sorbet/rbi/gems/loofah@2.22.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `loofah` gem. # Please instead update this file by running `bin/tapioca gem loofah`. + # == Strings and IO Objects as Input # # The following methods accept any IO object in addition to accepting a string: @@ -341,42 +342,42 @@ module Loofah::HTML5::Scrub class << self # @return [Boolean] # - # source://loofah//lib/loofah/html5/scrub.rb#17 + # source://loofah//lib/loofah/html5/scrub.rb#18 def allowed_element?(element_name); end - # source://loofah//lib/loofah/html5/scrub.rb#191 + # source://loofah//lib/loofah/html5/scrub.rb#192 def cdata_escape(node); end # @return [Boolean] # - # source://loofah//lib/loofah/html5/scrub.rb#186 + # source://loofah//lib/loofah/html5/scrub.rb#187 def cdata_needs_escaping?(node); end - # source://loofah//lib/loofah/html5/scrub.rb#206 + # source://loofah//lib/loofah/html5/scrub.rb#207 def escape_tags(string); end # libxml2 >= 2.9.2 fails to escape comments within some attributes. # # see comments about CVE-2018-8048 within the tests for more information # - # source://loofah//lib/loofah/html5/scrub.rb#165 + # source://loofah//lib/loofah/html5/scrub.rb#166 def force_correct_attribute_escaping!(node); end - # source://loofah//lib/loofah/html5/scrub.rb#122 + # source://loofah//lib/loofah/html5/scrub.rb#123 def scrub_attribute_that_allows_local_ref(attr_node); end # alternative implementation of the html5lib attribute scrubbing algorithm # - # source://loofah//lib/loofah/html5/scrub.rb#22 + # source://loofah//lib/loofah/html5/scrub.rb#23 def scrub_attributes(node); end - # source://loofah//lib/loofah/html5/scrub.rb#71 + # source://loofah//lib/loofah/html5/scrub.rb#72 def scrub_css(style); end - # source://loofah//lib/loofah/html5/scrub.rb#66 + # source://loofah//lib/loofah/html5/scrub.rb#67 def scrub_css_attribute(node); end - # source://loofah//lib/loofah/html5/scrub.rb#141 + # source://loofah//lib/loofah/html5/scrub.rb#142 def scrub_uri_attribute(attr_node); end end end @@ -393,10 +394,13 @@ Loofah::HTML5::Scrub::CSS_IMPORTANT = T.let(T.unsafe(nil), String) # source://loofah//lib/loofah/html5/scrub.rb#10 Loofah::HTML5::Scrub::CSS_KEYWORDISH = T.let(T.unsafe(nil), Regexp) -# source://loofah//lib/loofah/html5/scrub.rb#13 +# source://loofah//lib/loofah/html5/scrub.rb#14 Loofah::HTML5::Scrub::CSS_PROPERTY_STRING_WITHOUT_EMBEDDED_QUOTES = T.let(T.unsafe(nil), Regexp) -# source://loofah//lib/loofah/html5/scrub.rb#14 +# source://loofah//lib/loofah/html5/scrub.rb#13 +Loofah::HTML5::Scrub::CSS_WHITESPACE = T.let(T.unsafe(nil), String) + +# source://loofah//lib/loofah/html5/scrub.rb#15 Loofah::HTML5::Scrub::DATA_ATTRIBUTE_NAME = T.let(T.unsafe(nil), Regexp) # source://loofah//lib/loofah/html5/safelist.rb#1048 @@ -705,6 +709,15 @@ class Loofah::ScrubberNotFound < ::RuntimeError; end # => "ohai! I like your blog post" # # +# === Loofah::Scrubbers::TargetBlank / scrub!(:targetblank) +# +# +:targetblank+ adds a target="_blank" attribute to all links +# +# link_farmers_markup = "ohai! I like your blog post" +# Loofah.html5_fragment(link_farmers_markup).scrub!(:targetblank) +# => "ohai! I like your blog post" +# +# # === Loofah::Scrubbers::NoOpener / scrub!(:noopener) # # +:noopener+ adds a rel="noopener" attribute to all links @@ -713,6 +726,14 @@ class Loofah::ScrubberNotFound < ::RuntimeError; end # Loofah.html5_fragment(link_farmers_markup).scrub!(:noopener) # => "ohai! I like your blog post" # +# === Loofah::Scrubbers::NoReferrer / scrub!(:noreferrer) +# +# +:noreferrer+ adds a rel="noreferrer" attribute to all links +# +# link_farmers_markup = "ohai! I like your blog post" +# Loofah.html5_fragment(link_farmers_markup).scrub!(:noreferrer) +# => "ohai! I like your blog post" +# # # === Loofah::Scrubbers::Unprintable / scrub!(:unprintable) # @@ -728,12 +749,12 @@ class Loofah::ScrubberNotFound < ::RuntimeError; end # # http://timelessrepo.com/json-isnt-a-javascript-subset # -# source://loofah//lib/loofah/scrubbers.rb#87 +# source://loofah//lib/loofah/scrubbers.rb#104 module Loofah::Scrubbers class << self # Returns an array of symbols representing the built-in scrubbers # - # source://loofah//lib/loofah/scrubbers.rb#303 + # source://loofah//lib/loofah/scrubbers.rb#371 def scrubber_symbols; end end end @@ -746,32 +767,32 @@ end # Loofah.html5_fragment(unsafe_html).scrub!(:escape) # => "ohai!
div is safe
<foo>but foo is <b>not</b></foo>" # -# source://loofah//lib/loofah/scrubbers.rb#142 +# source://loofah//lib/loofah/scrubbers.rb#159 class Loofah::Scrubbers::Escape < ::Loofah::Scrubber # @return [Escape] a new instance of Escape # - # source://loofah//lib/loofah/scrubbers.rb#143 + # source://loofah//lib/loofah/scrubbers.rb#160 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#147 + # source://loofah//lib/loofah/scrubbers.rb#164 def scrub(node); end end # A hash that maps a symbol (like +:prune+) to the appropriate Scrubber (Loofah::Scrubbers::Prune). # -# source://loofah//lib/loofah/scrubbers.rb#288 +# source://loofah//lib/loofah/scrubbers.rb#354 Loofah::Scrubbers::MAP = T.let(T.unsafe(nil), Hash) # This class probably isn't useful publicly, but is used for #to_text's current implemention # -# source://loofah//lib/loofah/scrubbers.rb#239 +# source://loofah//lib/loofah/scrubbers.rb#305 class Loofah::Scrubbers::NewlineBlockElements < ::Loofah::Scrubber # @return [NewlineBlockElements] a new instance of NewlineBlockElements # - # source://loofah//lib/loofah/scrubbers.rb#240 + # source://loofah//lib/loofah/scrubbers.rb#306 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#244 + # source://loofah//lib/loofah/scrubbers.rb#310 def scrub(node); end end @@ -783,14 +804,14 @@ end # Loofah.html5_fragment(link_farmers_markup).scrub!(:nofollow) # => "ohai! I like your blog post" # -# source://loofah//lib/loofah/scrubbers.rb#203 +# source://loofah//lib/loofah/scrubbers.rb#220 class Loofah::Scrubbers::NoFollow < ::Loofah::Scrubber # @return [NoFollow] a new instance of NoFollow # - # source://loofah//lib/loofah/scrubbers.rb#204 + # source://loofah//lib/loofah/scrubbers.rb#221 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#208 + # source://loofah//lib/loofah/scrubbers.rb#225 def scrub(node); end end @@ -802,14 +823,33 @@ end # Loofah.html5_fragment(link_farmers_markup).scrub!(:noopener) # => "ohai! I like your blog post" # -# source://loofah//lib/loofah/scrubbers.rb#225 +# source://loofah//lib/loofah/scrubbers.rb#269 class Loofah::Scrubbers::NoOpener < ::Loofah::Scrubber # @return [NoOpener] a new instance of NoOpener # - # source://loofah//lib/loofah/scrubbers.rb#226 + # source://loofah//lib/loofah/scrubbers.rb#270 + def initialize; end + + # source://loofah//lib/loofah/scrubbers.rb#274 + def scrub(node); end +end + +# === scrub!(:noreferrer) +# +# +:noreferrer+ adds a rel="noreferrer" attribute to all links +# +# link_farmers_markup = "ohai! I like your blog post" +# Loofah.html5_fragment(link_farmers_markup).scrub!(:noreferrer) +# => "ohai! I like your blog post" +# +# source://loofah//lib/loofah/scrubbers.rb#291 +class Loofah::Scrubbers::NoReferrer < ::Loofah::Scrubber + # @return [NoReferrer] a new instance of NoReferrer + # + # source://loofah//lib/loofah/scrubbers.rb#292 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#230 + # source://loofah//lib/loofah/scrubbers.rb#296 def scrub(node); end end @@ -821,14 +861,14 @@ end # Loofah.html5_fragment(unsafe_html).scrub!(:prune) # => "ohai!
div is safe
" # -# source://loofah//lib/loofah/scrubbers.rb#120 +# source://loofah//lib/loofah/scrubbers.rb#137 class Loofah::Scrubbers::Prune < ::Loofah::Scrubber # @return [Prune] a new instance of Prune # - # source://loofah//lib/loofah/scrubbers.rb#121 + # source://loofah//lib/loofah/scrubbers.rb#138 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#125 + # source://loofah//lib/loofah/scrubbers.rb#142 def scrub(node); end end @@ -840,14 +880,37 @@ end # Loofah.html5_fragment(unsafe_html).scrub!(:strip) # => "ohai!
div is safe
but foo is not" # -# source://loofah//lib/loofah/scrubbers.rb#97 +# source://loofah//lib/loofah/scrubbers.rb#114 class Loofah::Scrubbers::Strip < ::Loofah::Scrubber # @return [Strip] a new instance of Strip # - # source://loofah//lib/loofah/scrubbers.rb#98 + # source://loofah//lib/loofah/scrubbers.rb#115 + def initialize; end + + # source://loofah//lib/loofah/scrubbers.rb#119 + def scrub(node); end +end + +# === scrub!(:targetblank) +# +# +:targetblank+ adds a target="_blank" attribute to all links. +# If there is a target already set, replaces it with target="_blank". +# +# link_farmers_markup = "ohai! I like your blog post" +# Loofah.html5_fragment(link_farmers_markup).scrub!(:targetblank) +# => "ohai! I like your blog post" +# +# On modern browsers, setting target="_blank" on anchor elements implicitly provides the same +# behavior as setting rel="noopener". +# +# source://loofah//lib/loofah/scrubbers.rb#246 +class Loofah::Scrubbers::TargetBlank < ::Loofah::Scrubber + # @return [TargetBlank] a new instance of TargetBlank + # + # source://loofah//lib/loofah/scrubbers.rb#247 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#102 + # source://loofah//lib/loofah/scrubbers.rb#251 def scrub(node); end end @@ -865,14 +928,14 @@ end # # http://timelessrepo.com/json-isnt-a-javascript-subset # -# source://loofah//lib/loofah/scrubbers.rb#272 +# source://loofah//lib/loofah/scrubbers.rb#338 class Loofah::Scrubbers::Unprintable < ::Loofah::Scrubber # @return [Unprintable] a new instance of Unprintable # - # source://loofah//lib/loofah/scrubbers.rb#273 + # source://loofah//lib/loofah/scrubbers.rb#339 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#277 + # source://loofah//lib/loofah/scrubbers.rb#343 def scrub(node); end end @@ -893,14 +956,14 @@ end # all kinds of cruft into its HTML output. Who needs that crap? # Certainly not me. # -# source://loofah//lib/loofah/scrubbers.rb#174 +# source://loofah//lib/loofah/scrubbers.rb#191 class Loofah::Scrubbers::Whitewash < ::Loofah::Scrubber # @return [Whitewash] a new instance of Whitewash # - # source://loofah//lib/loofah/scrubbers.rb#175 + # source://loofah//lib/loofah/scrubbers.rb#192 def initialize; end - # source://loofah//lib/loofah/scrubbers.rb#179 + # source://loofah//lib/loofah/scrubbers.rb#196 def scrub(node); end end diff --git a/sorbet/rbi/gems/mail@2.8.1.rbi b/sorbet/rbi/gems/mail@2.8.1.rbi index 789ca1aa3..b1a8a0a23 100644 --- a/sorbet/rbi/gems/mail@2.8.1.rbi +++ b/sorbet/rbi/gems/mail@2.8.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `mail` gem. # Please instead update this file by running `bin/tapioca gem mail`. + # source://mail//lib/mail.rb#3 module Mail class << self @@ -127,9 +128,6 @@ module Mail # source://mail//lib/mail/mail.rb#151 def first(*args, &block); end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/from_source.rb#4 - def from_source(source); end - # source://mail//lib/mail/mail.rb#233 def inform_interceptors(mail); end @@ -276,9 +274,6 @@ class Mail::Address # source://mail//lib/mail/elements/address.rb#25 def initialize(value = T.unsafe(nil)); end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/address_equality.rb#5 - def ==(other_address); end - # Returns the address that is in the address itself. That is, the # local@domain string, without any angle brackets or the like. # @@ -423,11 +418,6 @@ class Mail::Address # source://mail//lib/mail/elements/address.rb#207 def strip_domain_comments(value); end - - class << self - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/address_wrapping.rb#5 - def wrap(address); end - end end # source://mail//lib/mail/fields/common_address_field.rb#6 @@ -3550,9 +3540,6 @@ class Mail::Message # source://mail//lib/mail/message.rb#512 def bcc=(val); end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/addresses.rb#21 - def bcc_addresses; end - # Returns an array of addresses (the encoded value) in the Bcc field, # if no Bcc field, returns an empty array # @@ -3659,9 +3646,6 @@ class Mail::Message # source://mail//lib/mail/message.rb#553 def cc=(val); end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/addresses.rb#17 - def cc_addresses; end - # Returns an array of addresses (the encoded value) in the Cc field, # if no Cc field, returns an empty array # @@ -3978,9 +3962,6 @@ class Mail::Message # source://mail//lib/mail/message.rb#670 def from=(val); end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/addresses.rb#5 - def from_address; end - # Returns an array of addresses (the encoded value) in the From field, # if no From field, returns an empty array # @@ -4371,12 +4352,6 @@ class Mail::Message # source://mail//lib/mail/message.rb#751 def received=(val); end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/recipients.rb#5 - def recipients; end - - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/addresses.rb#9 - def recipients_addresses; end - # source://mail//lib/mail/message.rb#755 def references(val = T.unsafe(nil)); end @@ -4845,9 +4820,6 @@ class Mail::Message # source://mail//lib/mail/message.rb#1193 def to=(val); end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/addresses.rb#13 - def to_addresses; end - # Returns an array of addresses (the encoded value) in the To field, # if no To field, returns an empty array # @@ -4869,9 +4841,6 @@ class Mail::Message # source://mail//lib/mail/message.rb#1811 def without_attachments!; end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/addresses.rb#25 - def x_original_to_addresses; end - private # source://mail//lib/mail/message.rb#2067 @@ -4892,9 +4861,6 @@ class Mail::Message # source://mail//lib/mail/message.rb#2056 def add_required_message_fields; end - # source://actionmailbox/7.0.5/lib/action_mailbox/mail_ext/addresses.rb#30 - def address_list(obj); end - # source://mail//lib/mail/message.rb#2025 def allowed_encodings; end diff --git a/sorbet/rbi/gems/marcel@1.0.2.rbi b/sorbet/rbi/gems/marcel@1.0.4.rbi similarity index 66% rename from sorbet/rbi/gems/marcel@1.0.2.rbi rename to sorbet/rbi/gems/marcel@1.0.4.rbi index 135aac855..861f2c1c8 100644 --- a/sorbet/rbi/gems/marcel@1.0.2.rbi +++ b/sorbet/rbi/gems/marcel@1.0.4.rbi @@ -4,20 +4,21 @@ # This is an autogenerated file for types exported from the `marcel` gem. # Please instead update this file by running `bin/tapioca gem marcel`. + # This file is auto-generated. Instead of editing this file, please # add MIMEs to data/custom.xml or lib/marcel/mime_type/definitions.rb. # -# source://marcel//lib/marcel.rb#1 +# source://marcel//lib/marcel.rb#3 module Marcel; end # @private # -# source://marcel//lib/marcel/tables.rb#10 +# source://marcel//lib/marcel/tables.rb#9 Marcel::EXTENSIONS = T.let(T.unsafe(nil), Hash) # @private # -# source://marcel//lib/marcel/tables.rb#2154 +# source://marcel//lib/marcel/tables.rb#2394 Marcel::MAGIC = T.let(T.unsafe(nil), Array) # Mime type detection @@ -35,46 +36,46 @@ class Marcel::Magic # # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#102 + # source://marcel//lib/marcel/magic.rb#103 def ==(other); end # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#53 + # source://marcel//lib/marcel/magic.rb#54 def audio?; end # Returns true if type is child of parent type # # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#57 + # source://marcel//lib/marcel/magic.rb#58 def child_of?(parent); end # Get mime comment # - # source://marcel//lib/marcel/magic.rb#67 + # source://marcel//lib/marcel/magic.rb#68 def comment; end # Allow comparison with string # # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#102 + # source://marcel//lib/marcel/magic.rb#103 def eql?(other); end # Get string list of file extensions # - # source://marcel//lib/marcel/magic.rb#62 + # source://marcel//lib/marcel/magic.rb#63 def extensions; end - # source://marcel//lib/marcel/magic.rb#106 + # source://marcel//lib/marcel/magic.rb#107 def hash; end # Mediatype shortcuts # # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#52 + # source://marcel//lib/marcel/magic.rb#53 def image?; end # Returns the value of attribute mediatype. @@ -91,12 +92,12 @@ class Marcel::Magic # # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#49 + # source://marcel//lib/marcel/magic.rb#50 def text?; end # Return type as string # - # source://marcel//lib/marcel/magic.rb#97 + # source://marcel//lib/marcel/magic.rb#98 def to_s; end # Returns the value of attribute type. @@ -106,7 +107,7 @@ class Marcel::Magic # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#54 + # source://marcel//lib/marcel/magic.rb#55 def video?; end class << self @@ -126,28 +127,28 @@ class Marcel::Magic # Lookup all mime types by magic content analysis. # This is a slower operation. # - # source://marcel//lib/marcel/magic.rb#92 + # source://marcel//lib/marcel/magic.rb#93 def all_by_magic(io); end # Lookup mime type by file extension # - # source://marcel//lib/marcel/magic.rb#72 + # source://marcel//lib/marcel/magic.rb#73 def by_extension(ext); end # Lookup mime type by magic content analysis. # This is a slow operation. # - # source://marcel//lib/marcel/magic.rb#85 + # source://marcel//lib/marcel/magic.rb#86 def by_magic(io); end # Lookup mime type by filename # - # source://marcel//lib/marcel/magic.rb#79 + # source://marcel//lib/marcel/magic.rb#80 def by_path(path); end # @return [Boolean] # - # source://marcel//lib/marcel/magic.rb#112 + # source://marcel//lib/marcel/magic.rb#113 def child?(child, parent); end # Removes a mime type from the dictionary. You might want to do this if @@ -159,62 +160,80 @@ class Marcel::Magic private - # source://marcel//lib/marcel/magic.rb#116 + # source://marcel//lib/marcel/magic.rb#117 def magic_match(io, method); end - # source://marcel//lib/marcel/magic.rb#126 + # source://marcel//lib/marcel/magic.rb#127 def magic_match_io(io, matches, buffer); end end end -# source://marcel//lib/marcel/mime_type.rb#2 +# source://marcel//lib/marcel/mime_type.rb#4 class Marcel::MimeType class << self - # source://marcel//lib/marcel/mime_type.rb#6 + # source://marcel//lib/marcel/mime_type.rb#8 def extend(type, extensions: T.unsafe(nil), parents: T.unsafe(nil), magic: T.unsafe(nil)); end - # source://marcel//lib/marcel/mime_type.rb#16 + # Returns the most appropriate content type for the given file. + # + # The first argument should be a +Pathname+ or an +IO+. If it is a +Pathname+, the specified + # file will be opened first. + # + # Optional parameters: + # * +name+: file name, if known + # * +extension+: file extension, if known + # * +declared_type+: MIME type, if known + # + # The most appropriate type is determined by the following: + # * type declared by binary magic number data + # * type declared by the first of file name, file extension, or declared MIME type + # + # If no type can be determined, then +application/octet-stream+ is returned. + # + # source://marcel//lib/marcel/mime_type.rb#29 def for(pathname_or_io = T.unsafe(nil), name: T.unsafe(nil), extension: T.unsafe(nil), declared_type: T.unsafe(nil)); end private - # source://marcel//lib/marcel/mime_type.rb#28 + # source://marcel//lib/marcel/mime_type.rb#36 def for_data(pathname_or_io); end - # source://marcel//lib/marcel/mime_type.rb#54 + # source://marcel//lib/marcel/mime_type.rb#62 def for_declared_type(declared_type); end - # source://marcel//lib/marcel/mime_type.rb#46 + # source://marcel//lib/marcel/mime_type.rb#54 def for_extension(extension); end - # source://marcel//lib/marcel/mime_type.rb#38 + # source://marcel//lib/marcel/mime_type.rb#46 def for_name(name); end # For some document types (notably Microsoft Office) we recognise the main content # type with magic, but not the specific subclass. In this situation, if we can get a more # specific class using either the name or declared_type, we should use that in preference # - # source://marcel//lib/marcel/mime_type.rb#80 - def most_specific_type(from_magic_type, fallback_type); end + # source://marcel//lib/marcel/mime_type.rb#89 + def most_specific_type(*candidates); end - # source://marcel//lib/marcel/mime_type.rb#70 + # source://marcel//lib/marcel/mime_type.rb#79 def parse_media_type(content_type); end - # source://marcel//lib/marcel/mime_type.rb#88 - def root_types(type); end - - # source://marcel//lib/marcel/mime_type.rb#62 + # source://marcel//lib/marcel/mime_type.rb#71 def with_io(pathname_or_io, &block); end end end -# source://marcel//lib/marcel/mime_type.rb#3 +# source://marcel//lib/marcel/mime_type.rb#5 Marcel::MimeType::BINARY = T.let(T.unsafe(nil), String) # @private # -# source://marcel//lib/marcel/tables.rb#1261 -Marcel::TYPES = T.let(T.unsafe(nil), Hash) +# source://marcel//lib/marcel/tables.rb#1260 +Marcel::TYPE_EXTS = T.let(T.unsafe(nil), Hash) + +# Cooltalk Audio +# +# source://marcel//lib/marcel/tables.rb#2151 +Marcel::TYPE_PARENTS = T.let(T.unsafe(nil), Hash) -# source://marcel//lib/marcel/version.rb#2 +# source://marcel//lib/marcel/version.rb#4 Marcel::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/matrix@0.4.2.rbi b/sorbet/rbi/gems/matrix@0.4.2.rbi index 81e249f06..5fb50907e 100644 --- a/sorbet/rbi/gems/matrix@0.4.2.rbi +++ b/sorbet/rbi/gems/matrix@0.4.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `matrix` gem. # Please instead update this file by running `bin/tapioca gem matrix`. + # source://matrix//lib/matrix.rb#17 module ExceptionForMatrix; end diff --git a/sorbet/rbi/gems/maxmind-db@1.1.1.rbi b/sorbet/rbi/gems/maxmind-db@1.2.0.rbi similarity index 84% rename from sorbet/rbi/gems/maxmind-db@1.1.1.rbi rename to sorbet/rbi/gems/maxmind-db@1.2.0.rbi index b907bdac7..94a51ece0 100644 --- a/sorbet/rbi/gems/maxmind-db@1.1.1.rbi +++ b/sorbet/rbi/gems/maxmind-db@1.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `maxmind-db` gem. # Please instead update this file by running `bin/tapioca gem maxmind-db`. + # source://maxmind-db//lib/maxmind/db/errors.rb#3 module MaxMind; end @@ -57,7 +58,7 @@ class MaxMind::DB # # @return [void] # - # source://maxmind-db//lib/maxmind/db.rb#299 + # source://maxmind-db//lib/maxmind/db.rb#298 def close; end # Return the record for the IP address in the {MaxMind @@ -66,14 +67,13 @@ class MaxMind::DB # # If no record is found for the IP address, +get+ returns +nil+. # - # @param ip_address [String] a string in the standard notation. It may be - # IPv4 or IPv6. + # @param ip_address [String, IPAddr] IPv4 or IPv6 address. # @raise [ArgumentError] if you attempt to look up an IPv6 address in an # IPv4-only database. # @raise [InvalidDatabaseError] if the database is corrupt or invalid. # @return [Object, nil] # - # source://maxmind-db//lib/maxmind/db.rb#142 + # source://maxmind-db//lib/maxmind/db.rb#141 def get(ip_address); end # Return an array containing the record for the IP address in the @@ -84,14 +84,13 @@ class MaxMind::DB # If no record is found for the IP address, the record will be +nil+ and # the prefix length will be the value for the missing network. # - # @param ip_address [String] a string in the standard notation. It may be - # IPv4 or IPv6. + # @param ip_address [String, IPAddr] IPv4 or IPv6 address. # @raise [ArgumentError] if you attempt to look up an IPv6 address in an # IPv4-only database. # @raise [InvalidDatabaseError] if the database is corrupt or invalid. # @return [Array<(Object, Integer)>] # - # source://maxmind-db//lib/maxmind/db.rb#165 + # source://maxmind-db//lib/maxmind/db.rb#163 def get_with_prefix_length(ip_address); end # Return the metadata associated with the {MaxMind @@ -106,17 +105,17 @@ class MaxMind::DB # @return [Boolean] # - # source://maxmind-db//lib/maxmind/db.rb#290 + # source://maxmind-db//lib/maxmind/db.rb#289 def at_metadata?(index); end # @raise [InvalidDatabaseError] # - # source://maxmind-db//lib/maxmind/db.rb#190 + # source://maxmind-db//lib/maxmind/db.rb#189 def find_address_in_tree(ip_address, ip_version); end # @raise [InvalidDatabaseError] # - # source://maxmind-db//lib/maxmind/db.rb#275 + # source://maxmind-db//lib/maxmind/db.rb#274 def find_metadata_start; end # Read a record from the indicated node. Index indicates whether it's the @@ -124,13 +123,13 @@ class MaxMind::DB # # @raise [InvalidDatabaseError] # - # source://maxmind-db//lib/maxmind/db.rb#232 + # source://maxmind-db//lib/maxmind/db.rb#231 def read_node(node_number, index); end - # source://maxmind-db//lib/maxmind/db.rb#263 + # source://maxmind-db//lib/maxmind/db.rb#262 def resolve_data_pointer(pointer); end - # source://maxmind-db//lib/maxmind/db.rb#215 + # source://maxmind-db//lib/maxmind/db.rb#214 def start_node(length); end end @@ -159,7 +158,7 @@ class MaxMind::DB::Decoder # # @return [Decoder] a new instance of Decoder # - # source://maxmind-db//lib/maxmind/db/decoder.rb#26 + # source://maxmind-db//lib/maxmind/db/decoder.rb#28 def initialize(io, pointer_base = T.unsafe(nil), pointer_test = T.unsafe(nil)); end # Decode a section of the data section starting at +offset+. @@ -171,90 +170,95 @@ class MaxMind::DB::Decoder # # Throws an exception if there is an error. # - # source://maxmind-db//lib/maxmind/db/decoder.rb#186 + # source://maxmind-db//lib/maxmind/db/decoder.rb#189 def decode(offset); end private - # source://maxmind-db//lib/maxmind/db/decoder.rb#34 + # source://maxmind-db//lib/maxmind/db/decoder.rb#37 def decode_array(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#43 + # source://maxmind-db//lib/maxmind/db/decoder.rb#46 def decode_boolean(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#47 + # source://maxmind-db//lib/maxmind/db/decoder.rb#50 def decode_bytes(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#51 + # source://maxmind-db//lib/maxmind/db/decoder.rb#54 def decode_double(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#57 + # source://maxmind-db//lib/maxmind/db/decoder.rb#60 def decode_float(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#86 + # source://maxmind-db//lib/maxmind/db/decoder.rb#89 def decode_int(type_code, type_size, size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#70 + # source://maxmind-db//lib/maxmind/db/decoder.rb#73 def decode_int32(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#112 + # source://maxmind-db//lib/maxmind/db/decoder.rb#115 def decode_map(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#122 + # source://maxmind-db//lib/maxmind/db/decoder.rb#125 def decode_pointer(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#94 + # source://maxmind-db//lib/maxmind/db/decoder.rb#97 def decode_uint128(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#74 + # source://maxmind-db//lib/maxmind/db/decoder.rb#77 def decode_uint16(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#78 + # source://maxmind-db//lib/maxmind/db/decoder.rb#81 def decode_uint32(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#82 + # source://maxmind-db//lib/maxmind/db/decoder.rb#85 def decode_uint64(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#150 + # source://maxmind-db//lib/maxmind/db/decoder.rb#153 def decode_utf8_string(size, offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#201 + # source://maxmind-db//lib/maxmind/db/decoder.rb#204 def read_extended(offset); end - # source://maxmind-db//lib/maxmind/db/decoder.rb#212 + # source://maxmind-db//lib/maxmind/db/decoder.rb#215 def size_from_ctrl_byte(ctrl_byte, offset, type_num); end # @raise [InvalidDatabaseError] # - # source://maxmind-db//lib/maxmind/db/decoder.rb#63 + # source://maxmind-db//lib/maxmind/db/decoder.rb#66 def verify_size(expected, actual); end end -# source://maxmind-db//lib/maxmind/db/decoder.rb#159 +# source://maxmind-db//lib/maxmind/db/decoder.rb#162 MaxMind::DB::Decoder::TYPE_DECODER = T.let(T.unsafe(nil), Hash) # source://maxmind-db//lib/maxmind/db/file_reader.rb#8 class MaxMind::DB::FileReader # @return [FileReader] a new instance of FileReader # - # source://maxmind-db//lib/maxmind/db/file_reader.rb#9 + # source://maxmind-db//lib/maxmind/db/file_reader.rb#36 def initialize(filename); end - # source://maxmind-db//lib/maxmind/db/file_reader.rb#17 + # source://maxmind-db//lib/maxmind/db/file_reader.rb#43 def close; end # @raise [InvalidDatabaseError] # - # source://maxmind-db//lib/maxmind/db/file_reader.rb#21 + # source://maxmind-db//lib/maxmind/db/file_reader.rb#47 def read(offset, size); end # Returns the value of attribute size. # - # source://maxmind-db//lib/maxmind/db/file_reader.rb#15 + # source://maxmind-db//lib/maxmind/db/file_reader.rb#41 def size; end end -# source://maxmind-db//lib/maxmind/db.rb#184 +# For Windows support +# +# source://maxmind-db//lib/maxmind/db/file_reader.rb#10 +MaxMind::DB::FileReader::PReadFile = File + +# source://maxmind-db//lib/maxmind/db.rb#183 MaxMind::DB::IP_VERSION_TO_BIT_COUNT = T.let(T.unsafe(nil), Hash) # An InvalidDatabaseError means the {MaxMind diff --git a/sorbet/rbi/gems/maxmind-geoip2@1.1.0.rbi b/sorbet/rbi/gems/maxmind-geoip2@1.2.0.rbi similarity index 91% rename from sorbet/rbi/gems/maxmind-geoip2@1.1.0.rbi rename to sorbet/rbi/gems/maxmind-geoip2@1.2.0.rbi index 3c2f80be2..3ee601205 100644 --- a/sorbet/rbi/gems/maxmind-geoip2@1.1.0.rbi +++ b/sorbet/rbi/gems/maxmind-geoip2@1.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `maxmind-geoip2` gem. # Please instead update this file by running `bin/tapioca gem maxmind-geoip2`. + # source://maxmind-geoip2//lib/maxmind/geoip2/errors.rb#3 module MaxMind; end @@ -38,9 +39,9 @@ class MaxMind::GeoIP2::AddressReservedError < ::MaxMind::GeoIP2::AddressError; e # source://maxmind-geoip2//lib/maxmind/geoip2/errors.rb#33 class MaxMind::GeoIP2::AuthenticationError < ::MaxMind::GeoIP2::Error; end -# source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#56 +# source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#58 class MaxMind::GeoIP2::Client - # Create a Client that may be used to query a GeoIP2 Precision web service. + # Create a Client that may be used to query a GeoIP2 web service. # # Once created, the Client is safe to use for lookups from multiple # threads. @@ -50,8 +51,10 @@ class MaxMind::GeoIP2::Client # @param locales [Array] a list of locale codes to use in the name # property from most preferred to least preferred. # @param host [String] the host to use when querying the web service. Set - # this to "geolite.info" to use the GeoLite2 web service instead of - # GeoIP2 Precision. + # this to "geolite.info" to use the GeoLite2 web service instead of the + # GeoIP2 web service. Set this to "sandbox.maxmind.com" to use the + # Sandbox environment. The sandbox allows you to experiment with the + # API without affecting your production data. # @param timeout [Integer] the number of seconds to wait for a request # before timing out. If 0, no timeout is set. # @param proxy_address [String] proxy address to use, if any. @@ -61,10 +64,10 @@ class MaxMind::GeoIP2::Client # @param pool_size [Integer] HTTP connection pool size # @return [Client] a new instance of Client # - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#89 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#93 def initialize(account_id:, license_key:, locales: T.unsafe(nil), host: T.unsafe(nil), timeout: T.unsafe(nil), proxy_address: T.unsafe(nil), proxy_port: T.unsafe(nil), proxy_username: T.unsafe(nil), proxy_password: T.unsafe(nil), pool_size: T.unsafe(nil)); end - # This method calls the City web service. + # This method calls the City Plus web service. # # @param ip_address [String] IPv4 or IPv6 address as a string. If no # address is provided, the address that the web service is called from is @@ -87,7 +90,7 @@ class MaxMind::GeoIP2::Client # and there is no more specific error to raise. # @return [MaxMind::GeoIP2::Model::City] # - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#153 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#157 def city(ip_address = T.unsafe(nil)); end # This method calls the Country web service. @@ -113,13 +116,13 @@ class MaxMind::GeoIP2::Client # and there is no more specific error to raise. # @return [MaxMind::GeoIP2::Model::Country] # - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#190 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#194 def country(ip_address = T.unsafe(nil)); end # This method calls the Insights web service. # - # Insights is only supported by the GeoIP2 Precision web service. The - # GeoLite2 web service does not support it. + # Insights is only supported by the GeoIP2 web service. The GeoLite2 web + # service does not support it. # # @param ip_address [String] IPv4 or IPv6 address as a string. If no # address is provided, the address that the web service is called from is @@ -142,24 +145,24 @@ class MaxMind::GeoIP2::Client # and there is no more specific error to raise. # @return [MaxMind::GeoIP2::Model::Insights] # - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#230 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#234 def insights(ip_address = T.unsafe(nil)); end private - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#262 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#271 def get(endpoint, ip_address); end - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#292 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#301 def handle_client_error(endpoint, status, body, is_json); end - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#327 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#336 def handle_success(endpoint, body, is_json); end - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#242 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#250 def make_http_client; end - # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#236 + # source://maxmind-geoip2//lib/maxmind/geoip2/client.rb#240 def response_for(endpoint, model_class, ip_address); end end @@ -304,34 +307,33 @@ class MaxMind::GeoIP2::Model::AnonymousIP < ::MaxMind::GeoIP2::Model::Abstract def tor_exit_node?; end end -# Model class for the data returned by the GeoIP2 City web service and -# database. It is also used for GeoLite2 City lookups. +# Model class for the data returned by the GeoIP2 City Plus web service +# and the City database. It is also used for GeoLite2 City lookups. # -# The only difference between the City and Insights model classes is which -# fields in each record may be populated. See -# https://dev.maxmind.com/geoip/docs/web-services?lang=en for more details. +# See https://dev.maxmind.com/geoip/docs/web-services?lang=en for more +# details. # # See {MaxMind::GeoIP2::Model::Country} for inherited methods. # -# source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#20 +# source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#19 class MaxMind::GeoIP2::Model::City < ::MaxMind::GeoIP2::Model::Country # @return [City] a new instance of City # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#49 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#48 def initialize(record, locales); end # City data for the IP address. # # @return [MaxMind::GeoIP2::Record::City] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#24 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#23 def city; end # Location data for the IP address. # # @return [MaxMind::GeoIP2::Record::Location] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#29 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#28 def location; end # The most specific subdivision returned. @@ -341,14 +343,14 @@ class MaxMind::GeoIP2::Model::City < ::MaxMind::GeoIP2::Model::Country # # @return [MaxMind::GeoIP2::Record::Subdivision, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#63 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#62 def most_specific_subdivision; end # Postal data for the IP address. # # @return [MaxMind::GeoIP2::Record::Postal] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#34 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#33 def postal; end # The country subdivisions for the IP address. @@ -362,12 +364,12 @@ class MaxMind::GeoIP2::Model::City < ::MaxMind::GeoIP2::Model::Country # # @return [Array] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#46 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#45 def subdivisions; end private - # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#69 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/city.rb#68 def create_subdivisions(subdivisions, locales); end end @@ -375,19 +377,20 @@ end # # source://maxmind-geoip2//lib/maxmind/geoip2/model/connection_type.rb#9 class MaxMind::GeoIP2::Model::ConnectionType < ::MaxMind::GeoIP2::Model::Abstract - # The connection type may take the following values: "Dialup", "Cable/DSL", - # "Corporate", "Cellular". Additional values may be added in the future. + # The connection type may take the following values: "Dialup", + # "Cable/DSL", "Corporate", "Cellular", and "Satellite". Additional + # values may be added in the future. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/connection_type.rb#14 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/connection_type.rb#15 def connection_type; end # The IP address that the data in the model is for. # # @return [String] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/connection_type.rb#21 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/connection_type.rb#22 def ip_address; end # The network in CIDR notation associated with the record. In particular, @@ -396,7 +399,7 @@ class MaxMind::GeoIP2::Model::ConnectionType < ::MaxMind::GeoIP2::Model::Abstrac # # @return [String] # - # source://maxmind-geoip2//lib/maxmind/geoip2/model/connection_type.rb#30 + # source://maxmind-geoip2//lib/maxmind/geoip2/model/connection_type.rb#31 def network; end end @@ -489,13 +492,12 @@ end # Model class for the data returned by GeoIP2 Enterprise database lookups. # -# The only difference between the City and Insights model classes is which -# fields in each record may be populated. See -# https://dev.maxmind.com/geoip/docs/web-services?lang=en for more details. +# See https://dev.maxmind.com/geoip/docs/web-services?lang=en for more +# details. # # See {MaxMind::GeoIP2::Model::City} for inherited methods. # -# source://maxmind-geoip2//lib/maxmind/geoip2/model/enterprise.rb#15 +# source://maxmind-geoip2//lib/maxmind/geoip2/model/enterprise.rb#14 class MaxMind::GeoIP2::Model::Enterprise < ::MaxMind::GeoIP2::Model::City; end # Model class for the GeoIP2 ISP database. @@ -564,14 +566,12 @@ class MaxMind::GeoIP2::Model::ISP < ::MaxMind::GeoIP2::Model::Abstract def organization; end end -# Model class for the data returned by the GeoIP2 Precision Insights web -# service. +# Model class for the data returned by the GeoIP2 Insights web service. # -# The only difference between the City and Insights model classes is which -# fields in each record may be populated. See -# https://dev.maxmind.com/geoip/docs/web-services?lang=en for more details. +# See https://dev.maxmind.com/geoip/docs/web-services?lang=en for more +# details. # -# source://maxmind-geoip2//lib/maxmind/geoip2/model/insights.rb#14 +# source://maxmind-geoip2//lib/maxmind/geoip2/model/insights.rb#12 class MaxMind::GeoIP2::Model::Insights < ::MaxMind::GeoIP2::Model::City; end # A PermissionRequiredError means the account does not have permission to @@ -1101,28 +1101,39 @@ class MaxMind::GeoIP2::Record::Traits < ::MaxMind::GeoIP2::Record::Abstract def initialize(record); end # This is true if the IP address belongs to any sort of anonymous network. - # This property is only available from GeoIP2 Precision Insights. + # This property is only available from Insights. # # @return [Boolean] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#79 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#80 def anonymous?; end # This is true if the IP address is registered to an anonymous VPN # provider. If a VPN provider does not register subnets under names # associated with them, we will likely only flag their IP ranges using the - # hosting_provider? property. This property is only available from GeoIP2 - # Precision Insights. + # hosting_provider? property. This property is only available from Insights. # # @return [Boolean] # # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#90 def anonymous_vpn?; end + # This is true if the IP address belongs to an + # {https://en.wikipedia.org/wiki/Anycast anycast network}. + # + # This property is only available from the Country, City Plus, and + # Insights web services and the GeoIP2 Country, City, and Enterprise + # databases. + # + # @return [Boolean] + # + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#102 + def anycast?; end + # The autonomous system number associated with the IP address. See # Wikipedia[https://en.wikipedia.org/wiki/Autonomous_system_(Internet)]. - # This attribute is only available from the City and Insights web service - # and the GeoIP2 Enterprise database. + # This attribute is only available from the City Plus and Insights web + # services and the Enterprise database. # # @return [Integer, nil] # @@ -1132,8 +1143,8 @@ class MaxMind::GeoIP2::Record::Traits < ::MaxMind::GeoIP2::Record::Abstract # The organization associated with the registered autonomous system number # for the IP address. See # Wikipedia[https://en.wikipedia.org/wiki/Autonomous_system_(Internet)]. - # This attribute is only available from the City and Insights web service - # and the GeoIP2 Enterprise database. + # This attribute is only available from the City Plus and Insights web + # services and the Enterprise database. # # @return [String, nil] # @@ -1141,32 +1152,33 @@ class MaxMind::GeoIP2::Record::Traits < ::MaxMind::GeoIP2::Record::Abstract def autonomous_system_organization; end # The connection type may take the following values: "Dialup", - # "Cable/DSL", "Corporate", "Cellular". Additional values may be added in - # the future. This attribute is only available in the GeoIP2 Enterprise + # "Cable/DSL", "Corporate", "Cellular", and "Satellite". Additional + # values may be added in the future. This attribute is only available + # from the City Plus and Insights web services and the Enterprise # database. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#50 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#51 def connection_type; end # The second level domain associated with the IP address. This will be # something like "example.com" or "example.co.uk", not "foo.example.com". - # This attribute is only available from the City and Insights web service - # and the GeoIP2 Enterprise database. + # This attribute is only available from the City Plus and Insights web + # services and the Enterprise database. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#60 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#61 def domain; end # This is true if the IP address belongs to a hosting or VPN provider (see # description of the anonymous_vpn? property). This property is only - # available from GeoIP2 Precision Insights. + # available from Insights. # # @return [Boolean] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#99 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#111 def hosting_provider?; end # The IP address that the data in the model is for. If you performed a "me" @@ -1177,47 +1189,47 @@ class MaxMind::GeoIP2::Record::Traits < ::MaxMind::GeoIP2::Record::Abstract # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#71 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#72 def ip_address; end # The name of the ISP associated with the IP address. This attribute is - # only available from the City and Insights web services and the GeoIP2 + # only available from the City Plus and Insights web services and the # Enterprise database. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#164 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#176 def isp; end # This attribute is true if MaxMind believes this IP address to be a # legitimate proxy, such as an internal VPN used by a corporation. This - # attribute is only available in the GeoIP2 Enterprise database. + # attribute is only available in the Enterprise database. # # @return [Boolean] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#108 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#120 def legitimate_proxy?; end # The {https://en.wikipedia.org/wiki/Mobile_country_code mobile country # code (MCC)} associated with the IP address and ISP. # - # This attribute is only available from the City and Insights web service - # and the GeoIP2 Enterprise database. + # This attribute is only available from the City Plus and Insights web + # services and the Enterprise database. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#119 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#131 def mobile_country_code; end # The {https://en.wikipedia.org/wiki/Mobile_country_code mobile network # code (MNC)} associated with the IP address and ISP. # - # This attribute is only available from the City and Insights web service - # and the GeoIP2 Enterprise database. + # This attribute is only available from the City Plus and Insights web + # services and the Enterprise database. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#130 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#142 def mobile_network_code; end # The network in CIDR notation associated with the record. In particular, @@ -1226,59 +1238,58 @@ class MaxMind::GeoIP2::Record::Traits < ::MaxMind::GeoIP2::Record::Abstract # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#173 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#185 def network; end # The name of the organization associated with the IP address. This - # attribute is only available from the City and Insights web services and - # the GeoIP2 Enterprise database. + # attribute is only available from the City Plus and Insights web services + # and the Enterprise database. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#182 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#194 def organization; end # This is true if the IP address belongs to a public proxy. This property - # is only available from GeoIP2 Precision Insights. + # is only available from Insights. # # @return [Boolean] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#138 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#150 def public_proxy?; end # This is true if the IP address is on a suspected anonymizing network # and belongs to a residential ISP. This property is only available - # from GeoIP2 Precision Insights. + # from Insights. # # @return [Boolean] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#147 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#159 def residential_proxy?; end # An indicator of how static or dynamic an IP address is. This property is - # only available from GeoIP2 Precision Insights. + # only available from Insights. # # @return [Float, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#190 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#202 def static_ip_score; end # This is true if the IP address is a Tor exit node. This property is only - # available from GeoIP2 Precision Insights. + # available from Insights. # # @return [Boolean] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#155 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#167 def tor_exit_node?; end # The estimated number of users sharing the IP/network during the past 24 # hours. For IPv4, the count is for the individual IP. For IPv6, the count - # is for the /64 network. This property is only available from GeoIP2 - # Precision Insights. + # is for the /64 network. This property is only available from Insights. # # @return [Integer, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#200 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#211 def user_count; end # The user type associated with the IP address. This can be one of the @@ -1288,6 +1299,7 @@ class MaxMind::GeoIP2::Record::Traits < ::MaxMind::GeoIP2::Record::Abstract # * cafe # * cellular # * college + # * consumer_privacy_network # * content_delivery_network # * dialup # * government @@ -1301,10 +1313,15 @@ class MaxMind::GeoIP2::Record::Traits < ::MaxMind::GeoIP2::Record::Abstract # * traveler # # This attribute is only available from the Insights web service and the - # GeoIP2 Enterprise database. + # Enterprise database. # # @return [String, nil] # - # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#227 + # source://maxmind-geoip2//lib/maxmind/geoip2/record/traits.rb#239 def user_type; end end + +# The Gem version. +# +# source://maxmind-geoip2//lib/maxmind/geoip2/version.rb#6 +MaxMind::GeoIP2::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/maxminddb@0.1.22.rbi b/sorbet/rbi/gems/maxminddb@0.1.22.rbi index a1a37192c..8fc648daf 100644 --- a/sorbet/rbi/gems/maxminddb@0.1.22.rbi +++ b/sorbet/rbi/gems/maxminddb@0.1.22.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `maxminddb` gem. # Please instead update this file by running `bin/tapioca gem maxminddb`. + # source://maxminddb//lib/maxminddb/version.rb#1 module MaxMindDB class << self diff --git a/sorbet/rbi/gems/mechanize@2.9.1.rbi b/sorbet/rbi/gems/mechanize@2.12.0.rbi similarity index 92% rename from sorbet/rbi/gems/mechanize@2.9.1.rbi rename to sorbet/rbi/gems/mechanize@2.12.0.rbi index 33ee8028b..d0fedf77f 100644 --- a/sorbet/rbi/gems/mechanize@2.9.1.rbi +++ b/sorbet/rbi/gems/mechanize@2.12.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `mechanize` gem. # Please instead update this file by running `bin/tapioca gem mechanize`. + # source://mechanize//lib/mechanize/cookie.rb#54 class HTTP::Cookie include ::Mechanize::CookieDeprecated @@ -17,55 +18,55 @@ class HTTP::CookieJar include ::Mechanize::CookieDeprecated include ::Mechanize::CookieJarIMethods - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#69 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#69 def initialize(options = T.unsafe(nil)); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#105 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#105 def <<(cookie); end # source://mechanize//lib/mechanize/cookie_jar.rb#12 def add(arg1, arg2 = T.unsafe(nil)); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#340 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#340 def cleanup(session = T.unsafe(nil)); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#333 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#333 def clear; end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#130 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#130 def cookies(url = T.unsafe(nil)); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#122 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#122 def delete(cookie); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#155 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#155 def each(uri = T.unsafe(nil), &block); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#136 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#136 def empty?(url = T.unsafe(nil)); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#294 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#294 def load(readable, *options); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#183 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#183 def parse(set_cookie, origin, options = T.unsafe(nil)); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#231 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#231 def save(writable, *options); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#30 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#30 def store; end private - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#32 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#32 def get_impl(base, value, *args); end - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#78 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#78 def initialize_copy(other); end class << self - # source://http-cookie/1.0.5/lib/http/cookie_jar.rb#10 + # source://http-cookie/1.0.7/lib/http/cookie_jar.rb#10 def const_missing(name); end end end @@ -137,7 +138,7 @@ class Mechanize # # If you need segregated SSL connections give each agent a unique # name. Otherwise the connections will be shared. This is - # particularly important if you are using certifcates. + # particularly important if you are using certificates. # # agent_1 = Mechanize.new 'conn1' # agent_2 = Mechanize.new 'conn2' @@ -146,7 +147,7 @@ class Mechanize # @yield [_self] # @yieldparam _self [Mechanize] the object that the method was called on # - # source://mechanize//lib/mechanize.rb#210 + # source://mechanize//lib/mechanize.rb#209 def initialize(connection_name = T.unsafe(nil)); end # Adds credentials +user+, +pass+ for +uri+. If +realm+ is set the @@ -156,12 +157,12 @@ class Mechanize # +domain+ and +realm+ are exclusive as NTLM does not follow RFC 2617. If # +domain+ is given it is only used for NTLM authentication. # - # source://mechanize//lib/mechanize.rb#743 + # source://mechanize//lib/mechanize.rb#742 def add_auth(uri, user, password, realm = T.unsafe(nil), domain = T.unsafe(nil)); end # :section: Utilities # - # source://mechanize//lib/mechanize.rb#1254 + # source://mechanize//lib/mechanize.rb#1253 def agent; end # *NOTE*: These credentials will be used as a default for any challenge @@ -173,12 +174,12 @@ class Mechanize # HTTP authentication for any server. The +domain+ is used for NTLM # authentication. # - # source://mechanize//lib/mechanize.rb#720 + # source://mechanize//lib/mechanize.rb#719 def auth(user, password, domain = T.unsafe(nil)); end # Equivalent to the browser back button. Returns the previous page visited. # - # source://mechanize//lib/mechanize.rb#251 + # source://mechanize//lib/mechanize.rb#250 def back; end # *NOTE*: These credentials will be used as a default for any challenge @@ -190,28 +191,28 @@ class Mechanize # HTTP authentication for any server. The +domain+ is used for NTLM # authentication. # - # source://mechanize//lib/mechanize.rb#720 + # source://mechanize//lib/mechanize.rb#719 def basic_auth(user, password, domain = T.unsafe(nil)); end # Path to an OpenSSL server certificate file # - # source://mechanize//lib/mechanize.rb#1103 + # source://mechanize//lib/mechanize.rb#1102 def ca_file; end # Sets the certificate file used for SSL connections # - # source://mechanize//lib/mechanize.rb#1110 + # source://mechanize//lib/mechanize.rb#1109 def ca_file=(ca_file); end # An OpenSSL client certificate or the path to a certificate file. # - # source://mechanize//lib/mechanize.rb#1117 + # source://mechanize//lib/mechanize.rb#1116 def cert; end # Sets the OpenSSL client certificate +cert+ to the given path or # certificate instance # - # source://mechanize//lib/mechanize.rb#1125 + # source://mechanize//lib/mechanize.rb#1124 def cert=(cert); end # An OpenSSL certificate store for verifying server certificates. This @@ -235,38 +236,38 @@ class Mechanize # # agent.cert_store = cert_store # - # source://mechanize//lib/mechanize.rb#1151 + # source://mechanize//lib/mechanize.rb#1150 def cert_store; end # Sets the OpenSSL certificate store to +store+. # # See also #cert_store # - # source://mechanize//lib/mechanize.rb#1160 + # source://mechanize//lib/mechanize.rb#1159 def cert_store=(cert_store); end # What is this? # # Why is it different from #cert? # - # source://mechanize//lib/mechanize.rb#1169 + # source://mechanize//lib/mechanize.rb#1168 def certificate; end # If the parameter is a string, finds the button or link with the # value of the string on the current page and clicks it. Otherwise, clicks # the Mechanize::Page::Link object passed in. Returns the page fetched. # - # source://mechanize//lib/mechanize.rb#352 + # source://mechanize//lib/mechanize.rb#351 def click(link); end # Are If-Modified-Since conditional requests enabled? # - # source://mechanize//lib/mechanize.rb#750 + # source://mechanize//lib/mechanize.rb#749 def conditional_requests; end # Disables If-Modified-Since conditional requests (enabled by default) # - # source://mechanize//lib/mechanize.rb#757 + # source://mechanize//lib/mechanize.rb#756 def conditional_requests=(enabled); end # A list of hooks to call before reading response header 'content-encoding'. @@ -274,39 +275,39 @@ class Mechanize # The hook is called with the agent making the request, the URI of the # request, the response an IO containing the response body. # - # source://mechanize//lib/mechanize.rb#318 + # source://mechanize//lib/mechanize.rb#317 def content_encoding_hooks; end # A Mechanize::CookieJar which stores cookies # - # source://mechanize//lib/mechanize.rb#764 + # source://mechanize//lib/mechanize.rb#763 def cookie_jar; end # Replaces the cookie jar with +cookie_jar+ # - # source://mechanize//lib/mechanize.rb#771 + # source://mechanize//lib/mechanize.rb#770 def cookie_jar=(cookie_jar); end # Returns a list of cookies stored in the cookie jar. # - # source://mechanize//lib/mechanize.rb#778 + # source://mechanize//lib/mechanize.rb#777 def cookies; end # Returns the latest page loaded by Mechanize # - # source://mechanize//lib/mechanize.rb#258 + # source://mechanize//lib/mechanize.rb#257 def current_page; end # A default encoding name used when parsing HTML parsing. When set it is # used after any other encoding. The default is nil. # - # source://mechanize//lib/mechanize.rb#658 + # source://mechanize//lib/mechanize.rb#657 def default_encoding; end # A default encoding name used when parsing HTML parsing. When set it is # used after any other encoding. The default is nil. # - # source://mechanize//lib/mechanize.rb#658 + # source://mechanize//lib/mechanize.rb#657 def default_encoding=(_arg0); end # DELETE +uri+ with +query_params+, and setting +headers+: @@ -316,7 +317,7 @@ class Mechanize # # delete('http://example/', {'q' => 'foo'}, {}) # - # source://mechanize//lib/mechanize.rb#446 + # source://mechanize//lib/mechanize.rb#445 def delete(uri, query_params = T.unsafe(nil), headers = T.unsafe(nil)); end # GETs +uri+ and writes it to +io_or_filename+ without recording the request @@ -332,19 +333,19 @@ class Mechanize # For alternate ways of downloading files see Mechanize::FileSaver and # Mechanize::DirectorySaver. # - # source://mechanize//lib/mechanize.rb#411 + # source://mechanize//lib/mechanize.rb#410 def download(uri, io_or_filename, parameters = T.unsafe(nil), referer = T.unsafe(nil), headers = T.unsafe(nil)); end # Follow HTML meta refresh and HTTP Refresh headers. If set to +:anywhere+ # meta refresh tags outside of the head element will be followed. # - # source://mechanize//lib/mechanize.rb#786 + # source://mechanize//lib/mechanize.rb#785 def follow_meta_refresh; end # Controls following of HTML meta refresh and HTTP Refresh headers in # responses. # - # source://mechanize//lib/mechanize.rb#794 + # source://mechanize//lib/mechanize.rb#793 def follow_meta_refresh=(follow); end # Follow an HTML meta refresh and HTTP Refresh headers that have no "url=" @@ -352,41 +353,41 @@ class Mechanize # # Defaults to false to prevent infinite refresh loops. # - # source://mechanize//lib/mechanize.rb#804 + # source://mechanize//lib/mechanize.rb#803 def follow_meta_refresh_self; end # Alters the following of HTML meta refresh and HTTP Refresh headers that # point to the same page. # - # source://mechanize//lib/mechanize.rb#812 + # source://mechanize//lib/mechanize.rb#811 def follow_meta_refresh_self=(follow); end # Sets the mechanize redirect handling policy. See redirect_ok for allowed # values # - # source://mechanize//lib/mechanize.rb#973 + # source://mechanize//lib/mechanize.rb#972 def follow_redirect=(follow); end # Controls how mechanize deals with redirects. The following values are # allowed: # # :all, true:: All 3xx redirects are followed (default) - # :permanent:: Only 301 Moved Permanantly redirects are followed + # :permanent:: Only 301 Moved Permanently redirects are followed # false:: No redirects are followed # - # source://mechanize//lib/mechanize.rb#963 + # source://mechanize//lib/mechanize.rb#962 def follow_redirect?; end # Overrides the encodings given by the HTTP server and the HTML page with # the default_encoding when set to true. # - # source://mechanize//lib/mechanize.rb#664 + # source://mechanize//lib/mechanize.rb#663 def force_default_encoding; end # Overrides the encodings given by the HTTP server and the HTML page with # the default_encoding when set to true. # - # source://mechanize//lib/mechanize.rb#664 + # source://mechanize//lib/mechanize.rb#663 def force_default_encoding=(_arg0); end # GET the +uri+ with the given request +parameters+, +referer+ and @@ -399,22 +400,22 @@ class Mechanize # # @yield [page] # - # source://mechanize//lib/mechanize.rb#461 + # source://mechanize//lib/mechanize.rb#460 def get(uri, parameters = T.unsafe(nil), referer = T.unsafe(nil), headers = T.unsafe(nil)); end # GET +url+ and return only its contents # - # source://mechanize//lib/mechanize.rb#493 + # source://mechanize//lib/mechanize.rb#492 def get_file(url); end # Is gzip compression of responses enabled? # - # source://mechanize//lib/mechanize.rb#819 + # source://mechanize//lib/mechanize.rb#818 def gzip_enabled; end # Disables HTTP/1.1 gzip compression (enabled by default) # - # source://mechanize//lib/mechanize.rb#826 + # source://mechanize//lib/mechanize.rb#825 def gzip_enabled=(enabled); end # HEAD +uri+ with +query_params+ and +headers+: @@ -426,44 +427,44 @@ class Mechanize # # @yield [page] # - # source://mechanize//lib/mechanize.rb#505 + # source://mechanize//lib/mechanize.rb#504 def head(uri, query_params = T.unsafe(nil), headers = T.unsafe(nil)); end # The history of this mechanize run # - # source://mechanize//lib/mechanize.rb#267 + # source://mechanize//lib/mechanize.rb#266 def history; end # Callback which is invoked with the page that was added to history. # - # source://mechanize//lib/mechanize.rb#325 + # source://mechanize//lib/mechanize.rb#324 def history_added; end # Callback which is invoked with the page that was added to history. # - # source://mechanize//lib/mechanize.rb#325 + # source://mechanize//lib/mechanize.rb#324 def history_added=(_arg0); end # The HTML parser to be used when parsing documents # - # source://mechanize//lib/mechanize.rb#669 + # source://mechanize//lib/mechanize.rb#668 def html_parser; end # The HTML parser to be used when parsing documents # - # source://mechanize//lib/mechanize.rb#669 + # source://mechanize//lib/mechanize.rb#668 def html_parser=(_arg0); end # Connections that have not been used in this many seconds will be reset. # - # source://mechanize//lib/mechanize.rb#833 + # source://mechanize//lib/mechanize.rb#832 def idle_timeout; end # Sets the idle timeout to +idle_timeout+. The default timeout is 5 # seconds. If you experience "too many connection resets", reducing this # value may help. # - # source://mechanize//lib/mechanize.rb#841 + # source://mechanize//lib/mechanize.rb#840 def idle_timeout=(idle_timeout); end # When set to true mechanize will ignore an EOF during chunked transfer @@ -475,18 +476,18 @@ class Mechanize # CRLF (invalid termination) but it may occur earlier. In the second case # your response body may be incomplete. # - # source://mechanize//lib/mechanize.rb#855 + # source://mechanize//lib/mechanize.rb#854 def ignore_bad_chunking; end # When set to true mechanize will ignore an EOF during chunked transfer # encoding. See ignore_bad_chunking for further details # - # source://mechanize//lib/mechanize.rb#863 + # source://mechanize//lib/mechanize.rb#862 def ignore_bad_chunking=(ignore_bad_chunking); end # Are HTTP/1.1 keep-alive connections enabled? # - # source://mechanize//lib/mechanize.rb#870 + # source://mechanize//lib/mechanize.rb#869 def keep_alive; end # Disable HTTP/1.1 keep-alive connections if +enable+ is set to false. If @@ -495,42 +496,42 @@ class Mechanize # # You should first investigate reducing idle_timeout. # - # source://mechanize//lib/mechanize.rb#881 + # source://mechanize//lib/mechanize.rb#880 def keep_alive=(enable); end # HTTP/1.0 keep-alive time. This is no longer supported by mechanize as it # now uses net-http-persistent which only supports HTTP/1.1 persistent # connections # - # source://mechanize//lib/mechanize.rb#676 + # source://mechanize//lib/mechanize.rb#675 def keep_alive_time; end # HTTP/1.0 keep-alive time. This is no longer supported by mechanize as it # now uses net-http-persistent which only supports HTTP/1.1 persistent # connections # - # source://mechanize//lib/mechanize.rb#676 + # source://mechanize//lib/mechanize.rb#675 def keep_alive_time=(_arg0); end # An OpenSSL private key or the path to a private key # - # source://mechanize//lib/mechanize.rb#1176 + # source://mechanize//lib/mechanize.rb#1175 def key; end # Sets the OpenSSL client +key+ to the given path or key instance. If a # path is given, the path must contain an RSA key file. # - # source://mechanize//lib/mechanize.rb#1184 + # source://mechanize//lib/mechanize.rb#1183 def key=(key); end # The current logger. If no logger has been set Mechanize.log is used. # - # source://mechanize//lib/mechanize.rb#888 + # source://mechanize//lib/mechanize.rb#887 def log; end # Sets the +logger+ used by this instance of mechanize # - # source://mechanize//lib/mechanize.rb#895 + # source://mechanize//lib/mechanize.rb#894 def log=(logger); end # Responses larger than this will be written to a Tempfile instead of stored @@ -538,7 +539,7 @@ class Mechanize # # A value of nil disables creation of Tempfiles. # - # source://mechanize//lib/mechanize.rb#905 + # source://mechanize//lib/mechanize.rb#904 def max_file_buffer; end # Sets the maximum size of a response body that will be stored in memory to @@ -553,14 +554,14 @@ class Mechanize # # See also the discussion under #max_history= # - # source://mechanize//lib/mechanize.rb#922 + # source://mechanize//lib/mechanize.rb#921 def max_file_buffer=(bytes); end # Maximum number of items allowed in the history. The default setting is 50 # pages. Note that the size of the history multiplied by the maximum # response body size # - # source://mechanize//lib/mechanize.rb#276 + # source://mechanize//lib/mechanize.rb#275 def max_history; end # Sets the maximum number of items allowed in the history to +length+. @@ -572,38 +573,38 @@ class Mechanize # # See also the discussion under #max_file_buffer= # - # source://mechanize//lib/mechanize.rb#290 + # source://mechanize//lib/mechanize.rb#289 def max_history=(length); end # Length of time to wait until a connection is opened in seconds # - # source://mechanize//lib/mechanize.rb#929 + # source://mechanize//lib/mechanize.rb#928 def open_timeout; end # Sets the connection open timeout to +open_timeout+ # - # source://mechanize//lib/mechanize.rb#936 + # source://mechanize//lib/mechanize.rb#935 def open_timeout=(open_timeout); end # Returns the latest page loaded by Mechanize # - # source://mechanize//lib/mechanize.rb#258 + # source://mechanize//lib/mechanize.rb#257 def page; end # Parses the +body+ of the +response+ from +uri+ using the pluggable parser # that matches its content type # - # source://mechanize//lib/mechanize.rb#1260 + # source://mechanize//lib/mechanize.rb#1259 def parse(uri, response, body); end # OpenSSL client key password # - # source://mechanize//lib/mechanize.rb#1191 + # source://mechanize//lib/mechanize.rb#1190 def pass; end # Sets the client key password to +pass+ # - # source://mechanize//lib/mechanize.rb#1198 + # source://mechanize//lib/mechanize.rb#1197 def pass=(pass); end # The pluggable parser maps a response Content-Type to a parser class. The @@ -615,7 +616,7 @@ class Mechanize # # agent.pluggable_parser['application/octet-stream'] = Mechanize::Download # - # source://mechanize//lib/mechanize.rb#688 + # source://mechanize//lib/mechanize.rb#687 def pluggable_parser; end # POST to the given +uri+ with the given +query+. @@ -634,118 +635,118 @@ class Mechanize # agent.post('http://example.com/', "hello", # 'Content-Type' => 'application/xml') # - # source://mechanize//lib/mechanize.rb#530 + # source://mechanize//lib/mechanize.rb#529 def post(uri, query = T.unsafe(nil), headers = T.unsafe(nil)); end # A list of hooks to call after retrieving a response. Hooks are called with # the agent, the URI, the response, and the response body. # - # source://mechanize//lib/mechanize.rb#331 + # source://mechanize//lib/mechanize.rb#330 def post_connect_hooks; end # A list of hooks to call before retrieving a response. Hooks are called # with the agent, the URI, the response, and the response body. # - # source://mechanize//lib/mechanize.rb#339 + # source://mechanize//lib/mechanize.rb#338 def pre_connect_hooks; end - # source://mechanize//lib/mechanize.rb#1287 + # source://mechanize//lib/mechanize.rb#1286 def pretty_print(q); end # The HTTP proxy address # - # source://mechanize//lib/mechanize.rb#693 + # source://mechanize//lib/mechanize.rb#692 def proxy_addr; end # The HTTP proxy password # - # source://mechanize//lib/mechanize.rb#698 + # source://mechanize//lib/mechanize.rb#697 def proxy_pass; end # The HTTP proxy port # - # source://mechanize//lib/mechanize.rb#703 + # source://mechanize//lib/mechanize.rb#702 def proxy_port; end # The HTTP proxy username # - # source://mechanize//lib/mechanize.rb#708 + # source://mechanize//lib/mechanize.rb#707 def proxy_user; end # PUT to +uri+ with +entity+, and setting +headers+: # # put('http://example/', 'new content', {'Content-Type' => 'text/plain'}) # - # source://mechanize//lib/mechanize.rb#564 + # source://mechanize//lib/mechanize.rb#563 def put(uri, entity, headers = T.unsafe(nil)); end # Length of time to wait for data from the server # - # source://mechanize//lib/mechanize.rb#943 + # source://mechanize//lib/mechanize.rb#942 def read_timeout; end # Sets the timeout for each chunk of data read from the server to # +read_timeout+. A single request may read many chunks of data. # - # source://mechanize//lib/mechanize.rb#951 + # source://mechanize//lib/mechanize.rb#950 def read_timeout=(read_timeout); end # Controls how mechanize deals with redirects. The following values are # allowed: # # :all, true:: All 3xx redirects are followed (default) - # :permanent:: Only 301 Moved Permanantly redirects are followed + # :permanent:: Only 301 Moved Permanently redirects are followed # false:: No redirects are followed # - # source://mechanize//lib/mechanize.rb#963 + # source://mechanize//lib/mechanize.rb#962 def redirect_ok; end # Sets the mechanize redirect handling policy. See redirect_ok for allowed # values # - # source://mechanize//lib/mechanize.rb#973 + # source://mechanize//lib/mechanize.rb#972 def redirect_ok=(follow); end # Maximum number of redirections to follow # - # source://mechanize//lib/mechanize.rb#982 + # source://mechanize//lib/mechanize.rb#981 def redirection_limit; end # Sets the maximum number of redirections to follow to +limit+ # - # source://mechanize//lib/mechanize.rb#989 + # source://mechanize//lib/mechanize.rb#988 def redirection_limit=(limit); end # A hash of custom request headers that will be sent on every request # - # source://mechanize//lib/mechanize.rb#1002 + # source://mechanize//lib/mechanize.rb#1001 def request_headers; end # Replaces the custom request headers that will be sent on every request # with +request_headers+ # - # source://mechanize//lib/mechanize.rb#1010 + # source://mechanize//lib/mechanize.rb#1009 def request_headers=(request_headers); end # Makes an HTTP request to +url+ using HTTP method +verb+. +entity+ is used # as the request body, if allowed. # - # source://mechanize//lib/mechanize.rb#572 + # source://mechanize//lib/mechanize.rb#571 def request_with_entity(verb, uri, entity, headers = T.unsafe(nil)); end # Clears history and cookies. # - # source://mechanize//lib/mechanize.rb#1311 + # source://mechanize//lib/mechanize.rb#1310 def reset; end # Resolve the full path of a link / uri # - # source://mechanize//lib/mechanize.rb#995 + # source://mechanize//lib/mechanize.rb#994 def resolve(link); end # Retry POST and other non-idempotent requests. See RFC 2616 9.1.2. # - # source://mechanize//lib/mechanize.rb#1017 + # source://mechanize//lib/mechanize.rb#1016 def retry_change_requests; end # When setting +retry_change_requests+ to true you are stating that, for all @@ -757,50 +758,50 @@ class Mechanize # instead investigate reducing the idle_timeout or disabling keep_alive # connections. # - # source://mechanize//lib/mechanize.rb#1031 + # source://mechanize//lib/mechanize.rb#1030 def retry_change_requests=(retry_change_requests); end # Will /robots.txt files be obeyed? # - # source://mechanize//lib/mechanize.rb#1038 + # source://mechanize//lib/mechanize.rb#1037 def robots; end # When +enabled+ mechanize will retrieve and obey robots.txt # files # - # source://mechanize//lib/mechanize.rb#1046 + # source://mechanize//lib/mechanize.rb#1045 def robots=(enabled); end # The handlers for HTTP and other URI protocols. # - # source://mechanize//lib/mechanize.rb#1053 + # source://mechanize//lib/mechanize.rb#1052 def scheme_handlers; end # Replaces the URI scheme handler table with +scheme_handlers+ # - # source://mechanize//lib/mechanize.rb#1060 + # source://mechanize//lib/mechanize.rb#1059 def scheme_handlers=(scheme_handlers); end # Sets the proxy +address+ at +port+ with an optional +user+ and +password+ # - # source://mechanize//lib/mechanize.rb#1299 + # source://mechanize//lib/mechanize.rb#1298 def set_proxy(address, port, user = T.unsafe(nil), password = T.unsafe(nil)); end # Shuts down this session by clearing browsing state and closing all # persistent connections. # - # source://mechanize//lib/mechanize.rb#1319 + # source://mechanize//lib/mechanize.rb#1318 def shutdown; end # SSL version to use. # - # source://mechanize//lib/mechanize.rb#1205 + # source://mechanize//lib/mechanize.rb#1204 def ssl_version; end # Sets the SSL version to use to +version+ without client/server # negotiation. # - # source://mechanize//lib/mechanize.rb#1213 + # source://mechanize//lib/mechanize.rb#1212 def ssl_version=(ssl_version); end # Submits +form+ with an optional +button+. @@ -814,31 +815,31 @@ class Mechanize # # agent.submit(page.forms.first, page.forms.first.buttons.first) # - # source://mechanize//lib/mechanize.rb#599 + # source://mechanize//lib/mechanize.rb#598 def submit(form, button = T.unsafe(nil), headers = T.unsafe(nil)); end # Runs given block, then resets the page history as it was before. self is # given as a parameter to the block. Returns the value of the block. # - # source://mechanize//lib/mechanize.rb#619 + # source://mechanize//lib/mechanize.rb#618 def transact; end # The identification string for the client initiating a web request # - # source://mechanize//lib/mechanize.rb#1067 + # source://mechanize//lib/mechanize.rb#1066 def user_agent; end # Sets the User-Agent used by mechanize to +user_agent+. See also # user_agent_alias # - # source://mechanize//lib/mechanize.rb#1075 + # source://mechanize//lib/mechanize.rb#1074 def user_agent=(user_agent); end # Set the user agent for the Mechanize object based on the given +name+. # # See also AGENT_ALIASES # - # source://mechanize//lib/mechanize.rb#1084 + # source://mechanize//lib/mechanize.rb#1083 def user_agent_alias=(name); end # A callback for additional certificate verification. See @@ -848,31 +849,31 @@ class Mechanize # returning +true+. Specifying nil uses the default method that was valid # when the SSLContext was created # - # source://mechanize//lib/mechanize.rb#1225 + # source://mechanize//lib/mechanize.rb#1224 def verify_callback; end # Sets the OpenSSL certificate verification callback # - # source://mechanize//lib/mechanize.rb#1232 + # source://mechanize//lib/mechanize.rb#1231 def verify_callback=(verify_callback); end # the OpenSSL server certificate verification method. The default is # OpenSSL::SSL::VERIFY_PEER and certificate verification uses the default # system certificates. See also cert_store # - # source://mechanize//lib/mechanize.rb#1241 + # source://mechanize//lib/mechanize.rb#1240 def verify_mode; end # Sets the OpenSSL server certificate verification method. # - # source://mechanize//lib/mechanize.rb#1248 + # source://mechanize//lib/mechanize.rb#1247 def verify_mode=(verify_mode); end # Returns a visited page for the +url+ passed in, otherwise nil # # @return [Boolean] # - # source://mechanize//lib/mechanize.rb#297 + # source://mechanize//lib/mechanize.rb#296 def visited?(url); end # Returns a visited page for the +url+ passed in, otherwise nil @@ -880,31 +881,31 @@ class Mechanize # # @return [Boolean] # - # source://mechanize//lib/mechanize.rb#297 + # source://mechanize//lib/mechanize.rb#296 def visited_page(url); end # The value of watch_for_set is passed to pluggable parsers for retrieved # content # - # source://mechanize//lib/mechanize.rb#1093 + # source://mechanize//lib/mechanize.rb#1092 def watch_for_set; end # The value of watch_for_set is passed to pluggable parsers for retrieved # content # - # source://mechanize//lib/mechanize.rb#1093 + # source://mechanize//lib/mechanize.rb#1092 def watch_for_set=(_arg0); end private # Adds +page+ to the history # - # source://mechanize//lib/mechanize.rb#1351 + # source://mechanize//lib/mechanize.rb#1350 def add_to_history(page); end # Posts +form+ to +uri+ # - # source://mechanize//lib/mechanize.rb#1329 + # source://mechanize//lib/mechanize.rb#1328 def post_form(uri, form, headers = T.unsafe(nil)); end class << self @@ -912,31 +913,31 @@ class Mechanize # # Mechanize.html_parser = Nokogiri::XML # - # source://mechanize//lib/mechanize.rb#643 + # source://mechanize//lib/mechanize.rb#642 def html_parser; end # Default HTML parser for all mechanize instances # # Mechanize.html_parser = Nokogiri::XML # - # source://mechanize//lib/mechanize.rb#643 + # source://mechanize//lib/mechanize.rb#642 def html_parser=(_arg0); end - # source://mechanize//lib/mechanize.rb#169 + # source://mechanize//lib/mechanize.rb#168 def inherited(child); end # Default logger for all mechanize instances # # Mechanize.log = Logger.new $stderr # - # source://mechanize//lib/mechanize.rb#650 + # source://mechanize//lib/mechanize.rb#649 def log; end # Default logger for all mechanize instances # # Mechanize.log = Logger.new $stderr # - # source://mechanize//lib/mechanize.rb#650 + # source://mechanize//lib/mechanize.rb#649 def log=(_arg0); end # Creates a new Mechanize instance and yields it to the given block. @@ -948,7 +949,7 @@ class Mechanize # m.get("http://example.com") # end # - # source://mechanize//lib/mechanize.rb#185 + # source://mechanize//lib/mechanize.rb#184 def start; end end end @@ -976,6 +977,7 @@ end # # Windows User-Agent aliases: # +# * "Windows Chrome" # * "Windows Edge" # * "Windows Firefox" # * "Windows IE 6" @@ -1256,7 +1258,7 @@ end # Base mechanize error class # -# source://mechanize//lib/mechanize.rb#76 +# source://mechanize//lib/mechanize.rb#75 class Mechanize::Error < ::RuntimeError; end # This is the base class for the Pluggable Parsers. If Mechanize cannot find @@ -1768,7 +1770,7 @@ class Mechanize::Form # source://mechanize//lib/mechanize/form.rb#35 def ignore_encoding_error=(_arg0); end - # source://pp/0.4.0/pp.rb#637 + # source://pp/0.5.0/pp.rb#637 def inspect; end # Returns all fields of type Keygen @@ -2574,7 +2576,7 @@ class Mechanize::HTTP::Agent # If a block is provided, each chunk of +input_io+ is yielded for further # processing. # - # source://mechanize//lib/mechanize/http/agent.rb#1194 + # source://mechanize//lib/mechanize/http/agent.rb#1223 def auto_io(name, read_size, input_io); end # Equivalent to the browser back button. Returns the most recent page @@ -2585,33 +2587,33 @@ class Mechanize::HTTP::Agent # Path to an OpenSSL CA certificate file # - # source://mechanize//lib/mechanize/http/agent.rb#1085 + # source://mechanize//lib/mechanize/http/agent.rb#1114 def ca_file; end # Sets the path to an OpenSSL CA certificate file # - # source://mechanize//lib/mechanize/http/agent.rb#1090 + # source://mechanize//lib/mechanize/http/agent.rb#1119 def ca_file=(ca_file); end # The SSL certificate store used for validating connections # - # source://mechanize//lib/mechanize/http/agent.rb#1095 + # source://mechanize//lib/mechanize/http/agent.rb#1124 def cert_store; end # Sets the SSL certificate store used for validating connections # - # source://mechanize//lib/mechanize/http/agent.rb#1100 + # source://mechanize//lib/mechanize/http/agent.rb#1129 def cert_store=(cert_store); end # The client X509 certificate # - # source://mechanize//lib/mechanize/http/agent.rb#1105 + # source://mechanize//lib/mechanize/http/agent.rb#1134 def certificate; end # Sets the client certificate to given X509 certificate. If a path is given # the certificate will be loaded and set. # - # source://mechanize//lib/mechanize/http/agent.rb#1111 + # source://mechanize//lib/mechanize/http/agent.rb#1140 def certificate=(certificate); end # Disables If-Modified-Since conditional requests (enabled by default) @@ -2629,6 +2631,19 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#429 def connection_for(uri); end + # Decodes a Brotli-encoded +body_io+ + # + # (Experimental, CRuby only) Although Mechanize will never request a Brotli-encoded response via + # `accept-encoding`, buggy servers may return brotli-encoded responses anyway. Let's try to handle + # that case if the Brotli gem is loaded. + # + # If you need to handle Brotli-encoded responses, install the 'brotli' gem and require it in your + # application. If the `Brotli` constant is defined, Mechanize will attempt to use it to inflate + # the response. + # + # source://mechanize//lib/mechanize/http/agent.rb#509 + def content_encoding_brotli(body_io); end + # Decodes a gzip-encoded +body_io+. If it cannot be decoded, inflate is # tried followed by raising an error. # @@ -2674,10 +2689,10 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#52 def digest_challenges; end - # source://mechanize//lib/mechanize/http/agent.rb#498 + # source://mechanize//lib/mechanize/http/agent.rb#526 def disable_keep_alive(request); end - # source://mechanize//lib/mechanize/http/agent.rb#502 + # source://mechanize//lib/mechanize/http/agent.rb#530 def enable_gzip(request); end # Retrieves +uri+ and parses it into a page or other object according to @@ -2723,10 +2738,10 @@ class Mechanize::HTTP::Agent # :section: Response # - # source://mechanize//lib/mechanize/http/agent.rb#725 + # source://mechanize//lib/mechanize/http/agent.rb#752 def get_meta_refresh(response, uri, page); end - # source://mechanize//lib/mechanize/http/agent.rb#1019 + # source://mechanize//lib/mechanize/http/agent.rb#1048 def get_robots(uri); end # Is gzip compression of requests enabled? @@ -2757,17 +2772,17 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#123 def http; end - # source://mechanize//lib/mechanize/http/agent.rb#510 + # source://mechanize//lib/mechanize/http/agent.rb#538 def http_request(uri, method, params = T.unsafe(nil)); end # Reset connections that have not been used in this many seconds # - # source://mechanize//lib/mechanize/http/agent.rb#1175 + # source://mechanize//lib/mechanize/http/agent.rb#1204 def idle_timeout; end # Sets the connection idle timeout for persistent connections # - # source://mechanize//lib/mechanize/http/agent.rb#1180 + # source://mechanize//lib/mechanize/http/agent.rb#1209 def idle_timeout=(timeout); end # When set to true mechanize will ignore an EOF during chunked transfer @@ -2784,7 +2799,7 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#128 def ignore_bad_chunking=(_arg0); end - # source://mechanize//lib/mechanize/http/agent.rb#1215 + # source://mechanize//lib/mechanize/http/agent.rb#1244 def inflate(compressed, window_bits = T.unsafe(nil)); end # Set to false to disable HTTP/1.1 keep-alive requests @@ -2797,10 +2812,10 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#101 def keep_alive=(_arg0); end - # source://mechanize//lib/mechanize/http/agent.rb#1229 + # source://mechanize//lib/mechanize/http/agent.rb#1258 def log; end - # source://mechanize//lib/mechanize/http/agent.rb#1273 + # source://mechanize//lib/mechanize/http/agent.rb#1302 def make_tempfile(name); end # Responses larger than this will be written to a Tempfile instead of stored @@ -2874,12 +2889,12 @@ class Mechanize::HTTP::Agent # An OpenSSL private key or the path to a private key # - # source://mechanize//lib/mechanize/http/agent.rb#1122 + # source://mechanize//lib/mechanize/http/agent.rb#1151 def private_key; end # Sets the client's private key # - # source://mechanize//lib/mechanize/http/agent.rb#1127 + # source://mechanize//lib/mechanize/http/agent.rb#1156 def private_key=(private_key); end # URI for a proxy connection @@ -2901,7 +2916,7 @@ class Mechanize::HTTP::Agent # allowed: # # :all, true:: All 3xx redirects are followed (default) - # :permanent:: Only 301 Moved Permanantly redirects are followed + # :permanent:: Only 301 Moved Permanently redirects are followed # false:: No redirects are followed # # source://mechanize//lib/mechanize/http/agent.rb#71 @@ -2911,7 +2926,7 @@ class Mechanize::HTTP::Agent # allowed: # # :all, true:: All 3xx redirects are followed (default) - # :permanent:: Only 301 Moved Permanantly redirects are followed + # :permanent:: Only 301 Moved Permanently redirects are followed # false:: No redirects are followed # # source://mechanize//lib/mechanize/http/agent.rb#71 @@ -2927,16 +2942,16 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#74 def redirection_limit=(_arg0); end - # source://mechanize//lib/mechanize/http/agent.rb#524 + # source://mechanize//lib/mechanize/http/agent.rb#552 def request_add_headers(request, headers = T.unsafe(nil)); end - # source://mechanize//lib/mechanize/http/agent.rb#541 + # source://mechanize//lib/mechanize/http/agent.rb#569 def request_auth(request, uri); end - # source://mechanize//lib/mechanize/http/agent.rb#557 + # source://mechanize//lib/mechanize/http/agent.rb#585 def request_auth_digest(request, uri, realm, base_uri, iis); end - # source://mechanize//lib/mechanize/http/agent.rb#566 + # source://mechanize//lib/mechanize/http/agent.rb#594 def request_cookies(request, uri); end # A hash of request headers to be used for every request @@ -2949,64 +2964,64 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#25 def request_headers=(_arg0); end - # source://mechanize//lib/mechanize/http/agent.rb#576 + # source://mechanize//lib/mechanize/http/agent.rb#604 def request_host(request, uri); end - # source://mechanize//lib/mechanize/http/agent.rb#583 + # source://mechanize//lib/mechanize/http/agent.rb#611 def request_language_charset(request); end # Log specified headers for the request # - # source://mechanize//lib/mechanize/http/agent.rb#589 + # source://mechanize//lib/mechanize/http/agent.rb#616 def request_log(request); end # Sets a Referer header. Fragment part is removed as demanded by # RFC 2616 14.36, and user information part is removed just like # major browsers do. # - # source://mechanize//lib/mechanize/http/agent.rb#602 + # source://mechanize//lib/mechanize/http/agent.rb#629 def request_referer(request, uri, referer); end - # source://mechanize//lib/mechanize/http/agent.rb#613 + # source://mechanize//lib/mechanize/http/agent.rb#640 def request_user_agent(request); end - # source://mechanize//lib/mechanize/http/agent.rb#1287 + # source://mechanize//lib/mechanize/http/agent.rb#1316 def reset; end - # source://mechanize//lib/mechanize/http/agent.rb#617 + # source://mechanize//lib/mechanize/http/agent.rb#644 def resolve(uri, referer = T.unsafe(nil)); end - # source://mechanize//lib/mechanize/http/agent.rb#708 + # source://mechanize//lib/mechanize/http/agent.rb#735 def resolve_parameters(uri, method, parameters); end - # source://mechanize//lib/mechanize/http/agent.rb#740 + # source://mechanize//lib/mechanize/http/agent.rb#767 def response_authenticate(response, page, uri, request, headers, params, referer); end - # source://mechanize//lib/mechanize/http/agent.rb#817 + # source://mechanize//lib/mechanize/http/agent.rb#844 def response_content_encoding(response, body_io); end - # source://mechanize//lib/mechanize/http/agent.rb#859 + # source://mechanize//lib/mechanize/http/agent.rb#888 def response_cookies(response, uri, page); end # @raise [Mechanize::RedirectLimitReachedError] # - # source://mechanize//lib/mechanize/http/agent.rb#887 + # source://mechanize//lib/mechanize/http/agent.rb#916 def response_follow_meta_refresh(response, uri, page, redirects); end - # source://mechanize//lib/mechanize/http/agent.rb#901 + # source://mechanize//lib/mechanize/http/agent.rb#930 def response_log(response); end - # source://mechanize//lib/mechanize/http/agent.rb#912 + # source://mechanize//lib/mechanize/http/agent.rb#941 def response_parse(response, body_io, uri); end # @raise [Mechanize::ResponseCodeError] # - # source://mechanize//lib/mechanize/http/agent.rb#916 + # source://mechanize//lib/mechanize/http/agent.rb#945 def response_read(response, request, uri); end # @raise [Mechanize::RedirectLimitReachedError] # - # source://mechanize//lib/mechanize/http/agent.rb#975 + # source://mechanize//lib/mechanize/http/agent.rb#1004 def response_redirect(response, method, page, redirects, headers, referer = T.unsafe(nil)); end # Retry non-idempotent requests? @@ -3024,7 +3039,7 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#88 def robots; end - # source://mechanize//lib/mechanize/http/agent.rb#1039 + # source://mechanize//lib/mechanize/http/agent.rb#1068 def robots=(value); end # Tests if this agent is allowed to access +url+, consulting the site's @@ -3032,26 +3047,26 @@ class Mechanize::HTTP::Agent # # @return [Boolean] # - # source://mechanize//lib/mechanize/http/agent.rb#1049 + # source://mechanize//lib/mechanize/http/agent.rb#1078 def robots_allowed?(uri); end # Opposite of robots_allowed? # # @return [Boolean] # - # source://mechanize//lib/mechanize/http/agent.rb#1057 + # source://mechanize//lib/mechanize/http/agent.rb#1086 def robots_disallowed?(url); end # Returns an error object if there is an error in fetching or parsing # robots.txt of the site +url+. # - # source://mechanize//lib/mechanize/http/agent.rb#1063 + # source://mechanize//lib/mechanize/http/agent.rb#1092 def robots_error(url); end # Raises the error if there is an error in fetching or parsing robots.txt of # the site +url+. # - # source://mechanize//lib/mechanize/http/agent.rb#1069 + # source://mechanize//lib/mechanize/http/agent.rb#1098 def robots_error!(url); end # Mutex used when fetching robots.txt @@ -3061,10 +3076,10 @@ class Mechanize::HTTP::Agent # Removes robots.txt cache for the site +url+. # - # source://mechanize//lib/mechanize/http/agent.rb#1074 + # source://mechanize//lib/mechanize/http/agent.rb#1103 def robots_reset(url); end - # source://mechanize//lib/mechanize/http/agent.rb#875 + # source://mechanize//lib/mechanize/http/agent.rb#904 def save_cookies(uri, set_cookie); end # Handlers for various URI schemes @@ -3077,14 +3092,14 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#131 def scheme_handlers=(_arg0); end - # source://mechanize//lib/mechanize/http/agent.rb#696 + # source://mechanize//lib/mechanize/http/agent.rb#723 def secure_resolve!(uri, referer = T.unsafe(nil)); end # Sets the proxy address, port, user, and password. +addr+ may be # an HTTP URL/URI or a host name, +port+ may be a port number, service # name or port number string. # - # source://mechanize//lib/mechanize/http/agent.rb#1238 + # source://mechanize//lib/mechanize/http/agent.rb#1267 def set_proxy(addr, port = T.unsafe(nil), user = T.unsafe(nil), pass = T.unsafe(nil)); end # Closes all open connections for this agent. @@ -3094,17 +3109,17 @@ class Mechanize::HTTP::Agent # SSL version to use # - # source://mechanize//lib/mechanize/http/agent.rb#1138 + # source://mechanize//lib/mechanize/http/agent.rb#1167 def ssl_version; end # Sets the SSL version to use # - # source://mechanize//lib/mechanize/http/agent.rb#1143 + # source://mechanize//lib/mechanize/http/agent.rb#1172 def ssl_version=(ssl_version); end # @return [Boolean] # - # source://mechanize//lib/mechanize/http/agent.rb#1280 + # source://mechanize//lib/mechanize/http/agent.rb#1309 def use_tempfile?(size); end # The User-Agent header to send @@ -3124,22 +3139,22 @@ class Mechanize::HTTP::Agent # returning +true+. Specifying nil uses the default method that was valid # when the SSLContext was created # - # source://mechanize//lib/mechanize/http/agent.rb#1153 + # source://mechanize//lib/mechanize/http/agent.rb#1182 def verify_callback; end # Sets the certificate verify callback # - # source://mechanize//lib/mechanize/http/agent.rb#1158 + # source://mechanize//lib/mechanize/http/agent.rb#1187 def verify_callback=(verify_callback); end # How to verify SSL connections. Defaults to VERIFY_PEER # - # source://mechanize//lib/mechanize/http/agent.rb#1163 + # source://mechanize//lib/mechanize/http/agent.rb#1192 def verify_mode; end # Sets the mode for verifying SSL connections # - # source://mechanize//lib/mechanize/http/agent.rb#1168 + # source://mechanize//lib/mechanize/http/agent.rb#1197 def verify_mode=(verify_mode); end # Returns a visited page for the url passed in, otherwise nil @@ -3147,7 +3162,7 @@ class Mechanize::HTTP::Agent # source://mechanize//lib/mechanize/http/agent.rb#388 def visited_page(url); end - # source://mechanize//lib/mechanize/http/agent.rb#1078 + # source://mechanize//lib/mechanize/http/agent.rb#1107 def webrobots; end end @@ -3162,7 +3177,7 @@ Mechanize::HTTP::Agent::POST_HEADERS = T.let(T.unsafe(nil), Array) # :section: Robots # -# source://mechanize//lib/mechanize/http/agent.rb#1017 +# source://mechanize//lib/mechanize/http/agent.rb#1046 Mechanize::HTTP::Agent::RobotsKey = T.let(T.unsafe(nil), Symbol) # A parsed WWW-Authenticate header @@ -3451,7 +3466,7 @@ class Mechanize::HTTP::ContentDispositionParser # source://mechanize//lib/mechanize/http/content_disposition_parser.rb#48 def parse(content_disposition, header = T.unsafe(nil)); end - # Extracts disposition-parm and returns a Hash. + # Extracts disposition-param and returns a Hash. # # source://mechanize//lib/mechanize/http/content_disposition_parser.rb#86 def parse_parameters; end @@ -3705,7 +3720,7 @@ class Mechanize::Page < ::Mechanize::File # Return a list of all base tags # - # source://mechanize//lib/mechanize/page.rb#526 + # source://mechanize//lib/mechanize/page.rb#527 def bases; end def bases_with(criteria = T.unsafe(nil)); end @@ -3713,12 +3728,12 @@ class Mechanize::Page < ::Mechanize::File # Return the canonical URI for the page if there is a link tag # with href="canonical". # - # source://mechanize//lib/mechanize/page.rb#178 + # source://mechanize//lib/mechanize/page.rb#179 def canonical_uri; end # Get the content type # - # source://mechanize//lib/mechanize/page.rb#189 + # source://mechanize//lib/mechanize/page.rb#190 def content_type; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -3734,7 +3749,7 @@ class Mechanize::Page < ::Mechanize::File def encoding=(encoding); end # Return whether parser result has errors related to encoding or not. - # false indicates just parser has no encoding errors, not encoding is vaild. + # false indicates just parser has no encoding errors, not encoding is valid. # # @return [Boolean] # @@ -3786,7 +3801,7 @@ class Mechanize::Page < ::Mechanize::File # Return a list of all form tags # - # source://mechanize//lib/mechanize/page.rb#505 + # source://mechanize//lib/mechanize/page.rb#506 def forms; end def forms_with(criteria = T.unsafe(nil)); end @@ -3809,7 +3824,7 @@ class Mechanize::Page < ::Mechanize::File # Return a list of all frame tags # - # source://mechanize//lib/mechanize/page.rb#533 + # source://mechanize//lib/mechanize/page.rb#534 def frames; end def frames_with(criteria = T.unsafe(nil)); end @@ -3832,7 +3847,7 @@ class Mechanize::Page < ::Mechanize::File # Return a list of all iframe tags # - # source://mechanize//lib/mechanize/page.rb#540 + # source://mechanize//lib/mechanize/page.rb#541 def iframes; end def iframes_with(criteria = T.unsafe(nil)); end @@ -3850,7 +3865,7 @@ class Mechanize::Page < ::Mechanize::File # end def image(criteria = T.unsafe(nil)); end - # source://mechanize//lib/mechanize/page.rb#552 + # source://mechanize//lib/mechanize/page.rb#553 def image_urls; end def image_with(criteria = T.unsafe(nil)); end @@ -3858,20 +3873,20 @@ class Mechanize::Page < ::Mechanize::File # Return a list of all img tags # - # source://mechanize//lib/mechanize/page.rb#547 + # source://mechanize//lib/mechanize/page.rb#548 def images; end def images_with(criteria = T.unsafe(nil)); end - # source://pp/0.4.0/pp.rb#637 + # source://pp/0.5.0/pp.rb#637 def inspect; end # Return a list of all label tags # - # source://mechanize//lib/mechanize/page.rb#558 + # source://mechanize//lib/mechanize/page.rb#559 def labels; end - # source://mechanize//lib/mechanize/page.rb#563 + # source://mechanize//lib/mechanize/page.rb#564 def labels_hash; end # :method: links_with @@ -3893,7 +3908,7 @@ class Mechanize::Page < ::Mechanize::File # Return a list of all link and area tags # - # source://mechanize//lib/mechanize/page.rb#495 + # source://mechanize//lib/mechanize/page.rb#496 def links; end def links_with(criteria = T.unsafe(nil)); end @@ -3915,7 +3930,7 @@ class Mechanize::Page < ::Mechanize::File # Return a list of all meta refresh elements # - # source://mechanize//lib/mechanize/page.rb#516 + # source://mechanize//lib/mechanize/page.rb#517 def meta_refresh; end # :method: at_xpath @@ -3924,19 +3939,19 @@ class Mechanize::Page < ::Mechanize::File # # See also Nokogiri::XML::Node#at_xpath for details. # - # source://mechanize//lib/mechanize/page.rb#109 + # source://mechanize//lib/mechanize/page.rb#110 def parser; end - # source://mechanize//lib/mechanize/page.rb#132 + # source://mechanize//lib/mechanize/page.rb#133 def pretty_print(q); end - # source://mechanize//lib/mechanize/page.rb#163 + # source://mechanize//lib/mechanize/page.rb#164 def reset; end # source://mechanize//lib/mechanize/page.rb#63 def response_header_charset; end - # source://mechanize//lib/mechanize/page.rb#109 + # source://mechanize//lib/mechanize/page.rb#110 def root; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -3957,27 +3972,27 @@ class Mechanize::Page < ::Mechanize::File private - # source://mechanize//lib/mechanize/page.rb#629 + # source://mechanize//lib/mechanize/page.rb#630 def html_body; end class << self - # source://mechanize//lib/mechanize/page.rb#575 + # source://mechanize//lib/mechanize/page.rb#576 def charset(content_type); end - # source://mechanize//lib/mechanize/page.rb#575 + # source://mechanize//lib/mechanize/page.rb#576 def charset_from_content_type(content_type); end # Retrieves all charsets from +meta+ tags in +body+ # - # source://mechanize//lib/mechanize/page.rb#597 + # source://mechanize//lib/mechanize/page.rb#598 def meta_charset(body); end # Retrieves the last content-type set by a +meta+ tag in +body+ # - # source://mechanize//lib/mechanize/page.rb#615 + # source://mechanize//lib/mechanize/page.rb#616 def meta_content_type(body); end - # source://mechanize//lib/mechanize/page.rb#584 + # source://mechanize//lib/mechanize/page.rb#585 def response_header_charset(response); end end end @@ -4096,7 +4111,7 @@ class Mechanize::Page::Image # source://mechanize//lib/mechanize/page/image.rb#94 def image_referer; end - # source://pp/0.4.0/pp.rb#637 + # source://pp/0.5.0/pp.rb#637 def inspect; end # Returns the value of attribute mech. @@ -4256,7 +4271,7 @@ class Mechanize::Page::Link # source://mechanize//lib/mechanize/page/link.rb#16 def href; end - # source://pp/0.4.0/pp.rb#637 + # source://pp/0.5.0/pp.rb#637 def inspect; end # Returns the value of attribute node. diff --git a/sorbet/rbi/gems/method_source@1.0.0.rbi b/sorbet/rbi/gems/method_source@1.1.0.rbi similarity index 86% rename from sorbet/rbi/gems/method_source@1.0.0.rbi rename to sorbet/rbi/gems/method_source@1.1.0.rbi index 039ac9d5d..2f1a74123 100644 --- a/sorbet/rbi/gems/method_source@1.0.0.rbi +++ b/sorbet/rbi/gems/method_source@1.1.0.rbi @@ -4,7 +4,8 @@ # This is an autogenerated file for types exported from the `method_source` gem. # Please instead update this file by running `bin/tapioca gem method_source`. -# source://method_source//lib/method_source.rb#127 + +# source://method_source//lib/method_source.rb#163 class Method include ::MethodSource::SourceLocation::MethodExtensions include ::MethodSource::MethodExtensions @@ -15,6 +16,11 @@ module MethodSource extend ::MethodSource::CodeHelpers class << self + # Clear cache. + # + # source://method_source//lib/method_source.rb#59 + def clear_cache; end + # Helper method responsible for opening source file and buffering up # the comments for a specified method. Defined here to avoid polluting # `Method` class. @@ -29,7 +35,7 @@ module MethodSource # @deprecated — use MethodSource::CodeHelpers#expression_at # - # source://method_source//lib/method_source.rb#66 + # source://method_source//lib/method_source.rb#71 def extract_code(source_location); end # Load a memoized copy of the lines in a file. @@ -55,7 +61,7 @@ module MethodSource # @deprecated — use MethodSource::CodeHelpers#complete_expression? # @return [Boolean] # - # source://method_source//lib/method_source.rb#59 + # source://method_source//lib/method_source.rb#64 def valid_expression?(str); end end end @@ -154,8 +160,21 @@ MethodSource::CodeHelpers::IncompleteExpression::RBX_ONLY_REGEXPS = T.let(T.unsa # This module is to be included by `Method` and `UnboundMethod` and # provides the `#source` functionality # -# source://method_source//lib/method_source.rb#72 +# source://method_source//lib/method_source.rb#77 module MethodSource::MethodExtensions + # Return the comments associated with the method class/module. + # + # @example + # MethodSource::MethodExtensions.method(:included).module_comment + # => + # # This module is to be included by `Method` and `UnboundMethod` and + # # provides the `#source` functionality + # @raise SourceNotFoundException + # @return [String] The method's comments as a string + # + # source://method_source//lib/method_source.rb#139 + def class_comment; end + # Return the comments associated with the method as a string. # # @example @@ -165,9 +184,22 @@ module MethodSource::MethodExtensions # @raise SourceNotFoundException # @return [String] The method's comments as a string # - # source://method_source//lib/method_source.rb#121 + # source://method_source//lib/method_source.rb#126 def comment; end + # Return the comments associated with the method class/module. + # + # @example + # MethodSource::MethodExtensions.method(:included).module_comment + # => + # # This module is to be included by `Method` and `UnboundMethod` and + # # provides the `#source` functionality + # @raise SourceNotFoundException + # @return [String] The method's comments as a string + # + # source://method_source//lib/method_source.rb#139 + def module_comment; end + # Return the sourcecode for the method as a string # # @example @@ -180,7 +212,7 @@ module MethodSource::MethodExtensions # @raise SourceNotFoundException # @return [String] The method sourcecode as a string # - # source://method_source//lib/method_source.rb#109 + # source://method_source//lib/method_source.rb#114 def source; end class << self @@ -191,7 +223,7 @@ module MethodSource::MethodExtensions # # @param klass [Class] The class that includes the module. # - # source://method_source//lib/method_source.rb#79 + # source://method_source//lib/method_source.rb#84 def included(klass); end end end @@ -259,13 +291,13 @@ class MethodSource::SourceNotFoundError < ::StandardError; end # source://method_source//lib/method_source/version.rb#2 MethodSource::VERSION = T.let(T.unsafe(nil), String) -# source://method_source//lib/method_source.rb#137 +# source://method_source//lib/method_source.rb#173 class Proc include ::MethodSource::SourceLocation::ProcExtensions include ::MethodSource::MethodExtensions end -# source://method_source//lib/method_source.rb#132 +# source://method_source//lib/method_source.rb#168 class UnboundMethod include ::MethodSource::SourceLocation::UnboundMethodExtensions include ::MethodSource::MethodExtensions diff --git a/sorbet/rbi/gems/mime-types-data@3.2023.0218.1.rbi b/sorbet/rbi/gems/mime-types-data@3.2024.0806.rbi similarity index 55% rename from sorbet/rbi/gems/mime-types-data@3.2023.0218.1.rbi rename to sorbet/rbi/gems/mime-types-data@3.2024.0806.rbi index 15129c93a..92faaf3ba 100644 --- a/sorbet/rbi/gems/mime-types-data@3.2023.0218.1.rbi +++ b/sorbet/rbi/gems/mime-types-data@3.2024.0806.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `mime-types-data` gem. # Please instead update this file by running `bin/tapioca gem mime-types-data`. + # source://mime-types-data//lib/mime/types/data.rb#3 module MIME; end @@ -11,96 +12,96 @@ module MIME; end class MIME::Types extend ::Enumerable - # source://mime-types/3.4.1/lib/mime/types.rb#75 + # source://mime-types/3.5.2/lib/mime/types.rb#75 def initialize; end - # source://mime-types/3.4.1/lib/mime/types.rb#125 + # source://mime-types/3.5.2/lib/mime/types.rb#125 def [](type_id, complete: T.unsafe(nil), registered: T.unsafe(nil)); end - # source://mime-types/3.4.1/lib/mime/types.rb#167 + # source://mime-types/3.5.2/lib/mime/types.rb#167 def add(*types); end - # source://mime-types/3.4.1/lib/mime/types.rb#188 + # source://mime-types/3.5.2/lib/mime/types.rb#188 def add_type(type, quiet = T.unsafe(nil)); end - # source://mime-types/3.4.1/lib/mime/types.rb#81 + # source://mime-types/3.5.2/lib/mime/types.rb#81 def count; end - # source://mime-types/3.4.1/lib/mime/types.rb#90 + # source://mime-types/3.5.2/lib/mime/types.rb#90 def each; end - # source://mime-types/3.4.1/lib/mime/types.rb#85 + # source://mime-types/3.5.2/lib/mime/types.rb#85 def inspect; end - # source://mime-types/3.4.1/lib/mime/types.rb#153 + # source://mime-types/3.5.2/lib/mime/types.rb#153 def of(filename); end - # source://mime-types/3.4.1/lib/mime/types.rb#153 + # source://mime-types/3.5.2/lib/mime/types.rb#153 def type_for(filename); end private - # source://mime-types/3.4.1/lib/mime/types.rb#201 + # source://mime-types/3.5.2/lib/mime/types.rb#201 def add_type_variant!(mime_type); end - # source://mime-types/3.4.1/lib/mime/types.rb#211 + # source://mime-types/3.5.2/lib/mime/types.rb#211 def index_extensions!(mime_type); end - # source://mime-types/3.4.1/lib/mime/types.rb#221 + # source://mime-types/3.5.2/lib/mime/types.rb#221 def match(pattern); end - # source://mime-types/3.4.1/lib/mime/types.rb#215 + # source://mime-types/3.5.2/lib/mime/types.rb#215 def prune_matches(matches, complete, registered); end - # source://mime-types/3.4.1/lib/mime/types.rb#205 + # source://mime-types/3.5.2/lib/mime/types.rb#205 def reindex_extensions!(mime_type); end class << self - # source://mime-types/3.4.1/lib/mime/types/registry.rb#14 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#14 def [](type_id, complete: T.unsafe(nil), registered: T.unsafe(nil)); end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#39 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#39 def add(*types); end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#19 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#19 def count; end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#24 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#24 def each; end - # source://mime-types/3.4.1/lib/mime/types/logger.rb#12 + # source://mime-types/3.5.2/lib/mime/types/logger.rb#12 def logger; end - # source://mime-types/3.4.1/lib/mime/types/logger.rb#12 + # source://mime-types/3.5.2/lib/mime/types/logger.rb#12 def logger=(_arg0); end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#7 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#7 def new(*_arg0); end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#33 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#33 def of(filename); end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#33 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#33 def type_for(filename); end private - # source://mime-types/3.4.1/lib/mime/types/registry.rb#75 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#75 def __instances__; end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#55 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#55 def __types__; end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#45 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#45 def lazy_load?; end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#65 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#65 def load_default_mime_types(mode = T.unsafe(nil)); end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#60 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#60 def load_mode; end - # source://mime-types/3.4.1/lib/mime/types/registry.rb#79 + # source://mime-types/3.5.2/lib/mime/types/registry.rb#79 def reindex_extensions(type); end end end @@ -124,6 +125,3 @@ MIME::Types::Data::PATH = T.let(T.unsafe(nil), String) # source://mime-types-data//lib/mime/types/data.rb#6 MIME::Types::Data::VERSION = T.let(T.unsafe(nil), String) - -# source://mime-types/3.4.1/lib/mime/types.rb#70 -MIME::Types::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/mime-types@3.4.1.rbi b/sorbet/rbi/gems/mime-types@3.5.2.rbi similarity index 92% rename from sorbet/rbi/gems/mime-types@3.4.1.rbi rename to sorbet/rbi/gems/mime-types@3.5.2.rbi index 1fe7f8691..74ab6ba03 100644 --- a/sorbet/rbi/gems/mime-types@3.4.1.rbi +++ b/sorbet/rbi/gems/mime-types@3.5.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `mime-types` gem. # Please instead update this file by running `bin/tapioca gem mime-types`. + # The namespace for MIME applications, tools, and libraries. # # source://mime-types//lib/mime/types.rb#4 @@ -106,7 +107,7 @@ class MIME::Type # Merge the +extensions+ provided into this MIME::Type. The extensions added # will be merged uniquely. # - # source://mime-types//lib/mime/type.rb#287 + # source://mime-types//lib/mime/type.rb#313 def add_extensions(*extensions); end # MIME types can be specified to be sent across a network in particular @@ -115,7 +116,7 @@ class MIME::Type # # @return [Boolean] # - # source://mime-types//lib/mime/type.rb#441 + # source://mime-types//lib/mime/type.rb#467 def ascii?; end # MIME types can be specified to be sent across a network in particular @@ -124,7 +125,7 @@ class MIME::Type # # @return [Boolean] # - # source://mime-types//lib/mime/type.rb#434 + # source://mime-types//lib/mime/type.rb#460 def binary?; end # Returns +true+ if the MIME::Type specifies an extension list, @@ -132,7 +133,7 @@ class MIME::Type # # @return [Boolean] # - # source://mime-types//lib/mime/type.rb#451 + # source://mime-types//lib/mime/type.rb#477 def complete?; end # Returns the whole MIME content-type string. @@ -145,22 +146,22 @@ class MIME::Type # x-chemical/x-pdb => x-chemical/x-pdb # audio/QCELP => audio/QCELP # - # source://mime-types//lib/mime/type.rb#236 + # source://mime-types//lib/mime/type.rb#262 def content_type; end # Returns the default encoding for the MIME::Type based on the media type. # - # source://mime-types//lib/mime/type.rb#340 + # source://mime-types//lib/mime/type.rb#366 def default_encoding; end # The documentation for this MIME::Type. # - # source://mime-types//lib/mime/type.rb#364 + # source://mime-types//lib/mime/type.rb#390 def docs; end # The documentation for this MIME::Type. # - # source://mime-types//lib/mime/type.rb#364 + # source://mime-types//lib/mime/type.rb#390 def docs=(_arg0); end # Populates the +coder+ with attributes about this record for @@ -169,15 +170,15 @@ class MIME::Type # # This method should be considered a private implementation detail. # - # source://mime-types//lib/mime/type.rb#485 + # source://mime-types//lib/mime/type.rb#511 def encode_with(coder); end # Returns the value of attribute encoding. # - # source://mime-types//lib/mime/type.rb#326 + # source://mime-types//lib/mime/type.rb#352 def encoding; end - # source://mime-types//lib/mime/type.rb#329 + # source://mime-types//lib/mime/type.rb#355 def encoding=(enc); end # Returns +true+ if the +other+ object is a MIME::Type and the content types @@ -194,10 +195,10 @@ class MIME::Type # # :attr_accessor: extensions # - # source://mime-types//lib/mime/type.rb#275 + # source://mime-types//lib/mime/type.rb#301 def extensions; end - # source://mime-types//lib/mime/type.rb#280 + # source://mime-types//lib/mime/type.rb#306 def extensions=(value); end # A friendly short description for this MIME::Type. @@ -206,9 +207,35 @@ class MIME::Type # text_plain.friendly # => "Text File" # text_plain.friendly('en') # => "Text File" # - # source://mime-types//lib/mime/type.rb#371 + # source://mime-types//lib/mime/type.rb#397 def friendly(lang = T.unsafe(nil)); end + # Returns a hash based on the #simplified value. + # + # This maintains the invariant that two #eql? instances must have the same + # #hash (although having the same #hash does *not* imply that the objects are + # #eql?). + # + # To see why, suppose a MIME::Type instance +a+ is compared to another object + # +b+, and that a.eql?(b) is true. By the definition of #eql?, + # we know the following: + # + # 1. +b+ is a MIME::Type instance itself. + # 2. a == b is true. + # + # Due to the first point, we know that +b+ should respond to the #simplified + # method. Thus, per the definition of #<=>, we know that +a.simplified+ must + # be equal to +b.simplified+, as compared by the <=> method corresponding to + # +a.simplified+. + # + # Presumably, if a.simplified <=> b.simplified is +0+, then + # +a.simplified+ has the same hash as +b.simplified+. So we assume it's + # suitable for #hash to delegate to #simplified in service of the #eql? + # invariant. + # + # source://mime-types//lib/mime/type.rb#249 + def hash; end + # A key suitable for use as a lookup key for translations, such as with # the I18n library. # @@ -219,7 +246,7 @@ class MIME::Type # x_msword.i18n_key # => "application.word" # # from application/x-msword # - # source://mime-types//lib/mime/type.rb#396 + # source://mime-types//lib/mime/type.rb#422 def i18n_key; end # Initialize an empty object from +coder+, which must contain the @@ -227,10 +254,10 @@ class MIME::Type # # This method should be considered a private implementation detail. # - # source://mime-types//lib/mime/type.rb#514 + # source://mime-types//lib/mime/type.rb#540 def init_with(coder); end - # source://mime-types//lib/mime/type.rb#530 + # source://mime-types//lib/mime/type.rb#556 def inspect; end # Indicates that a MIME type is like another type. This differs from @@ -247,28 +274,28 @@ class MIME::Type # x-chemical/x-pdb => x-chemical # audio/QCELP => audio # - # source://mime-types//lib/mime/type.rb#249 + # source://mime-types//lib/mime/type.rb#275 def media_type; end # Returns +true+ if the media type is obsolete. # - # source://mime-types//lib/mime/type.rb#360 + # source://mime-types//lib/mime/type.rb#386 def obsolete; end # Returns +true+ if the media type is obsolete. # - # source://mime-types//lib/mime/type.rb#360 + # source://mime-types//lib/mime/type.rb#386 def obsolete=(_arg0); end # Returns +true+ if the media type is obsolete. # - # source://mime-types//lib/mime/type.rb#360 + # source://mime-types//lib/mime/type.rb#386 def obsolete?; end - # source://mime-types//lib/mime/type.rb#301 + # source://mime-types//lib/mime/type.rb#327 def preferred_extension; end - # source://mime-types//lib/mime/type.rb#306 + # source://mime-types//lib/mime/type.rb#332 def preferred_extension=(value); end # Compares the +other+ MIME::Type based on how reliable it is before doing a @@ -293,19 +320,19 @@ class MIME::Type # Indicates whether the MIME type's registration with IANA is provisional. # - # source://mime-types//lib/mime/type.rb#424 + # source://mime-types//lib/mime/type.rb#450 def provisional; end # Indicates whether the MIME type's registration with IANA is provisional. # - # source://mime-types//lib/mime/type.rb#424 + # source://mime-types//lib/mime/type.rb#450 def provisional=(_arg0); end # Indicates whether the MIME type's registration with IANA is provisional. # # @return [Boolean] # - # source://mime-types//lib/mime/type.rb#427 + # source://mime-types//lib/mime/type.rb#453 def provisional?; end # Returns the media type of the unmodified MIME::Type. @@ -314,7 +341,7 @@ class MIME::Type # x-chemical/x-pdb => x-chemical # audio/QCELP => audio # - # source://mime-types//lib/mime/type.rb#255 + # source://mime-types//lib/mime/type.rb#281 def raw_media_type; end # Returns the media type of the unmodified MIME::Type. @@ -323,37 +350,37 @@ class MIME::Type # x-chemical/x-pdb => x-pdb # audio/QCELP => qcelp # - # source://mime-types//lib/mime/type.rb#267 + # source://mime-types//lib/mime/type.rb#293 def raw_sub_type; end # Indicates whether the MIME type has been registered with IANA. # - # source://mime-types//lib/mime/type.rb#420 + # source://mime-types//lib/mime/type.rb#446 def registered; end # Indicates whether the MIME type has been registered with IANA. # - # source://mime-types//lib/mime/type.rb#420 + # source://mime-types//lib/mime/type.rb#446 def registered=(_arg0); end # Indicates whether the MIME type has been registered with IANA. # - # source://mime-types//lib/mime/type.rb#420 + # source://mime-types//lib/mime/type.rb#446 def registered?; end # Indicateswhether the MIME type is declared as a signature type. # - # source://mime-types//lib/mime/type.rb#446 + # source://mime-types//lib/mime/type.rb#472 def signature; end # Indicateswhether the MIME type is declared as a signature type. # - # source://mime-types//lib/mime/type.rb#446 + # source://mime-types//lib/mime/type.rb#472 def signature=(_arg0); end # Indicateswhether the MIME type is declared as a signature type. # - # source://mime-types//lib/mime/type.rb#446 + # source://mime-types//lib/mime/type.rb#472 def signature?; end # A simplified form of the MIME content-type string, suitable for @@ -363,7 +390,7 @@ class MIME::Type # x-chemical/x-pdb => x-chemical/x-pdb # audio/QCELP => audio/qcelp # - # source://mime-types//lib/mime/type.rb#243 + # source://mime-types//lib/mime/type.rb#269 def simplified; end # Returns the sub-type of the simplified MIME::Type. @@ -372,23 +399,23 @@ class MIME::Type # x-chemical/x-pdb => pdb # audio/QCELP => QCELP # - # source://mime-types//lib/mime/type.rb#261 + # source://mime-types//lib/mime/type.rb#287 def sub_type; end # Converts the MIME::Type to a hash. The output of this method can also be # used to initialize a MIME::Type. # - # source://mime-types//lib/mime/type.rb#476 + # source://mime-types//lib/mime/type.rb#502 def to_h; end # Converts the MIME::Type to a JSON string. # - # source://mime-types//lib/mime/type.rb#469 + # source://mime-types//lib/mime/type.rb#495 def to_json(*args); end # Returns the MIME::Type as a string. # - # source://mime-types//lib/mime/type.rb#456 + # source://mime-types//lib/mime/type.rb#482 def to_s; end # Returns the MIME::Type as a string for implicit conversions. This allows @@ -396,72 +423,72 @@ class MIME::Type # # 'text/plain' == MIME::Type.new('text/plain') # - # source://mime-types//lib/mime/type.rb#464 + # source://mime-types//lib/mime/type.rb#490 def to_str; end - # source://mime-types//lib/mime/type.rb#352 + # source://mime-types//lib/mime/type.rb#378 def use_instead; end # Sets the attribute use_instead # # @param value the value to set the attribute use_instead to. # - # source://mime-types//lib/mime/type.rb#357 + # source://mime-types//lib/mime/type.rb#383 def use_instead=(_arg0); end # The decoded cross-reference URL list for this MIME::Type. # - # source://mime-types//lib/mime/type.rb#412 + # source://mime-types//lib/mime/type.rb#438 def xref_urls; end # Returns the value of attribute xrefs. # - # source://mime-types//lib/mime/type.rb#404 + # source://mime-types//lib/mime/type.rb#430 def xrefs; end - # source://mime-types//lib/mime/type.rb#407 + # source://mime-types//lib/mime/type.rb#433 def xrefs=(xrefs); end private - # source://mime-types//lib/mime/type.rb#583 + # source://mime-types//lib/mime/type.rb#609 def content_type=(type_string); end # MRI 2.2 and older don't have a method for string interning, # so we simply freeze them for keeping a similar interface # - # source://mime-types//lib/mime/type.rb#600 + # source://mime-types//lib/mime/type.rb#626 def intern_string(string); end - # source://mime-types//lib/mime/type.rb#611 + # source://mime-types//lib/mime/type.rb#637 def xref_map(values, helper); end - # source://mime-types//lib/mime/type.rb#619 + # source://mime-types//lib/mime/type.rb#645 def xref_url_for_draft(value); end - # source://mime-types//lib/mime/type.rb#627 + # source://mime-types//lib/mime/type.rb#653 def xref_url_for_person(value); end - # source://mime-types//lib/mime/type.rb#615 + # source://mime-types//lib/mime/type.rb#641 def xref_url_for_rfc(value); end - # source://mime-types//lib/mime/type.rb#623 + # source://mime-types//lib/mime/type.rb#649 def xref_url_for_rfc_errata(value); end - # source://mime-types//lib/mime/type.rb#631 + # source://mime-types//lib/mime/type.rb#657 def xref_url_for_template(value); end class << self # Converts a provided +content_type+ into a translation key suitable for # use with the I18n library. # - # source://mime-types//lib/mime/type.rb#550 + # source://mime-types//lib/mime/type.rb#576 def i18n_key(content_type); end # Return a +MatchData+ object of the +content_type+ against pattern of # media types. # - # source://mime-types//lib/mime/type.rb#558 + # source://mime-types//lib/mime/type.rb#584 def match(content_type); end # MIME media types are case-insensitive, but are typically presented in a @@ -472,12 +499,12 @@ class MIME::Type # prefix (x-). This is no longer default behaviour, but may be # provided by providing a truth value to +remove_x_prefix+. # - # source://mime-types//lib/mime/type.rb#544 + # source://mime-types//lib/mime/type.rb#570 def simplified(content_type, remove_x_prefix: T.unsafe(nil)); end private - # source://mime-types//lib/mime/type.rb#569 + # source://mime-types//lib/mime/type.rb#595 def simplify_matchdata(matchdata, remove_x = T.unsafe(nil), joiner: T.unsafe(nil)); end end end diff --git a/sorbet/rbi/gems/mini_magick@4.12.0.rbi b/sorbet/rbi/gems/mini_magick@4.13.2.rbi similarity index 94% rename from sorbet/rbi/gems/mini_magick@4.12.0.rbi rename to sorbet/rbi/gems/mini_magick@4.13.2.rbi index e9e394a38..927f3c6da 100644 --- a/sorbet/rbi/gems/mini_magick@4.12.0.rbi +++ b/sorbet/rbi/gems/mini_magick@4.13.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `mini_magick` gem. # Please instead update this file by running `bin/tapioca gem mini_magick`. + # source://mini_magick//lib/mini_magick/version.rb#1 module MiniMagick extend ::MiniMagick::Configuration @@ -63,13 +64,13 @@ module MiniMagick::Configuration # # @return [Symbol] `:imagemagick` or `:graphicsmagick` # - # source://mini_magick//lib/mini_magick/configuration.rb#142 + # source://mini_magick//lib/mini_magick/configuration.rb#138 def cli; end # Set whether you want to use [ImageMagick](http://www.imagemagick.org) or # [GraphicsMagick](http://www.graphicsmagick.org). # - # source://mini_magick//lib/mini_magick/configuration.rb#157 + # source://mini_magick//lib/mini_magick/configuration.rb#153 def cli=(value); end # If you set the path of CLI tools, you can get the path of the @@ -77,7 +78,7 @@ module MiniMagick::Configuration # # @return [String] # - # source://mini_magick//lib/mini_magick/configuration.rb#173 + # source://mini_magick//lib/mini_magick/configuration.rb#169 def cli_path; end # If you don't have the CLI tools in your PATH, you can set the path to the @@ -115,7 +116,7 @@ module MiniMagick::Configuration # end # @yield [self] # - # source://mini_magick//lib/mini_magick/configuration.rb#108 + # source://mini_magick//lib/mini_magick/configuration.rb#104 def configure; end # When get to `true`, it outputs each command to STDOUT in their shell @@ -129,7 +130,7 @@ module MiniMagick::Configuration # When set to `true`, it outputs each command to STDOUT in their shell # version. # - # source://mini_magick//lib/mini_magick/configuration.rb#187 + # source://mini_magick//lib/mini_magick/configuration.rb#183 def debug=(value); end # Logger for {#debug}, default is `MiniMagick::Logger.new(STDOUT)`, but @@ -152,12 +153,12 @@ module MiniMagick::Configuration # @private (for backwards compatibility) # - # source://mini_magick//lib/mini_magick/configuration.rb#119 + # source://mini_magick//lib/mini_magick/configuration.rb#115 def processor; end # @private (for backwards compatibility) # - # source://mini_magick//lib/mini_magick/configuration.rb#126 + # source://mini_magick//lib/mini_magick/configuration.rb#122 def processor=(processor); end # @private (for backwards compatibility) @@ -172,26 +173,14 @@ module MiniMagick::Configuration # Backwards compatibility # - # source://mini_magick//lib/mini_magick/configuration.rb#193 + # source://mini_magick//lib/mini_magick/configuration.rb#198 def reload_tools; end - # Instructs MiniMagick how to execute the shell commands. Available - # APIs are "open3" (default) and "posix-spawn" (requires the "posix-spawn" - # gem). - # - # @return [String] - # - # source://mini_magick//lib/mini_magick/configuration.rb#89 + # source://mini_magick//lib/mini_magick/configuration.rb#193 def shell_api; end - # Instructs MiniMagick how to execute the shell commands. Available - # APIs are "open3" (default) and "posix-spawn" (requires the "posix-spawn" - # gem). - # - # @return [String] - # - # source://mini_magick//lib/mini_magick/configuration.rb#89 - def shell_api=(_arg0); end + # source://mini_magick//lib/mini_magick/configuration.rb#188 + def shell_api=(value); end # If you don't want commands to take too long, you can set a timeout (in # seconds). @@ -245,7 +234,7 @@ module MiniMagick::Configuration # If set to `true`, it will `identify` every image that gets written (with # {MiniMagick::Image#write}), and raise `MiniMagick::Invalid` if the image - # is not valid. Useful for validating that processing was sucessful, + # is not valid. Useful for validating that processing was successful, # although it adds a bit of overhead. Defaults to `true`. # # @return [Boolean] @@ -255,7 +244,7 @@ module MiniMagick::Configuration # If set to `true`, it will `identify` every image that gets written (with # {MiniMagick::Image#write}), and raise `MiniMagick::Invalid` if the image - # is not valid. Useful for validating that processing was sucessful, + # is not valid. Useful for validating that processing was successful, # although it adds a bit of overhead. Defaults to `true`. # # @return [Boolean] @@ -263,6 +252,18 @@ module MiniMagick::Configuration # source://mini_magick//lib/mini_magick/configuration.rb#72 def validate_on_write=(_arg0); end + # If set to `false`, it will not forward warnings from ImageMagick to + # standard error. + # + # source://mini_magick//lib/mini_magick/configuration.rb#85 + def warnings; end + + # If set to `false`, it will not forward warnings from ImageMagick to + # standard error. + # + # source://mini_magick//lib/mini_magick/configuration.rb#85 + def warnings=(_arg0); end + # If set to `false`, it will not raise errors when ImageMagick returns # status code different than 0. Defaults to `true`. # @@ -282,12 +283,12 @@ module MiniMagick::Configuration class << self # @private # - # source://mini_magick//lib/mini_magick/configuration.rb#91 + # source://mini_magick//lib/mini_magick/configuration.rb#87 def extended(base); end end end -# source://mini_magick//lib/mini_magick/configuration.rb#112 +# source://mini_magick//lib/mini_magick/configuration.rb#108 MiniMagick::Configuration::CLI_DETECTION = T.let(T.unsafe(nil), Hash) # source://mini_magick//lib/mini_magick.rb#58 @@ -611,7 +612,7 @@ class MiniMagick::Image # source://mini_magick//lib/mini_magick/image.rb#596 def run_command(tool_name, *args); end - # Returns the message digest of this image as a SHA-256, hexidecimal + # Returns the message digest of this image as a SHA-256, hexadecimal # encoded string. This signature uniquely identifies the image and is # convenient for determining if an image has been modified or whether two # images are identical. @@ -803,16 +804,16 @@ class MiniMagick::Image::Info # @raise [Error] # - # source://mini_magick//lib/mini_magick/image/info.rb#165 + # source://mini_magick//lib/mini_magick/image/info.rb#167 def data; end - # source://mini_magick//lib/mini_magick/image/info.rb#132 + # source://mini_magick//lib/mini_magick/image/info.rb#134 def details; end - # source://mini_magick//lib/mini_magick/image/info.rb#95 + # source://mini_magick//lib/mini_magick/image/info.rb#97 def exif; end - # source://mini_magick//lib/mini_magick/image/info.rb#180 + # source://mini_magick//lib/mini_magick/image/info.rb#182 def identify; end # source://mini_magick//lib/mini_magick/image/info.rb#79 @@ -823,24 +824,24 @@ class MiniMagick::Image::Info # source://mini_magick//lib/mini_magick/image/info.rb#65 def parse_warnings(raw_info); end - # source://mini_magick//lib/mini_magick/image/info.rb#124 + # source://mini_magick//lib/mini_magick/image/info.rb#126 def raw(value); end - # source://mini_magick//lib/mini_magick/image/info.rb#91 + # source://mini_magick//lib/mini_magick/image/info.rb#93 def raw_exif(value); end - # source://mini_magick//lib/mini_magick/image/info.rb#83 + # source://mini_magick//lib/mini_magick/image/info.rb#85 def resolution(unit = T.unsafe(nil)); end - # source://mini_magick//lib/mini_magick/image/info.rb#128 + # source://mini_magick//lib/mini_magick/image/info.rb#130 def signature; end private - # source://mini_magick//lib/mini_magick/image/info.rb#189 + # source://mini_magick//lib/mini_magick/image/info.rb#191 def decode_comma_separated_ascii_characters(encoded_value); end - # source://mini_magick//lib/mini_magick/image/info.rb#194 + # source://mini_magick//lib/mini_magick/image/info.rb#196 def path; end end @@ -857,7 +858,7 @@ class MiniMagick::Invalid < ::StandardError; end # # source://mini_magick//lib/mini_magick/shell.rb#11 class MiniMagick::Shell - # source://mini_magick//lib/mini_magick/shell.rb#25 + # source://mini_magick//lib/mini_magick/shell.rb#26 def execute(command, options = T.unsafe(nil)); end # source://mini_magick//lib/mini_magick/shell.rb#13 @@ -865,13 +866,13 @@ class MiniMagick::Shell private - # source://mini_magick//lib/mini_magick/shell.rb#38 + # source://mini_magick//lib/mini_magick/shell.rb#39 def execute_open3(command, options = T.unsafe(nil)); end - # source://mini_magick//lib/mini_magick/shell.rb#63 + # source://mini_magick//lib/mini_magick/shell.rb#64 def execute_posix_spawn(command, options = T.unsafe(nil)); end - # source://mini_magick//lib/mini_magick/shell.rb#71 + # source://mini_magick//lib/mini_magick/shell.rb#72 def log(command, &block); end end @@ -1032,7 +1033,7 @@ class MiniMagick::Tool # Create an ImageMagick stack in the command (surround. # # @example - # MiniMagick::Tool::Convert.new do |convert| + # MiniMagick::Tool::Magick.new do |convert| # convert << "wand.gif" # convert.stack do |stack| # stack << "wand.gif" @@ -1062,7 +1063,7 @@ class MiniMagick::Tool # Adds ImageMagick's pseudo-filename `-` for standard output. # # @example - # content = MiniMagick::Tool::Convert.new do |convert| + # content = MiniMagick::Tool::Magick.new do |convert| # convert << "input.jpg" # convert.auto_orient # convert.stdout diff --git a/sorbet/rbi/gems/mini_mime@1.1.2.rbi b/sorbet/rbi/gems/mini_mime@1.1.5.rbi similarity index 82% rename from sorbet/rbi/gems/mini_mime@1.1.2.rbi rename to sorbet/rbi/gems/mini_mime@1.1.5.rbi index b12ee39d9..1551681e2 100644 --- a/sorbet/rbi/gems/mini_mime@1.1.2.rbi +++ b/sorbet/rbi/gems/mini_mime@1.1.5.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `mini_mime` gem. # Please instead update this file by running `bin/tapioca gem mini_mime`. + # source://mini_mime//lib/mini_mime/version.rb#2 module MiniMime class << self @@ -51,64 +52,66 @@ end class MiniMime::Db # @return [Db] a new instance of Db # - # source://mini_mime//lib/mini_mime.rb#154 + # source://mini_mime//lib/mini_mime.rb#173 def initialize; end - # source://mini_mime//lib/mini_mime.rb#163 + # source://mini_mime//lib/mini_mime.rb#182 def lookup_by_content_type(content_type); end - # source://mini_mime//lib/mini_mime.rb#159 + # source://mini_mime//lib/mini_mime.rb#178 def lookup_by_extension(extension); end class << self - # source://mini_mime//lib/mini_mime.rb#70 + # source://mini_mime//lib/mini_mime.rb#66 def lookup_by_content_type(content_type); end - # source://mini_mime//lib/mini_mime.rb#62 + # source://mini_mime//lib/mini_mime.rb#60 def lookup_by_extension(extension); end - # source://mini_mime//lib/mini_mime.rb#55 + # source://mini_mime//lib/mini_mime.rb#53 def lookup_by_filename(filename); end end end -# source://mini_mime//lib/mini_mime.rb#77 +# source://mini_mime//lib/mini_mime.rb#71 class MiniMime::Db::Cache # @return [Cache] a new instance of Cache # - # source://mini_mime//lib/mini_mime.rb#78 + # source://mini_mime//lib/mini_mime.rb#72 def initialize(size); end - # source://mini_mime//lib/mini_mime.rb#83 + # source://mini_mime//lib/mini_mime.rb#77 def []=(key, val); end - # source://mini_mime//lib/mini_mime.rb#89 + # source://mini_mime//lib/mini_mime.rb#83 def fetch(key, &blk); end end -# source://mini_mime//lib/mini_mime.rb#53 -MiniMime::Db::LOCK = T.let(T.unsafe(nil), Thread::Mutex) +# For Windows support +# +# source://mini_mime//lib/mini_mime.rb#89 +MiniMime::Db::PReadFile = File -# source://mini_mime//lib/mini_mime.rb#94 +# source://mini_mime//lib/mini_mime.rb#114 class MiniMime::Db::RandomAccessDb # @return [RandomAccessDb] a new instance of RandomAccessDb # - # source://mini_mime//lib/mini_mime.rb#97 + # source://mini_mime//lib/mini_mime.rb#117 def initialize(path, sort_order); end - # source://mini_mime//lib/mini_mime.rb#111 + # source://mini_mime//lib/mini_mime.rb#131 def lookup(val); end # lifted from marcandre/backports # - # source://mini_mime//lib/mini_mime.rb#127 + # source://mini_mime//lib/mini_mime.rb#147 def lookup_uncached(val); end - # source://mini_mime//lib/mini_mime.rb#148 + # source://mini_mime//lib/mini_mime.rb#168 def resolve(row); end end -# source://mini_mime//lib/mini_mime.rb#95 +# source://mini_mime//lib/mini_mime.rb#115 MiniMime::Db::RandomAccessDb::MAX_CACHED = T.let(T.unsafe(nil), Integer) # source://mini_mime//lib/mini_mime.rb#28 diff --git a/sorbet/rbi/gems/mini_racer@0.8.0.rbi b/sorbet/rbi/gems/mini_racer@0.14.1.rbi similarity index 72% rename from sorbet/rbi/gems/mini_racer@0.8.0.rbi rename to sorbet/rbi/gems/mini_racer@0.14.1.rbi index 0b37ca666..c94624b0c 100644 --- a/sorbet/rbi/gems/mini_racer@0.8.0.rbi +++ b/sorbet/rbi/gems/mini_racer@0.14.1.rbi @@ -4,83 +4,84 @@ # This is an autogenerated file for types exported from the `mini_racer` gem. # Please instead update this file by running `bin/tapioca gem mini_racer`. + # source://mini_racer//lib/mini_racer/version.rb#3 module MiniRacer; end # eval is defined in the C class # -# source://mini_racer//lib/mini_racer.rb#116 +# source://mini_racer//lib/mini_racer.rb#125 class MiniRacer::Context # @return [Context] a new instance of Context # - # source://mini_racer//lib/mini_racer.rb#151 + # source://mini_racer//lib/mini_racer.rb#160 def initialize(max_memory: T.unsafe(nil), timeout: T.unsafe(nil), isolate: T.unsafe(nil), ensure_gc_after_idle: T.unsafe(nil), snapshot: T.unsafe(nil), marshal_stack_depth: T.unsafe(nil)); end # @raise [ContextDisposedError] # - # source://mini_racer//lib/mini_racer.rb#261 + # source://mini_racer//lib/mini_racer.rb#270 def attach(name, callback); end - # source://mini_racer//lib/mini_racer.rb#236 + # source://mini_racer//lib/mini_racer.rb#245 def call(function_name, *arguments); end - # source://mini_racer//lib/mini_racer.rb#250 + # source://mini_racer//lib/mini_racer.rb#259 def dispose; end def dispose_unsafe; end - # source://mini_racer//lib/mini_racer.rb#219 + # source://mini_racer//lib/mini_racer.rb#228 def eval(str, options = T.unsafe(nil)); end def heap_stats; end - # source://mini_racer//lib/mini_racer.rb#186 + # source://mini_racer//lib/mini_racer.rb#195 def isolate; end - # source://mini_racer//lib/mini_racer.rb#192 + # source://mini_racer//lib/mini_racer.rb#201 def load(filename); end def stop; end - # source://mini_racer//lib/mini_racer.rb#197 + # source://mini_racer//lib/mini_racer.rb#206 def write_heap_snapshot(file_or_io); end def write_heap_snapshot_unsafe(_arg0); end private - # source://mini_racer//lib/mini_racer.rb#402 + # source://mini_racer//lib/mini_racer.rb#411 def assert_numeric_or_nil(option_name, object, min_value:, max_value: T.unsafe(nil)); end - # source://mini_racer//lib/mini_racer.rb#416 + # source://mini_racer//lib/mini_racer.rb#425 def assert_option_is_nil_or_a(option_name, object, klass); end def call_unsafe(*_arg0); end - # source://mini_racer//lib/mini_racer.rb#388 + # source://mini_racer//lib/mini_racer.rb#397 def check_init_options!(isolate:, snapshot:, max_memory:, marshal_stack_depth:, ensure_gc_after_idle:, timeout:); end def create_isolate_value; end - # source://mini_racer//lib/mini_racer.rb#306 + # source://mini_racer//lib/mini_racer.rb#315 def ensure_gc_thread; end def eval_unsafe(_arg0, _arg1); end def init_unsafe(_arg0, _arg1); end def isolate_mutex; end - # source://mini_racer//lib/mini_racer.rb#338 + # source://mini_racer//lib/mini_racer.rb#347 def stop_attached; end - # source://mini_racer//lib/mini_racer.rb#347 + # source://mini_racer//lib/mini_racer.rb#356 def timeout(&blk); end end -# source://mini_racer//lib/mini_racer.rb#118 +# source://mini_racer//lib/mini_racer.rb#127 class MiniRacer::Context::ExternalFunction # @return [ExternalFunction] a new instance of ExternalFunction # - # source://mini_racer//lib/mini_racer.rb#119 + # source://mini_racer//lib/mini_racer.rb#128 def initialize(name, callback, parent); end private @@ -88,33 +89,33 @@ class MiniRacer::Context::ExternalFunction def notify_v8; end end -# source://mini_racer//lib/mini_racer.rb#28 +# source://mini_racer//lib/mini_racer.rb#37 class MiniRacer::ContextDisposedError < ::MiniRacer::Error; end -# source://mini_racer//lib/mini_racer.rb#26 +# source://mini_racer//lib/mini_racer.rb#35 class MiniRacer::Error < ::StandardError; end -# source://mini_racer//lib/mini_racer.rb#32 +# source://mini_racer//lib/mini_racer.rb#41 class MiniRacer::EvalError < ::MiniRacer::Error; end -# source://mini_racer//lib/mini_racer.rb#37 +# source://mini_racer//lib/mini_racer.rb#46 class MiniRacer::FailedV8Conversion # @return [FailedV8Conversion] a new instance of FailedV8Conversion # - # source://mini_racer//lib/mini_racer.rb#39 + # source://mini_racer//lib/mini_racer.rb#48 def initialize(info); end # Returns the value of attribute info. # - # source://mini_racer//lib/mini_racer.rb#38 + # source://mini_racer//lib/mini_racer.rb#47 def info; end end -# source://mini_racer//lib/mini_racer.rb#74 +# source://mini_racer//lib/mini_racer.rb#83 class MiniRacer::Isolate # @return [Isolate] a new instance of Isolate # - # source://mini_racer//lib/mini_racer.rb#75 + # source://mini_racer//lib/mini_racer.rb#84 def initialize(snapshot = T.unsafe(nil)); end def idle_notification(_arg0); end @@ -128,9 +129,9 @@ end # helper class returned when we have a JavaScript function # -# source://mini_racer//lib/mini_racer.rb#68 +# source://mini_racer//lib/mini_racer.rb#77 class MiniRacer::JavaScriptFunction - # source://mini_racer//lib/mini_racer.rb#69 + # source://mini_racer//lib/mini_racer.rb#78 def to_s; end end @@ -143,66 +144,66 @@ module MiniRacer::Loader end end -# source://mini_racer//lib/mini_racer.rb#23 +# source://mini_racer//lib/mini_racer.rb#32 MiniRacer::MARSHAL_STACKDEPTH_DEFAULT = T.let(T.unsafe(nil), Integer) -# source://mini_racer//lib/mini_racer.rb#24 +# source://mini_racer//lib/mini_racer.rb#33 MiniRacer::MARSHAL_STACKDEPTH_MAX_VALUE = T.let(T.unsafe(nil), Integer) -# source://mini_racer//lib/mini_racer.rb#33 +# source://mini_racer//lib/mini_racer.rb#42 class MiniRacer::ParseError < ::MiniRacer::EvalError; end -# source://mini_racer//lib/mini_racer.rb#85 +# source://mini_racer//lib/mini_racer.rb#94 class MiniRacer::Platform class << self # @raise [TypeError] def set_flag_as_str!(_arg0); end - # source://mini_racer//lib/mini_racer.rb#87 + # source://mini_racer//lib/mini_racer.rb#96 def set_flags!(*args, **kwargs); end private # normalize flags to strings, and adds leading dashes if needed # - # source://mini_racer//lib/mini_racer.rb#101 + # source://mini_racer//lib/mini_racer.rb#110 def flag_to_string(flag); end - # source://mini_racer//lib/mini_racer.rb#96 + # source://mini_racer//lib/mini_racer.rb#105 def flags_to_strings(flags); end end end -# source://mini_racer//lib/mini_racer.rb#30 +# source://mini_racer//lib/mini_racer.rb#39 class MiniRacer::PlatformAlreadyInitialized < ::MiniRacer::Error; end -# source://mini_racer//lib/mini_racer.rb#44 +# source://mini_racer//lib/mini_racer.rb#53 class MiniRacer::RuntimeError < ::MiniRacer::EvalError # @return [RuntimeError] a new instance of RuntimeError # - # source://mini_racer//lib/mini_racer.rb#45 + # source://mini_racer//lib/mini_racer.rb#54 def initialize(message); end - # source://mini_racer//lib/mini_racer.rb#56 + # source://mini_racer//lib/mini_racer.rb#65 def backtrace; end end -# source://mini_racer//lib/mini_racer.rb#34 +# source://mini_racer//lib/mini_racer.rb#43 class MiniRacer::ScriptTerminatedError < ::MiniRacer::EvalError; end # `size` and `warmup!` public methods are defined in the C class # -# source://mini_racer//lib/mini_racer.rb#424 +# source://mini_racer//lib/mini_racer.rb#433 class MiniRacer::Snapshot # @return [Snapshot] a new instance of Snapshot # - # source://mini_racer//lib/mini_racer.rb#425 + # source://mini_racer//lib/mini_racer.rb#434 def initialize(str = T.unsafe(nil)); end def dump; end def size; end - # source://mini_racer//lib/mini_racer.rb#440 + # source://mini_racer//lib/mini_racer.rb#449 def warmup!(src); end # @raise [TypeError] @@ -214,10 +215,10 @@ class MiniRacer::Snapshot def load(_arg0); end end -# source://mini_racer//lib/mini_racer.rb#29 +# source://mini_racer//lib/mini_racer.rb#38 class MiniRacer::SnapshotError < ::MiniRacer::Error; end -# source://mini_racer//lib/mini_racer.rb#35 +# source://mini_racer//lib/mini_racer.rb#44 class MiniRacer::V8OutOfMemoryError < ::MiniRacer::EvalError; end # source://mini_racer//lib/mini_racer/version.rb#4 diff --git a/sorbet/rbi/gems/minitest@5.18.1.rbi b/sorbet/rbi/gems/minitest@5.25.0.rbi similarity index 70% rename from sorbet/rbi/gems/minitest@5.18.1.rbi rename to sorbet/rbi/gems/minitest@5.25.0.rbi index f68a238d1..9501420c7 100644 --- a/sorbet/rbi/gems/minitest@5.18.1.rbi +++ b/sorbet/rbi/gems/minitest@5.25.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `minitest` gem. # Please instead update this file by running `bin/tapioca gem minitest`. + # :include: README.rdoc # # source://minitest//lib/minitest/parallel.rb#1 @@ -12,7 +13,7 @@ module Minitest # Internal run method. Responsible for telling all Runnable # sub-classes to run. # - # source://minitest//lib/minitest.rb#173 + # source://minitest//lib/minitest.rb#322 def __run(reporter, options); end # A simple hook allowing you to run a block of code after everything @@ -20,12 +21,18 @@ module Minitest # # Minitest.after_run { p $debugging_info } # - # source://minitest//lib/minitest.rb#94 + # source://minitest//lib/minitest.rb#96 def after_run(&block); end + # source://minitest//lib/minitest.rb#19 + def allow_fork; end + + # source://minitest//lib/minitest.rb#19 + def allow_fork=(_arg0); end + # Registers Minitest to run at process exit # - # source://minitest//lib/minitest.rb#66 + # source://minitest//lib/minitest.rb#69 def autorun; end # source://minitest//lib/minitest.rb#19 @@ -37,16 +44,19 @@ module Minitest # source://minitest//lib/minitest.rb#18 def cattr_accessor(name); end - # source://minitest//lib/minitest.rb#1073 + # source://minitest//lib/minitest.rb#1215 def clock_time; end + # source://minitest//lib/minitest.rb#302 + def empty_run!(options); end + # source://minitest//lib/minitest.rb#19 def extensions; end # source://minitest//lib/minitest.rb#19 def extensions=(_arg0); end - # source://minitest//lib/minitest.rb#264 + # source://minitest//lib/minitest.rb#335 def filter_backtrace(bt); end # source://minitest//lib/minitest.rb#19 @@ -55,10 +65,10 @@ module Minitest # source://minitest//lib/minitest.rb#19 def info_signal=(_arg0); end - # source://minitest//lib/minitest.rb#98 + # source://minitest//lib/minitest.rb#124 def init_plugins(options); end - # source://minitest//lib/minitest.rb#105 + # source://minitest//lib/minitest.rb#108 def load_plugins; end # source://minitest//lib/minitest.rb#19 @@ -67,9 +77,14 @@ module Minitest # source://minitest//lib/minitest.rb#19 def parallel_executor=(_arg0); end - # source://minitest//lib/minitest.rb#186 + # source://minitest//lib/minitest.rb#142 def process_args(args = T.unsafe(nil)); end + # Register a plugin to be used. Does NOT require / load it. + # + # source://minitest//lib/minitest.rb#103 + def register_plugin(name_or_mod); end + # source://minitest//lib/minitest.rb#19 def reporter; end @@ -84,18 +99,21 @@ module Minitest # # Minitest.autorun # Minitest.run(args) + # Minitest.load_plugins + # Minitest.process_args + # Minitest.init_plugins # Minitest.__run(reporter, options) # Runnable.runnables.each - # runnable.run(reporter, options) + # runnable_klass.run(reporter, options) # self.runnable_methods.each # self.run_one_method(self, runnable_method, reporter) # Minitest.run_one_method(klass, runnable_method) # klass.new(runnable_method).run # - # source://minitest//lib/minitest.rb#140 + # source://minitest//lib/minitest.rb#268 def run(args = T.unsafe(nil)); end - # source://minitest//lib/minitest.rb#1064 + # source://minitest//lib/minitest.rb#1206 def run_one_method(klass, method_name); end # source://minitest//lib/minitest.rb#19 @@ -109,27 +127,24 @@ end # Defines the API for Reporters. Subclass this and override whatever # you want. Go nuts. # -# source://minitest//lib/minitest.rb#592 +# source://minitest//lib/minitest.rb#686 class Minitest::AbstractReporter - include ::Mutex_m - - # source://mutex_m/0.1.2/mutex_m.rb#93 - def lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#83 - def locked?; end + # @return [AbstractReporter] a new instance of AbstractReporter + # + # source://minitest//lib/minitest.rb#688 + def initialize; end # Did this run pass? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#626 + # source://minitest//lib/minitest.rb#723 def passed?; end # About to start running a test. This allows a reporter to show # that it is starting or that we are in the middle of a test run. # - # source://minitest//lib/minitest.rb#605 + # source://minitest//lib/minitest.rb#702 def prerecord(klass, name); end # Output and record the result of the test. Call @@ -137,48 +152,45 @@ class Minitest::AbstractReporter # result character string. Stores the result of the run if the run # did not pass. # - # source://minitest//lib/minitest.rb#614 + # source://minitest//lib/minitest.rb#711 def record(result); end # Outputs the summary of the run. # - # source://minitest//lib/minitest.rb#620 + # source://minitest//lib/minitest.rb#717 def report; end # Starts reporting on the run. # - # source://minitest//lib/minitest.rb#598 + # source://minitest//lib/minitest.rb#695 def start; end - # source://mutex_m/0.1.2/mutex_m.rb#78 + # source://minitest//lib/minitest.rb#727 def synchronize(&block); end - - # source://mutex_m/0.1.2/mutex_m.rb#88 - def try_lock; end - - # source://mutex_m/0.1.2/mutex_m.rb#98 - def unlock; end end # Represents run failures. # -# source://minitest//lib/minitest.rb#909 +# source://minitest//lib/minitest.rb#1019 class Minitest::Assertion < ::Exception - # source://minitest//lib/minitest.rb#910 + # source://minitest//lib/minitest.rb#1022 def error; end # Where was this run before an assertion was raised? # - # source://minitest//lib/minitest.rb#917 + # source://minitest//lib/minitest.rb#1029 def location; end - # source://minitest//lib/minitest.rb#926 + # source://minitest//lib/minitest.rb#1037 def result_code; end - # source://minitest//lib/minitest.rb#930 + # source://minitest//lib/minitest.rb#1041 def result_label; end end +# source://minitest//lib/minitest.rb#1020 +Minitest::Assertion::RE = T.let(T.unsafe(nil), Regexp) + # Minitest Assertions. All assertion methods accept a +msg+ which is # printed if the assertion fails. # @@ -188,19 +200,22 @@ end # provided by the thing including Assertions. See Minitest::Runnable # for an example. # -# source://minitest//lib/minitest/assertions.rb#18 +# source://minitest//lib/minitest/assertions.rb#16 module Minitest::Assertions - # source://minitest//lib/minitest/assertions.rb#188 + # source://minitest//lib/minitest/assertions.rb#181 def _synchronize; end + # source://minitest//lib/minitest/assertions.rb#194 + def _where; end + # Fails unless +test+ is truthy. # - # source://minitest//lib/minitest/assertions.rb#178 + # source://minitest//lib/minitest/assertions.rb#171 def assert(test, msg = T.unsafe(nil)); end # Fails unless +obj+ is empty. # - # source://minitest//lib/minitest/assertions.rb#195 + # source://minitest//lib/minitest/assertions.rb#188 def assert_empty(obj, msg = T.unsafe(nil)); end # Fails unless exp == act printing the difference between @@ -215,7 +230,7 @@ module Minitest::Assertions # # See also: Minitest::Assertions.diff # - # source://minitest//lib/minitest/assertions.rb#216 + # source://minitest//lib/minitest/assertions.rb#214 def assert_equal(exp, act, msg = T.unsafe(nil)); end # For comparing Floats. Fails unless +exp+ and +act+ are within +delta+ @@ -223,45 +238,45 @@ module Minitest::Assertions # # assert_in_delta Math::PI, (22.0 / 7.0), 0.01 # - # source://minitest//lib/minitest/assertions.rb#240 + # source://minitest//lib/minitest/assertions.rb#235 def assert_in_delta(exp, act, delta = T.unsafe(nil), msg = T.unsafe(nil)); end # For comparing Floats. Fails unless +exp+ and +act+ have a relative # error less than +epsilon+. # - # source://minitest//lib/minitest/assertions.rb#252 + # source://minitest//lib/minitest/assertions.rb#247 def assert_in_epsilon(exp, act, epsilon = T.unsafe(nil), msg = T.unsafe(nil)); end # Fails unless +collection+ includes +obj+. # - # source://minitest//lib/minitest/assertions.rb#259 + # source://minitest//lib/minitest/assertions.rb#254 def assert_includes(collection, obj, msg = T.unsafe(nil)); end # Fails unless +obj+ is an instance of +cls+. # - # source://minitest//lib/minitest/assertions.rb#270 + # source://minitest//lib/minitest/assertions.rb#265 def assert_instance_of(cls, obj, msg = T.unsafe(nil)); end # Fails unless +obj+ is a kind of +cls+. # - # source://minitest//lib/minitest/assertions.rb#281 + # source://minitest//lib/minitest/assertions.rb#276 def assert_kind_of(cls, obj, msg = T.unsafe(nil)); end # Fails unless +matcher+ =~ +obj+. # - # source://minitest//lib/minitest/assertions.rb#291 + # source://minitest//lib/minitest/assertions.rb#287 def assert_match(matcher, obj, msg = T.unsafe(nil)); end # Fails unless +obj+ is nil # - # source://minitest//lib/minitest/assertions.rb#303 + # source://minitest//lib/minitest/assertions.rb#299 def assert_nil(obj, msg = T.unsafe(nil)); end # For testing with binary operators. Eg: # # assert_operator 5, :<=, 4 # - # source://minitest//lib/minitest/assertions.rb#313 + # source://minitest//lib/minitest/assertions.rb#309 def assert_operator(o1, op, o2 = T.unsafe(nil), msg = T.unsafe(nil)); end # Fails if stdout or stderr do not output the expected results. @@ -275,12 +290,12 @@ module Minitest::Assertions # # See also: #assert_silent # - # source://minitest//lib/minitest/assertions.rb#331 + # source://minitest//lib/minitest/assertions.rb#327 def assert_output(stdout = T.unsafe(nil), stderr = T.unsafe(nil)); end # Fails unless +path+ exists. # - # source://minitest//lib/minitest/assertions.rb#355 + # source://minitest//lib/minitest/assertions.rb#351 def assert_path_exists(path, msg = T.unsafe(nil)); end # For testing with pattern matching (only supported with Ruby 3.0 and later) @@ -298,7 +313,7 @@ module Minitest::Assertions # # @raise [NotImplementedError] # - # source://minitest//lib/minitest/assertions.rb#374 + # source://minitest//lib/minitest/assertions.rb#370 def assert_pattern; end # For testing with predicates. Eg: @@ -309,7 +324,7 @@ module Minitest::Assertions # # str.must_be :empty? # - # source://minitest//lib/minitest/assertions.rb#395 + # source://minitest//lib/minitest/assertions.rb#391 def assert_predicate(o1, op, msg = T.unsafe(nil)); end # Fails unless the block raises one of +exp+. Returns the @@ -333,36 +348,37 @@ module Minitest::Assertions # # assert_equal 'This is really bad', error.message # - # source://minitest//lib/minitest/assertions.rb#422 + # source://minitest//lib/minitest/assertions.rb#418 def assert_raises(*exp); end # Fails unless +obj+ responds to +meth+. + # include_all defaults to false to match Object#respond_to? # - # source://minitest//lib/minitest/assertions.rb#453 - def assert_respond_to(obj, meth, msg = T.unsafe(nil)); end + # source://minitest//lib/minitest/assertions.rb#450 + def assert_respond_to(obj, meth, msg = T.unsafe(nil), include_all: T.unsafe(nil)); end # Fails unless +exp+ and +act+ are #equal? # - # source://minitest//lib/minitest/assertions.rb#463 + # source://minitest//lib/minitest/assertions.rb#460 def assert_same(exp, act, msg = T.unsafe(nil)); end # +send_ary+ is a receiver, message and arguments. # # Fails unless the call returns a true value # - # source://minitest//lib/minitest/assertions.rb#476 + # source://minitest//lib/minitest/assertions.rb#473 def assert_send(send_ary, m = T.unsafe(nil)); end # Fails if the block outputs anything to stderr or stdout. # # See also: #assert_output # - # source://minitest//lib/minitest/assertions.rb#492 + # source://minitest//lib/minitest/assertions.rb#488 def assert_silent; end # Fails unless the block throws +sym+ # - # source://minitest//lib/minitest/assertions.rb#501 + # source://minitest//lib/minitest/assertions.rb#497 def assert_throws(sym, msg = T.unsafe(nil)); end # Captures $stdout and $stderr into strings: @@ -379,7 +395,7 @@ module Minitest::Assertions # capture IO for subprocesses. Use #capture_subprocess_io for # that. # - # source://minitest//lib/minitest/assertions.rb#542 + # source://minitest//lib/minitest/assertions.rb#538 def capture_io; end # Captures $stdout and $stderr into strings, using Tempfile to @@ -396,7 +412,7 @@ module Minitest::Assertions # NOTE: This method is approximately 10x slower than #capture_io so # only use it when you need to test the output of a subprocess. # - # source://minitest//lib/minitest/assertions.rb#575 + # source://minitest//lib/minitest/assertions.rb#571 def capture_subprocess_io; end # Returns a diff between +exp+ and +act+. If there is no known @@ -406,29 +422,29 @@ module Minitest::Assertions # # See +things_to_diff+ for more info. # - # source://minitest//lib/minitest/assertions.rb#59 + # source://minitest//lib/minitest/assertions.rb#57 def diff(exp, act); end # Returns details for exception +e+ # - # source://minitest//lib/minitest/assertions.rb#607 + # source://minitest//lib/minitest/assertions.rb#603 def exception_details(e, msg); end # Fails after a given date (in the local time zone). This allows # you to put time-bombs in your tests if you need to keep # something around until a later date lest you forget about it. # - # source://minitest//lib/minitest/assertions.rb#623 + # source://minitest//lib/minitest/assertions.rb#619 def fail_after(y, m, d, msg); end # Fails with +msg+. # - # source://minitest//lib/minitest/assertions.rb#630 + # source://minitest//lib/minitest/assertions.rb#626 def flunk(msg = T.unsafe(nil)); end # Returns a proc that will output +msg+ along with the default message. # - # source://minitest//lib/minitest/assertions.rb#638 + # source://minitest//lib/minitest/assertions.rb#634 def message(msg = T.unsafe(nil), ending = T.unsafe(nil), &default); end # This returns a human-readable version of +obj+. By default @@ -437,7 +453,7 @@ module Minitest::Assertions # # See Minitest::Test.make_my_diffs_pretty! # - # source://minitest//lib/minitest/assertions.rb#129 + # source://minitest//lib/minitest/assertions.rb#127 def mu_pp(obj); end # This returns a diff-able more human-readable version of +obj+. @@ -445,67 +461,67 @@ module Minitest::Assertions # newlines and makes hex-values (like object_ids) generic. This # uses mu_pp to do the first pass and then cleans it up. # - # source://minitest//lib/minitest/assertions.rb#152 + # source://minitest//lib/minitest/assertions.rb#145 def mu_pp_for_diff(obj); end # used for counting assertions # - # source://minitest//lib/minitest/assertions.rb#649 + # source://minitest//lib/minitest/assertions.rb#645 def pass(_msg = T.unsafe(nil)); end # Fails if +test+ is truthy. # - # source://minitest//lib/minitest/assertions.rb#656 + # source://minitest//lib/minitest/assertions.rb#652 def refute(test, msg = T.unsafe(nil)); end # Fails if +obj+ is empty. # - # source://minitest//lib/minitest/assertions.rb#664 + # source://minitest//lib/minitest/assertions.rb#660 def refute_empty(obj, msg = T.unsafe(nil)); end # Fails if exp == act. # # For floats use refute_in_delta. # - # source://minitest//lib/minitest/assertions.rb#675 + # source://minitest//lib/minitest/assertions.rb#671 def refute_equal(exp, act, msg = T.unsafe(nil)); end # For comparing Floats. Fails if +exp+ is within +delta+ of +act+. # # refute_in_delta Math::PI, (22.0 / 7.0) # - # source://minitest//lib/minitest/assertions.rb#687 + # source://minitest//lib/minitest/assertions.rb#683 def refute_in_delta(exp, act, delta = T.unsafe(nil), msg = T.unsafe(nil)); end # For comparing Floats. Fails if +exp+ and +act+ have a relative error # less than +epsilon+. # - # source://minitest//lib/minitest/assertions.rb#699 + # source://minitest//lib/minitest/assertions.rb#695 def refute_in_epsilon(a, b, epsilon = T.unsafe(nil), msg = T.unsafe(nil)); end # Fails if +collection+ includes +obj+. # - # source://minitest//lib/minitest/assertions.rb#706 + # source://minitest//lib/minitest/assertions.rb#702 def refute_includes(collection, obj, msg = T.unsafe(nil)); end # Fails if +obj+ is an instance of +cls+. # - # source://minitest//lib/minitest/assertions.rb#717 + # source://minitest//lib/minitest/assertions.rb#713 def refute_instance_of(cls, obj, msg = T.unsafe(nil)); end # Fails if +obj+ is a kind of +cls+. # - # source://minitest//lib/minitest/assertions.rb#727 + # source://minitest//lib/minitest/assertions.rb#723 def refute_kind_of(cls, obj, msg = T.unsafe(nil)); end # Fails if +matcher+ =~ +obj+. # - # source://minitest//lib/minitest/assertions.rb#735 + # source://minitest//lib/minitest/assertions.rb#731 def refute_match(matcher, obj, msg = T.unsafe(nil)); end # Fails if +obj+ is nil. # - # source://minitest//lib/minitest/assertions.rb#745 + # source://minitest//lib/minitest/assertions.rb#741 def refute_nil(obj, msg = T.unsafe(nil)); end # Fails if +o1+ is not +op+ +o2+. Eg: @@ -513,12 +529,12 @@ module Minitest::Assertions # refute_operator 1, :>, 2 #=> pass # refute_operator 1, :<, 2 #=> fail # - # source://minitest//lib/minitest/assertions.rb#780 + # source://minitest//lib/minitest/assertions.rb#776 def refute_operator(o1, op, o2 = T.unsafe(nil), msg = T.unsafe(nil)); end # Fails if +path+ exists. # - # source://minitest//lib/minitest/assertions.rb#789 + # source://minitest//lib/minitest/assertions.rb#785 def refute_path_exists(path, msg = T.unsafe(nil)); end # For testing with pattern matching (only supported with Ruby 3.0 and later) @@ -534,7 +550,7 @@ module Minitest::Assertions # # @raise [NotImplementedError] # - # source://minitest//lib/minitest/assertions.rb#762 + # source://minitest//lib/minitest/assertions.rb#758 def refute_pattern; end # For testing with predicates. @@ -545,17 +561,18 @@ module Minitest::Assertions # # str.wont_be :empty? # - # source://minitest//lib/minitest/assertions.rb#803 + # source://minitest//lib/minitest/assertions.rb#799 def refute_predicate(o1, op, msg = T.unsafe(nil)); end # Fails if +obj+ responds to the message +meth+. + # include_all defaults to false to match Object#respond_to? # - # source://minitest//lib/minitest/assertions.rb#811 - def refute_respond_to(obj, meth, msg = T.unsafe(nil)); end + # source://minitest//lib/minitest/assertions.rb#808 + def refute_respond_to(obj, meth, msg = T.unsafe(nil), include_all: T.unsafe(nil)); end # Fails if +exp+ is the same (by object identity) as +act+. # - # source://minitest//lib/minitest/assertions.rb#820 + # source://minitest//lib/minitest/assertions.rb#817 def refute_same(exp, act, msg = T.unsafe(nil)); end # Skips the current run. If run in verbose-mode, the skipped run @@ -564,22 +581,22 @@ module Minitest::Assertions # # @raise [Minitest::Skip] # - # source://minitest//lib/minitest/assertions.rb#833 - def skip(msg = T.unsafe(nil), bt = T.unsafe(nil)); end + # source://minitest//lib/minitest/assertions.rb#830 + def skip(msg = T.unsafe(nil), _ignored = T.unsafe(nil)); end # Skips the current run until a given date (in the local time # zone). This allows you to put some fixes on hold until a later # date, but still holds you accountable and prevents you from # forgetting it. # - # source://minitest//lib/minitest/assertions.rb#845 + # source://minitest//lib/minitest/assertions.rb#842 def skip_until(y, m, d, msg); end # Was this testcase skipped? Meant for #teardown. # # @return [Boolean] # - # source://minitest//lib/minitest/assertions.rb#854 + # source://minitest//lib/minitest/assertions.rb#851 def skipped?; end # Returns things to diff [expect, butwas], or [nil, nil] if nothing to diff. @@ -591,90 +608,116 @@ module Minitest::Assertions # 3. or: Strings are equal to each other (but maybe different encodings?). # 4. and: we found a diff executable. # - # source://minitest//lib/minitest/assertions.rb#104 + # source://minitest//lib/minitest/assertions.rb#102 def things_to_diff(exp, act); end class << self # Returns the diff command to use in #diff. Tries to intelligently # figure out what diff to use. # - # source://minitest//lib/minitest/assertions.rb#29 + # source://minitest//lib/minitest/assertions.rb#27 def diff; end # Set the diff command to use in #diff. # - # source://minitest//lib/minitest/assertions.rb#47 + # source://minitest//lib/minitest/assertions.rb#45 def diff=(o); end end end -# source://minitest//lib/minitest/assertions.rb#201 +# source://minitest//lib/minitest/assertions.rb#199 Minitest::Assertions::E = T.let(T.unsafe(nil), String) -# source://minitest//lib/minitest/assertions.rb#19 +# source://minitest//lib/minitest/assertions.rb#17 Minitest::Assertions::UNDEFINED = T.let(T.unsafe(nil), Object) # The standard backtrace filter for minitest. # # See Minitest.backtrace_filter=. # -# source://minitest//lib/minitest.rb#1041 +# source://minitest//lib/minitest.rb#1174 class Minitest::BacktraceFilter + # @return [BacktraceFilter] a new instance of BacktraceFilter + # + # source://minitest//lib/minitest.rb#1183 + def initialize(regexp = T.unsafe(nil)); end + # Filter +bt+ to something useful. Returns the whole thing if # $DEBUG (ruby) or $MT_DEBUG (env). # - # source://minitest//lib/minitest.rb#1049 + # source://minitest//lib/minitest.rb#1191 def filter(bt); end + + # The regular expression to use to filter backtraces. Defaults to +MT_RE+. + # + # source://minitest//lib/minitest.rb#1181 + def regexp; end + + # The regular expression to use to filter backtraces. Defaults to +MT_RE+. + # + # source://minitest//lib/minitest.rb#1181 + def regexp=(_arg0); end end -# source://minitest//lib/minitest.rb#1043 +# source://minitest//lib/minitest.rb#1176 Minitest::BacktraceFilter::MT_RE = T.let(T.unsafe(nil), Regexp) # Dispatch to multiple reporters as one. # -# source://minitest//lib/minitest.rb#858 +# source://minitest//lib/minitest.rb#968 class Minitest::CompositeReporter < ::Minitest::AbstractReporter # @return [CompositeReporter] a new instance of CompositeReporter # - # source://minitest//lib/minitest.rb#864 + # source://minitest//lib/minitest.rb#974 def initialize(*reporters); end # Add another reporter to the mix. # - # source://minitest//lib/minitest.rb#876 + # source://minitest//lib/minitest.rb#986 def <<(reporter); end - # source://minitest//lib/minitest.rb#869 + # source://minitest//lib/minitest.rb#979 def io; end # @return [Boolean] # - # source://minitest//lib/minitest.rb#880 + # source://minitest//lib/minitest.rb#990 def passed?; end - # source://minitest//lib/minitest.rb#888 + # source://minitest//lib/minitest.rb#998 def prerecord(klass, name); end - # source://minitest//lib/minitest.rb#895 + # source://minitest//lib/minitest.rb#1005 def record(result); end - # source://minitest//lib/minitest.rb#901 + # source://minitest//lib/minitest.rb#1011 def report; end # The list of reporters to dispatch to. # - # source://minitest//lib/minitest.rb#862 + # source://minitest//lib/minitest.rb#972 def reporters; end # The list of reporters to dispatch to. # - # source://minitest//lib/minitest.rb#862 + # source://minitest//lib/minitest.rb#972 def reporters=(_arg0); end - # source://minitest//lib/minitest.rb#884 + # source://minitest//lib/minitest.rb#994 def start; end end +# Compresses backtraces. +# +# source://minitest//lib/minitest/compress.rb#5 +module Minitest::Compress + # Takes a backtrace (array of strings) and compresses repeating + # cycles in it to make it more readable. + # + # source://minitest//lib/minitest/compress.rb#11 + def compress(orig); end +end + # Provides a simple set of guards that you can use in your tests # to skip execution if it is not applicable. These methods are # mixed into Test as both instance and class methods so you @@ -689,48 +732,48 @@ end # # ... lots of test methods ... # end # -# source://minitest//lib/minitest.rb#985 +# source://minitest//lib/minitest.rb#1118 module Minitest::Guard # Is this running on jruby? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#990 + # source://minitest//lib/minitest.rb#1123 def jruby?(platform = T.unsafe(nil)); end # Is this running on maglev? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#997 + # source://minitest//lib/minitest.rb#1130 def maglev?(platform = T.unsafe(nil)); end # Is this running on mri? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#1007 + # source://minitest//lib/minitest.rb#1140 def mri?(platform = T.unsafe(nil)); end # Is this running on macOS? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#1014 + # source://minitest//lib/minitest.rb#1147 def osx?(platform = T.unsafe(nil)); end # Is this running on rubinius? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#1021 + # source://minitest//lib/minitest.rb#1154 def rubinius?(platform = T.unsafe(nil)); end # Is this running on windows? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#1031 + # source://minitest//lib/minitest.rb#1164 def windows?(platform = T.unsafe(nil)); end end @@ -793,36 +836,36 @@ end # plugin, pull this out of the composite and replace it with your # own. # -# source://minitest//lib/minitest.rb#657 +# source://minitest//lib/minitest.rb#758 class Minitest::ProgressReporter < ::Minitest::Reporter - # source://minitest//lib/minitest.rb#658 + # source://minitest//lib/minitest.rb#759 def prerecord(klass, name); end - # source://minitest//lib/minitest.rb#665 + # source://minitest//lib/minitest.rb#766 def record(result); end end # Shared code for anything that can get passed to a Reporter. See # Minitest::Test & Minitest::Result. # -# source://minitest//lib/minitest.rb#489 +# source://minitest//lib/minitest.rb#580 module Minitest::Reportable # @raise [NotImplementedError] # - # source://minitest//lib/minitest.rb#509 + # source://minitest//lib/minitest.rb#602 def class_name; end # Did this run error? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#530 + # source://minitest//lib/minitest.rb#623 def error?; end # The location identifier of this test. Depends on a method # existing called class_name. # - # source://minitest//lib/minitest.rb#504 + # source://minitest//lib/minitest.rb#597 def location; end # Did this run pass? @@ -832,47 +875,50 @@ module Minitest::Reportable # # @return [Boolean] # - # source://minitest//lib/minitest.rb#496 + # source://minitest//lib/minitest.rb#587 def passed?; end # Returns ".", "F", or "E" based on the result of the run. # - # source://minitest//lib/minitest.rb#516 + # source://minitest//lib/minitest.rb#609 def result_code; end # Was this run skipped? # # @return [Boolean] # - # source://minitest//lib/minitest.rb#523 + # source://minitest//lib/minitest.rb#616 def skipped?; end end -# source://minitest//lib/minitest.rb#633 +# source://minitest//lib/minitest.rb#591 +Minitest::Reportable::BASE_DIR = T.let(T.unsafe(nil), String) + +# source://minitest//lib/minitest.rb#734 class Minitest::Reporter < ::Minitest::AbstractReporter # @return [Reporter] a new instance of Reporter # - # source://minitest//lib/minitest.rb#642 + # source://minitest//lib/minitest.rb#743 def initialize(io = T.unsafe(nil), options = T.unsafe(nil)); end # The IO used to report. # - # source://minitest//lib/minitest.rb#635 + # source://minitest//lib/minitest.rb#736 def io; end # The IO used to report. # - # source://minitest//lib/minitest.rb#635 + # source://minitest//lib/minitest.rb#736 def io=(_arg0); end # Command-line options for this run. # - # source://minitest//lib/minitest.rb#640 + # source://minitest//lib/minitest.rb#741 def options; end # Command-line options for this run. # - # source://minitest//lib/minitest.rb#640 + # source://minitest//lib/minitest.rb#741 def options=(_arg0); end end @@ -882,90 +928,112 @@ end # blow up. By using Result.from(a_test) you can be reasonably sure # that the test result can be marshalled. # -# source://minitest//lib/minitest.rb#542 +# source://minitest//lib/minitest.rb#635 class Minitest::Result < ::Minitest::Runnable include ::Minitest::Reportable - # source://minitest//lib/minitest.rb#575 + # source://minitest//lib/minitest.rb#669 def class_name; end # The class name of the test result. # - # source://minitest//lib/minitest.rb#551 + # source://minitest//lib/minitest.rb#644 def klass; end # The class name of the test result. # - # source://minitest//lib/minitest.rb#551 + # source://minitest//lib/minitest.rb#644 def klass=(_arg0); end # The location of the test method. # - # source://minitest//lib/minitest.rb#556 + # source://minitest//lib/minitest.rb#649 def source_location; end # The location of the test method. # - # source://minitest//lib/minitest.rb#556 + # source://minitest//lib/minitest.rb#649 def source_location=(_arg0); end - # source://minitest//lib/minitest.rb#579 + # source://minitest//lib/minitest.rb#673 def to_s; end class << self # Create a new test result from a Runnable instance. # - # source://minitest//lib/minitest.rb#561 + # source://minitest//lib/minitest.rb#654 def from(runnable); end end end # re-open # -# source://minitest//lib/minitest.rb#277 +# source://minitest//lib/minitest.rb#348 class Minitest::Runnable # @return [Runnable] a new instance of Runnable # - # source://minitest//lib/minitest.rb#445 + # source://minitest//lib/minitest.rb#511 def initialize(name); end # Number of assertions executed in this run. # - # source://minitest//lib/minitest.rb#281 + # source://minitest//lib/minitest.rb#352 def assertions; end # Number of assertions executed in this run. # - # source://minitest//lib/minitest.rb#281 + # source://minitest//lib/minitest.rb#352 def assertions=(_arg0); end - # source://minitest//lib/minitest.rb#441 + # source://minitest//lib/minitest.rb#507 def failure; end # An assertion raised during the run, if any. # - # source://minitest//lib/minitest.rb#286 + # source://minitest//lib/minitest.rb#357 def failures; end # An assertion raised during the run, if any. # - # source://minitest//lib/minitest.rb#286 + # source://minitest//lib/minitest.rb#357 def failures=(_arg0); end - # source://minitest//lib/minitest.rb#427 + # source://minitest//lib/minitest.rb#493 def marshal_dump; end - # source://minitest//lib/minitest.rb#437 + # source://minitest//lib/minitest.rb#503 def marshal_load(ary); end + # Metadata you attach to the test results that get sent to the reporter. + # + # Lazily initializes to a hash, to keep memory down. + # + # NOTE: this data *must* be plain (read: marshal-able) data! + # Hashes! Arrays! Strings! + # + # source://minitest//lib/minitest.rb#526 + def metadata; end + + # Sets metadata, mainly used for +Result.from+. + # + # source://minitest//lib/minitest.rb#533 + def metadata=(_arg0); end + + # Returns true if metadata exists. + # + # @return [Boolean] + # + # source://minitest//lib/minitest.rb#538 + def metadata?; end + # Name of the run. # - # source://minitest//lib/minitest.rb#304 + # source://minitest//lib/minitest.rb#375 def name; end # Set the name of the run. # - # source://minitest//lib/minitest.rb#311 + # source://minitest//lib/minitest.rb#382 def name=(o); end # Did this run pass? @@ -976,7 +1044,7 @@ class Minitest::Runnable # @raise [NotImplementedError] # @return [Boolean] # - # source://minitest//lib/minitest.rb#464 + # source://minitest//lib/minitest.rb#555 def passed?; end # Returns a single character string to print based on the result @@ -985,14 +1053,14 @@ class Minitest::Runnable # # @raise [NotImplementedError] # - # source://minitest//lib/minitest.rb#473 + # source://minitest//lib/minitest.rb#564 def result_code; end # Runs a single method. Needs to return self. # # @raise [NotImplementedError] # - # source://minitest//lib/minitest.rb#454 + # source://minitest//lib/minitest.rb#545 def run; end # Was this run skipped? See #passed? for more information. @@ -1000,42 +1068,42 @@ class Minitest::Runnable # @raise [NotImplementedError] # @return [Boolean] # - # source://minitest//lib/minitest.rb#480 + # source://minitest//lib/minitest.rb#571 def skipped?; end # The time it took to run. # - # source://minitest//lib/minitest.rb#291 + # source://minitest//lib/minitest.rb#362 def time; end # The time it took to run. # - # source://minitest//lib/minitest.rb#291 + # source://minitest//lib/minitest.rb#362 def time=(_arg0); end - # source://minitest//lib/minitest.rb#293 + # source://minitest//lib/minitest.rb#364 def time_it; end class << self - # source://minitest//lib/minitest.rb#1083 + # source://minitest//lib/minitest.rb#1225 def inherited(klass); end # Returns all instance methods matching the pattern +re+. # - # source://minitest//lib/minitest.rb#318 + # source://minitest//lib/minitest.rb#389 def methods_matching(re); end - # source://minitest//lib/minitest.rb#397 + # source://minitest//lib/minitest.rb#463 def on_signal(name, action); end - # source://minitest//lib/minitest.rb#322 + # source://minitest//lib/minitest.rb#393 def reset; end # Responsible for running all runnable methods in a given class, # each in its own instance. Each instance is passed to the # reporter to record. # - # source://minitest//lib/minitest.rb#333 + # source://minitest//lib/minitest.rb#404 def run(reporter, options = T.unsafe(nil)); end # Runs a single method and has the reporter record the result. @@ -1043,7 +1111,7 @@ class Minitest::Runnable # that subclasses can specialize the running of an individual # test. See Minitest::ParallelTest::ClassMethods for an example. # - # source://minitest//lib/minitest.rb#369 + # source://minitest//lib/minitest.rb#444 def run_one_method(klass, method_name, reporter); end # Each subclass of Runnable is responsible for overriding this @@ -1051,33 +1119,33 @@ class Minitest::Runnable # # @raise [NotImplementedError] # - # source://minitest//lib/minitest.rb#414 + # source://minitest//lib/minitest.rb#480 def runnable_methods; end # Returns all subclasses of Runnable. # - # source://minitest//lib/minitest.rb#421 + # source://minitest//lib/minitest.rb#487 def runnables; end # Defines the order to run tests (:random by default). Override # this or use a convenience method to change it for your tests. # - # source://minitest//lib/minitest.rb#378 + # source://minitest//lib/minitest.rb#453 def test_order; end - # source://minitest//lib/minitest.rb#382 - def with_info_handler(reporter, &block); end + # source://minitest//lib/minitest.rb#457 + def with_info_handler(reporter, handler, &block); end end end -# source://minitest//lib/minitest.rb#395 +# source://minitest//lib/minitest.rb#461 Minitest::Runnable::SIGNALS = T.let(T.unsafe(nil), Hash) # Assertion raised when skipping a run. # -# source://minitest//lib/minitest.rb#938 +# source://minitest//lib/minitest.rb#1049 class Minitest::Skip < ::Minitest::Assertion - # source://minitest//lib/minitest.rb#939 + # source://minitest//lib/minitest.rb#1050 def result_label; end end @@ -1101,114 +1169,124 @@ end # end # end # -# source://minitest//lib/minitest.rb#693 +# source://minitest//lib/minitest.rb#794 class Minitest::StatisticsReporter < ::Minitest::Reporter # @return [StatisticsReporter] a new instance of StatisticsReporter # - # source://minitest//lib/minitest.rb#737 + # source://minitest//lib/minitest.rb#843 def initialize(io = T.unsafe(nil), options = T.unsafe(nil)); end # Total number of assertions. # - # source://minitest//lib/minitest.rb#697 + # source://minitest//lib/minitest.rb#798 def assertions; end # Total number of assertions. # - # source://minitest//lib/minitest.rb#697 + # source://minitest//lib/minitest.rb#798 def assertions=(_arg0); end # Total number of test cases. # - # source://minitest//lib/minitest.rb#702 + # source://minitest//lib/minitest.rb#803 def count; end # Total number of test cases. # - # source://minitest//lib/minitest.rb#702 + # source://minitest//lib/minitest.rb#803 def count=(_arg0); end # Total number of tests that erred. # - # source://minitest//lib/minitest.rb#730 + # source://minitest//lib/minitest.rb#831 def errors; end # Total number of tests that erred. # - # source://minitest//lib/minitest.rb#730 + # source://minitest//lib/minitest.rb#831 def errors=(_arg0); end # Total number of tests that failed. # - # source://minitest//lib/minitest.rb#725 + # source://minitest//lib/minitest.rb#826 def failures; end # Total number of tests that failed. # - # source://minitest//lib/minitest.rb#725 + # source://minitest//lib/minitest.rb#826 def failures=(_arg0); end # @return [Boolean] # - # source://minitest//lib/minitest.rb#750 + # source://minitest//lib/minitest.rb#857 def passed?; end - # source://minitest//lib/minitest.rb#758 + # source://minitest//lib/minitest.rb#865 def record(result); end # Report on the tracked statistics. # - # source://minitest//lib/minitest.rb#768 + # source://minitest//lib/minitest.rb#875 def report; end # An +Array+ of test cases that failed or were skipped. # - # source://minitest//lib/minitest.rb#707 + # source://minitest//lib/minitest.rb#808 def results; end # An +Array+ of test cases that failed or were skipped. # - # source://minitest//lib/minitest.rb#707 + # source://minitest//lib/minitest.rb#808 def results=(_arg0); end # Total number of tests that where skipped. # - # source://minitest//lib/minitest.rb#735 + # source://minitest//lib/minitest.rb#841 def skips; end # Total number of tests that where skipped. # - # source://minitest//lib/minitest.rb#735 + # source://minitest//lib/minitest.rb#841 def skips=(_arg0); end - # source://minitest//lib/minitest.rb#754 + # source://minitest//lib/minitest.rb#861 def start; end # Time the test run started. If available, the monotonic clock is # used and this is a +Float+, otherwise it's an instance of # +Time+. # - # source://minitest//lib/minitest.rb#714 + # source://minitest//lib/minitest.rb#815 def start_time; end # Time the test run started. If available, the monotonic clock is # used and this is a +Float+, otherwise it's an instance of # +Time+. # - # source://minitest//lib/minitest.rb#714 + # source://minitest//lib/minitest.rb#815 def start_time=(_arg0); end # Test run time. If available, the monotonic clock is used and # this is a +Float+, otherwise it's an instance of +Time+. # - # source://minitest//lib/minitest.rb#720 + # source://minitest//lib/minitest.rb#821 def total_time; end # Test run time. If available, the monotonic clock is used and # this is a +Float+, otherwise it's an instance of +Time+. # - # source://minitest//lib/minitest.rb#720 + # source://minitest//lib/minitest.rb#821 def total_time=(_arg0); end + + # Total number of tests that warned. + # + # source://minitest//lib/minitest.rb#836 + def warnings; end + + # Total number of tests that warned. + # + # source://minitest//lib/minitest.rb#836 + def warnings=(_arg0); end end # A reporter that prints the header, summary, and failure details at @@ -1219,48 +1297,36 @@ end # plugin, pull this out of the composite and replace it with your # own. # -# source://minitest//lib/minitest.rb#788 +# source://minitest//lib/minitest.rb#896 class Minitest::SummaryReporter < ::Minitest::StatisticsReporter - # source://minitest//lib/minitest.rb#823 + # source://minitest//lib/minitest.rb#929 def aggregated_results(io); end - # Returns the value of attribute old_sync. - # - # source://minitest//lib/minitest.rb#791 + # source://minitest//lib/minitest.rb#898 def old_sync; end - # Sets the attribute old_sync - # - # @param value the value to set the attribute old_sync to. - # - # source://minitest//lib/minitest.rb#791 + # source://minitest//lib/minitest.rb#898 def old_sync=(_arg0); end - # source://minitest//lib/minitest.rb#806 + # source://minitest//lib/minitest.rb#912 def report; end - # :startdoc: - # - # source://minitest//lib/minitest.rb#794 + # source://minitest//lib/minitest.rb#900 def start; end - # source://minitest//lib/minitest.rb#818 + # source://minitest//lib/minitest.rb#924 def statistics; end - # source://minitest//lib/minitest.rb#843 + # source://minitest//lib/minitest.rb#949 def summary; end - # :stopdoc: - # - # source://minitest//lib/minitest.rb#790 + # source://minitest//lib/minitest.rb#897 def sync; end - # :stopdoc: - # - # source://minitest//lib/minitest.rb#790 + # source://minitest//lib/minitest.rb#897 def sync=(_arg0); end - # source://minitest//lib/minitest.rb#839 + # source://minitest//lib/minitest.rb#945 def to_s; end end @@ -1279,29 +1345,26 @@ class Minitest::Test < ::Minitest::Runnable # LifecycleHooks # - # source://minitest//lib/minitest/test.rb#190 + # source://minitest//lib/minitest/test.rb#189 def capture_exceptions; end # source://minitest//lib/minitest/test.rb#15 def class_name; end - # source://minitest//lib/minitest/test.rb#207 + # source://minitest//lib/minitest/test.rb#206 def neuter_exception(e); end - # source://minitest//lib/minitest/test.rb#218 + # source://minitest//lib/minitest/test.rb#217 def new_exception(klass, msg, bt, kill = T.unsafe(nil)); end # Runs a single test with setup/teardown hooks. # - # source://minitest//lib/minitest/test.rb#86 + # source://minitest//lib/minitest/test.rb#87 def run; end - # source://minitest//lib/minitest/test.rb#200 + # source://minitest//lib/minitest/test.rb#199 def sanitize_exception(e); end - # source://minitest//lib/minitest/test.rb#232 - def with_info_handler(&block); end - class << self # Call this at the top of your tests when you absolutely # positively need to have ordered tests. In doing so, you're @@ -1330,18 +1393,19 @@ class Minitest::Test < ::Minitest::Runnable # source://minitest//lib/minitest/test.rb#48 def make_my_diffs_pretty!; end - # Call this at the top of your tests when you want to run your - # tests in parallel. In doing so, you're admitting that you rule - # and your tests are awesome. + # Call this at the top of your tests (inside the +Minitest::Test+ + # subclass or +describe+ block) when you want to run your tests in + # parallel. In doing so, you're admitting that you rule and your + # tests are awesome. # - # source://minitest//lib/minitest/test.rb#59 + # source://minitest//lib/minitest/test.rb#60 def parallelize_me!; end # Returns all instance methods starting with "test_". Based on # #test_order, the methods are either sorted, randomized # (default), or run in parallel. # - # source://minitest//lib/minitest/test.rb#69 + # source://minitest//lib/minitest/test.rb#70 def runnable_methods; end end end @@ -1350,7 +1414,7 @@ end # meant for library writers, NOT for regular test authors. See # #before_setup for an example. # -# source://minitest//lib/minitest/test.rb#113 +# source://minitest//lib/minitest/test.rb#112 module Minitest::Test::LifecycleHooks # Runs before every test, after setup. This hook is meant for # libraries to extend minitest. It is not meant to be used by @@ -1358,7 +1422,7 @@ module Minitest::Test::LifecycleHooks # # See #before_setup for an example. # - # source://minitest//lib/minitest/test.rb#163 + # source://minitest//lib/minitest/test.rb#162 def after_setup; end # Runs after every test, after teardown. This hook is meant for @@ -1367,7 +1431,7 @@ module Minitest::Test::LifecycleHooks # # See #before_setup for an example. # - # source://minitest//lib/minitest/test.rb#187 + # source://minitest//lib/minitest/test.rb#186 def after_teardown; end # Runs before every test, before setup. This hook is meant for @@ -1398,11 +1462,11 @@ module Minitest::Test::LifecycleHooks # end # end # - # class MiniTest::Test + # class Minitest::Test # include MyMinitestPlugin # end # - # source://minitest//lib/minitest/test.rb#148 + # source://minitest//lib/minitest/test.rb#147 def before_setup; end # Runs after every test, before teardown. This hook is meant for @@ -1411,19 +1475,19 @@ module Minitest::Test::LifecycleHooks # # See #before_setup for an example. # - # source://minitest//lib/minitest/test.rb#172 + # source://minitest//lib/minitest/test.rb#171 def before_teardown; end # Runs before every test. Use this to set up before each test # run. # - # source://minitest//lib/minitest/test.rb#154 + # source://minitest//lib/minitest/test.rb#153 def setup; end # Runs after every test. Use this to clean up after each test # run. # - # source://minitest//lib/minitest/test.rb#178 + # source://minitest//lib/minitest/test.rb#177 def teardown; end end @@ -1438,54 +1502,45 @@ Minitest::Test::TEARDOWN_METHODS = T.let(T.unsafe(nil), Array) # Assertion wrapping an unexpected error that was raised during a run. # -# source://minitest//lib/minitest.rb#947 +# source://minitest//lib/minitest.rb#1058 class Minitest::UnexpectedError < ::Minitest::Assertion + include ::Minitest::Compress + # @return [UnexpectedError] a new instance of UnexpectedError # - # source://minitest//lib/minitest.rb#951 + # source://minitest//lib/minitest.rb#1064 def initialize(error); end - # source://minitest//lib/minitest.rb#956 + # source://minitest//lib/minitest.rb#1077 def backtrace; end # TODO: figure out how to use `cause` instead # - # source://minitest//lib/minitest.rb#949 + # source://minitest//lib/minitest.rb#1062 def error; end # TODO: figure out how to use `cause` instead # - # source://minitest//lib/minitest.rb#949 + # source://minitest//lib/minitest.rb#1062 def error=(_arg0); end - # source://minitest//lib/minitest.rb#960 + # source://minitest//lib/minitest.rb#1083 def message; end - # source://minitest//lib/minitest.rb#965 + # source://minitest//lib/minitest.rb#1089 def result_label; end end -# source://minitest//lib/minitest/unit.rb#20 -class Minitest::Unit - class << self - # source://minitest//lib/minitest/unit.rb#36 - def after_tests(&b); end - - # source://minitest//lib/minitest/unit.rb#30 - def autorun; end - end -end +# source://minitest//lib/minitest.rb#1081 +Minitest::UnexpectedError::BASE_RE = T.let(T.unsafe(nil), Regexp) -# source://minitest//lib/minitest/unit.rb#22 -class Minitest::Unit::TestCase < ::Minitest::Test - class << self - # source://minitest//lib/minitest/unit.rb#23 - def inherited(klass); end - end +# Assertion raised on warning when running in -Werror mode. +# +# source://minitest//lib/minitest.rb#1097 +class Minitest::UnexpectedWarning < ::Minitest::Assertion + # source://minitest//lib/minitest.rb#1098 + def result_label; end end -# source://minitest//lib/minitest/unit.rb#21 -Minitest::Unit::VERSION = T.let(T.unsafe(nil), String) - # source://minitest//lib/minitest.rb#12 Minitest::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/msgpack@1.7.2.rbi b/sorbet/rbi/gems/msgpack@1.7.2.rbi new file mode 100644 index 000000000..c80c8f796 --- /dev/null +++ b/sorbet/rbi/gems/msgpack@1.7.2.rbi @@ -0,0 +1,320 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `msgpack` gem. +# Please instead update this file by running `bin/tapioca gem msgpack`. + + +# source://msgpack//lib/msgpack/core_ext.rb#67 +class Array + include ::Enumerable + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#71 + def to_msgpack_with_packer(packer); end +end + +# source://msgpack//lib/msgpack/core_ext.rb#37 +class FalseClass + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#41 + def to_msgpack_with_packer(packer); end +end + +# source://msgpack//lib/msgpack/core_ext.rb#47 +class Float < ::Numeric + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#51 + def to_msgpack_with_packer(packer); end +end + +# source://msgpack//lib/msgpack/core_ext.rb#77 +class Hash + include ::Enumerable + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#81 + def to_msgpack_with_packer(packer); end +end + +# source://msgpack//lib/msgpack/core_ext.rb#98 +class Integer < ::Numeric + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#102 + def to_msgpack_with_packer(packer); end +end + +Integer::GMP_VERSION = T.let(T.unsafe(nil), String) + +# MessagePack extention packer and unpacker for built-in Time class +# +# source://msgpack//lib/msgpack/version.rb#1 +module MessagePack + private + + # source://msgpack//lib/msgpack.rb#39 + def dump(v, io = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack.rb#22 + def load(src, param = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack.rb#39 + def pack(v, io = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack.rb#22 + def unpack(src, param = T.unsafe(nil)); end + + class << self + # source://msgpack//lib/msgpack.rb#39 + def dump(v, io = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack.rb#22 + def load(src, param = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack.rb#39 + def pack(v, io = T.unsafe(nil), options = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack.rb#22 + def unpack(src, param = T.unsafe(nil)); end + end +end + +# source://msgpack//lib/msgpack/core_ext.rb#2 +module MessagePack::CoreExt + # source://msgpack//lib/msgpack/core_ext.rb#3 + def to_msgpack(packer_or_io = T.unsafe(nil)); end +end + +# source://msgpack//lib/msgpack/core_ext.rb#130 +class MessagePack::ExtensionValue < ::Struct + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#134 + def to_msgpack_with_packer(packer); end +end + +# source://msgpack//lib/msgpack/factory.rb#2 +class MessagePack::Factory + # source://msgpack//lib/msgpack/factory.rb#113 + def dump(v, *rest); end + + # source://msgpack//lib/msgpack/factory.rb#99 + def load(src, param = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack/factory.rb#113 + def pack(v, *rest); end + + # source://msgpack//lib/msgpack/factory.rb#120 + def pool(size = T.unsafe(nil), **options); end + + # see ext for other methods + # + # @raise [FrozenError] + # + # source://msgpack//lib/msgpack/factory.rb#5 + def register_type(type, klass, options = T.unsafe(nil)); end + + # [ {type: id, class: Class(or nil), packer: arg, unpacker: arg}, ... ] + # + # source://msgpack//lib/msgpack/factory.rb#41 + def registered_types(selector = T.unsafe(nil)); end + + # @return [Boolean] + # + # source://msgpack//lib/msgpack/factory.rb#86 + def type_registered?(klass_or_type, selector = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack/factory.rb#99 + def unpack(src, param = T.unsafe(nil)); end +end + +# source://msgpack//lib/msgpack/factory.rb#128 +class MessagePack::Factory::Pool + # @return [Pool] a new instance of Pool + # + # source://msgpack//lib/msgpack/factory.rb#181 + def initialize(factory, size, options = T.unsafe(nil)); end + + # source://msgpack//lib/msgpack/factory.rb#195 + def dump(object); end + + # source://msgpack//lib/msgpack/factory.rb#188 + def load(data); end + + # source://msgpack//lib/msgpack/factory.rb#206 + def packer(&block); end + + # source://msgpack//lib/msgpack/factory.rb#202 + def unpacker(&block); end +end + +# source://msgpack//lib/msgpack/factory.rb#130 +class MessagePack::Factory::Pool::MemberPool + # @return [MemberPool] a new instance of MemberPool + # + # source://msgpack//lib/msgpack/factory.rb#131 + def initialize(size, &block); end + + # source://msgpack//lib/msgpack/factory.rb#137 + def with; end +end + +class MessagePack::HeldBuffer < ::BasicObject; end + +# source://msgpack//lib/msgpack/packer.rb#2 +class MessagePack::Packer + # @raise [ArgumentError] + # + # source://msgpack//lib/msgpack/packer.rb#9 + def register_type(type, klass, method_name = T.unsafe(nil), &block); end + + # source://msgpack//lib/msgpack/packer.rb#14 + def registered_types; end + + # @return [Boolean] + # + # source://msgpack//lib/msgpack/packer.rb#24 + def type_registered?(klass_or_type); end +end + +# source://msgpack//lib/msgpack/time.rb#5 +module MessagePack::Time; end + +# source://msgpack//lib/msgpack/time.rb#25 +MessagePack::Time::Packer = T.let(T.unsafe(nil), Proc) + +# 3-arg Time.at is available Ruby >= 2.5 +# +# source://msgpack//lib/msgpack/time.rb#7 +MessagePack::Time::TIME_AT_3_AVAILABLE = T.let(T.unsafe(nil), TrueClass) + +# source://msgpack//lib/msgpack/time.rb#13 +MessagePack::Time::Unpacker = T.let(T.unsafe(nil), Proc) + +# a.k.a. "TimeSpec" +# +# source://msgpack//lib/msgpack/timestamp.rb#4 +class MessagePack::Timestamp + # @param sec [Integer] + # @param nsec [Integer] + # @return [Timestamp] a new instance of Timestamp + # + # source://msgpack//lib/msgpack/timestamp.rb#24 + def initialize(sec, nsec); end + + # source://msgpack//lib/msgpack/timestamp.rb#72 + def ==(other); end + + # @return [Integer] + # + # source://msgpack//lib/msgpack/timestamp.rb#20 + def nsec; end + + # @return [Integer] + # + # source://msgpack//lib/msgpack/timestamp.rb#17 + def sec; end + + # source://msgpack//lib/msgpack/timestamp.rb#68 + def to_msgpack_ext; end + + class << self + # source://msgpack//lib/msgpack/timestamp.rb#29 + def from_msgpack_ext(data); end + + # source://msgpack//lib/msgpack/timestamp.rb#50 + def to_msgpack_ext(sec, nsec); end + end +end + +# source://msgpack//lib/msgpack/timestamp.rb#13 +MessagePack::Timestamp::TIMESTAMP32_MAX_SEC = T.let(T.unsafe(nil), Integer) + +# source://msgpack//lib/msgpack/timestamp.rb#14 +MessagePack::Timestamp::TIMESTAMP64_MAX_SEC = T.let(T.unsafe(nil), Integer) + +# The timestamp extension type defined in the MessagePack spec. +# See https://github.com/msgpack/msgpack/blob/master/spec.md#timestamp-extension-type for details. +# +# source://msgpack//lib/msgpack/timestamp.rb#11 +MessagePack::Timestamp::TYPE = T.let(T.unsafe(nil), Integer) + +class MessagePack::UnexpectedTypeError < ::MessagePack::UnpackError + include ::MessagePack::TypeError +end + +# source://msgpack//lib/msgpack/unpacker.rb#2 +class MessagePack::Unpacker + # source://msgpack//lib/msgpack/unpacker.rb#9 + def register_type(type, klass = T.unsafe(nil), method_name = T.unsafe(nil), &block); end + + # source://msgpack//lib/msgpack/unpacker.rb#18 + def registered_types; end + + # @return [Boolean] + # + # source://msgpack//lib/msgpack/unpacker.rb#28 + def type_registered?(klass_or_type); end +end + +# source://msgpack//lib/msgpack/core_ext.rb#17 +class NilClass + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#21 + def to_msgpack_with_packer(packer); end +end + +# source://msgpack//lib/msgpack/core_ext.rb#57 +class String + include ::Comparable + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#61 + def to_msgpack_with_packer(packer); end +end + +# source://msgpack//lib/msgpack/symbol.rb#1 +class Symbol + include ::Comparable + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#91 + def to_msgpack_with_packer(packer); end + + class << self + # source://msgpack//lib/msgpack/symbol.rb#12 + def from_msgpack_ext(data); end + end +end + +# source://msgpack//lib/msgpack/core_ext.rb#27 +class TrueClass + include ::MessagePack::CoreExt + + private + + # source://msgpack//lib/msgpack/core_ext.rb#31 + def to_msgpack_with_packer(packer); end +end diff --git a/sorbet/rbi/gems/multi_json@1.15.0.rbi b/sorbet/rbi/gems/multi_json@1.15.0.rbi index 833ddacea..64c3c0c72 100644 --- a/sorbet/rbi/gems/multi_json@1.15.0.rbi +++ b/sorbet/rbi/gems/multi_json@1.15.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `multi_json` gem. # Please instead update this file by running `bin/tapioca gem multi_json`. + # source://multi_json//lib/multi_json/options.rb#1 module MultiJson include ::MultiJson::Options diff --git a/sorbet/rbi/gems/multi_test@1.1.0.rbi b/sorbet/rbi/gems/multi_test@1.1.0.rbi index c230b400e..395b4b110 100644 --- a/sorbet/rbi/gems/multi_test@1.1.0.rbi +++ b/sorbet/rbi/gems/multi_test@1.1.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `multi_test` gem. # Please instead update this file by running `bin/tapioca gem multi_test`. + # source://multi_test//lib/multi_test/minitest_world.rb#1 module MultiTest class << self diff --git a/sorbet/rbi/gems/multi_xml@0.6.0.rbi b/sorbet/rbi/gems/multi_xml@0.7.1.rbi similarity index 72% rename from sorbet/rbi/gems/multi_xml@0.6.0.rbi rename to sorbet/rbi/gems/multi_xml@0.7.1.rbi index 7736e1aba..8a130926b 100644 --- a/sorbet/rbi/gems/multi_xml@0.6.0.rbi +++ b/sorbet/rbi/gems/multi_xml@0.7.1.rbi @@ -4,7 +4,8 @@ # This is an autogenerated file for types exported from the `multi_xml` gem. # Please instead update this file by running `bin/tapioca gem multi_xml`. -# source://multi_xml//lib/multi_xml.rb#8 + +# source://multi_xml//lib/multi_xml.rb#7 module MultiXml class << self # The default parser based on what you currently @@ -14,7 +15,7 @@ module MultiXml # # @raise [NoParserError] # - # source://multi_xml//lib/multi_xml.rb#87 + # source://multi_xml//lib/multi_xml.rb#89 def default_parser; end # Parse an XML string or IO into Ruby. @@ -27,12 +28,12 @@ module MultiXml # # :typecast_xml_value :: If true, won't typecast values for parsed document # - # source://multi_xml//lib/multi_xml.rb#133 + # source://multi_xml//lib/multi_xml.rb#134 def parse(xml, options = T.unsafe(nil)); end # Get the current parser class. # - # source://multi_xml//lib/multi_xml.rb#77 + # source://multi_xml//lib/multi_xml.rb#78 def parser; end # Set the XML parser utilizing a symbol, string, or class. @@ -44,58 +45,61 @@ module MultiXml # * :rexml # * :oga # - # source://multi_xml//lib/multi_xml.rb#112 + # source://multi_xml//lib/multi_xml.rb#113 def parser=(new_parser); end private + # source://multi_xml//lib/multi_xml.rb#193 + def base64_decode(input); end + # TODO: Add support for other encodings # - # source://multi_xml//lib/multi_xml.rb#174 + # source://multi_xml//lib/multi_xml.rb#176 def parse_binary(binary, entity); end - # source://multi_xml//lib/multi_xml.rb#183 + # source://multi_xml//lib/multi_xml.rb#185 def parse_file(file, entity); end - # source://multi_xml//lib/multi_xml.rb#191 + # source://multi_xml//lib/multi_xml.rb#197 def symbolize_keys(params); end - # source://multi_xml//lib/multi_xml.rb#218 + # source://multi_xml//lib/multi_xml.rb#224 def typecast_xml_value(value, disallowed_types = T.unsafe(nil)); end - # source://multi_xml//lib/multi_xml.rb#204 + # source://multi_xml//lib/multi_xml.rb#210 def undasherize_keys(params); end end end -# source://multi_xml//lib/multi_xml.rb#27 +# source://multi_xml//lib/multi_xml.rb#28 MultiXml::CONTENT_ROOT = T.let(T.unsafe(nil), String) -# source://multi_xml//lib/multi_xml.rb#69 +# source://multi_xml//lib/multi_xml.rb#70 MultiXml::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash) -# source://multi_xml//lib/multi_xml.rb#67 +# source://multi_xml//lib/multi_xml.rb#68 MultiXml::DISALLOWED_XML_TYPES = T.let(T.unsafe(nil), Array) -# source://multi_xml//lib/multi_xml.rb#11 +# source://multi_xml//lib/multi_xml.rb#12 class MultiXml::DisallowedTypeError < ::StandardError # @return [DisallowedTypeError] a new instance of DisallowedTypeError # - # source://multi_xml//lib/multi_xml.rb#12 + # source://multi_xml//lib/multi_xml.rb#13 def initialize(type); end end # source://multi_xml//lib/multi_xml.rb#10 class MultiXml::NoParserError < ::StandardError; end -# source://multi_xml//lib/multi_xml.rb#33 +# source://multi_xml//lib/multi_xml.rb#34 MultiXml::PARSING = T.let(T.unsafe(nil), Hash) -# source://multi_xml//lib/multi_xml.rb#9 +# source://multi_xml//lib/multi_xml.rb#8 class MultiXml::ParseError < ::StandardError; end -# source://multi_xml//lib/multi_xml.rb#18 +# source://multi_xml//lib/multi_xml.rb#19 MultiXml::REQUIREMENT_MAP = T.let(T.unsafe(nil), Array) -# source://multi_xml//lib/multi_xml.rb#52 +# source://multi_xml//lib/multi_xml.rb#53 MultiXml::TYPE_NAMES = T.let(T.unsafe(nil), Hash) diff --git a/sorbet/rbi/gems/multipart-post@2.3.0.rbi b/sorbet/rbi/gems/multipart-post@2.4.1.rbi similarity index 96% rename from sorbet/rbi/gems/multipart-post@2.3.0.rbi rename to sorbet/rbi/gems/multipart-post@2.4.1.rbi index 6e1e05385..12f4d4fc9 100644 --- a/sorbet/rbi/gems/multipart-post@2.3.0.rbi +++ b/sorbet/rbi/gems/multipart-post@2.4.1.rbi @@ -4,7 +4,8 @@ # This is an autogenerated file for types exported from the `multipart-post` gem. # Please instead update this file by running `bin/tapioca gem multipart-post`. -# source://multipart-post//lib/multipart/post/composite_read_io.rb#72 + +# source://multipart-post//lib/multipart/post/composite_read_io.rb#90 CompositeIO = Multipart::Post::CompositeReadIO # source://multipart-post//lib/multipart/post/version.rb#7 @@ -32,20 +33,30 @@ class Multipart::Post::CompositeReadIO # source://multipart-post//lib/multipart/post/composite_read_io.rb#31 def initialize(*ios); end - # Read from IOs in order until `length` bytes have been received. + # Close all the underyling IOs. # # source://multipart-post//lib/multipart/post/composite_read_io.rb#37 + def close; end + + # @return [Boolean] + # + # source://multipart-post//lib/multipart/post/composite_read_io.rb#46 + def closed?; end + + # Read from IOs in order until `length` bytes have been received. + # + # source://multipart-post//lib/multipart/post/composite_read_io.rb#51 def read(length = T.unsafe(nil), outbuf = T.unsafe(nil)); end - # source://multipart-post//lib/multipart/post/composite_read_io.rb#54 + # source://multipart-post//lib/multipart/post/composite_read_io.rb#72 def rewind; end private - # source://multipart-post//lib/multipart/post/composite_read_io.rb#65 + # source://multipart-post//lib/multipart/post/composite_read_io.rb#83 def advance_io; end - # source://multipart-post//lib/multipart/post/composite_read_io.rb#61 + # source://multipart-post//lib/multipart/post/composite_read_io.rb#79 def current_io; end end @@ -61,7 +72,7 @@ module Multipart::Post::Multipartable private - # source://multipart-post//lib/multipart/post/multipartable.rb#66 + # source://multipart-post//lib/multipart/post/multipartable.rb#65 def symbolize_keys(hash); end class << self diff --git a/sorbet/rbi/gems/net-ftp@0.2.0.rbi b/sorbet/rbi/gems/net-ftp@0.3.7.rbi similarity index 78% rename from sorbet/rbi/gems/net-ftp@0.2.0.rbi rename to sorbet/rbi/gems/net-ftp@0.3.7.rbi index c8d1de8ea..737ec26cf 100644 --- a/sorbet/rbi/gems/net-ftp@0.2.0.rbi +++ b/sorbet/rbi/gems/net-ftp@0.3.7.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `net-ftp` gem. # Please instead update this file by running `bin/tapioca gem net-ftp`. + # This class implements the File Transfer Protocol. If you have used a # command-line FTP program, and are familiar with the commands, you will be # able to use this class easily. Some extra features are included to take @@ -45,7 +46,11 @@ # - #rename # - #delete # -# source://net-ftp//lib/net/ftp.rb#80 +# == Mainframe User Support +# - #literal +# - #quote +# +# source://net-ftp//lib/net/ftp.rb#84 class Net::FTP < ::Net::Protocol include ::MonitorMixin include ::OpenSSL @@ -95,12 +100,12 @@ class Net::FTP < ::Net::Protocol # # @return [FTP] a new instance of FTP # - # source://net-ftp//lib/net/ftp.rb#226 + # source://net-ftp//lib/net/ftp.rb#230 def initialize(host = T.unsafe(nil), user_or_options = T.unsafe(nil), passwd = T.unsafe(nil), acct = T.unsafe(nil)); end # Aborts the previous command (ABOR command). # - # source://net-ftp//lib/net/ftp.rb#1262 + # source://net-ftp//lib/net/ftp.rb#1283 def abort; end # Sends the ACCT command. @@ -108,36 +113,36 @@ class Net::FTP < ::Net::Protocol # This is a less common FTP command, to send account # information if the destination host requires it. # - # source://net-ftp//lib/net/ftp.rb#914 + # source://net-ftp//lib/net/ftp.rb#925 def acct(account); end # When +true+, transfers are performed in binary mode. Default: +true+. # - # source://net-ftp//lib/net/ftp.rb#96 + # source://net-ftp//lib/net/ftp.rb#100 def binary; end # A setter to toggle transfers in binary mode. # +newmode+ is either +true+ or +false+ # - # source://net-ftp//lib/net/ftp.rb#305 + # source://net-ftp//lib/net/ftp.rb#314 def binary=(newmode); end # Changes the (remote) directory. # - # source://net-ftp//lib/net/ftp.rb#1183 + # source://net-ftp//lib/net/ftp.rb#1194 def chdir(dirname); end # Closes the connection. Further operations are impossible until you open # a new connection with #connect. # - # source://net-ftp//lib/net/ftp.rb#1376 + # source://net-ftp//lib/net/ftp.rb#1397 def close; end # Returns +true+ if and only if the connection is closed. # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1392 + # source://net-ftp//lib/net/ftp.rb#1413 def closed?; end # Establishes an FTP connection to host, optionally overriding the default @@ -145,62 +150,62 @@ class Net::FTP < ::Net::Protocol # connection through a SOCKS proxy. Raises an exception (typically # Errno::ECONNREFUSED) if the connection cannot be established. # - # source://net-ftp//lib/net/ftp.rb#398 + # source://net-ftp//lib/net/ftp.rb#402 def connect(host, port = T.unsafe(nil)); end # When +true+, all traffic to and from the server is written # to +$stdout+. Default: +false+. # - # source://net-ftp//lib/net/ftp.rb#107 + # source://net-ftp//lib/net/ftp.rb#111 def debug_mode; end # When +true+, all traffic to and from the server is written # to +$stdout+. Default: +false+. # - # source://net-ftp//lib/net/ftp.rb#107 + # source://net-ftp//lib/net/ftp.rb#111 def debug_mode=(_arg0); end # Sets or retrieves the output stream for debugging. # Output stream will be used only when +debug_mode+ is set to true. # The default value is +$stdout+. # - # source://net-ftp//lib/net/ftp.rb#112 + # source://net-ftp//lib/net/ftp.rb#116 def debug_output; end # Sets or retrieves the output stream for debugging. # Output stream will be used only when +debug_mode+ is set to true. # The default value is +$stdout+. # - # source://net-ftp//lib/net/ftp.rb#112 + # source://net-ftp//lib/net/ftp.rb#116 def debug_output=(_arg0); end # Writes debug message to the debug output stream # - # source://net-ftp//lib/net/ftp.rb#1467 + # source://net-ftp//lib/net/ftp.rb#1488 def debug_print(msg); end # Deletes a file on the server. # - # source://net-ftp//lib/net/ftp.rb#1169 + # source://net-ftp//lib/net/ftp.rb#1180 def delete(filename); end # Returns an array of file information in the directory (the output is like # `ls -l`). If a block is given, it iterates through the listing. # - # source://net-ftp//lib/net/ftp.rb#938 + # source://net-ftp//lib/net/ftp.rb#949 def dir(*args, &block); end # Issues a FEAT command # # Returns an array of supported optional features # - # source://net-ftp//lib/net/ftp.rb#1342 + # source://net-ftp//lib/net/ftp.rb#1363 def features; end # Retrieves +remotefile+ in whatever mode the session is set (text or # binary). See #gettextfile and #getbinaryfile. # - # source://net-ftp//lib/net/ftp.rb#843 + # source://net-ftp//lib/net/ftp.rb#849 def get(remotefile, localfile = T.unsafe(nil), blocksize = T.unsafe(nil), &block); end # Retrieves +remotefile+ in binary mode, storing the result in +localfile+. @@ -208,12 +213,12 @@ class Net::FTP < ::Net::Protocol # If a block is supplied, it is passed the retrieved data in +blocksize+ # chunks. # - # source://net-ftp//lib/net/ftp.rb#782 + # source://net-ftp//lib/net/ftp.rb#788 def getbinaryfile(remotefile, localfile = T.unsafe(nil), blocksize = T.unsafe(nil), &block); end # Returns the current remote directory. # - # source://net-ftp//lib/net/ftp.rb#1242 + # source://net-ftp//lib/net/ftp.rb#1263 def getdir; end # Retrieves +remotefile+ in ASCII (text) mode, storing the result in @@ -222,35 +227,43 @@ class Net::FTP < ::Net::Protocol # If a block is supplied, it is passed the retrieved data one # line at a time. # - # source://net-ftp//lib/net/ftp.rb#817 + # source://net-ftp//lib/net/ftp.rb#823 def gettextfile(remotefile, localfile = T.unsafe(nil), &block); end # Issues the HELP command. # - # source://net-ftp//lib/net/ftp.rb#1305 + # source://net-ftp//lib/net/ftp.rb#1326 def help(arg = T.unsafe(nil)); end # The server's last response. # - # source://net-ftp//lib/net/ftp.rb#151 + # source://net-ftp//lib/net/ftp.rb#155 def last_response; end # The server's last response code. # - # source://net-ftp//lib/net/ftp.rb#147 + # source://net-ftp//lib/net/ftp.rb#151 def last_response_code; end # The server's last response code. # - # source://net-ftp//lib/net/ftp.rb#147 + # source://net-ftp//lib/net/ftp.rb#151 def lastresp; end # Returns an array of file information in the directory (the output is like # `ls -l`). If a block is given, it iterates through the listing. # - # source://net-ftp//lib/net/ftp.rb#938 + # source://net-ftp//lib/net/ftp.rb#949 def list(*args, &block); end + # The "quote" subcommand sends arguments verbatim to the remote ftp server. + # The "literal" subcommand is an alias for "quote". + # + # @param arguments Array[String] to be sent verbatim to the remote ftp server + # + # source://net-ftp//lib/net/ftp.rb#1248 + def literal(arguments); end + # Logs in to the remote host. The session must have been # previously connected. If +user+ is the string "anonymous" and # the +password+ is +nil+, "anonymous@" is used as a password. If @@ -258,13 +271,13 @@ class Net::FTP < ::Net::Protocol # following the successful login. Raises an exception on error # (typically Net::FTPPermError). # - # source://net-ftp//lib/net/ftp.rb#629 + # source://net-ftp//lib/net/ftp.rb#635 def login(user = T.unsafe(nil), passwd = T.unsafe(nil), acct = T.unsafe(nil)); end # Returns an array of file information in the directory (the output is like # `ls -l`). If a block is given, it iterates through the listing. # - # source://net-ftp//lib/net/ftp.rb#938 + # source://net-ftp//lib/net/ftp.rb#949 def ls(*args, &block); end # Returns the raw last modification time of the (remote) file in the format @@ -272,12 +285,12 @@ class Net::FTP < ::Net::Protocol # # Use +mtime+ if you want a parsed Time instance. # - # source://net-ftp//lib/net/ftp.rb#1295 + # source://net-ftp//lib/net/ftp.rb#1316 def mdtm(filename); end # Creates a remote directory. # - # source://net-ftp//lib/net/ftp.rb#1227 + # source://net-ftp//lib/net/ftp.rb#1238 def mkdir(dirname); end # Returns an array of the entries of the directory specified by @@ -287,32 +300,32 @@ class Net::FTP < ::Net::Protocol # If a block is given, it iterates through the listing. # If +pathname+ is omitted, the current directory is assumed. # - # source://net-ftp//lib/net/ftp.rb#1143 + # source://net-ftp//lib/net/ftp.rb#1154 def mlsd(pathname = T.unsafe(nil), &block); end # Returns data (e.g., size, last modification time, entry type, etc.) # about the file or directory specified by +pathname+. # If +pathname+ is omitted, the current directory is assumed. # - # source://net-ftp//lib/net/ftp.rb#1121 + # source://net-ftp//lib/net/ftp.rb#1132 def mlst(pathname = T.unsafe(nil)); end # Returns the last modification time of the (remote) file. If +local+ is # +true+, it is returned as a local time, otherwise it's a UTC time. # - # source://net-ftp//lib/net/ftp.rb#1220 + # source://net-ftp//lib/net/ftp.rb#1231 def mtime(filename, local = T.unsafe(nil)); end # Returns an array of filenames in the remote directory. # - # source://net-ftp//lib/net/ftp.rb#922 + # source://net-ftp//lib/net/ftp.rb#933 def nlst(dir = T.unsafe(nil)); end # Issues a NOOP command. # # Does nothing except return a response. # - # source://net-ftp//lib/net/ftp.rb#1325 + # source://net-ftp//lib/net/ftp.rb#1346 def noop; end # Number of seconds to wait for the connection to open. Any number @@ -320,7 +333,7 @@ class Net::FTP < ::Net::Protocol # object cannot open a connection in this many seconds, it raises a # Net::OpenTimeout exception. The default value is +nil+. # - # source://net-ftp//lib/net/ftp.rb#122 + # source://net-ftp//lib/net/ftp.rb#126 def open_timeout; end # Number of seconds to wait for the connection to open. Any number @@ -328,7 +341,7 @@ class Net::FTP < ::Net::Protocol # object cannot open a connection in this many seconds, it raises a # Net::OpenTimeout exception. The default value is +nil+. # - # source://net-ftp//lib/net/ftp.rb#122 + # source://net-ftp//lib/net/ftp.rb#126 def open_timeout=(_arg0); end # Issues an OPTS command @@ -337,77 +350,88 @@ class Net::FTP < ::Net::Protocol # # example: option('UTF8', 'ON') => 'OPTS UTF8 ON' # - # source://net-ftp//lib/net/ftp.rb#1365 + # source://net-ftp//lib/net/ftp.rb#1386 def option(name, params = T.unsafe(nil)); end # When +true+, the connection is in passive mode. Default: +true+. # - # source://net-ftp//lib/net/ftp.rb#99 + # source://net-ftp//lib/net/ftp.rb#103 def passive; end # When +true+, the connection is in passive mode. Default: +true+. # - # source://net-ftp//lib/net/ftp.rb#99 + # source://net-ftp//lib/net/ftp.rb#103 def passive=(_arg0); end # Transfers +localfile+ to the server in whatever mode the session is set # (text or binary). See #puttextfile and #putbinaryfile. # - # source://net-ftp//lib/net/ftp.rb#899 + # source://net-ftp//lib/net/ftp.rb#910 def put(localfile, remotefile = T.unsafe(nil), blocksize = T.unsafe(nil), &block); end # Transfers +localfile+ to the server in binary mode, storing the result in # +remotefile+. If a block is supplied, calls it, passing in the transmitted # data in +blocksize+ chunks. # - # source://net-ftp//lib/net/ftp.rb#857 + # source://net-ftp//lib/net/ftp.rb#863 def putbinaryfile(localfile, remotefile = T.unsafe(nil), blocksize = T.unsafe(nil), &block); end # Transfers +localfile+ to the server in ASCII (text) mode, storing the result # in +remotefile+. If callback or an associated block is supplied, calls it, # passing in the transmitted data one line at a time. # - # source://net-ftp//lib/net/ftp.rb#886 + # Returns the response which will contain a job number if the user was communicating with a mainframe in ASCII mode + # after issuing 'quote site filetype=jes' + # + # source://net-ftp//lib/net/ftp.rb#895 def puttextfile(localfile, remotefile = T.unsafe(nil), &block); end # Returns the current remote directory. # - # source://net-ftp//lib/net/ftp.rb#1242 + # source://net-ftp//lib/net/ftp.rb#1263 def pwd; end # Exits the FTP session. # - # source://net-ftp//lib/net/ftp.rb#1316 + # source://net-ftp//lib/net/ftp.rb#1337 def quit; end + # The "quote" subcommand sends arguments verbatim to the remote ftp server. + # The "literal" subcommand is an alias for "quote". + # + # @param arguments Array[String] to be sent verbatim to the remote ftp server + # + # source://net-ftp//lib/net/ftp.rb#1248 + def quote(arguments); end + # Number of seconds to wait for one block to be read (via one read(2) # call). Any number may be used, including Floats for fractional # seconds. If the FTP object cannot read data in this many seconds, # it raises a Timeout::Error exception. The default value is 60 seconds. # - # source://net-ftp//lib/net/ftp.rb#135 + # source://net-ftp//lib/net/ftp.rb#139 def read_timeout; end # Setter for the read_timeout attribute. # - # source://net-ftp//lib/net/ftp.rb#138 + # source://net-ftp//lib/net/ftp.rb#142 def read_timeout=(sec); end # Renames a file on the server. # - # source://net-ftp//lib/net/ftp.rb#1158 + # source://net-ftp//lib/net/ftp.rb#1169 def rename(fromname, toname); end # Sets or retrieves the +resume+ status, which decides whether incomplete # transfers are resumed or restarted. Default: +false+. # - # source://net-ftp//lib/net/ftp.rb#116 + # source://net-ftp//lib/net/ftp.rb#120 def resume; end # Sets or retrieves the +resume+ status, which decides whether incomplete # transfers are resumed or restarted. Default: +false+. # - # source://net-ftp//lib/net/ftp.rb#116 + # source://net-ftp//lib/net/ftp.rb#120 def resume=(_arg0); end # Puts the connection into binary (image) mode, issues the given command, @@ -415,7 +439,7 @@ class Net::FTP < ::Net::Protocol # chunks of +blocksize+ characters. Note that +cmd+ is a server command # (such as "RETR myfile"). # - # source://net-ftp//lib/net/ftp.rb#660 + # source://net-ftp//lib/net/ftp.rb#666 def retrbinary(cmd, blocksize, rest_offset = T.unsafe(nil)); end # Puts the connection into ASCII (text) mode, issues the given command, and @@ -423,44 +447,44 @@ class Net::FTP < ::Net::Protocol # no block is given, prints the lines. Note that +cmd+ is a server command # (such as "RETR myfile"). # - # source://net-ftp//lib/net/ftp.rb#685 + # source://net-ftp//lib/net/ftp.rb#691 def retrlines(cmd); end # Obsolete # - # source://net-ftp//lib/net/ftp.rb#343 + # source://net-ftp//lib/net/ftp.rb#352 def return_code; end # Obsolete # - # source://net-ftp//lib/net/ftp.rb#349 + # source://net-ftp//lib/net/ftp.rb#358 def return_code=(s); end # Removes a remote directory. # - # source://net-ftp//lib/net/ftp.rb#1235 + # source://net-ftp//lib/net/ftp.rb#1256 def rmdir(dirname); end # Sends a command and returns the response. # - # source://net-ftp//lib/net/ftp.rb#519 + # source://net-ftp//lib/net/ftp.rb#523 def sendcmd(cmd); end # Set the socket used to connect to the FTP server. # # May raise FTPReplyError if +get_greeting+ is false. # - # source://net-ftp//lib/net/ftp.rb#428 + # source://net-ftp//lib/net/ftp.rb#432 def set_socket(sock, get_greeting = T.unsafe(nil)); end # Issues a SITE command. # - # source://net-ftp//lib/net/ftp.rb#1332 + # source://net-ftp//lib/net/ftp.rb#1353 def site(arg); end # Returns the size of the given (remote) filename. # - # source://net-ftp//lib/net/ftp.rb#1206 + # source://net-ftp//lib/net/ftp.rb#1217 def size(filename); end # Number of seconds to wait for the TLS handshake. Any number @@ -469,7 +493,7 @@ class Net::FTP < ::Net::Protocol # raises a Net::OpenTimeout exception. The default value is +nil+. # If +ssl_handshake_timeout+ is +nil+, +open_timeout+ is used instead. # - # source://net-ftp//lib/net/ftp.rb#129 + # source://net-ftp//lib/net/ftp.rb#133 def ssl_handshake_timeout; end # Number of seconds to wait for the TLS handshake. Any number @@ -478,7 +502,7 @@ class Net::FTP < ::Net::Protocol # raises a Net::OpenTimeout exception. The default value is +nil+. # If +ssl_handshake_timeout+ is +nil+, +open_timeout+ is used instead. # - # source://net-ftp//lib/net/ftp.rb#129 + # source://net-ftp//lib/net/ftp.rb#133 def ssl_handshake_timeout=(_arg0); end # Returns the status (STAT command). @@ -486,7 +510,7 @@ class Net::FTP < ::Net::Protocol # pathname:: when stat is invoked with pathname as a parameter it acts like # list but a lot faster and over the same tcp session. # - # source://net-ftp//lib/net/ftp.rb#1279 + # source://net-ftp//lib/net/ftp.rb#1300 def status(pathname = T.unsafe(nil)); end # Puts the connection into binary (image) mode, issues the given server-side @@ -494,7 +518,7 @@ class Net::FTP < ::Net::Protocol # +file+ to the server. If the optional block is given, it also passes it # the data, in chunks of +blocksize+ characters. # - # source://net-ftp//lib/net/ftp.rb#710 + # source://net-ftp//lib/net/ftp.rb#716 def storbinary(cmd, file, blocksize, rest_offset = T.unsafe(nil)); end # Puts the connection into ASCII (text) mode, issues the given server-side @@ -502,49 +526,49 @@ class Net::FTP < ::Net::Protocol # named +file+ to the server, one line at a time. If the optional block is # given, it also passes it the lines. # - # source://net-ftp//lib/net/ftp.rb#746 + # source://net-ftp//lib/net/ftp.rb#752 def storlines(cmd, file); end # Returns system information. # - # source://net-ftp//lib/net/ftp.rb#1251 + # source://net-ftp//lib/net/ftp.rb#1272 def system; end # When +true+, use the IP address in PASV responses. Otherwise, it uses # the same IP address for the control connection. Default: +false+. # - # source://net-ftp//lib/net/ftp.rb#103 + # source://net-ftp//lib/net/ftp.rb#107 def use_pasv_ip; end # When +true+, use the IP address in PASV responses. Otherwise, it uses # the same IP address for the control connection. Default: +false+. # - # source://net-ftp//lib/net/ftp.rb#103 + # source://net-ftp//lib/net/ftp.rb#107 def use_pasv_ip=(_arg0); end # Sends a command and expect a response beginning with '2'. # - # source://net-ftp//lib/net/ftp.rb#529 + # source://net-ftp//lib/net/ftp.rb#533 def voidcmd(cmd); end # The server's welcome message. # - # source://net-ftp//lib/net/ftp.rb#144 + # source://net-ftp//lib/net/ftp.rb#148 def welcome; end private - # source://net-ftp//lib/net/ftp.rb#1198 + # source://net-ftp//lib/net/ftp.rb#1209 def get_body(resp); end # Reads a line from the sock. If EOF, then it will raise EOFError # - # source://net-ftp//lib/net/ftp.rb#461 + # source://net-ftp//lib/net/ftp.rb#465 def getline; end # Receive a section of lines until the response code's match. # - # source://net-ftp//lib/net/ftp.rb#470 + # source://net-ftp//lib/net/ftp.rb#474 def getmultiline; end # Receives a response from the destination host. @@ -552,17 +576,17 @@ class Net::FTP < ::Net::Protocol # Returns the response code or raises FTPTempError, FTPPermError, or # FTPProtoError # - # source://net-ftp//lib/net/ftp.rb#488 + # source://net-ftp//lib/net/ftp.rb#492 def getresp; end # sends the appropriate command to enable a passive connection # - # source://net-ftp//lib/net/ftp.rb#557 + # source://net-ftp//lib/net/ftp.rb#561 def makepasv; end # Constructs a TCPServer socket # - # source://net-ftp//lib/net/ftp.rb#551 + # source://net-ftp//lib/net/ftp.rb#555 def makeport; end # Constructs a socket with +host+ and +port+. @@ -571,7 +595,7 @@ class Net::FTP < ::Net::Protocol # SOCKS_SERVER, then a SOCKSSocket is returned, else a Socket is # returned. # - # source://net-ftp//lib/net/ftp.rb#358 + # source://net-ftp//lib/net/ftp.rb#367 def open_socket(host, port); end # handler for response code 227 @@ -579,7 +603,7 @@ class Net::FTP < ::Net::Protocol # # Returns host and port. # - # source://net-ftp//lib/net/ftp.rb#1400 + # source://net-ftp//lib/net/ftp.rb#1421 def parse227(resp); end # handler for response code 229 @@ -587,7 +611,7 @@ class Net::FTP < ::Net::Protocol # # Returns host and port. # - # source://net-ftp//lib/net/ftp.rb#1440 + # source://net-ftp//lib/net/ftp.rb#1461 def parse229(resp); end # handler for response code 257 @@ -595,31 +619,31 @@ class Net::FTP < ::Net::Protocol # # Returns host and port. # - # source://net-ftp//lib/net/ftp.rb#1456 + # source://net-ftp//lib/net/ftp.rb#1477 def parse257(resp); end - # source://net-ftp//lib/net/ftp.rb#1101 + # source://net-ftp//lib/net/ftp.rb#1112 def parse_mlsx_entry(entry); end - # source://net-ftp//lib/net/ftp.rb#1417 + # source://net-ftp//lib/net/ftp.rb#1438 def parse_pasv_ipv4_host(s); end - # source://net-ftp//lib/net/ftp.rb#1422 + # source://net-ftp//lib/net/ftp.rb#1443 def parse_pasv_ipv6_host(s); end - # source://net-ftp//lib/net/ftp.rb#1429 + # source://net-ftp//lib/net/ftp.rb#1450 def parse_pasv_port(s); end # Ensures that +line+ has a control return / line feed (CRLF) and writes # it to the socket. # - # source://net-ftp//lib/net/ftp.rb#450 + # source://net-ftp//lib/net/ftp.rb#454 def putline(line); end # If string +s+ includes the PASS command (password), then the contents of # the password are cleaned from the string using "*" # - # source://net-ftp//lib/net/ftp.rb#439 + # source://net-ftp//lib/net/ftp.rb#443 def sanitize(s); end # Sends a command to destination host, with the current binary sendmode @@ -628,20 +652,20 @@ class Net::FTP < ::Net::Protocol # If binary mode is +true+, then "TYPE I" (image) is sent, otherwise "TYPE # A" (ascii) is sent. # - # source://net-ftp//lib/net/ftp.rb#317 + # source://net-ftp//lib/net/ftp.rb#326 def send_type_command; end # Constructs and send the appropriate PORT (or EPRT) command # - # source://net-ftp//lib/net/ftp.rb#537 + # source://net-ftp//lib/net/ftp.rb#541 def sendport(host, port); end - # source://net-ftp//lib/net/ftp.rb#375 + # source://net-ftp//lib/net/ftp.rb#379 def start_tls_session(sock); end # Constructs a connection for transferring data # - # source://net-ftp//lib/net/ftp.rb#568 + # source://net-ftp//lib/net/ftp.rb#572 def transfercmd(cmd, rest_offset = T.unsafe(nil)); end # Receives a response. @@ -649,7 +673,7 @@ class Net::FTP < ::Net::Protocol # Raises FTPReplyError if the first position of the response code is not # equal 2. # - # source://net-ftp//lib/net/ftp.rb#508 + # source://net-ftp//lib/net/ftp.rb#512 def voidresp; end # Toggles transfers in binary mode and yields to a block. @@ -658,20 +682,20 @@ class Net::FTP < ::Net::Protocol # # +newmode+ is either +true+ or +false+ # - # source://net-ftp//lib/net/ftp.rb#331 + # source://net-ftp//lib/net/ftp.rb#340 def with_binary(newmode); end class << self # When +true+, connections are in passive mode per default. # Default: +true+. # - # source://net-ftp//lib/net/ftp.rb#161 + # source://net-ftp//lib/net/ftp.rb#165 def default_passive; end # When +true+, connections are in passive mode per default. # Default: +true+. # - # source://net-ftp//lib/net/ftp.rb#155 + # source://net-ftp//lib/net/ftp.rb#159 def default_passive=(value); end # A synonym for FTP.new, but with a mandatory host parameter. @@ -679,57 +703,57 @@ class Net::FTP < ::Net::Protocol # If a block is given, it is passed the +FTP+ object, which will be closed # when the block finishes, or when an exception is raised. # - # source://net-ftp//lib/net/ftp.rb#171 + # source://net-ftp//lib/net/ftp.rb#175 def open(host, *args); end end end -# source://net-ftp//lib/net/ftp.rb#1524 +# source://net-ftp//lib/net/ftp.rb#1545 class Net::FTP::BufferedSSLSocket < ::Net::FTP::BufferedSocket # @return [BufferedSSLSocket] a new instance of BufferedSSLSocket # - # source://net-ftp//lib/net/ftp.rb#1525 + # source://net-ftp//lib/net/ftp.rb#1546 def initialize(*args, **options); end - # source://net-ftp//lib/net/ftp.rb#1537 + # source://net-ftp//lib/net/ftp.rb#1558 def send(mesg, flags, dest = T.unsafe(nil)); end - # source://net-ftp//lib/net/ftp.rb#1530 + # source://net-ftp//lib/net/ftp.rb#1551 def shutdown(*args); end private - # source://net-ftp//lib/net/ftp.rb#1544 + # source://net-ftp//lib/net/ftp.rb#1565 def rbuf_fill; end end -# source://net-ftp//lib/net/ftp.rb#1488 +# source://net-ftp//lib/net/ftp.rb#1509 class Net::FTP::BufferedSocket < ::Net::BufferedIO - # source://net-ftp//lib/net/ftp.rb#1490 + # source://net-ftp//lib/net/ftp.rb#1511 def addr(*args); end - # source://net-ftp//lib/net/ftp.rb#1509 + # source://net-ftp//lib/net/ftp.rb#1530 def gets; end - # source://net-ftp//lib/net/ftp.rb#1490 + # source://net-ftp//lib/net/ftp.rb#1511 def local_address(*args); end - # source://net-ftp//lib/net/ftp.rb#1490 + # source://net-ftp//lib/net/ftp.rb#1511 def peeraddr(*args); end - # source://net-ftp//lib/net/ftp.rb#1495 + # source://net-ftp//lib/net/ftp.rb#1516 def read(len = T.unsafe(nil)); end - # source://net-ftp//lib/net/ftp.rb#1514 + # source://net-ftp//lib/net/ftp.rb#1535 def readline; end - # source://net-ftp//lib/net/ftp.rb#1490 + # source://net-ftp//lib/net/ftp.rb#1511 def remote_address(*args); end - # source://net-ftp//lib/net/ftp.rb#1490 + # source://net-ftp//lib/net/ftp.rb#1511 def send(*args); end - # source://net-ftp//lib/net/ftp.rb#1490 + # source://net-ftp//lib/net/ftp.rb#1511 def shutdown(*args); end end @@ -737,21 +761,21 @@ end # Each entry has the facts (e.g., size, last modification time, etc.) # and the pathname. # -# source://net-ftp//lib/net/ftp.rb#960 +# source://net-ftp//lib/net/ftp.rb#971 class Net::FTP::MLSxEntry # @return [MLSxEntry] a new instance of MLSxEntry # - # source://net-ftp//lib/net/ftp.rb#963 + # source://net-ftp//lib/net/ftp.rb#974 def initialize(facts, pathname); end # Returns +true+ if the APPE command may be applied to the file. # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#999 + # source://net-ftp//lib/net/ftp.rb#1010 def appendable?; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def charset; end # Returns +true+ if files may be created in the directory by STOU, @@ -759,17 +783,17 @@ class Net::FTP::MLSxEntry # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1007 + # source://net-ftp//lib/net/ftp.rb#1018 def creatable?; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def create; end # Returns +true+ if the file or directory may be deleted by DELE/RMD. # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1014 + # source://net-ftp//lib/net/ftp.rb#1025 def deletable?; end # Returns +true+ if the entry is a directory (i.e., the value of the @@ -777,7 +801,7 @@ class Net::FTP::MLSxEntry # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#988 + # source://net-ftp//lib/net/ftp.rb#999 def directory?; end # Returns +true+ if the MKD command may be used to create a new @@ -785,19 +809,19 @@ class Net::FTP::MLSxEntry # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1044 + # source://net-ftp//lib/net/ftp.rb#1055 def directory_makable?; end # Returns +true+ if the directory may be entered by CWD/CDUP. # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1021 + # source://net-ftp//lib/net/ftp.rb#1032 def enterable?; end # Returns the value of attribute facts. # - # source://net-ftp//lib/net/ftp.rb#961 + # source://net-ftp//lib/net/ftp.rb#972 def facts; end # Returns +true+ if the entry is a file (i.e., the value of the type @@ -805,10 +829,10 @@ class Net::FTP::MLSxEntry # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#980 + # source://net-ftp//lib/net/ftp.rb#991 def file?; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def lang; end # Returns +true+ if the listing commands, LIST, NLST, and MLSD are @@ -816,21 +840,21 @@ class Net::FTP::MLSxEntry # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1036 + # source://net-ftp//lib/net/ftp.rb#1047 def listable?; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def media_type; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def modify; end # Returns the value of attribute pathname. # - # source://net-ftp//lib/net/ftp.rb#961 + # source://net-ftp//lib/net/ftp.rb#972 def pathname; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def perm; end # Returns +true+ if the objects in the directory may be deleted, or @@ -838,62 +862,62 @@ class Net::FTP::MLSxEntry # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1052 + # source://net-ftp//lib/net/ftp.rb#1063 def purgeable?; end # Returns +true+ if the RETR command may be applied to the file. # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1059 + # source://net-ftp//lib/net/ftp.rb#1070 def readable?; end # Returns +true+ if the file or directory may be renamed by RNFR. # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1028 + # source://net-ftp//lib/net/ftp.rb#1039 def renamable?; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def size; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def type; end - # source://net-ftp//lib/net/ftp.rb#971 + # source://net-ftp//lib/net/ftp.rb#982 def unique; end # Returns +true+ if the STOR command may be applied to the file. # # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1066 + # source://net-ftp//lib/net/ftp.rb#1077 def writable?; end end # :stopdoc: # -# source://net-ftp//lib/net/ftp.rb#1472 +# source://net-ftp//lib/net/ftp.rb#1493 class Net::FTP::NullSocket - # source://net-ftp//lib/net/ftp.rb#1480 + # source://net-ftp//lib/net/ftp.rb#1501 def close; end # @return [Boolean] # - # source://net-ftp//lib/net/ftp.rb#1476 + # source://net-ftp//lib/net/ftp.rb#1497 def closed?; end # @raise [FTPConnectionError] # - # source://net-ftp//lib/net/ftp.rb#1483 + # source://net-ftp//lib/net/ftp.rb#1504 def method_missing(mid, *args); end - # source://net-ftp//lib/net/ftp.rb#1473 + # source://net-ftp//lib/net/ftp.rb#1494 def read_timeout=(sec); end end # :stopdoc: # -# source://net-ftp//lib/net/ftp.rb#88 +# source://net-ftp//lib/net/ftp.rb#92 Net::FTP::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/net-http-digest_auth@1.4.1.rbi b/sorbet/rbi/gems/net-http-digest_auth@1.4.1.rbi index b18cc8f6a..e70d19024 100644 --- a/sorbet/rbi/gems/net-http-digest_auth@1.4.1.rbi +++ b/sorbet/rbi/gems/net-http-digest_auth@1.4.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `net-http-digest_auth` gem. # Please instead update this file by running `bin/tapioca gem net-http-digest_auth`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/net-http-persistent@4.0.2.rbi b/sorbet/rbi/gems/net-http-persistent@4.0.2.rbi index d0c8378ad..71425df04 100644 --- a/sorbet/rbi/gems/net-http-persistent@4.0.2.rbi +++ b/sorbet/rbi/gems/net-http-persistent@4.0.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `net-http-persistent` gem. # Please instead update this file by running `bin/tapioca gem net-http-persistent`. + # Persistent connections for Net::HTTP # # Net::HTTP::Persistent maintains persistent connections across all the diff --git a/sorbet/rbi/gems/net-imap@0.3.6.rbi b/sorbet/rbi/gems/net-imap@0.3.6.rbi deleted file mode 100644 index cb6a14017..000000000 --- a/sorbet/rbi/gems/net-imap@0.3.6.rbi +++ /dev/null @@ -1,3781 +0,0 @@ -# typed: false - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `net-imap` gem. -# Please instead update this file by running `bin/tapioca gem net-imap`. - -# Net::IMAP implements Internet Message Access Protocol (\IMAP) client -# functionality. The protocol is described in -# [IMAP4rev1[https://tools.ietf.org/html/rfc3501]]. -# -- -# TODO: and [IMAP4rev2[https://tools.ietf.org/html/rfc9051]]. -# ++ -# -# == \IMAP Overview -# -# An \IMAP client connects to a server, and then authenticates -# itself using either #authenticate or #login. Having -# authenticated itself, there is a range of commands -# available to it. Most work with mailboxes, which may be -# arranged in an hierarchical namespace, and each of which -# contains zero or more messages. How this is implemented on -# the server is implementation-dependent; on a UNIX server, it -# will frequently be implemented as files in mailbox format -# within a hierarchy of directories. -# -# To work on the messages within a mailbox, the client must -# first select that mailbox, using either #select or #examine -# (for read-only access). Once the client has successfully -# selected a mailbox, they enter the "_selected_" state, and that -# mailbox becomes the _current_ mailbox, on which mail-item -# related commands implicitly operate. -# -# === Sequence numbers and UIDs -# -# Messages have two sorts of identifiers: message sequence -# numbers and UIDs. -# -# Message sequence numbers number messages within a mailbox -# from 1 up to the number of items in the mailbox. If a new -# message arrives during a session, it receives a sequence -# number equal to the new size of the mailbox. If messages -# are expunged from the mailbox, remaining messages have their -# sequence numbers "shuffled down" to fill the gaps. -# -# To avoid sequence number race conditions, servers must not expunge messages -# when no command is in progress, nor when responding to #fetch, #store, or -# #search. Expunges _may_ be sent during any other command, including -# #uid_fetch, #uid_store, and #uid_search. The #noop and #idle commands are -# both useful for this side-effect: they allow the server to send all mailbox -# updates, including expunges. -# -# UIDs, on the other hand, are permanently guaranteed not to -# identify another message within the same mailbox, even if -# the existing message is deleted. UIDs are required to -# be assigned in ascending (but not necessarily sequential) -# order within a mailbox; this means that if a non-IMAP client -# rearranges the order of mail items within a mailbox, the -# UIDs have to be reassigned. An \IMAP client thus cannot -# rearrange message orders. -# -# === Server capabilities and protocol extensions -# -# Net::IMAP does not modify its behavior according to server -# #capability. Users of the class must check for required capabilities before -# issuing commands. Special care should be taken to follow all #capability -# requirements for #starttls, #login, and #authenticate. -# -# See the #capability method for more information. -# -# == Examples of Usage -# -# === List sender and subject of all recent messages in the default mailbox -# -# imap = Net::IMAP.new('mail.example.com') -# imap.authenticate('LOGIN', 'joe_user', 'joes_password') -# imap.examine('INBOX') -# imap.search(["RECENT"]).each do |message_id| -# envelope = imap.fetch(message_id, "ENVELOPE")[0].attr["ENVELOPE"] -# puts "#{envelope.from[0].name}: \t#{envelope.subject}" -# end -# -# === Move all messages from April 2003 from "Mail/sent-mail" to "Mail/sent-apr03" -# -# imap = Net::IMAP.new('mail.example.com') -# imap.authenticate('LOGIN', 'joe_user', 'joes_password') -# imap.select('Mail/sent-mail') -# if not imap.list('Mail/', 'sent-apr03') -# imap.create('Mail/sent-apr03') -# end -# imap.search(["BEFORE", "30-Apr-2003", "SINCE", "1-Apr-2003"]).each do |message_id| -# imap.copy(message_id, "Mail/sent-apr03") -# imap.store(message_id, "+FLAGS", [:Deleted]) -# end -# imap.expunge -# -# == Thread Safety -# -# Net::IMAP supports concurrent threads. For example, -# -# imap = Net::IMAP.new("imap.foo.net", "imap2") -# imap.authenticate("cram-md5", "bar", "password") -# imap.select("inbox") -# fetch_thread = Thread.start { imap.fetch(1..-1, "UID") } -# search_result = imap.search(["BODY", "hello"]) -# fetch_result = fetch_thread.value -# imap.disconnect -# -# This script invokes the FETCH command and the SEARCH command concurrently. -# -# == Errors -# -# An \IMAP server can send three different types of responses to indicate -# failure: -# -# NO:: the attempted command could not be successfully completed. For -# instance, the username/password used for logging in are incorrect; -# the selected mailbox does not exist; etc. -# -# BAD:: the request from the client does not follow the server's -# understanding of the \IMAP protocol. This includes attempting -# commands from the wrong client state; for instance, attempting -# to perform a SEARCH command without having SELECTed a current -# mailbox. It can also signal an internal server -# failure (such as a disk crash) has occurred. -# -# BYE:: the server is saying goodbye. This can be part of a normal -# logout sequence, and can be used as part of a login sequence -# to indicate that the server is (for some reason) unwilling -# to accept your connection. As a response to any other command, -# it indicates either that the server is shutting down, or that -# the server is timing out the client connection due to inactivity. -# -# These three error response are represented by the errors -# Net::IMAP::NoResponseError, Net::IMAP::BadResponseError, and -# Net::IMAP::ByeResponseError, all of which are subclasses of -# Net::IMAP::ResponseError. Essentially, all methods that involve -# sending a request to the server can generate one of these errors. -# Only the most pertinent instances have been documented below. -# -# Because the IMAP class uses Sockets for communication, its methods -# are also susceptible to the various errors that can occur when -# working with sockets. These are generally represented as -# Errno errors. For instance, any method that involves sending a -# request to the server and/or receiving a response from it could -# raise an Errno::EPIPE error if the network connection unexpectedly -# goes down. See the socket(7), ip(7), tcp(7), socket(2), connect(2), -# and associated man pages. -# -# Finally, a Net::IMAP::DataFormatError is thrown if low-level data -# is found to be in an incorrect format (for instance, when converting -# between UTF-8 and UTF-16), and Net::IMAP::ResponseParseError is -# thrown if a server response is non-parseable. -# -# == What's here? -# -# * {Connection control}[rdoc-ref:Net::IMAP@Connection+control+methods] -# * {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands] -# * {...for any state}[rdoc-ref:Net::IMAP@IMAP+commands+for+any+state] -# * {...for the "not authenticated" state}[rdoc-ref:Net::IMAP@IMAP+commands+for+the+-22Not+Authenticated-22+state] -# * {...for the "authenticated" state}[rdoc-ref:Net::IMAP@IMAP+commands+for+the+-22Authenticated-22+state] -# * {...for the "selected" state}[rdoc-ref:Net::IMAP@IMAP+commands+for+the+-22Selected-22+state] -# * {...for the "logout" state}[rdoc-ref:Net::IMAP@IMAP+commands+for+the+-22Logout-22+state] -# * {Supported IMAP extensions}[rdoc-ref:Net::IMAP@Supported+IMAP+extensions] -# * {Handling server responses}[rdoc-ref:Net::IMAP@Handling+server+responses] -# -# === Connection control methods -# -# - Net::IMAP.new: A new client connects immediately and waits for a -# successful server greeting before returning the new client object. -# - #starttls: Asks the server to upgrade a clear-text connection to use TLS. -# - #logout: Tells the server to end the session. Enters the "_logout_" state. -# - #disconnect: Disconnects the connection (without sending #logout first). -# - #disconnected?: True if the connection has been closed. -# -# === Core \IMAP commands -# -# The following commands are defined either by -# the [IMAP4rev1[https://tools.ietf.org/html/rfc3501]] base specification, or -# by one of the following extensions: -# [IDLE[https://tools.ietf.org/html/rfc2177]], -# [NAMESPACE[https://tools.ietf.org/html/rfc2342]], -# [UNSELECT[https://tools.ietf.org/html/rfc3691]], -# -- -# TODO: [ENABLE[https://tools.ietf.org/html/rfc5161]], -# TODO: [LIST-EXTENDED[https://tools.ietf.org/html/rfc5258]], -# TODO: [LIST-STATUS[https://tools.ietf.org/html/rfc5819]], -# ++ -# [MOVE[https://tools.ietf.org/html/rfc6851]]. -# These extensions are widely supported by modern IMAP4rev1 servers and have -# all been integrated into [IMAP4rev2[https://tools.ietf.org/html/rfc9051]]. -# Note: Net::IMAP doesn't fully support IMAP4rev2 yet. -# -# -- -# TODO: When IMAP4rev2 is supported, add the following to the each of the -# appropriate commands below. -# Note:: CHECK has been removed from IMAP4rev2. -# Note:: LSUB is obsoleted by +LIST-EXTENDED and has been removed from IMAP4rev2. -# Some arguments require the +LIST-EXTENDED+ or +IMAP4rev2+ capability. -# Requires either the +ENABLE+ or +IMAP4rev2+ capability. -# Requires either the +NAMESPACE+ or +IMAP4rev2+ capability. -# Requires either the +IDLE+ or +IMAP4rev2+ capability. -# Requires either the +UNSELECT+ or +IMAP4rev2+ capability. -# Requires either the +UIDPLUS+ or +IMAP4rev2+ capability. -# Requires either the +MOVE+ or +IMAP4rev2+ capability. -# ++ -# -# ==== \IMAP commands for any state -# -# - #capability: Returns the server's capabilities as an array of strings. -# -# Capabilities may change after #starttls, #authenticate, or #login -# and cached capabilities must be reloaded. -# - #noop: Allows the server to send unsolicited untagged #responses. -# - #logout: Tells the server to end the session. Enters the "_logout_" state. -# -# ==== \IMAP commands for the "Not Authenticated" state -# -# In addition to the universal commands, the following commands are valid in -# the "not authenticated" state: -# -# - #starttls: Upgrades a clear-text connection to use TLS. -# -# Requires the +STARTTLS+ capability. -# - #authenticate: Identifies the client to the server using a {SASL -# mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml]. -# Enters the "_authenticated_" state. -# -# Requires the AUTH=#{mechanism} capability for the chosen -# mechanism. -# - #login: Identifies the client to the server using a plain text password. -# Using #authenticate is generally preferred. Enters the "_authenticated_" -# state. -# -# The +LOGINDISABLED+ capability must NOT be listed. -# -# ==== \IMAP commands for the "Authenticated" state -# -# In addition to the universal commands, the following commands are valid in -# the "_authenticated_" state: -# -# -- -# - #enable: Not implemented by Net::IMAP, yet. -# -# Requires the +ENABLE+ capability. -# ++ -# - #select: Open a mailbox and enter the "_selected_" state. -# - #examine: Open a mailbox read-only, and enter the "_selected_" state. -# - #create: Creates a new mailbox. -# - #delete: Permanently remove a mailbox. -# - #rename: Change the name of a mailbox. -# - #subscribe: Adds a mailbox to the "subscribed" set. -# - #unsubscribe: Removes a mailbox from the "subscribed" set. -# - #list: Returns names and attributes of mailboxes matching a given pattern. -# - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. -# -# Requires the +NAMESPACE+ capability. -# - #status: Returns mailbox information, e.g. message count, unseen message -# count, +UIDVALIDITY+ and +UIDNEXT+. -# - #append: Appends a message to the end of a mailbox. -# - #idle: Allows the server to send updates to the client, without the client -# needing to poll using #noop. -# -# Requires the +IDLE+ capability. -# - #lsub: Lists mailboxes the user has declared "active" or "subscribed". -# -- -# Replaced by LIST-EXTENDED and removed from -# +IMAP4rev2+. However, Net::IMAP hasn't implemented -# LIST-EXTENDED _yet_. -# ++ -# -# ==== \IMAP commands for the "Selected" state -# -# In addition to the universal commands and the "authenticated" commands, the -# following commands are valid in the "_selected_" state: -# -# - #close: Closes the mailbox and returns to the "_authenticated_" state, -# expunging deleted messages, unless the mailbox was opened as read-only. -# - #unselect: Closes the mailbox and returns to the "_authenticated_" state, -# without expunging any messages. -# -# Requires the +UNSELECT+ capability. -# - #expunge: Permanently removes messages which have the Deleted flag set. -# - #uid_expunge: Restricts #expunge to only remove the specified UIDs. -# -# Requires the +UIDPLUS+ capability. -# - #search, #uid_search: Returns sequence numbers or UIDs of messages that -# match the given searching criteria. -# - #fetch, #uid_fetch: Returns data associated with a set of messages, -# specified by sequence number or UID. -# - #store, #uid_store: Alters a message's flags. -# - #copy, #uid_copy: Copies the specified messages to the end of the -# specified destination mailbox. -# - #move, #uid_move: Moves the specified messages to the end of the -# specified destination mailbox, expunging them from the current mailbox. -# -# Requires the +MOVE+ capability. -# - #check: Mostly obsolete. Can be replaced with #noop or #idle. -# -- -# Removed from IMAP4rev2. -# ++ -# -# ==== \IMAP commands for the "Logout" state -# -# No \IMAP commands are valid in the +logout+ state. If the socket is still -# open, Net::IMAP will close it after receiving server confirmation. -# Exceptions will be raised by \IMAP commands that have already started and -# are waiting for a response, as well as any that are called after logout. -# -# === Supported \IMAP extensions -# -# ==== RFC9051: +IMAP4rev2+ -# -# Although IMAP4rev2[https://tools.ietf.org/html/rfc9051] is not supported -# yet, Net::IMAP supports several extensions that have been folded into -# it: +IDLE+, +MOVE+, +NAMESPACE+, +UIDPLUS+, and +UNSELECT+. -# -- -# TODO: RFC4466, ABNF extensions (automatic support for other extensions) -# TODO: +ESEARCH+, ExtendedSearchData -# TODO: +SEARCHRES+, -# TODO: +ENABLE+, -# TODO: +SASL-IR+, -# TODO: +LIST-EXTENDED+, -# TODO: +LIST-STATUS+, -# TODO: +LITERAL-+, -# TODO: +BINARY+ (only the FETCH side) -# TODO: +SPECIAL-USE+ -# implicitly supported, but we can do better: Response codes: RFC5530, etc -# implicitly supported, but we can do better: STATUS=SIZE -# implicitly supported, but we can do better: STATUS DELETED -# ++ -# Commands for these extensions are included with the {Core IMAP -# commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands], above. Other supported -# extensons are listed below. -# -# ==== RFC2087: +QUOTA+ -# - #getquota: returns the resource usage and limits for a quota root -# - #getquotaroot: returns the list of quota roots for a mailbox, as well as -# their resource usage and limits. -# - #setquota: sets the resource limits for a given quota root. -# -# ==== RFC2177: +IDLE+ -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051], so it is also -# listed with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. -# - #idle: Allows the server to send updates to the client, without the client -# needing to poll using #noop. -# -# ==== RFC2342: +NAMESPACE+ -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051], so it is also -# listed with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. -# - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. -# -# ==== RFC2971: +ID+ -# - #id: exchanges client and server implementation information. -# -# -- -# ==== RFC3502: +MULTIAPPEND+ -# TODO... -# ++ -# -# -- -# ==== RFC3516: +BINARY+ -# TODO... -# ++ -# -# ==== RFC3691: +UNSELECT+ -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051], so it is also -# listed with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. -# - #unselect: Closes the mailbox and returns to the "_authenticated_" state, -# without expunging any messages. -# -# ==== RFC4314: +ACL+ -# - #getacl: lists the authenticated user's access rights to a mailbox. -# - #setacl: sets the access rights for a user on a mailbox -# -- -# TODO: #deleteacl, #listrights, #myrights -# ++ -# - *_Note:_* +DELETEACL+, +LISTRIGHTS+, and +MYRIGHTS+ are not supported yet. -# -# ==== RFC4315: +UIDPLUS+ -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051], so it is also -# listed with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. -# - #uid_expunge: Restricts #expunge to only remove the specified UIDs. -# - Updates #select, #examine with the +UIDNOTSTICKY+ ResponseCode -# - Updates #append with the +APPENDUID+ ResponseCode -# - Updates #copy, #move with the +COPYUID+ ResponseCode -# -# -- -# ==== RFC4466: Collected Extensions to IMAP4 ABNF -# TODO... -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051], this RFC updates -# the protocol to enable new optional parameters to many commands: #select, -# #examine, #create, #rename, #fetch, #uid_fetch, #store, #uid_store, #search, -# #uid_search, and #append. However, specific parameters are not defined. -# Extensions to these commands use this syntax whenever possible. Net::IMAP -# may be partially compatible with extensions to these commands, even without -# any explicit support. -# ++ -# -# -- -# ==== RFC4731 +ESEARCH+ -# TODO... -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. -# - Updates #search, #uid_search to accept result options: +MIN+, +MAX+, -# +ALL+, +COUNT+, and to return ExtendedSearchData. -# ++ -# -# -- -# ==== RFC4959: +SASL-IR+ -# TODO... -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. -# - Updates #authenticate to reduce round-trips for supporting mechanisms. -# ++ -# -# -- -# ==== RFC4978: COMPRESS=DEFLATE -# TODO... -# ++ -# -# -- -# ==== RFC5182 +SEARCHRES+ -# TODO... -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. -# - Updates #search, #uid_search with the +SAVE+ result option. -# - Updates #copy, #uid_copy, #fetch, #uid_fetch, #move, #uid_move, #search, -# #uid_search, #store, #uid_store, and #uid_expunge with ability to -# reference the saved result of a previous #search or #uid_search command. -# ++ -# -# ==== RFC5256: +SORT+ -# - #sort, #uid_sort: An alternate version of #search or #uid_search which -# sorts the results by specified keys. -# ==== RFC5256: +THREAD+ -# - #thread, #uid_thread: An alternate version of #search or #uid_search, -# which arranges the results into ordered groups or threads according to a -# chosen algorithm. -# -# -- -# ==== RFC5258 +LIST-EXTENDED+ -# TODO... -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051], this updates the -# protocol with new optional parameters to the #list command, adding a few of -# its own. Net::IMAP may be forward-compatible with future #list extensions, -# even without any explicit support. -# - Updates #list to accept selection options: +SUBSCRIBED+, +REMOTE+, and -# +RECURSIVEMATCH+, and return options: +SUBSCRIBED+ and +CHILDREN+. -# ++ -# -# -- -# ==== RFC5819 +LIST-STATUS+ -# TODO... -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. -# - Updates #list with +STATUS+ return option. -# ++ -# -# ==== +XLIST+ (non-standard, deprecated) -# - #xlist: replaced by +SPECIAL-USE+ attributes in #list responses. -# -# -- -# ==== RFC6154 +SPECIAL-USE+ -# TODO... -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. -# - Updates #list with the +SPECIAL-USE+ selection and return options. -# ++ -# -# ==== RFC6851: +MOVE+ -# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051], so it is also -# listed with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. -# - #move, #uid_move: Moves the specified messages to the end of the -# specified destination mailbox, expunging them from the current mailbox. -# -# -- -# ==== RFC6855: UTF8=ACCEPT -# TODO... -# ==== RFC6855: UTF8=ONLY -# TODO... -# ++ -# -# -- -# ==== RFC7888: LITERAL+, +LITERAL-+ -# TODO... -# ==== RFC7162: +QRESYNC+ -# TODO... -# ==== RFC7162: +CONDSTORE+ -# TODO... -# ==== RFC8474: +OBJECTID+ -# TODO... -# ==== RFC9208: +QUOTA+ -# TODO... -# ++ -# -# === Handling server responses -# -# - #greeting: The server's initial untagged response, which can indicate a -# pre-authenticated connection. -# - #responses: A hash with arrays of unhandled non-+nil+ -# UntaggedResponse and ResponseCode +#data+, keyed by +#name+. -# - #add_response_handler: Add a block to be called inside the receiver thread -# with every server response. -# - #remove_response_handler: Remove a previously added response handler. -# -# -# == References -# -- -# TODO: Consider moving references list to REFERENCES.md or REFERENCES.rdoc. -# ++ -# -# [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501.html]]:: -# Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL - \VERSION 4rev1", -# RFC 3501, DOI 10.17487/RFC3501, March 2003, -# . -# -# [IMAP-ABNF-EXT[https://www.rfc-editor.org/rfc/rfc4466.html]]:: -# Melnikov, A. and C. Daboo, "Collected Extensions to IMAP4 ABNF", -# RFC 4466, DOI 10.17487/RFC4466, April 2006, -# . -# -# Note: Net::IMAP cannot parse the entire RFC4466 grammar yet. -# -# [{IMAP4rev2}[https://www.rfc-editor.org/rfc/rfc9051.html]]:: -# Melnikov, A., Ed., and B. Leiba, Ed., "Internet Message Access Protocol -# (\IMAP) - Version 4rev2", RFC 9051, DOI 10.17487/RFC9051, August 2021, -# . -# -# Note: Net::IMAP is not fully compatible with IMAP4rev2 yet. -# -# [IMAP-IMPLEMENTATION[https://www.rfc-editor.org/info/rfc2683]]:: -# Leiba, B., "IMAP4 Implementation Recommendations", -# RFC 2683, DOI 10.17487/RFC2683, September 1999, -# . -# -# [IMAP-MULTIACCESS[https://www.rfc-editor.org/info/rfc2180]]:: -# Gahrns, M., "IMAP4 Multi-Accessed Mailbox Practice", RFC 2180, DOI -# 10.17487/RFC2180, July 1997, . -# -# [UTF7[https://tools.ietf.org/html/rfc2152]]:: -# Goldsmith, D. and M. Davis, "UTF-7 A Mail-Safe Transformation Format of -# Unicode", RFC 2152, DOI 10.17487/RFC2152, May 1997, -# . -# -# === Message envelope and body structure -# -# [RFC5322[https://tools.ietf.org/html/rfc5322]]:: -# Resnick, P., Ed., "Internet Message Format", -# RFC 5322, DOI 10.17487/RFC5322, October 2008, -# . -# -# Note: obsoletes -# RFC-2822[https://tools.ietf.org/html/rfc2822] (April 2001) and -# RFC-822[https://tools.ietf.org/html/rfc822] (August 1982). -# -# [CHARSET[https://tools.ietf.org/html/rfc2978]]:: -# Freed, N. and J. Postel, "IANA Charset Registration Procedures", BCP 19, -# RFC 2978, DOI 10.17487/RFC2978, October 2000, -# . -# -# [DISPOSITION[https://tools.ietf.org/html/rfc2183]]:: -# Troost, R., Dorner, S., and K. Moore, Ed., "Communicating Presentation -# Information in Internet Messages: The Content-Disposition Header -# Field", RFC 2183, DOI 10.17487/RFC2183, August 1997, -# . -# -# [MIME-IMB[https://tools.ietf.org/html/rfc2045]]:: -# Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions -# (MIME) Part One: Format of Internet Message Bodies", -# RFC 2045, DOI 10.17487/RFC2045, November 1996, -# . -# -# [MIME-IMT[https://tools.ietf.org/html/rfc2046]]:: -# Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions -# (MIME) Part Two: Media Types", RFC 2046, DOI 10.17487/RFC2046, -# November 1996, . -# -# [MIME-HDRS[https://tools.ietf.org/html/rfc2047]]:: -# Moore, K., "MIME (Multipurpose Internet Mail Extensions) Part Three: -# Message Header Extensions for Non-ASCII Text", -# RFC 2047, DOI 10.17487/RFC2047, November 1996, -# . -# -# [RFC2231[https://tools.ietf.org/html/rfc2231]]:: -# Freed, N. and K. Moore, "MIME Parameter Value and Encoded Word -# Extensions: Character Sets, Languages, and Continuations", -# RFC 2231, DOI 10.17487/RFC2231, November 1997, -# . -# -# [I18n-HDRS[https://tools.ietf.org/html/rfc6532]]:: -# Yang, A., Steele, S., and N. Freed, "Internationalized Email Headers", -# RFC 6532, DOI 10.17487/RFC6532, February 2012, -# . -# -# [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]:: -# Alvestrand, H., "Content Language Headers", -# RFC 3282, DOI 10.17487/RFC3282, May 2002, -# . -# -# [LOCATION[https://www.rfc-editor.org/info/rfc2557]]:: -# Palme, J., Hopmann, A., and N. Shelness, "MIME Encapsulation of -# Aggregate Documents, such as HTML (MHTML)", -# RFC 2557, DOI 10.17487/RFC2557, March 1999, -# . -# -# [MD5[https://tools.ietf.org/html/rfc1864]]:: -# Myers, J. and M. Rose, "The Content-MD5 Header Field", -# RFC 1864, DOI 10.17487/RFC1864, October 1995, -# . -# -# -- -# TODO: Document IMAP keywords. -# -# [RFC3503[https://tools.ietf.org/html/rfc3503]] -# Melnikov, A., "Message Disposition Notification (MDN) -# profile for Internet Message Access Protocol (IMAP)", -# RFC 3503, DOI 10.17487/RFC3503, March 2003, -# . -# ++ -# -# === Supported \IMAP Extensions -# -# [QUOTA[https://tools.ietf.org/html/rfc2087]]:: -# Myers, J., "IMAP4 QUOTA extension", RFC 2087, DOI 10.17487/RFC2087, -# January 1997, . -# -- -# TODO: test compatibility with updated QUOTA extension: -# [QUOTA[https://tools.ietf.org/html/rfc9208]]:: -# Melnikov, A., "IMAP QUOTA Extension", RFC 9208, DOI 10.17487/RFC9208, -# March 2022, . -# ++ -# [IDLE[https://tools.ietf.org/html/rfc2177]]:: -# Leiba, B., "IMAP4 IDLE command", RFC 2177, DOI 10.17487/RFC2177, -# June 1997, . -# [NAMESPACE[https://tools.ietf.org/html/rfc2342]]:: -# Gahrns, M. and C. Newman, "IMAP4 Namespace", RFC 2342, -# DOI 10.17487/RFC2342, May 1998, . -# [ID[https://tools.ietf.org/html/rfc2971]]:: -# Showalter, T., "IMAP4 ID extension", RFC 2971, DOI 10.17487/RFC2971, -# October 2000, . -# [ACL[https://tools.ietf.org/html/rfc4314]]:: -# Melnikov, A., "IMAP4 Access Control List (ACL) Extension", RFC 4314, -# DOI 10.17487/RFC4314, December 2005, -# . -# [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]]:: -# Crispin, M., "Internet Message Access Protocol (\IMAP) - UIDPLUS -# extension", RFC 4315, DOI 10.17487/RFC4315, December 2005, -# . -# [SORT[https://tools.ietf.org/html/rfc5256]]:: -# Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and -# THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, -# . -# [THREAD[https://tools.ietf.org/html/rfc5256]]:: -# Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and -# THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, -# . -# [RFC5530[https://www.rfc-editor.org/rfc/rfc5530.html]]:: -# Gulbrandsen, A., "IMAP Response Codes", RFC 5530, DOI 10.17487/RFC5530, -# May 2009, . -# [MOVE[https://tools.ietf.org/html/rfc6851]]:: -# Gulbrandsen, A. and N. Freed, Ed., "Internet Message Access Protocol -# (\IMAP) - MOVE Extension", RFC 6851, DOI 10.17487/RFC6851, January 2013, -# . -# -# === IANA registries -# -# * {IMAP Capabilities}[http://www.iana.org/assignments/imap4-capabilities] -# * {IMAP Response Codes}[https://www.iana.org/assignments/imap-response-codes/imap-response-codes.xhtml] -# * {IMAP Mailbox Name Attributes}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml] -# * {IMAP and JMAP Keywords}[https://www.iana.org/assignments/imap-jmap-keywords/imap-jmap-keywords.xhtml] -# * {IMAP Threading Algorithms}[https://www.iana.org/assignments/imap-threading-algorithms/imap-threading-algorithms.xhtml] -# -- -# * {IMAP Quota Resource Types}[http://www.iana.org/assignments/imap4-capabilities#imap-capabilities-2] -# * [{LIST-EXTENDED options and responses}[https://www.iana.org/assignments/imap-list-extended/imap-list-extended.xhtml] -# * {IMAP METADATA Server Entry and Mailbox Entry Registries}[https://www.iana.org/assignments/imap-metadata/imap-metadata.xhtml] -# * {IMAP ANNOTATE Extension Entries and Attributes}[https://www.iana.org/assignments/imap-annotate-extension/imap-annotate-extension.xhtml] -# * {IMAP URLAUTH Access Identifiers and Prefixes}[https://www.iana.org/assignments/urlauth-access-ids/urlauth-access-ids.xhtml] -# * {IMAP URLAUTH Authorization Mechanism Registry}[https://www.iana.org/assignments/urlauth-authorization-mechanism-registry/urlauth-authorization-mechanism-registry.xhtml] -# ++ -# * {SASL Mechanisms and SASL SCRAM Family Mechanisms}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] -# * {Service Name and Transport Protocol Port Number Registry}[https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml]: -# +imap+: tcp/143, +imaps+: tcp/993 -# * {GSSAPI/Kerberos/SASL Service Names}[https://www.iana.org/assignments/gssapi-service-names/gssapi-service-names.xhtml]: -# +imap+ -# * {Character sets}[https://www.iana.org/assignments/character-sets/character-sets.xhtml] -# -# source://net-imap//lib/net/imap.rb#701 -class Net::IMAP < ::Net::Protocol - include ::MonitorMixin - include ::OpenSSL - include ::OpenSSL::SSL - extend ::Net::IMAP::Authenticators - extend ::Net::IMAP::SASL - - # :call-seq: - # Net::IMAP.new(host, options = {}) - # - # Creates a new Net::IMAP object and connects it to the specified - # +host+. - # - # +options+ is an option hash, each key of which is a symbol. - # - # The available options are: - # - # port:: Port number (default value is 143 for imap, or 993 for imaps) - # ssl:: If +options[:ssl]+ is true, then an attempt will be made - # to use SSL (now TLS) to connect to the server. - # If +options[:ssl]+ is a hash, it's passed to - # OpenSSL::SSL::SSLContext#set_params as parameters. - # open_timeout:: Seconds to wait until a connection is opened - # idle_response_timeout:: Seconds to wait until an IDLE response is received - # - # The most common errors are: - # - # Errno::ECONNREFUSED:: Connection refused by +host+ or an intervening - # firewall. - # Errno::ETIMEDOUT:: Connection timed out (possibly due to packets - # being dropped by an intervening firewall). - # Errno::ENETUNREACH:: There is no route to that network. - # SocketError:: Hostname not known or other socket error. - # Net::IMAP::ByeResponseError:: The connected to the host was successful, but - # it immediately said goodbye. - # - # @return [IMAP] a new instance of IMAP - # - # source://net-imap//lib/net/imap.rb#2009 - def initialize(host, port_or_options = T.unsafe(nil), usessl = T.unsafe(nil), certs = T.unsafe(nil), verify = T.unsafe(nil)); end - - # Adds a response handler. For example, to detect when - # the server sends a new EXISTS response (which normally - # indicates new messages being added to the mailbox), - # add the following handler after selecting the - # mailbox: - # - # imap.add_response_handler { |resp| - # if resp.kind_of?(Net::IMAP::UntaggedResponse) and resp.name == "EXISTS" - # puts "Mailbox now has #{resp.data} messages" - # end - # } - # - # @raise [ArgumentError] - # - # source://net-imap//lib/net/imap.rb#1963 - def add_response_handler(handler = T.unsafe(nil), &block); end - - # Sends an {APPEND command [IMAP4rev1 §6.3.11]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.11] - # to append the +message+ to the end of the +mailbox+. The optional +flags+ - # argument is an array of flags initially passed to the new message. The - # optional +date_time+ argument specifies the creation time to assign to the - # new message; it defaults to the current time. - # - # For example: - # - # imap.append("inbox", < ok_resp - # authenticate(mech, *creds, **props) {|prop, auth| val } -> ok_resp - # authenticate(mechanism, authnid, credentials, authzid=nil) -> ok_resp - # authenticate(mechanism, **properties) -> ok_resp - # authenticate(mechanism) {|propname, authctx| prop_value } -> ok_resp - # - # Sends an {AUTHENTICATE command [IMAP4rev1 §6.2.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.2] - # to authenticate the client. If successful, the connection enters the - # "_authenticated_" state. - # - # +mechanism+ is the name of the \SASL authentication mechanism to be used. - # All other arguments are forwarded to the authenticator for the requested - # mechanism. The listed call signatures are suggestions. The - # documentation for each individual mechanism must be consulted for its - # specific parameters. - # - # An exception Net::IMAP::NoResponseError is raised if authentication fails. - # - # Related: #login, #starttls - # - # ==== Supported SASL Mechanisms - # - # +PLAIN+:: See PlainAuthenticator. - # Login using clear-text username and password. - # - # +XOAUTH2+:: See XOauth2Authenticator. - # Login using a username and OAuth2 access token. - # Non-standard and obsoleted by +OAUTHBEARER+, but widely - # supported. - # - # >>> - # *Deprecated:* Obsolete mechanisms are available for backwards - # compatibility. - # - # For +DIGEST-MD5+ see DigestMD5Authenticator. - # - # For +LOGIN+, see LoginAuthenticator. - # - # For +CRAM-MD5+, see CramMD5Authenticator. - # - # Using a deprecated mechanism will print a warning. - # - # See Net::IMAP::Authenticators for information on plugging in - # authenticators for other mechanisms. See the {SASL mechanism - # registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] - # for information on these and other SASL mechanisms. - # - # ===== Capabilities - # - # Clients MUST NOT attempt to authenticate with a mechanism unless - # "AUTH=#{mechanism}" for that mechanism is a server capability. - # - # Server capabilities may change after #starttls, #login, and #authenticate. - # Cached capabilities _must_ be invalidated after this method completes. - # The TaggedResponse to #authenticate may include updated capabilities in - # its ResponseCode. - # - # ===== Example - # If the authenticators ignore unhandled keyword arguments, the same config - # can be used for multiple mechanisms: - # - # password = nil # saved locally, so we don't ask more than once - # accesstok = nil # saved locally... - # creds = { - # authcid: username, - # password: proc { password ||= ui.prompt_for_password }, - # oauth2_token: proc { accesstok ||= kms.fresh_access_token }, - # } - # capa = imap.capability - # if capa.include? "AUTH=OAUTHBEARER" - # imap.authenticate "OAUTHBEARER", **creds # authcid, oauth2_token - # elsif capa.include? "AUTH=XOAUTH2" - # imap.authenticate "XOAUTH2", **creds # authcid, oauth2_token - # elsif capa.include? "AUTH=SCRAM-SHA-256" - # imap.authenticate "SCRAM-SHA-256", **creds # authcid, password - # elsif capa.include? "AUTH=PLAIN" - # imap.authenticate "PLAIN", **creds # authcid, password - # elsif capa.include? "AUTH=DIGEST-MD5" - # imap.authenticate "DIGEST-MD5", **creds # authcid, password - # elsif capa.include? "LOGINDISABLED" - # raise "the server has disabled login" - # else - # imap.login username, password - # end - # - # source://net-imap//lib/net/imap.rb#1040 - def authenticate(mechanism, *args, **props, &cb); end - - # Sends a {CAPABILITY command [IMAP4rev1 §6.1.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.1] - # and returns an array of capabilities that the server supports. Each - # capability is a string. - # - # See the {IANA IMAP4 capabilities - # registry}[http://www.iana.org/assignments/imap4-capabilities] for a list - # of all standard capabilities, and their reference RFCs. - # - # >>> - # *Note* that Net::IMAP does not currently modify its - # behaviour according to the capabilities of the server; - # it is up to the user of the class to ensure that - # a certain capability is supported by a server before - # using it. - # - # Capability requirements—other than +IMAP4rev1+—are listed in the - # documentation for each command method. - # - # ===== Basic IMAP4rev1 capabilities - # - # All IMAP4rev1 servers must include +IMAP4rev1+ in their capabilities list. - # All IMAP4rev1 servers must _implement_ the +STARTTLS+, - # AUTH=PLAIN, and +LOGINDISABLED+ capabilities, and clients must - # respect their presence or absence. See the capabilites requirements on - # #starttls, #login, and #authenticate. - # - # ===== Using IMAP4rev1 extensions - # - # IMAP4rev1 servers must not activate incompatible behavior until an - # explicit client action invokes a capability, e.g. sending a command or - # command argument specific to that capability. Extensions with backward - # compatible behavior, such as response codes or mailbox attributes, may - # be sent at any time. - # - # Invoking capabilities which are unknown to Net::IMAP may cause unexpected - # behavior and errors, for example ResponseParseError is raised when unknown - # response syntax is received. Invoking commands or command parameters that - # are unsupported by the server may raise NoResponseError, BadResponseError, - # or cause other unexpected behavior. - # - # ===== Caching +CAPABILITY+ responses - # - # Servers may send their capability list, unsolicited, using the - # +CAPABILITY+ response code or an untagged +CAPABILITY+ response. These - # responses can be retrieved and cached using #responses or - # #add_response_handler. - # - # But cached capabilities _must_ be discarded after #starttls, #login, or - # #authenticate. The OK TaggedResponse to #login and #authenticate may - # include +CAPABILITY+ response code data, but the TaggedResponse for - # #starttls is sent clear-text and cannot be trusted. - # - # source://net-imap//lib/net/imap.rb#849 - def capability; end - - # Sends a {CHECK command [IMAP4rev1 §6.4.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.1] - # to request a checkpoint of the currently selected mailbox. This performs - # implementation-specific housekeeping; for instance, reconciling the - # mailbox's in-memory and on-disk state. - # - # Related: #idle, #noop - # - # source://net-imap//lib/net/imap.rb#1503 - def check; end - - # source://net-imap//lib/net/imap.rb#737 - def client_thread; end - - # source://net-imap//lib/net/imap.rb#737 - def client_thread=(_arg0); end - - # Sends a {CLOSE command [IMAP4rev1 §6.4.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.2] - # to close the currently selected mailbox. The CLOSE command permanently - # removes from the mailbox all messages that have the \\Deleted - # flag set. - # - # Related: #unselect - # - # source://net-imap//lib/net/imap.rb#1513 - def close; end - - # Sends a {COPY command [IMAP4rev1 §6.4.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.7] - # to copy the specified message(s) to the end of the specified destination - # +mailbox+. The +set+ parameter is a number, an array of numbers, or a - # Range object. The number is a message sequence number. - # - # Related: #uid_copy - # - # ===== Capabilities - # - # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is - # supported, the server's response should include a +COPYUID+ response code - # with UIDPlusData. This will report the UIDVALIDITY of the destination - # mailbox, the UID set of the source messages, and the assigned UID set of - # the moved messages. - # - # source://net-imap//lib/net/imap.rb#1749 - def copy(set, mailbox); end - - # Sends a {CREATE command [IMAP4rev1 §6.3.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.3] - # to create a new +mailbox+. - # - # A Net::IMAP::NoResponseError is raised if a mailbox with that name - # cannot be created. - # - # Related: #rename, #delete - # - # source://net-imap//lib/net/imap.rb#1129 - def create(mailbox); end - - # Sends a {DELETE command [IMAP4rev1 §6.3.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.4] - # to remove the +mailbox+. - # - # A Net::IMAP::NoResponseError is raised if a mailbox with that name - # cannot be deleted, either because it does not exist or because the - # client does not have permission to delete it. - # - # Related: #create, #rename - # - # source://net-imap//lib/net/imap.rb#1141 - def delete(mailbox); end - - # Disconnects from the server. - # - # Related: #logout - # - # source://net-imap//lib/net/imap.rb#768 - def disconnect; end - - # Returns true if disconnected from the server. - # - # Related: #logout, #disconnect - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap.rb#793 - def disconnected?; end - - # Sends a {EXAMINE command [IMAP4rev1 §6.3.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.2] - # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. - # Behaves the same as #select, except that the selected +mailbox+ is - # identified as read-only. - # - # A Net::IMAP::NoResponseError is raised if the mailbox does not - # exist or is for some reason non-examinable. - # - # Related: #select - # - # source://net-imap//lib/net/imap.rb#1115 - def examine(mailbox); end - - # Sends an {EXPUNGE command [IMAP4rev1 §6.4.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.3] - # Sends a EXPUNGE command to permanently remove from the currently - # selected mailbox all messages that have the \Deleted flag set. - # - # Related: #uid_expunge - # - # source://net-imap//lib/net/imap.rb#1538 - def expunge; end - - # Sends a {FETCH command [IMAP4rev1 §6.4.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.5] - # to retrieve data associated with a message in the mailbox. - # - # The +set+ parameter is a number or a range between two numbers, - # or an array of those. The number is a message sequence number, - # where -1 represents a '*' for use in range notation like 100..-1 - # being interpreted as '100:*'. Beware that the +exclude_end?+ - # property of a Range object is ignored, and the contents of a - # range are independent of the order of the range endpoints as per - # the protocol specification, so 1...5, 5..1 and 5...1 are all - # equivalent to 1..5. - # - # +attr+ is a list of attributes to fetch; see the documentation - # for FetchData for a list of valid attributes. - # - # The return value is an array of FetchData or nil - # (instead of an empty array) if there is no matching message. - # - # Related: #uid_search, FetchData - # - # ===== For example: - # - # p imap.fetch(6..8, "UID") - # #=> [#98}>, \\ - # #99}>, \\ - # #100}>] - # p imap.fetch(6, "BODY[HEADER.FIELDS (SUBJECT)]") - # #=> [#"Subject: test\r\n\r\n"}>] - # data = imap.uid_fetch(98, ["RFC822.SIZE", "INTERNALDATE"])[0] - # p data.seqno - # #=> 6 - # p data.attr["RFC822.SIZE"] - # #=> 611 - # p data.attr["INTERNALDATE"] - # #=> "12-Oct-2000 22:40:59 +0900" - # p data.attr["UID"] - # #=> 98 - # - # source://net-imap//lib/net/imap.rb#1681 - def fetch(set, attr, mod = T.unsafe(nil)); end - - # Sends a {GETACL command [RFC4314 §3.3]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.3] - # along with a specified +mailbox+. If this mailbox exists, an array - # containing objects of MailboxACLItem will be returned. - # - # Related: #setacl, MailboxACLItem - # - # ===== Capabilities - # - # The server's capabilities must include +ACL+ - # [RFC4314[https://tools.ietf.org/html/rfc4314]]. - # - # source://net-imap//lib/net/imap.rb#1410 - def getacl(mailbox); end - - # Sends a {GETQUOTA command [RFC2087 §4.2]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.2] - # along with specified +mailbox+. If this mailbox exists, then an array - # containing a MailboxQuota object is returned. This command is generally - # only available to server admin. - # - # Related: #getquotaroot, #setquota, MailboxQuota - # - # ===== Capabilities - # - # The server's capabilities must include +QUOTA+ - # [RFC2087[https://tools.ietf.org/html/rfc2087]]. - # - # source://net-imap//lib/net/imap.rb#1354 - def getquota(mailbox); end - - # Sends a {GETQUOTAROOT command [RFC2087 §4.3]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.3] - # along with the specified +mailbox+. This command is generally available - # to both admin and user. If this mailbox exists, it returns an array - # containing objects of type MailboxQuotaRoot and MailboxQuota. - # - # Related: #getquota, #setquota, MailboxQuotaRoot, MailboxQuota - # - # ===== Capabilities - # - # The server's capabilities must include +QUOTA+ - # [RFC2087[https://tools.ietf.org/html/rfc2087]]. - # - # source://net-imap//lib/net/imap.rb#1333 - def getquotaroot(mailbox); end - - # Returns the initial greeting the server, an UntaggedResponse. - # - # source://net-imap//lib/net/imap.rb#711 - def greeting; end - - # Sends an {ID command [RFC2971 §3.1]}[https://www.rfc-editor.org/rfc/rfc2971#section-3.1] - # and returns a hash of the server's response, or nil if the server does not - # identify itself. - # - # Note that the user should first check if the server supports the ID - # capability. For example: - # - # capabilities = imap.capability - # if capabilities.include?("ID") - # id = imap.id( - # name: "my IMAP client (ruby)", - # version: MyIMAP::VERSION, - # "support-url": "mailto:bugs@example.com", - # os: RbConfig::CONFIG["host_os"], - # ) - # end - # - # See [ID[https://tools.ietf.org/html/rfc2971]] for field definitions. - # - # ===== Capabilities - # - # The server's capabilities must include +ID+ - # [RFC2971[https://tools.ietf.org/html/rfc2971]] - # - # source://net-imap//lib/net/imap.rb#879 - def id(client_id = T.unsafe(nil)); end - - # Sends an {IDLE command [RFC2177 §3]}[https://www.rfc-editor.org/rfc/rfc6851#section-3] - # {[IMAP4rev2 §6.3.13]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.3.13] - # that waits for notifications of new or expunged messages. Yields - # responses from the server during the IDLE. - # - # Use #idle_done to leave IDLE. - # - # If +timeout+ is given, this method returns after +timeout+ seconds passed. - # +timeout+ can be used for keep-alive. For example, the following code - # checks the connection for each 60 seconds. - # - # loop do - # imap.idle(60) do |res| - # ... - # end - # end - # - # Related: #idle_done, #noop, #check - # - # ===== Capabilities - # - # The server's capabilities must include +IDLE+ - # [RFC2177[https://tools.ietf.org/html/rfc2177]]. - # - # @raise [LocalJumpError] - # - # source://net-imap//lib/net/imap.rb#1910 - def idle(timeout = T.unsafe(nil), &response_handler); end - - # Leaves IDLE. - # - # Related: #idle - # - # source://net-imap//lib/net/imap.rb#1942 - def idle_done; end - - # Seconds to wait until an IDLE response is received. - # - # source://net-imap//lib/net/imap.rb#735 - def idle_response_timeout; end - - # Sends a {LIST command [IMAP4rev1 §6.3.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.8] - # and returns a subset of names from the complete set of all names available - # to the client. +refname+ provides a context (for instance, a base - # directory in a directory-based mailbox hierarchy). +mailbox+ specifies a - # mailbox or (via wildcards) mailboxes under that context. Two wildcards - # may be used in +mailbox+: '*', which matches all characters *including* - # the hierarchy delimiter (for instance, '/' on a UNIX-hosted - # directory-based mailbox hierarchy); and '%', which matches all characters - # *except* the hierarchy delimiter. - # - # If +refname+ is empty, +mailbox+ is used directly to determine - # which mailboxes to match. If +mailbox+ is empty, the root - # name of +refname+ and the hierarchy delimiter are returned. - # - # The return value is an array of MailboxList. - # - # Related: #lsub, MailboxList - # - # ===== For example: - # - # imap.create("foo/bar") - # imap.create("foo/baz") - # p imap.list("", "foo/%") - # #=> [#, \\ - # #, \\ - # #] - # - # -- - # TODO: support LIST-EXTENDED extension [RFC5258]. Needed for IMAP4rev2. - # ++ - # - # source://net-imap//lib/net/imap.rb#1213 - def list(refname, mailbox); end - - # Sends a {LOGIN command [IMAP4rev1 §6.2.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.3] - # to identify the client and carries the plaintext +password+ authenticating - # this +user+. If successful, the connection enters the "_authenticated_" - # state. - # - # Using #authenticate is generally preferred over #login. The LOGIN command - # is not the same as #authenticate with the "LOGIN" +mechanism+. - # - # A Net::IMAP::NoResponseError is raised if authentication fails. - # - # Related: #authenticate, #starttls - # - # ==== Capabilities - # Clients MUST NOT call #login if +LOGINDISABLED+ is listed with the - # capabilities. - # - # Server capabilities may change after #starttls, #login, and #authenticate. - # Cached capabilities _must_ be invalidated after this method completes. - # The TaggedResponse to #login may include updated capabilities in its - # ResponseCode. - # - # source://net-imap//lib/net/imap.rb#1073 - def login(user, password); end - - # Sends a {LOGOUT command [IMAP4rev1 §6.1.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.3] - # to inform the command to inform the server that the client is done with - # the connection. - # - # Related: #disconnect - # - # source://net-imap//lib/net/imap.rb#907 - def logout; end - - # Sends a {LSUB command [IMAP4rev1 §6.3.9]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.9] - # and returns a subset of names from the set of names that the user has - # declared as being "active" or "subscribed." +refname+ and +mailbox+ are - # interpreted as for #list. - # - # The return value is an array of MailboxList objects. - # - # Related: #subscribe, #unsubscribe, #list, MailboxList - # - # source://net-imap//lib/net/imap.rb#1425 - def lsub(refname, mailbox); end - - # Sends a {MOVE command [RFC6851 §3.1]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.1] - # {[IMAP4rev2 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.8] - # to move the specified message(s) to the end of the specified destination - # +mailbox+. The +set+ parameter is a number, an array of numbers, or a - # Range object. The number is a message sequence number. - # - # Related: #uid_move - # - # ===== Capabilities - # - # The server's capabilities must include +MOVE+ - # [RFC6851[https://tools.ietf.org/html/rfc6851]]. - # - # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is - # supported, the server's response should include a +COPYUID+ response code - # with UIDPlusData. This will report the UIDVALIDITY of the destination - # mailbox, the UID set of the source messages, and the assigned UID set of - # the moved messages. - # - # source://net-imap//lib/net/imap.rb#1785 - def move(set, mailbox); end - - # Sends a {NAMESPACE command [RFC2342 §5]}[https://www.rfc-editor.org/rfc/rfc2342#section-5] - # and returns the namespaces that are available. The NAMESPACE command - # allows a client to discover the prefixes of namespaces used by a server - # for personal mailboxes, other users' mailboxes, and shared mailboxes. - # - # The return value is a Namespaces object which has +personal+, +other+, and - # +shared+ fields, each an array of Namespace objects. These arrays will be - # empty when the server responds with +nil+. - # - # Many \IMAP servers are configured with the default personal namespaces as - # ("" "/"): no prefix and the "+/+" hierarchy delimiter. In that - # common case, the naive client may not have any trouble naming mailboxes. - # But many servers are configured with the default personal namespace as - # e.g. ("INBOX." "."), placing all personal folders under INBOX, - # with "+.+" as the hierarchy delimiter. If the client does not check for - # this, but naively assumes it can use the same folder names for all - # servers, then folder creation (and listing, moving, etc) can lead to - # errors. - # - # From RFC2342: - # - # Although typically a server will support only a single Personal - # Namespace, and a single Other User's Namespace, circumstances exist - # where there MAY be multiples of these, and a client MUST be prepared - # for them. If a client is configured such that it is required to create - # a certain mailbox, there can be circumstances where it is unclear which - # Personal Namespaces it should create the mailbox in. In these - # situations a client SHOULD let the user select which namespaces to - # create the mailbox in. - # - # Related: #list, Namespaces, Namespace - # - # ===== For example: - # - # capabilities = imap.capability - # if capabilities.include?("NAMESPACE") - # namespaces = imap.namespace - # if namespace = namespaces.personal.first - # prefix = namespace.prefix # e.g. "" or "INBOX." - # delim = namespace.delim # e.g. "/" or "." - # # personal folders should use the prefix and delimiter - # imap.create(prefix + "foo") - # imap.create(prefix + "bar") - # imap.create(prefix + %w[path to my folder].join(delim)) - # end - # end - # - # ===== Capabilities - # - # The server's capabilities must include +NAMESPACE+ - # [RFC2342[https://tools.ietf.org/html/rfc2342]]. - # - # source://net-imap//lib/net/imap.rb#1271 - def namespace; end - - # Sends a {NOOP command [IMAP4rev1 §6.1.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.2] - # to the server. - # - # This allows the server to send unsolicited untagged EXPUNGE #responses, - # but does not execute any client request. \IMAP servers are permitted to - # send unsolicited untagged responses at any time, except for `EXPUNGE`. - # - # * +EXPUNGE+ can only be sent while a command is in progress. - # * +EXPUNGE+ must _not_ be sent during #fetch, #store, or #search. - # * +EXPUNGE+ may be sent during #uid_fetch, #uid_store, or #uid_search. - # - # Related: #idle, #check - # - # source://net-imap//lib/net/imap.rb#898 - def noop; end - - # Seconds to wait until a connection is opened. - # If the IMAP object cannot open a connection within this time, - # it raises a Net::OpenTimeout exception. The default value is 30 seconds. - # - # source://net-imap//lib/net/imap.rb#732 - def open_timeout; end - - # Removes the response handler. - # - # source://net-imap//lib/net/imap.rb#1969 - def remove_response_handler(handler); end - - # Sends a {RENAME command [IMAP4rev1 §6.3.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.5] - # to change the name of the +mailbox+ to +newname+. - # - # A Net::IMAP::NoResponseError is raised if a mailbox with the - # name +mailbox+ cannot be renamed to +newname+ for whatever - # reason; for instance, because +mailbox+ does not exist, or - # because there is already a mailbox with the name +newname+. - # - # Related: #create, #delete - # - # source://net-imap//lib/net/imap.rb#1154 - def rename(mailbox, newname); end - - # Returns all response handlers. - # - # source://net-imap//lib/net/imap.rb#727 - def response_handlers; end - - # Returns a hash with arrays of unhandled non-+nil+ - # UntaggedResponse#data keyed by UntaggedResponse#name, and - # ResponseCode#data keyed by ResponseCode#name. - # - # For example: - # - # imap.select("inbox") - # p imap.responses["EXISTS"][-1] - # #=> 2 - # p imap.responses["UIDVALIDITY"][-1] - # #=> 968263756 - # - # source://net-imap//lib/net/imap.rb#724 - def responses; end - - # Sends a {SEARCH command [IMAP4rev1 §6.4.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.4] - # to search the mailbox for messages that match the given searching - # criteria, and returns message sequence numbers. +keys+ can either be a - # string holding the entire search string, or a single-dimension array of - # search keywords and arguments. - # - # Related: #uid_search - # - # ===== Search criteria - # - # For a full list of search criteria, - # see [{IMAP4rev1 §6.4.4}[https://www.rfc-editor.org/rfc/rfc3501.html#section-6.4.4]], - # or [{IMAP4rev2 §6.4.4}[https://www.rfc-editor.org/rfc/rfc9051.html#section-6.4.4]], - # in addition to documentation for - # any [CAPABILITIES[https://www.iana.org/assignments/imap-capabilities/imap-capabilities.xhtml]] - # reported by #capability which may define additional search filters, e.g: - # +CONDSTORE+, +WITHIN+, +FILTERS+, SEARCH=FUZZY, +OBJECTID+, or - # +SAVEDATE+. The following are some common search criteria: - # - # :: a set of message sequence numbers. "," indicates - # an interval, "+:+" indicates a range. For instance, - # "2,10:12,15" means "2,10,11,12,15". - # - # BEFORE :: messages with an internal date strictly before - # . The date argument has a format similar - # to 8-Aug-2002, and can be formatted using - # Net::IMAP.format_date. - # - # BODY :: messages that contain within their body. - # - # CC :: messages containing in their CC field. - # - # FROM :: messages that contain in their FROM field. - # - # NEW:: messages with the \Recent, but not the \Seen, flag set. - # - # NOT :: negate the following search key. - # - # OR :: "or" two search keys together. - # - # ON :: messages with an internal date exactly equal to , - # which has a format similar to 8-Aug-2002. - # - # SINCE :: messages with an internal date on or after . - # - # SUBJECT :: messages with in their subject. - # - # TO :: messages with in their TO field. - # - # ===== For example: - # - # p imap.search(["SUBJECT", "hello", "NOT", "NEW"]) - # #=> [1, 6, 7, 8] - # - # source://net-imap//lib/net/imap.rb#1631 - def search(keys, charset = T.unsafe(nil)); end - - # Sends a {SELECT command [IMAP4rev1 §6.3.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.1] - # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. - # - # After you have selected a mailbox, you may retrieve the number of items in - # that mailbox from imap.responses["EXISTS"][-1], and the number of - # recent messages from imap.responses["RECENT"][-1]. Note that - # these values can change if new messages arrive during a session or when - # existing messages are expunged; see #add_response_handler for a way to - # detect these events. - # - # A Net::IMAP::NoResponseError is raised if the mailbox does not - # exist or is for some reason non-selectable. - # - # Related: #examine - # - # ===== Capabilities - # - # If [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]] is supported, - # the server may return an untagged "NO" response with a "UIDNOTSTICKY" - # response code indicating that the mailstore does not support persistent - # UIDs: - # @responses["NO"].last.code.name == "UIDNOTSTICKY" - # - # source://net-imap//lib/net/imap.rb#1099 - def select(mailbox); end - - # Sends a {SETACL command [RFC4314 §3.1]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.1] - # along with +mailbox+, +user+ and the +rights+ that user is to have on that - # mailbox. If +rights+ is nil, then that user will be stripped of any - # rights to that mailbox. - # - # Related: #getacl - # - # ===== Capabilities - # - # The server's capabilities must include +ACL+ - # [RFC4314[https://tools.ietf.org/html/rfc4314]]. - # - # source://net-imap//lib/net/imap.rb#1392 - def setacl(mailbox, user, rights); end - - # Sends a {SETQUOTA command [RFC2087 §4.1]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.1] - # along with the specified +mailbox+ and +quota+. If +quota+ is nil, then - # +quota+ will be unset for that mailbox. Typically one needs to be logged - # in as a server admin for this to work. - # - # Related: #getquota, #getquotaroot - # - # ===== Capabilities - # - # The server's capabilities must include +QUOTA+ - # [RFC2087[https://tools.ietf.org/html/rfc2087]]. - # - # source://net-imap//lib/net/imap.rb#1372 - def setquota(mailbox, quota); end - - # Sends a {SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # to search a mailbox for messages that match +search_keys+ and return an - # array of message sequence numbers, sorted by +sort_keys+. +search_keys+ - # are interpreted the same as for #search. - # - # -- - # TODO: describe +sort_keys+ - # ++ - # - # Related: #uid_sort, #search, #uid_search, #thread, #uid_thread - # - # ===== For example: - # - # p imap.sort(["FROM"], ["ALL"], "US-ASCII") - # #=> [1, 2, 3, 5, 6, 7, 8, 4, 9] - # p imap.sort(["DATE"], ["SUBJECT", "hello"], "US-ASCII") - # #=> [6, 7, 8, 1] - # - # ===== Capabilities - # - # The server's capabilities must include +SORT+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - # - # source://net-imap//lib/net/imap.rb#1829 - def sort(sort_keys, search_keys, charset); end - - # Sends a {STARTTLS command [IMAP4rev1 §6.2.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.1] - # to start a TLS session. - # - # Any +options+ are forwarded to OpenSSL::SSL::SSLContext#set_params. - # - # This method returns after TLS negotiation and hostname verification are - # both successful. Any error indicates that the connection has not been - # secured. - # - # *Note:* - # >>> - # Any #response_handlers added before STARTTLS should be aware that the - # TaggedResponse to STARTTLS is sent clear-text, _before_ TLS negotiation. - # TLS negotiation starts immediately after that response. - # - # Related: Net::IMAP.new, #login, #authenticate - # - # ===== Capability - # - # The server's capabilities must include +STARTTLS+. - # - # Server capabilities may change after #starttls, #login, and #authenticate. - # Cached capabilities _must_ be invalidated after this method completes. - # - # The TaggedResponse to #starttls is sent clear-text, so the server must - # *not* send capabilities in the #starttls response and clients must - # not use them if they are sent. Servers will generally send an - # unsolicited untagged response immeditely _after_ #starttls completes. - # - # source://net-imap//lib/net/imap.rb#940 - def starttls(options = T.unsafe(nil), verify = T.unsafe(nil)); end - - # Sends a {STATUS commands [IMAP4rev1 §6.3.10]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.10] - # and returns the status of the indicated +mailbox+. +attr+ is a list of one - # or more attributes whose statuses are to be requested. Supported - # attributes include: - # - # MESSAGES:: the number of messages in the mailbox. - # RECENT:: the number of recent messages in the mailbox. - # UNSEEN:: the number of unseen messages in the mailbox. - # - # The return value is a hash of attributes. For example: - # - # p imap.status("inbox", ["MESSAGES", "RECENT"]) - # #=> {"RECENT"=>0, "MESSAGES"=>44} - # - # A Net::IMAP::NoResponseError is raised if status values - # for +mailbox+ cannot be returned; for instance, because it - # does not exist. - # - # source://net-imap//lib/net/imap.rb#1449 - def status(mailbox, attr); end - - # Sends a {STORE command [IMAP4rev1 §6.4.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.6] - # to alter data associated with messages in the mailbox, in particular their - # flags. The +set+ parameter is a number, an array of numbers, or a Range - # object. Each number is a message sequence number. +attr+ is the name of a - # data item to store: 'FLAGS' will replace the message's flag list with the - # provided one, '+FLAGS' will add the provided flags, and '-FLAGS' will - # remove them. +flags+ is a list of flags. - # - # The return value is an array of FetchData - # - # Related: #uid_store - # - # ===== For example: - # - # p imap.store(6..8, "+FLAGS", [:Deleted]) - # #=> [#[:Seen, :Deleted]}>, \\ - # #[:Seen, :Deleted]}>, \\ - # #[:Seen, :Deleted]}>] - # - # source://net-imap//lib/net/imap.rb#1719 - def store(set, attr, flags); end - - # Sends a {SUBSCRIBE command [IMAP4rev1 §6.3.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.6] - # to add the specified +mailbox+ name to the server's set of "active" or - # "subscribed" mailboxes as returned by #lsub. - # - # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be - # subscribed to; for instance, because it does not exist. - # - # Related: #unsubscribe, #lsub, #list - # - # source://net-imap//lib/net/imap.rb#1166 - def subscribe(mailbox); end - - # Sends a {THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # to search a mailbox and return message sequence numbers in threaded - # format, as a ThreadMember tree. +search_keys+ are interpreted the same as - # for #search. - # - # The supported algorithms are: - # - # ORDEREDSUBJECT:: split into single-level threads according to subject, - # ordered by date. - # REFERENCES:: split into threads by parent/child relationships determined - # by which message is a reply to which. - # - # Unlike #search, +charset+ is a required argument. US-ASCII - # and UTF-8 are sample values. - # - # Related: #uid_thread, #search, #uid_search, #sort, #uid_sort - # - # ===== Capabilities - # - # The server's capabilities must include +THREAD+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - # - # source://net-imap//lib/net/imap.rb#1869 - def thread(algorithm, search_keys, charset); end - - # Sends a {UID COPY command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to copy the specified message(s) to the end of the specified destination - # +mailbox+. - # - # Similar to #copy, but +set+ contains unique identifiers. - # - # ===== Capabilities - # - # +UIDPLUS+ affects #uid_copy the same way it affects #copy. - # - # source://net-imap//lib/net/imap.rb#1762 - def uid_copy(set, mailbox); end - - # Sends a {UID EXPUNGE command [RFC4315 §2.1]}[https://www.rfc-editor.org/rfc/rfc4315#section-2.1] - # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] - # to permanently remove all messages that have both the \\Deleted - # flag set and a UID that is included in +uid_set+. - # - # By using #uid_expunge instead of #expunge when resynchronizing with - # the server, the client can ensure that it does not inadvertantly - # remove any messages that have been marked as \\Deleted by other - # clients between the time that the client was last connected and - # the time the client resynchronizes. - # - # *Note:* - # >>> - # Although the command takes a set of UIDs for its argument, the - # server still returns regular EXPUNGE responses, which contain - # a sequence number. These will be deleted from - # #responses and this method returns them as an array of - # sequence number integers. - # - # Related: #expunge - # - # ===== Capabilities - # - # The server's capabilities must include +UIDPLUS+ - # [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]]. - # - # source://net-imap//lib/net/imap.rb#1570 - def uid_expunge(uid_set); end - - # Sends a {UID FETCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to retrieve data associated with a message in the mailbox. - # - # Similar to #fetch, but the +set+ parameter contains unique identifiers - # instead of message sequence numbers. - # - # >>> - # *Note:* Servers _MUST_ implicitly include the +UID+ message data item as - # part of any +FETCH+ response caused by a +UID+ command, regardless of - # whether a +UID+ was specified as a message data item to the +FETCH+. - # - # Related: #fetch, FetchData - # - # source://net-imap//lib/net/imap.rb#1697 - def uid_fetch(set, attr, mod = T.unsafe(nil)); end - - # Sends a {UID MOVE command [RFC6851 §3.2]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.2] - # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] - # to move the specified message(s) to the end of the specified destination - # +mailbox+. - # - # Similar to #move, but +set+ contains unique identifiers. - # - # Related: #move - # - # ===== Capabilities - # - # Same as #move: The server's capabilities must include +MOVE+ - # [RFC6851[https://tools.ietf.org/html/rfc6851]]. +UIDPLUS+ also affects - # #uid_move the same way it affects #move. - # - # source://net-imap//lib/net/imap.rb#1803 - def uid_move(set, mailbox); end - - # Sends a {UID SEARCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to search the mailbox for messages that match the given searching - # criteria, and returns unique identifiers (UIDs). - # - # See #search for documentation of search criteria. - # - # source://net-imap//lib/net/imap.rb#1640 - def uid_search(keys, charset = T.unsafe(nil)); end - - # Sends a {UID SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # to search a mailbox for messages that match +search_keys+ and return an - # array of unique identifiers, sorted by +sort_keys+. +search_keys+ are - # interpreted the same as for #search. - # - # Related: #sort, #search, #uid_search, #thread, #uid_thread - # - # ===== Capabilities - # - # The server's capabilities must include +SORT+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - # - # source://net-imap//lib/net/imap.rb#1844 - def uid_sort(sort_keys, search_keys, charset); end - - # Sends a {UID STORE command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] - # to alter data associated with messages in the mailbox, in particular their - # flags. - # - # Similar to #store, but +set+ contains unique identifiers instead of - # message sequence numbers. - # - # Related: #store - # - # source://net-imap//lib/net/imap.rb#1731 - def uid_store(set, attr, flags); end - - # Sends a {UID THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] - # Similar to #thread, but returns unique identifiers instead of - # message sequence numbers. - # - # Related: #thread, #search, #uid_search, #sort, #uid_sort - # - # ===== Capabilities - # - # The server's capabilities must include +THREAD+ - # [RFC5256[https://tools.ietf.org/html/rfc5256]]. - # - # source://net-imap//lib/net/imap.rb#1883 - def uid_thread(algorithm, search_keys, charset); end - - # Sends an {UNSELECT command [RFC3691 §2]}[https://www.rfc-editor.org/rfc/rfc3691#section-3] - # {[IMAP4rev2 §6.4.2]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.2] - # to free the session resources for a mailbox and return to the - # "_authenticated_" state. This is the same as #close, except that - # \\Deleted messages are not removed from the mailbox. - # - # Related: #close - # - # ===== Capabilities - # - # The server's capabilities must include +UNSELECT+ - # [RFC3691[https://tools.ietf.org/html/rfc3691]]. - # - # source://net-imap//lib/net/imap.rb#1529 - def unselect; end - - # Sends an {UNSUBSCRIBE command [IMAP4rev1 §6.3.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.7] - # to remove the specified +mailbox+ name from the server's set of "active" - # or "subscribed" mailboxes. - # - # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be - # unsubscribed from; for instance, because the client is not currently - # subscribed to it. - # - # Related: #subscribe, #lsub, #list - # - # source://net-imap//lib/net/imap.rb#1179 - def unsubscribe(mailbox); end - - # Sends a XLIST command, and returns a subset of names from - # the complete set of all names available to the client. - # +refname+ provides a context (for instance, a base directory - # in a directory-based mailbox hierarchy). +mailbox+ specifies - # a mailbox or (via wildcards) mailboxes under that context. - # Two wildcards may be used in +mailbox+: '*', which matches - # all characters *including* the hierarchy delimiter (for instance, - # '/' on a UNIX-hosted directory-based mailbox hierarchy); and '%', - # which matches all characters *except* the hierarchy delimiter. - # - # If +refname+ is empty, +mailbox+ is used directly to determine - # which mailboxes to match. If +mailbox+ is empty, the root - # name of +refname+ and the hierarchy delimiter are returned. - # - # The XLIST command is like the LIST command except that the flags - # returned refer to the function of the folder/mailbox, e.g. :Sent - # - # The return value is an array of MailboxList objects. For example: - # - # imap.create("foo/bar") - # imap.create("foo/baz") - # p imap.xlist("", "foo/%") - # #=> [#, \\ - # #, \\ - # #] - # - # Related: #list, MailboxList - # - # ===== Capabilities - # - # The server's capabilities must include +XLIST+, - # a deprecated Gmail extension (replaced by +SPECIAL-USE+). - # -- - # TODO: Net::IMAP doesn't yet have full SPECIAL-USE support. Supporting - # servers MAY return SPECIAL-USE attributes, but are not *required* to - # unless the SPECIAL-USE return option is supplied. - # ++ - # - # source://net-imap//lib/net/imap.rb#1315 - def xlist(refname, mailbox); end - - private - - # source://net-imap//lib/net/imap.rb#2301 - def copy_internal(cmd, set, mailbox); end - - # source://net-imap//lib/net/imap.rb#2340 - def create_ssl_params(certs = T.unsafe(nil), verify = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap.rb#2269 - def fetch_internal(cmd, set, attr, mod = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap.rb#2233 - def generate_tag; end - - # source://net-imap//lib/net/imap.rb#2178 - def get_response; end - - # source://net-imap//lib/net/imap.rb#2151 - def get_tagged_response(tag, cmd, timeout = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap.rb#2329 - def normalize_searching_criteria(keys); end - - # source://net-imap//lib/net/imap.rb#2238 - def put_string(str); end - - # source://net-imap//lib/net/imap.rb#2080 - def receive_responses; end - - # source://net-imap//lib/net/imap.rb#2198 - def record_response(name, data); end - - # source://net-imap//lib/net/imap.rb#2253 - def search_internal(cmd, keys, charset); end - - # source://net-imap//lib/net/imap.rb#2205 - def send_command(cmd, *args, &block); end - - # source://net-imap//lib/net/imap/command_data.rb#33 - def send_data(data, tag = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap/command_data.rb#108 - def send_date_data(date); end - - # source://net-imap//lib/net/imap/command_data.rb#94 - def send_list_data(list, tag = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap/command_data.rb#73 - def send_literal(str, tag = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap/command_data.rb#90 - def send_number_data(num); end - - # source://net-imap//lib/net/imap/command_data.rb#69 - def send_quoted_string(str); end - - # source://net-imap//lib/net/imap/command_data.rb#54 - def send_string_data(str, tag = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap/command_data.rb#111 - def send_symbol_data(symbol); end - - # source://net-imap//lib/net/imap/command_data.rb#109 - def send_time_data(time); end - - # source://net-imap//lib/net/imap.rb#2305 - def sort_internal(cmd, sort_keys, search_keys, charset); end - - # source://net-imap//lib/net/imap.rb#2357 - def start_tls_session(params = T.unsafe(nil)); end - - # source://net-imap//lib/net/imap.rb#2290 - def store_internal(cmd, set, attr, flags); end - - # source://net-imap//lib/net/imap.rb#2071 - def tcp_socket(host, port); end - - # source://net-imap//lib/net/imap.rb#2318 - def thread_internal(cmd, algorithm, search_keys, charset); end - - # source://net-imap//lib/net/imap/command_data.rb#12 - def validate_data(data); end - - class << self - # Returns the debug mode. - # - # source://net-imap//lib/net/imap.rb#740 - def debug; end - - # Sets the debug mode. - # - # source://net-imap//lib/net/imap.rb#745 - def debug=(val); end - - # :call-seq: decode_date(string) -> Date - # - # Decodes +string+ as an IMAP formatted "date". - # - # Double quotes are optional. Day of month may be padded with zero or - # space. See STRFDATE. - # - # source://net-imap//lib/net/imap/data_encoding.rb#89 - def decode_date(string); end - - # :call-seq: decode_datetime(string) -> DateTime - # - # Decodes +string+ as an IMAP4 formatted "date-time". - # - # Note that double quotes are not optional. See STRFTIME. - # - # source://net-imap//lib/net/imap/data_encoding.rb#106 - def decode_datetime(string); end - - # :call-seq: decode_time(string) -> Time - # - # Decodes +string+ as an IMAP4 formatted "date-time". - # - # Same as +decode_datetime+, but returning a Time instead. - # - # source://net-imap//lib/net/imap/data_encoding.rb#115 - def decode_time(string); end - - # Decode a string from modified UTF-7 format to UTF-8. - # - # UTF-7 is a 7-bit encoding of Unicode [UTF7]. IMAP uses a - # slightly modified version of this to encode mailbox names - # containing non-ASCII characters; see [IMAP] section 5.1.3. - # - # Net::IMAP does _not_ automatically encode and decode - # mailbox names to and from UTF-7. - # - # source://net-imap//lib/net/imap/data_encoding.rb#56 - def decode_utf7(s); end - - # The default port for IMAP connections, port 143 - # - # source://net-imap//lib/net/imap.rb#750 - def default_imap_port; end - - # The default port for IMAPS connections, port 993 - # - # source://net-imap//lib/net/imap.rb#755 - def default_imaps_port; end - - # The default port for IMAP connections, port 143 - # - # source://net-imap//lib/net/imap.rb#750 - def default_port; end - - # The default port for IMAPS connections, port 993 - # - # source://net-imap//lib/net/imap.rb#755 - def default_ssl_port; end - - # The default port for IMAPS connections, port 993 - # - # source://net-imap//lib/net/imap.rb#755 - def default_tls_port; end - - # Formats +time+ as an IMAP4 date. - # - # source://net-imap//lib/net/imap/data_encoding.rb#79 - def encode_date(date); end - - # :call-seq: encode_datetime(time) -> string - # - # Formats +time+ as an IMAP4 date-time. - # - # source://net-imap//lib/net/imap/data_encoding.rb#97 - def encode_datetime(time); end - - # :call-seq: encode_datetime(time) -> string - # - # Formats +time+ as an IMAP4 date-time. - # - # source://net-imap//lib/net/imap/data_encoding.rb#97 - def encode_time(time); end - - # Encode a string from UTF-8 format to modified UTF-7. - # - # source://net-imap//lib/net/imap/data_encoding.rb#67 - def encode_utf7(s); end - - # Formats +time+ as an IMAP4 date. - # - # source://net-imap//lib/net/imap/data_encoding.rb#79 - def format_date(date); end - - # DEPRECATED:: The original version returned incorrectly formatted strings. - # Strings returned by encode_datetime or format_time use the - # correct IMAP4rev1 syntax for "date-time". - # - # This invalid format has been temporarily retained for backward - # compatibility. A future release will change this method to return the - # correct format. - # - # source://net-imap//lib/net/imap/data_encoding.rb#137 - def format_datetime(time); end - - # :call-seq: encode_datetime(time) -> string - # - # Formats +time+ as an IMAP4 date-time. - # - # source://net-imap//lib/net/imap/data_encoding.rb#97 - def format_time(time); end - - # :call-seq: decode_date(string) -> Date - # - # Decodes +string+ as an IMAP formatted "date". - # - # Double quotes are optional. Day of month may be padded with zero or - # space. See STRFDATE. - # - # source://net-imap//lib/net/imap/data_encoding.rb#89 - def parse_date(string); end - - # :call-seq: decode_datetime(string) -> DateTime - # - # Decodes +string+ as an IMAP4 formatted "date-time". - # - # Note that double quotes are not optional. See STRFTIME. - # - # source://net-imap//lib/net/imap/data_encoding.rb#106 - def parse_datetime(string); end - - # :call-seq: decode_time(string) -> Time - # - # Decodes +string+ as an IMAP4 formatted "date-time". - # - # Same as +decode_datetime+, but returning a Time instead. - # - # source://net-imap//lib/net/imap/data_encoding.rb#115 - def parse_time(string); end - end -end - -# Mailbox attribute indicating that this mailbox presents all messages in -# the user's message store. Implementations MAY omit some messages, such as, -# perhaps, those in \Trash and \Junk. When this special use is supported, it -# is almost certain to represent a virtual mailbox -# -# source://net-imap//lib/net/imap/flags.rb#218 -Net::IMAP::ALL = T.let(T.unsafe(nil), Symbol) - -# Mailbox attribute indicating that this mailbox is used to archive -# messages. The meaning of an "archival" mailbox is server dependent; -# typically, it will be used to get messages out of the inbox, or otherwise -# keep them out of the user's way, while still making them accessible -# -# source://net-imap//lib/net/imap/flags.rb#224 -Net::IMAP::ARCHIVE = T.let(T.unsafe(nil), Symbol) - -# source://net-imap//lib/net/imap/command_data.rb#130 -class Net::IMAP::Atom - # @return [Atom] a new instance of Atom - # - # source://net-imap//lib/net/imap/command_data.rb#140 - def initialize(data); end - - # source://net-imap//lib/net/imap/command_data.rb#131 - def send_data(imap, tag); end - - # source://net-imap//lib/net/imap/command_data.rb#135 - def validate; end -end - -# Registry for SASL authenticators used by Net::IMAP. -# -# source://net-imap//lib/net/imap/authenticators.rb#4 -module Net::IMAP::Authenticators - # Adds an authenticator for Net::IMAP#authenticate to use. +mechanism+ is the - # {SASL mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] - # implemented by +authenticator+ (for instance, "PLAIN"). - # - # The +authenticator+ must respond to +#new+ (or #call), receiving the - # authenticator configuration and return a configured authentication session. - # The authenticator session must respond to +#process+, receiving the server's - # challenge and returning the client's response. - # - # See PlainAuthenticator, XOauth2Authenticator, and DigestMD5Authenticator for - # examples. - # - # source://net-imap//lib/net/imap/authenticators.rb#17 - def add_authenticator(auth_type, authenticator); end - - # :call-seq: - # authenticator(mechanism, ...) -> authenticator - # authenticator(mech, *creds, **props) {|prop, auth| val } -> authenticator - # authenticator(mechanism, authnid, creds, authzid=nil) -> authenticator - # authenticator(mechanism, **properties) -> authenticator - # authenticator(mechanism) {|propname, authctx| value } -> authenticator - # - # Builds a new authentication session context for +mechanism+. - # - # [Note] - # This method is intended for internal use by connection protocol code only. - # Protocol client users should see refer to their client's documentation, - # e.g. Net::IMAP#authenticate for Net::IMAP. - # - # The call signatures documented for this method are recommendations for - # authenticator implementors. All arguments (other than +mechanism+) are - # forwarded to the registered authenticator's +#new+ (or +#call+) method, and - # each authenticator must document its own arguments. - # - # The returned object represents a single authentication exchange and must - # not be reused for multiple authentication attempts. - # - # source://net-imap//lib/net/imap/authenticators.rb#42 - def authenticator(mechanism, *authargs, **properties, &callback); end - - private - - # source://net-imap//lib/net/imap/authenticators.rb#55 - def authenticators; end -end - -# Net::IMAP::BodyStructure is included by all of the structs that can be -# returned from a "BODYSTRUCTURE" or "BODY" -# FetchData#attr value. Although these classes don't share a base class, -# this module can be used to pattern match all of them. -# -# See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] -# and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] -# for full description of all +BODYSTRUCTURE+ fields, and also -# Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. -# -# === Classes that include BodyStructure -# BodyTypeBasic:: Represents any message parts that are not handled by -# BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. -# BodyTypeText:: Used by text/* parts. Contains all of the -# BodyTypeBasic fields. -# BodyTypeMessage:: Used by message/rfc822 and -# message/global parts. Contains all of the -# BodyTypeBasic fields. Other message/* types -# should use BodyTypeBasic. -# BodyTypeMultipart:: for multipart/* parts -# -# ==== Deprecated BodyStructure classes -# The following classes represent invalid server responses or parser bugs: -# BodyTypeExtension:: parser bug: used for message/* where -# BodyTypeBasic should have been used. -# BodyTypeAttachment:: server bug: some servers sometimes return the -# "Content-Disposition: attachment" data where the -# entire body structure for a message part is expected. -# -# source://net-imap//lib/net/imap/response_data.rb#901 -module Net::IMAP::BodyStructure; end - -# === WARNING -# BodyTypeAttachment represents a body-fld-dsp that is -# incorrectly in a position where the IMAP4rev1 grammar expects a nested -# +body+ structure. -# -# >>> -# \IMAP body structures are parenthesized lists and assign their fields -# positionally, so missing fields change the intepretation of all -# following fields. Buggy \IMAP servers sometimes leave fields missing -# rather than empty, which inevitably confuses parsers. -# BodyTypeAttachment was an attempt to parse a common type of buggy body -# structure without crashing. -# -# Currently, when Net::IMAP::ResponseParser sees "attachment" as the first -# entry in a body-type-1part, which is where the MIME type should -# be, it uses BodyTypeAttachment to capture the rest. "attachment" is not -# a valid MIME type, but _is_ a common Content-Disposition. What -# might have happened was that buggy server could not parse the message -# (which might have been incorrectly formatted) and output a -# body-type-dsp where a Net::IMAP::ResponseParser expected to see -# a +body+. -# -# A future release will replace this, probably with a ContentDisposition -# nested inside another body structure object, maybe BodyTypeBasic, or -# perhaps a new body structure class that represents any unparsable body -# structure. -# -# source://net-imap//lib/net/imap/response_data.rb#1156 -class Net::IMAP::BodyTypeAttachment < ::Struct - include ::Net::IMAP::BodyStructure - - # *invalid for BodyTypeAttachment* - # - # source://net-imap//lib/net/imap/response_data.rb#1160 - def media_type; end - - # @return [Boolean] - # - # source://net-imap//lib/net/imap/response_data.rb#1188 - def multipart?; end - - # *invalid for BodyTypeAttachment* - # - # source://net-imap//lib/net/imap/response_data.rb#1168 - def subtype; end -end - -# Net::IMAP::BodyTypeBasic represents basic body structures of messages and -# message parts, unless they have a Content-Type that is handled by -# BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. -# -# See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] -# and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] -# for full description of all +BODYSTRUCTURE+ fields, and also -# Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. -# -# source://net-imap//lib/net/imap/response_data.rb#917 -class Net::IMAP::BodyTypeBasic < ::Struct - include ::Net::IMAP::BodyStructure - - # :call-seq: media_subtype -> subtype - # - # >>> - # [Obsolete] - # Use +subtype+ instead. Calling this will generate a warning message - # to +stderr+, then return the value of +subtype+. - # -- - # TODO: why not just keep this as an alias? Would "media_subtype" be used - # for something else? - # ++ - # - # source://net-imap//lib/net/imap/response_data.rb#1028 - def media_subtype; end - - # :call-seq: multipart? -> false - # - # BodyTypeBasic is not used for multipart MIME parts. - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/response_data.rb#1014 - def multipart?; end -end - -# === WARNING: -# >>> -# BodyTypeExtension is (incorrectly) used for message/* parts -# (besides message/rfc822, which correctly uses BodyTypeMessage). -# -# A future release will replace this class with: -# * BodyTypeMessage for message/rfc822 and message/global -# * BodyTypeBasic for any other message/* -# -# source://net-imap//lib/net/imap/response_data.rb#1278 -class Net::IMAP::BodyTypeExtension < ::Struct - include ::Net::IMAP::BodyStructure - - # @return [Boolean] - # - # source://net-imap//lib/net/imap/response_data.rb#1281 - def multipart?; end -end - -# Net::IMAP::BodyTypeMessage represents the body structures of messages and -# message parts, when Content-Type is message/rfc822 or -# message/global. -# -# BodyTypeMessage contains all of the fields of BodyTypeBasic. See -# BodyTypeBasic for documentation of the following fields: -# * {media_type}[rdoc-ref:BodyTypeBasic#media_type] -# * subtype[rdoc-ref:BodyTypeBasic#subtype] -# * param[rdoc-ref:BodyTypeBasic#param] -# * {content_id}[rdoc-ref:BodyTypeBasic#content_id] -# * description[rdoc-ref:BodyTypeBasic#description] -# * encoding[rdoc-ref:BodyTypeBasic#encoding] -# * size[rdoc-ref:BodyTypeBasic#size] -# -# source://net-imap//lib/net/imap/response_data.rb#1097 -class Net::IMAP::BodyTypeMessage < ::Struct - include ::Net::IMAP::BodyStructure - - # Obsolete: use +subtype+ instead. Calling this will - # generate a warning message to +stderr+, then return - # the value of +subtype+. - # - # source://net-imap//lib/net/imap/response_data.rb#1123 - def media_subtype; end - - # :call-seq: multipart? -> false - # - # BodyTypeMessage is not used for multipart MIME parts. - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/response_data.rb#1116 - def multipart?; end -end - -# Net::IMAP::BodyTypeMultipart represents body structures of messages and -# message parts, when Content-Type is multipart/*. -# -# source://net-imap//lib/net/imap/response_data.rb#1198 -class Net::IMAP::BodyTypeMultipart < ::Struct - include ::Net::IMAP::BodyStructure - - # Obsolete: use +subtype+ instead. Calling this will - # generate a warning message to +stderr+, then return - # the value of +subtype+. - # - # source://net-imap//lib/net/imap/response_data.rb#1262 - def media_subtype; end - - # :call-seq: multipart? -> true - # - # BodyTypeMultipart is used for multipart MIME parts. - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/response_data.rb#1254 - def multipart?; end -end - -# Net::IMAP::BodyTypeText represents the body structures of messages and -# message parts, when Content-Type is text/*. -# -# BodyTypeText contains all of the fields of BodyTypeBasic. See -# BodyTypeBasic for documentation of the following: -# * {media_type}[rdoc-ref:BodyTypeBasic#media_type] -# * subtype[rdoc-ref:BodyTypeBasic#subtype] -# * param[rdoc-ref:BodyTypeBasic#param] -# * {content_id}[rdoc-ref:BodyTypeBasic#content_id] -# * description[rdoc-ref:BodyTypeBasic#description] -# * encoding[rdoc-ref:BodyTypeBasic#encoding] -# * size[rdoc-ref:BodyTypeBasic#size] -# -# source://net-imap//lib/net/imap/response_data.rb#1052 -class Net::IMAP::BodyTypeText < ::Struct - include ::Net::IMAP::BodyStructure - - # Obsolete: use +subtype+ instead. Calling this will - # generate a warning message to +stderr+, then return - # the value of +subtype+. - # - # source://net-imap//lib/net/imap/response_data.rb#1072 - def media_subtype; end - - # :call-seq: multipart? -> false - # - # BodyTypeText is not used for multipart MIME parts. - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/response_data.rb#1065 - def multipart?; end -end - -# source://net-imap//lib/net/imap/command_data.rb#231 -class Net::IMAP::ClientID - # @return [ClientID] a new instance of ClientID - # - # source://net-imap//lib/net/imap/command_data.rb#243 - def initialize(data); end - - # source://net-imap//lib/net/imap/command_data.rb#233 - def send_data(imap, tag); end - - # source://net-imap//lib/net/imap/command_data.rb#237 - def validate; end - - private - - # source://net-imap//lib/net/imap/command_data.rb#257 - def format_internal(client_id); end - - # source://net-imap//lib/net/imap/command_data.rb#247 - def validate_internal(client_id); end -end - -# Authenticator for the "+CRAM-MD5+" SASL mechanism, specified in -# RFC2195[https://tools.ietf.org/html/rfc2195]. See Net::IMAP#authenticate. -# -# == Deprecated -# -# +CRAM-MD5+ is obsolete and insecure. It is included for compatibility with -# existing servers. -# {draft-ietf-sasl-crammd5-to-historic}[https://tools.ietf.org/html/draft-ietf-sasl-crammd5-to-historic-00.html] -# recommends using +SCRAM-*+ or +PLAIN+ protected by TLS instead. -# -# Additionally, RFC8314[https://tools.ietf.org/html/rfc8314] discourage the use -# of cleartext and recommends TLS version 1.2 or greater be used for all -# traffic. With TLS +CRAM-MD5+ is okay, but so is +PLAIN+ -# -# source://net-imap//lib/net/imap/authenticators/cram_md5.rb#16 -class Net::IMAP::CramMD5Authenticator - # @return [CramMD5Authenticator] a new instance of CramMD5Authenticator - # - # source://net-imap//lib/net/imap/authenticators/cram_md5.rb#24 - def initialize(user, password, warn_deprecation: T.unsafe(nil), **_ignored); end - - # source://net-imap//lib/net/imap/authenticators/cram_md5.rb#17 - def process(challenge); end - - private - - # source://net-imap//lib/net/imap/authenticators/cram_md5.rb#33 - def hmac_md5(text, key); end -end - -# Mailbox attribute indicating that this mailbox is used to hold draft -# messages -- typically, messages that are being composed but have not yet -# been sent. In some server implementations, this might be a virtual -# mailbox, containing messages from other mailboxes that are marked with the -# "\Draft" message flag. Alternatively, this might just be advice that a -# client put drafts here -# -# source://net-imap//lib/net/imap/flags.rb#232 -Net::IMAP::DRAFTS = T.let(T.unsafe(nil), Symbol) - -# Net::IMAP authenticator for the "`DIGEST-MD5`" SASL mechanism type, specified -# in RFC2831(https://tools.ietf.org/html/rfc2831). See Net::IMAP#authenticate. -# -# == Deprecated -# -# "+DIGEST-MD5+" has been deprecated by -# {RFC6331}[https://tools.ietf.org/html/rfc6331] and should not be relied on for -# security. It is included for compatibility with existing servers. -# -# source://net-imap//lib/net/imap/authenticators/digest_md5.rb#11 -class Net::IMAP::DigestMD5Authenticator - # @return [DigestMD5Authenticator] a new instance of DigestMD5Authenticator - # - # source://net-imap//lib/net/imap/authenticators/digest_md5.rb#77 - def initialize(user, password, authname = T.unsafe(nil), warn_deprecation: T.unsafe(nil)); end - - # source://net-imap//lib/net/imap/authenticators/digest_md5.rb#12 - def process(challenge); end - - private - - # source://net-imap//lib/net/imap/authenticators/digest_md5.rb#94 - def nc(nonce); end - - # some responses need quoting - # - # source://net-imap//lib/net/imap/authenticators/digest_md5.rb#104 - def qdval(k, v); end -end - -# Alias for HAS_CHILDREN, to match the \IMAP spelling. -# -# source://net-imap//lib/net/imap/flags.rb#183 -Net::IMAP::HASCHILDREN = T.let(T.unsafe(nil), Symbol) - -# Alias for HAS_NO_CHILDREN, to match the \IMAP spelling. -# -# source://net-imap//lib/net/imap/flags.rb#185 -Net::IMAP::HASNOCHILDREN = T.let(T.unsafe(nil), Symbol) - -# The presence of this attribute indicates that the mailbox has child -# mailboxes. A server SHOULD NOT set this attribute if there are child -# mailboxes and the user does not have permission to access any of them. In -# this case, +\HasNoChildren+ SHOULD be used. In many cases, however, a -# server may not be able to efficiently compute whether a user has access to -# any child mailboxes. Note that even though the +\HasChildren+ attribute -# for a mailbox must be correct at the time of processing the mailbox, a -# client must be prepared to deal with a situation when a mailbox is marked -# with the +\HasChildren+ attribute, but no child mailbox appears in the -# response to the #list command. This might happen, for example, due to child -# mailboxes being deleted or made inaccessible to the user (using access -# control) by another client before the server is able to list them. -# -# It is an error for the server to return both a +\HasChildren+ and a -# +\HasNoChildren+ attribute in the same #list response. A client that -# encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ -# attributes present should act as if both are absent in the #list response. -# -# source://net-imap//lib/net/imap/flags.rb#136 -Net::IMAP::HAS_CHILDREN = T.let(T.unsafe(nil), Symbol) - -# The presence of this attribute indicates that the mailbox has NO child -# mailboxes that are accessible to the currently authenticated user. -# -# It is an error for the server to return both a +\HasChildren+ and a -# +\HasNoChildren+ attribute in the same #list response. A client that -# encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ -# attributes present should act as if both are absent in the #list response. -# -# Note: the +\HasNoChildren+ attribute should not be confused with the -# +\NoInferiors+ attribute, which indicates that no child mailboxes exist -# now and none can be created in the future. -# -# source://net-imap//lib/net/imap/flags.rb#149 -Net::IMAP::HAS_NO_CHILDREN = T.let(T.unsafe(nil), Symbol) - -# Net::IMAP::IgnoredResponse represents intentionally ignored responses. -# -# This includes untagged response "NOOP" sent by eg. Zimbra to avoid some -# clients to close the connection. -# -# It matches no IMAP standard. -# -# source://net-imap//lib/net/imap/response_data.rb#63 -class Net::IMAP::IgnoredResponse < ::Struct; end - -# Mailbox attribute indicating that this mailbox is where messages deemed to -# be junk mail are held. Some server implementations might put messages here -# automatically. Alternatively, this might just be advice to a client-side -# spam filter. -# -# source://net-imap//lib/net/imap/flags.rb#242 -Net::IMAP::JUNK = T.let(T.unsafe(nil), Symbol) - -# source://net-imap//lib/net/imap/command_data.rb#160 -class Net::IMAP::Literal - # @return [Literal] a new instance of Literal - # - # source://net-imap//lib/net/imap/command_data.rb#170 - def initialize(data); end - - # source://net-imap//lib/net/imap/command_data.rb#161 - def send_data(imap, tag); end - - # source://net-imap//lib/net/imap/command_data.rb#165 - def validate; end -end - -# Authenticator for the "+LOGIN+" SASL mechanism. See Net::IMAP#authenticate. -# -# +LOGIN+ authentication sends the password in cleartext. -# RFC3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable -# cleartext authentication until after TLS has been negotiated. -# RFC8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or -# greater be used for all traffic, and deprecate cleartext access ASAP. +LOGIN+ -# can be secured by TLS encryption. -# -# == Deprecated -# -# The {SASL mechanisms -# registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] -# marks "LOGIN" as obsoleted in favor of "PLAIN". It is included here for -# compatibility with existing servers. See -# {draft-murchison-sasl-login}[https://www.iana.org/go/draft-murchison-sasl-login] -# for both specification and deprecation. -# -# source://net-imap//lib/net/imap/authenticators/login.rb#20 -class Net::IMAP::LoginAuthenticator - # @return [LoginAuthenticator] a new instance of LoginAuthenticator - # - # source://net-imap//lib/net/imap/authenticators/login.rb#36 - def initialize(user, password, warn_deprecation: T.unsafe(nil), **_ignored); end - - # source://net-imap//lib/net/imap/authenticators/login.rb#21 - def process(data); end -end - -# source://net-imap//lib/net/imap/command_data.rb#175 -class Net::IMAP::MessageSet - # @return [MessageSet] a new instance of MessageSet - # - # source://net-imap//lib/net/imap/command_data.rb#186 - def initialize(data); end - - # source://net-imap//lib/net/imap/command_data.rb#176 - def send_data(imap, tag); end - - # source://net-imap//lib/net/imap/command_data.rb#180 - def validate; end - - private - - # source://net-imap//lib/net/imap/command_data.rb#190 - def format_internal(data); end - - # source://net-imap//lib/net/imap/command_data.rb#211 - def validate_internal(data); end -end - -# The +\NonExistent+ attribute indicates that a mailbox name does not refer -# to an existing mailbox. Note that this attribute is not meaningful by -# itself, as mailbox names that match the canonical #list pattern but don't -# exist must not be returned unless one of the two conditions listed below -# is also satisfied: -# -# 1. The mailbox name also satisfies the selection criteria (for example, -# it is subscribed and the "SUBSCRIBED" selection option has been -# specified). -# -# 2. "RECURSIVEMATCH" has been specified, and the mailbox name has at least -# one descendant mailbox name that does not match the #list pattern and -# does match the selection criteria. -# -# In practice, this means that the +\NonExistent+ attribute is usually -# returned with one or more of +\Subscribed+, +\Remote+, +\HasChildren+, or -# the CHILDINFO extended data item. -# -# The client must treat the presence of the +\NonExistent+ attribute as if the -# +\NoSelect+ attribute was also sent by the server -# -# source://net-imap//lib/net/imap/flags.rb#105 -Net::IMAP::NONEXISTENT = T.let(T.unsafe(nil), Symbol) - -# Mailbox attribute indicating it is not possible for any child levels of -# hierarchy to exist under this name; no child levels exist now and none can -# be created in the future children. -# -# The client must treat the presence of the +\NoInferiors+ attribute as if the -# +\HasNoChildren+ attribute was also sent by the server -# -# source://net-imap//lib/net/imap/flags.rb#113 -Net::IMAP::NO_INFERIORS = T.let(T.unsafe(nil), Symbol) - -# Mailbox attribute indicating it is not possible to use this name as a -# selectable mailbox. -# -# source://net-imap//lib/net/imap/flags.rb#117 -Net::IMAP::NO_SELECT = T.let(T.unsafe(nil), Symbol) - -# Net::IMAP::Namespace represents a single namespace contained inside a -# NAMESPACE response. -# -# Returned by Net::IMAP#namespace, contained inside a Namespaces object. -# -# source://net-imap//lib/net/imap/response_data.rb#387 -class Net::IMAP::Namespace < ::Struct; end - -# Net::IMAP::Namespaces represents a +NAMESPACE+ server response, which -# contains lists of #personal, #shared, and #other namespaces. -# -# Net::IMAP#namespace returns a Namespaces object. -# -# source://net-imap//lib/net/imap/response_data.rb#413 -class Net::IMAP::Namespaces < ::Struct; end - -# Common validators of number and nz_number types -# -# source://net-imap//lib/net/imap/data_encoding.rb#145 -module Net::IMAP::NumValidator - private - - # Ensure argument is 'mod_sequence_value' or raise DataFormatError - # - # source://net-imap//lib/net/imap/data_encoding.rb#192 - def ensure_mod_sequence_value(num); end - - # Ensure argument is 'number' or raise DataFormatError - # - # source://net-imap//lib/net/imap/data_encoding.rb#176 - def ensure_number(num); end - - # Ensure argument is 'nz_number' or raise DataFormatError - # - # source://net-imap//lib/net/imap/data_encoding.rb#184 - def ensure_nz_number(num); end - - # Check is passed argument valid 'mod_sequence_value' in RFC 4551 terminology - # - # source://net-imap//lib/net/imap/data_encoding.rb#167 - def valid_mod_sequence_value?(num); end - - # Check is passed argument valid 'number' in RFC 3501 terminology - # - # source://net-imap//lib/net/imap/data_encoding.rb#149 - def valid_number?(num); end - - # Check is passed argument valid 'nz_number' in RFC 3501 terminology - # - # source://net-imap//lib/net/imap/data_encoding.rb#158 - def valid_nz_number?(num); end - - class << self - # Ensure argument is 'mod_sequence_value' or raise DataFormatError - # - # @raise [DataFormatError] - # - # source://net-imap//lib/net/imap/data_encoding.rb#192 - def ensure_mod_sequence_value(num); end - - # Ensure argument is 'number' or raise DataFormatError - # - # @raise [DataFormatError] - # - # source://net-imap//lib/net/imap/data_encoding.rb#176 - def ensure_number(num); end - - # Ensure argument is 'nz_number' or raise DataFormatError - # - # @raise [DataFormatError] - # - # source://net-imap//lib/net/imap/data_encoding.rb#184 - def ensure_nz_number(num); end - - # Check is passed argument valid 'mod_sequence_value' in RFC 4551 terminology - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/data_encoding.rb#167 - def valid_mod_sequence_value?(num); end - - # Check is passed argument valid 'number' in RFC 3501 terminology - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/data_encoding.rb#149 - def valid_number?(num); end - - # Check is passed argument valid 'nz_number' in RFC 3501 terminology - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/data_encoding.rb#158 - def valid_nz_number?(num); end - end -end - -# Authenticator for the "+PLAIN+" SASL mechanism, specified in -# RFC4616[https://tools.ietf.org/html/rfc4616]. See Net::IMAP#authenticate. -# -# +PLAIN+ authentication sends the password in cleartext. -# RFC3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable -# cleartext authentication until after TLS has been negotiated. -# RFC8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or -# greater be used for all traffic, and deprecate cleartext access ASAP. +PLAIN+ -# can be secured by TLS encryption. -# -# source://net-imap//lib/net/imap/authenticators/plain.rb#12 -class Net::IMAP::PlainAuthenticator - # +username+ is the authentication identity, the identity whose +password+ is - # used. +username+ is referred to as +authcid+ by - # RFC4616[https://tools.ietf.org/html/rfc4616]. - # - # +authzid+ is the authorization identity (identity to act as). It can - # usually be left blank. When +authzid+ is left blank (nil or empty string) - # the server will derive an identity from the credentials and use that as the - # authorization identity. - # - # @raise [ArgumentError] - # @return [PlainAuthenticator] a new instance of PlainAuthenticator - # - # source://net-imap//lib/net/imap/authenticators/plain.rb#31 - def initialize(username, password, authzid: T.unsafe(nil)); end - - # source://net-imap//lib/net/imap/authenticators/plain.rb#14 - def process(data); end -end - -# source://net-imap//lib/net/imap/authenticators/plain.rb#19 -Net::IMAP::PlainAuthenticator::NULL = T.let(T.unsafe(nil), String) - -# source://net-imap//lib/net/imap/command_data.rb#145 -class Net::IMAP::QuotedString - # @return [QuotedString] a new instance of QuotedString - # - # source://net-imap//lib/net/imap/command_data.rb#155 - def initialize(data); end - - # source://net-imap//lib/net/imap/command_data.rb#146 - def send_data(imap, tag); end - - # source://net-imap//lib/net/imap/command_data.rb#150 - def validate; end -end - -# The mailbox is a remote mailbox. -# -# source://net-imap//lib/net/imap/flags.rb#176 -Net::IMAP::REMOTE = T.let(T.unsafe(nil), Symbol) - -# source://net-imap//lib/net/imap/errors.rb#54 -Net::IMAP::RESPONSE_ERRORS = T.let(T.unsafe(nil), Hash) - -# source://net-imap//lib/net/imap/command_data.rb#115 -class Net::IMAP::RawData - # @return [RawData] a new instance of RawData - # - # source://net-imap//lib/net/imap/command_data.rb#125 - def initialize(data); end - - # source://net-imap//lib/net/imap/command_data.rb#116 - def send_data(imap, tag); end - - # source://net-imap//lib/net/imap/command_data.rb#120 - def validate; end -end - -# Superclass of all errors used to encapsulate "fail" responses -# from the server. -# -# source://net-imap//lib/net/imap/errors.rb#20 -class Net::IMAP::ResponseError < ::Net::IMAP::Error - # @return [ResponseError] a new instance of ResponseError - # - # source://net-imap//lib/net/imap/errors.rb#25 - def initialize(response); end - - # The response that caused this error - # - # source://net-imap//lib/net/imap/errors.rb#23 - def response; end - - # The response that caused this error - # - # source://net-imap//lib/net/imap/errors.rb#23 - def response=(_arg0); end -end - -# Parses an \IMAP server response. -# -# source://net-imap//lib/net/imap/response_parser.rb#9 -class Net::IMAP::ResponseParser - # :call-seq: Net::IMAP::ResponseParser.new -> Net::IMAP::ResponseParser - # - # @return [ResponseParser] a new instance of ResponseParser - # - # source://net-imap//lib/net/imap/response_parser.rb#11 - def initialize; end - - # :call-seq: - # parse(str) -> ContinuationRequest - # parse(str) -> UntaggedResponse - # parse(str) -> TaggedResponse - # - # Raises ResponseParseError for unparsable strings. - # - # source://net-imap//lib/net/imap/response_parser.rb#24 - def parse(str); end - - private - - # like match, but does not raise error on failure. - # - # returns and shifts token on successful match - # returns nil and leaves @token unshifted on no match - # - # source://net-imap//lib/net/imap/response_parser.rb#1440 - def accept(*args); end - - # This advances @pos directly so it's safe before changing @lex_state. - # - # source://net-imap//lib/net/imap/response_parser.rb#1397 - def accept_space; end - - # The RFC is very strict about this and usually we should be too. - # But skipping spaces is usually a safe workaround for buggy servers. - # - # This advances @pos directly so it's safe before changing @lex_state. - # - # source://net-imap//lib/net/imap/response_parser.rb#1409 - def accept_spaces; end - - # source://net-imap//lib/net/imap/response_parser.rb#1223 - def address; end - - # source://net-imap//lib/net/imap/response_parser.rb#1193 - def address_list; end - - # source://net-imap//lib/net/imap/response_parser.rb#1279 - def astring; end - - # source://net-imap//lib/net/imap/response_parser.rb#1332 - def astring_chars; end - - # source://net-imap//lib/net/imap/response_parser.rb#1324 - def atom; end - - # source://net-imap//lib/net/imap/response_parser.rb#336 - def body; end - - # source://net-imap//lib/net/imap/response_parser.rb#317 - def body_data; end - - # source://net-imap//lib/net/imap/response_parser.rb#523 - def body_ext_1part; end - - # source://net-imap//lib/net/imap/response_parser.rb#559 - def body_ext_mpart; end - - # source://net-imap//lib/net/imap/response_parser.rb#649 - def body_extension; end - - # source://net-imap//lib/net/imap/response_parser.rb#635 - def body_extensions; end - - # source://net-imap//lib/net/imap/response_parser.rb#485 - def body_fields; end - - # source://net-imap//lib/net/imap/response_parser.rb#595 - def body_fld_dsp; end - - # source://net-imap//lib/net/imap/response_parser.rb#609 - def body_fld_lang; end - - # source://net-imap//lib/net/imap/response_parser.rb#498 - def body_fld_param; end - - # source://net-imap//lib/net/imap/response_parser.rb#356 - def body_type_1part; end - - # source://net-imap//lib/net/imap/response_parser.rb#442 - def body_type_attachment; end - - # source://net-imap//lib/net/imap/response_parser.rb#372 - def body_type_basic; end - - # source://net-imap//lib/net/imap/response_parser.rb#449 - def body_type_mixed; end - - # source://net-imap//lib/net/imap/response_parser.rb#456 - def body_type_mpart; end - - # source://net-imap//lib/net/imap/response_parser.rb#401 - def body_type_msg; end - - # source://net-imap//lib/net/imap/response_parser.rb#387 - def body_type_text; end - - # source://net-imap//lib/net/imap/response_parser.rb#977 - def capability_data; end - - # source://net-imap//lib/net/imap/response_parser.rb#970 - def capability_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#1304 - def case_insensitive_string; end - - # See https://www.rfc-editor.org/errata/rfc3501 - # - # charset = atom / quoted - # - # source://net-imap//lib/net/imap/response_parser.rb#1351 - def charset; end - - # source://net-imap//lib/net/imap/response_parser.rb#1152 - def charset_list; end - - # source://net-imap//lib/net/imap/response_parser.rb#1336 - def combine_adjacent(*tokens); end - - # source://net-imap//lib/net/imap/response_parser.rb#118 - def continue_req; end - - # source://net-imap//lib/net/imap/response_parser.rb#248 - def envelope; end - - # source://net-imap//lib/net/imap/response_parser.rb#241 - def envelope_data; end - - # source://net-imap//lib/net/imap/response_parser.rb#1254 - def flag_list; end - - # source://net-imap//lib/net/imap/response_parser.rb#283 - def flags_data; end - - # source://net-imap//lib/net/imap/response_parser.rb#746 - def flags_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#699 - def format_string(str); end - - # source://net-imap//lib/net/imap/response_parser.rb#824 - def getacl_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#774 - def getquota_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#807 - def getquotaroot_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#993 - def id_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#732 - def ignored_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#290 - def internaldate_data; end - - # source://net-imap//lib/net/imap/response_parser.rb#753 - def list_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#1448 - def lookahead; end - - # source://net-imap//lib/net/imap/response_parser.rb#760 - def mailbox_list; end - - # source://net-imap//lib/net/imap/response_parser.rb#1416 - def match(*args, lex_state: T.unsafe(nil)); end - - # source://net-imap//lib/net/imap/response_parser.rb#474 - def media_type; end - - # source://net-imap//lib/net/imap/response_parser.rb#722 - def modseq_data; end - - # source://net-imap//lib/net/imap/response_parser.rb#203 - def msg_att(n); end - - # source://net-imap//lib/net/imap/response_parser.rb#1056 - def namespace; end - - # source://net-imap//lib/net/imap/response_parser.rb#1022 - def namespace_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#1066 - def namespace_response_extensions; end - - # source://net-imap//lib/net/imap/response_parser.rb#1038 - def namespaces; end - - # source://net-imap//lib/net/imap/response_parser.rb#1456 - def next_token; end - - # source://net-imap//lib/net/imap/response_parser.rb#1389 - def nil_atom; end - - # source://net-imap//lib/net/imap/response_parser.rb#1269 - def nstring; end - - # source://net-imap//lib/net/imap/response_parser.rb#1359 - def number; end - - # source://net-imap//lib/net/imap/response_parser.rb#187 - def numeric_response; end - - # @raise [ResponseParseError] - # - # source://net-imap//lib/net/imap/response_parser.rb#1575 - def parse_error(fmt, *args); end - - # already matched: "APPENDUID" - # - # +UIDPLUS+ ABNF:: https://www.rfc-editor.org/rfc/rfc4315.html#section-4 - # resp-code-apnd = "APPENDUID" SP nz-number SP append-uid - # append-uid = uniqueid - # append-uid =/ uid-set - # ; only permitted if client uses [MULTIAPPEND] - # ; to append multiple messages. - # - # n.b, uniqueid ⊂ uid-set. To avoid inconsistent return types, we always - # match uid_set even if that returns a single-member array. - # - # source://net-imap//lib/net/imap/response_parser.rb#1177 - def resp_code_apnd__data; end - - # already matched: "COPYUID" - # - # resp-code-copy = "COPYUID" SP nz-number SP uid-set SP uid-set - # - # source://net-imap//lib/net/imap/response_parser.rb#1186 - def resp_code_copy__data; end - - # resp-text = ["[" resp-text-code "]" SP] text - # - # source://net-imap//lib/net/imap/response_parser.rb#1092 - def resp_text; end - - # See https://www.rfc-editor.org/errata/rfc3501 - # - # resp-text-code = "ALERT" / - # "BADCHARSET" [SP "(" charset *(SP charset) ")" ] / - # capability-data / "PARSE" / - # "PERMANENTFLAGS" SP "(" - # [flag-perm *(SP flag-perm)] ")" / - # "READ-ONLY" / "READ-WRITE" / "TRYCREATE" / - # "UIDNEXT" SP nz-number / "UIDVALIDITY" SP nz-number / - # "UNSEEN" SP nz-number / - # atom [SP 1*] - # - # +UIDPLUS+ ABNF:: https://www.rfc-editor.org/rfc/rfc4315.html#section-4 - # resp-text-code =/ resp-code-apnd / resp-code-copy / "UIDNOTSTICKY" - # - # source://net-imap//lib/net/imap/response_parser.rb#1119 - def resp_text_code; end - - # source://net-imap//lib/net/imap/response_parser.rb#99 - def response; end - - # source://net-imap//lib/net/imap/response_parser.rb#180 - def response_cond; end - - # source://net-imap//lib/net/imap/response_parser.rb#171 - def response_tagged; end - - # source://net-imap//lib/net/imap/response_parser.rb#129 - def response_untagged; end - - # source://net-imap//lib/net/imap/response_parser.rb#310 - def rfc822_size; end - - # source://net-imap//lib/net/imap/response_parser.rb#298 - def rfc822_text; end - - # source://net-imap//lib/net/imap/response_parser.rb#850 - def search_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#664 - def section; end - - # source://net-imap//lib/net/imap/response_parser.rb#1452 - def shift_token; end - - # source://net-imap//lib/net/imap/response_parser.rb#943 - def status_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#1288 - def string; end - - # @return [Boolean] - # - # source://net-imap//lib/net/imap/response_parser.rb#1300 - def string_token?(token); end - - # text = 1*TEXT-CHAR - # TEXT-CHAR = - # - # source://net-imap//lib/net/imap/response_parser.rb#1087 - def text; end - - # source://net-imap//lib/net/imap/response_parser.rb#739 - def text_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#908 - def thread_branch(token); end - - # source://net-imap//lib/net/imap/response_parser.rb#881 - def thread_response; end - - # source://net-imap//lib/net/imap/response_parser.rb#715 - def uid_data; end - - # RFC-4315 (UIDPLUS) or RFC9051 (IMAP4rev2): - # uid-set = (uniqueid / uid-range) *("," uid-set) - # uid-range = (uniqueid ":" uniqueid) - # ; two uniqueid values and all values - # ; between these two regardless of order. - # ; Example: 2:4 and 4:2 are equivalent. - # uniqueid = nz-number - # ; Strictly ascending - # - # source://net-imap//lib/net/imap/response_parser.rb#1377 - def uid_set; end -end - -# ASTRING-CHAR = ATOM-CHAR / resp-specials -# resp-specials = "]" -# -# source://net-imap//lib/net/imap/response_parser.rb#1330 -Net::IMAP::ResponseParser::ASTRING_CHARS_TOKENS = T.let(T.unsafe(nil), Array) - -# source://net-imap//lib/net/imap/response_parser.rb#1394 -Net::IMAP::ResponseParser::SPACES_REGEXP = T.let(T.unsafe(nil), Regexp) - -# Pluggable authentication mechanisms for protocols which support SASL -# (Simple Authentication and Security Layer), such as IMAP4, SMTP, LDAP, and -# XMPP. {RFC-4422}[https://tools.ietf.org/html/rfc4422] specifies the -# common SASL framework and the +EXTERNAL+ mechanism, and the -# {SASL mechanism registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] -# lists the specification for others. -# -# "SASL is conceptually a framework that provides an abstraction layer -# between protocols and mechanisms as illustrated in the following diagram." -# -# SMTP LDAP XMPP Other protocols ... -# \ | | / -# \ | | / -# SASL abstraction layer -# / | | \ -# / | | \ -# EXTERNAL GSSAPI PLAIN Other mechanisms ... -# -# source://net-imap//lib/net/imap/sasl.rb#24 -module Net::IMAP::SASL - extend ::Net::IMAP::SASL - - # See SASLprep#saslprep. - # - # source://net-imap//lib/net/imap/sasl.rb#69 - def saslprep(string, **opts); end -end - -# StringPrepError raised when +string+ contains bidirectional characters -# which violate the StringPrep requirements. -# -# source://net-imap//lib/net/imap/sasl.rb#59 -class Net::IMAP::SASL::BidiStringError < ::Net::IMAP::SASL::StringPrepError; end - -# StringPrepError raised when +string+ contains a codepoint prohibited by -# +table+. -# -# source://net-imap//lib/net/imap/sasl.rb#45 -class Net::IMAP::SASL::ProhibitedCodepoint < ::Net::IMAP::SASL::StringPrepError - # @return [ProhibitedCodepoint] a new instance of ProhibitedCodepoint - # - # source://net-imap//lib/net/imap/sasl.rb#48 - def initialize(table, *args, **kwargs); end - - # Returns the value of attribute table. - # - # source://net-imap//lib/net/imap/sasl.rb#46 - def table; end -end - -# SASLprep#saslprep can be used to prepare a string according to [RFC4013]. -# -# \SASLprep maps characters three ways: to nothing, to space, and Unicode -# normalization form KC. \SASLprep prohibits codepoints from nearly all -# standard StringPrep tables (RFC3454, Appendix "C"), and uses \StringPrep's -# standard bidirectional characters requirements (Appendix "D"). \SASLprep -# also uses \StringPrep's definition of "Unassigned" codepoints (Appendix "A"). -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#9 -module Net::IMAP::SASL::SASLprep - private - - # Prepares a UTF-8 +string+ for comparison, using the \SASLprep profile - # RFC4013 of the StringPrep algorithm RFC3454. - # - # By default, prohibited strings will return +nil+. When +exception+ is - # +true+, a StringPrepError describing the violation will be raised. - # - # When +stored+ is +true+, "unassigned" codepoints will be prohibited. For - # \StringPrep and the \SASLprep profile, "unassigned" refers to Unicode 3.2, - # and not later versions. See RFC3454 §7 for more information. - # - # source://net-imap//lib/net/imap/sasl/saslprep.rb#31 - def saslprep(str, stored: T.unsafe(nil), exception: T.unsafe(nil)); end - - class << self - # Prepares a UTF-8 +string+ for comparison, using the \SASLprep profile - # RFC4013 of the StringPrep algorithm RFC3454. - # - # By default, prohibited strings will return +nil+. When +exception+ is - # +true+, a StringPrepError describing the violation will be raised. - # - # When +stored+ is +true+, "unassigned" codepoints will be prohibited. For - # \StringPrep and the \SASLprep profile, "unassigned" refers to Unicode 3.2, - # and not later versions. See RFC3454 §7 for more information. - # - # source://net-imap//lib/net/imap/sasl/saslprep.rb#31 - def saslprep(str, stored: T.unsafe(nil), exception: T.unsafe(nil)); end - end -end - -# Used to short-circuit strings that don't need preparation. -# -# source://net-imap//lib/net/imap/sasl/saslprep.rb#17 -Net::IMAP::SASL::SASLprep::ASCII_NO_CTRLS = T.let(T.unsafe(nil), Regexp) - -# Bidirectional Characters [StringPrep, §6] -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#68 -Net::IMAP::SASL::SASLprep::BIDI_FAILURE = T.let(T.unsafe(nil), Regexp) - -# RFC4013 §2.1 Mapping - mapped to nothing -# the "commonly mapped to nothing" characters (\StringPrep\[\"B.1\"]) -# that can be mapped to nothing. -# -# Equal to \StringPrep\[\"B.1\"]. -# Redefined here to avoid loading the StringPrep module. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#25 -Net::IMAP::SASL::SASLprep::MAP_TO_NOTHING = T.let(T.unsafe(nil), Regexp) - -# RFC4013 §2.1 Mapping - mapped to space -# * non-ASCII space characters (\StringPrep\[\"C.1.2\"]) that can be -# mapped to SPACE (U+0020), and -# -# Equal to \StringPrep\[\"C.1.2\"]. -# Redefined here to avoid loading the StringPrep module. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#17 -Net::IMAP::SASL::SASLprep::MAP_TO_SPACE = T.let(T.unsafe(nil), Regexp) - -# Matches strings prohibited by RFC4013 §2.3 and §2.4. -# -# This checks prohibited output and bidirectional characters. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#85 -Net::IMAP::SASL::SASLprep::PROHIBITED = T.let(T.unsafe(nil), Regexp) - -# Matches codepoints prohibited by RFC4013 §2.3. -# -# See TABLES_PROHIBITED. -# -# Equal to +Regexp.union+ of the TABLES_PROHIBITED tables. Redefined -# here to avoid loading the StringPrep module unless necessary. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#53 -Net::IMAP::SASL::SASLprep::PROHIBITED_OUTPUT = T.let(T.unsafe(nil), Regexp) - -# Matches codepoints prohibited by RFC4013 §2.3 and §2.5. -# -# See TABLES_PROHIBITED_STORED. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#63 -Net::IMAP::SASL::SASLprep::PROHIBITED_OUTPUT_STORED = T.let(T.unsafe(nil), Regexp) - -# Matches strings prohibited by RFC4013 §2.3, §2.4, and §2.5. -# -# This checks prohibited output, bidirectional characters, and -# unassigned codepoints. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#93 -Net::IMAP::SASL::SASLprep::PROHIBITED_STORED = T.let(T.unsafe(nil), Regexp) - -# RFC4013 §2.3 Prohibited Output:: -# * Non-ASCII space characters — \StringPrep\[\"C.1.2\"] -# * ASCII control characters — \StringPrep\[\"C.2.1\"] -# * Non-ASCII control characters — \StringPrep\[\"C.2.2\"] -# * Private Use characters — \StringPrep\[\"C.3\"] -# * Non-character code points — \StringPrep\[\"C.4\"] -# * Surrogate code points — \StringPrep\[\"C.5\"] -# * Inappropriate for plain text characters — \StringPrep\[\"C.6\"] -# * Inappropriate for canonical representation characters — \StringPrep\[\"C.7\"] -# * Change display properties or deprecated characters — \StringPrep\[\"C.8\"] -# * Tagging characters — \StringPrep\[\"C.9\"] -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#38 -Net::IMAP::SASL::SASLprep::TABLES_PROHIBITED = T.let(T.unsafe(nil), Array) - -# Adds unassigned (by Unicode 3.2) codepoints to TABLES_PROHIBITED. -# -# RFC4013 §2.5 Unassigned Code Points:: -# This profile specifies the \StringPrep\[\"A.1\"] table as its list of -# unassigned code points. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#45 -Net::IMAP::SASL::SASLprep::TABLES_PROHIBITED_STORED = T.let(T.unsafe(nil), Array) - -# RFC4013 §2.5 Unassigned Code Points:: -# This profile specifies the \StringPrep\[\"A.1\"] table as its list of -# unassigned code points. -# -# source://net-imap//lib/net/imap/sasl/saslprep_tables.rb#58 -Net::IMAP::SASL::SASLprep::UNASSIGNED = T.let(T.unsafe(nil), Regexp) - -# Regexps and utility methods for implementing stringprep profiles. The -# \StringPrep algorithm is defined by -# {RFC-3454}[https://www.rfc-editor.org/rfc/rfc3454.html]. Each -# codepoint table defined in the RFC-3454 appendices is matched by a Regexp -# defined in this module. -# -- -# TODO: generic StringPrep mapping (not needed for SASLprep implementation) -# ++ -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#9 -module Net::IMAP::SASL::StringPrep - private - - # Checks that +string+ obeys all of the "Bidirectional Characters" - # requirements in RFC-3454, §6: - # - # * The characters in \StringPrep\[\"C.8\"] MUST be prohibited - # * If a string contains any RandALCat character, the string MUST NOT - # contain any LCat character. - # * If a string contains any RandALCat character, a RandALCat - # character MUST be the first character of the string, and a - # RandALCat character MUST be the last character of the string. - # - # This is usually combined with #check_prohibited!, so table "C.8" is only - # checked when c_8: true. - # - # Raises either ProhibitedCodepoint or BidiStringError unless all - # requirements are met. +profile+ is an optional string which will be - # added to any exception that is raised (it does not affect behavior). - # - # source://net-imap//lib/net/imap/sasl/stringprep.rb#58 - def check_bidi!(string, c_8: T.unsafe(nil), profile: T.unsafe(nil)); end - - # Checks +string+ for any codepoint in +tables+. Raises a - # ProhibitedCodepoint describing the first matching table. - # - # Also checks bidirectional characters, when bidi: true, which may - # raise a BidiStringError. - # - # +profile+ is an optional string which will be added to any exception that - # is raised (it does not affect behavior). - # - # source://net-imap//lib/net/imap/sasl/stringprep.rb#32 - def check_prohibited!(string, *tables, bidi: T.unsafe(nil), profile: T.unsafe(nil)); end - - class << self - # Returns a Regexp matching the given +table+ name. - # - # source://net-imap//lib/net/imap/sasl/stringprep.rb#18 - def [](table); end - - # Checks that +string+ obeys all of the "Bidirectional Characters" - # requirements in RFC-3454, §6: - # - # * The characters in \StringPrep\[\"C.8\"] MUST be prohibited - # * If a string contains any RandALCat character, the string MUST NOT - # contain any LCat character. - # * If a string contains any RandALCat character, a RandALCat - # character MUST be the first character of the string, and a - # RandALCat character MUST be the last character of the string. - # - # This is usually combined with #check_prohibited!, so table "C.8" is only - # checked when c_8: true. - # - # Raises either ProhibitedCodepoint or BidiStringError unless all - # requirements are met. +profile+ is an optional string which will be - # added to any exception that is raised (it does not affect behavior). - # - # source://net-imap//lib/net/imap/sasl/stringprep.rb#58 - def check_bidi!(string, c_8: T.unsafe(nil), profile: T.unsafe(nil)); end - - # Checks +string+ for any codepoint in +tables+. Raises a - # ProhibitedCodepoint describing the first matching table. - # - # Also checks bidirectional characters, when bidi: true, which may - # raise a BidiStringError. - # - # +profile+ is an optional string which will be added to any exception that - # is raised (it does not affect behavior). - # - # @raise [ProhibitedCodepoint] - # - # source://net-imap//lib/net/imap/sasl/stringprep.rb#32 - def check_prohibited!(string, *tables, bidi: T.unsafe(nil), profile: T.unsafe(nil)); end - end -end - -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#66 -Net::IMAP::SASL::StringPrep::BIDI_DESC_REQ2 = T.let(T.unsafe(nil), String) - -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#79 -Net::IMAP::SASL::StringPrep::BIDI_DESC_REQ3 = T.let(T.unsafe(nil), String) - -# Bidirectional Characters [StringPrep, §6], Requirement 2:: -# If a string contains any RandALCat character, the string MUST NOT -# contain any LCat character. -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#71 -Net::IMAP::SASL::StringPrep::BIDI_FAILS_REQ2 = T.let(T.unsafe(nil), Regexp) - -# Bidirectional Characters [StringPrep, §6], Requirement 3:: -# If a string contains any RandALCat character, a RandALCat -# character MUST be the first character of the string, and a -# RandALCat character MUST be the last character of the string. -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#85 -Net::IMAP::SASL::StringPrep::BIDI_FAILS_REQ3 = T.let(T.unsafe(nil), Regexp) - -# Bidirectional Characters [StringPrep, §6] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#94 -Net::IMAP::SASL::StringPrep::BIDI_FAILURE = T.let(T.unsafe(nil), Regexp) - -# Unassigned code points in Unicode 3.2 \StringPrep\[\"A.1\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#12 -Net::IMAP::SASL::StringPrep::IN_A_1 = T.let(T.unsafe(nil), Regexp) - -# Commonly mapped to nothing \StringPrep\[\"B.1\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#15 -Net::IMAP::SASL::StringPrep::IN_B_1 = T.let(T.unsafe(nil), Regexp) - -# Mapping for case-folding used with NFKC \StringPrep\[\"B.2\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#18 -Net::IMAP::SASL::StringPrep::IN_B_2 = T.let(T.unsafe(nil), Regexp) - -# Mapping for case-folding used with no normalization \StringPrep\[\"B.3\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#21 -Net::IMAP::SASL::StringPrep::IN_B_3 = T.let(T.unsafe(nil), Regexp) - -# ASCII space characters \StringPrep\[\"C.1.1\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#24 -Net::IMAP::SASL::StringPrep::IN_C_1_1 = T.let(T.unsafe(nil), Regexp) - -# Non-ASCII space characters \StringPrep\[\"C.1.2\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#27 -Net::IMAP::SASL::StringPrep::IN_C_1_2 = T.let(T.unsafe(nil), Regexp) - -# ASCII control characters \StringPrep\[\"C.2.1\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#30 -Net::IMAP::SASL::StringPrep::IN_C_2_1 = T.let(T.unsafe(nil), Regexp) - -# Non-ASCII control characters \StringPrep\[\"C.2.2\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#33 -Net::IMAP::SASL::StringPrep::IN_C_2_2 = T.let(T.unsafe(nil), Regexp) - -# Private use \StringPrep\[\"C.3\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#36 -Net::IMAP::SASL::StringPrep::IN_C_3 = T.let(T.unsafe(nil), Regexp) - -# Non-character code points \StringPrep\[\"C.4\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#39 -Net::IMAP::SASL::StringPrep::IN_C_4 = T.let(T.unsafe(nil), Regexp) - -# Surrogate codes \StringPrep\[\"C.5\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#42 -Net::IMAP::SASL::StringPrep::IN_C_5 = T.let(T.unsafe(nil), Regexp) - -# Inappropriate for plain text \StringPrep\[\"C.6\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#45 -Net::IMAP::SASL::StringPrep::IN_C_6 = T.let(T.unsafe(nil), Regexp) - -# Inappropriate for canonical representation \StringPrep\[\"C.7\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#48 -Net::IMAP::SASL::StringPrep::IN_C_7 = T.let(T.unsafe(nil), Regexp) - -# Change display properties or are deprecated \StringPrep\[\"C.8\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#51 -Net::IMAP::SASL::StringPrep::IN_C_8 = T.let(T.unsafe(nil), Regexp) - -# Tagging characters \StringPrep\[\"C.9\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#54 -Net::IMAP::SASL::StringPrep::IN_C_9 = T.let(T.unsafe(nil), Regexp) - -# Characters with bidirectional property "R" or "AL" \StringPrep\[\"D.1\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#57 -Net::IMAP::SASL::StringPrep::IN_D_1 = T.let(T.unsafe(nil), Regexp) - -# Used to check req3 of bidirectional checks -# Matches the negation of the D.1 table -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#61 -Net::IMAP::SASL::StringPrep::IN_D_1_NEGATED = T.let(T.unsafe(nil), Regexp) - -# Characters with bidirectional property "L" \StringPrep\[\"D.2\"] -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#64 -Net::IMAP::SASL::StringPrep::IN_D_2 = T.let(T.unsafe(nil), Regexp) - -# Regexps matching each codepoint table in the RFC-3454 appendices -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#132 -Net::IMAP::SASL::StringPrep::TABLE_REGEXPS = T.let(T.unsafe(nil), Hash) - -# Names of each codepoint table in the RFC-3454 appendices -# -# source://net-imap//lib/net/imap/sasl/stringprep_tables.rb#109 -Net::IMAP::SASL::StringPrep::TABLE_TITLES = T.let(T.unsafe(nil), Hash) - -# ArgumentError raised when +string+ is invalid for the stringprep -# +profile+. -# -# source://net-imap//lib/net/imap/sasl.rb#33 -class Net::IMAP::SASL::StringPrepError < ::ArgumentError - # @return [StringPrepError] a new instance of StringPrepError - # - # source://net-imap//lib/net/imap/sasl.rb#36 - def initialize(*args, string: T.unsafe(nil), profile: T.unsafe(nil)); end - - # Returns the value of attribute profile. - # - # source://net-imap//lib/net/imap/sasl.rb#34 - def profile; end - - # Returns the value of attribute string. - # - # source://net-imap//lib/net/imap/sasl.rb#34 - def string; end -end - -# Mailbox attribute indicating that this mailbox is used to hold copies of -# messages that have been sent. Some server implementations might put -# messages here automatically. Alternatively, this might just be advice that -# a client save sent messages here. -# -# source://net-imap//lib/net/imap/flags.rb#248 -Net::IMAP::SENT = T.let(T.unsafe(nil), Symbol) - -# strftime/strptime format for an IMAP4 +date+, excluding optional dquotes. -# Use via the encode_date and decode_date methods. -# -# date = date-text / DQUOTE date-text DQUOTE -# date-text = date-day "-" date-month "-" date-year -# -# date-day = 1*2DIGIT -# ; Day of month -# date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / -# "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" -# date-year = 4DIGIT -# -# source://net-imap//lib/net/imap/data_encoding.rb#21 -Net::IMAP::STRFDATE = T.let(T.unsafe(nil), String) - -# strftime/strptime format for an IMAP4 +date-time+, including dquotes. -# See the encode_datetime and decode_datetime methods. -# -# date-time = DQUOTE date-day-fixed "-" date-month "-" date-year -# SP time SP zone DQUOTE -# -# date-day-fixed = (SP DIGIT) / 2DIGIT -# ; Fixed-format version of date-day -# date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / -# "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" -# date-year = 4DIGIT -# time = 2DIGIT ":" 2DIGIT ":" 2DIGIT -# ; Hours minutes seconds -# zone = ("+" / "-") 4DIGIT -# ; Signed four-digit value of hhmm representing -# ; hours and minutes east of Greenwich (that is, -# ; the amount that the given time differs from -# ; Universal Time). Subtracting the timezone -# ; from the given time will give the UT form. -# ; The Universal Time zone is "+0000". -# -# Note that Time.strptime "%d" flexibly parses either space or zero -# padding. However, the DQUOTEs are *not* optional. -# -# source://net-imap//lib/net/imap/data_encoding.rb#46 -Net::IMAP::STRFTIME = T.let(T.unsafe(nil), String) - -# The mailbox name was subscribed to using the #subscribe command. -# -# source://net-imap//lib/net/imap/flags.rb#173 -Net::IMAP::SUBSCRIBED = T.let(T.unsafe(nil), Symbol) - -# source://net-imap//lib/net/imap/command_data.rb#266 -module Net::IMAP::StringFormatter - private - - # coerces non-nil using +to_s+ - # - # source://net-imap//lib/net/imap/command_data.rb#293 - def nstring(str); end - - # coerces using +to_s+ - # - # source://net-imap//lib/net/imap/command_data.rb#283 - def string(str); end - - # Allows nil, symbols, and strings - # - # source://net-imap//lib/net/imap/command_data.rb#278 - def valid_nstring?(str); end - - # Allows symbols in addition to strings - # - # source://net-imap//lib/net/imap/command_data.rb#273 - def valid_string?(str); end - - class << self - # coerces non-nil using +to_s+ - # - # source://net-imap//lib/net/imap/command_data.rb#293 - def nstring(str); end - - # coerces using +to_s+ - # - # source://net-imap//lib/net/imap/command_data.rb#283 - def string(str); end - - # Allows nil, symbols, and strings - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/command_data.rb#278 - def valid_nstring?(str); end - - # Allows symbols in addition to strings - # - # @return [Boolean] - # - # source://net-imap//lib/net/imap/command_data.rb#273 - def valid_string?(str); end - end -end - -# source://net-imap//lib/net/imap/command_data.rb#268 -Net::IMAP::StringFormatter::LITERAL_REGEX = T.let(T.unsafe(nil), Regexp) - -# Mailbox attribute indicating that this mailbox is used to hold messages -# that have been deleted or marked for deletion. In some server -# implementations, this might be a virtual mailbox, containing messages from -# other mailboxes that are marked with the +\Deleted+ message flag. -# Alternatively, this might just be advice that a client that chooses not to -# use the \IMAP +\Deleted+ model should use as its trash location. In server -# implementations that strictly expect the \IMAP +\Deleted+ model, this -# special use is likely not to be supported. -# -# source://net-imap//lib/net/imap/flags.rb#258 -Net::IMAP::TRASH = T.let(T.unsafe(nil), Symbol) - -# Net::IMAP::UIDPlusData represents the ResponseCode#data that accompanies -# the +APPENDUID+ and +COPYUID+ response codes. -# -# See [[UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]]. -# -# ==== Capability requirement -# -# The +UIDPLUS+ capability[rdoc-ref:Net::IMAP#capability] must be supported. -# A server that supports +UIDPLUS+ should send a UIDPlusData object inside -# every TaggedResponse returned by the append[rdoc-ref:Net::IMAP#append], -# copy[rdoc-ref:Net::IMAP#copy], move[rdoc-ref:Net::IMAP#move], {uid -# copy}[rdoc-ref:Net::IMAP#uid_copy], and {uid -# move}[rdoc-ref:Net::IMAP#uid_move] commands---unless the destination -# mailbox reports +UIDNOTSTICKY+. -# -# -- -# TODO: support MULTIAPPEND -# ++ -# -# source://net-imap//lib/net/imap/response_data.rb#237 -class Net::IMAP::UIDPlusData < ::Struct - # :call-seq: uid_mapping -> nil or a hash - # - # Returns a hash mapping each source UID to the newly assigned destination - # UID. - # - # Note:: Returns +nil+ for Net::IMAP#append. - # - # source://net-imap//lib/net/imap/response_data.rb#267 - def uid_mapping; end -end - -# Error raised upon an unknown response from the server. -# -# source://net-imap//lib/net/imap/errors.rb#51 -class Net::IMAP::UnknownResponseError < ::Net::IMAP::ResponseError; end - -# source://net-imap//lib/net/imap.rb#702 -Net::IMAP::VERSION = T.let(T.unsafe(nil), String) - -# source://net-imap//lib/net/imap/authenticators/xoauth2.rb#3 -class Net::IMAP::XOauth2Authenticator - # @return [XOauth2Authenticator] a new instance of XOauth2Authenticator - # - # source://net-imap//lib/net/imap/authenticators/xoauth2.rb#10 - def initialize(user, oauth2_token, **_); end - - # source://net-imap//lib/net/imap/authenticators/xoauth2.rb#4 - def process(_data); end - - private - - # source://net-imap//lib/net/imap/authenticators/xoauth2.rb#15 - def build_oauth2_string(user, oauth2_token); end -end diff --git a/sorbet/rbi/gems/net-imap@0.4.14.rbi b/sorbet/rbi/gems/net-imap@0.4.14.rbi new file mode 100644 index 000000000..a7462cd0c --- /dev/null +++ b/sorbet/rbi/gems/net-imap@0.4.14.rbi @@ -0,0 +1,10845 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `net-imap` gem. +# Please instead update this file by running `bin/tapioca gem net-imap`. + + +# Net::IMAP implements Internet Message Access Protocol (\IMAP) client +# functionality. The protocol is described +# in {IMAP4rev1 [RFC3501]}[https://tools.ietf.org/html/rfc3501] +# and {IMAP4rev2 [RFC9051]}[https://tools.ietf.org/html/rfc9051]. +# +# == \IMAP Overview +# +# An \IMAP client connects to a server, and then authenticates +# itself using either #authenticate or #login. Having +# authenticated itself, there is a range of commands +# available to it. Most work with mailboxes, which may be +# arranged in an hierarchical namespace, and each of which +# contains zero or more messages. How this is implemented on +# the server is implementation-dependent; on a UNIX server, it +# will frequently be implemented as files in mailbox format +# within a hierarchy of directories. +# +# To work on the messages within a mailbox, the client must +# first select that mailbox, using either #select or #examine +# (for read-only access). Once the client has successfully +# selected a mailbox, they enter the "_selected_" state, and that +# mailbox becomes the _current_ mailbox, on which mail-item +# related commands implicitly operate. +# +# === Sequence numbers and UIDs +# +# Messages have two sorts of identifiers: message sequence +# numbers and UIDs. +# +# Message sequence numbers number messages within a mailbox +# from 1 up to the number of items in the mailbox. If a new +# message arrives during a session, it receives a sequence +# number equal to the new size of the mailbox. If messages +# are expunged from the mailbox, remaining messages have their +# sequence numbers "shuffled down" to fill the gaps. +# +# To avoid sequence number race conditions, servers must not expunge messages +# when no command is in progress, nor when responding to #fetch, #store, or +# #search. Expunges _may_ be sent during any other command, including +# #uid_fetch, #uid_store, and #uid_search. The #noop and #idle commands are +# both useful for this side-effect: they allow the server to send all mailbox +# updates, including expunges. +# +# UIDs, on the other hand, are permanently guaranteed not to +# identify another message within the same mailbox, even if +# the existing message is deleted. UIDs are required to +# be assigned in ascending (but not necessarily sequential) +# order within a mailbox; this means that if a non-IMAP client +# rearranges the order of mail items within a mailbox, the +# UIDs have to be reassigned. An \IMAP client thus cannot +# rearrange message orders. +# +# === Examples of Usage +# +# ==== List sender and subject of all recent messages in the default mailbox +# +# imap = Net::IMAP.new('mail.example.com') +# imap.authenticate('PLAIN', 'joe_user', 'joes_password') +# imap.examine('INBOX') +# imap.search(["RECENT"]).each do |message_id| +# envelope = imap.fetch(message_id, "ENVELOPE")[0].attr["ENVELOPE"] +# puts "#{envelope.from[0].name}: \t#{envelope.subject}" +# end +# +# ==== Move all messages from April 2003 from "Mail/sent-mail" to "Mail/sent-apr03" +# +# imap = Net::IMAP.new('mail.example.com') +# imap.authenticate('PLAIN', 'joe_user', 'joes_password') +# imap.select('Mail/sent-mail') +# if not imap.list('Mail/', 'sent-apr03') +# imap.create('Mail/sent-apr03') +# end +# imap.search(["BEFORE", "30-Apr-2003", "SINCE", "1-Apr-2003"]).each do |message_id| +# imap.copy(message_id, "Mail/sent-apr03") +# imap.store(message_id, "+FLAGS", [:Deleted]) +# end +# imap.expunge +# +# == Capabilities +# +# Most Net::IMAP methods do not _currently_ modify their behaviour according +# to the server's advertised #capabilities. Users of this class must check +# that the server is capable of extension commands or command arguments before +# sending them. Special care should be taken to follow the #capabilities +# requirements for #starttls, #login, and #authenticate. +# +# See #capable?, #auth_capable?, #capabilities, #auth_mechanisms to discover +# server capabilities. For relevant capability requirements, see the +# documentation on each \IMAP command. +# +# imap = Net::IMAP.new("mail.example.com") +# imap.capable?(:IMAP4rev1) or raise "Not an IMAP4rev1 server" +# imap.capable?(:starttls) or raise "Cannot start TLS" +# imap.starttls +# +# if imap.auth_capable?("PLAIN") +# imap.authenticate "PLAIN", username, password +# elsif !imap.capability?("LOGINDISABLED") +# imap.login username, password +# else +# raise "No acceptable authentication mechanisms" +# end +# +# # Support for "UTF8=ACCEPT" implies support for "ENABLE" +# imap.enable :utf8 if imap.capable?("UTF8=ACCEPT") +# +# namespaces = imap.namespace if imap.capable?(:namespace) +# mbox_prefix = namespaces&.personal&.first&.prefix || "" +# mbox_delim = namespaces&.personal&.first&.delim || "/" +# mbox_path = prefix + %w[path to my mailbox].join(delim) +# imap.create mbox_path +# +# === Basic IMAP4rev1 capabilities +# +# IMAP4rev1 servers must advertise +IMAP4rev1+ in their capabilities list. +# IMAP4rev1 servers must _implement_ the +STARTTLS+, AUTH=PLAIN, +# and +LOGINDISABLED+ capabilities. See #starttls, #login, and #authenticate +# for the implications of these capabilities. +# +# === Caching +CAPABILITY+ responses +# +# Net::IMAP automatically stores and discards capability data according to the +# the requirements and recommendations in +# {IMAP4rev2 §6.1.1}[https://www.rfc-editor.org/rfc/rfc9051#section-6.1.1], +# {§6.2}[https://www.rfc-editor.org/rfc/rfc9051#section-6.2], and +# {§7.1}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1]. +# Use #capable?, #auth_capable?, or #capabilities to use this cache and avoid +# sending the #capability command unnecessarily. +# +# The server may advertise its initial capabilities using the +CAPABILITY+ +# ResponseCode in a +PREAUTH+ or +OK+ #greeting. When TLS has started +# (#starttls) and after authentication (#login or #authenticate), the server's +# capabilities may change and cached capabilities are discarded. The server +# may send updated capabilities with an +OK+ TaggedResponse to #login or +# #authenticate, and these will be cached by Net::IMAP. But the +# TaggedResponse to #starttls MUST be ignored--it is sent before TLS starts +# and is unprotected. +# +# When storing capability values to variables, be careful that they are +# discarded or reset appropriately, especially following #starttls. +# +# === Using IMAP4rev1 extensions +# +# See the {IANA IMAP4 capabilities +# registry}[http://www.iana.org/assignments/imap4-capabilities] for a list of +# all standard capabilities, and their reference RFCs. +# +# IMAP4rev1 servers must not activate behavior that is incompatible with the +# base specification until an explicit client action invokes a capability, +# e.g. sending a command or command argument specific to that capability. +# Servers may send data with backward compatible behavior, such as response +# codes or mailbox attributes, at any time without client action. +# +# Invoking capabilities which are unknown to Net::IMAP may cause unexpected +# behavior and errors. For example, ResponseParseError is raised when +# unknown response syntax is received. Invoking commands or command +# parameters that are unsupported by the server may raise NoResponseError, +# BadResponseError, or cause other unexpected behavior. +# +# Some capabilities must be explicitly activated using the #enable command. +# See #enable for details. +# +# == Thread Safety +# +# Net::IMAP supports concurrent threads. For example, +# +# imap = Net::IMAP.new("imap.foo.net", "imap2") +# imap.authenticate("scram-md5", "bar", "password") +# imap.select("inbox") +# fetch_thread = Thread.start { imap.fetch(1..-1, "UID") } +# search_result = imap.search(["BODY", "hello"]) +# fetch_result = fetch_thread.value +# imap.disconnect +# +# This script invokes the FETCH command and the SEARCH command concurrently. +# +# == Errors +# +# An \IMAP server can send three different types of responses to indicate +# failure: +# +# NO:: the attempted command could not be successfully completed. For +# instance, the username/password used for logging in are incorrect; +# the selected mailbox does not exist; etc. +# +# BAD:: the request from the client does not follow the server's +# understanding of the \IMAP protocol. This includes attempting +# commands from the wrong client state; for instance, attempting +# to perform a SEARCH command without having SELECTed a current +# mailbox. It can also signal an internal server +# failure (such as a disk crash) has occurred. +# +# BYE:: the server is saying goodbye. This can be part of a normal +# logout sequence, and can be used as part of a login sequence +# to indicate that the server is (for some reason) unwilling +# to accept your connection. As a response to any other command, +# it indicates either that the server is shutting down, or that +# the server is timing out the client connection due to inactivity. +# +# These three error response are represented by the errors +# Net::IMAP::NoResponseError, Net::IMAP::BadResponseError, and +# Net::IMAP::ByeResponseError, all of which are subclasses of +# Net::IMAP::ResponseError. Essentially, all methods that involve +# sending a request to the server can generate one of these errors. +# Only the most pertinent instances have been documented below. +# +# Because the IMAP class uses Sockets for communication, its methods +# are also susceptible to the various errors that can occur when +# working with sockets. These are generally represented as +# Errno errors. For instance, any method that involves sending a +# request to the server and/or receiving a response from it could +# raise an Errno::EPIPE error if the network connection unexpectedly +# goes down. See the socket(7), ip(7), tcp(7), socket(2), connect(2), +# and associated man pages. +# +# Finally, a Net::IMAP::DataFormatError is thrown if low-level data +# is found to be in an incorrect format (for instance, when converting +# between UTF-8 and UTF-16), and Net::IMAP::ResponseParseError is +# thrown if a server response is non-parseable. +# +# == What's here? +# +# * {Connection control}[rdoc-ref:Net::IMAP@Connection+control+methods] +# * {Server capabilities}[rdoc-ref:Net::IMAP@Server+capabilities] +# * {Handling server responses}[rdoc-ref:Net::IMAP@Handling+server+responses] +# * {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands] +# * {for any state}[rdoc-ref:Net::IMAP@Any+state] +# * {for the "not authenticated" state}[rdoc-ref:Net::IMAP@Not+Authenticated+state] +# * {for the "authenticated" state}[rdoc-ref:Net::IMAP@Authenticated+state] +# * {for the "selected" state}[rdoc-ref:Net::IMAP@Selected+state] +# * {for the "logout" state}[rdoc-ref:Net::IMAP@Logout+state] +# * {IMAP extension support}[rdoc-ref:Net::IMAP@IMAP+extension+support] +# +# === Connection control methods +# +# - Net::IMAP.new: Creates a new \IMAP client which connects immediately and +# waits for a successful server greeting before the method returns. +# - #starttls: Asks the server to upgrade a clear-text connection to use TLS. +# - #logout: Tells the server to end the session. Enters the "_logout_" state. +# - #disconnect: Disconnects the connection (without sending #logout first). +# - #disconnected?: True if the connection has been closed. +# +# === Server capabilities +# +# - #capable?: Returns whether the server supports a given capability. +# - #capabilities: Returns the server's capabilities as an array of strings. +# - #auth_capable?: Returns whether the server advertises support for a given +# SASL mechanism, for use with #authenticate. +# - #auth_mechanisms: Returns the #authenticate SASL mechanisms which +# the server claims to support as an array of strings. +# - #clear_cached_capabilities: Clears cached capabilities. +# +# The capabilities cache is automatically cleared after completing +# #starttls, #login, or #authenticate. +# - #capability: Sends the +CAPABILITY+ command and returns the #capabilities. +# +# In general, #capable? should be used rather than explicitly sending a +# +CAPABILITY+ command to the server. +# +# === Handling server responses +# +# - #greeting: The server's initial untagged response, which can indicate a +# pre-authenticated connection. +# - #responses: Yields unhandled UntaggedResponse#data and non-+nil+ +# ResponseCode#data. +# - #clear_responses: Deletes unhandled data from #responses and returns it. +# - #add_response_handler: Add a block to be called inside the receiver thread +# with every server response. +# - #response_handlers: Returns the list of response handlers. +# - #remove_response_handler: Remove a previously added response handler. +# +# === Core \IMAP commands +# +# The following commands are defined either by +# the [IMAP4rev1[https://tools.ietf.org/html/rfc3501]] base specification, or +# by one of the following extensions: +# [IDLE[https://tools.ietf.org/html/rfc2177]], +# [NAMESPACE[https://tools.ietf.org/html/rfc2342]], +# [UNSELECT[https://tools.ietf.org/html/rfc3691]], +# [ENABLE[https://tools.ietf.org/html/rfc5161]], +# [MOVE[https://tools.ietf.org/html/rfc6851]]. +# These extensions are widely supported by modern IMAP4rev1 servers and have +# all been integrated into [IMAP4rev2[https://tools.ietf.org/html/rfc9051]]. +# *NOTE:* Net::IMAP doesn't support IMAP4rev2 yet. +# +# ==== Any state +# +# - #capability: Returns the server's capabilities as an array of strings. +# +# In general, #capable? should be used rather than explicitly sending a +# +CAPABILITY+ command to the server. +# - #noop: Allows the server to send unsolicited untagged #responses. +# - #logout: Tells the server to end the session. Enters the "_logout_" state. +# +# ==== Not Authenticated state +# +# In addition to the commands for any state, the following commands are valid +# in the "not authenticated" state: +# +# - #starttls: Upgrades a clear-text connection to use TLS. +# +# Requires the +STARTTLS+ capability. +# - #authenticate: Identifies the client to the server using the given +# {SASL mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] +# and credentials. Enters the "_authenticated_" state. +# +# The server should list "AUTH=#{mechanism}" capabilities for +# supported mechanisms. +# - #login: Identifies the client to the server using a plain text password. +# Using #authenticate is generally preferred. Enters the "_authenticated_" +# state. +# +# The +LOGINDISABLED+ capability must NOT be listed. +# +# ==== Authenticated state +# +# In addition to the commands for any state, the following commands are valid +# in the "_authenticated_" state: +# +# - #enable: Enables backwards incompatible server extensions. +# Requires the +ENABLE+ or +IMAP4rev2+ capability. +# - #select: Open a mailbox and enter the "_selected_" state. +# - #examine: Open a mailbox read-only, and enter the "_selected_" state. +# - #create: Creates a new mailbox. +# - #delete: Permanently remove a mailbox. +# - #rename: Change the name of a mailbox. +# - #subscribe: Adds a mailbox to the "subscribed" set. +# - #unsubscribe: Removes a mailbox from the "subscribed" set. +# - #list: Returns names and attributes of mailboxes matching a given pattern. +# - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. +# Requires the +NAMESPACE+ or +IMAP4rev2+ capability. +# - #status: Returns mailbox information, e.g. message count, unseen message +# count, +UIDVALIDITY+ and +UIDNEXT+. +# - #append: Appends a message to the end of a mailbox. +# - #idle: Allows the server to send updates to the client, without the client +# needing to poll using #noop. +# Requires the +IDLE+ or +IMAP4rev2+ capability. +# - *Obsolete* #lsub: Replaced by LIST-EXTENDED and removed from +# +IMAP4rev2+. Lists mailboxes in the "subscribed" set. +# +# *Note:* Net::IMAP hasn't implemented LIST-EXTENDED yet. +# +# ==== Selected state +# +# In addition to the commands for any state and the "_authenticated_" +# commands, the following commands are valid in the "_selected_" state: +# +# - #close: Closes the mailbox and returns to the "_authenticated_" state, +# expunging deleted messages, unless the mailbox was opened as read-only. +# - #unselect: Closes the mailbox and returns to the "_authenticated_" state, +# without expunging any messages. +# Requires the +UNSELECT+ or +IMAP4rev2+ capability. +# - #expunge: Permanently removes messages which have the Deleted flag set. +# - #uid_expunge: Restricts expunge to only remove the specified UIDs. +# Requires the +UIDPLUS+ or +IMAP4rev2+ capability. +# - #search, #uid_search: Returns sequence numbers or UIDs of messages that +# match the given searching criteria. +# - #fetch, #uid_fetch: Returns data associated with a set of messages, +# specified by sequence number or UID. +# - #store, #uid_store: Alters a message's flags. +# - #copy, #uid_copy: Copies the specified messages to the end of the +# specified destination mailbox. +# - #move, #uid_move: Moves the specified messages to the end of the +# specified destination mailbox, expunging them from the current mailbox. +# Requires the +MOVE+ or +IMAP4rev2+ capability. +# - #check: *Obsolete:* removed from +IMAP4rev2+. +# Can be replaced with #noop or #idle. +# +# ==== Logout state +# +# No \IMAP commands are valid in the "_logout_" state. If the socket is still +# open, Net::IMAP will close it after receiving server confirmation. +# Exceptions will be raised by \IMAP commands that have already started and +# are waiting for a response, as well as any that are called after logout. +# +# === \IMAP extension support +# +# ==== RFC9051: +IMAP4rev2+ +# +# Although IMAP4rev2[https://tools.ietf.org/html/rfc9051] is not supported +# yet, Net::IMAP supports several extensions that have been folded into it: +# +ENABLE+, +IDLE+, +MOVE+, +NAMESPACE+, +SASL-IR+, +UIDPLUS+, +UNSELECT+, +# STATUS=SIZE, and the fetch side of +BINARY+. +# Commands for these extensions are listed with the {Core IMAP +# commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands], above. +# +# >>> +# The following are folded into +IMAP4rev2+ but are currently +# unsupported or incompletely supported by Net::IMAP: RFC4466 +# extensions, +ESEARCH+, +SEARCHRES+, +LIST-EXTENDED+, +LIST-STATUS+, +# +LITERAL-+, and +SPECIAL-USE+. +# +# ==== RFC2087: +QUOTA+ +# - #getquota: returns the resource usage and limits for a quota root +# - #getquotaroot: returns the list of quota roots for a mailbox, as well as +# their resource usage and limits. +# - #setquota: sets the resource limits for a given quota root. +# +# ==== RFC2177: +IDLE+ +# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included +# above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. +# - #idle: Allows the server to send updates to the client, without the client +# needing to poll using #noop. +# +# ==== RFC2342: +NAMESPACE+ +# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included +# above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. +# - #namespace: Returns mailbox namespaces, with path prefixes and delimiters. +# +# ==== RFC2971: +ID+ +# - #id: exchanges client and server implementation information. +# +# ==== RFC3516: +BINARY+ +# The fetch side of +BINARY+ has been folded into +# IMAP4rev2[https://tools.ietf.org/html/rfc9051]. +# - Updates #fetch and #uid_fetch with the +BINARY+, +BINARY.PEEK+, and +# +BINARY.SIZE+ items. See FetchData#binary and FetchData#binary_size. +# +# >>> +# *NOTE:* The binary extension the #append command is _not_ supported yet. +# +# ==== RFC3691: +UNSELECT+ +# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included +# above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. +# - #unselect: Closes the mailbox and returns to the "_authenticated_" state, +# without expunging any messages. +# +# ==== RFC4314: +ACL+ +# - #getacl: lists the authenticated user's access rights to a mailbox. +# - #setacl: sets the access rights for a user on a mailbox +# >>> +# *NOTE:* +DELETEACL+, +LISTRIGHTS+, and +MYRIGHTS+ are not supported yet. +# +# ==== RFC4315: +UIDPLUS+ +# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included +# above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. +# - #uid_expunge: Restricts #expunge to only remove the specified UIDs. +# - Updates #select, #examine with the +UIDNOTSTICKY+ ResponseCode +# - Updates #append with the +APPENDUID+ ResponseCode +# - Updates #copy, #move with the +COPYUID+ ResponseCode +# +# ==== RFC4959: +SASL-IR+ +# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051]. +# - Updates #authenticate with the option to send an initial response. +# +# ==== RFC5161: +ENABLE+ +# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included +# above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. +# - #enable: Enables backwards incompatible server extensions. +# +# ==== RFC5256: +SORT+ +# - #sort, #uid_sort: An alternate version of #search or #uid_search which +# sorts the results by specified keys. +# ==== RFC5256: +THREAD+ +# - #thread, #uid_thread: An alternate version of #search or #uid_search, +# which arranges the results into ordered groups or threads according to a +# chosen algorithm. +# +# ==== +X-GM-EXT-1+ +# +X-GM-EXT-1+ is a non-standard Gmail extension. See {Google's +# documentation}[https://developers.google.com/gmail/imap/imap-extensions]. +# - Updates #fetch and #uid_fetch with support for +X-GM-MSGID+ (unique +# message ID), +X-GM-THRID+ (thread ID), and +X-GM-LABELS+ (Gmail labels). +# - Updates #search with the +X-GM-RAW+ search attribute. +# - #xlist: replaced by +SPECIAL-USE+ attributes in #list responses. +# +# *NOTE:* The +OBJECTID+ extension should replace +X-GM-MSGID+ and +# +X-GM-THRID+, but Gmail does not support it (as of 2023-11-10). +# +# ==== RFC6851: +MOVE+ +# Folded into IMAP4rev2[https://tools.ietf.org/html/rfc9051] and also included +# above with {Core IMAP commands}[rdoc-ref:Net::IMAP@Core+IMAP+commands]. +# - #move, #uid_move: Moves the specified messages to the end of the +# specified destination mailbox, expunging them from the current mailbox. +# +# ==== RFC6855: UTF8=ACCEPT, UTF8=ONLY +# +# - See #enable for information about support for UTF-8 string encoding. +# +# ==== RFC7162: +CONDSTORE+ +# +# - Updates #enable with +CONDSTORE+ parameter. +CONDSTORE+ will also be +# enabled by using any of the extension's command parameters, listed below. +# - Updates #status with the +HIGHESTMODSEQ+ status attribute. +# - Updates #select and #examine with the +condstore+ modifier, and adds +# either a +HIGHESTMODSEQ+ or +NOMODSEQ+ ResponseCode to the responses. +# - Updates #search, #uid_search, #sort, and #uid_sort with the +MODSEQ+ +# search criterion, and adds SearchResult#modseq to the search response. +# - Updates #thread and #uid_thread with the +MODSEQ+ search criterion +# (but thread responses are unchanged). +# - Updates #fetch and #uid_fetch with the +changedsince+ modifier and +# +MODSEQ+ FetchData attribute. +# - Updates #store and #uid_store with the +unchangedsince+ modifier and adds +# the +MODIFIED+ ResponseCode to the tagged response. +# +# ==== RFC8438: STATUS=SIZE +# - Updates #status with the +SIZE+ status attribute. +# +# ==== RFC8474: +OBJECTID+ +# - Adds +MAILBOXID+ ResponseCode to #create tagged response. +# - Adds +MAILBOXID+ ResponseCode to #select and #examine untagged response. +# - Updates #fetch and #uid_fetch with the +EMAILID+ and +THREADID+ items. +# See FetchData#emailid and FetchData#emailid. +# - Updates #status with support for the +MAILBOXID+ status attribute. +# +# == References +# +# [{IMAP4rev1}[https://www.rfc-editor.org/rfc/rfc3501.html]]:: +# Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL - \VERSION 4rev1", +# RFC 3501, DOI 10.17487/RFC3501, March 2003, +# . +# +# [IMAP-ABNF-EXT[https://www.rfc-editor.org/rfc/rfc4466.html]]:: +# Melnikov, A. and C. Daboo, "Collected Extensions to IMAP4 ABNF", +# RFC 4466, DOI 10.17487/RFC4466, April 2006, +# . +# +# Note: Net::IMAP cannot parse the entire RFC4466 grammar yet. +# +# [{IMAP4rev2}[https://www.rfc-editor.org/rfc/rfc9051.html]]:: +# Melnikov, A., Ed., and B. Leiba, Ed., "Internet Message Access Protocol +# (\IMAP) - Version 4rev2", RFC 9051, DOI 10.17487/RFC9051, August 2021, +# . +# +# Note: Net::IMAP is not fully compatible with IMAP4rev2 yet. +# +# [IMAP-IMPLEMENTATION[https://www.rfc-editor.org/info/rfc2683]]:: +# Leiba, B., "IMAP4 Implementation Recommendations", +# RFC 2683, DOI 10.17487/RFC2683, September 1999, +# . +# +# [IMAP-MULTIACCESS[https://www.rfc-editor.org/info/rfc2180]]:: +# Gahrns, M., "IMAP4 Multi-Accessed Mailbox Practice", RFC 2180, DOI +# 10.17487/RFC2180, July 1997, . +# +# [UTF7[https://tools.ietf.org/html/rfc2152]]:: +# Goldsmith, D. and M. Davis, "UTF-7 A Mail-Safe Transformation Format of +# Unicode", RFC 2152, DOI 10.17487/RFC2152, May 1997, +# . +# +# === Message envelope and body structure +# +# [RFC5322[https://tools.ietf.org/html/rfc5322]]:: +# Resnick, P., Ed., "Internet Message Format", +# RFC 5322, DOI 10.17487/RFC5322, October 2008, +# . +# +# Note: obsoletes +# RFC-2822[https://tools.ietf.org/html/rfc2822] (April 2001) and +# RFC-822[https://tools.ietf.org/html/rfc822] (August 1982). +# +# [CHARSET[https://tools.ietf.org/html/rfc2978]]:: +# Freed, N. and J. Postel, "IANA Charset Registration Procedures", BCP 19, +# RFC 2978, DOI 10.17487/RFC2978, October 2000, +# . +# +# [DISPOSITION[https://tools.ietf.org/html/rfc2183]]:: +# Troost, R., Dorner, S., and K. Moore, Ed., "Communicating Presentation +# Information in Internet Messages: The Content-Disposition Header +# Field", RFC 2183, DOI 10.17487/RFC2183, August 1997, +# . +# +# [MIME-IMB[https://tools.ietf.org/html/rfc2045]]:: +# Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions +# (MIME) Part One: Format of Internet Message Bodies", +# RFC 2045, DOI 10.17487/RFC2045, November 1996, +# . +# +# [MIME-IMT[https://tools.ietf.org/html/rfc2046]]:: +# Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions +# (MIME) Part Two: Media Types", RFC 2046, DOI 10.17487/RFC2046, +# November 1996, . +# +# [MIME-HDRS[https://tools.ietf.org/html/rfc2047]]:: +# Moore, K., "MIME (Multipurpose Internet Mail Extensions) Part Three: +# Message Header Extensions for Non-ASCII Text", +# RFC 2047, DOI 10.17487/RFC2047, November 1996, +# . +# +# [RFC2231[https://tools.ietf.org/html/rfc2231]]:: +# Freed, N. and K. Moore, "MIME Parameter Value and Encoded Word +# Extensions: Character Sets, Languages, and Continuations", +# RFC 2231, DOI 10.17487/RFC2231, November 1997, +# . +# +# [I18n-HDRS[https://tools.ietf.org/html/rfc6532]]:: +# Yang, A., Steele, S., and N. Freed, "Internationalized Email Headers", +# RFC 6532, DOI 10.17487/RFC6532, February 2012, +# . +# +# [LANGUAGE-TAGS[https://www.rfc-editor.org/info/rfc3282]]:: +# Alvestrand, H., "Content Language Headers", +# RFC 3282, DOI 10.17487/RFC3282, May 2002, +# . +# +# [LOCATION[https://www.rfc-editor.org/info/rfc2557]]:: +# Palme, J., Hopmann, A., and N. Shelness, "MIME Encapsulation of +# Aggregate Documents, such as HTML (MHTML)", +# RFC 2557, DOI 10.17487/RFC2557, March 1999, +# . +# +# [MD5[https://tools.ietf.org/html/rfc1864]]:: +# Myers, J. and M. Rose, "The Content-MD5 Header Field", +# RFC 1864, DOI 10.17487/RFC1864, October 1995, +# . +# +# [RFC3503[https://tools.ietf.org/html/rfc3503]]:: +# Melnikov, A., "Message Disposition Notification (MDN) +# profile for Internet Message Access Protocol (IMAP)", +# RFC 3503, DOI 10.17487/RFC3503, March 2003, +# . +# +# === \IMAP Extensions +# +# [QUOTA[https://tools.ietf.org/html/rfc9208]]:: +# Melnikov, A., "IMAP QUOTA Extension", RFC 9208, DOI 10.17487/RFC9208, +# March 2022, . +# +# Note: obsoletes +# RFC-2087[https://tools.ietf.org/html/rfc2087] (January 1997). +# Net::IMAP does not fully support the RFC9208 updates yet. +# [IDLE[https://tools.ietf.org/html/rfc2177]]:: +# Leiba, B., "IMAP4 IDLE command", RFC 2177, DOI 10.17487/RFC2177, +# June 1997, . +# [NAMESPACE[https://tools.ietf.org/html/rfc2342]]:: +# Gahrns, M. and C. Newman, "IMAP4 Namespace", RFC 2342, +# DOI 10.17487/RFC2342, May 1998, . +# [ID[https://tools.ietf.org/html/rfc2971]]:: +# Showalter, T., "IMAP4 ID extension", RFC 2971, DOI 10.17487/RFC2971, +# October 2000, . +# [BINARY[https://tools.ietf.org/html/rfc3516]]:: +# Nerenberg, L., "IMAP4 Binary Content Extension", RFC 3516, +# DOI 10.17487/RFC3516, April 2003, +# . +# [ACL[https://tools.ietf.org/html/rfc4314]]:: +# Melnikov, A., "IMAP4 Access Control List (ACL) Extension", RFC 4314, +# DOI 10.17487/RFC4314, December 2005, +# . +# [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]]:: +# Crispin, M., "Internet Message Access Protocol (\IMAP) - UIDPLUS +# extension", RFC 4315, DOI 10.17487/RFC4315, December 2005, +# . +# [SORT[https://tools.ietf.org/html/rfc5256]]:: +# Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and +# THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, +# . +# [THREAD[https://tools.ietf.org/html/rfc5256]]:: +# Crispin, M. and K. Murchison, "Internet Message Access Protocol - SORT and +# THREAD Extensions", RFC 5256, DOI 10.17487/RFC5256, June 2008, +# . +# [RFC5530[https://www.rfc-editor.org/rfc/rfc5530.html]]:: +# Gulbrandsen, A., "IMAP Response Codes", RFC 5530, DOI 10.17487/RFC5530, +# May 2009, . +# [MOVE[https://tools.ietf.org/html/rfc6851]]:: +# Gulbrandsen, A. and N. Freed, Ed., "Internet Message Access Protocol +# (\IMAP) - MOVE Extension", RFC 6851, DOI 10.17487/RFC6851, January 2013, +# . +# [UTF8=ACCEPT[https://tools.ietf.org/html/rfc6855]]:: +# [UTF8=ONLY[https://tools.ietf.org/html/rfc6855]]:: +# Resnick, P., Ed., Newman, C., Ed., and S. Shen, Ed., +# "IMAP Support for UTF-8", RFC 6855, DOI 10.17487/RFC6855, March 2013, +# . +# [CONDSTORE[https://tools.ietf.org/html/rfc7162]]:: +# [QRESYNC[https://tools.ietf.org/html/rfc7162]]:: +# Melnikov, A. and D. Cridland, "IMAP Extensions: Quick Flag Changes +# Resynchronization (CONDSTORE) and Quick Mailbox Resynchronization +# (QRESYNC)", RFC 7162, DOI 10.17487/RFC7162, May 2014, +# . +# [OBJECTID[https://tools.ietf.org/html/rfc8474]]:: +# Gondwana, B., Ed., "IMAP Extension for Object Identifiers", +# RFC 8474, DOI 10.17487/RFC8474, September 2018, +# . +# +# === IANA registries +# * {IMAP Capabilities}[http://www.iana.org/assignments/imap4-capabilities] +# * {IMAP Response Codes}[https://www.iana.org/assignments/imap-response-codes/imap-response-codes.xhtml] +# * {IMAP Mailbox Name Attributes}[https://www.iana.org/assignments/imap-mailbox-name-attributes/imap-mailbox-name-attributes.xhtml] +# * {IMAP and JMAP Keywords}[https://www.iana.org/assignments/imap-jmap-keywords/imap-jmap-keywords.xhtml] +# * {IMAP Threading Algorithms}[https://www.iana.org/assignments/imap-threading-algorithms/imap-threading-algorithms.xhtml] +# * {SASL Mechanisms and SASL SCRAM Family Mechanisms}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] +# * {Service Name and Transport Protocol Port Number Registry}[https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml]: +# +imap+: tcp/143, +imaps+: tcp/993 +# * {GSSAPI/Kerberos/SASL Service Names}[https://www.iana.org/assignments/gssapi-service-names/gssapi-service-names.xhtml]: +# +imap+ +# * {Character sets}[https://www.iana.org/assignments/character-sets/character-sets.xhtml] +# ===== For currently unsupported features: +# * {IMAP Quota Resource Types}[http://www.iana.org/assignments/imap4-capabilities#imap-capabilities-2] +# * {LIST-EXTENDED options and responses}[https://www.iana.org/assignments/imap-list-extended/imap-list-extended.xhtml] +# * {IMAP METADATA Server Entry and Mailbox Entry Registries}[https://www.iana.org/assignments/imap-metadata/imap-metadata.xhtml] +# * {IMAP ANNOTATE Extension Entries and Attributes}[https://www.iana.org/assignments/imap-annotate-extension/imap-annotate-extension.xhtml] +# * {IMAP URLAUTH Access Identifiers and Prefixes}[https://www.iana.org/assignments/urlauth-access-ids/urlauth-access-ids.xhtml] +# * {IMAP URLAUTH Authorization Mechanism Registry}[https://www.iana.org/assignments/urlauth-authorization-mechanism-registry/urlauth-authorization-mechanism-registry.xhtml] +# +# source://net-imap//lib/net/imap.rb#719 +class Net::IMAP < ::Net::Protocol + include ::Net::IMAP::DeprecatedClientOptions + include ::MonitorMixin + include ::OpenSSL + include ::OpenSSL::SSL + extend ::Net::IMAP::Authenticators + + # Creates a new Net::IMAP object and connects it to the specified + # +host+. + # + # ==== Options + # + # Accepts the following options: + # + # [port] + # Port number. Defaults to 993 when +ssl+ is truthy, and 143 otherwise. + # + # [ssl] + # If +true+, the connection will use TLS with the default params set by + # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]. + # If +ssl+ is a hash, it's passed to + # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]; + # the keys are names of attribute assignment methods on + # SSLContext[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html]. For example: + # + # [{ca_file}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-ca_file]] + # The path to a file containing a PEM-format CA certificate. + # [{ca_path}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-ca_path]] + # The path to a directory containing CA certificates in PEM format. + # [{min_version}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-min_version-3D]] + # Sets the lower bound on the supported SSL/TLS protocol version. Set to + # an +OpenSSL+ constant such as +OpenSSL::SSL::TLS1_2_VERSION+, + # [{verify_mode}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#attribute-i-verify_mode]] + # SSL session verification mode. Valid modes include + # +OpenSSL::SSL::VERIFY_PEER+ and +OpenSSL::SSL::VERIFY_NONE+. + # + # See {OpenSSL::SSL::SSLContext}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html] for other valid SSL context params. + # + # See DeprecatedClientOptions.new for deprecated SSL arguments. + # + # [config] + # A Net::IMAP::Config object to use as the basis for #config. By default, + # the global Net::IMAP.config is used. + # + # >>> + # *NOTE:* +config+ does not set #config directly---it sets the _parent_ + # config for inheritance. Every client creates its own unique #config. + # + # All other keyword arguments are forwarded to Net::IMAP::Config.new, to + # initialize the client's #config. For example: + # + # [{open_timeout}[rdoc-ref:Config#open_timeout]] + # Seconds to wait until a connection is opened + # [{idle_response_timeout}[rdoc-ref:Config#idle_response_timeout]] + # Seconds to wait until an IDLE response is received + # + # See Net::IMAP::Config for other valid options. + # + # ==== Examples + # + # Connect to cleartext port 143 at mail.example.com and receive the server greeting: + # imap = Net::IMAP.new('mail.example.com', ssl: false) # => # + # imap.port => 143 + # imap.tls_verified? => false + # imap.greeting => name: ("OK" | "PREAUTH") => status + # status # => "OK" + # # The client is connected in the "Not Authenticated" state. + # + # Connect with TLS to port 993 + # imap = Net::IMAP.new('mail.example.com', ssl: true) # => # + # imap.port => 993 + # imap.tls_verified? => true + # imap.greeting => name: (/OK/i | /PREAUTH/i) => status + # case status + # in /OK/i + # # The client is connected in the "Not Authenticated" state. + # imap.authenticate("PLAIN", "joe_user", "joes_password") + # in /PREAUTH/i + # # The client is connected in the "Authenticated" state. + # end + # + # Connect with prior authentication, for example using an SSL certificate: + # ssl_ctx_params = { + # cert: OpenSSL::X509::Certificate.new(File.read("client.crt")), + # key: OpenSSL::PKey::EC.new(File.read('client.key')), + # extra_chain_cert: [ + # OpenSSL::X509::Certificate.new(File.read("intermediate.crt")), + # ], + # } + # imap = Net::IMAP.new('mail.example.com', ssl: ssl_ctx_params) + # imap.port => 993 + # imap.tls_verified? => true + # imap.greeting => name: "PREAUTH" + # # The client is connected in the "Authenticated" state. + # + # ==== Exceptions + # + # The most common errors are: + # + # [Errno::ECONNREFUSED] + # Connection refused by +host+ or an intervening firewall. + # [Errno::ETIMEDOUT] + # Connection timed out (possibly due to packets being dropped by an + # intervening firewall). + # [Errno::ENETUNREACH] + # There is no route to that network. + # [SocketError] + # Hostname not known or other socket error. + # [Net::IMAP::ByeResponseError] + # Connected to the host successfully, but it immediately said goodbye. + # + # @return [IMAP] a new instance of IMAP + # + # source://net-imap//lib/net/imap/deprecated_client_options.rb#72 + def initialize(host, port_or_options = T.unsafe(nil), *deprecated, **options); end + + # Adds a response handler. For example, to detect when + # the server sends a new EXISTS response (which normally + # indicates new messages being added to the mailbox), + # add the following handler after selecting the + # mailbox: + # + # imap.add_response_handler { |resp| + # if resp.kind_of?(Net::IMAP::UntaggedResponse) and resp.name == "EXISTS" + # puts "Mailbox now has #{resp.data} messages" + # end + # } + # + # Related: #remove_response_handler, #response_handlers + # + # @raise [ArgumentError] + # + # source://net-imap//lib/net/imap.rb#2614 + def add_response_handler(handler = T.unsafe(nil), &block); end + + # Sends an {APPEND command [IMAP4rev1 §6.3.11]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.11] + # to append the +message+ to the end of the +mailbox+. The optional +flags+ + # argument is an array of flags initially passed to the new message. The + # optional +date_time+ argument specifies the creation time to assign to the + # new message; it defaults to the current time. + # + # For example: + # + # imap.append("inbox", <"AUTH=#{mechanism.to_s.upcase}"
. When + # available, cached capabilities are used without sending a new #capability + # command to the server. + # + # imap.capable? "AUTH=PLAIN" # => true + # imap.auth_capable? "PLAIN" # => true + # imap.auth_capable? "blurdybloop" # => false + # + # Related: #authenticate, #auth_mechanisms, #capable?, #capabilities + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap.rb#1059 + def auth_capable?(mechanism); end + + # Returns the #authenticate mechanisms that the server claims to support. + # These are derived from the #capabilities with an AUTH= prefix. + # + # This may be different when the connection is cleartext or using TLS. Most + # servers will drop all AUTH= mechanisms from #capabilities after + # the connection has authenticated. + # + # imap = Net::IMAP.new(hostname, ssl: false) + # imap.capabilities # => ["IMAP4REV1", "LOGINDISABLED"] + # imap.auth_mechanisms # => [] + # + # imap.starttls + # imap.capabilities # => ["IMAP4REV1", "AUTH=PLAIN", "AUTH=XOAUTH2", + # # "AUTH=OAUTHBEARER"] + # imap.auth_mechanisms # => ["PLAIN", "XOAUTH2", "OAUTHBEARER"] + # + # imap.authenticate("XOAUTH2", username, oauth2_access_token) + # imap.auth_mechanisms # => [] + # + # Related: #authenticate, #auth_capable?, #capabilities + # + # source://net-imap//lib/net/imap.rb#1042 + def auth_mechanisms; end + + # :call-seq: + # authenticate(mechanism, *, sasl_ir: config.sasl_ir, registry: Net::IMAP::SASL.authenticators, **, &) -> ok_resp + # + # Sends an {AUTHENTICATE command [IMAP4rev1 §6.2.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.2] + # to authenticate the client. If successful, the connection enters the + # "_authenticated_" state. + # + # +mechanism+ is the name of the \SASL authentication mechanism to be used. + # + # +sasl_ir+ allows or disallows sending an "initial response" (see the + # +SASL-IR+ capability, below). Defaults to the #config value for + # {sasl_ir}[rdoc-ref:Config#sasl_ir], which defaults to +true+. + # + # All other arguments are forwarded to the registered SASL authenticator for + # the requested mechanism. The documentation for each individual + # mechanism must be consulted for its specific parameters. + # + # Related: #login, #starttls, #auth_capable?, #auth_mechanisms + # + # ==== Mechanisms + # + # Each mechanism has different properties and requirements. Please consult + # the documentation for the specific mechanisms you are using: + # + # +ANONYMOUS+:: + # See AnonymousAuthenticator[rdoc-ref:Net::IMAP::SASL::AnonymousAuthenticator]. + # + # Allows the user to gain access to public services or resources without + # authenticating or disclosing an identity. + # + # +EXTERNAL+:: + # See ExternalAuthenticator[rdoc-ref:Net::IMAP::SASL::ExternalAuthenticator]. + # + # Authenticates using already established credentials, such as a TLS + # certificate or IPsec. + # + # +OAUTHBEARER+:: + # See OAuthBearerAuthenticator[rdoc-ref:Net::IMAP::SASL::OAuthBearerAuthenticator]. + # + # Login using an OAuth2 Bearer token. This is the standard mechanism + # for using OAuth2 with \SASL, but it is not yet deployed as widely as + # +XOAUTH2+. + # + # +PLAIN+:: + # See PlainAuthenticator[rdoc-ref:Net::IMAP::SASL::PlainAuthenticator]. + # + # Login using clear-text username and password. + # + # +SCRAM-SHA-1+:: + # +SCRAM-SHA-256+:: + # See ScramAuthenticator[rdoc-ref:Net::IMAP::SASL::ScramAuthenticator]. + # + # Login by username and password. The password is not sent to the + # server but is used in a salted challenge/response exchange. + # +SCRAM-SHA-1+ and +SCRAM-SHA-256+ are directly supported by + # Net::IMAP::SASL. New authenticators can easily be added for any other + # SCRAM-* mechanism if the digest algorithm is supported by + # OpenSSL::Digest. + # + # +XOAUTH2+:: + # See XOAuth2Authenticator[rdoc-ref:Net::IMAP::SASL::XOAuth2Authenticator]. + # + # Login using a username and an OAuth2 access token. Non-standard and + # obsoleted by +OAUTHBEARER+, but widely supported. + # + # See the {SASL mechanism + # registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] + # for a list of all SASL mechanisms and their specifications. To register + # new authenticators, see Authenticators. + # + # ===== Deprecated mechanisms + # + # Obsolete mechanisms should be avoided, but are still available for + # backwards compatibility. See Net::IMAP::SASL@Deprecated+mechanisms. + # Using a deprecated mechanism will print a warning. + # + # ==== Capabilities + # + # "AUTH=#{mechanism}" capabilities indicate server support for + # mechanisms. Use #auth_capable? or #auth_mechanisms to check for support + # before using a particular mechanism. + # + # if imap.auth_capable? "XOAUTH2" + # imap.authenticate "XOAUTH2", username, oauth2_access_token + # elsif imap.auth_capable? "PLAIN" + # imap.authenticate "PLAIN", username, password + # elsif !imap.capability? "LOGINDISABLED" + # imap.login username, password + # else + # raise "No acceptable authentication mechanism is available" + # end + # + # Although servers should list all supported \SASL mechanisms, they may + # allow authentication with an unlisted +mechanism+. + # + # If [SASL-IR[https://www.rfc-editor.org/rfc/rfc4959.html]] is supported + # and the appropriate "AUTH=#{mechanism}" capability is present, + # an "initial response" may be sent as an argument to the +AUTHENTICATE+ + # command, saving a round-trip. The SASL exchange allows for server + # challenges and client responses, but many mechanisms expect the client to + # "respond" first. The initial response will only be sent for + # "client-first" mechanisms. + # + # Server capabilities may change after #starttls, #login, and #authenticate. + # Previously cached #capabilities will be cleared when this method + # completes. If the TaggedResponse to #authenticate includes updated + # capabilities, they will be cached. + # + # source://net-imap//lib/net/imap.rb#1339 + def authenticate(mechanism, *creds, sasl_ir: T.unsafe(nil), **props, &callback); end + + # Returns the server capabilities. When available, cached capabilities are + # used without sending a new #capability command to the server. + # + # To ensure a case-insensitive comparison, #capable? can be used instead. + # + # *NOTE:* Most Net::IMAP methods do not _currently_ modify their + # behaviour according to the server's advertised #capabilities. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #capable?, #auth_capable?, #auth_mechanisms, #capability, #enable + # + # source://net-imap//lib/net/imap.rb#1018 + def capabilities; end + + # Returns whether capabilities have been cached. When true, #capable? and + # #capabilities don't require sending a #capability command to the server. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #capable?, #capability, #clear_cached_capabilities + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap.rb#1069 + def capabilities_cached?; end + + # Sends a {CAPABILITY command [IMAP4rev1 §6.1.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.1] + # and returns an array of capabilities that are supported by the server. + # The result is stored for use by #capable? and #capabilities. + # + # *NOTE:* Most Net::IMAP methods do not _currently_ modify their + # behaviour according to the server's advertised #capabilities. + # + # Net::IMAP automatically stores and discards capability data according to + # the requirements and recommendations in + # {IMAP4rev2 §6.1.1}[https://www.rfc-editor.org/rfc/rfc9051#section-6.1.1], + # {§6.2}[https://www.rfc-editor.org/rfc/rfc9051#section-6.2], and + # {§7.1}[https://www.rfc-editor.org/rfc/rfc9051#section-7.1]. + # Use #capable?, #auth_capable?, or #capabilities to this cache and avoid + # sending the #capability command unnecessarily. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #capable?, #auth_capable?, #capability, #enable + # + # source://net-imap//lib/net/imap.rb#1107 + def capability; end + + # Returns whether the server supports a given +capability+. When available, + # cached #capabilities are used without sending a new #capability command to + # the server. + # + # *NOTE:* Most Net::IMAP methods do not _currently_ modify their + # behaviour according to the server's advertised #capabilities. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #auth_capable?, #capabilities, #capability, #enable + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap.rb#1004 + def capability?(capability); end + + # Returns whether the server supports a given +capability+. When available, + # cached #capabilities are used without sending a new #capability command to + # the server. + # + # *NOTE:* Most Net::IMAP methods do not _currently_ modify their + # behaviour according to the server's advertised #capabilities. + # + # See Net::IMAP@Capabilities for more about \IMAP capabilities. + # + # Related: #auth_capable?, #capabilities, #capability, #enable + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap.rb#1004 + def capable?(capability); end + + # Sends a {CHECK command [IMAP4rev1 §6.4.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.1] + # to request a checkpoint of the currently selected mailbox. This performs + # implementation-specific housekeeping; for instance, reconciling the + # mailbox's in-memory and on-disk state. + # + # Related: #idle, #noop + # + # source://net-imap//lib/net/imap.rb#1882 + def check; end + + # Clears capabilities that have been remembered by the Net::IMAP client. + # This forces a #capability command to be sent the next time a #capabilities + # query method is called. + # + # Net::IMAP automatically discards its cached capabilities when they can + # change. Explicitly calling this _should_ be unnecessary for well-behaved + # servers. + # + # Related: #capable?, #capability, #capabilities_cached? + # + # source://net-imap//lib/net/imap.rb#1082 + def clear_cached_capabilities; end + + # :call-seq: + # clear_responses -> hash + # clear_responses(type) -> array + # + # Clears and returns the unhandled #responses hash or the unhandled + # responses array for a single response +type+. + # + # Clearing responses is synchronized with other threads. The lock is + # released before returning. + # + # Related: #responses, #response_handlers + # + # source://net-imap//lib/net/imap.rb#2571 + def clear_responses(type = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap.rb#957 + def client_thread; end + + # Sends a {CLOSE command [IMAP4rev1 §6.4.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.2] + # to close the currently selected mailbox. The CLOSE command permanently + # removes from the mailbox all messages that have the \\Deleted + # flag set. + # + # Related: #unselect + # + # source://net-imap//lib/net/imap.rb#1892 + def close; end + + # The client configuration. See Net::IMAP::Config. + # + # By default, the client's local configuration inherits from the global + # Net::IMAP.config. + # + # source://net-imap//lib/net/imap.rb#772 + def config; end + + # Sends a {COPY command [IMAP4rev1 §6.4.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.7] + # to copy the specified message(s) to the end of the specified destination + # +mailbox+. The +set+ parameter is a number, an array of numbers, or a + # Range object. The number is a message sequence number. + # + # Related: #uid_copy + # + # ===== Capabilities + # + # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is + # supported, the server's response should include a +COPYUID+ response code + # with UIDPlusData. This will report the UIDVALIDITY of the destination + # mailbox, the UID set of the source messages, and the assigned UID set of + # the moved messages. + # + # source://net-imap//lib/net/imap.rb#2197 + def copy(set, mailbox); end + + # Sends a {CREATE command [IMAP4rev1 §6.3.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.3] + # to create a new +mailbox+. + # + # A Net::IMAP::NoResponseError is raised if a mailbox with that name + # cannot be created. + # + # Related: #rename, #delete + # + # source://net-imap//lib/net/imap.rb#1466 + def create(mailbox); end + + # Sends a {DELETE command [IMAP4rev1 §6.3.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.4] + # to remove the +mailbox+. + # + # A Net::IMAP::NoResponseError is raised if a mailbox with that name + # cannot be deleted, either because it does not exist or because the + # client does not have permission to delete it. + # + # Related: #create, #rename + # + # source://net-imap//lib/net/imap.rb#1478 + def delete(mailbox); end + + # Disconnects from the server. + # + # Related: #logout, #logout! + # + # source://net-imap//lib/net/imap.rb#965 + def disconnect; end + + # Returns true if disconnected from the server. + # + # Related: #logout, #disconnect + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap.rb#990 + def disconnected?; end + + # Sends an {ENABLE command [RFC5161 §3.2]}[https://www.rfc-editor.org/rfc/rfc5161#section-3.1] + # {[IMAP4rev2 §6.3.1]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.3.1] + # to enable the specified server +capabilities+. Each capability may be an + # array, string, or symbol. Returns a list of the capabilities that were + # enabled. + # + # The +ENABLE+ command is only valid in the _authenticated_ state, before + # any mailbox is selected. + # + # Related: #capable?, #capabilities, #capability + # + # ===== Capabilities + # + # The server's capabilities must include + # +ENABLE+ [RFC5161[https://tools.ietf.org/html/rfc5161]] + # or +IMAP4REV2+ [RFC9051[https://tools.ietf.org/html/rfc9051]]. + # + # Additionally, the server capabilities must include a capability matching + # each enabled extension (usually the same name as the enabled extension). + # The following capabilities may be enabled: + # + # [+CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]] + # + # Updates various commands to return +CONDSTORE+ extension responses. It + # is not necessary to explicitly enable +CONDSTORE+—using any of the + # command parameters defined by the extension will implicitly enable it. + # See {[RFC7162 §3.1]}[https://www.rfc-editor.org/rfc/rfc7162.html#section-3.1]. + # + # [+:utf8+ --- an alias for "UTF8=ACCEPT"] + # + # In a future release, enable(:utf8) will enable either + # "UTF8=ACCEPT" or "IMAP4rev2", depending on server + # capabilities. + # + # ["UTF8=ACCEPT" [RFC6855[https://tools.ietf.org/html/rfc6855]]] + # + # The server's capabilities must include UTF8=ACCEPT _or_ + # UTF8=ONLY. + # + # This allows the server to send strings encoded as UTF-8 which might + # otherwise need to use a 7-bit encoding, such as {modified + # UTF-7}[::decode_utf7] for mailbox names, or RFC2047 encoded-words for + # message headers. + # + # *Note:* A future update may set string encodings slightly + # differently, e.g: "US-ASCII" when UTF-8 is not enabled, and "UTF-8" + # when it is. Currently, the encoding of strings sent as "quoted" or + # "text" will _always_ be "UTF-8", even when only ASCII characters are + # used (e.g. "Subject: Agenda") And currently, string "literals" sent + # by the server will always have an "ASCII-8BIT" (binary) + # encoding, even if they generally contain UTF-8 data, if they are + # text at all. + # + # ["UTF8=ONLY" [RFC6855[https://tools.ietf.org/html/rfc6855]]] + # + # A server that reports the UTF8=ONLY capability _requires_ that + # the client enable("UTF8=ACCEPT") before any mailboxes may be + # selected. For convenience, enable("UTF8=ONLY") is aliased to + # enable("UTF8=ACCEPT"). + # + # ===== Unsupported capabilities + # + # *Note:* Some extensions that use ENABLE permit the server to send syntax + # that Net::IMAP cannot parse, which may raise an exception and disconnect. + # Some extensions may work, but the support may be incomplete, untested, or + # experimental. + # + # Until a capability is documented here as supported, enabling it may result + # in undocumented behavior and a future release may update with incompatible + # behavior without warning or deprecation. + # + # Caution is advised. + # + # source://net-imap//lib/net/imap.rb#2408 + def enable(*capabilities); end + + # Sends a {EXAMINE command [IMAP4rev1 §6.3.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.2] + # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. + # Behaves the same as #select, except that the selected +mailbox+ is + # identified as read-only. + # + # A Net::IMAP::NoResponseError is raised if the mailbox does not + # exist or is for some reason non-examinable. + # + # Related: #select + # + # source://net-imap//lib/net/imap.rb#1450 + def examine(mailbox, condstore: T.unsafe(nil)); end + + # Sends an {EXPUNGE command [IMAP4rev1 §6.4.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.3] + # Sends a EXPUNGE command to permanently remove from the currently + # selected mailbox all messages that have the \Deleted flag set. + # + # Related: #uid_expunge + # + # source://net-imap//lib/net/imap.rb#1917 + def expunge; end + + # :call-seq: + # fetch(set, attr, changedsince: nil) -> array of FetchData + # + # Sends a {FETCH command [IMAP4rev1 §6.4.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.5] + # to retrieve data associated with a message in the mailbox. + # + # The +set+ parameter is a number or a range between two numbers, + # or an array of those. The number is a message sequence number, + # where -1 represents a '*' for use in range notation like 100..-1 + # being interpreted as '100:*'. Beware that the +exclude_end?+ + # property of a Range object is ignored, and the contents of a + # range are independent of the order of the range endpoints as per + # the protocol specification, so 1...5, 5..1 and 5...1 are all + # equivalent to 1..5. + # + # +attr+ is a list of attributes to fetch; see the documentation + # for FetchData for a list of valid attributes. + # + # +changedsince+ is an optional integer mod-sequence. It limits results to + # messages with a mod-sequence greater than +changedsince+. + # + # The return value is an array of FetchData. + # + # Related: #uid_search, FetchData + # + # ===== For example: + # + # p imap.fetch(6..8, "UID") + # #=> [#98}>, \\ + # #99}>, \\ + # #100}>] + # p imap.fetch(6, "BODY[HEADER.FIELDS (SUBJECT)]") + # #=> [#"Subject: test\r\n\r\n"}>] + # data = imap.uid_fetch(98, ["RFC822.SIZE", "INTERNALDATE"])[0] + # p data.seqno + # #=> 6 + # p data.attr["RFC822.SIZE"] + # #=> 611 + # p data.attr["INTERNALDATE"] + # #=> "12-Oct-2000 22:40:59 +0900" + # p data.attr["UID"] + # #=> 98 + # + # ===== Capabilities + # + # Many extensions define new message +attr+ names. See FetchData for a list + # of supported extension fields. + # + # The server's capabilities must include +CONDSTORE+ + # {[RFC7162]}[https://tools.ietf.org/html/rfc7162] in order to use the + # +changedsince+ argument. Using +changedsince+ implicitly enables the + # +CONDSTORE+ extension. + # + # source://net-imap//lib/net/imap.rb#2092 + def fetch(set, attr, mod = T.unsafe(nil), changedsince: T.unsafe(nil)); end + + # Sends a {GETACL command [RFC4314 §3.3]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.3] + # along with a specified +mailbox+. If this mailbox exists, an array + # containing objects of MailboxACLItem will be returned. + # + # Related: #setacl, MailboxACLItem + # + # ===== Capabilities + # + # The server's capabilities must include +ACL+ + # [RFC4314[https://tools.ietf.org/html/rfc4314]]. + # + # source://net-imap//lib/net/imap.rb#1746 + def getacl(mailbox); end + + # Sends a {GETQUOTA command [RFC2087 §4.2]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.2] + # along with specified +mailbox+. If this mailbox exists, then an array + # containing a MailboxQuota object is returned. This command is generally + # only available to server admin. + # + # Related: #getquotaroot, #setquota, MailboxQuota + # + # ===== Capabilities + # + # The server's capabilities must include +QUOTA+ + # [RFC2087[https://tools.ietf.org/html/rfc2087]]. + # + # source://net-imap//lib/net/imap.rb#1690 + def getquota(mailbox); end + + # Sends a {GETQUOTAROOT command [RFC2087 §4.3]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.3] + # along with the specified +mailbox+. This command is generally available + # to both admin and user. If this mailbox exists, it returns an array + # containing objects of type MailboxQuotaRoot and MailboxQuota. + # + # Related: #getquota, #setquota, MailboxQuotaRoot, MailboxQuota + # + # ===== Capabilities + # + # The server's capabilities must include +QUOTA+ + # [RFC2087[https://tools.ietf.org/html/rfc2087]]. + # + # source://net-imap//lib/net/imap.rb#1669 + def getquotaroot(mailbox); end + + # Returns the initial greeting the server, an UntaggedResponse. + # + # source://net-imap//lib/net/imap.rb#766 + def greeting; end + + # The hostname this client connected to + # + # source://net-imap//lib/net/imap.rb#783 + def host; end + + # Sends an {ID command [RFC2971 §3.1]}[https://www.rfc-editor.org/rfc/rfc2971#section-3.1] + # and returns a hash of the server's response, or nil if the server does not + # identify itself. + # + # Note that the user should first check if the server supports the ID + # capability. For example: + # + # if capable?(:ID) + # id = imap.id( + # name: "my IMAP client (ruby)", + # version: MyIMAP::VERSION, + # "support-url": "mailto:bugs@example.com", + # os: RbConfig::CONFIG["host_os"], + # ) + # end + # + # See [ID[https://tools.ietf.org/html/rfc2971]] for field definitions. + # + # ===== Capabilities + # + # The server's capabilities must include +ID+ + # [RFC2971[https://tools.ietf.org/html/rfc2971]]. + # + # source://net-imap//lib/net/imap.rb#1136 + def id(client_id = T.unsafe(nil)); end + + # Sends an {IDLE command [RFC2177 §3]}[https://www.rfc-editor.org/rfc/rfc6851#section-3] + # {[IMAP4rev2 §6.3.13]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.3.13] + # that waits for notifications of new or expunged messages. Yields + # responses from the server during the IDLE. + # + # Use #idle_done to leave IDLE. + # + # If +timeout+ is given, this method returns after +timeout+ seconds passed. + # +timeout+ can be used for keep-alive. For example, the following code + # checks the connection for each 60 seconds. + # + # loop do + # imap.idle(60) do |response| + # do_something_with(response) + # imap.idle_done if some_condition?(response) + # end + # end + # + # Returns the server's response to indicate the IDLE state has ended. + # Returns +nil+ if the server does not respond to #idle_done within + # {config.idle_response_timeout}[rdoc-ref:Config#idle_response_timeout] + # seconds. + # + # Related: #idle_done, #noop, #check + # + # ===== Capabilities + # + # The server's capabilities must include +IDLE+ + # [RFC2177[https://tools.ietf.org/html/rfc2177]]. + # + # @raise [LocalJumpError] + # + # source://net-imap//lib/net/imap.rb#2452 + def idle(timeout = T.unsafe(nil), &response_handler); end + + # Leaves IDLE, allowing #idle to return. + # + # If the server does not respond within + # {config.idle_response_timeout}[rdoc-ref:Config#idle_response_timeout] + # seconds, #idle will return +nil+. + # + # Related: #idle + # + # source://net-imap//lib/net/imap.rb#2488 + def idle_done; end + + # Seconds to wait until an IDLE response is received. + # + # source://net-imap//lib/net/imap.rb#780 + def idle_response_timeout; end + + # Sends a {LIST command [IMAP4rev1 §6.3.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.8] + # and returns a subset of names from the complete set of all names available + # to the client. +refname+ provides a context (for instance, a base + # directory in a directory-based mailbox hierarchy). +mailbox+ specifies a + # mailbox or (via wildcards) mailboxes under that context. Two wildcards + # may be used in +mailbox+: "*", which matches all characters + # *including* the hierarchy delimiter (for instance, "/" on a UNIX-hosted + # directory-based mailbox hierarchy); and "%", which matches all + # characters *except* the hierarchy delimiter. + # + # If +refname+ is empty, +mailbox+ is used directly to determine + # which mailboxes to match. If +mailbox+ is empty, the root + # name of +refname+ and the hierarchy delimiter are returned. + # + # The return value is an array of MailboxList. + # + # Related: #lsub, MailboxList + # + # ===== For example: + # + # imap.create("foo/bar") + # imap.create("foo/baz") + # p imap.list("", "foo/%") + # #=> [#, \\ + # #, \\ + # #] + # + # -- + # TODO: support LIST-EXTENDED extension [RFC5258]. Needed for IMAP4rev2. + # ++ + # + # source://net-imap//lib/net/imap.rb#1550 + def list(refname, mailbox); end + + # Sends a {LOGIN command [IMAP4rev1 §6.2.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.3] + # to identify the client and carries the plaintext +password+ authenticating + # this +user+. If successful, the connection enters the "_authenticated_" + # state. + # + # Using #authenticate {should be + # preferred}[https://www.rfc-editor.org/rfc/rfc9051.html#name-login-command] + # over #login. The LOGIN command is not the same as #authenticate with the + # "LOGIN" +mechanism+. + # + # A Net::IMAP::NoResponseError is raised if authentication fails. + # + # Related: #authenticate, #starttls + # + # ===== Capabilities + # + # An IMAP client MUST NOT call #login when the server advertises the + # +LOGINDISABLED+ capability. + # + # if imap.capability? "LOGINDISABLED" + # raise "Remote server has disabled the login command" + # else + # imap.login username, password + # end + # + # Server capabilities may change after #starttls, #login, and #authenticate. + # Cached capabilities _must_ be invalidated after this method completes. + # The TaggedResponse to #login may include updated capabilities in its + # ResponseCode. + # + # source://net-imap//lib/net/imap.rb#1394 + def login(user, password); end + + # Sends a {LOGOUT command [IMAP4rev1 §6.1.3]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.3] + # to inform the command to inform the server that the client is done with + # the connection. + # + # Related: #disconnect, #logout! + # + # source://net-imap//lib/net/imap.rb#1164 + def logout; end + + # Calls #logout then, after receiving the TaggedResponse for the +LOGOUT+, + # calls #disconnect. Returns the TaggedResponse from +LOGOUT+. Returns + # +nil+ when the client is already disconnected, in contrast to #logout + # which raises an exception. + # + # If #logout raises a StandardError, a warning will be printed but the + # exception will not be re-raised. + # + # This is useful in situations where the connection must be dropped, for + # example for security or after tests. If logout errors need to be handled, + # use #logout and #disconnect instead. + # + # Related: #logout, #disconnect + # + # source://net-imap//lib/net/imap.rb#1181 + def logout!; end + + # Sends a {LSUB command [IMAP4rev1 §6.3.9]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.9] + # and returns a subset of names from the set of names that the user has + # declared as being "active" or "subscribed." +refname+ and +mailbox+ are + # interpreted as for #list. + # + # The return value is an array of MailboxList objects. + # + # Related: #subscribe, #unsubscribe, #list, MailboxList + # + # source://net-imap//lib/net/imap.rb#1761 + def lsub(refname, mailbox); end + + # Sends a {MOVE command [RFC6851 §3.1]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.1] + # {[IMAP4rev2 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.8] + # to move the specified message(s) to the end of the specified destination + # +mailbox+. The +set+ parameter is a number, an array of numbers, or a + # Range object. The number is a message sequence number. + # + # Related: #uid_move + # + # ===== Capabilities + # + # The server's capabilities must include +MOVE+ + # [RFC6851[https://tools.ietf.org/html/rfc6851]]. + # + # If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is + # supported, the server's response should include a +COPYUID+ response code + # with UIDPlusData. This will report the UIDVALIDITY of the destination + # mailbox, the UID set of the source messages, and the assigned UID set of + # the moved messages. + # + # source://net-imap//lib/net/imap.rb#2233 + def move(set, mailbox); end + + # Sends a {NAMESPACE command [RFC2342 §5]}[https://www.rfc-editor.org/rfc/rfc2342#section-5] + # and returns the namespaces that are available. The NAMESPACE command + # allows a client to discover the prefixes of namespaces used by a server + # for personal mailboxes, other users' mailboxes, and shared mailboxes. + # + # The return value is a Namespaces object which has +personal+, +other+, and + # +shared+ fields, each an array of Namespace objects. These arrays will be + # empty when the server responds with +nil+. + # + # Many \IMAP servers are configured with the default personal namespaces as + # ("" "/"): no prefix and the "+/+" hierarchy delimiter. In that + # common case, the naive client may not have any trouble naming mailboxes. + # But many servers are configured with the default personal namespace as + # e.g. ("INBOX." "."), placing all personal folders under INBOX, + # with "+.+" as the hierarchy delimiter. If the client does not check for + # this, but naively assumes it can use the same folder names for all + # servers, then folder creation (and listing, moving, etc) can lead to + # errors. + # + # From RFC2342[https://tools.ietf.org/html/rfc2342]: + # >>> + # Although typically a server will support only a single Personal + # Namespace, and a single Other User's Namespace, circumstances exist + # where there MAY be multiples of these, and a client MUST be prepared + # for them. If a client is configured such that it is required to create + # a certain mailbox, there can be circumstances where it is unclear which + # Personal Namespaces it should create the mailbox in. In these + # situations a client SHOULD let the user select which namespaces to + # create the mailbox in. + # + # Related: #list, Namespaces, Namespace + # + # ===== For example: + # + # if capable?("NAMESPACE") + # namespaces = imap.namespace + # if namespace = namespaces.personal.first + # prefix = namespace.prefix # e.g. "" or "INBOX." + # delim = namespace.delim # e.g. "/" or "." + # # personal folders should use the prefix and delimiter + # imap.create(prefix + "foo") + # imap.create(prefix + "bar") + # imap.create(prefix + %w[path to my folder].join(delim)) + # end + # end + # + # ===== Capabilities + # + # The server's capabilities must include +NAMESPACE+ + # [RFC2342[https://tools.ietf.org/html/rfc2342]]. + # + # source://net-imap//lib/net/imap.rb#1607 + def namespace; end + + # Sends a {NOOP command [IMAP4rev1 §6.1.2]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.1.2] + # to the server. + # + # This allows the server to send unsolicited untagged EXPUNGE #responses, + # but does not execute any client request. \IMAP servers are permitted to + # send unsolicited untagged responses at any time, except for +EXPUNGE+: + # + # * +EXPUNGE+ can only be sent while a command is in progress. + # * +EXPUNGE+ must _not_ be sent during #fetch, #store, or #search. + # * +EXPUNGE+ may be sent during #uid_fetch, #uid_store, or #uid_search. + # + # Related: #idle, #check + # + # source://net-imap//lib/net/imap.rb#1155 + def noop; end + + # Seconds to wait until a connection is opened. + # If the IMAP object cannot open a connection within this time, + # it raises a Net::OpenTimeout exception. The default value is 30 seconds. + # + # source://net-imap//lib/net/imap.rb#777 + def open_timeout; end + + # The port this client connected to + # + # source://net-imap//lib/net/imap.rb#786 + def port; end + + # Removes the response handler. + # + # Related: #add_response_handler, #response_handlers + # + # source://net-imap//lib/net/imap.rb#2624 + def remove_response_handler(handler); end + + # Sends a {RENAME command [IMAP4rev1 §6.3.5]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.5] + # to change the name of the +mailbox+ to +newname+. + # + # A Net::IMAP::NoResponseError is raised if a mailbox with the + # name +mailbox+ cannot be renamed to +newname+ for whatever + # reason; for instance, because +mailbox+ does not exist, or + # because there is already a mailbox with the name +newname+. + # + # Related: #create, #delete + # + # source://net-imap//lib/net/imap.rb#1491 + def rename(mailbox, newname); end + + # Returns all response handlers, including those that are added internally + # by commands. Each response handler will be called with every new + # UntaggedResponse, TaggedResponse, and ContinuationRequest. + # + # Response handlers are called with a mutex inside the receiver thread. New + # responses cannot be processed and commands from other threads must wait + # until all response_handlers return. An exception will shut-down the + # receiver thread and close the connection. + # + # For thread-safety, the returned array is a frozen copy of the internal + # array. + # + # Related: #add_response_handler, #remove_response_handler + # + # source://net-imap//lib/net/imap.rb#2597 + def response_handlers; end + + # :call-seq: + # responses {|hash| ...} -> block result + # responses(type) {|array| ...} -> block result + # + # Yields unhandled responses and returns the result of the block. + # + # Unhandled responses are stored in a hash, with arrays of + # non-+nil+ UntaggedResponse#data keyed by UntaggedResponse#name + # and ResponseCode#data keyed by ResponseCode#name. Call without +type+ to + # yield the entire responses hash. Call with +type+ to yield only the array + # of responses for that type. + # + # For example: + # + # imap.select("inbox") + # p imap.responses("EXISTS", &:last) + # #=> 2 + # p imap.responses("UIDVALIDITY", &:last) + # #=> 968263756 + # + # >>> + # *Note:* Access to the responses hash is synchronized for thread-safety. + # The receiver thread and response_handlers cannot process new responses + # until the block completes. Accessing either the response hash or its + # response type arrays outside of the block is unsafe. + # + # Calling without a block is unsafe and deprecated. Future releases will + # raise ArgumentError unless a block is given. + # See Config#responses_without_block. + # + # Previously unhandled responses are automatically cleared before entering a + # mailbox with #select or #examine. Long-lived connections can receive many + # unhandled server responses, which must be pruned or they will continually + # consume more memory. Update or clear the responses hash or arrays inside + # the block, or use #clear_responses. + # + # Only non-+nil+ data is stored. Many important response codes have no data + # of their own, but are used as "tags" on the ResponseText object they are + # attached to. ResponseText will be accessible by its response types: + # "+OK+", "+NO+", "+BAD+", "+BYE+", or "+PREAUTH+". + # + # TaggedResponse#data is not saved to #responses, nor is any + # ResponseCode#data on tagged responses. Although some command methods do + # return the TaggedResponse directly, #add_response_handler must be used to + # handle all response codes. + # + # Related: #clear_responses, #response_handlers, #greeting + # + # source://net-imap//lib/net/imap.rb#2544 + def responses(type = T.unsafe(nil)); end + + # Sends a {SEARCH command [IMAP4rev1 §6.4.4]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.4] + # to search the mailbox for messages that match the given searching + # criteria, and returns message sequence numbers. +keys+ can either be a + # string holding the entire search string, or a single-dimension array of + # search keywords and arguments. + # + # Returns a SearchResult object. SearchResult inherits from Array (for + # backward compatibility) but adds SearchResult#modseq when the +CONDSTORE+ + # capability has been enabled. + # + # Related: #uid_search + # + # ===== Search criteria + # + # For a full list of search criteria, + # see [{IMAP4rev1 §6.4.4}[https://www.rfc-editor.org/rfc/rfc3501.html#section-6.4.4]], + # or [{IMAP4rev2 §6.4.4}[https://www.rfc-editor.org/rfc/rfc9051.html#section-6.4.4]], + # in addition to documentation for + # any [CAPABILITIES[https://www.iana.org/assignments/imap-capabilities/imap-capabilities.xhtml]] + # reported by #capabilities which may define additional search filters, e.g: + # +CONDSTORE+, +WITHIN+, +FILTERS+, SEARCH=FUZZY, +OBJECTID+, or + # +SAVEDATE+. The following are some common search criteria: + # + # :: a set of message sequence numbers. "," indicates + # an interval, "+:+" indicates a range. For instance, + # "2,10:12,15" means "2,10,11,12,15". + # + # BEFORE :: messages with an internal date strictly before + # . The date argument has a format similar + # to 8-Aug-2002, and can be formatted using + # Net::IMAP.format_date. + # + # BODY :: messages that contain within their body. + # + # CC :: messages containing in their CC field. + # + # FROM :: messages that contain in their FROM field. + # + # NEW:: messages with the \Recent, but not the \Seen, flag set. + # + # NOT :: negate the following search key. + # + # OR :: "or" two search keys together. + # + # ON :: messages with an internal date exactly equal to , + # which has a format similar to 8-Aug-2002. + # + # SINCE :: messages with an internal date on or after . + # + # SUBJECT :: messages with in their subject. + # + # TO :: messages with in their TO field. + # + # ===== For example: + # + # p imap.search(["SUBJECT", "hello", "NOT", "NEW"]) + # #=> [1, 6, 7, 8] + # + # ===== Capabilities + # + # If [CONDSTORE[https://www.rfc-editor.org/rfc/rfc7162.html]] is supported + # and enabled for the selected mailbox, a non-empty SearchResult will + # include a +MODSEQ+ value. + # imap.select("mbox", condstore: true) + # result = imap.search(["SUBJECT", "hi there", "not", "new") + # #=> Net::IMAP::SearchResult[1, 6, 7, 8, modseq: 5594] + # result.modseq # => 5594 + # + # source://net-imap//lib/net/imap.rb#2023 + def search(keys, charset = T.unsafe(nil)); end + + # Sends a {SELECT command [IMAP4rev1 §6.3.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.1] + # to select a +mailbox+ so that messages in the +mailbox+ can be accessed. + # + # After you have selected a mailbox, you may retrieve the number of items in + # that mailbox from imap.responses("EXISTS", &:last), and the + # number of recent messages from imap.responses("RECENT", &:last). + # Note that these values can change if new messages arrive during a session + # or when existing messages are expunged; see #add_response_handler for a + # way to detect these events. + # + # When the +condstore+ keyword argument is true, the server is told to + # enable the extension. If +mailbox+ supports persistence of mod-sequences, + # the +HIGHESTMODSEQ+ ResponseCode will be sent as an untagged response to + # #select and all `FETCH` responses will include FetchData#modseq. + # Otherwise, the +NOMODSEQ+ ResponseCode will be sent. + # + # A Net::IMAP::NoResponseError is raised if the mailbox does not + # exist or is for some reason non-selectable. + # + # Related: #examine + # + # ===== Capabilities + # + # If [UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]] is supported, + # the server may return an untagged "NO" response with a "UIDNOTSTICKY" + # response code indicating that the mailstore does not support persistent + # UIDs: + # imap.responses("NO", &:last)&.code&.name == "UIDNOTSTICKY" + # + # If [CONDSTORE[https://www.rfc-editor.org/rfc/rfc7162.html]] is supported, + # the +condstore+ keyword parameter may be used. + # imap.select("mbox", condstore: true) + # modseq = imap.responses("HIGHESTMODSEQ", &:last) + # + # source://net-imap//lib/net/imap.rb#1432 + def select(mailbox, condstore: T.unsafe(nil)); end + + # Sends a {SETACL command [RFC4314 §3.1]}[https://www.rfc-editor.org/rfc/rfc4314#section-3.1] + # along with +mailbox+, +user+ and the +rights+ that user is to have on that + # mailbox. If +rights+ is nil, then that user will be stripped of any + # rights to that mailbox. + # + # Related: #getacl + # + # ===== Capabilities + # + # The server's capabilities must include +ACL+ + # [RFC4314[https://tools.ietf.org/html/rfc4314]]. + # + # source://net-imap//lib/net/imap.rb#1728 + def setacl(mailbox, user, rights); end + + # Sends a {SETQUOTA command [RFC2087 §4.1]}[https://www.rfc-editor.org/rfc/rfc2087#section-4.1] + # along with the specified +mailbox+ and +quota+. If +quota+ is nil, then + # +quota+ will be unset for that mailbox. Typically one needs to be logged + # in as a server admin for this to work. + # + # Related: #getquota, #getquotaroot + # + # ===== Capabilities + # + # The server's capabilities must include +QUOTA+ + # [RFC2087[https://tools.ietf.org/html/rfc2087]]. + # + # source://net-imap//lib/net/imap.rb#1708 + def setquota(mailbox, quota); end + + # Sends a {SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # to search a mailbox for messages that match +search_keys+ and return an + # array of message sequence numbers, sorted by +sort_keys+. +search_keys+ + # are interpreted the same as for #search. + # + # -- + # TODO: describe +sort_keys+ + # ++ + # + # Related: #uid_sort, #search, #uid_search, #thread, #uid_thread + # + # ===== For example: + # + # p imap.sort(["FROM"], ["ALL"], "US-ASCII") + # #=> [1, 2, 3, 5, 6, 7, 8, 4, 9] + # p imap.sort(["DATE"], ["SUBJECT", "hello"], "US-ASCII") + # #=> [6, 7, 8, 1] + # + # ===== Capabilities + # + # The server's capabilities must include +SORT+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + # + # source://net-imap//lib/net/imap.rb#2277 + def sort(sort_keys, search_keys, charset); end + + # Returns the + # {SSLContext}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html] + # used by the SSLSocket when TLS is attempted, even when the TLS handshake + # is unsuccessful. The context object will be frozen. + # + # Returns +nil+ for a plaintext connection. + # + # source://net-imap//lib/net/imap.rb#794 + def ssl_ctx; end + + # Returns the parameters that were sent to #ssl_ctx + # {set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params] + # when the connection tries to use TLS (even when unsuccessful). + # + # Returns +false+ for a plaintext connection. + # + # source://net-imap//lib/net/imap.rb#801 + def ssl_ctx_params; end + + # Sends a {STARTTLS command [IMAP4rev1 §6.2.1]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.2.1] + # to start a TLS session. + # + # Any +options+ are forwarded directly to + # {OpenSSL::SSL::SSLContext#set_params}[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html#method-i-set_params]; + # the keys are names of attribute assignment methods on + # SSLContext[https://docs.ruby-lang.org/en/master/OpenSSL/SSL/SSLContext.html]. + # + # See DeprecatedClientOptions#starttls for deprecated arguments. + # + # This method returns after TLS negotiation and hostname verification are + # both successful. Any error indicates that the connection has not been + # secured. + # + # *Note:* + # >>> + # Any #response_handlers added before STARTTLS should be aware that the + # TaggedResponse to STARTTLS is sent clear-text, _before_ TLS negotiation. + # TLS starts immediately _after_ that response. Any response code sent + # with the response (e.g. CAPABILITY) is insecure and cannot be trusted. + # + # Related: Net::IMAP.new, #login, #authenticate + # + # ===== Capability + # Clients should not call #starttls unless the server advertises the + # +STARTTLS+ capability. + # + # Server capabilities may change after #starttls, #login, and #authenticate. + # Cached #capabilities will be cleared when this method completes. + # + # source://net-imap//lib/net/imap/deprecated_client_options.rb#104 + def starttls(*deprecated, **options); end + + # Sends a {STATUS command [IMAP4rev1 §6.3.10]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.10] + # and returns the status of the indicated +mailbox+. +attr+ is a list of one + # or more attributes whose statuses are to be requested. + # + # The return value is a hash of attributes. Most status attributes return + # integer values, but some return other value types (documented below). + # + # A Net::IMAP::NoResponseError is raised if status values + # for +mailbox+ cannot be returned; for instance, because it + # does not exist. + # + # ===== Supported attributes + # + # +MESSAGES+:: The number of messages in the mailbox. + # + # +UIDNEXT+:: The next unique identifier value of the mailbox. + # + # +UIDVALIDITY+:: The unique identifier validity value of the mailbox. + # + # +UNSEEN+:: The number of messages without the \Seen flag. + # + # +DELETED+:: The number of messages with the \Deleted flag. + # + # +SIZE+:: + # The approximate size of the mailbox---must be greater than or equal to + # the sum of all messages' +RFC822.SIZE+ fetch item values. + # + # +HIGHESTMODSEQ+:: + # The highest mod-sequence value of all messages in the mailbox. See + # +CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # + # +MAILBOXID+:: + # A server-allocated unique _string_ identifier for the mailbox. See + # +OBJECTID+ {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + # + # +RECENT+:: + # The number of messages with the \Recent flag. + # _NOTE:_ +RECENT+ was removed from IMAP4rev2. + # + # Unsupported attributes may be requested. The attribute value will be + # either an Integer or an ExtensionData object. + # + # ===== For example: + # + # p imap.status("inbox", ["MESSAGES", "RECENT"]) + # #=> {"RECENT"=>0, "MESSAGES"=>44} + # + # ===== Capabilities + # + # +SIZE+ requires the server's capabilities to include either +IMAP4rev2+ or + # STATUS=SIZE + # {[RFC8483]}[https://www.rfc-editor.org/rfc/rfc8483.html]. + # + # +DELETED+ requires the server's capabilities to include +IMAP4rev2+. + # + # +HIGHESTMODSEQ+ requires the server's capabilities to include +CONDSTORE+ + # {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # + # +MAILBOXID+ requires the server's capabilities to include +OBJECTID+ + # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + # + # source://net-imap//lib/net/imap.rb#1828 + def status(mailbox, attr); end + + # :call-seq: + # store(set, attr, value, unchangedsince: nil) -> array of FetchData + # + # Sends a {STORE command [IMAP4rev1 §6.4.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.6] + # to alter data associated with messages in the mailbox, in particular their + # flags. + # + # +set+ is a number, an array of numbers, or a Range object. Each number is + # a message sequence number. + # + # +attr+ is the name of a data item to store. The semantics of +value+ + # varies based on +attr+: + # * When +attr+ is "FLAGS", the flags in +value+ replace the + # message's flag list. + # * When +attr+ is "+FLAGS", the flags in +value+ are added to + # the flags for the message. + # * When +attr+ is "-FLAGS", the flags in +value+ are removed + # from the message. + # + # +unchangedsince+ is an optional integer mod-sequence. It prohibits any + # changes to messages with +mod-sequence+ greater than the specified + # +unchangedsince+ value. A SequenceSet of any messages that fail this + # check will be returned in a +MODIFIED+ ResponseCode. + # + # The return value is an array of FetchData. + # + # Related: #uid_store + # + # ===== For example: + # + # p imap.store(6..8, "+FLAGS", [:Deleted]) + # #=> [#[:Seen, :Deleted]}>, + # #[:Seen, :Deleted]}>, + # #[:Seen, :Deleted]}>] + # + # ===== Capabilities + # + # Extensions may define new data items to be used with #store. + # + # The server's capabilities must include +CONDSTORE+ + # {[RFC7162]}[https://tools.ietf.org/html/rfc7162] in order to use the + # +unchangedsince+ argument. Using +unchangedsince+ implicitly enables the + # +CONDSTORE+ extension. + # + # source://net-imap//lib/net/imap.rb#2161 + def store(set, attr, flags, unchangedsince: T.unsafe(nil)); end + + # Sends a {SUBSCRIBE command [IMAP4rev1 §6.3.6]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.6] + # to add the specified +mailbox+ name to the server's set of "active" or + # "subscribed" mailboxes as returned by #lsub. + # + # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be + # subscribed to; for instance, because it does not exist. + # + # Related: #unsubscribe, #lsub, #list + # + # source://net-imap//lib/net/imap.rb#1503 + def subscribe(mailbox); end + + # Sends a {THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # to search a mailbox and return message sequence numbers in threaded + # format, as a ThreadMember tree. +search_keys+ are interpreted the same as + # for #search. + # + # The supported algorithms are: + # + # ORDEREDSUBJECT:: split into single-level threads according to subject, + # ordered by date. + # REFERENCES:: split into threads by parent/child relationships determined + # by which message is a reply to which. + # + # Unlike #search, +charset+ is a required argument. US-ASCII + # and UTF-8 are sample values. + # + # Related: #uid_thread, #search, #uid_search, #sort, #uid_sort + # + # ===== Capabilities + # + # The server's capabilities must include +THREAD+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + # + # source://net-imap//lib/net/imap.rb#2317 + def thread(algorithm, search_keys, charset); end + + # Returns true after the TLS negotiation has completed and the remote + # hostname has been verified. Returns false when TLS has been established + # but peer verification was disabled. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap.rb#955 + def tls_verified?; end + + # Sends a {UID COPY command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to copy the specified message(s) to the end of the specified destination + # +mailbox+. + # + # Similar to #copy, but +set+ contains unique identifiers. + # + # ===== Capabilities + # + # +UIDPLUS+ affects #uid_copy the same way it affects #copy. + # + # source://net-imap//lib/net/imap.rb#2210 + def uid_copy(set, mailbox); end + + # Sends a {UID EXPUNGE command [RFC4315 §2.1]}[https://www.rfc-editor.org/rfc/rfc4315#section-2.1] + # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] + # to permanently remove all messages that have both the \\Deleted + # flag set and a UID that is included in +uid_set+. + # + # By using #uid_expunge instead of #expunge when resynchronizing with + # the server, the client can ensure that it does not inadvertantly + # remove any messages that have been marked as \\Deleted by other + # clients between the time that the client was last connected and + # the time the client resynchronizes. + # + # *Note:* + # >>> + # Although the command takes a set of UIDs for its argument, the + # server still returns regular EXPUNGE responses, which contain + # a sequence number. These will be deleted from + # #responses and this method returns them as an array of + # sequence number integers. + # + # Related: #expunge + # + # ===== Capabilities + # + # The server's capabilities must include +UIDPLUS+ + # [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]]. + # + # source://net-imap//lib/net/imap.rb#1949 + def uid_expunge(uid_set); end + + # :call-seq: + # uid_fetch(set, attr, changedsince: nil) -> array of FetchData + # + # Sends a {UID FETCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to retrieve data associated with a message in the mailbox. + # + # Similar to #fetch, but the +set+ parameter contains unique identifiers + # instead of message sequence numbers. + # + # >>> + # *Note:* Servers _MUST_ implicitly include the +UID+ message data item as + # part of any +FETCH+ response caused by a +UID+ command, regardless of + # whether a +UID+ was specified as a message data item to the +FETCH+. + # + # Related: #fetch, FetchData + # + # ===== Capabilities + # Same as #fetch. + # + # source://net-imap//lib/net/imap.rb#2114 + def uid_fetch(set, attr, mod = T.unsafe(nil), changedsince: T.unsafe(nil)); end + + # Sends a {UID MOVE command [RFC6851 §3.2]}[https://www.rfc-editor.org/rfc/rfc6851#section-3.2] + # {[IMAP4rev2 §6.4.9]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.9] + # to move the specified message(s) to the end of the specified destination + # +mailbox+. + # + # Similar to #move, but +set+ contains unique identifiers. + # + # Related: #move + # + # ===== Capabilities + # + # Same as #move: The server's capabilities must include +MOVE+ + # [RFC6851[https://tools.ietf.org/html/rfc6851]]. +UIDPLUS+ also affects + # #uid_move the same way it affects #move. + # + # source://net-imap//lib/net/imap.rb#2251 + def uid_move(set, mailbox); end + + # Sends a {UID SEARCH command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to search the mailbox for messages that match the given searching + # criteria, and returns unique identifiers (UIDs). + # + # Returns a SearchResult object. SearchResult inherits from Array (for + # backward compatibility) but adds SearchResult#modseq when the +CONDSTORE+ + # capability has been enabled. + # + # See #search for documentation of search criteria. + # + # source://net-imap//lib/net/imap.rb#2036 + def uid_search(keys, charset = T.unsafe(nil)); end + + # Sends a {UID SORT command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # to search a mailbox for messages that match +search_keys+ and return an + # array of unique identifiers, sorted by +sort_keys+. +search_keys+ are + # interpreted the same as for #search. + # + # Related: #sort, #search, #uid_search, #thread, #uid_thread + # + # ===== Capabilities + # + # The server's capabilities must include +SORT+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + # + # source://net-imap//lib/net/imap.rb#2292 + def uid_sort(sort_keys, search_keys, charset); end + + # :call-seq: + # uid_store(set, attr, value, unchangedsince: nil) -> array of FetchData + # + # Sends a {UID STORE command [IMAP4rev1 §6.4.8]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.4.8] + # to alter data associated with messages in the mailbox, in particular their + # flags. + # + # Similar to #store, but +set+ contains unique identifiers instead of + # message sequence numbers. + # + # Related: #store + # + # ===== Capabilities + # Same as #store. + # + # source://net-imap//lib/net/imap.rb#2179 + def uid_store(set, attr, flags, unchangedsince: T.unsafe(nil)); end + + # Sends a {UID THREAD command [RFC5256 §3]}[https://www.rfc-editor.org/rfc/rfc5256#section-3] + # Similar to #thread, but returns unique identifiers instead of + # message sequence numbers. + # + # Related: #thread, #search, #uid_search, #sort, #uid_sort + # + # ===== Capabilities + # + # The server's capabilities must include +THREAD+ + # [RFC5256[https://tools.ietf.org/html/rfc5256]]. + # + # source://net-imap//lib/net/imap.rb#2331 + def uid_thread(algorithm, search_keys, charset); end + + # Sends an {UNSELECT command [RFC3691 §2]}[https://www.rfc-editor.org/rfc/rfc3691#section-3] + # {[IMAP4rev2 §6.4.2]}[https://www.rfc-editor.org/rfc/rfc9051#section-6.4.2] + # to free the session resources for a mailbox and return to the + # "_authenticated_" state. This is the same as #close, except that + # \\Deleted messages are not removed from the mailbox. + # + # Related: #close + # + # ===== Capabilities + # + # The server's capabilities must include +UNSELECT+ + # [RFC3691[https://tools.ietf.org/html/rfc3691]]. + # + # source://net-imap//lib/net/imap.rb#1908 + def unselect; end + + # Sends an {UNSUBSCRIBE command [IMAP4rev1 §6.3.7]}[https://www.rfc-editor.org/rfc/rfc3501#section-6.3.7] + # to remove the specified +mailbox+ name from the server's set of "active" + # or "subscribed" mailboxes. + # + # A Net::IMAP::NoResponseError is raised if +mailbox+ cannot be + # unsubscribed from; for instance, because the client is not currently + # subscribed to it. + # + # Related: #subscribe, #lsub, #list + # + # source://net-imap//lib/net/imap.rb#1516 + def unsubscribe(mailbox); end + + # Sends a XLIST command, and returns a subset of names from + # the complete set of all names available to the client. + # +refname+ provides a context (for instance, a base directory + # in a directory-based mailbox hierarchy). +mailbox+ specifies + # a mailbox or (via wildcards) mailboxes under that context. + # Two wildcards may be used in +mailbox+: '*', which matches + # all characters *including* the hierarchy delimiter (for instance, + # '/' on a UNIX-hosted directory-based mailbox hierarchy); and '%', + # which matches all characters *except* the hierarchy delimiter. + # + # If +refname+ is empty, +mailbox+ is used directly to determine + # which mailboxes to match. If +mailbox+ is empty, the root + # name of +refname+ and the hierarchy delimiter are returned. + # + # The XLIST command is like the LIST command except that the flags + # returned refer to the function of the folder/mailbox, e.g. :Sent + # + # The return value is an array of MailboxList objects. For example: + # + # imap.create("foo/bar") + # imap.create("foo/baz") + # p imap.xlist("", "foo/%") + # #=> [#, \\ + # #, \\ + # #] + # + # Related: #list, MailboxList + # + # ===== Capabilities + # + # The server's capabilities must include +XLIST+, + # a deprecated Gmail extension (replaced by +SPECIAL-USE+). + # -- + # TODO: Net::IMAP doesn't yet have full SPECIAL-USE support. Supporting + # servers MAY return SPECIAL-USE attributes, but are not *required* to + # unless the SPECIAL-USE return option is supplied. + # ++ + # + # source://net-imap//lib/net/imap.rb#1651 + def xlist(refname, mailbox); end + + private + + # source://net-imap//lib/net/imap.rb#2964 + def build_ssl_ctx(ssl); end + + # NOTE: only call this for greeting, login, and authenticate + # + # source://net-imap//lib/net/imap.rb#2803 + def capabilities_from_resp_code(resp); end + + # source://net-imap//lib/net/imap.rb#2925 + def copy_internal(cmd, set, mailbox); end + + # source://net-imap//lib/net/imap.rb#2888 + def fetch_internal(cmd, set, attr, mod = T.unsafe(nil), changedsince: T.unsafe(nil)); end + + # source://net-imap//lib/net/imap.rb#2852 + def generate_tag; end + + # source://net-imap//lib/net/imap.rb#2766 + def get_response; end + + # @raise [Error] + # + # source://net-imap//lib/net/imap.rb#2645 + def get_server_greeting; end + + # source://net-imap//lib/net/imap.rb#2738 + def get_tagged_response(tag, cmd, timeout = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap.rb#2953 + def normalize_searching_criteria(keys); end + + # source://net-imap//lib/net/imap.rb#2857 + def put_string(str); end + + # source://net-imap//lib/net/imap.rb#2671 + def receive_responses; end + + # store name => [..., data] + # + # source://net-imap//lib/net/imap.rb#2790 + def record_untagged_response(resp); end + + # store code.name => [..., code.data] + # + # source://net-imap//lib/net/imap.rb#2796 + def record_untagged_response_code(resp); end + + # source://net-imap//lib/net/imap.rb#2993 + def sasl_adapter; end + + # source://net-imap//lib/net/imap.rb#2872 + def search_internal(cmd, keys, charset); end + + # source://net-imap//lib/net/imap.rb#2824 + def send_command(cmd, *args, &block); end + + # Calls send_command, yielding the text of each ContinuationRequest and + # responding with each block result. Returns TaggedResponse. Raises + # NoResponseError or BadResponseError. + # + # source://net-imap//lib/net/imap.rb#2815 + def send_command_with_continuations(cmd, *args); end + + # source://net-imap//lib/net/imap/command_data.rb#33 + def send_data(data, tag = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/command_data.rb#115 + def send_date_data(date); end + + # source://net-imap//lib/net/imap/command_data.rb#101 + def send_list_data(list, tag = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/command_data.rb#80 + def send_literal(str, tag = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/command_data.rb#97 + def send_number_data(num); end + + # source://net-imap//lib/net/imap/command_data.rb#76 + def send_quoted_string(str); end + + # source://net-imap//lib/net/imap/command_data.rb#54 + def send_string_data(str, tag = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/command_data.rb#118 + def send_symbol_data(symbol); end + + # source://net-imap//lib/net/imap/command_data.rb#116 + def send_time_data(time); end + + # source://net-imap//lib/net/imap.rb#2929 + def sort_internal(cmd, sort_keys, search_keys, charset); end + + # source://net-imap//lib/net/imap.rb#2636 + def start_imap_connection; end + + # source://net-imap//lib/net/imap.rb#2653 + def start_receiver_thread; end + + # source://net-imap//lib/net/imap.rb#2979 + def start_tls_session; end + + # source://net-imap//lib/net/imap.rb#2913 + def store_internal(cmd, set, attr, flags, unchangedsince: T.unsafe(nil)); end + + # source://net-imap//lib/net/imap.rb#2662 + def tcp_socket(host, port); end + + # source://net-imap//lib/net/imap.rb#2941 + def thread_internal(cmd, algorithm, search_keys, charset); end + + # source://net-imap//lib/net/imap/command_data.rb#12 + def validate_data(data); end + + class << self + # Returns the global Config object + # + # source://net-imap//lib/net/imap.rb#739 + def config; end + + # Returns the global debug mode. + # + # source://net-imap//lib/net/imap.rb#742 + def debug; end + + # Sets the global debug mode. + # + # source://net-imap//lib/net/imap.rb#745 + def debug=(val); end + + # :call-seq: decode_date(string) -> Date + # + # Decodes +string+ as an IMAP formatted "date". + # + # Double quotes are optional. Day of month may be padded with zero or + # space. See STRFDATE. + # + # source://net-imap//lib/net/imap/data_encoding.rb#90 + def decode_date(string); end + + # :call-seq: decode_datetime(string) -> DateTime + # + # Decodes +string+ as an IMAP4 formatted "date-time". + # + # NOTE: Although double-quotes are not optional in the IMAP grammar, + # Net::IMAP currently parses "date-time" values as "quoted" strings and this + # removes the quotation marks. To be useful for strings which have already + # been parsed as a quoted string, this method makes double-quotes optional. + # + # See STRFTIME. + # + # source://net-imap//lib/net/imap/data_encoding.rb#112 + def decode_datetime(string); end + + # :call-seq: decode_time(string) -> Time + # + # Decodes +string+ as an IMAP4 formatted "date-time". + # + # Same as +decode_datetime+, but returning a Time instead. + # + # source://net-imap//lib/net/imap/data_encoding.rb#124 + def decode_time(string); end + + # Decode a string from modified UTF-7 format to UTF-8. + # + # UTF-7 is a 7-bit encoding of Unicode [UTF7]. IMAP uses a + # slightly modified version of this to encode mailbox names + # containing non-ASCII characters; see [IMAP] section 5.1.3. + # + # Net::IMAP does _not_ automatically encode and decode + # mailbox names to and from UTF-7. + # + # source://net-imap//lib/net/imap/data_encoding.rb#57 + def decode_utf7(s); end + + # The default port for IMAP connections, port 143 + # + # source://net-imap//lib/net/imap.rb#750 + def default_imap_port; end + + # The default port for IMAPS connections, port 993 + # + # source://net-imap//lib/net/imap.rb#755 + def default_imaps_port; end + + # The default port for IMAP connections, port 143 + # + # source://net-imap//lib/net/imap.rb#750 + def default_port; end + + # The default port for IMAPS connections, port 993 + # + # source://net-imap//lib/net/imap.rb#755 + def default_ssl_port; end + + # The default port for IMAPS connections, port 993 + # + # source://net-imap//lib/net/imap.rb#755 + def default_tls_port; end + + # Formats +time+ as an IMAP4 date. + # + # source://net-imap//lib/net/imap/data_encoding.rb#80 + def encode_date(date); end + + # :call-seq: encode_datetime(time) -> string + # + # Formats +time+ as an IMAP4 date-time. + # + # source://net-imap//lib/net/imap/data_encoding.rb#98 + def encode_datetime(time); end + + # :call-seq: encode_datetime(time) -> string + # + # Formats +time+ as an IMAP4 date-time. + # + # source://net-imap//lib/net/imap/data_encoding.rb#98 + def encode_time(time); end + + # Encode a string from UTF-8 format to modified UTF-7. + # + # source://net-imap//lib/net/imap/data_encoding.rb#68 + def encode_utf7(s); end + + # Formats +time+ as an IMAP4 date. + # + # source://net-imap//lib/net/imap/data_encoding.rb#80 + def format_date(date); end + + # DEPRECATED:: The original version returned incorrectly formatted strings. + # Strings returned by encode_datetime or format_time use the + # correct IMAP4rev1 syntax for "date-time". + # + # This invalid format has been temporarily retained for backward + # compatibility. A future release will change this method to return the + # correct format. + # + # source://net-imap//lib/net/imap/data_encoding.rb#149 + def format_datetime(time); end + + # :call-seq: encode_datetime(time) -> string + # + # Formats +time+ as an IMAP4 date-time. + # + # source://net-imap//lib/net/imap/data_encoding.rb#98 + def format_time(time); end + + # :call-seq: decode_date(string) -> Date + # + # Decodes +string+ as an IMAP formatted "date". + # + # Double quotes are optional. Day of month may be padded with zero or + # space. See STRFDATE. + # + # source://net-imap//lib/net/imap/data_encoding.rb#90 + def parse_date(string); end + + # :call-seq: decode_datetime(string) -> DateTime + # + # Decodes +string+ as an IMAP4 formatted "date-time". + # + # NOTE: Although double-quotes are not optional in the IMAP grammar, + # Net::IMAP currently parses "date-time" values as "quoted" strings and this + # removes the quotation marks. To be useful for strings which have already + # been parsed as a quoted string, this method makes double-quotes optional. + # + # See STRFTIME. + # + # source://net-imap//lib/net/imap/data_encoding.rb#112 + def parse_datetime(string); end + + # :call-seq: decode_time(string) -> Time + # + # Decodes +string+ as an IMAP4 formatted "date-time". + # + # Same as +decode_datetime+, but returning a Time instead. + # + # source://net-imap//lib/net/imap/data_encoding.rb#124 + def parse_time(string); end + + # -- + # We could get the saslprep method by extending the SASLprep module + # directly. It's done indirectly, so SASLprep can be lazily autoloaded, + # because most users won't need it. + # ++ + # Delegates to Net::IMAP::StringPrep::SASLprep#saslprep. + # + # source://net-imap//lib/net/imap.rb#3003 + def saslprep(string, **opts); end + end +end + +# Mailbox attribute indicating that this mailbox presents all messages in +# the user's message store. Implementations MAY omit some messages, such as, +# perhaps, those in \Trash and \Junk. When this special use is supported, it +# is almost certain to represent a virtual mailbox +# +# source://net-imap//lib/net/imap/flags.rb#218 +Net::IMAP::ALL = T.let(T.unsafe(nil), Symbol) + +# Mailbox attribute indicating that this mailbox is used to archive +# messages. The meaning of an "archival" mailbox is server dependent; +# typically, it will be used to get messages out of the inbox, or otherwise +# keep them out of the user's way, while still making them accessible +# +# source://net-imap//lib/net/imap/flags.rb#224 +Net::IMAP::ARCHIVE = T.let(T.unsafe(nil), Symbol) + +# source://net-imap//lib/net/imap/command_data.rb#137 +class Net::IMAP::Atom + # @return [Atom] a new instance of Atom + # + # source://net-imap//lib/net/imap/command_data.rb#147 + def initialize(data); end + + # source://net-imap//lib/net/imap/command_data.rb#138 + def send_data(imap, tag); end + + # source://net-imap//lib/net/imap/command_data.rb#142 + def validate; end +end + +# Backward compatible delegators from Net::IMAP to Net::IMAP::SASL. +# +# source://net-imap//lib/net/imap/authenticators.rb#4 +module Net::IMAP::Authenticators + # Deprecated. Use Net::IMAP::SASL.add_authenticator instead. + # + # source://net-imap//lib/net/imap/authenticators.rb#7 + def add_authenticator(*_arg0, **_arg1, &_arg2); end + + # Deprecated. Use Net::IMAP::SASL.authenticator instead. + # + # source://net-imap//lib/net/imap/authenticators.rb#18 + def authenticator(*_arg0, **_arg1, &_arg2); end +end + +# Net::IMAP::BodyStructure is included by all of the structs that can be +# returned from a "BODYSTRUCTURE" or "BODY" +# FetchData#attr value. Although these classes don't share a base class, +# this module can be used to pattern match all of them. +# +# See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] +# and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] +# for full description of all +BODYSTRUCTURE+ fields, and also +# Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. +# +# === Classes that include BodyStructure +# BodyTypeBasic:: Represents any message parts that are not handled by +# BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. +# BodyTypeText:: Used by text/* parts. Contains all of the +# BodyTypeBasic fields. +# BodyTypeMessage:: Used by message/rfc822 and +# message/global parts. Contains all of the +# BodyTypeBasic fields. Other message/* types +# should use BodyTypeBasic. +# BodyTypeMultipart:: for multipart/* parts +# +# source://net-imap//lib/net/imap/response_data.rb#813 +module Net::IMAP::BodyStructure; end + +# BodyTypeAttachment is not used and will be removed in an upcoming release. +# +# === Bug Analysis +# +# \IMAP body structures are parenthesized lists and assign their fields +# positionally, so missing fields change the interpretation of all +# following fields. Additionally, different body types have a different +# number of required fields, followed by optional "extension" fields. +# +# BodyTypeAttachment was previously returned when a "message/rfc822" part, +# which should be sent as body-type-msg with ten required fields, +# was actually sent as a body-type-basic with _seven_ required +# fields. +# +# basic => type, subtype, param, id, desc, enc, octets, md5=nil, dsp=nil, lang=nil, loc=nil, *ext +# msg => type, subtype, param, id, desc, enc, octets, envelope, body, lines, md5=nil, ... +# +# Normally, +envelope+ and +md5+ are incompatible, but Net::IMAP leniently +# allowed buggy servers to send +NIL+ for +envelope+. As a result, when a +# server sent a message/rfc822 part with +NIL+ for +md5+ and a +# non-NIL +dsp+, Net::IMAP misinterpreted the +# Content-Disposition as if it were a strange body type. In all +# reported cases, the Content-Disposition was "attachment", so +# BodyTypeAttachment was created as the workaround. +# +# === Current behavior +# +# When interpreted strictly, +envelope+ and +md5+ are incompatible. So the +# current parsing algorithm peeks ahead after it has received the seventh +# body field. If the next token is not the start of an +envelope+, we assume +# the server has incorrectly sent us a body-type-basic and return +# BodyTypeBasic. As a result, what was previously BodyTypeMessage#body => +# BodyTypeAttachment is now BodyTypeBasic#disposition => ContentDisposition. +# +# source://net-imap//lib/net/imap/response_data.rb#1077 +class Net::IMAP::BodyTypeAttachment < ::Struct + # *invalid for BodyTypeAttachment* + # + # source://net-imap//lib/net/imap/response_data.rb#1079 + def media_type; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_data.rb#1107 + def multipart?; end + + # *invalid for BodyTypeAttachment* + # + # source://net-imap//lib/net/imap/response_data.rb#1087 + def subtype; end +end + +# Net::IMAP::BodyTypeBasic represents basic body structures of messages and +# message parts, unless they have a Content-Type that is handled by +# BodyTypeText, BodyTypeMessage, or BodyTypeMultipart. +# +# See {[IMAP4rev1] §7.4.2}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] +# and {[IMAP4rev2] §7.5.2}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2-4.9] +# for full description of all +BODYSTRUCTURE+ fields, and also +# Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. +# +# source://net-imap//lib/net/imap/response_data.rb#830 +class Net::IMAP::BodyTypeBasic < ::Struct + include ::Net::IMAP::BodyStructure + + # :call-seq: media_subtype -> subtype + # + # >>> + # [Obsolete] + # Use +subtype+ instead. Calling this will generate a warning message + # to +stderr+, then return the value of +subtype+. + # -- + # TODO: why not just keep this as an alias? Would "media_subtype" be used + # for something else? + # ++ + # + # source://net-imap//lib/net/imap/response_data.rb#941 + def media_subtype; end + + # :call-seq: multipart? -> false + # + # BodyTypeBasic is not used for multipart MIME parts. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_data.rb#927 + def multipart?; end +end + +# === Obsolete +# BodyTypeExtension is not used and will be removed in an upcoming release. +# +# >>> +# BodyTypeExtension was (incorrectly) used for message/* parts +# (besides message/rfc822, which correctly uses BodyTypeMessage). +# +# Net::IMAP now (correctly) parses all message types (other than +# message/rfc822 or message/global) as BodyTypeBasic. +# +# source://net-imap//lib/net/imap/response_data.rb#1201 +class Net::IMAP::BodyTypeExtension < ::Struct + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_data.rb#1202 + def multipart?; end +end + +# Net::IMAP::BodyTypeMessage represents the body structures of messages and +# message parts, when Content-Type is message/rfc822 or +# message/global. +# +# BodyTypeMessage contains all of the fields of BodyTypeBasic. See +# BodyTypeBasic for documentation of the following fields: +# * {media_type}[rdoc-ref:BodyTypeBasic#media_type] +# * subtype[rdoc-ref:BodyTypeBasic#subtype] +# * param[rdoc-ref:BodyTypeBasic#param] +# * {content_id}[rdoc-ref:BodyTypeBasic#content_id] +# * description[rdoc-ref:BodyTypeBasic#description] +# * encoding[rdoc-ref:BodyTypeBasic#encoding] +# * size[rdoc-ref:BodyTypeBasic#size] +# +# source://net-imap//lib/net/imap/response_data.rb#1011 +class Net::IMAP::BodyTypeMessage < ::Struct + include ::Net::IMAP::BodyStructure + + # Obsolete: use +subtype+ instead. Calling this will + # generate a warning message to +stderr+, then return + # the value of +subtype+. + # + # source://net-imap//lib/net/imap/response_data.rb#1037 + def media_subtype; end + + # :call-seq: multipart? -> false + # + # BodyTypeMessage is not used for multipart MIME parts. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_data.rb#1030 + def multipart?; end +end + +# Net::IMAP::BodyTypeMultipart represents body structures of messages and +# message parts, when Content-Type is multipart/*. +# +# source://net-imap//lib/net/imap/response_data.rb#1120 +class Net::IMAP::BodyTypeMultipart < ::Struct + include ::Net::IMAP::BodyStructure + + # Obsolete: use +subtype+ instead. Calling this will + # generate a warning message to +stderr+, then return + # the value of +subtype+. + # + # source://net-imap//lib/net/imap/response_data.rb#1184 + def media_subtype; end + + # :call-seq: multipart? -> true + # + # BodyTypeMultipart is used for multipart MIME parts. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_data.rb#1176 + def multipart?; end +end + +# Net::IMAP::BodyTypeText represents the body structures of messages and +# message parts, when Content-Type is text/*. +# +# BodyTypeText contains all of the fields of BodyTypeBasic. See +# BodyTypeBasic for documentation of the following: +# * {media_type}[rdoc-ref:BodyTypeBasic#media_type] +# * subtype[rdoc-ref:BodyTypeBasic#subtype] +# * param[rdoc-ref:BodyTypeBasic#param] +# * {content_id}[rdoc-ref:BodyTypeBasic#content_id] +# * description[rdoc-ref:BodyTypeBasic#description] +# * encoding[rdoc-ref:BodyTypeBasic#encoding] +# * size[rdoc-ref:BodyTypeBasic#size] +# +# source://net-imap//lib/net/imap/response_data.rb#966 +class Net::IMAP::BodyTypeText < ::Struct + include ::Net::IMAP::BodyStructure + + # Obsolete: use +subtype+ instead. Calling this will + # generate a warning message to +stderr+, then return + # the value of +subtype+. + # + # source://net-imap//lib/net/imap/response_data.rb#986 + def media_subtype; end + + # :call-seq: multipart? -> false + # + # BodyTypeText is not used for multipart MIME parts. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_data.rb#979 + def multipart?; end +end + +# source://net-imap//lib/net/imap/command_data.rb#238 +class Net::IMAP::ClientID + # @return [ClientID] a new instance of ClientID + # + # source://net-imap//lib/net/imap/command_data.rb#250 + def initialize(data); end + + # source://net-imap//lib/net/imap/command_data.rb#240 + def send_data(imap, tag); end + + # source://net-imap//lib/net/imap/command_data.rb#244 + def validate; end + + private + + # source://net-imap//lib/net/imap/command_data.rb#264 + def format_internal(client_id); end + + # source://net-imap//lib/net/imap/command_data.rb#254 + def validate_internal(client_id); end +end + +# Net::IMAP::Config stores configuration options for Net::IMAP clients. +# The global configuration can be seen at either Net::IMAP.config or +# Net::IMAP::Config.global, and the client-specific configuration can be +# seen at Net::IMAP#config. +# +# When creating a new client, all unhandled keyword arguments to +# Net::IMAP.new are delegated to Config.new. Every client has its own +# config. +# +# debug_client = Net::IMAP.new(hostname, debug: true) +# quiet_client = Net::IMAP.new(hostname, debug: false) +# debug_client.config.debug? # => true +# quiet_client.config.debug? # => false +# +# == Inheritance +# +# Configs have a parent[rdoc-ref:Config::AttrInheritance#parent] config, and +# any attributes which have not been set locally will inherit the parent's +# value. Every client creates its own specific config. By default, client +# configs inherit from Config.global. +# +# plain_client = Net::IMAP.new(hostname) +# debug_client = Net::IMAP.new(hostname, debug: true) +# quiet_client = Net::IMAP.new(hostname, debug: false) +# +# plain_client.config.inherited?(:debug) # => true +# debug_client.config.inherited?(:debug) # => false +# quiet_client.config.inherited?(:debug) # => false +# +# plain_client.config.debug? # => false +# debug_client.config.debug? # => true +# quiet_client.config.debug? # => false +# +# # Net::IMAP.debug is delegated to Net::IMAP::Config.global.debug +# Net::IMAP.debug = true +# plain_client.config.debug? # => true +# debug_client.config.debug? # => true +# quiet_client.config.debug? # => false +# +# Net::IMAP.debug = false +# plain_client.config.debug = true +# plain_client.config.inherited?(:debug) # => false +# plain_client.config.debug? # => true +# plain_client.config.reset(:debug) +# plain_client.config.inherited?(:debug) # => true +# plain_client.config.debug? # => false +# +# == Versioned defaults +# +# The effective default configuration for a specific +x.y+ version of +# +net-imap+ can be loaded with the +config+ keyword argument to +# Net::IMAP.new. Requesting default configurations for previous versions +# enables extra backward compatibility with those versions: +# +# client = Net::IMAP.new(hostname, config: 0.3) +# client.config.sasl_ir # => false +# client.config.responses_without_block # => :silence_deprecation_warning +# +# client = Net::IMAP.new(hostname, config: 0.4) +# client.config.sasl_ir # => true +# client.config.responses_without_block # => :silence_deprecation_warning +# +# client = Net::IMAP.new(hostname, config: 0.5) +# client.config.sasl_ir # => true +# client.config.responses_without_block # => :warn +# +# client = Net::IMAP.new(hostname, config: :future) +# client.config.sasl_ir # => true +# client.config.responses_without_block # => :raise +# +# The versioned default configs inherit certain specific config options from +# Config.global, for example #debug: +# +# client = Net::IMAP.new(hostname, config: 0.4) +# Net::IMAP.debug = false +# client.config.debug? # => false +# +# Net::IMAP.debug = true +# client.config.debug? # => true +# +# Use #load_defaults to globally behave like a specific version: +# client = Net::IMAP.new(hostname) +# client.config.sasl_ir # => true +# Net::IMAP.config.load_defaults 0.3 +# client.config.sasl_ir # => false +# +# === Named defaults +# In addition to +x.y+ version numbers, the following aliases are supported: +# +# [+:default+] +# An alias for +:current+. +# +# >>> +# *NOTE*: This is _not_ the same as Config.default. It inherits some +# attributes from Config.global, for example: #debug. +# [+:current+] +# An alias for the current +x.y+ version's defaults. +# [+:next+] +# The _planned_ config for the next +x.y+ version. +# [+:future+] +# The _planned_ eventual config for some future +x.y+ version. +# +# For example, to raise exceptions for all current deprecations: +# client = Net::IMAP.new(hostname, config: :future) +# client.responses # raises an ArgumentError +# +# == Thread Safety +# +# *NOTE:* Updates to config objects are not synchronized for thread-safety. +# +# source://net-imap//lib/net/imap/config/attr_accessors.rb#7 +class Net::IMAP::Config + include ::Net::IMAP::Config::AttrAccessors + include ::Net::IMAP::Config::AttrInheritance + include ::Net::IMAP::Config::AttrTypeCoercion + extend ::Net::IMAP::Config::AttrAccessors::Macros + extend ::Net::IMAP::Config::AttrInheritance::Macros + extend ::Net::IMAP::Config::AttrTypeCoercion::Macros + + # Creates a new config object and initialize its attribute with +attrs+. + # + # If +parent+ is not given, the global config is used by default. + # + # If a block is given, the new config object is yielded to it. + # + # @return [Config] a new instance of Config + # @yield [_self] + # @yieldparam _self [Net::IMAP::Config] the object that the method was called on + # + # source://net-imap//lib/net/imap/config.rb#236 + def initialize(parent = T.unsafe(nil), **attrs); end + + # :call-seq: load_defaults(version) -> self + # + # Resets the current config to behave like the versioned default + # configuration for +version+. #parent will not be changed. + # + # Some config attributes default to inheriting from their #parent (which + # is usually Config.global) and are left unchanged, for example: #debug. + # + # See Config@Versioned+defaults and Config@Named+defaults. + # + # source://net-imap//lib/net/imap/config.rb#287 + def load_defaults(version); end + + # :call-seq: to_h -> hash + # + # Returns all config attributes in a hash. + # + # source://net-imap//lib/net/imap/config.rb#296 + def to_h; end + + # :call-seq: update(**attrs) -> self + # + # Assigns all of the provided +attrs+ to this config, and returns +self+. + # + # An ArgumentError is raised unless every key in +attrs+ matches an + # assignment method on Config. + # + # >>> + # *NOTE:* #update is not atomic. If an exception is raised due to an + # invalid attribute value, +attrs+ may be partially applied. + # + # source://net-imap//lib/net/imap/config.rb#252 + def update(**attrs); end + + # :call-seq: + # with(**attrs) -> config + # with(**attrs) {|config| } -> result + # + # Without a block, returns a new config which inherits from self. With a + # block, yields the new config and returns the block's result. + # + # If no keyword arguments are given, an ArgumentError will be raised. + # + # If +self+ is frozen, the copy will also be frozen. + # + # source://net-imap//lib/net/imap/config.rb#270 + def with(**attrs); end + + protected + + # source://net-imap//lib/net/imap/config.rb#300 + def defaults_hash; end + + class << self + # :call-seq: + # Net::IMAP::Config[number] -> versioned config + # Net::IMAP::Config[symbol] -> named config + # Net::IMAP::Config[hash] -> new frozen config + # Net::IMAP::Config[config] -> same config + # + # Given a version number, returns the default configuration for the target + # version. See Config@Versioned+defaults. + # + # Given a version name, returns the default configuration for the target + # version. See Config@Named+defaults. + # + # Given a Hash, creates a new _frozen_ config which inherits from + # Config.global. Use Config.new for an unfrozen config. + # + # Given a config, returns that same config. + # + # source://net-imap//lib/net/imap/config.rb#151 + def [](config); end + + # The default config, which is hardcoded and frozen. + # + # source://net-imap//lib/net/imap/config.rb#126 + def default; end + + # The global config object. Also available from Net::IMAP.config. + # + # source://net-imap//lib/net/imap/config.rb#129 + def global; end + + # A hash of hard-coded configurations, indexed by version number. + # + # source://net-imap//lib/net/imap/config.rb#132 + def version_defaults; end + end +end + +# >>> +# *NOTE:* This module is an internal implementation detail, with no +# guarantee of backward compatibility. +# +# +attr_accessor+ values are stored in a struct rather than ivars, making +# it simpler to ensure that all config objects share a single object +# shape. This also simplifies iteration over all defined attributes. +# +# source://net-imap//lib/net/imap/config/attr_accessors.rb#15 +module Net::IMAP::Config::AttrAccessors + extend ::Forwardable + + mixes_in_class_methods ::Net::IMAP::Config::AttrAccessors::Macros + + # :notnew: + # + # source://net-imap//lib/net/imap/config/attr_accessors.rb#45 + def initialize; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def debug(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def debug=(*args, **_arg1, &block); end + + # Freezes the internal attributes struct, in addition to +self+. + # + # source://net-imap//lib/net/imap/config/attr_accessors.rb#51 + def freeze; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def idle_response_timeout(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def idle_response_timeout=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def open_timeout(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def open_timeout=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def responses_without_block(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def responses_without_block=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def sasl_ir(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def sasl_ir=(*args, **_arg1, &block); end + + protected + + # source://net-imap//lib/net/imap/config/attr_accessors.rb#58 + def data; end + + private + + # source://net-imap//lib/net/imap/config/attr_accessors.rb#62 + def initialize_clone(other); end + + # source://net-imap//lib/net/imap/config/attr_accessors.rb#67 + def initialize_dup(other); end + + class << self + # source://net-imap//lib/net/imap/config/attr_accessors.rb#28 + def attr_accessor(name); end + + # source://net-imap//lib/net/imap/config/attr_accessors.rb#38 + def struct; end + + private + + # source://net-imap//lib/net/imap/config/attr_accessors.rb#33 + def attributes; end + + # @private + # + # source://net-imap//lib/net/imap/config/attr_accessors.rb#21 + def included(mod); end + end +end + +# source://net-imap//lib/net/imap/config/attr_accessors.rb#16 +module Net::IMAP::Config::AttrAccessors::Macros + # source://net-imap//lib/net/imap/config/attr_accessors.rb#17 + def attr_accessor(name); end +end + +# source://net-imap//lib/net/imap/config.rb#0 +class Net::IMAP::Config::AttrAccessors::Struct < ::Struct + def debug; end + def debug=(_); end + def idle_response_timeout; end + def idle_response_timeout=(_); end + def open_timeout; end + def open_timeout=(_); end + def responses_without_block; end + def responses_without_block=(_); end + def sasl_ir; end + def sasl_ir=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# >>> +# *NOTE:* The public methods on this module are part of the stable +# public API of Net::IMAP::Config. But the module itself is an internal +# implementation detail, with no guarantee of backward compatibility. +# +# +attr_accessor+ methods will delegate to their #parent when the local +# value does not contain an override. Inheritance forms a singly linked +# list, so lookup will be O(n) on the number of ancestors. In +# practice, the ancestor chain is not expected to be long. Without +# customization, it is only three deep: +# >>> +# IMAP#config → Config.global → Config.default +# +# When creating a client with the +config+ keyword, for example to use +# the appropriate defaults for an application or a library while still +# relying on global for configuration of +debug+ or +logger+, most likely +# the ancestor chain is still only four deep: +# >>> +# IMAP#config → alternate defaults → Config.global → Config.default +# +# source://net-imap//lib/net/imap/config/attr_inheritance.rb#25 +module Net::IMAP::Config::AttrInheritance + mixes_in_class_methods ::Net::IMAP::Config::AttrInheritance::Macros + + # :notnew: + # + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#48 + def initialize(parent = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#41 + def debug; end + + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#41 + def idle_response_timeout; end + + # Returns +true+ if +attr+ is inherited from #parent and not overridden + # by this config. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#59 + def inherited?(attr); end + + # Creates a new config, which inherits from +self+. + # + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#55 + def new(**attrs); end + + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#41 + def open_timeout; end + + # The parent Config object + # + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#46 + def parent; end + + # :call-seq: + # reset -> self + # reset(attr) -> attribute value + # + # Resets an +attr+ to inherit from the #parent config. + # + # When +attr+ is nil or not given, all attributes are reset. + # + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#68 + def reset(attr = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#41 + def responses_without_block; end + + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#41 + def sasl_ir; end + + private + + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#82 + def initialize_copy(other); end + + class << self + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#39 + def attr_accessor(name); end + + private + + # @private + # + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#34 + def included(mod); end + end +end + +# source://net-imap//lib/net/imap/config/attr_inheritance.rb#26 +module Net::IMAP::Config::AttrInheritance::INHERITED; end + +# source://net-imap//lib/net/imap/config/attr_inheritance.rb#29 +module Net::IMAP::Config::AttrInheritance::Macros + # source://net-imap//lib/net/imap/config/attr_inheritance.rb#30 + def attr_accessor(name); end +end + +# >>> +# *NOTE:* This module is an internal implementation detail, with no +# guarantee of backward compatibility. +# +# Adds a +type+ keyword parameter to +attr_accessor+, to enforce that +# config attributes have valid types, for example: boolean, numeric, +# enumeration, non-nullable, etc. +# +# source://net-imap//lib/net/imap/config/attr_type_coercion.rb#13 +module Net::IMAP::Config::AttrTypeCoercion + mixes_in_class_methods ::Net::IMAP::Config::AttrTypeCoercion::Macros + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#39 + def debug=(val); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#40 + def debug?; end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#44 + def idle_response_timeout=(val); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#44 + def open_timeout=(val); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#50 + def responses_without_block=(val); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#39 + def sasl_ir=(val); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#40 + def sasl_ir?; end + + class << self + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#29 + def attr_accessor(attr, type: T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#38 + def boolean(attr); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#47 + def enum(attr, enum); end + + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#43 + def integer(attr); end + + private + + # @private + # + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#24 + def included(mod); end + end +end + +# :stopdoc: internal APIs only +# +# source://net-imap//lib/net/imap/config/attr_type_coercion.rb#16 +module Net::IMAP::Config::AttrTypeCoercion::Macros + # source://net-imap//lib/net/imap/config/attr_type_coercion.rb#17 + def attr_accessor(attr, type: T.unsafe(nil)); end +end + +# Array of attribute names that are _not_ loaded by #load_defaults. +# +# source://net-imap//lib/net/imap/config.rb#122 +Net::IMAP::Config::DEFAULT_TO_INHERIT = T.let(T.unsafe(nil), Array) + +# Mailbox attribute indicating that this mailbox is used to hold draft +# messages -- typically, messages that are being composed but have not yet +# been sent. In some server implementations, this might be a virtual +# mailbox, containing messages from other mailboxes that are marked with the +# "\Draft" message flag. Alternatively, this might just be advice that a +# client put drafts here +# +# source://net-imap//lib/net/imap/flags.rb#232 +Net::IMAP::DRAFTS = T.let(T.unsafe(nil), Symbol) + +# This module handles deprecated arguments to various Net::IMAP methods. +# +# source://net-imap//lib/net/imap/deprecated_client_options.rb#7 +module Net::IMAP::DeprecatedClientOptions + # :call-seq: + # Net::IMAP.new(host, **options) # standard keyword options + # Net::IMAP.new(host, options) # obsolete hash options + # Net::IMAP.new(host, port) # obsolete port argument + # Net::IMAP.new(host, port, usessl, certs = nil, verify = true) # deprecated SSL arguments + # + # Translates Net::IMAP.new arguments for backward compatibility. + # + # ==== Obsolete arguments + # + # Use of obsolete arguments does not print a warning. Obsolete arguments + # will be deprecated by a future release. + # + # If a second positional argument is given and it is a hash (or is + # convertible via +#to_hash+), it is converted to keyword arguments. + # + # # Obsolete: + # Net::IMAP.new("imap.example.com", options_hash) + # # Use instead: + # Net::IMAP.new("imap.example.com", **options_hash) + # + # If a second positional argument is given and it is not a hash, it is + # converted to the +port+ keyword argument. + # # Obsolete: + # Net::IMAP.new("imap.example.com", 114433) + # # Use instead: + # Net::IMAP.new("imap.example.com", port: 114433) + # + # ==== Deprecated arguments + # + # Using deprecated arguments prints a warning. Convert to keyword + # arguments to avoid the warning. Deprecated arguments will be removed in + # a future release. + # + # If +usessl+ is false, +certs+, and +verify+ are ignored. When it true, + # all three arguments are converted to the +ssl+ keyword argument. + # Without +certs+ or +verify+, it is converted to ssl: true. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true) # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: true) + # + # When +certs+ is a path to a directory, it is converted to ca_path: + # certs. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true, "/path/to/certs") # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: {ca_path: "/path/to/certs"}) + # + # When +certs+ is a path to a file, it is converted to ca_file: + # certs. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true, "/path/to/cert.pem") # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: {ca_file: "/path/to/cert.pem"}) + # + # When +verify+ is +false+, it is converted to verify_mode: + # OpenSSL::SSL::VERIFY_NONE. + # # DEPRECATED: + # Net::IMAP.new("imap.example.com", nil, true, nil, false) # => prints a warning + # # Use instead: + # Net::IMAP.new("imap.example.com", ssl: {verify_mode: OpenSSL::SSL::VERIFY_NONE}) + # + # source://net-imap//lib/net/imap/deprecated_client_options.rb#72 + def initialize(host, port_or_options = T.unsafe(nil), *deprecated, **options); end + + # :call-seq: + # starttls(**options) # standard + # starttls(options = {}) # obsolete + # starttls(certs = nil, verify = true) # deprecated + # + # Translates Net::IMAP#starttls arguments for backward compatibility. + # + # Support for +certs+ and +verify+ will be dropped in a future release. + # + # See ::new for interpretation of +certs+ and +verify+. + # + # source://net-imap//lib/net/imap/deprecated_client_options.rb#104 + def starttls(*deprecated, **options); end + + private + + # source://net-imap//lib/net/imap/deprecated_client_options.rb#123 + def create_ssl_params(certs = T.unsafe(nil), verify = T.unsafe(nil)); end +end + +# Aliases for supported capabilities, to be used with the #enable command. +# +# source://net-imap//lib/net/imap.rb#723 +Net::IMAP::ENABLE_ALIASES = T.let(T.unsafe(nil), Hash) + +# **Note:** This represents an intentionally _unstable_ API. Where +# instances of this class are returned, future releases may return a +# different (incompatible) object without deprecation or warning. +# +# Net::IMAP::ExtensionData represents data that is parsable according to the +# forward-compatible extension syntax in RFC3501, RFC4466, or RFC9051, but +# isn't directly known or understood by Net::IMAP yet. +# +# See also: UnparsedData, UnparsedNumericResponseData, IgnoredResponse +# +# source://net-imap//lib/net/imap/response_data.rb#120 +class Net::IMAP::ExtensionData < ::Struct; end + +# Net::IMAP::FetchData represents the contents of a FETCH response. +# Net::IMAP#fetch and Net::IMAP#uid_fetch both return an array of +# FetchData objects. +# +# === Fetch attributes +# +# See {[IMAP4rev1 §7.4.2]}[https://www.rfc-editor.org/rfc/rfc3501.html#section-7.4.2] +# and {[IMAP4rev2 §7.5.2]}[https://www.rfc-editor.org/rfc/rfc9051.html#section-7.5.2] +# for a full description of the standard fetch response data items, and +# Net::IMAP@Message+envelope+and+body+structure for other relevant RFCs. +# +# ==== Static fetch data items +# +# Most message attributes are static, and must never change for a given +# (server, account, mailbox, UIDVALIDITY, UID) tuple. +# +# The static fetch data items defined by both +# IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and +# IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] are: +# +# * "UID" --- See #uid. +# * "BODY" --- See #body. +# * "BODY[#{section_spec}]", +# "BODY[#{section_spec}]<#{offset}>" --- See #message, +# #part, #header, #header_fields, #header_fields_not, #mime, and #text. +# * "BODYSTRUCTURE" --- See #bodystructure. +# * "ENVELOPE" --- See #envelope. +# * "INTERNALDATE" --- See #internaldate. +# * "RFC822.SIZE" --- See #rfc822_size. +# +# IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] adds the +# additional fetch items from the +BINARY+ extension +# {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]: +# +# * "BINARY[#{part}]", +# "BINARY[#{part}]<#{offset}>" -- See #binary. +# * "BINARY.SIZE[#{part}]" -- See #binary_size. +# +# Several static message attributes in +# IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] are obsolete and +# been removed from +# IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html]: +# +# * "RFC822" --- See #rfc822 or replace with +# "BODY[]" and #message. +# * "RFC822.HEADER" --- See #rfc822_header or replace with +# "BODY[HEADER]" and #header. +# * "RFC822.TEXT" --- See #rfc822_text or replace with +# "BODY[TEXT]" and #text. +# +# Net::IMAP supports static attributes defined by the following extensions: +# * +OBJECTID+ {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html] +# * "EMAILID" --- See #emailid. +# * "THREADID" --- See #threadid. +# +# * +X-GM-EXT-1+ {[non-standard Gmail +# extension]}[https://developers.google.com/gmail/imap/imap-extensions] +# * "X-GM-MSGID" --- unique message ID. Access via #attr. +# * "X-GM-THRID" --- Thread ID. Access via #attr. +# +# [Note:] +# >>> +# Additional static fields are defined in other \IMAP extensions, but +# Net::IMAP can't parse them yet. +# +# ==== Dynamic message attributes +# +# Some message attributes can be dynamically changed, for example using the +# {STORE command}[rdoc-ref:Net::IMAP#store]. +# +# The only dynamic message attribute defined by +# IMAP4rev1[https://www.rfc-editor.org/rfc/rfc3501.html] and +# IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] is: +# +# * "FLAGS" --- See #flags. +# +# Net::IMAP supports dynamic attributes defined by the following extensions: +# +# * +CONDSTORE+ {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]: +# * "MODSEQ" --- See #modseq. +# * +X-GM-EXT-1+ {[non-standard Gmail +# extension]}[https://developers.google.com/gmail/imap/imap-extensions] +# * "X-GM-LABELS" --- Gmail labels. Access via #attr. +# +# [Note:] +# >>> +# Additional dynamic fields are defined in other \IMAP extensions, but +# Net::IMAP can't parse them yet. +# +# === Implicitly setting \Seen and using +PEEK+ +# +# Unless the mailbox is has been opened as read-only, fetching +# BODY[#{section}] or BINARY[#{section}] +# will implicitly set the \Seen flag. To avoid this, fetch using +# BODY.PEEK[#{section}] or BINARY.PEEK[#{section}] +# instead. +# +# Note that the data will always be _returned_ without ".PEEK", in +# BODY[#{specifier}] or BINARY[#{section}]. +# +# source://net-imap//lib/net/imap/fetch_data.rb#106 +class Net::IMAP::FetchData < ::Struct + # :call-seq: attr_upcase -> hash + # + # A transformation of #attr, with all the keys converted to upper case. + # + # Header field names are case-preserved but not case-sensitive, so this is + # used by #header_fields and #header_fields_not. + # + # source://net-imap//lib/net/imap/fetch_data.rb#136 + def attr_upcase; end + + # :call-seq: + # binary(*part_nums, offset: nil) -> string or nil + # + # Returns the binary representation of a particular MIME part, which has + # already been decoded according to its Content-Transfer-Encoding. + # + # See #part for a description of +part_nums+ and +offset+. + # + # This is the same as getting the value of + # "BINARY[#{part_nums.join(".")}]" or + # "BINARY[#{part_nums.join(".")}]<#{offset}>" from #attr. + # + # The server must support either + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] + # or the +BINARY+ extension + # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]. + # + # See also: #binary_size, #mime + # + # source://net-imap//lib/net/imap/fetch_data.rb#430 + def binary(*part_nums, offset: T.unsafe(nil)); end + + # :call-seq: + # binary_size(*part_nums) -> integer or nil + # + # Returns the decoded size of a particular MIME part (the size to expect + # in response to a BINARY fetch request). + # + # See #part for a description of +part_nums+. + # + # This is the same as getting the value of + # "BINARY.SIZE[#{part_nums.join(".")}]" from #attr. + # + # The server must support either + # IMAP4rev2[https://www.rfc-editor.org/rfc/rfc9051.html] + # or the +BINARY+ extension + # {[RFC3516]}[https://www.rfc-editor.org/rfc/rfc3516.html]. + # + # See also: #binary, #mime + # + # source://net-imap//lib/net/imap/fetch_data.rb#451 + def binary_size(*part_nums); end + + # :call-seq: + # body -> body structure or nil + # + # Returns an alternate form of #bodystructure, without any extension data. + # + # This is the same as getting the value for "BODY" from #attr. + # + # [Note] + # Use #message, #part, #header, #header_fields, #header_fields_not, + # #text, or #mime to retrieve BODY[#{section_spec}] attributes. + # + # source://net-imap//lib/net/imap/fetch_data.rb#148 + def body; end + + # :call-seq: + # bodystructure -> BodyStructure struct or nil + # + # A BodyStructure object that describes the message, if it was fetched. + # + # This is the same as getting the value for "BODYSTRUCTURE" from + # #attr. + # + # source://net-imap//lib/net/imap/fetch_data.rb#310 + def body_structure; end + + # :call-seq: + # bodystructure -> BodyStructure struct or nil + # + # A BodyStructure object that describes the message, if it was fetched. + # + # This is the same as getting the value for "BODYSTRUCTURE" from + # #attr. + # + # source://net-imap//lib/net/imap/fetch_data.rb#310 + def bodystructure; end + + # :call-seq: emailid -> string or nil + # + # An ObjectID that uniquely identifies the immutable content of a single + # message. + # + # The server must return the same +EMAILID+ for both the source and + # destination messages after a COPY or MOVE command. However, it is + # possible for different messages with the same EMAILID to have different + # mutable attributes, such as flags. + # + # This is the same as getting the value for "EMAILID" from + # #attr. + # + # The server must support the +OBJECTID+ extension + # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + # + # source://net-imap//lib/net/imap/fetch_data.rb#484 + def emailid; end + + # :call-seq: envelope -> Envelope or nil + # + # An Envelope object that describes the envelope structure of a message. + # See the documentation for Envelope for a description of the envelope + # structure attributes. + # + # This is the same as getting the value for "ENVELOPE" from + # #attr. + # + # source://net-imap//lib/net/imap/fetch_data.rb#321 + def envelope; end + + # :call-seq: flags -> array of Symbols and Strings + # + # A array of flags that are set for this message. System flags are + # symbols that have been capitalized by String#capitalize. Keyword flags + # are strings and their case is not changed. + # + # This is the same as getting the value for "FLAGS" from #attr. + # + # [Note] + # The +FLAGS+ field is dynamic, and can change for a uniquely identified + # message. + # + # source://net-imap//lib/net/imap/fetch_data.rb#334 + def flags; end + + # :call-seq: + # header(*part_nums, offset: nil) -> string or nil + # header(*part_nums, fields: names, offset: nil) -> string or nil + # header(*part_nums, except: names, offset: nil) -> string or nil + # + # The {[RFC5322]}[https://www.rfc-editor.org/rfc/rfc5322.html] header of a + # message or of an encapsulated + # {[MIME-IMT]}[https://www.rfc-editor.org/rfc/rfc2046.html] + # MESSAGE/RFC822 or MESSAGE/GLOBAL message. + # + # Headers can be parsed using the "mail" gem. + # + # See #part for a description of +part_nums+ and +offset+. + # + # ==== Without +fields+ or +except+ + # This is the same as getting the value from #attr for one of: + # * BODY[HEADER] + # * BODY[HEADER]<#{offset}> + # * BODY[#{part_nums.join "."}.HEADER]" + # * BODY[#{part_nums.join "."}.HEADER]<#{offset}>" + # + # ==== With +fields+ + # When +fields+ is sent, returns a subset of the header which contains + # only the header fields that match one of the names in the list. + # + # This is the same as getting the value from #attr_upcase for one of: + # * BODY[HEADER.FIELDS (#{names.join " "})] + # * BODY[HEADER.FIELDS (#{names.join " "})]<#{offset}> + # * BODY[#{part_nums.join "."}.HEADER.FIELDS (#{names.join " "})] + # * BODY[#{part_nums.join "."}.HEADER.FIELDS (#{names.join " "})]<#{offset}> + # + # See also: #header_fields + # + # ==== With +except+ + # When +except+ is sent, returns a subset of the header which contains + # only the header fields that do _not_ match one of the names in the list. + # + # This is the same as getting the value from #attr_upcase for one of: + # * BODY[HEADER.FIELDS.NOT (#{names.join " "})] + # * BODY[HEADER.FIELDS.NOT (#{names.join " "})]<#{offset}> + # * BODY[#{part_nums.join "."}.HEADER.FIELDS.NOT (#{names.join " "})] + # * BODY[#{part_nums.join "."}.HEADER.FIELDS.NOT (#{names.join " "})]<#{offset}> + # + # See also: #header_fields_not + # + # source://net-imap//lib/net/imap/fetch_data.rb#234 + def header(*part_nums, fields: T.unsafe(nil), except: T.unsafe(nil), offset: T.unsafe(nil)); end + + # :call-seq: + # header_fields(*names, part: [], offset: nil) -> string or nil + # + # The result from #header when called with fields: names. + # + # source://net-imap//lib/net/imap/fetch_data.rb#252 + def header_fields(first, *rest, part: T.unsafe(nil), offset: T.unsafe(nil)); end + + # :call-seq: + # header_fields_not(*names, part: [], offset: nil) -> string or nil + # + # The result from #header when called with except: names. + # + # source://net-imap//lib/net/imap/fetch_data.rb#260 + def header_fields_not(first, *rest, part: T.unsafe(nil), offset: T.unsafe(nil)); end + + # :call-seq: internaldate -> Time or nil + # + # The internal date and time of the message on the server. This is not + # the date and time in the [RFC5322[https://tools.ietf.org/html/rfc5322]] + # header, but rather a date and time which reflects when the message was + # received. + # + # This is similar to getting the value for "INTERNALDATE" from + # #attr. + # + # [Note] + # attr["INTERNALDATE"] returns a string, and this method + # returns a Time object. + # + # source://net-imap//lib/net/imap/fetch_data.rb#349 + def internal_date; end + + # :call-seq: internaldate -> Time or nil + # + # The internal date and time of the message on the server. This is not + # the date and time in the [RFC5322[https://tools.ietf.org/html/rfc5322]] + # header, but rather a date and time which reflects when the message was + # received. + # + # This is similar to getting the value for "INTERNALDATE" from + # #attr. + # + # [Note] + # attr["INTERNALDATE"] returns a string, and this method + # returns a Time object. + # + # source://net-imap//lib/net/imap/fetch_data.rb#349 + def internaldate; end + + # :call-seq: + # message(offset: bytes) -> string or nil + # + # The RFC5322[https://www.rfc-editor.org/rfc/rfc5322.html] + # expression of the entire message, as a string. + # + # See #part for a description of +offset+. + # + # RFC5322 messages can be parsed using the "mail" gem. + # + # This is the same as getting the value for "BODY[]" or + # "BODY[]<#{offset}>" from #attr. + # + # See also: #header, #text, and #mime. + # + # source://net-imap//lib/net/imap/fetch_data.rb#164 + def message(offset: T.unsafe(nil)); end + + # :call-seq: + # mime(*part_nums) -> string or nil + # mime(*part_nums, offset: bytes) -> string or nil + # + # The {[MIME-IMB]}[https://www.rfc-editor.org/rfc/rfc2045.html] header for + # a message part, if it was fetched. + # + # See #part for a description of +part_nums+ and +offset+. + # + # This is the same as getting the value for + # "BODY[#{part_nums}.MIME]" or + # "BODY[#{part_nums}.MIME]<#{offset}>" from #attr. + # + # See also: #message, #header, and #text. + # + # source://net-imap//lib/net/imap/fetch_data.rb#278 + def mime(part, *subparts, offset: T.unsafe(nil)); end + + # :call-seq: modseq -> Integer + # + # The modification sequence number associated with this IMAP message. + # + # This is the same as getting the value for "MODSEQ" from #attr. + # + # The server must support the +CONDSTORE+ extension + # {[RFC7162]}[https://www.rfc-editor.org/rfc/rfc7162.html]. + # + # [Note] + # The +MODSEQ+ field is dynamic, and can change for a uniquely + # identified message. + # + # source://net-imap//lib/net/imap/fetch_data.rb#467 + def modseq; end + + # :call-seq: + # part(*part_nums, offset: bytes) -> string or nil + # + # The string representation of a particular MIME part. + # + # +part_nums+ forms a path of MIME part numbers, counting up from +1+, + # which may specify an arbitrarily nested part, similarly to Array#dig. + # Messages that don't use MIME, or MIME messages that are not multipart + # and don't hold an encapsulated message, only have part +1+. + # + # If a zero-based +offset+ is given, the returned string is a substring of + # the entire contents, starting at that origin octet. This means that + # BODY[]<0> MAY be truncated, but BODY[] is never + # truncated. + # + # This is the same as getting the value of + # "BODY[#{part_nums.join(".")}]" or + # "BODY[#{part_nums.join(".")}]<#{offset}>" from #attr. + # + # See also: #message, #header, #text, and #mime. + # + # source://net-imap//lib/net/imap/fetch_data.rb#186 + def part(index, *subparts, offset: T.unsafe(nil)); end + + # :call-seq: rfc822 -> String + # + # Semantically equivalent to #message with no arguments. + # + # This is the same as getting the value for "RFC822" from #attr. + # + # [Note] + # +IMAP4rev2+ deprecates RFC822. + # + # source://net-imap//lib/net/imap/fetch_data.rb#362 + def rfc822; end + + # :call-seq: rfc822_header -> String + # + # Semantically equivalent to #header, with no arguments. + # + # This is the same as getting the value for "RFC822.HEADER" from #attr. + # + # [Note] + # +IMAP4rev2+ deprecates RFC822.HEADER. + # + # source://net-imap//lib/net/imap/fetch_data.rb#392 + def rfc822_header; end + + # :call-seq: rfc822_size -> Integer + # + # A number expressing the [RFC5322[https://tools.ietf.org/html/rfc5322]] + # size of the message. + # + # This is the same as getting the value for "RFC822.SIZE" from + # #attr. + # + # [Note] + # \IMAP was originally developed for the older + # RFC822[https://www.rfc-editor.org/rfc/rfc822.html] standard, and as a + # consequence several fetch items in \IMAP incorporate "RFC822" in their + # name. With the exception of +RFC822.SIZE+, there are more modern + # replacements; for example, the modern version of +RFC822.HEADER+ is + # BODY.PEEK[HEADER]. In all cases, "RFC822" should be + # interpreted as a reference to the updated + # RFC5322[https://www.rfc-editor.org/rfc/rfc5322.html] standard. + # + # source://net-imap//lib/net/imap/fetch_data.rb#381 + def rfc822_size; end + + # :call-seq: rfc822_text -> String + # + # Semantically equivalent to #text, with no arguments. + # + # This is the same as getting the value for "RFC822.TEXT" from + # #attr. + # + # [Note] + # +IMAP4rev2+ deprecates RFC822.TEXT. + # + # source://net-imap//lib/net/imap/fetch_data.rb#403 + def rfc822_text; end + + # :call-seq: rfc822_size -> Integer + # + # A number expressing the [RFC5322[https://tools.ietf.org/html/rfc5322]] + # size of the message. + # + # This is the same as getting the value for "RFC822.SIZE" from + # #attr. + # + # [Note] + # \IMAP was originally developed for the older + # RFC822[https://www.rfc-editor.org/rfc/rfc822.html] standard, and as a + # consequence several fetch items in \IMAP incorporate "RFC822" in their + # name. With the exception of +RFC822.SIZE+, there are more modern + # replacements; for example, the modern version of +RFC822.HEADER+ is + # BODY.PEEK[HEADER]. In all cases, "RFC822" should be + # interpreted as a reference to the updated + # RFC5322[https://www.rfc-editor.org/rfc/rfc5322.html] standard. + # + # source://net-imap//lib/net/imap/fetch_data.rb#381 + def size; end + + # :call-seq: + # text(*part_nums) -> string or nil + # text(*part_nums, offset: bytes) -> string or nil + # + # The text body of a message or a message part, if it was fetched, + # omitting the {[RFC5322]}[https://www.rfc-editor.org/rfc/rfc5322.html] + # header. + # + # See #part for a description of +part_nums+ and +offset+. + # + # This is the same as getting the value from #attr for one of: + # * "BODY[TEXT]", + # * "BODY[TEXT]<#{offset}>", + # * "BODY[#{section}.TEXT]", or + # * "BODY[#{section}.TEXT]<#{offset}>". + # + # See also: #message, #header, and #mime. + # + # source://net-imap//lib/net/imap/fetch_data.rb#299 + def text(*part, offset: T.unsafe(nil)); end + + # :call-seq: threadid -> string or nil + # + # An ObjectID that uniquely identifies a set of messages that the server + # believes should be grouped together. + # + # It is generally based on some combination of References, In-Reply-To, + # and Subject, but the exact implementation is left up to the server + # implementation. The server should return the same thread identifier for + # related messages, even if they are in different mailboxes. + # + # This is the same as getting the value for "THREADID" from + # #attr. + # + # The server must support the +OBJECTID+ extension + # {[RFC8474]}[https://www.rfc-editor.org/rfc/rfc8474.html]. + # + # source://net-imap//lib/net/imap/fetch_data.rb#501 + def threadid; end + + # :call-seq: uid -> Integer + # + # A number expressing the unique identifier of the message. + # + # This is the same as getting the value for "UID" from #attr. + # + # source://net-imap//lib/net/imap/fetch_data.rb#410 + def uid; end + + private + + # source://net-imap//lib/net/imap/fetch_data.rb#505 + def body_section_attr(*_arg0, **_arg1, &_arg2); end + + # source://net-imap//lib/net/imap/fetch_data.rb#507 + def section_attr(attr, part = T.unsafe(nil), text = T.unsafe(nil), offset: T.unsafe(nil)); end +end + +# Alias for HAS_CHILDREN, to match the \IMAP spelling. +# +# source://net-imap//lib/net/imap/flags.rb#183 +Net::IMAP::HASCHILDREN = T.let(T.unsafe(nil), Symbol) + +# Alias for HAS_NO_CHILDREN, to match the \IMAP spelling. +# +# source://net-imap//lib/net/imap/flags.rb#185 +Net::IMAP::HASNOCHILDREN = T.let(T.unsafe(nil), Symbol) + +# The presence of this attribute indicates that the mailbox has child +# mailboxes. A server SHOULD NOT set this attribute if there are child +# mailboxes and the user does not have permission to access any of them. In +# this case, +\HasNoChildren+ SHOULD be used. In many cases, however, a +# server may not be able to efficiently compute whether a user has access to +# any child mailboxes. Note that even though the +\HasChildren+ attribute +# for a mailbox must be correct at the time of processing the mailbox, a +# client must be prepared to deal with a situation when a mailbox is marked +# with the +\HasChildren+ attribute, but no child mailbox appears in the +# response to the #list command. This might happen, for example, due to child +# mailboxes being deleted or made inaccessible to the user (using access +# control) by another client before the server is able to list them. +# +# It is an error for the server to return both a +\HasChildren+ and a +# +\HasNoChildren+ attribute in the same #list response. A client that +# encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ +# attributes present should act as if both are absent in the #list response. +# +# source://net-imap//lib/net/imap/flags.rb#136 +Net::IMAP::HAS_CHILDREN = T.let(T.unsafe(nil), Symbol) + +# The presence of this attribute indicates that the mailbox has NO child +# mailboxes that are accessible to the currently authenticated user. +# +# It is an error for the server to return both a +\HasChildren+ and a +# +\HasNoChildren+ attribute in the same #list response. A client that +# encounters a #list response with both +\HasChildren+ and +\HasNoChildren+ +# attributes present should act as if both are absent in the #list response. +# +# Note: the +\HasNoChildren+ attribute should not be confused with the +# +\NoInferiors+ attribute, which indicates that no child mailboxes exist +# now and none can be created in the future. +# +# source://net-imap//lib/net/imap/flags.rb#149 +Net::IMAP::HAS_NO_CHILDREN = T.let(T.unsafe(nil), Symbol) + +# Net::IMAP::IgnoredResponse represents intentionally ignored responses. +# +# This includes untagged response "NOOP" sent by e.g. Zimbra to avoid +# some clients to close the connection. +# +# It matches no IMAP standard. +# +# source://net-imap//lib/net/imap/response_data.rb#65 +class Net::IMAP::IgnoredResponse < ::Net::IMAP::UntaggedResponse; end + +# Error raised when the server sends an invalid response. +# +# This is different from UnknownResponseError: the response has been +# rejected. Although it may be parsable, the server is forbidden from +# sending it in the current context. The client should automatically +# disconnect, abruptly (without logout). +# +# Note that InvalidResponseError does not inherit from ResponseError: it +# can be raised before the response is fully parsed. A related +# ResponseParseError or ResponseError may be the #cause. +# +# source://net-imap//lib/net/imap/errors.rb#60 +class Net::IMAP::InvalidResponseError < ::Net::IMAP::Error; end + +# Mailbox attribute indicating that this mailbox is where messages deemed to +# be junk mail are held. Some server implementations might put messages here +# automatically. Alternatively, this might just be advice to a client-side +# spam filter. +# +# source://net-imap//lib/net/imap/flags.rb#242 +Net::IMAP::JUNK = T.let(T.unsafe(nil), Symbol) + +# source://net-imap//lib/net/imap/command_data.rb#167 +class Net::IMAP::Literal + # @return [Literal] a new instance of Literal + # + # source://net-imap//lib/net/imap/command_data.rb#177 + def initialize(data); end + + # source://net-imap//lib/net/imap/command_data.rb#168 + def send_data(imap, tag); end + + # source://net-imap//lib/net/imap/command_data.rb#172 + def validate; end +end + +# source://net-imap//lib/net/imap/command_data.rb#182 +class Net::IMAP::MessageSet + # @return [MessageSet] a new instance of MessageSet + # + # source://net-imap//lib/net/imap/command_data.rb#193 + def initialize(data); end + + # source://net-imap//lib/net/imap/command_data.rb#183 + def send_data(imap, tag); end + + # source://net-imap//lib/net/imap/command_data.rb#187 + def validate; end + + private + + # source://net-imap//lib/net/imap/command_data.rb#197 + def format_internal(data); end + + # source://net-imap//lib/net/imap/command_data.rb#218 + def validate_internal(data); end +end + +# The +\NonExistent+ attribute indicates that a mailbox name does not refer +# to an existing mailbox. Note that this attribute is not meaningful by +# itself, as mailbox names that match the canonical #list pattern but don't +# exist must not be returned unless one of the two conditions listed below +# is also satisfied: +# +# 1. The mailbox name also satisfies the selection criteria (for example, +# it is subscribed and the "SUBSCRIBED" selection option has been +# specified). +# +# 2. "RECURSIVEMATCH" has been specified, and the mailbox name has at least +# one descendant mailbox name that does not match the #list pattern and +# does match the selection criteria. +# +# In practice, this means that the +\NonExistent+ attribute is usually +# returned with one or more of +\Subscribed+, +\Remote+, +\HasChildren+, or +# the CHILDINFO extended data item. +# +# The client must treat the presence of the +\NonExistent+ attribute as if the +# +\NoSelect+ attribute was also sent by the server +# +# source://net-imap//lib/net/imap/flags.rb#105 +Net::IMAP::NONEXISTENT = T.let(T.unsafe(nil), Symbol) + +# Mailbox attribute indicating it is not possible for any child levels of +# hierarchy to exist under this name; no child levels exist now and none can +# be created in the future children. +# +# The client must treat the presence of the +\NoInferiors+ attribute as if the +# +\HasNoChildren+ attribute was also sent by the server +# +# source://net-imap//lib/net/imap/flags.rb#113 +Net::IMAP::NO_INFERIORS = T.let(T.unsafe(nil), Symbol) + +# Mailbox attribute indicating it is not possible to use this name as a +# selectable mailbox. +# +# source://net-imap//lib/net/imap/flags.rb#117 +Net::IMAP::NO_SELECT = T.let(T.unsafe(nil), Symbol) + +# Net::IMAP::Namespace represents a single namespace contained inside a +# NAMESPACE response. +# +# Returned by Net::IMAP#namespace, contained inside a Namespaces object. +# +# source://net-imap//lib/net/imap/response_data.rb#496 +class Net::IMAP::Namespace < ::Struct; end + +# Net::IMAP::Namespaces represents a +NAMESPACE+ server response, which +# contains lists of #personal, #shared, and #other namespaces. +# +# Net::IMAP#namespace returns a Namespaces object. +# +# source://net-imap//lib/net/imap/response_data.rb#522 +class Net::IMAP::Namespaces < ::Struct; end + +# Common validators of number and nz_number types +# +# source://net-imap//lib/net/imap/data_encoding.rb#157 +module Net::IMAP::NumValidator + private + + # Ensure argument is 'mod_sequence_value' or raise DataFormatError + # + # source://net-imap//lib/net/imap/data_encoding.rb#204 + def ensure_mod_sequence_value(num); end + + # Ensure argument is 'number' or raise DataFormatError + # + # source://net-imap//lib/net/imap/data_encoding.rb#188 + def ensure_number(num); end + + # Ensure argument is 'nz_number' or raise DataFormatError + # + # source://net-imap//lib/net/imap/data_encoding.rb#196 + def ensure_nz_number(num); end + + # Check is passed argument valid 'mod_sequence_value' in RFC 4551 terminology + # + # source://net-imap//lib/net/imap/data_encoding.rb#179 + def valid_mod_sequence_value?(num); end + + # Check is passed argument valid 'number' in RFC 3501 terminology + # + # source://net-imap//lib/net/imap/data_encoding.rb#161 + def valid_number?(num); end + + # Check is passed argument valid 'nz_number' in RFC 3501 terminology + # + # source://net-imap//lib/net/imap/data_encoding.rb#170 + def valid_nz_number?(num); end + + class << self + # Ensure argument is 'mod_sequence_value' or raise DataFormatError + # + # @raise [DataFormatError] + # + # source://net-imap//lib/net/imap/data_encoding.rb#204 + def ensure_mod_sequence_value(num); end + + # Ensure argument is 'number' or raise DataFormatError + # + # @raise [DataFormatError] + # + # source://net-imap//lib/net/imap/data_encoding.rb#188 + def ensure_number(num); end + + # Ensure argument is 'nz_number' or raise DataFormatError + # + # @raise [DataFormatError] + # + # source://net-imap//lib/net/imap/data_encoding.rb#196 + def ensure_nz_number(num); end + + # Check is passed argument valid 'mod_sequence_value' in RFC 4551 terminology + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/data_encoding.rb#179 + def valid_mod_sequence_value?(num); end + + # Check is passed argument valid 'number' in RFC 3501 terminology + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/data_encoding.rb#161 + def valid_number?(num); end + + # Check is passed argument valid 'nz_number' in RFC 3501 terminology + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/data_encoding.rb#170 + def valid_nz_number?(num); end + end +end + +# source://net-imap//lib/net/imap/command_data.rb#152 +class Net::IMAP::QuotedString + # @return [QuotedString] a new instance of QuotedString + # + # source://net-imap//lib/net/imap/command_data.rb#162 + def initialize(data); end + + # source://net-imap//lib/net/imap/command_data.rb#153 + def send_data(imap, tag); end + + # source://net-imap//lib/net/imap/command_data.rb#157 + def validate; end +end + +# The mailbox is a remote mailbox. +# +# source://net-imap//lib/net/imap/flags.rb#176 +Net::IMAP::REMOTE = T.let(T.unsafe(nil), Symbol) + +# source://net-imap//lib/net/imap/errors.rb#74 +Net::IMAP::RESPONSE_ERRORS = T.let(T.unsafe(nil), Hash) + +# source://net-imap//lib/net/imap/command_data.rb#122 +class Net::IMAP::RawData + # @return [RawData] a new instance of RawData + # + # source://net-imap//lib/net/imap/command_data.rb#132 + def initialize(data); end + + # source://net-imap//lib/net/imap/command_data.rb#123 + def send_data(imap, tag); end + + # source://net-imap//lib/net/imap/command_data.rb#127 + def validate; end +end + +# Superclass of all errors used to encapsulate "fail" responses +# from the server. +# +# source://net-imap//lib/net/imap/errors.rb#20 +class Net::IMAP::ResponseError < ::Net::IMAP::Error + # @return [ResponseError] a new instance of ResponseError + # + # source://net-imap//lib/net/imap/errors.rb#25 + def initialize(response); end + + # The response that caused this error + # + # source://net-imap//lib/net/imap/errors.rb#23 + def response; end + + # The response that caused this error + # + # source://net-imap//lib/net/imap/errors.rb#23 + def response=(_arg0); end +end + +# Parses an \IMAP server response. +# +# source://net-imap//lib/net/imap/response_parser/parser_utils.rb#5 +class Net::IMAP::ResponseParser + include ::Net::IMAP::ResponseParser::ParserUtils + include ::Net::IMAP::ResponseParser::ResponseConditions + extend ::Net::IMAP::ResponseParser::ParserUtils::Generator + + # :call-seq: Net::IMAP::ResponseParser.new -> Net::IMAP::ResponseParser + # + # @return [ResponseParser] a new instance of ResponseParser + # + # source://net-imap//lib/net/imap/response_parser.rb#17 + def initialize(config: T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def CRLF!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def CRLF?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def EOF!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def EOF?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def NIL!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def NIL?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#46 + def PLUS!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def PLUS?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#46 + def SP!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def SP?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#46 + def STAR!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def STAR?; end + + # RFC-3501 & RFC-9051: + # body-fld-enc = (DQUOTE ("7BIT" / "8BIT" / "BINARY" / "BASE64"/ + # "QUOTED-PRINTABLE") DQUOTE) / string + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def body_fld_enc; end + + # valid number ranges are not enforced by parser + # number64 = 1*DIGIT + # ; Unsigned 63-bit integer + # ; (0 <= n <= 9,223,372,036,854,775,807) + # number in 3501, number64 in 9051 + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def body_fld_lines; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def body_fld_octets; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def case_insensitive__string; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def case_insensitive__string?; end + + # Returns the value of attribute config. + # + # source://net-imap//lib/net/imap/response_parser.rb#14 + def config; end + + # date-time = DQUOTE date-day-fixed "-" date-month "-" date-year + # SP time SP zone DQUOTE + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def date_time; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#46 + def lbra; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def lbra?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_CRLF!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_EOF!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_NIL!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_PLUS?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_SP?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_STAR?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_body?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_case_insensitive__string!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_lbra?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_lpar?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_number!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_quoted!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_rbra?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_rpar?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_string!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_string8!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#86 + def lookahead_tagged_ext_label!; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_thread_list?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#25 + def lookahead_thread_nested?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#46 + def lpar; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def lpar?; end + + # text/* + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def media_subtype; end + + # valid number ranges are not enforced by parser + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + # valid number ranges are not enforced by parser + # nz-number64 = digit-nz *DIGIT + # ; Unsigned 63-bit integer + # ; (0 < n <= 9,223,372,036,854,775,807) + # RFC7162: + # mod-sequence-value = 1*DIGIT + # ;; Positive unsigned 63-bit integer + # ;; (mod-sequence) + # ;; (1 <= n <= 9,223,372,036,854,775,807). + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def mod_sequence_value; end + + # valid number ranges are not enforced by parser + # number64 = 1*DIGIT + # ; Unsigned 63-bit integer + # ; (0 <= n <= 9,223,372,036,854,775,807) + # RFC7162: + # mod-sequence-valzer = "0" / mod-sequence-value + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def mod_sequence_valzer; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def number; end + + # valid number ranges are not enforced by parser + # number64 = 1*DIGIT + # ; Unsigned 63-bit integer + # ; (0 <= n <= 9,223,372,036,854,775,807) + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def number64; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def number64?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def number?; end + + # valid number ranges are not enforced by parser + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def nz_number; end + + # valid number ranges are not enforced by parser + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + # valid number ranges are not enforced by parser + # nz-number64 = digit-nz *DIGIT + # ; Unsigned 63-bit integer + # ; (0 < n <= 9,223,372,036,854,775,807) + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def nz_number64; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def nz_number?; end + + # :call-seq: + # parse(str) -> ContinuationRequest + # parse(str) -> UntaggedResponse + # parse(str) -> TaggedResponse + # + # Raises ResponseParseError for unparsable strings. + # + # source://net-imap//lib/net/imap/response_parser.rb#31 + def parse(str); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#30 + def peek_PLUS?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#30 + def peek_SP?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#30 + def peek_STAR?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#30 + def peek_lbra?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#30 + def peek_lpar?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#30 + def peek_rbra?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#30 + def peek_rpar?; end + + # valid number ranges are not enforced by parser + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + # valid number ranges are not enforced by parser + # nz-number64 = digit-nz *DIGIT + # ; Unsigned 63-bit integer + # ; (0 < n <= 9,223,372,036,854,775,807) + # RFC7162: + # mod-sequence-value = 1*DIGIT + # ;; Positive unsigned 63-bit integer + # ;; (mod-sequence) + # ;; (1 <= n <= 9,223,372,036,854,775,807). + # RFC7162: + # permsg-modsequence = mod-sequence-value + # ;; Per-message mod-sequence. + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def permsg_modsequence; end + + # Used when servers erroneously send an extra SP. + # + # As of 2023-11-28, Outlook.com (still) sends SP + # between +address+ in env-* lists. + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def quirky_SP?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def quoted; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def quoted?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#46 + def rbra; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def rbra?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#46 + def rpar; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#35 + def rpar?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def string; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def string8; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def string8?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def string?; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def tagged_ext_label; end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#96 + def tagged_ext_label?; end + + # valid number ranges are not enforced by parser + # nz-number = digit-nz *DIGIT + # ; Non-zero unsigned 32-bit integer + # ; (0 < n < 4,294,967,296) + # valid number ranges are not enforced by parser + # uniqueid = nz-number + # ; Strictly ascending + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def uniqueid; end + + # valid number ranges are not enforced by parser + # + # a 64-bit unsigned integer and is the decimal equivalent for the ID hex + # string used in the web interface and the Gmail API. + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#104 + def x_gm_id; end + + private + + # The RFC is very strict about this and usually we should be too. + # But skipping spaces is usually a safe workaround for buggy servers. + # + # This advances @pos directly so it's safe before changing @lex_state. + # + # source://net-imap//lib/net/imap/response_parser.rb#2027 + def accept_spaces; end + + # acl-data = "ACL" SP mailbox *(SP identifier SP rights) + # + # source://net-imap//lib/net/imap/response_parser.rb#1428 + def acl_data; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def addr_adl; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def addr_host; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def addr_mailbox; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def addr_name; end + + # address = "(" addr-name SP addr-adl SP addr-mailbox SP + # addr-host ")" + # addr-adl = nstring + # addr-host = nstring + # addr-mailbox = nstring + # addr-name = nstring + # + # source://net-imap//lib/net/imap/response_parser.rb#1896 + def address; end + + # astring = 1*ASTRING-CHAR / string + # + # source://net-imap//lib/net/imap/response_parser.rb#506 + def astring; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_parser.rb#510 + def astring?; end + + # source://net-imap//lib/net/imap/response_parser.rb#491 + def astring_chars; end + + # TODO: handle atom, astring_chars, and tag entirely inside the lexer + # + # source://net-imap//lib/net/imap/response_parser.rb#490 + def atom; end + + # the #accept version of #atom + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_parser.rb#495 + def atom?; end + + # RFC-3501 & RFC-9051: + # body = "(" (body-type-1part / body-type-mpart) ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1012 + def body; end + + # RFC2060 + # body_ext_1part ::= body_fld_md5 [SPACE body_fld_dsp + # [SPACE body_fld_lang + # [SPACE 1#body_extension]]] + # ;; MUST NOT be returned on non-extensible + # ;; "BODY" fetch + # RFC3501 & RFC9051 + # body-ext-1part = body-fld-md5 [SP body-fld-dsp [SP body-fld-lang + # [SP body-fld-loc *(SP body-extension)]]] + # ; MUST NOT be returned on non-extensible + # ; "BODY" fetch + # + # source://net-imap//lib/net/imap/response_parser.rb#1184 + def body_ext_1part; end + + # RFC-2060: + # body_ext_mpart = body_fld_param [SP body_fld_dsp SP body_fld_lang + # [SP 1#body_extension]] + # ;; MUST NOT be returned on non-extensible + # ;; "BODY" fetch + # RFC-3501 & RFC-9051: + # body-ext-mpart = body-fld-param [SP body-fld-dsp [SP body-fld-lang + # [SP body-fld-loc *(SP body-extension)]]] + # ; MUST NOT be returned on non-extensible + # ; "BODY" fetch + # + # source://net-imap//lib/net/imap/response_parser.rb#1203 + def body_ext_mpart; end + + # body-extension = nstring / number / number64 / + # "(" body-extension *(SP body-extension) ")" + # ; Future expansion. Client implementations + # ; MUST accept body-extension fields. Server + # ; implementations MUST NOT generate + # ; body-extension fields except as defined by + # ; future Standard or Standards Track + # ; revisions of this specification. + # + # source://net-imap//lib/net/imap/response_parser.rb#1260 + def body_extension; end + + # body-extension *(SP body-extension) + # + # source://net-imap//lib/net/imap/response_parser.rb#1246 + def body_extensions; end + + # RFC-3501 & RFC-9051: + # body-fields = body-fld-param SP body-fld-id SP body-fld-desc SP + # body-fld-enc SP body-fld-octets + # + # source://net-imap//lib/net/imap/response_parser.rb#1148 + def body_fields; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def body_fld_desc; end + + # body-fld-dsp = "(" string SP body-fld-param ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#1225 + def body_fld_dsp; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def body_fld_id; end + + # body-fld-lang = nstring / "(" string *(SP string) ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1234 + def body_fld_lang; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def body_fld_loc; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def body_fld_md5; end + + # RFC3501, RFC9051: + # body-fld-param = "(" string SP string *(SP string SP string) ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#1160 + def body_fld_param; end + + # RFC-3501 & RFC9051: + # body-type-1part = (body-type-basic / body-type-msg / body-type-text) + # [SP body-ext-1part] + # + # source://net-imap//lib/net/imap/response_parser.rb#1024 + def body_type_1part; end + + # RFC-3501 & RFC9051: + # body-type-basic = media-basic SP body-fields + # + # source://net-imap//lib/net/imap/response_parser.rb#1048 + def body_type_basic; end + + # This is a malformed body-type-mpart with no subparts. + # + # source://net-imap//lib/net/imap/response_parser.rb#1097 + def body_type_mixed; end + + # RFC-3501 & RFC-9051: + # body-type-mpart = 1*body SP media-subtype + # [SP body-ext-mpart] + # + # source://net-imap//lib/net/imap/response_parser.rb#1107 + def body_type_mpart; end + + # RFC-3501 & RFC-9051: + # body-type-msg = media-message SP body-fields SP envelope + # SP body SP body-fld-lines + # + # source://net-imap//lib/net/imap/response_parser.rb#1069 + def body_type_msg; end + + # RFC-3501 & RFC-9051: + # body-type-text = media-text SP body-fields SP body-fld-lines + # + # source://net-imap//lib/net/imap/response_parser.rb#1058 + def body_type_text; end + + # Returns atom.upcase + # capability = ("AUTH=" auth-type) / atom + # ; New capabilities MUST begin with "X" or be + # ; registered with IANA as standard or + # ; standards-track + # + # source://net-imap//lib/net/imap/response_parser.rb#498 + def capability; end + + # Returns atom?&.upcase + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_parser.rb#501 + def capability?; end + + # As a workaround for buggy servers, allow a trailing SP: + # *(SP capability) [SP] + # + # source://net-imap//lib/net/imap/response_parser.rb#1631 + def capability__list; end + + # The presence of "IMAP4rev1" or "IMAP4rev2" is unenforced here. + # The grammar rule is used by both response-data and resp-text-code. + # But this method only returns UntaggedResponse (response-data). + # + # RFC3501: + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev1" + # *(SP capability) + # RFC9051: + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev2" + # *(SP capability) + # + # source://net-imap//lib/net/imap/response_parser.rb#1620 + def capability_data__untagged; end + + # Returns atom.upcase + # + # source://net-imap//lib/net/imap/response_parser.rb#498 + def case_insensitive__atom; end + + # Returns atom?&.upcase + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_parser.rb#501 + def case_insensitive__atom?; end + + # use where nstring represents "LABEL" values + # + # source://net-imap//lib/net/imap/response_parser.rb#559 + def case_insensitive__nstring; end + + # See https://www.rfc-editor.org/errata/rfc3501 + # + # charset = atom / quoted + # + # source://net-imap//lib/net/imap/response_parser.rb#1967 + def charset; end + + # "(" charset *(SP charset) ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1850 + def charset__list; end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def comparator_data(klass = T.unsafe(nil)); end + + # RFC3501 & RFC9051: + # continue-req = "+" SP (resp-text / base64) CRLF + # + # n.b: base64 is valid resp-text. And in the spirit of RFC9051 Appx E 23 + # (and to workaround existing servers), we use the following grammar: + # + # continue-req = "+" (SP (resp-text)) CRLF + # + # source://net-imap//lib/net/imap/response_parser.rb#676 + def continue_req; end + + # enable-data = "ENABLED" *(SP capability) + # + # source://net-imap//lib/net/imap/response_parser.rb#1625 + def enable_data; end + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#986 + def env_bcc; end + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#986 + def env_cc; end + + # nstring = string / nil + # env-date = nstring + # env-subject = nstring + # env-in-reply-to = nstring + # env-message-id = nstring + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def env_date; end + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#986 + def env_from; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def env_in_reply_to; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def env_message_id; end + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#986 + def env_reply_to; end + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#986 + def env_sender; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def env_subject; end + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#986 + def env_to; end + + # RFC3501 & RFC9051: + # envelope = "(" env-date SP env-subject SP env-from SP + # env-sender SP env-reply-to SP env-to SP env-cc SP + # env-bcc SP env-in-reply-to SP env-message-id ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#952 + def envelope; end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def esearch_response(klass = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def expunged_resp(klass = T.unsafe(nil)); end + + # flag-list = "(" [flag *(SP flag)] ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1917 + def flag_list; end + + # "(" [flag-perm *(SP flag-perm)] ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1927 + def flag_perm__list; end + + # TODO: handle atom, astring_chars, and tag entirely inside the lexer + # this represents the partial size for BODY or BINARY + # + # source://net-imap//lib/net/imap/response_parser.rb#490 + def gt__number__lt; end + + # RFC3501 & RFC9051: + # header-fld-name = astring + # + # NOTE: Previously, Net::IMAP recreated the raw original source string. + # Now, it grabs the raw encoded value using @str and @pos. A future + # version may simply return the decoded astring value. Although that is + # technically incompatible, it should almost never make a difference: all + # standard header field names are valid atoms: + # + # https://www.iana.org/assignments/message-headers/message-headers.xhtml + # + # Although RFC3501 allows any astring, RFC5322-valid header names are one + # or more of the printable US-ASCII characters, except SP and colon. So + # empty string isn't valid, and literals aren't needed and should not be + # used. This is explicitly unchanged by [I18N-HDRS] (RFC6532). + # + # RFC5233: + # optional-field = field-name ":" unstructured CRLF + # field-name = 1*ftext + # ftext = %d33-57 / ; Printable US-ASCII + # %d59-126 ; characters not including + # ; ":". + # + # source://net-imap//lib/net/imap/response_parser.rb#1338 + def header_fld_name; end + + # header-list = "(" header-fld-name *(SP header-fld-name) ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1304 + def header_list; end + + # source://net-imap//lib/net/imap/response_parser.rb#1644 + def id_response; end + + # Use #label or #label_in to assert specific known labels + # (+tagged-ext-label+ only, not +atom+). + # + # source://net-imap//lib/net/imap/response_parser.rb#516 + def label(word); end + + # Use #label or #label_in to assert specific known labels + # (+tagged-ext-label+ only, not +atom+). + # + # source://net-imap//lib/net/imap/response_parser.rb#523 + def label_in(*labels); end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def language_data(klass = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def listrights_data(klass = T.unsafe(nil)); end + + # astring = 1*ASTRING-CHAR / string + # mailbox = "INBOX" / astring + # ; INBOX is case-insensitive. All case variants of + # ; INBOX (e.g., "iNbOx") MUST be interpreted as INBOX + # ; not as an astring. An astring which consists of + # ; the case-insensitive sequence "I" "N" "B" "O" "X" + # ; is considered to be INBOX and not an astring. + # ; Refer to section 5.1 for further + # ; semantic details of mailbox names. + # + # source://net-imap//lib/net/imap/response_parser.rb#506 + def mailbox; end + + # source://net-imap//lib/net/imap/response_parser.rb#835 + def mailbox_data__exists; end + + # mailbox-data = "FLAGS" SP flag-list / "LIST" SP mailbox-list / + # "LSUB" SP mailbox-list / "SEARCH" *(SP nz-number) / + # "STATUS" SP mailbox SP "(" [status-att-list] ")" / + # number SP "EXISTS" / number SP "RECENT" + # + # source://net-imap//lib/net/imap/response_parser.rb#1350 + def mailbox_data__flags; end + + # source://net-imap//lib/net/imap/response_parser.rb#1356 + def mailbox_data__list; end + + # source://net-imap//lib/net/imap/response_parser.rb#1356 + def mailbox_data__lsub; end + + # source://net-imap//lib/net/imap/response_parser.rb#835 + def mailbox_data__recent; end + + # RFC3501: + # mailbox-data = "SEARCH" *(SP nz-number) / ... + # RFC5256: SORT + # sort-data = "SORT" *(SP nz-number) + # RFC7162: CONDSTORE, QRESYNC + # mailbox-data =/ "SEARCH" [1*(SP nz-number) SP + # search-sort-mod-seq] + # sort-data = "SORT" [1*(SP nz-number) SP + # search-sort-mod-seq] + # ; Updates the SORT response from RFC 5256. + # search-sort-mod-seq = "(" "MODSEQ" SP mod-sequence-value ")" + # RFC9051: + # mailbox-data = obsolete-search-response / ... + # obsolete-search-response = "SEARCH" *(SP nz-number) + # + # source://net-imap//lib/net/imap/response_parser.rb#1468 + def mailbox_data__search; end + + # mailbox-data =/ "STATUS" SP mailbox SP "(" [status-att-list] ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1534 + def mailbox_data__status; end + + # source://net-imap//lib/net/imap/response_parser.rb#1356 + def mailbox_data__xlist; end + + # mailbox-list = "(" [mbx-list-flags] ")" SP + # (DQUOTE QUOTED-CHAR DQUOTE / nil) SP mailbox + # [SP mbox-list-extended] + # ; This is the list information pointed to by the ABNF + # ; item "mailbox-data", which is defined above + # + # source://net-imap//lib/net/imap/response_parser.rb#1369 + def mailbox_list; end + + # See Patterns::MBX_LIST_FLAGS + # + # source://net-imap//lib/net/imap/response_parser.rb#1945 + def mbx_list_flags; end + + # n.b. this handles both type and subtype + # + # RFC-3501 vs RFC-9051: + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "MESSAGE" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "FONT" / "MESSAGE" / "MODEL" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE "RFC822" DQUOTE + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE ("RFC822" / "GLOBAL") DQUOTE + # + # RFC-3501 & RFC-9051: + # media-text = DQUOTE "TEXT" DQUOTE SP media-subtype + # media-subtype = string + # TODO: check types + # + # source://net-imap//lib/net/imap/response_parser.rb#1131 + def media_basic; end + + # n.b. this handles both type and subtype + # + # RFC-3501 vs RFC-9051: + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "MESSAGE" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "FONT" / "MESSAGE" / "MODEL" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE "RFC822" DQUOTE + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE ("RFC822" / "GLOBAL") DQUOTE + # + # RFC-3501 & RFC-9051: + # media-text = DQUOTE "TEXT" DQUOTE SP media-subtype + # media-subtype = string + # */* --- catchall + # + # source://net-imap//lib/net/imap/response_parser.rb#1131 + def media_message; end + + # n.b. this handles both type and subtype + # + # RFC-3501 vs RFC-9051: + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "MESSAGE" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "FONT" / "MESSAGE" / "MODEL" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE "RFC822" DQUOTE + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE ("RFC822" / "GLOBAL") DQUOTE + # + # RFC-3501 & RFC-9051: + # media-text = DQUOTE "TEXT" DQUOTE SP media-subtype + # media-subtype = string + # message/rfc822, message/global + # + # source://net-imap//lib/net/imap/response_parser.rb#1131 + def media_text; end + + # n.b. this handles both type and subtype + # + # RFC-3501 vs RFC-9051: + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "MESSAGE" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # media-basic = ((DQUOTE ("APPLICATION" / "AUDIO" / "IMAGE" / + # "FONT" / "MESSAGE" / "MODEL" / + # "VIDEO") DQUOTE) / string) SP media-subtype + # + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE "RFC822" DQUOTE + # media-message = DQUOTE "MESSAGE" DQUOTE SP + # DQUOTE ("RFC822" / "GLOBAL") DQUOTE + # + # RFC-3501 & RFC-9051: + # media-text = DQUOTE "TEXT" DQUOTE SP media-subtype + # media-subtype = string + # + # source://net-imap//lib/net/imap/response_parser.rb#1131 + def media_type; end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def message_data__converted(klass = T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/response_parser.rb#835 + def message_data__expunge; end + + # message-data = nz-number SP ("EXPUNGE" / ("FETCH" SP msg-att)) + # + # source://net-imap//lib/net/imap/response_parser.rb#828 + def message_data__fetch; end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def metadata_resp(klass = T.unsafe(nil)); end + + # RFC3501 & RFC9051: + # msg-att = "(" (msg-att-dynamic / msg-att-static) + # *(SP (msg-att-dynamic / msg-att-static)) ")" + # + # msg-att-dynamic = "FLAGS" SP "(" [flag-fetch *(SP flag-fetch)] ")" + # RFC5257 (ANNOTATE extension): + # msg-att-dynamic =/ "ANNOTATION" SP + # ( "(" entry-att *(SP entry-att) ")" / + # "(" entry *(SP entry) ")" ) + # RFC7162 (CONDSTORE extension): + # msg-att-dynamic =/ fetch-mod-resp + # fetch-mod-resp = "MODSEQ" SP "(" permsg-modsequence ")" + # RFC8970 (PREVIEW extension): + # msg-att-dynamic =/ "PREVIEW" SP nstring + # + # RFC3501: + # msg-att-static = "ENVELOPE" SP envelope / + # "INTERNALDATE" SP date-time / + # "RFC822" [".HEADER" / ".TEXT"] SP nstring / + # "RFC822.SIZE" SP number / + # "BODY" ["STRUCTURE"] SP body / + # "BODY" section ["<" number ">"] SP nstring / + # "UID" SP uniqueid + # RFC3516 (BINARY extension): + # msg-att-static =/ "BINARY" section-binary SP (nstring / literal8) + # / "BINARY.SIZE" section-binary SP number + # RFC8514 (SAVEDATE extension): + # msg-att-static =/ "SAVEDATE" SP (date-time / nil) + # RFC8474 (OBJECTID extension): + # msg-att-static =/ fetch-emailid-resp / fetch-threadid-resp + # fetch-emailid-resp = "EMAILID" SP "(" objectid ")" + # fetch-threadid-resp = "THREADID" SP ( "(" objectid ")" / nil ) + # RFC9051: + # msg-att-static = "ENVELOPE" SP envelope / + # "INTERNALDATE" SP date-time / + # "RFC822.SIZE" SP number64 / + # "BODY" ["STRUCTURE"] SP body / + # "BODY" section ["<" number ">"] SP nstring / + # "BINARY" section-binary SP (nstring / literal8) / + # "BINARY.SIZE" section-binary SP number / + # "UID" SP uniqueid + # + # Re https://www.rfc-editor.org/errata/eid7246, I'm adding "offset" to the + # official "BINARY" ABNF, like so: + # + # msg-att-static =/ "BINARY" section-binary ["<" number ">"] SP + # (nstring / literal8) + # + # source://net-imap//lib/net/imap/response_parser.rb#892 + def msg_att(n); end + + # appends "[section]" and "" to the base label + # + # source://net-imap//lib/net/imap/response_parser.rb#929 + def msg_att__label; end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def myrights_data(klass = T.unsafe(nil)); end + + # namespace = nil / "(" 1*namespace-descr ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1691 + def namespace; end + + # namespace-descr = "(" string SP + # (DQUOTE QUOTED-CHAR DQUOTE / nil) + # [namespace-response-extensions] ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1702 + def namespace_descr; end + + # namespace-response = "NAMESPACE" SP namespace + # SP namespace SP namespace + # ; The first Namespace is the Personal Namespace(s). + # ; The second Namespace is the Other Users' + # ; Namespace(s). + # ; The third Namespace is the Shared Namespace(s). + # + # source://net-imap//lib/net/imap/response_parser.rb#1679 + def namespace_response; end + + # namespace-response-extensions = *namespace-response-extension + # namespace-response-extension = SP string SP + # "(" string *(SP string) ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1714 + def namespace_response_extensions; end + + # source://net-imap//lib/net/imap/response_parser.rb#554 + def ndatetime; end + + # source://net-imap//lib/net/imap/response_parser.rb#2034 + def next_token; end + + # source://net-imap//lib/net/imap/response_parser.rb#2016 + def nil_atom; end + + # env-from = "(" 1*address ")" / nil + # env-sender = "(" 1*address ")" / nil + # env-reply-to = "(" 1*address ")" / nil + # env-to = "(" 1*address ")" / nil + # env-cc = "(" 1*address ")" / nil + # env-bcc = "(" 1*address ")" / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#986 + def nlist__address; end + + # source://net-imap//lib/net/imap/response_parser.rb#1994 + def nparens__objectid; end + + # source://net-imap//lib/net/imap/response_parser.rb#554 + def nquoted; end + + # nstring = string / nil + # + # source://net-imap//lib/net/imap/response_parser.rb#546 + def nstring; end + + # source://net-imap//lib/net/imap/response_parser.rb#550 + def nstring8; end + + # TODO: handle atom, astring_chars, and tag entirely inside the lexer + # RFC8474: + # objectid = 1*255(ALPHA / DIGIT / "_" / "-") + # ; characters in object identifiers are case + # ; significant + # + # source://net-imap//lib/net/imap/response_parser.rb#490 + def objectid; end + + # source://net-imap//lib/net/imap/response_parser.rb#1985 + def parens__modseq; end + + # source://net-imap//lib/net/imap/response_parser.rb#1993 + def parens__objectid; end + + # This allows illegal "]" in flag names (Gmail), + # or "\*" in a FLAGS response (greenmail). + # + # source://net-imap//lib/net/imap/response_parser.rb#1938 + def quirky__flag_list(name); end + + # source://net-imap//lib/net/imap/response_parser.rb#1377 + def quota_response; end + + # source://net-imap//lib/net/imap/response_parser.rb#1410 + def quotaroot_response; end + + # reads all the way up until CRLF + # + # source://net-imap//lib/net/imap/response_parser.rb#764 + def remaining_unparsed; end + + # As a workaround for buggy servers, allow a trailing SP: + # *(SP capability) [SP] + # + # source://net-imap//lib/net/imap/response_parser.rb#1631 + def resp_code__capability; end + + # already matched: "APPENDUID" + # + # +UIDPLUS+ ABNF:: https://www.rfc-editor.org/rfc/rfc4315.html#section-4 + # resp-code-apnd = "APPENDUID" SP nz-number SP append-uid + # append-uid = uniqueid + # append-uid =/ uid-set + # ; only permitted if client uses [MULTIAPPEND] + # ; to append multiple messages. + # + # n.b, uniqueid ⊂ uid-set. To avoid inconsistent return types, we always + # match uid_set even if that returns a single-member array. + # + # source://net-imap//lib/net/imap/response_parser.rb#1866 + def resp_code_apnd__data; end + + # already matched: "COPYUID" + # + # resp-code-copy = "COPYUID" SP nz-number SP uid-set SP uid-set + # + # source://net-imap//lib/net/imap/response_parser.rb#1875 + def resp_code_copy__data; end + + # resp-cond-auth = ("OK" / "PREAUTH") SP resp-text + # + # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing + # servers), we don't require a final SP and instead parse this as: + # + # resp-cond-auth = ("OK" / "PREAUTH") [SP resp-text] + # + # source://net-imap//lib/net/imap/response_parser.rb#809 + def resp_cond_auth; end + + # expects "OK" or "PREAUTH" and raises InvalidResponseError on failure + # + # @raise [InvalidResponseError] + # + # source://net-imap//lib/net/imap/response_parser.rb#530 + def resp_cond_auth__name; end + + # resp-cond-bye = "BYE" SP resp-text + # + # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing + # servers), we don't require a final SP and instead parse this as: + # + # resp-cond-bye = "BYE" [SP resp-text] + # + # source://net-imap//lib/net/imap/response_parser.rb#821 + def resp_cond_bye; end + + # RFC3501 & RFC9051: + # resp-cond-state = ("OK" / "NO" / "BAD") SP resp-text + # + # NOTE: In the spirit of RFC9051 Appx E 23 (and to workaround existing + # servers), we don't require a final SP and instead parse this as: + # + # resp-cond-state = ("OK" / "NO" / "BAD") [SP resp-text] + # + # source://net-imap//lib/net/imap/response_parser.rb#795 + def resp_cond_state; end + + # expects "OK" or "NO" or "BAD" and raises InvalidResponseError on failure + # + # @raise [InvalidResponseError] + # + # source://net-imap//lib/net/imap/response_parser.rb#538 + def resp_cond_state__name; end + + # source://net-imap//lib/net/imap/response_parser.rb#799 + def resp_cond_state__untagged; end + + # RFC3501: + # resp-text = ["[" resp-text-code "]" SP] text + # RFC9051: + # resp-text = ["[" resp-text-code "]" SP] [text] + # + # We leniently re-interpret this as + # resp-text = ["[" resp-text-code "]" [SP [text]] / [text] + # + # source://net-imap//lib/net/imap/response_parser.rb#1750 + def resp_text; end + + # RFC3501 (See https://www.rfc-editor.org/errata/rfc3501): + # resp-text-code = "ALERT" / + # "BADCHARSET" [SP "(" charset *(SP charset) ")" ] / + # capability-data / "PARSE" / + # "PERMANENTFLAGS" SP "(" [flag-perm *(SP flag-perm)] ")" / + # "READ-ONLY" / "READ-WRITE" / "TRYCREATE" / + # "UIDNEXT" SP nz-number / "UIDVALIDITY" SP nz-number / + # "UNSEEN" SP nz-number / + # atom [SP 1*] + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev1" + # *(SP capability) + # + # RFC5530: + # resp-text-code =/ "UNAVAILABLE" / "AUTHENTICATIONFAILED" / + # "AUTHORIZATIONFAILED" / "EXPIRED" / + # "PRIVACYREQUIRED" / "CONTACTADMIN" / "NOPERM" / + # "INUSE" / "EXPUNGEISSUED" / "CORRUPTION" / + # "SERVERBUG" / "CLIENTBUG" / "CANNOT" / + # "LIMIT" / "OVERQUOTA" / "ALREADYEXISTS" / + # "NONEXISTENT" + # RFC9051: + # resp-text-code = "ALERT" / + # "BADCHARSET" [SP "(" charset *(SP charset) ")" ] / + # capability-data / "PARSE" / + # "PERMANENTFLAGS" SP "(" [flag-perm *(SP flag-perm)] ")" / + # "READ-ONLY" / "READ-WRITE" / "TRYCREATE" / + # "UIDNEXT" SP nz-number / "UIDVALIDITY" SP nz-number / + # resp-code-apnd / resp-code-copy / "UIDNOTSTICKY" / + # "UNAVAILABLE" / "AUTHENTICATIONFAILED" / + # "AUTHORIZATIONFAILED" / "EXPIRED" / + # "PRIVACYREQUIRED" / "CONTACTADMIN" / "NOPERM" / + # "INUSE" / "EXPUNGEISSUED" / "CORRUPTION" / + # "SERVERBUG" / "CLIENTBUG" / "CANNOT" / + # "LIMIT" / "OVERQUOTA" / "ALREADYEXISTS" / + # "NONEXISTENT" / "NOTSAVED" / "HASCHILDREN" / + # "CLOSED" / + # "UNKNOWN-CTE" / + # atom [SP 1*] + # capability-data = "CAPABILITY" *(SP capability) SP "IMAP4rev2" + # *(SP capability) + # + # RFC4315 (UIDPLUS), RFC9051 (IMAP4rev2): + # resp-code-apnd = "APPENDUID" SP nz-number SP append-uid + # resp-code-copy = "COPYUID" SP nz-number SP uid-set SP uid-set + # resp-text-code =/ resp-code-apnd / resp-code-copy / "UIDNOTSTICKY" + # + # RFC7162 (CONDSTORE): + # resp-text-code =/ "HIGHESTMODSEQ" SP mod-sequence-value / + # "NOMODSEQ" / + # "MODIFIED" SP sequence-set + # RFC7162 (QRESYNC): + # resp-text-code =/ "CLOSED" + # + # RFC8474: OBJECTID + # resp-text-code =/ "MAILBOXID" SP "(" objectid ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1814 + def resp_text_code; end + + # Returns atom.upcase + # + # source://net-imap//lib/net/imap/response_parser.rb#498 + def resp_text_code__name; end + + # [RFC3501 & RFC9051:] + # response = *(continue-req / response-data) response-done + # + # For simplicity, response isn't interpreted as the combination of the + # three response types, but instead represents any individual server + # response. Our simplified interpretation is defined as: + # response = continue-req | response_data | response-tagged + # + # n.b: our "response-tagged" definition parses "greeting" too. + # + # source://net-imap//lib/net/imap/response_parser.rb#657 + def response; end + + # [RFC3501:] + # response-data = "*" SP (resp-cond-state / resp-cond-bye / + # mailbox-data / message-data / capability-data) CRLF + # [RFC4466:] + # response-data = "*" SP response-payload CRLF + # response-payload = resp-cond-state / resp-cond-bye / + # mailbox-data / message-data / capability-data + # RFC5161 (ENABLE capability): + # response-data =/ "*" SP enable-data CRLF + # RFC5255 (LANGUAGE capability) + # response-payload =/ language-data + # RFC5255 (I18NLEVEL=1 and I18NLEVEL=2 capabilities) + # response-payload =/ comparator-data + # [RFC9051:] + # response-data = "*" SP (resp-cond-state / resp-cond-bye / + # mailbox-data / message-data / capability-data / + # enable-data) CRLF + # + # [merging in greeting and response-fatal:] + # greeting = "*" SP (resp-cond-auth / resp-cond-bye) CRLF + # response-fatal = "*" SP resp-cond-bye CRLF + # response-data =/ "*" SP (resp-cond-auth / resp-cond-bye) CRLF + # [removing duplicates, this is simply] + # response-payload =/ resp-cond-auth + # + # TODO: remove resp-cond-auth and handle greeting separately + # + # source://net-imap//lib/net/imap/response_parser.rb#709 + def response_data; end + + # source://net-imap//lib/net/imap/response_parser.rb#769 + def response_data__ignored; end + + # source://net-imap//lib/net/imap/response_parser.rb#769 + def response_data__noop; end + + # source://net-imap//lib/net/imap/response_parser.rb#835 + def response_data__simple_numeric; end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def response_data__unhandled(klass = T.unsafe(nil)); end + + # RFC3501 & RFC9051: + # response-tagged = tag SP resp-cond-state CRLF + # + # source://net-imap//lib/net/imap/response_parser.rb#784 + def response_tagged; end + + # section = "[" [section-spec] "]" + # + # source://net-imap//lib/net/imap/response_parser.rb#1268 + def section; end + + # section-binary = "[" [section-part] "]" + # + # source://net-imap//lib/net/imap/response_parser.rb#1275 + def section_binary; end + + # TODO: handle atom, astring_chars, and tag entirely inside the lexer + # section-part = nz-number *("." nz-number) + # ; body part reference. + # ; Allows for accessing nested body parts. + # + # source://net-imap//lib/net/imap/response_parser.rb#490 + def section_part; end + + # section-spec = section-msgtext / (section-part ["." section-text]) + # section-msgtext = "HEADER" / + # "HEADER.FIELDS" [".NOT"] SP header-list / + # "TEXT" + # ; top-level or MESSAGE/RFC822 or + # ; MESSAGE/GLOBAL part + # section-part = nz-number *("." nz-number) + # ; body part reference. + # ; Allows for accessing nested body parts. + # section-text = section-msgtext / "MIME" + # ; text other than actual body part (headers, + # ; etc.) + # + # n.b: we could "cheat" here and just grab all text inside the brackets, + # but literals would need special treatment. + # + # source://net-imap//lib/net/imap/response_parser.rb#1296 + def section_spec; end + + # sequence-set = (seq-number / seq-range) ["," sequence-set] + # sequence-set =/ seq-last-command + # ; Allow for "result of the last command" + # ; indicator. + # seq-last-command = "$" + # + # *note*: doesn't match seq-last-command + # + # source://net-imap//lib/net/imap/response_parser.rb#471 + def sequence_set; end + + # RFC3501: + # mailbox-data = "SEARCH" *(SP nz-number) / ... + # RFC5256: SORT + # sort-data = "SORT" *(SP nz-number) + # RFC7162: CONDSTORE, QRESYNC + # mailbox-data =/ "SEARCH" [1*(SP nz-number) SP + # search-sort-mod-seq] + # sort-data = "SORT" [1*(SP nz-number) SP + # search-sort-mod-seq] + # ; Updates the SORT response from RFC 5256. + # search-sort-mod-seq = "(" "MODSEQ" SP mod-sequence-value ")" + # RFC9051: + # mailbox-data = obsolete-search-response / ... + # obsolete-search-response = "SEARCH" *(SP nz-number) + # + # source://net-imap//lib/net/imap/response_parser.rb#1468 + def sort_data; end + + # RFC3501 + # status-att-list = status-att SP number *(SP status-att SP number) + # RFC4466, RFC9051, and RFC3501 Errata + # status-att-list = status-att-val *(SP status-att-val) + # + # source://net-imap//lib/net/imap/response_parser.rb#1545 + def status_att_list; end + + # RFC3501 Errata: + # status-att-val = ("MESSAGES" SP number) / ("RECENT" SP number) / + # ("UIDNEXT" SP nz-number) / ("UIDVALIDITY" SP nz-number) / + # ("UNSEEN" SP number) + # RFC4466: + # status-att-val = ("MESSAGES" SP number) / + # ("RECENT" SP number) / + # ("UIDNEXT" SP nz-number) / + # ("UIDVALIDITY" SP nz-number) / + # ("UNSEEN" SP number) + # ;; Extensions to the STATUS responses + # ;; should extend this production. + # ;; Extensions should use the generic + # ;; syntax defined by tagged-ext. + # RFC9051: + # status-att-val = ("MESSAGES" SP number) / + # ("UIDNEXT" SP nz-number) / + # ("UIDVALIDITY" SP nz-number) / + # ("UNSEEN" SP number) / + # ("DELETED" SP number) / + # ("SIZE" SP number64) + # ; Extensions to the STATUS responses + # ; should extend this production. + # ; Extensions should use the generic + # ; syntax defined by tagged-ext. + # RFC7162: + # status-att-val =/ "HIGHESTMODSEQ" SP mod-sequence-valzer + # ;; Extends non-terminal defined in [RFC4466]. + # ;; Value 0 denotes that the mailbox doesn't + # ;; support persistent mod-sequences + # ;; as described in Section 3.1.2.2. + # RFC7889: + # status-att-val =/ "APPENDLIMIT" SP (number / nil) + # ;; status-att-val is defined in RFC 4466 + # RFC8438: + # status-att-val =/ "SIZE" SP number64 + # RFC8474: + # status-att-val =/ "MAILBOXID" SP "(" objectid ")" + # ; follows tagged-ext production from [RFC4466] + # + # source://net-imap//lib/net/imap/response_parser.rb#1590 + def status_att_val; end + + # source://net-imap//lib/net/imap/response_parser.rb#492 + def tag; end + + # tagged-ext-comp = astring / + # tagged-ext-comp *(SP tagged-ext-comp) / + # "(" tagged-ext-comp ")" + # ; Extensions that follow this general + # ; syntax should use nstring instead of + # ; astring when appropriate in the context + # ; of the extension. + # ; Note that a message set or a "number" + # ; can always be represented as an "atom". + # ; A URL should be represented as + # ; a "quoted" string. + # + # source://net-imap//lib/net/imap/response_parser.rb#574 + def tagged_ext_comp; end + + # tagged-ext-simple is a subset of atom + # TODO: recognize sequence-set in the lexer + # + # tagged-ext-simple = sequence-set / number / number64 + # + # source://net-imap//lib/net/imap/response_parser.rb#591 + def tagged_ext_simple; end + + # tagged-ext-val = tagged-ext-simple / + # "(" [tagged-ext-comp] ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#597 + def tagged_ext_val; end + + # TEXT-CHAR = + # RFC3501: + # text = 1*TEXT-CHAR + # RFC9051: + # text = 1*(TEXT-CHAR / UTF8-2 / UTF8-3 / UTF8-4) + # ; Non-ASCII text can only be returned + # ; after ENABLE IMAP4rev2 command + # + # source://net-imap//lib/net/imap/response_parser.rb#1734 + def text; end + + # an "accept" versiun of #text + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_parser.rb#1739 + def text?; end + + # 1* + # + # source://net-imap//lib/net/imap/response_parser.rb#1845 + def text_chars_except_rbra; end + + # RFC5256: THREAD + # thread-data = "THREAD" [SP 1*thread-list] + # + # source://net-imap//lib/net/imap/response_parser.rb#1484 + def thread_data; end + + # RFC5256: THREAD + # thread-list = "(" (thread-members / thread-nested) ")" + # + # source://net-imap//lib/net/imap/response_parser.rb#1498 + def thread_list; end + + # RFC5256: THREAD + # thread-members = nz-number *(SP nz-number) [SP thread-nested] + # + # source://net-imap//lib/net/imap/response_parser.rb#1511 + def thread_members; end + + # RFC5256: THREAD + # thread-nested = 2*thread-list + # + # source://net-imap//lib/net/imap/response_parser.rb#1527 + def thread_nested; end + + # RFC-4315 (UIDPLUS) or RFC9051 (IMAP4rev2): + # uid-set = (uniqueid / uid-range) *("," uid-set) + # uid-range = (uniqueid ":" uniqueid) + # ; two uniqueid values and all values + # ; between these two regardless of order. + # ; Example: 2:4 and 4:2 are equivalent. + # uniqueid = nz-number + # ; Strictly ascending + # + # source://net-imap//lib/net/imap/response_parser.rb#2004 + def uid_set; end + + # source://net-imap//lib/net/imap/response_parser.rb#751 + def uidfetch_resp(klass = T.unsafe(nil)); end + + # See https://developers.google.com/gmail/imap/imap-extensions + # + # source://net-imap//lib/net/imap/response_parser.rb#1952 + def x_gm_label; end + + # See https://developers.google.com/gmail/imap/imap-extensions + # + # source://net-imap//lib/net/imap/response_parser.rb#1955 + def x_gm_labels; end +end + +# ASTRING-CHAR = ATOM-CHAR / resp-specials +# resp-specials = "]" +# +# source://net-imap//lib/net/imap/response_parser.rb#482 +Net::IMAP::ResponseParser::ASTRING_CHARS_TOKENS = T.let(T.unsafe(nil), Array) + +# source://net-imap//lib/net/imap/response_parser.rb#484 +Net::IMAP::ResponseParser::ASTRING_TOKENS = T.let(T.unsafe(nil), Array) + +# basic utility methods for parsing. +# +# (internal API, subject to change) +# +# source://net-imap//lib/net/imap/response_parser/parser_utils.rb#9 +module Net::IMAP::ResponseParser::ParserUtils + private + + # like match, but does not raise error on failure. + # + # returns and shifts token on successful match + # returns nil and leaves @token unshifted on no match + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#148 + def accept(*args); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#193 + def accept_re(re); end + + # To be used conditionally: + # assert_no_lookahead if config.debug? + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#158 + def assert_no_lookahead; end + + # TODO: after checking the lookahead, use a regexp for remaining chars. + # That way a loop isn't needed. + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#121 + def combine_adjacent(*tokens); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#169 + def lookahead; end + + # like match, without consuming the token + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#174 + def lookahead!(*args); end + + # like accept, without consuming the token + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#165 + def lookahead?(*symbols); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#133 + def match(*args); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#199 + def match_re(re, name); end + + # @raise [ResponseParseError] + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#213 + def parse_error(fmt, *args); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#188 + def peek_re(re); end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#183 + def peek_str?(str); end + + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#209 + def shift_token; end +end + +# source://net-imap//lib/net/imap/response_parser/parser_utils.rb#11 +module Net::IMAP::ResponseParser::ParserUtils::Generator + # we can skip lexer for single character matches, as a shortcut + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#17 + def def_char_matchers(name, char, token); end + + # TODO: move coersion to the token.value method? + # + # source://net-imap//lib/net/imap/response_parser/parser_utils.rb#62 + def def_token_matchers(name, *token_symbols, coerce: T.unsafe(nil), send: T.unsafe(nil)); end +end + +# source://net-imap//lib/net/imap/response_parser/parser_utils.rb#13 +Net::IMAP::ResponseParser::ParserUtils::Generator::LOOKAHEAD = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/response_parser/parser_utils.rb#14 +Net::IMAP::ResponseParser::ParserUtils::Generator::SHIFT_TOKEN = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/response_parser.rb#80 +module Net::IMAP::ResponseParser::Patterns + include ::Net::IMAP::ResponseParser::Patterns::RFC5234 + include ::Net::IMAP::ResponseParser::Patterns::RFC3629 + + private + + # source://net-imap//lib/net/imap/response_parser.rb#355 + def unescape_quoted(quoted); end + + # source://net-imap//lib/net/imap/response_parser.rb#349 + def unescape_quoted!(quoted); end + + class << self + # source://net-imap//lib/net/imap/response_parser.rb#355 + def unescape_quoted(quoted); end + + # source://net-imap//lib/net/imap/response_parser.rb#349 + def unescape_quoted!(quoted); end + end +end + +# source://net-imap//lib/net/imap/response_parser.rb#177 +Net::IMAP::ResponseParser::Patterns::ASTRING_CHAR = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#181 +Net::IMAP::ResponseParser::Patterns::ASTRING_CHARS = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#175 +Net::IMAP::ResponseParser::Patterns::ASTRING_SPECIALS = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#180 +Net::IMAP::ResponseParser::Patterns::ATOM = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#182 +Net::IMAP::ResponseParser::Patterns::ATOMISH = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#178 +Net::IMAP::ResponseParser::Patterns::ATOM_CHAR = T.let(T.unsafe(nil), Regexp) + +# atomish = 1* +# ; We use "atomish" for msg-att and section, in order +# ; to simplify "BODY[HEADER.FIELDS (foo bar)]". +# +# atom-specials = "(" / ")" / "{" / SP / CTL / list-wildcards / +# quoted-specials / resp-specials +# ATOM-CHAR = +# atom = 1*ATOM-CHAR +# ASTRING-CHAR = ATOM-CHAR / resp-specials +# tag = 1* +# +# source://net-imap//lib/net/imap/response_parser.rb#174 +Net::IMAP::ResponseParser::Patterns::ATOM_SPECIALS = T.let(T.unsafe(nil), Regexp) + +# CHAR8 = %x01-ff +# ; any OCTET except NUL, %x00 +# +# source://net-imap//lib/net/imap/response_parser.rb#154 +Net::IMAP::ResponseParser::Patterns::CHAR8 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#190 +Net::IMAP::ResponseParser::Patterns::CODE_TEXT = T.let(T.unsafe(nil), Regexp) + +# resp-text-code = ... / atom [SP 1*] +# +# source://net-imap//lib/net/imap/response_parser.rb#189 +Net::IMAP::ResponseParser::Patterns::CODE_TEXT_CHAR = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#82 +module Net::IMAP::ResponseParser::Patterns::CharClassSubtraction; end + +# flag = "\Answered" / "\Flagged" / "\Deleted" / +# "\Seen" / "\Draft" / flag-keyword / flag-extension +# ; Does not include "\Recent" +# flag-extension = "\" atom +# ; Future expansion. Client implementations +# ; MUST accept flag-extension flags. Server +# ; implementations MUST NOT generate +# ; flag-extension flags except as defined by +# ; a future Standard or Standards Track +# ; revisions of this specification. +# flag-keyword = "$MDNSent" / "$Forwarded" / "$Junk" / +# "$NotJunk" / "$Phishing" / atom +# +# flag-perm = flag / "\*" +# +# Not checking for max one mbx-list-sflag in the parser. +# >>> +# mbx-list-oflag = "\Noinferiors" / child-mbox-flag / +# "\Subscribed" / "\Remote" / flag-extension +# ; Other flags; multiple from this list are +# ; possible per LIST response, but each flag +# ; can only appear once per LIST response +# mbx-list-sflag = "\NonExistent" / "\Noselect" / "\Marked" / +# "\Unmarked" +# ; Selectability flags; only one per LIST response +# child-mbox-flag = "\HasChildren" / "\HasNoChildren" +# ; attributes for the CHILDREN return option, at most +# ; one possible per LIST response +# +# source://net-imap//lib/net/imap/response_parser.rb#220 +Net::IMAP::ResponseParser::Patterns::FLAG = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#221 +Net::IMAP::ResponseParser::Patterns::FLAG_EXTENSION = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#222 +Net::IMAP::ResponseParser::Patterns::FLAG_KEYWORD = T.let(T.unsafe(nil), Regexp) + +# flag-list = "(" [flag *(SP flag)] ")" +# resp-text-code =/ "PERMANENTFLAGS" SP +# "(" [flag-perm *(SP flag-perm)] ")" +# mbx-list-flags = *(mbx-list-oflag SP) mbx-list-sflag +# *(SP mbx-list-oflag) / +# mbx-list-oflag *(SP mbx-list-oflag) +# (Not checking for max one mbx-list-sflag in the parser.) +# +# source://net-imap//lib/net/imap/response_parser.rb#233 +Net::IMAP::ResponseParser::Patterns::FLAG_LIST = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#223 +Net::IMAP::ResponseParser::Patterns::FLAG_PERM = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#234 +Net::IMAP::ResponseParser::Patterns::FLAG_PERM_LIST = T.let(T.unsafe(nil), Regexp) + +# list-wildcards = "%" / "*" +# +# source://net-imap//lib/net/imap/response_parser.rb#157 +Net::IMAP::ResponseParser::Patterns::LIST_WILDCARDS = T.let(T.unsafe(nil), Regexp) + +# RFC3501: +# literal = "{" number "}" CRLF *CHAR8 +# ; Number represents the number of CHAR8s +# RFC9051: +# literal = "{" number64 ["+"] "}" CRLF *CHAR8 +# ; represents the number of CHAR8s. +# ; A non-synchronizing literal is distinguished +# ; from a synchronizing literal by the presence of +# ; "+" before the closing "}". +# ; Non-synchronizing literals are not allowed when +# ; sent from server to the client. +# +# source://net-imap//lib/net/imap/response_parser.rb#335 +Net::IMAP::ResponseParser::Patterns::LITERAL = T.let(T.unsafe(nil), Regexp) + +# RFC3516 (BINARY): +# literal8 = "~{" number "}" CRLF *OCTET +# ; represents the number of OCTETs +# ; in the response string. +# RFC9051: +# literal8 = "~{" number64 "}" CRLF *OCTET +# ; represents the number of OCTETs +# ; in the response string. +# +# source://net-imap//lib/net/imap/response_parser.rb#345 +Net::IMAP::ResponseParser::Patterns::LITERAL8 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#224 +Net::IMAP::ResponseParser::Patterns::MBX_FLAG = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#235 +Net::IMAP::ResponseParser::Patterns::MBX_LIST_FLAGS = T.let(T.unsafe(nil), Regexp) + +# nz-number = digit-nz *DIGIT +# ; Non-zero unsigned 32-bit integer +# ; (0 < n < 4,294,967,296) +# +# source://net-imap//lib/net/imap/response_parser.rb#277 +Net::IMAP::ResponseParser::Patterns::NZ_NUMBER = T.let(T.unsafe(nil), Regexp) + +# Gmail allows SP and "]" in flags....... +# +# source://net-imap//lib/net/imap/response_parser.rb#238 +Net::IMAP::ResponseParser::Patterns::QUIRKY_FLAG = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#239 +Net::IMAP::ResponseParser::Patterns::QUIRKY_FLAGS_LIST = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#250 +Net::IMAP::ResponseParser::Patterns::QUOTED_CHAR_esc = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#251 +Net::IMAP::ResponseParser::Patterns::QUOTED_CHAR_rev1 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#252 +Net::IMAP::ResponseParser::Patterns::QUOTED_CHAR_rev2 = T.let(T.unsafe(nil), Regexp) + +# RFC3501: +# QUOTED-CHAR = / +# "\" quoted-specials +# RFC9051: +# QUOTED-CHAR = / +# "\" quoted-specials / UTF8-2 / UTF8-3 / UTF8-4 +# RFC3501 & RFC9051: +# quoted = DQUOTE *QUOTED-CHAR DQUOTE +# +# source://net-imap//lib/net/imap/response_parser.rb#249 +Net::IMAP::ResponseParser::Patterns::QUOTED_CHAR_safe = T.let(T.unsafe(nil), Regexp) + +# quoted-specials = DQUOTE / "\" +# +# source://net-imap//lib/net/imap/response_parser.rb#159 +Net::IMAP::ResponseParser::Patterns::QUOTED_SPECIALS = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#254 +Net::IMAP::ResponseParser::Patterns::QUOTED_rev1 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#255 +Net::IMAP::ResponseParser::Patterns::QUOTED_rev2 = T.let(T.unsafe(nil), Regexp) + +# resp-specials = "]" +# +# source://net-imap//lib/net/imap/response_parser.rb#161 +Net::IMAP::ResponseParser::Patterns::RESP_SPECIALS = T.let(T.unsafe(nil), Regexp) + +# UTF-8, a transformation format of ISO 10646 +# >>> +# UTF8-1 = %x00-7F +# UTF8-tail = %x80-BF +# UTF8-2 = %xC2-DF UTF8-tail +# UTF8-3 = %xE0 %xA0-BF UTF8-tail / %xE1-EC 2( UTF8-tail ) / +# %xED %x80-9F UTF8-tail / %xEE-EF 2( UTF8-tail ) +# UTF8-4 = %xF0 %x90-BF 2( UTF8-tail ) / %xF1-F3 3( UTF8-tail ) / +# %xF4 %x80-8F 2( UTF8-tail ) +# UTF8-char = UTF8-1 / UTF8-2 / UTF8-3 / UTF8-4 +# UTF8-octets = *( UTF8-char ) +# +# n.b. String * Integer is used for repetition, rather than /x{3}/, +# because ruby 3.2's linear-time cache-based optimization doesn't work +# with "bounded or fixed times repetition nesting in another repetition +# (e.g. /(a{2,3})*/). It is an implementation issue entirely, but we +# believe it is hard to support this case correctly." +# See https://bugs.ruby-lang.org/issues/19104 +# +# source://net-imap//lib/net/imap/response_parser.rb#134 +module Net::IMAP::ResponseParser::Patterns::RFC3629; end + +# aka ASCII 7bit +# +# source://net-imap//lib/net/imap/response_parser.rb#135 +Net::IMAP::ResponseParser::Patterns::RFC3629::UTF8_1 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#137 +Net::IMAP::ResponseParser::Patterns::RFC3629::UTF8_2 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#138 +Net::IMAP::ResponseParser::Patterns::RFC3629::UTF8_3 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#142 +Net::IMAP::ResponseParser::Patterns::RFC3629::UTF8_4 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#145 +Net::IMAP::ResponseParser::Patterns::RFC3629::UTF8_CHAR = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#146 +Net::IMAP::ResponseParser::Patterns::RFC3629::UTF8_OCTETS = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#136 +Net::IMAP::ResponseParser::Patterns::RFC3629::UTF8_TAIL = T.let(T.unsafe(nil), Regexp) + +# From RFC5234, "Augmented BNF for Syntax Specifications: ABNF" +# >>> +# ALPHA = %x41-5A / %x61-7A ; A-Z / a-z +# CHAR = %x01-7F +# CRLF = CR LF +# ; Internet standard newline +# CTL = %x00-1F / %x7F +# ; controls +# DIGIT = %x30-39 +# ; 0-9 +# DQUOTE = %x22 +# ; " (Double Quote) +# HEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F" +# OCTET = %x00-FF +# SP = %x20 +# +# source://net-imap//lib/net/imap/response_parser.rb#104 +module Net::IMAP::ResponseParser::Patterns::RFC5234; end + +# source://net-imap//lib/net/imap/response_parser.rb#105 +Net::IMAP::ResponseParser::Patterns::RFC5234::ALPHA = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#106 +Net::IMAP::ResponseParser::Patterns::RFC5234::CHAR = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#107 +Net::IMAP::ResponseParser::Patterns::RFC5234::CRLF = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#108 +Net::IMAP::ResponseParser::Patterns::RFC5234::CTL = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#109 +Net::IMAP::ResponseParser::Patterns::RFC5234::DIGIT = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#110 +Net::IMAP::ResponseParser::Patterns::RFC5234::DQUOTE = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#111 +Net::IMAP::ResponseParser::Patterns::RFC5234::HEXDIG = T.let(T.unsafe(nil), Regexp) + +# not using /./m for embedding purposes +# +# source://net-imap//lib/net/imap/response_parser.rb#112 +Net::IMAP::ResponseParser::Patterns::RFC5234::OCTET = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#113 +Net::IMAP::ResponseParser::Patterns::RFC5234::SP = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#321 +Net::IMAP::ResponseParser::Patterns::SEQUENCE_SET = T.let(T.unsafe(nil), Regexp) + +# sequence-set = (seq-number / seq-range) ["," sequence-set] +# ; set of seq-number values, regardless of order. +# ; Servers MAY coalesce overlaps and/or execute +# ; the sequence in any order. +# ; Example: a message sequence number set of +# ; 2,4:7,9,12:* for a mailbox with 15 messages is +# ; equivalent to 2,4,5,6,7,9,12,13,14,15 +# ; Example: a message sequence number set of +# ; *:4,5:7 for a mailbox with 10 messages is +# ; equivalent to 10,9,8,7,6,5,4,5,6,7 and MAY +# ; be reordered and overlap coalesced to be +# ; 4,5,6,7,8,9,10. +# +# source://net-imap//lib/net/imap/response_parser.rb#320 +Net::IMAP::ResponseParser::Patterns::SEQUENCE_SET_ITEM = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#322 +Net::IMAP::ResponseParser::Patterns::SEQUENCE_SET_STR = T.let(T.unsafe(nil), Regexp) + +# seq-number = nz-number / "*" +# ; message sequence number (COPY, FETCH, STORE +# ; commands) or unique identifier (UID COPY, +# ; UID FETCH, UID STORE commands). +# ; * represents the largest number in use. In +# ; the case of message sequence numbers, it is +# ; the number of messages in a non-empty mailbox. +# ; In the case of unique identifiers, it is the +# ; unique identifier of the last message in the +# ; mailbox or, if the mailbox is empty, the +# ; mailbox's current UIDNEXT value. +# ; The server should respond with a tagged BAD +# ; response to a command that uses a message +# ; sequence number greater than the number of +# ; messages in the selected mailbox. This +# ; includes "*" if the selected mailbox is empty. +# +# source://net-imap//lib/net/imap/response_parser.rb#295 +Net::IMAP::ResponseParser::Patterns::SEQ_NUMBER = T.let(T.unsafe(nil), Regexp) + +# seq-range = seq-number ":" seq-number +# ; two seq-number values and all values between +# ; these two regardless of order. +# ; Example: 2:4 and 4:2 are equivalent and +# ; indicate values 2, 3, and 4. +# ; Example: a unique identifier sequence range of +# ; 3291:* includes the UID of the last message in +# ; the mailbox, even if that value is less than +# ; 3291. +# +# source://net-imap//lib/net/imap/response_parser.rb#306 +Net::IMAP::ResponseParser::Patterns::SEQ_RANGE = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#183 +Net::IMAP::ResponseParser::Patterns::TAG = T.let(T.unsafe(nil), Regexp) + +# tagged-ext-label = tagged-label-fchar *tagged-label-char +# ; Is a valid RFC 3501 "atom". +# +# source://net-imap//lib/net/imap/response_parser.rb#272 +Net::IMAP::ResponseParser::Patterns::TAGGED_EXT_LABEL = T.let(T.unsafe(nil), Regexp) + +# tagged-label-char = tagged-label-fchar / DIGIT / ":" +# +# source://net-imap//lib/net/imap/response_parser.rb#269 +Net::IMAP::ResponseParser::Patterns::TAGGED_LABEL_CHAR = T.let(T.unsafe(nil), Regexp) + +# tagged-label-fchar = ALPHA / "-" / "_" / "." +# +# source://net-imap//lib/net/imap/response_parser.rb#267 +Net::IMAP::ResponseParser::Patterns::TAGGED_LABEL_FCHAR = T.let(T.unsafe(nil), Regexp) + +# TEXT-CHAR = +# +# source://net-imap//lib/net/imap/response_parser.rb#186 +Net::IMAP::ResponseParser::Patterns::TEXT_CHAR = T.let(T.unsafe(nil), Regexp) + +# RFC3501: +# text = 1*TEXT-CHAR +# RFC9051: +# text = 1*(TEXT-CHAR / UTF8-2 / UTF8-3 / UTF8-4) +# ; Non-ASCII text can only be returned +# ; after ENABLE IMAP4rev2 command +# +# source://net-imap//lib/net/imap/response_parser.rb#263 +Net::IMAP::ResponseParser::Patterns::TEXT_rev1 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#264 +Net::IMAP::ResponseParser::Patterns::TEXT_rev2 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/response_parser.rb#681 +Net::IMAP::ResponseParser::RE_RESPONSE_TYPE = T.let(T.unsafe(nil), Regexp) + +# end of response string +# +# source://net-imap//lib/net/imap/response_parser.rb#65 +module Net::IMAP::ResponseParser::ResponseConditions; end + +# source://net-imap//lib/net/imap/response_parser.rb#74 +Net::IMAP::ResponseParser::ResponseConditions::AUTH_CONDS = T.let(T.unsafe(nil), Array) + +# source://net-imap//lib/net/imap/response_parser.rb#68 +Net::IMAP::ResponseParser::ResponseConditions::BAD = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/response_parser.rb#69 +Net::IMAP::ResponseParser::ResponseConditions::BYE = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/response_parser.rb#75 +Net::IMAP::ResponseParser::ResponseConditions::GREETING_CONDS = T.let(T.unsafe(nil), Array) + +# source://net-imap//lib/net/imap/response_parser.rb#67 +Net::IMAP::ResponseParser::ResponseConditions::NO = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/response_parser.rb#66 +Net::IMAP::ResponseParser::ResponseConditions::OK = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/response_parser.rb#70 +Net::IMAP::ResponseParser::ResponseConditions::PREAUTH = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/response_parser.rb#76 +Net::IMAP::ResponseParser::ResponseConditions::RESP_CONDS = T.let(T.unsafe(nil), Array) + +# source://net-imap//lib/net/imap/response_parser.rb#72 +Net::IMAP::ResponseParser::ResponseConditions::RESP_COND_STATES = T.let(T.unsafe(nil), Array) + +# source://net-imap//lib/net/imap/response_parser.rb#73 +Net::IMAP::ResponseParser::ResponseConditions::RESP_DATA_CONDS = T.let(T.unsafe(nil), Array) + +# source://net-imap//lib/net/imap/response_parser.rb#462 +Net::IMAP::ResponseParser::SEQUENCE_SET_TOKENS = T.let(T.unsafe(nil), Array) + +# source://net-imap//lib/net/imap/response_parser.rb#2021 +Net::IMAP::ResponseParser::SPACES_REGEXP = T.let(T.unsafe(nil), Regexp) + +# tag = 1* +# +# source://net-imap//lib/net/imap/response_parser.rb#487 +Net::IMAP::ResponseParser::TAG_TOKENS = T.let(T.unsafe(nil), Array) + +# starts with atom special +# +# source://net-imap//lib/net/imap/response_parser.rb#60 +Net::IMAP::ResponseParser::T_LITERAL8 = T.let(T.unsafe(nil), Symbol) + +# Used to avoid an allocation when ResponseText is empty +# +# source://net-imap//lib/net/imap/response_data.rb#169 +Net::IMAP::ResponseText::EMPTY = T.let(T.unsafe(nil), Net::IMAP::ResponseText) + +# Pluggable authentication mechanisms for protocols which support SASL +# (Simple Authentication and Security Layer), such as IMAP4, SMTP, LDAP, and +# XMPP. {RFC-4422}[https://tools.ietf.org/html/rfc4422] specifies the +# common \SASL framework: +# >>> +# SASL is conceptually a framework that provides an abstraction layer +# between protocols and mechanisms as illustrated in the following +# diagram. +# +# SMTP LDAP XMPP Other protocols ... +# \ | | / +# \ | | / +# SASL abstraction layer +# / | | \ +# / | | \ +# EXTERNAL GSSAPI PLAIN Other mechanisms ... +# +# Net::IMAP uses SASL via the Net::IMAP#authenticate method. +# +# == Mechanisms +# +# Each mechanism has different properties and requirements. Please consult +# the documentation for the specific mechanisms you are using: +# +# +ANONYMOUS+:: +# See AnonymousAuthenticator. +# +# Allows the user to gain access to public services or resources without +# authenticating or disclosing an identity. +# +# +EXTERNAL+:: +# See ExternalAuthenticator. +# +# Authenticates using already established credentials, such as a TLS +# certificate or IPSec. +# +# +OAUTHBEARER+:: +# See OAuthBearerAuthenticator. +# +# Login using an OAuth2 Bearer token. This is the standard mechanism +# for using OAuth2 with \SASL, but it is not yet deployed as widely as +# +XOAUTH2+. +# +# +PLAIN+:: +# See PlainAuthenticator. +# +# Login using clear-text username and password. +# +# +SCRAM-SHA-1+:: +# +SCRAM-SHA-256+:: +# See ScramAuthenticator. +# +# Login by username and password. The password is not sent to the +# server but is used in a salted challenge/response exchange. +# +SCRAM-SHA-1+ and +SCRAM-SHA-256+ are directly supported by +# Net::IMAP::SASL. New authenticators can easily be added for any other +# SCRAM-* mechanism if the digest algorithm is supported by +# OpenSSL::Digest. +# +# +XOAUTH2+:: +# See XOAuth2Authenticator. +# +# Login using a username and an OAuth2 access token. Non-standard and +# obsoleted by +OAUTHBEARER+, but widely supported. +# +# See the {SASL mechanism +# registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] +# for a list of all SASL mechanisms and their specifications. To register +# new authenticators, see Authenticators. +# +# === Deprecated mechanisms +# +# Obsolete mechanisms should be avoided, but are still available for +# backwards compatibility. +# +# >>> +# For +DIGEST-MD5+ see DigestMD5Authenticator. +# +# For +LOGIN+, see LoginAuthenticator. +# +# For +CRAM-MD5+, see CramMD5Authenticator. +# +# Using a deprecated mechanism will print a warning. +# +# source://net-imap//lib/net/imap/sasl.rb#90 +module Net::IMAP::SASL + private + + # See Net::IMAP::StringPrep::SASLprep#saslprep. + # + # source://net-imap//lib/net/imap/sasl.rb#173 + def saslprep(string, **opts); end + + class << self + # Delegates to ::authenticators. See Authenticators#add_authenticator. + # + # source://net-imap//lib/net/imap/sasl.rb#168 + def add_authenticator(*_arg0, **_arg1, &_arg2); end + + # Delegates to registry.new See Authenticators#new. + # + # source://net-imap//lib/net/imap/sasl.rb#163 + def authenticator(*args, registry: T.unsafe(nil), **kwargs, &block); end + + # Returns the default global SASL::Authenticators instance. + # + # source://net-imap//lib/net/imap/sasl.rb#160 + def authenticators; end + + # See Net::IMAP::StringPrep::SASLprep#saslprep. + # + # source://net-imap//lib/net/imap/sasl.rb#173 + def saslprep(string, **opts); end + end +end + +# Authenticator for the "+ANONYMOUS+" SASL mechanism, as specified by +# RFC-4505[https://tools.ietf.org/html/rfc4505]. See +# Net::IMAP#authenticate. +# +# source://net-imap//lib/net/imap/sasl/anonymous_authenticator.rb#10 +class Net::IMAP::SASL::AnonymousAuthenticator + # :call-seq: + # new(anonymous_message = "", **) -> authenticator + # new(anonymous_message: "", **) -> authenticator + # + # Creates an Authenticator for the "+ANONYMOUS+" SASL mechanism, as + # specified in RFC-4505[https://tools.ietf.org/html/rfc4505]. To use + # this, see Net::IMAP#authenticate or your client's authentication + # method. + # + # ==== Parameters + # + # * _optional_ #anonymous_message — a message to send to the server. + # + # Any other keyword arguments are silently ignored. + # + # @return [AnonymousAuthenticator] a new instance of AnonymousAuthenticator + # + # source://net-imap//lib/net/imap/sasl/anonymous_authenticator.rb#37 + def initialize(anon_msg = T.unsafe(nil), anonymous_message: T.unsafe(nil), **_arg2); end + + # An optional token sent for the +ANONYMOUS+ mechanism., up to 255 UTF-8 + # characters in length. + # + # If it contains an "@" sign, the message must be a valid email address + # (+addr-spec+ from RFC-2822[https://tools.ietf.org/html/rfc2822]). + # Email syntax is _not_ validated by AnonymousAuthenticator. + # + # Otherwise, it can be any UTF8 string which is permitted by the + # StringPrep::Trace profile. + # + # source://net-imap//lib/net/imap/sasl/anonymous_authenticator.rb#21 + def anonymous_message; end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/anonymous_authenticator.rb#64 + def done?; end + + # :call-seq: + # initial_response? -> true + # + # +ANONYMOUS+ can send an initial client response. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/anonymous_authenticator.rb#51 + def initial_response?; end + + # Returns #anonymous_message. + # + # source://net-imap//lib/net/imap/sasl/anonymous_authenticator.rb#54 + def process(_server_challenge_string); end +end + +# Indicates an authentication exchange that will be or has been canceled +# by the client, not due to any error or failure during processing. +# +# source://net-imap//lib/net/imap/sasl.rb#106 +class Net::IMAP::SASL::AuthenticationCanceled < ::Net::IMAP::SASL::Error; end + +# Indicates an error when processing a server challenge, e.g: an invalid +# or unparsable challenge. An underlying exception may be available as +# the exception's #cause. +# +# source://net-imap//lib/net/imap/sasl.rb#111 +class Net::IMAP::SASL::AuthenticationError < ::Net::IMAP::SASL::Error; end + +# This API is *experimental*, and may change. +# +# TODO: catch exceptions in #process and send #cancel_response. +# TODO: raise an error if the command succeeds after being canceled. +# TODO: use with more clients, to verify the API can accommodate them. +# +# Create an AuthenticationExchange from a client adapter and a mechanism +# authenticator: +# def authenticate(mechanism, ...) +# authenticator = SASL.authenticator(mechanism, ...) +# SASL::AuthenticationExchange.new( +# sasl_adapter, mechanism, authenticator +# ).authenticate +# end +# +# private +# +# def sasl_adapter = MyClientAdapter.new(self, &method(:send_command)) +# +# Or delegate creation of the authenticator to ::build: +# def authenticate(...) +# SASL::AuthenticationExchange.build(sasl_adapter, ...) +# .authenticate +# end +# +# As a convenience, ::authenticate combines ::build and #authenticate: +# def authenticate(...) +# SASL::AuthenticationExchange.authenticate(sasl_adapter, ...) +# end +# +# Likewise, ClientAdapter#authenticate delegates to #authenticate: +# def authenticate(...) = sasl_adapter.authenticate(...) +# +# source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#40 +class Net::IMAP::SASL::AuthenticationExchange + # @return [AuthenticationExchange] a new instance of AuthenticationExchange + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#52 + def initialize(client, mechanism, authenticator, sasl_ir: T.unsafe(nil)); end + + # Call #authenticate to execute an authentication exchange for #client + # using #authenticator. Authentication failures will raise an + # exception. Any exceptions other than those in RESPONSE_ERRORS will + # drop the connection. + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#64 + def authenticate; end + + # Returns the value of attribute authenticator. + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#50 + def authenticator; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#85 + def done?; end + + # Returns the value of attribute mechanism. + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#50 + def mechanism; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#77 + def send_initial_response?; end + + private + + # Returns the value of attribute client. + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#91 + def client; end + + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#93 + def initial_response; end + + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#98 + def process(challenge); end + + class << self + # Convenience method for build(...).authenticate + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#42 + def authenticate(*_arg0, **_arg1, &_arg2); end + + # Use +registry+ to override the global Authenticators registry. + # + # source://net-imap//lib/net/imap/sasl/authentication_exchange.rb#45 + def build(client, mechanism, *args, sasl_ir: T.unsafe(nil), **kwargs, &block); end + end +end + +# Indicates that authentication cannot proceed because one of the server's +# messages has not passed integrity checks. +# +# source://net-imap//lib/net/imap/sasl.rb#115 +class Net::IMAP::SASL::AuthenticationFailed < ::Net::IMAP::SASL::Error; end + +# Indicates that authentication cannot proceed because one of the server's +# ended authentication prematurely. +# +# source://net-imap//lib/net/imap/sasl.rb#119 +class Net::IMAP::SASL::AuthenticationIncomplete < ::Net::IMAP::SASL::AuthenticationFailed + # @return [AuthenticationIncomplete] a new instance of AuthenticationIncomplete + # + # source://net-imap//lib/net/imap/sasl.rb#123 + def initialize(response, message = T.unsafe(nil)); end + + # The success response from the server + # + # source://net-imap//lib/net/imap/sasl.rb#121 + def response; end +end + +# Registry for SASL authenticators +# +# Registered authenticators must respond to +#new+ or +#call+ (e.g. a class or +# a proc), receiving any credentials and options and returning an +# authenticator instance. The returned object represents a single +# authentication exchange and must not be reused for multiple +# authentication attempts. +# +# An authenticator instance object must respond to +#process+, receiving the +# server's challenge and returning the client's response. Optionally, it may +# also respond to +#initial_response?+ and +#done?+. When +# +#initial_response?+ returns +true+, +#process+ may be called the first +# time with +nil+. When +#done?+ returns +false+, the exchange is incomplete +# and an exception should be raised if the exchange terminates prematurely. +# +# See the source for PlainAuthenticator, XOAuth2Authenticator, and +# ScramSHA1Authenticator for examples. +# +# source://net-imap//lib/net/imap/sasl/authenticators.rb#22 +class Net::IMAP::SASL::Authenticators + # Create a new Authenticators registry. + # + # This class is usually not instantiated directly. Use SASL.authenticators + # to reuse the default global registry. + # + # When +use_defaults+ is +false+, the registry will start empty. When + # +use_deprecated+ is +false+, deprecated authenticators will not be + # included with the defaults. + # + # @return [Authenticators] a new instance of Authenticators + # + # source://net-imap//lib/net/imap/sasl/authenticators.rb#32 + def initialize(use_defaults: T.unsafe(nil), use_deprecated: T.unsafe(nil)); end + + # :call-seq: + # add_authenticator(mechanism) + # add_authenticator(mechanism, authenticator_class) + # add_authenticator(mechanism, authenticator_proc) + # + # Registers an authenticator for #authenticator to use. +mechanism+ is the + # name of the + # {SASL mechanism}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] + # implemented by +authenticator_class+ (for instance, "PLAIN"). + # + # If +mechanism+ refers to an existing authenticator, + # the old authenticator will be replaced. + # + # When only a single argument is given, the authenticator class will be + # lazily loaded from Net::IMAP::SASL::#{name}Authenticator (case is + # preserved and non-alphanumeric characters are removed.. + # + # source://net-imap//lib/net/imap/sasl/authenticators.rb#67 + def add_authenticator(name, authenticator = T.unsafe(nil)); end + + # :call-seq: + # authenticator(mechanism, ...) -> auth_session + # + # Builds an authenticator instance using the authenticator registered to + # +mechanism+. The returned object represents a single authentication + # exchange and must not be reused for multiple authentication + # attempts. + # + # All arguments (except +mechanism+) are forwarded to the registered + # authenticator's +#new+ or +#call+ method. Each authenticator must + # document its own arguments. + # + # [Note] + # This method is intended for internal use by connection protocol code + # only. Protocol client users should see refer to their client's + # documentation, e.g. Net::IMAP#authenticate. + # + # source://net-imap//lib/net/imap/sasl/authenticators.rb#107 + def authenticator(mechanism, *_arg1, **_arg2, &_arg3); end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/authenticators.rb#86 + def mechanism?(name); end + + # Returns the names of all registered SASL mechanisms. + # + # source://net-imap//lib/net/imap/sasl/authenticators.rb#49 + def names; end + + # :call-seq: + # authenticator(mechanism, ...) -> auth_session + # + # Builds an authenticator instance using the authenticator registered to + # +mechanism+. The returned object represents a single authentication + # exchange and must not be reused for multiple authentication + # attempts. + # + # All arguments (except +mechanism+) are forwarded to the registered + # authenticator's +#new+ or +#call+ method. Each authenticator must + # document its own arguments. + # + # [Note] + # This method is intended for internal use by connection protocol code + # only. Protocol client users should see refer to their client's + # documentation, e.g. Net::IMAP#authenticate. + # + # source://net-imap//lib/net/imap/sasl/authenticators.rb#107 + def new(mechanism, *_arg1, **_arg2, &_arg3); end + + # Removes the authenticator registered for +name+ + # + # source://net-imap//lib/net/imap/sasl/authenticators.rb#81 + def remove_authenticator(name); end +end + +# source://net-imap//lib/net/imap/sasl/stringprep.rb#8 +Net::IMAP::SASL::BidiStringError = Net::IMAP::StringPrep::BidiStringError + +# This API is *experimental*, and may change. +# +# TODO: use with more clients, to verify the API can accommodate them. +# +# An abstract base class for implementing a SASL authentication exchange. +# Different clients will each have their own adapter subclass, overridden +# to match their needs. +# +# Although the default implementations _may_ be sufficient, subclasses +# will probably need to override some methods. Additionally, subclasses +# may need to include a protocol adapter mixin, if the default +# ProtocolAdapters::Generic isn't sufficient. +# +# source://net-imap//lib/net/imap/sasl/client_adapter.rb#19 +class Net::IMAP::SASL::ClientAdapter + include ::Net::IMAP::SASL::ProtocolAdapters::Generic + + # +command_proc+ can used to avoid exposing private methods on #client. + # It should run a command with the arguments sent to it, yield each + # continuation payload, respond to the server with the result of each + # yield, and return the result. Non-successful results *MUST* raise an + # exception. Exceptions in the block *MUST* cause the command to fail. + # + # Subclasses that override #run_command may use #command_proc for + # other purposes. + # + # @return [ClientAdapter] a new instance of ClientAdapter + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#32 + def initialize(client, &command_proc); end + + # Does the server advertise support for the mechanism? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#43 + def auth_capable?(mechanism); end + + # Delegates to AuthenticationExchange.authenticate. + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#37 + def authenticate(*_arg0, **_arg1, &_arg2); end + + # Returns the value of attribute client. + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#22 + def client; end + + # Returns the value of attribute command_proc. + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#22 + def command_proc; end + + # Drop the connection gracefully. + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#65 + def drop_connection; end + + # Drop the connection abruptly. + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#68 + def drop_connection!; end + + # Returns an array of server responses errors raised by run_command. + # Exceptions in this array won't drop the connection. + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#62 + def response_errors; end + + # Runs the authenticate command with +mechanism+ and +initial_response+. + # When +initial_response+ is nil, an initial response must NOT be sent. + # + # Yields each continuation payload, responds to the server with the + # result of each yield, and returns the result. Non-successful results + # *MUST* raise an exception. Exceptions in the block *MUST* cause the + # command to fail. + # + # Subclasses that override this may use #command_proc differently. + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#54 + def run_command(mechanism, initial_response = T.unsafe(nil), &block); end + + # Do the protocol and server both support an initial response? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/client_adapter.rb#40 + def sasl_ir_capable?; end +end + +# Authenticator for the "+CRAM-MD5+" SASL mechanism, specified in +# RFC2195[https://tools.ietf.org/html/rfc2195]. See Net::IMAP#authenticate. +# +# == Deprecated +# +# +CRAM-MD5+ is obsolete and insecure. It is included for compatibility with +# existing servers. +# {draft-ietf-sasl-crammd5-to-historic}[https://tools.ietf.org/html/draft-ietf-sasl-crammd5-to-historic-00.html] +# recommends using +SCRAM-*+ or +PLAIN+ protected by TLS instead. +# +# Additionally, RFC8314[https://tools.ietf.org/html/rfc8314] discourage the use +# of cleartext and recommends TLS version 1.2 or greater be used for all +# traffic. With TLS +CRAM-MD5+ is okay, but so is +PLAIN+ +# +# source://net-imap//lib/net/imap/sasl/cram_md5_authenticator.rb#16 +class Net::IMAP::SASL::CramMD5Authenticator + # @return [CramMD5Authenticator] a new instance of CramMD5Authenticator + # + # source://net-imap//lib/net/imap/sasl/cram_md5_authenticator.rb#17 + def initialize(user = T.unsafe(nil), pass = T.unsafe(nil), authcid: T.unsafe(nil), username: T.unsafe(nil), password: T.unsafe(nil), secret: T.unsafe(nil), warn_deprecation: T.unsafe(nil), **_arg7); end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/cram_md5_authenticator.rb#40 + def done?; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/cram_md5_authenticator.rb#31 + def initial_response?; end + + # source://net-imap//lib/net/imap/sasl/cram_md5_authenticator.rb#33 + def process(challenge); end + + private + + # source://net-imap//lib/net/imap/sasl/cram_md5_authenticator.rb#44 + def hmac_md5(text, key); end +end + +# Net::IMAP authenticator for the "`DIGEST-MD5`" SASL mechanism type, specified +# in RFC-2831[https://tools.ietf.org/html/rfc2831]. See Net::IMAP#authenticate. +# +# == Deprecated +# +# "+DIGEST-MD5+" has been deprecated by +# RFC-6331[https://tools.ietf.org/html/rfc6331] and should not be relied on for +# security. It is included for compatibility with existing servers. +# +# source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#11 +class Net::IMAP::SASL::DigestMD5Authenticator + # :call-seq: + # new(username, password, authzid = nil, **options) -> authenticator + # new(username:, password:, authzid: nil, **options) -> authenticator + # new(authcid:, password:, authzid: nil, **options) -> authenticator + # + # Creates an Authenticator for the "+DIGEST-MD5+" SASL mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # ==== Parameters + # + # * #authcid ― Authentication identity that is associated with #password. + # + # #username ― An alias for +authcid+. + # + # * #password ― A password or passphrase associated with this #authcid. + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # When +authzid+ is not set, the server should derive the authorization + # identity from the authentication identity. + # + # * _optional_ +warn_deprecation+ — Set to +false+ to silence the warning. + # + # Any other keyword arguments are silently ignored. + # + # @return [DigestMD5Authenticator] a new instance of DigestMD5Authenticator + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#70 + def initialize(user = T.unsafe(nil), pass = T.unsafe(nil), authz = T.unsafe(nil), username: T.unsafe(nil), password: T.unsafe(nil), authzid: T.unsafe(nil), authcid: T.unsafe(nil), secret: T.unsafe(nil), warn_deprecation: T.unsafe(nil), **_arg9); end + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#24 + def authcid; end + + # Authorization identity: an identity to act as or on behalf of. The identity + # form is application protocol specific. If not provided or left blank, the + # server derives an authorization identity from the authentication identity. + # The server is responsible for verifying the client's credentials and + # verifying that the identity it associates with the client's authentication + # identity is allowed to act as (or on behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "DIGEST-MD5", "root", ->{passwd}, authzid: "user" + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#43 + def authzid; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#156 + def done?; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#88 + def initial_response?; end + + # A password or passphrase that matches the #username. + # + # The +password+ will be used to create the response digest. + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#30 + def password; end + + # Responds to server challenge in two stages. + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#91 + def process(challenge); end + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#24 + def username; end + + private + + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#160 + def nc(nonce); end + + # some responses need quoting + # + # source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#170 + def qdval(k, v); end +end + +# source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#14 +Net::IMAP::SASL::DigestMD5Authenticator::STAGE_DONE = T.let(T.unsafe(nil), Symbol) + +# source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#12 +Net::IMAP::SASL::DigestMD5Authenticator::STAGE_ONE = T.let(T.unsafe(nil), Symbol) + +# source://net-imap//lib/net/imap/sasl/digest_md5_authenticator.rb#13 +Net::IMAP::SASL::DigestMD5Authenticator::STAGE_TWO = T.let(T.unsafe(nil), Symbol) + +# Exception class for any client error detected during the authentication +# exchange. +# +# When the _server_ reports an authentication failure, it will respond +# with a protocol specific error instead, e.g: +BAD+ or +NO+ in IMAP. +# +# When the client encounters any error, it *must* consider the +# authentication exchange to be unsuccessful and it might need to drop the +# connection. For example, if the server reports that the authentication +# exchange was successful or the protocol does not allow additional +# authentication attempts. +# +# source://net-imap//lib/net/imap/sasl.rb#102 +class Net::IMAP::SASL::Error < ::StandardError; end + +# Authenticator for the "+EXTERNAL+" SASL mechanism, as specified by +# RFC-4422[https://tools.ietf.org/html/rfc4422]. See +# Net::IMAP#authenticate. +# +# The EXTERNAL mechanism requests that the server use client credentials +# established external to SASL, for example by TLS certificate or IPSec. +# +# source://net-imap//lib/net/imap/sasl/external_authenticator.rb#13 +class Net::IMAP::SASL::ExternalAuthenticator + # :call-seq: + # new(authzid: nil, **) -> authenticator + # new(username: nil, **) -> authenticator + # new(username = nil, **) -> authenticator + # + # Creates an Authenticator for the "+EXTERNAL+" SASL mechanism, as + # specified in RFC-4422[https://tools.ietf.org/html/rfc4422]. To use + # this, see Net::IMAP#authenticate or your client's authentication + # method. + # + # ==== Parameters + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # _optional_ #username ― An alias for #authzid. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authentication identity is established for the client by the + # external credentials. + # + # Any other keyword parameters are quietly ignored. + # + # @return [ExternalAuthenticator] a new instance of ExternalAuthenticator + # + # source://net-imap//lib/net/imap/sasl/external_authenticator.rb#52 + def initialize(user = T.unsafe(nil), authzid: T.unsafe(nil), username: T.unsafe(nil), **_arg3); end + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. The server is responsible for verifying the + # client's credentials and verifying that the identity it associates + # with the client's authentication identity is allowed to act as (or on + # behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + # source://net-imap//lib/net/imap/sasl/external_authenticator.rb#27 + def authzid; end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/external_authenticator.rb#78 + def done?; end + + # :call-seq: + # initial_response? -> true + # + # +EXTERNAL+ can send an initial client response. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/external_authenticator.rb#65 + def initial_response?; end + + # Returns #authzid, or an empty string if there is no authzid. + # + # source://net-imap//lib/net/imap/sasl/external_authenticator.rb#68 + def process(_); end + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. The server is responsible for verifying the + # client's credentials and verifying that the identity it associates + # with the client's authentication identity is allowed to act as (or on + # behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + # source://net-imap//lib/net/imap/sasl/external_authenticator.rb#27 + def username; end +end + +# Originally defined for the GS2 mechanism family in +# RFC5801[https://tools.ietf.org/html/rfc5801], +# several different mechanisms start with a GS2 header: +# * +GS2-*+ --- RFC5801[https://tools.ietf.org/html/rfc5801] +# * +SCRAM-*+ --- RFC5802[https://tools.ietf.org/html/rfc5802] +# (ScramAuthenticator) +# * +SAML20+ --- RFC6595[https://tools.ietf.org/html/rfc6595] +# * +OPENID20+ --- RFC6616[https://tools.ietf.org/html/rfc6616] +# * +OAUTH10A+ --- RFC7628[https://tools.ietf.org/html/rfc7628] +# * +OAUTHBEARER+ --- RFC7628[https://tools.ietf.org/html/rfc7628] +# (OAuthBearerAuthenticator) +# +# Classes that include this module must implement +#authzid+. +# +# source://net-imap//lib/net/imap/sasl/gs2_header.rb#20 +module Net::IMAP::SASL::GS2Header + # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] + # +gs2-authzid+ header, when +#authzid+ is not empty. + # + # If +#authzid+ is empty or +nil+, an empty string is returned. + # + # source://net-imap//lib/net/imap/sasl/gs2_header.rb#59 + def gs2_authzid; end + + # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] + # +gs2-cb-flag+: + # + # "+n+":: The client doesn't support channel binding. + # "+y+":: The client does support channel binding + # but thinks the server does not. + # "+p+":: The client requires channel binding. + # The selected channel binding follows "+p=+". + # + # The default always returns "+n+". A mechanism that supports channel + # binding must override this method. + # + # source://net-imap//lib/net/imap/sasl/gs2_header.rb#53 + def gs2_cb_flag; end + + # The {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] + # +gs2-header+, which prefixes the #initial_client_response. + # + # >>> + # Note: the actual GS2 header includes an optional flag to + # indicate that the GSS mechanism is not "standard", but since all of + # the SASL mechanisms using GS2 are "standard", we don't include that + # flag. A class for a nonstandard GSSAPI mechanism should prefix with + # "+F,+". + # + # source://net-imap//lib/net/imap/sasl/gs2_header.rb#37 + def gs2_header; end + + private + + # Encodes +str+ to match RFC5801_SASLNAME. + # + # source://net-imap//lib/net/imap/sasl/gs2_header.rb#67 + def gs2_saslname_encode(str); end + + class << self + # Encodes +str+ to match RFC5801_SASLNAME. + # + # source://net-imap//lib/net/imap/sasl/gs2_header.rb#67 + def gs2_saslname_encode(str); end + end +end + +# source://net-imap//lib/net/imap/sasl/gs2_header.rb#21 +Net::IMAP::SASL::GS2Header::NO_NULL_CHARS = T.let(T.unsafe(nil), Regexp) + +# Matches {RFC5801 §4}[https://www.rfc-editor.org/rfc/rfc5801#section-4] +# +saslname+. The output from gs2_saslname_encode matches this Regexp. +# +# source://net-imap//lib/net/imap/sasl/gs2_header.rb#26 +Net::IMAP::SASL::GS2Header::RFC5801_SASLNAME = T.let(T.unsafe(nil), Regexp) + +# Authenticator for the "+LOGIN+" SASL mechanism. See Net::IMAP#authenticate. +# +# +LOGIN+ authentication sends the password in cleartext. +# RFC3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable +# cleartext authentication until after TLS has been negotiated. +# RFC8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or +# greater be used for all traffic, and deprecate cleartext access ASAP. +LOGIN+ +# can be secured by TLS encryption. +# +# == Deprecated +# +# The {SASL mechanisms +# registry}[https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml] +# marks "LOGIN" as obsoleted in favor of "PLAIN". It is included here for +# compatibility with existing servers. See +# {draft-murchison-sasl-login}[https://www.iana.org/go/draft-murchison-sasl-login] +# for both specification and deprecation. +# +# source://net-imap//lib/net/imap/sasl/login_authenticator.rb#20 +class Net::IMAP::SASL::LoginAuthenticator + # @return [LoginAuthenticator] a new instance of LoginAuthenticator + # + # source://net-imap//lib/net/imap/sasl/login_authenticator.rb#26 + def initialize(user = T.unsafe(nil), pass = T.unsafe(nil), authcid: T.unsafe(nil), username: T.unsafe(nil), password: T.unsafe(nil), secret: T.unsafe(nil), warn_deprecation: T.unsafe(nil), **_arg7); end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/login_authenticator.rb#54 + def done?; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/login_authenticator.rb#39 + def initial_response?; end + + # source://net-imap//lib/net/imap/sasl/login_authenticator.rb#41 + def process(data); end +end + +# source://net-imap//lib/net/imap/sasl/login_authenticator.rb#23 +Net::IMAP::SASL::LoginAuthenticator::STATE_DONE = T.let(T.unsafe(nil), Symbol) + +# source://net-imap//lib/net/imap/sasl/login_authenticator.rb#22 +Net::IMAP::SASL::LoginAuthenticator::STATE_PASSWORD = T.let(T.unsafe(nil), Symbol) + +# source://net-imap//lib/net/imap/sasl/login_authenticator.rb#21 +Net::IMAP::SASL::LoginAuthenticator::STATE_USER = T.let(T.unsafe(nil), Symbol) + +# Abstract base class for the SASL mechanisms defined in +# RFC7628[https://tools.ietf.org/html/rfc7628]: +# * OAUTHBEARER[rdoc-ref:OAuthBearerAuthenticator] +# (OAuthBearerAuthenticator) +# * OAUTH10A +# +# source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#14 +class Net::IMAP::SASL::OAuthAuthenticator + include ::Net::IMAP::SASL::GS2Header + + # Creates an RFC7628[https://tools.ietf.org/html/rfc7628] OAuth + # authenticator. + # + # ==== Parameters + # + # See child classes for required parameter(s). The following parameters + # are all optional, but it is worth noting that application protocols + # are allowed to require #authzid (or other parameters, such as + # #host or #port) as are specific server implementations. + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # _optional_ #username — An alias for #authzid. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authentication identity is established for the client by the OAuth + # token. + # + # * _optional_ #host — Hostname to which the client connected. + # * _optional_ #port — Service port to which the client connected. + # * _optional_ #mthd — HTTP method + # * _optional_ #path — HTTP path data + # * _optional_ #post — HTTP post data + # * _optional_ #qs — HTTP query string + # + # _optional_ #query — An alias for #qs + # + # Any other keyword parameters are quietly ignored. + # + # @return [OAuthAuthenticator] a new instance of OAuthAuthenticator + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#84 + def initialize(authzid: T.unsafe(nil), host: T.unsafe(nil), port: T.unsafe(nil), username: T.unsafe(nil), query: T.unsafe(nil), mthd: T.unsafe(nil), path: T.unsafe(nil), post: T.unsafe(nil), qs: T.unsafe(nil), **_arg9); end + + # Value of the HTTP Authorization header + # + # Implemented by subclasses. + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#124 + def authorization; end + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. The server is responsible for verifying the + # client's credentials and verifying that the identity it associates + # with the client's authentication identity is allowed to act as (or on + # behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#29 + def authzid; end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#119 + def done?; end + + # Hostname to which the client connected. (optional) + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#33 + def host; end + + # The {RFC7628 §3.1}[https://www.rfc-editor.org/rfc/rfc7628#section-3.1] + # formatted response. + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#99 + def initial_client_response; end + + # Stores the most recent server "challenge". When authentication fails, + # this may hold information about the failure reason, as JSON. + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#53 + def last_server_response; end + + # HTTP method. (optional) + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#39 + def mthd; end + + # HTTP path data. (optional) + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#42 + def path; end + + # Service port to which the client connected. (optional) + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#36 + def port; end + + # HTTP post data. (optional) + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#45 + def post; end + + # Returns initial_client_response the first time, then "^A". + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#108 + def process(data); end + + # The query string. (optional) + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#48 + def qs; end + + # The query string. (optional) + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#48 + def query; end + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. The server is responsible for verifying the + # client's credentials and verifying that the identity it associates + # with the client's authentication identity is allowed to act as (or on + # behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#29 + def username; end +end + +# Authenticator for the "+OAUTHBEARER+" SASL mechanism, specified in +# RFC7628[https://tools.ietf.org/html/rfc7628]. Authenticates using OAuth +# 2.0 bearer tokens, as described in +# RFC6750[https://tools.ietf.org/html/rfc6750]. Use via +# Net::IMAP#authenticate. +# +# RFC6750[https://tools.ietf.org/html/rfc6750] requires Transport Layer +# Security (TLS) to secure the protocol interaction between the client and +# the resource server. TLS _MUST_ be used for +OAUTHBEARER+ to protect +# the bearer token. +# +# source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#138 +class Net::IMAP::SASL::OAuthBearerAuthenticator < ::Net::IMAP::SASL::OAuthAuthenticator + # :call-seq: + # new(oauth2_token, **options) -> authenticator + # new(authzid, oauth2_token, **options) -> authenticator + # new(oauth2_token:, **options) -> authenticator + # + # Creates an Authenticator for the "+OAUTHBEARER+" SASL mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # ==== Parameters + # + # * #oauth2_token — An OAuth2 bearer token + # + # All other keyword parameters are passed to + # {super}[rdoc-ref:OAuthAuthenticator::new] (see OAuthAuthenticator). + # The most common ones are: + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # _optional_ #username — An alias for #authzid. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authentication identity is established for the client by + # #oauth2_token. + # + # * _optional_ #host — Hostname to which the client connected. + # * _optional_ #port — Service port to which the client connected. + # + # Although only oauth2_token is required by this mechanism, it is worth + # noting that application protocols are allowed to + # require #authzid (or other parameters, such as #host + # _or_ #port) as are specific server implementations. + # + # @return [OAuthBearerAuthenticator] a new instance of OAuthBearerAuthenticator + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#177 + def initialize(arg1 = T.unsafe(nil), arg2 = T.unsafe(nil), oauth2_token: T.unsafe(nil), secret: T.unsafe(nil), **args, &blk); end + + # Value of the HTTP Authorization header + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#193 + def authorization; end + + # :call-seq: + # initial_response? -> true + # + # +OAUTHBEARER+ sends an initial client response. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#190 + def initial_response?; end + + # An OAuth 2.0 bearer token. See {RFC-6750}[https://www.rfc-editor.org/rfc/rfc6750] + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#141 + def oauth2_token; end + + # An OAuth 2.0 bearer token. See {RFC-6750}[https://www.rfc-editor.org/rfc/rfc6750] + # + # source://net-imap//lib/net/imap/sasl/oauthbearer_authenticator.rb#141 + def secret; end +end + +# Authenticator for the "+PLAIN+" SASL mechanism, specified in +# RFC-4616[https://tools.ietf.org/html/rfc4616]. See Net::IMAP#authenticate. +# +# +PLAIN+ authentication sends the password in cleartext. +# RFC-3501[https://tools.ietf.org/html/rfc3501] encourages servers to disable +# cleartext authentication until after TLS has been negotiated. +# RFC-8314[https://tools.ietf.org/html/rfc8314] recommends TLS version 1.2 or +# greater be used for all traffic, and deprecate cleartext access ASAP. +PLAIN+ +# can be secured by TLS encryption. +# +# source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#12 +class Net::IMAP::SASL::PlainAuthenticator + # :call-seq: + # new(username, password, authzid: nil, **) -> authenticator + # new(username:, password:, authzid: nil, **) -> authenticator + # new(authcid:, password:, authzid: nil, **) -> authenticator + # + # Creates an Authenticator for the "+PLAIN+" SASL mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # ==== Parameters + # + # * #authcid ― Authentication identity that is associated with #password. + # + # #username ― An alias for #authcid. + # + # * #password ― A password or passphrase associated with the #authcid. + # + # * _optional_ #authzid ― Authorization identity to act as or on behalf of. + # + # When +authzid+ is not set, the server should derive the authorization + # identity from the authentication identity. + # + # Any other keyword parameters are quietly ignored. + # + # @raise [ArgumentError] + # @return [PlainAuthenticator] a new instance of PlainAuthenticator + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#67 + def initialize(user = T.unsafe(nil), pass = T.unsafe(nil), authcid: T.unsafe(nil), secret: T.unsafe(nil), username: T.unsafe(nil), password: T.unsafe(nil), authzid: T.unsafe(nil), **_arg7); end + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#24 + def authcid; end + + # Authorization identity: an identity to act as or on behalf of. The identity + # form is application protocol specific. If not provided or left blank, the + # server derives an authorization identity from the authentication identity. + # The server is responsible for verifying the client's credentials and + # verifying that the identity it associates with the client's authentication + # identity is allowed to act as (or on behalf of) the authorization identity. + # + # For example, an administrator or superuser might take on another role: + # + # imap.authenticate "PLAIN", "root", passwd, authzid: "user" + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#42 + def authzid; end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#99 + def done?; end + + # :call-seq: + # initial_response? -> true + # + # +PLAIN+ can send an initial client response. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#86 + def initial_response?; end + + # A password or passphrase that matches the #username. + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#28 + def password; end + + # Responds with the client's credentials. + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#89 + def process(data); end + + # A password or passphrase that matches the #username. + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#28 + def secret; end + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + # + # source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#24 + def username; end +end + +# source://net-imap//lib/net/imap/sasl/plain_authenticator.rb#14 +Net::IMAP::SASL::PlainAuthenticator::NULL = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/sasl/stringprep.rb#9 +Net::IMAP::SASL::ProhibitedCodepoint = Net::IMAP::StringPrep::ProhibitedCodepoint + +# source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#7 +module Net::IMAP::SASL::ProtocolAdapters; end + +# This API is experimental, and may change. +# +# source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#9 +module Net::IMAP::SASL::ProtocolAdapters::Generic + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#17 + def cancel_response; end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#10 + def command_name; end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#16 + def decode(string); end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#15 + def encode(string); end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#14 + def encode_ir(string); end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#12 + def host; end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#13 + def port; end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#11 + def service; end +end + +# See RFC-3501 (IMAP4rev1), RFC-4959 (SASL-IR capability), +# and RFC-9051 (IMAP4rev2). +# +# source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#22 +module Net::IMAP::SASL::ProtocolAdapters::IMAP + include ::Net::IMAP::SASL::ProtocolAdapters::Generic + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#24 + def service; end +end + +# See RFC-5034 (SASL capability). +# +# source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#35 +module Net::IMAP::SASL::ProtocolAdapters::POP + include ::Net::IMAP::SASL::ProtocolAdapters::Generic + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#37 + def command_name; end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#38 + def service; end +end + +# See RFC-4954 (AUTH capability). +# +# source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#28 +module Net::IMAP::SASL::ProtocolAdapters::SMTP + include ::Net::IMAP::SASL::ProtocolAdapters::Generic + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#30 + def command_name; end + + # source://net-imap//lib/net/imap/sasl/protocol_adapters.rb#31 + def service; end +end + +# Alias for Net::IMAP::StringPrep::SASLprep. +# +# source://net-imap//lib/net/imap/sasl/stringprep.rb#6 +Net::IMAP::SASL::SASLprep = Net::IMAP::StringPrep::SASLprep + +# For method descriptions, +# see {RFC5802 §2.2}[https://www.rfc-editor.org/rfc/rfc5802#section-2.2] +# and {RFC5802 §3}[https://www.rfc-editor.org/rfc/rfc5802#section-3]. +# +# source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#10 +module Net::IMAP::SASL::ScramAlgorithm + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#24 + def H(str); end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#26 + def HMAC(key, data); end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#13 + def Hi(str, salt, iterations); end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#11 + def Normalize(str); end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#28 + def XOR(str1, str2); end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#35 + def auth_message; end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#48 + def client_key; end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#53 + def client_proof; end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#51 + def client_signature; end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#44 + def salted_password; end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#49 + def server_key; end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#52 + def server_signature; end + + # source://net-imap//lib/net/imap/sasl/scram_algorithm.rb#50 + def stored_key; end +end + +# Abstract base class for the "+SCRAM-*+" family of SASL mechanisms, +# defined in RFC5802[https://tools.ietf.org/html/rfc5802]. Use via +# Net::IMAP#authenticate. +# +# Directly supported: +# * +SCRAM-SHA-1+ --- ScramSHA1Authenticator +# * +SCRAM-SHA-256+ --- ScramSHA256Authenticator +# +# New +SCRAM-*+ mechanisms can easily be added for any hash algorithm +# supported by +# OpenSSL::Digest[https://ruby.github.io/openssl/OpenSSL/Digest.html]. +# Subclasses need only set an appropriate +DIGEST_NAME+ constant. +# +# === SCRAM algorithm +# +# See the documentation and method definitions on ScramAlgorithm for an +# overview of the algorithm. The different mechanisms differ only by +# which hash function that is used (or by support for channel binding with +# +-PLUS+). +# +# See also the methods on GS2Header. +# +# ==== Server messages +# +# As server messages are received, they are validated and loaded into +# the various attributes, e.g: #snonce, #salt, #iterations, #verifier, +# #server_error, etc. +# +# Unlike many other SASL mechanisms, the +SCRAM-*+ family supports mutual +# authentication and can return server error data in the server messages. +# If #process raises an Error for the server-final-message, then +# server_error may contain error details. +# +# === TLS Channel binding +# +# The SCRAM-*-PLUS mechanisms and channel binding are not +# supported yet. +# +# === Caching SCRAM secrets +# +# Caching of salted_password, client_key, stored_key, and server_key +# is not supported yet. +# +# source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#56 +class Net::IMAP::SASL::ScramAuthenticator + include ::Net::IMAP::SASL::GS2Header + include ::Net::IMAP::SASL::ScramAlgorithm + + # :call-seq: + # new(username, password, **options) -> auth_ctx + # new(username:, password:, **options) -> auth_ctx + # new(authcid:, password:, **options) -> auth_ctx + # + # Creates an authenticator for one of the "+SCRAM-*+" SASL mechanisms. + # Each subclass defines #digest to match a specific mechanism. + # + # Called by Net::IMAP#authenticate and similar methods on other clients. + # + # === Parameters + # + # * #authcid ― Identity whose #password is used. + # + # #username - An alias for #authcid. + # * #password ― Password or passphrase associated with this #username. + # * _optional_ #authzid ― Alternate identity to act as or on behalf of. + # * _optional_ #min_iterations - Overrides the default value (4096). + # + # Any other keyword parameters are quietly ignored. + # + # @return [ScramAuthenticator] a new instance of ScramAuthenticator + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#80 + def initialize(username_arg = T.unsafe(nil), password_arg = T.unsafe(nil), authcid: T.unsafe(nil), username: T.unsafe(nil), authzid: T.unsafe(nil), password: T.unsafe(nil), secret: T.unsafe(nil), min_iterations: T.unsafe(nil), cnonce: T.unsafe(nil), **options); end + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#107 + def authcid; end + + # Authorization identity: an identity to act as or on behalf of. The + # identity form is application protocol specific. If not provided or + # left blank, the server derives an authorization identity from the + # authentication identity. For example, an administrator or superuser + # might take on another role: + # + # imap.authenticate "SCRAM-SHA-256", "root", passwd, authzid: "user" + # + # The server is responsible for verifying the client's credentials and + # verifying that the identity it associates with the client's + # authentication identity is allowed to act as (or on behalf of) the + # authorization identity. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#126 + def authzid; end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +cbind-input+. + # + # >>> + # *TODO:* implement channel binding, appending +cbind-data+ here. + # + # source://net-imap//lib/net/imap/sasl/gs2_header.rb#37 + def cbind_input; end + + # The client nonce, generated by SecureRandom + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#133 + def cnonce; end + + # Returns a new OpenSSL::Digest object, set to the appropriate hash + # function for the chosen mechanism. + # + # The class's +DIGEST_NAME+ constant must be set to the name of an + # algorithm supported by OpenSSL::Digest. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#155 + def digest; end + + # Is the authentication exchange complete? + # + # If false, another server continuation is required. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#185 + def done?; end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-first-message+. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#159 + def initial_client_response; end + + # The iteration count for the selected hash function and user + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#142 + def iterations; end + + # The minimal allowed iteration count. Lower #iterations will raise an + # Error. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#130 + def min_iterations; end + + # A password or passphrase that matches the #username. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#111 + def password; end + + # responds to the server's challenges + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#164 + def process(challenge); end + + # The salt used by the server for this user + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#139 + def salt; end + + # A password or passphrase that matches the #username. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#111 + def secret; end + + # An error reported by the server during the \SASL exchange. + # + # Does not include errors reported by the protocol, e.g. + # Net::IMAP::NoResponseError. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#148 + def server_error; end + + # The server nonce, which must start with #cnonce + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#136 + def snonce; end + + # Authentication identity: the identity that matches the #password. + # + # RFC-2831[https://tools.ietf.org/html/rfc2831] uses the term +username+. + # "Authentication identity" is the generic term used by + # RFC-4422[https://tools.ietf.org/html/rfc4422]. + # RFC-4616[https://tools.ietf.org/html/rfc4616] and many later RFCs abbreviate + # this to +authcid+. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#107 + def username; end + + private + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-final-message-without-proof+. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#240 + def client_final_message_without_proof; end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-first-message-bare+. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#225 + def client_first_message_bare; end + + # See {RFC5802 §7}[https://www.rfc-editor.org/rfc/rfc5802#section-7] + # +client-final-message+. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#233 + def final_message_with_proof; end + + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#192 + def format_message(hash); end + + # RFC5802 specifies "that the order of attributes in client or server + # messages is fixed, with the exception of extension attributes", but + # this parses it simply as a hash, without respect to order. Note that + # repeated keys (violating the spec) will use the last value. + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#257 + def parse_challenge(challenge); end + + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#211 + def recv_server_final_message(server_final_message); end + + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#194 + def recv_server_first_message(server_first_message); end + + # Need to store this for auth_message + # + # source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#190 + def server_first_message; end +end + +# Authenticator for the "+SCRAM-SHA-1+" SASL mechanism, defined in +# RFC5802[https://tools.ietf.org/html/rfc5802]. +# +# Uses the "SHA-1" digest algorithm from OpenSSL::Digest. +# +# See ScramAuthenticator. +# +# source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#271 +class Net::IMAP::SASL::ScramSHA1Authenticator < ::Net::IMAP::SASL::ScramAuthenticator; end + +# source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#272 +Net::IMAP::SASL::ScramSHA1Authenticator::DIGEST_NAME = T.let(T.unsafe(nil), String) + +# Authenticator for the "+SCRAM-SHA-256+" SASL mechanism, defined in +# RFC7677[https://tools.ietf.org/html/rfc7677]. +# +# Uses the "SHA-256" digest algorithm from OpenSSL::Digest. +# +# See ScramAuthenticator. +# +# source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#281 +class Net::IMAP::SASL::ScramSHA256Authenticator < ::Net::IMAP::SASL::ScramAuthenticator; end + +# source://net-imap//lib/net/imap/sasl/scram_authenticator.rb#282 +Net::IMAP::SASL::ScramSHA256Authenticator::DIGEST_NAME = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/sasl/stringprep.rb#7 +Net::IMAP::SASL::StringPrep = Net::IMAP::StringPrep + +# source://net-imap//lib/net/imap/sasl/stringprep.rb#10 +Net::IMAP::SASL::StringPrepError = Net::IMAP::StringPrep::StringPrepError + +# Authenticator for the "+XOAUTH2+" SASL mechanism. This mechanism was +# originally created for GMail and widely adopted by hosted email providers. +# +XOAUTH2+ has been documented by +# Google[https://developers.google.com/gmail/imap/xoauth2-protocol] and +# Microsoft[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth]. +# +# This mechanism requires an OAuth2 access token which has been authorized +# with the appropriate OAuth2 scopes to access the user's services. Most of +# these scopes are not standardized---consult each service provider's +# documentation for their scopes. +# +# Although this mechanism was never standardized and has been obsoleted by +# "+OAUTHBEARER+", it is still very widely supported. +# +# See Net::IMAP::SASL::OAuthBearerAuthenticator. +# +# source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#18 +class Net::IMAP::SASL::XOAuth2Authenticator + # :call-seq: + # new(username, oauth2_token, **) -> authenticator + # new(username:, oauth2_token:, **) -> authenticator + # new(authzid:, oauth2_token:, **) -> authenticator + # + # Creates an Authenticator for the "+XOAUTH2+" SASL mechanism, as specified by + # Google[https://developers.google.com/gmail/imap/xoauth2-protocol], + # Microsoft[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth] + # and Yahoo[https://senders.yahooinc.com/developer/documentation]. + # + # === Properties + # + # * #username --- the username for the account being accessed. + # + # #authzid --- an alias for #username. + # + # Note that, unlike some other authenticators, +username+ sets the + # _authorization_ identity and not the _authentication_ identity. The + # authenticated identity is established for the client with the OAuth token. + # + # * #oauth2_token --- An OAuth2.0 access token which is authorized to access + # the service for #username. + # + # Any other keyword parameters are quietly ignored. + # + # @return [XOAuth2Authenticator] a new instance of XOAuth2Authenticator + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#71 + def initialize(user = T.unsafe(nil), token = T.unsafe(nil), username: T.unsafe(nil), oauth2_token: T.unsafe(nil), authzid: T.unsafe(nil), secret: T.unsafe(nil), **_arg6); end + + # It is unclear from {Google's original XOAUTH2 + # documentation}[https://developers.google.com/gmail/imap/xoauth2-protocol], + # whether "User" refers to the authentication identity (+authcid+) or the + # authorization identity (+authzid+). The authentication identity is + # established for the client by the OAuth token, so it seems that +username+ + # must be the authorization identity. + # + # {Microsoft's documentation for shared + # mailboxes}[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth#sasl-xoauth2-authentication-for-shared-mailboxes-in-office-365] + # _clearly_ indicates that the Office 365 server interprets it as the + # authorization identity. + # + # Although they _should_ validate that the token has been authorized to access + # the service for +username+, _some_ servers appear to ignore this field, + # relying only the identity and scope authorized by the token. + # Note that, unlike most other authenticators, #username is an alias for the + # authorization identity and not the authentication identity. The + # authenticated identity is established for the client by the #oauth2_token. + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#35 + def authzid; end + + # Returns true when the initial client response was sent. + # + # The authentication should not succeed unless this returns true, but it + # does *not* indicate success. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#98 + def done?; end + + # :call-seq: + # initial_response? -> true + # + # +XOAUTH2+ can send an initial client response. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#84 + def initial_response?; end + + # An OAuth2 access token which has been authorized with the appropriate OAuth2 + # scopes to use the service for #username. + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#44 + def oauth2_token; end + + # Returns the XOAUTH2 formatted response, which combines the +username+ + # with the +oauth2_token+. + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#88 + def process(_data); end + + # An OAuth2 access token which has been authorized with the appropriate OAuth2 + # scopes to use the service for #username. + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#44 + def secret; end + + # It is unclear from {Google's original XOAUTH2 + # documentation}[https://developers.google.com/gmail/imap/xoauth2-protocol], + # whether "User" refers to the authentication identity (+authcid+) or the + # authorization identity (+authzid+). The authentication identity is + # established for the client by the OAuth token, so it seems that +username+ + # must be the authorization identity. + # + # {Microsoft's documentation for shared + # mailboxes}[https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how-to-authenticate-an-imap-pop-smtp-application-by-using-oauth#sasl-xoauth2-authentication-for-shared-mailboxes-in-office-365] + # _clearly_ indicates that the Office 365 server interprets it as the + # authorization identity. + # + # Although they _should_ validate that the token has been authorized to access + # the service for +username+, _some_ servers appear to ignore this field, + # relying only the identity and scope authorized by the token. + # + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#35 + def username; end + + private + + # source://net-imap//lib/net/imap/sasl/xoauth2_authenticator.rb#102 + def build_oauth2_string(username, oauth2_token); end +end + +# Experimental +# +# source://net-imap//lib/net/imap/sasl_adapter.rb#7 +class Net::IMAP::SASLAdapter < ::Net::IMAP::SASL::ClientAdapter + include ::Net::IMAP::SASL::ProtocolAdapters::IMAP + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl_adapter.rb#15 + def auth_capable?(mechanism); end + + # source://net-imap//lib/net/imap/sasl_adapter.rb#16 + def drop_connection; end + + # source://net-imap//lib/net/imap/sasl_adapter.rb#17 + def drop_connection!; end + + # source://net-imap//lib/net/imap/sasl_adapter.rb#13 + def response_errors; end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sasl_adapter.rb#14 + def sasl_ir_capable?; end +end + +# source://net-imap//lib/net/imap/sasl_adapter.rb#10 +Net::IMAP::SASLAdapter::RESPONSE_ERRORS = T.let(T.unsafe(nil), Array) + +# Mailbox attribute indicating that this mailbox is used to hold copies of +# messages that have been sent. Some server implementations might put +# messages here automatically. Alternatively, this might just be advice that +# a client save sent messages here. +# +# source://net-imap//lib/net/imap/flags.rb#248 +Net::IMAP::SENT = T.let(T.unsafe(nil), Symbol) + +# strftime/strptime format for an IMAP4 +date+, excluding optional dquotes. +# Use via the encode_date and decode_date methods. +# +# date = date-text / DQUOTE date-text DQUOTE +# date-text = date-day "-" date-month "-" date-year +# +# date-day = 1*2DIGIT +# ; Day of month +# date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / +# "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" +# date-year = 4DIGIT +# +# source://net-imap//lib/net/imap/data_encoding.rb#22 +Net::IMAP::STRFDATE = T.let(T.unsafe(nil), String) + +# strftime/strptime format for an IMAP4 +date-time+, including dquotes. +# See the encode_datetime and decode_datetime methods. +# +# date-time = DQUOTE date-day-fixed "-" date-month "-" date-year +# SP time SP zone DQUOTE +# +# date-day-fixed = (SP DIGIT) / 2DIGIT +# ; Fixed-format version of date-day +# date-month = "Jan" / "Feb" / "Mar" / "Apr" / "May" / "Jun" / +# "Jul" / "Aug" / "Sep" / "Oct" / "Nov" / "Dec" +# date-year = 4DIGIT +# time = 2DIGIT ":" 2DIGIT ":" 2DIGIT +# ; Hours minutes seconds +# zone = ("+" / "-") 4DIGIT +# ; Signed four-digit value of hhmm representing +# ; hours and minutes east of Greenwich (that is, +# ; the amount that the given time differs from +# ; Universal Time). Subtracting the timezone +# ; from the given time will give the UT form. +# ; The Universal Time zone is "+0000". +# +# Note that Time.strptime "%d" flexibly parses either space or zero +# padding. However, the DQUOTEs are *not* optional. +# +# source://net-imap//lib/net/imap/data_encoding.rb#47 +Net::IMAP::STRFTIME = T.let(T.unsafe(nil), String) + +# The mailbox name was subscribed to using the #subscribe command. +# +# source://net-imap//lib/net/imap/flags.rb#173 +Net::IMAP::SUBSCRIBED = T.let(T.unsafe(nil), Symbol) + +# An array of sequence numbers returned by Net::IMAP#search, or unique +# identifiers returned by Net::IMAP#uid_search. +# +# For backward compatibility, SearchResult inherits from Array. +# +# source://net-imap//lib/net/imap/search_result.rb#10 +class Net::IMAP::SearchResult < ::Array + # Returns a SearchResult populated with the given +seq_nums+. + # + # Net::IMAP::SearchResult.new([1, 3, 5], modseq: 9) + # # => Net::IMAP::SearchResult[1, 3, 5, modseq: 9] + # + # @return [SearchResult] a new instance of SearchResult + # + # source://net-imap//lib/net/imap/search_result.rb#29 + def initialize(seq_nums, modseq: T.unsafe(nil)); end + + # Returns whether +other+ is a SearchResult with the same values and the + # same #modseq. The order of numbers is irrelevant. + # + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[123, 456, modseq: 789] + # # => true + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[456, 123, modseq: 789] + # # => true + # + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[987, 654, modseq: 789] + # # => false + # Net::IMAP::SearchResult[123, 456, modseq: 789] == + # Net::IMAP::SearchResult[1, 2, 3, modseq: 9999] + # # => false + # + # SearchResult can be compared directly with Array, if #modseq is nil and + # the array is sorted. + # + # Net::IMAP::SearchResult[9, 8, 6, 4, 1] == [1, 4, 6, 8, 9] # => true + # Net::IMAP::SearchResult[3, 5, 7, modseq: 99] == [3, 5, 7] # => false + # + # Note that Array#== does require matching order and ignores #modseq. + # + # [9, 8, 6, 4, 1] == Net::IMAP::SearchResult[1, 4, 6, 8, 9] # => false + # [3, 5, 7] == Net::IMAP::SearchResult[3, 5, 7, modseq: 99] # => true + # + # source://net-imap//lib/net/imap/search_result.rb#62 + def ==(other); end + + # Hash equality. Unlike #==, order will be taken into account. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/search_result.rb#77 + def eql?(other); end + + # Hash equality. Unlike #==, order will be taken into account. + # + # source://net-imap//lib/net/imap/search_result.rb#71 + def hash; end + + # Returns a string that represents the SearchResult. + # + # Net::IMAP::SearchResult[123, 456, 789].inspect + # # => "[123, 456, 789]" + # + # Net::IMAP::SearchResult[543, 210, 678, modseq: 2048].inspect + # # => "Net::IMAP::SearchResult[543, 210, 678, modseq: 2048]" + # + # source://net-imap//lib/net/imap/search_result.rb#90 + def inspect; end + + # A modification sequence number, as described by the +CONDSTORE+ + # extension in {[RFC7162 + # §3.1.6]}[https://www.rfc-editor.org/rfc/rfc7162.html#section-3.1.6]. + # + # source://net-imap//lib/net/imap/search_result.rb#23 + def modseq; end + + # source://net-imap//lib/net/imap/search_result.rb#123 + def pretty_print(pp); end + + # Returns a string that follows the formal \IMAP syntax. + # + # data = Net::IMAP::SearchResult[2, 8, 32, 128, 256, 512] + # data.to_s # => "* SEARCH 2 8 32 128 256 512" + # data.to_s("SEARCH") # => "* SEARCH 2 8 32 128 256 512" + # data.to_s("SORT") # => "* SORT 2 8 32 128 256 512" + # data.to_s(nil) # => "2 8 32 128 256 512" + # + # data = Net::IMAP::SearchResult[1, 3, 16, 1024, modseq: 2048].to_s + # data.to_s # => "* SEARCH 1 3 16 1024 (MODSEQ 2048)" + # data.to_s("SORT") # => "* SORT 1 3 16 1024 (MODSEQ 2048)" + # data.to_s # => "1 3 16 1024 (MODSEQ 2048)" + # + # source://net-imap//lib/net/imap/search_result.rb#108 + def to_s(type = T.unsafe(nil)); end + + # Converts the SearchResult into a SequenceSet. + # + # Net::IMAP::SearchResult[9, 1, 2, 4, 10, 12, 3, modseq: 123_456] + # .to_sequence_set + # # => Net::IMAP::SequenceSet["1:4,9:10,12"] + # + # source://net-imap//lib/net/imap/search_result.rb#121 + def to_sequence_set; end + + class << self + # Returns a SearchResult populated with the given +seq_nums+. + # + # Net::IMAP::SearchResult[1, 3, 5, modseq: 9] + # # => Net::IMAP::SearchResult[1, 3, 5, modseq: 9] + # + # source://net-imap//lib/net/imap/search_result.rb#16 + def [](*seq_nums, modseq: T.unsafe(nil)); end + end +end + +# An \IMAP sequence set is a set of message sequence numbers or unique +# identifier numbers ("UIDs"). It contains numbers and ranges of numbers. +# The numbers are all non-zero unsigned 32-bit integers and one special +# value ("*") that represents the largest value in the mailbox. +# +# Certain types of \IMAP responses will contain a SequenceSet, for example +# the data for a "MODIFIED" ResponseCode. Some \IMAP commands may +# receive a SequenceSet as an argument, for example IMAP#search, IMAP#fetch, +# and IMAP#store. +# +# == EXPERIMENTAL API +# +# SequenceSet is currently experimental. Only two methods, ::[] and +# #valid_string, are considered stable. Although the API isn't expected to +# change much, any other methods may be removed or changed without +# deprecation. +# +# == Creating sequence sets +# +# SequenceSet.new with no arguments creates an empty sequence set. Note +# that an empty sequence set is invalid in the \IMAP grammar. +# +# set = Net::IMAP::SequenceSet.new +# set.empty? #=> true +# set.valid? #=> false +# set.valid_string #!> raises DataFormatError +# set << 1..10 +# set.empty? #=> false +# set.valid? #=> true +# set.valid_string #=> "1:10" +# +# SequenceSet.new may receive a single optional argument: a non-zero 32 bit +# unsigned integer, a range, a sequence-set formatted string, +# another sequence set, or an enumerable containing any of these. +# +# set = Net::IMAP::SequenceSet.new(1) +# set.valid_string #=> "1" +# set = Net::IMAP::SequenceSet.new(1..100) +# set.valid_string #=> "1:100" +# set = Net::IMAP::SequenceSet.new(1...100) +# set.valid_string #=> "1:99" +# set = Net::IMAP::SequenceSet.new([1, 2, 5..]) +# set.valid_string #=> "1:2,5:*" +# set = Net::IMAP::SequenceSet.new("1,2,3:7,5,6:10,2048,1024") +# set.valid_string #=> "1,2,3:7,5,6:10,2048,1024" +# set = Net::IMAP::SequenceSet.new(1, 2, 3..7, 5, 6..10, 2048, 1024) +# set.valid_string #=> "1:10,55,1024:2048" +# +# Use ::[] with one or more arguments to create a frozen SequenceSet. An +# invalid (empty) set cannot be created with ::[]. +# +# set = Net::IMAP::SequenceSet["1,2,3:7,5,6:10,2048,1024"] +# set.valid_string #=> "1,2,3:7,5,6:10,2048,1024" +# set = Net::IMAP::SequenceSet[1, 2, [3..7, 5], 6..10, 2048, 1024] +# set.valid_string #=> "1:10,55,1024:2048" +# +# == Normalized form +# +# When a sequence set is created with a single String value, that #string +# representation is preserved. SequenceSet's internal representation +# implicitly sorts all entries, de-duplicates numbers, and coalesces +# adjacent or overlapping ranges. Most enumeration methods and offset-based +# methods use this normalized representation. Most modification methods +# will convert #string to its normalized form. +# +# In some cases the order of the string representation is significant, such +# as the +ESORT+, CONTEXT=SORT, and +UIDPLUS+ extensions. Use +# #entries or #each_entry to enumerate the set in its original order. To +# preserve #string order while modifying a set, use #append, #string=, or +# #replace. +# +# == Using * +# +# \IMAP sequence sets may contain a special value "*", which +# represents the largest number in use. From +seq-number+ in +# {RFC9051 §9}[https://www.rfc-editor.org/rfc/rfc9051.html#section-9-5]: +# >>> +# In the case of message sequence numbers, it is the number of messages +# in a non-empty mailbox. In the case of unique identifiers, it is the +# unique identifier of the last message in the mailbox or, if the +# mailbox is empty, the mailbox's current UIDNEXT value. +# +# When creating a SequenceSet, * may be input as -1, +# "*", :*, an endless range, or a range ending in +# -1. When converting to #elements, #ranges, or #numbers, it will +# output as either :* or an endless range. For example: +# +# Net::IMAP::SequenceSet["1,3,*"].to_a #=> [1, 3, :*] +# Net::IMAP::SequenceSet["1,234:*"].to_a #=> [1, 234..] +# Net::IMAP::SequenceSet[1234..-1].to_a #=> [1234..] +# Net::IMAP::SequenceSet[1234..].to_a #=> [1234..] +# +# Net::IMAP::SequenceSet[1234..].to_s #=> "1234:*" +# Net::IMAP::SequenceSet[1234..-1].to_s #=> "1234:*" +# +# Use #limit to convert "*" to a maximum value. When a range +# includes "*", the maximum value will always be matched: +# +# Net::IMAP::SequenceSet["9999:*"].limit(max: 25) +# #=> Net::IMAP::SequenceSet["25"] +# +# === Surprising * behavior +# +# When a set includes *, some methods may have surprising behavior. +# +# For example, #complement treats * as its own number. This way, +# the #intersection of a set and its #complement will always be empty. +# This is not how an \IMAP server interprets the set: it will convert +# * to either the number of messages in the mailbox or +UIDNEXT+, +# as appropriate. And there _will_ be overlap between a set and its +# complement after #limit is applied to each: +# +# ~Net::IMAP::SequenceSet["*"] == Net::IMAP::SequenceSet[1..(2**32-1)] +# ~Net::IMAP::SequenceSet[1..5] == Net::IMAP::SequenceSet["6:*"] +# +# set = Net::IMAP::SequenceSet[1..5] +# (set & ~set).empty? => true +# +# (set.limit(max: 4) & (~set).limit(max: 4)).to_a => [4] +# +# When counting the number of numbers in a set, * will be counted +# _except_ when UINT32_MAX is also in the set: +# UINT32_MAX = 2**32 - 1 +# Net::IMAP::SequenceSet["*"].count => 1 +# Net::IMAP::SequenceSet[1..UINT32_MAX - 1, :*].count => UINT32_MAX +# +# Net::IMAP::SequenceSet["1:*"].count => UINT32_MAX +# Net::IMAP::SequenceSet[UINT32_MAX, :*].count => 1 +# Net::IMAP::SequenceSet[UINT32_MAX..].count => 1 +# +# == What's here? +# +# SequenceSet provides methods for: +# * {Creating a SequenceSet}[rdoc-ref:SequenceSet@Methods+for+Creating+a+SequenceSet] +# * {Comparing}[rdoc-ref:SequenceSet@Methods+for+Comparing] +# * {Querying}[rdoc-ref:SequenceSet@Methods+for+Querying] +# * {Iterating}[rdoc-ref:SequenceSet@Methods+for+Iterating] +# * {Set Operations}[rdoc-ref:SequenceSet@Methods+for+Set+Operations] +# * {Assigning}[rdoc-ref:SequenceSet@Methods+for+Assigning] +# * {Deleting}[rdoc-ref:SequenceSet@Methods+for+Deleting] +# * {IMAP String Formatting}[rdoc-ref:SequenceSet@Methods+for+IMAP+String+Formatting] +# +# === Methods for Creating a \SequenceSet +# * ::[]: Creates a validated frozen sequence set from one or more inputs. +# * ::new: Creates a new mutable sequence set, which may be empty (invalid). +# * ::try_convert: Calls +to_sequence_set+ on an object and verifies that +# the result is a SequenceSet. +# * ::empty: Returns a frozen empty (invalid) SequenceSet. +# * ::full: Returns a frozen SequenceSet containing every possible number. +# +# === Methods for Comparing +# +# Comparison to another \SequenceSet: +# - #==: Returns whether a given set contains the same numbers as +self+. +# - #eql?: Returns whether a given set uses the same #string as +self+. +# +# Comparison to objects which are convertible to \SequenceSet: +# - #===: +# Returns whether a given object is fully contained within +self+, or +# +nil+ if the object cannot be converted to a compatible type. +# - #cover? (aliased as #===): +# Returns whether a given object is fully contained within +self+. +# - #intersect? (aliased as #overlap?): +# Returns whether +self+ and a given object have any common elements. +# - #disjoint?: +# Returns whether +self+ and a given object have no common elements. +# +# === Methods for Querying +# These methods do not modify +self+. +# +# Set membership: +# - #include? (aliased as #member?): +# Returns whether a given object (nz-number, range, or *) is +# contained by the set. +# - #include_star?: Returns whether the set contains *. +# +# Minimum and maximum value elements: +# - #min: Returns the minimum number in the set. +# - #max: Returns the maximum number in the set. +# - #minmax: Returns the minimum and maximum numbers in the set. +# +# Accessing value by offset: +# - #[] (aliased as #slice): Returns the number or consecutive subset at a +# given offset or range of offsets. +# - #at: Returns the number at a given offset. +# - #find_index: Returns the given number's offset in the set +# +# Set cardinality: +# - #count (aliased as #size): Returns the count of numbers in the set. +# - #empty?: Returns whether the set has no members. \IMAP syntax does not +# allow empty sequence sets. +# - #valid?: Returns whether the set has any members. +# - #full?: Returns whether the set contains every possible value, including +# *. +# +# === Methods for Iterating +# +# - #each_element: Yields each number and range in the set, sorted and +# coalesced, and returns +self+. +# - #elements (aliased as #to_a): Returns an Array of every number and range +# in the set, sorted and coalesced. +# - #each_entry: Yields each number and range in the set, unsorted and +# without deduplicating numbers or coalescing ranges, and returns +self+. +# - #entries: Returns an Array of every number and range in the set, +# unsorted and without deduplicating numbers or coalescing ranges. +# - #each_range: +# Yields each element in the set as a Range and returns +self+. +# - #ranges: Returns an Array of every element in the set, converting +# numbers into ranges of a single value. +# - #each_number: Yields each number in the set and returns +self+. +# - #numbers: Returns an Array with every number in the set, expanding +# ranges into all of their contained numbers. +# - #to_set: Returns a Set containing all of the #numbers in the set. +# +# === Methods for \Set Operations +# These methods do not modify +self+. +# +# - #| (aliased as #union and #+): Returns a new set combining all members +# from +self+ with all members from the other object. +# - #& (aliased as #intersection): Returns a new set containing all members +# common to +self+ and the other object. +# - #- (aliased as #difference): Returns a copy of +self+ with all members +# in the other object removed. +# - #^ (aliased as #xor): Returns a new set containing all members from +# +self+ and the other object except those common to both. +# - #~ (aliased as #complement): Returns a new set containing all members +# that are not in +self+ +# - #limit: Returns a copy of +self+ which has replaced * with a +# given maximum value and removed all members over that maximum. +# +# === Methods for Assigning +# These methods add or replace elements in +self+. +# +# - #add (aliased as #<<): Adds a given object to the set; returns +self+. +# - #add?: If the given object is not an element in the set, adds it and +# returns +self+; otherwise, returns +nil+. +# - #merge: Merges multiple elements into the set; returns +self+. +# - #append: Adds a given object to the set, appending it to the existing +# string, and returns +self+. +# - #string=: Assigns a new #string value and replaces #elements to match. +# - #replace: Replaces the contents of the set with the contents +# of a given object. +# - #complement!: Replaces the contents of the set with its own #complement. +# +# === Methods for Deleting +# These methods remove elements from +self+. +# +# - #clear: Removes all elements in the set; returns +self+. +# - #delete: Removes a given object from the set; returns +self+. +# - #delete?: If the given object is an element in the set, removes it and +# returns it; otherwise, returns +nil+. +# - #delete_at: Removes the number at a given offset. +# - #slice!: Removes the number or consecutive numbers at a given offset or +# range of offsets. +# - #subtract: Removes each given object from the set; returns +self+. +# - #limit!: Replaces * with a given maximum value and removes all +# members over that maximum; returns +self+. +# +# === Methods for \IMAP String Formatting +# +# - #to_s: Returns the +sequence-set+ string, or an empty string when the +# set is empty. +# - #string: Returns the +sequence-set+ string, or nil when empty. +# - #valid_string: Returns the +sequence-set+ string, or raises +# DataFormatError when the set is empty. +# - #normalized_string: Returns a sequence-set string with its +# elements sorted and coalesced, or nil when the set is empty. +# - #normalize: Returns a new set with this set's normalized +sequence-set+ +# representation. +# - #normalize!: Updates #string to its normalized +sequence-set+ +# representation and returns +self+. +# +# source://net-imap//lib/net/imap/sequence_set.rb#279 +class Net::IMAP::SequenceSet + # Create a new SequenceSet object from +input+, which may be another + # SequenceSet, an IMAP formatted +sequence-set+ string, a number, a + # range, :*, or an enumerable of these. + # + # Use ::[] to create a frozen (non-empty) SequenceSet. + # + # @return [SequenceSet] a new instance of SequenceSet + # + # source://net-imap//lib/net/imap/sequence_set.rb#348 + def initialize(input = T.unsafe(nil)); end + + # :call-seq: + # self & other -> sequence set + # intersection(other) -> sequence set + # + # Returns a new sequence set containing only the numbers common to this + # set and +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] & [2, 4, 6] + # #=> Net::IMAP::SequenceSet["2,4"] + # + # (seqset & other) is equivalent to (seqset - ~other). + # + # source://net-imap//lib/net/imap/sequence_set.rb#623 + def &(other); end + + # :call-seq: + # self + other -> sequence set + # self | other -> sequence set + # union(other) -> sequence set + # + # Returns a new sequence set that has every number in the +other+ object + # added. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet["1:5"] | 2 | [4..6, 99] + # #=> Net::IMAP::SequenceSet["1:6,99"] + # + # Related: #add, #merge + # + # source://net-imap//lib/net/imap/sequence_set.rb#586 + def +(other); end + + # :call-seq: + # self - other -> sequence set + # difference(other) -> sequence set + # + # Returns a new sequence set built by duplicating this set and removing + # every number that appears in +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] - 2 - 4 - 6 + # #=> Net::IMAP::SequenceSet["1,3,5"] + # + # Related: #subtract + # + # source://net-imap//lib/net/imap/sequence_set.rb#605 + def -(other); end + + # :call-seq: + # add(object) -> self + # self << other -> self + # + # Adds a range or number to the set and returns +self+. + # + # #string will be regenerated. Use #merge to add many elements at once. + # + # Related: #add?, #merge, #union + # + # source://net-imap//lib/net/imap/sequence_set.rb#674 + def <<(object); end + + # :call-seq: self == other -> true or false + # + # Returns true when the other SequenceSet represents the same message + # identifiers. Encoding difference—such as order, overlaps, or + # duplicates—are ignored. + # + # Net::IMAP::SequenceSet["1:3"] == Net::IMAP::SequenceSet["1:3"] + # #=> true + # Net::IMAP::SequenceSet["1,2,3"] == Net::IMAP::SequenceSet["1:3"] + # #=> true + # Net::IMAP::SequenceSet["1,3"] == Net::IMAP::SequenceSet["3,1"] + # #=> true + # Net::IMAP::SequenceSet["9,1:*"] == Net::IMAP::SequenceSet["1:*"] + # #=> true + # + # Related: #eql?, #normalize + # + # source://net-imap//lib/net/imap/sequence_set.rb#441 + def ==(other); end + + # :call-seq: self === other -> true | false | nil + # + # Returns whether +other+ is contained within the set. Returns +nil+ if a + # StandardError is raised while converting +other+ to a comparable type. + # + # Related: #cover?, #include?, #include_star? + # + # source://net-imap//lib/net/imap/sequence_set.rb#471 + def ===(other); end + + # :call-seq: + # seqset[index] -> integer or :* or nil + # slice(index) -> integer or :* or nil + # seqset[start, length] -> sequence set or nil + # slice(start, length) -> sequence set or nil + # seqset[range] -> sequence set or nil + # slice(range) -> sequence set or nil + # + # Returns a number or a subset from +self+, without modifying the set. + # + # When an Integer argument +index+ is given, the number at offset +index+ + # is returned: + # + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[0] #=> 10 + # set[5] #=> 15 + # set[10] #=> 26 + # + # If +index+ is negative, it counts relative to the end of +self+: + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[-1] #=> 26 + # set[-3] #=> 22 + # set[-6] #=> 15 + # + # If +index+ is out of range, +nil+ is returned. + # + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[11] #=> nil + # set[-12] #=> nil + # + # The result is based on the normalized set—sorted and de-duplicated—not + # on the assigned value of #string. + # + # set = Net::IMAP::SequenceSet["12,20:23,11:16,21"] + # set[0] #=> 11 + # set[-1] #=> 23 + # + # source://net-imap//lib/net/imap/sequence_set.rb#1088 + def [](index, length = T.unsafe(nil)); end + + # :call-seq: + # self ^ other -> sequence set + # xor(other) -> sequence set + # + # Returns a new sequence set containing numbers that are exclusive between + # this set and +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] ^ [2, 4, 6] + # #=> Net::IMAP::SequenceSet["1,3,5:6"] + # + # (seqset ^ other) is equivalent to ((seqset | other) - + # (seqset & other)). + # + # source://net-imap//lib/net/imap/sequence_set.rb#644 + def ^(other); end + + # :call-seq: + # add(object) -> self + # self << other -> self + # + # Adds a range or number to the set and returns +self+. + # + # #string will be regenerated. Use #merge to add many elements at once. + # + # Related: #add?, #merge, #union + # + # source://net-imap//lib/net/imap/sequence_set.rb#674 + def add(object); end + + # :call-seq: add?(object) -> self or nil + # + # Adds a range or number to the set and returns +self+. Returns +nil+ + # when the object is already included in the set. + # + # #string will be regenerated. Use #merge to add many elements at once. + # + # Related: #add, #merge, #union, #include? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#700 + def add?(object); end + + # Adds a range or number to the set and returns +self+. + # + # Unlike #add, #merge, or #union, the new value is appended to #string. + # This may result in a #string which has duplicates or is out-of-order. + # + # source://net-imap//lib/net/imap/sequence_set.rb#684 + def append(object); end + + # :call-seq: at(index) -> integer or nil + # + # Returns a number from +self+, without modifying the set. Behaves the + # same as #[], except that #at only allows a single integer argument. + # + # Related: #[], #slice + # + # source://net-imap//lib/net/imap/sequence_set.rb#1037 + def at(index); end + + # Removes all elements and returns self. + # + # source://net-imap//lib/net/imap/sequence_set.rb#351 + def clear; end + + # :call-seq: + # ~ self -> sequence set + # complement -> sequence set + # + # Returns the complement of self, a SequenceSet which contains all numbers + # _except_ for those in this set. + # + # ~Net::IMAP::SequenceSet.full #=> Net::IMAP::SequenceSet.empty + # ~Net::IMAP::SequenceSet.empty #=> Net::IMAP::SequenceSet.full + # ~Net::IMAP::SequenceSet["1:5,100:222"] + # #=> Net::IMAP::SequenceSet["6:99,223:*"] + # ~Net::IMAP::SequenceSet["6:99,223:*"] + # #=> Net::IMAP::SequenceSet["1:5,100:222"] + # + # Related: #complement! + # + # source://net-imap//lib/net/imap/sequence_set.rb#662 + def complement; end + + # :call-seq: complement! -> self + # + # Converts the SequenceSet to its own #complement. It will contain all + # possible values _except_ for those currently in the set. + # + # Related: #complement + # + # source://net-imap//lib/net/imap/sequence_set.rb#1168 + def complement!; end + + # Returns the count of #numbers in the set. + # + # If * and 2**32 - 1 (the maximum 32-bit unsigned + # integer value) are both in the set, they will only be counted once. + # + # source://net-imap//lib/net/imap/sequence_set.rb#989 + def count; end + + # :call-seq: cover?(other) -> true | false | nil + # + # Returns whether +other+ is contained within the set. +other+ may be any + # object that would be accepted by ::new. + # + # Related: #===, #include?, #include_star? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#483 + def cover?(other); end + + # :call-seq: delete(object) -> self + # + # Deletes the given range or number from the set and returns +self+. + # + # #string will be regenerated after deletion. Use #subtract to remove + # many elements at once. + # + # Related: #delete?, #delete_at, #subtract, #difference + # + # source://net-imap//lib/net/imap/sequence_set.rb#712 + def delete(object); end + + # :call-seq: + # delete?(number) -> integer or nil + # delete?(star) -> :* or nil + # delete?(range) -> sequence set or nil + # + # Removes a specified value from the set, and returns the removed value. + # Returns +nil+ if nothing was removed. + # + # Returns an integer when the specified +number+ argument was removed: + # set = Net::IMAP::SequenceSet.new [5..10, 20] + # set.delete?(7) #=> 7 + # set #=> # + # set.delete?("20") #=> 20 + # set #=> # + # set.delete?(30) #=> nil + # + # Returns :* when * or -1 is specified and + # removed: + # set = Net::IMAP::SequenceSet.new "5:9,20,35,*" + # set.delete?(-1) #=> :* + # set #=> # + # + # And returns a new SequenceSet when a range is specified: + # + # set = Net::IMAP::SequenceSet.new [5..10, 20] + # set.delete?(9..) #=> # + # set #=> # + # set.delete?(21..) #=> nil + # + # #string will be regenerated after deletion. + # + # Related: #delete, #delete_at, #subtract, #difference, #disjoint? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#749 + def delete?(object); end + + # :call-seq: delete_at(index) -> number or :* or nil + # + # Deletes a number the set, indicated by the given +index+. Returns the + # number that was removed, or +nil+ if nothing was removed. + # + # #string will be regenerated after deletion. + # + # Related: #delete, #delete?, #slice!, #subtract, #difference + # + # source://net-imap//lib/net/imap/sequence_set.rb#772 + def delete_at(index); end + + # :call-seq: + # self - other -> sequence set + # difference(other) -> sequence set + # + # Returns a new sequence set built by duplicating this set and removing + # every number that appears in +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] - 2 - 4 - 6 + # #=> Net::IMAP::SequenceSet["1,3,5"] + # + # Related: #subtract + # + # source://net-imap//lib/net/imap/sequence_set.rb#605 + def difference(other); end + + # Returns +true+ if the set and a given object have no common elements, + # +false+ otherwise. + # + # Net::IMAP::SequenceSet["5:10"].disjoint? "7,9,11" #=> false + # Net::IMAP::SequenceSet["5:10"].disjoint? "11:33" #=> true + # + # Related: #intersection, #intersect? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#535 + def disjoint?(other); end + + # Yields each number or range (or :*) in #elements to the block + # and returns self. Returns an enumerator when called without a block. + # + # The returned numbers are sorted and de-duplicated, even when the input + # #string is not. See #normalize. + # + # Related: #elements, #each_entry + # + # source://net-imap//lib/net/imap/sequence_set.rb#924 + def each_element; end + + # Yields each number or range in #string to the block and returns +self+. + # Returns an enumerator when called without a block. + # + # The entries are yielded in the same order they appear in #string, with + # no sorting, deduplication, or coalescing. When #string is in its + # normalized form, this will yield the same values as #each_element. + # + # Related: #entries, #each_element + # + # source://net-imap//lib/net/imap/sequence_set.rb#910 + def each_entry(&block); end + + # Yields each number in #numbers to the block and returns self. + # If the set contains a *, RangeError will be raised. + # + # Returns an enumerator when called without a block (even if the set + # contains *). + # + # Related: #numbers + # + # @raise [RangeError] + # + # source://net-imap//lib/net/imap/sequence_set.rb#964 + def each_number(&block); end + + # Yields each range in #ranges to the block and returns self. + # Returns an enumerator when called without a block. + # + # Related: #ranges + # + # source://net-imap//lib/net/imap/sequence_set.rb#946 + def each_range; end + + # Returns an array of ranges and integers and :*. + # + # The returned elements are sorted and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # By itself, * translates to :*. A range containing + # * translates to an endless range. Use #limit to translate both + # cases to a maximum value. + # + # If the original input was unordered or contains overlapping ranges, the + # returned ranges will be ordered and coalesced. + # + # Net::IMAP::SequenceSet["2,5:9,6,*,12:11"].elements + # #=> [2, 5..9, 11..12, :*] + # + # Related: #each_element, #ranges, #numbers + # + # source://net-imap//lib/net/imap/sequence_set.rb#851 + def elements; end + + # Returns true if the set contains no elements + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#565 + def empty?; end + + # Returns an array of ranges and integers and :*. + # + # The entries are in the same order they appear in #string, with no + # sorting, deduplication, or coalescing. When #string is in its + # normalized form, this will return the same result as #elements. + # This is useful when the given order is significant, for example in a + # ESEARCH response to IMAP#sort. + # + # Related: #each_entry, #elements + # + # source://net-imap//lib/net/imap/sequence_set.rb#833 + def entries; end + + # :call-seq: eql?(other) -> true or false + # + # Hash equality requires the same encoded #string representation. + # + # Net::IMAP::SequenceSet["1:3"] .eql? Net::IMAP::SequenceSet["1:3"] + # #=> true + # Net::IMAP::SequenceSet["1,2,3"].eql? Net::IMAP::SequenceSet["1:3"] + # #=> false + # Net::IMAP::SequenceSet["1,3"] .eql? Net::IMAP::SequenceSet["3,1"] + # #=> false + # Net::IMAP::SequenceSet["9,1:*"].eql? Net::IMAP::SequenceSet["1:*"] + # #=> false + # + # Related: #==, #normalize + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#460 + def eql?(other); end + + # Returns the index of +number+ in the set, or +nil+ if +number+ isn't in + # the set. + # + # Related: #[] + # + # source://net-imap//lib/net/imap/sequence_set.rb#1000 + def find_index(number); end + + # Freezes and returns the set. A frozen SequenceSet is Ractor-safe. + # + # source://net-imap//lib/net/imap/sequence_set.rb#418 + def freeze; end + + # Returns true if the set contains every possible element. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#568 + def full?; end + + # See #eql? + # + # source://net-imap//lib/net/imap/sequence_set.rb#463 + def hash; end + + # Returns +true+ when a given number or range is in +self+, and +false+ + # otherwise. Returns +false+ unless +number+ is an Integer, Range, or + # *. + # + # set = Net::IMAP::SequenceSet["5:10,100,111:115"] + # set.include? 1 #=> false + # set.include? 5..10 #=> true + # set.include? 11..20 #=> false + # set.include? 100 #=> true + # set.include? 6 #=> true, covered by "5:10" + # set.include? 4..9 #=> true, covered by "5:10" + # set.include? "4:9" #=> true, strings are parsed + # set.include? 4..9 #=> false, intersection is not sufficient + # set.include? "*" #=> false, use #limit to re-interpret "*" + # set.include? -1 #=> false, -1 is interpreted as "*" + # + # set = Net::IMAP::SequenceSet["5:10,100,111:*"] + # set.include? :* #=> true + # set.include? "*" #=> true + # set.include? -1 #=> true + # set.include? 200.. #=> true + # set.include? 100.. #=> false + # + # Related: #include_star?, #cover?, #=== + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#509 + def include?(element); end + + # Returns +true+ when the set contains *. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#514 + def include_star?; end + + # source://net-imap//lib/net/imap/sequence_set.rb#1214 + def inspect; end + + # Returns +true+ if the set and a given object have any common elements, + # +false+ otherwise. + # + # Net::IMAP::SequenceSet["5:10"].intersect? "7,9,11" #=> true + # Net::IMAP::SequenceSet["5:10"].intersect? "11:33" #=> false + # + # Related: #intersection, #disjoint? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#523 + def intersect?(other); end + + # :call-seq: + # self & other -> sequence set + # intersection(other) -> sequence set + # + # Returns a new sequence set containing only the numbers common to this + # set and +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] & [2, 4, 6] + # #=> Net::IMAP::SequenceSet["2,4"] + # + # (seqset & other) is equivalent to (seqset - ~other). + # + # source://net-imap//lib/net/imap/sequence_set.rb#623 + def intersection(other); end + + # Returns a frozen SequenceSet with * converted to +max+, numbers + # and ranges over +max+ removed, and ranges containing +max+ converted to + # end at +max+. + # + # Net::IMAP::SequenceSet["5,10:22,50"].limit(max: 20).to_s + # #=> "5,10:20" + # + # * is always interpreted as the maximum value. When the set + # contains *, it will be set equal to the limit. + # + # Net::IMAP::SequenceSet["*"].limit(max: 37) + # #=> Net::IMAP::SequenceSet["37"] + # Net::IMAP::SequenceSet["5:*"].limit(max: 37) + # #=> Net::IMAP::SequenceSet["5:37"] + # Net::IMAP::SequenceSet["500:*"].limit(max: 37) + # #=> Net::IMAP::SequenceSet["37"] + # + # source://net-imap//lib/net/imap/sequence_set.rb#1141 + def limit(max:); end + + # Removes all members over +max+ and returns self. If * is a + # member, it will be converted to +max+. + # + # Related: #limit + # + # source://net-imap//lib/net/imap/sequence_set.rb#1154 + def limit!(max:); end + + # :call-seq: max(star: :*) => integer or star or nil + # + # Returns the maximum value in +self+, +star+ when the set includes + # *, or +nil+ when the set is empty. + # + # source://net-imap//lib/net/imap/sequence_set.rb#543 + def max(star: T.unsafe(nil)); end + + # Returns +true+ when a given number or range is in +self+, and +false+ + # otherwise. Returns +false+ unless +number+ is an Integer, Range, or + # *. + # + # set = Net::IMAP::SequenceSet["5:10,100,111:115"] + # set.include? 1 #=> false + # set.include? 5..10 #=> true + # set.include? 11..20 #=> false + # set.include? 100 #=> true + # set.include? 6 #=> true, covered by "5:10" + # set.include? 4..9 #=> true, covered by "5:10" + # set.include? "4:9" #=> true, strings are parsed + # set.include? 4..9 #=> false, intersection is not sufficient + # set.include? "*" #=> false, use #limit to re-interpret "*" + # set.include? -1 #=> false, -1 is interpreted as "*" + # + # set = Net::IMAP::SequenceSet["5:10,100,111:*"] + # set.include? :* #=> true + # set.include? "*" #=> true + # set.include? -1 #=> true + # set.include? 200.. #=> true + # set.include? 100.. #=> false + # + # Related: #include_star?, #cover?, #=== + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#509 + def member?(element); end + + # Merges all of the elements that appear in any of the +inputs+ into the + # set, and returns +self+. + # + # The +inputs+ may be any objects that would be accepted by ::new: + # non-zero 32 bit unsigned integers, ranges, sequence-set + # formatted strings, other sequence sets, or enumerables containing any of + # these. + # + # #string will be regenerated after all inputs have been merged. + # + # Related: #add, #add?, #union + # + # source://net-imap//lib/net/imap/sequence_set.rb#805 + def merge(*inputs); end + + # :call-seq: min(star: :*) => integer or star or nil + # + # Returns the minimum value in +self+, +star+ when the only value in the + # set is *, or +nil+ when the set is empty. + # + # source://net-imap//lib/net/imap/sequence_set.rb#551 + def min(star: T.unsafe(nil)); end + + # :call-seq: minmax(star: :*) => nil or [integer, integer or star] + # + # Returns a 2-element array containing the minimum and maximum numbers in + # +self+, or +nil+ when the set is empty. + # + # source://net-imap//lib/net/imap/sequence_set.rb#559 + def minmax(star: T.unsafe(nil)); end + + # Returns a new SequenceSet with a normalized string representation. + # + # The returned set's #string is sorted and deduplicated. Adjacent or + # overlapping elements will be merged into a single larger range. + # + # Net::IMAP::SequenceSet["1:5,3:7,10:9,10:11"].normalize + # #=> Net::IMAP::SequenceSet["1:7,9:11"] + # + # Related: #normalize!, #normalized_string + # + # source://net-imap//lib/net/imap/sequence_set.rb#1187 + def normalize; end + + # Resets #string to be sorted, deduplicated, and coalesced. Returns + # +self+. + # + # Related: #normalize, #normalized_string + # + # source://net-imap//lib/net/imap/sequence_set.rb#1197 + def normalize!; end + + # Returns a normalized +sequence-set+ string representation, sorted + # and deduplicated. Adjacent or overlapping elements will be merged into + # a single larger range. Returns +nil+ when the set is empty. + # + # Net::IMAP::SequenceSet["1:5,3:7,10:9,10:11"].normalized_string + # #=> "1:7,9:11" + # + # Related: #normalize!, #normalize + # + # source://net-imap//lib/net/imap/sequence_set.rb#1210 + def normalized_string; end + + # Returns a sorted array of all of the number values in the sequence set. + # + # The returned numbers are sorted and de-duplicated, even when the input + # #string is not. See #normalize. + # + # Net::IMAP::SequenceSet["2,5:9,6,12:11"].numbers + # #=> [2, 5, 6, 7, 8, 9, 11, 12] + # + # If the set contains a *, RangeError is raised. See #limit. + # + # Net::IMAP::SequenceSet["10000:*"].numbers + # #!> RangeError + # + # *WARNING:* Even excluding sets with *, an enormous result can + # easily be created. An array with over 4 billion integers could be + # returned, requiring up to 32GiB of memory on a 64-bit architecture. + # + # Net::IMAP::SequenceSet[10000..2**32-1].numbers + # # ...probably freezes the process for a while... + # #!> NoMemoryError (probably) + # + # For safety, consider using #limit or #intersection to set an upper + # bound. Alternatively, use #each_element, #each_range, or even + # #each_number to avoid allocation of a result array. + # + # Related: #elements, #ranges, #to_set + # + # source://net-imap//lib/net/imap/sequence_set.rb#900 + def numbers; end + + # Returns +true+ if the set and a given object have any common elements, + # +false+ otherwise. + # + # Net::IMAP::SequenceSet["5:10"].intersect? "7,9,11" #=> true + # Net::IMAP::SequenceSet["5:10"].intersect? "11:33" #=> false + # + # Related: #intersection, #disjoint? + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#523 + def overlap?(other); end + + # Returns an array of ranges + # + # The returned elements are sorted and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # * translates to an endless range. By itself, * + # translates to :*... Use #limit to set * to a maximum + # value. + # + # The returned ranges will be ordered and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # Net::IMAP::SequenceSet["2,5:9,6,*,12:11"].ranges + # #=> [2..2, 5..9, 11..12, :*..] + # Net::IMAP::SequenceSet["123,999:*,456:789"].ranges + # #=> [123..123, 456..789, 999..] + # + # Related: #each_range, #elements, #numbers, #to_set + # + # source://net-imap//lib/net/imap/sequence_set.rb#872 + def ranges; end + + # Replace the contents of the set with the contents of +other+ and returns + # +self+. + # + # +other+ may be another SequenceSet, or it may be an IMAP +sequence-set+ + # string, a number, a range, *, or an enumerable of these. + # + # source://net-imap//lib/net/imap/sequence_set.rb#358 + def replace(other); end + + # Unstable API: for internal use only (Net::IMAP#send_data) + # + # source://net-imap//lib/net/imap/sequence_set.rb#1234 + def send_data(imap, tag); end + + # Returns the count of #numbers in the set. + # + # If * and 2**32 - 1 (the maximum 32-bit unsigned + # integer value) are both in the set, they will only be counted once. + # + # source://net-imap//lib/net/imap/sequence_set.rb#989 + def size; end + + # :call-seq: + # seqset[index] -> integer or :* or nil + # slice(index) -> integer or :* or nil + # seqset[start, length] -> sequence set or nil + # slice(start, length) -> sequence set or nil + # seqset[range] -> sequence set or nil + # slice(range) -> sequence set or nil + # + # Returns a number or a subset from +self+, without modifying the set. + # + # When an Integer argument +index+ is given, the number at offset +index+ + # is returned: + # + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[0] #=> 10 + # set[5] #=> 15 + # set[10] #=> 26 + # + # If +index+ is negative, it counts relative to the end of +self+: + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[-1] #=> 26 + # set[-3] #=> 22 + # set[-6] #=> 15 + # + # If +index+ is out of range, +nil+ is returned. + # + # set = Net::IMAP::SequenceSet["10:15,20:23,26"] + # set[11] #=> nil + # set[-12] #=> nil + # + # The result is based on the normalized set—sorted and de-duplicated—not + # on the assigned value of #string. + # + # set = Net::IMAP::SequenceSet["12,20:23,11:16,21"] + # set[0] #=> 11 + # set[-1] #=> 23 + # + # source://net-imap//lib/net/imap/sequence_set.rb#1088 + def slice(index, length = T.unsafe(nil)); end + + # :call-seq: + # slice!(index) -> integer or :* or nil + # slice!(start, length) -> sequence set or nil + # slice!(range) -> sequence set or nil + # + # Deletes a number or consecutive numbers from the set, indicated by the + # given +index+, +start+ and +length+, or +range+ of offsets. Returns the + # number or sequence set that was removed, or +nil+ if nothing was + # removed. Arguments are interpreted the same as for #slice or #[]. + # + # #string will be regenerated after deletion. + # + # Related: #slice, #delete_at, #delete, #delete?, #subtract, #difference + # + # source://net-imap//lib/net/imap/sequence_set.rb#789 + def slice!(index, length = T.unsafe(nil)); end + + # Returns the \IMAP +sequence-set+ string representation, or +nil+ when + # the set is empty. Note that an empty set is invalid in the \IMAP + # syntax. + # + # Use #valid_string to raise an exception when the set is empty, or #to_s + # to return an empty string. + # + # If the set was created from a single string, it is not normalized. If + # the set is updated the string will be normalized. + # + # Related: #valid_string, #normalized_string, #to_s + # + # source://net-imap//lib/net/imap/sequence_set.rb#390 + def string; end + + # Assigns a new string to #string and resets #elements to match. It + # cannot be set to an empty string—assign +nil+ or use #clear instead. + # The string is validated but not normalized. + # + # Use #add or #merge to add a string to an existing set. + # + # Related: #replace, #clear + # + # source://net-imap//lib/net/imap/sequence_set.rb#399 + def string=(str); end + + # Removes all of the elements that appear in any of the given +objects+ + # from the set, and returns +self+. + # + # The +objects+ may be any objects that would be accepted by ::new: + # non-zero 32 bit unsigned integers, ranges, sequence-set + # formatted strings, other sequence sets, or enumerables containing any of + # these. + # + # Related: #difference + # + # source://net-imap//lib/net/imap/sequence_set.rb#819 + def subtract(*objects); end + + # Returns an array of ranges and integers and :*. + # + # The returned elements are sorted and coalesced, even when the input + # #string is not. * will sort last. See #normalize. + # + # By itself, * translates to :*. A range containing + # * translates to an endless range. Use #limit to translate both + # cases to a maximum value. + # + # If the original input was unordered or contains overlapping ranges, the + # returned ranges will be ordered and coalesced. + # + # Net::IMAP::SequenceSet["2,5:9,6,*,12:11"].elements + # #=> [2, 5..9, 11..12, :*] + # + # Related: #each_element, #ranges, #numbers + # + # source://net-imap//lib/net/imap/sequence_set.rb#851 + def to_a; end + + # Returns the \IMAP +sequence-set+ string representation, or an empty + # string when the set is empty. Note that an empty set is invalid in the + # \IMAP syntax. + # + # Related: #valid_string, #normalized_string, #to_s + # + # source://net-imap//lib/net/imap/sequence_set.rb#415 + def to_s; end + + # Returns self + def to_sequence_set; end + + # Returns a Set with all of the #numbers in the sequence set. + # + # If the set contains a *, RangeError will be raised. + # + # See #numbers for the warning about very large sets. + # + # Related: #elements, #ranges, #numbers + # + # source://net-imap//lib/net/imap/sequence_set.rb#983 + def to_set; end + + # :call-seq: + # self + other -> sequence set + # self | other -> sequence set + # union(other) -> sequence set + # + # Returns a new sequence set that has every number in the +other+ object + # added. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet["1:5"] | 2 | [4..6, 99] + # #=> Net::IMAP::SequenceSet["1:6,99"] + # + # Related: #add, #merge + # + # source://net-imap//lib/net/imap/sequence_set.rb#586 + def union(other); end + + # Returns false when the set is empty. + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#562 + def valid?; end + + # Returns the \IMAP +sequence-set+ string representation, or raises a + # DataFormatError when the set is empty. + # + # Use #string to return +nil+ or #to_s to return an empty string without + # error. + # + # Related: #string, #normalized_string, #to_s + # + # @raise [DataFormatError] + # + # source://net-imap//lib/net/imap/sequence_set.rb#374 + def valid_string; end + + # Unstable API: currently for internal use only (Net::IMAP#validate_data) + # + # source://net-imap//lib/net/imap/sequence_set.rb#1228 + def validate; end + + # :call-seq: + # self ^ other -> sequence set + # xor(other) -> sequence set + # + # Returns a new sequence set containing numbers that are exclusive between + # this set and +other+. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet[1..5] ^ [2, 4, 6] + # #=> Net::IMAP::SequenceSet["1,3,5:6"] + # + # (seqset ^ other) is equivalent to ((seqset | other) - + # (seqset & other)). + # + # source://net-imap//lib/net/imap/sequence_set.rb#644 + def xor(other); end + + # :call-seq: + # self + other -> sequence set + # self | other -> sequence set + # union(other) -> sequence set + # + # Returns a new sequence set that has every number in the +other+ object + # added. + # + # +other+ may be any object that would be accepted by ::new: a non-zero 32 + # bit unsigned integer, range, sequence-set formatted string, + # another sequence set, or an enumerable containing any of these. + # + # Net::IMAP::SequenceSet["1:5"] | 2 | [4..6, 99] + # #=> Net::IMAP::SequenceSet["1:6,99"] + # + # Related: #add, #merge + # + # source://net-imap//lib/net/imap/sequence_set.rb#586 + def |(other); end + + # :call-seq: + # ~ self -> sequence set + # complement -> sequence set + # + # Returns the complement of self, a SequenceSet which contains all numbers + # _except_ for those in this set. + # + # ~Net::IMAP::SequenceSet.full #=> Net::IMAP::SequenceSet.empty + # ~Net::IMAP::SequenceSet.empty #=> Net::IMAP::SequenceSet.full + # ~Net::IMAP::SequenceSet["1:5,100:222"] + # #=> Net::IMAP::SequenceSet["6:99,223:*"] + # ~Net::IMAP::SequenceSet["6:99,223:*"] + # #=> Net::IMAP::SequenceSet["1:5,100:222"] + # + # Related: #complement! + # + # source://net-imap//lib/net/imap/sequence_set.rb#662 + def ~; end + + protected + + # source://net-imap//lib/net/imap/sequence_set.rb#1240 + def tuples; end + + private + + # source://net-imap//lib/net/imap/sequence_set.rb#1011 + def each_tuple_with_index; end + + # source://net-imap//lib/net/imap/sequence_set.rb#1304 + def from_tuple_int(num); end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#1313 + def include_tuple?(_arg0); end + + # frozen clones are shallow copied + # + # source://net-imap//lib/net/imap/sequence_set.rb#1247 + def initialize_clone(other); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1251 + def initialize_dup(other); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1257 + def input_to_tuple(obj); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1268 + def input_to_tuples(obj); end + + # unlike SequenceSet#try_convert, this returns an Integer, Range, + # String, Set, Array, or... any type of object. + # + # source://net-imap//lib/net/imap/sequence_set.rb#1285 + def input_try_convert(input); end + + # @return [Boolean] + # + # source://net-imap//lib/net/imap/sequence_set.rb#1315 + def intersect_tuple?(_arg0); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1409 + def nz_number(num); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1404 + def range_gte_to(num); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1293 + def range_to_tuple(range); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1244 + def remain_frozen(set); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1020 + def reverse_each_tuple_with_index; end + + # @raise [ArgumentError] + # + # source://net-imap//lib/net/imap/sequence_set.rb#1099 + def slice_length(start, length); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1107 + def slice_range(range); end + + # @raise [DataFormatError] + # + # source://net-imap//lib/net/imap/sequence_set.rb#1308 + def str_to_tuple(str); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1307 + def str_to_tuples(str); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1303 + def to_tuple_int(obj); end + + # --|=====| |=====new tuple=====| append + # ?????????-|=====new tuple=====|-|===lower===|-- insert + # + # |=====new tuple=====| + # ---------??=======lower=======??--------------- noop + # + # ---------??===lower==|--|==| join remaining + # ---------??===lower==|--|==|----|===upper===|-- join until upper + # ---------??===lower==|--|==|--|=====upper===|-- join to upper + # + # source://net-imap//lib/net/imap/sequence_set.rb#1333 + def tuple_add(tuple); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1342 + def tuple_coalesce(lower, lower_idx, min, max); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1400 + def tuple_gte_with_index(num); end + + # |====tuple================| + # --|====| no more 1. noop + # --|====|---------------------------|====lower====|-- 2. noop + # -------|======lower================|---------------- 3. split + # --------|=====lower================|---------------- 4. trim beginning + # + # -------|======lower====????????????----------------- trim lower + # --------|=====lower====????????????----------------- delete lower + # + # -------??=====lower===============|----------------- 5. trim/delete one + # -------??=====lower====|--|====| no more 6. delete rest + # -------??=====lower====|--|====|---|====upper====|-- 7. delete until + # -------??=====lower====|--|====|--|=====upper====|-- 8. delete and trim + # + # source://net-imap//lib/net/imap/sequence_set.rb#1369 + def tuple_subtract(tuple); end + + # source://net-imap//lib/net/imap/sequence_set.rb#932 + def tuple_to_entry(_arg0); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1306 + def tuple_to_str(tuple); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1379 + def tuple_trim_or_split(lower, idx, tmin, tmax); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1320 + def tuples_add(tuples); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1321 + def tuples_subtract(tuples); end + + # source://net-imap//lib/net/imap/sequence_set.rb#1386 + def tuples_trim_or_delete(lower, lower_idx, tmin, tmax); end + + class << self + # :call-seq: + # SequenceSet[*values] -> valid frozen sequence set + # + # Returns a frozen SequenceSet, constructed from +values+. + # + # An empty SequenceSet is invalid and will raise a DataFormatError. + # + # Use ::new to create a mutable or empty SequenceSet. + # + # source://net-imap//lib/net/imap/sequence_set.rb#305 + def [](first, *rest); end + + # Returns a frozen empty set singleton. Note that valid \IMAP sequence + # sets cannot be empty, so this set is _invalid_. + # + # source://net-imap//lib/net/imap/sequence_set.rb#336 + def empty; end + + # Returns a frozen full set singleton: "1:*" + # + # source://net-imap//lib/net/imap/sequence_set.rb#339 + def full; end + + # :call-seq: + # SequenceSet.try_convert(obj) -> sequence set or nil + # + # If +obj+ is a SequenceSet, returns +obj+. If +obj+ responds_to + # +to_sequence_set+, calls +obj.to_sequence_set+ and returns the result. + # Otherwise returns +nil+. + # + # If +obj.to_sequence_set+ doesn't return a SequenceSet, an exception is + # raised. + # + # @raise [DataFormatError] + # + # source://net-imap//lib/net/imap/sequence_set.rb#326 + def try_convert(obj); end + end +end + +# source://net-imap//lib/net/imap/sequence_set.rb#291 +Net::IMAP::SequenceSet::COERCIBLE = T.let(T.unsafe(nil), Proc) + +# intentionally defined after the class implementation +# +# source://net-imap//lib/net/imap/sequence_set.rb#1420 +Net::IMAP::SequenceSet::EMPTY = T.let(T.unsafe(nil), Net::IMAP::SequenceSet) + +# source://net-imap//lib/net/imap/sequence_set.rb#292 +Net::IMAP::SequenceSet::ENUMABLE = T.let(T.unsafe(nil), Proc) + +# source://net-imap//lib/net/imap/sequence_set.rb#1421 +Net::IMAP::SequenceSet::FULL = T.let(T.unsafe(nil), Net::IMAP::SequenceSet) + +# valid inputs for "*" +# +# source://net-imap//lib/net/imap/sequence_set.rb#288 +Net::IMAP::SequenceSet::STARS = T.let(T.unsafe(nil), Array) + +# represents "*" internally, to simplify sorting (etc) +# +# source://net-imap//lib/net/imap/sequence_set.rb#284 +Net::IMAP::SequenceSet::STAR_INT = T.let(T.unsafe(nil), Integer) + +# The largest possible non-zero unsigned 32-bit integer +# +# source://net-imap//lib/net/imap/sequence_set.rb#281 +Net::IMAP::SequenceSet::UINT32_MAX = T.let(T.unsafe(nil), Integer) + +# source://net-imap//lib/net/imap/command_data.rb#273 +module Net::IMAP::StringFormatter + private + + # coerces non-nil using +to_s+ + # + # source://net-imap//lib/net/imap/command_data.rb#300 + def nstring(str); end + + # coerces using +to_s+ + # + # source://net-imap//lib/net/imap/command_data.rb#290 + def string(str); end + + # Allows nil, symbols, and strings + # + # source://net-imap//lib/net/imap/command_data.rb#285 + def valid_nstring?(str); end + + # Allows symbols in addition to strings + # + # source://net-imap//lib/net/imap/command_data.rb#280 + def valid_string?(str); end + + class << self + # coerces non-nil using +to_s+ + # + # source://net-imap//lib/net/imap/command_data.rb#300 + def nstring(str); end + + # coerces using +to_s+ + # + # source://net-imap//lib/net/imap/command_data.rb#290 + def string(str); end + + # Allows nil, symbols, and strings + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/command_data.rb#285 + def valid_nstring?(str); end + + # Allows symbols in addition to strings + # + # @return [Boolean] + # + # source://net-imap//lib/net/imap/command_data.rb#280 + def valid_string?(str); end + end +end + +# source://net-imap//lib/net/imap/command_data.rb#275 +Net::IMAP::StringFormatter::LITERAL_REGEX = T.let(T.unsafe(nil), Regexp) + +# Regexps and utility methods for implementing stringprep profiles. The +# \StringPrep algorithm is defined by +# {RFC-3454}[https://www.rfc-editor.org/rfc/rfc3454.html]. Each +# codepoint table defined in the RFC-3454 appendices is matched by a Regexp +# defined in this module. +# +# source://net-imap//lib/net/imap/stringprep.rb#11 +module Net::IMAP::StringPrep + private + + # Checks that +string+ obeys all of the "Bidirectional Characters" + # requirements in RFC-3454, §6: + # + # * The characters in \StringPrep\[\"C.8\"] MUST be prohibited + # * If a string contains any RandALCat character, the string MUST NOT + # contain any LCat character. + # * If a string contains any RandALCat character, a RandALCat + # character MUST be the first character of the string, and a + # RandALCat character MUST be the last character of the string. + # + # This is usually combined with #check_prohibited!, so table "C.8" is only + # checked when c_8: true. + # + # Raises either ProhibitedCodepoint or BidiStringError unless all + # requirements are met. +profile+ is an optional string which will be + # added to any exception that is raised (it does not affect behavior). + # + # source://net-imap//lib/net/imap/stringprep.rb#144 + def check_bidi!(string, c_8: T.unsafe(nil), profile: T.unsafe(nil)); end + + # Checks +string+ for any codepoint in +tables+. Raises a + # ProhibitedCodepoint describing the first matching table. + # + # Also checks bidirectional characters, when bidi: true, which may + # raise a BidiStringError. + # + # +profile+ is an optional string which will be added to any exception that + # is raised (it does not affect behavior). + # + # source://net-imap//lib/net/imap/stringprep.rb#104 + def check_prohibited!(string, *tables, bidi: T.unsafe(nil), unassigned: T.unsafe(nil), stored: T.unsafe(nil), profile: T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/stringprep.rb#88 + def map_tables!(string, *tables); end + + # >>> + # 1. Map -- For each character in the input, check if it has a mapping + # and, if so, replace it with its mapping. This is described in + # section 3. + # + # 2. Normalize -- Possibly normalize the result of step 1 using Unicode + # normalization. This is described in section 4. + # + # 3. Prohibit -- Check for any characters that are not allowed in the + # output. If any are found, return an error. This is described in + # section 5. + # + # 4. Check bidi -- Possibly check for right-to-left characters, and if + # any are found, make sure that the whole string satisfies the + # requirements for bidirectional strings. If the string does not + # satisfy the requirements for bidirectional strings, return an + # error. This is described in section 6. + # + # The above steps MUST be performed in the order given to comply with + # this specification. + # + # source://net-imap//lib/net/imap/stringprep.rb#76 + def stringprep(string, maps:, normalization:, prohibited:, **opts); end + + class << self + # Returns a Regexp matching the given +table+ name. + # + # source://net-imap//lib/net/imap/stringprep.rb#49 + def [](table); end + + # Checks that +string+ obeys all of the "Bidirectional Characters" + # requirements in RFC-3454, §6: + # + # * The characters in \StringPrep\[\"C.8\"] MUST be prohibited + # * If a string contains any RandALCat character, the string MUST NOT + # contain any LCat character. + # * If a string contains any RandALCat character, a RandALCat + # character MUST be the first character of the string, and a + # RandALCat character MUST be the last character of the string. + # + # This is usually combined with #check_prohibited!, so table "C.8" is only + # checked when c_8: true. + # + # Raises either ProhibitedCodepoint or BidiStringError unless all + # requirements are met. +profile+ is an optional string which will be + # added to any exception that is raised (it does not affect behavior). + # + # source://net-imap//lib/net/imap/stringprep.rb#144 + def check_bidi!(string, c_8: T.unsafe(nil), profile: T.unsafe(nil)); end + + # Checks +string+ for any codepoint in +tables+. Raises a + # ProhibitedCodepoint describing the first matching table. + # + # Also checks bidirectional characters, when bidi: true, which may + # raise a BidiStringError. + # + # +profile+ is an optional string which will be added to any exception that + # is raised (it does not affect behavior). + # + # source://net-imap//lib/net/imap/stringprep.rb#104 + def check_prohibited!(string, *tables, bidi: T.unsafe(nil), unassigned: T.unsafe(nil), stored: T.unsafe(nil), profile: T.unsafe(nil)); end + + # source://net-imap//lib/net/imap/stringprep.rb#88 + def map_tables!(string, *tables); end + + # >>> + # 1. Map -- For each character in the input, check if it has a mapping + # and, if so, replace it with its mapping. This is described in + # section 3. + # + # 2. Normalize -- Possibly normalize the result of step 1 using Unicode + # normalization. This is described in section 4. + # + # 3. Prohibit -- Check for any characters that are not allowed in the + # output. If any are found, return an error. This is described in + # section 5. + # + # 4. Check bidi -- Possibly check for right-to-left characters, and if + # any are found, make sure that the whole string satisfies the + # requirements for bidirectional strings. If the string does not + # satisfy the requirements for bidirectional strings, return an + # error. This is described in section 6. + # + # The above steps MUST be performed in the order given to comply with + # this specification. + # + # source://net-imap//lib/net/imap/stringprep.rb#76 + def stringprep(string, maps:, normalization:, prohibited:, **opts); end + end +end + +# StringPrepError raised when +string+ contains bidirectional characters +# which violate the StringPrep requirements. +# +# source://net-imap//lib/net/imap/stringprep.rb#45 +class Net::IMAP::StringPrep::BidiStringError < ::Net::IMAP::StringPrep::StringPrepError; end + +# Defined in RFC3491[https://tools.ietf.org/html/rfc3491], the +nameprep+ +# profile of "Stringprep" is: +# >>> +# used by the IDNA protocol for preparing domain names; it is not +# designed for any other purpose. It is explicitly not designed for +# processing arbitrary free text and SHOULD NOT be used for that +# purpose. +# +# ... +# +# This profile specifies prohibiting using the following tables...: +# +# - C.1.2 (Non-ASCII space characters) +# - C.2.2 (Non-ASCII control characters) +# - C.3 (Private use characters) +# - C.4 (Non-character code points) +# - C.5 (Surrogate codes) +# - C.6 (Inappropriate for plain text) +# - C.7 (Inappropriate for canonical representation) +# - C.8 (Change display properties are deprecated) +# - C.9 (Tagging characters) +# +# IMPORTANT NOTE: This profile MUST be used with the IDNA protocol. +# The IDNA protocol has additional prohibitions that are checked +# outside of this profile. +# +# source://net-imap//lib/net/imap/stringprep/nameprep.rb#32 +module Net::IMAP::StringPrep::NamePrep + private + + # source://net-imap//lib/net/imap/stringprep/nameprep.rb#54 + def nameprep(string, **opts); end + + class << self + # source://net-imap//lib/net/imap/stringprep/nameprep.rb#54 + def nameprep(string, **opts); end + end +end + +# From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §6 +# +# source://net-imap//lib/net/imap/stringprep/nameprep.rb#50 +Net::IMAP::StringPrep::NamePrep::CHECK_BIDI = T.let(T.unsafe(nil), TrueClass) + +# From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §3 +# +# source://net-imap//lib/net/imap/stringprep/nameprep.rb#41 +Net::IMAP::StringPrep::NamePrep::MAPPING_TABLES = T.let(T.unsafe(nil), Array) + +# From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §4 +# +# source://net-imap//lib/net/imap/stringprep/nameprep.rb#44 +Net::IMAP::StringPrep::NamePrep::NORMALIZATION = T.let(T.unsafe(nil), Symbol) + +# From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §5 +# +# source://net-imap//lib/net/imap/stringprep/nameprep.rb#47 +Net::IMAP::StringPrep::NamePrep::PROHIBITED_TABLES = T.let(T.unsafe(nil), Array) + +# From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §10 +# +# source://net-imap//lib/net/imap/stringprep/nameprep.rb#35 +Net::IMAP::StringPrep::NamePrep::STRINGPREP_PROFILE = T.let(T.unsafe(nil), String) + +# From RFC3491[https://www.rfc-editor.org/rfc/rfc3491.html] §2 +# +# source://net-imap//lib/net/imap/stringprep/nameprep.rb#38 +Net::IMAP::StringPrep::NamePrep::UNASSIGNED_TABLE = T.let(T.unsafe(nil), String) + +# StringPrepError raised when +string+ contains a codepoint prohibited by +# +table+. +# +# source://net-imap//lib/net/imap/stringprep.rb#31 +class Net::IMAP::StringPrep::ProhibitedCodepoint < ::Net::IMAP::StringPrep::StringPrepError + # @return [ProhibitedCodepoint] a new instance of ProhibitedCodepoint + # + # source://net-imap//lib/net/imap/stringprep.rb#34 + def initialize(table, *args, **kwargs); end + + # Returns the value of attribute table. + # + # source://net-imap//lib/net/imap/stringprep.rb#32 + def table; end +end + +# SASLprep#saslprep can be used to prepare a string according to [RFC4013]. +# +# \SASLprep maps characters three ways: to nothing, to space, and Unicode +# normalization form KC. \SASLprep prohibits codepoints from nearly all +# standard StringPrep tables (RFC3454, Appendix "C"), and uses +# \StringPrep's standard bidirectional characters requirements (Appendix +# "D"). \SASLprep also uses \StringPrep's definition of "Unassigned" +# codepoints (Appendix "A"). +# +# source://net-imap//lib/net/imap/stringprep/saslprep.rb#15 +module Net::IMAP::StringPrep::SASLprep + private + + # Prepares a UTF-8 +string+ for comparison, using the \SASLprep profile + # RFC4013 of the StringPrep algorithm RFC3454. + # + # By default, prohibited strings will return +nil+. When +exception+ is + # +true+, a StringPrepError describing the violation will be raised. + # + # When +stored+ is +true+, "unassigned" codepoints will be prohibited. + # For \StringPrep and the \SASLprep profile, "unassigned" refers to + # Unicode 3.2, and not later versions. See RFC3454 §7 for more + # information. + # + # source://net-imap//lib/net/imap/stringprep/saslprep.rb#42 + def saslprep(str, stored: T.unsafe(nil), exception: T.unsafe(nil)); end + + class << self + # Prepares a UTF-8 +string+ for comparison, using the \SASLprep profile + # RFC4013 of the StringPrep algorithm RFC3454. + # + # By default, prohibited strings will return +nil+. When +exception+ is + # +true+, a StringPrepError describing the violation will be raised. + # + # When +stored+ is +true+, "unassigned" codepoints will be prohibited. + # For \StringPrep and the \SASLprep profile, "unassigned" refers to + # Unicode 3.2, and not later versions. See RFC3454 §7 for more + # information. + # + # source://net-imap//lib/net/imap/stringprep/saslprep.rb#42 + def saslprep(str, stored: T.unsafe(nil), exception: T.unsafe(nil)); end + end +end + +# Used to short-circuit strings that don't need preparation. +# +# source://net-imap//lib/net/imap/stringprep/saslprep.rb#18 +Net::IMAP::StringPrep::SASLprep::ASCII_NO_CTRLS = T.let(T.unsafe(nil), Regexp) + +# Bidirectional Characters [StringPrep, §6] +# +# A Regexp for strings that don't satisfy StringPrep's Bidirectional +# Characters rules. +# +# Equal to StringPrep::Tables::BIDI_FAILURE. +# Redefined here to avoid loading StringPrep::Tables unless necessary. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#79 +Net::IMAP::StringPrep::SASLprep::BIDI_FAILURE = T.let(T.unsafe(nil), Regexp) + +# RFC4013 §2.1 Mapping - mapped to nothing +# >>> +# the "commonly mapped to nothing" characters +# (\StringPrep\[\"B.1\"]) that can be mapped to nothing. +# +# Equal to \StringPrep\[\"B.1\"]. +# Redefined here to avoid loading StringPrep::Tables unless necessary. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#27 +Net::IMAP::StringPrep::SASLprep::MAP_TO_NOTHING = T.let(T.unsafe(nil), Regexp) + +# RFC4013 §2.1 Mapping - mapped to space +# >>> +# non-ASCII space characters (\StringPrep\[\"C.1.2\"]) that can +# be mapped to SPACE (U+0020) +# +# Equal to \StringPrep\[\"C.1.2\"]. +# Redefined here to avoid loading StringPrep::Tables unless necessary. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#18 +Net::IMAP::StringPrep::SASLprep::MAP_TO_SPACE = T.let(T.unsafe(nil), Regexp) + +# A Regexp matching strings prohibited by RFC4013 §2.3 and §2.4. +# +# This combines PROHIBITED_OUTPUT and BIDI_FAILURE. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#84 +Net::IMAP::StringPrep::SASLprep::PROHIBITED = T.let(T.unsafe(nil), Regexp) + +# A Regexp matching codepoints prohibited by RFC4013 §2.3. +# +# This combines all of the TABLES_PROHIBITED tables. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#54 +Net::IMAP::StringPrep::SASLprep::PROHIBITED_OUTPUT = T.let(T.unsafe(nil), Regexp) + +# A Regexp matching codepoints prohibited by RFC4013 §2.3 and §2.5. +# +# This combines PROHIBITED_OUTPUT and UNASSIGNED. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#68 +Net::IMAP::StringPrep::SASLprep::PROHIBITED_OUTPUT_STORED = T.let(T.unsafe(nil), Regexp) + +# A Regexp matching strings prohibited by RFC4013 §2.3, §2.4, and §2.5. +# +# This combines PROHIBITED_OUTPUT_STORED and BIDI_FAILURE. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#91 +Net::IMAP::StringPrep::SASLprep::PROHIBITED_STORED = T.let(T.unsafe(nil), Regexp) + +# RFC4013 §2.3 Prohibited Output +# >>> +# * Non-ASCII space characters — \StringPrep\[\"C.1.2\"] +# * ASCII control characters — \StringPrep\[\"C.2.1\"] +# * Non-ASCII control characters — \StringPrep\[\"C.2.2\"] +# * Private Use characters — \StringPrep\[\"C.3\"] +# * Non-character code points — \StringPrep\[\"C.4\"] +# * Surrogate code points — \StringPrep\[\"C.5\"] +# * Inappropriate for plain text characters — \StringPrep\[\"C.6\"] +# * Inappropriate for canonical representation characters — \StringPrep\[\"C.7\"] +# * Change display properties or deprecated characters — \StringPrep\[\"C.8\"] +# * Tagging characters — \StringPrep\[\"C.9\"] +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#41 +Net::IMAP::StringPrep::SASLprep::TABLES_PROHIBITED = T.let(T.unsafe(nil), Array) + +# Adds unassigned (by Unicode 3.2) codepoints to TABLES_PROHIBITED. +# +# RFC4013 §2.5 Unassigned Code Points +# >>> +# This profile specifies the \StringPrep\[\"A.1\"] table as its +# list of unassigned code points. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#49 +Net::IMAP::StringPrep::SASLprep::TABLES_PROHIBITED_STORED = T.let(T.unsafe(nil), Array) + +# RFC4013 §2.5 Unassigned Code Points +# >>> +# This profile specifies the \StringPrep\[\"A.1\"] table as its +# list of unassigned code points. +# +# Equal to \StringPrep\[\"A.1\"]. +# Redefined here to avoid loading StringPrep::Tables unless necessary. +# +# source://net-imap//lib/net/imap/stringprep/saslprep_tables.rb#63 +Net::IMAP::StringPrep::SASLprep::UNASSIGNED = T.let(T.unsafe(nil), Regexp) + +# ArgumentError raised when +string+ is invalid for the stringprep +# +profile+. +# +# source://net-imap//lib/net/imap/stringprep.rb#19 +class Net::IMAP::StringPrep::StringPrepError < ::ArgumentError + # @return [StringPrepError] a new instance of StringPrepError + # + # source://net-imap//lib/net/imap/stringprep.rb#22 + def initialize(*args, string: T.unsafe(nil), profile: T.unsafe(nil)); end + + # Returns the value of attribute profile. + # + # source://net-imap//lib/net/imap/stringprep.rb#20 + def profile; end + + # Returns the value of attribute string. + # + # source://net-imap//lib/net/imap/stringprep.rb#20 + def string; end +end + +# source://net-imap//lib/net/imap/stringprep/tables.rb#9 +module Net::IMAP::StringPrep::Tables; end + +# source://net-imap//lib/net/imap/stringprep/tables.rb#75 +Net::IMAP::StringPrep::Tables::BIDI_DESC_REQ2 = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/stringprep/tables.rb#83 +Net::IMAP::StringPrep::Tables::BIDI_DESC_REQ3 = T.let(T.unsafe(nil), String) + +# Bidirectional Characters [StringPrep, §6], Requirement 2 +# >>> +# If a string contains any RandALCat character, the string MUST NOT +# contain any LCat character. +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#81 +Net::IMAP::StringPrep::Tables::BIDI_FAILS_REQ2 = T.let(T.unsafe(nil), Regexp) + +# Bidirectional Characters [StringPrep, §6], Requirement 3 +# >>> +# If a string contains any RandALCat character, a RandALCat +# character MUST be the first character of the string, and a +# RandALCat character MUST be the last character of the string. +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#90 +Net::IMAP::StringPrep::Tables::BIDI_FAILS_REQ3 = T.let(T.unsafe(nil), Regexp) + +# Bidirectional Characters [StringPrep, §6] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#93 +Net::IMAP::StringPrep::Tables::BIDI_FAILURE = T.let(T.unsafe(nil), Regexp) + +# Unassigned code points in Unicode 3.2 \StringPrep\[\"A.1\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#12 +Net::IMAP::StringPrep::Tables::IN_A_1 = T.let(T.unsafe(nil), Regexp) + +# Commonly mapped to nothing \StringPrep\[\"B.1\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#15 +Net::IMAP::StringPrep::Tables::IN_B_1 = T.let(T.unsafe(nil), Regexp) + +# Mapping for case-folding used with NFKC \StringPrep\[\"B.2\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#18 +Net::IMAP::StringPrep::Tables::IN_B_2 = T.let(T.unsafe(nil), Regexp) + +# Mapping for case-folding used with no normalization \StringPrep\[\"B.3\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#21 +Net::IMAP::StringPrep::Tables::IN_B_3 = T.let(T.unsafe(nil), Regexp) + +# ASCII space characters \StringPrep\[\"C.1.1\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#33 +Net::IMAP::StringPrep::Tables::IN_C_1_1 = T.let(T.unsafe(nil), Regexp) + +# Non-ASCII space characters \StringPrep\[\"C.1.2\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#36 +Net::IMAP::StringPrep::Tables::IN_C_1_2 = T.let(T.unsafe(nil), Regexp) + +# ASCII control characters \StringPrep\[\"C.2.1\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#39 +Net::IMAP::StringPrep::Tables::IN_C_2_1 = T.let(T.unsafe(nil), Regexp) + +# Non-ASCII control characters \StringPrep\[\"C.2.2\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#42 +Net::IMAP::StringPrep::Tables::IN_C_2_2 = T.let(T.unsafe(nil), Regexp) + +# Private use \StringPrep\[\"C.3\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#45 +Net::IMAP::StringPrep::Tables::IN_C_3 = T.let(T.unsafe(nil), Regexp) + +# Non-character code points \StringPrep\[\"C.4\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#48 +Net::IMAP::StringPrep::Tables::IN_C_4 = T.let(T.unsafe(nil), Regexp) + +# Surrogate codes \StringPrep\[\"C.5\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#51 +Net::IMAP::StringPrep::Tables::IN_C_5 = T.let(T.unsafe(nil), Regexp) + +# Inappropriate for plain text \StringPrep\[\"C.6\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#54 +Net::IMAP::StringPrep::Tables::IN_C_6 = T.let(T.unsafe(nil), Regexp) + +# Inappropriate for canonical representation \StringPrep\[\"C.7\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#57 +Net::IMAP::StringPrep::Tables::IN_C_7 = T.let(T.unsafe(nil), Regexp) + +# Change display properties or are deprecated \StringPrep\[\"C.8\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#60 +Net::IMAP::StringPrep::Tables::IN_C_8 = T.let(T.unsafe(nil), Regexp) + +# Tagging characters \StringPrep\[\"C.9\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#63 +Net::IMAP::StringPrep::Tables::IN_C_9 = T.let(T.unsafe(nil), Regexp) + +# Characters with bidirectional property "R" or "AL" \StringPrep\[\"D.1\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#66 +Net::IMAP::StringPrep::Tables::IN_D_1 = T.let(T.unsafe(nil), Regexp) + +# Used to check req3 of bidirectional checks +# Matches the negation of the D.1 table +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#70 +Net::IMAP::StringPrep::Tables::IN_D_1_NEGATED = T.let(T.unsafe(nil), Regexp) + +# Characters with bidirectional property "L" \StringPrep\[\"D.2\"] +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#73 +Net::IMAP::StringPrep::Tables::IN_D_2 = T.let(T.unsafe(nil), Regexp) + +# source://net-imap//lib/net/imap/stringprep/tables.rb#139 +Net::IMAP::StringPrep::Tables::MAPPINGS = T.let(T.unsafe(nil), Hash) + +# Replacements for IN_B.1 +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#24 +Net::IMAP::StringPrep::Tables::MAP_B_1 = T.let(T.unsafe(nil), String) + +# Replacements for IN_B.2 +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#27 +Net::IMAP::StringPrep::Tables::MAP_B_2 = T.let(T.unsafe(nil), Hash) + +# Replacements for IN_B.3 +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#30 +Net::IMAP::StringPrep::Tables::MAP_B_3 = T.let(T.unsafe(nil), Hash) + +# Regexps matching each codepoint table in the RFC-3454 appendices +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#119 +Net::IMAP::StringPrep::Tables::REGEXPS = T.let(T.unsafe(nil), Hash) + +# Names of each codepoint table in the RFC-3454 appendices +# +# source://net-imap//lib/net/imap/stringprep/tables.rb#96 +Net::IMAP::StringPrep::Tables::TITLES = T.let(T.unsafe(nil), Hash) + +# Defined in RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The +trace+ +# profile of \StringPrep is used by the +ANONYMOUS+ \SASL mechanism. +# +# source://net-imap//lib/net/imap/stringprep/trace.rb#9 +module Net::IMAP::StringPrep::Trace + private + + # From RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The "trace" + # Profile of "Stringprep": + # >>> + # The character repertoire of this profile is Unicode 3.2 [Unicode]. + # + # No mapping is required by this profile. + # + # No Unicode normalization is required by this profile. + # + # The list of unassigned code points for this profile is that provided + # in Appendix A of [StringPrep]. Unassigned code points are not + # prohibited. + # + # Characters from the following tables of [StringPrep] are prohibited: + # (documented on PROHIBITED_TABLES) + # + # This profile requires bidirectional character checking per Section 6 + # of [StringPrep]. + # + # source://net-imap//lib/net/imap/stringprep/trace.rb#68 + def stringprep_trace(string, **opts); end + + class << self + # From RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The "trace" + # Profile of "Stringprep": + # >>> + # The character repertoire of this profile is Unicode 3.2 [Unicode]. + # + # No mapping is required by this profile. + # + # No Unicode normalization is required by this profile. + # + # The list of unassigned code points for this profile is that provided + # in Appendix A of [StringPrep]. Unassigned code points are not + # prohibited. + # + # Characters from the following tables of [StringPrep] are prohibited: + # (documented on PROHIBITED_TABLES) + # + # This profile requires bidirectional character checking per Section 6 + # of [StringPrep]. + # + # source://net-imap//lib/net/imap/stringprep/trace.rb#68 + def stringprep_trace(string, **opts); end + end +end + +# >>> +# This profile requires bidirectional character checking per Section 6 +# of [StringPrep]. +# +# source://net-imap//lib/net/imap/stringprep/trace.rb#46 +Net::IMAP::StringPrep::Trace::CHECK_BIDI = T.let(T.unsafe(nil), TrueClass) + +# >>> +# No mapping is required by this profile. +# +# source://net-imap//lib/net/imap/stringprep/trace.rb#20 +Net::IMAP::StringPrep::Trace::MAPPING_TABLES = T.let(T.unsafe(nil), T.untyped) + +# >>> +# No Unicode normalization is required by this profile. +# +# source://net-imap//lib/net/imap/stringprep/trace.rb#24 +Net::IMAP::StringPrep::Trace::NORMALIZATION = T.let(T.unsafe(nil), T.untyped) + +# From RFC-4505[https://tools.ietf.org/html/rfc4505] §3, The "trace" +# Profile of "Stringprep": +# >>> +# Characters from the following tables of [StringPrep] are prohibited: +# +# - C.2.1 (ASCII control characters) +# - C.2.2 (Non-ASCII control characters) +# - C.3 (Private use characters) +# - C.4 (Non-character code points) +# - C.5 (Surrogate codes) +# - C.6 (Inappropriate for plain text) +# - C.8 (Change display properties are deprecated) +# - C.9 (Tagging characters) +# +# No additional characters are prohibited. +# +# source://net-imap//lib/net/imap/stringprep/trace.rb#41 +Net::IMAP::StringPrep::Trace::PROHIBITED_TABLES = T.let(T.unsafe(nil), Array) + +# Defined in RFC-4505[https://tools.ietf.org/html/rfc4505] §3. +# +# source://net-imap//lib/net/imap/stringprep/trace.rb#12 +Net::IMAP::StringPrep::Trace::STRINGPREP_PROFILE = T.let(T.unsafe(nil), String) + +# >>> +# The character repertoire of this profile is Unicode 3.2 [Unicode]. +# +# source://net-imap//lib/net/imap/stringprep/trace.rb#16 +Net::IMAP::StringPrep::Trace::UNASSIGNED_TABLE = T.let(T.unsafe(nil), String) + +# Mailbox attribute indicating that this mailbox is used to hold messages +# that have been deleted or marked for deletion. In some server +# implementations, this might be a virtual mailbox, containing messages from +# other mailboxes that are marked with the +\Deleted+ message flag. +# Alternatively, this might just be advice that a client that chooses not to +# use the \IMAP +\Deleted+ model should use as its trash location. In server +# implementations that strictly expect the \IMAP +\Deleted+ model, this +# special use is likely not to be supported. +# +# source://net-imap//lib/net/imap/flags.rb#258 +Net::IMAP::TRASH = T.let(T.unsafe(nil), Symbol) + +# Net::IMAP::ThreadMember represents a thread-node returned +# by Net::IMAP#thread. +# +# source://net-imap//lib/net/imap/response_data.rb#764 +class Net::IMAP::ThreadMember < ::Struct + # Returns a SequenceSet containing #seqno and all #children's seqno, + # recursively. + # + # source://net-imap//lib/net/imap/response_data.rb#780 + def to_sequence_set; end + + protected + + # source://net-imap//lib/net/imap/response_data.rb#786 + def all_seqnos(node = T.unsafe(nil)); end +end + +# Net::IMAP::UIDPlusData represents the ResponseCode#data that accompanies +# the +APPENDUID+ and +COPYUID+ response codes. +# +# See [[UIDPLUS[https://www.rfc-editor.org/rfc/rfc4315.html]]. +# +# ==== Capability requirement +# +# The +UIDPLUS+ capability[rdoc-ref:Net::IMAP#capability] must be supported. +# A server that supports +UIDPLUS+ should send a UIDPlusData object inside +# every TaggedResponse returned by the append[rdoc-ref:Net::IMAP#append], +# copy[rdoc-ref:Net::IMAP#copy], move[rdoc-ref:Net::IMAP#move], {uid +# copy}[rdoc-ref:Net::IMAP#uid_copy], and {uid +# move}[rdoc-ref:Net::IMAP#uid_move] commands---unless the destination +# mailbox reports +UIDNOTSTICKY+. +# +# -- +# TODO: support MULTIAPPEND +# ++ +# +# source://net-imap//lib/net/imap/response_data.rb#346 +class Net::IMAP::UIDPlusData < ::Struct + # :call-seq: uid_mapping -> nil or a hash + # + # Returns a hash mapping each source UID to the newly assigned destination + # UID. + # + # Note:: Returns +nil+ for Net::IMAP#append. + # + # source://net-imap//lib/net/imap/response_data.rb#376 + def uid_mapping; end +end + +# Error raised upon an unknown response from the server. +# +# This is different from InvalidResponseError: the response may be a +# valid extension response and the server may be allowed to send it in +# this context, but Net::IMAP either does not know how to parse it or +# how to handle it. This could result from enabling unknown or +# unhandled extensions. The connection may still be usable, +# but—depending on context—it may be prudent to disconnect. +# +# source://net-imap//lib/net/imap/errors.rb#71 +class Net::IMAP::UnknownResponseError < ::Net::IMAP::ResponseError; end + +# **Note:** This represents an intentionally _unstable_ API. Where +# instances of this class are returned, future releases may return a +# different (incompatible) object without deprecation or warning. +# +# Net::IMAP::UnparsedData represents data for unknown response types or +# unknown extensions to response types without a well-defined extension +# grammar. +# +# See also: UnparsedNumericResponseData, ExtensionData, IgnoredResponse +# +# source://net-imap//lib/net/imap/response_data.rb#77 +class Net::IMAP::UnparsedData < ::Struct; end + +# **Note:** This represents an intentionally _unstable_ API. Where +# instances of this class are returned, future releases may return a +# different (incompatible) object without deprecation or warning. +# +# Net::IMAP::UnparsedNumericResponseData represents data for unhandled +# response types with a numeric prefix. See the documentation for #number. +# +# See also: UnparsedData, ExtensionData, IgnoredResponse +# +# source://net-imap//lib/net/imap/response_data.rb#93 +class Net::IMAP::UnparsedNumericResponseData < ::Struct; end + +# source://net-imap//lib/net/imap.rb#720 +Net::IMAP::VERSION = T.let(T.unsafe(nil), String) + +# source://net-imap//lib/net/imap/authenticators.rb#35 +Net::IMAP::XOauth2Authenticator = Net::IMAP::SASL::XOAuth2Authenticator diff --git a/sorbet/rbi/gems/net-pop@0.1.2.rbi b/sorbet/rbi/gems/net-pop@0.1.2.rbi index d331e506c..0157b1a82 100644 --- a/sorbet/rbi/gems/net-pop@0.1.2.rbi +++ b/sorbet/rbi/gems/net-pop@0.1.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `net-pop` gem. # Please instead update this file by running `bin/tapioca gem net-pop`. + # This class is equivalent to POP3, except that it uses APOP authentication. # # source://net-pop//lib/net/pop.rb#729 diff --git a/sorbet/rbi/gems/net-protocol@0.2.1.rbi b/sorbet/rbi/gems/net-protocol@0.2.2.rbi similarity index 99% rename from sorbet/rbi/gems/net-protocol@0.2.1.rbi rename to sorbet/rbi/gems/net-protocol@0.2.2.rbi index 17b01b7d0..f9ede8954 100644 --- a/sorbet/rbi/gems/net-protocol@0.2.1.rbi +++ b/sorbet/rbi/gems/net-protocol@0.2.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `net-protocol` gem. # Please instead update this file by running `bin/tapioca gem net-protocol`. + class Net::BufferedIO # @return [BufferedIO] a new instance of BufferedIO # diff --git a/sorbet/rbi/gems/net-scp@4.0.0.rbi b/sorbet/rbi/gems/net-scp@4.0.0.rbi index 96b218c61..6547443f3 100644 --- a/sorbet/rbi/gems/net-scp@4.0.0.rbi +++ b/sorbet/rbi/gems/net-scp@4.0.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `net-scp` gem. # Please instead update this file by running `bin/tapioca gem net-scp`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/net-sftp@4.0.0.rbi b/sorbet/rbi/gems/net-sftp@4.0.0.rbi index d29c21ac0..9c663fb6e 100644 --- a/sorbet/rbi/gems/net-sftp@4.0.0.rbi +++ b/sorbet/rbi/gems/net-sftp@4.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `net-sftp` gem. # Please instead update this file by running `bin/tapioca gem net-sftp`. + # Net::SFTP is a pure-Ruby module for programmatically interacting with a # remote host via the SFTP protocol (that's SFTP as in "Secure File Transfer # Protocol" produced by the Secure Shell Working Group, not "Secure FTP" @@ -3755,100 +3756,100 @@ module Net::SSH::Connection; end # source://net-sftp//lib/net/sftp.rb#62 class Net::SSH::Connection::Session - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#68 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#68 def initialize(transport, options = T.unsafe(nil)); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#94 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#94 def [](key); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#99 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#99 def []=(key, value); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#152 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#152 def busy?(include_invisible = T.unsafe(nil)); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#51 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#51 def channel_open_handlers; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#44 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#44 def channels; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#522 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#522 def cleanup_channel(channel); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#121 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#121 def close; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#114 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#114 def closed?; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#255 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#255 def ev_do_calculate_rw_wait(wait); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#270 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#270 def ev_do_handle_events(readers, writers); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#289 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#289 def ev_do_postprocess(was_events); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#248 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#248 def ev_preprocess(&block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#379 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#379 def exec(command, status: T.unsafe(nil), &block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#420 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#420 def exec!(command, status: T.unsafe(nil), &block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#493 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#493 def forward; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#105 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#105 def host; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#481 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#481 def listen_to(io, &callback); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#47 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#47 def listeners; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#177 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#177 def loop(wait = T.unsafe(nil), &block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#532 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#532 def max_select_wait_time; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#517 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#517 def on_global_request(type, &block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#507 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#507 def on_open_channel(type, &block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#338 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#338 def open_channel(type = T.unsafe(nil), *extra, &on_confirm); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#38 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#38 def options; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#54 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#54 def pending_requests; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#262 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#262 def postprocess(readers, writers); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#237 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#237 def preprocess(&block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#225 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#225 def process(wait = T.unsafe(nil), &block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#41 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#41 def properties; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#311 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#311 def send_global_request(type, *extra, &callback); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#443 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#443 def send_message(message); end # A convenience method for starting up a new SFTP connection on the current @@ -3863,82 +3864,76 @@ class Net::SSH::Connection::Session # source://net-sftp//lib/net/sftp.rb#71 def sftp(wait = T.unsafe(nil)); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#136 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#136 def shutdown!; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#487 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#487 def stop_listening_to(io); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#35 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#35 def transport; end private - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#682 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#682 def channel_close(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#568 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#568 def channel_closed(channel); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#667 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#667 def channel_data(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#677 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#677 def channel_eof(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#672 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#672 def channel_extended_data(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#694 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#694 def channel_failure(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#612 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#612 def channel_open(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#645 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#645 def channel_open_confirmation(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#651 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#651 def channel_open_failure(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#662 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#662 def channel_request(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#689 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#689 def channel_success(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#657 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#657 def channel_window_adjust(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#545 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#545 def dispatch_incoming_packets(raise_disconnect_errors: T.unsafe(nil)); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#539 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#539 def each_channel(&block); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#562 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#562 def force_channel_cleanup_on_close; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#558 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#558 def get_next_channel_id; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#579 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#579 def global_request(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#699 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#699 def io_select_wait(wait); end def loop_forever; end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#602 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#602 def request_failure(packet); end - # source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#595 + # source://net-ssh/7.2.3/lib/net/ssh/connection/session.rb#595 def request_success(packet); end end - -# source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#32 -Net::SSH::Connection::Session::DEFAULT_IO_SELECT_TIMEOUT = T.let(T.unsafe(nil), Integer) - -# source://net-ssh/7.1.0/lib/net/ssh/connection/session.rb#703 -Net::SSH::Connection::Session::MAP = T.let(T.unsafe(nil), Hash) diff --git a/sorbet/rbi/gems/net-smtp@0.3.3.rbi b/sorbet/rbi/gems/net-smtp@0.5.0.rbi similarity index 68% rename from sorbet/rbi/gems/net-smtp@0.3.3.rbi rename to sorbet/rbi/gems/net-smtp@0.5.0.rbi index 54df6e622..94d8eab1c 100644 --- a/sorbet/rbi/gems/net-smtp@0.3.3.rbi +++ b/sorbet/rbi/gems/net-smtp@0.5.0.rbi @@ -4,28 +4,38 @@ # This is an autogenerated file for types exported from the `net-smtp` gem. # Please instead update this file by running `bin/tapioca gem net-smtp`. + # == What is This Library? # # This library provides functionality to send internet -# mail via SMTP, the Simple Mail Transfer Protocol. For details of -# SMTP itself, see [RFC2821] (http://www.ietf.org/rfc/rfc2821.txt). +# mail via \SMTP, the Simple Mail Transfer Protocol. For details of +# \SMTP itself, see [RFC5321[https://www.rfc-editor.org/rfc/rfc5321.txt]]. +# This library also implements \SMTP authentication, which is often +# necessary for message composers to submit messages to their +# outgoing \SMTP server, see +# [RFC6409[https://www.rfc-editor.org/rfc/rfc6409.html]], +# and [SMTPUTF8[https://www.rfc-editor.org/rfc/rfc6531.txt]], which is +# necessary to send messages to/from addresses containing characters +# outside the ASCII range. # # == What is This Library NOT? # # This library does NOT provide functions to compose internet mails. # You must create them by yourself. If you want better mail support, -# try RubyMail or TMail or search for alternatives in +# try the mail[https://rubygems.org/gems/mail] or +# rmail[https://rubygems.org/gems/rmail] gems, or search for alternatives in # {RubyGems.org}[https://rubygems.org/] or {The Ruby # Toolbox}[https://www.ruby-toolbox.com/]. # -# FYI: the official documentation on internet mail is: [RFC2822] (http://www.ietf.org/rfc/rfc2822.txt). +# FYI: the official specification on internet mail is: +# [RFC5322[https://www.rfc-editor.org/rfc/rfc5322.txt]]. # # == Examples # # === Sending Messages # -# You must open a connection to an SMTP server before sending messages. -# The first argument is the address of your SMTP server, and the second +# You must open a connection to an \SMTP server before sending messages. +# The first argument is the address of your \SMTP server, and the second # argument is the port number. Using SMTP.start with a block is the simplest # way to do this. This way, the SMTP connection is closed automatically # after the block is executed. @@ -35,7 +45,7 @@ # # Use the SMTP object smtp only in this block. # end # -# Replace 'your.smtp.server' with your SMTP server. Normally +# Replace 'your.smtp.server' with your \SMTP server. Normally # your system manager or internet provider supplies a server # for you. # @@ -68,7 +78,7 @@ # smtp.send_message msgstr, 'from@address', 'to@address' # smtp.finish # -# You can also use the block form of SMTP.start/SMTP#start. This closes +# You can also use the block form of SMTP.start or SMTP#start. This closes # the SMTP session automatically: # # # using block form of SMTP.start @@ -81,33 +91,36 @@ # === HELO domain # # In almost all situations, you must provide a third argument -# to SMTP.start/SMTP#start. This is the domain name which you are on +# to SMTP.start or SMTP#start. This is the domain name which you are on # (the host to send mail from). It is called the "HELO domain". -# The SMTP server will judge whether it should send or reject +# The \SMTP server will judge whether it should send or reject # the SMTP session by inspecting the HELO domain. # -# Net::SMTP.start('your.smtp.server', 25 -# helo: 'mail.from.domain') { |smtp| ... } +# Net::SMTP.start('your.smtp.server', 25, helo: 'mail.from.domain') do |smtp| +# smtp.send_message msgstr, 'from@address', 'to@address' +# end +# +# === \SMTP Authentication # -# === SMTP Authentication +# The Net::SMTP class supports the \SMTP extension for SASL Authentication +# [RFC4954[https://www.rfc-editor.org/rfc/rfc4954.html]] and the following +# SASL mechanisms: +PLAIN+, +LOGIN+ _(deprecated)_, and +CRAM-MD5+ +# _(deprecated)_. # -# The Net::SMTP class supports three authentication schemes; -# PLAIN, LOGIN and CRAM MD5. (SMTP Authentication: [RFC2554]) -# To use SMTP authentication, pass extra arguments to -# SMTP.start/SMTP#start. +# To use \SMTP authentication, pass extra arguments to +# SMTP.start or SMTP#start. # # # PLAIN -# Net::SMTP.start('your.smtp.server', 25 +# Net::SMTP.start('your.smtp.server', 25, # user: 'Your Account', secret: 'Your Password', authtype: :plain) -# # LOGIN -# Net::SMTP.start('your.smtp.server', 25 -# user: 'Your Account', secret: 'Your Password', authtype: :login) # -# # CRAM MD5 -# Net::SMTP.start('your.smtp.server', 25 -# user: 'Your Account', secret: 'Your Password', authtype: :cram_md5) +# Support for other SASL mechanisms-such as +EXTERNAL+, +OAUTHBEARER+, +# +SCRAM-SHA-256+, and +XOAUTH2+-will be added in a future release. # -# source://net-smtp//lib/net/smtp.rb#188 +# The +LOGIN+ and +CRAM-MD5+ mechanisms are still available for backwards +# compatibility, but are deprecated and should be avoided. +# +# source://net-smtp//lib/net/smtp.rb#194 class Net::SMTP < ::Net::Protocol # Creates a new Net::SMTP object. # @@ -123,52 +136,62 @@ class Net::SMTP < ::Net::Protocol # If the hostname in the server certificate is different from +address+, # it can be specified with +tls_hostname+. # - # Additional SSLContext params can be added to +ssl_context_params+ hash argument and are passed to - # +OpenSSL::SSL::SSLContext#set_params+ + # Additional SSLContext[https://ruby.github.io/openssl/OpenSSL/SSL/SSLContext.html] + # params can be added to the +ssl_context_params+ hash argument and are + # passed to {OpenSSL::SSL::SSLContext#set_params}[https://ruby.github.io/openssl/OpenSSL/SSL/SSLContext.html#method-i-set_params]. + # + # tls_verify: true is equivalent to ssl_context_params: { + # verify_mode: OpenSSL::SSL::VERIFY_PEER }. # - # +tls_verify: true+ is equivalent to +ssl_context_params: { verify_mode: OpenSSL::SSL::VERIFY_PEER }+. # This method does not open the TCP connection. You can use # SMTP.start instead of SMTP.new if you want to do everything # at once. Otherwise, follow SMTP.new with SMTP#start. # # @return [SMTP] a new instance of SMTP # - # source://net-smtp//lib/net/smtp.rb#241 + # source://net-smtp//lib/net/smtp.rb#248 def initialize(address, port = T.unsafe(nil), tls: T.unsafe(nil), starttls: T.unsafe(nil), tls_verify: T.unsafe(nil), tls_hostname: T.unsafe(nil), ssl_context_params: T.unsafe(nil)); end # The address of the SMTP server to connect to. # - # source://net-smtp//lib/net/smtp.rb#406 + # source://net-smtp//lib/net/smtp.rb#414 def address; end - # source://net-smtp//lib/net/smtp.rb#860 - def auth_cram_md5(user, secret); end - - # source://net-smtp//lib/net/smtp.rb#849 - def auth_login(user, secret); end - - # source://net-smtp//lib/net/smtp.rb#840 - def auth_plain(user, secret); end + # Returns whether the server advertises support for the authentication type. + # You cannot get valid result before opening SMTP session. + # + # @return [Boolean] + # + # source://net-smtp//lib/net/smtp.rb#329 + def auth_capable?(type); end - # source://net-smtp//lib/net/smtp.rb#834 + # Authenticates with the server, using the "AUTH" command. + # + # +authtype+ is the name of a SASL authentication mechanism. + # + # All arguments-other than +authtype+-are forwarded to the authenticator. + # Different authenticators may interpret the +user+ and +secret+ + # arguments differently. + # + # source://net-smtp//lib/net/smtp.rb#872 def authenticate(user, secret, authtype = T.unsafe(nil)); end # The server capabilities by EHLO response # - # source://net-smtp//lib/net/smtp.rb#300 + # source://net-smtp//lib/net/smtp.rb#307 def capabilities; end # true if the EHLO response contains +key+. # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#294 + # source://net-smtp//lib/net/smtp.rb#301 def capable?(key); end # Returns supported authentication methods on this server. # You cannot get valid value before opening SMTP session. # - # source://net-smtp//lib/net/smtp.rb#329 + # source://net-smtp//lib/net/smtp.rb#337 def capable_auth_types; end # true if server advertises AUTH CRAM-MD5. @@ -176,7 +199,7 @@ class Net::SMTP < ::Net::Protocol # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#316 + # source://net-smtp//lib/net/smtp.rb#323 def capable_cram_md5_auth?; end # true if server advertises AUTH LOGIN. @@ -184,7 +207,7 @@ class Net::SMTP < ::Net::Protocol # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#310 + # source://net-smtp//lib/net/smtp.rb#317 def capable_login_auth?; end # true if server advertises AUTH PLAIN. @@ -192,7 +215,7 @@ class Net::SMTP < ::Net::Protocol # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#304 + # source://net-smtp//lib/net/smtp.rb#311 def capable_plain_auth?; end # true if server advertises STARTTLS. @@ -200,7 +223,7 @@ class Net::SMTP < ::Net::Protocol # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#289 + # source://net-smtp//lib/net/smtp.rb#296 def capable_starttls?; end # This method sends a message. @@ -226,7 +249,7 @@ class Net::SMTP < ::Net::Protocol # f.puts "Check vm.c:58879." # } # - # source://net-smtp//lib/net/smtp.rb#998 + # source://net-smtp//lib/net/smtp.rb#958 def data(msgstr = T.unsafe(nil), &block); end # WARNING: This method causes serious security holes. @@ -242,37 +265,37 @@ class Net::SMTP < ::Net::Protocol # .... # end # - # source://net-smtp//lib/net/smtp.rb#442 + # source://net-smtp//lib/net/smtp.rb#450 def debug_output=(arg); end # Disables SMTP/TLS for this object. Must be called before the # connection is established to have any effect. # - # source://net-smtp//lib/net/smtp.rb#356 + # source://net-smtp//lib/net/smtp.rb#364 def disable_ssl; end # Disables SMTP/TLS (STARTTLS) for this object. Must be called # before the connection is established to have any effect. # - # source://net-smtp//lib/net/smtp.rb#400 + # source://net-smtp//lib/net/smtp.rb#408 def disable_starttls; end # Disables SMTP/TLS for this object. Must be called before the # connection is established to have any effect. # - # source://net-smtp//lib/net/smtp.rb#356 + # source://net-smtp//lib/net/smtp.rb#364 def disable_tls; end - # source://net-smtp//lib/net/smtp.rb#938 + # source://net-smtp//lib/net/smtp.rb#907 def ehlo(domain); end - # Enables SMTP/TLS (SMTPS: SMTP over direct TLS connection) for + # Enables SMTP/TLS (SMTPS: \SMTP over direct TLS connection) for # this object. Must be called before the connection is established # to have any effect. +context+ is a OpenSSL::SSL::SSLContext object. # # @raise [ArgumentError] # - # source://net-smtp//lib/net/smtp.rb#345 + # source://net-smtp//lib/net/smtp.rb#353 def enable_ssl(context = T.unsafe(nil)); end # Enables SMTP/TLS (STARTTLS) for this object. @@ -280,7 +303,7 @@ class Net::SMTP < ::Net::Protocol # # @raise [ArgumentError] # - # source://net-smtp//lib/net/smtp.rb#382 + # source://net-smtp//lib/net/smtp.rb#390 def enable_starttls(context = T.unsafe(nil)); end # Enables SMTP/TLS (STARTTLS) for this object if server accepts. @@ -288,16 +311,16 @@ class Net::SMTP < ::Net::Protocol # # @raise [ArgumentError] # - # source://net-smtp//lib/net/smtp.rb#391 + # source://net-smtp//lib/net/smtp.rb#399 def enable_starttls_auto(context = T.unsafe(nil)); end - # Enables SMTP/TLS (SMTPS: SMTP over direct TLS connection) for + # Enables SMTP/TLS (SMTPS: \SMTP over direct TLS connection) for # this object. Must be called before the connection is established # to have any effect. +context+ is a OpenSSL::SSL::SSLContext object. # # @raise [ArgumentError] # - # source://net-smtp//lib/net/smtp.rb#345 + # source://net-smtp//lib/net/smtp.rb#353 def enable_tls(context = T.unsafe(nil)); end # Set whether to use ESMTP or not. This should be done before @@ -306,7 +329,7 @@ class Net::SMTP < ::Net::Protocol # object will automatically switch to plain SMTP mode and # retry (but not vice versa). # - # source://net-smtp//lib/net/smtp.rb#282 + # source://net-smtp//lib/net/smtp.rb#289 def esmtp; end # Set whether to use ESMTP or not. This should be done before @@ -315,7 +338,7 @@ class Net::SMTP < ::Net::Protocol # object will automatically switch to plain SMTP mode and # retry (but not vice versa). # - # source://net-smtp//lib/net/smtp.rb#282 + # source://net-smtp//lib/net/smtp.rb#289 def esmtp=(_arg0); end # Set whether to use ESMTP or not. This should be done before @@ -325,7 +348,7 @@ class Net::SMTP < ::Net::Protocol # retry (but not vice versa). # +true+ if the SMTP object uses ESMTP (which it does by default). # - # source://net-smtp//lib/net/smtp.rb#282 + # source://net-smtp//lib/net/smtp.rb#289 def esmtp?; end # Finishes the SMTP session and closes TCP connection. @@ -333,20 +356,23 @@ class Net::SMTP < ::Net::Protocol # # @raise [IOError] # - # source://net-smtp//lib/net/smtp.rb#624 + # source://net-smtp//lib/net/smtp.rb#655 def finish; end - # source://net-smtp//lib/net/smtp.rb#934 + # source://net-smtp//lib/net/smtp.rb#989 + def get_response(reqline); end + + # source://net-smtp//lib/net/smtp.rb#903 def helo(domain); end # Provide human-readable stringification of class state. # - # source://net-smtp//lib/net/smtp.rb#271 + # source://net-smtp//lib/net/smtp.rb#278 def inspect; end # +from_addr+ is +String+ or +Net::SMTP::Address+ # - # source://net-smtp//lib/net/smtp.rb#943 + # source://net-smtp//lib/net/smtp.rb#912 def mailfrom(from_addr); end # Opens a message writer stream and gives it to the block. @@ -394,52 +420,52 @@ class Net::SMTP < ::Net::Protocol # # @raise [IOError] # - # source://net-smtp//lib/net/smtp.rb#818 + # source://net-smtp//lib/net/smtp.rb#849 def open_message_stream(from_addr, *to_addrs, &block); end # Seconds to wait while attempting to open a connection. # If the connection cannot be opened within this time, a # Net::OpenTimeout is raised. The default value is 30 seconds. # - # source://net-smtp//lib/net/smtp.rb#414 + # source://net-smtp//lib/net/smtp.rb#422 def open_timeout; end # Seconds to wait while attempting to open a connection. # If the connection cannot be opened within this time, a # Net::OpenTimeout is raised. The default value is 30 seconds. # - # source://net-smtp//lib/net/smtp.rb#414 + # source://net-smtp//lib/net/smtp.rb#422 def open_timeout=(_arg0); end # The port number of the SMTP server to connect to. # - # source://net-smtp//lib/net/smtp.rb#409 + # source://net-smtp//lib/net/smtp.rb#417 def port; end - # source://net-smtp//lib/net/smtp.rb#1025 + # source://net-smtp//lib/net/smtp.rb#985 def quit; end # +to_addr+ is +String+ or +Net::SMTP::Address+ # - # source://net-smtp//lib/net/smtp.rb#970 + # source://net-smtp//lib/net/smtp.rb#930 def rcptto(to_addr); end # @raise [ArgumentError] # - # source://net-smtp//lib/net/smtp.rb#948 + # source://net-smtp//lib/net/smtp.rb#921 def rcptto_list(to_addrs); end # Seconds to wait while reading one block (by one read(2) call). # If the read(2) call does not complete within this time, a # Net::ReadTimeout is raised. The default value is 60 seconds. # - # source://net-smtp//lib/net/smtp.rb#419 + # source://net-smtp//lib/net/smtp.rb#427 def read_timeout; end # Set the number of seconds to wait until timing-out a read(2) # call. # - # source://net-smtp//lib/net/smtp.rb#423 + # source://net-smtp//lib/net/smtp.rb#431 def read_timeout=(sec); end # Opens a message writer stream and gives it to the block. @@ -488,12 +514,12 @@ class Net::SMTP < ::Net::Protocol # # @raise [IOError] # - # source://net-smtp//lib/net/smtp.rb#818 + # source://net-smtp//lib/net/smtp.rb#849 def ready(from_addr, *to_addrs, &block); end # Aborts the current mail transaction # - # source://net-smtp//lib/net/smtp.rb#926 + # source://net-smtp//lib/net/smtp.rb#895 def rset; end # Sends +msgstr+ as a message. Single CR ("\r") and LF ("\n") found @@ -533,7 +559,7 @@ class Net::SMTP < ::Net::Protocol # # @raise [IOError] # - # source://net-smtp//lib/net/smtp.rb#765 + # source://net-smtp//lib/net/smtp.rb#794 def send_mail(msgstr, from_addr, *to_addrs); end # Sends +msgstr+ as a message. Single CR ("\r") and LF ("\n") found @@ -573,7 +599,7 @@ class Net::SMTP < ::Net::Protocol # # @raise [IOError] # - # source://net-smtp//lib/net/smtp.rb#765 + # source://net-smtp//lib/net/smtp.rb#794 def send_message(msgstr, from_addr, *to_addrs); end # Sends +msgstr+ as a message. Single CR ("\r") and LF ("\n") found @@ -614,7 +640,7 @@ class Net::SMTP < ::Net::Protocol # # @raise [IOError] # - # source://net-smtp//lib/net/smtp.rb#765 + # source://net-smtp//lib/net/smtp.rb#794 def sendmail(msgstr, from_addr, *to_addrs); end # WARNING: This method causes serious security holes. @@ -630,24 +656,24 @@ class Net::SMTP < ::Net::Protocol # .... # end # - # source://net-smtp//lib/net/smtp.rb#442 + # source://net-smtp//lib/net/smtp.rb#450 def set_debug_output(arg); end # true if this object uses SMTP/TLS (SMTPS). # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#336 + # source://net-smtp//lib/net/smtp.rb#344 def ssl?; end # Hash for additional SSLContext parameters. # - # source://net-smtp//lib/net/smtp.rb#268 + # source://net-smtp//lib/net/smtp.rb#275 def ssl_context_params; end # Hash for additional SSLContext parameters. # - # source://net-smtp//lib/net/smtp.rb#268 + # source://net-smtp//lib/net/smtp.rb#275 def ssl_context_params=(_arg0); end # :call-seq: @@ -661,11 +687,21 @@ class Net::SMTP < ::Net::Protocol # +helo+ is the _HELO_ _domain_ that you'll dispatch mails from; see # the discussion in the overview notes. # - # If both of +user+ and +secret+ are given, SMTP authentication - # will be attempted using the AUTH command. +authtype+ specifies - # the type of authentication to attempt; it must be one of - # :login, :plain, and :cram_md5. See the notes on SMTP Authentication - # in the overview. + # The remaining arguments are used for \SMTP authentication, if required or + # desired. + # + # +authtype+ is the SASL authentication mechanism. + # + # +user+ is the authentication or authorization identity. + # + # +secret+ or +password+ is your password or other authentication token. + # + # These will be sent to #authenticate as positional arguments-the exact + # semantics are dependent on the +authtype+. + # + # See the discussion of Net::SMTP@SMTP+Authentication in the overview notes. + # + # See also: Net::SMTP.start # # === Block Usage # @@ -706,17 +742,17 @@ class Net::SMTP < ::Net::Protocol # # @raise [ArgumentError] # - # source://net-smtp//lib/net/smtp.rb#591 + # source://net-smtp//lib/net/smtp.rb#622 def start(*args, helo: T.unsafe(nil), user: T.unsafe(nil), secret: T.unsafe(nil), password: T.unsafe(nil), authtype: T.unsafe(nil)); end - # +true+ if the SMTP session has been started. + # +true+ if the \SMTP session has been started. # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#532 + # source://net-smtp//lib/net/smtp.rb#553 def started?; end - # source://net-smtp//lib/net/smtp.rb#930 + # source://net-smtp//lib/net/smtp.rb#899 def starttls; end # Returns truth value if this object uses STARTTLS. @@ -725,153 +761,125 @@ class Net::SMTP < ::Net::Protocol # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#366 + # source://net-smtp//lib/net/smtp.rb#374 def starttls?; end # true if this object uses STARTTLS. # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#371 + # source://net-smtp//lib/net/smtp.rb#379 def starttls_always?; end # true if this object uses STARTTLS when server advertises STARTTLS. # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#376 + # source://net-smtp//lib/net/smtp.rb#384 def starttls_auto?; end # true if this object uses SMTP/TLS (SMTPS). # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#336 + # source://net-smtp//lib/net/smtp.rb#344 def tls?; end # The hostname for verifying hostname in the server certificatate. # - # source://net-smtp//lib/net/smtp.rb#265 + # source://net-smtp//lib/net/smtp.rb#272 def tls_hostname; end # The hostname for verifying hostname in the server certificatate. # - # source://net-smtp//lib/net/smtp.rb#265 + # source://net-smtp//lib/net/smtp.rb#272 def tls_hostname=(_arg0); end # If +true+, verify th server's certificate. # - # source://net-smtp//lib/net/smtp.rb#262 + # source://net-smtp//lib/net/smtp.rb#269 def tls_verify; end # If +true+, verify th server's certificate. # - # source://net-smtp//lib/net/smtp.rb#262 + # source://net-smtp//lib/net/smtp.rb#269 def tls_verify=(_arg0); end private - # @return [Boolean] - # - # source://net-smtp//lib/net/smtp.rb#320 - def auth_capable?(type); end + # source://net-smtp//lib/net/smtp.rb#748 + def any_require_smtputf8(addresses); end # source://net-smtp//lib/net/smtp.rb#880 - def auth_method(type); end - - # source://net-smtp//lib/net/smtp.rb#893 - def base64_encode(str); end + def check_auth_args(type, *args, **kwargs); end - # source://net-smtp//lib/net/smtp.rb#884 - def check_auth_args(user, secret, authtype = T.unsafe(nil)); end - - # source://net-smtp//lib/net/smtp.rb#1092 - def check_auth_continue(res); end - - # source://net-smtp//lib/net/smtp.rb#874 - def check_auth_method(type); end - - # source://net-smtp//lib/net/smtp.rb#1086 - def check_auth_response(res); end - - # source://net-smtp//lib/net/smtp.rb#1080 + # source://net-smtp//lib/net/smtp.rb#1040 def check_continue(res); end - # source://net-smtp//lib/net/smtp.rb#1074 + # source://net-smtp//lib/net/smtp.rb#1034 def check_response(res); end - # CRAM-MD5: [RFC2195] - # - # source://net-smtp//lib/net/smtp.rb#902 - def cram_md5_response(secret, challenge); end - - # source://net-smtp//lib/net/smtp.rb#909 - def cram_secret(secret, mask); end - - # source://net-smtp//lib/net/smtp.rb#1064 + # source://net-smtp//lib/net/smtp.rb#1024 def critical; end - # source://net-smtp//lib/net/smtp.rb#631 - def digest_class; end - - # source://net-smtp//lib/net/smtp.rb#714 + # source://net-smtp//lib/net/smtp.rb#731 def do_finish; end - # source://net-smtp//lib/net/smtp.rb#702 + # source://net-smtp//lib/net/smtp.rb#719 def do_helo(helo_domain); end - # source://net-smtp//lib/net/smtp.rb#650 + # source://net-smtp//lib/net/smtp.rb#666 def do_start(helo_domain, user, secret, authtype); end - # source://net-smtp//lib/net/smtp.rb#1048 - def get_response(reqline); end - - # source://net-smtp//lib/net/smtp.rb#1038 + # source://net-smtp//lib/net/smtp.rb#1004 def getok(reqline); end - # source://net-smtp//lib/net/smtp.rb#1177 + # source://net-smtp//lib/net/smtp.rb#1125 def logging(msg); end - # source://net-smtp//lib/net/smtp.rb#697 + # source://net-smtp//lib/net/smtp.rb#714 def new_internet_message_io(s); end - # source://net-smtp//lib/net/smtp.rb#1054 + # source://net-smtp//lib/net/smtp.rb#1014 def recv_response; end - # source://net-smtp//lib/net/smtp.rb#680 + # source://net-smtp//lib/net/smtp.rb#740 + def requires_smtputf8(address); end + + # source://net-smtp//lib/net/smtp.rb#697 def ssl_socket(socket, context); end - # source://net-smtp//lib/net/smtp.rb#641 + # source://net-smtp//lib/net/smtp.rb#662 def tcp_socket(address, port); end - # source://net-smtp//lib/net/smtp.rb#684 + # source://net-smtp//lib/net/smtp.rb#701 def tlsconnect(s, context); end - # source://net-smtp//lib/net/smtp.rb#1031 + # source://net-smtp//lib/net/smtp.rb#997 def validate_line(line); end class << self # The default SMTP port number, 25. # - # source://net-smtp//lib/net/smtp.rb#194 + # source://net-smtp//lib/net/smtp.rb#198 def default_port; end - # source://net-smtp//lib/net/smtp.rb#212 + # source://net-smtp//lib/net/smtp.rb#216 def default_ssl_context(ssl_context_params = T.unsafe(nil)); end # The default SMTPS port number, 465. # - # source://net-smtp//lib/net/smtp.rb#204 + # source://net-smtp//lib/net/smtp.rb#208 def default_ssl_port; end # The default mail submission port number, 587. # - # source://net-smtp//lib/net/smtp.rb#199 + # source://net-smtp//lib/net/smtp.rb#203 def default_submission_port; end # The default SMTPS port number, 465. # - # source://net-smtp//lib/net/smtp.rb#204 + # source://net-smtp//lib/net/smtp.rb#208 def default_tls_port; end # :call-seq: @@ -882,7 +890,10 @@ class Net::SMTP < ::Net::Protocol # # This method is equivalent to: # - # Net::SMTP.new(address, port).start(helo: helo_domain, user: account, secret: password, authtype: authtype, tls_verify: flag, tls_hostname: hostname, ssl_context_params: nil) + # Net::SMTP.new(address, port, tls_verify: flag, tls_hostname: hostname, ssl_context_params: nil) + # .start(helo: helo_domain, user: account, secret: password, authtype: authtype) + # + # See also: Net::SMTP.new, #start # # === Example # @@ -907,12 +918,6 @@ class Net::SMTP < ::Net::Protocol # +helo+ is the _HELO_ _domain_ provided by the client to the # server (see overview comments); it defaults to 'localhost'. # - # The remaining arguments are used for SMTP authentication, if required - # or desired. +user+ is the account name; +secret+ is your password - # or other authentication token; and +authtype+ is the authentication - # type, one of :plain, :login, or :cram_md5. See the discussion of - # SMTP Authentication in the overview notes. - # # If +tls+ is true, enable TLS. The default is false. # If +starttls+ is :always, enable STARTTLS, if +:auto+, use STARTTLS when the server supports it, # if false, disable STARTTLS. @@ -921,10 +926,26 @@ class Net::SMTP < ::Net::Protocol # If the hostname in the server certificate is different from +address+, # it can be specified with +tls_hostname+. # - # Additional SSLContext params can be added to +ssl_context_params+ hash argument and are passed to - # +OpenSSL::SSL::SSLContext#set_params+ + # Additional SSLContext[https://ruby.github.io/openssl/OpenSSL/SSL/SSLContext.html] + # params can be added to the +ssl_context_params+ hash argument and are + # passed to {OpenSSL::SSL::SSLContext#set_params}[https://ruby.github.io/openssl/OpenSSL/SSL/SSLContext.html#method-i-set_params]. + # + # tls_verify: true is equivalent to ssl_context_params: { + # verify_mode: OpenSSL::SSL::VERIFY_PEER }. + # + # The remaining arguments are used for \SMTP authentication, if required or + # desired. + # + # +authtype+ is the SASL authentication mechanism. + # + # +user+ is the authentication or authorization identity. + # + # +secret+ or +password+ is your password or other authentication token. + # + # These will be sent to #authenticate as positional arguments-the exact + # semantics are dependent on the +authtype+. # - # +tls_verify: true+ is equivalent to +ssl_context_params: { verify_mode: OpenSSL::SSL::VERIFY_PEER }+. + # See the discussion of Net::SMTP@SMTP+Authentication in the overview notes. # # === Errors # @@ -941,14 +962,14 @@ class Net::SMTP < ::Net::Protocol # # @raise [ArgumentError] # - # source://net-smtp//lib/net/smtp.rb#518 + # source://net-smtp//lib/net/smtp.rb#539 def start(address, port = T.unsafe(nil), *args, helo: T.unsafe(nil), user: T.unsafe(nil), secret: T.unsafe(nil), password: T.unsafe(nil), authtype: T.unsafe(nil), tls: T.unsafe(nil), starttls: T.unsafe(nil), tls_verify: T.unsafe(nil), tls_hostname: T.unsafe(nil), ssl_context_params: T.unsafe(nil), &block); end end end # Address with parametres for MAIL or RCPT command # -# source://net-smtp//lib/net/smtp.rb#1182 +# source://net-smtp//lib/net/smtp.rb#1130 class Net::SMTP::Address # :call-seq: # initialize(address, parameter, ...) @@ -958,36 +979,132 @@ class Net::SMTP::Address # # @return [Address] a new instance of Address # - # source://net-smtp//lib/net/smtp.rb#1193 + # source://net-smtp//lib/net/smtp.rb#1141 def initialize(address, *args, **kw_args); end # mail address [String] # - # source://net-smtp//lib/net/smtp.rb#1184 + # source://net-smtp//lib/net/smtp.rb#1132 def address; end # parameters [Array] # - # source://net-smtp//lib/net/smtp.rb#1186 + # source://net-smtp//lib/net/smtp.rb#1134 def parameters; end - # source://net-smtp//lib/net/smtp.rb#1203 + # source://net-smtp//lib/net/smtp.rb#1152 def to_s; end end +# source://net-smtp//lib/net/smtp/auth_cram_md5.rb#9 +class Net::SMTP::AuthCramMD5 < ::Net::SMTP::Authenticator + # source://net-smtp//lib/net/smtp/auth_cram_md5.rb#12 + def auth(user, secret); end + + # CRAM-MD5: [RFC2195] + # + # source://net-smtp//lib/net/smtp/auth_cram_md5.rb#22 + def cram_md5_response(secret, challenge); end + + # source://net-smtp//lib/net/smtp/auth_cram_md5.rb#29 + def cram_secret(secret, mask); end + + # source://net-smtp//lib/net/smtp/auth_cram_md5.rb#38 + def digest_class; end +end + +# source://net-smtp//lib/net/smtp/auth_cram_md5.rb#27 +Net::SMTP::AuthCramMD5::CRAM_BUFSIZE = T.let(T.unsafe(nil), Integer) + +# source://net-smtp//lib/net/smtp/auth_cram_md5.rb#18 +Net::SMTP::AuthCramMD5::IMASK = T.let(T.unsafe(nil), Integer) + +# source://net-smtp//lib/net/smtp/auth_cram_md5.rb#19 +Net::SMTP::AuthCramMD5::OMASK = T.let(T.unsafe(nil), Integer) + +# source://net-smtp//lib/net/smtp/auth_login.rb#2 +class Net::SMTP::AuthLogin < ::Net::SMTP::Authenticator + # source://net-smtp//lib/net/smtp/auth_login.rb#5 + def auth(user, secret); end +end + +# source://net-smtp//lib/net/smtp/auth_plain.rb#2 +class Net::SMTP::AuthPlain < ::Net::SMTP::Authenticator + # source://net-smtp//lib/net/smtp/auth_plain.rb#5 + def auth(user, secret); end +end + +# source://net-smtp//lib/net/smtp/auth_xoauth2.rb#2 +class Net::SMTP::AuthXoauth2 < ::Net::SMTP::Authenticator + # source://net-smtp//lib/net/smtp/auth_xoauth2.rb#5 + def auth(user, secret); end + + private + + # source://net-smtp//lib/net/smtp/auth_xoauth2.rb#13 + def xoauth2_string(user, secret); end +end + +# source://net-smtp//lib/net/smtp/authenticator.rb#3 +class Net::SMTP::Authenticator + # @return [Authenticator] a new instance of Authenticator + # + # source://net-smtp//lib/net/smtp/authenticator.rb#29 + def initialize(smtp); end + + # @param str [String] + # @return [String] Base64 encoded string + # + # source://net-smtp//lib/net/smtp/authenticator.rb#51 + def base64_encode(str); end + + # @param arg [String] message to server + # @raise [res.exception_class] + # @return [String] message from server + # + # source://net-smtp//lib/net/smtp/authenticator.rb#35 + def continue(arg); end + + # @param arg [String] message to server + # @raise [SMTPAuthenticationError] + # @return [Net::SMTP::Response] response from server + # + # source://net-smtp//lib/net/smtp/authenticator.rb#43 + def finish(arg); end + + # Returns the value of attribute smtp. + # + # source://net-smtp//lib/net/smtp/authenticator.rb#27 + def smtp; end + + class << self + # source://net-smtp//lib/net/smtp/authenticator.rb#13 + def auth_class(type); end + + # source://net-smtp//lib/net/smtp/authenticator.rb#4 + def auth_classes; end + + # source://net-smtp//lib/net/smtp/authenticator.rb#8 + def auth_type(type); end + + # source://net-smtp//lib/net/smtp/authenticator.rb#18 + def check_args(user_arg = T.unsafe(nil), secret_arg = T.unsafe(nil), *_arg2, **_arg3); end + end +end + # This class represents a response received by the SMTP server. Instances # of this class are created by the SMTP class; they should not be directly # created by the user. For more information on SMTP responses, view # {Section 4.2 of RFC 5321}[http://tools.ietf.org/html/rfc5321#section-4.2] # -# source://net-smtp//lib/net/smtp.rb#1102 +# source://net-smtp//lib/net/smtp.rb#1050 class Net::SMTP::Response # Creates a new instance of the Response class and sets the status and # string attributes # # @return [Response] a new instance of Response # - # source://net-smtp//lib/net/smtp.rb#1111 + # source://net-smtp//lib/net/smtp.rb#1059 def initialize(status, string); end # Returns a hash of the human readable reply text in the response if it @@ -995,7 +1112,7 @@ class Net::SMTP::Response # hash is the first word the value of the hash is an array with each word # thereafter being a value in the array # - # source://net-smtp//lib/net/smtp.rb#1154 + # source://net-smtp//lib/net/smtp.rb#1102 def capabilities; end # Determines whether the response received was a Positive Intermediate @@ -1003,39 +1120,39 @@ class Net::SMTP::Response # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#1135 + # source://net-smtp//lib/net/smtp.rb#1083 def continue?; end # Creates a CRAM-MD5 challenge. You can view more information on CRAM-MD5 # on Wikipedia: https://en.wikipedia.org/wiki/CRAM-MD5 # - # source://net-smtp//lib/net/smtp.rb#1146 + # source://net-smtp//lib/net/smtp.rb#1094 def cram_md5_challenge; end # Determines whether there was an error and raises the appropriate error # based on the reply code of the response # - # source://net-smtp//lib/net/smtp.rb#1166 + # source://net-smtp//lib/net/smtp.rb#1114 def exception_class; end # The first line of the human readable reply text # - # source://net-smtp//lib/net/smtp.rb#1140 + # source://net-smtp//lib/net/smtp.rb#1088 def message; end # The three digit reply code of the SMTP response # - # source://net-smtp//lib/net/smtp.rb#1117 + # source://net-smtp//lib/net/smtp.rb#1065 def status; end # Takes the first digit of the reply code to determine the status type # - # source://net-smtp//lib/net/smtp.rb#1123 + # source://net-smtp//lib/net/smtp.rb#1071 def status_type_char; end # The human readable reply text of the SMTP response # - # source://net-smtp//lib/net/smtp.rb#1120 + # source://net-smtp//lib/net/smtp.rb#1068 def string; end # Determines whether the response received was a Positive Completion @@ -1043,69 +1160,69 @@ class Net::SMTP::Response # # @return [Boolean] # - # source://net-smtp//lib/net/smtp.rb#1129 + # source://net-smtp//lib/net/smtp.rb#1077 def success?; end class << self # Parses the received response and separates the reply code and the human # readable reply text # - # source://net-smtp//lib/net/smtp.rb#1105 + # source://net-smtp//lib/net/smtp.rb#1053 def parse(str); end end end -# source://net-smtp//lib/net/smtp.rb#189 +# source://net-smtp//lib/net/smtp.rb#195 Net::SMTP::VERSION = T.let(T.unsafe(nil), String) -# source://net-smtp//lib/net/smtp.rb#55 +# source://net-smtp//lib/net/smtp.rb#49 class Net::SMTPAuthenticationError < ::Net::ProtoAuthError include ::Net::SMTPError end # Module mixed in to all SMTP error classes # -# source://net-smtp//lib/net/smtp.rb#33 +# source://net-smtp//lib/net/smtp.rb#27 module Net::SMTPError - # source://net-smtp//lib/net/smtp.rb#39 + # source://net-smtp//lib/net/smtp.rb#33 def initialize(response, message: T.unsafe(nil)); end - # source://net-smtp//lib/net/smtp.rb#49 + # source://net-smtp//lib/net/smtp.rb#43 def message; end # This *class* is a module for backward compatibility. # In later release, this module becomes a class. # - # source://net-smtp//lib/net/smtp.rb#37 + # source://net-smtp//lib/net/smtp.rb#31 def response; end end -# source://net-smtp//lib/net/smtp.rb#70 +# source://net-smtp//lib/net/smtp.rb#64 class Net::SMTPFatalError < ::Net::ProtoFatalError include ::Net::SMTPError end -# source://net-smtp//lib/net/smtp.rb#60 +# source://net-smtp//lib/net/smtp.rb#54 class Net::SMTPServerBusy < ::Net::ProtoServerError include ::Net::SMTPError end # class SMTP # -# source://net-smtp//lib/net/smtp.rb#1210 +# source://net-smtp//lib/net/smtp.rb#1158 Net::SMTPSession = Net::SMTP -# source://net-smtp//lib/net/smtp.rb#65 +# source://net-smtp//lib/net/smtp.rb#59 class Net::SMTPSyntaxError < ::Net::ProtoSyntaxError include ::Net::SMTPError end -# source://net-smtp//lib/net/smtp.rb#75 +# source://net-smtp//lib/net/smtp.rb#69 class Net::SMTPUnknownError < ::Net::ProtoUnknownError include ::Net::SMTPError end -# source://net-smtp//lib/net/smtp.rb#80 +# source://net-smtp//lib/net/smtp.rb#74 class Net::SMTPUnsupportedCommand < ::Net::ProtocolError include ::Net::SMTPError end diff --git a/sorbet/rbi/gems/net-ssh@7.1.0.rbi b/sorbet/rbi/gems/net-ssh@7.2.3.rbi similarity index 96% rename from sorbet/rbi/gems/net-ssh@7.1.0.rbi rename to sorbet/rbi/gems/net-ssh@7.2.3.rbi index c2b5ecca3..2fc19fbea 100644 --- a/sorbet/rbi/gems/net-ssh@7.1.0.rbi +++ b/sorbet/rbi/gems/net-ssh@7.2.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `net-ssh` gem. # Please instead update this file by running `bin/tapioca gem net-ssh`. + # Net::SSH is a library for interacting, programmatically, with remote # processes via the SSH2 protocol. Sessions are always initiated via # Net::SSH.start. From there, a program interacts with the new SSH session @@ -52,7 +53,7 @@ # source://net-ssh//lib/net/ssh/config.rb#2 module Net::SSH class << self - # source://net-ssh//lib/net/ssh.rb#295 + # source://net-ssh//lib/net/ssh.rb#298 def assign_defaults(options); end # Returns a hash of the configuration options for the given host, as read @@ -65,7 +66,7 @@ module Net::SSH # # See Net::SSH::Config for the full description of all supported options. # - # source://net-ssh//lib/net/ssh.rb#285 + # source://net-ssh//lib/net/ssh.rb#288 def configuration_for(host, use_ssh_config); end # The standard means of starting a new SSH connection. When used with a @@ -138,6 +139,8 @@ module Net::SSH # and hostbased authentication # * :keycerts => an array of file names of key certificates to use # with publickey authentication + # * :keycert_data => an array of strings, which each element of the array + # being a key certificate to use with publickey authentication # * :key_data => an array of strings, with each element of the array being # a raw private key in PEM format. # * :keys_only => set to +true+ to use only private keys from +keys+ and @@ -184,6 +187,7 @@ module Net::SSH # Defaults to %w(~/.ssh/known_hosts ~/.ssh/known_hosts2). # * :use_agent => Set false to disable the use of ssh-agent. Defaults to # true + # * :identity_agent => the path to the ssh-agent's UNIX socket # * :verbose => how verbose to be (Logger verbosity constants, Logger::DEBUG # is very verbose, Logger::FATAL is all but silent). Logger::FATAL is the # default. The symbols :debug, :info, :warn, :error, and :fatal are also @@ -212,15 +216,15 @@ module Net::SSH # If +user+ parameter is nil it defaults to USER from ssh_config, or # local username # - # source://net-ssh//lib/net/ssh.rb#222 + # source://net-ssh//lib/net/ssh.rb#225 def start(host, user = T.unsafe(nil), options = T.unsafe(nil), &block); end private - # source://net-ssh//lib/net/ssh.rb#308 + # source://net-ssh//lib/net/ssh.rb#311 def _sanitize_options(options); end - # source://net-ssh//lib/net/ssh.rb#317 + # source://net-ssh//lib/net/ssh.rb#320 def _support_deprecated_option_paranoid(options); end end end @@ -736,130 +740,130 @@ Net::SSH::Authentication::Constants::USERAUTH_SUCCESS = T.let(T.unsafe(nil), Int # source://net-ssh//lib/net/ssh/authentication/session.rb#15 class Net::SSH::Authentication::DisallowedMethod < ::Net::SSH::Exception; end -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#15 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#13 module Net::SSH::Authentication::ED25519; end -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#25 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#23 class Net::SSH::Authentication::ED25519::OpenSSHPrivateKeyLoader class << self # @raise [ArgumentError] # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#43 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#41 def read(datafull, password); end end end -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#26 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#24 Net::SSH::Authentication::ED25519::OpenSSHPrivateKeyLoader::CipherFactory = Net::SSH::Transport::CipherFactory -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#32 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#30 class Net::SSH::Authentication::ED25519::OpenSSHPrivateKeyLoader::DecryptError < ::ArgumentError # @return [DecryptError] a new instance of DecryptError # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#33 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#31 def initialize(message, encrypted_key: T.unsafe(nil)); end # @return [Boolean] # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#38 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#36 def encrypted_key?; end end -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#30 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#28 Net::SSH::Authentication::ED25519::OpenSSHPrivateKeyLoader::MAGIC = T.let(T.unsafe(nil), String) -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#28 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#26 Net::SSH::Authentication::ED25519::OpenSSHPrivateKeyLoader::MBEGIN = T.let(T.unsafe(nil), String) -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#29 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#27 Net::SSH::Authentication::ED25519::OpenSSHPrivateKeyLoader::MEND = T.let(T.unsafe(nil), String) -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#141 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#139 class Net::SSH::Authentication::ED25519::PrivKey # @return [PrivKey] a new instance of PrivKey # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#150 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#148 def initialize(buffer); end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#171 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#169 def public_key; end # Returns the value of attribute sign_key. # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#148 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#146 def sign_key; end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#175 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#173 def ssh_do_sign(data, sig_alg = T.unsafe(nil)); end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#167 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#165 def ssh_signature_type; end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#163 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#161 def ssh_type; end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#159 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#157 def to_blob; end class << self - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#179 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#177 def read(data, password); end end end -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#142 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#140 Net::SSH::Authentication::ED25519::PrivKey::CipherFactory = Net::SSH::Transport::CipherFactory -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#146 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#144 Net::SSH::Authentication::ED25519::PrivKey::MAGIC = T.let(T.unsafe(nil), String) -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#144 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#142 Net::SSH::Authentication::ED25519::PrivKey::MBEGIN = T.let(T.unsafe(nil), String) -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#145 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#143 Net::SSH::Authentication::ED25519::PrivKey::MEND = T.let(T.unsafe(nil), String) -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#106 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#104 class Net::SSH::Authentication::ED25519::PubKey include ::Net::SSH::Authentication::PubKeyFingerprint # @return [PubKey] a new instance of PubKey # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#111 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#109 def initialize(data); end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#131 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#129 def ssh_do_verify(sig, data, options = T.unsafe(nil)); end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#127 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#125 def ssh_signature_type; end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#123 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#121 def ssh_type; end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#119 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#117 def to_blob; end - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#135 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#133 def to_pem; end # Returns the value of attribute verify_key. # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#109 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#107 def verify_key; end class << self - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#115 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#113 def read_keyblob(buffer); end end end -# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#16 +# source://net-ssh//lib/net/ssh/authentication/ed25519.rb#14 class Net::SSH::Authentication::ED25519::SigningKeyFromFile < ::SimpleDelegator # @raise [ArgumentError] # @return [SigningKeyFromFile] a new instance of SigningKeyFromFile # - # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#17 + # source://net-ssh//lib/net/ssh/authentication/ed25519.rb#15 def initialize(pk, sk); end end @@ -907,29 +911,34 @@ class Net::SSH::Authentication::KeyManager # # @return [KeyManager] a new instance of KeyManager # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#44 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#47 def initialize(logger, options = T.unsafe(nil)); end # Add the given key_file to the list of key files that will be used. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#67 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#72 def add(key_file); end # Add the given key_file to the list of keys that will be used. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#79 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#90 def add_key_data(key_data_); end # Add the given keycert_file to the list of keycert files that will be used. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#73 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#78 def add_keycert(keycert_file); end + # Add the given keycert_data to the list of keycerts that will be used. + # + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#84 + def add_keycert_data(keycert_data_); end + # Returns an Agent instance to use for communicating with an SSH # agent process. Returns nil if use of an SSH agent has been disabled, # or if the agent is otherwise not available. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#215 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#226 def agent; end # Clear all knowledge of any loaded user keys. This also clears the list @@ -937,7 +946,7 @@ class Net::SSH::Authentication::KeyManager # appropriate to use if a client wishes to NOT use the default identity # files. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#59 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#63 def clear!; end # Iterates over all available identities (public keys) known to this @@ -950,7 +959,7 @@ class Net::SSH::Authentication::KeyManager # from ssh-agent will be ignored unless it present in key_files or # key_data. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#107 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#118 def each_identity; end # This is used as a hint to the KeyManager indicating that the agent @@ -963,7 +972,7 @@ class Net::SSH::Authentication::KeyManager # reconnected. This method simply allows the client connection to be # closed when it will not be used in the immediate future. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#93 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#104 def finish; end # The list of user key data that will be examined @@ -976,6 +985,11 @@ class Net::SSH::Authentication::KeyManager # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#27 def key_files; end + # The list of user key certificate data that will be examined + # + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#36 + def keycert_data; end + # The list of user key certificate files that will be examined # # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#33 @@ -983,17 +997,17 @@ class Net::SSH::Authentication::KeyManager # The map of loaded identities # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#36 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#39 def known_identities; end # @return [Boolean] # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#224 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#235 def no_keys?; end # The map of options that were passed to the key-manager # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#39 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#42 def options; end # Sign the given data, using the corresponding private key of the given @@ -1008,46 +1022,51 @@ class Net::SSH::Authentication::KeyManager # # @raise [KeyManagerError] # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#161 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#172 def sign(identity, data, sig_alg = T.unsafe(nil)); end # Toggles whether the ssh-agent will be used or not. If true, an # attempt will be made to use the ssh-agent. If false, any existing # connection to an agent is closed and the agent will not be used. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#207 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#218 def use_agent=(use_agent); end # Identifies whether the ssh-agent will be used or not. # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#200 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#211 def use_agent?; end private + # Load keycerts from files and data. + # + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#242 + def keycerts; end + # Load prepared identities. Private key decryption errors ignored if ignore_decryption_errors # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#263 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#280 def load_identities(identities, ask_passphrase, ignore_decryption_errors); end # Prepared identities from user key_data, preserving their order and sources. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#256 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#273 def prepare_identities_from_data; end # Prepares identities from user key_files for loading, preserving their order and sources. # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#231 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#248 def prepare_identities_from_files; end - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#297 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#314 def process_identity_loading_error(identity, e); end # @return [Boolean] # - # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#251 + # source://net-ssh//lib/net/ssh/authentication/key_manager.rb#268 def readable_file?(path); end end @@ -1316,14 +1335,14 @@ class Net::SSH::Authentication::Session # # @raise [Net::SSH::Exception] # - # source://net-ssh//lib/net/ssh/authentication/session.rb#129 + # source://net-ssh//lib/net/ssh/authentication/session.rb#130 def expect_message(type); end # Blocks until a packet is received. It silently handles USERAUTH_BANNER # packets, and will raise an error if any packet is received that is not # valid during user authentication. # - # source://net-ssh//lib/net/ssh/authentication/session.rb#100 + # source://net-ssh//lib/net/ssh/authentication/session.rb#101 def next_message; end # a hash of options, given at construction time @@ -1341,25 +1360,31 @@ class Net::SSH::Authentication::Session # Returns an array of paths to the key files usually defined # by system default. # - # source://net-ssh//lib/net/ssh/authentication/session.rb#140 + # source://net-ssh//lib/net/ssh/authentication/session.rb#141 def default_keys; end # Returns an array of the key data that should be used when # attempting any key-based authentication mechanism. # - # source://net-ssh//lib/net/ssh/authentication/session.rb#159 + # source://net-ssh//lib/net/ssh/authentication/session.rb#166 def key_data; end + # Returns an array of the keycert data that should be used when + # attempting any key-based authentication mechanism. + # + # source://net-ssh//lib/net/ssh/authentication/session.rb#160 + def keycert_data; end + # Returns an array of paths to the keycert files that should be used when # attempting any key-based authentication mechanism. # - # source://net-ssh//lib/net/ssh/authentication/session.rb#153 + # source://net-ssh//lib/net/ssh/authentication/session.rb#154 def keycerts; end # Returns an array of paths to the key files that should be used when # attempting any key-based authentication mechanism. # - # source://net-ssh//lib/net/ssh/authentication/session.rb#147 + # source://net-ssh//lib/net/ssh/authentication/session.rb#148 def keys; end end @@ -3547,51 +3572,51 @@ module Net::SSH::ForwardedBufferedIo def send_pending; end end -# source://net-ssh//lib/net/ssh/known_hosts.rb#10 +# source://net-ssh//lib/net/ssh/known_hosts.rb#9 module Net::SSH::HostKeyEntries; end # @cert-authority entry # -# source://net-ssh//lib/net/ssh/known_hosts.rb#41 +# source://net-ssh//lib/net/ssh/known_hosts.rb#40 class Net::SSH::HostKeyEntries::CertAuthority # @return [CertAuthority] a new instance of CertAuthority # - # source://net-ssh//lib/net/ssh/known_hosts.rb#53 + # source://net-ssh//lib/net/ssh/known_hosts.rb#52 def initialize(key, comment: T.unsafe(nil)); end # @return [Boolean] # - # source://net-ssh//lib/net/ssh/known_hosts.rb#58 + # source://net-ssh//lib/net/ssh/known_hosts.rb#57 def matches_key?(server_key); end - # source://net-ssh//lib/net/ssh/known_hosts.rb#42 + # source://net-ssh//lib/net/ssh/known_hosts.rb#41 def ssh_types; end end # regular public key entry # -# source://net-ssh//lib/net/ssh/known_hosts.rb#12 +# source://net-ssh//lib/net/ssh/known_hosts.rb#11 class Net::SSH::HostKeyEntries::PubKey # @return [PubKey] a new instance of PubKey # - # source://net-ssh//lib/net/ssh/known_hosts.rb#13 + # source://net-ssh//lib/net/ssh/known_hosts.rb#12 def initialize(key, comment: T.unsafe(nil)); end - # source://net-ssh//lib/net/ssh/known_hosts.rb#30 + # source://net-ssh//lib/net/ssh/known_hosts.rb#29 def __getobj__; end # @return [Boolean] # - # source://net-ssh//lib/net/ssh/known_hosts.rb#35 + # source://net-ssh//lib/net/ssh/known_hosts.rb#34 def matches_key?(server_key); end - # source://net-ssh//lib/net/ssh/known_hosts.rb#18 + # source://net-ssh//lib/net/ssh/known_hosts.rb#17 def ssh_type; end - # source://net-ssh//lib/net/ssh/known_hosts.rb#22 + # source://net-ssh//lib/net/ssh/known_hosts.rb#21 def ssh_types; end - # source://net-ssh//lib/net/ssh/known_hosts.rb#26 + # source://net-ssh//lib/net/ssh/known_hosts.rb#25 def to_blob; end end @@ -3671,29 +3696,29 @@ class Net::SSH::HostKeyUnknown < ::Net::SSH::HostKeyError; end # Represents the result of a search in known hosts # see search_for # -# source://net-ssh//lib/net/ssh/known_hosts.rb#70 +# source://net-ssh//lib/net/ssh/known_hosts.rb#69 class Net::SSH::HostKeys include ::Enumerable # @return [HostKeys] a new instance of HostKeys # - # source://net-ssh//lib/net/ssh/known_hosts.rb#74 + # source://net-ssh//lib/net/ssh/known_hosts.rb#73 def initialize(host_keys, host, known_hosts, options = T.unsafe(nil)); end - # source://net-ssh//lib/net/ssh/known_hosts.rb#81 + # source://net-ssh//lib/net/ssh/known_hosts.rb#80 def add_host_key(key); end - # source://net-ssh//lib/net/ssh/known_hosts.rb#86 + # source://net-ssh//lib/net/ssh/known_hosts.rb#85 def each(&block); end # @return [Boolean] # - # source://net-ssh//lib/net/ssh/known_hosts.rb#90 + # source://net-ssh//lib/net/ssh/known_hosts.rb#89 def empty?; end # Returns the value of attribute host. # - # source://net-ssh//lib/net/ssh/known_hosts.rb#72 + # source://net-ssh//lib/net/ssh/known_hosts.rb#71 def host; end end @@ -3772,21 +3797,21 @@ Net::SSH::KeyFactory::MAP = T.let(T.unsafe(nil), Hash) # This is used internally by Net::SSH, and will never need to be used directly # by consumers of the library. # -# source://net-ssh//lib/net/ssh/known_hosts.rb#101 +# source://net-ssh//lib/net/ssh/known_hosts.rb#100 class Net::SSH::KnownHosts # Instantiate a new KnownHosts instance that will search the given known-hosts # file. The path is expanded file File.expand_path. # # @return [KnownHosts] a new instance of KnownHosts # - # source://net-ssh//lib/net/ssh/known_hosts.rb#162 + # source://net-ssh//lib/net/ssh/known_hosts.rb#161 def initialize(source); end # Tries to append an entry to the current source file for the given host # and key. If it is unable to (because the file is not writable, for # instance), an exception will be raised. # - # source://net-ssh//lib/net/ssh/known_hosts.rb#257 + # source://net-ssh//lib/net/ssh/known_hosts.rb#256 def add(host, key); end # Returns an array of all keys that are known to be associatd with the @@ -3803,7 +3828,7 @@ class Net::SSH::KnownHosts # "[1,2,3,4]:5555" # "[net.ssh.test]:5555,[1.2.3.4]:5555 # - # source://net-ssh//lib/net/ssh/known_hosts.rb#179 + # source://net-ssh//lib/net/ssh/known_hosts.rb#178 def keys_for(host, options = T.unsafe(nil)); end # Indicates whether one of the entries matches an hostname that has been @@ -3811,16 +3836,16 @@ class Net::SSH::KnownHosts # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/known_hosts.rb#241 + # source://net-ssh//lib/net/ssh/known_hosts.rb#240 def known_host_hash?(hostlist, entries); end - # source://net-ssh//lib/net/ssh/known_hosts.rb#224 + # source://net-ssh//lib/net/ssh/known_hosts.rb#223 def match(host, pattern); end # The host-key file name that this KnownHosts instance will use to search # for keys. # - # source://net-ssh//lib/net/ssh/known_hosts.rb#158 + # source://net-ssh//lib/net/ssh/known_hosts.rb#157 def source; end class << self @@ -3828,7 +3853,7 @@ class Net::SSH::KnownHosts # add an entry for the given host and key to the first file it is able # to. # - # source://net-ssh//lib/net/ssh/known_hosts.rb#146 + # source://net-ssh//lib/net/ssh/known_hosts.rb#145 def add(host, key, options = T.unsafe(nil)); end # Looks in the given +options+ hash for the :user_known_hosts_file and @@ -3841,24 +3866,24 @@ class Net::SSH::KnownHosts # If you only want the user known host files, you can pass :user as # the second option. # - # source://net-ssh//lib/net/ssh/known_hosts.rb#131 + # source://net-ssh//lib/net/ssh/known_hosts.rb#130 def hostfiles(options, which = T.unsafe(nil)); end # Searches all known host files (see KnownHosts.hostfiles) for all keys # of the given host. Returns an enumerable of keys found. # - # source://net-ssh//lib/net/ssh/known_hosts.rb#112 + # source://net-ssh//lib/net/ssh/known_hosts.rb#111 def search_for(host, options = T.unsafe(nil)); end # Search for all known keys for the given host, in every file given in # the +files+ array. Returns the list of keys. # - # source://net-ssh//lib/net/ssh/known_hosts.rb#118 + # source://net-ssh//lib/net/ssh/known_hosts.rb#117 def search_in(files, host, options = T.unsafe(nil)); end end end -# source://net-ssh//lib/net/ssh/known_hosts.rb#102 +# source://net-ssh//lib/net/ssh/known_hosts.rb#101 Net::SSH::KnownHosts::SUPPORTED_TYPE = T.let(T.unsafe(nil), Array) # A simple module to make logging easier to deal with. It assumes that the @@ -4379,13 +4404,13 @@ class Net::SSH::Transport::Algorithms # # @return [Algorithms] a new instance of Algorithms # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#149 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#154 def initialize(session, options = T.unsafe(nil)); end # A convenience method for accessing the list of preferred types for a # specific algorithm (see #algorithms). # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#193 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#198 def [](key); end # Called by the transport layer when a KEXINIT packet is received, indicating @@ -4393,13 +4418,13 @@ class Net::SSH::Transport::Algorithms # can be in response to a client-initiated rekey request (see #rekey!). Either # way, this will block until the key exchange completes. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#180 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#185 def accept_kexinit(packet); end # The hash of algorithms preferred by the client, which will be told to # the server during algorithm negotiation. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#135 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#140 def algorithms; end # Returns true if no exchange is pending, and otherwise returns true or @@ -4408,73 +4433,73 @@ class Net::SSH::Transport::Algorithms # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#209 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#214 def allow?(packet); end # The type of compression to use to compress packets being sent by the client. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#122 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#127 def compression_client; end # The type of compression to use to decompress packets arriving from the server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#125 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#130 def compression_server; end # The type of the cipher to use to encrypt packets sent from the client to # the server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#110 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#115 def encryption_client; end # The type of the cipher to use to decrypt packets arriving from the server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#113 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#118 def encryption_server; end # The type of HMAC to use to sign packets sent by the client. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#116 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#121 def hmac_client; end # The type of HMAC to use to validate packets arriving from the server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#119 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#124 def hmac_server; end # The type of host key that will be used for this session. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#106 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#111 def host_key; end - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#218 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#223 def host_key_format; end # Returns true if the algorithms have been negotiated at all. # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#214 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#219 def initialized?; end # The kex algorithm to use settled on between the client and server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#103 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#108 def kex; end # The language that will be used in messages sent by the client. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#128 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#133 def language_client; end # The language that will be used in messages sent from the server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#131 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#136 def language_server; end # The hash of options used to initialize this object # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#100 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#105 def options; end # Returns +true+ if a key-exchange is pending. This will be true from the @@ -4485,7 +4510,7 @@ class Net::SSH::Transport::Algorithms # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#202 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#207 def pending?; end # Request a rekey operation. This will return immediately, and does not @@ -4493,24 +4518,24 @@ class Net::SSH::Transport::Algorithms # state, however--until the key exchange finishes, no new packets will be # processed. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#170 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#175 def rekey!; end # The underlying transport layer session that supports this object # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#97 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#102 def session; end # The session-id for this session, as decided during the initial key exchange. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#138 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#143 def session_id; end # Start the algorithm negotation # # @raise [ArgumentError] # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#160 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#165 def start; end private @@ -4519,12 +4544,12 @@ class Net::SSH::Transport::Algorithms # a KEXINIT packet to send to the server. It does not actually send it, # it simply builds the packet and returns it. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#363 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#368 def build_client_algorithm_packet; end # Composes the list of algorithms by taking supported algorithms and matching with supplied options. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#290 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#295 def compose_algorithm_list(supported, option, append_all_supported_algorithms = T.unsafe(nil)); end # Instantiates one of the Transport::Kex classes (based on the negotiated @@ -4532,21 +4557,21 @@ class Net::SSH::Transport::Algorithms # HMACs are initialized and fed to the transport layer, to be used in # further communication with the server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#437 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#442 def exchange_keys; end # Considers the sizes of the keys and block-sizes for the selected ciphers, # and the lengths of the hmacs, and returns the largest as the byte requirement # for the key-exchange algorithm. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#421 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#426 def kex_byte_requirement; end # Negotiates a single algorithm based on the preferences reported by the # server and those set by the client. This is called by # #negotiate_algorithms. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#406 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#411 def negotiate(algorithm); end # Given the parsed server KEX packet, and the client's preferred algorithm @@ -4554,18 +4579,18 @@ class Net::SSH::Transport::Algorithms # in common and set those as the selected algorithms. If, for any algorithm, # no type can be settled on, an exception is raised. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#382 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#387 def negotiate_algorithms; end # Given the SSH name for some compression algorithm, return a normalized # name as a symbol. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#491 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#513 def normalize_compression_name(name); end # Parses a KEXINIT packet from the server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#336 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#341 def parse_server_algorithm_packet(packet); end # Prepares the list of preferred algorithms, based on the options hash @@ -4575,14 +4600,14 @@ class Net::SSH::Transport::Algorithms # before, and if so, that key type is used as the preferred type for # communicating with this server. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#258 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#263 def prepare_preferred_algorithms!; end # After both client and server have sent their KEXINIT packets, this # will do the algorithm negotiation and key exchange. Once both finish, # the object leaves the pending state and the method returns. # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#245 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#250 def proceed!; end # Sends a KEXINIT packet to the server. If a server KEXINIT has already @@ -4590,7 +4615,7 @@ class Net::SSH::Transport::Algorithms # exchange, otherwise it returns immediately (but sets the object to the # pending state). # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#233 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#238 def send_kexinit; end class << self @@ -4598,14 +4623,14 @@ class Net::SSH::Transport::Algorithms # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/transport/algorithms.rb#141 + # source://net-ssh//lib/net/ssh/transport/algorithms.rb#146 def allowed_packet?(packet); end end end # Define all algorithms, with the deprecated, supported by Net::SSH. # -# source://net-ssh//lib/net/ssh/transport/algorithms.rb#69 +# source://net-ssh//lib/net/ssh/transport/algorithms.rb#74 Net::SSH::Transport::Algorithms::ALGORITHMS = T.let(T.unsafe(nil), Hash) # Define the default algorithms, in order of preference, supported by Net::SSH. @@ -4626,9 +4651,20 @@ module Net::SSH::Transport::CTR end end +# Loads chacha20 poly1305 support which requires optinal dependency rbnacl +# +# source://net-ssh//lib/net/ssh/transport/chacha20_poly1305_cipher_loader.rb#5 +module Net::SSH::Transport::ChaCha20Poly1305CipherLoader; end + +# source://net-ssh//lib/net/ssh/transport/chacha20_poly1305_cipher_loader.rb#11 +Net::SSH::Transport::ChaCha20Poly1305CipherLoader::ERROR = T.let(T.unsafe(nil), LoadError) + +# source://net-ssh//lib/net/ssh/transport/chacha20_poly1305_cipher_loader.rb#12 +Net::SSH::Transport::ChaCha20Poly1305CipherLoader::LOADED = T.let(T.unsafe(nil), FalseClass) + # Implements a factory of OpenSSL cipher algorithms. # -# source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#10 +# source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#12 class Net::SSH::Transport::CipherFactory class << self # Retrieves a new instance of the named algorithm. The new instance @@ -4637,7 +4673,7 @@ class Net::SSH::Transport::CipherFactory # cipher will be put into encryption or decryption mode, based on the # value of the +encrypt+ parameter. # - # source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#46 + # source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#60 def get(name, options = T.unsafe(nil)); end # Returns a two-element array containing the [ key-length, @@ -4646,7 +4682,7 @@ class Net::SSH::Transport::CipherFactory # of the tuple. # if :iv_len option is supplied the third return value will be ivlen # - # source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#77 + # source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#99 def get_lengths(name, options = T.unsafe(nil)); end # Returns true if the underlying OpenSSL library supports the given cipher, @@ -4654,14 +4690,17 @@ class Net::SSH::Transport::CipherFactory # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#34 + # source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#46 def supported?(name); end end end +# source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#34 +Net::SSH::Transport::CipherFactory::SSH_TO_CLASS = T.let(T.unsafe(nil), Hash) + # Maps the SSH name of a cipher to it's corresponding OpenSSL name # -# source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#12 +# source://net-ssh//lib/net/ssh/transport/cipher_factory.rb#14 Net::SSH::Transport::CipherFactory::SSH_TO_OSSL = T.let(T.unsafe(nil), Hash) # source://net-ssh//lib/net/ssh/transport/constants.rb#4 @@ -4890,42 +4929,50 @@ class Net::SSH::Transport::IdentityCipher # Does nothing. Returns self. # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#25 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#29 def decrypt; end # Does nothing. Returns self. # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#20 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#24 def encrypt; end # Returns the empty string. # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#35 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#39 def final; end + # @return [Boolean] + # + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#58 + def implicit_mac?; end + # Does nothing. Returns nil. # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#45 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#49 def iv=(v); end # Returns an arbitrary integer. # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#15 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#19 def iv_len; end + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#14 + def key_length; end + # The name of this cipher, which is "identity". # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#40 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#44 def name; end # Does nothing. Returns self. # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#50 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#54 def reset; end # Passes its single argument through unchanged. # - # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#30 + # source://net-ssh//lib/net/ssh/transport/identity_cipher.rb#34 def update(text); end end end @@ -5298,6 +5345,16 @@ class Net::SSH::Transport::OpenSSLAESCTR < ::SimpleDelegator end end +# we add those mehtods to OpenSSL::Chipher instances +# +# source://net-ssh//lib/net/ssh/transport/openssl_cipher_extensions.rb#3 +module Net::SSH::Transport::OpenSSLCipherExtensions + # @return [Boolean] + # + # source://net-ssh//lib/net/ssh/transport/openssl_cipher_extensions.rb#4 + def implicit_mac?; end +end + # A module that builds additional functionality onto the Net::SSH::BufferedIo # module. It adds SSH encryption, compression, and packet validation, as # per the SSH2 protocol. It also adds an abstraction for polling packets, @@ -5318,7 +5375,7 @@ module Net::SSH::Transport::PacketStream # Performs any pending cleanup necessary on the IO and its associated # state objects. (See State#cleanup). # - # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#184 + # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#187 def cleanup; end # The client state object, which encapsulates the algorithms used to build @@ -5354,7 +5411,7 @@ module Net::SSH::Transport::PacketStream # # @return [Boolean] # - # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#192 + # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#195 def if_needs_rekey?; end # Returns the next full packet. If the mode parameter is :nonblock (the @@ -5389,7 +5446,7 @@ module Net::SSH::Transport::PacketStream # Called when this module is used to extend an object. It initializes # the states and generally prepares the object for use as a packet stream. # - # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#204 + # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#207 def initialize_ssh; end # Tries to read the next packet. If there is insufficient data to read @@ -5400,7 +5457,7 @@ module Net::SSH::Transport::PacketStream # # @raise [Net::SSH::Exception] # - # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#218 + # source://net-ssh//lib/net/ssh/transport/packet_stream.rb#221 def poll_next_packet; end class << self @@ -6072,8 +6129,6 @@ class OpenSSL::BN def to_ssh; end end -OpenSSL::BN::CONSTTIME = T.let(T.unsafe(nil), Integer) - # This class is originally defined in the OpenSSL module. As needed, methods # have been added to it by the Net::SSH module for convenience in dealing # with SSH functionality. @@ -6175,8 +6230,6 @@ OpenSSL::PKey::EC::CurveNameAlias = T.let(T.unsafe(nil), Hash) # source://net-ssh//lib/net/ssh/transport/openssl.rb#147 OpenSSL::PKey::EC::CurveNameAliasInv = T.let(T.unsafe(nil), Hash) -OpenSSL::PKey::EC::EXPLICIT_CURVE = T.let(T.unsafe(nil), Integer) - # source://net-ssh//lib/net/ssh/transport/openssl.rb#255 class OpenSSL::PKey::EC::Point # Returns the description of this key type used by the diff --git a/sorbet/rbi/gems/netrc@0.11.0.rbi b/sorbet/rbi/gems/netrc@0.11.0.rbi index 062a5577c..4ae989b9b 100644 --- a/sorbet/rbi/gems/netrc@0.11.0.rbi +++ b/sorbet/rbi/gems/netrc@0.11.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `netrc` gem. # Please instead update this file by running `bin/tapioca gem netrc`. + # source://netrc//lib/netrc.rb#3 class Netrc # @return [Netrc] a new instance of Netrc diff --git a/sorbet/rbi/gems/nio4r@2.5.9.rbi b/sorbet/rbi/gems/nio4r@2.7.3.rbi similarity index 97% rename from sorbet/rbi/gems/nio4r@2.5.9.rbi rename to sorbet/rbi/gems/nio4r@2.7.3.rbi index 665dbd980..1b9cda885 100644 --- a/sorbet/rbi/gems/nio4r@2.5.9.rbi +++ b/sorbet/rbi/gems/nio4r@2.7.3.rbi @@ -4,9 +4,10 @@ # This is an autogenerated file for types exported from the `nio4r` gem. # Please instead update this file by running `bin/tapioca gem nio4r`. + # New I/O for Ruby # -# source://nio4r//lib/nio/version.rb#3 +# source://nio4r//lib/nio/version.rb#8 module NIO class << self # NIO implementation, one of the following (as a string): @@ -14,12 +15,12 @@ module NIO # * libev: as a C extension using libev # * java: using Java NIO # - # source://nio4r//lib/nio.rb#12 + # source://nio4r//lib/nio.rb#21 def engine; end # @return [Boolean] # - # source://nio4r//lib/nio.rb#16 + # source://nio4r//lib/nio.rb#25 def pure?(env = T.unsafe(nil)); end end end @@ -150,7 +151,7 @@ class NIO::ByteBuffer::OverflowError < ::IOError; end # Not enough data remaining in buffer class NIO::ByteBuffer::UnderflowError < ::IOError; end -# source://nio4r//lib/nio.rb#50 +# source://nio4r//lib/nio.rb#59 NIO::ENGINE = T.let(T.unsafe(nil), String) # Monitors watch IO objects for specific events @@ -288,5 +289,5 @@ class NIO::Selector end end -# source://nio4r//lib/nio/version.rb#4 +# source://nio4r//lib/nio/version.rb#9 NIO::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/time@0.2.2.rbi b/sorbet/rbi/gems/nkf@0.2.0.rbi similarity index 50% rename from sorbet/rbi/gems/time@0.2.2.rbi rename to sorbet/rbi/gems/nkf@0.2.0.rbi index 03310474b..174d57862 100644 --- a/sorbet/rbi/gems/time@0.2.2.rbi +++ b/sorbet/rbi/gems/nkf@0.2.0.rbi @@ -1,8 +1,9 @@ # typed: true # DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `time` gem. -# Please instead update this file by running `bin/tapioca gem time`. +# This is an autogenerated file for types exported from the `nkf` gem. +# Please instead update this file by running `bin/tapioca gem nkf`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/nokogiri@1.15.2.rbi b/sorbet/rbi/gems/nokogiri@1.16.7.rbi similarity index 96% rename from sorbet/rbi/gems/nokogiri@1.15.2.rbi rename to sorbet/rbi/gems/nokogiri@1.16.7.rbi index b7a1b59c7..f695bcef6 100644 --- a/sorbet/rbi/gems/nokogiri@1.15.2.rbi +++ b/sorbet/rbi/gems/nokogiri@1.16.7.rbi @@ -4,17 +4,6 @@ # This is an autogenerated file for types exported from the `nokogiri` gem. # Please instead update this file by running `bin/tapioca gem nokogiri`. -# source://american_date/1.2.0/lib/american_date.rb#16 -::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) - -# source://ruby-openid/2.9.2/lib/openid/fetchers.rb#13 -::MAX_RESPONSE_KB = T.let(T.unsafe(nil), Integer) - -# source://yard/0.9.34/lib/yard.rb#61 -::RUBY18 = T.let(T.unsafe(nil), FalseClass) - -# source://yard/0.9.34/lib/yard.rb#62 -::RUBY19 = T.let(T.unsafe(nil), TrueClass) # Nokogiri parses and searches XML/HTML very quickly, and also has # correctly implemented CSS3 selector support as well as XPath 1.0 @@ -104,10 +93,10 @@ module Nokogiri # @return [Boolean] # - # source://nokogiri//lib/nokogiri/version/info.rb#205 + # source://nokogiri//lib/nokogiri/version/info.rb#206 def jruby?; end - # source://nokogiri//lib/nokogiri/version/info.rb#210 + # source://nokogiri//lib/nokogiri/version/info.rb#211 def libxml2_patches; end # Create a new Nokogiri::XML::DocumentFragment @@ -122,12 +111,12 @@ module Nokogiri # @return [Boolean] # - # source://nokogiri//lib/nokogiri/version/info.rb#200 + # source://nokogiri//lib/nokogiri/version/info.rb#201 def uses_gumbo?; end # @return [Boolean] # - # source://nokogiri//lib/nokogiri/version/info.rb#192 + # source://nokogiri//lib/nokogiri/version/info.rb#193 def uses_libxml?(requirement = T.unsafe(nil)); end end end @@ -731,22 +720,6 @@ Nokogiri::CSS::XPathVisitor::DoctypeConfig::XML = T.let(T.unsafe(nil), Symbol) # source://nokogiri//lib/nokogiri/css/xpath_visitor.rb#10 Nokogiri::CSS::XPathVisitor::WILDCARD_NAMESPACES = T.let(T.unsafe(nil), TrueClass) -# source://nokogiri//lib/nokogiri/css/xpath_visitor.rb#339 -module Nokogiri::CSS::XPathVisitorAlwaysUseBuiltins - class << self - # source://nokogiri//lib/nokogiri/css/xpath_visitor.rb#340 - def new; end - end -end - -# source://nokogiri//lib/nokogiri/css/xpath_visitor.rb#349 -module Nokogiri::CSS::XPathVisitorOptimallyUseBuiltins - class << self - # source://nokogiri//lib/nokogiri/css/xpath_visitor.rb#350 - def new; end - end -end - # Some classes in Nokogiri are namespaced as a group, for example # Document, DocumentFragment, and Builder. # @@ -1845,30 +1818,16 @@ module Nokogiri::HTML5 # source://nokogiri//lib/nokogiri/html5.rb#238 def fragment(string, encoding = T.unsafe(nil), **options); end - # Fetch and parse a HTML document from the web, following redirects, - # handling https, and determining the character encoding using HTML5 - # rules. +uri+ may be a +String+ or a +URI+. +options+ contains - # http headers and special options. Everything which is not a - # special option is considered a header. Special options include: - # * :follow_limit => number of redirects which are followed - # * :basic_auth => [username, password] - # - # source://nokogiri//lib/nokogiri/html5.rb#249 - def get(uri, options = T.unsafe(nil)); end - # Parse an HTML 5 document. Convenience method for {Nokogiri::HTML5::Document.parse} # # source://nokogiri//lib/nokogiri/html5.rb#232 def parse(string, url = T.unsafe(nil), encoding = T.unsafe(nil), **options, &block); end - # source://nokogiri//lib/nokogiri/html5.rb#260 + # source://nokogiri//lib/nokogiri/html5.rb#243 def read_and_encode(string, encoding); end private - # source://nokogiri//lib/nokogiri/html5.rb#286 - def get_impl(uri, options = T.unsafe(nil)); end - # Charset sniffing is a complex and controversial topic that understandably isn't done _by # default_ by the Ruby Net::HTTP library. This being said, it is a very real problem for # consumers of HTML as the default for HTML is iso-8859-1, most "good" producers use utf-8, and @@ -1881,7 +1840,7 @@ module Nokogiri::HTML5 # http://bugs.ruby-lang.org/issues/2567 # http://www.w3.org/TR/html5/syntax.html#determining-the-character-encoding # - # source://nokogiri//lib/nokogiri/html5.rb#347 + # source://nokogiri//lib/nokogiri/html5.rb#281 def reencode(body, content_type = T.unsafe(nil)); end end end @@ -2142,7 +2101,7 @@ Nokogiri::VERSION = T.let(T.unsafe(nil), String) # Detailed version info about Nokogiri and the installed extension dependencies. # -# source://nokogiri//lib/nokogiri/version/info.rb#222 +# source://nokogiri//lib/nokogiri/version/info.rb#223 Nokogiri::VERSION_INFO = T.let(T.unsafe(nil), Hash) # source://nokogiri//lib/nokogiri/version/info.rb#7 @@ -2206,7 +2165,7 @@ class Nokogiri::VersionInfo # source://nokogiri//lib/nokogiri/version/info.rb#88 def to_hash; end - # source://nokogiri//lib/nokogiri/version/info.rb#180 + # source://nokogiri//lib/nokogiri/version/info.rb#181 def to_markdown; end # source://nokogiri//lib/nokogiri/version/info.rb#72 @@ -2273,8 +2232,6 @@ class Nokogiri::XML::Attr < ::Nokogiri::XML::Node # - +value+ → (String) The value of the attribute. # - +namespace+ → (Namespace, nil) The Namespace of the attribute, or +nil+ if there is no namespace. # - # ⚡ This is an experimental feature, available since v1.14.0 - # # *Example* # # doc = Nokogiri::XML.parse(<<~XML) @@ -2307,6 +2264,8 @@ class Nokogiri::XML::Attr < ::Nokogiri::XML::Node # # href = "http://nokogiri.org/ns/noko" # # })} # + # Since v1.14.0 + # # source://nokogiri//lib/nokogiri/xml/attr.rb#55 def deconstruct_keys(keys); end @@ -2793,13 +2752,13 @@ end class Nokogiri::XML::Document < ::Nokogiri::XML::Node # @return [Document] a new instance of Document # - # source://nokogiri//lib/nokogiri/xml/document.rb#178 + # source://nokogiri//lib/nokogiri/xml/document.rb#177 def initialize(*args); end - # source://nokogiri//lib/nokogiri/xml/document.rb#394 + # source://nokogiri//lib/nokogiri/xml/document.rb#393 def <<(node_or_tags); end - # source://nokogiri//lib/nokogiri/xml/document.rb#394 + # source://nokogiri//lib/nokogiri/xml/document.rb#393 def add_child(node_or_tags); end def canonicalize(*_arg0); end @@ -2841,17 +2800,17 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # # {"xmlns:foo" => "baz"} # - # source://nokogiri//lib/nokogiri/xml/document.rb#317 + # source://nokogiri//lib/nokogiri/xml/document.rb#316 def collect_namespaces; end # Create a CDATA Node containing +string+ # - # source://nokogiri//lib/nokogiri/xml/document.rb#262 + # source://nokogiri//lib/nokogiri/xml/document.rb#261 def create_cdata(string, &block); end # Create a Comment Node containing +string+ # - # source://nokogiri//lib/nokogiri/xml/document.rb#267 + # source://nokogiri//lib/nokogiri/xml/document.rb#266 def create_comment(string, &block); end # :call-seq: @@ -2902,14 +2861,14 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # # doc.create_element("div") { |node| node["class"] = "blue" if before_noon? } # - # source://nokogiri//lib/nokogiri/xml/document.rb#232 + # source://nokogiri//lib/nokogiri/xml/document.rb#231 def create_element(name, *contents_or_attrs, &block); end def create_entity(*_arg0); end # Create a Text Node with +string+ # - # source://nokogiri//lib/nokogiri/xml/document.rb#257 + # source://nokogiri//lib/nokogiri/xml/document.rb#256 def create_text_node(string, &block); end # :call-seq: deconstruct_keys(array_of_names) → Hash @@ -2923,8 +2882,6 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # instructions. If you have a use case and would like this functionality, please let us know # by opening an issue or a discussion on the github project. # - # ⚡ This is an experimental feature, available since v1.14.0 - # # *Example* # # doc = Nokogiri::XML.parse(<<~XML) @@ -2951,22 +2908,24 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # doc.deconstruct_keys([:root]) # # => {:root=>nil} # - # source://nokogiri//lib/nokogiri/xml/document.rb#458 + # Since v1.14.0 + # + # source://nokogiri//lib/nokogiri/xml/document.rb#457 def deconstruct_keys(keys); end # Apply any decorators to +node+ # - # source://nokogiri//lib/nokogiri/xml/document.rb#365 + # source://nokogiri//lib/nokogiri/xml/document.rb#364 def decorate(node); end # Get the list of decorators given +key+ # - # source://nokogiri//lib/nokogiri/xml/document.rb#324 + # source://nokogiri//lib/nokogiri/xml/document.rb#323 def decorators(key); end # A reference to +self+ # - # source://nokogiri//lib/nokogiri/xml/document.rb#277 + # source://nokogiri//lib/nokogiri/xml/document.rb#276 def document; end def dup(*_arg0); end @@ -2990,12 +2949,12 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # Create a Nokogiri::XML::DocumentFragment from +tags+ # Returns an empty fragment if +tags+ is nil. # - # source://nokogiri//lib/nokogiri/xml/document.rb#386 + # source://nokogiri//lib/nokogiri/xml/document.rb#385 def fragment(tags = T.unsafe(nil)); end # The name of this document. Always returns "document" # - # source://nokogiri//lib/nokogiri/xml/document.rb#272 + # source://nokogiri//lib/nokogiri/xml/document.rb#271 def name; end # When `true`, reparented elements without a namespace will inherit their new parent's @@ -3098,7 +3057,7 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # Get the hash of namespaces on the root Nokogiri::XML::Node # - # source://nokogiri//lib/nokogiri/xml/document.rb#379 + # source://nokogiri//lib/nokogiri/xml/document.rb#378 def namespaces; end def remove_namespaces!; end @@ -3120,10 +3079,10 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # irb> doc.slop! # ... which does absolutely nothing. # - # source://nokogiri//lib/nokogiri/xml/document.rb#354 + # source://nokogiri//lib/nokogiri/xml/document.rb#353 def slop!; end - # source://nokogiri//lib/nokogiri/xml/node.rb#1280 + # source://nokogiri//lib/nokogiri/xml/node.rb#1286 def to_xml(*args, &block); end def url; end @@ -3131,7 +3090,7 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # Validate this Document against it's DTD. Returns a list of errors on # the document or +nil+ when there is no DTD. # - # source://nokogiri//lib/nokogiri/xml/document.rb#332 + # source://nokogiri//lib/nokogiri/xml/document.rb#331 def validate; end def version; end @@ -3143,12 +3102,12 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node # # See XPathVisitor for more information. # - # source://nokogiri//lib/nokogiri/xml/document.rb#414 + # source://nokogiri//lib/nokogiri/xml/document.rb#413 def xpath_doctype; end private - # source://nokogiri//lib/nokogiri/xml/document.rb#466 + # source://nokogiri//lib/nokogiri/xml/document.rb#465 def inspect_attributes; end class << self @@ -3196,7 +3155,7 @@ class Nokogiri::XML::Document < ::Nokogiri::XML::Node end end -# source://nokogiri//lib/nokogiri/xml/document.rb#464 +# source://nokogiri//lib/nokogiri/xml/document.rb#463 Nokogiri::XML::Document::IMPLIED_XPATH_CONTEXTS = T.let(T.unsafe(nil), Array) # source://nokogiri//lib/nokogiri/xml/document.rb#19 @@ -3244,8 +3203,6 @@ class Nokogiri::XML::DocumentFragment < ::Nokogiri::XML::Node # root elements, you should deconstruct the array returned by # DocumentFragment#elements. # - # ⚡ This is an experimental feature, available since v1.14.0 - # # *Example* # # frag = Nokogiri::HTML5.fragment(<<~HTML) @@ -3277,6 +3234,8 @@ class Nokogiri::XML::DocumentFragment < ::Nokogiri::XML::Node # # }), # # #(Element:0x398 { name = "div", children = [ #(Text "End")] })] # + # Since v1.14.0 + # # source://nokogiri//lib/nokogiri/xml/document_fragment.rb#190 def deconstruct; end @@ -3485,8 +3444,6 @@ class Nokogiri::XML::Namespace # - +prefix+ → (String, nil) The namespace's prefix, or +nil+ if there is no prefix (e.g., default namespace). # - +href+ → (String) The namespace's URI # - # ⚡ This is an experimental feature, available since v1.14.0 - # # *Example* # # doc = Nokogiri::XML.parse(<<~XML) @@ -3512,7 +3469,9 @@ class Nokogiri::XML::Namespace # doc.root.elements.last.namespace.deconstruct_keys([:prefix, :href]) # # => {:prefix=>"noko", :href=>"http://nokogiri.org/ns/noko"} # - # source://nokogiri//lib/nokogiri/xml/namespace.rb#47 + # Since v1.14.0 + # + # source://nokogiri//lib/nokogiri/xml/namespace.rb#46 def deconstruct_keys(keys); end # Returns the value of attribute document. @@ -3525,7 +3484,7 @@ class Nokogiri::XML::Namespace private - # source://nokogiri//lib/nokogiri/xml/namespace.rb#53 + # source://nokogiri//lib/nokogiri/xml/namespace.rb#52 def inspect_attributes; end end @@ -3625,12 +3584,12 @@ class Nokogiri::XML::Node # Compare two Node objects with respect to their Document. Nodes from # different documents cannot be compared. # - # source://nokogiri//lib/nokogiri/xml/node.rb#1256 + # source://nokogiri//lib/nokogiri/xml/node.rb#1262 def <=>(other); end # Test to see if this Node is equal to +other+ # - # source://nokogiri//lib/nokogiri/xml/node.rb#1246 + # source://nokogiri//lib/nokogiri/xml/node.rb#1252 def ==(other); end # :call-seq: [](name) → (String, nil) @@ -3705,7 +3664,7 @@ class Nokogiri::XML::Node # Accept a visitor. This method calls "visit" on +visitor+ with self. # - # source://nokogiri//lib/nokogiri/xml/node.rb#1240 + # source://nokogiri//lib/nokogiri/xml/node.rb#1246 def accept(visitor); end # Add +node_or_tags+ as a child of this Node. @@ -3813,7 +3772,7 @@ class Nokogiri::XML::Node # Get a list of ancestor Node for this Node. If +selector+ is given, # the ancestors must match +selector+ # - # source://nokogiri//lib/nokogiri/xml/node.rb#1209 + # source://nokogiri//lib/nokogiri/xml/node.rb#1215 def ancestors(selector = T.unsafe(nil)); end # :call-seq: append_class(names) → self @@ -3966,14 +3925,14 @@ class Nokogiri::XML::Node def blank?; end - # source://nokogiri//lib/nokogiri/xml/node.rb#1407 + # source://nokogiri//lib/nokogiri/xml/node.rb#1414 def canonicalize(mode = T.unsafe(nil), inclusive_namespaces = T.unsafe(nil), with_comments = T.unsafe(nil)); end # Returns true if this is a CDATA # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1130 + # source://nokogiri//lib/nokogiri/xml/node.rb#1136 def cdata?; end def child; end @@ -4017,7 +3976,7 @@ class Nokogiri::XML::Node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1125 + # source://nokogiri//lib/nokogiri/xml/node.rb#1131 def comment?; end def content; end @@ -4033,7 +3992,7 @@ class Nokogiri::XML::Node # Get the path to this node as a CSS expression # - # source://nokogiri//lib/nokogiri/xml/node.rb#1200 + # source://nokogiri//lib/nokogiri/xml/node.rb#1206 def css_path; end # :call-seq: deconstruct_keys(array_of_names) → Hash @@ -4049,8 +4008,6 @@ class Nokogiri::XML::Node # - +content+ → (String) The contents of all the text nodes in this node's subtree. See #content. # - +inner_html+ → (String) The inner markup for the children of this node. See #inner_html. # - # ⚡ This is an experimental feature, available since v1.14.0 - # # *Example* # # doc = Nokogiri::XML.parse(<<~XML) @@ -4085,7 +4042,9 @@ class Nokogiri::XML::Node # # value = "def" # # })]} # - # source://nokogiri//lib/nokogiri/xml/node.rb#1468 + # Since v1.14.0 + # + # source://nokogiri//lib/nokogiri/xml/node.rb#1475 def deconstruct_keys(keys); end # Decorate this node with the decorators set up in this node's Document @@ -4110,7 +4069,7 @@ class Nokogiri::XML::Node # Fetch the Nokogiri::HTML4::ElementDescription for this node. Returns # nil on XML documents and on unknown tags. # - # source://nokogiri//lib/nokogiri/xml/node.rb#1167 + # source://nokogiri//lib/nokogiri/xml/node.rb#1173 def description; end # Do xinclude substitution on the subtree below node. If given a block, a @@ -4128,7 +4087,7 @@ class Nokogiri::XML::Node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1145 + # source://nokogiri//lib/nokogiri/xml/node.rb#1151 def document?; end def dup(*_arg0); end @@ -4142,14 +4101,14 @@ class Nokogiri::XML::Node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1181 + # source://nokogiri//lib/nokogiri/xml/node.rb#1187 def elem?; end # Returns true if this is an Element node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1181 + # source://nokogiri//lib/nokogiri/xml/node.rb#1187 def element?; end def element_children; end @@ -4168,7 +4127,7 @@ class Nokogiri::XML::Node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1160 + # source://nokogiri//lib/nokogiri/xml/node.rb#1166 def fragment?; end # :call-seq: [](name) → (String, nil) @@ -4210,7 +4169,7 @@ class Nokogiri::XML::Node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1140 + # source://nokogiri//lib/nokogiri/xml/node.rb#1146 def html?; end # Get the inner_html for this node's Node#children @@ -4484,7 +4443,7 @@ class Nokogiri::XML::Node # # "xmlns"=>"http://example.com/root", # # "xmlns:in_scope"=>"http://example.com/in_scope"} # - # source://nokogiri//lib/nokogiri/xml/node.rb#1116 + # source://nokogiri//lib/nokogiri/xml/node.rb#1122 def namespaces; end def native_content=(_arg0); end @@ -4566,14 +4525,14 @@ class Nokogiri::XML::Node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1150 + # source://nokogiri//lib/nokogiri/xml/node.rb#1156 def processing_instruction?; end # Is this a read only node? # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1175 + # source://nokogiri//lib/nokogiri/xml/node.rb#1181 def read_only?; end def remove; end @@ -4657,7 +4616,7 @@ class Nokogiri::XML::Node # config.format.as_xml # end # - # source://nokogiri//lib/nokogiri/xml/node.rb#1280 + # source://nokogiri//lib/nokogiri/xml/node.rb#1286 def serialize(*args, &block); end # :call-seq: []=(name, value) → value @@ -4715,7 +4674,7 @@ class Nokogiri::XML::Node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1155 + # source://nokogiri//lib/nokogiri/xml/node.rb#1161 def text?; end # Serialize this Node to HTML @@ -4725,13 +4684,13 @@ class Nokogiri::XML::Node # See Node#write_to for a list of +options+. For formatted output, # use Node#to_xhtml instead. # - # source://nokogiri//lib/nokogiri/xml/node.rb#1306 + # source://nokogiri//lib/nokogiri/xml/node.rb#1313 def to_html(options = T.unsafe(nil)); end # Turn this node in to a string. If the document is HTML, this method # returns html. If the document is XML, this method returns XML. # - # source://nokogiri//lib/nokogiri/xml/node.rb#1190 + # source://nokogiri//lib/nokogiri/xml/node.rb#1196 def to_s; end def to_str; end @@ -4741,7 +4700,7 @@ class Nokogiri::XML::Node # # See Node#write_to for a list of +options+ # - # source://nokogiri//lib/nokogiri/xml/node.rb#1327 + # source://nokogiri//lib/nokogiri/xml/node.rb#1334 def to_xhtml(options = T.unsafe(nil)); end # Serialize this Node to XML using +options+ @@ -4749,7 +4708,7 @@ class Nokogiri::XML::Node # # See Node#write_to for a list of +options+ # - # source://nokogiri//lib/nokogiri/xml/node.rb#1316 + # source://nokogiri//lib/nokogiri/xml/node.rb#1323 def to_xml(options = T.unsafe(nil)); end # Yields self and all children to +block+ recursively. @@ -4757,7 +4716,7 @@ class Nokogiri::XML::Node # @yield [_self] # @yieldparam _self [Nokogiri::XML::Node] the object that the method was called on # - # source://nokogiri//lib/nokogiri/xml/node.rb#1233 + # source://nokogiri//lib/nokogiri/xml/node.rb#1239 def traverse(&block); end def type; end @@ -4826,7 +4785,7 @@ class Nokogiri::XML::Node # # See Node#write_to for a list of +options+ # - # source://nokogiri//lib/nokogiri/xml/node.rb#1384 + # source://nokogiri//lib/nokogiri/xml/node.rb#1391 def write_html_to(io, options = T.unsafe(nil)); end # :call-seq: @@ -4860,7 +4819,7 @@ class Nokogiri::XML::Node # # See Node#write_to for a list of +options+ # - # source://nokogiri//lib/nokogiri/xml/node.rb#1392 + # source://nokogiri//lib/nokogiri/xml/node.rb#1399 def write_xhtml_to(io, options = T.unsafe(nil)); end # Write Node as XML to +io+ with +options+ @@ -4869,21 +4828,21 @@ class Nokogiri::XML::Node # # See Node#write_to for a list of options # - # source://nokogiri//lib/nokogiri/xml/node.rb#1402 + # source://nokogiri//lib/nokogiri/xml/node.rb#1409 def write_xml_to(io, options = T.unsafe(nil)); end # Returns true if this is an XML::Document node # # @return [Boolean] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1135 + # source://nokogiri//lib/nokogiri/xml/node.rb#1141 def xml?; end protected # @raise [ArgumentError] # - # source://nokogiri//lib/nokogiri/xml/node.rb#1482 + # source://nokogiri//lib/nokogiri/xml/node.rb#1489 def coerce(data); end private @@ -4896,7 +4855,7 @@ class Nokogiri::XML::Node def add_next_sibling_node(_arg0); end def add_previous_sibling_node(_arg0); end - # source://nokogiri//lib/nokogiri/xml/node.rb#1516 + # source://nokogiri//lib/nokogiri/xml/node.rb#1523 def add_sibling(next_or_previous, node_or_tags); end def compare(_arg0); end @@ -4905,10 +4864,10 @@ class Nokogiri::XML::Node def html_standard_serialize(_arg0); end def in_context(_arg0, _arg1); end - # source://nokogiri//lib/nokogiri/xml/node.rb#1555 + # source://nokogiri//lib/nokogiri/xml/node.rb#1562 def inspect_attributes; end - # source://nokogiri//lib/nokogiri/xml/node.rb#1504 + # source://nokogiri//lib/nokogiri/xml/node.rb#1511 def keywordify(keywords); end def native_write_to(_arg0, _arg1, _arg2, _arg3); end @@ -4918,10 +4877,10 @@ class Nokogiri::XML::Node def set(_arg0, _arg1); end def set_namespace(_arg0); end - # source://nokogiri//lib/nokogiri/xml/node.rb#1541 + # source://nokogiri//lib/nokogiri/xml/node.rb#1548 def to_format(save_option, options); end - # source://nokogiri//lib/nokogiri/xml/node.rb#1548 + # source://nokogiri//lib/nokogiri/xml/node.rb#1555 def write_format_to(save_option, io, options); end class << self @@ -4949,10 +4908,10 @@ Nokogiri::XML::Node::CDATA_SECTION_NODE = T.let(T.unsafe(nil), Integer) # source://nokogiri//lib/nokogiri/xml/node.rb#77 Nokogiri::XML::Node::COMMENT_NODE = T.let(T.unsafe(nil), Integer) -# source://nokogiri//lib/nokogiri/xml/node.rb#1415 +# source://nokogiri//lib/nokogiri/xml/node.rb#1422 Nokogiri::XML::Node::DECONSTRUCT_KEYS = T.let(T.unsafe(nil), Array) -# source://nokogiri//lib/nokogiri/xml/node.rb#1416 +# source://nokogiri//lib/nokogiri/xml/node.rb#1423 Nokogiri::XML::Node::DECONSTRUCT_METHODS = T.let(T.unsafe(nil), Hash) # DOCB document node type @@ -5010,7 +4969,7 @@ Nokogiri::XML::Node::ENTITY_REF_NODE = T.let(T.unsafe(nil), Integer) # source://nokogiri//lib/nokogiri/xml/node.rb#87 Nokogiri::XML::Node::HTML_DOCUMENT_NODE = T.let(T.unsafe(nil), Integer) -# source://nokogiri//lib/nokogiri/xml/node.rb#1559 +# source://nokogiri//lib/nokogiri/xml/node.rb#1566 Nokogiri::XML::Node::IMPLIED_XPATH_CONTEXTS = T.let(T.unsafe(nil), Array) # Namespace declaration type @@ -5169,7 +5128,7 @@ Nokogiri::XML::Node::SaveOptions::NO_XHTML = T.let(T.unsafe(nil), Integer) # source://nokogiri//lib/nokogiri/xml/node.rb#67 Nokogiri::XML::Node::TEXT_NODE = T.let(T.unsafe(nil), Integer) -# source://nokogiri//lib/nokogiri/xml/node.rb#1538 +# source://nokogiri//lib/nokogiri/xml/node.rb#1545 Nokogiri::XML::Node::USING_LIBXML_WITH_BROKEN_SERIALIZATION = T.let(T.unsafe(nil), FalseClass) # XInclude end type @@ -5360,7 +5319,7 @@ class Nokogiri::XML::NodeSet # # Returns the members of this NodeSet as an array, to use in pattern matching. # - # ⚡ This is an experimental feature, available since v1.14.0 + # Since v1.14.0 # # source://nokogiri//lib/nokogiri/xml/node_set.rb#440 def deconstruct; end @@ -6155,9 +6114,11 @@ class Nokogiri::XML::ProcessingInstruction < ::Nokogiri::XML::Node end end -# Nokogiri::XML::Reader parses an XML document similar to the way a cursor -# would move. The Reader is given an XML document, and yields nodes -# to an each block. +# Nokogiri::XML::Reader parses an XML document similar to the way a cursor would move. The +# Reader is given an XML document, and yields nodes to an each block. +# +# The Reader parser might be good for when you need the speed and low memory usage of the SAX +# parser, but do not want to write a Document handler. # # Here is an example of usage: # @@ -6174,28 +6135,26 @@ end # # end # -# Note that Nokogiri::XML::Reader#each can only be called once!! Once -# the cursor moves through the entire document, you must parse the -# document again. So make sure that you capture any information you -# need during the first iteration. +# ⚠ Nokogiri::XML::Reader#each can only be called once! Once the cursor moves through the entire +# document, you must parse the document again. It may be better to capture all information you +# need during a single iteration. # -# The Reader parser is good for when you need the speed of a SAX parser, -# but do not want to write a Document handler. +# ⚠ libxml2 does not support error recovery in the Reader parser. The `RECOVER` ParseOption is +# ignored. If a syntax error is encountered during parsing, an exception will be raised. # -# source://nokogiri//lib/nokogiri/xml/reader.rb#32 +# source://nokogiri//lib/nokogiri/xml/reader.rb#33 class Nokogiri::XML::Reader include ::Enumerable # @return [Reader] a new instance of Reader # - # source://nokogiri//lib/nokogiri/xml/reader.rb#79 + # source://nokogiri//lib/nokogiri/xml/reader.rb#80 def initialize(source, url = T.unsafe(nil), encoding = T.unsafe(nil)); end def attribute(_arg0); end def attribute_at(_arg0); end def attribute_count; end def attribute_hash; end - def attribute_nodes; end # Get the attributes and namespaces of the current node as a Hash. # @@ -6204,7 +6163,7 @@ class Nokogiri::XML::Reader # [Returns] # (Hash) Attribute names and values, and namespace prefixes and hrefs. # - # source://nokogiri//lib/nokogiri/xml/reader.rb#92 + # source://nokogiri//lib/nokogiri/xml/reader.rb#93 def attributes; end def attributes?; end @@ -6214,7 +6173,7 @@ class Nokogiri::XML::Reader # Move the cursor through the document yielding the cursor to the block # - # source://nokogiri//lib/nokogiri/xml/reader.rb#98 + # source://nokogiri//lib/nokogiri/xml/reader.rb#99 def each; end def empty_element?; end @@ -6222,12 +6181,12 @@ class Nokogiri::XML::Reader # A list of errors encountered while parsing # - # source://nokogiri//lib/nokogiri/xml/reader.rb#72 + # source://nokogiri//lib/nokogiri/xml/reader.rb#73 def errors; end # A list of errors encountered while parsing # - # source://nokogiri//lib/nokogiri/xml/reader.rb#72 + # source://nokogiri//lib/nokogiri/xml/reader.rb#73 def errors=(_arg0); end def inner_xml; end @@ -6244,7 +6203,7 @@ class Nokogiri::XML::Reader # The XML source # - # source://nokogiri//lib/nokogiri/xml/reader.rb#75 + # source://nokogiri//lib/nokogiri/xml/reader.rb#76 def source; end def state; end @@ -6260,90 +6219,90 @@ end # Attribute node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#39 +# source://nokogiri//lib/nokogiri/xml/reader.rb#40 Nokogiri::XML::Reader::TYPE_ATTRIBUTE = T.let(T.unsafe(nil), Integer) # CDATA node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#43 +# source://nokogiri//lib/nokogiri/xml/reader.rb#44 Nokogiri::XML::Reader::TYPE_CDATA = T.let(T.unsafe(nil), Integer) # Comment node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#51 +# source://nokogiri//lib/nokogiri/xml/reader.rb#52 Nokogiri::XML::Reader::TYPE_COMMENT = T.let(T.unsafe(nil), Integer) # Document node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#53 +# source://nokogiri//lib/nokogiri/xml/reader.rb#54 Nokogiri::XML::Reader::TYPE_DOCUMENT = T.let(T.unsafe(nil), Integer) # Document Fragment node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#57 +# source://nokogiri//lib/nokogiri/xml/reader.rb#58 Nokogiri::XML::Reader::TYPE_DOCUMENT_FRAGMENT = T.let(T.unsafe(nil), Integer) # Document Type node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#55 +# source://nokogiri//lib/nokogiri/xml/reader.rb#56 Nokogiri::XML::Reader::TYPE_DOCUMENT_TYPE = T.let(T.unsafe(nil), Integer) # Element node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#37 +# source://nokogiri//lib/nokogiri/xml/reader.rb#38 Nokogiri::XML::Reader::TYPE_ELEMENT = T.let(T.unsafe(nil), Integer) # Element end node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#65 +# source://nokogiri//lib/nokogiri/xml/reader.rb#66 Nokogiri::XML::Reader::TYPE_END_ELEMENT = T.let(T.unsafe(nil), Integer) # Entity end node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#67 +# source://nokogiri//lib/nokogiri/xml/reader.rb#68 Nokogiri::XML::Reader::TYPE_END_ENTITY = T.let(T.unsafe(nil), Integer) # Entity node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#47 +# source://nokogiri//lib/nokogiri/xml/reader.rb#48 Nokogiri::XML::Reader::TYPE_ENTITY = T.let(T.unsafe(nil), Integer) # Entity Reference node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#45 +# source://nokogiri//lib/nokogiri/xml/reader.rb#46 Nokogiri::XML::Reader::TYPE_ENTITY_REFERENCE = T.let(T.unsafe(nil), Integer) -# source://nokogiri//lib/nokogiri/xml/reader.rb#35 +# source://nokogiri//lib/nokogiri/xml/reader.rb#36 Nokogiri::XML::Reader::TYPE_NONE = T.let(T.unsafe(nil), Integer) # Notation node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#59 +# source://nokogiri//lib/nokogiri/xml/reader.rb#60 Nokogiri::XML::Reader::TYPE_NOTATION = T.let(T.unsafe(nil), Integer) # PI node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#49 +# source://nokogiri//lib/nokogiri/xml/reader.rb#50 Nokogiri::XML::Reader::TYPE_PROCESSING_INSTRUCTION = T.let(T.unsafe(nil), Integer) # Significant Whitespace node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#63 +# source://nokogiri//lib/nokogiri/xml/reader.rb#64 Nokogiri::XML::Reader::TYPE_SIGNIFICANT_WHITESPACE = T.let(T.unsafe(nil), Integer) # Text node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#41 +# source://nokogiri//lib/nokogiri/xml/reader.rb#42 Nokogiri::XML::Reader::TYPE_TEXT = T.let(T.unsafe(nil), Integer) # Whitespace node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#61 +# source://nokogiri//lib/nokogiri/xml/reader.rb#62 Nokogiri::XML::Reader::TYPE_WHITESPACE = T.let(T.unsafe(nil), Integer) # XML Declaration node type # -# source://nokogiri//lib/nokogiri/xml/reader.rb#69 +# source://nokogiri//lib/nokogiri/xml/reader.rb#70 Nokogiri::XML::Reader::TYPE_XML_DECLARATION = T.let(T.unsafe(nil), Integer) # Nokogiri::XML::RelaxNG is used for validating XML against a @@ -7308,18 +7267,41 @@ end # doc = Nokogiri::XML(File.read('some_file.xml')) # xslt = Nokogiri::XSLT(File.read('some_transformer.xslt')) # -# puts xslt.transform(doc) +# xslt.transform(doc) # => Nokogiri::XML::Document # -# See Nokogiri::XSLT::Stylesheet#transform for more transformation -# information. +# Many XSLT transformations include serialization behavior to emit a non-XML document. For these +# cases, please take care to invoke the #serialize method on the result of the transformation: +# +# doc = Nokogiri::XML(File.read('some_file.xml')) +# xslt = Nokogiri::XSLT(File.read('some_transformer.xslt')) +# xslt.serialize(xslt.transform(doc)) # => String # -# source://nokogiri//lib/nokogiri/xslt/stylesheet.rb#17 +# or use the #apply_to method, which is a shortcut for `serialize(transform(document))`: +# +# doc = Nokogiri::XML(File.read('some_file.xml')) +# xslt = Nokogiri::XSLT(File.read('some_transformer.xslt')) +# xslt.apply_to(doc) # => String +# +# See Nokogiri::XSLT::Stylesheet#transform for more information and examples. +# +# source://nokogiri//lib/nokogiri/xslt/stylesheet.rb#29 class Nokogiri::XSLT::Stylesheet - # Apply an XSLT stylesheet to an XML::Document. - # +params+ is an array of strings used as XSLT parameters. - # returns serialized document + # :call-seq: + # apply_to(document, params = []) -> String + # + # Apply an XSLT stylesheet to an XML::Document and serialize it properly. This method is + # equivalent to calling #serialize on the result of #transform. + # + # [Parameters] + # - +document+ is an instance of XML::Document to transform + # - +params+ is an array of strings used as XSLT parameters, passed into #transform + # + # [Returns] + # A string containing the serialized result of the transformation. + # + # See Nokogiri::XSLT::Stylesheet#transform for more information and examples. # - # source://nokogiri//lib/nokogiri/xslt/stylesheet.rb#22 + # source://nokogiri//lib/nokogiri/xslt/stylesheet.rb#44 def apply_to(document, params = T.unsafe(nil)); end def serialize(_arg0); end diff --git a/sorbet/rbi/gems/oily_png@1.2.1.rbi b/sorbet/rbi/gems/oily_png@1.2.1.rbi index 8be2c1645..2855a1c85 100644 --- a/sorbet/rbi/gems/oily_png@1.2.1.rbi +++ b/sorbet/rbi/gems/oily_png@1.2.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `oily_png` gem. # Please instead update this file by running `bin/tapioca gem oily_png`. + module ChunkyPNG include ::OilyPNG end diff --git a/sorbet/rbi/gems/omniauth-openid@2.0.1.rbi b/sorbet/rbi/gems/omniauth-openid@2.0.1.rbi index 4b3a9ac32..e9f8e25a3 100644 --- a/sorbet/rbi/gems/omniauth-openid@2.0.1.rbi +++ b/sorbet/rbi/gems/omniauth-openid@2.0.1.rbi @@ -4,22 +4,23 @@ # This is an autogenerated file for types exported from the `omniauth-openid` gem. # Please instead update this file by running `bin/tapioca gem omniauth-openid`. + # source://omniauth-openid//lib/omniauth-openid/version.rb#1 module OmniAuth class << self - # source://omniauth/2.1.1/lib/omniauth.rb#130 + # source://omniauth/2.1.2/lib/omniauth.rb#134 def config; end - # source://omniauth/2.1.1/lib/omniauth.rb#134 + # source://omniauth/2.1.2/lib/omniauth.rb#138 def configure; end - # source://omniauth/2.1.1/lib/omniauth.rb#138 + # source://omniauth/2.1.2/lib/omniauth.rb#142 def logger; end - # source://omniauth/2.1.1/lib/omniauth.rb#142 + # source://omniauth/2.1.2/lib/omniauth.rb#146 def mock_auth_for(provider); end - # source://omniauth/2.1.1/lib/omniauth.rb#20 + # source://omniauth/2.1.2/lib/omniauth.rb#24 def strategies; end end end diff --git a/sorbet/rbi/gems/omniauth-rails_csrf_protection@1.0.1.rbi b/sorbet/rbi/gems/omniauth-rails_csrf_protection@1.0.2.rbi similarity index 56% rename from sorbet/rbi/gems/omniauth-rails_csrf_protection@1.0.1.rbi rename to sorbet/rbi/gems/omniauth-rails_csrf_protection@1.0.2.rbi index 3b98f14b5..fc84ccdb9 100644 --- a/sorbet/rbi/gems/omniauth-rails_csrf_protection@1.0.1.rbi +++ b/sorbet/rbi/gems/omniauth-rails_csrf_protection@1.0.2.rbi @@ -4,22 +4,23 @@ # This is an autogenerated file for types exported from the `omniauth-rails_csrf_protection` gem. # Please instead update this file by running `bin/tapioca gem omniauth-rails_csrf_protection`. + # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/version.rb#1 module OmniAuth class << self - # source://omniauth/2.1.1/lib/omniauth.rb#130 + # source://omniauth/2.1.2/lib/omniauth.rb#134 def config; end - # source://omniauth/2.1.1/lib/omniauth.rb#134 + # source://omniauth/2.1.2/lib/omniauth.rb#138 def configure; end - # source://omniauth/2.1.1/lib/omniauth.rb#138 + # source://omniauth/2.1.2/lib/omniauth.rb#142 def logger; end - # source://omniauth/2.1.1/lib/omniauth.rb#142 + # source://omniauth/2.1.2/lib/omniauth.rb#146 def mock_auth_for(provider); end - # source://omniauth/2.1.1/lib/omniauth.rb#20 + # source://omniauth/2.1.2/lib/omniauth.rb#24 def strategies; end end end @@ -48,179 +49,186 @@ class OmniAuth::RailsCsrfProtection::TokenVerifier include ::AbstractController::Callbacks include ::ActionController::RequestForgeryProtection extend ::ActiveSupport::Configurable::ClassMethods + extend ::AbstractController::Helpers::Resolution extend ::AbstractController::Helpers::ClassMethods extend ::ActiveSupport::Callbacks::ClassMethods extend ::ActiveSupport::DescendantsTracker extend ::AbstractController::Callbacks::ClassMethods extend ::ActionController::RequestForgeryProtection::ClassMethods - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#34 + def _call(env); end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_process_action_callbacks(&block); end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#30 def call(env); end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 - def default_protect_from_forgery; end + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#41 + # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#45 def params(*_arg0, **_arg1, &_arg2); end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 def request_forgery_protection_token; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def request_forgery_protection_token=(value); end - # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#41 + # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#45 def session(*_arg0, **_arg1, &_arg2); end - # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#25 - def urlsafe_csrf_tokens; end - private # Returns the value of attribute request. # - # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#40 + # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#44 def request; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#15 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#17 def _helpers; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _process_action_callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_protect_from_forgery; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def request_forgery_protection_token; end + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def request_forgery_protection_token=(value); end + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def urlsafe_csrf_tokens; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def request_forgery_protection_token; end - # source://actionpack/7.0.5/lib/action_controller/metal/request_forgery_protection.rb#97 - def urlsafe_csrf_tokens=(urlsafe_csrf_tokens); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def request_forgery_protection_token=(value); end end end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/token_verifier.rb#0 module OmniAuth::RailsCsrfProtection::TokenVerifier::HelperMethods - # source://actionpack/7.0.5/lib/action_controller/metal/request_forgery_protection.rb#106 - def form_authenticity_token(*args, **_arg1, &block); end + # source://actionpack/7.2.0/lib/action_controller/metal/request_forgery_protection.rb#102 + def form_authenticity_token(*_arg0, **_arg1, &_arg2); end - # source://actionpack/7.0.5/lib/action_controller/metal/request_forgery_protection.rb#107 - def protect_against_forgery?(*args, **_arg1, &block); end + # source://actionpack/7.2.0/lib/action_controller/metal/request_forgery_protection.rb#103 + def protect_against_forgery?(*_arg0, **_arg1, &_arg2); end end # source://omniauth-rails_csrf_protection//lib/omniauth/rails_csrf_protection/version.rb#3 diff --git a/sorbet/rbi/gems/omniauth-steam@1.0.6.rbi b/sorbet/rbi/gems/omniauth-steam@1.0.6.rbi index 806c1f49b..33dd49d1e 100644 --- a/sorbet/rbi/gems/omniauth-steam@1.0.6.rbi +++ b/sorbet/rbi/gems/omniauth-steam@1.0.6.rbi @@ -4,22 +4,23 @@ # This is an autogenerated file for types exported from the `omniauth-steam` gem. # Please instead update this file by running `bin/tapioca gem omniauth-steam`. + # source://omniauth-steam//lib/omniauth-steam/version.rb#1 module OmniAuth class << self - # source://omniauth/2.1.1/lib/omniauth.rb#130 + # source://omniauth/2.1.2/lib/omniauth.rb#134 def config; end - # source://omniauth/2.1.1/lib/omniauth.rb#134 + # source://omniauth/2.1.2/lib/omniauth.rb#138 def configure; end - # source://omniauth/2.1.1/lib/omniauth.rb#138 + # source://omniauth/2.1.2/lib/omniauth.rb#142 def logger; end - # source://omniauth/2.1.1/lib/omniauth.rb#142 + # source://omniauth/2.1.2/lib/omniauth.rb#146 def mock_auth_for(provider); end - # source://omniauth/2.1.1/lib/omniauth.rb#20 + # source://omniauth/2.1.2/lib/omniauth.rb#24 def strategies; end end end diff --git a/sorbet/rbi/gems/omniauth@2.1.1.rbi b/sorbet/rbi/gems/omniauth@2.1.2.rbi similarity index 90% rename from sorbet/rbi/gems/omniauth@2.1.1.rbi rename to sorbet/rbi/gems/omniauth@2.1.2.rbi index 6aa461777..c8b470250 100644 --- a/sorbet/rbi/gems/omniauth@2.1.1.rbi +++ b/sorbet/rbi/gems/omniauth@2.1.2.rbi @@ -4,24 +4,25 @@ # This is an autogenerated file for types exported from the `omniauth` gem. # Please instead update this file by running `bin/tapioca gem omniauth`. -# source://omniauth//lib/omniauth.rb#5 + +# source://omniauth//lib/omniauth.rb#9 module OmniAuth class << self - # source://omniauth//lib/omniauth.rb#130 + # source://omniauth//lib/omniauth.rb#134 def config; end # @yield [config] # - # source://omniauth//lib/omniauth.rb#134 + # source://omniauth//lib/omniauth.rb#138 def configure; end - # source://omniauth//lib/omniauth.rb#138 + # source://omniauth//lib/omniauth.rb#142 def logger; end - # source://omniauth//lib/omniauth.rb#142 + # source://omniauth//lib/omniauth.rb#146 def mock_auth_for(provider); end - # source://omniauth//lib/omniauth.rb#20 + # source://omniauth//lib/omniauth.rb#24 def strategies; end end end @@ -138,14 +139,14 @@ class OmniAuth::Builder < ::Rack::Builder def provider(klass, *args, **opts, &block); end end -# source://omniauth//lib/omniauth.rb#24 +# source://omniauth//lib/omniauth.rb#28 class OmniAuth::Configuration include ::Singleton extend ::Singleton::SingletonClassMethods # @return [Configuration] a new instance of Configuration # - # source://omniauth//lib/omniauth.rb#52 + # source://omniauth//lib/omniauth.rb#56 def initialize; end # This is a convenience method to be used by strategy authors @@ -155,187 +156,187 @@ class OmniAuth::Configuration # @param name [String] The underscored name, e.g. `oauth` # @param camelized [String] The properly camelized name, e.g. 'OAuth' # - # source://omniauth//lib/omniauth.rb#121 + # source://omniauth//lib/omniauth.rb#125 def add_camelization(name, camelized); end - # source://omniauth//lib/omniauth.rb#96 + # source://omniauth//lib/omniauth.rb#100 def add_mock(provider, original = T.unsafe(nil)); end # Returns the value of attribute allowed_request_methods. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def allowed_request_methods; end # Sets the attribute allowed_request_methods # # @param value the value to set the attribute allowed_request_methods to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def allowed_request_methods=(_arg0); end - # source://omniauth//lib/omniauth.rb#64 + # source://omniauth//lib/omniauth.rb#68 def before_callback_phase(&block); end # Sets the attribute before_callback_phase # # @param value the value to set the attribute before_callback_phase to. # - # source://omniauth//lib/omniauth.rb#125 + # source://omniauth//lib/omniauth.rb#129 def before_callback_phase=(_arg0); end - # source://omniauth//lib/omniauth.rb#72 + # source://omniauth//lib/omniauth.rb#76 def before_options_phase(&block); end # Sets the attribute before_options_phase # # @param value the value to set the attribute before_options_phase to. # - # source://omniauth//lib/omniauth.rb#125 + # source://omniauth//lib/omniauth.rb#129 def before_options_phase=(_arg0); end - # source://omniauth//lib/omniauth.rb#88 + # source://omniauth//lib/omniauth.rb#92 def before_request_phase(&block); end # Sets the attribute before_request_phase # # @param value the value to set the attribute before_request_phase to. # - # source://omniauth//lib/omniauth.rb#125 + # source://omniauth//lib/omniauth.rb#129 def before_request_phase=(_arg0); end # Returns the value of attribute camelizations. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def camelizations; end # Sets the attribute camelizations # # @param value the value to set the attribute camelizations to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def camelizations=(_arg0); end # Returns the value of attribute failure_raise_out_environments. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def failure_raise_out_environments; end # Sets the attribute failure_raise_out_environments # # @param value the value to set the attribute failure_raise_out_environments to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def failure_raise_out_environments=(_arg0); end # Returns the value of attribute form_css. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def form_css; end # Sets the attribute form_css # # @param value the value to set the attribute form_css to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def form_css=(_arg0); end # Returns the value of attribute full_host. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def full_host; end # Sets the attribute full_host # # @param value the value to set the attribute full_host to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def full_host=(_arg0); end # Returns the value of attribute logger. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def logger; end # Sets the attribute logger # # @param value the value to set the attribute logger to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def logger=(_arg0); end # Returns the value of attribute mock_auth. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def mock_auth; end # Sets the attribute mock_auth # # @param value the value to set the attribute mock_auth to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def mock_auth=(_arg0); end - # source://omniauth//lib/omniauth.rb#56 + # source://omniauth//lib/omniauth.rb#60 def on_failure(&block); end # Sets the attribute on_failure # # @param value the value to set the attribute on_failure to. # - # source://omniauth//lib/omniauth.rb#125 + # source://omniauth//lib/omniauth.rb#129 def on_failure=(_arg0); end # Returns the value of attribute path_prefix. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def path_prefix; end # Sets the attribute path_prefix # # @param value the value to set the attribute path_prefix to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def path_prefix=(_arg0); end - # source://omniauth//lib/omniauth.rb#80 + # source://omniauth//lib/omniauth.rb#84 def request_validation_phase(&block); end # Sets the attribute request_validation_phase # # @param value the value to set the attribute request_validation_phase to. # - # source://omniauth//lib/omniauth.rb#125 + # source://omniauth//lib/omniauth.rb#129 def request_validation_phase=(_arg0); end # Returns the value of attribute silence_get_warning. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def silence_get_warning; end # Sets the attribute silence_get_warning # # @param value the value to set the attribute silence_get_warning to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def silence_get_warning=(_arg0); end # Returns the value of attribute test_mode. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def test_mode; end # Sets the attribute test_mode # # @param value the value to set the attribute test_mode to. # - # source://omniauth//lib/omniauth.rb#126 + # source://omniauth//lib/omniauth.rb#130 def test_mode=(_arg0); end class << self - # source://omniauth//lib/omniauth.rb#27 + # source://omniauth//lib/omniauth.rb#31 def default_logger; end - # source://omniauth//lib/omniauth.rb#33 + # source://omniauth//lib/omniauth.rb#37 def defaults; end private @@ -345,7 +346,7 @@ class OmniAuth::Configuration end end -# source://omniauth//lib/omniauth.rb#6 +# source://omniauth//lib/omniauth.rb#10 class OmniAuth::Error < ::StandardError; end # This simple Rack endpoint that serves as the default @@ -398,25 +399,25 @@ class OmniAuth::Form # source://omniauth//lib/omniauth/form.rb#7 def initialize(options = T.unsafe(nil)); end - # source://omniauth//lib/omniauth/form.rb#50 + # source://omniauth//lib/omniauth/form.rb#51 def button(text); end - # source://omniauth//lib/omniauth/form.rb#59 + # source://omniauth//lib/omniauth/form.rb#60 def fieldset(legend, options = T.unsafe(nil), &block); end - # source://omniauth//lib/omniauth/form.rb#83 + # source://omniauth//lib/omniauth/form.rb#84 def footer; end - # source://omniauth//lib/omniauth/form.rb#66 + # source://omniauth//lib/omniauth/form.rb#67 def header(title, header_info); end - # source://omniauth//lib/omniauth/form.rb#55 + # source://omniauth//lib/omniauth/form.rb#56 def html(html); end - # source://omniauth//lib/omniauth/form.rb#33 + # source://omniauth//lib/omniauth/form.rb#34 def input_field(type, name); end - # source://omniauth//lib/omniauth/form.rb#28 + # source://omniauth//lib/omniauth/form.rb#29 def label_field(text, target); end # Returns the value of attribute options. @@ -431,25 +432,25 @@ class OmniAuth::Form # source://omniauth//lib/omniauth/form.rb#5 def options=(_arg0); end - # source://omniauth//lib/omniauth/form.rb#44 + # source://omniauth//lib/omniauth/form.rb#45 def password_field(label, name); end - # source://omniauth//lib/omniauth/form.rb#38 + # source://omniauth//lib/omniauth/form.rb#39 def text_field(label, name); end - # source://omniauth//lib/omniauth/form.rb#96 + # source://omniauth//lib/omniauth/form.rb#97 def to_html; end - # source://omniauth//lib/omniauth/form.rb#101 + # source://omniauth//lib/omniauth/form.rb#102 def to_response; end protected - # source://omniauth//lib/omniauth/form.rb#108 + # source://omniauth//lib/omniauth/form.rb#109 def css; end class << self - # source://omniauth//lib/omniauth/form.rb#18 + # source://omniauth//lib/omniauth/form.rb#19 def build(options = T.unsafe(nil), &block); end end end @@ -472,7 +473,7 @@ end # source://omniauth//lib/omniauth/strategy.rb#4 class OmniAuth::NoSessionError < ::StandardError; end -# source://omniauth//lib/omniauth.rb#8 +# source://omniauth//lib/omniauth.rb#12 module OmniAuth::Strategies; end # The Developer strategy is a very simple strategy that can be used as a @@ -931,27 +932,27 @@ module OmniAuth::Test::StrategyTestCase def strategy; end end -# source://omniauth//lib/omniauth.rb#146 +# source://omniauth//lib/omniauth.rb#150 module OmniAuth::Utils private - # source://omniauth//lib/omniauth.rb#168 + # source://omniauth//lib/omniauth.rb#172 def camelize(word, first_letter_in_uppercase = T.unsafe(nil)); end - # source://omniauth//lib/omniauth.rb#153 + # source://omniauth//lib/omniauth.rb#157 def deep_merge(hash, other_hash); end - # source://omniauth//lib/omniauth.rb#149 + # source://omniauth//lib/omniauth.rb#153 def form_css; end class << self - # source://omniauth//lib/omniauth.rb#168 + # source://omniauth//lib/omniauth.rb#172 def camelize(word, first_letter_in_uppercase = T.unsafe(nil)); end - # source://omniauth//lib/omniauth.rb#153 + # source://omniauth//lib/omniauth.rb#157 def deep_merge(hash, other_hash); end - # source://omniauth//lib/omniauth.rb#149 + # source://omniauth//lib/omniauth.rb#153 def form_css; end end end diff --git a/sorbet/rbi/gems/orm_adapter@0.5.0.rbi b/sorbet/rbi/gems/orm_adapter@0.5.0.rbi index 01db0fd9f..e40b5c4b1 100644 --- a/sorbet/rbi/gems/orm_adapter@0.5.0.rbi +++ b/sorbet/rbi/gems/orm_adapter@0.5.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `orm_adapter` gem. # Please instead update this file by running `bin/tapioca gem orm_adapter`. + # source://orm_adapter//lib/orm_adapter/base.rb#1 module OrmAdapter class << self diff --git a/sorbet/rbi/gems/parallel@1.23.0.rbi b/sorbet/rbi/gems/parallel@1.26.2.rbi similarity index 81% rename from sorbet/rbi/gems/parallel@1.23.0.rbi rename to sorbet/rbi/gems/parallel@1.26.2.rbi index c8b319a36..854c48709 100644 --- a/sorbet/rbi/gems/parallel@1.23.0.rbi +++ b/sorbet/rbi/gems/parallel@1.26.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `parallel` gem. # Please instead update this file by running `bin/tapioca gem parallel`. + # source://parallel//lib/parallel/version.rb#2 module Parallel class << self @@ -24,10 +25,10 @@ module Parallel def each_with_index(array, options = T.unsafe(nil), &block); end # source://parallel//lib/parallel.rb#307 - def filter_map(*args, &block); end + def filter_map(*_arg0, **_arg1, &_arg2); end # source://parallel//lib/parallel.rb#303 - def flat_map(*args, &block); end + def flat_map(*_arg0, **_arg1, &_arg2); end # source://parallel//lib/parallel.rb#228 def in_processes(options = T.unsafe(nil), &block); end @@ -46,63 +47,80 @@ module Parallel # source://parallel//lib/parallel.rb#312 def physical_processor_count; end - # Number of processors seen by the OS, used for process scheduling + # Number of processors seen by the OS or value considering CPU quota if the process is inside a cgroup, + # used for process scheduling # - # source://parallel//lib/parallel.rb#345 + # source://parallel//lib/parallel.rb#342 def processor_count; end - # source://parallel//lib/parallel.rb#350 + # source://parallel//lib/parallel.rb#346 def worker_number; end # TODO: this does not work when doing threads in forks, so should remove and yield the number instead if needed # - # source://parallel//lib/parallel.rb#355 + # source://parallel//lib/parallel.rb#351 def worker_number=(worker_num); end private - # source://parallel//lib/parallel.rb#361 + # source://parallel//lib/parallel.rb#384 def add_progress_bar!(job_factory, options); end - # source://parallel//lib/parallel.rb#624 + # source://parallel//lib/parallel.rb#699 + def available_processor_count; end + + # source://parallel//lib/parallel.rb#647 def call_with_index(item, index, options, &block); end - # source://parallel//lib/parallel.rb#556 + # source://parallel//lib/parallel.rb#579 def create_workers(job_factory, options, &block); end # options is either a Integer or a Hash with :count # - # source://parallel//lib/parallel.rb#614 + # source://parallel//lib/parallel.rb#637 def extract_count_from_options(options); end - # source://parallel//lib/parallel.rb#642 + # source://parallel//lib/parallel.rb#665 def instrument_finish(item, index, result, options); end - # source://parallel//lib/parallel.rb#647 + # yield results in the order of the input items + # needs to use `options` to store state between executions + # needs to use `done` index since a nil result would also be valid + # + # source://parallel//lib/parallel.rb#674 + def instrument_finish_in_order(item, index, result, options); end + + # source://parallel//lib/parallel.rb#694 def instrument_start(item, index, options); end - # source://parallel//lib/parallel.rb#590 + # source://parallel//lib/parallel.rb#357 + def physical_processor_count_windows; end + + # source://parallel//lib/parallel.rb#613 def process_incoming_jobs(read, write, job_factory, options, &block); end - # source://parallel//lib/parallel.rb#544 + # source://parallel//lib/parallel.rb#567 def replace_worker(job_factory, workers, index, options, blk); end - # source://parallel//lib/parallel.rb#635 + # source://parallel//lib/parallel.rb#378 + def run(command); end + + # source://parallel//lib/parallel.rb#658 def with_instrumentation(item, index, options); end - # source://parallel//lib/parallel.rb#386 + # source://parallel//lib/parallel.rb#409 def work_direct(job_factory, options, &block); end - # source://parallel//lib/parallel.rb#496 + # source://parallel//lib/parallel.rb#519 def work_in_processes(job_factory, options, &blk); end - # source://parallel//lib/parallel.rb#430 + # source://parallel//lib/parallel.rb#453 def work_in_ractors(job_factory, options); end - # source://parallel//lib/parallel.rb#405 + # source://parallel//lib/parallel.rb#428 def work_in_threads(job_factory, options, &block); end - # source://parallel//lib/parallel.rb#564 + # source://parallel//lib/parallel.rb#587 def worker(job_factory, options, &block); end end end diff --git a/sorbet/rbi/gems/parallel_tests@4.2.1.rbi b/sorbet/rbi/gems/parallel_tests@4.7.1.rbi similarity index 79% rename from sorbet/rbi/gems/parallel_tests@4.2.1.rbi rename to sorbet/rbi/gems/parallel_tests@4.7.1.rbi index 49f744dc4..6e6936d94 100644 --- a/sorbet/rbi/gems/parallel_tests@4.2.1.rbi +++ b/sorbet/rbi/gems/parallel_tests@4.7.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `parallel_tests` gem. # Please instead update this file by running `bin/tapioca gem parallel_tests`. + # rake tasks for Rails 3+ # # source://parallel_tests//lib/parallel_tests/railtie.rb#3 @@ -13,10 +14,10 @@ module ParallelTests # # @return [Boolean] # - # source://parallel_tests//lib/parallel_tests.rb#50 + # source://parallel_tests//lib/parallel_tests.rb#52 def bundler_enabled?; end - # source://parallel_tests//lib/parallel_tests.rb#95 + # source://parallel_tests//lib/parallel_tests.rb#97 def delta; end # source://parallel_tests//lib/parallel_tests.rb#16 @@ -24,18 +25,18 @@ module ParallelTests # @return [Boolean] # - # source://parallel_tests//lib/parallel_tests.rb#66 + # source://parallel_tests//lib/parallel_tests.rb#68 def first_process?; end # @return [Boolean] # - # source://parallel_tests//lib/parallel_tests.rb#70 + # source://parallel_tests//lib/parallel_tests.rb#72 def last_process?; end - # source://parallel_tests//lib/parallel_tests.rb#91 + # source://parallel_tests//lib/parallel_tests.rb#93 def now; end - # source://parallel_tests//lib/parallel_tests.rb#87 + # source://parallel_tests//lib/parallel_tests.rb#89 def number_of_running_processes; end # source://parallel_tests//lib/parallel_tests.rb#41 @@ -47,13 +48,13 @@ module ParallelTests # source://parallel_tests//lib/parallel_tests.rb#45 def stop_all_processes; end - # source://parallel_tests//lib/parallel_tests.rb#82 + # source://parallel_tests//lib/parallel_tests.rb#84 def wait_for_other_processes_to_finish; end # source://parallel_tests//lib/parallel_tests.rb#24 def with_pid_file; end - # source://parallel_tests//lib/parallel_tests.rb#78 + # source://parallel_tests//lib/parallel_tests.rb#80 def with_ruby_binary(command); end end end @@ -69,66 +70,66 @@ class ParallelTests::CLI # # @return [Boolean] # - # source://parallel_tests//lib/parallel_tests/cli.rb#177 + # source://parallel_tests//lib/parallel_tests/cli.rb#178 def any_test_failed?(test_results); end - # source://parallel_tests//lib/parallel_tests/cli.rb#340 + # source://parallel_tests//lib/parallel_tests/cli.rb#362 def append_test_options(options, argv); end - # source://parallel_tests//lib/parallel_tests/cli.rb#381 + # source://parallel_tests//lib/parallel_tests/cli.rb#403 def detailed_duration(seconds); end - # source://parallel_tests//lib/parallel_tests/cli.rb#355 + # source://parallel_tests//lib/parallel_tests/cli.rb#377 def execute_command_in_parallel(command, num_processes, options); end # source://parallel_tests//lib/parallel_tests/cli.rb#56 def execute_in_parallel(items, num_processes, options); end - # source://parallel_tests//lib/parallel_tests/cli.rb#329 + # source://parallel_tests//lib/parallel_tests/cli.rb#351 def extract_file_paths(argv); end - # source://parallel_tests//lib/parallel_tests/cli.rb#335 + # source://parallel_tests//lib/parallel_tests/cli.rb#357 def extract_test_options(argv); end - # source://parallel_tests//lib/parallel_tests/cli.rb#388 + # source://parallel_tests//lib/parallel_tests/cli.rb#410 def final_fail_message; end # @return [Boolean] # - # source://parallel_tests//lib/parallel_tests/cli.rb#398 + # source://parallel_tests//lib/parallel_tests/cli.rb#420 def first_is_1?; end # source://parallel_tests//lib/parallel_tests/cli.rb#31 def handle_interrupt; end - # source://parallel_tests//lib/parallel_tests/cli.rb#348 + # source://parallel_tests//lib/parallel_tests/cli.rb#370 def load_runner(type); end - # source://parallel_tests//lib/parallel_tests/cli.rb#126 + # source://parallel_tests//lib/parallel_tests/cli.rb#127 def lock(lockfile); end - # source://parallel_tests//lib/parallel_tests/cli.rb#181 + # source://parallel_tests//lib/parallel_tests/cli.rb#182 def parse_options!(argv); end - # source://parallel_tests//lib/parallel_tests/cli.rb#166 + # source://parallel_tests//lib/parallel_tests/cli.rb#167 def pluralize(n, singular); end - # source://parallel_tests//lib/parallel_tests/cli.rb#144 + # source://parallel_tests//lib/parallel_tests/cli.rb#145 def report_failure_rerun_commmand(test_results, options); end - # source://parallel_tests//lib/parallel_tests/cli.rb#158 + # source://parallel_tests//lib/parallel_tests/cli.rb#159 def report_number_of_tests(groups); end - # source://parallel_tests//lib/parallel_tests/cli.rb#136 + # source://parallel_tests//lib/parallel_tests/cli.rb#137 def report_results(test_results, options); end - # source://parallel_tests//lib/parallel_tests/cli.rb#376 + # source://parallel_tests//lib/parallel_tests/cli.rb#398 def report_time_taken(&block); end - # source://parallel_tests//lib/parallel_tests/cli.rb#118 + # source://parallel_tests//lib/parallel_tests/cli.rb#119 def reprint_output(result, lockfile); end - # source://parallel_tests//lib/parallel_tests/cli.rb#110 + # source://parallel_tests//lib/parallel_tests/cli.rb#111 def run_tests(group, process_number, num_processes, options); end # source://parallel_tests//lib/parallel_tests/cli.rb#71 @@ -136,12 +137,12 @@ class ParallelTests::CLI # CI systems often fail when there is no output for a long time, so simulate some output # - # source://parallel_tests//lib/parallel_tests/cli.rb#404 + # source://parallel_tests//lib/parallel_tests/cli.rb#426 def simulate_output_for_ci(simulate); end # @return [Boolean] # - # source://parallel_tests//lib/parallel_tests/cli.rb#394 + # source://parallel_tests//lib/parallel_tests/cli.rb#416 def use_colors?; end end diff --git a/sorbet/rbi/gems/parser@3.2.2.3.rbi b/sorbet/rbi/gems/parser@3.3.4.2.rbi similarity index 75% rename from sorbet/rbi/gems/parser@3.2.2.3.rbi rename to sorbet/rbi/gems/parser@3.3.4.2.rbi index 680c9da48..5c8811c71 100644 --- a/sorbet/rbi/gems/parser@3.2.2.3.rbi +++ b/sorbet/rbi/gems/parser@3.3.4.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `parser` gem. # Please instead update this file by running `bin/tapioca gem parser`. + # @api public # # source://parser//lib/parser.rb#19 @@ -59,603 +60,605 @@ end # @api public # # source://parser//lib/parser/ast/processor.rb#9 -class Parser::AST::Processor < ::AST::Processor +class Parser::AST::Processor + include ::AST::Processor::Mixin + # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_alias(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_and(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_and_asgn(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_arg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_arg_expr(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_args(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#103 + # source://parser//lib/parser/ast/processor.rb#105 def on_argument(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_array(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_array_pattern(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_array_pattern_with_tail(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#32 + # source://parser//lib/parser/ast/processor.rb#34 def on_back_ref(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_begin(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_block(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_block_pass(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_blockarg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_blockarg_expr(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_break(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_case(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_case_match(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#87 + # source://parser//lib/parser/ast/processor.rb#89 def on_casgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_class(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#79 + # source://parser//lib/parser/ast/processor.rb#81 def on_const(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_const_pattern(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#179 + # source://parser//lib/parser/ast/processor.rb#181 def on_csend(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#32 + # source://parser//lib/parser/ast/processor.rb#34 def on_cvar(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#56 + # source://parser//lib/parser/ast/processor.rb#58 def on_cvasgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#158 + # source://parser//lib/parser/ast/processor.rb#160 def on_def(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_defined?(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#167 + # source://parser//lib/parser/ast/processor.rb#169 def on_defs(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_dstr(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_dsym(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_eflipflop(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#286 + # source://parser//lib/parser/ast/processor.rb#288 def on_empty_else(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_ensure(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_erange(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_find_pattern(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_for(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_forward_arg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_forwarded_kwrestarg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_forwarded_restarg(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#32 + # source://parser//lib/parser/ast/processor.rb#34 def on_gvar(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#56 + # source://parser//lib/parser/ast/processor.rb#58 def on_gvasgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_hash(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_hash_pattern(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_if(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_if_guard(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_iflipflop(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_in_match(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_in_pattern(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_index(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_indexasgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_irange(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#32 + # source://parser//lib/parser/ast/processor.rb#34 def on_ivar(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#56 + # source://parser//lib/parser/ast/processor.rb#58 def on_ivasgn(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_kwarg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_kwargs(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_kwbegin(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_kwoptarg(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_kwrestarg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_kwsplat(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_lambda(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#32 + # source://parser//lib/parser/ast/processor.rb#34 def on_lvar(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#56 + # source://parser//lib/parser/ast/processor.rb#58 def on_lvasgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_masgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_match_alt(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_match_as(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_match_current_line(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_match_pattern(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_match_pattern_p(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_match_rest(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#32 + # source://parser//lib/parser/ast/processor.rb#34 def on_match_var(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_match_with_lvasgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_mlhs(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_module(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_next(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_not(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#32 + # source://parser//lib/parser/ast/processor.rb#34 def on_nth_ref(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#196 + # source://parser//lib/parser/ast/processor.rb#198 def on_numblock(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#68 + # source://parser//lib/parser/ast/processor.rb#70 def on_op_asgn(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_optarg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_or(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_or_asgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_pair(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_pin(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_postexe(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_preexe(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#130 + # source://parser//lib/parser/ast/processor.rb#132 def on_procarg0(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_redo(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_regexp(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_resbody(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_rescue(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_restarg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_restarg_expr(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_retry(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_return(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_sclass(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#179 + # source://parser//lib/parser/ast/processor.rb#181 def on_send(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#116 + # source://parser//lib/parser/ast/processor.rb#118 def on_shadowarg(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_splat(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_super(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_undef(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_unless_guard(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_until(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_until_post(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#27 + # source://parser//lib/parser/ast/processor.rb#29 def on_var(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#43 + # source://parser//lib/parser/ast/processor.rb#45 def on_vasgn(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_when(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_while(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_while_post(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_xstr(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def on_yield(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#279 + # source://parser//lib/parser/ast/processor.rb#281 def process_argument_node(node); end # @api public # - # source://parser//lib/parser/ast/processor.rb#10 + # source://parser//lib/parser/ast/processor.rb#12 def process_regular_node(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#271 + # source://parser//lib/parser/ast/processor.rb#273 def process_var_asgn_node(node); end # @api public # @private # - # source://parser//lib/parser/ast/processor.rb#263 + # source://parser//lib/parser/ast/processor.rb#265 def process_variable_node(node); end end @@ -868,7 +871,7 @@ end # @api public # -# source://parser//lib/parser.rb#77 +# source://parser//lib/parser.rb#78 module Parser::Builders; end # source://parser//lib/parser/builders/default.rb#8 @@ -876,7 +879,7 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#243 def initialize; end - # source://parser//lib/parser/builders/default.rb#690 + # source://parser//lib/parser/builders/default.rb#703 def __ENCODING__(__ENCODING__t); end # source://parser//lib/parser/builders/default.rb#348 @@ -885,79 +888,79 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#312 def __LINE__(__LINE__t); end - # source://parser//lib/parser/builders/default.rb#616 + # source://parser//lib/parser/builders/default.rb#622 def accessible(node); end - # source://parser//lib/parser/builders/default.rb#865 + # source://parser//lib/parser/builders/default.rb#878 def alias(alias_t, to, from); end - # source://parser//lib/parser/builders/default.rb#904 + # source://parser//lib/parser/builders/default.rb#917 def arg(name_t); end - # source://parser//lib/parser/builders/default.rb#994 + # source://parser//lib/parser/builders/default.rb#1007 def arg_expr(expr); end - # source://parser//lib/parser/builders/default.rb#874 + # source://parser//lib/parser/builders/default.rb#887 def args(begin_t, args, end_t, check_args = T.unsafe(nil)); end # source://parser//lib/parser/builders/default.rb#440 def array(begin_t, elements, end_t); end - # source://parser//lib/parser/builders/default.rb#1577 + # source://parser//lib/parser/builders/default.rb#1590 def array_pattern(lbrack_t, elements, rbrack_t); end - # source://parser//lib/parser/builders/default.rb#754 + # source://parser//lib/parser/builders/default.rb#767 def assign(lhs, eql_t, rhs); end - # source://parser//lib/parser/builders/default.rb#699 + # source://parser//lib/parser/builders/default.rb#712 def assignable(node); end # source://parser//lib/parser/builders/default.rb#540 def associate(begin_t, pairs, end_t); end - # source://parser//lib/parser/builders/default.rb#1158 + # source://parser//lib/parser/builders/default.rb#1171 def attr_asgn(receiver, dot_t, selector_t); end - # source://parser//lib/parser/builders/default.rb#606 + # source://parser//lib/parser/builders/default.rb#612 def back_ref(token); end - # source://parser//lib/parser/builders/default.rb#1422 + # source://parser//lib/parser/builders/default.rb#1435 def begin(begin_t, body, end_t); end - # source://parser//lib/parser/builders/default.rb#1364 + # source://parser//lib/parser/builders/default.rb#1377 def begin_body(compound_stmt, rescue_bodies = T.unsafe(nil), else_t = T.unsafe(nil), else_ = T.unsafe(nil), ensure_t = T.unsafe(nil), ensure_ = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1440 + # source://parser//lib/parser/builders/default.rb#1453 def begin_keyword(begin_t, body, end_t); end - # source://parser//lib/parser/builders/default.rb#1192 + # source://parser//lib/parser/builders/default.rb#1205 def binary_op(receiver, operator_t, arg); end - # source://parser//lib/parser/builders/default.rb#1109 + # source://parser//lib/parser/builders/default.rb#1122 def block(method_call, begin_t, args, body, end_t); end - # source://parser//lib/parser/builders/default.rb#1144 + # source://parser//lib/parser/builders/default.rb#1157 def block_pass(amper_t, arg); end - # source://parser//lib/parser/builders/default.rb#969 + # source://parser//lib/parser/builders/default.rb#982 def blockarg(amper_t, name_t); end - # source://parser//lib/parser/builders/default.rb#1014 + # source://parser//lib/parser/builders/default.rb#1027 def blockarg_expr(amper_t, expr); end - # source://parser//lib/parser/builders/default.rb#1100 + # source://parser//lib/parser/builders/default.rb#1113 def call_lambda(lambda_t); end - # source://parser//lib/parser/builders/default.rb#1083 + # source://parser//lib/parser/builders/default.rb#1096 def call_method(receiver, dot_t, selector_t, lparen_t = T.unsafe(nil), args = T.unsafe(nil), rparen_t = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1055 + # source://parser//lib/parser/builders/default.rb#1068 def call_type_for_dot(dot_t); end - # source://parser//lib/parser/builders/default.rb#1297 + # source://parser//lib/parser/builders/default.rb#1310 def case(case_t, expr, when_bodies, else_t, else_body, end_t); end - # source://parser//lib/parser/builders/default.rb#1460 + # source://parser//lib/parser/builders/default.rb#1473 def case_match(case_t, expr, in_bodies, else_t, else_body, end_t); end # source://parser//lib/parser/builders/default.rb#343 @@ -966,55 +969,55 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#284 def complex(complex_t); end - # source://parser//lib/parser/builders/default.rb#1410 + # source://parser//lib/parser/builders/default.rb#1423 def compstmt(statements); end - # source://parser//lib/parser/builders/default.rb#1273 + # source://parser//lib/parser/builders/default.rb#1286 def condition(cond_t, cond, then_t, if_true, else_t, if_false, end_t); end - # source://parser//lib/parser/builders/default.rb#1279 + # source://parser//lib/parser/builders/default.rb#1292 def condition_mod(if_true, if_false, cond_t, cond); end - # source://parser//lib/parser/builders/default.rb#673 + # source://parser//lib/parser/builders/default.rb#686 def const(name_t); end - # source://parser//lib/parser/builders/default.rb#685 + # source://parser//lib/parser/builders/default.rb#698 def const_fetch(scope, t_colon2, name_t); end - # source://parser//lib/parser/builders/default.rb#678 + # source://parser//lib/parser/builders/default.rb#691 def const_global(t_colon3, name_t); end - # source://parser//lib/parser/builders/default.rb#750 + # source://parser//lib/parser/builders/default.rb#763 def const_op_assignable(node); end - # source://parser//lib/parser/builders/default.rb#1607 + # source://parser//lib/parser/builders/default.rb#1620 def const_pattern(const, ldelim_t, pattern, rdelim_t); end - # source://parser//lib/parser/builders/default.rb#601 + # source://parser//lib/parser/builders/default.rb#607 def cvar(token); end # source://parser//lib/parser/builders/default.rb#388 def dedent_string(node, dedent_level); end - # source://parser//lib/parser/builders/default.rb#801 + # source://parser//lib/parser/builders/default.rb#814 def def_class(class_t, name, lt_t, superclass, body, end_t); end - # source://parser//lib/parser/builders/default.rb#832 + # source://parser//lib/parser/builders/default.rb#845 def def_endless_method(def_t, name_t, args, assignment_t, body); end - # source://parser//lib/parser/builders/default.rb#850 + # source://parser//lib/parser/builders/default.rb#863 def def_endless_singleton(def_t, definee, dot_t, name_t, args, assignment_t, body); end - # source://parser//lib/parser/builders/default.rb#824 + # source://parser//lib/parser/builders/default.rb#837 def def_method(def_t, name_t, args, body, end_t); end - # source://parser//lib/parser/builders/default.rb#814 + # source://parser//lib/parser/builders/default.rb#827 def def_module(module_t, name, body, end_t); end - # source://parser//lib/parser/builders/default.rb#808 + # source://parser//lib/parser/builders/default.rb#821 def def_sclass(class_t, lshft_t, expr, body, end_t); end - # source://parser//lib/parser/builders/default.rb#840 + # source://parser//lib/parser/builders/default.rb#853 def def_singleton(def_t, definee, dot_t, name_t, args, body, end_t); end # source://parser//lib/parser/builders/default.rb#237 @@ -1026,52 +1029,52 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#265 def false(false_t); end - # source://parser//lib/parser/builders/default.rb#1598 + # source://parser//lib/parser/builders/default.rb#1611 def find_pattern(lbrack_t, elements, rbrack_t); end # source://parser//lib/parser/builders/default.rb#276 def float(float_t); end - # source://parser//lib/parser/builders/default.rb#1318 + # source://parser//lib/parser/builders/default.rb#1331 def for(for_t, iterator, in_t, iteratee, do_t, body, end_t); end - # source://parser//lib/parser/builders/default.rb#900 + # source://parser//lib/parser/builders/default.rb#913 def forward_arg(dots_t); end - # source://parser//lib/parser/builders/default.rb#890 + # source://parser//lib/parser/builders/default.rb#903 def forward_only_args(begin_t, dots_t, end_t); end - # source://parser//lib/parser/builders/default.rb#1071 + # source://parser//lib/parser/builders/default.rb#1084 def forwarded_args(dots_t); end - # source://parser//lib/parser/builders/default.rb#1079 + # source://parser//lib/parser/builders/default.rb#1092 def forwarded_kwrestarg(dstar_t); end - # source://parser//lib/parser/builders/default.rb#1075 + # source://parser//lib/parser/builders/default.rb#1088 def forwarded_restarg(star_t); end # source://parser//lib/parser/builders/default.rb#596 def gvar(token); end - # source://parser//lib/parser/builders/default.rb#1571 + # source://parser//lib/parser/builders/default.rb#1584 def hash_pattern(lbrace_t, kwargs, rbrace_t); end # source://parser//lib/parser/builders/default.rb#586 def ident(token); end - # source://parser//lib/parser/builders/default.rb#1487 + # source://parser//lib/parser/builders/default.rb#1500 def if_guard(if_t, if_body); end - # source://parser//lib/parser/builders/default.rb#1466 + # source://parser//lib/parser/builders/default.rb#1479 def in_match(lhs, in_t, rhs); end - # source://parser//lib/parser/builders/default.rb#1481 + # source://parser//lib/parser/builders/default.rb#1494 def in_pattern(in_t, pattern, guard, then_t, body); end - # source://parser//lib/parser/builders/default.rb#1167 + # source://parser//lib/parser/builders/default.rb#1180 def index(receiver, lbrack_t, indexes, rbrack_t); end - # source://parser//lib/parser/builders/default.rb#1181 + # source://parser//lib/parser/builders/default.rb#1194 def index_asgn(receiver, lbrack_t, indexes, rbrack_t); end # source://parser//lib/parser/builders/default.rb#272 @@ -1080,103 +1083,103 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#591 def ivar(token); end - # source://parser//lib/parser/builders/default.rb#1326 + # source://parser//lib/parser/builders/default.rb#1339 def keyword_cmd(type, keyword_t, lparen_t = T.unsafe(nil), args = T.unsafe(nil), rparen_t = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#931 + # source://parser//lib/parser/builders/default.rb#944 def kwarg(name_t); end - # source://parser//lib/parser/builders/default.rb#957 + # source://parser//lib/parser/builders/default.rb#970 def kwnilarg(dstar_t, nil_t); end - # source://parser//lib/parser/builders/default.rb#938 + # source://parser//lib/parser/builders/default.rb#951 def kwoptarg(name_t, value); end - # source://parser//lib/parser/builders/default.rb#945 + # source://parser//lib/parser/builders/default.rb#958 def kwrestarg(dstar_t, name_t = T.unsafe(nil)); end # source://parser//lib/parser/builders/default.rb#535 def kwsplat(dstar_t, arg); end - # source://parser//lib/parser/builders/default.rb#1266 + # source://parser//lib/parser/builders/default.rb#1279 def logical_op(type, lhs, op_t, rhs); end - # source://parser//lib/parser/builders/default.rb#1304 + # source://parser//lib/parser/builders/default.rb#1317 def loop(type, keyword_t, cond, do_t, body, end_t); end - # source://parser//lib/parser/builders/default.rb#1309 + # source://parser//lib/parser/builders/default.rb#1322 def loop_mod(type, body, keyword_t, cond); end - # source://parser//lib/parser/builders/default.rb#1621 + # source://parser//lib/parser/builders/default.rb#1634 def match_alt(left, pipe_t, right); end - # source://parser//lib/parser/builders/default.rb#1628 + # source://parser//lib/parser/builders/default.rb#1641 def match_as(value, assoc_t, as); end - # source://parser//lib/parser/builders/default.rb#1507 + # source://parser//lib/parser/builders/default.rb#1520 def match_hash_var(name_t); end - # source://parser//lib/parser/builders/default.rb#1521 + # source://parser//lib/parser/builders/default.rb#1534 def match_hash_var_from_str(begin_t, strings, end_t); end - # source://parser//lib/parser/builders/default.rb#1659 + # source://parser//lib/parser/builders/default.rb#1672 def match_label(label_type, label); end - # source://parser//lib/parser/builders/default.rb#1635 + # source://parser//lib/parser/builders/default.rb#1648 def match_nil_pattern(dstar_t, nil_t); end - # source://parser//lib/parser/builders/default.rb#1214 + # source://parser//lib/parser/builders/default.rb#1227 def match_op(receiver, match_t, arg); end - # source://parser//lib/parser/builders/default.rb#1640 + # source://parser//lib/parser/builders/default.rb#1653 def match_pair(label_type, label, value); end - # source://parser//lib/parser/builders/default.rb#1471 + # source://parser//lib/parser/builders/default.rb#1484 def match_pattern(lhs, match_t, rhs); end - # source://parser//lib/parser/builders/default.rb#1476 + # source://parser//lib/parser/builders/default.rb#1489 def match_pattern_p(lhs, match_t, rhs); end - # source://parser//lib/parser/builders/default.rb#1560 + # source://parser//lib/parser/builders/default.rb#1573 def match_rest(star_t, name_t = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1495 + # source://parser//lib/parser/builders/default.rb#1508 def match_var(name_t); end - # source://parser//lib/parser/builders/default.rb#1603 + # source://parser//lib/parser/builders/default.rb#1616 def match_with_trailing_comma(match, comma_t); end - # source://parser//lib/parser/builders/default.rb#792 + # source://parser//lib/parser/builders/default.rb#805 def multi_assign(lhs, eql_t, rhs); end - # source://parser//lib/parser/builders/default.rb#787 + # source://parser//lib/parser/builders/default.rb#800 def multi_lhs(begin_t, items, end_t); end # source://parser//lib/parser/builders/default.rb#255 def nil(nil_t); end - # source://parser//lib/parser/builders/default.rb#1242 + # source://parser//lib/parser/builders/default.rb#1255 def not_op(not_t, begin_t = T.unsafe(nil), receiver = T.unsafe(nil), end_t = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#611 + # source://parser//lib/parser/builders/default.rb#617 def nth_ref(token); end - # source://parser//lib/parser/builders/default.rb#886 + # source://parser//lib/parser/builders/default.rb#899 def numargs(max_numparam); end - # source://parser//lib/parser/builders/default.rb#1025 + # source://parser//lib/parser/builders/default.rb#1038 def objc_kwarg(kwname_t, assoc_t, name_t); end - # source://parser//lib/parser/builders/default.rb#1039 + # source://parser//lib/parser/builders/default.rb#1052 def objc_restarg(star_t, name = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1149 + # source://parser//lib/parser/builders/default.rb#1162 def objc_varargs(pair, rest_of_varargs); end - # source://parser//lib/parser/builders/default.rb#761 + # source://parser//lib/parser/builders/default.rb#774 def op_assign(lhs, op_t, rhs); end - # source://parser//lib/parser/builders/default.rb#911 + # source://parser//lib/parser/builders/default.rb#924 def optarg(name_t, eql_t, value); end # source://parser//lib/parser/builders/default.rb#488 @@ -1200,16 +1203,16 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#225 def parser=(_arg0); end - # source://parser//lib/parser/builders/default.rb#1616 + # source://parser//lib/parser/builders/default.rb#1629 def pin(pin_t, var); end - # source://parser//lib/parser/builders/default.rb#1349 + # source://parser//lib/parser/builders/default.rb#1362 def postexe(postexe_t, lbrace_t, compstmt, rbrace_t); end - # source://parser//lib/parser/builders/default.rb#1344 + # source://parser//lib/parser/builders/default.rb#1357 def preexe(preexe_t, lbrace_t, compstmt, rbrace_t); end - # source://parser//lib/parser/builders/default.rb#979 + # source://parser//lib/parser/builders/default.rb#992 def procarg0(arg); end # source://parser//lib/parser/builders/default.rb#572 @@ -1227,19 +1230,19 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#417 def regexp_options(regopt_t); end - # source://parser//lib/parser/builders/default.rb#1356 + # source://parser//lib/parser/builders/default.rb#1369 def rescue_body(rescue_t, exc_list, assoc_t, exc_var, then_t, compound_stmt); end - # source://parser//lib/parser/builders/default.rb#920 + # source://parser//lib/parser/builders/default.rb#933 def restarg(star_t, name_t = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1003 + # source://parser//lib/parser/builders/default.rb#1016 def restarg_expr(star_t, expr = T.unsafe(nil)); end # source://parser//lib/parser/builders/default.rb#581 def self(token); end - # source://parser//lib/parser/builders/default.rb#962 + # source://parser//lib/parser/builders/default.rb#975 def shadowarg(name_t); end # source://parser//lib/parser/builders/default.rb#445 @@ -1266,7 +1269,7 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#469 def symbols_compose(begin_t, parts, end_t); end - # source://parser//lib/parser/builders/default.rb#1284 + # source://parser//lib/parser/builders/default.rb#1297 def ternary(cond, question_t, if_true, colon_t, if_false); end # source://parser//lib/parser/builders/default.rb#260 @@ -1275,16 +1278,16 @@ class Parser::Builders::Default # source://parser//lib/parser/builders/default.rb#294 def unary_num(unary_t, numeric); end - # source://parser//lib/parser/builders/default.rb#1230 + # source://parser//lib/parser/builders/default.rb#1243 def unary_op(op_t, receiver); end - # source://parser//lib/parser/builders/default.rb#860 + # source://parser//lib/parser/builders/default.rb#873 def undef_method(undef_t, names); end - # source://parser//lib/parser/builders/default.rb#1491 + # source://parser//lib/parser/builders/default.rb#1504 def unless_guard(unless_t, unless_body); end - # source://parser//lib/parser/builders/default.rb#1291 + # source://parser//lib/parser/builders/default.rb#1304 def when(when_t, patterns, then_t, body); end # source://parser//lib/parser/builders/default.rb#455 @@ -1298,184 +1301,184 @@ class Parser::Builders::Default private - # source://parser//lib/parser/builders/default.rb#1798 + # source://parser//lib/parser/builders/default.rb#1821 def arg_name_collides?(this_name, that_name); end - # source://parser//lib/parser/builders/default.rb#1994 + # source://parser//lib/parser/builders/default.rb#2017 def arg_prefix_map(op_t, name_t = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1968 + # source://parser//lib/parser/builders/default.rb#1991 def binary_op_map(left_e, op_t, right_e); end - # source://parser//lib/parser/builders/default.rb#2096 + # source://parser//lib/parser/builders/default.rb#2119 def block_map(receiver_l, begin_t, end_t); end - # source://parser//lib/parser/builders/default.rb#1773 + # source://parser//lib/parser/builders/default.rb#1796 def check_assignment_to_numparam(name, loc); end - # source://parser//lib/parser/builders/default.rb#1675 + # source://parser//lib/parser/builders/default.rb#1688 def check_condition(cond); end - # source://parser//lib/parser/builders/default.rb#1744 + # source://parser//lib/parser/builders/default.rb#1767 def check_duplicate_arg(this_arg, map = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1719 + # source://parser//lib/parser/builders/default.rb#1742 def check_duplicate_args(args, map = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1831 + # source://parser//lib/parser/builders/default.rb#1854 def check_duplicate_pattern_key(name, loc); end - # source://parser//lib/parser/builders/default.rb#1821 + # source://parser//lib/parser/builders/default.rb#1844 def check_duplicate_pattern_variable(name, loc); end - # source://parser//lib/parser/builders/default.rb#1813 + # source://parser//lib/parser/builders/default.rb#1836 def check_lvar_name(name, loc); end - # source://parser//lib/parser/builders/default.rb#1788 + # source://parser//lib/parser/builders/default.rb#1811 def check_reserved_for_numparam(name, loc); end - # source://parser//lib/parser/builders/default.rb#2253 + # source://parser//lib/parser/builders/default.rb#2280 def collapse_string_parts?(parts); end - # source://parser//lib/parser/builders/default.rb#1919 + # source://parser//lib/parser/builders/default.rb#1942 def collection_map(begin_t, parts, end_t); end - # source://parser//lib/parser/builders/default.rb#2123 + # source://parser//lib/parser/builders/default.rb#2146 def condition_map(keyword_t, cond_e, begin_t, body_e, else_t, else_e, end_t); end - # source://parser//lib/parser/builders/default.rb#1954 + # source://parser//lib/parser/builders/default.rb#1977 def constant_map(scope, colon2_t, name_t); end - # source://parser//lib/parser/builders/default.rb#2027 + # source://parser//lib/parser/builders/default.rb#2050 def definition_map(keyword_t, operator_t, name_t, end_t); end - # source://parser//lib/parser/builders/default.rb#1860 + # source://parser//lib/parser/builders/default.rb#1883 def delimited_string_map(string_t); end - # source://parser//lib/parser/builders/default.rb#2275 + # source://parser//lib/parser/builders/default.rb#2302 def diagnostic(type, reason, arguments, location, highlights = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#2167 + # source://parser//lib/parser/builders/default.rb#2190 def eh_keyword_map(compstmt_e, keyword_t, body_es, else_t, else_e); end - # source://parser//lib/parser/builders/default.rb#2033 + # source://parser//lib/parser/builders/default.rb#2056 def endless_definition_map(keyword_t, operator_t, name_t, assignment_t, body_e); end - # source://parser//lib/parser/builders/default.rb#1915 + # source://parser//lib/parser/builders/default.rb#1938 def expr_map(loc); end - # source://parser//lib/parser/builders/default.rb#2148 + # source://parser//lib/parser/builders/default.rb#2171 def for_map(keyword_t, in_t, begin_t, end_t); end - # source://parser//lib/parser/builders/default.rb#2195 + # source://parser//lib/parser/builders/default.rb#2218 def guard_map(keyword_t, guard_body_e); end - # source://parser//lib/parser/builders/default.rb#2085 + # source://parser//lib/parser/builders/default.rb#2108 def index_map(receiver_e, lbrack_t, rbrack_t); end - # source://parser//lib/parser/builders/default.rb#1851 + # source://parser//lib/parser/builders/default.rb#1874 def join_exprs(left_expr, right_expr); end - # source://parser//lib/parser/builders/default.rb#2101 + # source://parser//lib/parser/builders/default.rb#2124 def keyword_map(keyword_t, begin_t, args, end_t); end - # source://parser//lib/parser/builders/default.rb#2118 + # source://parser//lib/parser/builders/default.rb#2141 def keyword_mod_map(pre_e, keyword_t, post_e); end - # source://parser//lib/parser/builders/default.rb#2004 + # source://parser//lib/parser/builders/default.rb#2027 def kwarg_map(name_t, value_e = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#2306 + # source://parser//lib/parser/builders/default.rb#2333 def kwargs?(node); end - # source://parser//lib/parser/builders/default.rb#2270 + # source://parser//lib/parser/builders/default.rb#2297 def loc(token); end - # source://parser//lib/parser/builders/default.rb#2017 + # source://parser//lib/parser/builders/default.rb#2040 def module_definition_map(keyword_t, name_e, operator_t, end_t); end - # source://parser//lib/parser/builders/default.rb#1843 + # source://parser//lib/parser/builders/default.rb#1866 def n(type, children, source_map); end - # source://parser//lib/parser/builders/default.rb#1847 + # source://parser//lib/parser/builders/default.rb#1870 def n0(type, source_map); end # source://parser//lib/parser/builders/default.rb#288 def numeric(kind, token); end - # source://parser//lib/parser/builders/default.rb#1885 + # source://parser//lib/parser/builders/default.rb#1908 def pair_keyword_map(key_t, value_e); end - # source://parser//lib/parser/builders/default.rb#1900 + # source://parser//lib/parser/builders/default.rb#1923 def pair_quoted_map(begin_t, end_t, value_e); end - # source://parser//lib/parser/builders/default.rb#1871 + # source://parser//lib/parser/builders/default.rb#1894 def prefix_string_map(symbol); end - # source://parser//lib/parser/builders/default.rb#1982 + # source://parser//lib/parser/builders/default.rb#2005 def range_map(start_e, op_t, end_e); end - # source://parser//lib/parser/builders/default.rb#1949 + # source://parser//lib/parser/builders/default.rb#1972 def regexp_map(begin_t, end_t, options_e); end - # source://parser//lib/parser/builders/default.rb#2154 + # source://parser//lib/parser/builders/default.rb#2177 def rescue_body_map(keyword_t, exc_list_e, assoc_t, exc_var_e, then_t, compstmt_e); end - # source://parser//lib/parser/builders/default.rb#2296 + # source://parser//lib/parser/builders/default.rb#2323 def rewrite_hash_args_to_kwargs(args); end - # source://parser//lib/parser/builders/default.rb#2067 + # source://parser//lib/parser/builders/default.rb#2090 def send_binary_op_map(lhs_e, selector_t, rhs_e); end - # source://parser//lib/parser/builders/default.rb#2090 + # source://parser//lib/parser/builders/default.rb#2113 def send_index_map(receiver_e, lbrack_t, rbrack_t); end - # source://parser//lib/parser/builders/default.rb#2041 + # source://parser//lib/parser/builders/default.rb#2064 def send_map(receiver_e, dot_t, selector_t, begin_t = T.unsafe(nil), args = T.unsafe(nil), end_t = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#2073 + # source://parser//lib/parser/builders/default.rb#2096 def send_unary_op_map(selector_t, arg_e); end - # source://parser//lib/parser/builders/default.rb#2226 + # source://parser//lib/parser/builders/default.rb#2249 def static_regexp(parts, options); end - # source://parser//lib/parser/builders/default.rb#2246 + # source://parser//lib/parser/builders/default.rb#2269 def static_regexp_node(node); end - # source://parser//lib/parser/builders/default.rb#2209 + # source://parser//lib/parser/builders/default.rb#2232 def static_string(nodes); end - # source://parser//lib/parser/builders/default.rb#1935 + # source://parser//lib/parser/builders/default.rb#1958 def string_map(begin_t, parts, end_t); end - # source://parser//lib/parser/builders/default.rb#2262 + # source://parser//lib/parser/builders/default.rb#2289 def string_value(token); end - # source://parser//lib/parser/builders/default.rb#2143 + # source://parser//lib/parser/builders/default.rb#2166 def ternary_map(begin_e, question_t, mid_e, colon_t, end_e); end - # source://parser//lib/parser/builders/default.rb#1856 + # source://parser//lib/parser/builders/default.rb#1879 def token_map(token); end - # source://parser//lib/parser/builders/default.rb#1972 + # source://parser//lib/parser/builders/default.rb#1995 def unary_op_map(op_t, arg_e = T.unsafe(nil)); end - # source://parser//lib/parser/builders/default.rb#1880 + # source://parser//lib/parser/builders/default.rb#1903 def unquoted_map(token); end - # source://parser//lib/parser/builders/default.rb#2284 + # source://parser//lib/parser/builders/default.rb#2311 def validate_definee(definee); end - # source://parser//lib/parser/builders/default.rb#1758 + # source://parser//lib/parser/builders/default.rb#1781 def validate_no_forward_arg_after_restarg(args); end - # source://parser//lib/parser/builders/default.rb#2258 + # source://parser//lib/parser/builders/default.rb#2285 def value(token); end - # source://parser//lib/parser/builders/default.rb#2061 + # source://parser//lib/parser/builders/default.rb#2084 def var_send_map(variable_e); end - # source://parser//lib/parser/builders/default.rb#1964 + # source://parser//lib/parser/builders/default.rb#1987 def variable_map(name_t); end class << self @@ -1671,8 +1674,8 @@ class Parser::CurrentArgStack def top; end end -# source://parser//lib/parser/current.rb#111 -Parser::CurrentRuby = Parser::Ruby32 +# source://parser//lib/parser/current.rb#120 +Parser::CurrentRuby = Parser::Ruby33 # @api private # @@ -2090,69 +2093,69 @@ class Parser::Lexer protected - # source://parser//lib/parser/lexer-F1.rb#14631 + # source://parser//lib/parser/lexer-F1.rb#14692 def arg_or_cmdarg(cmd_state); end - # source://parser//lib/parser/lexer-F1.rb#14693 + # source://parser//lib/parser/lexer-F1.rb#14754 def check_ambiguous_slash(tm); end - # source://parser//lib/parser/lexer-F1.rb#14655 + # source://parser//lib/parser/lexer-F1.rb#14716 def diagnostic(type, reason, arguments = T.unsafe(nil), location = T.unsafe(nil), highlights = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14661 + # source://parser//lib/parser/lexer-F1.rb#14722 def e_lbrace; end - # source://parser//lib/parser/lexer-F1.rb#14605 + # source://parser//lib/parser/lexer-F1.rb#14666 def emit(type, value = T.unsafe(nil), s = T.unsafe(nil), e = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14714 + # source://parser//lib/parser/lexer-F1.rb#14775 def emit_class_var(ts = T.unsafe(nil), te = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14742 + # source://parser//lib/parser/lexer-F1.rb#14803 def emit_colon_with_digits(p, tm, diag_msg); end - # source://parser//lib/parser/lexer-F1.rb#14639 + # source://parser//lib/parser/lexer-F1.rb#14700 def emit_comment(s = T.unsafe(nil), e = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14651 + # source://parser//lib/parser/lexer-F1.rb#14712 def emit_comment_from_range(p, pe); end - # source://parser//lib/parser/lexer-F1.rb#14621 + # source://parser//lib/parser/lexer-F1.rb#14682 def emit_do(do_block = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14704 + # source://parser//lib/parser/lexer-F1.rb#14765 def emit_global_var(ts = T.unsafe(nil), te = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14722 + # source://parser//lib/parser/lexer-F1.rb#14783 def emit_instance_var(ts = T.unsafe(nil), te = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14730 + # source://parser//lib/parser/lexer-F1.rb#14791 def emit_rbrace_rparen_rbrack; end - # source://parser//lib/parser/lexer-F1.rb#14752 + # source://parser//lib/parser/lexer-F1.rb#14813 def emit_singleton_class; end - # source://parser//lib/parser/lexer-F1.rb#14615 + # source://parser//lib/parser/lexer-F1.rb#14676 def emit_table(table, s = T.unsafe(nil), e = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14670 + # source://parser//lib/parser/lexer-F1.rb#14731 def numeric_literal_int; end - # source://parser//lib/parser/lexer-F1.rb#14689 + # source://parser//lib/parser/lexer-F1.rb#14750 def on_newline(p); end - # source://parser//lib/parser/lexer-F1.rb#14601 + # source://parser//lib/parser/lexer-F1.rb#14662 def range(s = T.unsafe(nil), e = T.unsafe(nil)); end - # source://parser//lib/parser/lexer-F1.rb#14592 + # source://parser//lib/parser/lexer-F1.rb#14653 def stack_pop; end - # source://parser//lib/parser/lexer-F1.rb#14597 + # source://parser//lib/parser/lexer-F1.rb#14658 def tok(s = T.unsafe(nil), e = T.unsafe(nil)); end # @return [Boolean] # - # source://parser//lib/parser/lexer-F1.rb#14588 + # source://parser//lib/parser/lexer-F1.rb#14649 def version?(*versions); end class << self @@ -2499,13 +2502,13 @@ end # source://parser//lib/parser/lexer/dedenter.rb#7 Parser::Lexer::Dedenter::TAB_WIDTH = T.let(T.unsafe(nil), Integer) -# source://parser//lib/parser/lexer-F1.rb#14799 +# source://parser//lib/parser/lexer-F1.rb#14860 Parser::Lexer::ESCAPE_WHITESPACE = T.let(T.unsafe(nil), Hash) -# source://parser//lib/parser/lexer-F1.rb#14785 +# source://parser//lib/parser/lexer-F1.rb#14846 Parser::Lexer::KEYWORDS = T.let(T.unsafe(nil), Hash) -# source://parser//lib/parser/lexer-F1.rb#14792 +# source://parser//lib/parser/lexer-F1.rb#14853 Parser::Lexer::KEYWORDS_BEGIN = T.let(T.unsafe(nil), Hash) # source://parser//lib/parser/lexer-F1.rb#8362 @@ -2513,108 +2516,114 @@ Parser::Lexer::LEX_STATES = T.let(T.unsafe(nil), Hash) # source://parser//lib/parser/lexer/literal.rb#6 class Parser::Lexer::Literal - # source://parser//lib/parser/lexer/literal.rb#40 + # source://parser//lib/parser/lexer/literal.rb#42 def initialize(lexer, str_type, delimiter, str_s, heredoc_e = T.unsafe(nil), indent = T.unsafe(nil), dedent_body = T.unsafe(nil), label_allowed = T.unsafe(nil)); end - # source://parser//lib/parser/lexer/literal.rb#114 + # source://parser//lib/parser/lexer/literal.rb#116 def backslash_delimited?; end - # source://parser//lib/parser/lexer/literal.rb#37 + # source://parser//lib/parser/lexer/literal.rb#39 def dedent_level; end - # source://parser//lib/parser/lexer/literal.rb#189 + # source://parser//lib/parser/lexer/literal.rb#191 def end_interp_brace_and_try_closing; end - # source://parser//lib/parser/lexer/literal.rb#216 + # source://parser//lib/parser/lexer/literal.rb#218 def extend_content; end - # source://parser//lib/parser/lexer/literal.rb#220 + # source://parser//lib/parser/lexer/literal.rb#222 def extend_space(ts, te); end - # source://parser//lib/parser/lexer/literal.rb#195 + # source://parser//lib/parser/lexer/literal.rb#197 def extend_string(string, ts, te); end - # source://parser//lib/parser/lexer/literal.rb#202 + # source://parser//lib/parser/lexer/literal.rb#204 def flush_string; end - # source://parser//lib/parser/lexer/literal.rb#102 + # source://parser//lib/parser/lexer/literal.rb#104 def heredoc?; end - # source://parser//lib/parser/lexer/literal.rb#37 + # source://parser//lib/parser/lexer/literal.rb#39 def heredoc_e; end - # source://parser//lib/parser/lexer/literal.rb#166 + # source://parser//lib/parser/lexer/literal.rb#168 def infer_indent_level(line); end - # source://parser//lib/parser/lexer/literal.rb#89 + # source://parser//lib/parser/lexer/literal.rb#91 def interpolate?; end - # source://parser//lib/parser/lexer/literal.rb#122 + # source://parser//lib/parser/lexer/literal.rb#124 def munge_escape?(character); end - # source://parser//lib/parser/lexer/literal.rb#132 + # source://parser//lib/parser/lexer/literal.rb#134 def nest_and_try_closing(delimiter, ts, te, lookahead = T.unsafe(nil)); end - # source://parser//lib/parser/lexer/literal.rb#106 + # source://parser//lib/parser/lexer/literal.rb#108 def plain_heredoc?; end - # source://parser//lib/parser/lexer/literal.rb#98 + # source://parser//lib/parser/lexer/literal.rb#100 def regexp?; end - # source://parser//lib/parser/lexer/literal.rb#38 + # source://parser//lib/parser/lexer/literal.rb#40 def saved_herebody_s; end - # source://parser//lib/parser/lexer/literal.rb#38 + # source://parser//lib/parser/lexer/literal.rb#40 def saved_herebody_s=(_arg0); end - # source://parser//lib/parser/lexer/literal.rb#110 + # source://parser//lib/parser/lexer/literal.rb#112 def squiggly_heredoc?; end - # source://parser//lib/parser/lexer/literal.rb#185 + # source://parser//lib/parser/lexer/literal.rb#187 def start_interp_brace; end - # source://parser//lib/parser/lexer/literal.rb#37 + # source://parser//lib/parser/lexer/literal.rb#39 def str_s; end - # source://parser//lib/parser/lexer/literal.rb#230 + # source://parser//lib/parser/lexer/literal.rb#232 def supports_line_continuation_via_slash?; end - # source://parser//lib/parser/lexer/literal.rb#118 + # source://parser//lib/parser/lexer/literal.rb#120 def type; end - # source://parser//lib/parser/lexer/literal.rb#93 + # source://parser//lib/parser/lexer/literal.rb#95 def words?; end protected - # source://parser//lib/parser/lexer/literal.rb#248 + # source://parser//lib/parser/lexer/literal.rb#263 def clear_buffer; end - # source://parser//lib/parser/lexer/literal.rb#244 + # source://parser//lib/parser/lexer/literal.rb#259 def coerce_encoding(string); end - # source://parser//lib/parser/lexer/literal.rb#236 + # source://parser//lib/parser/lexer/literal.rb#238 def delimiter?(delimiter); end - # source://parser//lib/parser/lexer/literal.rb#264 + # source://parser//lib/parser/lexer/literal.rb#279 def emit(token, type, s, e); end - # source://parser//lib/parser/lexer/literal.rb#259 + # source://parser//lib/parser/lexer/literal.rb#274 def emit_start_tok; end end # source://parser//lib/parser/lexer/literal.rb#7 Parser::Lexer::Literal::DELIMITERS = T.let(T.unsafe(nil), Hash) +# source://parser//lib/parser/lexer/literal.rb#8 +Parser::Lexer::Literal::SPACE = T.let(T.unsafe(nil), Integer) + # source://parser//lib/parser/lexer/literal.rb#9 +Parser::Lexer::Literal::TAB = T.let(T.unsafe(nil), Integer) + +# source://parser//lib/parser/lexer/literal.rb#11 Parser::Lexer::Literal::TYPES = T.let(T.unsafe(nil), Hash) # Mapping of strings to parser tokens. # -# source://parser//lib/parser/lexer-F1.rb#14759 +# source://parser//lib/parser/lexer-F1.rb#14820 Parser::Lexer::PUNCTUATION = T.let(T.unsafe(nil), Hash) -# source://parser//lib/parser/lexer-F1.rb#14779 +# source://parser//lib/parser/lexer-F1.rb#14840 Parser::Lexer::PUNCTUATION_BEGIN = T.let(T.unsafe(nil), Hash) # source://parser//lib/parser/lexer/stack_state.rb#5 @@ -3200,7 +3209,7 @@ Parser::MaxNumparamStack::ORDINARY_PARAMS = T.let(T.unsafe(nil), Integer) # @api private # -# source://parser//lib/parser/messages.rb#107 +# source://parser//lib/parser/messages.rb#112 module Parser::Messages class << self # Formats the message, returns a raw template if there's nothing to interpolate @@ -3210,7 +3219,7 @@ module Parser::Messages # # @api private # - # source://parser//lib/parser/messages.rb#114 + # source://parser//lib/parser/messages.rb#119 def compile(reason, arguments); end end end @@ -3315,1797 +3324,1792 @@ end # source://parser//lib/parser/rewriter.rb#91 Parser::Rewriter::DEPRECATION_WARNING = T.let(T.unsafe(nil), String) -# source://parser//lib/parser/ruby32.rb#14 -class Parser::Ruby32 < ::Parser::Base +# source://parser//lib/parser/ruby33.rb#14 +class Parser::Ruby33 < ::Parser::Base # reduce 0 omitted # - # source://parser//lib/parser/ruby32.rb#8421 + # source://parser//lib/parser/ruby33.rb#8371 def _reduce_1(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8475 + # source://parser//lib/parser/ruby33.rb#8425 def _reduce_10(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9110 + # source://parser//lib/parser/ruby33.rb#9024 def _reduce_100(val, _values, result); end # reduce 101 omitted # - # source://parser//lib/parser/ruby32.rb#9119 + # source://parser//lib/parser/ruby33.rb#9033 def _reduce_102(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9125 + # source://parser//lib/parser/ruby33.rb#9039 def _reduce_103(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9131 + # source://parser//lib/parser/ruby33.rb#9045 def _reduce_104(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9137 + # source://parser//lib/parser/ruby33.rb#9051 def _reduce_105(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9143 + # source://parser//lib/parser/ruby33.rb#9057 def _reduce_106(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9149 + # source://parser//lib/parser/ruby33.rb#9063 def _reduce_107(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9155 + # source://parser//lib/parser/ruby33.rb#9069 def _reduce_108(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9161 + # source://parser//lib/parser/ruby33.rb#9075 def _reduce_109(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8481 + # source://parser//lib/parser/ruby33.rb#8431 def _reduce_11(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9167 + # source://parser//lib/parser/ruby33.rb#9081 def _reduce_110(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9177 + # source://parser//lib/parser/ruby33.rb#9091 def _reduce_111(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9183 + # source://parser//lib/parser/ruby33.rb#9097 def _reduce_112(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9193 + # source://parser//lib/parser/ruby33.rb#9107 def _reduce_113(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9200 + # source://parser//lib/parser/ruby33.rb#9114 def _reduce_114(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9207 + # source://parser//lib/parser/ruby33.rb#9121 def _reduce_115(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9213 + # source://parser//lib/parser/ruby33.rb#9127 def _reduce_116(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9219 + # source://parser//lib/parser/ruby33.rb#9133 def _reduce_117(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9225 + # source://parser//lib/parser/ruby33.rb#9139 def _reduce_118(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9231 + # source://parser//lib/parser/ruby33.rb#9145 def _reduce_119(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8498 + # source://parser//lib/parser/ruby33.rb#8448 def _reduce_12(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9237 + # source://parser//lib/parser/ruby33.rb#9151 def _reduce_120(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9243 + # source://parser//lib/parser/ruby33.rb#9157 def _reduce_121(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9249 + # source://parser//lib/parser/ruby33.rb#9163 def _reduce_122(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9256 + # source://parser//lib/parser/ruby33.rb#9170 def _reduce_123(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9263 + # source://parser//lib/parser/ruby33.rb#9177 def _reduce_124(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9269 + # source://parser//lib/parser/ruby33.rb#9183 def _reduce_125(val, _values, result); end # reduce 126 omitted # - # source://parser//lib/parser/ruby32.rb#9277 + # source://parser//lib/parser/ruby33.rb#9191 def _reduce_127(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9283 + # source://parser//lib/parser/ruby33.rb#9197 def _reduce_128(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9289 + # source://parser//lib/parser/ruby33.rb#9203 def _reduce_129(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8504 + # source://parser//lib/parser/ruby33.rb#8454 def _reduce_13(val, _values, result); end # reduce 134 omitted # - # source://parser//lib/parser/ruby32.rb#9305 + # source://parser//lib/parser/ruby33.rb#9219 def _reduce_135(val, _values, result); end # reduce 136 omitted # - # source://parser//lib/parser/ruby32.rb#9313 + # source://parser//lib/parser/ruby33.rb#9227 def _reduce_137(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9319 + # source://parser//lib/parser/ruby33.rb#9233 def _reduce_138(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9325 + # source://parser//lib/parser/ruby33.rb#9239 def _reduce_139(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8510 + # source://parser//lib/parser/ruby33.rb#8460 def _reduce_14(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8516 + # source://parser//lib/parser/ruby33.rb#8466 def _reduce_15(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8522 + # source://parser//lib/parser/ruby33.rb#8472 def _reduce_16(val, _values, result); end # reduce 17 omitted # - # source://parser//lib/parser/ruby32.rb#8530 + # source://parser//lib/parser/ruby33.rb#8480 def _reduce_18(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8536 + # source://parser//lib/parser/ruby33.rb#8486 def _reduce_19(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8428 + # source://parser//lib/parser/ruby33.rb#8378 def _reduce_2(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8542 + # source://parser//lib/parser/ruby33.rb#8492 def _reduce_20(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8548 + # source://parser//lib/parser/ruby33.rb#8498 def _reduce_21(val, _values, result); end # reduce 210 omitted # - # source://parser//lib/parser/ruby32.rb#9473 + # source://parser//lib/parser/ruby33.rb#9387 def _reduce_211(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9479 + # source://parser//lib/parser/ruby33.rb#9393 def _reduce_212(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9485 + # source://parser//lib/parser/ruby33.rb#9399 def _reduce_213(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9494 + # source://parser//lib/parser/ruby33.rb#9408 def _reduce_214(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9503 + # source://parser//lib/parser/ruby33.rb#9417 def _reduce_215(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9512 + # source://parser//lib/parser/ruby33.rb#9426 def _reduce_216(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9521 + # source://parser//lib/parser/ruby33.rb#9435 def _reduce_217(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9529 + # source://parser//lib/parser/ruby33.rb#9443 def _reduce_218(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9537 + # source://parser//lib/parser/ruby33.rb#9451 def _reduce_219(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8556 + # source://parser//lib/parser/ruby33.rb#8506 def _reduce_22(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9543 + # source://parser//lib/parser/ruby33.rb#9457 def _reduce_220(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9549 + # source://parser//lib/parser/ruby33.rb#9463 def _reduce_221(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9555 + # source://parser//lib/parser/ruby33.rb#9469 def _reduce_222(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9561 + # source://parser//lib/parser/ruby33.rb#9475 def _reduce_223(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9567 + # source://parser//lib/parser/ruby33.rb#9481 def _reduce_224(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9573 + # source://parser//lib/parser/ruby33.rb#9487 def _reduce_225(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9579 + # source://parser//lib/parser/ruby33.rb#9493 def _reduce_226(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9585 + # source://parser//lib/parser/ruby33.rb#9499 def _reduce_227(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9591 + # source://parser//lib/parser/ruby33.rb#9505 def _reduce_228(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9597 + # source://parser//lib/parser/ruby33.rb#9511 def _reduce_229(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8564 + # source://parser//lib/parser/ruby33.rb#8514 def _reduce_23(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9603 + # source://parser//lib/parser/ruby33.rb#9517 def _reduce_230(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9609 + # source://parser//lib/parser/ruby33.rb#9523 def _reduce_231(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9615 + # source://parser//lib/parser/ruby33.rb#9529 def _reduce_232(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9623 + # source://parser//lib/parser/ruby33.rb#9537 def _reduce_233(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9629 + # source://parser//lib/parser/ruby33.rb#9543 def _reduce_234(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9635 + # source://parser//lib/parser/ruby33.rb#9549 def _reduce_235(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9641 + # source://parser//lib/parser/ruby33.rb#9555 def _reduce_236(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9647 + # source://parser//lib/parser/ruby33.rb#9561 def _reduce_237(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9653 + # source://parser//lib/parser/ruby33.rb#9567 def _reduce_238(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8570 + # source://parser//lib/parser/ruby33.rb#8520 def _reduce_24(val, _values, result); end # reduce 239 omitted # - # source://parser//lib/parser/ruby32.rb#9661 + # source://parser//lib/parser/ruby33.rb#9575 def _reduce_240(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9667 + # source://parser//lib/parser/ruby33.rb#9581 def _reduce_241(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9673 + # source://parser//lib/parser/ruby33.rb#9587 def _reduce_242(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9679 + # source://parser//lib/parser/ruby33.rb#9593 def _reduce_243(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9685 + # source://parser//lib/parser/ruby33.rb#9599 def _reduce_244(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9691 + # source://parser//lib/parser/ruby33.rb#9605 def _reduce_245(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9697 + # source://parser//lib/parser/ruby33.rb#9611 def _reduce_246(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9703 + # source://parser//lib/parser/ruby33.rb#9617 def _reduce_247(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9709 + # source://parser//lib/parser/ruby33.rb#9623 def _reduce_248(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9715 + # source://parser//lib/parser/ruby33.rb#9629 def _reduce_249(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8576 + # source://parser//lib/parser/ruby33.rb#8526 def _reduce_25(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9721 + # source://parser//lib/parser/ruby33.rb#9635 def _reduce_250(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9727 + # source://parser//lib/parser/ruby33.rb#9641 def _reduce_251(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9733 + # source://parser//lib/parser/ruby33.rb#9648 def _reduce_252(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9740 + # source://parser//lib/parser/ruby33.rb#9655 def _reduce_253(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9747 + # source://parser//lib/parser/ruby33.rb#9669 def _reduce_254(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9761 - def _reduce_255(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#9781 - def _reduce_256(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#9795 + # reduce 256 omitted + # + # source://parser//lib/parser/ruby33.rb#9687 def _reduce_257(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8583 + # source://parser//lib/parser/ruby33.rb#9697 + def _reduce_258(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#8533 def _reduce_26(val, _values, result); end # reduce 262 omitted # - # source://parser//lib/parser/ruby32.rb#9825 + # source://parser//lib/parser/ruby33.rb#9711 def _reduce_263(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9831 + # source://parser//lib/parser/ruby33.rb#9717 def _reduce_264(val, _values, result); end - # reduce 267 omitted - # - # source://parser//lib/parser/ruby32.rb#9843 - def _reduce_268(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#9723 + def _reduce_265(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9849 + # reduce 268 omitted + # + # source://parser//lib/parser/ruby33.rb#9735 def _reduce_269(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8590 + # source://parser//lib/parser/ruby33.rb#8540 def _reduce_27(val, _values, result); end - # reduce 270 omitted - # - # source://parser//lib/parser/ruby32.rb#9857 - def _reduce_271(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#9741 + def _reduce_270(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9867 + # reduce 271 omitted + # + # source://parser//lib/parser/ruby33.rb#9749 def _reduce_272(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9873 + # source://parser//lib/parser/ruby33.rb#9759 def _reduce_273(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9883 + # source://parser//lib/parser/ruby33.rb#9765 def _reduce_274(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9893 + # source://parser//lib/parser/ruby33.rb#9775 def _reduce_275(val, _values, result); end - # reduce 276 omitted + # source://parser//lib/parser/ruby33.rb#9785 + def _reduce_276(val, _values, result); end + + # reduce 277 omitted # - # source://parser//lib/parser/ruby32.rb#9901 - def _reduce_277(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#9793 + def _reduce_278(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8596 + # source://parser//lib/parser/ruby33.rb#8546 def _reduce_28(val, _values, result); end - # reduce 279 omitted + # reduce 280 omitted # - # source://parser//lib/parser/ruby32.rb#9911 - def _reduce_280(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#9917 + # source://parser//lib/parser/ruby33.rb#9803 def _reduce_281(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9923 + # source://parser//lib/parser/ruby33.rb#9809 def _reduce_282(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9929 + # source://parser//lib/parser/ruby33.rb#9815 def _reduce_283(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9935 + # source://parser//lib/parser/ruby33.rb#9821 def _reduce_284(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9942 + # source://parser//lib/parser/ruby33.rb#9827 def _reduce_285(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9950 + # source://parser//lib/parser/ruby33.rb#9834 def _reduce_286(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9956 + # source://parser//lib/parser/ruby33.rb#9842 def _reduce_287(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9983 + # source://parser//lib/parser/ruby33.rb#9848 def _reduce_288(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10004 + # source://parser//lib/parser/ruby33.rb#9875 def _reduce_289(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8602 + # source://parser//lib/parser/ruby33.rb#8552 def _reduce_29(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10010 + # source://parser//lib/parser/ruby33.rb#9896 def _reduce_290(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10020 + # source://parser//lib/parser/ruby33.rb#9902 def _reduce_291(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10026 + # source://parser//lib/parser/ruby33.rb#9917 def _reduce_292(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10032 + # source://parser//lib/parser/ruby33.rb#9923 def _reduce_293(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10038 + # source://parser//lib/parser/ruby33.rb#9929 def _reduce_294(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10044 - def _reduce_295(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10054 + # reduce 295 omitted + # + # source://parser//lib/parser/ruby33.rb#9937 def _reduce_296(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10060 + # source://parser//lib/parser/ruby33.rb#9943 def _reduce_297(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10066 + # source://parser//lib/parser/ruby33.rb#9949 def _reduce_298(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10076 + # source://parser//lib/parser/ruby33.rb#9955 def _reduce_299(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8437 + # source://parser//lib/parser/ruby33.rb#8387 def _reduce_3(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8612 + # source://parser//lib/parser/ruby33.rb#8562 def _reduce_30(val, _values, result); end - # reduce 300 omitted - # - # source://parser//lib/parser/ruby32.rb#10084 - def _reduce_301(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#9970 + def _reduce_300(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10090 + # reduce 301 omitted + # + # source://parser//lib/parser/ruby33.rb#9978 def _reduce_302(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10096 + # source://parser//lib/parser/ruby33.rb#9984 def _reduce_303(val, _values, result); end - # reduce 313 omitted - # - # source://parser//lib/parser/ruby32.rb#10122 - def _reduce_314(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#9990 + def _reduce_304(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10128 + # reduce 314 omitted + # + # source://parser//lib/parser/ruby33.rb#10016 def _reduce_315(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10134 + # source://parser//lib/parser/ruby33.rb#10022 def _reduce_316(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10142 + # source://parser//lib/parser/ruby33.rb#10028 def _reduce_317(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10148 + # source://parser//lib/parser/ruby33.rb#10036 def _reduce_318(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10154 + # source://parser//lib/parser/ruby33.rb#10042 def _reduce_319(val, _values, result); end # reduce 31 omitted # - # source://parser//lib/parser/ruby32.rb#8620 + # source://parser//lib/parser/ruby33.rb#8570 def _reduce_32(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10160 + # source://parser//lib/parser/ruby33.rb#10048 def _reduce_320(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10166 + # source://parser//lib/parser/ruby33.rb#10054 def _reduce_321(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10172 + # source://parser//lib/parser/ruby33.rb#10060 def _reduce_322(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10178 + # source://parser//lib/parser/ruby33.rb#10066 def _reduce_323(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10184 + # source://parser//lib/parser/ruby33.rb#10072 def _reduce_324(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10190 + # source://parser//lib/parser/ruby33.rb#10078 def _reduce_325(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10196 + # source://parser//lib/parser/ruby33.rb#10084 def _reduce_326(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10202 + # source://parser//lib/parser/ruby33.rb#10090 def _reduce_327(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10208 + # source://parser//lib/parser/ruby33.rb#10096 def _reduce_328(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10214 + # source://parser//lib/parser/ruby33.rb#10102 def _reduce_329(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8626 + # source://parser//lib/parser/ruby33.rb#8576 def _reduce_33(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10220 + # source://parser//lib/parser/ruby33.rb#10110 def _reduce_330(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10226 + # source://parser//lib/parser/ruby33.rb#10116 def _reduce_331(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10234 + # source://parser//lib/parser/ruby33.rb#10122 def _reduce_332(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10240 - def _reduce_333(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10246 + # reduce 333 omitted + # + # source://parser//lib/parser/ruby33.rb#10134 def _reduce_334(val, _values, result); end # reduce 335 omitted # - # source://parser//lib/parser/ruby32.rb#10258 + # source://parser//lib/parser/ruby33.rb#10144 def _reduce_336(val, _values, result); end - # reduce 337 omitted - # - # source://parser//lib/parser/ruby32.rb#10268 + # source://parser//lib/parser/ruby33.rb#10153 + def _reduce_337(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10162 def _reduce_338(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10277 + # source://parser//lib/parser/ruby33.rb#10168 def _reduce_339(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8633 + # source://parser//lib/parser/ruby33.rb#8583 def _reduce_34(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10286 + # source://parser//lib/parser/ruby33.rb#10174 def _reduce_340(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10292 + # source://parser//lib/parser/ruby33.rb#10184 def _reduce_341(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10298 + # source://parser//lib/parser/ruby33.rb#10194 def _reduce_342(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10308 + # source://parser//lib/parser/ruby33.rb#10204 def _reduce_343(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10318 + # source://parser//lib/parser/ruby33.rb#10210 def _reduce_344(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10328 + # source://parser//lib/parser/ruby33.rb#10217 def _reduce_345(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10334 + # source://parser//lib/parser/ruby33.rb#10233 def _reduce_346(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10341 + # source://parser//lib/parser/ruby33.rb#10241 def _reduce_347(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10357 + # source://parser//lib/parser/ruby33.rb#10253 def _reduce_348(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10365 + # source://parser//lib/parser/ruby33.rb#10260 def _reduce_349(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8644 + # source://parser//lib/parser/ruby33.rb#8594 def _reduce_35(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10377 + # source://parser//lib/parser/ruby33.rb#10274 def _reduce_350(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10384 + # source://parser//lib/parser/ruby33.rb#10286 def _reduce_351(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10398 + # source://parser//lib/parser/ruby33.rb#10298 def _reduce_352(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10410 + # source://parser//lib/parser/ruby33.rb#10304 def _reduce_353(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10422 + # source://parser//lib/parser/ruby33.rb#10310 def _reduce_354(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10428 + # source://parser//lib/parser/ruby33.rb#10316 def _reduce_355(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10434 - def _reduce_356(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10440 + # reduce 356 omitted + # + # source://parser//lib/parser/ruby33.rb#10324 def _reduce_357(val, _values, result); end - # reduce 358 omitted - # - # source://parser//lib/parser/ruby32.rb#10448 + # source://parser//lib/parser/ruby33.rb#10330 + def _reduce_358(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10336 def _reduce_359(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10454 + # source://parser//lib/parser/ruby33.rb#10343 def _reduce_360(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10460 - def _reduce_361(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10467 - def _reduce_362(val, _values, result); end + # reduce 362 omitted + # + # source://parser//lib/parser/ruby33.rb#10355 + def _reduce_363(val, _values, result); end - # reduce 364 omitted + # reduce 366 omitted # - # source://parser//lib/parser/ruby32.rb#10479 - def _reduce_365(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#10367 + def _reduce_367(val, _values, result); end # reduce 368 omitted # - # source://parser//lib/parser/ruby32.rb#10491 + # source://parser//lib/parser/ruby33.rb#10380 def _reduce_369(val, _values, result); end # reduce 36 omitted # - # source://parser//lib/parser/ruby32.rb#8652 + # source://parser//lib/parser/ruby33.rb#8602 def _reduce_37(val, _values, result); end - # reduce 370 omitted + # reduce 371 omitted # - # source://parser//lib/parser/ruby32.rb#10504 - def _reduce_371(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#10390 + def _reduce_372(val, _values, result); end - # reduce 373 omitted - # - # source://parser//lib/parser/ruby32.rb#10514 + # source://parser//lib/parser/ruby33.rb#10396 + def _reduce_373(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10402 def _reduce_374(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10520 + # source://parser//lib/parser/ruby33.rb#10408 def _reduce_375(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10526 - def _reduce_376(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10532 + # reduce 376 omitted + # + # source://parser//lib/parser/ruby33.rb#10416 def _reduce_377(val, _values, result); end - # reduce 378 omitted - # - # source://parser//lib/parser/ruby32.rb#10540 + # source://parser//lib/parser/ruby33.rb#10423 + def _reduce_378(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10431 def _reduce_379(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8658 + # source://parser//lib/parser/ruby33.rb#8608 def _reduce_38(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10547 + # source://parser//lib/parser/ruby33.rb#10437 def _reduce_380(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10555 + # source://parser//lib/parser/ruby33.rb#10443 def _reduce_381(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10561 + # source://parser//lib/parser/ruby33.rb#10449 def _reduce_382(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10567 - def _reduce_383(val, _values, result); end + # reduce 384 omitted + # + # source://parser//lib/parser/ruby33.rb#10459 + def _reduce_385(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10573 - def _reduce_384(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#10465 + def _reduce_386(val, _values, result); end - # reduce 386 omitted - # - # source://parser//lib/parser/ruby32.rb#10583 + # source://parser//lib/parser/ruby33.rb#10471 def _reduce_387(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10589 + # source://parser//lib/parser/ruby33.rb#10477 def _reduce_388(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10595 + # source://parser//lib/parser/ruby33.rb#10483 def _reduce_389(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8664 + # source://parser//lib/parser/ruby33.rb#8614 def _reduce_39(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10601 + # source://parser//lib/parser/ruby33.rb#10489 def _reduce_390(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10607 + # source://parser//lib/parser/ruby33.rb#10495 def _reduce_391(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10613 + # source://parser//lib/parser/ruby33.rb#10501 def _reduce_392(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10619 - def _reduce_393(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10625 + # reduce 393 omitted + # + # source://parser//lib/parser/ruby33.rb#10509 def _reduce_394(val, _values, result); end - # reduce 395 omitted - # - # source://parser//lib/parser/ruby32.rb#10633 + # source://parser//lib/parser/ruby33.rb#10518 + def _reduce_395(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10528 def _reduce_396(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10642 + # source://parser//lib/parser/ruby33.rb#10536 def _reduce_397(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10652 + # source://parser//lib/parser/ruby33.rb#10545 def _reduce_398(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10660 - def _reduce_399(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#8443 + # source://parser//lib/parser/ruby33.rb#8393 def _reduce_4(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8673 + # source://parser//lib/parser/ruby33.rb#8623 def _reduce_40(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10669 + # reduce 399 omitted + # + # source://parser//lib/parser/ruby33.rb#10555 def _reduce_400(val, _values, result); end - # reduce 401 omitted - # - # source://parser//lib/parser/ruby32.rb#10679 + # source://parser//lib/parser/ruby33.rb#10564 + def _reduce_401(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10574 def _reduce_402(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10688 + # source://parser//lib/parser/ruby33.rb#10582 def _reduce_403(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10698 + # source://parser//lib/parser/ruby33.rb#10591 def _reduce_404(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10706 + # source://parser//lib/parser/ruby33.rb#10598 def _reduce_405(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10715 + # source://parser//lib/parser/ruby33.rb#10606 def _reduce_406(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10722 + # source://parser//lib/parser/ruby33.rb#10613 def _reduce_407(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10730 - def _reduce_408(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10737 + # reduce 408 omitted + # + # source://parser//lib/parser/ruby33.rb#10623 def _reduce_409(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8682 + # source://parser//lib/parser/ruby33.rb#8632 def _reduce_41(val, _values, result); end - # reduce 410 omitted - # - # source://parser//lib/parser/ruby32.rb#10747 + # source://parser//lib/parser/ruby33.rb#10629 + def _reduce_410(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10635 def _reduce_411(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10753 + # source://parser//lib/parser/ruby33.rb#10644 def _reduce_412(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10759 + # source://parser//lib/parser/ruby33.rb#10653 def _reduce_413(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10768 + # source://parser//lib/parser/ruby33.rb#10659 def _reduce_414(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10777 + # source://parser//lib/parser/ruby33.rb#10665 def _reduce_415(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10783 + # source://parser//lib/parser/ruby33.rb#10671 def _reduce_416(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10789 + # source://parser//lib/parser/ruby33.rb#10677 def _reduce_417(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10795 - def _reduce_418(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#10801 + # reduce 418 omitted + # + # source://parser//lib/parser/ruby33.rb#10686 def _reduce_419(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8691 + # source://parser//lib/parser/ruby33.rb#8641 def _reduce_42(val, _values, result); end - # reduce 420 omitted - # - # source://parser//lib/parser/ruby32.rb#10810 + # source://parser//lib/parser/ruby33.rb#10695 + def _reduce_420(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10701 def _reduce_421(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10819 + # source://parser//lib/parser/ruby33.rb#10717 def _reduce_422(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10825 + # source://parser//lib/parser/ruby33.rb#10725 def _reduce_423(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10841 + # source://parser//lib/parser/ruby33.rb#10735 def _reduce_424(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10849 + # source://parser//lib/parser/ruby33.rb#10742 def _reduce_425(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10859 + # source://parser//lib/parser/ruby33.rb#10749 def _reduce_426(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10866 + # source://parser//lib/parser/ruby33.rb#10756 def _reduce_427(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10873 + # source://parser//lib/parser/ruby33.rb#10763 def _reduce_428(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10880 + # source://parser//lib/parser/ruby33.rb#10770 def _reduce_429(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8699 + # source://parser//lib/parser/ruby33.rb#8649 def _reduce_43(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10887 + # source://parser//lib/parser/ruby33.rb#10777 def _reduce_430(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10894 + # source://parser//lib/parser/ruby33.rb#10785 def _reduce_431(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10901 + # source://parser//lib/parser/ruby33.rb#10793 def _reduce_432(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10909 + # source://parser//lib/parser/ruby33.rb#10805 def _reduce_433(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10917 + # source://parser//lib/parser/ruby33.rb#10816 def _reduce_434(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10929 + # source://parser//lib/parser/ruby33.rb#10824 def _reduce_435(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10940 + # source://parser//lib/parser/ruby33.rb#10832 def _reduce_436(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10948 + # source://parser//lib/parser/ruby33.rb#10840 def _reduce_437(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10956 + # source://parser//lib/parser/ruby33.rb#10846 def _reduce_438(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10964 + # source://parser//lib/parser/ruby33.rb#10854 def _reduce_439(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8708 + # source://parser//lib/parser/ruby33.rb#8658 def _reduce_44(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10970 + # source://parser//lib/parser/ruby33.rb#10862 def _reduce_440(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10978 + # source://parser//lib/parser/ruby33.rb#10870 def _reduce_441(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10986 + # source://parser//lib/parser/ruby33.rb#10876 def _reduce_442(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#10994 + # source://parser//lib/parser/ruby33.rb#10882 def _reduce_443(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11000 + # source://parser//lib/parser/ruby33.rb#10889 def _reduce_444(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11006 + # source://parser//lib/parser/ruby33.rb#10896 def _reduce_445(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11013 + # source://parser//lib/parser/ruby33.rb#10903 def _reduce_446(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11020 + # source://parser//lib/parser/ruby33.rb#10910 def _reduce_447(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11027 + # source://parser//lib/parser/ruby33.rb#10917 def _reduce_448(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11034 + # source://parser//lib/parser/ruby33.rb#10927 def _reduce_449(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8722 + # source://parser//lib/parser/ruby33.rb#8672 def _reduce_45(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11041 + # source://parser//lib/parser/ruby33.rb#10934 def _reduce_450(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11051 + # source://parser//lib/parser/ruby33.rb#10940 def _reduce_451(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11058 + # source://parser//lib/parser/ruby33.rb#10951 def _reduce_452(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11064 + # source://parser//lib/parser/ruby33.rb#10958 def _reduce_453(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11075 - def _reduce_454(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#11082 + # reduce 454 omitted + # + # source://parser//lib/parser/ruby33.rb#10966 def _reduce_455(val, _values, result); end - # reduce 456 omitted - # - # source://parser//lib/parser/ruby32.rb#11090 + # source://parser//lib/parser/ruby33.rb#10972 + def _reduce_456(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#10978 def _reduce_457(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11102 + # source://parser//lib/parser/ruby33.rb#10988 def _reduce_458(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11110 + # source://parser//lib/parser/ruby33.rb#10996 def _reduce_459(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8742 + # source://parser//lib/parser/ruby33.rb#8686 def _reduce_46(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11117 + # source://parser//lib/parser/ruby33.rb#11003 def _reduce_460(val, _values, result); end # reduce 461 omitted # - # source://parser//lib/parser/ruby32.rb#11125 + # source://parser//lib/parser/ruby33.rb#11011 def _reduce_462(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11131 + # source://parser//lib/parser/ruby33.rb#11017 def _reduce_463(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11137 + # source://parser//lib/parser/ruby33.rb#11023 def _reduce_464(val, _values, result); end # reduce 465 omitted # - # source://parser//lib/parser/ruby32.rb#11145 + # source://parser//lib/parser/ruby33.rb#11031 def _reduce_466(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11155 + # source://parser//lib/parser/ruby33.rb#11041 def _reduce_467(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11161 + # source://parser//lib/parser/ruby33.rb#11047 def _reduce_468(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11167 + # source://parser//lib/parser/ruby33.rb#11053 def _reduce_469(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8756 - def _reduce_47(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#11173 + # source://parser//lib/parser/ruby33.rb#11059 def _reduce_470(val, _values, result); end # reduce 471 omitted # - # source://parser//lib/parser/ruby32.rb#11181 + # source://parser//lib/parser/ruby33.rb#11067 def _reduce_472(val, _values, result); end # reduce 473 omitted # - # source://parser//lib/parser/ruby32.rb#11189 + # source://parser//lib/parser/ruby33.rb#11075 def _reduce_474(val, _values, result); end # reduce 475 omitted # - # source://parser//lib/parser/ruby32.rb#11197 + # source://parser//lib/parser/ruby33.rb#11083 def _reduce_476(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11204 + # source://parser//lib/parser/ruby33.rb#11090 def _reduce_477(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8776 + # reduce 47 omitted + # + # source://parser//lib/parser/ruby33.rb#8694 def _reduce_48(val, _values, result); end # reduce 479 omitted # - # source://parser//lib/parser/ruby32.rb#11215 + # source://parser//lib/parser/ruby33.rb#11101 def _reduce_480(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11223 + # source://parser//lib/parser/ruby33.rb#11109 def _reduce_481(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11231 + # source://parser//lib/parser/ruby33.rb#11117 def _reduce_482(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11239 + # source://parser//lib/parser/ruby33.rb#11125 def _reduce_483(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11246 + # source://parser//lib/parser/ruby33.rb#11132 def _reduce_484(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11254 + # source://parser//lib/parser/ruby33.rb#11140 def _reduce_485(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11262 + # source://parser//lib/parser/ruby33.rb#11148 def _reduce_486(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11270 + # source://parser//lib/parser/ruby33.rb#11156 def _reduce_487(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11277 + # source://parser//lib/parser/ruby33.rb#11163 def _reduce_488(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11283 + # source://parser//lib/parser/ruby33.rb#11169 def _reduce_489(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11289 + # source://parser//lib/parser/ruby33.rb#8704 + def _reduce_49(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#11175 def _reduce_490(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11295 + # source://parser//lib/parser/ruby33.rb#11181 def _reduce_491(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11303 + # source://parser//lib/parser/ruby33.rb#11189 def _reduce_492(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11311 + # source://parser//lib/parser/ruby33.rb#11197 def _reduce_493(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11317 + # source://parser//lib/parser/ruby33.rb#11203 def _reduce_494(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11323 + # source://parser//lib/parser/ruby33.rb#11209 def _reduce_495(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11330 + # source://parser//lib/parser/ruby33.rb#11216 def _reduce_496(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11336 + # source://parser//lib/parser/ruby33.rb#11222 def _reduce_497(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11342 + # source://parser//lib/parser/ruby33.rb#11228 def _reduce_498(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11348 + # source://parser//lib/parser/ruby33.rb#11234 def _reduce_499(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8449 + # source://parser//lib/parser/ruby33.rb#8399 def _reduce_5(val, _values, result); end - # reduce 49 omitted - # - # source://parser//lib/parser/ruby32.rb#8784 - def _reduce_50(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#11354 + # source://parser//lib/parser/ruby33.rb#11240 def _reduce_500(val, _values, result); end # reduce 501 omitted # - # source://parser//lib/parser/ruby32.rb#11362 + # source://parser//lib/parser/ruby33.rb#11248 def _reduce_502(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11372 + # source://parser//lib/parser/ruby33.rb#11258 def _reduce_503(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11382 + # source://parser//lib/parser/ruby33.rb#11268 def _reduce_504(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11388 + # source://parser//lib/parser/ruby33.rb#11274 def _reduce_505(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11394 + # source://parser//lib/parser/ruby33.rb#11280 def _reduce_506(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11400 + # source://parser//lib/parser/ruby33.rb#11286 def _reduce_507(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11406 + # source://parser//lib/parser/ruby33.rb#11292 def _reduce_508(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11412 + # source://parser//lib/parser/ruby33.rb#11298 def _reduce_509(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11418 + # reduce 50 omitted + # + # source://parser//lib/parser/ruby33.rb#8712 + def _reduce_51(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#11304 def _reduce_510(val, _values, result); end # reduce 511 omitted # - # source://parser//lib/parser/ruby32.rb#11426 + # source://parser//lib/parser/ruby33.rb#11312 def _reduce_512(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11432 + # source://parser//lib/parser/ruby33.rb#11318 def _reduce_513(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11438 + # source://parser//lib/parser/ruby33.rb#11324 def _reduce_514(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11444 + # source://parser//lib/parser/ruby33.rb#11330 def _reduce_515(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11450 + # source://parser//lib/parser/ruby33.rb#11336 def _reduce_516(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11456 + # source://parser//lib/parser/ruby33.rb#11342 def _reduce_517(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11462 + # source://parser//lib/parser/ruby33.rb#11348 def _reduce_518(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11468 + # source://parser//lib/parser/ruby33.rb#11354 def _reduce_519(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11474 + # source://parser//lib/parser/ruby33.rb#11360 def _reduce_520(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11480 + # source://parser//lib/parser/ruby33.rb#11366 def _reduce_521(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11486 + # source://parser//lib/parser/ruby33.rb#11372 def _reduce_522(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11492 + # source://parser//lib/parser/ruby33.rb#11378 def _reduce_523(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11498 + # source://parser//lib/parser/ruby33.rb#11384 def _reduce_524(val, _values, result); end # reduce 525 omitted # - # source://parser//lib/parser/ruby32.rb#11506 + # source://parser//lib/parser/ruby33.rb#11392 def _reduce_526(val, _values, result); end # reduce 527 omitted # - # source://parser//lib/parser/ruby32.rb#11514 + # source://parser//lib/parser/ruby33.rb#11400 def _reduce_528(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11520 + # source://parser//lib/parser/ruby33.rb#11406 def _reduce_529(val, _values, result); end - # reduce 52 omitted - # - # source://parser//lib/parser/ruby32.rb#8798 - def _reduce_53(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#11526 + # source://parser//lib/parser/ruby33.rb#11412 def _reduce_530(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11532 + # source://parser//lib/parser/ruby33.rb#11418 def _reduce_531(val, _values, result); end # reduce 534 omitted # - # source://parser//lib/parser/ruby32.rb#11544 + # source://parser//lib/parser/ruby33.rb#11430 def _reduce_535(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11550 + # source://parser//lib/parser/ruby33.rb#11436 def _reduce_536(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8804 + # reduce 53 omitted + # + # source://parser//lib/parser/ruby33.rb#8726 def _reduce_54(val, _values, result); end # reduce 544 omitted # - # source://parser//lib/parser/ruby32.rb#11572 + # source://parser//lib/parser/ruby33.rb#11458 def _reduce_545(val, _values, result); end # reduce 546 omitted # - # source://parser//lib/parser/ruby32.rb#11580 + # source://parser//lib/parser/ruby33.rb#11466 def _reduce_547(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11586 + # source://parser//lib/parser/ruby33.rb#11472 def _reduce_548(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11598 + # source://parser//lib/parser/ruby33.rb#11484 def _reduce_549(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8810 + # source://parser//lib/parser/ruby33.rb#8732 def _reduce_55(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11605 + # source://parser//lib/parser/ruby33.rb#11491 def _reduce_550(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11612 + # source://parser//lib/parser/ruby33.rb#11498 def _reduce_551(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11618 + # source://parser//lib/parser/ruby33.rb#11504 def _reduce_552(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11624 + # source://parser//lib/parser/ruby33.rb#11510 def _reduce_553(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11630 + # source://parser//lib/parser/ruby33.rb#11516 def _reduce_554(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11645 + # source://parser//lib/parser/ruby33.rb#11531 def _reduce_555(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11651 + # source://parser//lib/parser/ruby33.rb#11537 def _reduce_556(val, _values, result); end # reduce 558 omitted # - # source://parser//lib/parser/ruby32.rb#11661 + # source://parser//lib/parser/ruby33.rb#11547 def _reduce_559(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8816 + # source://parser//lib/parser/ruby33.rb#8738 def _reduce_56(val, _values, result); end # reduce 560 omitted # - # source://parser//lib/parser/ruby32.rb#11669 + # source://parser//lib/parser/ruby33.rb#11555 def _reduce_561(val, _values, result); end # reduce 564 omitted # - # source://parser//lib/parser/ruby32.rb#11681 + # source://parser//lib/parser/ruby33.rb#11567 def _reduce_565(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11687 + # source://parser//lib/parser/ruby33.rb#11573 def _reduce_566(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11693 + # source://parser//lib/parser/ruby33.rb#11579 def _reduce_567(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11699 + # source://parser//lib/parser/ruby33.rb#11585 def _reduce_568(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11706 + # source://parser//lib/parser/ruby33.rb#11592 def _reduce_569(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8822 + # source://parser//lib/parser/ruby33.rb#8744 def _reduce_57(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11713 + # source://parser//lib/parser/ruby33.rb#11599 def _reduce_570(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11719 + # source://parser//lib/parser/ruby33.rb#11605 def _reduce_571(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11726 + # source://parser//lib/parser/ruby33.rb#11612 def _reduce_572(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11733 - def _reduce_573(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#11739 - def _reduce_574(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#11745 + # reduce 574 omitted + # + # source://parser//lib/parser/ruby33.rb#11623 def _reduce_575(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11751 + # source://parser//lib/parser/ruby33.rb#11629 def _reduce_576(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11757 + # source://parser//lib/parser/ruby33.rb#11635 def _reduce_577(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11763 + # source://parser//lib/parser/ruby33.rb#11641 def _reduce_578(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11769 + # source://parser//lib/parser/ruby33.rb#11647 def _reduce_579(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8834 + # source://parser//lib/parser/ruby33.rb#8750 def _reduce_58(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11775 + # source://parser//lib/parser/ruby33.rb#11653 def _reduce_580(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11781 + # source://parser//lib/parser/ruby33.rb#11659 def _reduce_581(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11787 + # source://parser//lib/parser/ruby33.rb#11665 def _reduce_582(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11793 + # source://parser//lib/parser/ruby33.rb#11671 def _reduce_583(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11799 + # source://parser//lib/parser/ruby33.rb#11677 def _reduce_584(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11805 + # source://parser//lib/parser/ruby33.rb#11683 def _reduce_585(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11811 + # source://parser//lib/parser/ruby33.rb#11689 def _reduce_586(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11817 + # source://parser//lib/parser/ruby33.rb#11695 def _reduce_587(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11823 + # source://parser//lib/parser/ruby33.rb#11701 def _reduce_588(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11829 + # source://parser//lib/parser/ruby33.rb#11707 def _reduce_589(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8843 + # source://parser//lib/parser/ruby33.rb#8759 def _reduce_59(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11835 + # source://parser//lib/parser/ruby33.rb#11713 def _reduce_590(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11841 + # source://parser//lib/parser/ruby33.rb#11719 def _reduce_591(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11847 + # source://parser//lib/parser/ruby33.rb#11725 def _reduce_592(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11853 + # source://parser//lib/parser/ruby33.rb#11731 def _reduce_593(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11859 + # source://parser//lib/parser/ruby33.rb#11737 def _reduce_594(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11865 + # source://parser//lib/parser/ruby33.rb#11743 def _reduce_595(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11872 + # source://parser//lib/parser/ruby33.rb#11749 def _reduce_596(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11881 + # source://parser//lib/parser/ruby33.rb#11755 def _reduce_597(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11887 + # source://parser//lib/parser/ruby33.rb#11762 def _reduce_598(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11893 - def _reduce_599(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#8455 + # source://parser//lib/parser/ruby33.rb#8405 def _reduce_6(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8855 - def _reduce_60(val, _values, result); end - - # reduce 602 omitted + # reduce 599 omitted # - # source://parser//lib/parser/ruby32.rb#11905 - def _reduce_603(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#11773 + def _reduce_600(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11912 + # reduce 603 omitted + # + # source://parser//lib/parser/ruby33.rb#11785 def _reduce_604(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11919 + # source://parser//lib/parser/ruby33.rb#11792 def _reduce_605(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11925 + # source://parser//lib/parser/ruby33.rb#11799 def _reduce_606(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11936 + # source://parser//lib/parser/ruby33.rb#11805 def _reduce_607(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11943 + # source://parser//lib/parser/ruby33.rb#11816 def _reduce_608(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11950 + # source://parser//lib/parser/ruby33.rb#11823 def _reduce_609(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11957 + # source://parser//lib/parser/ruby33.rb#11830 def _reduce_610(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11964 + # source://parser//lib/parser/ruby33.rb#11837 def _reduce_611(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11970 + # source://parser//lib/parser/ruby33.rb#11844 def _reduce_612(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11976 + # source://parser//lib/parser/ruby33.rb#11850 def _reduce_613(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11982 + # source://parser//lib/parser/ruby33.rb#11856 def _reduce_614(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#11988 + # source://parser//lib/parser/ruby33.rb#11862 def _reduce_615(val, _values, result); end - # reduce 616 omitted - # - # source://parser//lib/parser/ruby32.rb#11996 - def _reduce_617(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#11868 + def _reduce_616(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12002 + # reduce 617 omitted + # + # source://parser//lib/parser/ruby33.rb#11876 def _reduce_618(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12008 + # source://parser//lib/parser/ruby33.rb#11882 def _reduce_619(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12014 + # reduce 61 omitted + # + # source://parser//lib/parser/ruby33.rb#8772 + def _reduce_62(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#11888 def _reduce_620(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12020 + # source://parser//lib/parser/ruby33.rb#11894 def _reduce_621(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12026 + # source://parser//lib/parser/ruby33.rb#11900 def _reduce_622(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12032 + # source://parser//lib/parser/ruby33.rb#11906 def _reduce_623(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12038 + # source://parser//lib/parser/ruby33.rb#11912 def _reduce_624(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12044 + # source://parser//lib/parser/ruby33.rb#11918 def _reduce_625(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12050 + # source://parser//lib/parser/ruby33.rb#11924 def _reduce_626(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12056 + # source://parser//lib/parser/ruby33.rb#11930 def _reduce_627(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12062 + # source://parser//lib/parser/ruby33.rb#11936 def _reduce_628(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12068 + # source://parser//lib/parser/ruby33.rb#11942 def _reduce_629(val, _values, result); end - # reduce 62 omitted - # - # source://parser//lib/parser/ruby32.rb#8868 + # source://parser//lib/parser/ruby33.rb#8778 def _reduce_63(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12074 + # source://parser//lib/parser/ruby33.rb#11948 def _reduce_630(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12080 + # source://parser//lib/parser/ruby33.rb#11954 def _reduce_631(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12086 + # source://parser//lib/parser/ruby33.rb#11960 def _reduce_632(val, _values, result); end - # reduce 633 omitted - # - # source://parser//lib/parser/ruby32.rb#12094 - def _reduce_634(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#11966 + def _reduce_633(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12101 + # reduce 634 omitted + # + # source://parser//lib/parser/ruby33.rb#11974 def _reduce_635(val, _values, result); end - # reduce 636 omitted - # - # source://parser//lib/parser/ruby32.rb#12112 - def _reduce_637(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#11981 + def _reduce_636(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12120 + # reduce 637 omitted + # + # source://parser//lib/parser/ruby33.rb#11992 def _reduce_638(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12128 + # source://parser//lib/parser/ruby33.rb#12000 def _reduce_639(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8874 + # source://parser//lib/parser/ruby33.rb#8785 def _reduce_64(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12134 + # source://parser//lib/parser/ruby33.rb#12008 def _reduce_640(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12140 + # source://parser//lib/parser/ruby33.rb#12014 def _reduce_641(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12146 + # source://parser//lib/parser/ruby33.rb#12020 def _reduce_642(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12152 + # source://parser//lib/parser/ruby33.rb#12026 def _reduce_643(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12159 + # source://parser//lib/parser/ruby33.rb#12032 def _reduce_644(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12165 + # source://parser//lib/parser/ruby33.rb#12039 def _reduce_645(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12171 + # source://parser//lib/parser/ruby33.rb#12045 def _reduce_646(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12180 + # source://parser//lib/parser/ruby33.rb#12051 def _reduce_647(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12190 + # source://parser//lib/parser/ruby33.rb#12060 def _reduce_648(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12198 + # source://parser//lib/parser/ruby33.rb#12070 def _reduce_649(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8881 + # source://parser//lib/parser/ruby33.rb#8795 def _reduce_65(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12207 + # source://parser//lib/parser/ruby33.rb#12078 def _reduce_650(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12215 + # source://parser//lib/parser/ruby33.rb#12087 def _reduce_651(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12224 + # source://parser//lib/parser/ruby33.rb#12095 def _reduce_652(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12231 + # source://parser//lib/parser/ruby33.rb#12104 def _reduce_653(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12239 + # source://parser//lib/parser/ruby33.rb#12111 def _reduce_654(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12248 + # source://parser//lib/parser/ruby33.rb#12119 def _reduce_655(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12255 + # source://parser//lib/parser/ruby33.rb#12128 def _reduce_656(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12263 + # source://parser//lib/parser/ruby33.rb#12135 def _reduce_657(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12270 + # source://parser//lib/parser/ruby33.rb#12143 def _reduce_658(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12278 + # source://parser//lib/parser/ruby33.rb#12150 def _reduce_659(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8891 + # source://parser//lib/parser/ruby33.rb#8801 def _reduce_66(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12284 + # source://parser//lib/parser/ruby33.rb#12158 def _reduce_660(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12290 + # source://parser//lib/parser/ruby33.rb#12164 def _reduce_661(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12296 + # source://parser//lib/parser/ruby33.rb#12170 def _reduce_662(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12302 + # source://parser//lib/parser/ruby33.rb#12176 def _reduce_663(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12308 + # source://parser//lib/parser/ruby33.rb#12182 def _reduce_664(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12314 + # source://parser//lib/parser/ruby33.rb#12188 def _reduce_665(val, _values, result); end - # reduce 666 omitted - # - # source://parser//lib/parser/ruby32.rb#12322 - def _reduce_667(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12194 + def _reduce_666(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12332 + # reduce 667 omitted + # + # source://parser//lib/parser/ruby33.rb#12202 def _reduce_668(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12339 + # source://parser//lib/parser/ruby33.rb#12212 def _reduce_669(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8897 + # source://parser//lib/parser/ruby33.rb#8808 def _reduce_67(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12346 + # source://parser//lib/parser/ruby33.rb#12219 def _reduce_670(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12352 + # source://parser//lib/parser/ruby33.rb#12226 def _reduce_671(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12358 + # source://parser//lib/parser/ruby33.rb#12232 def _reduce_672(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12364 + # source://parser//lib/parser/ruby33.rb#12238 def _reduce_673(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12379 + # source://parser//lib/parser/ruby33.rb#12244 def _reduce_674(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12387 + # source://parser//lib/parser/ruby33.rb#12259 def _reduce_675(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12395 + # source://parser//lib/parser/ruby33.rb#12267 def _reduce_676(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12402 + # source://parser//lib/parser/ruby33.rb#12275 def _reduce_677(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12409 + # source://parser//lib/parser/ruby33.rb#12282 def _reduce_678(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12415 + # source://parser//lib/parser/ruby33.rb#12289 def _reduce_679(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8904 - def _reduce_68(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#12421 + # source://parser//lib/parser/ruby33.rb#12295 def _reduce_680(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12427 + # source://parser//lib/parser/ruby33.rb#12301 def _reduce_681(val, _values, result); end - # reduce 683 omitted - # - # source://parser//lib/parser/ruby32.rb#12437 - def _reduce_684(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12307 + def _reduce_682(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12443 + # reduce 684 omitted + # + # source://parser//lib/parser/ruby33.rb#12317 def _reduce_685(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12451 + # source://parser//lib/parser/ruby33.rb#12323 def _reduce_686(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12459 + # source://parser//lib/parser/ruby33.rb#12331 def _reduce_687(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12467 + # source://parser//lib/parser/ruby33.rb#12339 def _reduce_688(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12475 + # source://parser//lib/parser/ruby33.rb#12347 def _reduce_689(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12481 + # source://parser//lib/parser/ruby33.rb#12355 def _reduce_690(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12487 + # source://parser//lib/parser/ruby33.rb#12361 def _reduce_691(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12493 + # source://parser//lib/parser/ruby33.rb#12367 def _reduce_692(val, _values, result); end - # reduce 694 omitted - # - # source://parser//lib/parser/ruby32.rb#12503 - def _reduce_695(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12373 + def _reduce_693(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12511 + # reduce 695 omitted + # + # source://parser//lib/parser/ruby33.rb#12383 def _reduce_696(val, _values, result); end - # reduce 698 omitted - # - # source://parser//lib/parser/ruby32.rb#12523 - def _reduce_699(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12391 + def _reduce_697(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8461 + # source://parser//lib/parser/ruby33.rb#8411 def _reduce_7(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12531 + # reduce 699 omitted + # + # source://parser//lib/parser/ruby33.rb#12403 def _reduce_700(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12539 + # source://parser//lib/parser/ruby33.rb#12411 def _reduce_701(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12545 + # source://parser//lib/parser/ruby33.rb#12419 def _reduce_702(val, _values, result); end - # reduce 703 omitted - # - # source://parser//lib/parser/ruby32.rb#12553 - def _reduce_704(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12425 + def _reduce_703(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12559 + # reduce 704 omitted + # + # source://parser//lib/parser/ruby33.rb#12433 def _reduce_705(val, _values, result); end - # reduce 706 omitted - # - # source://parser//lib/parser/ruby32.rb#12567 - def _reduce_707(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12439 + def _reduce_706(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12573 + # reduce 707 omitted + # + # source://parser//lib/parser/ruby33.rb#12447 def _reduce_708(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12579 + # source://parser//lib/parser/ruby33.rb#12453 def _reduce_709(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12585 + # reduce 70 omitted + # + # source://parser//lib/parser/ruby33.rb#8820 + def _reduce_71(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#12459 def _reduce_710(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12591 + # source://parser//lib/parser/ruby33.rb#12465 def _reduce_711(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12597 + # source://parser//lib/parser/ruby33.rb#12471 def _reduce_712(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12603 + # source://parser//lib/parser/ruby33.rb#12477 def _reduce_713(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12609 + # source://parser//lib/parser/ruby33.rb#12483 def _reduce_714(val, _values, result); end - # reduce 71 omitted - # - # source://parser//lib/parser/ruby32.rb#8916 + # source://parser//lib/parser/ruby33.rb#12489 + def _reduce_715(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#8827 def _reduce_72(val, _values, result); end - # reduce 724 omitted + # reduce 725 omitted # - # source://parser//lib/parser/ruby32.rb#12639 - def _reduce_725(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#12645 + # source://parser//lib/parser/ruby33.rb#12524 def _reduce_726(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8923 + # source://parser//lib/parser/ruby33.rb#12530 + def _reduce_727(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#8834 def _reduce_73(val, _values, result); end - # reduce 730 omitted + # reduce 731 omitted # - # source://parser//lib/parser/ruby32.rb#12659 - def _reduce_731(val, _values, result); end - - # source://parser//lib/parser/ruby32.rb#12665 + # source://parser//lib/parser/ruby33.rb#12544 def _reduce_732(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12671 + # source://parser//lib/parser/ruby33.rb#12550 def _reduce_733(val, _values, result); end - # reduce 735 omitted - # - # source://parser//lib/parser/ruby32.rb#12681 - def _reduce_736(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12556 + def _reduce_734(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8930 - def _reduce_74(val, _values, result); end + # reduce 736 omitted + # + # source://parser//lib/parser/ruby33.rb#12566 + def _reduce_737(val, _values, result); end - # reduce 739 omitted + # reduce 740 omitted # - # source://parser//lib/parser/ruby32.rb#12693 - def _reduce_740(val, _values, result); end + # source://parser//lib/parser/ruby33.rb#12578 + def _reduce_741(val, _values, result); end - # reduce 75 omitted + # reduce 74 omitted # - # source://parser//lib/parser/ruby32.rb#8939 + # source://parser//lib/parser/ruby33.rb#8843 + def _reduce_75(val, _values, result); end + + # source://parser//lib/parser/ruby33.rb#8850 def _reduce_76(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8946 + # source://parser//lib/parser/ruby33.rb#8861 def _reduce_77(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8957 + # source://parser//lib/parser/ruby33.rb#8868 def _reduce_78(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8964 + # source://parser//lib/parser/ruby33.rb#8879 def _reduce_79(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8975 + # source://parser//lib/parser/ruby33.rb#8886 def _reduce_80(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8982 + # source://parser//lib/parser/ruby33.rb#8897 def _reduce_81(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#8993 + # source://parser//lib/parser/ruby33.rb#8907 def _reduce_82(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9000 + # source://parser//lib/parser/ruby33.rb#8914 def _reduce_83(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9007 + # source://parser//lib/parser/ruby33.rb#8921 def _reduce_84(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9014 + # source://parser//lib/parser/ruby33.rb#8928 def _reduce_85(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9021 + # source://parser//lib/parser/ruby33.rb#8935 def _reduce_86(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9028 + # source://parser//lib/parser/ruby33.rb#8942 def _reduce_87(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9034 + # source://parser//lib/parser/ruby33.rb#8948 def _reduce_88(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9040 + # source://parser//lib/parser/ruby33.rb#8954 def _reduce_89(val, _values, result); end # reduce 8 omitted # - # source://parser//lib/parser/ruby32.rb#8469 + # source://parser//lib/parser/ruby33.rb#8419 def _reduce_9(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9046 + # source://parser//lib/parser/ruby33.rb#8960 def _reduce_90(val, _values, result); end # reduce 91 omitted # - # source://parser//lib/parser/ruby32.rb#9054 + # source://parser//lib/parser/ruby33.rb#8968 def _reduce_92(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9061 + # source://parser//lib/parser/ruby33.rb#8975 def _reduce_93(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9068 + # source://parser//lib/parser/ruby33.rb#8982 def _reduce_94(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9076 + # source://parser//lib/parser/ruby33.rb#8990 def _reduce_95(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9083 + # source://parser//lib/parser/ruby33.rb#8997 def _reduce_96(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9091 + # source://parser//lib/parser/ruby33.rb#9005 def _reduce_97(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9097 + # source://parser//lib/parser/ruby33.rb#9011 def _reduce_98(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#9104 + # source://parser//lib/parser/ruby33.rb#9018 def _reduce_99(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#12699 + # source://parser//lib/parser/ruby33.rb#12584 def _reduce_none(val, _values, result); end - # source://parser//lib/parser/ruby32.rb#21 + # source://parser//lib/parser/ruby33.rb#21 def default_encoding; end - # source://parser//lib/parser/ruby32.rb#25 + # source://parser//lib/parser/ruby33.rb#25 def endless_method_name(name_t); end - # source://parser//lib/parser/ruby32.rb#38 + # source://parser//lib/parser/ruby33.rb#38 def local_pop; end - # source://parser//lib/parser/ruby32.rb#31 + # source://parser//lib/parser/ruby33.rb#31 def local_push; end - # source://parser//lib/parser/ruby32.rb#45 + # source://parser//lib/parser/ruby33.rb#45 def try_declare_numparam(node); end - # source://parser//lib/parser/ruby32.rb#17 + # source://parser//lib/parser/ruby33.rb#17 def version; end end -# source://parser//lib/parser/ruby32.rb#8008 -Parser::Ruby32::Racc_arg = T.let(T.unsafe(nil), Array) +# source://parser//lib/parser/ruby33.rb#7955 +Parser::Ruby33::Racc_arg = T.let(T.unsafe(nil), Array) -# source://parser//lib/parser/ruby32.rb#8415 -Parser::Ruby32::Racc_debug_parser = T.let(T.unsafe(nil), FalseClass) +# source://parser//lib/parser/ruby33.rb#8365 +Parser::Ruby33::Racc_debug_parser = T.let(T.unsafe(nil), FalseClass) -# source://parser//lib/parser/ruby32.rb#8025 -Parser::Ruby32::Racc_token_to_s_table = T.let(T.unsafe(nil), Array) +# source://parser//lib/parser/ruby33.rb#7972 +Parser::Ruby33::Racc_token_to_s_table = T.let(T.unsafe(nil), Array) # @api public # @@ -5125,7 +5129,7 @@ class Parser::Source::Buffer # @api public # @return [Buffer] a new instance of Buffer # - # source://parser//lib/parser/source/buffer.rb#105 + # source://parser//lib/parser/source/buffer.rb#110 def initialize(name, first_line = T.unsafe(nil), source: T.unsafe(nil)); end # Convert a character index into the source to a column number. @@ -5134,7 +5138,7 @@ class Parser::Source::Buffer # @param position [Integer] # @return [Integer] column # - # source://parser//lib/parser/source/buffer.rb#242 + # source://parser//lib/parser/source/buffer.rb#247 def column_for_position(position); end # Convert a character index into the source to a `[line, column]` tuple. @@ -5143,7 +5147,7 @@ class Parser::Source::Buffer # @param position [Integer] # @return [[Integer, Integer]] `[line, column]` # - # source://parser//lib/parser/source/buffer.rb#217 + # source://parser//lib/parser/source/buffer.rb#222 def decompose_position(position); end # First line of the buffer, 1 by default. @@ -5156,12 +5160,12 @@ class Parser::Source::Buffer # @api public # - # source://parser//lib/parser/source/buffer.rb#312 + # source://parser//lib/parser/source/buffer.rb#317 def freeze; end # @api public # - # source://parser//lib/parser/source/buffer.rb#318 + # source://parser//lib/parser/source/buffer.rb#323 def inspect; end # Number of last line in the buffer @@ -5169,7 +5173,7 @@ class Parser::Source::Buffer # @api public # @return [Integer] # - # source://parser//lib/parser/source/buffer.rb#307 + # source://parser//lib/parser/source/buffer.rb#312 def last_line; end # Convert a character index into the source to a line number. @@ -5178,7 +5182,7 @@ class Parser::Source::Buffer # @param position [Integer] # @return [Integer] line # - # source://parser//lib/parser/source/buffer.rb#231 + # source://parser//lib/parser/source/buffer.rb#236 def line_for_position(position); end # Extract line `lineno` as a new `Range`, taking `first_line` into account. @@ -5188,7 +5192,7 @@ class Parser::Source::Buffer # @raise [IndexError] if `lineno` is out of bounds # @return [Range] # - # source://parser//lib/parser/source/buffer.rb#284 + # source://parser//lib/parser/source/buffer.rb#289 def line_range(lineno); end # Buffer name. If the buffer was created from a file, the name corresponds @@ -5207,7 +5211,7 @@ class Parser::Source::Buffer # @raise [ArgumentError] if already populated # @return [String] # - # source://parser//lib/parser/source/buffer.rb#180 + # source://parser//lib/parser/source/buffer.rb#185 def raw_source=(input); end # Populate this buffer from correspondingly named file. @@ -5218,12 +5222,12 @@ class Parser::Source::Buffer # @raise [ArgumentError] if already populated # @return [Buffer] self # - # source://parser//lib/parser/source/buffer.rb#131 + # source://parser//lib/parser/source/buffer.rb#136 def read; end # @api public # - # source://parser//lib/parser/source/buffer.rb#194 + # source://parser//lib/parser/source/buffer.rb#199 def slice(start, length = T.unsafe(nil)); end # Source code contained in this buffer. @@ -5232,7 +5236,7 @@ class Parser::Source::Buffer # @raise [RuntimeError] if buffer is not populated yet # @return [String] source code # - # source://parser//lib/parser/source/buffer.rb#145 + # source://parser//lib/parser/source/buffer.rb#150 def source; end # Populate this buffer from a string with encoding autodetection. @@ -5244,7 +5248,7 @@ class Parser::Source::Buffer # @raise [EncodingError] if `input` includes invalid byte sequence for the encoding # @return [String] # - # source://parser//lib/parser/source/buffer.rb#162 + # source://parser//lib/parser/source/buffer.rb#167 def source=(input); end # Extract line `lineno` from source, taking `first_line` into account. @@ -5254,7 +5258,7 @@ class Parser::Source::Buffer # @raise [IndexError] if `lineno` is out of bounds # @return [String] # - # source://parser//lib/parser/source/buffer.rb#273 + # source://parser//lib/parser/source/buffer.rb#278 def source_line(lineno); end # Return an `Array` of source code lines. @@ -5262,30 +5266,30 @@ class Parser::Source::Buffer # @api public # @return [Array] # - # source://parser//lib/parser/source/buffer.rb#252 + # source://parser//lib/parser/source/buffer.rb#257 def source_lines; end # @api public # @return [Range] A range covering the whole source # - # source://parser//lib/parser/source/buffer.rb#298 + # source://parser//lib/parser/source/buffer.rb#303 def source_range; end private # @api public # - # source://parser//lib/parser/source/buffer.rb#348 + # source://parser//lib/parser/source/buffer.rb#353 def bsearch(line_begins, position); end # @api public # - # source://parser//lib/parser/source/buffer.rb#325 + # source://parser//lib/parser/source/buffer.rb#330 def line_begins; end # @api public # - # source://parser//lib/parser/source/buffer.rb#339 + # source://parser//lib/parser/source/buffer.rb#344 def line_index_for_position(position); end class << self @@ -5294,9 +5298,10 @@ class Parser::Source::Buffer # # @api public # @param string [String] + # @raise [Parser::UnknownEncodingInMagicComment] if the encoding is not recognized # @return [String, nil] encoding name, if recognized # - # source://parser//lib/parser/source/buffer.rb#51 + # source://parser//lib/parser/source/buffer.rb#52 def recognize_encoding(string); end # Recognize encoding of `input` and process it so it could be lexed. @@ -5314,7 +5319,7 @@ class Parser::Source::Buffer # @raise [EncodingError] # @return [String] # - # source://parser//lib/parser/source/buffer.rb#90 + # source://parser//lib/parser/source/buffer.rb#95 def reencode_string(input); end end end @@ -5452,7 +5457,7 @@ class Parser::Source::Comment::Associator # source://parser//lib/parser/source/comment/associator.rb#115 def associate_by_identity; end - # source://parser//lib/parser/source/comment/associator.rb#103 + # source://parser//lib/parser/source/comment/associator.rb#104 def associate_locations; end # source://parser//lib/parser/source/comment/associator.rb#46 @@ -6920,80 +6925,80 @@ end # source://parser//lib/parser/source/tree_rewriter.rb#391 Parser::Source::TreeRewriter::ACTIONS = T.let(T.unsafe(nil), Array) -# source://parser//lib/parser/source/tree_rewriter/action.rb#13 +# source://parser//lib/parser/source/tree_rewriter/action.rb#14 class Parser::Source::TreeRewriter::Action - # source://parser//lib/parser/source/tree_rewriter/action.rb#16 + # source://parser//lib/parser/source/tree_rewriter/action.rb#17 def initialize(range, enforcer, insert_before: T.unsafe(nil), replacement: T.unsafe(nil), insert_after: T.unsafe(nil), children: T.unsafe(nil)); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#28 + # source://parser//lib/parser/source/tree_rewriter/action.rb#29 def combine(action); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#67 + # source://parser//lib/parser/source/tree_rewriter/action.rb#68 def contract; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#33 + # source://parser//lib/parser/source/tree_rewriter/action.rb#34 def empty?; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#14 + # source://parser//lib/parser/source/tree_rewriter/action.rb#15 def insert_after; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#14 + # source://parser//lib/parser/source/tree_rewriter/action.rb#15 def insert_before; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#57 + # source://parser//lib/parser/source/tree_rewriter/action.rb#58 def insertion?; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#80 + # source://parser//lib/parser/source/tree_rewriter/action.rb#81 def moved(source_buffer, offset); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#49 + # source://parser//lib/parser/source/tree_rewriter/action.rb#50 def nested_actions; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#40 + # source://parser//lib/parser/source/tree_rewriter/action.rb#41 def ordered_replacements; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#14 + # source://parser//lib/parser/source/tree_rewriter/action.rb#15 def range; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#14 + # source://parser//lib/parser/source/tree_rewriter/action.rb#15 def replacement; end protected - # source://parser//lib/parser/source/tree_rewriter/action.rb#158 + # source://parser//lib/parser/source/tree_rewriter/action.rb#159 def analyse_hierarchy(action); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#145 + # source://parser//lib/parser/source/tree_rewriter/action.rb#146 def bsearch_child_index(from = T.unsafe(nil)); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#224 + # source://parser//lib/parser/source/tree_rewriter/action.rb#225 def call_enforcer_for_merge(action); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#204 + # source://parser//lib/parser/source/tree_rewriter/action.rb#205 def check_fusible(action, *fusible); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#94 + # source://parser//lib/parser/source/tree_rewriter/action.rb#95 def children; end - # source://parser//lib/parser/source/tree_rewriter/action.rb#129 + # source://parser//lib/parser/source/tree_rewriter/action.rb#130 def combine_children(more_children); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#102 + # source://parser//lib/parser/source/tree_rewriter/action.rb#103 def do_combine(action); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#135 + # source://parser//lib/parser/source/tree_rewriter/action.rb#136 def fuse_deletions(action, fusible, other_sibblings); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#215 + # source://parser//lib/parser/source/tree_rewriter/action.rb#216 def merge(action); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#110 + # source://parser//lib/parser/source/tree_rewriter/action.rb#111 def place_in_hierarchy(action); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#232 + # source://parser//lib/parser/source/tree_rewriter/action.rb#233 def swallow(children); end - # source://parser//lib/parser/source/tree_rewriter/action.rb#96 + # source://parser//lib/parser/source/tree_rewriter/action.rb#97 def with(range: T.unsafe(nil), enforcer: T.unsafe(nil), children: T.unsafe(nil), insert_before: T.unsafe(nil), replacement: T.unsafe(nil), insert_after: T.unsafe(nil)); end end @@ -7011,75 +7016,122 @@ Parser::Source::TreeRewriter::POLICY_TO_LEVEL = T.let(T.unsafe(nil), Hash) class Parser::StaticEnvironment # @return [StaticEnvironment] a new instance of StaticEnvironment # - # source://parser//lib/parser/static_environment.rb#11 + # source://parser//lib/parser/static_environment.rb#17 def initialize; end - # source://parser//lib/parser/static_environment.rb#40 + # source://parser//lib/parser/static_environment.rb#55 def declare(name); end - # source://parser//lib/parser/static_environment.rb#58 + # Anonymous blockarg + # + # source://parser//lib/parser/static_environment.rb#77 def declare_anonymous_blockarg; end - # source://parser//lib/parser/static_environment.rb#74 + # Anonymous kwresarg + # + # source://parser//lib/parser/static_environment.rb#113 def declare_anonymous_kwrestarg; end - # source://parser//lib/parser/static_environment.rb#66 + # Anonymous restarg + # + # source://parser//lib/parser/static_environment.rb#95 def declare_anonymous_restarg; end - # source://parser//lib/parser/static_environment.rb#50 + # Forward args + # + # source://parser//lib/parser/static_environment.rb#67 def declare_forward_args; end # @return [Boolean] # - # source://parser//lib/parser/static_environment.rb#46 + # source://parser//lib/parser/static_environment.rb#61 def declared?(name); end # @return [Boolean] # - # source://parser//lib/parser/static_environment.rb#62 + # source://parser//lib/parser/static_environment.rb#81 def declared_anonymous_blockarg?; end # @return [Boolean] # - # source://parser//lib/parser/static_environment.rb#78 + # source://parser//lib/parser/static_environment.rb#85 + def declared_anonymous_blockarg_in_current_scpe?; end + + # @return [Boolean] + # + # source://parser//lib/parser/static_environment.rb#117 def declared_anonymous_kwrestarg?; end # @return [Boolean] # - # source://parser//lib/parser/static_environment.rb#70 + # source://parser//lib/parser/static_environment.rb#121 + def declared_anonymous_kwrestarg_in_current_scope?; end + + # @return [Boolean] + # + # source://parser//lib/parser/static_environment.rb#99 def declared_anonymous_restarg?; end # @return [Boolean] # - # source://parser//lib/parser/static_environment.rb#54 + # source://parser//lib/parser/static_environment.rb#103 + def declared_anonymous_restarg_in_current_scope?; end + + # @return [Boolean] + # + # source://parser//lib/parser/static_environment.rb#71 def declared_forward_args?; end # @return [Boolean] # - # source://parser//lib/parser/static_environment.rb#82 + # source://parser//lib/parser/static_environment.rb#129 def empty?; end - # source://parser//lib/parser/static_environment.rb#27 + # source://parser//lib/parser/static_environment.rb#33 def extend_dynamic; end - # source://parser//lib/parser/static_environment.rb#20 + # source://parser//lib/parser/static_environment.rb#26 def extend_static; end - # source://parser//lib/parser/static_environment.rb#15 + # @return [Boolean] + # + # source://parser//lib/parser/static_environment.rb#89 + def parent_has_anonymous_blockarg?; end + + # @return [Boolean] + # + # source://parser//lib/parser/static_environment.rb#125 + def parent_has_anonymous_kwrestarg?; end + + # @return [Boolean] + # + # source://parser//lib/parser/static_environment.rb#107 + def parent_has_anonymous_restarg?; end + + # source://parser//lib/parser/static_environment.rb#21 def reset; end - # source://parser//lib/parser/static_environment.rb#34 + # source://parser//lib/parser/static_environment.rb#49 def unextend; end end -# source://parser//lib/parser/static_environment.rb#7 -Parser::StaticEnvironment::ANONYMOUS_BLOCKARG = T.let(T.unsafe(nil), Symbol) +# source://parser//lib/parser/static_environment.rb#15 +Parser::StaticEnvironment::ANONYMOUS_BLOCKARG_INHERITED = T.let(T.unsafe(nil), Symbol) + +# source://parser//lib/parser/static_environment.rb#14 +Parser::StaticEnvironment::ANONYMOUS_BLOCKARG_IN_CURRENT_SCOPE = T.let(T.unsafe(nil), Symbol) + +# source://parser//lib/parser/static_environment.rb#12 +Parser::StaticEnvironment::ANONYMOUS_KWRESTARG_INHERITED = T.let(T.unsafe(nil), Symbol) + +# source://parser//lib/parser/static_environment.rb#11 +Parser::StaticEnvironment::ANONYMOUS_KWRESTARG_IN_CURRENT_SCOPE = T.let(T.unsafe(nil), Symbol) # source://parser//lib/parser/static_environment.rb#9 -Parser::StaticEnvironment::ANONYMOUS_KWRESTARG = T.let(T.unsafe(nil), Symbol) +Parser::StaticEnvironment::ANONYMOUS_RESTARG_INHERITED = T.let(T.unsafe(nil), Symbol) # source://parser//lib/parser/static_environment.rb#8 -Parser::StaticEnvironment::ANONYMOUS_RESTARG = T.let(T.unsafe(nil), Symbol) +Parser::StaticEnvironment::ANONYMOUS_RESTARG_IN_CURRENT_SCOPE = T.let(T.unsafe(nil), Symbol) # source://parser//lib/parser/static_environment.rb#6 Parser::StaticEnvironment::FORWARD_ARGS = T.let(T.unsafe(nil), Symbol) @@ -7219,6 +7271,17 @@ class Parser::TreeRewriter < ::Parser::AST::Processor def wrap(range, before, after); end end +# {Parser::UnknownEncodingInMagicComment} is raised when a magic encoding +# comment is encountered that the currently running Ruby version doesn't +# recognize. It inherits from {ArgumentError} since that is the exception +# Ruby itself raises when trying to execute a file with an unknown encoding. +# As such, it is also not a {Parser::SyntaxError}. +# +# @api public +# +# source://parser//lib/parser/unknown_encoding_in_magic_comment_error.rb#13 +class Parser::UnknownEncodingInMagicComment < ::ArgumentError; end + # source://parser//lib/parser/version.rb#4 Parser::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/paypal-sdk-rest@1.7.4.rbi b/sorbet/rbi/gems/paypal-sdk-rest@1.7.5.rbi similarity index 99% rename from sorbet/rbi/gems/paypal-sdk-rest@1.7.4.rbi rename to sorbet/rbi/gems/paypal-sdk-rest@1.7.5.rbi index 52f8e4f71..a15135d81 100644 --- a/sorbet/rbi/gems/paypal-sdk-rest@1.7.4.rbi +++ b/sorbet/rbi/gems/paypal-sdk-rest@1.7.5.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `paypal-sdk-rest` gem. # Please instead update this file by running `bin/tapioca gem paypal-sdk-rest`. + # source://paypal-sdk-rest//lib/paypal-sdk-core.rb#1 module PayPal; end diff --git a/sorbet/rbi/gems/pg@1.5.3.rbi b/sorbet/rbi/gems/pg@1.5.7.rbi similarity index 95% rename from sorbet/rbi/gems/pg@1.5.3.rbi rename to sorbet/rbi/gems/pg@1.5.7.rbi index 07d88d07b..2a74684d8 100644 --- a/sorbet/rbi/gems/pg@1.5.3.rbi +++ b/sorbet/rbi/gems/pg@1.5.7.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `pg` gem. # Please instead update this file by running `bin/tapioca gem pg`. + # The top-level PG namespace. # # source://pg//lib/pg.rb#6 @@ -25,6 +26,13 @@ module PG # source://pg//lib/pg.rb#67 def make_shareable(obj); end + # Ruby-3.4+ prints a warning, if bigdecimal is required but not in the Gemfile. + # But it's a false positive, since we enable bigdecimal depending features only if it's available. + # And most people don't need these features. + # + # source://pg//lib/pg.rb#132 + def require_bigdecimal_without_warning; end + def threadsafe?; end # Get the PG library version. @@ -204,10 +212,10 @@ end # source://pg//lib/pg/basic_type_map_for_queries.rb#37 class PG::BasicTypeMapForQueries::BinaryData < ::String; end -# source://pg//lib/pg/basic_type_map_for_queries.rb#187 +# source://pg//lib/pg/basic_type_map_for_queries.rb#192 PG::BasicTypeMapForQueries::DEFAULT_ARRAY_TYPE_MAP = T.let(T.unsafe(nil), Hash) -# source://pg//lib/pg/basic_type_map_for_queries.rb#169 +# source://pg//lib/pg/basic_type_map_for_queries.rb#175 PG::BasicTypeMapForQueries::DEFAULT_TYPE_MAP = T.let(T.unsafe(nil), Hash) # source://pg//lib/pg/basic_type_map_for_queries.rb#40 @@ -333,19 +341,19 @@ class PG::BasicTypeRegistry # Alias the +old+ type to the +new+ type. # - # source://pg//lib/pg/basic_type_registry.rb#209 + # source://pg//lib/pg/basic_type_registry.rb#216 def alias_type(format, new, old); end # Retrieve a Hash of all en- or decoders for a given wire format. # The hash key is the name as defined in table +pg_type+. # The hash value is the registered coder object. # - # source://pg//lib/pg/basic_type_registry.rb#181 + # source://pg//lib/pg/basic_type_registry.rb#188 def coders_for(format, direction); end # Populate the registry with all builtin types of ruby-pg # - # source://pg//lib/pg/basic_type_registry.rb#222 + # source://pg//lib/pg/basic_type_registry.rb#229 def define_default_types; end # Register an encoder or decoder instance for casting a PostgreSQL type. @@ -353,12 +361,12 @@ class PG::BasicTypeRegistry # Coder#name must correspond to the +typname+ column in the +pg_type+ table. # Coder#format can be 0 for text format and 1 for binary. # - # source://pg//lib/pg/basic_type_registry.rb#190 + # source://pg//lib/pg/basic_type_registry.rb#197 def register_coder(coder); end # Populate the registry with all builtin types of ruby-pg # - # source://pg//lib/pg/basic_type_registry.rb#222 + # source://pg//lib/pg/basic_type_registry.rb#229 def register_default_types; end # Register the given +encoder_class+ and/or +decoder_class+ for casting a PostgreSQL type. @@ -366,7 +374,7 @@ class PG::BasicTypeRegistry # +name+ must correspond to the +typname+ column in the +pg_type+ table. # +format+ can be 0 for text format and 1 for binary. # - # source://pg//lib/pg/basic_type_registry.rb#202 + # source://pg//lib/pg/basic_type_registry.rb#209 def register_type(format, name, encoder_class, decoder_class); end end @@ -469,7 +477,7 @@ class PG::BasicTypeRegistry::CoderMapsBundle def init_maps(registry, result); end end -# source://pg//lib/pg/basic_type_registry.rb#297 +# source://pg//lib/pg/basic_type_registry.rb#308 PG::BasicTypeRegistry::DEFAULT_TYPE_REGISTRY = T.let(T.unsafe(nil), PG::BasicTypeRegistry) # source://pg//lib/pg.rb#76 @@ -823,7 +831,7 @@ class PG::Connection # Returns +nil+ on success, or a string containing the # error message if a failure occurs. # - # source://pg//lib/pg/connection.rb#582 + # source://pg//lib/pg/connection.rb#595 def async_cancel; end def async_describe_portal(_arg0); end @@ -850,7 +858,7 @@ class PG::Connection # Available since PostgreSQL-10. # See also corresponding {libpq function}[https://www.postgresql.org/docs/current/libpq-misc.html#LIBPQ-PQENCRYPTPASSWORDCONN]. # - # source://pg//lib/pg/connection.rb#555 + # source://pg//lib/pg/connection.rb#563 def async_encrypt_password(password, username, algorithm = T.unsafe(nil)); end def async_exec(*_arg0); end @@ -875,7 +883,7 @@ class PG::Connection # # See also #copy_data. # - # source://pg//lib/pg/connection.rb#423 + # source://pg//lib/pg/connection.rb#431 def async_get_copy_data(async = T.unsafe(nil), decoder = T.unsafe(nil)); end def async_get_last_result; end @@ -895,7 +903,7 @@ class PG::Connection # and the PG::Result object will automatically be cleared when the block terminates. # In this instance, conn.exec returns the value of the block. # - # source://pg//lib/pg/connection.rb#400 + # source://pg//lib/pg/connection.rb#408 def async_get_result; end # call-seq: @@ -904,7 +912,7 @@ class PG::Connection # Returns the blocking status of the database connection. # Returns +true+ if the connection is set to nonblocking mode and +false+ if blocking. # - # source://pg//lib/pg/connection.rb#471 + # source://pg//lib/pg/connection.rb#479 def async_isnonblocking; end def async_prepare(*_arg0); end @@ -927,7 +935,7 @@ class PG::Connection # # See also #copy_data. # - # source://pg//lib/pg/connection.rb#495 + # source://pg//lib/pg/connection.rb#503 def async_put_copy_data(buffer, encoder = T.unsafe(nil)); end # call-seq: @@ -943,7 +951,7 @@ class PG::Connection # not sent (*false* is only possible if the connection # is in nonblocking mode, and this command would block). # - # source://pg//lib/pg/connection.rb#525 + # source://pg//lib/pg/connection.rb#533 def async_put_copy_end(*args); end def async_query(*_arg0); end @@ -954,7 +962,7 @@ class PG::Connection # Resets the backend connection. This method closes the # backend connection and tries to re-connect. # - # source://pg//lib/pg/connection.rb#567 + # source://pg//lib/pg/connection.rb#575 def async_reset; end def async_set_client_encoding(_arg0); end @@ -975,7 +983,7 @@ class PG::Connection # # Returns +nil+. # - # source://pg//lib/pg/connection.rb#457 + # source://pg//lib/pg/connection.rb#465 def async_setnonblocking(enabled); end def backend_key; end @@ -991,7 +999,7 @@ class PG::Connection # Returns +nil+ on success, or a string containing the # error message if a failure occurs. # - # source://pg//lib/pg/connection.rb#582 + # source://pg//lib/pg/connection.rb#595 def cancel; end # Read all pending socket input to internal memory and raise an exception in case of errors. @@ -1005,7 +1013,7 @@ class PG::Connection # The method doesn't verify that the server is still responding. # To verify that the communication to the server works, it is recommended to use something like conn.exec('') instead. # - # source://pg//lib/pg/connection.rb#379 + # source://pg//lib/pg/connection.rb#387 def check_socket; end def client_encoding=(_arg0); end @@ -1014,13 +1022,13 @@ class PG::Connection # Returns an array of Hashes with connection defaults. See ::conndefaults # for details. # - # source://pg//lib/pg/connection.rb#321 + # source://pg//lib/pg/connection.rb#329 def conndefaults; end # Returns a Hash with connection defaults. See ::conndefaults_hash # for details. # - # source://pg//lib/pg/connection.rb#337 + # source://pg//lib/pg/connection.rb#345 def conndefaults_hash; end def connect_poll; end @@ -1033,58 +1041,12 @@ class PG::Connection # # See also #conninfo # - # source://pg//lib/pg/connection.rb#345 + # source://pg//lib/pg/connection.rb#353 def conninfo_hash; end def consume_input; end - # call-seq: - # conn.copy_data( sql [, coder] ) {|sql_result| ... } -> PG::Result - # - # Execute a copy process for transferring data to or from the server. - # - # This issues the SQL COPY command via #exec. The response to this - # (if there is no error in the command) is a PG::Result object that - # is passed to the block, bearing a status code of PGRES_COPY_OUT or - # PGRES_COPY_IN (depending on the specified copy direction). - # The application should then use #put_copy_data or #get_copy_data - # to receive or transmit data rows and should return from the block - # when finished. - # - # #copy_data returns another PG::Result object when the data transfer - # is complete. An exception is raised if some problem was encountered, - # so it isn't required to make use of any of them. - # At this point further SQL commands can be issued via #exec. - # (It is not possible to execute other SQL commands using the same - # connection while the COPY operation is in progress.) - # - # This method ensures, that the copy process is properly terminated - # in case of client side or server side failures. Therefore, in case - # of blocking mode of operation, #copy_data is preferred to raw calls - # of #put_copy_data, #get_copy_data and #put_copy_end. - # - # _coder_ can be a PG::Coder derivation - # (typically PG::TextEncoder::CopyRow or PG::TextDecoder::CopyRow). - # This enables encoding of data fields given to #put_copy_data - # or decoding of fields received by #get_copy_data. - # - # Example with CSV input format: - # conn.exec "create table my_table (a text,b text,c text,d text)" - # conn.copy_data "COPY my_table FROM STDIN CSV" do - # conn.put_copy_data "some,data,to,copy\n" - # conn.put_copy_data "more,data,to,copy\n" - # end - # This creates +my_table+ and inserts two CSV rows. - # - # The same with text format encoder PG::TextEncoder::CopyRow - # and Array input: - # enco = PG::TextEncoder::CopyRow.new - # conn.copy_data "COPY my_table FROM STDIN", enco do - # conn.put_copy_data ['some', 'data', 'to', 'copy'] - # conn.put_copy_data ['more', 'data', 'to', 'copy'] - # end - # - # Also PG::BinaryEncoder::CopyRow can be used to send data in binary format to the server. + # PG::BinaryEncoder::CopyRow can be used to send data in binary format to the server. # In this case copy_data generates the header and trailer data automatically: # enco = PG::BinaryEncoder::CopyRow.new # conn.copy_data "COPY my_table FROM STDIN (FORMAT binary)", enco do @@ -1128,7 +1090,7 @@ class PG::Connection # # @raise [PG::NotInBlockingMode] # - # source://pg//lib/pg/connection.rb#211 + # source://pg//lib/pg/connection.rb#214 def copy_data(sql, coder = T.unsafe(nil)); end def db; end @@ -1161,9 +1123,10 @@ class PG::Connection # Available since PostgreSQL-10. # See also corresponding {libpq function}[https://www.postgresql.org/docs/current/libpq-misc.html#LIBPQ-PQENCRYPTPASSWORDCONN]. # - # source://pg//lib/pg/connection.rb#555 + # source://pg//lib/pg/connection.rb#563 def encrypt_password(password, username, algorithm = T.unsafe(nil)); end + def enter_pipeline_mode; end def error_message; end def escape(_arg0); end def escape_bytea(_arg0); end @@ -1173,6 +1136,7 @@ class PG::Connection def exec(*_arg0); end def exec_params(*_arg0); end def exec_prepared(*_arg0); end + def exit_pipeline_mode; end def external_encoding; end def field_name_type; end def field_name_type=(_arg0); end @@ -1198,7 +1162,7 @@ class PG::Connection # # See also #copy_data. # - # source://pg//lib/pg/connection.rb#423 + # source://pg//lib/pg/connection.rb#431 def get_copy_data(async = T.unsafe(nil), decoder = T.unsafe(nil)); end def get_last_result; end @@ -1218,7 +1182,7 @@ class PG::Connection # and the PG::Result object will automatically be cleared when the block terminates. # In this instance, conn.exec returns the value of the block. # - # source://pg//lib/pg/connection.rb#400 + # source://pg//lib/pg/connection.rb#408 def get_result; end def host; end @@ -1239,7 +1203,7 @@ class PG::Connection # Returns the blocking status of the database connection. # Returns +true+ if the connection is set to nonblocking mode and +false+ if blocking. # - # source://pg//lib/pg/connection.rb#471 + # source://pg//lib/pg/connection.rb#479 def isnonblocking; end def lo_close(_arg0); end @@ -1276,7 +1240,7 @@ class PG::Connection # Returns the blocking status of the database connection. # Returns +true+ if the connection is set to nonblocking mode and +false+ if blocking. # - # source://pg//lib/pg/connection.rb#471 + # source://pg//lib/pg/connection.rb#479 def nonblocking?; end def notifies; end @@ -1284,6 +1248,8 @@ class PG::Connection def options; end def parameter_status(_arg0); end def pass; end + def pipeline_status; end + def pipeline_sync; end def port; end def prepare(*_arg0); end def protocol_version; end @@ -1306,7 +1272,7 @@ class PG::Connection # # See also #copy_data. # - # source://pg//lib/pg/connection.rb#495 + # source://pg//lib/pg/connection.rb#503 def put_copy_data(buffer, encoder = T.unsafe(nil)); end # call-seq: @@ -1322,7 +1288,7 @@ class PG::Connection # not sent (*false* is only possible if the connection # is in nonblocking mode, and this command would block). # - # source://pg//lib/pg/connection.rb#525 + # source://pg//lib/pg/connection.rb#533 def put_copy_end(*args); end def query(*_arg0); end @@ -1334,13 +1300,14 @@ class PG::Connection # Resets the backend connection. This method closes the # backend connection and tries to re-connect. # - # source://pg//lib/pg/connection.rb#567 + # source://pg//lib/pg/connection.rb#575 def reset; end def reset_poll; end def reset_start; end def send_describe_portal(_arg0); end def send_describe_prepared(_arg0); end + def send_flush_request; end def send_prepare(*_arg0); end def send_query(*_arg0); end def send_query_params(*_arg0); end @@ -1370,7 +1337,7 @@ class PG::Connection # # Returns +nil+. # - # source://pg//lib/pg/connection.rb#457 + # source://pg//lib/pg/connection.rb#465 def setnonblocking(enabled); end def socket; end @@ -1388,7 +1355,7 @@ class PG::Connection # # See also #ssl_attribute # - # source://pg//lib/pg/connection.rb#362 + # source://pg//lib/pg/connection.rb#370 def ssl_attributes; end def ssl_in_use?; end @@ -1420,7 +1387,7 @@ class PG::Connection # and a +COMMIT+ at the end of the block, or # +ROLLBACK+ if any exception occurs. # - # source://pg//lib/pg/connection.rb#305 + # source://pg//lib/pg/connection.rb#308 def transaction; end def transaction_status; end @@ -1436,10 +1403,11 @@ class PG::Connection private - # source://pg//lib/pg/connection.rb#637 + # source://pg//lib/pg/connection.rb#650 def async_connect_or_reset(poll_meth); end def flush_data=(_arg0); end + def reset_start2(_arg0); end class << self # Switch between sync and async libpq API. @@ -1458,7 +1426,7 @@ class PG::Connection # Do not use this method in production code. # Any issues with the default setting of async_api=true should be reported to the maintainers instead. # - # source://pg//lib/pg/connection.rb#937 + # source://pg//lib/pg/connection.rb#954 def async_api=(enable); end # call-seq: @@ -1513,7 +1481,7 @@ class PG::Connection # # Raises a PG::Error if the connection fails. # - # source://pg//lib/pg/connection.rb#758 + # source://pg//lib/pg/connection.rb#771 def async_connect(*args); end # call-seq: @@ -1540,10 +1508,10 @@ class PG::Connection # # See also check_socket for a way to check the connection without doing any server communication. # - # source://pg//lib/pg/connection.rb#858 + # source://pg//lib/pg/connection.rb#875 def async_ping(*args); end - # source://pg//lib/pg/connection.rb#914 + # source://pg//lib/pg/connection.rb#931 def async_send_api=(enable); end def conndefaults; end @@ -1553,7 +1521,7 @@ class PG::Connection # # See also #conndefaults # - # source://pg//lib/pg/connection.rb#329 + # source://pg//lib/pg/connection.rb#337 def conndefaults_hash; end # call-seq: @@ -1608,7 +1576,7 @@ class PG::Connection # # Raises a PG::Error if the connection fails. # - # source://pg//lib/pg/connection.rb#758 + # source://pg//lib/pg/connection.rb#771 def connect(*args); end # Convert Hash options to connection String @@ -1678,7 +1646,7 @@ class PG::Connection # # Raises a PG::Error if the connection fails. # - # source://pg//lib/pg/connection.rb#758 + # source://pg//lib/pg/connection.rb#771 def new(*args); end # call-seq: @@ -1733,7 +1701,7 @@ class PG::Connection # # Raises a PG::Error if the connection fails. # - # source://pg//lib/pg/connection.rb#758 + # source://pg//lib/pg/connection.rb#771 def open(*args); end # Parse the connection +args+ into a connection-parameter string. @@ -1776,7 +1744,7 @@ class PG::Connection # # See also check_socket for a way to check the connection without doing any server communication. # - # source://pg//lib/pg/connection.rb#858 + # source://pg//lib/pg/connection.rb#875 def ping(*args); end # Quote a single +value+ for use in a connection-parameter string. @@ -1838,7 +1806,7 @@ class PG::Connection # # Raises a PG::Error if the connection fails. # - # source://pg//lib/pg/connection.rb#758 + # source://pg//lib/pg/connection.rb#771 def setdb(*args); end # call-seq: @@ -1893,7 +1861,7 @@ class PG::Connection # # Raises a PG::Error if the connection fails. # - # source://pg//lib/pg/connection.rb#758 + # source://pg//lib/pg/connection.rb#771 def setdblogin(*args); end def sync_connect(*_arg0); end @@ -1902,11 +1870,14 @@ class PG::Connection private - # source://pg//lib/pg/connection.rb#776 + # source://pg//lib/pg/connection.rb#823 def connect_to_hosts(*args); end - # source://pg//lib/pg/connection.rb#828 + # source://pg//lib/pg/connection.rb#845 def host_is_named_pipe?(host_string); end + + # source://pg//lib/pg/connection.rb#792 + def resolve_hosts(iopts); end end end @@ -1931,6 +1902,7 @@ module PG::Constants; end PG::Constants::CONNECTION_AUTH_OK = T.let(T.unsafe(nil), Integer) PG::Constants::CONNECTION_AWAITING_RESPONSE = T.let(T.unsafe(nil), Integer) PG::Constants::CONNECTION_BAD = T.let(T.unsafe(nil), Integer) +PG::Constants::CONNECTION_CHECK_STANDBY = T.let(T.unsafe(nil), Integer) PG::Constants::CONNECTION_CHECK_TARGET = T.let(T.unsafe(nil), Integer) PG::Constants::CONNECTION_CHECK_WRITABLE = T.let(T.unsafe(nil), Integer) PG::Constants::CONNECTION_CONSUME = T.let(T.unsafe(nil), Integer) @@ -1954,6 +1926,8 @@ PG::Constants::PGRES_COPY_OUT = T.let(T.unsafe(nil), Integer) PG::Constants::PGRES_EMPTY_QUERY = T.let(T.unsafe(nil), Integer) PG::Constants::PGRES_FATAL_ERROR = T.let(T.unsafe(nil), Integer) PG::Constants::PGRES_NONFATAL_ERROR = T.let(T.unsafe(nil), Integer) +PG::Constants::PGRES_PIPELINE_ABORTED = T.let(T.unsafe(nil), Integer) +PG::Constants::PGRES_PIPELINE_SYNC = T.let(T.unsafe(nil), Integer) PG::Constants::PGRES_POLLING_FAILED = T.let(T.unsafe(nil), Integer) PG::Constants::PGRES_POLLING_OK = T.let(T.unsafe(nil), Integer) PG::Constants::PGRES_POLLING_READING = T.let(T.unsafe(nil), Integer) @@ -1994,6 +1968,9 @@ PG::Constants::PQTRANS_IDLE = T.let(T.unsafe(nil), Integer) PG::Constants::PQTRANS_INERROR = T.let(T.unsafe(nil), Integer) PG::Constants::PQTRANS_INTRANS = T.let(T.unsafe(nil), Integer) PG::Constants::PQTRANS_UNKNOWN = T.let(T.unsafe(nil), Integer) +PG::Constants::PQ_PIPELINE_ABORTED = T.let(T.unsafe(nil), Integer) +PG::Constants::PQ_PIPELINE_OFF = T.let(T.unsafe(nil), Integer) +PG::Constants::PQ_PIPELINE_ON = T.let(T.unsafe(nil), Integer) PG::Constants::SEEK_CUR = T.let(T.unsafe(nil), Integer) PG::Constants::SEEK_END = T.let(T.unsafe(nil), Integer) PG::Constants::SEEK_SET = T.let(T.unsafe(nil), Integer) @@ -2319,6 +2296,13 @@ class PG::Result end end +# PG::Connection#transaction uses this exception to distinguish a deliberate rollback from other exceptional situations. +# Normally, raising an exception will cause the .transaction method to rollback the database transaction and pass on the exception. +# But if you raise an PG::RollbackTransaction exception, then the database transaction will be rolled back, without passing on the exception. +# +# source://pg//lib/pg/exceptions.rb#27 +class PG::RollbackTransaction < ::StandardError; end + class PG::SEInvalidSpecification < ::PG::SavepointException; end class PG::SREFunctionExecutedNoReturnStatement < ::PG::SqlRoutineException; end class PG::SREModifyingSqlDataNotPermitted < ::PG::SqlRoutineException; end diff --git a/sorbet/rbi/gems/popper_js@1.16.1.rbi b/sorbet/rbi/gems/popper_js@1.16.1.rbi index 7dedfbd60..34f2b187f 100644 --- a/sorbet/rbi/gems/popper_js@1.16.1.rbi +++ b/sorbet/rbi/gems/popper_js@1.16.1.rbi @@ -4,11 +4,17 @@ # This is an autogenerated file for types exported from the `popper_js` gem. # Please instead update this file by running `bin/tapioca gem popper_js`. + # source://popper_js//lib/popper_js/version.rb#3 module PopperJs; end # source://popper_js//lib/popper_js/engine.rb#4 -class PopperJs::Engine < ::Rails::Engine; end +class PopperJs::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # source://popper_js//lib/popper_js/version.rb#4 PopperJs::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/prettier_print@1.2.1.rbi b/sorbet/rbi/gems/prettier_print@1.2.1.rbi deleted file mode 100644 index 7f655d840..000000000 --- a/sorbet/rbi/gems/prettier_print@1.2.1.rbi +++ /dev/null @@ -1,8 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `prettier_print` gem. -# Please instead update this file by running `bin/tapioca gem prettier_print`. - -# THIS IS AN EMPTY RBI FILE. -# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/prism@0.30.0.rbi b/sorbet/rbi/gems/prism@0.30.0.rbi new file mode 100644 index 000000000..9aec9c308 --- /dev/null +++ b/sorbet/rbi/gems/prism@0.30.0.rbi @@ -0,0 +1,39212 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `prism` gem. +# Please instead update this file by running `bin/tapioca gem prism`. + + +# typed: strict + +# =begin +# This file is generated by the templates/template.rb script and should not be +# modified manually. See templates/rbi/prism/node.rbi.erb +# if you are looking to modify the template +# =end +# =begin +# This file is generated by the templates/template.rb script and should not be +# modified manually. See templates/rbi/prism/visitor.rbi.erb +# if you are looking to modify the template +# =end + +# We keep these shims in here because our client libraries might not have parser +# in their bundle. +module Parser; end + +class Parser::Base; end + +# The Prism Ruby parser. +# +# "Parsing Ruby is suddenly manageable!" +# - You, hopefully +# +# source://prism//lib/prism.rb#8 +module Prism + class << self + # Mirror the Prism.dump API by using the serialization API. + def dump(*_arg0); end + + # Mirror the Prism.dump_file API by using the serialization API. + def dump_file(*_arg0); end + + # Mirror the Prism.lex API by using the serialization API. + def lex(*_arg0); end + + # :call-seq: + # Prism::lex_compat(source, **options) -> LexCompat::Result + # + # Returns a parse result whose value is an array of tokens that closely + # resembles the return value of Ripper::lex. The main difference is that the + # `:on_sp` token is not emitted. + # + # For supported options, see Prism::parse. + # + # source://prism//lib/prism.rb#45 + sig { params(source: String, options: T::Hash[Symbol, T.untyped]).returns(Prism::LexCompat::Result) } + def lex_compat(source, **options); end + + # Mirror the Prism.lex_file API by using the serialization API. + def lex_file(*_arg0); end + + # :call-seq: + # Prism::lex_ripper(source) -> Array + # + # This lexes with the Ripper lex. It drops any space events but otherwise + # returns the same tokens. Raises SyntaxError if the syntax in source is + # invalid. + # + # source://prism//lib/prism.rb#55 + sig { params(source: String).returns(T::Array[T.untyped]) } + def lex_ripper(source); end + + # :call-seq: + # Prism::load(source, serialized) -> ParseResult + # + # Load the serialized AST using the source as a reference into a tree. + # + # source://prism//lib/prism.rb#63 + sig { params(source: String, serialized: String).returns(Prism::ParseResult) } + def load(source, serialized); end + + # Mirror the Prism.parse API by using the serialization API. + def parse(*_arg0); end + + # Mirror the Prism.parse_comments API by using the serialization API. + def parse_comments(*_arg0); end + + # Mirror the Prism.parse_failure? API by using the serialization API. + # + # @return [Boolean] + def parse_failure?(*_arg0); end + + # Mirror the Prism.parse_file API by using the serialization API. This uses + # native strings instead of Ruby strings because it allows us to use mmap + # when it is available. + def parse_file(*_arg0); end + + # Mirror the Prism.parse_file_comments API by using the serialization + # API. This uses native strings instead of Ruby strings because it allows us + # to use mmap when it is available. + def parse_file_comments(*_arg0); end + + # Mirror the Prism.parse_file_failure? API by using the serialization API. + # + # @return [Boolean] + def parse_file_failure?(*_arg0); end + + # Mirror the Prism.parse_file_success? API by using the serialization API. + # + # @return [Boolean] + def parse_file_success?(*_arg0); end + + # Mirror the Prism.parse_lex API by using the serialization API. + def parse_lex(*_arg0); end + + # Mirror the Prism.parse_lex_file API by using the serialization API. + def parse_lex_file(*_arg0); end + + # Mirror the Prism.parse_stream API by using the serialization API. + def parse_stream(*_arg0); end + + # Mirror the Prism.parse_success? API by using the serialization API. + # + # @return [Boolean] + def parse_success?(*_arg0); end + + # Mirror the Prism.profile API by using the serialization API. + def profile(*_arg0); end + + # Mirror the Prism.profile_file API by using the serialization API. + def profile_file(*_arg0); end + end +end + +# Specialized version of Prism::Source for source code that includes ASCII +# characters only. This class is used to apply performance optimizations that +# cannot be applied to sources that include multibyte characters. Sources that +# include multibyte characters are represented by the Prism::Source class. +# +# source://prism//lib/prism/parse_result.rb#126 +class Prism::ASCIISource < ::Prism::Source + # Return the column number in characters for the given byte offset. + # + # source://prism//lib/prism/parse_result.rb#133 + sig { params(byte_offset: Integer).returns(Integer) } + def character_column(byte_offset); end + + # Return the character offset for the given byte offset. + # + # source://prism//lib/prism/parse_result.rb#128 + sig { params(byte_offset: Integer).returns(Integer) } + def character_offset(byte_offset); end + + # Specialized version of `code_units_column` that does not depend on + # `code_units_offset`, which is a more expensive operation. This is + # essentialy the same as `Prism::Source#column`. + # + # source://prism//lib/prism/parse_result.rb#150 + sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) } + def code_units_column(byte_offset, encoding); end + + # Returns the offset from the start of the file for the given byte offset + # counting in code units for the given encoding. + # + # This method is tested with UTF-8, UTF-16, and UTF-32. If there is the + # concept of code units that differs from the number of characters in other + # encodings, it is not captured here. + # + # source://prism//lib/prism/parse_result.rb#143 + sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) } + def code_units_offset(byte_offset, encoding); end +end + +# Represents the use of the `alias` keyword to alias a global variable. +# +# alias $foo $bar +# ^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#176 +class Prism::AliasGlobalVariableNode < ::Prism::Node + # def initialize: (Prism::node new_name, Prism::node old_name, Location keyword_loc, Location location) -> void + # + # @return [AliasGlobalVariableNode] a new instance of AliasGlobalVariableNode + # + # source://prism//lib/prism/node.rb#178 + sig do + params( + source: Prism::Source, + new_name: Prism::Node, + old_name: Prism::Node, + keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, new_name, old_name, keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#281 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#187 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#192 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#202 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#197 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?new_name: Prism::node, ?old_name: Prism::node, ?keyword_loc: Location, ?location: Location) -> AliasGlobalVariableNode + # + # source://prism//lib/prism/node.rb#207 + sig do + params( + new_name: Prism::Node, + old_name: Prism::Node, + keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::AliasGlobalVariableNode) + end + def copy(new_name: T.unsafe(nil), old_name: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#192 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { new_name: Prism::node, old_name: Prism::node, keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#215 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#247 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#242 + sig { returns(String) } + def keyword; end + + # The location of the `alias` keyword. + # + # alias $foo $bar + # ^^^^^ + # + # source://prism//lib/prism/node.rb#235 + sig { returns(Prism::Location) } + def keyword_loc; end + + # Represents the new name of the global variable that can be used after aliasing. This can be either a global variable, a back reference, or a numbered reference. + # + # alias $foo $bar + # ^^^^ + # + # source://prism//lib/prism/node.rb#223 + sig { returns(Prism::Node) } + def new_name; end + + # Represents the old name of the global variable that could be used before aliasing. This can be either a global variable, a back reference, or a numbered reference. + # + # alias $foo $bar + # ^^^^ + # + # source://prism//lib/prism/node.rb#229 + sig { returns(Prism::Node) } + def old_name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#265 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#275 + def type; end + end +end + +# Represents the use of the `alias` keyword to alias a method. +# +# alias foo bar +# ^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#293 +class Prism::AliasMethodNode < ::Prism::Node + # def initialize: (Prism::node new_name, Prism::node old_name, Location keyword_loc, Location location) -> void + # + # @return [AliasMethodNode] a new instance of AliasMethodNode + # + # source://prism//lib/prism/node.rb#295 + sig do + params( + source: Prism::Source, + new_name: Prism::Node, + old_name: Prism::Node, + keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, new_name, old_name, keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#389 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#304 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#309 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#319 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#314 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?new_name: Prism::node, ?old_name: Prism::node, ?keyword_loc: Location, ?location: Location) -> AliasMethodNode + # + # source://prism//lib/prism/node.rb#324 + sig do + params( + new_name: Prism::Node, + old_name: Prism::Node, + keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::AliasMethodNode) + end + def copy(new_name: T.unsafe(nil), old_name: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#309 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { new_name: Prism::node, old_name: Prism::node, keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#332 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#355 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#350 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#343 + sig { returns(Prism::Location) } + def keyword_loc; end + + # attr_reader new_name: Prism::node + # + # source://prism//lib/prism/node.rb#337 + sig { returns(Prism::Node) } + def new_name; end + + # attr_reader old_name: Prism::node + # + # source://prism//lib/prism/node.rb#340 + sig { returns(Prism::Node) } + def old_name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#373 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#383 + def type; end + end +end + +# Represents an alternation pattern in pattern matching. +# +# foo => bar | baz +# ^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#401 +class Prism::AlternationPatternNode < ::Prism::Node + # def initialize: (Prism::node left, Prism::node right, Location operator_loc, Location location) -> void + # + # @return [AlternationPatternNode] a new instance of AlternationPatternNode + # + # source://prism//lib/prism/node.rb#403 + sig do + params( + source: Prism::Source, + left: Prism::Node, + right: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, left, right, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#497 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#412 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#417 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#427 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#422 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?left: Prism::node, ?right: Prism::node, ?operator_loc: Location, ?location: Location) -> AlternationPatternNode + # + # source://prism//lib/prism/node.rb#432 + sig do + params( + left: Prism::Node, + right: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::AlternationPatternNode) + end + def copy(left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#417 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { left: Prism::node, right: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#440 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#463 + sig { override.returns(String) } + def inspect; end + + # attr_reader left: Prism::node + # + # source://prism//lib/prism/node.rb#445 + sig { returns(Prism::Node) } + def left; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#458 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#451 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader right: Prism::node + # + # source://prism//lib/prism/node.rb#448 + sig { returns(Prism::Node) } + def right; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#481 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#491 + def type; end + end +end + +# Represents the use of the `&&` operator or the `and` keyword. +# +# left and right +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#509 +class Prism::AndNode < ::Prism::Node + # def initialize: (Prism::node left, Prism::node right, Location operator_loc, Location location) -> void + # + # @return [AndNode] a new instance of AndNode + # + # source://prism//lib/prism/node.rb#511 + sig do + params( + source: Prism::Source, + left: Prism::Node, + right: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, left, right, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#620 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#520 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#525 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#535 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#530 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?left: Prism::node, ?right: Prism::node, ?operator_loc: Location, ?location: Location) -> AndNode + # + # source://prism//lib/prism/node.rb#540 + sig do + params( + left: Prism::Node, + right: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::AndNode) + end + def copy(left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#525 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { left: Prism::node, right: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#548 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#586 + sig { override.returns(String) } + def inspect; end + + # Represents the left side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # left and right + # ^^^^ + # + # 1 && 2 + # ^ + # + # source://prism//lib/prism/node.rb#559 + sig { returns(Prism::Node) } + def left; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#581 + sig { returns(String) } + def operator; end + + # The location of the `and` keyword or the `&&` operator. + # + # left and right + # ^^^ + # + # source://prism//lib/prism/node.rb#574 + sig { returns(Prism::Location) } + def operator_loc; end + + # Represents the right side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # left && right + # ^^^^^ + # + # 1 and 2 + # ^ + # + # source://prism//lib/prism/node.rb#568 + sig { returns(Prism::Node) } + def right; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#604 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#614 + def type; end + end +end + +# Represents a set of arguments to a method or a keyword. +# +# return foo, bar, baz +# ^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#632 +class Prism::ArgumentsNode < ::Prism::Node + # def initialize: (Integer flags, Array[Prism::node] arguments, Location location) -> void + # + # @return [ArgumentsNode] a new instance of ArgumentsNode + # + # source://prism//lib/prism/node.rb#634 + sig do + params( + source: Prism::Source, + flags: Integer, + arguments: T::Array[Prism::Node], + location: Prism::Location + ).void + end + def initialize(source, flags, arguments, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#726 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#642 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#679 + sig { returns(T::Array[Prism::Node]) } + def arguments; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#647 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#657 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#652 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def contains_keyword_splat?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#687 + sig { returns(T::Boolean) } + def contains_keyword_splat?; end + + # def contains_keywords?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#682 + sig { returns(T::Boolean) } + def contains_keywords?; end + + # def copy: (?flags: Integer, ?arguments: Array[Prism::node], ?location: Location) -> ArgumentsNode + # + # source://prism//lib/prism/node.rb#662 + sig do + params( + flags: Integer, + arguments: T::Array[Prism::Node], + location: Prism::Location + ).returns(Prism::ArgumentsNode) + end + def copy(flags: T.unsafe(nil), arguments: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#647 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, arguments: Array[Prism::node], location: Location } + # + # source://prism//lib/prism/node.rb#670 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#692 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#710 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#675 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#720 + def type; end + end +end + +# Flags for arguments nodes. +# +# source://prism//lib/prism/node.rb#19127 +module Prism::ArgumentsNodeFlags; end + +# if arguments contain keywords +# +# source://prism//lib/prism/node.rb#19129 +Prism::ArgumentsNodeFlags::CONTAINS_KEYWORDS = T.let(T.unsafe(nil), Integer) + +# if arguments contain keyword splat +# +# source://prism//lib/prism/node.rb#19132 +Prism::ArgumentsNodeFlags::CONTAINS_KEYWORD_SPLAT = T.let(T.unsafe(nil), Integer) + +# Represents an array literal. This can be a regular array using brackets or a special array using % like %w or %i. +# +# [1, 2, 3] +# ^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#738 +class Prism::ArrayNode < ::Prism::Node + # def initialize: (Integer flags, Array[Prism::node] elements, Location? opening_loc, Location? closing_loc, Location location) -> void + # + # @return [ArrayNode] a new instance of ArrayNode + # + # source://prism//lib/prism/node.rb#740 + sig do + params( + source: Prism::Source, + flags: Integer, + elements: T::Array[Prism::Node], + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, flags, elements, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#875 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#750 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#755 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#836 + sig { returns(T.nilable(String)) } + def closing; end + + # Represents the optional source location for the closing token. + # + # [1,2,3] # "]" + # %w[foo bar baz] # "]" + # %I(apple orange banana) # ")" + # foo = 1, 2, 3 # nil + # + # source://prism//lib/prism/node.rb#813 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#765 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#760 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def contains_splat?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#826 + sig { returns(T::Boolean) } + def contains_splat?; end + + # def copy: (?flags: Integer, ?elements: Array[Prism::node], ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> ArrayNode + # + # source://prism//lib/prism/node.rb#770 + sig do + params( + flags: Integer, + elements: T::Array[Prism::Node], + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::ArrayNode) + end + def copy(flags: T.unsafe(nil), elements: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#755 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, elements: Array[Prism::node], opening_loc: Location?, closing_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#778 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # Represent the list of zero or more [non-void expressions](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression) within the array. + # + # source://prism//lib/prism/node.rb#787 + sig { returns(T::Array[Prism::Node]) } + def elements; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#841 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#831 + sig { returns(T.nilable(String)) } + def opening; end + + # Represents the optional source location for the opening token. + # + # [1,2,3] # "[" + # %w[foo bar baz] # "%w[" + # %I(apple orange banana) # "%I(" + # foo = 1, 2, 3 # nil + # + # source://prism//lib/prism/node.rb#795 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#859 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#783 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#869 + def type; end + end +end + +# Flags for array nodes. +# +# source://prism//lib/prism/node.rb#19136 +module Prism::ArrayNodeFlags; end + +# if array contains splat nodes +# +# source://prism//lib/prism/node.rb#19138 +Prism::ArrayNodeFlags::CONTAINS_SPLAT = T.let(T.unsafe(nil), Integer) + +# Represents an array pattern in pattern matching. +# +# foo in 1, 2 +# ^^^^^^^^^^^ +# +# foo in [1, 2] +# ^^^^^^^^^^^^^ +# +# foo in *1 +# ^^^^^^^^^ +# +# foo in Bar[] +# ^^^^^^^^^^^^ +# +# foo in Bar[1, 2, 3] +# ^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#901 +class Prism::ArrayPatternNode < ::Prism::Node + # def initialize: (Prism::node? constant, Array[Prism::node] requireds, Prism::node? rest, Array[Prism::node] posts, Location? opening_loc, Location? closing_loc, Location location) -> void + # + # @return [ArrayPatternNode] a new instance of ArrayPatternNode + # + # source://prism//lib/prism/node.rb#903 + sig do + params( + source: Prism::Source, + constant: T.nilable(Prism::Node), + requireds: T::Array[Prism::Node], + rest: T.nilable(Prism::Node), + posts: T::Array[Prism::Node], + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, constant, requireds, rest, posts, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1035 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#915 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#920 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#996 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#978 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#935 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#925 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader constant: Prism::node? + # + # source://prism//lib/prism/node.rb#953 + sig { returns(T.nilable(Prism::Node)) } + def constant; end + + # def copy: (?constant: Prism::node?, ?requireds: Array[Prism::node], ?rest: Prism::node?, ?posts: Array[Prism::node], ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> ArrayPatternNode + # + # source://prism//lib/prism/node.rb#940 + sig do + params( + constant: T.nilable(Prism::Node), + requireds: T::Array[Prism::Node], + rest: T.nilable(Prism::Node), + posts: T::Array[Prism::Node], + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::ArrayPatternNode) + end + def copy(constant: T.unsafe(nil), requireds: T.unsafe(nil), rest: T.unsafe(nil), posts: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#920 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { constant: Prism::node?, requireds: Array[Prism::node], rest: Prism::node?, posts: Array[Prism::node], opening_loc: Location?, closing_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#948 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1001 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#991 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#965 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # attr_reader posts: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#962 + sig { returns(T::Array[Prism::Node]) } + def posts; end + + # attr_reader requireds: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#956 + sig { returns(T::Array[Prism::Node]) } + def requireds; end + + # attr_reader rest: Prism::node? + # + # source://prism//lib/prism/node.rb#959 + sig { returns(T.nilable(Prism::Node)) } + def rest; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1019 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1029 + def type; end + end +end + +# Represents a hash key/value pair. +# +# { a => b } +# ^^^^^^ +# +# source://prism//lib/prism/node.rb#1052 +class Prism::AssocNode < ::Prism::Node + # def initialize: (Prism::node key, Prism::node value, Location? operator_loc, Location location) -> void + # + # @return [AssocNode] a new instance of AssocNode + # + # source://prism//lib/prism/node.rb#1054 + sig do + params( + source: Prism::Source, + key: Prism::Node, + value: Prism::Node, + operator_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, key, value, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1172 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1063 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1068 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1078 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1073 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?key: Prism::node, ?value: Prism::node, ?operator_loc: Location?, ?location: Location) -> AssocNode + # + # source://prism//lib/prism/node.rb#1083 + sig do + params( + key: Prism::Node, + value: Prism::Node, + operator_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::AssocNode) + end + def copy(key: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1068 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { key: Prism::node, value: Prism::node, operator_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#1091 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1138 + sig { override.returns(String) } + def inspect; end + + # The key of the association. This can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # { a: b } + # ^ + # + # { foo => bar } + # ^^^ + # + # { def a; end => 1 } + # ^^^^^^^^^^ + # + # source://prism//lib/prism/node.rb#1105 + sig { returns(Prism::Node) } + def key; end + + # def operator: () -> String? + # + # source://prism//lib/prism/node.rb#1133 + sig { returns(T.nilable(String)) } + def operator; end + + # The location of the `=>` operator, if present. + # + # { foo => bar } + # ^^ + # + # source://prism//lib/prism/node.rb#1120 + sig { returns(T.nilable(Prism::Location)) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1156 + sig { override.returns(Symbol) } + def type; end + + # The value of the association, if present. This can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # { foo => bar } + # ^^^ + # + # { x: 1 } + # ^ + # + # source://prism//lib/prism/node.rb#1114 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1166 + def type; end + end +end + +# Represents a splat in a hash literal. +# +# { **foo } +# ^^^^^ +# +# source://prism//lib/prism/node.rb#1184 +class Prism::AssocSplatNode < ::Prism::Node + # def initialize: (Prism::node? value, Location operator_loc, Location location) -> void + # + # @return [AssocSplatNode] a new instance of AssocSplatNode + # + # source://prism//lib/prism/node.rb#1186 + sig do + params( + source: Prism::Source, + value: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, value, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1284 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1194 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1199 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1211 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1204 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?value: Prism::node?, ?operator_loc: Location, ?location: Location) -> AssocSplatNode + # + # source://prism//lib/prism/node.rb#1216 + sig do + params( + value: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::AssocSplatNode) + end + def copy(value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1199 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node?, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#1224 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1250 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#1245 + sig { returns(String) } + def operator; end + + # The location of the `**` operator. + # + # { **x } + # ^^ + # + # source://prism//lib/prism/node.rb#1238 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1268 + sig { override.returns(Symbol) } + def type; end + + # The value to be splatted, if present. Will be missing when keyword rest argument forwarding is used. + # + # { **foo } + # ^^^ + # + # source://prism//lib/prism/node.rb#1232 + sig { returns(T.nilable(Prism::Node)) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1278 + def type; end + end +end + +# The FFI backend is used on other Ruby implementations. +# +# source://prism//lib/prism.rb#81 +Prism::BACKEND = T.let(T.unsafe(nil), Symbol) + +# Represents reading a reference to a field in the previous match. +# +# $' +# ^^ +# +# source://prism//lib/prism/node.rb#1295 +class Prism::BackReferenceReadNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [BackReferenceReadNode] a new instance of BackReferenceReadNode + # + # source://prism//lib/prism/node.rb#1297 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1378 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1304 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1309 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1319 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1314 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> BackReferenceReadNode + # + # source://prism//lib/prism/node.rb#1324 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::BackReferenceReadNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1309 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#1332 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1344 + sig { override.returns(String) } + def inspect; end + + # The name of the back-reference variable, including the leading `$`. + # + # $& # name `:$&` + # + # $+ # name `:$+` + # + # source://prism//lib/prism/node.rb#1341 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1362 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1372 + def type; end + end +end + +# A class that knows how to walk down the tree. None of the individual visit +# methods are implemented on this visitor, so it forces the consumer to +# implement each one that they need. For a default implementation that +# continues walking the tree, see the Visitor class. +# +# source://prism//lib/prism/visitor.rb#14 +class Prism::BasicVisitor + # Calls `accept` on the given node if it is not `nil`, which in turn should + # call back into this visitor by calling the appropriate `visit_*` method. + # + # source://prism//lib/prism/visitor.rb#17 + sig { params(node: T.nilable(Prism::Node)).void } + def visit(node); end + + # Visits each node in `nodes` by calling `accept` on each one. + # + # source://prism//lib/prism/visitor.rb#23 + sig { params(nodes: T::Array[T.nilable(Prism::Node)]).void } + def visit_all(nodes); end + + # Visits the child nodes of `node` by calling `accept` on each one. + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::Node).void } + def visit_child_nodes(node); end +end + +# Represents a begin statement. +# +# begin +# foo +# end +# ^^^^^ +# +# source://prism//lib/prism/node.rb#1390 +class Prism::BeginNode < ::Prism::Node + # def initialize: (Location? begin_keyword_loc, StatementsNode? statements, RescueNode? rescue_clause, ElseNode? else_clause, EnsureNode? ensure_clause, Location? end_keyword_loc, Location location) -> void + # + # @return [BeginNode] a new instance of BeginNode + # + # source://prism//lib/prism/node.rb#1392 + sig do + params( + source: Prism::Source, + begin_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + rescue_clause: T.nilable(Prism::RescueNode), + else_clause: T.nilable(Prism::ElseNode), + ensure_clause: T.nilable(Prism::EnsureNode), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, begin_keyword_loc, statements, rescue_clause, else_clause, ensure_clause, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1524 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1404 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def begin_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#1480 + sig { returns(T.nilable(String)) } + def begin_keyword; end + + # attr_reader begin_keyword_loc: Location? + # + # source://prism//lib/prism/node.rb#1442 + sig { returns(T.nilable(Prism::Location)) } + def begin_keyword_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1409 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1424 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1414 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?begin_keyword_loc: Location?, ?statements: StatementsNode?, ?rescue_clause: RescueNode?, ?else_clause: ElseNode?, ?ensure_clause: EnsureNode?, ?end_keyword_loc: Location?, ?location: Location) -> BeginNode + # + # source://prism//lib/prism/node.rb#1429 + sig do + params( + begin_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + rescue_clause: T.nilable(Prism::RescueNode), + else_clause: T.nilable(Prism::ElseNode), + ensure_clause: T.nilable(Prism::EnsureNode), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::BeginNode) + end + def copy(begin_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), rescue_clause: T.unsafe(nil), else_clause: T.unsafe(nil), ensure_clause: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1409 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { begin_keyword_loc: Location?, statements: StatementsNode?, rescue_clause: RescueNode?, else_clause: ElseNode?, ensure_clause: EnsureNode?, end_keyword_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#1437 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader else_clause: ElseNode? + # + # source://prism//lib/prism/node.rb#1461 + sig { returns(T.nilable(Prism::ElseNode)) } + def else_clause; end + + # def end_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#1485 + sig { returns(T.nilable(String)) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location? + # + # source://prism//lib/prism/node.rb#1467 + sig { returns(T.nilable(Prism::Location)) } + def end_keyword_loc; end + + # attr_reader ensure_clause: EnsureNode? + # + # source://prism//lib/prism/node.rb#1464 + sig { returns(T.nilable(Prism::EnsureNode)) } + def ensure_clause; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1490 + sig { override.returns(String) } + def inspect; end + + # source://prism//lib/prism/parse_result/newlines.rb#79 + def newline!(lines); end + + # attr_reader rescue_clause: RescueNode? + # + # source://prism//lib/prism/node.rb#1458 + sig { returns(T.nilable(Prism::RescueNode)) } + def rescue_clause; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#1455 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1508 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1518 + def type; end + end +end + +# Represents block method arguments. +# +# bar(&args) +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#1539 +class Prism::BlockArgumentNode < ::Prism::Node + # def initialize: (Prism::node? expression, Location operator_loc, Location location) -> void + # + # @return [BlockArgumentNode] a new instance of BlockArgumentNode + # + # source://prism//lib/prism/node.rb#1541 + sig do + params( + source: Prism::Source, + expression: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, expression, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1633 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1549 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1554 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1566 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1559 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?expression: Prism::node?, ?operator_loc: Location, ?location: Location) -> BlockArgumentNode + # + # source://prism//lib/prism/node.rb#1571 + sig do + params( + expression: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::BlockArgumentNode) + end + def copy(expression: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1554 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { expression: Prism::node?, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#1579 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader expression: Prism::node? + # + # source://prism//lib/prism/node.rb#1584 + sig { returns(T.nilable(Prism::Node)) } + def expression; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1599 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#1594 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#1587 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1617 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1627 + def type; end + end +end + +# Represents a block local variable. +# +# a { |; b| } +# ^ +# +# source://prism//lib/prism/node.rb#1644 +class Prism::BlockLocalVariableNode < ::Prism::Node + # def initialize: (Integer flags, Symbol name, Location location) -> void + # + # @return [BlockLocalVariableNode] a new instance of BlockLocalVariableNode + # + # source://prism//lib/prism/node.rb#1646 + sig { params(source: Prism::Source, flags: Integer, name: Symbol, location: Prism::Location).void } + def initialize(source, flags, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1733 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1654 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1659 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1669 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1664 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol, ?location: Location) -> BlockLocalVariableNode + # + # source://prism//lib/prism/node.rb#1674 + sig { params(flags: Integer, name: Symbol, location: Prism::Location).returns(Prism::BlockLocalVariableNode) } + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1659 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#1682 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1699 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#1691 + sig { returns(Symbol) } + def name; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#1694 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1717 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#1687 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1727 + def type; end + end +end + +# Represents a block of ruby code. +# +# [1, 2, 3].each { |i| puts x } +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#1744 +class Prism::BlockNode < ::Prism::Node + # def initialize: (Array[Symbol] locals, Prism::node? parameters, Prism::node? body, Location opening_loc, Location closing_loc, Location location) -> void + # + # @return [BlockNode] a new instance of BlockNode + # + # source://prism//lib/prism/node.rb#1746 + sig do + params( + source: Prism::Source, + locals: T::Array[Symbol], + parameters: T.nilable(Prism::Node), + body: T.nilable(Prism::Node), + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, locals, parameters, body, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1860 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1757 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Prism::node? + # + # source://prism//lib/prism/node.rb#1799 + sig { returns(T.nilable(Prism::Node)) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1762 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#1821 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#1809 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1775 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1767 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?locals: Array[Symbol], ?parameters: Prism::node?, ?body: Prism::node?, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> BlockNode + # + # source://prism//lib/prism/node.rb#1780 + sig do + params( + locals: T::Array[Symbol], + parameters: T.nilable(Prism::Node), + body: T.nilable(Prism::Node), + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::BlockNode) + end + def copy(locals: T.unsafe(nil), parameters: T.unsafe(nil), body: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1762 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], parameters: Prism::node?, body: Prism::node?, opening_loc: Location, closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#1788 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1826 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[Symbol] + # + # source://prism//lib/prism/node.rb#1793 + sig { returns(T::Array[Symbol]) } + def locals; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#1816 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#1802 + sig { returns(Prism::Location) } + def opening_loc; end + + # attr_reader parameters: Prism::node? + # + # source://prism//lib/prism/node.rb#1796 + sig { returns(T.nilable(Prism::Node)) } + def parameters; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1844 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1854 + def type; end + end +end + +# Represents a block parameter to a method, block, or lambda definition. +# +# def a(&b) +# ^^ +# end +# +# source://prism//lib/prism/node.rb#1876 +class Prism::BlockParameterNode < ::Prism::Node + # def initialize: (Integer flags, Symbol? name, Location? name_loc, Location operator_loc, Location location) -> void + # + # @return [BlockParameterNode] a new instance of BlockParameterNode + # + # source://prism//lib/prism/node.rb#1878 + sig do + params( + source: Prism::Source, + flags: Integer, + name: T.nilable(Symbol), + name_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, name, name_loc, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#1992 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#1888 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1893 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#1903 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#1898 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol?, ?name_loc: Location?, ?operator_loc: Location, ?location: Location) -> BlockParameterNode + # + # source://prism//lib/prism/node.rb#1908 + sig do + params( + flags: Integer, + name: T.nilable(Symbol), + name_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::BlockParameterNode) + end + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#1893 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol?, name_loc: Location?, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#1916 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#1958 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol? + # + # source://prism//lib/prism/node.rb#1925 + sig { returns(T.nilable(Symbol)) } + def name; end + + # attr_reader name_loc: Location? + # + # source://prism//lib/prism/node.rb#1928 + sig { returns(T.nilable(Prism::Location)) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#1953 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#1941 + sig { returns(Prism::Location) } + def operator_loc; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#1948 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1976 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#1921 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#1986 + def type; end + end +end + +# Represents a block's parameters declaration. +# +# -> (a, b = 1; local) { } +# ^^^^^^^^^^^^^^^^^ +# +# foo do |a, b = 1; local| +# ^^^^^^^^^^^^^^^^^ +# end +# +# source://prism//lib/prism/node.rb#2009 +class Prism::BlockParametersNode < ::Prism::Node + # def initialize: (ParametersNode? parameters, Array[BlockLocalVariableNode] locals, Location? opening_loc, Location? closing_loc, Location location) -> void + # + # @return [BlockParametersNode] a new instance of BlockParametersNode + # + # source://prism//lib/prism/node.rb#2011 + sig do + params( + source: Prism::Source, + parameters: T.nilable(Prism::ParametersNode), + locals: T::Array[Prism::BlockLocalVariableNode], + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, parameters, locals, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#2133 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#2021 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2026 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#2094 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#2076 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#2039 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#2031 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?parameters: ParametersNode?, ?locals: Array[BlockLocalVariableNode], ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> BlockParametersNode + # + # source://prism//lib/prism/node.rb#2044 + sig do + params( + parameters: T.nilable(Prism::ParametersNode), + locals: T::Array[Prism::BlockLocalVariableNode], + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::BlockParametersNode) + end + def copy(parameters: T.unsafe(nil), locals: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2026 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { parameters: ParametersNode?, locals: Array[BlockLocalVariableNode], opening_loc: Location?, closing_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#2052 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#2099 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[BlockLocalVariableNode] + # + # source://prism//lib/prism/node.rb#2060 + sig { returns(T::Array[Prism::BlockLocalVariableNode]) } + def locals; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#2089 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#2063 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # attr_reader parameters: ParametersNode? + # + # source://prism//lib/prism/node.rb#2057 + sig { returns(T.nilable(Prism::ParametersNode)) } + def parameters; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2117 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2127 + def type; end + end +end + +# Represents the use of the `break` keyword. +# +# break foo +# ^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#2147 +class Prism::BreakNode < ::Prism::Node + # def initialize: (ArgumentsNode? arguments, Location keyword_loc, Location location) -> void + # + # @return [BreakNode] a new instance of BreakNode + # + # source://prism//lib/prism/node.rb#2149 + sig do + params( + source: Prism::Source, + arguments: T.nilable(Prism::ArgumentsNode), + keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, arguments, keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#2247 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#2157 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # The arguments to the break statement, if present. These can be any [non-void expressions](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # break foo + # ^^^ + # + # source://prism//lib/prism/node.rb#2195 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2162 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#2174 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#2167 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?arguments: ArgumentsNode?, ?keyword_loc: Location, ?location: Location) -> BreakNode + # + # source://prism//lib/prism/node.rb#2179 + sig do + params( + arguments: T.nilable(Prism::ArgumentsNode), + keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::BreakNode) + end + def copy(arguments: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2162 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { arguments: ArgumentsNode?, keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#2187 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#2213 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#2208 + sig { returns(String) } + def keyword; end + + # The location of the `break` keyword. + # + # break foo + # ^^^^^ + # + # source://prism//lib/prism/node.rb#2201 + sig { returns(Prism::Location) } + def keyword_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2231 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2241 + def type; end + end +end + +# Represents the use of the `&&=` operator on a call. +# +# foo.bar &&= value +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#2258 +class Prism::CallAndWriteNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location? message_loc, Symbol read_name, Symbol write_name, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [CallAndWriteNode] a new instance of CallAndWriteNode + # + # source://prism//lib/prism/node.rb#2260 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + message_loc: T.nilable(Prism::Location), + read_name: Symbol, + write_name: Symbol, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#2428 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#2274 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2369 + sig { returns(T::Boolean) } + def attribute_write?; end + + # def call_operator: () -> String? + # + # source://prism//lib/prism/node.rb#2379 + sig { returns(T.nilable(String)) } + def call_operator; end + + # attr_reader call_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#2317 + sig { returns(T.nilable(Prism::Location)) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2279 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#2292 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#2284 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?message_loc: Location?, ?read_name: Symbol, ?write_name: Symbol, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> CallAndWriteNode + # + # source://prism//lib/prism/node.rb#2297 + sig do + params( + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + message_loc: T.nilable(Prism::Location), + read_name: Symbol, + write_name: Symbol, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::CallAndWriteNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), message_loc: T.unsafe(nil), read_name: T.unsafe(nil), write_name: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2279 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, message_loc: Location?, read_name: Symbol, write_name: Symbol, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#2305 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2374 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#2394 + sig { override.returns(String) } + def inspect; end + + # def message: () -> String? + # + # source://prism//lib/prism/node.rb#2384 + sig { returns(T.nilable(String)) } + def message; end + + # attr_reader message_loc: Location? + # + # source://prism//lib/prism/node.rb#2330 + sig { returns(T.nilable(Prism::Location)) } + def message_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#2389 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#2349 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader read_name: Symbol + # + # source://prism//lib/prism/node.rb#2343 + sig { returns(Symbol) } + def read_name; end + + # attr_reader receiver: Prism::node? + # + # source://prism//lib/prism/node.rb#2314 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2359 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2412 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#2356 + sig { returns(Prism::Node) } + def value; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2364 + sig { returns(T::Boolean) } + def variable_call?; end + + # attr_reader write_name: Symbol + # + # source://prism//lib/prism/node.rb#2346 + sig { returns(Symbol) } + def write_name; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#2310 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2422 + def type; end + end +end + +# Represents a method call, in all of the various forms that can take. +# +# foo +# ^^^ +# +# foo() +# ^^^^^ +# +# +foo +# ^^^^ +# +# foo + bar +# ^^^^^^^^^ +# +# foo.bar +# ^^^^^^^ +# +# foo&.bar +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#2460 +class Prism::CallNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Symbol name, Location? message_loc, Location? opening_loc, ArgumentsNode? arguments, Location? closing_loc, Prism::node? block, Location location) -> void + # + # @return [CallNode] a new instance of CallNode + # + # source://prism//lib/prism/node.rb#2462 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + name: Symbol, + message_loc: T.nilable(Prism::Location), + opening_loc: T.nilable(Prism::Location), + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: T.nilable(Prism::Location), + block: T.nilable(Prism::Node), + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, name, message_loc, opening_loc, arguments, closing_loc, block, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#2665 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#2477 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#2572 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2601 + sig { returns(T::Boolean) } + def attribute_write?; end + + # attr_reader block: Prism::node? + # + # source://prism//lib/prism/node.rb#2588 + sig { returns(T.nilable(Prism::Node)) } + def block; end + + # def call_operator: () -> String? + # + # source://prism//lib/prism/node.rb#2611 + sig { returns(T.nilable(String)) } + def call_operator; end + + # attr_reader call_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#2530 + sig { returns(T.nilable(Prism::Location)) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2482 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#2626 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#2575 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#2496 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#2487 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?name: Symbol, ?message_loc: Location?, ?opening_loc: Location?, ?arguments: ArgumentsNode?, ?closing_loc: Location?, ?block: Prism::node?, ?location: Location) -> CallNode + # + # source://prism//lib/prism/node.rb#2501 + sig do + params( + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + name: Symbol, + message_loc: T.nilable(Prism::Location), + opening_loc: T.nilable(Prism::Location), + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: T.nilable(Prism::Location), + block: T.nilable(Prism::Node), + location: Prism::Location + ).returns(Prism::CallNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), name: T.unsafe(nil), message_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2482 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, name: Symbol, message_loc: Location?, opening_loc: Location?, arguments: ArgumentsNode?, closing_loc: Location?, block: Prism::node?, location: Location } + # + # source://prism//lib/prism/node.rb#2509 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # When a call node has the attribute_write flag set, it means that the call + # is using the attribute write syntax. This is either a method call to []= + # or a method call to a method that ends with =. Either way, the = sign is + # present in the source. + # + # Prism returns the message_loc _without_ the = sign attached, because there + # can be any amount of space between the message and the = sign. However, + # sometimes you want the location of the full message including the inner + # space and the = sign. This method provides that. + # + # source://prism//lib/prism/node_ext.rb#315 + sig { returns(T.nilable(Prism::Location)) } + def full_message_loc; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2606 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#2631 + sig { override.returns(String) } + def inspect; end + + # def message: () -> String? + # + # source://prism//lib/prism/node.rb#2616 + sig { returns(T.nilable(String)) } + def message; end + + # attr_reader message_loc: Location? + # + # source://prism//lib/prism/node.rb#2546 + sig { returns(T.nilable(Prism::Location)) } + def message_loc; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#2543 + sig { returns(Symbol) } + def name; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#2621 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#2559 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # The object that the method is being called on. This can be either `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # foo.bar + # ^^^ + # + # +foo + # ^^^ + # + # foo + bar + # ^^^ + # + # source://prism//lib/prism/node.rb#2527 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2591 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2649 + sig { override.returns(Symbol) } + def type; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2596 + sig { returns(T::Boolean) } + def variable_call?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#2514 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2659 + def type; end + end +end + +# Flags for call nodes. +# +# source://prism//lib/prism/node.rb#19142 +module Prism::CallNodeFlags; end + +# a call that is an attribute write, so the value being written should be returned +# +# source://prism//lib/prism/node.rb#19150 +Prism::CallNodeFlags::ATTRIBUTE_WRITE = T.let(T.unsafe(nil), Integer) + +# a call that ignores method visibility +# +# source://prism//lib/prism/node.rb#19153 +Prism::CallNodeFlags::IGNORE_VISIBILITY = T.let(T.unsafe(nil), Integer) + +# &. operator +# +# source://prism//lib/prism/node.rb#19144 +Prism::CallNodeFlags::SAFE_NAVIGATION = T.let(T.unsafe(nil), Integer) + +# a call that could have been a local variable +# +# source://prism//lib/prism/node.rb#19147 +Prism::CallNodeFlags::VARIABLE_CALL = T.let(T.unsafe(nil), Integer) + +# Represents the use of an assignment operator on a call. +# +# foo.bar += baz +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#2683 +class Prism::CallOperatorWriteNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location? message_loc, Symbol read_name, Symbol write_name, Symbol binary_operator, Location binary_operator_loc, Prism::node value, Location location) -> void + # + # @return [CallOperatorWriteNode] a new instance of CallOperatorWriteNode + # + # source://prism//lib/prism/node.rb#2685 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + message_loc: T.nilable(Prism::Location), + read_name: Symbol, + write_name: Symbol, + binary_operator: Symbol, + binary_operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, message_loc, read_name, write_name, binary_operator, binary_operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#2852 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#2700 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2798 + sig { returns(T::Boolean) } + def attribute_write?; end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#2775 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#2778 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # def call_operator: () -> String? + # + # source://prism//lib/prism/node.rb#2808 + sig { returns(T.nilable(String)) } + def call_operator; end + + # attr_reader call_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#2743 + sig { returns(T.nilable(Prism::Location)) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2705 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#2718 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#2710 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?message_loc: Location?, ?read_name: Symbol, ?write_name: Symbol, ?binary_operator: Symbol, ?binary_operator_loc: Location, ?value: Prism::node, ?location: Location) -> CallOperatorWriteNode + # + # source://prism//lib/prism/node.rb#2723 + sig do + params( + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + message_loc: T.nilable(Prism::Location), + read_name: Symbol, + write_name: Symbol, + binary_operator: Symbol, + binary_operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::CallOperatorWriteNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), message_loc: T.unsafe(nil), read_name: T.unsafe(nil), write_name: T.unsafe(nil), binary_operator: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2705 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, message_loc: Location?, read_name: Symbol, write_name: Symbol, binary_operator: Symbol, binary_operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#2731 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2803 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#2818 + sig { override.returns(String) } + def inspect; end + + # def message: () -> String? + # + # source://prism//lib/prism/node.rb#2813 + sig { returns(T.nilable(String)) } + def message; end + + # attr_reader message_loc: Location? + # + # source://prism//lib/prism/node.rb#2756 + sig { returns(T.nilable(Prism::Location)) } + def message_loc; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#323 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#330 + def operator_loc; end + + # attr_reader read_name: Symbol + # + # source://prism//lib/prism/node.rb#2769 + sig { returns(Symbol) } + def read_name; end + + # attr_reader receiver: Prism::node? + # + # source://prism//lib/prism/node.rb#2740 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2788 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2836 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#2785 + sig { returns(Prism::Node) } + def value; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2793 + sig { returns(T::Boolean) } + def variable_call?; end + + # attr_reader write_name: Symbol + # + # source://prism//lib/prism/node.rb#2772 + sig { returns(Symbol) } + def write_name; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#2736 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#2846 + def type; end + end +end + +# Represents the use of the `||=` operator on a call. +# +# foo.bar ||= value +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#2870 +class Prism::CallOrWriteNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location? message_loc, Symbol read_name, Symbol write_name, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [CallOrWriteNode] a new instance of CallOrWriteNode + # + # source://prism//lib/prism/node.rb#2872 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + message_loc: T.nilable(Prism::Location), + read_name: Symbol, + write_name: Symbol, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3040 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#2886 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2981 + sig { returns(T::Boolean) } + def attribute_write?; end + + # def call_operator: () -> String? + # + # source://prism//lib/prism/node.rb#2991 + sig { returns(T.nilable(String)) } + def call_operator; end + + # attr_reader call_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#2929 + sig { returns(T.nilable(Prism::Location)) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2891 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#2904 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#2896 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?message_loc: Location?, ?read_name: Symbol, ?write_name: Symbol, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> CallOrWriteNode + # + # source://prism//lib/prism/node.rb#2909 + sig do + params( + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + message_loc: T.nilable(Prism::Location), + read_name: Symbol, + write_name: Symbol, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::CallOrWriteNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), message_loc: T.unsafe(nil), read_name: T.unsafe(nil), write_name: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#2891 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, message_loc: Location?, read_name: Symbol, write_name: Symbol, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#2917 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2986 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3006 + sig { override.returns(String) } + def inspect; end + + # def message: () -> String? + # + # source://prism//lib/prism/node.rb#2996 + sig { returns(T.nilable(String)) } + def message; end + + # attr_reader message_loc: Location? + # + # source://prism//lib/prism/node.rb#2942 + sig { returns(T.nilable(Prism::Location)) } + def message_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#3001 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#2961 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader read_name: Symbol + # + # source://prism//lib/prism/node.rb#2955 + sig { returns(Symbol) } + def read_name; end + + # attr_reader receiver: Prism::node? + # + # source://prism//lib/prism/node.rb#2926 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2971 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3024 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#2968 + sig { returns(Prism::Node) } + def value; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#2976 + sig { returns(T::Boolean) } + def variable_call?; end + + # attr_reader write_name: Symbol + # + # source://prism//lib/prism/node.rb#2958 + sig { returns(Symbol) } + def write_name; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#2922 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3034 + def type; end + end +end + +# Represents assigning to a method call. +# +# foo.bar, = 1 +# ^^^^^^^ +# +# begin +# rescue => foo.bar +# ^^^^^^^ +# end +# +# for foo.bar in baz do end +# ^^^^^^^ +# +# source://prism//lib/prism/node.rb#3065 +class Prism::CallTargetNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node receiver, Location call_operator_loc, Symbol name, Location message_loc, Location location) -> void + # + # @return [CallTargetNode] a new instance of CallTargetNode + # + # source://prism//lib/prism/node.rb#3067 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: Prism::Node, + call_operator_loc: Prism::Location, + name: Symbol, + message_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, name, message_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3199 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3078 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#3145 + sig { returns(T::Boolean) } + def attribute_write?; end + + # def call_operator: () -> String + # + # source://prism//lib/prism/node.rb#3155 + sig { returns(String) } + def call_operator; end + + # attr_reader call_operator_loc: Location + # + # source://prism//lib/prism/node.rb#3118 + sig { returns(Prism::Location) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3083 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#3093 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#3088 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node, ?call_operator_loc: Location, ?name: Symbol, ?message_loc: Location, ?location: Location) -> CallTargetNode + # + # source://prism//lib/prism/node.rb#3098 + sig do + params( + flags: Integer, + receiver: Prism::Node, + call_operator_loc: Prism::Location, + name: Symbol, + message_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::CallTargetNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), name: T.unsafe(nil), message_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3083 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node, call_operator_loc: Location, name: Symbol, message_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#3106 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#3150 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3165 + sig { override.returns(String) } + def inspect; end + + # def message: () -> String + # + # source://prism//lib/prism/node.rb#3160 + sig { returns(String) } + def message; end + + # attr_reader message_loc: Location + # + # source://prism//lib/prism/node.rb#3128 + sig { returns(Prism::Location) } + def message_loc; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#3125 + sig { returns(Symbol) } + def name; end + + # attr_reader receiver: Prism::node + # + # source://prism//lib/prism/node.rb#3115 + sig { returns(Prism::Node) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#3135 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3183 + sig { override.returns(Symbol) } + def type; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#3140 + sig { returns(T::Boolean) } + def variable_call?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#3111 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3193 + def type; end + end +end + +# Represents assigning to a local variable in pattern matching. +# +# foo => [bar => baz] +# ^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#3213 +class Prism::CapturePatternNode < ::Prism::Node + # def initialize: (Prism::node value, Prism::node target, Location operator_loc, Location location) -> void + # + # @return [CapturePatternNode] a new instance of CapturePatternNode + # + # source://prism//lib/prism/node.rb#3215 + sig do + params( + source: Prism::Source, + value: Prism::Node, + target: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, value, target, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3309 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3224 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3229 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#3239 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#3234 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?value: Prism::node, ?target: Prism::node, ?operator_loc: Location, ?location: Location) -> CapturePatternNode + # + # source://prism//lib/prism/node.rb#3244 + sig do + params( + value: Prism::Node, + target: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::CapturePatternNode) + end + def copy(value: T.unsafe(nil), target: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3229 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, target: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#3252 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3275 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#3270 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#3263 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader target: Prism::node + # + # source://prism//lib/prism/node.rb#3260 + sig { returns(Prism::Node) } + def target; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3293 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#3257 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3303 + def type; end + end +end + +# Represents the use of a case statement for pattern matching. +# +# case true +# in false +# end +# ^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#3323 +class Prism::CaseMatchNode < ::Prism::Node + # def initialize: (Prism::node? predicate, Array[Prism::node] conditions, ElseNode? consequent, Location case_keyword_loc, Location end_keyword_loc, Location location) -> void + # + # @return [CaseMatchNode] a new instance of CaseMatchNode + # + # source://prism//lib/prism/node.rb#3325 + sig do + params( + source: Prism::Source, + predicate: T.nilable(Prism::Node), + conditions: T::Array[Prism::Node], + consequent: T.nilable(Prism::ElseNode), + case_keyword_loc: Prism::Location, + end_keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3440 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3336 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def case_keyword: () -> String + # + # source://prism//lib/prism/node.rb#3396 + sig { returns(String) } + def case_keyword; end + + # attr_reader case_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#3382 + sig { returns(Prism::Location) } + def case_keyword_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3341 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#3355 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#3346 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader conditions: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#3376 + sig { returns(T::Array[Prism::Node]) } + def conditions; end + + # attr_reader consequent: ElseNode? + # + # source://prism//lib/prism/node.rb#3379 + sig { returns(T.nilable(Prism::ElseNode)) } + def consequent; end + + # def copy: (?predicate: Prism::node?, ?conditions: Array[Prism::node], ?consequent: ElseNode?, ?case_keyword_loc: Location, ?end_keyword_loc: Location, ?location: Location) -> CaseMatchNode + # + # source://prism//lib/prism/node.rb#3360 + sig do + params( + predicate: T.nilable(Prism::Node), + conditions: T::Array[Prism::Node], + consequent: T.nilable(Prism::ElseNode), + case_keyword_loc: Prism::Location, + end_keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::CaseMatchNode) + end + def copy(predicate: T.unsafe(nil), conditions: T.unsafe(nil), consequent: T.unsafe(nil), case_keyword_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3341 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { predicate: Prism::node?, conditions: Array[Prism::node], consequent: ElseNode?, case_keyword_loc: Location, end_keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#3368 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String + # + # source://prism//lib/prism/node.rb#3401 + sig { returns(String) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#3389 + sig { returns(Prism::Location) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3406 + sig { override.returns(String) } + def inspect; end + + # attr_reader predicate: Prism::node? + # + # source://prism//lib/prism/node.rb#3373 + sig { returns(T.nilable(Prism::Node)) } + def predicate; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3424 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3434 + def type; end + end +end + +# Represents the use of a case statement. +# +# case true +# when false +# end +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#3457 +class Prism::CaseNode < ::Prism::Node + # def initialize: (Prism::node? predicate, Array[Prism::node] conditions, ElseNode? consequent, Location case_keyword_loc, Location end_keyword_loc, Location location) -> void + # + # @return [CaseNode] a new instance of CaseNode + # + # source://prism//lib/prism/node.rb#3459 + sig do + params( + source: Prism::Source, + predicate: T.nilable(Prism::Node), + conditions: T::Array[Prism::Node], + consequent: T.nilable(Prism::ElseNode), + case_keyword_loc: Prism::Location, + end_keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3574 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3470 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def case_keyword: () -> String + # + # source://prism//lib/prism/node.rb#3530 + sig { returns(String) } + def case_keyword; end + + # attr_reader case_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#3516 + sig { returns(Prism::Location) } + def case_keyword_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3475 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#3489 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#3480 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader conditions: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#3510 + sig { returns(T::Array[Prism::Node]) } + def conditions; end + + # attr_reader consequent: ElseNode? + # + # source://prism//lib/prism/node.rb#3513 + sig { returns(T.nilable(Prism::ElseNode)) } + def consequent; end + + # def copy: (?predicate: Prism::node?, ?conditions: Array[Prism::node], ?consequent: ElseNode?, ?case_keyword_loc: Location, ?end_keyword_loc: Location, ?location: Location) -> CaseNode + # + # source://prism//lib/prism/node.rb#3494 + sig do + params( + predicate: T.nilable(Prism::Node), + conditions: T::Array[Prism::Node], + consequent: T.nilable(Prism::ElseNode), + case_keyword_loc: Prism::Location, + end_keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::CaseNode) + end + def copy(predicate: T.unsafe(nil), conditions: T.unsafe(nil), consequent: T.unsafe(nil), case_keyword_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3475 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { predicate: Prism::node?, conditions: Array[Prism::node], consequent: ElseNode?, case_keyword_loc: Location, end_keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#3502 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String + # + # source://prism//lib/prism/node.rb#3535 + sig { returns(String) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#3523 + sig { returns(Prism::Location) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3540 + sig { override.returns(String) } + def inspect; end + + # attr_reader predicate: Prism::node? + # + # source://prism//lib/prism/node.rb#3507 + sig { returns(T.nilable(Prism::Node)) } + def predicate; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3558 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3568 + def type; end + end +end + +# Represents a class declaration involving the `class` keyword. +# +# class Foo end +# ^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#3589 +class Prism::ClassNode < ::Prism::Node + # def initialize: (Array[Symbol] locals, Location class_keyword_loc, Prism::node constant_path, Location? inheritance_operator_loc, Prism::node? superclass, Prism::node? body, Location end_keyword_loc, Symbol name, Location location) -> void + # + # @return [ClassNode] a new instance of ClassNode + # + # source://prism//lib/prism/node.rb#3591 + sig do + params( + source: Prism::Source, + locals: T::Array[Symbol], + class_keyword_loc: Prism::Location, + constant_path: Prism::Node, + inheritance_operator_loc: T.nilable(Prism::Location), + superclass: T.nilable(Prism::Node), + body: T.nilable(Prism::Node), + end_keyword_loc: Prism::Location, + name: Symbol, + location: Prism::Location + ).void + end + def initialize(source, locals, class_keyword_loc, constant_path, inheritance_operator_loc, superclass, body, end_keyword_loc, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3733 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3605 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Prism::node? + # + # source://prism//lib/prism/node.rb#3671 + sig { returns(T.nilable(Prism::Node)) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3610 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def class_keyword: () -> String + # + # source://prism//lib/prism/node.rb#3684 + sig { returns(String) } + def class_keyword; end + + # attr_reader class_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#3645 + sig { returns(Prism::Location) } + def class_keyword_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#3624 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#3615 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader constant_path: Prism::node + # + # source://prism//lib/prism/node.rb#3652 + sig { returns(Prism::Node) } + def constant_path; end + + # def copy: (?locals: Array[Symbol], ?class_keyword_loc: Location, ?constant_path: Prism::node, ?inheritance_operator_loc: Location?, ?superclass: Prism::node?, ?body: Prism::node?, ?end_keyword_loc: Location, ?name: Symbol, ?location: Location) -> ClassNode + # + # source://prism//lib/prism/node.rb#3629 + sig do + params( + locals: T::Array[Symbol], + class_keyword_loc: Prism::Location, + constant_path: Prism::Node, + inheritance_operator_loc: T.nilable(Prism::Location), + superclass: T.nilable(Prism::Node), + body: T.nilable(Prism::Node), + end_keyword_loc: Prism::Location, + name: Symbol, + location: Prism::Location + ).returns(Prism::ClassNode) + end + def copy(locals: T.unsafe(nil), class_keyword_loc: T.unsafe(nil), constant_path: T.unsafe(nil), inheritance_operator_loc: T.unsafe(nil), superclass: T.unsafe(nil), body: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3610 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], class_keyword_loc: Location, constant_path: Prism::node, inheritance_operator_loc: Location?, superclass: Prism::node?, body: Prism::node?, end_keyword_loc: Location, name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#3637 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String + # + # source://prism//lib/prism/node.rb#3694 + sig { returns(String) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#3674 + sig { returns(Prism::Location) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inheritance_operator: () -> String? + # + # source://prism//lib/prism/node.rb#3689 + sig { returns(T.nilable(String)) } + def inheritance_operator; end + + # attr_reader inheritance_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#3655 + sig { returns(T.nilable(Prism::Location)) } + def inheritance_operator_loc; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3699 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[Symbol] + # + # source://prism//lib/prism/node.rb#3642 + sig { returns(T::Array[Symbol]) } + def locals; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#3681 + sig { returns(Symbol) } + def name; end + + # attr_reader superclass: Prism::node? + # + # source://prism//lib/prism/node.rb#3668 + sig { returns(T.nilable(Prism::Node)) } + def superclass; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3717 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3727 + def type; end + end +end + +# Represents the use of the `&&=` operator for assignment to a class variable. +# +# @@target &&= value +# ^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#3751 +class Prism::ClassVariableAndWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [ClassVariableAndWriteNode] a new instance of ClassVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#3753 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3855 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3763 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3768 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#3778 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#3773 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ClassVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#3783 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::ClassVariableAndWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3768 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#3791 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#127 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3821 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#3796 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#3799 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#3816 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#3806 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3839 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#3813 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3849 + def type; end + end +end + +# Represents assigning to a class variable using an operator that isn't `=`. +# +# @@target += value +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#3868 +class Prism::ClassVariableOperatorWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void + # + # @return [ClassVariableOperatorWriteNode] a new instance of ClassVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#3870 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#3971 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3881 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#3934 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#3924 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3886 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#3896 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#3891 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> ClassVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#3901 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).returns(Prism::ClassVariableOperatorWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#3886 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#3909 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#139 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#3937 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#3914 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#3917 + sig { returns(Prism::Location) } + def name_loc; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#339 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#346 + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3955 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#3931 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#3965 + def type; end + end +end + +# Represents the use of the `||=` operator for assignment to a class variable. +# +# @@target ||= value +# ^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#3985 +class Prism::ClassVariableOrWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [ClassVariableOrWriteNode] a new instance of ClassVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#3987 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4089 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#3997 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4002 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4012 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4007 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ClassVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#4017 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::ClassVariableOrWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4002 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#4025 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#133 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4055 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#4030 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#4033 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#4050 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#4040 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4073 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#4047 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4083 + def type; end + end +end + +# Represents referencing a class variable. +# +# @@foo +# ^^^^^ +# +# source://prism//lib/prism/node.rb#4102 +class Prism::ClassVariableReadNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [ClassVariableReadNode] a new instance of ClassVariableReadNode + # + # source://prism//lib/prism/node.rb#4104 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4185 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4111 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4116 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4126 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4121 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> ClassVariableReadNode + # + # source://prism//lib/prism/node.rb#4131 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::ClassVariableReadNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4116 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#4139 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4151 + sig { override.returns(String) } + def inspect; end + + # The name of the class variable, which is a `@@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers). + # + # @@abc # name `:@@abc` + # + # @@_test # name `:@@_test` + # + # source://prism//lib/prism/node.rb#4148 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4169 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4179 + def type; end + end +end + +# Represents writing to a class variable in a context that doesn't have an explicit value. +# +# @@foo, @@bar = baz +# ^^^^^ ^^^^^ +# +# source://prism//lib/prism/node.rb#4195 +class Prism::ClassVariableTargetNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [ClassVariableTargetNode] a new instance of ClassVariableTargetNode + # + # source://prism//lib/prism/node.rb#4197 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4274 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4204 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4209 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4219 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4214 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> ClassVariableTargetNode + # + # source://prism//lib/prism/node.rb#4224 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::ClassVariableTargetNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4209 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#4232 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4240 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#4237 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4258 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4268 + def type; end + end +end + +# Represents writing to a class variable. +# +# @@foo = 1 +# ^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#4284 +class Prism::ClassVariableWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void + # + # @return [ClassVariableWriteNode] a new instance of ClassVariableWriteNode + # + # source://prism//lib/prism/node.rb#4286 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, value, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4404 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4296 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4301 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4311 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4306 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> ClassVariableWriteNode + # + # source://prism//lib/prism/node.rb#4316 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::ClassVariableWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4301 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#4324 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4370 + sig { override.returns(String) } + def inspect; end + + # The name of the class variable, which is a `@@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers). + # + # @@abc = 123 # name `@@abc` + # + # @@_test = :test # name `@@_test` + # + # source://prism//lib/prism/node.rb#4333 + sig { returns(Symbol) } + def name; end + + # The location of the variable name. + # + # @@foo = :bar + # ^^^^^ + # + # source://prism//lib/prism/node.rb#4339 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#4365 + sig { returns(String) } + def operator; end + + # The location of the `=` operator. + # + # @@foo = :bar + # ^ + # + # source://prism//lib/prism/node.rb#4358 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4388 + sig { override.returns(Symbol) } + def type; end + + # The value to write to the class variable. This can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # @@foo = :bar + # ^^^^ + # + # @@_xyz = 123 + # ^^^ + # + # source://prism//lib/prism/node.rb#4352 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4398 + def type; end + end +end + +# This represents a comment that was encountered during parsing. It is the +# base class for all comment types. +# +# source://prism//lib/prism/parse_result.rb#366 +class Prism::Comment + abstract! + + # Create a new comment object with the given location. + # + # @return [Comment] a new instance of Comment + # + # source://prism//lib/prism/parse_result.rb#371 + sig { params(location: Prism::Location).void } + def initialize(location); end + + # Implement the hash pattern matching interface for Comment. + # + # source://prism//lib/prism/parse_result.rb#376 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # The location of this comment in the source. + # + # source://prism//lib/prism/parse_result.rb#368 + sig { returns(Prism::Location) } + def location; end + + # Returns the content of the comment by slicing it from the source code. + # + # source://prism//lib/prism/parse_result.rb#381 + sig { returns(String) } + def slice; end + + sig { abstract.returns(T::Boolean) } + def trailing?; end +end + +# A compiler is a visitor that returns the value of each node as it visits. +# This is as opposed to a visitor which will only walk the tree. This can be +# useful when you are trying to compile a tree into a different format. +# +# For example, to build a representation of the tree as s-expressions, you +# could write: +# +# class SExpressions < Prism::Compiler +# def visit_arguments_node(node) = [:arguments, super] +# def visit_call_node(node) = [:call, super] +# def visit_integer_node(node) = [:integer] +# def visit_program_node(node) = [:program, super] +# end +# +# Prism.parse("1 + 2").value.accept(SExpressions.new) +# # => [:program, [[[:call, [[:integer], [:arguments, [[:integer]]]]]]]] +# +# source://prism//lib/prism/compiler.rb#27 +class Prism::Compiler < ::Prism::Visitor + # Visit an individual node. + # + # source://prism//lib/prism/compiler.rb#29 + sig { params(node: T.nilable(Prism::Node)).returns(T.untyped) } + def visit(node); end + + # Visit the child nodes of the given node. + # Compile a AliasGlobalVariableNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_alias_global_variable_node(node); end + + # Visit the child nodes of the given node. + # Compile a AliasMethodNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_alias_method_node(node); end + + # Visit a list of nodes. + # + # source://prism//lib/prism/compiler.rb#34 + sig { params(nodes: T::Array[T.nilable(Prism::Node)]).returns(T::Array[T.untyped]) } + def visit_all(nodes); end + + # Visit the child nodes of the given node. + # Compile a AlternationPatternNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_alternation_pattern_node(node); end + + # Visit the child nodes of the given node. + # Compile a AndNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_and_node(node); end + + # Visit the child nodes of the given node. + # Compile a ArgumentsNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_arguments_node(node); end + + # Visit the child nodes of the given node. + # Compile a ArrayNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_array_node(node); end + + # Visit the child nodes of the given node. + # Compile a ArrayPatternNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_array_pattern_node(node); end + + # Visit the child nodes of the given node. + # Compile a AssocNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_assoc_node(node); end + + # Visit the child nodes of the given node. + # Compile a AssocSplatNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_assoc_splat_node(node); end + + # Visit the child nodes of the given node. + # Compile a BackReferenceReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_back_reference_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a BeginNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_begin_node(node); end + + # Visit the child nodes of the given node. + # Compile a BlockArgumentNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_block_argument_node(node); end + + # Visit the child nodes of the given node. + # Compile a BlockLocalVariableNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_block_local_variable_node(node); end + + # Visit the child nodes of the given node. + # Compile a BlockNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_block_node(node); end + + # Visit the child nodes of the given node. + # Compile a BlockParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_block_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a BlockParametersNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_block_parameters_node(node); end + + # Visit the child nodes of the given node. + # Compile a BreakNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_break_node(node); end + + # Visit the child nodes of the given node. + # Compile a CallAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_call_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a CallNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_call_node(node); end + + # Visit the child nodes of the given node. + # Compile a CallOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_call_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a CallOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_call_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a CallTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_call_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a CapturePatternNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_capture_pattern_node(node); end + + # Visit the child nodes of the given node. + # Compile a CaseMatchNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_case_match_node(node); end + + # Visit the child nodes of the given node. + # Compile a CaseNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_case_node(node); end + + # Visit the child nodes of the given node. + # + # source://prism//lib/prism/compiler.rb#39 + sig { params(node: Prism::Node).returns(T::Array[T.untyped]) } + def visit_child_nodes(node); end + + # Visit the child nodes of the given node. + # Compile a ClassNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_class_node(node); end + + # Visit the child nodes of the given node. + # Compile a ClassVariableAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_class_variable_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ClassVariableOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_class_variable_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ClassVariableOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_class_variable_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ClassVariableReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_class_variable_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a ClassVariableTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_class_variable_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a ClassVariableWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_class_variable_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantPathAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_path_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantPathNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_path_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantPathOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_path_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantPathOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_path_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantPathTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_path_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantPathWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_path_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a ConstantWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_constant_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a DefNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_def_node(node); end + + # Visit the child nodes of the given node. + # Compile a DefinedNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_defined_node(node); end + + # Visit the child nodes of the given node. + # Compile a ElseNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_else_node(node); end + + # Visit the child nodes of the given node. + # Compile a EmbeddedStatementsNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_embedded_statements_node(node); end + + # Visit the child nodes of the given node. + # Compile a EmbeddedVariableNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_embedded_variable_node(node); end + + # Visit the child nodes of the given node. + # Compile a EnsureNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_ensure_node(node); end + + # Visit the child nodes of the given node. + # Compile a FalseNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_false_node(node); end + + # Visit the child nodes of the given node. + # Compile a FindPatternNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_find_pattern_node(node); end + + # Visit the child nodes of the given node. + # Compile a FlipFlopNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_flip_flop_node(node); end + + # Visit the child nodes of the given node. + # Compile a FloatNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_float_node(node); end + + # Visit the child nodes of the given node. + # Compile a ForNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_for_node(node); end + + # Visit the child nodes of the given node. + # Compile a ForwardingArgumentsNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_forwarding_arguments_node(node); end + + # Visit the child nodes of the given node. + # Compile a ForwardingParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_forwarding_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a ForwardingSuperNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_forwarding_super_node(node); end + + # Visit the child nodes of the given node. + # Compile a GlobalVariableAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_global_variable_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a GlobalVariableOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_global_variable_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a GlobalVariableOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_global_variable_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a GlobalVariableReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_global_variable_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a GlobalVariableTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_global_variable_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a GlobalVariableWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_global_variable_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a HashNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_hash_node(node); end + + # Visit the child nodes of the given node. + # Compile a HashPatternNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_hash_pattern_node(node); end + + # Visit the child nodes of the given node. + # Compile a IfNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_if_node(node); end + + # Visit the child nodes of the given node. + # Compile a ImaginaryNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_imaginary_node(node); end + + # Visit the child nodes of the given node. + # Compile a ImplicitNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_implicit_node(node); end + + # Visit the child nodes of the given node. + # Compile a ImplicitRestNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_implicit_rest_node(node); end + + # Visit the child nodes of the given node. + # Compile a InNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_in_node(node); end + + # Visit the child nodes of the given node. + # Compile a IndexAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_index_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a IndexOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_index_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a IndexOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_index_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a IndexTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_index_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a InstanceVariableAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_instance_variable_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a InstanceVariableOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_instance_variable_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a InstanceVariableOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_instance_variable_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a InstanceVariableReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_instance_variable_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a InstanceVariableTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_instance_variable_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a InstanceVariableWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_instance_variable_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a IntegerNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_integer_node(node); end + + # Visit the child nodes of the given node. + # Compile a InterpolatedMatchLastLineNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_interpolated_match_last_line_node(node); end + + # Visit the child nodes of the given node. + # Compile a InterpolatedRegularExpressionNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_interpolated_regular_expression_node(node); end + + # Visit the child nodes of the given node. + # Compile a InterpolatedStringNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_interpolated_string_node(node); end + + # Visit the child nodes of the given node. + # Compile a InterpolatedSymbolNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_interpolated_symbol_node(node); end + + # Visit the child nodes of the given node. + # Compile a InterpolatedXStringNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_interpolated_x_string_node(node); end + + # Visit the child nodes of the given node. + # Compile a ItLocalVariableReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_it_local_variable_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a ItParametersNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_it_parameters_node(node); end + + # Visit the child nodes of the given node. + # Compile a KeywordHashNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_keyword_hash_node(node); end + + # Visit the child nodes of the given node. + # Compile a KeywordRestParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_keyword_rest_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a LambdaNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_lambda_node(node); end + + # Visit the child nodes of the given node. + # Compile a LocalVariableAndWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_local_variable_and_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a LocalVariableOperatorWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_local_variable_operator_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a LocalVariableOrWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_local_variable_or_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a LocalVariableReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_local_variable_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a LocalVariableTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_local_variable_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a LocalVariableWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_local_variable_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a MatchLastLineNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_match_last_line_node(node); end + + # Visit the child nodes of the given node. + # Compile a MatchPredicateNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_match_predicate_node(node); end + + # Visit the child nodes of the given node. + # Compile a MatchRequiredNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_match_required_node(node); end + + # Visit the child nodes of the given node. + # Compile a MatchWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_match_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a MissingNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_missing_node(node); end + + # Visit the child nodes of the given node. + # Compile a ModuleNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_module_node(node); end + + # Visit the child nodes of the given node. + # Compile a MultiTargetNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_multi_target_node(node); end + + # Visit the child nodes of the given node. + # Compile a MultiWriteNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_multi_write_node(node); end + + # Visit the child nodes of the given node. + # Compile a NextNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_next_node(node); end + + # Visit the child nodes of the given node. + # Compile a NilNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_nil_node(node); end + + # Visit the child nodes of the given node. + # Compile a NoKeywordsParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_no_keywords_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a NumberedParametersNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_numbered_parameters_node(node); end + + # Visit the child nodes of the given node. + # Compile a NumberedReferenceReadNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_numbered_reference_read_node(node); end + + # Visit the child nodes of the given node. + # Compile a OptionalKeywordParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_optional_keyword_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a OptionalParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_optional_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a OrNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_or_node(node); end + + # Visit the child nodes of the given node. + # Compile a ParametersNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_parameters_node(node); end + + # Visit the child nodes of the given node. + # Compile a ParenthesesNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_parentheses_node(node); end + + # Visit the child nodes of the given node. + # Compile a PinnedExpressionNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_pinned_expression_node(node); end + + # Visit the child nodes of the given node. + # Compile a PinnedVariableNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_pinned_variable_node(node); end + + # Visit the child nodes of the given node. + # Compile a PostExecutionNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_post_execution_node(node); end + + # Visit the child nodes of the given node. + # Compile a PreExecutionNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_pre_execution_node(node); end + + # Visit the child nodes of the given node. + # Compile a ProgramNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_program_node(node); end + + # Visit the child nodes of the given node. + # Compile a RangeNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_range_node(node); end + + # Visit the child nodes of the given node. + # Compile a RationalNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_rational_node(node); end + + # Visit the child nodes of the given node. + # Compile a RedoNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_redo_node(node); end + + # Visit the child nodes of the given node. + # Compile a RegularExpressionNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_regular_expression_node(node); end + + # Visit the child nodes of the given node. + # Compile a RequiredKeywordParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_required_keyword_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a RequiredParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_required_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a RescueModifierNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_rescue_modifier_node(node); end + + # Visit the child nodes of the given node. + # Compile a RescueNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_rescue_node(node); end + + # Visit the child nodes of the given node. + # Compile a RestParameterNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_rest_parameter_node(node); end + + # Visit the child nodes of the given node. + # Compile a RetryNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_retry_node(node); end + + # Visit the child nodes of the given node. + # Compile a ReturnNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_return_node(node); end + + # Visit the child nodes of the given node. + # Compile a SelfNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_self_node(node); end + + # Visit the child nodes of the given node. + # Compile a ShareableConstantNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_shareable_constant_node(node); end + + # Visit the child nodes of the given node. + # Compile a SingletonClassNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_singleton_class_node(node); end + + # Visit the child nodes of the given node. + # Compile a SourceEncodingNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_source_encoding_node(node); end + + # Visit the child nodes of the given node. + # Compile a SourceFileNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_source_file_node(node); end + + # Visit the child nodes of the given node. + # Compile a SourceLineNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_source_line_node(node); end + + # Visit the child nodes of the given node. + # Compile a SplatNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_splat_node(node); end + + # Visit the child nodes of the given node. + # Compile a StatementsNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_statements_node(node); end + + # Visit the child nodes of the given node. + # Compile a StringNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_string_node(node); end + + # Visit the child nodes of the given node. + # Compile a SuperNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_super_node(node); end + + # Visit the child nodes of the given node. + # Compile a SymbolNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_symbol_node(node); end + + # Visit the child nodes of the given node. + # Compile a TrueNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_true_node(node); end + + # Visit the child nodes of the given node. + # Compile a UndefNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_undef_node(node); end + + # Visit the child nodes of the given node. + # Compile a UnlessNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_unless_node(node); end + + # Visit the child nodes of the given node. + # Compile a UntilNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_until_node(node); end + + # Visit the child nodes of the given node. + # Compile a WhenNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_when_node(node); end + + # Visit the child nodes of the given node. + # Compile a WhileNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_while_node(node); end + + # Visit the child nodes of the given node. + # Compile a XStringNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_x_string_node(node); end + + # Visit the child nodes of the given node. + # Compile a YieldNode node + # + # source://prism//lib/prism/compiler.rb#39 + def visit_yield_node(node); end +end + +# Represents the use of the `&&=` operator for assignment to a constant. +# +# Target &&= value +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#4417 +class Prism::ConstantAndWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [ConstantAndWriteNode] a new instance of ConstantAndWriteNode + # + # source://prism//lib/prism/node.rb#4419 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4521 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4429 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4434 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4444 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4439 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantAndWriteNode + # + # source://prism//lib/prism/node.rb#4449 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::ConstantAndWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4434 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#4457 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#145 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4487 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#4462 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#4465 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#4482 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#4472 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4505 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#4479 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4515 + def type; end + end +end + +# Represents assigning to a constant using an operator that isn't `=`. +# +# Target += value +# ^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#4534 +class Prism::ConstantOperatorWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void + # + # @return [ConstantOperatorWriteNode] a new instance of ConstantOperatorWriteNode + # + # source://prism//lib/prism/node.rb#4536 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4637 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4547 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#4600 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#4590 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4552 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4562 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4557 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> ConstantOperatorWriteNode + # + # source://prism//lib/prism/node.rb#4567 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).returns(Prism::ConstantOperatorWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4552 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#4575 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#157 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4603 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#4580 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#4583 + sig { returns(Prism::Location) } + def name_loc; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#355 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#362 + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4621 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#4597 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4631 + def type; end + end +end + +# Represents the use of the `||=` operator for assignment to a constant. +# +# Target ||= value +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#4651 +class Prism::ConstantOrWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [ConstantOrWriteNode] a new instance of ConstantOrWriteNode + # + # source://prism//lib/prism/node.rb#4653 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4755 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4663 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4668 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4678 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4673 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantOrWriteNode + # + # source://prism//lib/prism/node.rb#4683 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::ConstantOrWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4668 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#4691 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#151 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4721 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#4696 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#4699 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#4716 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#4706 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4739 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#4713 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4749 + def type; end + end +end + +# Represents the use of the `&&=` operator for assignment to a constant path. +# +# Parent::Child &&= value +# ^^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#4768 +class Prism::ConstantPathAndWriteNode < ::Prism::Node + # def initialize: (ConstantPathNode target, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [ConstantPathAndWriteNode] a new instance of ConstantPathAndWriteNode + # + # source://prism//lib/prism/node.rb#4770 + sig do + params( + source: Prism::Source, + target: Prism::ConstantPathNode, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, target, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#4864 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4779 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4784 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4794 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4789 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?target: ConstantPathNode, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantPathAndWriteNode + # + # source://prism//lib/prism/node.rb#4799 + sig do + params( + target: Prism::ConstantPathNode, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::ConstantPathAndWriteNode) + end + def copy(target: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4784 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#4807 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4830 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#4825 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#4815 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader target: ConstantPathNode + # + # source://prism//lib/prism/node.rb#4812 + sig { returns(Prism::ConstantPathNode) } + def target; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4848 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#4822 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4858 + def type; end + end +end + +# Represents accessing a constant through a path of `::` operators. +# +# Foo::Bar +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#4876 +class Prism::ConstantPathNode < ::Prism::Node + # def initialize: (Prism::node? parent, Symbol? name, Location delimiter_loc, Location name_loc, Location location) -> void + # + # @return [ConstantPathNode] a new instance of ConstantPathNode + # + # source://prism//lib/prism/node.rb#4878 + sig do + params( + source: Prism::Source, + parent: T.nilable(Prism::Node), + name: T.nilable(Symbol), + delimiter_loc: Prism::Location, + name_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, parent, name, delimiter_loc, name_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5003 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#4888 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # Previously, we had a child node on this class that contained either a + # constant read or a missing node. To not cause a breaking change, we + # continue to supply that API. + # + # source://prism//lib/prism/node_ext.rb#196 + def child; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4893 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#4905 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#4898 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?parent: Prism::node?, ?name: Symbol?, ?delimiter_loc: Location, ?name_loc: Location, ?location: Location) -> ConstantPathNode + # + # source://prism//lib/prism/node.rb#4910 + sig do + params( + parent: T.nilable(Prism::Node), + name: T.nilable(Symbol), + delimiter_loc: Prism::Location, + name_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::ConstantPathNode) + end + def copy(parent: T.unsafe(nil), name: T.unsafe(nil), delimiter_loc: T.unsafe(nil), name_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#4893 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { parent: Prism::node?, name: Symbol?, delimiter_loc: Location, name_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#4918 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def delimiter: () -> String + # + # source://prism//lib/prism/node.rb#4964 + sig { returns(String) } + def delimiter; end + + # The location of the `::` delimiter. + # + # ::Foo + # ^^ + # + # One::Two + # ^^ + # + # source://prism//lib/prism/node.rb#4944 + sig { returns(Prism::Location) } + def delimiter_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # Returns the full name of this constant path. For example: "Foo::Bar" + # + # source://prism//lib/prism/node_ext.rb#189 + sig { returns(String) } + def full_name; end + + # Returns the list of parts for the full name of this constant path. + # For example: [:Foo, :Bar] + # + # source://prism//lib/prism/node_ext.rb#167 + sig { returns(T::Array[Symbol]) } + def full_name_parts; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#4969 + sig { override.returns(String) } + def inspect; end + + # The name of the constant being accessed. This could be `nil` in the event of a syntax error. + # + # source://prism//lib/prism/node.rb#4935 + sig { returns(T.nilable(Symbol)) } + def name; end + + # The location of the name of the constant. + # + # ::Foo + # ^^^ + # + # One::Two + # ^^^ + # + # source://prism//lib/prism/node.rb#4957 + sig { returns(Prism::Location) } + def name_loc; end + + # The left-hand node of the path, if present. It can be `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). It will be `nil` when the constant lookup is at the root of the module tree. + # + # Foo::Bar + # ^^^ + # + # self::Test + # ^^^^ + # + # a.b::C + # ^^^ + # + # source://prism//lib/prism/node.rb#4932 + sig { returns(T.nilable(Prism::Node)) } + def parent; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4987 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#4997 + def type; end + end +end + +# An error class raised when dynamic parts are found while computing a +# constant path's full name. For example: +# Foo::Bar::Baz -> does not raise because all parts of the constant path are +# simple constants +# var::Bar::Baz -> raises because the first part of the constant path is a +# local variable +# +# source://prism//lib/prism/node_ext.rb#158 +class Prism::ConstantPathNode::DynamicPartsInConstantPathError < ::StandardError; end + +# An error class raised when missing nodes are found while computing a +# constant path's full name. For example: +# Foo:: -> raises because the constant path is missing the last part +# +# source://prism//lib/prism/node_ext.rb#163 +class Prism::ConstantPathNode::MissingNodesInConstantPathError < ::StandardError; end + +# Represents assigning to a constant path using an operator that isn't `=`. +# +# Parent::Child += value +# ^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#5016 +class Prism::ConstantPathOperatorWriteNode < ::Prism::Node + # def initialize: (ConstantPathNode target, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void + # + # @return [ConstantPathOperatorWriteNode] a new instance of ConstantPathOperatorWriteNode + # + # source://prism//lib/prism/node.rb#5018 + sig do + params( + source: Prism::Source, + target: Prism::ConstantPathNode, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).void + end + def initialize(source, target, binary_operator_loc, value, binary_operator, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5111 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5028 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#5074 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#5064 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5033 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5043 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5038 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?target: ConstantPathNode, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> ConstantPathOperatorWriteNode + # + # source://prism//lib/prism/node.rb#5048 + sig do + params( + target: Prism::ConstantPathNode, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).returns(Prism::ConstantPathOperatorWriteNode) + end + def copy(target: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5033 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#5056 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5077 + sig { override.returns(String) } + def inspect; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#371 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#378 + def operator_loc; end + + # attr_reader target: ConstantPathNode + # + # source://prism//lib/prism/node.rb#5061 + sig { returns(Prism::ConstantPathNode) } + def target; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5095 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#5071 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5105 + def type; end + end +end + +# Represents the use of the `||=` operator for assignment to a constant path. +# +# Parent::Child ||= value +# ^^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#5124 +class Prism::ConstantPathOrWriteNode < ::Prism::Node + # def initialize: (ConstantPathNode target, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [ConstantPathOrWriteNode] a new instance of ConstantPathOrWriteNode + # + # source://prism//lib/prism/node.rb#5126 + sig do + params( + source: Prism::Source, + target: Prism::ConstantPathNode, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, target, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5220 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5135 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5140 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5150 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5145 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?target: ConstantPathNode, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantPathOrWriteNode + # + # source://prism//lib/prism/node.rb#5155 + sig do + params( + target: Prism::ConstantPathNode, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::ConstantPathOrWriteNode) + end + def copy(target: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5140 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#5163 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5186 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#5181 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#5171 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader target: ConstantPathNode + # + # source://prism//lib/prism/node.rb#5168 + sig { returns(Prism::ConstantPathNode) } + def target; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5204 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#5178 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5214 + def type; end + end +end + +# Represents writing to a constant path in a context that doesn't have an explicit value. +# +# Foo::Foo, Bar::Bar = baz +# ^^^^^^^^ ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#5232 +class Prism::ConstantPathTargetNode < ::Prism::Node + # def initialize: (Prism::node? parent, Symbol? name, Location delimiter_loc, Location name_loc, Location location) -> void + # + # @return [ConstantPathTargetNode] a new instance of ConstantPathTargetNode + # + # source://prism//lib/prism/node.rb#5234 + sig do + params( + source: Prism::Source, + parent: T.nilable(Prism::Node), + name: T.nilable(Symbol), + delimiter_loc: Prism::Location, + name_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, parent, name, delimiter_loc, name_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5338 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5244 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # Previously, we had a child node on this class that contained either a + # constant read or a missing node. To not cause a breaking change, we + # continue to supply that API. + # + # source://prism//lib/prism/node_ext.rb#232 + def child; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5249 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5261 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5254 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?parent: Prism::node?, ?name: Symbol?, ?delimiter_loc: Location, ?name_loc: Location, ?location: Location) -> ConstantPathTargetNode + # + # source://prism//lib/prism/node.rb#5266 + sig do + params( + parent: T.nilable(Prism::Node), + name: T.nilable(Symbol), + delimiter_loc: Prism::Location, + name_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::ConstantPathTargetNode) + end + def copy(parent: T.unsafe(nil), name: T.unsafe(nil), delimiter_loc: T.unsafe(nil), name_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5249 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { parent: Prism::node?, name: Symbol?, delimiter_loc: Location, name_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#5274 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def delimiter: () -> String + # + # source://prism//lib/prism/node.rb#5299 + sig { returns(String) } + def delimiter; end + + # attr_reader delimiter_loc: Location + # + # source://prism//lib/prism/node.rb#5285 + sig { returns(Prism::Location) } + def delimiter_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # Returns the full name of this constant path. For example: "Foo::Bar" + # + # source://prism//lib/prism/node_ext.rb#225 + sig { returns(String) } + def full_name; end + + # Returns the list of parts for the full name of this constant path. + # For example: [:Foo, :Bar] + # + # source://prism//lib/prism/node_ext.rb#205 + sig { returns(T::Array[Symbol]) } + def full_name_parts; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5304 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol? + # + # source://prism//lib/prism/node.rb#5282 + sig { returns(T.nilable(Symbol)) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#5292 + sig { returns(Prism::Location) } + def name_loc; end + + # attr_reader parent: Prism::node? + # + # source://prism//lib/prism/node.rb#5279 + sig { returns(T.nilable(Prism::Node)) } + def parent; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5322 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5332 + def type; end + end +end + +# Represents writing to a constant path. +# +# ::Foo = 1 +# ^^^^^^^^^ +# +# Foo::Bar = 1 +# ^^^^^^^^^^^^ +# +# ::Foo::Bar = 1 +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#5357 +class Prism::ConstantPathWriteNode < ::Prism::Node + # def initialize: (ConstantPathNode target, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [ConstantPathWriteNode] a new instance of ConstantPathWriteNode + # + # source://prism//lib/prism/node.rb#5359 + sig do + params( + source: Prism::Source, + target: Prism::ConstantPathNode, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, target, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5465 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5368 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5373 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5383 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5378 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?target: ConstantPathNode, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantPathWriteNode + # + # source://prism//lib/prism/node.rb#5388 + sig do + params( + target: Prism::ConstantPathNode, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::ConstantPathWriteNode) + end + def copy(target: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5373 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#5396 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5431 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#5426 + sig { returns(String) } + def operator; end + + # The location of the `=` operator. + # + # ::ABC = 123 + # ^ + # + # source://prism//lib/prism/node.rb#5413 + sig { returns(Prism::Location) } + def operator_loc; end + + # A node representing the constant path being written to. + # + # Foo::Bar = 1 + # ^^^^^^^^ + # + # ::Foo = :abc + # ^^^^^ + # + # source://prism//lib/prism/node.rb#5407 + sig { returns(Prism::ConstantPathNode) } + def target; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5449 + sig { override.returns(Symbol) } + def type; end + + # The value to write to the constant path. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # FOO::BAR = :abc + # ^^^^ + # + # source://prism//lib/prism/node.rb#5423 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5459 + def type; end + end +end + +# Represents referencing a constant. +# +# Foo +# ^^^ +# +# source://prism//lib/prism/node.rb#5477 +class Prism::ConstantReadNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [ConstantReadNode] a new instance of ConstantReadNode + # + # source://prism//lib/prism/node.rb#5479 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5560 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5486 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5491 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5501 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5496 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> ConstantReadNode + # + # source://prism//lib/prism/node.rb#5506 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::ConstantReadNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5491 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#5514 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # Returns the full name of this constant. For example: "Foo" + # + # source://prism//lib/prism/node_ext.rb#133 + sig { returns(String) } + def full_name; end + + # Returns the list of parts for the full name of this constant. + # For example: [:Foo] + # + # source://prism//lib/prism/node_ext.rb#128 + sig { returns(T::Array[Symbol]) } + def full_name_parts; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5526 + sig { override.returns(String) } + def inspect; end + + # The name of the [constant](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#constants). + # + # X # name `:X` + # + # SOME_CONSTANT # name `:SOME_CONSTANT` + # + # source://prism//lib/prism/node.rb#5523 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5544 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5554 + def type; end + end +end + +# Represents writing to a constant in a context that doesn't have an explicit value. +# +# Foo, Bar = baz +# ^^^ ^^^ +# +# source://prism//lib/prism/node.rb#5570 +class Prism::ConstantTargetNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [ConstantTargetNode] a new instance of ConstantTargetNode + # + # source://prism//lib/prism/node.rb#5572 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5649 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5579 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5584 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5594 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5589 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> ConstantTargetNode + # + # source://prism//lib/prism/node.rb#5599 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::ConstantTargetNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5584 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#5607 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # Returns the full name of this constant. For example: "Foo" + # + # source://prism//lib/prism/node_ext.rb#246 + sig { returns(String) } + def full_name; end + + # Returns the list of parts for the full name of this constant. + # For example: [:Foo] + # + # source://prism//lib/prism/node_ext.rb#241 + sig { returns(T::Array[Symbol]) } + def full_name_parts; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5615 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#5612 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5633 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5643 + def type; end + end +end + +# Represents writing to a constant. +# +# Foo = 1 +# ^^^^^^^ +# +# source://prism//lib/prism/node.rb#5659 +class Prism::ConstantWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void + # + # @return [ConstantWriteNode] a new instance of ConstantWriteNode + # + # source://prism//lib/prism/node.rb#5661 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, value, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#5779 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5671 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5676 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5686 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5681 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> ConstantWriteNode + # + # source://prism//lib/prism/node.rb#5691 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::ConstantWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5676 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#5699 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # Returns the full name of this constant. For example: "Foo" + # + # source://prism//lib/prism/node_ext.rb#146 + sig { returns(String) } + def full_name; end + + # Returns the list of parts for the full name of this constant. + # For example: [:Foo] + # + # source://prism//lib/prism/node_ext.rb#141 + sig { returns(T::Array[Symbol]) } + def full_name_parts; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5745 + sig { override.returns(String) } + def inspect; end + + # The name of the [constant](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#constants). + # + # Foo = :bar # name `:Foo` + # + # XYZ = 1 # name `:XYZ` + # + # source://prism//lib/prism/node.rb#5708 + sig { returns(Symbol) } + def name; end + + # The location of the constant name. + # + # FOO = 1 + # ^^^ + # + # source://prism//lib/prism/node.rb#5714 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#5740 + sig { returns(String) } + def operator; end + + # The location of the `=` operator. + # + # FOO = :bar + # ^ + # + # source://prism//lib/prism/node.rb#5733 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5763 + sig { override.returns(Symbol) } + def type; end + + # The value to write to the constant. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # FOO = :bar + # ^^^^ + # + # MyClass = Class.new + # ^^^^^^^^^ + # + # source://prism//lib/prism/node.rb#5727 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5773 + def type; end + end +end + +# The DSL module provides a set of methods that can be used to create prism +# nodes in a more concise manner. For example, instead of writing: +# +# source = Prism::Source.for("[1]") +# +# Prism::ArrayNode.new( +# [ +# Prism::IntegerNode.new( +# Prism::IntegerBaseFlags::DECIMAL, +# 1, +# Prism::Location.new(source, 1, 1), +# source +# ) +# ], +# Prism::Location.new(source, 0, 1), +# Prism::Location.new(source, 2, 1), +# source +# ) +# +# you could instead write: +# +# source = Prism::Source.for("[1]") +# +# ArrayNode( +# IntegerNode(Prism::IntegerBaseFlags::DECIMAL, 1, Location(source, 1, 1)), source), +# Location(source, 0, 1), +# Location(source, 2, 1), +# source +# ) +# +# This is mostly helpful in the context of writing tests, but can also be used +# to generate trees programmatically. +# +# source://prism//lib/prism/dsl.rb#42 +module Prism::DSL + private + + # Create a new AliasGlobalVariableNode node + # + # source://prism//lib/prism/dsl.rb#51 + def AliasGlobalVariableNode(new_name, old_name, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new AliasMethodNode node + # + # source://prism//lib/prism/dsl.rb#56 + def AliasMethodNode(new_name, old_name, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new AlternationPatternNode node + # + # source://prism//lib/prism/dsl.rb#61 + def AlternationPatternNode(left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new AndNode node + # + # source://prism//lib/prism/dsl.rb#66 + def AndNode(left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ArgumentsNode node + # + # source://prism//lib/prism/dsl.rb#71 + def ArgumentsNode(flags, arguments, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ArrayNode node + # + # source://prism//lib/prism/dsl.rb#76 + def ArrayNode(flags, elements, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ArrayPatternNode node + # + # source://prism//lib/prism/dsl.rb#81 + def ArrayPatternNode(constant, requireds, rest, posts, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new AssocNode node + # + # source://prism//lib/prism/dsl.rb#86 + def AssocNode(key, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new AssocSplatNode node + # + # source://prism//lib/prism/dsl.rb#91 + def AssocSplatNode(value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BackReferenceReadNode node + # + # source://prism//lib/prism/dsl.rb#96 + def BackReferenceReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BeginNode node + # + # source://prism//lib/prism/dsl.rb#101 + def BeginNode(begin_keyword_loc, statements, rescue_clause, else_clause, ensure_clause, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BlockArgumentNode node + # + # source://prism//lib/prism/dsl.rb#106 + def BlockArgumentNode(expression, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BlockLocalVariableNode node + # + # source://prism//lib/prism/dsl.rb#111 + def BlockLocalVariableNode(flags, name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BlockNode node + # + # source://prism//lib/prism/dsl.rb#116 + def BlockNode(locals, parameters, body, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BlockParameterNode node + # + # source://prism//lib/prism/dsl.rb#121 + def BlockParameterNode(flags, name, name_loc, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BlockParametersNode node + # + # source://prism//lib/prism/dsl.rb#126 + def BlockParametersNode(parameters, locals, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new BreakNode node + # + # source://prism//lib/prism/dsl.rb#131 + def BreakNode(arguments, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CallAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#136 + def CallAndWriteNode(flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CallNode node + # + # source://prism//lib/prism/dsl.rb#141 + def CallNode(flags, receiver, call_operator_loc, name, message_loc, opening_loc, arguments, closing_loc, block, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CallOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#146 + def CallOperatorWriteNode(flags, receiver, call_operator_loc, message_loc, read_name, write_name, binary_operator, binary_operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CallOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#151 + def CallOrWriteNode(flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CallTargetNode node + # + # source://prism//lib/prism/dsl.rb#156 + def CallTargetNode(flags, receiver, call_operator_loc, name, message_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CapturePatternNode node + # + # source://prism//lib/prism/dsl.rb#161 + def CapturePatternNode(value, target, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CaseMatchNode node + # + # source://prism//lib/prism/dsl.rb#166 + def CaseMatchNode(predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new CaseNode node + # + # source://prism//lib/prism/dsl.rb#171 + def CaseNode(predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ClassNode node + # + # source://prism//lib/prism/dsl.rb#176 + def ClassNode(locals, class_keyword_loc, constant_path, inheritance_operator_loc, superclass, body, end_keyword_loc, name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ClassVariableAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#181 + def ClassVariableAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ClassVariableOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#186 + def ClassVariableOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ClassVariableOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#191 + def ClassVariableOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ClassVariableReadNode node + # + # source://prism//lib/prism/dsl.rb#196 + def ClassVariableReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ClassVariableTargetNode node + # + # source://prism//lib/prism/dsl.rb#201 + def ClassVariableTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ClassVariableWriteNode node + # + # source://prism//lib/prism/dsl.rb#206 + def ClassVariableWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#211 + def ConstantAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#216 + def ConstantOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#221 + def ConstantOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantPathAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#226 + def ConstantPathAndWriteNode(target, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantPathNode node + # + # source://prism//lib/prism/dsl.rb#231 + def ConstantPathNode(parent, name, delimiter_loc, name_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantPathOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#236 + def ConstantPathOperatorWriteNode(target, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantPathOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#241 + def ConstantPathOrWriteNode(target, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantPathTargetNode node + # + # source://prism//lib/prism/dsl.rb#246 + def ConstantPathTargetNode(parent, name, delimiter_loc, name_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantPathWriteNode node + # + # source://prism//lib/prism/dsl.rb#251 + def ConstantPathWriteNode(target, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantReadNode node + # + # source://prism//lib/prism/dsl.rb#256 + def ConstantReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantTargetNode node + # + # source://prism//lib/prism/dsl.rb#261 + def ConstantTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ConstantWriteNode node + # + # source://prism//lib/prism/dsl.rb#266 + def ConstantWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new DefNode node + # + # source://prism//lib/prism/dsl.rb#271 + def DefNode(name, name_loc, receiver, parameters, body, locals, def_keyword_loc, operator_loc, lparen_loc, rparen_loc, equal_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new DefinedNode node + # + # source://prism//lib/prism/dsl.rb#276 + def DefinedNode(lparen_loc, value, rparen_loc, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ElseNode node + # + # source://prism//lib/prism/dsl.rb#281 + def ElseNode(else_keyword_loc, statements, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new EmbeddedStatementsNode node + # + # source://prism//lib/prism/dsl.rb#286 + def EmbeddedStatementsNode(opening_loc, statements, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new EmbeddedVariableNode node + # + # source://prism//lib/prism/dsl.rb#291 + def EmbeddedVariableNode(operator_loc, variable, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new EnsureNode node + # + # source://prism//lib/prism/dsl.rb#296 + def EnsureNode(ensure_keyword_loc, statements, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new FalseNode node + # + # source://prism//lib/prism/dsl.rb#301 + def FalseNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new FindPatternNode node + # + # source://prism//lib/prism/dsl.rb#306 + def FindPatternNode(constant, left, requireds, right, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new FlipFlopNode node + # + # source://prism//lib/prism/dsl.rb#311 + def FlipFlopNode(flags, left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new FloatNode node + # + # source://prism//lib/prism/dsl.rb#316 + def FloatNode(value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ForNode node + # + # source://prism//lib/prism/dsl.rb#321 + def ForNode(index, collection, statements, for_keyword_loc, in_keyword_loc, do_keyword_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ForwardingArgumentsNode node + # + # source://prism//lib/prism/dsl.rb#326 + def ForwardingArgumentsNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ForwardingParameterNode node + # + # source://prism//lib/prism/dsl.rb#331 + def ForwardingParameterNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ForwardingSuperNode node + # + # source://prism//lib/prism/dsl.rb#336 + def ForwardingSuperNode(block, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new GlobalVariableAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#341 + def GlobalVariableAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new GlobalVariableOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#346 + def GlobalVariableOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new GlobalVariableOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#351 + def GlobalVariableOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new GlobalVariableReadNode node + # + # source://prism//lib/prism/dsl.rb#356 + def GlobalVariableReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new GlobalVariableTargetNode node + # + # source://prism//lib/prism/dsl.rb#361 + def GlobalVariableTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new GlobalVariableWriteNode node + # + # source://prism//lib/prism/dsl.rb#366 + def GlobalVariableWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new HashNode node + # + # source://prism//lib/prism/dsl.rb#371 + def HashNode(opening_loc, elements, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new HashPatternNode node + # + # source://prism//lib/prism/dsl.rb#376 + def HashPatternNode(constant, elements, rest, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new IfNode node + # + # source://prism//lib/prism/dsl.rb#381 + def IfNode(if_keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ImaginaryNode node + # + # source://prism//lib/prism/dsl.rb#386 + def ImaginaryNode(numeric, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ImplicitNode node + # + # source://prism//lib/prism/dsl.rb#391 + def ImplicitNode(value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ImplicitRestNode node + # + # source://prism//lib/prism/dsl.rb#396 + def ImplicitRestNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InNode node + # + # source://prism//lib/prism/dsl.rb#401 + def InNode(pattern, statements, in_loc, then_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new IndexAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#406 + def IndexAndWriteNode(flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new IndexOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#411 + def IndexOperatorWriteNode(flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, binary_operator, binary_operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new IndexOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#416 + def IndexOrWriteNode(flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new IndexTargetNode node + # + # source://prism//lib/prism/dsl.rb#421 + def IndexTargetNode(flags, receiver, opening_loc, arguments, closing_loc, block, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InstanceVariableAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#426 + def InstanceVariableAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InstanceVariableOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#431 + def InstanceVariableOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InstanceVariableOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#436 + def InstanceVariableOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InstanceVariableReadNode node + # + # source://prism//lib/prism/dsl.rb#441 + def InstanceVariableReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InstanceVariableTargetNode node + # + # source://prism//lib/prism/dsl.rb#446 + def InstanceVariableTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InstanceVariableWriteNode node + # + # source://prism//lib/prism/dsl.rb#451 + def InstanceVariableWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new IntegerNode node + # + # source://prism//lib/prism/dsl.rb#456 + def IntegerNode(flags, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InterpolatedMatchLastLineNode node + # + # source://prism//lib/prism/dsl.rb#461 + def InterpolatedMatchLastLineNode(flags, opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InterpolatedRegularExpressionNode node + # + # source://prism//lib/prism/dsl.rb#466 + def InterpolatedRegularExpressionNode(flags, opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InterpolatedStringNode node + # + # source://prism//lib/prism/dsl.rb#471 + def InterpolatedStringNode(flags, opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InterpolatedSymbolNode node + # + # source://prism//lib/prism/dsl.rb#476 + def InterpolatedSymbolNode(opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new InterpolatedXStringNode node + # + # source://prism//lib/prism/dsl.rb#481 + def InterpolatedXStringNode(opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ItLocalVariableReadNode node + # + # source://prism//lib/prism/dsl.rb#486 + def ItLocalVariableReadNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ItParametersNode node + # + # source://prism//lib/prism/dsl.rb#491 + def ItParametersNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new KeywordHashNode node + # + # source://prism//lib/prism/dsl.rb#496 + def KeywordHashNode(flags, elements, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new KeywordRestParameterNode node + # + # source://prism//lib/prism/dsl.rb#501 + def KeywordRestParameterNode(flags, name, name_loc, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new LambdaNode node + # + # source://prism//lib/prism/dsl.rb#506 + def LambdaNode(locals, operator_loc, opening_loc, closing_loc, parameters, body, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new LocalVariableAndWriteNode node + # + # source://prism//lib/prism/dsl.rb#511 + def LocalVariableAndWriteNode(name_loc, operator_loc, value, name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new LocalVariableOperatorWriteNode node + # + # source://prism//lib/prism/dsl.rb#516 + def LocalVariableOperatorWriteNode(name_loc, binary_operator_loc, value, name, binary_operator, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new LocalVariableOrWriteNode node + # + # source://prism//lib/prism/dsl.rb#521 + def LocalVariableOrWriteNode(name_loc, operator_loc, value, name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new LocalVariableReadNode node + # + # source://prism//lib/prism/dsl.rb#526 + def LocalVariableReadNode(name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new LocalVariableTargetNode node + # + # source://prism//lib/prism/dsl.rb#531 + def LocalVariableTargetNode(name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new LocalVariableWriteNode node + # + # source://prism//lib/prism/dsl.rb#536 + def LocalVariableWriteNode(name, depth, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new Location object + # + # source://prism//lib/prism/dsl.rb#46 + def Location(source = T.unsafe(nil), start_offset = T.unsafe(nil), length = T.unsafe(nil)); end + + # Create a new MatchLastLineNode node + # + # source://prism//lib/prism/dsl.rb#541 + def MatchLastLineNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new MatchPredicateNode node + # + # source://prism//lib/prism/dsl.rb#546 + def MatchPredicateNode(value, pattern, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new MatchRequiredNode node + # + # source://prism//lib/prism/dsl.rb#551 + def MatchRequiredNode(value, pattern, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new MatchWriteNode node + # + # source://prism//lib/prism/dsl.rb#556 + def MatchWriteNode(call, targets, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new MissingNode node + # + # source://prism//lib/prism/dsl.rb#561 + def MissingNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ModuleNode node + # + # source://prism//lib/prism/dsl.rb#566 + def ModuleNode(locals, module_keyword_loc, constant_path, body, end_keyword_loc, name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new MultiTargetNode node + # + # source://prism//lib/prism/dsl.rb#571 + def MultiTargetNode(lefts, rest, rights, lparen_loc, rparen_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new MultiWriteNode node + # + # source://prism//lib/prism/dsl.rb#576 + def MultiWriteNode(lefts, rest, rights, lparen_loc, rparen_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new NextNode node + # + # source://prism//lib/prism/dsl.rb#581 + def NextNode(arguments, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new NilNode node + # + # source://prism//lib/prism/dsl.rb#586 + def NilNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new NoKeywordsParameterNode node + # + # source://prism//lib/prism/dsl.rb#591 + def NoKeywordsParameterNode(operator_loc, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new NumberedParametersNode node + # + # source://prism//lib/prism/dsl.rb#596 + def NumberedParametersNode(maximum, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new NumberedReferenceReadNode node + # + # source://prism//lib/prism/dsl.rb#601 + def NumberedReferenceReadNode(number, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new OptionalKeywordParameterNode node + # + # source://prism//lib/prism/dsl.rb#606 + def OptionalKeywordParameterNode(flags, name, name_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new OptionalParameterNode node + # + # source://prism//lib/prism/dsl.rb#611 + def OptionalParameterNode(flags, name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new OrNode node + # + # source://prism//lib/prism/dsl.rb#616 + def OrNode(left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ParametersNode node + # + # source://prism//lib/prism/dsl.rb#621 + def ParametersNode(requireds, optionals, rest, posts, keywords, keyword_rest, block, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ParenthesesNode node + # + # source://prism//lib/prism/dsl.rb#626 + def ParenthesesNode(body, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new PinnedExpressionNode node + # + # source://prism//lib/prism/dsl.rb#631 + def PinnedExpressionNode(expression, operator_loc, lparen_loc, rparen_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new PinnedVariableNode node + # + # source://prism//lib/prism/dsl.rb#636 + def PinnedVariableNode(variable, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new PostExecutionNode node + # + # source://prism//lib/prism/dsl.rb#641 + def PostExecutionNode(statements, keyword_loc, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new PreExecutionNode node + # + # source://prism//lib/prism/dsl.rb#646 + def PreExecutionNode(statements, keyword_loc, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ProgramNode node + # + # source://prism//lib/prism/dsl.rb#651 + def ProgramNode(locals, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RangeNode node + # + # source://prism//lib/prism/dsl.rb#656 + def RangeNode(flags, left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RationalNode node + # + # source://prism//lib/prism/dsl.rb#661 + def RationalNode(flags, numerator, denominator, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RedoNode node + # + # source://prism//lib/prism/dsl.rb#666 + def RedoNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RegularExpressionNode node + # + # source://prism//lib/prism/dsl.rb#671 + def RegularExpressionNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RequiredKeywordParameterNode node + # + # source://prism//lib/prism/dsl.rb#676 + def RequiredKeywordParameterNode(flags, name, name_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RequiredParameterNode node + # + # source://prism//lib/prism/dsl.rb#681 + def RequiredParameterNode(flags, name, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RescueModifierNode node + # + # source://prism//lib/prism/dsl.rb#686 + def RescueModifierNode(expression, keyword_loc, rescue_expression, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RescueNode node + # + # source://prism//lib/prism/dsl.rb#691 + def RescueNode(keyword_loc, exceptions, operator_loc, reference, statements, consequent, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RestParameterNode node + # + # source://prism//lib/prism/dsl.rb#696 + def RestParameterNode(flags, name, name_loc, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new RetryNode node + # + # source://prism//lib/prism/dsl.rb#701 + def RetryNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ReturnNode node + # + # source://prism//lib/prism/dsl.rb#706 + def ReturnNode(flags, keyword_loc, arguments, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SelfNode node + # + # source://prism//lib/prism/dsl.rb#711 + def SelfNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new ShareableConstantNode node + # + # source://prism//lib/prism/dsl.rb#716 + def ShareableConstantNode(flags, write, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SingletonClassNode node + # + # source://prism//lib/prism/dsl.rb#721 + def SingletonClassNode(locals, class_keyword_loc, operator_loc, expression, body, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SourceEncodingNode node + # + # source://prism//lib/prism/dsl.rb#726 + def SourceEncodingNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SourceFileNode node + # + # source://prism//lib/prism/dsl.rb#731 + def SourceFileNode(flags, filepath, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SourceLineNode node + # + # source://prism//lib/prism/dsl.rb#736 + def SourceLineNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SplatNode node + # + # source://prism//lib/prism/dsl.rb#741 + def SplatNode(operator_loc, expression, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new StatementsNode node + # + # source://prism//lib/prism/dsl.rb#746 + def StatementsNode(body, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new StringNode node + # + # source://prism//lib/prism/dsl.rb#751 + def StringNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SuperNode node + # + # source://prism//lib/prism/dsl.rb#756 + def SuperNode(keyword_loc, lparen_loc, arguments, rparen_loc, block, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new SymbolNode node + # + # source://prism//lib/prism/dsl.rb#761 + def SymbolNode(flags, opening_loc, value_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new TrueNode node + # + # source://prism//lib/prism/dsl.rb#766 + def TrueNode(source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new UndefNode node + # + # source://prism//lib/prism/dsl.rb#771 + def UndefNode(names, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new UnlessNode node + # + # source://prism//lib/prism/dsl.rb#776 + def UnlessNode(keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new UntilNode node + # + # source://prism//lib/prism/dsl.rb#781 + def UntilNode(flags, keyword_loc, closing_loc, predicate, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new WhenNode node + # + # source://prism//lib/prism/dsl.rb#786 + def WhenNode(keyword_loc, conditions, then_keyword_loc, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new WhileNode node + # + # source://prism//lib/prism/dsl.rb#791 + def WhileNode(flags, keyword_loc, closing_loc, predicate, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new XStringNode node + # + # source://prism//lib/prism/dsl.rb#796 + def XStringNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end + + # Create a new YieldNode node + # + # source://prism//lib/prism/dsl.rb#801 + def YieldNode(keyword_loc, lparen_loc, arguments, rparen_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end +end + +# Represents a method definition. +# +# def method +# end +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#5793 +class Prism::DefNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Prism::node? receiver, ParametersNode? parameters, Prism::node? body, Array[Symbol] locals, Location def_keyword_loc, Location? operator_loc, Location? lparen_loc, Location? rparen_loc, Location? equal_loc, Location? end_keyword_loc, Location location) -> void + # + # @return [DefNode] a new instance of DefNode + # + # source://prism//lib/prism/node.rb#5795 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + receiver: T.nilable(Prism::Node), + parameters: T.nilable(Prism::ParametersNode), + body: T.nilable(Prism::Node), + locals: T::Array[Symbol], + def_keyword_loc: Prism::Location, + operator_loc: T.nilable(Prism::Location), + lparen_loc: T.nilable(Prism::Location), + rparen_loc: T.nilable(Prism::Location), + equal_loc: T.nilable(Prism::Location), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, receiver, parameters, body, locals, def_keyword_loc, operator_loc, lparen_loc, rparen_loc, equal_loc, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6008 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#5813 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Prism::node? + # + # source://prism//lib/prism/node.rb#5866 + sig { returns(T.nilable(Prism::Node)) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5818 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#5832 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#5823 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?receiver: Prism::node?, ?parameters: ParametersNode?, ?body: Prism::node?, ?locals: Array[Symbol], ?def_keyword_loc: Location, ?operator_loc: Location?, ?lparen_loc: Location?, ?rparen_loc: Location?, ?equal_loc: Location?, ?end_keyword_loc: Location?, ?location: Location) -> DefNode + # + # source://prism//lib/prism/node.rb#5837 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + receiver: T.nilable(Prism::Node), + parameters: T.nilable(Prism::ParametersNode), + body: T.nilable(Prism::Node), + locals: T::Array[Symbol], + def_keyword_loc: Prism::Location, + operator_loc: T.nilable(Prism::Location), + lparen_loc: T.nilable(Prism::Location), + rparen_loc: T.nilable(Prism::Location), + equal_loc: T.nilable(Prism::Location), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::DefNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), receiver: T.unsafe(nil), parameters: T.unsafe(nil), body: T.unsafe(nil), locals: T.unsafe(nil), def_keyword_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), equal_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#5818 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, receiver: Prism::node?, parameters: ParametersNode?, body: Prism::node?, locals: Array[Symbol], def_keyword_loc: Location, operator_loc: Location?, lparen_loc: Location?, rparen_loc: Location?, equal_loc: Location?, end_keyword_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#5845 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def def_keyword: () -> String + # + # source://prism//lib/prism/node.rb#5944 + sig { returns(String) } + def def_keyword; end + + # attr_reader def_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#5872 + sig { returns(Prism::Location) } + def def_keyword_loc; end + + # def end_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#5969 + sig { returns(T.nilable(String)) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location? + # + # source://prism//lib/prism/node.rb#5931 + sig { returns(T.nilable(Prism::Location)) } + def end_keyword_loc; end + + # def equal: () -> String? + # + # source://prism//lib/prism/node.rb#5964 + sig { returns(T.nilable(String)) } + def equal; end + + # attr_reader equal_loc: Location? + # + # source://prism//lib/prism/node.rb#5918 + sig { returns(T.nilable(Prism::Location)) } + def equal_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#5974 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[Symbol] + # + # source://prism//lib/prism/node.rb#5869 + sig { returns(T::Array[Symbol]) } + def locals; end + + # def lparen: () -> String? + # + # source://prism//lib/prism/node.rb#5954 + sig { returns(T.nilable(String)) } + def lparen; end + + # attr_reader lparen_loc: Location? + # + # source://prism//lib/prism/node.rb#5892 + sig { returns(T.nilable(Prism::Location)) } + def lparen_loc; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#5850 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#5853 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String? + # + # source://prism//lib/prism/node.rb#5949 + sig { returns(T.nilable(String)) } + def operator; end + + # attr_reader operator_loc: Location? + # + # source://prism//lib/prism/node.rb#5879 + sig { returns(T.nilable(Prism::Location)) } + def operator_loc; end + + # attr_reader parameters: ParametersNode? + # + # source://prism//lib/prism/node.rb#5863 + sig { returns(T.nilable(Prism::ParametersNode)) } + def parameters; end + + # attr_reader receiver: Prism::node? + # + # source://prism//lib/prism/node.rb#5860 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def rparen: () -> String? + # + # source://prism//lib/prism/node.rb#5959 + sig { returns(T.nilable(String)) } + def rparen; end + + # attr_reader rparen_loc: Location? + # + # source://prism//lib/prism/node.rb#5905 + sig { returns(T.nilable(Prism::Location)) } + def rparen_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#5992 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6002 + def type; end + end +end + +# Represents the use of the `defined?` keyword. +# +# defined?(a) +# ^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#6030 +class Prism::DefinedNode < ::Prism::Node + # def initialize: (Location? lparen_loc, Prism::node value, Location? rparen_loc, Location keyword_loc, Location location) -> void + # + # @return [DefinedNode] a new instance of DefinedNode + # + # source://prism//lib/prism/node.rb#6032 + sig do + params( + source: Prism::Source, + lparen_loc: T.nilable(Prism::Location), + value: Prism::Node, + rparen_loc: T.nilable(Prism::Location), + keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, lparen_loc, value, rparen_loc, keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6160 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6042 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6047 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6057 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6052 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?lparen_loc: Location?, ?value: Prism::node, ?rparen_loc: Location?, ?keyword_loc: Location, ?location: Location) -> DefinedNode + # + # source://prism//lib/prism/node.rb#6062 + sig do + params( + lparen_loc: T.nilable(Prism::Location), + value: Prism::Node, + rparen_loc: T.nilable(Prism::Location), + keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::DefinedNode) + end + def copy(lparen_loc: T.unsafe(nil), value: T.unsafe(nil), rparen_loc: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6047 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { lparen_loc: Location?, value: Prism::node, rparen_loc: Location?, keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#6070 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6126 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#6121 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#6104 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def lparen: () -> String? + # + # source://prism//lib/prism/node.rb#6111 + sig { returns(T.nilable(String)) } + def lparen; end + + # attr_reader lparen_loc: Location? + # + # source://prism//lib/prism/node.rb#6075 + sig { returns(T.nilable(Prism::Location)) } + def lparen_loc; end + + # def rparen: () -> String? + # + # source://prism//lib/prism/node.rb#6116 + sig { returns(T.nilable(String)) } + def rparen; end + + # attr_reader rparen_loc: Location? + # + # source://prism//lib/prism/node.rb#6091 + sig { returns(T.nilable(Prism::Location)) } + def rparen_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6144 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#6088 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6154 + def type; end + end +end + +# source://prism//lib/prism/desugar_compiler.rb#4 +class Prism::DesugarAndWriteNode + # @return [DesugarAndWriteNode] a new instance of DesugarAndWriteNode + # + # source://prism//lib/prism/desugar_compiler.rb#7 + def initialize(node, source, read_class, write_class, *arguments); end + + # Returns the value of attribute arguments. + # + # source://prism//lib/prism/desugar_compiler.rb#5 + def arguments; end + + # Desugar `x &&= y` to `x && x = y` + # + # source://prism//lib/prism/desugar_compiler.rb#16 + def compile; end + + # Returns the value of attribute node. + # + # source://prism//lib/prism/desugar_compiler.rb#5 + def node; end + + # Returns the value of attribute read_class. + # + # source://prism//lib/prism/desugar_compiler.rb#5 + def read_class; end + + # Returns the value of attribute source. + # + # source://prism//lib/prism/desugar_compiler.rb#5 + def source; end + + # Returns the value of attribute write_class. + # + # source://prism//lib/prism/desugar_compiler.rb#5 + def write_class; end +end + +# DesugarCompiler is a compiler that desugars Ruby code into a more primitive +# form. This is useful for consumers that want to deal with fewer node types. +# +# source://prism//lib/prism/desugar_compiler.rb#218 +class Prism::DesugarCompiler < ::Prism::MutationCompiler + # @@foo &&= bar + # + # becomes + # + # @@foo && @@foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#224 + def visit_class_variable_and_write_node(node); end + + # @@foo += bar + # + # becomes + # + # @@foo = @@foo + bar + # + # source://prism//lib/prism/desugar_compiler.rb#242 + def visit_class_variable_operator_write_node(node); end + + # @@foo ||= bar + # + # becomes + # + # defined?(@@foo) ? @@foo : @@foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#233 + def visit_class_variable_or_write_node(node); end + + # Foo &&= bar + # + # becomes + # + # Foo && Foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#251 + def visit_constant_and_write_node(node); end + + # Foo += bar + # + # becomes + # + # Foo = Foo + bar + # + # source://prism//lib/prism/desugar_compiler.rb#269 + def visit_constant_operator_write_node(node); end + + # Foo ||= bar + # + # becomes + # + # defined?(Foo) ? Foo : Foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#260 + def visit_constant_or_write_node(node); end + + # $foo &&= bar + # + # becomes + # + # $foo && $foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#278 + def visit_global_variable_and_write_node(node); end + + # $foo += bar + # + # becomes + # + # $foo = $foo + bar + # + # source://prism//lib/prism/desugar_compiler.rb#296 + def visit_global_variable_operator_write_node(node); end + + # $foo ||= bar + # + # becomes + # + # defined?($foo) ? $foo : $foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#287 + def visit_global_variable_or_write_node(node); end + + # becomes + # + # source://prism//lib/prism/desugar_compiler.rb#305 + def visit_instance_variable_and_write_node(node); end + + # becomes + # + # source://prism//lib/prism/desugar_compiler.rb#323 + def visit_instance_variable_operator_write_node(node); end + + # becomes + # + # source://prism//lib/prism/desugar_compiler.rb#314 + def visit_instance_variable_or_write_node(node); end + + # foo &&= bar + # + # becomes + # + # foo && foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#332 + def visit_local_variable_and_write_node(node); end + + # foo += bar + # + # becomes + # + # foo = foo + bar + # + # source://prism//lib/prism/desugar_compiler.rb#350 + def visit_local_variable_operator_write_node(node); end + + # foo ||= bar + # + # becomes + # + # foo || foo = bar + # + # source://prism//lib/prism/desugar_compiler.rb#341 + def visit_local_variable_or_write_node(node); end +end + +# source://prism//lib/prism/desugar_compiler.rb#63 +class Prism::DesugarOperatorWriteNode + # @return [DesugarOperatorWriteNode] a new instance of DesugarOperatorWriteNode + # + # source://prism//lib/prism/desugar_compiler.rb#66 + def initialize(node, source, read_class, write_class, *arguments); end + + # Returns the value of attribute arguments. + # + # source://prism//lib/prism/desugar_compiler.rb#64 + def arguments; end + + # Desugar `x += y` to `x = x + y` + # + # source://prism//lib/prism/desugar_compiler.rb#75 + def compile; end + + # Returns the value of attribute node. + # + # source://prism//lib/prism/desugar_compiler.rb#64 + def node; end + + # Returns the value of attribute read_class. + # + # source://prism//lib/prism/desugar_compiler.rb#64 + def read_class; end + + # Returns the value of attribute source. + # + # source://prism//lib/prism/desugar_compiler.rb#64 + def source; end + + # Returns the value of attribute write_class. + # + # source://prism//lib/prism/desugar_compiler.rb#64 + def write_class; end +end + +# source://prism//lib/prism/desugar_compiler.rb#27 +class Prism::DesugarOrWriteDefinedNode + # @return [DesugarOrWriteDefinedNode] a new instance of DesugarOrWriteDefinedNode + # + # source://prism//lib/prism/desugar_compiler.rb#30 + def initialize(node, source, read_class, write_class, *arguments); end + + # Returns the value of attribute arguments. + # + # source://prism//lib/prism/desugar_compiler.rb#28 + def arguments; end + + # Desugar `x ||= y` to `defined?(x) ? x : x = y` + # + # source://prism//lib/prism/desugar_compiler.rb#39 + def compile; end + + # Returns the value of attribute node. + # + # source://prism//lib/prism/desugar_compiler.rb#28 + def node; end + + # Returns the value of attribute read_class. + # + # source://prism//lib/prism/desugar_compiler.rb#28 + def read_class; end + + # Returns the value of attribute source. + # + # source://prism//lib/prism/desugar_compiler.rb#28 + def source; end + + # Returns the value of attribute write_class. + # + # source://prism//lib/prism/desugar_compiler.rb#28 + def write_class; end +end + +# source://prism//lib/prism/desugar_compiler.rb#101 +class Prism::DesugarOrWriteNode + # @return [DesugarOrWriteNode] a new instance of DesugarOrWriteNode + # + # source://prism//lib/prism/desugar_compiler.rb#104 + def initialize(node, source, read_class, write_class, *arguments); end + + # Returns the value of attribute arguments. + # + # source://prism//lib/prism/desugar_compiler.rb#102 + def arguments; end + + # Desugar `x ||= y` to `x || x = y` + # + # source://prism//lib/prism/desugar_compiler.rb#113 + def compile; end + + # Returns the value of attribute node. + # + # source://prism//lib/prism/desugar_compiler.rb#102 + def node; end + + # Returns the value of attribute read_class. + # + # source://prism//lib/prism/desugar_compiler.rb#102 + def read_class; end + + # Returns the value of attribute source. + # + # source://prism//lib/prism/desugar_compiler.rb#102 + def source; end + + # Returns the value of attribute write_class. + # + # source://prism//lib/prism/desugar_compiler.rb#102 + def write_class; end +end + +# The dispatcher class fires events for nodes that are found while walking an +# AST to all registered listeners. It's useful for performing different types +# of analysis on the AST while only having to walk the tree once. +# +# To use the dispatcher, you would first instantiate it and register listeners +# for the events you're interested in: +# +# class OctalListener +# def on_integer_node_enter(node) +# if node.octal? && !node.slice.start_with?("0o") +# warn("Octal integers should be written with the 0o prefix") +# end +# end +# end +# +# dispatcher = Dispatcher.new +# dispatcher.register(listener, :on_integer_node_enter) +# +# Then, you can walk any number of trees and dispatch events to the listeners: +# +# result = Prism.parse("001 + 002 + 003") +# dispatcher.dispatch(result.value) +# +# Optionally, you can also use `#dispatch_once` to dispatch enter and leave +# events for a single node without recursing further down the tree. This can +# be useful in circumstances where you want to reuse the listeners you already +# have registers but want to stop walking the tree at a certain point. +# +# integer = result.value.statements.body.first.receiver.receiver +# dispatcher.dispatch_once(integer) +# +# source://prism//lib/prism/dispatcher.rb#41 +class Prism::Dispatcher < ::Prism::Visitor + # Initialize a new dispatcher. + # + # @return [Dispatcher] a new instance of Dispatcher + # + # source://prism//lib/prism/dispatcher.rb#46 + def initialize; end + + # Walks `root` dispatching events to all registered listeners. + # + # def dispatch: (Node) -> void + # + # source://prism//lib/prism/visitor.rb#17 + def dispatch(node); end + + # Dispatches a single event for `node` to all registered listeners. + # + # def dispatch_once: (Node) -> void + # + # source://prism//lib/prism/dispatcher.rb#65 + def dispatch_once(node); end + + # attr_reader listeners: Hash[Symbol, Array[Listener]] + # + # source://prism//lib/prism/dispatcher.rb#43 + def listeners; end + + # Register a listener for one or more events. + # + # def register: (Listener, *Symbol) -> void + # + # source://prism//lib/prism/dispatcher.rb#53 + def register(listener, *events); end + + # Dispatch enter and leave events for AliasGlobalVariableNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#71 + def visit_alias_global_variable_node(node); end + + # Dispatch enter and leave events for AliasMethodNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#79 + def visit_alias_method_node(node); end + + # Dispatch enter and leave events for AlternationPatternNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#87 + def visit_alternation_pattern_node(node); end + + # Dispatch enter and leave events for AndNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#95 + def visit_and_node(node); end + + # Dispatch enter and leave events for ArgumentsNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#103 + def visit_arguments_node(node); end + + # Dispatch enter and leave events for ArrayNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#111 + def visit_array_node(node); end + + # Dispatch enter and leave events for ArrayPatternNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#119 + def visit_array_pattern_node(node); end + + # Dispatch enter and leave events for AssocNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#127 + def visit_assoc_node(node); end + + # Dispatch enter and leave events for AssocSplatNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#135 + def visit_assoc_splat_node(node); end + + # Dispatch enter and leave events for BackReferenceReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#143 + def visit_back_reference_read_node(node); end + + # Dispatch enter and leave events for BeginNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#151 + def visit_begin_node(node); end + + # Dispatch enter and leave events for BlockArgumentNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#159 + def visit_block_argument_node(node); end + + # Dispatch enter and leave events for BlockLocalVariableNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#167 + def visit_block_local_variable_node(node); end + + # Dispatch enter and leave events for BlockNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#175 + def visit_block_node(node); end + + # Dispatch enter and leave events for BlockParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#183 + def visit_block_parameter_node(node); end + + # Dispatch enter and leave events for BlockParametersNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#191 + def visit_block_parameters_node(node); end + + # Dispatch enter and leave events for BreakNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#199 + def visit_break_node(node); end + + # Dispatch enter and leave events for CallAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#207 + def visit_call_and_write_node(node); end + + # Dispatch enter and leave events for CallNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#215 + def visit_call_node(node); end + + # Dispatch enter and leave events for CallOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#223 + def visit_call_operator_write_node(node); end + + # Dispatch enter and leave events for CallOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#231 + def visit_call_or_write_node(node); end + + # Dispatch enter and leave events for CallTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#239 + def visit_call_target_node(node); end + + # Dispatch enter and leave events for CapturePatternNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#247 + def visit_capture_pattern_node(node); end + + # Dispatch enter and leave events for CaseMatchNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#255 + def visit_case_match_node(node); end + + # Dispatch enter and leave events for CaseNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#263 + def visit_case_node(node); end + + # Dispatch enter and leave events for ClassNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#271 + def visit_class_node(node); end + + # Dispatch enter and leave events for ClassVariableAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#279 + def visit_class_variable_and_write_node(node); end + + # Dispatch enter and leave events for ClassVariableOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#287 + def visit_class_variable_operator_write_node(node); end + + # Dispatch enter and leave events for ClassVariableOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#295 + def visit_class_variable_or_write_node(node); end + + # Dispatch enter and leave events for ClassVariableReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#303 + def visit_class_variable_read_node(node); end + + # Dispatch enter and leave events for ClassVariableTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#311 + def visit_class_variable_target_node(node); end + + # Dispatch enter and leave events for ClassVariableWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#319 + def visit_class_variable_write_node(node); end + + # Dispatch enter and leave events for ConstantAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#327 + def visit_constant_and_write_node(node); end + + # Dispatch enter and leave events for ConstantOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#335 + def visit_constant_operator_write_node(node); end + + # Dispatch enter and leave events for ConstantOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#343 + def visit_constant_or_write_node(node); end + + # Dispatch enter and leave events for ConstantPathAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#351 + def visit_constant_path_and_write_node(node); end + + # Dispatch enter and leave events for ConstantPathNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#359 + def visit_constant_path_node(node); end + + # Dispatch enter and leave events for ConstantPathOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#367 + def visit_constant_path_operator_write_node(node); end + + # Dispatch enter and leave events for ConstantPathOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#375 + def visit_constant_path_or_write_node(node); end + + # Dispatch enter and leave events for ConstantPathTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#383 + def visit_constant_path_target_node(node); end + + # Dispatch enter and leave events for ConstantPathWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#391 + def visit_constant_path_write_node(node); end + + # Dispatch enter and leave events for ConstantReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#399 + def visit_constant_read_node(node); end + + # Dispatch enter and leave events for ConstantTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#407 + def visit_constant_target_node(node); end + + # Dispatch enter and leave events for ConstantWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#415 + def visit_constant_write_node(node); end + + # Dispatch enter and leave events for DefNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#423 + def visit_def_node(node); end + + # Dispatch enter and leave events for DefinedNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#431 + def visit_defined_node(node); end + + # Dispatch enter and leave events for ElseNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#439 + def visit_else_node(node); end + + # Dispatch enter and leave events for EmbeddedStatementsNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#447 + def visit_embedded_statements_node(node); end + + # Dispatch enter and leave events for EmbeddedVariableNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#455 + def visit_embedded_variable_node(node); end + + # Dispatch enter and leave events for EnsureNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#463 + def visit_ensure_node(node); end + + # Dispatch enter and leave events for FalseNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#471 + def visit_false_node(node); end + + # Dispatch enter and leave events for FindPatternNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#479 + def visit_find_pattern_node(node); end + + # Dispatch enter and leave events for FlipFlopNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#487 + def visit_flip_flop_node(node); end + + # Dispatch enter and leave events for FloatNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#495 + def visit_float_node(node); end + + # Dispatch enter and leave events for ForNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#503 + def visit_for_node(node); end + + # Dispatch enter and leave events for ForwardingArgumentsNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#511 + def visit_forwarding_arguments_node(node); end + + # Dispatch enter and leave events for ForwardingParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#519 + def visit_forwarding_parameter_node(node); end + + # Dispatch enter and leave events for ForwardingSuperNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#527 + def visit_forwarding_super_node(node); end + + # Dispatch enter and leave events for GlobalVariableAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#535 + def visit_global_variable_and_write_node(node); end + + # Dispatch enter and leave events for GlobalVariableOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#543 + def visit_global_variable_operator_write_node(node); end + + # Dispatch enter and leave events for GlobalVariableOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#551 + def visit_global_variable_or_write_node(node); end + + # Dispatch enter and leave events for GlobalVariableReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#559 + def visit_global_variable_read_node(node); end + + # Dispatch enter and leave events for GlobalVariableTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#567 + def visit_global_variable_target_node(node); end + + # Dispatch enter and leave events for GlobalVariableWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#575 + def visit_global_variable_write_node(node); end + + # Dispatch enter and leave events for HashNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#583 + def visit_hash_node(node); end + + # Dispatch enter and leave events for HashPatternNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#591 + def visit_hash_pattern_node(node); end + + # Dispatch enter and leave events for IfNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#599 + def visit_if_node(node); end + + # Dispatch enter and leave events for ImaginaryNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#607 + def visit_imaginary_node(node); end + + # Dispatch enter and leave events for ImplicitNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#615 + def visit_implicit_node(node); end + + # Dispatch enter and leave events for ImplicitRestNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#623 + def visit_implicit_rest_node(node); end + + # Dispatch enter and leave events for InNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#631 + def visit_in_node(node); end + + # Dispatch enter and leave events for IndexAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#639 + def visit_index_and_write_node(node); end + + # Dispatch enter and leave events for IndexOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#647 + def visit_index_operator_write_node(node); end + + # Dispatch enter and leave events for IndexOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#655 + def visit_index_or_write_node(node); end + + # Dispatch enter and leave events for IndexTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#663 + def visit_index_target_node(node); end + + # Dispatch enter and leave events for InstanceVariableAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#671 + def visit_instance_variable_and_write_node(node); end + + # Dispatch enter and leave events for InstanceVariableOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#679 + def visit_instance_variable_operator_write_node(node); end + + # Dispatch enter and leave events for InstanceVariableOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#687 + def visit_instance_variable_or_write_node(node); end + + # Dispatch enter and leave events for InstanceVariableReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#695 + def visit_instance_variable_read_node(node); end + + # Dispatch enter and leave events for InstanceVariableTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#703 + def visit_instance_variable_target_node(node); end + + # Dispatch enter and leave events for InstanceVariableWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#711 + def visit_instance_variable_write_node(node); end + + # Dispatch enter and leave events for IntegerNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#719 + def visit_integer_node(node); end + + # Dispatch enter and leave events for InterpolatedMatchLastLineNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#727 + def visit_interpolated_match_last_line_node(node); end + + # Dispatch enter and leave events for InterpolatedRegularExpressionNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#735 + def visit_interpolated_regular_expression_node(node); end + + # Dispatch enter and leave events for InterpolatedStringNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#743 + def visit_interpolated_string_node(node); end + + # Dispatch enter and leave events for InterpolatedSymbolNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#751 + def visit_interpolated_symbol_node(node); end + + # Dispatch enter and leave events for InterpolatedXStringNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#759 + def visit_interpolated_x_string_node(node); end + + # Dispatch enter and leave events for ItLocalVariableReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#767 + def visit_it_local_variable_read_node(node); end + + # Dispatch enter and leave events for ItParametersNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#775 + def visit_it_parameters_node(node); end + + # Dispatch enter and leave events for KeywordHashNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#783 + def visit_keyword_hash_node(node); end + + # Dispatch enter and leave events for KeywordRestParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#791 + def visit_keyword_rest_parameter_node(node); end + + # Dispatch enter and leave events for LambdaNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#799 + def visit_lambda_node(node); end + + # Dispatch enter and leave events for LocalVariableAndWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#807 + def visit_local_variable_and_write_node(node); end + + # Dispatch enter and leave events for LocalVariableOperatorWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#815 + def visit_local_variable_operator_write_node(node); end + + # Dispatch enter and leave events for LocalVariableOrWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#823 + def visit_local_variable_or_write_node(node); end + + # Dispatch enter and leave events for LocalVariableReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#831 + def visit_local_variable_read_node(node); end + + # Dispatch enter and leave events for LocalVariableTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#839 + def visit_local_variable_target_node(node); end + + # Dispatch enter and leave events for LocalVariableWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#847 + def visit_local_variable_write_node(node); end + + # Dispatch enter and leave events for MatchLastLineNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#855 + def visit_match_last_line_node(node); end + + # Dispatch enter and leave events for MatchPredicateNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#863 + def visit_match_predicate_node(node); end + + # Dispatch enter and leave events for MatchRequiredNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#871 + def visit_match_required_node(node); end + + # Dispatch enter and leave events for MatchWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#879 + def visit_match_write_node(node); end + + # Dispatch enter and leave events for MissingNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#887 + def visit_missing_node(node); end + + # Dispatch enter and leave events for ModuleNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#895 + def visit_module_node(node); end + + # Dispatch enter and leave events for MultiTargetNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#903 + def visit_multi_target_node(node); end + + # Dispatch enter and leave events for MultiWriteNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#911 + def visit_multi_write_node(node); end + + # Dispatch enter and leave events for NextNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#919 + def visit_next_node(node); end + + # Dispatch enter and leave events for NilNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#927 + def visit_nil_node(node); end + + # Dispatch enter and leave events for NoKeywordsParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#935 + def visit_no_keywords_parameter_node(node); end + + # Dispatch enter and leave events for NumberedParametersNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#943 + def visit_numbered_parameters_node(node); end + + # Dispatch enter and leave events for NumberedReferenceReadNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#951 + def visit_numbered_reference_read_node(node); end + + # Dispatch enter and leave events for OptionalKeywordParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#959 + def visit_optional_keyword_parameter_node(node); end + + # Dispatch enter and leave events for OptionalParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#967 + def visit_optional_parameter_node(node); end + + # Dispatch enter and leave events for OrNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#975 + def visit_or_node(node); end + + # Dispatch enter and leave events for ParametersNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#983 + def visit_parameters_node(node); end + + # Dispatch enter and leave events for ParenthesesNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#991 + def visit_parentheses_node(node); end + + # Dispatch enter and leave events for PinnedExpressionNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#999 + def visit_pinned_expression_node(node); end + + # Dispatch enter and leave events for PinnedVariableNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1007 + def visit_pinned_variable_node(node); end + + # Dispatch enter and leave events for PostExecutionNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1015 + def visit_post_execution_node(node); end + + # Dispatch enter and leave events for PreExecutionNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1023 + def visit_pre_execution_node(node); end + + # Dispatch enter and leave events for ProgramNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1031 + def visit_program_node(node); end + + # Dispatch enter and leave events for RangeNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1039 + def visit_range_node(node); end + + # Dispatch enter and leave events for RationalNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1047 + def visit_rational_node(node); end + + # Dispatch enter and leave events for RedoNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1055 + def visit_redo_node(node); end + + # Dispatch enter and leave events for RegularExpressionNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1063 + def visit_regular_expression_node(node); end + + # Dispatch enter and leave events for RequiredKeywordParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1071 + def visit_required_keyword_parameter_node(node); end + + # Dispatch enter and leave events for RequiredParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1079 + def visit_required_parameter_node(node); end + + # Dispatch enter and leave events for RescueModifierNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1087 + def visit_rescue_modifier_node(node); end + + # Dispatch enter and leave events for RescueNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1095 + def visit_rescue_node(node); end + + # Dispatch enter and leave events for RestParameterNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1103 + def visit_rest_parameter_node(node); end + + # Dispatch enter and leave events for RetryNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1111 + def visit_retry_node(node); end + + # Dispatch enter and leave events for ReturnNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1119 + def visit_return_node(node); end + + # Dispatch enter and leave events for SelfNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1127 + def visit_self_node(node); end + + # Dispatch enter and leave events for ShareableConstantNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1135 + def visit_shareable_constant_node(node); end + + # Dispatch enter and leave events for SingletonClassNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1143 + def visit_singleton_class_node(node); end + + # Dispatch enter and leave events for SourceEncodingNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1151 + def visit_source_encoding_node(node); end + + # Dispatch enter and leave events for SourceFileNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1159 + def visit_source_file_node(node); end + + # Dispatch enter and leave events for SourceLineNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1167 + def visit_source_line_node(node); end + + # Dispatch enter and leave events for SplatNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1175 + def visit_splat_node(node); end + + # Dispatch enter and leave events for StatementsNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1183 + def visit_statements_node(node); end + + # Dispatch enter and leave events for StringNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1191 + def visit_string_node(node); end + + # Dispatch enter and leave events for SuperNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1199 + def visit_super_node(node); end + + # Dispatch enter and leave events for SymbolNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1207 + def visit_symbol_node(node); end + + # Dispatch enter and leave events for TrueNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1215 + def visit_true_node(node); end + + # Dispatch enter and leave events for UndefNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1223 + def visit_undef_node(node); end + + # Dispatch enter and leave events for UnlessNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1231 + def visit_unless_node(node); end + + # Dispatch enter and leave events for UntilNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1239 + def visit_until_node(node); end + + # Dispatch enter and leave events for WhenNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1247 + def visit_when_node(node); end + + # Dispatch enter and leave events for WhileNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1255 + def visit_while_node(node); end + + # Dispatch enter and leave events for XStringNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1263 + def visit_x_string_node(node); end + + # Dispatch enter and leave events for YieldNode nodes and continue + # walking the tree. + # + # source://prism//lib/prism/dispatcher.rb#1271 + def visit_yield_node(node); end +end + +# source://prism//lib/prism/dispatcher.rb#1277 +class Prism::Dispatcher::DispatchOnce < ::Prism::Visitor + # @return [DispatchOnce] a new instance of DispatchOnce + # + # source://prism//lib/prism/dispatcher.rb#1280 + def initialize(listeners); end + + # Returns the value of attribute listeners. + # + # source://prism//lib/prism/dispatcher.rb#1278 + def listeners; end + + # Dispatch enter and leave events for AliasGlobalVariableNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1285 + def visit_alias_global_variable_node(node); end + + # Dispatch enter and leave events for AliasMethodNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1291 + def visit_alias_method_node(node); end + + # Dispatch enter and leave events for AlternationPatternNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1297 + def visit_alternation_pattern_node(node); end + + # Dispatch enter and leave events for AndNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1303 + def visit_and_node(node); end + + # Dispatch enter and leave events for ArgumentsNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1309 + def visit_arguments_node(node); end + + # Dispatch enter and leave events for ArrayNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1315 + def visit_array_node(node); end + + # Dispatch enter and leave events for ArrayPatternNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1321 + def visit_array_pattern_node(node); end + + # Dispatch enter and leave events for AssocNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1327 + def visit_assoc_node(node); end + + # Dispatch enter and leave events for AssocSplatNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1333 + def visit_assoc_splat_node(node); end + + # Dispatch enter and leave events for BackReferenceReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1339 + def visit_back_reference_read_node(node); end + + # Dispatch enter and leave events for BeginNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1345 + def visit_begin_node(node); end + + # Dispatch enter and leave events for BlockArgumentNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1351 + def visit_block_argument_node(node); end + + # Dispatch enter and leave events for BlockLocalVariableNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1357 + def visit_block_local_variable_node(node); end + + # Dispatch enter and leave events for BlockNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1363 + def visit_block_node(node); end + + # Dispatch enter and leave events for BlockParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1369 + def visit_block_parameter_node(node); end + + # Dispatch enter and leave events for BlockParametersNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1375 + def visit_block_parameters_node(node); end + + # Dispatch enter and leave events for BreakNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1381 + def visit_break_node(node); end + + # Dispatch enter and leave events for CallAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1387 + def visit_call_and_write_node(node); end + + # Dispatch enter and leave events for CallNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1393 + def visit_call_node(node); end + + # Dispatch enter and leave events for CallOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1399 + def visit_call_operator_write_node(node); end + + # Dispatch enter and leave events for CallOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1405 + def visit_call_or_write_node(node); end + + # Dispatch enter and leave events for CallTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1411 + def visit_call_target_node(node); end + + # Dispatch enter and leave events for CapturePatternNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1417 + def visit_capture_pattern_node(node); end + + # Dispatch enter and leave events for CaseMatchNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1423 + def visit_case_match_node(node); end + + # Dispatch enter and leave events for CaseNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1429 + def visit_case_node(node); end + + # Dispatch enter and leave events for ClassNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1435 + def visit_class_node(node); end + + # Dispatch enter and leave events for ClassVariableAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1441 + def visit_class_variable_and_write_node(node); end + + # Dispatch enter and leave events for ClassVariableOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1447 + def visit_class_variable_operator_write_node(node); end + + # Dispatch enter and leave events for ClassVariableOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1453 + def visit_class_variable_or_write_node(node); end + + # Dispatch enter and leave events for ClassVariableReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1459 + def visit_class_variable_read_node(node); end + + # Dispatch enter and leave events for ClassVariableTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1465 + def visit_class_variable_target_node(node); end + + # Dispatch enter and leave events for ClassVariableWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1471 + def visit_class_variable_write_node(node); end + + # Dispatch enter and leave events for ConstantAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1477 + def visit_constant_and_write_node(node); end + + # Dispatch enter and leave events for ConstantOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1483 + def visit_constant_operator_write_node(node); end + + # Dispatch enter and leave events for ConstantOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1489 + def visit_constant_or_write_node(node); end + + # Dispatch enter and leave events for ConstantPathAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1495 + def visit_constant_path_and_write_node(node); end + + # Dispatch enter and leave events for ConstantPathNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1501 + def visit_constant_path_node(node); end + + # Dispatch enter and leave events for ConstantPathOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1507 + def visit_constant_path_operator_write_node(node); end + + # Dispatch enter and leave events for ConstantPathOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1513 + def visit_constant_path_or_write_node(node); end + + # Dispatch enter and leave events for ConstantPathTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1519 + def visit_constant_path_target_node(node); end + + # Dispatch enter and leave events for ConstantPathWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1525 + def visit_constant_path_write_node(node); end + + # Dispatch enter and leave events for ConstantReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1531 + def visit_constant_read_node(node); end + + # Dispatch enter and leave events for ConstantTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1537 + def visit_constant_target_node(node); end + + # Dispatch enter and leave events for ConstantWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1543 + def visit_constant_write_node(node); end + + # Dispatch enter and leave events for DefNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1549 + def visit_def_node(node); end + + # Dispatch enter and leave events for DefinedNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1555 + def visit_defined_node(node); end + + # Dispatch enter and leave events for ElseNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1561 + def visit_else_node(node); end + + # Dispatch enter and leave events for EmbeddedStatementsNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1567 + def visit_embedded_statements_node(node); end + + # Dispatch enter and leave events for EmbeddedVariableNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1573 + def visit_embedded_variable_node(node); end + + # Dispatch enter and leave events for EnsureNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1579 + def visit_ensure_node(node); end + + # Dispatch enter and leave events for FalseNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1585 + def visit_false_node(node); end + + # Dispatch enter and leave events for FindPatternNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1591 + def visit_find_pattern_node(node); end + + # Dispatch enter and leave events for FlipFlopNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1597 + def visit_flip_flop_node(node); end + + # Dispatch enter and leave events for FloatNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1603 + def visit_float_node(node); end + + # Dispatch enter and leave events for ForNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1609 + def visit_for_node(node); end + + # Dispatch enter and leave events for ForwardingArgumentsNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1615 + def visit_forwarding_arguments_node(node); end + + # Dispatch enter and leave events for ForwardingParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1621 + def visit_forwarding_parameter_node(node); end + + # Dispatch enter and leave events for ForwardingSuperNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1627 + def visit_forwarding_super_node(node); end + + # Dispatch enter and leave events for GlobalVariableAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1633 + def visit_global_variable_and_write_node(node); end + + # Dispatch enter and leave events for GlobalVariableOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1639 + def visit_global_variable_operator_write_node(node); end + + # Dispatch enter and leave events for GlobalVariableOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1645 + def visit_global_variable_or_write_node(node); end + + # Dispatch enter and leave events for GlobalVariableReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1651 + def visit_global_variable_read_node(node); end + + # Dispatch enter and leave events for GlobalVariableTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1657 + def visit_global_variable_target_node(node); end + + # Dispatch enter and leave events for GlobalVariableWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1663 + def visit_global_variable_write_node(node); end + + # Dispatch enter and leave events for HashNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1669 + def visit_hash_node(node); end + + # Dispatch enter and leave events for HashPatternNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1675 + def visit_hash_pattern_node(node); end + + # Dispatch enter and leave events for IfNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1681 + def visit_if_node(node); end + + # Dispatch enter and leave events for ImaginaryNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1687 + def visit_imaginary_node(node); end + + # Dispatch enter and leave events for ImplicitNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1693 + def visit_implicit_node(node); end + + # Dispatch enter and leave events for ImplicitRestNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1699 + def visit_implicit_rest_node(node); end + + # Dispatch enter and leave events for InNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1705 + def visit_in_node(node); end + + # Dispatch enter and leave events for IndexAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1711 + def visit_index_and_write_node(node); end + + # Dispatch enter and leave events for IndexOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1717 + def visit_index_operator_write_node(node); end + + # Dispatch enter and leave events for IndexOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1723 + def visit_index_or_write_node(node); end + + # Dispatch enter and leave events for IndexTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1729 + def visit_index_target_node(node); end + + # Dispatch enter and leave events for InstanceVariableAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1735 + def visit_instance_variable_and_write_node(node); end + + # Dispatch enter and leave events for InstanceVariableOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1741 + def visit_instance_variable_operator_write_node(node); end + + # Dispatch enter and leave events for InstanceVariableOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1747 + def visit_instance_variable_or_write_node(node); end + + # Dispatch enter and leave events for InstanceVariableReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1753 + def visit_instance_variable_read_node(node); end + + # Dispatch enter and leave events for InstanceVariableTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1759 + def visit_instance_variable_target_node(node); end + + # Dispatch enter and leave events for InstanceVariableWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1765 + def visit_instance_variable_write_node(node); end + + # Dispatch enter and leave events for IntegerNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1771 + def visit_integer_node(node); end + + # Dispatch enter and leave events for InterpolatedMatchLastLineNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1777 + def visit_interpolated_match_last_line_node(node); end + + # Dispatch enter and leave events for InterpolatedRegularExpressionNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1783 + def visit_interpolated_regular_expression_node(node); end + + # Dispatch enter and leave events for InterpolatedStringNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1789 + def visit_interpolated_string_node(node); end + + # Dispatch enter and leave events for InterpolatedSymbolNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1795 + def visit_interpolated_symbol_node(node); end + + # Dispatch enter and leave events for InterpolatedXStringNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1801 + def visit_interpolated_x_string_node(node); end + + # Dispatch enter and leave events for ItLocalVariableReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1807 + def visit_it_local_variable_read_node(node); end + + # Dispatch enter and leave events for ItParametersNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1813 + def visit_it_parameters_node(node); end + + # Dispatch enter and leave events for KeywordHashNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1819 + def visit_keyword_hash_node(node); end + + # Dispatch enter and leave events for KeywordRestParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1825 + def visit_keyword_rest_parameter_node(node); end + + # Dispatch enter and leave events for LambdaNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1831 + def visit_lambda_node(node); end + + # Dispatch enter and leave events for LocalVariableAndWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1837 + def visit_local_variable_and_write_node(node); end + + # Dispatch enter and leave events for LocalVariableOperatorWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1843 + def visit_local_variable_operator_write_node(node); end + + # Dispatch enter and leave events for LocalVariableOrWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1849 + def visit_local_variable_or_write_node(node); end + + # Dispatch enter and leave events for LocalVariableReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1855 + def visit_local_variable_read_node(node); end + + # Dispatch enter and leave events for LocalVariableTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1861 + def visit_local_variable_target_node(node); end + + # Dispatch enter and leave events for LocalVariableWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1867 + def visit_local_variable_write_node(node); end + + # Dispatch enter and leave events for MatchLastLineNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1873 + def visit_match_last_line_node(node); end + + # Dispatch enter and leave events for MatchPredicateNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1879 + def visit_match_predicate_node(node); end + + # Dispatch enter and leave events for MatchRequiredNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1885 + def visit_match_required_node(node); end + + # Dispatch enter and leave events for MatchWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1891 + def visit_match_write_node(node); end + + # Dispatch enter and leave events for MissingNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1897 + def visit_missing_node(node); end + + # Dispatch enter and leave events for ModuleNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1903 + def visit_module_node(node); end + + # Dispatch enter and leave events for MultiTargetNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1909 + def visit_multi_target_node(node); end + + # Dispatch enter and leave events for MultiWriteNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1915 + def visit_multi_write_node(node); end + + # Dispatch enter and leave events for NextNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1921 + def visit_next_node(node); end + + # Dispatch enter and leave events for NilNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1927 + def visit_nil_node(node); end + + # Dispatch enter and leave events for NoKeywordsParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1933 + def visit_no_keywords_parameter_node(node); end + + # Dispatch enter and leave events for NumberedParametersNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1939 + def visit_numbered_parameters_node(node); end + + # Dispatch enter and leave events for NumberedReferenceReadNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1945 + def visit_numbered_reference_read_node(node); end + + # Dispatch enter and leave events for OptionalKeywordParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1951 + def visit_optional_keyword_parameter_node(node); end + + # Dispatch enter and leave events for OptionalParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1957 + def visit_optional_parameter_node(node); end + + # Dispatch enter and leave events for OrNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1963 + def visit_or_node(node); end + + # Dispatch enter and leave events for ParametersNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1969 + def visit_parameters_node(node); end + + # Dispatch enter and leave events for ParenthesesNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1975 + def visit_parentheses_node(node); end + + # Dispatch enter and leave events for PinnedExpressionNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1981 + def visit_pinned_expression_node(node); end + + # Dispatch enter and leave events for PinnedVariableNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1987 + def visit_pinned_variable_node(node); end + + # Dispatch enter and leave events for PostExecutionNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1993 + def visit_post_execution_node(node); end + + # Dispatch enter and leave events for PreExecutionNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#1999 + def visit_pre_execution_node(node); end + + # Dispatch enter and leave events for ProgramNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2005 + def visit_program_node(node); end + + # Dispatch enter and leave events for RangeNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2011 + def visit_range_node(node); end + + # Dispatch enter and leave events for RationalNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2017 + def visit_rational_node(node); end + + # Dispatch enter and leave events for RedoNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2023 + def visit_redo_node(node); end + + # Dispatch enter and leave events for RegularExpressionNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2029 + def visit_regular_expression_node(node); end + + # Dispatch enter and leave events for RequiredKeywordParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2035 + def visit_required_keyword_parameter_node(node); end + + # Dispatch enter and leave events for RequiredParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2041 + def visit_required_parameter_node(node); end + + # Dispatch enter and leave events for RescueModifierNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2047 + def visit_rescue_modifier_node(node); end + + # Dispatch enter and leave events for RescueNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2053 + def visit_rescue_node(node); end + + # Dispatch enter and leave events for RestParameterNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2059 + def visit_rest_parameter_node(node); end + + # Dispatch enter and leave events for RetryNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2065 + def visit_retry_node(node); end + + # Dispatch enter and leave events for ReturnNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2071 + def visit_return_node(node); end + + # Dispatch enter and leave events for SelfNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2077 + def visit_self_node(node); end + + # Dispatch enter and leave events for ShareableConstantNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2083 + def visit_shareable_constant_node(node); end + + # Dispatch enter and leave events for SingletonClassNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2089 + def visit_singleton_class_node(node); end + + # Dispatch enter and leave events for SourceEncodingNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2095 + def visit_source_encoding_node(node); end + + # Dispatch enter and leave events for SourceFileNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2101 + def visit_source_file_node(node); end + + # Dispatch enter and leave events for SourceLineNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2107 + def visit_source_line_node(node); end + + # Dispatch enter and leave events for SplatNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2113 + def visit_splat_node(node); end + + # Dispatch enter and leave events for StatementsNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2119 + def visit_statements_node(node); end + + # Dispatch enter and leave events for StringNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2125 + def visit_string_node(node); end + + # Dispatch enter and leave events for SuperNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2131 + def visit_super_node(node); end + + # Dispatch enter and leave events for SymbolNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2137 + def visit_symbol_node(node); end + + # Dispatch enter and leave events for TrueNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2143 + def visit_true_node(node); end + + # Dispatch enter and leave events for UndefNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2149 + def visit_undef_node(node); end + + # Dispatch enter and leave events for UnlessNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2155 + def visit_unless_node(node); end + + # Dispatch enter and leave events for UntilNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2161 + def visit_until_node(node); end + + # Dispatch enter and leave events for WhenNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2167 + def visit_when_node(node); end + + # Dispatch enter and leave events for WhileNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2173 + def visit_while_node(node); end + + # Dispatch enter and leave events for XStringNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2179 + def visit_x_string_node(node); end + + # Dispatch enter and leave events for YieldNode nodes. + # + # source://prism//lib/prism/dispatcher.rb#2185 + def visit_yield_node(node); end +end + +# This visitor provides the ability to call Node#to_dot, which converts a +# subtree into a graphviz dot graph. +# +# source://prism//lib/prism/dot_visitor.rb#14 +class Prism::DotVisitor < ::Prism::Visitor + # Initialize a new dot visitor. + # + # @return [DotVisitor] a new instance of DotVisitor + # + # source://prism//lib/prism/dot_visitor.rb#106 + def initialize; end + + # The digraph that is being built. + # + # source://prism//lib/prism/dot_visitor.rb#103 + def digraph; end + + # Convert this visitor into a graphviz dot graph string. + # + # source://prism//lib/prism/dot_visitor.rb#111 + def to_dot; end + + # Visit a AliasGlobalVariableNode node. + # + # source://prism//lib/prism/dot_visitor.rb#116 + def visit_alias_global_variable_node(node); end + + # Visit a AliasMethodNode node. + # + # source://prism//lib/prism/dot_visitor.rb#141 + def visit_alias_method_node(node); end + + # Visit a AlternationPatternNode node. + # + # source://prism//lib/prism/dot_visitor.rb#166 + def visit_alternation_pattern_node(node); end + + # Visit a AndNode node. + # + # source://prism//lib/prism/dot_visitor.rb#191 + def visit_and_node(node); end + + # Visit a ArgumentsNode node. + # + # source://prism//lib/prism/dot_visitor.rb#216 + def visit_arguments_node(node); end + + # Visit a ArrayNode node. + # + # source://prism//lib/prism/dot_visitor.rb#246 + def visit_array_node(node); end + + # Visit a ArrayPatternNode node. + # + # source://prism//lib/prism/dot_visitor.rb#286 + def visit_array_pattern_node(node); end + + # Visit a AssocNode node. + # + # source://prism//lib/prism/dot_visitor.rb#348 + def visit_assoc_node(node); end + + # Visit a AssocSplatNode node. + # + # source://prism//lib/prism/dot_visitor.rb#375 + def visit_assoc_splat_node(node); end + + # Visit a BackReferenceReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#398 + def visit_back_reference_read_node(node); end + + # Visit a BeginNode node. + # + # source://prism//lib/prism/dot_visitor.rb#415 + def visit_begin_node(node); end + + # Visit a BlockArgumentNode node. + # + # source://prism//lib/prism/dot_visitor.rb#463 + def visit_block_argument_node(node); end + + # Visit a BlockLocalVariableNode node. + # + # source://prism//lib/prism/dot_visitor.rb#486 + def visit_block_local_variable_node(node); end + + # Visit a BlockNode node. + # + # source://prism//lib/prism/dot_visitor.rb#506 + def visit_block_node(node); end + + # Visit a BlockParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#541 + def visit_block_parameter_node(node); end + + # Visit a BlockParametersNode node. + # + # source://prism//lib/prism/dot_visitor.rb#569 + def visit_block_parameters_node(node); end + + # Visit a BreakNode node. + # + # source://prism//lib/prism/dot_visitor.rb#612 + def visit_break_node(node); end + + # Visit a CallAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#635 + def visit_call_and_write_node(node); end + + # Visit a CallNode node. + # + # source://prism//lib/prism/dot_visitor.rb#681 + def visit_call_node(node); end + + # Visit a CallOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#739 + def visit_call_operator_write_node(node); end + + # Visit a CallOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#788 + def visit_call_or_write_node(node); end + + # Visit a CallTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#834 + def visit_call_target_node(node); end + + # Visit a CapturePatternNode node. + # + # source://prism//lib/prism/dot_visitor.rb#864 + def visit_capture_pattern_node(node); end + + # Visit a CaseMatchNode node. + # + # source://prism//lib/prism/dot_visitor.rb#889 + def visit_case_match_node(node); end + + # Visit a CaseNode node. + # + # source://prism//lib/prism/dot_visitor.rb#934 + def visit_case_node(node); end + + # Visit a ClassNode node. + # + # source://prism//lib/prism/dot_visitor.rb#979 + def visit_class_node(node); end + + # Visit a ClassVariableAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1026 + def visit_class_variable_and_write_node(node); end + + # Visit a ClassVariableOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1053 + def visit_class_variable_operator_write_node(node); end + + # Visit a ClassVariableOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1083 + def visit_class_variable_or_write_node(node); end + + # Visit a ClassVariableReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1110 + def visit_class_variable_read_node(node); end + + # Visit a ClassVariableTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1127 + def visit_class_variable_target_node(node); end + + # Visit a ClassVariableWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1144 + def visit_class_variable_write_node(node); end + + # Visit a ConstantAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1171 + def visit_constant_and_write_node(node); end + + # Visit a ConstantOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1198 + def visit_constant_operator_write_node(node); end + + # Visit a ConstantOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1228 + def visit_constant_or_write_node(node); end + + # Visit a ConstantPathAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1255 + def visit_constant_path_and_write_node(node); end + + # Visit a ConstantPathNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1280 + def visit_constant_path_node(node); end + + # Visit a ConstantPathOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1309 + def visit_constant_path_operator_write_node(node); end + + # Visit a ConstantPathOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1337 + def visit_constant_path_or_write_node(node); end + + # Visit a ConstantPathTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1362 + def visit_constant_path_target_node(node); end + + # Visit a ConstantPathWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1391 + def visit_constant_path_write_node(node); end + + # Visit a ConstantReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1416 + def visit_constant_read_node(node); end + + # Visit a ConstantTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1433 + def visit_constant_target_node(node); end + + # Visit a ConstantWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1450 + def visit_constant_write_node(node); end + + # Visit a DefNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1477 + def visit_def_node(node); end + + # Visit a DefinedNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1546 + def visit_defined_node(node); end + + # Visit a ElseNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1577 + def visit_else_node(node); end + + # Visit a EmbeddedStatementsNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1605 + def visit_embedded_statements_node(node); end + + # Visit a EmbeddedVariableNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1631 + def visit_embedded_variable_node(node); end + + # Visit a EnsureNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1652 + def visit_ensure_node(node); end + + # Visit a FalseNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1678 + def visit_false_node(node); end + + # Visit a FindPatternNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1692 + def visit_find_pattern_node(node); end + + # Visit a FlipFlopNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1743 + def visit_flip_flop_node(node); end + + # Visit a FloatNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1775 + def visit_float_node(node); end + + # Visit a ForNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1792 + def visit_for_node(node); end + + # Visit a ForwardingArgumentsNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1834 + def visit_forwarding_arguments_node(node); end + + # Visit a ForwardingParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1848 + def visit_forwarding_parameter_node(node); end + + # Visit a ForwardingSuperNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1862 + def visit_forwarding_super_node(node); end + + # Visit a GlobalVariableAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1882 + def visit_global_variable_and_write_node(node); end + + # Visit a GlobalVariableOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1909 + def visit_global_variable_operator_write_node(node); end + + # Visit a GlobalVariableOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1939 + def visit_global_variable_or_write_node(node); end + + # Visit a GlobalVariableReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1966 + def visit_global_variable_read_node(node); end + + # Visit a GlobalVariableTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#1983 + def visit_global_variable_target_node(node); end + + # Visit a GlobalVariableWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2000 + def visit_global_variable_write_node(node); end + + # Visit a HashNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2027 + def visit_hash_node(node); end + + # Visit a HashPatternNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2060 + def visit_hash_pattern_node(node); end + + # Visit a IfNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2109 + def visit_if_node(node); end + + # Visit a ImaginaryNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2154 + def visit_imaginary_node(node); end + + # Visit a ImplicitNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2172 + def visit_implicit_node(node); end + + # Visit a ImplicitRestNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2190 + def visit_implicit_rest_node(node); end + + # Visit a InNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2204 + def visit_in_node(node); end + + # Visit a IndexAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2236 + def visit_index_and_write_node(node); end + + # Visit a IndexOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2289 + def visit_index_operator_write_node(node); end + + # Visit a IndexOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2345 + def visit_index_or_write_node(node); end + + # Visit a IndexTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2398 + def visit_index_target_node(node); end + + # Visit a InstanceVariableAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2437 + def visit_instance_variable_and_write_node(node); end + + # Visit a InstanceVariableOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2464 + def visit_instance_variable_operator_write_node(node); end + + # Visit a InstanceVariableOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2494 + def visit_instance_variable_or_write_node(node); end + + # Visit a InstanceVariableReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2521 + def visit_instance_variable_read_node(node); end + + # Visit a InstanceVariableTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2538 + def visit_instance_variable_target_node(node); end + + # Visit a InstanceVariableWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2555 + def visit_instance_variable_write_node(node); end + + # Visit a IntegerNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2582 + def visit_integer_node(node); end + + # Visit a InterpolatedMatchLastLineNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2602 + def visit_interpolated_match_last_line_node(node); end + + # Visit a InterpolatedRegularExpressionNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2638 + def visit_interpolated_regular_expression_node(node); end + + # Visit a InterpolatedStringNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2674 + def visit_interpolated_string_node(node); end + + # Visit a InterpolatedSymbolNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2714 + def visit_interpolated_symbol_node(node); end + + # Visit a InterpolatedXStringNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2751 + def visit_interpolated_x_string_node(node); end + + # Visit a ItLocalVariableReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2784 + def visit_it_local_variable_read_node(node); end + + # Visit a ItParametersNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2798 + def visit_it_parameters_node(node); end + + # Visit a KeywordHashNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2812 + def visit_keyword_hash_node(node); end + + # Visit a KeywordRestParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2842 + def visit_keyword_rest_parameter_node(node); end + + # Visit a LambdaNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2870 + def visit_lambda_node(node); end + + # Visit a LocalVariableAndWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2908 + def visit_local_variable_and_write_node(node); end + + # Visit a LocalVariableOperatorWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2938 + def visit_local_variable_operator_write_node(node); end + + # Visit a LocalVariableOrWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#2971 + def visit_local_variable_or_write_node(node); end + + # Visit a LocalVariableReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3001 + def visit_local_variable_read_node(node); end + + # Visit a LocalVariableTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3021 + def visit_local_variable_target_node(node); end + + # Visit a LocalVariableWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3041 + def visit_local_variable_write_node(node); end + + # Visit a MatchLastLineNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3071 + def visit_match_last_line_node(node); end + + # Visit a MatchPredicateNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3100 + def visit_match_predicate_node(node); end + + # Visit a MatchRequiredNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3125 + def visit_match_required_node(node); end + + # Visit a MatchWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3150 + def visit_match_write_node(node); end + + # Visit a MissingNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3181 + def visit_missing_node(node); end + + # Visit a ModuleNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3195 + def visit_module_node(node); end + + # Visit a MultiTargetNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3231 + def visit_multi_target_node(node); end + + # Visit a MultiWriteNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3287 + def visit_multi_write_node(node); end + + # Visit a NextNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3350 + def visit_next_node(node); end + + # Visit a NilNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3373 + def visit_nil_node(node); end + + # Visit a NoKeywordsParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3387 + def visit_no_keywords_parameter_node(node); end + + # Visit a NumberedParametersNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3407 + def visit_numbered_parameters_node(node); end + + # Visit a NumberedReferenceReadNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3424 + def visit_numbered_reference_read_node(node); end + + # Visit a OptionalKeywordParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3441 + def visit_optional_keyword_parameter_node(node); end + + # Visit a OptionalParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3468 + def visit_optional_parameter_node(node); end + + # Visit a OrNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3498 + def visit_or_node(node); end + + # Visit a ParametersNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3523 + def visit_parameters_node(node); end + + # Visit a ParenthesesNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3607 + def visit_parentheses_node(node); end + + # Visit a PinnedExpressionNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3633 + def visit_pinned_expression_node(node); end + + # Visit a PinnedVariableNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3660 + def visit_pinned_variable_node(node); end + + # Visit a PostExecutionNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3681 + def visit_post_execution_node(node); end + + # Visit a PreExecutionNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3710 + def visit_pre_execution_node(node); end + + # Visit a ProgramNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3739 + def visit_program_node(node); end + + # Visit a RangeNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3760 + def visit_range_node(node); end + + # Visit a RationalNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3792 + def visit_rational_node(node); end + + # Visit a RedoNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3815 + def visit_redo_node(node); end + + # Visit a RegularExpressionNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3829 + def visit_regular_expression_node(node); end + + # Visit a RequiredKeywordParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3858 + def visit_required_keyword_parameter_node(node); end + + # Visit a RequiredParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3881 + def visit_required_parameter_node(node); end + + # Visit a RescueModifierNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3901 + def visit_rescue_modifier_node(node); end + + # Visit a RescueNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3926 + def visit_rescue_node(node); end + + # Visit a RestParameterNode node. + # + # source://prism//lib/prism/dot_visitor.rb#3979 + def visit_rest_parameter_node(node); end + + # Visit a RetryNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4007 + def visit_retry_node(node); end + + # Visit a ReturnNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4021 + def visit_return_node(node); end + + # Visit a SelfNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4047 + def visit_self_node(node); end + + # Visit a ShareableConstantNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4061 + def visit_shareable_constant_node(node); end + + # Visit a SingletonClassNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4082 + def visit_singleton_class_node(node); end + + # Visit a SourceEncodingNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4118 + def visit_source_encoding_node(node); end + + # Visit a SourceFileNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4132 + def visit_source_file_node(node); end + + # Visit a SourceLineNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4152 + def visit_source_line_node(node); end + + # Visit a SplatNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4166 + def visit_splat_node(node); end + + # Visit a StatementsNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4189 + def visit_statements_node(node); end + + # Visit a StringNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4216 + def visit_string_node(node); end + + # Visit a SuperNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4249 + def visit_super_node(node); end + + # Visit a SymbolNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4288 + def visit_symbol_node(node); end + + # Visit a TrueNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4323 + def visit_true_node(node); end + + # Visit a UndefNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4337 + def visit_undef_node(node); end + + # Visit a UnlessNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4367 + def visit_unless_node(node); end + + # Visit a UntilNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4410 + def visit_until_node(node); end + + # Visit a WhenNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4445 + def visit_when_node(node); end + + # Visit a WhileNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4486 + def visit_while_node(node); end + + # Visit a XStringNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4521 + def visit_x_string_node(node); end + + # Visit a YieldNode node. + # + # source://prism//lib/prism/dot_visitor.rb#4550 + def visit_yield_node(node); end + + private + + # Inspect a node that has arguments_node_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4596 + def arguments_node_flags_inspect(node); end + + # Inspect a node that has array_node_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4605 + def array_node_flags_inspect(node); end + + # Inspect a node that has call_node_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4613 + def call_node_flags_inspect(node); end + + # Inspect a node that has encoding_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4624 + def encoding_flags_inspect(node); end + + # Inspect a node that has integer_base_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4633 + def integer_base_flags_inspect(node); end + + # Inspect a node that has interpolated_string_node_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4644 + def interpolated_string_node_flags_inspect(node); end + + # Inspect a node that has keyword_hash_node_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4653 + def keyword_hash_node_flags_inspect(node); end + + # Inspect a location to display the start and end line and column numbers. + # + # source://prism//lib/prism/dot_visitor.rb#4590 + def location_inspect(location); end + + # Inspect a node that has loop_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4661 + def loop_flags_inspect(node); end + + # Generate a unique node ID for a node throughout the digraph. + # + # source://prism//lib/prism/dot_visitor.rb#4585 + def node_id(node); end + + # Inspect a node that has parameter_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4669 + def parameter_flags_inspect(node); end + + # Inspect a node that has range_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4677 + def range_flags_inspect(node); end + + # Inspect a node that has regular_expression_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4685 + def regular_expression_flags_inspect(node); end + + # Inspect a node that has return_node_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4703 + def return_node_flags_inspect(node); end + + # Inspect a node that has shareable_constant_node_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4711 + def shareable_constant_node_flags_inspect(node); end + + # Inspect a node that has string_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4721 + def string_flags_inspect(node); end + + # Inspect a node that has symbol_flags flags to display the flags as a + # comma-separated list. + # + # source://prism//lib/prism/dot_visitor.rb#4732 + def symbol_flags_inspect(node); end +end + +# source://prism//lib/prism/dot_visitor.rb#59 +class Prism::DotVisitor::Digraph + # @return [Digraph] a new instance of Digraph + # + # source://prism//lib/prism/dot_visitor.rb#62 + def initialize; end + + # source://prism//lib/prism/dot_visitor.rb#76 + def edge(value); end + + # Returns the value of attribute edges. + # + # source://prism//lib/prism/dot_visitor.rb#60 + def edges; end + + # source://prism//lib/prism/dot_visitor.rb#68 + def node(value); end + + # Returns the value of attribute nodes. + # + # source://prism//lib/prism/dot_visitor.rb#60 + def nodes; end + + # source://prism//lib/prism/dot_visitor.rb#80 + def to_dot; end + + # source://prism//lib/prism/dot_visitor.rb#72 + def waypoint(value); end + + # Returns the value of attribute waypoints. + # + # source://prism//lib/prism/dot_visitor.rb#60 + def waypoints; end +end + +# source://prism//lib/prism/dot_visitor.rb#15 +class Prism::DotVisitor::Field + # @return [Field] a new instance of Field + # + # source://prism//lib/prism/dot_visitor.rb#18 + def initialize(name, value, port); end + + # Returns the value of attribute name. + # + # source://prism//lib/prism/dot_visitor.rb#16 + def name; end + + # Returns the value of attribute port. + # + # source://prism//lib/prism/dot_visitor.rb#16 + def port; end + + # source://prism//lib/prism/dot_visitor.rb#24 + def to_dot; end + + # Returns the value of attribute value. + # + # source://prism//lib/prism/dot_visitor.rb#16 + def value; end +end + +# source://prism//lib/prism/dot_visitor.rb#33 +class Prism::DotVisitor::Table + # @return [Table] a new instance of Table + # + # source://prism//lib/prism/dot_visitor.rb#36 + def initialize(name); end + + # source://prism//lib/prism/dot_visitor.rb#41 + def field(name, value = T.unsafe(nil), port: T.unsafe(nil)); end + + # Returns the value of attribute fields. + # + # source://prism//lib/prism/dot_visitor.rb#34 + def fields; end + + # Returns the value of attribute name. + # + # source://prism//lib/prism/dot_visitor.rb#34 + def name; end + + # source://prism//lib/prism/dot_visitor.rb#45 + def to_dot; end +end + +# Represents an `else` clause in a `case`, `if`, or `unless` statement. +# +# if a then b else c end +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#6173 +class Prism::ElseNode < ::Prism::Node + # def initialize: (Location else_keyword_loc, StatementsNode? statements, Location? end_keyword_loc, Location location) -> void + # + # @return [ElseNode] a new instance of ElseNode + # + # source://prism//lib/prism/node.rb#6175 + sig do + params( + source: Prism::Source, + else_keyword_loc: Prism::Location, + statements: T.nilable(Prism::StatementsNode), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, else_keyword_loc, statements, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6286 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6184 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6189 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6201 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6194 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?else_keyword_loc: Location, ?statements: StatementsNode?, ?end_keyword_loc: Location?, ?location: Location) -> ElseNode + # + # source://prism//lib/prism/node.rb#6206 + sig do + params( + else_keyword_loc: Prism::Location, + statements: T.nilable(Prism::StatementsNode), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::ElseNode) + end + def copy(else_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6189 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { else_keyword_loc: Location, statements: StatementsNode?, end_keyword_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#6214 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def else_keyword: () -> String + # + # source://prism//lib/prism/node.rb#6242 + sig { returns(String) } + def else_keyword; end + + # attr_reader else_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#6219 + sig { returns(Prism::Location) } + def else_keyword_loc; end + + # def end_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#6247 + sig { returns(T.nilable(String)) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location? + # + # source://prism//lib/prism/node.rb#6229 + sig { returns(T.nilable(Prism::Location)) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6252 + sig { override.returns(String) } + def inspect; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#6226 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6270 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6280 + def type; end + end +end + +# EmbDocComment objects correspond to comments that are surrounded by =begin +# and =end. +# +# source://prism//lib/prism/parse_result.rb#403 +class Prism::EmbDocComment < ::Prism::Comment + # Returns a string representation of this comment. + # + # source://prism//lib/prism/parse_result.rb#410 + sig { returns(String) } + def inspect; end + + # This can only be true for inline comments. + # + # @return [Boolean] + # + # source://prism//lib/prism/parse_result.rb#405 + sig { override.returns(T::Boolean) } + def trailing?; end +end + +# Represents an interpolated set of statements. +# +# "foo #{bar}" +# ^^^^^^ +# +# source://prism//lib/prism/node.rb#6298 +class Prism::EmbeddedStatementsNode < ::Prism::Node + # def initialize: (Location opening_loc, StatementsNode? statements, Location closing_loc, Location location) -> void + # + # @return [EmbeddedStatementsNode] a new instance of EmbeddedStatementsNode + # + # source://prism//lib/prism/node.rb#6300 + sig do + params( + source: Prism::Source, + opening_loc: Prism::Location, + statements: T.nilable(Prism::StatementsNode), + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, opening_loc, statements, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6405 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6309 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6314 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#6366 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#6354 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6326 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6319 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?opening_loc: Location, ?statements: StatementsNode?, ?closing_loc: Location, ?location: Location) -> EmbeddedStatementsNode + # + # source://prism//lib/prism/node.rb#6331 + sig do + params( + opening_loc: Prism::Location, + statements: T.nilable(Prism::StatementsNode), + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::EmbeddedStatementsNode) + end + def copy(opening_loc: T.unsafe(nil), statements: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6314 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location, statements: StatementsNode?, closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#6339 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6371 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#6361 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#6344 + sig { returns(Prism::Location) } + def opening_loc; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#6351 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6389 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6399 + def type; end + end +end + +# Represents an interpolated variable. +# +# "foo #@bar" +# ^^^^^ +# +# source://prism//lib/prism/node.rb#6417 +class Prism::EmbeddedVariableNode < ::Prism::Node + # def initialize: (Location operator_loc, Prism::node variable, Location location) -> void + # + # @return [EmbeddedVariableNode] a new instance of EmbeddedVariableNode + # + # source://prism//lib/prism/node.rb#6419 + sig do + params( + source: Prism::Source, + operator_loc: Prism::Location, + variable: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, operator_loc, variable, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6509 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6427 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6432 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6442 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6437 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?operator_loc: Location, ?variable: Prism::node, ?location: Location) -> EmbeddedVariableNode + # + # source://prism//lib/prism/node.rb#6447 + sig do + params( + operator_loc: Prism::Location, + variable: Prism::Node, + location: Prism::Location + ).returns(Prism::EmbeddedVariableNode) + end + def copy(operator_loc: T.unsafe(nil), variable: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6432 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { operator_loc: Location, variable: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#6455 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6475 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#6470 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#6460 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6493 + sig { override.returns(Symbol) } + def type; end + + # attr_reader variable: Prism::node + # + # source://prism//lib/prism/node.rb#6467 + sig { returns(Prism::Node) } + def variable; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6503 + def type; end + end +end + +# Flags for nodes that have unescaped content. +# +# source://prism//lib/prism/node.rb#19157 +module Prism::EncodingFlags; end + +# internal bytes forced the encoding to binary +# +# source://prism//lib/prism/node.rb#19162 +Prism::EncodingFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer) + +# internal bytes forced the encoding to UTF-8 +# +# source://prism//lib/prism/node.rb#19159 +Prism::EncodingFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer) + +# Represents an `ensure` clause in a `begin` statement. +# +# begin +# foo +# ensure +# ^^^^^^ +# bar +# end +# +# source://prism//lib/prism/node.rb#6524 +class Prism::EnsureNode < ::Prism::Node + # def initialize: (Location ensure_keyword_loc, StatementsNode? statements, Location end_keyword_loc, Location location) -> void + # + # @return [EnsureNode] a new instance of EnsureNode + # + # source://prism//lib/prism/node.rb#6526 + sig do + params( + source: Prism::Source, + ensure_keyword_loc: Prism::Location, + statements: T.nilable(Prism::StatementsNode), + end_keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, ensure_keyword_loc, statements, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6631 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6535 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6540 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6552 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6545 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?ensure_keyword_loc: Location, ?statements: StatementsNode?, ?end_keyword_loc: Location, ?location: Location) -> EnsureNode + # + # source://prism//lib/prism/node.rb#6557 + sig do + params( + ensure_keyword_loc: Prism::Location, + statements: T.nilable(Prism::StatementsNode), + end_keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::EnsureNode) + end + def copy(ensure_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6540 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { ensure_keyword_loc: Location, statements: StatementsNode?, end_keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#6565 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String + # + # source://prism//lib/prism/node.rb#6592 + sig { returns(String) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#6580 + sig { returns(Prism::Location) } + def end_keyword_loc; end + + # def ensure_keyword: () -> String + # + # source://prism//lib/prism/node.rb#6587 + sig { returns(String) } + def ensure_keyword; end + + # attr_reader ensure_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#6570 + sig { returns(Prism::Location) } + def ensure_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6597 + sig { override.returns(String) } + def inspect; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#6577 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6615 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6625 + def type; end + end +end + +# Represents the use of the literal `false` keyword. +# +# false +# ^^^^^ +# +# source://prism//lib/prism/node.rb#6643 +class Prism::FalseNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [FalseNode] a new instance of FalseNode + # + # source://prism//lib/prism/node.rb#6645 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6718 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6651 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6656 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6666 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6661 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> FalseNode + # + # source://prism//lib/prism/node.rb#6671 + sig { params(location: Prism::Location).returns(Prism::FalseNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6656 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#6679 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6684 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6702 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6712 + def type; end + end +end + +# Represents a find pattern in pattern matching. +# +# foo in *bar, baz, *qux +# ^^^^^^^^^^^^^^^ +# +# foo in [*bar, baz, *qux] +# ^^^^^^^^^^^^^^^^^ +# +# foo in Foo(*bar, baz, *qux) +# ^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#6733 +class Prism::FindPatternNode < ::Prism::Node + # def initialize: (Prism::node? constant, Prism::node left, Array[Prism::node] requireds, Prism::node right, Location? opening_loc, Location? closing_loc, Location location) -> void + # + # @return [FindPatternNode] a new instance of FindPatternNode + # + # source://prism//lib/prism/node.rb#6735 + sig do + params( + source: Prism::Source, + constant: T.nilable(Prism::Node), + left: Prism::Node, + requireds: T::Array[Prism::Node], + right: Prism::Node, + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, constant, left, requireds, right, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6867 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6747 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6752 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#6828 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#6810 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6767 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6757 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader constant: Prism::node? + # + # source://prism//lib/prism/node.rb#6785 + sig { returns(T.nilable(Prism::Node)) } + def constant; end + + # def copy: (?constant: Prism::node?, ?left: Prism::node, ?requireds: Array[Prism::node], ?right: Prism::node, ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> FindPatternNode + # + # source://prism//lib/prism/node.rb#6772 + sig do + params( + constant: T.nilable(Prism::Node), + left: Prism::Node, + requireds: T::Array[Prism::Node], + right: Prism::Node, + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::FindPatternNode) + end + def copy(constant: T.unsafe(nil), left: T.unsafe(nil), requireds: T.unsafe(nil), right: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6752 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { constant: Prism::node?, left: Prism::node, requireds: Array[Prism::node], right: Prism::node, opening_loc: Location?, closing_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#6780 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6833 + sig { override.returns(String) } + def inspect; end + + # attr_reader left: Prism::node + # + # source://prism//lib/prism/node.rb#6788 + sig { returns(Prism::Node) } + def left; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#6823 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#6797 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # attr_reader requireds: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#6791 + sig { returns(T::Array[Prism::Node]) } + def requireds; end + + # attr_reader right: Prism::node + # + # source://prism//lib/prism/node.rb#6794 + sig { returns(Prism::Node) } + def right; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6851 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6861 + def type; end + end +end + +# Represents the use of the `..` or `...` operators to create flip flops. +# +# baz if foo .. bar +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#6883 +class Prism::FlipFlopNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? left, Prism::node? right, Location operator_loc, Location location) -> void + # + # @return [FlipFlopNode] a new instance of FlipFlopNode + # + # source://prism//lib/prism/node.rb#6885 + sig do + params( + source: Prism::Source, + flags: Integer, + left: T.nilable(Prism::Node), + right: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, left, right, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#6992 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#6895 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6900 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#6913 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#6905 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?left: Prism::node?, ?right: Prism::node?, ?operator_loc: Location, ?location: Location) -> FlipFlopNode + # + # source://prism//lib/prism/node.rb#6918 + sig do + params( + flags: Integer, + left: T.nilable(Prism::Node), + right: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::FlipFlopNode) + end + def copy(flags: T.unsafe(nil), left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#6900 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, left: Prism::node?, right: Prism::node?, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#6926 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def exclude_end?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#6948 + sig { returns(T::Boolean) } + def exclude_end?; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#6958 + sig { override.returns(String) } + def inspect; end + + # attr_reader left: Prism::node? + # + # source://prism//lib/prism/node.rb#6935 + sig { returns(T.nilable(Prism::Node)) } + def left; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#6953 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#6941 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader right: Prism::node? + # + # source://prism//lib/prism/node.rb#6938 + sig { returns(T.nilable(Prism::Node)) } + def right; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6976 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#6931 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#6986 + def type; end + end +end + +# Represents a floating point number literal. +# +# 1.0 +# ^^^ +# +# source://prism//lib/prism/node.rb#7005 +class Prism::FloatNode < ::Prism::Node + # def initialize: (Float value, Location location) -> void + # + # @return [FloatNode] a new instance of FloatNode + # + # source://prism//lib/prism/node.rb#7007 + sig { params(source: Prism::Source, value: Float, location: Prism::Location).void } + def initialize(source, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7084 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7014 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7019 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7029 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7024 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?value: Float, ?location: Location) -> FloatNode + # + # source://prism//lib/prism/node.rb#7034 + sig { params(value: Float, location: Prism::Location).returns(Prism::FloatNode) } + def copy(value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7019 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { value: Float, location: Location } + # + # source://prism//lib/prism/node.rb#7042 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7050 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7068 + sig { override.returns(Symbol) } + def type; end + + # The value of the floating point number as a Float. + # + # source://prism//lib/prism/node.rb#7047 + sig { returns(Float) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7078 + def type; end + end +end + +# Represents the use of the `for` keyword. +# +# for i in a end +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#7094 +class Prism::ForNode < ::Prism::Node + # def initialize: (Prism::node index, Prism::node collection, StatementsNode? statements, Location for_keyword_loc, Location in_keyword_loc, Location? do_keyword_loc, Location end_keyword_loc, Location location) -> void + # + # @return [ForNode] a new instance of ForNode + # + # source://prism//lib/prism/node.rb#7096 + sig do + params( + source: Prism::Source, + index: Prism::Node, + collection: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + for_keyword_loc: Prism::Location, + in_keyword_loc: Prism::Location, + do_keyword_loc: T.nilable(Prism::Location), + end_keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, index, collection, statements, for_keyword_loc, in_keyword_loc, do_keyword_loc, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7266 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7109 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7114 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # The collection to iterate over. + # + # for i in a end + # ^ + # + # source://prism//lib/prism/node.rb#7155 + sig { returns(Prism::Node) } + def collection; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7128 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7119 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?index: Prism::node, ?collection: Prism::node, ?statements: StatementsNode?, ?for_keyword_loc: Location, ?in_keyword_loc: Location, ?do_keyword_loc: Location?, ?end_keyword_loc: Location, ?location: Location) -> ForNode + # + # source://prism//lib/prism/node.rb#7133 + sig do + params( + index: Prism::Node, + collection: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + for_keyword_loc: Prism::Location, + in_keyword_loc: Prism::Location, + do_keyword_loc: T.nilable(Prism::Location), + end_keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::ForNode) + end + def copy(index: T.unsafe(nil), collection: T.unsafe(nil), statements: T.unsafe(nil), for_keyword_loc: T.unsafe(nil), in_keyword_loc: T.unsafe(nil), do_keyword_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7114 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { index: Prism::node, collection: Prism::node, statements: StatementsNode?, for_keyword_loc: Location, in_keyword_loc: Location, do_keyword_loc: Location?, end_keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#7141 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def do_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#7222 + sig { returns(T.nilable(String)) } + def do_keyword; end + + # The location of the `do` keyword, if present. + # + # for i in a do end + # ^^ + # + # source://prism//lib/prism/node.rb#7189 + sig { returns(T.nilable(Prism::Location)) } + def do_keyword_loc; end + + # def end_keyword: () -> String + # + # source://prism//lib/prism/node.rb#7227 + sig { returns(String) } + def end_keyword; end + + # The location of the `end` keyword. + # + # for i in a end + # ^^^ + # + # source://prism//lib/prism/node.rb#7205 + sig { returns(Prism::Location) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def for_keyword: () -> String + # + # source://prism//lib/prism/node.rb#7212 + sig { returns(String) } + def for_keyword; end + + # The location of the `for` keyword. + # + # for i in a end + # ^^^ + # + # source://prism//lib/prism/node.rb#7169 + sig { returns(Prism::Location) } + def for_keyword_loc; end + + # def in_keyword: () -> String + # + # source://prism//lib/prism/node.rb#7217 + sig { returns(String) } + def in_keyword; end + + # The location of the `in` keyword. + # + # for i in a end + # ^^ + # + # source://prism//lib/prism/node.rb#7179 + sig { returns(Prism::Location) } + def in_keyword_loc; end + + # The index expression for `for` loops. + # + # for i in a end + # ^ + # + # source://prism//lib/prism/node.rb#7149 + sig { returns(Prism::Node) } + def index; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7232 + sig { override.returns(String) } + def inspect; end + + # Represents the body of statements to execute for each iteration of the loop. + # + # for i in a + # foo(i) + # ^^^^^^ + # end + # + # source://prism//lib/prism/node.rb#7163 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7250 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7260 + def type; end + end +end + +# Represents forwarding all arguments to this method to another method. +# +# def foo(...) +# bar(...) +# ^^^ +# end +# +# source://prism//lib/prism/node.rb#7284 +class Prism::ForwardingArgumentsNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [ForwardingArgumentsNode] a new instance of ForwardingArgumentsNode + # + # source://prism//lib/prism/node.rb#7286 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7359 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7292 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7297 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7307 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7302 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> ForwardingArgumentsNode + # + # source://prism//lib/prism/node.rb#7312 + sig { params(location: Prism::Location).returns(Prism::ForwardingArgumentsNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7297 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#7320 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7325 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7343 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7353 + def type; end + end +end + +# Represents the use of the forwarding parameter in a method, block, or lambda declaration. +# +# def foo(...) +# ^^^ +# end +# +# source://prism//lib/prism/node.rb#7369 +class Prism::ForwardingParameterNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [ForwardingParameterNode] a new instance of ForwardingParameterNode + # + # source://prism//lib/prism/node.rb#7371 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7444 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7377 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7382 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7392 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7387 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> ForwardingParameterNode + # + # source://prism//lib/prism/node.rb#7397 + sig { params(location: Prism::Location).returns(Prism::ForwardingParameterNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7382 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#7405 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7410 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7428 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7438 + def type; end + end +end + +# Represents the use of the `super` keyword without parentheses or arguments. +# +# super +# ^^^^^ +# +# source://prism//lib/prism/node.rb#7453 +class Prism::ForwardingSuperNode < ::Prism::Node + # def initialize: (BlockNode? block, Location location) -> void + # + # @return [ForwardingSuperNode] a new instance of ForwardingSuperNode + # + # source://prism//lib/prism/node.rb#7455 + sig { params(source: Prism::Source, block: T.nilable(Prism::BlockNode), location: Prism::Location).void } + def initialize(source, block, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7534 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7462 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader block: BlockNode? + # + # source://prism//lib/prism/node.rb#7497 + sig { returns(T.nilable(Prism::BlockNode)) } + def block; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7467 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7479 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7472 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?block: BlockNode?, ?location: Location) -> ForwardingSuperNode + # + # source://prism//lib/prism/node.rb#7484 + sig { params(block: T.nilable(Prism::BlockNode), location: Prism::Location).returns(Prism::ForwardingSuperNode) } + def copy(block: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7467 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { block: BlockNode?, location: Location } + # + # source://prism//lib/prism/node.rb#7492 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7500 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7518 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7528 + def type; end + end +end + +# Represents the use of the `&&=` operator for assignment to a global variable. +# +# $target &&= value +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#7544 +class Prism::GlobalVariableAndWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [GlobalVariableAndWriteNode] a new instance of GlobalVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#7546 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7648 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7556 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7561 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7571 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7566 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> GlobalVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#7576 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::GlobalVariableAndWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7561 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#7584 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#163 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7614 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#7589 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#7592 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#7609 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#7599 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7632 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#7606 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7642 + def type; end + end +end + +# Represents assigning to a global variable using an operator that isn't `=`. +# +# $target += value +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#7661 +class Prism::GlobalVariableOperatorWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void + # + # @return [GlobalVariableOperatorWriteNode] a new instance of GlobalVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#7663 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7764 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7674 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#7727 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#7717 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7679 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7689 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7684 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> GlobalVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#7694 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).returns(Prism::GlobalVariableOperatorWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7679 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#7702 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#175 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7730 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#7707 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#7710 + sig { returns(Prism::Location) } + def name_loc; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#387 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#394 + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7748 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#7724 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7758 + def type; end + end +end + +# Represents the use of the `||=` operator for assignment to a global variable. +# +# $target ||= value +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#7778 +class Prism::GlobalVariableOrWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [GlobalVariableOrWriteNode] a new instance of GlobalVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#7780 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7882 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7790 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7795 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7805 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7800 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> GlobalVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#7810 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::GlobalVariableOrWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7795 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#7818 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#169 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7848 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#7823 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#7826 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#7843 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#7833 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7866 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#7840 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7876 + def type; end + end +end + +# Represents referencing a global variable. +# +# $foo +# ^^^^ +# +# source://prism//lib/prism/node.rb#7895 +class Prism::GlobalVariableReadNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [GlobalVariableReadNode] a new instance of GlobalVariableReadNode + # + # source://prism//lib/prism/node.rb#7897 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#7978 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7904 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7909 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#7919 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#7914 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> GlobalVariableReadNode + # + # source://prism//lib/prism/node.rb#7924 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::GlobalVariableReadNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#7909 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#7932 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#7944 + sig { override.returns(String) } + def inspect; end + + # The name of the global variable, which is a `$` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifier). Alternatively, it can be one of the special global variables designated by a symbol. + # + # $foo # name `:$foo` + # + # $_Test # name `:$_Test` + # + # source://prism//lib/prism/node.rb#7941 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7962 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#7972 + def type; end + end +end + +# Represents writing to a global variable in a context that doesn't have an explicit value. +# +# $foo, $bar = baz +# ^^^^ ^^^^ +# +# source://prism//lib/prism/node.rb#7988 +class Prism::GlobalVariableTargetNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [GlobalVariableTargetNode] a new instance of GlobalVariableTargetNode + # + # source://prism//lib/prism/node.rb#7990 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8067 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#7997 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8002 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8012 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8007 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> GlobalVariableTargetNode + # + # source://prism//lib/prism/node.rb#8017 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::GlobalVariableTargetNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8002 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#8025 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8033 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#8030 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8051 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8061 + def type; end + end +end + +# Represents writing to a global variable. +# +# $foo = 1 +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#8077 +class Prism::GlobalVariableWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void + # + # @return [GlobalVariableWriteNode] a new instance of GlobalVariableWriteNode + # + # source://prism//lib/prism/node.rb#8079 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, value, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8197 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8089 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8094 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8104 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8099 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> GlobalVariableWriteNode + # + # source://prism//lib/prism/node.rb#8109 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::GlobalVariableWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8094 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#8117 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8163 + sig { override.returns(String) } + def inspect; end + + # The name of the global variable, which is a `$` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifier). Alternatively, it can be one of the special global variables designated by a symbol. + # + # $foo = :bar # name `:$foo` + # + # $_Test = 123 # name `:$_Test` + # + # source://prism//lib/prism/node.rb#8126 + sig { returns(Symbol) } + def name; end + + # The location of the global variable's name. + # + # $foo = :bar + # ^^^^ + # + # source://prism//lib/prism/node.rb#8132 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#8158 + sig { returns(String) } + def operator; end + + # The location of the `=` operator. + # + # $foo = :bar + # ^ + # + # source://prism//lib/prism/node.rb#8151 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8181 + sig { override.returns(Symbol) } + def type; end + + # The value to write to the global variable. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # $foo = :bar + # ^^^^ + # + # $-xyz = 123 + # ^^^ + # + # source://prism//lib/prism/node.rb#8145 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8191 + def type; end + end +end + +# Represents a hash literal. +# +# { a => b } +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#8210 +class Prism::HashNode < ::Prism::Node + # def initialize: (Location opening_loc, Array[AssocNode | AssocSplatNode] elements, Location closing_loc, Location location) -> void + # + # @return [HashNode] a new instance of HashNode + # + # source://prism//lib/prism/node.rb#8212 + sig do + params( + source: Prism::Source, + opening_loc: Prism::Location, + elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, opening_loc, elements, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8327 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8221 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8226 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#8288 + sig { returns(String) } + def closing; end + + # The location of the closing brace. + # + # { a => b } + # ^ + # + # source://prism//lib/prism/node.rb#8276 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8236 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8231 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?opening_loc: Location, ?elements: Array[AssocNode | AssocSplatNode], ?closing_loc: Location, ?location: Location) -> HashNode + # + # source://prism//lib/prism/node.rb#8241 + sig do + params( + opening_loc: Prism::Location, + elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::HashNode) + end + def copy(opening_loc: T.unsafe(nil), elements: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8226 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location, elements: Array[AssocNode | AssocSplatNode], closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#8249 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # The elements of the hash. These can be either `AssocNode`s or `AssocSplatNode`s. + # + # { a: b } + # ^^^^ + # + # { **foo } + # ^^^^^ + # + # source://prism//lib/prism/node.rb#8270 + sig { returns(T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)]) } + def elements; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8293 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#8283 + sig { returns(String) } + def opening; end + + # The location of the opening brace. + # + # { a => b } + # ^ + # + # source://prism//lib/prism/node.rb#8257 + sig { returns(Prism::Location) } + def opening_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8311 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8321 + def type; end + end +end + +# Represents a hash pattern in pattern matching. +# +# foo => { a: 1, b: 2 } +# ^^^^^^^^^^^^^^ +# +# foo => { a: 1, b: 2, **c } +# ^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#8343 +class Prism::HashPatternNode < ::Prism::Node + # def initialize: (Prism::node? constant, Array[AssocNode] elements, AssocSplatNode | NoKeywordsParameterNode | nil rest, Location? opening_loc, Location? closing_loc, Location location) -> void + # + # @return [HashPatternNode] a new instance of HashPatternNode + # + # source://prism//lib/prism/node.rb#8345 + sig do + params( + source: Prism::Source, + constant: T.nilable(Prism::Node), + elements: T::Array[Prism::AssocNode], + rest: T.nilable(T.any(Prism::AssocSplatNode, Prism::NoKeywordsParameterNode)), + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, constant, elements, rest, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8472 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8356 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8361 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#8433 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#8415 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8375 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8366 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader constant: Prism::node? + # + # source://prism//lib/prism/node.rb#8393 + sig { returns(T.nilable(Prism::Node)) } + def constant; end + + # def copy: (?constant: Prism::node?, ?elements: Array[AssocNode], ?rest: AssocSplatNode | NoKeywordsParameterNode | nil, ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> HashPatternNode + # + # source://prism//lib/prism/node.rb#8380 + sig do + params( + constant: T.nilable(Prism::Node), + elements: T::Array[Prism::AssocNode], + rest: T.nilable(T.any(Prism::AssocSplatNode, Prism::NoKeywordsParameterNode)), + opening_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::HashPatternNode) + end + def copy(constant: T.unsafe(nil), elements: T.unsafe(nil), rest: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8361 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { constant: Prism::node?, elements: Array[AssocNode], rest: AssocSplatNode | NoKeywordsParameterNode | nil, opening_loc: Location?, closing_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#8388 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader elements: Array[AssocNode] + # + # source://prism//lib/prism/node.rb#8396 + sig { returns(T::Array[Prism::AssocNode]) } + def elements; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8438 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#8428 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#8402 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # attr_reader rest: AssocSplatNode | NoKeywordsParameterNode | nil + # + # source://prism//lib/prism/node.rb#8399 + sig { returns(T.nilable(T.any(Prism::AssocSplatNode, Prism::NoKeywordsParameterNode))) } + def rest; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8456 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8466 + def type; end + end +end + +# source://prism//lib/prism/node_ext.rb#49 +module Prism::HeredocQuery + # Returns true if this node was represented as a heredoc in the source code. + # + # @return [Boolean] + # + # source://prism//lib/prism/node_ext.rb#51 + def heredoc?; end +end + +# Represents the use of the `if` keyword, either in the block form or the modifier form, or a ternary expression. +# +# bar if foo +# ^^^^^^^^^^ +# +# if foo then bar end +# ^^^^^^^^^^^^^^^^^^^ +# +# foo ? bar : baz +# ^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#8493 +class Prism::IfNode < ::Prism::Node + # def initialize: (Location? if_keyword_loc, Prism::node predicate, Location? then_keyword_loc, StatementsNode? statements, Prism::node? consequent, Location? end_keyword_loc, Location location) -> void + # + # @return [IfNode] a new instance of IfNode + # + # source://prism//lib/prism/node.rb#8495 + sig do + params( + source: Prism::Source, + if_keyword_loc: T.nilable(Prism::Location), + predicate: Prism::Node, + then_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + consequent: T.nilable(Prism::Node), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, if_keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8687 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8507 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8512 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8526 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8517 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # Represents an `ElseNode` or an `IfNode` when there is an `else` or an `elsif` in the `if` statement. + # + # if foo + # bar + # elsif baz + # ^^^^^^^^^ + # qux + # ^^^ + # end + # ^^^ + # + # if foo then bar else baz end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/node.rb#8617 + sig { returns(T.nilable(Prism::Node)) } + def consequent; end + + # def copy: (?if_keyword_loc: Location?, ?predicate: Prism::node, ?then_keyword_loc: Location?, ?statements: StatementsNode?, ?consequent: Prism::node?, ?end_keyword_loc: Location?, ?location: Location) -> IfNode + # + # source://prism//lib/prism/node.rb#8531 + sig do + params( + if_keyword_loc: T.nilable(Prism::Location), + predicate: Prism::Node, + then_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + consequent: T.nilable(Prism::Node), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::IfNode) + end + def copy(if_keyword_loc: T.unsafe(nil), predicate: T.unsafe(nil), then_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), consequent: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8512 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { if_keyword_loc: Location?, predicate: Prism::node, then_keyword_loc: Location?, statements: StatementsNode?, consequent: Prism::node?, end_keyword_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#8539 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#8648 + sig { returns(T.nilable(String)) } + def end_keyword; end + + # The location of the `end` keyword if present, `nil` otherwise. + # + # if foo + # bar + # end + # ^^^ + # + # source://prism//lib/prism/node.rb#8625 + sig { returns(T.nilable(Prism::Location)) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def if_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#8638 + sig { returns(T.nilable(String)) } + def if_keyword; end + + # The location of the `if` keyword if present. + # + # bar if foo + # ^^ + # + # The `if_keyword_loc` field will be `nil` when the `IfNode` represents a ternary expression. + # + # source://prism//lib/prism/node.rb#8549 + sig { returns(T.nilable(Prism::Location)) } + def if_keyword_loc; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8653 + sig { override.returns(String) } + def inspect; end + + # source://prism//lib/prism/parse_result/newlines.rb#91 + def newline!(lines); end + + # The node for the condition the `IfNode` is testing. + # + # if foo + # ^^^ + # bar + # end + # + # bar if foo + # ^^^ + # + # foo ? bar : baz + # ^^^ + # + # source://prism//lib/prism/node.rb#8573 + sig { returns(Prism::Node) } + def predicate; end + + # Represents the body of statements that will be executed when the predicate is evaluated as truthy. Will be `nil` when no body is provided. + # + # if foo + # bar + # ^^^ + # baz + # ^^^ + # end + # + # source://prism//lib/prism/node.rb#8602 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # def then_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#8643 + sig { returns(T.nilable(String)) } + def then_keyword; end + + # The location of the `then` keyword (if present) or the `?` in a ternary expression, `nil` otherwise. + # + # if foo then bar end + # ^^^^ + # + # a ? b : c + # ^ + # + # source://prism//lib/prism/node.rb#8582 + sig { returns(T.nilable(Prism::Location)) } + def then_keyword_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8671 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8681 + def type; end + end +end + +# Represents an imaginary number literal. +# +# 1.0i +# ^^^^ +# +# source://prism//lib/prism/node.rb#8702 +class Prism::ImaginaryNode < ::Prism::Node + # def initialize: (FloatNode | IntegerNode | RationalNode numeric, Location location) -> void + # + # @return [ImaginaryNode] a new instance of ImaginaryNode + # + # source://prism//lib/prism/node.rb#8704 + sig do + params( + source: Prism::Source, + numeric: T.any(Prism::FloatNode, Prism::IntegerNode, Prism::RationalNode), + location: Prism::Location + ).void + end + def initialize(source, numeric, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8781 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8711 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8716 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8726 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8721 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?numeric: FloatNode | IntegerNode | RationalNode, ?location: Location) -> ImaginaryNode + # + # source://prism//lib/prism/node.rb#8731 + sig do + params( + numeric: T.any(Prism::FloatNode, Prism::IntegerNode, Prism::RationalNode), + location: Prism::Location + ).returns(Prism::ImaginaryNode) + end + def copy(numeric: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8716 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { numeric: FloatNode | IntegerNode | RationalNode, location: Location } + # + # source://prism//lib/prism/node.rb#8739 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8747 + sig { override.returns(String) } + def inspect; end + + # attr_reader numeric: FloatNode | IntegerNode | RationalNode + # + # source://prism//lib/prism/node.rb#8744 + sig { returns(T.any(Prism::FloatNode, Prism::IntegerNode, Prism::RationalNode)) } + def numeric; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8765 + sig { override.returns(Symbol) } + def type; end + + # Returns the value of the node as a Ruby Complex. + # + # source://prism//lib/prism/node_ext.rb#101 + sig { returns(Complex) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8775 + def type; end + end +end + +# Represents a node that is implicitly being added to the tree but doesn't correspond directly to a node in the source. +# +# { foo: } +# ^^^^ +# +# { Foo: } +# ^^^^ +# +# foo in { bar: } +# ^^^^ +# +# source://prism//lib/prism/node.rb#8797 +class Prism::ImplicitNode < ::Prism::Node + # def initialize: (Prism::node value, Location location) -> void + # + # @return [ImplicitNode] a new instance of ImplicitNode + # + # source://prism//lib/prism/node.rb#8799 + sig { params(source: Prism::Source, value: Prism::Node, location: Prism::Location).void } + def initialize(source, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8876 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8806 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8811 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8821 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8816 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?value: Prism::node, ?location: Location) -> ImplicitNode + # + # source://prism//lib/prism/node.rb#8826 + sig { params(value: Prism::Node, location: Prism::Location).returns(Prism::ImplicitNode) } + def copy(value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8811 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#8834 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8842 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8860 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#8839 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8870 + def type; end + end +end + +# Represents using a trailing comma to indicate an implicit rest parameter. +# +# foo { |bar,| } +# ^ +# +# foo in [bar,] +# ^ +# +# for foo, in bar do end +# ^ +# +# foo, = bar +# ^ +# +# source://prism//lib/prism/node.rb#8895 +class Prism::ImplicitRestNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [ImplicitRestNode] a new instance of ImplicitRestNode + # + # source://prism//lib/prism/node.rb#8897 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#8970 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8903 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8908 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#8918 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#8913 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> ImplicitRestNode + # + # source://prism//lib/prism/node.rb#8923 + sig { params(location: Prism::Location).returns(Prism::ImplicitRestNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8908 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#8931 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#8936 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8954 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#8964 + def type; end + end +end + +# Represents the use of the `in` keyword in a case statement. +# +# case a; in b then c end +# ^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#8979 +class Prism::InNode < ::Prism::Node + # def initialize: (Prism::node pattern, StatementsNode? statements, Location in_loc, Location? then_loc, Location location) -> void + # + # @return [InNode] a new instance of InNode + # + # source://prism//lib/prism/node.rb#8981 + sig do + params( + source: Prism::Source, + pattern: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + in_loc: Prism::Location, + then_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, pattern, statements, in_loc, then_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#9097 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#8991 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8996 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#9009 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#9001 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?pattern: Prism::node, ?statements: StatementsNode?, ?in_loc: Location, ?then_loc: Location?, ?location: Location) -> InNode + # + # source://prism//lib/prism/node.rb#9014 + sig do + params( + pattern: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + in_loc: Prism::Location, + then_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::InNode) + end + def copy(pattern: T.unsafe(nil), statements: T.unsafe(nil), in_loc: T.unsafe(nil), then_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#8996 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { pattern: Prism::node, statements: StatementsNode?, in_loc: Location, then_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#9022 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def in: () -> String + # + # source://prism//lib/prism/node.rb#9053 + sig { returns(String) } + def in; end + + # attr_reader in_loc: Location + # + # source://prism//lib/prism/node.rb#9033 + sig { returns(Prism::Location) } + def in_loc; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#9063 + sig { override.returns(String) } + def inspect; end + + # attr_reader pattern: Prism::node + # + # source://prism//lib/prism/node.rb#9027 + sig { returns(Prism::Node) } + def pattern; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#9030 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # def then: () -> String? + # + # source://prism//lib/prism/node.rb#9058 + sig { returns(T.nilable(String)) } + def then; end + + # attr_reader then_loc: Location? + # + # source://prism//lib/prism/node.rb#9040 + sig { returns(T.nilable(Prism::Location)) } + def then_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9081 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9091 + def type; end + end +end + +# Represents the use of the `&&=` operator on a call to the `[]` method. +# +# foo.bar[baz] &&= value +# ^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#9110 +class Prism::IndexAndWriteNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [IndexAndWriteNode] a new instance of IndexAndWriteNode + # + # source://prism//lib/prism/node.rb#9112 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#9289 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#9127 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#9192 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9225 + sig { returns(T::Boolean) } + def attribute_write?; end + + # attr_reader block: Prism::node? + # + # source://prism//lib/prism/node.rb#9202 + sig { returns(T.nilable(Prism::Node)) } + def block; end + + # def call_operator: () -> String? + # + # source://prism//lib/prism/node.rb#9235 + sig { returns(T.nilable(String)) } + def call_operator; end + + # attr_reader call_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#9172 + sig { returns(T.nilable(Prism::Location)) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9132 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#9245 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#9195 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#9147 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#9137 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> IndexAndWriteNode + # + # source://prism//lib/prism/node.rb#9152 + sig do + params( + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::IndexAndWriteNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9132 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#9160 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9230 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#9255 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#9240 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#9185 + sig { returns(Prism::Location) } + def opening_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#9250 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#9205 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader receiver: Prism::node? + # + # source://prism//lib/prism/node.rb#9169 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9215 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9273 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#9212 + sig { returns(Prism::Node) } + def value; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9220 + sig { returns(T::Boolean) } + def variable_call?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#9165 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9283 + def type; end + end +end + +# Represents the use of an assignment operator on a call to `[]`. +# +# foo.bar[baz] += value +# ^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#9307 +class Prism::IndexOperatorWriteNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Symbol binary_operator, Location binary_operator_loc, Prism::node value, Location location) -> void + # + # @return [IndexOperatorWriteNode] a new instance of IndexOperatorWriteNode + # + # source://prism//lib/prism/node.rb#9309 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + binary_operator: Symbol, + binary_operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, binary_operator, binary_operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#9485 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#9325 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#9390 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9426 + sig { returns(T::Boolean) } + def attribute_write?; end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#9403 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#9406 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # attr_reader block: Prism::node? + # + # source://prism//lib/prism/node.rb#9400 + sig { returns(T.nilable(Prism::Node)) } + def block; end + + # def call_operator: () -> String? + # + # source://prism//lib/prism/node.rb#9436 + sig { returns(T.nilable(String)) } + def call_operator; end + + # attr_reader call_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#9370 + sig { returns(T.nilable(Prism::Location)) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9330 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#9446 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#9393 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#9345 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#9335 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?binary_operator: Symbol, ?binary_operator_loc: Location, ?value: Prism::node, ?location: Location) -> IndexOperatorWriteNode + # + # source://prism//lib/prism/node.rb#9350 + sig do + params( + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + binary_operator: Symbol, + binary_operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::IndexOperatorWriteNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), binary_operator: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9330 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, binary_operator: Symbol, binary_operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#9358 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9431 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#9451 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#9441 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#9383 + sig { returns(Prism::Location) } + def opening_loc; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#403 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#410 + def operator_loc; end + + # attr_reader receiver: Prism::node? + # + # source://prism//lib/prism/node.rb#9367 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9416 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9469 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#9413 + sig { returns(Prism::Node) } + def value; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9421 + sig { returns(T::Boolean) } + def variable_call?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#9363 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9479 + def type; end + end +end + +# Represents the use of the `||=` operator on a call to `[]`. +# +# foo.bar[baz] ||= value +# ^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#9504 +class Prism::IndexOrWriteNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [IndexOrWriteNode] a new instance of IndexOrWriteNode + # + # source://prism//lib/prism/node.rb#9506 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#9683 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#9521 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#9586 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9619 + sig { returns(T::Boolean) } + def attribute_write?; end + + # attr_reader block: Prism::node? + # + # source://prism//lib/prism/node.rb#9596 + sig { returns(T.nilable(Prism::Node)) } + def block; end + + # def call_operator: () -> String? + # + # source://prism//lib/prism/node.rb#9629 + sig { returns(T.nilable(String)) } + def call_operator; end + + # attr_reader call_operator_loc: Location? + # + # source://prism//lib/prism/node.rb#9566 + sig { returns(T.nilable(Prism::Location)) } + def call_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9526 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#9639 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#9589 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#9541 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#9531 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> IndexOrWriteNode + # + # source://prism//lib/prism/node.rb#9546 + sig do + params( + flags: Integer, + receiver: T.nilable(Prism::Node), + call_operator_loc: T.nilable(Prism::Location), + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::IndexOrWriteNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9526 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#9554 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9624 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#9649 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#9634 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#9579 + sig { returns(Prism::Location) } + def opening_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#9644 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#9599 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader receiver: Prism::node? + # + # source://prism//lib/prism/node.rb#9563 + sig { returns(T.nilable(Prism::Node)) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9609 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9667 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#9606 + sig { returns(Prism::Node) } + def value; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9614 + sig { returns(T::Boolean) } + def variable_call?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#9559 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9677 + def type; end + end +end + +# Represents assigning to an index. +# +# foo[bar], = 1 +# ^^^^^^^^ +# +# begin +# rescue => foo[bar] +# ^^^^^^^^ +# end +# +# for foo[bar] in baz do end +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#9709 +class Prism::IndexTargetNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node receiver, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Location location) -> void + # + # @return [IndexTargetNode] a new instance of IndexTargetNode + # + # source://prism//lib/prism/node.rb#9711 + sig do + params( + source: Prism::Source, + flags: Integer, + receiver: Prism::Node, + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + location: Prism::Location + ).void + end + def initialize(source, flags, receiver, opening_loc, arguments, closing_loc, block, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#9851 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#9723 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#9774 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def attribute_write?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9797 + sig { returns(T::Boolean) } + def attribute_write?; end + + # attr_reader block: Prism::node? + # + # source://prism//lib/prism/node.rb#9784 + sig { returns(T.nilable(Prism::Node)) } + def block; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9728 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#9812 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#9777 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#9742 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#9733 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?receiver: Prism::node, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?location: Location) -> IndexTargetNode + # + # source://prism//lib/prism/node.rb#9747 + sig do + params( + flags: Integer, + receiver: Prism::Node, + opening_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + closing_loc: Prism::Location, + block: T.nilable(Prism::Node), + location: Prism::Location + ).returns(Prism::IndexTargetNode) + end + def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9728 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, location: Location } + # + # source://prism//lib/prism/node.rb#9755 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def ignore_visibility?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9802 + sig { returns(T::Boolean) } + def ignore_visibility?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#9817 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#9807 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#9767 + sig { returns(Prism::Location) } + def opening_loc; end + + # attr_reader receiver: Prism::node + # + # source://prism//lib/prism/node.rb#9764 + sig { returns(Prism::Node) } + def receiver; end + + # def safe_navigation?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9787 + sig { returns(T::Boolean) } + def safe_navigation?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9835 + sig { override.returns(Symbol) } + def type; end + + # def variable_call?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#9792 + sig { returns(T::Boolean) } + def variable_call?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#9760 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9845 + def type; end + end +end + +# InlineComment objects are the most common. They correspond to comments in +# the source file like this one that start with #. +# +# source://prism//lib/prism/parse_result.rb#388 +class Prism::InlineComment < ::Prism::Comment + # Returns a string representation of this comment. + # + # source://prism//lib/prism/parse_result.rb#396 + sig { returns(String) } + def inspect; end + + # Returns true if this comment happens on the same line as other code and + # false if the comment is by itself. + # + # @return [Boolean] + # + # source://prism//lib/prism/parse_result.rb#391 + sig { override.returns(T::Boolean) } + def trailing?; end +end + +# This visitor is responsible for composing the strings that get returned by +# the various #inspect methods defined on each of the nodes. +# +# source://prism//lib/prism/inspect_visitor.rb#12 +class Prism::InspectVisitor < ::Prism::Visitor + # Initializes a new instance of the InspectVisitor. + # + # @return [InspectVisitor] a new instance of InspectVisitor + # + # source://prism//lib/prism/inspect_visitor.rb#35 + sig { params(indent: String).void } + def initialize(indent = T.unsafe(nil)); end + + # The list of commands that we need to execute in order to compose the + # final string. + # + # source://prism//lib/prism/inspect_visitor.rb#32 + def commands; end + + # Compose the final string. + # + # source://prism//lib/prism/inspect_visitor.rb#48 + sig { returns(String) } + def compose; end + + # The current prefix string. + # + # source://prism//lib/prism/inspect_visitor.rb#28 + def indent; end + + # Inspect a AliasGlobalVariableNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#77 + def visit_alias_global_variable_node(node); end + + # Inspect a AliasMethodNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#87 + def visit_alias_method_node(node); end + + # Inspect a AlternationPatternNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#97 + def visit_alternation_pattern_node(node); end + + # Inspect a AndNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#107 + def visit_and_node(node); end + + # Inspect a ArgumentsNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#117 + def visit_arguments_node(node); end + + # Inspect a ArrayNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#133 + def visit_array_node(node); end + + # Inspect a ArrayPatternNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#151 + def visit_array_pattern_node(node); end + + # Inspect a AssocNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#188 + def visit_assoc_node(node); end + + # Inspect a AssocSplatNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#198 + def visit_assoc_splat_node(node); end + + # Inspect a BackReferenceReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#210 + def visit_back_reference_read_node(node); end + + # Inspect a BeginNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#216 + def visit_begin_node(node); end + + # Inspect a BlockArgumentNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#247 + def visit_block_argument_node(node); end + + # Inspect a BlockLocalVariableNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#259 + def visit_block_local_variable_node(node); end + + # Inspect a BlockNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#267 + def visit_block_node(node); end + + # Inspect a BlockParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#287 + def visit_block_parameter_node(node); end + + # Inspect a BlockParametersNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#301 + def visit_block_parameters_node(node); end + + # Inspect a BreakNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#323 + def visit_break_node(node); end + + # Inspect a CallAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#335 + def visit_call_and_write_node(node); end + + # Inspect a CallNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#355 + def visit_call_node(node); end + + # Inspect a CallOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#385 + def visit_call_operator_write_node(node); end + + # Inspect a CallOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#406 + def visit_call_or_write_node(node); end + + # Inspect a CallTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#426 + def visit_call_target_node(node); end + + # Inspect a CapturePatternNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#438 + def visit_capture_pattern_node(node); end + + # Inspect a CaseMatchNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#448 + def visit_case_match_node(node); end + + # Inspect a CaseNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#476 + def visit_case_node(node); end + + # Inspect a ClassNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#504 + def visit_class_node(node); end + + # Inspect a ClassVariableAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#528 + def visit_class_variable_and_write_node(node); end + + # Inspect a ClassVariableOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#538 + def visit_class_variable_operator_write_node(node); end + + # Inspect a ClassVariableOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#549 + def visit_class_variable_or_write_node(node); end + + # Inspect a ClassVariableReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#559 + def visit_class_variable_read_node(node); end + + # Inspect a ClassVariableTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#565 + def visit_class_variable_target_node(node); end + + # Inspect a ClassVariableWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#571 + def visit_class_variable_write_node(node); end + + # Inspect a ConstantAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#581 + def visit_constant_and_write_node(node); end + + # Inspect a ConstantOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#591 + def visit_constant_operator_write_node(node); end + + # Inspect a ConstantOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#602 + def visit_constant_or_write_node(node); end + + # Inspect a ConstantPathAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#612 + def visit_constant_path_and_write_node(node); end + + # Inspect a ConstantPathNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#622 + def visit_constant_path_node(node); end + + # Inspect a ConstantPathOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#640 + def visit_constant_path_operator_write_node(node); end + + # Inspect a ConstantPathOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#651 + def visit_constant_path_or_write_node(node); end + + # Inspect a ConstantPathTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#661 + def visit_constant_path_target_node(node); end + + # Inspect a ConstantPathWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#679 + def visit_constant_path_write_node(node); end + + # Inspect a ConstantReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#689 + def visit_constant_read_node(node); end + + # Inspect a ConstantTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#695 + def visit_constant_target_node(node); end + + # Inspect a ConstantWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#701 + def visit_constant_write_node(node); end + + # Inspect a DefNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#711 + def visit_def_node(node); end + + # Inspect a DefinedNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#743 + def visit_defined_node(node); end + + # Inspect a ElseNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#753 + def visit_else_node(node); end + + # Inspect a EmbeddedStatementsNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#766 + def visit_embedded_statements_node(node); end + + # Inspect a EmbeddedVariableNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#779 + def visit_embedded_variable_node(node); end + + # Inspect a EnsureNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#787 + def visit_ensure_node(node); end + + # Inspect a FalseNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#800 + def visit_false_node(node); end + + # Inspect a FindPatternNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#805 + def visit_find_pattern_node(node); end + + # Inspect a FlipFlopNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#831 + def visit_flip_flop_node(node); end + + # Inspect a FloatNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#851 + def visit_float_node(node); end + + # Inspect a ForNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#857 + def visit_for_node(node); end + + # Inspect a ForwardingArgumentsNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#876 + def visit_forwarding_arguments_node(node); end + + # Inspect a ForwardingParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#881 + def visit_forwarding_parameter_node(node); end + + # Inspect a ForwardingSuperNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#886 + def visit_forwarding_super_node(node); end + + # Inspect a GlobalVariableAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#897 + def visit_global_variable_and_write_node(node); end + + # Inspect a GlobalVariableOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#907 + def visit_global_variable_operator_write_node(node); end + + # Inspect a GlobalVariableOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#918 + def visit_global_variable_or_write_node(node); end + + # Inspect a GlobalVariableReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#928 + def visit_global_variable_read_node(node); end + + # Inspect a GlobalVariableTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#934 + def visit_global_variable_target_node(node); end + + # Inspect a GlobalVariableWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#940 + def visit_global_variable_write_node(node); end + + # Inspect a HashNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#950 + def visit_hash_node(node); end + + # Inspect a HashPatternNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#966 + def visit_hash_pattern_node(node); end + + # Inspect a IfNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#994 + def visit_if_node(node); end + + # Inspect a ImaginaryNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1016 + def visit_imaginary_node(node); end + + # Inspect a ImplicitNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1023 + def visit_implicit_node(node); end + + # Inspect a ImplicitRestNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1030 + def visit_implicit_rest_node(node); end + + # Inspect a InNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1035 + def visit_in_node(node); end + + # Inspect a IndexAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1050 + def visit_index_and_write_node(node); end + + # Inspect a IndexOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1081 + def visit_index_operator_write_node(node); end + + # Inspect a IndexOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1113 + def visit_index_or_write_node(node); end + + # Inspect a IndexTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1144 + def visit_index_target_node(node); end + + # Inspect a InstanceVariableAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1167 + def visit_instance_variable_and_write_node(node); end + + # Inspect a InstanceVariableOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1177 + def visit_instance_variable_operator_write_node(node); end + + # Inspect a InstanceVariableOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1188 + def visit_instance_variable_or_write_node(node); end + + # Inspect a InstanceVariableReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1198 + def visit_instance_variable_read_node(node); end + + # Inspect a InstanceVariableTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1204 + def visit_instance_variable_target_node(node); end + + # Inspect a InstanceVariableWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1210 + def visit_instance_variable_write_node(node); end + + # Inspect a IntegerNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1220 + def visit_integer_node(node); end + + # Inspect a InterpolatedMatchLastLineNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1228 + def visit_interpolated_match_last_line_node(node); end + + # Inspect a InterpolatedRegularExpressionNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1246 + def visit_interpolated_regular_expression_node(node); end + + # Inspect a InterpolatedStringNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1264 + def visit_interpolated_string_node(node); end + + # Inspect a InterpolatedSymbolNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1282 + def visit_interpolated_symbol_node(node); end + + # Inspect a InterpolatedXStringNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1298 + def visit_interpolated_x_string_node(node); end + + # Inspect a ItLocalVariableReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1314 + def visit_it_local_variable_read_node(node); end + + # Inspect a ItParametersNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1319 + def visit_it_parameters_node(node); end + + # Inspect a KeywordHashNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1324 + def visit_keyword_hash_node(node); end + + # Inspect a KeywordRestParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1340 + def visit_keyword_rest_parameter_node(node); end + + # Inspect a LambdaNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1354 + def visit_lambda_node(node); end + + # Inspect a LocalVariableAndWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1375 + def visit_local_variable_and_write_node(node); end + + # Inspect a LocalVariableOperatorWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1386 + def visit_local_variable_operator_write_node(node); end + + # Inspect a LocalVariableOrWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1398 + def visit_local_variable_or_write_node(node); end + + # Inspect a LocalVariableReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1409 + def visit_local_variable_read_node(node); end + + # Inspect a LocalVariableTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1416 + def visit_local_variable_target_node(node); end + + # Inspect a LocalVariableWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1423 + def visit_local_variable_write_node(node); end + + # Inspect a MatchLastLineNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1434 + def visit_match_last_line_node(node); end + + # Inspect a MatchPredicateNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1445 + def visit_match_predicate_node(node); end + + # Inspect a MatchRequiredNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1455 + def visit_match_required_node(node); end + + # Inspect a MatchWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1465 + def visit_match_write_node(node); end + + # Inspect a MissingNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1481 + def visit_missing_node(node); end + + # Inspect a ModuleNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1486 + def visit_module_node(node); end + + # Inspect a MultiTargetNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1503 + def visit_multi_target_node(node); end + + # Inspect a MultiWriteNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1534 + def visit_multi_write_node(node); end + + # Inspect a NextNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1568 + def visit_next_node(node); end + + # Inspect a NilNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1580 + def visit_nil_node(node); end + + # Inspect a NoKeywordsParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1585 + def visit_no_keywords_parameter_node(node); end + + # Inspect a NumberedParametersNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1592 + def visit_numbered_parameters_node(node); end + + # Inspect a NumberedReferenceReadNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1598 + def visit_numbered_reference_read_node(node); end + + # Inspect a OptionalKeywordParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1604 + def visit_optional_keyword_parameter_node(node); end + + # Inspect a OptionalParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1615 + def visit_optional_parameter_node(node); end + + # Inspect a OrNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1627 + def visit_or_node(node); end + + # Inspect a ParametersNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1637 + def visit_parameters_node(node); end + + # Inspect a ParenthesesNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1696 + def visit_parentheses_node(node); end + + # Inspect a PinnedExpressionNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1709 + def visit_pinned_expression_node(node); end + + # Inspect a PinnedVariableNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1719 + def visit_pinned_variable_node(node); end + + # Inspect a PostExecutionNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1727 + def visit_post_execution_node(node); end + + # Inspect a PreExecutionNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1741 + def visit_pre_execution_node(node); end + + # Inspect a ProgramNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1755 + def visit_program_node(node); end + + # Inspect a RangeNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1763 + def visit_range_node(node); end + + # Inspect a RationalNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1783 + def visit_rational_node(node); end + + # Inspect a RedoNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1792 + def visit_redo_node(node); end + + # Inspect a RegularExpressionNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1797 + def visit_regular_expression_node(node); end + + # Inspect a RequiredKeywordParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1808 + def visit_required_keyword_parameter_node(node); end + + # Inspect a RequiredParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1817 + def visit_required_parameter_node(node); end + + # Inspect a RescueModifierNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1825 + def visit_rescue_modifier_node(node); end + + # Inspect a RescueNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1835 + def visit_rescue_node(node); end + + # Inspect a RestParameterNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1869 + def visit_rest_parameter_node(node); end + + # Inspect a RetryNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1883 + def visit_retry_node(node); end + + # Inspect a ReturnNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1888 + def visit_return_node(node); end + + # Inspect a SelfNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1902 + def visit_self_node(node); end + + # Inspect a ShareableConstantNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1907 + def visit_shareable_constant_node(node); end + + # Inspect a SingletonClassNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1916 + def visit_singleton_class_node(node); end + + # Inspect a SourceEncodingNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1933 + def visit_source_encoding_node(node); end + + # Inspect a SourceFileNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1938 + def visit_source_file_node(node); end + + # Inspect a SourceLineNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1946 + def visit_source_line_node(node); end + + # Inspect a SplatNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1951 + def visit_splat_node(node); end + + # Inspect a StatementsNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1963 + def visit_statements_node(node); end + + # Inspect a StringNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1977 + def visit_string_node(node); end + + # Inspect a SuperNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#1988 + def visit_super_node(node); end + + # Inspect a SymbolNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2008 + def visit_symbol_node(node); end + + # Inspect a TrueNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2019 + def visit_true_node(node); end + + # Inspect a UndefNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2024 + def visit_undef_node(node); end + + # Inspect a UnlessNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2039 + def visit_unless_node(node); end + + # Inspect a UntilNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2061 + def visit_until_node(node); end + + # Inspect a WhenNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2078 + def visit_when_node(node); end + + # Inspect a WhileNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2100 + def visit_while_node(node); end + + # Inspect a XStringNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2117 + def visit_x_string_node(node); end + + # Inspect a YieldNode node. + # + # source://prism//lib/prism/inspect_visitor.rb#2128 + def visit_yield_node(node); end + + private + + # Compose a string representing the given inner location field. + # + # source://prism//lib/prism/inspect_visitor.rb#2150 + def inspect_location(location); end + + # Compose a header for the given node. + # + # source://prism//lib/prism/inspect_visitor.rb#2144 + def inspect_node(name, node); end + + class << self + # Compose an inspect string for the given node. + # + # source://prism//lib/prism/inspect_visitor.rb#41 + sig { params(node: Prism::Node).returns(String) } + def compose(node); end + end +end + +# Most of the time, we can simply pass down the indent to the next node. +# However, when we are inside a list we want some extra special formatting +# when we hit an element in that list. In this case, we have a special +# command that replaces the subsequent indent with the given value. +# +# source://prism//lib/prism/inspect_visitor.rb#17 +class Prism::InspectVisitor::Replace + # @return [Replace] a new instance of Replace + # + # source://prism//lib/prism/inspect_visitor.rb#20 + def initialize(value); end + + # source://prism//lib/prism/inspect_visitor.rb#18 + def value; end +end + +# Represents the use of the `&&=` operator for assignment to an instance variable. +# +# @target &&= value +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#9866 +class Prism::InstanceVariableAndWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [InstanceVariableAndWriteNode] a new instance of InstanceVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#9868 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#9970 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#9878 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9883 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#9893 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#9888 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> InstanceVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#9898 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::InstanceVariableAndWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#9883 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#9906 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#181 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#9936 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#9911 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#9914 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#9931 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#9921 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9954 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#9928 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#9964 + def type; end + end +end + +# Represents assigning to an instance variable using an operator that isn't `=`. +# +# @target += value +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#9983 +class Prism::InstanceVariableOperatorWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void + # + # @return [InstanceVariableOperatorWriteNode] a new instance of InstanceVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#9985 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10086 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#9996 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#10049 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#10039 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10001 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10011 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10006 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> InstanceVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#10016 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + binary_operator: Symbol, + location: Prism::Location + ).returns(Prism::InstanceVariableOperatorWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10001 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#10024 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#193 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10052 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#10029 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#10032 + sig { returns(Prism::Location) } + def name_loc; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#419 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#426 + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10070 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#10046 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10080 + def type; end + end +end + +# Represents the use of the `||=` operator for assignment to an instance variable. +# +# @target ||= value +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#10100 +class Prism::InstanceVariableOrWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [InstanceVariableOrWriteNode] a new instance of InstanceVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#10102 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10204 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#10112 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10117 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10127 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10122 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> InstanceVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#10132 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::InstanceVariableOrWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10117 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#10140 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # source://prism//lib/prism/desugar_compiler.rb#187 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10170 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#10145 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#10148 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#10165 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#10155 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10188 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#10162 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10198 + def type; end + end +end + +# Represents referencing an instance variable. +# +# @foo +# ^^^^ +# +# source://prism//lib/prism/node.rb#10217 +class Prism::InstanceVariableReadNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [InstanceVariableReadNode] a new instance of InstanceVariableReadNode + # + # source://prism//lib/prism/node.rb#10219 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10300 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#10226 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10231 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10241 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10236 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> InstanceVariableReadNode + # + # source://prism//lib/prism/node.rb#10246 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::InstanceVariableReadNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10231 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#10254 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10266 + sig { override.returns(String) } + def inspect; end + + # The name of the instance variable, which is a `@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers). + # + # @x # name `:@x` + # + # @_test # name `:@_test` + # + # source://prism//lib/prism/node.rb#10263 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10284 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10294 + def type; end + end +end + +# Represents writing to an instance variable in a context that doesn't have an explicit value. +# +# @foo, @bar = baz +# ^^^^ ^^^^ +# +# source://prism//lib/prism/node.rb#10310 +class Prism::InstanceVariableTargetNode < ::Prism::Node + # def initialize: (Symbol name, Location location) -> void + # + # @return [InstanceVariableTargetNode] a new instance of InstanceVariableTargetNode + # + # source://prism//lib/prism/node.rb#10312 + sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void } + def initialize(source, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10389 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#10319 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10324 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10334 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10329 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?location: Location) -> InstanceVariableTargetNode + # + # source://prism//lib/prism/node.rb#10339 + sig { params(name: Symbol, location: Prism::Location).returns(Prism::InstanceVariableTargetNode) } + def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10324 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#10347 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10355 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#10352 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10373 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10383 + def type; end + end +end + +# Represents writing to an instance variable. +# +# @foo = 1 +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#10399 +class Prism::InstanceVariableWriteNode < ::Prism::Node + # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void + # + # @return [InstanceVariableWriteNode] a new instance of InstanceVariableWriteNode + # + # source://prism//lib/prism/node.rb#10401 + sig do + params( + source: Prism::Source, + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, name, name_loc, value, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10519 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#10411 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10416 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10426 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10421 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> InstanceVariableWriteNode + # + # source://prism//lib/prism/node.rb#10431 + sig do + params( + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::InstanceVariableWriteNode) + end + def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10416 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#10439 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10485 + sig { override.returns(String) } + def inspect; end + + # The name of the instance variable, which is a `@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers). + # + # @x = :y # name `:@x` + # + # @_foo = "bar" # name `@_foo` + # + # source://prism//lib/prism/node.rb#10448 + sig { returns(Symbol) } + def name; end + + # The location of the variable name. + # + # @_x = 1 + # ^^^ + # + # source://prism//lib/prism/node.rb#10454 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#10480 + sig { returns(String) } + def operator; end + + # The location of the `=` operator. + # + # @x = y + # ^ + # + # source://prism//lib/prism/node.rb#10473 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10503 + sig { override.returns(Symbol) } + def type; end + + # The value to write to the instance variable. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # @foo = :bar + # ^^^^ + # + # @_x = 1234 + # ^^^^ + # + # source://prism//lib/prism/node.rb#10467 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10513 + def type; end + end +end + +# Flags for integer nodes that correspond to the base of the integer. +# +# source://prism//lib/prism/node.rb#19166 +module Prism::IntegerBaseFlags; end + +# 0b prefix +# +# source://prism//lib/prism/node.rb#19168 +Prism::IntegerBaseFlags::BINARY = T.let(T.unsafe(nil), Integer) + +# 0d or no prefix +# +# source://prism//lib/prism/node.rb#19171 +Prism::IntegerBaseFlags::DECIMAL = T.let(T.unsafe(nil), Integer) + +# 0x prefix +# +# source://prism//lib/prism/node.rb#19177 +Prism::IntegerBaseFlags::HEXADECIMAL = T.let(T.unsafe(nil), Integer) + +# 0o or 0 prefix +# +# source://prism//lib/prism/node.rb#19174 +Prism::IntegerBaseFlags::OCTAL = T.let(T.unsafe(nil), Integer) + +# Represents an integer number literal. +# +# 1 +# ^ +# +# source://prism//lib/prism/node.rb#10532 +class Prism::IntegerNode < ::Prism::Node + # def initialize: (Integer flags, Integer value, Location location) -> void + # + # @return [IntegerNode] a new instance of IntegerNode + # + # source://prism//lib/prism/node.rb#10534 + sig { params(source: Prism::Source, flags: Integer, value: Integer, location: Prism::Location).void } + def initialize(source, flags, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10636 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#10542 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def binary?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10582 + sig { returns(T::Boolean) } + def binary?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10547 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10557 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10552 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?value: Integer, ?location: Location) -> IntegerNode + # + # source://prism//lib/prism/node.rb#10562 + sig { params(flags: Integer, value: Integer, location: Prism::Location).returns(Prism::IntegerNode) } + def copy(flags: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def decimal?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10587 + sig { returns(T::Boolean) } + def decimal?; end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10547 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, value: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#10570 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def hexadecimal?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10597 + sig { returns(T::Boolean) } + def hexadecimal?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10602 + sig { override.returns(String) } + def inspect; end + + # def octal?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10592 + sig { returns(T::Boolean) } + def octal?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10620 + sig { override.returns(Symbol) } + def type; end + + # The value of the integer literal as a number. + # + # source://prism//lib/prism/node.rb#10579 + sig { returns(Integer) } + def value; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#10575 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10630 + def type; end + end +end + +# Represents a regular expression literal that contains interpolation that is being used in the predicate of a conditional to implicitly match against the last line read by an IO object. +# +# if /foo #{bar} baz/ then end +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#10647 +class Prism::InterpolatedMatchLastLineNode < ::Prism::Node + include ::Prism::RegularExpressionOptions + + # def initialize: (Integer flags, Location opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location closing_loc, Location location) -> void + # + # @return [InterpolatedMatchLastLineNode] a new instance of InterpolatedMatchLastLineNode + # + # source://prism//lib/prism/node.rb#10649 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: Prism::Location, + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, parts, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10812 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#10659 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def ascii_8bit?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10738 + sig { returns(T::Boolean) } + def ascii_8bit?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10664 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#10773 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#10706 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10674 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10669 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?opening_loc: Location, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location, ?location: Location) -> InterpolatedMatchLastLineNode + # + # source://prism//lib/prism/node.rb#10679 + sig do + params( + flags: Integer, + opening_loc: Prism::Location, + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::InterpolatedMatchLastLineNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10664 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#10687 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def euc_jp?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10733 + sig { returns(T::Boolean) } + def euc_jp?; end + + # def extended?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10718 + sig { returns(T::Boolean) } + def extended?; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10758 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_us_ascii_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10763 + sig { returns(T::Boolean) } + def forced_us_ascii_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10753 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + # def ignore_case?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10713 + sig { returns(T::Boolean) } + def ignore_case?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10778 + sig { override.returns(String) } + def inspect; end + + # def multi_line?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10723 + sig { returns(T::Boolean) } + def multi_line?; end + + # source://prism//lib/prism/parse_result/newlines.rb#121 + def newline!(lines); end + + # def once?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10728 + sig { returns(T::Boolean) } + def once?; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#10768 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#10696 + sig { returns(Prism::Location) } + def opening_loc; end + + sig { returns(Integer) } + def options; end + + # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] + # + # source://prism//lib/prism/node.rb#10703 + sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) } + def parts; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10796 + sig { override.returns(Symbol) } + def type; end + + # def utf_8?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10748 + sig { returns(T::Boolean) } + def utf_8?; end + + # def windows_31j?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10743 + sig { returns(T::Boolean) } + def windows_31j?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#10692 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10806 + def type; end + end +end + +# Represents a regular expression literal that contains interpolation. +# +# /foo #{bar} baz/ +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#10826 +class Prism::InterpolatedRegularExpressionNode < ::Prism::Node + include ::Prism::RegularExpressionOptions + + # def initialize: (Integer flags, Location opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location closing_loc, Location location) -> void + # + # @return [InterpolatedRegularExpressionNode] a new instance of InterpolatedRegularExpressionNode + # + # source://prism//lib/prism/node.rb#10828 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: Prism::Location, + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, parts, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#10991 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#10838 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def ascii_8bit?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10917 + sig { returns(T::Boolean) } + def ascii_8bit?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10843 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#10952 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#10885 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#10853 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#10848 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?opening_loc: Location, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location, ?location: Location) -> InterpolatedRegularExpressionNode + # + # source://prism//lib/prism/node.rb#10858 + sig do + params( + flags: Integer, + opening_loc: Prism::Location, + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::InterpolatedRegularExpressionNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#10843 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#10866 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def euc_jp?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10912 + sig { returns(T::Boolean) } + def euc_jp?; end + + # def extended?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10897 + sig { returns(T::Boolean) } + def extended?; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10937 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_us_ascii_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10942 + sig { returns(T::Boolean) } + def forced_us_ascii_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10932 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + # def ignore_case?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10892 + sig { returns(T::Boolean) } + def ignore_case?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#10957 + sig { override.returns(String) } + def inspect; end + + # def multi_line?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10902 + sig { returns(T::Boolean) } + def multi_line?; end + + # source://prism//lib/prism/parse_result/newlines.rb#128 + def newline!(lines); end + + # def once?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10907 + sig { returns(T::Boolean) } + def once?; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#10947 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#10875 + sig { returns(Prism::Location) } + def opening_loc; end + + sig { returns(Integer) } + def options; end + + # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] + # + # source://prism//lib/prism/node.rb#10882 + sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) } + def parts; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10975 + sig { override.returns(Symbol) } + def type; end + + # def utf_8?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10927 + sig { returns(T::Boolean) } + def utf_8?; end + + # def windows_31j?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#10922 + sig { returns(T::Boolean) } + def windows_31j?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#10871 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#10985 + def type; end + end +end + +# Represents a string literal that contains interpolation. +# +# "foo #{bar} baz" +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#11005 +class Prism::InterpolatedStringNode < ::Prism::Node + include ::Prism::HeredocQuery + + # def initialize: (Integer flags, Location? opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode] parts, Location? closing_loc, Location location) -> void + # + # @return [InterpolatedStringNode] a new instance of InterpolatedStringNode + # + # source://prism//lib/prism/node.rb#11007 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: T.nilable(Prism::Location), + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode, Prism::InterpolatedStringNode)], + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, parts, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11137 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11017 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11022 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#11098 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#11070 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11032 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11027 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?opening_loc: Location?, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode], ?closing_loc: Location?, ?location: Location) -> InterpolatedStringNode + # + # source://prism//lib/prism/node.rb#11037 + sig do + params( + flags: Integer, + opening_loc: T.nilable(Prism::Location), + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode, Prism::InterpolatedStringNode)], + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::InterpolatedStringNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11022 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location?, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode], closing_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#11045 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def frozen?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#11083 + sig { returns(T::Boolean) } + def frozen?; end + + sig { returns(T::Boolean) } + def heredoc?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11103 + sig { override.returns(String) } + def inspect; end + + # def mutable?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#11088 + sig { returns(T::Boolean) } + def mutable?; end + + # source://prism//lib/prism/parse_result/newlines.rb#135 + def newline!(lines); end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#11093 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#11054 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode] + # + # source://prism//lib/prism/node.rb#11067 + sig do + returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode, Prism::InterpolatedStringNode)]) + end + def parts; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11121 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#11050 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11131 + def type; end + end +end + +# Flags for interpolated string nodes that indicated mutability if they are also marked as literals. +# +# source://prism//lib/prism/node.rb#19181 +module Prism::InterpolatedStringNodeFlags; end + +# source://prism//lib/prism/node.rb#19183 +Prism::InterpolatedStringNodeFlags::FROZEN = T.let(T.unsafe(nil), Integer) + +# source://prism//lib/prism/node.rb#19186 +Prism::InterpolatedStringNodeFlags::MUTABLE = T.let(T.unsafe(nil), Integer) + +# Represents a symbol literal that contains interpolation. +# +# :"foo #{bar} baz" +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#11151 +class Prism::InterpolatedSymbolNode < ::Prism::Node + # def initialize: (Location? opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location? closing_loc, Location location) -> void + # + # @return [InterpolatedSymbolNode] a new instance of InterpolatedSymbolNode + # + # source://prism//lib/prism/node.rb#11153 + sig do + params( + source: Prism::Source, + opening_loc: T.nilable(Prism::Location), + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, opening_loc, parts, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11268 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11162 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11167 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#11229 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#11211 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11177 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11172 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?opening_loc: Location?, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location?, ?location: Location) -> InterpolatedSymbolNode + # + # source://prism//lib/prism/node.rb#11182 + sig do + params( + opening_loc: T.nilable(Prism::Location), + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::InterpolatedSymbolNode) + end + def copy(opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11167 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location?, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#11190 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11234 + sig { override.returns(String) } + def inspect; end + + # source://prism//lib/prism/parse_result/newlines.rb#142 + def newline!(lines); end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#11224 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#11195 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] + # + # source://prism//lib/prism/node.rb#11208 + sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) } + def parts; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11252 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11262 + def type; end + end +end + +# Represents an xstring literal that contains interpolation. +# +# `foo #{bar} baz` +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#11281 +class Prism::InterpolatedXStringNode < ::Prism::Node + include ::Prism::HeredocQuery + + # def initialize: (Location opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location closing_loc, Location location) -> void + # + # @return [InterpolatedXStringNode] a new instance of InterpolatedXStringNode + # + # source://prism//lib/prism/node.rb#11283 + sig do + params( + source: Prism::Source, + opening_loc: Prism::Location, + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, opening_loc, parts, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11386 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11292 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11297 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#11347 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#11335 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11307 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11302 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?opening_loc: Location, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location, ?location: Location) -> InterpolatedXStringNode + # + # source://prism//lib/prism/node.rb#11312 + sig do + params( + opening_loc: Prism::Location, + parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)], + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::InterpolatedXStringNode) + end + def copy(opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11297 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#11320 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + sig { returns(T::Boolean) } + def heredoc?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11352 + sig { override.returns(String) } + def inspect; end + + # source://prism//lib/prism/parse_result/newlines.rb#149 + def newline!(lines); end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#11342 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#11325 + sig { returns(Prism::Location) } + def opening_loc; end + + # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] + # + # source://prism//lib/prism/node.rb#11332 + sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) } + def parts; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11370 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11380 + def type; end + end +end + +# Represents reading from the implicit `it` local variable. +# +# -> { it } +# ^^ +# +# source://prism//lib/prism/node.rb#11399 +class Prism::ItLocalVariableReadNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [ItLocalVariableReadNode] a new instance of ItLocalVariableReadNode + # + # source://prism//lib/prism/node.rb#11401 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11474 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11407 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11412 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11422 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11417 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> ItLocalVariableReadNode + # + # source://prism//lib/prism/node.rb#11427 + sig { params(location: Prism::Location).returns(Prism::ItLocalVariableReadNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11412 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#11435 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11440 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11458 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11468 + def type; end + end +end + +# Represents an implicit set of parameters through the use of the `it` keyword within a block or lambda. +# +# -> { it + it } +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#11483 +class Prism::ItParametersNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [ItParametersNode] a new instance of ItParametersNode + # + # source://prism//lib/prism/node.rb#11485 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11558 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11491 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11496 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11506 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11501 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> ItParametersNode + # + # source://prism//lib/prism/node.rb#11511 + sig { params(location: Prism::Location).returns(Prism::ItParametersNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11496 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#11519 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11524 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11542 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11552 + def type; end + end +end + +# Represents a hash literal without opening and closing braces. +# +# foo(a: b) +# ^^^^ +# +# source://prism//lib/prism/node.rb#11567 +class Prism::KeywordHashNode < ::Prism::Node + # def initialize: (Integer flags, Array[AssocNode | AssocSplatNode] elements, Location location) -> void + # + # @return [KeywordHashNode] a new instance of KeywordHashNode + # + # source://prism//lib/prism/node.rb#11569 + sig do + params( + source: Prism::Source, + flags: Integer, + elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)], + location: Prism::Location + ).void + end + def initialize(source, flags, elements, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11656 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11577 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11582 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11592 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11587 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?elements: Array[AssocNode | AssocSplatNode], ?location: Location) -> KeywordHashNode + # + # source://prism//lib/prism/node.rb#11597 + sig do + params( + flags: Integer, + elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)], + location: Prism::Location + ).returns(Prism::KeywordHashNode) + end + def copy(flags: T.unsafe(nil), elements: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11582 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, elements: Array[AssocNode | AssocSplatNode], location: Location } + # + # source://prism//lib/prism/node.rb#11605 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader elements: Array[AssocNode | AssocSplatNode] + # + # source://prism//lib/prism/node.rb#11614 + sig { returns(T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)]) } + def elements; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11622 + sig { override.returns(String) } + def inspect; end + + # def symbol_keys?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#11617 + sig { returns(T::Boolean) } + def symbol_keys?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11640 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#11610 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11650 + def type; end + end +end + +# Flags for keyword hash nodes. +# +# source://prism//lib/prism/node.rb#19190 +module Prism::KeywordHashNodeFlags; end + +# a keyword hash which only has `AssocNode` elements all with symbol keys, which means the elements can be treated as keyword arguments +# +# source://prism//lib/prism/node.rb#19192 +Prism::KeywordHashNodeFlags::SYMBOL_KEYS = T.let(T.unsafe(nil), Integer) + +# Represents a keyword rest parameter to a method, block, or lambda definition. +# +# def a(**b) +# ^^^ +# end +# +# source://prism//lib/prism/node.rb#11669 +class Prism::KeywordRestParameterNode < ::Prism::Node + # def initialize: (Integer flags, Symbol? name, Location? name_loc, Location operator_loc, Location location) -> void + # + # @return [KeywordRestParameterNode] a new instance of KeywordRestParameterNode + # + # source://prism//lib/prism/node.rb#11671 + sig do + params( + source: Prism::Source, + flags: Integer, + name: T.nilable(Symbol), + name_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, name, name_loc, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11785 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11681 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11686 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11696 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11691 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol?, ?name_loc: Location?, ?operator_loc: Location, ?location: Location) -> KeywordRestParameterNode + # + # source://prism//lib/prism/node.rb#11701 + sig do + params( + flags: Integer, + name: T.nilable(Symbol), + name_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::KeywordRestParameterNode) + end + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11686 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol?, name_loc: Location?, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#11709 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11751 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol? + # + # source://prism//lib/prism/node.rb#11718 + sig { returns(T.nilable(Symbol)) } + def name; end + + # attr_reader name_loc: Location? + # + # source://prism//lib/prism/node.rb#11721 + sig { returns(T.nilable(Prism::Location)) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#11746 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#11734 + sig { returns(Prism::Location) } + def operator_loc; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#11741 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11769 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#11714 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11779 + def type; end + end +end + +# Represents using a lambda literal (not the lambda method call). +# +# ->(value) { value * 2 } +# ^^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#11798 +class Prism::LambdaNode < ::Prism::Node + # def initialize: (Array[Symbol] locals, Location operator_loc, Location opening_loc, Location closing_loc, Prism::node? parameters, Prism::node? body, Location location) -> void + # + # @return [LambdaNode] a new instance of LambdaNode + # + # source://prism//lib/prism/node.rb#11800 + sig do + params( + source: Prism::Source, + locals: T::Array[Symbol], + operator_loc: Prism::Location, + opening_loc: Prism::Location, + closing_loc: Prism::Location, + parameters: T.nilable(Prism::Node), + body: T.nilable(Prism::Node), + location: Prism::Location + ).void + end + def initialize(source, locals, operator_loc, opening_loc, closing_loc, parameters, body, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#11927 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11812 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Prism::node? + # + # source://prism//lib/prism/node.rb#11875 + sig { returns(T.nilable(Prism::Node)) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11817 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#11888 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#11865 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11830 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11822 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?locals: Array[Symbol], ?operator_loc: Location, ?opening_loc: Location, ?closing_loc: Location, ?parameters: Prism::node?, ?body: Prism::node?, ?location: Location) -> LambdaNode + # + # source://prism//lib/prism/node.rb#11835 + sig do + params( + locals: T::Array[Symbol], + operator_loc: Prism::Location, + opening_loc: Prism::Location, + closing_loc: Prism::Location, + parameters: T.nilable(Prism::Node), + body: T.nilable(Prism::Node), + location: Prism::Location + ).returns(Prism::LambdaNode) + end + def copy(locals: T.unsafe(nil), operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), parameters: T.unsafe(nil), body: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11817 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], operator_loc: Location, opening_loc: Location, closing_loc: Location, parameters: Prism::node?, body: Prism::node?, location: Location } + # + # source://prism//lib/prism/node.rb#11843 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#11893 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[Symbol] + # + # source://prism//lib/prism/node.rb#11848 + sig { returns(T::Array[Symbol]) } + def locals; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#11883 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#11858 + sig { returns(Prism::Location) } + def opening_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#11878 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#11851 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader parameters: Prism::node? + # + # source://prism//lib/prism/node.rb#11872 + sig { returns(T.nilable(Prism::Node)) } + def parameters; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11911 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#11921 + def type; end + end +end + +# This class is responsible for lexing the source using prism and then +# converting those tokens to be compatible with Ripper. In the vast majority +# of cases, this is a one-to-one mapping of the token type. Everything else +# generally lines up. However, there are a few cases that require special +# handling. +# +# source://prism//lib/prism/lex_compat.rb#12 +class Prism::LexCompat + # @return [LexCompat] a new instance of LexCompat + # + # source://prism//lib/prism/lex_compat.rb#619 + def initialize(source, **options); end + + # Returns the value of attribute options. + # + # source://prism//lib/prism/lex_compat.rb#617 + def options; end + + # source://prism//lib/prism/lex_compat.rb#624 + def result; end + + # Returns the value of attribute source. + # + # source://prism//lib/prism/lex_compat.rb#617 + def source; end +end + +# Ripper doesn't include the rest of the token in the event, so we need to +# trim it down to just the content on the first line when comparing. +# +# source://prism//lib/prism/lex_compat.rb#230 +class Prism::LexCompat::EndContentToken < ::Prism::LexCompat::Token + # source://prism//lib/prism/lex_compat.rb#231 + def ==(other); end +end + +# A heredoc in this case is a list of tokens that belong to the body of the +# heredoc that should be appended onto the list of tokens when the heredoc +# closes. +# +# source://prism//lib/prism/lex_compat.rb#291 +module Prism::LexCompat::Heredoc + class << self + # Here we will split between the two types of heredocs and return the + # object that will store their tokens. + # + # source://prism//lib/prism/lex_compat.rb#603 + def build(opening); end + end +end + +# Dash heredocs are a little more complicated. They are a list of tokens +# that need to be split on "\\\n" to mimic Ripper's behavior. We also need +# to keep track of the state that the heredoc was opened in. +# +# source://prism//lib/prism/lex_compat.rb#315 +class Prism::LexCompat::Heredoc::DashHeredoc + # @return [DashHeredoc] a new instance of DashHeredoc + # + # source://prism//lib/prism/lex_compat.rb#318 + def initialize(split); end + + # source://prism//lib/prism/lex_compat.rb#323 + def <<(token); end + + # source://prism//lib/prism/lex_compat.rb#316 + def split; end + + # source://prism//lib/prism/lex_compat.rb#327 + def to_a; end + + # source://prism//lib/prism/lex_compat.rb#316 + def tokens; end +end + +# Heredocs that are dedenting heredocs are a little more complicated. +# Ripper outputs on_ignored_sp tokens for the whitespace that is being +# removed from the output. prism only modifies the node itself and keeps +# the token the same. This simplifies prism, but makes comparing against +# Ripper much harder because there is a length mismatch. +# +# Fortunately, we already have to pull out the heredoc tokens in order to +# insert them into the stream in the correct order. As such, we can do +# some extra manipulation on the tokens to make them match Ripper's +# output by mirroring the dedent logic that Ripper uses. +# +# source://prism//lib/prism/lex_compat.rb#374 +class Prism::LexCompat::Heredoc::DedentingHeredoc + # @return [DedentingHeredoc] a new instance of DedentingHeredoc + # + # source://prism//lib/prism/lex_compat.rb#379 + def initialize; end + + # As tokens are coming in, we track the minimum amount of common leading + # whitespace on plain string content tokens. This allows us to later + # remove that amount of whitespace from the beginning of each line. + # + # source://prism//lib/prism/lex_compat.rb#390 + def <<(token); end + + # Returns the value of attribute dedent. + # + # source://prism//lib/prism/lex_compat.rb#377 + def dedent; end + + # Returns the value of attribute dedent_next. + # + # source://prism//lib/prism/lex_compat.rb#377 + def dedent_next; end + + # Returns the value of attribute embexpr_balance. + # + # source://prism//lib/prism/lex_compat.rb#377 + def embexpr_balance; end + + # source://prism//lib/prism/lex_compat.rb#427 + def to_a; end + + # Returns the value of attribute tokens. + # + # source://prism//lib/prism/lex_compat.rb#377 + def tokens; end +end + +# source://prism//lib/prism/lex_compat.rb#375 +Prism::LexCompat::Heredoc::DedentingHeredoc::TAB_WIDTH = T.let(T.unsafe(nil), Integer) + +# Heredocs that are no dash or tilde heredocs are just a list of tokens. +# We need to keep them around so that we can insert them in the correct +# order back into the token stream and set the state of the last token to +# the state that the heredoc was opened in. +# +# source://prism//lib/prism/lex_compat.rb#296 +class Prism::LexCompat::Heredoc::PlainHeredoc + # @return [PlainHeredoc] a new instance of PlainHeredoc + # + # source://prism//lib/prism/lex_compat.rb#299 + def initialize; end + + # source://prism//lib/prism/lex_compat.rb#303 + def <<(token); end + + # source://prism//lib/prism/lex_compat.rb#307 + def to_a; end + + # source://prism//lib/prism/lex_compat.rb#297 + def tokens; end +end + +# Ident tokens for the most part are exactly the same, except sometimes we +# know an ident is a local when ripper doesn't (when they are introduced +# through named captures in regular expressions). In that case we don't +# compare the state. +# +# source://prism//lib/prism/lex_compat.rb#248 +class Prism::LexCompat::IdentToken < ::Prism::LexCompat::Token + # source://prism//lib/prism/lex_compat.rb#249 + def ==(other); end +end + +# Tokens where state should be ignored +# used for :on_comment, :on_heredoc_end, :on_embexpr_end +# +# source://prism//lib/prism/lex_compat.rb#238 +class Prism::LexCompat::IgnoreStateToken < ::Prism::LexCompat::Token + # source://prism//lib/prism/lex_compat.rb#239 + def ==(other); end +end + +# Ignored newlines can occasionally have a LABEL state attached to them, so +# we compare the state differently here. +# +# source://prism//lib/prism/lex_compat.rb#259 +class Prism::LexCompat::IgnoredNewlineToken < ::Prism::LexCompat::Token + # source://prism//lib/prism/lex_compat.rb#260 + def ==(other); end +end + +# If we have an identifier that follows a method name like: +# +# def foo bar +# +# then Ripper will mark bar as END|LABEL if there is a local in a parent +# scope named bar because it hasn't pushed the local table yet. We do this +# more accurately, so we need to allow comparing against both END and +# END|LABEL. +# +# source://prism//lib/prism/lex_compat.rb#279 +class Prism::LexCompat::ParamToken < ::Prism::LexCompat::Token + # source://prism//lib/prism/lex_compat.rb#280 + def ==(other); end +end + +# This is a mapping of prism token types to Ripper token types. This is a +# many-to-one mapping because we split up our token types, whereas Ripper +# tends to group them. +# +# source://prism//lib/prism/lex_compat.rb#33 +Prism::LexCompat::RIPPER = T.let(T.unsafe(nil), Hash) + +# A result class specialized for holding tokens produced by the lexer. +# +# source://prism//lib/prism/lex_compat.rb#14 +class Prism::LexCompat::Result < ::Prism::Result + # Create a new lex compat result object with the given values. + # + # @return [Result] a new instance of Result + # + # source://prism//lib/prism/lex_compat.rb#19 + def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end + + # Implement the hash pattern matching interface for Result. + # + # source://prism//lib/prism/lex_compat.rb#25 + def deconstruct_keys(keys); end + + # The list of tokens that were produced by the lexer. + # + # source://prism//lib/prism/lex_compat.rb#16 + def value; end +end + +# When we produce tokens, we produce the same arrays that Ripper does. +# However, we add a couple of convenience methods onto them to make them a +# little easier to work with. We delegate all other methods to the array. +# +# source://prism//lib/prism/lex_compat.rb#204 +class Prism::LexCompat::Token < ::SimpleDelegator + # The type of the token. + # + # source://prism//lib/prism/lex_compat.rb#213 + def event; end + + # The location of the token in the source. + # + # source://prism//lib/prism/lex_compat.rb#208 + def location; end + + # The state of the lexer when this token was produced. + # + # source://prism//lib/prism/lex_compat.rb#223 + def state; end + + # The slice of the source that this token represents. + # + # source://prism//lib/prism/lex_compat.rb#218 + def value; end +end + +# This is a result specific to the `lex` and `lex_file` methods. +# +# source://prism//lib/prism/parse_result.rb#610 +class Prism::LexResult < ::Prism::Result + # Create a new lex result object with the given values. + # + # @return [LexResult] a new instance of LexResult + # + # source://prism//lib/prism/parse_result.rb#615 + sig do + params( + value: T::Array[T.untyped], + comments: T::Array[Prism::Comment], + magic_comments: T::Array[Prism::MagicComment], + data_loc: T.nilable(Prism::Location), + errors: T::Array[Prism::ParseError], + warnings: T::Array[Prism::ParseWarning], + source: Prism::Source + ).void + end + def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end + + # Implement the hash pattern matching interface for LexResult. + # + # source://prism//lib/prism/parse_result.rb#621 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # The list of tokens that were parsed from the source code. + # + # source://prism//lib/prism/parse_result.rb#612 + sig { returns(T::Array[T.untyped]) } + def value; end +end + +# This is a class that wraps the Ripper lexer to produce almost exactly the +# same tokens. +# +# source://prism//lib/prism/lex_compat.rb#872 +class Prism::LexRipper + # @return [LexRipper] a new instance of LexRipper + # + # source://prism//lib/prism/lex_compat.rb#875 + def initialize(source); end + + # source://prism//lib/prism/lex_compat.rb#879 + def result; end + + # source://prism//lib/prism/lex_compat.rb#873 + def source; end + + private + + # source://prism//lib/prism/lex_compat.rb#913 + def lex(source); end +end + +# Represents the use of the `&&=` operator for assignment to a local variable. +# +# target &&= value +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#11943 +class Prism::LocalVariableAndWriteNode < ::Prism::Node + # def initialize: (Location name_loc, Location operator_loc, Prism::node value, Symbol name, Integer depth, Location location) -> void + # + # @return [LocalVariableAndWriteNode] a new instance of LocalVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#11945 + sig do + params( + source: Prism::Source, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + name: Symbol, + depth: Integer, + location: Prism::Location + ).void + end + def initialize(source, name_loc, operator_loc, value, name, depth, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12051 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#11956 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11961 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#11971 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#11966 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableAndWriteNode + # + # source://prism//lib/prism/node.rb#11976 + sig do + params( + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + name: Symbol, + depth: Integer, + location: Prism::Location + ).returns(Prism::LocalVariableAndWriteNode) + end + def copy(name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#11961 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name_loc: Location, operator_loc: Location, value: Prism::node, name: Symbol, depth: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#11984 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader depth: Integer + # + # source://prism//lib/prism/node.rb#12009 + sig { returns(Integer) } + def depth; end + + # source://prism//lib/prism/desugar_compiler.rb#199 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12017 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#12006 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#11989 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#12012 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#11996 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12035 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#12003 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12045 + def type; end + end +end + +# Represents assigning to a local variable using an operator that isn't `=`. +# +# target += value +# ^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#12065 +class Prism::LocalVariableOperatorWriteNode < ::Prism::Node + # def initialize: (Location name_loc, Location binary_operator_loc, Prism::node value, Symbol name, Symbol binary_operator, Integer depth, Location location) -> void + # + # @return [LocalVariableOperatorWriteNode] a new instance of LocalVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#12067 + sig do + params( + source: Prism::Source, + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + name: Symbol, + binary_operator: Symbol, + depth: Integer, + location: Prism::Location + ).void + end + def initialize(source, name_loc, binary_operator_loc, value, name, binary_operator, depth, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12172 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12079 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader binary_operator: Symbol + # + # source://prism//lib/prism/node.rb#12132 + sig { returns(Symbol) } + def binary_operator; end + + # attr_reader binary_operator_loc: Location + # + # source://prism//lib/prism/node.rb#12119 + sig { returns(Prism::Location) } + def binary_operator_loc; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12084 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12094 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12089 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?name: Symbol, ?binary_operator: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableOperatorWriteNode + # + # source://prism//lib/prism/node.rb#12099 + sig do + params( + name_loc: Prism::Location, + binary_operator_loc: Prism::Location, + value: Prism::Node, + name: Symbol, + binary_operator: Symbol, + depth: Integer, + location: Prism::Location + ).returns(Prism::LocalVariableOperatorWriteNode) + end + def copy(name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), name: T.unsafe(nil), binary_operator: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12084 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name_loc: Location, binary_operator_loc: Location, value: Prism::node, name: Symbol, binary_operator: Symbol, depth: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#12107 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader depth: Integer + # + # source://prism//lib/prism/node.rb#12135 + sig { returns(Integer) } + def depth; end + + # source://prism//lib/prism/desugar_compiler.rb#211 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12138 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#12129 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#12112 + sig { returns(Prism::Location) } + def name_loc; end + + # Returns the binary operator used to modify the receiver. This method is + # deprecated in favor of #binary_operator. + # + # source://prism//lib/prism/node_ext.rb#435 + def operator; end + + # Returns the location of the binary operator used to modify the receiver. + # This method is deprecated in favor of #binary_operator_loc. + # + # source://prism//lib/prism/node_ext.rb#442 + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12156 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#12126 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12166 + def type; end + end +end + +# Represents the use of the `||=` operator for assignment to a local variable. +# +# target ||= value +# ^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#12187 +class Prism::LocalVariableOrWriteNode < ::Prism::Node + # def initialize: (Location name_loc, Location operator_loc, Prism::node value, Symbol name, Integer depth, Location location) -> void + # + # @return [LocalVariableOrWriteNode] a new instance of LocalVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#12189 + sig do + params( + source: Prism::Source, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + name: Symbol, + depth: Integer, + location: Prism::Location + ).void + end + def initialize(source, name_loc, operator_loc, value, name, depth, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12295 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12200 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12205 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12215 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12210 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableOrWriteNode + # + # source://prism//lib/prism/node.rb#12220 + sig do + params( + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + name: Symbol, + depth: Integer, + location: Prism::Location + ).returns(Prism::LocalVariableOrWriteNode) + end + def copy(name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12205 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name_loc: Location, operator_loc: Location, value: Prism::node, name: Symbol, depth: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#12228 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader depth: Integer + # + # source://prism//lib/prism/node.rb#12253 + sig { returns(Integer) } + def depth; end + + # source://prism//lib/prism/desugar_compiler.rb#205 + def desugar; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12261 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#12250 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#12233 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#12256 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#12240 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12279 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#12247 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12289 + def type; end + end +end + +# Represents reading a local variable. Note that this requires that a local variable of the same name has already been written to in the same scope, otherwise it is parsed as a method call. +# +# foo +# ^^^ +# +# source://prism//lib/prism/node.rb#12309 +class Prism::LocalVariableReadNode < ::Prism::Node + # def initialize: (Symbol name, Integer depth, Location location) -> void + # + # @return [LocalVariableReadNode] a new instance of LocalVariableReadNode + # + # source://prism//lib/prism/node.rb#12311 + sig { params(source: Prism::Source, name: Symbol, depth: Integer, location: Prism::Location).void } + def initialize(source, name, depth, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12406 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12319 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12324 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12334 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12329 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableReadNode + # + # source://prism//lib/prism/node.rb#12339 + sig { params(name: Symbol, depth: Integer, location: Prism::Location).returns(Prism::LocalVariableReadNode) } + def copy(name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12324 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, depth: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#12347 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # The number of visible scopes that should be searched to find the origin of this local variable. + # + # foo = 1; foo # depth 0 + # + # bar = 2; tap { bar } # depth 1 + # + # The specific rules for calculating the depth may differ from individual Ruby implementations, as they are not specified by the language. For more information, see [the Prism documentation](https://github.com/ruby/prism/blob/main/docs/local_variable_depth.md). + # + # source://prism//lib/prism/node.rb#12369 + sig { returns(Integer) } + def depth; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12372 + sig { override.returns(String) } + def inspect; end + + # The name of the local variable, which is an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers). + # + # x # name `:x` + # + # _Test # name `:_Test` + # + # Note that this can also be an underscore followed by a number for the default block parameters. + # + # _1 # name `:_1` + # + # source://prism//lib/prism/node.rb#12360 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12390 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12400 + def type; end + end +end + +# Represents writing to a local variable in a context that doesn't have an explicit value. +# +# foo, bar = baz +# ^^^ ^^^ +# +# source://prism//lib/prism/node.rb#12417 +class Prism::LocalVariableTargetNode < ::Prism::Node + # def initialize: (Symbol name, Integer depth, Location location) -> void + # + # @return [LocalVariableTargetNode] a new instance of LocalVariableTargetNode + # + # source://prism//lib/prism/node.rb#12419 + sig { params(source: Prism::Source, name: Symbol, depth: Integer, location: Prism::Location).void } + def initialize(source, name, depth, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12500 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12427 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12432 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12442 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12437 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableTargetNode + # + # source://prism//lib/prism/node.rb#12447 + sig { params(name: Symbol, depth: Integer, location: Prism::Location).returns(Prism::LocalVariableTargetNode) } + def copy(name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12432 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, depth: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#12455 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader depth: Integer + # + # source://prism//lib/prism/node.rb#12463 + sig { returns(Integer) } + def depth; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12466 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#12460 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12484 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12494 + def type; end + end +end + +# Represents writing to a local variable. +# +# foo = 1 +# ^^^^^^^ +# +# source://prism//lib/prism/node.rb#12511 +class Prism::LocalVariableWriteNode < ::Prism::Node + # def initialize: (Symbol name, Integer depth, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void + # + # @return [LocalVariableWriteNode] a new instance of LocalVariableWriteNode + # + # source://prism//lib/prism/node.rb#12513 + sig do + params( + source: Prism::Source, + name: Symbol, + depth: Integer, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, name, depth, name_loc, value, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12645 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12524 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12529 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12539 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12534 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?name: Symbol, ?depth: Integer, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> LocalVariableWriteNode + # + # source://prism//lib/prism/node.rb#12544 + sig do + params( + name: Symbol, + depth: Integer, + name_loc: Prism::Location, + value: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::LocalVariableWriteNode) + end + def copy(name: T.unsafe(nil), depth: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12529 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, depth: Integer, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#12552 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # The number of semantic scopes we have to traverse to find the declaration of this variable. + # + # foo = 1 # depth 0 + # + # tap { foo = 1 } # depth 1 + # + # The specific rules for calculating the depth may differ from individual Ruby implementations, as they are not specified by the language. For more information, see [the Prism documentation](https://github.com/ruby/prism/blob/main/docs/local_variable_depth.md). + # + # source://prism//lib/prism/node.rb#12570 + sig { returns(Integer) } + def depth; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12611 + sig { override.returns(String) } + def inspect; end + + # The name of the local variable, which is an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers). + # + # foo = :bar # name `:foo` + # + # abc = 123 # name `:abc` + # + # source://prism//lib/prism/node.rb#12561 + sig { returns(Symbol) } + def name; end + + # The location of the variable name. + # + # foo = :bar + # ^^^ + # + # source://prism//lib/prism/node.rb#12576 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#12606 + sig { returns(String) } + def operator; end + + # The location of the `=` operator. + # + # x = :y + # ^ + # + # source://prism//lib/prism/node.rb#12599 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12629 + sig { override.returns(Symbol) } + def type; end + + # The value to write to the local variable. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # foo = :bar + # ^^^^ + # + # abc = 1234 + # ^^^^ + # + # Note that since the name of a local variable is known before the value is parsed, it is valid for a local variable to appear within the value of its own write. + # + # foo = foo + # + # source://prism//lib/prism/node.rb#12593 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12639 + def type; end + end +end + +# This represents a location in the source. +# +# source://prism//lib/prism/parse_result.rb#156 +class Prism::Location + # Create a new location object with the given source, start byte offset, and + # byte length. + # + # @return [Location] a new instance of Location + # + # source://prism//lib/prism/parse_result.rb#171 + sig { params(source: Prism::Source, start_offset: Integer, length: Integer).void } + def initialize(source, start_offset, length); end + + # Returns true if the given other location is equal to this location. + # + # source://prism//lib/prism/parse_result.rb#335 + sig { params(other: T.untyped).returns(T::Boolean) } + def ==(other); end + + # Join this location with the first occurrence of the string in the source + # that occurs after this location on the same line, and return the new + # location. This will raise an error if the string does not exist. + # + # source://prism//lib/prism/parse_result.rb#354 + sig { params(string: String).returns(Prism::Location) } + def adjoin(string); end + + # Returns a new location that is the result of chopping off the last byte. + # + # source://prism//lib/prism/parse_result.rb#217 + sig { returns(Prism::Location) } + def chop; end + + # Returns all comments that are associated with this location (both leading + # and trailing comments). + # + # source://prism//lib/prism/parse_result.rb#207 + sig { returns(T::Array[Prism::Comment]) } + def comments; end + + # Create a new location object with the given options. + # + # source://prism//lib/prism/parse_result.rb#212 + sig { params(source: Prism::Source, start_offset: Integer, length: Integer).returns(Prism::Location) } + def copy(source: T.unsafe(nil), start_offset: T.unsafe(nil), length: T.unsafe(nil)); end + + # Implement the hash pattern matching interface for Location. + # + # source://prism//lib/prism/parse_result.rb#325 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # The column number in characters where this location ends from the start of + # the line. + # + # source://prism//lib/prism/parse_result.rb#314 + sig { returns(Integer) } + def end_character_column; end + + # The character offset from the beginning of the source where this location + # ends. + # + # source://prism//lib/prism/parse_result.rb#263 + sig { returns(Integer) } + def end_character_offset; end + + # The column number in code units of the given encoding where this location + # ends from the start of the line. + # + # source://prism//lib/prism/parse_result.rb#320 + sig { params(encoding: Encoding).returns(Integer) } + def end_code_units_column(encoding = T.unsafe(nil)); end + + # The offset from the start of the file in code units of the given encoding. + # + # source://prism//lib/prism/parse_result.rb#268 + sig { params(encoding: Encoding).returns(Integer) } + def end_code_units_offset(encoding = T.unsafe(nil)); end + + # The column number in bytes where this location ends from the start of the + # line. + # + # source://prism//lib/prism/parse_result.rb#308 + sig { returns(Integer) } + def end_column; end + + # The line number where this location ends. + # + # source://prism//lib/prism/parse_result.rb#284 + sig { returns(Integer) } + def end_line; end + + # The byte offset from the beginning of the source where this location ends. + # + # source://prism//lib/prism/parse_result.rb#257 + sig { returns(Integer) } + def end_offset; end + + # Returns a string representation of this location. + # + # source://prism//lib/prism/parse_result.rb#222 + sig { returns(String) } + def inspect; end + + # Returns a new location that stretches from this location to the given + # other location. Raises an error if this location is not before the other + # location or if they don't share the same source. + # + # source://prism//lib/prism/parse_result.rb#344 + sig { params(other: Prism::Location).returns(Prism::Location) } + def join(other); end + + # Attach a comment to the leading comments of this location. + # + # source://prism//lib/prism/parse_result.rb#190 + sig { params(comment: Prism::Comment).void } + def leading_comment(comment); end + + # These are the comments that are associated with this location that exist + # before the start of this location. + # + # source://prism//lib/prism/parse_result.rb#185 + sig { returns(T::Array[Prism::Comment]) } + def leading_comments; end + + # The length of this location in bytes. + # + # source://prism//lib/prism/parse_result.rb#167 + sig { returns(Integer) } + def length; end + + # Implement the pretty print interface for Location. + # + # source://prism//lib/prism/parse_result.rb#330 + sig { params(q: T.untyped).void } + def pretty_print(q); end + + # The source code that this location represents. + # + # source://prism//lib/prism/parse_result.rb#232 + sig { returns(String) } + def slice; end + + # The source code that this location represents starting from the beginning + # of the line that this location starts on to the end of the line that this + # location ends on. + # + # source://prism//lib/prism/parse_result.rb#239 + def slice_lines; end + + # Returns all of the lines of the source code associated with this location. + # + # source://prism//lib/prism/parse_result.rb#227 + sig { returns(T::Array[String]) } + def source_lines; end + + # The column number in characters where this location ends from the start of + # the line. + # + # source://prism//lib/prism/parse_result.rb#296 + sig { returns(Integer) } + def start_character_column; end + + # The character offset from the beginning of the source where this location + # starts. + # + # source://prism//lib/prism/parse_result.rb#247 + sig { returns(Integer) } + def start_character_offset; end + + # The column number in code units of the given encoding where this location + # starts from the start of the line. + # + # source://prism//lib/prism/parse_result.rb#302 + sig { params(encoding: Encoding).returns(Integer) } + def start_code_units_column(encoding = T.unsafe(nil)); end + + # The offset from the start of the file in code units of the given encoding. + # + # source://prism//lib/prism/parse_result.rb#252 + sig { params(encoding: Encoding).returns(Integer) } + def start_code_units_offset(encoding = T.unsafe(nil)); end + + # The column number in bytes where this location starts from the start of + # the line. + # + # source://prism//lib/prism/parse_result.rb#290 + sig { returns(Integer) } + def start_column; end + + # The line number where this location starts. + # + # source://prism//lib/prism/parse_result.rb#273 + sig { returns(Integer) } + def start_line; end + + # The content of the line where this location starts before this location. + # + # source://prism//lib/prism/parse_result.rb#278 + sig { returns(String) } + def start_line_slice; end + + # The byte offset from the beginning of the source where this location + # starts. + # + # source://prism//lib/prism/parse_result.rb#164 + sig { returns(Integer) } + def start_offset; end + + # Attach a comment to the trailing comments of this location. + # + # source://prism//lib/prism/parse_result.rb#201 + sig { params(comment: Prism::Comment).void } + def trailing_comment(comment); end + + # These are the comments that are associated with this location that exist + # after the end of this location. + # + # source://prism//lib/prism/parse_result.rb#196 + sig { returns(T::Array[Prism::Comment]) } + def trailing_comments; end + + protected + + # A Source object that is used to determine more information from the given + # offset and length. + # + # source://prism//lib/prism/parse_result.rb#159 + sig { returns(Prism::Source) } + def source; end +end + +# Flags for while and until loop nodes. +# +# source://prism//lib/prism/node.rb#19196 +module Prism::LoopFlags; end + +# a loop after a begin statement, so the body is executed first before the condition +# +# source://prism//lib/prism/node.rb#19198 +Prism::LoopFlags::BEGIN_MODIFIER = T.let(T.unsafe(nil), Integer) + +# This represents a magic comment that was encountered during parsing. +# +# source://prism//lib/prism/parse_result.rb#416 +class Prism::MagicComment + # Create a new magic comment object with the given key and value locations. + # + # @return [MagicComment] a new instance of MagicComment + # + # source://prism//lib/prism/parse_result.rb#424 + sig { params(key_loc: Prism::Location, value_loc: Prism::Location).void } + def initialize(key_loc, value_loc); end + + # Implement the hash pattern matching interface for MagicComment. + # + # source://prism//lib/prism/parse_result.rb#440 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # Returns a string representation of this magic comment. + # + # source://prism//lib/prism/parse_result.rb#445 + sig { returns(String) } + def inspect; end + + # Returns the key of the magic comment by slicing it from the source code. + # + # source://prism//lib/prism/parse_result.rb#430 + sig { returns(String) } + def key; end + + # A Location object representing the location of the key in the source. + # + # source://prism//lib/prism/parse_result.rb#418 + sig { returns(Prism::Location) } + def key_loc; end + + # Returns the value of the magic comment by slicing it from the source code. + # + # source://prism//lib/prism/parse_result.rb#435 + sig { returns(String) } + def value; end + + # A Location object representing the location of the value in the source. + # + # source://prism//lib/prism/parse_result.rb#421 + sig { returns(Prism::Location) } + def value_loc; end +end + +# Represents a regular expression literal used in the predicate of a conditional to implicitly match against the last line read by an IO object. +# +# if /foo/i then end +# ^^^^^^ +# +# source://prism//lib/prism/node.rb#12659 +class Prism::MatchLastLineNode < ::Prism::Node + include ::Prism::RegularExpressionOptions + + # def initialize: (Integer flags, Location opening_loc, Location content_loc, Location closing_loc, String unescaped, Location location) -> void + # + # @return [MatchLastLineNode] a new instance of MatchLastLineNode + # + # source://prism//lib/prism/node.rb#12661 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: Prism::Location, + content_loc: Prism::Location, + closing_loc: Prism::Location, + unescaped: String, + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12837 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12672 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def ascii_8bit?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12758 + sig { returns(T::Boolean) } + def ascii_8bit?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12677 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#12798 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#12723 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12687 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12682 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def content: () -> String + # + # source://prism//lib/prism/node.rb#12793 + sig { returns(String) } + def content; end + + # attr_reader content_loc: Location + # + # source://prism//lib/prism/node.rb#12716 + sig { returns(Prism::Location) } + def content_loc; end + + # def copy: (?flags: Integer, ?opening_loc: Location, ?content_loc: Location, ?closing_loc: Location, ?unescaped: String, ?location: Location) -> MatchLastLineNode + # + # source://prism//lib/prism/node.rb#12692 + sig do + params( + flags: Integer, + opening_loc: Prism::Location, + content_loc: Prism::Location, + closing_loc: Prism::Location, + unescaped: String, + location: Prism::Location + ).returns(Prism::MatchLastLineNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12677 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, content_loc: Location, closing_loc: Location, unescaped: String, location: Location } + # + # source://prism//lib/prism/node.rb#12700 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def euc_jp?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12753 + sig { returns(T::Boolean) } + def euc_jp?; end + + # def extended?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12738 + sig { returns(T::Boolean) } + def extended?; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12778 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_us_ascii_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12783 + sig { returns(T::Boolean) } + def forced_us_ascii_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12773 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + # def ignore_case?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12733 + sig { returns(T::Boolean) } + def ignore_case?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12803 + sig { override.returns(String) } + def inspect; end + + # def multi_line?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12743 + sig { returns(T::Boolean) } + def multi_line?; end + + # def once?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12748 + sig { returns(T::Boolean) } + def once?; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#12788 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#12709 + sig { returns(Prism::Location) } + def opening_loc; end + + sig { returns(Integer) } + def options; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12821 + sig { override.returns(Symbol) } + def type; end + + # attr_reader unescaped: String + # + # source://prism//lib/prism/node.rb#12730 + sig { returns(String) } + def unescaped; end + + # def utf_8?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12768 + sig { returns(T::Boolean) } + def utf_8?; end + + # def windows_31j?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#12763 + sig { returns(T::Boolean) } + def windows_31j?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#12705 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12831 + def type; end + end +end + +# Represents the use of the modifier `in` operator. +# +# foo in bar +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#12851 +class Prism::MatchPredicateNode < ::Prism::Node + # def initialize: (Prism::node value, Prism::node pattern, Location operator_loc, Location location) -> void + # + # @return [MatchPredicateNode] a new instance of MatchPredicateNode + # + # source://prism//lib/prism/node.rb#12853 + sig do + params( + source: Prism::Source, + value: Prism::Node, + pattern: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, value, pattern, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#12947 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12862 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12867 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12877 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12872 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?value: Prism::node, ?pattern: Prism::node, ?operator_loc: Location, ?location: Location) -> MatchPredicateNode + # + # source://prism//lib/prism/node.rb#12882 + sig do + params( + value: Prism::Node, + pattern: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::MatchPredicateNode) + end + def copy(value: T.unsafe(nil), pattern: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12867 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, pattern: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#12890 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#12913 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#12908 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#12901 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader pattern: Prism::node + # + # source://prism//lib/prism/node.rb#12898 + sig { returns(Prism::Node) } + def pattern; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12931 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#12895 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#12941 + def type; end + end +end + +# Represents the use of the `=>` operator. +# +# foo => bar +# ^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#12959 +class Prism::MatchRequiredNode < ::Prism::Node + # def initialize: (Prism::node value, Prism::node pattern, Location operator_loc, Location location) -> void + # + # @return [MatchRequiredNode] a new instance of MatchRequiredNode + # + # source://prism//lib/prism/node.rb#12961 + sig do + params( + source: Prism::Source, + value: Prism::Node, + pattern: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, value, pattern, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13055 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#12970 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12975 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#12985 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#12980 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?value: Prism::node, ?pattern: Prism::node, ?operator_loc: Location, ?location: Location) -> MatchRequiredNode + # + # source://prism//lib/prism/node.rb#12990 + sig do + params( + value: Prism::Node, + pattern: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::MatchRequiredNode) + end + def copy(value: T.unsafe(nil), pattern: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#12975 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, pattern: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#12998 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13021 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#13016 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#13009 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader pattern: Prism::node + # + # source://prism//lib/prism/node.rb#13006 + sig { returns(Prism::Node) } + def pattern; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13039 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#13003 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13049 + def type; end + end +end + +# Represents writing local variables using a regular expression match with named capture groups. +# +# /(?bar)/ =~ baz +# ^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#13067 +class Prism::MatchWriteNode < ::Prism::Node + # def initialize: (CallNode call, Array[LocalVariableTargetNode] targets, Location location) -> void + # + # @return [MatchWriteNode] a new instance of MatchWriteNode + # + # source://prism//lib/prism/node.rb#13069 + sig do + params( + source: Prism::Source, + call: Prism::CallNode, + targets: T::Array[Prism::LocalVariableTargetNode], + location: Prism::Location + ).void + end + def initialize(source, call, targets, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13150 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13077 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader call: CallNode + # + # source://prism//lib/prism/node.rb#13110 + sig { returns(Prism::CallNode) } + def call; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13082 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13092 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13087 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?call: CallNode, ?targets: Array[LocalVariableTargetNode], ?location: Location) -> MatchWriteNode + # + # source://prism//lib/prism/node.rb#13097 + sig do + params( + call: Prism::CallNode, + targets: T::Array[Prism::LocalVariableTargetNode], + location: Prism::Location + ).returns(Prism::MatchWriteNode) + end + def copy(call: T.unsafe(nil), targets: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13082 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { call: CallNode, targets: Array[LocalVariableTargetNode], location: Location } + # + # source://prism//lib/prism/node.rb#13105 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13116 + sig { override.returns(String) } + def inspect; end + + # attr_reader targets: Array[LocalVariableTargetNode] + # + # source://prism//lib/prism/node.rb#13113 + sig { returns(T::Array[Prism::LocalVariableTargetNode]) } + def targets; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13134 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13144 + def type; end + end +end + +# Represents a node that is missing from the source and results in a syntax error. +# +# source://prism//lib/prism/node.rb#13159 +class Prism::MissingNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [MissingNode] a new instance of MissingNode + # + # source://prism//lib/prism/node.rb#13161 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13234 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13167 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13172 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13182 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13177 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> MissingNode + # + # source://prism//lib/prism/node.rb#13187 + sig { params(location: Prism::Location).returns(Prism::MissingNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13172 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#13195 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13200 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13218 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13228 + def type; end + end +end + +# Represents a module declaration involving the `module` keyword. +# +# module Foo end +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#13243 +class Prism::ModuleNode < ::Prism::Node + # def initialize: (Array[Symbol] locals, Location module_keyword_loc, Prism::node constant_path, Prism::node? body, Location end_keyword_loc, Symbol name, Location location) -> void + # + # @return [ModuleNode] a new instance of ModuleNode + # + # source://prism//lib/prism/node.rb#13245 + sig do + params( + source: Prism::Source, + locals: T::Array[Symbol], + module_keyword_loc: Prism::Location, + constant_path: Prism::Node, + body: T.nilable(Prism::Node), + end_keyword_loc: Prism::Location, + name: Symbol, + location: Prism::Location + ).void + end + def initialize(source, locals, module_keyword_loc, constant_path, body, end_keyword_loc, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13363 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13257 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Prism::node? + # + # source://prism//lib/prism/node.rb#13306 + sig { returns(T.nilable(Prism::Node)) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13262 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13275 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13267 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader constant_path: Prism::node + # + # source://prism//lib/prism/node.rb#13303 + sig { returns(Prism::Node) } + def constant_path; end + + # def copy: (?locals: Array[Symbol], ?module_keyword_loc: Location, ?constant_path: Prism::node, ?body: Prism::node?, ?end_keyword_loc: Location, ?name: Symbol, ?location: Location) -> ModuleNode + # + # source://prism//lib/prism/node.rb#13280 + sig do + params( + locals: T::Array[Symbol], + module_keyword_loc: Prism::Location, + constant_path: Prism::Node, + body: T.nilable(Prism::Node), + end_keyword_loc: Prism::Location, + name: Symbol, + location: Prism::Location + ).returns(Prism::ModuleNode) + end + def copy(locals: T.unsafe(nil), module_keyword_loc: T.unsafe(nil), constant_path: T.unsafe(nil), body: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13262 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], module_keyword_loc: Location, constant_path: Prism::node, body: Prism::node?, end_keyword_loc: Location, name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#13288 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String + # + # source://prism//lib/prism/node.rb#13324 + sig { returns(String) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#13309 + sig { returns(Prism::Location) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13329 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[Symbol] + # + # source://prism//lib/prism/node.rb#13293 + sig { returns(T::Array[Symbol]) } + def locals; end + + # def module_keyword: () -> String + # + # source://prism//lib/prism/node.rb#13319 + sig { returns(String) } + def module_keyword; end + + # attr_reader module_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#13296 + sig { returns(Prism::Location) } + def module_keyword_loc; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#13316 + sig { returns(Symbol) } + def name; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13347 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13357 + def type; end + end +end + +# Represents a multi-target expression. +# +# a, (b, c) = 1, 2, 3 +# ^^^^^^ +# +# source://prism//lib/prism/node.rb#13379 +class Prism::MultiTargetNode < ::Prism::Node + # def initialize: (Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode] lefts, Prism::node? rest, Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode] rights, Location? lparen_loc, Location? rparen_loc, Location location) -> void + # + # @return [MultiTargetNode] a new instance of MultiTargetNode + # + # source://prism//lib/prism/node.rb#13381 + sig do + params( + source: Prism::Source, + lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode, Prism::NumberedReferenceReadNode)], + rest: T.nilable(Prism::Node), + rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode)], + lparen_loc: T.nilable(Prism::Location), + rparen_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, lefts, rest, rights, lparen_loc, rparen_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13508 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13392 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13397 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13411 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13402 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode], ?rest: Prism::node?, ?rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode], ?lparen_loc: Location?, ?rparen_loc: Location?, ?location: Location) -> MultiTargetNode + # + # source://prism//lib/prism/node.rb#13416 + sig do + params( + lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode, Prism::NumberedReferenceReadNode)], + rest: T.nilable(Prism::Node), + rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode)], + lparen_loc: T.nilable(Prism::Location), + rparen_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::MultiTargetNode) + end + def copy(lefts: T.unsafe(nil), rest: T.unsafe(nil), rights: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13397 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode], rest: Prism::node?, rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode], lparen_loc: Location?, rparen_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#13424 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13474 + sig { override.returns(String) } + def inspect; end + + # attr_reader lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode] + # + # source://prism//lib/prism/node.rb#13429 + sig do + returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode, Prism::NumberedReferenceReadNode)]) + end + def lefts; end + + # def lparen: () -> String? + # + # source://prism//lib/prism/node.rb#13464 + sig { returns(T.nilable(String)) } + def lparen; end + + # attr_reader lparen_loc: Location? + # + # source://prism//lib/prism/node.rb#13438 + sig { returns(T.nilable(Prism::Location)) } + def lparen_loc; end + + # attr_reader rest: Prism::node? + # + # source://prism//lib/prism/node.rb#13432 + sig { returns(T.nilable(Prism::Node)) } + def rest; end + + # attr_reader rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode] + # + # source://prism//lib/prism/node.rb#13435 + sig do + returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode)]) + end + def rights; end + + # def rparen: () -> String? + # + # source://prism//lib/prism/node.rb#13469 + sig { returns(T.nilable(String)) } + def rparen; end + + # attr_reader rparen_loc: Location? + # + # source://prism//lib/prism/node.rb#13451 + sig { returns(T.nilable(Prism::Location)) } + def rparen_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13492 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13502 + def type; end + end +end + +# Represents a write to a multi-target expression. +# +# a, b, c = 1, 2, 3 +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#13524 +class Prism::MultiWriteNode < ::Prism::Node + # def initialize: (Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode] lefts, Prism::node? rest, Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode] rights, Location? lparen_loc, Location? rparen_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [MultiWriteNode] a new instance of MultiWriteNode + # + # source://prism//lib/prism/node.rb#13526 + sig do + params( + source: Prism::Source, + lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)], + rest: T.nilable(Prism::Node), + rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)], + lparen_loc: T.nilable(Prism::Location), + rparen_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, lefts, rest, rights, lparen_loc, rparen_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13671 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13539 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13544 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13559 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13549 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], ?rest: Prism::node?, ?rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], ?lparen_loc: Location?, ?rparen_loc: Location?, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> MultiWriteNode + # + # source://prism//lib/prism/node.rb#13564 + sig do + params( + lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)], + rest: T.nilable(Prism::Node), + rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)], + lparen_loc: T.nilable(Prism::Location), + rparen_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::MultiWriteNode) + end + def copy(lefts: T.unsafe(nil), rest: T.unsafe(nil), rights: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13544 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], rest: Prism::node?, rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], lparen_loc: Location?, rparen_loc: Location?, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#13572 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13637 + sig { override.returns(String) } + def inspect; end + + # attr_reader lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode] + # + # source://prism//lib/prism/node.rb#13577 + sig do + returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)]) + end + def lefts; end + + # def lparen: () -> String? + # + # source://prism//lib/prism/node.rb#13622 + sig { returns(T.nilable(String)) } + def lparen; end + + # attr_reader lparen_loc: Location? + # + # source://prism//lib/prism/node.rb#13586 + sig { returns(T.nilable(Prism::Location)) } + def lparen_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#13632 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#13612 + sig { returns(Prism::Location) } + def operator_loc; end + + # attr_reader rest: Prism::node? + # + # source://prism//lib/prism/node.rb#13580 + sig { returns(T.nilable(Prism::Node)) } + def rest; end + + # attr_reader rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode] + # + # source://prism//lib/prism/node.rb#13583 + sig do + returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)]) + end + def rights; end + + # def rparen: () -> String? + # + # source://prism//lib/prism/node.rb#13627 + sig { returns(T.nilable(String)) } + def rparen; end + + # attr_reader rparen_loc: Location? + # + # source://prism//lib/prism/node.rb#13599 + sig { returns(T.nilable(Prism::Location)) } + def rparen_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13655 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#13619 + sig { returns(Prism::Node) } + def value; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13665 + def type; end + end +end + +# This visitor walks through the tree and copies each node as it is being +# visited. This is useful for consumers that want to mutate the tree, as you +# can change subtrees in place without effecting the rest of the tree. +# +# source://prism//lib/prism/mutation_compiler.rb#13 +class Prism::MutationCompiler < ::Prism::Compiler + # Copy a AliasGlobalVariableNode node + # + # source://prism//lib/prism/mutation_compiler.rb#15 + def visit_alias_global_variable_node(node); end + + # Copy a AliasMethodNode node + # + # source://prism//lib/prism/mutation_compiler.rb#20 + def visit_alias_method_node(node); end + + # Copy a AlternationPatternNode node + # + # source://prism//lib/prism/mutation_compiler.rb#25 + def visit_alternation_pattern_node(node); end + + # Copy a AndNode node + # + # source://prism//lib/prism/mutation_compiler.rb#30 + def visit_and_node(node); end + + # Copy a ArgumentsNode node + # + # source://prism//lib/prism/mutation_compiler.rb#35 + def visit_arguments_node(node); end + + # Copy a ArrayNode node + # + # source://prism//lib/prism/mutation_compiler.rb#40 + def visit_array_node(node); end + + # Copy a ArrayPatternNode node + # + # source://prism//lib/prism/mutation_compiler.rb#45 + def visit_array_pattern_node(node); end + + # Copy a AssocNode node + # + # source://prism//lib/prism/mutation_compiler.rb#50 + def visit_assoc_node(node); end + + # Copy a AssocSplatNode node + # + # source://prism//lib/prism/mutation_compiler.rb#55 + def visit_assoc_splat_node(node); end + + # Copy a BackReferenceReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#60 + def visit_back_reference_read_node(node); end + + # Copy a BeginNode node + # + # source://prism//lib/prism/mutation_compiler.rb#65 + def visit_begin_node(node); end + + # Copy a BlockArgumentNode node + # + # source://prism//lib/prism/mutation_compiler.rb#70 + def visit_block_argument_node(node); end + + # Copy a BlockLocalVariableNode node + # + # source://prism//lib/prism/mutation_compiler.rb#75 + def visit_block_local_variable_node(node); end + + # Copy a BlockNode node + # + # source://prism//lib/prism/mutation_compiler.rb#80 + def visit_block_node(node); end + + # Copy a BlockParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#85 + def visit_block_parameter_node(node); end + + # Copy a BlockParametersNode node + # + # source://prism//lib/prism/mutation_compiler.rb#90 + def visit_block_parameters_node(node); end + + # Copy a BreakNode node + # + # source://prism//lib/prism/mutation_compiler.rb#95 + def visit_break_node(node); end + + # Copy a CallAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#100 + def visit_call_and_write_node(node); end + + # Copy a CallNode node + # + # source://prism//lib/prism/mutation_compiler.rb#105 + def visit_call_node(node); end + + # Copy a CallOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#110 + def visit_call_operator_write_node(node); end + + # Copy a CallOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#115 + def visit_call_or_write_node(node); end + + # Copy a CallTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#120 + def visit_call_target_node(node); end + + # Copy a CapturePatternNode node + # + # source://prism//lib/prism/mutation_compiler.rb#125 + def visit_capture_pattern_node(node); end + + # Copy a CaseMatchNode node + # + # source://prism//lib/prism/mutation_compiler.rb#130 + def visit_case_match_node(node); end + + # Copy a CaseNode node + # + # source://prism//lib/prism/mutation_compiler.rb#135 + def visit_case_node(node); end + + # Copy a ClassNode node + # + # source://prism//lib/prism/mutation_compiler.rb#140 + def visit_class_node(node); end + + # Copy a ClassVariableAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#145 + def visit_class_variable_and_write_node(node); end + + # Copy a ClassVariableOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#150 + def visit_class_variable_operator_write_node(node); end + + # Copy a ClassVariableOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#155 + def visit_class_variable_or_write_node(node); end + + # Copy a ClassVariableReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#160 + def visit_class_variable_read_node(node); end + + # Copy a ClassVariableTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#165 + def visit_class_variable_target_node(node); end + + # Copy a ClassVariableWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#170 + def visit_class_variable_write_node(node); end + + # Copy a ConstantAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#175 + def visit_constant_and_write_node(node); end + + # Copy a ConstantOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#180 + def visit_constant_operator_write_node(node); end + + # Copy a ConstantOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#185 + def visit_constant_or_write_node(node); end + + # Copy a ConstantPathAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#190 + def visit_constant_path_and_write_node(node); end + + # Copy a ConstantPathNode node + # + # source://prism//lib/prism/mutation_compiler.rb#195 + def visit_constant_path_node(node); end + + # Copy a ConstantPathOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#200 + def visit_constant_path_operator_write_node(node); end + + # Copy a ConstantPathOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#205 + def visit_constant_path_or_write_node(node); end + + # Copy a ConstantPathTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#210 + def visit_constant_path_target_node(node); end + + # Copy a ConstantPathWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#215 + def visit_constant_path_write_node(node); end + + # Copy a ConstantReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#220 + def visit_constant_read_node(node); end + + # Copy a ConstantTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#225 + def visit_constant_target_node(node); end + + # Copy a ConstantWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#230 + def visit_constant_write_node(node); end + + # Copy a DefNode node + # + # source://prism//lib/prism/mutation_compiler.rb#235 + def visit_def_node(node); end + + # Copy a DefinedNode node + # + # source://prism//lib/prism/mutation_compiler.rb#240 + def visit_defined_node(node); end + + # Copy a ElseNode node + # + # source://prism//lib/prism/mutation_compiler.rb#245 + def visit_else_node(node); end + + # Copy a EmbeddedStatementsNode node + # + # source://prism//lib/prism/mutation_compiler.rb#250 + def visit_embedded_statements_node(node); end + + # Copy a EmbeddedVariableNode node + # + # source://prism//lib/prism/mutation_compiler.rb#255 + def visit_embedded_variable_node(node); end + + # Copy a EnsureNode node + # + # source://prism//lib/prism/mutation_compiler.rb#260 + def visit_ensure_node(node); end + + # Copy a FalseNode node + # + # source://prism//lib/prism/mutation_compiler.rb#265 + def visit_false_node(node); end + + # Copy a FindPatternNode node + # + # source://prism//lib/prism/mutation_compiler.rb#270 + def visit_find_pattern_node(node); end + + # Copy a FlipFlopNode node + # + # source://prism//lib/prism/mutation_compiler.rb#275 + def visit_flip_flop_node(node); end + + # Copy a FloatNode node + # + # source://prism//lib/prism/mutation_compiler.rb#280 + def visit_float_node(node); end + + # Copy a ForNode node + # + # source://prism//lib/prism/mutation_compiler.rb#285 + def visit_for_node(node); end + + # Copy a ForwardingArgumentsNode node + # + # source://prism//lib/prism/mutation_compiler.rb#290 + def visit_forwarding_arguments_node(node); end + + # Copy a ForwardingParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#295 + def visit_forwarding_parameter_node(node); end + + # Copy a ForwardingSuperNode node + # + # source://prism//lib/prism/mutation_compiler.rb#300 + def visit_forwarding_super_node(node); end + + # Copy a GlobalVariableAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#305 + def visit_global_variable_and_write_node(node); end + + # Copy a GlobalVariableOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#310 + def visit_global_variable_operator_write_node(node); end + + # Copy a GlobalVariableOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#315 + def visit_global_variable_or_write_node(node); end + + # Copy a GlobalVariableReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#320 + def visit_global_variable_read_node(node); end + + # Copy a GlobalVariableTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#325 + def visit_global_variable_target_node(node); end + + # Copy a GlobalVariableWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#330 + def visit_global_variable_write_node(node); end + + # Copy a HashNode node + # + # source://prism//lib/prism/mutation_compiler.rb#335 + def visit_hash_node(node); end + + # Copy a HashPatternNode node + # + # source://prism//lib/prism/mutation_compiler.rb#340 + def visit_hash_pattern_node(node); end + + # Copy a IfNode node + # + # source://prism//lib/prism/mutation_compiler.rb#345 + def visit_if_node(node); end + + # Copy a ImaginaryNode node + # + # source://prism//lib/prism/mutation_compiler.rb#350 + def visit_imaginary_node(node); end + + # Copy a ImplicitNode node + # + # source://prism//lib/prism/mutation_compiler.rb#355 + def visit_implicit_node(node); end + + # Copy a ImplicitRestNode node + # + # source://prism//lib/prism/mutation_compiler.rb#360 + def visit_implicit_rest_node(node); end + + # Copy a InNode node + # + # source://prism//lib/prism/mutation_compiler.rb#365 + def visit_in_node(node); end + + # Copy a IndexAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#370 + def visit_index_and_write_node(node); end + + # Copy a IndexOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#375 + def visit_index_operator_write_node(node); end + + # Copy a IndexOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#380 + def visit_index_or_write_node(node); end + + # Copy a IndexTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#385 + def visit_index_target_node(node); end + + # Copy a InstanceVariableAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#390 + def visit_instance_variable_and_write_node(node); end + + # Copy a InstanceVariableOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#395 + def visit_instance_variable_operator_write_node(node); end + + # Copy a InstanceVariableOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#400 + def visit_instance_variable_or_write_node(node); end + + # Copy a InstanceVariableReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#405 + def visit_instance_variable_read_node(node); end + + # Copy a InstanceVariableTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#410 + def visit_instance_variable_target_node(node); end + + # Copy a InstanceVariableWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#415 + def visit_instance_variable_write_node(node); end + + # Copy a IntegerNode node + # + # source://prism//lib/prism/mutation_compiler.rb#420 + def visit_integer_node(node); end + + # Copy a InterpolatedMatchLastLineNode node + # + # source://prism//lib/prism/mutation_compiler.rb#425 + def visit_interpolated_match_last_line_node(node); end + + # Copy a InterpolatedRegularExpressionNode node + # + # source://prism//lib/prism/mutation_compiler.rb#430 + def visit_interpolated_regular_expression_node(node); end + + # Copy a InterpolatedStringNode node + # + # source://prism//lib/prism/mutation_compiler.rb#435 + def visit_interpolated_string_node(node); end + + # Copy a InterpolatedSymbolNode node + # + # source://prism//lib/prism/mutation_compiler.rb#440 + def visit_interpolated_symbol_node(node); end + + # Copy a InterpolatedXStringNode node + # + # source://prism//lib/prism/mutation_compiler.rb#445 + def visit_interpolated_x_string_node(node); end + + # Copy a ItLocalVariableReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#450 + def visit_it_local_variable_read_node(node); end + + # Copy a ItParametersNode node + # + # source://prism//lib/prism/mutation_compiler.rb#455 + def visit_it_parameters_node(node); end + + # Copy a KeywordHashNode node + # + # source://prism//lib/prism/mutation_compiler.rb#460 + def visit_keyword_hash_node(node); end + + # Copy a KeywordRestParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#465 + def visit_keyword_rest_parameter_node(node); end + + # Copy a LambdaNode node + # + # source://prism//lib/prism/mutation_compiler.rb#470 + def visit_lambda_node(node); end + + # Copy a LocalVariableAndWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#475 + def visit_local_variable_and_write_node(node); end + + # Copy a LocalVariableOperatorWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#480 + def visit_local_variable_operator_write_node(node); end + + # Copy a LocalVariableOrWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#485 + def visit_local_variable_or_write_node(node); end + + # Copy a LocalVariableReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#490 + def visit_local_variable_read_node(node); end + + # Copy a LocalVariableTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#495 + def visit_local_variable_target_node(node); end + + # Copy a LocalVariableWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#500 + def visit_local_variable_write_node(node); end + + # Copy a MatchLastLineNode node + # + # source://prism//lib/prism/mutation_compiler.rb#505 + def visit_match_last_line_node(node); end + + # Copy a MatchPredicateNode node + # + # source://prism//lib/prism/mutation_compiler.rb#510 + def visit_match_predicate_node(node); end + + # Copy a MatchRequiredNode node + # + # source://prism//lib/prism/mutation_compiler.rb#515 + def visit_match_required_node(node); end + + # Copy a MatchWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#520 + def visit_match_write_node(node); end + + # Copy a MissingNode node + # + # source://prism//lib/prism/mutation_compiler.rb#525 + def visit_missing_node(node); end + + # Copy a ModuleNode node + # + # source://prism//lib/prism/mutation_compiler.rb#530 + def visit_module_node(node); end + + # Copy a MultiTargetNode node + # + # source://prism//lib/prism/mutation_compiler.rb#535 + def visit_multi_target_node(node); end + + # Copy a MultiWriteNode node + # + # source://prism//lib/prism/mutation_compiler.rb#540 + def visit_multi_write_node(node); end + + # Copy a NextNode node + # + # source://prism//lib/prism/mutation_compiler.rb#545 + def visit_next_node(node); end + + # Copy a NilNode node + # + # source://prism//lib/prism/mutation_compiler.rb#550 + def visit_nil_node(node); end + + # Copy a NoKeywordsParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#555 + def visit_no_keywords_parameter_node(node); end + + # Copy a NumberedParametersNode node + # + # source://prism//lib/prism/mutation_compiler.rb#560 + def visit_numbered_parameters_node(node); end + + # Copy a NumberedReferenceReadNode node + # + # source://prism//lib/prism/mutation_compiler.rb#565 + def visit_numbered_reference_read_node(node); end + + # Copy a OptionalKeywordParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#570 + def visit_optional_keyword_parameter_node(node); end + + # Copy a OptionalParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#575 + def visit_optional_parameter_node(node); end + + # Copy a OrNode node + # + # source://prism//lib/prism/mutation_compiler.rb#580 + def visit_or_node(node); end + + # Copy a ParametersNode node + # + # source://prism//lib/prism/mutation_compiler.rb#585 + def visit_parameters_node(node); end + + # Copy a ParenthesesNode node + # + # source://prism//lib/prism/mutation_compiler.rb#590 + def visit_parentheses_node(node); end + + # Copy a PinnedExpressionNode node + # + # source://prism//lib/prism/mutation_compiler.rb#595 + def visit_pinned_expression_node(node); end + + # Copy a PinnedVariableNode node + # + # source://prism//lib/prism/mutation_compiler.rb#600 + def visit_pinned_variable_node(node); end + + # Copy a PostExecutionNode node + # + # source://prism//lib/prism/mutation_compiler.rb#605 + def visit_post_execution_node(node); end + + # Copy a PreExecutionNode node + # + # source://prism//lib/prism/mutation_compiler.rb#610 + def visit_pre_execution_node(node); end + + # Copy a ProgramNode node + # + # source://prism//lib/prism/mutation_compiler.rb#615 + def visit_program_node(node); end + + # Copy a RangeNode node + # + # source://prism//lib/prism/mutation_compiler.rb#620 + def visit_range_node(node); end + + # Copy a RationalNode node + # + # source://prism//lib/prism/mutation_compiler.rb#625 + def visit_rational_node(node); end + + # Copy a RedoNode node + # + # source://prism//lib/prism/mutation_compiler.rb#630 + def visit_redo_node(node); end + + # Copy a RegularExpressionNode node + # + # source://prism//lib/prism/mutation_compiler.rb#635 + def visit_regular_expression_node(node); end + + # Copy a RequiredKeywordParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#640 + def visit_required_keyword_parameter_node(node); end + + # Copy a RequiredParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#645 + def visit_required_parameter_node(node); end + + # Copy a RescueModifierNode node + # + # source://prism//lib/prism/mutation_compiler.rb#650 + def visit_rescue_modifier_node(node); end + + # Copy a RescueNode node + # + # source://prism//lib/prism/mutation_compiler.rb#655 + def visit_rescue_node(node); end + + # Copy a RestParameterNode node + # + # source://prism//lib/prism/mutation_compiler.rb#660 + def visit_rest_parameter_node(node); end + + # Copy a RetryNode node + # + # source://prism//lib/prism/mutation_compiler.rb#665 + def visit_retry_node(node); end + + # Copy a ReturnNode node + # + # source://prism//lib/prism/mutation_compiler.rb#670 + def visit_return_node(node); end + + # Copy a SelfNode node + # + # source://prism//lib/prism/mutation_compiler.rb#675 + def visit_self_node(node); end + + # Copy a ShareableConstantNode node + # + # source://prism//lib/prism/mutation_compiler.rb#680 + def visit_shareable_constant_node(node); end + + # Copy a SingletonClassNode node + # + # source://prism//lib/prism/mutation_compiler.rb#685 + def visit_singleton_class_node(node); end + + # Copy a SourceEncodingNode node + # + # source://prism//lib/prism/mutation_compiler.rb#690 + def visit_source_encoding_node(node); end + + # Copy a SourceFileNode node + # + # source://prism//lib/prism/mutation_compiler.rb#695 + def visit_source_file_node(node); end + + # Copy a SourceLineNode node + # + # source://prism//lib/prism/mutation_compiler.rb#700 + def visit_source_line_node(node); end + + # Copy a SplatNode node + # + # source://prism//lib/prism/mutation_compiler.rb#705 + def visit_splat_node(node); end + + # Copy a StatementsNode node + # + # source://prism//lib/prism/mutation_compiler.rb#710 + def visit_statements_node(node); end + + # Copy a StringNode node + # + # source://prism//lib/prism/mutation_compiler.rb#715 + def visit_string_node(node); end + + # Copy a SuperNode node + # + # source://prism//lib/prism/mutation_compiler.rb#720 + def visit_super_node(node); end + + # Copy a SymbolNode node + # + # source://prism//lib/prism/mutation_compiler.rb#725 + def visit_symbol_node(node); end + + # Copy a TrueNode node + # + # source://prism//lib/prism/mutation_compiler.rb#730 + def visit_true_node(node); end + + # Copy a UndefNode node + # + # source://prism//lib/prism/mutation_compiler.rb#735 + def visit_undef_node(node); end + + # Copy a UnlessNode node + # + # source://prism//lib/prism/mutation_compiler.rb#740 + def visit_unless_node(node); end + + # Copy a UntilNode node + # + # source://prism//lib/prism/mutation_compiler.rb#745 + def visit_until_node(node); end + + # Copy a WhenNode node + # + # source://prism//lib/prism/mutation_compiler.rb#750 + def visit_when_node(node); end + + # Copy a WhileNode node + # + # source://prism//lib/prism/mutation_compiler.rb#755 + def visit_while_node(node); end + + # Copy a XStringNode node + # + # source://prism//lib/prism/mutation_compiler.rb#760 + def visit_x_string_node(node); end + + # Copy a YieldNode node + # + # source://prism//lib/prism/mutation_compiler.rb#765 + def visit_yield_node(node); end +end + +# Represents the use of the `next` keyword. +# +# next 1 +# ^^^^^^ +# +# source://prism//lib/prism/node.rb#13689 +class Prism::NextNode < ::Prism::Node + # def initialize: (ArgumentsNode? arguments, Location keyword_loc, Location location) -> void + # + # @return [NextNode] a new instance of NextNode + # + # source://prism//lib/prism/node.rb#13691 + sig do + params( + source: Prism::Source, + arguments: T.nilable(Prism::ArgumentsNode), + keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, arguments, keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13783 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13699 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#13734 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13704 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13716 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13709 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?arguments: ArgumentsNode?, ?keyword_loc: Location, ?location: Location) -> NextNode + # + # source://prism//lib/prism/node.rb#13721 + sig do + params( + arguments: T.nilable(Prism::ArgumentsNode), + keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::NextNode) + end + def copy(arguments: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13704 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { arguments: ArgumentsNode?, keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#13729 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13749 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#13744 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#13737 + sig { returns(Prism::Location) } + def keyword_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13767 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13777 + def type; end + end +end + +# Represents the use of the `nil` keyword. +# +# nil +# ^^^ +# +# source://prism//lib/prism/node.rb#13794 +class Prism::NilNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [NilNode] a new instance of NilNode + # + # source://prism//lib/prism/node.rb#13796 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13869 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13802 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13807 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13817 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13812 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> NilNode + # + # source://prism//lib/prism/node.rb#13822 + sig { params(location: Prism::Location).returns(Prism::NilNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13807 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#13830 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13835 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13853 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13863 + def type; end + end +end + +# Represents the use of `**nil` inside method arguments. +# +# def a(**nil) +# ^^^^^ +# end +# +# source://prism//lib/prism/node.rb#13879 +class Prism::NoKeywordsParameterNode < ::Prism::Node + # def initialize: (Location operator_loc, Location keyword_loc, Location location) -> void + # + # @return [NoKeywordsParameterNode] a new instance of NoKeywordsParameterNode + # + # source://prism//lib/prism/node.rb#13881 + sig do + params( + source: Prism::Source, + operator_loc: Prism::Location, + keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, operator_loc, keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#13980 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#13889 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13894 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#13904 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#13899 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?operator_loc: Location, ?keyword_loc: Location, ?location: Location) -> NoKeywordsParameterNode + # + # source://prism//lib/prism/node.rb#13909 + sig do + params( + operator_loc: Prism::Location, + keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::NoKeywordsParameterNode) + end + def copy(operator_loc: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#13894 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { operator_loc: Location, keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#13917 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#13946 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#13941 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#13929 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#13936 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#13922 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13964 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#13974 + def type; end + end +end + +# This represents a node in the tree. It is the parent class of all of the +# various node types. +# +# source://prism//lib/prism/node.rb#12 +class Prism::Node + abstract! + + # Accepts a visitor and calls back into the specialized visit function. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#131 + sig { abstract.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # Returns an array of child nodes, including `nil`s in the place of optional + # nodes that were not present. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#137 + sig { abstract.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # Returns an array of child nodes and locations that could potentially have + # comments attached to them. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#151 + sig { abstract.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # Returns an array of child nodes, excluding any `nil`s in the place of + # optional nodes that were not present. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#145 + sig { abstract.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # Returns an array of child nodes, including `nil`s in the place of optional + # nodes that were not present. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#137 + sig { abstract.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # source://prism//lib/prism/node_ext.rb#7 + def deprecated(*replacements); end + + # The end offset of the node in the source. This method is effectively a + # delegate method to the location object. + # + # source://prism//lib/prism/node.rb#34 + sig { returns(Integer) } + def end_offset; end + + sig { abstract.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # Returns a string representation of the node. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#162 + sig { abstract.returns(String) } + def inspect; end + + # A Location instance that represents the location of this node in the + # source. + # + # source://prism//lib/prism/node.rb#19 + sig { returns(Prism::Location) } + def location; end + + # source://prism//lib/prism/parse_result/newlines.rb#69 + def newline!(lines); end + + # @return [Boolean] + # + # source://prism//lib/prism/parse_result/newlines.rb#65 + def newline?; end + + # Similar to inspect, but respects the current level of indentation given by + # the pretty print object. + # + # source://prism//lib/prism/node.rb#62 + sig { params(q: T.untyped).void } + def pretty_print(q); end + + # Returns all of the lines of the source code associated with this node. + # An alias for source_lines, used to mimic the API from + # RubyVM::AbstractSyntaxTree to make it easier to migrate. + # + # source://prism//lib/prism/node.rb#40 + sig { returns(T::Array[String]) } + def script_lines; end + + # Slice the location of the node from the source. + # + # source://prism//lib/prism/node.rb#49 + sig { returns(String) } + def slice; end + + # Slice the location of the node from the source, starting at the beginning + # of the line that the location starts on, ending at the end of the line + # that the location ends on. + # + # source://prism//lib/prism/node.rb#56 + sig { returns(String) } + def slice_lines; end + + # Returns all of the lines of the source code associated with this node. + # + # source://prism//lib/prism/node.rb#40 + sig { returns(T::Array[String]) } + def source_lines; end + + # The start offset of the node in the source. This method is effectively a + # delegate method to the location object. + # + # source://prism//lib/prism/node.rb#27 + sig { returns(Integer) } + def start_offset; end + + # Convert this node into a graphviz dot graph string. + # + # source://prism//lib/prism/node.rb#70 + sig { returns(String) } + def to_dot; end + + # Returns a list of nodes that are descendants of this node that contain the + # given line and column. This is useful for locating a node that is selected + # based on the line and column of the source code. + # + # Important to note is that the column given to this method should be in + # bytes, as opposed to characters or code units. + # + # source://prism//lib/prism/node.rb#81 + sig { params(line: Integer, column: Integer).returns(T::Array[Prism::Node]) } + def tunnel(line, column); end + + # Returns a symbol symbolizing the type of node that this represents. This + # is particularly useful for case statements and array comparisons. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#157 + sig { abstract.returns(Symbol) } + def type; end + + private + + # A pointer to the source that this node was created from. + # + # source://prism//lib/prism/node.rb#14 + sig { returns(Prism::Source) } + def source; end + + class << self + # Returns a list of the fields that exist for this node class. Fields + # describe the structure of the node. This kind of reflection is useful for + # things like recursively visiting each node _and_ field in the tree. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#115 + def fields; end + + # Returns the type of the node as a symbol. + # + # @raise [NoMethodError] + # + # source://prism//lib/prism/node.rb#167 + def type; end + end +end + +# Represents an implicit set of parameters through the use of numbered parameters within a block or lambda. +# +# -> { _1 + _2 } +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#13991 +class Prism::NumberedParametersNode < ::Prism::Node + # def initialize: (Integer maximum, Location location) -> void + # + # @return [NumberedParametersNode] a new instance of NumberedParametersNode + # + # source://prism//lib/prism/node.rb#13993 + sig { params(source: Prism::Source, maximum: Integer, location: Prism::Location).void } + def initialize(source, maximum, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14070 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14000 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14005 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14015 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14010 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?maximum: Integer, ?location: Location) -> NumberedParametersNode + # + # source://prism//lib/prism/node.rb#14020 + sig { params(maximum: Integer, location: Prism::Location).returns(Prism::NumberedParametersNode) } + def copy(maximum: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14005 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { maximum: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#14028 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14036 + sig { override.returns(String) } + def inspect; end + + # attr_reader maximum: Integer + # + # source://prism//lib/prism/node.rb#14033 + sig { returns(Integer) } + def maximum; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14054 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14064 + def type; end + end +end + +# Represents reading a numbered reference to a capture in the previous match. +# +# $1 +# ^^ +# +# source://prism//lib/prism/node.rb#14080 +class Prism::NumberedReferenceReadNode < ::Prism::Node + # def initialize: (Integer number, Location location) -> void + # + # @return [NumberedReferenceReadNode] a new instance of NumberedReferenceReadNode + # + # source://prism//lib/prism/node.rb#14082 + sig { params(source: Prism::Source, number: Integer, location: Prism::Location).void } + def initialize(source, number, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14165 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14089 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14094 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14104 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14099 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?number: Integer, ?location: Location) -> NumberedReferenceReadNode + # + # source://prism//lib/prism/node.rb#14109 + sig { params(number: Integer, location: Prism::Location).returns(Prism::NumberedReferenceReadNode) } + def copy(number: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14094 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { number: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#14117 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14131 + sig { override.returns(String) } + def inspect; end + + # The (1-indexed, from the left) number of the capture group. Numbered references that are too large result in this value being `0`. + # + # $1 # number `1` + # + # $5432 # number `5432` + # + # $4294967296 # number `0` + # + # source://prism//lib/prism/node.rb#14128 + sig { returns(Integer) } + def number; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14149 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14159 + def type; end + end +end + +# Represents an optional keyword parameter to a method, block, or lambda definition. +# +# def a(b: 1) +# ^^^^ +# end +# +# source://prism//lib/prism/node.rb#14176 +class Prism::OptionalKeywordParameterNode < ::Prism::Node + # def initialize: (Integer flags, Symbol name, Location name_loc, Prism::node value, Location location) -> void + # + # @return [OptionalKeywordParameterNode] a new instance of OptionalKeywordParameterNode + # + # source://prism//lib/prism/node.rb#14178 + sig do + params( + source: Prism::Source, + flags: Integer, + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, name, name_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14277 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14188 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14193 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14203 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14198 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?location: Location) -> OptionalKeywordParameterNode + # + # source://prism//lib/prism/node.rb#14208 + sig do + params( + flags: Integer, + name: Symbol, + name_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::OptionalKeywordParameterNode) + end + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14193 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, name_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#14216 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14243 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#14225 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#14228 + sig { returns(Prism::Location) } + def name_loc; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#14238 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14261 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#14235 + sig { returns(Prism::Node) } + def value; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#14221 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14271 + def type; end + end +end + +# Represents an optional parameter to a method, block, or lambda definition. +# +# def a(b = 1) +# ^^^^^ +# end +# +# source://prism//lib/prism/node.rb#14291 +class Prism::OptionalParameterNode < ::Prism::Node + # def initialize: (Integer flags, Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void + # + # @return [OptionalParameterNode] a new instance of OptionalParameterNode + # + # source://prism//lib/prism/node.rb#14293 + sig do + params( + source: Prism::Source, + flags: Integer, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, flags, name, name_loc, operator_loc, value, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14405 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14304 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14309 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14319 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14314 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> OptionalParameterNode + # + # source://prism//lib/prism/node.rb#14324 + sig do + params( + flags: Integer, + name: Symbol, + name_loc: Prism::Location, + operator_loc: Prism::Location, + value: Prism::Node, + location: Prism::Location + ).returns(Prism::OptionalParameterNode) + end + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14309 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#14332 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14371 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#14341 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#14344 + sig { returns(Prism::Location) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#14366 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#14351 + sig { returns(Prism::Location) } + def operator_loc; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#14361 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14389 + sig { override.returns(Symbol) } + def type; end + + # attr_reader value: Prism::node + # + # source://prism//lib/prism/node.rb#14358 + sig { returns(Prism::Node) } + def value; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#14337 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14399 + def type; end + end +end + +# Represents the use of the `||` operator or the `or` keyword. +# +# left or right +# ^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#14419 +class Prism::OrNode < ::Prism::Node + # def initialize: (Prism::node left, Prism::node right, Location operator_loc, Location location) -> void + # + # @return [OrNode] a new instance of OrNode + # + # source://prism//lib/prism/node.rb#14421 + sig do + params( + source: Prism::Source, + left: Prism::Node, + right: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, left, right, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14530 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14430 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14435 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14445 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14440 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?left: Prism::node, ?right: Prism::node, ?operator_loc: Location, ?location: Location) -> OrNode + # + # source://prism//lib/prism/node.rb#14450 + sig do + params( + left: Prism::Node, + right: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::OrNode) + end + def copy(left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14435 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { left: Prism::node, right: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#14458 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14496 + sig { override.returns(String) } + def inspect; end + + # Represents the left side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # left or right + # ^^^^ + # + # 1 || 2 + # ^ + # + # source://prism//lib/prism/node.rb#14469 + sig { returns(Prism::Node) } + def left; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#14491 + sig { returns(String) } + def operator; end + + # The location of the `or` keyword or the `||` operator. + # + # left or right + # ^^ + # + # source://prism//lib/prism/node.rb#14484 + sig { returns(Prism::Location) } + def operator_loc; end + + # Represents the right side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # left || right + # ^^^^^ + # + # 1 or 2 + # ^ + # + # source://prism//lib/prism/node.rb#14478 + sig { returns(Prism::Node) } + def right; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14514 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14524 + def type; end + end +end + +# A parser for the pack template language. +# +# source://prism//lib/prism/pack.rb#6 +module Prism::Pack + class << self + def parse(_arg0, _arg1, _arg2); end + end +end + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::AGNOSTIC_ENDIAN = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::BACK = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::BER = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::BIG_ENDIAN = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::COMMENT = T.let(T.unsafe(nil), Symbol) + +# A directive in the pack template language. +# +# source://prism//lib/prism/pack.rb#60 +class Prism::Pack::Directive + # Initialize a new directive with the given values. + # + # @return [Directive] a new instance of Directive + # + # source://prism//lib/prism/pack.rb#89 + def initialize(version, variant, source, type, signed, endian, size, length_type, length); end + + # Provide a human-readable description of the directive. + # + # source://prism//lib/prism/pack.rb#131 + def describe; end + + # The type of endianness of the directive. + # + # source://prism//lib/prism/pack.rb#77 + def endian; end + + # The length of this directive (used for integers). + # + # source://prism//lib/prism/pack.rb#86 + def length; end + + # The length type of this directive (used for integers). + # + # source://prism//lib/prism/pack.rb#83 + def length_type; end + + # The type of signedness of the directive. + # + # source://prism//lib/prism/pack.rb#74 + def signed; end + + # The size of the directive. + # + # source://prism//lib/prism/pack.rb#80 + def size; end + + # A byteslice of the source string that this directive represents. + # + # source://prism//lib/prism/pack.rb#68 + def source; end + + # The type of the directive. + # + # source://prism//lib/prism/pack.rb#71 + def type; end + + # A symbol representing whether or not we are packing or unpacking. + # + # source://prism//lib/prism/pack.rb#65 + def variant; end + + # A symbol representing the version of Ruby. + # + # source://prism//lib/prism/pack.rb#62 + def version; end +end + +# The descriptions of the various types of endianness. +# +# source://prism//lib/prism/pack.rb#102 +Prism::Pack::Directive::ENDIAN_DESCRIPTIONS = T.let(T.unsafe(nil), Hash) + +# The descriptions of the various types of signedness. +# +# source://prism//lib/prism/pack.rb#111 +Prism::Pack::Directive::SIGNED_DESCRIPTIONS = T.let(T.unsafe(nil), Hash) + +# The descriptions of the various types of sizes. +# +# source://prism//lib/prism/pack.rb#118 +Prism::Pack::Directive::SIZE_DESCRIPTIONS = T.let(T.unsafe(nil), Hash) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::ENDIAN_NA = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::FLOAT = T.let(T.unsafe(nil), Symbol) + +# The result of parsing a pack template. +# +# source://prism//lib/prism/pack.rb#198 +class Prism::Pack::Format + # Create a new Format with the given directives and encoding. + # + # @return [Format] a new instance of Format + # + # source://prism//lib/prism/pack.rb#206 + def initialize(directives, encoding); end + + # Provide a human-readable description of the format. + # + # source://prism//lib/prism/pack.rb#212 + def describe; end + + # A list of the directives in the template. + # + # source://prism//lib/prism/pack.rb#200 + def directives; end + + # The encoding of the template. + # + # source://prism//lib/prism/pack.rb#203 + def encoding; end +end + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::INTEGER = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::LENGTH_FIXED = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::LENGTH_MAX = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::LENGTH_NA = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::LENGTH_RELATIVE = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::LITTLE_ENDIAN = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::MOVE = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::NATIVE_ENDIAN = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::NULL = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIGNED = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIGNED_NA = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_16 = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_32 = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_64 = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_8 = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_INT = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_LONG = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_LONG_LONG = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_NA = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_P = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SIZE_SHORT = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::SPACE = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_BASE64 = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_FIXED = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_HEX_HIGH = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_HEX_LOW = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_LSB = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_MIME = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_MSB = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_NULL_PADDED = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_NULL_TERMINATED = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_POINTER = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_SPACE_PADDED = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::STRING_UU = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::UNSIGNED = T.let(T.unsafe(nil), Symbol) + +# source://prism//lib/prism/pack.rb#56 +Prism::Pack::UTF8 = T.let(T.unsafe(nil), Symbol) + +# Flags for parameter nodes. +# +# source://prism//lib/prism/node.rb#19202 +module Prism::ParameterFlags; end + +# a parameter name that has been repeated in the method signature +# +# source://prism//lib/prism/node.rb#19204 +Prism::ParameterFlags::REPEATED_PARAMETER = T.let(T.unsafe(nil), Integer) + +# Represents the list of parameters on a method, block, or lambda definition. +# +# def a(b, c, d) +# ^^^^^^^ +# end +# +# source://prism//lib/prism/node.rb#14543 +class Prism::ParametersNode < ::Prism::Node + # def initialize: (Array[RequiredParameterNode | MultiTargetNode] requireds, Array[OptionalParameterNode] optionals, RestParameterNode | ImplicitRestNode | nil rest, Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode] posts, Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode] keywords, KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil keyword_rest, BlockParameterNode? block, Location location) -> void + # + # @return [ParametersNode] a new instance of ParametersNode + # + # source://prism//lib/prism/node.rb#14545 + sig do + params( + source: Prism::Source, + requireds: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode)], + optionals: T::Array[Prism::OptionalParameterNode], + rest: T.nilable(T.any(Prism::RestParameterNode, Prism::ImplicitRestNode)), + posts: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode, Prism::KeywordRestParameterNode, Prism::NoKeywordsParameterNode, Prism::ForwardingParameterNode)], + keywords: T::Array[T.any(Prism::RequiredKeywordParameterNode, Prism::OptionalKeywordParameterNode)], + keyword_rest: T.nilable(T.any(Prism::KeywordRestParameterNode, Prism::ForwardingParameterNode, Prism::NoKeywordsParameterNode)), + block: T.nilable(Prism::BlockParameterNode), + location: Prism::Location + ).void + end + def initialize(source, requireds, optionals, rest, posts, keywords, keyword_rest, block, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14654 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14558 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader block: BlockParameterNode? + # + # source://prism//lib/prism/node.rb#14617 + sig { returns(T.nilable(Prism::BlockParameterNode)) } + def block; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14563 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14581 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14568 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?requireds: Array[RequiredParameterNode | MultiTargetNode], ?optionals: Array[OptionalParameterNode], ?rest: RestParameterNode | ImplicitRestNode | nil, ?posts: Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode], ?keywords: Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode], ?keyword_rest: KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil, ?block: BlockParameterNode?, ?location: Location) -> ParametersNode + # + # source://prism//lib/prism/node.rb#14586 + sig do + params( + requireds: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode)], + optionals: T::Array[Prism::OptionalParameterNode], + rest: T.nilable(T.any(Prism::RestParameterNode, Prism::ImplicitRestNode)), + posts: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode, Prism::KeywordRestParameterNode, Prism::NoKeywordsParameterNode, Prism::ForwardingParameterNode)], + keywords: T::Array[T.any(Prism::RequiredKeywordParameterNode, Prism::OptionalKeywordParameterNode)], + keyword_rest: T.nilable(T.any(Prism::KeywordRestParameterNode, Prism::ForwardingParameterNode, Prism::NoKeywordsParameterNode)), + block: T.nilable(Prism::BlockParameterNode), + location: Prism::Location + ).returns(Prism::ParametersNode) + end + def copy(requireds: T.unsafe(nil), optionals: T.unsafe(nil), rest: T.unsafe(nil), posts: T.unsafe(nil), keywords: T.unsafe(nil), keyword_rest: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14563 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { requireds: Array[RequiredParameterNode | MultiTargetNode], optionals: Array[OptionalParameterNode], rest: RestParameterNode | ImplicitRestNode | nil, posts: Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode], keywords: Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode], keyword_rest: KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil, block: BlockParameterNode?, location: Location } + # + # source://prism//lib/prism/node.rb#14594 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14620 + sig { override.returns(String) } + def inspect; end + + # attr_reader keyword_rest: KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil + # + # source://prism//lib/prism/node.rb#14614 + sig do + returns(T.nilable(T.any(Prism::KeywordRestParameterNode, Prism::ForwardingParameterNode, Prism::NoKeywordsParameterNode))) + end + def keyword_rest; end + + # attr_reader keywords: Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode] + # + # source://prism//lib/prism/node.rb#14611 + sig { returns(T::Array[T.any(Prism::RequiredKeywordParameterNode, Prism::OptionalKeywordParameterNode)]) } + def keywords; end + + # attr_reader optionals: Array[OptionalParameterNode] + # + # source://prism//lib/prism/node.rb#14602 + sig { returns(T::Array[Prism::OptionalParameterNode]) } + def optionals; end + + # attr_reader posts: Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode] + # + # source://prism//lib/prism/node.rb#14608 + sig do + returns(T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode, Prism::KeywordRestParameterNode, Prism::NoKeywordsParameterNode, Prism::ForwardingParameterNode)]) + end + def posts; end + + # attr_reader requireds: Array[RequiredParameterNode | MultiTargetNode] + # + # source://prism//lib/prism/node.rb#14599 + sig { returns(T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode)]) } + def requireds; end + + # attr_reader rest: RestParameterNode | ImplicitRestNode | nil + # + # source://prism//lib/prism/node.rb#14605 + sig { returns(T.nilable(T.any(Prism::RestParameterNode, Prism::ImplicitRestNode))) } + def rest; end + + # Mirrors the Method#parameters method. + # + # source://prism//lib/prism/node_ext.rb#253 + sig { returns(T::Array[T.any([Symbol, Symbol], [Symbol])]) } + def signature; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14638 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14648 + def type; end + end +end + +# Represents a parenthesized expression +# +# (10 + 34) +# ^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#14674 +class Prism::ParenthesesNode < ::Prism::Node + # def initialize: (Prism::node? body, Location opening_loc, Location closing_loc, Location location) -> void + # + # @return [ParenthesesNode] a new instance of ParenthesesNode + # + # source://prism//lib/prism/node.rb#14676 + sig do + params( + source: Prism::Source, + body: T.nilable(Prism::Node), + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, body, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14781 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14685 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Prism::node? + # + # source://prism//lib/prism/node.rb#14720 + sig { returns(T.nilable(Prism::Node)) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14690 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#14742 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#14730 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14702 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14695 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?body: Prism::node?, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> ParenthesesNode + # + # source://prism//lib/prism/node.rb#14707 + sig do + params( + body: T.nilable(Prism::Node), + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::ParenthesesNode) + end + def copy(body: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14690 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { body: Prism::node?, opening_loc: Location, closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#14715 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14747 + sig { override.returns(String) } + def inspect; end + + # source://prism//lib/prism/parse_result/newlines.rb#85 + def newline!(lines); end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#14737 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#14723 + sig { returns(Prism::Location) } + def opening_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14765 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14775 + def type; end + end +end + +# This represents an error that was encountered during parsing. +# +# source://prism//lib/prism/parse_result.rb#451 +class Prism::ParseError + # Create a new error object with the given message and location. + # + # @return [ParseError] a new instance of ParseError + # + # source://prism//lib/prism/parse_result.rb#466 + sig { params(type: Symbol, message: String, location: Prism::Location, level: Symbol).void } + def initialize(type, message, location, level); end + + # Implement the hash pattern matching interface for ParseError. + # + # source://prism//lib/prism/parse_result.rb#474 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # Returns a string representation of this error. + # + # source://prism//lib/prism/parse_result.rb#479 + sig { returns(String) } + def inspect; end + + # The level of this error. + # + # source://prism//lib/prism/parse_result.rb#463 + sig { returns(Symbol) } + def level; end + + # A Location object representing the location of this error in the source. + # + # source://prism//lib/prism/parse_result.rb#460 + sig { returns(Prism::Location) } + def location; end + + # The message associated with this error. + # + # source://prism//lib/prism/parse_result.rb#457 + sig { returns(String) } + def message; end + + # The type of error. This is an _internal_ symbol that is used for + # communicating with translation layers. It is not meant to be public API. + # + # source://prism//lib/prism/parse_result.rb#454 + sig { returns(Symbol) } + def type; end +end + +# This is a result specific to the `parse_lex` and `parse_lex_file` methods. +# +# source://prism//lib/prism/parse_result.rb#627 +class Prism::ParseLexResult < ::Prism::Result + # Create a new parse lex result object with the given values. + # + # @return [ParseLexResult] a new instance of ParseLexResult + # + # source://prism//lib/prism/parse_result.rb#633 + sig do + params( + value: [Prism::ProgramNode, T::Array[T.untyped]], + comments: T::Array[Prism::Comment], + magic_comments: T::Array[Prism::MagicComment], + data_loc: T.nilable(Prism::Location), + errors: T::Array[Prism::ParseError], + warnings: T::Array[Prism::ParseWarning], + source: Prism::Source + ).void + end + def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end + + # Implement the hash pattern matching interface for ParseLexResult. + # + # source://prism//lib/prism/parse_result.rb#639 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # A tuple of the syntax tree and the list of tokens that were parsed from + # the source code. + # + # source://prism//lib/prism/parse_result.rb#630 + sig { returns([Prism::ProgramNode, T::Array[T.untyped]]) } + def value; end +end + +# This is a result specific to the `parse` and `parse_file` methods. +# +# source://prism//lib/prism/parse_result.rb#576 +class Prism::ParseResult < ::Prism::Result + # Create a new parse result object with the given values. + # + # @return [ParseResult] a new instance of ParseResult + # + # source://prism//lib/prism/parse_result.rb#587 + sig do + params( + value: Prism::ProgramNode, + comments: T::Array[Prism::Comment], + magic_comments: T::Array[Prism::MagicComment], + data_loc: T.nilable(Prism::Location), + errors: T::Array[Prism::ParseError], + warnings: T::Array[Prism::ParseWarning], + source: Prism::Source + ).void + end + def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end + + # Attach the list of comments to their respective locations in the tree. + # + # source://prism//lib/prism/parse_result.rb#598 + def attach_comments!; end + + # Implement the hash pattern matching interface for ParseResult. + # + # source://prism//lib/prism/parse_result.rb#593 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # Walk the tree and mark nodes that are on a new line, loosely emulating + # the behavior of CRuby's `:line` tracepoint event. + # + # source://prism//lib/prism/parse_result.rb#604 + def mark_newlines!; end + + # The syntax tree that was parsed from the source code. + # + # source://prism//lib/prism/parse_result.rb#584 + sig { returns(Prism::ProgramNode) } + def value; end +end + +# When we've parsed the source, we have both the syntax tree and the list of +# comments that we found in the source. This class is responsible for +# walking the tree and finding the nearest location to attach each comment. +# +# It does this by first finding the nearest locations to each comment. +# Locations can either come from nodes directly or from location fields on +# nodes. For example, a `ClassNode` has an overall location encompassing the +# entire class, but it also has a location for the `class` keyword. +# +# Once the nearest locations are found, it determines which one to attach +# to. If it's a trailing comment (a comment on the same line as other source +# code), it will favor attaching to the nearest location that occurs before +# the comment. Otherwise it will favor attaching to the nearest location +# that is after the comment. +# +# source://prism//lib/prism/parse_result/comments.rb#19 +class Prism::ParseResult::Comments + # Create a new Comments object that will attach comments to the given + # parse result. + # + # @return [Comments] a new instance of Comments + # + # source://prism//lib/prism/parse_result/comments.rb#86 + def initialize(parse_result); end + + # Attach the comments to their respective locations in the tree by + # mutating the parse result. + # + # source://prism//lib/prism/parse_result/comments.rb#92 + def attach!; end + + # The parse result that we are attaching comments to. + # + # source://prism//lib/prism/parse_result/comments.rb#82 + def parse_result; end + + private + + # Responsible for finding the nearest targets to the given comment within + # the context of the given encapsulating node. + # + # source://prism//lib/prism/parse_result/comments.rb#119 + def nearest_targets(node, comment); end +end + +# A target for attaching comments that is based on a location field on a +# node. For example, the `end` token of a ClassNode. +# +# source://prism//lib/prism/parse_result/comments.rb#53 +class Prism::ParseResult::Comments::LocationTarget + # @return [LocationTarget] a new instance of LocationTarget + # + # source://prism//lib/prism/parse_result/comments.rb#56 + def initialize(location); end + + # @return [Boolean] + # + # source://prism//lib/prism/parse_result/comments.rb#68 + def encloses?(comment); end + + # source://prism//lib/prism/parse_result/comments.rb#64 + def end_offset; end + + # source://prism//lib/prism/parse_result/comments.rb#72 + def leading_comment(comment); end + + # source://prism//lib/prism/parse_result/comments.rb#54 + def location; end + + # source://prism//lib/prism/parse_result/comments.rb#60 + def start_offset; end + + # source://prism//lib/prism/parse_result/comments.rb#76 + def trailing_comment(comment); end +end + +# A target for attaching comments that is based on a specific node's +# location. +# +# source://prism//lib/prism/parse_result/comments.rb#22 +class Prism::ParseResult::Comments::NodeTarget + # @return [NodeTarget] a new instance of NodeTarget + # + # source://prism//lib/prism/parse_result/comments.rb#25 + def initialize(node); end + + # @return [Boolean] + # + # source://prism//lib/prism/parse_result/comments.rb#37 + def encloses?(comment); end + + # source://prism//lib/prism/parse_result/comments.rb#33 + def end_offset; end + + # source://prism//lib/prism/parse_result/comments.rb#42 + def leading_comment(comment); end + + # source://prism//lib/prism/parse_result/comments.rb#23 + def node; end + + # source://prism//lib/prism/parse_result/comments.rb#29 + def start_offset; end + + # source://prism//lib/prism/parse_result/comments.rb#46 + def trailing_comment(comment); end +end + +# The :line tracepoint event gets fired whenever the Ruby VM encounters an +# expression on a new line. The types of expressions that can trigger this +# event are: +# +# * if statements +# * unless statements +# * nodes that are children of statements lists +# +# In order to keep track of the newlines, we have a list of offsets that +# come back from the parser. We assign these offsets to the first nodes that +# we find in the tree that are on those lines. +# +# Note that the logic in this file should be kept in sync with the Java +# MarkNewlinesVisitor, since that visitor is responsible for marking the +# newlines for JRuby/TruffleRuby. +# +# This file is autoloaded only when `mark_newlines!` is called, so the +# re-opening of the various nodes in this file will only be performed in +# that case. We do that to avoid storing the extra `@newline` instance +# variable on every node if we don't need it. +# +# source://prism//lib/prism/parse_result/newlines.rb#25 +class Prism::ParseResult::Newlines < ::Prism::Visitor + # Create a new Newlines visitor with the given newline offsets. + # + # @return [Newlines] a new instance of Newlines + # + # source://prism//lib/prism/parse_result/newlines.rb#27 + def initialize(lines); end + + # Permit block/lambda nodes to mark newlines within themselves. + # + # source://prism//lib/prism/parse_result/newlines.rb#33 + def visit_block_node(node); end + + # Mark if/unless nodes as newlines. + # + # source://prism//lib/prism/parse_result/newlines.rb#47 + def visit_if_node(node); end + + # Permit block/lambda nodes to mark newlines within themselves. + # + # source://prism//lib/prism/parse_result/newlines.rb#33 + def visit_lambda_node(node); end + + # Permit statements lists to mark newlines within themselves. + # + # source://prism//lib/prism/parse_result/newlines.rb#55 + def visit_statements_node(node); end + + # Mark if/unless nodes as newlines. + # + # source://prism//lib/prism/parse_result/newlines.rb#47 + def visit_unless_node(node); end +end + +# This represents a warning that was encountered during parsing. +# +# source://prism//lib/prism/parse_result.rb#485 +class Prism::ParseWarning + # Create a new warning object with the given message and location. + # + # @return [ParseWarning] a new instance of ParseWarning + # + # source://prism//lib/prism/parse_result.rb#500 + sig { params(type: Symbol, message: String, location: Prism::Location, level: Symbol).void } + def initialize(type, message, location, level); end + + # Implement the hash pattern matching interface for ParseWarning. + # + # source://prism//lib/prism/parse_result.rb#508 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # Returns a string representation of this warning. + # + # source://prism//lib/prism/parse_result.rb#513 + sig { returns(String) } + def inspect; end + + # The level of this warning. + # + # source://prism//lib/prism/parse_result.rb#497 + sig { returns(Symbol) } + def level; end + + # A Location object representing the location of this warning in the source. + # + # source://prism//lib/prism/parse_result.rb#494 + sig { returns(Prism::Location) } + def location; end + + # The message associated with this warning. + # + # source://prism//lib/prism/parse_result.rb#491 + sig { returns(String) } + def message; end + + # The type of warning. This is an _internal_ symbol that is used for + # communicating with translation layers. It is not meant to be public API. + # + # source://prism//lib/prism/parse_result.rb#488 + sig { returns(Symbol) } + def type; end +end + +# A pattern is an object that wraps a Ruby pattern matching expression. The +# expression would normally be passed to an `in` clause within a `case` +# expression or a rightward assignment expression. For example, in the +# following snippet: +# +# case node +# in ConstantPathNode[ConstantReadNode[name: :Prism], ConstantReadNode[name: :Pattern]] +# end +# +# the pattern is the ConstantPathNode[...] expression. +# +# The pattern gets compiled into an object that responds to #call by running +# the #compile method. This method itself will run back through Prism to +# parse the expression into a tree, then walk the tree to generate the +# necessary callable objects. For example, if you wanted to compile the +# expression above into a callable, you would: +# +# callable = Prism::Pattern.new("ConstantPathNode[ConstantReadNode[name: :Prism], ConstantReadNode[name: :Pattern]]").compile +# callable.call(node) +# +# The callable object returned by #compile is guaranteed to respond to #call +# with a single argument, which is the node to match against. It also is +# guaranteed to respond to #===, which means it itself can be used in a `case` +# expression, as in: +# +# case node +# when callable +# end +# +# If the query given to the initializer cannot be compiled into a valid +# matcher (either because of a syntax error or because it is using syntax we +# do not yet support) then a Prism::Pattern::CompilationError will be +# raised. +# +# source://prism//lib/prism/pattern.rb#37 +class Prism::Pattern + # Create a new pattern with the given query. The query should be a string + # containing a Ruby pattern matching expression. + # + # @return [Pattern] a new instance of Pattern + # + # source://prism//lib/prism/pattern.rb#63 + def initialize(query); end + + # Compile the query into a callable object that can be used to match against + # nodes. + # + # @raise [CompilationError] + # + # source://prism//lib/prism/pattern.rb#70 + def compile; end + + # The query that this pattern was initialized with. + # + # source://prism//lib/prism/pattern.rb#59 + def query; end + + # Scan the given node and all of its children for nodes that match the + # pattern. If a block is given, it will be called with each node that + # matches the pattern. If no block is given, an enumerator will be returned + # that will yield each node that matches the pattern. + # + # source://prism//lib/prism/pattern.rb#86 + def scan(root); end + + private + + # Shortcut for combining two procs into one that returns true if both return + # true. + # + # source://prism//lib/prism/pattern.rb#102 + def combine_and(left, right); end + + # Shortcut for combining two procs into one that returns true if either + # returns true. + # + # source://prism//lib/prism/pattern.rb#108 + def combine_or(left, right); end + + # in foo | bar + # + # source://prism//lib/prism/pattern.rb#143 + def compile_alternation_pattern_node(node); end + + # in [foo, bar, baz] + # + # source://prism//lib/prism/pattern.rb#118 + def compile_array_pattern_node(node); end + + # Compile a name associated with a constant. + # + # source://prism//lib/prism/pattern.rb#168 + def compile_constant_name(node, name); end + + # in Prism::ConstantReadNode + # + # source://prism//lib/prism/pattern.rb#148 + def compile_constant_path_node(node); end + + # in ConstantReadNode + # in String + # + # source://prism//lib/prism/pattern.rb#163 + def compile_constant_read_node(node); end + + # Raise an error because the given node is not supported. + # + # @raise [CompilationError] + # + # source://prism//lib/prism/pattern.rb#113 + def compile_error(node); end + + # in InstanceVariableReadNode[name: Symbol] + # in { name: Symbol } + # + # source://prism//lib/prism/pattern.rb#184 + def compile_hash_pattern_node(node); end + + # in nil + # + # source://prism//lib/prism/pattern.rb#214 + def compile_nil_node(node); end + + # Compile any kind of node. Dispatch out to the individual compilation + # methods based on the type of node. + # + # source://prism//lib/prism/pattern.rb#243 + def compile_node(node); end + + # in /foo/ + # + # source://prism//lib/prism/pattern.rb#219 + def compile_regular_expression_node(node); end + + # in "" + # in "foo" + # + # source://prism//lib/prism/pattern.rb#227 + def compile_string_node(node); end + + # in :+ + # in :foo + # + # source://prism//lib/prism/pattern.rb#235 + def compile_symbol_node(node); end +end + +# Raised when the query given to a pattern is either invalid Ruby syntax or +# is using syntax that we don't yet support. +# +# source://prism//lib/prism/pattern.rb#40 +class Prism::Pattern::CompilationError < ::StandardError + # Create a new CompilationError with the given representation of the node + # that caused the error. + # + # @return [CompilationError] a new instance of CompilationError + # + # source://prism//lib/prism/pattern.rb#43 + def initialize(repr); end +end + +# Represents the use of the `^` operator for pinning an expression in a pattern matching expression. +# +# foo in ^(bar) +# ^^^^^^ +# +# source://prism//lib/prism/node.rb#14793 +class Prism::PinnedExpressionNode < ::Prism::Node + # def initialize: (Prism::node expression, Location operator_loc, Location lparen_loc, Location rparen_loc, Location location) -> void + # + # @return [PinnedExpressionNode] a new instance of PinnedExpressionNode + # + # source://prism//lib/prism/node.rb#14795 + sig do + params( + source: Prism::Source, + expression: Prism::Node, + operator_loc: Prism::Location, + lparen_loc: Prism::Location, + rparen_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, expression, operator_loc, lparen_loc, rparen_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#14911 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14805 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14810 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14820 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14815 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?expression: Prism::node, ?operator_loc: Location, ?lparen_loc: Location, ?rparen_loc: Location, ?location: Location) -> PinnedExpressionNode + # + # source://prism//lib/prism/node.rb#14825 + sig do + params( + expression: Prism::Node, + operator_loc: Prism::Location, + lparen_loc: Prism::Location, + rparen_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::PinnedExpressionNode) + end + def copy(expression: T.unsafe(nil), operator_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14810 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { expression: Prism::node, operator_loc: Location, lparen_loc: Location, rparen_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#14833 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader expression: Prism::node + # + # source://prism//lib/prism/node.rb#14838 + sig { returns(Prism::Node) } + def expression; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14877 + sig { override.returns(String) } + def inspect; end + + # def lparen: () -> String + # + # source://prism//lib/prism/node.rb#14867 + sig { returns(String) } + def lparen; end + + # attr_reader lparen_loc: Location + # + # source://prism//lib/prism/node.rb#14848 + sig { returns(Prism::Location) } + def lparen_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#14862 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#14841 + sig { returns(Prism::Location) } + def operator_loc; end + + # def rparen: () -> String + # + # source://prism//lib/prism/node.rb#14872 + sig { returns(String) } + def rparen; end + + # attr_reader rparen_loc: Location + # + # source://prism//lib/prism/node.rb#14855 + sig { returns(Prism::Location) } + def rparen_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14895 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#14905 + def type; end + end +end + +# Represents the use of the `^` operator for pinning a variable in a pattern matching expression. +# +# foo in ^bar +# ^^^^ +# +# source://prism//lib/prism/node.rb#14924 +class Prism::PinnedVariableNode < ::Prism::Node + # def initialize: (Prism::node variable, Location operator_loc, Location location) -> void + # + # @return [PinnedVariableNode] a new instance of PinnedVariableNode + # + # source://prism//lib/prism/node.rb#14926 + sig do + params( + source: Prism::Source, + variable: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, variable, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15016 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#14934 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14939 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#14949 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#14944 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?variable: Prism::node, ?operator_loc: Location, ?location: Location) -> PinnedVariableNode + # + # source://prism//lib/prism/node.rb#14954 + sig do + params( + variable: Prism::Node, + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::PinnedVariableNode) + end + def copy(variable: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#14939 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { variable: Prism::node, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#14962 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#14982 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#14977 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#14970 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15000 + sig { override.returns(Symbol) } + def type; end + + # attr_reader variable: Prism::node + # + # source://prism//lib/prism/node.rb#14967 + sig { returns(Prism::Node) } + def variable; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15010 + def type; end + end +end + +# Represents the use of the `END` keyword. +# +# END { foo } +# ^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#15027 +class Prism::PostExecutionNode < ::Prism::Node + # def initialize: (StatementsNode? statements, Location keyword_loc, Location opening_loc, Location closing_loc, Location location) -> void + # + # @return [PostExecutionNode] a new instance of PostExecutionNode + # + # source://prism//lib/prism/node.rb#15029 + sig do + params( + source: Prism::Source, + statements: T.nilable(Prism::StatementsNode), + keyword_loc: Prism::Location, + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, statements, keyword_loc, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15147 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15039 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15044 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#15108 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#15091 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15056 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15049 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?statements: StatementsNode?, ?keyword_loc: Location, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> PostExecutionNode + # + # source://prism//lib/prism/node.rb#15061 + sig do + params( + statements: T.nilable(Prism::StatementsNode), + keyword_loc: Prism::Location, + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::PostExecutionNode) + end + def copy(statements: T.unsafe(nil), keyword_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15044 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { statements: StatementsNode?, keyword_loc: Location, opening_loc: Location, closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#15069 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15113 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#15098 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#15077 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#15103 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#15084 + sig { returns(Prism::Location) } + def opening_loc; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#15074 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15131 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15141 + def type; end + end +end + +# Represents the use of the `BEGIN` keyword. +# +# BEGIN { foo } +# ^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#15160 +class Prism::PreExecutionNode < ::Prism::Node + # def initialize: (StatementsNode? statements, Location keyword_loc, Location opening_loc, Location closing_loc, Location location) -> void + # + # @return [PreExecutionNode] a new instance of PreExecutionNode + # + # source://prism//lib/prism/node.rb#15162 + sig do + params( + source: Prism::Source, + statements: T.nilable(Prism::StatementsNode), + keyword_loc: Prism::Location, + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, statements, keyword_loc, opening_loc, closing_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15280 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15172 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15177 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#15241 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#15224 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15189 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15182 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?statements: StatementsNode?, ?keyword_loc: Location, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> PreExecutionNode + # + # source://prism//lib/prism/node.rb#15194 + sig do + params( + statements: T.nilable(Prism::StatementsNode), + keyword_loc: Prism::Location, + opening_loc: Prism::Location, + closing_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::PreExecutionNode) + end + def copy(statements: T.unsafe(nil), keyword_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15177 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { statements: StatementsNode?, keyword_loc: Location, opening_loc: Location, closing_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#15202 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15246 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#15231 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#15210 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#15236 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#15217 + sig { returns(Prism::Location) } + def opening_loc; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#15207 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15264 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15274 + def type; end + end +end + +# The top level node of any parse tree. +# +# source://prism//lib/prism/node.rb#15290 +class Prism::ProgramNode < ::Prism::Node + # def initialize: (Array[Symbol] locals, StatementsNode statements, Location location) -> void + # + # @return [ProgramNode] a new instance of ProgramNode + # + # source://prism//lib/prism/node.rb#15292 + sig do + params( + source: Prism::Source, + locals: T::Array[Symbol], + statements: Prism::StatementsNode, + location: Prism::Location + ).void + end + def initialize(source, locals, statements, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15373 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15300 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15305 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15315 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15310 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?locals: Array[Symbol], ?statements: StatementsNode, ?location: Location) -> ProgramNode + # + # source://prism//lib/prism/node.rb#15320 + sig do + params( + locals: T::Array[Symbol], + statements: Prism::StatementsNode, + location: Prism::Location + ).returns(Prism::ProgramNode) + end + def copy(locals: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15305 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], statements: StatementsNode, location: Location } + # + # source://prism//lib/prism/node.rb#15328 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15339 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[Symbol] + # + # source://prism//lib/prism/node.rb#15333 + sig { returns(T::Array[Symbol]) } + def locals; end + + # attr_reader statements: StatementsNode + # + # source://prism//lib/prism/node.rb#15336 + sig { returns(Prism::StatementsNode) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15357 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15367 + def type; end + end +end + +# Flags for range and flip-flop nodes. +# +# source://prism//lib/prism/node.rb#19208 +module Prism::RangeFlags; end + +# ... operator +# +# source://prism//lib/prism/node.rb#19210 +Prism::RangeFlags::EXCLUDE_END = T.let(T.unsafe(nil), Integer) + +# Represents the use of the `..` or `...` operators. +# +# 1..2 +# ^^^^ +# +# c if a =~ /left/ ... b =~ /right/ +# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#15388 +class Prism::RangeNode < ::Prism::Node + # def initialize: (Integer flags, Prism::node? left, Prism::node? right, Location operator_loc, Location location) -> void + # + # @return [RangeNode] a new instance of RangeNode + # + # source://prism//lib/prism/node.rb#15390 + sig do + params( + source: Prism::Source, + flags: Integer, + left: T.nilable(Prism::Node), + right: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, left, right, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15510 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15400 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15405 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15418 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15410 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?left: Prism::node?, ?right: Prism::node?, ?operator_loc: Location, ?location: Location) -> RangeNode + # + # source://prism//lib/prism/node.rb#15423 + sig do + params( + flags: Integer, + left: T.nilable(Prism::Node), + right: T.nilable(Prism::Node), + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::RangeNode) + end + def copy(flags: T.unsafe(nil), left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15405 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, left: Prism::node?, right: Prism::node?, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#15431 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def exclude_end?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15466 + sig { returns(T::Boolean) } + def exclude_end?; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15476 + sig { override.returns(String) } + def inspect; end + + # The left-hand side of the range, if present. It can be either `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # 1... + # ^ + # + # hello...goodbye + # ^^^^^ + # + # source://prism//lib/prism/node.rb#15446 + sig { returns(T.nilable(Prism::Node)) } + def left; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#15471 + sig { returns(String) } + def operator; end + + # The location of the `..` or `...` operator. + # + # source://prism//lib/prism/node.rb#15459 + sig { returns(Prism::Location) } + def operator_loc; end + + # The right-hand side of the range, if present. It can be either `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # ..5 + # ^ + # + # 1...foo + # ^^^ + # If neither right-hand or left-hand side was included, this will be a MissingNode. + # + # source://prism//lib/prism/node.rb#15456 + sig { returns(T.nilable(Prism::Node)) } + def right; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15494 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#15436 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15504 + def type; end + end +end + +# Represents a rational number literal. +# +# 1.0r +# ^^^^ +# +# source://prism//lib/prism/node.rb#15523 +class Prism::RationalNode < ::Prism::Node + # def initialize: (Integer flags, Integer numerator, Integer denominator, Location location) -> void + # + # @return [RationalNode] a new instance of RationalNode + # + # source://prism//lib/prism/node.rb#15525 + sig do + params( + source: Prism::Source, + flags: Integer, + numerator: Integer, + denominator: Integer, + location: Prism::Location + ).void + end + def initialize(source, flags, numerator, denominator, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15635 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15534 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def binary?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15581 + sig { returns(T::Boolean) } + def binary?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15539 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15549 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15544 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?numerator: Integer, ?denominator: Integer, ?location: Location) -> RationalNode + # + # source://prism//lib/prism/node.rb#15554 + sig do + params( + flags: Integer, + numerator: Integer, + denominator: Integer, + location: Prism::Location + ).returns(Prism::RationalNode) + end + def copy(flags: T.unsafe(nil), numerator: T.unsafe(nil), denominator: T.unsafe(nil), location: T.unsafe(nil)); end + + # def decimal?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15586 + sig { returns(T::Boolean) } + def decimal?; end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15539 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, numerator: Integer, denominator: Integer, location: Location } + # + # source://prism//lib/prism/node.rb#15562 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # The denominator of the rational number. + # + # 1.5r # denominator 2 + # + # source://prism//lib/prism/node.rb#15578 + sig { returns(Integer) } + def denominator; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def hexadecimal?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15596 + sig { returns(T::Boolean) } + def hexadecimal?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15601 + sig { override.returns(String) } + def inspect; end + + # The numerator of the rational number. + # + # 1.5r # numerator 3 + # + # source://prism//lib/prism/node.rb#15573 + sig { returns(Integer) } + def numerator; end + + # Returns the value of the node as an IntegerNode or a FloatNode. This + # method is deprecated in favor of #value or #numerator/#denominator. + # + # source://prism//lib/prism/node_ext.rb#114 + def numeric; end + + # def octal?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15591 + sig { returns(T::Boolean) } + def octal?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15619 + sig { override.returns(Symbol) } + def type; end + + # Returns the value of the node as a Ruby Rational. + # + # source://prism//lib/prism/node_ext.rb#108 + sig { returns(Rational) } + def value; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#15567 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15629 + def type; end + end +end + +# Represents the use of the `redo` keyword. +# +# redo +# ^^^^ +# +# source://prism//lib/prism/node.rb#15647 +class Prism::RedoNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [RedoNode] a new instance of RedoNode + # + # source://prism//lib/prism/node.rb#15649 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15722 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15655 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15660 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15670 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15665 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> RedoNode + # + # source://prism//lib/prism/node.rb#15675 + sig { params(location: Prism::Location).returns(Prism::RedoNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15660 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#15683 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15688 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15706 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15716 + def type; end + end +end + +# The Reflection module provides the ability to reflect on the structure of +# the syntax tree itself, as opposed to looking at a single syntax tree. This +# is useful in metaprogramming contexts. +# +# source://prism//lib/prism/reflection.rb#13 +module Prism::Reflection + class << self + # Returns the fields for the given node. + # + # source://prism//lib/prism/reflection.rb#104 + sig { params(node: T.class_of(Prism::Node)).returns(T::Array[Prism::Reflection::Field]) } + def fields_for(node); end + end +end + +# A constant field represents a constant value on a node. Effectively, it +# represents an identifier found within the source. It resolves to a symbol +# in Ruby. +# +# source://prism//lib/prism/reflection.rb#45 +class Prism::Reflection::ConstantField < ::Prism::Reflection::Field; end + +# A constant list field represents a list of constant values on a node. It +# resolves to an array of symbols in Ruby. +# +# source://prism//lib/prism/reflection.rb#55 +class Prism::Reflection::ConstantListField < ::Prism::Reflection::Field; end + +# A field represents a single piece of data on a node. It is the base class +# for all other field types. +# +# source://prism//lib/prism/reflection.rb#16 +class Prism::Reflection::Field + # Initializes the field with the given name. + # + # @return [Field] a new instance of Field + # + # source://prism//lib/prism/reflection.rb#21 + sig { params(name: Symbol).void } + def initialize(name); end + + # The name of the field. + # + # source://prism//lib/prism/reflection.rb#18 + sig { returns(Symbol) } + def name; end +end + +# A flags field represents a bitset of flags on a node. It resolves to an +# integer in Ruby. Note that the flags cannot be accessed directly on the +# node because the integer is kept private. Instead, the various flags in +# the bitset should be accessed through their query methods. +# +# source://prism//lib/prism/reflection.rb#92 +class Prism::Reflection::FlagsField < ::Prism::Reflection::Field + # Initializes the flags field with the given name and flags. + # + # @return [FlagsField] a new instance of FlagsField + # + # source://prism//lib/prism/reflection.rb#97 + sig { params(name: Symbol, flags: T::Array[Symbol]).void } + def initialize(name, flags); end + + # The names of the flags in the bitset. + # + # source://prism//lib/prism/reflection.rb#94 + sig { returns(T::Array[Symbol]) } + def flags; end +end + +# A float field represents a double-precision floating point value. It is +# used exclusively to represent the value of a floating point literal. It +# resolves to a Float in Ruby. +# +# source://prism//lib/prism/reflection.rb#85 +class Prism::Reflection::FloatField < ::Prism::Reflection::Field; end + +# An integer field represents an integer value. It is used to represent the +# value of an integer literal, the depth of local variables, and the number +# of a numbered reference. It resolves to an Integer in Ruby. +# +# source://prism//lib/prism/reflection.rb#79 +class Prism::Reflection::IntegerField < ::Prism::Reflection::Field; end + +# A location field represents the location of some part of the node in the +# source code. For example, the location of a keyword or an operator. It +# resolves to a Prism::Location in Ruby. +# +# source://prism//lib/prism/reflection.rb#67 +class Prism::Reflection::LocationField < ::Prism::Reflection::Field; end + +# A node field represents a single child node in the syntax tree. It +# resolves to a Prism::Node in Ruby. +# +# source://prism//lib/prism/reflection.rb#28 +class Prism::Reflection::NodeField < ::Prism::Reflection::Field; end + +# A node list field represents a list of child nodes in the syntax tree. It +# resolves to an array of Prism::Node instances in Ruby. +# +# source://prism//lib/prism/reflection.rb#39 +class Prism::Reflection::NodeListField < ::Prism::Reflection::Field; end + +# An optional constant field represents a constant value on a node that may +# or may not be present. It resolves to either a symbol or nil in Ruby. +# +# source://prism//lib/prism/reflection.rb#50 +class Prism::Reflection::OptionalConstantField < ::Prism::Reflection::Field; end + +# An optional location field represents the location of some part of the +# node in the source code that may or may not be present. It resolves to +# either a Prism::Location or nil in Ruby. +# +# source://prism//lib/prism/reflection.rb#73 +class Prism::Reflection::OptionalLocationField < ::Prism::Reflection::Field; end + +# An optional node field represents a single child node in the syntax tree +# that may or may not be present. It resolves to either a Prism::Node or nil +# in Ruby. +# +# source://prism//lib/prism/reflection.rb#34 +class Prism::Reflection::OptionalNodeField < ::Prism::Reflection::Field; end + +# A string field represents a string value on a node. It almost always +# represents the unescaped value of a string-like literal. It resolves to a +# string in Ruby. +# +# source://prism//lib/prism/reflection.rb#61 +class Prism::Reflection::StringField < ::Prism::Reflection::Field; end + +# Flags for regular expression and match last line nodes. +# +# source://prism//lib/prism/node.rb#19214 +module Prism::RegularExpressionFlags; end + +# n - forces the ASCII-8BIT encoding +# +# source://prism//lib/prism/node.rb#19231 +Prism::RegularExpressionFlags::ASCII_8BIT = T.let(T.unsafe(nil), Integer) + +# e - forces the EUC-JP encoding +# +# source://prism//lib/prism/node.rb#19228 +Prism::RegularExpressionFlags::EUC_JP = T.let(T.unsafe(nil), Integer) + +# x - ignores whitespace and allows comments in regular expressions +# +# source://prism//lib/prism/node.rb#19219 +Prism::RegularExpressionFlags::EXTENDED = T.let(T.unsafe(nil), Integer) + +# internal bytes forced the encoding to binary +# +# source://prism//lib/prism/node.rb#19243 +Prism::RegularExpressionFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer) + +# internal bytes forced the encoding to US-ASCII +# +# source://prism//lib/prism/node.rb#19246 +Prism::RegularExpressionFlags::FORCED_US_ASCII_ENCODING = T.let(T.unsafe(nil), Integer) + +# internal bytes forced the encoding to UTF-8 +# +# source://prism//lib/prism/node.rb#19240 +Prism::RegularExpressionFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer) + +# i - ignores the case of characters when matching +# +# source://prism//lib/prism/node.rb#19216 +Prism::RegularExpressionFlags::IGNORE_CASE = T.let(T.unsafe(nil), Integer) + +# m - allows $ to match the end of lines within strings +# +# source://prism//lib/prism/node.rb#19222 +Prism::RegularExpressionFlags::MULTI_LINE = T.let(T.unsafe(nil), Integer) + +# o - only interpolates values into the regular expression once +# +# source://prism//lib/prism/node.rb#19225 +Prism::RegularExpressionFlags::ONCE = T.let(T.unsafe(nil), Integer) + +# u - forces the UTF-8 encoding +# +# source://prism//lib/prism/node.rb#19237 +Prism::RegularExpressionFlags::UTF_8 = T.let(T.unsafe(nil), Integer) + +# s - forces the Windows-31J encoding +# +# source://prism//lib/prism/node.rb#19234 +Prism::RegularExpressionFlags::WINDOWS_31J = T.let(T.unsafe(nil), Integer) + +# Represents a regular expression literal with no interpolation. +# +# /foo/i +# ^^^^^^ +# +# source://prism//lib/prism/node.rb#15731 +class Prism::RegularExpressionNode < ::Prism::Node + include ::Prism::RegularExpressionOptions + + # def initialize: (Integer flags, Location opening_loc, Location content_loc, Location closing_loc, String unescaped, Location location) -> void + # + # @return [RegularExpressionNode] a new instance of RegularExpressionNode + # + # source://prism//lib/prism/node.rb#15733 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: Prism::Location, + content_loc: Prism::Location, + closing_loc: Prism::Location, + unescaped: String, + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#15909 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15744 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def ascii_8bit?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15830 + sig { returns(T::Boolean) } + def ascii_8bit?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15749 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#15870 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#15795 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15759 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15754 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def content: () -> String + # + # source://prism//lib/prism/node.rb#15865 + sig { returns(String) } + def content; end + + # attr_reader content_loc: Location + # + # source://prism//lib/prism/node.rb#15788 + sig { returns(Prism::Location) } + def content_loc; end + + # def copy: (?flags: Integer, ?opening_loc: Location, ?content_loc: Location, ?closing_loc: Location, ?unescaped: String, ?location: Location) -> RegularExpressionNode + # + # source://prism//lib/prism/node.rb#15764 + sig do + params( + flags: Integer, + opening_loc: Prism::Location, + content_loc: Prism::Location, + closing_loc: Prism::Location, + unescaped: String, + location: Prism::Location + ).returns(Prism::RegularExpressionNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15749 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, content_loc: Location, closing_loc: Location, unescaped: String, location: Location } + # + # source://prism//lib/prism/node.rb#15772 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def euc_jp?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15825 + sig { returns(T::Boolean) } + def euc_jp?; end + + # def extended?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15810 + sig { returns(T::Boolean) } + def extended?; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15850 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_us_ascii_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15855 + sig { returns(T::Boolean) } + def forced_us_ascii_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15845 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + # def ignore_case?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15805 + sig { returns(T::Boolean) } + def ignore_case?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15875 + sig { override.returns(String) } + def inspect; end + + # def multi_line?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15815 + sig { returns(T::Boolean) } + def multi_line?; end + + # def once?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15820 + sig { returns(T::Boolean) } + def once?; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#15860 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#15781 + sig { returns(Prism::Location) } + def opening_loc; end + + sig { returns(Integer) } + def options; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15893 + sig { override.returns(Symbol) } + def type; end + + # attr_reader unescaped: String + # + # source://prism//lib/prism/node.rb#15802 + sig { returns(String) } + def unescaped; end + + # def utf_8?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15840 + sig { returns(T::Boolean) } + def utf_8?; end + + # def windows_31j?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15835 + sig { returns(T::Boolean) } + def windows_31j?; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#15777 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#15903 + def type; end + end +end + +# source://prism//lib/prism/node_ext.rb#20 +module Prism::RegularExpressionOptions + # Returns a numeric value that represents the flags that were used to create + # the regular expression. + # + # source://prism//lib/prism/node_ext.rb#23 + def options; end +end + +# Represents a required keyword parameter to a method, block, or lambda definition. +# +# def a(b: ) +# ^^ +# end +# +# source://prism//lib/prism/node.rb#15924 +class Prism::RequiredKeywordParameterNode < ::Prism::Node + # def initialize: (Integer flags, Symbol name, Location name_loc, Location location) -> void + # + # @return [RequiredKeywordParameterNode] a new instance of RequiredKeywordParameterNode + # + # source://prism//lib/prism/node.rb#15926 + sig do + params( + source: Prism::Source, + flags: Integer, + name: Symbol, + name_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, name, name_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16021 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#15935 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15940 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#15950 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#15945 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol, ?name_loc: Location, ?location: Location) -> RequiredKeywordParameterNode + # + # source://prism//lib/prism/node.rb#15955 + sig do + params( + flags: Integer, + name: Symbol, + name_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::RequiredKeywordParameterNode) + end + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#15940 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, name_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#15963 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#15987 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#15972 + sig { returns(Symbol) } + def name; end + + # attr_reader name_loc: Location + # + # source://prism//lib/prism/node.rb#15975 + sig { returns(Prism::Location) } + def name_loc; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#15982 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16005 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#15968 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16015 + def type; end + end +end + +# Represents a required parameter to a method, block, or lambda definition. +# +# def a(b) +# ^ +# end +# +# source://prism//lib/prism/node.rb#16034 +class Prism::RequiredParameterNode < ::Prism::Node + # def initialize: (Integer flags, Symbol name, Location location) -> void + # + # @return [RequiredParameterNode] a new instance of RequiredParameterNode + # + # source://prism//lib/prism/node.rb#16036 + sig { params(source: Prism::Source, flags: Integer, name: Symbol, location: Prism::Location).void } + def initialize(source, flags, name, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16123 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16044 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16049 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16059 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16054 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol, ?location: Location) -> RequiredParameterNode + # + # source://prism//lib/prism/node.rb#16064 + sig { params(flags: Integer, name: Symbol, location: Prism::Location).returns(Prism::RequiredParameterNode) } + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16049 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, location: Location } + # + # source://prism//lib/prism/node.rb#16072 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16089 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol + # + # source://prism//lib/prism/node.rb#16081 + sig { returns(Symbol) } + def name; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#16084 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16107 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#16077 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16117 + def type; end + end +end + +# Represents an expression modified with a rescue. +# +# foo rescue nil +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#16134 +class Prism::RescueModifierNode < ::Prism::Node + # def initialize: (Prism::node expression, Location keyword_loc, Prism::node rescue_expression, Location location) -> void + # + # @return [RescueModifierNode] a new instance of RescueModifierNode + # + # source://prism//lib/prism/node.rb#16136 + sig do + params( + source: Prism::Source, + expression: Prism::Node, + keyword_loc: Prism::Location, + rescue_expression: Prism::Node, + location: Prism::Location + ).void + end + def initialize(source, expression, keyword_loc, rescue_expression, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16230 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16145 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16150 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16160 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16155 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?expression: Prism::node, ?keyword_loc: Location, ?rescue_expression: Prism::node, ?location: Location) -> RescueModifierNode + # + # source://prism//lib/prism/node.rb#16165 + sig do + params( + expression: Prism::Node, + keyword_loc: Prism::Location, + rescue_expression: Prism::Node, + location: Prism::Location + ).returns(Prism::RescueModifierNode) + end + def copy(expression: T.unsafe(nil), keyword_loc: T.unsafe(nil), rescue_expression: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16150 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { expression: Prism::node, keyword_loc: Location, rescue_expression: Prism::node, location: Location } + # + # source://prism//lib/prism/node.rb#16173 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader expression: Prism::node + # + # source://prism//lib/prism/node.rb#16178 + sig { returns(Prism::Node) } + def expression; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16196 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#16191 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#16181 + sig { returns(Prism::Location) } + def keyword_loc; end + + # source://prism//lib/prism/parse_result/newlines.rb#115 + def newline!(lines); end + + # attr_reader rescue_expression: Prism::node + # + # source://prism//lib/prism/node.rb#16188 + sig { returns(Prism::Node) } + def rescue_expression; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16214 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16224 + def type; end + end +end + +# Represents a rescue statement. +# +# begin +# rescue Foo, *splat, Bar => ex +# foo +# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +# end +# +# `Foo, *splat, Bar` are in the `exceptions` field. `ex` is in the `exception` field. +# +# source://prism//lib/prism/node.rb#16247 +class Prism::RescueNode < ::Prism::Node + # def initialize: (Location keyword_loc, Array[Prism::node] exceptions, Location? operator_loc, Prism::node? reference, StatementsNode? statements, RescueNode? consequent, Location location) -> void + # + # @return [RescueNode] a new instance of RescueNode + # + # source://prism//lib/prism/node.rb#16249 + sig do + params( + source: Prism::Source, + keyword_loc: Prism::Location, + exceptions: T::Array[Prism::Node], + operator_loc: T.nilable(Prism::Location), + reference: T.nilable(Prism::Node), + statements: T.nilable(Prism::StatementsNode), + consequent: T.nilable(Prism::RescueNode), + location: Prism::Location + ).void + end + def initialize(source, keyword_loc, exceptions, operator_loc, reference, statements, consequent, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16375 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16261 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16266 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16281 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16271 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader consequent: RescueNode? + # + # source://prism//lib/prism/node.rb#16328 + sig { returns(T.nilable(Prism::RescueNode)) } + def consequent; end + + # def copy: (?keyword_loc: Location, ?exceptions: Array[Prism::node], ?operator_loc: Location?, ?reference: Prism::node?, ?statements: StatementsNode?, ?consequent: RescueNode?, ?location: Location) -> RescueNode + # + # source://prism//lib/prism/node.rb#16286 + sig do + params( + keyword_loc: Prism::Location, + exceptions: T::Array[Prism::Node], + operator_loc: T.nilable(Prism::Location), + reference: T.nilable(Prism::Node), + statements: T.nilable(Prism::StatementsNode), + consequent: T.nilable(Prism::RescueNode), + location: Prism::Location + ).returns(Prism::RescueNode) + end + def copy(keyword_loc: T.unsafe(nil), exceptions: T.unsafe(nil), operator_loc: T.unsafe(nil), reference: T.unsafe(nil), statements: T.unsafe(nil), consequent: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16266 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, exceptions: Array[Prism::node], operator_loc: Location?, reference: Prism::node?, statements: StatementsNode?, consequent: RescueNode?, location: Location } + # + # source://prism//lib/prism/node.rb#16294 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader exceptions: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#16306 + sig { returns(T::Array[Prism::Node]) } + def exceptions; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16341 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#16331 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#16299 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def operator: () -> String? + # + # source://prism//lib/prism/node.rb#16336 + sig { returns(T.nilable(String)) } + def operator; end + + # attr_reader operator_loc: Location? + # + # source://prism//lib/prism/node.rb#16309 + sig { returns(T.nilable(Prism::Location)) } + def operator_loc; end + + # attr_reader reference: Prism::node? + # + # source://prism//lib/prism/node.rb#16322 + sig { returns(T.nilable(Prism::Node)) } + def reference; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#16325 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16359 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16369 + def type; end + end +end + +# Represents a rest parameter to a method, block, or lambda definition. +# +# def a(*b) +# ^^ +# end +# +# source://prism//lib/prism/node.rb#16392 +class Prism::RestParameterNode < ::Prism::Node + # def initialize: (Integer flags, Symbol? name, Location? name_loc, Location operator_loc, Location location) -> void + # + # @return [RestParameterNode] a new instance of RestParameterNode + # + # source://prism//lib/prism/node.rb#16394 + sig do + params( + source: Prism::Source, + flags: Integer, + name: T.nilable(Symbol), + name_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, flags, name, name_loc, operator_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16508 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16404 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16409 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16419 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16414 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?name: Symbol?, ?name_loc: Location?, ?operator_loc: Location, ?location: Location) -> RestParameterNode + # + # source://prism//lib/prism/node.rb#16424 + sig do + params( + flags: Integer, + name: T.nilable(Symbol), + name_loc: T.nilable(Prism::Location), + operator_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::RestParameterNode) + end + def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16409 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol?, name_loc: Location?, operator_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#16432 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16474 + sig { override.returns(String) } + def inspect; end + + # attr_reader name: Symbol? + # + # source://prism//lib/prism/node.rb#16441 + sig { returns(T.nilable(Symbol)) } + def name; end + + # attr_reader name_loc: Location? + # + # source://prism//lib/prism/node.rb#16444 + sig { returns(T.nilable(Prism::Location)) } + def name_loc; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#16469 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#16457 + sig { returns(Prism::Location) } + def operator_loc; end + + # def repeated_parameter?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#16464 + sig { returns(T::Boolean) } + def repeated_parameter?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16492 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#16437 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16502 + def type; end + end +end + +# This represents the result of a call to ::parse or ::parse_file. It contains +# the requested structure, any comments that were encounters, and any errors +# that were encountered. +# +# source://prism//lib/prism/parse_result.rb#521 +class Prism::Result + # Create a new result object with the given values. + # + # @return [Result] a new instance of Result + # + # source://prism//lib/prism/parse_result.rb#543 + sig do + params( + comments: T::Array[Prism::Comment], + magic_comments: T::Array[Prism::MagicComment], + data_loc: T.nilable(Prism::Location), + errors: T::Array[Prism::ParseError], + warnings: T::Array[Prism::ParseWarning], + source: Prism::Source + ).void + end + def initialize(comments, magic_comments, data_loc, errors, warnings, source); end + + # The list of comments that were encountered during parsing. + # + # source://prism//lib/prism/parse_result.rb#523 + sig { returns(T::Array[Prism::Comment]) } + def comments; end + + # An optional location that represents the location of the __END__ marker + # and the rest of the content of the file. This content is loaded into the + # DATA constant when the file being parsed is the main file being executed. + # + # source://prism//lib/prism/parse_result.rb#531 + sig { returns(T.nilable(Prism::Location)) } + def data_loc; end + + # Implement the hash pattern matching interface for Result. + # + # source://prism//lib/prism/parse_result.rb#553 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # Returns the encoding of the source code that was parsed. + # + # source://prism//lib/prism/parse_result.rb#558 + sig { returns(Encoding) } + def encoding; end + + # The list of errors that were generated during parsing. + # + # source://prism//lib/prism/parse_result.rb#534 + sig { returns(T::Array[Prism::ParseError]) } + def errors; end + + # Returns true if there were errors during parsing and false if there were + # not. + # + # @return [Boolean] + # + # source://prism//lib/prism/parse_result.rb#570 + sig { returns(T::Boolean) } + def failure?; end + + # The list of magic comments that were encountered during parsing. + # + # source://prism//lib/prism/parse_result.rb#526 + sig { returns(T::Array[Prism::MagicComment]) } + def magic_comments; end + + # A Source instance that represents the source code that was parsed. + # + # source://prism//lib/prism/parse_result.rb#540 + sig { returns(Prism::Source) } + def source; end + + # Returns true if there were no errors during parsing and false if there + # were. + # + # @return [Boolean] + # + # source://prism//lib/prism/parse_result.rb#564 + sig { returns(T::Boolean) } + def success?; end + + # The list of warnings that were generated during parsing. + # + # source://prism//lib/prism/parse_result.rb#537 + sig { returns(T::Array[Prism::ParseWarning]) } + def warnings; end +end + +# Represents the use of the `retry` keyword. +# +# retry +# ^^^^^ +# +# source://prism//lib/prism/node.rb#16521 +class Prism::RetryNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [RetryNode] a new instance of RetryNode + # + # source://prism//lib/prism/node.rb#16523 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16596 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16529 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16534 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16544 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16539 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> RetryNode + # + # source://prism//lib/prism/node.rb#16549 + sig { params(location: Prism::Location).returns(Prism::RetryNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16534 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#16557 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16562 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16580 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16590 + def type; end + end +end + +# Represents the use of the `return` keyword. +# +# return 1 +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#16605 +class Prism::ReturnNode < ::Prism::Node + # def initialize: (Integer flags, Location keyword_loc, ArgumentsNode? arguments, Location location) -> void + # + # @return [ReturnNode] a new instance of ReturnNode + # + # source://prism//lib/prism/node.rb#16607 + sig do + params( + source: Prism::Source, + flags: Integer, + keyword_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + location: Prism::Location + ).void + end + def initialize(source, flags, keyword_loc, arguments, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16709 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16616 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#16662 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16621 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16633 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16626 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?keyword_loc: Location, ?arguments: ArgumentsNode?, ?location: Location) -> ReturnNode + # + # source://prism//lib/prism/node.rb#16638 + sig do + params( + flags: Integer, + keyword_loc: Prism::Location, + arguments: T.nilable(Prism::ArgumentsNode), + location: Prism::Location + ).returns(Prism::ReturnNode) + end + def copy(flags: T.unsafe(nil), keyword_loc: T.unsafe(nil), arguments: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16621 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, keyword_loc: Location, arguments: ArgumentsNode?, location: Location } + # + # source://prism//lib/prism/node.rb#16646 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16675 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#16670 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#16655 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def redundant?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#16665 + sig { returns(T::Boolean) } + def redundant?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16693 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#16651 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16703 + def type; end + end +end + +# Flags for return nodes. +# +# source://prism//lib/prism/node.rb#19250 +module Prism::ReturnNodeFlags; end + +# a return statement that is redundant because it is the last statement in a method +# +# source://prism//lib/prism/node.rb#19252 +Prism::ReturnNodeFlags::REDUNDANT = T.let(T.unsafe(nil), Integer) + +# Represents the `self` keyword. +# +# self +# ^^^^ +# +# source://prism//lib/prism/node.rb#16721 +class Prism::SelfNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [SelfNode] a new instance of SelfNode + # + # source://prism//lib/prism/node.rb#16723 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16796 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16729 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16734 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16744 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16739 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> SelfNode + # + # source://prism//lib/prism/node.rb#16749 + sig { params(location: Prism::Location).returns(Prism::SelfNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16734 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#16757 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16762 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16780 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16790 + def type; end + end +end + +# A module responsible for deserializing parse results. +# +# source://prism//lib/prism/serialize.rb#14 +module Prism::Serialize + class << self + # Deserialize the AST represented by the given string into a parse result. + # + # source://prism//lib/prism/serialize.rb#28 + def load(input, serialized); end + + # Deserialize the tokens represented by the given string into a parse + # result. + # + # source://prism//lib/prism/serialize.rb#40 + def load_tokens(source, serialized); end + end +end + +# source://prism//lib/prism/serialize.rb#44 +class Prism::Serialize::Loader + # @return [Loader] a new instance of Loader + # + # source://prism//lib/prism/serialize.rb#80 + def initialize(source, serialized); end + + # Returns the value of attribute constant_pool. + # + # source://prism//lib/prism/serialize.rb#77 + def constant_pool; end + + # Returns the value of attribute constant_pool_offset. + # + # source://prism//lib/prism/serialize.rb#77 + def constant_pool_offset; end + + # Returns the value of attribute encoding. + # + # source://prism//lib/prism/serialize.rb#76 + def encoding; end + + # Returns the value of attribute input. + # + # source://prism//lib/prism/serialize.rb#76 + def input; end + + # Returns the value of attribute io. + # + # source://prism//lib/prism/serialize.rb#76 + def io; end + + # source://prism//lib/prism/serialize.rb#118 + def load_comments; end + + # source://prism//lib/prism/serialize.rb#104 + def load_encoding; end + + # source://prism//lib/prism/serialize.rb#95 + def load_header; end + + # source://prism//lib/prism/serialize.rb#114 + def load_line_offsets; end + + # source://prism//lib/prism/serialize.rb#438 + def load_metadata; end + + # source://prism//lib/prism/serialize.rb#472 + def load_nodes; end + + # source://prism//lib/prism/serialize.rb#486 + def load_result; end + + # source://prism//lib/prism/serialize.rb#110 + def load_start_line; end + + # source://prism//lib/prism/serialize.rb#447 + def load_tokens; end + + # source://prism//lib/prism/serialize.rb#460 + def load_tokens_result; end + + # Returns the value of attribute serialized. + # + # source://prism//lib/prism/serialize.rb#76 + def serialized; end + + # Returns the value of attribute source. + # + # source://prism//lib/prism/serialize.rb#77 + def source; end + + # Returns the value of attribute start_line. + # + # source://prism//lib/prism/serialize.rb#78 + def start_line; end + + private + + # source://prism//lib/prism/serialize.rb#572 + def load_constant(index); end + + # source://prism//lib/prism/serialize.rb#525 + def load_double; end + + # source://prism//lib/prism/serialize.rb#540 + def load_embedded_string; end + + # source://prism//lib/prism/serialize.rb#602 + def load_error_level; end + + # source://prism//lib/prism/serialize.rb#514 + def load_integer; end + + # source://prism//lib/prism/serialize.rb#556 + def load_location; end + + # source://prism//lib/prism/serialize.rb#560 + def load_location_object; end + + # source://prism//lib/prism/serialize.rb#631 + def load_node; end + + # source://prism//lib/prism/serialize.rb#597 + def load_optional_constant; end + + # source://prism//lib/prism/serialize.rb#564 + def load_optional_location; end + + # source://prism//lib/prism/serialize.rb#568 + def load_optional_location_object; end + + # source://prism//lib/prism/serialize.rb#533 + def load_optional_node; end + + # source://prism//lib/prism/serialize.rb#593 + def load_required_constant; end + + # source://prism//lib/prism/serialize.rb#544 + def load_string; end + + # source://prism//lib/prism/serialize.rb#529 + def load_uint32; end + + # source://prism//lib/prism/serialize.rb#509 + def load_varsint; end + + # variable-length integer using https://en.wikipedia.org/wiki/LEB128 + # This is also what protobuf uses: https://protobuf.dev/programming-guides/encoding/#varints + # + # source://prism//lib/prism/serialize.rb#495 + def load_varuint; end + + # source://prism//lib/prism/serialize.rb#617 + def load_warning_level; end +end + +# source://prism//lib/prism/serialize.rb#127 +Prism::Serialize::Loader::DIAGNOSTIC_TYPES = T.let(T.unsafe(nil), Array) + +# StringIO is synchronized and that adds a high overhead on TruffleRuby. +# +# source://prism//lib/prism/serialize.rb#72 +Prism::Serialize::Loader::FastStringIO = StringIO + +# The major version of prism that we are expecting to find in the serialized +# strings. +# +# source://prism//lib/prism/serialize.rb#17 +Prism::Serialize::MAJOR_VERSION = T.let(T.unsafe(nil), Integer) + +# The minor version of prism that we are expecting to find in the serialized +# strings. +# +# source://prism//lib/prism/serialize.rb#21 +Prism::Serialize::MINOR_VERSION = T.let(T.unsafe(nil), Integer) + +# The patch version of prism that we are expecting to find in the serialized +# strings. +# +# source://prism//lib/prism/serialize.rb#25 +Prism::Serialize::PATCH_VERSION = T.let(T.unsafe(nil), Integer) + +# The token types that can be indexed by their enum values. +# +# source://prism//lib/prism/serialize.rb#1863 +Prism::Serialize::TOKEN_TYPES = T.let(T.unsafe(nil), Array) + +# This node wraps a constant write to indicate that when the value is written, it should have its shareability state modified. +# +# C = { a: 1 } +# ^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#16806 +class Prism::ShareableConstantNode < ::Prism::Node + # def initialize: (Integer flags, ConstantWriteNode | ConstantAndWriteNode | ConstantOrWriteNode | ConstantOperatorWriteNode | ConstantPathWriteNode | ConstantPathAndWriteNode | ConstantPathOrWriteNode | ConstantPathOperatorWriteNode write, Location location) -> void + # + # @return [ShareableConstantNode] a new instance of ShareableConstantNode + # + # source://prism//lib/prism/node.rb#16808 + sig do + params( + source: Prism::Source, + flags: Integer, + write: T.any(Prism::ConstantWriteNode, Prism::ConstantAndWriteNode, Prism::ConstantOrWriteNode, Prism::ConstantOperatorWriteNode, Prism::ConstantPathWriteNode, Prism::ConstantPathAndWriteNode, Prism::ConstantPathOrWriteNode, Prism::ConstantPathOperatorWriteNode), + location: Prism::Location + ).void + end + def initialize(source, flags, write, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#16905 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16816 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16821 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16831 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16826 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?write: ConstantWriteNode | ConstantAndWriteNode | ConstantOrWriteNode | ConstantOperatorWriteNode | ConstantPathWriteNode | ConstantPathAndWriteNode | ConstantPathOrWriteNode | ConstantPathOperatorWriteNode, ?location: Location) -> ShareableConstantNode + # + # source://prism//lib/prism/node.rb#16836 + sig do + params( + flags: Integer, + write: T.any(Prism::ConstantWriteNode, Prism::ConstantAndWriteNode, Prism::ConstantOrWriteNode, Prism::ConstantOperatorWriteNode, Prism::ConstantPathWriteNode, Prism::ConstantPathAndWriteNode, Prism::ConstantPathOrWriteNode, Prism::ConstantPathOperatorWriteNode), + location: Prism::Location + ).returns(Prism::ShareableConstantNode) + end + def copy(flags: T.unsafe(nil), write: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16821 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, write: ConstantWriteNode | ConstantAndWriteNode | ConstantOrWriteNode | ConstantOperatorWriteNode | ConstantPathWriteNode | ConstantPathAndWriteNode | ConstantPathOrWriteNode | ConstantPathOperatorWriteNode, location: Location } + # + # source://prism//lib/prism/node.rb#16844 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def experimental_copy?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#16866 + sig { returns(T::Boolean) } + def experimental_copy?; end + + # def experimental_everything?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#16861 + sig { returns(T::Boolean) } + def experimental_everything?; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#16871 + sig { override.returns(String) } + def inspect; end + + # def literal?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#16856 + sig { returns(T::Boolean) } + def literal?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16889 + sig { override.returns(Symbol) } + def type; end + + # The constant write that should be modified with the shareability state. + # + # source://prism//lib/prism/node.rb#16853 + sig do + returns(T.any(Prism::ConstantWriteNode, Prism::ConstantAndWriteNode, Prism::ConstantOrWriteNode, Prism::ConstantOperatorWriteNode, Prism::ConstantPathWriteNode, Prism::ConstantPathAndWriteNode, Prism::ConstantPathOrWriteNode, Prism::ConstantPathOperatorWriteNode)) + end + def write; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#16849 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#16899 + def type; end + end +end + +# Flags for shareable constant nodes. +# +# source://prism//lib/prism/node.rb#19256 +module Prism::ShareableConstantNodeFlags; end + +# constant writes that should be modified with shareable constant value experimental copy +# +# source://prism//lib/prism/node.rb#19264 +Prism::ShareableConstantNodeFlags::EXPERIMENTAL_COPY = T.let(T.unsafe(nil), Integer) + +# constant writes that should be modified with shareable constant value experimental everything +# +# source://prism//lib/prism/node.rb#19261 +Prism::ShareableConstantNodeFlags::EXPERIMENTAL_EVERYTHING = T.let(T.unsafe(nil), Integer) + +# constant writes that should be modified with shareable constant value literal +# +# source://prism//lib/prism/node.rb#19258 +Prism::ShareableConstantNodeFlags::LITERAL = T.let(T.unsafe(nil), Integer) + +# Represents a singleton class declaration involving the `class` keyword. +# +# class << self end +# ^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#16916 +class Prism::SingletonClassNode < ::Prism::Node + # def initialize: (Array[Symbol] locals, Location class_keyword_loc, Location operator_loc, Prism::node expression, Prism::node? body, Location end_keyword_loc, Location location) -> void + # + # @return [SingletonClassNode] a new instance of SingletonClassNode + # + # source://prism//lib/prism/node.rb#16918 + sig do + params( + source: Prism::Source, + locals: T::Array[Symbol], + class_keyword_loc: Prism::Location, + operator_loc: Prism::Location, + expression: Prism::Node, + body: T.nilable(Prism::Node), + end_keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, locals, class_keyword_loc, operator_loc, expression, body, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17045 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#16930 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Prism::node? + # + # source://prism//lib/prism/node.rb#16986 + sig { returns(T.nilable(Prism::Node)) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16935 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def class_keyword: () -> String + # + # source://prism//lib/prism/node.rb#16996 + sig { returns(String) } + def class_keyword; end + + # attr_reader class_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#16969 + sig { returns(Prism::Location) } + def class_keyword_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#16948 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#16940 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?locals: Array[Symbol], ?class_keyword_loc: Location, ?operator_loc: Location, ?expression: Prism::node, ?body: Prism::node?, ?end_keyword_loc: Location, ?location: Location) -> SingletonClassNode + # + # source://prism//lib/prism/node.rb#16953 + sig do + params( + locals: T::Array[Symbol], + class_keyword_loc: Prism::Location, + operator_loc: Prism::Location, + expression: Prism::Node, + body: T.nilable(Prism::Node), + end_keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::SingletonClassNode) + end + def copy(locals: T.unsafe(nil), class_keyword_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), expression: T.unsafe(nil), body: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#16935 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], class_keyword_loc: Location, operator_loc: Location, expression: Prism::node, body: Prism::node?, end_keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#16961 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String + # + # source://prism//lib/prism/node.rb#17006 + sig { returns(String) } + def end_keyword; end + + # attr_reader end_keyword_loc: Location + # + # source://prism//lib/prism/node.rb#16989 + sig { returns(Prism::Location) } + def end_keyword_loc; end + + # attr_reader expression: Prism::node + # + # source://prism//lib/prism/node.rb#16983 + sig { returns(Prism::Node) } + def expression; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17011 + sig { override.returns(String) } + def inspect; end + + # attr_reader locals: Array[Symbol] + # + # source://prism//lib/prism/node.rb#16966 + sig { returns(T::Array[Symbol]) } + def locals; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#17001 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#16976 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17029 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17039 + def type; end + end +end + +# This represents a source of Ruby code that has been parsed. It is used in +# conjunction with locations to allow them to resolve line numbers and source +# ranges. +# +# source://prism//lib/prism/parse_result.rb#7 +class Prism::Source + # Create a new source object with the given source code. + # + # @return [Source] a new instance of Source + # + # source://prism//lib/prism/parse_result.rb#26 + sig { params(source: String, start_line: Integer, offsets: T::Array[Integer]).void } + def initialize(source, start_line = T.unsafe(nil), offsets = T.unsafe(nil)); end + + # Return the column number in characters for the given byte offset. + # + # source://prism//lib/prism/parse_result.rb#78 + sig { params(byte_offset: Integer).returns(Integer) } + def character_column(byte_offset); end + + # Return the character offset for the given byte offset. + # + # source://prism//lib/prism/parse_result.rb#73 + sig { params(byte_offset: Integer).returns(Integer) } + def character_offset(byte_offset); end + + # Returns the column number in code units for the given encoding for the + # given byte offset. + # + # source://prism//lib/prism/parse_result.rb#95 + sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) } + def code_units_column(byte_offset, encoding); end + + # Returns the offset from the start of the file for the given byte offset + # counting in code units for the given encoding. + # + # This method is tested with UTF-8, UTF-16, and UTF-32. If there is the + # concept of code units that differs from the number of characters in other + # encodings, it is not captured here. + # + # source://prism//lib/prism/parse_result.rb#88 + sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) } + def code_units_offset(byte_offset, encoding); end + + # Return the column number for the given byte offset. + # + # source://prism//lib/prism/parse_result.rb#68 + sig { params(byte_offset: Integer).returns(Integer) } + def column(byte_offset); end + + # Returns the encoding of the source code, which is set by parameters to the + # parser or by the encoding magic comment. + # + # source://prism//lib/prism/parse_result.rb#34 + sig { returns(Encoding) } + def encoding; end + + # Binary search through the offsets to find the line number for the given + # byte offset. + # + # source://prism//lib/prism/parse_result.rb#51 + sig { params(byte_offset: Integer).returns(Integer) } + def line(byte_offset); end + + # Returns the byte offset of the end of the line corresponding to the given + # byte offset. + # + # source://prism//lib/prism/parse_result.rb#63 + def line_end(byte_offset); end + + # Return the byte offset of the start of the line corresponding to the given + # byte offset. + # + # source://prism//lib/prism/parse_result.rb#57 + sig { params(byte_offset: Integer).returns(Integer) } + def line_start(byte_offset); end + + # Returns the lines of the source code as an array of strings. + # + # source://prism//lib/prism/parse_result.rb#39 + sig { returns(T::Array[String]) } + def lines; end + + # The list of newline byte offsets in the source code. + # + # source://prism//lib/prism/parse_result.rb#23 + sig { returns(T::Array[Integer]) } + def offsets; end + + # Perform a byteslice on the source code using the given byte offset and + # byte length. + # + # source://prism//lib/prism/parse_result.rb#45 + sig { params(byte_offset: Integer, length: Integer).returns(String) } + def slice(byte_offset, length); end + + # The source code that this source object represents. + # + # source://prism//lib/prism/parse_result.rb#17 + sig { returns(String) } + def source; end + + # The line number where this source starts. + # + # source://prism//lib/prism/parse_result.rb#20 + sig { returns(Integer) } + def start_line; end + + private + + # Binary search through the offsets to find the line number for the given + # byte offset. + # + # source://prism//lib/prism/parse_result.rb#103 + def find_line(byte_offset); end + + class << self + # Create a new source object with the given source code. This method should + # be used instead of `new` and it will return either a `Source` or a + # specialized and more performant `ASCIISource` if no multibyte characters + # are present in the source code. + # + # source://prism//lib/prism/parse_result.rb#12 + def for(source, start_line = T.unsafe(nil), offsets = T.unsafe(nil)); end + end +end + +# Represents the use of the `__ENCODING__` keyword. +# +# __ENCODING__ +# ^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#17061 +class Prism::SourceEncodingNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [SourceEncodingNode] a new instance of SourceEncodingNode + # + # source://prism//lib/prism/node.rb#17063 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17136 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17069 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17074 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17084 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17079 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> SourceEncodingNode + # + # source://prism//lib/prism/node.rb#17089 + sig { params(location: Prism::Location).returns(Prism::SourceEncodingNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17074 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#17097 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17102 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17120 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17130 + def type; end + end +end + +# Represents the use of the `__FILE__` keyword. +# +# __FILE__ +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#17145 +class Prism::SourceFileNode < ::Prism::Node + # def initialize: (Integer flags, String filepath, Location location) -> void + # + # @return [SourceFileNode] a new instance of SourceFileNode + # + # source://prism//lib/prism/node.rb#17147 + sig { params(source: Prism::Source, flags: Integer, filepath: String, location: Prism::Location).void } + def initialize(source, flags, filepath, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17249 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17155 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17160 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17170 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17165 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?filepath: String, ?location: Location) -> SourceFileNode + # + # source://prism//lib/prism/node.rb#17175 + sig { params(flags: Integer, filepath: String, location: Prism::Location).returns(Prism::SourceFileNode) } + def copy(flags: T.unsafe(nil), filepath: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17160 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, filepath: String, location: Location } + # + # source://prism//lib/prism/node.rb#17183 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # Represents the file path being parsed. This corresponds directly to the `filepath` option given to the various `Prism::parse*` APIs. + # + # source://prism//lib/prism/node.rb#17192 + sig { returns(String) } + def filepath; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17200 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17195 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + # def frozen?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17205 + sig { returns(T::Boolean) } + def frozen?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17215 + sig { override.returns(String) } + def inspect; end + + # def mutable?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17210 + sig { returns(T::Boolean) } + def mutable?; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17233 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#17188 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17243 + def type; end + end +end + +# Represents the use of the `__LINE__` keyword. +# +# __LINE__ +# ^^^^^^^^ +# +# source://prism//lib/prism/node.rb#17260 +class Prism::SourceLineNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [SourceLineNode] a new instance of SourceLineNode + # + # source://prism//lib/prism/node.rb#17262 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17335 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17268 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17273 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17283 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17278 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> SourceLineNode + # + # source://prism//lib/prism/node.rb#17288 + sig { params(location: Prism::Location).returns(Prism::SourceLineNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17273 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#17296 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17301 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17319 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17329 + def type; end + end +end + +# Represents the use of the splat operator. +# +# [*a] +# ^^ +# +# source://prism//lib/prism/node.rb#17344 +class Prism::SplatNode < ::Prism::Node + # def initialize: (Location operator_loc, Prism::node? expression, Location location) -> void + # + # @return [SplatNode] a new instance of SplatNode + # + # source://prism//lib/prism/node.rb#17346 + sig do + params( + source: Prism::Source, + operator_loc: Prism::Location, + expression: T.nilable(Prism::Node), + location: Prism::Location + ).void + end + def initialize(source, operator_loc, expression, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17438 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17354 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17359 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17371 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17364 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?operator_loc: Location, ?expression: Prism::node?, ?location: Location) -> SplatNode + # + # source://prism//lib/prism/node.rb#17376 + sig do + params( + operator_loc: Prism::Location, + expression: T.nilable(Prism::Node), + location: Prism::Location + ).returns(Prism::SplatNode) + end + def copy(operator_loc: T.unsafe(nil), expression: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17359 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { operator_loc: Location, expression: Prism::node?, location: Location } + # + # source://prism//lib/prism/node.rb#17384 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # attr_reader expression: Prism::node? + # + # source://prism//lib/prism/node.rb#17396 + sig { returns(T.nilable(Prism::Node)) } + def expression; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17404 + sig { override.returns(String) } + def inspect; end + + # def operator: () -> String + # + # source://prism//lib/prism/node.rb#17399 + sig { returns(String) } + def operator; end + + # attr_reader operator_loc: Location + # + # source://prism//lib/prism/node.rb#17389 + sig { returns(Prism::Location) } + def operator_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17422 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17432 + def type; end + end +end + +# Represents a set of statements contained within some scope. +# +# foo; bar; baz +# ^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#17449 +class Prism::StatementsNode < ::Prism::Node + # def initialize: (Array[Prism::node] body, Location location) -> void + # + # @return [StatementsNode] a new instance of StatementsNode + # + # source://prism//lib/prism/node.rb#17451 + sig { params(source: Prism::Source, body: T::Array[Prism::Node], location: Prism::Location).void } + def initialize(source, body, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17528 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17458 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader body: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#17491 + sig { returns(T::Array[Prism::Node]) } + def body; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17463 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17473 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17468 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?body: Array[Prism::node], ?location: Location) -> StatementsNode + # + # source://prism//lib/prism/node.rb#17478 + sig { params(body: T::Array[Prism::Node], location: Prism::Location).returns(Prism::StatementsNode) } + def copy(body: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17463 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { body: Array[Prism::node], location: Location } + # + # source://prism//lib/prism/node.rb#17486 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17494 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17512 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17522 + def type; end + end +end + +# Flags for string nodes. +# +# source://prism//lib/prism/node.rb#19268 +module Prism::StringFlags; end + +# internal bytes forced the encoding to binary +# +# source://prism//lib/prism/node.rb#19273 +Prism::StringFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer) + +# internal bytes forced the encoding to UTF-8 +# +# source://prism//lib/prism/node.rb#19270 +Prism::StringFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer) + +# source://prism//lib/prism/node.rb#19276 +Prism::StringFlags::FROZEN = T.let(T.unsafe(nil), Integer) + +# source://prism//lib/prism/node.rb#19279 +Prism::StringFlags::MUTABLE = T.let(T.unsafe(nil), Integer) + +# Represents a string literal, a string contained within a `%w` list, or plain string content within an interpolated string. +# +# "foo" +# ^^^^^ +# +# %w[foo] +# ^^^ +# +# "foo #{bar} baz" +# ^^^^ ^^^^ +# +# source://prism//lib/prism/node.rb#17545 +class Prism::StringNode < ::Prism::Node + include ::Prism::HeredocQuery + + # def initialize: (Integer flags, Location? opening_loc, Location content_loc, Location? closing_loc, String unescaped, Location location) -> void + # + # @return [StringNode] a new instance of StringNode + # + # source://prism//lib/prism/node.rb#17547 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: T.nilable(Prism::Location), + content_loc: Prism::Location, + closing_loc: T.nilable(Prism::Location), + unescaped: String, + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17700 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17558 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17563 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#17661 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#17615 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17573 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17568 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def content: () -> String + # + # source://prism//lib/prism/node.rb#17656 + sig { returns(String) } + def content; end + + # attr_reader content_loc: Location + # + # source://prism//lib/prism/node.rb#17608 + sig { returns(Prism::Location) } + def content_loc; end + + # def copy: (?flags: Integer, ?opening_loc: Location?, ?content_loc: Location, ?closing_loc: Location?, ?unescaped: String, ?location: Location) -> StringNode + # + # source://prism//lib/prism/node.rb#17578 + sig do + params( + flags: Integer, + opening_loc: T.nilable(Prism::Location), + content_loc: Prism::Location, + closing_loc: T.nilable(Prism::Location), + unescaped: String, + location: Prism::Location + ).returns(Prism::StringNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17563 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location?, content_loc: Location, closing_loc: Location?, unescaped: String, location: Location } + # + # source://prism//lib/prism/node.rb#17586 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17636 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17631 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + # def frozen?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17641 + sig { returns(T::Boolean) } + def frozen?; end + + sig { returns(T::Boolean) } + def heredoc?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17666 + sig { override.returns(String) } + def inspect; end + + # def mutable?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17646 + sig { returns(T::Boolean) } + def mutable?; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#17651 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#17595 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # Occasionally it's helpful to treat a string as if it were interpolated so + # that there's a consistent interface for working with strings. + # + # source://prism//lib/prism/node_ext.rb#69 + sig { returns(Prism::InterpolatedStringNode) } + def to_interpolated; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17684 + sig { override.returns(Symbol) } + def type; end + + # attr_reader unescaped: String + # + # source://prism//lib/prism/node.rb#17628 + sig { returns(String) } + def unescaped; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#17591 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17694 + def type; end + end +end + +# Represents the use of the `super` keyword with parentheses or arguments. +# +# super() +# ^^^^^^^ +# +# super foo, bar +# ^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#17717 +class Prism::SuperNode < ::Prism::Node + # def initialize: (Location keyword_loc, Location? lparen_loc, ArgumentsNode? arguments, Location? rparen_loc, Prism::node? block, Location location) -> void + # + # @return [SuperNode] a new instance of SuperNode + # + # source://prism//lib/prism/node.rb#17719 + sig do + params( + source: Prism::Source, + keyword_loc: Prism::Location, + lparen_loc: T.nilable(Prism::Location), + arguments: T.nilable(Prism::ArgumentsNode), + rparen_loc: T.nilable(Prism::Location), + block: T.nilable(Prism::Node), + location: Prism::Location + ).void + end + def initialize(source, keyword_loc, lparen_loc, arguments, rparen_loc, block, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#17854 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17730 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#17786 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # attr_reader block: Prism::node? + # + # source://prism//lib/prism/node.rb#17802 + sig { returns(T.nilable(Prism::Node)) } + def block; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17735 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17748 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17740 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?keyword_loc: Location, ?lparen_loc: Location?, ?arguments: ArgumentsNode?, ?rparen_loc: Location?, ?block: Prism::node?, ?location: Location) -> SuperNode + # + # source://prism//lib/prism/node.rb#17753 + sig do + params( + keyword_loc: Prism::Location, + lparen_loc: T.nilable(Prism::Location), + arguments: T.nilable(Prism::ArgumentsNode), + rparen_loc: T.nilable(Prism::Location), + block: T.nilable(Prism::Node), + location: Prism::Location + ).returns(Prism::SuperNode) + end + def copy(keyword_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), arguments: T.unsafe(nil), rparen_loc: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17735 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, lparen_loc: Location?, arguments: ArgumentsNode?, rparen_loc: Location?, block: Prism::node?, location: Location } + # + # source://prism//lib/prism/node.rb#17761 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17820 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#17805 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#17766 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def lparen: () -> String? + # + # source://prism//lib/prism/node.rb#17810 + sig { returns(T.nilable(String)) } + def lparen; end + + # attr_reader lparen_loc: Location? + # + # source://prism//lib/prism/node.rb#17773 + sig { returns(T.nilable(Prism::Location)) } + def lparen_loc; end + + # def rparen: () -> String? + # + # source://prism//lib/prism/node.rb#17815 + sig { returns(T.nilable(String)) } + def rparen; end + + # attr_reader rparen_loc: Location? + # + # source://prism//lib/prism/node.rb#17789 + sig { returns(T.nilable(Prism::Location)) } + def rparen_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17838 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#17848 + def type; end + end +end + +# Flags for symbol nodes. +# +# source://prism//lib/prism/node.rb#19283 +module Prism::SymbolFlags; end + +# internal bytes forced the encoding to binary +# +# source://prism//lib/prism/node.rb#19288 +Prism::SymbolFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer) + +# internal bytes forced the encoding to US-ASCII +# +# source://prism//lib/prism/node.rb#19291 +Prism::SymbolFlags::FORCED_US_ASCII_ENCODING = T.let(T.unsafe(nil), Integer) + +# internal bytes forced the encoding to UTF-8 +# +# source://prism//lib/prism/node.rb#19285 +Prism::SymbolFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer) + +# Represents a symbol literal or a symbol contained within a `%i` list. +# +# :foo +# ^^^^ +# +# %i[foo] +# ^^^ +# +# source://prism//lib/prism/node.rb#17871 +class Prism::SymbolNode < ::Prism::Node + # def initialize: (Integer flags, Location? opening_loc, Location? value_loc, Location? closing_loc, String unescaped, Location location) -> void + # + # @return [SymbolNode] a new instance of SymbolNode + # + # source://prism//lib/prism/node.rb#17873 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: T.nilable(Prism::Location), + value_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + unescaped: String, + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, value_loc, closing_loc, unescaped, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18027 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#17884 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17889 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#17988 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#17947 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#17899 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#17894 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?opening_loc: Location?, ?value_loc: Location?, ?closing_loc: Location?, ?unescaped: String, ?location: Location) -> SymbolNode + # + # source://prism//lib/prism/node.rb#17904 + sig do + params( + flags: Integer, + opening_loc: T.nilable(Prism::Location), + value_loc: T.nilable(Prism::Location), + closing_loc: T.nilable(Prism::Location), + unescaped: String, + location: Prism::Location + ).returns(Prism::SymbolNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), value_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#17889 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location?, value_loc: Location?, closing_loc: Location?, unescaped: String, location: Location } + # + # source://prism//lib/prism/node.rb#17912 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17968 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_us_ascii_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17973 + sig { returns(T::Boolean) } + def forced_us_ascii_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#17963 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#17993 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String? + # + # source://prism//lib/prism/node.rb#17978 + sig { returns(T.nilable(String)) } + def opening; end + + # attr_reader opening_loc: Location? + # + # source://prism//lib/prism/node.rb#17921 + sig { returns(T.nilable(Prism::Location)) } + def opening_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18011 + sig { override.returns(Symbol) } + def type; end + + # attr_reader unescaped: String + # + # source://prism//lib/prism/node.rb#17960 + sig { returns(String) } + def unescaped; end + + # def value: () -> String? + # + # source://prism//lib/prism/node.rb#17983 + sig { returns(T.nilable(String)) } + def value; end + + # attr_reader value_loc: Location? + # + # source://prism//lib/prism/node.rb#17934 + sig { returns(T.nilable(Prism::Location)) } + def value_loc; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#17917 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18021 + def type; end + end +end + +# This represents a token from the Ruby source. +# +# source://prism//lib/prism/parse_result.rb#645 +class Prism::Token + # Create a new token object with the given type, value, and location. + # + # @return [Token] a new instance of Token + # + # source://prism//lib/prism/parse_result.rb#657 + sig { params(source: Prism::Source, type: Symbol, value: String, location: T.any(Integer, Prism::Location)).void } + def initialize(source, type, value, location); end + + # Returns true if the given other token is equal to this token. + # + # source://prism//lib/prism/parse_result.rb#692 + sig { params(other: T.untyped).returns(T::Boolean) } + def ==(other); end + + # Implement the hash pattern matching interface for Token. + # + # source://prism//lib/prism/parse_result.rb#665 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # A Location object representing the location of this token in the source. + # + # source://prism//lib/prism/parse_result.rb#670 + sig { returns(Prism::Location) } + def location; end + + # Implement the pretty print interface for Token. + # + # source://prism//lib/prism/parse_result.rb#677 + sig { params(q: T.untyped).void } + def pretty_print(q); end + + # The type of token that this token is. + # + # source://prism//lib/prism/parse_result.rb#651 + sig { returns(Symbol) } + def type; end + + # A byteslice of the source that this token represents. + # + # source://prism//lib/prism/parse_result.rb#654 + sig { returns(String) } + def value; end + + private + + # The Source object that represents the source this token came from. + # + # source://prism//lib/prism/parse_result.rb#647 + sig { returns(Prism::Source) } + def source; end +end + +# This module is responsible for converting the prism syntax tree into other +# syntax trees. +# +# source://prism//lib/prism/translation.rb#6 +module Prism::Translation; end + +# This class is the entry-point for converting a prism syntax tree into the +# whitequark/parser gem's syntax tree. It inherits from the base parser for +# the parser gem, and overrides the parse* methods to parse with prism and +# then translate. +# +# source://prism//lib/prism/translation/parser.rb#16 +class Prism::Translation::Parser < ::Parser::Base + # The default encoding for Ruby files is UTF-8. + # + # source://prism//lib/prism/translation/parser.rb#41 + def default_encoding; end + + # Parses a source buffer and returns the AST. + # + # source://prism//lib/prism/translation/parser.rb#49 + def parse(source_buffer); end + + # Parses a source buffer and returns the AST and the source code comments. + # + # source://prism//lib/prism/translation/parser.rb#62 + def parse_with_comments(source_buffer); end + + # Parses a source buffer and returns the AST, the source code comments, + # and the tokens emitted by the lexer. + # + # source://prism//lib/prism/translation/parser.rb#79 + def tokenize(source_buffer, recover = T.unsafe(nil)); end + + # Since prism resolves num params for us, we don't need to support this + # kind of logic here. + # + # source://prism//lib/prism/translation/parser.rb#105 + def try_declare_numparam(node); end + + # source://prism//lib/prism/translation/parser.rb#36 + sig { overridable.returns(Integer) } + def version; end + + # source://prism//lib/prism/translation/parser.rb#45 + def yyerror; end + + private + + # Build the parser gem AST from the prism AST. + # + # source://prism//lib/prism/translation/parser.rb#263 + def build_ast(program, offset_cache); end + + # Build the parser gem comments from the prism comments. + # + # source://prism//lib/prism/translation/parser.rb#268 + def build_comments(comments, offset_cache); end + + # Prism deals with offsets in bytes, while the parser gem deals with + # offsets in characters. We need to handle this conversion in order to + # build the parser gem AST. + # + # If the bytesize of the source is the same as the length, then we can + # just use the offset directly. Otherwise, we build an array where the + # index is the byte offset and the value is the character offset. + # + # source://prism//lib/prism/translation/parser.rb#246 + def build_offset_cache(source); end + + # Build a range from a prism location. + # + # source://prism//lib/prism/translation/parser.rb#280 + def build_range(location, offset_cache); end + + # Build the parser gem tokens from the prism tokens. + # + # source://prism//lib/prism/translation/parser.rb#275 + def build_tokens(tokens, offset_cache); end + + # Converts the version format handled by Parser to the format handled by Prism. + # + # source://prism//lib/prism/translation/parser.rb#289 + def convert_for_prism(version); end + + # Build a diagnostic from the given prism parse error. + # + # source://prism//lib/prism/translation/parser.rb#124 + def error_diagnostic(error, offset_cache); end + + # If there was a error generated during the parse, then raise an + # appropriate syntax error. Otherwise return the result. + # + # source://prism//lib/prism/translation/parser.rb#224 + def unwrap(result, offset_cache); end + + # This is a hook to allow consumers to disable some errors if they don't + # want them to block creating the syntax tree. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/parser.rb#113 + def valid_error?(error); end + + # This is a hook to allow consumers to disable some warnings if they don't + # want them to block creating the syntax tree. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/parser.rb#119 + def valid_warning?(warning); end + + # Build a diagnostic from the given prism parse warning. + # + # source://prism//lib/prism/translation/parser.rb#197 + def warning_diagnostic(warning, offset_cache); end +end + +# This class is the entry-point for Ruby 3.3 of `Prism::Translation::Parser`. +# +# source://prism//lib/prism/translation/parser33.rb#6 +class Prism::Translation::Parser33 < ::Prism::Translation::Parser + # source://prism//lib/prism/translation/parser33.rb#7 + sig { override.returns(Integer) } + def version; end +end + +# This class is the entry-point for Ruby 3.4 of `Prism::Translation::Parser`. +# +# source://prism//lib/prism/translation/parser34.rb#6 +class Prism::Translation::Parser34 < ::Prism::Translation::Parser + # source://prism//lib/prism/translation/parser34.rb#7 + sig { override.returns(Integer) } + def version; end +end + +# A visitor that knows how to convert a prism syntax tree into the +# whitequark/parser gem's syntax tree. +# +# source://prism//lib/prism/translation/parser/compiler.rb#8 +class Prism::Translation::Parser::Compiler < ::Prism::Compiler + # Initialize a new compiler with the given parser, offset cache, and + # options. + # + # @return [Compiler] a new instance of Compiler + # + # source://prism//lib/prism/translation/parser/compiler.rb#39 + def initialize(parser, offset_cache, forwarding: T.unsafe(nil), in_destructure: T.unsafe(nil), in_pattern: T.unsafe(nil)); end + + # The Parser::Builders::Default instance that is being used to build the + # AST. + # + # source://prism//lib/prism/translation/parser/compiler.rb#18 + def builder; end + + # The types of values that can be forwarded in the current scope. + # + # source://prism//lib/prism/translation/parser/compiler.rb#29 + def forwarding; end + + # Whether or not the current node is in a destructure. + # + # source://prism//lib/prism/translation/parser/compiler.rb#32 + def in_destructure; end + + # Whether or not the current node is in a pattern. + # + # source://prism//lib/prism/translation/parser/compiler.rb#35 + def in_pattern; end + + # The offset cache that is used to map between byte and character + # offsets in the file. + # + # source://prism//lib/prism/translation/parser/compiler.rb#26 + def offset_cache; end + + # The Parser::Base instance that is being used to build the AST. + # + # source://prism//lib/prism/translation/parser/compiler.rb#14 + def parser; end + + # The Parser::Source::Buffer instance that is holding a reference to the + # source code. + # + # source://prism//lib/prism/translation/parser/compiler.rb#22 + def source_buffer; end + + # alias $foo $bar + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#58 + def visit_alias_global_variable_node(node); end + + # alias foo bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#52 + def visit_alias_method_node(node); end + + # foo => bar | baz + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#64 + def visit_alternation_pattern_node(node); end + + # a and b + # ^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#70 + def visit_and_node(node); end + + # foo(bar) + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#105 + def visit_arguments_node(node); end + + # [] + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#76 + def visit_array_node(node); end + + # foo => [bar] + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#82 + def visit_array_pattern_node(node); end + + # { a: 1 } + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#111 + def visit_assoc_node(node); end + + # def foo(**); bar(**); end + # ^^ + # + # { **foo } + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#160 + def visit_assoc_splat_node(node); end + + # $+ + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#172 + def visit_back_reference_read_node(node); end + + # begin end + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#178 + def visit_begin_node(node); end + + # foo(&bar) + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#216 + def visit_block_argument_node(node); end + + # foo { |; bar| } + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#222 + def visit_block_local_variable_node(node); end + + # A block on a keyword or method call. + # + # @raise [CompilationError] + # + # source://prism//lib/prism/translation/parser/compiler.rb#227 + def visit_block_node(node); end + + # def foo(&bar); end + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#233 + def visit_block_parameter_node(node); end + + # A block's parameters. + # + # source://prism//lib/prism/translation/parser/compiler.rb#238 + def visit_block_parameters_node(node); end + + # break + # ^^^^^ + # + # break foo + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#247 + def visit_break_node(node); end + + # foo.bar &&= baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#352 + def visit_call_and_write_node(node); end + + # foo + # ^^^ + # + # foo.bar + # ^^^^^^^ + # + # foo.bar() {} + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#259 + def visit_call_node(node); end + + # foo.bar += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#333 + def visit_call_operator_write_node(node); end + + # foo.bar ||= baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#371 + def visit_call_or_write_node(node); end + + # foo.bar, = 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#390 + def visit_call_target_node(node); end + + # foo => bar => baz + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#402 + def visit_capture_pattern_node(node); end + + # case foo; in bar; end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#421 + def visit_case_match_node(node); end + + # case foo; when bar; end + # ^^^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#408 + def visit_case_node(node); end + + # class Foo; end + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#434 + def visit_class_node(node); end + + # @@foo &&= bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#473 + def visit_class_variable_and_write_node(node); end + + # @@foo += bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#463 + def visit_class_variable_operator_write_node(node); end + + # @@foo ||= bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#483 + def visit_class_variable_or_write_node(node); end + + # @@foo + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#447 + def visit_class_variable_read_node(node); end + + # @@foo, = bar + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#493 + def visit_class_variable_target_node(node); end + + # @@foo = 1 + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#453 + def visit_class_variable_write_node(node); end + + # Foo &&= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#524 + def visit_constant_and_write_node(node); end + + # Foo += bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#514 + def visit_constant_operator_write_node(node); end + + # Foo ||= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#534 + def visit_constant_or_write_node(node); end + + # Foo::Bar &&= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#590 + def visit_constant_path_and_write_node(node); end + + # Foo::Bar + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#550 + def visit_constant_path_node(node); end + + # Foo::Bar += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#580 + def visit_constant_path_operator_write_node(node); end + + # Foo::Bar ||= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#600 + def visit_constant_path_or_write_node(node); end + + # Foo::Bar, = baz + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#610 + def visit_constant_path_target_node(node); end + + # Foo::Bar = 1 + # ^^^^^^^^^^^^ + # + # Foo::Foo, Bar::Bar = 1 + # ^^^^^^^^ ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#570 + def visit_constant_path_write_node(node); end + + # Foo + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#499 + def visit_constant_read_node(node); end + + # Foo, = bar + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#544 + def visit_constant_target_node(node); end + + # Foo = 1 + # ^^^^^^^ + # + # Foo, Bar = 1 + # ^^^ ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#508 + def visit_constant_write_node(node); end + + # def foo; end + # ^^^^^^^^^^^^ + # + # def self.foo; end + # ^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#619 + def visit_def_node(node); end + + # defined? a + # ^^^^^^^^^^ + # + # defined?(a) + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#666 + def visit_defined_node(node); end + + # if foo then bar else baz end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#678 + def visit_else_node(node); end + + # "foo #{bar}" + # ^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#684 + def visit_embedded_statements_node(node); end + + # "foo #@bar" + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#694 + def visit_embedded_variable_node(node); end + + # begin; foo; ensure; bar; end + # ^^^^^^^^^^^^ + # + # @raise [CompilationError] + # + # source://prism//lib/prism/translation/parser/compiler.rb#700 + def visit_ensure_node(node); end + + # false + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#706 + def visit_false_node(node); end + + # foo => [*, bar, *] + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#712 + def visit_find_pattern_node(node); end + + # 0..5 + # ^^^^ + # if foo .. bar; end + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1475 + def visit_flip_flop_node(node); end + + # 1.0 + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#724 + def visit_float_node(node); end + + # for foo in bar do end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#730 + def visit_for_node(node); end + + # def foo(...); bar(...); end + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#748 + def visit_forwarding_arguments_node(node); end + + # def foo(...); end + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#754 + def visit_forwarding_parameter_node(node); end + + # super + # ^^^^^ + # + # super {} + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#763 + def visit_forwarding_super_node(node); end + + # $foo &&= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#801 + def visit_global_variable_and_write_node(node); end + + # $foo += bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#791 + def visit_global_variable_operator_write_node(node); end + + # $foo ||= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#811 + def visit_global_variable_or_write_node(node); end + + # $foo + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#775 + def visit_global_variable_read_node(node); end + + # $foo, = bar + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#821 + def visit_global_variable_target_node(node); end + + # $foo = 1 + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#781 + def visit_global_variable_write_node(node); end + + # {} + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#827 + def visit_hash_node(node); end + + # foo => {} + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#837 + def visit_hash_pattern_node(node); end + + # if foo then bar end + # ^^^^^^^^^^^^^^^^^^^ + # + # bar if foo + # ^^^^^^^^^^ + # + # foo ? bar : baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#855 + def visit_if_node(node); end + + # 1i + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#897 + def visit_imaginary_node(node); end + + # { foo: } + # ^^^^ + # + # @raise [CompilationError] + # + # source://prism//lib/prism/translation/parser/compiler.rb#903 + def visit_implicit_node(node); end + + # foo { |bar,| } + # ^ + # + # @raise [CompilationError] + # + # source://prism//lib/prism/translation/parser/compiler.rb#909 + def visit_implicit_rest_node(node); end + + # case foo; in bar; end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#915 + def visit_in_node(node); end + + # foo[bar] &&= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#959 + def visit_index_and_write_node(node); end + + # foo[bar] += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#941 + def visit_index_operator_write_node(node); end + + # foo[bar] ||= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#977 + def visit_index_or_write_node(node); end + + # foo[bar], = 1 + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#995 + def visit_index_target_node(node); end + + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1032 + def visit_instance_variable_and_write_node(node); end + + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1022 + def visit_instance_variable_operator_write_node(node); end + + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1042 + def visit_instance_variable_or_write_node(node); end + + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1006 + def visit_instance_variable_read_node(node); end + + # @foo, = bar + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1052 + def visit_instance_variable_target_node(node); end + + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1012 + def visit_instance_variable_write_node(node); end + + # 1 + # ^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1058 + def visit_integer_node(node); end + + # /foo #{bar}/ + # ^^^^^^^^^^^^ + # if /foo #{bar}/ then end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1064 + def visit_interpolated_match_last_line_node(node); end + + # /foo #{bar}/ + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1064 + def visit_interpolated_regular_expression_node(node); end + + # "foo #{bar}" + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1079 + def visit_interpolated_string_node(node); end + + # :"foo #{bar}" + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1113 + def visit_interpolated_symbol_node(node); end + + # `foo #{bar}` + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1123 + def visit_interpolated_x_string_node(node); end + + # -> { it } + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1137 + def visit_it_local_variable_read_node(node); end + + # -> { it } + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1143 + def visit_it_parameters_node(node); end + + # foo(bar: baz) + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1149 + def visit_keyword_hash_node(node); end + + # def foo(**bar); end + # ^^^^^ + # + # def foo(**); end + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1158 + def visit_keyword_rest_parameter_node(node); end + + # -> {} + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1167 + def visit_lambda_node(node); end + + # foo &&= bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1219 + def visit_local_variable_and_write_node(node); end + + # foo += bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1209 + def visit_local_variable_operator_write_node(node); end + + # foo ||= bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1229 + def visit_local_variable_or_write_node(node); end + + # foo + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1193 + def visit_local_variable_read_node(node); end + + # foo, = bar + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1239 + def visit_local_variable_target_node(node); end + + # foo = 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1199 + def visit_local_variable_write_node(node); end + + # /foo/ + # ^^^^^ + # if /foo/ then end + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1509 + def visit_match_last_line_node(node); end + + # foo in bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1249 + def visit_match_predicate_node(node); end + + # foo => bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1259 + def visit_match_required_node(node); end + + # /(?foo)/ =~ bar + # ^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1269 + def visit_match_write_node(node); end + + # A node that is missing from the syntax tree. This is only used in the + # case of a syntax error. The parser gem doesn't have such a concept, so + # we invent our own here. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1280 + def visit_missing_node(node); end + + # module Foo; end + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1286 + def visit_module_node(node); end + + # foo, bar = baz + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1297 + def visit_multi_target_node(node); end + + # foo, bar = baz + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1307 + def visit_multi_write_node(node); end + + # next + # ^^^^ + # + # next foo + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1330 + def visit_next_node(node); end + + # nil + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1342 + def visit_nil_node(node); end + + # def foo(**nil); end + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1348 + def visit_no_keywords_parameter_node(node); end + + # -> { _1 + _2 } + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1358 + def visit_numbered_parameters_node(node); end + + # $1 + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1364 + def visit_numbered_reference_read_node(node); end + + # def foo(bar: baz); end + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1370 + def visit_optional_keyword_parameter_node(node); end + + # def foo(bar = 1); end + # ^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1376 + def visit_optional_parameter_node(node); end + + # a or b + # ^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1382 + def visit_or_node(node); end + + # def foo(bar, *baz); end + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1388 + def visit_parameters_node(node); end + + # () + # ^^ + # + # (1) + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1427 + def visit_parentheses_node(node); end + + # foo => ^(bar) + # ^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1437 + def visit_pinned_expression_node(node); end + + # foo = 1 and bar => ^foo + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1444 + def visit_pinned_variable_node(node); end + + # END {} + # + # source://prism//lib/prism/translation/parser/compiler.rb#1449 + def visit_post_execution_node(node); end + + # BEGIN {} + # + # source://prism//lib/prism/translation/parser/compiler.rb#1459 + def visit_pre_execution_node(node); end + + # The top-level program node. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1469 + def visit_program_node(node); end + + # 0..5 + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1475 + def visit_range_node(node); end + + # 1r + # ^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1497 + def visit_rational_node(node); end + + # redo + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1503 + def visit_redo_node(node); end + + # /foo/ + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1509 + def visit_regular_expression_node(node); end + + # def foo(bar:); end + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1535 + def visit_required_keyword_parameter_node(node); end + + # def foo(bar); end + # ^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1541 + def visit_required_parameter_node(node); end + + # foo rescue bar + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1547 + def visit_rescue_modifier_node(node); end + + # begin; rescue; end + # ^^^^^^^ + # + # @raise [CompilationError] + # + # source://prism//lib/prism/translation/parser/compiler.rb#1565 + def visit_rescue_node(node); end + + # def foo(*bar); end + # ^^^^ + # + # def foo(*); end + # ^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1574 + def visit_rest_parameter_node(node); end + + # retry + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1580 + def visit_retry_node(node); end + + # return + # ^^^^^^ + # + # return 1 + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1589 + def visit_return_node(node); end + + # self + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1601 + def visit_self_node(node); end + + # A shareable constant. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1606 + def visit_shareable_constant_node(node); end + + # class << self; end + # ^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1612 + def visit_singleton_class_node(node); end + + # __ENCODING__ + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1624 + def visit_source_encoding_node(node); end + + # __FILE__ + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1630 + def visit_source_file_node(node); end + + # __LINE__ + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1636 + def visit_source_line_node(node); end + + # foo(*bar) + # ^^^^ + # + # def foo((bar, *baz)); end + # ^^^^ + # + # def foo(*); bar(*); end + # ^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1648 + def visit_splat_node(node); end + + # A list of statements. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1661 + def visit_statements_node(node); end + + # "foo" + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1667 + def visit_string_node(node); end + + # super(foo) + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1709 + def visit_super_node(node); end + + # :foo + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1732 + def visit_symbol_node(node); end + + # true + # ^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1764 + def visit_true_node(node); end + + # undef foo + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1770 + def visit_undef_node(node); end + + # unless foo; bar end + # ^^^^^^^^^^^^^^^^^^^ + # + # bar unless foo + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1779 + def visit_unless_node(node); end + + # until foo; bar end + # ^^^^^^^^^^^^^^^^^^ + # + # bar until foo + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1809 + def visit_until_node(node); end + + # case foo; when bar; end + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1831 + def visit_when_node(node); end + + # while foo; bar end + # ^^^^^^^^^^^^^^^^^^ + # + # bar while foo + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1849 + def visit_while_node(node); end + + # `foo` + # ^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1871 + def visit_x_string_node(node); end + + # yield + # ^^^^^ + # + # yield 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/parser/compiler.rb#1902 + def visit_yield_node(node); end + + private + + # The parser gem automatically converts \r\n to \n, meaning our offsets + # need to be adjusted to always subtract 1 from the length. + # + # source://prism//lib/prism/translation/parser/compiler.rb#2045 + def chomped_bytesize(line); end + + # Initialize a new compiler with the given option overrides, used to + # visit a subtree with the given options. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1916 + def copy_compiler(forwarding: T.unsafe(nil), in_destructure: T.unsafe(nil), in_pattern: T.unsafe(nil)); end + + # When *, **, &, or ... are used as an argument in a method call, we + # check if they were allowed by the current context. To determine that + # we build this lookup table. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1923 + def find_forwarding(node); end + + # Returns the set of targets for a MultiTargetNode or a MultiWriteNode. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1936 + def multi_target_elements(node); end + + # Negate the value of a numeric node. This is a special case where you + # have a negative sign on one line and then a number on the next line. + # In normal Ruby, this will always be a method call. The parser gem, + # however, marks this as a numeric literal. We have to massage the tree + # here to get it into the correct form. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1948 + def numeric_negate(message_loc, receiver); end + + # Blocks can have a special set of parameters that automatically expand + # when given arrays if they have a single required parameter and no + # other parameters. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/parser/compiler.rb#1962 + def procarg0?(parameters); end + + # Constructs a new source range from the given start and end offsets. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1979 + def srange(location); end + + # Constructs a new source range by finding the given tokens between the + # given start offset and end offset. If the needle is not found, it + # returns nil. Importantly it does not search past newlines or comments. + # + # Note that end_offset is allowed to be nil, in which case this will + # search until the end of the string. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1994 + def srange_find(start_offset, end_offset, tokens); end + + # Constructs a new source range from the given start and end offsets. + # + # source://prism//lib/prism/translation/parser/compiler.rb#1984 + def srange_offsets(start_offset, end_offset); end + + # Transform a location into a token that the parser gem expects. + # + # source://prism//lib/prism/translation/parser/compiler.rb#2004 + def token(location); end + + # Visit a block node on a call. + # + # source://prism//lib/prism/translation/parser/compiler.rb#2009 + def visit_block(call, block); end + + # Visit a heredoc that can be either a string or an xstring. + # + # source://prism//lib/prism/translation/parser/compiler.rb#2051 + def visit_heredoc(node); end + + # Visit a numeric node and account for the optional sign. + # + # source://prism//lib/prism/translation/parser/compiler.rb#2123 + def visit_numeric(node, value); end + + # Within the given block, track that we're within a pattern. + # + # source://prism//lib/prism/translation/parser/compiler.rb#2135 + def within_pattern; end +end + +# Raised when the tree is malformed or there is a bug in the compiler. +# +# source://prism//lib/prism/translation/parser/compiler.rb#10 +class Prism::Translation::Parser::Compiler::CompilationError < ::StandardError; end + +# Locations in the parser gem AST are generated using this class. We +# store a reference to its constant to make it slightly faster to look +# up. +# +# source://prism//lib/prism/translation/parser/compiler.rb#1976 +Prism::Translation::Parser::Compiler::Range = Parser::Source::Range + +# source://prism//lib/prism/translation/parser.rb#17 +Prism::Translation::Parser::Diagnostic = Parser::Diagnostic + +# Accepts a list of prism tokens and converts them into the expected +# format for the parser gem. +# +# source://prism//lib/prism/translation/parser/lexer.rb#8 +class Prism::Translation::Parser::Lexer + # Initialize the lexer with the given source buffer, prism tokens, and + # offset cache. + # + # @return [Lexer] a new instance of Lexer + # + # source://prism//lib/prism/translation/parser/lexer.rb#204 + def initialize(source_buffer, lexed, offset_cache); end + + # An array of tuples that contain prism tokens and their associated lex + # state when they were lexed. + # + # source://prism//lib/prism/translation/parser/lexer.rb#197 + def lexed; end + + # A hash that maps offsets in bytes to offsets in characters. + # + # source://prism//lib/prism/translation/parser/lexer.rb#200 + def offset_cache; end + + # The Parser::Source::Buffer that the tokens were lexed from. + # + # source://prism//lib/prism/translation/parser/lexer.rb#193 + def source_buffer; end + + # Convert the prism tokens into the expected format for the parser gem. + # + # source://prism//lib/prism/translation/parser/lexer.rb#214 + def to_a; end + + private + + # Parse a complex from the string representation. + # + # source://prism//lib/prism/translation/parser/lexer.rb#387 + def parse_complex(value); end + + # Parse a float from the string representation. + # + # source://prism//lib/prism/translation/parser/lexer.rb#380 + def parse_float(value); end + + # Parse an integer from the string representation. + # + # source://prism//lib/prism/translation/parser/lexer.rb#373 + def parse_integer(value); end + + # Parse a rational from the string representation. + # + # source://prism//lib/prism/translation/parser/lexer.rb#402 + def parse_rational(value); end +end + +# These constants represent flags in our lex state. We really, really +# don't want to be using them and we really, really don't want to be +# exposing them as part of our public API. Unfortunately, we don't have +# another way of matching the exact tokens that the parser gem expects +# without them. We should find another way to do this, but in the +# meantime we'll hide them from the documentation and mark them as +# private constants. +# +# source://prism//lib/prism/translation/parser/lexer.rb#187 +Prism::Translation::Parser::Lexer::EXPR_BEG = T.let(T.unsafe(nil), Integer) + +# source://prism//lib/prism/translation/parser/lexer.rb#188 +Prism::Translation::Parser::Lexer::EXPR_LABEL = T.let(T.unsafe(nil), Integer) + +# source://prism//lib/prism/translation/parser/lexer.rb#210 +Prism::Translation::Parser::Lexer::Range = Parser::Source::Range + +# The direct translating of types between the two lexers. +# +# source://prism//lib/prism/translation/parser/lexer.rb#10 +Prism::Translation::Parser::Lexer::TYPES = T.let(T.unsafe(nil), Hash) + +# The parser gem has a list of diagnostics with a hard-coded set of error +# messages. We create our own diagnostic class in order to set our own +# error messages. +# +# source://prism//lib/prism/translation/parser.rb#23 +class Prism::Translation::Parser::PrismDiagnostic < ::Parser::Diagnostic + # Initialize a new diagnostic with the given message and location. + # + # @return [PrismDiagnostic] a new instance of PrismDiagnostic + # + # source://prism//lib/prism/translation/parser.rb#28 + def initialize(message, level, reason, location); end + + # This is the cached message coming from prism. + # + # source://prism//lib/prism/translation/parser.rb#25 + def message; end +end + +# source://prism//lib/prism/translation/parser.rb#34 +Prism::Translation::Parser::Racc_debug_parser = T.let(T.unsafe(nil), FalseClass) + +# This class provides a compatibility layer between prism and Ripper. It +# functions by parsing the entire tree first and then walking it and +# executing each of the Ripper callbacks as it goes. To use this class, you +# treat `Prism::Translation::Ripper` effectively as you would treat the +# `Ripper` class. +# +# Note that this class will serve the most common use cases, but Ripper's +# API is extensive and undocumented. It relies on reporting the state of the +# parser at any given time. We do our best to replicate that here, but +# because it is a different architecture it is not possible to perfectly +# replicate the behavior of Ripper. +# +# The main known difference is that we may omit dispatching some events in +# some cases. This impacts the following events: +# +# - on_assign_error +# - on_comma +# - on_ignored_nl +# - on_ignored_sp +# - on_kw +# - on_label_end +# - on_lbrace +# - on_lbracket +# - on_lparen +# - on_nl +# - on_op +# - on_operator_ambiguous +# - on_rbrace +# - on_rbracket +# - on_rparen +# - on_semicolon +# - on_sp +# - on_symbeg +# - on_tstring_beg +# - on_tstring_end +# +# source://prism//lib/prism/translation/ripper.rb#43 +class Prism::Translation::Ripper < ::Prism::Compiler + # Create a new Translation::Ripper object with the given source. + # + # @return [Ripper] a new instance of Ripper + # + # source://prism//lib/prism/translation/ripper.rb#444 + def initialize(source, filename = T.unsafe(nil), lineno = T.unsafe(nil)); end + + # The current column number of the parser. + # + # source://prism//lib/prism/translation/ripper.rb#441 + def column; end + + # True if the parser encountered an error during parsing. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/ripper.rb#457 + sig { returns(T::Boolean) } + def error?; end + + # The filename of the source being parsed. + # + # source://prism//lib/prism/translation/ripper.rb#435 + def filename; end + + # The current line number of the parser. + # + # source://prism//lib/prism/translation/ripper.rb#438 + def lineno; end + + # Parse the source and return the result. + # + # source://prism//lib/prism/translation/ripper.rb#462 + sig { returns(T.untyped) } + def parse; end + + # The source that is being parsed. + # + # source://prism//lib/prism/translation/ripper.rb#432 + def source; end + + # alias $foo $bar + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#561 + def visit_alias_global_variable_node(node); end + + # alias foo bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#551 + def visit_alias_method_node(node); end + + # foo => bar | baz + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#585 + def visit_alternation_pattern_node(node); end + + # a and b + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#605 + def visit_and_node(node); end + + # foo(bar) + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#796 + def visit_arguments_node(node); end + + # [] + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#615 + def visit_array_node(node); end + + # foo => [bar] + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#775 + def visit_array_pattern_node(node); end + + # { a: 1 } + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#803 + def visit_assoc_node(node); end + + # def foo(**); bar(**); end + # ^^ + # + # { **foo } + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#816 + def visit_assoc_splat_node(node); end + + # $+ + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#825 + def visit_back_reference_read_node(node); end + + # begin end + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#832 + def visit_begin_node(node); end + + # foo(&bar) + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#896 + def visit_block_argument_node(node); end + + # foo { |; bar| } + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#902 + def visit_block_local_variable_node(node); end + + # Visit a BlockNode. + # + # source://prism//lib/prism/translation/ripper.rb#908 + def visit_block_node(node); end + + # def foo(&bar); end + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#944 + def visit_block_parameter_node(node); end + + # A block's parameters. + # + # source://prism//lib/prism/translation/ripper.rb#958 + def visit_block_parameters_node(node); end + + # break + # ^^^^^ + # + # break foo + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#982 + def visit_break_node(node); end + + # foo.bar &&= baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1194 + def visit_call_and_write_node(node); end + + # foo + # ^^^ + # + # foo.bar + # ^^^^^^^ + # + # foo.bar() {} + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1002 + def visit_call_node(node); end + + # foo.bar += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1172 + def visit_call_operator_write_node(node); end + + # foo.bar ||= baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1216 + def visit_call_or_write_node(node); end + + # foo.bar, = 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1238 + def visit_call_target_node(node); end + + # foo => bar => baz + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1263 + def visit_capture_pattern_node(node); end + + # case foo; in bar; end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1286 + def visit_case_match_node(node); end + + # case foo; when bar; end + # ^^^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1273 + def visit_case_node(node); end + + # class Foo; end + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1299 + def visit_class_node(node); end + + # @@foo &&= bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1352 + def visit_class_variable_and_write_node(node); end + + # @@foo += bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1338 + def visit_class_variable_operator_write_node(node); end + + # @@foo ||= bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1366 + def visit_class_variable_or_write_node(node); end + + # @@foo + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1317 + def visit_class_variable_read_node(node); end + + # @@foo, = bar + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1380 + def visit_class_variable_target_node(node); end + + # @@foo = 1 + # ^^^^^^^^^ + # + # @@foo, @@bar = 1 + # ^^^^^ ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1327 + def visit_class_variable_write_node(node); end + + # Foo &&= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1422 + def visit_constant_and_write_node(node); end + + # Foo += bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1408 + def visit_constant_operator_write_node(node); end + + # Foo ||= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1436 + def visit_constant_or_write_node(node); end + + # Foo::Bar &&= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1523 + def visit_constant_path_and_write_node(node); end + + # Foo::Bar + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1457 + def visit_constant_path_node(node); end + + # Foo::Bar += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1509 + def visit_constant_path_operator_write_node(node); end + + # Foo::Bar ||= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1537 + def visit_constant_path_or_write_node(node); end + + # Foo::Bar, = baz + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1551 + def visit_constant_path_target_node(node); end + + # Foo::Bar = 1 + # ^^^^^^^^^^^^ + # + # Foo::Foo, Bar::Bar = 1 + # ^^^^^^^^ ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1480 + def visit_constant_path_write_node(node); end + + # Foo + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1387 + def visit_constant_read_node(node); end + + # Foo, = bar + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1450 + def visit_constant_target_node(node); end + + # Foo = 1 + # ^^^^^^^ + # + # Foo, Bar = 1 + # ^^^ ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1397 + def visit_constant_write_node(node); end + + # def foo; end + # ^^^^^^^^^^^^ + # + # def self.foo; end + # ^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1560 + def visit_def_node(node); end + + # defined? a + # ^^^^^^^^^^ + # + # defined?(a) + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1607 + def visit_defined_node(node); end + + # if foo then bar else baz end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1614 + def visit_else_node(node); end + + # "foo #{bar}" + # ^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1630 + def visit_embedded_statements_node(node); end + + # "foo #@bar" + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1651 + def visit_embedded_variable_node(node); end + + # Visit an EnsureNode node. + # + # source://prism//lib/prism/translation/ripper.rb#1662 + def visit_ensure_node(node); end + + # false + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1680 + def visit_false_node(node); end + + # foo => [*, bar, *] + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1687 + def visit_find_pattern_node(node); end + + # if foo .. bar; end + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1712 + def visit_flip_flop_node(node); end + + # 1.0 + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1726 + def visit_float_node(node); end + + # for foo in bar do end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1732 + def visit_for_node(node); end + + # def foo(...); bar(...); end + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1749 + def visit_forwarding_arguments_node(node); end + + # def foo(...); end + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1756 + def visit_forwarding_parameter_node(node); end + + # super + # ^^^^^ + # + # super {} + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1766 + def visit_forwarding_super_node(node); end + + # $foo &&= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1815 + def visit_global_variable_and_write_node(node); end + + # $foo += bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1801 + def visit_global_variable_operator_write_node(node); end + + # $foo ||= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1829 + def visit_global_variable_or_write_node(node); end + + # $foo + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1780 + def visit_global_variable_read_node(node); end + + # $foo, = bar + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1843 + def visit_global_variable_target_node(node); end + + # $foo = 1 + # ^^^^^^^^ + # + # $foo, $bar = 1 + # ^^^^ ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1790 + def visit_global_variable_write_node(node); end + + # {} + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#1850 + def visit_hash_node(node); end + + # foo => {} + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#1865 + def visit_hash_pattern_node(node); end + + # if foo then bar end + # ^^^^^^^^^^^^^^^^^^^ + # + # bar if foo + # ^^^^^^^^^^ + # + # foo ? bar : baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1907 + def visit_if_node(node); end + + # 1i + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#1943 + def visit_imaginary_node(node); end + + # { foo: } + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1949 + def visit_implicit_node(node); end + + # foo { |bar,| } + # ^ + # + # source://prism//lib/prism/translation/ripper.rb#1954 + def visit_implicit_rest_node(node); end + + # case foo; in bar; end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1961 + def visit_in_node(node); end + + # foo[bar] &&= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1996 + def visit_index_and_write_node(node); end + + # foo[bar] += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#1979 + def visit_index_operator_write_node(node); end + + # foo[bar] ||= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2013 + def visit_index_or_write_node(node); end + + # foo[bar], = 1 + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2030 + def visit_index_target_node(node); end + + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2072 + def visit_instance_variable_and_write_node(node); end + + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2058 + def visit_instance_variable_operator_write_node(node); end + + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2086 + def visit_instance_variable_or_write_node(node); end + + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2040 + def visit_instance_variable_read_node(node); end + + # @foo, = bar + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2100 + def visit_instance_variable_target_node(node); end + + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2047 + def visit_instance_variable_write_node(node); end + + # 1 + # ^ + # + # source://prism//lib/prism/translation/ripper.rb#2107 + def visit_integer_node(node); end + + # if /foo #{bar}/ then end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2113 + def visit_interpolated_match_last_line_node(node); end + + # /foo #{bar}/ + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2132 + def visit_interpolated_regular_expression_node(node); end + + # "foo #{bar}" + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2151 + def visit_interpolated_string_node(node); end + + # :"foo #{bar}" + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2179 + def visit_interpolated_symbol_node(node); end + + # `foo #{bar}` + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2192 + def visit_interpolated_x_string_node(node); end + + # -> { it } + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#2222 + def visit_it_local_variable_read_node(node); end + + # -> { it } + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2229 + def visit_it_parameters_node(node); end + + # foo(bar: baz) + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2234 + def visit_keyword_hash_node(node); end + + # def foo(**bar); end + # ^^^^^ + # + # def foo(**); end + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#2246 + def visit_keyword_rest_parameter_node(node); end + + # -> {} + # + # source://prism//lib/prism/translation/ripper.rb#2260 + def visit_lambda_node(node); end + + # foo &&= bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2352 + def visit_local_variable_and_write_node(node); end + + # foo += bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2338 + def visit_local_variable_operator_write_node(node); end + + # foo ||= bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2366 + def visit_local_variable_or_write_node(node); end + + # foo + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2320 + def visit_local_variable_read_node(node); end + + # foo, = bar + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2380 + def visit_local_variable_target_node(node); end + + # foo = 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2327 + def visit_local_variable_write_node(node); end + + # if /foo/ then end + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2387 + def visit_match_last_line_node(node); end + + # foo in bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2402 + def visit_match_predicate_node(node); end + + # foo => bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2411 + def visit_match_required_node(node); end + + # /(?foo)/ =~ bar + # ^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2420 + def visit_match_write_node(node); end + + # A node that is missing from the syntax tree. This is only used in the + # case of a syntax error. + # + # source://prism//lib/prism/translation/ripper.rb#2426 + def visit_missing_node(node); end + + # module Foo; end + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2432 + def visit_module_node(node); end + + # (foo, bar), bar = qux + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2449 + def visit_multi_target_node(node); end + + # foo, bar = baz + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2503 + def visit_multi_write_node(node); end + + # next + # ^^^^ + # + # next foo + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2523 + def visit_next_node(node); end + + # nil + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2537 + def visit_nil_node(node); end + + # def foo(**nil); end + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2544 + def visit_no_keywords_parameter_node(node); end + + # -> { _1 + _2 } + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2553 + def visit_numbered_parameters_node(node); end + + # $1 + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#2558 + def visit_numbered_reference_read_node(node); end + + # def foo(bar: baz); end + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2565 + def visit_optional_keyword_parameter_node(node); end + + # def foo(bar = 1); end + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2575 + def visit_optional_parameter_node(node); end + + # a or b + # ^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2585 + def visit_or_node(node); end + + # def foo(bar, *baz); end + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2595 + def visit_parameters_node(node); end + + # () + # ^^ + # + # (1) + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2622 + def visit_parentheses_node(node); end + + # foo => ^(bar) + # ^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2636 + def visit_pinned_expression_node(node); end + + # foo = 1 and bar => ^foo + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2645 + def visit_pinned_variable_node(node); end + + # END {} + # ^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2651 + def visit_post_execution_node(node); end + + # BEGIN {} + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2666 + def visit_pre_execution_node(node); end + + # The top-level program node. + # + # source://prism//lib/prism/translation/ripper.rb#2680 + def visit_program_node(node); end + + # 0..5 + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2691 + def visit_range_node(node); end + + # 1r + # ^^ + # + # source://prism//lib/prism/translation/ripper.rb#2705 + def visit_rational_node(node); end + + # redo + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2711 + def visit_redo_node(node); end + + # /foo/ + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2718 + def visit_regular_expression_node(node); end + + # def foo(bar:); end + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2740 + def visit_required_keyword_parameter_node(node); end + + # def foo(bar); end + # ^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2747 + def visit_required_parameter_node(node); end + + # foo rescue bar + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2754 + def visit_rescue_modifier_node(node); end + + # begin; rescue; end + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2764 + def visit_rescue_node(node); end + + # def foo(*bar); end + # ^^^^ + # + # def foo(*); end + # ^ + # + # source://prism//lib/prism/translation/ripper.rb#2822 + def visit_rest_parameter_node(node); end + + # retry + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2834 + def visit_retry_node(node); end + + # return + # ^^^^^^ + # + # return 1 + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2844 + def visit_return_node(node); end + + # self + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2858 + def visit_self_node(node); end + + # A shareable constant. + # + # source://prism//lib/prism/translation/ripper.rb#2864 + def visit_shareable_constant_node(node); end + + # class << self; end + # ^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2870 + def visit_singleton_class_node(node); end + + # __ENCODING__ + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2880 + def visit_source_encoding_node(node); end + + # __FILE__ + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2887 + def visit_source_file_node(node); end + + # __LINE__ + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2894 + def visit_source_line_node(node); end + + # foo(*bar) + # ^^^^ + # + # def foo((bar, *baz)); end + # ^^^^ + # + # def foo(*); bar(*); end + # ^ + # + # source://prism//lib/prism/translation/ripper.rb#2907 + def visit_splat_node(node); end + + # A list of statements. + # + # source://prism//lib/prism/translation/ripper.rb#2912 + def visit_statements_node(node); end + + # "foo" + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#2929 + def visit_string_node(node); end + + # super(foo) + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3061 + def visit_super_node(node); end + + # :foo + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3082 + def visit_symbol_node(node); end + + # true + # ^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3106 + def visit_true_node(node); end + + # undef foo + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3113 + def visit_undef_node(node); end + + # unless foo; bar end + # ^^^^^^^^^^^^^^^^^^^ + # + # bar unless foo + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3125 + def visit_unless_node(node); end + + # until foo; bar end + # ^^^^^^^^^^^^^^^^^ + # + # bar until foo + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3153 + def visit_until_node(node); end + + # case foo; when bar; end + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3177 + def visit_when_node(node); end + + # while foo; bar end + # ^^^^^^^^^^^^^^^^^^ + # + # bar while foo + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3198 + def visit_while_node(node); end + + # `foo` + # ^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3222 + def visit_x_string_node(node); end + + # yield + # ^^^^^ + # + # yield 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ripper.rb#3245 + def visit_yield_node(node); end + + private + + # :stopdoc: + # + # source://prism//lib/prism/translation/ripper.rb#3389 + def _dispatch_0; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def _dispatch_1(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def _dispatch_2(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def _dispatch_3(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3393 + def _dispatch_4(_, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3394 + def _dispatch_5(_, _, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3395 + def _dispatch_7(_, _, _, _, _, _, _); end + + # This method is responsible for updating lineno and column information + # to reflect the current node. + # + # This method could be drastically improved with some caching on the start + # of every line, but for now it's good enough. + # + # source://prism//lib/prism/translation/ripper.rb#3379 + def bounds(location); end + + # Returns true if the given node is a command node. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/ripper.rb#1163 + def command?(node); end + + # This method is called when the parser found syntax error. + # + # source://prism//lib/prism/translation/ripper.rb#3417 + def compile_error(msg); end + + # This method is provided by the Ripper C extension. It is called when a + # string needs to be dedented because of a tilde heredoc. It is expected + # that it will modify the string in place and return the number of bytes + # that were removed. + # + # source://prism//lib/prism/translation/ripper.rb#3432 + def dedent_string(string, width); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_BEGIN(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_CHAR(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_END(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on___end__(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_alias(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_alias_error(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_aref(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_aref_field(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_arg_ambiguous(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_arg_paren(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_args_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_args_add_block(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_args_add_star(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_args_forward; end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_args_new; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_array(_); end + + # source://prism//lib/prism/translation/ripper.rb#3393 + def on_aryptn(_, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_assign(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_assign_error(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_assoc_new(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_assoc_splat(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_assoclist_from_args(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_backref(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_backtick(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_bare_assoc_hash(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_begin(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_binary(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_block_var(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_blockarg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3393 + def on_bodystmt(_, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_brace_block(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_break(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_call(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_case(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_class(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_class_name_error(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_comma(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_command(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3393 + def on_command_call(_, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_comment(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_const(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_const_path_field(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_const_path_ref(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_const_ref(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_cvar(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_def(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_defined(_); end + + # source://prism//lib/prism/translation/ripper.rb#3394 + def on_defs(_, _, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_do_block(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_dot2(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_dot3(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_dyna_symbol(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_else(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_elsif(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_embdoc(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_embdoc_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_embdoc_end(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_embexpr_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_embexpr_end(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_embvar(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_ensure(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_excessed_comma; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_fcall(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_field(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_float(_); end + + # source://prism//lib/prism/translation/ripper.rb#3393 + def on_fndptn(_, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_for(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_gvar(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_hash(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_heredoc_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_heredoc_dedent(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_heredoc_end(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_hshptn(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_ident(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_if(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_if_mod(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_ifop(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_ignored_nl(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_ignored_sp(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_imaginary(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_in(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_int(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_ivar(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_kw(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_kwrest_param(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_label(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_label_end(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_lambda(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_lbrace(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_lbracket(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_lparen(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_magic_comment(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_massign(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_method_add_arg(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_method_add_block(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_mlhs_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_mlhs_add_post(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_mlhs_add_star(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_mlhs_new; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_mlhs_paren(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_module(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_mrhs_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_mrhs_add_star(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_mrhs_new; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_mrhs_new_from_args(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_next(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_nl(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_nokw_param(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_op(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_opassign(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_operator_ambiguous(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_param_error(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3395 + def on_params(_, _, _, _, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_paren(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_parse_error(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_period(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_program(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_qsymbols_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_qsymbols_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_qsymbols_new; end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_qwords_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_qwords_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_qwords_new; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_rational(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_rbrace(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_rbracket(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_redo; end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_regexp_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_regexp_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_regexp_end(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_regexp_literal(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_regexp_new; end + + # source://prism//lib/prism/translation/ripper.rb#3393 + def on_rescue(_, _, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_rescue_mod(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_rest_param(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_retry; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_return(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_return0; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_rparen(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_sclass(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_semicolon(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_sp(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_stmts_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_stmts_new; end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_string_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_string_concat(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_string_content; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_string_dvar(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_string_embexpr(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_string_literal(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_super(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_symbeg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_symbol(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_symbol_literal(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_symbols_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_symbols_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_symbols_new; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_tlambda(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_tlambeg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_top_const_field(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_top_const_ref(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_tstring_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_tstring_content(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_tstring_end(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_unary(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_undef(_); end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_unless(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_unless_mod(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_until(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_until_mod(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_var_alias(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_var_field(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_var_ref(_); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_vcall(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_void_stmt; end + + # source://prism//lib/prism/translation/ripper.rb#3392 + def on_when(_, _, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_while(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_while_mod(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_word_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_word_new; end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_words_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_words_beg(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_words_new; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_words_sep(_); end + + # source://prism//lib/prism/translation/ripper.rb#3391 + def on_xstring_add(_, _); end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_xstring_literal(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_xstring_new; end + + # source://prism//lib/prism/translation/ripper.rb#3390 + def on_yield(_); end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_yield0; end + + # source://prism//lib/prism/translation/ripper.rb#3389 + def on_zsuper; end + + # Lazily initialize the parse result. + # + # source://prism//lib/prism/translation/ripper.rb#3271 + def result; end + + # Returns true if there is a comma between the two locations. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/ripper.rb#3284 + def trailing_comma?(left, right); end + + # Visit one side of an alias global variable node. + # + # source://prism//lib/prism/translation/ripper.rb#570 + def visit_alias_global_variable_node_value(node); end + + # Visit a list of elements, like the elements of an array or arguments. + # + # source://prism//lib/prism/translation/ripper.rb#756 + def visit_arguments(elements); end + + # Visit the clauses of a begin node to form an on_bodystmt call. + # + # source://prism//lib/prism/translation/ripper.rb#840 + def visit_begin_node_clauses(location, node, allow_newline); end + + # Visit the body of a structure that can have either a set of statements + # or statements wrapped in rescue/else/ensure. + # + # source://prism//lib/prism/translation/ripper.rb#875 + def visit_body_node(location, node, allow_newline = T.unsafe(nil)); end + + # Visit the arguments and block of a call node and return the arguments + # and block as they should be used. + # + # source://prism//lib/prism/translation/ripper.rb#1136 + def visit_call_node_arguments(arguments_node, block_node, trailing_comma); end + + # Visit a constant path that is part of a write node. + # + # source://prism//lib/prism/translation/ripper.rb#1489 + def visit_constant_path_write_node_target(node); end + + # Visit a destructured positional parameter node. + # + # source://prism//lib/prism/translation/ripper.rb#2609 + def visit_destructured_parameter_node(node); end + + # Visit a string that is expressed using a <<~ heredoc. + # + # source://prism//lib/prism/translation/ripper.rb#2980 + def visit_heredoc_node(parts, base); end + + # Ripper gives back the escaped string content but strips out the common + # leading whitespace. Prism gives back the unescaped string content and + # a location for the escaped string content. Unfortunately these don't + # work well together, so here we need to re-derive the common leading + # whitespace. + # + # source://prism//lib/prism/translation/ripper.rb#2955 + def visit_heredoc_node_whitespace(parts); end + + # Visit a heredoc node that is representing a string. + # + # source://prism//lib/prism/translation/ripper.rb#3026 + def visit_heredoc_string_node(node); end + + # Visit a heredoc node that is representing an xstring. + # + # source://prism//lib/prism/translation/ripper.rb#3043 + def visit_heredoc_x_string_node(node); end + + # Visit the targets of a multi-target node. + # + # source://prism//lib/prism/translation/ripper.rb#2462 + def visit_multi_target_node_targets(lefts, rest, rights, skippable); end + + # Visit a node that represents a number. We need to explicitly handle the + # unary - operator. + # + # source://prism//lib/prism/translation/ripper.rb#3323 + def visit_number_node(node); end + + # Visit a pattern within a pattern match. This is used to bypass the + # parenthesis node that can be used to wrap patterns. + # + # source://prism//lib/prism/translation/ripper.rb#595 + def visit_pattern_node(node); end + + # Visit the list of statements of a statements node. We support nil + # statements in the list. This would normally not be allowed by the + # structure of the prism parse tree, but we manually add them here so that + # we can mirror Ripper's void stmt. + # + # source://prism//lib/prism/translation/ripper.rb#2921 + def visit_statements_node_body(body); end + + # Visit an individual part of a string-like node. + # + # source://prism//lib/prism/translation/ripper.rb#2211 + def visit_string_content(part); end + + # Visit the string content of a particular node. This method is used to + # split into the various token types. + # + # source://prism//lib/prism/translation/ripper.rb#3296 + def visit_token(token, allow_keywords = T.unsafe(nil)); end + + # Dispatch a words_sep event that contains the space between the elements + # of list literals. + # + # source://prism//lib/prism/translation/ripper.rb#745 + def visit_words_sep(opening_loc, previous, current); end + + # Visit a node that represents a write value. This is used to handle the + # special case of an implicit array that is generated without brackets. + # + # source://prism//lib/prism/translation/ripper.rb#3341 + def visit_write_value(node); end + + # Returns true if there is a semicolon between the two locations. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/ripper.rb#3289 + def void_stmt?(left, right, allow_newline); end + + # This method is called when weak warning is produced by the parser. + # +fmt+ and +args+ is printf style. + # + # source://prism//lib/prism/translation/ripper.rb#3408 + def warn(fmt, *args); end + + # This method is called when strong warning is produced by the parser. + # +fmt+ and +args+ is printf style. + # + # source://prism//lib/prism/translation/ripper.rb#3413 + def warning(fmt, *args); end + + class << self + # Tokenizes the Ruby program and returns an array of an array, + # which is formatted like + # [[lineno, column], type, token, state]. + # The +filename+ argument is mostly ignored. + # By default, this method does not handle syntax errors in +src+, + # use the +raise_errors+ keyword to raise a SyntaxError for an error in +src+. + # + # require "ripper" + # require "pp" + # + # pp Ripper.lex("def m(a) nil end") + # #=> [[[1, 0], :on_kw, "def", FNAME ], + # [[1, 3], :on_sp, " ", FNAME ], + # [[1, 4], :on_ident, "m", ENDFN ], + # [[1, 5], :on_lparen, "(", BEG|LABEL], + # [[1, 6], :on_ident, "a", ARG ], + # [[1, 7], :on_rparen, ")", ENDFN ], + # [[1, 8], :on_sp, " ", BEG ], + # [[1, 9], :on_kw, "nil", END ], + # [[1, 12], :on_sp, " ", END ], + # [[1, 13], :on_kw, "end", END ]] + # + # source://prism//lib/prism/translation/ripper.rb#72 + def lex(src, filename = T.unsafe(nil), lineno = T.unsafe(nil), raise_errors: T.unsafe(nil)); end + + # Parses the given Ruby program read from +src+. + # +src+ must be a String or an IO or a object with a #gets method. + # + # source://prism//lib/prism/translation/ripper.rb#46 + def parse(src, filename = T.unsafe(nil), lineno = T.unsafe(nil)); end + + # Parses +src+ and create S-exp tree. + # Returns more readable tree rather than Ripper.sexp_raw. + # This method is mainly for developer use. + # The +filename+ argument is mostly ignored. + # By default, this method does not handle syntax errors in +src+, + # returning +nil+ in such cases. Use the +raise_errors+ keyword + # to raise a SyntaxError for an error in +src+. + # + # require "ripper" + # require "pp" + # + # pp Ripper.sexp("def m(a) nil end") + # #=> [:program, + # [[:def, + # [:@ident, "m", [1, 4]], + # [:paren, [:params, [[:@ident, "a", [1, 6]]], nil, nil, nil, nil, nil, nil]], + # [:bodystmt, [[:var_ref, [:@kw, "nil", [1, 9]]]], nil, nil, nil]]]] + # + # source://prism//lib/prism/translation/ripper.rb#381 + def sexp(src, filename = T.unsafe(nil), lineno = T.unsafe(nil), raise_errors: T.unsafe(nil)); end + + # Parses +src+ and create S-exp tree. + # This method is mainly for developer use. + # The +filename+ argument is mostly ignored. + # By default, this method does not handle syntax errors in +src+, + # returning +nil+ in such cases. Use the +raise_errors+ keyword + # to raise a SyntaxError for an error in +src+. + # + # require "ripper" + # require "pp" + # + # pp Ripper.sexp_raw("def m(a) nil end") + # #=> [:program, + # [:stmts_add, + # [:stmts_new], + # [:def, + # [:@ident, "m", [1, 4]], + # [:paren, [:params, [[:@ident, "a", [1, 6]]], nil, nil, nil]], + # [:bodystmt, + # [:stmts_add, [:stmts_new], [:var_ref, [:@kw, "nil", [1, 9]]]], + # nil, + # nil, + # nil]]]] + # + # source://prism//lib/prism/translation/ripper.rb#416 + def sexp_raw(src, filename = T.unsafe(nil), lineno = T.unsafe(nil), raise_errors: T.unsafe(nil)); end + end +end + +# A list of all of the Ruby binary operators. +# +# source://prism//lib/prism/translation/ripper.rb#337 +Prism::Translation::Ripper::BINARY_OPERATORS = T.let(T.unsafe(nil), Array) + +# This array contains name of all ripper events. +# +# source://prism//lib/prism/translation/ripper.rb#289 +Prism::Translation::Ripper::EVENTS = T.let(T.unsafe(nil), Array) + +# A list of all of the Ruby keywords. +# +# source://prism//lib/prism/translation/ripper.rb#292 +Prism::Translation::Ripper::KEYWORDS = T.let(T.unsafe(nil), Array) + +# This array contains name of parser events. +# +# source://prism//lib/prism/translation/ripper.rb#283 +Prism::Translation::Ripper::PARSER_EVENTS = T.let(T.unsafe(nil), Array) + +# This contains a table of all of the parser events and their +# corresponding arity. +# +# source://prism//lib/prism/translation/ripper.rb#84 +Prism::Translation::Ripper::PARSER_EVENT_TABLE = T.let(T.unsafe(nil), Hash) + +# This array contains name of scanner events. +# +# source://prism//lib/prism/translation/ripper.rb#286 +Prism::Translation::Ripper::SCANNER_EVENTS = T.let(T.unsafe(nil), Array) + +# This contains a table of all of the scanner events and their +# corresponding arity. +# +# source://prism//lib/prism/translation/ripper.rb#227 +Prism::Translation::Ripper::SCANNER_EVENT_TABLE = T.let(T.unsafe(nil), Hash) + +# This class mirrors the ::Ripper::SexpBuilder subclass of ::Ripper that +# returns the arrays of [type, *children]. +# +# source://prism//lib/prism/translation/ripper/sexp.rb#10 +class Prism::Translation::Ripper::SexpBuilder < ::Prism::Translation::Ripper + # :stopdoc: + # + # source://prism//lib/prism/translation/ripper/sexp.rb#13 + def error; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_BEGIN(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_CHAR(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_END(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on___end__(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_alias(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_alias_error(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_aref(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_aref_field(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_arg_ambiguous(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_arg_paren(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_args_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_args_add_block(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_args_add_star(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_args_forward(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_args_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_array(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_aryptn(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_assign(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_assign_error(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_assoc_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_assoc_splat(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_assoclist_from_args(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_backref(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_backtick(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_bare_assoc_hash(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_begin(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_binary(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_block_var(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_blockarg(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_bodystmt(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_brace_block(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_break(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_call(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_case(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_class(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_class_name_error(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_comma(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_command(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_command_call(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_comment(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_const(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_const_path_field(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_const_path_ref(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_const_ref(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_cvar(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_def(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_defined(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_defs(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_do_block(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_dot2(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_dot3(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_dyna_symbol(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_else(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_elsif(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_embdoc(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_embdoc_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_embdoc_end(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_embexpr_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_embexpr_end(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_embvar(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_ensure(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_excessed_comma(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_fcall(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_field(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_float(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_fndptn(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_for(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_gvar(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_hash(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_heredoc_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_heredoc_end(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_hshptn(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_ident(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_if(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_if_mod(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_ifop(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_ignored_nl(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_ignored_sp(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_imaginary(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_in(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_int(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_ivar(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_kw(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_kwrest_param(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_label(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_label_end(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_lambda(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_lbrace(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_lbracket(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_lparen(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_magic_comment(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_massign(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_method_add_arg(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_method_add_block(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mlhs_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mlhs_add_post(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mlhs_add_star(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mlhs_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mlhs_paren(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_module(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mrhs_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mrhs_add_star(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mrhs_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_mrhs_new_from_args(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_next(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_nl(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_nokw_param(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_op(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_opassign(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_operator_ambiguous(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_param_error(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_params(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_paren(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_period(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_program(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_qsymbols_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_qsymbols_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_qsymbols_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_qwords_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_qwords_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_qwords_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_rational(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_rbrace(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_rbracket(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_redo(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_regexp_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_regexp_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_regexp_end(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_regexp_literal(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_regexp_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_rescue(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_rescue_mod(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_rest_param(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_retry(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_return(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_return0(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_rparen(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_sclass(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_semicolon(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_sp(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_stmts_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_stmts_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_string_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_string_concat(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_string_content(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_string_dvar(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_string_embexpr(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_string_literal(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_super(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_symbeg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_symbol(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_symbol_literal(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_symbols_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_symbols_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_symbols_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_tlambda(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_tlambeg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_top_const_field(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_top_const_ref(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_tstring_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_tstring_content(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_tstring_end(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_unary(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_undef(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_unless(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_unless_mod(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_until(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_until_mod(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_var_alias(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_var_field(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_var_ref(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_vcall(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_void_stmt(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_when(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_while(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_while_mod(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_word_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_word_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_words_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_words_beg(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_words_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#55 + def on_words_sep(tok); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_xstring_add(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_xstring_literal(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_xstring_new(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_yield(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_yield0(*args); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#47 + def on_zsuper(*args); end + + private + + # source://prism//lib/prism/translation/ripper/sexp.rb#61 + def compile_error(mesg); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#17 + def dedent_element(e, width); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#61 + def on_error(mesg); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#24 + def on_heredoc_dedent(val, width); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#61 + def on_parse_error(mesg); end +end + +# This class mirrors the ::Ripper::SexpBuilderPP subclass of ::Ripper that +# returns the same values as ::Ripper::SexpBuilder except with a couple of +# niceties that flatten linked lists into arrays. +# +# source://prism//lib/prism/translation/ripper/sexp.rb#74 +class Prism::Translation::Ripper::SexpBuilderPP < ::Prism::Translation::Ripper::SexpBuilder + private + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def _dispatch_event_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def _dispatch_event_push(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_args_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_args_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#79 + def on_heredoc_dedent(val, width); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_mlhs_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#109 + def on_mlhs_add_post(list, post); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#105 + def on_mlhs_add_star(list, star); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_mlhs_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#101 + def on_mlhs_paren(list); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_mrhs_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_mrhs_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_qsymbols_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_qsymbols_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_qwords_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_qwords_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_regexp_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_regexp_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_stmts_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_stmts_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_string_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_symbols_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_symbols_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_word_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_word_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_words_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_words_new; end + + # source://prism//lib/prism/translation/ripper/sexp.rb#96 + def on_xstring_add(list, item); end + + # source://prism//lib/prism/translation/ripper/sexp.rb#92 + def on_xstring_new; end +end + +# This module is the entry-point for converting a prism syntax tree into the +# seattlerb/ruby_parser gem's syntax tree. +# +# source://prism//lib/prism/translation/ruby_parser.rb#14 +class Prism::Translation::RubyParser + # Parse the given source and translate it into the seattlerb/ruby_parser + # gem's Sexp format. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1556 + def parse(source, filepath = T.unsafe(nil)); end + + # Parse the given file and translate it into the seattlerb/ruby_parser + # gem's Sexp format. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1562 + def parse_file(filepath); end + + private + + # Translate the given parse result and filepath into the + # seattlerb/ruby_parser gem's Sexp format. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1584 + def translate(result, filepath); end + + class << self + # Parse the given source and translate it into the seattlerb/ruby_parser + # gem's Sexp format. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1569 + def parse(source, filepath = T.unsafe(nil)); end + + # Parse the given file and translate it into the seattlerb/ruby_parser + # gem's Sexp format. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1575 + def parse_file(filepath); end + end +end + +# A prism visitor that builds Sexp objects. +# +# source://prism//lib/prism/translation/ruby_parser.rb#16 +class Prism::Translation::RubyParser::Compiler < ::Prism::Compiler + # Initialize a new compiler with the given file name. + # + # @return [Compiler] a new instance of Compiler + # + # source://prism//lib/prism/translation/ruby_parser.rb#31 + def initialize(file, in_def: T.unsafe(nil), in_pattern: T.unsafe(nil)); end + + # This is the name of the file that we are compiling. We set it on every + # Sexp object that is generated, and also use it to compile __FILE__ + # nodes. + # + # source://prism//lib/prism/translation/ruby_parser.rb#20 + def file; end + + # Class variables will change their type based on if they are inside of + # a method definition or not, so we need to track that state. + # + # source://prism//lib/prism/translation/ruby_parser.rb#24 + def in_def; end + + # Some nodes will change their representation if they are inside of a + # pattern, so we need to track that state. + # + # source://prism//lib/prism/translation/ruby_parser.rb#28 + def in_pattern; end + + # alias $foo $bar + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#45 + def visit_alias_global_variable_node(node); end + + # alias foo bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#39 + def visit_alias_method_node(node); end + + # foo => bar | baz + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#51 + def visit_alternation_pattern_node(node); end + + # a and b + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#57 + def visit_and_node(node); end + + # foo(bar) + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#96 + def visit_arguments_node(node); end + + # [] + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#63 + def visit_array_node(node); end + + # foo => [bar] + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#73 + def visit_array_pattern_node(node); end + + # { a: 1 } + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#102 + def visit_assoc_node(node); end + + # def foo(**); bar(**); end + # ^^ + # + # { **foo } + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#111 + def visit_assoc_splat_node(node); end + + # $+ + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#121 + def visit_back_reference_read_node(node); end + + # begin end + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#127 + def visit_begin_node(node); end + + # foo(&bar) + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#160 + def visit_block_argument_node(node); end + + # foo { |; bar| } + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#168 + def visit_block_local_variable_node(node); end + + # A block on a keyword or method call. + # + # source://prism//lib/prism/translation/ruby_parser.rb#173 + def visit_block_node(node); end + + # def foo(&bar); end + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#179 + def visit_block_parameter_node(node); end + + # A block's parameters. + # + # source://prism//lib/prism/translation/ruby_parser.rb#184 + def visit_block_parameters_node(node); end + + # break + # ^^^^^ + # + # break foo + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#224 + def visit_break_node(node); end + + # foo.bar &&= baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#287 + def visit_call_and_write_node(node); end + + # foo + # ^^^ + # + # foo.bar + # ^^^^^^^ + # + # foo.bar() {} + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#242 + def visit_call_node(node); end + + # foo.bar += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#277 + def visit_call_operator_write_node(node); end + + # foo.bar ||= baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#297 + def visit_call_or_write_node(node); end + + # foo.bar, = 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#320 + def visit_call_target_node(node); end + + # foo => bar => baz + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#326 + def visit_capture_pattern_node(node); end + + # case foo; in bar; end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#338 + def visit_case_match_node(node); end + + # case foo; when bar; end + # ^^^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#332 + def visit_case_node(node); end + + # class Foo; end + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#344 + def visit_class_node(node); end + + # @@foo &&= bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#385 + def visit_class_variable_and_write_node(node); end + + # @@foo += bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#379 + def visit_class_variable_operator_write_node(node); end + + # @@foo ||= bar + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#391 + def visit_class_variable_or_write_node(node); end + + # @@foo + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#364 + def visit_class_variable_read_node(node); end + + # @@foo, = bar + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#397 + def visit_class_variable_target_node(node); end + + # @@foo = 1 + # ^^^^^^^^^ + # + # @@foo, @@bar = 1 + # ^^^^^ ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#373 + def visit_class_variable_write_node(node); end + + # Foo &&= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#430 + def visit_constant_and_write_node(node); end + + # Foo += bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#424 + def visit_constant_operator_write_node(node); end + + # Foo ||= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#436 + def visit_constant_or_write_node(node); end + + # Foo::Bar &&= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#473 + def visit_constant_path_and_write_node(node); end + + # Foo::Bar + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#448 + def visit_constant_path_node(node); end + + # Foo::Bar += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#467 + def visit_constant_path_operator_write_node(node); end + + # Foo::Bar ||= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#479 + def visit_constant_path_or_write_node(node); end + + # Foo::Bar, = baz + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#485 + def visit_constant_path_target_node(node); end + + # Foo::Bar = 1 + # ^^^^^^^^^^^^ + # + # Foo::Foo, Bar::Bar = 1 + # ^^^^^^^^ ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#461 + def visit_constant_path_write_node(node); end + + # Foo + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#409 + def visit_constant_read_node(node); end + + # Foo, = bar + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#442 + def visit_constant_target_node(node); end + + # Foo = 1 + # ^^^^^^^ + # + # Foo, Bar = 1 + # ^^^ ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#418 + def visit_constant_write_node(node); end + + # def foo; end + # ^^^^^^^^^^^^ + # + # def self.foo; end + # ^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#501 + def visit_def_node(node); end + + # defined? a + # ^^^^^^^^^^ + # + # defined?(a) + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#532 + def visit_defined_node(node); end + + # if foo then bar else baz end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#538 + def visit_else_node(node); end + + # "foo #{bar}" + # ^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#544 + def visit_embedded_statements_node(node); end + + # "foo #@bar" + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#552 + def visit_embedded_variable_node(node); end + + # begin; foo; ensure; bar; end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#558 + def visit_ensure_node(node); end + + # false + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#564 + def visit_false_node(node); end + + # foo => [*, bar, *] + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#570 + def visit_find_pattern_node(node); end + + # if foo .. bar; end + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#576 + def visit_flip_flop_node(node); end + + # 1.0 + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#586 + def visit_float_node(node); end + + # for foo in bar do end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#592 + def visit_for_node(node); end + + # def foo(...); bar(...); end + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#598 + def visit_forwarding_arguments_node(node); end + + # def foo(...); end + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#604 + def visit_forwarding_parameter_node(node); end + + # super + # ^^^^^ + # + # super {} + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#613 + def visit_forwarding_super_node(node); end + + # $foo &&= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#640 + def visit_global_variable_and_write_node(node); end + + # $foo += bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#634 + def visit_global_variable_operator_write_node(node); end + + # $foo ||= bar + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#646 + def visit_global_variable_or_write_node(node); end + + # $foo + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#619 + def visit_global_variable_read_node(node); end + + # $foo, = bar + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#652 + def visit_global_variable_target_node(node); end + + # $foo = 1 + # ^^^^^^^^ + # + # $foo, $bar = 1 + # ^^^^ ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#628 + def visit_global_variable_write_node(node); end + + # {} + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#658 + def visit_hash_node(node); end + + # foo => {} + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#664 + def visit_hash_pattern_node(node); end + + # if foo then bar end + # ^^^^^^^^^^^^^^^^^^^ + # + # bar if foo + # ^^^^^^^^^^ + # + # foo ? bar : baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#685 + def visit_if_node(node); end + + # 1i + # + # source://prism//lib/prism/translation/ruby_parser.rb#690 + def visit_imaginary_node(node); end + + # { foo: } + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#696 + def visit_implicit_node(node); end + + # foo { |bar,| } + # ^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#701 + def visit_implicit_rest_node(node); end + + # case foo; in bar; end + # ^^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#706 + def visit_in_node(node); end + + # foo[bar] &&= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#732 + def visit_index_and_write_node(node); end + + # foo[bar] += baz + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#719 + def visit_index_operator_write_node(node); end + + # foo[bar] ||= baz + # ^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#745 + def visit_index_or_write_node(node); end + + # foo[bar], = 1 + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#758 + def visit_index_target_node(node); end + + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#788 + def visit_instance_variable_and_write_node(node); end + + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#782 + def visit_instance_variable_operator_write_node(node); end + + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#794 + def visit_instance_variable_or_write_node(node); end + + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#767 + def visit_instance_variable_read_node(node); end + + # @foo, = bar + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#800 + def visit_instance_variable_target_node(node); end + + # ^^^^^^^^ + # + # @foo, @bar = 1 + # ^^^^ ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#776 + def visit_instance_variable_write_node(node); end + + # 1 + # ^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#806 + def visit_integer_node(node); end + + # if /foo #{bar}/ then end + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#812 + def visit_interpolated_match_last_line_node(node); end + + # /foo #{bar}/ + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#829 + def visit_interpolated_regular_expression_node(node); end + + # "foo #{bar}" + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#844 + def visit_interpolated_string_node(node); end + + # :"foo #{bar}" + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#851 + def visit_interpolated_symbol_node(node); end + + # `foo #{bar}` + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#858 + def visit_interpolated_x_string_node(node); end + + # -> { it } + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#923 + def visit_it_local_variable_read_node(node); end + + # foo(bar: baz) + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#929 + def visit_keyword_hash_node(node); end + + # def foo(**bar); end + # ^^^^^ + # + # def foo(**); end + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#938 + def visit_keyword_rest_parameter_node(node); end + + # -> {} + # + # source://prism//lib/prism/translation/ruby_parser.rb#943 + def visit_lambda_node(node); end + + # foo &&= bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#986 + def visit_local_variable_and_write_node(node); end + + # foo += bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#980 + def visit_local_variable_operator_write_node(node); end + + # foo ||= bar + # ^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#992 + def visit_local_variable_or_write_node(node); end + + # foo + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#961 + def visit_local_variable_read_node(node); end + + # foo, = bar + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#998 + def visit_local_variable_target_node(node); end + + # foo = 1 + # ^^^^^^^ + # + # foo, bar = 1 + # ^^^ ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#974 + def visit_local_variable_write_node(node); end + + # if /foo/ then end + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1004 + def visit_match_last_line_node(node); end + + # foo in bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1010 + def visit_match_predicate_node(node); end + + # foo => bar + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1016 + def visit_match_required_node(node); end + + # /(?foo)/ =~ bar + # ^^^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1022 + def visit_match_write_node(node); end + + # A node that is missing from the syntax tree. This is only used in the + # case of a syntax error. The parser gem doesn't have such a concept, so + # we invent our own here. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1029 + def visit_missing_node(node); end + + # module Foo; end + # ^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1035 + def visit_module_node(node); end + + # foo, bar = baz + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1055 + def visit_multi_target_node(node); end + + # foo, bar = baz + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1065 + def visit_multi_write_node(node); end + + # next + # ^^^^ + # + # next foo + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1089 + def visit_next_node(node); end + + # nil + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1102 + def visit_nil_node(node); end + + # def foo(**nil); end + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1108 + def visit_no_keywords_parameter_node(node); end + + # -> { _1 + _2 } + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1114 + def visit_numbered_parameters_node(node); end + + # $1 + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1120 + def visit_numbered_reference_read_node(node); end + + # def foo(bar: baz); end + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1126 + def visit_optional_keyword_parameter_node(node); end + + # def foo(bar = 1); end + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1132 + def visit_optional_parameter_node(node); end + + # a or b + # ^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1138 + def visit_or_node(node); end + + # def foo(bar, *baz); end + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1144 + def visit_parameters_node(node); end + + # () + # ^^ + # + # (1) + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1182 + def visit_parentheses_node(node); end + + # foo => ^(bar) + # ^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1192 + def visit_pinned_expression_node(node); end + + # foo = 1 and bar => ^foo + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1198 + def visit_pinned_variable_node(node); end + + # END {} + # + # source://prism//lib/prism/translation/ruby_parser.rb#1207 + def visit_post_execution_node(node); end + + # BEGIN {} + # + # source://prism//lib/prism/translation/ruby_parser.rb#1212 + def visit_pre_execution_node(node); end + + # The top-level program node. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1217 + def visit_program_node(node); end + + # 0..5 + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1223 + def visit_range_node(node); end + + # 1r + # ^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1245 + def visit_rational_node(node); end + + # redo + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1251 + def visit_redo_node(node); end + + # /foo/ + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1257 + def visit_regular_expression_node(node); end + + # def foo(bar:); end + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1263 + def visit_required_keyword_parameter_node(node); end + + # def foo(bar); end + # ^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1269 + def visit_required_parameter_node(node); end + + # foo rescue bar + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1275 + def visit_rescue_modifier_node(node); end + + # begin; rescue; end + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1281 + def visit_rescue_node(node); end + + # def foo(*bar); end + # ^^^^ + # + # def foo(*); end + # ^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1301 + def visit_rest_parameter_node(node); end + + # retry + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1307 + def visit_retry_node(node); end + + # return + # ^^^^^^ + # + # return 1 + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1316 + def visit_return_node(node); end + + # self + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1329 + def visit_self_node(node); end + + # A shareable constant. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1334 + def visit_shareable_constant_node(node); end + + # class << self; end + # ^^^^^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1340 + def visit_singleton_class_node(node); end + + # __ENCODING__ + # ^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1348 + def visit_source_encoding_node(node); end + + # __FILE__ + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1355 + def visit_source_file_node(node); end + + # __LINE__ + # ^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1361 + def visit_source_line_node(node); end + + # foo(*bar) + # ^^^^ + # + # def foo((bar, *baz)); end + # ^^^^ + # + # def foo(*); bar(*); end + # ^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1373 + def visit_splat_node(node); end + + # A list of statements. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1382 + def visit_statements_node(node); end + + # "foo" + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1394 + def visit_string_node(node); end + + # super(foo) + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1400 + def visit_super_node(node); end + + # :foo + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1414 + def visit_symbol_node(node); end + + # true + # ^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1420 + def visit_true_node(node); end + + # undef foo + # ^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1426 + def visit_undef_node(node); end + + # unless foo; bar end + # ^^^^^^^^^^^^^^^^^^^ + # + # bar unless foo + # ^^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1436 + def visit_unless_node(node); end + + # until foo; bar end + # ^^^^^^^^^^^^^^^^^ + # + # bar until foo + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1445 + def visit_until_node(node); end + + # case foo; when bar; end + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1451 + def visit_when_node(node); end + + # while foo; bar end + # ^^^^^^^^^^^^^^^^^^ + # + # bar while foo + # ^^^^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1460 + def visit_while_node(node); end + + # `foo` + # ^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1466 + def visit_x_string_node(node); end + + # yield + # ^^^^^ + # + # yield 1 + # ^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1482 + def visit_yield_node(node); end + + private + + # If a class variable is written within a method definition, it has a + # different type than everywhere else. + # + # source://prism//lib/prism/translation/ruby_parser.rb#403 + def class_variable_write_type; end + + # Create a new compiler with the given options. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1489 + def copy_compiler(in_def: T.unsafe(nil), in_pattern: T.unsafe(nil)); end + + # Call nodes with operators following them will either be op_asgn or + # op_asgn2 nodes. That is determined by their call operator and their + # right-hand side. + # + # @return [Boolean] + # + # source://prism//lib/prism/translation/ruby_parser.rb#308 + def op_asgn?(node); end + + # Call nodes with operators following them can use &. as an operator, + # which changes their type by prefixing "safe_". + # + # source://prism//lib/prism/translation/ruby_parser.rb#314 + def op_asgn_type(node, type); end + + # Create a new Sexp object from the given prism node and arguments. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1494 + def s(node, *arguments); end + + # Visit a block node, which will modify the AST by wrapping the given + # visited node in an iter node. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1504 + def visit_block(node, sexp, block); end + + # def foo((bar, baz)); end + # ^^^^^^^^^^ + # + # source://prism//lib/prism/translation/ruby_parser.rb#1159 + def visit_destructured_parameter(node); end + + # Visit the interpolated content of the string-like node. + # + # source://prism//lib/prism/translation/ruby_parser.rb#865 + def visit_interpolated_parts(parts); end + + # Pattern constants get wrapped in another layer of :const. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1525 + def visit_pattern_constant(node); end + + # If the bounds of a range node are empty parentheses, then they do not + # get replaced by their usual s(:nil), but instead are s(:begin). + # + # source://prism//lib/prism/translation/ruby_parser.rb#1235 + def visit_range_bounds_node(node); end + + # Visit the value of a write, which will be on the right-hand side of + # a write operator. Because implicit arrays can have splats, those could + # potentially be wrapped in an svalue node. + # + # source://prism//lib/prism/translation/ruby_parser.rb#1539 + def visit_write_value(node); end +end + +# Represents the use of the literal `true` keyword. +# +# true +# ^^^^ +# +# source://prism//lib/prism/node.rb#18041 +class Prism::TrueNode < ::Prism::Node + # def initialize: (Location location) -> void + # + # @return [TrueNode] a new instance of TrueNode + # + # source://prism//lib/prism/node.rb#18043 + sig { params(source: Prism::Source, location: Prism::Location).void } + def initialize(source, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18116 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18049 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18054 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#18064 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#18059 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?location: Location) -> TrueNode + # + # source://prism//lib/prism/node.rb#18069 + sig { params(location: Prism::Location).returns(Prism::TrueNode) } + def copy(location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18054 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location } + # + # source://prism//lib/prism/node.rb#18077 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#18082 + sig { override.returns(String) } + def inspect; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18100 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18110 + def type; end + end +end + +# Represents the use of the `undef` keyword. +# +# undef :foo, :bar, :baz +# ^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#18125 +class Prism::UndefNode < ::Prism::Node + # def initialize: (Array[SymbolNode | InterpolatedSymbolNode] names, Location keyword_loc, Location location) -> void + # + # @return [UndefNode] a new instance of UndefNode + # + # source://prism//lib/prism/node.rb#18127 + sig do + params( + source: Prism::Source, + names: T::Array[T.any(Prism::SymbolNode, Prism::InterpolatedSymbolNode)], + keyword_loc: Prism::Location, + location: Prism::Location + ).void + end + def initialize(source, names, keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18217 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18135 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18140 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#18150 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#18145 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?names: Array[SymbolNode | InterpolatedSymbolNode], ?keyword_loc: Location, ?location: Location) -> UndefNode + # + # source://prism//lib/prism/node.rb#18155 + sig do + params( + names: T::Array[T.any(Prism::SymbolNode, Prism::InterpolatedSymbolNode)], + keyword_loc: Prism::Location, + location: Prism::Location + ).returns(Prism::UndefNode) + end + def copy(names: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18140 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { names: Array[SymbolNode | InterpolatedSymbolNode], keyword_loc: Location, location: Location } + # + # source://prism//lib/prism/node.rb#18163 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#18183 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#18178 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#18171 + sig { returns(Prism::Location) } + def keyword_loc; end + + # attr_reader names: Array[SymbolNode | InterpolatedSymbolNode] + # + # source://prism//lib/prism/node.rb#18168 + sig { returns(T::Array[T.any(Prism::SymbolNode, Prism::InterpolatedSymbolNode)]) } + def names; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18201 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18211 + def type; end + end +end + +# Represents the use of the `unless` keyword, either in the block form or the modifier form. +# +# bar unless foo +# ^^^^^^^^^^^^^^ +# +# unless foo then bar end +# ^^^^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#18232 +class Prism::UnlessNode < ::Prism::Node + # def initialize: (Location keyword_loc, Prism::node predicate, Location? then_keyword_loc, StatementsNode? statements, ElseNode? consequent, Location? end_keyword_loc, Location location) -> void + # + # @return [UnlessNode] a new instance of UnlessNode + # + # source://prism//lib/prism/node.rb#18234 + sig do + params( + source: Prism::Source, + keyword_loc: Prism::Location, + predicate: Prism::Node, + then_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + consequent: T.nilable(Prism::ElseNode), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18399 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18246 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18251 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#18265 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#18256 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # The else clause of the unless expression, if present. + # + # unless cond then bar else baz end + # ^^^^^^^^ + # + # source://prism//lib/prism/node.rb#18331 + sig { returns(T.nilable(Prism::ElseNode)) } + def consequent; end + + # def copy: (?keyword_loc: Location, ?predicate: Prism::node, ?then_keyword_loc: Location?, ?statements: StatementsNode?, ?consequent: ElseNode?, ?end_keyword_loc: Location?, ?location: Location) -> UnlessNode + # + # source://prism//lib/prism/node.rb#18270 + sig do + params( + keyword_loc: Prism::Location, + predicate: Prism::Node, + then_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + consequent: T.nilable(Prism::ElseNode), + end_keyword_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::UnlessNode) + end + def copy(keyword_loc: T.unsafe(nil), predicate: T.unsafe(nil), then_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), consequent: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18251 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, predicate: Prism::node, then_keyword_loc: Location?, statements: StatementsNode?, consequent: ElseNode?, end_keyword_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#18278 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + # def end_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#18360 + sig { returns(T.nilable(String)) } + def end_keyword; end + + # The location of the `end` keyword, if present. + # + # unless cond then bar end + # ^^^ + # + # source://prism//lib/prism/node.rb#18337 + sig { returns(T.nilable(Prism::Location)) } + def end_keyword_loc; end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#18365 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#18350 + sig { returns(String) } + def keyword; end + + # The location of the `unless` keyword. + # + # unless cond then bar end + # ^^^^^^ + # + # bar unless cond + # ^^^^^^ + # + # source://prism//lib/prism/node.rb#18289 + sig { returns(Prism::Location) } + def keyword_loc; end + + # source://prism//lib/prism/parse_result/newlines.rb#97 + def newline!(lines); end + + # The condition to be evaluated for the unless expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). + # + # unless cond then bar end + # ^^^^ + # + # bar unless cond + # ^^^^ + # + # source://prism//lib/prism/node.rb#18302 + sig { returns(Prism::Node) } + def predicate; end + + # The body of statements that will executed if the unless condition is + # falsey. Will be `nil` if no body is provided. + # + # unless cond then bar end + # ^^^ + # + # source://prism//lib/prism/node.rb#18325 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # def then_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#18355 + sig { returns(T.nilable(String)) } + def then_keyword; end + + # The location of the `then` keyword, if present. + # + # unless cond then bar end + # ^^^^ + # + # source://prism//lib/prism/node.rb#18308 + sig { returns(T.nilable(Prism::Location)) } + def then_keyword_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18383 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18393 + def type; end + end +end + +# Represents the use of the `until` keyword, either in the block form or the modifier form. +# +# bar until foo +# ^^^^^^^^^^^^^ +# +# until foo do bar end +# ^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#18417 +class Prism::UntilNode < ::Prism::Node + # def initialize: (Integer flags, Location keyword_loc, Location? closing_loc, Prism::node predicate, StatementsNode? statements, Location location) -> void + # + # @return [UntilNode] a new instance of UntilNode + # + # source://prism//lib/prism/node.rb#18419 + sig do + params( + source: Prism::Source, + flags: Integer, + keyword_loc: Prism::Location, + closing_loc: T.nilable(Prism::Location), + predicate: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + location: Prism::Location + ).void + end + def initialize(source, flags, keyword_loc, closing_loc, predicate, statements, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18545 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18430 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def begin_modifier?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#18496 + sig { returns(T::Boolean) } + def begin_modifier?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18435 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#18506 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#18477 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#18448 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#18440 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?keyword_loc: Location, ?closing_loc: Location?, ?predicate: Prism::node, ?statements: StatementsNode?, ?location: Location) -> UntilNode + # + # source://prism//lib/prism/node.rb#18453 + sig do + params( + flags: Integer, + keyword_loc: Prism::Location, + closing_loc: T.nilable(Prism::Location), + predicate: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + location: Prism::Location + ).returns(Prism::UntilNode) + end + def copy(flags: T.unsafe(nil), keyword_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), predicate: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18435 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, keyword_loc: Location, closing_loc: Location?, predicate: Prism::node, statements: StatementsNode?, location: Location } + # + # source://prism//lib/prism/node.rb#18461 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#18511 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#18501 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#18470 + sig { returns(Prism::Location) } + def keyword_loc; end + + # source://prism//lib/prism/parse_result/newlines.rb#103 + def newline!(lines); end + + # attr_reader predicate: Prism::node + # + # source://prism//lib/prism/node.rb#18490 + sig { returns(Prism::Node) } + def predicate; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#18493 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18529 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#18466 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18539 + def type; end + end +end + +# The version constant is set by reading the result of calling pm_version. +Prism::VERSION = T.let(T.unsafe(nil), String) + +# A visitor is a class that provides a default implementation for every accept +# method defined on the nodes. This means it can walk a tree without the +# caller needing to define any special handling. This allows you to handle a +# subset of the tree, while still walking the whole tree. +# +# For example, to find all of the method calls that call the `foo` method, you +# could write: +# +# class FooCalls < Prism::Visitor +# def visit_call_node(node) +# if node.name == "foo" +# # Do something with the node +# end +# +# # Call super so that the visitor continues walking the tree +# super +# end +# end +# +# source://prism//lib/prism/visitor.rb#54 +class Prism::Visitor < ::Prism::BasicVisitor + # Visit a AliasGlobalVariableNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::AliasGlobalVariableNode).void } + def visit_alias_global_variable_node(node); end + + # Visit a AliasMethodNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::AliasMethodNode).void } + def visit_alias_method_node(node); end + + # Visit a AlternationPatternNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::AlternationPatternNode).void } + def visit_alternation_pattern_node(node); end + + # Visit a AndNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::AndNode).void } + def visit_and_node(node); end + + # Visit a ArgumentsNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ArgumentsNode).void } + def visit_arguments_node(node); end + + # Visit a ArrayNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ArrayNode).void } + def visit_array_node(node); end + + # Visit a ArrayPatternNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ArrayPatternNode).void } + def visit_array_pattern_node(node); end + + # Visit a AssocNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::AssocNode).void } + def visit_assoc_node(node); end + + # Visit a AssocSplatNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::AssocSplatNode).void } + def visit_assoc_splat_node(node); end + + # Visit a BackReferenceReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BackReferenceReadNode).void } + def visit_back_reference_read_node(node); end + + # Visit a BeginNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BeginNode).void } + def visit_begin_node(node); end + + # Visit a BlockArgumentNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BlockArgumentNode).void } + def visit_block_argument_node(node); end + + # Visit a BlockLocalVariableNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BlockLocalVariableNode).void } + def visit_block_local_variable_node(node); end + + # Visit a BlockNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BlockNode).void } + def visit_block_node(node); end + + # Visit a BlockParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BlockParameterNode).void } + def visit_block_parameter_node(node); end + + # Visit a BlockParametersNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BlockParametersNode).void } + def visit_block_parameters_node(node); end + + # Visit a BreakNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::BreakNode).void } + def visit_break_node(node); end + + # Visit a CallAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CallAndWriteNode).void } + def visit_call_and_write_node(node); end + + # Visit a CallNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CallNode).void } + def visit_call_node(node); end + + # Visit a CallOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CallOperatorWriteNode).void } + def visit_call_operator_write_node(node); end + + # Visit a CallOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CallOrWriteNode).void } + def visit_call_or_write_node(node); end + + # Visit a CallTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CallTargetNode).void } + def visit_call_target_node(node); end + + # Visit a CapturePatternNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CapturePatternNode).void } + def visit_capture_pattern_node(node); end + + # Visit a CaseMatchNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CaseMatchNode).void } + def visit_case_match_node(node); end + + # Visit a CaseNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::CaseNode).void } + def visit_case_node(node); end + + # Visit a ClassNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ClassNode).void } + def visit_class_node(node); end + + # Visit a ClassVariableAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ClassVariableAndWriteNode).void } + def visit_class_variable_and_write_node(node); end + + # Visit a ClassVariableOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ClassVariableOperatorWriteNode).void } + def visit_class_variable_operator_write_node(node); end + + # Visit a ClassVariableOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ClassVariableOrWriteNode).void } + def visit_class_variable_or_write_node(node); end + + # Visit a ClassVariableReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ClassVariableReadNode).void } + def visit_class_variable_read_node(node); end + + # Visit a ClassVariableTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ClassVariableTargetNode).void } + def visit_class_variable_target_node(node); end + + # Visit a ClassVariableWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ClassVariableWriteNode).void } + def visit_class_variable_write_node(node); end + + # Visit a ConstantAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantAndWriteNode).void } + def visit_constant_and_write_node(node); end + + # Visit a ConstantOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantOperatorWriteNode).void } + def visit_constant_operator_write_node(node); end + + # Visit a ConstantOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantOrWriteNode).void } + def visit_constant_or_write_node(node); end + + # Visit a ConstantPathAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantPathAndWriteNode).void } + def visit_constant_path_and_write_node(node); end + + # Visit a ConstantPathNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantPathNode).void } + def visit_constant_path_node(node); end + + # Visit a ConstantPathOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantPathOperatorWriteNode).void } + def visit_constant_path_operator_write_node(node); end + + # Visit a ConstantPathOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantPathOrWriteNode).void } + def visit_constant_path_or_write_node(node); end + + # Visit a ConstantPathTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantPathTargetNode).void } + def visit_constant_path_target_node(node); end + + # Visit a ConstantPathWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantPathWriteNode).void } + def visit_constant_path_write_node(node); end + + # Visit a ConstantReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantReadNode).void } + def visit_constant_read_node(node); end + + # Visit a ConstantTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantTargetNode).void } + def visit_constant_target_node(node); end + + # Visit a ConstantWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ConstantWriteNode).void } + def visit_constant_write_node(node); end + + # Visit a DefNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::DefNode).void } + def visit_def_node(node); end + + # Visit a DefinedNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::DefinedNode).void } + def visit_defined_node(node); end + + # Visit a ElseNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ElseNode).void } + def visit_else_node(node); end + + # Visit a EmbeddedStatementsNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::EmbeddedStatementsNode).void } + def visit_embedded_statements_node(node); end + + # Visit a EmbeddedVariableNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::EmbeddedVariableNode).void } + def visit_embedded_variable_node(node); end + + # Visit a EnsureNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::EnsureNode).void } + def visit_ensure_node(node); end + + # Visit a FalseNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::FalseNode).void } + def visit_false_node(node); end + + # Visit a FindPatternNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::FindPatternNode).void } + def visit_find_pattern_node(node); end + + # Visit a FlipFlopNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::FlipFlopNode).void } + def visit_flip_flop_node(node); end + + # Visit a FloatNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::FloatNode).void } + def visit_float_node(node); end + + # Visit a ForNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ForNode).void } + def visit_for_node(node); end + + # Visit a ForwardingArgumentsNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ForwardingArgumentsNode).void } + def visit_forwarding_arguments_node(node); end + + # Visit a ForwardingParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ForwardingParameterNode).void } + def visit_forwarding_parameter_node(node); end + + # Visit a ForwardingSuperNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ForwardingSuperNode).void } + def visit_forwarding_super_node(node); end + + # Visit a GlobalVariableAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::GlobalVariableAndWriteNode).void } + def visit_global_variable_and_write_node(node); end + + # Visit a GlobalVariableOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::GlobalVariableOperatorWriteNode).void } + def visit_global_variable_operator_write_node(node); end + + # Visit a GlobalVariableOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::GlobalVariableOrWriteNode).void } + def visit_global_variable_or_write_node(node); end + + # Visit a GlobalVariableReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::GlobalVariableReadNode).void } + def visit_global_variable_read_node(node); end + + # Visit a GlobalVariableTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::GlobalVariableTargetNode).void } + def visit_global_variable_target_node(node); end + + # Visit a GlobalVariableWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::GlobalVariableWriteNode).void } + def visit_global_variable_write_node(node); end + + # Visit a HashNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::HashNode).void } + def visit_hash_node(node); end + + # Visit a HashPatternNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::HashPatternNode).void } + def visit_hash_pattern_node(node); end + + # Visit a IfNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::IfNode).void } + def visit_if_node(node); end + + # Visit a ImaginaryNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ImaginaryNode).void } + def visit_imaginary_node(node); end + + # Visit a ImplicitNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ImplicitNode).void } + def visit_implicit_node(node); end + + # Visit a ImplicitRestNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ImplicitRestNode).void } + def visit_implicit_rest_node(node); end + + # Visit a InNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InNode).void } + def visit_in_node(node); end + + # Visit a IndexAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::IndexAndWriteNode).void } + def visit_index_and_write_node(node); end + + # Visit a IndexOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::IndexOperatorWriteNode).void } + def visit_index_operator_write_node(node); end + + # Visit a IndexOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::IndexOrWriteNode).void } + def visit_index_or_write_node(node); end + + # Visit a IndexTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::IndexTargetNode).void } + def visit_index_target_node(node); end + + # Visit a InstanceVariableAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InstanceVariableAndWriteNode).void } + def visit_instance_variable_and_write_node(node); end + + # Visit a InstanceVariableOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InstanceVariableOperatorWriteNode).void } + def visit_instance_variable_operator_write_node(node); end + + # Visit a InstanceVariableOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InstanceVariableOrWriteNode).void } + def visit_instance_variable_or_write_node(node); end + + # Visit a InstanceVariableReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InstanceVariableReadNode).void } + def visit_instance_variable_read_node(node); end + + # Visit a InstanceVariableTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InstanceVariableTargetNode).void } + def visit_instance_variable_target_node(node); end + + # Visit a InstanceVariableWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InstanceVariableWriteNode).void } + def visit_instance_variable_write_node(node); end + + # Visit a IntegerNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::IntegerNode).void } + def visit_integer_node(node); end + + # Visit a InterpolatedMatchLastLineNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InterpolatedMatchLastLineNode).void } + def visit_interpolated_match_last_line_node(node); end + + # Visit a InterpolatedRegularExpressionNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InterpolatedRegularExpressionNode).void } + def visit_interpolated_regular_expression_node(node); end + + # Visit a InterpolatedStringNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InterpolatedStringNode).void } + def visit_interpolated_string_node(node); end + + # Visit a InterpolatedSymbolNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InterpolatedSymbolNode).void } + def visit_interpolated_symbol_node(node); end + + # Visit a InterpolatedXStringNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::InterpolatedXStringNode).void } + def visit_interpolated_x_string_node(node); end + + # Visit a ItLocalVariableReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ItLocalVariableReadNode).void } + def visit_it_local_variable_read_node(node); end + + # Visit a ItParametersNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ItParametersNode).void } + def visit_it_parameters_node(node); end + + # Visit a KeywordHashNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::KeywordHashNode).void } + def visit_keyword_hash_node(node); end + + # Visit a KeywordRestParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::KeywordRestParameterNode).void } + def visit_keyword_rest_parameter_node(node); end + + # Visit a LambdaNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::LambdaNode).void } + def visit_lambda_node(node); end + + # Visit a LocalVariableAndWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::LocalVariableAndWriteNode).void } + def visit_local_variable_and_write_node(node); end + + # Visit a LocalVariableOperatorWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::LocalVariableOperatorWriteNode).void } + def visit_local_variable_operator_write_node(node); end + + # Visit a LocalVariableOrWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::LocalVariableOrWriteNode).void } + def visit_local_variable_or_write_node(node); end + + # Visit a LocalVariableReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::LocalVariableReadNode).void } + def visit_local_variable_read_node(node); end + + # Visit a LocalVariableTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::LocalVariableTargetNode).void } + def visit_local_variable_target_node(node); end + + # Visit a LocalVariableWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::LocalVariableWriteNode).void } + def visit_local_variable_write_node(node); end + + # Visit a MatchLastLineNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::MatchLastLineNode).void } + def visit_match_last_line_node(node); end + + # Visit a MatchPredicateNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::MatchPredicateNode).void } + def visit_match_predicate_node(node); end + + # Visit a MatchRequiredNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::MatchRequiredNode).void } + def visit_match_required_node(node); end + + # Visit a MatchWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::MatchWriteNode).void } + def visit_match_write_node(node); end + + # Visit a MissingNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::MissingNode).void } + def visit_missing_node(node); end + + # Visit a ModuleNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ModuleNode).void } + def visit_module_node(node); end + + # Visit a MultiTargetNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::MultiTargetNode).void } + def visit_multi_target_node(node); end + + # Visit a MultiWriteNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::MultiWriteNode).void } + def visit_multi_write_node(node); end + + # Visit a NextNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::NextNode).void } + def visit_next_node(node); end + + # Visit a NilNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::NilNode).void } + def visit_nil_node(node); end + + # Visit a NoKeywordsParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::NoKeywordsParameterNode).void } + def visit_no_keywords_parameter_node(node); end + + # Visit a NumberedParametersNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::NumberedParametersNode).void } + def visit_numbered_parameters_node(node); end + + # Visit a NumberedReferenceReadNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::NumberedReferenceReadNode).void } + def visit_numbered_reference_read_node(node); end + + # Visit a OptionalKeywordParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::OptionalKeywordParameterNode).void } + def visit_optional_keyword_parameter_node(node); end + + # Visit a OptionalParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::OptionalParameterNode).void } + def visit_optional_parameter_node(node); end + + # Visit a OrNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::OrNode).void } + def visit_or_node(node); end + + # Visit a ParametersNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ParametersNode).void } + def visit_parameters_node(node); end + + # Visit a ParenthesesNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ParenthesesNode).void } + def visit_parentheses_node(node); end + + # Visit a PinnedExpressionNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::PinnedExpressionNode).void } + def visit_pinned_expression_node(node); end + + # Visit a PinnedVariableNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::PinnedVariableNode).void } + def visit_pinned_variable_node(node); end + + # Visit a PostExecutionNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::PostExecutionNode).void } + def visit_post_execution_node(node); end + + # Visit a PreExecutionNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::PreExecutionNode).void } + def visit_pre_execution_node(node); end + + # Visit a ProgramNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ProgramNode).void } + def visit_program_node(node); end + + # Visit a RangeNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RangeNode).void } + def visit_range_node(node); end + + # Visit a RationalNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RationalNode).void } + def visit_rational_node(node); end + + # Visit a RedoNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RedoNode).void } + def visit_redo_node(node); end + + # Visit a RegularExpressionNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RegularExpressionNode).void } + def visit_regular_expression_node(node); end + + # Visit a RequiredKeywordParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RequiredKeywordParameterNode).void } + def visit_required_keyword_parameter_node(node); end + + # Visit a RequiredParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RequiredParameterNode).void } + def visit_required_parameter_node(node); end + + # Visit a RescueModifierNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RescueModifierNode).void } + def visit_rescue_modifier_node(node); end + + # Visit a RescueNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RescueNode).void } + def visit_rescue_node(node); end + + # Visit a RestParameterNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RestParameterNode).void } + def visit_rest_parameter_node(node); end + + # Visit a RetryNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::RetryNode).void } + def visit_retry_node(node); end + + # Visit a ReturnNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ReturnNode).void } + def visit_return_node(node); end + + # Visit a SelfNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SelfNode).void } + def visit_self_node(node); end + + # Visit a ShareableConstantNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::ShareableConstantNode).void } + def visit_shareable_constant_node(node); end + + # Visit a SingletonClassNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SingletonClassNode).void } + def visit_singleton_class_node(node); end + + # Visit a SourceEncodingNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SourceEncodingNode).void } + def visit_source_encoding_node(node); end + + # Visit a SourceFileNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SourceFileNode).void } + def visit_source_file_node(node); end + + # Visit a SourceLineNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SourceLineNode).void } + def visit_source_line_node(node); end + + # Visit a SplatNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SplatNode).void } + def visit_splat_node(node); end + + # Visit a StatementsNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::StatementsNode).void } + def visit_statements_node(node); end + + # Visit a StringNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::StringNode).void } + def visit_string_node(node); end + + # Visit a SuperNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SuperNode).void } + def visit_super_node(node); end + + # Visit a SymbolNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::SymbolNode).void } + def visit_symbol_node(node); end + + # Visit a TrueNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::TrueNode).void } + def visit_true_node(node); end + + # Visit a UndefNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::UndefNode).void } + def visit_undef_node(node); end + + # Visit a UnlessNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::UnlessNode).void } + def visit_unless_node(node); end + + # Visit a UntilNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::UntilNode).void } + def visit_until_node(node); end + + # Visit a WhenNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::WhenNode).void } + def visit_when_node(node); end + + # Visit a WhileNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::WhileNode).void } + def visit_while_node(node); end + + # Visit a XStringNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::XStringNode).void } + def visit_x_string_node(node); end + + # Visit a YieldNode node + # + # source://prism//lib/prism/visitor.rb#29 + sig { params(node: Prism::YieldNode).void } + def visit_yield_node(node); end +end + +# Represents the use of the `when` keyword within a case statement. +# +# case true +# when true +# ^^^^^^^^^ +# end +# +# source://prism//lib/prism/node.rb#18561 +class Prism::WhenNode < ::Prism::Node + # def initialize: (Location keyword_loc, Array[Prism::node] conditions, Location? then_keyword_loc, StatementsNode? statements, Location location) -> void + # + # @return [WhenNode] a new instance of WhenNode + # + # source://prism//lib/prism/node.rb#18563 + sig do + params( + source: Prism::Source, + keyword_loc: Prism::Location, + conditions: T::Array[Prism::Node], + then_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + location: Prism::Location + ).void + end + def initialize(source, keyword_loc, conditions, then_keyword_loc, statements, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18679 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18573 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18578 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#18591 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#18583 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # attr_reader conditions: Array[Prism::node] + # + # source://prism//lib/prism/node.rb#18616 + sig { returns(T::Array[Prism::Node]) } + def conditions; end + + # def copy: (?keyword_loc: Location, ?conditions: Array[Prism::node], ?then_keyword_loc: Location?, ?statements: StatementsNode?, ?location: Location) -> WhenNode + # + # source://prism//lib/prism/node.rb#18596 + sig do + params( + keyword_loc: Prism::Location, + conditions: T::Array[Prism::Node], + then_keyword_loc: T.nilable(Prism::Location), + statements: T.nilable(Prism::StatementsNode), + location: Prism::Location + ).returns(Prism::WhenNode) + end + def copy(keyword_loc: T.unsafe(nil), conditions: T.unsafe(nil), then_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18578 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, conditions: Array[Prism::node], then_keyword_loc: Location?, statements: StatementsNode?, location: Location } + # + # source://prism//lib/prism/node.rb#18604 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#18645 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#18635 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#18609 + sig { returns(Prism::Location) } + def keyword_loc; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#18632 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # def then_keyword: () -> String? + # + # source://prism//lib/prism/node.rb#18640 + sig { returns(T.nilable(String)) } + def then_keyword; end + + # attr_reader then_keyword_loc: Location? + # + # source://prism//lib/prism/node.rb#18619 + sig { returns(T.nilable(Prism::Location)) } + def then_keyword_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18663 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18673 + def type; end + end +end + +# Represents the use of the `while` keyword, either in the block form or the modifier form. +# +# bar while foo +# ^^^^^^^^^^^^^ +# +# while foo do bar end +# ^^^^^^^^^^^^^^^^^^^^ +# +# source://prism//lib/prism/node.rb#18696 +class Prism::WhileNode < ::Prism::Node + # def initialize: (Integer flags, Location keyword_loc, Location? closing_loc, Prism::node predicate, StatementsNode? statements, Location location) -> void + # + # @return [WhileNode] a new instance of WhileNode + # + # source://prism//lib/prism/node.rb#18698 + sig do + params( + source: Prism::Source, + flags: Integer, + keyword_loc: Prism::Location, + closing_loc: T.nilable(Prism::Location), + predicate: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + location: Prism::Location + ).void + end + def initialize(source, flags, keyword_loc, closing_loc, predicate, statements, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18824 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18709 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def begin_modifier?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#18775 + sig { returns(T::Boolean) } + def begin_modifier?; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18714 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String? + # + # source://prism//lib/prism/node.rb#18785 + sig { returns(T.nilable(String)) } + def closing; end + + # attr_reader closing_loc: Location? + # + # source://prism//lib/prism/node.rb#18756 + sig { returns(T.nilable(Prism::Location)) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#18727 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#18719 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?flags: Integer, ?keyword_loc: Location, ?closing_loc: Location?, ?predicate: Prism::node, ?statements: StatementsNode?, ?location: Location) -> WhileNode + # + # source://prism//lib/prism/node.rb#18732 + sig do + params( + flags: Integer, + keyword_loc: Prism::Location, + closing_loc: T.nilable(Prism::Location), + predicate: Prism::Node, + statements: T.nilable(Prism::StatementsNode), + location: Prism::Location + ).returns(Prism::WhileNode) + end + def copy(flags: T.unsafe(nil), keyword_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), predicate: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18714 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, keyword_loc: Location, closing_loc: Location?, predicate: Prism::node, statements: StatementsNode?, location: Location } + # + # source://prism//lib/prism/node.rb#18740 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#18790 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#18780 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#18749 + sig { returns(Prism::Location) } + def keyword_loc; end + + # source://prism//lib/prism/parse_result/newlines.rb#109 + def newline!(lines); end + + # attr_reader predicate: Prism::node + # + # source://prism//lib/prism/node.rb#18769 + sig { returns(Prism::Node) } + def predicate; end + + # attr_reader statements: StatementsNode? + # + # source://prism//lib/prism/node.rb#18772 + sig { returns(T.nilable(Prism::StatementsNode)) } + def statements; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18808 + sig { override.returns(Symbol) } + def type; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#18745 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18818 + def type; end + end +end + +# Represents an xstring literal with no interpolation. +# +# `foo` +# ^^^^^ +# +# source://prism//lib/prism/node.rb#18838 +class Prism::XStringNode < ::Prism::Node + include ::Prism::HeredocQuery + + # def initialize: (Integer flags, Location opening_loc, Location content_loc, Location closing_loc, String unescaped, Location location) -> void + # + # @return [XStringNode] a new instance of XStringNode + # + # source://prism//lib/prism/node.rb#18840 + sig do + params( + source: Prism::Source, + flags: Integer, + opening_loc: Prism::Location, + content_loc: Prism::Location, + closing_loc: Prism::Location, + unescaped: String, + location: Prism::Location + ).void + end + def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#18971 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18851 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18856 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def closing: () -> String + # + # source://prism//lib/prism/node.rb#18932 + sig { returns(String) } + def closing; end + + # attr_reader closing_loc: Location + # + # source://prism//lib/prism/node.rb#18902 + sig { returns(Prism::Location) } + def closing_loc; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#18866 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#18861 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def content: () -> String + # + # source://prism//lib/prism/node.rb#18927 + sig { returns(String) } + def content; end + + # attr_reader content_loc: Location + # + # source://prism//lib/prism/node.rb#18895 + sig { returns(Prism::Location) } + def content_loc; end + + # def copy: (?flags: Integer, ?opening_loc: Location, ?content_loc: Location, ?closing_loc: Location, ?unescaped: String, ?location: Location) -> XStringNode + # + # source://prism//lib/prism/node.rb#18871 + sig do + params( + flags: Integer, + opening_loc: Prism::Location, + content_loc: Prism::Location, + closing_loc: Prism::Location, + unescaped: String, + location: Prism::Location + ).returns(Prism::XStringNode) + end + def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#18856 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, content_loc: Location, closing_loc: Location, unescaped: String, location: Location } + # + # source://prism//lib/prism/node.rb#18879 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def forced_binary_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#18917 + sig { returns(T::Boolean) } + def forced_binary_encoding?; end + + # def forced_utf8_encoding?: () -> bool + # + # @return [Boolean] + # + # source://prism//lib/prism/node.rb#18912 + sig { returns(T::Boolean) } + def forced_utf8_encoding?; end + + sig { returns(T::Boolean) } + def heredoc?; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#18937 + sig { override.returns(String) } + def inspect; end + + # def opening: () -> String + # + # source://prism//lib/prism/node.rb#18922 + sig { returns(String) } + def opening; end + + # attr_reader opening_loc: Location + # + # source://prism//lib/prism/node.rb#18888 + sig { returns(Prism::Location) } + def opening_loc; end + + # Occasionally it's helpful to treat a string as if it were interpolated so + # that there's a consistent interface for working with strings. + # + # source://prism//lib/prism/node_ext.rb#86 + sig { returns(Prism::InterpolatedXStringNode) } + def to_interpolated; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18955 + sig { override.returns(Symbol) } + def type; end + + # attr_reader unescaped: String + # + # source://prism//lib/prism/node.rb#18909 + sig { returns(String) } + def unescaped; end + + protected + + # protected attr_reader flags: Integer + # + # source://prism//lib/prism/node.rb#18884 + sig { returns(Integer) } + def flags; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#18965 + def type; end + end +end + +# Represents the use of the `yield` keyword. +# +# yield 1 +# ^^^^^^^ +# +# source://prism//lib/prism/node.rb#18985 +class Prism::YieldNode < ::Prism::Node + # def initialize: (Location keyword_loc, Location? lparen_loc, ArgumentsNode? arguments, Location? rparen_loc, Location location) -> void + # + # @return [YieldNode] a new instance of YieldNode + # + # source://prism//lib/prism/node.rb#18987 + sig do + params( + source: Prism::Source, + keyword_loc: Prism::Location, + lparen_loc: T.nilable(Prism::Location), + arguments: T.nilable(Prism::ArgumentsNode), + rparen_loc: T.nilable(Prism::Location), + location: Prism::Location + ).void + end + def initialize(source, keyword_loc, lparen_loc, arguments, rparen_loc, location); end + + # Implements case-equality for the node. This is effectively == but without + # comparing the value of locations. Locations are checked only for presence. + # + # source://prism//lib/prism/node.rb#19117 + def ===(other); end + + # def accept: (Visitor visitor) -> void + # + # source://prism//lib/prism/node.rb#18997 + sig { override.params(visitor: Prism::Visitor).returns(T.untyped) } + def accept(visitor); end + + # attr_reader arguments: ArgumentsNode? + # + # source://prism//lib/prism/node.rb#19052 + sig { returns(T.nilable(Prism::ArgumentsNode)) } + def arguments; end + + # def child_nodes: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#19002 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def child_nodes; end + + # def comment_targets: () -> Array[Node | Location] + # + # source://prism//lib/prism/node.rb#19014 + sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) } + def comment_targets; end + + # def compact_child_nodes: () -> Array[Node] + # + # source://prism//lib/prism/node.rb#19007 + sig { override.returns(T::Array[Prism::Node]) } + def compact_child_nodes; end + + # def copy: (?keyword_loc: Location, ?lparen_loc: Location?, ?arguments: ArgumentsNode?, ?rparen_loc: Location?, ?location: Location) -> YieldNode + # + # source://prism//lib/prism/node.rb#19019 + sig do + params( + keyword_loc: Prism::Location, + lparen_loc: T.nilable(Prism::Location), + arguments: T.nilable(Prism::ArgumentsNode), + rparen_loc: T.nilable(Prism::Location), + location: Prism::Location + ).returns(Prism::YieldNode) + end + def copy(keyword_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), arguments: T.unsafe(nil), rparen_loc: T.unsafe(nil), location: T.unsafe(nil)); end + + # def child_nodes: () -> Array[nil | Node] + # def deconstruct: () -> Array[nil | Node] + # + # source://prism//lib/prism/node.rb#19002 + sig { override.returns(T::Array[T.nilable(Prism::Node)]) } + def deconstruct; end + + # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, lparen_loc: Location?, arguments: ArgumentsNode?, rparen_loc: Location?, location: Location } + # + # source://prism//lib/prism/node.rb#19027 + sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) } + def deconstruct_keys(keys); end + + sig { override.returns(T::Array[Prism::Reflection::Field]) } + def fields; end + + # def inspect -> String + # + # source://prism//lib/prism/node.rb#19083 + sig { override.returns(String) } + def inspect; end + + # def keyword: () -> String + # + # source://prism//lib/prism/node.rb#19068 + sig { returns(String) } + def keyword; end + + # attr_reader keyword_loc: Location + # + # source://prism//lib/prism/node.rb#19032 + sig { returns(Prism::Location) } + def keyword_loc; end + + # def lparen: () -> String? + # + # source://prism//lib/prism/node.rb#19073 + sig { returns(T.nilable(String)) } + def lparen; end + + # attr_reader lparen_loc: Location? + # + # source://prism//lib/prism/node.rb#19039 + sig { returns(T.nilable(Prism::Location)) } + def lparen_loc; end + + # def rparen: () -> String? + # + # source://prism//lib/prism/node.rb#19078 + sig { returns(T.nilable(String)) } + def rparen; end + + # attr_reader rparen_loc: Location? + # + # source://prism//lib/prism/node.rb#19055 + sig { returns(T.nilable(Prism::Location)) } + def rparen_loc; end + + # Sometimes you want to check an instance of a node against a list of + # classes to see what kind of behavior to perform. Usually this is done by + # calling `[cls1, cls2].include?(node.class)` or putting the node into a + # case statement and doing `case node; when cls1; when cls2; end`. Both of + # these approaches are relatively slow because of the constant lookups, + # method calls, and/or array allocations. + # + # Instead, you can call #type, which will return to you a symbol that you + # can use for comparison. This is faster than the other approaches because + # it uses a single integer comparison, but also because if you're on CRuby + # you can take advantage of the fact that case statements with all symbol + # keys will use a jump table. + # + # def type: () -> Symbol + # + # source://prism//lib/prism/node.rb#19101 + sig { override.returns(Symbol) } + def type; end + + class << self + # Similar to #type, this method returns a symbol that you can use for + # splitting on the type of the node without having to do a long === chain. + # Note that like #type, it will still be slower than using == for a single + # class, but should be faster in a case statement or an array comparison. + # + # def self.type: () -> Symbol + # + # source://prism//lib/prism/node.rb#19111 + def type; end + end +end diff --git a/sorbet/rbi/gems/pry-nav@1.0.0.rbi b/sorbet/rbi/gems/pry-nav@1.0.0.rbi index 12364088d..b39400840 100644 --- a/sorbet/rbi/gems/pry-nav@1.0.0.rbi +++ b/sorbet/rbi/gems/pry-nav@1.0.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `pry-nav` gem. # Please instead update this file by running `bin/tapioca gem pry-nav`. + # source://pry-nav//lib/pry-nav/version.rb#1 module PryNav extend ::PryNav diff --git a/sorbet/rbi/gems/pry@0.14.2.rbi b/sorbet/rbi/gems/pry@0.14.2.rbi index cb25e7d81..5268e7d92 100644 --- a/sorbet/rbi/gems/pry@0.14.2.rbi +++ b/sorbet/rbi/gems/pry@0.14.2.rbi @@ -4,17 +4,6 @@ # This is an autogenerated file for types exported from the `pry` gem. # Please instead update this file by running `bin/tapioca gem pry`. -# source://american_date/1.2.0/lib/american_date.rb#16 -::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) - -# source://ruby-openid/2.9.2/lib/openid/fetchers.rb#13 -::MAX_RESPONSE_KB = T.let(T.unsafe(nil), Integer) - -# source://yard/0.9.34/lib/yard.rb#61 -::RUBY18 = T.let(T.unsafe(nil), FalseClass) - -# source://yard/0.9.34/lib/yard.rb#62 -::RUBY19 = T.let(T.unsafe(nil), TrueClass) # source://pry//lib/pry/core_extensions.rb#115 class BasicObject diff --git a/sorbet/rbi/gems/psych@5.1.2.rbi b/sorbet/rbi/gems/psych@5.1.2.rbi new file mode 100644 index 000000000..db4b64ec2 --- /dev/null +++ b/sorbet/rbi/gems/psych@5.1.2.rbi @@ -0,0 +1,1715 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `psych` gem. +# Please instead update this file by running `bin/tapioca gem psych`. + + +class Object < ::BasicObject + include ::Kernel + include ::PP::ObjectMixin + + # call-seq: to_yaml(options = {}) + # + # Convert an object to YAML. See Psych.dump for more information on the + # available +options+. + # + # source://psych//psych/core_ext.rb#12 + def to_yaml(options = T.unsafe(nil)); end + + class << self + # source://psych//psych/core_ext.rb#3 + def yaml_tag(url); end + end +end + +# = Overview +# +# Psych is a YAML parser and emitter. +# Psych leverages libyaml [Home page: https://pyyaml.org/wiki/LibYAML] +# or [git repo: https://github.com/yaml/libyaml] for its YAML parsing +# and emitting capabilities. In addition to wrapping libyaml, Psych also +# knows how to serialize and de-serialize most Ruby objects to and from +# the YAML format. +# +# = I NEED TO PARSE OR EMIT YAML RIGHT NOW! +# +# # Parse some YAML +# Psych.load("--- foo") # => "foo" +# +# # Emit some YAML +# Psych.dump("foo") # => "--- foo\n...\n" +# { :a => 'b'}.to_yaml # => "---\n:a: b\n" +# +# Got more time on your hands? Keep on reading! +# +# == YAML Parsing +# +# Psych provides a range of interfaces for parsing a YAML document ranging from +# low level to high level, depending on your parsing needs. At the lowest +# level, is an event based parser. Mid level is access to the raw YAML AST, +# and at the highest level is the ability to unmarshal YAML to Ruby objects. +# +# == YAML Emitting +# +# Psych provides a range of interfaces ranging from low to high level for +# producing YAML documents. Very similar to the YAML parsing interfaces, Psych +# provides at the lowest level, an event based system, mid-level is building +# a YAML AST, and the highest level is converting a Ruby object straight to +# a YAML document. +# +# == High-level API +# +# === Parsing +# +# The high level YAML parser provided by Psych simply takes YAML as input and +# returns a Ruby data structure. For information on using the high level parser +# see Psych.load +# +# ==== Reading from a string +# +# Psych.safe_load("--- a") # => 'a' +# Psych.safe_load("---\n - a\n - b") # => ['a', 'b'] +# # From a trusted string: +# Psych.load("--- !ruby/range\nbegin: 0\nend: 42\nexcl: false\n") # => 0..42 +# +# ==== Reading from a file +# +# Psych.safe_load_file("data.yml", permitted_classes: [Date]) +# Psych.load_file("trusted_database.yml") +# +# ==== Exception handling +# +# begin +# # The second argument changes only the exception contents +# Psych.parse("--- `", "file.txt") +# rescue Psych::SyntaxError => ex +# ex.file # => 'file.txt' +# ex.message # => "(file.txt): found character that cannot start any token" +# end +# +# === Emitting +# +# The high level emitter has the easiest interface. Psych simply takes a Ruby +# data structure and converts it to a YAML document. See Psych.dump for more +# information on dumping a Ruby data structure. +# +# ==== Writing to a string +# +# # Dump an array, get back a YAML string +# Psych.dump(['a', 'b']) # => "---\n- a\n- b\n" +# +# # Dump an array to an IO object +# Psych.dump(['a', 'b'], StringIO.new) # => # +# +# # Dump an array with indentation set +# Psych.dump(['a', ['b']], :indentation => 3) # => "---\n- a\n- - b\n" +# +# # Dump an array to an IO with indentation set +# Psych.dump(['a', ['b']], StringIO.new, :indentation => 3) +# +# ==== Writing to a file +# +# Currently there is no direct API for dumping Ruby structure to file: +# +# File.open('database.yml', 'w') do |file| +# file.write(Psych.dump(['a', 'b'])) +# end +# +# == Mid-level API +# +# === Parsing +# +# Psych provides access to an AST produced from parsing a YAML document. This +# tree is built using the Psych::Parser and Psych::TreeBuilder. The AST can +# be examined and manipulated freely. Please see Psych::parse_stream, +# Psych::Nodes, and Psych::Nodes::Node for more information on dealing with +# YAML syntax trees. +# +# ==== Reading from a string +# +# # Returns Psych::Nodes::Stream +# Psych.parse_stream("---\n - a\n - b") +# +# # Returns Psych::Nodes::Document +# Psych.parse("---\n - a\n - b") +# +# ==== Reading from a file +# +# # Returns Psych::Nodes::Stream +# Psych.parse_stream(File.read('database.yml')) +# +# # Returns Psych::Nodes::Document +# Psych.parse_file('database.yml') +# +# ==== Exception handling +# +# begin +# # The second argument changes only the exception contents +# Psych.parse("--- `", "file.txt") +# rescue Psych::SyntaxError => ex +# ex.file # => 'file.txt' +# ex.message # => "(file.txt): found character that cannot start any token" +# end +# +# === Emitting +# +# At the mid level is building an AST. This AST is exactly the same as the AST +# used when parsing a YAML document. Users can build an AST by hand and the +# AST knows how to emit itself as a YAML document. See Psych::Nodes, +# Psych::Nodes::Node, and Psych::TreeBuilder for more information on building +# a YAML AST. +# +# ==== Writing to a string +# +# # We need Psych::Nodes::Stream (not Psych::Nodes::Document) +# stream = Psych.parse_stream("---\n - a\n - b") +# +# stream.to_yaml # => "---\n- a\n- b\n" +# +# ==== Writing to a file +# +# # We need Psych::Nodes::Stream (not Psych::Nodes::Document) +# stream = Psych.parse_stream(File.read('database.yml')) +# +# File.open('database.yml', 'w') do |file| +# file.write(stream.to_yaml) +# end +# +# == Low-level API +# +# === Parsing +# +# The lowest level parser should be used when the YAML input is already known, +# and the developer does not want to pay the price of building an AST or +# automatic detection and conversion to Ruby objects. See Psych::Parser for +# more information on using the event based parser. +# +# ==== Reading to Psych::Nodes::Stream structure +# +# parser = Psych::Parser.new(TreeBuilder.new) # => # +# parser = Psych.parser # it's an alias for the above +# +# parser.parse("---\n - a\n - b") # => # +# parser.handler # => # +# parser.handler.root # => # +# +# ==== Receiving an events stream +# +# recorder = Psych::Handlers::Recorder.new +# parser = Psych::Parser.new(recorder) +# +# parser.parse("---\n - a\n - b") +# recorder.events # => [list of [event, args] lists] +# # event is one of: Psych::Handler::EVENTS +# # args are the arguments passed to the event +# +# === Emitting +# +# The lowest level emitter is an event based system. Events are sent to a +# Psych::Emitter object. That object knows how to convert the events to a YAML +# document. This interface should be used when document format is known in +# advance or speed is a concern. See Psych::Emitter for more information. +# +# ==== Writing to a Ruby structure +# +# Psych.parser.parse("--- a") # => # +# +# parser.handler.first # => # +# parser.handler.first.to_ruby # => ["a"] +# +# parser.handler.root.first # => # +# parser.handler.root.first.to_ruby # => "a" +# +# # You can instantiate an Emitter manually +# Psych::Visitors::ToRuby.new.accept(parser.handler.root.first) +# # => "a" +module Psych + extend ::Bootsnap::CompileCache::YAML::Psych4::Patch + + class << self + # source://psych//psych.rb#682 + def add_builtin_type(type_tag, &block); end + + # :stopdoc: + # + # source://psych//psych.rb#676 + def add_domain_type(domain, type_tag, &block); end + + # source://psych//psych.rb#692 + def add_tag(tag, klass); end + + # source://psych//psych.rb#708 + def config; end + + # source://psych//psych.rb#720 + def domain_types; end + + # source://psych//psych.rb#732 + def domain_types=(value); end + + # call-seq: + # Psych.dump(o) -> string of yaml + # Psych.dump(o, options) -> string of yaml + # Psych.dump(o, io) -> io object passed in + # Psych.dump(o, io, options) -> io object passed in + # + # Dump Ruby object +o+ to a YAML string. Optional +options+ may be passed in + # to control the output format. If an IO object is passed in, the YAML will + # be dumped to that IO object. + # + # Currently supported options are: + # + # [:indentation] Number of space characters used to indent. + # Acceptable value should be in 0..9 range, + # otherwise option is ignored. + # + # Default: 2. + # [:line_width] Max character to wrap line at. + # + # Default: 0 (meaning "wrap at 81"). + # [:canonical] Write "canonical" YAML form (very verbose, yet + # strictly formal). + # + # Default: false. + # [:header] Write %YAML [version] at the beginning of document. + # + # Default: false. + # + # Example: + # + # # Dump an array, get back a YAML string + # Psych.dump(['a', 'b']) # => "---\n- a\n- b\n" + # + # # Dump an array to an IO object + # Psych.dump(['a', 'b'], StringIO.new) # => # + # + # # Dump an array with indentation set + # Psych.dump(['a', ['b']], indentation: 3) # => "---\n- a\n- - b\n" + # + # # Dump an array to an IO with indentation set + # Psych.dump(['a', ['b']], StringIO.new, indentation: 3) + # + # source://psych//psych.rb#505 + def dump(o, io = T.unsafe(nil), options = T.unsafe(nil)); end + + # Dump a list of objects as separate documents to a document stream. + # + # Example: + # + # Psych.dump_stream("foo\n ", {}) # => "--- ! \"foo\\n \"\n--- {}\n" + # + # source://psych//psych.rb#595 + def dump_stream(*objects); end + + # source://psych//psych.rb#716 + def dump_tags; end + + # source://psych//psych.rb#728 + def dump_tags=(value); end + + # Load +yaml+ in to a Ruby data structure. If multiple documents are + # provided, the object contained in the first document will be returned. + # +filename+ will be used in the exception message if any exception + # is raised while parsing. If +yaml+ is empty, it returns + # the specified +fallback+ return value, which defaults to +false+. + # + # Raises a Psych::SyntaxError when a YAML syntax error is detected. + # + # Example: + # + # Psych.load("--- a") # => 'a' + # Psych.load("---\n - a\n - b") # => ['a', 'b'] + # + # begin + # Psych.load("--- `", filename: "file.txt") + # rescue Psych::SyntaxError => ex + # ex.file # => 'file.txt' + # ex.message # => "(file.txt): found character that cannot start any token" + # end + # + # When the optional +symbolize_names+ keyword argument is set to a + # true value, returns symbols for keys in Hash objects (default: strings). + # + # Psych.load("---\n foo: bar") # => {"foo"=>"bar"} + # Psych.load("---\n foo: bar", symbolize_names: true) # => {:foo=>"bar"} + # + # Raises a TypeError when `yaml` parameter is NilClass. This method is + # similar to `safe_load` except that `Symbol` objects are allowed by default. + # + # source://psych//psych.rb#368 + def load(yaml, permitted_classes: T.unsafe(nil), permitted_symbols: T.unsafe(nil), aliases: T.unsafe(nil), filename: T.unsafe(nil), fallback: T.unsafe(nil), symbolize_names: T.unsafe(nil), freeze: T.unsafe(nil), strict_integer: T.unsafe(nil)); end + + # Load multiple documents given in +yaml+. Returns the parsed documents + # as a list. If a block is given, each document will be converted to Ruby + # and passed to the block during parsing + # + # Example: + # + # Psych.load_stream("--- foo\n...\n--- bar\n...") # => ['foo', 'bar'] + # + # list = [] + # Psych.load_stream("--- foo\n...\n--- bar\n...") do |ruby| + # list << ruby + # end + # list # => ['foo', 'bar'] + # + # source://psych//psych.rb#626 + def load_stream(yaml, filename: T.unsafe(nil), fallback: T.unsafe(nil), **kwargs); end + + # source://psych//psych.rb#712 + def load_tags; end + + # source://psych//psych.rb#724 + def load_tags=(value); end + + # Parse a YAML string in +yaml+. Returns the Psych::Nodes::Document. + # +filename+ is used in the exception message if a Psych::SyntaxError is + # raised. + # + # Raises a Psych::SyntaxError when a YAML syntax error is detected. + # + # Example: + # + # Psych.parse("---\n - a\n - b") # => # + # + # begin + # Psych.parse("--- `", filename: "file.txt") + # rescue Psych::SyntaxError => ex + # ex.file # => 'file.txt' + # ex.message # => "(file.txt): found character that cannot start any token" + # end + # + # See Psych::Nodes for more information about YAML AST. + # + # source://psych//psych.rb#398 + def parse(yaml, filename: T.unsafe(nil)); end + + # Parse a file at +filename+. Returns the Psych::Nodes::Document. + # + # Raises a Psych::SyntaxError when a YAML syntax error is detected. + # + # source://psych//psych.rb#410 + def parse_file(filename, fallback: T.unsafe(nil)); end + + # Parse a YAML string in +yaml+. Returns the Psych::Nodes::Stream. + # This method can handle multiple YAML documents contained in +yaml+. + # +filename+ is used in the exception message if a Psych::SyntaxError is + # raised. + # + # If a block is given, a Psych::Nodes::Document node will be yielded to the + # block as it's being parsed. + # + # Raises a Psych::SyntaxError when a YAML syntax error is detected. + # + # Example: + # + # Psych.parse_stream("---\n - a\n - b") # => # + # + # Psych.parse_stream("--- a\n--- b") do |node| + # node # => # + # end + # + # begin + # Psych.parse_stream("--- `", filename: "file.txt") + # rescue Psych::SyntaxError => ex + # ex.file # => 'file.txt' + # ex.message # => "(file.txt): found character that cannot start any token" + # end + # + # Raises a TypeError when NilClass is passed. + # + # See Psych::Nodes for more information about YAML AST. + # + # source://psych//psych.rb#452 + def parse_stream(yaml, filename: T.unsafe(nil), &block); end + + # Returns a default parser + # + # source://psych//psych.rb#419 + def parser; end + + # source://psych//psych.rb#688 + def remove_type(type_tag); end + + # call-seq: + # Psych.safe_dump(o) -> string of yaml + # Psych.safe_dump(o, options) -> string of yaml + # Psych.safe_dump(o, io) -> io object passed in + # Psych.safe_dump(o, io, options) -> io object passed in + # + # Safely dump Ruby object +o+ to a YAML string. Optional +options+ may be passed in + # to control the output format. If an IO object is passed in, the YAML will + # be dumped to that IO object. By default, only the following + # classes are allowed to be serialized: + # + # * TrueClass + # * FalseClass + # * NilClass + # * Integer + # * Float + # * String + # * Array + # * Hash + # + # Arbitrary classes can be allowed by adding those classes to the +permitted_classes+ + # keyword argument. They are additive. For example, to allow Date serialization: + # + # Psych.safe_dump(yaml, permitted_classes: [Date]) + # + # Now the Date class can be dumped in addition to the classes listed above. + # + # A Psych::DisallowedClass exception will be raised if the object contains a + # class that isn't in the +permitted_classes+ list. + # + # Currently supported options are: + # + # [:indentation] Number of space characters used to indent. + # Acceptable value should be in 0..9 range, + # otherwise option is ignored. + # + # Default: 2. + # [:line_width] Max character to wrap line at. + # + # Default: 0 (meaning "wrap at 81"). + # [:canonical] Write "canonical" YAML form (very verbose, yet + # strictly formal). + # + # Default: false. + # [:header] Write %YAML [version] at the beginning of document. + # + # Default: false. + # + # Example: + # + # # Dump an array, get back a YAML string + # Psych.safe_dump(['a', 'b']) # => "---\n- a\n- b\n" + # + # # Dump an array to an IO object + # Psych.safe_dump(['a', 'b'], StringIO.new) # => # + # + # # Dump an array with indentation set + # Psych.safe_dump(['a', ['b']], indentation: 3) # => "---\n- a\n- - b\n" + # + # # Dump an array to an IO with indentation set + # Psych.safe_dump(['a', ['b']], StringIO.new, indentation: 3) + # + # source://psych//psych.rb#578 + def safe_dump(o, io = T.unsafe(nil), options = T.unsafe(nil)); end + + # Safely load the yaml string in +yaml+. By default, only the following + # classes are allowed to be deserialized: + # + # * TrueClass + # * FalseClass + # * NilClass + # * Integer + # * Float + # * String + # * Array + # * Hash + # + # Recursive data structures are not allowed by default. Arbitrary classes + # can be allowed by adding those classes to the +permitted_classes+ keyword argument. They are + # additive. For example, to allow Date deserialization: + # + # Psych.safe_load(yaml, permitted_classes: [Date]) + # + # Now the Date class can be loaded in addition to the classes listed above. + # + # Aliases can be explicitly allowed by changing the +aliases+ keyword argument. + # For example: + # + # x = [] + # x << x + # yaml = Psych.dump x + # Psych.safe_load yaml # => raises an exception + # Psych.safe_load yaml, aliases: true # => loads the aliases + # + # A Psych::DisallowedClass exception will be raised if the yaml contains a + # class that isn't in the +permitted_classes+ list. + # + # A Psych::AliasesNotEnabled exception will be raised if the yaml contains aliases + # but the +aliases+ keyword argument is set to false. + # + # +filename+ will be used in the exception message if any exception is raised + # while parsing. + # + # When the optional +symbolize_names+ keyword argument is set to a + # true value, returns symbols for keys in Hash objects (default: strings). + # + # Psych.safe_load("---\n foo: bar") # => {"foo"=>"bar"} + # Psych.safe_load("---\n foo: bar", symbolize_names: true) # => {:foo=>"bar"} + # + # source://psych//psych.rb#322 + def safe_load(yaml, permitted_classes: T.unsafe(nil), permitted_symbols: T.unsafe(nil), aliases: T.unsafe(nil), filename: T.unsafe(nil), fallback: T.unsafe(nil), symbolize_names: T.unsafe(nil), freeze: T.unsafe(nil), strict_integer: T.unsafe(nil)); end + + # Safely loads the document contained in +filename+. Returns the yaml contained in + # +filename+ as a Ruby object, or if the file is empty, it returns + # the specified +fallback+ return value, which defaults to +false+. + # See safe_load for options. + # + # source://psych//psych.rb#658 + def safe_load_file(filename, **kwargs); end + + # Dump Ruby +object+ to a JSON string. + # + # source://psych//psych.rb#605 + def to_json(object); end + + # Load +yaml+ in to a Ruby data structure. If multiple documents are + # provided, the object contained in the first document will be returned. + # +filename+ will be used in the exception message if any exception + # is raised while parsing. If +yaml+ is empty, it returns + # the specified +fallback+ return value, which defaults to +false+. + # + # Raises a Psych::SyntaxError when a YAML syntax error is detected. + # + # Example: + # + # Psych.unsafe_load("--- a") # => 'a' + # Psych.unsafe_load("---\n - a\n - b") # => ['a', 'b'] + # + # begin + # Psych.unsafe_load("--- `", filename: "file.txt") + # rescue Psych::SyntaxError => ex + # ex.file # => 'file.txt' + # ex.message # => "(file.txt): found character that cannot start any token" + # end + # + # When the optional +symbolize_names+ keyword argument is set to a + # true value, returns symbols for keys in Hash objects (default: strings). + # + # Psych.unsafe_load("---\n foo: bar") # => {"foo"=>"bar"} + # Psych.unsafe_load("---\n foo: bar", symbolize_names: true) # => {:foo=>"bar"} + # + # Raises a TypeError when `yaml` parameter is NilClass + # + # NOTE: This method *should not* be used to parse untrusted documents, such as + # YAML documents that are supplied via user input. Instead, please use the + # load method or the safe_load method. + # + # source://psych//psych.rb#271 + def unsafe_load(yaml, filename: T.unsafe(nil), fallback: T.unsafe(nil), symbolize_names: T.unsafe(nil), freeze: T.unsafe(nil), strict_integer: T.unsafe(nil)); end + end +end + +# Subclasses `BadAlias` for backwards compatibility +class Psych::AliasesNotEnabled < ::Psych::BadAlias + # @return [AliasesNotEnabled] a new instance of AliasesNotEnabled + # + # source://psych//psych/exception.rb#11 + def initialize; end +end + +# Subclasses `BadAlias` for backwards compatibility +class Psych::AnchorNotDefined < ::Psych::BadAlias + # @return [AnchorNotDefined] a new instance of AnchorNotDefined + # + # source://psych//psych/exception.rb#18 + def initialize(anchor_name); end +end + +class Psych::ClassLoader + # @return [ClassLoader] a new instance of ClassLoader + # + # source://psych//psych/class_loader.rb#21 + def initialize; end + + # source://psych//psych/class_loader.rb#39 + def big_decimal; end + + # source://psych//psych/class_loader.rb#39 + def complex; end + + # source://psych//psych/class_loader.rb#39 + def date; end + + # source://psych//psych/class_loader.rb#39 + def date_time; end + + # source://psych//psych/class_loader.rb#39 + def exception; end + + # source://psych//psych/class_loader.rb#25 + def load(klassname); end + + # source://psych//psych/class_loader.rb#39 + def object; end + + # source://psych//psych/class_loader.rb#39 + def psych_omap; end + + # source://psych//psych/class_loader.rb#39 + def psych_set; end + + # source://psych//psych/class_loader.rb#39 + def range; end + + # source://psych//psych/class_loader.rb#39 + def rational; end + + # source://psych//psych/class_loader.rb#39 + def regexp; end + + # source://psych//psych/class_loader.rb#39 + def struct; end + + # source://psych//psych/class_loader.rb#39 + def symbol; end + + # source://psych//psych/class_loader.rb#31 + def symbolize(sym); end + + private + + # source://psych//psych/class_loader.rb#47 + def find(klassname); end + + # source://psych//psych/class_loader.rb#51 + def resolve(klassname); end +end + +class Psych::ClassLoader::Restricted < ::Psych::ClassLoader + # @return [Restricted] a new instance of Restricted + # + # source://psych//psych/class_loader.rb#77 + def initialize(classes, symbols); end + + # source://psych//psych/class_loader.rb#83 + def symbolize(sym); end + + private + + # source://psych//psych/class_loader.rb#95 + def find(klassname); end +end + +# If an object defines +encode_with+, then an instance of Psych::Coder will +# be passed to the method when the object is being serialized. The Coder +# automatically assumes a Psych::Nodes::Mapping is being emitted. Other +# objects like Sequence and Scalar may be emitted if +seq=+ or +scalar=+ are +# called, respectively. +class Psych::Coder + # @return [Coder] a new instance of Coder + # + # source://psych//psych/coder.rb#13 + def initialize(tag); end + + # source://psych//psych/coder.rb#84 + def [](k); end + + # source://psych//psych/coder.rb#78 + def []=(k, v); end + + # source://psych//psych/coder.rb#78 + def add(k, v); end + + # Returns the value of attribute implicit. + # + # source://psych//psych/coder.rb#10 + def implicit; end + + # Sets the attribute implicit + # + # @param value the value to set the attribute implicit to. + # + # source://psych//psych/coder.rb#10 + def implicit=(_arg0); end + + # Emit a map. The coder will be yielded to the block. + # + # @yield [_self] + # @yieldparam _self [Psych::Coder] the object that the method was called on + # + # source://psych//psych/coder.rb#34 + def map(tag = T.unsafe(nil), style = T.unsafe(nil)); end + + # Emit a map with +value+ + # + # source://psych//psych/coder.rb#73 + def map=(map); end + + # Returns the value of attribute object. + # + # source://psych//psych/coder.rb#10 + def object; end + + # Sets the attribute object + # + # @param value the value to set the attribute object to. + # + # source://psych//psych/coder.rb#10 + def object=(_arg0); end + + # Emit a sequence with +map+ and +tag+ + # + # source://psych//psych/coder.rb#54 + def represent_map(tag, map); end + + # Emit an arbitrary object +obj+ and +tag+ + # + # source://psych//psych/coder.rb#60 + def represent_object(tag, obj); end + + # Emit a scalar with +value+ and +tag+ + # + # source://psych//psych/coder.rb#42 + def represent_scalar(tag, value); end + + # Emit a sequence with +list+ and +tag+ + # + # source://psych//psych/coder.rb#48 + def represent_seq(tag, list); end + + # source://psych//psych/coder.rb#24 + def scalar(*args); end + + # Emit a scalar with +value+ + # + # source://psych//psych/coder.rb#67 + def scalar=(value); end + + # Returns the value of attribute seq. + # + # source://psych//psych/coder.rb#11 + def seq; end + + # Emit a sequence of +list+ + # + # source://psych//psych/coder.rb#90 + def seq=(list); end + + # Returns the value of attribute style. + # + # source://psych//psych/coder.rb#10 + def style; end + + # Sets the attribute style + # + # @param value the value to set the attribute style to. + # + # source://psych//psych/coder.rb#10 + def style=(_arg0); end + + # Returns the value of attribute tag. + # + # source://psych//psych/coder.rb#10 + def tag; end + + # Sets the attribute tag + # + # @param value the value to set the attribute tag to. + # + # source://psych//psych/coder.rb#10 + def tag=(_arg0); end + + # Returns the value of attribute type. + # + # source://psych//psych/coder.rb#11 + def type; end +end + +class Psych::DisallowedClass < ::Psych::Exception + # @return [DisallowedClass] a new instance of DisallowedClass + # + # source://psych//psych/exception.rb#24 + def initialize(action, klass_name); end +end + +# Psych::Handler is an abstract base class that defines the events used +# when dealing with Psych::Parser. Clients who want to use Psych::Parser +# should implement a class that inherits from Psych::Handler and define +# events that they can handle. +# +# Psych::Handler defines all events that Psych::Parser can possibly send to +# event handlers. +# +# See Psych::Parser for more details +class Psych::Handler + # Called when an alias is found to +anchor+. +anchor+ will be the name + # of the anchor found. + # + # === Example + # + # Here we have an example of an array that references itself in YAML: + # + # --- &ponies + # - first element + # - *ponies + # + # &ponies is the anchor, *ponies is the alias. In this case, alias is + # called with "ponies". + # + # source://psych//psych/handler.rb#110 + def alias(anchor); end + + # Called when an empty event happens. (Which, as far as I can tell, is + # never). + # + # source://psych//psych/handler.rb#236 + def empty; end + + # Called with the document ends. +implicit+ is a boolean value indicating + # whether or not the document has an implicit ending. + # + # === Example + # + # Given the following YAML: + # + # --- + # hello world + # + # +implicit+ will be true. Given this YAML: + # + # --- + # hello world + # ... + # + # +implicit+ will be false. + # + # source://psych//psych/handler.rb#93 + def end_document(implicit); end + + # Called when a map ends + # + # source://psych//psych/handler.rb#230 + def end_mapping; end + + # Called when a sequence ends. + # + # source://psych//psych/handler.rb#191 + def end_sequence; end + + # Called when the YAML stream ends + # + # source://psych//psych/handler.rb#241 + def end_stream; end + + # Called before each event with line/column information. + # + # source://psych//psych/handler.rb#246 + def event_location(start_line, start_column, end_line, end_column); end + + # Called when a scalar +value+ is found. The scalar may have an + # +anchor+, a +tag+, be implicitly +plain+ or implicitly +quoted+ + # + # +value+ is the string value of the scalar + # +anchor+ is an associated anchor or nil + # +tag+ is an associated tag or nil + # +plain+ is a boolean value + # +quoted+ is a boolean value + # +style+ is an integer indicating the string style + # + # See the constants in Psych::Nodes::Scalar for the possible values of + # +style+ + # + # === Example + # + # Here is a YAML document that exercises most of the possible ways this + # method can be called: + # + # --- + # - !str "foo" + # - &anchor fun + # - many + # lines + # - | + # many + # newlines + # + # The above YAML document contains a list with four strings. Here are + # the parameters sent to this method in the same order: + # + # # value anchor tag plain quoted style + # ["foo", nil, "!str", false, false, 3 ] + # ["fun", "anchor", nil, true, false, 1 ] + # ["many lines", nil, nil, true, false, 1 ] + # ["many\nnewlines\n", nil, nil, false, true, 4 ] + # + # source://psych//psych/handler.rb#150 + def scalar(value, anchor, tag, plain, quoted, style); end + + # Called when the document starts with the declared +version+, + # +tag_directives+, if the document is +implicit+. + # + # +version+ will be an array of integers indicating the YAML version being + # dealt with, +tag_directives+ is a list of tuples indicating the prefix + # and suffix of each tag, and +implicit+ is a boolean indicating whether + # the document is started implicitly. + # + # === Example + # + # Given the following YAML: + # + # %YAML 1.1 + # %TAG ! tag:tenderlovemaking.com,2009: + # --- !squee + # + # The parameters for start_document must be this: + # + # version # => [1, 1] + # tag_directives # => [["!", "tag:tenderlovemaking.com,2009:"]] + # implicit # => false + # + # source://psych//psych/handler.rb#72 + def start_document(version, tag_directives, implicit); end + + # Called when a map starts. + # + # +anchor+ is the anchor associated with the map or +nil+. + # +tag+ is the tag associated with the map or +nil+. + # +implicit+ is a boolean indicating whether or not the map was implicitly + # started. + # +style+ is an integer indicating the mapping style. + # + # See the constants in Psych::Nodes::Mapping for the possible values of + # +style+. + # + # === Example + # + # Here is a YAML document that exercises most of the possible ways this + # method can be called: + # + # --- + # k: !!map { hello: world } + # v: &pewpew + # hello: world + # + # The above YAML document consists of three maps, an outer map that contains + # two inner maps. Below is a matrix of the parameters sent in order to + # represent these three maps: + # + # # anchor tag implicit style + # [nil, nil, true, 1 ] + # [nil, "tag:yaml.org,2002:map", false, 2 ] + # ["pewpew", nil, true, 1 ] + # + # source://psych//psych/handler.rb#225 + def start_mapping(anchor, tag, implicit, style); end + + # Called when a sequence is started. + # + # +anchor+ is the anchor associated with the sequence or nil. + # +tag+ is the tag associated with the sequence or nil. + # +implicit+ a boolean indicating whether or not the sequence was implicitly + # started. + # +style+ is an integer indicating the list style. + # + # See the constants in Psych::Nodes::Sequence for the possible values of + # +style+. + # + # === Example + # + # Here is a YAML document that exercises most of the possible ways this + # method can be called: + # + # --- + # - !!seq [ + # a + # ] + # - &pewpew + # - b + # + # The above YAML document consists of three lists, an outer list that + # contains two inner lists. Here is a matrix of the parameters sent + # to represent these lists: + # + # # anchor tag implicit style + # [nil, nil, true, 1 ] + # [nil, "tag:yaml.org,2002:seq", false, 2 ] + # ["pewpew", nil, true, 1 ] + # + # source://psych//psych/handler.rb#186 + def start_sequence(anchor, tag, implicit, style); end + + # Called with +encoding+ when the YAML stream starts. This method is + # called once per stream. A stream may contain multiple documents. + # + # See the constants in Psych::Parser for the possible values of +encoding+. + # + # source://psych//psych/handler.rb#47 + def start_stream(encoding); end + + # Is this handler a streaming handler? + # + # @return [Boolean] + # + # source://psych//psych/handler.rb#251 + def streaming?; end +end + +# Configuration options for dumping YAML. +class Psych::Handler::DumperOptions + # @return [DumperOptions] a new instance of DumperOptions + # + # source://psych//psych/handler.rb#19 + def initialize; end + + # Returns the value of attribute canonical. + # + # source://psych//psych/handler.rb#17 + def canonical; end + + # Sets the attribute canonical + # + # @param value the value to set the attribute canonical to. + # + # source://psych//psych/handler.rb#17 + def canonical=(_arg0); end + + # Returns the value of attribute indentation. + # + # source://psych//psych/handler.rb#17 + def indentation; end + + # Sets the attribute indentation + # + # @param value the value to set the attribute indentation to. + # + # source://psych//psych/handler.rb#17 + def indentation=(_arg0); end + + # Returns the value of attribute line_width. + # + # source://psych//psych/handler.rb#17 + def line_width; end + + # Sets the attribute line_width + # + # @param value the value to set the attribute line_width to. + # + # source://psych//psych/handler.rb#17 + def line_width=(_arg0); end +end + +class Psych::JSON::Stream < ::Psych::Visitors::JSONTree + include ::Psych::Streaming + extend ::Psych::Streaming::ClassMethods +end + +# YAML event parser class. This class parses a YAML document and calls +# events on the handler that is passed to the constructor. The events can +# be used for things such as constructing a YAML AST or deserializing YAML +# documents. It can even be fed back to Psych::Emitter to emit the same +# document that was parsed. +# +# See Psych::Handler for documentation on the events that Psych::Parser emits. +# +# Here is an example that prints out ever scalar found in a YAML document: +# +# # Handler for detecting scalar values +# class ScalarHandler < Psych::Handler +# def scalar value, anchor, tag, plain, quoted, style +# puts value +# end +# end +# +# parser = Psych::Parser.new(ScalarHandler.new) +# parser.parse(yaml_document) +# +# Here is an example that feeds the parser back in to Psych::Emitter. The +# YAML document is read from STDIN and written back out to STDERR: +# +# parser = Psych::Parser.new(Psych::Emitter.new($stderr)) +# parser.parse($stdin) +# +# Psych uses Psych::Parser in combination with Psych::TreeBuilder to +# construct an AST of the parsed YAML document. +class Psych::Parser + # Creates a new Psych::Parser instance with +handler+. YAML events will + # be called on +handler+. See Psych::Parser for more details. + # + # @return [Parser] a new instance of Parser + # + # source://psych//psych/parser.rb#47 + def initialize(handler = T.unsafe(nil)); end + + # Set the encoding for this parser to +encoding+ + # + # source://psych//psych/parser.rb#41 + def external_encoding=(_arg0); end + + # The handler on which events will be called + # + # source://psych//psych/parser.rb#38 + def handler; end + + # The handler on which events will be called + # + # source://psych//psych/parser.rb#38 + def handler=(_arg0); end + + # call-seq: + # parser.parse(yaml) + # + # Parse the YAML document contained in +yaml+. Events will be called on + # the handler set on the parser instance. + # + # See Psych::Parser and Psych::Parser#handler + # + # source://psych//psych/parser.rb#61 + def parse(yaml, path = T.unsafe(nil)); end +end + +# Scan scalars for built in types +class Psych::ScalarScanner + # Create a new scanner + # + # @return [ScalarScanner] a new instance of ScalarScanner + # + # source://psych//psych/scalar_scanner.rb#30 + def initialize(class_loader, strict_integer: T.unsafe(nil)); end + + # Returns the value of attribute class_loader. + # + # source://psych//psych/scalar_scanner.rb#27 + def class_loader; end + + # Parse and return an int from +string+ + # + # source://psych//psych/scalar_scanner.rb#109 + def parse_int(string); end + + # Parse and return a Time from +string+ + # + # source://psych//psych/scalar_scanner.rb#115 + def parse_time(string); end + + # Tokenize +string+ returning the Ruby object + # + # source://psych//psych/scalar_scanner.rb#37 + def tokenize(string); end +end + +# Same as above, but allows commas. +# Not to YML spec, but kept for backwards compatibility +# +# source://psych//psych/scalar_scanner.rb#22 +Psych::ScalarScanner::INTEGER_LEGACY = T.let(T.unsafe(nil), Regexp) + +# Taken from http://yaml.org/type/int.html +# +# source://psych//psych/scalar_scanner.rb#15 +Psych::ScalarScanner::INTEGER_STRICT = T.let(T.unsafe(nil), Regexp) + +# Psych::Stream is a streaming YAML emitter. It will not buffer your YAML, +# but send it straight to an IO. +# +# Here is an example use: +# +# stream = Psych::Stream.new($stdout) +# stream.start +# stream.push({:foo => 'bar'}) +# stream.finish +# +# YAML will be immediately emitted to $stdout with no buffering. +# +# Psych::Stream#start will take a block and ensure that Psych::Stream#finish +# is called, so you can do this form: +# +# stream = Psych::Stream.new($stdout) +# stream.start do |em| +# em.push(:foo => 'bar') +# end +class Psych::Stream < ::Psych::Visitors::YAMLTree + include ::Psych::Streaming + extend ::Psych::Streaming::ClassMethods +end + +class Psych::Stream::Emitter < ::Psych::Emitter + # source://psych//psych/stream.rb#26 + def end_document(implicit_end = T.unsafe(nil)); end + + # @return [Boolean] + # + # source://psych//psych/stream.rb#30 + def streaming?; end +end + +module Psych::Streaming + # Start streaming using +encoding+ + # + # source://psych//psych/streaming.rb#18 + def start(encoding = T.unsafe(nil)); end + + private + + # source://psych//psych/streaming.rb#25 + def register(target, obj); end +end + +module Psych::Streaming::ClassMethods + # Create a new streaming emitter. Emitter will print to +io+. See + # Psych::Stream for an example. + # + # source://psych//psych/streaming.rb#8 + def new(io); end +end + +class Psych::SyntaxError < ::Psych::Exception + # @return [SyntaxError] a new instance of SyntaxError + # + # source://psych//psych/syntax_error.rb#8 + def initialize(file, line, col, offset, problem, context); end + + # Returns the value of attribute column. + # + # source://psych//psych/syntax_error.rb#6 + def column; end + + # Returns the value of attribute context. + # + # source://psych//psych/syntax_error.rb#6 + def context; end + + # Returns the value of attribute file. + # + # source://psych//psych/syntax_error.rb#6 + def file; end + + # Returns the value of attribute line. + # + # source://psych//psych/syntax_error.rb#6 + def line; end + + # Returns the value of attribute offset. + # + # source://psych//psych/syntax_error.rb#6 + def offset; end + + # Returns the value of attribute problem. + # + # source://psych//psych/syntax_error.rb#6 + def problem; end +end + +# This class works in conjunction with Psych::Parser to build an in-memory +# parse tree that represents a YAML document. +# +# == Example +# +# parser = Psych::Parser.new Psych::TreeBuilder.new +# parser.parse('--- foo') +# tree = parser.handler.root +# +# See Psych::Handler for documentation on the event methods used in this +# class. +class Psych::TreeBuilder < ::Psych::Handler + # Create a new TreeBuilder instance + # + # @return [TreeBuilder] a new instance of TreeBuilder + # + # source://psych//psych/tree_builder.rb#22 + def initialize; end + + # source://psych//psych/tree_builder.rb#103 + def alias(anchor); end + + # Handles end_document events with +version+, +tag_directives+, + # and +implicit+ styling. + # + # See Psych::Handler#start_document + # + # source://psych//psych/tree_builder.rb#77 + def end_document(implicit_end = T.unsafe(nil)); end + + # source://psych//psych/tree_builder.rb#52 + def end_mapping; end + + # source://psych//psych/tree_builder.rb#52 + def end_sequence; end + + # source://psych//psych/tree_builder.rb#90 + def end_stream; end + + # source://psych//psych/tree_builder.rb#33 + def event_location(start_line, start_column, end_line, end_column); end + + # Returns the root node for the built tree + # + # source://psych//psych/tree_builder.rb#19 + def root; end + + # source://psych//psych/tree_builder.rb#96 + def scalar(value, anchor, tag, plain, quoted, style); end + + # Handles start_document events with +version+, +tag_directives+, + # and +implicit+ styling. + # + # See Psych::Handler#start_document + # + # source://psych//psych/tree_builder.rb#65 + def start_document(version, tag_directives, implicit); end + + # source://psych//psych/tree_builder.rb#45 + def start_mapping(anchor, tag, implicit, style); end + + # source://psych//psych/tree_builder.rb#45 + def start_sequence(anchor, tag, implicit, style); end + + # source://psych//psych/tree_builder.rb#84 + def start_stream(encoding); end + + private + + # source://psych//psych/tree_builder.rb#116 + def pop; end + + # source://psych//psych/tree_builder.rb#111 + def push(value); end + + # source://psych//psych/tree_builder.rb#132 + def set_end_location(node); end + + # source://psych//psych/tree_builder.rb#122 + def set_location(node); end + + # source://psych//psych/tree_builder.rb#127 + def set_start_location(node); end +end + +# The version of Psych you are using +# +# source://psych//psych/versions.rb#5 +Psych::VERSION = T.let(T.unsafe(nil), String) + +class Psych::Visitors::DepthFirst < ::Psych::Visitors::Visitor + # @return [DepthFirst] a new instance of DepthFirst + # + # source://psych//psych/visitors/depth_first.rb#5 + def initialize(block); end + + private + + # source://psych//psych/visitors/depth_first.rb#11 + def nary(o); end + + # source://psych//psych/visitors/depth_first.rb#20 + def terminal(o); end + + # source://psych//psych/visitors/depth_first.rb#20 + def visit_Psych_Nodes_Alias(o); end + + # source://psych//psych/visitors/depth_first.rb#11 + def visit_Psych_Nodes_Document(o); end + + # source://psych//psych/visitors/depth_first.rb#11 + def visit_Psych_Nodes_Mapping(o); end + + # source://psych//psych/visitors/depth_first.rb#20 + def visit_Psych_Nodes_Scalar(o); end + + # source://psych//psych/visitors/depth_first.rb#11 + def visit_Psych_Nodes_Sequence(o); end + + # source://psych//psych/visitors/depth_first.rb#11 + def visit_Psych_Nodes_Stream(o); end +end + +class Psych::Visitors::RestrictedYAMLTree < ::Psych::Visitors::YAMLTree + # @return [RestrictedYAMLTree] a new instance of RestrictedYAMLTree + # + # source://psych//psych/visitors/yaml_tree.rb#552 + def initialize(emitter, ss, options); end + + # source://psych//psych/visitors/yaml_tree.rb#565 + def accept(target); end + + # source://psych//psych/visitors/yaml_tree.rb#577 + def visit_Symbol(sym); end +end + +# source://psych//psych/visitors/yaml_tree.rb#541 +Psych::Visitors::RestrictedYAMLTree::DEFAULT_PERMITTED_CLASSES = T.let(T.unsafe(nil), Hash) + +# This class walks a YAML AST, converting each node to Ruby +class Psych::Visitors::ToRuby < ::Psych::Visitors::Visitor + # @return [ToRuby] a new instance of ToRuby + # + # source://psych//psych/visitors/to_ruby.rb#23 + def initialize(ss, class_loader, symbolize_names: T.unsafe(nil), freeze: T.unsafe(nil)); end + + # source://psych//psych/visitors/to_ruby.rb#34 + def accept(target); end + + # Returns the value of attribute class_loader. + # + # source://psych//psych/visitors/to_ruby.rb#21 + def class_loader; end + + # source://psych//psych/visitors/to_ruby.rb#327 + def visit_Psych_Nodes_Alias(o); end + + # source://psych//psych/visitors/to_ruby.rb#319 + def visit_Psych_Nodes_Document(o); end + + # source://psych//psych/visitors/to_ruby.rb#165 + def visit_Psych_Nodes_Mapping(o); end + + # source://psych//psych/visitors/to_ruby.rb#129 + def visit_Psych_Nodes_Scalar(o); end + + # source://psych//psych/visitors/to_ruby.rb#133 + def visit_Psych_Nodes_Sequence(o); end + + # source://psych//psych/visitors/to_ruby.rb#323 + def visit_Psych_Nodes_Stream(o); end + + private + + # source://psych//psych/visitors/to_ruby.rb#395 + def deduplicate(key); end + + # source://psych//psych/visitors/to_ruby.rb#51 + def deserialize(o); end + + # source://psych//psych/visitors/to_ruby.rb#412 + def init_with(o, h, node); end + + # source://psych//psych/visitors/to_ruby.rb#404 + def merge_key(hash, key, val); end + + # source://psych//psych/visitors/to_ruby.rb#333 + def register(node, object); end + + # source://psych//psych/visitors/to_ruby.rb#338 + def register_empty(object); end + + # Convert +klassname+ to a Class + # + # source://psych//psych/visitors/to_ruby.rb#425 + def resolve_class(klassname); end + + # source://psych//psych/visitors/to_ruby.rb#407 + def revive(klass, node); end + + # source://psych//psych/visitors/to_ruby.rb#344 + def revive_hash(hash, o, tagged = T.unsafe(nil)); end + + class << self + # source://psych//psych/visitors/to_ruby.rb#15 + def create(symbolize_names: T.unsafe(nil), freeze: T.unsafe(nil), strict_integer: T.unsafe(nil)); end + end +end + +class Psych::Visitors::Visitor + # source://psych//psych/visitors/visitor.rb#5 + def accept(target); end + + private + + # source://psych//psych/visitors/visitor.rb#19 + def dispatch; end + + # source://psych//psych/visitors/visitor.rb#29 + def visit(target); end + + class << self + # @api private + # + # source://psych//psych/visitors/visitor.rb#12 + def dispatch_cache; end + end +end + +# YAMLTree builds a YAML ast given a Ruby object. For example: +# +# builder = Psych::Visitors::YAMLTree.new +# builder << { :foo => 'bar' } +# builder.tree # => #", where @@ -1269,12 +1255,12 @@ end # # source://rack-cache//lib/rack/cache/request.rb#12 class Rack::Cache::Request < ::Rack::Request - # A CacheControl instance based on the request's Cache-Control header. + # A CacheControl instance based on the request's cache-control header. # # source://rack-cache//lib/rack/cache/request.rb#22 def cache_control; end - # True when the Cache-Control/no-cache directive is present or the + # True when the cache-control/no-cache directive is present or the # Pragma header is set to no-cache. # # @return [Boolean] @@ -1331,26 +1317,26 @@ class Rack::Cache::Response # source://rack-cache//lib/rack/cache/response.rb#25 def body=(_arg0); end - # A Hash of name=value pairs that correspond to the Cache-Control header. + # A Hash of name=value pairs that correspond to the cache-control header. # Valueless parameters (e.g., must-revalidate, no-store) have a Hash value - # of true. This method always returns a Hash, empty if no Cache-Control + # of true. This method always returns a Hash, empty if no cache-control # header is present. # # source://rack-cache//lib/rack/cache/response.rb#69 def cache_control; end - # Set the Cache-Control header to the values specified by the Hash. See + # Set the cache-control header to the values specified by the Hash. See # the #cache_control method for information on expected Hash structure. # # source://rack-cache//lib/rack/cache/response.rb#75 def cache_control=(value); end # Determine if the response is worth caching under any circumstance. Responses - # marked "private" with an explicit Cache-Control directive are considered + # marked "private" with an explicit cache-control directive are considered # uncacheable # - # Responses with neither a freshness lifetime (Expires, max-age) nor cache - # validator (Last-Modified, ETag) are considered uncacheable. + # Responses with neither a freshness lifetime (expires, max-age) nor cache + # validator (last-modified, etag) are considered uncacheable. # # @return [Boolean] # @@ -1358,7 +1344,7 @@ class Rack::Cache::Response def cacheable?; end # Set the response's time-to-live for private/client caches. This adjusts - # the Cache-Control/max-age directive. + # the cache-control/max-age directive. # # source://rack-cache//lib/rack/cache/response.rb#209 def client_ttl=(seconds); end @@ -1369,7 +1355,7 @@ class Rack::Cache::Response # source://rack-cache//lib/rack/cache/response.rb#139 def date; end - # The literal value of ETag HTTP header or nil if no ETag is specified. + # The literal value of etag HTTP header or nil if no etag is specified. # # source://rack-cache//lib/rack/cache/response.rb#220 def etag; end @@ -1380,14 +1366,14 @@ class Rack::Cache::Response # source://rack-cache//lib/rack/cache/response.rb#133 def expire!; end - # The value of the Expires header as a Time object. + # The value of the expires header as a Time object. # # source://rack-cache//lib/rack/cache/response.rb#169 def expires; end # Determine if the response is "fresh". Fresh responses may be served from # cache without any interaction with the origin. A response is considered - # fresh when it includes a Cache-Control/max-age indicator or Expiration + # fresh when it includes a cache-control/max-age indicator or Expiration # header and the calculated age is less than the freshness lifetime. # # @return [Boolean] @@ -1405,7 +1391,7 @@ class Rack::Cache::Response # source://rack-cache//lib/rack/cache/response.rb#25 def headers=(_arg0); end - # The String value of the Last-Modified header exactly as it appears + # The String value of the last-modified header exactly as it appears # in the response (i.e., no date parsing / conversion is performed). # # source://rack-cache//lib/rack/cache/response.rb#215 @@ -1421,7 +1407,7 @@ class Rack::Cache::Response def max_age; end # The number of seconds after which the response should no longer - # be considered fresh. Sets the Cache-Control max-age directive. + # be considered fresh. Sets the cache-control max-age directive. # # source://rack-cache//lib/rack/cache/response.rb#177 def max_age=(value); end @@ -1492,7 +1478,7 @@ class Rack::Cache::Response def ttl; end # Set the response's time-to-live for shared caches to the specified number - # of seconds. This adjusts the Cache-Control/s-maxage directive. + # of seconds. This adjusts the cache-control/s-maxage directive. # # source://rack-cache//lib/rack/cache/response.rb#203 def ttl=(seconds); end @@ -1505,20 +1491,20 @@ class Rack::Cache::Response # source://rack-cache//lib/rack/cache/response.rb#111 def validateable?; end - # The literal value of the Vary header, or nil when no header is present. + # The literal value of the vary header, or nil when no header is present. # # source://rack-cache//lib/rack/cache/response.rb#251 def vary; end - # Does the response include a Vary header? + # Does the response include a vary header? # # @return [Boolean] # # source://rack-cache//lib/rack/cache/response.rb#256 def vary?; end - # An array of header names given in the Vary header or an empty - # array when no Vary header is present. + # An array of header names given in the vary header or an empty + # array when no vary header is present. # # source://rack-cache//lib/rack/cache/response.rb#262 def vary_header_names; end @@ -1575,177 +1561,3 @@ class Rack::Cache::Storage def instance; end end end - -# source://rack/2.2.7/lib/rack.rb#43 -Rack::DELETE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#36 -Rack::ETAG = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#30 -Rack::EXPIRES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/file.rb#6 -Rack::File = Rack::Files - -# source://rack/2.2.7/lib/rack.rb#39 -Rack::GET = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#44 -Rack::HEAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#20 -Rack::HTTPS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#35 -Rack::HTTP_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#17 -Rack::HTTP_HOST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#18 -Rack::HTTP_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#19 -Rack::HTTP_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#46 -Rack::LINK = T.let(T.unsafe(nil), String) - -# source://rack-test/2.1.0/lib/rack/test.rb#381 -Rack::MockSession = Rack::Test::Session - -# source://rack/2.2.7/lib/rack.rb#45 -Rack::OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#42 -Rack::PATCH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#21 -Rack::PATH_INFO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#40 -Rack::POST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#41 -Rack::PUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#25 -Rack::QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#53 -Rack::RACK_ERRORS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#63 -Rack::RACK_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#65 -Rack::RACK_HIJACK_IO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#55 -Rack::RACK_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#64 -Rack::RACK_IS_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#54 -Rack::RACK_LOGGER = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#76 -Rack::RACK_METHODOVERRIDE_ORIGINAL_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#67 -Rack::RACK_MULTIPART_BUFFER_SIZE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#68 -Rack::RACK_MULTIPART_TEMPFILE_FACTORY = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#60 -Rack::RACK_MULTIPROCESS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#59 -Rack::RACK_MULTITHREAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#66 -Rack::RACK_RECURSIVE_INCLUDE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#72 -Rack::RACK_REQUEST_COOKIE_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#73 -Rack::RACK_REQUEST_COOKIE_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#70 -Rack::RACK_REQUEST_FORM_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#69 -Rack::RACK_REQUEST_FORM_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#71 -Rack::RACK_REQUEST_FORM_VARS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#74 -Rack::RACK_REQUEST_QUERY_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#75 -Rack::RACK_REQUEST_QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#61 -Rack::RACK_RUNONCE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#56 -Rack::RACK_SESSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#57 -Rack::RACK_SESSION_OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#77 -Rack::RACK_SESSION_UNPACKED_COOKIE_DATA = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#58 -Rack::RACK_SHOWSTATUS_DETAIL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#52 -Rack::RACK_TEMPFILES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#62 -Rack::RACK_URL_SCHEME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#51 -Rack::RACK_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#23 -Rack::RELEASE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#22 -Rack::REQUEST_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#23 -Rack::REQUEST_PATH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#24 -Rack::SCRIPT_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#27 -Rack::SERVER_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#28 -Rack::SERVER_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#26 -Rack::SERVER_PROTOCOL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#33 -Rack::SET_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#48 -Rack::TRACE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#34 -Rack::TRANSFER_ENCODING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#47 -Rack::UNLINK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#16 -Rack::VERSION = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/rack-openid@1.4.2.rbi b/sorbet/rbi/gems/rack-openid@1.4.2.rbi index 459440807..d88036c44 100644 --- a/sorbet/rbi/gems/rack-openid@1.4.2.rbi +++ b/sorbet/rbi/gems/rack-openid@1.4.2.rbi @@ -4,68 +4,18 @@ # This is an autogenerated file for types exported from the `rack-openid` gem. # Please instead update this file by running `bin/tapioca gem rack-openid`. + # source://rack-openid//lib/rack/openid.rb#11 module Rack class << self - # source://rack/2.2.7/lib/rack/version.rb#26 + # source://rack/2.2.9/lib/rack/version.rb#26 def release; end - # source://rack/2.2.7/lib/rack/version.rb#19 + # source://rack/2.2.9/lib/rack/version.rb#19 def version; end end end -# source://rack/2.2.7/lib/rack.rb#29 -Rack::CACHE_CONTROL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#31 -Rack::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#32 -Rack::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#43 -Rack::DELETE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#36 -Rack::ETAG = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#30 -Rack::EXPIRES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/file.rb#6 -Rack::File = Rack::Files - -# source://rack/2.2.7/lib/rack.rb#39 -Rack::GET = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#44 -Rack::HEAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#20 -Rack::HTTPS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#35 -Rack::HTTP_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#17 -Rack::HTTP_HOST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#18 -Rack::HTTP_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#19 -Rack::HTTP_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#46 -Rack::LINK = T.let(T.unsafe(nil), String) - -# source://rack-test/2.1.0/lib/rack/test.rb#381 -Rack::MockSession = Rack::Test::Session - -# source://rack/2.2.7/lib/rack.rb#45 -Rack::OPTIONS = T.let(T.unsafe(nil), String) - # A Rack middleware that provides a more HTTPish API around the # ruby-openid library. # @@ -201,135 +151,3 @@ Rack::OpenID::TimeoutResponse::STATUS = T.let(T.unsafe(nil), Symbol) # source://rack-openid//lib/rack/openid.rb#72 Rack::OpenID::URL_FIELD_SELECTOR = T.let(T.unsafe(nil), Proc) - -# source://rack/2.2.7/lib/rack.rb#42 -Rack::PATCH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#21 -Rack::PATH_INFO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#40 -Rack::POST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#41 -Rack::PUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#25 -Rack::QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#53 -Rack::RACK_ERRORS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#63 -Rack::RACK_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#65 -Rack::RACK_HIJACK_IO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#55 -Rack::RACK_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#64 -Rack::RACK_IS_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#54 -Rack::RACK_LOGGER = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#76 -Rack::RACK_METHODOVERRIDE_ORIGINAL_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#67 -Rack::RACK_MULTIPART_BUFFER_SIZE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#68 -Rack::RACK_MULTIPART_TEMPFILE_FACTORY = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#60 -Rack::RACK_MULTIPROCESS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#59 -Rack::RACK_MULTITHREAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#66 -Rack::RACK_RECURSIVE_INCLUDE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#72 -Rack::RACK_REQUEST_COOKIE_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#73 -Rack::RACK_REQUEST_COOKIE_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#70 -Rack::RACK_REQUEST_FORM_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#69 -Rack::RACK_REQUEST_FORM_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#71 -Rack::RACK_REQUEST_FORM_VARS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#74 -Rack::RACK_REQUEST_QUERY_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#75 -Rack::RACK_REQUEST_QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#61 -Rack::RACK_RUNONCE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#56 -Rack::RACK_SESSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#57 -Rack::RACK_SESSION_OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#77 -Rack::RACK_SESSION_UNPACKED_COOKIE_DATA = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#58 -Rack::RACK_SHOWSTATUS_DETAIL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#52 -Rack::RACK_TEMPFILES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#62 -Rack::RACK_URL_SCHEME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#51 -Rack::RACK_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#23 -Rack::RELEASE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#22 -Rack::REQUEST_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#23 -Rack::REQUEST_PATH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#24 -Rack::SCRIPT_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#27 -Rack::SERVER_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#28 -Rack::SERVER_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#26 -Rack::SERVER_PROTOCOL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#33 -Rack::SET_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#48 -Rack::TRACE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#34 -Rack::TRANSFER_ENCODING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#47 -Rack::UNLINK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#16 -Rack::VERSION = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/rack-protection@3.0.6.rbi b/sorbet/rbi/gems/rack-protection@3.2.0.rbi similarity index 84% rename from sorbet/rbi/gems/rack-protection@3.0.6.rbi rename to sorbet/rbi/gems/rack-protection@3.2.0.rbi index 77473082a..0832cf21e 100644 --- a/sorbet/rbi/gems/rack-protection@3.0.6.rbi +++ b/sorbet/rbi/gems/rack-protection@3.2.0.rbi @@ -4,80 +4,18 @@ # This is an autogenerated file for types exported from the `rack-protection` gem. # Please instead update this file by running `bin/tapioca gem rack-protection`. + # source://rack-protection//lib/rack/protection/version.rb#3 module Rack class << self - # source://rack/2.2.7/lib/rack/version.rb#26 + # source://rack/2.2.9/lib/rack/version.rb#26 def release; end - # source://rack/2.2.7/lib/rack/version.rb#19 + # source://rack/2.2.9/lib/rack/version.rb#19 def version; end end end -# source://rack/2.2.7/lib/rack.rb#29 -Rack::CACHE_CONTROL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#31 -Rack::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#32 -Rack::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#43 -Rack::DELETE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#36 -Rack::ETAG = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#30 -Rack::EXPIRES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/file.rb#6 -Rack::File = Rack::Files - -# source://rack/2.2.7/lib/rack.rb#39 -Rack::GET = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#44 -Rack::HEAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#20 -Rack::HTTPS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#35 -Rack::HTTP_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#17 -Rack::HTTP_HOST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#18 -Rack::HTTP_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#19 -Rack::HTTP_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#46 -Rack::LINK = T.let(T.unsafe(nil), String) - -# source://rack-test/2.1.0/lib/rack/test.rb#381 -Rack::MockSession = Rack::Test::Session - -# source://rack/2.2.7/lib/rack.rb#45 -Rack::OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#42 -Rack::PATCH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#21 -Rack::PATH_INFO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#40 -Rack::POST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#41 -Rack::PUT = T.let(T.unsafe(nil), String) - # source://rack-protection//lib/rack/protection/version.rb#4 module Rack::Protection class << self @@ -299,12 +237,12 @@ class Rack::Protection::Base # source://rack-protection//lib/rack/protection/base.rb#95 def drop_session(env); end - # source://rack-protection//lib/rack/protection/base.rb#117 + # source://rack-protection//lib/rack/protection/base.rb#123 def encrypt(value); end # @return [Boolean] # - # source://rack-protection//lib/rack/protection/base.rb#127 + # source://rack-protection//lib/rack/protection/base.rb#133 def html?(headers); end # source://rack-protection//lib/rack/protection/base.rb#68 @@ -315,16 +253,16 @@ class Rack::Protection::Base # source://rack-protection//lib/rack/protection/base.rb#21 def options; end - # source://rack-protection//lib/rack/protection/base.rb#107 + # source://rack-protection//lib/rack/protection/base.rb#113 def origin(env); end - # source://rack-protection//lib/rack/protection/base.rb#111 + # source://rack-protection//lib/rack/protection/base.rb#117 def random_string(secure = T.unsafe(nil)); end # source://rack-protection//lib/rack/protection/base.rb#56 def react(env); end - # source://rack-protection//lib/rack/protection/base.rb#99 + # source://rack-protection//lib/rack/protection/base.rb#105 def referrer(env); end # source://rack-protection//lib/rack/protection/base.rb#80 @@ -335,7 +273,7 @@ class Rack::Protection::Base # source://rack-protection//lib/rack/protection/base.rb#40 def safe?(env); end - # source://rack-protection//lib/rack/protection/base.rb#121 + # source://rack-protection//lib/rack/protection/base.rb#127 def secure_compare(a, b); end # source://rack-protection//lib/rack/protection/base.rb#89 @@ -676,12 +614,12 @@ class Rack::Protection::EscapedParams < ::Rack::Protection::Base def handle(hash); end class << self - # source://rack/2.2.7/lib/rack/utils.rb#184 + # source://rack/2.2.9/lib/rack/utils.rb#184 def escape_html(string); end private - # source://rack/2.2.7/lib/rack/utils.rb#38 + # source://rack/2.2.9/lib/rack/utils.rb#38 def escape_url(s); end end end @@ -965,123 +903,3 @@ class Rack::Protection::XSSHeader < ::Rack::Protection::Base # source://rack-protection//lib/rack/protection/base.rb#24 def default_options; end end - -# source://rack/2.2.7/lib/rack.rb#25 -Rack::QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#53 -Rack::RACK_ERRORS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#63 -Rack::RACK_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#65 -Rack::RACK_HIJACK_IO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#55 -Rack::RACK_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#64 -Rack::RACK_IS_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#54 -Rack::RACK_LOGGER = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#76 -Rack::RACK_METHODOVERRIDE_ORIGINAL_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#67 -Rack::RACK_MULTIPART_BUFFER_SIZE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#68 -Rack::RACK_MULTIPART_TEMPFILE_FACTORY = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#60 -Rack::RACK_MULTIPROCESS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#59 -Rack::RACK_MULTITHREAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#66 -Rack::RACK_RECURSIVE_INCLUDE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#72 -Rack::RACK_REQUEST_COOKIE_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#73 -Rack::RACK_REQUEST_COOKIE_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#70 -Rack::RACK_REQUEST_FORM_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#69 -Rack::RACK_REQUEST_FORM_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#71 -Rack::RACK_REQUEST_FORM_VARS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#74 -Rack::RACK_REQUEST_QUERY_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#75 -Rack::RACK_REQUEST_QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#61 -Rack::RACK_RUNONCE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#56 -Rack::RACK_SESSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#57 -Rack::RACK_SESSION_OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#77 -Rack::RACK_SESSION_UNPACKED_COOKIE_DATA = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#58 -Rack::RACK_SHOWSTATUS_DETAIL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#52 -Rack::RACK_TEMPFILES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#62 -Rack::RACK_URL_SCHEME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#51 -Rack::RACK_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#23 -Rack::RELEASE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#22 -Rack::REQUEST_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#23 -Rack::REQUEST_PATH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#24 -Rack::SCRIPT_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#27 -Rack::SERVER_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#28 -Rack::SERVER_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#26 -Rack::SERVER_PROTOCOL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#33 -Rack::SET_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#48 -Rack::TRACE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#34 -Rack::TRANSFER_ENCODING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#47 -Rack::UNLINK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#16 -Rack::VERSION = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/rack-session@1.0.2.rbi b/sorbet/rbi/gems/rack-session@1.0.2.rbi new file mode 100644 index 000000000..677dc7a64 --- /dev/null +++ b/sorbet/rbi/gems/rack-session@1.0.2.rbi @@ -0,0 +1,9 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `rack-session` gem. +# Please instead update this file by running `bin/tapioca gem rack-session`. + + +# THIS IS AN EMPTY RBI FILE. +# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/rack-test@2.1.0.rbi b/sorbet/rbi/gems/rack-test@2.1.0.rbi index 89c901ac7..fc5a7fa21 100644 --- a/sorbet/rbi/gems/rack-test@2.1.0.rbi +++ b/sorbet/rbi/gems/rack-test@2.1.0.rbi @@ -4,196 +4,23 @@ # This is an autogenerated file for types exported from the `rack-test` gem. # Please instead update this file by running `bin/tapioca gem rack-test`. + # source://rack-test//lib/rack/test/cookie_jar.rb#6 module Rack class << self - # source://rack/2.2.7/lib/rack/version.rb#26 + # source://rack/2.2.9/lib/rack/version.rb#26 def release; end - # source://rack/2.2.7/lib/rack/version.rb#19 + # source://rack/2.2.9/lib/rack/version.rb#19 def version; end end end -# source://rack/2.2.7/lib/rack.rb#29 -Rack::CACHE_CONTROL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#31 -Rack::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#32 -Rack::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#43 -Rack::DELETE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#36 -Rack::ETAG = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#30 -Rack::EXPIRES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/file.rb#6 -Rack::File = Rack::Files - -# source://rack/2.2.7/lib/rack.rb#39 -Rack::GET = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#44 -Rack::HEAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#20 -Rack::HTTPS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#35 -Rack::HTTP_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#17 -Rack::HTTP_HOST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#18 -Rack::HTTP_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#19 -Rack::HTTP_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#46 -Rack::LINK = T.let(T.unsafe(nil), String) - # For backwards compatibility with 1.1.0 and below # # source://rack-test//lib/rack/test.rb#381 Rack::MockSession = Rack::Test::Session -# source://rack/2.2.7/lib/rack.rb#45 -Rack::OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#42 -Rack::PATCH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#21 -Rack::PATH_INFO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#40 -Rack::POST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#41 -Rack::PUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#25 -Rack::QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#53 -Rack::RACK_ERRORS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#63 -Rack::RACK_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#65 -Rack::RACK_HIJACK_IO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#55 -Rack::RACK_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#64 -Rack::RACK_IS_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#54 -Rack::RACK_LOGGER = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#76 -Rack::RACK_METHODOVERRIDE_ORIGINAL_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#67 -Rack::RACK_MULTIPART_BUFFER_SIZE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#68 -Rack::RACK_MULTIPART_TEMPFILE_FACTORY = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#60 -Rack::RACK_MULTIPROCESS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#59 -Rack::RACK_MULTITHREAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#66 -Rack::RACK_RECURSIVE_INCLUDE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#72 -Rack::RACK_REQUEST_COOKIE_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#73 -Rack::RACK_REQUEST_COOKIE_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#70 -Rack::RACK_REQUEST_FORM_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#69 -Rack::RACK_REQUEST_FORM_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#71 -Rack::RACK_REQUEST_FORM_VARS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#74 -Rack::RACK_REQUEST_QUERY_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#75 -Rack::RACK_REQUEST_QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#61 -Rack::RACK_RUNONCE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#56 -Rack::RACK_SESSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#57 -Rack::RACK_SESSION_OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#77 -Rack::RACK_SESSION_UNPACKED_COOKIE_DATA = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#58 -Rack::RACK_SHOWSTATUS_DETAIL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#52 -Rack::RACK_TEMPFILES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#62 -Rack::RACK_URL_SCHEME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#51 -Rack::RACK_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#23 -Rack::RELEASE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#22 -Rack::REQUEST_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#23 -Rack::REQUEST_PATH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#24 -Rack::SCRIPT_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#27 -Rack::SERVER_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#28 -Rack::SERVER_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#26 -Rack::SERVER_PROTOCOL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#33 -Rack::SET_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#48 -Rack::TRACE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#34 -Rack::TRANSFER_ENCODING = T.let(T.unsafe(nil), String) - # source://rack-test//lib/rack/test/cookie_jar.rb#7 module Rack::Test class << self @@ -921,9 +748,3 @@ end # source://rack-test//lib/rack/test/version.rb#3 Rack::Test::VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#47 -Rack::UNLINK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#16 -Rack::VERSION = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/rack@2.2.7.rbi b/sorbet/rbi/gems/rack@2.2.9.rbi similarity index 96% rename from sorbet/rbi/gems/rack@2.2.7.rbi rename to sorbet/rbi/gems/rack@2.2.9.rbi index 000dc0254..60ef97fea 100644 --- a/sorbet/rbi/gems/rack@2.2.7.rbi +++ b/sorbet/rbi/gems/rack@2.2.9.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rack` gem. # Please instead update this file by running `bin/tapioca gem rack`. + # The Rack main module, serving as a namespace for all core Rack # modules and classes. # @@ -1629,6 +1630,8 @@ class Rack::Lint # source://rack//lib/rack/lint.rb#10 def initialize(app); end + # @raise [LintError] + # # source://rack//lib/rack/lint.rb#41 def _call(env); end @@ -1640,27 +1643,29 @@ class Rack::Lint # === The Content-Length # - # source://rack//lib/rack/lint.rb#719 + # source://rack//lib/rack/lint.rb#708 def check_content_length(status, headers); end # === The Content-Type # - # source://rack//lib/rack/lint.rb#705 + # source://rack//lib/rack/lint.rb#694 def check_content_type(status, headers); end # == The Environment # - # source://rack//lib/rack/lint.rb#77 + # @raise [LintError] + # + # source://rack//lib/rack/lint.rb#73 def check_env(env); end # === The Error Stream # - # source://rack//lib/rack/lint.rb#497 + # source://rack//lib/rack/lint.rb#483 def check_error(error); end # === The Headers # - # source://rack//lib/rack/lint.rb#668 + # source://rack//lib/rack/lint.rb#656 def check_headers(header); end # === Hijacking @@ -1671,14 +1676,14 @@ class Rack::Lint # # ==== Request (before status) # - # source://rack//lib/rack/lint.rb#562 + # source://rack//lib/rack/lint.rb#548 def check_hijack(env); end # ==== Response (after headers) # It is also possible to hijack a response after the status and headers # have been sent. # - # source://rack//lib/rack/lint.rb#609 + # source://rack//lib/rack/lint.rb#595 def check_hijack_response(headers, env); end # === The Input Stream @@ -1686,23 +1691,23 @@ class Rack::Lint # The input stream is an IO-like object which contains the raw HTTP # POST data. # - # source://rack//lib/rack/lint.rb#377 + # source://rack//lib/rack/lint.rb#365 def check_input(input); end # === The Status # - # source://rack//lib/rack/lint.rb#661 + # source://rack//lib/rack/lint.rb#647 def check_status(status); end - # source://rack//lib/rack/lint.rb#792 + # source://rack//lib/rack/lint.rb#781 def close; end # === The Body # - # source://rack//lib/rack/lint.rb#745 + # source://rack//lib/rack/lint.rb#734 def each; end - # source://rack//lib/rack/lint.rb#732 + # source://rack//lib/rack/lint.rb#721 def verify_content_length(bytes); end end @@ -1712,45 +1717,49 @@ module Rack::Lint::Assertion def assert(message); end end -# source://rack//lib/rack/lint.rb#506 +# source://rack//lib/rack/lint.rb#492 class Rack::Lint::ErrorWrapper include ::Rack::Lint::Assertion # @return [ErrorWrapper] a new instance of ErrorWrapper # - # source://rack//lib/rack/lint.rb#509 + # source://rack//lib/rack/lint.rb#495 def initialize(error); end # * +close+ must never be called on the error stream. # - # source://rack//lib/rack/lint.rb#531 + # @raise [LintError] + # + # source://rack//lib/rack/lint.rb#517 def close(*args); end # * +flush+ must be called without arguments and must be called # in order to make the error appear for sure. # - # source://rack//lib/rack/lint.rb#526 + # source://rack//lib/rack/lint.rb#512 def flush; end # * +puts+ must be called with a single argument that responds to +to_s+. # - # source://rack//lib/rack/lint.rb#514 + # source://rack//lib/rack/lint.rb#500 def puts(str); end # * +write+ must be called with a single argument that is a String. # - # source://rack//lib/rack/lint.rb#519 + # @raise [LintError] + # + # source://rack//lib/rack/lint.rb#505 def write(str); end end -# source://rack//lib/rack/lint.rb#536 +# source://rack//lib/rack/lint.rb#522 class Rack::Lint::HijackWrapper include ::Rack::Lint::Assertion extend ::Forwardable # @return [HijackWrapper] a new instance of HijackWrapper # - # source://rack//lib/rack/lint.rb#547 + # source://rack//lib/rack/lint.rb#533 def initialize(io); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -1781,32 +1790,38 @@ class Rack::Lint::HijackWrapper def write_nonblock(*args, **_arg1, &block); end end -# source://rack//lib/rack/lint.rb#540 +# source://rack//lib/rack/lint.rb#526 Rack::Lint::HijackWrapper::REQUIRED_METHODS = T.let(T.unsafe(nil), Array) -# source://rack//lib/rack/lint.rb#395 +# source://rack//lib/rack/lint.rb#383 class Rack::Lint::InputWrapper include ::Rack::Lint::Assertion # @return [InputWrapper] a new instance of InputWrapper # - # source://rack//lib/rack/lint.rb#398 + # source://rack//lib/rack/lint.rb#386 def initialize(input); end # * +close+ must never be called on the input stream. # - # source://rack//lib/rack/lint.rb#491 + # @raise [LintError] + # + # source://rack//lib/rack/lint.rb#477 def close(*args); end # * +each+ must be called without arguments and only yield Strings. # - # source://rack//lib/rack/lint.rb#463 + # @raise [LintError] + # + # source://rack//lib/rack/lint.rb#451 def each(*args); end # * +gets+ must be called without arguments and return a string, # or +nil+ on EOF. # - # source://rack//lib/rack/lint.rb#404 + # @raise [LintError] + # + # source://rack//lib/rack/lint.rb#392 def gets(*args); end # * +read+ behaves like IO#read. @@ -1827,7 +1842,7 @@ class Rack::Lint::InputWrapper # If +buffer+ is given, then the read data will be placed # into +buffer+ instead of a newly created String object. # - # source://rack//lib/rack/lint.rb#430 + # source://rack//lib/rack/lint.rb#418 def read(*args); end # * +rewind+ must be called without arguments. It rewinds the input @@ -1836,7 +1851,9 @@ class Rack::Lint::InputWrapper # developers must buffer the input data into some rewindable object # if the underlying input stream is not rewindable. # - # source://rack//lib/rack/lint.rb#478 + # @raise [LintError] + # + # source://rack//lib/rack/lint.rb#466 def rewind(*args); end end @@ -1888,7 +1905,7 @@ class Rack::MediaType # this method responds with the following Hash: # { 'charset' => 'utf-8' } # - # source://rack//lib/rack/media_type.rb#26 + # source://rack//lib/rack/media_type.rb#30 def params(content_type); end # The media type (type/subtype) portion of the CONTENT_TYPE header @@ -1903,7 +1920,7 @@ class Rack::MediaType private - # source://rack//lib/rack/media_type.rb#38 + # source://rack//lib/rack/media_type.rb#43 def strip_doublequotes(str); end end end @@ -2193,9 +2210,6 @@ class Rack::MockResponse < ::Rack::Response end end -# source://rack-test/2.1.0/lib/rack/test.rb#381 -Rack::MockSession = Rack::Test::Session - # A multipart form data parser, adapted from IOWA. # # Usually, Rack::Request#POST takes care of calling this. @@ -2307,145 +2321,145 @@ class Rack::Multipart::MultipartTotalPartLimitError < ::StandardError; end class Rack::Multipart::Parser # @return [Parser] a new instance of Parser # - # source://rack//lib/rack/multipart/parser.rb#178 + # source://rack//lib/rack/multipart/parser.rb#180 def initialize(boundary, tempfile, bufsize, query_parser); end - # source://rack//lib/rack/multipart/parser.rb#196 + # source://rack//lib/rack/multipart/parser.rb#199 def on_read(content); end - # source://rack//lib/rack/multipart/parser.rb#202 + # source://rack//lib/rack/multipart/parser.rb#205 def result; end # Returns the value of attribute state. # - # source://rack//lib/rack/multipart/parser.rb#176 + # source://rack//lib/rack/multipart/parser.rb#178 def state; end private - # source://rack//lib/rack/multipart/parser.rb#294 + # source://rack//lib/rack/multipart/parser.rb#302 def consume_boundary; end - # source://rack//lib/rack/multipart/parser.rb#292 + # source://rack//lib/rack/multipart/parser.rb#300 def full_boundary; end - # source://rack//lib/rack/multipart/parser.rb#304 + # source://rack//lib/rack/multipart/parser.rb#312 def get_filename(head); end - # source://rack//lib/rack/multipart/parser.rb#240 + # source://rack//lib/rack/multipart/parser.rb#248 def handle_consume_token; end - # source://rack//lib/rack/multipart/parser.rb#369 + # source://rack//lib/rack/multipart/parser.rb#377 def handle_empty_content!(content); end - # source://rack//lib/rack/multipart/parser.rb#231 + # source://rack//lib/rack/multipart/parser.rb#234 def handle_fast_forward; end - # source://rack//lib/rack/multipart/parser.rb#273 + # source://rack//lib/rack/multipart/parser.rb#281 def handle_mime_body; end - # source://rack//lib/rack/multipart/parser.rb#250 + # source://rack//lib/rack/multipart/parser.rb#258 def handle_mime_head; end - # source://rack//lib/rack/multipart/parser.rb#214 + # source://rack//lib/rack/multipart/parser.rb#217 def run_parser; end - # source://rack//lib/rack/multipart/parser.rb#341 + # source://rack//lib/rack/multipart/parser.rb#349 def tag_multipart_encoding(filename, content_type, name, body); end class << self - # source://rack//lib/rack/multipart/parser.rb#64 + # source://rack//lib/rack/multipart/parser.rb#66 def parse(io, content_length, content_type, tmpfile, bufsize, qp); end - # source://rack//lib/rack/multipart/parser.rb#57 + # source://rack//lib/rack/multipart/parser.rb#59 def parse_boundary(content_type); end end end -# source://rack//lib/rack/multipart/parser.rb#19 +# source://rack//lib/rack/multipart/parser.rb#21 Rack::Multipart::Parser::BOUNDARY_REGEX = T.let(T.unsafe(nil), Regexp) # source://rack//lib/rack/multipart/parser.rb#13 Rack::Multipart::Parser::BUFSIZE = T.let(T.unsafe(nil), Integer) -# source://rack//lib/rack/multipart/parser.rb#21 +# source://rack//lib/rack/multipart/parser.rb#23 class Rack::Multipart::Parser::BoundedIO # @return [BoundedIO] a new instance of BoundedIO # - # source://rack//lib/rack/multipart/parser.rb#22 + # source://rack//lib/rack/multipart/parser.rb#24 def initialize(io, content_length); end - # source://rack//lib/rack/multipart/parser.rb#28 + # source://rack//lib/rack/multipart/parser.rb#30 def read(size, outbuf = T.unsafe(nil)); end - # source://rack//lib/rack/multipart/parser.rb#49 + # source://rack//lib/rack/multipart/parser.rb#51 def rewind; end end -# source://rack//lib/rack/multipart/parser.rb#339 +# source://rack//lib/rack/multipart/parser.rb#347 Rack::Multipart::Parser::CHARSET = T.let(T.unsafe(nil), String) -# source://rack//lib/rack/multipart/parser.rb#85 +# source://rack//lib/rack/multipart/parser.rb#87 class Rack::Multipart::Parser::Collector include ::Enumerable # @return [Collector] a new instance of Collector # - # source://rack//lib/rack/multipart/parser.rb#121 + # source://rack//lib/rack/multipart/parser.rb#123 def initialize(tempfile); end - # source://rack//lib/rack/multipart/parser.rb#127 + # source://rack//lib/rack/multipart/parser.rb#129 def each; end - # source://rack//lib/rack/multipart/parser.rb#147 + # source://rack//lib/rack/multipart/parser.rb#149 def on_mime_body(mime_index, content); end - # source://rack//lib/rack/multipart/parser.rb#151 + # source://rack//lib/rack/multipart/parser.rb#153 def on_mime_finish(mime_index); end - # source://rack//lib/rack/multipart/parser.rb#131 + # source://rack//lib/rack/multipart/parser.rb#133 def on_mime_head(mime_index, head, filename, content_type, name); end private - # source://rack//lib/rack/multipart/parser.rb#156 + # source://rack//lib/rack/multipart/parser.rb#158 def check_part_limits; end end -# source://rack//lib/rack/multipart/parser.rb#109 +# source://rack//lib/rack/multipart/parser.rb#111 class Rack::Multipart::Parser::Collector::BufferPart < ::Rack::Multipart::Parser::Collector::MimePart - # source://rack//lib/rack/multipart/parser.rb#111 + # source://rack//lib/rack/multipart/parser.rb#113 def close; end # @return [Boolean] # - # source://rack//lib/rack/multipart/parser.rb#110 + # source://rack//lib/rack/multipart/parser.rb#112 def file?; end end -# source://rack//lib/rack/multipart/parser.rb#86 +# source://rack//lib/rack/multipart/parser.rb#88 class Rack::Multipart::Parser::Collector::MimePart < ::Struct # @yield [data] # - # source://rack//lib/rack/multipart/parser.rb#87 + # source://rack//lib/rack/multipart/parser.rb#89 def get_data; end end -# source://rack//lib/rack/multipart/parser.rb#114 +# source://rack//lib/rack/multipart/parser.rb#116 class Rack::Multipart::Parser::Collector::TempfilePart < ::Rack::Multipart::Parser::Collector::MimePart - # source://rack//lib/rack/multipart/parser.rb#116 + # source://rack//lib/rack/multipart/parser.rb#118 def close; end # @return [Boolean] # - # source://rack//lib/rack/multipart/parser.rb#115 + # source://rack//lib/rack/multipart/parser.rb#117 def file?; end end -# source://rack//lib/rack/multipart/parser.rb#55 +# source://rack//lib/rack/multipart/parser.rb#57 Rack::Multipart::Parser::EMPTY = T.let(T.unsafe(nil), Rack::Multipart::Parser::MultipartInfo) -# source://rack//lib/rack/multipart/parser.rb#54 +# source://rack//lib/rack/multipart/parser.rb#56 class Rack::Multipart::Parser::MultipartInfo < ::Struct # Returns the value of attribute params # @@ -3005,13 +3019,13 @@ class Rack::Request # source://rack//lib/rack/request.rb#35 def update_param(k, v); end - # source://yard/0.9.34/lib/yard/server/rack_adapter.rb#94 + # source://yard/0.9.36/lib/yard/server/rack_adapter.rb#94 def version_supplied; end - # source://yard/0.9.34/lib/yard/server/rack_adapter.rb#94 + # source://yard/0.9.36/lib/yard/server/rack_adapter.rb#94 def version_supplied=(_arg0); end - # source://yard/0.9.34/lib/yard/server/rack_adapter.rb#96 + # source://yard/0.9.36/lib/yard/server/rack_adapter.rb#96 def xhr?; end class << self @@ -4663,116 +4677,116 @@ Rack::Session::Abstract::SessionHash::Unspecified = T.let(T.unsafe(nil), Object) # }.new # }) # -# source://rack//lib/rack/session/cookie.rb#49 +# source://rack//lib/rack/session/cookie.rb#50 class Rack::Session::Cookie < ::Rack::Session::Abstract::PersistedSecure # @return [Cookie] a new instance of Cookie # - # source://rack//lib/rack/session/cookie.rb#107 + # source://rack//lib/rack/session/cookie.rb#108 def initialize(app, options = T.unsafe(nil)); end # Returns the value of attribute coder. # - # source://rack//lib/rack/session/cookie.rb#105 + # source://rack//lib/rack/session/cookie.rb#106 def coder; end private - # source://rack//lib/rack/session/cookie.rb#180 + # source://rack//lib/rack/session/cookie.rb#181 def delete_session(req, session_id, options); end # @return [Boolean] # - # source://rack//lib/rack/session/cookie.rb#185 + # source://rack//lib/rack/session/cookie.rb#186 def digest_match?(data, digest); end - # source://rack//lib/rack/session/cookie.rb#132 + # source://rack//lib/rack/session/cookie.rb#133 def extract_session_id(request); end - # source://rack//lib/rack/session/cookie.rb#126 + # source://rack//lib/rack/session/cookie.rb#127 def find_session(req, sid); end - # source://rack//lib/rack/session/cookie.rb#192 + # source://rack//lib/rack/session/cookie.rb#193 def generate_hmac(data, secret); end - # source://rack//lib/rack/session/cookie.rb#149 + # source://rack//lib/rack/session/cookie.rb#150 def persistent_session_id!(data, sid = T.unsafe(nil)); end # @return [Boolean] # - # source://rack//lib/rack/session/cookie.rb#196 + # source://rack//lib/rack/session/cookie.rb#197 def secure?(options); end - # source://rack//lib/rack/session/cookie.rb#136 + # source://rack//lib/rack/session/cookie.rb#137 def unpacked_cookie_data(request); end - # source://rack//lib/rack/session/cookie.rb#164 + # source://rack//lib/rack/session/cookie.rb#165 def write_session(req, session_id, session, options); end end # Encode session cookies as Base64 # -# source://rack//lib/rack/session/cookie.rb#51 +# source://rack//lib/rack/session/cookie.rb#52 class Rack::Session::Cookie::Base64 - # source://rack//lib/rack/session/cookie.rb#56 + # source://rack//lib/rack/session/cookie.rb#57 def decode(str); end - # source://rack//lib/rack/session/cookie.rb#52 + # source://rack//lib/rack/session/cookie.rb#53 def encode(str); end end # N.B. Unlike other encoding methods, the contained objects must be a # valid JSON composite type, either a Hash or an Array. # -# source://rack//lib/rack/session/cookie.rb#74 +# source://rack//lib/rack/session/cookie.rb#75 class Rack::Session::Cookie::Base64::JSON < ::Rack::Session::Cookie::Base64 - # source://rack//lib/rack/session/cookie.rb#79 + # source://rack//lib/rack/session/cookie.rb#80 def decode(str); end - # source://rack//lib/rack/session/cookie.rb#75 + # source://rack//lib/rack/session/cookie.rb#76 def encode(obj); end end # Encode session cookies as Marshaled Base64 data # -# source://rack//lib/rack/session/cookie.rb#61 +# source://rack//lib/rack/session/cookie.rb#62 class Rack::Session::Cookie::Base64::Marshal < ::Rack::Session::Cookie::Base64 - # source://rack//lib/rack/session/cookie.rb#66 + # source://rack//lib/rack/session/cookie.rb#67 def decode(str); end - # source://rack//lib/rack/session/cookie.rb#62 + # source://rack//lib/rack/session/cookie.rb#63 def encode(str); end end -# source://rack//lib/rack/session/cookie.rb#85 +# source://rack//lib/rack/session/cookie.rb#86 class Rack::Session::Cookie::Base64::ZipJSON < ::Rack::Session::Cookie::Base64 - # source://rack//lib/rack/session/cookie.rb#90 + # source://rack//lib/rack/session/cookie.rb#91 def decode(str); end - # source://rack//lib/rack/session/cookie.rb#86 + # source://rack//lib/rack/session/cookie.rb#87 def encode(obj); end end # Use no encoding for session cookies # -# source://rack//lib/rack/session/cookie.rb#100 +# source://rack//lib/rack/session/cookie.rb#101 class Rack::Session::Cookie::Identity - # source://rack//lib/rack/session/cookie.rb#102 + # source://rack//lib/rack/session/cookie.rb#103 def decode(str); end - # source://rack//lib/rack/session/cookie.rb#101 + # source://rack//lib/rack/session/cookie.rb#102 def encode(str); end end -# source://rack//lib/rack/session/cookie.rb#155 +# source://rack//lib/rack/session/cookie.rb#156 class Rack::Session::Cookie::SessionId # @return [SessionId] a new instance of SessionId # - # source://rack//lib/rack/session/cookie.rb#158 + # source://rack//lib/rack/session/cookie.rb#159 def initialize(session_id, cookie_value); end # Returns the value of attribute cookie_value. # - # source://rack//lib/rack/session/cookie.rb#156 + # source://rack//lib/rack/session/cookie.rb#157 def cookie_value; end end @@ -5155,7 +5169,7 @@ module Rack::Utils # source://rack//lib/rack/utils.rb#352 def byte_ranges(env, size); end - # source://rack//lib/rack/utils.rb#606 + # source://rack//lib/rack/utils.rb#609 def clean_path_info(path_info); end # :nocov: @@ -5225,7 +5239,7 @@ module Rack::Utils # on variable length plaintext strings because it could leak length info # via timing attacks. # - # source://rack//lib/rack/utils.rb#392 + # source://rack//lib/rack/utils.rb#395 def secure_compare(a, b); end # source://rack//lib/rack/utils.rb#188 @@ -5234,7 +5248,7 @@ module Rack::Utils # source://rack//lib/rack/utils.rb#278 def set_cookie_header!(header, key, value); end - # source://rack//lib/rack/utils.rb#596 + # source://rack//lib/rack/utils.rb#599 def status_code(status); end # Unescapes a URI escaped string with +encoding+. +encoding+ will be the @@ -5249,7 +5263,7 @@ module Rack::Utils # source://rack//lib/rack/utils.rb#50 def unescape_path(s); end - # source://rack//lib/rack/utils.rb#623 + # source://rack//lib/rack/utils.rb#626 def valid_path?(path); end class << self @@ -5283,7 +5297,7 @@ module Rack::Utils # source://rack//lib/rack/utils.rb#352 def byte_ranges(env, size); end - # source://rack//lib/rack/utils.rb#606 + # source://rack//lib/rack/utils.rb#609 def clean_path_info(path_info); end # source://rack//lib/rack/utils.rb#97 @@ -5413,7 +5427,7 @@ module Rack::Utils # on variable length plaintext strings because it could leak length info # via timing attacks. # - # source://rack//lib/rack/utils.rb#392 + # source://rack//lib/rack/utils.rb#395 def secure_compare(a, b); end # source://rack//lib/rack/utils.rb#188 @@ -5422,7 +5436,7 @@ module Rack::Utils # source://rack//lib/rack/utils.rb#278 def set_cookie_header!(header, key, value); end - # source://rack//lib/rack/utils.rb#596 + # source://rack//lib/rack/utils.rb#599 def status_code(status); end # Unescapes a URI escaped string with +encoding+. +encoding+ will be the @@ -5439,7 +5453,7 @@ module Rack::Utils # @return [Boolean] # - # source://rack//lib/rack/utils.rb#623 + # source://rack//lib/rack/utils.rb#626 def valid_path?(path); end end end @@ -5453,30 +5467,30 @@ Rack::Utils::COMMON_SEP = T.let(T.unsafe(nil), Hash) # would be the request environment. The second of which would be the rack # application that the request would be forwarded to. # -# source://rack//lib/rack/utils.rb#407 +# source://rack//lib/rack/utils.rb#410 class Rack::Utils::Context # @return [Context] a new instance of Context # - # source://rack//lib/rack/utils.rb#410 + # source://rack//lib/rack/utils.rb#413 def initialize(app_f, app_r); end # Returns the value of attribute app. # - # source://rack//lib/rack/utils.rb#408 + # source://rack//lib/rack/utils.rb#411 def app; end - # source://rack//lib/rack/utils.rb#415 + # source://rack//lib/rack/utils.rb#418 def call(env); end - # source://rack//lib/rack/utils.rb#423 + # source://rack//lib/rack/utils.rb#426 def context(env, app = T.unsafe(nil)); end # Returns the value of attribute for. # - # source://rack//lib/rack/utils.rb#408 + # source://rack//lib/rack/utils.rb#411 def for; end - # source://rack//lib/rack/utils.rb#419 + # source://rack//lib/rack/utils.rb#422 def recontext(app); end end @@ -5495,7 +5509,7 @@ Rack::Utils::ESCAPE_HTML_PATTERN = T.let(T.unsafe(nil), Regexp) # ruby -ne 'm = /^(\d{3}),(?!Unassigned|\(Unused\))([^,]+)/.match($_) and \ # puts "#{m[1]} => \x27#{m[2].strip}\x27,"' # -# source://rack//lib/rack/utils.rb#523 +# source://rack//lib/rack/utils.rb#526 Rack::Utils::HTTP_STATUS_CODES = T.let(T.unsafe(nil), Hash) # A case-insensitive Hash that preserves the original case of a @@ -5503,90 +5517,90 @@ Rack::Utils::HTTP_STATUS_CODES = T.let(T.unsafe(nil), Hash) # # @api private # -# source://rack//lib/rack/utils.rb#432 +# source://rack//lib/rack/utils.rb#435 class Rack::Utils::HeaderHash < ::Hash # @api private # @return [HeaderHash] a new instance of HeaderHash # - # source://rack//lib/rack/utils.rb#441 + # source://rack//lib/rack/utils.rb#444 def initialize(hash = T.unsafe(nil)); end # @api private # - # source://rack//lib/rack/utils.rb#471 + # source://rack//lib/rack/utils.rb#474 def [](k); end # @api private # - # source://rack//lib/rack/utils.rb#475 + # source://rack//lib/rack/utils.rb#478 def []=(k, v); end # on clear, we need to clear @names hash # # @api private # - # source://rack//lib/rack/utils.rb#454 + # source://rack//lib/rack/utils.rb#457 def clear; end # @api private # - # source://rack//lib/rack/utils.rb#482 + # source://rack//lib/rack/utils.rb#485 def delete(k); end # @api private # - # source://rack//lib/rack/utils.rb#459 + # source://rack//lib/rack/utils.rb#462 def each; end # @api private # @return [Boolean] # - # source://rack//lib/rack/utils.rb#488 + # source://rack//lib/rack/utils.rb#491 def has_key?(k); end # @api private # @return [Boolean] # - # source://rack//lib/rack/utils.rb#488 + # source://rack//lib/rack/utils.rb#491 def include?(k); end # @api private # @return [Boolean] # - # source://rack//lib/rack/utils.rb#488 + # source://rack//lib/rack/utils.rb#491 def key?(k); end # @api private # @return [Boolean] # - # source://rack//lib/rack/utils.rb#488 + # source://rack//lib/rack/utils.rb#491 def member?(k); end # @api private # - # source://rack//lib/rack/utils.rb#501 + # source://rack//lib/rack/utils.rb#504 def merge(other); end # @api private # - # source://rack//lib/rack/utils.rb#496 + # source://rack//lib/rack/utils.rb#499 def merge!(other); end # @api private # - # source://rack//lib/rack/utils.rb#506 + # source://rack//lib/rack/utils.rb#509 def replace(other); end # @api private # - # source://rack//lib/rack/utils.rb#465 + # source://rack//lib/rack/utils.rb#468 def to_hash; end protected # @api private # - # source://rack//lib/rack/utils.rb#513 + # source://rack//lib/rack/utils.rb#516 def names; end private @@ -5595,13 +5609,13 @@ class Rack::Utils::HeaderHash < ::Hash # # @api private # - # source://rack//lib/rack/utils.rb#448 + # source://rack//lib/rack/utils.rb#451 def initialize_copy(other); end class << self # @api private # - # source://rack//lib/rack/utils.rb#433 + # source://rack//lib/rack/utils.rb#436 def [](headers); end end end @@ -5612,10 +5626,10 @@ Rack::Utils::InvalidParameterError = Rack::QueryParser::InvalidParameterError # source://rack//lib/rack/utils.rb#23 Rack::Utils::KeySpaceConstrainedParams = Rack::QueryParser::Params -# source://rack//lib/rack/utils.rb#621 +# source://rack//lib/rack/utils.rb#624 Rack::Utils::NULL_BYTE = T.let(T.unsafe(nil), String) -# source://rack//lib/rack/utils.rb#604 +# source://rack//lib/rack/utils.rb#607 Rack::Utils::PATH_SEPS = T.let(T.unsafe(nil), Regexp) # source://rack//lib/rack/utils.rb#19 @@ -5629,10 +5643,10 @@ Rack::Utils::RFC2822_MONTH_NAME = T.let(T.unsafe(nil), Array) # Responses with HTTP status codes that should not have an entity body # -# source://rack//lib/rack/utils.rb#590 +# source://rack//lib/rack/utils.rb#593 Rack::Utils::STATUS_WITH_NO_ENTITY_BODY = T.let(T.unsafe(nil), Hash) -# source://rack//lib/rack/utils.rb#592 +# source://rack//lib/rack/utils.rb#595 Rack::Utils::SYMBOL_TO_STATUS_CODE = T.let(T.unsafe(nil), Hash) # The Rack protocol version number implemented. diff --git a/sorbet/rbi/gems/rackup@1.0.0.rbi b/sorbet/rbi/gems/rackup@1.0.0.rbi new file mode 100644 index 000000000..f556867b0 --- /dev/null +++ b/sorbet/rbi/gems/rackup@1.0.0.rbi @@ -0,0 +1,9 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `rackup` gem. +# Please instead update this file by running `bin/tapioca gem rackup`. + + +# THIS IS AN EMPTY RBI FILE. +# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/rails-controller-testing@1.0.5.rbi b/sorbet/rbi/gems/rails-controller-testing@1.0.5.rbi index aebfca4b6..159623a29 100644 --- a/sorbet/rbi/gems/rails-controller-testing@1.0.5.rbi +++ b/sorbet/rbi/gems/rails-controller-testing@1.0.5.rbi @@ -4,70 +4,74 @@ # This is an autogenerated file for types exported from the `rails-controller-testing` gem. # Please instead update this file by running `bin/tapioca gem rails-controller-testing`. + # source://rails-controller-testing//lib/rails/controller/testing/test_process.rb#3 module Rails class << self - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def app_class; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def app_class=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#39 + # source://railties/7.2.0/lib/rails.rb#45 def application; end - # source://railties/7.0.5/lib/rails.rb#37 + # source://railties/7.2.0/lib/rails.rb#43 def application=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#123 + # source://railties/7.2.0/lib/rails.rb#126 def autoloaders; end - # source://railties/7.0.5/lib/rails.rb#50 + # source://railties/7.2.0/lib/rails.rb#56 def backtrace_cleaner; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def cache; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def cache=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#46 + # source://railties/7.2.0/lib/rails.rb#52 def configuration; end - # source://railties/7.0.5/lib/rails.rb#72 + # source://railties/7.2.0/lib/rails/deprecator.rb#4 + def deprecator; end + + # source://railties/7.2.0/lib/rails.rb#75 def env; end - # source://railties/7.0.5/lib/rails.rb#79 + # source://railties/7.2.0/lib/rails.rb#82 def env=(environment); end - # source://railties/7.0.5/lib/rails.rb#90 + # source://railties/7.2.0/lib/rails.rb#93 def error; end - # source://railties/7.0.5/lib/rails/gem_version.rb#5 + # source://railties/7.2.0/lib/rails/gem_version.rb#5 def gem_version; end - # source://railties/7.0.5/lib/rails.rb#103 + # source://railties/7.2.0/lib/rails.rb#106 def groups(*groups); end - # source://railties/7.0.5/lib/rails.rb#43 + # source://railties/7.2.0/lib/rails.rb#49 def initialize!(*_arg0, **_arg1, &_arg2); end - # source://railties/7.0.5/lib/rails.rb#43 + # source://railties/7.2.0/lib/rails.rb#49 def initialized?(*_arg0, **_arg1, &_arg2); end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def logger; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def logger=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#119 + # source://railties/7.2.0/lib/rails.rb#122 def public_path; end - # source://railties/7.0.5/lib/rails.rb#63 + # source://railties/7.2.0/lib/rails.rb#65 def root; end - # source://railties/7.0.5/lib/rails/version.rb#7 + # source://railties/7.2.0/lib/rails/version.rb#7 def version; end end end @@ -174,6 +178,3 @@ end # source://rails-controller-testing//lib/rails/controller/testing/version.rb#4 Rails::Controller::Testing::VERSION = T.let(T.unsafe(nil), String) - -# source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#11 -Rails::Html = Rails::HTML diff --git a/sorbet/rbi/gems/rails-dom-testing@2.0.3.rbi b/sorbet/rbi/gems/rails-dom-testing@2.0.3.rbi deleted file mode 100644 index 7edd57908..000000000 --- a/sorbet/rbi/gems/rails-dom-testing@2.0.3.rbi +++ /dev/null @@ -1,458 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `rails-dom-testing` gem. -# Please instead update this file by running `bin/tapioca gem rails-dom-testing`. - -# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#4 -class HTMLSelector - # @return [HTMLSelector] a new instance of HTMLSelector - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#7 - def initialize(values, previous_selection = T.unsafe(nil), &root_fallback); end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#33 - def context; end - - # Returns the value of attribute css_selector. - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#5 - def css_selector; end - - # Returns the value of attribute message. - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#5 - def message; end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#25 - def select; end - - # @return [Boolean] - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#19 - def selecting_no_body?; end - - # Returns the value of attribute tests. - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#5 - def tests; end - - private - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#87 - def extract_equality_tests; end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#59 - def extract_root(previous_selection, root_fallback); end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#76 - def extract_selectors; end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#35 - def filter(matches); end - - class << self - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#33 - def context; end - end -end - -# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#31 -HTMLSelector::NO_STRIP = T.let(T.unsafe(nil), Array) - -# source://rails-dom-testing//lib/rails/dom/testing/assertions.rb#4 -module Rails - class << self - # source://railties/7.0.5/lib/rails.rb#38 - def app_class; end - - # source://railties/7.0.5/lib/rails.rb#38 - def app_class=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#39 - def application; end - - # source://railties/7.0.5/lib/rails.rb#37 - def application=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#123 - def autoloaders; end - - # source://railties/7.0.5/lib/rails.rb#50 - def backtrace_cleaner; end - - # source://railties/7.0.5/lib/rails.rb#38 - def cache; end - - # source://railties/7.0.5/lib/rails.rb#38 - def cache=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#46 - def configuration; end - - # source://railties/7.0.5/lib/rails.rb#72 - def env; end - - # source://railties/7.0.5/lib/rails.rb#79 - def env=(environment); end - - # source://railties/7.0.5/lib/rails.rb#90 - def error; end - - # source://railties/7.0.5/lib/rails/gem_version.rb#5 - def gem_version; end - - # source://railties/7.0.5/lib/rails.rb#103 - def groups(*groups); end - - # source://railties/7.0.5/lib/rails.rb#43 - def initialize!(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails.rb#43 - def initialized?(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails.rb#38 - def logger; end - - # source://railties/7.0.5/lib/rails.rb#38 - def logger=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#119 - def public_path; end - - # source://railties/7.0.5/lib/rails.rb#63 - def root; end - - # source://railties/7.0.5/lib/rails/version.rb#7 - def version; end - end -end - -# source://rails-dom-testing//lib/rails/dom/testing/assertions.rb#5 -module Rails::Dom; end - -# source://rails-dom-testing//lib/rails/dom/testing/assertions.rb#6 -module Rails::Dom::Testing; end - -# source://rails-dom-testing//lib/rails/dom/testing/assertions.rb#7 -module Rails::Dom::Testing::Assertions - include ::Rails::Dom::Testing::Assertions::DomAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable - include ::Rails::Dom::Testing::Assertions::SelectorAssertions - extend ::ActiveSupport::Concern -end - -# source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#5 -module Rails::Dom::Testing::Assertions::DomAssertions - # \Test two HTML strings for equivalency (e.g., equal even when attributes are in another order) - # - # # assert that the referenced method generates the appropriate HTML string - # assert_dom_equal 'Apples', link_to("Apples", "http://www.example.com") - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#10 - def assert_dom_equal(expected, actual, message = T.unsafe(nil)); end - - # The negated form of +assert_dom_equal+. - # - # # assert that the referenced method does not generate the specified HTML string - # assert_dom_not_equal 'Apples', link_to("Oranges", "http://www.example.com") - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#20 - def assert_dom_not_equal(expected, actual, message = T.unsafe(nil)); end - - protected - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#28 - def compare_doms(expected, actual); end - - # @return [Boolean] - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#63 - def equal_attribute?(attr, other_attr); end - - # @return [Boolean] - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#50 - def equal_attribute_nodes?(nodes, other_nodes); end - - # @return [Boolean] - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#38 - def equal_children?(child, other_child); end - - private - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#69 - def fragment(text); end -end - -# Adds the +assert_select+ method for use in Rails functional -# test cases, which can be used to make assertions on the response HTML of a controller -# action. You can also call +assert_select+ within another +assert_select+ to -# make assertions on elements selected by the enclosing assertion. -# -# Use +css_select+ to select elements without making an assertions, either -# from the response HTML or elements selected by the enclosing assertion. -# -# In addition to HTML responses, you can make the following assertions: -# -# * +assert_select_encoded+ - Assertions on HTML encoded inside XML, for example for dealing with feed item descriptions. -# * +assert_select_email+ - Assertions on the HTML body of an e-mail. -# -# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/count_describable.rb#7 -module Rails::Dom::Testing::Assertions::SelectorAssertions - include ::Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable - - # An assertion that selects elements and makes one or more equality tests. - # - # If the first argument is an element, selects all matching elements - # starting from (and including) that element and all its children in - # depth-first order. - # - # If no element is specified +assert_select+ selects from - # the element returned in +document_root_element+ - # unless +assert_select+ is called from within an +assert_select+ block. - # Override +document_root_element+ to tell +assert_select+ what to select from. - # The default implementation raises an exception explaining this. - # - # When called with a block +assert_select+ passes an array of selected elements - # to the block. Calling +assert_select+ from the block, with no element specified, - # runs the assertion on the complete set of elements selected by the enclosing assertion. - # Alternatively the array may be iterated through so that +assert_select+ can be called - # separately for each element. - # - # - # ==== Example - # If the response contains two ordered lists, each with four list elements then: - # assert_select "ol" do |elements| - # elements.each do |element| - # assert_select element, "li", 4 - # end - # end - # - # will pass, as will: - # assert_select "ol" do - # assert_select "li", 8 - # end - # - # The selector may be a CSS selector expression (String) or an expression - # with substitution values (Array). - # Substitution uses a custom pseudo class match. Pass in whatever attribute you want to match (enclosed in quotes) and a ? for the substitution. - # assert_select returns nil if called with an invalid css selector. - # - # assert_select "div:match('id', ?)", /\d+/ - # - # === Equality Tests - # - # The equality test may be one of the following: - # * true - Assertion is true if at least one element selected. - # * false - Assertion is true if no element selected. - # * String/Regexp - Assertion is true if the text value of at least - # one element matches the string or regular expression. - # * Integer - Assertion is true if exactly that number of - # elements are selected. - # * Range - Assertion is true if the number of selected - # elements fit the range. - # If no equality test specified, the assertion is true if at least one - # element selected. - # - # To perform more than one equality tests, use a hash with the following keys: - # * :text - Narrow the selection to elements that have this text - # value (string or regexp). - # * :html - Narrow the selection to elements that have this HTML - # content (string or regexp). - # * :count - Assertion is true if the number of selected elements - # is equal to this value. - # * :minimum - Assertion is true if the number of selected - # elements is at least this value. - # * :maximum - Assertion is true if the number of selected - # elements is at most this value. - # - # If the method is called with a block, once all equality tests are - # evaluated the block is called with an array of all matched elements. - # - # # At least one form element - # assert_select "form" - # - # # Form element includes four input fields - # assert_select "form input", 4 - # - # # Page title is "Welcome" - # assert_select "title", "Welcome" - # - # # Page title is "Welcome" and there is only one title element - # assert_select "title", {count: 1, text: "Welcome"}, - # "Wrong title or more than one title element" - # - # # Page contains no forms - # assert_select "form", false, "This page must contain no forms" - # - # # Test the content and style - # assert_select "body div.header ul.menu" - # - # # Use substitution values - # assert_select "ol>li:match('id', ?)", /item-\d+/ - # - # # All input fields in the form have a name - # assert_select "form input" do - # assert_select ":match('name', ?)", /.+/ # Not empty - # end - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#161 - def assert_select(*args, &block); end - - # Extracts the body of an email and runs nested assertions on it. - # - # You must enable deliveries for this assertion to work, use: - # ActionMailer::Base.perform_deliveries = true - # - # assert_select_email do - # assert_select "h1", "Email alert" - # end - # - # assert_select_email do - # items = assert_select "ol>li" - # items.each do - # # Work with items here... - # end - # end - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#247 - def assert_select_email(&block); end - - # Extracts the content of an element, treats it as encoded HTML and runs - # nested assertion on it. - # - # You typically call this method within another assertion to operate on - # all currently selected elements. You can also pass an element or array - # of elements. - # - # The content of each element is un-encoded, and wrapped in the root - # element +encoded+. It then calls the block with all un-encoded elements. - # - # # Selects all bold tags from within the title of an Atom feed's entries (perhaps to nab a section name prefix) - # assert_select "feed[xmlns='http://www.w3.org/2005/Atom']" do - # # Select each entry item and then the title item - # assert_select "entry>title" do - # # Run assertions on the encoded title elements - # assert_select_encoded do - # assert_select "b" - # end - # end - # end - # - # - # # Selects all paragraph tags from within the description of an RSS feed - # assert_select "rss[version=2.0]" do - # # Select description element of each feed item. - # assert_select "channel>item>description" do - # # Run assertions on the encoded elements. - # assert_select_encoded do - # assert_select "p" - # end - # end - # end - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#211 - def assert_select_encoded(element = T.unsafe(nil), &block); end - - # Select and return all matching elements. - # - # If called with a single argument, uses that argument as a selector. - # Called without an element +css_select+ selects from - # the element returned in +document_root_element+ - # - # The default implementation of +document_root_element+ raises an exception explaining this. - # - # Returns an empty Nokogiri::XML::NodeSet if no match is found. - # - # If called with two arguments, uses the first argument as the root - # element and the second argument as the selector. Attempts to match the - # root element and any of its children. - # Returns an empty Nokogiri::XML::NodeSet if no match is found. - # - # The selector may be a CSS selector expression (String). - # css_select returns nil if called with an invalid css selector. - # - # # Selects all div tags - # divs = css_select("div") - # - # # Selects all paragraph tags and does something interesting - # pars = css_select("p") - # pars.each do |par| - # # Do something fun with paragraphs here... - # end - # - # # Selects all list items in unordered lists - # items = css_select("ul>li") - # - # # Selects all form tags and then all inputs inside the form - # forms = css_select("form") - # forms.each do |form| - # inputs = css_select(form, "input") - # ... - # end - # - # @raise [ArgumentError] - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#59 - def css_select(*args); end - - private - - # +equals+ must contain :minimum, :maximum and :count keys - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#270 - def assert_size_match!(size, equals, css_selector, message = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#264 - def document_root_element; end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#282 - def nest_selection(selection); end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#291 - def nodeset(node); end -end - -# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/count_describable.rb#8 -module Rails::Dom::Testing::Assertions::SelectorAssertions::CountDescribable - extend ::ActiveSupport::Concern - - private - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/count_describable.rb#12 - def count_description(min, max, count); end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/count_describable.rb#24 - def pluralize_element(quantity); end -end - -# source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#11 -Rails::Html = Rails::HTML - -# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#1 -class SubstitutionContext - # @return [SubstitutionContext] a new instance of SubstitutionContext - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#2 - def initialize; end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#16 - def match(matches, attribute, matcher); end - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#6 - def substitute!(selector, values, format_for_presentation = T.unsafe(nil)); end - - private - - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#21 - def matcher_for(value, format_for_presentation); end - - # @return [Boolean] - # - # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#30 - def substitutable?(value); end -end diff --git a/sorbet/rbi/gems/rails-dom-testing@2.2.0.rbi b/sorbet/rbi/gems/rails-dom-testing@2.2.0.rbi new file mode 100644 index 000000000..3e86ff77c --- /dev/null +++ b/sorbet/rbi/gems/rails-dom-testing@2.2.0.rbi @@ -0,0 +1,758 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `rails-dom-testing` gem. +# Please instead update this file by running `bin/tapioca gem rails-dom-testing`. + + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#3 +module Rails + class << self + # source://railties/7.2.0/lib/rails.rb#44 + def app_class; end + + # source://railties/7.2.0/lib/rails.rb#44 + def app_class=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#45 + def application; end + + # source://railties/7.2.0/lib/rails.rb#43 + def application=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#126 + def autoloaders; end + + # source://railties/7.2.0/lib/rails.rb#56 + def backtrace_cleaner; end + + # source://railties/7.2.0/lib/rails.rb#44 + def cache; end + + # source://railties/7.2.0/lib/rails.rb#44 + def cache=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#52 + def configuration; end + + # source://railties/7.2.0/lib/rails/deprecator.rb#4 + def deprecator; end + + # source://railties/7.2.0/lib/rails.rb#75 + def env; end + + # source://railties/7.2.0/lib/rails.rb#82 + def env=(environment); end + + # source://railties/7.2.0/lib/rails.rb#93 + def error; end + + # source://railties/7.2.0/lib/rails/gem_version.rb#5 + def gem_version; end + + # source://railties/7.2.0/lib/rails.rb#106 + def groups(*groups); end + + # source://railties/7.2.0/lib/rails.rb#49 + def initialize!(*_arg0, **_arg1, &_arg2); end + + # source://railties/7.2.0/lib/rails.rb#49 + def initialized?(*_arg0, **_arg1, &_arg2); end + + # source://railties/7.2.0/lib/rails.rb#44 + def logger; end + + # source://railties/7.2.0/lib/rails.rb#44 + def logger=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#122 + def public_path; end + + # source://railties/7.2.0/lib/rails.rb#65 + def root; end + + # source://railties/7.2.0/lib/rails/version.rb#7 + def version; end + end +end + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#4 +module Rails::Dom; end + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#5 +module Rails::Dom::Testing + # source://rails-dom-testing//lib/rails/dom/testing.rb#12 + def default_html_version; end + + # source://rails-dom-testing//lib/rails/dom/testing.rb#12 + def default_html_version=(val); end + + class << self + # source://rails-dom-testing//lib/rails/dom/testing.rb#12 + def default_html_version; end + + # source://rails-dom-testing//lib/rails/dom/testing.rb#12 + def default_html_version=(val); end + + # @return [Boolean] + # + # source://rails-dom-testing//lib/rails/dom/testing.rb#15 + def html5_support?; end + + # source://rails-dom-testing//lib/rails/dom/testing.rb#19 + def html_document(html_version: T.unsafe(nil)); end + + # source://rails-dom-testing//lib/rails/dom/testing.rb#26 + def html_document_fragment(html_version: T.unsafe(nil)); end + + private + + # source://rails-dom-testing//lib/rails/dom/testing.rb#34 + def choose_html_parser(parser_classes, html_version: T.unsafe(nil)); end + end +end + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#6 +module Rails::Dom::Testing::Assertions + include ::Rails::Dom::Testing::Assertions::DomAssertions + include ::Rails::Dom::Testing::Assertions::SelectorAssertions +end + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#7 +module Rails::Dom::Testing::Assertions::DomAssertions + # \Test two HTML strings for equivalency (e.g., equal even when attributes are in another order) + # + # # assert that the referenced method generates the appropriate HTML string + # assert_dom_equal( + # 'Apples', + # link_to("Apples", "http://www.example.com"), + # ) + # + # By default, the matcher will not pay attention to whitespace in text nodes (e.g., spaces + # and newlines). If you want stricter matching with exact matching for whitespace, pass + # strict: true: + # + # # these assertions will both pass + # assert_dom_equal "
\nfoo\n\
", "
foo
", strict: false + # assert_dom_not_equal "
\nfoo\n\
", "
foo
", strict: true + # + # The DOMs are created using an HTML parser specified by + # Rails::Dom::Testing.default_html_version (either :html4 or :html5). + # + # When testing in a Rails application, the parser default can also be set by setting + # +Rails.application.config.dom_testing_default_html_version+. + # + # If you want to specify the HTML parser just for a particular assertion, pass + # html_version: :html4 or html_version: :html5 keyword arguments: + # + # assert_dom_equal expected, actual, html_version: :html5 + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#35 + def assert_dom_equal(expected, actual, message = T.unsafe(nil), strict: T.unsafe(nil), html_version: T.unsafe(nil)); end + + # The negated form of +assert_dom_equal+. + # + # # assert that the referenced method does not generate the specified HTML string + # assert_dom_not_equal( + # 'Apples', + # link_to("Oranges", "http://www.example.com"), + # ) + # + # By default, the matcher will not pay attention to whitespace in text nodes (e.g., spaces + # and newlines). If you want stricter matching with exact matching for whitespace, pass + # strict: true: + # + # # these assertions will both pass + # assert_dom_equal "
\nfoo\n\
", "
foo
", strict: false + # assert_dom_not_equal "
\nfoo\n\
", "
foo
", strict: true + # + # The DOMs are created using an HTML parser specified by + # Rails::Dom::Testing.default_html_version (either :html4 or :html5). + # + # When testing in a Rails application, the parser default can also be set by setting + # +Rails.application.config.dom_testing_default_html_version+. + # + # If you want to specify the HTML parser just for a particular assertion, pass + # html_version: :html4 or html_version: :html5 keyword arguments: + # + # assert_dom_not_equal expected, actual, html_version: :html5 + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#68 + def assert_dom_not_equal(expected, actual, message = T.unsafe(nil), strict: T.unsafe(nil), html_version: T.unsafe(nil)); end + + protected + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#75 + def compare_doms(expected, actual, strict); end + + # @return [Boolean] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#128 + def equal_attribute?(attr, other_attr); end + + # @return [Boolean] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#115 + def equal_attribute_nodes?(nodes, other_nodes); end + + # @return [Boolean] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#107 + def equal_child?(child, other_child, strict); end + + # @return [Boolean] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#95 + def equal_children?(child, other_child, strict); end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#87 + def extract_children(node, strict); end + + private + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/dom_assertions.rb#133 + def fragment(text, html_version: T.unsafe(nil)); end +end + +# Adds the +assert_dom+ method for use in Rails functional +# test cases, which can be used to make assertions on the response HTML of a controller +# action. You can also call +assert_dom+ within another +assert_dom+ to +# make assertions on elements selected by the enclosing assertion. +# +# Use +css_select+ to select elements without making an assertions, either +# from the response HTML or elements selected by the enclosing assertion. +# +# In addition to HTML responses, you can make the following assertions: +# +# * +assert_dom_encoded+ - Assertions on HTML encoded inside XML, for example for dealing with feed item descriptions. +# * +assert_dom_email+ - Assertions on the HTML body of an e-mail. +# +# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#7 +module Rails::Dom::Testing::Assertions::SelectorAssertions + # An assertion that selects elements and makes one or more equality tests. + # + # If the first argument is an element, selects all matching elements + # starting from (and including) that element and all its children in + # depth-first order. + # + # If no element is specified +assert_dom+ selects from + # the element returned in +document_root_element+ + # unless +assert_dom+ is called from within an +assert_dom+ block. + # Override +document_root_element+ to tell +assert_dom+ what to select from. + # The default implementation raises an exception explaining this. + # + # When called with a block +assert_dom+ passes an array of selected elements + # to the block. Calling +assert_dom+ from the block, with no element specified, + # runs the assertion on the complete set of elements selected by the enclosing assertion. + # Alternatively the array may be iterated through so that +assert_dom+ can be called + # separately for each element. + # + # + # ==== Example + # If the response contains two ordered lists, each with four list elements then: + # assert_dom "ol" do |elements| + # elements.each do |element| + # assert_dom element, "li", 4 + # end + # end + # + # will pass, as will: + # assert_dom "ol" do + # assert_dom "li", 8 + # end + # + # The selector may be a CSS selector expression (String, Symbol, or Numeric) or an expression + # with substitution values (Array). + # Substitution uses a custom pseudo class match. Pass in whatever attribute you want to match (enclosed in quotes) and a ? for the substitution. + # assert_dom returns nil if called with an invalid css selector. + # + # assert_dom "div:match('id', ?)", "id_string" + # assert_dom "div:match('id', ?)", :id_string + # assert_dom "div:match('id', ?)", 1 + # assert_dom "div:match('id', ?)", /\d+/ + # + # === Equality Tests + # + # The equality test may be one of the following: + # * true - Assertion is true if at least one element selected. + # * false - Assertion is true if no element selected. + # * String/Regexp - Assertion is true if the text value of at least + # one element matches the string or regular expression. + # * Integer - Assertion is true if exactly that number of + # elements are selected. + # * Range - Assertion is true if the number of selected + # elements fit the range. + # If no equality test specified, the assertion is true if at least one + # element selected. + # + # To perform more than one equality tests, use a hash with the following keys: + # * :text - Narrow the selection to elements that have this text + # value (string or regexp). + # * :html - Narrow the selection to elements that have this HTML + # content (string or regexp). + # * :count - Assertion is true if the number of selected elements + # is equal to this value. + # * :minimum - Assertion is true if the number of selected + # elements is at least this value. + # * :maximum - Assertion is true if the number of selected + # elements is at most this value. + # + # If the method is called with a block, once all equality tests are + # evaluated the block is called with an array of all matched elements. + # + # # At least one form element + # assert_dom "form" + # + # # Form element includes four input fields + # assert_dom "form input", 4 + # + # # Page title is "Welcome" + # assert_dom "title", "Welcome" + # + # # Page title is "Welcome" and there is only one title element + # assert_dom "title", {count: 1, text: "Welcome"}, + # "Wrong title or more than one title element" + # + # # Page contains no forms + # assert_dom "form", false, "This page must contain no forms" + # + # # Test the content and style + # assert_dom "body div.header ul.menu" + # + # # Use substitution values + # assert_dom "ol>li:match('id', ?)", /item-\d+/ + # + # # All input fields in the form have a name + # assert_dom "form input" do + # assert_dom ":match('name', ?)", /.+/ # Not empty + # end + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#163 + def assert_dom(*args, &block); end + + # Extracts the body of an email and runs nested assertions on it. + # + # You must enable deliveries for this assertion to work, use: + # ActionMailer::Base.perform_deliveries = true + # + # Example usage: + # + # assert_dom_email do + # assert_dom "h1", "Email alert" + # end + # + # assert_dom_email do + # items = assert_dom "ol>li" + # items.each do + # # Work with items here... + # end + # end + # + # The DOM is created using an HTML parser specified by + # Rails::Dom::Testing.default_html_version (either :html4 or :html5). + # + # When testing in a Rails application, the parser default can also be set by setting + # +Rails.application.config.dom_testing_default_html_version+. + # + # If you want to specify the HTML parser just for a particular assertion, pass + # html_version: :html4 or html_version: :html5 keyword arguments: + # + # assert_dom_email(html_version: :html5) do + # assert_dom "h1", "Email alert" + # end + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#285 + def assert_dom_email(html_version: T.unsafe(nil), &block); end + + # Extracts the content of an element, treats it as encoded HTML and runs + # nested assertion on it. + # + # You typically call this method within another assertion to operate on + # all currently selected elements. You can also pass an element or array + # of elements. + # + # The content of each element is un-encoded, and wrapped in the root + # element +encoded+. It then calls the block with all un-encoded elements. + # + # # Selects all bold tags from within the title of an Atom feed's entries (perhaps to nab a section name prefix) + # assert_dom "feed[xmlns='http://www.w3.org/2005/Atom']" do + # # Select each entry item and then the title item + # assert_dom "entry>title" do + # # Run assertions on the encoded title elements + # assert_dom_encoded do + # assert_dom "b" + # end + # end + # end + # + # + # # Selects all paragraph tags from within the description of an RSS feed + # assert_dom "rss[version=2.0]" do + # # Select description element of each feed item. + # assert_dom "channel>item>description" do + # # Run assertions on the encoded elements. + # assert_dom_encoded do + # assert_dom "p" + # end + # end + # end + # + # The DOM is created using an HTML parser specified by + # Rails::Dom::Testing.default_html_version (either :html4 or :html5). + # + # When testing in a Rails application, the parser default can also be set by setting + # +Rails.application.config.dom_testing_default_html_version+. + # + # If you want to specify the HTML parser just for a particular assertion, pass + # html_version: :html4 or html_version: :html5 keyword arguments: + # + # assert_dom "feed[xmlns='http://www.w3.org/2005/Atom']" do + # assert_dom "entry>title" do + # assert_dom_encoded(html_version: :html5) do + # assert_dom "b" + # end + # end + # end + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#232 + def assert_dom_encoded(element = T.unsafe(nil), html_version: T.unsafe(nil), &block); end + + # An assertion that selects elements and makes one or more equality tests. + # + # If the first argument is an element, selects all matching elements + # starting from (and including) that element and all its children in + # depth-first order. + # + # If no element is specified +assert_dom+ selects from + # the element returned in +document_root_element+ + # unless +assert_dom+ is called from within an +assert_dom+ block. + # Override +document_root_element+ to tell +assert_dom+ what to select from. + # The default implementation raises an exception explaining this. + # + # When called with a block +assert_dom+ passes an array of selected elements + # to the block. Calling +assert_dom+ from the block, with no element specified, + # runs the assertion on the complete set of elements selected by the enclosing assertion. + # Alternatively the array may be iterated through so that +assert_dom+ can be called + # separately for each element. + # + # + # ==== Example + # If the response contains two ordered lists, each with four list elements then: + # assert_dom "ol" do |elements| + # elements.each do |element| + # assert_dom element, "li", 4 + # end + # end + # + # will pass, as will: + # assert_dom "ol" do + # assert_dom "li", 8 + # end + # + # The selector may be a CSS selector expression (String, Symbol, or Numeric) or an expression + # with substitution values (Array). + # Substitution uses a custom pseudo class match. Pass in whatever attribute you want to match (enclosed in quotes) and a ? for the substitution. + # assert_dom returns nil if called with an invalid css selector. + # + # assert_dom "div:match('id', ?)", "id_string" + # assert_dom "div:match('id', ?)", :id_string + # assert_dom "div:match('id', ?)", 1 + # assert_dom "div:match('id', ?)", /\d+/ + # + # === Equality Tests + # + # The equality test may be one of the following: + # * true - Assertion is true if at least one element selected. + # * false - Assertion is true if no element selected. + # * String/Regexp - Assertion is true if the text value of at least + # one element matches the string or regular expression. + # * Integer - Assertion is true if exactly that number of + # elements are selected. + # * Range - Assertion is true if the number of selected + # elements fit the range. + # If no equality test specified, the assertion is true if at least one + # element selected. + # + # To perform more than one equality tests, use a hash with the following keys: + # * :text - Narrow the selection to elements that have this text + # value (string or regexp). + # * :html - Narrow the selection to elements that have this HTML + # content (string or regexp). + # * :count - Assertion is true if the number of selected elements + # is equal to this value. + # * :minimum - Assertion is true if the number of selected + # elements is at least this value. + # * :maximum - Assertion is true if the number of selected + # elements is at most this value. + # + # If the method is called with a block, once all equality tests are + # evaluated the block is called with an array of all matched elements. + # + # # At least one form element + # assert_dom "form" + # + # # Form element includes four input fields + # assert_dom "form input", 4 + # + # # Page title is "Welcome" + # assert_dom "title", "Welcome" + # + # # Page title is "Welcome" and there is only one title element + # assert_dom "title", {count: 1, text: "Welcome"}, + # "Wrong title or more than one title element" + # + # # Page contains no forms + # assert_dom "form", false, "This page must contain no forms" + # + # # Test the content and style + # assert_dom "body div.header ul.menu" + # + # # Use substitution values + # assert_dom "ol>li:match('id', ?)", /item-\d+/ + # + # # All input fields in the form have a name + # assert_dom "form input" do + # assert_dom ":match('name', ?)", /.+/ # Not empty + # end + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#163 + def assert_select(*args, &block); end + + # Extracts the body of an email and runs nested assertions on it. + # + # You must enable deliveries for this assertion to work, use: + # ActionMailer::Base.perform_deliveries = true + # + # Example usage: + # + # assert_dom_email do + # assert_dom "h1", "Email alert" + # end + # + # assert_dom_email do + # items = assert_dom "ol>li" + # items.each do + # # Work with items here... + # end + # end + # + # The DOM is created using an HTML parser specified by + # Rails::Dom::Testing.default_html_version (either :html4 or :html5). + # + # When testing in a Rails application, the parser default can also be set by setting + # +Rails.application.config.dom_testing_default_html_version+. + # + # If you want to specify the HTML parser just for a particular assertion, pass + # html_version: :html4 or html_version: :html5 keyword arguments: + # + # assert_dom_email(html_version: :html5) do + # assert_dom "h1", "Email alert" + # end + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#285 + def assert_select_email(html_version: T.unsafe(nil), &block); end + + # Extracts the content of an element, treats it as encoded HTML and runs + # nested assertion on it. + # + # You typically call this method within another assertion to operate on + # all currently selected elements. You can also pass an element or array + # of elements. + # + # The content of each element is un-encoded, and wrapped in the root + # element +encoded+. It then calls the block with all un-encoded elements. + # + # # Selects all bold tags from within the title of an Atom feed's entries (perhaps to nab a section name prefix) + # assert_dom "feed[xmlns='http://www.w3.org/2005/Atom']" do + # # Select each entry item and then the title item + # assert_dom "entry>title" do + # # Run assertions on the encoded title elements + # assert_dom_encoded do + # assert_dom "b" + # end + # end + # end + # + # + # # Selects all paragraph tags from within the description of an RSS feed + # assert_dom "rss[version=2.0]" do + # # Select description element of each feed item. + # assert_dom "channel>item>description" do + # # Run assertions on the encoded elements. + # assert_dom_encoded do + # assert_dom "p" + # end + # end + # end + # + # The DOM is created using an HTML parser specified by + # Rails::Dom::Testing.default_html_version (either :html4 or :html5). + # + # When testing in a Rails application, the parser default can also be set by setting + # +Rails.application.config.dom_testing_default_html_version+. + # + # If you want to specify the HTML parser just for a particular assertion, pass + # html_version: :html4 or html_version: :html5 keyword arguments: + # + # assert_dom "feed[xmlns='http://www.w3.org/2005/Atom']" do + # assert_dom "entry>title" do + # assert_dom_encoded(html_version: :html5) do + # assert_dom "b" + # end + # end + # end + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#232 + def assert_select_encoded(element = T.unsafe(nil), html_version: T.unsafe(nil), &block); end + + # Select and return all matching elements. + # + # If called with a single argument, uses that argument as a selector. + # Called without an element +css_select+ selects from + # the element returned in +document_root_element+ + # + # The default implementation of +document_root_element+ raises an exception explaining this. + # + # Returns an empty Nokogiri::XML::NodeSet if no match is found. + # + # If called with two arguments, uses the first argument as the root + # element and the second argument as the selector. Attempts to match the + # root element and any of its children. + # Returns an empty Nokogiri::XML::NodeSet if no match is found. + # + # The selector may be a CSS selector expression (String). + # css_select returns nil if called with an invalid css selector. + # + # # Selects all div tags + # divs = css_select("div") + # + # # Selects all paragraph tags and does something interesting + # pars = css_select("p") + # pars.each do |par| + # # Do something fun with paragraphs here... + # end + # + # # Selects all list items in unordered lists + # items = css_select("ul>li") + # + # # Selects all form tags and then all inputs inside the form + # forms = css_select("form") + # forms.each do |form| + # inputs = css_select(form, "input") + # ... + # end + # + # @raise [ArgumentError] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#58 + def css_select(*args); end + + private + + # +equals+ must contain :minimum, :maximum and :count keys + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#307 + def assert_size_match!(size, equals, css_selector, message = T.unsafe(nil)); end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#319 + def count_description(min, max, count); end + + # @raise [NotImplementedError] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#301 + def document_root_element; end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#335 + def nest_selection(selection); end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#344 + def nodeset(node); end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions.rb#331 + def pluralize_element(quantity); end +end + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#12 +class Rails::Dom::Testing::Assertions::SelectorAssertions::HTMLSelector + include ::Minitest::Assertions + + # @return [HTMLSelector] a new instance of HTMLSelector + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#17 + def initialize(values, previous_selection = T.unsafe(nil), &root_fallback); end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#46 + def context; end + + # Returns the value of attribute css_selector. + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#13 + def css_selector; end + + # Returns the value of attribute message. + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#13 + def message; end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#39 + def select; end + + # @return [Boolean] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#33 + def selecting_no_body?; end + + # Returns the value of attribute tests. + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#13 + def tests; end + + private + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#100 + def extract_equality_tests; end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#72 + def extract_root(previous_selection, root_fallback); end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#89 + def extract_selectors; end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#48 + def filter(matches); end + + class << self + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#46 + def context; end + end +end + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/html_selector.rb#44 +Rails::Dom::Testing::Assertions::SelectorAssertions::HTMLSelector::NO_STRIP = T.let(T.unsafe(nil), Array) + +# source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#8 +class Rails::Dom::Testing::Assertions::SelectorAssertions::SubstitutionContext + # @return [SubstitutionContext] a new instance of SubstitutionContext + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#9 + def initialize; end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#20 + def match(matches, attribute, matcher); end + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#13 + def substitute!(selector, values, format_for_presentation = T.unsafe(nil)); end + + private + + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#25 + def matcher_for(value, format_for_presentation); end + + # @return [Boolean] + # + # source://rails-dom-testing//lib/rails/dom/testing/assertions/selector_assertions/substitution_context.rb#36 + def substitutable?(value); end +end + +# source://rails-dom-testing//lib/rails/dom/testing/railtie.rb#6 +class Rails::Dom::Testing::Railtie < ::Rails::Railtie; end diff --git a/sorbet/rbi/gems/rails-html-sanitizer@1.6.0.rbi b/sorbet/rbi/gems/rails-html-sanitizer@1.6.0.rbi index c14b0e263..2993fc2b3 100644 --- a/sorbet/rbi/gems/rails-html-sanitizer@1.6.0.rbi +++ b/sorbet/rbi/gems/rails-html-sanitizer@1.6.0.rbi @@ -4,23 +4,24 @@ # This is an autogenerated file for types exported from the `rails-html-sanitizer` gem. # Please instead update this file by running `bin/tapioca gem rails-html-sanitizer`. + # source://rails-html-sanitizer//lib/rails-html-sanitizer.rb#14 module ActionView class << self - # source://actionview/7.0.5/lib/action_view.rb#90 + # source://actionview/7.2.0/lib/action_view/deprecator.rb#4 + def deprecator; end + + # source://actionview/7.2.0/lib/action_view.rb#93 def eager_load!; end - # source://actionview/7.0.5/lib/action_view/gem_version.rb#5 + # source://actionview/7.2.0/lib/action_view/gem_version.rb#5 def gem_version; end - # source://actionview/7.0.5/lib/action_view/version.rb#7 + # source://actionview/7.2.0/lib/action_view/version.rb#7 def version; end end end -# source://actionview/7.0.5/lib/action_view.rb#33 -ActionView::ENCODING_FLAG = T.let(T.unsafe(nil), String) - # source://rails-html-sanitizer//lib/rails-html-sanitizer.rb#15 module ActionView::Helpers include ::ActionView::Helpers::SanitizeHelper @@ -36,7 +37,7 @@ module ActionView::Helpers mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods class << self - # source://actionview/7.0.5/lib/action_view/helpers.rb#34 + # source://actionview/7.2.0/lib/action_view/helpers.rb#35 def eager_load!; end end end @@ -45,40 +46,54 @@ end module ActionView::Helpers::SanitizeHelper mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#81 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#111 def sanitize(html, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#86 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#116 def sanitize_css(style); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#120 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor; end + + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor=(val); end + + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#150 def strip_links(html); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#103 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#133 def strip_tags(html); end + + class << self + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor; end + + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#12 + def sanitizer_vendor=(val); end + end end # source://rails-html-sanitizer//lib/rails-html-sanitizer.rb#17 module ActionView::Helpers::SanitizeHelper::ClassMethods - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#145 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#175 def full_sanitizer; end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#125 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#155 def full_sanitizer=(_arg0); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#155 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#185 def link_sanitizer; end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#125 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#155 def link_sanitizer=(_arg0); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#165 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#195 def safe_list_sanitizer; end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#125 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#155 def safe_list_sanitizer=(_arg0); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#135 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#165 def sanitized_allowed_attributes; end # Replaces the allowed HTML attributes for the +sanitize+ helper. @@ -108,7 +123,7 @@ module ActionView::Helpers::SanitizeHelper::ClassMethods # source://rails-html-sanitizer//lib/rails-html-sanitizer.rb#48 def sanitized_allowed_protocols=(_); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#131 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#161 def sanitized_allowed_tags; end # Replaces the allowed tags for the +sanitize+ helper. @@ -144,7 +159,7 @@ module ActionView::Helpers::SanitizeHelper::ClassMethods # source://rails-html-sanitizer//lib/rails-html-sanitizer.rb#48 def sanitized_uri_attributes=(_); end - # source://actionview/7.0.5/lib/action_view/helpers/sanitize_helper.rb#127 + # source://actionview/7.2.0/lib/action_view/helpers/sanitize_helper.rb#157 def sanitizer_vendor; end private @@ -153,73 +168,73 @@ module ActionView::Helpers::SanitizeHelper::ClassMethods def deprecate_option(name); end end -# source://actionview/7.0.5/lib/action_view/template/error.rb#230 -ActionView::TemplateError = ActionView::Template::Error - # source://rails-html-sanitizer//lib/rails/html/sanitizer/version.rb#3 module Rails class << self - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def app_class; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def app_class=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#39 + # source://railties/7.2.0/lib/rails.rb#45 def application; end - # source://railties/7.0.5/lib/rails.rb#37 + # source://railties/7.2.0/lib/rails.rb#43 def application=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#123 + # source://railties/7.2.0/lib/rails.rb#126 def autoloaders; end - # source://railties/7.0.5/lib/rails.rb#50 + # source://railties/7.2.0/lib/rails.rb#56 def backtrace_cleaner; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def cache; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def cache=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#46 + # source://railties/7.2.0/lib/rails.rb#52 def configuration; end - # source://railties/7.0.5/lib/rails.rb#72 + # source://railties/7.2.0/lib/rails/deprecator.rb#4 + def deprecator; end + + # source://railties/7.2.0/lib/rails.rb#75 def env; end - # source://railties/7.0.5/lib/rails.rb#79 + # source://railties/7.2.0/lib/rails.rb#82 def env=(environment); end - # source://railties/7.0.5/lib/rails.rb#90 + # source://railties/7.2.0/lib/rails.rb#93 def error; end - # source://railties/7.0.5/lib/rails/gem_version.rb#5 + # source://railties/7.2.0/lib/rails/gem_version.rb#5 def gem_version; end - # source://railties/7.0.5/lib/rails.rb#103 + # source://railties/7.2.0/lib/rails.rb#106 def groups(*groups); end - # source://railties/7.0.5/lib/rails.rb#43 + # source://railties/7.2.0/lib/rails.rb#49 def initialize!(*_arg0, **_arg1, &_arg2); end - # source://railties/7.0.5/lib/rails.rb#43 + # source://railties/7.2.0/lib/rails.rb#49 def initialized?(*_arg0, **_arg1, &_arg2); end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def logger; end - # source://railties/7.0.5/lib/rails.rb#38 + # source://railties/7.2.0/lib/rails.rb#44 def logger=(_arg0); end - # source://railties/7.0.5/lib/rails.rb#119 + # source://railties/7.2.0/lib/rails.rb#122 def public_path; end - # source://railties/7.0.5/lib/rails.rb#63 + # source://railties/7.2.0/lib/rails.rb#65 def root; end - # source://railties/7.0.5/lib/rails/version.rb#7 + # source://railties/7.2.0/lib/rails/version.rb#7 def version; end end end diff --git a/sorbet/rbi/gems/rails@7.0.5.rbi b/sorbet/rbi/gems/rails@7.2.0.rbi similarity index 99% rename from sorbet/rbi/gems/rails@7.0.5.rbi rename to sorbet/rbi/gems/rails@7.2.0.rbi index a789f5918..e414d2594 100644 --- a/sorbet/rbi/gems/rails@7.0.5.rbi +++ b/sorbet/rbi/gems/rails@7.2.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `rails` gem. # Please instead update this file by running `bin/tapioca gem rails`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/railties@7.0.5.rbi b/sorbet/rbi/gems/railties@7.2.0.rbi similarity index 65% rename from sorbet/rbi/gems/railties@7.0.5.rbi rename to sorbet/rbi/gems/railties@7.2.0.rbi index 933fbdc4d..eda901bc5 100644 --- a/sorbet/rbi/gems/railties@7.0.5.rbi +++ b/sorbet/rbi/gems/railties@7.2.0.rbi @@ -4,7 +4,10 @@ # This is an autogenerated file for types exported from the `railties` gem. # Please instead update this file by running `bin/tapioca gem railties`. -# source://railties//lib/rails/initializable.rb#5 + +# :include: ../README.rdoc +# +# source://railties//lib/rails/gem_version.rb#3 module Rails extend ::ActiveSupport::Autoload extend ::ActiveSupport::Benchmarkable @@ -12,66 +15,70 @@ module Rails class << self # Returns the value of attribute app_class. # - # source://railties//lib/rails.rb#38 + # source://railties//lib/rails.rb#44 def app_class; end # Sets the attribute app_class # # @param value the value to set the attribute app_class to. # - # source://railties//lib/rails.rb#38 + # source://railties//lib/rails.rb#44 def app_class=(_arg0); end - # source://railties//lib/rails.rb#39 + # source://railties//lib/rails.rb#45 def application; end # Sets the attribute application # # @param value the value to set the attribute application to. # - # source://railties//lib/rails.rb#37 + # source://railties//lib/rails.rb#43 def application=(_arg0); end - # source://railties//lib/rails.rb#123 + # source://railties//lib/rails.rb#126 def autoloaders; end - # source://railties//lib/rails.rb#50 + # source://railties//lib/rails.rb#56 def backtrace_cleaner; end # Returns the value of attribute cache. # - # source://railties//lib/rails.rb#38 + # source://railties//lib/rails.rb#44 def cache; end # Sets the attribute cache # # @param value the value to set the attribute cache to. # - # source://railties//lib/rails.rb#38 + # source://railties//lib/rails.rb#44 def cache=(_arg0); end - # The Configuration instance used to configure the Rails environment + # The Configuration instance used to configure the \Rails environment # - # source://railties//lib/rails.rb#46 + # source://railties//lib/rails.rb#52 def configuration; end - # Returns the current Rails environment. + # source://railties//lib/rails/deprecator.rb#4 + def deprecator; end + + # Returns the current \Rails environment. # # Rails.env # => "development" # Rails.env.development? # => true # Rails.env.production? # => false + # Rails.env.local? # => true true for "development" and "test", false for anything else # - # source://railties//lib/rails.rb#72 + # source://railties//lib/rails.rb#75 def env; end - # Sets the Rails environment. + # Sets the \Rails environment. # # Rails.env = "staging" # => "staging" # - # source://railties//lib/rails.rb#79 + # source://railties//lib/rails.rb#82 def env=(environment); end - # Returns the ActiveSupport::ErrorReporter of the current Rails project, + # Returns the ActiveSupport::ErrorReporter of the current \Rails project, # otherwise it returns +nil+ if there is no project. # # Rails.error.handle(IOError) do @@ -79,17 +86,17 @@ module Rails # end # Rails.error.report(error) # - # source://railties//lib/rails.rb#90 + # source://railties//lib/rails.rb#93 def error; end - # Returns the currently loaded version of Rails as a Gem::Version. + # Returns the currently loaded version of \Rails as a +Gem::Version+. # # source://railties//lib/rails/gem_version.rb#5 def gem_version; end - # Returns all Rails groups for loading based on: + # Returns all \Rails groups for loading based on: # - # * The Rails environment; + # * The \Rails environment; # * The environment variable RAILS_GROUPS; # * The optional envs given as argument and the hash with group dependencies; # @@ -97,46 +104,46 @@ module Rails # # => [:default, "development", :assets] for Rails.env == "development" # # => [:default, "production"] for Rails.env == "production" # - # source://railties//lib/rails.rb#103 + # source://railties//lib/rails.rb#106 def groups(*groups); end - # source://railties//lib/rails.rb#43 + # source://railties//lib/rails.rb#49 def initialize!(*_arg0, **_arg1, &_arg2); end - # source://railties//lib/rails.rb#43 + # source://railties//lib/rails.rb#49 def initialized?(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute logger. # - # source://railties//lib/rails.rb#38 + # source://railties//lib/rails.rb#44 def logger; end # Sets the attribute logger # # @param value the value to set the attribute logger to. # - # source://railties//lib/rails.rb#38 + # source://railties//lib/rails.rb#44 def logger=(_arg0); end # Returns a Pathname object of the public folder of the current - # Rails project, otherwise it returns +nil+ if there is no project: + # \Rails project, otherwise it returns +nil+ if there is no project: # # Rails.public_path # # => # # - # source://railties//lib/rails.rb#119 + # source://railties//lib/rails.rb#122 def public_path; end - # Returns a Pathname object of the current Rails project, + # Returns a Pathname object of the current \Rails project, # otherwise it returns +nil+ if there is no project: # # Rails.root # # => # # - # source://railties//lib/rails.rb#63 + # source://railties//lib/rails.rb#65 def root; end - # Returns the currently loaded version of Rails as a string. + # Returns the currently loaded version of \Rails as a string. # # source://railties//lib/rails/version.rb#7 def version; end @@ -156,7 +163,7 @@ end # # Besides providing the same configuration as Rails::Engine and Rails::Railtie, # the application object has several specific configurations, for example -# +cache_classes+, +consider_all_requests_local+, +filter_parameters+, +# +enable_reloading+, +consider_all_requests_local+, +filter_parameters+, # +logger+, and so forth. # # Check Rails::Application::Configuration to see them all. @@ -193,51 +200,50 @@ end class Rails::Application < ::Rails::Engine # @return [Application] a new instance of Application # - # source://railties//lib/rails/application.rb#106 + # source://railties//lib/rails/application.rb#108 def initialize(initial_variable_values = T.unsafe(nil), &block); end - # source://sprockets-rails/3.4.2/lib/sprockets/railtie.rb#37 + # source://sprockets-rails/3.5.2/lib/sprockets/railtie.rb#38 def asset_precompiled?(logical_path); end # Returns the value of attribute assets. # - # source://sprockets-rails/3.4.2/lib/sprockets/railtie.rb#30 + # source://sprockets-rails/3.5.2/lib/sprockets/railtie.rb#31 def assets; end # Sets the attribute assets # # @param value the value to set the attribute assets to. # - # source://sprockets-rails/3.4.2/lib/sprockets/railtie.rb#30 + # source://sprockets-rails/3.5.2/lib/sprockets/railtie.rb#31 def assets=(_arg0); end - # source://sprockets-rails/3.4.2/lib/sprockets/railtie.rb#33 + # source://sprockets-rails/3.5.2/lib/sprockets/railtie.rb#34 def assets_manifest; end - # source://sprockets-rails/3.4.2/lib/sprockets/railtie.rb#33 + # source://sprockets-rails/3.5.2/lib/sprockets/railtie.rb#34 def assets_manifest=(_arg0); end # Returns the value of attribute autoloaders. # - # source://railties//lib/rails/application.rb#99 + # source://railties//lib/rails/application.rb#101 def autoloaders; end - # source://railties//lib/rails/engine.rb#511 + # source://railties//lib/rails/engine.rb#516 def build_middleware_stack; end - # source://railties//lib/rails/application.rb#383 + # source://railties//lib/rails/application.rb#439 def config; end # Sets the attribute config # # @param value the value to set the attribute config to. # - # source://railties//lib/rails/application.rb#387 + # source://railties//lib/rails/application.rb#443 def config=(_arg0); end - # Convenience for loading config/foo.yml for the current Rails env. - # - # Examples: + # Convenience for loading config/foo.yml for the current \Rails env. + # Example: # # # config/exception_notification.yml: # production: @@ -248,13 +254,15 @@ class Rails::Application < ::Rails::Engine # url: http://localhost:3001 # namespace: my_app_development # + # + # # # config/environments/production.rb # Rails.application.configure do # config.middleware.use ExceptionNotifier, config_for(:exception_notification) # end # - # # You can also store configurations in a shared section which will be - # # merged with the environment configuration + # You can also store configurations in a shared section which will be merged + # with the environment configuration # # # config/example.yml # shared: @@ -267,17 +275,19 @@ class Rails::Application < ::Rails::Engine # bar: # qux: 2 # + # + # # # development environment # Rails.application.config_for(:example)[:foo][:bar] # # => { baz: 1, qux: 2 } # - # source://railties//lib/rails/application.rb#221 + # source://railties//lib/rails/application.rb#276 def config_for(name, env: T.unsafe(nil)); end # Sends any console called in the instance of a new application up # to the +console+ method defined in Rails::Railtie. # - # source://railties//lib/rails/application.rb#303 + # source://railties//lib/rails/application.rb#359 def console(&blk); end # Returns an ActiveSupport::EncryptedConfiguration instance for the @@ -295,25 +305,33 @@ class Rails::Application < ::Rails::Engine # config/credentials/#{environment}.key for the current # environment, or +config/master.key+ if that file does not exist. # - # source://railties//lib/rails/application.rb#439 + # source://railties//lib/rails/application.rb#480 def credentials; end # Sets the attribute credentials # # @param value the value to set the attribute credentials to. # - # source://railties//lib/rails/application.rb#403 + # source://railties//lib/rails/application.rb#444 def credentials=(_arg0); end - # source://railties//lib/rails/application.rb#101 + # source://railties//lib/rails/application.rb#103 def default_url_options(*_arg0, **_arg1, &_arg2); end - # source://railties//lib/rails/application.rb#101 + # source://railties//lib/rails/application.rb#103 def default_url_options=(arg); end + # A managed collection of deprecators (ActiveSupport::Deprecation::Deprecators). + # The collection's configuration methods affect all deprecators in the + # collection. Additionally, the collection's +silence+ method silences all + # deprecators in the collection for the duration of a given block. + # + # source://railties//lib/rails/application.rb#232 + def deprecators; end + # Eager loads the application code. # - # source://railties//lib/rails/application.rb#492 + # source://railties//lib/rails/application.rb#538 def eager_load!; end # Returns an ActiveSupport::EncryptedConfiguration instance for an encrypted @@ -332,67 +350,73 @@ class Rails::Application < ::Rails::Engine # command. (See the output of bin/rails encrypted:edit --help for # more information.) # - # source://railties//lib/rails/application.rb#458 + # source://railties//lib/rails/application.rb#499 def encrypted(path, key_path: T.unsafe(nil), env_key: T.unsafe(nil)); end - # Stores some of the Rails initial environment parameters which + # Stores some of the \Rails initial environment parameters which # will be used by middlewares and engines to configure themselves. # - # source://railties//lib/rails/application.rb#250 + # source://railties//lib/rails/application.rb#305 def env_config; end # Returns the value of attribute executor. # - # source://railties//lib/rails/application.rb#99 + # source://railties//lib/rails/application.rb#101 def executor; end # Sends any generators called in the instance of a new application up # to the +generators+ method defined in Rails::Railtie. # - # source://railties//lib/rails/application.rb#309 + # source://railties//lib/rails/application.rb#365 def generators(&blk); end - # source://railties//lib/rails/application.rb#471 + # source://railties//lib/rails/application.rb#512 def helpers_paths; end - # source://importmap-rails/1.2.1/lib/importmap/engine.rb#4 + # source://importmap-rails/2.0.1/lib/importmap/engine.rb#4 def importmap; end - # source://importmap-rails/1.2.1/lib/importmap/engine.rb#4 + # source://importmap-rails/2.0.1/lib/importmap/engine.rb#4 def importmap=(_arg0); end # Initialize the application passing the given group. By default, the # group is :default # - # source://railties//lib/rails/application.rb#370 + # source://railties//lib/rails/application.rb#426 def initialize!(group = T.unsafe(nil)); end # Returns true if the application is initialized. # # @return [Boolean] # - # source://railties//lib/rails/application.rb#129 + # source://railties//lib/rails/application.rb#133 def initialized?; end # Sends the initializers to the +initializer+ method defined in the # Rails::Initializable module. Each Rails::Application class has its own # set of initializers, as defined by the Initializable module. # - # source://railties//lib/rails/application.rb#291 + # source://railties//lib/rails/application.rb#347 def initializer(name, opts = T.unsafe(nil), &block); end - # source://railties//lib/rails/application.rb#377 + # source://railties//lib/rails/application.rb#433 def initializers; end # Sends the +isolate_namespace+ method up to the class method. # - # source://railties//lib/rails/application.rb#320 + # source://railties//lib/rails/application.rb#376 def isolate_namespace(mod); end - # Returns the application's KeyGenerator + # Returns a key generator (ActiveSupport::CachingKeyGenerator) for a + # specified +secret_key_base+. The return value is memoized, so additional + # calls with the same +secret_key_base+ will return the same key generator + # instance. # - # source://railties//lib/rails/application.rb#153 - def key_generator; end + # source://railties//lib/rails/application.rb#160 + def key_generator(secret_key_base = T.unsafe(nil)); end + + # source://railties//lib/rails/application.rb#532 + def load_generators(app = T.unsafe(nil)); end # Returns a message verifier object. # @@ -401,21 +425,55 @@ class Rails::Application < ::Rails::Engine # It is recommended not to use the same verifier for different things, so you can get different # verifiers passing the +verifier_name+ argument. # + # For instance, +ActiveStorage::Blob.signed_id_verifier+ is implemented using this feature, which assures that + # the IDs strings haven't been tampered with and are safe to use in a finder. + # + # See the ActiveSupport::MessageVerifier documentation for more information. + # # ==== Parameters # # * +verifier_name+ - the name of the message verifier. # # ==== Examples # - # message = Rails.application.message_verifier('sensitive_data').generate('my sensible data') - # Rails.application.message_verifier('sensitive_data').verify(message) - # # => 'my sensible data' - # - # See the ActiveSupport::MessageVerifier documentation for more information. + # message = Rails.application.message_verifier('my_purpose').generate('data to sign against tampering') + # Rails.application.message_verifier('my_purpose').verify(message) + # # => 'data to sign against tampering' # - # source://railties//lib/rails/application.rb#179 + # source://railties//lib/rails/application.rb#224 def message_verifier(verifier_name); end + # Returns a message verifier factory (ActiveSupport::MessageVerifiers). This + # factory can be used as a central point to configure and create message + # verifiers (ActiveSupport::MessageVerifier) for your application. + # + # By default, message verifiers created by this factory will generate + # messages using the default ActiveSupport::MessageVerifier options. You can + # override these options with a combination of + # ActiveSupport::MessageVerifiers#clear_rotations and + # ActiveSupport::MessageVerifiers#rotate. However, this must be done prior + # to building any message verifier instances. For example, in a + # +before_initialize+ block: + # + # # Use `url_safe: true` when generating messages + # config.before_initialize do |app| + # app.message_verifiers.clear_rotations + # app.message_verifiers.rotate(url_safe: true) + # end + # + # Message verifiers created by this factory will always use a secret derived + # from #secret_key_base when generating messages. +clear_rotations+ will not + # affect this behavior. However, older +secret_key_base+ values can be + # rotated for verifying messages: + # + # # Fall back to old `secret_key_base` when verifying messages + # config.before_initialize do |app| + # app.message_verifiers.rotate(secret_key_base: "old secret_key_base") + # end + # + # source://railties//lib/rails/application.rb#196 + def message_verifiers; end + # Return an array of railties respecting the order they're loaded # and the order specified by the +railties_order+ config. # @@ -423,63 +481,63 @@ class Rails::Application < ::Rails::Engine # copying migrations from railties ; we need them in the order given by # +railties_order+. # - # source://railties//lib/rails/application.rb#487 + # source://railties//lib/rails/application.rb#528 def migration_railties; end - # source://sprockets-rails/3.4.2/lib/sprockets/railtie.rb#51 + # source://sprockets-rails/3.5.2/lib/sprockets/railtie.rb#52 def precompiled_assets(clear_cache = T.unsafe(nil)); end # If you try to define a set of Rake tasks on the instance, these will get # passed up to the Rake tasks defined on the application's class. # - # source://railties//lib/rails/application.rb#284 + # source://railties//lib/rails/application.rb#340 def rake_tasks(&block); end # Reload application routes regardless if they changed or not. # - # source://railties//lib/rails/application.rb#148 + # source://railties//lib/rails/application.rb#152 def reload_routes!; end # Returns the value of attribute reloader. # - # source://railties//lib/rails/application.rb#99 + # source://railties//lib/rails/application.rb#101 def reloader; end # Returns the value of attribute reloaders. # - # source://railties//lib/rails/application.rb#99 + # source://railties//lib/rails/application.rb#101 def reloaders; end - # source://railties//lib/rails/application.rb#346 + # source://railties//lib/rails/application.rb#402 def require_environment!; end - # source://railties//lib/rails/application.rb#351 + # source://railties//lib/rails/application.rb#407 def routes_reloader; end - # source://railties//lib/rails/application.rb#133 + # source://railties//lib/rails/application.rb#137 def run_load_hooks!; end # Sends any runner called in the instance of a new application up # to the +runner+ method defined in Rails::Railtie. # - # source://railties//lib/rails/application.rb#297 + # source://railties//lib/rails/application.rb#353 def runner(&blk); end # Returns the value of attribute sandbox. # - # source://railties//lib/rails/application.rb#97 + # source://railties//lib/rails/application.rb#99 def sandbox; end # Sets the attribute sandbox # # @param value the value to set the attribute sandbox to. # - # source://railties//lib/rails/application.rb#97 + # source://railties//lib/rails/application.rb#99 def sandbox=(_arg0); end # Returns the value of attribute sandbox. # - # source://railties//lib/rails/application.rb#97 + # source://railties//lib/rails/application.rb#99 def sandbox?; end # The secret_key_base is used as the input secret to the application's key generator, which in turn @@ -487,85 +545,81 @@ class Rails::Application < ::Rails::Engine # including the ones that sign and encrypt cookies. # # In development and test, this is randomly generated and stored in a - # temporary file in tmp/development_secret.txt. + # temporary file in tmp/local_secret.txt. # - # In all other environments, we look for it first in ENV["SECRET_KEY_BASE"], - # then +credentials.secret_key_base+, and finally +secrets.secret_key_base+. For most applications, - # the correct place to store it is in the encrypted credentials file. + # You can also set ENV["SECRET_KEY_BASE_DUMMY"] to trigger the use of a randomly generated + # secret_key_base that's stored in a temporary file. This is useful when precompiling assets for + # production as part of a build step that otherwise does not need access to the production secrets. # - # source://railties//lib/rails/application.rb#415 - def secret_key_base; end - - # source://railties//lib/rails/application.rb#389 - def secrets; end - - # Sets the attribute secrets + # Dockerfile example: RUN SECRET_KEY_BASE_DUMMY=1 bundle exec rails assets:precompile. # - # @param value the value to set the attribute secrets to. + # In all other environments, we look for it first in ENV["SECRET_KEY_BASE"], + # then +credentials.secret_key_base+. For most applications, the correct place to store it is in the + # encrypted credentials file. # - # source://railties//lib/rails/application.rb#403 - def secrets=(_arg0); end + # source://railties//lib/rails/application.rb#462 + def secret_key_base; end # Sends any server called in the instance of a new application up # to the +server+ method defined in Rails::Railtie. # - # source://railties//lib/rails/application.rb#315 + # source://railties//lib/rails/application.rb#371 def server(&blk); end - # source://railties//lib/rails/application.rb#467 + # source://railties//lib/rails/application.rb#508 def to_app; end # Returns an array of file paths appended with a hash of # directories-extensions suitable for ActiveSupport::FileUpdateChecker # API. # - # source://railties//lib/rails/application.rb#358 + # source://railties//lib/rails/application.rb#414 def watchable_args; end protected - # source://railties//lib/rails/application.rb#565 + # source://railties//lib/rails/application.rb#611 def default_middleware_stack; end + # source://railties//lib/rails/application.rb#616 + def ensure_generator_templates_added; end + # Returns the ordered railties for this application considering railties_order. # - # source://railties//lib/rails/application.rb#531 + # source://railties//lib/rails/application.rb#577 def ordered_railties; end - # source://railties//lib/rails/application.rb#553 + # source://railties//lib/rails/application.rb#599 def railties_initializers(current); end - # source://railties//lib/rails/application.rb#520 + # source://railties//lib/rails/application.rb#566 def run_console_blocks(app); end - # source://railties//lib/rails/application.rb#510 + # source://railties//lib/rails/application.rb#556 def run_generators_blocks(app); end - # source://railties//lib/rails/application.rb#515 + # source://railties//lib/rails/application.rb#561 def run_runner_blocks(app); end - # source://railties//lib/rails/application.rb#525 + # source://railties//lib/rails/application.rb#571 def run_server_blocks(app); end - # source://railties//lib/rails/application.rb#499 + # source://railties//lib/rails/application.rb#545 def run_tasks_blocks(app); end - # source://railties//lib/rails/application.rb#570 - def validate_secret_key_base(secret_key_base); end - private - # source://railties//lib/rails/application.rb#604 + # source://railties//lib/rails/application.rb#629 def build_middleware; end - # source://railties//lib/rails/application.rb#597 + # source://railties//lib/rails/application.rb#622 def build_request(env); end - # source://railties//lib/rails/application.rb#608 + # source://railties//lib/rails/application.rb#633 def coerce_same_site_protection(protection); end - # source://railties//lib/rails/application.rb#581 - def generate_development_secret; end + # source://railties//lib/rails/application.rb#637 + def filter_parameters; end class << self # This method is called just after an application inherits from Rails::Application, @@ -582,13 +636,13 @@ class Rails::Application < ::Rails::Engine # Rails application, you will need to add lib to $LOAD_PATH on your own in case # you need to load files in lib/ during the application configuration as well. # - # source://railties//lib/rails/application.rb#339 + # source://railties//lib/rails/application.rb#395 def add_lib_to_load_path!(root); end - # source://railties//lib/rails/application.rb#81 + # source://railties//lib/rails/application.rb#83 def create(initial_variable_values = T.unsafe(nil), &block); end - # source://railties//lib/rails/application.rb#85 + # source://railties//lib/rails/application.rb#87 def find_root(from); end # @private @@ -596,7 +650,7 @@ class Rails::Application < ::Rails::Engine # source://railties//lib/rails/application.rb#70 def inherited(base); end - # source://railties//lib/rails/application.rb#77 + # source://railties//lib/rails/application.rb#79 def instance; end def new(*_arg0); end @@ -609,553 +663,607 @@ module Rails::Application::Bootstrap extend ::Rails::Initializable::ClassMethods end -# source://railties//lib/rails/application/configuration.rb#12 +# source://railties//lib/rails/application/configuration.rb#13 class Rails::Application::Configuration < ::Rails::Engine::Configuration # @return [Configuration] a new instance of Configuration # - # source://railties//lib/rails/application/configuration.rb#28 + # source://railties//lib/rails/application/configuration.rb#30 def initialize(*_arg0); end # Returns the value of attribute add_autoload_paths_to_load_path. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def add_autoload_paths_to_load_path; end # Sets the attribute add_autoload_paths_to_load_path # # @param value the value to set the attribute add_autoload_paths_to_load_path to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def add_autoload_paths_to_load_path=(_arg0); end # Returns the value of attribute allow_concurrency. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def allow_concurrency; end # Sets the attribute allow_concurrency # # @param value the value to set the attribute allow_concurrency to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def allow_concurrency=(_arg0); end - # source://railties//lib/rails/application/configuration.rb#415 + # source://railties//lib/rails/application/configuration.rb#558 def annotations; end # Returns the value of attribute api_only. # - # source://railties//lib/rails/application/configuration.rb#26 + # source://railties//lib/rails/application/configuration.rb#28 def api_only; end - # source://railties//lib/rails/application/configuration.rb#276 + # source://railties//lib/rails/application/configuration.rb#373 def api_only=(value); end # Returns the value of attribute asset_host. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def asset_host; end # Sets the attribute asset_host # # @param value the value to set the attribute asset_host to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def asset_host=(_arg0); end + # Returns the value of attribute assume_ssl. + # + # source://railties//lib/rails/application/configuration.rb#14 + def assume_ssl; end + + # Sets the attribute assume_ssl + # + # @param value the value to set the attribute assume_ssl to. + # + # source://railties//lib/rails/application/configuration.rb#14 + def assume_ssl=(_arg0); end + # Returns the value of attribute autoflush_log. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def autoflush_log; end # Sets the attribute autoflush_log # # @param value the value to set the attribute autoflush_log to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def autoflush_log=(_arg0); end + # source://railties//lib/rails/application/configuration.rb#468 + def autoload_lib(ignore:); end + + # source://railties//lib/rails/application/configuration.rb#480 + def autoload_lib_once(ignore:); end + # Returns the value of attribute beginning_of_week. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def beginning_of_week; end # Sets the attribute beginning_of_week # # @param value the value to set the attribute beginning_of_week to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def beginning_of_week=(_arg0); end + # source://railties//lib/rails/application/configuration.rb#385 + def broadcast_log_level; end + # Returns the value of attribute cache_classes. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def cache_classes; end # Sets the attribute cache_classes # # @param value the value to set the attribute cache_classes to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def cache_classes=(_arg0); end # Returns the value of attribute cache_store. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def cache_store; end # Sets the attribute cache_store # # @param value the value to set the attribute cache_store to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def cache_store=(_arg0); end - # source://railties//lib/rails/application/configuration.rb#361 + # source://railties//lib/rails/application/configuration.rb#492 def colorize_logging; end - # source://railties//lib/rails/application/configuration.rb#365 + # source://railties//lib/rails/application/configuration.rb#496 def colorize_logging=(val); end # Returns the value of attribute consider_all_requests_local. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def consider_all_requests_local; end # Sets the attribute consider_all_requests_local # # @param value the value to set the attribute consider_all_requests_local to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def consider_all_requests_local=(_arg0); end # Returns the value of attribute console. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def console; end # Sets the attribute console # # @param value the value to set the attribute console to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def console=(_arg0); end # Configures the ActionDispatch::ContentSecurityPolicy. # - # source://railties//lib/rails/application/configuration.rb#420 + # source://railties//lib/rails/application/configuration.rb#563 def content_security_policy(&block); end # Returns the value of attribute content_security_policy_nonce_directives. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def content_security_policy_nonce_directives; end # Sets the attribute content_security_policy_nonce_directives # # @param value the value to set the attribute content_security_policy_nonce_directives to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def content_security_policy_nonce_directives=(_arg0); end # Returns the value of attribute content_security_policy_nonce_generator. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def content_security_policy_nonce_generator; end # Sets the attribute content_security_policy_nonce_generator # # @param value the value to set the attribute content_security_policy_nonce_generator to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def content_security_policy_nonce_generator=(_arg0); end # Returns the value of attribute content_security_policy_report_only. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def content_security_policy_report_only; end # Sets the attribute content_security_policy_report_only # # @param value the value to set the attribute content_security_policy_report_only to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def content_security_policy_report_only=(_arg0); end # Returns the value of attribute credentials. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def credentials; end # Sets the attribute credentials # # @param value the value to set the attribute credentials to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def credentials=(_arg0); end # Loads and returns the entire raw configuration of database from # values stored in config/database.yml. # - # source://railties//lib/rails/application/configuration.rb#330 + # source://railties//lib/rails/application/configuration.rb#431 def database_configuration; end - # source://railties//lib/rails/application/configuration.rb#283 + # source://railties//lib/rails/application/configuration.rb#387 def debug_exception_response_format; end # Sets the attribute debug_exception_response_format # # @param value the value to set the attribute debug_exception_response_format to. # - # source://railties//lib/rails/application/configuration.rb#287 + # source://railties//lib/rails/application/configuration.rb#391 def debug_exception_response_format=(_arg0); end - # source://railties//lib/rails/application/configuration.rb#437 + # source://railties//lib/rails/application/configuration.rb#580 def default_log_file; end # Returns the value of attribute disable_sandbox. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def disable_sandbox; end # Sets the attribute disable_sandbox # # @param value the value to set the attribute disable_sandbox to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def disable_sandbox=(_arg0); end + # Returns the value of attribute dom_testing_default_html_version. + # + # source://railties//lib/rails/application/configuration.rb#14 + def dom_testing_default_html_version; end + + # Sets the attribute dom_testing_default_html_version + # + # @param value the value to set the attribute dom_testing_default_html_version to. + # + # source://railties//lib/rails/application/configuration.rb#14 + def dom_testing_default_html_version=(_arg0); end + # Returns the value of attribute eager_load. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def eager_load; end # Sets the attribute eager_load # # @param value the value to set the attribute eager_load to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def eager_load=(_arg0); end - # Returns the value of attribute enable_dependency_loading. - # - # source://railties//lib/rails/application/configuration.rb#13 - def enable_dependency_loading; end + # source://railties//lib/rails/application/configuration.rb#349 + def enable_reloading; end - # Sets the attribute enable_dependency_loading - # - # @param value the value to set the attribute enable_dependency_loading to. - # - # source://railties//lib/rails/application/configuration.rb#13 - def enable_dependency_loading=(_arg0); end + # source://railties//lib/rails/application/configuration.rb#353 + def enable_reloading=(value); end # Returns the value of attribute encoding. # - # source://railties//lib/rails/application/configuration.rb#26 + # source://railties//lib/rails/application/configuration.rb#28 def encoding; end - # source://railties//lib/rails/application/configuration.rb#268 + # source://railties//lib/rails/application/configuration.rb#365 def encoding=(value); end # Returns the value of attribute exceptions_app. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def exceptions_app; end # Sets the attribute exceptions_app # # @param value the value to set the attribute exceptions_app to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def exceptions_app=(_arg0); end # Returns the value of attribute file_watcher. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def file_watcher; end # Sets the attribute file_watcher # # @param value the value to set the attribute file_watcher to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def file_watcher=(_arg0); end # Returns the value of attribute filter_parameters. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def filter_parameters; end # Sets the attribute filter_parameters # # @param value the value to set the attribute filter_parameters to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def filter_parameters=(_arg0); end # Returns the value of attribute filter_redirect. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def filter_redirect; end # Sets the attribute filter_redirect # # @param value the value to set the attribute filter_redirect to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def filter_redirect=(_arg0); end # Returns the value of attribute force_ssl. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def force_ssl; end # Sets the attribute force_ssl # # @param value the value to set the attribute force_ssl to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def force_ssl=(_arg0); end # Returns the value of attribute helpers_paths. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def helpers_paths; end # Sets the attribute helpers_paths # # @param value the value to set the attribute helpers_paths to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def helpers_paths=(_arg0); end # Returns the value of attribute host_authorization. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def host_authorization; end # Sets the attribute host_authorization # # @param value the value to set the attribute host_authorization to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def host_authorization=(_arg0); end # Returns the value of attribute hosts. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def hosts; end # Sets the attribute hosts # # @param value the value to set the attribute hosts to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def hosts=(_arg0); end - # Load the database YAML without evaluating ERB. This allows us to - # create the rake tasks for multiple databases without filling in the - # configuration values or loading the environment. Do not use this - # method. + # source://railties//lib/rails/application/configuration.rb#592 + def inspect; end + + # Load the config/database.yml to create the Rake tasks for + # multiple databases without loading the environment and filling in the + # environment specific configuration values. # - # This uses a DummyERB custom compiler so YAML can ignore the ERB - # tags and load the database.yml for the rake tasks. + # Do not use this method, use #database_configuration instead. # - # source://railties//lib/rails/application/configuration.rb#312 + # source://railties//lib/rails/application/configuration.rb#413 def load_database_yaml; end # Loads default configuration values for a target version. This includes # defaults for versions prior to the target version. See the - # {configuration guide}[https://guides.rubyonrails.org/configuring.html] + # {configuration guide}[https://guides.rubyonrails.org/configuring.html#versioned-default-values] # for the default values associated with a particular version. # - # source://railties//lib/rails/application/configuration.rb#88 + # source://railties//lib/rails/application/configuration.rb#91 def load_defaults(target_version); end # Returns the value of attribute loaded_config_version. # - # source://railties//lib/rails/application/configuration.rb#26 + # source://railties//lib/rails/application/configuration.rb#28 def loaded_config_version; end + # Returns the value of attribute log_file_size. + # + # source://railties//lib/rails/application/configuration.rb#14 + def log_file_size; end + + # Sets the attribute log_file_size + # + # @param value the value to set the attribute log_file_size to. + # + # source://railties//lib/rails/application/configuration.rb#14 + def log_file_size=(_arg0); end + # Returns the value of attribute log_formatter. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def log_formatter; end # Sets the attribute log_formatter # # @param value the value to set the attribute log_formatter to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def log_formatter=(_arg0); end # Returns the value of attribute log_level. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#28 def log_level; end - # Sets the attribute log_level - # - # @param value the value to set the attribute log_level to. - # - # source://railties//lib/rails/application/configuration.rb#13 - def log_level=(_arg0); end + # source://railties//lib/rails/application/configuration.rb#380 + def log_level=(level); end # Returns the value of attribute log_tags. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def log_tags; end # Sets the attribute log_tags # # @param value the value to set the attribute log_tags to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def log_tags=(_arg0); end # Returns the value of attribute logger. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def logger; end # Sets the attribute logger # # @param value the value to set the attribute logger to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def logger=(_arg0); end - # source://railties//lib/rails/application/configuration.rb#289 + # source://railties//lib/rails/application/configuration.rb#393 def paths; end # Configures the ActionDispatch::PermissionsPolicy. # - # source://railties//lib/rails/application/configuration.rb#429 + # source://railties//lib/rails/application/configuration.rb#572 def permissions_policy(&block); end + # Returns the value of attribute precompile_filter_parameters. + # + # source://railties//lib/rails/application/configuration.rb#14 + def precompile_filter_parameters; end + + # Sets the attribute precompile_filter_parameters + # + # @param value the value to set the attribute precompile_filter_parameters to. + # + # source://railties//lib/rails/application/configuration.rb#14 + def precompile_filter_parameters=(_arg0); end + # Returns the value of attribute public_file_server. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def public_file_server; end # Sets the attribute public_file_server # # @param value the value to set the attribute public_file_server to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def public_file_server=(_arg0); end # Returns the value of attribute railties_order. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def railties_order; end # Sets the attribute railties_order # # @param value the value to set the attribute railties_order to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def railties_order=(_arg0); end # Returns the value of attribute rake_eager_load. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def rake_eager_load; end # Sets the attribute rake_eager_load # # @param value the value to set the attribute rake_eager_load to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def rake_eager_load=(_arg0); end - # Returns the value of attribute read_encrypted_secrets. - # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#357 def read_encrypted_secrets; end - # Sets the attribute read_encrypted_secrets - # - # @param value the value to set the attribute read_encrypted_secrets to. - # - # source://railties//lib/rails/application/configuration.rb#13 - def read_encrypted_secrets=(_arg0); end + # source://railties//lib/rails/application/configuration.rb#361 + def read_encrypted_secrets=(value); end # Returns the value of attribute relative_url_root. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def relative_url_root; end # Sets the attribute relative_url_root # # @param value the value to set the attribute relative_url_root to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def relative_url_root=(_arg0); end # Returns the value of attribute reload_classes_only_on_change. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def reload_classes_only_on_change; end # Sets the attribute reload_classes_only_on_change # # @param value the value to set the attribute reload_classes_only_on_change to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def reload_classes_only_on_change=(_arg0); end + # @return [Boolean] + # + # source://railties//lib/rails/application/configuration.rb#345 + def reloading_enabled?; end + # Returns the value of attribute require_master_key. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def require_master_key; end # Sets the attribute require_master_key # # @param value the value to set the attribute require_master_key to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def require_master_key=(_arg0); end - # Returns the value of attribute secret_key_base. + # Returns the value of attribute sandbox_by_default. # - # source://railties//lib/rails/application/configuration.rb#13 - def secret_key_base; end + # source://railties//lib/rails/application/configuration.rb#14 + def sandbox_by_default; end - # Sets the attribute secret_key_base + # Sets the attribute sandbox_by_default # - # @param value the value to set the attribute secret_key_base to. + # @param value the value to set the attribute sandbox_by_default to. # - # source://railties//lib/rails/application/configuration.rb#13 - def secret_key_base=(_arg0); end + # source://railties//lib/rails/application/configuration.rb#14 + def sandbox_by_default=(_arg0); end + + # source://railties//lib/rails/application/configuration.rb#501 + def secret_key_base; end + + # source://railties//lib/rails/application/configuration.rb#511 + def secret_key_base=(new_secret_key_base); end # Returns the value of attribute server_timing. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def server_timing; end # Sets the attribute server_timing # # @param value the value to set the attribute server_timing to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def server_timing=(_arg0); end # Returns the value of attribute session_options. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def session_options; end # Sets the attribute session_options # # @param value the value to set the attribute session_options to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def session_options=(_arg0); end # Specifies what class to use to store the session. Possible values - # are +:cookie_store+, +:mem_cache_store+, a custom store, or - # +:disabled+. +:disabled+ tells Rails not to deal with sessions. + # are +:cache_store+, +:cookie_store+, +:mem_cache_store+, a custom + # store, or +:disabled+. +:disabled+ tells \Rails not to deal with + # sessions. # # Additional options will be set as +session_options+: # @@ -1168,80 +1276,92 @@ class Rails::Application::Configuration < ::Rails::Engine::Configuration # # use ActionDispatch::Session::MyCustomStore as the session store # config.session_store :my_custom_store # - # source://railties//lib/rails/application/configuration.rb#384 + # source://railties//lib/rails/application/configuration.rb#538 def session_store(new_session_store = T.unsafe(nil), **options); end # @return [Boolean] # - # source://railties//lib/rails/application/configuration.rb#411 + # source://railties//lib/rails/application/configuration.rb#554 def session_store?; end # Returns the value of attribute ssl_options. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def ssl_options; end # Sets the attribute ssl_options # # @param value the value to set the attribute ssl_options to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def ssl_options=(_arg0); end # Returns the value of attribute time_zone. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def time_zone; end # Sets the attribute time_zone # # @param value the value to set the attribute time_zone to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def time_zone=(_arg0); end # Returns the value of attribute x. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def x; end # Sets the attribute x # # @param value the value to set the attribute x to. # - # source://railties//lib/rails/application/configuration.rb#13 + # source://railties//lib/rails/application/configuration.rb#14 def x=(_arg0); end - private + # Returns the value of attribute yjit. + # + # source://railties//lib/rails/application/configuration.rb#14 + def yjit; end - # @return [Boolean] + # Sets the attribute yjit + # + # @param value the value to set the attribute yjit to. # - # source://railties//lib/rails/application/configuration.rb#486 - def credentials_available_for_current_env?; end + # source://railties//lib/rails/application/configuration.rb#14 + def yjit=(_arg0); end + + private - # source://railties//lib/rails/application/configuration.rb#470 - def default_credentials_content_path; end + # source://railties//lib/rails/application/configuration.rb#619 + def credentials_defaults; end - # source://railties//lib/rails/application/configuration.rb#478 - def default_credentials_key_path; end + # source://railties//lib/rails/application/configuration.rb#629 + def generate_local_secret; end + + # @return [Boolean] + # + # source://railties//lib/rails/application/configuration.rb#641 + def generate_local_secret?; end end -# source://railties//lib/rails/application/configuration.rb#449 +# source://railties//lib/rails/application/configuration.rb#596 class Rails::Application::Configuration::Custom # @return [Custom] a new instance of Custom # - # source://railties//lib/rails/application/configuration.rb#450 + # source://railties//lib/rails/application/configuration.rb#597 def initialize; end - # source://railties//lib/rails/application/configuration.rb#454 + # source://railties//lib/rails/application/configuration.rb#601 def method_missing(method, *args); end private # @return [Boolean] # - # source://railties//lib/rails/application/configuration.rb#464 - def respond_to_missing?(symbol, *_arg1); end + # source://railties//lib/rails/application/configuration.rb#613 + def respond_to_missing?(symbol, _); end end # source://railties//lib/rails/application/default_middleware_stack.rb#5 @@ -1271,45 +1391,45 @@ class Rails::Application::DefaultMiddlewareStack private - # source://railties//lib/rails/application/default_middleware_stack.rb#103 + # source://railties//lib/rails/application/default_middleware_stack.rb#109 def load_rack_cache; end - # source://railties//lib/rails/application/default_middleware_stack.rb#125 + # source://railties//lib/rails/application/default_middleware_stack.rb#131 def show_exceptions_app; end end -# source://railties//lib/rails/application/finisher.rb#10 +# source://railties//lib/rails/application/finisher.rb#11 module Rails::Application::Finisher include ::Rails::Initializable extend ::Rails::Initializable::ClassMethods end -# source://railties//lib/rails/application/finisher.rb#104 +# source://railties//lib/rails/application/finisher.rb#111 module Rails::Application::Finisher::InterlockHook class << self - # source://railties//lib/rails/application/finisher.rb#109 + # source://railties//lib/rails/application/finisher.rb#116 def complete(_state); end - # source://railties//lib/rails/application/finisher.rb#105 + # source://railties//lib/rails/application/finisher.rb#112 def run; end end end -# source://railties//lib/rails/application/finisher.rb#90 +# source://railties//lib/rails/application/finisher.rb#97 class Rails::Application::Finisher::MonitorHook # @return [MonitorHook] a new instance of MonitorHook # - # source://railties//lib/rails/application/finisher.rb#91 + # source://railties//lib/rails/application/finisher.rb#98 def initialize(monitor = T.unsafe(nil)); end - # source://railties//lib/rails/application/finisher.rb#99 + # source://railties//lib/rails/application/finisher.rb#106 def complete(_state); end - # source://railties//lib/rails/application/finisher.rb#95 + # source://railties//lib/rails/application/finisher.rb#102 def run; end end -# source://railties//lib/rails/application.rb#103 +# source://railties//lib/rails/application.rb#105 Rails::Application::INITIAL_VARIABLES = T.let(T.unsafe(nil), Array) # source://railties//lib/rails/application/routes_reloader.rb#7 @@ -1323,10 +1443,10 @@ class Rails::Application::RoutesReloader # source://railties//lib/rails/application/routes_reloader.rb#15 def initialize; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end # Returns the value of attribute eager_load. @@ -1392,13 +1512,13 @@ class Rails::Application::RoutesReloader def updater; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end end end @@ -1407,9 +1527,11 @@ end class Rails::ApplicationController < ::ActionController::Base private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end + def _layout_from_proc; end + # source://railties//lib/rails/application_controller.rb#25 def disable_content_security_policy_nonce!; end @@ -1422,16 +1544,16 @@ class Rails::ApplicationController < ::ActionController::Base def require_local!; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions; end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end end end @@ -1483,14 +1605,40 @@ module Rails::Autoloaders::Inflector end end -# source://railties//lib/rails/command.rb#10 +# source://railties//lib/rails/backtrace_cleaner.rb#7 +class Rails::BacktraceCleaner < ::ActiveSupport::BacktraceCleaner + # @return [BacktraceCleaner] a new instance of BacktraceCleaner + # + # source://railties//lib/rails/backtrace_cleaner.rb#11 + def initialize; end + + # source://railties//lib/rails/backtrace_cleaner.rb#29 + def clean(backtrace, kind = T.unsafe(nil)); end + + # source://railties//lib/rails/backtrace_cleaner.rb#36 + def clean_frame(frame, kind = T.unsafe(nil)); end + + # source://railties//lib/rails/backtrace_cleaner.rb#29 + def filter(backtrace, kind = T.unsafe(nil)); end +end + +# source://railties//lib/rails/backtrace_cleaner.rb#8 +Rails::BacktraceCleaner::APP_DIRS_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://railties//lib/rails/backtrace_cleaner.rb#9 +Rails::BacktraceCleaner::RENDER_TEMPLATE_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://railties//lib/rails/command.rb#11 module Rails::Command include ::Rails::Command::Behavior extend ::ActiveSupport::Autoload extend ::Rails::Command::Behavior::ClassMethods class << self - # source://railties//lib/rails/command.rb#25 + # source://railties//lib/rails/command.rb#116 + def application_root; end + + # source://railties//lib/rails/command.rb#57 def environment; end # Rails finds namespaces similar to Thor, it only adds one rule: @@ -1504,62 +1652,68 @@ module Rails::Command # # "webrat", "webrat:integration", "rails:webrat", "rails:webrat:integration" # - # source://railties//lib/rails/command.rb#68 + # source://railties//lib/rails/command.rb#96 def find_by_namespace(namespace, command_name = T.unsafe(nil)); end - # source://railties//lib/rails/command.rb#21 + # source://railties//lib/rails/command.rb#53 def hidden_commands; end # Receives a namespace, arguments, and the behavior to invoke the command. # - # source://railties//lib/rails/command.rb#30 + # source://railties//lib/rails/command.rb#62 def invoke(full_namespace, args = T.unsafe(nil), **config); end - # source://railties//lib/rails/command.rb#88 - def print_commands; end + # source://railties//lib/rails/command.rb#120 + def printing_commands; end - # Returns the root of the Rails engine or app running the command. + # Returns the root of the \Rails engine or app running the command. # - # source://railties//lib/rails/command.rb#80 + # source://railties//lib/rails/command.rb#108 def root; end private - # source://railties//lib/rails/command.rb#108 + # source://railties//lib/rails/command.rb#159 def command_type; end - # source://railties//lib/rails/command.rb#100 - def commands; end - - # source://railties//lib/rails/command.rb#116 + # source://railties//lib/rails/command.rb#167 def file_lookup_paths; end - # source://railties//lib/rails/command.rb#112 + # source://railties//lib/rails/command.rb#154 + def invoke_rake(task, args, config); end + + # source://railties//lib/rails/command.rb#163 def lookup_paths; end # @return [Boolean] # - # source://railties//lib/rails/command.rb#96 + # source://railties//lib/rails/command.rb#127 def rails_new_with_no_path?(args); end + + # source://railties//lib/rails/command.rb#131 + def split_namespace(namespace); end + + # source://railties//lib/rails/command.rb#146 + def with_argv(argv); end end end # source://railties//lib/rails/command/actions.rb#5 module Rails::Command::Actions - # source://railties//lib/rails/command/actions.rb#48 + # source://railties//lib/rails/command/actions.rb#18 + def boot_application!; end + + # source://railties//lib/rails/command/actions.rb#23 + def load_environment_config!; end + + # source://railties//lib/rails/command/actions.rb#46 def load_generators; end - # source://railties//lib/rails/command/actions.rb#44 + # source://railties//lib/rails/command/actions.rb#42 def load_tasks; end - # source://railties//lib/rails/command/actions.rb#18 - def require_application!; end - # source://railties//lib/rails/command/actions.rb#13 - def require_application_and_environment!; end - - # source://railties//lib/rails/command/actions.rb#26 - def require_environment!; end + def require_application!; end # Change to the application's path if there is no config.ru file in current directory. # This allows us to run rails server from other directories, but still get @@ -1569,18 +1723,22 @@ module Rails::Command::Actions def set_application_directory!; end end -# source://railties//lib/rails/command/base.rb#13 +# source://railties//lib/rails/command/base.rb#14 class Rails::Command::Base < ::Thor include ::Rails::Command::Actions - # source://railties//lib/rails/command/base.rb#174 - def help; end + # source://thor/1.3.1/lib/thor/base.rb#155 + def current_subcommand; end + + # source://railties//lib/rails/command/base.rb#172 + def executable(*_arg0, **_arg1, &_arg2); end + + # source://railties//lib/rails/command/base.rb#175 + def invoke_command(command, *_arg1); end class << self - # Use Rails' default banner. - # - # source://railties//lib/rails/command/base.rb#99 - def banner(*_arg0); end + # source://railties//lib/rails/command/base.rb#86 + def banner(command = T.unsafe(nil), *_arg1); end # Sets the base_name taking into account the current class namespace. # @@ -1589,6 +1747,18 @@ class Rails::Command::Base < ::Thor # source://railties//lib/rails/command/base.rb#106 def base_name; end + # source://railties//lib/rails/command/base.rb#20 + def bin; end + + # source://railties//lib/rails/command/base.rb#20 + def bin=(value); end + + # source://railties//lib/rails/command/base.rb#20 + def bin?; end + + # source://railties//lib/rails/command/base.rb#122 + def class_usage; end + # Return command name without namespaces. # # Rails::Command::TestCommand.command_name # => 'test' @@ -1602,99 +1772,78 @@ class Rails::Command::Base < ::Thor # For a Rails::Command::TestCommand placed in rails/command/test_command.rb # would return rails/test. # - # source://railties//lib/rails/command/base.rb#135 + # source://railties//lib/rails/command/base.rb#139 def default_command_root; end # Tries to get the description from a USAGE file one folder above the command # root. # - # source://railties//lib/rails/command/base.rb#49 + # source://railties//lib/rails/command/base.rb#34 def desc(usage = T.unsafe(nil), description = T.unsafe(nil), options = T.unsafe(nil)); end - # Returns true when the app is a Rails engine. + # Returns true when the app is a \Rails engine. # # @return [Boolean] # - # source://railties//lib/rails/command/base.rb#43 + # source://railties//lib/rails/command/base.rb#28 def engine?; end - # source://railties//lib/rails/command/base.rb#94 - def executable; end + # source://railties//lib/rails/command/base.rb#82 + def executable(command_name = T.unsafe(nil)); end # @return [Boolean] # - # source://railties//lib/rails/command/base.rb#38 + # source://railties//lib/rails/command/base.rb#23 def exit_on_failure?; end + # Override Thor's class-level help to also show the USAGE. + # + # source://railties//lib/rails/command/base.rb#98 + def help(shell, *_arg1); end + # Convenience method to hide this command from the available ones when # running rails command. # - # source://railties//lib/rails/command/base.rb#70 + # source://railties//lib/rails/command/base.rb#55 def hide_command!; end - # source://railties//lib/rails/command/base.rb#74 + # source://railties//lib/rails/command/base.rb#59 def inherited(base); end # Convenience method to get the namespace from the class name. It's the # same as Thor default except that the Command at the end of the class # is removed. # - # source://railties//lib/rails/command/base.rb#60 + # source://railties//lib/rails/command/base.rb#45 def namespace(name = T.unsafe(nil)); end - # source://railties//lib/rails/command/base.rb#82 + # source://railties//lib/rails/command/base.rb#67 def perform(command, args, config); end - # source://railties//lib/rails/command/base.rb#90 + # source://railties//lib/rails/command/base.rb#76 def printing_commands; end # Path to lookup a USAGE description in a file. # - # source://railties//lib/rails/command/base.rb#123 + # source://railties//lib/rails/command/base.rb#129 def usage_path; end private - # source://railties//lib/rails/command/base.rb#155 - def command_root_namespace; end - # Allow the command method to be called perform. # - # source://railties//lib/rails/command/base.rb#142 + # source://railties//lib/rails/command/base.rb#146 def create_command(meth); end - # source://railties//lib/rails/command/base.rb#163 - def namespaced_commands; end - # source://railties//lib/rails/command/base.rb#159 - def relative_command_path; end - end -end - -# source://railties//lib/rails/command/base.rb#17 -class Rails::Command::Base::CorrectableError < ::Rails::Command::Base::Error - include ::DidYouMean::Correctable - - # @return [CorrectableError] a new instance of CorrectableError - # - # source://railties//lib/rails/command/base.rb#20 - def initialize(message, key, options); end - - # source://railties//lib/rails/command/base.rb#29 - def corrections; end - - # Returns the value of attribute key. - # - # source://railties//lib/rails/command/base.rb#18 - def key; end + def namespaced_name(name); end - # Returns the value of attribute options. - # - # source://railties//lib/rails/command/base.rb#18 - def options; end + # source://railties//lib/rails/command/base.rb#164 + def resolve_path(path); end + end end -# source://railties//lib/rails/command/base.rb#14 +# source://railties//lib/rails/command/base.rb#15 class Rails::Command::Base::Error < ::Thor::Error; end # source://railties//lib/rails/command/behavior.rb#7 @@ -1727,8 +1876,37 @@ module Rails::Command::Behavior::ClassMethods def print_list(base, namespaces); end end -# source://railties//lib/rails/command.rb#18 -Rails::Command::HELP_MAPPINGS = T.let(T.unsafe(nil), Array) +# source://railties//lib/rails/command.rb#17 +class Rails::Command::CorrectableNameError < ::StandardError + include ::DidYouMean::Correctable + + # @return [CorrectableNameError] a new instance of CorrectableNameError + # + # source://railties//lib/rails/command.rb#20 + def initialize(message, name, alternatives); end + + # source://railties//lib/rails/command.rb#35 + def corrections; end + + # Returns the value of attribute name. + # + # source://railties//lib/rails/command.rb#18 + def name; end +end + +# source://railties//lib/rails/command.rb#49 +Rails::Command::HELP_MAPPINGS = T.let(T.unsafe(nil), Set) + +# source://railties//lib/rails/command.rb#41 +class Rails::Command::UnrecognizedCommandError < ::Rails::Command::CorrectableNameError + # @return [UnrecognizedCommandError] a new instance of UnrecognizedCommandError + # + # source://railties//lib/rails/command.rb#42 + def initialize(name); end +end + +# source://railties//lib/rails/command.rb#50 +Rails::Command::VERSION_MAPPINGS = T.let(T.unsafe(nil), Set) # source://railties//lib/rails/configuration.rb#9 module Rails::Configuration; end @@ -1772,6 +1950,9 @@ class Rails::Configuration::Generators # source://railties//lib/rails/configuration.rb#105 def api_only=(_arg0); end + # source://railties//lib/rails/configuration.rb#134 + def apply_rubocop_autocorrect_after_generate!; end + # Returns the value of attribute colorize_logging. # # source://railties//lib/rails/configuration.rb#105 @@ -1804,7 +1985,7 @@ class Rails::Configuration::Generators # source://railties//lib/rails/configuration.rb#126 def hide_namespace(namespace); end - # source://railties//lib/rails/configuration.rb#134 + # source://railties//lib/rails/configuration.rb#143 def method_missing(method, *args); end # Returns the value of attribute options. @@ -1837,17 +2018,17 @@ class Rails::Configuration::Generators def initialize_copy(source); end end -# MiddlewareStackProxy is a proxy for the Rails middleware stack that allows +# MiddlewareStackProxy is a proxy for the \Rails middleware stack that allows # you to configure middlewares in your application. It works basically as a # command recorder, saving each command to be applied after initialization # over the default middleware stack, so you can add, swap, or remove any -# middleware in Rails. +# middleware in \Rails. # # You can add your own middlewares by using the +config.middleware.use+ method: # # config.middleware.use Magical::Unicorns # -# This will put the Magical::Unicorns middleware on the end of the stack. +# This will put the +Magical::Unicorns+ middleware on the end of the stack. # You can use +insert_before+ if you wish to add a middleware before another: # # config.middleware.insert_before Rack::Head, Magical::Unicorns @@ -1864,8 +2045,8 @@ end # # config.middleware.move_before ActionDispatch::Flash, Magical::Unicorns # -# This will move the Magical::Unicorns middleware before the -# ActionDispatch::Flash. You can also move it after: +# This will move the +Magical::Unicorns+ middleware before the +# +ActionDispatch::Flash+. You can also move it after: # # config.middleware.move_after ActionDispatch::Flash, Magical::Unicorns # @@ -1929,13 +2110,14 @@ class Rails::Configuration::MiddlewareStackProxy def operations; end end -# Rails::Engine allows you to wrap a specific Rails application or subset of +# +Rails::Engine+ allows you to wrap a specific \Rails application or subset of # functionality and share it with other applications or within a larger packaged application. # Every Rails::Application is just an engine, which allows for simple # feature and application sharing. # -# Any Rails::Engine is also a Rails::Railtie, so the same -# methods (like rake_tasks and +generators+) and configuration +# Any +Rails::Engine+ is also a Rails::Railtie, so the same +# methods (like {rake_tasks}[rdoc-ref:Rails::Railtie::rake_tasks] and +# {generators}[rdoc-ref:Rails::Railtie::generators]) and configuration # options that are available in railties can also be used in engines. # # == Creating an Engine @@ -2036,7 +2218,7 @@ end # An engine can also be a Rack application. It can be useful if you have a Rack application that # you would like to provide with some of the +Engine+'s features. # -# To do that, use the +endpoint+ method: +# To do that, use the ::endpoint method: # # module MyEngine # class Engine < Rails::Engine @@ -2101,7 +2283,7 @@ end # it's used as default :as option # * rake task for installing migrations my_engine:install:migrations # -# Engine name is set by default based on class name. For MyEngine::Engine it will be +# Engine name is set by default based on class name. For +MyEngine::Engine+ it will be # my_engine_engine. You can change it manually using the engine_name method: # # module MyEngine @@ -2117,7 +2299,7 @@ end # named routes from the application will be available to your engine's controllers as well. # # However, sometimes you want to isolate your engine from the application, especially if your engine -# has its own router. To do that, you simply need to call +isolate_namespace+. This method requires +# has its own router. To do that, you simply need to call ::isolate_namespace. This method requires # you to pass a module where all your controllers, helpers, and models should be nested to: # # module MyEngine @@ -2151,14 +2333,14 @@ end # end # # If +MyEngine+ is isolated, the routes above will point to -# MyEngine::ArticlesController. You also don't need to use longer +# +MyEngine::ArticlesController+. You also don't need to use longer # URL helpers like +my_engine_articles_path+. Instead, you should simply use # +articles_path+, like you would do with your main application. # # To make this behavior consistent with other parts of the framework, # isolated engines also have an effect on ActiveModel::Naming. In a -# normal Rails app, when you use a namespaced model such as -# Namespace::Article, ActiveModel::Naming will generate +# normal \Rails app, when you use a namespaced model such as +# +Namespace::Article+, ActiveModel::Naming will generate # names with the prefix "namespace". In an isolated engine, the prefix will # be omitted in URL helpers and form fields, for convenience. # @@ -2172,7 +2354,7 @@ end # Additionally, an isolated engine will set its own name according to its # namespace, so MyEngine::Engine.engine_name will return # "my_engine". It will also set +MyEngine.table_name_prefix+ to "my_engine_", -# meaning for example that MyEngine::Article will use the +# meaning for example that +MyEngine::Article+ will use the # +my_engine_articles+ database table by default. # # == Using Engine's routes outside Engine @@ -2220,7 +2402,7 @@ end # # == Isolated engine's helpers # -# Sometimes you may want to isolate engine, but use helpers that are defined for it. +# Sometimes you may want to isolate an engine, but use helpers that are defined for it. # If you want to share just a few specific helpers you can add them to application's # helpers in ApplicationController: # @@ -2247,7 +2429,7 @@ end # To use engine's migrations in application you can use the rake task below, which copies them to # application's dir: # -# rake ENGINE_NAME:install:migrations +# $ rake ENGINE_NAME:install:migrations # # Note that some of the migrations may be skipped if a migration with the same name already exists # in application. In such a situation you must decide whether to leave that migration or rename the @@ -2274,82 +2456,82 @@ class Rails::Engine < ::Rails::Railtie # @return [Engine] a new instance of Engine # - # source://railties//lib/rails/engine.rb#432 + # source://railties//lib/rails/engine.rb#439 def initialize; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _load_seed_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_load_seed_callbacks(&block); end # Returns the underlying Rack application for this engine. # - # source://railties//lib/rails/engine.rb#511 + # source://railties//lib/rails/engine.rb#516 def app; end # Define the Rack API for this engine. # - # source://railties//lib/rails/engine.rb#528 + # source://railties//lib/rails/engine.rb#533 def call(env); end # Define the configuration object for the engine. # - # source://railties//lib/rails/engine.rb#547 + # source://railties//lib/rails/engine.rb#552 def config; end - # source://railties//lib/rails/engine.rb#484 + # source://railties//lib/rails/engine.rb#490 def eager_load!; end # Returns the endpoint for this engine. If none is registered, # defaults to an ActionDispatch::Routing::RouteSet. # - # source://railties//lib/rails/engine.rb#523 + # source://railties//lib/rails/engine.rb#528 def endpoint; end - # source://railties//lib/rails/engine.rb#430 + # source://railties//lib/rails/engine.rb#437 def engine_name(*_arg0, **_arg1, &_arg2); end # Defines additional Rack env configuration that is added on each call. # - # source://railties//lib/rails/engine.rb#534 + # source://railties//lib/rails/engine.rb#539 def env_config; end # Returns a module with all the helpers defined for the engine. # - # source://railties//lib/rails/engine.rb#494 + # source://railties//lib/rails/engine.rb#500 def helpers; end # Returns all registered helpers paths. # - # source://railties//lib/rails/engine.rb#506 + # source://railties//lib/rails/engine.rb#511 def helpers_paths; end - # source://railties//lib/rails/engine.rb#430 - def isolated?(*_arg0, **_arg1, &_arg2); end + # source://railties//lib/rails/engine.rb#437 + def isolated?(&_arg0); end # Load console and invoke the registered hooks. # Check Rails::Railtie.console for more info. # - # source://railties//lib/rails/engine.rb#446 + # source://railties//lib/rails/engine.rb#453 def load_console(app = T.unsafe(nil)); end - # Load Rails generators and invoke the registered hooks. + # Load \Rails generators and invoke the registered hooks. # Check Rails::Railtie.generators for more info. # - # source://railties//lib/rails/engine.rb#470 + # source://railties//lib/rails/engine.rb#476 def load_generators(app = T.unsafe(nil)); end - # Load Rails runner and invoke the registered hooks. + # Load \Rails runner and invoke the registered hooks. # Check Rails::Railtie.runner for more info. # - # source://railties//lib/rails/engine.rb#455 + # source://railties//lib/rails/engine.rb#461 def load_runner(app = T.unsafe(nil)); end # Load data from db/seeds.rb file. It can be used in to load engines' @@ -2357,109 +2539,114 @@ class Rails::Engine < ::Rails::Railtie # # Blog::Engine.load_seed # - # source://railties//lib/rails/engine.rb#555 + # source://railties//lib/rails/engine.rb#560 def load_seed; end # Invoke the server registered hooks. # Check Rails::Railtie.server for more info. # - # source://railties//lib/rails/engine.rb#479 + # source://railties//lib/rails/engine.rb#485 def load_server(app = T.unsafe(nil)); end # Load Rake and railties tasks, and invoke the registered hooks. # Check Rails::Railtie.rake_tasks for more info. # - # source://railties//lib/rails/engine.rb#462 + # source://railties//lib/rails/engine.rb#468 def load_tasks(app = T.unsafe(nil)); end - # source://railties//lib/rails/engine.rb#429 + # source://railties//lib/rails/engine.rb#436 def middleware(*_arg0, **_arg1, &_arg2); end - # source://railties//lib/rails/engine.rb#429 + # source://railties//lib/rails/engine.rb#436 def paths(*_arg0, **_arg1, &_arg2); end - # source://railties//lib/rails/engine.rb#489 + # source://railties//lib/rails/engine.rb#495 def railties; end - # source://railties//lib/rails/engine.rb#429 + # source://railties//lib/rails/engine.rb#436 def root(*_arg0, **_arg1, &_arg2); end # Defines the routes for this engine. If a block is given to # routes, it is appended to the engine. # - # source://railties//lib/rails/engine.rb#540 + # source://railties//lib/rails/engine.rb#545 def routes(&block); end # @return [Boolean] # - # source://railties//lib/rails/engine.rb#654 + # source://railties//lib/rails/engine.rb#676 def routes?; end protected - # source://railties//lib/rails/engine.rb#659 + # source://railties//lib/rails/engine.rb#681 def run_tasks_blocks(*_arg0); end private - # source://railties//lib/rails/engine.rb#691 + # source://railties//lib/rails/engine.rb#713 def _all_autoload_once_paths; end - # source://railties//lib/rails/engine.rb#695 + # source://railties//lib/rails/engine.rb#717 def _all_autoload_paths; end - # source://railties//lib/rails/engine.rb#704 + # source://railties//lib/rails/engine.rb#726 def _all_load_paths(add_autoload_paths_to_load_path); end - # source://railties//lib/rails/engine.rb#723 + # source://railties//lib/rails/engine.rb#751 def build_middleware; end - # source://railties//lib/rails/engine.rb#715 + # source://railties//lib/rails/engine.rb#743 def build_request(env); end - # source://railties//lib/rails/engine.rb#687 + # source://railties//lib/rails/engine.rb#709 def default_middleware_stack; end # @return [Boolean] # - # source://railties//lib/rails/engine.rb#671 + # source://railties//lib/rails/engine.rb#737 + def fixtures_in_root_and_not_in_vendor_or_dot_dir?(fixtures); end + + # @return [Boolean] + # + # source://railties//lib/rails/engine.rb#693 def has_migrations?; end - # source://railties//lib/rails/engine.rb#665 + # source://railties//lib/rails/engine.rb#687 def load_config_initializer(initializer); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _load_seed_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _load_seed_callbacks=(value); end # Returns the value of attribute called_from. # - # source://railties//lib/rails/engine.rb#353 + # source://railties//lib/rails/engine.rb#354 def called_from; end # Sets the attribute called_from # # @param value the value to set the attribute called_from to. # - # source://railties//lib/rails/engine.rb#353 + # source://railties//lib/rails/engine.rb#354 def called_from=(_arg0); end - # source://railties//lib/rails/engine.rb#358 + # source://railties//lib/rails/engine.rb#359 def eager_load!(*_arg0, **_arg1, &_arg2); end - # source://railties//lib/rails/engine.rb#378 + # source://railties//lib/rails/engine.rb#379 def endpoint(endpoint = T.unsafe(nil)); end # source://railties//lib/rails/railtie.rb#176 @@ -2467,38 +2654,38 @@ class Rails::Engine < ::Rails::Railtie # Finds engine with given path. # - # source://railties//lib/rails/engine.rb#416 + # source://railties//lib/rails/engine.rb#423 def find(path); end - # source://railties//lib/rails/engine.rb#374 + # source://railties//lib/rails/engine.rb#375 def find_root(from); end - # source://railties//lib/rails/engine.rb#675 + # source://railties//lib/rails/engine.rb#697 def find_root_with_flag(flag, root_path, default = T.unsafe(nil)); end # @private # - # source://railties//lib/rails/engine.rb#360 + # source://railties//lib/rails/engine.rb#361 def inherited(base); end - # source://railties//lib/rails/engine.rb#384 + # source://railties//lib/rails/engine.rb#385 def isolate_namespace(mod); end # Returns the value of attribute isolated. # - # source://railties//lib/rails/engine.rb#353 + # source://railties//lib/rails/engine.rb#354 def isolated; end # Sets the attribute isolated # # @param value the value to set the attribute isolated to. # - # source://railties//lib/rails/engine.rb#353 + # source://railties//lib/rails/engine.rb#354 def isolated=(_arg0); end # Returns the value of attribute isolated. # - # source://railties//lib/rails/engine.rb#353 + # source://railties//lib/rails/engine.rb#354 def isolated?; end end end @@ -2507,10 +2694,36 @@ end class Rails::Engine::Configuration < ::Rails::Railtie::Configuration # @return [Configuration] a new instance of Configuration # - # source://railties//lib/rails/engine/configuration.rb#12 + # source://railties//lib/rails/engine/configuration.rb#41 def initialize(root = T.unsafe(nil)); end - # source://railties//lib/rails/engine/configuration.rb#83 + # Private method that adds custom autoload once paths to the ones defined + # by +paths+. + # + # source://railties//lib/rails/engine/configuration.rb#125 + def all_autoload_once_paths; end + + # Private method that adds custom autoload paths to the ones defined by + # +paths+. + # + # source://railties//lib/rails/engine/configuration.rb#119 + def all_autoload_paths; end + + # Private method that adds custom eager load paths to the ones defined by + # +paths+. + # + # source://railties//lib/rails/engine/configuration.rb#131 + def all_eager_load_paths; end + + # An array of custom autoload once paths. These won't be eager loaded + # unless you push them to +eager_load_paths+ too, which is recommended. + # + # This collection is empty by default, it accepts strings and +Pathname+ + # objects. + # + # If you'd like to add +lib+ to it, please see +autoload_lib_once+. + # + # source://railties//lib/rails/engine/configuration.rb#29 def autoload_once_paths; end # Sets the attribute autoload_once_paths @@ -2520,7 +2733,16 @@ class Rails::Engine::Configuration < ::Rails::Railtie::Configuration # source://railties//lib/rails/engine/configuration.rb#10 def autoload_once_paths=(_arg0); end - # source://railties//lib/rails/engine/configuration.rb#87 + # An array of custom autoload paths to be added to the ones defined + # automatically by Rails. These won't be eager loaded, unless you push + # them to +eager_load_paths+ too, which is recommended. + # + # This collection is empty by default, it accepts strings and +Pathname+ + # objects. + # + # If you'd like to add +lib+ to it, please see +autoload_lib+. + # + # source://railties//lib/rails/engine/configuration.rb#20 def autoload_paths; end # Sets the attribute autoload_paths @@ -2530,7 +2752,16 @@ class Rails::Engine::Configuration < ::Rails::Railtie::Configuration # source://railties//lib/rails/engine/configuration.rb#10 def autoload_paths=(_arg0); end - # source://railties//lib/rails/engine/configuration.rb#79 + # An array of custom eager load paths to be added to the ones defined + # automatically by Rails. Anything in this collection is considered to be + # an autoload path regardless of whether it was added to +autoload_paths+. + # + # This collection is empty by default, it accepts strings and +Pathname+ + # objects. + # + # If you'd like to add +lib+ to it, please see +autoload_lib+. + # + # source://railties//lib/rails/engine/configuration.rb#39 def eager_load_paths; end # Sets the attribute eager_load_paths @@ -2554,7 +2785,7 @@ class Rails::Engine::Configuration < ::Rails::Railtie::Configuration # # @yield [@generators] # - # source://railties//lib/rails/engine/configuration.rb#32 + # source://railties//lib/rails/engine/configuration.rb#65 def generators; end # Returns the value of attribute javascript_path. @@ -2581,7 +2812,7 @@ class Rails::Engine::Configuration < ::Rails::Railtie::Configuration # source://railties//lib/rails/engine/configuration.rb#9 def middleware=(_arg0); end - # source://railties//lib/rails/engine/configuration.rb#38 + # source://railties//lib/rails/engine/configuration.rb#71 def paths; end # Returns the value of attribute root. @@ -2589,7 +2820,7 @@ class Rails::Engine::Configuration < ::Rails::Railtie::Configuration # source://railties//lib/rails/engine/configuration.rb#8 def root; end - # source://railties//lib/rails/engine/configuration.rb#75 + # source://railties//lib/rails/engine/configuration.rb#113 def root=(value); end end @@ -2614,25 +2845,25 @@ class Rails::Engine::Railties def each(*args, &block); end end -# source://railties//lib/rails/generators.rb#17 +# source://railties//lib/rails/generators.rb#14 module Rails::Generators include ::Rails::Command::Behavior extend ::Rails::Command::Behavior::ClassMethods - # source://railties//lib/rails/generators.rb#30 + # source://railties//lib/rails/generators.rb#28 def namespace; end - # source://railties//lib/rails/generators.rb#30 + # source://railties//lib/rails/generators.rb#28 def namespace=(val); end class << self - # source://railties//lib/rails/generators.rb#282 + # source://railties//lib/rails/generators.rb#274 def add_generated_file(file); end - # source://railties//lib/rails/generators.rb#91 + # source://railties//lib/rails/generators.rb#89 def after_generate_callbacks; end - # source://railties//lib/rails/generators.rb#83 + # source://railties//lib/rails/generators.rb#81 def aliases; end # Configure generators for API only applications. It basically hides @@ -2640,14 +2871,14 @@ module Rails::Generators # migration generators, and completely disable helpers and assets # so generators such as scaffold won't create them. # - # source://railties//lib/rails/generators.rb#115 + # source://railties//lib/rails/generators.rb#113 def api_only!; end - # source://railties//lib/rails/generators.rb#67 + # source://railties//lib/rails/generators.rb#65 def configure!(config); end # Hold configured generators fallbacks. If a plugin developer wants a - # generator group to fallback to another group in case of missing generators, + # generator group to fall back to another group in case of missing generators, # they can add a fallback. # # For example, shoulda is considered a test_framework and is an extension @@ -2659,7 +2890,7 @@ module Rails::Generators # # Rails::Generators.fallbacks[:shoulda] = :test_unit # - # source://railties//lib/rails/generators.rb#107 + # source://railties//lib/rails/generators.rb#105 def fallbacks; end # Rails finds namespaces similar to Thor, it only adds one rule: @@ -2676,12 +2907,12 @@ module Rails::Generators # Notice that "rails:generators:webrat" could be loaded as well, what # Rails looks for is the first and last parts of the namespace. # - # source://railties//lib/rails/generators.rb#232 + # source://railties//lib/rails/generators.rb#230 def find_by_namespace(name, base = T.unsafe(nil), context = T.unsafe(nil)); end # Show help message with available generators. # - # source://railties//lib/rails/generators.rb#168 + # source://railties//lib/rails/generators.rb#166 def help(command = T.unsafe(nil)); end # Returns an array of generator namespaces that are hidden. @@ -2689,63 +2920,63 @@ module Rails::Generators # Some are aliased such as "rails:migration" and can be # invoked with the shorter "migration". # - # source://railties//lib/rails/generators.rb#133 + # source://railties//lib/rails/generators.rb#131 def hidden_namespaces; end - # source://railties//lib/rails/generators.rb#162 + # source://railties//lib/rails/generators.rb#160 def hide_namespace(*namespaces); end - # source://railties//lib/rails/generators.rb#162 + # source://railties//lib/rails/generators.rb#160 def hide_namespaces(*namespaces); end # Receives a namespace, arguments, and the behavior to invoke the generator. # It's used as the default entry point for generate, destroy, and update # commands. # - # source://railties//lib/rails/generators.rb#259 + # source://railties//lib/rails/generators.rb#257 def invoke(namespace, args = T.unsafe(nil), config = T.unsafe(nil)); end - # source://railties//lib/rails/generators.rb#30 + # source://railties//lib/rails/generators.rb#28 def namespace; end - # source://railties//lib/rails/generators.rb#30 + # source://railties//lib/rails/generators.rb#28 def namespace=(val); end - # source://railties//lib/rails/generators.rb#87 + # source://railties//lib/rails/generators.rb#85 def options; end - # source://railties//lib/rails/generators.rb#189 + # source://railties//lib/rails/generators.rb#188 def print_generators; end - # source://railties//lib/rails/generators.rb#184 + # source://railties//lib/rails/generators.rb#183 def public_namespaces; end - # source://railties//lib/rails/generators.rb#193 + # source://railties//lib/rails/generators.rb#192 def sorted_groups; end - # source://railties//lib/rails/generators.rb#79 + # source://railties//lib/rails/generators.rb#77 def templates_path; end private - # source://railties//lib/rails/generators.rb#309 + # source://railties//lib/rails/generators.rb#301 def command_type; end - # source://railties//lib/rails/generators.rb#317 + # source://railties//lib/rails/generators.rb#309 def file_lookup_paths; end # Try fallbacks for the given base. # - # source://railties//lib/rails/generators.rb#294 + # source://railties//lib/rails/generators.rb#286 def invoke_fallbacks_for(name, base); end - # source://railties//lib/rails/generators.rb#313 + # source://railties//lib/rails/generators.rb#305 def lookup_paths; end - # source://railties//lib/rails/generators.rb#288 + # source://railties//lib/rails/generators.rb#280 def print_list(base, namespaces); end - # source://railties//lib/rails/generators.rb#321 + # source://railties//lib/rails/generators.rb#313 def run_after_generate_callback; end end end @@ -2765,42 +2996,98 @@ module Rails::Generators::Actions # gem "rspec-rails" # end # - # source://railties//lib/rails/generators/actions.rb#106 + # source://railties//lib/rails/generators/actions.rb#151 def add_source(source, options = T.unsafe(nil), &block); end - # Adds a line inside the Application class for config/application.rb. + # Adds configuration code to a \Rails runtime environment. + # + # By default, adds code inside the +Application+ class in + # +config/application.rb+ so that it applies to all environments. + # + # environment %(config.asset_host = "cdn.provider.com") + # + # Results in: + # + # # config/application.rb + # class Application < Rails::Application + # config.asset_host = "cdn.provider.com" + # # ... + # end # - # If options :env is specified, the line is appended to the corresponding - # file in config/environments. + # If the +:env+ option is specified, the code will be added to the + # corresponding file in +config/environments+ instead. + # + # environment %(config.asset_host = "localhost:3000"), env: "development" + # + # Results in: + # + # # config/environments/development.rb + # Rails.application.configure do + # config.asset_host = "localhost:3000" + # # ... + # end + # + # +:env+ can also be an array. In which case, the code is added to each + # corresponding file in +config/environments+. + # + # The code can also be specified as the return value of the block: # # environment do - # "config.asset_host = 'cdn.provider.com'" + # %(config.asset_host = "cdn.provider.com") # end # # environment(nil, env: "development") do - # "config.asset_host = 'localhost:3000'" + # %(config.asset_host = "localhost:3000") # end # - # source://railties//lib/rails/generators/actions.rb#132 + # source://railties//lib/rails/generators/actions.rb#206 def application(data = T.unsafe(nil), options = T.unsafe(nil)); end - # Adds a line inside the Application class for config/application.rb. + # Adds configuration code to a \Rails runtime environment. + # + # By default, adds code inside the +Application+ class in + # +config/application.rb+ so that it applies to all environments. + # + # environment %(config.asset_host = "cdn.provider.com") + # + # Results in: + # + # # config/application.rb + # class Application < Rails::Application + # config.asset_host = "cdn.provider.com" + # # ... + # end + # + # If the +:env+ option is specified, the code will be added to the + # corresponding file in +config/environments+ instead. + # + # environment %(config.asset_host = "localhost:3000"), env: "development" + # + # Results in: + # + # # config/environments/development.rb + # Rails.application.configure do + # config.asset_host = "localhost:3000" + # # ... + # end # - # If options :env is specified, the line is appended to the corresponding - # file in config/environments. + # +:env+ can also be an array. In which case, the code is added to each + # corresponding file in +config/environments+. + # + # The code can also be specified as the return value of the block: # # environment do - # "config.asset_host = 'cdn.provider.com'" + # %(config.asset_host = "cdn.provider.com") # end # # environment(nil, env: "development") do - # "config.asset_host = 'localhost:3000'" + # %(config.asset_host = "localhost:3000") # end # - # source://railties//lib/rails/generators/actions.rb#132 + # source://railties//lib/rails/generators/actions.rb#206 def environment(data = T.unsafe(nil), options = T.unsafe(nil)); end - # Adds an entry into +Gemfile+ for the supplied gem. + # Adds a +gem+ declaration to the +Gemfile+ for the specified gem. # # gem "rspec", group: :test # gem "technoweenie-restful-authentication", lib: "restful-authentication", source: "http://gems.github.com/" @@ -2808,189 +3095,277 @@ module Rails::Generators::Actions # gem "RedCloth", ">= 4.1.0", "< 4.2.0" # gem "rspec", comment: "Put this comment above the gem declaration" # - # source://railties//lib/rails/generators/actions.rb#22 - def gem(*args); end - - # Wraps gem entries inside a group. + # Note that this method only adds the gem to the +Gemfile+; it does not + # install the gem. # - # gem_group :development, :test do - # gem "rspec-rails" - # end + # ==== Options # - # source://railties//lib/rails/generators/actions.rb#66 - def gem_group(*names, &block); end - - # Generate something using a generator from Rails or a plugin. - # The second parameter is the argument string that is passed to - # the generator or an Array that is joined. + # [+:version+] + # The version constraints for the gem, specified as a string or an + # array of strings: # - # generate(:authenticated, "user session") + # gem "my_gem", version: "~> 1.1" + # gem "my_gem", version: [">= 1.1", "< 2.0"] # - # source://railties//lib/rails/generators/actions.rb#238 - def generate(what, *args); end - - # Run a command in git. + # Alternatively, can be specified as one or more arguments following the + # gem name: # - # git :init - # git add: "this.file that.rb" - # git add: "onefile.rb", rm: "badfile.cxx" + # gem "my_gem", ">= 1.1", "< 2.0" # - # source://railties//lib/rails/generators/actions.rb#154 - def git(commands = T.unsafe(nil)); end - - # source://railties//lib/rails/generators/actions.rb#80 - def github(repo, options = T.unsafe(nil), &block); end - - # Create a new initializer with the provided code (either in a block or a string). + # [+:comment+] + # Outputs a comment above the +gem+ declaration in the +Gemfile+. # - # initializer("globals.rb") do - # data = "" + # gem "my_gem", comment: "First line.\nSecond line." # - # ['MY_WORK', 'ADMINS', 'BEST_COMPANY_EVAR'].each do |const| - # data << "#{const} = :entp\n" - # end + # Outputs: + # + # # First line. + # # Second line. + # gem "my_gem" + # + # [+:group+] + # The gem group in the +Gemfile+ that the gem belongs to. + # + # [+:git+] + # The URL of the git repository for the gem. + # + # Any additional options passed to this method will be appended to the + # +gem+ declaration in the +Gemfile+. For example: # - # data + # gem "my_gem", comment: "Edge my_gem", git: "https://example.com/my_gem.git", branch: "master" + # + # Outputs: + # + # # Edge my_gem + # gem "my_gem", git: "https://example.com/my_gem.git", branch: "master" + # + # source://railties//lib/rails/generators/actions.rb#67 + def gem(*args); end + + # Wraps gem entries inside a group. + # + # gem_group :development, :test do + # gem "rspec-rails" # end # - # initializer("api.rb", "API_KEY = '123456'") + # source://railties//lib/rails/generators/actions.rb#111 + def gem_group(*names, &block); end + + # Runs another generator. + # + # generate "scaffold", "Post title:string body:text" + # generate "scaffold", "Post", "title:string", "body:text" # - # source://railties//lib/rails/generators/actions.rb#227 - def initializer(filename, data = T.unsafe(nil)); end + # The first argument is the generator name, and the remaining arguments + # are joined together and passed to the generator. + # + # source://railties//lib/rails/generators/actions.rb#332 + def generate(what, *args); end - # Create a new file in the lib/ directory. Code can be specified - # in a block or a data string can be given. + # Runs one or more git commands. # - # lib("crypto.rb") do - # "crypted_special_value = '#{rand}--#{Time.now}--#{rand(1337)}--'" + # git :init + # # => runs `git init` + # + # git add: "this.file that.rb" + # # => runs `git add this.file that.rb` + # + # git commit: "-m 'First commit'" + # # => runs `git commit -m 'First commit'` + # + # git add: "good.rb", rm: "bad.cxx" + # # => runs `git add good.rb; git rm bad.cxx` + # + # source://railties//lib/rails/generators/actions.rb#237 + def git(commands = T.unsafe(nil)); end + + # source://railties//lib/rails/generators/actions.rb#125 + def github(repo, options = T.unsafe(nil), &block); end + + # Creates an initializer file in +config/initializers/+. The code can be + # specified as an argument or as the return value of the block. + # + # initializer "api.rb", <<~RUBY + # API_KEY = "123456" + # RUBY + # + # initializer "api.rb" do + # %(API_KEY = "123456") # end # - # lib("foreign.rb", "# Foreign code is fun") + # source://railties//lib/rails/generators/actions.rb#319 + def initializer(filename, data = T.unsafe(nil)); end + + # Creates a file in +lib/+. The contents can be specified as an argument + # or as the return value of the block. + # + # lib "foreign.rb", <<~RUBY + # # Foreign code is fun + # RUBY # - # source://railties//lib/rails/generators/actions.rb#187 + # lib "foreign.rb" do + # "# Foreign code is fun" + # end + # + # source://railties//lib/rails/generators/actions.rb#275 def lib(filename, data = T.unsafe(nil)); end - # Runs the supplied rake task (invoked with 'rails ...') + # Runs the specified \Rails command. + # + # rails_command "db:migrate" + # rails_command "db:migrate", env: "production" + # rails_command "db:migrate", abort_on_failure: true + # rails_command "stats", capture: true + # rails_command "gems:install", sudo: true + # + # ==== Options + # + # [+:env+] + # The \Rails environment in which to run the command. Defaults to + # ENV["RAILS_ENV"] || "development". # - # rails_command("db:migrate") - # rails_command("db:migrate", env: "production") - # rails_command("gems:install", sudo: true) - # rails_command("gems:install", capture: true) + # [+:abort_on_failure+] + # Whether to halt the generator if the command exits with a non-success + # exit status. # - # source://railties//lib/rails/generators/actions.rb#263 + # [+:capture+] + # Whether to capture and return the output of the command. + # + # [+:sudo+] + # Whether to run the command using +sudo+. + # + # source://railties//lib/rails/generators/actions.rb#391 def rails_command(command, options = T.unsafe(nil)); end - # Runs the supplied rake task (invoked with 'rake ...') + # Runs the specified Rake task. + # + # rake "db:migrate" + # rake "db:migrate", env: "production" + # rake "db:migrate", abort_on_failure: true + # rake "stats", capture: true + # rake "gems:install", sudo: true + # + # ==== Options + # + # [+:env+] + # The \Rails environment in which to run the task. Defaults to + # ENV["RAILS_ENV"] || "development". + # + # [+:abort_on_failure+] + # Whether to halt the generator if the task exits with a non-success + # exit status. # - # rake("db:migrate") - # rake("db:migrate", env: "production") - # rake("gems:install", sudo: true) - # rake("gems:install", capture: true) + # [+:capture+] + # Whether to capture and return the output of the task. # - # source://railties//lib/rails/generators/actions.rb#253 + # [+:sudo+] + # Whether to run the task using +sudo+. + # + # source://railties//lib/rails/generators/actions.rb#364 def rake(command, options = T.unsafe(nil)); end - # Create a new +Rakefile+ with the provided code (either in a block or a string). + # Creates a Rake tasks file in +lib/tasks/+. The code can be specified as + # an argument or as the return value of the block. + # + # rakefile "bootstrap.rake", <<~RUBY + # task :bootstrap do + # puts "Boots! Boots! Boots!" + # end + # RUBY # - # rakefile("bootstrap.rake") do + # rakefile "bootstrap.rake" do # project = ask("What is the UNIX name of your project?") # - # <<-TASK + # <<~RUBY # namespace :#{project} do # task :bootstrap do - # puts "I like boots!" + # puts "Boots! Boots! Boots!" # end # end - # TASK + # RUBY # end # - # rakefile('seed.rake', 'puts "Planting seeds"') - # - # source://railties//lib/rails/generators/actions.rb#208 + # source://railties//lib/rails/generators/actions.rb#302 def rakefile(filename, data = T.unsafe(nil)); end # Reads the given file at the source root and prints it in the console. # # readme "README" # - # source://railties//lib/rails/generators/actions.rb#314 + # source://railties//lib/rails/generators/actions.rb#442 def readme(path); end - # Make an entry in Rails routing file config/routes.rb + # Make an entry in \Rails routing file config/routes.rb # # route "root 'welcome#index'" # route "root 'admin#index'", namespace: :admin # - # source://railties//lib/rails/generators/actions.rb#281 + # source://railties//lib/rails/generators/actions.rb#409 def route(routing_code, namespace: T.unsafe(nil)); end - # Create a new file in the vendor/ directory. Code can be specified - # in a block or a data string can be given. + # Creates a file in +vendor/+. The contents can be specified as an + # argument or as the return value of the block. # - # vendor("sekrit.rb") do - # sekrit_salt = "#{Time.now}--#{3.years.ago}--#{rand}--" - # "salt = '#{sekrit_salt}'" - # end + # vendor "foreign.rb", <<~RUBY + # # Foreign code is fun + # RUBY # - # vendor("foreign.rb", "# Foreign code is fun") + # vendor "foreign.rb" do + # "# Foreign code is fun" + # end # - # source://railties//lib/rails/generators/actions.rb#173 + # source://railties//lib/rails/generators/actions.rb#258 def vendor(filename, data = T.unsafe(nil)); end private # Append string to a file with a newline if necessary # - # source://railties//lib/rails/generators/actions.rb#388 + # source://railties//lib/rails/generators/actions.rb#507 def append_file_with_newline(path, str, options = T.unsafe(nil)); end # Runs the supplied command using either "rake ..." or "rails ..." # based on the executor parameter provided. # - # source://railties//lib/rails/generators/actions.rb#333 + # source://railties//lib/rails/generators/actions.rb#461 def execute_command(executor, command, options = T.unsafe(nil)); end - # Add an extension to the given name based on the platform. - # - # source://railties//lib/rails/generators/actions.rb#347 - def extify(name); end - # Indent the +Gemfile+ to the depth of @indentation # - # source://railties//lib/rails/generators/actions.rb#375 + # source://railties//lib/rails/generators/actions.rb#494 def indentation; end # Define log for backwards compatibility. If just one argument is sent, # invoke say, otherwise invoke say_status. Differently from say and # similarly to say_status, this method respects the quiet? option given. # - # source://railties//lib/rails/generators/actions.rb#322 + # source://railties//lib/rails/generators/actions.rb#450 def log(*args); end - # source://railties//lib/rails/generators/actions.rb#394 + # source://railties//lib/rails/generators/actions.rb#513 def match_file(path, pattern); end # Returns optimized string with indentation # - # source://railties//lib/rails/generators/actions.rb#368 + # source://railties//lib/rails/generators/actions.rb#487 def optimize_indentation(value, amount = T.unsafe(nil)); end # Always returns value in double quotes. # - # source://railties//lib/rails/generators/actions.rb#356 + # source://railties//lib/rails/generators/actions.rb#475 def quote(value); end # Returns optimized string with indentation # - # source://railties//lib/rails/generators/actions.rb#368 + # source://railties//lib/rails/generators/actions.rb#487 def rebase_indentation(value, amount = T.unsafe(nil)); end - # source://railties//lib/rails/generators/actions.rb#398 + # source://railties//lib/rails/generators/actions.rb#517 def route_namespace_pattern(namespace); end # Manage +Gemfile+ indentation for a DSL action block # - # source://railties//lib/rails/generators/actions.rb#380 + # source://railties//lib/rails/generators/actions.rb#499 def with_indentation(&block); end end @@ -3031,7 +3406,7 @@ class Rails::Generators::Actions::CreateMigration < ::Thor::Actions::CreateFile def say_status(status, color, message = T.unsafe(nil)); end end -# ActiveModel is a class to be implemented by each ORM to allow Rails to +# ActiveModel is a class to be implemented by each ORM to allow \Rails to # generate customized controller code. # # The API has the same methods as ActiveRecord, but each method returns a @@ -3061,15 +3436,19 @@ class Rails::Generators::ActiveModel # source://railties//lib/rails/generators/active_model.rb#31 def initialize(name); end - # DELETE destroy + # Used for: # - # source://railties//lib/rails/generators/active_model.rb#75 + # * DELETE +destroy+ + # + # source://railties//lib/rails/generators/active_model.rb#89 def destroy; end - # POST create - # PATCH/PUT update + # Used for: + # + # * POST +create+ + # * PATCH / PUT +update+ # - # source://railties//lib/rails/generators/active_model.rb#70 + # source://railties//lib/rails/generators/active_model.rb#82 def errors; end # Returns the value of attribute name. @@ -3077,34 +3456,44 @@ class Rails::Generators::ActiveModel # source://railties//lib/rails/generators/active_model.rb#29 def name; end - # POST create + # Used for: # - # source://railties//lib/rails/generators/active_model.rb#59 + # * POST +create+ + # + # source://railties//lib/rails/generators/active_model.rb#67 def save; end - # PATCH/PUT update + # Used for: + # + # * PATCH / PUT +update+ # - # source://railties//lib/rails/generators/active_model.rb#64 + # source://railties//lib/rails/generators/active_model.rb#74 def update(params = T.unsafe(nil)); end class << self - # GET index + # Used for: + # + # * GET +index+ # - # source://railties//lib/rails/generators/active_model.rb#36 + # source://railties//lib/rails/generators/active_model.rb#38 def all(klass); end - # GET new - # POST create + # Used for: # - # source://railties//lib/rails/generators/active_model.rb#50 + # * GET +new+ + # * POST +create+ + # + # source://railties//lib/rails/generators/active_model.rb#56 def build(klass, params = T.unsafe(nil)); end - # GET show - # GET edit - # PATCH/PUT update - # DELETE destroy + # Used for: + # + # * GET +show+ + # * GET +edit+ + # * PATCH / PUT +update+ + # * DELETE +destroy+ # - # source://railties//lib/rails/generators/active_model.rb#44 + # source://railties//lib/rails/generators/active_model.rb#48 def find(klass, params = T.unsafe(nil)); end end end @@ -3113,33 +3502,24 @@ end module Rails::Generators::AppName private - # source://railties//lib/rails/generators/app_name.rb#33 + # source://railties//lib/rails/generators/app_name.rb#22 def app_const; end - # source://railties//lib/rails/generators/app_name.rb#28 + # source://railties//lib/rails/generators/app_name.rb#17 def app_const_base; end # source://railties//lib/rails/generators/app_name.rb#9 def app_name; end - # source://railties//lib/rails/generators/app_name.rb#28 - def camelized; end - - # source://railties//lib/rails/generators/app_name.rb#21 - def defined_app_const_base; end - - # source://railties//lib/rails/generators/app_name.rb#21 - def defined_app_const_base?; end - # source://railties//lib/rails/generators/app_name.rb#17 - def defined_app_name; end + def camelized; end # source://railties//lib/rails/generators/app_name.rb#13 def original_app_name; end # @return [Boolean] # - # source://railties//lib/rails/generators/app_name.rb#37 + # source://railties//lib/rails/generators/app_name.rb#26 def valid_const?; end end @@ -3157,93 +3537,96 @@ class Rails::Generators::Base < ::Thor::Group # Check whether the given class names are already taken by user # application or Ruby on Rails. # - # source://railties//lib/rails/generators/base.rb#256 + # source://railties//lib/rails/generators/base.rb#264 def class_collisions(*class_names); end # Takes in an array of nested modules and extracts the last module # - # source://railties//lib/rails/generators/base.rb#279 + # source://railties//lib/rails/generators/base.rb#287 def extract_last_module(nesting); end - # source://railties//lib/rails/generators/base.rb#294 + # source://railties//lib/rails/generators/base.rb#427 + def gem_ruby_version; end + + # source://railties//lib/rails/generators/base.rb#302 def indent(content, multiplier = T.unsafe(nil)); end # Wrap block with namespace of current application # if namespace exists and is not skipped # - # source://railties//lib/rails/generators/base.rb#288 + # source://railties//lib/rails/generators/base.rb#296 def module_namespacing(&block); end - # source://railties//lib/rails/generators/base.rb#304 + # source://railties//lib/rails/generators/base.rb#312 def namespace; end - # source://railties//lib/rails/generators/base.rb#312 + # source://railties//lib/rails/generators/base.rb#320 def namespace_dirs; end # @return [Boolean] # - # source://railties//lib/rails/generators/base.rb#308 + # source://railties//lib/rails/generators/base.rb#316 def namespaced?; end - # source://railties//lib/rails/generators/base.rb#316 + # source://railties//lib/rails/generators/base.rb#324 def namespaced_path; end - # source://railties//lib/rails/generators/base.rb#299 + # source://railties//lib/rails/generators/base.rb#307 def wrap_with_namespace(content); end class << self # Small macro to add ruby as an option to the generator with proper # default value plus an instance helper method called shebang. # - # source://railties//lib/rails/generators/base.rb#388 + # source://railties//lib/rails/generators/base.rb#396 def add_shebang_option!; end - # Use Rails default banner. + # Use \Rails default banner. # - # source://railties//lib/rails/generators/base.rb#321 + # source://railties//lib/rails/generators/base.rb#329 def banner; end # Sets the base_name taking into account the current class namespace. # - # source://railties//lib/rails/generators/base.rb#326 + # source://railties//lib/rails/generators/base.rb#334 def base_name; end # Returns the base root for a common set of generators. This is used to dynamically # guess the default source root. # - # source://railties//lib/rails/generators/base.rb#228 + # source://railties//lib/rails/generators/base.rb#236 def base_root; end # Make class option aware of Rails::Generators.options and Rails::Generators.aliases. # - # source://railties//lib/rails/generators/base.rb#209 + # source://railties//lib/rails/generators/base.rb#217 def class_option(name, options = T.unsafe(nil)); end # Returns default aliases for the option name given doing a lookup in # Rails::Generators.aliases. # - # source://railties//lib/rails/generators/base.rb#349 + # source://railties//lib/rails/generators/base.rb#357 def default_aliases_for_option(name, options); end # Returns default for the option name given doing a lookup in config. # - # source://railties//lib/rails/generators/base.rb#354 + # source://railties//lib/rails/generators/base.rb#362 def default_for_option(config, name, options, default); end - # source://railties//lib/rails/generators/base.rb#414 + # source://railties//lib/rails/generators/base.rb#422 def default_generator_root; end # Returns the default source root for a given generator. This is used internally - # by rails to set its generators source root. If you want to customize your source + # by Rails to set its generators source root. If you want to customize your source # root, you should use source_root. # - # source://railties//lib/rails/generators/base.rb#219 + # source://railties//lib/rails/generators/base.rb#227 def default_source_root; end # Returns the default value for the option name given doing a lookup in # Rails::Generators.options. # - # source://railties//lib/rails/generators/base.rb#343 + # source://railties//lib/rails/generators/base.rb#351 def default_value_for_option(name, options); end # Tries to get the description from a USAGE file one folder above the source @@ -3260,7 +3643,7 @@ class Rails::Generators::Base < ::Thor::Group # Removes the namespaces and get the generator name. For example, # Rails::Generators::ModelGenerator will return "model" as generator name. # - # source://railties//lib/rails/generators/base.rb#334 + # source://railties//lib/rails/generators/base.rb#342 def generator_name; end # Convenience method to hide this generator from the available ones when @@ -3286,15 +3669,15 @@ class Rails::Generators::Base < ::Thor::Group # # For example, if the user invoke the controller generator as: # - # bin/rails generate controller Account --test-framework=test_unit + # $ bin/rails generate controller Account --test-framework=test_unit # # The controller generator will then try to invoke the following generators: # # "rails:test_unit", "test_unit:controller", "test_unit" # # Notice that "rails:generators:test_unit" could be loaded as well, what - # Rails looks for is the first and last parts of the namespace. This is what - # allows any test framework to hook into Rails as long as it provides any + # \Rails looks for is the first and last parts of the namespace. This is what + # allows any test framework to hook into \Rails as long as it provides any # of the hooks above. # # ==== Options @@ -3341,11 +3724,11 @@ class Rails::Generators::Base < ::Thor::Group # All hooks come with switches for user interface. If you do not want # to use any test framework, you can do: # - # bin/rails generate controller Account --skip-test-framework + # $ bin/rails generate controller Account --skip-test-framework # # Or similarly: # - # bin/rails generate controller Account --no-test-framework + # $ bin/rails generate controller Account --no-test-framework # # ==== Boolean hooks # @@ -3357,7 +3740,7 @@ class Rails::Generators::Base < ::Thor::Group # # Then, if you want webrat to be invoked, just supply: # - # bin/rails generate controller Account --webrat + # $ bin/rails generate controller Account --webrat # # The hooks lookup is similar as above: # @@ -3383,13 +3766,13 @@ class Rails::Generators::Base < ::Thor::Group # Keep hooks configuration that are used on prepare_for_invocation. # - # source://railties//lib/rails/generators/base.rb#367 + # source://railties//lib/rails/generators/base.rb#375 def hooks; end # Cache source root and add lib/generators/base/generator/templates to # source paths. # - # source://railties//lib/rails/generators/base.rb#234 + # source://railties//lib/rails/generators/base.rb#242 def inherited(base); end # Convenience method to get the namespace from the class name. It's the @@ -3402,14 +3785,14 @@ class Rails::Generators::Base < ::Thor::Group # Prepare class invocation to search on Rails namespace if a previous # added hook is being used. # - # source://railties//lib/rails/generators/base.rb#373 + # source://railties//lib/rails/generators/base.rb#381 def prepare_for_invocation(name, value); end # Remove a previously added hook. # # remove_hook_for :orm # - # source://railties//lib/rails/generators/base.rb#200 + # source://railties//lib/rails/generators/base.rb#207 def remove_hook_for(*names); end # Returns the source root for this generator using default_source_root as default. @@ -3417,39 +3800,210 @@ class Rails::Generators::Base < ::Thor::Group # source://railties//lib/rails/generators/base.rb#34 def source_root(path = T.unsafe(nil)); end - # source://railties//lib/rails/generators/base.rb#406 + # source://railties//lib/rails/generators/base.rb#414 def usage_path; end end end -# source://railties//lib/rails/generators.rb#32 +# source://railties//lib/rails/generators.rb#30 Rails::Generators::DEFAULT_ALIASES = T.let(T.unsafe(nil), Hash) -# source://railties//lib/rails/generators.rb#49 +# source://railties//lib/rails/generators.rb#47 Rails::Generators::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash) # source://railties//lib/rails/generators/database.rb#5 -module Rails::Generators::Database - # source://railties//lib/rails/generators/database.rb#9 - def initialize(*_arg0); end +class Rails::Generators::Database + # @raise [NotImplementedError] + # + # source://railties//lib/rails/generators/database.rb#49 + def base_package; end + # @raise [NotImplementedError] + # + # source://railties//lib/rails/generators/database.rb#53 + def build_package; end + + # source://railties//lib/rails/generators/database.rb#60 + def feature; end + + # @raise [NotImplementedError] + # + # source://railties//lib/rails/generators/database.rb#41 + def feature_name; end + + # @raise [NotImplementedError] + # + # source://railties//lib/rails/generators/database.rb#45 + def gem; end + + # source://railties//lib/rails/generators/database.rb#58 + def host; end + + # @raise [NotImplementedError] + # # source://railties//lib/rails/generators/database.rb#29 - def convert_database_option_for_jruby; end + def name; end - # source://railties//lib/rails/generators/database.rb#14 - def gem_for_database(database = T.unsafe(nil)); end + # @raise [NotImplementedError] + # + # source://railties//lib/rails/generators/database.rb#37 + def port; end - private + # @raise [NotImplementedError] + # + # source://railties//lib/rails/generators/database.rb#33 + def service; end + + # source://railties//lib/rails/generators/database.rb#57 + def socket; end + + # source://railties//lib/rails/generators/database.rb#66 + def volume; end + + class << self + # source://railties//lib/rails/generators/database.rb#19 + def all; end - # source://railties//lib/rails/generators/database.rb#42 - def mysql_socket; end + # source://railties//lib/rails/generators/database.rb#9 + def build(database_name); end + end end -# source://railties//lib/rails/generators/database.rb#7 +# source://railties//lib/rails/generators/database.rb#6 Rails::Generators::Database::DATABASES = T.let(T.unsafe(nil), Array) -# source://railties//lib/rails/generators/database.rb#6 -Rails::Generators::Database::JDBC_DATABASES = T.let(T.unsafe(nil), Array) +# source://railties//lib/rails/generators/database.rb#172 +class Rails::Generators::Database::MariaDB < ::Rails::Generators::Database + include ::Rails::Generators::Database::MySqlSocket + + # source://railties//lib/rails/generators/database.rb#199 + def base_package; end + + # source://railties//lib/rails/generators/database.rb#203 + def build_package; end + + # source://railties//lib/rails/generators/database.rb#207 + def feature_name; end + + # source://railties//lib/rails/generators/database.rb#195 + def gem; end + + # source://railties//lib/rails/generators/database.rb#175 + def name; end + + # source://railties//lib/rails/generators/database.rb#191 + def port; end + + # source://railties//lib/rails/generators/database.rb#179 + def service; end +end + +# source://railties//lib/rails/generators/database.rb#92 +class Rails::Generators::Database::MySQL < ::Rails::Generators::Database + include ::Rails::Generators::Database::MySqlSocket + + # source://railties//lib/rails/generators/database.rb#120 + def base_package; end + + # source://railties//lib/rails/generators/database.rb#124 + def build_package; end + + # source://railties//lib/rails/generators/database.rb#128 + def feature_name; end + + # source://railties//lib/rails/generators/database.rb#116 + def gem; end + + # source://railties//lib/rails/generators/database.rb#95 + def name; end + + # source://railties//lib/rails/generators/database.rb#112 + def port; end + + # source://railties//lib/rails/generators/database.rb#99 + def service; end +end + +# source://railties//lib/rails/generators/database.rb#72 +module Rails::Generators::Database::MySqlSocket + # source://railties//lib/rails/generators/database.rb#87 + def host; end + + # source://railties//lib/rails/generators/database.rb#73 + def socket; end +end + +# source://railties//lib/rails/generators/database.rb#242 +class Rails::Generators::Database::Null < ::Rails::Generators::Database + # source://railties//lib/rails/generators/database.rb#247 + def base_package; end + + # source://railties//lib/rails/generators/database.rb#248 + def build_package; end + + # source://railties//lib/rails/generators/database.rb#249 + def feature_name; end + + # source://railties//lib/rails/generators/database.rb#243 + def name; end + + # source://railties//lib/rails/generators/database.rb#245 + def port; end + + # source://railties//lib/rails/generators/database.rb#244 + def service; end + + # source://railties//lib/rails/generators/database.rb#246 + def volume; end +end + +# source://railties//lib/rails/generators/database.rb#133 +class Rails::Generators::Database::PostgreSQL < ::Rails::Generators::Database + # source://railties//lib/rails/generators/database.rb#159 + def base_package; end + + # source://railties//lib/rails/generators/database.rb#163 + def build_package; end + + # source://railties//lib/rails/generators/database.rb#167 + def feature_name; end + + # source://railties//lib/rails/generators/database.rb#155 + def gem; end + + # source://railties//lib/rails/generators/database.rb#134 + def name; end + + # source://railties//lib/rails/generators/database.rb#151 + def port; end + + # source://railties//lib/rails/generators/database.rb#138 + def service; end +end + +# source://railties//lib/rails/generators/database.rb#212 +class Rails::Generators::Database::SQLite3 < ::Rails::Generators::Database + # source://railties//lib/rails/generators/database.rb#229 + def base_package; end + + # source://railties//lib/rails/generators/database.rb#233 + def build_package; end + + # source://railties//lib/rails/generators/database.rb#237 + def feature_name; end + + # source://railties//lib/rails/generators/database.rb#225 + def gem; end + + # source://railties//lib/rails/generators/database.rb#213 + def name; end + + # source://railties//lib/rails/generators/database.rb#221 + def port; end + + # source://railties//lib/rails/generators/database.rb#217 + def service; end +end # source://railties//lib/rails/generators/base.rb#14 class Rails::Generators::Error < ::Thor::Error; end @@ -3458,17 +4012,17 @@ class Rails::Generators::Error < ::Thor::Error; end class Rails::Generators::GeneratedAttribute # @return [GeneratedAttribute] a new instance of GeneratedAttribute # - # source://railties//lib/rails/generators/generated_attribute.rb#97 + # source://railties//lib/rails/generators/generated_attribute.rb#109 def initialize(name, type = T.unsafe(nil), index_type = T.unsafe(nil), attr_options = T.unsafe(nil)); end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#199 + # source://railties//lib/rails/generators/generated_attribute.rb#211 def attachment?; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#203 + # source://railties//lib/rails/generators/generated_attribute.rb#215 def attachments?; end # Returns the value of attribute attr_options. @@ -3476,34 +4030,34 @@ class Rails::Generators::GeneratedAttribute # source://railties//lib/rails/generators/generated_attribute.rb#31 def attr_options; end - # source://railties//lib/rails/generators/generated_attribute.rb#159 + # source://railties//lib/rails/generators/generated_attribute.rb#171 def column_name; end - # source://railties//lib/rails/generators/generated_attribute.rb#121 + # source://railties//lib/rails/generators/generated_attribute.rb#133 def default; end - # source://railties//lib/rails/generators/generated_attribute.rb#105 + # source://railties//lib/rails/generators/generated_attribute.rb#117 def field_type; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#163 + # source://railties//lib/rails/generators/generated_attribute.rb#175 def foreign_key?; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#179 + # source://railties//lib/rails/generators/generated_attribute.rb#191 def has_index?; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#183 + # source://railties//lib/rails/generators/generated_attribute.rb#195 def has_uniq_index?; end - # source://railties//lib/rails/generators/generated_attribute.rb#147 + # source://railties//lib/rails/generators/generated_attribute.rb#159 def human_name; end - # source://railties//lib/rails/generators/generated_attribute.rb#151 + # source://railties//lib/rails/generators/generated_attribute.rb#163 def index_name; end # Sets the attribute index_name @@ -3513,10 +4067,10 @@ class Rails::Generators::GeneratedAttribute # source://railties//lib/rails/generators/generated_attribute.rb#32 def index_name=(_arg0); end - # source://railties//lib/rails/generators/generated_attribute.rb#215 + # source://railties//lib/rails/generators/generated_attribute.rb#227 def inject_index_options; end - # source://railties//lib/rails/generators/generated_attribute.rb#211 + # source://railties//lib/rails/generators/generated_attribute.rb#223 def inject_options; end # Returns the value of attribute name. @@ -3531,43 +4085,46 @@ class Rails::Generators::GeneratedAttribute # source://railties//lib/rails/generators/generated_attribute.rb#30 def name=(_arg0); end - # source://railties//lib/rails/generators/generated_attribute.rb#219 + # source://railties//lib/rails/generators/generated_attribute.rb#231 def options_for_migration; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#187 + # source://railties//lib/rails/generators/generated_attribute.rb#199 def password_digest?; end - # source://railties//lib/rails/generators/generated_attribute.rb#139 + # source://railties//lib/rails/generators/generated_attribute.rb#151 def plural_name; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#171 + # source://railties//lib/rails/generators/generated_attribute.rb#183 def polymorphic?; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#167 + # source://railties//lib/rails/generators/generated_attribute.rb#179 def reference?; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#175 + # source://railties//lib/rails/generators/generated_attribute.rb#187 def required?; end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#195 + # source://railties//lib/rails/generators/generated_attribute.rb#207 def rich_text?; end - # source://railties//lib/rails/generators/generated_attribute.rb#143 + # source://railties//lib/rails/generators/generated_attribute.rb#155 def singular_name; end + # source://railties//lib/rails/generators/generated_attribute.rb#243 + def to_s; end + # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#191 + # source://railties//lib/rails/generators/generated_attribute.rb#203 def token?; end # Returns the value of attribute type. @@ -3584,26 +4141,36 @@ class Rails::Generators::GeneratedAttribute # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#207 + # source://railties//lib/rails/generators/generated_attribute.rb#219 def virtual?; end + private + + # source://railties//lib/rails/generators/generated_attribute.rb#254 + def print_attribute_options; end + class << self + # @return [Boolean] + # + # source://railties//lib/rails/generators/generated_attribute.rb#67 + def dangerous_name?(name); end + # source://railties//lib/rails/generators/generated_attribute.rb#35 def parse(column_definition); end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#72 + # source://railties//lib/rails/generators/generated_attribute.rb#82 def reference?(type); end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#68 + # source://railties//lib/rails/generators/generated_attribute.rb#78 def valid_index_type?(index_type); end # @return [Boolean] # - # source://railties//lib/rails/generators/generated_attribute.rb#63 + # source://railties//lib/rails/generators/generated_attribute.rb#72 def valid_type?(type); end private @@ -3611,7 +4178,7 @@ class Rails::Generators::GeneratedAttribute # parse possible attribute options like :limit for string/text/binary/integer, :precision/:scale for decimals or :polymorphic for references/belongs_to # when declaring options curly brackets should be used # - # source://railties//lib/rails/generators/generated_attribute.rb#79 + # source://railties//lib/rails/generators/generated_attribute.rb#89 def parse_type_and_options(type); end end end @@ -3627,7 +4194,7 @@ Rails::Generators::GeneratedAttribute::UNIQ_INDEX_OPTIONS = T.let(T.unsafe(nil), # Holds common methods for migrations. It assumes that migrations have the # [0-9]*_name format and can be used by other frameworks (like Sequel) -# just by implementing the next migration version method. +# just by implementing the +next_migration_number+ method. # # source://railties//lib/rails/generators/migration.rb#11 module Rails::Generators::Migration @@ -3654,10 +4221,10 @@ module Rails::Generators::Migration def migration_number; end # Creates a migration template at the given destination. The difference - # to the default template method is that the migration version is appended + # to the default template method is that the migration number is prepended # to the destination file name. # - # The migration version, migration file name, migration class name are + # The migration number, migration file name, migration class name are # available as instance variables in the template to be rendered. # # migration_template "migration.rb", "db/migrate/add_foo_to_bar.rb" @@ -3690,7 +4257,7 @@ end # source://railties//lib/rails/generators/model_helpers.rb#7 module Rails::Generators::ModelHelpers - # source://railties//lib/rails/generators/model_helpers.rb#25 + # source://railties//lib/rails/generators/model_helpers.rb#26 def initialize(args, *_options); end # source://railties//lib/rails/generators/model_helpers.rb#19 @@ -3703,17 +4270,17 @@ module Rails::Generators::ModelHelpers # @return [Boolean] # - # source://railties//lib/rails/generators/model_helpers.rb#55 + # source://railties//lib/rails/generators/model_helpers.rb#56 def inflection_impossible?(name); end # @return [Boolean] # - # source://railties//lib/rails/generators/model_helpers.rb#51 + # source://railties//lib/rails/generators/model_helpers.rb#52 def irregular_model_name?(name); end # @return [Boolean] # - # source://railties//lib/rails/generators/model_helpers.rb#47 + # source://railties//lib/rails/generators/model_helpers.rb#48 def plural_model_name?(name); end class << self @@ -3746,16 +4313,16 @@ class Rails::Generators::NamedBase < ::Rails::Generators::Base # Returns the value of attribute file_name. # - # source://thor/1.2.2/lib/thor/base.rb#139 + # source://thor/1.3.1/lib/thor/base.rb#155 def file_name; end - # source://railties//lib/rails/generators/named_base.rb#29 + # source://coffee-rails/5.0.0/lib/coffee/rails/js_hook.rb#8 def js_template(source, destination); end - # source://thor/1.2.2/lib/thor/base.rb#147 + # source://thor/1.3.1/lib/thor/base.rb#163 def name; end - # source://thor/1.2.2/lib/thor/base.rb#147 + # source://thor/1.3.1/lib/thor/base.rb#163 def name=(_arg0); end # source://railties//lib/rails/generators/named_base.rb#23 @@ -3970,89 +4537,89 @@ end # source://railties//lib/rails/generators/test_case.rb#30 class Rails::Generators::TestCase < ::ActiveSupport::TestCase include ::ActiveSupport::Testing::Stream - include ::Rails::Generators::Testing::Behaviour + include ::Rails::Generators::Testing::Behavior include ::Rails::Generators::Testing::SetupAndTeardown include ::Rails::Generators::Testing::Assertions include ::FileUtils::StreamUtils_ include ::FileUtils - extend ::Rails::Generators::Testing::Behaviour::ClassMethods + extend ::Rails::Generators::Testing::Behavior::ClassMethods - # source://railties//lib/rails/generators/testing/behaviour.rb#21 + # source://railties//lib/rails/generators/testing/behavior.rb#21 def current_path; end - # source://railties//lib/rails/generators/testing/behaviour.rb#21 + # source://railties//lib/rails/generators/testing/behavior.rb#21 def current_path=(_arg0); end - # source://railties//lib/rails/generators/testing/behaviour.rb#21 + # source://railties//lib/rails/generators/testing/behavior.rb#21 def current_path?; end - # source://railties//lib/rails/generators/testing/behaviour.rb#22 + # source://railties//lib/rails/generators/testing/behavior.rb#22 def default_arguments; end - # source://railties//lib/rails/generators/testing/behaviour.rb#22 + # source://railties//lib/rails/generators/testing/behavior.rb#22 def default_arguments=(_arg0); end - # source://railties//lib/rails/generators/testing/behaviour.rb#22 + # source://railties//lib/rails/generators/testing/behavior.rb#22 def default_arguments?; end - # source://railties//lib/rails/generators/testing/behaviour.rb#23 + # source://railties//lib/rails/generators/testing/behavior.rb#23 def destination_root; end - # source://railties//lib/rails/generators/testing/behaviour.rb#23 + # source://railties//lib/rails/generators/testing/behavior.rb#23 def destination_root=(_arg0); end - # source://railties//lib/rails/generators/testing/behaviour.rb#23 + # source://railties//lib/rails/generators/testing/behavior.rb#23 def destination_root?; end - # source://railties//lib/rails/generators/testing/behaviour.rb#24 + # source://railties//lib/rails/generators/testing/behavior.rb#24 def generator_class; end - # source://railties//lib/rails/generators/testing/behaviour.rb#24 + # source://railties//lib/rails/generators/testing/behavior.rb#24 def generator_class=(_arg0); end - # source://railties//lib/rails/generators/testing/behaviour.rb#24 + # source://railties//lib/rails/generators/testing/behavior.rb#24 def generator_class?; end class << self - # source://railties//lib/rails/generators/testing/behaviour.rb#21 + # source://railties//lib/rails/generators/testing/behavior.rb#21 def current_path; end - # source://railties//lib/rails/generators/testing/behaviour.rb#21 + # source://railties//lib/rails/generators/testing/behavior.rb#21 def current_path=(value); end - # source://railties//lib/rails/generators/testing/behaviour.rb#21 + # source://railties//lib/rails/generators/testing/behavior.rb#21 def current_path?; end - # source://railties//lib/rails/generators/testing/behaviour.rb#22 + # source://railties//lib/rails/generators/testing/behavior.rb#22 def default_arguments; end - # source://railties//lib/rails/generators/testing/behaviour.rb#22 + # source://railties//lib/rails/generators/testing/behavior.rb#22 def default_arguments=(value); end - # source://railties//lib/rails/generators/testing/behaviour.rb#22 + # source://railties//lib/rails/generators/testing/behavior.rb#22 def default_arguments?; end - # source://railties//lib/rails/generators/testing/behaviour.rb#23 + # source://railties//lib/rails/generators/testing/behavior.rb#23 def destination_root; end - # source://railties//lib/rails/generators/testing/behaviour.rb#23 + # source://railties//lib/rails/generators/testing/behavior.rb#23 def destination_root=(value); end - # source://railties//lib/rails/generators/testing/behaviour.rb#23 + # source://railties//lib/rails/generators/testing/behavior.rb#23 def destination_root?; end - # source://railties//lib/rails/generators/testing/behaviour.rb#24 + # source://railties//lib/rails/generators/testing/behavior.rb#24 def generator_class; end - # source://railties//lib/rails/generators/testing/behaviour.rb#24 + # source://railties//lib/rails/generators/testing/behavior.rb#24 def generator_class=(value); end - # source://railties//lib/rails/generators/testing/behaviour.rb#24 + # source://railties//lib/rails/generators/testing/behavior.rb#24 def generator_class?; end end end -# source://railties//lib/rails/generators/testing/behaviour.rb#13 +# source://railties//lib/rails/generators/testing/behavior.rb#13 module Rails::Generators::Testing; end # source://railties//lib/rails/generators/testing/assertions.rb#6 @@ -4129,6 +4696,26 @@ module Rails::Generators::Testing::Assertions # source://railties//lib/rails/generators/testing/assertions.rb#25 def assert_file(relative, *contents); end + # Asserts a given initializer exists. You need to supply a path relative + # to the `config/initializers/` directory. + # + # assert_initializer "mail_interceptors.rb" + # + # You can also give extra arguments. If the argument is a regexp, it will check if the + # regular expression matches the given file content. If it's a string, it compares the + # file with the given string: + # + # assert_initializer "mail_interceptors.rb", /SandboxEmailInterceptor/ + # + # Finally, when a block is given, it yields the file content: + # + # assert_initializer "mail_interceptors.rb" do |initializer| + # assert_match(/SandboxEmailInterceptor/, initializer) + # end + # + # source://railties//lib/rails/generators/testing/assertions.rb#141 + def assert_initializer(name, *contents, &block); end + # Asserts the given method exists in the given content. When a block is given, # it yields the content of the method. # @@ -4193,26 +4780,26 @@ module Rails::Generators::Testing::Assertions def assert_no_migration(relative); end end -# source://railties//lib/rails/generators/testing/behaviour.rb#14 -module Rails::Generators::Testing::Behaviour +# source://railties//lib/rails/generators/testing/behavior.rb#14 +module Rails::Generators::Testing::Behavior include ::ActiveSupport::Testing::Stream extend ::ActiveSupport::Concern include GeneratedInstanceMethods mixes_in_class_methods GeneratedClassMethods - mixes_in_class_methods ::Rails::Generators::Testing::Behaviour::ClassMethods + mixes_in_class_methods ::Rails::Generators::Testing::Behavior::ClassMethods # Create a Rails::Generators::GeneratedAttribute by supplying the # attribute type and, optionally, the attribute name: # # create_generated_attribute(:string, "name") # - # source://railties//lib/rails/generators/testing/behaviour.rb#85 + # source://railties//lib/rails/generators/testing/behavior.rb#89 def create_generated_attribute(attribute_type, name = T.unsafe(nil), index = T.unsafe(nil)); end # Instantiate the generator. # - # source://railties//lib/rails/generators/testing/behaviour.rb#77 + # source://railties//lib/rails/generators/testing/behavior.rb#81 def generator(args = T.unsafe(nil), options = T.unsafe(nil), config = T.unsafe(nil)); end # Runs the generator configured for this class. The first argument is an array like @@ -4232,25 +4819,25 @@ module Rails::Generators::Testing::Behaviour # You can provide a configuration hash as second argument. This method returns the output # printed by the generator. # - # source://railties//lib/rails/generators/testing/behaviour.rb#67 + # source://railties//lib/rails/generators/testing/behavior.rb#67 def run_generator(args = T.unsafe(nil), config = T.unsafe(nil)); end private # @return [Boolean] # - # source://railties//lib/rails/generators/testing/behaviour.rb#90 + # source://railties//lib/rails/generators/testing/behavior.rb#94 def destination_root_is_set?; end - # source://railties//lib/rails/generators/testing/behaviour.rb#94 + # source://railties//lib/rails/generators/testing/behavior.rb#98 def ensure_current_path; end - # source://railties//lib/rails/generators/testing/behaviour.rb#104 + # source://railties//lib/rails/generators/testing/behavior.rb#108 def migration_file_name(relative); end # Clears all files and directories in destination. # - # source://railties//lib/rails/generators/testing/behaviour.rb#99 + # source://railties//lib/rails/generators/testing/behavior.rb#103 def prepare_destination; end module GeneratedClassMethods @@ -4284,28 +4871,28 @@ module Rails::Generators::Testing::Behaviour end end -# source://railties//lib/rails/generators/testing/behaviour.rb#27 -module Rails::Generators::Testing::Behaviour::ClassMethods +# source://railties//lib/rails/generators/testing/behavior.rb#27 +module Rails::Generators::Testing::Behavior::ClassMethods # Sets default arguments on generator invocation. This can be overwritten when # invoking it. # # arguments %w(app_name --skip-active-record) # - # source://railties//lib/rails/generators/testing/behaviour.rb#39 + # source://railties//lib/rails/generators/testing/behavior.rb#39 def arguments(array); end # Sets the destination of generator files: # # destination File.expand_path("../tmp", __dir__) # - # source://railties//lib/rails/generators/testing/behaviour.rb#46 + # source://railties//lib/rails/generators/testing/behavior.rb#46 def destination(path); end # Sets which generator should be tested: # # tests AppGenerator # - # source://railties//lib/rails/generators/testing/behaviour.rb#31 + # source://railties//lib/rails/generators/testing/behavior.rb#31 def tests(klass); end end @@ -4318,11 +4905,70 @@ module Rails::Generators::Testing::SetupAndTeardown def teardown; end end -# source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#11 -Rails::Html = Rails::HTML +# Built-in Health Check Endpoint +# +# \Rails also comes with a built-in health check endpoint that is reachable at +# the +/up+ path. This endpoint will return a 200 status code if the app has +# booted with no exceptions, and a 500 status code otherwise. +# +# In production, many applications are required to report their status upstream, +# whether it's to an uptime monitor that will page an engineer when things go +# wrong, or a load balancer or Kubernetes controller used to determine a pod's +# health. This health check is designed to be a one-size fits all that will work +# in many situations. +# +# While any newly generated \Rails applications will have the health check at +# +/up+, you can configure the path to be anything you'd like in your +# "config/routes.rb": +# +# Rails.application.routes.draw do +# get "healthz" => "rails/health#show", as: :rails_health_check +# end +# +# The health check will now be accessible via the +/healthz+ path. +# +# NOTE: This endpoint does not reflect the status of all of your application's +# dependencies, such as the database or Redis cluster. Replace +# "rails/health#show" with your own controller action if you have +# application specific needs. +# +# Think carefully about what you want to check as it can lead to situations +# where your application is being restarted due to a third-party service going +# bad. Ideally, you should design your application to handle those outages +# gracefully. +# +# source://railties//lib/rails/health_controller.rb#35 +class Rails::HealthController < ::ActionController::Base + # source://railties//lib/rails/health_controller.rb#38 + def show; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + # source://railties//lib/rails/health_controller.rb#51 + def html_status(color:); end + + # source://railties//lib/rails/health_controller.rb#47 + def render_down; end + + # source://railties//lib/rails/health_controller.rb#43 + def render_up; end + + class << self + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end # This module helps build the runtime properties that are displayed in -# Rails::InfoController responses. These include the active Rails version, +# Rails::InfoController responses. These include the active \Rails version, # Ruby version, Rack version, and so on. # # source://railties//lib/rails/info.rb#9 @@ -4367,29 +5013,26 @@ class Rails::InfoController < ::Rails::ApplicationController private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end # source://railties//lib/rails/info_controller.rb#8 def _layout_from_proc; end # source://railties//lib/rails/info_controller.rb#36 - def match_route; end - - # source://railties//lib/rails/info_controller.rb#40 - def with_leading_slash(path); end + def matching_routes(query:, exact_match:); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions; end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end end end @@ -4484,188 +5127,211 @@ module Rails::LineFiltering def run(reporter, options = T.unsafe(nil)); end end -# source://railties//lib/rails/mailers_controller.rb#5 +# source://railties//lib/rails/mailers_controller.rb#6 class Rails::MailersController < ::Rails::ApplicationController - # source://railties//lib/rails/mailers_controller.rb#16 + # source://railties//lib/rails/mailers_controller.rb#22 + def download; end + + # source://railties//lib/rails/mailers_controller.rb#17 def index; end - # source://railties//lib/rails/mailers_controller.rb#21 + # source://railties//lib/rails/mailers_controller.rb#32 def preview; end private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end - # source://railties//lib/rails/mailers_controller.rb#80 + # source://railties//lib/rails/mailers_controller.rb#107 + def attachment_url(attachment); end + + # source://railties//lib/rails/mailers_controller.rb#101 + def attachments_for(email); end + + # source://railties//lib/rails/mailers_controller.rb#93 def find_part(format); end - # source://railties//lib/rails/mailers_controller.rb#68 + # source://railties//lib/rails/mailers_controller.rb#81 def find_preferred_part(*formats); end - # source://railties//lib/rails/mailers_controller.rb#56 + # source://railties//lib/rails/mailers_controller.rb#69 def find_preview; end - # source://railties//lib/rails/mailers_controller.rb#92 + # source://railties//lib/rails/mailers_controller.rb#115 def locale_query(locale); end - # source://railties//lib/rails/mailers_controller.rb#88 + # source://railties//lib/rails/mailers_controller.rb#111 def part_query(mime_type); end - # source://railties//lib/rails/mailers_controller.rb#96 + # source://railties//lib/rails/mailers_controller.rb#119 def set_locale(&block); end # @return [Boolean] # - # source://railties//lib/rails/mailers_controller.rb#52 + # source://railties//lib/rails/mailers_controller.rb#65 def show_previews?; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end end end # source://railties//lib/rails/mailers_controller.rb#0 module Rails::MailersController::HelperMethods + include ::ActionText::ContentHelper + include ::ActionText::TagHelper + include ::Turbo::DriveHelper + include ::Turbo::FramesHelper + include ::Turbo::IncludesHelper + include ::Turbo::StreamsHelper + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::Turbo::Streams::ActionHelper + include ::Importmap::ImportmapTagsHelper include ::ActionController::Base::HelperMethods - # source://railties//lib/rails/mailers_controller.rb#12 - def locale_query(*args, **_arg1, &block); end + # source://railties//lib/rails/mailers_controller.rb#13 + def attachment_url(*_arg0, **_arg1, &_arg2); end - # source://railties//lib/rails/mailers_controller.rb#12 - def part_query(*args, **_arg1, &block); end + # source://railties//lib/rails/mailers_controller.rb#13 + def locale_query(*_arg0, **_arg1, &_arg2); end + + # source://railties//lib/rails/mailers_controller.rb#13 + def part_query(*_arg0, **_arg1, &_arg2); end end # source://railties//lib/rails/paths.rb#6 module Rails::Paths; end -# source://railties//lib/rails/paths.rb#111 +# source://railties//lib/rails/paths.rb#114 class Rails::Paths::Path include ::Enumerable # @return [Path] a new instance of Path # - # source://railties//lib/rails/paths.rb#116 + # source://railties//lib/rails/paths.rb#119 def initialize(root, current, paths, options = T.unsafe(nil)); end - # source://railties//lib/rails/paths.rb#168 + # source://railties//lib/rails/paths.rb#171 def <<(path); end - # source://railties//lib/rails/paths.rb#129 + # source://railties//lib/rails/paths.rb#132 def absolute_current; end - # source://railties//lib/rails/paths.rb#150 + # source://railties//lib/rails/paths.rb#153 def autoload!; end - # source://railties//lib/rails/paths.rb#158 + # source://railties//lib/rails/paths.rb#161 def autoload?; end - # source://railties//lib/rails/paths.rb#150 + # source://railties//lib/rails/paths.rb#153 def autoload_once!; end - # source://railties//lib/rails/paths.rb#158 + # source://railties//lib/rails/paths.rb#161 def autoload_once?; end - # source://railties//lib/rails/paths.rb#133 + # source://railties//lib/rails/paths.rb#136 def children; end - # source://railties//lib/rails/paths.rb#173 + # source://railties//lib/rails/paths.rb#176 def concat(paths); end - # source://railties//lib/rails/paths.rb#164 + # source://railties//lib/rails/paths.rb#167 def each(&block); end - # source://railties//lib/rails/paths.rb#150 + # source://railties//lib/rails/paths.rb#153 def eager_load!; end - # source://railties//lib/rails/paths.rb#158 + # source://railties//lib/rails/paths.rb#161 def eager_load?; end # Returns all expanded paths but only if they exist in the filesystem. # - # source://railties//lib/rails/paths.rb#217 + # source://railties//lib/rails/paths.rb#220 def existent; end - # source://railties//lib/rails/paths.rb#228 + # source://railties//lib/rails/paths.rb#231 def existent_directories; end # Expands all paths against the root and return all unique values. # - # source://railties//lib/rails/paths.rb#198 + # source://railties//lib/rails/paths.rb#201 def expanded; end - # source://railties//lib/rails/paths.rb#193 + # source://railties//lib/rails/paths.rb#196 def extensions; end - # source://railties//lib/rails/paths.rb#140 + # source://railties//lib/rails/paths.rb#143 def first; end # Returns the value of attribute glob. # - # source://railties//lib/rails/paths.rb#114 + # source://railties//lib/rails/paths.rb#117 def glob; end # Sets the attribute glob # # @param value the value to set the attribute glob to. # - # source://railties//lib/rails/paths.rb#114 + # source://railties//lib/rails/paths.rb#117 def glob=(_arg0); end - # source://railties//lib/rails/paths.rb#144 + # source://railties//lib/rails/paths.rb#147 def last; end - # source://railties//lib/rails/paths.rb#150 + # source://railties//lib/rails/paths.rb#153 def load_path!; end - # source://railties//lib/rails/paths.rb#158 + # source://railties//lib/rails/paths.rb#161 def load_path?; end - # source://railties//lib/rails/paths.rb#185 + # source://railties//lib/rails/paths.rb#188 def paths; end - # source://railties//lib/rails/paths.rb#168 + # source://railties//lib/rails/paths.rb#171 def push(path); end - # source://railties//lib/rails/paths.rb#154 + # source://railties//lib/rails/paths.rb#157 def skip_autoload!; end - # source://railties//lib/rails/paths.rb#154 + # source://railties//lib/rails/paths.rb#157 def skip_autoload_once!; end - # source://railties//lib/rails/paths.rb#154 + # source://railties//lib/rails/paths.rb#157 def skip_eager_load!; end - # source://railties//lib/rails/paths.rb#154 + # source://railties//lib/rails/paths.rb#157 def skip_load_path!; end # Expands all paths against the root and return all unique values. # - # source://railties//lib/rails/paths.rb#198 + # source://railties//lib/rails/paths.rb#201 def to_a; end - # source://railties//lib/rails/paths.rb#181 + # source://railties//lib/rails/paths.rb#184 def to_ary; end - # source://railties//lib/rails/paths.rb#177 + # source://railties//lib/rails/paths.rb#180 def unshift(*paths); end private - # source://railties//lib/rails/paths.rb#235 + # source://railties//lib/rails/paths.rb#238 def files_in(path); end end -# This object is an extended hash that behaves as root of the Rails::Paths system. +# This object is an extended hash that behaves as root of the Rails::Paths system. # It allows you to collect information about how you want to structure your application -# paths through a Hash-like API. It requires you to give a physical path on initialization. +# paths through a Hash-like \API. It requires you to give a physical path on initialization. # # root = Root.new "/rails" # root.add "app/controllers", eager_load: true @@ -4677,7 +5343,8 @@ end # path.eager_load? # => true # path.is_a?(Rails::Paths::Path) # => true # -# The +Path+ object is simply an enumerable and allows you to easily add extra paths: +# The Path[rdoc-ref:Rails::Paths::Path] object is simply an enumerable and +# allows you to easily add extra paths: # # path.is_a?(Enumerable) # => true # path.to_ary.inspect # => ["app/controllers"] @@ -4685,17 +5352,19 @@ end # path << "lib/controllers" # path.to_ary.inspect # => ["app/controllers", "lib/controllers"] # -# Notice that when you add a path using +add+, the path object created already -# contains the path with the same path value given to +add+. In some situations, -# you may not want this behavior, so you can give :with as option. +# Notice that when you add a path using #add, the +# Path[rdoc-ref:Rails::Paths::Path] object created already contains the path +# with the same path value given to #add. In some situations, you may not +# want this behavior, so you can give :with as option. # # root.add "config/routes", with: "config/routes.rb" # root["config/routes"].inspect # => ["config/routes.rb"] # -# The +add+ method accepts the following options as arguments: -# eager_load, autoload, autoload_once, and glob. +# The #add method accepts the following options as arguments: +# +eager_load+, +autoload+, +autoload_once+, and +glob+. # -# Finally, the +Path+ object also provides a few helpers: +# Finally, the Path[rdoc-ref:Rails::Paths::Path] object also provides a few +# helpers: # # root = Root.new "/rails" # root.add "app/controllers" @@ -4703,66 +5372,88 @@ end # root["app/controllers"].expanded # => ["/rails/app/controllers"] # root["app/controllers"].existent # => ["/rails/app/controllers"] # -# Check the Rails::Paths::Path documentation for more information. +# Check the Rails::Paths::Path documentation for more information. # -# source://railties//lib/rails/paths.rb#48 +# source://railties//lib/rails/paths.rb#51 class Rails::Paths::Root # @return [Root] a new instance of Root # - # source://railties//lib/rails/paths.rb#51 + # source://railties//lib/rails/paths.rb#54 def initialize(path); end - # source://railties//lib/rails/paths.rb#66 + # source://railties//lib/rails/paths.rb#69 def [](path); end - # source://railties//lib/rails/paths.rb#56 + # source://railties//lib/rails/paths.rb#59 def []=(path, value); end - # source://railties//lib/rails/paths.rb#61 + # source://railties//lib/rails/paths.rb#64 def add(path, options = T.unsafe(nil)); end - # source://railties//lib/rails/paths.rb#82 + # source://railties//lib/rails/paths.rb#85 def all_paths; end - # source://railties//lib/rails/paths.rb#86 + # source://railties//lib/rails/paths.rb#89 def autoload_once; end - # source://railties//lib/rails/paths.rb#94 + # source://railties//lib/rails/paths.rb#97 def autoload_paths; end - # source://railties//lib/rails/paths.rb#90 + # source://railties//lib/rails/paths.rb#93 def eager_load; end - # source://railties//lib/rails/paths.rb#74 + # source://railties//lib/rails/paths.rb#77 def keys; end - # source://railties//lib/rails/paths.rb#98 + # source://railties//lib/rails/paths.rb#101 def load_paths; end # Returns the value of attribute path. # - # source://railties//lib/rails/paths.rb#49 + # source://railties//lib/rails/paths.rb#52 def path; end # Sets the attribute path # # @param value the value to set the attribute path to. # - # source://railties//lib/rails/paths.rb#49 + # source://railties//lib/rails/paths.rb#52 def path=(_arg0); end - # source://railties//lib/rails/paths.rb#70 + # source://railties//lib/rails/paths.rb#73 def values; end - # source://railties//lib/rails/paths.rb#78 + # source://railties//lib/rails/paths.rb#81 def values_at(*list); end private - # source://railties//lib/rails/paths.rb#103 + # source://railties//lib/rails/paths.rb#106 def filter_by(&block); end end +# source://railties//lib/rails/pwa_controller.rb#5 +class Rails::PwaController < ::Rails::ApplicationController + # source://railties//lib/rails/pwa_controller.rb#12 + def manifest; end + + # source://railties//lib/rails/pwa_controller.rb#8 + def service_worker; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + # source://railties//lib/rails/rack.rb#4 module Rails::Rack; end @@ -4772,61 +5463,64 @@ module Rails::Rack; end # object responds to, objects that respond to +to_s+ or Proc objects that accept # an instance of the +request+ object. # -# source://railties//lib/rails/rack/logger.rb#15 +# source://railties//lib/rails/rack/logger.rb#14 class Rails::Rack::Logger < ::ActiveSupport::LogSubscriber # @return [Logger] a new instance of Logger # - # source://railties//lib/rails/rack/logger.rb#16 + # source://railties//lib/rails/rack/logger.rb#15 def initialize(app, taggers = T.unsafe(nil)); end - # source://railties//lib/rails/rack/logger.rb#21 + # source://railties//lib/rails/rack/logger.rb#20 def call(env); end private - # source://railties//lib/rails/rack/logger.rb#32 + # source://railties//lib/rails/rack/logger.rb#33 def call_app(request, env); end - # source://railties//lib/rails/rack/logger.rb#59 + # source://railties//lib/rails/rack/logger.rb#64 def compute_tags(request); end - # source://railties//lib/rails/rack/logger.rb#72 + # source://railties//lib/rails/rack/logger.rb#81 + def finish_request_instrumentation(handle, logger_tag_pop_count); end + + # source://railties//lib/rails/rack/logger.rb#77 def logger; end # Started GET "/session/new" for 127.0.0.1 at 2012-09-26 14:51:42 -0700 # - # source://railties//lib/rails/rack/logger.rb#51 + # source://railties//lib/rails/rack/logger.rb#56 def started_request_message(request); end end -# Rails::Railtie is the core of the Rails framework and provides -# several hooks to extend Rails and/or modify the initialization process. +# +Rails::Railtie+ is the core of the \Rails framework and provides +# several hooks to extend \Rails and/or modify the initialization process. # -# Every major component of Rails (Action Mailer, Action Controller, Active +# Every major component of \Rails (Action Mailer, Action Controller, Active # Record, etc.) implements a railtie. Each of them is responsible for their -# own initialization. This makes Rails itself absent of any component hooks, -# allowing other components to be used in place of any of the Rails defaults. +# own initialization. This makes \Rails itself absent of any component hooks, +# allowing other components to be used in place of any of the \Rails defaults. # -# Developing a Rails extension does _not_ require implementing a railtie, but -# if you need to interact with the Rails framework during or after boot, then +# Developing a \Rails extension does _not_ require implementing a railtie, but +# if you need to interact with the \Rails framework during or after boot, then # a railtie is needed. # # For example, an extension doing any of the following would need a railtie: # # * creating initializers -# * configuring a Rails framework for the application, like setting a generator +# * configuring a \Rails framework for the application, like setting a generator # * adding config.* keys to the environment # * setting up a subscriber with ActiveSupport::Notifications # * adding Rake tasks # # == Creating a Railtie # -# To extend Rails using a railtie, create a subclass of Rails::Railtie. -# This class must be loaded during the Rails boot process, and is conventionally -# called MyNamespace::Railtie. +# To extend \Rails using a railtie, create a subclass of +Rails::Railtie+. +# This class must be loaded during the \Rails boot process, and is conventionally +# called +MyNamespace::Railtie+. # # The following example demonstrates an extension which can be used with or -# without Rails. +# without \Rails. # # # lib/my_gem/railtie.rb # module MyGem @@ -4839,7 +5533,7 @@ end # # == Initializers # -# To add an initialization step to the Rails boot process from your railtie, just +# To add an initialization step to the \Rails boot process from your railtie, just # define the initialization code with the +initializer+ macro: # # class MyRailtie < Rails::Railtie @@ -4879,7 +5573,7 @@ end # # == Loading Rake Tasks and Generators # -# If your railtie has Rake tasks, you can tell Rails to load them through the method +# If your railtie has Rake tasks, you can tell \Rails to load them through the method # +rake_tasks+: # # class MyRailtie < Rails::Railtie @@ -4888,7 +5582,7 @@ end # end # end # -# By default, Rails loads generators from your load path. However, if you want to place +# By default, \Rails loads generators from your load path. However, if you want to place # your generators at a different location, you can specify in your railtie a block which # will load them during normal generators lookup: # @@ -4901,13 +5595,13 @@ end # Since filenames on the load path are shared across gems, be sure that files you load # through a railtie have unique names. # -# == Run another program when the Rails server starts +# == Run another program when the \Rails server starts # -# In development, it's very usual to have to run another process next to the Rails Server. In example +# In development, it's very usual to have to run another process next to the \Rails Server. In example # you might want to start the Webpack or React server. Or maybe you need to run your job scheduler process # like Sidekiq. This is usually done by opening a new shell and running the program from here. # -# Rails allow you to specify a +server+ block which will get called when a Rails server starts. +# \Rails allow you to specify a +server+ block which will get called when a \Rails server starts. # This way, your users don't need to remember to have to open a new shell and run another program, making # this less confusing for everyone. # It can be used like this: @@ -4934,50 +5628,50 @@ class Rails::Railtie # @return [Railtie] a new instance of Railtie # - # source://railties//lib/rails/railtie.rb#246 + # source://railties//lib/rails/railtie.rb#245 def initialize; end # This is used to create the config object on Railties, an instance of # Railtie::Configuration, that is used by Railties and Application to store # related configuration. # - # source://railties//lib/rails/railtie.rb#263 + # source://railties//lib/rails/railtie.rb#262 def config; end - # source://railties//lib/rails/railtie.rb#256 + # source://railties//lib/rails/railtie.rb#255 def configure(&block); end - # source://railties//lib/rails/railtie.rb#252 + # source://railties//lib/rails/railtie.rb#251 def inspect; end - # source://railties//lib/rails/railtie.rb#244 + # source://railties//lib/rails/railtie.rb#243 def railtie_name(*_arg0, **_arg1, &_arg2); end - # source://railties//lib/rails/railtie.rb#267 + # source://railties//lib/rails/railtie.rb#266 def railtie_namespace; end protected - # source://railties//lib/rails/railtie.rb#272 + # source://railties//lib/rails/railtie.rb#271 def run_console_blocks(app); end - # source://railties//lib/rails/railtie.rb#276 + # source://railties//lib/rails/railtie.rb#275 def run_generators_blocks(app); end - # source://railties//lib/rails/railtie.rb#280 + # source://railties//lib/rails/railtie.rb#279 def run_runner_blocks(app); end - # source://railties//lib/rails/railtie.rb#289 + # source://railties//lib/rails/railtie.rb#288 def run_server_blocks(app); end - # source://railties//lib/rails/railtie.rb#284 + # source://railties//lib/rails/railtie.rb#283 def run_tasks_blocks(app); end private # run `&block` in every registered block in `#register_block_for` # - # source://railties//lib/rails/railtie.rb#295 + # source://railties//lib/rails/railtie.rb#294 def each_registered_block(type, &block); end class << self @@ -5050,7 +5744,7 @@ class Rails::Railtie # to the Railtie instance. # # source://railties//lib/rails/railtie.rb#224 - def method_missing(name, *args, **_arg2, &block); end + def method_missing(name, *_arg1, **_arg2, &_arg3); end def new(*_arg0); end @@ -5058,7 +5752,7 @@ class Rails::Railtie # blank and append given block to value, which will be used later in # `#each_registered_block(type, &block)` # - # source://railties//lib/rails/railtie.rb#236 + # source://railties//lib/rails/railtie.rb#235 def register_block_for(type, &blk); end # @return [Boolean] @@ -5083,6 +5777,11 @@ class Rails::Railtie::Configuration # source://railties//lib/rails/railtie/configuration.rb#70 def after_initialize(&block); end + # Called after application routes have been loaded. + # + # source://railties//lib/rails/railtie/configuration.rb#75 + def after_routes_loaded(&block); end + # This allows you to modify application's generators from Railties. # # Values set on app_generators will become defaults for application, unless @@ -5125,18 +5824,18 @@ class Rails::Railtie::Configuration # @return [Boolean] # - # source://railties//lib/rails/railtie/configuration.rb#85 + # source://railties//lib/rails/railtie/configuration.rb#90 def respond_to?(name, include_private = T.unsafe(nil)); end # Defines generic callbacks to run before #after_initialize. Useful for # Rails::Railtie subclasses. # - # source://railties//lib/rails/railtie/configuration.rb#81 + # source://railties//lib/rails/railtie/configuration.rb#86 def to_prepare(&blk); end # Array of callbacks defined by #to_prepare. # - # source://railties//lib/rails/railtie/configuration.rb#75 + # source://railties//lib/rails/railtie/configuration.rb#80 def to_prepare_blocks; end # Add directories that should be watched for change. @@ -5153,7 +5852,12 @@ class Rails::Railtie::Configuration private - # source://railties//lib/rails/railtie/configuration.rb#90 + # @return [Boolean] + # + # source://railties//lib/rails/railtie/configuration.rb#95 + def actual_method?(key); end + + # source://railties//lib/rails/railtie/configuration.rb#99 def method_missing(name, *args, &blk); end class << self @@ -5164,75 +5868,7 @@ class Rails::Railtie::Configuration end end -# Greatly inspired by Ara T. Howard's magnificent sekrets gem. 😘 -# -# source://railties//lib/rails/secrets.rb#8 -class Rails::Secrets - class << self - # source://railties//lib/rails/secrets.rb#45 - def decrypt(data); end - - # source://railties//lib/rails/secrets.rb#41 - def encrypt(data); end - - # source://railties//lib/rails/secrets.rb#37 - def key; end - - # source://railties//lib/rails/secrets.rb#24 - def parse(paths, env:); end - - # source://railties//lib/rails/secrets.rb#49 - def read; end - - # source://railties//lib/rails/secrets.rb#58 - def read_for_editing(&block); end - - # Sets the attribute root - # - # @param value the value to set the attribute root to. - # - # source://railties//lib/rails/secrets.rb#22 - def root=(_arg0); end - - # source://railties//lib/rails/secrets.rb#53 - def write(contents); end - - private - - # source://railties//lib/rails/secrets.rb#103 - def encryptor; end - - # @raise [MissingKeyError] - # - # source://railties//lib/rails/secrets.rb#63 - def handle_missing_key; end - - # source://railties//lib/rails/secrets.rb#73 - def key_path; end - - # source://railties//lib/rails/secrets.rb#77 - def path; end - - # source://railties//lib/rails/secrets.rb#81 - def preprocess(path); end - - # source://railties//lib/rails/secrets.rb#67 - def read_key_file; end - - # source://railties//lib/rails/secrets.rb#89 - def writing(contents); end - end -end - -# source://railties//lib/rails/secrets.rb#9 -class Rails::Secrets::MissingKeyError < ::RuntimeError - # @return [MissingKeyError] a new instance of MissingKeyError - # - # source://railties//lib/rails/secrets.rb#10 - def initialize; end -end - -# Implements the logic behind Rails::Command::NotesCommand. See rails notes --help for usage information. +# Implements the logic behind +Rails::Command::NotesCommand+. See rails notes --help for usage information. # # Annotation objects are triplets :line, :tag, :text that # represent the line where the annotation lives, its tag, and its text. Note @@ -5242,30 +5878,23 @@ end # start with the tag optionally followed by a colon. Everything up to the end # of the line (or closing ERB comment tag) is considered to be their text. # -# source://railties//lib/rails/source_annotation_extractor.rb#13 +# source://railties//lib/rails/source_annotation_extractor.rb#15 class Rails::SourceAnnotationExtractor # @return [SourceAnnotationExtractor] a new instance of SourceAnnotationExtractor # - # source://railties//lib/rails/source_annotation_extractor.rb#85 + # source://railties//lib/rails/source_annotation_extractor.rb#137 def initialize(tag); end # Prints the mapping from filenames to annotations in +results+ ordered by filename. # The +options+ hash is passed to each annotation's +to_s+. # - # source://railties//lib/rails/source_annotation_extractor.rb#137 + # source://railties//lib/rails/source_annotation_extractor.rb#186 def display(results, options = T.unsafe(nil)); end - # If +file+ is the filename of a file that contains annotations this method returns - # a hash with a single entry that maps +file+ to an array of its annotations. - # Otherwise it returns an empty hash. - # - # source://railties//lib/rails/source_annotation_extractor.rb#125 - def extract_annotations_from(file, pattern); end - # Returns a hash that maps filenames under +dirs+ (recursively) to arrays # with their annotations. # - # source://railties//lib/rails/source_annotation_extractor.rb#91 + # source://railties//lib/rails/source_annotation_extractor.rb#143 def find(dirs); end # Returns a hash that maps filenames under +dir+ (recursively) to arrays @@ -5273,12 +5902,12 @@ class Rails::SourceAnnotationExtractor # Rails::SourceAnnotationExtractor::Annotation.extensions are # taken into account. Only files with annotations are included. # - # source://railties//lib/rails/source_annotation_extractor.rb#99 + # source://railties//lib/rails/source_annotation_extractor.rb#151 def find_in(dir); end # Returns the value of attribute tag. # - # source://railties//lib/rails/source_annotation_extractor.rb#83 + # source://railties//lib/rails/source_annotation_extractor.rb#135 def tag; end class << self @@ -5297,12 +5926,12 @@ class Rails::SourceAnnotationExtractor # # This class method is the single entry point for the rails notes command. # - # source://railties//lib/rails/source_annotation_extractor.rb#76 + # source://railties//lib/rails/source_annotation_extractor.rb#128 def enumerate(tag = T.unsafe(nil), options = T.unsafe(nil)); end end end -# source://railties//lib/rails/source_annotation_extractor.rb#14 +# source://railties//lib/rails/source_annotation_extractor.rb#54 class Rails::SourceAnnotationExtractor::Annotation < ::Struct # Returns a representation of the annotation that looks like this: # @@ -5311,137 +5940,207 @@ class Rails::SourceAnnotationExtractor::Annotation < ::Struct # If +options+ has a flag :tag the tag is shown as in the example above. # Otherwise the string contains just line and text. # - # source://railties//lib/rails/source_annotation_extractor.rb#55 + # source://railties//lib/rails/source_annotation_extractor.rb#107 def to_s(options = T.unsafe(nil)); end class << self - # source://railties//lib/rails/source_annotation_extractor.rb#15 + # source://railties//lib/rails/source_annotation_extractor.rb#55 def directories; end - # source://railties//lib/rails/source_annotation_extractor.rb#35 + # source://railties//lib/rails/source_annotation_extractor.rb#75 def extensions; end # Registers additional directories to be included # Rails::SourceAnnotationExtractor::Annotation.register_directories("spec", "another") # - # source://railties//lib/rails/source_annotation_extractor.rb#21 + # source://railties//lib/rails/source_annotation_extractor.rb#61 def register_directories(*dirs); end # Registers new Annotations File Extensions # Rails::SourceAnnotationExtractor::Annotation.register_extensions("css", "scss", "sass", "less", "js") { |tag| /\/\/\s*(#{tag}):?\s*(.*)$/ } # - # source://railties//lib/rails/source_annotation_extractor.rb#41 + # source://railties//lib/rails/source_annotation_extractor.rb#81 def register_extensions(*exts, &block); end # Registers additional tags # Rails::SourceAnnotationExtractor::Annotation.register_tags("TESTME", "DEPRECATEME") # - # source://railties//lib/rails/source_annotation_extractor.rb#31 + # source://railties//lib/rails/source_annotation_extractor.rb#71 def register_tags(*additional_tags); end - # source://railties//lib/rails/source_annotation_extractor.rb#25 + # source://railties//lib/rails/source_annotation_extractor.rb#65 def tags; end end end -# source://railties//lib/rails/test_unit/runner.rb#10 +# Wraps a regular expression that will be tested against each of the source +# file's comments. +# +# source://railties//lib/rails/source_annotation_extractor.rb#18 +class Rails::SourceAnnotationExtractor::ParserExtractor < ::Struct + # source://railties//lib/rails/source_annotation_extractor.rb#33 + def annotations(file); end +end + +# source://railties//lib/rails/source_annotation_extractor.rb#19 +class Rails::SourceAnnotationExtractor::ParserExtractor::Parser < ::Ripper + # @return [Parser] a new instance of Parser + # + # source://railties//lib/rails/source_annotation_extractor.rb#22 + def initialize(source, pattern:); end + + # Returns the value of attribute comments. + # + # source://railties//lib/rails/source_annotation_extractor.rb#20 + def comments; end + + # source://railties//lib/rails/source_annotation_extractor.rb#28 + def on_comment(value); end + + # Returns the value of attribute pattern. + # + # source://railties//lib/rails/source_annotation_extractor.rb#20 + def pattern; end +end + +# Wraps a regular expression that will iterate through a file's lines and +# test each one for the given pattern. +# +# source://railties//lib/rails/source_annotation_extractor.rb#42 +class Rails::SourceAnnotationExtractor::PatternExtractor < ::Struct + # source://railties//lib/rails/source_annotation_extractor.rb#43 + def annotations(file); end +end + +# source://railties//lib/rails/test_unit/test_parser.rb#12 module Rails::TestUnit; end -# source://railties//lib/rails/test_unit/runner.rb#105 +# source://railties//lib/rails/test_unit/runner.rb#146 class Rails::TestUnit::CompositeFilter # @return [CompositeFilter] a new instance of CompositeFilter # - # source://railties//lib/rails/test_unit/runner.rb#108 + # source://railties//lib/rails/test_unit/runner.rb#149 def initialize(runnable, filter, patterns); end # minitest uses === to find matching filters. # - # source://railties//lib/rails/test_unit/runner.rb#115 + # source://railties//lib/rails/test_unit/runner.rb#156 def ===(method); end # Returns the value of attribute named_filter. # - # source://railties//lib/rails/test_unit/runner.rb#106 + # source://railties//lib/rails/test_unit/runner.rb#147 def named_filter; end private - # source://railties//lib/rails/test_unit/runner.rb#130 + # source://railties//lib/rails/test_unit/runner.rb#171 def derive_line_filters(patterns); end - # source://railties//lib/rails/test_unit/runner.rb#120 + # source://railties//lib/rails/test_unit/runner.rb#161 def derive_named_filter(filter); end end -# source://railties//lib/rails/test_unit/runner.rb#141 +# source://railties//lib/rails/test_unit/runner.rb#182 class Rails::TestUnit::Filter # @return [Filter] a new instance of Filter # - # source://railties//lib/rails/test_unit/runner.rb#142 - def initialize(runnable, file, line); end + # source://railties//lib/rails/test_unit/runner.rb#183 + def initialize(runnable, file, line_or_range); end - # source://railties//lib/rails/test_unit/runner.rb#147 + # source://railties//lib/rails/test_unit/runner.rb#192 def ===(method); end private - # source://railties//lib/rails/test_unit/runner.rb#159 + # source://railties//lib/rails/test_unit/runner.rb#204 def definition_for(method); end end -# source://railties//lib/rails/test_unit/runner.rb#11 +# source://railties//lib/rails/test_unit/runner.rb#12 +class Rails::TestUnit::InvalidTestError < ::StandardError + # @return [InvalidTestError] a new instance of InvalidTestError + # + # source://railties//lib/rails/test_unit/runner.rb#13 + def initialize(path, suggestion); end +end + +# source://railties//lib/rails/test_unit/runner.rb#21 class Rails::TestUnit::Runner - # source://railties//lib/rails/test_unit/runner.rb#12 + # source://railties//lib/rails/test_unit/runner.rb#24 def filters; end class << self - # source://railties//lib/rails/test_unit/runner.rb#15 + # source://railties//lib/rails/test_unit/runner.rb#27 def attach_before_load_options(opts); end - # source://railties//lib/rails/test_unit/runner.rb#50 + # source://railties//lib/rails/test_unit/runner.rb#78 def compose_filter(runnable, filter); end - # source://railties//lib/rails/test_unit/runner.rb#12 + # source://railties//lib/rails/test_unit/runner.rb#24 def filters; end - # source://railties//lib/rails/test_unit/runner.rb#45 + # source://railties//lib/rails/test_unit/runner.rb#57 def load_tests(argv); end - # source://railties//lib/rails/test_unit/runner.rb#20 + # source://railties//lib/rails/test_unit/runner.rb#32 def parse_options(argv); end - # source://railties//lib/rails/test_unit/runner.rb#33 - def rake_run(argv = T.unsafe(nil)); end - - # source://railties//lib/rails/test_unit/runner.rb#39 + # source://railties//lib/rails/test_unit/runner.rb#51 def run(argv = T.unsafe(nil)); end + # source://railties//lib/rails/test_unit/runner.rb#45 + def run_from_rake(test_command, argv = T.unsafe(nil)); end + private - # source://railties//lib/rails/test_unit/runner.rb#83 + # source://railties//lib/rails/test_unit/runner.rb#113 def default_test_exclude_glob; end - # source://railties//lib/rails/test_unit/runner.rb#79 + # source://railties//lib/rails/test_unit/runner.rb#109 def default_test_glob; end - # source://railties//lib/rails/test_unit/runner.rb#59 + # source://railties//lib/rails/test_unit/runner.rb#89 def extract_filters(argv); end - # source://railties//lib/rails/test_unit/runner.rb#95 - def list_tests(argv); end + # source://railties//lib/rails/test_unit/runner.rb#125 + def list_tests(patterns); end + + # source://railties//lib/rails/test_unit/runner.rb#131 + def normalize_declarative_test_filter(filter); end # @return [Boolean] # - # source://railties//lib/rails/test_unit/runner.rb#91 + # source://railties//lib/rails/test_unit/runner.rb#121 def path_argument?(arg); end # @return [Boolean] # - # source://railties//lib/rails/test_unit/runner.rb#87 + # source://railties//lib/rails/test_unit/runner.rb#117 def regexp_filter?(arg); end end end +# source://railties//lib/rails/test_unit/runner.rb#23 +Rails::TestUnit::Runner::PATH_ARGUMENT_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://railties//lib/rails/test_unit/runner.rb#22 +Rails::TestUnit::Runner::TEST_FOLDERS = T.let(T.unsafe(nil), Array) + +# Parse a test file to extract the line ranges of all tests in both +# method-style (def test_foo) and declarative-style (test "foo" do) +# +# source://railties//lib/rails/test_unit/test_parser.rb#15 +module Rails::TestUnit::TestParser + class << self + # Helper to translate a method object into the path and line range where + # the method was defined. + # + # source://railties//lib/rails/test_unit/test_parser.rb#18 + def definition_for(method); end + end +end + # source://railties//lib/rails/test_unit/railtie.rb#6 class Rails::TestUnitRailtie < ::Rails::Railtie; end @@ -5470,20 +6169,20 @@ class Rails::WelcomeController < ::Rails::ApplicationController private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions; end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end end end diff --git a/sorbet/rbi/gems/rainbow@3.1.1.rbi b/sorbet/rbi/gems/rainbow@3.1.1.rbi index 14cbb1213..d02bc0487 100644 --- a/sorbet/rbi/gems/rainbow@3.1.1.rbi +++ b/sorbet/rbi/gems/rainbow@3.1.1.rbi @@ -4,17 +4,6 @@ # This is an autogenerated file for types exported from the `rainbow` gem. # Please instead update this file by running `bin/tapioca gem rainbow`. -# source://american_date/1.2.0/lib/american_date.rb#16 -::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) - -# source://ruby-openid/2.9.2/lib/openid/fetchers.rb#13 -::MAX_RESPONSE_KB = T.let(T.unsafe(nil), Integer) - -# source://yard/0.9.34/lib/yard.rb#61 -::RUBY18 = T.let(T.unsafe(nil), FalseClass) - -# source://yard/0.9.34/lib/yard.rb#62 -::RUBY19 = T.let(T.unsafe(nil), TrueClass) class Object < ::BasicObject include ::Kernel diff --git a/sorbet/rbi/gems/rake@13.0.6.rbi b/sorbet/rbi/gems/rake@13.2.1.rbi similarity index 95% rename from sorbet/rbi/gems/rake@13.0.6.rbi rename to sorbet/rbi/gems/rake@13.2.1.rbi index b0a908d94..90ae1309c 100644 --- a/sorbet/rbi/gems/rake@13.0.6.rbi +++ b/sorbet/rbi/gems/rake@13.2.1.rbi @@ -4,11 +4,12 @@ # This is an autogenerated file for types exported from the `rake` gem. # Please instead update this file by running `bin/tapioca gem rake`. + # :stopdoc: # # Some top level Constants. # -# source://rake//lib/rake.rb#70 +# source://rake//lib/rake.rb#69 FileList = Rake::FileList # -- @@ -22,13 +23,13 @@ module FileUtils # Example: # ruby %{-pe '$_.upcase!' ['a', 'b', 'c'] # - # source://rake//lib/rake/file_utils.rb#128 + # source://rake//lib/rake/file_utils.rb#126 def split_all(path); end private @@ -75,14 +76,14 @@ module FileUtils # source://rake//lib/rake/file_utils.rb#61 def create_shell_runner(cmd); end - # source://rake//lib/rake/file_utils.rb#86 + # source://rake//lib/rake/file_utils.rb#84 def set_verbose_option(options); end - # source://rake//lib/rake/file_utils.rb#73 + # source://rake//lib/rake/file_utils.rb#71 def sh_show_command(cmd); end end -# source://rake//lib/rake/file_utils.rb#108 +# source://rake//lib/rake/file_utils.rb#106 FileUtils::LN_SUPPORTED = T.let(T.unsafe(nil), Array) # Path to the currently running Ruby program @@ -111,15 +112,6 @@ class Module def rake_extension(method); end end -# source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#13 -Module::DELEGATION_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) - -# source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#14 -Module::DELEGATION_RESERVED_METHOD_NAMES = T.let(T.unsafe(nil), Set) - -# source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#10 -Module::RUBY_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) - # source://rake//lib/rake/cloneable.rb#2 module Rake extend ::FileUtils::StreamUtils_ @@ -204,13 +196,13 @@ class Rake::Application # Add a file to the list of files to be imported. # - # source://rake//lib/rake/application.rb#777 + # source://rake//lib/rake/application.rb#807 def add_import(fn); end # Add a loader to handle imported files ending in the extension # +ext+. # - # source://rake//lib/rake/application.rb#139 + # source://rake//lib/rake/application.rb#161 def add_loader(ext, loader); end # Collect the list of tasks on the command line. If no tasks are @@ -222,13 +214,13 @@ class Rake::Application # recognised command-line options, which OptionParser.parse will # have taken care of already. # - # source://rake//lib/rake/application.rb#758 + # source://rake//lib/rake/application.rb#788 def collect_command_line_tasks(args); end # Default task name ("default"). # (May be overridden by subclasses) # - # source://rake//lib/rake/application.rb#772 + # source://rake//lib/rake/application.rb#802 def default_task_name; end # Warn about deprecated usage. @@ -236,75 +228,75 @@ class Rake::Application # Example: # Rake.application.deprecate("import", "Rake.import", caller.first) # - # source://rake//lib/rake/application.rb#258 + # source://rake//lib/rake/application.rb#288 def deprecate(old_usage, new_usage, call_site); end - # source://rake//lib/rake/application.rb#222 + # source://rake//lib/rake/application.rb#250 def display_cause_details(ex); end # Display the error message that caused the exception. # - # source://sentry-raven/3.1.2/lib/raven/integrations/rake.rb#8 + # source://sentry-ruby/5.19.0/lib/sentry/rake.rb#10 def display_error_message(ex); end - # source://rake//lib/rake/application.rb#245 + # source://rake//lib/rake/application.rb#275 def display_exception_backtrace(ex); end - # source://rake//lib/rake/application.rb#214 + # source://rake//lib/rake/application.rb#242 def display_exception_details(ex); end - # source://rake//lib/rake/application.rb#229 + # source://rake//lib/rake/application.rb#257 def display_exception_details_seen; end - # source://rake//lib/rake/application.rb#237 + # source://rake//lib/rake/application.rb#265 def display_exception_message_details(ex); end # Display the tasks and prerequisites # - # source://rake//lib/rake/application.rb#381 + # source://rake//lib/rake/application.rb#411 def display_prerequisites; end # Display the tasks and comments. # - # source://rake//lib/rake/application.rb#298 + # source://rake//lib/rake/application.rb#328 def display_tasks_and_comments; end # Calculate the dynamic width of the # - # source://rake//lib/rake/application.rb#349 + # source://rake//lib/rake/application.rb#379 def dynamic_width; end - # source://rake//lib/rake/application.rb#353 + # source://rake//lib/rake/application.rb#383 def dynamic_width_stty; end - # source://rake//lib/rake/application.rb#357 + # source://rake//lib/rake/application.rb#387 def dynamic_width_tput; end # Exit the program because of an unhandled exception. # (may be overridden by subclasses) # - # source://rake//lib/rake/application.rb#201 + # source://rake//lib/rake/application.rb#229 def exit_because_of_exception(ex); end - # source://rake//lib/rake/application.rb#678 + # source://rake//lib/rake/application.rb#708 def find_rakefile_location; end # Read and handle the command line options. Returns the command line # arguments that we didn't understand, which should (in theory) be just # task names and env vars. # - # source://rake//lib/rake/application.rb#644 + # source://rake//lib/rake/application.rb#674 def handle_options(argv); end # @return [Boolean] # - # source://rake//lib/rake/application.rb#233 + # source://rake//lib/rake/application.rb#261 def has_cause?(ex); end # True if one of the files in RAKEFILES is in the current directory. # If a match is found, it is copied into @rakefile. # - # source://rake//lib/rake/application.rb#274 + # source://rake//lib/rake/application.rb#304 def have_rakefile; end # Initialize the command line parameters and app name. @@ -314,17 +306,17 @@ class Rake::Application # Invokes a task with arguments that are extracted from +task_string+ # - # source://rake//lib/rake/application.rb#157 + # source://rake//lib/rake/application.rb#185 def invoke_task(task_string); end # Load the pending list of imported files. # - # source://rake//lib/rake/application.rb#782 + # source://rake//lib/rake/application.rb#812 def load_imports; end # Find the rakefile and then load it and any pending imports. # - # source://rake//lib/rake/application.rb#102 + # source://rake//lib/rake/application.rb#124 def load_rakefile; end # The name of the application (typically 'rake') @@ -334,27 +326,24 @@ class Rake::Application # Application options from the command line # - # source://rake//lib/rake/application.rb#145 + # source://rake//lib/rake/application.rb#167 def options; end - # source://rake//lib/rake/application.rb#206 - def orig_display_error_messsage(ex); end - # The original directory where rake was invoked. # # source://rake//lib/rake/application.rb#27 def original_dir; end - # source://rake//lib/rake/application.rb#163 + # source://rake//lib/rake/application.rb#191 def parse_task_string(string); end - # source://rake//lib/rake/application.rb#690 + # source://rake//lib/rake/application.rb#720 def print_rakefile_directory(location); end # Similar to the regular Ruby +require+ command, but will check # for *.rake files in addition to *.rb files. # - # source://rake//lib/rake/application.rb#664 + # source://rake//lib/rake/application.rb#694 def rake_require(file_name, paths = T.unsafe(nil), loaded = T.unsafe(nil)); end # Name of the actual rakefile used. @@ -362,10 +351,10 @@ class Rake::Application # source://rake//lib/rake/application.rb#30 def rakefile; end - # source://rake//lib/rake/application.rb#798 + # source://rake//lib/rake/application.rb#828 def rakefile_location(backtrace = T.unsafe(nil)); end - # source://rake//lib/rake/application.rb#695 + # source://rake//lib/rake/application.rb#725 def raw_load_rakefile; end # Run the Rake application. The run method performs the following @@ -384,26 +373,26 @@ class Rake::Application # Run the given block with the thread startup and shutdown. # - # source://rake//lib/rake/application.rb#122 + # source://rake//lib/rake/application.rb#144 def run_with_threads; end - # source://rake//lib/rake/application.rb#807 + # source://rake//lib/rake/application.rb#837 def set_default_options; end # Provide standard exception handling for the given block. # - # source://rake//lib/rake/application.rb#185 + # source://rake//lib/rake/application.rb#213 def standard_exception_handling; end # A list of all the standard options used in rake, suitable for # passing to OptionParser. # - # source://rake//lib/rake/application.rb#402 + # source://rake//lib/rake/application.rb#432 def standard_rake_options; end # The directory path containing the system wide rakefiles. # - # source://rake//lib/rake/application.rb#727 + # source://rake//lib/rake/application.rb#757 def system_dir; end # Number of columns on the terminal @@ -416,17 +405,17 @@ class Rake::Application # source://rake//lib/rake/application.rb#33 def terminal_columns=(_arg0); end - # source://rake//lib/rake/application.rb#337 + # source://rake//lib/rake/application.rb#367 def terminal_width; end # Return the thread pool used for multithreaded processing. # - # source://rake//lib/rake/application.rb#150 + # source://rake//lib/rake/application.rb#178 def thread_pool; end # Run the top level tasks of a Rake application. # - # source://rake//lib/rake/application.rb#109 + # source://rake//lib/rake/application.rb#131 def top_level; end # List of the top level task names (task names from the command line). @@ -434,10 +423,10 @@ class Rake::Application # source://rake//lib/rake/application.rb#36 def top_level_tasks; end - # source://rake//lib/rake/application.rb#388 + # source://rake//lib/rake/application.rb#418 def trace(*strings); end - # source://rake//lib/rake/application.rb#370 + # source://rake//lib/rake/application.rb#400 def truncate(string, width); end # We will truncate output if we are outputting to a TTY or if we've been @@ -445,7 +434,7 @@ class Rake::Application # # @return [Boolean] # - # source://rake//lib/rake/application.rb#293 + # source://rake//lib/rake/application.rb#323 def truncate_output?; end # Override the detected TTY output state (mostly for testing) @@ -457,41 +446,44 @@ class Rake::Application # # @return [Boolean] # - # source://rake//lib/rake/application.rb#287 + # source://rake//lib/rake/application.rb#317 def tty_output?; end # @return [Boolean] # - # source://rake//lib/rake/application.rb#361 + # source://rake//lib/rake/application.rb#391 def unix?; end # @return [Boolean] # - # source://rake//lib/rake/application.rb#366 + # source://rake//lib/rake/application.rb#396 def windows?; end private - # source://rake//lib/rake/application.rb#721 + # source://rake//lib/rake/application.rb#751 def glob(path, &block); end # Does the exception have a task invocation chain? # # @return [Boolean] # - # source://rake//lib/rake/application.rb#267 + # source://rake//lib/rake/application.rb#297 def has_chain?(exception); end - # source://rake//lib/rake/application.rb#620 + # source://rake//lib/rake/application.rb#102 + def load_debug_at_stop_feature; end + + # source://rake//lib/rake/application.rb#650 def select_tasks_to_show(options, show_tasks, value); end - # source://rake//lib/rake/application.rb#627 + # source://rake//lib/rake/application.rb#657 def select_trace_output(options, trace_option, value); end - # source://rake//lib/rake/application.rb#393 + # source://rake//lib/rake/application.rb#423 def sort_options(options); end - # source://rake//lib/rake/application.rb#744 + # source://rake//lib/rake/application.rb#774 def standard_system_dir; end end @@ -501,7 +493,7 @@ Rake::Application::DEFAULT_RAKEFILES = T.let(T.unsafe(nil), Array) # source://rake//lib/rake/backtrace.rb#3 module Rake::Backtrace class << self - # source://rake//lib/rake/backtrace.rb#18 + # source://rake//lib/rake/backtrace.rb#19 def collapse(backtrace); end end end @@ -512,7 +504,7 @@ Rake::Backtrace::SUPPRESSED_PATHS = T.let(T.unsafe(nil), Array) # source://rake//lib/rake/backtrace.rb#12 Rake::Backtrace::SUPPRESSED_PATHS_RE = T.let(T.unsafe(nil), String) -# source://rake//lib/rake/backtrace.rb#16 +# source://rake//lib/rake/backtrace.rb#17 Rake::Backtrace::SUPPRESS_PATTERN = T.let(T.unsafe(nil), Regexp) # source://rake//lib/rake/backtrace.rb#4 @@ -603,11 +595,11 @@ module Rake::DSL # # Example: # desc "Run the Unit Tests" - # task test: [:build] + # task test: [:build] do # # ... run tests # end # - # source://rake//lib/rake/dsl_definition.rb#165 + # source://rake//lib/rake/dsl_definition.rb#166 def desc(description); end # Declare a set of files tasks to create the given directories on @@ -655,7 +647,7 @@ module Rake::DSL # Example: # import ".depend", "my_rules" # - # source://rake//lib/rake/dsl_definition.rb#183 + # source://rake//lib/rake/dsl_definition.rb#184 def import(*fns); end # source://rake//lib/rake/file_utils_ext.rb#34 @@ -699,7 +691,7 @@ module Rake::DSL # Example: # multitask deploy: %w[deploy_gem deploy_rdoc] # - # source://rake//lib/rake/dsl_definition.rb#112 + # source://rake//lib/rake/dsl_definition.rb#113 def multitask(*args, &block); end # source://rake//lib/rake/file_utils_ext.rb#34 @@ -724,7 +716,7 @@ module Rake::DSL # # ... # end # - # source://rake//lib/rake/dsl_definition.rb#135 + # source://rake//lib/rake/dsl_definition.rb#136 def namespace(name = T.unsafe(nil), &block); end # source://rake//lib/rake/file_utils_ext.rb#77 @@ -757,20 +749,20 @@ module Rake::DSL # source://rake//lib/rake/file_utils_ext.rb#34 def rmtree(*args, **options, &block); end - # source://rake//lib/rake/file_utils.rb#100 + # source://rake//lib/rake/file_utils.rb#98 def ruby(*args, **options, &block); end # Declare a rule for auto-tasks. # # Example: # rule '.o' => '.c' do |t| - # sh 'cc', '-o', t.name, t.source + # sh 'cc', '-c', '-o', t.name, t.source # end # - # source://rake//lib/rake/dsl_definition.rb#151 + # source://rake//lib/rake/dsl_definition.rb#152 def rule(*args, &block); end - # source://rake//lib/rake/file_utils.rb#112 + # source://rake//lib/rake/file_utils.rb#110 def safe_ln(*args, **options); end # source://rake//lib/rake/file_utils_ext.rb#34 @@ -779,7 +771,7 @@ module Rake::DSL # source://rake//lib/rake/file_utils.rb#43 def sh(*cmd, &block); end - # source://rake//lib/rake/file_utils.rb#128 + # source://rake//lib/rake/file_utils.rb#126 def split_all(path); end # source://rake//lib/rake/file_utils_ext.rb#34 @@ -1547,9 +1539,6 @@ class Rake::FileList # source://rake//lib/rake/file_list.rb#182 def to_ary; end - # source://rake//lib/rake/file_list.rb#77 - def to_default_s(*args, &block); end - # source://rake//lib/rake/file_list.rb#77 def to_formatted_s(*args, &block); end @@ -1559,6 +1548,9 @@ class Rake::FileList # source://rake//lib/rake/file_list.rb#77 def to_h(*args, &block); end + # source://rake//lib/rake/file_list.rb#77 + def to_msgpack(*args, &block); end + # Convert a FileList to a string by joining all elements with a space. # # source://rake//lib/rake/file_list.rb#344 @@ -1682,7 +1674,7 @@ class Rake::FileTask < ::Rake::Task # Time stamp for file task. # - # source://rake//lib/rake/file_task.rb#21 + # source://rake//lib/rake/file_task.rb#25 def timestamp; end private @@ -1691,14 +1683,14 @@ class Rake::FileTask < ::Rake::Task # # @return [Boolean] # - # source://rake//lib/rake/file_task.rb#32 + # source://rake//lib/rake/file_task.rb#36 def out_of_date?(stamp); end class << self # Apply the scope to the task name according to the rules for this kind # of task. File based tasks ignore the scope when creating the name. # - # source://rake//lib/rake/file_task.rb#49 + # source://rake//lib/rake/file_task.rb#53 def scope_name(scope, task_name); end end end @@ -2272,9 +2264,6 @@ class Rake::PseudoStatus def to_i; end end -# source://rdoc/6.5.0/rdoc/task.rb#326 -Rake::RDocTask = RDoc::Task - # Error indicating a recursion overflow error in task selection. # # source://rake//lib/rake/rule_recursion_overflow_error.rb#5 @@ -2959,14 +2948,14 @@ class Rake::ThreadHistoryDisplay def threads; end end -# source://rake//lib/rake/thread_pool.rb#7 +# source://rake//lib/rake/thread_pool.rb#8 class Rake::ThreadPool # Creates a ThreadPool object. The +thread_count+ parameter is the size # of the pool. # # @return [ThreadPool] a new instance of ThreadPool # - # source://rake//lib/rake/thread_pool.rb#11 + # source://rake//lib/rake/thread_pool.rb#12 def initialize(thread_count); end # Creates a future executed by the +ThreadPool+. @@ -3103,7 +3092,7 @@ end # source://rake//lib/rake/win32.rb#11 class Rake::Win32::Win32HomeError < ::RuntimeError; end -# source://rake//lib/rake.rb#71 +# source://rake//lib/rake.rb#70 RakeFileUtils = Rake::FileUtilsExt # source://rake//lib/rake/ext/string.rb#4 @@ -3127,9 +3116,3 @@ class String # source://rake//lib/rake/ext/string.rb#59 def pathmap_replace(patterns, &block); end end - -# source://activesupport/7.0.5/lib/active_support/core_ext/object/blank.rb#104 -String::BLANK_RE = T.let(T.unsafe(nil), Regexp) - -# source://activesupport/7.0.5/lib/active_support/core_ext/object/blank.rb#105 -String::ENCODED_BLANKS = T.let(T.unsafe(nil), Concurrent::Map) diff --git a/sorbet/rbi/gems/rb-fsevent@0.11.2.rbi b/sorbet/rbi/gems/rb-fsevent@0.11.2.rbi index adc6c50a3..529b1b2f3 100644 --- a/sorbet/rbi/gems/rb-fsevent@0.11.2.rbi +++ b/sorbet/rbi/gems/rb-fsevent@0.11.2.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `rb-fsevent` gem. # Please instead update this file by running `bin/tapioca gem rb-fsevent`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/rb-inotify@0.10.1.rbi b/sorbet/rbi/gems/rb-inotify@0.11.1.rbi similarity index 99% rename from sorbet/rbi/gems/rb-inotify@0.10.1.rbi rename to sorbet/rbi/gems/rb-inotify@0.11.1.rbi index 1b1214d18..18f3c2f6e 100644 --- a/sorbet/rbi/gems/rb-inotify@0.10.1.rbi +++ b/sorbet/rbi/gems/rb-inotify@0.11.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `rb-inotify` gem. # Please instead update this file by running `bin/tapioca gem rb-inotify`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/rbi@0.0.16.rbi b/sorbet/rbi/gems/rbi@0.1.14.rbi similarity index 57% rename from sorbet/rbi/gems/rbi@0.0.16.rbi rename to sorbet/rbi/gems/rbi@0.1.14.rbi index ffef1d967..91934e215 100644 --- a/sorbet/rbi/gems/rbi@0.0.16.rbi +++ b/sorbet/rbi/gems/rbi@0.1.14.rbi @@ -4,58 +4,25 @@ # This is an autogenerated file for types exported from the `rbi` gem. # Please instead update this file by running `bin/tapioca gem rbi`. + # source://rbi//lib/rbi.rb#7 module RBI; end -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://rbi//lib/rbi/parser.rb#129 -class RBI::ASTVisitor - abstract! - - # source://sorbet-runtime/0.5.10601/lib/types/private/abstract/declare.rb#37 - def initialize(*args, **_arg1, &blk); end - - # @abstract - # - # source://rbi//lib/rbi/parser.rb#141 - sig { abstract.params(node: T.nilable(::AST::Node)).void } - def visit(node); end - - # source://rbi//lib/rbi/parser.rb#136 - sig { params(nodes: T::Array[::AST::Node]).void } - def visit_all(nodes); end - - private - - # source://rbi//lib/rbi/parser.rb#151 - sig { params(node: ::AST::Node).returns(::String) } - def parse_expr(node); end - - # source://rbi//lib/rbi/parser.rb#146 - sig { params(node: ::AST::Node).returns(::String) } - def parse_name(node); end -end - -# source://rbi//lib/rbi/model.rb#960 +# source://rbi//lib/rbi/model.rb#1043 class RBI::Arg < ::RBI::Node - # source://rbi//lib/rbi/model.rb#972 + # source://rbi//lib/rbi/model.rb#1055 sig { params(value: ::String, loc: T.nilable(::RBI::Loc)).void } def initialize(value, loc: T.unsafe(nil)); end - # source://rbi//lib/rbi/model.rb#978 + # source://rbi//lib/rbi/model.rb#1061 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#611 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#983 + # source://rbi//lib/rbi/model.rb#1066 sig { returns(::String) } def to_s; end - # source://rbi//lib/rbi/model.rb#964 + # source://rbi//lib/rbi/model.rb#1047 sig { returns(::String) } def value; end end @@ -64,13 +31,13 @@ end # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#341 +# source://rbi//lib/rbi/model.rb#351 class RBI::Attr < ::RBI::NodeWithComments include ::RBI::Indexable abstract! - # source://rbi//lib/rbi/model.rb#366 + # source://rbi//lib/rbi/model.rb#376 sig do params( name: ::Symbol, @@ -83,58 +50,84 @@ class RBI::Attr < ::RBI::NodeWithComments end def initialize(name, names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#346 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#406 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#414 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end # @abstract # - # source://rbi//lib/rbi/model.rb#374 + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#61 + sig { abstract.returns(T::Array[::RBI::Method]) } + def convert_to_methods; end + + # @abstract + # + # source://rbi//lib/rbi/model.rb#384 sig { abstract.returns(T::Array[::String]) } def fully_qualified_names; end - # source://rbi//lib/rbi/index.rb#109 + # source://rbi//lib/rbi/index.rb#113 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#413 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#422 sig { override.params(other: ::RBI::Node).void } def merge_with(other); end - # source://rbi//lib/rbi/model.rb#348 + # source://rbi//lib/rbi/model.rb#358 sig { returns(T::Array[::Symbol]) } def names; end - # @return [Array] - # - # source://rbi//lib/rbi/model.rb#348 - def names=(_arg0); end - - # source://rbi//lib/rbi/printer.rb#373 - sig { override.returns(T::Boolean) } - def oneline?; end - - # source://rbi//lib/rbi/model.rb#354 + # source://rbi//lib/rbi/model.rb#364 sig { returns(T::Array[::RBI::Sig]) } def sigs; end - # source://rbi//lib/rbi/model.rb#351 + # source://rbi//lib/rbi/model.rb#361 sig { returns(::RBI::Visibility) } def visibility; end # @return [Visibility] # - # source://rbi//lib/rbi/model.rb#351 + # source://rbi//lib/rbi/model.rb#361 def visibility=(_arg0); end + + private + + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#89 + sig do + params( + name: ::String, + sig: T.nilable(::RBI::Sig), + visibility: ::RBI::Visibility, + loc: T.nilable(::RBI::Loc), + comments: T::Array[::RBI::Comment] + ).returns(::RBI::Method) + end + def create_getter_method(name, sig, visibility, loc, comments); end + + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#110 + sig do + params( + name: ::String, + sig: T.nilable(::RBI::Sig), + attribute_type: T.nilable(::String), + visibility: ::RBI::Visibility, + loc: T.nilable(::RBI::Loc), + comments: T::Array[::RBI::Comment] + ).returns(::RBI::Method) + end + def create_setter_method(name, sig, attribute_type, visibility, loc, comments); end + + # @raise [UnexpectedMultipleSigsError] + # + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#66 + sig(:final) { returns([T.nilable(::RBI::Sig), T.nilable(::String)]) } + def parse_sig; end end -# source://rbi//lib/rbi/model.rb#377 +# source://rbi//lib/rbi/model.rb#387 class RBI::AttrAccessor < ::RBI::Attr - # source://rbi//lib/rbi/model.rb#391 + # source://rbi//lib/rbi/model.rb#401 sig do params( name: ::Symbol, @@ -148,22 +141,26 @@ class RBI::AttrAccessor < ::RBI::Attr end def initialize(name, *names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#444 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#454 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#397 + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#140 + sig { override.returns(T::Array[::RBI::Method]) } + def convert_to_methods; end + + # source://rbi//lib/rbi/model.rb#407 sig { override.returns(T::Array[::String]) } def fully_qualified_names; end - # source://rbi//lib/rbi/model.rb#403 + # source://rbi//lib/rbi/model.rb#413 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#409 +# source://rbi//lib/rbi/model.rb#419 class RBI::AttrReader < ::RBI::Attr - # source://rbi//lib/rbi/model.rb#423 + # source://rbi//lib/rbi/model.rb#433 sig do params( name: ::Symbol, @@ -177,22 +174,26 @@ class RBI::AttrReader < ::RBI::Attr end def initialize(name, *names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#426 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#436 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#429 + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#154 + sig { override.returns(T::Array[::RBI::Method]) } + def convert_to_methods; end + + # source://rbi//lib/rbi/model.rb#439 sig { override.returns(T::Array[::String]) } def fully_qualified_names; end - # source://rbi//lib/rbi/model.rb#435 + # source://rbi//lib/rbi/model.rb#445 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#441 +# source://rbi//lib/rbi/model.rb#451 class RBI::AttrWriter < ::RBI::Attr - # source://rbi//lib/rbi/model.rb#455 + # source://rbi//lib/rbi/model.rb#465 sig do params( name: ::Symbol, @@ -206,35 +207,35 @@ class RBI::AttrWriter < ::RBI::Attr end def initialize(name, *names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#435 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#445 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#461 + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#163 + sig { override.returns(T::Array[::RBI::Method]) } + def convert_to_methods; end + + # source://rbi//lib/rbi/model.rb#471 sig { override.returns(T::Array[::String]) } def fully_qualified_names; end - # source://rbi//lib/rbi/model.rb#467 + # source://rbi//lib/rbi/model.rb#477 sig { override.returns(::String) } def to_s; end end # An arbitrary blank line that can be added both in trees and comments # -# source://rbi//lib/rbi/model.rb#70 +# source://rbi//lib/rbi/model.rb#76 class RBI::BlankLine < ::RBI::Comment - # source://rbi//lib/rbi/model.rb#74 + # source://rbi//lib/rbi/model.rb#80 sig { params(loc: T.nilable(::RBI::Loc)).void } def initialize(loc: T.unsafe(nil)); end - - # source://rbi//lib/rbi/printer.rb#215 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end end -# source://rbi//lib/rbi/model.rb#733 +# source://rbi//lib/rbi/model.rb#816 class RBI::BlockParam < ::RBI::Param - # source://rbi//lib/rbi/model.rb#744 + # source://rbi//lib/rbi/model.rb#827 sig do params( name: ::String, @@ -245,26 +246,18 @@ class RBI::BlockParam < ::RBI::Param end def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#755 + # source://rbi//lib/rbi/model.rb#838 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#541 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#546 - sig { override.params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - - # source://rbi//lib/rbi/model.rb#750 + # source://rbi//lib/rbi/model.rb#833 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#213 +# source://rbi//lib/rbi/model.rb#220 class RBI::Class < ::RBI::Scope - # source://rbi//lib/rbi/model.rb#231 + # source://rbi//lib/rbi/model.rb#238 sig do params( name: ::String, @@ -276,58 +269,50 @@ class RBI::Class < ::RBI::Scope end def initialize(name, superclass_name: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#370 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#378 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#239 + # source://rbi//lib/rbi/model.rb#246 sig { override.returns(::String) } def fully_qualified_name; end - # source://rbi//lib/rbi/model.rb#217 + # source://rbi//lib/rbi/model.rb#224 sig { returns(::String) } def name; end # @return [String] # - # source://rbi//lib/rbi/model.rb#217 + # source://rbi//lib/rbi/model.rb#224 def name=(_arg0); end - # source://rbi//lib/rbi/printer.rb#282 - sig { override.params(v: ::RBI::Printer).void } - def print_header(v); end - - # source://rbi//lib/rbi/model.rb#220 + # source://rbi//lib/rbi/model.rb#227 sig { returns(T.nilable(::String)) } def superclass_name; end # @return [String, nil] # - # source://rbi//lib/rbi/model.rb#220 + # source://rbi//lib/rbi/model.rb#227 def superclass_name=(_arg0); end end -# source://rbi//lib/rbi/model.rb#50 +# source://rbi//lib/rbi/model.rb#55 class RBI::Comment < ::RBI::Node - # source://rbi//lib/rbi/model.rb#57 + # source://rbi//lib/rbi/model.rb#62 sig { params(text: ::String, loc: T.nilable(::RBI::Loc)).void } def initialize(text, loc: T.unsafe(nil)); end - # source://rbi//lib/rbi/model.rb#63 + # source://rbi//lib/rbi/model.rb#68 sig { params(other: ::Object).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#195 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#54 + # source://rbi//lib/rbi/model.rb#59 sig { returns(::String) } def text; end # @return [String] # - # source://rbi//lib/rbi/model.rb#54 + # source://rbi//lib/rbi/model.rb#59 def text=(_arg0); end end @@ -346,33 +331,38 @@ end # end # ~~~ # -# source://rbi//lib/rbi/rewriters/merge_trees.rb#578 +# source://rbi//lib/rbi/rewriters/merge_trees.rb#591 class RBI::ConflictTree < ::RBI::Tree - # source://rbi//lib/rbi/rewriters/merge_trees.rb#585 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#601 sig { params(left_name: ::String, right_name: ::String).void } def initialize(left_name: T.unsafe(nil), right_name: T.unsafe(nil)); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#596 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#582 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#595 sig { returns(::RBI::Tree) } def left; end + # source://rbi//lib/rbi/rewriters/merge_trees.rb#598 + sig { returns(::String) } + def left_name; end + # @return [Tree] # - # source://rbi//lib/rbi/rewriters/merge_trees.rb#582 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#595 def right; end + + # @return [String] + # + # source://rbi//lib/rbi/rewriters/merge_trees.rb#598 + def right_name; end end # Consts # -# source://rbi//lib/rbi/model.rb#305 +# source://rbi//lib/rbi/model.rb#314 class RBI::Const < ::RBI::NodeWithComments include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#320 + # source://rbi//lib/rbi/model.rb#329 sig do params( name: ::String, @@ -384,70 +374,43 @@ class RBI::Const < ::RBI::NodeWithComments end def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/printer.rb#333 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#397 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#405 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#328 + # source://rbi//lib/rbi/model.rb#337 sig { returns(::String) } def fully_qualified_name; end - # source://rbi//lib/rbi/index.rb#99 + # source://rbi//lib/rbi/index.rb#103 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#309 + # source://rbi//lib/rbi/model.rb#318 sig { returns(::String) } def name; end - # source://rbi//lib/rbi/model.rb#334 + # source://rbi//lib/rbi/model.rb#344 sig { override.returns(::String) } def to_s; end # @return [String] # - # source://rbi//lib/rbi/model.rb#309 + # source://rbi//lib/rbi/model.rb#318 def value; end end -# source://rbi//lib/rbi/parser.rb#600 -class RBI::ConstBuilder < ::RBI::ASTVisitor - # source://rbi//lib/rbi/parser.rb#615 - sig { void } - def initialize; end - - # source://rbi//lib/rbi/parser.rb#612 - sig { returns(T::Array[::String]) } - def names; end - - # @return [Array] - # - # source://rbi//lib/rbi/parser.rb#612 - def names=(_arg0); end - - # source://rbi//lib/rbi/parser.rb#621 - sig { override.params(node: T.nilable(::AST::Node)).void } - def visit(node); end - - class << self - # source://rbi//lib/rbi/parser.rb#604 - sig { params(node: T.nilable(::AST::Node)).returns(T.nilable(::String)) } - def visit(node); end - end -end +# source://rbi//lib/rbi/rewriters/merge_trees.rb#351 +class RBI::DuplicateNodeError < ::RBI::Error; end # source://rbi//lib/rbi.rb#8 class RBI::Error < ::StandardError; end -# source://rbi//lib/rbi/model.rb#808 +# source://rbi//lib/rbi/model.rb#891 class RBI::Extend < ::RBI::Mixin include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#820 + # source://rbi//lib/rbi/model.rb#903 sig do params( name: ::String, @@ -459,22 +422,22 @@ class RBI::Extend < ::RBI::Mixin end def initialize(name, *names, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#492 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#504 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/index.rb#139 + # source://rbi//lib/rbi/index.rb#143 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#826 + # source://rbi//lib/rbi/model.rb#909 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#133 +# source://rbi//lib/rbi/model.rb#139 class RBI::File - # source://rbi//lib/rbi/model.rb#152 + # source://rbi//lib/rbi/model.rb#158 sig do params( strictness: T.nilable(::String), @@ -484,28 +447,24 @@ class RBI::File end def initialize(strictness: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#160 + # source://rbi//lib/rbi/model.rb#166 sig { params(node: ::RBI::Node).void } def <<(node); end - # source://rbi//lib/rbi/printer.rb#104 - sig { params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#143 + # source://rbi//lib/rbi/model.rb#149 sig { returns(T::Array[::RBI::Comment]) } def comments; end # @return [Array] # - # source://rbi//lib/rbi/model.rb#143 + # source://rbi//lib/rbi/model.rb#149 def comments=(_arg0); end - # source://rbi//lib/rbi/model.rb#165 + # source://rbi//lib/rbi/model.rb#171 sig { returns(T::Boolean) } def empty?; end - # source://rbi//lib/rbi/printer.rb#128 + # source://rbi//lib/rbi/printer.rb#744 sig do params( out: T.any(::IO, ::StringIO), @@ -516,25 +475,25 @@ class RBI::File end def print(out: T.unsafe(nil), indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end - # source://rbi//lib/rbi/model.rb#137 + # source://rbi//lib/rbi/model.rb#143 sig { returns(::RBI::Tree) } def root; end # @return [Tree] # - # source://rbi//lib/rbi/model.rb#137 + # source://rbi//lib/rbi/model.rb#143 def root=(_arg0); end - # source://rbi//lib/rbi/model.rb#140 + # source://rbi//lib/rbi/model.rb#146 sig { returns(T.nilable(::String)) } def strictness; end # @return [String, nil] # - # source://rbi//lib/rbi/model.rb#140 + # source://rbi//lib/rbi/model.rb#146 def strictness=(_arg0); end - # source://rbi//lib/rbi/printer.rb#134 + # source://rbi//lib/rbi/printer.rb#750 sig { params(indent: ::Integer, print_locs: T::Boolean, max_line_length: T.nilable(::Integer)).returns(::String) } def string(indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end end @@ -554,33 +513,14 @@ class RBI::Formatter end def initialize(add_sig_templates: T.unsafe(nil), group_nodes: T.unsafe(nil), max_line_length: T.unsafe(nil), nest_singleton_methods: T.unsafe(nil), nest_non_public_methods: T.unsafe(nil), sort_nodes: T.unsafe(nil)); end - # source://rbi//lib/rbi/formatter.rb#9 - sig { returns(T::Boolean) } - def add_sig_templates; end - - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def add_sig_templates=(_arg0); end - - # source://rbi//lib/rbi/formatter.rb#53 + # source://rbi//lib/rbi/formatter.rb#47 sig { params(file: ::RBI::File).void } def format_file(file); end - # source://rbi//lib/rbi/formatter.rb#58 + # source://rbi//lib/rbi/formatter.rb#52 sig { params(tree: ::RBI::Tree).void } def format_tree(tree); end - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def group_nodes; end - - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def group_nodes=(_arg0); end - # source://rbi//lib/rbi/formatter.rb#12 sig { returns(T.nilable(::Integer)) } def max_line_length; end @@ -590,61 +530,27 @@ class RBI::Formatter # source://rbi//lib/rbi/formatter.rb#12 def max_line_length=(_arg0); end - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def nest_non_public_methods; end - - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def nest_non_public_methods=(_arg0); end - - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def nest_singleton_methods; end - - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def nest_singleton_methods=(_arg0); end - # source://rbi//lib/rbi/formatter.rb#41 sig { params(file: ::RBI::File).returns(::String) } def print_file(file); end - # source://rbi//lib/rbi/formatter.rb#47 - sig { params(tree: ::RBI::Tree).returns(::String) } - def print_tree(tree); end - - # @return [Boolean] - # # source://rbi//lib/rbi/formatter.rb#9 - def sort_nodes; end - - # @return [Boolean] - # - # source://rbi//lib/rbi/formatter.rb#9 - def sort_nodes=(_arg0); end + sig { params(sort_nodes: T::Boolean).returns(T::Boolean) } + def sort_nodes=(sort_nodes); end end -# source://rbi//lib/rbi/rewriters/group_nodes.rb#88 +# source://rbi//lib/rbi/rewriters/group_nodes.rb#87 class RBI::Group < ::RBI::Tree - # source://rbi//lib/rbi/rewriters/group_nodes.rb#95 + # source://rbi//lib/rbi/rewriters/group_nodes.rb#94 sig { params(kind: ::RBI::Group::Kind).void } def initialize(kind); end - # source://rbi//lib/rbi/printer.rb#836 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/group_nodes.rb#92 + # source://rbi//lib/rbi/rewriters/group_nodes.rb#91 sig { returns(::RBI::Group::Kind) } def kind; end end -# source://rbi//lib/rbi/rewriters/group_nodes.rb#100 +# source://rbi//lib/rbi/rewriters/group_nodes.rb#99 class RBI::Group::Kind < ::T::Enum enums do Mixins = new @@ -663,13 +569,16 @@ class RBI::Group::Kind < ::T::Enum end end +# source://rbi//lib/rbi/rewriters/group_nodes.rb#5 +class RBI::GroupNodesError < ::RBI::Error; end + # Sorbet's misc. # -# source://rbi//lib/rbi/model.rb#1285 +# source://rbi//lib/rbi/model.rb#1374 class RBI::Helper < ::RBI::NodeWithComments include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#1299 + # source://rbi//lib/rbi/model.rb#1388 sig do params( name: ::String, @@ -680,32 +589,28 @@ class RBI::Helper < ::RBI::NodeWithComments end def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/printer.rb#823 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#510 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#522 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/index.rb#169 + # source://rbi//lib/rbi/index.rb#173 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#1289 + # source://rbi//lib/rbi/model.rb#1378 sig { returns(::String) } def name; end - # source://rbi//lib/rbi/model.rb#1306 + # source://rbi//lib/rbi/model.rb#1395 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#785 +# source://rbi//lib/rbi/model.rb#868 class RBI::Include < ::RBI::Mixin include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#797 + # source://rbi//lib/rbi/model.rb#880 sig do params( name: ::String, @@ -717,59 +622,59 @@ class RBI::Include < ::RBI::Mixin end def initialize(name, *names, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#483 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#495 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/index.rb#129 + # source://rbi//lib/rbi/index.rb#133 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#803 + # source://rbi//lib/rbi/model.rb#886 sig { override.returns(::String) } def to_s; end end # source://rbi//lib/rbi/index.rb#5 class RBI::Index < ::RBI::Visitor - # source://rbi//lib/rbi/index.rb#17 + # source://rbi//lib/rbi/index.rb#21 sig { void } def initialize; end - # source://rbi//lib/rbi/index.rb#28 + # source://rbi//lib/rbi/index.rb#32 sig { params(id: ::String).returns(T::Array[::RBI::Node]) } def [](id); end - # source://rbi//lib/rbi/index.rb#33 + # source://rbi//lib/rbi/index.rb#37 sig { params(nodes: ::RBI::Node).void } def index(*nodes); end - # source://rbi//lib/rbi/index.rb#23 + # source://rbi//lib/rbi/index.rb#27 sig { returns(T::Array[::String]) } def keys; end - # source://rbi//lib/rbi/index.rb#38 + # source://rbi//lib/rbi/index.rb#42 sig { override.params(node: T.nilable(::RBI::Node)).void } def visit(node); end private - # source://rbi//lib/rbi/index.rb#55 + # source://rbi//lib/rbi/index.rb#59 sig { params(node: T.all(::RBI::Indexable, ::RBI::Node)).void } def index_node(node); end class << self - # source://rbi//lib/rbi/index.rb#10 + # source://rbi//lib/rbi/index.rb#13 sig { params(node: ::RBI::Node).returns(::RBI::Index) } def index(*node); end end end -# A Node that can be refered to by a unique ID inside an index +# A Node that can be referred to by a unique ID inside an index # # @abstract Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/index.rb#70 +# source://rbi//lib/rbi/index.rb#74 module RBI::Indexable interface! @@ -780,37 +685,33 @@ module RBI::Indexable # # @abstract # - # source://rbi//lib/rbi/index.rb#81 + # source://rbi//lib/rbi/index.rb#85 sig { abstract.returns(T::Array[::String]) } def index_ids; end end -# source://rbi//lib/rbi/model.rb#988 +# source://rbi//lib/rbi/model.rb#1071 class RBI::KwArg < ::RBI::Arg - # source://rbi//lib/rbi/model.rb#1001 + # source://rbi//lib/rbi/model.rb#1084 sig { params(keyword: ::String, value: ::String, loc: T.nilable(::RBI::Loc)).void } def initialize(keyword, value, loc: T.unsafe(nil)); end - # source://rbi//lib/rbi/model.rb#1007 + # source://rbi//lib/rbi/model.rb#1090 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#620 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#992 + # source://rbi//lib/rbi/model.rb#1075 sig { returns(::String) } def keyword; end - # source://rbi//lib/rbi/model.rb#1012 + # source://rbi//lib/rbi/model.rb#1095 sig { returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#674 +# source://rbi//lib/rbi/model.rb#757 class RBI::KwOptParam < ::RBI::Param - # source://rbi//lib/rbi/model.rb#689 + # source://rbi//lib/rbi/model.rb#772 sig do params( name: ::String, @@ -822,30 +723,22 @@ class RBI::KwOptParam < ::RBI::Param end def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#701 + # source://rbi//lib/rbi/model.rb#784 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#511 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#516 - sig { override.params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - - # source://rbi//lib/rbi/model.rb#696 + # source://rbi//lib/rbi/model.rb#779 sig { override.returns(::String) } def to_s; end - # source://rbi//lib/rbi/model.rb#678 + # source://rbi//lib/rbi/model.rb#761 sig { returns(::String) } def value; end end -# source://rbi//lib/rbi/model.rb#647 +# source://rbi//lib/rbi/model.rb#730 class RBI::KwParam < ::RBI::Param - # source://rbi//lib/rbi/model.rb#658 + # source://rbi//lib/rbi/model.rb#741 sig do params( name: ::String, @@ -856,26 +749,18 @@ class RBI::KwParam < ::RBI::Param end def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#669 + # source://rbi//lib/rbi/model.rb#752 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#496 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#501 - sig { override.params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - - # source://rbi//lib/rbi/model.rb#664 + # source://rbi//lib/rbi/model.rb#747 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#706 +# source://rbi//lib/rbi/model.rb#789 class RBI::KwRestParam < ::RBI::Param - # source://rbi//lib/rbi/model.rb#717 + # source://rbi//lib/rbi/model.rb#800 sig do params( name: ::String, @@ -886,26 +771,18 @@ class RBI::KwRestParam < ::RBI::Param end def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#728 + # source://rbi//lib/rbi/model.rb#811 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#526 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#531 - sig { override.params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - - # source://rbi//lib/rbi/model.rb#723 + # source://rbi//lib/rbi/model.rb#806 sig { override.returns(::String) } def to_s; end end # source://rbi//lib/rbi/loc.rb#5 class RBI::Loc - # source://rbi//lib/rbi/loc.rb#23 + # source://rbi//lib/rbi/loc.rb#38 sig do params( file: T.nilable(::String), @@ -919,47 +796,47 @@ class RBI::Loc # @return [Integer, nil] # - # source://rbi//lib/rbi/loc.rb#12 + # source://rbi//lib/rbi/loc.rb#27 def begin_column; end - # source://rbi//lib/rbi/loc.rb#12 + # source://rbi//lib/rbi/loc.rb#27 sig { returns(T.nilable(::Integer)) } def begin_line; end # @return [Integer, nil] # - # source://rbi//lib/rbi/loc.rb#12 + # source://rbi//lib/rbi/loc.rb#27 def end_column; end # @return [Integer, nil] # - # source://rbi//lib/rbi/loc.rb#12 + # source://rbi//lib/rbi/loc.rb#27 def end_line; end - # source://rbi//lib/rbi/loc.rb#9 + # source://rbi//lib/rbi/loc.rb#24 sig { returns(T.nilable(::String)) } def file; end - # source://rbi//lib/rbi/loc.rb#37 + # source://rbi//lib/rbi/loc.rb#56 sig { returns(T.nilable(::String)) } def source; end - # source://rbi//lib/rbi/loc.rb#32 + # source://rbi//lib/rbi/loc.rb#47 sig { returns(::String) } def to_s; end class << self - # source://rbi//lib/rbi/parser.rb#707 - sig { params(file: ::String, ast_loc: T.any(::Parser::Source::Map, ::Parser::Source::Range)).returns(::RBI::Loc) } - def from_ast_loc(file, ast_loc); end + # source://rbi//lib/rbi/loc.rb#12 + sig { params(file: ::String, prism_location: ::Prism::Location).returns(::RBI::Loc) } + def from_prism(file, prism_location); end end end # A tree that _might_ contain conflicts # -# source://rbi//lib/rbi/rewriters/merge_trees.rb#324 +# source://rbi//lib/rbi/rewriters/merge_trees.rb#330 class RBI::MergeTree < ::RBI::Tree - # source://rbi//lib/rbi/rewriters/merge_trees.rb#338 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#344 sig do params( loc: T.nilable(::RBI::Loc), @@ -970,18 +847,18 @@ class RBI::MergeTree < ::RBI::Tree end def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), conflicts: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#328 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#334 sig { returns(T::Array[::RBI::Rewriters::Merge::Conflict]) } def conflicts; end end # Methods and args # -# source://rbi//lib/rbi/model.rb#475 +# source://rbi//lib/rbi/model.rb#485 class RBI::Method < ::RBI::NodeWithComments include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#505 + # source://rbi//lib/rbi/model.rb#515 sig do params( name: ::String, @@ -996,88 +873,120 @@ class RBI::Method < ::RBI::NodeWithComments end def initialize(name, params: T.unsafe(nil), is_singleton: T.unsafe(nil), visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#525 + # source://rbi//lib/rbi/model.rb#535 sig { params(param: ::RBI::Param).void } def <<(param); end - # source://rbi//lib/rbi/printer.rb#382 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end + # source://rbi//lib/rbi/model.rb#570 + sig { params(name: ::String).void } + def add_block_param(name); end + + # source://rbi//lib/rbi/model.rb#560 + sig { params(name: ::String, default_value: ::String).void } + def add_kw_opt_param(name, default_value); end + + # source://rbi//lib/rbi/model.rb#555 + sig { params(name: ::String).void } + def add_kw_param(name); end + + # source://rbi//lib/rbi/model.rb#565 + sig { params(name: ::String).void } + def add_kw_rest_param(name); end + + # source://rbi//lib/rbi/model.rb#545 + sig { params(name: ::String, default_value: ::String).void } + def add_opt_param(name, default_value); end + + # source://rbi//lib/rbi/model.rb#540 + sig { params(name: ::String).void } + def add_param(name); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#453 + # source://rbi//lib/rbi/model.rb#550 + sig { params(name: ::String).void } + def add_rest_param(name); end + + # source://rbi//lib/rbi/model.rb#587 + sig do + params( + params: T::Array[::RBI::SigParam], + return_type: T.nilable(::String), + is_abstract: T::Boolean, + is_override: T::Boolean, + is_overridable: T::Boolean, + is_final: T::Boolean, + type_params: T::Array[::String], + checked: T.nilable(::Symbol), + block: T.proc.params(node: ::RBI::Sig).void + ).void + end + def add_sig(params: T.unsafe(nil), return_type: T.unsafe(nil), is_abstract: T.unsafe(nil), is_override: T.unsafe(nil), is_overridable: T.unsafe(nil), is_final: T.unsafe(nil), type_params: T.unsafe(nil), checked: T.unsafe(nil), &block); end + + # source://rbi//lib/rbi/rewriters/merge_trees.rb#463 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#530 + # source://rbi//lib/rbi/model.rb#613 sig { returns(::String) } def fully_qualified_name; end - # source://rbi//lib/rbi/index.rb#119 + # source://rbi//lib/rbi/index.rb#123 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/printer.rb#435 - sig { returns(T::Boolean) } - def inline_params?; end - - # source://rbi//lib/rbi/model.rb#485 + # source://rbi//lib/rbi/model.rb#495 sig { returns(T::Boolean) } def is_singleton; end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#485 + # source://rbi//lib/rbi/model.rb#495 def is_singleton=(_arg0); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#461 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#472 sig { override.params(other: ::RBI::Node).void } def merge_with(other); end - # source://rbi//lib/rbi/model.rb#479 + # source://rbi//lib/rbi/model.rb#489 sig { returns(::String) } def name; end # @return [String] # - # source://rbi//lib/rbi/model.rb#479 + # source://rbi//lib/rbi/model.rb#489 def name=(_arg0); end - # source://rbi//lib/rbi/printer.rb#430 - sig { override.returns(T::Boolean) } - def oneline?; end - - # source://rbi//lib/rbi/model.rb#482 + # source://rbi//lib/rbi/model.rb#492 sig { returns(T::Array[::RBI::Param]) } def params; end - # source://rbi//lib/rbi/model.rb#491 + # source://rbi//lib/rbi/model.rb#501 sig { returns(T::Array[::RBI::Sig]) } def sigs; end # @return [Array] # - # source://rbi//lib/rbi/model.rb#491 + # source://rbi//lib/rbi/model.rb#501 def sigs=(_arg0); end - # source://rbi//lib/rbi/model.rb#539 + # source://rbi//lib/rbi/model.rb#622 sig { override.returns(::String) } def to_s; end - # source://rbi//lib/rbi/model.rb#488 + # source://rbi//lib/rbi/model.rb#498 sig { returns(::RBI::Visibility) } def visibility; end # @return [Visibility] # - # source://rbi//lib/rbi/model.rb#488 + # source://rbi//lib/rbi/model.rb#498 def visibility=(_arg0); end end -# source://rbi//lib/rbi/model.rb#1345 +# source://rbi//lib/rbi/model.rb#1435 class RBI::MixesInClassMethods < ::RBI::Mixin include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#1357 + # source://rbi//lib/rbi/model.rb#1447 sig do params( name: ::String, @@ -1089,15 +998,15 @@ class RBI::MixesInClassMethods < ::RBI::Mixin end def initialize(name, *names, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#501 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#513 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/index.rb#149 + # source://rbi//lib/rbi/index.rb#153 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#1363 + # source://rbi//lib/rbi/model.rb#1453 sig { override.returns(::String) } def to_s; end end @@ -1106,11 +1015,11 @@ end # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#762 +# source://rbi//lib/rbi/model.rb#845 class RBI::Mixin < ::RBI::NodeWithComments abstract! - # source://rbi//lib/rbi/model.rb#779 + # source://rbi//lib/rbi/model.rb#862 sig do params( name: ::String, @@ -1121,27 +1030,18 @@ class RBI::Mixin < ::RBI::NodeWithComments end def initialize(name, names, loc: T.unsafe(nil), comments: T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#556 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#474 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#486 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#769 + # source://rbi//lib/rbi/model.rb#852 sig { returns(T::Array[::String]) } def names; end - - # @return [Array] - # - # source://rbi//lib/rbi/model.rb#769 - def names=(_arg0); end end -# source://rbi//lib/rbi/model.rb#186 +# source://rbi//lib/rbi/model.rb#192 class RBI::Module < ::RBI::Scope - # source://rbi//lib/rbi/model.rb#200 + # source://rbi//lib/rbi/model.rb#206 sig do params( name: ::String, @@ -1152,95 +1052,77 @@ class RBI::Module < ::RBI::Scope end def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#379 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#387 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#207 + # source://rbi//lib/rbi/model.rb#213 sig { override.returns(::String) } def fully_qualified_name; end - # source://rbi//lib/rbi/model.rb#190 + # source://rbi//lib/rbi/model.rb#196 sig { returns(::String) } def name; end # @return [String] # - # source://rbi//lib/rbi/model.rb#190 + # source://rbi//lib/rbi/model.rb#196 def name=(_arg0); end - - # source://rbi//lib/rbi/printer.rb#268 - sig { override.params(v: ::RBI::Printer).void } - def print_header(v); end end # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#5 +# source://rbi//lib/rbi/model.rb#7 class RBI::Node abstract! - # source://rbi//lib/rbi/model.rb#18 + # source://rbi//lib/rbi/model.rb#20 sig { params(loc: T.nilable(::RBI::Loc)).void } def initialize(loc: T.unsafe(nil)); end - # @abstract - # - # source://rbi//lib/rbi/printer.rb#145 - sig { abstract.params(v: ::RBI::Printer).void } - def accept_printer(v); end - # Can `self` and `_other` be merged into a single definition? # - # source://rbi//lib/rbi/rewriters/merge_trees.rb#283 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#287 sig { params(_other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(_other); end - # source://rbi//lib/rbi/model.rb#24 + # source://rbi//lib/rbi/model.rb#26 sig { void } def detach; end - # source://rbi//lib/rbi/rewriters/group_nodes.rb#48 - sig { returns(::RBI::Group::Kind) } - def group_kind; end - - # source://rbi//lib/rbi/model.rb#15 + # source://rbi//lib/rbi/model.rb#17 sig { returns(T.nilable(::RBI::Loc)) } def loc; end # @return [Loc, nil] # - # source://rbi//lib/rbi/model.rb#15 + # source://rbi//lib/rbi/model.rb#17 def loc=(_arg0); end # Merge `self` and `other` into a single definition # - # source://rbi//lib/rbi/rewriters/merge_trees.rb#289 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#293 sig { params(other: ::RBI::Node).void } def merge_with(other); end - # source://rbi//lib/rbi/printer.rb#177 - sig { returns(T::Boolean) } - def oneline?; end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#292 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#296 sig { returns(T.nilable(::RBI::ConflictTree)) } def parent_conflict_tree; end - # source://rbi//lib/rbi/model.rb#43 + # source://rbi//lib/rbi/model.rb#48 sig { returns(T.nilable(::RBI::Scope)) } def parent_scope; end - # source://rbi//lib/rbi/model.rb#12 + # source://rbi//lib/rbi/model.rb#14 sig { returns(T.nilable(::RBI::Tree)) } def parent_tree; end # @return [Tree, nil] # - # source://rbi//lib/rbi/model.rb#12 + # source://rbi//lib/rbi/model.rb#14 def parent_tree=(_arg0); end - # source://rbi//lib/rbi/printer.rb#155 + # source://rbi//lib/rbi/printer.rb#768 sig do params( out: T.any(::IO, ::StringIO), @@ -1251,54 +1133,56 @@ class RBI::Node end def print(out: T.unsafe(nil), indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#168 - sig { params(v: ::RBI::Printer).void } - def print_blank_line_before(v); end - - # source://rbi//lib/rbi/model.rb#32 + # @raise [ReplaceNodeError] + # + # source://rbi//lib/rbi/model.rb#35 sig { params(node: ::RBI::Node).void } def replace(node); end - # source://rbi//lib/rbi/printer.rb#161 + # source://rbi//lib/rbi/rewriters/filter_versions.rb#94 + sig { params(version: ::Gem::Version).returns(T::Boolean) } + def satisfies_version?(version); end + + # source://rbi//lib/rbi/printer.rb#774 sig { params(indent: ::Integer, print_locs: T::Boolean, max_line_length: T.nilable(::Integer)).returns(::String) } def string(indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end end # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#79 +# source://rbi//lib/rbi/model.rb#85 class RBI::NodeWithComments < ::RBI::Node abstract! - # source://rbi//lib/rbi/model.rb#89 + # source://rbi//lib/rbi/model.rb#95 sig { params(loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void } def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil)); end - # source://rbi//lib/rbi/model.rb#95 + # source://rbi//lib/rbi/model.rb#101 sig { returns(T::Array[::String]) } def annotations; end - # source://rbi//lib/rbi/model.rb#86 + # source://rbi//lib/rbi/model.rb#92 sig { returns(T::Array[::RBI::Comment]) } def comments; end # @return [Array] # - # source://rbi//lib/rbi/model.rb#86 + # source://rbi//lib/rbi/model.rb#92 def comments=(_arg0); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#306 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#311 sig { override.params(other: ::RBI::Node).void } def merge_with(other); end - # source://rbi//lib/rbi/printer.rb#186 - sig { override.returns(T::Boolean) } - def oneline?; end + # source://rbi//lib/rbi/rewriters/filter_versions.rb#104 + sig { returns(T::Array[::Gem::Requirement]) } + def version_requirements; end end -# source://rbi//lib/rbi/model.rb#593 +# source://rbi//lib/rbi/model.rb#676 class RBI::OptParam < ::RBI::Param - # source://rbi//lib/rbi/model.rb#608 + # source://rbi//lib/rbi/model.rb#691 sig do params( name: ::String, @@ -1310,56 +1194,36 @@ class RBI::OptParam < ::RBI::Param end def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#615 + # source://rbi//lib/rbi/model.rb#698 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#466 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#471 - sig { override.params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - - # source://rbi//lib/rbi/model.rb#597 + # source://rbi//lib/rbi/model.rb#680 sig { returns(::String) } def value; end end # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#544 +# source://rbi//lib/rbi/model.rb#627 class RBI::Param < ::RBI::NodeWithComments abstract! - # source://rbi//lib/rbi/model.rb#560 + # source://rbi//lib/rbi/model.rb#643 sig { params(name: ::String, loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void } def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#444 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#457 - sig { returns(T::Array[::String]) } - def comments_lines; end - - # source://rbi//lib/rbi/model.rb#551 + # source://rbi//lib/rbi/model.rb#634 sig { returns(::String) } def name; end - # source://rbi//lib/rbi/printer.rb#449 - sig { params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - - # source://rbi//lib/rbi/model.rb#566 + # source://rbi//lib/rbi/model.rb#649 sig { override.returns(::String) } def to_s; end end # source://rbi//lib/rbi/parser.rb#7 -class RBI::ParseError < ::StandardError +class RBI::ParseError < ::RBI::Error # source://rbi//lib/rbi/parser.rb#14 sig { params(message: ::String, location: ::RBI::Loc).void } def initialize(message, location); end @@ -1371,46 +1235,207 @@ end # source://rbi//lib/rbi/parser.rb#53 class RBI::Parser - # source://rbi//lib/rbi/parser.rb#64 - sig { void } - def initialize; end - - # source://rbi//lib/rbi/parser.rb#97 + # source://rbi//lib/rbi/parser.rb#88 sig { params(path: ::String).returns(::RBI::Tree) } def parse_file(path); end - # source://rbi//lib/rbi/parser.rb#86 + # source://rbi//lib/rbi/parser.rb#83 sig { params(string: ::String).returns(::RBI::Tree) } def parse_string(string); end private - # source://rbi//lib/rbi/parser.rb#104 - sig { params(content: ::String, file: ::String).returns(::RBI::Tree) } - def parse(content, file:); end + # source://rbi//lib/rbi/parser.rb#95 + sig { params(source: ::String, file: ::String).returns(::RBI::Tree) } + def parse(source, file:); end class << self - # source://rbi//lib/rbi/parser.rb#75 + # source://rbi//lib/rbi/parser.rb#65 sig { params(path: ::String).returns(::RBI::Tree) } def parse_file(path); end - # source://rbi//lib/rbi/parser.rb#80 + # source://rbi//lib/rbi/parser.rb#70 sig { params(paths: T::Array[::String]).returns(T::Array[::RBI::Tree]) } def parse_files(paths); end - # source://rbi//lib/rbi/parser.rb#70 + # source://rbi//lib/rbi/parser.rb#60 sig { params(string: ::String).returns(::RBI::Tree) } def parse_string(string); end - # source://rbi//lib/rbi/parser.rb#91 + # source://rbi//lib/rbi/parser.rb#76 sig { params(strings: T::Array[::String]).returns(T::Array[::RBI::Tree]) } def parse_strings(strings); end end end -# source://rbi//lib/rbi/printer.rb#5 +# source://rbi//lib/rbi/parser.rb#791 +class RBI::Parser::SigBuilder < ::RBI::Parser::Visitor + # source://rbi//lib/rbi/parser.rb#798 + sig { params(content: ::String, file: ::String).void } + def initialize(content, file:); end + + # source://rbi//lib/rbi/parser.rb#795 + sig { returns(::RBI::Sig) } + def current; end + + # source://rbi//lib/rbi/parser.rb#850 + sig { override.params(node: ::Prism::AssocNode).void } + def visit_assoc_node(node); end + + # source://rbi//lib/rbi/parser.rb#805 + sig { override.params(node: ::Prism::CallNode).void } + def visit_call_node(node); end +end + +# source://rbi//lib/rbi/parser.rb#153 +class RBI::Parser::TreeBuilder < ::RBI::Parser::Visitor + # source://rbi//lib/rbi/parser.rb#163 + sig { params(source: ::String, comments: T::Array[::Prism::Comment], file: ::String).void } + def initialize(source, comments:, file:); end + + # source://rbi//lib/rbi/parser.rb#160 + sig { returns(T.nilable(::Prism::Node)) } + def last_node; end + + # source://rbi//lib/rbi/parser.rb#157 + sig { returns(::RBI::Tree) } + def tree; end + + # source://rbi//lib/rbi/parser.rb#299 + sig { params(node: ::Prism::CallNode).void } + def visit_call_node(node); end + + # source://rbi//lib/rbi/parser.rb#176 + sig { override.params(node: ::Prism::ClassNode).void } + def visit_class_node(node); end + + # source://rbi//lib/rbi/parser.rb#208 + sig { params(node: T.any(::Prism::ConstantPathWriteNode, ::Prism::ConstantWriteNode)).void } + def visit_constant_assign(node); end + + # source://rbi//lib/rbi/parser.rb#201 + sig { override.params(node: ::Prism::ConstantPathWriteNode).void } + def visit_constant_path_write_node(node); end + + # source://rbi//lib/rbi/parser.rb#194 + sig { override.params(node: ::Prism::ConstantWriteNode).void } + def visit_constant_write_node(node); end + + # source://rbi//lib/rbi/parser.rb#241 + sig { override.params(node: ::Prism::DefNode).void } + def visit_def_node(node); end + + # source://rbi//lib/rbi/parser.rb#255 + sig { override.params(node: ::Prism::ModuleNode).void } + def visit_module_node(node); end + + # source://rbi//lib/rbi/parser.rb#272 + sig { override.params(node: ::Prism::ProgramNode).void } + def visit_program_node(node); end + + # source://rbi//lib/rbi/parser.rb#283 + sig { override.params(node: ::Prism::SingletonClassNode).void } + def visit_singleton_class_node(node); end + + private + + # Collect all the remaining comments within a node + # + # source://rbi//lib/rbi/parser.rb#467 + sig { params(node: ::Prism::Node).void } + def collect_dangling_comments(node); end + + # Collect all the remaining comments after visiting the tree + # + # source://rbi//lib/rbi/parser.rb#485 + sig { void } + def collect_orphan_comments; end + + # source://rbi//lib/rbi/parser.rb#508 + sig { returns(::RBI::Tree) } + def current_scope; end + + # source://rbi//lib/rbi/parser.rb#513 + sig { returns(T::Array[::RBI::Sig]) } + def current_sigs; end + + # source://rbi//lib/rbi/parser.rb#520 + sig { returns(T::Array[::RBI::Comment]) } + def current_sigs_comments; end + + # source://rbi//lib/rbi/parser.rb#527 + sig { params(node: ::Prism::Node).returns(T::Array[::RBI::Comment]) } + def node_comments(node); end + + # source://rbi//lib/rbi/parser.rb#545 + sig { params(node: ::Prism::Comment).returns(::RBI::Comment) } + def parse_comment(node); end + + # source://rbi//lib/rbi/parser.rb#574 + sig { params(node: T.nilable(::Prism::Node)).returns(T::Array[::RBI::Param]) } + def parse_params(node); end + + # source://rbi//lib/rbi/parser.rb#550 + sig { params(node: T.nilable(::Prism::Node)).returns(T::Array[::RBI::Arg]) } + def parse_send_args(node); end + + # source://rbi//lib/rbi/parser.rb#648 + sig { params(node: ::Prism::CallNode).returns(::RBI::Sig) } + def parse_sig(node); end + + # source://rbi//lib/rbi/parser.rb#658 + sig do + params( + node: T.any(::Prism::ConstantPathWriteNode, ::Prism::ConstantWriteNode) + ).returns(T.nilable(::RBI::Struct)) + end + def parse_struct(node); end + + # source://rbi//lib/rbi/parser.rb#708 + sig { params(send: ::Prism::CallNode).void } + def parse_tstruct_field(send); end + + # source://rbi//lib/rbi/parser.rb#745 + sig { params(name: ::String, node: ::Prism::Node).returns(::RBI::Visibility) } + def parse_visibility(name, node); end + + # source://rbi//lib/rbi/parser.rb#759 + sig { void } + def separate_header_comments; end + + # source://rbi//lib/rbi/parser.rb#769 + sig { void } + def set_root_tree_loc; end + + # source://rbi//lib/rbi/parser.rb#783 + sig { params(node: T.nilable(::Prism::Node)).returns(T::Boolean) } + def type_variable_definition?(node); end +end + +# source://rbi//lib/rbi/parser.rb#122 +class RBI::Parser::Visitor < ::Prism::Visitor + # source://rbi//lib/rbi/parser.rb#126 + sig { params(source: ::String, file: ::String).void } + def initialize(source, file:); end + + private + + # source://rbi//lib/rbi/parser.rb#136 + sig { params(node: ::Prism::Node).returns(::RBI::Loc) } + def node_loc(node); end + + # source://rbi//lib/rbi/parser.rb#141 + sig { params(node: T.nilable(::Prism::Node)).returns(T.nilable(::String)) } + def node_string(node); end + + # source://rbi//lib/rbi/parser.rb#148 + sig { params(node: ::Prism::Node).returns(::String) } + def node_string!(node); end +end + +# source://rbi//lib/rbi/printer.rb#7 class RBI::Printer < ::RBI::Visitor - # source://rbi//lib/rbi/printer.rb#28 + # source://rbi//lib/rbi/printer.rb#30 sig do params( out: T.any(::IO, ::StringIO), @@ -1421,87 +1446,316 @@ class RBI::Printer < ::RBI::Visitor end def initialize(out: T.unsafe(nil), indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#15 + # source://rbi//lib/rbi/printer.rb#17 sig { returns(::Integer) } def current_indent; end - # source://rbi//lib/rbi/printer.rb#46 + # source://rbi//lib/rbi/printer.rb#48 sig { void } def dedent; end # @return [Boolean] # - # source://rbi//lib/rbi/printer.rb#9 + # source://rbi//lib/rbi/printer.rb#11 def in_visibility_group; end # @return [Boolean] # - # source://rbi//lib/rbi/printer.rb#9 + # source://rbi//lib/rbi/printer.rb#11 def in_visibility_group=(_arg0); end # Printing # - # source://rbi//lib/rbi/printer.rb#41 + # source://rbi//lib/rbi/printer.rb#43 sig { void } def indent; end - # source://rbi//lib/rbi/printer.rb#18 + # source://rbi//lib/rbi/printer.rb#20 sig { returns(T.nilable(::Integer)) } def max_line_length; end - # source://rbi//lib/rbi/printer.rb#12 + # source://rbi//lib/rbi/printer.rb#14 sig { returns(T.nilable(::RBI::Node)) } def previous_node; end # Print a string without indentation nor `\n` at the end. # - # source://rbi//lib/rbi/printer.rb#52 + # source://rbi//lib/rbi/printer.rb#54 sig { params(string: ::String).void } def print(string); end - # source://rbi//lib/rbi/printer.rb#9 + # source://rbi//lib/rbi/printer.rb#11 sig { returns(T::Boolean) } def print_locs; end # @return [Boolean] # - # source://rbi//lib/rbi/printer.rb#9 + # source://rbi//lib/rbi/printer.rb#11 def print_locs=(_arg0); end # Print a string with indentation and `\n` at the end. # - # source://rbi//lib/rbi/printer.rb#72 + # source://rbi//lib/rbi/printer.rb#74 sig { params(string: ::String).void } def printl(string); end # Print a string without indentation but with a `\n` at the end. # - # source://rbi//lib/rbi/printer.rb#58 + # source://rbi//lib/rbi/printer.rb#60 sig { params(string: T.nilable(::String)).void } def printn(string = T.unsafe(nil)); end # Print a string with indentation but without a `\n` at the end. # - # source://rbi//lib/rbi/printer.rb#65 + # source://rbi//lib/rbi/printer.rb#67 sig { params(string: T.nilable(::String)).void } def printt(string = T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#83 - sig { override.params(node: T.nilable(::RBI::Node)).void } - def visit(node); end + # source://rbi//lib/rbi/printer.rb#80 + sig { override.params(nodes: T::Array[::RBI::Node]).void } + def visit_all(nodes); end + + # source://rbi//lib/rbi/printer.rb#91 + sig { override.params(file: ::RBI::File).void } + def visit_file(file); end + + private + + # source://rbi//lib/rbi/printer.rb#619 + sig { params(node: ::RBI::Node).returns(T::Boolean) } + def oneline?(node); end + + # source://rbi//lib/rbi/printer.rb#577 + sig { params(node: ::RBI::Node).void } + def print_blank_line_before(node); end + + # source://rbi//lib/rbi/printer.rb#587 + sig { params(node: ::RBI::Node).void } + def print_loc(node); end + + # source://rbi//lib/rbi/printer.rb#593 + sig { params(node: ::RBI::Param, last: T::Boolean).void } + def print_param_comment_leading_space(node, last:); end + + # source://rbi//lib/rbi/printer.rb#666 + sig { params(node: ::RBI::Sig).void } + def print_sig_as_block(node); end + + # source://rbi//lib/rbi/printer.rb#641 + sig { params(node: ::RBI::Sig).void } + def print_sig_as_line(node); end + + # source://rbi//lib/rbi/printer.rb#611 + sig { params(node: ::RBI::SigParam, last: T::Boolean).void } + def print_sig_param_comment_leading_space(node, last:); end + + # source://rbi//lib/rbi/printer.rb#722 + sig { params(node: ::RBI::Sig).returns(T::Array[::String]) } + def sig_modifiers(node); end + + # source://rbi//lib/rbi/printer.rb#417 + sig { override.params(node: ::RBI::Arg).void } + def visit_arg(node); end + + # source://rbi//lib/rbi/printer.rb#237 + sig { params(node: ::RBI::Attr).void } + def visit_attr(node); end + + # source://rbi//lib/rbi/printer.rb#222 + sig { override.params(node: ::RBI::AttrAccessor).void } + def visit_attr_accessor(node); end + + # source://rbi//lib/rbi/printer.rb#227 + sig { override.params(node: ::RBI::AttrReader).void } + def visit_attr_reader(node); end + + # source://rbi//lib/rbi/printer.rb#232 + sig { override.params(node: ::RBI::AttrWriter).void } + def visit_attr_writer(node); end + + # source://rbi//lib/rbi/printer.rb#126 + sig { override.params(node: ::RBI::BlankLine).void } + def visit_blank_line(node); end + + # source://rbi//lib/rbi/printer.rb#344 + sig { override.params(node: ::RBI::BlockParam).void } + def visit_block_param(node); end + + # source://rbi//lib/rbi/printer.rb#143 + sig { override.params(node: ::RBI::Class).void } + def visit_class(node); end + + # source://rbi//lib/rbi/printer.rb#110 + sig { override.params(node: ::RBI::Comment).void } + def visit_comment(node); end + + # source://rbi//lib/rbi/printer.rb#554 + sig { override.params(node: ::RBI::ConflictTree).void } + def visit_conflict_tree(node); end + + # source://rbi//lib/rbi/printer.rb#213 + sig { override.params(node: ::RBI::Const).void } + def visit_const(node); end + + # source://rbi//lib/rbi/printer.rb#354 + sig { override.params(node: ::RBI::Extend).void } + def visit_extend(node); end + + # source://rbi//lib/rbi/printer.rb#526 + sig { override.params(node: ::RBI::Group).void } + def visit_group(node); end + + # source://rbi//lib/rbi/printer.rb#512 + sig { override.params(node: ::RBI::Helper).void } + def visit_helper(node); end + + # source://rbi//lib/rbi/printer.rb#349 + sig { override.params(node: ::RBI::Include).void } + def visit_include(node); end + + # source://rbi//lib/rbi/printer.rb#422 + sig { override.params(node: ::RBI::KwArg).void } + def visit_kw_arg(node); end + + # source://rbi//lib/rbi/printer.rb#334 + sig { override.params(node: ::RBI::KwOptParam).void } + def visit_kw_opt_param(node); end + + # source://rbi//lib/rbi/printer.rb#329 + sig { override.params(node: ::RBI::KwParam).void } + def visit_kw_param(node); end + + # source://rbi//lib/rbi/printer.rb#339 + sig { override.params(node: ::RBI::KwRestParam).void } + def visit_kw_rest_param(node); end + + # source://rbi//lib/rbi/printer.rb#265 + sig { override.params(node: ::RBI::Method).void } + def visit_method(node); end + + # source://rbi//lib/rbi/printer.rb#521 + sig { override.params(node: ::RBI::MixesInClassMethods).void } + def visit_mixes_in_class_methods(node); end + + # source://rbi//lib/rbi/printer.rb#359 + sig { params(node: ::RBI::Mixin).void } + def visit_mixin(node); end + + # source://rbi//lib/rbi/printer.rb#138 + sig { override.params(node: ::RBI::Module).void } + def visit_module(node); end + + # source://rbi//lib/rbi/printer.rb#319 + sig { override.params(node: ::RBI::OptParam).void } + def visit_opt_param(node); end + + # source://rbi//lib/rbi/printer.rb#386 + sig { override.params(node: ::RBI::Private).void } + def visit_private(node); end + + # source://rbi//lib/rbi/printer.rb#381 + sig { override.params(node: ::RBI::Protected).void } + def visit_protected(node); end + + # source://rbi//lib/rbi/printer.rb#376 + sig { override.params(node: ::RBI::Public).void } + def visit_public(node); end + + # source://rbi//lib/rbi/printer.rb#314 + sig { override.params(node: ::RBI::ReqParam).void } + def visit_req_param(node); end + + # source://rbi//lib/rbi/printer.rb#545 + sig { override.params(node: ::RBI::RequiresAncestor).void } + def visit_requires_ancestor(node); end + + # source://rbi//lib/rbi/printer.rb#324 + sig { override.params(node: ::RBI::RestParam).void } + def visit_rest_param(node); end + + # source://rbi//lib/rbi/printer.rb#158 + sig { params(node: ::RBI::Scope).void } + def visit_scope(node); end + + # source://rbi//lib/rbi/printer.rb#203 + sig { params(node: ::RBI::Scope).void } + def visit_scope_body(node); end + + # source://rbi//lib/rbi/printer.rb#563 + sig { override.params(node: ::RBI::ScopeConflict).void } + def visit_scope_conflict(node); end + + # source://rbi//lib/rbi/printer.rb#168 + sig { params(node: ::RBI::Scope).void } + def visit_scope_header(node); end + + # source://rbi//lib/rbi/printer.rb#400 + sig { override.params(node: ::RBI::Send).void } + def visit_send(node); end + + # source://rbi//lib/rbi/printer.rb#427 + sig { override.params(node: ::RBI::Sig).void } + def visit_sig(node); end + + # source://rbi//lib/rbi/printer.rb#446 + sig { override.params(node: ::RBI::SigParam).void } + def visit_sig_param(node); end + + # source://rbi//lib/rbi/printer.rb#153 + sig { override.params(node: ::RBI::SingletonClass).void } + def visit_singleton_class(node); end + + # source://rbi//lib/rbi/printer.rb#148 + sig { override.params(node: ::RBI::Struct).void } + def visit_struct(node); end + + # source://rbi//lib/rbi/printer.rb#466 + sig { params(node: ::RBI::TStructField).void } + def visit_t_struct_field(node); end + + # source://rbi//lib/rbi/printer.rb#484 + sig { override.params(node: ::RBI::TEnum).void } + def visit_tenum(node); end + + # source://rbi//lib/rbi/printer.rb#489 + sig { override.params(node: ::RBI::TEnumBlock).void } + def visit_tenum_block(node); end + + # source://rbi//lib/rbi/printer.rb#131 + sig { override.params(node: ::RBI::Tree).void } + def visit_tree(node); end + + # source://rbi//lib/rbi/printer.rb#451 + sig { override.params(node: ::RBI::TStruct).void } + def visit_tstruct(node); end + + # source://rbi//lib/rbi/printer.rb#456 + sig { override.params(node: ::RBI::TStructConst).void } + def visit_tstruct_const(node); end + + # source://rbi//lib/rbi/printer.rb#461 + sig { override.params(node: ::RBI::TStructProp).void } + def visit_tstruct_prop(node); end + + # source://rbi//lib/rbi/printer.rb#503 + sig { override.params(node: ::RBI::TypeMember).void } + def visit_type_member(node); end - # source://rbi//lib/rbi/printer.rb#89 - sig { override.params(nodes: T::Array[::RBI::Node]).void } - def visit_all(nodes); end + # source://rbi//lib/rbi/printer.rb#391 + sig { params(node: ::RBI::Visibility).void } + def visit_visibility(node); end - # source://rbi//lib/rbi/printer.rb#78 - sig { params(file: ::RBI::File).void } - def visit_file(file); end + # source://rbi//lib/rbi/printer.rb#532 + sig { override.params(node: ::RBI::VisibilityGroup).void } + def visit_visibility_group(node); end end -# source://rbi//lib/rbi/model.rb#901 +# source://rbi//lib/rbi/printer.rb#5 +class RBI::PrinterError < ::RBI::Error; end + +# source://rbi//lib/rbi/model.rb#984 class RBI::Private < ::RBI::Visibility - # source://rbi//lib/rbi/model.rb#911 + # source://rbi//lib/rbi/model.rb#994 sig do params( loc: T.nilable(::RBI::Loc), @@ -1512,9 +1766,9 @@ class RBI::Private < ::RBI::Visibility def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end end -# source://rbi//lib/rbi/model.rb#885 +# source://rbi//lib/rbi/model.rb#968 class RBI::Protected < ::RBI::Visibility - # source://rbi//lib/rbi/model.rb#895 + # source://rbi//lib/rbi/model.rb#978 sig do params( loc: T.nilable(::RBI::Loc), @@ -1525,9 +1779,9 @@ class RBI::Protected < ::RBI::Visibility def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end end -# source://rbi//lib/rbi/model.rb#869 +# source://rbi//lib/rbi/model.rb#952 class RBI::Public < ::RBI::Visibility - # source://rbi//lib/rbi/model.rb#879 + # source://rbi//lib/rbi/model.rb#962 sig do params( loc: T.nilable(::RBI::Loc), @@ -1538,9 +1792,12 @@ class RBI::Public < ::RBI::Visibility def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end end -# source://rbi//lib/rbi/model.rb#571 +# source://rbi//lib/rbi/model.rb#5 +class RBI::ReplaceNodeError < ::RBI::Error; end + +# source://rbi//lib/rbi/model.rb#654 class RBI::ReqParam < ::RBI::Param - # source://rbi//lib/rbi/model.rb#582 + # source://rbi//lib/rbi/model.rb#665 sig do params( name: ::String, @@ -1551,39 +1808,35 @@ class RBI::ReqParam < ::RBI::Param end def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#588 + # source://rbi//lib/rbi/model.rb#671 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end end -# source://rbi//lib/rbi/model.rb#1368 +# source://rbi//lib/rbi/model.rb#1458 class RBI::RequiresAncestor < ::RBI::NodeWithComments include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#1381 + # source://rbi//lib/rbi/model.rb#1471 sig { params(name: ::String, loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void } def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#868 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/index.rb#159 + # source://rbi//lib/rbi/index.rb#163 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#1372 + # source://rbi//lib/rbi/model.rb#1462 sig { returns(::String) } def name; end - # source://rbi//lib/rbi/model.rb#1387 + # source://rbi//lib/rbi/model.rb#1477 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#620 +# source://rbi//lib/rbi/model.rb#703 class RBI::RestParam < ::RBI::Param - # source://rbi//lib/rbi/model.rb#631 + # source://rbi//lib/rbi/model.rb#714 sig do params( name: ::String, @@ -1594,19 +1847,11 @@ class RBI::RestParam < ::RBI::Param end def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#642 + # source://rbi//lib/rbi/model.rb#725 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#481 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#486 - sig { override.params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - - # source://rbi//lib/rbi/model.rb#637 + # source://rbi//lib/rbi/model.rb#720 sig { override.returns(::String) } def to_s; end end @@ -1655,11 +1900,26 @@ class RBI::Rewriters::Annotate < ::RBI::Visitor sig { params(node: ::RBI::NodeWithComments).void } def annotate_node(node); end - # source://rbi//lib/rbi/rewriters/annotate.rb#37 + # source://rbi//lib/rbi/rewriters/annotate.rb#38 sig { params(node: ::RBI::Node).returns(T::Boolean) } def root?(node); end end +# source://rbi//lib/rbi/rewriters/attr_to_methods.rb#22 +class RBI::Rewriters::AttrToMethods < ::RBI::Visitor + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#26 + sig { override.params(node: T.nilable(::RBI::Node)).void } + def visit(node); end + + private + + # @raise [ReplaceNodeError] + # + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#39 + sig { params(node: ::RBI::Node, with: T::Array[::RBI::Node]).void } + def replace(node, with:); end +end + # source://rbi//lib/rbi/rewriters/deannotate.rb#6 class RBI::Rewriters::Deannotate < ::RBI::Visitor # source://rbi//lib/rbi/rewriters/deannotate.rb#10 @@ -1677,11 +1937,89 @@ class RBI::Rewriters::Deannotate < ::RBI::Visitor def deannotate_node(node); end end -# source://rbi//lib/rbi/rewriters/group_nodes.rb#6 +# Take a gem version and filter out all RBI that is not relevant to that version based on @version annotations +# in comments. As an example: +# +# ~~~rb +# tree = Parser.parse_string(<<~RBI) +# class Foo +# # @version > 0.3.0 +# def bar +# end +# +# # @version <= 0.3.0 +# def bar(arg1) +# end +# end +# RBI +# +# Rewriters::FilterVersions.filter(tree, Gem::Version.new("0.3.1")) +# +# assert_equal(<<~RBI, tree.string) +# class Foo +# # @version > 0.3.0 +# def bar +# end +# end +# RBI +# ~~~ +# +# Supported operators: +# - equals `=` +# - not equals `!=` +# - greater than `>` +# - greater than or equal to `>=` +# - less than `<` +# - less than or equal to `<=` +# - pessimistic or twiddle-wakka`~>` +# +# And/or logic: +# - "And" logic: put multiple versions on the same line +# - e.g. `@version > 0.3.0, <1.0.0` means version must be greater than 0.3.0 AND less than 1.0.0 +# - "Or" logic: put multiple versions on subsequent lines +# - e.g. the following means version must be less than 0.3.0 OR greater than 1.0.0 +# ``` +# # @version < 0.3.0 +# # @version > 1.0.0 +# ``` +# Prerelease versions: +# - Prerelease versions are considered less than their non-prerelease counterparts +# - e.g. `0.4.0-prerelease` is less than `0.4.0` +# +# RBI with no versions: +# - RBI with no version annotations are automatically counted towards ALL versions +# +# source://rbi//lib/rbi/rewriters/filter_versions.rb#57 +class RBI::Rewriters::FilterVersions < ::RBI::Visitor + # source://rbi//lib/rbi/rewriters/filter_versions.rb#73 + sig { params(version: ::Gem::Version).void } + def initialize(version); end + + # source://rbi//lib/rbi/rewriters/filter_versions.rb#79 + sig { override.params(node: T.nilable(::RBI::Node)).void } + def visit(node); end + + class << self + # source://rbi//lib/rbi/rewriters/filter_versions.rb#66 + sig { params(tree: ::RBI::Tree, version: ::Gem::Version).void } + def filter(tree, version); end + end +end + +# source://rbi//lib/rbi/rewriters/filter_versions.rb#60 +RBI::Rewriters::FilterVersions::VERSION_PREFIX = T.let(T.unsafe(nil), String) + +# source://rbi//lib/rbi/rewriters/group_nodes.rb#8 class RBI::Rewriters::GroupNodes < ::RBI::Visitor - # source://rbi//lib/rbi/rewriters/group_nodes.rb#10 + # source://rbi//lib/rbi/rewriters/group_nodes.rb#12 sig { override.params(node: T.nilable(::RBI::Node)).void } def visit(node); end + + private + + # source://rbi//lib/rbi/rewriters/group_nodes.rb#36 + sig { params(node: ::RBI::Node).returns(::RBI::Group::Kind) } + def group_kind(node); end end # Merge two RBI trees together @@ -1720,20 +2058,20 @@ end # # source://rbi//lib/rbi/rewriters/merge_trees.rb#39 class RBI::Rewriters::Merge - # source://rbi//lib/rbi/rewriters/merge_trees.rb#66 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#70 sig { params(left_name: ::String, right_name: ::String, keep: ::RBI::Rewriters::Merge::Keep).void } def initialize(left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#75 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#79 sig { params(tree: ::RBI::Tree).void } def merge(tree); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#63 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#67 sig { returns(::RBI::MergeTree) } def tree; end class << self - # source://rbi//lib/rbi/rewriters/merge_trees.rb#51 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#54 sig do params( left: ::RBI::Tree, @@ -1749,19 +2087,19 @@ end # Used for logging / error displaying purpose # -# source://rbi//lib/rbi/rewriters/merge_trees.rb#82 +# source://rbi//lib/rbi/rewriters/merge_trees.rb#86 class RBI::Rewriters::Merge::Conflict < ::T::Struct const :left, ::RBI::Node const :right, ::RBI::Node const :left_name, ::String const :right_name, ::String - # source://rbi//lib/rbi/rewriters/merge_trees.rb#91 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#95 sig { returns(::String) } def to_s; end class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 def inherited(s); end end end @@ -1797,19 +2135,19 @@ end # end # ~~~ # -# source://rbi//lib/rbi/rewriters/merge_trees.rb#241 +# source://rbi//lib/rbi/rewriters/merge_trees.rb#245 class RBI::Rewriters::Merge::ConflictTreeMerger < ::RBI::Visitor - # source://rbi//lib/rbi/rewriters/merge_trees.rb#243 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#247 sig { override.params(node: T.nilable(::RBI::Node)).void } def visit(node); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#248 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#252 sig { override.params(nodes: T::Array[::RBI::Node]).void } def visit_all(nodes); end private - # source://rbi//lib/rbi/rewriters/merge_trees.rb#269 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#273 sig { params(left: ::RBI::Tree, right: ::RBI::Tree).void } def merge_conflict_trees(left, right); end end @@ -1823,9 +2161,9 @@ class RBI::Rewriters::Merge::Keep < ::T::Enum end end -# source://rbi//lib/rbi/rewriters/merge_trees.rb#96 +# source://rbi//lib/rbi/rewriters/merge_trees.rb#100 class RBI::Rewriters::Merge::TreeMerger < ::RBI::Visitor - # source://rbi//lib/rbi/rewriters/merge_trees.rb#103 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#107 sig do params( output: ::RBI::Tree, @@ -1836,33 +2174,33 @@ class RBI::Rewriters::Merge::TreeMerger < ::RBI::Visitor end def initialize(output, left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#100 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#104 sig { returns(T::Array[::RBI::Rewriters::Merge::Conflict]) } def conflicts; end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#115 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#119 sig { override.params(node: T.nilable(::RBI::Node)).void } def visit(node); end private - # source://rbi//lib/rbi/rewriters/merge_trees.rb#164 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#168 sig { returns(::RBI::Tree) } def current_scope; end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#181 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#185 sig { params(left: ::RBI::Scope, right: ::RBI::Scope).void } def make_conflict_scope(left, right); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#188 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#192 sig { params(left: ::RBI::Node, right: ::RBI::Node).void } def make_conflict_tree(left, right); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#169 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#173 sig { params(node: ::RBI::Node).returns(T.nilable(::RBI::Node)) } def previous_definition(node); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#200 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#204 sig { params(left: ::RBI::Scope, right: ::RBI::Scope).returns(::RBI::Scope) } def replace_scope_header(left, right); end end @@ -1926,38 +2264,38 @@ end # # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#48 class RBI::Rewriters::RemoveKnownDefinitions < ::RBI::Visitor - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#67 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#55 sig { params(index: ::RBI::Index).void } def initialize(index); end - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#64 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#52 sig { returns(T::Array[::RBI::Rewriters::RemoveKnownDefinitions::Operation]) } def operations; end - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#79 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#83 sig { override.params(node: T.nilable(::RBI::Node)).void } def visit(node); end - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#74 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#78 sig { params(nodes: T::Array[::RBI::Node]).void } def visit_all(nodes); end private - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#107 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#111 sig { params(node: ::RBI::Node, previous: ::RBI::Node).returns(T::Boolean) } def can_delete_node?(node, previous); end - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#125 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#129 sig { params(node: ::RBI::Node, previous: ::RBI::Node).void } def delete_node(node, previous); end - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#98 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#102 sig { params(node: ::RBI::Indexable).returns(T.nilable(::RBI::Node)) } def previous_definition_for(node); end class << self - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#57 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#70 sig do params( tree: ::RBI::Tree, @@ -1968,17 +2306,17 @@ class RBI::Rewriters::RemoveKnownDefinitions < ::RBI::Visitor end end -# source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#130 +# source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#134 class RBI::Rewriters::RemoveKnownDefinitions::Operation < ::T::Struct const :deleted_node, ::RBI::Node const :duplicate_of, ::RBI::Node - # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#137 + # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#141 sig { returns(::String) } def to_s; end class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 def inherited(s); end end end @@ -1991,19 +2329,19 @@ class RBI::Rewriters::SortNodes < ::RBI::Visitor private - # source://rbi//lib/rbi/rewriters/sort_nodes.rb#61 + # source://rbi//lib/rbi/rewriters/sort_nodes.rb#73 sig { params(kind: ::RBI::Group::Kind).returns(::Integer) } def group_rank(kind); end - # source://rbi//lib/rbi/rewriters/sort_nodes.rb#82 + # source://rbi//lib/rbi/rewriters/sort_nodes.rb#94 sig { params(node: ::RBI::Node).returns(T.nilable(::String)) } def node_name(node); end - # source://rbi//lib/rbi/rewriters/sort_nodes.rb#33 + # source://rbi//lib/rbi/rewriters/sort_nodes.rb#45 sig { params(node: ::RBI::Node).returns(::Integer) } def node_rank(node); end - # source://rbi//lib/rbi/rewriters/sort_nodes.rb#94 + # source://rbi//lib/rbi/rewriters/sort_nodes.rb#106 sig { params(node: ::RBI::Node).void } def sort_node_names!(node); end end @@ -2012,46 +2350,29 @@ end # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#172 +# source://rbi//lib/rbi/model.rb#178 class RBI::Scope < ::RBI::Tree include ::RBI::Indexable abstract! - # source://sorbet-runtime/0.5.10601/lib/types/private/abstract/declare.rb#37 - def initialize(*args, **_arg1, &blk); end - - # source://rbi//lib/rbi/printer.rb#240 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - # Duplicate `self` scope without its body # - # source://rbi//lib/rbi/rewriters/merge_trees.rb#350 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#358 sig { returns(T.self_type) } def dup_empty; end # @abstract # - # source://rbi//lib/rbi/model.rb#178 + # source://rbi//lib/rbi/model.rb#184 sig { abstract.returns(::String) } def fully_qualified_name; end - # source://rbi//lib/rbi/index.rb#89 + # source://rbi//lib/rbi/index.rb#93 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/printer.rb#254 - sig { params(v: ::RBI::Printer).void } - def print_body(v); end - - # @abstract - # - # source://rbi//lib/rbi/printer.rb#251 - sig { abstract.params(v: ::RBI::Printer).void } - def print_header(v); end - - # source://rbi//lib/rbi/model.rb#181 + # source://rbi//lib/rbi/model.rb#187 sig { override.returns(::String) } def to_s; end end @@ -2069,37 +2390,38 @@ end # end # ~~~ # -# source://rbi//lib/rbi/rewriters/merge_trees.rb#617 +# source://rbi//lib/rbi/rewriters/merge_trees.rb#624 class RBI::ScopeConflict < ::RBI::Tree - # source://rbi//lib/rbi/rewriters/merge_trees.rb#631 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#641 sig { params(left: ::RBI::Scope, right: ::RBI::Scope, left_name: ::String, right_name: ::String).void } def initialize(left:, right:, left_name: T.unsafe(nil), right_name: T.unsafe(nil)); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#640 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#621 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#628 sig { returns(::RBI::Scope) } def left; end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#656 - sig { override.returns(T::Boolean) } - def oneline?; end + # source://rbi//lib/rbi/rewriters/merge_trees.rb#631 + sig { returns(::String) } + def left_name; end # @return [Scope] # - # source://rbi//lib/rbi/rewriters/merge_trees.rb#621 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#628 def right; end + + # @return [String] + # + # source://rbi//lib/rbi/rewriters/merge_trees.rb#631 + def right_name; end end # Sends # -# source://rbi//lib/rbi/model.rb#919 +# source://rbi//lib/rbi/model.rb#1002 class RBI::Send < ::RBI::NodeWithComments include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#937 + # source://rbi//lib/rbi/model.rb#1020 sig do params( method: ::String, @@ -2111,44 +2433,40 @@ class RBI::Send < ::RBI::NodeWithComments end def initialize(method, args = T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#945 + # source://rbi//lib/rbi/model.rb#1028 sig { params(arg: ::RBI::Arg).void } def <<(arg); end - # source://rbi//lib/rbi/model.rb#950 + # source://rbi//lib/rbi/model.rb#1033 sig { params(other: T.nilable(::Object)).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#590 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#926 + # source://rbi//lib/rbi/model.rb#1009 sig { returns(T::Array[::RBI::Arg]) } def args; end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#519 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#531 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/index.rb#179 + # source://rbi//lib/rbi/index.rb#193 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#923 + # source://rbi//lib/rbi/model.rb#1006 sig { returns(::String) } def method; end - # source://rbi//lib/rbi/model.rb#955 + # source://rbi//lib/rbi/model.rb#1038 sig { returns(::String) } def to_s; end end # Sorbet's sigs # -# source://rbi//lib/rbi/model.rb#1019 +# source://rbi//lib/rbi/model.rb#1102 class RBI::Sig < ::RBI::Node - # source://rbi//lib/rbi/model.rb#1051 + # source://rbi//lib/rbi/model.rb#1134 sig do params( params: T::Array[::RBI::SigParam], @@ -2165,139 +2483,87 @@ class RBI::Sig < ::RBI::Node end def initialize(params: T.unsafe(nil), return_type: T.unsafe(nil), is_abstract: T.unsafe(nil), is_override: T.unsafe(nil), is_overridable: T.unsafe(nil), is_final: T.unsafe(nil), type_params: T.unsafe(nil), checked: T.unsafe(nil), loc: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#1076 + # source://rbi//lib/rbi/model.rb#1159 sig { params(param: ::RBI::SigParam).void } def <<(param); end - # source://rbi//lib/rbi/model.rb#1081 + # source://rbi//lib/rbi/model.rb#1169 sig { params(other: ::Object).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#631 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end + # source://rbi//lib/rbi/model.rb#1164 + sig { params(name: ::String, type: ::String).void } + def add_param(name, type); end - # source://rbi//lib/rbi/model.rb#1035 + # source://rbi//lib/rbi/model.rb#1118 sig { returns(T.nilable(::Symbol)) } def checked; end # @return [Symbol, nil] # - # source://rbi//lib/rbi/model.rb#1035 + # source://rbi//lib/rbi/model.rb#1118 def checked=(_arg0); end - # source://rbi//lib/rbi/printer.rb#654 - sig { returns(T::Boolean) } - def inline_params?; end - - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 sig { returns(T::Boolean) } def is_abstract; end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 def is_abstract=(_arg0); end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 def is_final; end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 def is_final=(_arg0); end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 def is_overridable; end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 def is_overridable=(_arg0); end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 def is_override; end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#1029 + # source://rbi//lib/rbi/model.rb#1112 def is_override=(_arg0); end - # source://rbi//lib/rbi/printer.rb#649 - sig { override.returns(T::Boolean) } - def oneline?; end - - # source://rbi//lib/rbi/model.rb#1023 + # source://rbi//lib/rbi/model.rb#1106 sig { returns(T::Array[::RBI::SigParam]) } def params; end - # source://rbi//lib/rbi/model.rb#1026 + # source://rbi//lib/rbi/model.rb#1109 sig { returns(T.nilable(::String)) } def return_type; end # @return [String, nil] # - # source://rbi//lib/rbi/model.rb#1026 + # source://rbi//lib/rbi/model.rb#1109 def return_type=(_arg0); end - # source://rbi//lib/rbi/model.rb#1032 + # source://rbi//lib/rbi/model.rb#1115 sig { returns(T::Array[::String]) } def type_params; end - - private - - # source://rbi//lib/rbi/printer.rb#696 - sig { params(v: ::RBI::Printer).void } - def print_as_block(v); end - - # source://rbi//lib/rbi/printer.rb#672 - sig { params(v: ::RBI::Printer).void } - def print_as_line(v); end - - # source://rbi//lib/rbi/printer.rb#661 - sig { returns(T::Array[::String]) } - def sig_modifiers; end -end - -# source://rbi//lib/rbi/parser.rb#635 -class RBI::SigBuilder < ::RBI::ASTVisitor - # source://rbi//lib/rbi/parser.rb#649 - sig { void } - def initialize; end - - # source://rbi//lib/rbi/parser.rb#646 - sig { returns(::RBI::Sig) } - def current; end - - # @return [Sig] - # - # source://rbi//lib/rbi/parser.rb#646 - def current=(_arg0); end - - # source://rbi//lib/rbi/parser.rb#655 - sig { override.params(node: T.nilable(::AST::Node)).void } - def visit(node); end - - # source://rbi//lib/rbi/parser.rb#664 - sig { params(node: ::AST::Node).void } - def visit_send(node); end - - class << self - # source://rbi//lib/rbi/parser.rb#639 - sig { params(node: ::AST::Node).returns(::RBI::Sig) } - def build(node); end - end end -# source://rbi//lib/rbi/model.rb#1089 +# source://rbi//lib/rbi/model.rb#1178 class RBI::SigParam < ::RBI::NodeWithComments - # source://rbi//lib/rbi/model.rb#1104 + # source://rbi//lib/rbi/model.rb#1193 sig do params( name: ::String, @@ -2309,35 +2575,23 @@ class RBI::SigParam < ::RBI::NodeWithComments end def initialize(name, type, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#1112 + # source://rbi//lib/rbi/model.rb#1201 sig { params(other: ::Object).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#749 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#762 - sig { returns(T::Array[::String]) } - def comments_lines; end - - # source://rbi//lib/rbi/model.rb#1093 + # source://rbi//lib/rbi/model.rb#1182 sig { returns(::String) } def name; end - # source://rbi//lib/rbi/printer.rb#754 - sig { params(v: ::RBI::Printer, last: T::Boolean).void } - def print_comment_leading_space(v, last:); end - # @return [String] # - # source://rbi//lib/rbi/model.rb#1093 + # source://rbi//lib/rbi/model.rb#1182 def type; end end -# source://rbi//lib/rbi/model.rb#245 +# source://rbi//lib/rbi/model.rb#253 class RBI::SingletonClass < ::RBI::Scope - # source://rbi//lib/rbi/model.rb#255 + # source://rbi//lib/rbi/model.rb#263 sig do params( loc: T.nilable(::RBI::Loc), @@ -2347,18 +2601,14 @@ class RBI::SingletonClass < ::RBI::Scope end def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#261 + # source://rbi//lib/rbi/model.rb#269 sig { override.returns(::String) } def fully_qualified_name; end - - # source://rbi//lib/rbi/printer.rb#319 - sig { override.params(v: ::RBI::Printer).void } - def print_header(v); end end -# source://rbi//lib/rbi/model.rb#266 +# source://rbi//lib/rbi/model.rb#274 class RBI::Struct < ::RBI::Scope - # source://rbi//lib/rbi/model.rb#288 + # source://rbi//lib/rbi/model.rb#296 sig do params( name: ::String, @@ -2371,51 +2621,47 @@ class RBI::Struct < ::RBI::Scope end def initialize(name, members: T.unsafe(nil), keyword_init: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#388 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#396 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#297 + # source://rbi//lib/rbi/model.rb#305 sig { override.returns(::String) } def fully_qualified_name; end - # source://rbi//lib/rbi/model.rb#276 + # source://rbi//lib/rbi/model.rb#284 sig { returns(T::Boolean) } def keyword_init; end # @return [Boolean] # - # source://rbi//lib/rbi/model.rb#276 + # source://rbi//lib/rbi/model.rb#284 def keyword_init=(_arg0); end - # source://rbi//lib/rbi/model.rb#273 + # source://rbi//lib/rbi/model.rb#281 sig { returns(T::Array[::Symbol]) } def members; end # @return [Array] # - # source://rbi//lib/rbi/model.rb#273 + # source://rbi//lib/rbi/model.rb#281 def members=(_arg0); end - # source://rbi//lib/rbi/model.rb#270 + # source://rbi//lib/rbi/model.rb#278 sig { returns(::String) } def name; end # @return [String] # - # source://rbi//lib/rbi/model.rb#270 + # source://rbi//lib/rbi/model.rb#278 def name=(_arg0); end - - # source://rbi//lib/rbi/printer.rb#298 - sig { override.params(v: ::RBI::Printer).void } - def print_header(v); end end # Sorbet's T::Enum # -# source://rbi//lib/rbi/model.rb#1230 +# source://rbi//lib/rbi/model.rb#1319 class RBI::TEnum < ::RBI::Class - # source://rbi//lib/rbi/model.rb#1241 + # source://rbi//lib/rbi/model.rb#1330 sig do params( name: ::String, @@ -2427,11 +2673,11 @@ class RBI::TEnum < ::RBI::Class def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end end -# source://rbi//lib/rbi/model.rb#1247 +# source://rbi//lib/rbi/model.rb#1336 class RBI::TEnumBlock < ::RBI::NodeWithComments include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#1261 + # source://rbi//lib/rbi/model.rb#1350 sig do params( names: T::Array[::String], @@ -2442,40 +2688,36 @@ class RBI::TEnumBlock < ::RBI::NodeWithComments end def initialize(names = T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#1273 + # source://rbi//lib/rbi/model.rb#1362 sig { params(name: ::String).void } def <<(name); end - # source://rbi//lib/rbi/printer.rb#793 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#1268 + # source://rbi//lib/rbi/model.rb#1357 sig { returns(T::Boolean) } def empty?; end - # source://rbi//lib/rbi/index.rb#209 + # source://rbi//lib/rbi/index.rb#223 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#546 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#558 sig { override.params(other: ::RBI::Node).void } def merge_with(other); end - # source://rbi//lib/rbi/model.rb#1251 + # source://rbi//lib/rbi/model.rb#1340 sig { returns(T::Array[::String]) } def names; end - # source://rbi//lib/rbi/model.rb#1278 + # source://rbi//lib/rbi/model.rb#1367 sig { override.returns(::String) } def to_s; end end # Sorbet's T::Struct # -# source://rbi//lib/rbi/model.rb#1119 +# source://rbi//lib/rbi/model.rb#1208 class RBI::TStruct < ::RBI::Class - # source://rbi//lib/rbi/model.rb#1130 + # source://rbi//lib/rbi/model.rb#1219 sig do params( name: ::String, @@ -2487,11 +2729,11 @@ class RBI::TStruct < ::RBI::Class def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end end -# source://rbi//lib/rbi/model.rb#1168 +# source://rbi//lib/rbi/model.rb#1257 class RBI::TStructConst < ::RBI::TStructField include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#1181 + # source://rbi//lib/rbi/model.rb#1270 sig do params( name: ::String, @@ -2504,30 +2746,30 @@ class RBI::TStructConst < ::RBI::TStructField end def initialize(name, type, default: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#537 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#549 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#1187 + # source://rbi//lib/rbi/model.rb#1276 sig { override.returns(T::Array[::String]) } def fully_qualified_names; end - # source://rbi//lib/rbi/index.rb#189 + # source://rbi//lib/rbi/index.rb#203 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#1193 + # source://rbi//lib/rbi/model.rb#1282 sig { override.returns(::String) } def to_s; end end # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#1136 +# source://rbi//lib/rbi/model.rb#1225 class RBI::TStructField < ::RBI::NodeWithComments abstract! - # source://rbi//lib/rbi/model.rb#1157 + # source://rbi//lib/rbi/model.rb#1246 sig do params( name: ::String, @@ -2539,54 +2781,50 @@ class RBI::TStructField < ::RBI::NodeWithComments end def initialize(name, type, default: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil)); end - # source://rbi//lib/rbi/printer.rb#771 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/rewriters/merge_trees.rb#528 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#540 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#1146 + # source://rbi//lib/rbi/model.rb#1235 sig { returns(T.nilable(::String)) } def default; end # @return [String, nil] # - # source://rbi//lib/rbi/model.rb#1146 + # source://rbi//lib/rbi/model.rb#1235 def default=(_arg0); end # @abstract # - # source://rbi//lib/rbi/model.rb#1165 + # source://rbi//lib/rbi/model.rb#1254 sig { abstract.returns(T::Array[::String]) } def fully_qualified_names; end - # source://rbi//lib/rbi/model.rb#1143 + # source://rbi//lib/rbi/model.rb#1232 sig { returns(::String) } def name; end # @return [String] # - # source://rbi//lib/rbi/model.rb#1143 + # source://rbi//lib/rbi/model.rb#1232 def name=(_arg0); end # @return [String] # - # source://rbi//lib/rbi/model.rb#1143 + # source://rbi//lib/rbi/model.rb#1232 def type; end # @return [String] # - # source://rbi//lib/rbi/model.rb#1143 + # source://rbi//lib/rbi/model.rb#1232 def type=(_arg0); end end -# source://rbi//lib/rbi/model.rb#1198 +# source://rbi//lib/rbi/model.rb#1287 class RBI::TStructProp < ::RBI::TStructField include ::RBI::Indexable - # source://rbi//lib/rbi/model.rb#1211 + # source://rbi//lib/rbi/model.rb#1300 sig do params( name: ::String, @@ -2599,26 +2837,26 @@ class RBI::TStructProp < ::RBI::TStructField end def initialize(name, type, default: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#559 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#572 sig { override.params(other: ::RBI::Node).returns(T::Boolean) } def compatible_with?(other); end - # source://rbi//lib/rbi/model.rb#1217 + # source://rbi//lib/rbi/model.rb#1306 sig { override.returns(T::Array[::String]) } def fully_qualified_names; end - # source://rbi//lib/rbi/index.rb#199 + # source://rbi//lib/rbi/index.rb#213 sig { override.returns(T::Array[::String]) } def index_ids; end - # source://rbi//lib/rbi/model.rb#1223 + # source://rbi//lib/rbi/model.rb#1312 sig { override.returns(::String) } def to_s; end end -# source://rbi//lib/rbi/model.rb#102 +# source://rbi//lib/rbi/model.rb#108 class RBI::Tree < ::RBI::NodeWithComments - # source://rbi//lib/rbi/model.rb#115 + # source://rbi//lib/rbi/model.rb#121 sig do params( loc: T.nilable(::RBI::Loc), @@ -2628,23 +2866,19 @@ class RBI::Tree < ::RBI::NodeWithComments end def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/model.rb#122 + # source://rbi//lib/rbi/model.rb#128 sig { params(node: ::RBI::Node).void } def <<(node); end - # source://rbi//lib/rbi/printer.rb#224 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - # source://rbi//lib/rbi/rewriters/add_sig_templates.rb#66 sig { params(with_todo_comment: T::Boolean).void } def add_sig_templates!(with_todo_comment: T.unsafe(nil)); end - # source://rbi//lib/rbi/rewriters/annotate.rb#48 + # source://rbi//lib/rbi/rewriters/annotate.rb#49 sig { params(annotation: ::String, annotate_scopes: T::Boolean, annotate_properties: T::Boolean).void } def annotate!(annotation, annotate_scopes: T.unsafe(nil), annotate_properties: T.unsafe(nil)); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#38 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#38 sig do params( name: ::String, @@ -2654,44 +2888,45 @@ class RBI::Tree < ::RBI::NodeWithComments end def create_class(name, superclass_name: T.unsafe(nil), &block); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#45 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#45 sig { params(name: ::String, value: ::String).void } def create_constant(name, value:); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#55 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#55 sig { params(name: ::String).void } def create_extend(name); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#50 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#50 sig { params(name: ::String).void } def create_include(name); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#89 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#90 sig do params( name: ::String, parameters: T::Array[::RBI::TypedParam], - return_type: ::String, + return_type: T.nilable(::String), class_method: T::Boolean, visibility: ::RBI::Visibility, - comments: T::Array[::RBI::Comment] + comments: T::Array[::RBI::Comment], + block: T.nilable(T.proc.params(node: ::RBI::Method).void) ).void end - def create_method(name, parameters: T.unsafe(nil), return_type: T.unsafe(nil), class_method: T.unsafe(nil), visibility: T.unsafe(nil), comments: T.unsafe(nil)); end + def create_method(name, parameters: T.unsafe(nil), return_type: T.unsafe(nil), class_method: T.unsafe(nil), visibility: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#60 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#60 sig { params(name: ::String).void } def create_mixes_in_class_methods(name); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#25 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#25 sig { params(name: ::String, block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)).returns(::RBI::Scope) } def create_module(name, &block); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#9 - sig { params(constant: ::Module, block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)).void } + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#9 + sig { params(constant: ::Module, block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)).returns(::RBI::Scope) } def create_path(constant, &block); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#74 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#74 sig do params( name: ::String, @@ -2704,23 +2939,27 @@ class RBI::Tree < ::RBI::NodeWithComments end def create_type_variable(name, type:, variance: T.unsafe(nil), fixed: T.unsafe(nil), upper: T.unsafe(nil), lower: T.unsafe(nil)); end - # source://rbi//lib/rbi/rewriters/deannotate.rb#40 + # source://rbi//lib/rbi/rewriters/deannotate.rb#41 sig { params(annotation: ::String).void } def deannotate!(annotation); end - # source://rbi//lib/rbi/model.rb#128 + # source://rbi//lib/rbi/model.rb#134 sig { returns(T::Boolean) } def empty?; end - # source://rbi//lib/rbi/rewriters/group_nodes.rb#38 + # source://rbi//lib/rbi/rewriters/filter_versions.rb#118 + sig { params(version: ::Gem::Version).void } + def filter_versions!(version); end + + # source://rbi//lib/rbi/rewriters/group_nodes.rb#81 sig { void } def group_nodes!; end - # source://rbi//lib/rbi/index.rb#64 + # source://rbi//lib/rbi/index.rb#68 sig { returns(::RBI::Index) } def index; end - # source://rbi//lib/rbi/rewriters/merge_trees.rb#318 + # source://rbi//lib/rbi/rewriters/merge_trees.rb#324 sig do params( other: ::RBI::Tree, @@ -2731,155 +2970,42 @@ class RBI::Tree < ::RBI::NodeWithComments end def merge(other, left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end - # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#45 + # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#46 sig { void } def nest_non_public_methods!; end - # source://rbi//lib/rbi/rewriters/nest_singleton_methods.rb#35 + # source://rbi//lib/rbi/rewriters/nest_singleton_methods.rb#36 sig { void } def nest_singleton_methods!; end - # source://rbi//lib/rbi/model.rb#106 + # source://rbi//lib/rbi/model.rb#112 sig { returns(T::Array[::RBI::Node]) } def nodes; end - # source://rbi//lib/rbi/printer.rb#231 - sig { override.returns(T::Boolean) } - def oneline?; end + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#53 + sig { void } + def replace_attributes_with_methods!; end - # source://rbi//lib/rbi/rewriters/sort_nodes.rb#107 + # source://rbi//lib/rbi/rewriters/sort_nodes.rb#119 sig { void } def sort_nodes!; end private - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#116 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#123 sig { params(node: ::RBI::Node).returns(::RBI::Node) } def create_node(node); end - # source://tapioca/0.10.5/lib/tapioca/rbi_ext/model.rb#111 + # source://tapioca/0.16.0/lib/tapioca/rbi_ext/model.rb#118 sig { returns(T::Hash[::String, ::RBI::Node]) } def nodes_cache; end end -# source://rbi//lib/rbi/parser.rb#156 -class RBI::TreeBuilder < ::RBI::ASTVisitor - # source://rbi//lib/rbi/parser.rb#172 - sig do - params( - file: ::String, - comments: T::Array[::Parser::Source::Comment], - nodes_comments_assoc: T::Hash[::Parser::Source::Map, T::Array[::Parser::Source::Comment]] - ).void - end - def initialize(file:, comments: T.unsafe(nil), nodes_comments_assoc: T.unsafe(nil)); end - - # source://rbi//lib/rbi/parser.rb#163 - sig { returns(T.nilable(::AST::Node)) } - def last_node; end - - # source://rbi//lib/rbi/parser.rb#187 - sig { void } - def post_process; end - - # source://rbi//lib/rbi/parser.rb#160 - sig { returns(::RBI::Tree) } - def tree; end - - # source://rbi//lib/rbi/parser.rb#193 - sig { override.params(node: T.nilable(::Object)).void } - def visit(node); end - - private - - # source://rbi//lib/rbi/parser.rb#546 - sig { void } - def assoc_dangling_comments; end - - # source://rbi//lib/rbi/parser.rb#527 - sig { returns(::RBI::Tree) } - def current_scope; end - - # source://rbi//lib/rbi/parser.rb#532 - sig { returns(T::Array[::RBI::Sig]) } - def current_sigs; end - - # source://rbi//lib/rbi/parser.rb#539 - sig { returns(T::Array[::RBI::Comment]) } - def current_sigs_comments; end - - # source://rbi//lib/rbi/parser.rb#516 - sig { params(node: ::AST::Node).returns(T::Array[::RBI::Comment]) } - def node_comments(node); end - - # source://rbi//lib/rbi/parser.rb#511 - sig { params(node: ::AST::Node).returns(::RBI::Loc) } - def node_loc(node); end - - # source://rbi//lib/rbi/parser.rb#402 - sig { params(node: ::AST::Node).returns(T.nilable(::RBI::Node)) } - def parse_block(node); end - - # source://rbi//lib/rbi/parser.rb#249 - sig { params(node: ::AST::Node).returns(::RBI::Node) } - def parse_const_assign(node); end - - # source://rbi//lib/rbi/parser.rb#263 - sig { params(node: ::AST::Node).returns(::RBI::Method) } - def parse_def(node); end - - # source://rbi//lib/rbi/parser.rb#486 - sig { params(node: ::AST::Node).returns(::RBI::TEnumBlock) } - def parse_enum(node); end - - # source://rbi//lib/rbi/parser.rb#290 - sig { params(node: ::AST::Node).returns(::RBI::Param) } - def parse_param(node); end - - # source://rbi//lib/rbi/parser.rb#503 - sig { params(node: ::AST::Node).returns(::RBI::RequiresAncestor) } - def parse_requires_ancestor(node); end - - # source://rbi//lib/rbi/parser.rb#229 - sig { params(node: ::AST::Node).returns(::RBI::Scope) } - def parse_scope(node); end - - # source://rbi//lib/rbi/parser.rb#318 - sig { params(node: ::AST::Node).returns(T.nilable(::RBI::Node)) } - def parse_send(node); end - - # source://rbi//lib/rbi/parser.rb#385 - sig { params(node: ::AST::Node).returns(T::Array[::RBI::Arg]) } - def parse_send_args(node); end - - # source://rbi//lib/rbi/parser.rb#479 - sig { params(node: ::AST::Node).returns(::RBI::Sig) } - def parse_sig(node); end - - # source://rbi//lib/rbi/parser.rb#424 - sig { params(node: ::AST::Node).returns(::RBI::Struct) } - def parse_struct(node); end - - # source://rbi//lib/rbi/parser.rb#463 - sig { params(node: ::AST::Node).returns([::String, ::String, T.nilable(::String)]) } - def parse_tstruct_prop(node); end - - # source://rbi//lib/rbi/parser.rb#564 - sig { void } - def separate_header_comments; end - - # source://rbi//lib/rbi/parser.rb#586 - sig { void } - def set_root_tree_loc; end - - # source://rbi//lib/rbi/parser.rb#418 - sig { params(node: ::AST::Node).returns(T::Boolean) } - def struct_definition?(node); end -end - -# source://rbi//lib/rbi/model.rb#1311 +# source://rbi//lib/rbi/model.rb#1400 class RBI::TypeMember < ::RBI::NodeWithComments - # source://rbi//lib/rbi/model.rb#1326 + include ::RBI::Indexable + + # source://rbi//lib/rbi/model.rb#1415 sig do params( name: ::String, @@ -2891,30 +3017,41 @@ class RBI::TypeMember < ::RBI::NodeWithComments end def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi//lib/rbi/printer.rb#810 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#1334 + # source://rbi//lib/rbi/model.rb#1423 sig { returns(::String) } def fully_qualified_name; end - # source://rbi//lib/rbi/model.rb#1315 + # source://rbi//lib/rbi/index.rb#183 + sig { override.returns(T::Array[::String]) } + def index_ids; end + + # source://rbi//lib/rbi/model.rb#1404 sig { returns(::String) } def name; end - # source://rbi//lib/rbi/model.rb#1340 + # source://rbi//lib/rbi/model.rb#1430 sig { override.returns(::String) } def to_s; end # @return [String] # - # source://rbi//lib/rbi/model.rb#1315 + # source://rbi//lib/rbi/model.rb#1404 def value; end end +# source://rbi//lib/rbi/rewriters/attr_to_methods.rb#5 +class RBI::UnexpectedMultipleSigsError < ::RBI::Error + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#10 + sig { params(node: ::RBI::Node).void } + def initialize(node); end + + # source://rbi//lib/rbi/rewriters/attr_to_methods.rb#7 + sig { returns(::RBI::Node) } + def node; end +end + # source://rbi//lib/rbi/parser.rb#20 -class RBI::UnexpectedParserError < ::StandardError +class RBI::UnexpectedParserError < ::RBI::Error # source://rbi//lib/rbi/parser.rb#27 sig { params(parent_exception: ::Exception, last_location: ::RBI::Loc).void } def initialize(parent_exception, last_location); end @@ -2935,74 +3072,234 @@ RBI::VERSION = T.let(T.unsafe(nil), String) # # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/model.rb#833 +# source://rbi//lib/rbi/model.rb#916 class RBI::Visibility < ::RBI::NodeWithComments abstract! - # source://rbi//lib/rbi/model.rb#843 + # source://rbi//lib/rbi/model.rb#926 sig { params(visibility: ::Symbol, loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void } def initialize(visibility, loc: T.unsafe(nil), comments: T.unsafe(nil)); end - # source://rbi//lib/rbi/model.rb#849 + # source://rbi//lib/rbi/model.rb#932 sig { params(other: ::RBI::Visibility).returns(T::Boolean) } def ==(other); end - # source://rbi//lib/rbi/printer.rb#577 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/model.rb#864 + # source://rbi//lib/rbi/model.rb#947 sig { returns(T::Boolean) } def private?; end - # source://rbi//lib/rbi/model.rb#859 + # source://rbi//lib/rbi/model.rb#942 sig { returns(T::Boolean) } def protected?; end - # source://rbi//lib/rbi/model.rb#854 + # source://rbi//lib/rbi/model.rb#937 sig { returns(T::Boolean) } def public?; end - # source://rbi//lib/rbi/model.rb#840 + # source://rbi//lib/rbi/model.rb#923 sig { returns(::Symbol) } def visibility; end end -# source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#51 +# source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#52 class RBI::VisibilityGroup < ::RBI::Tree - # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#58 + # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#59 sig { params(visibility: ::RBI::Visibility).void } def initialize(visibility); end - # source://rbi//lib/rbi/printer.rb#846 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi//lib/rbi/printer.rb#859 - sig { override.returns(T::Boolean) } - def oneline?; end - - # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#55 + # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#56 sig { returns(::RBI::Visibility) } def visibility; end end # @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. # -# source://rbi//lib/rbi/visitor.rb#5 +# source://rbi//lib/rbi/visitor.rb#7 class RBI::Visitor abstract! - # source://sorbet-runtime/0.5.10601/lib/types/private/abstract/declare.rb#37 - def initialize(*args, **_arg1, &blk); end - - # @abstract - # - # source://rbi//lib/rbi/visitor.rb#12 - sig { abstract.params(node: T.nilable(::RBI::Node)).void } + # source://rbi//lib/rbi/visitor.rb#14 + sig { params(node: T.nilable(::RBI::Node)).void } def visit(node); end - # source://rbi//lib/rbi/visitor.rb#15 + # source://rbi//lib/rbi/visitor.rb#108 sig { params(nodes: T::Array[::RBI::Node]).void } def visit_all(nodes); end + + # source://rbi//lib/rbi/visitor.rb#113 + sig { params(file: ::RBI::File).void } + def visit_file(file); end + + private + + # source://rbi//lib/rbi/visitor.rb#195 + sig { params(node: ::RBI::Arg).void } + def visit_arg(node); end + + # source://rbi//lib/rbi/visitor.rb#144 + sig { params(node: ::RBI::AttrAccessor).void } + def visit_attr_accessor(node); end + + # source://rbi//lib/rbi/visitor.rb#147 + sig { params(node: ::RBI::AttrReader).void } + def visit_attr_reader(node); end + + # source://rbi//lib/rbi/visitor.rb#150 + sig { params(node: ::RBI::AttrWriter).void } + def visit_attr_writer(node); end + + # source://rbi//lib/rbi/visitor.rb#123 + sig { params(node: ::RBI::BlankLine).void } + def visit_blank_line(node); end + + # source://rbi//lib/rbi/visitor.rb#174 + sig { params(node: ::RBI::BlockParam).void } + def visit_block_param(node); end + + # source://rbi//lib/rbi/visitor.rb#129 + sig { params(node: ::RBI::Class).void } + def visit_class(node); end + + # source://rbi//lib/rbi/visitor.rb#120 + sig { params(node: ::RBI::Comment).void } + def visit_comment(node); end + + # source://rbi//lib/rbi/visitor.rb#240 + sig { params(node: ::RBI::ConflictTree).void } + def visit_conflict_tree(node); end + + # source://rbi//lib/rbi/visitor.rb#141 + sig { params(node: ::RBI::Const).void } + def visit_const(node); end + + # source://rbi//lib/rbi/visitor.rb#180 + sig { params(node: ::RBI::Extend).void } + def visit_extend(node); end + + # source://rbi//lib/rbi/visitor.rb#234 + sig { params(node: ::RBI::Group).void } + def visit_group(node); end + + # source://rbi//lib/rbi/visitor.rb#222 + sig { params(node: ::RBI::Helper).void } + def visit_helper(node); end + + # source://rbi//lib/rbi/visitor.rb#177 + sig { params(node: ::RBI::Include).void } + def visit_include(node); end + + # source://rbi//lib/rbi/visitor.rb#198 + sig { params(node: ::RBI::KwArg).void } + def visit_kw_arg(node); end + + # source://rbi//lib/rbi/visitor.rb#168 + sig { params(node: ::RBI::KwOptParam).void } + def visit_kw_opt_param(node); end + + # source://rbi//lib/rbi/visitor.rb#165 + sig { params(node: ::RBI::KwParam).void } + def visit_kw_param(node); end + + # source://rbi//lib/rbi/visitor.rb#171 + sig { params(node: ::RBI::KwRestParam).void } + def visit_kw_rest_param(node); end + + # source://rbi//lib/rbi/visitor.rb#153 + sig { params(node: ::RBI::Method).void } + def visit_method(node); end + + # source://rbi//lib/rbi/visitor.rb#228 + sig { params(node: ::RBI::MixesInClassMethods).void } + def visit_mixes_in_class_methods(node); end + + # source://rbi//lib/rbi/visitor.rb#126 + sig { params(node: ::RBI::Module).void } + def visit_module(node); end + + # source://rbi//lib/rbi/visitor.rb#159 + sig { params(node: ::RBI::OptParam).void } + def visit_opt_param(node); end + + # source://rbi//lib/rbi/visitor.rb#189 + sig { params(node: ::RBI::Private).void } + def visit_private(node); end + + # source://rbi//lib/rbi/visitor.rb#186 + sig { params(node: ::RBI::Protected).void } + def visit_protected(node); end + + # source://rbi//lib/rbi/visitor.rb#183 + sig { params(node: ::RBI::Public).void } + def visit_public(node); end + + # source://rbi//lib/rbi/visitor.rb#156 + sig { params(node: ::RBI::ReqParam).void } + def visit_req_param(node); end + + # source://rbi//lib/rbi/visitor.rb#231 + sig { params(node: ::RBI::RequiresAncestor).void } + def visit_requires_ancestor(node); end + + # source://rbi//lib/rbi/visitor.rb#162 + sig { params(node: ::RBI::RestParam).void } + def visit_rest_param(node); end + + # source://rbi//lib/rbi/visitor.rb#243 + sig { params(node: ::RBI::ScopeConflict).void } + def visit_scope_conflict(node); end + + # source://rbi//lib/rbi/visitor.rb#192 + sig { params(node: ::RBI::Send).void } + def visit_send(node); end + + # source://rbi//lib/rbi/visitor.rb#201 + sig { params(node: ::RBI::Sig).void } + def visit_sig(node); end + + # source://rbi//lib/rbi/visitor.rb#204 + sig { params(node: ::RBI::SigParam).void } + def visit_sig_param(node); end + + # source://rbi//lib/rbi/visitor.rb#132 + sig { params(node: ::RBI::SingletonClass).void } + def visit_singleton_class(node); end + + # source://rbi//lib/rbi/visitor.rb#135 + sig { params(node: ::RBI::Struct).void } + def visit_struct(node); end + + # source://rbi//lib/rbi/visitor.rb#216 + sig { params(node: ::RBI::TEnum).void } + def visit_tenum(node); end + + # source://rbi//lib/rbi/visitor.rb#219 + sig { params(node: ::RBI::TEnumBlock).void } + def visit_tenum_block(node); end + + # source://rbi//lib/rbi/visitor.rb#138 + sig { params(node: ::RBI::Tree).void } + def visit_tree(node); end + + # source://rbi//lib/rbi/visitor.rb#207 + sig { params(node: ::RBI::TStruct).void } + def visit_tstruct(node); end + + # source://rbi//lib/rbi/visitor.rb#210 + sig { params(node: ::RBI::TStructConst).void } + def visit_tstruct_const(node); end + + # source://rbi//lib/rbi/visitor.rb#213 + sig { params(node: ::RBI::TStructProp).void } + def visit_tstruct_prop(node); end + + # source://rbi//lib/rbi/visitor.rb#225 + sig { params(node: ::RBI::TypeMember).void } + def visit_type_member(node); end + + # source://rbi//lib/rbi/visitor.rb#237 + sig { params(node: ::RBI::VisibilityGroup).void } + def visit_visibility_group(node); end end + +# source://rbi//lib/rbi/visitor.rb#5 +class RBI::VisitorError < ::RBI::Error; end diff --git a/sorbet/rbi/gems/rbs@2.8.4.rbi b/sorbet/rbi/gems/rbs@2.8.4.rbi index 7e4a636fa..0dcf40598 100644 --- a/sorbet/rbi/gems/rbs@2.8.4.rbi +++ b/sorbet/rbi/gems/rbs@2.8.4.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rbs` gem. # Please instead update this file by running `bin/tapioca gem rbs`. + # source://rbs//lib/rbs/namespace.rb#120 module Kernel # source://rbs//lib/rbs/namespace.rb#121 diff --git a/sorbet/rbi/gems/rbzip2@0.3.0.rbi b/sorbet/rbi/gems/rbzip2@0.3.0.rbi index 003a7ecbb..5c114e548 100644 --- a/sorbet/rbi/gems/rbzip2@0.3.0.rbi +++ b/sorbet/rbi/gems/rbzip2@0.3.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rbzip2` gem. # Please instead update this file by running `bin/tapioca gem rbzip2`. + # source://rbzip2//lib/rbzip2.rb#6 module RBzip2 class << self diff --git a/sorbet/rbi/gems/rdoc@6.7.0.rbi b/sorbet/rbi/gems/rdoc@6.7.0.rbi new file mode 100644 index 000000000..ad2e9bf7b --- /dev/null +++ b/sorbet/rbi/gems/rdoc@6.7.0.rbi @@ -0,0 +1,12721 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `rdoc` gem. +# Please instead update this file by running `bin/tapioca gem rdoc`. + + +module ERB::Escape + private + + def html_escape(_arg0); end + + class << self + def html_escape(_arg0); end + end +end + +# RDoc produces documentation for Ruby source files by parsing the source and +# extracting the definition for classes, modules, methods, includes and +# requires. It associates these with optional documentation contained in an +# immediately preceding comment block then renders the result using an output +# formatter. +# +# For a simple introduction to writing or generating documentation using RDoc +# see the README. +# +# == Roadmap +# +# If you think you found a bug in RDoc see CONTRIBUTING@Bugs +# +# If you want to use RDoc to create documentation for your Ruby source files, +# see RDoc::Markup and refer to rdoc --help for command line usage. +# +# If you want to set the default markup format see +# RDoc::Markup@Supported+Formats +# +# If you want to store rdoc configuration in your gem (such as the default +# markup format) see RDoc::Options@Saved+Options +# +# If you want to write documentation for Ruby files see RDoc::Parser::Ruby +# +# If you want to write documentation for extensions written in C see +# RDoc::Parser::C +# +# If you want to generate documentation using rake see RDoc::Task. +# +# If you want to drive RDoc programmatically, see RDoc::RDoc. +# +# If you want to use the library to format text blocks into HTML or other +# formats, look at RDoc::Markup. +# +# If you want to make an RDoc plugin such as a generator or directive handler +# see RDoc::RDoc. +# +# If you want to write your own output generator see RDoc::Generator. +# +# If you want an overview of how RDoc works see CONTRIBUTING +# +# == Credits +# +# RDoc is currently being maintained by Eric Hodel . +# +# Dave Thomas is the original author of RDoc. +# +# * The Ruby parser in rdoc/parse.rb is based heavily on the outstanding +# work of Keiju ISHITSUKA of Nippon Rational Inc, who produced the Ruby +# parser for irb and the rtags package. +# +# source://rdoc//lib/rdoc.rb#58 +module RDoc + class << self + # Searches and returns the directory for settings. + # + # 1. $HOME/.rdoc directory, if it exists. + # 2. The +rdoc+ directory under the path specified by the + # +XDG_DATA_HOME+ environment variable, if it is set. + # 3. $HOME/.local/share/rdoc directory. + # + # Other than the home directory, the containing directory will be + # created automatically. + # + # source://rdoc//lib/rdoc.rb#134 + def home; end + + # Loads the best available YAML library. + # + # source://rdoc//lib/rdoc.rb#107 + def load_yaml; end + end +end + +# Represent an alias, which is an old_name/new_name pair associated with a +# particular context +# -- +# TODO implement Alias as a proxy to a method/attribute, inheriting from +# MethodAttr +# +# source://rdoc//lib/rdoc/alias.rb#9 +class RDoc::Alias < ::RDoc::CodeObject + # Creates a new Alias with a token stream of +text+ that aliases +old_name+ + # to +new_name+, has +comment+ and is a +singleton+ context. + # + # @return [Alias] a new instance of Alias + # + # source://rdoc//lib/rdoc/alias.rb#37 + def initialize(text, old_name, new_name, comment, singleton = T.unsafe(nil)); end + + # Order by #singleton then #new_name + # + # source://rdoc//lib/rdoc/alias.rb#50 + def <=>(other); end + + # HTML fragment reference for this alias + # + # source://rdoc//lib/rdoc/alias.rb#57 + def aref; end + + # Full old name including namespace + # + # source://rdoc//lib/rdoc/alias.rb#65 + def full_old_name; end + + # HTML id-friendly version of +#new_name+. + # + # source://rdoc//lib/rdoc/alias.rb#72 + def html_name; end + + # source://rdoc//lib/rdoc/alias.rb#76 + def inspect; end + + # Aliased method's name + # + # source://rdoc//lib/rdoc/alias.rb#14 + def name; end + + # '::' for the alias of a singleton method/attribute, '#' for instance-level. + # + # source://rdoc//lib/rdoc/alias.rb#87 + def name_prefix; end + + # Aliased method's name + # + # source://rdoc//lib/rdoc/alias.rb#14 + def new_name; end + + # Aliasee method's name + # + # source://rdoc//lib/rdoc/alias.rb#21 + def old_name; end + + # New name with prefix '::' or '#'. + # + # source://rdoc//lib/rdoc/alias.rb#101 + def pretty_name; end + + # New name with prefix '::' or '#'. + # + # source://rdoc//lib/rdoc/alias.rb#101 + def pretty_new_name; end + + # Old name with prefix '::' or '#'. + # + # source://rdoc//lib/rdoc/alias.rb#94 + def pretty_old_name; end + + # Is this an alias declared in a singleton context? + # + # source://rdoc//lib/rdoc/alias.rb#26 + def singleton; end + + # Is this an alias declared in a singleton context? + # + # source://rdoc//lib/rdoc/alias.rb#26 + def singleton=(_arg0); end + + # Source file token stream + # + # source://rdoc//lib/rdoc/alias.rb#31 + def text; end + + # source://rdoc//lib/rdoc/alias.rb#107 + def to_s; end +end + +# AnyMethod is the base class for objects representing methods +# +# source://rdoc//lib/rdoc/any_method.rb#5 +class RDoc::AnyMethod < ::RDoc::MethodAttr + include ::RDoc::TokenStream + + # Creates a new AnyMethod with a token stream +text+ and +name+ + # + # @return [AnyMethod] a new instance of AnyMethod + # + # source://rdoc//lib/rdoc/any_method.rb#46 + def initialize(text, name); end + + # Adds +an_alias+ as an alias for this method in +context+. + # + # source://rdoc//lib/rdoc/any_method.rb#59 + def add_alias(an_alias, context = T.unsafe(nil)); end + + # Prefix for +aref+ is 'method'. + # + # source://rdoc//lib/rdoc/any_method.rb#76 + def aref_prefix; end + + # The call_seq or the param_seq with method name, if there is no call_seq. + # + # Use this for displaying a method's argument lists. + # + # source://rdoc//lib/rdoc/any_method.rb#85 + def arglists; end + + # The C function that implements this method (if it was defined in a C file) + # + # source://rdoc//lib/rdoc/any_method.rb#27 + def c_function; end + + # The C function that implements this method (if it was defined in a C file) + # + # source://rdoc//lib/rdoc/any_method.rb#27 + def c_function=(_arg0); end + + # Different ways to call this method + # + # source://rdoc//lib/rdoc/any_method.rb#96 + def call_seq; end + + # Sets the different ways you can call this method. If an empty +call_seq+ + # is given nil is assumed. + # + # See also #param_seq + # + # source://rdoc//lib/rdoc/any_method.rb#112 + def call_seq=(call_seq); end + + # If true this method uses +super+ to call a superclass version + # + # source://rdoc//lib/rdoc/any_method.rb#39 + def calls_super; end + + # If true this method uses +super+ to call a superclass version + # + # source://rdoc//lib/rdoc/any_method.rb#39 + def calls_super=(_arg0); end + + # Don't rename \#initialize to \::new + # + # source://rdoc//lib/rdoc/any_method.rb#22 + def dont_rename_initialize; end + + # Don't rename \#initialize to \::new + # + # source://rdoc//lib/rdoc/any_method.rb#22 + def dont_rename_initialize=(_arg0); end + + # Whether the method has a call-seq. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/any_method.rb#121 + def has_call_seq?; end + + # Loads is_alias_for from the internal name. Returns nil if the alias + # cannot be found. + # + # source://rdoc//lib/rdoc/any_method.rb#129 + def is_alias_for; end + + # Dumps this AnyMethod for use by ri. See also #marshal_load + # + # source://rdoc//lib/rdoc/any_method.rb#147 + def marshal_dump; end + + # Loads this AnyMethod from +array+. For a loaded AnyMethod the following + # methods will return cached values: + # + # * #full_name + # * #parent_name + # + # source://rdoc//lib/rdoc/any_method.rb#184 + def marshal_load(array); end + + # Method name + # + # If the method has no assigned name, it extracts it from #call_seq. + # + # source://rdoc//lib/rdoc/any_method.rb#233 + def name; end + + # A list of this method's method and yield parameters. +call-seq+ params + # are preferred over parsed method and block params. + # + # source://rdoc//lib/rdoc/any_method.rb#246 + def param_list; end + + # Pretty parameter list for this method. If the method's parameters were + # given by +call-seq+ it is preferred over the parsed values. + # + # source://rdoc//lib/rdoc/any_method.rb#278 + def param_seq; end + + # Parameters for this method + # + # source://rdoc//lib/rdoc/any_method.rb#34 + def params; end + + # Parameters for this method + # + # source://rdoc//lib/rdoc/any_method.rb#34 + def params=(_arg0); end + + # The section title of the method (if defined in a C file via +:category:+) + # + # source://rdoc//lib/rdoc/any_method.rb#30 + def section_title; end + + # The section title of the method (if defined in a C file via +:category:+) + # + # source://rdoc//lib/rdoc/any_method.rb#30 + def section_title=(_arg0); end + + # Whether to skip the method description, true for methods that have + # aliases with a call-seq that doesn't include the method name. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/any_method.rb#310 + def skip_description?; end + + # Sets the store for this method and its referenced code objects. + # + # source://rdoc//lib/rdoc/any_method.rb#317 + def store=(store); end + + # For methods that +super+, find the superclass method that would be called. + # + # source://rdoc//lib/rdoc/any_method.rb#326 + def superclass_method; end + + protected + + # call_seq without deduplication and alias lookup. + # + # source://rdoc//lib/rdoc/any_method.rb#345 + def _call_seq; end + + private + + # call_seq with alias examples information removed, if this + # method is an alias method. + # + # source://rdoc//lib/rdoc/any_method.rb#355 + def deduplicate_call_seq(call_seq); end +end + +# An attribute created by \#attr, \#attr_reader, \#attr_writer or +# \#attr_accessor +# +# source://rdoc//lib/rdoc/attr.rb#6 +class RDoc::Attr < ::RDoc::MethodAttr + # Creates a new Attr with body +text+, +name+, read/write status +rw+ and + # +comment+. +singleton+ marks this as a class attribute. + # + # @return [Attr] a new instance of Attr + # + # source://rdoc//lib/rdoc/attr.rb#25 + def initialize(text, name, rw, comment, singleton = T.unsafe(nil)); end + + # Attributes are equal when their names, singleton and rw are identical + # + # source://rdoc//lib/rdoc/attr.rb#36 + def ==(other); end + + # Add +an_alias+ as an attribute in +context+. + # + # source://rdoc//lib/rdoc/attr.rb#46 + def add_alias(an_alias, context); end + + # The #aref prefix for attributes + # + # source://rdoc//lib/rdoc/attr.rb#61 + def aref_prefix; end + + # Attributes never call super. See RDoc::AnyMethod#calls_super + # + # An RDoc::Attr can show up in the method list in some situations (see + # Gem::ConfigFile) + # + # source://rdoc//lib/rdoc/attr.rb#71 + def calls_super; end + + # Returns attr_reader, attr_writer or attr_accessor as appropriate. + # + # source://rdoc//lib/rdoc/attr.rb#78 + def definition; end + + # source://rdoc//lib/rdoc/attr.rb#86 + def inspect; end + + # Dumps this Attr for use by ri. See also #marshal_load + # + # source://rdoc//lib/rdoc/attr.rb#102 + def marshal_dump; end + + # Loads this Attr from +array+. For a loaded Attr the following + # methods will return cached values: + # + # * #full_name + # * #parent_name + # + # source://rdoc//lib/rdoc/attr.rb#124 + def marshal_load(array); end + + # source://rdoc//lib/rdoc/attr.rb#151 + def pretty_print(q); end + + # Is the attribute readable ('R'), writable ('W') or both ('RW')? + # + # source://rdoc//lib/rdoc/attr.rb#19 + def rw; end + + # Is the attribute readable ('R'), writable ('W') or both ('RW')? + # + # source://rdoc//lib/rdoc/attr.rb#19 + def rw=(_arg0); end + + # source://rdoc//lib/rdoc/attr.rb#162 + def to_s; end + + # Attributes do not have token streams. + # + # An RDoc::Attr can show up in the method list in some situations (see + # Gem::ConfigFile) + # + # source://rdoc//lib/rdoc/attr.rb#172 + def token_stream; end +end + +# ClassModule is the base class for objects representing either a class or a +# module. +# +# source://rdoc//lib/rdoc/class_module.rb#6 +class RDoc::ClassModule < ::RDoc::Context + # Creates a new ClassModule with +name+ with optional +superclass+ + # + # This is a constructor for subclasses, and must never be called directly. + # + # @return [ClassModule] a new instance of ClassModule + # + # source://rdoc//lib/rdoc/class_module.rb#111 + def initialize(name, superclass = T.unsafe(nil)); end + + # Adds +comment+ to this ClassModule's list of comments at +location+. This + # method is preferred over #comment= since it allows ri data to be updated + # across multiple runs. + # + # source://rdoc//lib/rdoc/class_module.rb#127 + def add_comment(comment, location); end + + # source://rdoc//lib/rdoc/class_module.rb#148 + def add_things(my_things, other_things); end + + # Ancestors list for this ClassModule: the list of included modules + # (classes will add their superclass if any). + # + # Returns the included classes or modules, not the includes + # themselves. The returned values are either String or + # RDoc::NormalModule instances (see RDoc::Include#module). + # + # The values are returned in reverse order of their inclusion, + # which is the order suitable for searching methods/attributes + # in the ancestors. The superclass, if any, comes last. + # + # source://rdoc//lib/rdoc/class_module.rb#171 + def ancestors; end + + # HTML fragment reference for this module or class. See + # RDoc::NormalClass#aref and RDoc::NormalModule#aref + # + # source://rdoc//lib/rdoc/class_module.rb#183 + def aref; end + + # @raise [NotImplementedError] + # + # source://rdoc//lib/rdoc/class_module.rb#175 + def aref_prefix; end + + # Clears the comment. Used by the Ruby parser. + # + # source://rdoc//lib/rdoc/class_module.rb#195 + def clear_comment; end + + # This method is deprecated, use #add_comment instead. + # + # Appends +comment+ to the current comment, but separated by a rule. Works + # more like +=. + # + # source://rdoc//lib/rdoc/class_module.rb#205 + def comment=(comment); end + + # Comment and the location it came from. Use #add_comment to add comments + # + # source://rdoc//lib/rdoc/class_module.rb#35 + def comment_location; end + + # Comment and the location it came from. Use #add_comment to add comments + # + # source://rdoc//lib/rdoc/class_module.rb#35 + def comment_location=(_arg0); end + + # Prepares this ClassModule for use by a generator. + # + # See RDoc::Store#complete + # + # source://rdoc//lib/rdoc/class_module.rb#223 + def complete(min_visibility); end + + # Constants that are aliases for this class or module + # + # source://rdoc//lib/rdoc/class_module.rb#30 + def constant_aliases; end + + # Constants that are aliases for this class or module + # + # source://rdoc//lib/rdoc/class_module.rb#30 + def constant_aliases=(_arg0); end + + # Handy wrapper for marking up this class or module's comment + # + # source://rdoc//lib/rdoc/generator/markup.rb#131 + def description; end + + # source://rdoc//lib/rdoc/class_module.rb#37 + def diagram; end + + # source://rdoc//lib/rdoc/class_module.rb#37 + def diagram=(_arg0); end + + # Ancestors list for this ClassModule: the list of included modules + # (classes will add their superclass if any). + # + # Returns the included classes or modules, not the includes + # themselves. The returned values are either String or + # RDoc::NormalModule instances (see RDoc::Include#module). + # + # The values are returned in reverse order of their inclusion, + # which is the order suitable for searching methods/attributes + # in the ancestors. The superclass, if any, comes last. + # + # Ancestors of this class or module only + # + # source://rdoc//lib/rdoc/class_module.rb#171 + def direct_ancestors; end + + # Does this ClassModule or any of its methods have document_self set? + # + # source://rdoc//lib/rdoc/class_module.rb#233 + def document_self_or_methods; end + + # Does this class or module have a comment with content or is + # #received_nodoc true? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/class_module.rb#241 + def documented?; end + + # Iterates the ancestors of this class or module for which an + # RDoc::ClassModule exists. + # + # source://rdoc//lib/rdoc/class_module.rb#251 + def each_ancestor; end + + # Looks for a symbol in the #ancestors. See Context#find_local_symbol. + # + # source://rdoc//lib/rdoc/class_module.rb#264 + def find_ancestor_local_symbol(symbol); end + + # Finds a class or module with +name+ in this namespace or its descendants + # + # source://rdoc//lib/rdoc/class_module.rb#276 + def find_class_named(name); end + + # Return the fully qualified name of this class or module + # + # source://rdoc//lib/rdoc/class_module.rb#289 + def full_name; end + + # Class or module this constant is an alias for + # + # source://rdoc//lib/rdoc/class_module.rb#42 + def is_alias_for; end + + # Class or module this constant is an alias for + # + # source://rdoc//lib/rdoc/class_module.rb#42 + def is_alias_for=(_arg0); end + + # TODO: filter included items by #display? + # + # source://rdoc//lib/rdoc/class_module.rb#300 + def marshal_dump; end + + # source://rdoc//lib/rdoc/class_module.rb#346 + def marshal_load(array); end + + # Merges +class_module+ into this ClassModule. + # + # The data in +class_module+ is preferred over the receiver. + # + # source://rdoc//lib/rdoc/class_module.rb#435 + def merge(class_module); end + + # Merges collection +mine+ with +other+ preferring other. +other_files+ is + # used to help determine which items should be deleted. + # + # Yields whether the item should be added or removed (true or false) and the + # item to be added or removed. + # + # merge_collections things, other.things, other.in_files do |add, thing| + # if add then + # # add the thing + # else + # # remove the thing + # end + # end + # + # source://rdoc//lib/rdoc/class_module.rb#519 + def merge_collections(mine, other, other_files, &block); end + + # Merges the comments in this ClassModule with the comments in the other + # ClassModule +cm+. + # + # source://rdoc//lib/rdoc/class_module.rb#531 + def merge_sections(cm); end + + # Does this object represent a module? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/class_module.rb#570 + def module?; end + + # Allows overriding the initial name. + # + # Used for modules and classes that are constant aliases. + # + # source://rdoc//lib/rdoc/class_module.rb#579 + def name=(new_name); end + + # Name to use to generate the url: + # modules and classes that are aliases for another + # module or class return the name of the latter. + # + # source://rdoc//lib/rdoc/class_module.rb#622 + def name_for_path; end + + # Returns the classes and modules that are not constants + # aliasing another class or module. For use by formatters + # only (caches its result). + # + # source://rdoc//lib/rdoc/class_module.rb#631 + def non_aliases; end + + # Parses +comment_location+ into an RDoc::Markup::Document composed of + # multiple RDoc::Markup::Documents with their file set. + # + # source://rdoc//lib/rdoc/class_module.rb#587 + def parse(comment_location); end + + # Path to this class or module for use with HTML generator output. + # + # source://rdoc//lib/rdoc/class_module.rb#613 + def path; end + + # Updates the child modules or classes of class/module +parent+ by + # deleting the ones that have been removed from the documentation. + # + # +parent_hash+ is either parent.modules_hash or + # parent.classes_hash and +all_hash+ is ::all_modules_hash or + # ::all_classes_hash. + # + # source://rdoc//lib/rdoc/class_module.rb#643 + def remove_nodoc_children; end + + # source://rdoc//lib/rdoc/class_module.rb#657 + def remove_things(my_things, other_files); end + + # Search record used by RDoc::Generator::JsonIndex + # + # source://rdoc//lib/rdoc/class_module.rb#672 + def search_record; end + + # Sets the store for this class or module and its contained code objects. + # + # source://rdoc//lib/rdoc/class_module.rb#687 + def store=(store); end + + # Get the superclass of this class. Attempts to retrieve the superclass + # object, returns the name if it is not known. + # + # source://rdoc//lib/rdoc/class_module.rb#701 + def superclass; end + + # Set the superclass of this class to +superclass+ + # + # @raise [NoMethodError] + # + # source://rdoc//lib/rdoc/class_module.rb#708 + def superclass=(superclass); end + + # source://rdoc//lib/rdoc/class_module.rb#713 + def to_s; end + + # 'module' or 'class' + # + # source://rdoc//lib/rdoc/class_module.rb#724 + def type; end + + # Updates the child modules & classes by replacing the ones that are + # aliases through a constant. + # + # The aliased module/class is replaced in the children and in + # RDoc::Store#modules_hash or RDoc::Store#classes_hash + # by a copy that has RDoc::ClassModule#is_alias_for set to + # the aliased module/class, and this copy is added to #aliases + # of the aliased module/class. + # + # Formatters can use the #non_aliases method to retrieve children that + # are not aliases, for instance to list the namespace content, since + # the aliased modules are included in the constants of the class/module, + # that are listed separately. + # + # source://rdoc//lib/rdoc/class_module.rb#743 + def update_aliases; end + + # Deletes from #extends those whose module has been removed from the + # documentation. + # -- + # FIXME: like update_includes, extends are not reliably removed + # + # source://rdoc//lib/rdoc/class_module.rb#791 + def update_extends; end + + # Deletes from #includes those whose module has been removed from the + # documentation. + # -- + # FIXME: includes are not reliably removed, see _possible_bug test case + # + # source://rdoc//lib/rdoc/class_module.rb#776 + def update_includes; end + + class << self + # Return a RDoc::ClassModule of class +class_type+ that is a copy + # of module +module+. Used to promote modules to classes. + # -- + # TODO move to RDoc::NormalClass (I think) + # + # source://rdoc//lib/rdoc/class_module.rb#50 + def from_module(class_type, mod); end + end +end + +# Base class for the RDoc code tree. +# +# We contain the common stuff for contexts (which are containers) and other +# elements (methods, attributes and so on) +# +# Here's the tree of the CodeObject subclasses: +# +# * RDoc::Context +# * RDoc::TopLevel +# * RDoc::ClassModule +# * RDoc::AnonClass (never used so far) +# * RDoc::NormalClass +# * RDoc::NormalModule +# * RDoc::SingleClass +# * RDoc::MethodAttr +# * RDoc::Attr +# * RDoc::AnyMethod +# * RDoc::GhostMethod +# * RDoc::MetaMethod +# * RDoc::Alias +# * RDoc::Constant +# * RDoc::Mixin +# * RDoc::Require +# * RDoc::Include +# +# source://rdoc//lib/rdoc/code_object.rb#28 +class RDoc::CodeObject + include ::RDoc::Text + include ::RDoc::Generator::Markup + + # Creates a new CodeObject that will document itself and its children + # + # @return [CodeObject] a new instance of CodeObject + # + # source://rdoc//lib/rdoc/code_object.rb#102 + def initialize; end + + # Our comment + # + # source://rdoc//lib/rdoc/code_object.rb#35 + def comment; end + + # Replaces our comment with +comment+, unless it is empty. + # + # source://rdoc//lib/rdoc/code_object.rb#135 + def comment=(comment); end + + # Should this CodeObject be displayed in output? + # + # A code object should be displayed if: + # + # * The item didn't have a nodoc or wasn't in a container that had nodoc + # * The item wasn't ignored + # * The item has documentation and was not suppressed + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/code_object.rb#163 + def display?; end + + # Do we document our children? + # + # source://rdoc//lib/rdoc/code_object.rb#40 + def document_children; end + + # Enables or disables documentation of this CodeObject's children unless it + # has been turned off by :enddoc: + # + # source://rdoc//lib/rdoc/code_object.rb#172 + def document_children=(document_children); end + + # Do we document ourselves? + # + # source://rdoc//lib/rdoc/code_object.rb#45 + def document_self; end + + # Enables or disables documentation of this CodeObject unless it has been + # turned off by :enddoc:. If the argument is +nil+ it means the + # + # source://rdoc//lib/rdoc/code_object.rb#183 + def document_self=(document_self); end + + # Does this object have a comment with content or is #received_nodoc true? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/code_object.rb#194 + def documented?; end + + # Are we done documenting (ie, did we come across a :enddoc:)? + # + # source://rdoc//lib/rdoc/code_object.rb#50 + def done_documenting; end + + # Turns documentation on/off, and turns on/off #document_self + # and #document_children. + # + # Once documentation has been turned off (by +:enddoc:+), + # the object will refuse to turn #document_self or + # will have no effect in the current file. + # + # source://rdoc//lib/rdoc/code_object.rb#207 + def done_documenting=(value); end + + # Yields each parent of this CodeObject. See also + # RDoc::ClassModule#each_ancestor + # + # source://rdoc//lib/rdoc/code_object.rb#218 + def each_parent; end + + # Which file this code object was defined in + # + # source://rdoc//lib/rdoc/code_object.rb#55 + def file; end + + # File name where this CodeObject was found. + # + # See also RDoc::Context#in_files + # + # source://rdoc//lib/rdoc/code_object.rb#233 + def file_name; end + + # Force documentation of this CodeObject + # + # source://rdoc//lib/rdoc/code_object.rb#60 + def force_documentation; end + + # Force the documentation of this object unless documentation + # has been turned off by :enddoc: + # -- + # HACK untested, was assigning to an ivar + # + # source://rdoc//lib/rdoc/code_object.rb#245 + def force_documentation=(value); end + + # Sets the full_name overriding any computed full name. + # + # Set to +nil+ to clear RDoc's cached value + # + # source://rdoc//lib/rdoc/code_object.rb#254 + def full_name=(full_name); end + + # Use this to ignore a CodeObject and all its children until found again + # (#record_location is called). An ignored item will not be displayed in + # documentation. + # + # See github issue #55 + # + # The ignored status is temporary in order to allow implementation details + # to be hidden. At the end of processing a file RDoc allows all classes + # and modules to add new documentation to previously created classes. + # + # If a class was ignored (via stopdoc) then reopened later with additional + # documentation it should be displayed. If a class was ignored and never + # reopened it should not be displayed. The ignore flag allows this to + # occur. + # + # source://rdoc//lib/rdoc/code_object.rb#274 + def ignore; end + + # Has this class been ignored? + # + # See also #ignore + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/code_object.rb#287 + def ignored?; end + + # Initializes state for visibility of this CodeObject and its children. + # + # source://rdoc//lib/rdoc/code_object.rb#121 + def initialize_visibility; end + + # Line in #file where this CodeObject was defined + # + # source://rdoc//lib/rdoc/code_object.rb#65 + def line; end + + # Line in #file where this CodeObject was defined + # + # source://rdoc//lib/rdoc/code_object.rb#65 + def line=(_arg0); end + + # Hash of arbitrary metadata for this CodeObject + # + # source://rdoc//lib/rdoc/code_object.rb#70 + def metadata; end + + # The options instance from the store this CodeObject is attached to, or a + # default options instance if the CodeObject is not attached. + # + # This is used by Text#snippet + # + # source://rdoc//lib/rdoc/code_object.rb#297 + def options; end + + # Our parent CodeObject. The parent may be missing for classes loaded from + # legacy RI data stores. + # + # source://rdoc//lib/rdoc/code_object.rb#309 + def parent; end + + # Sets the parent CodeObject + # + # source://rdoc//lib/rdoc/code_object.rb#75 + def parent=(_arg0); end + + # File name of our parent + # + # source://rdoc//lib/rdoc/code_object.rb#331 + def parent_file_name; end + + # Name of our parent + # + # source://rdoc//lib/rdoc/code_object.rb#338 + def parent_name; end + + # source://rdoc//lib/rdoc/code_object.rb#80 + def received_nodoc; end + + # Records the RDoc::TopLevel (file) where this code object was defined + # + # source://rdoc//lib/rdoc/code_object.rb#345 + def record_location(top_level); end + + # The section this CodeObject is in. Sections allow grouping of constants, + # attributes and methods inside a class or module. + # + # source://rdoc//lib/rdoc/code_object.rb#355 + def section; end + + # Set the section this CodeObject is in + # + # source://rdoc//lib/rdoc/code_object.rb#85 + def section=(_arg0); end + + # Enable capture of documentation unless documentation has been + # turned off by :enddoc: + # + # source://rdoc//lib/rdoc/code_object.rb#365 + def start_doc; end + + # Disable capture of documentation + # + # source://rdoc//lib/rdoc/code_object.rb#377 + def stop_doc; end + + # The RDoc::Store for this object. + # + # source://rdoc//lib/rdoc/code_object.rb#90 + def store; end + + # Sets the +store+ that contains this CodeObject + # + # source://rdoc//lib/rdoc/code_object.rb#387 + def store=(store); end + + # Use this to suppress a CodeObject and all its children until the next file + # it is seen in or documentation is discovered. A suppressed item with + # documentation will be displayed while an ignored item with documentation + # may not be displayed. + # + # source://rdoc//lib/rdoc/code_object.rb#404 + def suppress; end + + # Has this class been suppressed? + # + # See also #suppress + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/code_object.rb#417 + def suppressed?; end + + # We are the model of the code, but we know that at some point we will be + # worked on by viewers. By implementing the Viewable protocol, viewers can + # associated themselves with these objects. + # + # source://rdoc//lib/rdoc/code_object.rb#97 + def viewer; end + + # We are the model of the code, but we know that at some point we will be + # worked on by viewers. By implementing the Viewable protocol, viewers can + # associated themselves with these objects. + # + # source://rdoc//lib/rdoc/code_object.rb#97 + def viewer=(_arg0); end +end + +# source://rdoc//lib/rdoc/comment.rb#12 +class RDoc::Comment + include ::RDoc::Text + + # Creates a new comment with +text+ that is found in the RDoc::TopLevel + # +location+. + # + # @return [Comment] a new instance of Comment + # + # source://rdoc//lib/rdoc/comment.rb#56 + def initialize(text = T.unsafe(nil), location = T.unsafe(nil), language = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/comment.rb#74 + def ==(other); end + + # Overrides the content returned by #parse. Use when there is no #text + # source for this comment + # + # source://rdoc//lib/rdoc/comment.rb#50 + def document=(_arg0); end + + # A comment is empty if its text String is empty. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/comment.rb#128 + def empty?; end + + # HACK dubious + # + # source://rdoc//lib/rdoc/comment.rb#135 + def encode!(encoding); end + + # Look for a 'call-seq' in the comment to override the normal parameter + # handling. The :call-seq: is indented from the baseline. All lines of the + # same indentation level and prefix are consumed. + # + # For example, all of the following will be used as the :call-seq: + # + # # :call-seq: + # # ARGF.readlines(sep=$/) -> array + # # ARGF.readlines(limit) -> array + # # ARGF.readlines(sep, limit) -> array + # # + # # ARGF.to_a(sep=$/) -> array + # # ARGF.to_a(limit) -> array + # # ARGF.to_a(sep, limit) -> array + # + # source://rdoc//lib/rdoc/comment.rb#95 + def extract_call_seq(method); end + + # The RDoc::TopLevel this comment was found in + # + # For duck-typing when merging classes at load time + # + # source://rdoc//lib/rdoc/comment.rb#24 + def file; end + + # The format of this comment. Defaults to RDoc::Markup + # + # source://rdoc//lib/rdoc/comment.rb#19 + def format; end + + # Sets the format of this comment and resets any parsed document + # + # source://rdoc//lib/rdoc/comment.rb#143 + def format=(format); end + + # source://rdoc//lib/rdoc/comment.rb#148 + def inspect; end + + # Line where this Comment was written + # + # source://rdoc//lib/rdoc/comment.rb#29 + def line; end + + # Line where this Comment was written + # + # source://rdoc//lib/rdoc/comment.rb#29 + def line=(_arg0); end + + # The RDoc::TopLevel this comment was found in + # + # source://rdoc//lib/rdoc/comment.rb#24 + def location; end + + # The RDoc::TopLevel this comment was found in + # + # source://rdoc//lib/rdoc/comment.rb#24 + def location=(_arg0); end + + # Normalizes the text. See RDoc::Text#normalize_comment for details + # + # source://rdoc//lib/rdoc/comment.rb#157 + def normalize; end + + # Was this text normalized? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/comment.rb#171 + def normalized?; end + + # Parses the comment into an RDoc::Markup::Document. The parsed document is + # cached until the text is changed. + # + # source://rdoc//lib/rdoc/comment.rb#179 + def parse; end + + # Removes private sections from this comment. Private sections are flush to + # the comment marker and start with -- and end with ++. + # For C-style comments, a private marker may not start at the opening of the + # comment. + # + # /* + # *-- + # * private + # *++ + # * public + # */ + # + # source://rdoc//lib/rdoc/comment.rb#200 + def remove_private; end + + # The text for this comment + # + # source://rdoc//lib/rdoc/comment.rb#39 + def text; end + + # Replaces this comment's text with +text+ and resets the parsed document. + # + # An error is raised if the comment contains a document but no text. + # + # @raise [RDoc::Error] + # + # source://rdoc//lib/rdoc/comment.rb#214 + def text=(text); end + + # The text for this comment + # + # Alias for text + # + # source://rdoc//lib/rdoc/comment.rb#39 + def to_s; end + + # Returns true if this comment is in TomDoc format. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/comment.rb#225 + def tomdoc?; end + + private + + # -- + # TODO deep copy @document + # + # source://rdoc//lib/rdoc/comment.rb#70 + def initialize_copy(copy); end +end + +# A constant +# +# source://rdoc//lib/rdoc/constant.rb#5 +class RDoc::Constant < ::RDoc::CodeObject + # Creates a new constant with +name+, +value+ and +comment+ + # + # @return [Constant] a new instance of Constant + # + # source://rdoc//lib/rdoc/constant.rb#32 + def initialize(name, value, comment); end + + # Constants are ordered by name + # + # source://rdoc//lib/rdoc/constant.rb#47 + def <=>(other); end + + # Constants are equal when their #parent and #name is the same + # + # source://rdoc//lib/rdoc/constant.rb#56 + def ==(other); end + + # A constant is documented if it has a comment, or is an alias + # for a documented class or module. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/constant.rb#66 + def documented?; end + + # Full constant name including namespace + # + # source://rdoc//lib/rdoc/constant.rb#81 + def full_name; end + + # source://rdoc//lib/rdoc/constant.rb#99 + def inspect; end + + # The module or class this constant is an alias for + # + # source://rdoc//lib/rdoc/constant.rb#88 + def is_alias_for; end + + # Sets the module or class this is constant is an alias for. + # + # source://rdoc//lib/rdoc/constant.rb#12 + def is_alias_for=(_arg0); end + + # Dumps this Constant for use by ri. See also #marshal_load + # + # source://rdoc//lib/rdoc/constant.rb#109 + def marshal_dump; end + + # Loads this Constant from +array+. For a loaded Constant the following + # methods will return cached values: + # + # * #full_name + # * #parent_name + # + # source://rdoc//lib/rdoc/constant.rb#135 + def marshal_load(array); end + + # The constant's name + # + # source://rdoc//lib/rdoc/constant.rb#17 + def name; end + + # The constant's name + # + # source://rdoc//lib/rdoc/constant.rb#17 + def name=(_arg0); end + + # Path to this constant for use with HTML generator output. + # + # source://rdoc//lib/rdoc/constant.rb#153 + def path; end + + # source://rdoc//lib/rdoc/constant.rb#157 + def pretty_print(q); end + + # Sets the store for this class or module and its contained code objects. + # + # source://rdoc//lib/rdoc/constant.rb#171 + def store=(store); end + + # source://rdoc//lib/rdoc/constant.rb#177 + def to_s; end + + # The constant's value + # + # source://rdoc//lib/rdoc/constant.rb#22 + def value; end + + # The constant's value + # + # source://rdoc//lib/rdoc/constant.rb#22 + def value=(_arg0); end + + # The constant's visibility + # + # source://rdoc//lib/rdoc/constant.rb#27 + def visibility; end + + # The constant's visibility + # + # source://rdoc//lib/rdoc/constant.rb#27 + def visibility=(_arg0); end +end + +# A Context is something that can hold modules, classes, methods, attributes, +# aliases, requires, and includes. Classes, modules, and files are all +# Contexts. +# +# source://rdoc//lib/rdoc/context.rb#7 +class RDoc::Context < ::RDoc::CodeObject + include ::Comparable + + # Creates an unnamed empty context with public current visibility + # + # @return [Context] a new instance of Context + # + # source://rdoc//lib/rdoc/context.rb#123 + def initialize; end + + # Contexts are sorted by full_name + # + # source://rdoc//lib/rdoc/context.rb#171 + def <=>(other); end + + # Adds an item of type +klass+ with the given +name+ and +comment+ to the + # context. + # + # Currently only RDoc::Extend and RDoc::Include are supported. + # + # source://rdoc//lib/rdoc/context.rb#183 + def add(klass, name, comment); end + + # Adds +an_alias+ that is automatically resolved + # + # source://rdoc//lib/rdoc/context.rb#198 + def add_alias(an_alias); end + + # Adds +attribute+ if not already there. If it is (as method(s) or attribute), + # updates the comment if it was empty. + # + # The attribute is registered only if it defines a new method. + # For instance, attr_reader :foo will not be registered + # if method +foo+ exists, but attr_accessor :foo will be registered + # if method +foo+ exists, but foo= does not. + # + # source://rdoc//lib/rdoc/context.rb#225 + def add_attribute(attribute); end + + # Adds a class named +given_name+ with +superclass+. + # + # Both +given_name+ and +superclass+ may contain '::', and are + # interpreted relative to the +self+ context. This allows handling correctly + # examples like these: + # class RDoc::Gauntlet < Gauntlet + # module Mod + # class Object # implies < ::Object + # class SubObject < Object # this is _not_ ::Object + # + # Given class Container::Item RDoc assumes +Container+ is a module + # unless it later sees class Container. +add_class+ automatically + # upgrades +given_name+ to a class in this case. + # + # source://rdoc//lib/rdoc/context.rb#288 + def add_class(class_type, given_name, superclass = T.unsafe(nil)); end + + # Adds the class or module +mod+ to the modules or + # classes Hash +self_hash+, and to +all_hash+ (either + # TopLevel::modules_hash or TopLevel::classes_hash), + # unless #done_documenting is +true+. Sets the #parent of +mod+ + # to +self+, and its #section to #current_section. Returns +mod+. + # + # source://rdoc//lib/rdoc/context.rb#404 + def add_class_or_module(mod, self_hash, all_hash); end + + # Adds +constant+ if not already there. If it is, updates the comment, + # value and/or is_alias_for of the known constant if they were empty/nil. + # + # source://rdoc//lib/rdoc/context.rb#429 + def add_constant(constant); end + + # Adds extension module +ext+ which should be an RDoc::Extend + # + # source://rdoc//lib/rdoc/context.rb#463 + def add_extend(ext); end + + # Adds included module +include+ which should be an RDoc::Include + # + # source://rdoc//lib/rdoc/context.rb#454 + def add_include(include); end + + # Adds +method+ if not already there. If it is (as method or attribute), + # updates the comment if it was empty. + # + # source://rdoc//lib/rdoc/context.rb#473 + def add_method(method); end + + # Adds a module named +name+. If RDoc already knows +name+ is a class then + # that class is returned instead. See also #add_class. + # + # source://rdoc//lib/rdoc/context.rb#506 + def add_module(class_type, name); end + + # Adds an alias from +from+ (a class or module) to +name+ which was defined + # in +file+. + # + # source://rdoc//lib/rdoc/context.rb#527 + def add_module_alias(from, from_name, to, file); end + + # Adds a module by +RDoc::NormalModule+ instance. See also #add_module. + # + # source://rdoc//lib/rdoc/context.rb#519 + def add_module_by_normal_module(mod); end + + # Adds +require+ to this context's top level + # + # source://rdoc//lib/rdoc/context.rb#568 + def add_require(require); end + + # Returns a section with +title+, creating it if it doesn't already exist. + # +comment+ will be appended to the section's comment. + # + # A section with a +title+ of +nil+ will return the default section. + # + # See also RDoc::Context::Section + # + # source://rdoc//lib/rdoc/context.rb#586 + def add_section(title, comment = T.unsafe(nil)); end + + # Adds +thing+ to the collection +array+ + # + # source://rdoc//lib/rdoc/context.rb#600 + def add_to(array, thing); end + + # Class/module aliases + # + # source://rdoc//lib/rdoc/context.rb#25 + def aliases; end + + # Is there any content? + # + # This means any of: comment, aliases, methods, attributes, external + # aliases, require, constant. + # + # Includes and extends are also checked unless includes == false. + # + # source://rdoc//lib/rdoc/context.rb#616 + def any_content(includes = T.unsafe(nil)); end + + # All attr* methods + # + # source://rdoc//lib/rdoc/context.rb#30 + def attributes; end + + # Block params to be used in the next MethodAttr parsed under this context + # + # source://rdoc//lib/rdoc/context.rb#35 + def block_params; end + + # Block params to be used in the next MethodAttr parsed under this context + # + # source://rdoc//lib/rdoc/context.rb#35 + def block_params=(_arg0); end + + # Creates the full name for a child with +name+ + # + # source://rdoc//lib/rdoc/context.rb#632 + def child_name(name); end + + # Class attributes + # + # source://rdoc//lib/rdoc/context.rb#645 + def class_attributes; end + + # Class methods + # + # source://rdoc//lib/rdoc/context.rb#652 + def class_method_list; end + + # Array of classes in this context + # + # source://rdoc//lib/rdoc/context.rb#659 + def classes; end + + # All classes and modules in this namespace + # + # source://rdoc//lib/rdoc/context.rb#666 + def classes_and_modules; end + + # Hash of classes keyed by class name + # + # source://rdoc//lib/rdoc/context.rb#673 + def classes_hash; end + + # Constants defined + # + # source://rdoc//lib/rdoc/context.rb#40 + def constants; end + + # Hash of registered constants. + # + # source://rdoc//lib/rdoc/context.rb#118 + def constants_hash; end + + # Current visibility of this line + # + # source://rdoc//lib/rdoc/context.rb#102 + def current_line_visibility=(_arg0); end + + # The current documentation section that new items will be added to. If + # temporary_section is available it will be used. + # + # source://rdoc//lib/rdoc/context.rb#681 + def current_section; end + + # Sets the current documentation section of documentation + # + # source://rdoc//lib/rdoc/context.rb#45 + def current_section=(_arg0); end + + # Is part of this thing was defined in +file+? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/context.rb#694 + def defined_in?(file); end + + # source://rdoc//lib/rdoc/context.rb#698 + def display(method_attr); end + + # Iterator for ancestors for duck-typing. Does nothing. See + # RDoc::ClassModule#each_ancestor. + # + # This method exists to make it easy to work with Context subclasses that + # aren't part of RDoc. + # + # source://rdoc//lib/rdoc/context.rb#713 + def each_ancestor(&_); end + + # Iterator for attributes + # + # source://rdoc//lib/rdoc/context.rb#719 + def each_attribute; end + + # Iterator for classes and modules + # + # source://rdoc//lib/rdoc/context.rb#726 + def each_classmodule(&block); end + + # Iterator for constants + # + # source://rdoc//lib/rdoc/context.rb#733 + def each_constant; end + + # Iterator for extension modules + # + # source://rdoc//lib/rdoc/context.rb#747 + def each_extend; end + + # Iterator for included modules + # + # source://rdoc//lib/rdoc/context.rb#740 + def each_include; end + + # Iterator for methods + # + # source://rdoc//lib/rdoc/context.rb#754 + def each_method; end + + # Iterator for each section's contents sorted by title. The +section+, the + # section's +constants+ and the sections +attributes+ are yielded. The + # +constants+ and +attributes+ collections are sorted. + # + # To retrieve methods in a section use #methods_by_type with the optional + # +section+ parameter. + # + # NOTE: Do not edit collections yielded by this method + # + # source://rdoc//lib/rdoc/context.rb#770 + def each_section; end + + # Modules this context is extended with + # + # source://rdoc//lib/rdoc/context.rb#60 + def extends; end + + # Aliases that could not be resolved. + # + # source://rdoc//lib/rdoc/context.rb#92 + def external_aliases; end + + # Finds an attribute +name+ with singleton value +singleton+. + # + # source://rdoc//lib/rdoc/context.rb#787 + def find_attribute(name, singleton); end + + # Finds an attribute with +name+ in this context + # + # source://rdoc//lib/rdoc/context.rb#795 + def find_attribute_named(name); end + + # Finds a class method with +name+ in this context + # + # source://rdoc//lib/rdoc/context.rb#809 + def find_class_method_named(name); end + + # Finds a constant with +name+ in this context + # + # source://rdoc//lib/rdoc/context.rb#816 + def find_constant_named(name); end + + # Find a module at a higher scope + # + # source://rdoc//lib/rdoc/context.rb#825 + def find_enclosing_module_named(name); end + + # Finds an external alias +name+ with singleton value +singleton+. + # + # source://rdoc//lib/rdoc/context.rb#832 + def find_external_alias(name, singleton); end + + # Finds an external alias with +name+ in this context + # + # source://rdoc//lib/rdoc/context.rb#839 + def find_external_alias_named(name); end + + # Finds a file with +name+ in this context + # + # source://rdoc//lib/rdoc/context.rb#853 + def find_file_named(name); end + + # Finds an instance method with +name+ in this context + # + # source://rdoc//lib/rdoc/context.rb#860 + def find_instance_method_named(name); end + + # Finds a method, constant, attribute, external alias, module or file + # named +symbol+ in this context. + # + # source://rdoc//lib/rdoc/context.rb#868 + def find_local_symbol(symbol); end + + # Finds a method named +name+ with singleton value +singleton+. + # + # source://rdoc//lib/rdoc/context.rb#880 + def find_method(name, singleton); end + + # Finds a instance or module method with +name+ in this context + # + # source://rdoc//lib/rdoc/context.rb#893 + def find_method_named(name); end + + # Find a module with +name+ using ruby's scoping rules + # + # source://rdoc//lib/rdoc/context.rb#907 + def find_module_named(name); end + + # Look up +symbol+, first as a module, then as a local symbol. + # + # source://rdoc//lib/rdoc/context.rb#917 + def find_symbol(symbol); end + + # Look up a module named +symbol+. + # + # source://rdoc//lib/rdoc/context.rb#924 + def find_symbol_module(symbol); end + + # The full name for this context. This method is overridden by subclasses. + # + # source://rdoc//lib/rdoc/context.rb#957 + def full_name; end + + # Does this context and its methods and constants all have documentation? + # + # (Yes, fully documented doesn't mean everything.) + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/context.rb#966 + def fully_documented?; end + + # URL for this with a +prefix+ + # + # source://rdoc//lib/rdoc/context.rb#976 + def http_url(prefix); end + + # Files this context is found in + # + # source://rdoc//lib/rdoc/context.rb#50 + def in_files; end + + # Modules this context includes + # + # source://rdoc//lib/rdoc/context.rb#55 + def includes; end + + # Sets the defaults for methods and so-forth + # + # source://rdoc//lib/rdoc/context.rb#145 + def initialize_methods_etc; end + + # Instance attributes + # + # source://rdoc//lib/rdoc/context.rb#987 + def instance_attributes; end + + # Instance methods + # -- + # TODO remove this later + # + # source://rdoc//lib/rdoc/context.rb#1003 + def instance_method_list; end + + # Instance methods + # + # source://rdoc//lib/rdoc/context.rb#994 + def instance_methods; end + + # Methods defined in this context + # + # source://rdoc//lib/rdoc/context.rb#65 + def method_list; end + + # Breaks method_list into a nested hash by type ('class' or + # 'instance') and visibility (+:public+, +:protected+, +:private+). + # + # If +section+ is provided only methods in that RDoc::Context::Section will + # be returned. + # + # source://rdoc//lib/rdoc/context.rb#1015 + def methods_by_type(section = T.unsafe(nil)); end + + # Hash of registered methods. Attributes are also registered here, + # twice if they are RW. + # + # source://rdoc//lib/rdoc/context.rb#108 + def methods_hash; end + + # Yields AnyMethod and Attr entries matching the list of names in +methods+. + # + # source://rdoc//lib/rdoc/context.rb#1038 + def methods_matching(methods, singleton = T.unsafe(nil), &block); end + + # Array of modules in this context + # + # source://rdoc//lib/rdoc/context.rb#1051 + def modules; end + + # Hash of modules keyed by module name + # + # source://rdoc//lib/rdoc/context.rb#1058 + def modules_hash; end + + # Name of this class excluding namespace. See also full_name + # + # source://rdoc//lib/rdoc/context.rb#70 + def name; end + + # Name to use to generate the url. + # #full_name by default. + # + # source://rdoc//lib/rdoc/context.rb#1066 + def name_for_path; end + + # Changes the visibility for new methods to +visibility+ + # + # source://rdoc//lib/rdoc/context.rb#1073 + def ongoing_visibility=(visibility); end + + # Params to be used in the next MethodAttr parsed under this context + # + # source://rdoc//lib/rdoc/context.rb#113 + def params; end + + # Params to be used in the next MethodAttr parsed under this context + # + # source://rdoc//lib/rdoc/context.rb#113 + def params=(_arg0); end + + # Record +top_level+ as a file +self+ is in. + # + # source://rdoc//lib/rdoc/context.rb#1080 + def record_location(top_level); end + + # Should we remove this context from the documentation? + # + # The answer is yes if: + # * #received_nodoc is +true+ + # * #any_content is +false+ (not counting includes) + # * All #includes are modules (not a string), and their module has + # #remove_from_documentation? == true + # * All classes and modules have #remove_from_documentation? == true + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/context.rb#1094 + def remove_from_documentation?; end + + # Removes methods and attributes with a visibility less than +min_visibility+. + # -- + # TODO mark the visibility of attributes in the template (if not public?) + # + # source://rdoc//lib/rdoc/context.rb#1107 + def remove_invisible(min_visibility); end + + # Only called when min_visibility == :public or :private + # + # source://rdoc//lib/rdoc/context.rb#1117 + def remove_invisible_in(array, min_visibility); end + + # Files this context requires + # + # source://rdoc//lib/rdoc/context.rb#75 + def requires; end + + # Tries to resolve unmatched aliases when a method or attribute has just + # been added. + # + # source://rdoc//lib/rdoc/context.rb#1133 + def resolve_aliases(added); end + + # Returns RDoc::Context::Section objects referenced in this context for use + # in a table of contents. + # + # source://rdoc//lib/rdoc/context.rb#1149 + def section_contents; end + + # Sections in this context + # + # source://rdoc//lib/rdoc/context.rb#1173 + def sections; end + + # source://rdoc//lib/rdoc/context.rb#1177 + def sections_hash; end + + # Given an array +names+ of constants, set the visibility of each constant to + # +visibility+ + # + # source://rdoc//lib/rdoc/context.rb#1202 + def set_constant_visibility_for(names, visibility); end + + # Sets the current section to a section with +title+. See also #add_section + # + # source://rdoc//lib/rdoc/context.rb#1184 + def set_current_section(title, comment); end + + # Given an array +methods+ of method names, set the visibility of each to + # +visibility+ + # + # source://rdoc//lib/rdoc/context.rb#1192 + def set_visibility_for(methods, visibility, singleton = T.unsafe(nil)); end + + # Sorts sections alphabetically (default) or in TomDoc fashion (none, + # Public, Internal, Deprecated) + # + # source://rdoc//lib/rdoc/context.rb#1213 + def sort_sections; end + + # Use this section for the next method, attribute or constant added. + # + # source://rdoc//lib/rdoc/context.rb#80 + def temporary_section; end + + # Use this section for the next method, attribute or constant added. + # + # source://rdoc//lib/rdoc/context.rb#80 + def temporary_section=(_arg0); end + + # source://rdoc//lib/rdoc/context.rb#1229 + def to_s; end + + # Return the TopLevel that owns us + # -- + # FIXME we can be 'owned' by several TopLevel (see #record_location & + # #in_files) + # + # source://rdoc//lib/rdoc/context.rb#1239 + def top_level; end + + # Hash old_name => [aliases], for aliases + # that haven't (yet) been resolved to a method/attribute. + # (Not to be confused with the aliases of the context.) + # + # source://rdoc//lib/rdoc/context.rb#87 + def unmatched_alias_lists; end + + # Hash old_name => [aliases], for aliases + # that haven't (yet) been resolved to a method/attribute. + # (Not to be confused with the aliases of the context.) + # + # source://rdoc//lib/rdoc/context.rb#87 + def unmatched_alias_lists=(_arg0); end + + # Upgrades NormalModule +mod+ in +enclosing+ to a +class_type+ + # + # source://rdoc//lib/rdoc/context.rb#1249 + def upgrade_to_class(mod, class_type, enclosing); end + + # Current visibility of this context + # + # source://rdoc//lib/rdoc/context.rb#97 + def visibility; end + + # Current visibility of this context + # + # source://rdoc//lib/rdoc/context.rb#97 + def visibility=(_arg0); end +end + +# A section of documentation like: +# +# # :section: The title +# # The body +# +# Sections can be referenced multiple times and will be collapsed into a +# single section. +# +# source://rdoc//lib/rdoc/context/section.rb#13 +class RDoc::Context::Section + include ::RDoc::Text + include ::RDoc::Generator::Markup + + # Creates a new section with +title+ and +comment+ + # + # @return [Section] a new instance of Section + # + # source://rdoc//lib/rdoc/context/section.rb#42 + def initialize(parent, title, comment); end + + # Sections are equal when they have the same #title + # + # source://rdoc//lib/rdoc/context/section.rb#54 + def ==(other); end + + # Adds +comment+ to this section + # + # source://rdoc//lib/rdoc/context/section.rb#63 + def add_comment(comment); end + + # Anchor reference for linking to this section + # + # source://rdoc//lib/rdoc/context/section.rb#83 + def aref; end + + # Section comment + # + # source://rdoc//lib/rdoc/context/section.rb#22 + def comment; end + + # Section comments + # + # source://rdoc//lib/rdoc/context/section.rb#27 + def comments; end + + # Sections are equal when they have the same #title + # + # source://rdoc//lib/rdoc/context/section.rb#54 + def eql?(other); end + + # Extracts the comment for this section from the original comment block. + # If the first line contains :section:, strip it and use the rest. + # Otherwise remove lines up to the line containing :section:, and look + # for those lines again at the end and remove them. This lets us write + # + # # :section: The title + # # The body + # + # source://rdoc//lib/rdoc/context/section.rb#98 + def extract_comment(comment); end + + # source://rdoc//lib/rdoc/context/section.rb#130 + def hash; end + + # The files comments in this section come from + # + # source://rdoc//lib/rdoc/context/section.rb#137 + def in_files; end + + # source://rdoc//lib/rdoc/context/section.rb#126 + def inspect; end + + # Serializes this Section. The title and parsed comment are saved, but not + # the section parent which must be restored manually. + # + # source://rdoc//lib/rdoc/context/section.rb#158 + def marshal_dump; end + + # De-serializes this Section. The section parent must be restored manually. + # + # source://rdoc//lib/rdoc/context/section.rb#169 + def marshal_load(array); end + + # Context this Section lives in + # + # source://rdoc//lib/rdoc/context/section.rb#32 + def parent; end + + # Parses +comment_location+ into an RDoc::Markup::Document composed of + # multiple RDoc::Markup::Documents with their file set. + # + # source://rdoc//lib/rdoc/context/section.rb#180 + def parse; end + + # The section's title, or 'Top Section' if the title is nil. + # + # This is used by the table of contents template so the name is silly. + # + # source://rdoc//lib/rdoc/context/section.rb#208 + def plain_html; end + + # Removes a comment from this section if it is from the same file as + # +comment+ + # + # source://rdoc//lib/rdoc/context/section.rb#216 + def remove_comment(comment); end + + # Section title + # + # source://rdoc//lib/rdoc/context/section.rb#37 + def title; end +end + +# RDoc::CrossReference is a reusable way to create cross references for names. +# +# source://rdoc//lib/rdoc/cross_reference.rb#8 +class RDoc::CrossReference + # Allows cross-references to be created based on the given +context+ + # (RDoc::Context). + # + # @return [CrossReference] a new instance of CrossReference + # + # source://rdoc//lib/rdoc/cross_reference.rb#127 + def initialize(context); end + + # Returns a reference to +name+. + # + # If the reference is found and +name+ is not documented +text+ will be + # returned. If +name+ is escaped +name+ is returned. If +name+ is not + # found +text+ is returned. + # + # source://rdoc//lib/rdoc/cross_reference.rb#190 + def resolve(name, text); end + + # Returns a method reference to +name+. + # + # source://rdoc//lib/rdoc/cross_reference.rb#137 + def resolve_method(name); end + + # Hash of references that have been looked-up to their replacements + # + # source://rdoc//lib/rdoc/cross_reference.rb#121 + def seen; end + + # Hash of references that have been looked-up to their replacements + # + # source://rdoc//lib/rdoc/cross_reference.rb#121 + def seen=(_arg0); end +end + +# Regular expression to match method arguments. +# +# source://rdoc//lib/rdoc/cross_reference.rb#28 +RDoc::CrossReference::METHOD_ARGS_REGEXP_STR = T.let(T.unsafe(nil), String) + +# Regular expression to match a single method argument. +# +# source://rdoc//lib/rdoc/cross_reference.rb#23 +RDoc::CrossReference::METHOD_ARG_REGEXP_STR = T.let(T.unsafe(nil), String) + +# A subclass of ERB that writes directly to an IO. Credit to Aaron Patterson +# and Masatoshi SEKI. +# +# To use: +# +# erbio = RDoc::ERBIO.new '<%= "hello world" %>', nil, nil +# +# File.open 'hello.txt', 'w' do |io| +# erbio.result binding +# end +# +# Note that binding must enclose the io you wish to output on. +# +# source://rdoc//lib/rdoc/erbio.rb#18 +class RDoc::ERBIO < ::ERB + # Defaults +eoutvar+ to 'io', otherwise is identical to ERB's initialize + # + # @return [ERBIO] a new instance of ERBIO + # + # source://rdoc//lib/rdoc/erbio.rb#23 + def initialize(str, trim_mode: T.unsafe(nil), eoutvar: T.unsafe(nil)); end + + # Instructs +compiler+ how to write to +io_variable+ + # + # source://rdoc//lib/rdoc/erbio.rb#30 + def set_eoutvar(compiler, io_variable); end +end + +# Allows an ERB template to be rendered in the context (binding) of an +# existing ERB template evaluation. +# +# source://rdoc//lib/rdoc/erb_partial.rb#6 +class RDoc::ERBPartial < ::ERB + # Overrides +compiler+ startup to set the +eoutvar+ to an empty string only + # if it isn't already set. + # + # source://rdoc//lib/rdoc/erb_partial.rb#12 + def set_eoutvar(compiler, eoutvar = T.unsafe(nil)); end +end + +# This class is a wrapper around File IO and Encoding that helps RDoc load +# files and convert them to the correct encoding. +# +# source://rdoc//lib/rdoc/encoding.rb#8 +module RDoc::Encoding + class << self + # Changes encoding based on +encoding+ without converting and returns new + # string + # + # source://rdoc//lib/rdoc/encoding.rb#112 + def change_encoding(text, encoding); end + + # Detects the encoding of +string+ based on the magic comment + # + # source://rdoc//lib/rdoc/encoding.rb#92 + def detect_encoding(string); end + + # Reads the contents of +filename+ and handles any encoding directives in + # the file. + # + # The content will be converted to the +encoding+. If the file cannot be + # converted a warning will be printed and nil will be returned. + # + # If +force_transcode+ is true the document will be transcoded and any + # unknown character in the target encoding will be replaced with '?' + # + # source://rdoc//lib/rdoc/encoding.rb#32 + def read_file(filename, encoding, force_transcode = T.unsafe(nil)); end + + # Removes magic comments and shebang + # + # source://rdoc//lib/rdoc/encoding.rb#102 + def remove_magic_comment(string); end + end +end + +# source://rdoc//lib/rdoc/encoding.rb#10 +RDoc::Encoding::HEADER_REGEXP = T.let(T.unsafe(nil), Regexp) + +# source://rdoc//lib/rdoc/generator/darkfish.rb#55 +class RDoc::Generator::Darkfish + include ::ERB::Escape + include ::ERB::Util + include ::ActiveSupport::CoreExt::ERBUtil + include ::ActiveSupport::CoreExt::ERBUtilPrivate + + # Initialize a few instance variables before we start + # + # @return [Darkfish] a new instance of Darkfish + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#159 + def initialize(store, options); end + + # Creates a template from its components and the +body_file+. + # + # For backwards compatibility, if +body_file+ contains "--op
from the + # options for a full path. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#102 + def base_dir; end + + # Directory where generated class HTML files live relative to the output + # dir. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#191 + def class_dir; end + + # Classes and modules to be used by this generator, not necessarily + # displayed. See also #modsort + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#108 + def classes; end + + # Copies static files from the static_path into the output directory + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#265 + def copy_static; end + + # Output progress information if debugging is enabled + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#182 + def debug_msg(*msg); end + + # No files will be written when dry_run is true. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#113 + def dry_run; end + + # No files will be written when dry_run is true. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#113 + def dry_run=(_arg0); end + + # Directory where generated class HTML files live relative to the output + # dir. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#199 + def file_dir; end + + # When false the generate methods return a String instead of writing to a + # file. The default is true. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#119 + def file_output; end + + # When false the generate methods return a String instead of writing to a + # file. The default is true. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#119 + def file_output=(_arg0); end + + # Files to be displayed by this generator + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#124 + def files; end + + # Create the directories the generated docs will live in if they don't + # already exist. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#207 + def gen_sub_directories; end + + # Build the initial indices and output objects based on an array of TopLevel + # objects containing the extracted information. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#241 + def generate; end + + # Generates a class file for +klass+ + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#337 + def generate_class(klass, template_file = T.unsafe(nil)); end + + # Generate a documentation file for each class and module + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#368 + def generate_class_files; end + + # Generate a documentation file for each file + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#395 + def generate_file_files; end + + # Generate an index page which lists all the classes which are documented. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#303 + def generate_index; end + + # Generate a page file for +file+ + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#464 + def generate_page(file); end + + # Generates the 404 page for the RDoc servlet + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#493 + def generate_servlet_not_found(message); end + + # Generates the servlet root page for the RDoc servlet + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#526 + def generate_servlet_root(installed); end + + # Generate an index page which lists all the classes which are documented. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#553 + def generate_table_of_contents; end + + # Return a list of the documented modules sorted by salience first, then + # by name. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#294 + def get_sorted_module_list(classes); end + + # Try to extract Subversion information out of the first constant whose + # value looks like a subversion Id tag. If no matching constant is found, + # and empty hash is returned. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#652 + def get_svninfo(klass); end + + # source://rdoc//lib/rdoc/generator/darkfish.rb#584 + def install_rdoc_static_file(source, destination, options); end + + # The JSON index generator for this Darkfish generator + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#129 + def json_index; end + + # Methods to be displayed by this generator + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#134 + def methods; end + + # Sorted list of classes and modules to be displayed by this generator + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#139 + def modsort; end + + # The output directory + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#154 + def outputdir; end + + # Renders the ERb contained in +file_name+ relative to the template + # directory and returns the result based on the current context. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#699 + def render(file_name); end + + # Load and render the erb template in the given +template_file+ and write + # it out to +out_file+. + # + # Both +template_file+ and +out_file+ should be Pathname-like objects. + # + # An io will be yielded which must be captured by binding in the caller. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#717 + def render_template(template_file, out_file = T.unsafe(nil)); end + + # Prepares for generation of output from the current directory + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#604 + def setup; end + + # The RDoc::Store that is the source of the generated content + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#144 + def store; end + + # The directory where the template files live + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#149 + def template_dir; end + + # Retrieves a cache template for +file+, if present, or fills the cache. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#764 + def template_for(file, page = T.unsafe(nil), klass = T.unsafe(nil)); end + + # Creates the result for +template+ with +context+. If an error is raised a + # Pathname +template_file+ will indicate the file where the error occurred. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#751 + def template_result(template, context, template_file); end + + # Return a string describing the amount of time in the given number of + # seconds in terms a human can understand easily. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#621 + def time_delta_string(seconds); end + + # Copy over the stylesheet into the appropriate place in the output + # directory. + # + # source://rdoc//lib/rdoc/generator/darkfish.rb#215 + def write_style_sheet; end +end + +# source://rdoc//lib/rdoc/generator/json_index.rb#77 +class RDoc::Generator::JsonIndex + include ::RDoc::Text + + # Creates a new generator. +parent_generator+ is used to determine the + # class_dir and file_dir of links in the output index. + # + # +options+ are the same options passed to the parent generator. + # + # @return [JsonIndex] a new instance of JsonIndex + # + # source://rdoc//lib/rdoc/generator/json_index.rb#94 + def initialize(parent_generator, options); end + + # Builds the JSON index as a Hash. + # + # source://rdoc//lib/rdoc/generator/json_index.rb#110 + def build_index; end + + # The directory classes are written to + # + # source://rdoc//lib/rdoc/generator/json_index.rb#271 + def class_dir; end + + # Output progress information if debugging is enabled + # + # source://rdoc//lib/rdoc/generator/json_index.rb#123 + def debug_msg(*msg); end + + # The directory files are written to + # + # source://rdoc//lib/rdoc/generator/json_index.rb#278 + def file_dir; end + + # Writes the JSON index to disk + # + # source://rdoc//lib/rdoc/generator/json_index.rb#131 + def generate; end + + # Compress the search_index.js file using gzip + # + # source://rdoc//lib/rdoc/generator/json_index.rb#166 + def generate_gzipped; end + + # source://rdoc//lib/rdoc/generator/json_index.rb#86 + def index; end + + # Adds classes and modules to the index + # + # source://rdoc//lib/rdoc/generator/json_index.rb#211 + def index_classes; end + + # Adds methods to the index + # + # source://rdoc//lib/rdoc/generator/json_index.rb#230 + def index_methods; end + + # Adds pages to the index + # + # source://rdoc//lib/rdoc/generator/json_index.rb#251 + def index_pages; end + + # source://rdoc//lib/rdoc/generator/json_index.rb#282 + def reset(files, classes); end + + # Removes whitespace and downcases +string+ + # + # source://rdoc//lib/rdoc/generator/json_index.rb#296 + def search_string(string); end +end + +# Generates a POT file. +# +# Here is a translator work flow with the generator. +# +# == Create .pot +# +# You create .pot file by pot formatter: +# +# % rdoc --format pot +# +# It generates doc/rdoc.pot. +# +# == Create .po +# +# You create .po file from doc/rdoc.pot. This operation is needed only +# the first time. This work flow assumes that you are a translator +# for Japanese. +# +# You create locale/ja/rdoc.po from doc/rdoc.pot. You can use msginit +# provided by GNU gettext or rmsginit provided by gettext gem. This +# work flow uses gettext gem because it is more portable than GNU +# gettext for Rubyists. Gettext gem is implemented by pure Ruby. +# +# % gem install gettext +# % mkdir -p locale/ja +# % rmsginit --input doc/rdoc.pot --output locale/ja/rdoc.po --locale ja +# +# Translate messages in .po +# +# You translate messages in .po by a PO file editor. po-mode.el exists +# for Emacs users. There are some GUI tools such as GTranslator. +# There are some Web services such as POEditor and Tansifex. You can +# edit by your favorite text editor because .po is a text file. +# Generate localized documentation +# +# You can generate localized documentation with locale/ja/rdoc.po: +# +# % rdoc --locale ja +# +# You can find documentation in Japanese in doc/. Yay! +# +# == Update translation +# +# You need to update translation when your application is added or +# modified messages. +# +# You can update .po by the following command lines: +# +# % rdoc --format pot +# % rmsgmerge --update locale/ja/rdoc.po doc/rdoc.pot +# +# You edit locale/ja/rdoc.po to translate new messages. +# +# source://rdoc//lib/rdoc/generator/pot.rb#56 +class RDoc::Generator::POT + # Set up a new .pot generator + # + # @return [POT] a new instance of POT + # + # source://rdoc//lib/rdoc/generator/pot.rb#68 + def initialize(store, options); end + + # source://rdoc//lib/rdoc/generator/pot.rb#85 + def class_dir; end + + # Writes .pot to disk. + # + # source://rdoc//lib/rdoc/generator/pot.rb#76 + def generate; end + + private + + # source://rdoc//lib/rdoc/generator/pot.rb#90 + def extract_messages; end +end + +# Extracts message from RDoc::Store +# +# source://rdoc//lib/rdoc/generator/pot/message_extractor.rb#5 +class RDoc::Generator::POT::MessageExtractor + # Creates a message extractor for +store+. + # + # @return [MessageExtractor] a new instance of MessageExtractor + # + # source://rdoc//lib/rdoc/generator/pot/message_extractor.rb#10 + def initialize(store); end + + # Extracts messages from +store+, stores them into + # RDoc::Generator::POT::PO and returns it. + # + # source://rdoc//lib/rdoc/generator/pot/message_extractor.rb#19 + def extract; end + + private + + # source://rdoc//lib/rdoc/generator/pot/message_extractor.rb#64 + def entry(msgid, options); end + + # source://rdoc//lib/rdoc/generator/pot/message_extractor.rb#28 + def extract_from_klass(klass); end + + # source://rdoc//lib/rdoc/generator/pot/message_extractor.rb#51 + def extract_text(text, comment, location = T.unsafe(nil)); end +end + +# Generates a PO format text +# +# source://rdoc//lib/rdoc/generator/pot/po.rb#5 +class RDoc::Generator::POT::PO + # Creates an object that represents PO format. + # + # @return [PO] a new instance of PO + # + # source://rdoc//lib/rdoc/generator/pot/po.rb#10 + def initialize; end + + # Adds a PO entry to the PO. + # + # source://rdoc//lib/rdoc/generator/pot/po.rb#18 + def add(entry); end + + # Returns PO format text for the PO. + # + # source://rdoc//lib/rdoc/generator/pot/po.rb#29 + def to_s; end + + private + + # source://rdoc//lib/rdoc/generator/pot/po.rb#40 + def add_header; end + + # source://rdoc//lib/rdoc/generator/pot/po.rb#44 + def header_entry; end + + # source://rdoc//lib/rdoc/generator/pot/po.rb#73 + def sort_entries; end +end + +# A PO entry in PO +# +# source://rdoc//lib/rdoc/generator/pot/po_entry.rb#5 +class RDoc::Generator::POT::POEntry + # Creates a PO entry for +msgid+. Other valus can be specified by + # +options+. + # + # @return [POEntry] a new instance of POEntry + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#29 + def initialize(msgid, options = T.unsafe(nil)); end + + # The comment content extracted from source file + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#17 + def extracted_comment; end + + # The flags of the PO entry + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#23 + def flags; end + + # Merges the PO entry with +other_entry+. + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#56 + def merge(other_entry); end + + # The msgid content + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#8 + def msgid; end + + # The msgstr content + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#11 + def msgstr; end + + # The locations where the PO entry is extracted + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#20 + def references; end + + # Returns the PO entry in PO format. + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#41 + def to_s; end + + # The comment content created by translator (PO editor) + # + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#14 + def translator_comment; end + + private + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#120 + def escape(string); end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#72 + def format_comment(mark, comment); end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#88 + def format_extracted_comment; end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#102 + def format_flags; end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#109 + def format_message(message); end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#92 + def format_references; end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#84 + def format_translator_comment; end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#137 + def merge_array(array1, array2); end + + # source://rdoc//lib/rdoc/generator/pot/po_entry.rb#133 + def merge_string(string1, string2); end +end + +# Generates ri data files +# +# source://rdoc//lib/rdoc/generator/ri.rb#5 +class RDoc::Generator::RI + # Set up a new ri generator + # + # @return [RI] a new instance of RI + # + # source://rdoc//lib/rdoc/generator/ri.rb#17 + def initialize(store, options); end + + # Writes the parsed data store to disk for use by ri. + # + # source://rdoc//lib/rdoc/generator/ri.rb#26 + def generate; end +end + +# A message container for a locale. +# +# This object provides the following two features: +# +# * Loads translated messages from .po file. +# * Translates a message into the locale. +# +# source://rdoc//lib/rdoc/i18n/locale.rb#10 +class RDoc::I18n::Locale + # Creates a new locale object for +name+ locale. +name+ must + # follow IETF language tag format. + # + # @return [Locale] a new instance of Locale + # + # source://rdoc//lib/rdoc/i18n/locale.rb#48 + def initialize(name); end + + # Loads translation messages from +locale_directory+/+@name+/rdoc.po + # or +locale_directory+/+@name+.po. The former has high priority. + # + # This method requires gettext gem for parsing .po file. If you + # don't have gettext gem, this method doesn't load .po file. This + # method warns and returns +false+. + # + # Returns +true+ if succeeded, +false+ otherwise. + # + # source://rdoc//lib/rdoc/i18n/locale.rb#63 + def load(locale_directory); end + + # The name of the locale. It uses IETF language tag format + # +[language[_territory][.codeset][@modifier]]+. + # + # See also {BCP 47 - Tags for Identifying + # Languages}[http://tools.ietf.org/rfc/bcp/bcp47.txt]. + # + # source://rdoc//lib/rdoc/i18n/locale.rb#42 + def name; end + + # Translates the +message+ into locale. If there is no translation + # messages for +message+ in locale, +message+ itself is returned. + # + # source://rdoc//lib/rdoc/i18n/locale.rb#98 + def translate(message); end + + class << self + # Returns the locale object for +locale_name+. + # + # source://rdoc//lib/rdoc/i18n/locale.rb#19 + def [](locale_name); end + + # Sets the locale object for +locale_name+. + # + # Normally, this method is not used. This method is useful for + # testing. + # + # source://rdoc//lib/rdoc/i18n/locale.rb#29 + def []=(locale_name, locale); end + end +end + +# An i18n supported text. +# +# This object provides the following two features: +# +# * Extracts translation messages from wrapped raw text. +# * Translates wrapped raw text in specified locale. +# +# Wrapped raw text is one of String, RDoc::Comment or Array of them. +# +# source://rdoc//lib/rdoc/i18n/text.rb#12 +class RDoc::I18n::Text + # Creates a new i18n supported text for +raw+ text. + # + # @return [Text] a new instance of Text + # + # source://rdoc//lib/rdoc/i18n/text.rb#17 + def initialize(raw); end + + # Extracts translation target messages and yields each message. + # + # Each yielded message is a Hash. It consists of the followings: + # + # :type :: :paragraph + # :paragraph :: String (The translation target message itself.) + # :line_no :: Integer (The line number of the :paragraph is started.) + # + # The above content may be added in the future. + # + # source://rdoc//lib/rdoc/i18n/text.rb#32 + def extract_messages; end + + # Translates raw text into +locale+. + # + # source://rdoc//lib/rdoc/i18n/text.rb#44 + def translate(locale); end + + private + + # source://rdoc//lib/rdoc/i18n/text.rb#88 + def each_line(raw, &block); end + + # @yield [part] + # + # source://rdoc//lib/rdoc/i18n/text.rb#101 + def emit_empty_line_event(line, line_no); end + + # source://rdoc//lib/rdoc/i18n/text.rb#110 + def emit_paragraph_event(paragraph, paragraph_start_line, line_no, &block); end + + # source://rdoc//lib/rdoc/i18n/text.rb#60 + def parse(&block); end +end + +# source://rdoc//lib/rdoc/markdown.rb#182 +class RDoc::Markdown + # Creates a new markdown parser that enables the given +extensions+. + # + # @return [Markdown] a new instance of Markdown + # + # source://rdoc//lib/rdoc/markdown.rb#668 + def initialize(extensions = T.unsafe(nil), debug = T.unsafe(nil)); end + + # Alphanumeric = %literals.Alphanumeric + # + # source://rdoc//lib/rdoc/markdown.rb#14705 + def _Alphanumeric; end + + # AlphanumericAscii = %literals.AlphanumericAscii + # + # source://rdoc//lib/rdoc/markdown.rb#14712 + def _AlphanumericAscii; end + + # AtxHeading = AtxStart:s @Sp AtxInline+:a (@Sp /#*/ @Sp)? @Newline { RDoc::Markup::Heading.new(s, a.join) } + # + # source://rdoc//lib/rdoc/markdown.rb#1162 + def _AtxHeading; end + + # AtxInline = !@Newline !(@Sp /#*/ @Sp @Newline) Inline + # + # source://rdoc//lib/rdoc/markdown.rb#1080 + def _AtxInline; end + + # AtxStart = < /\#{1,6}/ > { text.length } + # + # source://rdoc//lib/rdoc/markdown.rb#1136 + def _AtxStart; end + + # AutoLink = (AutoLinkUrl | AutoLinkEmail) + # + # source://rdoc//lib/rdoc/markdown.rb#11574 + def _AutoLink; end + + # AutoLinkEmail = "<" "mailto:"? < /[\w+.\/!%~$-]+/i "@" (!@Newline !">" .)+ > ">" { "mailto:#{text}" } + # + # source://rdoc//lib/rdoc/markdown.rb#11707 + def _AutoLinkEmail; end + + # AutoLinkUrl = "<" < /[A-Za-z]+/ "://" (!@Newline !">" .)+ > ">" { text } + # + # source://rdoc//lib/rdoc/markdown.rb#11592 + def _AutoLinkUrl; end + + # BOM = %literals.BOM + # + # source://rdoc//lib/rdoc/markdown.rb#14719 + def _BOM; end + + # BlankLine = @Sp @Newline { "\n" } + # + # source://rdoc//lib/rdoc/markdown.rb#14148 + def _BlankLine; end + + # Block = @BlankLine* (BlockQuote | Verbatim | CodeFence | Table | Note | Reference | HorizontalRule | Heading | OrderedList | BulletList | DefinitionList | HtmlBlock | StyleBlock | Para | Plain) + # + # source://rdoc//lib/rdoc/markdown.rb#939 + def _Block; end + + # BlockQuote = BlockQuoteRaw:a { RDoc::Markup::BlockQuote.new(*a) } + # + # source://rdoc//lib/rdoc/markdown.rb#1566 + def _BlockQuote; end + + # BlockQuoteRaw = @StartList:a (">" " "? Line:l { a << l } (!">" !@BlankLine Line:c { a << c })* (@BlankLine:n { a << n })*)+ { inner_parse a.join } + # + # source://rdoc//lib/rdoc/markdown.rb#1589 + def _BlockQuoteRaw; end + + # Bullet = !HorizontalRule @NonindentSpace /[+*-]/ @Spacechar+ + # + # source://rdoc//lib/rdoc/markdown.rb#2154 + def _Bullet; end + + # BulletList = &Bullet (ListTight | ListLoose):a { RDoc::Markup::List.new(:BULLET, *a) } + # + # source://rdoc//lib/rdoc/markdown.rb#2198 + def _BulletList; end + + # CharEntity = "&" < /[A-Za-z0-9]+/ > ";" { if entity = HTML_ENTITIES[text] then entity.pack 'U*' else "&#{text};" end } + # + # source://rdoc//lib/rdoc/markdown.rb#14812 + def _CharEntity; end + + # Code = (Ticks1 @Sp < ((!"`" Nonspacechar)+ | !Ticks1 /`+/ | !(@Sp Ticks1) (@Spacechar | @Newline !@BlankLine))+ > @Sp Ticks1 | Ticks2 @Sp < ((!"`" Nonspacechar)+ | !Ticks2 /`+/ | !(@Sp Ticks2) (@Spacechar | @Newline !@BlankLine))+ > @Sp Ticks2 | Ticks3 @Sp < ((!"`" Nonspacechar)+ | !Ticks3 /`+/ | !(@Sp Ticks3) (@Spacechar | @Newline !@BlankLine))+ > @Sp Ticks3 | Ticks4 @Sp < ((!"`" Nonspacechar)+ | !Ticks4 /`+/ | !(@Sp Ticks4) (@Spacechar | @Newline !@BlankLine))+ > @Sp Ticks4 | Ticks5 @Sp < ((!"`" Nonspacechar)+ | !Ticks5 /`+/ | !(@Sp Ticks5) (@Spacechar | @Newline !@BlankLine))+ > @Sp Ticks5) { "#{text}" } + # + # source://rdoc//lib/rdoc/markdown.rb#12511 + def _Code; end + + # CodeFence = &{ github? } Ticks3 (@Sp StrChunk:format)? Spnl < ((!"`" Nonspacechar)+ | !Ticks3 /`+/ | Spacechar | @Newline)+ > Ticks3 @Sp @Newline* { verbatim = RDoc::Markup::Verbatim.new text verbatim.format = format.intern if format.instance_of?(String) verbatim } + # + # source://rdoc//lib/rdoc/markdown.rb#15681 + def _CodeFence; end + + # DecEntity = "&#" < /[0-9]+/ > ";" { [text.to_i].pack 'U' } + # + # source://rdoc//lib/rdoc/markdown.rb#14776 + def _DecEntity; end + + # DefinitionList = &{ definition_lists? } DefinitionListItem+:list { RDoc::Markup::List.new :NOTE, *list.flatten } + # + # source://rdoc//lib/rdoc/markdown.rb#16339 + def _DefinitionList; end + + # DefinitionListDefinition = @NonindentSpace ":" @Space Inlines:a @BlankLine+ { paragraph a } + # + # source://rdoc//lib/rdoc/markdown.rb#16482 + def _DefinitionListDefinition; end + + # DefinitionListItem = DefinitionListLabel+:label DefinitionListDefinition+:defns { list_items = [] list_items << RDoc::Markup::ListItem.new(label, defns.shift) list_items.concat defns.map { |defn| RDoc::Markup::ListItem.new nil, defn } unless list_items.empty? list_items } + # + # source://rdoc//lib/rdoc/markdown.rb#16383 + def _DefinitionListItem; end + + # DefinitionListLabel = Inline:label @Sp @Newline { label } + # + # source://rdoc//lib/rdoc/markdown.rb#16449 + def _DefinitionListLabel; end + + # Digit = [0-9] + # + # source://rdoc//lib/rdoc/markdown.rb#14691 + def _Digit; end + + # Doc = BOM? Block*:a { RDoc::Markup::Document.new(*a.compact) } + # + # source://rdoc//lib/rdoc/markdown.rb#899 + def _Doc; end + + # Emph = (EmphStar | EmphUl) + # + # source://rdoc//lib/rdoc/markdown.rb#10283 + def _Emph; end + + # EmphStar = "*" !@Whitespace @StartList:a (!"*" Inline:b { a << b } | StrongStar:b { a << b })+ "*" { emphasis a.join } + # + # source://rdoc//lib/rdoc/markdown.rb#10319 + def _EmphStar; end + + # EmphUl = "_" !@Whitespace @StartList:a (!"_" Inline:b { a << b } | StrongUl:b { a << b })+ "_" { emphasis a.join } + # + # source://rdoc//lib/rdoc/markdown.rb#10477 + def _EmphUl; end + + # EmptyTitle = "" + # + # source://rdoc//lib/rdoc/markdown.rb#12086 + def _EmptyTitle; end + + # Endline = (@LineBreak | @TerminalEndline | @NormalEndline) + # + # source://rdoc//lib/rdoc/markdown.rb#9917 + def _Endline; end + + # Entity = (HexEntity | DecEntity | CharEntity):a { a } + # + # source://rdoc//lib/rdoc/markdown.rb#9880 + def _Entity; end + + # Enumerator = @NonindentSpace [0-9]+ "." @Spacechar+ + # + # source://rdoc//lib/rdoc/markdown.rb#2687 + def _Enumerator; end + + # Eof = !. + # + # source://rdoc//lib/rdoc/markdown.rb#14542 + def _Eof; end + + # EscapedChar = "\\" !@Newline < /[:\\`|*_{}\[\]()#+.!><-]/ > { text } + # + # source://rdoc//lib/rdoc/markdown.rb#9841 + def _EscapedChar; end + + # ExplicitLink = Label:l "(" @Sp Source:s Spnl Title @Sp ")" { "{#{l}}[#{s}]" } + # + # source://rdoc//lib/rdoc/markdown.rb#11147 + def _ExplicitLink; end + + # ExtendedSpecialChar = &{ notes? } "^" + # + # source://rdoc//lib/rdoc/markdown.rb#15184 + def _ExtendedSpecialChar; end + + # Heading = (SetextHeading | AtxHeading) + # + # source://rdoc//lib/rdoc/markdown.rb#1548 + def _Heading; end + + # HexEntity = /&#x/i < /[0-9a-fA-F]+/ > ";" { [text.to_i(16)].pack 'U' } + # + # source://rdoc//lib/rdoc/markdown.rb#14740 + def _HexEntity; end + + # HorizontalRule = @NonindentSpace ("*" @Sp "*" @Sp "*" (@Sp "*")* | "-" @Sp "-" @Sp "-" (@Sp "-")* | "_" @Sp "_" @Sp "_" (@Sp "_")*) @Sp @Newline @BlankLine+ { RDoc::Markup::Rule.new 1 } + # + # source://rdoc//lib/rdoc/markdown.rb#1932 + def _HorizontalRule; end + + # HtmlAnchor = HtmlOpenAnchor (HtmlAnchor | !HtmlCloseAnchor .)* HtmlCloseAnchor + # + # source://rdoc//lib/rdoc/markdown.rb#2971 + def _HtmlAnchor; end + + # HtmlAttribute = (AlphanumericAscii | "-")+ Spnl ("=" Spnl (Quoted | (!">" Nonspacechar)+))? Spnl + # + # source://rdoc//lib/rdoc/markdown.rb#14273 + def _HtmlAttribute; end + + # HtmlBlock = < (HtmlBlockInTags | HtmlComment | HtmlBlockSelfClosing | HtmlUnclosed) > @BlankLine+ { if html? then RDoc::Markup::Raw.new text end } + # + # source://rdoc//lib/rdoc/markdown.rb#8768 + def _HtmlBlock; end + + # HtmlBlockAddress = HtmlBlockOpenAddress (HtmlBlockAddress | !HtmlBlockCloseAddress .)* HtmlBlockCloseAddress + # + # source://rdoc//lib/rdoc/markdown.rb#3137 + def _HtmlBlockAddress; end + + # HtmlBlockBlockquote = HtmlBlockOpenBlockquote (HtmlBlockBlockquote | !HtmlBlockCloseBlockquote .)* HtmlBlockCloseBlockquote + # + # source://rdoc//lib/rdoc/markdown.rb#3303 + def _HtmlBlockBlockquote; end + + # HtmlBlockCenter = HtmlBlockOpenCenter (HtmlBlockCenter | !HtmlBlockCloseCenter .)* HtmlBlockCloseCenter + # + # source://rdoc//lib/rdoc/markdown.rb#3469 + def _HtmlBlockCenter; end + + # HtmlBlockCloseAddress = "<" Spnl "/" ("address" | "ADDRESS") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3085 + def _HtmlBlockCloseAddress; end + + # HtmlBlockCloseBlockquote = "<" Spnl "/" ("blockquote" | "BLOCKQUOTE") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3251 + def _HtmlBlockCloseBlockquote; end + + # HtmlBlockCloseCenter = "<" Spnl "/" ("center" | "CENTER") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3417 + def _HtmlBlockCloseCenter; end + + # HtmlBlockCloseDd = "<" Spnl "/" ("dd" | "DD") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6737 + def _HtmlBlockCloseDd; end + + # HtmlBlockCloseDir = "<" Spnl "/" ("dir" | "DIR") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3583 + def _HtmlBlockCloseDir; end + + # HtmlBlockCloseDiv = "<" Spnl "/" ("div" | "DIV") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3749 + def _HtmlBlockCloseDiv; end + + # HtmlBlockCloseDl = "<" Spnl "/" ("dl" | "DL") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3915 + def _HtmlBlockCloseDl; end + + # HtmlBlockCloseDt = "<" Spnl "/" ("dt" | "DT") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6903 + def _HtmlBlockCloseDt; end + + # HtmlBlockCloseFieldset = "<" Spnl "/" ("fieldset" | "FIELDSET") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4081 + def _HtmlBlockCloseFieldset; end + + # HtmlBlockCloseForm = "<" Spnl "/" ("form" | "FORM") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4247 + def _HtmlBlockCloseForm; end + + # HtmlBlockCloseFrameset = "<" Spnl "/" ("frameset" | "FRAMESET") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7069 + def _HtmlBlockCloseFrameset; end + + # HtmlBlockCloseH1 = "<" Spnl "/" ("h1" | "H1") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4413 + def _HtmlBlockCloseH1; end + + # HtmlBlockCloseH2 = "<" Spnl "/" ("h2" | "H2") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4579 + def _HtmlBlockCloseH2; end + + # HtmlBlockCloseH3 = "<" Spnl "/" ("h3" | "H3") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4745 + def _HtmlBlockCloseH3; end + + # HtmlBlockCloseH4 = "<" Spnl "/" ("h4" | "H4") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4911 + def _HtmlBlockCloseH4; end + + # HtmlBlockCloseH5 = "<" Spnl "/" ("h5" | "H5") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5077 + def _HtmlBlockCloseH5; end + + # HtmlBlockCloseH6 = "<" Spnl "/" ("h6" | "H6") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5243 + def _HtmlBlockCloseH6; end + + # HtmlBlockCloseHead = "<" Spnl "/" ("head" | "HEAD") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8552 + def _HtmlBlockCloseHead; end + + # HtmlBlockCloseLi = "<" Spnl "/" ("li" | "LI") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7235 + def _HtmlBlockCloseLi; end + + # HtmlBlockCloseMenu = "<" Spnl "/" ("menu" | "MENU") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5409 + def _HtmlBlockCloseMenu; end + + # HtmlBlockCloseNoframes = "<" Spnl "/" ("noframes" | "NOFRAMES") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5575 + def _HtmlBlockCloseNoframes; end + + # HtmlBlockCloseNoscript = "<" Spnl "/" ("noscript" | "NOSCRIPT") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5741 + def _HtmlBlockCloseNoscript; end + + # HtmlBlockCloseOl = "<" Spnl "/" ("ol" | "OL") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5907 + def _HtmlBlockCloseOl; end + + # HtmlBlockCloseP = "<" Spnl "/" ("p" | "P") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6073 + def _HtmlBlockCloseP; end + + # HtmlBlockClosePre = "<" Spnl "/" ("pre" | "PRE") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6239 + def _HtmlBlockClosePre; end + + # HtmlBlockCloseScript = "<" Spnl "/" ("script" | "SCRIPT") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8397 + def _HtmlBlockCloseScript; end + + # HtmlBlockCloseTable = "<" Spnl "/" ("table" | "TABLE") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6405 + def _HtmlBlockCloseTable; end + + # HtmlBlockCloseTbody = "<" Spnl "/" ("tbody" | "TBODY") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7401 + def _HtmlBlockCloseTbody; end + + # HtmlBlockCloseTd = "<" Spnl "/" ("td" | "TD") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7567 + def _HtmlBlockCloseTd; end + + # HtmlBlockCloseTfoot = "<" Spnl "/" ("tfoot" | "TFOOT") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7733 + def _HtmlBlockCloseTfoot; end + + # HtmlBlockCloseTh = "<" Spnl "/" ("th" | "TH") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7899 + def _HtmlBlockCloseTh; end + + # HtmlBlockCloseThead = "<" Spnl "/" ("thead" | "THEAD") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8065 + def _HtmlBlockCloseThead; end + + # HtmlBlockCloseTr = "<" Spnl "/" ("tr" | "TR") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8231 + def _HtmlBlockCloseTr; end + + # HtmlBlockCloseUl = "<" Spnl "/" ("ul" | "UL") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6571 + def _HtmlBlockCloseUl; end + + # HtmlBlockDd = HtmlBlockOpenDd (HtmlBlockDd | !HtmlBlockCloseDd .)* HtmlBlockCloseDd + # + # source://rdoc//lib/rdoc/markdown.rb#6789 + def _HtmlBlockDd; end + + # HtmlBlockDir = HtmlBlockOpenDir (HtmlBlockDir | !HtmlBlockCloseDir .)* HtmlBlockCloseDir + # + # source://rdoc//lib/rdoc/markdown.rb#3635 + def _HtmlBlockDir; end + + # HtmlBlockDiv = HtmlBlockOpenDiv (HtmlBlockDiv | !HtmlBlockCloseDiv .)* HtmlBlockCloseDiv + # + # source://rdoc//lib/rdoc/markdown.rb#3801 + def _HtmlBlockDiv; end + + # HtmlBlockDl = HtmlBlockOpenDl (HtmlBlockDl | !HtmlBlockCloseDl .)* HtmlBlockCloseDl + # + # source://rdoc//lib/rdoc/markdown.rb#3967 + def _HtmlBlockDl; end + + # HtmlBlockDt = HtmlBlockOpenDt (HtmlBlockDt | !HtmlBlockCloseDt .)* HtmlBlockCloseDt + # + # source://rdoc//lib/rdoc/markdown.rb#6955 + def _HtmlBlockDt; end + + # HtmlBlockFieldset = HtmlBlockOpenFieldset (HtmlBlockFieldset | !HtmlBlockCloseFieldset .)* HtmlBlockCloseFieldset + # + # source://rdoc//lib/rdoc/markdown.rb#4133 + def _HtmlBlockFieldset; end + + # HtmlBlockForm = HtmlBlockOpenForm (HtmlBlockForm | !HtmlBlockCloseForm .)* HtmlBlockCloseForm + # + # source://rdoc//lib/rdoc/markdown.rb#4299 + def _HtmlBlockForm; end + + # HtmlBlockFrameset = HtmlBlockOpenFrameset (HtmlBlockFrameset | !HtmlBlockCloseFrameset .)* HtmlBlockCloseFrameset + # + # source://rdoc//lib/rdoc/markdown.rb#7121 + def _HtmlBlockFrameset; end + + # HtmlBlockH1 = HtmlBlockOpenH1 (HtmlBlockH1 | !HtmlBlockCloseH1 .)* HtmlBlockCloseH1 + # + # source://rdoc//lib/rdoc/markdown.rb#4465 + def _HtmlBlockH1; end + + # HtmlBlockH2 = HtmlBlockOpenH2 (HtmlBlockH2 | !HtmlBlockCloseH2 .)* HtmlBlockCloseH2 + # + # source://rdoc//lib/rdoc/markdown.rb#4631 + def _HtmlBlockH2; end + + # HtmlBlockH3 = HtmlBlockOpenH3 (HtmlBlockH3 | !HtmlBlockCloseH3 .)* HtmlBlockCloseH3 + # + # source://rdoc//lib/rdoc/markdown.rb#4797 + def _HtmlBlockH3; end + + # HtmlBlockH4 = HtmlBlockOpenH4 (HtmlBlockH4 | !HtmlBlockCloseH4 .)* HtmlBlockCloseH4 + # + # source://rdoc//lib/rdoc/markdown.rb#4963 + def _HtmlBlockH4; end + + # HtmlBlockH5 = HtmlBlockOpenH5 (HtmlBlockH5 | !HtmlBlockCloseH5 .)* HtmlBlockCloseH5 + # + # source://rdoc//lib/rdoc/markdown.rb#5129 + def _HtmlBlockH5; end + + # HtmlBlockH6 = HtmlBlockOpenH6 (HtmlBlockH6 | !HtmlBlockCloseH6 .)* HtmlBlockCloseH6 + # + # source://rdoc//lib/rdoc/markdown.rb#5295 + def _HtmlBlockH6; end + + # HtmlBlockHead = HtmlBlockOpenHead (!HtmlBlockCloseHead .)* HtmlBlockCloseHead + # + # source://rdoc//lib/rdoc/markdown.rb#8604 + def _HtmlBlockHead; end + + # HtmlBlockInTags = (HtmlAnchor | HtmlBlockAddress | HtmlBlockBlockquote | HtmlBlockCenter | HtmlBlockDir | HtmlBlockDiv | HtmlBlockDl | HtmlBlockFieldset | HtmlBlockForm | HtmlBlockH1 | HtmlBlockH2 | HtmlBlockH3 | HtmlBlockH4 | HtmlBlockH5 | HtmlBlockH6 | HtmlBlockMenu | HtmlBlockNoframes | HtmlBlockNoscript | HtmlBlockOl | HtmlBlockP | HtmlBlockPre | HtmlBlockTable | HtmlBlockUl | HtmlBlockDd | HtmlBlockDt | HtmlBlockFrameset | HtmlBlockLi | HtmlBlockTbody | HtmlBlockTd | HtmlBlockTfoot | HtmlBlockTh | HtmlBlockThead | HtmlBlockTr | HtmlBlockScript | HtmlBlockHead) + # + # source://rdoc//lib/rdoc/markdown.rb#8651 + def _HtmlBlockInTags; end + + # HtmlBlockLi = HtmlBlockOpenLi (HtmlBlockLi | !HtmlBlockCloseLi .)* HtmlBlockCloseLi + # + # source://rdoc//lib/rdoc/markdown.rb#7287 + def _HtmlBlockLi; end + + # HtmlBlockMenu = HtmlBlockOpenMenu (HtmlBlockMenu | !HtmlBlockCloseMenu .)* HtmlBlockCloseMenu + # + # source://rdoc//lib/rdoc/markdown.rb#5461 + def _HtmlBlockMenu; end + + # HtmlBlockNoframes = HtmlBlockOpenNoframes (HtmlBlockNoframes | !HtmlBlockCloseNoframes .)* HtmlBlockCloseNoframes + # + # source://rdoc//lib/rdoc/markdown.rb#5627 + def _HtmlBlockNoframes; end + + # HtmlBlockNoscript = HtmlBlockOpenNoscript (HtmlBlockNoscript | !HtmlBlockCloseNoscript .)* HtmlBlockCloseNoscript + # + # source://rdoc//lib/rdoc/markdown.rb#5793 + def _HtmlBlockNoscript; end + + # HtmlBlockOl = HtmlBlockOpenOl (HtmlBlockOl | !HtmlBlockCloseOl .)* HtmlBlockCloseOl + # + # source://rdoc//lib/rdoc/markdown.rb#5959 + def _HtmlBlockOl; end + + # HtmlBlockOpenAddress = "<" Spnl ("address" | "ADDRESS") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3029 + def _HtmlBlockOpenAddress; end + + # HtmlBlockOpenBlockquote = "<" Spnl ("blockquote" | "BLOCKQUOTE") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3195 + def _HtmlBlockOpenBlockquote; end + + # HtmlBlockOpenCenter = "<" Spnl ("center" | "CENTER") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3361 + def _HtmlBlockOpenCenter; end + + # HtmlBlockOpenDd = "<" Spnl ("dd" | "DD") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6681 + def _HtmlBlockOpenDd; end + + # HtmlBlockOpenDir = "<" Spnl ("dir" | "DIR") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3527 + def _HtmlBlockOpenDir; end + + # HtmlBlockOpenDiv = "<" Spnl ("div" | "DIV") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3693 + def _HtmlBlockOpenDiv; end + + # HtmlBlockOpenDl = "<" Spnl ("dl" | "DL") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#3859 + def _HtmlBlockOpenDl; end + + # HtmlBlockOpenDt = "<" Spnl ("dt" | "DT") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6847 + def _HtmlBlockOpenDt; end + + # HtmlBlockOpenFieldset = "<" Spnl ("fieldset" | "FIELDSET") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4025 + def _HtmlBlockOpenFieldset; end + + # HtmlBlockOpenForm = "<" Spnl ("form" | "FORM") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4191 + def _HtmlBlockOpenForm; end + + # HtmlBlockOpenFrameset = "<" Spnl ("frameset" | "FRAMESET") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7013 + def _HtmlBlockOpenFrameset; end + + # HtmlBlockOpenH1 = "<" Spnl ("h1" | "H1") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4357 + def _HtmlBlockOpenH1; end + + # HtmlBlockOpenH2 = "<" Spnl ("h2" | "H2") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4523 + def _HtmlBlockOpenH2; end + + # HtmlBlockOpenH3 = "<" Spnl ("h3" | "H3") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4689 + def _HtmlBlockOpenH3; end + + # HtmlBlockOpenH4 = "<" Spnl ("h4" | "H4") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#4855 + def _HtmlBlockOpenH4; end + + # HtmlBlockOpenH5 = "<" Spnl ("h5" | "H5") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5021 + def _HtmlBlockOpenH5; end + + # HtmlBlockOpenH6 = "<" Spnl ("h6" | "H6") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5187 + def _HtmlBlockOpenH6; end + + # HtmlBlockOpenHead = "<" Spnl ("head" | "HEAD") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8496 + def _HtmlBlockOpenHead; end + + # HtmlBlockOpenLi = "<" Spnl ("li" | "LI") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7179 + def _HtmlBlockOpenLi; end + + # HtmlBlockOpenMenu = "<" Spnl ("menu" | "MENU") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5353 + def _HtmlBlockOpenMenu; end + + # HtmlBlockOpenNoframes = "<" Spnl ("noframes" | "NOFRAMES") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5519 + def _HtmlBlockOpenNoframes; end + + # HtmlBlockOpenNoscript = "<" Spnl ("noscript" | "NOSCRIPT") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5685 + def _HtmlBlockOpenNoscript; end + + # HtmlBlockOpenOl = "<" Spnl ("ol" | "OL") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#5851 + def _HtmlBlockOpenOl; end + + # HtmlBlockOpenP = "<" Spnl ("p" | "P") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6017 + def _HtmlBlockOpenP; end + + # HtmlBlockOpenPre = "<" Spnl ("pre" | "PRE") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6183 + def _HtmlBlockOpenPre; end + + # HtmlBlockOpenScript = "<" Spnl ("script" | "SCRIPT") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8341 + def _HtmlBlockOpenScript; end + + # HtmlBlockOpenTable = "<" Spnl ("table" | "TABLE") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6349 + def _HtmlBlockOpenTable; end + + # HtmlBlockOpenTbody = "<" Spnl ("tbody" | "TBODY") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7345 + def _HtmlBlockOpenTbody; end + + # HtmlBlockOpenTd = "<" Spnl ("td" | "TD") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7511 + def _HtmlBlockOpenTd; end + + # HtmlBlockOpenTfoot = "<" Spnl ("tfoot" | "TFOOT") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7677 + def _HtmlBlockOpenTfoot; end + + # HtmlBlockOpenTh = "<" Spnl ("th" | "TH") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#7843 + def _HtmlBlockOpenTh; end + + # HtmlBlockOpenThead = "<" Spnl ("thead" | "THEAD") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8009 + def _HtmlBlockOpenThead; end + + # HtmlBlockOpenTr = "<" Spnl ("tr" | "TR") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8175 + def _HtmlBlockOpenTr; end + + # HtmlBlockOpenUl = "<" Spnl ("ul" | "UL") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#6515 + def _HtmlBlockOpenUl; end + + # HtmlBlockP = HtmlBlockOpenP (HtmlBlockP | !HtmlBlockCloseP .)* HtmlBlockCloseP + # + # source://rdoc//lib/rdoc/markdown.rb#6125 + def _HtmlBlockP; end + + # HtmlBlockPre = HtmlBlockOpenPre (HtmlBlockPre | !HtmlBlockClosePre .)* HtmlBlockClosePre + # + # source://rdoc//lib/rdoc/markdown.rb#6291 + def _HtmlBlockPre; end + + # HtmlBlockScript = HtmlBlockOpenScript (!HtmlBlockCloseScript .)* HtmlBlockCloseScript + # + # source://rdoc//lib/rdoc/markdown.rb#8449 + def _HtmlBlockScript; end + + # HtmlBlockSelfClosing = "<" Spnl HtmlBlockType Spnl HtmlAttribute* "/" Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8896 + def _HtmlBlockSelfClosing; end + + # HtmlBlockTable = HtmlBlockOpenTable (HtmlBlockTable | !HtmlBlockCloseTable .)* HtmlBlockCloseTable + # + # source://rdoc//lib/rdoc/markdown.rb#6457 + def _HtmlBlockTable; end + + # HtmlBlockTbody = HtmlBlockOpenTbody (HtmlBlockTbody | !HtmlBlockCloseTbody .)* HtmlBlockCloseTbody + # + # source://rdoc//lib/rdoc/markdown.rb#7453 + def _HtmlBlockTbody; end + + # HtmlBlockTd = HtmlBlockOpenTd (HtmlBlockTd | !HtmlBlockCloseTd .)* HtmlBlockCloseTd + # + # source://rdoc//lib/rdoc/markdown.rb#7619 + def _HtmlBlockTd; end + + # HtmlBlockTfoot = HtmlBlockOpenTfoot (HtmlBlockTfoot | !HtmlBlockCloseTfoot .)* HtmlBlockCloseTfoot + # + # source://rdoc//lib/rdoc/markdown.rb#7785 + def _HtmlBlockTfoot; end + + # HtmlBlockTh = HtmlBlockOpenTh (HtmlBlockTh | !HtmlBlockCloseTh .)* HtmlBlockCloseTh + # + # source://rdoc//lib/rdoc/markdown.rb#7951 + def _HtmlBlockTh; end + + # HtmlBlockThead = HtmlBlockOpenThead (HtmlBlockThead | !HtmlBlockCloseThead .)* HtmlBlockCloseThead + # + # source://rdoc//lib/rdoc/markdown.rb#8117 + def _HtmlBlockThead; end + + # HtmlBlockTr = HtmlBlockOpenTr (HtmlBlockTr | !HtmlBlockCloseTr .)* HtmlBlockCloseTr + # + # source://rdoc//lib/rdoc/markdown.rb#8283 + def _HtmlBlockTr; end + + # HtmlBlockType = ("ADDRESS" | "BLOCKQUOTE" | "CENTER" | "DD" | "DIR" | "DIV" | "DL" | "DT" | "FIELDSET" | "FORM" | "FRAMESET" | "H1" | "H2" | "H3" | "H4" | "H5" | "H6" | "HR" | "ISINDEX" | "LI" | "MENU" | "NOFRAMES" | "NOSCRIPT" | "OL" | "P" | "PRE" | "SCRIPT" | "TABLE" | "TBODY" | "TD" | "TFOOT" | "TH" | "THEAD" | "TR" | "UL" | "address" | "blockquote" | "center" | "dd" | "dir" | "div" | "dl" | "dt" | "fieldset" | "form" | "frameset" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "hr" | "isindex" | "li" | "menu" | "noframes" | "noscript" | "ol" | "p" | "pre" | "script" | "table" | "tbody" | "td" | "tfoot" | "th" | "thead" | "tr" | "ul") + # + # source://rdoc//lib/rdoc/markdown.rb#8951 + def _HtmlBlockType; end + + # HtmlBlockUl = HtmlBlockOpenUl (HtmlBlockUl | !HtmlBlockCloseUl .)* HtmlBlockCloseUl + # + # source://rdoc//lib/rdoc/markdown.rb#6623 + def _HtmlBlockUl; end + + # HtmlCloseAnchor = "<" Spnl "/" ("a" | "A") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#2919 + def _HtmlCloseAnchor; end + + # HtmlComment = "" .)* "-->" + # + # source://rdoc//lib/rdoc/markdown.rb#14415 + def _HtmlComment; end + + # HtmlOpenAnchor = "<" Spnl ("a" | "A") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#2863 + def _HtmlOpenAnchor; end + + # HtmlTag = "<" Spnl "/"? AlphanumericAscii+ Spnl HtmlAttribute* "/"? Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#14462 + def _HtmlTag; end + + # HtmlUnclosed = "<" Spnl HtmlUnclosedType Spnl HtmlAttribute* Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#8828 + def _HtmlUnclosed; end + + # HtmlUnclosedType = ("HR" | "hr") + # + # source://rdoc//lib/rdoc/markdown.rb#8878 + def _HtmlUnclosedType; end + + # Image = "!" (ExplicitLink | ReferenceLink):a { "rdoc-image:#{a[/\[(.*)\]/, 1]}" } + # + # source://rdoc//lib/rdoc/markdown.rb#10972 + def _Image; end + + # InStyleTags = StyleOpen (!StyleClose .)* StyleClose + # + # source://rdoc//lib/rdoc/markdown.rb#9281 + def _InStyleTags; end + + # Indent = /\t| / + # + # source://rdoc//lib/rdoc/markdown.rb#14860 + def _Indent; end + + # IndentedLine = Indent Line + # + # source://rdoc//lib/rdoc/markdown.rb#14867 + def _IndentedLine; end + + # Inline = (Str | @Endline | UlOrStarLine | @Space | Strong | Emph | Strike | Image | Link | NoteReference | InlineNote | Code | RawHtml | Entity | EscapedChar | Symbol) + # + # source://rdoc//lib/rdoc/markdown.rb#9586 + def _Inline; end + + # InlineNote = &{ notes? } "^[" @StartList:a (!"]" Inline:l { a << l })+ "]" { ref = [:inline, @note_order.length] @footnotes[ref] = paragraph a note_for ref } + # + # source://rdoc//lib/rdoc/markdown.rb#15431 + def _InlineNote; end + + # Inlines = (!@Endline Inline:i { i } | @Endline:c !(&{ github? } Ticks3 /[^`\n]*$/) &Inline { c })+:chunks @Endline? { chunks } + # + # source://rdoc//lib/rdoc/markdown.rb#9365 + def _Inlines; end + + # Label = "[" (!"^" &{ notes? } | &. &{ !notes? }) @StartList:a (!"]" Inline:l { a << l })* "]" { a.join.gsub(/\s+/, ' ') } + # + # source://rdoc//lib/rdoc/markdown.rb#11907 + def _Label; end + + # Line = @RawLine:a { a } + # + # source://rdoc//lib/rdoc/markdown.rb#14938 + def _Line; end + + # LineBreak = " " @NormalEndline { RDoc::Markup::HardBreak.new } + # + # source://rdoc//lib/rdoc/markdown.rb#10042 + def _LineBreak; end + + # Link = (ExplicitLink | ReferenceLink | AutoLink) + # + # source://rdoc//lib/rdoc/markdown.rb#11011 + def _Link; end + + # ListBlock = !@BlankLine Line:a ListBlockLine*:c { [a, *c] } + # + # source://rdoc//lib/rdoc/markdown.rb#2548 + def _ListBlock; end + + # ListBlockLine = !@BlankLine !(Indent? (Bullet | Enumerator)) !HorizontalRule OptionallyIndentedLine + # + # source://rdoc//lib/rdoc/markdown.rb#2793 + def _ListBlockLine; end + + # ListContinuationBlock = @StartList:a @BlankLine* { a << "\n" } (Indent ListBlock:b { a.concat b })+ { a } + # + # source://rdoc//lib/rdoc/markdown.rb#2592 + def _ListContinuationBlock; end + + # ListItem = (Bullet | Enumerator) @StartList:a ListBlock:b { a << b } (ListContinuationBlock:c { a.push(*c) })* { list_item_from a } + # + # source://rdoc//lib/rdoc/markdown.rb#2392 + def _ListItem; end + + # ListItemTight = (Bullet | Enumerator) ListBlock:a (!@BlankLine ListContinuationBlock:b { a.push(*b) })* !ListContinuationBlock { list_item_from a } + # + # source://rdoc//lib/rdoc/markdown.rb#2468 + def _ListItemTight; end + + # ListLoose = @StartList:a (ListItem:b @BlankLine* { a << b })+ { a } + # + # source://rdoc//lib/rdoc/markdown.rb#2304 + def _ListLoose; end + + # ListTight = ListItemTight+:a @BlankLine* !(Bullet | Enumerator) { a } + # + # source://rdoc//lib/rdoc/markdown.rb#2239 + def _ListTight; end + + # Newline = %literals.Newline + # + # source://rdoc//lib/rdoc/markdown.rb#14726 + def _Newline; end + + # NonblankIndentedLine = !@BlankLine IndentedLine + # + # source://rdoc//lib/rdoc/markdown.rb#1821 + def _NonblankIndentedLine; end + + # NonindentSpace = / {0,3}/ + # + # source://rdoc//lib/rdoc/markdown.rb#14853 + def _NonindentSpace; end + + # Nonspacechar = !@Spacechar !@Newline . + # + # source://rdoc//lib/rdoc/markdown.rb#14552 + def _Nonspacechar; end + + # NormalChar = !(@SpecialChar | @Spacechar | @Newline) . + # + # source://rdoc//lib/rdoc/markdown.rb#14653 + def _NormalChar; end + + # NormalEndline = @Sp @Newline !@BlankLine !">" !AtxStart !(Line /={1,}|-{1,}/ @Newline) { "\n" } + # + # source://rdoc//lib/rdoc/markdown.rb#9938 + def _NormalEndline; end + + # Note = &{ notes? } @NonindentSpace RawNoteReference:ref ":" @Sp @StartList:a RawNoteBlock:i { a.concat i } (&Indent RawNoteBlock:i { a.concat i })* { @footnotes[ref] = paragraph a nil } + # + # source://rdoc//lib/rdoc/markdown.rb#15333 + def _Note; end + + # NoteReference = &{ notes? } RawNoteReference:ref { note_for ref } + # + # source://rdoc//lib/rdoc/markdown.rb#15207 + def _NoteReference; end + + # Notes = (Note | SkipBlock)* + # + # source://rdoc//lib/rdoc/markdown.rb#15538 + def _Notes; end + + # OptionallyIndentedLine = Indent? Line + # + # source://rdoc//lib/rdoc/markdown.rb#14888 + def _OptionallyIndentedLine; end + + # OrderedList = &Enumerator (ListTight | ListLoose):a { RDoc::Markup::List.new(:NUMBER, *a) } + # + # source://rdoc//lib/rdoc/markdown.rb#2752 + def _OrderedList; end + + # Para = @NonindentSpace Inlines:a @BlankLine+ { paragraph a } + # + # source://rdoc//lib/rdoc/markdown.rb#1014 + def _Para; end + + # Plain = Inlines:a { paragraph a } + # + # source://rdoc//lib/rdoc/markdown.rb#1057 + def _Plain; end + + # Quoted = ("\"" (!"\"" .)* "\"" | "'" (!"'" .)* "'") + # + # source://rdoc//lib/rdoc/markdown.rb#14175 + def _Quoted; end + + # RawHtml = < (HtmlComment | HtmlBlockScript | HtmlTag) > { if html? then text else '' end } + # + # source://rdoc//lib/rdoc/markdown.rb#14108 + def _RawHtml; end + + # RawLine = (< /[^\r\n]*/ @Newline > | < .+ > @Eof) { text } + # + # source://rdoc//lib/rdoc/markdown.rb#14961 + def _RawLine; end + + # RawNoteBlock = @StartList:a (!@BlankLine !RawNoteReference OptionallyIndentedLine:l { a << l })+ < @BlankLine* > { a << text } { a } + # + # source://rdoc//lib/rdoc/markdown.rb#15560 + def _RawNoteBlock; end + + # RawNoteReference = "[^" < (!@Newline !"]" .)+ > "]" { text } + # + # source://rdoc//lib/rdoc/markdown.rb#15237 + def _RawNoteReference; end + + # RefSrc = < Nonspacechar+ > { text } + # + # source://rdoc//lib/rdoc/markdown.rb#12026 + def _RefSrc; end + + # RefTitle = (RefTitleSingle | RefTitleDouble | RefTitleParens | EmptyTitle) + # + # source://rdoc//lib/rdoc/markdown.rb#12062 + def _RefTitle; end + + # RefTitleDouble = Spnl "\"" < (!("\"" @Sp @Newline | @Newline) .)* > "\"" { text } + # + # source://rdoc//lib/rdoc/markdown.rb#12185 + def _RefTitleDouble; end + + # RefTitleParens = Spnl "(" < (!(")" @Sp @Newline | @Newline) .)* > ")" { text } + # + # source://rdoc//lib/rdoc/markdown.rb#12277 + def _RefTitleParens; end + + # RefTitleSingle = Spnl "'" < (!("'" @Sp @Newline | @Newline) .)* > "'" { text } + # + # source://rdoc//lib/rdoc/markdown.rb#12093 + def _RefTitleSingle; end + + # Reference = @NonindentSpace !"[]" Label:label ":" Spnl RefSrc:link RefTitle @BlankLine+ { # TODO use title reference label, link nil } + # + # source://rdoc//lib/rdoc/markdown.rb#11832 + def _Reference; end + + # ReferenceLink = (ReferenceLinkDouble | ReferenceLinkSingle) + # + # source://rdoc//lib/rdoc/markdown.rb#11032 + def _ReferenceLink; end + + # ReferenceLinkDouble = Label:content < Spnl > !"[]" Label:label { link_to content, label, text } + # + # source://rdoc//lib/rdoc/markdown.rb#11050 + def _ReferenceLinkDouble; end + + # ReferenceLinkSingle = Label:content < (Spnl "[]")? > { link_to content, content, text } + # + # source://rdoc//lib/rdoc/markdown.rb#11096 + def _ReferenceLinkSingle; end + + # References = (Reference | SkipBlock)* + # + # source://rdoc//lib/rdoc/markdown.rb#12369 + def _References; end + + # SetextBottom1 = /={1,}/ @Newline + # + # source://rdoc//lib/rdoc/markdown.rb#1262 + def _SetextBottom1; end + + # SetextBottom2 = /-{1,}/ @Newline + # + # source://rdoc//lib/rdoc/markdown.rb#1283 + def _SetextBottom2; end + + # SetextHeading = (SetextHeading1 | SetextHeading2) + # + # source://rdoc//lib/rdoc/markdown.rb#1244 + def _SetextHeading; end + + # SetextHeading1 = &(@RawLine SetextBottom1) @StartList:a (!@Endline Inline:b { a << b })+ @Sp @Newline SetextBottom1 { RDoc::Markup::Heading.new(1, a.join) } + # + # source://rdoc//lib/rdoc/markdown.rb#1304 + def _SetextHeading1; end + + # SetextHeading2 = &(@RawLine SetextBottom2) @StartList:a (!@Endline Inline:b { a << b })+ @Sp @Newline SetextBottom2 { RDoc::Markup::Heading.new(2, a.join) } + # + # source://rdoc//lib/rdoc/markdown.rb#1426 + def _SetextHeading2; end + + # SkipBlock = (HtmlBlock | (!"#" !SetextBottom1 !SetextBottom2 !@BlankLine @RawLine)+ @BlankLine* | @BlankLine+ | @RawLine) + # + # source://rdoc//lib/rdoc/markdown.rb#15040 + def _SkipBlock; end + + # Source = ("<" < SourceContents > ">" | < SourceContents >) { text } + # + # source://rdoc//lib/rdoc/markdown.rb#11206 + def _Source; end + + # SourceContents = ((!"(" !")" !">" Nonspacechar)+ | "(" SourceContents ")")* + # + # source://rdoc//lib/rdoc/markdown.rb#11266 + def _SourceContents; end + + # Sp = @Spacechar* + # + # source://rdoc//lib/rdoc/markdown.rb#14584 + def _Sp; end + + # Space = @Spacechar+ { " " } + # + # source://rdoc//lib/rdoc/markdown.rb#9646 + def _Space; end + + # Spacechar = %literals.Spacechar + # + # source://rdoc//lib/rdoc/markdown.rb#14733 + def _Spacechar; end + + # SpecialChar = (/[~*_`&\[\]() { text } | < @Spacechar /\*+/ &@Spacechar > { text }) + # + # source://rdoc//lib/rdoc/markdown.rb#10129 + def _StarLine; end + + # StartList = &. { [] } + # + # source://rdoc//lib/rdoc/markdown.rb#14914 + def _StartList; end + + # Str = @StartList:a < @NormalChar+ > { a = text } (StrChunk:c { a << c })* { a } + # + # source://rdoc//lib/rdoc/markdown.rb#9678 + def _Str; end + + # StrChunk = < (@NormalChar | /_+/ &Alphanumeric)+ > { text } + # + # source://rdoc//lib/rdoc/markdown.rb#9751 + def _StrChunk; end + + # Strike = &{ strike? } "~~" !@Whitespace @StartList:a (!"~~" Inline:b { a << b })+ "~~" { strike a.join } + # + # source://rdoc//lib/rdoc/markdown.rb#10861 + def _Strike; end + + # Strong = (StrongStar | StrongUl) + # + # source://rdoc//lib/rdoc/markdown.rb#10635 + def _Strong; end + + # StrongStar = "**" !@Whitespace @StartList:a (!"**" Inline:b { a << b })+ "**" { strong a.join } + # + # source://rdoc//lib/rdoc/markdown.rb#10653 + def _StrongStar; end + + # StrongUl = "__" !@Whitespace @StartList:a (!"__" Inline:b { a << b })+ "__" { strong a.join } + # + # source://rdoc//lib/rdoc/markdown.rb#10757 + def _StrongUl; end + + # StyleBlock = < InStyleTags > @BlankLine* { if css? then RDoc::Markup::Raw.new text end } + # + # source://rdoc//lib/rdoc/markdown.rb#9328 + def _StyleBlock; end + + # StyleClose = "<" Spnl "/" ("style" | "STYLE") Spnl ">" + # + # source://rdoc//lib/rdoc/markdown.rb#9229 + def _StyleClose; end + + # StyleOpen = "<" Spnl ("style" | "STYLE") Spnl HtmlAttribute* ">" + # + # source://rdoc//lib/rdoc/markdown.rb#9173 + def _StyleOpen; end + + # Symbol = < @SpecialChar > { text } + # + # source://rdoc//lib/rdoc/markdown.rb#10069 + def _Symbol; end + + # Table = &{ github? } TableHead:header TableLine:line TableRow+:body { table = RDoc::Markup::Table.new(header, line, body) } + # + # source://rdoc//lib/rdoc/markdown.rb#15937 + def _Table; end + + # TableAlign = < /:?-+:?/ > @Sp { text.start_with?(":") ? (text.end_with?(":") ? :center : :left) : (text.end_with?(":") ? :right : nil) } + # + # source://rdoc//lib/rdoc/markdown.rb#16304 + def _TableAlign; end + + # TableAlign2 = "|" @Sp TableAlign + # + # source://rdoc//lib/rdoc/markdown.rb#16278 + def _TableAlign2; end + + # TableHead = TableItem2+:items "|"? @Newline { items } + # + # source://rdoc//lib/rdoc/markdown.rb#15993 + def _TableHead; end + + # TableItem = < /(?:\\.|[^|\n])+/ > { text.strip.gsub(/\\(.)/, '\1') } + # + # source://rdoc//lib/rdoc/markdown.rb#16159 + def _TableItem; end + + # TableItem2 = "|" TableItem + # + # source://rdoc//lib/rdoc/markdown.rb#16138 + def _TableItem2; end + + # TableLine = ((TableAlign:align1 TableAlign2*:aligns {[align1, *aligns] }):line | TableAlign2+:line) "|"? @Newline { line } + # + # source://rdoc//lib/rdoc/markdown.rb#16185 + def _TableLine; end + + # TableRow = ((TableItem:item1 TableItem2*:items { [item1, *items] }):row | TableItem2+:row) "|"? @Newline { row } + # + # source://rdoc//lib/rdoc/markdown.rb#16045 + def _TableRow; end + + # TerminalEndline = @Sp @Newline @Eof + # + # source://rdoc//lib/rdoc/markdown.rb#10016 + def _TerminalEndline; end + + # Ticks1 = "`" !"`" + # + # source://rdoc//lib/rdoc/markdown.rb#12391 + def _Ticks1; end + + # Ticks2 = "``" !"`" + # + # source://rdoc//lib/rdoc/markdown.rb#12415 + def _Ticks2; end + + # Ticks3 = "```" !"`" + # + # source://rdoc//lib/rdoc/markdown.rb#12439 + def _Ticks3; end + + # Ticks4 = "````" !"`" + # + # source://rdoc//lib/rdoc/markdown.rb#12463 + def _Ticks4; end + + # Ticks5 = "`````" !"`" + # + # source://rdoc//lib/rdoc/markdown.rb#12487 + def _Ticks5; end + + # Title = (TitleSingle | TitleDouble | ""):a { a } + # + # source://rdoc//lib/rdoc/markdown.rb#11383 + def _Title; end + + # TitleDouble = "\"" (!("\"" @Sp (")" | @Newline)) .)* "\"" + # + # source://rdoc//lib/rdoc/markdown.rb#11497 + def _TitleDouble; end + + # TitleSingle = "'" (!("'" @Sp (")" | @Newline)) .)* "'" + # + # source://rdoc//lib/rdoc/markdown.rb#11420 + def _TitleSingle; end + + # UlLine = (< /_{4,}/ > { text } | < @Spacechar /_+/ &@Spacechar > { text }) + # + # source://rdoc//lib/rdoc/markdown.rb#10206 + def _UlLine; end + + # UlOrStarLine = (UlLine | StarLine):a { a } + # + # source://rdoc//lib/rdoc/markdown.rb#10095 + def _UlOrStarLine; end + + # Verbatim = VerbatimChunk+:a { RDoc::Markup::Verbatim.new(*a.flatten) } + # + # source://rdoc//lib/rdoc/markdown.rb#1895 + def _Verbatim; end + + # VerbatimChunk = @BlankLine*:a NonblankIndentedLine+:b { a.concat b } + # + # source://rdoc//lib/rdoc/markdown.rb#1845 + def _VerbatimChunk; end + + # Whitespace = (@Spacechar | @Newline) + # + # source://rdoc//lib/rdoc/markdown.rb#10301 + def _Whitespace; end + + # root = Doc + # + # source://rdoc//lib/rdoc/markdown.rb#892 + def _root; end + + # source://rdoc//lib/rdoc/markdown.rb#502 + def apply(rule); end + + # source://rdoc//lib/rdoc/markdown.rb#468 + def apply_with_args(rule, *args); end + + # source://rdoc//lib/rdoc/markdown.rb#610 + def break_on_newline=(enable); end + + # source://rdoc//lib/rdoc/markdown.rb#606 + def break_on_newline?; end + + # source://rdoc//lib/rdoc/markdown.rb#610 + def css=(enable); end + + # source://rdoc//lib/rdoc/markdown.rb#606 + def css?; end + + # source://rdoc//lib/rdoc/markdown.rb#250 + def current_character(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown.rb#211 + def current_column(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown.rb#234 + def current_line(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown.rb#259 + def current_pos_info(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown.rb#610 + def definition_lists=(enable); end + + # source://rdoc//lib/rdoc/markdown.rb#606 + def definition_lists?; end + + # Wraps `text` in emphasis for rdoc inline formatting + # + # source://rdoc//lib/rdoc/markdown.rb#683 + def emphasis(text); end + + # :category: Extensions + # + # Enables or disables the extension with `name` + # + # source://rdoc//lib/rdoc/markdown.rb#705 + def extension(name, enable); end + + # :category: Extensions + # + # Is the extension `name` enabled? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markdown.rb#696 + def extension?(name); end + + # source://rdoc//lib/rdoc/markdown.rb#449 + def external_invoke(other, rule, *args); end + + # Returns the value of attribute failed_rule. + # + # source://rdoc//lib/rdoc/markdown.rb#371 + def failed_rule; end + + # Returns the value of attribute failing_rule_offset. + # + # source://rdoc//lib/rdoc/markdown.rb#208 + def failing_rule_offset; end + + # source://rdoc//lib/rdoc/markdown.rb#318 + def failure_caret; end + + # source://rdoc//lib/rdoc/markdown.rb#323 + def failure_character; end + + # source://rdoc//lib/rdoc/markdown.rb#306 + def failure_info; end + + # source://rdoc//lib/rdoc/markdown.rb#327 + def failure_oneline; end + + # source://rdoc//lib/rdoc/markdown.rb#393 + def get_byte; end + + # source://rdoc//lib/rdoc/markdown.rb#271 + def get_line(no); end + + # source://rdoc//lib/rdoc/markdown.rb#285 + def get_text(start); end + + # source://rdoc//lib/rdoc/markdown.rb#610 + def github=(enable); end + + # source://rdoc//lib/rdoc/markdown.rb#606 + def github?; end + + # source://rdoc//lib/rdoc/markdown.rb#535 + def grow_lr(rule, args, start_pos, m); end + + # source://rdoc//lib/rdoc/markdown.rb#610 + def html=(enable); end + + # source://rdoc//lib/rdoc/markdown.rb#606 + def html?; end + + # Parses `text` in a clone of this parser. This is used for handling nested + # lists the same way as markdown_parser. + # + # source://rdoc//lib/rdoc/markdown.rb#717 + def inner_parse(text); end + + # source://rdoc//lib/rdoc/markdown.rb#267 + def lines; end + + # Finds a link reference for `label` and creates a new link to it with + # `content` as the link text. If `label` was not encountered in the + # reference-gathering parser pass the label and content are reconstructed + # with the linking `text` (usually whitespace). + # + # @raise [ParseError] + # + # source://rdoc//lib/rdoc/markdown.rb#737 + def link_to(content, label = T.unsafe(nil), text = T.unsafe(nil)); end + + # Creates an RDoc::Markup::ListItem by parsing the `unparsed` content from + # the first parsing pass. + # + # source://rdoc//lib/rdoc/markdown.rb#754 + def list_item_from(unparsed); end + + # source://rdoc//lib/rdoc/markdown.rb#373 + def match_string(str); end + + # Stores `label` as a note and fills in previously unknown note references. + # + # source://rdoc//lib/rdoc/markdown.rb#762 + def note(label); end + + # Creates a new link for the footnote `reference` and adds the reference to + # the note order list for proper display at the end of the document. + # + # source://rdoc//lib/rdoc/markdown.rb#776 + def note_for(ref); end + + # source://rdoc//lib/rdoc/markdown.rb#610 + def notes=(enable); end + + # source://rdoc//lib/rdoc/markdown.rb#606 + def notes?; end + + # Creates an RDoc::Markup::Paragraph from `parts` and including + # extension-specific behavior + # + # source://rdoc//lib/rdoc/markdown.rb#793 + def paragraph(parts); end + + # Parses `markdown` into an RDoc::Document + # + # source://rdoc//lib/rdoc/markdown.rb#808 + def parse(markdown); end + + # The internal kpeg parse method + # + # source://rdoc//lib/rdoc/markdown.rb#414 + def peg_parse(rule = T.unsafe(nil)); end + + # Returns the value of attribute pos. + # + # source://rdoc//lib/rdoc/markdown.rb#209 + def pos; end + + # Sets the attribute pos + # + # @param value the value to set the attribute pos to. + # + # source://rdoc//lib/rdoc/markdown.rb#209 + def pos=(_arg0); end + + # source://rdoc//lib/rdoc/markdown.rb#221 + def position_line_offsets; end + + # @raise [ParseError] + # + # source://rdoc//lib/rdoc/markdown.rb#341 + def raise_error; end + + # Stores `label` as a reference to `link` and fills in previously unknown + # link references. + # + # source://rdoc//lib/rdoc/markdown.rb#855 + def reference(label, link); end + + # Returns the value of attribute result. + # + # source://rdoc//lib/rdoc/markdown.rb#209 + def result; end + + # Sets the attribute result + # + # @param value the value to set the attribute result to. + # + # source://rdoc//lib/rdoc/markdown.rb#209 + def result=(_arg0); end + + # source://rdoc//lib/rdoc/markdown.rb#383 + def scan(reg); end + + # source://rdoc//lib/rdoc/markdown.rb#364 + def set_failed_rule(name); end + + # Sets the string and current parsing position for the parser. + # + # source://rdoc//lib/rdoc/markdown.rb#290 + def set_string(string, pos); end + + # :stopdoc: + # + # source://rdoc//lib/rdoc/markdown.rb#887 + def setup_foreign_grammar; end + + # Prepares for parsing +str+. If you define a custom initialize you must + # call this method before #parse + # + # source://rdoc//lib/rdoc/markdown.rb#196 + def setup_parser(str, debug = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown.rb#345 + def show_error(io = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown.rb#297 + def show_pos; end + + # Wraps `text` in strike markup for rdoc inline formatting + # + # source://rdoc//lib/rdoc/markdown.rb#877 + def strike(text); end + + # source://rdoc//lib/rdoc/markdown.rb#610 + def strike=(enable); end + + # source://rdoc//lib/rdoc/markdown.rb#606 + def strike?; end + + # Returns the value of attribute string. + # + # source://rdoc//lib/rdoc/markdown.rb#207 + def string; end + + # Wraps `text` in strong markup for rdoc inline formatting + # + # source://rdoc//lib/rdoc/markdown.rb#866 + def strong(text); end + + private + + # This is distinct from setup_parser so that a standalone parser + # can redefine #initialize and still have access to the proper + # parser setup code. + # TODO remove when kpeg 0.10 is released + # + # @return [Markdown] a new instance of Markdown + # + # source://rdoc//lib/rdoc/markdown.rb#188 + def orig_initialize(str, debug = T.unsafe(nil)); end + + class << self + # Creates extension methods for the `name` extension to enable and disable + # the extension and to query if they are active. + # + # source://rdoc//lib/rdoc/markdown.rb#603 + def extension(name); end + + # Parses the `markdown` document into an RDoc::Document using the default + # extensions. + # + # source://rdoc//lib/rdoc/markdown.rb#656 + def parse(markdown); end + + # source://rdoc//lib/rdoc/markdown.rb#566 + def rule_info(name, rendered); end + end +end + +# source://rdoc//lib/rdoc/markdown.rb#257 +class RDoc::Markdown::KpegPosInfo < ::Struct + # Returns the value of attribute char + # + # @return [Object] the current value of char + def char; end + + # Sets the attribute char + # + # @param value [Object] the value to set the attribute char to. + # @return [Object] the newly set value + def char=(_); end + + # Returns the value of attribute col + # + # @return [Object] the current value of col + def col; end + + # Sets the attribute col + # + # @param value [Object] the value to set the attribute col to. + # @return [Object] the newly set value + def col=(_); end + + # Returns the value of attribute line + # + # @return [Object] the current value of line + def line; end + + # Sets the attribute line + # + # @param value [Object] the value to set the attribute line to. + # @return [Object] the newly set value + def line=(_); end + + # Returns the value of attribute lno + # + # @return [Object] the current value of lno + def lno; end + + # Sets the attribute lno + # + # @param value [Object] the value to set the attribute lno to. + # @return [Object] the newly set value + def lno=(_); end + + # Returns the value of attribute pos + # + # @return [Object] the current value of pos + def pos; end + + # Sets the attribute pos + # + # @param value [Object] the value to set the attribute pos to. + # @return [Object] the newly set value + def pos=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# This set of literals is for Ruby 1.9 regular expressions and gives full +# unicode support. +# +# Unlike peg-markdown, this set of literals recognizes Unicode alphanumeric +# characters, newlines and spaces. +# +# source://rdoc//lib/rdoc/markdown/literals.rb#11 +class RDoc::Markdown::Literals + # This is distinct from setup_parser so that a standalone parser + # can redefine #initialize and still have access to the proper + # parser setup code. + # + # @return [Literals] a new instance of Literals + # + # source://rdoc//lib/rdoc/markdown/literals.rb#17 + def initialize(str, debug = T.unsafe(nil)); end + + # Alphanumeric = /\p{Word}/ + # + # source://rdoc//lib/rdoc/markdown/literals.rb#405 + def _Alphanumeric; end + + # AlphanumericAscii = /[A-Za-z0-9]/ + # + # source://rdoc//lib/rdoc/markdown/literals.rb#412 + def _AlphanumericAscii; end + + # BOM = "uFEFF" + # + # source://rdoc//lib/rdoc/markdown/literals.rb#419 + def _BOM; end + + # Newline = /\n|\r\n?|\p{Zl}|\p{Zp}/ + # + # source://rdoc//lib/rdoc/markdown/literals.rb#426 + def _Newline; end + + # NonAlphanumeric = /\p{^Word}/ + # + # source://rdoc//lib/rdoc/markdown/literals.rb#433 + def _NonAlphanumeric; end + + # Spacechar = /\t|\p{Zs}/ + # + # source://rdoc//lib/rdoc/markdown/literals.rb#440 + def _Spacechar; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#331 + def apply(rule); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#297 + def apply_with_args(rule, *args); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#79 + def current_character(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#40 + def current_column(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#63 + def current_line(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#88 + def current_pos_info(target = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#278 + def external_invoke(other, rule, *args); end + + # Returns the value of attribute failed_rule. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#200 + def failed_rule; end + + # Returns the value of attribute failing_rule_offset. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#37 + def failing_rule_offset; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#147 + def failure_caret; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#152 + def failure_character; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#135 + def failure_info; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#156 + def failure_oneline; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#222 + def get_byte; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#100 + def get_line(no); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#114 + def get_text(start); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#364 + def grow_lr(rule, args, start_pos, m); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#96 + def lines; end + + # source://rdoc//lib/rdoc/markdown/literals.rb#202 + def match_string(str); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#243 + def parse(rule = T.unsafe(nil)); end + + # Returns the value of attribute pos. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#38 + def pos; end + + # Sets the attribute pos + # + # @param value the value to set the attribute pos to. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#38 + def pos=(_arg0); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#50 + def position_line_offsets; end + + # @raise [ParseError] + # + # source://rdoc//lib/rdoc/markdown/literals.rb#170 + def raise_error; end + + # Returns the value of attribute result. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#38 + def result; end + + # Sets the attribute result + # + # @param value the value to set the attribute result to. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#38 + def result=(_arg0); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#212 + def scan(reg); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#193 + def set_failed_rule(name); end + + # Sets the string and current parsing position for the parser. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#119 + def set_string(string, pos); end + + # :startdoc: + # :stopdoc: + # + # source://rdoc//lib/rdoc/markdown/literals.rb#402 + def setup_foreign_grammar; end + + # Prepares for parsing +str+. If you define a custom initialize you must + # call this method before #parse + # + # source://rdoc//lib/rdoc/markdown/literals.rb#25 + def setup_parser(str, debug = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#174 + def show_error(io = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#126 + def show_pos; end + + # Returns the value of attribute string. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#36 + def string; end + + class << self + # source://rdoc//lib/rdoc/markdown/literals.rb#395 + def rule_info(name, rendered); end + end +end + +# source://rdoc//lib/rdoc/markdown/literals.rb#86 +class RDoc::Markdown::Literals::KpegPosInfo < ::Struct + # Returns the value of attribute char + # + # @return [Object] the current value of char + def char; end + + # Sets the attribute char + # + # @param value [Object] the value to set the attribute char to. + # @return [Object] the newly set value + def char=(_); end + + # Returns the value of attribute col + # + # @return [Object] the current value of col + def col; end + + # Sets the attribute col + # + # @param value [Object] the value to set the attribute col to. + # @return [Object] the newly set value + def col=(_); end + + # Returns the value of attribute line + # + # @return [Object] the current value of line + def line; end + + # Sets the attribute line + # + # @param value [Object] the value to set the attribute line to. + # @return [Object] the newly set value + def line=(_); end + + # Returns the value of attribute lno + # + # @return [Object] the current value of lno + def lno; end + + # Sets the attribute lno + # + # @param value [Object] the value to set the attribute lno to. + # @return [Object] the newly set value + def lno=(_); end + + # Returns the value of attribute pos + # + # @return [Object] the current value of pos + def pos; end + + # Sets the attribute pos + # + # @param value [Object] the value to set the attribute pos to. + # @return [Object] the newly set value + def pos=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://rdoc//lib/rdoc/markdown/literals.rb#257 +class RDoc::Markdown::Literals::MemoEntry + # @return [MemoEntry] a new instance of MemoEntry + # + # source://rdoc//lib/rdoc/markdown/literals.rb#258 + def initialize(ans, pos); end + + # Returns the value of attribute ans. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#266 + def ans; end + + # Returns the value of attribute left_rec. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#267 + def left_rec; end + + # Sets the attribute left_rec + # + # @param value the value to set the attribute left_rec to. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#267 + def left_rec=(_arg0); end + + # source://rdoc//lib/rdoc/markdown/literals.rb#269 + def move!(ans, pos, result); end + + # Returns the value of attribute pos. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#266 + def pos; end + + # Returns the value of attribute result. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#266 + def result; end + + # Returns the value of attribute set. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#266 + def set; end +end + +# source://rdoc//lib/rdoc/markdown/literals.rb#386 +class RDoc::Markdown::Literals::RuleInfo + # @return [RuleInfo] a new instance of RuleInfo + # + # source://rdoc//lib/rdoc/markdown/literals.rb#387 + def initialize(name, rendered); end + + # Returns the value of attribute name. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#392 + def name; end + + # Returns the value of attribute rendered. + # + # source://rdoc//lib/rdoc/markdown/literals.rb#392 + def rendered; end +end + +# source://rdoc//lib/rdoc/markdown.rb#428 +class RDoc::Markdown::MemoEntry + # @return [MemoEntry] a new instance of MemoEntry + # + # source://rdoc//lib/rdoc/markdown.rb#429 + def initialize(ans, pos); end + + # Returns the value of attribute ans. + # + # source://rdoc//lib/rdoc/markdown.rb#437 + def ans; end + + # Returns the value of attribute left_rec. + # + # source://rdoc//lib/rdoc/markdown.rb#438 + def left_rec; end + + # Sets the attribute left_rec + # + # @param value the value to set the attribute left_rec to. + # + # source://rdoc//lib/rdoc/markdown.rb#438 + def left_rec=(_arg0); end + + # source://rdoc//lib/rdoc/markdown.rb#440 + def move!(ans, pos, result); end + + # Returns the value of attribute pos. + # + # source://rdoc//lib/rdoc/markdown.rb#437 + def pos; end + + # Returns the value of attribute result. + # + # source://rdoc//lib/rdoc/markdown.rb#437 + def result; end + + # Returns the value of attribute set. + # + # source://rdoc//lib/rdoc/markdown.rb#437 + def set; end +end + +# source://rdoc//lib/rdoc/markdown.rb#557 +class RDoc::Markdown::RuleInfo + # @return [RuleInfo] a new instance of RuleInfo + # + # source://rdoc//lib/rdoc/markdown.rb#558 + def initialize(name, rendered); end + + # Returns the value of attribute name. + # + # source://rdoc//lib/rdoc/markdown.rb#563 + def name; end + + # Returns the value of attribute rendered. + # + # source://rdoc//lib/rdoc/markdown.rb#563 + def rendered; end +end + +# source://rdoc//lib/rdoc/markup.rb#106 +class RDoc::Markup + # Take a block of text and use various heuristics to determine its + # structure (paragraphs, lists, and so on). Invoke an event handler as we + # identify significant chunks. + # + # @return [Markup] a new instance of Markup + # + # source://rdoc//lib/rdoc/markup.rb#146 + def initialize(attribute_manager = T.unsafe(nil)); end + + # Add to the sequences recognized as general markup. + # + # source://rdoc//lib/rdoc/markup.rb#163 + def add_html(tag, name); end + + # Add to other inline sequences. For example, we could add WikiWords using + # something like: + # + # parser.add_regexp_handling(/\b([A-Z][a-z]+[A-Z]\w+)/, :WIKIWORD) + # + # Each wiki word will be presented to the output formatter. + # + # source://rdoc//lib/rdoc/markup.rb#175 + def add_regexp_handling(pattern, name); end + + # Add to the sequences used to add formatting to an individual word (such + # as *bold*). Matching entries will generate attributes that the output + # formatters can recognize by their +name+. + # + # source://rdoc//lib/rdoc/markup.rb#156 + def add_word_pair(start, stop, name); end + + # An AttributeManager which handles inline markup. + # + # source://rdoc//lib/rdoc/markup.rb#111 + def attribute_manager; end + + # We take +input+, parse it if necessary, then invoke the output +formatter+ + # using a Visitor to render the result. + # + # source://rdoc//lib/rdoc/markup.rb#183 + def convert(input, formatter); end + + class << self + # Parses +str+ into an RDoc::Markup::Document. + # + # source://rdoc//lib/rdoc/markup.rb#116 + def parse(str); end + end +end + +# An AttrChanger records a change in attributes. It contains a bitmap of the +# attributes to turn on, and a bitmap of those to turn off. +# +# source://rdoc//lib/rdoc/markup/attr_changer.rb#4 +class RDoc::Markup::AttrChanger < ::Struct + # source://rdoc//lib/rdoc/markup/attr_changer.rb#18 + def inspect; end + + # source://rdoc//lib/rdoc/markup/attr_changer.rb#14 + def to_s; end +end + +# An array of attributes which parallels the characters in a string. +# +# source://rdoc//lib/rdoc/markup/attr_span.rb#5 +class RDoc::Markup::AttrSpan + # Creates a new AttrSpan for +length+ characters + # + # @return [AttrSpan] a new instance of AttrSpan + # + # source://rdoc//lib/rdoc/markup/attr_span.rb#10 + def initialize(length, exclusive); end + + # Accesses flags for character +n+ + # + # source://rdoc//lib/rdoc/markup/attr_span.rb#31 + def [](n); end + + # Toggles +bits+ from +start+ to +length+ + # + # source://rdoc//lib/rdoc/markup/attr_span.rb#17 + def set_attrs(start, length, bits); end +end + +# Manages changes of attributes in a block of text +# +# source://rdoc//lib/rdoc/markup/attribute_manager.rb#6 +class RDoc::Markup::AttributeManager + # Creates a new attribute manager that understands bold, emphasized and + # teletype text. + # + # @return [AttributeManager] a new instance of AttributeManager + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#80 + def initialize; end + + # Adds a markup class with +name+ for words surrounded by HTML tag +tag+. + # To process emphasis tags: + # + # am.add_html 'em', :EM + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#286 + def add_html(tag, name, exclusive = T.unsafe(nil)); end + + # Adds a regexp handling for +pattern+ with +name+. A simple URL handler + # would be: + # + # @am.add_regexp_handling(/((https?:)\S+\w)/, :HYPERLINK) + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#298 + def add_regexp_handling(pattern, name, exclusive = T.unsafe(nil)); end + + # Adds a markup class with +name+ for words wrapped in the +start+ and + # +stop+ character. To make words wrapped with "*" bold: + # + # am.add_word_pair '*', '*', :BOLD + # + # @raise [ArgumentError] + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#261 + def add_word_pair(start, stop, name, exclusive = T.unsafe(nil)); end + + # Return an attribute object with the given turn_on and turn_off bits set + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#103 + def attribute(turn_on, turn_off); end + + # The attributes enabled for this markup object. + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#40 + def attributes; end + + # Changes the current attribute from +current+ to +new+ + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#110 + def change_attribute(current, new); end + + # Used by the tests to change attributes by name from +current_set+ to + # +new_set+ + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#119 + def changed_attribute_by_name(current_set, new_set); end + + # Map attributes like textto the sequence + # \001\002\001\003, where is a per-attribute specific + # character + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#154 + def convert_attrs(str, attrs, exclusive = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#160 + def convert_attrs_matching_word_pairs(str, attrs, exclusive); end + + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#185 + def convert_attrs_word_pair_map(str, attrs, exclusive); end + + # Converts HTML tags to RDoc attributes + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#206 + def convert_html(str, attrs, exclusive = T.unsafe(nil)); end + + # Converts regexp handling sequences to RDoc attributes + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#223 + def convert_regexp_handlings(str, attrs, exclusive = T.unsafe(nil)); end + + # Copies +start_pos+ to +end_pos+ from the current string + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#135 + def copy_string(start_pos, end_pos); end + + # Debug method that prints a string along with its attributes + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#329 + def display_attributes; end + + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#142 + def exclusive?(attr); end + + # A bits of exclusive maps + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#74 + def exclusive_bitmap; end + + # Processes +str+ converting attributes, HTML and regexp handlings + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#307 + def flow(str); end + + # This maps HTML tags to the corresponding attribute char + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#58 + def html_tags; end + + # Escapes regexp handling sequences of text to prevent conversion to RDoc + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#239 + def mask_protected_sequences; end + + # This maps delimiters that occur around words (such as *bold* or +tt+) + # where the start and end delimiters and the same. This lets us optimize + # the regexp + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#47 + def matching_word_pairs; end + + # A \ in front of a character that would normally be processed turns off + # processing. We do this by turning \< into <#{PROTECT} + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#64 + def protectable; end + + # And this maps _regexp handling_ sequences to a name. A regexp handling + # sequence is something like a WikiWord + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#70 + def regexp_handlings; end + + # Splits the string into chunks by attribute change + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#354 + def split_into_flow; end + + # Unescapes regexp handling sequences of text + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#251 + def unmask_protected_sequences; end + + # And this is used when the delimiters aren't the same. In this case the + # hash maps a pattern to the attribute character + # + # source://rdoc//lib/rdoc/markup/attribute_manager.rb#53 + def word_pair_map; end +end + +# source://rdoc//lib/rdoc/markup/attribute_manager.rb#147 +RDoc::Markup::AttributeManager::NON_PRINTING_END = T.let(T.unsafe(nil), String) + +# source://rdoc//lib/rdoc/markup/attribute_manager.rb#146 +RDoc::Markup::AttributeManager::NON_PRINTING_START = T.let(T.unsafe(nil), String) + +# We manage a set of attributes. Each attribute has a symbol name and a bit +# value. +# +# source://rdoc//lib/rdoc/markup/attributes.rb#6 +class RDoc::Markup::Attributes + # Creates a new attributes set. + # + # @return [Attributes] a new instance of Attributes + # + # source://rdoc//lib/rdoc/markup/attributes.rb#16 + def initialize; end + + # Returns a string representation of +bitmap+ + # + # source://rdoc//lib/rdoc/markup/attributes.rb#46 + def as_string(bitmap); end + + # Returns a unique bit for +name+ + # + # source://rdoc//lib/rdoc/markup/attributes.rb#29 + def bitmap_for(name); end + + # yields each attribute name in +bitmap+ + # + # source://rdoc//lib/rdoc/markup/attributes.rb#60 + def each_name_of(bitmap); end + + # The regexp handling attribute type. See RDoc::Markup#add_regexp_handling + # + # source://rdoc//lib/rdoc/markup/attributes.rb#11 + def regexp_handling; end +end + +# An empty line. This class is a singleton. +# +# source://rdoc//lib/rdoc/markup/blank_line.rb#5 +class RDoc::Markup::BlankLine + # Calls #accept_blank_line on +visitor+ + # + # source://rdoc//lib/rdoc/markup/blank_line.rb#19 + def accept(visitor); end + + # source://rdoc//lib/rdoc/markup/blank_line.rb#23 + def pretty_print(q); end + + class << self + # RDoc::Markup::BlankLine is a singleton + # + # source://rdoc//lib/rdoc/markup/blank_line.rb#12 + def new; end + end +end + +# A quoted section which contains markup items. +# +# source://rdoc//lib/rdoc/markup/block_quote.rb#5 +class RDoc::Markup::BlockQuote < ::RDoc::Markup::Raw + # Calls #accept_block_quote on +visitor+ + # + # source://rdoc//lib/rdoc/markup/block_quote.rb#10 + def accept(visitor); end +end + +# A Document containing lists, headings, paragraphs, etc. +# +# source://rdoc//lib/rdoc/markup/document.rb#5 +class RDoc::Markup::Document + include ::Enumerable + + # Creates a new Document with +parts+ + # + # @return [Document] a new instance of Document + # + # source://rdoc//lib/rdoc/markup/document.rb#29 + def initialize(*parts); end + + # Appends +part+ to the document + # + # source://rdoc//lib/rdoc/markup/document.rb#40 + def <<(part); end + + # source://rdoc//lib/rdoc/markup/document.rb#56 + def ==(other); end + + # Runs this document and all its #items through +visitor+ + # + # source://rdoc//lib/rdoc/markup/document.rb#65 + def accept(visitor); end + + # Concatenates the given +parts+ onto the document + # + # source://rdoc//lib/rdoc/markup/document.rb#76 + def concat(parts); end + + # Enumerator for the parts of this document + # + # source://rdoc//lib/rdoc/markup/document.rb#83 + def each(&block); end + + # Does this document have no parts? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/document.rb#90 + def empty?; end + + # The file this document was created from. See also + # RDoc::ClassModule#add_comment + # + # source://rdoc//lib/rdoc/markup/document.rb#13 + def file; end + + # The file this Document was created from. + # + # source://rdoc//lib/rdoc/markup/document.rb#97 + def file=(location); end + + # When this is a collection of documents (#file is not set and this document + # contains only other documents as its direct children) #merge replaces + # documents in this class with documents from +other+ when the file matches + # and adds documents from +other+ when the files do not. + # + # The information in +other+ is preferred over the receiver + # + # source://rdoc//lib/rdoc/markup/document.rb#114 + def merge(other); end + + # Does this Document contain other Documents? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/document.rb#134 + def merged?; end + + # If a heading is below the given level it will be omitted from the + # table_of_contents + # + # source://rdoc//lib/rdoc/markup/document.rb#19 + def omit_headings_below; end + + # If a heading is below the given level it will be omitted from the + # table_of_contents + # + # source://rdoc//lib/rdoc/markup/document.rb#19 + def omit_headings_below=(_arg0); end + + # The parts of the Document + # + # source://rdoc//lib/rdoc/markup/document.rb#24 + def parts; end + + # source://rdoc//lib/rdoc/markup/document.rb#138 + def pretty_print(q); end + + # Appends +parts+ to the document + # + # source://rdoc//lib/rdoc/markup/document.rb#151 + def push(*parts); end + + # Returns an Array of headings in the document. + # + # Require 'rdoc/markup/formatter' before calling this method. + # + # source://rdoc//lib/rdoc/markup/document.rb#160 + def table_of_contents; end +end + +# Base class for RDoc markup formatters +# +# Formatters are a visitor that converts an RDoc::Markup tree (from a comment) +# into some kind of output. RDoc ships with formatters for converting back to +# rdoc, ANSI text, HTML, a Table of Contents and other formats. +# +# If you'd like to write your own Formatter use +# RDoc::Markup::FormatterTestCase. If you're writing a text-output formatter +# use RDoc::Markup::TextFormatterTestCase which provides extra test cases. +# +# source://rdoc//lib/rdoc/markup/formatter.rb#13 +class RDoc::Markup::Formatter + # Creates a new Formatter + # + # @return [Formatter] a new instance of Formatter + # + # source://rdoc//lib/rdoc/markup/formatter.rb#48 + def initialize(options, markup = T.unsafe(nil)); end + + # Adds +document+ to the output + # + # source://rdoc//lib/rdoc/markup/formatter.rb#69 + def accept_document(document); end + + # Adds a regexp handling for links of the form rdoc-...: + # + # source://rdoc//lib/rdoc/markup/formatter.rb#83 + def add_regexp_handling_RDOCLINK; end + + # Adds a regexp handling for links of the form {}[] and + # [] + # + # source://rdoc//lib/rdoc/markup/formatter.rb#91 + def add_regexp_handling_TIDYLINK; end + + # Add a new set of tags for an attribute. We allow separate start and end + # tags for flexibility + # + # source://rdoc//lib/rdoc/markup/formatter.rb#105 + def add_tag(name, start, stop); end + + # Allows +tag+ to be decorated with additional information. + # + # source://rdoc//lib/rdoc/markup/formatter.rb#113 + def annotate(tag); end + + # Marks up +content+ + # + # source://rdoc//lib/rdoc/markup/formatter.rb#120 + def convert(content); end + + # Converts flow items +flow+ + # + # source://rdoc//lib/rdoc/markup/formatter.rb#127 + def convert_flow(flow); end + + # Converts added regexp handlings. See RDoc::Markup#add_regexp_handling + # + # source://rdoc//lib/rdoc/markup/formatter.rb#150 + def convert_regexp_handling(target); end + + # Converts a string to be fancier if desired + # + # source://rdoc//lib/rdoc/markup/formatter.rb#176 + def convert_string(string); end + + # Use ignore in your subclass to ignore the content of a node. + # + # ## + # # We don't support raw nodes in ToNoRaw + # + # alias accept_raw ignore + # + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def ignore(*node); end + + # Are we currently inside tt tags? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/formatter.rb#194 + def in_tt?; end + + # Turns off tags for +item+ on +res+ + # + # source://rdoc//lib/rdoc/markup/formatter.rb#216 + def off_tags(res, item); end + + # Turns on tags for +item+ on +res+ + # + # source://rdoc//lib/rdoc/markup/formatter.rb#201 + def on_tags(res, item); end + + # Extracts and a scheme, url and an anchor id from +url+ and returns them. + # + # source://rdoc//lib/rdoc/markup/formatter.rb#231 + def parse_url(url); end + + # Is +tag+ a tt tag? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/formatter.rb#261 + def tt?(tag); end + + class << self + # Converts a target url to one that is relative to a given path + # + # source://rdoc//lib/rdoc/markup/formatter.rb#24 + def gen_relative_url(path, target); end + end +end + +# A hard-break in the middle of a paragraph. +# +# source://rdoc//lib/rdoc/markup/hard_break.rb#5 +class RDoc::Markup::HardBreak + # source://rdoc//lib/rdoc/markup/hard_break.rb#23 + def ==(other); end + + # Calls #accept_hard_break on +visitor+ + # + # source://rdoc//lib/rdoc/markup/hard_break.rb#19 + def accept(visitor); end + + # source://rdoc//lib/rdoc/markup/hard_break.rb#27 + def pretty_print(q); end + + class << self + # RDoc::Markup::HardBreak is a singleton + # + # source://rdoc//lib/rdoc/markup/hard_break.rb#12 + def new; end + end +end + +# source://rdoc//lib/rdoc/markup/heading.rb#6 +class RDoc::Markup::Heading < ::Struct + # source://rdoc//lib/rdoc/markup/heading.rb#40 + def accept(visitor); end + + # source://rdoc//lib/rdoc/markup/heading.rb#47 + def aref; end + + # source://rdoc//lib/rdoc/markup/heading.rb#55 + def label(context = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markup/heading.rb#68 + def plain_html; end + + # source://rdoc//lib/rdoc/markup/heading.rb#72 + def pretty_print(q); end + + class << self + # source://rdoc//lib/rdoc/markup/heading.rb#22 + def to_html; end + + # source://rdoc//lib/rdoc/markup/heading.rb#14 + def to_label; end + end +end + +# A file included at generation time. Objects of this class are created by +# RDoc::RD for an extension-less include. +# +# This implementation in incomplete. +# +# source://rdoc//lib/rdoc/markup/include.rb#8 +class RDoc::Markup::Include + # Creates a new include that will import +file+ from +include_path+ + # + # @return [Include] a new instance of Include + # + # source://rdoc//lib/rdoc/markup/include.rb#23 + def initialize(file, include_path); end + + # source://rdoc//lib/rdoc/markup/include.rb#28 + def ==(other); end + + # The filename to be included, without extension + # + # source://rdoc//lib/rdoc/markup/include.rb#13 + def file; end + + # Directories to search for #file + # + # source://rdoc//lib/rdoc/markup/include.rb#18 + def include_path; end + + # source://rdoc//lib/rdoc/markup/include.rb#33 + def pretty_print(q); end +end + +# An Indented Paragraph of text +# +# source://rdoc//lib/rdoc/markup/indented_paragraph.rb#5 +class RDoc::Markup::IndentedParagraph < ::RDoc::Markup::Raw + # Creates a new IndentedParagraph containing +parts+ indented with +indent+ + # spaces + # + # @return [IndentedParagraph] a new instance of IndentedParagraph + # + # source://rdoc//lib/rdoc/markup/indented_paragraph.rb#16 + def initialize(indent, *parts); end + + # source://rdoc//lib/rdoc/markup/indented_paragraph.rb#22 + def ==(other); end + + # Calls #accept_indented_paragraph on +visitor+ + # + # source://rdoc//lib/rdoc/markup/indented_paragraph.rb#29 + def accept(visitor); end + + # The indent in number of spaces + # + # source://rdoc//lib/rdoc/markup/indented_paragraph.rb#10 + def indent; end + + # Joins the raw paragraph text and converts inline HardBreaks to the + # +hard_break+ text followed by the indent. + # + # source://rdoc//lib/rdoc/markup/indented_paragraph.rb#37 + def text(hard_break = T.unsafe(nil)); end +end + +# A List is a homogeneous set of ListItems. +# +# The supported list types include: +# +# :BULLET:: +# An unordered list +# :LABEL:: +# An unordered definition list, but using an alternate RDoc::Markup syntax +# :LALPHA:: +# An ordered list using increasing lowercase English letters +# :NOTE:: +# An unordered definition list +# :NUMBER:: +# An ordered list using increasing Arabic numerals +# :UALPHA:: +# An ordered list using increasing uppercase English letters +# +# Definition lists behave like HTML definition lists. Each list item can +# describe multiple terms. See RDoc::Markup::ListItem for how labels and +# definition are stored as list items. +# +# source://rdoc//lib/rdoc/markup/list.rb#24 +class RDoc::Markup::List + # Creates a new list of +type+ with +items+. Valid list types are: + # +:BULLET+, +:LABEL+, +:LALPHA+, +:NOTE+, +:NUMBER+, +:UALPHA+ + # + # @return [List] a new instance of List + # + # source://rdoc//lib/rdoc/markup/list.rb#40 + def initialize(type = T.unsafe(nil), *items); end + + # Appends +item+ to the list + # + # source://rdoc//lib/rdoc/markup/list.rb#49 + def <<(item); end + + # source://rdoc//lib/rdoc/markup/list.rb#53 + def ==(other); end + + # Runs this list and all its #items through +visitor+ + # + # source://rdoc//lib/rdoc/markup/list.rb#62 + def accept(visitor); end + + # Is the list empty? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/list.rb#75 + def empty?; end + + # Items in the list + # + # source://rdoc//lib/rdoc/markup/list.rb#34 + def items; end + + # Returns the last item in the list + # + # source://rdoc//lib/rdoc/markup/list.rb#82 + def last; end + + # source://rdoc//lib/rdoc/markup/list.rb#86 + def pretty_print(q); end + + # Appends +items+ to the list + # + # source://rdoc//lib/rdoc/markup/list.rb#97 + def push(*items); end + + # The list's type + # + # source://rdoc//lib/rdoc/markup/list.rb#29 + def type; end + + # The list's type + # + # source://rdoc//lib/rdoc/markup/list.rb#29 + def type=(_arg0); end +end + +# An item within a List that contains paragraphs, headings, etc. +# +# For BULLET, NUMBER, LALPHA and UALPHA lists, the label will always be nil. +# For NOTE and LABEL lists, the list label may contain: +# +# * a single String for a single label +# * an Array of Strings for a list item with multiple terms +# * nil for an extra description attached to a previously labeled list item +# +# source://rdoc//lib/rdoc/markup/list_item.rb#12 +class RDoc::Markup::ListItem + # Creates a new ListItem with an optional +label+ containing +parts+ + # + # @return [ListItem] a new instance of ListItem + # + # source://rdoc//lib/rdoc/markup/list_item.rb#27 + def initialize(label = T.unsafe(nil), *parts); end + + # Appends +part+ to the ListItem + # + # source://rdoc//lib/rdoc/markup/list_item.rb#36 + def <<(part); end + + # source://rdoc//lib/rdoc/markup/list_item.rb#40 + def ==(other); end + + # Runs this list item and all its #parts through +visitor+ + # + # source://rdoc//lib/rdoc/markup/list_item.rb#49 + def accept(visitor); end + + # Is the ListItem empty? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/list_item.rb#62 + def empty?; end + + # The label for the ListItem + # + # source://rdoc//lib/rdoc/markup/list_item.rb#17 + def label; end + + # The label for the ListItem + # + # source://rdoc//lib/rdoc/markup/list_item.rb#17 + def label=(_arg0); end + + # Length of parts in the ListItem + # + # source://rdoc//lib/rdoc/markup/list_item.rb#69 + def length; end + + # Parts of the ListItem + # + # source://rdoc//lib/rdoc/markup/list_item.rb#22 + def parts; end + + # source://rdoc//lib/rdoc/markup/list_item.rb#73 + def pretty_print(q); end + + # Adds +parts+ to the ListItem + # + # source://rdoc//lib/rdoc/markup/list_item.rb#95 + def push(*parts); end +end + +# A Paragraph of text +# +# source://rdoc//lib/rdoc/markup/paragraph.rb#5 +class RDoc::Markup::Paragraph < ::RDoc::Markup::Raw + # Calls #accept_paragraph on +visitor+ + # + # source://rdoc//lib/rdoc/markup/paragraph.rb#10 + def accept(visitor); end + + # Joins the raw paragraph text and converts inline HardBreaks to the + # +hard_break+ text. + # + # source://rdoc//lib/rdoc/markup/paragraph.rb#18 + def text(hard_break = T.unsafe(nil)); end +end + +# A recursive-descent parser for RDoc markup. +# +# The parser tokenizes an input string then parses the tokens into a Document. +# Documents can be converted into output formats by writing a visitor like +# RDoc::Markup::ToHTML. +# +# The parser only handles the block-level constructs Paragraph, List, +# ListItem, Heading, Verbatim, BlankLine, Rule and BlockQuote. +# Inline markup such as \+blah\+ is handled separately by +# RDoc::Markup::AttributeManager. +# +# To see what markup the Parser implements read RDoc. To see how to use +# RDoc markup to format text in your program read RDoc::Markup. +# +# source://rdoc//lib/rdoc/markup/parser.rb#19 +class RDoc::Markup::Parser + include ::RDoc::Text + + # Creates a new Parser. See also ::parse + # + # @return [Parser] a new instance of Parser + # + # source://rdoc//lib/rdoc/markup/parser.rb#79 + def initialize; end + + # Builds a Heading of +level+ + # + # source://rdoc//lib/rdoc/markup/parser.rb#90 + def build_heading(level); end + + # Builds a List flush to +margin+ + # + # source://rdoc//lib/rdoc/markup/parser.rb#108 + def build_list(margin); end + + # Builds a Paragraph that is flush to +margin+ + # + # source://rdoc//lib/rdoc/markup/parser.rb#208 + def build_paragraph(margin); end + + # Builds a Verbatim that is indented from +margin+. + # + # The verbatim block is shifted left (the least indented lines start in + # column 0). Each part of the verbatim is one line of text, always + # terminated by a newline. Blank lines always consist of a single newline + # character, and there is never a single newline at the end of the verbatim. + # + # source://rdoc//lib/rdoc/markup/parser.rb#243 + def build_verbatim(margin); end + + # Enables display of debugging information + # + # source://rdoc//lib/rdoc/markup/parser.rb#48 + def debug; end + + # Enables display of debugging information + # + # source://rdoc//lib/rdoc/markup/parser.rb#48 + def debug=(_arg0); end + + # Pulls the next token from the stream. + # + # source://rdoc//lib/rdoc/markup/parser.rb#327 + def get; end + + # Parses the tokens into an array of RDoc::Markup::XXX objects, + # and appends them to the passed +parent+ RDoc::Markup::YYY object. + # + # Exits at the end of the token stream, or when it encounters a token + # in a column less than +indent+ (unless it is a NEWLINE). + # + # Returns +parent+. + # + # source://rdoc//lib/rdoc/markup/parser.rb#342 + def parse(parent, indent = T.unsafe(nil)); end + + # Small hook that is overridden by RDoc::TomDoc + # + # source://rdoc//lib/rdoc/markup/parser.rb#406 + def parse_text(parent, indent); end + + # Returns the next token on the stream without modifying the stream + # + # source://rdoc//lib/rdoc/markup/parser.rb#413 + def peek_token; end + + # Creates the StringScanner + # + # source://rdoc//lib/rdoc/markup/parser.rb#468 + def setup_scanner(input); end + + # Skips the next token if its type is +token_type+. + # + # Optionally raises an error if the next token is not of the expected type. + # + # @raise [ParseError] + # + # source://rdoc//lib/rdoc/markup/parser.rb#477 + def skip(token_type, error = T.unsafe(nil)); end + + # Turns text +input+ into a stream of tokens + # + # source://rdoc//lib/rdoc/markup/parser.rb#488 + def tokenize(input); end + + # Token accessor + # + # source://rdoc//lib/rdoc/markup/parser.rb#53 + def tokens; end + + # Returns the current token to the token stream + # + # @raise [Error] + # + # source://rdoc//lib/rdoc/markup/parser.rb#578 + def unget; end + + class << self + # Parses +str+ into a Document. + # + # Use RDoc::Markup#parse instead of this method. + # + # source://rdoc//lib/rdoc/markup/parser.rb#60 + def parse(str); end + + # Returns a token stream for +str+, for testing + # + # source://rdoc//lib/rdoc/markup/parser.rb#70 + def tokenize(str); end + end +end + +# A simple wrapper of StringScanner that is aware of the current column and lineno +# +# source://rdoc//lib/rdoc/markup/parser.rb#422 +class RDoc::Markup::Parser::MyStringScanner + # :stopdoc: + # + # @return [MyStringScanner] a new instance of MyStringScanner + # + # source://rdoc//lib/rdoc/markup/parser.rb#425 + def initialize(input); end + + # source://rdoc//lib/rdoc/markup/parser.rb#458 + def [](i); end + + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/parser.rb#450 + def eos?; end + + # source://rdoc//lib/rdoc/markup/parser.rb#454 + def matched; end + + # source://rdoc//lib/rdoc/markup/parser.rb#445 + def newline!; end + + # source://rdoc//lib/rdoc/markup/parser.rb#441 + def pos; end + + # source://rdoc//lib/rdoc/markup/parser.rb#430 + def scan(re); end + + # source://rdoc//lib/rdoc/markup/parser.rb#436 + def unscan(s); end +end + +# Handle common directives that can occur in a block of text: +# +# \:include: filename +# +# Directives can be escaped by preceding them with a backslash. +# +# RDoc plugin authors can register additional directives to be handled by +# using RDoc::Markup::PreProcess::register. +# +# Any directive that is not built-in to RDoc (including those registered via +# plugins) will be stored in the metadata hash on the CodeObject the comment +# is attached to. See RDoc::Markup@Directives for the list of built-in +# directives. +# +# source://rdoc//lib/rdoc/markup/pre_process.rb#17 +class RDoc::Markup::PreProcess + # Creates a new pre-processor for +input_file_name+ that will look for + # included files in +include_path+ + # + # @return [PreProcess] a new instance of PreProcess + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#78 + def initialize(input_file_name, include_path); end + + # Look for the given file in the directory containing the current file, + # and then in each of the directories specified in the RDOC_INCLUDE path + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#288 + def find_include_file(name); end + + # Look for directives in the given +text+. + # + # Options that we don't handle are yielded. If the block returns false the + # directive is restored to the text. If the block returns nil or no block + # was given the directive is handled according to the registered directives. + # If a String was returned the directive is replaced with the string. + # + # If no matching directive was registered the directive is restored to the + # text. + # + # If +code_object+ is given and the directive is unknown then the + # directive's parameter is set as metadata on the +code_object+. See + # RDoc::CodeObject#metadata for details. + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#99 + def handle(text, code_object = T.unsafe(nil), &block); end + + # Performs the actions described by +directive+ and its parameter +param+. + # + # +code_object+ is used for directives that operate on a class or module. + # +prefix+ is used to ensure the replacement for handled directives is + # correct. +encoding+ is used for the include directive. + # + # For a list of directives in RDoc see RDoc::Markup. + # -- + # When 1.8.7 support is ditched prefix can be defaulted to '' + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#150 + def handle_directive(prefix, directive, param, code_object = T.unsafe(nil), encoding = T.unsafe(nil)); end + + # Handles the :include: _filename_ directive. + # + # If the first line of the included file starts with '#', and contains + # an encoding information in the form 'coding:' or 'coding=', it is + # removed. + # + # If all lines in the included file start with a '#', this leading '#' + # is removed before inclusion. The included content is indented like + # the :include: directive. + # -- + # so all content will be verbatim because of the likely space after '#'? + # TODO shift left the whole file content in that case + # TODO comment stop/start #-- and #++ in included file must be processed here + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#262 + def include_file(name, indent, encoding); end + + # An RDoc::Options instance that will be filled in with overrides from + # directives + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#23 + def options; end + + # An RDoc::Options instance that will be filled in with overrides from + # directives + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#23 + def options=(_arg0); end + + class << self + # Adds a post-process handler for directives. The handler will be called + # with the result RDoc::Comment (or text String) and the code object for the + # comment (if any). + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#30 + def post_process(&block); end + + # Registered post-processors + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#37 + def post_processors; end + + # Registers +directive+ as one handled by RDoc. If a block is given the + # directive will be replaced by the result of the block, otherwise the + # directive will be removed from the processed text. + # + # The block will be called with the directive name and the directive + # parameter: + # + # RDoc::Markup::PreProcess.register 'my-directive' do |directive, param| + # # replace text, etc. + # end + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#53 + def register(directive, &block); end + + # Registered directives + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#60 + def registered; end + + # Clears all registered directives and post-processors + # + # source://rdoc//lib/rdoc/markup/pre_process.rb#67 + def reset; end + end +end + +# A section of text that is added to the output document as-is +# +# source://rdoc//lib/rdoc/markup/raw.rb#5 +class RDoc::Markup::Raw + # Creates a new Raw containing +parts+ + # + # @return [Raw] a new instance of Raw + # + # source://rdoc//lib/rdoc/markup/raw.rb#15 + def initialize(*parts); end + + # Appends +text+ + # + # source://rdoc//lib/rdoc/markup/raw.rb#23 + def <<(text); end + + # source://rdoc//lib/rdoc/markup/raw.rb#27 + def ==(other); end + + # Calls #accept_raw+ on +visitor+ + # + # source://rdoc//lib/rdoc/markup/raw.rb#34 + def accept(visitor); end + + # Appends +other+'s parts + # + # source://rdoc//lib/rdoc/markup/raw.rb#41 + def merge(other); end + + # The component parts of the list + # + # source://rdoc//lib/rdoc/markup/raw.rb#10 + def parts; end + + # source://rdoc//lib/rdoc/markup/raw.rb#45 + def pretty_print(q); end + + # Appends +texts+ onto this Paragraph + # + # source://rdoc//lib/rdoc/markup/raw.rb#58 + def push(*texts); end + + # The raw text + # + # source://rdoc//lib/rdoc/markup/raw.rb#65 + def text; end +end + +# Hold details of a regexp handling sequence +# +# source://rdoc//lib/rdoc/markup/regexp_handling.rb#5 +class RDoc::Markup::RegexpHandling + # Creates a new regexp handling sequence of +type+ with +text+ + # + # @return [RegexpHandling] a new instance of RegexpHandling + # + # source://rdoc//lib/rdoc/markup/regexp_handling.rb#20 + def initialize(type, text); end + + # Regexp handlings are equal when the have the same text and type + # + # source://rdoc//lib/rdoc/markup/regexp_handling.rb#27 + def ==(o); end + + # source://rdoc//lib/rdoc/markup/regexp_handling.rb#31 + def inspect; end + + # Regexp handling text + # + # source://rdoc//lib/rdoc/markup/regexp_handling.rb#15 + def text; end + + # Regexp handling text + # + # source://rdoc//lib/rdoc/markup/regexp_handling.rb#15 + def text=(_arg0); end + + # source://rdoc//lib/rdoc/markup/regexp_handling.rb#36 + def to_s; end + + # Regexp handling type + # + # source://rdoc//lib/rdoc/markup/regexp_handling.rb#10 + def type; end +end + +# A horizontal rule with a weight +# +# source://rdoc//lib/rdoc/markup/rule.rb#5 +class RDoc::Markup::Rule < ::Struct + # Calls #accept_rule on +visitor+ + # + # source://rdoc//lib/rdoc/markup/rule.rb#10 + def accept(visitor); end + + # source://rdoc//lib/rdoc/markup/rule.rb#14 + def pretty_print(q); end +end + +# A section of table +# +# source://rdoc//lib/rdoc/markup/table.rb#5 +class RDoc::Markup::Table + # Creates new instance + # + # @return [Table] a new instance of Table + # + # source://rdoc//lib/rdoc/markup/table.rb#16 + def initialize(header, align, body); end + + # :stopdoc: + # + # source://rdoc//lib/rdoc/markup/table.rb#21 + def ==(other); end + + # source://rdoc//lib/rdoc/markup/table.rb#28 + def accept(visitor); end + + # alignments of each column + # + # source://rdoc//lib/rdoc/markup/table.rb#10 + def align; end + + # alignments of each column + # + # source://rdoc//lib/rdoc/markup/table.rb#10 + def align=(_arg0); end + + # body texts of each column + # + # source://rdoc//lib/rdoc/markup/table.rb#13 + def body; end + + # body texts of each column + # + # source://rdoc//lib/rdoc/markup/table.rb#13 + def body=(_arg0); end + + # headers of each column + # + # source://rdoc//lib/rdoc/markup/table.rb#7 + def header; end + + # headers of each column + # + # source://rdoc//lib/rdoc/markup/table.rb#7 + def header=(_arg0); end + + # source://rdoc//lib/rdoc/markup/table.rb#32 + def pretty_print(q); end +end + +# Outputs RDoc markup with vibrant ANSI color! +# +# source://rdoc//lib/rdoc/markup/to_ansi.rb#5 +class RDoc::Markup::ToAnsi < ::RDoc::Markup::ToRdoc + # Creates a new ToAnsi visitor that is ready to output vibrant ANSI color! + # + # @return [ToAnsi] a new instance of ToAnsi + # + # source://rdoc//lib/rdoc/markup/to_ansi.rb#10 + def initialize(markup = T.unsafe(nil)); end + + # Overrides indent width to ensure output lines up correctly. + # + # source://rdoc//lib/rdoc/markup/to_ansi.rb#31 + def accept_list_item_end(list_item); end + + # Adds coloring to note and label list items + # + # source://rdoc//lib/rdoc/markup/to_ansi.rb#55 + def accept_list_item_start(list_item); end + + # Maps attributes to ANSI sequences + # + # source://rdoc//lib/rdoc/markup/to_ansi.rb#22 + def init_tags; end + + # Starts accepting with a reset screen + # + # source://rdoc//lib/rdoc/markup/to_ansi.rb#87 + def start_accepting; end +end + +# Outputs RDoc markup with hot backspace action! You will probably need a +# pager to use this output format. +# +# This formatter won't work on 1.8.6 because it lacks String#chars. +# +# source://rdoc//lib/rdoc/markup/to_bs.rb#8 +class RDoc::Markup::ToBs < ::RDoc::Markup::ToRdoc + # Returns a new ToBs that is ready for hot backspace action! + # + # @return [ToBs] a new instance of ToBs + # + # source://rdoc//lib/rdoc/markup/to_bs.rb#13 + def initialize(markup = T.unsafe(nil)); end + + # Makes heading text bold. + # + # source://rdoc//lib/rdoc/markup/to_bs.rb#33 + def accept_heading(heading); end + + # Prepares the visitor for consuming +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_bs.rb#46 + def accept_list_item_start(list_item); end + + # Turns on or off regexp handling for +convert_string+ + # + # source://rdoc//lib/rdoc/markup/to_bs.rb#71 + def annotate(tag); end + + # Calls convert_string on the result of convert_regexp_handling + # + # source://rdoc//lib/rdoc/markup/to_bs.rb#84 + def convert_regexp_handling(target); end + + # Adds bold or underline mixed with backspaces + # + # source://rdoc//lib/rdoc/markup/to_bs.rb#91 + def convert_string(string); end + + # Sets a flag that is picked up by #annotate to do the right thing in + # #convert_string + # + # source://rdoc//lib/rdoc/markup/to_bs.rb#24 + def init_tags; end +end + +# Outputs RDoc markup as HTML. +# +# source://rdoc//lib/rdoc/markup/to_html.rb#7 +class RDoc::Markup::ToHtml < ::RDoc::Markup::Formatter + include ::RDoc::Text + + # Creates a new formatter that will output HTML + # + # @return [ToHtml] a new instance of ToHtml + # + # source://rdoc//lib/rdoc/markup/to_html.rb#45 + def initialize(options, markup = T.unsafe(nil)); end + + # Adds +blank_line+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#291 + def accept_blank_line(blank_line); end + + # Adds +block_quote+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#190 + def accept_block_quote(block_quote); end + + # Adds +heading+ to the output. The headings greater than 6 are trimmed to + # level 6. + # + # source://rdoc//lib/rdoc/markup/to_html.rb#299 + def accept_heading(heading); end + + # Finishes consumption of +list+ + # + # source://rdoc//lib/rdoc/markup/to_html.rb#262 + def accept_list_end(list); end + + # Finishes consumption of +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_html.rb#284 + def accept_list_item_end(list_item); end + + # Prepares the visitor for consuming +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_html.rb#273 + def accept_list_item_start(list_item); end + + # Prepares the visitor for consuming +list+ + # + # source://rdoc//lib/rdoc/markup/to_html.rb#253 + def accept_list_start(list); end + + # Adds +paragraph+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#203 + def accept_paragraph(paragraph); end + + # Adds +raw+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#320 + def accept_raw(raw); end + + # Adds +rule+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#246 + def accept_rule(rule); end + + # Adds +table+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#327 + def accept_table(header, body, aligns); end + + # Adds +verbatim+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#216 + def accept_verbatim(verbatim); end + + # The RDoc::CodeObject HTML is being generated for. This is used to + # generate namespaced URI fragments + # + # source://rdoc//lib/rdoc/markup/to_html.rb#33 + def code_object; end + + # The RDoc::CodeObject HTML is being generated for. This is used to + # generate namespaced URI fragments + # + # source://rdoc//lib/rdoc/markup/to_html.rb#33 + def code_object=(_arg0); end + + # CGI-escapes +text+ + # + # source://rdoc//lib/rdoc/markup/to_html.rb#352 + def convert_string(text); end + + # Returns the generated output + # + # source://rdoc//lib/rdoc/markup/to_html.rb#183 + def end_accepting; end + + # Path to this document for relative links + # + # source://rdoc//lib/rdoc/markup/to_html.rb#38 + def from_path; end + + # Path to this document for relative links + # + # source://rdoc//lib/rdoc/markup/to_html.rb#38 + def from_path=(_arg0); end + + # Generate a link to +url+ with content +text+. Handles the special cases + # for img: and link: described under handle_regexp_HYPERLINK + # + # source://rdoc//lib/rdoc/markup/to_html.rb#360 + def gen_url(url, text); end + + # source://rdoc//lib/rdoc/markup/to_html.rb#85 + def handle_RDOCLINK(url); end + + # +target+ is a
+ # + # source://rdoc//lib/rdoc/markup/to_html.rb#110 + def handle_regexp_HARD_BREAK(target); end + + # +target+ is a potential link. The following schemes are handled: + # + # mailto::: + # Inserted as-is. + # http::: + # Links are checked to see if they reference an image. If so, that image + # gets inserted using an tag. Otherwise a conventional + # is used. + # link::: + # Reference to a local file relative to the output directory. + # + # source://rdoc//lib/rdoc/markup/to_html.rb#126 + def handle_regexp_HYPERLINK(target); end + + # +target+ is an rdoc-schemed link that will be converted into a hyperlink. + # + # For the +rdoc-ref+ scheme the named reference will be returned without + # creating a link. + # + # For the +rdoc-label+ scheme the footnote and label prefixes are stripped + # when creating a link. All other contents will be linked verbatim. + # + # source://rdoc//lib/rdoc/markup/to_html.rb#141 + def handle_regexp_RDOCLINK(target); end + + # This +target+ is a link where the label is different from the URL + # label[url] or {long label}[url] + # + # source://rdoc//lib/rdoc/markup/to_html.rb#149 + def handle_regexp_TIDYLINK(target); end + + # Determines the HTML list element for +list_type+ and +open_tag+ + # + # @raise [RDoc::Error] + # + # source://rdoc//lib/rdoc/markup/to_html.rb#385 + def html_list_name(list_type, open_tag); end + + # source://rdoc//lib/rdoc/markup/to_html.rb#26 + def in_list_entry; end + + # Adds regexp handlings about link notations. + # + # source://rdoc//lib/rdoc/markup/to_html.rb#80 + def init_link_notation_regexp_handlings; end + + # Adds regexp handlings. + # + # source://rdoc//lib/rdoc/markup/to_html.rb#70 + def init_regexp_handlings; end + + # Maps attributes to HTML tags + # + # source://rdoc//lib/rdoc/markup/to_html.rb#394 + def init_tags; end + + # source://rdoc//lib/rdoc/markup/to_html.rb#27 + def list; end + + # Returns the HTML end-tag for +list_type+ + # + # source://rdoc//lib/rdoc/markup/to_html.rb#420 + def list_end_for(list_type); end + + # Returns the HTML tag for +list_type+, possible using a label from + # +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_html.rb#404 + def list_item_start(list_item, list_type); end + + # Returns true if text is valid ruby syntax + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/to_html.rb#434 + def parseable?(text); end + + # source://rdoc//lib/rdoc/markup/to_html.rb#25 + def res; end + + # Prepares the visitor for HTML generation + # + # source://rdoc//lib/rdoc/markup/to_html.rb#174 + def start_accepting; end + + # Converts +item+ to HTML using RDoc::Text#to_html + # + # source://rdoc//lib/rdoc/markup/to_html.rb#448 + def to_html(item); end +end + +# source://rdoc//lib/rdoc/markup/to_html.rb#65 +RDoc::Markup::ToHtml::URL_CHARACTERS_REGEXP_STR = T.let(T.unsafe(nil), String) + +# Subclass of the RDoc::Markup::ToHtml class that supports looking up method +# names, classes, etc to create links. RDoc::CrossReference is used to +# generate those links based on the current context. +# +# source://rdoc//lib/rdoc/markup/to_html_crossref.rb#7 +class RDoc::Markup::ToHtmlCrossref < ::RDoc::Markup::ToHtml + # Creates a new crossref resolver that generates links relative to +context+ + # which lives at +from_path+ in the generated files. '#' characters on + # references are removed unless +show_hash+ is true. Only method names + # preceded by '#' or '::' are linked, unless +hyperlink_all+ is true. + # + # @raise [ArgumentError] + # @return [ToHtmlCrossref] a new instance of ToHtmlCrossref + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#32 + def initialize(options, from_path, context, markup = T.unsafe(nil)); end + + # RDoc::CodeObject for generating references + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#19 + def context; end + + # RDoc::CodeObject for generating references + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#19 + def context=(_arg0); end + + # Creates a link to the reference +name+ if the name exists. If +text+ is + # given it is used as the link text, otherwise +name+ is used. + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#61 + def cross_reference(name, text = T.unsafe(nil), code = T.unsafe(nil)); end + + # Generates links for rdoc-ref: scheme URLs and allows + # RDoc::Markup::ToHtml to handle other schemes. + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#131 + def gen_url(url, text); end + + # We're invoked when any text matches the CROSSREF pattern. If we find the + # corresponding reference, generate a link. If the name we're looking for + # contains no punctuation, we look for it up the module/class chain. For + # example, ToHtml is found, even without the RDoc::Markup:: prefix, + # because we look for it in module Markup first. + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#83 + def handle_regexp_CROSSREF(target); end + + # Handles rdoc-ref: scheme links and allows RDoc::Markup::ToHtml to + # handle other schemes. + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#102 + def handle_regexp_HYPERLINK(target); end + + # +target+ is an rdoc-schemed link that will be converted into a hyperlink. + # For the rdoc-ref scheme the cross-reference will be looked up and the + # given name will be used. + # + # All other contents are handled by + # {the superclass}[rdoc-ref:RDoc::Markup::ToHtml#handle_regexp_RDOCLINK] + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#116 + def handle_regexp_RDOCLINK(target); end + + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#46 + def init_link_notation_regexp_handlings; end + + # Creates an HTML link to +name+ with the given +text+. + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#141 + def link(name, text, code = T.unsafe(nil)); end + + # Should we show '#' characters on method references? + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#24 + def show_hash; end + + # Should we show '#' characters on method references? + # + # source://rdoc//lib/rdoc/markup/to_html_crossref.rb#24 + def show_hash=(_arg0); end +end + +# Outputs RDoc markup as paragraphs with inline markup only. +# +# source://rdoc//lib/rdoc/markup/to_html_snippet.rb#5 +class RDoc::Markup::ToHtmlSnippet < ::RDoc::Markup::ToHtml + # Creates a new ToHtmlSnippet formatter that will cut off the input on the + # next word boundary after the given number of +characters+ or +paragraphs+ + # of text have been encountered. + # + # @return [ToHtmlSnippet] a new instance of ToHtmlSnippet + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#37 + def initialize(options, characters = T.unsafe(nil), paragraphs = T.unsafe(nil), markup = T.unsafe(nil)); end + + # Adds +heading+ to the output as a paragraph + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#53 + def accept_heading(heading); end + + # Finishes consumption of +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#85 + def accept_list_item_end(list_item); end + + # Prepares the visitor for consuming +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#91 + def accept_list_item_start(list_item); end + + # Prepares the visitor for consuming +list+ + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#98 + def accept_list_start(list); end + + # Adds +paragraph+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#72 + def accept_paragraph(paragraph); end + + # Raw sections are untrusted and ignored + # + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_raw(*node); end + + # Rules are ignored + # + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_rule(*node); end + + # Adds +verbatim+ to the output + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#107 + def accept_verbatim(verbatim); end + + # Throws +:done+ when paragraph_limit paragraphs have been encountered + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#198 + def add_paragraph; end + + # After this many characters the input will be cut off. + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#10 + def character_limit; end + + # The number of characters seen so far. + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#15 + def characters; end + + # Marks up +content+ + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#207 + def convert(content); end + + # Converts flow items +flow+ + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#218 + def convert_flow(flow); end + + # Returns just the text of +link+, +url+ is only used to determine the link + # type. + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#171 + def gen_url(url, text); end + + # Removes escaping from the cross-references in +target+ + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#131 + def handle_regexp_CROSSREF(target); end + + # +target+ is a
+ # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#138 + def handle_regexp_HARD_BREAK(target); end + + # In snippets, there are no lists + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#191 + def html_list_name(list_type, open_tag); end + + # Lists are paragraphs, but notes and labels have a separator + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#146 + def list_item_start(list_item, list_type); end + + # The attribute bitmask + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#20 + def mask; end + + # Maintains a bitmask to allow HTML elements to be closed properly. See + # RDoc::Markup::Formatter. + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#264 + def off_tags(res, item); end + + # Maintains a bitmask to allow HTML elements to be closed properly. See + # RDoc::Markup::Formatter. + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#254 + def on_tags(res, item); end + + # After this many paragraphs the input will be cut off. + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#25 + def paragraph_limit; end + + # Count of paragraphs found + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#30 + def paragraphs; end + + # Prepares the visitor for HTML snippet generation + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#122 + def start_accepting; end + + # Truncates +text+ at the end of the first word after the character_limit. + # + # source://rdoc//lib/rdoc/markup/to_html_snippet.rb#273 + def truncate(text); end +end + +# Joins the parts of an RDoc::Markup::Paragraph into a single String. +# +# This allows for easier maintenance and testing of Markdown support. +# +# This formatter only works on Paragraph instances. Attempting to process +# other markup syntax items will not work. +# +# source://rdoc//lib/rdoc/markup/to_joined_paragraph.rb#10 +class RDoc::Markup::ToJoinedParagraph < ::RDoc::Markup::Formatter + # @return [ToJoinedParagraph] a new instance of ToJoinedParagraph + # + # source://rdoc//lib/rdoc/markup/to_joined_paragraph.rb#12 + def initialize; end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_block_quote(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_heading(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_end(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_item_end(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_item_start(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_start(*node); end + + # Converts the parts of +paragraph+ to a single entry. + # + # source://rdoc//lib/rdoc/markup/to_joined_paragraph.rb#25 + def accept_paragraph(paragraph); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_raw(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_rule(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_table(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_verbatim(*node); end + + # source://rdoc//lib/rdoc/markup/to_joined_paragraph.rb#19 + def end_accepting; end + + # source://rdoc//lib/rdoc/markup/to_joined_paragraph.rb#16 + def start_accepting; end +end + +# Creates HTML-safe labels suitable for use in id attributes. Tidylinks are +# converted to their link part and cross-reference links have the suppression +# marks removed (\\SomeClass is converted to SomeClass). +# +# source://rdoc//lib/rdoc/markup/to_label.rb#9 +class RDoc::Markup::ToLabel < ::RDoc::Markup::Formatter + # Creates a new formatter that will output HTML-safe labels + # + # @return [ToLabel] a new instance of ToLabel + # + # source://rdoc//lib/rdoc/markup/to_label.rb#16 + def initialize(markup = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_blank_line(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_block_quote(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_heading(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_end(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_item_end(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_item_start(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_start(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_paragraph(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_raw(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_rule(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_verbatim(*node); end + + # Converts +text+ to an HTML-safe label + # + # source://rdoc//lib/rdoc/markup/to_label.rb#32 + def convert(text); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def end_accepting(*node); end + + # Converts the CROSSREF +target+ to plain text, removing the suppression + # marker, if any + # + # source://rdoc//lib/rdoc/markup/to_label.rb#42 + def handle_regexp_CROSSREF(target); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def handle_regexp_HARD_BREAK(*node); end + + # Converts the TIDYLINK +target+ to just the text part + # + # source://rdoc//lib/rdoc/markup/to_label.rb#51 + def handle_regexp_TIDYLINK(target); end + + # source://rdoc//lib/rdoc/markup/to_label.rb#11 + def res; end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def start_accepting(*node); end +end + +# Outputs parsed markup as Markdown +# +# source://rdoc//lib/rdoc/markup/to_markdown.rb#7 +class RDoc::Markup::ToMarkdown < ::RDoc::Markup::ToRdoc + # Creates a new formatter that will output Markdown format text + # + # @return [ToMarkdown] a new instance of ToMarkdown + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#12 + def initialize(markup = T.unsafe(nil)); end + + # Finishes consumption of `list` + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#47 + def accept_list_end(list); end + + # Finishes consumption of `list_item` + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#54 + def accept_list_item_end(list_item); end + + # Prepares the visitor for consuming `list_item` + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#75 + def accept_list_item_start(list_item); end + + # Prepares the visitor for consuming `list` + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#100 + def accept_list_start(list); end + + # Adds `rule` to the output + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#117 + def accept_rule(rule); end + + # Outputs `verbatim` indented 4 columns + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#126 + def accept_verbatim(verbatim); end + + # Creates a Markdown-style URL from +url+ with +text+. + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#140 + def gen_url(url, text); end + + # Handles rdoc- type links for footnotes. + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#149 + def handle_rdoc_link(url); end + + # Adds a newline to the output + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#40 + def handle_regexp_HARD_BREAK(target); end + + # Converts the rdoc-...: links into a Markdown.style links. + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#187 + def handle_regexp_RDOCLINK(target); end + + # Converts the RDoc markup tidylink into a Markdown.style link. + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#169 + def handle_regexp_TIDYLINK(target); end + + # Maps attributes to HTML sequences + # + # source://rdoc//lib/rdoc/markup/to_markdown.rb#31 + def init_tags; end +end + +# Outputs RDoc markup as RDoc markup! (mostly) +# +# source://rdoc//lib/rdoc/markup/to_rdoc.rb#5 +class RDoc::Markup::ToRdoc < ::RDoc::Markup::Formatter + # Creates a new formatter that will output (mostly) \RDoc markup + # + # @return [ToRdoc] a new instance of ToRdoc + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#45 + def initialize(markup = T.unsafe(nil)); end + + # Adds +blank_line+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#77 + def accept_blank_line(blank_line); end + + # Adds +paragraph+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#84 + def accept_block_quote(block_quote); end + + # Adds +heading+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#99 + def accept_heading(heading); end + + # Adds +paragraph+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#211 + def accept_indented_paragraph(paragraph); end + + # Finishes consumption of +list+ + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#110 + def accept_list_end(list); end + + # Finishes consumption of +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#119 + def accept_list_item_end(list_item); end + + # Prepares the visitor for consuming +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#143 + def accept_list_item_start(list_item); end + + # Prepares the visitor for consuming +list+ + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#176 + def accept_list_start(list); end + + # Adds +paragraph+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#203 + def accept_paragraph(paragraph); end + + # Adds +raw+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#221 + def accept_raw(raw); end + + # Adds +rule+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#228 + def accept_rule(rule); end + + # Adds +table+ to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#251 + def accept_table(header, body, aligns); end + + # Outputs +verbatim+ indented 2 columns + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#237 + def accept_verbatim(verbatim); end + + # Applies attribute-specific markup to +text+ using RDoc::AttributeManager + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#279 + def attributes(text); end + + # Returns the generated output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#287 + def end_accepting; end + + # Adds a newline to the output + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#303 + def handle_regexp_HARD_BREAK(target); end + + # Removes preceding \\ from the suppressed crossref +target+ + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#294 + def handle_regexp_SUPPRESSED_CROSSREF(target); end + + # Current indent amount for output in characters + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#10 + def indent; end + + # Current indent amount for output in characters + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#10 + def indent=(_arg0); end + + # Maps attributes to HTML sequences + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#68 + def init_tags; end + + # Stack of current list indexes for alphabetic and numeric lists + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#20 + def list_index; end + + # Stack of list types + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#25 + def list_type; end + + # Stack of list widths for indentation + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#30 + def list_width; end + + # Prefix for the next list item. See #use_prefix + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#35 + def prefix; end + + # Output accumulator + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#40 + def res; end + + # Prepares the visitor for text generation + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#310 + def start_accepting; end + + # Adds the stored #prefix to the output and clears it. Lists generate a + # prefix for later consumption. + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#324 + def use_prefix; end + + # Output width in characters + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#15 + def width; end + + # Output width in characters + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#15 + def width=(_arg0); end + + # Wraps +text+ to #width + # + # source://rdoc//lib/rdoc/markup/to_rdoc.rb#334 + def wrap(text); end +end + +# Extracts just the RDoc::Markup::Heading elements from a +# RDoc::Markup::Document to help build a table of contents +# +# source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#6 +class RDoc::Markup::ToTableOfContents < ::RDoc::Markup::Formatter + # @return [ToTableOfContents] a new instance of ToTableOfContents + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#27 + def initialize; end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_blank_line(*node); end + + # :stopdoc: + # + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_block_quote(*node); end + + # Adds +document+ to the output, using its heading cutoff if present + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#36 + def accept_document(document); end + + # Adds +heading+ to the table of contents + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#45 + def accept_heading(heading); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_end(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_end_bullet(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_item_end(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_item_start(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_list_start(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_paragraph(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_raw(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_rule(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_table(*node); end + + # source://rdoc//lib/rdoc/markup/formatter.rb#188 + def accept_verbatim(*node); end + + # Returns the table of contents + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#52 + def end_accepting; end + + # Omits headings with a level less than the given level. + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#25 + def omit_headings_below; end + + # Omits headings with a level less than the given level. + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#25 + def omit_headings_below=(_arg0); end + + # Output accumulator + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#20 + def res; end + + # Prepares the visitor for text generation + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#59 + def start_accepting; end + + # Returns true if +heading+ is below the display threshold + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#67 + def suppressed?(heading); end + + class << self + # Singleton for table-of-contents generation + # + # source://rdoc//lib/rdoc/markup/to_table_of_contents.rb#13 + def to_toc; end + end +end + +# This Markup outputter is used for testing purposes. +# +# source://rdoc//lib/rdoc/markup/to_test.rb#5 +class RDoc::Markup::ToTest < ::RDoc::Markup::Formatter + # source://rdoc//lib/rdoc/markup/to_test.rb#55 + def accept_blank_line(blank_line); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#59 + def accept_heading(heading); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#44 + def accept_list_end(list); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#52 + def accept_list_item_end(list_item); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#48 + def accept_list_item_start(list_item); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#33 + def accept_list_start(list); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#21 + def accept_paragraph(paragraph); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#25 + def accept_raw(raw); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#63 + def accept_rule(rule); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#29 + def accept_verbatim(verbatim); end + + # source://rdoc//lib/rdoc/markup/to_test.rb#17 + def end_accepting; end + + # :section: Visitor + # + # source://rdoc//lib/rdoc/markup/to_test.rb#12 + def start_accepting; end +end + +# Extracts sections of text enclosed in plus, tt or code. Used to discover +# undocumented parameters. +# +# source://rdoc//lib/rdoc/markup/to_tt_only.rb#6 +class RDoc::Markup::ToTtOnly < ::RDoc::Markup::Formatter + # Creates a new tt-only formatter. + # + # @return [ToTtOnly] a new instance of ToTtOnly + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#21 + def initialize(markup = T.unsafe(nil)); end + + # Does nothing to +markup_item+ because it doesn't have any user-built + # content + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#71 + def accept_blank_line(markup_item); end + + # Adds tts from +block_quote+ to the output + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#30 + def accept_block_quote(block_quote); end + + # Does nothing to +markup_item+ because it doesn't have any user-built + # content + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#71 + def accept_heading(markup_item); end + + # Pops the list type for +list+ from #list_type + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#37 + def accept_list_end(list); end + + # Does nothing to +markup_item+ because it doesn't have any user-built + # content + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#71 + def accept_list_item_end(markup_item); end + + # Prepares the visitor for consuming +list_item+ + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#51 + def accept_list_item_start(list_item); end + + # Pushes the list type for +list+ onto #list_type + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#44 + def accept_list_start(list); end + + # Adds +paragraph+ to the output + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#63 + def accept_paragraph(paragraph); end + + # Does nothing to +markup_item+ because it doesn't have any user-built + # content + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#71 + def accept_raw(markup_item); end + + # Does nothing to +markup_item+ because it doesn't have any user-built + # content + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#71 + def accept_rule(markup_item); end + + # Does nothing to +markup_item+ because it doesn't have any user-built + # content + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#71 + def accept_verbatim(markup_item); end + + # Does nothing to +markup_item+ because it doesn't have any user-built + # content + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#71 + def do_nothing(markup_item); end + + # Returns an Array of items that were wrapped in plus, tt or code. + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#107 + def end_accepting; end + + # Stack of list types + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#11 + def list_type; end + + # Output accumulator + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#16 + def res; end + + # Prepares the visitor for gathering tt sections + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#114 + def start_accepting; end + + # Extracts tt sections from +text+ + # + # source://rdoc//lib/rdoc/markup/to_tt_only.rb#84 + def tt_sections(text); end +end + +# A section of verbatim text +# +# source://rdoc//lib/rdoc/markup/verbatim.rb#5 +class RDoc::Markup::Verbatim < ::RDoc::Markup::Raw + # @return [Verbatim] a new instance of Verbatim + # + # source://rdoc//lib/rdoc/markup/verbatim.rb#12 + def initialize(*parts); end + + # source://rdoc//lib/rdoc/markup/verbatim.rb#18 + def ==(other); end + + # Calls #accept_verbatim on +visitor+ + # + # source://rdoc//lib/rdoc/markup/verbatim.rb#25 + def accept(visitor); end + + # Format of this verbatim section + # + # source://rdoc//lib/rdoc/markup/verbatim.rb#10 + def format; end + + # Format of this verbatim section + # + # source://rdoc//lib/rdoc/markup/verbatim.rb#10 + def format=(_arg0); end + + # Collapses 3+ newlines into two newlines + # + # source://rdoc//lib/rdoc/markup/verbatim.rb#32 + def normalize; end + + # source://rdoc//lib/rdoc/markup/verbatim.rb#53 + def pretty_print(q); end + + # Is this verbatim section Ruby code? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/markup/verbatim.rb#71 + def ruby?; end + + # The text of the section + # + # source://rdoc//lib/rdoc/markup/verbatim.rb#79 + def text; end +end + +# Abstract class representing either a method or an attribute. +# +# source://rdoc//lib/rdoc/method_attr.rb#5 +class RDoc::MethodAttr < ::RDoc::CodeObject + include ::Comparable + + # Creates a new MethodAttr from token stream +text+ and method or attribute + # name +name+. + # + # Usually this is called by super from a subclass. + # + # @return [MethodAttr] a new instance of MethodAttr + # + # source://rdoc//lib/rdoc/method_attr.rb#78 + def initialize(text, name); end + + # Order by #singleton then #name + # + # source://rdoc//lib/rdoc/method_attr.rb#113 + def <=>(other); end + + # source://rdoc//lib/rdoc/method_attr.rb#121 + def ==(other); end + + # Abstract method. Contexts in their building phase call this + # to register a new alias for this known method/attribute. + # + # - creates a new AnyMethod/Attribute named an_alias.new_name; + # - adds +self+ as an alias for the new method or attribute + # - adds the method or attribute to #aliases + # - adds the method or attribute to +context+. + # + # @raise [NotImplementedError] + # + # source://rdoc//lib/rdoc/method_attr.rb#209 + def add_alias(an_alias, context); end + + # Prepend +src+ with line numbers. Relies on the first line of a source + # code listing having: + # + # # File xxxxx, line dddd + # + # If it has this comment then line numbers are added to +src+ and the , + # line dddd portion of the comment is removed. + # + # source://rdoc//lib/rdoc/generator/markup.rb#77 + def add_line_numbers(src); end + + # Array of other names for this method/attribute + # + # source://rdoc//lib/rdoc/method_attr.rb#32 + def aliases; end + + # HTML fragment reference for this method + # + # source://rdoc//lib/rdoc/method_attr.rb#216 + def aref; end + + # Prefix for +aref+, defined by subclasses. + # + # @raise [NotImplementedError] + # + # source://rdoc//lib/rdoc/method_attr.rb#225 + def aref_prefix; end + + # The call_seq or the param_seq with method name, if there is no call_seq. + # + # source://rdoc//lib/rdoc/method_attr.rb#64 + def arglists; end + + # Parameters yielded by the called block + # + # source://rdoc//lib/rdoc/method_attr.rb#49 + def block_params; end + + # Attempts to sanitize the content passed by the Ruby parser: + # remove outer parentheses, etc. + # + # source://rdoc//lib/rdoc/method_attr.rb#233 + def block_params=(value); end + + # Different ways to call this method + # + # source://rdoc//lib/rdoc/method_attr.rb#59 + def call_seq; end + + # Different ways to call this method + # + # source://rdoc//lib/rdoc/method_attr.rb#59 + def call_seq=(_arg0); end + + # A method/attribute is documented if any of the following is true: + # - it has a comment; + # - it is an alias for a documented method; + # - it has a +#see+ method that is documented. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/method_attr.rb#132 + def documented?; end + + # source://rdoc//lib/rdoc/method_attr.rb#178 + def find_method_or_attribute(name); end + + # source://rdoc//lib/rdoc/method_attr.rb#166 + def find_see; end + + # Full method/attribute name including namespace + # + # source://rdoc//lib/rdoc/method_attr.rb#300 + def full_name; end + + # HTML id-friendly method/attribute name + # + # source://rdoc//lib/rdoc/method_attr.rb#291 + def html_name; end + + # source://rdoc//lib/rdoc/method_attr.rb#105 + def initialize_visibility; end + + # source://rdoc//lib/rdoc/method_attr.rb#304 + def inspect; end + + # The method/attribute we're aliasing + # + # source://rdoc//lib/rdoc/method_attr.rb#37 + def is_alias_for; end + + # The method/attribute we're aliasing + # + # source://rdoc//lib/rdoc/method_attr.rb#37 + def is_alias_for=(_arg0); end + + # Turns the method's token stream into HTML. + # + # Prepends line numbers if +options.line_numbers+ is true. + # + # source://rdoc//lib/rdoc/generator/markup.rb#101 + def markup_code; end + + # Name of this method/attribute. + # + # source://rdoc//lib/rdoc/method_attr.rb#12 + def name; end + + # Name of this method/attribute. + # + # source://rdoc//lib/rdoc/method_attr.rb#12 + def name=(_arg0); end + + # '::' for a class method/attribute, '#' for an instance method. + # + # source://rdoc//lib/rdoc/method_attr.rb#319 + def name_prefix; end + + # Name for output to HTML. For class methods the full name with a "." is + # used like +SomeClass.method_name+. For instance methods the class name is + # used if +context+ does not match the parent. + # + # This is to help prevent people from using :: to call class methods. + # + # source://rdoc//lib/rdoc/method_attr.rb#330 + def output_name(context); end + + # Pretty parameter list for this method + # + # source://rdoc//lib/rdoc/method_attr.rb#69 + def param_seq; end + + # Parameters for this method + # + # source://rdoc//lib/rdoc/method_attr.rb#54 + def params; end + + # Parameters for this method + # + # source://rdoc//lib/rdoc/method_attr.rb#54 + def params=(_arg0); end + + # Name of our parent with special handling for un-marshaled methods + # + # source://rdoc//lib/rdoc/method_attr.rb#360 + def parent_name; end + + # Path to this method for use with HTML generator output. + # + # source://rdoc//lib/rdoc/method_attr.rb#353 + def path; end + + # Method/attribute name with class/instance indicator + # + # source://rdoc//lib/rdoc/method_attr.rb#339 + def pretty_name; end + + # source://rdoc//lib/rdoc/method_attr.rb#364 + def pretty_print(q); end + + # Used by RDoc::Generator::JsonIndex to create a record for the search + # engine. + # + # source://rdoc//lib/rdoc/method_attr.rb#398 + def search_record; end + + # A method/attribute to look at, + # in particular if this method/attribute has no documentation. + # + # It can be a method/attribute of the superclass or of an included module, + # including the Kernel module, which is always appended to the included + # modules. + # + # Returns +nil+ if there is no such method/attribute. + # The +#is_alias_for+ method/attribute, if any, is not included. + # + # Templates may generate a "see also ..." if this method/attribute + # has documentation, and "see ..." if it does not. + # + # source://rdoc//lib/rdoc/method_attr.rb#152 + def see; end + + # Is this a singleton method/attribute? + # + # source://rdoc//lib/rdoc/method_attr.rb#22 + def singleton; end + + # Is this a singleton method/attribute? + # + # source://rdoc//lib/rdoc/method_attr.rb#22 + def singleton=(_arg0); end + + # Sets the store for this class or module and its contained code objects. + # + # source://rdoc//lib/rdoc/method_attr.rb#160 + def store=(store); end + + # Source file token stream + # + # source://rdoc//lib/rdoc/method_attr.rb#27 + def text; end + + # source://rdoc//lib/rdoc/method_attr.rb#410 + def to_s; end + + # Type of method/attribute (class or instance) + # + # source://rdoc//lib/rdoc/method_attr.rb#346 + def type; end + + # public, protected, private + # + # source://rdoc//lib/rdoc/method_attr.rb#17 + def visibility; end + + # public, protected, private + # + # source://rdoc//lib/rdoc/method_attr.rb#17 + def visibility=(_arg0); end + + private + + # Resets cached data for the object so it can be rebuilt by accessor methods + # + # source://rdoc//lib/rdoc/method_attr.rb#101 + def initialize_copy(other); end +end + +# A Mixin adds features from a module into another context. RDoc::Include and +# RDoc::Extend are both mixins. +# +# source://rdoc//lib/rdoc/mixin.rb#6 +class RDoc::Mixin < ::RDoc::CodeObject + # Creates a new Mixin for +name+ with +comment+ + # + # @return [Mixin] a new instance of Mixin + # + # source://rdoc//lib/rdoc/mixin.rb#16 + def initialize(name, comment); end + + # Mixins are sorted by name + # + # source://rdoc//lib/rdoc/mixin.rb#26 + def <=>(other); end + + # source://rdoc//lib/rdoc/mixin.rb#32 + def ==(other); end + + # source://rdoc//lib/rdoc/mixin.rb#32 + def eql?(other); end + + # Full name based on #module + # + # source://rdoc//lib/rdoc/mixin.rb#41 + def full_name; end + + # source://rdoc//lib/rdoc/mixin.rb#46 + def hash; end + + # source://rdoc//lib/rdoc/mixin.rb#50 + def inspect; end + + # Attempts to locate the included module object. Returns the name if not + # known. + # + # The scoping rules of Ruby to resolve the name of an included module are: + # - first look into the children of the current context; + # - if not found, look into the children of included modules, + # in reverse inclusion order; + # - if still not found, go up the hierarchy of names. + # + # This method has O(n!) behavior when the module calling + # include is referencing nonexistent modules. Avoid calling #module until + # after all the files are parsed. This behavior is due to ruby's constant + # lookup behavior. + # + # As of the beginning of October, 2011, no gem includes nonexistent modules. + # + # source://rdoc//lib/rdoc/mixin.rb#75 + def module; end + + # Name of included module + # + # source://rdoc//lib/rdoc/mixin.rb#11 + def name; end + + # Name of included module + # + # source://rdoc//lib/rdoc/mixin.rb#11 + def name=(_arg0); end + + # Sets the store for this class or module and its contained code objects. + # + # source://rdoc//lib/rdoc/mixin.rb#110 + def store=(store); end + + # source://rdoc//lib/rdoc/mixin.rb#116 + def to_s; end +end + +# A normal class, neither singleton nor anonymous +# +# source://rdoc//lib/rdoc/normal_class.rb#5 +class RDoc::NormalClass < ::RDoc::ClassModule + # The ancestors of this class including modules. Unlike Module#ancestors, + # this class is not included in the result. The result will contain both + # RDoc::ClassModules and Strings. + # + # source://rdoc//lib/rdoc/normal_class.rb#12 + def ancestors; end + + # source://rdoc//lib/rdoc/normal_class.rb#24 + def aref_prefix; end + + # The definition of this class, class MyClassName + # + # source://rdoc//lib/rdoc/normal_class.rb#31 + def definition; end + + # source://rdoc//lib/rdoc/normal_class.rb#35 + def direct_ancestors; end + + # source://rdoc//lib/rdoc/normal_class.rb#39 + def inspect; end + + # source://rdoc//lib/rdoc/normal_class.rb#56 + def pretty_print(q); end + + # source://rdoc//lib/rdoc/normal_class.rb#47 + def to_s; end +end + +# A normal module, like NormalClass +# +# source://rdoc//lib/rdoc/normal_module.rb#5 +class RDoc::NormalModule < ::RDoc::ClassModule + # source://rdoc//lib/rdoc/normal_module.rb#7 + def aref_prefix; end + + # The definition of this module, module MyModuleName + # + # source://rdoc//lib/rdoc/normal_module.rb#21 + def definition; end + + # source://rdoc//lib/rdoc/normal_module.rb#11 + def inspect; end + + # This is a module, returns true + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/normal_module.rb#28 + def module?; end + + # source://rdoc//lib/rdoc/normal_module.rb#32 + def pretty_print(q); end + + # Modules don't have one, raises NoMethodError + # + # @raise [NoMethodError] + # + # source://rdoc//lib/rdoc/normal_module.rb#69 + def superclass; end +end + +# RDoc::Options handles the parsing and storage of options +# +# == Saved Options +# +# You can save some options like the markup format in the +# .rdoc_options file in your gem. The easiest way to do this is: +# +# rdoc --markup tomdoc --write-options +# +# Which will automatically create the file and fill it with the options you +# specified. +# +# The following options will not be saved since they interfere with the user's +# preferences or with the normal operation of RDoc: +# +# * +--coverage-report+ +# * +--dry-run+ +# * +--encoding+ +# * +--force-update+ +# * +--format+ +# * +--pipe+ +# * +--quiet+ +# * +--template+ +# * +--verbose+ +# +# == Custom Options +# +# Generators can hook into RDoc::Options to add generator-specific command +# line options. +# +# When --format is encountered in ARGV, RDoc calls ::setup_options on +# the generator class to add extra options to the option parser. Options for +# custom generators must occur after --format. rdoc --help +# will list options for all installed generators. +# +# Example: +# +# class RDoc::Generator::Spellcheck +# RDoc::RDoc.add_generator self +# +# def self.setup_options rdoc_options +# op = rdoc_options.option_parser +# +# op.on('--spell-dictionary DICTIONARY', +# RDoc::Options::Path) do |dictionary| +# rdoc_options.spell_dictionary = dictionary +# end +# end +# end +# +# Of course, RDoc::Options does not respond to +spell_dictionary+ by default +# so you will need to add it: +# +# class RDoc::Options +# +# ## +# # The spell dictionary used by the spell-checking plugin. +# +# attr_accessor :spell_dictionary +# +# end +# +# == Option Validators +# +# OptionParser validators will validate and cast user input values. In +# addition to the validators that ship with OptionParser (String, Integer, +# Float, TrueClass, FalseClass, Array, Regexp, Date, Time, URI, etc.), +# RDoc::Options adds Path, PathArray and Template. +# +# source://rdoc//lib/rdoc/options.rb#75 +class RDoc::Options + # @return [Options] a new instance of Options + # + # source://rdoc//lib/rdoc/options.rb#347 + def initialize(loaded_options = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/options.rb#460 + def ==(other); end + + # Character-set for HTML output. #encoding is preferred over #charset + # + # source://rdoc//lib/rdoc/options.rb#152 + def charset; end + + # Character-set for HTML output. #encoding is preferred over #charset + # + # source://rdoc//lib/rdoc/options.rb#152 + def charset=(_arg0); end + + # Check that the files on the command line exist + # + # source://rdoc//lib/rdoc/options.rb#484 + def check_files; end + + # Ensure only one generator is loaded + # + # source://rdoc//lib/rdoc/options.rb#505 + def check_generator; end + + # If true, only report on undocumented files + # + # source://rdoc//lib/rdoc/options.rb#244 + def coverage_report; end + + # If true, only report on undocumented files + # + # source://rdoc//lib/rdoc/options.rb#244 + def coverage_report=(_arg0); end + + # Set the title, but only if not already set. Used to set the title + # from a source file, so that a title set from the command line + # will have the priority. + # + # source://rdoc//lib/rdoc/options.rb#517 + def default_title=(string); end + + # If true, RDoc will not write any files. + # + # source://rdoc//lib/rdoc/options.rb#157 + def dry_run; end + + # If true, RDoc will not write any files. + # + # source://rdoc//lib/rdoc/options.rb#157 + def dry_run=(_arg0); end + + # The output encoding. All input files will be transcoded to this encoding. + # + # The default encoding is UTF-8. This is set via --encoding. + # + # source://rdoc//lib/rdoc/options.rb#164 + def encoding; end + + # The output encoding. All input files will be transcoded to this encoding. + # + # The default encoding is UTF-8. This is set via --encoding. + # + # source://rdoc//lib/rdoc/options.rb#164 + def encoding=(_arg0); end + + # Create a regexp for #exclude + # + # source://rdoc//lib/rdoc/options.rb#545 + def exclude; end + + # Files matching this pattern will be excluded + # + # source://rdoc//lib/rdoc/options.rb#169 + def exclude=(_arg0); end + + # The list of files to be processed + # + # source://rdoc//lib/rdoc/options.rb#174 + def files; end + + # The list of files to be processed + # + # source://rdoc//lib/rdoc/options.rb#174 + def files=(_arg0); end + + # Completes any unfinished option setup business such as filtering for + # existent files, creating a regexp for #exclude and setting a default + # #template. + # + # source://rdoc//lib/rdoc/options.rb#561 + def finish; end + + # Fixes the page_dir to be relative to the root_dir and adds the page_dir to + # the files list. + # + # source://rdoc//lib/rdoc/options.rb#602 + def finish_page_dir; end + + # Create the output even if the output directory does not look + # like an rdoc output directory + # + # source://rdoc//lib/rdoc/options.rb#180 + def force_output; end + + # Create the output even if the output directory does not look + # like an rdoc output directory + # + # source://rdoc//lib/rdoc/options.rb#180 + def force_output=(_arg0); end + + # Scan newer sources than the flag file if true. + # + # source://rdoc//lib/rdoc/options.rb#185 + def force_update; end + + # Scan newer sources than the flag file if true. + # + # source://rdoc//lib/rdoc/options.rb#185 + def force_update=(_arg0); end + + # Formatter to mark up text with + # + # source://rdoc//lib/rdoc/options.rb#190 + def formatter; end + + # Formatter to mark up text with + # + # source://rdoc//lib/rdoc/options.rb#190 + def formatter=(_arg0); end + + # Description of the output generator (set with the --format option) + # + # source://rdoc//lib/rdoc/options.rb#195 + def generator; end + + # Description of the output generator (set with the --format option) + # + # source://rdoc//lib/rdoc/options.rb#195 + def generator=(_arg0); end + + # Returns a properly-space list of generators and their descriptions. + # + # source://rdoc//lib/rdoc/options.rb#621 + def generator_descriptions; end + + # For #== + # + # source://rdoc//lib/rdoc/options.rb#200 + def generator_name; end + + # Loaded generator options. Used to prevent --help from loading the same + # options multiple times. + # + # source://rdoc//lib/rdoc/options.rb#206 + def generator_options; end + + # Loaded generator options. Used to prevent --help from loading the same + # options multiple times. + # + # source://rdoc//lib/rdoc/options.rb#206 + def generator_options=(_arg0); end + + # Old rdoc behavior: hyperlink all words that match a method name, + # even if not preceded by '#' or '::' + # + # source://rdoc//lib/rdoc/options.rb#212 + def hyperlink_all; end + + # Old rdoc behavior: hyperlink all words that match a method name, + # even if not preceded by '#' or '::' + # + # source://rdoc//lib/rdoc/options.rb#212 + def hyperlink_all=(_arg0); end + + # source://rdoc//lib/rdoc/options.rb#352 + def init_ivars; end + + # source://rdoc//lib/rdoc/options.rb#397 + def init_with(map); end + + # Include line numbers in the source code + # + # source://rdoc//lib/rdoc/options.rb#217 + def line_numbers; end + + # Include line numbers in the source code + # + # source://rdoc//lib/rdoc/options.rb#217 + def line_numbers=(_arg0); end + + # The output locale. + # + # source://rdoc//lib/rdoc/options.rb#222 + def locale; end + + # The output locale. + # + # source://rdoc//lib/rdoc/options.rb#222 + def locale=(_arg0); end + + # The directory where locale data live. + # + # source://rdoc//lib/rdoc/options.rb#227 + def locale_dir; end + + # The directory where locale data live. + # + # source://rdoc//lib/rdoc/options.rb#227 + def locale_dir=(_arg0); end + + # Name of the file, class or module to display in the initial index page (if + # not specified the first file we encounter is used) + # + # source://rdoc//lib/rdoc/options.rb#233 + def main_page; end + + # Name of the file, class or module to display in the initial index page (if + # not specified the first file we encounter is used) + # + # source://rdoc//lib/rdoc/options.rb#233 + def main_page=(_arg0); end + + # The default markup format. The default is 'rdoc'. 'markdown', 'tomdoc' + # and 'rd' are also built-in. + # + # source://rdoc//lib/rdoc/options.rb#239 + def markup; end + + # The default markup format. The default is 'rdoc'. 'markdown', 'tomdoc' + # and 'rd' are also built-in. + # + # source://rdoc//lib/rdoc/options.rb#239 + def markup=(_arg0); end + + # The name of the output directory + # + # source://rdoc//lib/rdoc/options.rb#249 + def op_dir; end + + # The name of the output directory + # + # source://rdoc//lib/rdoc/options.rb#249 + def op_dir=(_arg0); end + + # The OptionParser for this instance + # + # source://rdoc//lib/rdoc/options.rb#254 + def option_parser; end + + # The OptionParser for this instance + # + # source://rdoc//lib/rdoc/options.rb#254 + def option_parser=(_arg0); end + + # Output heading decorations? + # + # source://rdoc//lib/rdoc/options.rb#258 + def output_decoration; end + + # Output heading decorations? + # + # source://rdoc//lib/rdoc/options.rb#258 + def output_decoration=(_arg0); end + + # source://rdoc//lib/rdoc/options.rb#428 + def override(map); end + + # Directory where guides, FAQ, and other pages not associated with a class + # live. You may leave this unset if these are at the root of your project. + # + # source://rdoc//lib/rdoc/options.rb#264 + def page_dir; end + + # Directory where guides, FAQ, and other pages not associated with a class + # live. You may leave this unset if these are at the root of your project. + # + # source://rdoc//lib/rdoc/options.rb#264 + def page_dir=(_arg0); end + + # Parses command line options. + # + # source://rdoc//lib/rdoc/options.rb#647 + def parse(argv); end + + # Is RDoc in pipe mode? + # + # source://rdoc//lib/rdoc/options.rb#269 + def pipe; end + + # Is RDoc in pipe mode? + # + # source://rdoc//lib/rdoc/options.rb#269 + def pipe=(_arg0); end + + # Don't display progress as we process the files + # + # source://rdoc//lib/rdoc/options.rb#1192 + def quiet; end + + # Set quietness to +bool+ + # + # source://rdoc//lib/rdoc/options.rb#1199 + def quiet=(bool); end + + # Array of directories to search for files to satisfy an :include: + # + # source://rdoc//lib/rdoc/options.rb#274 + def rdoc_include; end + + # Array of directories to search for files to satisfy an :include: + # + # source://rdoc//lib/rdoc/options.rb#274 + def rdoc_include=(_arg0); end + + # Root of the source documentation will be generated for. Set this when + # building documentation outside the source directory. Defaults to the + # current directory. + # + # source://rdoc//lib/rdoc/options.rb#281 + def root; end + + # Root of the source documentation will be generated for. Set this when + # building documentation outside the source directory. Defaults to the + # current directory. + # + # source://rdoc//lib/rdoc/options.rb#281 + def root=(_arg0); end + + # Removes directories from +path+ that are outside the current directory + # + # source://rdoc//lib/rdoc/options.rb#1206 + def sanitize_path(path); end + + # Set up an output generator for the named +generator_name+. + # + # If the found generator responds to :setup_options it will be called with + # the options instance. This allows generators to add custom options or set + # default options. + # + # source://rdoc//lib/rdoc/options.rb#1233 + def setup_generator(generator_name = T.unsafe(nil)); end + + # Include the '#' at the front of hyperlinked instance method names + # + # source://rdoc//lib/rdoc/options.rb#286 + def show_hash; end + + # Include the '#' at the front of hyperlinked instance method names + # + # source://rdoc//lib/rdoc/options.rb#286 + def show_hash=(_arg0); end + + # Indicates if files of test suites should be skipped + # + # source://rdoc//lib/rdoc/options.rb#345 + def skip_tests; end + + # Indicates if files of test suites should be skipped + # + # source://rdoc//lib/rdoc/options.rb#345 + def skip_tests=(_arg0); end + + # Directory to copy static files from + # + # source://rdoc//lib/rdoc/options.rb#291 + def static_path; end + + # Directory to copy static files from + # + # source://rdoc//lib/rdoc/options.rb#291 + def static_path=(_arg0); end + + # The number of columns in a tab + # + # source://rdoc//lib/rdoc/options.rb#296 + def tab_width; end + + # The number of columns in a tab + # + # source://rdoc//lib/rdoc/options.rb#296 + def tab_width=(_arg0); end + + # Template to be used when generating output + # + # source://rdoc//lib/rdoc/options.rb#301 + def template; end + + # Template to be used when generating output + # + # source://rdoc//lib/rdoc/options.rb#301 + def template=(_arg0); end + + # Directory the template lives in + # + # source://rdoc//lib/rdoc/options.rb#306 + def template_dir; end + + # Directory the template lives in + # + # source://rdoc//lib/rdoc/options.rb#306 + def template_dir=(_arg0); end + + # Finds the template dir for +template+ + # + # source://rdoc//lib/rdoc/options.rb#1255 + def template_dir_for(template); end + + # Additional template stylesheets + # + # source://rdoc//lib/rdoc/options.rb#311 + def template_stylesheets; end + + # Additional template stylesheets + # + # source://rdoc//lib/rdoc/options.rb#311 + def template_stylesheets=(_arg0); end + + # Documentation title + # + # source://rdoc//lib/rdoc/options.rb#316 + def title; end + + # Documentation title + # + # source://rdoc//lib/rdoc/options.rb#316 + def title=(_arg0); end + + # For dumping YAML + # + # source://rdoc//lib/rdoc/options.rb#524 + def to_yaml(*options); end + + # Should RDoc update the timestamps in the output dir? + # + # source://rdoc//lib/rdoc/options.rb#321 + def update_output_dir; end + + # Should RDoc update the timestamps in the output dir? + # + # source://rdoc//lib/rdoc/options.rb#321 + def update_output_dir=(_arg0); end + + # Verbosity, zero means quiet + # + # source://rdoc//lib/rdoc/options.rb#326 + def verbosity; end + + # Verbosity, zero means quiet + # + # source://rdoc//lib/rdoc/options.rb#326 + def verbosity=(_arg0); end + + # Minimum visibility of a documented method. One of +:public+, +:protected+, + # +:private+ or +:nodoc+. + # + # The +:nodoc+ visibility ignores all directives related to visibility. The + # directive. + # + # source://rdoc//lib/rdoc/options.rb#341 + def visibility; end + + # Sets the minimum visibility of a documented method. + # + # Accepts +:public+, +:protected+, +:private+, +:nodoc+, or +:all+. + # + # When +:all+ is passed, visibility is set to +:private+, similarly to + # RDOCOPT="--all", see #visibility for more information. + # + # source://rdoc//lib/rdoc/options.rb#1272 + def visibility=(visibility); end + + # Displays a warning using Kernel#warn if we're being verbose + # + # source://rdoc//lib/rdoc/options.rb#1284 + def warn(message); end + + # URL of web cvs frontend + # + # source://rdoc//lib/rdoc/options.rb#331 + def webcvs; end + + # URL of web cvs frontend + # + # source://rdoc//lib/rdoc/options.rb#331 + def webcvs=(_arg0); end + + # Writes the YAML file .rdoc_options to the current directory containing the + # parsed options. + # + # source://rdoc//lib/rdoc/options.rb#1292 + def write_options; end + + # source://rdoc//lib/rdoc/options.rb#424 + def yaml_initialize(tag, map); end + + class << self + # Loads options from .rdoc_options if the file exists, otherwise creates a + # new RDoc::Options instance. + # + # @raise [RDoc::Error] + # + # source://rdoc//lib/rdoc/options.rb#1306 + def load_options; end + end +end + +# A parser is simple a class that subclasses RDoc::Parser and implements #scan +# to fill in an RDoc::TopLevel with parsed data. +# +# The initialize method takes an RDoc::TopLevel to fill with parsed content, +# the name of the file to be parsed, the content of the file, an RDoc::Options +# object and an RDoc::Stats object to inform the user of parsed items. The +# scan method is then called to parse the file and must return the +# RDoc::TopLevel object. By calling super these items will be set for you. +# +# In order to be used by RDoc the parser needs to register the file extensions +# it can parse. Use ::parse_files_matching to register extensions. +# +# require 'rdoc' +# +# class RDoc::Parser::Xyz < RDoc::Parser +# parse_files_matching /\.xyz$/ +# +# def initialize top_level, file_name, content, options, stats +# super +# +# # extra initialization if needed +# end +# +# def scan +# # parse file and fill in @top_level +# end +# end +# +# source://rdoc//lib/rdoc/parser.rb#33 +class RDoc::Parser + # Creates a new Parser storing +top_level+, +file_name+, +content+, + # +options+ and +stats+ in instance variables. In +@preprocess+ an + # RDoc::Markup::PreProcess object is created which allows processing of + # directives. + # + # @return [Parser] a new instance of Parser + # + # source://rdoc//lib/rdoc/parser.rb#254 + def initialize(top_level, file_name, content, options, stats); end + + # The name of the file being parsed + # + # source://rdoc//lib/rdoc/parser.rb#52 + def file_name; end + + # Normalizes tabs in +body+ + # + # source://rdoc//lib/rdoc/parser.rb#274 + def handle_tab_width(body); end + + class << self + # Alias an extension to another extension. After this call, files ending + # "new_ext" will be parsed using the same parser as "old_ext" + # + # source://rdoc//lib/rdoc/parser.rb#58 + def alias_extension(old_ext, new_ext); end + + # Determines if the file is a "binary" file which basically means it has + # content that an RDoc parser shouldn't try to consume. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/parser.rb#74 + def binary?(file); end + + # Return a parser that can handle a particular extension + # + # source://rdoc//lib/rdoc/parser.rb#107 + def can_parse(file_name); end + + # Returns a parser that can handle the extension for +file_name+. This does + # not depend upon the file being readable. + # + # source://rdoc//lib/rdoc/parser.rb#120 + def can_parse_by_name(file_name); end + + # Returns the file type from the modeline in +file_name+ + # + # source://rdoc//lib/rdoc/parser.rb#143 + def check_modeline(file_name); end + + # Finds and instantiates the correct parser for the given +file_name+ and + # +content+. + # + # source://rdoc//lib/rdoc/parser.rb#169 + def for(top_level, file_name, content, options, stats); end + + # Record which file types this parser can understand. + # + # It is ok to call this multiple times. + # + # source://rdoc//lib/rdoc/parser.rb#203 + def parse_files_matching(regexp); end + + # An Array of arrays that maps file extension (or name) regular + # expressions to parser classes that will parse matching filenames. + # + # Use parse_files_matching to register a parser's file extensions. + # + # source://rdoc//lib/rdoc/parser.rb#45 + def parsers; end + + # Removes an emacs-style modeline from the first line of the document + # + # source://rdoc//lib/rdoc/parser.rb#210 + def remove_modeline(content); end + + # If there is a markup: parser_name comment at the front of the + # file, use it to determine the parser. For example: + # + # # markup: rdoc + # # Class comment can go here + # + # class C + # end + # + # The comment should appear as the first line of the +content+. + # + # If the content contains a shebang or editor modeline the comment may + # appear on the second or third line. + # + # Any comment style may be used to hide the markup comment. + # + # source://rdoc//lib/rdoc/parser.rb#231 + def use_markup(content); end + + # Checks if +file+ is a zip file in disguise. Signatures from + # http://www.garykessler.net/library/file_sigs.html + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/parser.rb#94 + def zip?(file); end + end +end + +# RDoc::Parser::C attempts to parse C extension files. It looks for +# the standard patterns that you find in extensions: +rb_define_class+, +# +rb_define_method+ and so on. It tries to find the corresponding +# C source for the methods and extract comments, but if we fail +# we don't worry too much. +# +# The comments associated with a Ruby method are extracted from the C +# comment block associated with the routine that _implements_ that +# method, that is to say the method whose name is given in the +# +rb_define_method+ call. For example, you might write: +# +# /* +# * Returns a new array that is a one-dimensional flattening of this +# * array (recursively). That is, for every element that is an array, +# * extract its elements into the new array. +# * +# * s = [ 1, 2, 3 ] #=> [1, 2, 3] +# * t = [ 4, 5, 6, [7, 8] ] #=> [4, 5, 6, [7, 8]] +# * a = [ s, t, 9, 10 ] #=> [[1, 2, 3], [4, 5, 6, [7, 8]], 9, 10] +# * a.flatten #=> [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] +# */ +# static VALUE +# rb_ary_flatten(VALUE ary) +# { +# ary = rb_obj_dup(ary); +# rb_ary_flatten_bang(ary); +# return ary; +# } +# +# ... +# +# void +# Init_Array(void) +# { +# ... +# rb_define_method(rb_cArray, "flatten", rb_ary_flatten, 0); +# +# Here RDoc will determine from the +rb_define_method+ line that there's a +# method called "flatten" in class Array, and will look for the implementation +# in the method +rb_ary_flatten+. It will then use the comment from that +# method in the HTML output. This method must be in the same source file +# as the +rb_define_method+. +# +# The comment blocks may include special directives: +# +# [Document-class: +name+] +# Documentation for the named class. +# +# [Document-module: +name+] +# Documentation for the named module. +# +# [Document-const: +name+] +# Documentation for the named +rb_define_const+. +# +# Constant values can be supplied on the first line of the comment like so: +# +# /* 300: The highest possible score in bowling */ +# rb_define_const(cFoo, "PERFECT", INT2FIX(300)); +# +# The value can contain internal colons so long as they are escaped with a \ +# +# [Document-global: +name+] +# Documentation for the named +rb_define_global_const+ +# +# [Document-variable: +name+] +# Documentation for the named +rb_define_variable+ +# +# [Document-method\: +method_name+] +# Documentation for the named method. Use this when the method name is +# unambiguous. +# +# [Document-method\: ClassName::method_name] +# Documentation for a singleton method in the given class. Use this when +# the method name alone is ambiguous. +# +# [Document-method\: ClassName#method_name] +# Documentation for a instance method in the given class. Use this when the +# method name alone is ambiguous. +# +# [Document-attr: +name+] +# Documentation for the named attribute. +# +# [call-seq: text up to an empty line] +# Because C source doesn't give descriptive names to Ruby-level parameters, +# you need to document the calling sequence explicitly +# +# In addition, RDoc assumes by default that the C method implementing a +# Ruby function is in the same source file as the rb_define_method call. +# If this isn't the case, add the comment: +# +# rb_define_method(....); // in filename +# +# As an example, we might have an extension that defines multiple classes +# in its Init_xxx method. We could document them using +# +# /* +# * Document-class: MyClass +# * +# * Encapsulate the writing and reading of the configuration +# * file. ... +# */ +# +# /* +# * Document-method: read_value +# * +# * call-seq: +# * cfg.read_value(key) -> value +# * cfg.read_value(key} { |key| } -> value +# * +# * Return the value corresponding to +key+ from the configuration. +# * In the second form, if the key isn't found, invoke the +# * block and return its value. +# */ +# +# source://rdoc//lib/rdoc/parser/c.rb#119 +class RDoc::Parser::C < ::RDoc::Parser + include ::RDoc::Text + + # Prepares for parsing a C file. See RDoc::Parser#initialize for details on + # the arguments. + # + # @return [C] a new instance of C + # + # source://rdoc//lib/rdoc/parser/c.rb#171 + def initialize(top_level, file_name, content, options, stats); end + + # Add alias, either from a direct alias definition, or from two + # method that reference the same function. + # + # source://rdoc//lib/rdoc/parser/c.rb#250 + def add_alias(var_name, class_obj, old_name, new_name, comment); end + + # Maps C variable names to names of Ruby classes or modules + # + # source://rdoc//lib/rdoc/parser/c.rb#133 + def classes; end + + # C file the parser is parsing + # + # source://rdoc//lib/rdoc/parser/c.rb#138 + def content; end + + # C file the parser is parsing + # + # source://rdoc//lib/rdoc/parser/c.rb#138 + def content=(_arg0); end + + # Scans #content for rb_define_alias + # + # source://rdoc//lib/rdoc/parser/c.rb#222 + def do_aliases; end + + # Scans #content for rb_attr and rb_define_attr + # + # source://rdoc//lib/rdoc/parser/c.rb#263 + def do_attrs; end + + # Scans #content for boot_defclass + # + # source://rdoc//lib/rdoc/parser/c.rb#286 + def do_boot_defclass; end + + # Scans #content for rb_define_class, boot_defclass, rb_define_class_under + # and rb_singleton_class + # + # source://rdoc//lib/rdoc/parser/c.rb#298 + def do_classes_and_modules; end + + # Scans #content for rb_define_variable, rb_define_readonly_variable, + # rb_define_const and rb_define_global_const + # + # source://rdoc//lib/rdoc/parser/c.rb#396 + def do_constants; end + + # Scans #content for rb_include_module + # + # source://rdoc//lib/rdoc/parser/c.rb#442 + def do_includes; end + + # Scans #content for rb_define_method, rb_define_singleton_method, + # rb_define_module_function, rb_define_private_method, + # rb_define_global_function and define_filetest_function + # + # source://rdoc//lib/rdoc/parser/c.rb#458 + def do_methods; end + + # Creates classes and module that were missing were defined due to the file + # order being different than the declaration order. + # + # source://rdoc//lib/rdoc/parser/c.rb#507 + def do_missing; end + + # Dependencies from a missing enclosing class to the classes in + # missing_dependencies that depend upon it. + # + # source://rdoc//lib/rdoc/parser/c.rb#144 + def enclosure_dependencies; end + + # Finds the comment for an alias on +class_name+ from +new_name+ to + # +old_name+ + # + # source://rdoc//lib/rdoc/parser/c.rb#523 + def find_alias_comment(class_name, new_name, old_name); end + + # Finds a comment for rb_define_attr, rb_attr or Document-attr. + # + # +var_name+ is the C class variable the attribute is defined on. + # +attr_name+ is the attribute's name. + # + # +read+ and +write+ are the read/write flags ('1' or '0'). Either both or + # neither must be provided. + # + # source://rdoc//lib/rdoc/parser/c.rb#541 + def find_attr_comment(var_name, attr_name, read = T.unsafe(nil), write = T.unsafe(nil)); end + + # Find the C code corresponding to a Ruby method + # + # source://rdoc//lib/rdoc/parser/c.rb#598 + def find_body(class_name, meth_name, meth_obj, file_content, quiet = T.unsafe(nil)); end + + # Finds a RDoc::NormalClass or RDoc::NormalModule for +raw_name+ + # + # source://rdoc//lib/rdoc/parser/c.rb#682 + def find_class(raw_name, name, base_name = T.unsafe(nil)); end + + # Look for class or module documentation above Init_+class_name+(void), + # in a Document-class +class_name+ (or module) comment or above an + # rb_define_class (or module). If a comment is supplied above a matching + # Init_ and a rb_define_class the Init_ comment is used. + # + # /* + # * This is a comment for Foo + # */ + # Init_Foo(void) { + # VALUE cFoo = rb_define_class("Foo", rb_cObject); + # } + # + # /* + # * Document-class: Foo + # * This is a comment for Foo + # */ + # Init_foo(void) { + # VALUE cFoo = rb_define_class("Foo", rb_cObject); + # } + # + # /* + # * This is a comment for Foo + # */ + # VALUE cFoo = rb_define_class("Foo", rb_cObject); + # + # source://rdoc//lib/rdoc/parser/c.rb#723 + def find_class_comment(class_name, class_mod); end + + # Finds a comment matching +type+ and +const_name+ either above the + # comment or in the matching Document- section. + # + # source://rdoc//lib/rdoc/parser/c.rb#789 + def find_const_comment(type, const_name, class_name = T.unsafe(nil)); end + + # Handles modifiers in +comment+ and updates +meth_obj+ as appropriate. + # + # source://rdoc//lib/rdoc/parser/c.rb#806 + def find_modifiers(comment, meth_obj); end + + # Finds a Document-method override for +meth_obj+ on +class_name+ + # + # source://rdoc//lib/rdoc/parser/c.rb#816 + def find_override_comment(class_name, meth_obj); end + + # Generate a Ruby-method table + # + # source://rdoc//lib/rdoc/parser/c.rb#574 + def gen_body_table(file_content); end + + # Generate a const table + # + # source://rdoc//lib/rdoc/parser/c.rb#756 + def gen_const_table(file_content); end + + # Creates a new RDoc::Attr +attr_name+ on class +var_name+ that is either + # +read+, +write+ or both + # + # source://rdoc//lib/rdoc/parser/c.rb#838 + def handle_attr(var_name, attr_name, read, write); end + + # Creates a new RDoc::NormalClass or RDoc::NormalModule based on +type+ + # named +class_name+ in +parent+ which was assigned to the C +var_name+. + # + # source://rdoc//lib/rdoc/parser/c.rb#867 + def handle_class_module(var_name, type, class_name, parent, in_module); end + + # Adds constants. By providing some_value: at the start of the comment you + # can override the C value of the comment to give a friendly definition. + # + # /* 300: The perfect score in bowling */ + # rb_define_const(cFoo, "PERFECT", INT2FIX(300)); + # + # Will override INT2FIX(300) with the value +300+ in the output + # RDoc. Values may include quotes and escaped colons (\:). + # + # source://rdoc//lib/rdoc/parser/c.rb#932 + def handle_constants(type, var_name, const_name, definition); end + + # Removes #ifdefs that would otherwise confuse us + # + # source://rdoc//lib/rdoc/parser/c.rb#982 + def handle_ifdefs_in(body); end + + # Adds an RDoc::AnyMethod +meth_name+ defined on a class or module assigned + # to +var_name+. +type+ is the type of method definition function used. + # +singleton_method+ and +module_function+ create a singleton method. + # + # source://rdoc//lib/rdoc/parser/c.rb#991 + def handle_method(type, var_name, meth_name, function, param_count, source_file = T.unsafe(nil)); end + + # Registers a singleton class +sclass_var+ as a singleton of +class_var+ + # + # source://rdoc//lib/rdoc/parser/c.rb#1061 + def handle_singleton(sclass_var, class_var); end + + # Maps C variable names to names of Ruby classes (and singleton classes) + # + # source://rdoc//lib/rdoc/parser/c.rb#149 + def known_classes; end + + # Loads the variable map with the given +name+ from the RDoc::Store, if + # present. + # + # source://rdoc//lib/rdoc/parser/c.rb#1072 + def load_variable_map(map_name); end + + # Look for directives in a normal comment block: + # + # /* + # * :title: My Awesome Project + # */ + # + # This method modifies the +comment+ + # + # source://rdoc//lib/rdoc/parser/c.rb#1101 + def look_for_directives_in(context, comment); end + + # Classes found while parsing the C file that were not yet registered due to + # a missing enclosing class. These are processed by do_missing + # + # source://rdoc//lib/rdoc/parser/c.rb#155 + def missing_dependencies; end + + # Creates a RDoc::Comment instance. + # + # source://rdoc//lib/rdoc/parser/c.rb#1231 + def new_comment(text = T.unsafe(nil), location = T.unsafe(nil), language = T.unsafe(nil)); end + + # Extracts parameters from the +method_body+ and returns a method + # parameter string. Follows 1.9.3dev's scan-arg-spec, see README.EXT + # + # source://rdoc//lib/rdoc/parser/c.rb#1120 + def rb_scan_args(method_body); end + + # Removes lines that are commented out that might otherwise get picked up + # when scanning for classes and methods + # + # source://rdoc//lib/rdoc/parser/c.rb#1203 + def remove_commented_out_lines; end + + # Extracts the classes, modules, methods, attributes, constants and aliases + # from a C file and returns an RDoc::TopLevel for this file + # + # source://rdoc//lib/rdoc/parser/c.rb#1211 + def scan; end + + # Maps C variable names to names of Ruby singleton classes + # + # source://rdoc//lib/rdoc/parser/c.rb#160 + def singleton_classes; end + + # The TopLevel items in the parsed file belong to + # + # source://rdoc//lib/rdoc/parser/c.rb#165 + def top_level; end +end + +# :stopdoc: +# +# source://rdoc//lib/rdoc/parser/c.rb#126 +RDoc::Parser::C::BOOL_ARG_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://rdoc//lib/rdoc/parser/c.rb#127 +RDoc::Parser::C::TRUE_VALUES = T.let(T.unsafe(nil), Array) + +# A ChangeLog file parser. +# +# This parser converts a ChangeLog into an RDoc::Markup::Document. When +# viewed as HTML a ChangeLog page will have an entry for each day's entries in +# the sidebar table of contents. +# +# This parser is meant to parse the MRI ChangeLog, but can be used to parse any +# {GNU style Change +# Log}[http://www.gnu.org/prep/standards/html_node/Style-of-Change-Logs.html]. +# +# source://rdoc//lib/rdoc/parser/changelog.rb#14 +class RDoc::Parser::ChangeLog < ::RDoc::Parser + include ::RDoc::Parser::Text + + # Attaches the +continuation+ of the previous line to the +entry_body+. + # + # Continued function listings are joined together as a single entry. + # Continued descriptions are joined to make a single paragraph. + # + # source://rdoc//lib/rdoc/parser/changelog.rb#26 + def continue_entry_body(entry_body, continuation); end + + # Creates an RDoc::Markup::Document given the +groups+ of ChangeLog entries. + # + # source://rdoc//lib/rdoc/parser/changelog.rb#44 + def create_document(groups); end + + # Returns a list of ChangeLog entries an RDoc::Markup nodes for the given + # +entries+. + # + # source://rdoc//lib/rdoc/parser/changelog.rb#66 + def create_entries(entries); end + + # Returns an RDoc::Markup::List containing the given +items+ in the + # ChangeLog + # + # source://rdoc//lib/rdoc/parser/changelog.rb#83 + def create_items(items); end + + # Groups +entries+ by date. + # + # source://rdoc//lib/rdoc/parser/changelog.rb#103 + def group_entries(entries); end + + # Parse date in ISO-8601, RFC-2822, or default of Git + # + # source://rdoc//lib/rdoc/parser/changelog.rb#119 + def parse_date(date); end + + # Parses the entries in the ChangeLog. + # + # Returns an Array of each ChangeLog entry in order of parsing. + # + # A ChangeLog entry is an Array containing the ChangeLog title (date and + # committer) and an Array of ChangeLog items (file and function changed with + # description). + # + # An example result would be: + # + # [ 'Tue Dec 4 08:33:46 2012 Eric Hodel ', + # [ 'README.EXT: Converted to RDoc format', + # 'README.EXT.ja: ditto']] + # + # source://rdoc//lib/rdoc/parser/changelog.rb#149 + def parse_entries; end + + # Converts the ChangeLog into an RDoc::Markup::Document + # + # source://rdoc//lib/rdoc/parser/changelog.rb#206 + def scan; end +end + +# The extension for Git commit log +# +# source://rdoc//lib/rdoc/parser/changelog.rb#222 +module RDoc::Parser::ChangeLog::Git + # Returns a list of ChangeLog entries as + # RDoc::Parser::ChangeLog::Git::LogEntry list for the given + # +entries+. + # + # source://rdoc//lib/rdoc/parser/changelog.rb#262 + def create_entries(entries); end + + # Parses the entries in the Git commit logs + # + # source://rdoc//lib/rdoc/parser/changelog.rb#235 + def parse_entries; end + + # Parses auxiliary info. Currentry `base-url` to expand + # references is effective. + # + # source://rdoc//lib/rdoc/parser/changelog.rb#227 + def parse_info(info); end +end + +# source://rdoc//lib/rdoc/parser/changelog.rb#271 +RDoc::Parser::ChangeLog::Git::HEADING_LEVEL = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/changelog.rb#270 +class RDoc::Parser::ChangeLog::Git::LogEntry < ::Struct + # @return [LogEntry] a new instance of LogEntry + # + # source://rdoc//lib/rdoc/parser/changelog.rb#273 + def initialize(base, commit, author, email, date, contents); end + + # source://rdoc//lib/rdoc/parser/changelog.rb#313 + def accept(visitor); end + + # source://rdoc//lib/rdoc/parser/changelog.rb#294 + def aref; end + + # Returns the value of attribute author + # + # @return [Object] the current value of author + def author; end + + # Sets the attribute author + # + # @param value [Object] the value to set the attribute author to. + # @return [Object] the newly set value + def author=(_); end + + # Returns the value of attribute base + # + # @return [Object] the current value of base + def base; end + + # Sets the attribute base + # + # @param value [Object] the value to set the attribute base to. + # @return [Object] the newly set value + def base=(_); end + + # Returns the value of attribute commit + # + # @return [Object] the current value of commit + def commit; end + + # Sets the attribute commit + # + # @param value [Object] the value to set the attribute commit to. + # @return [Object] the newly set value + def commit=(_); end + + # Returns the value of attribute contents + # + # @return [Object] the current value of contents + def contents; end + + # Sets the attribute contents + # + # @param value [Object] the value to set the attribute contents to. + # @return [Object] the newly set value + def contents=(_); end + + # Returns the value of attribute date + # + # @return [Object] the current value of date + def date; end + + # Sets the attribute date + # + # @param value [Object] the value to set the attribute date to. + # @return [Object] the newly set value + def date=(_); end + + # Returns the value of attribute email + # + # @return [Object] the current value of email + def email; end + + # Sets the attribute email + # + # @param value [Object] the value to set the attribute email to. + # @return [Object] the newly set value + def email=(_); end + + # source://rdoc//lib/rdoc/parser/changelog.rb#298 + def label(context = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/parser/changelog.rb#290 + def level; end + + # source://rdoc//lib/rdoc/parser/changelog.rb#330 + def pretty_print(q); end + + # source://rdoc//lib/rdoc/parser/changelog.rb#302 + def text; end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# Parse a Markdown format file. The parsed RDoc::Markup::Document is attached +# as a file comment. +# +# source://rdoc//lib/rdoc/parser/markdown.rb#6 +class RDoc::Parser::Markdown < ::RDoc::Parser + include ::RDoc::Parser::Text + + # Creates an Markdown-format TopLevel for the given file. + # + # source://rdoc//lib/rdoc/parser/markdown.rb#15 + def scan; end +end + +# Parse a RD format file. The parsed RDoc::Markup::Document is attached as a +# file comment. +# +# source://rdoc//lib/rdoc/parser/rd.rb#6 +class RDoc::Parser::RD < ::RDoc::Parser + include ::RDoc::Parser::Text + + # Creates an rd-format TopLevel for the given file. + # + # source://rdoc//lib/rdoc/parser/rd.rb#15 + def scan; end +end + +# Wrapper for Ripper lex states +# +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#7 +class RDoc::Parser::RipperStateLex + # New lexer for +code+. + # + # @return [RipperStateLex] a new instance of RipperStateLex + # + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#576 + def initialize(code); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#322 + def get_squashed_tk; end + + private + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#465 + def get_embdoc_tk(tk); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#474 + def get_heredoc_tk(heredoc_name, indent); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#549 + def get_op_tk(tk); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#447 + def get_regexp_tk(tk); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#420 + def get_string_tk(tk); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#373 + def get_symbol_tk(tk); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#511 + def get_words_tk(tk); end + + # @return [Boolean] + # + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#499 + def heredoc_end?(name, indent, tk); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#493 + def retrieve_heredoc_info(tk); end + + class << self + # Returns +true+ if lex state will be +END+ after +token+. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#597 + def end?(token); end + + # Returns tokens parsed from +code+. + # + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#584 + def parse(code); end + end +end + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#20 +RDoc::Parser::RipperStateLex::EXPR_ARG = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#31 +RDoc::Parser::RipperStateLex::EXPR_ARG_ANY = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#16 +RDoc::Parser::RipperStateLex::EXPR_BEG = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#30 +RDoc::Parser::RipperStateLex::EXPR_BEG_ANY = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#25 +RDoc::Parser::RipperStateLex::EXPR_CLASS = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#21 +RDoc::Parser::RipperStateLex::EXPR_CMDARG = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#24 +RDoc::Parser::RipperStateLex::EXPR_DOT = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#17 +RDoc::Parser::RipperStateLex::EXPR_END = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#18 +RDoc::Parser::RipperStateLex::EXPR_ENDARG = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#19 +RDoc::Parser::RipperStateLex::EXPR_ENDFN = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#32 +RDoc::Parser::RipperStateLex::EXPR_END_ANY = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#28 +RDoc::Parser::RipperStateLex::EXPR_FITEM = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#23 +RDoc::Parser::RipperStateLex::EXPR_FNAME = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#26 +RDoc::Parser::RipperStateLex::EXPR_LABEL = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#27 +RDoc::Parser::RipperStateLex::EXPR_LABELED = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#22 +RDoc::Parser::RipperStateLex::EXPR_MID = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#15 +RDoc::Parser::RipperStateLex::EXPR_NONE = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#29 +RDoc::Parser::RipperStateLex::EXPR_VALUE = T.let(T.unsafe(nil), Integer) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#312 +class RDoc::Parser::RipperStateLex::InnerStateLex < ::Ripper::Filter + # @return [InnerStateLex] a new instance of InnerStateLex + # + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#313 + def initialize(code); end + + # source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#317 + def on_default(event, tok, data); end +end + +# TODO: Remove this constants after Ruby 2.4 EOL +# +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#11 +RDoc::Parser::RipperStateLex::RIPPER_HAS_LEX_STATE = T.let(T.unsafe(nil), TrueClass) + +# source://rdoc//lib/rdoc/parser/ripper_state_lex.rb#13 +class RDoc::Parser::RipperStateLex::Token < ::Struct + # Returns the value of attribute char_no + # + # @return [Object] the current value of char_no + def char_no; end + + # Sets the attribute char_no + # + # @param value [Object] the value to set the attribute char_no to. + # @return [Object] the newly set value + def char_no=(_); end + + # Returns the value of attribute kind + # + # @return [Object] the current value of kind + def kind; end + + # Sets the attribute kind + # + # @param value [Object] the value to set the attribute kind to. + # @return [Object] the newly set value + def kind=(_); end + + # Returns the value of attribute line_no + # + # @return [Object] the current value of line_no + def line_no; end + + # Sets the attribute line_no + # + # @param value [Object] the value to set the attribute line_no to. + # @return [Object] the newly set value + def line_no=(_); end + + # Returns the value of attribute state + # + # @return [Object] the current value of state + def state; end + + # Sets the attribute state + # + # @param value [Object] the value to set the attribute state to. + # @return [Object] the newly set value + def state=(_); end + + # Returns the value of attribute text + # + # @return [Object] the current value of text + def text; end + + # Sets the attribute text + # + # @param value [Object] the value to set the attribute text to. + # @return [Object] the newly set value + def text=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# Extracts code elements from a source file returning a TopLevel object +# containing the constituent file elements. +# +# This file is based on rtags +# +# RubyParser understands how to document: +# * classes +# * modules +# * methods +# * constants +# * aliases +# * private, public, protected +# * private_class_function, public_class_function +# * private_constant, public_constant +# * module_function +# * attr, attr_reader, attr_writer, attr_accessor +# * extra accessors given on the command line +# * metaprogrammed methods +# * require +# * include +# +# == Method Arguments +# +# -- +# NOTE: I don't think this works, needs tests, remove the paragraph following +# this block when known to work +# +# The parser extracts the arguments from the method definition. You can +# override this with a custom argument definition using the :args: directive: +# +# ## +# # This method tries over and over until it is tired +# +# def go_go_go(thing_to_try, tries = 10) # :args: thing_to_try +# puts thing_to_try +# go_go_go thing_to_try, tries - 1 +# end +# +# If you have a more-complex set of overrides you can use the :call-seq: +# directive: +# ++ +# +# The parser extracts the arguments from the method definition. You can +# override this with a custom argument definition using the :call-seq: +# directive: +# +# ## +# # This method can be called with a range or an offset and length +# # +# # :call-seq: +# # my_method(Range) +# # my_method(offset, length) +# +# def my_method(*args) +# end +# +# The parser extracts +yield+ expressions from method bodies to gather the +# yielded argument names. If your method manually calls a block instead of +# yielding or you want to override the discovered argument names use +# the :yields: directive: +# +# ## +# # My method is awesome +# +# def my_method(&block) # :yields: happy, times +# block.call 1, 2 +# end +# +# == Metaprogrammed Methods +# +# To pick up a metaprogrammed method, the parser looks for a comment starting +# with '##' before an identifier: +# +# ## +# # This is a meta-programmed method! +# +# add_my_method :meta_method, :arg1, :arg2 +# +# The parser looks at the token after the identifier to determine the name, in +# this example, :meta_method. If a name cannot be found, a warning is printed +# and 'unknown is used. +# +# You can force the name of a method using the :method: directive: +# +# ## +# # :method: some_method! +# +# By default, meta-methods are instance methods. To indicate that a method is +# a singleton method instead use the :singleton-method: directive: +# +# ## +# # :singleton-method: +# +# You can also use the :singleton-method: directive with a name: +# +# ## +# # :singleton-method: some_method! +# +# You can define arguments for metaprogrammed methods via either the +# :call-seq:, :arg: or :args: directives. +# +# Additionally you can mark a method as an attribute by +# using :attr:, :attr_reader:, :attr_writer: or :attr_accessor:. Just like +# for :method:, the name is optional. +# +# ## +# # :attr_reader: my_attr_name +# +# == Hidden methods and attributes +# +# You can provide documentation for methods that don't appear using +# the :method:, :singleton-method: and :attr: directives: +# +# ## +# # :attr_writer: ghost_writer +# # There is an attribute here, but you can't see it! +# +# ## +# # :method: ghost_method +# # There is a method here, but you can't see it! +# +# ## +# # this is a comment for a regular method +# +# def regular_method() end +# +# Note that by default, the :method: directive will be ignored if there is a +# standard rdocable item following it. +# +# source://rdoc//lib/rdoc/parser/ruby.rb#144 +class RDoc::Parser::Ruby < ::RDoc::Parser + include ::RDoc::TokenStream + include ::RDoc::Parser::RubyTools + + # Creates a new Ruby parser. + # + # @return [Ruby] a new instance of Ruby + # + # source://rdoc//lib/rdoc/parser/ruby.rb#164 + def initialize(top_level, file_name, content, options, stats); end + + # Look for the first comment in a file that isn't a shebang line. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#236 + def collect_first_comment; end + + # Consumes trailing whitespace from the token stream + # + # source://rdoc//lib/rdoc/parser/ruby.rb#279 + def consume_trailing_spaces; end + + # Creates a new attribute in +container+ with +name+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#286 + def create_attr(container, single, name, rw, comment); end + + # Creates a module alias in +container+ at +rhs_name+ (or at the top-level + # for "::") with the name from +constant+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#300 + def create_module_alias(container, constant, rhs_name); end + + # Aborts with +msg+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#313 + def error(msg); end + + # Looks for a true or false token. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#322 + def get_bool; end + + # Look for the name of a class of module (optionally with a leading :: or + # with :: separated named) and return the ultimate name, the associated + # container, and the given name (with the ::). + # + # source://rdoc//lib/rdoc/parser/ruby.rb#340 + def get_class_or_module(container, ignore_constants = T.unsafe(nil)); end + + # Return a superclass, which can be either a constant of an expression + # + # source://rdoc//lib/rdoc/parser/ruby.rb#423 + def get_class_specification; end + + # Parse a constant, which might be qualified by one or more class or module + # names + # + # source://rdoc//lib/rdoc/parser/ruby.rb#456 + def get_constant; end + + # Little hack going on here. In the statement: + # + # f = 2*(1+yield) + # + # We see the RPAREN as the next token, so we need to exit early. This still + # won't catch all cases (such as "a = yield + 1" + # + # source://rdoc//lib/rdoc/parser/ruby.rb#558 + def get_end_token(tk); end + + # Get an included module that may be surrounded by parens + # + # source://rdoc//lib/rdoc/parser/ruby.rb#473 + def get_included_module_with_optional_parens; end + + # Retrieves the method container for a singleton method. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#578 + def get_method_container(container, name_t); end + + # Extracts a name or symbol from the token stream. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#621 + def get_symbol_or_name; end + + # Retrieves the read token stream and replaces +pattern+ with +replacement+ + # using gsub. If the result is only a ";" returns an empty string. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#194 + def get_tkread_clean(pattern, replacement); end + + # Extracts the visibility information for the visibility token +tk+ + # and +single+ class type identifier. + # + # Returns the visibility type (a string), the visibility (a symbol) and + # +singleton+ if the methods following should be converted to singleton + # methods. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#208 + def get_visibility_information(tk, single); end + + # Look for directives in a normal comment block: + # + # # :stopdoc: + # # Don't display comment from this point forward + # + # This routine modifies its +comment+ parameter. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#661 + def look_for_directives_in(container, comment); end + + # Adds useful info about the parser to +message+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#681 + def make_message(message); end + + # Creates a comment with the correct format + # + # source://rdoc//lib/rdoc/parser/ruby.rb#693 + def new_comment(comment, line_no = T.unsafe(nil)); end + + # Parses an +alias+ in +context+ with +comment+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#762 + def parse_alias(context, single, tk, comment); end + + # Creates an RDoc::Attr for the name following +tk+, setting the comment to + # +comment+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#704 + def parse_attr(context, single, tk, comment); end + + # Creates an RDoc::Attr for each attribute listed after +tk+, setting the + # comment for each to +comment+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#733 + def parse_attr_accessor(context, single, tk, comment); end + + # Extracts call parameters from the token stream. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#803 + def parse_call_parameters(tk); end + + # Parses a class in +context+ with +comment+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#846 + def parse_class(container, single, tk, comment); end + + # Parses and creates a regular class + # + # source://rdoc//lib/rdoc/parser/ruby.rb#880 + def parse_class_regular(container, declaration_context, single, name_t, given_name, comment); end + + # Parses a singleton class in +container+ with the given +name+ and + # +comment+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#920 + def parse_class_singleton(container, name, comment); end + + # Generates an RDoc::Method or RDoc::Attr from +comment+ by looking for + # :method: or :attr: directives in +comment+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1085 + def parse_comment(container, tk, comment); end + + # Parse a comment that is describing an attribute in +container+ with the + # given +name+ and +comment+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1113 + def parse_comment_attr(container, type, name, comment); end + + # source://rdoc//lib/rdoc/parser/ruby.rb#1125 + def parse_comment_ghost(container, text, name, column, line_no, comment); end + + # Creates an RDoc::Method on +container+ from +comment+ if there is a + # Signature section in the comment + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1164 + def parse_comment_tomdoc(container, tk, comment); end + + # Parses a constant in +context+ with +comment+. If +ignore_constants+ is + # true, no found constants will be added to RDoc. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#959 + def parse_constant(container, tk, comment, ignore_constants = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/parser/ruby.rb#1026 + def parse_constant_body(container, constant, is_array_or_hash); end + + # Parses a Module#private_constant or Module#public_constant call from +tk+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2103 + def parse_constant_visibility(container, single, tk); end + + # Parses an +include+ or +extend+, indicated by the +klass+ and adds it to + # +container+ # with +comment+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1199 + def parse_extend_or_include(klass, container, comment); end + + # Parses identifiers that can create new methods or change visibility. + # + # Returns true if the comment was not consumed. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1237 + def parse_identifier(container, single, tk, comment); end + + # Parses an +included+ with a block feature of ActiveSupport::Concern. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1219 + def parse_included_with_activesupport_concern(container, comment); end + + # Parses a meta-programmed attribute and creates an RDoc::Attr. + # + # To create foo and bar attributes on class C with comment "My attributes": + # + # class C + # + # ## + # # :attr: + # # + # # My attributes + # + # my_attr :foo, :bar + # + # end + # + # To create a foo attribute on class C with comment "My attribute": + # + # class C + # + # ## + # # :attr: foo + # # + # # My attribute + # + # my_attr :foo, :bar + # + # end + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1301 + def parse_meta_attr(context, single, tk, comment); end + + # Parses a meta-programmed method + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1335 + def parse_meta_method(container, single, tk, comment); end + + # Parses the name of a metaprogrammed method. +comment+ is used to + # determine the name while +tk+ is used in an error message if the name + # cannot be determined. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1381 + def parse_meta_method_name(comment, tk); end + + # Parses the parameters and block for a meta-programmed method. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1405 + def parse_meta_method_params(container, single, meth, tk, comment); end + + # Parses a normal method defined by +def+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1437 + def parse_method(container, single, tk, comment); end + + # Parses a method that needs to be ignored. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1522 + def parse_method_dummy(container); end + + # Parses the name of a method in +container+. + # + # Returns the method name, the container it is in (for def Foo.name) and if + # it is a singleton or regular method. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1535 + def parse_method_name(container); end + + # For the given +container+ and initial name token +name_t+ the method name + # is parsed from the token stream for a regular method. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1562 + def parse_method_name_regular(container, name_t); end + + # For the given +container+ and initial name token +name_t+ the method name + # and the new +container+ (if necessary) are parsed from the token stream + # for a singleton method. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1580 + def parse_method_name_singleton(container, name_t); end + + # Extracts +yield+ parameters from +method+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1624 + def parse_method_or_yield_parameters(method = T.unsafe(nil), modifiers = T.unsafe(nil)); end + + # Capture the method's parameters. Along the way, look for a comment + # containing: + # + # # yields: .... + # + # and add this as the block_params for the method + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1691 + def parse_method_parameters(method); end + + # Parses the parameters and body of +meth+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1492 + def parse_method_params_and_body(container, single, meth, added_container); end + + # Parses an RDoc::NormalModule in +container+ with +comment+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1706 + def parse_module(container, single, tk, comment); end + + # Parses an RDoc::Require in +context+ containing +comment+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1728 + def parse_require(context, comment); end + + # Parses a rescue + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1749 + def parse_rescue; end + + # The core of the Ruby parser. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1780 + def parse_statements(container, single = T.unsafe(nil), current_method = T.unsafe(nil), comment = T.unsafe(nil)); end + + # Parse up to +no+ symbol arguments + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1971 + def parse_symbol_arg(no = T.unsafe(nil)); end + + # Parses up to +no+ symbol arguments surrounded by () and places them in + # +args+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1986 + def parse_symbol_arg_paren(no); end + + # Parses up to +no+ symbol arguments separated by spaces and places them in + # +args+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2014 + def parse_symbol_arg_space(no, tk); end + + # Returns symbol text from the next token + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2045 + def parse_symbol_in_arg; end + + # Parses statements in the top-level +container+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2062 + def parse_top_level_statements(container); end + + # Determines the visibility in +container+ from +tk+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2080 + def parse_visibility(container, single, tk); end + + # Determines the block parameter for +context+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2119 + def parse_yield(context, single, tk, method); end + + # Directives are modifier comments that can appear after class, module, or + # method names. For example: + # + # def fred # :yields: a, b + # + # or: + # + # + # We return the directive name and any parameters as a two element array if + # the name is in +allowed+. A directive can be found anywhere up to the end + # of the current line. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2140 + def read_directive(allowed); end + + # Handles directives following the definition for +context+ (any + # RDoc::CodeObject) if the directives are +allowed+ at this point. + # + # See also RDoc::Markup::PreProcess#handle_directive + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2172 + def read_documentation_modifiers(context, allowed); end + + # Records the location of this +container+ in the file for this parser and + # adds it to the list of classes and modules in the file. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2191 + def record_location(container); end + + # Retrieve comment body without =begin/=end + # + # source://rdoc//lib/rdoc/parser/ruby.rb#1769 + def retrieve_comment_body(tk); end + + # Scans this Ruby file for Ruby constructs + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2203 + def scan; end + + # skip the var [in] part of a 'for' statement + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2291 + def skip_for_variable; end + + # Skips the next method in +container+ + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2302 + def skip_method(container); end + + # while, until, and for have an optional do + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2250 + def skip_optional_do_after_expression; end + + # Skip opening parentheses and yield the block. + # Skip closing parentheses too when exists. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#401 + def skip_parentheses(&block); end + + # Skip spaces until a comment is found + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2311 + def skip_tkspace_comment(skip_nl = T.unsafe(nil)); end + + # Marks containers between +container+ and +ancestor+ as ignored + # + # source://rdoc//lib/rdoc/parser/ruby.rb#646 + def suppress_parents(container, ancestor); end + + # Return +true+ if +tk+ is a newline. + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/parser/ruby.rb#186 + def tk_nl?(tk); end + + # Updates visibility in +container+ from +vis_type+ and +vis+. + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2323 + def update_visibility(container, vis_type, vis, singleton); end + + # Prints +message+ to +$stderr+ unless we're being quiet + # + # source://rdoc//lib/rdoc/parser/ruby.rb#2368 + def warn(message); end +end + +# Collection of methods for writing parsers +# +# source://rdoc//lib/rdoc/parser/ruby_tools.rb#5 +module RDoc::Parser::RubyTools + # Adds a token listener +obj+, but you should probably use token_listener + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#10 + def add_token_listener(obj); end + + # Fetches the next token from the scanner + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#18 + def get_tk; end + + # Reads and returns all tokens up to one of +tokens+. Leaves the matched + # token in the token list. + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#52 + def get_tk_until(*tokens); end + + # Retrieves a String representation of the read tokens + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#73 + def get_tkread; end + + # Peek equivalent for get_tkread + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#82 + def peek_read; end + + # Peek at the next token, but don't remove it from the stream + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#89 + def peek_tk; end + + # Removes the token listener +obj+ + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#97 + def remove_token_listener(obj); end + + # Resets the tools + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#104 + def reset; end + + # Skips whitespace tokens including newlines + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#115 + def skip_tkspace; end + + # Skips whitespace tokens excluding newlines + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#129 + def skip_tkspace_without_nl; end + + # Has +obj+ listen to tokens + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#143 + def token_listener(obj); end + + # Returns +tk+ to the scanner + # + # source://rdoc//lib/rdoc/parser/ruby_tools.rb#153 + def unget_tk(tk); end +end + +# Parse a non-source file. We basically take the whole thing as one big +# comment. +# +# source://rdoc//lib/rdoc/parser/simple.rb#6 +class RDoc::Parser::Simple < ::RDoc::Parser + include ::RDoc::Parser::Text + + # Prepare to parse a plain file + # + # @return [Simple] a new instance of Simple + # + # source://rdoc//lib/rdoc/parser/simple.rb#17 + def initialize(top_level, file_name, content, options, stats); end + + # source://rdoc//lib/rdoc/parser/simple.rb#12 + def content; end + + # Removes the encoding magic comment from +text+ + # + # source://rdoc//lib/rdoc/parser/simple.rb#41 + def remove_coding_comment(text); end + + # Removes private comments. + # + # Unlike RDoc::Comment#remove_private this implementation only looks for two + # dashes at the beginning of the line. Three or more dashes are considered + # to be a rule and ignored. + # + # source://rdoc//lib/rdoc/parser/simple.rb#52 + def remove_private_comment(comment); end + + # Extract the file contents and attach them to the TopLevel as a comment + # + # source://rdoc//lib/rdoc/parser/simple.rb#28 + def scan; end +end + +# source://rdoc//lib/rdoc/rd.rb#72 +class RDoc::RD + class << self + # Parses +rd+ source and returns an RDoc::Markup::Document. If the + # =begin or =end lines are missing they will be added. + # + # source://rdoc//lib/rdoc/rd.rb#78 + def parse(rd); end + end +end + +# RD format parser for headings, paragraphs, lists, verbatim sections that +# exist as blocks. +# +# source://rdoc//lib/rdoc/rd/block_parser.rb#660 +class RDoc::RD::BlockParser < ::Racc::Parser + # Creates a new RDoc::RD::BlockParser. Use #parse to parse an rd-format + # document. + # + # @return [BlockParser] a new instance of BlockParser + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#695 + def initialize; end + + # reduce 0 omitted + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1330 + def _reduce_1(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1372 + def _reduce_10(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1377 + def _reduce_11(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1382 + def _reduce_12(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1390 + def _reduce_13(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1396 + def _reduce_14(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1403 + def _reduce_15(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1408 + def _reduce_16(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1413 + def _reduce_17(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1424 + def _reduce_18(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1435 + def _reduce_19(val, _values, result); end + + # @raise [ParseError] + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1335 + def _reduce_2(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1441 + def _reduce_20(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1447 + def _reduce_21(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1453 + def _reduce_22(val, _values, result); end + + # reduce 26 omitted + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1469 + def _reduce_27(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1475 + def _reduce_28(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1481 + def _reduce_29(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1340 + def _reduce_3(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1487 + def _reduce_30(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1492 + def _reduce_31(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1497 + def _reduce_32(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1503 + def _reduce_33(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1508 + def _reduce_34(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1513 + def _reduce_35(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1519 + def _reduce_36(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1525 + def _reduce_37(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1530 + def _reduce_38(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1535 + def _reduce_39(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1345 + def _reduce_4(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1541 + def _reduce_40(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1547 + def _reduce_41(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1552 + def _reduce_42(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1557 + def _reduce_43(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1565 + def _reduce_44(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1571 + def _reduce_45(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1576 + def _reduce_46(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1581 + def _reduce_47(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1587 + def _reduce_48(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1593 + def _reduce_49(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1350 + def _reduce_5(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1599 + def _reduce_50(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1605 + def _reduce_51(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1611 + def _reduce_52(val, _values, result); end + + # reduce 53 omitted + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1618 + def _reduce_54(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1623 + def _reduce_55(val, _values, result); end + + # reduce 56 omitted + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1630 + def _reduce_57(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1355 + def _reduce_6(val, _values, result); end + + # reduce 61 omitted + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1643 + def _reduce_62(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1649 + def _reduce_63(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1655 + def _reduce_64(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1661 + def _reduce_65(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1667 + def _reduce_66(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1673 + def _reduce_67(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1678 + def _reduce_68(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1683 + def _reduce_69(val, _values, result); end + + # reduce 70 omitted + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1690 + def _reduce_71(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1695 + def _reduce_72(val, _values, result); end + + # reduce 7 omitted + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1362 + def _reduce_8(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1367 + def _reduce_9(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#1700 + def _reduce_none(val, _values, result); end + + # Adds footnote +content+ to the document + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1045 + def add_footnote(content); end + + # Adds label +label+ to the document + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1059 + def add_label(label); end + + # Retrieves the content of +values+ as a single String + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1028 + def content(values); end + + # Footnotes for this document + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#679 + def footnotes; end + + # Path to find included files in + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#689 + def include_path; end + + # Path to find included files in + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#689 + def include_path=(_arg0); end + + # Labels for items in this document + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#684 + def labels; end + + # Current line number + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#983 + def line_index; end + + # Returns the next token from the document + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#751 + def next_token; end + + # Raises a ParseError when invalid formatting is found + # + # @raise [ParseError] + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#967 + def on_error(et, ev, _values); end + + # Creates a paragraph for +value+ + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1035 + def paragraph(value); end + + # Parses +src+ and returns an RDoc::Markup::Document. + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#707 + def parse(src); end + + private + + # Cuts off excess whitespace in +src+ + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#931 + def cut_off(src); end + + # Formats line numbers +line_numbers+ prettily + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1019 + def format_line_num(*line_numbers); end + + # Retrieves the content for +file+ from the include_path + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#1000 + def get_included(file); end + + # Yields to the given block if +indent+ matches the current indent, otherwise + # an indentation token is processed. + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#913 + def if_current_indent_equal(indent); end + + # Parses subtree +src+ + # + # source://rdoc//lib/rdoc/rd/block_parser.rb#990 + def parse_subtree(src); end + + # source://rdoc//lib/rdoc/rd/block_parser.rb#958 + def set_term_to_element(parent, term); end +end + +# source://rdoc//lib/rdoc/rd/block_parser.rb#1324 +RDoc::RD::BlockParser::Racc_debug_parser = T.let(T.unsafe(nil), FalseClass) + +# Inline keeps track of markup and labels to create proper links. +# +# source://rdoc//lib/rdoc/rd/inline.rb#5 +class RDoc::RD::Inline + # Initializes the Inline with +rdoc+ and +inline+ + # + # @return [Inline] a new instance of Inline + # + # source://rdoc//lib/rdoc/rd/inline.rb#34 + def initialize(rdoc, reference); end + + # source://rdoc//lib/rdoc/rd/inline.rb#42 + def ==(other); end + + # Appends +more+ to this inline. +more+ may be a String or another Inline. + # + # source://rdoc//lib/rdoc/rd/inline.rb#50 + def append(more); end + + # source://rdoc//lib/rdoc/rd/inline.rb#65 + def inspect; end + + # The markup of this reference in RDoc format + # + # source://rdoc//lib/rdoc/rd/inline.rb#15 + def rdoc; end + + # The text of the reference + # + # source://rdoc//lib/rdoc/rd/inline.rb#10 + def reference; end + + # The markup of this reference in RDoc format + # + # source://rdoc//lib/rdoc/rd/inline.rb#15 + def to_s; end + + class << self + # Creates a new Inline for +rdoc+ and +reference+. + # + # +rdoc+ may be another Inline or a String. If +reference+ is not given it + # will use the text from +rdoc+. + # + # source://rdoc//lib/rdoc/rd/inline.rb#23 + def new(rdoc, reference = T.unsafe(nil)); end + end +end + +# RD format parser for inline markup such as emphasis, links, footnotes, etc. +# +# source://rdoc//lib/rdoc/rd/inline_parser.rb#661 +class RDoc::RD::InlineParser < ::Racc::Parser + # Creates a new parser for inline markup in the rd format. The +block_parser+ + # is used to for footnotes and labels in the inline text. + # + # @return [InlineParser] a new instance of InlineParser + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#734 + def initialize(block_parser); end + + # reduce 100 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1746 + def _reduce_101(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1753 + def _reduce_102(val, _values, result); end + + # reduce 108 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1771 + def _reduce_109(val, _values, result); end + + # reduce 110 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1778 + def _reduce_111(val, _values, result); end + + # reduce 112 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1786 + def _reduce_113(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1791 + def _reduce_114(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1796 + def _reduce_115(val, _values, result); end + + # reduce 12 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1409 + def _reduce_13(val, _values, result); end + + # reduce 135 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1841 + def _reduce_136(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1416 + def _reduce_14(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1423 + def _reduce_15(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1430 + def _reduce_16(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1437 + def _reduce_17(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1445 + def _reduce_18(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1451 + def _reduce_19(val, _values, result); end + + # reduce 1 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1381 + def _reduce_2(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1459 + def _reduce_20(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1465 + def _reduce_21(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1474 + def _reduce_22(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1480 + def _reduce_23(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1486 + def _reduce_24(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1492 + def _reduce_25(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1501 + def _reduce_26(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1507 + def _reduce_27(val, _values, result); end + + # reduce 28 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1516 + def _reduce_29(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1386 + def _reduce_3(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1521 + def _reduce_30(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1526 + def _reduce_31(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1532 + def _reduce_32(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1538 + def _reduce_33(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1544 + def _reduce_34(val, _values, result); end + + # reduce 35 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1552 + def _reduce_36(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1557 + def _reduce_37(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1562 + def _reduce_38(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1568 + def _reduce_39(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1574 + def _reduce_40(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1580 + def _reduce_41(val, _values, result); end + + # reduce 42 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1588 + def _reduce_43(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1594 + def _reduce_44(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1600 + def _reduce_45(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1606 + def _reduce_46(val, _values, result); end + + # reduce 56 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1632 + def _reduce_57(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1638 + def _reduce_58(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1644 + def _reduce_59(val, _values, result); end + + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1650 + def _reduce_60(val, _values, result); end + + # reduce 61 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1657 + def _reduce_62(val, _values, result); end + + # reduce 63 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1665 + def _reduce_64(val, _values, result); end + + # reduce 77 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1697 + def _reduce_78(val, _values, result); end + + # reduce 137 omitted + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#1848 + def _reduce_none(val, _values, result); end + + # Creates a new RDoc::RD::Inline for the +rdoc+ markup and the raw +reference+ + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#883 + def inline(rdoc, reference = T.unsafe(nil)); end + + # Returns the next token from the inline text + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#752 + def next_token; end + + # Returns words following an error + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#872 + def next_words_on_error; end + + # Raises a ParseError when invalid formatting is found + # + # @raise [ParseError] + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#832 + def on_error(et, ev, values); end + + # Parses the +inline+ text from RD format into RDoc format. + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#741 + def parse(inline); end + + # Returns words before the error + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#849 + def prev_words_on_error(ev); end + + private + + # Returns the last line of +src+ + # + # source://rdoc//lib/rdoc/rd/inline_parser.rb#860 + def last_line(src); end +end + +# source://rdoc//lib/rdoc/rd/inline_parser.rb#1373 +RDoc::RD::InlineParser::Racc_debug_parser = T.let(T.unsafe(nil), FalseClass) + +# This is the driver for generating RDoc output. It handles file parsing and +# generation of output. +# +# To use this class to generate RDoc output via the API, the recommended way +# is: +# +# rdoc = RDoc::RDoc.new +# options = RDoc::Options.load_options # returns an RDoc::Options instance +# # set extra options +# rdoc.document options +# +# You can also generate output like the +rdoc+ executable: +# +# rdoc = RDoc::RDoc.new +# rdoc.document argv +# +# Where +argv+ is an array of strings, each corresponding to an argument you'd +# give rdoc on the command line. See rdoc --help for details. +# +# source://rdoc//lib/rdoc/rdoc.rb#29 +class RDoc::RDoc + # Creates a new RDoc::RDoc instance. Call #document to parse files and + # generate documentation. + # + # @return [RDoc] a new instance of RDoc + # + # source://rdoc//lib/rdoc/rdoc.rb#100 + def initialize; end + + # Generates documentation or a coverage report depending upon the settings + # in +options+. + # + # +options+ can be either an RDoc::Options instance or an array of strings + # equivalent to the strings that would be passed on the command line like + # %w[-q -o doc -t My\ Doc\ Title]. #document will automatically + # call RDoc::Options#finish if an options instance was given. + # + # For a list of options, see either RDoc::Options or rdoc --help. + # + # By default, output will be stored in a directory called "doc" below the + # current directory, so make sure you're somewhere writable before invoking. + # + # source://rdoc//lib/rdoc/rdoc.rb#450 + def document(options); end + + # Report an error message and exit + # + # @raise [RDoc::Error] + # + # source://rdoc//lib/rdoc/rdoc.rb#113 + def error(msg); end + + # Gathers a set of parseable files from the files and directories listed in + # +files+. + # + # source://rdoc//lib/rdoc/rdoc.rb#121 + def gather_files(files); end + + # Generates documentation for +file_info+ (from #parse_files) into the + # output dir using the generator selected + # by the RDoc options + # + # source://rdoc//lib/rdoc/rdoc.rb#515 + def generate; end + + # Generator instance used for creating output + # + # source://rdoc//lib/rdoc/rdoc.rb#52 + def generator; end + + # Generator instance used for creating output + # + # source://rdoc//lib/rdoc/rdoc.rb#52 + def generator=(_arg0); end + + # Turns RDoc from stdin into HTML + # + # source://rdoc//lib/rdoc/rdoc.rb#142 + def handle_pipe; end + + # Installs a siginfo handler that prints the current filename. + # + # source://rdoc//lib/rdoc/rdoc.rb#157 + def install_siginfo_handler; end + + # Hash of files and their last modified times. + # + # source://rdoc//lib/rdoc/rdoc.rb#57 + def last_modified; end + + # Return a list of the files to be processed in a directory. We know that + # this directory doesn't have a .document file, so we're looking for real + # files. However we may well contain subdirectories which must be tested + # for .document files. + # + # source://rdoc//lib/rdoc/rdoc.rb#323 + def list_files_in_directory(dir); end + + # Given a list of files and directories, create a list of all the Ruby + # files they contain. + # + # If +force_doc+ is true we always add the given files, if false, only + # add files that we guarantee we can parse. It is true when looking at + # files given on the command line, false when recursing through + # subdirectories. + # + # The effect of this is that if you want a file with a non-standard + # extension parsed, you must name it explicitly. + # + # source://rdoc//lib/rdoc/rdoc.rb#275 + def normalized_file_list(relative_files, force_doc = T.unsafe(nil), exclude_pattern = T.unsafe(nil)); end + + # RDoc options + # + # source://rdoc//lib/rdoc/rdoc.rb#62 + def options; end + + # RDoc options + # + # source://rdoc//lib/rdoc/rdoc.rb#62 + def options=(_arg0); end + + # Return the path name of the flag file in an output directory. + # + # source://rdoc//lib/rdoc/rdoc.rb#240 + def output_flag_file(op_dir); end + + # The .document file contains a list of file and directory name patterns, + # representing candidates for documentation. It may also contain comments + # (starting with '#') + # + # source://rdoc//lib/rdoc/rdoc.rb#249 + def parse_dot_doc_file(in_dir, filename); end + + # Parses +filename+ and returns an RDoc::TopLevel + # + # source://rdoc//lib/rdoc/rdoc.rb#332 + def parse_file(filename); end + + # Parse each file on the command line, recursively entering directories. + # + # source://rdoc//lib/rdoc/rdoc.rb#404 + def parse_files(files); end + + # Removes a siginfo handler and replaces the previous + # + # source://rdoc//lib/rdoc/rdoc.rb#534 + def remove_siginfo_handler; end + + # Removes file extensions known to be unparseable from +files+ and TAGS + # files for emacs and vim. + # + # source://rdoc//lib/rdoc/rdoc.rb#428 + def remove_unparseable(files); end + + # Create an output dir if it doesn't exist. If it does exist, but doesn't + # contain the flag file created.rid then we refuse to use it, as + # we may clobber some manually generated documentation + # + # source://rdoc//lib/rdoc/rdoc.rb#170 + def setup_output_dir(dir, force); end + + # Accessor for statistics. Available after each call to parse_files + # + # source://rdoc//lib/rdoc/rdoc.rb#67 + def stats; end + + # The current documentation store + # + # source://rdoc//lib/rdoc/rdoc.rb#72 + def store; end + + # Sets the current documentation tree to +store+ and sets the store's rdoc + # driver to this instance. + # + # source://rdoc//lib/rdoc/rdoc.rb#215 + def store=(store); end + + # Update the flag file in an output directory. + # + # source://rdoc//lib/rdoc/rdoc.rb#223 + def update_output_dir(op_dir, time, last = T.unsafe(nil)); end + + class << self + # Add +klass+ that can generate output after parsing + # + # source://rdoc//lib/rdoc/rdoc.rb#77 + def add_generator(klass); end + + # Active RDoc::RDoc instance + # + # source://rdoc//lib/rdoc/rdoc.rb#85 + def current; end + + # Sets the active RDoc::RDoc instance + # + # source://rdoc//lib/rdoc/rdoc.rb#92 + def current=(rdoc); end + end +end + +# List of directory names skipped if test suites should be skipped +# +# source://rdoc//lib/rdoc/rdoc.rb#46 +RDoc::RDoc::TEST_SUITE_DIRECTORY_NAMES = T.let(T.unsafe(nil), Array) + +# List of directory names always skipped +# +# source://rdoc//lib/rdoc/rdoc.rb#41 +RDoc::RDoc::UNCONDITIONALLY_SKIPPED_DIRECTORIES = T.let(T.unsafe(nil), Array) + +# The RI driver implements the command-line ri tool. +# +# The driver supports: +# * loading RI data from: +# * Ruby's standard library +# * RubyGems +# * ~/.rdoc +# * A user-supplied directory +# * Paging output (uses RI_PAGER environment variable, PAGER environment +# variable or the less, more and pager programs) +# * Interactive mode with tab-completion +# * Abbreviated names (ri Zl shows Zlib documentation) +# * Colorized output +# * Merging output from multiple RI data sources +# +# source://rdoc//lib/rdoc/ri/driver.rb#25 +class RDoc::RI::Driver + # Creates a new driver using +initial_options+ from ::process_args + # + # @return [Driver] a new instance of Driver + # + # source://rdoc//lib/rdoc/ri/driver.rb#391 + def initialize(initial_options = T.unsafe(nil)); end + + # Adds paths for undocumented classes +also_in+ to +out+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#429 + def add_also_in(out, also_in); end + + # Adds a class header to +out+ for class +name+ which is described in + # +classes+. + # + # source://rdoc//lib/rdoc/ri/driver.rb#446 + def add_class(out, name, classes); end + + # Adds +extends+ to +out+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#473 + def add_extends(out, extends); end + + # Adds a list of +extensions+ to this module of the given +type+ to +out+. + # add_includes and add_extends call this, so you should use those directly. + # + # source://rdoc//lib/rdoc/ri/driver.rb#481 + def add_extension_modules(out, type, extensions); end + + # Renders multiple included +modules+ from +store+ to +out+. + # + # source://rdoc//lib/rdoc/ri/driver.rb#499 + def add_extension_modules_multiple(out, store, modules); end + + # Adds a single extension module +include+ from +store+ to +out+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#526 + def add_extension_modules_single(out, store, include); end + + # Adds "(from ...)" to +out+ for +store+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#466 + def add_from(out, store); end + + # Adds +includes+ to +out+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#540 + def add_includes(out, includes); end + + # Looks up the method +name+ and adds it to +out+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#547 + def add_method(out, name); end + + # Adds documentation for all methods in +klass+ to +out+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#558 + def add_method_documentation(out, klass); end + + # Adds a list of +methods+ to +out+ with a heading of +name+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#571 + def add_method_list(out, methods, name); end + + # Returns ancestor classes of +klass+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#591 + def ancestors_of(klass); end + + # source://rdoc//lib/rdoc/ri/driver.rb#926 + def check_did_you_mean; end + + # For RubyGems backwards compatibility + # + # source://rdoc//lib/rdoc/ri/driver.rb#622 + def class_cache; end + + # Builds a RDoc::Markup::Document from +found+, +klasess+ and +includes+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#628 + def class_document(name, found, klasses, includes, extends); end + + # Adds the class +comment+ to +out+. + # + # source://rdoc//lib/rdoc/ri/driver.rb#650 + def class_document_comment(out, comment); end + + # Adds the constants from +klass+ to the Document +out+. + # + # source://rdoc//lib/rdoc/ri/driver.rb#670 + def class_document_constants(out, klass); end + + # Hash mapping a known class or module to the stores it can be loaded from + # + # source://rdoc//lib/rdoc/ri/driver.rb#694 + def classes; end + + # Returns the stores wherein +name+ is found along with the classes, + # extends and includes that match it + # + # source://rdoc//lib/rdoc/ri/driver.rb#714 + def classes_and_includes_and_extends_for(name); end + + # Completes +name+ based on the caches. For Readline + # + # source://rdoc//lib/rdoc/ri/driver.rb#739 + def complete(name); end + + # source://rdoc//lib/rdoc/ri/driver.rb#750 + def complete_klass(name, klass, selector, method, completions); end + + # source://rdoc//lib/rdoc/ri/driver.rb#769 + def complete_method(name, klass, selector, completions); end + + # Converts +document+ to text and writes it to the pager + # + # source://rdoc//lib/rdoc/ri/driver.rb#789 + def display(document); end + + # Outputs formatted RI data for class +name+. Groups undocumented classes + # + # source://rdoc//lib/rdoc/ri/driver.rb#802 + def display_class(name); end + + # Outputs formatted RI data for method +name+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#818 + def display_method(name); end + + # Outputs formatted RI data for the class or method +name+. + # + # Returns true if +name+ was found, false if it was not an alternative could + # be guessed, raises an error if +name+ couldn't be guessed. + # + # source://rdoc//lib/rdoc/ri/driver.rb#832 + def display_name(name); end + + # Displays each name in +name+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#861 + def display_names(names); end + + # Outputs formatted RI data for page +name+. + # + # source://rdoc//lib/rdoc/ri/driver.rb#872 + def display_page(name); end + + # Outputs a formatted RI page list for the pages in +store+. + # + # source://rdoc//lib/rdoc/ri/driver.rb#903 + def display_page_list(store, pages = T.unsafe(nil), search = T.unsafe(nil)); end + + # Expands abbreviated klass +klass+ into a fully-qualified class. "Zl::Da" + # will be expanded to Zlib::DataError. + # + # source://rdoc//lib/rdoc/ri/driver.rb#947 + def expand_class(klass); end + + # Expands the class portion of +name+ into a fully-qualified class. See + # #expand_class. + # + # source://rdoc//lib/rdoc/ri/driver.rb#965 + def expand_name(name); end + + # Filters the methods in +found+ trying to find a match for +name+. + # + # source://rdoc//lib/rdoc/ri/driver.rb#981 + def filter_methods(found, name); end + + # Yields items matching +name+ including the store they were found in, the + # class being searched for, the class they were found in (an ancestor) the + # types of methods to look up (from #method_type), and the method name being + # searched for + # + # source://rdoc//lib/rdoc/ri/driver.rb#999 + def find_methods(name); end + + # Finds a store that matches +name+ which can be the name of a gem, "ruby", + # "home" or "site". + # + # See also RDoc::Store#source + # + # @raise [RDoc::RI::Driver::NotFoundError] + # + # source://rdoc//lib/rdoc/ri/driver.rb#1045 + def find_store(name); end + + # Creates a new RDoc::Markup::Formatter. If a formatter is given with -f, + # use it. If we're outputting to a pager, use bs, otherwise ansi. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1062 + def formatter(io); end + + # Runs ri interactively using Readline if it is available. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1075 + def interactive; end + + # Lists classes known to ri starting with +names+. If +names+ is empty all + # known classes are shown. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1114 + def list_known_classes(names = T.unsafe(nil)); end + + # Returns an Array of methods matching +name+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#1146 + def list_methods_matching(name); end + + # Loads RI data for method +name+ on +klass+ from +store+. +type+ and + # +cache+ indicate if it is a class or instance method. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1185 + def load_method(store, cache, klass, type, name); end + + # Returns an Array of RI data for methods matching +name+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#1208 + def load_methods_matching(name); end + + # Returns a filtered list of methods matching +name+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#1229 + def lookup_method(name); end + + # Builds a RDoc::Markup::Document from +found+, +klasses+ and +includes+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#1254 + def method_document(name, filtered); end + + # Returns the type of method (:both, :instance, :class) for +selector+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#1272 + def method_type(selector); end + + # Returns a regular expression for +name+ that will match an + # RDoc::AnyMethod's name. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1284 + def name_regexp(name); end + + # Paginates output through a pager program. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1298 + def page; end + + # Are we using a pager? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/ri/driver.rb#1316 + def paging?; end + + # Extracts the class, selector and method name parts from +name+ like + # Foo::Bar#baz. + # + # NOTE: Given Foo::Bar, Bar is considered a class even though it may be a + # method + # + # source://rdoc//lib/rdoc/ri/driver.rb#1327 + def parse_name(name); end + + # Renders the +klass+ from +store+ to +out+. If the klass has no + # documentable items the class is added to +also_in+ instead. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1359 + def render_class(out, store, klass, also_in); end + + # source://rdoc//lib/rdoc/ri/driver.rb#1389 + def render_method(out, store, method, name); end + + # source://rdoc//lib/rdoc/ri/driver.rb#1409 + def render_method_arguments(out, arglists); end + + # source://rdoc//lib/rdoc/ri/driver.rb#1418 + def render_method_comment(out, method, alias_for = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/ri/driver.rb#1436 + def render_method_superclass(out, method); end + + # Looks up and displays ri data according to the options given. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1448 + def run; end + + # Sets up a pager program to pass output through. Tries the RI_PAGER and + # PAGER environment variables followed by pager, less then more. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1468 + def setup_pager; end + + # Show all method documentation following a class or module + # + # source://rdoc//lib/rdoc/ri/driver.rb#62 + def show_all; end + + # Show all method documentation following a class or module + # + # source://rdoc//lib/rdoc/ri/driver.rb#62 + def show_all=(_arg0); end + + # Starts a WEBrick server for ri. + # + # source://rdoc//lib/rdoc/ri/driver.rb#1494 + def start_server; end + + # An RDoc::RI::Store for each entry in the RI path + # + # source://rdoc//lib/rdoc/ri/driver.rb#67 + def stores; end + + # An RDoc::RI::Store for each entry in the RI path + # + # source://rdoc//lib/rdoc/ri/driver.rb#67 + def stores=(_arg0); end + + # Controls the user of the pager vs $stdout + # + # source://rdoc//lib/rdoc/ri/driver.rb#72 + def use_stdout; end + + # Controls the user of the pager vs $stdout + # + # source://rdoc//lib/rdoc/ri/driver.rb#72 + def use_stdout=(_arg0); end + + class << self + # Default options for ri + # + # source://rdoc//lib/rdoc/ri/driver.rb#77 + def default_options; end + + # Dump +data_path+ using pp + # + # source://rdoc//lib/rdoc/ri/driver.rb#98 + def dump(data_path); end + + # Parses +argv+ and returns a Hash of options + # + # source://rdoc//lib/rdoc/ri/driver.rb#109 + def process_args(argv); end + + # Runs the ri command line executable using +argv+ + # + # source://rdoc//lib/rdoc/ri/driver.rb#376 + def run(argv = T.unsafe(nil)); end + end +end + +# Raised when a name isn't found in the ri data stores +# +# source://rdoc//lib/rdoc/ri/driver.rb#35 +class RDoc::RI::Driver::NotFoundError < ::RDoc::RI::Driver::Error + # @return [NotFoundError] a new instance of NotFoundError + # + # source://rdoc//lib/rdoc/ri/driver.rb#37 + def initialize(klass, suggestion_proc = T.unsafe(nil)); end + + # source://rdoc//lib/rdoc/ri/driver.rb#49 + def message; end + + # Name that wasn't found + # + # source://rdoc//lib/rdoc/ri/driver.rb#45 + def name; end +end + +# For RubyGems backwards compatibility +# +# source://rdoc//lib/rdoc/ri/formatter.rb#5 +module RDoc::RI::Formatter; end + +# source://rdoc//lib/rdoc/ri/store.rb#4 +RDoc::RI::Store = RDoc::Store + +# A file loaded by \#require +# +# source://rdoc//lib/rdoc/require.rb#5 +class RDoc::Require < ::RDoc::CodeObject + # Creates a new Require that loads +name+ with +comment+ + # + # @return [Require] a new instance of Require + # + # source://rdoc//lib/rdoc/require.rb#15 + def initialize(name, comment); end + + # source://rdoc//lib/rdoc/require.rb#22 + def inspect; end + + # Name of the required file + # + # source://rdoc//lib/rdoc/require.rb#10 + def name; end + + # Name of the required file + # + # source://rdoc//lib/rdoc/require.rb#10 + def name=(_arg0); end + + # source://rdoc//lib/rdoc/require.rb#31 + def to_s; end + + # The RDoc::TopLevel corresponding to this require, or +nil+ if not found. + # + # source://rdoc//lib/rdoc/require.rb#38 + def top_level; end +end + +# This is a WEBrick servlet that allows you to browse ri documentation. +# +# You can show documentation through either `ri --server` or, with RubyGems +# 2.0 or newer, `gem server`. For ri, the server runs on port 8214 by +# default. For RubyGems the server runs on port 8808 by default. +# +# You can use this servlet in your own project by mounting it on a WEBrick +# server: +# +# require 'webrick' +# +# server = WEBrick::HTTPServer.new Port: 8000 +# +# server.mount '/', RDoc::Servlet +# +# If you want to mount the servlet some other place than the root, provide the +# base path when mounting: +# +# server.mount '/rdoc', RDoc::Servlet, '/rdoc' +# +# source://rdoc//lib/rdoc/servlet.rb#34 +class RDoc::Servlet < ::WEBrick::HTTPServlet::AbstractServlet + # Creates a new WEBrick servlet. + # + # Use +mount_path+ when mounting the servlet somewhere other than /. + # + # Use +extra_doc_dirs+ for additional documentation directories. + # + # +server+ is provided automatically by WEBrick when mounting. +stores+ and + # +cache+ are provided automatically by the servlet. + # + # @return [Servlet] a new instance of Servlet + # + # source://rdoc//lib/rdoc/servlet.rb#69 + def initialize(server, stores, cache, mount_path = T.unsafe(nil), extra_doc_dirs = T.unsafe(nil)); end + + # Serves the asset at the path in +req+ for +generator_name+ via +res+. + # + # source://rdoc//lib/rdoc/servlet.rb#100 + def asset(generator_name, req, res); end + + # Maps an asset type to its path on the filesystem + # + # source://rdoc//lib/rdoc/servlet.rb#42 + def asset_dirs; end + + # GET request entry point. Fills in +res+ for the path, etc. in +req+. + # + # source://rdoc//lib/rdoc/servlet.rb#119 + def do_GET(req, res); end + + # Fills in +res+ with the class, module or page for +req+ from +store+. + # + # +path+ is relative to the mount_path and is used to determine the class, + # module or page name (/RDoc/Servlet.html becomes RDoc::Servlet). + # +generator+ is used to create the page. + # + # source://rdoc//lib/rdoc/servlet.rb#152 + def documentation_page(store, generator, path, req, res); end + + # Creates the JSON search index on +res+ for the given +store+. +generator+ + # must respond to \#json_index to build. +req+ is ignored. + # + # source://rdoc//lib/rdoc/servlet.rb#171 + def documentation_search(store, generator, req, res); end + + # Returns the RDoc::Store and path relative to +mount_path+ for + # documentation at +path+. + # + # source://rdoc//lib/rdoc/servlet.rb#185 + def documentation_source(path); end + + # Generates an error page for the +exception+ while handling +req+ on +res+. + # + # source://rdoc//lib/rdoc/servlet.rb#203 + def error(exception, req, res); end + + # Instantiates a Darkfish generator for +store+ + # + # source://rdoc//lib/rdoc/servlet.rb#246 + def generator_for(store); end + + # Handles the If-Modified-Since HTTP header on +req+ for +path+. If the + # file has not been modified a Not Modified response is returned. If the + # file has been modified a Last-Modified header is added to +res+. + # + # source://rdoc//lib/rdoc/servlet.rb#267 + def if_modified_since(req, res, path = T.unsafe(nil)); end + + # Returns an Array of installed documentation. + # + # Each entry contains the documentation name (gem name, 'Ruby + # Documentation', etc.), the path relative to the mount point, whether the + # documentation exists, the type of documentation (See RDoc::RI::Paths#each) + # and the filesystem to the RDoc::Store for the documentation. + # + # source://rdoc//lib/rdoc/servlet.rb#290 + def installed_docs; end + + # Returns a 404 page built by +generator+ for +req+ on +res+. + # + # source://rdoc//lib/rdoc/servlet.rb#318 + def not_found(generator, req, res, message = T.unsafe(nil)); end + + # An RDoc::Options instance used for rendering options + # + # source://rdoc//lib/rdoc/servlet.rb#47 + def options; end + + # Enumerates the ri paths. See RDoc::RI::Paths#each + # + # source://rdoc//lib/rdoc/servlet.rb#327 + def ri_paths(&block); end + + # Generates the root page on +res+. +req+ is ignored. + # + # source://rdoc//lib/rdoc/servlet.rb#334 + def root(req, res); end + + # Generates a search index for the root page on +res+. +req+ is ignored. + # + # source://rdoc//lib/rdoc/servlet.rb#345 + def root_search(req, res); end + + # Displays documentation for +req+ on +res+, whether that be HTML or some + # asset. + # + # source://rdoc//lib/rdoc/servlet.rb#395 + def show_documentation(req, res); end + + # Returns an RDoc::Store for the given +source_name+ ('ruby' or a gem name). + # + # source://rdoc//lib/rdoc/servlet.rb#419 + def store_for(source_name); end + + class << self + # Creates an instance of this servlet that shares cached data between + # requests. + # + # source://rdoc//lib/rdoc/servlet.rb#53 + def get_instance(server, *options); end + end +end + +# A singleton class +# +# source://rdoc//lib/rdoc/single_class.rb#5 +class RDoc::SingleClass < ::RDoc::ClassModule + # Adds the superclass to the included modules. + # + # source://rdoc//lib/rdoc/single_class.rb#10 + def ancestors; end + + # source://rdoc//lib/rdoc/single_class.rb#14 + def aref_prefix; end + + # The definition of this singleton class, class << MyClassName + # + # source://rdoc//lib/rdoc/single_class.rb#21 + def definition; end + + # source://rdoc//lib/rdoc/single_class.rb#25 + def pretty_print(q); end +end + +# RDoc statistics collector which prints a summary and report of a project's +# documentation totals. +# +# source://rdoc//lib/rdoc/stats.rb#6 +class RDoc::Stats + include ::RDoc::Text + + # Creates a new Stats that will have +num_files+. +verbosity+ defaults to 1 + # which will create an RDoc::Stats::Normal outputter. + # + # @return [Stats] a new instance of Stats + # + # source://rdoc//lib/rdoc/stats.rb#29 + def initialize(store, num_files, verbosity = T.unsafe(nil)); end + + # Records the parsing of an alias +as+. + # + # source://rdoc//lib/rdoc/stats.rb#52 + def add_alias(as); end + + # Records the parsing of an attribute +attribute+ + # + # source://rdoc//lib/rdoc/stats.rb#59 + def add_attribute(attribute); end + + # Records the parsing of a class +klass+ + # + # source://rdoc//lib/rdoc/stats.rb#66 + def add_class(klass); end + + # Records the parsing of +constant+ + # + # source://rdoc//lib/rdoc/stats.rb#73 + def add_constant(constant); end + + # Records the parsing of +file+ + # + # source://rdoc//lib/rdoc/stats.rb#80 + def add_file(file); end + + # Records the parsing of +method+ + # + # source://rdoc//lib/rdoc/stats.rb#88 + def add_method(method); end + + # Records the parsing of a module +mod+ + # + # source://rdoc//lib/rdoc/stats.rb#95 + def add_module(mod); end + + # Call this to mark the beginning of parsing for display purposes + # + # source://rdoc//lib/rdoc/stats.rb#102 + def begin_adding; end + + # Calculates documentation totals and percentages for classes, modules, + # constants, attributes and methods. + # + # source://rdoc//lib/rdoc/stats.rb#110 + def calculate; end + + # Output level for the coverage report + # + # source://rdoc//lib/rdoc/stats.rb#13 + def coverage_level; end + + # Sets coverage report level. Accepted values are: + # + # false or nil:: No report + # 0:: Classes, modules, constants, attributes, methods + # 1:: Level 0 + method parameters + # + # source://rdoc//lib/rdoc/stats.rb#158 + def coverage_level=(level); end + + # Returns the length and number of undocumented items in +collection+. + # + # source://rdoc//lib/rdoc/stats.rb#167 + def doc_stats(collection); end + + # Call this to mark the end of parsing for display purposes + # + # source://rdoc//lib/rdoc/stats.rb#175 + def done_adding; end + + # Count of files parsed during parsing + # + # source://rdoc//lib/rdoc/stats.rb#18 + def files_so_far; end + + # The documentation status of this project. +true+ when 100%, +false+ when + # less than 100% and +nil+ when unknown. + # + # Set by calling #calculate + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/stats.rb#185 + def fully_documented?; end + + # A report that says you did a great job! + # + # source://rdoc//lib/rdoc/stats.rb#192 + def great_job; end + + # Total number of files found + # + # source://rdoc//lib/rdoc/stats.rb#23 + def num_files; end + + # Calculates the percentage of items documented. + # + # source://rdoc//lib/rdoc/stats.rb#204 + def percent_doc; end + + # Returns a report on which items are not documented + # + # source://rdoc//lib/rdoc/stats.rb#218 + def report; end + + # Returns a report on undocumented attributes in ClassModule +cm+ + # + # source://rdoc//lib/rdoc/stats.rb#259 + def report_attributes(cm); end + + # Returns a report on undocumented items in ClassModule +cm+ + # + # source://rdoc//lib/rdoc/stats.rb#277 + def report_class_module(cm); end + + # Returns a report on undocumented constants in ClassModule +cm+ + # + # source://rdoc//lib/rdoc/stats.rb#329 + def report_constants(cm); end + + # Returns a report on undocumented methods in ClassModule +cm+ + # + # source://rdoc//lib/rdoc/stats.rb#351 + def report_methods(cm); end + + # Returns a summary of the collected statistics. + # + # source://rdoc//lib/rdoc/stats.rb#389 + def summary; end + + # Determines which parameters in +method+ were not documented. Returns a + # total parameter count and an Array of undocumented methods. + # + # source://rdoc//lib/rdoc/stats.rb#439 + def undoc_params(method); end +end + +# Stats printer that prints just the files being documented with a progress +# bar +# +# source://rdoc//lib/rdoc/stats/normal.rb#13 +class RDoc::Stats::Normal < ::RDoc::Stats::Quiet + # source://rdoc//lib/rdoc/stats/normal.rb#15 + def begin_adding; end + + # source://rdoc//lib/rdoc/stats/normal.rb#54 + def done_adding; end + + # Prints a file with a progress bar + # + # source://rdoc//lib/rdoc/stats/normal.rb#23 + def print_file(files_so_far, filename); end +end + +# Stats printer that prints nothing +# +# source://rdoc//lib/rdoc/stats/quiet.rb#5 +class RDoc::Stats::Quiet + # Creates a new Quiet that will print nothing + # + # @return [Quiet] a new instance of Quiet + # + # source://rdoc//lib/rdoc/stats/quiet.rb#10 + def initialize(num_files); end + + # Prints a message at the beginning of parsing + # + # source://rdoc//lib/rdoc/stats/quiet.rb#17 + def begin_adding(*_arg0); end + + # Prints when RDoc is done + # + # source://rdoc//lib/rdoc/stats/quiet.rb#57 + def done_adding(*_arg0); end + + # Prints when an alias is added + # + # source://rdoc//lib/rdoc/stats/quiet.rb#22 + def print_alias(*_arg0); end + + # Prints when an attribute is added + # + # source://rdoc//lib/rdoc/stats/quiet.rb#27 + def print_attribute(*_arg0); end + + # Prints when a class is added + # + # source://rdoc//lib/rdoc/stats/quiet.rb#32 + def print_class(*_arg0); end + + # Prints when a constant is added + # + # source://rdoc//lib/rdoc/stats/quiet.rb#37 + def print_constant(*_arg0); end + + # Prints when a file is added + # + # source://rdoc//lib/rdoc/stats/quiet.rb#42 + def print_file(*_arg0); end + + # Prints when a method is added + # + # source://rdoc//lib/rdoc/stats/quiet.rb#47 + def print_method(*_arg0); end + + # Prints when a module is added + # + # source://rdoc//lib/rdoc/stats/quiet.rb#52 + def print_module(*_arg0); end +end + +# Stats printer that prints everything documented, including the documented +# status +# +# source://rdoc//lib/rdoc/stats/verbose.rb#6 +class RDoc::Stats::Verbose < ::RDoc::Stats::Normal + # Returns a marker for RDoc::CodeObject +co+ being undocumented + # + # source://rdoc//lib/rdoc/stats/verbose.rb#11 + def nodoc(co); end + + # source://rdoc//lib/rdoc/stats/verbose.rb#15 + def print_alias(as); end + + # source://rdoc//lib/rdoc/stats/verbose.rb#19 + def print_attribute(attribute); end + + # source://rdoc//lib/rdoc/stats/verbose.rb#23 + def print_class(klass); end + + # source://rdoc//lib/rdoc/stats/verbose.rb#27 + def print_constant(constant); end + + # source://rdoc//lib/rdoc/stats/verbose.rb#31 + def print_file(files_so_far, file); end + + # source://rdoc//lib/rdoc/stats/verbose.rb#36 + def print_method(method); end + + # source://rdoc//lib/rdoc/stats/verbose.rb#40 + def print_module(mod); end +end + +# A set of rdoc data for a single project (gem, path, etc.). +# +# The store manages reading and writing ri data for a project and maintains a +# cache of methods, classes and ancestors in the store. +# +# The store maintains a #cache of its contents for faster lookup. After +# adding items to the store it must be flushed using #save_cache. The cache +# contains the following structures: +# +# @cache = { +# :ancestors => {}, # class name => ancestor names +# :attributes => {}, # class name => attributes +# :class_methods => {}, # class name => class methods +# :instance_methods => {}, # class name => instance methods +# :modules => [], # classes and modules in this store +# :pages => [], # page names +# } +# -- +# TODO need to prune classes +# +# source://rdoc//lib/rdoc/store.rb#25 +class RDoc::Store + # Creates a new Store of +type+ that will load or save to +path+ + # + # @return [Store] a new instance of Store + # + # source://rdoc//lib/rdoc/store.rb#127 + def initialize(path = T.unsafe(nil), type = T.unsafe(nil)); end + + # Adds +module+ as an enclosure (namespace) for the given +variable+ for C + # files. + # + # source://rdoc//lib/rdoc/store.rb#169 + def add_c_enclosure(variable, namespace); end + + # Adds C variables from an RDoc::Parser::C + # + # source://rdoc//lib/rdoc/store.rb#176 + def add_c_variables(c_parser); end + + # Adds the file with +name+ as an RDoc::TopLevel to the store. Returns the + # created RDoc::TopLevel. + # + # source://rdoc//lib/rdoc/store.rb#188 + def add_file(absolute_name, relative_name: T.unsafe(nil), parser: T.unsafe(nil)); end + + # Returns all classes discovered by RDoc + # + # source://rdoc//lib/rdoc/store.rb#212 + def all_classes; end + + # Returns all classes and modules discovered by RDoc + # + # source://rdoc//lib/rdoc/store.rb#219 + def all_classes_and_modules; end + + # All TopLevels known to RDoc + # + # source://rdoc//lib/rdoc/store.rb#226 + def all_files; end + + # Returns all modules discovered by RDoc + # + # source://rdoc//lib/rdoc/store.rb#233 + def all_modules; end + + # Ancestors cache accessor. Maps a klass name to an Array of its ancestors + # in this store. If Foo in this store inherits from Object, Kernel won't be + # listed (it will be included from ruby's ri store). + # + # source://rdoc//lib/rdoc/store.rb#242 + def ancestors; end + + # Attributes cache accessor. Maps a class to an Array of its attributes. + # + # source://rdoc//lib/rdoc/store.rb#249 + def attributes; end + + # Maps C variables to class or module names for each parsed C file. + # + # source://rdoc//lib/rdoc/store.rb#80 + def c_class_variables; end + + # Stores the name of the C variable a class belongs to. This helps wire up + # classes defined from C across files. + # + # source://rdoc//lib/rdoc/store.rb#73 + def c_enclosure_classes; end + + # source://rdoc//lib/rdoc/store.rb#75 + def c_enclosure_names; end + + # Maps C variables to singleton class names for each parsed C file. + # + # source://rdoc//lib/rdoc/store.rb#85 + def c_singleton_class_variables; end + + # The contents of the Store + # + # source://rdoc//lib/rdoc/store.rb#112 + def cache; end + + # Path to the cache file + # + # source://rdoc//lib/rdoc/store.rb#256 + def cache_path; end + + # Path to the ri data for +klass_name+ + # + # source://rdoc//lib/rdoc/store.rb#263 + def class_file(klass_name); end + + # Class methods cache accessor. Maps a class to an Array of its class + # methods (not full name). + # + # source://rdoc//lib/rdoc/store.rb#272 + def class_methods; end + + # Path where data for +klass_name+ will be stored (methods or class data) + # + # source://rdoc//lib/rdoc/store.rb#279 + def class_path(klass_name); end + + # Hash of all classes known to RDoc + # + # source://rdoc//lib/rdoc/store.rb#286 + def classes_hash; end + + # Removes empty items and ensures item in each collection are unique and + # sorted + # + # source://rdoc//lib/rdoc/store.rb#294 + def clean_cache_collection(collection); end + + # Prepares the RDoc code object tree for use by a generator. + # + # It finds unique classes/modules defined, and replaces classes/modules that + # are aliases for another one by a copy with RDoc::ClassModule#is_alias_for + # set. + # + # It updates the RDoc::ClassModule#constant_aliases attribute of "real" + # classes or modules. + # + # It also completely removes the classes and modules that should be removed + # from the documentation and the methods that have a visibility below + # +min_visibility+, which is the --visibility option. + # + # See also RDoc::Context#remove_from_documentation? + # + # source://rdoc//lib/rdoc/store.rb#322 + def complete(min_visibility); end + + # If true this Store will not write any files + # + # source://rdoc//lib/rdoc/store.rb#90 + def dry_run; end + + # If true this Store will not write any files + # + # source://rdoc//lib/rdoc/store.rb#90 + def dry_run=(_arg0); end + + # The encoding of the contents in the Store + # + # source://rdoc//lib/rdoc/store.rb#117 + def encoding; end + + # The encoding of the contents in the Store + # + # source://rdoc//lib/rdoc/store.rb#117 + def encoding=(_arg0); end + + # Hash of all files known to RDoc + # + # source://rdoc//lib/rdoc/store.rb#362 + def files_hash; end + + # Finds the enclosure (namespace) for the given C +variable+. + # + # source://rdoc//lib/rdoc/store.rb#369 + def find_c_enclosure(variable); end + + # Finds the class with +name+ in all discovered classes + # + # source://rdoc//lib/rdoc/store.rb#394 + def find_class_named(name); end + + # Finds the class with +name+ starting in namespace +from+ + # + # source://rdoc//lib/rdoc/store.rb#401 + def find_class_named_from(name, from); end + + # Finds the class or module with +name+ + # + # source://rdoc//lib/rdoc/store.rb#419 + def find_class_or_module(name); end + + # Finds the file with +name+ in all discovered files + # + # source://rdoc//lib/rdoc/store.rb#427 + def find_file_named(name); end + + # Finds the module with +name+ in all discovered modules + # + # source://rdoc//lib/rdoc/store.rb#434 + def find_module_named(name); end + + # Returns the RDoc::TopLevel that is a text file and has the given + # +file_name+ + # + # source://rdoc//lib/rdoc/store.rb#442 + def find_text_page(file_name); end + + # Finds unique classes/modules defined in +all_hash+, + # and returns them as an array. Performs the alias + # updates in +all_hash+: see ::complete. + # -- + # TODO aliases should be registered by Context#add_module_alias + # + # source://rdoc//lib/rdoc/store.rb#455 + def find_unique(all_hash); end + + # Fixes the erroneous BasicObject < Object in 1.9. + # + # Because we assumed all classes without a stated superclass + # inherit from Object, we have the above wrong inheritance. + # + # We fix BasicObject right away if we are running in a Ruby + # version >= 1.9. + # + # source://rdoc//lib/rdoc/store.rb#474 + def fix_basic_object_inheritance; end + + # Friendly rendition of #path + # + # source://rdoc//lib/rdoc/store.rb#483 + def friendly_path; end + + # source://rdoc//lib/rdoc/store.rb#495 + def inspect; end + + # Instance methods cache accessor. Maps a class to an Array of its + # instance methods (not full name). + # + # source://rdoc//lib/rdoc/store.rb#503 + def instance_methods; end + + # Loads all items from this store into memory. This recreates a + # documentation tree for use by a generator + # + # source://rdoc//lib/rdoc/store.rb#511 + def load_all; end + + # Loads cache file for this store + # + # source://rdoc//lib/rdoc/store.rb#559 + def load_cache; end + + # Loads ri data for +klass_name+ and hooks it up to this store. + # + # source://rdoc//lib/rdoc/store.rb#598 + def load_class(klass_name); end + + # Loads ri data for +klass_name+ + # + # source://rdoc//lib/rdoc/store.rb#616 + def load_class_data(klass_name); end + + # Loads ri data for +method_name+ in +klass_name+ + # + # source://rdoc//lib/rdoc/store.rb#629 + def load_method(klass_name, method_name); end + + # Loads ri data for +page_name+ + # + # source://rdoc//lib/rdoc/store.rb#645 + def load_page(page_name); end + + # Gets the main page for this RDoc store. This page is used as the root of + # the RDoc server. + # + # source://rdoc//lib/rdoc/store.rb#661 + def main; end + + # Sets the main page for this RDoc store. + # + # source://rdoc//lib/rdoc/store.rb#668 + def main=(page); end + + # Converts the variable => ClassModule map +variables+ from a C parser into + # a variable => class name map. + # + # source://rdoc//lib/rdoc/store.rb#676 + def make_variable_map(variables); end + + # Path to the ri data for +method_name+ in +klass_name+ + # + # source://rdoc//lib/rdoc/store.rb#689 + def method_file(klass_name, method_name); end + + # Modules cache accessor. An Array of all the module (and class) names in + # the store. + # + # source://rdoc//lib/rdoc/store.rb#703 + def module_names; end + + # Hash of all modules known to RDoc + # + # source://rdoc//lib/rdoc/store.rb#710 + def modules_hash; end + + # Returns the RDoc::TopLevel that is a text file and has the given +name+ + # + # source://rdoc//lib/rdoc/store.rb#717 + def page(name); end + + # Path to the ri data for +page_name+ + # + # source://rdoc//lib/rdoc/store.rb#726 + def page_file(page_name); end + + # Path this store reads or writes + # + # source://rdoc//lib/rdoc/store.rb#95 + def path; end + + # Path this store reads or writes + # + # source://rdoc//lib/rdoc/store.rb#95 + def path=(_arg0); end + + # The RDoc::RDoc driver for this parse tree. This allows classes consulting + # the documentation tree to access user-set options, for example. + # + # source://rdoc//lib/rdoc/store.rb#101 + def rdoc; end + + # The RDoc::RDoc driver for this parse tree. This allows classes consulting + # the documentation tree to access user-set options, for example. + # + # source://rdoc//lib/rdoc/store.rb#101 + def rdoc=(_arg0); end + + # Removes from +all_hash+ the contexts that are nodoc or have no content. + # + # See RDoc::Context#remove_from_documentation? + # + # source://rdoc//lib/rdoc/store.rb#737 + def remove_nodoc(all_hash); end + + # Saves all entries in the store + # + # source://rdoc//lib/rdoc/store.rb#747 + def save; end + + # Writes the cache file for this store + # + # source://rdoc//lib/rdoc/store.rb#772 + def save_cache; end + + # Writes the ri data for +klass+ (or module) + # + # source://rdoc//lib/rdoc/store.rb#799 + def save_class(klass); end + + # Writes the ri data for +method+ on +klass+ + # + # source://rdoc//lib/rdoc/store.rb#873 + def save_method(klass, method); end + + # Writes the ri data for +page+ + # + # source://rdoc//lib/rdoc/store.rb#896 + def save_page(page); end + + # Source of the contents of this store. + # + # For a store from a gem the source is the gem name. For a store from the + # home directory the source is "home". For system ri store (the standard + # library documentation) the source is"ruby". For a store from the site + # ri directory the store is "site". For other stores the source is the + # #path. + # + # source://rdoc//lib/rdoc/store.rb#922 + def source; end + + # Gets the title for this RDoc store. This is used as the title in each + # page on the RDoc server + # + # source://rdoc//lib/rdoc/store.rb#936 + def title; end + + # Sets the title page for this RDoc store. + # + # source://rdoc//lib/rdoc/store.rb#943 + def title=(title); end + + # Type of ri datastore this was loaded from. See RDoc::RI::Driver, + # RDoc::RI::Paths. + # + # source://rdoc//lib/rdoc/store.rb#107 + def type; end + + # Type of ri datastore this was loaded from. See RDoc::RI::Driver, + # RDoc::RI::Paths. + # + # source://rdoc//lib/rdoc/store.rb#107 + def type=(_arg0); end + + # Returns the unique classes discovered by RDoc. + # + # ::complete must have been called prior to using this method. + # + # source://rdoc//lib/rdoc/store.rb#952 + def unique_classes; end + + # Returns the unique classes and modules discovered by RDoc. + # ::complete must have been called prior to using this method. + # + # source://rdoc//lib/rdoc/store.rb#960 + def unique_classes_and_modules; end + + # Returns the unique modules discovered by RDoc. + # ::complete must have been called prior to using this method. + # + # source://rdoc//lib/rdoc/store.rb#968 + def unique_modules; end + + # The lazy constants alias will be discovered in passing + # + # source://rdoc//lib/rdoc/store.rb#122 + def unmatched_constant_alias; end + + # Sets the parser of +absolute_name+, unless it from a source code file. + # + # source://rdoc//lib/rdoc/store.rb#203 + def update_parser_of_file(absolute_name, parser); end + + private + + # source://rdoc//lib/rdoc/store.rb#973 + def marshal_load(file); end +end + +# source://rdoc//lib/rdoc/store.rb#977 +RDoc::Store::MarshalFilter = T.let(T.unsafe(nil), Proc) + +# Raised when a stored file for a class, module, page or method is missing. +# +# source://rdoc//lib/rdoc/store.rb#36 +class RDoc::Store::MissingFileError < ::RDoc::Store::Error + # Creates a new MissingFileError for the missing +file+ for the given + # +name+ that should have been in the +store+. + # + # @return [MissingFileError] a new instance of MissingFileError + # + # source://rdoc//lib/rdoc/store.rb#57 + def initialize(store, file, name); end + + # The file the #name should be saved as + # + # source://rdoc//lib/rdoc/store.rb#46 + def file; end + + # source://rdoc//lib/rdoc/store.rb#63 + def message; end + + # The name of the object the #file would be loaded from + # + # source://rdoc//lib/rdoc/store.rb#51 + def name; end + + # The store the file should exist in + # + # source://rdoc//lib/rdoc/store.rb#41 + def store; end +end + +# RDoc::Task creates the following rake tasks to generate and clean up RDoc +# output: +# +# [rdoc] +# Main task for this RDoc task. +# +# [clobber_rdoc] +# Delete all the rdoc files. This target is automatically added to the main +# clobber target. +# +# [rerdoc] +# Rebuild the rdoc files from scratch, even if they are not out of date. +# +# [rdoc:coverage] +# Print RDoc coverage report for all rdoc files. +# +# Simple Example: +# +# require 'rdoc/task' +# +# RDoc::Task.new do |rdoc| +# rdoc.main = "README.rdoc" +# rdoc.rdoc_files.include("README.rdoc", "lib/**/*.rb") +# end +# +# The +rdoc+ object passed to the block is an RDoc::Task object. See the +# attributes list for the RDoc::Task class for available customization options. +# +# == Specifying different task names +# +# You may wish to give the task a different name, such as if you are +# generating two sets of documentation. For instance, if you want to have a +# development set of documentation including private methods: +# +# require 'rdoc/task' +# +# RDoc::Task.new :rdoc_dev do |rdoc| +# rdoc.main = "README.rdoc" +# rdoc.rdoc_files.include("README.rdoc", "lib/**/*.rb") +# rdoc.options << "--all" +# end +# +# The tasks would then be named :rdoc_dev, +# :clobber_rdoc_dev, and :rerdoc_dev. +# +# If you wish to have completely different task names, then pass a Hash as +# first argument. With the :rdoc, :clobber_rdoc and +# :rerdoc options, you can customize the task names to your liking. +# +# For example: +# +# require 'rdoc/task' +# +# RDoc::Task.new(:rdoc => "rdoc", :clobber_rdoc => "rdoc:clean", +# :rerdoc => "rdoc:force") +# +# This will create the tasks :rdoc, :rdoc:clean, +# :rdoc:force, and :rdoc:coverage. +# +# source://rdoc//lib/rdoc/task.rb#99 +class RDoc::Task < ::Rake::TaskLib + # Create an RDoc task with the given name. See the RDoc::Task class overview + # for documentation. + # + # @return [Task] a new instance of Task + # @yield [_self] + # @yieldparam _self [RDoc::Task] the object that the method was called on + # + # source://rdoc//lib/rdoc/task.rb#158 + def initialize(name = T.unsafe(nil)); end + + # The block passed to this method will be called just before running the + # RDoc generator. It is allowed to modify RDoc::Task attributes inside the + # block. + # + # source://rdoc//lib/rdoc/task.rb#288 + def before_running_rdoc(&block); end + + # Ensures that +names+ only includes names for the :rdoc, :clobber_rdoc and + # :rerdoc. If other names are given an ArgumentError is raised. + # + # source://rdoc//lib/rdoc/task.rb#174 + def check_names(names); end + + # Task description for the clobber rdoc task or its renamed equivalent + # + # source://rdoc//lib/rdoc/task.rb#188 + def clobber_task_description; end + + # Task description for the coverage task or its renamed description + # + # source://rdoc//lib/rdoc/task.rb#309 + def coverage_task_description; end + + # Sets default task values + # + # source://rdoc//lib/rdoc/task.rb#195 + def defaults; end + + # Create the tasks defined by this task lib. + # + # source://rdoc//lib/rdoc/task.rb#224 + def define; end + + # Whether to run the rdoc process as an external shell (default is false) + # + # source://rdoc//lib/rdoc/task.rb#152 + def external; end + + # Whether to run the rdoc process as an external shell (default is false) + # + # source://rdoc//lib/rdoc/task.rb#152 + def external=(_arg0); end + + # Name of format generator (--format) used by rdoc. (defaults to + # rdoc's default) + # + # source://rdoc//lib/rdoc/task.rb#137 + def generator; end + + # Name of format generator (--format) used by rdoc. (defaults to + # rdoc's default) + # + # source://rdoc//lib/rdoc/task.rb#137 + def generator=(_arg0); end + + # All source is inline now. This method is deprecated + # + # source://rdoc//lib/rdoc/task.rb#209 + def inline_source; end + + # All source is inline now. This method is deprecated + # + # source://rdoc//lib/rdoc/task.rb#217 + def inline_source=(value); end + + # Name of file to be used as the main, top level file of the RDoc. (default + # is none) + # + # source://rdoc//lib/rdoc/task.rb#126 + def main; end + + # Name of file to be used as the main, top level file of the RDoc. (default + # is none) + # + # source://rdoc//lib/rdoc/task.rb#126 + def main=(_arg0); end + + # Comment markup format. rdoc, rd and tomdoc are supported. (default is + # 'rdoc') + # + # source://rdoc//lib/rdoc/task.rb#110 + def markup; end + + # Comment markup format. rdoc, rd and tomdoc are supported. (default is + # 'rdoc') + # + # source://rdoc//lib/rdoc/task.rb#110 + def markup=(_arg0); end + + # Name of the main, top level task. (default is :rdoc) + # + # source://rdoc//lib/rdoc/task.rb#104 + def name; end + + # Name of the main, top level task. (default is :rdoc) + # + # source://rdoc//lib/rdoc/task.rb#104 + def name=(_arg0); end + + # List of options that will be supplied to RDoc + # + # source://rdoc//lib/rdoc/task.rb#272 + def option_list; end + + # Additional list of options to be passed rdoc. (default is []) + # + # source://rdoc//lib/rdoc/task.rb#147 + def options; end + + # Additional list of options to be passed rdoc. (default is []) + # + # source://rdoc//lib/rdoc/task.rb#147 + def options=(_arg0); end + + # Name of directory to receive the html output files. (default is "html") + # + # source://rdoc//lib/rdoc/task.rb#115 + def rdoc_dir; end + + # Name of directory to receive the html output files. (default is "html") + # + # source://rdoc//lib/rdoc/task.rb#115 + def rdoc_dir=(_arg0); end + + # List of files to be included in the rdoc generation. (default is []) + # + # source://rdoc//lib/rdoc/task.rb#142 + def rdoc_files; end + + # List of files to be included in the rdoc generation. (default is []) + # + # source://rdoc//lib/rdoc/task.rb#142 + def rdoc_files=(_arg0); end + + # Task description for the rdoc task or its renamed equivalent + # + # source://rdoc//lib/rdoc/task.rb#295 + def rdoc_task_description; end + + # Task description for the rerdoc task or its renamed description + # + # source://rdoc//lib/rdoc/task.rb#302 + def rerdoc_task_description; end + + # Name of template to be used by rdoc. (defaults to rdoc's default) + # + # source://rdoc//lib/rdoc/task.rb#131 + def template; end + + # Name of template to be used by rdoc. (defaults to rdoc's default) + # + # source://rdoc//lib/rdoc/task.rb#131 + def template=(_arg0); end + + # Title of RDoc documentation. (defaults to rdoc's default) + # + # source://rdoc//lib/rdoc/task.rb#120 + def title; end + + # Title of RDoc documentation. (defaults to rdoc's default) + # + # source://rdoc//lib/rdoc/task.rb#120 + def title=(_arg0); end + + private + + # source://rdoc//lib/rdoc/task.rb#326 + def clobber_task_name; end + + # source://rdoc//lib/rdoc/task.rb#340 + def coverage_task_name; end + + # source://rdoc//lib/rdoc/task.rb#315 + def rdoc_target; end + + # source://rdoc//lib/rdoc/task.rb#319 + def rdoc_task_name; end + + # source://rdoc//lib/rdoc/task.rb#333 + def rerdoc_task_name; end +end + +# Methods for manipulating comment text +# +# source://rdoc//lib/rdoc/text.rb#11 +module RDoc::Text + # Expands tab characters in +text+ to eight spaces + # + # source://rdoc//lib/rdoc/text.rb#63 + def expand_tabs(text); end + + # Flush +text+ left based on the shortest line + # + # source://rdoc//lib/rdoc/text.rb#82 + def flush_left(text); end + + # The language for this text. This affects stripping comments + # markers. + # + # source://rdoc//lib/rdoc/text.rb#17 + def language; end + + # The language for this text. This affects stripping comments + # markers. + # + # source://rdoc//lib/rdoc/text.rb#17 + def language=(_arg0); end + + # Convert a string in markup format into HTML. + # + # Requires the including class to implement #formatter + # + # source://rdoc//lib/rdoc/text.rb#101 + def markup(text); end + + # Strips hashes, expands tabs then flushes +text+ to the left + # + # source://rdoc//lib/rdoc/text.rb#117 + def normalize_comment(text); end + + # Normalizes +text+ then builds a RDoc::Markup::Document from it + # + # source://rdoc//lib/rdoc/text.rb#135 + def parse(text, format = T.unsafe(nil)); end + + # The first +limit+ characters of +text+ as HTML + # + # source://rdoc//lib/rdoc/text.rb#149 + def snippet(text, limit = T.unsafe(nil)); end + + # Strips leading # characters from +text+ + # + # source://rdoc//lib/rdoc/text.rb#158 + def strip_hashes(text); end + + # Strips leading and trailing \n characters from +text+ + # + # source://rdoc//lib/rdoc/text.rb#170 + def strip_newlines(text); end + + # Strips /* */ style comments + # + # source://rdoc//lib/rdoc/text.rb#177 + def strip_stars(text); end + + # source://rdoc//lib/rdoc/text.rb#200 + def to_html(text); end + + # Wraps +txt+ to +line_len+ + # + # source://rdoc//lib/rdoc/text.rb#287 + def wrap(txt, line_len = T.unsafe(nil)); end + + class << self + # Transcodes +character+ to +encoding+ with a +fallback+ character. + # + # source://rdoc//lib/rdoc/text.rb#55 + def encode_fallback(character, encoding, fallback); end + end +end + +# Character class to be separated by a space when concatenating +# lines. +# +# source://rdoc//lib/rdoc/text.rb#320 +RDoc::Text::SPACE_SEPARATED_LETTER_CLASS = T.let(T.unsafe(nil), Regexp) + +# A TokenStream is a list of tokens, gathered during the parse of some entity +# (say a method). Entities populate these streams by being registered with the +# lexer. Any class can collect tokens by including TokenStream. From the +# outside, you use such an object by calling the start_collecting_tokens +# method, followed by calls to add_token and pop_token. +# +# source://rdoc//lib/rdoc/token_stream.rb#9 +module RDoc::TokenStream + # Adds one +token+ to the collected tokens + # + # source://rdoc//lib/rdoc/token_stream.rb#84 + def add_token(token); end + + # Adds +tokens+ to the collected tokens + # + # source://rdoc//lib/rdoc/token_stream.rb#77 + def add_tokens(tokens); end + + # Starts collecting tokens + # + # source://rdoc//lib/rdoc/token_stream.rb#91 + def collect_tokens; end + + # Remove the last token from the collected tokens + # + # source://rdoc//lib/rdoc/token_stream.rb#100 + def pop_token; end + + # Starts collecting tokens + # + # source://rdoc//lib/rdoc/token_stream.rb#91 + def start_collecting_tokens; end + + # Current token stream + # + # source://rdoc//lib/rdoc/token_stream.rb#107 + def token_stream; end + + # Returns a string representation of the token stream + # + # source://rdoc//lib/rdoc/token_stream.rb#114 + def tokens_to_s; end + + class << self + # Converts +token_stream+ to HTML wrapping various tokens with + # elements. Some tokens types are wrapped in spans + # with the given class names. Other token types are not wrapped in spans. + # + # source://rdoc//lib/rdoc/token_stream.rb#16 + def to_html(token_stream); end + end +end + +# A parser for TomDoc based on TomDoc 1.0.0-rc1 (02adef9b5a) +# +# The TomDoc specification can be found at: +# +# http://tomdoc.org +# +# The latest version of the TomDoc specification can be found at: +# +# https://github.com/mojombo/tomdoc/blob/master/tomdoc.md +# +# To choose TomDoc as your only default format see RDoc::Options@Saved+Options +# for instructions on setting up a .rdoc_options file to store +# your project default. +# +# There are a few differences between this parser and the specification. A +# best-effort was made to follow the specification as closely as possible but +# some choices to deviate were made. +# +# A future version of RDoc will warn when a MUST or MUST NOT is violated and +# may warn when a SHOULD or SHOULD NOT is violated. RDoc will always try +# to emit documentation even if given invalid TomDoc. +# +# Here are some implementation choices this parser currently makes: +# +# This parser allows rdoc-style inline markup but you should not depended on +# it. +# +# This parser allows a space between the comment and the method body. +# +# This parser does not require the default value to be described for an +# optional argument. +# +# This parser does not examine the order of sections. An Examples section may +# precede the Arguments section. +# +# This class is documented in TomDoc format. Since this is a subclass of the +# RDoc markup parser there isn't much to see here, unfortunately. +# +# source://rdoc//lib/rdoc/tom_doc.rb#42 +class RDoc::TomDoc < ::RDoc::Markup::Parser + # Public: Creates a new TomDoc parser. See also RDoc::Markup::parse + # + # @return [TomDoc] a new instance of TomDoc + # + # source://rdoc//lib/rdoc/tom_doc.rb#130 + def initialize; end + + # Internal: Builds a heading from the token stream + # + # level - The level of heading to create + # + # Returns an RDoc::Markup::Heading + # + # source://rdoc//lib/rdoc/tom_doc.rb#143 + def build_heading(level); end + + # Internal: Builds a paragraph from the token stream + # + # margin - Unused + # + # Returns an RDoc::Markup::Paragraph. + # + # source://rdoc//lib/rdoc/tom_doc.rb#173 + def build_paragraph(margin); end + + # Internal: Builds a verbatim from the token stream. A verbatim in the + # Examples section will be marked as in Ruby format. + # + # margin - The indentation from the margin for lines that belong to this + # verbatim section. + # + # Returns an RDoc::Markup::Verbatim + # + # source://rdoc//lib/rdoc/tom_doc.rb#159 + def build_verbatim(margin); end + + # Detects a section change to "Returns" and adds a heading + # + # source://rdoc//lib/rdoc/tom_doc.rb#213 + def parse_text(parent, indent); end + + # Internal: Turns text into an Array of tokens + # + # text - A String containing TomDoc-format text. + # + # Returns self. + # + # source://rdoc//lib/rdoc/tom_doc.rb#231 + def tokenize(text); end + + # Internal: Token accessor + # + # source://rdoc//lib/rdoc/tom_doc.rb#46 + def tokens; end + + class << self + # Internal: Adds a post-processor which sets the RDoc section based on the + # comment's status. + # + # Returns nothing. + # + # source://rdoc//lib/rdoc/tom_doc.rb#53 + def add_post_processor; end + + # Public: Parses TomDoc from text + # + # text - A String containing TomDoc-format text. + # + # Examples + # + # RDoc::TomDoc.parse <<-TOMDOC + # This method does some things + # + # Returns nothing. + # TOMDOC + # # => # + # + # Returns an RDoc::Markup::Document representing the TomDoc format. + # + # source://rdoc//lib/rdoc/tom_doc.rb#84 + def parse(text); end + + # Internal: Extracts the Signature section's method signature + # + # comment - An RDoc::Comment that will be parsed and have the signature + # extracted + # + # Returns a String containing the signature and nil if not + # + # source://rdoc//lib/rdoc/tom_doc.rb#100 + def signature(comment); end + end +end + +# A TopLevel context is a representation of the contents of a single file +# +# source://rdoc//lib/rdoc/top_level.rb#5 +class RDoc::TopLevel < ::RDoc::Context + # Creates a new TopLevel for the file at +absolute_name+. If documentation + # is being generated outside the source dir +relative_name+ is relative to + # the source directory. + # + # @return [TopLevel] a new instance of TopLevel + # + # source://rdoc//lib/rdoc/top_level.rb#43 + def initialize(absolute_name, relative_name = T.unsafe(nil)); end + + # An RDoc::TopLevel is equal to another with the same relative_name + # + # source://rdoc//lib/rdoc/top_level.rb#67 + def ==(other); end + + # Absolute name of this file + # + # source://rdoc//lib/rdoc/top_level.rb#22 + def absolute_name; end + + # Absolute name of this file + # + # source://rdoc//lib/rdoc/top_level.rb#22 + def absolute_name=(_arg0); end + + # Adds +an_alias+ to +Object+ instead of +self+. + # + # source://rdoc//lib/rdoc/top_level.rb#76 + def add_alias(an_alias); end + + # Adds +constant+ to +Object+ instead of +self+. + # + # source://rdoc//lib/rdoc/top_level.rb#85 + def add_constant(constant); end + + # Adds +include+ to +Object+ instead of +self+. + # + # source://rdoc//lib/rdoc/top_level.rb#94 + def add_include(include); end + + # Adds +method+ to +Object+ instead of +self+. + # + # source://rdoc//lib/rdoc/top_level.rb#103 + def add_method(method); end + + # Adds class or module +mod+. Used in the building phase + # by the Ruby parser. + # + # source://rdoc//lib/rdoc/top_level.rb#113 + def add_to_classes_or_modules(mod); end + + # Base name of this file + # + # source://rdoc//lib/rdoc/top_level.rb#120 + def base_name; end + + # All the classes or modules that were declared in + # this file. These are assigned to either +#classes_hash+ + # or +#modules_hash+ once we know what they really are. + # + # source://rdoc//lib/rdoc/top_level.rb#29 + def classes_or_modules; end + + # Returns a URL for this source file on some web repository. Use the -W + # command line option to set. + # + # source://rdoc//lib/rdoc/generator/markup.rb#149 + def cvs_url; end + + # source://rdoc//lib/rdoc/top_level.rb#31 + def diagram; end + + # source://rdoc//lib/rdoc/top_level.rb#31 + def diagram=(_arg0); end + + # Only a TopLevel that contains text file) will be displayed. See also + # RDoc::CodeObject#display? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/top_level.rb#130 + def display?; end + + # An RDoc::TopLevel is equal to another with the same relative_name + # + # source://rdoc//lib/rdoc/top_level.rb#67 + def eql?(other); end + + # This TopLevel's File::Stat struct + # + # source://rdoc//lib/rdoc/top_level.rb#12 + def file_stat; end + + # This TopLevel's File::Stat struct + # + # source://rdoc//lib/rdoc/top_level.rb#12 + def file_stat=(_arg0); end + + # See RDoc::TopLevel::find_class_or_module + # -- + # TODO Why do we search through all classes/modules found, not just the + # ones of this instance? + # + # source://rdoc//lib/rdoc/top_level.rb#140 + def find_class_or_module(name); end + + # Finds a class or module named +symbol+ + # + # source://rdoc//lib/rdoc/top_level.rb#147 + def find_local_symbol(symbol); end + + # Finds a module or class with +name+ + # + # source://rdoc//lib/rdoc/top_level.rb#154 + def find_module_named(name); end + + # Returns the relative name of this file + # + # source://rdoc//lib/rdoc/top_level.rb#161 + def full_name; end + + # An RDoc::TopLevel has the same hash as another with the same + # relative_name + # + # source://rdoc//lib/rdoc/top_level.rb#169 + def hash; end + + # URL for this with a +prefix+ + # + # source://rdoc//lib/rdoc/top_level.rb#176 + def http_url(prefix); end + + # source://rdoc//lib/rdoc/top_level.rb#182 + def inspect; end + + # Time this file was last modified, if known + # + # source://rdoc//lib/rdoc/top_level.rb#194 + def last_modified; end + + # Dumps this TopLevel for use by ri. See also #marshal_load + # + # source://rdoc//lib/rdoc/top_level.rb#201 + def marshal_dump; end + + # Loads this TopLevel from +array+. + # + # source://rdoc//lib/rdoc/top_level.rb#213 + def marshal_load(array); end + + # Base name of this file + # + # source://rdoc//lib/rdoc/top_level.rb#120 + def name; end + + # Returns the NormalClass "Object", creating it if not found. + # + # Records +self+ as a location in "Object". + # + # source://rdoc//lib/rdoc/top_level.rb#227 + def object_class; end + + # Base name of this file without the extension + # + # source://rdoc//lib/rdoc/top_level.rb#238 + def page_name; end + + # The parser class that processed this file + # + # source://rdoc//lib/rdoc/top_level.rb#36 + def parser; end + + # Sets the parser for this toplevel context, also the store. + # + # source://rdoc//lib/rdoc/top_level.rb#58 + def parser=(val); end + + # Path to this file for use with HTML generator output. + # + # source://rdoc//lib/rdoc/top_level.rb#248 + def path; end + + # source://rdoc//lib/rdoc/top_level.rb#252 + def pretty_print(q); end + + # Relative name of this file + # + # source://rdoc//lib/rdoc/top_level.rb#17 + def relative_name; end + + # Relative name of this file + # + # source://rdoc//lib/rdoc/top_level.rb#17 + def relative_name=(_arg0); end + + # Search record used by RDoc::Generator::JsonIndex + # + # source://rdoc//lib/rdoc/top_level.rb#266 + def search_record; end + + # Is this TopLevel from a text file instead of a source code file? + # + # @return [Boolean] + # + # source://rdoc//lib/rdoc/top_level.rb#283 + def text?; end + + # source://rdoc//lib/rdoc/top_level.rb#287 + def to_s; end +end + +# :stopdoc: +# +# source://rdoc//lib/rdoc/task.rb#347 +module Rake + extend ::FileUtils::StreamUtils_ + extend ::FileUtils +end + +# For backwards compatibility +# +# source://rdoc//lib/rdoc/task.rb#352 +Rake::RDocTask = RDoc::Task diff --git a/sorbet/rbi/gems/redis-actionpack@5.3.0.rbi b/sorbet/rbi/gems/redis-actionpack@5.4.0.rbi similarity index 60% rename from sorbet/rbi/gems/redis-actionpack@5.3.0.rbi rename to sorbet/rbi/gems/redis-actionpack@5.4.0.rbi index be606ffce..0a65f0b86 100644 --- a/sorbet/rbi/gems/redis-actionpack@5.3.0.rbi +++ b/sorbet/rbi/gems/redis-actionpack@5.4.0.rbi @@ -4,25 +4,37 @@ # This is an autogenerated file for types exported from the `redis-actionpack` gem. # Please instead update this file by running `bin/tapioca gem redis-actionpack`. + # source://redis-actionpack//lib/action_dispatch/middleware/session/redis_store.rb#7 module ActionDispatch - # source://actionpack/7.0.5/lib/action_dispatch.rb#99 + # source://actionpack/7.2.0/lib/action_dispatch.rb#135 + def eager_load!; end + + # source://actionpack/7.2.0/lib/action_dispatch.rb#121 def test_app; end - # source://actionpack/7.0.5/lib/action_dispatch.rb#99 + # source://actionpack/7.2.0/lib/action_dispatch.rb#121 def test_app=(val); end class << self - # source://actionpack/7.0.5/lib/action_dispatch.rb#99 + # source://actionpack/7.2.0/lib/action_dispatch/deprecator.rb#6 + def deprecator; end + + # source://actionpack/7.2.0/lib/action_dispatch.rb#121 def test_app; end - # source://actionpack/7.0.5/lib/action_dispatch.rb#99 + # source://actionpack/7.2.0/lib/action_dispatch.rb#121 def test_app=(val); end end end # source://redis-actionpack//lib/action_dispatch/middleware/session/redis_store.rb#8 -module ActionDispatch::Session; end +module ActionDispatch::Session + class << self + # source://actionpack/7.2.0/lib/action_dispatch.rb#107 + def resolve_store(session_store); end + end +end # Session storage in Redis, using +Redis::Rack+ as a basis. # @@ -77,100 +89,73 @@ class Redis include ::Redis::Commands::Strings include ::Redis::Commands::Transactions - # source://redis/4.8.1/lib/redis.rb#83 + # source://redis/5.2.0/lib/redis.rb#63 def initialize(options = T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#160 + # source://redis/5.2.0/lib/redis.rb#98 def _client; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def close; end - # source://redis/4.8.1/lib/redis.rb#140 - def commit; end - - # source://redis/4.8.1/lib/redis.rb#105 + # source://redis/5.2.0/lib/redis.rb#83 def connected?; end - # source://redis/4.8.1/lib/redis.rb#250 + # source://redis/5.2.0/lib/redis.rb#122 def connection; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def disconnect!; end - # source://redis/4.8.1/lib/redis.rb#246 + # source://redis/5.2.0/lib/redis.rb#118 def dup; end - # source://redis/4.8.1/lib/redis.rb#238 + # source://redis/5.2.0/lib/redis.rb#110 def id; end - # source://redis/4.8.1/lib/redis.rb#242 + # source://redis/5.2.0/lib/redis.rb#114 def inspect; end - # source://redis/4.8.1/lib/redis.rb#214 - def multi(&block); end - - # source://redis/4.8.1/lib/redis.rb#164 - def pipelined(&block); end + # source://redis/5.2.0/lib/redis.rb#102 + def pipelined(exception: T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#125 - def queue(*command); end - - # source://redis/4.8.1/lib/redis.rb#115 + # source://redis/5.2.0/lib/redis.rb#94 def with; end - # source://redis/4.8.1/lib/redis.rb#93 - def with_reconnect(val = T.unsafe(nil), &blk); end - - # source://redis/4.8.1/lib/redis.rb#100 - def without_reconnect(&blk); end + # source://redis/5.2.0/lib/redis.rb#78 + def without_reconnect(&block); end private - # source://redis/4.8.1/lib/redis.rb#280 + # source://redis/5.2.0/lib/redis.rb#164 def _subscription(method, timeout, channels, block); end - # source://redis/4.8.1/lib/redis.rb#274 + # source://redis/5.2.0/lib/redis.rb#134 + def initialize_client(options); end + + # source://redis/5.2.0/lib/redis.rb#158 def send_blocking_command(command, timeout, &block); end - # source://redis/4.8.1/lib/redis.rb#268 + # source://redis/5.2.0/lib/redis.rb#150 def send_command(command, &block); end - # source://redis/4.8.1/lib/redis.rb#264 + # source://redis/5.2.0/lib/redis.rb#146 def synchronize; end class << self - # source://redis/4.8.1/lib/redis.rb#40 - def current; end - - # source://redis/4.8.1/lib/redis.rb#45 - def current=(redis); end - - # source://redis/4.8.1/lib/redis.rb#30 + # source://redis/5.2.0/lib/redis.rb#14 def deprecate!(message); end - # source://redis/4.8.1/lib/redis.rb#15 - def exists_returns_integer; end - - # source://redis/4.8.1/lib/redis.rb#18 - def exists_returns_integer=(value); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations=(_arg0); end - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean; end - - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean=(_arg0); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations=(_arg0); end end end @@ -180,9 +165,3 @@ module Redis::ActionPack; end # source://redis-actionpack//lib/redis/actionpack/version.rb#3 Redis::ActionPack::VERSION = T.let(T.unsafe(nil), String) - -# source://redis/4.8.1/lib/redis.rb#8 -Redis::BASE_PATH = T.let(T.unsafe(nil), String) - -# source://redis/4.8.1/lib/redis/version.rb#4 -Redis::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/redis-activesupport@5.3.0.rbi b/sorbet/rbi/gems/redis-activesupport@5.3.0.rbi index bf8b505b5..1956a162e 100644 --- a/sorbet/rbi/gems/redis-activesupport@5.3.0.rbi +++ b/sorbet/rbi/gems/redis-activesupport@5.3.0.rbi @@ -4,100 +4,104 @@ # This is an autogenerated file for types exported from the `redis-activesupport` gem. # Please instead update this file by running `bin/tapioca gem redis-activesupport`. + # source://redis-activesupport//lib/active_support/cache/redis_store.rb#4 module ActiveSupport - # source://activesupport/7.0.5/lib/active_support/json/decoding.rb#9 + # source://activesupport/7.2.0/lib/active_support/json/decoding.rb#9 def parse_json_times; end - # source://activesupport/7.0.5/lib/active_support/json/decoding.rb#9 + # source://activesupport/7.2.0/lib/active_support/json/decoding.rb#9 def parse_json_times=(val); end - # source://activesupport/7.0.5/lib/active_support.rb#94 + # source://activesupport/7.2.0/lib/active_support.rb#99 def test_order; end - # source://activesupport/7.0.5/lib/active_support.rb#94 + # source://activesupport/7.2.0/lib/active_support.rb#99 def test_order=(val); end - # source://activesupport/7.0.5/lib/active_support.rb#95 + # source://activesupport/7.2.0/lib/active_support.rb#100 def test_parallelization_threshold; end - # source://activesupport/7.0.5/lib/active_support.rb#95 + # source://activesupport/7.2.0/lib/active_support.rb#100 def test_parallelization_threshold=(val); end class << self - # source://activesupport/7.0.5/lib/active_support.rb#99 + # source://activesupport/7.2.0/lib/active_support.rb#105 def cache_format_version; end - # source://activesupport/7.0.5/lib/active_support.rb#103 + # source://activesupport/7.2.0/lib/active_support.rb#109 def cache_format_version=(value); end - # source://activesupport/7.0.5/lib/active_support.rb#88 + # source://activesupport/7.2.0/lib/active_support/deprecator.rb#4 + def deprecator; end + + # source://activesupport/7.2.0/lib/active_support.rb#93 def eager_load!; end - # source://activesupport/7.0.5/lib/active_support.rb#97 + # source://activesupport/7.2.0/lib/active_support.rb#103 def error_reporter; end - # source://activesupport/7.0.5/lib/active_support.rb#97 + # source://activesupport/7.2.0/lib/active_support.rb#103 def error_reporter=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def escape_html_entities_in_json(*_arg0, **_arg1, &_arg2); end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def escape_html_entities_in_json=(arg); end - # source://activesupport/7.0.5/lib/active_support/gem_version.rb#5 + # source://activesupport/7.2.0/lib/active_support/gem_version.rb#5 def gem_version; end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def json_encoder(*_arg0, **_arg1, &_arg2); end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def json_encoder=(arg); end - # source://activesupport/7.0.5/lib/active_support/json/decoding.rb#9 + # source://activesupport/7.2.0/lib/active_support/json/decoding.rb#9 def parse_json_times; end - # source://activesupport/7.0.5/lib/active_support/json/decoding.rb#9 + # source://activesupport/7.2.0/lib/active_support/json/decoding.rb#9 def parse_json_times=(val); end - # source://activesupport/7.0.5/lib/active_support.rb#94 + # source://activesupport/7.2.0/lib/active_support.rb#99 def test_order; end - # source://activesupport/7.0.5/lib/active_support.rb#94 + # source://activesupport/7.2.0/lib/active_support.rb#99 def test_order=(val); end - # source://activesupport/7.0.5/lib/active_support.rb#95 + # source://activesupport/7.2.0/lib/active_support.rb#100 def test_parallelization_threshold; end - # source://activesupport/7.0.5/lib/active_support.rb#95 + # source://activesupport/7.2.0/lib/active_support.rb#100 def test_parallelization_threshold=(val); end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def time_precision(*_arg0, **_arg1, &_arg2); end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def time_precision=(arg); end - # source://activesupport/7.0.5/lib/active_support.rb#107 + # source://activesupport/7.2.0/lib/active_support.rb#113 def to_time_preserves_timezone; end - # source://activesupport/7.0.5/lib/active_support.rb#111 + # source://activesupport/7.2.0/lib/active_support.rb#117 def to_time_preserves_timezone=(value); end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def use_standard_json_time_format(*_arg0, **_arg1, &_arg2); end - # source://activesupport/7.0.5/lib/active_support/json/encoding.rb#8 + # source://activesupport/7.2.0/lib/active_support/json/encoding.rb#8 def use_standard_json_time_format=(arg); end - # source://activesupport/7.0.5/lib/active_support.rb#115 + # source://activesupport/7.2.0/lib/active_support.rb#127 def utc_to_local_returns_utc_offset_times; end - # source://activesupport/7.0.5/lib/active_support.rb#119 + # source://activesupport/7.2.0/lib/active_support.rb#131 def utc_to_local_returns_utc_offset_times=(value); end - # source://activesupport/7.0.5/lib/active_support/version.rb#7 + # source://activesupport/7.2.0/lib/active_support/version.rb#7 def version; end end end @@ -105,34 +109,28 @@ end # source://redis-activesupport//lib/active_support/cache/redis_store.rb#5 module ActiveSupport::Cache class << self - # source://activesupport/7.0.5/lib/active_support/cache.rb#100 + # source://activesupport/7.2.0/lib/active_support/cache.rb#111 def expand_cache_key(key, namespace = T.unsafe(nil)); end - # source://activesupport/7.0.5/lib/active_support/cache.rb#41 + # source://activesupport/7.2.0/lib/active_support/cache.rb#58 def format_version; end - # source://activesupport/7.0.5/lib/active_support/cache.rb#41 + # source://activesupport/7.2.0/lib/active_support/cache.rb#58 def format_version=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/cache.rb#68 + # source://activesupport/7.2.0/lib/active_support/cache.rb#85 def lookup_store(store = T.unsafe(nil), *parameters); end private - # source://activesupport/7.0.5/lib/active_support/cache.rb#112 + # source://activesupport/7.2.0/lib/active_support/cache.rb#123 def retrieve_cache_key(key); end - # source://activesupport/7.0.5/lib/active_support/cache.rb#124 + # source://activesupport/7.2.0/lib/active_support/cache.rb#135 def retrieve_store_class(store); end end end -# source://activesupport/7.0.5/lib/active_support/cache.rb#27 -ActiveSupport::Cache::DEFAULT_COMPRESS_LIMIT = T.let(T.unsafe(nil), Integer) - -# source://activesupport/7.0.5/lib/active_support/cache.rb#30 -ActiveSupport::Cache::OPTION_ALIASES = T.let(T.unsafe(nil), Hash) - # source://redis-activesupport//lib/active_support/cache/redis_store.rb#6 class ActiveSupport::Cache::RedisStore < ::ActiveSupport::Cache::Store # Instantiate the store. @@ -326,6 +324,3 @@ ActiveSupport::Cache::RedisStore::DEFAULT_ERROR_HANDLER = T.let(T.unsafe(nil), P # source://redis-activesupport//lib/active_support/cache/redis_store.rb#8 ActiveSupport::Cache::RedisStore::ERRORS_TO_RESCUE = T.let(T.unsafe(nil), Array) - -# source://activesupport/7.0.5/lib/active_support/cache.rb#25 -ActiveSupport::Cache::UNIVERSAL_OPTIONS = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/redis-client@0.22.2.rbi b/sorbet/rbi/gems/redis-client@0.22.2.rbi new file mode 100644 index 000000000..9ce3e2bb2 --- /dev/null +++ b/sorbet/rbi/gems/redis-client@0.22.2.rbi @@ -0,0 +1,1359 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `redis-client` gem. +# Please instead update this file by running `bin/tapioca gem redis-client`. + + +module Process + extend ::ConnectionPool::ForkTracker + extend ::RedisClient::PIDCache::CoreExt + extend ::ActiveSupport::ForkTracker::CoreExt +end + +# source://redis-client//lib/redis_client/version.rb#3 +class RedisClient + include ::RedisClient::Common + + # @return [RedisClient] a new instance of RedisClient + # + # source://redis-client//lib/redis_client.rb#188 + def initialize(config, **_arg1); end + + # source://redis-client//lib/redis_client.rb#335 + def blocking_call(timeout, *command, **kwargs); end + + # source://redis-client//lib/redis_client.rb#355 + def blocking_call_v(timeout, command); end + + # source://redis-client//lib/redis_client.rb#275 + def call(*command, **kwargs); end + + # source://redis-client//lib/redis_client.rb#305 + def call_once(*command, **kwargs); end + + # source://redis-client//lib/redis_client.rb#320 + def call_once_v(command); end + + # source://redis-client//lib/redis_client.rb#290 + def call_v(command); end + + # source://redis-client//lib/redis_client.rb#415 + def close; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client.rb#411 + def connected?; end + + # source://redis-client//lib/redis_client.rb#212 + def db; end + + # source://redis-client//lib/redis_client.rb#420 + def disable_reconnection(&block); end + + # source://redis-client//lib/redis_client.rb#216 + def host; end + + # source://redis-client//lib/redis_client.rb#393 + def hscan(key, *args, **kwargs, &block); end + + # source://redis-client//lib/redis_client.rb#204 + def id; end + + # source://redis-client//lib/redis_client.rb#195 + def inspect; end + + # source://redis-client//lib/redis_client.rb#267 + def measure_round_trip_delay; end + + # source://redis-client//lib/redis_client.rb#442 + def multi(watch: T.unsafe(nil), &block); end + + # source://redis-client//lib/redis_client.rb#232 + def password; end + + # source://redis-client//lib/redis_client.rb#224 + def path; end + + # @yield [pipeline] + # + # source://redis-client//lib/redis_client.rb#424 + def pipelined(exception: T.unsafe(nil)); end + + # source://redis-client//lib/redis_client.rb#220 + def port; end + + # source://redis-client//lib/redis_client.rb#261 + def pubsub; end + + # source://redis-client//lib/redis_client.rb#251 + def read_timeout=(timeout); end + + # source://redis-client//lib/redis_client.rb#375 + def scan(*args, **kwargs, &block); end + + # source://redis-client//lib/redis_client.rb#200 + def server_url; end + + # source://redis-client//lib/redis_client.rb#236 + def size; end + + # source://redis-client//lib/redis_client.rb#384 + def sscan(key, *args, **kwargs, &block); end + + # @yield [_self] + # @yieldparam _self [RedisClient] the object that the method was called on + # + # source://redis-client//lib/redis_client.rb#240 + def then(_options = T.unsafe(nil)); end + + # source://redis-client//lib/redis_client.rb#208 + def timeout; end + + # source://redis-client//lib/redis_client.rb#245 + def timeout=(timeout); end + + # source://redis-client//lib/redis_client.rb#228 + def username; end + + # @yield [_self] + # @yieldparam _self [RedisClient] the object that the method was called on + # + # source://redis-client//lib/redis_client.rb#240 + def with(_options = T.unsafe(nil)); end + + # source://redis-client//lib/redis_client.rb#256 + def write_timeout=(timeout); end + + # source://redis-client//lib/redis_client.rb#402 + def zscan(key, *args, **kwargs, &block); end + + private + + # @yield [transaction] + # + # source://redis-client//lib/redis_client.rb#649 + def build_transaction; end + + # source://redis-client//lib/redis_client.rb#737 + def connect; end + + # source://redis-client//lib/redis_client.rb#683 + def ensure_connected(retryable: T.unsafe(nil)); end + + # source://redis-client//lib/redis_client.rb#730 + def raw_connection; end + + # source://redis-client//lib/redis_client.rb#657 + def scan_list(cursor_index, command, &block); end + + # source://redis-client//lib/redis_client.rb#667 + def scan_pairs(cursor_index, command); end + + class << self + # source://redis-client//lib/redis_client.rb#165 + def config(**kwargs); end + + # source://redis-client//lib/redis_client.rb#33 + def default_driver; end + + # source://redis-client//lib/redis_client.rb#45 + def default_driver=(name); end + + # source://redis-client//lib/redis_client.rb#22 + def driver(name); end + + # source://redis-client//lib/redis_client.rb#173 + def new(arg = T.unsafe(nil), **kwargs); end + + # source://redis-client//lib/redis_client.rb#181 + def register(middleware); end + + # source://redis-client//lib/redis_client.rb#18 + def register_driver(name, &block); end + + # source://redis-client//lib/redis_client.rb#169 + def sentinel(**kwargs); end + end +end + +# source://redis-client//lib/redis_client.rb#144 +class RedisClient::AuthenticationError < ::RedisClient::CommandError; end + +# source://redis-client//lib/redis_client/middlewares.rb#4 +class RedisClient::BasicMiddleware + # @return [BasicMiddleware] a new instance of BasicMiddleware + # + # source://redis-client//lib/redis_client/middlewares.rb#7 + def initialize(client); end + + # @yield [command] + # + # source://redis-client//lib/redis_client/middlewares.rb#15 + def call(command, _config); end + + # @yield [command] + # + # source://redis-client//lib/redis_client/middlewares.rb#15 + def call_pipelined(command, _config); end + + # Returns the value of attribute client. + # + # source://redis-client//lib/redis_client/middlewares.rb#5 + def client; end + + # source://redis-client//lib/redis_client/middlewares.rb#11 + def connect(_config); end +end + +# source://redis-client//lib/redis_client.rb#108 +class RedisClient::CannotConnectError < ::RedisClient::ConnectionError; end + +# source://redis-client//lib/redis_client.rb#115 +class RedisClient::CheckoutTimeoutError < ::RedisClient::TimeoutError; end + +# source://redis-client//lib/redis_client/circuit_breaker.rb#4 +class RedisClient::CircuitBreaker + # @return [CircuitBreaker] a new instance of CircuitBreaker + # + # source://redis-client//lib/redis_client/circuit_breaker.rb#23 + def initialize(error_threshold:, error_timeout:, error_threshold_timeout: T.unsafe(nil), success_threshold: T.unsafe(nil)); end + + # Returns the value of attribute error_threshold. + # + # source://redis-client//lib/redis_client/circuit_breaker.rb#21 + def error_threshold; end + + # Returns the value of attribute error_threshold_timeout. + # + # source://redis-client//lib/redis_client/circuit_breaker.rb#21 + def error_threshold_timeout; end + + # Returns the value of attribute error_timeout. + # + # source://redis-client//lib/redis_client/circuit_breaker.rb#21 + def error_timeout; end + + # source://redis-client//lib/redis_client/circuit_breaker.rb#34 + def protect; end + + # Returns the value of attribute success_threshold. + # + # source://redis-client//lib/redis_client/circuit_breaker.rb#21 + def success_threshold; end + + private + + # source://redis-client//lib/redis_client/circuit_breaker.rb#80 + def record_error; end + + # source://redis-client//lib/redis_client/circuit_breaker.rb#95 + def record_success; end + + # source://redis-client//lib/redis_client/circuit_breaker.rb#65 + def refresh_state; end +end + +# source://redis-client//lib/redis_client/circuit_breaker.rb#5 +module RedisClient::CircuitBreaker::Middleware + # source://redis-client//lib/redis_client/circuit_breaker.rb#10 + def call(_command, config); end + + # source://redis-client//lib/redis_client/circuit_breaker.rb#14 + def call_pipelined(_commands, config); end + + # source://redis-client//lib/redis_client/circuit_breaker.rb#6 + def connect(config); end +end + +# source://redis-client//lib/redis_client/circuit_breaker.rb#19 +class RedisClient::CircuitBreaker::OpenCircuitError < ::RedisClient::CannotConnectError; end + +# source://redis-client//lib/redis_client/command_builder.rb#4 +module RedisClient::CommandBuilder + extend ::RedisClient::CommandBuilder + + # source://redis-client//lib/redis_client/command_builder.rb#8 + def generate(args, kwargs = T.unsafe(nil)); end +end + +# source://redis-client//lib/redis_client.rb#125 +class RedisClient::CommandError < ::RedisClient::Error + include ::RedisClient::HasCommand + + class << self + # source://redis-client//lib/redis_client.rb#129 + def parse(error_message); end + end +end + +# source://redis-client//lib/redis_client.rb#155 +RedisClient::CommandError::ERRORS = T.let(T.unsafe(nil), Hash) + +# source://redis-client//lib/redis_client.rb#55 +module RedisClient::Common + # source://redis-client//lib/redis_client.rb#59 + def initialize(config, id: T.unsafe(nil), connect_timeout: T.unsafe(nil), read_timeout: T.unsafe(nil), write_timeout: T.unsafe(nil)); end + + # Returns the value of attribute config. + # + # source://redis-client//lib/redis_client.rb#56 + def config; end + + # Returns the value of attribute connect_timeout. + # + # source://redis-client//lib/redis_client.rb#57 + def connect_timeout; end + + # Sets the attribute connect_timeout + # + # @param value the value to set the attribute connect_timeout to. + # + # source://redis-client//lib/redis_client.rb#57 + def connect_timeout=(_arg0); end + + # Returns the value of attribute id. + # + # source://redis-client//lib/redis_client.rb#56 + def id; end + + # Returns the value of attribute read_timeout. + # + # source://redis-client//lib/redis_client.rb#57 + def read_timeout; end + + # Sets the attribute read_timeout + # + # @param value the value to set the attribute read_timeout to. + # + # source://redis-client//lib/redis_client.rb#57 + def read_timeout=(_arg0); end + + # source://redis-client//lib/redis_client.rb#75 + def timeout=(timeout); end + + # Returns the value of attribute write_timeout. + # + # source://redis-client//lib/redis_client.rb#57 + def write_timeout; end + + # Sets the attribute write_timeout + # + # @param value the value to set the attribute write_timeout to. + # + # source://redis-client//lib/redis_client.rb#57 + def write_timeout=(_arg0); end +end + +# source://redis-client//lib/redis_client/config.rb#7 +class RedisClient::Config + include ::RedisClient::Config::Common + + # @return [Config] a new instance of Config + # + # source://redis-client//lib/redis_client/config.rb#185 + def initialize(url: T.unsafe(nil), host: T.unsafe(nil), port: T.unsafe(nil), path: T.unsafe(nil), username: T.unsafe(nil), password: T.unsafe(nil), **kwargs); end + + # Returns the value of attribute host. + # + # source://redis-client//lib/redis_client/config.rb#183 + def host; end + + # Returns the value of attribute path. + # + # source://redis-client//lib/redis_client/config.rb#183 + def path; end + + # Returns the value of attribute port. + # + # source://redis-client//lib/redis_client/config.rb#183 + def port; end +end + +# source://redis-client//lib/redis_client/config.rb#14 +module RedisClient::Config::Common + # source://redis-client//lib/redis_client/config.rb#21 + def initialize(username: T.unsafe(nil), password: T.unsafe(nil), db: T.unsafe(nil), id: T.unsafe(nil), timeout: T.unsafe(nil), read_timeout: T.unsafe(nil), write_timeout: T.unsafe(nil), connect_timeout: T.unsafe(nil), ssl: T.unsafe(nil), custom: T.unsafe(nil), ssl_params: T.unsafe(nil), driver: T.unsafe(nil), protocol: T.unsafe(nil), client_implementation: T.unsafe(nil), command_builder: T.unsafe(nil), inherit_socket: T.unsafe(nil), reconnect_attempts: T.unsafe(nil), middlewares: T.unsafe(nil), circuit_breaker: T.unsafe(nil)); end + + # Returns the value of attribute circuit_breaker. + # + # source://redis-client//lib/redis_client/config.rb#15 + def circuit_breaker; end + + # Returns the value of attribute command_builder. + # + # source://redis-client//lib/redis_client/config.rb#15 + def command_builder; end + + # Returns the value of attribute connect_timeout. + # + # source://redis-client//lib/redis_client/config.rb#15 + def connect_timeout; end + + # Returns the value of attribute connection_prelude. + # + # source://redis-client//lib/redis_client/config.rb#15 + def connection_prelude; end + + # Returns the value of attribute custom. + # + # source://redis-client//lib/redis_client/config.rb#15 + def custom; end + + # Returns the value of attribute db. + # + # source://redis-client//lib/redis_client/config.rb#15 + def db; end + + # Returns the value of attribute driver. + # + # source://redis-client//lib/redis_client/config.rb#15 + def driver; end + + # Returns the value of attribute id. + # + # source://redis-client//lib/redis_client/config.rb#15 + def id; end + + # Returns the value of attribute inherit_socket. + # + # source://redis-client//lib/redis_client/config.rb#15 + def inherit_socket; end + + # Returns the value of attribute middlewares_stack. + # + # source://redis-client//lib/redis_client/config.rb#15 + def middlewares_stack; end + + # source://redis-client//lib/redis_client/config.rb#107 + def new_client(**kwargs); end + + # source://redis-client//lib/redis_client/config.rb#102 + def new_pool(**kwargs); end + + # Returns the value of attribute password. + # + # source://redis-client//lib/redis_client/config.rb#15 + def password; end + + # Returns the value of attribute protocol. + # + # source://redis-client//lib/redis_client/config.rb#15 + def protocol; end + + # Returns the value of attribute read_timeout. + # + # source://redis-client//lib/redis_client/config.rb#15 + def read_timeout; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/config.rb#94 + def resolved?; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/config.rb#111 + def retry_connecting?(attempt, _error); end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/config.rb#98 + def sentinel?; end + + # source://redis-client//lib/redis_client/config.rb#129 + def server_url; end + + # Returns the value of attribute ssl. + # + # source://redis-client//lib/redis_client/config.rb#15 + def ssl; end + + # Returns the value of attribute ssl. + def ssl?; end + + # source://redis-client//lib/redis_client/config.rb#123 + def ssl_context; end + + # Returns the value of attribute ssl_params. + # + # source://redis-client//lib/redis_client/config.rb#15 + def ssl_params; end + + # source://redis-client//lib/redis_client/config.rb#90 + def username; end + + # Returns the value of attribute write_timeout. + # + # source://redis-client//lib/redis_client/config.rb#15 + def write_timeout; end + + private + + # source://redis-client//lib/redis_client/config.rb#152 + def build_connection_prelude; end +end + +# source://redis-client//lib/redis_client/config.rb#12 +RedisClient::Config::DEFAULT_DB = T.let(T.unsafe(nil), Integer) + +# source://redis-client//lib/redis_client/config.rb#9 +RedisClient::Config::DEFAULT_HOST = T.let(T.unsafe(nil), String) + +# source://redis-client//lib/redis_client/config.rb#10 +RedisClient::Config::DEFAULT_PORT = T.let(T.unsafe(nil), Integer) + +# source://redis-client//lib/redis_client/config.rb#8 +RedisClient::Config::DEFAULT_TIMEOUT = T.let(T.unsafe(nil), Float) + +# source://redis-client//lib/redis_client/config.rb#11 +RedisClient::Config::DEFAULT_USERNAME = T.let(T.unsafe(nil), String) + +# source://redis-client//lib/redis_client.rb#107 +class RedisClient::ConnectionError < ::RedisClient::Error; end + +# source://redis-client//lib/redis_client/connection_mixin.rb#4 +module RedisClient::ConnectionMixin + # source://redis-client//lib/redis_client/connection_mixin.rb#5 + def initialize; end + + # source://redis-client//lib/redis_client/connection_mixin.rb#28 + def call(command, timeout); end + + # source://redis-client//lib/redis_client/connection_mixin.rb#42 + def call_pipelined(commands, timeouts, exception: T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/connection_mixin.rb#14 + def close; end + + # source://redis-client//lib/redis_client/connection_mixin.rb#77 + def connection_timeout(timeout); end + + # source://redis-client//lib/redis_client/connection_mixin.rb#9 + def reconnect; end + + # source://redis-client//lib/redis_client/connection_mixin.rb#19 + def revalidate; end +end + +# source://redis-client//lib/redis_client/decorator.rb#4 +module RedisClient::Decorator + class << self + # source://redis-client//lib/redis_client/decorator.rb#6 + def create(commands_mixin); end + end +end + +# source://redis-client//lib/redis_client/decorator.rb#37 +class RedisClient::Decorator::Client + include ::RedisClient::Decorator::CommandsMixin + + # @return [Client] a new instance of Client + # + # source://redis-client//lib/redis_client/decorator.rb#40 + def initialize(_client); end + + # source://redis-client//lib/redis_client/decorator.rb#60 + def close(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#69 + def config; end + + # source://redis-client//lib/redis_client/decorator.rb#69 + def connect_timeout; end + + # source://redis-client//lib/redis_client/decorator.rb#77 + def connect_timeout=(value); end + + # source://redis-client//lib/redis_client/decorator.rb#60 + def hscan(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#69 + def id; end + + # source://redis-client//lib/redis_client/decorator.rb#54 + def multi(**kwargs); end + + # source://redis-client//lib/redis_client/decorator.rb#50 + def pipelined(exception: T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/decorator.rb#69 + def pubsub; end + + # source://redis-client//lib/redis_client/decorator.rb#69 + def read_timeout; end + + # source://redis-client//lib/redis_client/decorator.rb#77 + def read_timeout=(value); end + + # source://redis-client//lib/redis_client/decorator.rb#60 + def scan(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#69 + def size; end + + # source://redis-client//lib/redis_client/decorator.rb#60 + def sscan(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#77 + def timeout=(value); end + + # source://redis-client//lib/redis_client/decorator.rb#45 + def with(*args, **_arg1); end + + # source://redis-client//lib/redis_client/decorator.rb#69 + def write_timeout; end + + # source://redis-client//lib/redis_client/decorator.rb#77 + def write_timeout=(value); end + + # source://redis-client//lib/redis_client/decorator.rb#60 + def zscan(*args, **_arg1, &block); end +end + +# source://redis-client//lib/redis_client/decorator.rb#18 +module RedisClient::Decorator::CommandsMixin + # source://redis-client//lib/redis_client/decorator.rb#19 + def initialize(client); end + + # source://redis-client//lib/redis_client/decorator.rb#25 + def blocking_call(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#25 + def blocking_call_v(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#25 + def call(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#25 + def call_once(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#25 + def call_once_v(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/decorator.rb#25 + def call_v(*args, **_arg1, &block); end +end + +# source://redis-client//lib/redis_client/decorator.rb#33 +class RedisClient::Decorator::Pipeline + include ::RedisClient::Decorator::CommandsMixin +end + +# source://redis-client//lib/redis_client.rb#94 +class RedisClient::Error < ::StandardError + include ::RedisClient::HasConfig + + class << self + # source://redis-client//lib/redis_client.rb#97 + def with_config(message, config = T.unsafe(nil)); end + end +end + +# source://redis-client//lib/redis_client.rb#110 +class RedisClient::FailoverError < ::RedisClient::ConnectionError; end + +# source://redis-client//lib/redis_client.rb#117 +module RedisClient::HasCommand + # source://redis-client//lib/redis_client.rb#120 + def _set_command(command); end + + # Returns the value of attribute command. + # + # source://redis-client//lib/redis_client.rb#118 + def command; end +end + +# source://redis-client//lib/redis_client.rb#80 +module RedisClient::HasConfig + # source://redis-client//lib/redis_client.rb#83 + def _set_config(config); end + + # Returns the value of attribute config. + # + # source://redis-client//lib/redis_client.rb#81 + def config; end + + # source://redis-client//lib/redis_client.rb#87 + def message; end +end + +# source://redis-client//lib/redis_client.rb#152 +class RedisClient::MasterDownError < ::RedisClient::ConnectionError + include ::RedisClient::HasCommand +end + +# source://redis-client//lib/redis_client/middlewares.rb#21 +class RedisClient::Middlewares < ::RedisClient::BasicMiddleware; end + +# source://redis-client//lib/redis_client.rb#523 +class RedisClient::Multi + # @return [Multi] a new instance of Multi + # + # source://redis-client//lib/redis_client.rb#524 + def initialize(command_builder); end + + # source://redis-client//lib/redis_client.rb#566 + def _blocks; end + + # source://redis-client//lib/redis_client.rb#586 + def _coerce!(results); end + + # source://redis-client//lib/redis_client.rb#562 + def _commands; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client.rb#574 + def _empty?; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client.rb#582 + def _retryable?; end + + # source://redis-client//lib/redis_client.rb#570 + def _size; end + + # source://redis-client//lib/redis_client.rb#578 + def _timeouts; end + + # source://redis-client//lib/redis_client.rb#532 + def call(*command, **kwargs, &block); end + + # source://redis-client//lib/redis_client.rb#546 + def call_once(*command, **kwargs, &block); end + + # source://redis-client//lib/redis_client.rb#554 + def call_once_v(command, &block); end + + # source://redis-client//lib/redis_client.rb#539 + def call_v(command, &block); end +end + +# source://redis-client//lib/redis_client.rb#147 +class RedisClient::OutOfMemoryError < ::RedisClient::CommandError; end + +# source://redis-client//lib/redis_client/pid_cache.rb#4 +module RedisClient::PIDCache + class << self + # Returns the value of attribute pid. + # + # source://redis-client//lib/redis_client/pid_cache.rb#10 + def pid; end + + # source://redis-client//lib/redis_client/pid_cache.rb#12 + def update!; end + end +end + +# source://redis-client//lib/redis_client/pid_cache.rb#18 +module RedisClient::PIDCache::CoreExt + # source://redis-client//lib/redis_client/pid_cache.rb#19 + def _fork; end +end + +# source://redis-client//lib/redis_client.rb#145 +class RedisClient::PermissionError < ::RedisClient::CommandError; end + +# source://redis-client//lib/redis_client.rb#602 +class RedisClient::Pipeline < ::RedisClient::Multi + # @return [Pipeline] a new instance of Pipeline + # + # source://redis-client//lib/redis_client.rb#603 + def initialize(_command_builder); end + + # source://redis-client//lib/redis_client.rb#634 + def _coerce!(results); end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client.rb#630 + def _empty?; end + + # source://redis-client//lib/redis_client.rb#626 + def _timeouts; end + + # source://redis-client//lib/redis_client.rb#608 + def blocking_call(timeout, *command, **kwargs, &block); end + + # source://redis-client//lib/redis_client.rb#617 + def blocking_call_v(timeout, command, &block); end +end + +# source://redis-client//lib/redis_client/pooled.rb#6 +class RedisClient::Pooled + include ::RedisClient::Common + + # @return [Pooled] a new instance of Pooled + # + # source://redis-client//lib/redis_client/pooled.rb#11 + def initialize(config, id: T.unsafe(nil), connect_timeout: T.unsafe(nil), read_timeout: T.unsafe(nil), write_timeout: T.unsafe(nil), **kwargs); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def blocking_call(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def blocking_call_v(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def call(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def call_once(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def call_once_v(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def call_v(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#37 + def close; end + + # source://redis-client//lib/redis_client/pooled.rb#65 + def hscan(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def multi(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def pipelined(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#56 + def pubsub(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#65 + def scan(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#48 + def size; end + + # source://redis-client//lib/redis_client/pooled.rb#65 + def sscan(*args, **_arg1, &block); end + + # source://redis-client//lib/redis_client/pooled.rb#25 + def then(options = T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/pooled.rb#25 + def with(options = T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/pooled.rb#65 + def zscan(*args, **_arg1, &block); end + + private + + # source://redis-client//lib/redis_client/pooled.rb#82 + def new_pool; end + + # source://redis-client//lib/redis_client/pooled.rb#78 + def pool; end +end + +# source://redis-client//lib/redis_client/pooled.rb#7 +RedisClient::Pooled::EMPTY_HASH = T.let(T.unsafe(nil), Hash) + +# source://redis-client//lib/redis_client.rb#104 +class RedisClient::ProtocolError < ::RedisClient::Error; end + +# source://redis-client//lib/redis_client.rb#486 +class RedisClient::PubSub + # @return [PubSub] a new instance of PubSub + # + # source://redis-client//lib/redis_client.rb#487 + def initialize(raw_connection, command_builder); end + + # source://redis-client//lib/redis_client.rb#492 + def call(*command, **kwargs); end + + # source://redis-client//lib/redis_client.rb#497 + def call_v(command); end + + # source://redis-client//lib/redis_client.rb#502 + def close; end + + # source://redis-client//lib/redis_client.rb#508 + def next_event(timeout = T.unsafe(nil)); end + + private + + # Returns the value of attribute raw_connection. + # + # source://redis-client//lib/redis_client.rb#520 + def raw_connection; end +end + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#4 +module RedisClient::RESP3 + private + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#36 + def dump(command, buffer = T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#57 + def dump_any(object, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#68 + def dump_array(array, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#84 + def dump_hash(hash, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#93 + def dump_numeric(numeric, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#76 + def dump_set(set, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#97 + def dump_string(string, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#103 + def dump_symbol(symbol, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#49 + def load(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#53 + def new_buffer; end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#112 + def parse(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#166 + def parse_array(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#218 + def parse_blob(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#155 + def parse_boolean(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#200 + def parse_double(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#151 + def parse_error(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#196 + def parse_integer(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#174 + def parse_map(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#213 + def parse_null(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#182 + def parse_push(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#186 + def parse_sequence(io, size); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#170 + def parse_set(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#145 + def parse_string(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#227 + def parse_verbatim_string(io); end + + class << self + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#36 + def dump(command, buffer = T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#57 + def dump_any(object, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#68 + def dump_array(array, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#84 + def dump_hash(hash, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#93 + def dump_numeric(numeric, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#76 + def dump_set(set, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#97 + def dump_string(string, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#103 + def dump_symbol(symbol, buffer); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#49 + def load(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#53 + def new_buffer; end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#112 + def parse(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#166 + def parse_array(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#218 + def parse_blob(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#155 + def parse_boolean(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#200 + def parse_double(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#151 + def parse_error(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#196 + def parse_integer(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#174 + def parse_map(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#213 + def parse_null(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#182 + def parse_push(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#186 + def parse_sequence(io, size); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#170 + def parse_set(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#145 + def parse_string(io); end + + # source://redis-client//lib/redis_client/ruby_connection/resp3.rb#227 + def parse_verbatim_string(io); end + end +end + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#13 +RedisClient::RESP3::DUMP_TYPES = T.let(T.unsafe(nil), Hash) + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#11 +RedisClient::RESP3::EOL = T.let(T.unsafe(nil), String) + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#12 +RedisClient::RESP3::EOL_SIZE = T.let(T.unsafe(nil), Integer) + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#7 +class RedisClient::RESP3::Error < ::RedisClient::Error; end + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#34 +RedisClient::RESP3::INTEGER_RANGE = T.let(T.unsafe(nil), Range) + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#19 +RedisClient::RESP3::PARSER_TYPES = T.let(T.unsafe(nil), Hash) + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#9 +class RedisClient::RESP3::SyntaxError < ::RedisClient::RESP3::Error; end + +# source://redis-client//lib/redis_client/ruby_connection/resp3.rb#8 +class RedisClient::RESP3::UnknownType < ::RedisClient::RESP3::Error; end + +# source://redis-client//lib/redis_client.rb#149 +class RedisClient::ReadOnlyError < ::RedisClient::ConnectionError + include ::RedisClient::HasCommand +end + +# source://redis-client//lib/redis_client.rb#113 +class RedisClient::ReadTimeoutError < ::RedisClient::TimeoutError; end + +# source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#6 +class RedisClient::RubyConnection + include ::RedisClient::ConnectionMixin + + # @return [RubyConnection] a new instance of RubyConnection + # + # source://redis-client//lib/redis_client/ruby_connection.rb#45 + def initialize(config, connect_timeout:, read_timeout:, write_timeout:); end + + # source://redis-client//lib/redis_client/ruby_connection.rb#58 + def close; end + + # Returns the value of attribute config. + # + # source://redis-client//lib/redis_client/ruby_connection.rb#43 + def config; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/ruby_connection.rb#54 + def connected?; end + + # source://redis-client//lib/redis_client/ruby_connection.rb#106 + def measure_round_trip_delay; end + + # source://redis-client//lib/redis_client/ruby_connection.rb#94 + def read(timeout = T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/ruby_connection.rb#63 + def read_timeout=(timeout); end + + # source://redis-client//lib/redis_client/ruby_connection.rb#73 + def write(command); end + + # source://redis-client//lib/redis_client/ruby_connection.rb#82 + def write_multi(commands); end + + # source://redis-client//lib/redis_client/ruby_connection.rb#68 + def write_timeout=(timeout); end + + private + + # source://redis-client//lib/redis_client/ruby_connection.rb#114 + def connect; end + + # unknown + # + # source://redis-client//lib/redis_client/ruby_connection.rb#165 + def enable_socket_keep_alive(socket); end + + class << self + # source://redis-client//lib/redis_client/ruby_connection.rb#14 + def ssl_context(ssl_params); end + end +end + +# source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#7 +class RedisClient::RubyConnection::BufferedIO + # @return [BufferedIO] a new instance of BufferedIO + # + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#16 + def initialize(io, read_timeout:, write_timeout:, chunk_size: T.unsafe(nil)); end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#89 + def close; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#93 + def closed?; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#97 + def eof?; end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#150 + def getbyte; end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#26 + def gets_chomp; end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#159 + def gets_integer; end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#37 + def read_chomp(bytes); end + + # Returns the value of attribute read_timeout. + # + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#11 + def read_timeout; end + + # Sets the attribute read_timeout + # + # @param value the value to set the attribute read_timeout to. + # + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#11 + def read_timeout=(_arg0); end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#121 + def skip(offset); end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#101 + def with_timeout(new_timeout); end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#127 + def write(string); end + + # Returns the value of attribute write_timeout. + # + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#11 + def write_timeout; end + + # Sets the attribute write_timeout + # + # @param value the value to set the attribute write_timeout to. + # + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#11 + def write_timeout=(_arg0); end + + private + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#44 + def ensure_line; end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#184 + def ensure_remaining(bytes); end + + # source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#191 + def fill_buffer(strict, size = T.unsafe(nil)); end +end + +# source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#14 +RedisClient::RubyConnection::BufferedIO::ENCODING = T.let(T.unsafe(nil), Encoding) + +# source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#8 +RedisClient::RubyConnection::BufferedIO::EOL = T.let(T.unsafe(nil), String) + +# source://redis-client//lib/redis_client/ruby_connection/buffered_io.rb#9 +RedisClient::RubyConnection::BufferedIO::EOL_SIZE = T.let(T.unsafe(nil), Integer) + +# Same as hiredis defaults +# +# source://redis-client//lib/redis_client/ruby_connection.rb#157 +RedisClient::RubyConnection::KEEP_ALIVE_INTERVAL = T.let(T.unsafe(nil), Integer) + +# source://redis-client//lib/redis_client/ruby_connection.rb#159 +RedisClient::RubyConnection::KEEP_ALIVE_PROBES = T.let(T.unsafe(nil), Integer) + +# Longer than hiredis defaults +# +# source://redis-client//lib/redis_client/ruby_connection.rb#158 +RedisClient::RubyConnection::KEEP_ALIVE_TTL = T.let(T.unsafe(nil), Integer) + +# source://redis-client//lib/redis_client/ruby_connection.rb#41 +RedisClient::RubyConnection::SUPPORTS_RESOLV_TIMEOUT = T.let(T.unsafe(nil), TrueClass) + +# source://redis-client//lib/redis_client/sentinel_config.rb#4 +class RedisClient::SentinelConfig + include ::RedisClient::Config::Common + + # @return [SentinelConfig] a new instance of SentinelConfig + # + # source://redis-client//lib/redis_client/sentinel_config.rb#12 + def initialize(sentinels:, sentinel_password: T.unsafe(nil), sentinel_username: T.unsafe(nil), role: T.unsafe(nil), name: T.unsafe(nil), url: T.unsafe(nil), **client_config); end + + # source://redis-client//lib/redis_client/sentinel_config.rb#101 + def check_role!(role); end + + # source://redis-client//lib/redis_client/sentinel_config.rb#80 + def host; end + + # Returns the value of attribute name. + # + # source://redis-client//lib/redis_client/sentinel_config.rb#10 + def name; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#88 + def path; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#84 + def port; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#74 + def reset; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/sentinel_config.rb#115 + def resolved?; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/sentinel_config.rb#92 + def retry_connecting?(attempt, error); end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/sentinel_config.rb#97 + def sentinel?; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#68 + def sentinels; end + + private + + # source://redis-client//lib/redis_client/sentinel_config.rb#134 + def config; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#181 + def each_sentinel; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#207 + def refresh_sentinels(sentinel_client); end + + # source://redis-client//lib/redis_client/sentinel_config.rb#144 + def resolve_master; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#163 + def resolve_replica; end + + # source://redis-client//lib/redis_client/sentinel_config.rb#159 + def sentinel_client(sentinel_config); end + + # source://redis-client//lib/redis_client/sentinel_config.rb#123 + def sentinels_to_configs(sentinels); end +end + +# source://redis-client//lib/redis_client/sentinel_config.rb#8 +RedisClient::SentinelConfig::DEFAULT_RECONNECT_ATTEMPTS = T.let(T.unsafe(nil), Integer) + +# source://redis-client//lib/redis_client/sentinel_config.rb#7 +RedisClient::SentinelConfig::SENTINEL_DELAY = T.let(T.unsafe(nil), Float) + +# source://redis-client//lib/redis_client.rb#112 +class RedisClient::TimeoutError < ::RedisClient::ConnectionError; end + +# source://redis-client//lib/redis_client/url_config.rb#6 +class RedisClient::URLConfig + # @return [URLConfig] a new instance of URLConfig + # + # source://redis-client//lib/redis_client/url_config.rb#9 + def initialize(url); end + + # source://redis-client//lib/redis_client/url_config.rb#30 + def db; end + + # source://redis-client//lib/redis_client/url_config.rb#56 + def host; end + + # source://redis-client//lib/redis_client/url_config.rb#48 + def password; end + + # source://redis-client//lib/redis_client/url_config.rb#62 + def path; end + + # source://redis-client//lib/redis_client/url_config.rb#68 + def port; end + + # @return [Boolean] + # + # source://redis-client//lib/redis_client/url_config.rb#26 + def ssl?; end + + # Returns the value of attribute uri. + # + # source://redis-client//lib/redis_client/url_config.rb#7 + def uri; end + + # Returns the value of attribute url. + # + # source://redis-client//lib/redis_client/url_config.rb#7 + def url; end + + # source://redis-client//lib/redis_client/url_config.rb#44 + def username; end +end + +# source://redis-client//lib/redis_client.rb#105 +class RedisClient::UnsupportedServer < ::RedisClient::Error; end + +# source://redis-client//lib/redis_client/version.rb#4 +RedisClient::VERSION = T.let(T.unsafe(nil), String) + +# source://redis-client//lib/redis_client.rb#114 +class RedisClient::WriteTimeoutError < ::RedisClient::TimeoutError; end + +# source://redis-client//lib/redis_client.rb#146 +class RedisClient::WrongTypeError < ::RedisClient::CommandError; end diff --git a/sorbet/rbi/gems/redis-rack-cache@2.2.1.rbi b/sorbet/rbi/gems/redis-rack-cache@2.2.1.rbi index 4c05cdcbf..25d0fc4ba 100644 --- a/sorbet/rbi/gems/redis-rack-cache@2.2.1.rbi +++ b/sorbet/rbi/gems/redis-rack-cache@2.2.1.rbi @@ -4,30 +4,25 @@ # This is an autogenerated file for types exported from the `redis-rack-cache` gem. # Please instead update this file by running `bin/tapioca gem redis-rack-cache`. + # source://redis-rack-cache//lib/rack/cache/redis_base.rb#4 module Rack class << self - # source://rack/2.2.7/lib/rack/version.rb#26 + # source://rack/2.2.9/lib/rack/version.rb#26 def release; end - # source://rack/2.2.7/lib/rack/version.rb#19 + # source://rack/2.2.9/lib/rack/version.rb#19 def version; end end end -# source://rack/2.2.7/lib/rack.rb#29 -Rack::CACHE_CONTROL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#31 -Rack::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#32 -Rack::CONTENT_TYPE = T.let(T.unsafe(nil), String) - # source://redis-rack-cache//lib/rack/cache/redis_base.rb#5 module Rack::Cache class << self - # source://rack-cache/1.13.0/lib/rack/cache.rb#42 + # source://rack-cache/1.17.0/lib/rack/cache/headers.rb#13 + def Headers(headers); end + + # source://rack-cache/1.17.0/lib/rack/cache.rb#42 def new(backend, options = T.unsafe(nil), &b); end end end @@ -36,40 +31,13 @@ end class Rack::Cache::EntityStore private - # source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#26 + # source://rack-cache/1.17.0/lib/rack/cache/entity_store.rb#26 def bytesize(string); end - # source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#14 + # source://rack-cache/1.17.0/lib/rack/cache/entity_store.rb#14 def slurp(body); end end -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#168 -Rack::Cache::EntityStore::DISK = Rack::Cache::EntityStore::Disk - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#169 -Rack::Cache::EntityStore::FILE = Rack::Cache::EntityStore::Disk - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#337 -Rack::Cache::EntityStore::GAE = Rack::Cache::EntityStore::GAEStore - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#336 -Rack::Cache::EntityStore::GAECACHE = Rack::Cache::EntityStore::GAEStore - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#79 -Rack::Cache::EntityStore::HEAP = Rack::Cache::EntityStore::Heap - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#80 -Rack::Cache::EntityStore::MEM = Rack::Cache::EntityStore::Heap - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#285 -Rack::Cache::EntityStore::MEMCACHE = Rack::Cache::EntityStore::Dalli - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#292 -Rack::Cache::EntityStore::MEMCACHED = Rack::Cache::EntityStore::Dalli - -# source://rack-cache/1.13.0/lib/rack/cache/entity_store.rb#374 -Rack::Cache::EntityStore::NOOP = Rack::Cache::EntityStore::Noop - # source://redis-rack-cache//lib/rack/cache/redis_entitystore.rb#92 Rack::Cache::EntityStore::REDIS = Rack::Cache::EntityStore::Redis @@ -132,71 +100,47 @@ Rack::Cache::EntityStore::Redis::MINIMUM_COMPRESSION_BYTESIZE = T.let(T.unsafe(n # source://redis-rack-cache//lib/rack/cache/redis_metastore.rb#9 class Rack::Cache::MetaStore - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#112 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#112 def cache_key(request); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#118 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#118 def invalidate(request, entity_store); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#28 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#28 def lookup(request, entity_store); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#61 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#62 def store(request, response, entity_store); end protected - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#187 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#185 def purge(key); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#174 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#172 def read(key); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#181 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#179 def write(key, negotiations, ttl = T.unsafe(nil)); end private - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#194 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#192 def hexdigest(data); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#140 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#138 def persist_request(request); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#153 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#151 def persist_response(response); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#161 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#159 def requests_match?(vary, env1, env2); end - # source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#148 + # source://rack-cache/1.17.0/lib/rack/cache/meta_store.rb#146 def restore_response(hash, body = T.unsafe(nil)); end end -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#291 -Rack::Cache::MetaStore::DISK = Rack::Cache::MetaStore::Disk - -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#292 -Rack::Cache::MetaStore::FILE = Rack::Cache::MetaStore::Disk - -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#441 -Rack::Cache::MetaStore::GAE = Rack::Cache::MetaStore::GAEStore - -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#440 -Rack::Cache::MetaStore::GAECACHE = Rack::Cache::MetaStore::GAEStore - -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#233 -Rack::Cache::MetaStore::HEAP = Rack::Cache::MetaStore::Heap - -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#234 -Rack::Cache::MetaStore::MEM = Rack::Cache::MetaStore::Heap - -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#402 -Rack::Cache::MetaStore::MEMCACHE = Rack::Cache::MetaStore::Dalli - -# source://rack-cache/1.13.0/lib/rack/cache/meta_store.rb#408 -Rack::Cache::MetaStore::MEMCACHED = Rack::Cache::MetaStore::Dalli - # source://redis-rack-cache//lib/rack/cache/redis_metastore.rb#28 Rack::Cache::MetaStore::REDIS = Rack::Cache::MetaStore::Redis @@ -253,180 +197,6 @@ module Rack::Cache::RedisBase::ClassMethods def resolve(uri, options = T.unsafe(nil)); end end -# source://rack/2.2.7/lib/rack.rb#43 -Rack::DELETE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#36 -Rack::ETAG = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#30 -Rack::EXPIRES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/file.rb#6 -Rack::File = Rack::Files - -# source://rack/2.2.7/lib/rack.rb#39 -Rack::GET = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#44 -Rack::HEAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#20 -Rack::HTTPS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#35 -Rack::HTTP_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#17 -Rack::HTTP_HOST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#18 -Rack::HTTP_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#19 -Rack::HTTP_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#46 -Rack::LINK = T.let(T.unsafe(nil), String) - -# source://rack-test/2.1.0/lib/rack/test.rb#381 -Rack::MockSession = Rack::Test::Session - -# source://rack/2.2.7/lib/rack.rb#45 -Rack::OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#42 -Rack::PATCH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#21 -Rack::PATH_INFO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#40 -Rack::POST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#41 -Rack::PUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#25 -Rack::QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#53 -Rack::RACK_ERRORS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#63 -Rack::RACK_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#65 -Rack::RACK_HIJACK_IO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#55 -Rack::RACK_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#64 -Rack::RACK_IS_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#54 -Rack::RACK_LOGGER = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#76 -Rack::RACK_METHODOVERRIDE_ORIGINAL_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#67 -Rack::RACK_MULTIPART_BUFFER_SIZE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#68 -Rack::RACK_MULTIPART_TEMPFILE_FACTORY = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#60 -Rack::RACK_MULTIPROCESS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#59 -Rack::RACK_MULTITHREAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#66 -Rack::RACK_RECURSIVE_INCLUDE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#72 -Rack::RACK_REQUEST_COOKIE_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#73 -Rack::RACK_REQUEST_COOKIE_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#70 -Rack::RACK_REQUEST_FORM_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#69 -Rack::RACK_REQUEST_FORM_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#71 -Rack::RACK_REQUEST_FORM_VARS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#74 -Rack::RACK_REQUEST_QUERY_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#75 -Rack::RACK_REQUEST_QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#61 -Rack::RACK_RUNONCE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#56 -Rack::RACK_SESSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#57 -Rack::RACK_SESSION_OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#77 -Rack::RACK_SESSION_UNPACKED_COOKIE_DATA = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#58 -Rack::RACK_SHOWSTATUS_DETAIL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#52 -Rack::RACK_TEMPFILES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#62 -Rack::RACK_URL_SCHEME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#51 -Rack::RACK_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#23 -Rack::RELEASE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#22 -Rack::REQUEST_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#23 -Rack::REQUEST_PATH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#24 -Rack::SCRIPT_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#27 -Rack::SERVER_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#28 -Rack::SERVER_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#26 -Rack::SERVER_PROTOCOL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#33 -Rack::SET_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#48 -Rack::TRACE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#34 -Rack::TRANSFER_ENCODING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#47 -Rack::UNLINK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#16 -Rack::VERSION = T.let(T.unsafe(nil), Array) - # source://redis-rack-cache//lib/redis-rack-cache/constants.rb#1 class Redis include ::Redis::Commands::Bitmaps @@ -446,107 +216,77 @@ class Redis include ::Redis::Commands::Strings include ::Redis::Commands::Transactions - # source://redis/4.8.1/lib/redis.rb#83 + # source://redis/5.2.0/lib/redis.rb#63 def initialize(options = T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#160 + # source://redis/5.2.0/lib/redis.rb#98 def _client; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def close; end - # source://redis/4.8.1/lib/redis.rb#140 - def commit; end - - # source://redis/4.8.1/lib/redis.rb#105 + # source://redis/5.2.0/lib/redis.rb#83 def connected?; end - # source://redis/4.8.1/lib/redis.rb#250 + # source://redis/5.2.0/lib/redis.rb#122 def connection; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def disconnect!; end - # source://redis/4.8.1/lib/redis.rb#246 + # source://redis/5.2.0/lib/redis.rb#118 def dup; end - # source://redis/4.8.1/lib/redis.rb#238 + # source://redis/5.2.0/lib/redis.rb#110 def id; end - # source://redis/4.8.1/lib/redis.rb#242 + # source://redis/5.2.0/lib/redis.rb#114 def inspect; end - # source://redis/4.8.1/lib/redis.rb#214 - def multi(&block); end - - # source://redis/4.8.1/lib/redis.rb#164 - def pipelined(&block); end - - # source://redis/4.8.1/lib/redis.rb#125 - def queue(*command); end + # source://redis/5.2.0/lib/redis.rb#102 + def pipelined(exception: T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#115 + # source://redis/5.2.0/lib/redis.rb#94 def with; end - # source://redis/4.8.1/lib/redis.rb#93 - def with_reconnect(val = T.unsafe(nil), &blk); end - - # source://redis/4.8.1/lib/redis.rb#100 - def without_reconnect(&blk); end + # source://redis/5.2.0/lib/redis.rb#78 + def without_reconnect(&block); end private - # source://redis/4.8.1/lib/redis.rb#280 + # source://redis/5.2.0/lib/redis.rb#164 def _subscription(method, timeout, channels, block); end - # source://redis/4.8.1/lib/redis.rb#274 + # source://redis/5.2.0/lib/redis.rb#134 + def initialize_client(options); end + + # source://redis/5.2.0/lib/redis.rb#158 def send_blocking_command(command, timeout, &block); end - # source://redis/4.8.1/lib/redis.rb#268 + # source://redis/5.2.0/lib/redis.rb#150 def send_command(command, &block); end - # source://redis/4.8.1/lib/redis.rb#264 + # source://redis/5.2.0/lib/redis.rb#146 def synchronize; end class << self - # source://redis/4.8.1/lib/redis.rb#40 - def current; end - - # source://redis/4.8.1/lib/redis.rb#45 - def current=(redis); end - - # source://redis/4.8.1/lib/redis.rb#30 + # source://redis/5.2.0/lib/redis.rb#14 def deprecate!(message); end - # source://redis/4.8.1/lib/redis.rb#15 - def exists_returns_integer; end - - # source://redis/4.8.1/lib/redis.rb#18 - def exists_returns_integer=(value); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations=(_arg0); end - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean; end - - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean=(_arg0); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations=(_arg0); end end end -# source://redis/4.8.1/lib/redis.rb#8 -Redis::BASE_PATH = T.let(T.unsafe(nil), String) - # source://redis-rack-cache//lib/redis-rack-cache/constants.rb#2 module Redis::Rack; end @@ -561,12 +301,6 @@ Redis::Rack::Cache::DEFAULT_TTL = T.let(T.unsafe(nil), Integer) # source://redis-rack-cache//lib/redis-rack-cache/version.rb#4 Redis::Rack::Cache::VERSION = T.let(T.unsafe(nil), String) -# source://redis-rack/2.1.4/lib/redis/rack/version.rb#3 -Redis::Rack::VERSION = T.let(T.unsafe(nil), String) - -# source://redis/4.8.1/lib/redis/version.rb#4 -Redis::VERSION = T.let(T.unsafe(nil), String) - # Compress data over the wire to Redis with GZip. This code was mostly # stolen from `Dalli::GzipCompressor`. # diff --git a/sorbet/rbi/gems/redis-rack@2.1.4.rbi b/sorbet/rbi/gems/redis-rack@2.1.4.rbi deleted file mode 100644 index 7fe47d1bb..000000000 --- a/sorbet/rbi/gems/redis-rack@2.1.4.rbi +++ /dev/null @@ -1,403 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `redis-rack` gem. -# Please instead update this file by running `bin/tapioca gem redis-rack`. - -# source://redis-rack//lib/rack/session/redis.rb#6 -module Rack - class << self - # source://rack/2.2.7/lib/rack/version.rb#26 - def release; end - - # source://rack/2.2.7/lib/rack/version.rb#19 - def version; end - end -end - -# source://rack/2.2.7/lib/rack.rb#29 -Rack::CACHE_CONTROL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#31 -Rack::CONTENT_LENGTH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#32 -Rack::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#43 -Rack::DELETE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#36 -Rack::ETAG = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#30 -Rack::EXPIRES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/file.rb#6 -Rack::File = Rack::Files - -# source://rack/2.2.7/lib/rack.rb#39 -Rack::GET = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#44 -Rack::HEAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#20 -Rack::HTTPS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#35 -Rack::HTTP_COOKIE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#17 -Rack::HTTP_HOST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#18 -Rack::HTTP_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#19 -Rack::HTTP_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#46 -Rack::LINK = T.let(T.unsafe(nil), String) - -# source://rack-test/2.1.0/lib/rack/test.rb#381 -Rack::MockSession = Rack::Test::Session - -# source://rack/2.2.7/lib/rack.rb#45 -Rack::OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#42 -Rack::PATCH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#21 -Rack::PATH_INFO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#40 -Rack::POST = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#41 -Rack::PUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#25 -Rack::QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#53 -Rack::RACK_ERRORS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#63 -Rack::RACK_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#65 -Rack::RACK_HIJACK_IO = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#55 -Rack::RACK_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#64 -Rack::RACK_IS_HIJACK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#54 -Rack::RACK_LOGGER = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#76 -Rack::RACK_METHODOVERRIDE_ORIGINAL_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#67 -Rack::RACK_MULTIPART_BUFFER_SIZE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#68 -Rack::RACK_MULTIPART_TEMPFILE_FACTORY = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#60 -Rack::RACK_MULTIPROCESS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#59 -Rack::RACK_MULTITHREAD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#66 -Rack::RACK_RECURSIVE_INCLUDE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#72 -Rack::RACK_REQUEST_COOKIE_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#73 -Rack::RACK_REQUEST_COOKIE_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#70 -Rack::RACK_REQUEST_FORM_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#69 -Rack::RACK_REQUEST_FORM_INPUT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#71 -Rack::RACK_REQUEST_FORM_VARS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#74 -Rack::RACK_REQUEST_QUERY_HASH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#75 -Rack::RACK_REQUEST_QUERY_STRING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#61 -Rack::RACK_RUNONCE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#56 -Rack::RACK_SESSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#57 -Rack::RACK_SESSION_OPTIONS = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#77 -Rack::RACK_SESSION_UNPACKED_COOKIE_DATA = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#58 -Rack::RACK_SHOWSTATUS_DETAIL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#52 -Rack::RACK_TEMPFILES = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#62 -Rack::RACK_URL_SCHEME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#51 -Rack::RACK_VERSION = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#23 -Rack::RELEASE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#22 -Rack::REQUEST_METHOD = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#23 -Rack::REQUEST_PATH = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#24 -Rack::SCRIPT_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#27 -Rack::SERVER_NAME = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#28 -Rack::SERVER_PORT = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#26 -Rack::SERVER_PROTOCOL = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#33 -Rack::SET_COOKIE = T.let(T.unsafe(nil), String) - -# source://redis-rack//lib/rack/session/redis.rb#7 -module Rack::Session; end - -# source://redis-rack//lib/rack/session/redis.rb#8 -class Rack::Session::Redis < ::Rack::Session::Abstract::PersistedSecure - # @return [Redis] a new instance of Redis - # - # source://redis-rack//lib/rack/session/redis.rb#15 - def initialize(app, options = T.unsafe(nil)); end - - # source://redis-rack//lib/rack/session/redis.rb#54 - def delete_session(req, sid, options); end - - # source://redis-rack//lib/rack/session/redis.rb#33 - def find_session(req, sid); end - - # source://redis-rack//lib/rack/session/redis.rb#22 - def generate_unique_sid(session); end - - # Returns the value of attribute mutex. - # - # source://redis-rack//lib/rack/session/redis.rb#9 - def mutex; end - - # @return [Boolean] - # - # source://redis-rack//lib/rack/session/redis.rb#64 - def threadsafe?; end - - # source://redis-rack//lib/rack/session/redis.rb#81 - def with(&block); end - - # source://redis-rack//lib/rack/session/redis.rb#68 - def with_lock(req, default = T.unsafe(nil)); end - - # source://redis-rack//lib/rack/session/redis.rb#47 - def write_session(req, sid, new_session, options = T.unsafe(nil)); end - - private - - # source://redis-rack//lib/rack/session/redis.rb#87 - def get_session_with_fallback(sid); end -end - -# source://redis-rack//lib/rack/session/redis.rb#11 -Rack::Session::Redis::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash) - -# source://rack/2.2.7/lib/rack.rb#48 -Rack::TRACE = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#34 -Rack::TRANSFER_ENCODING = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack.rb#47 -Rack::UNLINK = T.let(T.unsafe(nil), String) - -# source://rack/2.2.7/lib/rack/version.rb#16 -Rack::VERSION = T.let(T.unsafe(nil), Array) - -# source://redis-rack//lib/redis/rack/version.rb#1 -class Redis - include ::Redis::Commands::Bitmaps - include ::Redis::Commands::Cluster - include ::Redis::Commands::Connection - include ::Redis::Commands::Geo - include ::Redis::Commands::Hashes - include ::Redis::Commands::HyperLogLog - include ::Redis::Commands::Keys - include ::Redis::Commands::Lists - include ::Redis::Commands::Pubsub - include ::Redis::Commands::Scripting - include ::Redis::Commands::Server - include ::Redis::Commands::Sets - include ::Redis::Commands::SortedSets - include ::Redis::Commands::Streams - include ::Redis::Commands::Strings - include ::Redis::Commands::Transactions - - # source://redis/4.8.1/lib/redis.rb#83 - def initialize(options = T.unsafe(nil)); end - - # source://redis/4.8.1/lib/redis.rb#160 - def _client; end - - # source://redis/4.8.1/lib/redis.rb#110 - def close; end - - # source://redis/4.8.1/lib/redis.rb#140 - def commit; end - - # source://redis/4.8.1/lib/redis.rb#105 - def connected?; end - - # source://redis/4.8.1/lib/redis.rb#250 - def connection; end - - # source://redis/4.8.1/lib/redis.rb#110 - def disconnect!; end - - # source://redis/4.8.1/lib/redis.rb#246 - def dup; end - - # source://redis/4.8.1/lib/redis.rb#238 - def id; end - - # source://redis/4.8.1/lib/redis.rb#242 - def inspect; end - - # source://redis/4.8.1/lib/redis.rb#214 - def multi(&block); end - - # source://redis/4.8.1/lib/redis.rb#164 - def pipelined(&block); end - - # source://redis/4.8.1/lib/redis.rb#125 - def queue(*command); end - - # source://redis/4.8.1/lib/redis.rb#115 - def with; end - - # source://redis/4.8.1/lib/redis.rb#93 - def with_reconnect(val = T.unsafe(nil), &blk); end - - # source://redis/4.8.1/lib/redis.rb#100 - def without_reconnect(&blk); end - - private - - # source://redis/4.8.1/lib/redis.rb#280 - def _subscription(method, timeout, channels, block); end - - # source://redis/4.8.1/lib/redis.rb#274 - def send_blocking_command(command, timeout, &block); end - - # source://redis/4.8.1/lib/redis.rb#268 - def send_command(command, &block); end - - # source://redis/4.8.1/lib/redis.rb#264 - def synchronize; end - - class << self - # source://redis/4.8.1/lib/redis.rb#40 - def current; end - - # source://redis/4.8.1/lib/redis.rb#45 - def current=(redis); end - - # source://redis/4.8.1/lib/redis.rb#30 - def deprecate!(message); end - - # source://redis/4.8.1/lib/redis.rb#15 - def exists_returns_integer; end - - # source://redis/4.8.1/lib/redis.rb#18 - def exists_returns_integer=(value); end - - # source://redis/4.8.1/lib/redis.rb#16 - def raise_deprecations; end - - # source://redis/4.8.1/lib/redis.rb#16 - def raise_deprecations=(_arg0); end - - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean; end - - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean=(_arg0); end - - # source://redis/4.8.1/lib/redis.rb#16 - def silence_deprecations; end - - # source://redis/4.8.1/lib/redis.rb#16 - def silence_deprecations=(_arg0); end - end -end - -# source://redis/4.8.1/lib/redis.rb#8 -Redis::BASE_PATH = T.let(T.unsafe(nil), String) - -# source://redis-rack//lib/redis/rack/version.rb#2 -module Redis::Rack; end - -# source://redis-rack//lib/redis/rack/connection.rb#3 -class Redis::Rack::Connection - # @return [Connection] a new instance of Connection - # - # source://redis-rack//lib/redis/rack/connection.rb#6 - def initialize(options = T.unsafe(nil)); end - - # source://redis-rack//lib/redis/rack/connection.rb#34 - def pool; end - - # source://redis-rack//lib/redis/rack/connection.rb#42 - def pool_options; end - - # @return [Boolean] - # - # source://redis-rack//lib/redis/rack/connection.rb#28 - def pooled?; end - - # source://redis-rack//lib/redis/rack/connection.rb#38 - def store; end - - # source://redis-rack//lib/redis/rack/connection.rb#20 - def with(&block); end -end - -# source://redis-rack//lib/redis/rack/connection.rb#4 -Redis::Rack::Connection::POOL_KEYS = T.let(T.unsafe(nil), Array) - -# source://redis-rack//lib/redis/rack/version.rb#3 -Redis::Rack::VERSION = T.let(T.unsafe(nil), String) - -# source://redis/4.8.1/lib/redis/version.rb#4 -Redis::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/redis-rack@3.0.0.rbi b/sorbet/rbi/gems/redis-rack@3.0.0.rbi new file mode 100644 index 000000000..d5f6ed4ff --- /dev/null +++ b/sorbet/rbi/gems/redis-rack@3.0.0.rbi @@ -0,0 +1,188 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `redis-rack` gem. +# Please instead update this file by running `bin/tapioca gem redis-rack`. + + +# source://redis-rack//lib/rack/session/redis.rb#6 +module Rack + class << self + # source://rack/2.2.9/lib/rack/version.rb#26 + def release; end + + # source://rack/2.2.9/lib/rack/version.rb#19 + def version; end + end +end + +# source://redis-rack//lib/rack/session/redis.rb#7 +module Rack::Session; end + +# source://redis-rack//lib/rack/session/redis.rb#8 +class Rack::Session::Redis < ::Rack::Session::Abstract::PersistedSecure + # @return [Redis] a new instance of Redis + # + # source://redis-rack//lib/rack/session/redis.rb#15 + def initialize(app, options = T.unsafe(nil)); end + + # source://redis-rack//lib/rack/session/redis.rb#54 + def delete_session(req, sid, options); end + + # source://redis-rack//lib/rack/session/redis.rb#33 + def find_session(req, sid); end + + # source://redis-rack//lib/rack/session/redis.rb#22 + def generate_unique_sid(session); end + + # Returns the value of attribute mutex. + # + # source://redis-rack//lib/rack/session/redis.rb#9 + def mutex; end + + # @return [Boolean] + # + # source://redis-rack//lib/rack/session/redis.rb#64 + def threadsafe?; end + + # source://redis-rack//lib/rack/session/redis.rb#81 + def with(&block); end + + # source://redis-rack//lib/rack/session/redis.rb#68 + def with_lock(req, default = T.unsafe(nil)); end + + # source://redis-rack//lib/rack/session/redis.rb#47 + def write_session(req, sid, new_session, options = T.unsafe(nil)); end + + private + + # source://redis-rack//lib/rack/session/redis.rb#87 + def get_session_with_fallback(sid); end +end + +# source://redis-rack//lib/rack/session/redis.rb#11 +Rack::Session::Redis::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash) + +# source://redis-rack//lib/redis/rack/version.rb#1 +class Redis + include ::Redis::Commands::Bitmaps + include ::Redis::Commands::Cluster + include ::Redis::Commands::Connection + include ::Redis::Commands::Geo + include ::Redis::Commands::Hashes + include ::Redis::Commands::HyperLogLog + include ::Redis::Commands::Keys + include ::Redis::Commands::Lists + include ::Redis::Commands::Pubsub + include ::Redis::Commands::Scripting + include ::Redis::Commands::Server + include ::Redis::Commands::Sets + include ::Redis::Commands::SortedSets + include ::Redis::Commands::Streams + include ::Redis::Commands::Strings + include ::Redis::Commands::Transactions + + # source://redis/5.2.0/lib/redis.rb#63 + def initialize(options = T.unsafe(nil)); end + + # source://redis/5.2.0/lib/redis.rb#98 + def _client; end + + # source://redis/5.2.0/lib/redis.rb#88 + def close; end + + # source://redis/5.2.0/lib/redis.rb#83 + def connected?; end + + # source://redis/5.2.0/lib/redis.rb#122 + def connection; end + + # source://redis/5.2.0/lib/redis.rb#88 + def disconnect!; end + + # source://redis/5.2.0/lib/redis.rb#118 + def dup; end + + # source://redis/5.2.0/lib/redis.rb#110 + def id; end + + # source://redis/5.2.0/lib/redis.rb#114 + def inspect; end + + # source://redis/5.2.0/lib/redis.rb#102 + def pipelined(exception: T.unsafe(nil)); end + + # source://redis/5.2.0/lib/redis.rb#94 + def with; end + + # source://redis/5.2.0/lib/redis.rb#78 + def without_reconnect(&block); end + + private + + # source://redis/5.2.0/lib/redis.rb#164 + def _subscription(method, timeout, channels, block); end + + # source://redis/5.2.0/lib/redis.rb#134 + def initialize_client(options); end + + # source://redis/5.2.0/lib/redis.rb#158 + def send_blocking_command(command, timeout, &block); end + + # source://redis/5.2.0/lib/redis.rb#150 + def send_command(command, &block); end + + # source://redis/5.2.0/lib/redis.rb#146 + def synchronize; end + + class << self + # source://redis/5.2.0/lib/redis.rb#14 + def deprecate!(message); end + + # source://redis/5.2.0/lib/redis.rb#12 + def raise_deprecations; end + + # source://redis/5.2.0/lib/redis.rb#12 + def raise_deprecations=(_arg0); end + + # source://redis/5.2.0/lib/redis.rb#12 + def silence_deprecations; end + + # source://redis/5.2.0/lib/redis.rb#12 + def silence_deprecations=(_arg0); end + end +end + +# source://redis-rack//lib/redis/rack/version.rb#2 +module Redis::Rack; end + +# source://redis-rack//lib/redis/rack/connection.rb#3 +class Redis::Rack::Connection + # @return [Connection] a new instance of Connection + # + # source://redis-rack//lib/redis/rack/connection.rb#6 + def initialize(options = T.unsafe(nil)); end + + # source://redis-rack//lib/redis/rack/connection.rb#34 + def pool; end + + # source://redis-rack//lib/redis/rack/connection.rb#42 + def pool_options; end + + # @return [Boolean] + # + # source://redis-rack//lib/redis/rack/connection.rb#28 + def pooled?; end + + # source://redis-rack//lib/redis/rack/connection.rb#38 + def store; end + + # source://redis-rack//lib/redis/rack/connection.rb#20 + def with(&block); end +end + +# source://redis-rack//lib/redis/rack/connection.rb#4 +Redis::Rack::Connection::POOL_KEYS = T.let(T.unsafe(nil), Array) + +# source://redis-rack//lib/redis/rack/version.rb#3 +Redis::Rack::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/redis-rails@5.0.2.rbi b/sorbet/rbi/gems/redis-rails@5.0.2.rbi index 85eb7d79c..f8f138080 100644 --- a/sorbet/rbi/gems/redis-rails@5.0.2.rbi +++ b/sorbet/rbi/gems/redis-rails@5.0.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `redis-rails` gem. # Please instead update this file by running `bin/tapioca gem redis-rails`. + # source://redis-rails//lib/redis-rails/version.rb#1 class Redis include ::Redis::Commands::Bitmaps @@ -23,112 +24,79 @@ class Redis include ::Redis::Commands::Strings include ::Redis::Commands::Transactions - # source://redis/4.8.1/lib/redis.rb#83 + # source://redis/5.2.0/lib/redis.rb#63 def initialize(options = T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#160 + # source://redis/5.2.0/lib/redis.rb#98 def _client; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def close; end - # source://redis/4.8.1/lib/redis.rb#140 - def commit; end - - # source://redis/4.8.1/lib/redis.rb#105 + # source://redis/5.2.0/lib/redis.rb#83 def connected?; end - # source://redis/4.8.1/lib/redis.rb#250 + # source://redis/5.2.0/lib/redis.rb#122 def connection; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def disconnect!; end - # source://redis/4.8.1/lib/redis.rb#246 + # source://redis/5.2.0/lib/redis.rb#118 def dup; end - # source://redis/4.8.1/lib/redis.rb#238 + # source://redis/5.2.0/lib/redis.rb#110 def id; end - # source://redis/4.8.1/lib/redis.rb#242 + # source://redis/5.2.0/lib/redis.rb#114 def inspect; end - # source://redis/4.8.1/lib/redis.rb#214 - def multi(&block); end - - # source://redis/4.8.1/lib/redis.rb#164 - def pipelined(&block); end - - # source://redis/4.8.1/lib/redis.rb#125 - def queue(*command); end + # source://redis/5.2.0/lib/redis.rb#102 + def pipelined(exception: T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#115 + # source://redis/5.2.0/lib/redis.rb#94 def with; end - # source://redis/4.8.1/lib/redis.rb#93 - def with_reconnect(val = T.unsafe(nil), &blk); end - - # source://redis/4.8.1/lib/redis.rb#100 - def without_reconnect(&blk); end + # source://redis/5.2.0/lib/redis.rb#78 + def without_reconnect(&block); end private - # source://redis/4.8.1/lib/redis.rb#280 + # source://redis/5.2.0/lib/redis.rb#164 def _subscription(method, timeout, channels, block); end - # source://redis/4.8.1/lib/redis.rb#274 + # source://redis/5.2.0/lib/redis.rb#134 + def initialize_client(options); end + + # source://redis/5.2.0/lib/redis.rb#158 def send_blocking_command(command, timeout, &block); end - # source://redis/4.8.1/lib/redis.rb#268 + # source://redis/5.2.0/lib/redis.rb#150 def send_command(command, &block); end - # source://redis/4.8.1/lib/redis.rb#264 + # source://redis/5.2.0/lib/redis.rb#146 def synchronize; end class << self - # source://redis/4.8.1/lib/redis.rb#40 - def current; end - - # source://redis/4.8.1/lib/redis.rb#45 - def current=(redis); end - - # source://redis/4.8.1/lib/redis.rb#30 + # source://redis/5.2.0/lib/redis.rb#14 def deprecate!(message); end - # source://redis/4.8.1/lib/redis.rb#15 - def exists_returns_integer; end - - # source://redis/4.8.1/lib/redis.rb#18 - def exists_returns_integer=(value); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations=(_arg0); end - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean; end - - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean=(_arg0); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations=(_arg0); end end end -# source://redis/4.8.1/lib/redis.rb#8 -Redis::BASE_PATH = T.let(T.unsafe(nil), String) - # source://redis-rails//lib/redis-rails/version.rb#2 module Redis::Rails; end # source://redis-rails//lib/redis-rails/version.rb#3 Redis::Rails::VERSION = T.let(T.unsafe(nil), String) - -# source://redis/4.8.1/lib/redis/version.rb#4 -Redis::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/redis-store@1.9.2.rbi b/sorbet/rbi/gems/redis-store@1.11.0.rbi similarity index 76% rename from sorbet/rbi/gems/redis-store@1.9.2.rbi rename to sorbet/rbi/gems/redis-store@1.11.0.rbi index 43cba13a9..d3f548487 100644 --- a/sorbet/rbi/gems/redis-store@1.9.2.rbi +++ b/sorbet/rbi/gems/redis-store@1.11.0.rbi @@ -4,7 +4,8 @@ # This is an autogenerated file for types exported from the `redis-store` gem. # Please instead update this file by running `bin/tapioca gem redis-store`. -# source://redis-store//lib/redis/store/factory.rb#3 + +# source://redis-store//lib/redis/store/factory.rb#4 class Redis include ::Redis::Commands::Bitmaps include ::Redis::Commands::Cluster @@ -23,107 +24,77 @@ class Redis include ::Redis::Commands::Strings include ::Redis::Commands::Transactions - # source://redis/4.8.1/lib/redis.rb#83 + # source://redis/5.2.0/lib/redis.rb#63 def initialize(options = T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#160 + # source://redis/5.2.0/lib/redis.rb#98 def _client; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def close; end - # source://redis/4.8.1/lib/redis.rb#140 - def commit; end - - # source://redis/4.8.1/lib/redis.rb#105 + # source://redis/5.2.0/lib/redis.rb#83 def connected?; end - # source://redis/4.8.1/lib/redis.rb#250 + # source://redis/5.2.0/lib/redis.rb#122 def connection; end - # source://redis/4.8.1/lib/redis.rb#110 + # source://redis/5.2.0/lib/redis.rb#88 def disconnect!; end - # source://redis/4.8.1/lib/redis.rb#246 + # source://redis/5.2.0/lib/redis.rb#118 def dup; end - # source://redis/4.8.1/lib/redis.rb#238 + # source://redis/5.2.0/lib/redis.rb#110 def id; end - # source://redis/4.8.1/lib/redis.rb#242 + # source://redis/5.2.0/lib/redis.rb#114 def inspect; end - # source://redis/4.8.1/lib/redis.rb#214 - def multi(&block); end - - # source://redis/4.8.1/lib/redis.rb#164 - def pipelined(&block); end + # source://redis/5.2.0/lib/redis.rb#102 + def pipelined(exception: T.unsafe(nil)); end - # source://redis/4.8.1/lib/redis.rb#125 - def queue(*command); end - - # source://redis/4.8.1/lib/redis.rb#115 + # source://redis/5.2.0/lib/redis.rb#94 def with; end - # source://redis/4.8.1/lib/redis.rb#93 - def with_reconnect(val = T.unsafe(nil), &blk); end - - # source://redis/4.8.1/lib/redis.rb#100 - def without_reconnect(&blk); end + # source://redis/5.2.0/lib/redis.rb#78 + def without_reconnect(&block); end private - # source://redis/4.8.1/lib/redis.rb#280 + # source://redis/5.2.0/lib/redis.rb#164 def _subscription(method, timeout, channels, block); end - # source://redis/4.8.1/lib/redis.rb#274 + # source://redis/5.2.0/lib/redis.rb#134 + def initialize_client(options); end + + # source://redis/5.2.0/lib/redis.rb#158 def send_blocking_command(command, timeout, &block); end - # source://redis/4.8.1/lib/redis.rb#268 + # source://redis/5.2.0/lib/redis.rb#150 def send_command(command, &block); end - # source://redis/4.8.1/lib/redis.rb#264 + # source://redis/5.2.0/lib/redis.rb#146 def synchronize; end class << self - # source://redis/4.8.1/lib/redis.rb#40 - def current; end - - # source://redis/4.8.1/lib/redis.rb#45 - def current=(redis); end - - # source://redis/4.8.1/lib/redis.rb#30 + # source://redis/5.2.0/lib/redis.rb#14 def deprecate!(message); end - # source://redis/4.8.1/lib/redis.rb#15 - def exists_returns_integer; end - - # source://redis/4.8.1/lib/redis.rb#18 - def exists_returns_integer=(value); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def raise_deprecations=(_arg0); end - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean; end - - # source://redis/4.8.1/lib/redis.rb#16 - def sadd_returns_boolean=(_arg0); end - - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations; end - # source://redis/4.8.1/lib/redis.rb#16 + # source://redis/5.2.0/lib/redis.rb#12 def silence_deprecations=(_arg0); end end end -# source://redis/4.8.1/lib/redis.rb#8 -Redis::BASE_PATH = T.let(T.unsafe(nil), String) - # source://redis-store//lib/redis/distributed_store.rb#4 class Redis::DistributedStore < ::Redis::Distributed # @return [DistributedStore] a new instance of DistributedStore @@ -131,16 +102,16 @@ class Redis::DistributedStore < ::Redis::Distributed # source://redis-store//lib/redis/distributed_store.rb#8 def initialize(addresses, options = T.unsafe(nil)); end - # source://redis-store//lib/redis/distributed_store.rb#29 + # source://redis-store//lib/redis/distributed_store.rb#31 def get(key, options = T.unsafe(nil)); end - # source://redis-store//lib/redis/distributed_store.rb#17 + # source://redis-store//lib/redis/distributed_store.rb#19 def nodes; end - # source://redis-store//lib/redis/distributed_store.rb#21 + # source://redis-store//lib/redis/distributed_store.rb#23 def reconnect; end - # source://redis-store//lib/redis/distributed_store.rb#37 + # source://redis-store//lib/redis/distributed_store.rb#39 def redis_version; end # Returns the value of attribute ring. @@ -148,30 +119,30 @@ class Redis::DistributedStore < ::Redis::Distributed # source://redis-store//lib/redis/distributed_store.rb#6 def ring; end - # source://redis-store//lib/redis/distributed_store.rb#25 + # source://redis-store//lib/redis/distributed_store.rb#27 def set(key, value, options = T.unsafe(nil)); end - # source://redis-store//lib/redis/distributed_store.rb#49 + # source://redis-store//lib/redis/distributed_store.rb#51 def setex(key, expiry, value, options = T.unsafe(nil)); end - # source://redis-store//lib/redis/distributed_store.rb#33 + # source://redis-store//lib/redis/distributed_store.rb#35 def setnx(key, value, options = T.unsafe(nil)); end # @return [Boolean] # - # source://redis-store//lib/redis/distributed_store.rb#41 + # source://redis-store//lib/redis/distributed_store.rb#43 def supports_redis_version?(version); end private - # source://redis-store//lib/redis/distributed_store.rb#54 + # source://redis-store//lib/redis/distributed_store.rb#56 def _extend_namespace(options); end - # source://redis-store//lib/redis/distributed_store.rb#59 + # source://redis-store//lib/redis/distributed_store.rb#61 def _merge_options(address, options); end end -# source://redis-store//lib/redis/store/factory.rb#4 +# source://redis-store//lib/redis/store/factory.rb#5 class Redis::Store < ::Redis include ::Redis::Store::RedisVersion include ::Redis::Store::Interface @@ -182,65 +153,75 @@ class Redis::Store < ::Redis # source://redis-store//lib/redis/store.rb#16 def initialize(options = T.unsafe(nil)); end - # source://redis-store//lib/redis/store.rb#48 + # source://redis-store//lib/redis/store.rb#53 def location; end - # source://redis-store//lib/redis/store.rb#40 + # source://redis-store//lib/redis/store.rb#45 def reconnect; end - # source://redis-store//lib/redis/store.rb#44 + # source://redis-store//lib/redis/store.rb#49 def to_s; end private - # source://redis-store//lib/redis/store.rb#59 - def _extend_marshalling(options); end + # source://redis-store//lib/redis/store.rb#78 + def _extend_marshalling; end - # source://redis-store//lib/redis/store.rb#63 + # source://redis-store//lib/redis/store.rb#82 def _extend_namespace(options); end + + # source://redis-store//lib/redis/store.rb#64 + def _remove_unsupported_options(options); end + + class << self + # @return [Boolean] + # + # source://redis-store//lib/redis/store/version.rb#5 + def redis_client_defined?; end + end end -# source://redis-store//lib/redis/store/factory.rb#5 +# source://redis-store//lib/redis/store/factory.rb#6 class Redis::Store::Factory # @return [Factory] a new instance of Factory # - # source://redis-store//lib/redis/store/factory.rb#12 + # source://redis-store//lib/redis/store/factory.rb#13 def initialize(*options); end - # source://redis-store//lib/redis/store/factory.rb#18 + # source://redis-store//lib/redis/store/factory.rb#19 def create; end private - # source://redis-store//lib/redis/store/factory.rb#98 + # source://redis-store//lib/redis/store/factory.rb#106 def extract_addresses_and_options(*options); end class << self - # source://redis-store//lib/redis/store/factory.rb#8 + # source://redis-store//lib/redis/store/factory.rb#9 def create(*options); end - # source://redis-store//lib/redis/store/factory.rb#38 + # source://redis-store//lib/redis/store/factory.rb#39 def extract_host_options_from_hash(options); end - # source://redis-store//lib/redis/store/factory.rb#67 + # source://redis-store//lib/redis/store/factory.rb#68 def extract_host_options_from_uri(uri); end # @return [Boolean] # - # source://redis-store//lib/redis/store/factory.rb#63 + # source://redis-store//lib/redis/store/factory.rb#64 def host_options?(options); end - # source://redis-store//lib/redis/store/factory.rb#47 + # source://redis-store//lib/redis/store/factory.rb#48 def normalize_key_names(options); end # :api: private # - # source://redis-store//lib/redis/store/factory.rb#30 + # source://redis-store//lib/redis/store/factory.rb#31 def resolve(uri); end end end -# source://redis-store//lib/redis/store/factory.rb#6 +# source://redis-store//lib/redis/store/factory.rb#7 Redis::Store::Factory::DEFAULT_PORT = T.let(T.unsafe(nil), Integer) # source://redis-store//lib/redis/store/interface.rb#3 @@ -481,6 +462,3 @@ end # source://redis-store//lib/redis/store/version.rb#3 Redis::Store::VERSION = T.let(T.unsafe(nil), String) - -# source://redis/4.8.1/lib/redis/version.rb#4 -Redis::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/redis@4.8.1.rbi b/sorbet/rbi/gems/redis@5.2.0.rbi similarity index 69% rename from sorbet/rbi/gems/redis@4.8.1.rbi rename to sorbet/rbi/gems/redis@5.2.0.rbi index 53973d296..54bb4e00a 100644 --- a/sorbet/rbi/gems/redis@4.8.1.rbi +++ b/sorbet/rbi/gems/redis@5.2.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `redis` gem. # Please instead update this file by running `bin/tapioca gem redis`. + # source://redis//lib/redis/errors.rb#3 class Redis include ::Redis::Commands::Bitmaps @@ -41,946 +42,189 @@ class Redis # @option options # @option options # @option options - # @option options - # @option options - # @option options - # @option options - # @option options # @param options [Hash] # @return [Redis] a new client instance # - # source://redis//lib/redis.rb#83 + # source://redis//lib/redis.rb#63 def initialize(options = T.unsafe(nil)); end - # source://redis//lib/redis.rb#160 + # source://redis//lib/redis.rb#98 def _client; end # Disconnect the client as quickly and silently as possible. # - # source://redis//lib/redis.rb#110 + # source://redis//lib/redis.rb#88 def close; end - # See http://redis.io/topics/pipelining for more details. - # - # @deprecated Sends all commands in the queue. - # - # source://redis//lib/redis.rb#140 - def commit; end - # Test whether or not the client is connected # # @return [Boolean] # - # source://redis//lib/redis.rb#105 + # source://redis//lib/redis.rb#83 def connected?; end - # source://redis//lib/redis.rb#250 + # source://redis//lib/redis.rb#122 def connection; end # Disconnect the client as quickly and silently as possible. # - # source://redis//lib/redis.rb#110 + # source://redis//lib/redis.rb#88 def disconnect!; end - # source://redis//lib/redis.rb#246 + # source://redis//lib/redis.rb#118 def dup; end - # source://redis//lib/redis.rb#238 + # source://redis//lib/redis.rb#110 def id; end - # source://redis//lib/redis.rb#242 + # source://redis//lib/redis.rb#114 def inspect; end - # Mark the start of a transaction block. - # - # Passing a block is optional. - # - # @example With a block - # redis.multi do |multi| - # multi.set("key", "value") - # multi.incr("counter") - # end # => ["OK", 6] - # @example Without a block - # redis.multi - # # => "OK" - # redis.set("key", "value") - # # => "QUEUED" - # redis.incr("counter") - # # => "QUEUED" - # redis.exec - # # => ["OK", 6] - # @return [String, Array<...>] - when a block is not given, `OK` - # - when a block is given, an array with replies - # @see #watch - # @see #unwatch - # @yield [multi] the commands that are called inside this block are cached - # and written to the server upon returning from it - # @yieldparam multi [Redis] `self` - # - # source://redis//lib/redis.rb#214 - def multi(&block); end - - # source://redis//lib/redis.rb#164 - def pipelined(&block); end - - # Commands in the queue are executed with the Redis#commit method. - # - # See http://redis.io/topics/pipelining for more details. - # - # @deprecated Queues a command for pipelining. - # - # source://redis//lib/redis.rb#125 - def queue(*command); end + # source://redis//lib/redis.rb#102 + def pipelined(exception: T.unsafe(nil)); end # @yield [_self] # @yieldparam _self [Redis] the object that the method was called on # - # source://redis//lib/redis.rb#115 + # source://redis//lib/redis.rb#94 def with; end - # Run code with the client reconnecting - # - # source://redis//lib/redis.rb#93 - def with_reconnect(val = T.unsafe(nil), &blk); end - # Run code without the client reconnecting # - # source://redis//lib/redis.rb#100 - def without_reconnect(&blk); end + # source://redis//lib/redis.rb#78 + def without_reconnect(&block); end private - # source://redis//lib/redis.rb#280 + # source://redis//lib/redis.rb#164 def _subscription(method, timeout, channels, block); end - # source://redis//lib/redis.rb#274 + # source://redis//lib/redis.rb#134 + def initialize_client(options); end + + # source://redis//lib/redis.rb#158 def send_blocking_command(command, timeout, &block); end - # source://redis//lib/redis.rb#268 + # source://redis//lib/redis.rb#150 def send_command(command, &block); end - # source://redis//lib/redis.rb#264 + # source://redis//lib/redis.rb#146 def synchronize; end class << self - # source://redis//lib/redis.rb#40 - def current; end - - # source://redis//lib/redis.rb#45 - def current=(redis); end - - # source://redis//lib/redis.rb#30 + # source://redis//lib/redis.rb#14 def deprecate!(message); end - # Returns the value of attribute exists_returns_integer. - # - # source://redis//lib/redis.rb#15 - def exists_returns_integer; end - - # source://redis//lib/redis.rb#18 - def exists_returns_integer=(value); end - # Returns the value of attribute raise_deprecations. - # - # source://redis//lib/redis.rb#16 - def raise_deprecations; end - - # Sets the attribute raise_deprecations - # - # @param value the value to set the attribute raise_deprecations to. - # - # source://redis//lib/redis.rb#16 - def raise_deprecations=(_arg0); end - - # Returns the value of attribute sadd_returns_boolean. - # - # source://redis//lib/redis.rb#16 - def sadd_returns_boolean; end - - # Sets the attribute sadd_returns_boolean - # - # @param value the value to set the attribute sadd_returns_boolean to. - # - # source://redis//lib/redis.rb#16 - def sadd_returns_boolean=(_arg0); end - - # Returns the value of attribute silence_deprecations. - # - # source://redis//lib/redis.rb#16 - def silence_deprecations; end - - # Sets the attribute silence_deprecations - # - # @param value the value to set the attribute silence_deprecations to. - # - # source://redis//lib/redis.rb#16 - def silence_deprecations=(_arg0); end - end -end - -# source://redis//lib/redis.rb#8 -Redis::BASE_PATH = T.let(T.unsafe(nil), String) - -# Base error for connection related errors. -# -# source://redis//lib/redis/errors.rb#24 -class Redis::BaseConnectionError < ::Redis::BaseError; end - -# Base error for all redis-rb errors. -# -# source://redis//lib/redis/errors.rb#5 -class Redis::BaseError < ::RuntimeError; end - -# Raised when connection to a Redis server cannot be made. -# -# source://redis//lib/redis/errors.rb#28 -class Redis::CannotConnectError < ::Redis::BaseConnectionError; end - -# source://redis//lib/redis/client.rb#8 -class Redis::Client - # @return [Client] a new instance of Client - # - # source://redis//lib/redis/client.rb#91 - def initialize(options = T.unsafe(nil)); end - - # source://redis//lib/redis/client.rb#160 - def call(command); end - - # source://redis//lib/redis/client.rb#171 - def call_loop(command, timeout = T.unsafe(nil)); end - - # source://redis//lib/redis/client.rb#195 - def call_pipeline(pipeline); end - - # source://redis//lib/redis/client.rb#214 - def call_pipelined(pipeline); end - - # source://redis//lib/redis/client.rb#254 - def call_with_timeout(command, extra_timeout, &blk); end - - # source://redis//lib/redis/client.rb#263 - def call_without_timeout(command, &blk); end - - # source://redis//lib/redis/client.rb#288 - def close; end - - # Returns the value of attribute command_map. - # - # source://redis//lib/redis/client.rb#35 - def command_map; end - - # source://redis//lib/redis/client.rb#110 - def connect; end - - # source://redis//lib/redis/client.rb#57 - def connect_timeout; end - - # @return [Boolean] - # - # source://redis//lib/redis/client.rb#284 - def connected?; end - - # Returns the value of attribute connection. - # - # source://redis//lib/redis/client.rb#35 - def connection; end - - # source://redis//lib/redis/client.rb#73 - def db; end - - # source://redis//lib/redis/client.rb#77 - def db=(db); end - - # source://redis//lib/redis/client.rb#288 - def disconnect; end - - # source://redis//lib/redis/client.rb#81 - def driver; end - - # source://redis//lib/redis/client.rb#41 - def host; end - - # source://redis//lib/redis/client.rb#152 - def id; end - - # @return [Boolean] - # - # source://redis//lib/redis/client.rb#85 - def inherit_socket?; end - - # source://redis//lib/redis/client.rb#298 - def io; end - - # source://redis//lib/redis/client.rb#156 - def location; end - - # Returns the value of attribute logger. - # - # source://redis//lib/redis/client.rb#89 - def logger; end - - # Sets the attribute logger - # - # @param value the value to set the attribute logger to. - # - # source://redis//lib/redis/client.rb#89 - def logger=(_arg0); end - - # Returns the value of attribute options. - # - # source://redis//lib/redis/client.rb#35 - def options; end - - # source://redis//lib/redis/client.rb#69 - def password; end - - # source://redis//lib/redis/client.rb#49 - def path; end - - # source://redis//lib/redis/client.rb#45 - def port; end - - # source://redis//lib/redis/client.rb#267 - def process(commands); end - - # source://redis//lib/redis/client.rb#309 - def read; end - - # source://redis//lib/redis/client.rb#53 - def read_timeout; end - - # source://redis//lib/redis/client.rb#293 - def reconnect; end - - # source://redis//lib/redis/client.rb#37 - def scheme; end - - # source://redis//lib/redis/client.rb#61 - def timeout; end - - # source://redis//lib/redis/client.rb#65 - def username; end - - # source://redis//lib/redis/client.rb#342 - def with_reconnect(val = T.unsafe(nil)); end - - # source://redis//lib/redis/client.rb#324 - def with_socket_timeout(timeout); end - - # source://redis//lib/redis/client.rb#349 - def without_reconnect(&blk); end - - # source://redis//lib/redis/client.rb#338 - def without_socket_timeout(&blk); end - - # source://redis//lib/redis/client.rb#317 - def write(command); end - - protected - - # source://redis//lib/redis/client.rb#529 - def _parse_driver(driver); end - - # source://redis//lib/redis/client.rb#430 - def _parse_options(options); end - - # source://redis//lib/redis/client.rb#401 - def ensure_connected; end - - # source://redis//lib/redis/client.rb#379 - def establish_connection; end - - # source://redis//lib/redis/client.rb#355 - def logging(commands); end -end - -# source://redis//lib/redis/client.rb#549 -class Redis::Client::Connector - # @return [Connector] a new instance of Connector - # - # source://redis//lib/redis/client.rb#550 - def initialize(options); end - - # source://redis//lib/redis/client.rb#558 - def check(client); end - - # source://redis//lib/redis/client.rb#554 - def resolve; end -end - -# source://redis//lib/redis/client.rb#560 -class Redis::Client::Connector::Sentinel < ::Redis::Client::Connector - # @return [Sentinel] a new instance of Sentinel - # - # source://redis//lib/redis/client.rb#561 - def initialize(options); end - - # source://redis//lib/redis/client.rb#571 - def check(client); end - - # source://redis//lib/redis/client.rb#588 - def resolve; end - - # source://redis//lib/redis/client.rb#628 - def resolve_master; end - - # source://redis//lib/redis/client.rb#636 - def resolve_slave; end - - # @raise [CannotConnectError] - # - # source://redis//lib/redis/client.rb#601 - def sentinel_detect; end -end - -# Defaults are also used for converting string keys to symbols. -# -# source://redis//lib/redis/client.rb#10 -Redis::Client::DEFAULTS = T.let(T.unsafe(nil), Hash) - -# source://redis//lib/redis/errors.rb#47 -class Redis::Cluster - # @return [Cluster] a new instance of Cluster - # - # source://redis//lib/redis/cluster.rb#24 - def initialize(options = T.unsafe(nil)); end - - # source://redis//lib/redis/cluster.rb#71 - def call(command, &block); end - - # source://redis//lib/redis/cluster.rb#75 - def call_loop(command, timeout = T.unsafe(nil), &block); end - - # source://redis//lib/redis/cluster.rb#80 - def call_pipeline(pipeline); end - - # source://redis//lib/redis/cluster.rb#90 - def call_with_timeout(command, timeout, &block); end - - # source://redis//lib/redis/cluster.rb#95 - def call_without_timeout(command, &block); end - - # @return [Boolean] - # - # source://redis//lib/redis/cluster.rb#46 - def connected?; end - - # source://redis//lib/redis/cluster.rb#55 - def connection_info; end - - # db feature is disabled in cluster mode - # - # source://redis//lib/redis/cluster.rb#35 - def db; end - - # db feature is disabled in cluster mode - # - # source://redis//lib/redis/cluster.rb#40 - def db=(_db); end - - # source://redis//lib/redis/cluster.rb#50 - def disconnect; end - - # source://redis//lib/redis/cluster.rb#30 - def id; end - - # source://redis//lib/redis/cluster.rb#99 - def process(commands, &block); end - - # source://redis//lib/redis/cluster.rb#42 - def timeout; end - - # source://redis//lib/redis/cluster.rb#67 - def with_reconnect(val = T.unsafe(nil), &block); end - - private - - # source://redis//lib/redis/cluster.rb#242 - def _scan(command, &block); end - - # source://redis//lib/redis/cluster.rb#272 - def assign_asking_node(err_msg); end - - # source://redis//lib/redis/cluster.rb#277 - def assign_node(command); end - - # source://redis//lib/redis/cluster.rb#265 - def assign_redirection_node(err_msg); end - - # source://redis//lib/redis/cluster.rb#114 - def fetch_cluster_info!(option); end - - # source://redis//lib/redis/cluster.rb#125 - def fetch_command_details(nodes); end - - # source://redis//lib/redis/cluster.rb#296 - def find_node(node_key); end - - # source://redis//lib/redis/cluster.rb#282 - def find_node_key(command, primary_only: T.unsafe(nil)); end - - # source://redis//lib/redis/cluster.rb#175 - def send_client_command(command, &block); end - - # source://redis//lib/redis/cluster.rb#184 - def send_cluster_command(command, &block); end - - # source://redis//lib/redis/cluster.rb#130 - def send_command(command, &block); end - - # source://redis//lib/redis/cluster.rb#159 - def send_config_command(command, &block); end - - # source://redis//lib/redis/cluster.rb#167 - def send_memory_command(command, &block); end - - # source://redis//lib/redis/cluster.rb#205 - def send_pubsub_command(command, &block); end - - # source://redis//lib/redis/cluster.rb#195 - def send_script_command(command, &block); end - - # @see https://redis.io/topics/cluster-spec#redirection-and-resharding Redirection and resharding - # - # source://redis//lib/redis/cluster.rb#218 - def try_send(node, method_name, *args, retry_count: T.unsafe(nil), &block); end - - # source://redis//lib/redis/cluster.rb#305 - def update_cluster_info!(node_key = T.unsafe(nil)); end -end - -# Raised when cluster client can't select node. -# -# source://redis//lib/redis/errors.rb#83 -class Redis::Cluster::AmbiguousNodeError < ::Redis::BaseError - # @return [AmbiguousNodeError] a new instance of AmbiguousNodeError - # - # source://redis//lib/redis/errors.rb#84 - def initialize(command); end -end - -# Keep details about Redis commands for Redis Cluster Client. -# -# @see https://redis.io/commands/command -# -# source://redis//lib/redis/cluster/command.rb#9 -class Redis::Cluster::Command - # @return [Command] a new instance of Command - # - # source://redis//lib/redis/cluster/command.rb#10 - def initialize(details); end - - # source://redis//lib/redis/cluster/command.rb#14 - def extract_first_key(command); end - - # @return [Boolean] - # - # source://redis//lib/redis/cluster/command.rb#23 - def should_send_to_master?(command); end - - # @return [Boolean] - # - # source://redis//lib/redis/cluster/command.rb#27 - def should_send_to_slave?(command); end - - private - - # source://redis//lib/redis/cluster/command.rb#50 - def determine_first_key_position(command); end - - # source://redis//lib/redis/cluster/command.rb#63 - def determine_optional_key_position(command, option_name); end - - # source://redis//lib/redis/cluster/command.rb#43 - def dig_details(command, key); end - - # @see https://redis.io/topics/cluster-spec#keys-hash-tags Keys hash tags - # - # source://redis//lib/redis/cluster/command.rb#69 - def extract_hash_tag(key); end - - # source://redis//lib/redis/cluster/command.rb#33 - def pick_details(details); end -end - -# Raised when error occurs on any node of cluster. -# -# source://redis//lib/redis/errors.rb#71 -class Redis::Cluster::CommandErrorCollection < ::Redis::BaseError - # @param errors [Hash{String => Redis::CommandError}] - # @param error_message [String] - # @return [CommandErrorCollection] a new instance of CommandErrorCollection - # - # source://redis//lib/redis/errors.rb#76 - def initialize(errors, error_message = T.unsafe(nil)); end - - # Returns the value of attribute errors. - # - # source://redis//lib/redis/errors.rb#72 - def errors; end -end - -# Load details about Redis commands for Redis Cluster Client -# -# @see https://redis.io/commands/command -# -# source://redis//lib/redis/cluster/command_loader.rb#9 -module Redis::Cluster::CommandLoader - private - - # source://redis//lib/redis/cluster/command_loader.rb#24 - def fetch_command_details(node); end - - # source://redis//lib/redis/cluster/command_loader.rb#12 - def load(nodes); end - - class << self - # @raise [InitialSetupError] - # - # source://redis//lib/redis/cluster/command_loader.rb#12 - def load(nodes); end - - private - - # source://redis//lib/redis/cluster/command_loader.rb#24 - def fetch_command_details(node); end - end -end - -# Raised when commands in pipelining include cross slot keys. -# -# source://redis//lib/redis/errors.rb#90 -class Redis::Cluster::CrossSlotPipeliningError < ::Redis::BaseError - # @return [CrossSlotPipeliningError] a new instance of CrossSlotPipeliningError - # - # source://redis//lib/redis/errors.rb#91 - def initialize(keys); end -end - -# Raised when client connected to redis as cluster mode -# and failed to fetch cluster state information by commands. -# -# source://redis//lib/redis/errors.rb#50 -class Redis::Cluster::InitialSetupError < ::Redis::BaseError - # @param errors [Array] - # @return [InitialSetupError] a new instance of InitialSetupError - # - # source://redis//lib/redis/errors.rb#52 - def initialize(errors); end -end - -# source://redis//lib/redis/cluster/key_slot_converter.rb#17 -module Redis::Cluster::KeySlotConverter - private - - # Convert key into slot. - # - # @param key [String] the key of the redis command - # @return [Integer] slot number - # - # source://redis//lib/redis/cluster/key_slot_converter.rb#62 - def convert(key); end - - class << self - # Convert key into slot. - # - # @param key [String] the key of the redis command - # @return [Integer] slot number - # - # source://redis//lib/redis/cluster/key_slot_converter.rb#62 - def convert(key); end - end -end - -# source://redis//lib/redis/cluster/key_slot_converter.rb#53 -Redis::Cluster::KeySlotConverter::HASH_SLOTS = T.let(T.unsafe(nil), Integer) - -# source://redis//lib/redis/cluster/key_slot_converter.rb#18 -Redis::Cluster::KeySlotConverter::XMODEM_CRC16_LOOKUP = T.let(T.unsafe(nil), Array) - -# Keep client list of node for Redis Cluster Client -# -# source://redis//lib/redis/cluster/node.rb#8 -class Redis::Cluster::Node - include ::Enumerable - - # @return [Node] a new instance of Node - # - # source://redis//lib/redis/cluster/node.rb#15 - def initialize(options, node_flags = T.unsafe(nil), with_replica = T.unsafe(nil)); end - - # source://redis//lib/redis/cluster/node.rb#35 - def call_all(command, &block); end - - # source://redis//lib/redis/cluster/node.rb#39 - def call_master(command, &block); end - - # source://redis//lib/redis/cluster/node.rb#47 - def call_slave(command, &block); end - - # source://redis//lib/redis/cluster/node.rb#21 - def each(&block); end - - # source://redis//lib/redis/cluster/node.rb#29 - def find_by(node_key); end - - # source://redis//lib/redis/cluster/node.rb#57 - def process_all(commands, &block); end - - # source://redis//lib/redis/cluster/node.rb#25 - def sample; end - - # source://redis//lib/redis/cluster/node.rb#61 - def scale_reading_clients; end - - private - - # source://redis//lib/redis/cluster/node.rb#87 - def build_clients(options); end - - # @return [Boolean] - # - # source://redis//lib/redis/cluster/node.rb#79 - def master?(node_key); end - - # @return [Boolean] - # - # source://redis//lib/redis/cluster/node.rb#75 - def replica_disabled?; end - - # @return [Boolean] - # - # source://redis//lib/redis/cluster/node.rb#83 - def slave?(node_key); end - - # @raise [CommandErrorCollection] - # - # source://redis//lib/redis/cluster/node.rb#100 - def try_map; end -end - -# source://redis//lib/redis/cluster/node.rb#13 -Redis::Cluster::Node::ROLE_SLAVE = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/cluster/node.rb#11 -class Redis::Cluster::Node::ReloadNeeded < ::StandardError; end - -# Node key's format is `:`. -# It is different from node id. -# Node id is internal identifying code in Redis Cluster. -# -# source://redis//lib/redis/cluster/node_key.rb#8 -module Redis::Cluster::NodeKey - private - - # source://redis//lib/redis/cluster/node_key.rb#26 - def build_from_host_port(host, port); end - - # source://redis//lib/redis/cluster/node_key.rb#22 - def build_from_uri(uri); end - - # source://redis//lib/redis/cluster/node_key.rb#13 - def optionize(node_key); end - - # source://redis//lib/redis/cluster/node_key.rb#18 - def split(node_key); end - - class << self - # source://redis//lib/redis/cluster/node_key.rb#26 - def build_from_host_port(host, port); end - - # source://redis//lib/redis/cluster/node_key.rb#22 - def build_from_uri(uri); end - - # source://redis//lib/redis/cluster/node_key.rb#13 - def optionize(node_key); end - - # source://redis//lib/redis/cluster/node_key.rb#18 - def split(node_key); end - end -end - -# source://redis//lib/redis/cluster/node_key.rb#9 -Redis::Cluster::NodeKey::DELIMITER = T.let(T.unsafe(nil), String) - -# Load and hashify node info for Redis Cluster Client -# -# source://redis//lib/redis/cluster/node_loader.rb#8 -module Redis::Cluster::NodeLoader - private - - # source://redis//lib/redis/cluster/node_loader.rb#23 - def fetch_node_info(node); end - - # source://redis//lib/redis/cluster/node_loader.rb#11 - def load_flags(nodes); end - - class << self - # @raise [InitialSetupError] - # - # source://redis//lib/redis/cluster/node_loader.rb#11 - def load_flags(nodes); end - - private - - # source://redis//lib/redis/cluster/node_loader.rb#23 - def fetch_node_info(node); end - end -end - -# Keep options for Redis Cluster Client -# -# source://redis//lib/redis/cluster/option.rb#10 -class Redis::Cluster::Option - # @return [Option] a new instance of Option - # - # source://redis//lib/redis/cluster/option.rb#15 - def initialize(options); end - - # source://redis//lib/redis/cluster/option.rb#44 - def add_node(host, port); end - - # source://redis//lib/redis/cluster/option.rb#27 - def per_node_key; end - - # source://redis//lib/redis/cluster/option.rb#40 - def update_node(addrs); end - - # @return [Boolean] - # - # source://redis//lib/redis/cluster/option.rb#36 - def use_replica?; end - - private - - # Redis cluster node returns only host and port information. - # So we should complement additional information such as: - # scheme, username, password and so on. - # - # source://redis//lib/redis/cluster/option.rb#93 - def add_common_node_option_if_needed(options, node_opts, key); end - - # @raise [InvalidClientOptionError] - # - # source://redis//lib/redis/cluster/option.rb#50 - def build_node_options(addrs); end + # + # source://redis//lib/redis.rb#12 + def raise_deprecations; end - # source://redis//lib/redis/cluster/option.rb#56 - def parse_node_addr(addr); end + # Sets the attribute raise_deprecations + # + # @param value the value to set the attribute raise_deprecations to. + # + # source://redis//lib/redis.rb#12 + def raise_deprecations=(_arg0); end - # source://redis//lib/redis/cluster/option.rb#81 - def parse_node_option(addr); end + # Returns the value of attribute silence_deprecations. + # + # source://redis//lib/redis.rb#12 + def silence_deprecations; end - # source://redis//lib/redis/cluster/option.rb#67 - def parse_node_url(addr); end + # Sets the attribute silence_deprecations + # + # @param value the value to set the attribute silence_deprecations to. + # + # source://redis//lib/redis.rb#12 + def silence_deprecations=(_arg0); end + end end -# source://redis//lib/redis/cluster/option.rb#11 -Redis::Cluster::Option::DEFAULT_SCHEME = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/cluster/option.rb#12 -Redis::Cluster::Option::SECURE_SCHEME = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/cluster/option.rb#13 -Redis::Cluster::Option::VALID_SCHEMES = T.let(T.unsafe(nil), Array) +# source://redis//lib/redis.rb#8 +Redis::BASE_PATH = T.let(T.unsafe(nil), String) -# Raised when client connected to redis as cluster mode -# and some cluster subcommands were called. +# Base error for connection related errors. # -# source://redis//lib/redis/errors.rb#59 -class Redis::Cluster::OrchestrationCommandNotSupported < ::Redis::BaseError - # @return [OrchestrationCommandNotSupported] a new instance of OrchestrationCommandNotSupported - # - # source://redis//lib/redis/errors.rb#60 - def initialize(command, subcommand = T.unsafe(nil)); end -end +# source://redis//lib/redis/errors.rb#33 +class Redis::BaseConnectionError < ::Redis::BaseError; end -# Keep slot and node key map for Redis Cluster Client +# Base error for all redis-rb errors. # -# source://redis//lib/redis/cluster/slot.rb#6 -class Redis::Cluster::Slot - # @return [Slot] a new instance of Slot - # - # source://redis//lib/redis/cluster/slot.rb#9 - def initialize(available_slots, node_flags = T.unsafe(nil), with_replica = T.unsafe(nil)); end +# source://redis//lib/redis/errors.rb#5 +class Redis::BaseError < ::StandardError; end - # @return [Boolean] - # - # source://redis//lib/redis/cluster/slot.rb#15 - def exists?(slot); end +# Raised when connection to a Redis server cannot be made. +# +# source://redis//lib/redis/errors.rb#37 +class Redis::CannotConnectError < ::Redis::BaseConnectionError; end - # source://redis//lib/redis/cluster/slot.rb#19 - def find_node_key_of_master(slot); end +# source://redis//lib/redis/client.rb#6 +class Redis::Client < ::RedisClient + # source://redis//lib/redis/client.rb#95 + def blocking_call_v(timeout, command, &block); end - # source://redis//lib/redis/cluster/slot.rb#25 - def find_node_key_of_slave(slot); end + # source://redis//lib/redis/client.rb#89 + def call_v(command, &block); end - # source://redis//lib/redis/cluster/slot.rb#32 - def put(slot, node_key); end + # source://redis//lib/redis/client.rb#60 + def db; end - private + # source://redis//lib/redis/client.rb#64 + def host; end - # available_slots is mapping of node_key to list of slot ranges - # - # source://redis//lib/redis/cluster/slot.rb#61 - def build_slot_node_key_map(available_slots); end + # source://redis//lib/redis/client.rb#48 + def id; end - # @return [Boolean] - # - # source://redis//lib/redis/cluster/slot.rb#52 - def master?(node_key); end + # source://redis//lib/redis/client.rb#120 + def inherit_socket!; end - # @return [Boolean] - # - # source://redis//lib/redis/cluster/slot.rb#48 - def replica_disabled?; end + # source://redis//lib/redis/client.rb#114 + def multi(watch: T.unsafe(nil)); end - # @return [Boolean] - # - # source://redis//lib/redis/cluster/slot.rb#56 - def slave?(node_key); end -end + # source://redis//lib/redis/client.rb#80 + def password; end -# source://redis//lib/redis/cluster/slot.rb#7 -Redis::Cluster::Slot::ROLE_SLAVE = T.let(T.unsafe(nil), String) + # source://redis//lib/redis/client.rb#72 + def path; end -# Load and hashify slot info for Redis Cluster Client -# -# source://redis//lib/redis/cluster/slot_loader.rb#9 -module Redis::Cluster::SlotLoader - private + # source://redis//lib/redis/client.rb#108 + def pipelined(exception: T.unsafe(nil)); end - # source://redis//lib/redis/cluster/slot_loader.rb#24 - def fetch_slot_info(node); end + # source://redis//lib/redis/client.rb#68 + def port; end - # source://redis//lib/redis/cluster/slot_loader.rb#12 - def load(nodes); end + # source://redis//lib/redis/client.rb#52 + def server_url; end - # source://redis//lib/redis/cluster/slot_loader.rb#31 - def parse_slot_info(arr, default_ip:); end + # source://redis//lib/redis/client.rb#56 + def timeout; end - # source://redis//lib/redis/cluster/slot_loader.rb#37 - def stringify_node_key(arr, default_ip); end + # source://redis//lib/redis/client.rb#76 + def username; end class << self - # @raise [InitialSetupError] - # - # source://redis//lib/redis/cluster/slot_loader.rb#12 - def load(nodes); end + # source://redis//lib/redis/client.rb#22 + def config(**kwargs); end - private + # source://redis//lib/redis/client.rb#26 + def sentinel(**kwargs); end - # source://redis//lib/redis/cluster/slot_loader.rb#24 - def fetch_slot_info(node); end + # @raise [redis_error] + # + # source://redis//lib/redis/client.rb#30 + def translate_error!(error, mapping: T.unsafe(nil)); end - # source://redis//lib/redis/cluster/slot_loader.rb#31 - def parse_slot_info(arr, default_ip:); end + private - # source://redis//lib/redis/cluster/slot_loader.rb#37 - def stringify_node_key(arr, default_ip); end + # source://redis//lib/redis/client.rb#37 + def translate_error_class(error_class, mapping: T.unsafe(nil)); end end end +# source://redis//lib/redis/client.rb#7 +Redis::Client::ERROR_MAPPING = T.let(T.unsafe(nil), Hash) + # Raised by the client when command execution returns an error reply. # # source://redis//lib/redis/errors.rb#20 @@ -1014,7 +258,7 @@ module Redis::Commands # # Redis error replies are raised as Ruby exceptions. # - # source://redis//lib/redis/commands.rb#205 + # source://redis//lib/redis/commands.rb#202 def call(*command); end # Interact with the sentinel command (masters, master, slaves, failover) @@ -1023,12 +267,12 @@ module Redis::Commands # @param args [Array] depends on subcommand # @return [Array, Hash, String] depends on subcommand # - # source://redis//lib/redis/commands.rb#214 + # source://redis//lib/redis/commands.rb#211 def sentinel(subcommand, *args); end private - # source://redis//lib/redis/commands.rb#236 + # source://redis//lib/redis/commands.rb#233 def method_missing(*command); end end @@ -1039,10 +283,12 @@ module Redis::Commands::Bitmaps # @param key [String] # @param start [Integer] start index # @param stop [Integer] stop index + # @param scale [String, Symbol] the scale of the offset range + # e.g. 'BYTE' - interpreted as a range of bytes, 'BIT' - interpreted as a range of bits # @return [Integer] the number of bits set to 1 # - # source://redis//lib/redis/commands/bitmaps.rb#31 - def bitcount(key, start = T.unsafe(nil), stop = T.unsafe(nil)); end + # source://redis//lib/redis/commands/bitmaps.rb#33 + def bitcount(key, start = T.unsafe(nil), stop = T.unsafe(nil), scale: T.unsafe(nil)); end # Perform a bitwise operation between strings and store the resulting string in a key. # @@ -1051,7 +297,7 @@ module Redis::Commands::Bitmaps # @param keys [String, Array] one or more source keys to perform `operation` # @return [Integer] the length of the string stored in `destkey` # - # source://redis//lib/redis/commands/bitmaps.rb#41 + # source://redis//lib/redis/commands/bitmaps.rb#45 def bitop(operation, destkey, *keys); end # Return the position of the first bit set to 1 or 0 in a string. @@ -1060,12 +306,14 @@ module Redis::Commands::Bitmaps # @param bit [Integer] whether to look for the first 1 or 0 bit # @param start [Integer] start index # @param stop [Integer] stop index + # @param scale [String, Symbol] the scale of the offset range + # e.g. 'BYTE' - interpreted as a range of bytes, 'BIT' - interpreted as a range of bits # @raise [ArgumentError] # @return [Integer] the position of the first 1/0 bit. # -1 if looking for 1 and it is not found or start and stop are given. # - # source://redis//lib/redis/commands/bitmaps.rb#53 - def bitpos(key, bit, start = T.unsafe(nil), stop = T.unsafe(nil)); end + # source://redis//lib/redis/commands/bitmaps.rb#62 + def bitpos(key, bit, start = T.unsafe(nil), stop = T.unsafe(nil), scale: T.unsafe(nil)); end # Returns the bit value at offset in the string value stored at key. # @@ -1094,7 +342,7 @@ end # source://redis//lib/redis/commands.rb#42 Redis::Commands::Boolify = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#51 +# source://redis//lib/redis/commands.rb#46 Redis::Commands::BoolifySet = T.let(T.unsafe(nil), Proc) # source://redis//lib/redis/commands/cluster.rb#5 @@ -1104,7 +352,7 @@ module Redis::Commands::Cluster # @return [String] `'OK'` # @see https://redis.io/topics/cluster-spec#ask-redirection ASK redirection # - # source://redis//lib/redis/commands/cluster.rb#40 + # source://redis//lib/redis/commands/cluster.rb#23 def asking; end # Sends `CLUSTER *` command to random node and returns its reply. @@ -1150,7 +398,7 @@ module Redis::Commands::Connection # # @return [String] `OK` # - # source://redis//lib/redis/commands/connection.rb#46 + # source://redis//lib/redis/commands/connection.rb#43 def quit; end # Change the selected database for the current connection. @@ -1162,13 +410,13 @@ module Redis::Commands::Connection def select(db); end end -# source://redis//lib/redis/commands.rb#115 +# source://redis//lib/redis/commands.rb#110 Redis::Commands::EMPTY_STREAM_RESPONSE = T.let(T.unsafe(nil), Array) -# source://redis//lib/redis/commands.rb#78 +# source://redis//lib/redis/commands.rb#73 Redis::Commands::Floatify = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#91 +# source://redis//lib/redis/commands.rb#86 Redis::Commands::FloatifyPairs = T.let(T.unsafe(nil), Proc) # source://redis//lib/redis/commands/geo.rb#5 @@ -1251,7 +499,7 @@ module Redis::Commands::Hashes # @param field [String, Array] # @return [Integer] the number of fields that were removed from the hash # - # source://redis//lib/redis/commands/hashes.rb#154 + # source://redis//lib/redis/commands/hashes.rb#156 def hdel(key, *fields); end # Determine if a hash field exists. @@ -1260,7 +508,7 @@ module Redis::Commands::Hashes # @param field [String] # @return [Boolean] whether or not the field exists in the hash # - # source://redis//lib/redis/commands/hashes.rb#163 + # source://redis//lib/redis/commands/hashes.rb#166 def hexists(key, field); end # Get the value of a hash field. @@ -1277,7 +525,7 @@ module Redis::Commands::Hashes # @param key [String] # @return [Hash] # - # source://redis//lib/redis/commands/hashes.rb#207 + # source://redis//lib/redis/commands/hashes.rb#210 def hgetall(key); end # Increment the integer value of a hash field by the given integer number. @@ -1287,7 +535,7 @@ module Redis::Commands::Hashes # @param increment [Integer] # @return [Integer] value of the field after incrementing it # - # source://redis//lib/redis/commands/hashes.rb#173 + # source://redis//lib/redis/commands/hashes.rb#176 def hincrby(key, field, increment); end # Increment the numeric value of a hash field by the given float number. @@ -1297,7 +545,7 @@ module Redis::Commands::Hashes # @param increment [Float] # @return [Float] value of the field after incrementing it # - # source://redis//lib/redis/commands/hashes.rb#183 + # source://redis//lib/redis/commands/hashes.rb#186 def hincrbyfloat(key, field, increment); end # Get all the fields in a hash. @@ -1305,7 +553,7 @@ module Redis::Commands::Hashes # @param key [String] # @return [Array] # - # source://redis//lib/redis/commands/hashes.rb#191 + # source://redis//lib/redis/commands/hashes.rb#194 def hkeys(key); end # Get the number of fields in a hash. @@ -1361,7 +609,7 @@ module Redis::Commands::Hashes # - when `count` is specified and `:with_values` is not specified, an array of field names # - when `:with_values` is specified, an array with `[field, value]` pairs # - # source://redis//lib/redis/commands/hashes.rb#136 + # source://redis//lib/redis/commands/hashes.rb#138 def hrandfield(key, count = T.unsafe(nil), withvalues: T.unsafe(nil), with_values: T.unsafe(nil)); end # Scan a hash @@ -1373,7 +621,7 @@ module Redis::Commands::Hashes # - `:count => Integer`: return count keys at most per iteration # @return [String, Array<[String, String]>] the next cursor and all found keys # - # source://redis//lib/redis/commands/hashes.rb#222 + # source://redis//lib/redis/commands/hashes.rb#225 def hscan(key, cursor, **options); end # Scan a hash @@ -1385,7 +633,7 @@ module Redis::Commands::Hashes # - `:count => Integer`: return count keys at most per iteration # @return [Enumerator] an enumerator for all found keys # - # source://redis//lib/redis/commands/hashes.rb#239 + # source://redis//lib/redis/commands/hashes.rb#242 def hscan_each(key, **options, &block); end # Set one or more hash values. @@ -1415,7 +663,7 @@ module Redis::Commands::Hashes # @param key [String] # @return [Array] # - # source://redis//lib/redis/commands/hashes.rb#199 + # source://redis//lib/redis/commands/hashes.rb#202 def hvals(key); end # Get the values of all the given hash fields. @@ -1428,7 +676,7 @@ module Redis::Commands::Hashes # @return [Hash] a hash mapping the specified fields to their values # @see #hmget # - # source://redis//lib/redis/commands/hashes.rb#104 + # source://redis//lib/redis/commands/hashes.rb#105 def mapped_hmget(key, *fields); end # Set one or more hash values. @@ -1445,40 +693,40 @@ module Redis::Commands::Hashes def mapped_hmset(key, hash); end end -# source://redis//lib/redis/commands.rb#62 +# source://redis//lib/redis/commands.rb#57 Redis::Commands::Hashify = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#158 +# source://redis//lib/redis/commands.rb#155 Redis::Commands::HashifyClusterNodeInfo = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#187 +# source://redis//lib/redis/commands.rb#184 Redis::Commands::HashifyClusterNodes = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#191 +# source://redis//lib/redis/commands.rb#188 Redis::Commands::HashifyClusterSlaves = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#173 +# source://redis//lib/redis/commands.rb#170 Redis::Commands::HashifyClusterSlots = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#99 +# source://redis//lib/redis/commands.rb#94 Redis::Commands::HashifyInfo = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#124 +# source://redis//lib/redis/commands.rb#119 Redis::Commands::HashifyStreamAutoclaim = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#131 +# source://redis//lib/redis/commands.rb#128 Redis::Commands::HashifyStreamAutoclaimJustId = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#118 +# source://redis//lib/redis/commands.rb#113 Redis::Commands::HashifyStreamEntries = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#147 +# source://redis//lib/redis/commands.rb#144 Redis::Commands::HashifyStreamPendingDetails = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#138 +# source://redis//lib/redis/commands.rb#135 Redis::Commands::HashifyStreamPendings = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#106 +# source://redis//lib/redis/commands.rb#101 Redis::Commands::HashifyStreams = T.let(T.unsafe(nil), Proc) # source://redis//lib/redis/commands/hyper_log_log.rb#5 @@ -1516,9 +764,6 @@ end # source://redis//lib/redis/commands/keys.rb#5 module Redis::Commands::Keys - # source://redis//lib/redis/commands/keys.rb#269 - def _exists(*keys); end - # Copy a value from one key to another. # # @example Copy a value to another key @@ -1543,7 +788,7 @@ module Redis::Commands::Keys # @param replace [Boolean] removes the `destination` key before copying value to it # @return [Boolean] whether the key was copied or not # - # source://redis//lib/redis/commands/keys.rb#345 + # source://redis//lib/redis/commands/keys.rb#343 def copy(source, destination, db: T.unsafe(nil), replace: T.unsafe(nil)); end # Delete one or more keys. @@ -1551,7 +796,7 @@ module Redis::Commands::Keys # @param keys [String, Array] # @return [Integer] number of keys that were deleted # - # source://redis//lib/redis/commands/keys.rb#232 + # source://redis//lib/redis/commands/keys.rb#248 def del(*keys); end # Return a serialized version of the value stored at a key. @@ -1559,7 +804,7 @@ module Redis::Commands::Keys # @param key [String] # @return [String] serialized_value # - # source://redis//lib/redis/commands/keys.rb#183 + # source://redis//lib/redis/commands/keys.rb#199 def dump(key); end # Determine how many of the keys exists. @@ -1567,7 +812,7 @@ module Redis::Commands::Keys # @param keys [String, Array] # @return [Integer] # - # source://redis//lib/redis/commands/keys.rb#251 + # source://redis//lib/redis/commands/keys.rb#267 def exists(*keys); end # Determine if any of the keys exists. @@ -1575,7 +820,7 @@ module Redis::Commands::Keys # @param keys [String, Array] # @return [Boolean] # - # source://redis//lib/redis/commands/keys.rb#277 + # source://redis//lib/redis/commands/keys.rb#275 def exists?(*keys); end # Set a key's time to live in seconds. @@ -1604,12 +849,20 @@ module Redis::Commands::Keys # source://redis//lib/redis/commands/keys.rb#98 def expireat(key, unix_time, nx: T.unsafe(nil), xx: T.unsafe(nil), gt: T.unsafe(nil), lt: T.unsafe(nil)); end + # Get a key's expiry time specified as number of seconds from UNIX Epoch + # + # @param key [String] + # @return [Integer] expiry time specified as number of seconds from UNIX Epoch + # + # source://redis//lib/redis/commands/keys.rb#112 + def expiretime(key); end + # Find all keys matching the given pattern. # # @param pattern [String] # @return [Array] # - # source://redis//lib/redis/commands/keys.rb#287 + # source://redis//lib/redis/commands/keys.rb#285 def keys(pattern = T.unsafe(nil)); end # Transfer a key from the connected instance to another instance. @@ -1623,7 +876,7 @@ module Redis::Commands::Keys # - `:replace => Boolean`: Replace existing key on the remote instance. # @return [String] `"OK"` # - # source://redis//lib/redis/commands/keys.rb#214 + # source://redis//lib/redis/commands/keys.rb#230 def migrate(key, options); end # Move a key to another database. @@ -1645,10 +898,10 @@ module Redis::Commands::Keys # @param db [Integer] # @return [Boolean] whether the key was moved or not # - # source://redis//lib/redis/commands/keys.rb#316 + # source://redis//lib/redis/commands/keys.rb#314 def move(key, db); end - # source://redis//lib/redis/commands/keys.rb#353 + # source://redis//lib/redis/commands/keys.rb#351 def object(*args); end # Remove the expiration from a key. @@ -1669,7 +922,7 @@ module Redis::Commands::Keys # - `:lt => true`: Set expiry only when the new expiry is less than current one. # @return [Boolean] whether the timeout was set or not # - # source://redis//lib/redis/commands/keys.rb#134 + # source://redis//lib/redis/commands/keys.rb#142 def pexpire(key, milliseconds, nx: T.unsafe(nil), xx: T.unsafe(nil), gt: T.unsafe(nil), lt: T.unsafe(nil)); end # Set the expiration for a key as number of milliseconds from UNIX Epoch. @@ -1682,9 +935,17 @@ module Redis::Commands::Keys # - `:lt => true`: Set expiry only when the new expiry is less than current one. # @return [Boolean] whether the timeout was set or not # - # source://redis//lib/redis/commands/keys.rb#154 + # source://redis//lib/redis/commands/keys.rb#162 def pexpireat(key, ms_unix_time, nx: T.unsafe(nil), xx: T.unsafe(nil), gt: T.unsafe(nil), lt: T.unsafe(nil)); end + # Get a key's expiry time specified as number of milliseconds from UNIX Epoch + # + # @param key [String] + # @return [Integer] expiry time specified as number of milliseconds from UNIX Epoch + # + # source://redis//lib/redis/commands/keys.rb#176 + def pexpiretime(key); end + # Get the time to live (in milliseconds) for a key. # # In Redis 2.6 or older the command returns -1 if the key does not exist or if @@ -1698,14 +959,14 @@ module Redis::Commands::Keys # @param key [String] # @return [Integer] remaining time to live in milliseconds # - # source://redis//lib/redis/commands/keys.rb#175 + # source://redis//lib/redis/commands/keys.rb#191 def pttl(key); end # Return a random key from the keyspace. # # @return [String] # - # source://redis//lib/redis/commands/keys.rb#360 + # source://redis//lib/redis/commands/keys.rb#358 def randomkey; end # Rename a key. If the new key already exists it is overwritten. @@ -1714,7 +975,7 @@ module Redis::Commands::Keys # @param new_name [String] # @return [String] `OK` # - # source://redis//lib/redis/commands/keys.rb#369 + # source://redis//lib/redis/commands/keys.rb#367 def rename(old_name, new_name); end # Rename a key, only if the new key does not exist. @@ -1723,7 +984,7 @@ module Redis::Commands::Keys # @param new_name [String] # @return [Boolean] whether the key was renamed or not # - # source://redis//lib/redis/commands/keys.rb#378 + # source://redis//lib/redis/commands/keys.rb#376 def renamenx(old_name, new_name); end # Create a key using the serialized value, previously obtained using DUMP. @@ -1735,7 +996,7 @@ module Redis::Commands::Keys # @raise [Redis::CommandError] # @return [String] `"OK"` # - # source://redis//lib/redis/commands/keys.rb#196 + # source://redis//lib/redis/commands/keys.rb#212 def restore(key, ttl, serialized_value, replace: T.unsafe(nil)); end # Scan the keyspace @@ -1801,7 +1062,7 @@ module Redis::Commands::Keys # element specified in `:get` # - when `:store` is specified, the number of elements in the stored result # - # source://redis//lib/redis/commands/keys.rb#407 + # source://redis//lib/redis/commands/keys.rb#405 def sort(key, by: T.unsafe(nil), limit: T.unsafe(nil), get: T.unsafe(nil), order: T.unsafe(nil), store: T.unsafe(nil)); end # Get the time to live (in seconds) for a key. @@ -1817,7 +1078,7 @@ module Redis::Commands::Keys # @param key [String] # @return [Integer] remaining time to live in seconds. # - # source://redis//lib/redis/commands/keys.rb#120 + # source://redis//lib/redis/commands/keys.rb#128 def ttl(key); end # Determine the type stored at key. @@ -1825,7 +1086,7 @@ module Redis::Commands::Keys # @param key [String] # @return [String] `string`, `list`, `set`, `zset`, `hash` or `none` # - # source://redis//lib/redis/commands/keys.rb#437 + # source://redis//lib/redis/commands/keys.rb#435 def type(key); end # Unlink one or more keys. @@ -1833,12 +1094,12 @@ module Redis::Commands::Keys # @param keys [String, Array] # @return [Integer] number of keys that were unlinked # - # source://redis//lib/redis/commands/keys.rb#243 + # source://redis//lib/redis/commands/keys.rb#259 def unlink(*keys); end private - # source://redis//lib/redis/commands/keys.rb#443 + # source://redis//lib/redis/commands/keys.rb#441 def _scan(command, cursor, args, match: T.unsafe(nil), count: T.unsafe(nil), type: T.unsafe(nil), &block); end end @@ -1860,12 +1121,27 @@ module Redis::Commands::Lists # e.g. 'LEFT' - from head, 'RIGHT' - from tail # @param where_destination [String, Symbol] where to push the element to the source list # e.g. 'LEFT' - to head, 'RIGHT' - to tail - # @param options [Hash] - `:timeout => Numeric`: timeout in seconds, defaults to no timeout + # @param options [Hash] - `:timeout => [Float, Integer]`: timeout in seconds, defaults to no timeout # @return [nil, String] the element, or nil when the source key does not exist or the timeout expired # # source://redis//lib/redis/commands/lists.rb#55 def blmove(source, destination, where_source, where_destination, timeout: T.unsafe(nil)); end + # Pops one or more elements from the first non-empty list key from the list + # of provided key names. If lists are empty, blocks until timeout has passed. + # + # @example Popping a element + # redis.blmpop(1.0, 'list') + # #=> ['list', ['a']] + # @example With count option + # redis.blmpop(1.0, 'list', count: 2) + # #=> ['list', ['a', 'b']] + # @raise [ArgumentError] + # @return [Array>] list of popped elements or nil + # + # source://redis//lib/redis/commands/lists.rb#205 + def blmpop(timeout, *keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end + # Remove and get the first element in a list, or block until one is available. # # @example With timeout @@ -1880,7 +1156,7 @@ module Redis::Commands::Lists # # => ["list", "element"] # @param keys [String, Array] one or more keys to perform the # blocking pop on - # @param options [Hash] - `:timeout => Integer`: timeout in seconds, defaults to no timeout + # @param options [Hash] - `:timeout => [Float, Integer]`: timeout in seconds, defaults to no timeout # @return [nil, [String, String]] - `nil` when the operation timed out # - tuple of the list that was popped from and element was popped otherwise # @@ -1891,7 +1167,7 @@ module Redis::Commands::Lists # # @param keys [String, Array] one or more keys to perform the # blocking pop on - # @param options [Hash] - `:timeout => Integer`: timeout in seconds, defaults to no timeout + # @param options [Hash] - `:timeout => [Float, Integer]`: timeout in seconds, defaults to no timeout # @return [nil, [String, String]] - `nil` when the operation timed out # - tuple of the list that was popped from and element was popped otherwise # @see #blpop @@ -1904,12 +1180,12 @@ module Redis::Commands::Lists # # @param source [String] source key # @param destination [String] destination key - # @param options [Hash] - `:timeout => Integer`: timeout in seconds, defaults to no timeout + # @param options [Hash] - `:timeout => [Float, Integer]`: timeout in seconds, defaults to no timeout # @return [nil, String] - `nil` when the operation timed out # - the element was popped and pushed otherwise # # source://redis//lib/redis/commands/lists.rb#181 - def brpoplpush(source, destination, deprecated_timeout = T.unsafe(nil), timeout: T.unsafe(nil)); end + def brpoplpush(source, destination, timeout: T.unsafe(nil)); end # Get an element from a list by its index. # @@ -1917,7 +1193,7 @@ module Redis::Commands::Lists # @param index [Integer] # @return [String] # - # source://redis//lib/redis/commands/lists.rb#191 + # source://redis//lib/redis/commands/lists.rb#245 def lindex(key, index); end # Insert an element before or after another element in a list. @@ -1929,7 +1205,7 @@ module Redis::Commands::Lists # @return [Integer] length of the list after the insert operation, or `-1` # when the element `pivot` was not found # - # source://redis//lib/redis/commands/lists.rb#203 + # source://redis//lib/redis/commands/lists.rb#257 def linsert(key, where, pivot, value); end # Get the length of a list. @@ -1955,11 +1231,26 @@ module Redis::Commands::Lists # source://redis//lib/redis/commands/lists.rb#27 def lmove(source, destination, where_source, where_destination); end + # Pops one or more elements from the first non-empty list key from the list + # of provided key names. + # + # @example Popping a element + # redis.lmpop('list') + # #=> ['list', ['a']] + # @example With count option + # redis.lmpop('list', count: 2) + # #=> ['list', ['a', 'b']] + # @raise [ArgumentError] + # @return [Array>] list of popped elements or nil + # + # source://redis//lib/redis/commands/lists.rb#231 + def lmpop(*keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end + # Remove and get the first elements in a list. # # @param key [String] # @param count [Integer] number of elements to remove - # @return [String, Array] the values of the first elements + # @return [nil, String, Array] the values of the first elements # # source://redis//lib/redis/commands/lists.rb#103 def lpop(key, count = T.unsafe(nil)); end @@ -1989,7 +1280,7 @@ module Redis::Commands::Lists # @param stop [Integer] stop index # @return [Array] # - # source://redis//lib/redis/commands/lists.rb#213 + # source://redis//lib/redis/commands/lists.rb#267 def lrange(key, start, stop); end # Remove elements from a list. @@ -2002,7 +1293,7 @@ module Redis::Commands::Lists # @param value [String] # @return [Integer] the number of removed elements # - # source://redis//lib/redis/commands/lists.rb#226 + # source://redis//lib/redis/commands/lists.rb#280 def lrem(key, count, value); end # Set the value of an element in a list by its index. @@ -2012,7 +1303,7 @@ module Redis::Commands::Lists # @param value [String] # @return [String] `OK` # - # source://redis//lib/redis/commands/lists.rb#236 + # source://redis//lib/redis/commands/lists.rb#290 def lset(key, index, value); end # Trim a list to the specified range. @@ -2022,14 +1313,14 @@ module Redis::Commands::Lists # @param stop [Integer] stop index # @return [String] `OK` # - # source://redis//lib/redis/commands/lists.rb#246 + # source://redis//lib/redis/commands/lists.rb#300 def ltrim(key, start, stop); end # Remove and get the last elements in a list. # # @param key [String] # @param count [Integer] number of elements to remove - # @return [String, Array] the values of the last elements + # @return [nil, String, Array] the values of the last elements # # source://redis//lib/redis/commands/lists.rb#114 def rpop(key, count = T.unsafe(nil)); end @@ -2063,30 +1354,30 @@ module Redis::Commands::Lists private - # source://redis//lib/redis/commands/lists.rb#252 + # source://redis//lib/redis/commands/lists.rb#306 def _bpop(cmd, args, &blk); end - # source://redis//lib/redis/commands/lists.rb#274 + # source://redis//lib/redis/commands/lists.rb#323 def _normalize_move_wheres(where_source, where_destination); end end -# source://redis//lib/redis/commands.rb#195 +# source://redis//lib/redis/commands.rb#192 Redis::Commands::Noop = T.let(T.unsafe(nil), Proc) -# source://redis//lib/redis/commands.rb#70 +# source://redis//lib/redis/commands.rb#65 Redis::Commands::Pairify = T.let(T.unsafe(nil), Proc) # source://redis//lib/redis/commands/pubsub.rb#5 module Redis::Commands::Pubsub # Listen for messages published to channels matching the given patterns. # - # source://redis//lib/redis/commands/pubsub.rb#42 + # source://redis//lib/redis/commands/pubsub.rb#32 def psubscribe(*channels, &block); end # Listen for messages published to channels matching the given patterns. # Throw a timeout error if there is no messages for a timeout period. # - # source://redis//lib/redis/commands/pubsub.rb#50 + # source://redis//lib/redis/commands/pubsub.rb#38 def psubscribe_with_timeout(timeout, *channels, &block); end # Post a message to a channel. @@ -2097,23 +1388,39 @@ module Redis::Commands::Pubsub # Inspect the state of the Pub/Sub subsystem. # Possible subcommands: channels, numsub, numpat. # - # source://redis//lib/redis/commands/pubsub.rb#67 + # source://redis//lib/redis/commands/pubsub.rb#49 def pubsub(subcommand, *args); end # Stop listening for messages posted to channels matching the given patterns. # - # source://redis//lib/redis/commands/pubsub.rb#57 + # source://redis//lib/redis/commands/pubsub.rb#43 def punsubscribe(*channels); end + # Post a message to a channel in a shard. + # + # source://redis//lib/redis/commands/pubsub.rb#54 + def spublish(channel, message); end + + # Listen for messages published to the given channels in a shard. + # + # source://redis//lib/redis/commands/pubsub.rb#59 + def ssubscribe(*channels, &block); end + + # Listen for messages published to the given channels in a shard. + # Throw a timeout error if there is no messages for a timeout period. + # + # source://redis//lib/redis/commands/pubsub.rb#65 + def ssubscribe_with_timeout(timeout, *channels, &block); end + # Listen for messages published to the given channels. # - # source://redis//lib/redis/commands/pubsub.rb#18 + # source://redis//lib/redis/commands/pubsub.rb#16 def subscribe(*channels, &block); end # Listen for messages published to the given channels. Throw a timeout error # if there is no messages for a timeout period. # - # source://redis//lib/redis/commands/pubsub.rb#26 + # source://redis//lib/redis/commands/pubsub.rb#22 def subscribe_with_timeout(timeout, *channels, &block); end # @return [Boolean] @@ -2121,9 +1428,14 @@ module Redis::Commands::Pubsub # source://redis//lib/redis/commands/pubsub.rb#11 def subscribed?; end + # Stop listening for messages posted to the given channels in a shard. + # + # source://redis//lib/redis/commands/pubsub.rb#70 + def sunsubscribe(*channels); end + # Stop listening for messages posted to the given channels. # - # source://redis//lib/redis/commands/pubsub.rb#33 + # source://redis//lib/redis/commands/pubsub.rb#27 def unsubscribe(*channels); end end @@ -2227,7 +1539,7 @@ module Redis::Commands::Server # @return [String, Hash] depends on subcommand # # source://redis//lib/redis/commands/server.rb#39 - def client(subcommand = T.unsafe(nil), *args); end + def client(subcommand, *args); end # Get or set server configuration parameters. # @@ -2287,23 +1599,23 @@ module Redis::Commands::Server # @yieldparam line [String] timestamp and command that was executed # # source://redis//lib/redis/commands/server.rb#120 - def monitor(&block); end + def monitor; end # Synchronously save the dataset to disk. # # @return [String] # - # source://redis//lib/redis/commands/server.rb#129 + # source://redis//lib/redis/commands/server.rb#133 def save; end # Synchronously save the dataset to disk and then shut down the server. # - # source://redis//lib/redis/commands/server.rb#134 + # source://redis//lib/redis/commands/server.rb#138 def shutdown; end # Make the server a slave of another instance, or promote it as master. # - # source://redis//lib/redis/commands/server.rb#148 + # source://redis//lib/redis/commands/server.rb#150 def slaveof(host, port); end # Interact with the slowlog (get, len, reset) @@ -2312,7 +1624,7 @@ module Redis::Commands::Server # @param length [Integer] maximum number of entries to return # @return [Array, Integer, String] depends on subcommand # - # source://redis//lib/redis/commands/server.rb#157 + # source://redis//lib/redis/commands/server.rb#159 def slowlog(subcommand, length = T.unsafe(nil)); end # Internal command used for replication. @@ -2337,22 +1649,19 @@ module Redis::Commands::Sets # # @param key [String] # @param member [String, Array] one member, or array of members - # @return [Boolean, Integer] `Boolean` when a single member is specified, - # holding whether or not adding the member succeeded, or `Integer` when an - # array of members is specified, holding the number of members that were - # successfully added + # @return [Integer] The number of members that were successfully added # - # source://redis//lib/redis/commands/sets.rb#22 - def sadd(key, member); end + # source://redis//lib/redis/commands/sets.rb#19 + def sadd(key, *members); end # Add one or more members to a set. # # @param key [String] # @param member [String, Array] one member, or array of members - # @return [Boolean] Whether or not at least one member was added. + # @return [Boolean] Wether at least one member was successfully added. # - # source://redis//lib/redis/commands/sets.rb#38 - def sadd?(key, member); end + # source://redis//lib/redis/commands/sets.rb#29 + def sadd?(key, *members); end # Get the number of members in a set. # @@ -2367,7 +1676,7 @@ module Redis::Commands::Sets # @param keys [String, Array] keys pointing to sets to subtract # @return [Array] members in the difference # - # source://redis//lib/redis/commands/sets.rb#138 + # source://redis//lib/redis/commands/sets.rb#123 def sdiff(*keys); end # Subtract multiple sets and store the resulting set in a key. @@ -2376,7 +1685,7 @@ module Redis::Commands::Sets # @param keys [String, Array] keys pointing to sets to subtract # @return [Integer] number of elements in the resulting set # - # source://redis//lib/redis/commands/sets.rb#147 + # source://redis//lib/redis/commands/sets.rb#133 def sdiffstore(destination, *keys); end # Intersect multiple sets. @@ -2384,7 +1693,7 @@ module Redis::Commands::Sets # @param keys [String, Array] keys pointing to sets to intersect # @return [Array] members in the intersection # - # source://redis//lib/redis/commands/sets.rb#155 + # source://redis//lib/redis/commands/sets.rb#142 def sinter(*keys); end # Intersect multiple sets and store the resulting set in a key. @@ -2393,7 +1702,7 @@ module Redis::Commands::Sets # @param keys [String, Array] keys pointing to sets to intersect # @return [Integer] number of elements in the resulting set # - # source://redis//lib/redis/commands/sets.rb#164 + # source://redis//lib/redis/commands/sets.rb#152 def sinterstore(destination, *keys); end # Determine if a given value is a member of a set. @@ -2402,7 +1711,7 @@ module Redis::Commands::Sets # @param member [String] # @return [Boolean] # - # source://redis//lib/redis/commands/sets.rb#111 + # source://redis//lib/redis/commands/sets.rb#95 def sismember(key, member); end # Get all the members in a set. @@ -2410,7 +1719,7 @@ module Redis::Commands::Sets # @param key [String] # @return [Array] # - # source://redis//lib/redis/commands/sets.rb#130 + # source://redis//lib/redis/commands/sets.rb#115 def smembers(key); end # Determine if multiple values are members of a set. @@ -2419,7 +1728,7 @@ module Redis::Commands::Sets # @param members [String, Array] # @return [Array] # - # source://redis//lib/redis/commands/sets.rb#120 + # source://redis//lib/redis/commands/sets.rb#104 def smismember(key, *members); end # Move a member from one set to another. @@ -2429,7 +1738,7 @@ module Redis::Commands::Sets # @param member [String] member to move from `source` to `destination` # @return [Boolean] # - # source://redis//lib/redis/commands/sets.rb#102 + # source://redis//lib/redis/commands/sets.rb#86 def smove(source, destination, member); end # Remove and return one or more random member from a set. @@ -2438,7 +1747,7 @@ module Redis::Commands::Sets # @param count [Integer] # @return [String] # - # source://redis//lib/redis/commands/sets.rb#75 + # source://redis//lib/redis/commands/sets.rb#59 def spop(key, count = T.unsafe(nil)); end # Get one or more random members from a set. @@ -2447,29 +1756,26 @@ module Redis::Commands::Sets # @param count [Integer] # @return [String] # - # source://redis//lib/redis/commands/sets.rb#88 + # source://redis//lib/redis/commands/sets.rb#72 def srandmember(key, count = T.unsafe(nil)); end # Remove one or more members from a set. # # @param key [String] # @param member [String, Array] one member, or array of members - # @return [Boolean, Integer] `Boolean` when a single member is specified, - # holding whether or not removing the member succeeded, or `Integer` when an - # array of members is specified, holding the number of members that were - # successfully removed + # @return [Integer] The number of members that were successfully removed # - # source://redis//lib/redis/commands/sets.rb#50 - def srem(key, member); end + # source://redis//lib/redis/commands/sets.rb#39 + def srem(key, *members); end # Remove one or more members from a set. # # @param key [String] # @param member [String, Array] one member, or array of members - # @return [Boolean] `Boolean` Whether or not a member was removed. + # @return [Boolean] Wether at least one member was successfully removed. # - # source://redis//lib/redis/commands/sets.rb#66 - def srem?(key, member); end + # source://redis//lib/redis/commands/sets.rb#49 + def srem?(key, *members); end # Scan a set # @@ -2480,7 +1786,7 @@ module Redis::Commands::Sets # - `:count => Integer`: return count keys at most per iteration # @return [String, Array] the next cursor and all found members # - # source://redis//lib/redis/commands/sets.rb#196 + # source://redis//lib/redis/commands/sets.rb#187 def sscan(key, cursor, **options); end # Scan a set @@ -2492,7 +1798,7 @@ module Redis::Commands::Sets # - `:count => Integer`: return count keys at most per iteration # @return [Enumerator] an enumerator for all keys in the set # - # source://redis//lib/redis/commands/sets.rb#211 + # source://redis//lib/redis/commands/sets.rb#202 def sscan_each(key, **options, &block); end # Add multiple sets. @@ -2500,7 +1806,7 @@ module Redis::Commands::Sets # @param keys [String, Array] keys pointing to sets to unify # @return [Array] members in the union # - # source://redis//lib/redis/commands/sets.rb#172 + # source://redis//lib/redis/commands/sets.rb#161 def sunion(*keys); end # Add multiple sets and store the resulting set in a key. @@ -2509,12 +1815,26 @@ module Redis::Commands::Sets # @param keys [String, Array] keys pointing to sets to unify # @return [Integer] number of elements in the resulting set # - # source://redis//lib/redis/commands/sets.rb#181 + # source://redis//lib/redis/commands/sets.rb#171 def sunionstore(destination, *keys); end end # source://redis//lib/redis/commands/sorted_sets.rb#5 module Redis::Commands::SortedSets + # Removes and returns up to count members with scores in the sorted set stored at key. + # + # @example Popping a member + # redis.bzmpop('zset') + # #=> ['zset', ['a', 1.0]] + # @example With count option + # redis.bzmpop('zset', count: 2) + # #=> ['zset', [['a', 1.0], ['b', 2.0]] + # @raise [ArgumentError] + # @return [Array>] list of popped elements and scores + # + # source://redis//lib/redis/commands/sorted_sets.rb#188 + def bzmpop(timeout, *keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end + # Removes and returns up to count members with the highest scores in the sorted set stored at keys, # or block until one is available. # @@ -2527,7 +1847,7 @@ module Redis::Commands::SortedSets # @return [Array] a touple of key, member and score # @return [nil] when no element could be popped and the timeout expired # - # source://redis//lib/redis/commands/sorted_sets.rb#181 + # source://redis//lib/redis/commands/sorted_sets.rb#251 def bzpopmax(*args); end # Removes and returns up to count members with the lowest scores in the sorted set stored at keys, @@ -2542,7 +1862,7 @@ module Redis::Commands::SortedSets # @return [Array] a touple of key, member and score # @return [nil] when no element could be popped and the timeout expired # - # source://redis//lib/redis/commands/sorted_sets.rb#202 + # source://redis//lib/redis/commands/sorted_sets.rb#272 def bzpopmin(*args); end # Add one or more members to a sorted set, or update the score for members @@ -2605,7 +1925,7 @@ module Redis::Commands::SortedSets # - exclusive maximum score is specified by prefixing `(` # @return [Integer] number of members in within the specified range # - # source://redis//lib/redis/commands/sorted_sets.rb#608 + # source://redis//lib/redis/commands/sorted_sets.rb#678 def zcount(key, min, max); end # Return the difference between the first and all successive input sorted sets @@ -2625,7 +1945,7 @@ module Redis::Commands::SortedSets # @return [Array, Array<[String, Float]>] - when `:with_scores` is not specified, an array of members # - when `:with_scores` is specified, an array with `[member, score]` pairs # - # source://redis//lib/redis/commands/sorted_sets.rb#717 + # source://redis//lib/redis/commands/sorted_sets.rb#787 def zdiff(*keys, with_scores: T.unsafe(nil)); end # Compute the difference between the first and all successive input sorted sets @@ -2640,7 +1960,7 @@ module Redis::Commands::SortedSets # @param keys [Array] source keys # @return [Integer] number of elements in the resulting sorted set # - # source://redis//lib/redis/commands/sorted_sets.rb#733 + # source://redis//lib/redis/commands/sorted_sets.rb#803 def zdiffstore(*args, **_arg1); end # Increment the score of a member in a sorted set. @@ -2672,7 +1992,7 @@ module Redis::Commands::SortedSets # @return [Array, Array<[String, Float]>] - when `:with_scores` is not specified, an array of members # - when `:with_scores` is specified, an array with `[member, score]` pairs # - # source://redis//lib/redis/commands/sorted_sets.rb#631 + # source://redis//lib/redis/commands/sorted_sets.rb#701 def zinter(*args, **_arg1); end # Intersect multiple sorted sets and store the resulting sorted set in a new @@ -2688,7 +2008,7 @@ module Redis::Commands::SortedSets # - `:aggregate => String`: aggregate function to use (sum, min, max) # @return [Integer] number of elements in the resulting sorted set # - # source://redis//lib/redis/commands/sorted_sets.rb#650 + # source://redis//lib/redis/commands/sorted_sets.rb#720 def zinterstore(*args, **_arg1); end # Count the members, with the same score in a sorted set, within the given lexicographical range. @@ -2706,9 +2026,23 @@ module Redis::Commands::SortedSets # - exclusive maximum is specified by prefixing `[` # @return [Integer] number of members within the specified lexicographical range # - # source://redis//lib/redis/commands/sorted_sets.rb#439 + # source://redis//lib/redis/commands/sorted_sets.rb#509 def zlexcount(key, min, max); end + # Removes and returns up to count members with scores in the sorted set stored at key. + # + # @example Popping a member + # redis.zmpop('zset') + # #=> ['zset', ['a', 1.0]] + # @example With count option + # redis.zmpop('zset', count: 2) + # #=> ['zset', [['a', 1.0], ['b', 2.0]] + # @raise [ArgumentError] + # @return [Array>] list of popped elements and scores + # + # source://redis//lib/redis/commands/sorted_sets.rb#220 + def zmpop(*keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end + # Get the scores associated with the given members in a sorted set. # # @example Get the scores for members "a" and "b" @@ -2718,7 +2052,7 @@ module Redis::Commands::SortedSets # @param members [String, Array] # @return [Array] scores of the members # - # source://redis//lib/redis/commands/sorted_sets.rb#230 + # source://redis//lib/redis/commands/sorted_sets.rb#300 def zmscore(key, *members); end # Removes and returns up to count members with the highest scores in the sorted set stored at key. @@ -2746,7 +2080,7 @@ module Redis::Commands::SortedSets # @return [Array] element and score pair if count is not specified # @return [Array>] list of popped elements and scores # - # source://redis//lib/redis/commands/sorted_sets.rb#159 + # source://redis//lib/redis/commands/sorted_sets.rb#161 def zpopmin(key, count = T.unsafe(nil)); end # Get one or more random members from a sorted set. @@ -2768,7 +2102,7 @@ module Redis::Commands::SortedSets # - when `count` is specified and `:with_scores` is not specified, an array of members # - when `:with_scores` is specified, an array with `[member, score]` pairs # - # source://redis//lib/redis/commands/sorted_sets.rb#258 + # source://redis//lib/redis/commands/sorted_sets.rb#328 def zrandmember(key, count = T.unsafe(nil), withscores: T.unsafe(nil), with_scores: T.unsafe(nil)); end # Return a range of members in a sorted set, by index, score or lexicographical ordering. @@ -2791,7 +2125,7 @@ module Redis::Commands::SortedSets # @return [Array, Array<[String, Float]>] - when `:with_scores` is not specified, an array of members # - when `:with_scores` is specified, an array with `[member, score]` pairs # - # source://redis//lib/redis/commands/sorted_sets.rb#297 + # source://redis//lib/redis/commands/sorted_sets.rb#367 def zrange(key, start, stop, byscore: T.unsafe(nil), by_score: T.unsafe(nil), bylex: T.unsafe(nil), by_lex: T.unsafe(nil), rev: T.unsafe(nil), limit: T.unsafe(nil), withscores: T.unsafe(nil), with_scores: T.unsafe(nil)); end # Return a range of members with the same score in a sorted set, by lexicographical ordering @@ -2811,7 +2145,7 @@ module Redis::Commands::SortedSets # `count` members # @return [Array, Array<[String, Float]>] # - # source://redis//lib/redis/commands/sorted_sets.rb#464 + # source://redis//lib/redis/commands/sorted_sets.rb#534 def zrangebylex(key, min, max, limit: T.unsafe(nil)); end # Return a range of members in a sorted set, by score. @@ -2836,7 +2170,7 @@ module Redis::Commands::SortedSets # @return [Array, Array<[String, Float]>] - when `:with_scores` is not specified, an array of members # - when `:with_scores` is specified, an array with `[member, score]` pairs # - # source://redis//lib/redis/commands/sorted_sets.rb#524 + # source://redis//lib/redis/commands/sorted_sets.rb#594 def zrangebyscore(key, min, max, withscores: T.unsafe(nil), with_scores: T.unsafe(nil), limit: T.unsafe(nil)); end # Select a range of members in a sorted set, by index, score or lexicographical ordering @@ -2851,7 +2185,7 @@ module Redis::Commands::SortedSets # @return [Integer] the number of elements in the resulting sorted set # @see #zrange # - # source://redis//lib/redis/commands/sorted_sets.rb#339 + # source://redis//lib/redis/commands/sorted_sets.rb#409 def zrangestore(dest_key, src_key, start, stop, byscore: T.unsafe(nil), by_score: T.unsafe(nil), bylex: T.unsafe(nil), by_lex: T.unsafe(nil), rev: T.unsafe(nil), limit: T.unsafe(nil)); end # Determine the index of a member in a sorted set. @@ -2860,7 +2194,7 @@ module Redis::Commands::SortedSets # @param member [String] # @return [Integer] # - # source://redis//lib/redis/commands/sorted_sets.rb#390 + # source://redis//lib/redis/commands/sorted_sets.rb#460 def zrank(key, member); end # Remove one or more members from a sorted set. @@ -2893,7 +2227,7 @@ module Redis::Commands::SortedSets # @param stop [Integer] stop index # @return [Integer] number of members that were removed # - # source://redis//lib/redis/commands/sorted_sets.rb#417 + # source://redis//lib/redis/commands/sorted_sets.rb#487 def zremrangebyrank(key, start, stop); end # Remove all members in a sorted set within the given scores. @@ -2911,7 +2245,7 @@ module Redis::Commands::SortedSets # - exclusive maximum score is specified by prefixing `(` # @return [Integer] number of members that were removed # - # source://redis//lib/redis/commands/sorted_sets.rb#587 + # source://redis//lib/redis/commands/sorted_sets.rb#657 def zremrangebyscore(key, min, max); end # Return a range of members in a sorted set, by index, with scores ordered @@ -2925,7 +2259,7 @@ module Redis::Commands::SortedSets # # => [["b", 64.0], ["a", 32.0]] # @see #zrange # - # source://redis//lib/redis/commands/sorted_sets.rb#374 + # source://redis//lib/redis/commands/sorted_sets.rb#444 def zrevrange(key, start, stop, withscores: T.unsafe(nil), with_scores: T.unsafe(nil)); end # Return a range of members with the same score in a sorted set, by reversed lexicographical ordering. @@ -2939,7 +2273,7 @@ module Redis::Commands::SortedSets # # => ["abbygail", "abby"] # @see #zrangebylex # - # source://redis//lib/redis/commands/sorted_sets.rb#486 + # source://redis//lib/redis/commands/sorted_sets.rb#556 def zrevrangebylex(key, max, min, limit: T.unsafe(nil)); end # Return a range of members in a sorted set, by score, with scores ordered @@ -2956,7 +2290,7 @@ module Redis::Commands::SortedSets # # => [["b", 64.0], ["a", 32.0]] # @see #zrangebyscore # - # source://redis//lib/redis/commands/sorted_sets.rb#554 + # source://redis//lib/redis/commands/sorted_sets.rb#624 def zrevrangebyscore(key, max, min, withscores: T.unsafe(nil), with_scores: T.unsafe(nil), limit: T.unsafe(nil)); end # Determine the index of a member in a sorted set, with scores ordered from @@ -2966,7 +2300,7 @@ module Redis::Commands::SortedSets # @param member [String] # @return [Integer] # - # source://redis//lib/redis/commands/sorted_sets.rb#400 + # source://redis//lib/redis/commands/sorted_sets.rb#470 def zrevrank(key, member); end # Scan a sorted set @@ -2979,7 +2313,7 @@ module Redis::Commands::SortedSets # @return [String, Array<[String, Float]>] the next cursor and all found # members and scores # - # source://redis//lib/redis/commands/sorted_sets.rb#750 + # source://redis//lib/redis/commands/sorted_sets.rb#820 def zscan(key, cursor, **options); end # Scan a sorted set @@ -2991,7 +2325,7 @@ module Redis::Commands::SortedSets # - `:count => Integer`: return count keys at most per iteration # @return [Enumerator] an enumerator for all found scores and members # - # source://redis//lib/redis/commands/sorted_sets.rb#767 + # source://redis//lib/redis/commands/sorted_sets.rb#837 def zscan_each(key, **options, &block); end # Get the score associated with the given member in a sorted set. @@ -3003,7 +2337,7 @@ module Redis::Commands::SortedSets # @param member [String] # @return [Float] score of the member # - # source://redis//lib/redis/commands/sorted_sets.rb#217 + # source://redis//lib/redis/commands/sorted_sets.rb#287 def zscore(key, member); end # Return the union of multiple sorted sets @@ -3022,7 +2356,7 @@ module Redis::Commands::SortedSets # @return [Array, Array<[String, Float]>] - when `:with_scores` is not specified, an array of members # - when `:with_scores` is specified, an array with `[member, score]` pairs # - # source://redis//lib/redis/commands/sorted_sets.rb#674 + # source://redis//lib/redis/commands/sorted_sets.rb#744 def zunion(*args, **_arg1); end # Add multiple sorted sets and store the resulting sorted set in a new key. @@ -3037,15 +2371,15 @@ module Redis::Commands::SortedSets # - `:aggregate => String`: aggregate function to use (sum, min, max, ...) # @return [Integer] number of elements in the resulting sorted set # - # source://redis//lib/redis/commands/sorted_sets.rb#692 + # source://redis//lib/redis/commands/sorted_sets.rb#762 def zunionstore(*args, **_arg1); end private - # source://redis//lib/redis/commands/sorted_sets.rb#780 + # source://redis//lib/redis/commands/sorted_sets.rb#850 def _zsets_operation(cmd, *keys, weights: T.unsafe(nil), aggregate: T.unsafe(nil), with_scores: T.unsafe(nil)); end - # source://redis//lib/redis/commands/sorted_sets.rb#798 + # source://redis//lib/redis/commands/sorted_sets.rb#869 def _zsets_operation_store(cmd, destination, keys, weights: T.unsafe(nil), aggregate: T.unsafe(nil)); end end @@ -3064,7 +2398,7 @@ module Redis::Commands::Streams # @param ids [Array] one or multiple entry ids # @return [Integer] the number of entries successfully acknowledged # - # source://redis//lib/redis/commands/streams.rb#251 + # source://redis//lib/redis/commands/streams.rb#266 def xack(key, group, *ids); end # Add new entry to the stream. @@ -3072,7 +2406,8 @@ module Redis::Commands::Streams # @example Without options # redis.xadd('mystream', f1: 'v1', f2: 'v2') # @example With options - # redis.xadd('mystream', { f1: 'v1', f2: 'v2' }, id: '0-0', maxlen: 1000, approximate: true) + # redis.xadd('mystream', { f1: 'v1', f2: 'v2' }, id: '0-0', maxlen: 1000, approximate: true, nomkstream: true) + # @option opts # @option opts # @option opts # @option opts @@ -3081,8 +2416,8 @@ module Redis::Commands::Streams # @param opts [Hash] several options for `XADD` command # @return [String] the entry id # - # source://redis//lib/redis/commands/streams.rb#51 - def xadd(key, entry, approximate: T.unsafe(nil), maxlen: T.unsafe(nil), id: T.unsafe(nil)); end + # source://redis//lib/redis/commands/streams.rb#49 + def xadd(key, entry, approximate: T.unsafe(nil), maxlen: T.unsafe(nil), nomkstream: T.unsafe(nil), id: T.unsafe(nil)); end # Transfers ownership of pending stream entries that match the specified criteria. # @@ -3105,7 +2440,7 @@ module Redis::Commands::Streams # @return [Hash{String => Hash}] the entries successfully claimed # @return [Array] the entry ids successfully claimed if justid option is `true` # - # source://redis//lib/redis/commands/streams.rb#321 + # source://redis//lib/redis/commands/streams.rb#336 def xautoclaim(key, group, consumer, min_idle_time, start, count: T.unsafe(nil), justid: T.unsafe(nil)); end # Changes the ownership of a pending entry @@ -3138,7 +2473,7 @@ module Redis::Commands::Streams # @return [Hash{String => Hash}] the entries successfully claimed # @return [Array] the entry ids successfully claimed if justid option is `true` # - # source://redis//lib/redis/commands/streams.rb#288 + # source://redis//lib/redis/commands/streams.rb#303 def xclaim(key, group, consumer, min_idle_time, *ids, **opts); end # Delete entries by entry ids. @@ -3151,7 +2486,7 @@ module Redis::Commands::Streams # @param ids [Array] one or multiple entry ids # @return [Integer] the number of entries actually deleted # - # source://redis//lib/redis/commands/streams.rb#91 + # source://redis//lib/redis/commands/streams.rb#106 def xdel(key, *ids); end # Manages the consumer group of the stream. @@ -3173,7 +2508,7 @@ module Redis::Commands::Streams # @return [String] `OK` if subcommand is `create` or `setid` # @return [Integer] effected count if subcommand is `destroy` or `delconsumer` # - # source://redis//lib/redis/commands/streams.rb#199 + # source://redis//lib/redis/commands/streams.rb#214 def xgroup(subcommand, key, group, id_or_consumer = T.unsafe(nil), mkstream: T.unsafe(nil)); end # Returns the stream information each subcommand. @@ -3201,7 +2536,7 @@ module Redis::Commands::Streams # @param key [String] the stream key # @return [Integer] the number of entries # - # source://redis//lib/redis/commands/streams.rb#150 + # source://redis//lib/redis/commands/streams.rb#165 def xlen(key); end # Fetches not acknowledging pending entries @@ -3210,19 +2545,23 @@ module Redis::Commands::Streams # redis.xpending('mystream', 'mygroup') # @example With range options # redis.xpending('mystream', 'mygroup', '-', '+', 10) + # @example With range and idle time options + # redis.xpending('mystream', 'mygroup', '-', '+', 10, idle: 9000) # @example With range and consumer options # redis.xpending('mystream', 'mygroup', '-', '+', 10, 'consumer1') + # @option opts # @param key [String] the stream key # @param group [String] the consumer group name # @param start [String] start first entry id of range # @param end [String] end last entry id of range # @param count [Integer] count the number of entries as limit # @param consumer [String] the consumer name + # @param opts [Hash] a customizable set of options # @return [Hash] the summary of pending entries # @return [Array] the pending entries details if options were specified # - # source://redis//lib/redis/commands/streams.rb#349 - def xpending(key, group, *args); end + # source://redis//lib/redis/commands/streams.rb#368 + def xpending(key, group, *args, idle: T.unsafe(nil)); end # Fetches entries of the stream in ascending order. # @@ -3240,7 +2579,7 @@ module Redis::Commands::Streams # @param count [Integer] the number of entries as limit # @return [Array>] the ids and entries pairs # - # source://redis//lib/redis/commands/streams.rb#113 + # source://redis//lib/redis/commands/streams.rb#128 def xrange(key, start = T.unsafe(nil), range_end = T.unsafe(nil), count: T.unsafe(nil)); end # Fetches entries from one or multiple streams. Optionally blocking. @@ -3259,7 +2598,7 @@ module Redis::Commands::Streams # @param block [Integer] the number of milliseconds as blocking timeout # @return [Hash{String => Hash{String => Hash}}] the entries # - # source://redis//lib/redis/commands/streams.rb#171 + # source://redis//lib/redis/commands/streams.rb#186 def xread(keys, ids, count: T.unsafe(nil), block: T.unsafe(nil)); end # Fetches a subset of the entries from one or multiple streams related with the consumer group. @@ -3285,7 +2624,7 @@ module Redis::Commands::Streams # @param opts [Hash] several options for `XREADGROUP` command # @return [Hash{String => Hash{String => Hash}}] the entries # - # source://redis//lib/redis/commands/streams.rb#229 + # source://redis//lib/redis/commands/streams.rb#244 def xreadgroup(group, consumer, keys, ids, count: T.unsafe(nil), block: T.unsafe(nil), noack: T.unsafe(nil)); end # Fetches entries of the stream in descending order. @@ -3303,7 +2642,7 @@ module Redis::Commands::Streams # @param start [String] last entry id of range, default value is `-` # @return [Array>] the ids and entries pairs # - # source://redis//lib/redis/commands/streams.rb#136 + # source://redis//lib/redis/commands/streams.rb#151 def xrevrange(key, range_end = T.unsafe(nil), start = T.unsafe(nil), count: T.unsafe(nil)); end # Trims older entries of the stream if needed. @@ -3312,17 +2651,18 @@ module Redis::Commands::Streams # redis.xtrim('mystream', 1000) # @example With options # redis.xtrim('mystream', 1000, approximate: true) - # @param key [String] the stream key - # @param mexlen [Integer] max length of entries - # @param approximate [Boolean] whether to add `~` modifier of maxlen or not + # @example With strategy + # redis.xtrim('mystream', '1-0', strategy: 'MINID') + # @overload xtrim + # @overload xtrim # @return [Integer] the number of entries actually deleted # - # source://redis//lib/redis/commands/streams.rb#75 - def xtrim(key, maxlen, approximate: T.unsafe(nil)); end + # source://redis//lib/redis/commands/streams.rb#85 + def xtrim(key, len_or_id, strategy: T.unsafe(nil), approximate: T.unsafe(nil), limit: T.unsafe(nil)); end private - # source://redis//lib/redis/commands/streams.rb#365 + # source://redis//lib/redis/commands/streams.rb#385 def _xread(args, keys, ids, blocking_timeout_msec); end end @@ -3334,7 +2674,7 @@ module Redis::Commands::Strings # @param value [String] value to append # @return [Integer] length of the string after appending # - # source://redis//lib/redis/commands/strings.rb#254 + # source://redis//lib/redis/commands/strings.rb#255 def append(key, value); end # Decrement the integer value of a key by one. @@ -3375,7 +2715,7 @@ module Redis::Commands::Strings # @return [String] the old value stored in the key, or `nil` if the key # did not exist # - # source://redis//lib/redis/commands/strings.rb#274 + # source://redis//lib/redis/commands/strings.rb#275 def getdel(key); end # Get the value of key and optionally set its expiration. GETEX is similar to @@ -3392,7 +2732,7 @@ module Redis::Commands::Strings # - `:persist => true`: Remove the time to live associated with the key. # @return [String] The value of key, or nil when key does not exist. # - # source://redis//lib/redis/commands/strings.rb#292 + # source://redis//lib/redis/commands/strings.rb#293 def getex(key, ex: T.unsafe(nil), px: T.unsafe(nil), exat: T.unsafe(nil), pxat: T.unsafe(nil), persist: T.unsafe(nil)); end # Get a substring of the string stored at a key. @@ -3403,7 +2743,7 @@ module Redis::Commands::Strings # the end of the string # @return [Integer] `0` or `1` # - # source://redis//lib/redis/commands/strings.rb#245 + # source://redis//lib/redis/commands/strings.rb#246 def getrange(key, start, stop); end # Set the string value of a key and return its old value. @@ -3413,7 +2753,7 @@ module Redis::Commands::Strings # @return [String] the old value stored in the key, or `nil` if the key # did not exist # - # source://redis//lib/redis/commands/strings.rb#264 + # source://redis//lib/redis/commands/strings.rb#265 def getset(key, value); end # Increment the integer value of a key by one. @@ -3460,7 +2800,7 @@ module Redis::Commands::Strings # @return [Hash] a hash mapping the specified keys to their values # @see #mget # - # source://redis//lib/redis/commands/strings.rb#218 + # source://redis//lib/redis/commands/strings.rb#219 def mapped_mget(*keys); end # Set one or more values. @@ -3576,7 +2916,7 @@ module Redis::Commands::Strings # @param value [String] # @return [Integer] length of the string after it was modified # - # source://redis//lib/redis/commands/strings.rb#234 + # source://redis//lib/redis/commands/strings.rb#235 def setrange(key, offset, value); end # Get the length of the value stored in a key. @@ -3584,336 +2924,111 @@ module Redis::Commands::Strings # @param key [String] # @return [Integer] the length of the value stored in the key, or 0 # if the key does not exist - # - # source://redis//lib/redis/commands/strings.rb#308 - def strlen(key); end -end - -# source://redis//lib/redis/commands/transactions.rb#5 -module Redis::Commands::Transactions - # Discard all commands issued after MULTI. - # - # Only call this method when `#multi` was called **without** a block. - # - # @return [String] `"OK"` - # @see #multi - # @see #exec - # - # source://redis//lib/redis/commands/transactions.rb#134 - def discard; end - - # Execute all commands issued after MULTI. - # - # Only call this method when `#multi` was called **without** a block. - # - # @return [nil, Array<...>] - when commands were not executed, `nil` - # - when commands were executed, an array with their replies - # @see #multi - # @see #discard - # - # source://redis//lib/redis/commands/transactions.rb#122 - def exec; end - - # Mark the start of a transaction block. - # - # Passing a block is optional. - # - # @example With a block - # redis.multi do |multi| - # multi.set("key", "value") - # multi.incr("counter") - # end # => ["OK", 6] - # @example Without a block - # redis.multi - # # => "OK" - # redis.set("key", "value") - # # => "QUEUED" - # redis.incr("counter") - # # => "QUEUED" - # redis.exec - # # => ["OK", 6] - # @return [String, Array<...>] - when a block is not given, `OK` - # - when a block is given, an array with replies - # @see #watch - # @see #unwatch - # @yield [multi] the commands that are called inside this block are cached - # and written to the server upon returning from it - # @yieldparam multi [Redis] `self` - # - # source://redis//lib/redis/commands/transactions.rb#36 - def multi(&block); end - - # Forget about all watched keys. - # - # @return [String] `OK` - # @see #watch - # @see #multi - # - # source://redis//lib/redis/commands/transactions.rb#108 - def unwatch; end - - # Watch the given keys to determine execution of the MULTI/EXEC block. - # - # Using a block is optional, but is necessary for thread-safety. - # - # An `#unwatch` is automatically issued if an exception is raised within the - # block that is a subclass of StandardError and is not a ConnectionError. - # - # @example With a block - # redis.watch("key") do - # if redis.get("key") == "some value" - # redis.multi do |multi| - # multi.set("key", "other value") - # multi.incr("counter") - # end - # else - # redis.unwatch - # end - # end - # # => ["OK", 6] - # @example Without a block - # redis.watch("key") - # # => "OK" - # @param keys [String, Array] one or more keys to watch - # @return [Object] if using a block, returns the return value of the block - # @return [String] if not using a block, returns `OK` - # @see #unwatch - # @see #multi - # - # source://redis//lib/redis/commands/transactions.rb#83 - def watch(*keys); end -end - -# source://redis//lib/redis/connection/registry.rb#4 -module Redis::Connection - class << self - # Store a list of loaded connection drivers in the Connection module. - # Redis::Client uses the last required driver by default, and will be aware - # of the loaded connection drivers if the user chooses to override the - # default connection driver. - # - # source://redis//lib/redis/connection/registry.rb#9 - def drivers; end - end -end - -# source://redis//lib/redis/connection/command_helper.rb#5 -module Redis::Connection::CommandHelper - # source://redis//lib/redis/connection/command_helper.rb#8 - def build_command(args); end - - protected - - # source://redis//lib/redis/connection/command_helper.rb#36 - def encode(string); end -end - -# source://redis//lib/redis/connection/command_helper.rb#6 -Redis::Connection::CommandHelper::COMMAND_DELIMITER = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/connection/hiredis.rb#11 -class Redis::Connection::Hiredis - # @return [Hiredis] a new instance of Hiredis - # - # source://redis//lib/redis/connection/hiredis.rb#31 - def initialize(connection); end - - # @return [Boolean] - # - # source://redis//lib/redis/connection/hiredis.rb#35 - def connected?; end - - # source://redis//lib/redis/connection/hiredis.rb#44 - def disconnect; end - - # source://redis//lib/redis/connection/hiredis.rb#55 - def read; end - - # source://redis//lib/redis/connection/hiredis.rb#39 - def timeout=(timeout); end - - # source://redis//lib/redis/connection/hiredis.rb#49 - def write(command); end - - class << self - # source://redis//lib/redis/connection/hiredis.rb#12 - def connect(config); end - end -end - -# source://redis//lib/redis/connection/ruby.rb#291 -class Redis::Connection::Ruby - include ::Redis::Connection::CommandHelper - - # @return [Ruby] a new instance of Ruby - # - # source://redis//lib/redis/connection/ruby.rb#354 - def initialize(sock); end - - # @return [Boolean] - # - # source://redis//lib/redis/connection/ruby.rb#358 - def connected?; end - - # source://redis//lib/redis/connection/ruby.rb#362 - def disconnect; end - - # source://redis//lib/redis/connection/ruby.rb#418 - def format_bulk_reply(line); end - - # source://redis//lib/redis/connection/ruby.rb#406 - def format_error_reply(line); end - - # source://redis//lib/redis/connection/ruby.rb#414 - def format_integer_reply(line); end - - # source://redis//lib/redis/connection/ruby.rb#427 - def format_multi_bulk_reply(line); end - - # source://redis//lib/redis/connection/ruby.rb#395 - def format_reply(reply_type, line); end - - # source://redis//lib/redis/connection/ruby.rb#410 - def format_status_reply(line); end - - # source://redis//lib/redis/connection/ruby.rb#329 - def get_tcp_keepalive; end - - # source://redis//lib/redis/connection/ruby.rb#381 - def read; end - - # source://redis//lib/redis/connection/ruby.rb#320 - def set_tcp_keepalive(keepalive); end - - # source://redis//lib/redis/connection/ruby.rb#347 - def set_tcp_nodelay; end - - # source://redis//lib/redis/connection/ruby.rb#369 - def timeout=(timeout); end - - # source://redis//lib/redis/connection/ruby.rb#377 - def write(command); end - - # source://redis//lib/redis/connection/ruby.rb#373 - def write_timeout=(timeout); end - - class << self - # source://redis//lib/redis/connection/ruby.rb#300 - def connect(config); end - end -end - -# source://redis//lib/redis/connection/ruby.rb#298 -Redis::Connection::Ruby::ASTERISK = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/connection/ruby.rb#296 -Redis::Connection::Ruby::COLON = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/connection/ruby.rb#297 -Redis::Connection::Ruby::DOLLAR = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/connection/ruby.rb#294 -Redis::Connection::Ruby::MINUS = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/connection/ruby.rb#295 -Redis::Connection::Ruby::PLUS = T.let(T.unsafe(nil), String) - -# source://redis//lib/redis/connection/ruby.rb#230 -class Redis::Connection::SSLSocket < ::OpenSSL::SSL::SSLSocket - include ::Redis::Connection::SocketMixin - - # source://redis//lib/redis/connection/ruby.rb#234 - def wait_readable(timeout = T.unsafe(nil)); end - - # source://redis//lib/redis/connection/ruby.rb#240 - def wait_writable(timeout = T.unsafe(nil)); end - - class << self - # source://redis//lib/redis/connection/ruby.rb#245 - def connect(host, port, timeout, ssl_params); end - end -end - -# source://redis//lib/redis/connection/ruby.rb#18 -module Redis::Connection::SocketMixin - # source://redis//lib/redis/connection/ruby.rb#21 - def initialize(*args); end - - # source://redis//lib/redis/connection/ruby.rb#53 - def _read_from_socket(nbytes, buffer = T.unsafe(nil)); end - - # source://redis//lib/redis/connection/ruby.rb#45 - def gets; end - - # source://redis//lib/redis/connection/ruby.rb#36 - def read(nbytes); end - - # source://redis//lib/redis/connection/ruby.rb#28 - def timeout=(timeout); end - - # source://redis//lib/redis/connection/ruby.rb#72 - def write(buffer); end - - # source://redis//lib/redis/connection/ruby.rb#32 - def write_timeout=(timeout); end + # + # source://redis//lib/redis/commands/strings.rb#309 + def strlen(key); end end -# source://redis//lib/redis/connection/ruby.rb#19 -Redis::Connection::SocketMixin::CRLF = T.let(T.unsafe(nil), String) +# source://redis//lib/redis/commands/transactions.rb#5 +module Redis::Commands::Transactions + # Discard all commands issued after MULTI. + # + # @return [String] `"OK"` + # @see #multi + # @see #exec + # + # source://redis//lib/redis/commands/transactions.rb#110 + def discard; end -# source://redis//lib/redis/connection/ruby.rb#150 -class Redis::Connection::TCPSocket < ::Socket - include ::Redis::Connection::SocketMixin + # Execute all commands issued after MULTI. + # + # Only call this method when `#multi` was called **without** a block. + # + # @return [nil, Array<...>] - when commands were not executed, `nil` + # - when commands were executed, an array with their replies + # @see #multi + # @see #discard + # + # source://redis//lib/redis/commands/transactions.rb#100 + def exec; end - class << self - # source://redis//lib/redis/connection/ruby.rb#171 - def connect(host, port, timeout); end + # Mark the start of a transaction block. + # + # @example With a block + # redis.multi do |multi| + # multi.set("key", "value") + # multi.incr("counter") + # end # => ["OK", 6] + # @return [Array<...>] - an array with replies + # @see #watch + # @see #unwatch + # @yield [multi] the commands that are called inside this block are cached + # and written to the server upon returning from it + # @yieldparam multi [Redis] `self` + # + # source://redis//lib/redis/commands/transactions.rb#23 + def multi; end - # source://redis//lib/redis/connection/ruby.rb#153 - def connect_addrinfo(addrinfo, port, timeout); end - end -end + # Forget about all watched keys. + # + # @return [String] `OK` + # @see #watch + # @see #multi + # + # source://redis//lib/redis/commands/transactions.rb#86 + def unwatch; end -# source://redis//lib/redis/connection/ruby.rb#205 -class Redis::Connection::UNIXSocket < ::Socket - include ::Redis::Connection::SocketMixin + # Watch the given keys to determine execution of the MULTI/EXEC block. + # + # Using a block is optional, but is necessary for thread-safety. + # + # An `#unwatch` is automatically issued if an exception is raised within the + # block that is a subclass of StandardError and is not a ConnectionError. + # + # @example With a block + # redis.watch("key") do + # if redis.get("key") == "some value" + # redis.multi do |multi| + # multi.set("key", "other value") + # multi.incr("counter") + # end + # else + # redis.unwatch + # end + # end + # # => ["OK", 6] + # @example Without a block + # redis.watch("key") + # # => "OK" + # @param keys [String, Array] one or more keys to watch + # @return [Object] if using a block, returns the return value of the block + # @return [String] if not using a block, returns `OK` + # @see #unwatch + # @see #multi + # + # source://redis//lib/redis/commands/transactions.rb#61 + def watch(*keys); end +end +# soft-deprecated +# We added this back for older sidekiq releases +# +# source://redis//lib/redis.rb#27 +module Redis::Connection class << self - # source://redis//lib/redis/connection/ruby.rb#208 - def connect(path, timeout); end + # source://redis//lib/redis.rb#29 + def drivers; end end end # Raised when connection to a Redis server is lost. # -# source://redis//lib/redis/errors.rb#32 +# source://redis//lib/redis/errors.rb#41 class Redis::ConnectionError < ::Redis::BaseConnectionError; end -# source://redis//lib/redis.rb#12 +# source://redis//lib/redis.rb#9 class Redis::Deprecated < ::StandardError; end -# source://redis//lib/redis/pipeline.rb#223 -class Redis::DeprecatedMulti - # @return [DeprecatedMulti] a new instance of DeprecatedMulti - # - # source://redis//lib/redis/pipeline.rb#224 - def initialize(pipeline); end - - # source://redis//lib/redis/pipeline.rb#229 - def __getobj__; end -end - -# source://redis//lib/redis/pipeline.rb#208 -class Redis::DeprecatedPipeline - # @return [DeprecatedPipeline] a new instance of DeprecatedPipeline - # - # source://redis//lib/redis/pipeline.rb#209 - def initialize(pipeline); end - - # source://redis//lib/redis/pipeline.rb#214 - def __getobj__; end -end - # source://redis//lib/redis/distributed.rb#6 class Redis::Distributed # @return [Distributed] a new instance of Distributed @@ -3921,16 +3036,16 @@ class Redis::Distributed # source://redis//lib/redis/distributed.rb#20 def initialize(node_configs, options = T.unsafe(nil)); end - # source://redis//lib/redis/distributed.rb#396 + # source://redis//lib/redis/distributed.rb#410 def [](key); end - # source://redis//lib/redis/distributed.rb#400 + # source://redis//lib/redis/distributed.rb#414 def []=(key, value); end - # source://redis//lib/redis/distributed.rb#462 + # source://redis//lib/redis/distributed.rb#476 def _bpop(cmd, args); end - # source://redis//lib/redis/distributed.rb#979 + # source://redis//lib/redis/distributed.rb#1038 def _eval(cmd, args); end # source://redis//lib/redis/distributed.rb#41 @@ -3938,397 +3053,426 @@ class Redis::Distributed # Append a value to a key. # - # source://redis//lib/redis/distributed.rb#365 + # source://redis//lib/redis/distributed.rb#378 def append(key, value); end # Asynchronously save the dataset to disk. # - # source://redis//lib/redis/distributed.rb#68 + # source://redis//lib/redis/distributed.rb#74 def bgsave; end # Count the number of set bits in a range of the string value stored at key. # - # source://redis//lib/redis/distributed.rb#370 - def bitcount(key, start = T.unsafe(nil), stop = T.unsafe(nil)); end + # source://redis//lib/redis/distributed.rb#383 + def bitcount(key, start = T.unsafe(nil), stop = T.unsafe(nil), scale: T.unsafe(nil)); end # Perform a bitwise operation between strings and store the resulting string in a key. # - # source://redis//lib/redis/distributed.rb#375 + # source://redis//lib/redis/distributed.rb#388 def bitop(operation, destkey, *keys); end # Return the position of the first bit set to 1 or 0 in a string. # - # source://redis//lib/redis/distributed.rb#382 - def bitpos(key, bit, start = T.unsafe(nil), stop = T.unsafe(nil)); end + # source://redis//lib/redis/distributed.rb#396 + def bitpos(key, bit, start = T.unsafe(nil), stop = T.unsafe(nil), scale: T.unsafe(nil)); end # Remove the first/last element in a list and append/prepend it # to another list and return it, or block until one is available. # - # source://redis//lib/redis/distributed.rb#418 + # source://redis//lib/redis/distributed.rb#432 def blmove(source, destination, where_source, where_destination, timeout: T.unsafe(nil)); end + # Iterate over keys, blocking and removing elements from the first non empty liist found. + # + # source://redis//lib/redis/distributed.rb#556 + def blmpop(timeout, *keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end + # Remove and get the first element in a list, or block until one is # available. # - # source://redis//lib/redis/distributed.rb#489 + # source://redis//lib/redis/distributed.rb#495 def blpop(*args); end # Remove and get the last element in a list, or block until one is # available. # - # source://redis//lib/redis/distributed.rb#495 + # source://redis//lib/redis/distributed.rb#513 def brpop(*args); end # Pop a value from a list, push it to another list and return it; or block # until one is available. # - # source://redis//lib/redis/distributed.rb#501 - def brpoplpush(source, destination, deprecated_timeout = T.unsafe(nil), **options); end + # source://redis//lib/redis/distributed.rb#519 + def brpoplpush(source, destination, **options); end + + # Iterate over keys, blocking and removing members from the first non empty sorted set found. + # + # source://redis//lib/redis/distributed.rb#722 + def bzmpop(timeout, *keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end + + # source://redis//lib/redis/distributed.rb#499 + def bzpopmax(*args); end + + # source://redis//lib/redis/distributed.rb#505 + def bzpopmin(*args); end + + # source://redis//lib/redis/distributed.rb#69 + def close; end # Copy a value from one key to another. # - # source://redis//lib/redis/distributed.rb#215 + # source://redis//lib/redis/distributed.rb#226 def copy(source, destination, **options); end # Return the number of keys in the selected database. # - # source://redis//lib/redis/distributed.rb#73 + # source://redis//lib/redis/distributed.rb#79 def dbsize; end # Decrement the integer value of a key by one. # - # source://redis//lib/redis/distributed.rb#255 + # source://redis//lib/redis/distributed.rb#266 def decr(key); end # Decrement the integer value of a key by the given number. # - # source://redis//lib/redis/distributed.rb#260 + # source://redis//lib/redis/distributed.rb#271 def decrby(key, decrement); end # Delete a key. # - # source://redis//lib/redis/distributed.rb#163 + # source://redis//lib/redis/distributed.rb#179 def del(*args); end # Discard all commands issued after MULTI. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#946 + # source://redis//lib/redis/distributed.rb#1005 def discard; end # Return a serialized version of the value stored at a key. # - # source://redis//lib/redis/distributed.rb#148 + # source://redis//lib/redis/distributed.rb#164 def dump(key); end - # source://redis//lib/redis/distributed.rb#1006 + # source://redis//lib/redis/distributed.rb#1065 def dup; end # Echo the given string. # - # source://redis//lib/redis/distributed.rb#58 + # source://redis//lib/redis/distributed.rb#60 def echo(value); end # Evaluate Lua script. # - # source://redis//lib/redis/distributed.rb#993 + # source://redis//lib/redis/distributed.rb#1052 def eval(*args); end # Evaluate Lua script by its SHA. # - # source://redis//lib/redis/distributed.rb#998 + # source://redis//lib/redis/distributed.rb#1057 def evalsha(*args); end # Execute all commands issued after MULTI. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#937 + # source://redis//lib/redis/distributed.rb#996 def exec; end # Determine if a key exists. # - # source://redis//lib/redis/distributed.rb#179 + # source://redis//lib/redis/distributed.rb#197 def exists(*args); end # Determine if any of the keys exists. # # @return [Boolean] # - # source://redis//lib/redis/distributed.rb#196 + # source://redis//lib/redis/distributed.rb#206 def exists?(*args); end # Set a key's time to live in seconds. # - # source://redis//lib/redis/distributed.rb#118 + # source://redis//lib/redis/distributed.rb#124 def expire(key, seconds, **kwargs); end # Set the expiration for a key as a UNIX timestamp. # - # source://redis//lib/redis/distributed.rb#123 + # source://redis//lib/redis/distributed.rb#129 def expireat(key, unix_time, **kwargs); end + # Get the expiration for a key as a UNIX timestamp. + # + # source://redis//lib/redis/distributed.rb#134 + def expiretime(key); end + # Remove all keys from all databases. # - # source://redis//lib/redis/distributed.rb#78 + # source://redis//lib/redis/distributed.rb#84 def flushall; end # Remove all keys from the current database. # - # source://redis//lib/redis/distributed.rb#83 + # source://redis//lib/redis/distributed.rb#89 def flushdb; end # Get the value of a key. # - # source://redis//lib/redis/distributed.rb#318 + # source://redis//lib/redis/distributed.rb#329 def get(key); end # Returns the bit value at offset in the string value stored at key. # - # source://redis//lib/redis/distributed.rb#360 + # source://redis//lib/redis/distributed.rb#373 def getbit(key, offset); end # Get the value of a key and delete it. # - # source://redis//lib/redis/distributed.rb#323 + # source://redis//lib/redis/distributed.rb#334 def getdel(key); end # Get the value of a key and sets its time to live based on options. # - # source://redis//lib/redis/distributed.rb#328 + # source://redis//lib/redis/distributed.rb#339 def getex(key, **options); end # Get a substring of the string stored at a key. # - # source://redis//lib/redis/distributed.rb#350 + # source://redis//lib/redis/distributed.rb#363 def getrange(key, start, stop); end # Set the string value of a key and return its old value. # - # source://redis//lib/redis/distributed.rb#387 + # source://redis//lib/redis/distributed.rb#401 def getset(key, value); end # Delete one or more hash fields. # - # source://redis//lib/redis/distributed.rb#826 + # source://redis//lib/redis/distributed.rb#886 def hdel(key, *fields); end # Determine if a hash field exists. # - # source://redis//lib/redis/distributed.rb#831 + # source://redis//lib/redis/distributed.rb#892 def hexists(key, field); end # Get the value of a hash field. # - # source://redis//lib/redis/distributed.rb#808 + # source://redis//lib/redis/distributed.rb#866 def hget(key, field); end # Get all the fields and values in a hash. # - # source://redis//lib/redis/distributed.rb#856 + # source://redis//lib/redis/distributed.rb#917 def hgetall(key); end # Increment the integer value of a hash field by the given integer number. # - # source://redis//lib/redis/distributed.rb#836 + # source://redis//lib/redis/distributed.rb#897 def hincrby(key, field, increment); end # Increment the numeric value of a hash field by the given float number. # - # source://redis//lib/redis/distributed.rb#841 + # source://redis//lib/redis/distributed.rb#902 def hincrbyfloat(key, field, increment); end # Get all the fields in a hash. # - # source://redis//lib/redis/distributed.rb#846 + # source://redis//lib/redis/distributed.rb#907 def hkeys(key); end # Get the number of fields in a hash. # - # source://redis//lib/redis/distributed.rb#784 + # source://redis//lib/redis/distributed.rb#842 def hlen(key); end # Get the values of all the given hash fields. # - # source://redis//lib/redis/distributed.rb#813 + # source://redis//lib/redis/distributed.rb#871 def hmget(key, *fields); end # Set multiple hash fields to multiple values. # - # source://redis//lib/redis/distributed.rb#799 + # source://redis//lib/redis/distributed.rb#857 def hmset(key, *attrs); end - # source://redis//lib/redis/distributed.rb#821 + # source://redis//lib/redis/distributed.rb#881 def hrandfield(key, count = T.unsafe(nil), **options); end # Set multiple hash fields to multiple values. # - # source://redis//lib/redis/distributed.rb#789 + # source://redis//lib/redis/distributed.rb#847 def hset(key, *attrs); end # Set the value of a hash field, only if the field does not exist. # - # source://redis//lib/redis/distributed.rb#794 + # source://redis//lib/redis/distributed.rb#852 def hsetnx(key, field, value); end # Get all the values in a hash. # - # source://redis//lib/redis/distributed.rb#851 + # source://redis//lib/redis/distributed.rb#912 def hvals(key); end # Increment the integer value of a key by one. # - # source://redis//lib/redis/distributed.rb#265 + # source://redis//lib/redis/distributed.rb#276 def incr(key); end # Increment the integer value of a key by the given integer number. # - # source://redis//lib/redis/distributed.rb#270 + # source://redis//lib/redis/distributed.rb#281 def incrby(key, increment); end # Increment the numeric value of a key by the given float number. # - # source://redis//lib/redis/distributed.rb#275 + # source://redis//lib/redis/distributed.rb#286 def incrbyfloat(key, increment); end # Get information and statistics about the server. # - # source://redis//lib/redis/distributed.rb#88 + # source://redis//lib/redis/distributed.rb#94 def info(cmd = T.unsafe(nil)); end - # source://redis//lib/redis/distributed.rb#1002 + # source://redis//lib/redis/distributed.rb#1061 def inspect; end # Find all keys matching the given pattern. # - # source://redis//lib/redis/distributed.rb#205 + # source://redis//lib/redis/distributed.rb#216 def keys(glob = T.unsafe(nil)); end # Get the UNIX time stamp of the last successful save to disk. # - # source://redis//lib/redis/distributed.rb#93 + # source://redis//lib/redis/distributed.rb#99 def lastsave; end # Get an element from a list by its index. # - # source://redis//lib/redis/distributed.rb#508 + # source://redis//lib/redis/distributed.rb#526 def lindex(key, index); end # Insert an element before or after another element in a list. # - # source://redis//lib/redis/distributed.rb#513 + # source://redis//lib/redis/distributed.rb#531 def linsert(key, where, pivot, value); end # Get the length of a list. # - # source://redis//lib/redis/distributed.rb#405 + # source://redis//lib/redis/distributed.rb#419 def llen(key); end # Remove the first/last element in a list, append/prepend it to another list and return it. # - # source://redis//lib/redis/distributed.rb#410 + # source://redis//lib/redis/distributed.rb#424 def lmove(source, destination, where_source, where_destination); end + # Iterate over keys, removing elements from the first non list found. + # + # source://redis//lib/redis/distributed.rb#563 + def lmpop(*keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end + # Remove and get the first elements in a list. # - # source://redis//lib/redis/distributed.rb#445 + # source://redis//lib/redis/distributed.rb#459 def lpop(key, count = T.unsafe(nil)); end # Prepend one or more values to a list. # - # source://redis//lib/redis/distributed.rb#425 + # source://redis//lib/redis/distributed.rb#439 def lpush(key, value); end # Prepend a value to a list, only if the list exists. # - # source://redis//lib/redis/distributed.rb#430 + # source://redis//lib/redis/distributed.rb#444 def lpushx(key, value); end # Get a range of elements from a list. # - # source://redis//lib/redis/distributed.rb#518 + # source://redis//lib/redis/distributed.rb#536 def lrange(key, start, stop); end # Remove elements from a list. # - # source://redis//lib/redis/distributed.rb#523 + # source://redis//lib/redis/distributed.rb#541 def lrem(key, count, value); end # Set the value of an element in a list by its index. # - # source://redis//lib/redis/distributed.rb#528 + # source://redis//lib/redis/distributed.rb#546 def lset(key, index, value); end # Trim a list to the specified range. # - # source://redis//lib/redis/distributed.rb#533 + # source://redis//lib/redis/distributed.rb#551 def ltrim(key, start, stop); end - # source://redis//lib/redis/distributed.rb#817 + # source://redis//lib/redis/distributed.rb#876 def mapped_hmget(key, *fields); end - # source://redis//lib/redis/distributed.rb#803 + # source://redis//lib/redis/distributed.rb#861 def mapped_hmset(key, hash); end # Get the values of all the given keys as a Hash. # - # source://redis//lib/redis/distributed.rb#338 + # source://redis//lib/redis/distributed.rb#350 def mapped_mget(*keys); end # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#304 + # source://redis//lib/redis/distributed.rb#315 def mapped_mset(_hash); end # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#313 + # source://redis//lib/redis/distributed.rb#324 def mapped_msetnx(_hash); end # Get the values of all the given keys as an Array. # - # source://redis//lib/redis/distributed.rb#333 + # source://redis//lib/redis/distributed.rb#344 def mget(*keys); end # Transfer a key from the connected instance to another instance. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#158 + # source://redis//lib/redis/distributed.rb#174 def migrate(_key, _options); end # Listen for all requests received by the server in real time. # # @raise [NotImplementedError] # - # source://redis//lib/redis/distributed.rb#98 + # source://redis//lib/redis/distributed.rb#104 def monitor; end # Move a key to another database. # - # source://redis//lib/redis/distributed.rb#210 + # source://redis//lib/redis/distributed.rb#221 def move(key, db); end # Set multiple keys to multiple values. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#300 - def mset(*_args); end + # source://redis//lib/redis/distributed.rb#311 + def mset(*_arg0); end # Set multiple keys to multiple values, only if none of the keys exist. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#309 - def msetnx(*_args); end + # source://redis//lib/redis/distributed.rb#320 + def msetnx(*_arg0); end # Mark the start of a transaction block. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#928 + # source://redis//lib/redis/distributed.rb#989 def multi(&block); end # @raise [CannotDistribute] @@ -4341,65 +3485,70 @@ class Redis::Distributed # Remove the expiration from a key. # - # source://redis//lib/redis/distributed.rb#113 + # source://redis//lib/redis/distributed.rb#119 def persist(key); end # Set a key's time to live in milliseconds. # - # source://redis//lib/redis/distributed.rb#133 + # source://redis//lib/redis/distributed.rb#144 def pexpire(key, milliseconds, **kwarg); end # Set the expiration for a key as number of milliseconds from UNIX Epoch. # - # source://redis//lib/redis/distributed.rb#138 + # source://redis//lib/redis/distributed.rb#149 def pexpireat(key, ms_unix_time, **kwarg); end + # Get the expiration for a key as number of milliseconds from UNIX Epoch. + # + # source://redis//lib/redis/distributed.rb#154 + def pexpiretime(key); end + # Add one or more members to a HyperLogLog structure. # - # source://redis//lib/redis/distributed.rb#960 + # source://redis//lib/redis/distributed.rb#1019 def pfadd(key, member); end # Get the approximate cardinality of members added to HyperLogLog structure. # - # source://redis//lib/redis/distributed.rb#965 + # source://redis//lib/redis/distributed.rb#1024 def pfcount(*keys); end # Merge multiple HyperLogLog values into an unique value that will approximate the cardinality of the union of # the observed Sets of the source HyperLogLog structures. # - # source://redis//lib/redis/distributed.rb#973 + # source://redis//lib/redis/distributed.rb#1032 def pfmerge(dest_key, *source_key); end # Ping the server. # - # source://redis//lib/redis/distributed.rb#53 + # source://redis//lib/redis/distributed.rb#55 def ping; end # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#923 + # source://redis//lib/redis/distributed.rb#984 def pipelined; end # Set the time to live in milliseconds of a key. # - # source://redis//lib/redis/distributed.rb#290 + # source://redis//lib/redis/distributed.rb#301 def psetex(key, ttl, value); end # Listen for messages published to channels matching the given patterns. # # @raise [NotImplementedError] # - # source://redis//lib/redis/distributed.rb#890 + # source://redis//lib/redis/distributed.rb#951 def psubscribe(*channels, &block); end # Get the time to live (in milliseconds) for a key. # - # source://redis//lib/redis/distributed.rb#143 + # source://redis//lib/redis/distributed.rb#159 def pttl(key); end # Post a message to a channel. # - # source://redis//lib/redis/distributed.rb#861 + # source://redis//lib/redis/distributed.rb#922 def publish(channel, message); end # Stop listening for messages posted to channels matching the given @@ -4407,34 +3556,34 @@ class Redis::Distributed # # @raise [NotImplementedError] # - # source://redis//lib/redis/distributed.rb#896 + # source://redis//lib/redis/distributed.rb#957 def punsubscribe(*channels); end # Close the connection. # - # source://redis//lib/redis/distributed.rb#63 + # source://redis//lib/redis/distributed.rb#65 def quit; end # Return a random key from the keyspace. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#222 + # source://redis//lib/redis/distributed.rb#233 def randomkey; end # Rename a key. # - # source://redis//lib/redis/distributed.rb#227 + # source://redis//lib/redis/distributed.rb#238 def rename(old_name, new_name); end # Rename a key, only if the new key does not exist. # - # source://redis//lib/redis/distributed.rb#234 + # source://redis//lib/redis/distributed.rb#245 def renamenx(old_name, new_name); end # Create a key using the serialized value, previously obtained using DUMP. # - # source://redis//lib/redis/distributed.rb#153 + # source://redis//lib/redis/distributed.rb#169 def restore(key, ttl, serialized_value, **options); end # Returns the value of attribute ring. @@ -4444,357 +3593,364 @@ class Redis::Distributed # Remove and get the last elements in a list. # - # source://redis//lib/redis/distributed.rb#450 + # source://redis//lib/redis/distributed.rb#464 def rpop(key, count = T.unsafe(nil)); end # Remove the last element in a list, append it to another list and return # it. # - # source://redis//lib/redis/distributed.rb#456 + # source://redis//lib/redis/distributed.rb#470 def rpoplpush(source, destination); end # Append one or more values to a list. # - # source://redis//lib/redis/distributed.rb#435 + # source://redis//lib/redis/distributed.rb#449 def rpush(key, value); end # Append a value to a list, only if the list exists. # - # source://redis//lib/redis/distributed.rb#440 + # source://redis//lib/redis/distributed.rb#454 def rpushx(key, value); end # Add one or more members to a set. # - # source://redis//lib/redis/distributed.rb#543 - def sadd(key, member); end + # source://redis//lib/redis/distributed.rb#575 + def sadd(key, *members); end # Add one or more members to a set. # # @return [Boolean] # - # source://redis//lib/redis/distributed.rb#548 - def sadd?(key, member); end + # source://redis//lib/redis/distributed.rb#580 + def sadd?(key, *members); end # Synchronously save the dataset to disk. # - # source://redis//lib/redis/distributed.rb#103 + # source://redis//lib/redis/distributed.rb#109 def save; end # Get the number of members in a set. # - # source://redis//lib/redis/distributed.rb#538 + # source://redis//lib/redis/distributed.rb#570 def scard(key); end # Control remote script registry. # - # source://redis//lib/redis/distributed.rb#955 + # source://redis//lib/redis/distributed.rb#1014 def script(subcommand, *args); end # Subtract multiple sets. # - # source://redis//lib/redis/distributed.rb#605 + # source://redis//lib/redis/distributed.rb#637 def sdiff(*keys); end # Subtract multiple sets and store the resulting set in a key. # - # source://redis//lib/redis/distributed.rb#612 + # source://redis//lib/redis/distributed.rb#645 def sdiffstore(destination, *keys); end # Change the selected database for the current connection. # - # source://redis//lib/redis/distributed.rb#48 + # source://redis//lib/redis/distributed.rb#50 def select(db); end # Set the string value of a key. # - # source://redis//lib/redis/distributed.rb#280 + # source://redis//lib/redis/distributed.rb#291 def set(key, value, **options); end # Sets or clears the bit at offset in the string value stored at key. # - # source://redis//lib/redis/distributed.rb#355 + # source://redis//lib/redis/distributed.rb#368 def setbit(key, offset, value); end # Set the time to live in seconds of a key. # - # source://redis//lib/redis/distributed.rb#285 + # source://redis//lib/redis/distributed.rb#296 def setex(key, ttl, value); end # Set the value of a key, only if the key does not exist. # - # source://redis//lib/redis/distributed.rb#295 + # source://redis//lib/redis/distributed.rb#306 def setnx(key, value); end # Overwrite part of a string at key starting at the specified offset. # - # source://redis//lib/redis/distributed.rb#345 + # source://redis//lib/redis/distributed.rb#358 def setrange(key, offset, value); end # Intersect multiple sets. # - # source://redis//lib/redis/distributed.rb#619 + # source://redis//lib/redis/distributed.rb#653 def sinter(*keys); end # Intersect multiple sets and store the resulting set in a key. # - # source://redis//lib/redis/distributed.rb#626 + # source://redis//lib/redis/distributed.rb#661 def sinterstore(destination, *keys); end # Determine if a given value is a member of a set. # - # source://redis//lib/redis/distributed.rb#580 + # source://redis//lib/redis/distributed.rb#612 def sismember(key, member); end # Get all the members in a set. # - # source://redis//lib/redis/distributed.rb#590 + # source://redis//lib/redis/distributed.rb#622 def smembers(key); end # Determine if multiple values are members of a set. # - # source://redis//lib/redis/distributed.rb#585 + # source://redis//lib/redis/distributed.rb#617 def smismember(key, *members); end # Move a member from one set to another. # - # source://redis//lib/redis/distributed.rb#573 + # source://redis//lib/redis/distributed.rb#605 def smove(source, destination, member); end # Sort the elements in a list, set or sorted set. # - # source://redis//lib/redis/distributed.rb#241 + # source://redis//lib/redis/distributed.rb#252 def sort(key, **options); end # Remove and return a random member from a set. # - # source://redis//lib/redis/distributed.rb#563 + # source://redis//lib/redis/distributed.rb#595 def spop(key, count = T.unsafe(nil)); end # Get a random member from a set. # - # source://redis//lib/redis/distributed.rb#568 + # source://redis//lib/redis/distributed.rb#600 def srandmember(key, count = T.unsafe(nil)); end # Remove one or more members from a set. # - # source://redis//lib/redis/distributed.rb#553 - def srem(key, member); end + # source://redis//lib/redis/distributed.rb#585 + def srem(key, *members); end # Remove one or more members from a set. # # @return [Boolean] # - # source://redis//lib/redis/distributed.rb#558 - def srem?(key, member); end + # source://redis//lib/redis/distributed.rb#590 + def srem?(key, *members); end # Scan a set # - # source://redis//lib/redis/distributed.rb#595 + # source://redis//lib/redis/distributed.rb#627 def sscan(key, cursor, **options); end # Scan a set and return an enumerator # - # source://redis//lib/redis/distributed.rb#600 + # source://redis//lib/redis/distributed.rb#632 def sscan_each(key, **options, &block); end # Get the length of the value stored in a key. # - # source://redis//lib/redis/distributed.rb#392 + # source://redis//lib/redis/distributed.rb#406 def strlen(key); end # Listen for messages published to the given channels. # - # source://redis//lib/redis/distributed.rb#870 + # source://redis//lib/redis/distributed.rb#931 def subscribe(channel, *channels, &block); end # @return [Boolean] # - # source://redis//lib/redis/distributed.rb#865 + # source://redis//lib/redis/distributed.rb#926 def subscribed?; end # Add multiple sets. # - # source://redis//lib/redis/distributed.rb#633 + # source://redis//lib/redis/distributed.rb#669 def sunion(*keys); end # Add multiple sets and store the resulting set in a key. # - # source://redis//lib/redis/distributed.rb#640 + # source://redis//lib/redis/distributed.rb#677 def sunionstore(destination, *keys); end # Get server time: an UNIX timestamp and the elapsed microseconds in the current second. # - # source://redis//lib/redis/distributed.rb#108 + # source://redis//lib/redis/distributed.rb#114 def time; end # Get the time to live (in seconds) for a key. # - # source://redis//lib/redis/distributed.rb#128 + # source://redis//lib/redis/distributed.rb#139 def ttl(key); end # Determine the type stored at key. # - # source://redis//lib/redis/distributed.rb#250 + # source://redis//lib/redis/distributed.rb#261 def type(key); end # Unlink keys. # - # source://redis//lib/redis/distributed.rb#171 + # source://redis//lib/redis/distributed.rb#188 def unlink(*args); end # Stop listening for messages posted to the given channels. # - # source://redis//lib/redis/distributed.rb#883 + # @raise [SubscriptionError] + # + # source://redis//lib/redis/distributed.rb#944 def unsubscribe(*channels); end # Forget about all watched keys. # # @raise [CannotDistribute] # - # source://redis//lib/redis/distributed.rb#915 + # source://redis//lib/redis/distributed.rb#976 def unwatch; end # Watch the given keys to determine execution of the MULTI/EXEC block. # - # source://redis//lib/redis/distributed.rb#901 + # source://redis//lib/redis/distributed.rb#962 def watch(*keys, &block); end # Add one or more members to a sorted set, or update the score for members # that already exist. # - # source://redis//lib/redis/distributed.rb#653 + # source://redis//lib/redis/distributed.rb#691 def zadd(key, *args, **_arg2); end # Get the number of members in a sorted set. # - # source://redis//lib/redis/distributed.rb#647 + # source://redis//lib/redis/distributed.rb#685 def zcard(key); end # Get the number of members in a particular score range. # - # source://redis//lib/redis/distributed.rb#735 + # source://redis//lib/redis/distributed.rb#787 def zcount(key, min, max); end # Return the difference between the first and all successive input sorted sets. # - # source://redis//lib/redis/distributed.rb#769 + # source://redis//lib/redis/distributed.rb#825 def zdiff(*keys, **options); end # Compute the difference between the first and all successive input sorted sets # and store the resulting sorted set in a new key. # - # source://redis//lib/redis/distributed.rb#777 - def zdiffstore(destination, keys, **options); end + # source://redis//lib/redis/distributed.rb#834 + def zdiffstore(destination, *keys, **options); end # Increment the score of a member in a sorted set. # - # source://redis//lib/redis/distributed.rb#659 + # source://redis//lib/redis/distributed.rb#697 def zincrby(key, increment, member); end # Get the intersection of multiple sorted sets # - # source://redis//lib/redis/distributed.rb#740 + # source://redis//lib/redis/distributed.rb#792 def zinter(*keys, **options); end # Intersect multiple sorted sets and store the resulting sorted set in a new # key. # - # source://redis//lib/redis/distributed.rb#748 - def zinterstore(destination, keys, **options); end + # source://redis//lib/redis/distributed.rb#801 + def zinterstore(destination, *keys, **options); end + + # Iterate over keys, removing members from the first non empty sorted set found. + # + # source://redis//lib/redis/distributed.rb#729 + def zmpop(*keys, modifier: T.unsafe(nil), count: T.unsafe(nil)); end # Get the scores associated with the given members in a sorted set. # - # source://redis//lib/redis/distributed.rb#679 + # source://redis//lib/redis/distributed.rb#717 def zmscore(key, *members); end # Get one or more random members from a sorted set. # - # source://redis//lib/redis/distributed.rb#674 + # source://redis//lib/redis/distributed.rb#712 def zrandmember(key, count = T.unsafe(nil), **options); end # Return a range of members in a sorted set, by index, score or lexicographical ordering. # - # source://redis//lib/redis/distributed.rb#684 + # source://redis//lib/redis/distributed.rb#736 def zrange(key, start, stop, **options); end # Return a range of members in a sorted set, by score. # - # source://redis//lib/redis/distributed.rb#719 + # source://redis//lib/redis/distributed.rb#771 def zrangebyscore(key, min, max, **options); end # Select a range of members in a sorted set, by index, score or lexicographical ordering # and store the resulting sorted set in a new key. # - # source://redis//lib/redis/distributed.rb#690 + # source://redis//lib/redis/distributed.rb#742 def zrangestore(dest_key, src_key, start, stop, **options); end # Determine the index of a member in a sorted set. # - # source://redis//lib/redis/distributed.rb#703 + # source://redis//lib/redis/distributed.rb#755 def zrank(key, member); end # Remove one or more members from a sorted set. # - # source://redis//lib/redis/distributed.rb#664 + # source://redis//lib/redis/distributed.rb#702 def zrem(key, member); end # Remove all members in a sorted set within the given indexes. # - # source://redis//lib/redis/distributed.rb#714 + # source://redis//lib/redis/distributed.rb#766 def zremrangebyrank(key, start, stop); end # Remove all members in a sorted set within the given scores. # - # source://redis//lib/redis/distributed.rb#730 + # source://redis//lib/redis/distributed.rb#782 def zremrangebyscore(key, min, max); end # Return a range of members in a sorted set, by index, with scores ordered # from high to low. # - # source://redis//lib/redis/distributed.rb#698 + # source://redis//lib/redis/distributed.rb#750 def zrevrange(key, start, stop, **options); end # Return a range of members in a sorted set, by score, with scores ordered # from high to low. # - # source://redis//lib/redis/distributed.rb#725 + # source://redis//lib/redis/distributed.rb#777 def zrevrangebyscore(key, max, min, **options); end # Determine the index of a member in a sorted set, with scores ordered from # high to low. # - # source://redis//lib/redis/distributed.rb#709 + # source://redis//lib/redis/distributed.rb#761 def zrevrank(key, member); end # Get the score associated with the given member in a sorted set. # - # source://redis//lib/redis/distributed.rb#669 + # source://redis//lib/redis/distributed.rb#707 def zscore(key, member); end # Return the union of multiple sorted sets. # - # source://redis//lib/redis/distributed.rb#755 + # source://redis//lib/redis/distributed.rb#809 def zunion(*keys, **options); end # Add multiple sorted sets and store the resulting sorted set in a new key. # - # source://redis//lib/redis/distributed.rb#762 - def zunionstore(destination, keys, **options); end + # source://redis//lib/redis/distributed.rb#817 + def zunionstore(destination, *keys, **options); end protected # @yield [node_for(keys.first)] # - # source://redis//lib/redis/distributed.rb#1026 + # source://redis//lib/redis/distributed.rb#1086 def ensure_same_node(command, keys); end - # source://redis//lib/redis/distributed.rb#1022 + # source://redis//lib/redis/distributed.rb#1081 def key_tag(key); end - # source://redis//lib/redis/distributed.rb#1018 + # source://redis//lib/redis/distributed.rb#1077 def node_index_for(key); end - # source://redis//lib/redis/distributed.rb#1012 + # source://redis//lib/redis/distributed.rb#1071 def on_each_node(command, *args); end end @@ -4809,54 +3965,43 @@ class Redis::Distributed::CannotDistribute < ::RuntimeError def message; end end -# source://redis//lib/redis/pipeline.rb#244 +# source://redis//lib/redis/pipeline.rb#80 class Redis::Future < ::BasicObject # @return [Future] a new instance of Future # - # source://redis//lib/redis/pipeline.rb#249 - def initialize(command, transformation, timeout); end + # source://redis//lib/redis/pipeline.rb#83 + def initialize(command, coerce, exception); end - # source://redis//lib/redis/pipeline.rb#256 - def ==(_other); end - - # source://redis//lib/redis/pipeline.rb#275 - def _command; end - - # source://redis//lib/redis/pipeline.rb#270 + # source://redis//lib/redis/pipeline.rb#94 def _set(object); end - # source://redis//lib/redis/pipeline.rb#288 + # source://redis//lib/redis/pipeline.rb#108 def class; end - # source://redis//lib/redis/pipeline.rb#266 + # source://redis//lib/redis/pipeline.rb#90 def inspect; end # @return [Boolean] # - # source://redis//lib/redis/pipeline.rb#284 + # source://redis//lib/redis/pipeline.rb#104 def is_a?(other); end - # Returns the value of attribute timeout. - # - # source://redis//lib/redis/pipeline.rb#247 - def timeout; end - - # source://redis//lib/redis/pipeline.rb#279 + # source://redis//lib/redis/pipeline.rb#99 def value; end end -# source://redis//lib/redis/pipeline.rb#245 +# source://redis//lib/redis/pipeline.rb#81 Redis::Future::FutureNotReady = T.let(T.unsafe(nil), Redis::FutureNotReady) -# source://redis//lib/redis/pipeline.rb#238 +# source://redis//lib/redis/pipeline.rb#74 class Redis::FutureNotReady < ::RuntimeError # @return [FutureNotReady] a new instance of FutureNotReady # - # source://redis//lib/redis/pipeline.rb#239 + # source://redis//lib/redis/pipeline.rb#75 def initialize; end end -# source://redis//lib/redis/hash_ring.rb#6 +# source://redis//lib/redis/hash_ring.rb#7 class Redis::HashRing # nodes is a list of objects that have a proper to_s representation. # replicas indicates how many virtual points should be used pr. node, @@ -4864,192 +4009,107 @@ class Redis::HashRing # # @return [HashRing] a new instance of HashRing # - # source://redis//lib/redis/hash_ring.rb#14 + # source://redis//lib/redis/hash_ring.rb#15 def initialize(nodes = T.unsafe(nil), replicas = T.unsafe(nil)); end # Adds a `node` to the hash ring (including a number of replicas). # - # source://redis//lib/redis/hash_ring.rb#25 + # source://redis//lib/redis/hash_ring.rb#26 def add_node(node); end # get the node in the hash ring for this key # - # source://redis//lib/redis/hash_ring.rb#45 + # source://redis//lib/redis/hash_ring.rb#46 def get_node(key); end - # source://redis//lib/redis/hash_ring.rb#49 - def get_node_pos(key); end - - # source://redis//lib/redis/hash_ring.rb#57 + # source://redis//lib/redis/hash_ring.rb#52 def iter_nodes(key); end # Returns the value of attribute nodes. # - # source://redis//lib/redis/hash_ring.rb#9 + # source://redis//lib/redis/hash_ring.rb#10 def nodes; end - # source://redis//lib/redis/hash_ring.rb#35 + # source://redis//lib/redis/hash_ring.rb#36 def remove_node(node); end # Returns the value of attribute replicas. # - # source://redis//lib/redis/hash_ring.rb#9 + # source://redis//lib/redis/hash_ring.rb#10 def replicas; end # Returns the value of attribute ring. # - # source://redis//lib/redis/hash_ring.rb#9 + # source://redis//lib/redis/hash_ring.rb#10 def ring; end # Returns the value of attribute sorted_keys. # - # source://redis//lib/redis/hash_ring.rb#9 + # source://redis//lib/redis/hash_ring.rb#10 def sorted_keys; end - class << self - # Find the closest index in HashRing with value <= the given value - # - # source://redis//lib/redis/hash_ring.rb#67 - def binary_search(ary, value); end - end + private + + # Find the closest index in HashRing with value <= the given value + # + # source://redis//lib/redis/hash_ring.rb#73 + def binary_search(ary, value); end + + # source://redis//lib/redis/hash_ring.rb#64 + def hash_for(key); end + + # source://redis//lib/redis/hash_ring.rb#68 + def server_hash_for(key); end end # this is the default in libmemcached # -# source://redis//lib/redis/hash_ring.rb#7 +# source://redis//lib/redis/hash_ring.rb#8 Redis::HashRing::POINTS_PER_SERVER = T.let(T.unsafe(nil), Integer) # Raised when the connection was inherited by a child process. # -# source://redis//lib/redis/errors.rb#40 +# source://redis//lib/redis/errors.rb#49 class Redis::InheritedError < ::Redis::BaseConnectionError; end # Raised when client options are invalid. # -# source://redis//lib/redis/errors.rb#44 +# source://redis//lib/redis/errors.rb#57 class Redis::InvalidClientOptionError < ::Redis::BaseError; end -# source://redis//lib/redis/pipeline.rb#293 -class Redis::MultiFuture < ::Redis::Future - # @return [MultiFuture] a new instance of MultiFuture - # - # source://redis//lib/redis/pipeline.rb#294 - def initialize(futures); end - - # source://redis//lib/redis/pipeline.rb#299 - def _set(replies); end -end - -# source://redis//lib/redis/pipeline.rb#45 -class Redis::Pipeline - # @return [Pipeline] a new instance of Pipeline - # - # source://redis//lib/redis/pipeline.rb#79 - def initialize(client); end - - # source://redis//lib/redis/pipeline.rb#106 - def call(command, timeout: T.unsafe(nil), &block); end - - # source://redis//lib/redis/pipeline.rb#119 - def call_pipeline(pipeline); end - - # source://redis//lib/redis/pipeline.rb#115 - def call_with_timeout(command, timeout, &block); end - - # Returns the value of attribute client. - # - # source://redis//lib/redis/pipeline.rb#74 - def client; end - - # source://redis//lib/redis/pipeline.rb#126 - def commands; end - - # Returns the value of attribute db. - # - # source://redis//lib/redis/pipeline.rb#73 - def db; end - - # Sets the attribute db - # - # @param value the value to set the attribute db to. - # - # source://redis//lib/redis/pipeline.rb#73 - def db=(_arg0); end - - # @return [Boolean] - # - # source://redis//lib/redis/pipeline.rb#102 - def empty?; end - - # source://redis//lib/redis/pipeline.rb#143 - def finish(replies, &blk); end - - # Returns the value of attribute futures. - # - # source://redis//lib/redis/pipeline.rb#76 - def futures; end - - # Returns the value of attribute futures. - # - # source://redis//lib/redis/pipeline.rb#76 - def materialized_futures; end - - # @return [Boolean] - # - # source://redis//lib/redis/pipeline.rb#98 - def shutdown?; end - - # source://redis//lib/redis/pipeline.rb#86 - def timeout; end - - # source://redis//lib/redis/pipeline.rb#130 - def timeouts; end - - # source://redis//lib/redis/pipeline.rb#134 - def with_reconnect(val = T.unsafe(nil)); end - - # @return [Boolean] +# source://redis//lib/redis/pipeline.rb#59 +class Redis::MultiConnection < ::Redis::PipelinedConnection + # @raise [Redis::Error] # - # source://redis//lib/redis/pipeline.rb#90 - def with_reconnect?; end + # source://redis//lib/redis/pipeline.rb#60 + def multi; end - # source://redis//lib/redis/pipeline.rb#139 - def without_reconnect(&blk); end + private - # @return [Boolean] + # Blocking commands inside transaction behave like non-blocking. + # It shouldn't be done though. + # https://redis.io/commands/blpop/#blpop-inside-a-multi--exec-transaction # - # source://redis//lib/redis/pipeline.rb#94 - def without_reconnect?; end - - class << self - # source://redis//lib/redis/pipeline.rb#52 - def deprecation_warning(method, caller_locations); end - end + # source://redis//lib/redis/pipeline.rb#69 + def send_blocking_command(command, _timeout, &block); end end -# source://redis//lib/redis/pipeline.rb#155 -class Redis::Pipeline::Multi < ::Redis::Pipeline - # source://redis//lib/redis/pipeline.rb#198 - def commands; end - - # source://redis//lib/redis/pipeline.rb#156 - def finish(replies); end - - # source://redis//lib/redis/pipeline.rb#178 - def materialized_futures; end +# source://redis//lib/redis/pipeline.rb#113 +class Redis::MultiFuture < ::Redis::Future + # @return [MultiFuture] a new instance of MultiFuture + # + # source://redis//lib/redis/pipeline.rb#114 + def initialize(futures); end - # source://redis//lib/redis/pipeline.rb#190 - def timeouts; end + # source://redis//lib/redis/pipeline.rb#120 + def _set(replies); end end -# source://redis//lib/redis/pipeline.rb#46 -Redis::Pipeline::REDIS_INTERNAL_PATH = T.let(T.unsafe(nil), String) +# source://redis//lib/redis/errors.rb#29 +class Redis::OutOfMemoryError < ::Redis::CommandError; end -# Redis use MonitorMixin#synchronize and this class use DelegateClass which we want to filter out. -# Both are in the stdlib so we can simply filter the entire stdlib out. -# -# source://redis//lib/redis/pipeline.rb#49 -Redis::Pipeline::STDLIB_PATH = T.let(T.unsafe(nil), String) +# source://redis//lib/redis/errors.rb#23 +class Redis::PermissionError < ::Redis::CommandError; end # source://redis//lib/redis/pipeline.rb#6 class Redis::PipelinedConnection @@ -5073,36 +4133,44 @@ class Redis::PipelinedConnection # @return [PipelinedConnection] a new instance of PipelinedConnection # - # source://redis//lib/redis/pipeline.rb#7 - def initialize(pipeline); end - - # source://redis//lib/redis/pipeline.rb#25 - def call_pipeline(pipeline); end + # source://redis//lib/redis/pipeline.rb#9 + def initialize(pipeline, futures = T.unsafe(nil), exception: T.unsafe(nil)); end - # source://redis//lib/redis/pipeline.rb#13 + # Returns the value of attribute db. + # + # source://redis//lib/redis/pipeline.rb#7 def db; end - # source://redis//lib/redis/pipeline.rb#17 - def db=(db); end + # Sets the attribute db + # + # @param value the value to set the attribute db to. + # + # source://redis//lib/redis/pipeline.rb#7 + def db=(_arg0); end + + # @yield [transaction] + # + # source://redis//lib/redis/pipeline.rb#21 + def multi; end # @yield [_self] # @yieldparam _self [Redis::PipelinedConnection] the object that the method was called on # - # source://redis//lib/redis/pipeline.rb#21 + # source://redis//lib/redis/pipeline.rb#17 def pipelined; end private - # source://redis//lib/redis/pipeline.rb#40 + # source://redis//lib/redis/pipeline.rb#49 def send_blocking_command(command, timeout, &block); end - # source://redis//lib/redis/pipeline.rb#36 + # source://redis//lib/redis/pipeline.rb#40 def send_command(command, &block); end # @yield [_self] # @yieldparam _self [Redis::PipelinedConnection] the object that the method was called on # - # source://redis//lib/redis/pipeline.rb#32 + # source://redis//lib/redis/pipeline.rb#36 def synchronize; end end @@ -5116,6 +4184,14 @@ class Redis::ProtocolError < ::Redis::BaseError def initialize(reply_type); end end +# Generally raised during Redis failover scenarios +# +# source://redis//lib/redis/errors.rb#53 +class Redis::ReadOnlyError < ::Redis::BaseConnectionError; end + +# source://redis//lib/redis.rb#37 +Redis::SERVER_URL_OPTIONS = T.let(T.unsafe(nil), Array) + # source://redis//lib/redis/subscribe.rb#4 class Redis::SubscribedClient # @return [SubscribedClient] a new instance of SubscribedClient @@ -5123,70 +4199,97 @@ class Redis::SubscribedClient # source://redis//lib/redis/subscribe.rb#5 def initialize(client); end - # source://redis//lib/redis/subscribe.rb#9 - def call(command); end + # source://redis//lib/redis/subscribe.rb#10 + def call_v(command); end - # source://redis//lib/redis/subscribe.rb#21 + # source://redis//lib/redis/subscribe.rb#52 + def close; end + + # source://redis//lib/redis/subscribe.rb#24 def psubscribe(*channels, &block); end - # source://redis//lib/redis/subscribe.rb#25 + # source://redis//lib/redis/subscribe.rb#28 def psubscribe_with_timeout(timeout, *channels, &block); end - # source://redis//lib/redis/subscribe.rb#33 + # source://redis//lib/redis/subscribe.rb#44 def punsubscribe(*channels); end - # source://redis//lib/redis/subscribe.rb#13 + # source://redis//lib/redis/subscribe.rb#32 + def ssubscribe(*channels, &block); end + + # source://redis//lib/redis/subscribe.rb#36 + def ssubscribe_with_timeout(timeout, *channels, &block); end + + # source://redis//lib/redis/subscribe.rb#16 def subscribe(*channels, &block); end - # source://redis//lib/redis/subscribe.rb#17 + # source://redis//lib/redis/subscribe.rb#20 def subscribe_with_timeout(timeout, *channels, &block); end - # source://redis//lib/redis/subscribe.rb#29 + # source://redis//lib/redis/subscribe.rb#48 + def sunsubscribe(*channels); end + + # source://redis//lib/redis/subscribe.rb#40 def unsubscribe(*channels); end protected - # source://redis//lib/redis/subscribe.rb#39 + # source://redis//lib/redis/subscribe.rb#58 def subscription(start, stop, channels, block, timeout = T.unsafe(nil)); end end -# source://redis//lib/redis/subscribe.rb#55 +# source://redis//lib/redis/subscribe.rb#82 class Redis::Subscription # @return [Subscription] a new instance of Subscription # @yield [_self] # @yieldparam _self [Redis::Subscription] the object that the method was called on # - # source://redis//lib/redis/subscribe.rb#58 + # source://redis//lib/redis/subscribe.rb#85 def initialize; end # Returns the value of attribute callbacks. # - # source://redis//lib/redis/subscribe.rb#56 + # source://redis//lib/redis/subscribe.rb#83 def callbacks; end - # source://redis//lib/redis/subscribe.rb#74 + # source://redis//lib/redis/subscribe.rb#98 def message(&block); end - # source://redis//lib/redis/subscribe.rb#86 + # source://redis//lib/redis/subscribe.rb#110 def pmessage(&block); end - # source://redis//lib/redis/subscribe.rb#78 + # source://redis//lib/redis/subscribe.rb#102 def psubscribe(&block); end - # source://redis//lib/redis/subscribe.rb#82 + # source://redis//lib/redis/subscribe.rb#106 def punsubscribe(&block); end - # source://redis//lib/redis/subscribe.rb#66 + # source://redis//lib/redis/subscribe.rb#122 + def smessage(&block); end + + # source://redis//lib/redis/subscribe.rb#114 + def ssubscribe(&block); end + + # source://redis//lib/redis/subscribe.rb#90 def subscribe(&block); end - # source://redis//lib/redis/subscribe.rb#70 + # source://redis//lib/redis/subscribe.rb#118 + def sunsubscribe(&block); end + + # source://redis//lib/redis/subscribe.rb#94 def unsubscribe(&block); end end +# source://redis//lib/redis/errors.rb#60 +class Redis::SubscriptionError < ::Redis::BaseError; end + # Raised when performing I/O times out. # -# source://redis//lib/redis/errors.rb#36 +# source://redis//lib/redis/errors.rb#45 class Redis::TimeoutError < ::Redis::BaseConnectionError; end # source://redis//lib/redis/version.rb#4 Redis::VERSION = T.let(T.unsafe(nil), String) + +# source://redis//lib/redis/errors.rb#26 +class Redis::WrongTypeError < ::Redis::CommandError; end diff --git a/sorbet/rbi/gems/regexp_parser@2.8.1.rbi b/sorbet/rbi/gems/regexp_parser@2.9.2.rbi similarity index 96% rename from sorbet/rbi/gems/regexp_parser@2.8.1.rbi rename to sorbet/rbi/gems/regexp_parser@2.9.2.rbi index e10d9b8de..584c4553e 100644 --- a/sorbet/rbi/gems/regexp_parser@2.8.1.rbi +++ b/sorbet/rbi/gems/regexp_parser@2.9.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `regexp_parser` gem. # Please instead update this file by running `bin/tapioca gem regexp_parser`. + # source://regexp_parser//lib/regexp_parser/expression/shared.rb#1 module Regexp::Expression; end @@ -94,6 +95,9 @@ end class Regexp::Expression::Anchor::NonWordBoundary < ::Regexp::Expression::Anchor::Base # source://regexp_parser//lib/regexp_parser/expression/methods/human_name.rb#17 def human_name; end + + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#13 + def negative?; end end # source://regexp_parser//lib/regexp_parser/expression/classes/anchor.rb#13 @@ -127,12 +131,18 @@ end class Regexp::Expression::Assertion::NegativeLookahead < ::Regexp::Expression::Assertion::Base # source://regexp_parser//lib/regexp_parser/expression/methods/human_name.rb#21 def human_name; end + + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#14 + def negative?; end end # source://regexp_parser//lib/regexp_parser/expression/classes/group.rb#71 class Regexp::Expression::Assertion::NegativeLookbehind < ::Regexp::Expression::Assertion::Base # source://regexp_parser//lib/regexp_parser/expression/methods/human_name.rb#22 def human_name; end + + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#15 + def negative?; end end # alias for symmetry between token symbol and Expression class name @@ -574,10 +584,10 @@ end class Regexp::Expression::CharacterSet < ::Regexp::Expression::Subexpression # @return [CharacterSet] a new instance of CharacterSet # - # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#9 + # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#6 def initialize(token, options = T.unsafe(nil)); end - # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#19 + # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#16 def close; end # Returns the value of attribute closed. @@ -600,14 +610,9 @@ class Regexp::Expression::CharacterSet < ::Regexp::Expression::Subexpression # source://regexp_parser//lib/regexp_parser/expression/methods/match_length.rb#98 def match_length; end - # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#15 + # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#12 def negate; end - # Returns the value of attribute negative. - # - # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#3 - def negated?; end - # Returns the value of attribute negative. # # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#3 @@ -620,9 +625,7 @@ class Regexp::Expression::CharacterSet < ::Regexp::Expression::Subexpression # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#3 def negative=(_arg0); end - # Returns the value of attribute negative. - # - # source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#3 + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#16 def negative?; end # source://regexp_parser//lib/regexp_parser/expression/methods/parts.rb#15 @@ -686,6 +689,9 @@ end class Regexp::Expression::CharacterType::Base < ::Regexp::Expression::Base # source://regexp_parser//lib/regexp_parser/expression/methods/match_length.rb#98 def match_length; end + + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#17 + def negative?; end end # source://regexp_parser//lib/regexp_parser/expression/classes/character_type.rb#6 @@ -1127,7 +1133,7 @@ end # source://regexp_parser//lib/regexp_parser/expression/classes/keep.rb#2 module Regexp::Expression::Keep; end -# TOOD: in regexp_parser v3.0.0 this should possibly be a Subexpression +# TODO: in regexp_parser v3.0.0 this should possibly be a Subexpression # that contains all expressions to its left. # # source://regexp_parser//lib/regexp_parser/expression/classes/keep.rb#5 @@ -1151,10 +1157,10 @@ end # source://regexp_parser//lib/regexp_parser/expression/methods/match_length.rb#85 Regexp::Expression::MatchLength = Regexp::MatchLength -# source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#14 +# source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#10 Regexp::Expression::Nonposixclass = Regexp::Expression::PosixClass -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#121 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#118 Regexp::Expression::Nonproperty = Regexp::Expression::UnicodeProperty # source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#2 @@ -1162,23 +1168,21 @@ class Regexp::Expression::PosixClass < ::Regexp::Expression::Base # source://regexp_parser//lib/regexp_parser/expression/methods/match_length.rb#98 def match_length; end - # source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#7 + # source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#3 def name; end - # @return [Boolean] - # - # source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#3 + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#18 def negative?; end end # alias for symmetry between token symbol and Expression class name # -# source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#13 +# source://regexp_parser//lib/regexp_parser/expression/classes/posix_class.rb#9 Regexp::Expression::Posixclass = Regexp::Expression::PosixClass # alias for symmetry between token symbol and Expression class name # -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#120 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#117 Regexp::Expression::Property = Regexp::Expression::UnicodeProperty # TODO: in v3.0.0, maybe put Shared back into Base, and inherit from Base and @@ -1370,7 +1374,7 @@ end # alias for symmetry between token symbol and Expression class name # -# source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#25 +# source://regexp_parser//lib/regexp_parser/expression/classes/character_set.rb#22 Regexp::Expression::Set = Regexp::Expression::CharacterSet # source://regexp_parser//lib/regexp_parser/expression/shared.rb#2 @@ -1453,6 +1457,18 @@ module Regexp::Expression::Shared # source://regexp_parser//lib/regexp_parser/expression/methods/tests.rb#36 def is?(test_token, test_type = T.unsafe(nil)); end + # not an alias so as to respect overrides of #negative? + # + # @return [Boolean] + # + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#8 + def negated?; end + + # @return [Boolean] + # + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#3 + def negative?; end + # source://regexp_parser//lib/regexp_parser/expression/shared.rb#100 def nesting_level=(lvl); end @@ -1794,22 +1810,22 @@ end # source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#2 module Regexp::Expression::UnicodeProperty; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#112 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#108 class Regexp::Expression::UnicodeProperty::Age < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#17 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#13 class Regexp::Expression::UnicodeProperty::Alnum < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#18 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#14 class Regexp::Expression::UnicodeProperty::Alpha < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#35 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#31 class Regexp::Expression::UnicodeProperty::Any < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#19 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#15 class Regexp::Expression::UnicodeProperty::Ascii < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#36 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#32 class Regexp::Expression::UnicodeProperty::Assigned < ::Regexp::Expression::UnicodeProperty::Base; end # source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#3 @@ -1817,226 +1833,227 @@ class Regexp::Expression::UnicodeProperty::Base < ::Regexp::Expression::Base # source://regexp_parser//lib/regexp_parser/expression/methods/match_length.rb#98 def match_length; end - # source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#8 + # source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#4 def name; end - # @return [Boolean] - # - # source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#4 + # source://regexp_parser//lib/regexp_parser/expression/methods/negative.rb#19 def negative?; end - # source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#12 + # source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#8 def shortcut; end end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#20 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#16 class Regexp::Expression::UnicodeProperty::Blank < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#116 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#109 class Regexp::Expression::UnicodeProperty::Block < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#21 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#17 class Regexp::Expression::UnicodeProperty::Cntrl < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#101 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#97 module Regexp::Expression::UnicodeProperty::Codepoint; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#104 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#100 class Regexp::Expression::UnicodeProperty::Codepoint::Any < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#102 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#98 class Regexp::Expression::UnicodeProperty::Codepoint::Base < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#105 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#101 class Regexp::Expression::UnicodeProperty::Codepoint::Control < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#106 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#102 class Regexp::Expression::UnicodeProperty::Codepoint::Format < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#108 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#104 class Regexp::Expression::UnicodeProperty::Codepoint::PrivateUse < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#107 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#103 class Regexp::Expression::UnicodeProperty::Codepoint::Surrogate < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#109 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#105 class Regexp::Expression::UnicodeProperty::Codepoint::Unassigned < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#113 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#110 class Regexp::Expression::UnicodeProperty::Derived < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#22 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#18 class Regexp::Expression::UnicodeProperty::Digit < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#114 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#111 class Regexp::Expression::UnicodeProperty::Emoji < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#23 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#112 +class Regexp::Expression::UnicodeProperty::Enumerated < ::Regexp::Expression::UnicodeProperty::Base; end + +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#19 class Regexp::Expression::UnicodeProperty::Graph < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#38 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#34 module Regexp::Expression::UnicodeProperty::Letter; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#41 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#37 class Regexp::Expression::UnicodeProperty::Letter::Any < ::Regexp::Expression::UnicodeProperty::Letter::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#39 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#35 class Regexp::Expression::UnicodeProperty::Letter::Base < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#42 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#38 class Regexp::Expression::UnicodeProperty::Letter::Cased < ::Regexp::Expression::UnicodeProperty::Letter::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#44 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#40 class Regexp::Expression::UnicodeProperty::Letter::Lowercase < ::Regexp::Expression::UnicodeProperty::Letter::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#46 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#42 class Regexp::Expression::UnicodeProperty::Letter::Modifier < ::Regexp::Expression::UnicodeProperty::Letter::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#47 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#43 class Regexp::Expression::UnicodeProperty::Letter::Other < ::Regexp::Expression::UnicodeProperty::Letter::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#45 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#41 class Regexp::Expression::UnicodeProperty::Letter::Titlecase < ::Regexp::Expression::UnicodeProperty::Letter::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#43 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#39 class Regexp::Expression::UnicodeProperty::Letter::Uppercase < ::Regexp::Expression::UnicodeProperty::Letter::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#24 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#20 class Regexp::Expression::UnicodeProperty::Lower < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#50 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#46 module Regexp::Expression::UnicodeProperty::Mark; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#53 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#49 class Regexp::Expression::UnicodeProperty::Mark::Any < ::Regexp::Expression::UnicodeProperty::Mark::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#51 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#47 class Regexp::Expression::UnicodeProperty::Mark::Base < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#54 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#50 class Regexp::Expression::UnicodeProperty::Mark::Combining < ::Regexp::Expression::UnicodeProperty::Mark::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#57 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#53 class Regexp::Expression::UnicodeProperty::Mark::Enclosing < ::Regexp::Expression::UnicodeProperty::Mark::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#55 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#51 class Regexp::Expression::UnicodeProperty::Mark::Nonspacing < ::Regexp::Expression::UnicodeProperty::Mark::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#56 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#52 class Regexp::Expression::UnicodeProperty::Mark::Spacing < ::Regexp::Expression::UnicodeProperty::Mark::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#33 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#29 class Regexp::Expression::UnicodeProperty::Newline < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#60 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#56 module Regexp::Expression::UnicodeProperty::Number; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#63 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#59 class Regexp::Expression::UnicodeProperty::Number::Any < ::Regexp::Expression::UnicodeProperty::Number::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#61 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#57 class Regexp::Expression::UnicodeProperty::Number::Base < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#64 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#60 class Regexp::Expression::UnicodeProperty::Number::Decimal < ::Regexp::Expression::UnicodeProperty::Number::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#65 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#61 class Regexp::Expression::UnicodeProperty::Number::Letter < ::Regexp::Expression::UnicodeProperty::Number::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#66 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#62 class Regexp::Expression::UnicodeProperty::Number::Other < ::Regexp::Expression::UnicodeProperty::Number::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#25 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#21 class Regexp::Expression::UnicodeProperty::Print < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#26 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#22 class Regexp::Expression::UnicodeProperty::Punct < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#69 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#65 module Regexp::Expression::UnicodeProperty::Punctuation; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#72 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#68 class Regexp::Expression::UnicodeProperty::Punctuation::Any < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#70 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#66 class Regexp::Expression::UnicodeProperty::Punctuation::Base < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#76 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#72 class Regexp::Expression::UnicodeProperty::Punctuation::Close < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#73 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#69 class Regexp::Expression::UnicodeProperty::Punctuation::Connector < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#74 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#70 class Regexp::Expression::UnicodeProperty::Punctuation::Dash < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#78 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#74 class Regexp::Expression::UnicodeProperty::Punctuation::Final < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#77 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#73 class Regexp::Expression::UnicodeProperty::Punctuation::Initial < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#75 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#71 class Regexp::Expression::UnicodeProperty::Punctuation::Open < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#79 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#75 class Regexp::Expression::UnicodeProperty::Punctuation::Other < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#115 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#113 class Regexp::Expression::UnicodeProperty::Script < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#82 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#78 module Regexp::Expression::UnicodeProperty::Separator; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#85 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#81 class Regexp::Expression::UnicodeProperty::Separator::Any < ::Regexp::Expression::UnicodeProperty::Separator::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#83 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#79 class Regexp::Expression::UnicodeProperty::Separator::Base < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#87 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#83 class Regexp::Expression::UnicodeProperty::Separator::Line < ::Regexp::Expression::UnicodeProperty::Separator::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#88 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#84 class Regexp::Expression::UnicodeProperty::Separator::Paragraph < ::Regexp::Expression::UnicodeProperty::Separator::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#86 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#82 class Regexp::Expression::UnicodeProperty::Separator::Space < ::Regexp::Expression::UnicodeProperty::Separator::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#27 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#23 class Regexp::Expression::UnicodeProperty::Space < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#91 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#87 module Regexp::Expression::UnicodeProperty::Symbol; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#94 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#90 class Regexp::Expression::UnicodeProperty::Symbol::Any < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#92 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#88 class Regexp::Expression::UnicodeProperty::Symbol::Base < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#96 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#92 class Regexp::Expression::UnicodeProperty::Symbol::Currency < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#95 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#91 class Regexp::Expression::UnicodeProperty::Symbol::Math < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#97 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#93 class Regexp::Expression::UnicodeProperty::Symbol::Modifier < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#98 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#94 class Regexp::Expression::UnicodeProperty::Symbol::Other < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#28 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#24 class Regexp::Expression::UnicodeProperty::Upper < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#29 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#25 class Regexp::Expression::UnicodeProperty::Word < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#31 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#27 class Regexp::Expression::UnicodeProperty::XPosixPunct < ::Regexp::Expression::UnicodeProperty::Base; end -# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#30 +# source://regexp_parser//lib/regexp_parser/expression/classes/unicode_property.rb#26 class Regexp::Expression::UnicodeProperty::Xdigit < ::Regexp::Expression::UnicodeProperty::Base; end # source://regexp_parser//lib/regexp_parser/expression/classes/free_space.rb#11 @@ -2343,7 +2360,7 @@ class Regexp::Parser private - # source://regexp_parser//lib/regexp_parser/parser.rb#573 + # source://regexp_parser//lib/regexp_parser/parser.rb#574 def active_opts; end # source://regexp_parser//lib/regexp_parser/parser.rb#99 @@ -2352,11 +2369,11 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#262 def assign_effective_number(exp); end - # Assigns referenced expressions to refering expressions, e.g. if there is + # Assigns referenced expressions to referring expressions, e.g. if there is # an instance of Backreference::Number, its #referenced_expression is set to # the instance of Group::Capture that it refers to via its number. # - # source://regexp_parser//lib/regexp_parser/parser.rb#580 + # source://regexp_parser//lib/regexp_parser/parser.rb#581 def assign_referenced_expressions; end # source://regexp_parser//lib/regexp_parser/parser.rb#227 @@ -2377,13 +2394,13 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#56 def captured_group_counts=(_arg0); end - # source://regexp_parser//lib/regexp_parser/parser.rb#569 + # source://regexp_parser//lib/regexp_parser/parser.rb#570 def close_completed_character_set_range; end # source://regexp_parser//lib/regexp_parser/parser.rb#210 def close_group; end - # source://regexp_parser//lib/regexp_parser/parser.rb#537 + # source://regexp_parser//lib/regexp_parser/parser.rb#538 def close_set; end # source://regexp_parser//lib/regexp_parser/parser.rb#269 @@ -2421,10 +2438,10 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#114 def group(token); end - # source://regexp_parser//lib/regexp_parser/parser.rb#508 + # source://regexp_parser//lib/regexp_parser/parser.rb#509 def increase_group_level(exp); end - # source://regexp_parser//lib/regexp_parser/parser.rb#548 + # source://regexp_parser//lib/regexp_parser/parser.rb#549 def intersection(token); end # source://regexp_parser//lib/regexp_parser/parser.rb#360 @@ -2436,7 +2453,7 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#368 def meta(token); end - # source://regexp_parser//lib/regexp_parser/parser.rb#533 + # source://regexp_parser//lib/regexp_parser/parser.rb#534 def negate_set; end # source://regexp_parser//lib/regexp_parser/parser.rb#299 @@ -2472,7 +2489,7 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#165 def open_group(token); end - # source://regexp_parser//lib/regexp_parser/parser.rb#526 + # source://regexp_parser//lib/regexp_parser/parser.rb#527 def open_set(token); end # source://regexp_parser//lib/regexp_parser/parser.rb#130 @@ -2499,10 +2516,10 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#397 def property(token); end - # source://regexp_parser//lib/regexp_parser/parser.rb#478 + # source://regexp_parser//lib/regexp_parser/parser.rb#479 def quantifier(token); end - # source://regexp_parser//lib/regexp_parser/parser.rb#541 + # source://regexp_parser//lib/regexp_parser/parser.rb#542 def range(token); end # Returns the value of attribute root. @@ -2520,7 +2537,7 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#379 def sequence_operation(klass, token); end - # source://regexp_parser//lib/regexp_parser/parser.rb#514 + # source://regexp_parser//lib/regexp_parser/parser.rb#515 def set(token); end # Returns the value of attribute switching_options. @@ -2538,7 +2555,7 @@ class Regexp::Parser # source://regexp_parser//lib/regexp_parser/parser.rb#198 def total_captured_group_count; end - # source://regexp_parser//lib/regexp_parser/parser.rb#552 + # source://regexp_parser//lib/regexp_parser/parser.rb#553 def type(token); end class << self @@ -2590,17 +2607,17 @@ Regexp::Parser::VERSION = T.let(T.unsafe(nil), String) class Regexp::Scanner # Emits an array with the details of the scanned pattern # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2388 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2406 def emit(type, token, text); end # only public for #||= to work on ruby <= 2.5 # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2413 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2431 def literal_run; end # only public for #||= to work on ruby <= 2.5 # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2413 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2431 def literal_run=(_arg0); end # @raise [PrematureEndError] @@ -2613,168 +2630,168 @@ class Regexp::Scanner # Appends one or more characters to the literal buffer, to be emitted later # by a call to emit_literal. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2450 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2468 def append_literal(data, ts, te); end # Returns the value of attribute block. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def block; end # Sets the attribute block # # @param value the value to set the attribute block to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def block=(_arg0); end # Returns the value of attribute char_pos. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def char_pos; end # Sets the attribute char_pos # # @param value the value to set the attribute char_pos to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def char_pos=(_arg0); end # Returns the value of attribute collect_tokens. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def collect_tokens; end # Sets the attribute collect_tokens # # @param value the value to set the attribute collect_tokens to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def collect_tokens=(_arg0); end # Returns the value of attribute conditional_stack. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def conditional_stack; end # Sets the attribute conditional_stack # # @param value the value to set the attribute conditional_stack to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def conditional_stack=(_arg0); end # Copy from ts to te from data as text # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2444 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2462 def copy(data, ts, te); end # Emits the literal run collected by calls to the append_literal method. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2455 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2473 def emit_literal; end - # source://regexp_parser//lib/regexp_parser/scanner.rb#2490 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2508 def emit_meta_control_sequence(data, ts, te, token); end - # source://regexp_parser//lib/regexp_parser/scanner.rb#2461 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2479 def emit_options(text); end # Returns the value of attribute free_spacing. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def free_spacing; end # Sets the attribute free_spacing # # @param value the value to set the attribute free_spacing to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def free_spacing=(_arg0); end # @return [Boolean] # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2423 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2441 def free_spacing?(input_object, options); end # Returns the value of attribute group_depth. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def group_depth; end # Sets the attribute group_depth # # @param value the value to set the attribute group_depth to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def group_depth=(_arg0); end # @return [Boolean] # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2453 def in_group?; end # @return [Boolean] # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2439 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2457 def in_set?; end # Returns the value of attribute prev_token. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def prev_token; end # Sets the attribute prev_token # # @param value the value to set the attribute prev_token to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def prev_token=(_arg0); end # Returns the value of attribute set_depth. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def set_depth; end # Sets the attribute set_depth # # @param value the value to set the attribute set_depth to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def set_depth=(_arg0); end # Returns the value of attribute spacing_stack. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def spacing_stack; end # Sets the attribute spacing_stack # # @param value the value to set the attribute spacing_stack to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def spacing_stack=(_arg0); end # Returns the value of attribute tokens. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def tokens; end # Sets the attribute tokens # # @param value the value to set the attribute tokens to. # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2417 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2435 def tokens=(_arg0); end class << self - # source://regexp_parser//lib/regexp_parser/scanner.rb#2374 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2392 def long_prop_map; end - # source://regexp_parser//lib/regexp_parser/scanner.rb#2378 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2396 def parse_prop_map(name); end - # source://regexp_parser//lib/regexp_parser/scanner.rb#2382 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2400 def posix_classes; end # Scans the given regular expression text, or Regexp object and collects the @@ -2789,7 +2806,7 @@ class Regexp::Scanner # lazy-load property maps when first needed # - # source://regexp_parser//lib/regexp_parser/scanner.rb#2370 + # source://regexp_parser//lib/regexp_parser/scanner.rb#2388 def short_prop_map; end end end @@ -3355,7 +3372,7 @@ Regexp::Syntax::Token::PosixClass::Type = T.let(T.unsafe(nil), Symbol) # alias for symmetry between token symbol and Token module name # -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#731 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#749 Regexp::Syntax::Token::Property = Regexp::Syntax::Token::UnicodeProperty # source://regexp_parser//lib/regexp_parser/syntax/token/quantifier.rb#3 @@ -3452,7 +3469,7 @@ Regexp::Syntax::Token::UnicodeProperty::Age_V3_1_0 = T.let(T.unsafe(nil), Array) # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#62 Regexp::Syntax::Token::UnicodeProperty::Age_V3_2_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#721 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#739 Regexp::Syntax::Token::UnicodeProperty::All = T.let(T.unsafe(nil), Array) # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#13 @@ -3503,7 +3520,7 @@ Regexp::Syntax::Token::UnicodeProperty::Derived_V2_4_0 = T.let(T.unsafe(nil), Ar # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#129 Regexp::Syntax::Token::UnicodeProperty::Derived_V2_5_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#706 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#724 Regexp::Syntax::Token::UnicodeProperty::Emoji = T.let(T.unsafe(nil), Array) # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#694 @@ -3512,7 +3529,13 @@ Regexp::Syntax::Token::UnicodeProperty::Emoji_V2_5_0 = T.let(T.unsafe(nil), Arra # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#702 Regexp::Syntax::Token::UnicodeProperty::Emoji_V2_6_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#724 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#722 +Regexp::Syntax::Token::UnicodeProperty::Enumerated = T.let(T.unsafe(nil), Array) + +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#706 +Regexp::Syntax::Token::UnicodeProperty::Enumerated_V2_4_0 = T.let(T.unsafe(nil), Array) + +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#742 Regexp::Syntax::Token::UnicodeProperty::NonType = T.let(T.unsafe(nil), Symbol) # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#11 @@ -3554,7 +3577,7 @@ Regexp::Syntax::Token::UnicodeProperty::Script_V3_1_0 = T.let(T.unsafe(nil), Arr # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#322 Regexp::Syntax::Token::UnicodeProperty::Script_V3_2_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#723 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#741 Regexp::Syntax::Token::UnicodeProperty::Type = T.let(T.unsafe(nil), Symbol) # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#692 @@ -3590,40 +3613,40 @@ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V3_1_0 = T.let(T.unsafe(nil # source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#670 Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V3_2_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#708 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#726 Regexp::Syntax::Token::UnicodeProperty::V1_9_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#709 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#727 Regexp::Syntax::Token::UnicodeProperty::V1_9_3 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#710 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#728 Regexp::Syntax::Token::UnicodeProperty::V2_0_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#711 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#729 Regexp::Syntax::Token::UnicodeProperty::V2_2_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#712 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#730 Regexp::Syntax::Token::UnicodeProperty::V2_3_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#713 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#731 Regexp::Syntax::Token::UnicodeProperty::V2_4_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#714 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#732 Regexp::Syntax::Token::UnicodeProperty::V2_5_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#715 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#733 Regexp::Syntax::Token::UnicodeProperty::V2_6_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#716 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#734 Regexp::Syntax::Token::UnicodeProperty::V2_6_2 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#717 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#735 Regexp::Syntax::Token::UnicodeProperty::V2_6_3 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#718 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#736 Regexp::Syntax::Token::UnicodeProperty::V3_1_0 = T.let(T.unsafe(nil), Array) -# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#719 +# source://regexp_parser//lib/regexp_parser/syntax/token/unicode_property.rb#737 Regexp::Syntax::Token::UnicodeProperty::V3_2_0 = T.let(T.unsafe(nil), Array) # source://regexp_parser//lib/regexp_parser/syntax/version_lookup.rb#12 diff --git a/sorbet/rbi/gems/reline@0.3.5.rbi b/sorbet/rbi/gems/reline@0.3.5.rbi deleted file mode 100644 index 83be1426d..000000000 --- a/sorbet/rbi/gems/reline@0.3.5.rbi +++ /dev/null @@ -1,2058 +0,0 @@ -# typed: false - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `reline` gem. -# Please instead update this file by running `bin/tapioca gem reline`. - -# source://reline//lib/reline/version.rb#1 -module Reline - extend ::Forwardable - extend ::SingleForwardable - - class << self - # source://reline//lib/reline.rb#564 - def core; end - - # source://reline//lib/reline.rb#560 - def encoding_system_needs; end - - # source://reline//lib/reline.rb#541 - def insert_text(*args, &block); end - - # source://reline//lib/reline.rb#584 - def line_editor; end - - # source://reline//lib/reline.rb#580 - def ungetc(c); end - end -end - -# source://reline//lib/reline/ansi.rb#6 -class Reline::ANSI - class << self - # source://reline//lib/reline/ansi.rb#339 - def clear_screen; end - - # source://reline//lib/reline/ansi.rb#251 - def cursor_pos; end - - # source://reline//lib/reline/ansi.rb#354 - def deprep(otio); end - - # @return [Boolean] - # - # source://reline//lib/reline/ansi.rb#212 - def empty_buffer?; end - - # source://reline//lib/reline/ansi.rb#27 - def encoding; end - - # source://reline//lib/reline/ansi.rb#330 - def erase_after_cursor; end - - # source://reline//lib/reline/ansi.rb#234 - def get_screen_size; end - - # source://reline//lib/reline/ansi.rb#200 - def getc; end - - # source://reline//lib/reline/ansi.rb#171 - def getc_with_bracketed_paste; end - - # source://reline//lib/reline/ansi.rb#306 - def hide_cursor; end - - # @return [Boolean] - # - # source://reline//lib/reline/ansi.rb#208 - def in_pasting?; end - - # source://reline//lib/reline/ansi.rb#153 - def inner_getc; end - - # source://reline//lib/reline/ansi.rb#139 - def input=(val); end - - # source://reline//lib/reline/ansi.rb#286 - def move_cursor_column(x); end - - # source://reline//lib/reline/ansi.rb#298 - def move_cursor_down(x); end - - # source://reline//lib/reline/ansi.rb#290 - def move_cursor_up(x); end - - # source://reline//lib/reline/ansi.rb#144 - def output=(val); end - - # source://reline//lib/reline/ansi.rb#349 - def prep; end - - # source://reline//lib/reline/ansi.rb#223 - def retrieve_keybuffer; end - - # source://reline//lib/reline/ansi.rb#334 - def scroll_down(x); end - - # source://reline//lib/reline/ansi.rb#35 - def set_default_key_bindings(config, allow_terminfo: T.unsafe(nil)); end - - # source://reline//lib/reline/ansi.rb#91 - def set_default_key_bindings_comprehensive_list(config); end - - # source://reline//lib/reline/ansi.rb#67 - def set_default_key_bindings_terminfo(config); end - - # source://reline//lib/reline/ansi.rb#244 - def set_screen_size(rows, columns); end - - # source://reline//lib/reline/ansi.rb#345 - def set_winch_handler(&handler); end - - # source://reline//lib/reline/ansi.rb#318 - def show_cursor; end - - # source://reline//lib/reline/ansi.rb#219 - def ungetc(c); end - - # @return [Boolean] - # - # source://reline//lib/reline/ansi.rb#31 - def win?; end - - # source://reline//lib/reline/ansi.rb#148 - def with_raw_input; end - end -end - -# source://reline//lib/reline/ansi.rb#7 -Reline::ANSI::CAPNAME_KEY_BINDINGS = T.let(T.unsafe(nil), Hash) - -# source://reline//lib/reline/ansi.rb#170 -Reline::ANSI::END_BRACKETED_PASTE = T.let(T.unsafe(nil), String) - -# source://reline//lib/reline/ansi.rb#169 -Reline::ANSI::START_BRACKETED_PASTE = T.let(T.unsafe(nil), String) - -# source://reline//lib/reline/config.rb#1 -class Reline::Config - # @return [Config] a new instance of Config - # - # source://reline//lib/reline/config.rb#50 - def initialize; end - - # source://reline//lib/reline/config.rb#172 - def add_default_key_binding(keystroke, target); end - - # source://reline//lib/reline/config.rb#168 - def add_default_key_binding_by_keymap(keymap, keystroke, target); end - - # source://reline//lib/reline/config.rb#160 - def add_oneshot_key_binding(keystroke, target); end - - # Returns the value of attribute autocompletion. - # - # source://reline//lib/reline/config.rb#48 - def autocompletion; end - - # Sets the attribute autocompletion - # - # @param value the value to set the attribute autocompletion to. - # - # source://reline//lib/reline/config.rb#48 - def autocompletion=(_arg0); end - - # source://reline//lib/reline/config.rb#342 - def bind_key(key, func_name); end - - # source://reline//lib/reline/config.rb#45 - def bind_tty_special_chars; end - - # source://reline//lib/reline/config.rb#45 - def bind_tty_special_chars=(_arg0); end - - # source://reline//lib/reline/config.rb#259 - def bind_variable(name, value); end - - # source://reline//lib/reline/config.rb#45 - def blink_matching_paren; end - - # source://reline//lib/reline/config.rb#45 - def blink_matching_paren=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def byte_oriented; end - - # source://reline//lib/reline/config.rb#45 - def byte_oriented=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def completion_ignore_case; end - - # source://reline//lib/reline/config.rb#45 - def completion_ignore_case=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def convert_meta; end - - # source://reline//lib/reline/config.rb#45 - def convert_meta=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def disable_completion; end - - # source://reline//lib/reline/config.rb#45 - def disable_completion=(_arg0); end - - # source://reline//lib/reline/config.rb#87 - def editing_mode; end - - # source://reline//lib/reline/config.rb#91 - def editing_mode=(val); end - - # @return [Boolean] - # - # source://reline//lib/reline/config.rb#95 - def editing_mode_is?(*val); end - - # source://reline//lib/reline/config.rb#45 - def emacs_mode_string; end - - # source://reline//lib/reline/config.rb#45 - def emacs_mode_string=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def enable_bracketed_paste; end - - # source://reline//lib/reline/config.rb#45 - def enable_bracketed_paste=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def enable_keypad; end - - # source://reline//lib/reline/config.rb#45 - def enable_keypad=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def expand_tilde; end - - # source://reline//lib/reline/config.rb#45 - def expand_tilde=(_arg0); end - - # source://reline//lib/reline/config.rb#229 - def handle_directive(directive, file, no); end - - # source://reline//lib/reline/config.rb#45 - def history_preserve_point; end - - # source://reline//lib/reline/config.rb#45 - def history_preserve_point=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def history_size; end - - # source://reline//lib/reline/config.rb#45 - def history_size=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def horizontal_scroll_mode; end - - # source://reline//lib/reline/config.rb#45 - def horizontal_scroll_mode=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def input_meta; end - - # source://reline//lib/reline/config.rb#45 - def input_meta=(_arg0); end - - # source://reline//lib/reline/config.rb#103 - def inputrc_path; end - - # source://reline//lib/reline/config.rb#45 - def isearch_terminators; end - - # source://reline//lib/reline/config.rb#45 - def isearch_terminators=(_arg0); end - - # source://reline//lib/reline/config.rb#152 - def key_bindings; end - - # source://reline//lib/reline/config.rb#356 - def key_notation_to_code(notation); end - - # source://reline//lib/reline/config.rb#99 - def keymap; end - - # source://reline//lib/reline/config.rb#45 - def keyseq_timeout; end - - # source://reline//lib/reline/config.rb#45 - def keyseq_timeout=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def mark_directories; end - - # source://reline//lib/reline/config.rb#45 - def mark_directories=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def mark_modified_lines; end - - # source://reline//lib/reline/config.rb#45 - def mark_modified_lines=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def mark_symlinked_directories; end - - # source://reline//lib/reline/config.rb#45 - def mark_symlinked_directories=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def match_hidden_files; end - - # source://reline//lib/reline/config.rb#45 - def match_hidden_files=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def meta_flag; end - - # source://reline//lib/reline/config.rb#45 - def meta_flag=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def output_meta; end - - # source://reline//lib/reline/config.rb#45 - def output_meta=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def page_completions; end - - # source://reline//lib/reline/config.rb#45 - def page_completions=(_arg0); end - - # source://reline//lib/reline/config.rb#390 - def parse_keyseq(str); end - - # source://reline//lib/reline/config.rb#45 - def prefer_visible_bell; end - - # source://reline//lib/reline/config.rb#45 - def prefer_visible_bell=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def print_completions_horizontally; end - - # source://reline//lib/reline/config.rb#45 - def print_completions_horizontally=(_arg0); end - - # source://reline//lib/reline/config.rb#133 - def read(file = T.unsafe(nil)); end - - # source://reline//lib/reline/config.rb#182 - def read_lines(lines, file = T.unsafe(nil)); end - - # source://reline//lib/reline/config.rb#76 - def reset; end - - # source://reline//lib/reline/config.rb#176 - def reset_default_key_bindings; end - - # source://reline//lib/reline/config.rb#164 - def reset_oneshot_key_bindings; end - - # source://reline//lib/reline/config.rb#337 - def retrieve_string(str); end - - # source://reline//lib/reline/config.rb#45 - def show_all_if_ambiguous; end - - # source://reline//lib/reline/config.rb#45 - def show_all_if_ambiguous=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def show_all_if_unmodified; end - - # source://reline//lib/reline/config.rb#45 - def show_all_if_unmodified=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def show_mode_in_prompt; end - - # source://reline//lib/reline/config.rb#45 - def show_mode_in_prompt=(_arg0); end - - # Returns the value of attribute test_mode. - # - # source://reline//lib/reline/config.rb#2 - def test_mode; end - - # source://reline//lib/reline/config.rb#45 - def vi_cmd_mode_string; end - - # source://reline//lib/reline/config.rb#45 - def vi_cmd_mode_string=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def vi_ins_mode_string; end - - # source://reline//lib/reline/config.rb#45 - def vi_ins_mode_string=(_arg0); end - - # source://reline//lib/reline/config.rb#45 - def visible_stats; end - - # source://reline//lib/reline/config.rb#45 - def visible_stats=(_arg0); end - - private - - # source://reline//lib/reline/config.rb#129 - def default_inputrc_path; end - - # @return [Boolean] - # - # source://reline//lib/reline/config.rb#398 - def seven_bit_encoding?(encoding); end -end - -# source://reline//lib/reline/config.rb#6 -class Reline::Config::InvalidInputrc < ::RuntimeError - # Returns the value of attribute file. - # - # source://reline//lib/reline/config.rb#7 - def file; end - - # Sets the attribute file - # - # @param value the value to set the attribute file to. - # - # source://reline//lib/reline/config.rb#7 - def file=(_arg0); end - - # Returns the value of attribute lineno. - # - # source://reline//lib/reline/config.rb#7 - def lineno; end - - # Sets the attribute lineno - # - # @param value the value to set the attribute lineno to. - # - # source://reline//lib/reline/config.rb#7 - def lineno=(_arg0); end -end - -# source://reline//lib/reline/config.rb#4 -Reline::Config::KEYSEQ_PATTERN = T.let(T.unsafe(nil), Regexp) - -# source://reline//lib/reline/config.rb#10 -Reline::Config::VARIABLE_NAMES = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline/config.rb#43 -Reline::Config::VARIABLE_NAME_SYMBOLS = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline.rb#50 -class Reline::Core - extend ::Forwardable - - # @return [Core] a new instance of Core - # @yield [_self] - # @yieldparam _self [Reline::Core] the object that the method was called on - # - # source://reline//lib/reline.rb#78 - def initialize; end - - # @raise [ArgumentError] - # - # source://reline//lib/reline.rb#168 - def add_dialog_proc(name_sym, p, context = T.unsafe(nil)); end - - # source://reline//lib/reline.rb#487 - def ambiguous_width; end - - # source://reline//lib/reline.rb#65 - def auto_indent_proc; end - - # @raise [ArgumentError] - # - # source://reline//lib/reline.rb#153 - def auto_indent_proc=(p); end - - # source://reline//lib/reline.rb#65 - def basic_quote_characters; end - - # source://reline//lib/reline.rb#110 - def basic_quote_characters=(v); end - - # source://reline//lib/reline.rb#65 - def basic_word_break_characters; end - - # source://reline//lib/reline.rb#102 - def basic_word_break_characters=(v); end - - # source://reline//lib/reline.rb#65 - def completer_quote_characters; end - - # source://reline//lib/reline.rb#114 - def completer_quote_characters=(v); end - - # source://reline//lib/reline.rb#65 - def completer_word_break_characters; end - - # source://reline//lib/reline.rb#106 - def completer_word_break_characters=(v); end - - # source://reline//lib/reline.rb#65 - def completion_append_character; end - - # source://reline//lib/reline.rb#90 - def completion_append_character=(val); end - - # source://reline//lib/reline.rb#130 - def completion_case_fold; end - - # source://reline//lib/reline.rb#126 - def completion_case_fold=(v); end - - # source://reline//lib/reline.rb#65 - def completion_proc; end - - # @raise [ArgumentError] - # - # source://reline//lib/reline.rb#138 - def completion_proc=(p); end - - # source://reline//lib/reline.rb#134 - def completion_quote_character; end - - # Returns the value of attribute config. - # - # source://reline//lib/reline.rb#67 - def config; end - - # Sets the attribute config - # - # @param value the value to set the attribute config to. - # - # source://reline//lib/reline.rb#67 - def config=(_arg0); end - - # source://reline//lib/reline.rb#178 - def dialog_proc(name_sym); end - - # source://reline//lib/reline.rb#65 - def dig_perfect_match_proc; end - - # @raise [ArgumentError] - # - # source://reline//lib/reline.rb#162 - def dig_perfect_match_proc=(p); end - - # source://reline//lib/reline.rb#206 - def emacs_editing_mode; end - - # @return [Boolean] - # - # source://reline//lib/reline.rb#215 - def emacs_editing_mode?; end - - # source://reline//lib/reline.rb#86 - def encoding; end - - # source://reline//lib/reline.rb#65 - def filename_quote_characters; end - - # source://reline//lib/reline.rb#118 - def filename_quote_characters=(v); end - - # source://reline//lib/reline.rb#219 - def get_screen_size; end - - # @raise [TypeError] - # - # source://reline//lib/reline.rb#182 - def input=(val); end - - # Returns the value of attribute key_stroke. - # - # source://reline//lib/reline.rb#68 - def key_stroke; end - - # Sets the attribute key_stroke - # - # @param value the value to set the attribute key_stroke to. - # - # source://reline//lib/reline.rb#68 - def key_stroke=(_arg0); end - - # Returns the value of attribute last_incremental_search. - # - # source://reline//lib/reline.rb#70 - def last_incremental_search; end - - # Sets the attribute last_incremental_search - # - # @param value the value to set the attribute last_incremental_search to. - # - # source://reline//lib/reline.rb#70 - def last_incremental_search=(_arg0); end - - # Returns the value of attribute line_editor. - # - # source://reline//lib/reline.rb#69 - def line_editor; end - - # Sets the attribute line_editor - # - # @param value the value to set the attribute line_editor to. - # - # source://reline//lib/reline.rb#69 - def line_editor=(_arg0); end - - # Returns the value of attribute output. - # - # source://reline//lib/reline.rb#71 - def output; end - - # @raise [TypeError] - # - # source://reline//lib/reline.rb#193 - def output=(val); end - - # source://reline//lib/reline.rb#65 - def output_modifier_proc; end - - # @raise [ArgumentError] - # - # source://reline//lib/reline.rb#143 - def output_modifier_proc=(p); end - - # source://reline//lib/reline.rb#65 - def pre_input_hook; end - - # source://reline//lib/reline.rb#158 - def pre_input_hook=(p); end - - # source://reline//lib/reline.rb#65 - def prompt_proc; end - - # @raise [ArgumentError] - # - # source://reline//lib/reline.rb#148 - def prompt_proc=(p); end - - # source://reline//lib/reline.rb#290 - def readline(prompt = T.unsafe(nil), add_hist = T.unsafe(nil)); end - - # source://reline//lib/reline.rb#272 - def readmultiline(prompt = T.unsafe(nil), add_hist = T.unsafe(nil), &confirm_multiline_termination); end - - # source://reline//lib/reline.rb#65 - def special_prefixes; end - - # source://reline//lib/reline.rb#122 - def special_prefixes=(v); end - - # source://reline//lib/reline.rb#201 - def vi_editing_mode; end - - # @return [Boolean] - # - # source://reline//lib/reline.rb#211 - def vi_editing_mode?; end - - private - - # source://reline//lib/reline.rb#303 - def inner_readline(prompt, add_hist, multiline, &confirm_multiline_termination); end - - # source://reline//lib/reline.rb#492 - def may_req_ambiguous_char_width; end - - # source://reline//lib/reline.rb#434 - def read_2nd_character_of_key_sequence(keyseq_timeout, buffer, c, block); end - - # source://reline//lib/reline.rb#466 - def read_escaped_key(keyseq_timeout, c, block); end - - # GNU Readline waits for "keyseq-timeout" milliseconds to see if the ESC - # is followed by a character, and times out and treats it as a standalone - # ESC if the second character does not arrive. If the second character - # comes before timed out, it is treated as a modifier key with the - # meta-property of meta-key, so that it can be distinguished from - # multibyte characters with the 8th bit turned on. - # - # GNU Readline will wait for the 2nd character with "keyseq-timeout" - # milli-seconds but wait forever after 3rd characters. - # - # source://reline//lib/reline.rb#395 - def read_io(keyseq_timeout, &block); end -end - -# source://reline//lib/reline.rb#51 -Reline::Core::ATTR_READER_NAMES = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline.rb#270 -Reline::DEFAULT_DIALOG_CONTEXT = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline.rb#223 -Reline::DEFAULT_DIALOG_PROC_AUTOCOMPLETE = T.let(T.unsafe(nil), Proc) - -# NOTE: For making compatible with the rb-readline gem -# -# source://reline//lib/reline.rb#15 -Reline::FILENAME_COMPLETION_PROC = T.let(T.unsafe(nil), T.untyped) - -# source://reline//lib/reline/general_io.rb#4 -class Reline::GeneralIO - class << self - # source://reline//lib/reline/general_io.rb#85 - def clear_screen; end - - # source://reline//lib/reline/general_io.rb#60 - def cursor_pos; end - - # source://reline//lib/reline/general_io.rb#111 - def deprep(otio); end - - # source://reline//lib/reline/general_io.rb#10 - def encoding; end - - # source://reline//lib/reline/general_io.rb#79 - def erase_after_cursor; end - - # source://reline//lib/reline/general_io.rb#104 - def finish_pasting; end - - # source://reline//lib/reline/general_io.rb#56 - def get_screen_size; end - - # source://reline//lib/reline/general_io.rb#38 - def getc; end - - # source://reline//lib/reline/general_io.rb#64 - def hide_cursor; end - - # @return [Boolean] - # - # source://reline//lib/reline/general_io.rb#96 - def in_pasting?; end - - # source://reline//lib/reline/general_io.rb#30 - def input=(val); end - - # source://reline//lib/reline/general_io.rb#70 - def move_cursor_column(val); end - - # source://reline//lib/reline/general_io.rb#76 - def move_cursor_down(val); end - - # source://reline//lib/reline/general_io.rb#73 - def move_cursor_up(val); end - - # source://reline//lib/reline/general_io.rb#108 - def prep; end - - # source://reline//lib/reline/general_io.rb#5 - def reset(encoding: T.unsafe(nil)); end - - # source://reline//lib/reline/general_io.rb#82 - def scroll_down(val); end - - # source://reline//lib/reline/general_io.rb#24 - def set_default_key_bindings(_); end - - # source://reline//lib/reline/general_io.rb#88 - def set_screen_size(rows, columns); end - - # source://reline//lib/reline/general_io.rb#91 - def set_winch_handler(&handler); end - - # source://reline//lib/reline/general_io.rb#67 - def show_cursor; end - - # source://reline//lib/reline/general_io.rb#100 - def start_pasting; end - - # source://reline//lib/reline/general_io.rb#52 - def ungetc(c); end - - # @return [Boolean] - # - # source://reline//lib/reline/general_io.rb#20 - def win?; end - - # source://reline//lib/reline/general_io.rb#34 - def with_raw_input; end - end -end - -# source://reline//lib/reline.rb#607 -Reline::HISTORY = T.let(T.unsafe(nil), Reline::History) - -# source://reline//lib/reline/history.rb#1 -class Reline::History < ::Array - # @return [History] a new instance of History - # - # source://reline//lib/reline/history.rb#2 - def initialize(config); end - - # source://reline//lib/reline/history.rb#52 - def <<(val); end - - # source://reline//lib/reline/history.rb#15 - def [](index); end - - # source://reline//lib/reline/history.rb#20 - def []=(index, val); end - - # source://reline//lib/reline/history.rb#25 - def concat(*val); end - - # source://reline//lib/reline/history.rb#10 - def delete_at(index); end - - # source://reline//lib/reline/history.rb#31 - def push(*val); end - - # source://reline//lib/reline/history.rb#6 - def to_s; end - - private - - # @raise [IndexError] - # - # source://reline//lib/reline/history.rb#62 - def check_index(index); end -end - -# source://reline//lib/reline.rb#600 -Reline::IOGate = Reline::ANSI - -# source://reline//lib/reline.rb#20 -Reline::Key = Struct - -# source://reline//lib/reline/key_actor/base.rb#1 -class Reline::KeyActor::Base - # @return [Base] a new instance of Base - # - # source://reline//lib/reline/key_actor/base.rb#8 - def initialize; end - - # source://reline//lib/reline/key_actor/base.rb#12 - def default_key_bindings; end - - # source://reline//lib/reline/key_actor/base.rb#4 - def get_method(key); end - - # source://reline//lib/reline/key_actor/base.rb#16 - def reset_default_key_bindings; end -end - -# source://reline//lib/reline/key_actor/base.rb#2 -Reline::KeyActor::Base::MAPPING = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline/key_actor/emacs.rb#2 -Reline::KeyActor::Emacs::MAPPING = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline/key_actor/vi_command.rb#2 -Reline::KeyActor::ViCommand::MAPPING = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline/key_actor/vi_insert.rb#2 -Reline::KeyActor::ViInsert::MAPPING = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline/key_stroke.rb#1 -class Reline::KeyStroke - # @return [KeyStroke] a new instance of KeyStroke - # - # source://reline//lib/reline/key_stroke.rb#2 - def initialize(config); end - - # source://reline//lib/reline/key_stroke.rb#6 - def compress_meta_key(ary); end - - # @return [Boolean] - # - # source://reline//lib/reline/key_stroke.rb#42 - def equal?(me, other); end - - # source://reline//lib/reline/key_stroke.rb#83 - def expand(input); end - - # source://reline//lib/reline/key_stroke.rb#67 - def match_status(input); end - - # @return [Boolean] - # - # source://reline//lib/reline/key_stroke.rb#18 - def start_with?(me, other); end - - private - - # source://reline//lib/reline/key_stroke.rb#102 - def key_mapping; end -end - -# source://reline//lib/reline/kill_ring.rb#1 -class Reline::KillRing - include ::Enumerable - - # @return [KillRing] a new instance of KillRing - # - # source://reline//lib/reline/kill_ring.rb#61 - def initialize(max = T.unsafe(nil)); end - - # source://reline//lib/reline/kill_ring.rb#68 - def append(string, before_p = T.unsafe(nil)); end - - # source://reline//lib/reline/kill_ring.rb#116 - def each; end - - # source://reline//lib/reline/kill_ring.rb#83 - def process; end - - # source://reline//lib/reline/kill_ring.rb#96 - def yank; end - - # source://reline//lib/reline/kill_ring.rb#106 - def yank_pop; end -end - -# source://reline//lib/reline/kill_ring.rb#21 -class Reline::KillRing::RingBuffer - # @return [RingBuffer] a new instance of RingBuffer - # - # source://reline//lib/reline/kill_ring.rb#25 - def initialize(max = T.unsafe(nil)); end - - # source://reline//lib/reline/kill_ring.rb#31 - def <<(point); end - - # @return [Boolean] - # - # source://reline//lib/reline/kill_ring.rb#56 - def empty?; end - - # Returns the value of attribute head. - # - # source://reline//lib/reline/kill_ring.rb#23 - def head; end - - # Returns the value of attribute size. - # - # source://reline//lib/reline/kill_ring.rb#22 - def size; end -end - -# source://reline//lib/reline/kill_ring.rb#11 -class Reline::KillRing::RingPoint < ::Struct - # @return [RingPoint] a new instance of RingPoint - # - # source://reline//lib/reline/kill_ring.rb#12 - def initialize(str); end - - # source://reline//lib/reline/kill_ring.rb#16 - def ==(other); end -end - -# source://reline//lib/reline/kill_ring.rb#6 -Reline::KillRing::State::CONTINUED = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/kill_ring.rb#5 -Reline::KillRing::State::FRESH = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/kill_ring.rb#7 -Reline::KillRing::State::PROCESSED = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/kill_ring.rb#8 -Reline::KillRing::State::YANK = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/line_editor.rb#6 -class Reline::LineEditor - # @return [LineEditor] a new instance of LineEditor - # - # source://reline//lib/reline/line_editor.rb#57 - def initialize(config, encoding); end - - # source://reline//lib/reline/line_editor.rb#635 - def add_dialog_proc(name, p, context = T.unsafe(nil)); end - - # Returns the value of attribute auto_indent_proc. - # - # source://reline//lib/reline/line_editor.rb#16 - def auto_indent_proc; end - - # Sets the attribute auto_indent_proc - # - # @param value the value to set the attribute auto_indent_proc to. - # - # source://reline//lib/reline/line_editor.rb#16 - def auto_indent_proc=(_arg0); end - - # Returns the value of attribute byte_pointer. - # - # source://reline//lib/reline/line_editor.rb#10 - def byte_pointer; end - - # source://reline//lib/reline/line_editor.rb#1836 - def byte_pointer=(val); end - - # source://reline//lib/reline/line_editor.rb#1607 - def call_completion_proc; end - - # source://reline//lib/reline/line_editor.rb#1615 - def call_completion_proc_with_checking_args(pre, target, post); end - - # Returns the value of attribute completion_append_character. - # - # source://reline//lib/reline/line_editor.rb#13 - def completion_append_character; end - - # Sets the attribute completion_append_character - # - # @param value the value to set the attribute completion_append_character to. - # - # source://reline//lib/reline/line_editor.rb#13 - def completion_append_character=(_arg0); end - - # Returns the value of attribute completion_proc. - # - # source://reline//lib/reline/line_editor.rb#12 - def completion_proc; end - - # Sets the attribute completion_proc - # - # @param value the value to set the attribute completion_proc to. - # - # source://reline//lib/reline/line_editor.rb#12 - def completion_proc=(_arg0); end - - # source://reline//lib/reline/line_editor.rb#1754 - def confirm_multiline_termination; end - - # Returns the value of attribute confirm_multiline_termination_proc. - # - # source://reline//lib/reline/line_editor.rb#11 - def confirm_multiline_termination_proc; end - - # Sets the attribute confirm_multiline_termination_proc - # - # @param value the value to set the attribute confirm_multiline_termination_proc to. - # - # source://reline//lib/reline/line_editor.rb#11 - def confirm_multiline_termination_proc=(_arg0); end - - # source://reline//lib/reline/line_editor.rb#1776 - def delete_text(start = T.unsafe(nil), length = T.unsafe(nil)); end - - # Returns the value of attribute dig_perfect_match_proc. - # - # source://reline//lib/reline/line_editor.rb#18 - def dig_perfect_match_proc; end - - # Sets the attribute dig_perfect_match_proc - # - # @param value the value to set the attribute dig_perfect_match_proc to. - # - # source://reline//lib/reline/line_editor.rb#18 - def dig_perfect_match_proc=(_arg0); end - - # source://reline//lib/reline/line_editor.rb#1225 - def editing_mode; end - - # @return [Boolean] - # - # source://reline//lib/reline/line_editor.rb#248 - def eof?; end - - # source://reline//lib/reline/line_editor.rb#244 - def finalize; end - - # source://reline//lib/reline/line_editor.rb#1862 - def finish; end - - # @return [Boolean] - # - # source://reline//lib/reline/line_editor.rb#1858 - def finished?; end - - # source://reline//lib/reline/line_editor.rb#1532 - def input_key(key); end - - # source://reline//lib/reline/line_editor.rb#1764 - def insert_text(text); end - - # source://reline//lib/reline/line_editor.rb#931 - def just_move_cursor; end - - # TODO: undo - # TODO: Use "private alias_method" idiom after drop Ruby 2.5. - # - # source://reline//lib/reline/line_editor.rb#9 - def line; end - - # source://reline//lib/reline/line_editor.rb#314 - def multiline_off; end - - # source://reline//lib/reline/line_editor.rb#310 - def multiline_on; end - - # Sets the attribute output - # - # @param value the value to set the attribute output to. - # - # source://reline//lib/reline/line_editor.rb#19 - def output=(_arg0); end - - # Returns the value of attribute output_modifier_proc. - # - # source://reline//lib/reline/line_editor.rb#14 - def output_modifier_proc; end - - # Sets the attribute output_modifier_proc - # - # @param value the value to set the attribute output_modifier_proc to. - # - # source://reline//lib/reline/line_editor.rb#14 - def output_modifier_proc=(_arg0); end - - # Returns the value of attribute pre_input_hook. - # - # source://reline//lib/reline/line_editor.rb#17 - def pre_input_hook; end - - # Sets the attribute pre_input_hook - # - # @param value the value to set the attribute pre_input_hook to. - # - # source://reline//lib/reline/line_editor.rb#17 - def pre_input_hook=(_arg0); end - - # Returns the value of attribute prompt_proc. - # - # source://reline//lib/reline/line_editor.rb#15 - def prompt_proc; end - - # Sets the attribute prompt_proc - # - # @param value the value to set the attribute prompt_proc to. - # - # source://reline//lib/reline/line_editor.rb#15 - def prompt_proc=(_arg0); end - - # source://reline//lib/reline/line_editor.rb#422 - def rerender; end - - # source://reline//lib/reline/line_editor.rb#416 - def rerender_all; end - - # source://reline//lib/reline/line_editor.rb#150 - def reset(prompt = T.unsafe(nil), encoding:); end - - # source://reline//lib/reline/line_editor.rb#292 - def reset_line; end - - # source://reline//lib/reline/line_editor.rb#252 - def reset_variables(prompt = T.unsafe(nil), encoding:); end - - # source://reline//lib/reline/line_editor.rb#181 - def resize; end - - # source://reline//lib/reline/line_editor.rb#1676 - def retrieve_completion_block(set_completion_quote_character = T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#63 - def set_pasting_state(in_pasting); end - - # source://reline//lib/reline/line_editor.rb#221 - def set_signal_handlers; end - - # @return [Boolean] - # - # source://reline//lib/reline/line_editor.rb#67 - def simplified_rendering?; end - - # source://reline//lib/reline/line_editor.rb#1850 - def whole_buffer; end - - # source://reline//lib/reline/line_editor.rb#1843 - def whole_lines; end - - # source://reline//lib/reline/line_editor.rb#1417 - def wrap_method_call(method_symbol, method_obj, key, with_operator = T.unsafe(nil)); end - - private - - # @return [Boolean] - # - # source://reline//lib/reline/line_editor.rb#1407 - def argumentable?(method_obj); end - - # source://reline//lib/reline/line_editor.rb#2027 - def backward_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2517 - def backward_delete_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2676 - def backward_word(key); end - - # source://reline//lib/reline/line_editor.rb#2051 - def beginning_of_line(key); end - - # source://reline//lib/reline/line_editor.rb#1874 - def byteinsert(str, byte_pointer, other); end - - # source://reline//lib/reline/line_editor.rb#1868 - def byteslice!(str, byte_pointer, size); end - - # source://reline//lib/reline/line_editor.rb#318 - def calculate_height_by_lines(lines, prompt); end - - # source://reline//lib/reline/line_editor.rb#336 - def calculate_height_by_width(width); end - - # source://reline//lib/reline/line_editor.rb#374 - def calculate_nearest_cursor(line_to_calc = T.unsafe(nil), cursor = T.unsafe(nil), started_from = T.unsafe(nil), byte_pointer = T.unsafe(nil), update = T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#874 - def calculate_scroll_partial_screen(highest_in_all, cursor_y); end - - # source://reline//lib/reline/line_editor.rb#1881 - def calculate_width(str, allow_escape_code = T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2740 - def capitalize_word(key); end - - # source://reline//lib/reline/line_editor.rb#77 - def check_mode_string; end - - # source://reline//lib/reline/line_editor.rb#97 - def check_multiline_prompt(buffer, force_recalc: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#858 - def clear_dialog(cursor_column); end - - # source://reline//lib/reline/line_editor.rb#867 - def clear_dialog_with_trap_key(cursor_column); end - - # source://reline//lib/reline/line_editor.rb#2662 - def clear_screen(key); end - - # source://reline//lib/reline/line_editor.rb#1204 - def clear_screen_buffer(prompt, prompt_list, prompt_width); end - - # source://reline//lib/reline/line_editor.rb#1279 - def complete(list, just_show_list = T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#1233 - def complete_internal_proc(list, is_menu); end - - # source://reline//lib/reline/line_editor.rb#2796 - def copy_for_vi(text); end - - # source://reline//lib/reline/line_editor.rb#2594 - def delete_char(key); end - - # source://reline//lib/reline/line_editor.rb#2621 - def delete_char_or_list(key); end - - # source://reline//lib/reline/line_editor.rb#667 - def dialog_range(dialog, dialog_y); end - - # source://reline//lib/reline/line_editor.rb#2752 - def downcase_word(key); end - - # source://reline//lib/reline/line_editor.rb#3095 - def ed_argument_digit(key); end - - # source://reline//lib/reline/line_editor.rb#2662 - def ed_clear_screen(key); end - - # source://reline//lib/reline/line_editor.rb#3007 - def ed_delete_next_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2925 - def ed_delete_prev_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2694 - def ed_delete_prev_word(key); end - - # Editline:: +ed-insert+ (vi input: almost all; emacs: printable characters) - # In insert mode, insert the input character left of the cursor - # position. In replace mode, overwrite the character at the - # cursor and move the cursor to the right by one character - # position. Accept an argument to do this repeatedly. It is an - # error if the input character is the NUL character (+Ctrl-@+). - # Failure to enlarge the edit buffer also results in an error. - # Editline:: +ed-digit+ (emacs: 0 to 9) If in argument input mode, append - # the input digit to the argument being read. Otherwise, call - # +ed-insert+. It is an error if the input character is not a - # digit or if the existing argument is already greater than a - # million. - # GNU Readline:: +self-insert+ (a, b, A, 1, !, …) Insert yourself. - # - # source://reline//lib/reline/line_editor.rb#1938 - def ed_digit(key); end - - # Editline:: +ed-insert+ (vi input: almost all; emacs: printable characters) - # In insert mode, insert the input character left of the cursor - # position. In replace mode, overwrite the character at the - # cursor and move the cursor to the right by one character - # position. Accept an argument to do this repeatedly. It is an - # error if the input character is the NUL character (+Ctrl-@+). - # Failure to enlarge the edit buffer also results in an error. - # Editline:: +ed-digit+ (emacs: 0 to 9) If in argument input mode, append - # the input digit to the argument being read. Otherwise, call - # +ed-insert+. It is an error if the input character is not a - # digit or if the existing argument is already greater than a - # million. - # GNU Readline:: +self-insert+ (a, b, A, 1, !, …) Insert yourself. - # - # source://reline//lib/reline/line_editor.rb#1938 - def ed_insert(key); end - - # Editline:: +ed-kill-line+ (vi command: +D+, +Ctrl-K+; emacs: +Ctrl-K+, - # +Ctrl-U+) + Kill from the cursor to the end of the line. - # GNU Readline:: +kill-line+ (+C-k+) Kill the text from point to the end of - # the line. With a negative numeric argument, kill backward - # from the cursor to the beginning of the current line. - # - # source://reline//lib/reline/line_editor.rb#2545 - def ed_kill_line(key); end - - # source://reline//lib/reline/line_editor.rb#2051 - def ed_move_to_beg(key); end - - # source://reline//lib/reline/line_editor.rb#2056 - def ed_move_to_end(key); end - - # source://reline//lib/reline/line_editor.rb#2484 - def ed_newline(key); end - - # source://reline//lib/reline/line_editor.rb#2007 - def ed_next_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2436 - def ed_next_history(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2027 - def ed_prev_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2385 - def ed_prev_history(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2676 - def ed_prev_word(key); end - - # source://reline//lib/reline/line_editor.rb#1991 - def ed_quoted_insert(str, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2333 - def ed_search_next_history(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2286 - def ed_search_prev_history(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2705 - def ed_transpose_chars(key); end - - # source://reline//lib/reline/line_editor.rb#2725 - def ed_transpose_words(key); end - - # do nothing - # - # source://reline//lib/reline/line_editor.rb#1908 - def ed_unassigned(key); end - - # source://reline//lib/reline/line_editor.rb#2740 - def em_capitol_case(key); end - - # source://reline//lib/reline/line_editor.rb#2594 - def em_delete(key); end - - # source://reline//lib/reline/line_editor.rb#2685 - def em_delete_next_word(key); end - - # source://reline//lib/reline/line_editor.rb#2621 - def em_delete_or_list(key); end - - # source://reline//lib/reline/line_editor.rb#2517 - def em_delete_prev_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3279 - def em_exchange_mark(key); end - - # Editline:: +em-kill-line+ (not bound) Delete the entire contents of the - # edit buffer and save it to the cut buffer. +vi-kill-line-prev+ - # GNU Readline:: +kill-whole-line+ (not bound) Kill all characters on the - # current line, no matter where point is. - # - # source://reline//lib/reline/line_editor.rb#2583 - def em_kill_line(key); end - - # source://reline//lib/reline/line_editor.rb#2784 - def em_kill_region(key); end - - # source://reline//lib/reline/line_editor.rb#2752 - def em_lower_case(key); end - - # source://reline//lib/reline/line_editor.rb#2667 - def em_next_word(key); end - - # source://reline//lib/reline/line_editor.rb#3274 - def em_set_mark(key); end - - # source://reline//lib/reline/line_editor.rb#2768 - def em_upper_case(key); end - - # source://reline//lib/reline/line_editor.rb#2633 - def em_yank(key); end - - # source://reline//lib/reline/line_editor.rb#2645 - def em_yank_pop(key); end - - # source://reline//lib/reline/line_editor.rb#2056 - def end_of_line(key); end - - # source://reline//lib/reline/line_editor.rb#3279 - def exchange_point_and_mark(key); end - - # source://reline//lib/reline/line_editor.rb#2007 - def forward_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2281 - def forward_search_history(key); end - - # source://reline//lib/reline/line_editor.rb#2667 - def forward_word(key); end - - # source://reline//lib/reline/line_editor.rb#2071 - def generate_searcher; end - - # source://reline//lib/reline/line_editor.rb#2286 - def history_search_backward(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2333 - def history_search_forward(key, arg: T.unsafe(nil)); end - - # @return [Boolean] - # - # source://reline//lib/reline/line_editor.rb#1411 - def inclusive?(method_obj); end - - # source://reline//lib/reline/line_editor.rb#2189 - def incremental_search_history(key); end - - # source://reline//lib/reline/line_editor.rb#328 - def insert_new_line(cursor_line, next_line); end - - # source://reline//lib/reline/line_editor.rb#1885 - def key_delete(key); end - - # source://reline//lib/reline/line_editor.rb#1893 - def key_newline(key); end - - # Editline:: +ed-kill-line+ (vi command: +D+, +Ctrl-K+; emacs: +Ctrl-K+, - # +Ctrl-U+) + Kill from the cursor to the end of the line. - # GNU Readline:: +kill-line+ (+C-k+) Kill the text from point to the end of - # the line. With a negative numeric argument, kill backward - # from the cursor to the beginning of the current line. - # - # source://reline//lib/reline/line_editor.rb#2545 - def kill_line(key); end - - # Editline:: +em-kill-line+ (not bound) Delete the entire contents of the - # edit buffer and save it to the cut buffer. +vi-kill-line-prev+ - # GNU Readline:: +kill-whole-line+ (not bound) Kill all characters on the - # current line, no matter where point is. - # - # source://reline//lib/reline/line_editor.rb#2583 - def kill_whole_line(key); end - - # source://reline//lib/reline/line_editor.rb#1229 - def menu(target, list); end - - # source://reline//lib/reline/line_editor.rb#1181 - def modify_lines(before, force_recalc: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#1323 - def move_completed_list(list, direction); end - - # source://reline//lib/reline/line_editor.rb#364 - def move_cursor_down(val); end - - # source://reline//lib/reline/line_editor.rb#355 - def move_cursor_up(val); end - - # source://reline//lib/reline/line_editor.rb#2436 - def next_history(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#1494 - def normal_char(key); end - - # source://reline//lib/reline/line_editor.rb#654 - def padding_space_with_escape_sequences(str, width); end - - # source://reline//lib/reline/line_editor.rb#2385 - def previous_history(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#1637 - def process_auto_indent; end - - # source://reline//lib/reline/line_editor.rb#1910 - def process_insert(force: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#1437 - def process_key(key, method_symbol); end - - # source://reline//lib/reline/line_editor.rb#1991 - def quoted_insert(str, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#661 - def range_subtract(base_ranges, subtract_ranges); end - - # source://reline//lib/reline/line_editor.rb#645 - def render_dialog(cursor_column); end - - # source://reline//lib/reline/line_editor.rb#673 - def render_dialog_changes(changes, cursor_column); end - - # source://reline//lib/reline/line_editor.rb#1084 - def render_partial(prompt, prompt_width, line_to_render, this_started_from, with_control: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#1058 - def render_whole_lines(lines, prompt, prompt_width); end - - # source://reline//lib/reline/line_editor.rb#907 - def rerender_added_newline(prompt, prompt_width, prompt_list); end - - # source://reline//lib/reline/line_editor.rb#1003 - def rerender_all_lines; end - - # source://reline//lib/reline/line_editor.rb#959 - def rerender_changed_current_line; end - - # source://reline//lib/reline/line_editor.rb#2276 - def reverse_search_history(key); end - - # source://reline//lib/reline/line_editor.rb#1369 - def run_for_operators(key, method_symbol, &block); end - - # source://reline//lib/reline/line_editor.rb#344 - def scroll_down(val); end - - # source://reline//lib/reline/line_editor.rb#3163 - def search_next_char(key, arg, need_prev_char: T.unsafe(nil), inclusive: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3220 - def search_prev_char(key, arg, need_next_char = T.unsafe(nil)); end - - # Editline:: +ed-insert+ (vi input: almost all; emacs: printable characters) - # In insert mode, insert the input character left of the cursor - # position. In replace mode, overwrite the character at the - # cursor and move the cursor to the right by one character - # position. Accept an argument to do this repeatedly. It is an - # error if the input character is the NUL character (+Ctrl-@+). - # Failure to enlarge the edit buffer also results in an error. - # Editline:: +ed-digit+ (emacs: 0 to 9) If in argument input mode, append - # the input digit to the argument being read. Otherwise, call - # +ed-insert+. It is an error if the input character is not a - # digit or if the existing argument is already greater than a - # million. - # GNU Readline:: +self-insert+ (a, b, A, 1, !, …) Insert yourself. - # - # source://reline//lib/reline/line_editor.rb#1938 - def self_insert(key); end - - # source://reline//lib/reline/line_editor.rb#3274 - def set_mark(key); end - - # source://reline//lib/reline/line_editor.rb#1191 - def show_menu; end - - # source://reline//lib/reline/line_editor.rb#340 - def split_by_width(str, max_width); end - - # source://reline//lib/reline/line_editor.rb#2705 - def transpose_chars(key); end - - # source://reline//lib/reline/line_editor.rb#2725 - def transpose_words(key); end - - # Editline:: +vi-kill-line-prev+ (vi: +Ctrl-U+) Delete the string from the - # beginning of the edit buffer to the cursor and save it to the - # cut buffer. - # GNU Readline:: +unix-line-discard+ (+C-u+) Kill backward from the cursor - # to the beginning of the current line. - # - # source://reline//lib/reline/line_editor.rb#2568 - def unix_line_discard(key); end - - # source://reline//lib/reline/line_editor.rb#2784 - def unix_word_rubout(key); end - - # source://reline//lib/reline/line_editor.rb#2768 - def upcase_word(key); end - - # source://reline//lib/reline/line_editor.rb#765 - def update_each_dialog(dialog, cursor_column); end - - # source://reline//lib/reline/line_editor.rb#2806 - def vi_add(key); end - - # source://reline//lib/reline/line_editor.rb#2920 - def vi_add_at_eol(key); end - - # source://reline//lib/reline/line_editor.rb#2946 - def vi_change_meta(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2811 - def vi_command_mode(key); end - - # source://reline//lib/reline/line_editor.rb#2964 - def vi_delete_meta(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2895 - def vi_delete_prev_char(key); end - - # source://reline//lib/reline/line_editor.rb#2876 - def vi_end_big_word(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2991 - def vi_end_of_transmission(key); end - - # source://reline//lib/reline/line_editor.rb#2837 - def vi_end_word(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2991 - def vi_eof_maybe(key); end - - # source://reline//lib/reline/line_editor.rb#2047 - def vi_first_print(key); end - - # source://reline//lib/reline/line_editor.rb#3049 - def vi_histedit(key); end - - # source://reline//lib/reline/line_editor.rb#2802 - def vi_insert(key); end - - # source://reline//lib/reline/line_editor.rb#2915 - def vi_insert_at_bol(key); end - - # source://reline//lib/reline/line_editor.rb#3260 - def vi_join_lines(key, arg: T.unsafe(nil)); end - - # Editline:: +vi-kill-line-prev+ (vi: +Ctrl-U+) Delete the string from the - # beginning of the edit buffer to the cursor and save it to the - # cut buffer. - # GNU Readline:: +unix-line-discard+ (+C-u+) Kill backward from the cursor - # to the beginning of the current line. - # - # source://reline//lib/reline/line_editor.rb#2568 - def vi_kill_line_prev(key); end - - # source://reline//lib/reline/line_editor.rb#2991 - def vi_list_or_eof(key); end - - # source://reline//lib/reline/line_editor.rb#2811 - def vi_movement_mode(key); end - - # source://reline//lib/reline/line_editor.rb#2856 - def vi_next_big_word(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3155 - def vi_next_char(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2817 - def vi_next_word(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3083 - def vi_paste_next(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3071 - def vi_paste_prev(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2866 - def vi_prev_big_word(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3212 - def vi_prev_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2827 - def vi_prev_word(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3127 - def vi_replace_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2281 - def vi_search_next(key); end - - # source://reline//lib/reline/line_editor.rb#2276 - def vi_search_prev(key); end - - # source://reline//lib/reline/line_editor.rb#3112 - def vi_to_column(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3026 - def vi_to_history_line(key); end - - # source://reline//lib/reline/line_editor.rb#3159 - def vi_to_next_char(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#3216 - def vi_to_prev_char(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2979 - def vi_yank(key, arg: T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#2941 - def vi_zero(key); end - - # source://reline//lib/reline/line_editor.rb#2633 - def yank(key); end - - # source://reline//lib/reline/line_editor.rb#2645 - def yank_pop(key); end -end - -# source://reline//lib/reline/line_editor.rb#51 -Reline::LineEditor::CompletionJourneyData = Struct - -# source://reline//lib/reline/line_editor.rb#44 -Reline::LineEditor::CompletionState::COMPLETION = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/line_editor.rb#46 -Reline::LineEditor::CompletionState::JOURNEY = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/line_editor.rb#45 -Reline::LineEditor::CompletionState::MENU = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/line_editor.rb#47 -Reline::LineEditor::CompletionState::MENU_WITH_PERFECT_MATCH = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/line_editor.rb#43 -Reline::LineEditor::CompletionState::NORMAL = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/line_editor.rb#48 -Reline::LineEditor::CompletionState::PERFECT_MATCH = T.let(T.unsafe(nil), Symbol) - -# source://reline//lib/reline/line_editor.rb#644 -Reline::LineEditor::DIALOG_DEFAULT_HEIGHT = T.let(T.unsafe(nil), Integer) - -# source://reline//lib/reline/line_editor.rb#588 -class Reline::LineEditor::Dialog - # @return [Dialog] a new instance of Dialog - # - # source://reline//lib/reline/line_editor.rb#592 - def initialize(name, config, proc_scope); end - - # source://reline//lib/reline/line_editor.rb#616 - def call(key); end - - # Returns the value of attribute column. - # - # source://reline//lib/reline/line_editor.rb#590 - def column; end - - # Sets the attribute column - # - # @param value the value to set the attribute column to. - # - # source://reline//lib/reline/line_editor.rb#590 - def column=(_arg0); end - - # Returns the value of attribute contents. - # - # source://reline//lib/reline/line_editor.rb#589 - def contents; end - - # source://reline//lib/reline/line_editor.rb#609 - def contents=(contents); end - - # Returns the value of attribute name. - # - # source://reline//lib/reline/line_editor.rb#589 - def name; end - - # Returns the value of attribute pointer. - # - # source://reline//lib/reline/line_editor.rb#590 - def pointer; end - - # Sets the attribute pointer - # - # @param value the value to set the attribute pointer to. - # - # source://reline//lib/reline/line_editor.rb#590 - def pointer=(_arg0); end - - # Returns the value of attribute scroll_top. - # - # source://reline//lib/reline/line_editor.rb#590 - def scroll_top; end - - # Sets the attribute scroll_top - # - # @param value the value to set the attribute scroll_top to. - # - # source://reline//lib/reline/line_editor.rb#590 - def scroll_top=(_arg0); end - - # source://reline//lib/reline/line_editor.rb#601 - def set_cursor_pos(col, row); end - - # Returns the value of attribute trap_key. - # - # source://reline//lib/reline/line_editor.rb#590 - def trap_key; end - - # Sets the attribute trap_key - # - # @param value the value to set the attribute trap_key to. - # - # source://reline//lib/reline/line_editor.rb#590 - def trap_key=(_arg0); end - - # Returns the value of attribute vertical_offset. - # - # source://reline//lib/reline/line_editor.rb#590 - def vertical_offset; end - - # Sets the attribute vertical_offset - # - # @param value the value to set the attribute vertical_offset to. - # - # source://reline//lib/reline/line_editor.rb#590 - def vertical_offset=(_arg0); end - - # Returns the value of attribute width. - # - # source://reline//lib/reline/line_editor.rb#589 - def width; end - - # source://reline//lib/reline/line_editor.rb#605 - def width=(v); end -end - -# source://reline//lib/reline/line_editor.rb#511 -class Reline::LineEditor::DialogProcScope - # @return [DialogProcScope] a new instance of DialogProcScope - # - # source://reline//lib/reline/line_editor.rb#512 - def initialize(line_editor, config, proc_to_exec, context); end - - # source://reline//lib/reline/line_editor.rb#583 - def call; end - - # source://reline//lib/reline/line_editor.rb#528 - def call_completion_proc_with_checking_args(pre, target, post); end - - # source://reline//lib/reline/line_editor.rb#575 - def completion_journey_data; end - - # source://reline//lib/reline/line_editor.rb#579 - def config; end - - # source://reline//lib/reline/line_editor.rb#520 - def context; end - - # source://reline//lib/reline/line_editor.rb#553 - def cursor_pos; end - - # source://reline//lib/reline/line_editor.rb#536 - def dialog; end - - # source://reline//lib/reline/line_editor.rb#557 - def just_cursor_moving; end - - # source://reline//lib/reline/line_editor.rb#549 - def key; end - - # source://reline//lib/reline/line_editor.rb#569 - def preferred_dialog_height; end - - # source://reline//lib/reline/line_editor.rb#524 - def retrieve_completion_block(set_completion_quote_character = T.unsafe(nil)); end - - # source://reline//lib/reline/line_editor.rb#565 - def screen_height; end - - # source://reline//lib/reline/line_editor.rb#561 - def screen_width; end - - # source://reline//lib/reline/line_editor.rb#540 - def set_cursor_pos(col, row); end - - # source://reline//lib/reline/line_editor.rb#532 - def set_dialog(dialog); end - - # source://reline//lib/reline/line_editor.rb#545 - def set_key(key); end -end - -# source://reline//lib/reline/line_editor.rb#55 -Reline::LineEditor::MINIMUM_SCROLLBAR_HEIGHT = T.let(T.unsafe(nil), Integer) - -# source://reline//lib/reline/line_editor.rb#52 -Reline::LineEditor::MenuInfo = Struct - -# source://reline//lib/reline/line_editor.rb#54 -Reline::LineEditor::PROMPT_LIST_CACHE_TIMEOUT = T.let(T.unsafe(nil), Float) - -# source://reline//lib/reline/line_editor.rb#21 -Reline::LineEditor::VI_MOTIONS = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline/terminfo.rb#12 -module Reline::Terminfo - extend ::Fiddle - extend ::Fiddle::CParser - extend ::Fiddle::Importer - - class << self - # source://reline//lib/reline/terminfo.rb#32 - def curses_dl; end - - # source://reline//lib/reline/terminfo.rb#17 - def curses_dl_files; end - - # @return [Boolean] - # - # source://reline//lib/reline/terminfo.rb#157 - def enabled?; end - end -end - -# source://reline//lib/reline.rb#16 -Reline::USERNAME_COMPLETION_PROC = T.let(T.unsafe(nil), T.untyped) - -# source://reline//lib/reline/unicode.rb#1 -class Reline::Unicode - class << self - # source://reline//lib/reline/unicode.rb#125 - def calculate_width(str, allow_escape_code = T.unsafe(nil)); end - - # source://reline//lib/reline/unicode.rb#327 - def ed_transpose_words(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#287 - def em_backward_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#307 - def em_big_backward_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#238 - def em_forward_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#258 - def em_forward_word_with_capitalization(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#64 - def escape_for_print(str); end - - # source://reline//lib/reline/unicode.rb#44 - def get_mbchar_byte_size_by_first_char(c); end - - # source://reline//lib/reline/unicode.rb#105 - def get_mbchar_width(mbchar); end - - # source://reline//lib/reline/unicode.rb#224 - def get_next_mbchar_size(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#229 - def get_prev_mbchar_size(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#151 - def split_by_width(str, max_width, encoding = T.unsafe(nil)); end - - # Take a chunk of a String cut by width with escape sequences. - # - # source://reline//lib/reline/unicode.rb#195 - def take_range(str, start_col, max_width); end - - # source://reline//lib/reline/unicode.rb#616 - def vi_backward_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#478 - def vi_big_backward_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#448 - def vi_big_forward_end_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#428 - def vi_big_forward_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#648 - def vi_first_print(line); end - - # source://reline//lib/reline/unicode.rb#539 - def vi_forward_end_word(line, byte_pointer); end - - # source://reline//lib/reline/unicode.rb#498 - def vi_forward_word(line, byte_pointer, drop_terminate_spaces = T.unsafe(nil)); end - end -end - -# source://reline//lib/reline/unicode.rb#40 -Reline::Unicode::CSI_REGEXP = T.let(T.unsafe(nil), Regexp) - -# Ambiguous -# -# source://reline//lib/reline/unicode/east_asian_width.rb#158 -Reline::Unicode::EastAsianWidth::TYPE_A = T.let(T.unsafe(nil), Regexp) - -# Fullwidth -# -# source://reline//lib/reline/unicode/east_asian_width.rb#6 -Reline::Unicode::EastAsianWidth::TYPE_F = T.let(T.unsafe(nil), Regexp) - -# Halfwidth -# -# source://reline//lib/reline/unicode/east_asian_width.rb#13 -Reline::Unicode::EastAsianWidth::TYPE_H = T.let(T.unsafe(nil), Regexp) - -# Neutral -# -# source://reline//lib/reline/unicode/east_asian_width.rb#341 -Reline::Unicode::EastAsianWidth::TYPE_N = T.let(T.unsafe(nil), Regexp) - -# Narrow -# -# source://reline//lib/reline/unicode/east_asian_width.rb#147 -Reline::Unicode::EastAsianWidth::TYPE_NA = T.let(T.unsafe(nil), Regexp) - -# Wide -# -# source://reline//lib/reline/unicode/east_asian_width.rb#24 -Reline::Unicode::EastAsianWidth::TYPE_W = T.let(T.unsafe(nil), Regexp) - -# C-? C-8 -# -# source://reline//lib/reline/unicode.rb#36 -Reline::Unicode::EscapedChars = T.let(T.unsafe(nil), Array) - -# source://reline//lib/reline/unicode.rb#2 -Reline::Unicode::EscapedPairs = T.let(T.unsafe(nil), Hash) - -# source://reline//lib/reline/unicode.rb#77 -Reline::Unicode::HalfwidthDakutenHandakuten = T.let(T.unsafe(nil), Regexp) - -# source://reline//lib/reline/unicode.rb#79 -Reline::Unicode::MBCharWidthRE = T.let(T.unsafe(nil), Regexp) - -# source://reline//lib/reline/unicode.rb#39 -Reline::Unicode::NON_PRINTING_END = T.let(T.unsafe(nil), String) - -# source://reline//lib/reline/unicode.rb#38 -Reline::Unicode::NON_PRINTING_START = T.let(T.unsafe(nil), String) - -# source://reline//lib/reline/unicode.rb#41 -Reline::Unicode::OSC_REGEXP = T.let(T.unsafe(nil), Regexp) - -# source://reline//lib/reline/unicode.rb#42 -Reline::Unicode::WIDTH_SCANNER = T.let(T.unsafe(nil), Regexp) - -# source://reline//lib/reline/version.rb#2 -Reline::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/reline@0.5.9.rbi b/sorbet/rbi/gems/reline@0.5.9.rbi new file mode 100644 index 000000000..1b50adcd7 --- /dev/null +++ b/sorbet/rbi/gems/reline@0.5.9.rbi @@ -0,0 +1,2425 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `reline` gem. +# Please instead update this file by running `bin/tapioca gem reline`. + + +# source://reline//lib/reline/version.rb#1 +module Reline + extend ::Forwardable + extend ::SingleForwardable + + class << self + # source://reline//lib/reline.rb#483 + def core; end + + # source://reline//lib/reline.rb#479 + def encoding_system_needs; end + + # source://reline//lib/reline.rb#460 + def insert_text(*args, &block); end + + # source://reline//lib/reline.rb#503 + def line_editor; end + + # source://reline//lib/reline.rb#499 + def ungetc(c); end + end +end + +# source://reline//lib/reline/io/ansi.rb#4 +class Reline::ANSI < ::Reline::IO + # @return [ANSI] a new instance of ANSI + # + # source://reline//lib/reline/io/ansi.rb#36 + def initialize; end + + # @return [Boolean] + # + # source://reline//lib/reline/io/ansi.rb#283 + def both_tty?; end + + # source://reline//lib/reline/io/ansi.rb#343 + def clear_screen; end + + # source://reline//lib/reline/io/ansi.rb#248 + def cursor_pos; end + + # source://reline//lib/reline/io/ansi.rb#359 + def deprep(otio); end + + # @return [Boolean] + # + # source://reline//lib/reline/io/ansi.rb#209 + def empty_buffer?; end + + # source://reline//lib/reline/io/ansi.rb#43 + def encoding; end + + # source://reline//lib/reline/io/ansi.rb#331 + def erase_after_cursor; end + + # source://reline//lib/reline/io/ansi.rb#231 + def get_screen_size; end + + # if the usage expects to wait indefinitely, use Float::INFINITY for timeout_second + # + # source://reline//lib/reline/io/ansi.rb#201 + def getc(timeout_second); end + + # source://reline//lib/reline/io/ansi.rb#307 + def hide_cursor; end + + # @return [Boolean] + # + # source://reline//lib/reline/io/ansi.rb#205 + def in_pasting?; end + + # source://reline//lib/reline/io/ansi.rb#170 + def inner_getc(timeout_second); end + + # source://reline//lib/reline/io/ansi.rb#154 + def input=(val); end + + # source://reline//lib/reline/io/ansi.rb#287 + def move_cursor_column(x); end + + # source://reline//lib/reline/io/ansi.rb#299 + def move_cursor_down(x); end + + # source://reline//lib/reline/io/ansi.rb#291 + def move_cursor_up(x); end + + # source://reline//lib/reline/io/ansi.rb#158 + def output=(val); end + + # source://reline//lib/reline/io/ansi.rb#352 + def prep; end + + # source://reline//lib/reline/io/ansi.rb#189 + def read_bracketed_paste; end + + # source://reline//lib/reline/io/ansi.rb#220 + def retrieve_keybuffer; end + + # This only works when the cursor is at the bottom of the scroll range + # For more details, see https://github.com/ruby/reline/pull/577#issuecomment-1646679623 + # + # source://reline//lib/reline/io/ansi.rb#337 + def scroll_down(x); end + + # source://reline//lib/reline/io/ansi.rb#70 + def set_bracketed_paste_key_bindings(config); end + + # source://reline//lib/reline/io/ansi.rb#47 + def set_default_key_bindings(config, allow_terminfo: T.unsafe(nil)); end + + # source://reline//lib/reline/io/ansi.rb#76 + def set_default_key_bindings_ansi_cursor(config); end + + # source://reline//lib/reline/io/ansi.rb#115 + def set_default_key_bindings_comprehensive_list(config); end + + # source://reline//lib/reline/io/ansi.rb#98 + def set_default_key_bindings_terminfo(config); end + + # source://reline//lib/reline/io/ansi.rb#241 + def set_screen_size(rows, columns); end + + # source://reline//lib/reline/io/ansi.rb#348 + def set_winch_handler(&handler); end + + # source://reline//lib/reline/io/ansi.rb#319 + def show_cursor; end + + # source://reline//lib/reline/io/ansi.rb#216 + def ungetc(c); end + + # source://reline//lib/reline/io/ansi.rb#162 + def with_raw_input; end +end + +# source://reline//lib/reline/io/ansi.rb#17 +Reline::ANSI::ANSI_CURSOR_KEY_BINDINGS = T.let(T.unsafe(nil), Hash) + +# source://reline//lib/reline/io/ansi.rb#5 +Reline::ANSI::CAPNAME_KEY_BINDINGS = T.let(T.unsafe(nil), Hash) + +# source://reline//lib/reline/io/ansi.rb#188 +Reline::ANSI::END_BRACKETED_PASTE = T.let(T.unsafe(nil), String) + +# source://reline//lib/reline/io/ansi.rb#187 +Reline::ANSI::START_BRACKETED_PASTE = T.let(T.unsafe(nil), String) + +# source://reline//lib/reline/config.rb#1 +class Reline::Config + # @return [Config] a new instance of Config + # + # source://reline//lib/reline/config.rb#31 + def initialize; end + + # source://reline//lib/reline/config.rb#156 + def add_default_key_binding(keystroke, target); end + + # source://reline//lib/reline/config.rb#152 + def add_default_key_binding_by_keymap(keymap, keystroke, target); end + + # source://reline//lib/reline/config.rb#141 + def add_oneshot_key_binding(keystroke, target); end + + # Returns the value of attribute autocompletion. + # + # source://reline//lib/reline/config.rb#29 + def autocompletion; end + + # Sets the attribute autocompletion + # + # @param value the value to set the attribute autocompletion to. + # + # source://reline//lib/reline/config.rb#29 + def autocompletion=(_arg0); end + + # source://reline//lib/reline/config.rb#323 + def bind_key(key, func_name); end + + # source://reline//lib/reline/config.rb#240 + def bind_variable(name, value, raw_value); end + + # source://reline//lib/reline/config.rb#26 + def completion_ignore_case; end + + # source://reline//lib/reline/config.rb#26 + def completion_ignore_case=(_arg0); end + + # source://reline//lib/reline/config.rb#26 + def convert_meta; end + + # source://reline//lib/reline/config.rb#26 + def convert_meta=(_arg0); end + + # source://reline//lib/reline/config.rb#26 + def disable_completion; end + + # source://reline//lib/reline/config.rb#26 + def disable_completion=(_arg0); end + + # source://reline//lib/reline/config.rb#66 + def editing_mode; end + + # source://reline//lib/reline/config.rb#70 + def editing_mode=(val); end + + # @return [Boolean] + # + # source://reline//lib/reline/config.rb#74 + def editing_mode_is?(*val); end + + # source://reline//lib/reline/config.rb#26 + def emacs_mode_string; end + + # source://reline//lib/reline/config.rb#26 + def emacs_mode_string=(_arg0); end + + # source://reline//lib/reline/config.rb#26 + def enable_bracketed_paste; end + + # source://reline//lib/reline/config.rb#26 + def enable_bracketed_paste=(_arg0); end + + # source://reline//lib/reline/config.rb#205 + def handle_directive(directive, file, no, if_stack); end + + # source://reline//lib/reline/config.rb#26 + def history_size; end + + # source://reline//lib/reline/config.rb#26 + def history_size=(_arg0); end + + # source://reline//lib/reline/config.rb#86 + def inputrc_path; end + + # source://reline//lib/reline/config.rb#26 + def isearch_terminators; end + + # source://reline//lib/reline/config.rb#26 + def isearch_terminators=(_arg0); end + + # source://reline//lib/reline/config.rb#136 + def key_bindings; end + + # source://reline//lib/reline/config.rb#337 + def key_notation_to_code(notation); end + + # source://reline//lib/reline/config.rb#78 + def keymap; end + + # source://reline//lib/reline/config.rb#26 + def keyseq_timeout; end + + # source://reline//lib/reline/config.rb#26 + def keyseq_timeout=(_arg0); end + + # @return [Boolean] + # + # source://reline//lib/reline/config.rb#82 + def loaded?; end + + # source://reline//lib/reline/config.rb#371 + def parse_keyseq(str); end + + # source://reline//lib/reline/config.rb#116 + def read(file = T.unsafe(nil)); end + + # source://reline//lib/reline/config.rb#160 + def read_lines(lines, file = T.unsafe(nil)); end + + # source://reline//lib/reline/config.rb#59 + def reset; end + + # source://reline//lib/reline/config.rb#148 + def reset_oneshot_key_bindings; end + + # source://reline//lib/reline/config.rb#318 + def retrieve_string(str); end + + # source://reline//lib/reline/config.rb#26 + def show_all_if_ambiguous; end + + # source://reline//lib/reline/config.rb#26 + def show_all_if_ambiguous=(_arg0); end + + # source://reline//lib/reline/config.rb#26 + def show_mode_in_prompt; end + + # source://reline//lib/reline/config.rb#26 + def show_mode_in_prompt=(_arg0); end + + # Returns the value of attribute test_mode. + # + # source://reline//lib/reline/config.rb#2 + def test_mode; end + + # source://reline//lib/reline/config.rb#26 + def vi_cmd_mode_string; end + + # source://reline//lib/reline/config.rb#26 + def vi_cmd_mode_string=(_arg0); end + + # source://reline//lib/reline/config.rb#26 + def vi_ins_mode_string; end + + # source://reline//lib/reline/config.rb#26 + def vi_ins_mode_string=(_arg0); end + + private + + # source://reline//lib/reline/config.rb#112 + def default_inputrc_path; end + + # @return [Boolean] + # + # source://reline//lib/reline/config.rb#379 + def seven_bit_encoding?(encoding); end +end + +# source://reline//lib/reline/config.rb#6 +class Reline::Config::InvalidInputrc < ::RuntimeError + # Returns the value of attribute file. + # + # source://reline//lib/reline/config.rb#7 + def file; end + + # Sets the attribute file + # + # @param value the value to set the attribute file to. + # + # source://reline//lib/reline/config.rb#7 + def file=(_arg0); end + + # Returns the value of attribute lineno. + # + # source://reline//lib/reline/config.rb#7 + def lineno; end + + # Sets the attribute lineno + # + # @param value the value to set the attribute lineno to. + # + # source://reline//lib/reline/config.rb#7 + def lineno=(_arg0); end +end + +# source://reline//lib/reline/config.rb#4 +Reline::Config::KEYSEQ_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://reline//lib/reline/config.rb#10 +Reline::Config::VARIABLE_NAMES = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/config.rb#24 +Reline::Config::VARIABLE_NAME_SYMBOLS = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline.rb#39 +class Reline::Core + extend ::Forwardable + + # @return [Core] a new instance of Core + # @yield [_self] + # @yieldparam _self [Reline::Core] the object that the method was called on + # + # source://reline//lib/reline.rb#67 + def initialize; end + + # @raise [ArgumentError] + # + # source://reline//lib/reline.rb#161 + def add_dialog_proc(name_sym, p, context = T.unsafe(nil)); end + + # source://reline//lib/reline.rb#406 + def ambiguous_width; end + + # source://reline//lib/reline.rb#54 + def auto_indent_proc; end + + # @raise [ArgumentError] + # + # source://reline//lib/reline.rb#146 + def auto_indent_proc=(p); end + + # source://reline//lib/reline.rb#54 + def basic_quote_characters; end + + # source://reline//lib/reline.rb#103 + def basic_quote_characters=(v); end + + # source://reline//lib/reline.rb#54 + def basic_word_break_characters; end + + # source://reline//lib/reline.rb#95 + def basic_word_break_characters=(v); end + + # source://reline//lib/reline.rb#54 + def completer_quote_characters; end + + # source://reline//lib/reline.rb#107 + def completer_quote_characters=(v); end + + # source://reline//lib/reline.rb#54 + def completer_word_break_characters; end + + # source://reline//lib/reline.rb#99 + def completer_word_break_characters=(v); end + + # source://reline//lib/reline.rb#54 + def completion_append_character; end + + # source://reline//lib/reline.rb#83 + def completion_append_character=(val); end + + # source://reline//lib/reline.rb#123 + def completion_case_fold; end + + # source://reline//lib/reline.rb#119 + def completion_case_fold=(v); end + + # source://reline//lib/reline.rb#54 + def completion_proc; end + + # @raise [ArgumentError] + # + # source://reline//lib/reline.rb#131 + def completion_proc=(p); end + + # source://reline//lib/reline.rb#127 + def completion_quote_character; end + + # Returns the value of attribute config. + # + # source://reline//lib/reline.rb#56 + def config; end + + # Sets the attribute config + # + # @param value the value to set the attribute config to. + # + # source://reline//lib/reline.rb#56 + def config=(_arg0); end + + # source://reline//lib/reline.rb#171 + def dialog_proc(name_sym); end + + # source://reline//lib/reline.rb#54 + def dig_perfect_match_proc; end + + # @raise [ArgumentError] + # + # source://reline//lib/reline.rb#155 + def dig_perfect_match_proc=(p); end + + # source://reline//lib/reline.rb#195 + def emacs_editing_mode; end + + # @return [Boolean] + # + # source://reline//lib/reline.rb#204 + def emacs_editing_mode?; end + + # source://reline//lib/reline.rb#79 + def encoding; end + + # source://reline//lib/reline.rb#54 + def filename_quote_characters; end + + # source://reline//lib/reline.rb#111 + def filename_quote_characters=(v); end + + # source://reline//lib/reline.rb#208 + def get_screen_size; end + + # @raise [TypeError] + # + # source://reline//lib/reline.rb#175 + def input=(val); end + + # source://reline//lib/reline.rb#75 + def io_gate; end + + # Returns the value of attribute key_stroke. + # + # source://reline//lib/reline.rb#57 + def key_stroke; end + + # Sets the attribute key_stroke + # + # @param value the value to set the attribute key_stroke to. + # + # source://reline//lib/reline.rb#57 + def key_stroke=(_arg0); end + + # Returns the value of attribute last_incremental_search. + # + # source://reline//lib/reline.rb#59 + def last_incremental_search; end + + # Sets the attribute last_incremental_search + # + # @param value the value to set the attribute last_incremental_search to. + # + # source://reline//lib/reline.rb#59 + def last_incremental_search=(_arg0); end + + # Returns the value of attribute line_editor. + # + # source://reline//lib/reline.rb#58 + def line_editor; end + + # Sets the attribute line_editor + # + # @param value the value to set the attribute line_editor to. + # + # source://reline//lib/reline.rb#58 + def line_editor=(_arg0); end + + # Returns the value of attribute output. + # + # source://reline//lib/reline.rb#60 + def output; end + + # @raise [TypeError] + # + # source://reline//lib/reline.rb#182 + def output=(val); end + + # source://reline//lib/reline.rb#54 + def output_modifier_proc; end + + # @raise [ArgumentError] + # + # source://reline//lib/reline.rb#136 + def output_modifier_proc=(p); end + + # source://reline//lib/reline.rb#54 + def pre_input_hook; end + + # source://reline//lib/reline.rb#151 + def pre_input_hook=(p); end + + # source://reline//lib/reline.rb#54 + def prompt_proc; end + + # @raise [ArgumentError] + # + # source://reline//lib/reline.rb#141 + def prompt_proc=(p); end + + # source://reline//lib/reline.rb#277 + def readline(prompt = T.unsafe(nil), add_hist = T.unsafe(nil)); end + + # source://reline//lib/reline.rb#251 + def readmultiline(prompt = T.unsafe(nil), add_hist = T.unsafe(nil), &confirm_multiline_termination); end + + # source://reline//lib/reline.rb#54 + def special_prefixes; end + + # source://reline//lib/reline.rb#115 + def special_prefixes=(v); end + + # source://reline//lib/reline.rb#190 + def vi_editing_mode; end + + # @return [Boolean] + # + # source://reline//lib/reline.rb#200 + def vi_editing_mode?; end + + private + + # source://reline//lib/reline.rb#294 + def inner_readline(prompt, add_hist, multiline, &confirm_multiline_termination); end + + # source://reline//lib/reline.rb#411 + def may_req_ambiguous_char_width; end + + # GNU Readline watis for "keyseq-timeout" milliseconds when the input is + # ambiguous whether it is matching or matched. + # If the next character does not arrive within the specified timeout, input + # is considered as matched. + # `ESC` is ambiguous because it can be a standalone ESC (matched) or part of + # `ESC char` or part of CSI sequence (matching). + # + # source://reline//lib/reline.rb#376 + def read_io(keyseq_timeout, &block); end +end + +# source://reline//lib/reline.rb#40 +Reline::Core::ATTR_READER_NAMES = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline.rb#249 +Reline::DEFAULT_DIALOG_CONTEXT = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline.rb#212 +Reline::DEFAULT_DIALOG_PROC_AUTOCOMPLETE = T.let(T.unsafe(nil), Proc) + +# source://reline//lib/reline/io/dumb.rb#3 +class Reline::Dumb < ::Reline::IO + # @return [Dumb] a new instance of Dumb + # + # source://reline//lib/reline/io/dumb.rb#6 + def initialize(encoding: T.unsafe(nil)); end + + # source://reline//lib/reline/io/dumb.rb#87 + def clear_screen; end + + # source://reline//lib/reline/io/dumb.rb#62 + def cursor_pos; end + + # source://reline//lib/reline/io/dumb.rb#104 + def deprep(otio); end + + # @return [Boolean] + # + # source://reline//lib/reline/io/dumb.rb#14 + def dumb?; end + + # source://reline//lib/reline/io/dumb.rb#18 + def encoding; end + + # source://reline//lib/reline/io/dumb.rb#81 + def erase_after_cursor; end + + # source://reline//lib/reline/io/dumb.rb#58 + def get_screen_size; end + + # source://reline//lib/reline/io/dumb.rb#39 + def getc(_timeout_second); end + + # source://reline//lib/reline/io/dumb.rb#66 + def hide_cursor; end + + # @return [Boolean] + # + # source://reline//lib/reline/io/dumb.rb#97 + def in_pasting?; end + + # source://reline//lib/reline/io/dumb.rb#31 + def input=(val); end + + # source://reline//lib/reline/io/dumb.rb#72 + def move_cursor_column(val); end + + # source://reline//lib/reline/io/dumb.rb#78 + def move_cursor_down(val); end + + # source://reline//lib/reline/io/dumb.rb#75 + def move_cursor_up(val); end + + # source://reline//lib/reline/io/dumb.rb#101 + def prep; end + + # source://reline//lib/reline/io/dumb.rb#84 + def scroll_down(val); end + + # source://reline//lib/reline/io/dumb.rb#28 + def set_default_key_bindings(_); end + + # source://reline//lib/reline/io/dumb.rb#90 + def set_screen_size(rows, columns); end + + # source://reline//lib/reline/io/dumb.rb#94 + def set_winch_handler(&handler); end + + # source://reline//lib/reline/io/dumb.rb#69 + def show_cursor; end + + # source://reline//lib/reline/io/dumb.rb#54 + def ungetc(c); end + + # source://reline//lib/reline/io/dumb.rb#35 + def with_raw_input; end +end + +# Do not send color reset sequence +# +# source://reline//lib/reline/io/dumb.rb#4 +Reline::Dumb::RESET_COLOR = T.let(T.unsafe(nil), String) + +# NOTE: For making compatible with the rb-readline gem +# +# source://reline//lib/reline.rb#16 +Reline::FILENAME_COMPLETION_PROC = T.let(T.unsafe(nil), T.untyped) + +# source://reline//lib/reline/face.rb#3 +class Reline::Face + class << self + # source://reline//lib/reline/face.rb#169 + def [](name); end + + # source://reline//lib/reline/face.rb#173 + def config(name, &block); end + + # source://reline//lib/reline/face.rb#178 + def configs; end + + # source://reline//lib/reline/face.rb#164 + def force_truecolor; end + + # source://reline//lib/reline/face.rb#182 + def load_initial_configs; end + + # source://reline//lib/reline/face.rb#195 + def reset_to_initial_configs; end + + # @return [Boolean] + # + # source://reline//lib/reline/face.rb#160 + def truecolor?; end + end +end + +# source://reline//lib/reline/face.rb#58 +class Reline::Face::Config + # @return [Config] a new instance of Config + # + # source://reline//lib/reline/face.rb#62 + def initialize(name, &block); end + + # source://reline//lib/reline/face.rb#84 + def [](name); end + + # source://reline//lib/reline/face.rb#72 + def define(name, **values); end + + # Returns the value of attribute definition. + # + # source://reline//lib/reline/face.rb#70 + def definition; end + + # source://reline//lib/reline/face.rb#77 + def reconfigure; end + + private + + # source://reline//lib/reline/face.rb#126 + def format_to_sgr(ordered_values); end + + # @return [Boolean] + # + # source://reline//lib/reline/face.rb#153 + def rgb_expression?(color); end + + # source://reline//lib/reline/face.rb#90 + def sgr_rgb(key, value); end + + # source://reline//lib/reline/face.rb#108 + def sgr_rgb_256color(key, value); end + + # source://reline//lib/reline/face.rb#99 + def sgr_rgb_truecolor(key, value); end +end + +# source://reline//lib/reline/face.rb#59 +Reline::Face::Config::ESSENTIAL_DEFINE_NAMES = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/face.rb#60 +Reline::Face::Config::RESET_SGR = T.let(T.unsafe(nil), String) + +# source://reline//lib/reline/face.rb#4 +Reline::Face::SGR_PARAMETERS = T.let(T.unsafe(nil), Hash) + +# source://reline//lib/reline.rb#516 +Reline::HISTORY = T.let(T.unsafe(nil), Reline::History) + +# source://reline//lib/reline/history.rb#1 +class Reline::History < ::Array + # @return [History] a new instance of History + # + # source://reline//lib/reline/history.rb#2 + def initialize(config); end + + # source://reline//lib/reline/history.rb#52 + def <<(val); end + + # source://reline//lib/reline/history.rb#15 + def [](index); end + + # source://reline//lib/reline/history.rb#20 + def []=(index, val); end + + # source://reline//lib/reline/history.rb#25 + def concat(*val); end + + # source://reline//lib/reline/history.rb#10 + def delete_at(index); end + + # source://reline//lib/reline/history.rb#31 + def push(*val); end + + # source://reline//lib/reline/history.rb#6 + def to_s; end + + private + + # @raise [IndexError] + # + # source://reline//lib/reline/history.rb#62 + def check_index(index); end +end + +# source://reline//lib/reline/io.rb#3 +class Reline::IO + # @return [Boolean] + # + # source://reline//lib/reline/io.rb#27 + def dumb?; end + + # source://reline//lib/reline/io.rb#35 + def reset_color_sequence; end + + # @return [Boolean] + # + # source://reline//lib/reline/io.rb#31 + def win?; end + + class << self + # source://reline//lib/reline/io.rb#6 + def decide_io_gate; end + end +end + +# source://reline//lib/reline/io.rb#4 +Reline::IO::RESET_COLOR = T.let(T.unsafe(nil), String) + +# source://reline//lib/reline.rb#509 +Reline::IOGate = T.let(T.unsafe(nil), Reline::ANSI) + +# source://reline//lib/reline.rb#21 +class Reline::Key < ::Struct + # Returns the value of attribute char + # + # @return [Object] the current value of char + def char; end + + # Sets the attribute char + # + # @param value [Object] the value to set the attribute char to. + # @return [Object] the newly set value + def char=(_); end + + # Returns the value of attribute combined_char + # + # @return [Object] the current value of combined_char + def combined_char; end + + # Sets the attribute combined_char + # + # @param value [Object] the value to set the attribute combined_char to. + # @return [Object] the newly set value + def combined_char=(_); end + + # For dialog_proc `key.match?(dialog.name)` + # + # @return [Boolean] + # + # source://reline//lib/reline.rb#23 + def match?(sym); end + + # Returns the value of attribute with_meta + # + # @return [Object] the current value of with_meta + def with_meta; end + + # Sets the attribute with_meta + # + # @param value [Object] the value to set the attribute with_meta to. + # @return [Object] the newly set value + def with_meta=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://reline//lib/reline/key_actor/base.rb#1 +class Reline::KeyActor::Base + # @return [Base] a new instance of Base + # + # source://reline//lib/reline/key_actor/base.rb#2 + def initialize(mapping = T.unsafe(nil)); end + + # source://reline//lib/reline/key_actor/base.rb#12 + def add(key, func); end + + # source://reline//lib/reline/key_actor/base.rb#27 + def clear; end + + # source://reline//lib/reline/key_actor/base.rb#23 + def get(key); end + + # source://reline//lib/reline/key_actor/base.rb#8 + def get_method(key); end + + # @return [Boolean] + # + # source://reline//lib/reline/key_actor/base.rb#19 + def matching?(key); end +end + +# source://reline//lib/reline/key_actor/composite.rb#1 +class Reline::KeyActor::Composite + # @return [Composite] a new instance of Composite + # + # source://reline//lib/reline/key_actor/composite.rb#2 + def initialize(key_actors); end + + # source://reline//lib/reline/key_actor/composite.rb#10 + def get(key); end + + # @return [Boolean] + # + # source://reline//lib/reline/key_actor/composite.rb#6 + def matching?(key); end +end + +# source://reline//lib/reline/key_actor/emacs.rb#2 +Reline::KeyActor::EMACS_MAPPING = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/key_actor/vi_command.rb#2 +Reline::KeyActor::VI_COMMAND_MAPPING = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/key_actor/vi_insert.rb#2 +Reline::KeyActor::VI_INSERT_MAPPING = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/key_stroke.rb#1 +class Reline::KeyStroke + # @return [KeyStroke] a new instance of KeyStroke + # + # source://reline//lib/reline/key_stroke.rb#6 + def initialize(config); end + + # source://reline//lib/reline/key_stroke.rb#42 + def expand(input); end + + # source://reline//lib/reline/key_stroke.rb#19 + def match_status(input); end + + private + + # source://reline//lib/reline/key_stroke.rb#106 + def key_mapping; end + + # returns match status of CSI/SS3 sequence and matched length + # + # source://reline//lib/reline/key_stroke.rb#70 + def match_unknown_escape_sequence(input, vi_mode: T.unsafe(nil)); end +end + +# source://reline//lib/reline/key_stroke.rb#4 +Reline::KeyStroke::CSI_INTERMEDIATE_BYTES_RANGE = T.let(T.unsafe(nil), Range) + +# source://reline//lib/reline/key_stroke.rb#3 +Reline::KeyStroke::CSI_PARAMETER_BYTES_RANGE = T.let(T.unsafe(nil), Range) + +# source://reline//lib/reline/key_stroke.rb#2 +Reline::KeyStroke::ESC_BYTE = T.let(T.unsafe(nil), Integer) + +# Input partially matches to a key sequence +# +# source://reline//lib/reline/key_stroke.rb#13 +Reline::KeyStroke::MATCHED = T.let(T.unsafe(nil), Symbol) + +# Input exactly matches to a key sequence +# +# source://reline//lib/reline/key_stroke.rb#11 +Reline::KeyStroke::MATCHING = T.let(T.unsafe(nil), Symbol) + +# Input matches to a key sequence and the key sequence is a prefix of another key sequence +# +# source://reline//lib/reline/key_stroke.rb#15 +Reline::KeyStroke::MATCHING_MATCHED = T.let(T.unsafe(nil), Symbol) + +# Input does not match to any key sequence +# +# source://reline//lib/reline/key_stroke.rb#17 +Reline::KeyStroke::UNMATCHED = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/kill_ring.rb#1 +class Reline::KillRing + include ::Enumerable + + # @return [KillRing] a new instance of KillRing + # + # source://reline//lib/reline/kill_ring.rb#61 + def initialize(max = T.unsafe(nil)); end + + # source://reline//lib/reline/kill_ring.rb#68 + def append(string, before_p = T.unsafe(nil)); end + + # source://reline//lib/reline/kill_ring.rb#116 + def each; end + + # source://reline//lib/reline/kill_ring.rb#83 + def process; end + + # source://reline//lib/reline/kill_ring.rb#96 + def yank; end + + # source://reline//lib/reline/kill_ring.rb#106 + def yank_pop; end +end + +# source://reline//lib/reline/kill_ring.rb#21 +class Reline::KillRing::RingBuffer + # @return [RingBuffer] a new instance of RingBuffer + # + # source://reline//lib/reline/kill_ring.rb#25 + def initialize(max = T.unsafe(nil)); end + + # source://reline//lib/reline/kill_ring.rb#31 + def <<(point); end + + # @return [Boolean] + # + # source://reline//lib/reline/kill_ring.rb#56 + def empty?; end + + # Returns the value of attribute head. + # + # source://reline//lib/reline/kill_ring.rb#23 + def head; end + + # Returns the value of attribute size. + # + # source://reline//lib/reline/kill_ring.rb#22 + def size; end +end + +# source://reline//lib/reline/kill_ring.rb#11 +class Reline::KillRing::RingPoint < ::Struct + # @return [RingPoint] a new instance of RingPoint + # + # source://reline//lib/reline/kill_ring.rb#12 + def initialize(str); end + + # source://reline//lib/reline/kill_ring.rb#16 + def ==(other); end +end + +# source://reline//lib/reline/kill_ring.rb#6 +Reline::KillRing::State::CONTINUED = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/kill_ring.rb#5 +Reline::KillRing::State::FRESH = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/kill_ring.rb#7 +Reline::KillRing::State::PROCESSED = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/kill_ring.rb#8 +Reline::KillRing::State::YANK = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/line_editor.rb#6 +class Reline::LineEditor + # @return [LineEditor] a new instance of LineEditor + # + # source://reline//lib/reline/line_editor.rb#75 + def initialize(config, encoding); end + + # source://reline//lib/reline/line_editor.rb#697 + def add_dialog_proc(name, p, context = T.unsafe(nil)); end + + # Returns the value of attribute auto_indent_proc. + # + # source://reline//lib/reline/line_editor.rb#14 + def auto_indent_proc; end + + # Sets the attribute auto_indent_proc + # + # @param value the value to set the attribute auto_indent_proc to. + # + # source://reline//lib/reline/line_editor.rb#14 + def auto_indent_proc=(_arg0); end + + # TODO: Use "private alias_method" idiom after drop Ruby 2.5. + # + # source://reline//lib/reline/line_editor.rb#8 + def byte_pointer; end + + # source://reline//lib/reline/line_editor.rb#1396 + def byte_pointer=(val); end + + # source://reline//lib/reline/line_editor.rb#399 + def calculate_overlay_levels(overlay_levels); end + + # source://reline//lib/reline/line_editor.rb#1181 + def call_completion_proc; end + + # source://reline//lib/reline/line_editor.rb#1189 + def call_completion_proc_with_checking_args(pre, target, post); end + + # source://reline//lib/reline/line_editor.rb#447 + def clear_dialogs; end + + # source://reline//lib/reline/line_editor.rb#467 + def clear_rendered_lines; end + + # Returns the value of attribute completion_append_character. + # + # source://reline//lib/reline/line_editor.rb#11 + def completion_append_character; end + + # Sets the attribute completion_append_character + # + # @param value the value to set the attribute completion_append_character to. + # + # source://reline//lib/reline/line_editor.rb#11 + def completion_append_character=(_arg0); end + + # Returns the value of attribute completion_proc. + # + # source://reline//lib/reline/line_editor.rb#10 + def completion_proc; end + + # Sets the attribute completion_proc + # + # @param value the value to set the attribute completion_proc to. + # + # source://reline//lib/reline/line_editor.rb#10 + def completion_proc=(_arg0); end + + # source://reline//lib/reline/line_editor.rb#1335 + def confirm_multiline_termination; end + + # Returns the value of attribute confirm_multiline_termination_proc. + # + # source://reline//lib/reline/line_editor.rb#9 + def confirm_multiline_termination_proc; end + + # Sets the attribute confirm_multiline_termination_proc + # + # @param value the value to set the attribute confirm_multiline_termination_proc to. + # + # source://reline//lib/reline/line_editor.rb#9 + def confirm_multiline_termination_proc=(_arg0); end + + # source://reline//lib/reline/line_editor.rb#305 + def current_byte_pointer_cursor; end + + # source://reline//lib/reline/line_editor.rb#1232 + def current_line; end + + # source://reline//lib/reline/line_editor.rb#1362 + def delete_text(start = T.unsafe(nil), length = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#904 + def dialog_proc_scope_completion_journey_data; end + + # Returns the value of attribute dig_perfect_match_proc. + # + # source://reline//lib/reline/line_editor.rb#15 + def dig_perfect_match_proc; end + + # Sets the attribute dig_perfect_match_proc + # + # @param value the value to set the attribute dig_perfect_match_proc to. + # + # source://reline//lib/reline/line_editor.rb#15 + def dig_perfect_match_proc=(_arg0); end + + # source://reline//lib/reline/line_editor.rb#806 + def editing_mode; end + + # @return [Boolean] + # + # source://reline//lib/reline/line_editor.rb#219 + def eof?; end + + # source://reline//lib/reline/line_editor.rb#215 + def finalize; end + + # source://reline//lib/reline/line_editor.rb#1416 + def finish; end + + # @return [Boolean] + # + # source://reline//lib/reline/line_editor.rb#1412 + def finished?; end + + # source://reline//lib/reline/line_editor.rb#166 + def handle_signal; end + + # source://reline//lib/reline/line_editor.rb#1102 + def input_key(key); end + + # source://reline//lib/reline/line_editor.rb#1340 + def insert_pasted_text(text); end + + # source://reline//lib/reline/line_editor.rb#1352 + def insert_text(text); end + + # source://reline//lib/reline/line_editor.rb#82 + def io_gate; end + + # source://reline//lib/reline/line_editor.rb#1228 + def line; end + + # source://reline//lib/reline/line_editor.rb#352 + def modified_lines; end + + # source://reline//lib/reline/line_editor.rb#274 + def multiline_off; end + + # source://reline//lib/reline/line_editor.rb#270 + def multiline_on; end + + # Sets the attribute output + # + # @param value the value to set the attribute output to. + # + # source://reline//lib/reline/line_editor.rb#16 + def output=(_arg0); end + + # Returns the value of attribute output_modifier_proc. + # + # source://reline//lib/reline/line_editor.rb#12 + def output_modifier_proc; end + + # Sets the attribute output_modifier_proc + # + # @param value the value to set the attribute output_modifier_proc to. + # + # source://reline//lib/reline/line_editor.rb#12 + def output_modifier_proc=(_arg0); end + + # source://reline//lib/reline/line_editor.rb#493 + def print_nomultiline_prompt(prompt); end + + # source://reline//lib/reline/line_editor.rb#358 + def prompt_list; end + + # Returns the value of attribute prompt_proc. + # + # source://reline//lib/reline/line_editor.rb#13 + def prompt_proc; end + + # Sets the attribute prompt_proc + # + # @param value the value to set the attribute prompt_proc to. + # + # source://reline//lib/reline/line_editor.rb#13 + def prompt_proc=(_arg0); end + + # source://reline//lib/reline/line_editor.rb#1152 + def push_input_lines; end + + # source://reline//lib/reline/line_editor.rb#502 + def render_differential; end + + # source://reline//lib/reline/line_editor.rb#462 + def render_finished; end + + # source://reline//lib/reline/line_editor.rb#484 + def render_full_content; end + + # source://reline//lib/reline/line_editor.rb#407 + def render_line_differential(old_items, new_items); end + + # source://reline//lib/reline/line_editor.rb#570 + def rerender; end + + # source://reline//lib/reline/line_editor.rb#139 + def reset(prompt = T.unsafe(nil), encoding:); end + + # source://reline//lib/reline/line_editor.rb#261 + def reset_line; end + + # source://reline//lib/reline/line_editor.rb#223 + def reset_variables(prompt = T.unsafe(nil), encoding:); end + + # source://reline//lib/reline/line_editor.rb#566 + def rest_height(wrapped_cursor_y); end + + # source://reline//lib/reline/line_editor.rb#1259 + def retrieve_completion_block(set_completion_quote_character = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1148 + def save_old_buffer; end + + # source://reline//lib/reline/line_editor.rb#364 + def screen_height; end + + # source://reline//lib/reline/line_editor.rb#372 + def screen_scroll_top; end + + # source://reline//lib/reline/line_editor.rb#368 + def screen_width; end + + # source://reline//lib/reline/line_editor.rb#1171 + def scroll_into_view; end + + # source://reline//lib/reline/line_editor.rb#1236 + def set_current_line(line, byte_pointer = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1247 + def set_current_lines(lines, byte_pointer = T.unsafe(nil), line_index = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#86 + def set_pasting_state(in_pasting); end + + # source://reline//lib/reline/line_editor.rb#206 + def set_signal_handlers; end + + # source://reline//lib/reline/line_editor.rb#1164 + def trim_input_lines; end + + # source://reline//lib/reline/line_editor.rb#1092 + def update(key); end + + # source://reline//lib/reline/line_editor.rb#454 + def update_dialogs(key = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#562 + def upper_space_height(wrapped_cursor_y); end + + # source://reline//lib/reline/line_editor.rb#1404 + def whole_buffer; end + + # source://reline//lib/reline/line_editor.rb#1400 + def whole_lines; end + + # source://reline//lib/reline/line_editor.rb#344 + def with_cache(key, *deps); end + + # source://reline//lib/reline/line_editor.rb#978 + def wrap_method_call(method_symbol, method_obj, key, with_operator = T.unsafe(nil)); end + + # Calculate cursor position in word wrapped content. + # + # source://reline//lib/reline/line_editor.rb#438 + def wrapped_cursor_position; end + + # source://reline//lib/reline/line_editor.rb#376 + def wrapped_prompt_and_input_lines; end + + private + + # @return [Boolean] + # + # source://reline//lib/reline/line_editor.rb#968 + def argumentable?(method_obj); end + + # source://reline//lib/reline/line_editor.rb#1571 + def backward_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1874 + def backward_delete_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2017 + def backward_kill_word(key); end + + # source://reline//lib/reline/line_editor.rb#1999 + def backward_word(key); end + + # source://reline//lib/reline/line_editor.rb#1588 + def beginning_of_line(key); end + + # @return [Boolean] + # + # source://reline//lib/reline/line_editor.rb#1408 + def buffer_empty?; end + + # source://reline//lib/reline/line_editor.rb#1427 + def byteinsert(str, byte_pointer, other); end + + # source://reline//lib/reline/line_editor.rb#1421 + def byteslice!(str, byte_pointer, size); end + + # source://reline//lib/reline/line_editor.rb#309 + def calculate_nearest_cursor(cursor); end + + # source://reline//lib/reline/line_editor.rb#1434 + def calculate_width(str, allow_escape_code = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2057 + def capitalize_word(key); end + + # source://reline//lib/reline/line_editor.rb#93 + def check_mode_string; end + + # source://reline//lib/reline/line_editor.rb#107 + def check_multiline_prompt(buffer, mode_string); end + + # source://reline//lib/reline/line_editor.rb#998 + def cleanup_waiting; end + + # source://reline//lib/reline/line_editor.rb#1982 + def clear_screen(key); end + + # source://reline//lib/reline/line_editor.rb#1454 + def complete(_key); end + + # source://reline//lib/reline/line_editor.rb#814 + def complete_internal_proc(list, is_menu); end + + # source://reline//lib/reline/line_editor.rb#1471 + def completion_journey_move(direction); end + + # source://reline//lib/reline/line_editor.rb#1487 + def completion_journey_up(_key); end + + # source://reline//lib/reline/line_editor.rb#2103 + def copy_for_vi(text); end + + # source://reline//lib/reline/line_editor.rb#1939 + def delete_char(key); end + + # source://reline//lib/reline/line_editor.rb#1954 + def delete_char_or_list(key); end + + # source://reline//lib/reline/line_editor.rb#708 + def dialog_range(dialog, dialog_y); end + + # source://reline//lib/reline/line_editor.rb#2067 + def downcase_word(key); end + + # source://reline//lib/reline/line_editor.rb#2352 + def ed_argument_digit(key); end + + # source://reline//lib/reline/line_editor.rb#1982 + def ed_clear_screen(key); end + + # source://reline//lib/reline/line_editor.rb#2298 + def ed_delete_next_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2214 + def ed_delete_prev_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2017 + def ed_delete_prev_word(key); end + + # Editline:: +ed-insert+ (vi input: almost all; emacs: printable characters) + # In insert mode, insert the input character left of the cursor + # position. In replace mode, overwrite the character at the + # cursor and move the cursor to the right by one character + # position. Accept an argument to do this repeatedly. It is an + # error if the input character is the NUL character (+Ctrl-@+). + # Failure to enlarge the edit buffer also results in an error. + # Editline:: +ed-digit+ (emacs: 0 to 9) If in argument input mode, append + # the input digit to the argument being read. Otherwise, call + # +ed-insert+. It is an error if the input character is not a + # digit or if the existing argument is already greater than a + # million. + # GNU Readline:: +self-insert+ (a, b, A, 1, !, …) Insert yourself. + # + # source://reline//lib/reline/line_editor.rb#1514 + def ed_digit(key); end + + # Editline:: +ed-insert+ (vi input: almost all; emacs: printable characters) + # In insert mode, insert the input character left of the cursor + # position. In replace mode, overwrite the character at the + # cursor and move the cursor to the right by one character + # position. Accept an argument to do this repeatedly. It is an + # error if the input character is the NUL character (+Ctrl-@+). + # Failure to enlarge the edit buffer also results in an error. + # Editline:: +ed-digit+ (emacs: 0 to 9) If in argument input mode, append + # the input digit to the argument being read. Otherwise, call + # +ed-insert+. It is an error if the input character is not a + # digit or if the existing argument is already greater than a + # million. + # GNU Readline:: +self-insert+ (a, b, A, 1, !, …) Insert yourself. + # + # source://reline//lib/reline/line_editor.rb#1514 + def ed_insert(key); end + + # Editline:: +ed-kill-line+ (vi command: +D+, +Ctrl-K+; emacs: +Ctrl-K+, + # +Ctrl-U+) + Kill from the cursor to the end of the line. + # GNU Readline:: +kill-line+ (+C-k+) Kill the text from point to the end of + # the line. With a negative numeric argument, kill backward + # from the cursor to the beginning of the current line. + # + # source://reline//lib/reline/line_editor.rb#1895 + def ed_kill_line(key); end + + # source://reline//lib/reline/line_editor.rb#1588 + def ed_move_to_beg(key); end + + # source://reline//lib/reline/line_editor.rb#1594 + def ed_move_to_end(key); end + + # source://reline//lib/reline/line_editor.rb#1845 + def ed_newline(key); end + + # source://reline//lib/reline/line_editor.rb#1558 + def ed_next_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1828 + def ed_next_history(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1571 + def ed_prev_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1811 + def ed_prev_history(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1999 + def ed_prev_word(key); end + + # source://reline//lib/reline/line_editor.rb#1542 + def ed_quoted_insert(str, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1774 + def ed_search_next_history(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1759 + def ed_search_prev_history(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2027 + def ed_transpose_chars(key); end + + # source://reline//lib/reline/line_editor.rb#2044 + def ed_transpose_words(key); end + + # do nothing + # + # source://reline//lib/reline/line_editor.rb#1493 + def ed_unassigned(key); end + + # source://reline//lib/reline/line_editor.rb#2057 + def em_capitol_case(key); end + + # source://reline//lib/reline/line_editor.rb#1939 + def em_delete(key); end + + # source://reline//lib/reline/line_editor.rb#2007 + def em_delete_next_word(key); end + + # source://reline//lib/reline/line_editor.rb#1954 + def em_delete_or_list(key); end + + # source://reline//lib/reline/line_editor.rb#1874 + def em_delete_prev_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2514 + def em_exchange_mark(key); end + + # Editline:: +em-kill-line+ (not bound) Delete the entire contents of the + # edit buffer and save it to the cut buffer. +vi-kill-line-prev+ + # GNU Readline:: +kill-whole-line+ (not bound) Kill all characters on the + # current line, no matter where point is. + # + # source://reline//lib/reline/line_editor.rb#1931 + def em_kill_line(key); end + + # source://reline//lib/reline/line_editor.rb#2093 + def em_kill_region(key); end + + # source://reline//lib/reline/line_editor.rb#2067 + def em_lower_case(key); end + + # source://reline//lib/reline/line_editor.rb#1991 + def em_next_word(key); end + + # source://reline//lib/reline/line_editor.rb#2509 + def em_set_mark(key); end + + # source://reline//lib/reline/line_editor.rb#2080 + def em_upper_case(key); end + + # source://reline//lib/reline/line_editor.rb#1966 + def em_yank(key); end + + # source://reline//lib/reline/line_editor.rb#1972 + def em_yank_pop(key); end + + # source://reline//lib/reline/line_editor.rb#2522 + def emacs_editing_mode(key); end + + # source://reline//lib/reline/line_editor.rb#1594 + def end_of_line(key); end + + # source://reline//lib/reline/line_editor.rb#2514 + def exchange_point_and_mark(key); end + + # source://reline//lib/reline/line_editor.rb#1558 + def forward_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1744 + def forward_search_history(key); end + + # source://reline//lib/reline/line_editor.rb#1991 + def forward_word(key); end + + # source://reline//lib/reline/line_editor.rb#1599 + def generate_searcher(search_key); end + + # source://reline//lib/reline/line_editor.rb#184 + def handle_interrupted; end + + # source://reline//lib/reline/line_editor.rb#171 + def handle_resized; end + + # source://reline//lib/reline/line_editor.rb#1759 + def history_search_backward(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1774 + def history_search_forward(key, arg: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://reline//lib/reline/line_editor.rb#972 + def inclusive?(method_obj); end + + # source://reline//lib/reline/line_editor.rb#1683 + def incremental_search_history(key); end + + # source://reline//lib/reline/line_editor.rb#278 + def insert_new_line(cursor_line, next_line); end + + # source://reline//lib/reline/line_editor.rb#1438 + def key_delete(key); end + + # source://reline//lib/reline/line_editor.rb#1446 + def key_newline(key); end + + # Editline:: +ed-kill-line+ (vi command: +D+, +Ctrl-K+; emacs: +Ctrl-K+, + # +Ctrl-U+) + Kill from the cursor to the end of the line. + # GNU Readline:: +kill-line+ (+C-k+) Kill the text from point to the end of + # the line. With a negative numeric argument, kill backward + # from the cursor to the beginning of the current line. + # + # source://reline//lib/reline/line_editor.rb#1895 + def kill_line(key); end + + # Editline:: +em-kill-line+ (not bound) Delete the entire contents of the + # edit buffer and save it to the cut buffer. +vi-kill-line-prev+ + # GNU Readline:: +kill-whole-line+ (not bound) Kill all characters on the + # current line, no matter where point is. + # + # source://reline//lib/reline/line_editor.rb#1931 + def kill_whole_line(key); end + + # source://reline//lib/reline/line_editor.rb#2007 + def kill_word(key); end + + # source://reline//lib/reline/line_editor.rb#810 + def menu(_target, list); end + + # source://reline//lib/reline/line_editor.rb#1479 + def menu_complete(_key); end + + # source://reline//lib/reline/line_editor.rb#1483 + def menu_complete_backward(_key); end + + # source://reline//lib/reline/line_editor.rb#798 + def modify_lines(before, complete); end + + # source://reline//lib/reline/line_editor.rb#917 + def move_completed_list(direction); end + + # source://reline//lib/reline/line_editor.rb#1789 + def move_history(history_pointer, line:, cursor:, save_buffer: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1828 + def next_history(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1070 + def normal_char(key); end + + # source://reline//lib/reline/line_editor.rb#860 + def perform_completion(list, just_show_list); end + + # source://reline//lib/reline/line_editor.rb#2550 + def prev_action_state_value(type); end + + # source://reline//lib/reline/line_editor.rb#1811 + def previous_history(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1211 + def process_auto_indent(line_index = T.unsafe(nil), cursor_dependent: T.unsafe(nil), add_newline: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1495 + def process_insert(force: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1006 + def process_key(key, method_symbol); end + + # source://reline//lib/reline/line_editor.rb#1542 + def quoted_insert(str, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2540 + def redo(_key); end + + # source://reline//lib/reline/line_editor.rb#929 + def retrieve_completion_journey_state; end + + # source://reline//lib/reline/line_editor.rb#1739 + def reverse_search_history(key); end + + # source://reline//lib/reline/line_editor.rb#944 + def run_for_operators(key, method_symbol, &block); end + + # source://reline//lib/reline/line_editor.rb#1749 + def search_history(prefix, pointer_range); end + + # source://reline//lib/reline/line_editor.rb#2410 + def search_next_char(key, arg, need_prev_char: T.unsafe(nil), inclusive: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2462 + def search_prev_char(key, arg, need_next_char = T.unsafe(nil)); end + + # Editline:: +ed-insert+ (vi input: almost all; emacs: printable characters) + # In insert mode, insert the input character left of the cursor + # position. In replace mode, overwrite the character at the + # cursor and move the cursor to the right by one character + # position. Accept an argument to do this repeatedly. It is an + # error if the input character is the NUL character (+Ctrl-@+). + # Failure to enlarge the edit buffer also results in an error. + # Editline:: +ed-digit+ (emacs: 0 to 9) If in argument input mode, append + # the input digit to the argument being read. Otherwise, call + # +ed-insert+. It is an error if the input character is not a + # digit or if the existing argument is already greater than a + # million. + # GNU Readline:: +self-insert+ (a, b, A, 1, !, …) Insert yourself. + # + # source://reline//lib/reline/line_editor.rb#1514 + def self_insert(key); end + + # source://reline//lib/reline/line_editor.rb#2509 + def set_mark(key); end + + # source://reline//lib/reline/line_editor.rb#2554 + def set_next_action_state(type, value); end + + # source://reline//lib/reline/line_editor.rb#301 + def split_by_width(str, max_width, offset: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2027 + def transpose_chars(key); end + + # source://reline//lib/reline/line_editor.rb#2044 + def transpose_words(key); end + + # source://reline//lib/reline/line_editor.rb#2530 + def undo(_key); end + + # Editline:: +vi-kill-line-prev+ (vi: +Ctrl-U+) Delete the string from the + # beginning of the edit buffer to the cursor and save it to the + # cut buffer. + # GNU Readline:: +unix-line-discard+ (+C-u+) Kill backward from the cursor + # to the beginning of the current line. + # + # source://reline//lib/reline/line_editor.rb#1918 + def unix_line_discard(key); end + + # source://reline//lib/reline/line_editor.rb#2093 + def unix_word_rubout(key); end + + # source://reline//lib/reline/line_editor.rb#2080 + def upcase_word(key); end + + # source://reline//lib/reline/line_editor.rb#714 + def update_each_dialog(dialog, cursor_column, cursor_row, key = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2113 + def vi_add(key); end + + # source://reline//lib/reline/line_editor.rb#2209 + def vi_add_at_eol(key); end + + # source://reline//lib/reline/line_editor.rb#2228 + def vi_change_meta(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2240 + def vi_change_meta_confirm(byte_pointer_diff); end + + # Editline:: +vi_change_to_eol+ (vi command: +C+) + Kill and change from the cursor to the end of the line. + # + # source://reline//lib/reline/line_editor.rb#1907 + def vi_change_to_eol(key); end + + # source://reline//lib/reline/line_editor.rb#2118 + def vi_command_mode(key); end + + # source://reline//lib/reline/line_editor.rb#2246 + def vi_delete_meta(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2257 + def vi_delete_meta_confirm(byte_pointer_diff); end + + # source://reline//lib/reline/line_editor.rb#2190 + def vi_delete_prev_char(key); end + + # source://reline//lib/reline/line_editor.rb#2526 + def vi_editing_mode(key); end + + # source://reline//lib/reline/line_editor.rb#2175 + def vi_end_big_word(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2287 + def vi_end_of_transmission(key); end + + # source://reline//lib/reline/line_editor.rb#2142 + def vi_end_word(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2287 + def vi_eof_maybe(key); end + + # source://reline//lib/reline/line_editor.rb#1584 + def vi_first_print(key); end + + # source://reline//lib/reline/line_editor.rb#2321 + def vi_histedit(key); end + + # source://reline//lib/reline/line_editor.rb#2109 + def vi_insert(key); end + + # source://reline//lib/reline/line_editor.rb#2204 + def vi_insert_at_bol(key); end + + # source://reline//lib/reline/line_editor.rb#2500 + def vi_join_lines(key, arg: T.unsafe(nil)); end + + # Editline:: +vi-kill-line-prev+ (vi: +Ctrl-U+) Delete the string from the + # beginning of the edit buffer to the cursor and save it to the + # cut buffer. + # GNU Readline:: +unix-line-discard+ (+C-u+) Kill backward from the cursor + # to the beginning of the current line. + # + # source://reline//lib/reline/line_editor.rb#1918 + def vi_kill_line_prev(key); end + + # source://reline//lib/reline/line_editor.rb#2287 + def vi_list_or_eof(key); end + + # source://reline//lib/reline/line_editor.rb#2118 + def vi_movement_mode(key); end + + # source://reline//lib/reline/line_editor.rb#2157 + def vi_next_big_word(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2402 + def vi_next_char(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2124 + def vi_next_word(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2342 + def vi_paste_next(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2333 + def vi_paste_prev(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2166 + def vi_prev_big_word(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2454 + def vi_prev_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2133 + def vi_prev_word(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2378 + def vi_replace_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#1744 + def vi_search_next(key); end + + # source://reline//lib/reline/line_editor.rb#1739 + def vi_search_prev(key); end + + # source://reline//lib/reline/line_editor.rb#2369 + def vi_to_column(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2314 + def vi_to_history_line(key); end + + # source://reline//lib/reline/line_editor.rb#2406 + def vi_to_next_char(key, arg: T.unsafe(nil), inclusive: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2458 + def vi_to_prev_char(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2267 + def vi_yank(key, arg: T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#2278 + def vi_yank_confirm(byte_pointer_diff); end + + # source://reline//lib/reline/line_editor.rb#1588 + def vi_zero(key); end + + # source://reline//lib/reline/line_editor.rb#1966 + def yank(key); end + + # source://reline//lib/reline/line_editor.rb#1972 + def yank_pop(key); end +end + +# source://reline//lib/reline/line_editor.rb#47 +class Reline::LineEditor::CompletionJourneyState < ::Struct + # Returns the value of attribute line_index + # + # @return [Object] the current value of line_index + def line_index; end + + # Sets the attribute line_index + # + # @param value [Object] the value to set the attribute line_index to. + # @return [Object] the newly set value + def line_index=(_); end + + # Returns the value of attribute list + # + # @return [Object] the current value of list + def list; end + + # Sets the attribute list + # + # @param value [Object] the value to set the attribute list to. + # @return [Object] the newly set value + def list=(_); end + + # Returns the value of attribute pointer + # + # @return [Object] the current value of pointer + def pointer; end + + # Sets the attribute pointer + # + # @param value [Object] the value to set the attribute pointer to. + # @return [Object] the newly set value + def pointer=(_); end + + # Returns the value of attribute post + # + # @return [Object] the current value of post + def post; end + + # Sets the attribute post + # + # @param value [Object] the value to set the attribute post to. + # @return [Object] the newly set value + def post=(_); end + + # Returns the value of attribute pre + # + # @return [Object] the current value of pre + def pre; end + + # Sets the attribute pre + # + # @param value [Object] the value to set the attribute pre to. + # @return [Object] the newly set value + def pre=(_); end + + # Returns the value of attribute target + # + # @return [Object] the current value of target + def target; end + + # Sets the attribute target + # + # @param value [Object] the value to set the attribute target to. + # @return [Object] the newly set value + def target=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://reline//lib/reline/line_editor.rb#39 +Reline::LineEditor::CompletionState::COMPLETION = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/line_editor.rb#40 +Reline::LineEditor::CompletionState::MENU = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/line_editor.rb#41 +Reline::LineEditor::CompletionState::MENU_WITH_PERFECT_MATCH = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/line_editor.rb#38 +Reline::LineEditor::CompletionState::NORMAL = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/line_editor.rb#42 +Reline::LineEditor::CompletionState::PERFECT_MATCH = T.let(T.unsafe(nil), Symbol) + +# source://reline//lib/reline/line_editor.rb#706 +Reline::LineEditor::DIALOG_DEFAULT_HEIGHT = T.let(T.unsafe(nil), Integer) + +# source://reline//lib/reline/line_editor.rb#652 +class Reline::LineEditor::Dialog + # @return [Dialog] a new instance of Dialog + # + # source://reline//lib/reline/line_editor.rb#656 + def initialize(name, config, proc_scope); end + + # source://reline//lib/reline/line_editor.rb#680 + def call(key); end + + # Returns the value of attribute column. + # + # source://reline//lib/reline/line_editor.rb#654 + def column; end + + # Sets the attribute column + # + # @param value the value to set the attribute column to. + # + # source://reline//lib/reline/line_editor.rb#654 + def column=(_arg0); end + + # Returns the value of attribute contents. + # + # source://reline//lib/reline/line_editor.rb#653 + def contents; end + + # source://reline//lib/reline/line_editor.rb#673 + def contents=(contents); end + + # Returns the value of attribute name. + # + # source://reline//lib/reline/line_editor.rb#653 + def name; end + + # Returns the value of attribute pointer. + # + # source://reline//lib/reline/line_editor.rb#654 + def pointer; end + + # Sets the attribute pointer + # + # @param value the value to set the attribute pointer to. + # + # source://reline//lib/reline/line_editor.rb#654 + def pointer=(_arg0); end + + # Returns the value of attribute scroll_top. + # + # source://reline//lib/reline/line_editor.rb#654 + def scroll_top; end + + # Sets the attribute scroll_top + # + # @param value the value to set the attribute scroll_top to. + # + # source://reline//lib/reline/line_editor.rb#654 + def scroll_top=(_arg0); end + + # source://reline//lib/reline/line_editor.rb#665 + def set_cursor_pos(col, row); end + + # Returns the value of attribute trap_key. + # + # source://reline//lib/reline/line_editor.rb#654 + def trap_key; end + + # Sets the attribute trap_key + # + # @param value the value to set the attribute trap_key to. + # + # source://reline//lib/reline/line_editor.rb#654 + def trap_key=(_arg0); end + + # Returns the value of attribute vertical_offset. + # + # source://reline//lib/reline/line_editor.rb#654 + def vertical_offset; end + + # Sets the attribute vertical_offset + # + # @param value the value to set the attribute vertical_offset to. + # + # source://reline//lib/reline/line_editor.rb#654 + def vertical_offset=(_arg0); end + + # Returns the value of attribute width. + # + # source://reline//lib/reline/line_editor.rb#653 + def width; end + + # source://reline//lib/reline/line_editor.rb#669 + def width=(v); end +end + +# source://reline//lib/reline/line_editor.rb#574 +class Reline::LineEditor::DialogProcScope + # @return [DialogProcScope] a new instance of DialogProcScope + # + # source://reline//lib/reline/line_editor.rb#577 + def initialize(line_editor, config, proc_to_exec, context); end + + # source://reline//lib/reline/line_editor.rb#647 + def call; end + + # source://reline//lib/reline/line_editor.rb#593 + def call_completion_proc_with_checking_args(pre, target, post); end + + # source://reline//lib/reline/line_editor.rb#639 + def completion_journey_data; end + + # source://reline//lib/reline/line_editor.rb#643 + def config; end + + # source://reline//lib/reline/line_editor.rb#585 + def context; end + + # source://reline//lib/reline/line_editor.rb#618 + def cursor_pos; end + + # source://reline//lib/reline/line_editor.rb#601 + def dialog; end + + # source://reline//lib/reline/line_editor.rb#622 + def just_cursor_moving; end + + # source://reline//lib/reline/line_editor.rb#614 + def key; end + + # source://reline//lib/reline/line_editor.rb#634 + def preferred_dialog_height; end + + # source://reline//lib/reline/line_editor.rb#589 + def retrieve_completion_block(set_completion_quote_character = T.unsafe(nil)); end + + # source://reline//lib/reline/line_editor.rb#630 + def screen_height; end + + # source://reline//lib/reline/line_editor.rb#626 + def screen_width; end + + # source://reline//lib/reline/line_editor.rb#605 + def set_cursor_pos(col, row); end + + # source://reline//lib/reline/line_editor.rb#597 + def set_dialog(dialog); end + + # source://reline//lib/reline/line_editor.rb#610 + def set_key(key); end +end + +# source://reline//lib/reline/line_editor.rb#575 +class Reline::LineEditor::DialogProcScope::CompletionJourneyData < ::Struct + # Returns the value of attribute list + # + # @return [Object] the current value of list + def list; end + + # Sets the attribute list + # + # @param value [Object] the value to set the attribute list to. + # @return [Object] the newly set value + def list=(_); end + + # Returns the value of attribute pointer + # + # @return [Object] the current value of pointer + def pointer; end + + # Sets the attribute pointer + # + # @param value [Object] the value to set the attribute pointer to. + # @return [Object] the newly set value + def pointer=(_); end + + # Returns the value of attribute postposing + # + # @return [Object] the current value of postposing + def postposing; end + + # Sets the attribute postposing + # + # @param value [Object] the value to set the attribute postposing to. + # @return [Object] the newly set value + def postposing=(_); end + + # Returns the value of attribute preposing + # + # @return [Object] the current value of preposing + def preposing; end + + # Sets the attribute preposing + # + # @param value [Object] the value to set the attribute preposing to. + # @return [Object] the newly set value + def preposing=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://reline//lib/reline/line_editor.rb#1163 +Reline::LineEditor::MAX_INPUT_LINES = T.let(T.unsafe(nil), Integer) + +# source://reline//lib/reline/line_editor.rb#73 +Reline::LineEditor::MINIMUM_SCROLLBAR_HEIGHT = T.let(T.unsafe(nil), Integer) + +# source://reline//lib/reline/line_editor.rb#50 +class Reline::LineEditor::MenuInfo + # @return [MenuInfo] a new instance of MenuInfo + # + # source://reline//lib/reline/line_editor.rb#53 + def initialize(list); end + + # source://reline//lib/reline/line_editor.rb#57 + def lines(screen_width); end + + # Returns the value of attribute list. + # + # source://reline//lib/reline/line_editor.rb#51 + def list; end +end + +# source://reline//lib/reline/line_editor.rb#48 +Reline::LineEditor::NullActionState = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/line_editor.rb#45 +class Reline::LineEditor::RenderedScreen < ::Struct + # Returns the value of attribute base_y + # + # @return [Object] the current value of base_y + def base_y; end + + # Sets the attribute base_y + # + # @param value [Object] the value to set the attribute base_y to. + # @return [Object] the newly set value + def base_y=(_); end + + # Returns the value of attribute cursor_y + # + # @return [Object] the current value of cursor_y + def cursor_y; end + + # Sets the attribute cursor_y + # + # @param value [Object] the value to set the attribute cursor_y to. + # @return [Object] the newly set value + def cursor_y=(_); end + + # Returns the value of attribute lines + # + # @return [Object] the current value of lines + def lines; end + + # Sets the attribute lines + # + # @param value [Object] the value to set the attribute lines to. + # @return [Object] the newly set value + def lines=(_); end + + class << self + def [](*_arg0); end + def inspect; end + def keyword_init?; end + def members; end + def new(*_arg0); end + end +end + +# source://reline//lib/reline/line_editor.rb#18 +Reline::LineEditor::VI_MOTIONS = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/terminfo.rb#17 +module Reline::Terminfo + extend ::Fiddle + extend ::Fiddle::CParser + extend ::Fiddle::Importer + + class << self + # source://reline//lib/reline/terminfo.rb#37 + def curses_dl; end + + # source://reline//lib/reline/terminfo.rb#22 + def curses_dl_files; end + + # NOTE: This means Fiddle and curses are enabled. + # + # @return [Boolean] + # + # source://reline//lib/reline/terminfo.rb#155 + def enabled?; end + end +end + +# source://reline//lib/reline.rb#17 +Reline::USERNAME_COMPLETION_PROC = T.let(T.unsafe(nil), T.untyped) + +# source://reline//lib/reline/unicode.rb#1 +class Reline::Unicode + class << self + # source://reline//lib/reline/unicode.rb#107 + def calculate_width(str, allow_escape_code = T.unsafe(nil)); end + + # source://reline//lib/reline/unicode.rb#361 + def ed_transpose_words(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#321 + def em_backward_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#341 + def em_big_backward_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#272 + def em_forward_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#292 + def em_forward_word_with_capitalization(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#44 + def escape_for_print(str); end + + # source://reline//lib/reline/unicode.rb#87 + def get_mbchar_width(mbchar); end + + # source://reline//lib/reline/unicode.rb#258 + def get_next_mbchar_size(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#263 + def get_prev_mbchar_size(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#133 + def split_by_width(str, max_width, encoding = T.unsafe(nil), offset: T.unsafe(nil)); end + + # source://reline//lib/reline/unicode.rb#187 + def take_mbchar_range(str, start_col, width, cover_begin: T.unsafe(nil), cover_end: T.unsafe(nil), padding: T.unsafe(nil)); end + + # Take a chunk of a String cut by width with escape sequences. + # + # source://reline//lib/reline/unicode.rb#183 + def take_range(str, start_col, max_width); end + + # source://reline//lib/reline/unicode.rb#650 + def vi_backward_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#512 + def vi_big_backward_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#482 + def vi_big_forward_end_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#462 + def vi_big_forward_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#682 + def vi_first_print(line); end + + # source://reline//lib/reline/unicode.rb#573 + def vi_forward_end_word(line, byte_pointer); end + + # source://reline//lib/reline/unicode.rb#532 + def vi_forward_word(line, byte_pointer, drop_terminate_spaces = T.unsafe(nil)); end + end +end + +# source://reline//lib/reline/unicode.rb#40 +Reline::Unicode::CSI_REGEXP = T.let(T.unsafe(nil), Regexp) + +# Ambiguous +# +# source://reline//lib/reline/unicode/east_asian_width.rb#158 +Reline::Unicode::EastAsianWidth::TYPE_A = T.let(T.unsafe(nil), Regexp) + +# Fullwidth +# +# source://reline//lib/reline/unicode/east_asian_width.rb#6 +Reline::Unicode::EastAsianWidth::TYPE_F = T.let(T.unsafe(nil), Regexp) + +# Halfwidth +# +# source://reline//lib/reline/unicode/east_asian_width.rb#13 +Reline::Unicode::EastAsianWidth::TYPE_H = T.let(T.unsafe(nil), Regexp) + +# Neutral +# +# source://reline//lib/reline/unicode/east_asian_width.rb#341 +Reline::Unicode::EastAsianWidth::TYPE_N = T.let(T.unsafe(nil), Regexp) + +# Narrow +# +# source://reline//lib/reline/unicode/east_asian_width.rb#147 +Reline::Unicode::EastAsianWidth::TYPE_NA = T.let(T.unsafe(nil), Regexp) + +# Wide +# +# source://reline//lib/reline/unicode/east_asian_width.rb#24 +Reline::Unicode::EastAsianWidth::TYPE_W = T.let(T.unsafe(nil), Regexp) + +# C-? C-8 +# +# source://reline//lib/reline/unicode.rb#36 +Reline::Unicode::EscapedChars = T.let(T.unsafe(nil), Array) + +# source://reline//lib/reline/unicode.rb#2 +Reline::Unicode::EscapedPairs = T.let(T.unsafe(nil), Hash) + +# source://reline//lib/reline/unicode.rb#59 +Reline::Unicode::HalfwidthDakutenHandakuten = T.let(T.unsafe(nil), Regexp) + +# source://reline//lib/reline/unicode.rb#61 +Reline::Unicode::MBCharWidthRE = T.let(T.unsafe(nil), Regexp) + +# source://reline//lib/reline/unicode.rb#39 +Reline::Unicode::NON_PRINTING_END = T.let(T.unsafe(nil), String) + +# source://reline//lib/reline/unicode.rb#38 +Reline::Unicode::NON_PRINTING_START = T.let(T.unsafe(nil), String) + +# source://reline//lib/reline/unicode.rb#41 +Reline::Unicode::OSC_REGEXP = T.let(T.unsafe(nil), Regexp) + +# source://reline//lib/reline/unicode.rb#42 +Reline::Unicode::WIDTH_SCANNER = T.let(T.unsafe(nil), Regexp) + +# source://reline//lib/reline/version.rb#2 +Reline::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/remote_lock@1.2.0-402bba89168d8259ced331f0c5a6d75f529c06b7.rbi b/sorbet/rbi/gems/remote_lock@1.2.0-402bba89168d8259ced331f0c5a6d75f529c06b7.rbi index 947cdf6e6..78877575e 100644 --- a/sorbet/rbi/gems/remote_lock@1.2.0-402bba89168d8259ced331f0c5a6d75f529c06b7.rbi +++ b/sorbet/rbi/gems/remote_lock@1.2.0-402bba89168d8259ced331f0c5a6d75f529c06b7.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `remote_lock` gem. # Please instead update this file by running `bin/tapioca gem remote_lock`. + # source://remote_lock//lib/remote_lock.rb#1 class RemoteLock # @return [RemoteLock] a new instance of RemoteLock diff --git a/sorbet/rbi/gems/request_store@1.5.1.rbi b/sorbet/rbi/gems/request_store@1.7.0.rbi similarity index 99% rename from sorbet/rbi/gems/request_store@1.5.1.rbi rename to sorbet/rbi/gems/request_store@1.7.0.rbi index fca8463fd..44024c4bc 100644 --- a/sorbet/rbi/gems/request_store@1.5.1.rbi +++ b/sorbet/rbi/gems/request_store@1.7.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `request_store` gem. # Please instead update this file by running `bin/tapioca gem request_store`. + # A middleware that ensures the RequestStore stays around until # the last part of the body is rendered. This is useful when # using streaming. diff --git a/sorbet/rbi/gems/responders@3.1.0.rbi b/sorbet/rbi/gems/responders@3.1.1.rbi similarity index 68% rename from sorbet/rbi/gems/responders@3.1.0.rbi rename to sorbet/rbi/gems/responders@3.1.1.rbi index bd7909de0..1dc69324e 100644 --- a/sorbet/rbi/gems/responders@3.1.0.rbi +++ b/sorbet/rbi/gems/responders@3.1.1.rbi @@ -4,13 +4,17 @@ # This is an autogenerated file for types exported from the `responders` gem. # Please instead update this file by running `bin/tapioca gem responders`. + # source://responders//lib/responders.rb#6 module ActionController class << self - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#7 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#9 def add_renderer(key, &block); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#12 + # source://actionpack/7.2.0/lib/action_controller/deprecator.rb#6 + def deprecator; end + + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#14 def remove_renderer(key); end end end @@ -18,59 +22,61 @@ end class ActionController::API < ::ActionController::Metal include ::ActionDispatch::Routing::PolymorphicRoutes include ::ActionController::Head + include ::Devise::Controllers::SignInOut + include ::Devise::Controllers::StoreLocation - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _process_action_callbacks; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_process_action_callbacks(&block); end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end # source://responders//lib/action_controller/respond_with.rb#11 @@ -82,19 +88,25 @@ class ActionController::API < ::ActionController::Metal # source://responders//lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end # source://responders//lib/action_controller/respond_with.rb#11 @@ -107,64 +119,64 @@ class ActionController::API < ::ActionController::Metal def responder?; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _process_action_callbacks=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end # source://responders//lib/action_controller/respond_with.rb#11 @@ -176,19 +188,25 @@ class ActionController::API < ::ActionController::Metal # source://responders//lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end # source://responders//lib/action_controller/respond_with.rb#11 @@ -200,198 +218,204 @@ class ActionController::API < ::ActionController::Metal # source://responders//lib/action_controller/respond_with.rb#11 def responder?; end - # source://actionpack/7.0.5/lib/action_controller/api.rb#104 + # source://actionpack/7.2.0/lib/action_controller/api.rb#107 def without_modules(*modules); end end end -# source://actionpack/7.0.5/lib/action_controller/api.rb#112 -ActionController::API::MODULES = T.let(T.unsafe(nil), Array) - class ActionController::Base < ::ActionController::Metal include ::ActionDispatch::Routing::PolymorphicRoutes include ::ActionController::Head include ::AbstractController::Caching::ConfigMethods include ::ActionController::BasicImplicitRender + include ::Devise::Controllers::SignInOut + include ::Devise::Controllers::StoreLocation + extend ::AbstractController::Helpers::Resolution - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 def _process_action_callbacks; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 def _run_process_action_callbacks(&block); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#36 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#38 def alert; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_asset_host_protocol; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_asset_host_protocol=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_protect_from_forgery; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(_arg0); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest; end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest?; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#10 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#12 def flash(*_arg0, **_arg1, &_arg2); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(_arg0); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers=(_arg0); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end # source://responders//lib/action_controller/respond_with.rb#11 @@ -403,46 +427,52 @@ class ActionController::Base < ::ActionController::Metal # source://responders//lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#36 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#38 def notice; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def request_forgery_protection_token; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def request_forgery_protection_token=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(_arg0); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end # source://responders//lib/action_controller/respond_with.rb#11 @@ -454,241 +484,240 @@ class ActionController::Base < ::ActionController::Metal # source://responders//lib/action_controller/respond_with.rb#11 def responder?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def urlsafe_csrf_tokens; end - private - # source://actionview/7.0.5/lib/action_view/layouts.rb#328 + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 def _layout(lookup_context, formats); end - # source://actionpack/7.0.5/lib/action_controller/base.rb#266 + def _layout_from_proc; end + + # source://actionpack/7.2.0/lib/action_controller/base.rb#324 def _protected_ivars; end class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks=(value); end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 def __callbacks?; end - # source://actionpack/7.0.5/lib/action_controller/form_builder.rb#31 + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 def _default_form_builder; end - # source://actionpack/7.0.5/lib/action_controller/form_builder.rb#31 + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 def _default_form_builder=(value); end - # source://actionpack/7.0.5/lib/action_controller/form_builder.rb#31 + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 def _default_form_builder?; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#8 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 def _flash_types; end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#8 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 def _flash_types=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/flash.rb#8 + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 def _flash_types?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#11 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 def _helper_methods?; end - # source://actionpack/7.0.5/lib/abstract_controller/helpers.rb#15 + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#17 def _helpers; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout=(value); end - # source://actionview/7.0.5/lib/action_view/layouts.rb#209 + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 def _layout?; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions; end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions=(value); end - # source://actionview/7.0.5/lib/action_view/layouts.rb#210 + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 def _layout_conditions?; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 def _process_action_callbacks; end - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 def _process_action_callbacks=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers; end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/renderers.rb#31 + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 def _renderers?; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies; end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching.rb#42 + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 def _view_cache_dependencies?; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options; end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/params_wrapper.rb#185 + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 def _wrapper_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def allow_forgery_protection; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def allow_forgery_protection=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def asset_host; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def asset_host=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def assets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def assets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_asset_host_protocol; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_asset_host_protocol=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def default_protect_from_forgery; end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 - def default_protect_from_forgery=(value); end + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def default_static_extension; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def default_static_extension=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options; end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options=(value); end - # source://actionpack/7.0.5/lib/action_dispatch/routing/url_for.rb#95 + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 def default_url_options?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def enable_fragment_cache_logging; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def enable_fragment_cache_logging=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest; end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/etag_with_template_digest.rb#27 + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 def etag_with_template_digest?; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers; end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/conditional_get.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 def etaggers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_origin_check; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_origin_check=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def forgery_protection_strategy; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def forgery_protection_strategy=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys; end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys=(value); end - # source://actionpack/7.0.5/lib/abstract_controller/caching/fragments.rb#23 + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 def fragment_cache_keys?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#63 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 def helpers_path?; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers; end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/helpers.rb#64 + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 def include_all_helpers?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def javascripts_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def javascripts_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def log_warning_on_csrf_failure; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def log_warning_on_csrf_failure=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def logger; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def logger=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal.rb#210 + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 def middleware_stack; end # source://responders//lib/action_controller/respond_with.rb#11 @@ -700,43 +729,49 @@ class ActionController::Base < ::ActionController::Metal # source://responders//lib/action_controller/respond_with.rb#11 def mimes_for_respond_to?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def per_form_csrf_tokens; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def per_form_csrf_tokens=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def perform_caching; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def perform_caching=(value); end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects; end - # source://actionpack/7.0.5/lib/action_controller/metal/redirecting.rb#13 + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 def raise_on_open_redirects=(val); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def relative_url_root; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def relative_url_root=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def request_forgery_protection_token; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def request_forgery_protection_token=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers; end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers=(value); end - # source://activesupport/7.0.5/lib/active_support/rescuable.rb#13 + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 def rescue_handlers?; end # source://responders//lib/action_controller/respond_with.rb#11 @@ -748,29 +783,17 @@ class ActionController::Base < ::ActionController::Metal # source://responders//lib/action_controller/respond_with.rb#11 def responder?; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 def stylesheets_dir; end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#114 + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 def stylesheets_dir=(value); end - # source://activesupport/7.0.5/lib/active_support/configurable.rb#113 - def urlsafe_csrf_tokens; end - - # source://actionpack/7.0.5/lib/action_controller/metal/request_forgery_protection.rb#97 - def urlsafe_csrf_tokens=(urlsafe_csrf_tokens); end - - # source://actionpack/7.0.5/lib/action_controller/base.rb#198 + # source://actionpack/7.2.0/lib/action_controller/base.rb#222 def without_modules(*modules); end end end -# source://actionpack/7.0.5/lib/action_controller/base.rb#206 -ActionController::Base::MODULES = T.let(T.unsafe(nil), Array) - -# source://actionpack/7.0.5/lib/action_controller/base.rb#261 -ActionController::Base::PROTECTED_IVARS = T.let(T.unsafe(nil), Array) - # source://responders//lib/action_controller/respond_with.rb#7 module ActionController::RespondWith extend ::ActiveSupport::Concern diff --git a/sorbet/rbi/gems/reverse_markdown@2.1.1.rbi b/sorbet/rbi/gems/reverse_markdown@2.1.1.rbi index 9f78a3eab..22802d577 100644 --- a/sorbet/rbi/gems/reverse_markdown@2.1.1.rbi +++ b/sorbet/rbi/gems/reverse_markdown@2.1.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `reverse_markdown` gem. # Please instead update this file by running `bin/tapioca gem reverse_markdown`. + # source://reverse_markdown//lib/reverse_markdown/version.rb#1 module ReverseMarkdown class << self diff --git a/sorbet/rbi/gems/rexml@3.2.5.rbi b/sorbet/rbi/gems/rexml@3.3.5.rbi similarity index 90% rename from sorbet/rbi/gems/rexml@3.2.5.rbi rename to sorbet/rbi/gems/rexml@3.3.5.rbi index 32b3deedb..fc7231a0f 100644 --- a/sorbet/rbi/gems/rexml@3.2.5.rbi +++ b/sorbet/rbi/gems/rexml@3.3.5.rbi @@ -1,9 +1,10 @@ -# typed: true +# typed: false # DO NOT EDIT MANUALLY # This is an autogenerated file for types exported from the `rexml` gem. # Please instead update this file by running `bin/tapioca gem rexml`. + # This class needs: # * Documentation # * Work! Not all types of attlists are intelligently parsed, so we just @@ -101,18 +102,18 @@ class REXML::Attribute # # @return [Attribute] a new instance of Attribute # - # source://rexml//lib/rexml/attribute.rb#45 + # source://rexml//lib/rexml/attribute.rb#42 def initialize(first, second = T.unsafe(nil), parent = T.unsafe(nil)); end # Returns true if other is an Attribute and has the same name and value, # false otherwise. # - # source://rexml//lib/rexml/attribute.rb#109 + # source://rexml//lib/rexml/attribute.rb#106 def ==(other); end # Returns a copy of this attribute # - # source://rexml//lib/rexml/attribute.rb#158 + # source://rexml//lib/rexml/attribute.rb#163 def clone; end # source://rexml//lib/rexml/attribute.rb#132 @@ -128,15 +129,15 @@ class REXML::Attribute # # Returns this attribute # - # source://rexml//lib/rexml/attribute.rb#166 + # source://rexml//lib/rexml/attribute.rb#171 def element=(element); end # Creates (and returns) a hash from both the name and value # - # source://rexml//lib/rexml/attribute.rb#114 + # source://rexml//lib/rexml/attribute.rb#111 def hash; end - # source://rexml//lib/rexml/attribute.rb#192 + # source://rexml//lib/rexml/attribute.rb#197 def inspect; end # Returns the namespace URL, if defined, or nil otherwise @@ -161,17 +162,17 @@ class REXML::Attribute # e.add_attribute("a", "b") # e.attribute("a").namespace # => "" # - # source://rexml//lib/rexml/attribute.rb#98 + # source://rexml//lib/rexml/attribute.rb#95 def namespace(arg = T.unsafe(nil)); end - # source://rexml//lib/rexml/attribute.rb#188 + # source://rexml//lib/rexml/attribute.rb#193 def node_type; end # The normalized value of this attribute. That is, the attribute with # entities intact. # - # source://rexml//lib/rexml/attribute.rb#18 - def normalized=(_arg0); end + # source://rexml//lib/rexml/attribute.rb#157 + def normalized=(new_normalized); end # Returns the namespace of the attribute. # @@ -183,14 +184,14 @@ class REXML::Attribute # a = Attribute.new( "x", "y" ) # a.prefix # -> "" # - # source://rexml//lib/rexml/attribute.rb#73 + # source://rexml//lib/rexml/attribute.rb#70 def prefix; end # Removes this Attribute from the tree, and returns true if successful # # This method is usually not called directly. # - # source://rexml//lib/rexml/attribute.rb#179 + # source://rexml//lib/rexml/attribute.rb#184 def remove; end # Returns the attribute value, with entities replaced @@ -205,28 +206,28 @@ class REXML::Attribute # b = Attribute.new( "ns:x", "y" ) # b.to_string # -> "ns:x='y'" # - # source://rexml//lib/rexml/attribute.rb#124 + # source://rexml//lib/rexml/attribute.rb#121 def to_string; end # Returns the UNNORMALIZED value of this attribute. That is, entities # have been expanded to their values # - # source://rexml//lib/rexml/attribute.rb#150 + # source://rexml//lib/rexml/attribute.rb#149 def value; end # Writes this attribute (EG, puts 'key="value"' to the output) # - # source://rexml//lib/rexml/attribute.rb#184 + # source://rexml//lib/rexml/attribute.rb#189 def write(output, indent = T.unsafe(nil)); end - # source://rexml//lib/rexml/attribute.rb#198 + # source://rexml//lib/rexml/attribute.rb#203 def xpath; end end # A class that defines the set of Attributes of an Element and provides # operations for accessing elements in that set. # -# source://rexml//lib/rexml/element.rb#2141 +# source://rexml//lib/rexml/element.rb#2128 class REXML::Attributes < ::Hash # :call-seq: # new(element) @@ -247,7 +248,7 @@ class REXML::Attributes < ::Hash # # @return [Attributes] a new instance of Attributes # - # source://rexml//lib/rexml/element.rb#2160 + # source://rexml//lib/rexml/element.rb#2147 def initialize(element); end # :call-seq: @@ -270,7 +271,7 @@ class REXML::Attributes < ::Hash # attrs.add(REXML::Attribute.new('baz', '3')) # => baz='3' # attrs.include?('baz') # => true # - # source://rexml//lib/rexml/element.rb#2537 + # source://rexml//lib/rexml/element.rb#2524 def <<(attribute); end # :call-seq: @@ -294,7 +295,7 @@ class REXML::Attributes < ::Hash # # Related: get_attribute (returns an \Attribute object). # - # source://rexml//lib/rexml/element.rb#2185 + # source://rexml//lib/rexml/element.rb#2172 def [](name); end # :call-seq: @@ -320,7 +321,7 @@ class REXML::Attributes < ::Hash # attrs['baz:att'] = nil # attrs.include?('baz:att') # => false # - # source://rexml//lib/rexml/element.rb#2369 + # source://rexml//lib/rexml/element.rb#2356 def []=(name, value); end # :call-seq: @@ -343,7 +344,7 @@ class REXML::Attributes < ::Hash # attrs.add(REXML::Attribute.new('baz', '3')) # => baz='3' # attrs.include?('baz') # => true # - # source://rexml//lib/rexml/element.rb#2537 + # source://rexml//lib/rexml/element.rb#2524 def add(attribute); end # :call-seq: @@ -374,7 +375,7 @@ class REXML::Attributes < ::Hash # attrs.delete(attr) # => # => # attrs.delete(attr) # => # => # - # source://rexml//lib/rexml/element.rb#2490 + # source://rexml//lib/rexml/element.rb#2477 def delete(attribute); end # :call-seq: @@ -393,7 +394,7 @@ class REXML::Attributes < ::Hash # attrs = ele.attributes # attrs.delete_all('att') # => [att='<'] # - # source://rexml//lib/rexml/element.rb#2559 + # source://rexml//lib/rexml/element.rb#2546 def delete_all(name); end # :call-seq: @@ -418,7 +419,7 @@ class REXML::Attributes < ::Hash # ["bar:att", "2"] # ["att", "<"] # - # source://rexml//lib/rexml/element.rb#2287 + # source://rexml//lib/rexml/element.rb#2274 def each; end # :call-seq: @@ -443,7 +444,7 @@ class REXML::Attributes < ::Hash # [REXML::Attribute, bar:att='2'] # [REXML::Attribute, att='<'] # - # source://rexml//lib/rexml/element.rb#2254 + # source://rexml//lib/rexml/element.rb#2241 def each_attribute; end # :call-seq: @@ -465,7 +466,7 @@ class REXML::Attributes < ::Hash # attrs.get_attribute('att') # => att='<' # attrs.get_attribute('nosuch') # => nil # - # source://rexml//lib/rexml/element.rb#2313 + # source://rexml//lib/rexml/element.rb#2300 def get_attribute(name); end # :call-seq: @@ -485,7 +486,7 @@ class REXML::Attributes < ::Hash # attrs.get_attribute_ns('http://foo', 'att') # => foo:att='1' # attrs.get_attribute_ns('http://foo', 'nosuch') # => nil # - # source://rexml//lib/rexml/element.rb#2585 + # source://rexml//lib/rexml/element.rb#2572 def get_attribute_ns(namespace, name); end # :call-seq: @@ -502,7 +503,7 @@ class REXML::Attributes < ::Hash # ele = d.root.elements['//ele'] # =>
# ele.attributes.length # => 3 # - # source://rexml//lib/rexml/element.rb#2225 + # source://rexml//lib/rexml/element.rb#2212 def length; end # :call-seq: @@ -514,7 +515,7 @@ class REXML::Attributes < ::Hash # d = REXML::Document.new(xml_string) # d.root.attributes.namespaces # => {"xmlns"=>"foo", "x"=>"bar", "y"=>"twee"} # - # source://rexml//lib/rexml/element.rb#2446 + # source://rexml//lib/rexml/element.rb#2433 def namespaces; end # :call-seq: @@ -528,7 +529,7 @@ class REXML::Attributes < ::Hash # d = REXML::Document.new(xml_string) # d.root.attributes.prefixes # => ["x", "y"] # - # source://rexml//lib/rexml/element.rb#2421 + # source://rexml//lib/rexml/element.rb#2408 def prefixes; end # :call-seq: @@ -545,7 +546,7 @@ class REXML::Attributes < ::Hash # ele = d.root.elements['//ele'] # => # ele.attributes.length # => 3 # - # source://rexml//lib/rexml/element.rb#2225 + # source://rexml//lib/rexml/element.rb#2212 def size; end # :call-seq: @@ -564,7 +565,7 @@ class REXML::Attributes < ::Hash # attrs = ele.attributes.to_a # => [foo:att='1', bar:att='2', att='<'] # attrs.first.class # => REXML::Attribute # - # source://rexml//lib/rexml/element.rb#2207 + # source://rexml//lib/rexml/element.rb#2194 def to_a; end end @@ -978,7 +979,7 @@ class REXML::Document < ::REXML::Element # d.to_s # => "FooBar" # # When argument +document+ is given, it must be an existing - # document object, whose context and attributes (but not chidren) + # document object, whose context and attributes (but not children) # are cloned into the new document: # # d = REXML::Document.new(xml_string) @@ -1577,7 +1578,7 @@ end # #attributes:: Returns the REXML::Attributes object for the element. # #context:: Returns or sets the context hash for the element. # -# source://rexml//lib/rexml/element.rb#279 +# source://rexml//lib/rexml/element.rb#271 class REXML::Element < ::REXML::Parent include ::REXML::XMLTokens include ::REXML::Namespace @@ -1620,7 +1621,7 @@ class REXML::Element < ::REXML::Parent # # @return [Element] a new instance of Element # - # source://rexml//lib/rexml/element.rb#327 + # source://rexml//lib/rexml/element.rb#319 def initialize(arg = T.unsafe(nil), parent = T.unsafe(nil), context = T.unsafe(nil)); end # :call-seq: @@ -1662,7 +1663,7 @@ class REXML::Element < ::REXML::Parent # root[:attr] # => "value" # root[:nosuch] # => nil # - # source://rexml//lib/rexml/element.rb#1245 + # source://rexml//lib/rexml/element.rb#1237 def [](name_or_index); end # :call-seq: @@ -1691,7 +1692,7 @@ class REXML::Element < ::REXML::Parent # e.add_attribute(a) # => attr='VALUE' # e['attr'] # => "VALUE" # - # source://rexml//lib/rexml/element.rb#1349 + # source://rexml//lib/rexml/element.rb#1336 def add_attribute(key, value = T.unsafe(nil)); end # :call-seq: @@ -1717,7 +1718,7 @@ class REXML::Element < ::REXML::Parent # a = [['foo' => 'bar'], ['baz' => 'bat']] # e.add_attributes(a) # - # source://rexml//lib/rexml/element.rb#1380 + # source://rexml//lib/rexml/element.rb#1367 def add_attributes(hash); end # :call-seq: @@ -1754,7 +1755,7 @@ class REXML::Element < ::REXML::Parent # e0.add_element(e1, {'bat' => '0', 'bam' => '1'}) # e0[1] # => # - # source://rexml//lib/rexml/element.rb#731 + # source://rexml//lib/rexml/element.rb#723 def add_element(element, attrs = T.unsafe(nil)); end # :call-seq: @@ -1775,7 +1776,7 @@ class REXML::Element < ::REXML::Parent # e.add_namespace('baz', 'bat') # e.namespaces # => {"xmlns"=>"bar", "baz"=>"bat"} # - # source://rexml//lib/rexml/element.rb#654 + # source://rexml//lib/rexml/element.rb#646 def add_namespace(prefix, uri = T.unsafe(nil)); end # :call-seq: @@ -1817,7 +1818,7 @@ class REXML::Element < ::REXML::Parent # a.add_text(REXML::Text.new('baz')) # a.to_a # => ["foo", , "bar", "baz", "baz"] # - # source://rexml//lib/rexml/element.rb#1146 + # source://rexml//lib/rexml/element.rb#1138 def add_text(text); end # :call-seq: @@ -1849,13 +1850,13 @@ class REXML::Element < ::REXML::Parent # document.root.attribute("x") # => x='x' # document.root.attribute("x", "a") # => a:x='a:x' # - # source://rexml//lib/rexml/element.rb#1286 + # source://rexml//lib/rexml/element.rb#1278 def attribute(name, namespace = T.unsafe(nil)); end # Mechanisms for accessing attributes and child elements of this # element. # - # source://rexml//lib/rexml/element.rb#286 + # source://rexml//lib/rexml/element.rb#278 def attributes; end # :call-seq: @@ -1874,7 +1875,7 @@ class REXML::Element < ::REXML::Parent # cds.frozen? # => true # cds.map {|cd| cd.class } # => [REXML::CData, REXML::CData] # - # source://rexml//lib/rexml/element.rb#1424 + # source://rexml//lib/rexml/element.rb#1411 def cdatas; end # :call-seq: @@ -1887,7 +1888,7 @@ class REXML::Element < ::REXML::Parent # e.add_attributes({'bar' => 0, 'baz' => 1}) # e.clone # => # - # source://rexml//lib/rexml/element.rb#391 + # source://rexml//lib/rexml/element.rb#383 def clone; end # :call-seq: @@ -1907,19 +1908,19 @@ class REXML::Element < ::REXML::Parent # cs.map {|c| c.class } # => [REXML::Comment, REXML::Comment] # cs.map {|c| c.to_s } # => ["foo", "bar"] # - # source://rexml//lib/rexml/element.rb#1445 + # source://rexml//lib/rexml/element.rb#1432 def comments; end # The context holds information about the processing environment, such as # whitespace handling. # - # source://rexml//lib/rexml/element.rb#289 + # source://rexml//lib/rexml/element.rb#281 def context; end # The context holds information about the processing environment, such as # whitespace handling. # - # source://rexml//lib/rexml/element.rb#289 + # source://rexml//lib/rexml/element.rb#281 def context=(_arg0); end # :call-seq: @@ -1933,7 +1934,7 @@ class REXML::Element < ::REXML::Parent # e.delete_attribute('bar') # => # e.delete_attribute('bar') # => nil # - # source://rexml//lib/rexml/element.rb#1399 + # source://rexml//lib/rexml/element.rb#1386 def delete_attribute(key); end # :call-seq: @@ -1973,7 +1974,7 @@ class REXML::Element < ::REXML::Parent # a.delete_element('//c') # => # a.delete_element('//c') # => nil # - # source://rexml//lib/rexml/element.rb#777 + # source://rexml//lib/rexml/element.rb#769 def delete_element(element); end # :call-seq: @@ -1998,7 +1999,7 @@ class REXML::Element < ::REXML::Parent # d.root.delete_namespace('nosuch') # d.to_s # => "" # - # source://rexml//lib/rexml/element.rb#686 + # source://rexml//lib/rexml/element.rb#678 def delete_namespace(namespace = T.unsafe(nil)); end # :call-seq: @@ -2022,7 +2023,7 @@ class REXML::Element < ::REXML::Parent # # Related: #root, #root_node. # - # source://rexml//lib/rexml/element.rb#478 + # source://rexml//lib/rexml/element.rb#470 def document; end # :call-seq: @@ -2041,7 +2042,7 @@ class REXML::Element < ::REXML::Parent # ... # # - # source://rexml//lib/rexml/element.rb#929 + # source://rexml//lib/rexml/element.rb#921 def each_element(xpath = T.unsafe(nil), &block); end # :call-seq: @@ -2093,7 +2094,7 @@ class REXML::Element < ::REXML::Parent # # # - # source://rexml//lib/rexml/element.rb#846 + # source://rexml//lib/rexml/element.rb#838 def each_element_with_attribute(key, value = T.unsafe(nil), max = T.unsafe(nil), name = T.unsafe(nil), &block); end # :call-seq: @@ -2143,13 +2144,13 @@ class REXML::Element < ::REXML::Parent # # ... # - # source://rexml//lib/rexml/element.rb#903 + # source://rexml//lib/rexml/element.rb#895 def each_element_with_text(text = T.unsafe(nil), max = T.unsafe(nil), name = T.unsafe(nil), &block); end # Mechanisms for accessing attributes and child elements of this # element. # - # source://rexml//lib/rexml/element.rb#286 + # source://rexml//lib/rexml/element.rb#278 def elements; end # :call-seq: @@ -2167,7 +2168,7 @@ class REXML::Element < ::REXML::Parent # d = REXML::Document.new(xml_string) # d.root.get_elements('//a') # => [ ... , ] # - # source://rexml//lib/rexml/element.rb#948 + # source://rexml//lib/rexml/element.rb#940 def get_elements(xpath); end # :call-seq: @@ -2187,7 +2188,7 @@ class REXML::Element < ::REXML::Parent # # d.root.get_text(1) # => "this is bold!" # - # source://rexml//lib/rexml/element.rb#1052 + # source://rexml//lib/rexml/element.rb#1044 def get_text(path = T.unsafe(nil)); end # :call-seq: @@ -2202,7 +2203,7 @@ class REXML::Element < ::REXML::Parent # # @return [Boolean] # - # source://rexml//lib/rexml/element.rb#1319 + # source://rexml//lib/rexml/element.rb#1306 def has_attributes?; end # :call-seq: @@ -2219,13 +2220,13 @@ class REXML::Element < ::REXML::Parent # # @return [Boolean] # - # source://rexml//lib/rexml/element.rb#793 + # source://rexml//lib/rexml/element.rb#785 def has_elements?; end # :call-seq: # has_text? -> true or false # - # Returns +true if the element has one or more text noded, + # Returns +true+ if the element has one or more text noded, # +false+ otherwise: # # d = REXML::Document.new 'text' @@ -2236,7 +2237,7 @@ class REXML::Element < ::REXML::Parent # # @return [Boolean] # - # source://rexml//lib/rexml/element.rb#1001 + # source://rexml//lib/rexml/element.rb#993 def has_text?; end # :call-seq: @@ -2246,7 +2247,7 @@ class REXML::Element < ::REXML::Parent # # See {Element Context}[../doc/rexml/context_rdoc.html]. # - # source://rexml//lib/rexml/element.rb#516 + # source://rexml//lib/rexml/element.rb#508 def ignore_whitespace_nodes; end # :call-seq: @@ -2270,7 +2271,7 @@ class REXML::Element < ::REXML::Parent # e.add_element(REXML::Element.new('baz')) # e.inspect # => " ... " # - # source://rexml//lib/rexml/element.rb#366 + # source://rexml//lib/rexml/element.rb#358 def inspect; end # :call-seq: @@ -2290,7 +2291,7 @@ class REXML::Element < ::REXML::Parent # is.map {|i| i.class } # => [REXML::Instruction, REXML::Instruction] # is.map {|i| i.to_s } # => ["", ""] # - # source://rexml//lib/rexml/element.rb#1466 + # source://rexml//lib/rexml/element.rb#1453 def instructions; end # :call-seq: @@ -2313,7 +2314,7 @@ class REXML::Element < ::REXML::Parent # b.namespace('y') # => "2" # b.namespace('nosuch') # => nil # - # source://rexml//lib/rexml/element.rb#621 + # source://rexml//lib/rexml/element.rb#613 def namespace(prefix = T.unsafe(nil)); end # :call-seq: @@ -2335,7 +2336,7 @@ class REXML::Element < ::REXML::Parent # d.elements['//b'].namespaces # => {"x"=>"1", "y"=>"2"} # d.elements['//c'].namespaces # => {"x"=>"1", "y"=>"2", "z"=>"3"} # - # source://rexml//lib/rexml/element.rb#594 + # source://rexml//lib/rexml/element.rb#586 def namespaces; end # :call-seq: @@ -2348,7 +2349,7 @@ class REXML::Element < ::REXML::Parent # d.root.elements['b'].next_element #-> # d.root.elements['c'].next_element #-> nil # - # source://rexml//lib/rexml/element.rb#962 + # source://rexml//lib/rexml/element.rb#954 def next_element; end # :call-seq: @@ -2360,7 +2361,7 @@ class REXML::Element < ::REXML::Parent # a = d.root # => # a.node_type # => :element # - # source://rexml//lib/rexml/element.rb#1167 + # source://rexml//lib/rexml/element.rb#1159 def node_type; end # :call-seq: @@ -2382,7 +2383,7 @@ class REXML::Element < ::REXML::Parent # d.elements['//b'].prefixes # => ["x", "y"] # d.elements['//c'].prefixes # => ["x", "y", "z"] # - # source://rexml//lib/rexml/element.rb#568 + # source://rexml//lib/rexml/element.rb#560 def prefixes; end # :call-seq: @@ -2395,7 +2396,7 @@ class REXML::Element < ::REXML::Parent # d.root.elements['c'].previous_element #-> # d.root.elements['b'].previous_element #-> nil # - # source://rexml//lib/rexml/element.rb#978 + # source://rexml//lib/rexml/element.rb#970 def previous_element; end # :call-seq: @@ -2408,7 +2409,7 @@ class REXML::Element < ::REXML::Parent # The evaluation is tested against +expanded_name+, and so is namespace # sensitive. # - # source://rexml//lib/rexml/element.rb#536 + # source://rexml//lib/rexml/element.rb#528 def raw; end # :call-seq: @@ -2428,7 +2429,7 @@ class REXML::Element < ::REXML::Parent # # Related: #root_node, #document. # - # source://rexml//lib/rexml/element.rb#451 + # source://rexml//lib/rexml/element.rb#443 def root; end # :call-seq: @@ -2466,14 +2467,14 @@ class REXML::Element < ::REXML::Parent # # Related: #root, #document. # - # source://rexml//lib/rexml/element.rb#430 + # source://rexml//lib/rexml/element.rb#422 def root_node; end # :call-seq: # text(xpath = nil) -> text_string or nil # # Returns the text string from the first text node child - # in a specified element, if it exists, # +nil+ otherwise. + # in a specified element, if it exists, +nil+ otherwise. # # With no argument, returns the text from the first text node in +self+: # @@ -2481,7 +2482,7 @@ class REXML::Element < ::REXML::Parent # d.root.text.class # => String # d.root.text # => "some text " # - # With argument +xpath+, returns text from the the first text node + # With argument +xpath+, returns text from the first text node # in the element that matches +xpath+: # # d.root.text(1) # => "this is bold!" @@ -2493,7 +2494,7 @@ class REXML::Element < ::REXML::Parent # Note also that the text note is retrieved by method get_text, # and so is always normalized text. # - # source://rexml//lib/rexml/element.rb#1029 + # source://rexml//lib/rexml/element.rb#1021 def text(path = T.unsafe(nil)); end # :call-seq: @@ -2521,7 +2522,7 @@ class REXML::Element < ::REXML::Parent # # d.root.text = nil #-> '' # - # source://rexml//lib/rexml/element.rb#1088 + # source://rexml//lib/rexml/element.rb#1080 def text=(text); end # :call-seq: @@ -2536,7 +2537,7 @@ class REXML::Element < ::REXML::Parent # ts.map {|t| t.class } # => [REXML::Text, REXML::Text] # ts.map {|t| t.to_s } # => ["text", "more"] # - # source://rexml//lib/rexml/element.rb#1482 + # source://rexml//lib/rexml/element.rb#1469 def texts; end # :call-seq: @@ -2550,7 +2551,7 @@ class REXML::Element < ::REXML::Parent # The evaluation is tested against the element's +expanded_name+, # and so is namespace-sensitive. # - # source://rexml//lib/rexml/element.rb#493 + # source://rexml//lib/rexml/element.rb#485 def whitespace; end # == DEPRECATED @@ -2576,7 +2577,7 @@ class REXML::Element < ::REXML::Parent # doc.write( out ) #-> doc is written to the string 'out' # doc.write( $stdout ) #-> doc written to the console # - # source://rexml//lib/rexml/element.rb#1508 + # source://rexml//lib/rexml/element.rb#1495 def write(output = T.unsafe(nil), indent = T.unsafe(nil), transitive = T.unsafe(nil), ie_hack = T.unsafe(nil)); end # :call-seq: @@ -2599,17 +2600,17 @@ class REXML::Element < ::REXML::Parent # e = REXML::Element.new('foo') # e.xpath # => "foo" # - # source://rexml//lib/rexml/element.rb#1191 + # source://rexml//lib/rexml/element.rb#1183 def xpath; end private - # source://rexml//lib/rexml/element.rb#1525 + # source://rexml//lib/rexml/element.rb#1512 def __to_xpath_helper(node); end # A private helper method # - # source://rexml//lib/rexml/element.rb#1540 + # source://rexml//lib/rexml/element.rb#1527 def each_with_something(test, max = T.unsafe(nil), name = T.unsafe(nil)); end end @@ -2663,7 +2664,7 @@ end # elements = d.root.elements # elements # => # ... > # -# source://rexml//lib/rexml/element.rb#1595 +# source://rexml//lib/rexml/element.rb#1582 class REXML::Elements include ::Enumerable @@ -2680,7 +2681,7 @@ class REXML::Elements # # @return [Elements] a new instance of Elements # - # source://rexml//lib/rexml/element.rb#1608 + # source://rexml//lib/rexml/element.rb#1595 def initialize(parent); end # :call-seq: @@ -2745,7 +2746,7 @@ class REXML::Elements # element.parent # => ... # element.context # => {:raw=>:all} # - # source://rexml//lib/rexml/element.rb#1925 + # source://rexml//lib/rexml/element.rb#1912 def <<(element = T.unsafe(nil)); end # :call-seq: @@ -2801,7 +2802,7 @@ class REXML::Elements # eles[4, 'book'] # => ... # eles[5, 'book'] # => nil # - # source://rexml//lib/rexml/element.rb#1680 + # source://rexml//lib/rexml/element.rb#1667 def [](index, name = T.unsafe(nil)); end # :call-seq: @@ -2840,7 +2841,7 @@ class REXML::Elements # eles[50] = REXML::Text.new('bar') # => "bar" # eles.size # => 5 # - # source://rexml//lib/rexml/element.rb#1735 + # source://rexml//lib/rexml/element.rb#1722 def []=(index, element); end # :call-seq: @@ -2905,7 +2906,7 @@ class REXML::Elements # element.parent # => ... # element.context # => {:raw=>:all} # - # source://rexml//lib/rexml/element.rb#1925 + # source://rexml//lib/rexml/element.rb#1912 def add(element = T.unsafe(nil)); end # :call-seq: @@ -2925,7 +2926,7 @@ class REXML::Elements # xpath = '//book [@category="web"]' # elements.collect(xpath) {|element| element.size } # => [17, 9] # - # source://rexml//lib/rexml/element.rb#1988 + # source://rexml//lib/rexml/element.rb#1975 def collect(xpath = T.unsafe(nil)); end # :call-seq: @@ -2969,7 +2970,7 @@ class REXML::Elements # elements.delete('//book [@category="children"]') # => ... # elements.delete('//nosuch') # => nil # - # source://rexml//lib/rexml/element.rb#1825 + # source://rexml//lib/rexml/element.rb#1812 def delete(element); end # :call-seq: @@ -2989,7 +2990,7 @@ class REXML::Elements # elements.size # => 0 # elements.delete_all('//book') # => [] # - # source://rexml//lib/rexml/element.rb#1851 + # source://rexml//lib/rexml/element.rb#1838 def delete_all(xpath); end # :call-seq: @@ -3020,7 +3021,7 @@ class REXML::Elements # ... # ... # - # source://rexml//lib/rexml/element.rb#1967 + # source://rexml//lib/rexml/element.rb#1954 def each(xpath = T.unsafe(nil)); end # :call-seq: @@ -3035,7 +3036,7 @@ class REXML::Elements # # @return [Boolean] # - # source://rexml//lib/rexml/element.rb#1755 + # source://rexml//lib/rexml/element.rb#1742 def empty?; end # :call-seq: @@ -3052,7 +3053,7 @@ class REXML::Elements # elements.index(ele_4) # => 3 # elements.index(ele_3) # => -1 # - # source://rexml//lib/rexml/element.rb#1773 + # source://rexml//lib/rexml/element.rb#1760 def index(element); end # :call-seq: @@ -3132,7 +3133,7 @@ class REXML::Elements # total += element.size # end # => 26 # - # source://rexml//lib/rexml/element.rb#2073 + # source://rexml//lib/rexml/element.rb#2060 def inject(xpath = T.unsafe(nil), initial = T.unsafe(nil)); end # :call-seq: @@ -3146,7 +3147,7 @@ class REXML::Elements # elements = REXML::Elements.new(d.root) # elements.parent == d.root # => true # - # source://rexml//lib/rexml/element.rb#1623 + # source://rexml//lib/rexml/element.rb#1610 def parent; end # :call-seq: @@ -3158,7 +3159,7 @@ class REXML::Elements # d.root.elements.size # => 3 # Three elements. # d.root.size # => 6 # Three elements plus three text nodes.. # - # source://rexml//lib/rexml/element.rb#2097 + # source://rexml//lib/rexml/element.rb#2084 def size; end # :call-seq: @@ -3179,14 +3180,14 @@ class REXML::Elements # # elements.to_a('//c') # => [] # - # source://rexml//lib/rexml/element.rb#2121 + # source://rexml//lib/rexml/element.rb#2108 def to_a(xpath = T.unsafe(nil)); end private # Private helper class. Removes quotes from quoted strings # - # source://rexml//lib/rexml/element.rb#2129 + # source://rexml//lib/rexml/element.rb#2116 def literalize(name); end end @@ -3252,6 +3253,9 @@ class REXML::Entity < ::REXML::Child # source://rexml//lib/rexml/entity.rb#85 def normalized; end + # source://rexml//lib/rexml/entity.rb#138 + def parent=(other); end + # Returns the value of attribute pubid. # # source://rexml//lib/rexml/entity.rb#22 @@ -3298,6 +3302,11 @@ class REXML::Entity < ::REXML::Child # source://rexml//lib/rexml/entity.rb#97 def write(out, indent = T.unsafe(nil)); end + private + + # source://rexml//lib/rexml/entity.rb#144 + def resolve_value; end + class << self # Evaluates whether the given string matches an entity definition, # returning true if so, and false otherwise. @@ -3445,47 +3454,44 @@ end # A Source that wraps an IO. See the Source class for method # documentation # -# source://rexml//lib/rexml/source.rb#159 +# source://rexml//lib/rexml/source.rb#182 class REXML::IOSource < ::REXML::Source # block_size has been deprecated # # @return [IOSource] a new instance of IOSource # - # source://rexml//lib/rexml/source.rb#163 + # source://rexml//lib/rexml/source.rb#186 def initialize(arg, block_size = T.unsafe(nil), encoding = T.unsafe(nil)); end - # source://rexml//lib/rexml/source.rb#215 - def consume(pattern); end - # @return the current line in the source # - # source://rexml//lib/rexml/source.rb#244 + # source://rexml//lib/rexml/source.rb#274 def current_line; end # @return [Boolean] # - # source://rexml//lib/rexml/source.rb#235 + # source://rexml//lib/rexml/source.rb#269 def empty?; end - # source://rexml//lib/rexml/source.rb#219 - def match(pattern, cons = T.unsafe(nil)); end + # source://rexml//lib/rexml/source.rb#246 + def ensure_buffer; end - # source://rexml//lib/rexml/source.rb#239 - def position; end + # source://rexml//lib/rexml/source.rb#250 + def match(pattern, cons = T.unsafe(nil)); end # source://rexml//lib/rexml/source.rb#207 - def read; end + def read(term = T.unsafe(nil), min_bytes = T.unsafe(nil)); end - # source://rexml//lib/rexml/source.rb#184 - def scan(pattern, cons = T.unsafe(nil)); end + # source://rexml//lib/rexml/source.rb#228 + def read_until(term); end private - # source://rexml//lib/rexml/source.rb#286 + # source://rexml//lib/rexml/source.rb#316 def encoding_updated; end - # source://rexml//lib/rexml/source.rb#266 - def readline; end + # source://rexml//lib/rexml/source.rb#296 + def readline(term = T.unsafe(nil)); end end # Represents an XML Instruction; IE, @@ -3660,6 +3666,54 @@ REXML::Light::Node::NAMESPLIT = T.let(T.unsafe(nil), Regexp) # source://rexml//lib/rexml/light/node.rb#11 REXML::Light::Node::PARENTS = T.let(T.unsafe(nil), Array) +# Adds named attributes to an object. +# +# source://rexml//lib/rexml/namespace.rb#7 +module REXML::Namespace + include ::REXML::XMLTokens + + # The name of the object, valid if set + # + # source://rexml//lib/rexml/namespace.rb#9 + def expanded_name; end + + # Fully expand the name, even if the prefix wasn't specified in the + # source file. + # + # source://rexml//lib/rexml/namespace.rb#57 + def fully_expanded_name; end + + # Compares names optionally WITH namespaces + # + # @return [Boolean] + # + # source://rexml//lib/rexml/namespace.rb#43 + def has_name?(other, ns = T.unsafe(nil)); end + + # The name of the object, valid if set + # + # source://rexml//lib/rexml/namespace.rb#9 + def name; end + + # Sets the name and the expanded name + # + # source://rexml//lib/rexml/namespace.rb#17 + def name=(name); end + + # The expanded name of the object, valid if name is set + # + # source://rexml//lib/rexml/namespace.rb#11 + def prefix; end + + # The expanded name of the object, valid if name is set + # + # source://rexml//lib/rexml/namespace.rb#11 + def prefix=(_arg0); end +end + +# source://rexml//lib/rexml/namespace.rb#13 +REXML::Namespace::NAME_WITHOUT_NAMESPACE = T.let(T.unsafe(nil), Regexp) + # source://rexml//lib/rexml/doctype.rb#280 class REXML::NotationDecl < ::REXML::Child # @return [NotationDecl] a new instance of NotationDecl @@ -3866,7 +3920,7 @@ class REXML::ParseException < ::RuntimeError # source://rexml//lib/rexml/parseexception.rb#6 def initialize(message, source = T.unsafe(nil), parser = T.unsafe(nil), exception = T.unsafe(nil)); end - # source://rexml//lib/rexml/parseexception.rb#48 + # source://rexml//lib/rexml/parseexception.rb#49 def context; end # Returns the value of attribute continued_exception. @@ -3881,7 +3935,7 @@ class REXML::ParseException < ::RuntimeError # source://rexml//lib/rexml/parseexception.rb#4 def continued_exception=(_arg0); end - # source://rexml//lib/rexml/parseexception.rb#43 + # source://rexml//lib/rexml/parseexception.rb#44 def line; end # Returns the value of attribute parser. @@ -3896,7 +3950,7 @@ class REXML::ParseException < ::RuntimeError # source://rexml//lib/rexml/parseexception.rb#4 def parser=(_arg0); end - # source://rexml//lib/rexml/parseexception.rb#38 + # source://rexml//lib/rexml/parseexception.rb#39 def position; end # Returns the value of attribute source. @@ -3935,36 +3989,41 @@ end # # Nat Price gave me some good ideas for the API. # -# source://rexml//lib/rexml/parsers/baseparser.rb#29 +# source://rexml//lib/rexml/parsers/baseparser.rb#41 class REXML::Parsers::BaseParser # @return [BaseParser] a new instance of BaseParser # - # source://rexml//lib/rexml/parsers/baseparser.rb#115 + # source://rexml//lib/rexml/parsers/baseparser.rb#145 def initialize(source); end - # source://rexml//lib/rexml/parsers/baseparser.rb#120 + # source://rexml//lib/rexml/parsers/baseparser.rb#152 def add_listener(listener); end # Returns true if there are no more events # # @return [Boolean] # - # source://rexml//lib/rexml/parsers/baseparser.rb#146 + # source://rexml//lib/rexml/parsers/baseparser.rb#180 def empty?; end - # source://rexml//lib/rexml/parsers/baseparser.rb#438 + # source://rexml//lib/rexml/parsers/baseparser.rb#507 def entity(reference, entities); end + # Returns the value of attribute entity_expansion_count. + # + # source://rexml//lib/rexml/parsers/baseparser.rb#157 + def entity_expansion_count; end + # Returns true if there are more events. Synonymous with !empty? # # @return [Boolean] # - # source://rexml//lib/rexml/parsers/baseparser.rb#151 + # source://rexml//lib/rexml/parsers/baseparser.rb#185 def has_next?; end # Escapes all possible entities # - # source://rexml//lib/rexml/parsers/baseparser.rb#449 + # source://rexml//lib/rexml/parsers/baseparser.rb#520 def normalize(input, entities = T.unsafe(nil), entity_filter = T.unsafe(nil)); end # Peek at the +depth+ event in the stack. The first element on the stack @@ -3974,75 +4033,111 @@ class REXML::Parsers::BaseParser # event, so you can effectively pre-parse the entire document (pull the # entire thing into memory) using this method. # - # source://rexml//lib/rexml/parsers/baseparser.rb#167 + # source://rexml//lib/rexml/parsers/baseparser.rb#201 def peek(depth = T.unsafe(nil)); end - # source://rexml//lib/rexml/parsers/baseparser.rb#136 + # source://rexml//lib/rexml/parsers/baseparser.rb#170 def position; end # Returns the next event. This is a +PullEvent+ object. # - # source://rexml//lib/rexml/parsers/baseparser.rb#182 + # source://rexml//lib/rexml/parsers/baseparser.rb#216 def pull; end # Returns the value of attribute source. # - # source://rexml//lib/rexml/parsers/baseparser.rb#124 + # source://rexml//lib/rexml/parsers/baseparser.rb#156 def source; end - # source://rexml//lib/rexml/parsers/baseparser.rb#126 + # source://rexml//lib/rexml/parsers/baseparser.rb#159 def stream=(source); end # Unescapes all possible entities # - # source://rexml//lib/rexml/parsers/baseparser.rb#465 + # source://rexml//lib/rexml/parsers/baseparser.rb#536 def unnormalize(string, entities = T.unsafe(nil), filter = T.unsafe(nil)); end # Push an event back on the head of the stream. This method # has (theoretically) infinite depth. # - # source://rexml//lib/rexml/parsers/baseparser.rb#157 + # source://rexml//lib/rexml/parsers/baseparser.rb#191 def unshift(token); end private # @return [Boolean] # - # source://rexml//lib/rexml/parsers/baseparser.rb#495 + # source://rexml//lib/rexml/parsers/baseparser.rb#580 def need_source_encoding_update?(xml_declaration_encoding); end - # source://rexml//lib/rexml/parsers/baseparser.rb#589 + # source://rexml//lib/rexml/parsers/baseparser.rb#700 def parse_attributes(prefixes, curr_ns); end - # source://rexml//lib/rexml/parsers/baseparser.rb#514 + # source://rexml//lib/rexml/parsers/baseparser.rb#599 def parse_id(base_error_message, accept_external_id:, accept_public_id:); end - # source://rexml//lib/rexml/parsers/baseparser.rb#542 + # source://rexml//lib/rexml/parsers/baseparser.rb#627 def parse_id_invalid_details(accept_external_id:, accept_public_id:); end - # source://rexml//lib/rexml/parsers/baseparser.rb#501 + # source://rexml//lib/rexml/parsers/baseparser.rb#586 def parse_name(base_error_message); end - # source://rexml//lib/rexml/parsers/baseparser.rb#580 + # source://rexml//lib/rexml/parsers/baseparser.rb#665 def process_instruction; end - # source://rexml//lib/rexml/parsers/baseparser.rb#190 + # source://rexml//lib/rexml/parsers/baseparser.rb#226 def pull_event; end + + # source://rexml//lib/rexml/parsers/baseparser.rb#573 + def record_entity_expansion; end end -# source://rexml//lib/rexml/parsers/baseparser.rb#102 +# source://rexml//lib/rexml/parsers/baseparser.rb#114 REXML::Parsers::BaseParser::EXTERNAL_ID_PUBLIC = T.let(T.unsafe(nil), Regexp) -# source://rexml//lib/rexml/parsers/baseparser.rb#103 +# source://rexml//lib/rexml/parsers/baseparser.rb#115 REXML::Parsers::BaseParser::EXTERNAL_ID_SYSTEM = T.let(T.unsafe(nil), Regexp) -# source://rexml//lib/rexml/parsers/baseparser.rb#104 +# source://rexml//lib/rexml/parsers/baseparser.rb#116 REXML::Parsers::BaseParser::PUBLIC_ID = T.let(T.unsafe(nil), Regexp) -# source://rexml//lib/rexml/parsers/baseparser.rb#38 +# source://rexml//lib/rexml/parsers/baseparser.rb#127 +module REXML::Parsers::BaseParser::Private; end + +# source://rexml//lib/rexml/parsers/baseparser.rb#130 +REXML::Parsers::BaseParser::Private::ATTLISTDECL_END = T.let(T.unsafe(nil), Regexp) + +# source://rexml//lib/rexml/parsers/baseparser.rb#135 +REXML::Parsers::BaseParser::Private::CARRIAGE_RETURN_NEWLINE_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://rexml//lib/rexml/parsers/baseparser.rb#136 +REXML::Parsers::BaseParser::Private::CHARACTER_REFERENCES = T.let(T.unsafe(nil), Regexp) + +# source://rexml//lib/rexml/parsers/baseparser.rb#129 +REXML::Parsers::BaseParser::Private::CLOSE_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://rexml//lib/rexml/parsers/baseparser.rb#137 +REXML::Parsers::BaseParser::Private::DEFAULT_ENTITIES_PATTERNS = T.let(T.unsafe(nil), Hash) + +# source://rexml//lib/rexml/parsers/baseparser.rb#134 +REXML::Parsers::BaseParser::Private::ENTITYDECL_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://rexml//lib/rexml/parsers/baseparser.rb#132 +REXML::Parsers::BaseParser::Private::GEDECL_PATTERN = T.let(T.unsafe(nil), String) + +# source://rexml//lib/rexml/parsers/baseparser.rb#131 +REXML::Parsers::BaseParser::Private::NAME_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://rexml//lib/rexml/parsers/baseparser.rb#133 +REXML::Parsers::BaseParser::Private::PEDECL_PATTERN = T.let(T.unsafe(nil), String) + +# source://rexml//lib/rexml/parsers/baseparser.rb#128 +REXML::Parsers::BaseParser::Private::TAG_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://rexml//lib/rexml/parsers/baseparser.rb#50 REXML::Parsers::BaseParser::QNAME = T.let(T.unsafe(nil), Regexp) -# source://rexml//lib/rexml/parsers/baseparser.rb#37 +# source://rexml//lib/rexml/parsers/baseparser.rb#49 REXML::Parsers::BaseParser::QNAME_STR = T.let(T.unsafe(nil), String) # source://rexml//lib/rexml/parsers/streamparser.rb#6 @@ -4078,57 +4173,62 @@ end # There is strange, dark magic at work in this code. Beware. Go back! Go # back while you still can! # -# source://rexml//lib/rexml/parsers/xpathparser.rb#11 +# source://rexml//lib/rexml/parsers/xpathparser.rb#12 class REXML::Parsers::XPathParser include ::REXML::XMLTokens - # source://rexml//lib/rexml/parsers/xpathparser.rb#41 - def abbreviate(path); end + # source://rexml//lib/rexml/parsers/xpathparser.rb#42 + def abbreviate(path_or_parsed); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#99 - def expand(path); end + # source://rexml//lib/rexml/parsers/xpathparser.rb#132 + def expand(path_or_parsed); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#15 + # source://rexml//lib/rexml/parsers/xpathparser.rb#16 def namespaces=(namespaces); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#20 + # source://rexml//lib/rexml/parsers/xpathparser.rb#21 def parse(path); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#35 + # For backward compatibility + # + # source://rexml//lib/rexml/parsers/xpathparser.rb#174 + def preciate_to_string(parsed, &block); end + + # source://rexml//lib/rexml/parsers/xpathparser.rb#36 def predicate(path); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#138 - def predicate_to_string(path, &block); end + # source://rexml//lib/rexml/parsers/xpathparser.rb#174 + def predicate_to_path(parsed, &block); end private # | AdditiveExpr ('+' | '-') MultiplicativeExpr # | MultiplicativeExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#455 + # source://rexml//lib/rexml/parsers/xpathparser.rb#505 def AdditiveExpr(path, parsed); end # | AndExpr S 'and' S EqualityExpr # | EqualityExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#388 + # source://rexml//lib/rexml/parsers/xpathparser.rb#438 def AndExpr(path, parsed); end # | EqualityExpr ('=' | '!=') RelationalExpr # | RelationalExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#407 + # source://rexml//lib/rexml/parsers/xpathparser.rb#457 def EqualityExpr(path, parsed); end # | FilterExpr Predicate # | PrimaryExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#558 + # source://rexml//lib/rexml/parsers/xpathparser.rb#608 def FilterExpr(path, parsed); end # | FUNCTION_NAME '(' ( expr ( ',' expr )* )? ')' # - # source://rexml//lib/rexml/parsers/xpathparser.rb#613 + # source://rexml//lib/rexml/parsers/xpathparser.rb#663 def FunctionCall(rest, parsed); end # LocationPath @@ -4136,69 +4236,72 @@ class REXML::Parsers::XPathParser # | '/' RelativeLocationPath? # | '//' RelativeLocationPath # - # source://rexml//lib/rexml/parsers/xpathparser.rb#193 + # source://rexml//lib/rexml/parsers/xpathparser.rb#243 def LocationPath(path, parsed); end # | MultiplicativeExpr ('*' | S ('div' | 'mod') S) UnaryExpr # | UnaryExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#478 + # source://rexml//lib/rexml/parsers/xpathparser.rb#528 def MultiplicativeExpr(path, parsed); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#293 + # source://rexml//lib/rexml/parsers/xpathparser.rb#343 def NodeTest(path, parsed); end # | OrExpr S 'or' S AndExpr # | AndExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#369 + # source://rexml//lib/rexml/parsers/xpathparser.rb#419 def OrExpr(path, parsed); end # | LocationPath # | FilterExpr ('/' | '//') RelativeLocationPath # - # source://rexml//lib/rexml/parsers/xpathparser.rb#540 + # source://rexml//lib/rexml/parsers/xpathparser.rb#590 def PathExpr(path, parsed); end # Filters the supplied nodeset on the predicate(s) # - # source://rexml//lib/rexml/parsers/xpathparser.rb#345 + # source://rexml//lib/rexml/parsers/xpathparser.rb#395 def Predicate(path, parsed); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#576 + # source://rexml//lib/rexml/parsers/xpathparser.rb#626 def PrimaryExpr(path, parsed); end # | RelationalExpr ('<' | '>' | '<=' | '>=') AdditiveExpr # | AdditiveExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#430 + # source://rexml//lib/rexml/parsers/xpathparser.rb#480 def RelationalExpr(path, parsed); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#217 + # source://rexml//lib/rexml/parsers/xpathparser.rb#267 def RelativeLocationPath(path, parsed); end # | '-' UnaryExpr # | UnionExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#503 + # source://rexml//lib/rexml/parsers/xpathparser.rb#553 def UnaryExpr(path, parsed); end # | UnionExpr '|' PathExpr # | PathExpr # - # source://rexml//lib/rexml/parsers/xpathparser.rb#521 + # source://rexml//lib/rexml/parsers/xpathparser.rb#571 def UnionExpr(path, parsed); end # get_group( '[foo]bar' ) -> ['bar', '[foo]'] # - # source://rexml//lib/rexml/parsers/xpathparser.rb#626 + # source://rexml//lib/rexml/parsers/xpathparser.rb#676 def get_group(string); end - # source://rexml//lib/rexml/parsers/xpathparser.rb#644 + # source://rexml//lib/rexml/parsers/xpathparser.rb#694 def parse_args(string); end + + # source://rexml//lib/rexml/parsers/xpathparser.rb#224 + def quote_literal(literal); end end -# source://rexml//lib/rexml/parsers/xpathparser.rb#289 +# source://rexml//lib/rexml/parsers/xpathparser.rb#339 REXML::Parsers::XPathParser::LOCAL_NAME_WILDCARD = T.let(T.unsafe(nil), Regexp) # Returns a 1-1 map of the nodeset @@ -4212,7 +4315,7 @@ REXML::Parsers::XPathParser::LOCAL_NAME_WILDCARD = T.let(T.unsafe(nil), Regexp) # | PI '(' LITERAL ')' PI # | '[' expr ']' Predicate # -# source://rexml//lib/rexml/parsers/xpathparser.rb#288 +# source://rexml//lib/rexml/parsers/xpathparser.rb#338 REXML::Parsers::XPathParser::PREFIX_WILDCARD = T.let(T.unsafe(nil), Regexp) # source://rexml//lib/rexml/doctype.rb#10 @@ -4229,7 +4332,7 @@ end # A Source can be searched for patterns, and wraps buffers and other # objects and provides consumption of text # -# source://rexml//lib/rexml/source.rb#31 +# source://rexml//lib/rexml/source.rb#51 class REXML::Source include ::REXML::Encoding @@ -4240,88 +4343,82 @@ class REXML::Source # @param encoding if non-null, sets the encoding of the source to this # @return [Source] a new instance of Source # - # source://rexml//lib/rexml/source.rb#43 + # source://rexml//lib/rexml/source.rb#71 def initialize(arg, encoding = T.unsafe(nil)); end # The current buffer (what we're going to read next) # - # source://rexml//lib/rexml/source.rb#34 + # source://rexml//lib/rexml/source.rb#83 def buffer; end - # source://rexml//lib/rexml/source.rb#87 - def consume(pattern); end + # source://rexml//lib/rexml/source.rb#93 + def buffer_encoding=(encoding); end # @return the current line in the source # - # source://rexml//lib/rexml/source.rb#117 + # source://rexml//lib/rexml/source.rb#142 def current_line; end + # source://rexml//lib/rexml/source.rb#87 + def drop_parsed_content; end + # @return [Boolean] true if the Source is exhausted # - # source://rexml//lib/rexml/source.rb#108 + # source://rexml//lib/rexml/source.rb#137 def empty?; end # Returns the value of attribute encoding. # - # source://rexml//lib/rexml/source.rb#37 + # source://rexml//lib/rexml/source.rb#55 def encoding; end # Inherited from Encoding # Overridden to support optimized en/decoding # - # source://rexml//lib/rexml/source.rb#56 + # source://rexml//lib/rexml/source.rb#99 def encoding=(enc); end + # source://rexml//lib/rexml/source.rb#117 + def ensure_buffer; end + # The line number of the last consumed text # - # source://rexml//lib/rexml/source.rb#36 + # source://rexml//lib/rexml/source.rb#54 def line; end - # source://rexml//lib/rexml/source.rb#101 + # source://rexml//lib/rexml/source.rb#120 def match(pattern, cons = T.unsafe(nil)); end - # source://rexml//lib/rexml/source.rb#91 - def match_to(char, pattern); end + # source://rexml//lib/rexml/source.rb#128 + def position; end - # source://rexml//lib/rexml/source.rb#95 - def match_to_consume(char, pattern); end + # source://rexml//lib/rexml/source.rb#132 + def position=(pos); end - # source://rexml//lib/rexml/source.rb#112 - def position; end + # source://rexml//lib/rexml/source.rb#104 + def read(term = T.unsafe(nil)); end - # source://rexml//lib/rexml/source.rb#84 - def read; end - - # Scans the source for a given pattern. Note, that this is not your - # usual scan() method. For one thing, the pattern argument has some - # requirements; for another, the source can be consumed. You can easily - # confuse this method. Originally, the patterns were easier - # to construct and this method more robust, because this method - # generated search regexps on the fly; however, this was - # computationally expensive and slowed down the entire REXML package - # considerably, since this is by far the most commonly called method. - # /^\s*(#{your pattern, with no groups})(.*)/. The first group - # will be returned; the second group is used if the consume flag is - # set. - # everything after it in the Source. - # pattern is not found. - # - # @param pattern must be a Regexp, and must be in the form of - # @param consume if true, the pattern returned will be consumed, leaving - # @return the pattern, if found, or nil if the Source is empty or the - # - # source://rexml//lib/rexml/source.rb#77 - def scan(pattern, cons = T.unsafe(nil)); end + # source://rexml//lib/rexml/source.rb#107 + def read_until(term); end private - # source://rexml//lib/rexml/source.rb#125 + # source://rexml//lib/rexml/source.rb#151 def detect_encoding; end - # source://rexml//lib/rexml/source.rb#146 + # source://rexml//lib/rexml/source.rb#169 def encoding_updated; end end +# source://rexml//lib/rexml/source.rb#57 +module REXML::Source::Private; end + +# source://rexml//lib/rexml/source.rb#59 +REXML::Source::Private::PRE_DEFINED_TERM_PATTERNS = T.let(T.unsafe(nil), Hash) + +# source://rexml//lib/rexml/source.rb#58 +REXML::Source::Private::SCANNER_RESET_SIZE = T.let(T.unsafe(nil), Integer) + # Represents text nodes in an XML document # # source://rexml//lib/rexml/text.rb#11 @@ -4376,33 +4473,33 @@ class REXML::Text < ::REXML::Child # +returns+ the text itself to enable method chain like # 'text << "XXX" << "YYY"'. # - # source://rexml//lib/rexml/text.rb#194 + # source://rexml//lib/rexml/text.rb#214 def <<(to_append); end # +other+ a String or a Text # +returns+ the result of (to_s <=> arg.to_s) # - # source://rexml//lib/rexml/text.rb#203 + # source://rexml//lib/rexml/text.rb#223 def <=>(other); end - # source://rexml//lib/rexml/text.rb#184 + # source://rexml//lib/rexml/text.rb#204 def clone; end - # source://rexml//lib/rexml/text.rb#207 + # source://rexml//lib/rexml/text.rb#227 def doctype; end # @return [Boolean] # - # source://rexml//lib/rexml/text.rb#179 + # source://rexml//lib/rexml/text.rb#199 def empty?; end - # source://rexml//lib/rexml/text.rb#278 + # source://rexml//lib/rexml/text.rb#298 def indent_text(string, level = T.unsafe(nil), style = T.unsafe(nil), indentfirstline = T.unsafe(nil)); end - # source://rexml//lib/rexml/text.rb#233 + # source://rexml//lib/rexml/text.rb#253 def inspect; end - # source://rexml//lib/rexml/text.rb#175 + # source://rexml//lib/rexml/text.rb#195 def node_type; end # source://rexml//lib/rexml/text.rb#125 @@ -4432,7 +4529,7 @@ class REXML::Text < ::REXML::Child # u = Text.new( "sean russell", false, nil, true ) # u.to_s #-> "sean russell" # - # source://rexml//lib/rexml/text.rb#228 + # source://rexml//lib/rexml/text.rb#248 def to_s; end # Returns the string value of this text. This is the text without @@ -4449,7 +4546,7 @@ class REXML::Text < ::REXML::Child # u = Text.new( "sean russell", false, nil, true ) # u.value #-> "sean russell" # - # source://rexml//lib/rexml/text.rb#250 + # source://rexml//lib/rexml/text.rb#270 def value; end # Sets the contents of this text node. This expects the text to be @@ -4460,16 +4557,16 @@ class REXML::Text < ::REXML::Child # e[0].value = "bar" # bar # e[0].value = "" # <a> # - # source://rexml//lib/rexml/text.rb#261 + # source://rexml//lib/rexml/text.rb#281 def value=(val); end - # source://rexml//lib/rexml/text.rb#267 + # source://rexml//lib/rexml/text.rb#287 def wrap(string, width, addnewline = T.unsafe(nil)); end # == DEPRECATED # See REXML::Formatters # - # source://rexml//lib/rexml/text.rb#293 + # source://rexml//lib/rexml/text.rb#313 def write(writer, indent = T.unsafe(nil), transitive = T.unsafe(nil), ie_hack = T.unsafe(nil)); end # Writes out text, substituting special characters beforehand. @@ -4487,18 +4584,18 @@ class REXML::Text < ::REXML::Child # } # puts ascOut # - # source://rexml//lib/rexml/text.rb#325 + # source://rexml//lib/rexml/text.rb#345 def write_with_substitution(out, input); end # FIXME # This probably won't work properly # - # source://rexml//lib/rexml/text.rb#305 + # source://rexml//lib/rexml/text.rb#325 def xpath; end private - # source://rexml//lib/rexml/text.rb#338 + # source://rexml//lib/rexml/text.rb#358 def clear_cache; end class << self @@ -4507,22 +4604,22 @@ class REXML::Text < ::REXML::Child # source://rexml//lib/rexml/text.rb#131 def check(string, pattern, doctype); end - # source://rexml//lib/rexml/text.rb#405 + # source://rexml//lib/rexml/text.rb#427 def expand(ref, doctype, filter); end # Escapes all possible entities # - # source://rexml//lib/rexml/text.rb#370 + # source://rexml//lib/rexml/text.rb#390 def normalize(input, doctype = T.unsafe(nil), entity_filter = T.unsafe(nil)); end # Reads text, substituting entities # - # source://rexml//lib/rexml/text.rb#344 + # source://rexml//lib/rexml/text.rb#364 def read_with_substitution(input, illegal = T.unsafe(nil)); end # Unescapes all possible entities # - # source://rexml//lib/rexml/text.rb#392 + # source://rexml//lib/rexml/text.rb#414 def unnormalize(string, doctype = T.unsafe(nil), filter = T.unsafe(nil), illegal = T.unsafe(nil)); end end end @@ -4649,24 +4746,24 @@ end # @private # -# source://rexml//lib/rexml/xpath_parser.rb#959 +# source://rexml//lib/rexml/xpath_parser.rb#963 class REXML::XPathNode # @return [XPathNode] a new instance of XPathNode # - # source://rexml//lib/rexml/xpath_parser.rb#961 + # source://rexml//lib/rexml/xpath_parser.rb#965 def initialize(node, context = T.unsafe(nil)); end # Returns the value of attribute context. # - # source://rexml//lib/rexml/xpath_parser.rb#960 + # source://rexml//lib/rexml/xpath_parser.rb#964 def context; end - # source://rexml//lib/rexml/xpath_parser.rb#970 + # source://rexml//lib/rexml/xpath_parser.rb#974 def position; end # Returns the value of attribute raw_node. # - # source://rexml//lib/rexml/xpath_parser.rb#960 + # source://rexml//lib/rexml/xpath_parser.rb#964 def raw_node; end end @@ -4715,25 +4812,25 @@ class REXML::XPathParser private - # source://rexml//lib/rexml/xpath_parser.rb#775 + # source://rexml//lib/rexml/xpath_parser.rb#779 def child(nodeset); end - # source://rexml//lib/rexml/xpath_parser.rb#916 + # source://rexml//lib/rexml/xpath_parser.rb#920 def compare(a, operator, b); end - # source://rexml//lib/rexml/xpath_parser.rb#678 + # source://rexml//lib/rexml/xpath_parser.rb#682 def descendant(nodeset, include_self); end - # source://rexml//lib/rexml/xpath_parser.rb#689 + # source://rexml//lib/rexml/xpath_parser.rb#693 def descendant_recursive(raw_node, new_nodeset, new_nodes, include_self); end - # source://rexml//lib/rexml/xpath_parser.rb#938 + # source://rexml//lib/rexml/xpath_parser.rb#942 def each_unnode(nodeset); end - # source://rexml//lib/rexml/xpath_parser.rb#637 + # source://rexml//lib/rexml/xpath_parser.rb#641 def enter(tag, *args); end - # source://rexml//lib/rexml/xpath_parser.rb#815 + # source://rexml//lib/rexml/xpath_parser.rb#819 def equality_relational_compare(set1, op, set2); end # source://rexml//lib/rexml/xpath_parser.rb#591 @@ -4748,10 +4845,10 @@ class REXML::XPathParser # source://rexml//lib/rexml/xpath_parser.rb#582 def filter_nodeset(nodeset); end - # source://rexml//lib/rexml/xpath_parser.rb#745 + # source://rexml//lib/rexml/xpath_parser.rb#749 def following(node); end - # source://rexml//lib/rexml/xpath_parser.rb#756 + # source://rexml//lib/rexml/xpath_parser.rb#760 def following_node_of(node); end # Returns a String namespace for a node, given a prefix @@ -4763,19 +4860,19 @@ class REXML::XPathParser # source://rexml//lib/rexml/xpath_parser.rb#163 def get_namespace(node, prefix); end - # source://rexml//lib/rexml/xpath_parser.rb#642 + # source://rexml//lib/rexml/xpath_parser.rb#646 def leave(tag, *args); end - # source://rexml//lib/rexml/xpath_parser.rb#763 + # source://rexml//lib/rexml/xpath_parser.rb#767 def next_sibling_node(node); end # source://rexml//lib/rexml/xpath_parser.rb#477 def node_test(path_stack, nodesets, any_type: T.unsafe(nil)); end - # source://rexml//lib/rexml/xpath_parser.rb#802 + # source://rexml//lib/rexml/xpath_parser.rb#806 def norm(b); end - # source://rexml//lib/rexml/xpath_parser.rb#890 + # source://rexml//lib/rexml/xpath_parser.rb#894 def normalize_compare_values(a, operator, b); end # Builds a nodeset of all of the preceding nodes of the supplied node, @@ -4783,10 +4880,10 @@ class REXML::XPathParser # preceding:: includes every element in the document that precedes this node, # except for ancestors # - # source://rexml//lib/rexml/xpath_parser.rb#708 + # source://rexml//lib/rexml/xpath_parser.rb#712 def preceding(node); end - # source://rexml//lib/rexml/xpath_parser.rb#730 + # source://rexml//lib/rexml/xpath_parser.rb#734 def preceding_node_of(node); end # Reorders an array of nodes so that they are in document order @@ -4798,7 +4895,7 @@ class REXML::XPathParser # I wouldn't have to do this. Maybe add a document IDX for each node? # Problems with mutable documents. Or, rewrite everything. # - # source://rexml//lib/rexml/xpath_parser.rb#655 + # source://rexml//lib/rexml/xpath_parser.rb#659 def sort(array_of_nodes, order); end # source://rexml//lib/rexml/xpath_parser.rb#441 @@ -4809,13 +4906,13 @@ class REXML::XPathParser # source://rexml//lib/rexml/xpath_parser.rb#154 def strict?; end - # source://rexml//lib/rexml/xpath_parser.rb#630 + # source://rexml//lib/rexml/xpath_parser.rb#634 def trace(*args); end - # source://rexml//lib/rexml/xpath_parser.rb#950 + # source://rexml//lib/rexml/xpath_parser.rb#954 def unnode(nodeset); end - # source://rexml//lib/rexml/xpath_parser.rb#877 + # source://rexml//lib/rexml/xpath_parser.rb#881 def value_type(value); end end diff --git a/sorbet/rbi/gems/rouge@4.1.2.rbi b/sorbet/rbi/gems/rouge@4.3.0.rbi similarity index 98% rename from sorbet/rbi/gems/rouge@4.1.2.rbi rename to sorbet/rbi/gems/rouge@4.3.0.rbi index 53464bdfa..43024a025 100644 --- a/sorbet/rbi/gems/rouge@4.1.2.rbi +++ b/sorbet/rbi/gems/rouge@4.3.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rouge` gem. # Please instead update this file by running `bin/tapioca gem rouge`. + # The containing module for Rouge # # source://rouge//lib/rouge.rb#8 @@ -1598,6 +1599,9 @@ class Rouge::Lexers::Clojure < ::Rouge::RegexLexer end end +# source://rouge//lib/rouge/lexers/codeowners.rb#6 +class Rouge::Lexers::Codeowners < ::Rouge::RegexLexer; end + # source://rouge//lib/rouge/lexers/coffeescript.rb#6 class Rouge::Lexers::Coffeescript < ::Rouge::RegexLexer class << self @@ -1920,7 +1924,14 @@ Rouge::Lexers::Eiffel::SimpleString = T.let(T.unsafe(nil), Regexp) # See: https://bitbucket.org/birkenfeld/pygments-main/src/7304e4759ae65343d89a51359ca538912519cc31/pygments/lexers/functional.py?at=default#cl-2362 # # source://rouge//lib/rouge/lexers/elixir.rb#8 -class Rouge::Lexers::Elixir < ::Rouge::RegexLexer; end +class Rouge::Lexers::Elixir < ::Rouge::RegexLexer + class << self + # @return [Boolean] + # + # source://rouge//lib/rouge/lexers/elixir.rb#17 + def detect?(text); end + end +end # source://rouge//lib/rouge/lexers/elm.rb#6 class Rouge::Lexers::Elm < ::Rouge::RegexLexer; end @@ -2423,19 +2434,19 @@ end # source://rouge//lib/rouge/lexers/hcl.rb#6 class Rouge::Lexers::Hcl < ::Rouge::RegexLexer class << self - # source://rouge//lib/rouge/lexers/hcl.rb#55 + # source://rouge//lib/rouge/lexers/hcl.rb#56 def builtins; end - # source://rouge//lib/rouge/lexers/hcl.rb#51 + # source://rouge//lib/rouge/lexers/hcl.rb#52 def constants; end - # source://rouge//lib/rouge/lexers/hcl.rb#43 + # source://rouge//lib/rouge/lexers/hcl.rb#44 def declarations; end - # source://rouge//lib/rouge/lexers/hcl.rb#39 + # source://rouge//lib/rouge/lexers/hcl.rb#40 def keywords; end - # source://rouge//lib/rouge/lexers/hcl.rb#47 + # source://rouge//lib/rouge/lexers/hcl.rb#48 def reserved; end end end @@ -2503,7 +2514,7 @@ end class Rouge::Lexers::IRBLexer < ::Rouge::Lexers::ConsoleLexer # @return [Boolean] # - # source://rouge//lib/rouge/lexers/irb.rb#29 + # source://rouge//lib/rouge/lexers/irb.rb#35 def allow_comments?; end # source://rouge//lib/rouge/lexers/irb.rb#21 @@ -2516,7 +2527,7 @@ class Rouge::Lexers::IRBLexer < ::Rouge::Lexers::ConsoleLexer def prompt_regex; end end -# source://rouge//lib/rouge/lexers/irb.rb#35 +# source://rouge//lib/rouge/lexers/irb.rb#41 class Rouge::Lexers::IRBOutputLexer < ::Rouge::Lexers::Ruby; end # source://rouge//lib/rouge/lexers/isbl.rb#6 @@ -2553,6 +2564,23 @@ class Rouge::Lexers::Idris < ::Rouge::RegexLexer end end +# source://rouge//lib/rouge/lexers/iecst.rb#6 +class Rouge::Lexers::IecST < ::Rouge::RegexLexer + class << self + # source://rouge//lib/rouge/lexers/iecst.rb#14 + def keywords; end + + # source://rouge//lib/rouge/lexers/iecst.rb#39 + def literals; end + + # source://rouge//lib/rouge/lexers/iecst.rb#43 + def operators; end + + # source://rouge//lib/rouge/lexers/iecst.rb#29 + def types; end + end +end + # source://rouge//lib/rouge/lexers/igorpro.rb#6 class Rouge::Lexers::IgorPro < ::Rouge::RegexLexer class << self @@ -2787,6 +2815,9 @@ Rouge::Lexers::Julia::BUILTINS = T.let(T.unsafe(nil), Regexp) # source://rouge//lib/rouge/lexers/julia.rb#30 Rouge::Lexers::Julia::KEYWORDS = T.let(T.unsafe(nil), Regexp) +# source://rouge//lib/rouge/lexers/julia.rb#255 +Rouge::Lexers::Julia::NAME_RE = T.let(T.unsafe(nil), Regexp) + # source://rouge//lib/rouge/lexers/julia.rb#170 Rouge::Lexers::Julia::OPERATORS = T.let(T.unsafe(nil), Regexp) @@ -3112,7 +3143,7 @@ end # source://rouge//lib/rouge/lexers/meson.rb#6 class Rouge::Lexers::Meson < ::Rouge::RegexLexer - # source://rouge//lib/rouge/lexers/meson.rb#43 + # source://rouge//lib/rouge/lexers/meson.rb#42 def current_string; end class << self @@ -3127,22 +3158,22 @@ class Rouge::Lexers::Meson < ::Rouge::RegexLexer end end -# source://rouge//lib/rouge/lexers/meson.rb#138 +# source://rouge//lib/rouge/lexers/meson.rb#137 class Rouge::Lexers::Meson::StringRegister < ::Array # @return [Boolean] # - # source://rouge//lib/rouge/lexers/meson.rb#139 + # source://rouge//lib/rouge/lexers/meson.rb#138 def delim?(delim); end - # source://rouge//lib/rouge/lexers/meson.rb#143 + # source://rouge//lib/rouge/lexers/meson.rb#142 def register(type: T.unsafe(nil), delim: T.unsafe(nil)); end - # source://rouge//lib/rouge/lexers/meson.rb#147 + # source://rouge//lib/rouge/lexers/meson.rb#146 def remove; end # @return [Boolean] # - # source://rouge//lib/rouge/lexers/meson.rb#151 + # source://rouge//lib/rouge/lexers/meson.rb#150 def type?(type); end end @@ -3307,19 +3338,19 @@ end # source://rouge//lib/rouge/lexers/objective_c/common.rb#6 module Rouge::Lexers::ObjectiveCCommon - # source://rouge//lib/rouge/lexers/objective_c/common.rb#17 + # source://rouge//lib/rouge/lexers/objective_c/common.rb#15 def at_builtins; end - # source://rouge//lib/rouge/lexers/objective_c/common.rb#9 + # source://rouge//lib/rouge/lexers/objective_c/common.rb#7 def at_keywords; end - # source://rouge//lib/rouge/lexers/objective_c/common.rb#21 + # source://rouge//lib/rouge/lexers/objective_c/common.rb#19 def builtins; end class << self # @private # - # source://rouge//lib/rouge/lexers/objective_c/common.rb#25 + # source://rouge//lib/rouge/lexers/objective_c/common.rb#23 def extended(base); end end end @@ -3332,13 +3363,13 @@ end # source://rouge//lib/rouge/lexers/openedge.rb#6 class Rouge::Lexers::OpenEdge < ::Rouge::RegexLexer class << self - # source://rouge//lib/rouge/lexers/openedge.rb#19 + # source://rouge//lib/rouge/lexers/openedge.rb#17 def keywords; end - # source://rouge//lib/rouge/lexers/openedge.rb#495 + # source://rouge//lib/rouge/lexers/openedge.rb#493 def keywords_prepro; end - # source://rouge//lib/rouge/lexers/openedge.rb#504 + # source://rouge//lib/rouge/lexers/openedge.rb#502 def keywords_type; end end end @@ -4040,6 +4071,14 @@ class Rouge::Lexers::SuperCollider < ::Rouge::RegexLexer end end +# source://rouge//lib/rouge/lexers/svelte.rb#8 +class Rouge::Lexers::Svelte < ::Rouge::Lexers::HTML + # @return [Svelte] a new instance of Svelte + # + # source://rouge//lib/rouge/lexers/svelte.rb#14 + def initialize(*_arg0); end +end + # source://rouge//lib/rouge/lexers/swift.rb#6 class Rouge::Lexers::Swift < ::Rouge::RegexLexer; end @@ -5046,32 +5085,33 @@ end # source://rouge//lib/rouge/themes/thankful_eyes.rb#5 module Rouge::Themes; end -# default base16 theme -# by Chris Kempson (http://chriskempson.com) +# author Chris Kempson +# base16 default dark +# https://github.com/chriskempson/base16-default-schemes # -# source://rouge//lib/rouge/themes/base16.rb#8 +# source://rouge//lib/rouge/themes/base16.rb#9 class Rouge::Themes::Base16 < ::Rouge::CSSTheme extend ::Rouge::HasModes class << self - # source://rouge//lib/rouge/themes/base16.rb#35 + # source://rouge//lib/rouge/themes/base16.rb#36 def dark!; end - # source://rouge//lib/rouge/themes/base16.rb#30 + # source://rouge//lib/rouge/themes/base16.rb#31 def light!; end - # source://rouge//lib/rouge/themes/base16.rb#40 + # source://rouge//lib/rouge/themes/base16.rb#41 def make_dark!; end - # source://rouge//lib/rouge/themes/base16.rb#44 + # source://rouge//lib/rouge/themes/base16.rb#45 def make_light!; end end end -# source://rouge//lib/rouge/themes/base16.rb#108 +# source://rouge//lib/rouge/themes/base16.rb#113 class Rouge::Themes::Base16::Monokai < ::Rouge::Themes::Base16; end -# source://rouge//lib/rouge/themes/base16.rb#85 +# source://rouge//lib/rouge/themes/base16.rb#90 class Rouge::Themes::Base16::Solarized < ::Rouge::Themes::Base16; end # A port of the bw style from Pygments. @@ -5449,6 +5489,9 @@ class Rouge::Token::Tokens::Generic::Deleted < ::Rouge::Token::Tokens::Generic; # source://rouge//lib/rouge/token.rb#48 class Rouge::Token::Tokens::Generic::Emph < ::Rouge::Token::Tokens::Generic; end +# source://rouge//lib/rouge/token.rb#48 +class Rouge::Token::Tokens::Generic::EmphStrong < ::Rouge::Token::Tokens::Generic; end + # source://rouge//lib/rouge/token.rb#48 class Rouge::Token::Tokens::Generic::Error < ::Rouge::Token::Tokens::Generic; end @@ -5637,7 +5680,7 @@ class Rouge::Token::Tokens::Name::Variable::Magic < ::Rouge::Token::Tokens::Name # convenience # -# source://rouge//lib/rouge/token.rb#187 +# source://rouge//lib/rouge/token.rb#188 Rouge::Token::Tokens::Num = Rouge::Token::Tokens::Literal::Number # source://rouge//lib/rouge/token.rb#48 @@ -5655,7 +5698,7 @@ class Rouge::Token::Tokens::Punctuation < ::Rouge::Token; end # source://rouge//lib/rouge/token.rb#48 class Rouge::Token::Tokens::Punctuation::Indicator < ::Rouge::Token::Tokens::Punctuation; end -# source://rouge//lib/rouge/token.rb#188 +# source://rouge//lib/rouge/token.rb#189 Rouge::Token::Tokens::Str = Rouge::Token::Tokens::Literal::String # source://rouge//lib/rouge/token.rb#48 diff --git a/sorbet/rbi/gems/rspec-activemodel-mocks@1.1.0.rbi b/sorbet/rbi/gems/rspec-activemodel-mocks@1.2.0.rbi similarity index 84% rename from sorbet/rbi/gems/rspec-activemodel-mocks@1.1.0.rbi rename to sorbet/rbi/gems/rspec-activemodel-mocks@1.2.0.rbi index 5b38527b0..84b77de85 100644 --- a/sorbet/rbi/gems/rspec-activemodel-mocks@1.1.0.rbi +++ b/sorbet/rbi/gems/rspec-activemodel-mocks@1.2.0.rbi @@ -4,87 +4,88 @@ # This is an autogenerated file for types exported from the `rspec-activemodel-mocks` gem. # Please instead update this file by running `bin/tapioca gem rspec-activemodel-mocks`. -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#1 + +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#2 module RSpec class << self - # source://rspec-core/3.12.2/lib/rspec/core.rb#70 + # source://rspec-core/3.13.0/lib/rspec/core.rb#70 def clear_examples; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#85 + # source://rspec-core/3.13.0/lib/rspec/core.rb#85 def configuration; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def configuration=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#97 + # source://rspec-core/3.13.0/lib/rspec/core.rb#97 def configure; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#194 + # source://rspec-core/3.13.0/lib/rspec/core.rb#194 def const_missing(name); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def context(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#122 + # source://rspec-core/3.13.0/lib/rspec/core.rb#122 def current_example; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#128 + # source://rspec-core/3.13.0/lib/rspec/core.rb#128 def current_example=(example); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#154 + # source://rspec-core/3.13.0/lib/rspec/core.rb#154 def current_scope; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#134 + # source://rspec-core/3.13.0/lib/rspec/core.rb#134 def current_scope=(scope); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def describe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def example_group(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fdescribe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#58 + # source://rspec-core/3.13.0/lib/rspec/core.rb#58 def reset; end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_context(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples_for(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#160 + # source://rspec-core/3.13.0/lib/rspec/core.rb#160 def world; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def world=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xdescribe(*args, &example_group_block); end end end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#2 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#3 module RSpec::ActiveModel; end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#3 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#4 module RSpec::ActiveModel::Mocks; end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#6 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#7 class RSpec::ActiveModel::Mocks::IllegalDataAccessException < ::StandardError; end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#7 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#8 module RSpec::ActiveModel::Mocks::Mocks # Creates a test double representing `string_or_model_class` with common # ActiveModel methods stubbed out. Additional methods may be easily @@ -104,7 +105,7 @@ module RSpec::ActiveModel::Mocks::Mocks # * A String representing a Class that extends ActiveModel::Naming # * A Class that extends ActiveModel::Naming # - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#94 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#96 def mock_model(string_or_model_class, stubs = T.unsafe(nil)); end # Creates an instance of `Model` with `to_param` stubbed using a @@ -135,12 +136,12 @@ module RSpec::ActiveModel::Mocks::Mocks # stub_model(Person, :to_param => 37) # stub_model(Person) {|person| person.first_name = "David"} # - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#243 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#264 def stub_model(model_class, stubs = T.unsafe(nil)); end private - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#273 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#300 def next_id; end end @@ -169,18 +170,18 @@ module RSpec::ActiveModel::Mocks::Mocks::ActiveModelInstanceMethods def respond_to?(message, include_private = T.unsafe(nil)); end end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#183 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#201 module RSpec::ActiveModel::Mocks::Mocks::ActiveModelStubExtensions # Stubs `persisted` to return false and `id` to return nil # - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#185 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#203 def as_new_record; end # Returns `true` by default. Override with a stub. # # @return [Boolean] # - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#192 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#210 def persisted?; end end @@ -217,25 +218,25 @@ module RSpec::ActiveModel::Mocks::Mocks::ActiveRecordInstanceMethods def new_record?; end end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#197 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#215 module RSpec::ActiveModel::Mocks::Mocks::ActiveRecordStubExtensions # Stubs `id` (or other primary key method) to return nil # - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#199 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#217 def as_new_record; end # Raises an IllegalDataAccessException (stubbed models are not allowed to access the database) # # @raise [RSpec::ActiveModel::Mocks::IllegalDataAccessException] # - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#211 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#229 def connection; end # Returns the opposite of `persisted?`. # # @return [Boolean] # - # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#205 + # source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/mocks.rb#223 def new_record?; end end @@ -280,14 +281,8 @@ class RSpec::ActiveModel::Mocks::Mocks::Association def target=(_arg0); end end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#4 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#5 module RSpec::ActiveModel::Mocks::Version; end -# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#5 +# source://rspec-activemodel-mocks//lib/rspec/active_model/mocks/version.rb#6 RSpec::ActiveModel::Mocks::Version::STRING = T.let(T.unsafe(nil), String) - -# source://rspec-core/3.12.2/lib/rspec/core.rb#187 -RSpec::MODULES_TO_AUTOLOAD = T.let(T.unsafe(nil), Hash) - -# source://rspec-core/3.12.2/lib/rspec/core/shared_context.rb#54 -RSpec::SharedContext = RSpec::Core::SharedContext diff --git a/sorbet/rbi/gems/rspec-collection_matchers@1.2.0.rbi b/sorbet/rbi/gems/rspec-collection_matchers@1.2.1.rbi similarity index 66% rename from sorbet/rbi/gems/rspec-collection_matchers@1.2.0.rbi rename to sorbet/rbi/gems/rspec-collection_matchers@1.2.1.rbi index 545f55ea4..5a9263c66 100644 --- a/sorbet/rbi/gems/rspec-collection_matchers@1.2.0.rbi +++ b/sorbet/rbi/gems/rspec-collection_matchers@1.2.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rspec-collection_matchers` gem. # Please instead update this file by running `bin/tapioca gem rspec-collection_matchers`. + # source://rspec-collection_matchers//lib/rspec/collection_matchers/rails_extensions.rb#2 module ActiveModel::Validations include GeneratedInstanceMethods @@ -35,7 +36,7 @@ module ActiveModel::Validations # source://rspec-collection_matchers//lib/rspec/collection_matchers/rails_extensions.rb#17 def error_on(attribute, options = T.unsafe(nil)); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#301 + # source://activemodel/7.2.0/lib/active_model/validations.rb#330 def errors; end # Extension to enhance `to have` on AR Model instances. Calls @@ -56,32 +57,35 @@ module ActiveModel::Validations # source://rspec-collection_matchers//lib/rspec/collection_matchers/rails_extensions.rb#17 def errors_on(attribute, options = T.unsafe(nil)); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#373 + # source://activemodel/7.2.0/lib/active_model/validations.rb#402 def invalid?(context = T.unsafe(nil)); end def read_attribute_for_validation(*_arg0); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#334 + # source://activemodel/7.2.0/lib/active_model/validations.rb#363 def valid?(context = T.unsafe(nil)); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#334 + # source://activemodel/7.2.0/lib/active_model/validations.rb#363 def validate(context = T.unsafe(nil)); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#382 + # source://activemodel/7.2.0/lib/active_model/validations.rb#411 def validate!(context = T.unsafe(nil)); end - # source://activemodel/7.0.5/lib/active_model/validations/with.rb#137 + # source://activemodel/7.2.0/lib/active_model/validations/with.rb#144 def validates_with(*args, &block); end private - # source://activemodel/7.0.5/lib/active_model/validations.rb#283 + # source://activemodel/7.2.0/lib/active_model/validations.rb#434 + def init_internals; end + + # source://activemodel/7.2.0/lib/active_model/validations.rb#312 def initialize_dup(other); end - # source://activemodel/7.0.5/lib/active_model/validations.rb#410 + # source://activemodel/7.2.0/lib/active_model/validations.rb#445 def raise_validation_error; end - # source://activemodel/7.0.5/lib/active_model/validations.rb#405 + # source://activemodel/7.2.0/lib/active_model/validations.rb#440 def run_validations!; end module GeneratedClassMethods @@ -104,70 +108,70 @@ end # source://rspec-collection_matchers//lib/rspec/collection_matchers/version.rb#1 module RSpec class << self - # source://rspec-core/3.12.2/lib/rspec/core.rb#70 + # source://rspec-core/3.13.0/lib/rspec/core.rb#70 def clear_examples; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#85 + # source://rspec-core/3.13.0/lib/rspec/core.rb#85 def configuration; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def configuration=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#97 + # source://rspec-core/3.13.0/lib/rspec/core.rb#97 def configure; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#194 + # source://rspec-core/3.13.0/lib/rspec/core.rb#194 def const_missing(name); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def context(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#122 + # source://rspec-core/3.13.0/lib/rspec/core.rb#122 def current_example; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#128 + # source://rspec-core/3.13.0/lib/rspec/core.rb#128 def current_example=(example); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#154 + # source://rspec-core/3.13.0/lib/rspec/core.rb#154 def current_scope; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#134 + # source://rspec-core/3.13.0/lib/rspec/core.rb#134 def current_scope=(scope); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def describe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def example_group(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fdescribe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#58 + # source://rspec-core/3.13.0/lib/rspec/core.rb#58 def reset; end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_context(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples_for(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#160 + # source://rspec-core/3.13.0/lib/rspec/core.rb#160 def world; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def world=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xdescribe(*args, &example_group_block); end end end @@ -186,41 +190,41 @@ class RSpec::CollectionMatchers::Have # @return [Boolean] # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#38 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#42 def ==(collection_or_owner); end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#114 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#118 def description; end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#61 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#65 def determine_collection(collection_or_owner); end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#73 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#77 def determine_query_method(collection); end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#85 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#89 def failure_message; end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#85 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#89 def failure_message_for_should; end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#91 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#95 def failure_message_for_should_not; end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#91 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#95 def failure_message_when_negated; end # @return [Boolean] # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#77 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#81 def is_ignored_class?(collection); end # @return [Boolean] # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#38 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#42 def matches?(collection_or_owner); end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#81 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#85 def not_a_collection; end # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#19 @@ -228,26 +232,31 @@ class RSpec::CollectionMatchers::Have # @return [Boolean] # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#119 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#123 def respond_to?(m, include_all = T.unsafe(nil)); end + # @return [Boolean] + # + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#27 + def supports_value_expectations?; end + private - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#139 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#143 def enumerator_class; end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#147 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#151 def errors_on_message(prefix, suffix = T.unsafe(nil)); end # @return [Boolean] # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#143 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#147 def is_errors_on?; end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#125 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#129 def method_missing(method, *args, &block); end - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#135 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#139 def relative_expectation; end end @@ -257,28 +266,28 @@ RSpec::CollectionMatchers::Have::IGNORED_CLASSES = T.let(T.unsafe(nil), Array) # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#6 RSpec::CollectionMatchers::Have::QUERY_METHODS = T.let(T.unsafe(nil), Array) -# source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#152 +# source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#156 module RSpec::CollectionMatchers::Syntax class << self # Selects which expression generator to use based on the configured syntax. # # @api private # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#167 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#171 def expression_generator; end # Generates a negative expectation expression. # # @api private # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#161 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#165 def negative_expression(target_expression, matcher_expression); end # Generates a positive expectation expression. # # @api private # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#155 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#159 def positive_expression(target_expression, matcher_expression); end end end @@ -287,17 +296,17 @@ end # # @api private # -# source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#189 +# source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#193 module RSpec::CollectionMatchers::Syntax::ExpectExpressionGenerator class << self # @api private # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#194 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#198 def negative_expression(target_expression, matcher_expression); end # @api private # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#190 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#194 def positive_expression(target_expression, matcher_expression); end end end @@ -306,17 +315,17 @@ end # # @api private # -# source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#177 +# source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#181 module RSpec::CollectionMatchers::Syntax::ShouldExpressionGenerator class << self # @api private # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#182 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#186 def negative_expression(target_expression, matcher_expression); end # @api private # - # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#178 + # source://rspec-collection_matchers//lib/rspec/collection_matchers/have.rb#182 def positive_expression(target_expression, matcher_expression); end end end @@ -324,39 +333,36 @@ end # source://rspec-collection_matchers//lib/rspec/collection_matchers/version.rb#3 RSpec::CollectionMatchers::VERSION = T.let(T.unsafe(nil), String) -# source://rspec-core/3.12.2/lib/rspec/core.rb#187 -RSpec::MODULES_TO_AUTOLOAD = T.let(T.unsafe(nil), Hash) - # source://rspec-collection_matchers//lib/rspec/collection_matchers/matchers.rb#4 module RSpec::Matchers - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_changing(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_outputting(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_raising(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_throwing(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_yielding_control(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_yielding_successive_args(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_yielding_with_args(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_block_yielding_with_no_args(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_collection_containing_exactly(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_collection_ending_with(*args, **_arg1, &block); end # Passes if receiver is a collection with the submitted number of items OR @@ -390,178 +396,178 @@ module RSpec::Matchers # source://rspec-collection_matchers//lib/rspec/collection_matchers/matchers.rb#33 def a_collection_having(n); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_collection_including(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_collection_starting_with(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_falsey_value(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_falsy_value(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_hash_including(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_kind_of(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_nil_value(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_range_covering(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_string_ending_with(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_string_including(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_string_matching(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_string_starting_with(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_truthy_value(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_value(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_value_between(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def a_value_within(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#305 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#305 def aggregate_failures(label = T.unsafe(nil), metadata = T.unsafe(nil), &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#662 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#662 def all(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_array_matching(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_instance_of(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_eq_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_eql_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_equal_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_existing(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_having_attributes(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_matching(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_responding_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def an_object_satisfying(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#349 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#349 def be(*args); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#355 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#355 def be_a(klass); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#378 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#378 def be_a_kind_of(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#355 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#355 def be_an(klass); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#366 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#366 def be_an_instance_of(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#395 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#395 def be_between(min, max); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#316 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#316 def be_falsey; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def be_falsy(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#366 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#366 def be_instance_of(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#378 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#378 def be_kind_of(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#324 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#324 def be_nil; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#310 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#310 def be_truthy; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#405 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#405 def be_within(delta); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#492 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#492 def change(receiver = T.unsafe(nil), message = T.unsafe(nil), &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def changing(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#510 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#510 def contain_exactly(*items); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def containing_exactly(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#528 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#528 def cover(*values); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def covering(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#543 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#543 def end_with(*expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def ending_with(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#558 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#558 def eq(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def eq_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#572 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#572 def eql(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def eql_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#586 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#586 def equal(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def equal_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#596 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#596 def exist(*args); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def existing(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/expectations/syntax.rb#72 + # source://rspec-expectations/3.13.1/lib/rspec/expectations/syntax.rb#72 def expect(value = T.unsafe(nil), &block); end # Passes if receiver is a collection with the submitted number of items OR @@ -620,7 +626,7 @@ module RSpec::Matchers # source://rspec-collection_matchers//lib/rspec/collection_matchers/matchers.rb#59 def have_at_most(n); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#616 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#616 def have_attributes(expected); end # Passes if receiver is a collection with the submitted number of items OR @@ -654,142 +660,130 @@ module RSpec::Matchers # source://rspec-collection_matchers//lib/rspec/collection_matchers/matchers.rb#33 def have_exactly(n); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def having_attributes(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#639 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#639 def include(*expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def including(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#697 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#697 def match(expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#715 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#715 def match_array(items); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def match_regex(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def matching(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#752 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#752 def output(expected = T.unsafe(nil)); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#773 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#773 def raise_error(error = T.unsafe(nil), message = T.unsafe(nil), &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#773 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#773 def raise_exception(error = T.unsafe(nil), message = T.unsafe(nil), &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def raising(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#792 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#792 def respond_to(*names); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def responding_to(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#813 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#813 def satisfy(description = T.unsafe(nil), &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def satisfying(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#828 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#828 def start_with(*expected); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def starting_with(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#850 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#850 def throw_symbol(expected_symbol = T.unsafe(nil), expected_arg = T.unsafe(nil)); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def throwing(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def within(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#871 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#871 def yield_control; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#940 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#940 def yield_successive_args(*args); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#919 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#919 def yield_with_args(*args); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#889 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#889 def yield_with_no_args; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def yielding_control(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def yielding_successive_args(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def yielding_with_args(*args, **_arg1, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/dsl.rb#38 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/dsl.rb#38 def yielding_with_no_args(*args, **_arg1, &block); end private - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#961 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#961 def method_missing(method, *args, **_arg2, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#974 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#974 def respond_to_missing?(method, *_arg1); end class << self - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#250 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#250 def alias_matcher(*args, &block); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/generated_descriptions.rb#11 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/generated_descriptions.rb#11 def clear_generated_description; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#951 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#951 def configuration; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/generated_descriptions.rb#19 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/generated_descriptions.rb#19 def generated_description; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#1008 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#1008 def is_a_describable_matcher?(obj); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#988 + # source://rspec-expectations/3.13.1/lib/rspec/matchers.rb#988 def is_a_matcher?(obj); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/generated_descriptions.rb#25 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/generated_descriptions.rb#25 def last_description; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/generated_descriptions.rb#5 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/generated_descriptions.rb#5 def last_expectation_handler; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/generated_descriptions.rb#5 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/generated_descriptions.rb#5 def last_expectation_handler=(_arg0); end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/generated_descriptions.rb#5 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/generated_descriptions.rb#5 def last_matcher; end - # source://rspec-expectations/3.12.3/lib/rspec/matchers/generated_descriptions.rb#5 + # source://rspec-expectations/3.13.1/lib/rspec/matchers/generated_descriptions.rb#5 def last_matcher=(_arg0); end end end - -# source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#957 -RSpec::Matchers::BE_PREDICATE_REGEX = T.let(T.unsafe(nil), Regexp) - -# source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#959 -RSpec::Matchers::DYNAMIC_MATCHER_REGEX = T.let(T.unsafe(nil), Regexp) - -# source://rspec-expectations/3.12.3/lib/rspec/matchers.rb#958 -RSpec::Matchers::HAS_REGEX = T.let(T.unsafe(nil), Regexp) - -# source://rspec-core/3.12.2/lib/rspec/core/shared_context.rb#54 -RSpec::SharedContext = RSpec::Core::SharedContext diff --git a/sorbet/rbi/gems/rspec-core@3.12.2.rbi b/sorbet/rbi/gems/rspec-core@3.13.0.rbi similarity index 95% rename from sorbet/rbi/gems/rspec-core@3.12.2.rbi rename to sorbet/rbi/gems/rspec-core@3.13.0.rbi index ebc15cc28..70e3c0206 100644 --- a/sorbet/rbi/gems/rspec-core@3.12.2.rbi +++ b/sorbet/rbi/gems/rspec-core@3.13.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rspec-core` gem. # Please instead update this file by running `bin/tapioca gem rspec-core`. + module ERB::Escape private @@ -407,7 +408,7 @@ class RSpec::Core::Configuration # # @return [Configuration] a new instance of Configuration # - # source://rspec-core//lib/rspec/core/configuration.rb#509 + # source://rspec-core//lib/rspec/core/configuration.rb#528 def initialize; end # Adds a formatter to the set RSpec will use for this run. @@ -424,7 +425,7 @@ class RSpec::Core::Configuration # the configured `output_stream` (`$stdout`, by default) will be used. # @see RSpec::Core::Formatters::Protocol # - # source://rspec-core//lib/rspec/core/configuration.rb#975 + # source://rspec-core//lib/rspec/core/configuration.rb#996 def add_formatter(formatter, output = T.unsafe(nil)); end # Adds a custom setting to the RSpec.configuration object. @@ -453,7 +454,7 @@ class RSpec::Core::Configuration # @overload add_setting # @param opts [Hash] a customizable set of options # - # source://rspec-core//lib/rspec/core/configuration.rb#638 + # source://rspec-core//lib/rspec/core/configuration.rb#659 def add_setting(name, opts = T.unsafe(nil)); end # Defines a `after` hook. See {Hooks#after} for full docs. @@ -467,7 +468,7 @@ class RSpec::Core::Configuration # @see #before # @see #prepend_before # - # source://rspec-core//lib/rspec/core/configuration.rb#2004 + # source://rspec-core//lib/rspec/core/configuration.rb#2025 def after(scope = T.unsafe(nil), *meta, &block); end # Creates a method that defines an example group with the provided @@ -497,7 +498,7 @@ class RSpec::Core::Configuration # @see #alias_example_to # @see #expose_dsl_globally= # - # source://rspec-core//lib/rspec/core/configuration.rb#1188 + # source://rspec-core//lib/rspec/core/configuration.rb#1209 def alias_example_group_to(new_name, *args); end # Creates a method that delegates to `example` including the submitted @@ -532,7 +533,7 @@ class RSpec::Core::Configuration # @param name [String] example name alias # @param args [Array, Hash] metadata for the generated example # - # source://rspec-core//lib/rspec/core/configuration.rb#1156 + # source://rspec-core//lib/rspec/core/configuration.rb#1177 def alias_example_to(name, *args); end # Define an alias for it_should_behave_like that allows different @@ -561,7 +562,7 @@ class RSpec::Core::Configuration # in RSpec to define `it_should_behave_like` (for backward # compatibility), but we also add docs for that method. # - # source://rspec-core//lib/rspec/core/configuration.rb#1219 + # source://rspec-core//lib/rspec/core/configuration.rb#1240 def alias_it_behaves_like_to(new_name, report_label = T.unsafe(nil)); end # Define an alias for it_should_behave_like that allows different @@ -590,7 +591,7 @@ class RSpec::Core::Configuration # in RSpec to define `it_should_behave_like` (for backward # compatibility), but we also add docs for that method. # - # source://rspec-core//lib/rspec/core/configuration.rb#1219 + # source://rspec-core//lib/rspec/core/configuration.rb#1240 def alias_it_should_behave_like_to(new_name, report_label = T.unsafe(nil)); end # Adds `block` to the end of the list of `after` blocks in the same @@ -608,7 +609,7 @@ class RSpec::Core::Configuration # @see #before # @see #prepend_before # - # source://rspec-core//lib/rspec/core/configuration.rb#2034 + # source://rspec-core//lib/rspec/core/configuration.rb#2055 def append_after(scope = T.unsafe(nil), *meta, &block); end # Defines a `before` hook. See {Hooks#before} for full docs. @@ -622,20 +623,20 @@ class RSpec::Core::Configuration # @see #after # @see #append_after # - # source://rspec-core//lib/rspec/core/configuration.rb#1949 + # source://rspec-core//lib/rspec/core/configuration.rb#1970 def append_before(scope = T.unsafe(nil), *meta, &block); end # @private # @raise [SystemStackError] # - # source://rspec-core//lib/rspec/core/configuration.rb#1914 + # source://rspec-core//lib/rspec/core/configuration.rb#1935 def apply_derived_metadata_to(metadata); end # Registers `block` as an `around` hook. # # See {Hooks#around} for full `around` hook docs. # - # source://rspec-core//lib/rspec/core/configuration.rb#2052 + # source://rspec-core//lib/rspec/core/configuration.rb#2073 def around(scope = T.unsafe(nil), *meta, &block); end # Regexps used to exclude lines from backtraces. @@ -652,19 +653,19 @@ class RSpec::Core::Configuration # # @return [Array] # - # source://rspec-core//lib/rspec/core/configuration.rb#676 + # source://rspec-core//lib/rspec/core/configuration.rb#697 def backtrace_exclusion_patterns; end # Set regular expressions used to exclude lines in backtrace. # # @param patterns [Array] set backtrace_formatter exclusion_patterns # - # source://rspec-core//lib/rspec/core/configuration.rb#682 + # source://rspec-core//lib/rspec/core/configuration.rb#703 def backtrace_exclusion_patterns=(patterns); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#503 + # source://rspec-core//lib/rspec/core/configuration.rb#522 def backtrace_formatter; end # Regexps used to include lines in backtraces. @@ -678,14 +679,14 @@ class RSpec::Core::Configuration # # @return [Array] # - # source://rspec-core//lib/rspec/core/configuration.rb#695 + # source://rspec-core//lib/rspec/core/configuration.rb#716 def backtrace_inclusion_patterns; end # Set regular expressions used to include lines in backtrace. # # @attr patterns [Array] set backtrace_formatter inclusion_patterns # - # source://rspec-core//lib/rspec/core/configuration.rb#701 + # source://rspec-core//lib/rspec/core/configuration.rb#722 def backtrace_inclusion_patterns=(patterns); end # Defines a `before` hook. See {Hooks#before} for full docs. @@ -699,7 +700,7 @@ class RSpec::Core::Configuration # @see #after # @see #append_after # - # source://rspec-core//lib/rspec/core/configuration.rb#1949 + # source://rspec-core//lib/rspec/core/configuration.rb#1970 def before(scope = T.unsafe(nil), *meta, &block); end # Determines which bisect runner implementation gets used to run subsets @@ -721,15 +722,15 @@ class RSpec::Core::Configuration # loaded via `--require`. # @return [Symbol] # - # source://rspec-core//lib/rspec/core/configuration.rb#480 + # source://rspec-core//lib/rspec/core/configuration.rb#499 def bisect_runner; end - # source://rspec-core//lib/rspec/core/configuration.rb#481 + # source://rspec-core//lib/rspec/core/configuration.rb#500 def bisect_runner=(value); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#2098 + # source://rspec-core//lib/rspec/core/configuration.rb#2119 def bisect_runner_class; end # Enables color output if the output is a TTY. As of RSpec 3.6, this is @@ -743,7 +744,7 @@ class RSpec::Core::Configuration # @see color_mode # @see color_enabled? # - # source://rspec-core//lib/rspec/core/configuration.rb#901 + # source://rspec-core//lib/rspec/core/configuration.rb#922 def color; end # Toggle output color. @@ -752,7 +753,7 @@ class RSpec::Core::Configuration # rely on the fact that TTYs will display color by default, or set # {:color_mode} to :on to display color on a non-TTY output. # - # source://rspec-core//lib/rspec/core/configuration.rb#939 + # source://rspec-core//lib/rspec/core/configuration.rb#960 def color=(_arg0); end # Check if color is enabled for a particular output. @@ -761,7 +762,7 @@ class RSpec::Core::Configuration # `output_stream` # @return [Boolean] # - # source://rspec-core//lib/rspec/core/configuration.rb#922 + # source://rspec-core//lib/rspec/core/configuration.rb#943 def color_enabled?(output = T.unsafe(nil)); end # The mode for determining whether to display output in color. One of: @@ -774,12 +775,12 @@ class RSpec::Core::Configuration # @return [Boolean] # @see color_enabled? # - # source://rspec-core//lib/rspec/core/configuration.rb#914 + # source://rspec-core//lib/rspec/core/configuration.rb#935 def color_mode; end # Set the color mode. # - # source://rspec-core//lib/rspec/core/configuration.rb#932 + # source://rspec-core//lib/rspec/core/configuration.rb#953 def color_mode=(_arg0); end # Used internally to extend the singleton class of a single example's @@ -787,12 +788,12 @@ class RSpec::Core::Configuration # # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1556 + # source://rspec-core//lib/rspec/core/configuration.rb#1577 def configure_example(example, example_hooks); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1596 + # source://rspec-core//lib/rspec/core/configuration.rb#1617 def configure_expectation_framework; end # Used internally to extend a group with modules using `include`, `prepend` and/or @@ -800,12 +801,12 @@ class RSpec::Core::Configuration # # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1544 + # source://rspec-core//lib/rspec/core/configuration.rb#1565 def configure_group(group); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1590 + # source://rspec-core//lib/rspec/core/configuration.rb#1611 def configure_mock_framework; end # The default output color. Defaults to `:white` but can be set to one of @@ -832,7 +833,7 @@ class RSpec::Core::Configuration # The formatter that will be used if no formatter has been set. # Defaults to 'progress'. # - # source://rspec-core//lib/rspec/core/configuration.rb#982 + # source://rspec-core//lib/rspec/core/configuration.rb#1003 def default_formatter; end # Sets a fallback formatter to use if none other has been set. @@ -843,7 +844,7 @@ class RSpec::Core::Configuration # rspec.default_formatter = 'doc' # end # - # source://rspec-core//lib/rspec/core/configuration.rb#993 + # source://rspec-core//lib/rspec/core/configuration.rb#1014 def default_formatter=(value); end # Path to use if no path is provided to the `rspec` command (default: @@ -888,7 +889,7 @@ class RSpec::Core::Configuration # @yieldparam metadata [Hash] original metadata hash from an example or # group. Mutate this in your block as needed. # - # source://rspec-core//lib/rspec/core/configuration.rb#1873 + # source://rspec-core//lib/rspec/core/configuration.rb#1894 def define_derived_metadata(*filters, &block); end # Determines where deprecation warnings are printed. @@ -929,7 +930,7 @@ class RSpec::Core::Configuration # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1854 + # source://rspec-core//lib/rspec/core/configuration.rb#1875 def disable_monkey_patching; end # Enables zero monkey patching mode for RSpec. It removes monkey @@ -967,12 +968,12 @@ class RSpec::Core::Configuration # (or similar) they will still have monkey patching active # in their test environment from mocha. # - # source://rspec-core//lib/rspec/core/configuration.rb#1846 + # source://rspec-core//lib/rspec/core/configuration.rb#1867 def disable_monkey_patching!; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1854 + # source://rspec-core//lib/rspec/core/configuration.rb#1875 def disable_monkey_patching=(_arg0); end # Run examples over DRb (default: `false`). RSpec doesn't supply the DRb @@ -1084,7 +1085,7 @@ class RSpec::Core::Configuration # Returns the `exclusion_filter`. If none has been set, returns an empty # hash. # - # source://rspec-core//lib/rspec/core/configuration.rb#1348 + # source://rspec-core//lib/rspec/core/configuration.rb#1369 def exclusion_filter; end # Clears and reassigns the `exclusion_filter`. Set to `nil` if you don't @@ -1095,7 +1096,7 @@ class RSpec::Core::Configuration # This overrides any exclusion filters/tags set on the command line or in # configuration files. # - # source://rspec-core//lib/rspec/core/configuration.rb#1341 + # source://rspec-core//lib/rspec/core/configuration.rb#1362 def exclusion_filter=(filter); end # Sets the expectation framework module(s) to be included in each example @@ -1122,17 +1123,17 @@ class RSpec::Core::Configuration # custom_config.custom_setting = true # end # - # source://rspec-core//lib/rspec/core/configuration.rb#837 + # source://rspec-core//lib/rspec/core/configuration.rb#858 def expect_with(*frameworks); end # Delegates to expect_with(framework). # - # source://rspec-core//lib/rspec/core/configuration.rb#810 + # source://rspec-core//lib/rspec/core/configuration.rb#831 def expectation_framework=(framework); end # Returns the configured expectation framework adapter module(s) # - # source://rspec-core//lib/rspec/core/configuration.rb#798 + # source://rspec-core//lib/rspec/core/configuration.rb#819 def expectation_frameworks; end # Exposes the current running example via the named @@ -1157,7 +1158,7 @@ class RSpec::Core::Configuration # end # @param method_name [Symbol] the name of the helper method # - # source://rspec-core//lib/rspec/core/configuration.rb#1784 + # source://rspec-core//lib/rspec/core/configuration.rb#1805 def expose_current_running_example_as(method_name); end # Use this to expose the core RSpec DSL via `Module` and the `main` @@ -1214,7 +1215,7 @@ class RSpec::Core::Configuration # @see #include # @see #prepend # - # source://rspec-core//lib/rspec/core/configuration.rb#1494 + # source://rspec-core//lib/rspec/core/configuration.rb#1515 def extend(mod, *filters); end # If specified, indicates the number of failures required before cleaning @@ -1286,25 +1287,25 @@ class RSpec::Core::Configuration # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1062 + # source://rspec-core//lib/rspec/core/configuration.rb#1083 def files_or_directories_to_run=(*files); end # The spec files RSpec will run. # # @return [Array] specified files about to run # - # source://rspec-core//lib/rspec/core/configuration.rb#1075 + # source://rspec-core//lib/rspec/core/configuration.rb#1096 def files_to_run; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#497 + # source://rspec-core//lib/rspec/core/configuration.rb#516 def files_to_run=(_arg0); end # Returns the `inclusion_filter`. If none has been set, returns an empty # hash. # - # source://rspec-core//lib/rspec/core/configuration.rb#1292 + # source://rspec-core//lib/rspec/core/configuration.rb#1313 def filter; end # Clears and reassigns the `inclusion_filter`. Set to `nil` if you don't @@ -1315,7 +1316,7 @@ class RSpec::Core::Configuration # This overrides any inclusion filters/tags set on the command line or in # configuration files. # - # source://rspec-core//lib/rspec/core/configuration.rb#1283 + # source://rspec-core//lib/rspec/core/configuration.rb#1304 def filter=(filter); end # Adds {#backtrace_exclusion_patterns} that will filter lines from @@ -1333,17 +1334,17 @@ class RSpec::Core::Configuration # :path option, this will not filter it. # @param gem_names [Array] Names of the gems to filter # - # source://rspec-core//lib/rspec/core/configuration.rb#721 + # source://rspec-core//lib/rspec/core/configuration.rb#742 def filter_gems_from_backtrace(*gem_names); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#499 + # source://rspec-core//lib/rspec/core/configuration.rb#518 def filter_manager; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#499 + # source://rspec-core//lib/rspec/core/configuration.rb#518 def filter_manager=(_arg0); end # Adds key/value pairs to the `inclusion_filter`. If `args` @@ -1377,7 +1378,7 @@ class RSpec::Core::Configuration # # filter_run_including :foo # same as filter_run_including :foo => true # - # source://rspec-core//lib/rspec/core/configuration.rb#1254 + # source://rspec-core//lib/rspec/core/configuration.rb#1275 def filter_run(*args); end # Adds key/value pairs to the `exclusion_filter`. If `args` @@ -1411,7 +1412,7 @@ class RSpec::Core::Configuration # # filter_run_excluding :foo # same as filter_run_excluding :foo => true # - # source://rspec-core//lib/rspec/core/configuration.rb#1328 + # source://rspec-core//lib/rspec/core/configuration.rb#1349 def filter_run_excluding(*args); end # Adds key/value pairs to the `inclusion_filter`. If `args` @@ -1445,7 +1446,7 @@ class RSpec::Core::Configuration # # filter_run_including :foo # same as filter_run_including :foo => true # - # source://rspec-core//lib/rspec/core/configuration.rb#1254 + # source://rspec-core//lib/rspec/core/configuration.rb#1275 def filter_run_including(*args); end # Applies the provided filter only if any of examples match, in constrast @@ -1458,7 +1459,7 @@ class RSpec::Core::Configuration # (as in `fdescribe`, `fcontext` and `fit`) since those are aliases for # `describe`/`context`/`it` with `:focus` metadata. # - # source://rspec-core//lib/rspec/core/configuration.rb#1270 + # source://rspec-core//lib/rspec/core/configuration.rb#1291 def filter_run_when_matching(*args); end # Color used when a pending example is fixed. Defaults to `:blue` but can @@ -1486,7 +1487,7 @@ class RSpec::Core::Configuration # # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#571 + # source://rspec-core//lib/rspec/core/configuration.rb#592 def force(hash); end # Formats the docstring output using the block provided. @@ -1498,12 +1499,12 @@ class RSpec::Core::Configuration # config.format_docstrings { |s| s.strip } # end # - # source://rspec-core//lib/rspec/core/configuration.rb#1635 + # source://rspec-core//lib/rspec/core/configuration.rb#1656 def format_docstrings(&block); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1640 + # source://rspec-core//lib/rspec/core/configuration.rb#1661 def format_docstrings_block; end # Adds a formatter to the set RSpec will use for this run. @@ -1520,12 +1521,12 @@ class RSpec::Core::Configuration # the configured `output_stream` (`$stdout`, by default) will be used. # @see RSpec::Core::Formatters::Protocol # - # source://rspec-core//lib/rspec/core/configuration.rb#975 + # source://rspec-core//lib/rspec/core/configuration.rb#996 def formatter=(formatter, output = T.unsafe(nil)); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1008 + # source://rspec-core//lib/rspec/core/configuration.rb#1029 def formatter_loader; end # Returns a duplicate of the formatters currently loaded in @@ -1535,33 +1536,42 @@ class RSpec::Core::Configuration # # @return [Array] the formatters currently loaded # - # source://rspec-core//lib/rspec/core/configuration.rb#1003 + # source://rspec-core//lib/rspec/core/configuration.rb#1024 def formatters; end # Toggle full backtrace. # # @attr true_or_false [Boolean] toggle full backtrace display # - # source://rspec-core//lib/rspec/core/configuration.rb#887 + # source://rspec-core//lib/rspec/core/configuration.rb#908 def full_backtrace=(true_or_false); end # Check if full backtrace is enabled. # # @return [Boolean] is full backtrace enabled # - # source://rspec-core//lib/rspec/core/configuration.rb#881 + # source://rspec-core//lib/rspec/core/configuration.rb#902 def full_backtrace?; end + # source://rspec-core//lib/rspec/core/configuration.rb#66 + def full_cause_backtrace; end + + # source://rspec-core//lib/rspec/core/configuration.rb#89 + def full_cause_backtrace=(_arg0); end + + # source://rspec-core//lib/rspec/core/configuration.rb#78 + def full_cause_backtrace?; end + # @return [Array] full description filter # - # source://rspec-core//lib/rspec/core/configuration.rb#956 + # source://rspec-core//lib/rspec/core/configuration.rb#977 def full_description; end # Run examples matching on `description` in all files to run. # # @param description [String, Regexp] the pattern to filter on # - # source://rspec-core//lib/rspec/core/configuration.rb#951 + # source://rspec-core//lib/rspec/core/configuration.rb#972 def full_description=(description); end # Holds the various registered hooks. Here we use a FilterableItemRepository @@ -1570,12 +1580,12 @@ class RSpec::Core::Configuration # # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#2082 + # source://rspec-core//lib/rspec/core/configuration.rb#2103 def hooks; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1581 + # source://rspec-core//lib/rspec/core/configuration.rb#1602 def in_project_source_dir_regex; end # Tells RSpec to include `mod` in example groups. Methods defined in @@ -1629,7 +1639,7 @@ class RSpec::Core::Configuration # @see #extend # @see #prepend # - # source://rspec-core//lib/rspec/core/configuration.rb#1404 + # source://rspec-core//lib/rspec/core/configuration.rb#1425 def include(mod, *filters); end # Tells RSpec to include the named shared example group in example groups. @@ -1672,13 +1682,13 @@ class RSpec::Core::Configuration # example. # @see #include # - # source://rspec-core//lib/rspec/core/configuration.rb#1451 + # source://rspec-core//lib/rspec/core/configuration.rb#1472 def include_context(shared_group_name, *filters); end # Returns the `inclusion_filter`. If none has been set, returns an empty # hash. # - # source://rspec-core//lib/rspec/core/configuration.rb#1292 + # source://rspec-core//lib/rspec/core/configuration.rb#1313 def inclusion_filter; end # Clears and reassigns the `inclusion_filter`. Set to `nil` if you don't @@ -1689,12 +1699,12 @@ class RSpec::Core::Configuration # This overrides any inclusion filters/tags set on the command line or in # configuration files. # - # source://rspec-core//lib/rspec/core/configuration.rb#1283 + # source://rspec-core//lib/rspec/core/configuration.rb#1304 def inclusion_filter=(filter); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1080 + # source://rspec-core//lib/rspec/core/configuration.rb#1101 def last_run_statuses; end # Returns dirs that have been prepended to the load path by the `-I` @@ -1707,28 +1717,28 @@ class RSpec::Core::Configuration # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#942 + # source://rspec-core//lib/rspec/core/configuration.rb#963 def libs=(libs); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1604 + # source://rspec-core//lib/rspec/core/configuration.rb#1625 def load_spec_files; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#503 + # source://rspec-core//lib/rspec/core/configuration.rb#522 def loaded_spec_files; end - # Maximum count of failed source lines to display in the failure reports. - # (default `10`). + # Maximum count of failed source lines to display in the failure reports + # (defaults to `10`). # return [Integer] # # source://rspec-core//lib/rspec/core/configuration.rb#66 def max_displayed_failure_line_count; end - # Maximum count of failed source lines to display in the failure reports. - # (default `10`). + # Maximum count of failed source lines to display in the failure reports + # (defaults to `10`). # return [Integer] # # source://rspec-core//lib/rspec/core/configuration.rb#89 @@ -1741,12 +1751,12 @@ class RSpec::Core::Configuration # # @return [Symbol] # - # source://rspec-core//lib/rspec/core/configuration.rb#648 + # source://rspec-core//lib/rspec/core/configuration.rb#669 def mock_framework; end # Delegates to mock_framework=(framework). # - # source://rspec-core//lib/rspec/core/configuration.rb#660 + # source://rspec-core//lib/rspec/core/configuration.rb#681 def mock_framework=(framework); end # Sets the mock framework adapter module. @@ -1779,19 +1789,19 @@ class RSpec::Core::Configuration # mod_config.custom_setting = true # end # - # source://rspec-core//lib/rspec/core/configuration.rb#765 + # source://rspec-core//lib/rspec/core/configuration.rb#786 def mock_with(framework); end # Invokes block before defining an example group # - # source://rspec-core//lib/rspec/core/configuration.rb#2087 + # source://rspec-core//lib/rspec/core/configuration.rb#2108 def on_example_group_definition(&block); end # Returns an array of blocks to call before defining an example group # # @api private # - # source://rspec-core//lib/rspec/core/configuration.rb#2093 + # source://rspec-core//lib/rspec/core/configuration.rb#2114 def on_example_group_definition_callbacks; end # Indicates if the `--only-failures` (or `--next-failure`) flag is being used. @@ -1817,15 +1827,15 @@ class RSpec::Core::Configuration # # @see #register_ordering # - # source://rspec-core//lib/rspec/core/configuration.rb#1647 + # source://rspec-core//lib/rspec/core/configuration.rb#1668 def order=(*args, &block); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#503 + # source://rspec-core//lib/rspec/core/configuration.rb#522 def ordering_manager; end - # source://rspec-core//lib/rspec/core/configuration.rb#1647 + # source://rspec-core//lib/rspec/core/configuration.rb#1668 def ordering_registry(*args, &block); end # Determines where RSpec will send its output. @@ -1878,6 +1888,31 @@ class RSpec::Core::Configuration # source://rspec-core//lib/rspec/core/configuration.rb#78 def pending_color?; end + # Format the output for pending examples. Can be set to: + # - :full (default) - pending examples appear similarly to failures + # - :no_backtrace - same as above, but with no backtrace + # - :skip - do not show the section at all + # return [Symbol] + # + # @raise [ArgumentError] + # + # source://rspec-core//lib/rspec/core/configuration.rb#66 + def pending_failure_output; end + + # Format the output for pending examples. Can be set to: + # - :full (default) - pending examples appear similarly to failures + # - :no_backtrace - same as above, but with no backtrace + # - :skip - do not show the section at all + # return [Symbol] + # + # @raise [ArgumentError] + # + # source://rspec-core//lib/rspec/core/configuration.rb#473 + def pending_failure_output=(mode); end + + # source://rspec-core//lib/rspec/core/configuration.rb#78 + def pending_failure_output?; end + # Tells RSpec to prepend example groups with `mod`. Methods defined in # `mod` are exposed to examples (not example groups). Use `filters` to # constrain the groups in which to prepend the module. @@ -1910,7 +1945,7 @@ class RSpec::Core::Configuration # @see #include # @see #extend # - # source://rspec-core//lib/rspec/core/configuration.rb#1533 + # source://rspec-core//lib/rspec/core/configuration.rb#1554 def prepend(mod, *filters); end # Defines a `after` hook. See {Hooks#after} for full docs. @@ -1924,7 +1959,7 @@ class RSpec::Core::Configuration # @see #before # @see #prepend_before # - # source://rspec-core//lib/rspec/core/configuration.rb#2004 + # source://rspec-core//lib/rspec/core/configuration.rb#2025 def prepend_after(scope = T.unsafe(nil), *meta, &block); end # Adds `block` to the start of the list of `before` blocks in the same @@ -1942,7 +1977,7 @@ class RSpec::Core::Configuration # @see #after # @see #append_after # - # source://rspec-core//lib/rspec/core/configuration.rb#1979 + # source://rspec-core//lib/rspec/core/configuration.rb#2000 def prepend_before(scope = T.unsafe(nil), *meta, &block); end # Defaults `profile_examples` to 10 examples when `@profile_examples` is @@ -1950,7 +1985,7 @@ class RSpec::Core::Configuration # # @api private # - # source://rspec-core//lib/rspec/core/configuration.rb#1052 + # source://rspec-core//lib/rspec/core/configuration.rb#1073 def profile_examples; end # Report the times for the slowest examples (default: `false`). @@ -2002,7 +2037,7 @@ class RSpec::Core::Configuration # rspec.raise_errors_for_deprecations! # end # - # source://rspec-core//lib/rspec/core/configuration.rb#1806 + # source://rspec-core//lib/rspec/core/configuration.rb#1827 def raise_errors_for_deprecations!; end # Turns warnings into errors. This can be useful when @@ -2014,7 +2049,7 @@ class RSpec::Core::Configuration # rspec.raise_on_warning = true # end # - # source://rspec-core//lib/rspec/core/configuration.rb#1754 + # source://rspec-core//lib/rspec/core/configuration.rb#1775 def raise_on_warning=(value); end # Registers a named ordering strategy that can later be @@ -2056,12 +2091,12 @@ class RSpec::Core::Configuration # @yieldparam list [Array, Array] The examples or groups to order # @yieldreturn [Array, Array] The re-ordered examples or groups # - # source://rspec-core//lib/rspec/core/configuration.rb#1647 + # source://rspec-core//lib/rspec/core/configuration.rb#1668 def register_ordering(*args, &block); end # @return [RSpec::Core::Reporter] the currently configured reporter # - # source://rspec-core//lib/rspec/core/configuration.rb#1035 + # source://rspec-core//lib/rspec/core/configuration.rb#1056 def reporter; end # Indicates files configured to be required. @@ -2073,22 +2108,22 @@ class RSpec::Core::Configuration # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1573 + # source://rspec-core//lib/rspec/core/configuration.rb#1594 def requires=(paths); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#580 + # source://rspec-core//lib/rspec/core/configuration.rb#601 def reset; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#593 + # source://rspec-core//lib/rspec/core/configuration.rb#614 def reset_filters; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#586 + # source://rspec-core//lib/rspec/core/configuration.rb#607 def reset_reporter; end # Run all examples if none match the configured filters @@ -2124,15 +2159,15 @@ class RSpec::Core::Configuration # We recommend, actually, that you use the command line approach so you # don't accidentally leave the seed encoded. # - # source://rspec-core//lib/rspec/core/configuration.rb#1647 + # source://rspec-core//lib/rspec/core/configuration.rb#1668 def seed(*args, &block); end # Sets the seed value and sets the default global ordering to random. # - # source://rspec-core//lib/rspec/core/configuration.rb#1647 + # source://rspec-core//lib/rspec/core/configuration.rb#1668 def seed=(*args, &block); end - # source://rspec-core//lib/rspec/core/configuration.rb#1647 + # source://rspec-core//lib/rspec/core/configuration.rb#1668 def seed_used?(*args, &block); end # Configures how RSpec treats metadata passed as part of a shared example @@ -2200,7 +2235,7 @@ class RSpec::Core::Configuration # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1117 + # source://rspec-core//lib/rspec/core/configuration.rb#1138 def spec_files_with_failures; end # source://rspec-core//lib/rspec/core/configuration.rb#66 @@ -2214,12 +2249,12 @@ class RSpec::Core::Configuration # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#501 + # source://rspec-core//lib/rspec/core/configuration.rb#520 def static_config_filter_manager; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#501 + # source://rspec-core//lib/rspec/core/configuration.rb#520 def static_config_filter_manager=(_arg0); end # Color to use to indicate success. Defaults to `:green` but can be set @@ -2278,12 +2313,12 @@ class RSpec::Core::Configuration # Set Ruby warnings on or off. # - # source://rspec-core//lib/rspec/core/configuration.rb#1734 + # source://rspec-core//lib/rspec/core/configuration.rb#1755 def warnings=(value); end # @return [Boolean] Whether or not ruby warnings are enabled. # - # source://rspec-core//lib/rspec/core/configuration.rb#1739 + # source://rspec-core//lib/rspec/core/configuration.rb#1760 def warnings?; end # Defines a callback that runs after the first example with matching @@ -2305,22 +2340,22 @@ class RSpec::Core::Configuration # end # end # - # source://rspec-core//lib/rspec/core/configuration.rb#1896 + # source://rspec-core//lib/rspec/core/configuration.rb#1917 def when_first_matching_example_defined(*filters); end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#2064 + # source://rspec-core//lib/rspec/core/configuration.rb#2085 def with_suite_hooks; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#499 + # source://rspec-core//lib/rspec/core/configuration.rb#518 def world; end # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#499 + # source://rspec-core//lib/rspec/core/configuration.rb#518 def world=(_arg0); end private @@ -2329,111 +2364,111 @@ class RSpec::Core::Configuration # # @return [Boolean] # - # source://rspec-core//lib/rspec/core/configuration.rb#2220 + # source://rspec-core//lib/rspec/core/configuration.rb#2248 def absolute_pattern?(pattern); end - # source://rspec-core//lib/rspec/core/configuration.rb#2321 + # source://rspec-core//lib/rspec/core/configuration.rb#2349 def add_hook_to_existing_matching_groups(meta, scope, &block); end # @raise [MustBeConfiguredBeforeExampleGroupsError] # - # source://rspec-core//lib/rspec/core/configuration.rb#2260 + # source://rspec-core//lib/rspec/core/configuration.rb#2288 def assert_no_example_groups_defined(config_option); end - # source://rspec-core//lib/rspec/core/configuration.rb#2310 + # source://rspec-core//lib/rspec/core/configuration.rb#2338 def clear_values_derived_from_example_status_persistence_file_path; end - # source://rspec-core//lib/rspec/core/configuration.rb#2242 + # source://rspec-core//lib/rspec/core/configuration.rb#2270 def command; end - # source://rspec-core//lib/rspec/core/configuration.rb#2286 + # source://rspec-core//lib/rspec/core/configuration.rb#2314 def conditionally_disable_expectations_monkey_patching; end - # source://rspec-core//lib/rspec/core/configuration.rb#2277 + # source://rspec-core//lib/rspec/core/configuration.rb#2305 def conditionally_disable_mocks_monkey_patching; end - # source://rspec-core//lib/rspec/core/configuration.rb#2315 + # source://rspec-core//lib/rspec/core/configuration.rb#2343 def configure_group_with(group, module_list, application_method); end - # source://rspec-core//lib/rspec/core/configuration.rb#2250 + # source://rspec-core//lib/rspec/core/configuration.rb#2278 def define_built_in_hooks; end - # source://rspec-core//lib/rspec/core/configuration.rb#2373 + # source://rspec-core//lib/rspec/core/configuration.rb#2401 def define_mixed_in_module(mod, filters, mod_list, config_method, &block); end - # source://rspec-core//lib/rspec/core/configuration.rb#2225 + # source://rspec-core//lib/rspec/core/configuration.rb#2253 def extract_location(path); end - # source://rspec-core//lib/rspec/core/configuration.rb#2202 + # source://rspec-core//lib/rspec/core/configuration.rb#2230 def file_glob_from(path, pattern); end - # source://rspec-core//lib/rspec/core/configuration.rb#2191 + # source://rspec-core//lib/rspec/core/configuration.rb#2219 def gather_directories(path); end - # source://rspec-core//lib/rspec/core/configuration.rb#2170 + # source://rspec-core//lib/rspec/core/configuration.rb#2198 def get_files_to_run(paths); end - # source://rspec-core//lib/rspec/core/configuration.rb#2197 + # source://rspec-core//lib/rspec/core/configuration.rb#2225 def get_matching_files(path, pattern); end - # source://rspec-core//lib/rspec/core/configuration.rb#2137 + # source://rspec-core//lib/rspec/core/configuration.rb#2165 def handle_suite_hook(scope, meta); end - # source://rspec-core//lib/rspec/core/configuration.rb#2116 + # source://rspec-core//lib/rspec/core/configuration.rb#2137 def load_file_handling_errors(method, file); end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/configuration.rb#2343 + # source://rspec-core//lib/rspec/core/configuration.rb#2371 def metadata_applies_to_group?(meta, group); end - # source://rspec-core//lib/rspec/core/configuration.rb#2335 + # source://rspec-core//lib/rspec/core/configuration.rb#2363 def on_existing_matching_groups(meta); end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/configuration.rb#2273 + # source://rspec-core//lib/rspec/core/configuration.rb#2301 def output_to_tty?(output = T.unsafe(nil)); end - # source://rspec-core//lib/rspec/core/configuration.rb#2269 + # source://rspec-core//lib/rspec/core/configuration.rb#2297 def output_wrapper; end - # source://rspec-core//lib/rspec/core/configuration.rb#2182 + # source://rspec-core//lib/rspec/core/configuration.rb#2210 def paths_to_check(paths); end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/configuration.rb#2187 + # source://rspec-core//lib/rspec/core/configuration.rb#2215 def pattern_might_load_specs_from_vendored_dirs?; end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/configuration.rb#2296 + # source://rspec-core//lib/rspec/core/configuration.rb#2324 def rspec_expectations_loaded?; end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/configuration.rb#2292 + # source://rspec-core//lib/rspec/core/configuration.rb#2320 def rspec_mocks_loaded?; end - # source://rspec-core//lib/rspec/core/configuration.rb#2152 + # source://rspec-core//lib/rspec/core/configuration.rb#2180 def run_suite_hooks(hook_description, hooks); end - # source://rspec-core//lib/rspec/core/configuration.rb#2358 + # source://rspec-core//lib/rspec/core/configuration.rb#2386 def safe_extend(mod, host); end # :nocov: # - # source://rspec-core//lib/rspec/core/configuration.rb#2354 + # source://rspec-core//lib/rspec/core/configuration.rb#2382 def safe_include(mod, host); end - # source://rspec-core//lib/rspec/core/configuration.rb#2348 + # source://rspec-core//lib/rspec/core/configuration.rb#2376 def safe_prepend(mod, host); end - # source://rspec-core//lib/rspec/core/configuration.rb#2300 + # source://rspec-core//lib/rspec/core/configuration.rb#2328 def update_pattern_attr(name, value); end - # source://rspec-core//lib/rspec/core/configuration.rb#2246 + # source://rspec-core//lib/rspec/core/configuration.rb#2274 def value_for(key); end class << self @@ -2469,14 +2504,14 @@ class RSpec::Core::Configuration # @private # - # source://rspec-core//lib/rspec/core/configuration.rb#1645 + # source://rspec-core//lib/rspec/core/configuration.rb#1666 def delegate_to_ordering_manager(*methods); end end end # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1625 +# source://rspec-core//lib/rspec/core/configuration.rb#1646 RSpec::Core::Configuration::DEFAULT_FORMATTER = T.let(T.unsafe(nil), Proc) # This buffer is used to capture all messages sent to the reporter during @@ -2486,33 +2521,33 @@ RSpec::Core::Configuration::DEFAULT_FORMATTER = T.let(T.unsafe(nil), Proc) # # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1018 +# source://rspec-core//lib/rspec/core/configuration.rb#1039 class RSpec::Core::Configuration::DeprecationReporterBuffer # @return [DeprecationReporterBuffer] a new instance of DeprecationReporterBuffer # - # source://rspec-core//lib/rspec/core/configuration.rb#1019 + # source://rspec-core//lib/rspec/core/configuration.rb#1040 def initialize; end - # source://rspec-core//lib/rspec/core/configuration.rb#1023 + # source://rspec-core//lib/rspec/core/configuration.rb#1044 def deprecation(*args); end - # source://rspec-core//lib/rspec/core/configuration.rb#1027 + # source://rspec-core//lib/rspec/core/configuration.rb#1048 def play_onto(reporter); end end # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1794 +# source://rspec-core//lib/rspec/core/configuration.rb#1815 module RSpec::Core::Configuration::ExposeCurrentExample; end # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1105 +# source://rspec-core//lib/rspec/core/configuration.rb#1126 RSpec::Core::Configuration::FAILED_STATUS = T.let(T.unsafe(nil), String) # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#728 +# source://rspec-core//lib/rspec/core/configuration.rb#749 RSpec::Core::Configuration::MOCKING_ADAPTERS = T.let(T.unsafe(nil), Hash) # @private @@ -2522,17 +2557,17 @@ class RSpec::Core::Configuration::MustBeConfiguredBeforeExampleGroupsError < ::S # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1108 +# source://rspec-core//lib/rspec/core/configuration.rb#1129 RSpec::Core::Configuration::PASSED_STATUS = T.let(T.unsafe(nil), String) # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1111 +# source://rspec-core//lib/rspec/core/configuration.rb#1132 RSpec::Core::Configuration::PENDING_STATUS = T.let(T.unsafe(nil), String) # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1744 +# source://rspec-core//lib/rspec/core/configuration.rb#1765 RSpec::Core::Configuration::RAISE_ERROR_WARNING_NOTIFIER = T.let(T.unsafe(nil), Proc) # Module that holds `attr_reader` declarations. It's in a separate @@ -2590,6 +2625,9 @@ module RSpec::Core::Configuration::Readers # source://rspec-core//lib/rspec/core/configuration.rb#63 def fixed_color; end + # source://rspec-core//lib/rspec/core/configuration.rb#63 + def full_cause_backtrace; end + # source://rspec-core//lib/rspec/core/configuration.rb#63 def libs; end @@ -2608,6 +2646,9 @@ module RSpec::Core::Configuration::Readers # source://rspec-core//lib/rspec/core/configuration.rb#63 def pending_color; end + # source://rspec-core//lib/rspec/core/configuration.rb#63 + def pending_failure_output; end + # source://rspec-core//lib/rspec/core/configuration.rb#63 def project_source_dirs; end @@ -2638,12 +2679,12 @@ end # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1102 +# source://rspec-core//lib/rspec/core/configuration.rb#1123 RSpec::Core::Configuration::UNKNOWN_STATUS = T.let(T.unsafe(nil), String) # @private # -# source://rspec-core//lib/rspec/core/configuration.rb#1114 +# source://rspec-core//lib/rspec/core/configuration.rb#1135 RSpec::Core::Configuration::VALID_STATUSES = T.let(T.unsafe(nil), Array) # Responsible for utilizing externally provided configuration options, @@ -2687,22 +2728,22 @@ class RSpec::Core::ConfigurationOptions private - # source://rspec-core//lib/rspec/core/configuration_options.rb#169 + # source://rspec-core//lib/rspec/core/configuration_options.rb#173 def args_from_options_file(path); end - # source://rspec-core//lib/rspec/core/configuration_options.rb#138 + # source://rspec-core//lib/rspec/core/configuration_options.rb#142 def command_line_options; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#142 + # source://rspec-core//lib/rspec/core/configuration_options.rb#146 def custom_options; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#183 + # source://rspec-core//lib/rspec/core/configuration_options.rb#188 def custom_options_file; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#129 + # source://rspec-core//lib/rspec/core/configuration_options.rb#133 def env_options; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#121 + # source://rspec-core//lib/rspec/core/configuration_options.rb#125 def file_options; end # @return [Boolean] @@ -2710,28 +2751,28 @@ class RSpec::Core::ConfigurationOptions # source://rspec-core//lib/rspec/core/configuration_options.rb#66 def force?(key); end - # source://rspec-core//lib/rspec/core/configuration_options.rb#154 + # source://rspec-core//lib/rspec/core/configuration_options.rb#158 def global_options; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#195 + # source://rspec-core//lib/rspec/core/configuration_options.rb#200 def global_options_file; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#206 + # source://rspec-core//lib/rspec/core/configuration_options.rb#211 def home_options_file_path; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#117 + # source://rspec-core//lib/rspec/core/configuration_options.rb#121 def load_formatters_into(config); end - # source://rspec-core//lib/rspec/core/configuration_options.rb#146 + # source://rspec-core//lib/rspec/core/configuration_options.rb#150 def local_options; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#191 + # source://rspec-core//lib/rspec/core/configuration_options.rb#196 def local_options_file; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#175 + # source://rspec-core//lib/rspec/core/configuration_options.rb#180 def options_file_as_erb_string(path); end - # source://rspec-core//lib/rspec/core/configuration_options.rb#158 + # source://rspec-core//lib/rspec/core/configuration_options.rb#162 def options_from(path); end # source://rspec-core//lib/rspec/core/configuration_options.rb#70 @@ -2740,25 +2781,25 @@ class RSpec::Core::ConfigurationOptions # source://rspec-core//lib/rspec/core/configuration_options.rb#44 def organize_options; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#163 + # source://rspec-core//lib/rspec/core/configuration_options.rb#167 def parse_args_ignoring_files_or_dirs_to_run(args, source); end - # source://rspec-core//lib/rspec/core/configuration_options.rb#109 + # source://rspec-core//lib/rspec/core/configuration_options.rb#113 def process_options_into(config); end - # source://rspec-core//lib/rspec/core/configuration_options.rb#150 + # source://rspec-core//lib/rspec/core/configuration_options.rb#154 def project_options; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#187 + # source://rspec-core//lib/rspec/core/configuration_options.rb#192 def project_options_file; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#222 + # source://rspec-core//lib/rspec/core/configuration_options.rb#227 def resolve_xdg_config_home; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#199 + # source://rspec-core//lib/rspec/core/configuration_options.rb#204 def xdg_options_file_if_exists; end - # source://rspec-core//lib/rspec/core/configuration_options.rb#215 + # source://rspec-core//lib/rspec/core/configuration_options.rb#220 def xdg_options_file_path; end end @@ -5319,7 +5360,7 @@ class RSpec::Core::Formatters::ExceptionPresenter # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#16 def initialize(exception, example, options = T.unsafe(nil)); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#73 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#78 def colorized_formatted_backtrace(colorizer = T.unsafe(nil)); end # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#33 @@ -5348,10 +5389,10 @@ class RSpec::Core::Formatters::ExceptionPresenter # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#45 def formatted_cause(exception); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#79 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#84 def fully_formatted(failure_number, colorizer = T.unsafe(nil)); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#84 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#89 def fully_formatted_lines(failure_number, colorizer); end # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#29 @@ -5359,7 +5400,7 @@ class RSpec::Core::Formatters::ExceptionPresenter private - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#207 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#224 def add_shared_group_lines(lines, colorizer); end # Returns the value of attribute backtrace_formatter. @@ -5374,27 +5415,27 @@ class RSpec::Core::Formatters::ExceptionPresenter # for 1.8.7 # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#265 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#282 def encoded_description(description); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#115 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#120 def encoded_string(string); end # :nocov: # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#111 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#116 def encoding_of(string); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#275 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#292 def exception_backtrace; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#145 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#150 def exception_class_name(exception = T.unsafe(nil)); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#185 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#202 def exception_lines; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#178 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#184 def exception_message_string(exception); end # Returns the value of attribute extra_detail_formatter. @@ -5402,25 +5443,25 @@ class RSpec::Core::Formatters::ExceptionPresenter # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12 def extra_detail_formatter; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#196 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#213 def extra_failure_lines; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#151 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#156 def failure_lines; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#165 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#170 def failure_slash_error_lines; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#99 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#104 def final_exception(exception, previous = T.unsafe(nil)); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#241 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#258 def find_failed_line; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#256 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#273 def formatted_message_and_backtrace(colorizer); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#129 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#134 def indent_lines(lines, failure_number); end # Returns the value of attribute message_color. @@ -5428,7 +5469,7 @@ class RSpec::Core::Formatters::ExceptionPresenter # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12 def message_color; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#217 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#234 def read_failed_lines; end end @@ -5439,49 +5480,49 @@ end # # @private # -# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#284 +# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#301 class RSpec::Core::Formatters::ExceptionPresenter::Factory # @return [Factory] a new instance of Factory # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#291 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#308 def initialize(example); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#285 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#302 def build; end private - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#342 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#363 def multiple_exception_summarizer(exception, prior_detail_formatter, color); end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#338 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#359 def multiple_exceptions_error?(exception); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#301 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#318 def options; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#305 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#322 def pending_options; end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#363 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#384 def sub_failure_list_formatter(exception, message_color); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#322 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#343 def with_multiple_error_options_as_needed(exception, options); end end # @private # -# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#396 +# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#417 class RSpec::Core::Formatters::ExceptionPresenter::Factory::CommonBacktraceTruncater # @return [CommonBacktraceTruncater] a new instance of CommonBacktraceTruncater # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#397 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#418 def initialize(parent); end - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#401 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#422 def with_truncated_backtrace(child); end end @@ -5490,17 +5531,17 @@ end # # @private # -# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#389 +# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#410 module RSpec::Core::Formatters::ExceptionPresenter::Factory::EmptyBacktraceFormatter class << self - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#390 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#411 def format_backtrace(*_arg0); end end end # @private # -# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#421 +# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#442 RSpec::Core::Formatters::ExceptionPresenter::PENDING_DETAIL_FORMATTER = T.let(T.unsafe(nil), Proc) # @private @@ -5691,6 +5732,8 @@ end class RSpec::Core::Formatters::HtmlPrinter include ::ERB::Escape include ::ERB::Util + include ::ActiveSupport::CoreExt::ERBUtil + include ::ActiveSupport::CoreExt::ERBUtilPrivate # @return [HtmlPrinter] a new instance of HtmlPrinter # @@ -5763,20 +5806,20 @@ class RSpec::Core::Formatters::JsonFormatter < ::RSpec::Core::Formatters::BaseFo # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#13 def initialize(output); end - # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#55 + # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#56 def close(_notification); end - # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#59 + # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#60 def dump_profile(profile); end # @api private # - # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#78 + # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#79 def dump_profile_slowest_example_groups(profile); end # @api private # - # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#66 + # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#67 def dump_profile_slowest_examples(profile); end # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#24 @@ -5790,15 +5833,15 @@ class RSpec::Core::Formatters::JsonFormatter < ::RSpec::Core::Formatters::BaseFo # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#11 def output_hash; end - # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#50 + # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#51 def seed(notification); end # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#35 - def stop(notification); end + def stop(group_notification); end private - # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#87 + # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#88 def format_example(example); end end @@ -6244,6 +6287,9 @@ module RSpec::Core::HashImitatable # source://rspec-core//lib/rspec/core/metadata.rb#367 def deep_merge!(*args, &block); end + # source://rspec-core//lib/rspec/core/metadata.rb#367 + def deep_merge?(*args, &block); end + # source://rspec-core//lib/rspec/core/metadata.rb#367 def deep_stringify_keys(*args, &block); end @@ -6595,6 +6641,9 @@ module RSpec::Core::HashImitatable # source://rspec-core//lib/rspec/core/metadata.rb#367 def to_hash(*args, &block); end + # source://rspec-core//lib/rspec/core/metadata.rb#367 + def to_msgpack(*args, &block); end + # source://rspec-core//lib/rspec/core/metadata.rb#367 def to_options(*args, &block); end @@ -8261,57 +8310,57 @@ end # individual spec has multiple exceptions, such as one in the `it` block # and one in an `after` block. # -# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#431 +# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#452 class RSpec::Core::MultipleExceptionError < ::StandardError include ::RSpec::Core::MultipleExceptionError::InterfaceTag # @param exceptions [Array] The initial list of exceptions. # @return [MultipleExceptionError] a new instance of MultipleExceptionError # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#492 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#513 def initialize(*exceptions); end # @return [nil] Provided only for interface compatibility with # `RSpec::Expectations::MultipleExpectationsNotMetError`. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#489 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#510 def aggregation_block_label; end # @return [Hash] Metadata used by RSpec for formatting purposes. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#485 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#506 def aggregation_metadata; end # @return [Array] The list of failures and other exceptions, combined. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#482 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#503 def all_exceptions; end # return [String] A description of the failure/error counts. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#517 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#538 def exception_count_description; end # @return [Array] The list of failures. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#476 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#497 def failures; end # @note RSpec does not actually use this -- instead it formats each exception # individually. # @return [String] Combines all the exception messages into a single string. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#507 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#528 def message; end # @return [Array] The list of other errors. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#479 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#500 def other_errors; end # @return [String] A summary of the failure, including the block label and a count of failures. # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#512 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#533 def summary; end end @@ -8322,14 +8371,14 @@ end # # @private # -# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#437 +# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#458 module RSpec::Core::MultipleExceptionError::InterfaceTag # Appends the provided exception to the list. # # @param exception [Exception] Exception to append to the list. # @private # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#441 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#462 def add(exception); end class << self @@ -8339,7 +8388,7 @@ module RSpec::Core::MultipleExceptionError::InterfaceTag # # @private # - # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#467 + # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#488 def for(ex); end end end @@ -8354,7 +8403,7 @@ module RSpec::Core::Notifications; end # other registered listeners, it creates attributes based on supplied hash # of options. # -# source://rspec-core//lib/rspec/core/notifications.rb#510 +# source://rspec-core//lib/rspec/core/notifications.rb#512 class RSpec::Core::Notifications::CustomNotification < ::Struct class << self # Build a custom notification based on the supplied option key / values. @@ -8362,7 +8411,7 @@ class RSpec::Core::Notifications::CustomNotification < ::Struct # @param options [Hash] A hash of method / value pairs to create on this notification # @return [CustomNotification] # - # source://rspec-core//lib/rspec/core/notifications.rb#515 + # source://rspec-core//lib/rspec/core/notifications.rb#517 def for(options = T.unsafe(nil)); end end end @@ -8378,7 +8427,7 @@ end # @attr call_site [String] An optional call site from which the deprecation # was issued # -# source://rspec-core//lib/rspec/core/notifications.rb#491 +# source://rspec-core//lib/rspec/core/notifications.rb#493 class RSpec::Core::Notifications::DeprecationNotification < ::Struct # An optional call site from which the deprecation # was issued @@ -8435,7 +8484,7 @@ class RSpec::Core::Notifications::DeprecationNotification < ::Struct # # @api # - # source://rspec-core//lib/rspec/core/notifications.rb#497 + # source://rspec-core//lib/rspec/core/notifications.rb#499 def from_hash(data); end def inspect; end @@ -8551,7 +8600,7 @@ class RSpec::Core::Notifications::ExamplesNotification private - # source://rspec-core//lib/rspec/core/notifications.rb#134 + # source://rspec-core//lib/rspec/core/notifications.rb#136 def format_examples(examples); end end @@ -8568,11 +8617,11 @@ end # end # @see ExampleNotification # -# source://rspec-core//lib/rspec/core/notifications.rb#154 +# source://rspec-core//lib/rspec/core/notifications.rb#156 class RSpec::Core::Notifications::FailedExampleNotification < ::RSpec::Core::Notifications::ExampleNotification # @return [FailedExampleNotification] a new instance of FailedExampleNotification # - # source://rspec-core//lib/rspec/core/notifications.rb#211 + # source://rspec-core//lib/rspec/core/notifications.rb#213 def initialize(example, exception_presenter = T.unsafe(nil)); end # Returns the failures colorized formatted backtrace. @@ -8580,7 +8629,7 @@ class RSpec::Core::Notifications::FailedExampleNotification < ::RSpec::Core::Not # @param colorizer [#wrap] An object to colorize the message_lines by # @return [Array] the examples colorized backtrace lines # - # source://rspec-core//lib/rspec/core/notifications.rb#193 + # source://rspec-core//lib/rspec/core/notifications.rb#195 def colorized_formatted_backtrace(colorizer = T.unsafe(nil)); end # Returns the message generated for this failure colorized line by line. @@ -8588,43 +8637,43 @@ class RSpec::Core::Notifications::FailedExampleNotification < ::RSpec::Core::Not # @param colorizer [#wrap] An object to colorize the message_lines by # @return [Array] The example failure message colorized # - # source://rspec-core//lib/rspec/core/notifications.rb#178 + # source://rspec-core//lib/rspec/core/notifications.rb#180 def colorized_message_lines(colorizer = T.unsafe(nil)); end # @return [String] The example description # - # source://rspec-core//lib/rspec/core/notifications.rb#163 + # source://rspec-core//lib/rspec/core/notifications.rb#165 def description; end # @return [Exception] The example failure # - # source://rspec-core//lib/rspec/core/notifications.rb#158 + # source://rspec-core//lib/rspec/core/notifications.rb#160 def exception; end # Returns the failures formatted backtrace. # # @return [Array] the examples backtrace lines # - # source://rspec-core//lib/rspec/core/notifications.rb#185 + # source://rspec-core//lib/rspec/core/notifications.rb#187 def formatted_backtrace; end # @return [String] The failure information fully formatted in the way that # RSpec's built-in formatters emit. # - # source://rspec-core//lib/rspec/core/notifications.rb#199 + # source://rspec-core//lib/rspec/core/notifications.rb#201 def fully_formatted(failure_number, colorizer = T.unsafe(nil)); end # @return [Array] The failure information fully formatted in the way that # RSpec's built-in formatters emit, split by line. # - # source://rspec-core//lib/rspec/core/notifications.rb#205 + # source://rspec-core//lib/rspec/core/notifications.rb#207 def fully_formatted_lines(failure_number, colorizer = T.unsafe(nil)); end # Returns the message generated for this failure line by line. # # @return [Array] The example failure message # - # source://rspec-core//lib/rspec/core/notifications.rb#170 + # source://rspec-core//lib/rspec/core/notifications.rb#172 def message_lines; end class << self @@ -8643,7 +8692,7 @@ end # puts "Hey I started #{notification.group.description}" # end # -# source://rspec-core//lib/rspec/core/notifications.rb#256 +# source://rspec-core//lib/rspec/core/notifications.rb#258 class RSpec::Core::Notifications::GroupNotification < ::Struct # the current group # @@ -8670,7 +8719,7 @@ end # # @attr message [String] the message # -# source://rspec-core//lib/rspec/core/notifications.rb#262 +# source://rspec-core//lib/rspec/core/notifications.rb#264 class RSpec::Core::Notifications::MessageNotification < ::Struct # the message # @@ -8710,17 +8759,17 @@ end # `NullNotification` represents a placeholder value for notifications that # currently require no information, but we may wish to extend in future. # -# source://rspec-core//lib/rspec/core/notifications.rb#504 +# source://rspec-core//lib/rspec/core/notifications.rb#506 class RSpec::Core::Notifications::NullNotification; end # @deprecated Use {FailedExampleNotification} instead. # -# source://rspec-core//lib/rspec/core/notifications.rb#221 +# source://rspec-core//lib/rspec/core/notifications.rb#223 class RSpec::Core::Notifications::PendingExampleFailedAsExpectedNotification < ::RSpec::Core::Notifications::FailedExampleNotification; end # @deprecated Use {FailedExampleNotification} instead. # -# source://rspec-core//lib/rspec/core/notifications.rb#218 +# source://rspec-core//lib/rspec/core/notifications.rb#220 class RSpec::Core::Notifications::PendingExampleFixedNotification < ::RSpec::Core::Notifications::FailedExampleNotification; end # The `ProfileNotification` holds information about the results of running a @@ -8732,57 +8781,57 @@ class RSpec::Core::Notifications::PendingExampleFixedNotification < ::RSpec::Cor # @attr number_of_examples [Fixnum] the number of examples to profile # @attr example_groups [Array] example groups run # -# source://rspec-core//lib/rspec/core/notifications.rb#427 +# source://rspec-core//lib/rspec/core/notifications.rb#429 class RSpec::Core::Notifications::ProfileNotification # @return [ProfileNotification] a new instance of ProfileNotification # - # source://rspec-core//lib/rspec/core/notifications.rb#428 + # source://rspec-core//lib/rspec/core/notifications.rb#430 def initialize(duration, examples, number_of_examples, example_groups); end # the time taken (in seconds) to run the suite # # @return [Float] the current value of duration # - # source://rspec-core//lib/rspec/core/notifications.rb#434 + # source://rspec-core//lib/rspec/core/notifications.rb#436 def duration; end # the examples run # # @return [Array] the current value of examples # - # source://rspec-core//lib/rspec/core/notifications.rb#434 + # source://rspec-core//lib/rspec/core/notifications.rb#436 def examples; end # the number of examples to profile # # @return [Fixnum] the current value of number_of_examples # - # source://rspec-core//lib/rspec/core/notifications.rb#434 + # source://rspec-core//lib/rspec/core/notifications.rb#436 def number_of_examples; end # @return [String] the percentage of total time taken # - # source://rspec-core//lib/rspec/core/notifications.rb#453 + # source://rspec-core//lib/rspec/core/notifications.rb#455 def percentage; end # @return [Float] the time taken (in seconds) to run the slowest examples # - # source://rspec-core//lib/rspec/core/notifications.rb#445 + # source://rspec-core//lib/rspec/core/notifications.rb#447 def slow_duration; end # @return [Array] the slowest examples # - # source://rspec-core//lib/rspec/core/notifications.rb#437 + # source://rspec-core//lib/rspec/core/notifications.rb#439 def slowest_examples; end # @return [Array] the slowest example groups # - # source://rspec-core//lib/rspec/core/notifications.rb#462 + # source://rspec-core//lib/rspec/core/notifications.rb#464 def slowest_groups; end private - # source://rspec-core//lib/rspec/core/notifications.rb#468 + # source://rspec-core//lib/rspec/core/notifications.rb#470 def calculate_slowest_groups; end end @@ -8792,12 +8841,12 @@ end # @attr seed [Fixnum] the seed used to randomize ordering # @attr used [Boolean] whether the seed has been used or not # -# source://rspec-core//lib/rspec/core/notifications.rb#269 +# source://rspec-core//lib/rspec/core/notifications.rb#271 class RSpec::Core::Notifications::SeedNotification < ::Struct # @return [String] The seed information fully formatted in the way that # RSpec's built-in formatters emit. # - # source://rspec-core//lib/rspec/core/notifications.rb#280 + # source://rspec-core//lib/rspec/core/notifications.rb#282 def fully_formatted; end # the seed used to randomize ordering @@ -8814,7 +8863,7 @@ class RSpec::Core::Notifications::SeedNotification < ::Struct # @api # @return [Boolean] has the seed been used? # - # source://rspec-core//lib/rspec/core/notifications.rb#273 + # source://rspec-core//lib/rspec/core/notifications.rb#275 def seed_used?; end # whether the seed has been used or not @@ -8845,12 +8894,12 @@ end # @attr example [RSpec::Core::Example] the current example # @see ExampleNotification # -# source://rspec-core//lib/rspec/core/notifications.rb#228 +# source://rspec-core//lib/rspec/core/notifications.rb#230 class RSpec::Core::Notifications::SkippedExampleNotification < ::RSpec::Core::Notifications::ExampleNotification # @return [String] The pending detail fully formatted in the way that # RSpec's built-in formatters emit. # - # source://rspec-core//lib/rspec/core/notifications.rb#233 + # source://rspec-core//lib/rspec/core/notifications.rb#235 def fully_formatted(pending_number, colorizer = T.unsafe(nil)); end class << self @@ -8915,7 +8964,7 @@ end # have occurred processing # the spec suite # -# source://rspec-core//lib/rspec/core/notifications.rb#298 +# source://rspec-core//lib/rspec/core/notifications.rb#300 class RSpec::Core::Notifications::SummaryNotification < ::Struct include ::RSpec::Core::ShellEscape @@ -8926,7 +8975,7 @@ class RSpec::Core::Notifications::SummaryNotification < ::Struct # specific colors. # @return [String] A colorized summary line. # - # source://rspec-core//lib/rspec/core/notifications.rb#362 + # source://rspec-core//lib/rspec/core/notifications.rb#364 def colorized_rerun_commands(colorizer = T.unsafe(nil)); end # Wraps the results line with colors based on the configured @@ -8938,7 +8987,7 @@ class RSpec::Core::Notifications::SummaryNotification < ::Struct # specific colors. # @return [String] A colorized results line. # - # source://rspec-core//lib/rspec/core/notifications.rb#345 + # source://rspec-core//lib/rspec/core/notifications.rb#347 def colorized_totals_line(colorizer = T.unsafe(nil)); end # the time taken (in seconds) to run the suite @@ -8970,7 +9019,7 @@ class RSpec::Core::Notifications::SummaryNotification < ::Struct # @api # @return [Fixnum] the number of examples run # - # source://rspec-core//lib/rspec/core/notifications.rb#304 + # source://rspec-core//lib/rspec/core/notifications.rb#306 def example_count; end # the examples run @@ -8998,25 +9047,25 @@ class RSpec::Core::Notifications::SummaryNotification < ::Struct # @api # @return [Fixnum] the number of failed examples # - # source://rspec-core//lib/rspec/core/notifications.rb#310 + # source://rspec-core//lib/rspec/core/notifications.rb#312 def failure_count; end # @return [String] a formatted version of the time it took to run the # suite # - # source://rspec-core//lib/rspec/core/notifications.rb#372 + # source://rspec-core//lib/rspec/core/notifications.rb#374 def formatted_duration; end # @return [String] a formatted version of the time it took to boot RSpec # and load the spec files # - # source://rspec-core//lib/rspec/core/notifications.rb#378 + # source://rspec-core//lib/rspec/core/notifications.rb#380 def formatted_load_time; end # @return [String] The summary information fully formatted in the way that # RSpec's built-in formatters emit. # - # source://rspec-core//lib/rspec/core/notifications.rb#384 + # source://rspec-core//lib/rspec/core/notifications.rb#386 def fully_formatted(colorizer = T.unsafe(nil)); end # the number of seconds taken to boot RSpec @@ -9035,7 +9084,7 @@ class RSpec::Core::Notifications::SummaryNotification < ::Struct # @api # @return [Fixnum] the number of pending examples # - # source://rspec-core//lib/rspec/core/notifications.rb#316 + # source://rspec-core//lib/rspec/core/notifications.rb#318 def pending_count; end # the pending examples @@ -9052,15 +9101,15 @@ class RSpec::Core::Notifications::SummaryNotification < ::Struct # @api # @return [String] A line summarising the result totals of the spec run. # - # source://rspec-core//lib/rspec/core/notifications.rb#322 + # source://rspec-core//lib/rspec/core/notifications.rb#324 def totals_line; end private - # source://rspec-core//lib/rspec/core/notifications.rb#406 + # source://rspec-core//lib/rspec/core/notifications.rb#408 def duplicate_rerun_locations; end - # source://rspec-core//lib/rspec/core/notifications.rb#400 + # source://rspec-core//lib/rspec/core/notifications.rb#402 def rerun_argument_for(example); end class << self @@ -9097,38 +9146,38 @@ module RSpec::Core::Ordering; end # the APIs provided by `RSpec::Core::Configuration` instead. # @private # -# source://rspec-core//lib/rspec/core/ordering.rb#116 +# source://rspec-core//lib/rspec/core/ordering.rb#144 class RSpec::Core::Ordering::ConfigurationManager # @return [ConfigurationManager] a new instance of ConfigurationManager # - # source://rspec-core//lib/rspec/core/ordering.rb#119 + # source://rspec-core//lib/rspec/core/ordering.rb#147 def initialize; end - # source://rspec-core//lib/rspec/core/ordering.rb#151 + # source://rspec-core//lib/rspec/core/ordering.rb#190 def force(hash); end - # source://rspec-core//lib/rspec/core/ordering.rb#136 + # source://rspec-core//lib/rspec/core/ordering.rb#164 def order=(type); end # Returns the value of attribute ordering_registry. # - # source://rspec-core//lib/rspec/core/ordering.rb#117 + # source://rspec-core//lib/rspec/core/ordering.rb#145 def ordering_registry; end - # source://rspec-core//lib/rspec/core/ordering.rb#162 + # source://rspec-core//lib/rspec/core/ordering.rb#201 def register_ordering(name, strategy = T.unsafe(nil)); end # Returns the value of attribute seed. # - # source://rspec-core//lib/rspec/core/ordering.rb#117 + # source://rspec-core//lib/rspec/core/ordering.rb#145 def seed; end - # source://rspec-core//lib/rspec/core/ordering.rb#130 + # source://rspec-core//lib/rspec/core/ordering.rb#158 def seed=(seed); end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/ordering.rb#126 + # source://rspec-core//lib/rspec/core/ordering.rb#154 def seed_used?; end end @@ -9147,6 +9196,29 @@ class RSpec::Core::Ordering::Custom def order(list); end end +# A strategy which delays looking up the ordering until needed +# +# @private +# +# source://rspec-core//lib/rspec/core/ordering.rb#83 +class RSpec::Core::Ordering::Delayed + # @return [Delayed] a new instance of Delayed + # + # source://rspec-core//lib/rspec/core/ordering.rb#84 + def initialize(registry, name); end + + # source://rspec-core//lib/rspec/core/ordering.rb#89 + def order(list); end + + private + + # source://rspec-core//lib/rspec/core/ordering.rb#99 + def lookup_strategy; end + + # source://rspec-core//lib/rspec/core/ordering.rb#95 + def strategy; end +end + # The default global ordering (defined order). # # @private @@ -9205,22 +9277,27 @@ end # # @private # -# source://rspec-core//lib/rspec/core/ordering.rb#83 +# source://rspec-core//lib/rspec/core/ordering.rb#107 class RSpec::Core::Ordering::Registry # @return [Registry] a new instance of Registry # - # source://rspec-core//lib/rspec/core/ordering.rb#84 + # source://rspec-core//lib/rspec/core/ordering.rb#108 def initialize(configuration); end - # source://rspec-core//lib/rspec/core/ordering.rb#98 + # source://rspec-core//lib/rspec/core/ordering.rb#122 def fetch(name, &fallback); end - # source://rspec-core//lib/rspec/core/ordering.rb#102 + # @return [Boolean] + # + # source://rspec-core//lib/rspec/core/ordering.rb#126 + def has_strategy?(name); end + + # source://rspec-core//lib/rspec/core/ordering.rb#130 def register(sym, strategy); end # @return [Boolean] # - # source://rspec-core//lib/rspec/core/ordering.rb#106 + # source://rspec-core//lib/rspec/core/ordering.rb#134 def used_random_seed?; end end @@ -10044,7 +10121,7 @@ class RSpec::Core::Runner # @private # - # source://rspec-core//lib/rspec/core/runner.rb#190 + # source://rspec-core//lib/rspec/core/runner.rb#194 def exit_code(examples_passed = T.unsafe(nil)); end # @attr_reader @@ -10087,7 +10164,7 @@ class RSpec::Core::Runner private - # source://rspec-core//lib/rspec/core/runner.rb#199 + # source://rspec-core//lib/rspec/core/runner.rb#203 def persist_example_statuses; end class << self diff --git a/sorbet/rbi/gems/rspec-expectations@3.12.3.rbi b/sorbet/rbi/gems/rspec-expectations@3.13.1.rbi similarity index 97% rename from sorbet/rbi/gems/rspec-expectations@3.12.3.rbi rename to sorbet/rbi/gems/rspec-expectations@3.13.1.rbi index ffa574407..e15d4ba0f 100644 --- a/sorbet/rbi/gems/rspec-expectations@3.12.3.rbi +++ b/sorbet/rbi/gems/rspec-expectations@3.13.1.rbi @@ -4,76 +4,77 @@ # This is an autogenerated file for types exported from the `rspec-expectations` gem. # Please instead update this file by running `bin/tapioca gem rspec-expectations`. + # RSpec's top level namespace. All of rspec-expectations is contained # in the `RSpec::Expectations` and `RSpec::Matchers` namespaces. # # source://rspec-expectations//lib/rspec/matchers/english_phrasing.rb#1 module RSpec class << self - # source://rspec-core/3.12.2/lib/rspec/core.rb#70 + # source://rspec-core/3.13.0/lib/rspec/core.rb#70 def clear_examples; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#85 + # source://rspec-core/3.13.0/lib/rspec/core.rb#85 def configuration; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def configuration=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#97 + # source://rspec-core/3.13.0/lib/rspec/core.rb#97 def configure; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#194 + # source://rspec-core/3.13.0/lib/rspec/core.rb#194 def const_missing(name); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def context(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#122 + # source://rspec-core/3.13.0/lib/rspec/core.rb#122 def current_example; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#128 + # source://rspec-core/3.13.0/lib/rspec/core.rb#128 def current_example=(example); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#154 + # source://rspec-core/3.13.0/lib/rspec/core.rb#154 def current_scope; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#134 + # source://rspec-core/3.13.0/lib/rspec/core.rb#134 def current_scope=(scope); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def describe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def example_group(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fdescribe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#58 + # source://rspec-core/3.13.0/lib/rspec/core.rb#58 def reset; end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_context(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples_for(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#160 + # source://rspec-core/3.13.0/lib/rspec/core.rb#160 def world; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def world=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xdescribe(*args, &example_group_block); end end end @@ -1244,9 +1245,6 @@ module RSpec::Expectations::Version; end # source://rspec-expectations//lib/rspec/expectations/version.rb#5 RSpec::Expectations::Version::STRING = T.let(T.unsafe(nil), String) -# source://rspec-core/3.12.2/lib/rspec/core.rb#187 -RSpec::MODULES_TO_AUTOLOAD = T.let(T.unsafe(nil), Hash) - # RSpec::Matchers provides a number of useful matchers we use to define # expectations. Any object that implements the [matcher protocol](Matchers/MatcherProtocol) # can be used as a matcher. @@ -1728,7 +1726,7 @@ module RSpec::Matchers # source://rspec-expectations//lib/rspec/matchers/dsl.rb#38 def a_collection_ending_with(*args, **_arg1, &block); end - # source://rspec-collection_matchers/1.2.0/lib/rspec/collection_matchers/matchers.rb#33 + # source://rspec-collection_matchers/1.2.1/lib/rspec/collection_matchers/matchers.rb#33 def a_collection_having(n); end # Passes if actual includes expected. This works for @@ -2626,13 +2624,13 @@ module RSpec::Matchers # source://rspec-expectations//lib/rspec/expectations/syntax.rb#72 def expect(value = T.unsafe(nil), &block); end - # source://rspec-collection_matchers/1.2.0/lib/rspec/collection_matchers/matchers.rb#33 + # source://rspec-collection_matchers/1.2.1/lib/rspec/collection_matchers/matchers.rb#33 def have(n); end - # source://rspec-collection_matchers/1.2.0/lib/rspec/collection_matchers/matchers.rb#47 + # source://rspec-collection_matchers/1.2.1/lib/rspec/collection_matchers/matchers.rb#47 def have_at_least(n); end - # source://rspec-collection_matchers/1.2.0/lib/rspec/collection_matchers/matchers.rb#59 + # source://rspec-collection_matchers/1.2.1/lib/rspec/collection_matchers/matchers.rb#59 def have_at_most(n); end # Passes if actual's attribute values match the expected attributes hash. @@ -2651,7 +2649,7 @@ module RSpec::Matchers # source://rspec-expectations//lib/rspec/matchers.rb#616 def have_attributes(expected); end - # source://rspec-collection_matchers/1.2.0/lib/rspec/collection_matchers/matchers.rb#33 + # source://rspec-collection_matchers/1.2.1/lib/rspec/collection_matchers/matchers.rb#33 def have_exactly(n); end # Passes if actual's attribute values match the expected attributes hash. @@ -3380,6 +3378,18 @@ RSpec::Matchers::AliasedNegatedMatcher::DefaultFailureMessages = RSpec::Matchers # source://rspec-expectations//lib/rspec/matchers.rb#957 RSpec::Matchers::BE_PREDICATE_REGEX = T.let(T.unsafe(nil), Regexp) +# Provides a base class with as little methods as possible, so that +# most methods can be delegated via `method_missing`. +# +# On Ruby 2.0+ BasicObject could be used for this purpose, but it +# introduce some extra complexity with constant resolution, so the +# BlankSlate pattern was prefered. +# +# @private +# +# source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#10 +class RSpec::Matchers::BaseDelegator; end + # Container module for all built-in matchers. The matcher classes are here # (rather than directly under `RSpec::Matchers`) in order to prevent name # collisions, since `RSpec::Matchers` gets included into the user's namespace. @@ -3490,6 +3500,7 @@ end class RSpec::Matchers::BuiltIn::BaseMatcher include ::RSpec::Matchers::Composable include ::RSpec::Matchers::BuiltIn::BaseMatcher::HashFormatting + include ::RSpec::Matchers::BuiltIn::BaseMatcher::StringEncodingFormatting include ::RSpec::Matchers::BuiltIn::BaseMatcher::DefaultFailureMessages # @api private @@ -3636,7 +3647,7 @@ end # # @api private # -# source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#166 +# source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#207 module RSpec::Matchers::BuiltIn::BaseMatcher::DefaultFailureMessages # Provides a good generic failure message. Based on `description`. # When subclassing, if you are not satisfied with this failure message @@ -3645,7 +3656,7 @@ module RSpec::Matchers::BuiltIn::BaseMatcher::DefaultFailureMessages # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#172 + # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#213 def failure_message; end # Provides a good generic negative failure message. Based on `description`. @@ -3655,7 +3666,7 @@ module RSpec::Matchers::BuiltIn::BaseMatcher::DefaultFailureMessages # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#181 + # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#222 def failure_message_when_negated; end class << self @@ -3663,7 +3674,7 @@ module RSpec::Matchers::BuiltIn::BaseMatcher::DefaultFailureMessages # @private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#186 + # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#227 def has_default_failure_messages?(matcher); end end end @@ -3708,6 +3719,46 @@ module RSpec::Matchers::BuiltIn::BaseMatcher::HashFormatting end end +# @api private +# @private +# +# source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#165 +module RSpec::Matchers::BuiltIn::BaseMatcher::StringEncodingFormatting + private + + # Formats a String's encoding as a human readable string + # + # @api private + # @param _value [String] + # @return [nil] nil as the curent Ruby version does not support String encoding + # + # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#188 + def format_encoding(value); end + + # @api private + # @return [Boolean] False always as the curent Ruby version does not support String encoding + # + # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#171 + def string_encoding_differs?; end + + class << self + # Formats a String's encoding as a human readable string + # + # @api private + # @param _value [String] + # @return [nil] nil as the curent Ruby version does not support String encoding + # + # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#188 + def format_encoding(value); end + + # @api private + # @return [Boolean] False always as the curent Ruby version does not support String encoding + # + # source://rspec-expectations//lib/rspec/matchers/built_in/base_matcher.rb#171 + def string_encoding_differs?; end + end +end + # Used to detect when no arg is passed to `initialize`. # `nil` cannot be used because it's a valid value to pass. # @@ -4539,7 +4590,7 @@ class RSpec::Matchers::BuiltIn::Compound < ::RSpec::Matchers::BuiltIn::BaseMatch def evaluator; end # @api private - # @return [RSpec::Matchers::ExpectedsForMultipleDiffs] + # @return [RSpec::Matchers::MultiMatcherDiff] # # source://rspec-expectations//lib/rspec/matchers/built_in/compound.rb#55 def expected; end @@ -5400,13 +5451,13 @@ class RSpec::Matchers::BuiltIn::Eq < ::RSpec::Matchers::BuiltIn::BaseMatcher # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#22 + # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#26 def description; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#28 + # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#32 def diffable?; end # @api private @@ -5418,14 +5469,14 @@ class RSpec::Matchers::BuiltIn::Eq < ::RSpec::Matchers::BuiltIn::BaseMatcher # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#16 + # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#20 def failure_message_when_negated; end private # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#34 + # source://rspec-expectations//lib/rspec/matchers/built_in/eq.rb#38 def match(expected, actual); end end @@ -5439,7 +5490,7 @@ class RSpec::Matchers::BuiltIn::Eql < ::RSpec::Matchers::BuiltIn::BaseMatcher # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/eql.rb#22 + # source://rspec-expectations//lib/rspec/matchers/built_in/eql.rb#26 def diffable?; end # @api private @@ -5451,14 +5502,14 @@ class RSpec::Matchers::BuiltIn::Eql < ::RSpec::Matchers::BuiltIn::BaseMatcher # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/eql.rb#16 + # source://rspec-expectations//lib/rspec/matchers/built_in/eql.rb#20 def failure_message_when_negated; end private # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/eql.rb#28 + # source://rspec-expectations//lib/rspec/matchers/built_in/eql.rb#32 def match(expected, actual); end end @@ -6202,176 +6253,176 @@ class RSpec::Matchers::BuiltIn::RaiseError # @api private # @return [RaiseError] a new instance of RaiseError # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#18 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#22 def initialize(expected_error_or_message, expected_message, &block); end # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#113 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#117 def description; end # @api private # @private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#79 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#83 def does_not_match?(given_proc); end # @api private # @private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#95 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#99 def expects_call_stack_jump?; end # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#101 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#105 def failure_message; end # @api private # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#107 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#111 def failure_message_when_negated; end # @api private # @private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#48 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#52 def matches?(given_proc, negative_expectation = T.unsafe(nil), &block); end # @api private # @private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#85 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#89 def supports_block_expectations?; end # @api private # @private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#90 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#94 def supports_value_expectations?; end # Specifies the expected error message. # # @api public # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#39 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#43 def with_message(expected_message); end private # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#119 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#123 def actual_error_message; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#133 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#137 def block_matches?; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#129 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#133 def error_and_message_match?; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#141 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#145 def eval_block; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#125 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#129 def expectation_matched?; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#222 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#226 def expected_error; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#253 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#257 def expecting_specific_exception?; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#237 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#241 def format_backtrace(backtrace); end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#242 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#246 def given_error; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#172 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#176 def handle_warning(message); end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#257 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#261 def raise_message_already_set; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#137 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#141 def ready_to_eval_block?; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#151 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#155 def verify_message; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#184 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#188 def warn_about_bare_error!; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#176 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#180 def warn_about_bare_error?; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#210 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#214 def warn_about_negative_false_positive!(expression); end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#197 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#201 def warn_about_nil_error!; end # @api private # @return [Boolean] # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#180 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#184 def warn_about_nil_error?; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#156 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#160 def warn_for_negative_false_positives!; end # @api private # - # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#262 + # source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#266 def warning; end end @@ -6380,9 +6431,13 @@ end # passed in a different way. It's an Object, not a Module, since Module's `===` # does not evaluate to true when compared to itself. # +# Note; this _is_ the default value supplied for expected_error_or_message, but +# because there are two method-calls involved, that default is actually supplied +# in the definition of the _matcher_ method, `RSpec::Matchers#raise_error` +# # @api private # -# source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#16 +# source://rspec-expectations//lib/rspec/matchers/built_in/raise_error.rb#20 RSpec::Matchers::BuiltIn::RaiseError::UndefinedValue = T.let(T.unsafe(nil), Object) # Used to wrap match data and make it reliable for 1.8.7 @@ -7997,17 +8052,52 @@ module RSpec::Matchers::EnglishPhrasing end end -# Handles list of expected values when there is a need to render -# multiple diffs. Also can handle one value. +# source://rspec-expectations//lib/rspec/matchers.rb#958 +RSpec::Matchers::HAS_REGEX = T.let(T.unsafe(nil), Regexp) + +# Provides the necessary plumbing to wrap a matcher with a decorator. +# +# @private +# +# source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#31 +class RSpec::Matchers::MatcherDelegator < ::RSpec::Matchers::BaseDelegator + include ::RSpec::Matchers::Composable + + # @return [MatcherDelegator] a new instance of MatcherDelegator + # + # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#35 + def initialize(base_matcher); end + + # Returns the value of attribute base_matcher. + # + # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#33 + def base_matcher; end + + # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#39 + def method_missing(*args, &block); end + + private + + # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#55 + def initialize_copy(other); end + + # @return [Boolean] + # + # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#44 + def respond_to_missing?(name, include_all = T.unsafe(nil)); end +end + +# Handles list of expected and actual value pairs when there is a need +# to render multiple diffs. Also can handle one pair. # # @api private # -# source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#6 -class RSpec::Matchers::ExpectedsForMultipleDiffs +# source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#6 +class RSpec::Matchers::MultiMatcherDiff # @api private - # @return [ExpectedsForMultipleDiffs] a new instance of ExpectedsForMultipleDiffs + # @return [MultiMatcherDiff] a new instance of MultiMatcherDiff # - # source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#16 + # source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#16 def initialize(expected_list); end # Returns message with diff(s) appended for provided differ @@ -8016,51 +8106,51 @@ class RSpec::Matchers::ExpectedsForMultipleDiffs # @api private # @param message [String] original failure message # @param differ [Proc] - # @param actual [Any] value # @return [String] # - # source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#47 - def message_with_diff(message, differ, actual); end + # source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#47 + def message_with_diff(message, differ); end private # @api private # - # source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#68 - def diffs(differ, actual); end + # source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#68 + def diffs(differ); end class << self # Wraps provided matcher list in instance of - # ExpectedForMultipleDiffs. + # MultiMatcherDiff. # # @api private # @param matchers [Array] list of matchers to wrap - # @return [RSpec::Matchers::ExpectedsForMultipleDiffs] + # @return [RSpec::Matchers::MultiMatcherDiff] # - # source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#36 + # source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#37 def for_many_matchers(matchers); end # Wraps provided expected value in instance of - # ExpectedForMultipleDiffs. If provided value is already an - # ExpectedForMultipleDiffs then it just returns it. + # MultiMatcherDiff. If provided value is already an + # MultiMatcherDiff then it just returns it. # # @api private # @param expected [Any] value to be wrapped - # @return [RSpec::Matchers::ExpectedsForMultipleDiffs] + # @param actual [Any] value + # @return [RSpec::Matchers::MultiMatcherDiff] # - # source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#26 - def from(expected); end + # source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#27 + def from(expected, actual); end private # @api private # - # source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#58 + # source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#58 def diff_label_for(matcher); end # @api private # - # source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#62 + # source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#62 def truncated(description); end end end @@ -8071,51 +8161,13 @@ end # @api private # @private # -# source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#10 -RSpec::Matchers::ExpectedsForMultipleDiffs::DEFAULT_DIFF_LABEL = T.let(T.unsafe(nil), String) +# source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#10 +RSpec::Matchers::MultiMatcherDiff::DEFAULT_DIFF_LABEL = T.let(T.unsafe(nil), String) # Maximum readable matcher description length # # @api private # @private # -# source://rspec-expectations//lib/rspec/matchers/expecteds_for_multiple_diffs.rb#14 -RSpec::Matchers::ExpectedsForMultipleDiffs::DESCRIPTION_MAX_LENGTH = T.let(T.unsafe(nil), Integer) - -# source://rspec-expectations//lib/rspec/matchers.rb#958 -RSpec::Matchers::HAS_REGEX = T.let(T.unsafe(nil), Regexp) - -# Provides the necessary plumbing to wrap a matcher with a decorator. -# -# @private -# -# source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#5 -class RSpec::Matchers::MatcherDelegator - include ::RSpec::Matchers::Composable - - # @return [MatcherDelegator] a new instance of MatcherDelegator - # - # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#9 - def initialize(base_matcher); end - - # Returns the value of attribute base_matcher. - # - # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#7 - def base_matcher; end - - # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#13 - def method_missing(*args, &block); end - - private - - # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#29 - def initialize_copy(other); end - - # @return [Boolean] - # - # source://rspec-expectations//lib/rspec/matchers/matcher_delegator.rb#18 - def respond_to_missing?(name, include_all = T.unsafe(nil)); end -end - -# source://rspec-core/3.12.2/lib/rspec/core/shared_context.rb#54 -RSpec::SharedContext = RSpec::Core::SharedContext +# source://rspec-expectations//lib/rspec/matchers/multi_matcher_diff.rb#14 +RSpec::Matchers::MultiMatcherDiff::DESCRIPTION_MAX_LENGTH = T.let(T.unsafe(nil), Integer) diff --git a/sorbet/rbi/gems/rspec-mocks@3.12.5.rbi b/sorbet/rbi/gems/rspec-mocks@3.13.1.rbi similarity index 94% rename from sorbet/rbi/gems/rspec-mocks@3.12.5.rbi rename to sorbet/rbi/gems/rspec-mocks@3.13.1.rbi index d12163cb5..af2d69ea0 100644 --- a/sorbet/rbi/gems/rspec-mocks@3.12.5.rbi +++ b/sorbet/rbi/gems/rspec-mocks@3.13.1.rbi @@ -4,83 +4,81 @@ # This is an autogenerated file for types exported from the `rspec-mocks` gem. # Please instead update this file by running `bin/tapioca gem rspec-mocks`. + # Share the top-level RSpec namespace, because we are a core supported # extension. # # source://rspec-mocks//lib/rspec/mocks/instance_method_stasher.rb#1 module RSpec class << self - # source://rspec-core/3.12.2/lib/rspec/core.rb#70 + # source://rspec-core/3.13.0/lib/rspec/core.rb#70 def clear_examples; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#85 + # source://rspec-core/3.13.0/lib/rspec/core.rb#85 def configuration; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def configuration=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#97 + # source://rspec-core/3.13.0/lib/rspec/core.rb#97 def configure; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#194 + # source://rspec-core/3.13.0/lib/rspec/core.rb#194 def const_missing(name); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def context(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#122 + # source://rspec-core/3.13.0/lib/rspec/core.rb#122 def current_example; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#128 + # source://rspec-core/3.13.0/lib/rspec/core.rb#128 def current_example=(example); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#154 + # source://rspec-core/3.13.0/lib/rspec/core.rb#154 def current_scope; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#134 + # source://rspec-core/3.13.0/lib/rspec/core.rb#134 def current_scope=(scope); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def describe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def example_group(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fdescribe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#58 + # source://rspec-core/3.13.0/lib/rspec/core.rb#58 def reset; end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_context(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples_for(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#160 + # source://rspec-core/3.13.0/lib/rspec/core.rb#160 def world; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def world=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xdescribe(*args, &example_group_block); end end end -# source://rspec-core/3.12.2/lib/rspec/core.rb#187 -RSpec::MODULES_TO_AUTOLOAD = T.let(T.unsafe(nil), Hash) - # Contains top-level utility methods. While this contains a few # public methods, these are not generally meant to be called from # a test or example. They exist primarily for integration with @@ -818,46 +816,46 @@ class RSpec::Mocks::AnyInstance::Recorder private - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#280 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#282 def allow_no_prepended_module_definition_of(method_name); end # @return [Boolean] # # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#159 - def ancestor_is_an_observer?(method_name); end + def ancestor_is_an_observer?(ancestor, method_name); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#233 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#235 def backup_method!(method_name); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#267 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#269 def mark_invoked!(method_name); end # @yield [args.first, args] # - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#176 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#178 def normalize_chain(*args); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#247 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#249 def observe!(method_name); end # @return [Boolean] # - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#243 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#245 def public_protected_or_private_method_defined?(method_name); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#181 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#183 def received_expected_message!(method_name); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#227 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#229 def remove_dummy_method!(method_name); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#187 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#189 def restore_method!(method_name); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#195 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#197 def restore_original_method!(method_name); end - # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#168 + # source://rspec-mocks//lib/rspec/mocks/any_instance/recorder.rb#166 def super_class_observers_for(method_name); end # @return [Boolean] @@ -1043,7 +1041,7 @@ module RSpec::Mocks::ArgumentMatchers # @example # expect(object).to receive(:message).with(kind_of(Thing)) # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#111 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#121 def a_kind_of(klass); end # Matches if `arg.instance_of?(klass)` @@ -1051,7 +1049,7 @@ module RSpec::Mocks::ArgumentMatchers # @example # expect(object).to receive(:message).with(instance_of(Thing)) # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#101 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#111 def an_instance_of(klass); end # Acts like an arg splat, matching any number of args at any point in an arg list. @@ -1075,6 +1073,15 @@ module RSpec::Mocks::ArgumentMatchers # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#34 def anything; end + # Matches an array that excludes the specified items. + # + # @example + # expect(object).to receive(:message).with(array_excluding(1,2,3)) + # expect(object).to receive(:message).with(array_excluding([1,2,3])) + # + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#100 + def array_excluding(*args); end + # Matches an array that includes the specified items at least once. # Ignores duplicates and additional values # @@ -1082,7 +1089,7 @@ module RSpec::Mocks::ArgumentMatchers # expect(object).to receive(:message).with(array_including(1,2,3)) # expect(object).to receive(:message).with(array_including([1,2,3])) # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#80 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#90 def array_including(*args); end # Matches a boolean value. @@ -1109,7 +1116,7 @@ module RSpec::Mocks::ArgumentMatchers # expect(object).to receive(:message).with(hash_excluding(:key)) # expect(object).to receive(:message).with(hash_excluding(:key, :key2 => :val2)) # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#91 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#80 def hash_excluding(*args); end # Matches a hash that includes the specified key(s) or key/value pairs. @@ -1130,7 +1137,7 @@ module RSpec::Mocks::ArgumentMatchers # expect(object).to receive(:message).with(hash_excluding(:key)) # expect(object).to receive(:message).with(hash_excluding(:key, :key2 => :val2)) # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#91 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#80 def hash_not_including(*args); end # Matches if `arg.instance_of?(klass)` @@ -1138,7 +1145,7 @@ module RSpec::Mocks::ArgumentMatchers # @example # expect(object).to receive(:message).with(instance_of(Thing)) # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#101 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#111 def instance_of(klass); end # Matches if `arg.kind_of?(klass)` @@ -1146,7 +1153,7 @@ module RSpec::Mocks::ArgumentMatchers # @example # expect(object).to receive(:message).with(kind_of(Thing)) # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#111 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#121 def kind_of(klass); end # Matches no arguments. @@ -1160,171 +1167,192 @@ module RSpec::Mocks::ArgumentMatchers class << self # @private # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#118 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#128 def anythingize_lonely_keys(*args); end end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#149 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#159 class RSpec::Mocks::ArgumentMatchers::AnyArgMatcher < ::RSpec::Mocks::ArgumentMatchers::SingletonMatcher - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#150 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#160 def ===(_other); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#154 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#164 def description; end end -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#137 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#147 RSpec::Mocks::ArgumentMatchers::AnyArgMatcher::INSTANCE = T.let(T.unsafe(nil), RSpec::Mocks::ArgumentMatchers::AnyArgMatcher) # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#142 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#152 class RSpec::Mocks::ArgumentMatchers::AnyArgsMatcher < ::RSpec::Mocks::ArgumentMatchers::SingletonMatcher - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#143 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#153 def description; end end -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#137 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#147 RSpec::Mocks::ArgumentMatchers::AnyArgsMatcher::INSTANCE = T.let(T.unsafe(nil), RSpec::Mocks::ArgumentMatchers::AnyArgsMatcher) # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#232 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#274 +class RSpec::Mocks::ArgumentMatchers::ArrayExcludingMatcher + # @return [ArrayExcludingMatcher] a new instance of ArrayExcludingMatcher + # + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#275 + def initialize(unexpected); end + + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#279 + def ===(actual); end + + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#292 + def description; end + + private + + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#298 + def formatted_unexpected_values; end +end + +# @private +# +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#242 class RSpec::Mocks::ArgumentMatchers::ArrayIncludingMatcher # @return [ArrayIncludingMatcher] a new instance of ArrayIncludingMatcher # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#233 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#243 def initialize(expected); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#237 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#247 def ===(actual); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#248 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#260 def description; end private - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#254 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#266 def formatted_expected_values; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#178 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#188 class RSpec::Mocks::ArgumentMatchers::BaseHashMatcher # @return [BaseHashMatcher] a new instance of BaseHashMatcher # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#179 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#189 def initialize(expected); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#183 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#193 def ===(predicate, actual); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#191 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#201 def description(name); end private - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#197 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#207 def formatted_expected_hash; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#167 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#177 class RSpec::Mocks::ArgumentMatchers::BooleanMatcher < ::RSpec::Mocks::ArgumentMatchers::SingletonMatcher - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#168 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#178 def ===(value); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#172 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#182 def description; end end -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#137 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#147 RSpec::Mocks::ArgumentMatchers::BooleanMatcher::INSTANCE = T.let(T.unsafe(nil), RSpec::Mocks::ArgumentMatchers::BooleanMatcher) # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#262 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#306 class RSpec::Mocks::ArgumentMatchers::DuckTypeMatcher # @return [DuckTypeMatcher] a new instance of DuckTypeMatcher # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#263 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#307 def initialize(*methods_to_respond_to); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#267 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#311 def ===(value); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#271 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#315 def description; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#221 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#231 class RSpec::Mocks::ArgumentMatchers::HashExcludingMatcher < ::RSpec::Mocks::ArgumentMatchers::BaseHashMatcher - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#222 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#232 def ===(actual); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#226 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#236 def description; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#210 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#220 class RSpec::Mocks::ArgumentMatchers::HashIncludingMatcher < ::RSpec::Mocks::ArgumentMatchers::BaseHashMatcher - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#211 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#221 def ===(actual); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#215 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#225 def description; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#277 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#321 class RSpec::Mocks::ArgumentMatchers::InstanceOf # @return [InstanceOf] a new instance of InstanceOf # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#278 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#322 def initialize(klass); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#282 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#326 def ===(actual); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#286 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#330 def description; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#292 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#336 class RSpec::Mocks::ArgumentMatchers::KindOf # @return [KindOf] a new instance of KindOf # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#293 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#337 def initialize(klass); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#297 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#341 def ===(actual); end - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#301 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#345 def description; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#160 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#170 class RSpec::Mocks::ArgumentMatchers::NoArgsMatcher < ::RSpec::Mocks::ArgumentMatchers::SingletonMatcher - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#161 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#171 def description; end end -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#137 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#147 RSpec::Mocks::ArgumentMatchers::NoArgsMatcher::INSTANCE = T.let(T.unsafe(nil), RSpec::Mocks::ArgumentMatchers::NoArgsMatcher) # Intended to be subclassed by stateless, immutable argument matchers. @@ -1337,12 +1365,12 @@ RSpec::Mocks::ArgumentMatchers::NoArgsMatcher::INSTANCE = T.let(T.unsafe(nil), R # # @private # -# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#133 +# source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#143 class RSpec::Mocks::ArgumentMatchers::SingletonMatcher class << self # @private # - # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#136 + # source://rspec-mocks//lib/rspec/mocks/argument_matchers.rb#146 def inherited(subklass); end private @@ -1541,7 +1569,7 @@ class RSpec::Mocks::Configuration # source://rspec-mocks//lib/rspec/mocks/configuration.rb#81 def syntax=(*values); end - # Used to track wether we are temporarily suppressing verifying partial + # Used to track whether we are temporarily suppressing verifying partial # doubles with `without_partial_double_verification { ... }` # # @private @@ -1549,7 +1577,7 @@ class RSpec::Mocks::Configuration # source://rspec-mocks//lib/rspec/mocks/configuration.rb#161 def temporarily_suppress_partial_double_verification; end - # Used to track wether we are temporarily suppressing verifying partial + # Used to track whether we are temporarily suppressing verifying partial # doubles with `without_partial_double_verification { ... }` # # @private @@ -3265,7 +3293,7 @@ class RSpec::Mocks::MessageExpectation # # allow(api).to receive(:get_foo).and_invoke(-> { raise ApiTimeout }, -> { raise ApiTimeout }, -> { :a_foo }) # api.get_foo # => raises ApiTimeout - # api.get_foo # => rasies ApiTimeout + # api.get_foo # => raises ApiTimeout # api.get_foo # => :a_foo # api.get_foo # => :a_foo # api.get_foo # => :a_foo @@ -3736,17 +3764,17 @@ class RSpec::Mocks::MethodDouble # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#209 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#216 def add_default_stub(*args, &implementation); end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#159 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#166 def add_expectation(error_generator, expectation_ordering, expected_from, opts, &implementation); end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#195 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#202 def add_simple_expectation(method_name, response, error_generator, backtrace_line); end # A simple stub can only return a concrete value for a message, and @@ -3758,32 +3786,32 @@ class RSpec::Mocks::MethodDouble # # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#190 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#197 def add_simple_stub(method_name, response); end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#174 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#181 def add_stub(error_generator, expectation_ordering, expected_from, opts = T.unsafe(nil), &implementation); end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#168 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#175 def build_expectation(error_generator, expectation_ordering); end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#145 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#152 def clear; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#54 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#61 def configure_method; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#61 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#68 def define_proxy_method; end # @private @@ -3796,9 +3824,14 @@ class RSpec::Mocks::MethodDouble # # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#154 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#161 def message_expectation_class; end + # @private + # + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#41 + def method_missing_block; end + # @private # # source://rspec-mocks//lib/rspec/mocks/method_double.rb#9 @@ -3816,13 +3849,13 @@ class RSpec::Mocks::MethodDouble # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#49 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#56 def object_singleton_class; end # source://rspec-mocks//lib/rspec/mocks/method_double.rb#24 def original_implementation_callable; end - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#37 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#34 def original_method; end # The implementation of the proxied method. Subclasses may override this @@ -3830,37 +3863,37 @@ class RSpec::Mocks::MethodDouble # # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#90 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#97 def proxy_method_invoked(_obj, *args, **_arg2, &block); end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#226 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#233 def raise_method_not_stubbed_error; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#215 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#222 def remove_stub; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#221 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#228 def remove_stub_if_present; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#139 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#146 def reset; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#96 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#103 def restore_original_method; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#126 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#133 def restore_original_visibility; end # source://rspec-mocks//lib/rspec/mocks/method_double.rb#24 @@ -3868,12 +3901,12 @@ class RSpec::Mocks::MethodDouble # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#200 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#207 def setup_simple_method_double(method_name, response, collection, error_generator = T.unsafe(nil), backtrace_line = T.unsafe(nil)); end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#115 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#122 def show_frozen_warning; end # @private @@ -3883,26 +3916,26 @@ class RSpec::Mocks::MethodDouble # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#134 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#141 def verify; end # @private # - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#44 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#51 def visibility; end private - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#248 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#255 def definition_target; end - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#268 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#275 def new_rspec_prepended_module; end - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#286 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#293 def remove_method_from_definition_target; end - # source://rspec-mocks//lib/rspec/mocks/method_double.rb#252 + # source://rspec-mocks//lib/rspec/mocks/method_double.rb#259 def usable_rspec_prepended_module; end end @@ -3913,7 +3946,7 @@ RSpec::Mocks::MethodDouble::FROZEN_ERROR_MSG = T.let(T.unsafe(nil), Regexp) # We subclass `Module` in order to be able to easily detect our prepended module. # -# source://rspec-mocks//lib/rspec/mocks/method_double.rb#246 +# source://rspec-mocks//lib/rspec/mocks/method_double.rb#253 class RSpec::Mocks::MethodDouble::RSpecPrependedModule < ::Module; end # Represents a method on an object that may or may not be defined. @@ -4253,7 +4286,7 @@ class RSpec::Mocks::OutsideOfExampleError < ::StandardError; end # @private # -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#459 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#456 class RSpec::Mocks::PartialClassDoubleProxy < ::RSpec::Mocks::PartialDoubleProxy include ::RSpec::Mocks::PartialClassDoubleProxyMethods end @@ -4265,9 +4298,9 @@ end # # @private # -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#383 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#380 module RSpec::Mocks::PartialClassDoubleProxyMethods - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#384 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#381 def initialize(source_space, *args); end # Consider this situation: @@ -4291,85 +4324,85 @@ module RSpec::Mocks::PartialClassDoubleProxyMethods # That's what this method (together with `original_unbound_method_handle_from_ancestor_for`) # does. # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#409 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#406 def original_method_handle_for(message); end protected - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#437 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#434 def method_double_from_ancestor_for(message); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#432 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#429 def original_unbound_method_handle_from_ancestor_for(message); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#447 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#444 def superclass_proxy; end end # @private # -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#320 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#317 class RSpec::Mocks::PartialDoubleProxy < ::RSpec::Mocks::Proxy # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#334 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#331 def add_simple_expectation(method_name, response, location); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#340 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#337 def add_simple_stub(method_name, response); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#357 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#354 def message_received(message, *args, **_arg2, &block); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#321 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#318 def original_method_handle_for(message); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#352 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#349 def reset; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#346 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#343 def visibility_for(method_name); end private # @return [Boolean] # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#367 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#364 def any_instance_class_recorder_observing_method?(klass, method_name); end end # @private # -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#4 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#6 class RSpec::Mocks::Proxy # @private # @return [Proxy] a new instance of Proxy # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#23 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#20 def initialize(object, order_group, options = T.unsafe(nil)); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#68 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#65 def add_message_expectation(method_name, opts = T.unsafe(nil), &block); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#82 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#79 def add_simple_expectation(method_name, response, location); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#143 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#140 def add_simple_stub(method_name, response); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#137 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#134 def add_stub(method_name, opts = T.unsafe(nil), &implementation); end # Tells the object to ignore any messages that aren't explicitly set as @@ -4377,155 +4410,155 @@ class RSpec::Mocks::Proxy # # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#55 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#52 def as_null_object; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#87 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#84 def build_expectation(method_name); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#120 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#117 def check_for_unexpected_arguments(expectation); end # @private # @raise [ArgumentError] # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#37 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#34 def ensure_can_be_proxied!(object); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#18 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#15 def ensure_implemented(*_args); end # @private # @return [Boolean] # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#184 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#181 def has_negative_expectation?(message); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#198 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#195 def message_received(message, *args, **_arg2, &block); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#177 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#174 def messages_arg_list; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#263 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#260 def method_double_if_exists_for_message(message); end # @private # @return [Boolean] # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#48 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#45 def null_object?; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#45 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#42 def object; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#61 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#58 def original_method_handle_for(_message); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#257 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#254 def prepended_modules_of_singleton_class; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#236 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#233 def raise_missing_default_stub_error(expectation, args_for_multiple_calls); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#231 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#228 def raise_unexpected_message_error(method_name, args); end # @private # @return [Boolean] # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#170 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#167 def received_message?(method_name, *args, &block); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#189 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#186 def record_message_received(message, *args, **_arg2, &block); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#148 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#145 def remove_stub(method_name); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#153 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#150 def remove_stub_if_present(method_name); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#97 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#94 def replay_received_message_on(expectation, &block); end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#163 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#160 def reset; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#158 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#155 def verify; end # @private # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#241 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#238 def visibility_for(_method_name); end private - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#280 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#277 def find_almost_matching_expectation(method_name, *args, **_arg2); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#304 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#301 def find_almost_matching_stub(method_name, *args, **_arg2); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#287 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#284 def find_best_matching_expectation_for(method_name); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#273 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#270 def find_matching_expectation(method_name, *args, **_arg2); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#299 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#296 def find_matching_method_stub(method_name, *args, **_arg2); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#269 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#266 def method_double_for(message); end class << self - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#247 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#244 def prepended_modules_of(klass); end end end -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#65 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#62 RSpec::Mocks::Proxy::DEFAULT_MESSAGE_EXPECTATION_OPTS = T.let(T.unsafe(nil), Hash) # @private # -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#6 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#8 class RSpec::Mocks::Proxy::SpecificMessage < ::Struct - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#7 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#9 def ==(expectation); end # Returns the value of attribute args @@ -4572,55 +4605,55 @@ end # @private # -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#464 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#461 class RSpec::Mocks::ProxyForNil < ::RSpec::Mocks::PartialDoubleProxy # @return [ProxyForNil] a new instance of ProxyForNil # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#465 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#462 def initialize(order_group); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#473 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#470 def add_message_expectation(method_name, opts = T.unsafe(nil), &block); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#478 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#475 def add_stub(method_name, opts = T.unsafe(nil), &implementation); end # Returns the value of attribute disallow_expectations. # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#470 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#467 def disallow_expectations; end # Sets the attribute disallow_expectations # # @param value the value to set the attribute disallow_expectations to. # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#470 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#467 def disallow_expectations=(_arg0); end # Returns the value of attribute warn_about_expectations. # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#471 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#468 def warn_about_expectations; end # Sets the attribute warn_about_expectations # # @param value the value to set the attribute warn_about_expectations to. # - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#471 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#468 def warn_about_expectations=(_arg0); end private - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#515 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#512 def raise_error(method_name); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#485 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#482 def set_expectation_behavior; end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#510 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#507 def warn(method_name); end - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#499 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#496 def warn_or_raise!(method_name); end end @@ -5054,9 +5087,9 @@ end # @private # -# source://rspec-mocks//lib/rspec/mocks/proxy.rb#311 +# source://rspec-mocks//lib/rspec/mocks/proxy.rb#308 class RSpec::Mocks::TestDoubleProxy < ::RSpec::Mocks::Proxy - # source://rspec-mocks//lib/rspec/mocks/proxy.rb#312 + # source://rspec-mocks//lib/rspec/mocks/proxy.rb#309 def reset; end end @@ -5306,6 +5339,3 @@ module RSpec::Mocks::Version; end # # source://rspec-mocks//lib/rspec/mocks/version.rb#6 RSpec::Mocks::Version::STRING = T.let(T.unsafe(nil), String) - -# source://rspec-core/3.12.2/lib/rspec/core/shared_context.rb#54 -RSpec::SharedContext = RSpec::Core::SharedContext diff --git a/sorbet/rbi/gems/rspec-rails@6.0.3.rbi b/sorbet/rbi/gems/rspec-rails@6.1.3.rbi similarity index 74% rename from sorbet/rbi/gems/rspec-rails@6.0.3.rbi rename to sorbet/rbi/gems/rspec-rails@6.1.3.rbi index c45ab1002..5733bc577 100644 --- a/sorbet/rbi/gems/rspec-rails@6.0.3.rbi +++ b/sorbet/rbi/gems/rspec-rails@6.1.3.rbi @@ -4,82 +4,80 @@ # This is an autogenerated file for types exported from the `rspec-rails` gem. # Please instead update this file by running `bin/tapioca gem rspec-rails`. + # Namespace for all core RSpec projects. # # source://rspec-rails//lib/rspec/rails/feature_check.rb#1 module RSpec class << self - # source://rspec-core/3.12.2/lib/rspec/core.rb#70 + # source://rspec-core/3.13.0/lib/rspec/core.rb#70 def clear_examples; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#85 + # source://rspec-core/3.13.0/lib/rspec/core.rb#85 def configuration; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def configuration=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#97 + # source://rspec-core/3.13.0/lib/rspec/core.rb#97 def configure; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#194 + # source://rspec-core/3.13.0/lib/rspec/core.rb#194 def const_missing(name); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def context(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#122 + # source://rspec-core/3.13.0/lib/rspec/core.rb#122 def current_example; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#128 + # source://rspec-core/3.13.0/lib/rspec/core.rb#128 def current_example=(example); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#154 + # source://rspec-core/3.13.0/lib/rspec/core.rb#154 def current_scope; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#134 + # source://rspec-core/3.13.0/lib/rspec/core.rb#134 def current_scope=(scope); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def describe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def example_group(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fdescribe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#58 + # source://rspec-core/3.13.0/lib/rspec/core.rb#58 def reset; end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_context(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples_for(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#160 + # source://rspec-core/3.13.0/lib/rspec/core.rb#160 def world; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def world=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xdescribe(*args, &example_group_block); end end end -# source://rspec-core/3.12.2/lib/rspec/core.rb#187 -RSpec::MODULES_TO_AUTOLOAD = T.let(T.unsafe(nil), Hash) - # Namespace for rspec-rails code. # # source://rspec-rails//lib/rspec/rails/feature_check.rb#2 @@ -186,7 +184,7 @@ end class RSpec::Rails::Railtie < ::Rails::Railtie private - # source://rspec-rails//lib/rspec-rails.rb#50 + # source://rspec-rails//lib/rspec-rails.rb#51 def config_default_preview_path(options); end # @return [Boolean] @@ -199,9 +197,6 @@ class RSpec::Rails::Railtie < ::Rails::Railtie # @return [Boolean] # - # source://rspec-rails//lib/rspec-rails.rb#56 + # source://rspec-rails//lib/rspec-rails.rb#64 def supports_action_mailer_previews?(config); end end - -# source://rspec-core/3.12.2/lib/rspec/core/shared_context.rb#54 -RSpec::SharedContext = RSpec::Core::SharedContext diff --git a/sorbet/rbi/gems/rspec-support@3.12.0.rbi b/sorbet/rbi/gems/rspec-support@3.13.1.rbi similarity index 84% rename from sorbet/rbi/gems/rspec-support@3.12.0.rbi rename to sorbet/rbi/gems/rspec-support@3.13.1.rbi index e72e18999..6a7f9cf39 100644 --- a/sorbet/rbi/gems/rspec-support@3.12.0.rbi +++ b/sorbet/rbi/gems/rspec-support@3.13.1.rbi @@ -4,75 +4,76 @@ # This is an autogenerated file for types exported from the `rspec-support` gem. # Please instead update this file by running `bin/tapioca gem rspec-support`. -# source://rspec-support//lib/rspec/support.rb#1 + +# source://rspec-support//lib/rspec/support.rb#3 module RSpec extend ::RSpec::Support::Warnings class << self - # source://rspec-core/3.12.2/lib/rspec/core.rb#70 + # source://rspec-core/3.13.0/lib/rspec/core.rb#70 def clear_examples; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#85 + # source://rspec-core/3.13.0/lib/rspec/core.rb#85 def configuration; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def configuration=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#97 + # source://rspec-core/3.13.0/lib/rspec/core.rb#97 def configure; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#194 + # source://rspec-core/3.13.0/lib/rspec/core.rb#194 def const_missing(name); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def context(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#122 + # source://rspec-core/3.13.0/lib/rspec/core.rb#122 def current_example; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#128 + # source://rspec-core/3.13.0/lib/rspec/core.rb#128 def current_example=(example); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#154 + # source://rspec-core/3.13.0/lib/rspec/core.rb#154 def current_scope; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#134 + # source://rspec-core/3.13.0/lib/rspec/core.rb#134 def current_scope=(scope); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def describe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def example_group(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def fdescribe(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#58 + # source://rspec-core/3.13.0/lib/rspec/core.rb#58 def reset; end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_context(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core/shared_example_group.rb#110 + # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110 def shared_examples_for(name, *args, &block); end - # source://rspec-core/3.12.2/lib/rspec/core.rb#160 + # source://rspec-core/3.13.0/lib/rspec/core.rb#160 def world; end - # source://rspec-core/3.12.2/lib/rspec/core.rb#49 + # source://rspec-core/3.13.0/lib/rspec/core.rb#49 def world=(_arg0); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xcontext(*args, &example_group_block); end - # source://rspec-core/3.12.2/lib/rspec/core/dsl.rb#42 + # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42 def xdescribe(*args, &example_group_block); end end end @@ -82,18 +83,18 @@ end # the code using the library, which is far more useful than the particular # internal method that raised an error. # -# source://rspec-support//lib/rspec/support/caller_filter.rb#8 +# source://rspec-support//lib/rspec/support/caller_filter.rb#10 class RSpec::CallerFilter class << self # Earlier rubies do not support the two argument form of `caller`. This # fallback is logically the same, but slower. # - # source://rspec-support//lib/rspec/support/caller_filter.rb#47 + # source://rspec-support//lib/rspec/support/caller_filter.rb#49 def first_non_rspec_line(skip_frames = T.unsafe(nil), increment = T.unsafe(nil)); end end end -# source://rspec-support//lib/rspec/support/caller_filter.rb#18 +# source://rspec-support//lib/rspec/support/caller_filter.rb#20 RSpec::CallerFilter::ADDITIONAL_TOP_LEVEL_FILES = T.let(T.unsafe(nil), Array) # rubygems/core_ext/kernel_require.rb isn't actually part of rspec (obviously) but we want @@ -103,29 +104,23 @@ RSpec::CallerFilter::ADDITIONAL_TOP_LEVEL_FILES = T.let(T.unsafe(nil), Array) # file, but it depends on if rubygems is loaded or not. We don't want to have to deal # with this complexity in our `RSpec.deprecate` calls, so we ignore it here. # -# source://rspec-support//lib/rspec/support/caller_filter.rb#28 +# source://rspec-support//lib/rspec/support/caller_filter.rb#30 RSpec::CallerFilter::IGNORE_REGEX = T.let(T.unsafe(nil), Regexp) -# source://rspec-support//lib/rspec/support/caller_filter.rb#20 +# source://rspec-support//lib/rspec/support/caller_filter.rb#22 RSpec::CallerFilter::LIB_REGEX = T.let(T.unsafe(nil), Regexp) -# source://rspec-support//lib/rspec/support/caller_filter.rb#9 +# source://rspec-support//lib/rspec/support/caller_filter.rb#11 RSpec::CallerFilter::RSPEC_LIBS = T.let(T.unsafe(nil), Array) -# source://rspec-core/3.12.2/lib/rspec/core.rb#187 -RSpec::MODULES_TO_AUTOLOAD = T.let(T.unsafe(nil), Hash) - -# source://rspec-core/3.12.2/lib/rspec/core/shared_context.rb#54 -RSpec::SharedContext = RSpec::Core::SharedContext - -# source://rspec-support//lib/rspec/support.rb#2 +# source://rspec-support//lib/rspec/support.rb#4 module RSpec::Support class << self # Used internally to get a class of a given object, even if it does not respond to #class. # # @api private # - # source://rspec-support//lib/rspec/support.rb#84 + # source://rspec-support//lib/rspec/support.rb#86 def class_of(object); end # Defines a helper method that is optimized to require files from the @@ -140,7 +135,7 @@ module RSpec::Support # # @api private # - # source://rspec-support//lib/rspec/support.rb#14 + # source://rspec-support//lib/rspec/support.rb#16 def define_optimized_require_for_rspec(lib, &require_relative); end # Remove a previously registered matcher. Useful for cleaning up after @@ -148,36 +143,36 @@ module RSpec::Support # # @private # - # source://rspec-support//lib/rspec/support/matcher_definition.rb#22 + # source://rspec-support//lib/rspec/support/matcher_definition.rb#24 def deregister_matcher_definition(&block); end # @api private # - # source://rspec-support//lib/rspec/support.rb#105 + # source://rspec-support//lib/rspec/support.rb#113 def failure_notifier; end # @api private # - # source://rspec-support//lib/rspec/support.rb#97 + # source://rspec-support//lib/rspec/support.rb#105 def failure_notifier=(callable); end # @private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/matcher_definition.rb#27 + # source://rspec-support//lib/rspec/support/matcher_definition.rb#29 def is_a_matcher?(object); end # @private # - # source://rspec-support//lib/rspec/support/matcher_definition.rb#4 + # source://rspec-support//lib/rspec/support/matcher_definition.rb#6 def matcher_definitions; end - # source://rspec-support//lib/rspec/support.rb#52 + # source://rspec-support//lib/rspec/support.rb#54 def method_handle_for(object, method_name); end # @api private # - # source://rspec-support//lib/rspec/support.rb#110 + # source://rspec-support//lib/rspec/support.rb#118 def notify_failure(failure, options = T.unsafe(nil)); end # Used internally to break cyclic dependency between mocks, expectations, @@ -187,59 +182,57 @@ module RSpec::Support # # @private # - # source://rspec-support//lib/rspec/support/matcher_definition.rb#14 + # source://rspec-support//lib/rspec/support/matcher_definition.rb#16 def register_matcher_definition(&block); end - # source://rspec-support//lib/rspec/support.rb#23 + # source://rspec-support//lib/rspec/support.rb#25 def require_rspec_core(f); end - # source://rspec-support//lib/rspec/support.rb#23 + # source://rspec-support//lib/rspec/support.rb#25 def require_rspec_expectations(f); end - # source://rspec-support//lib/rspec/support.rb#23 + # source://rspec-support//lib/rspec/support.rb#25 def require_rspec_matchers(f); end - # source://rspec-support//lib/rspec/support.rb#23 + # source://rspec-support//lib/rspec/support.rb#25 def require_rspec_mocks(f); end - # source://rspec-support//lib/rspec/support.rb#23 + # source://rspec-support//lib/rspec/support.rb#25 def require_rspec_support(f); end # gives a string representation of an object for use in RSpec descriptions # # @api private # - # source://rspec-support//lib/rspec/support/matcher_definition.rb#34 + # source://rspec-support//lib/rspec/support/matcher_definition.rb#36 def rspec_description_for_object(object); end - # A single thread local variable so we don't excessively pollute that namespace. - # - # source://rspec-support//lib/rspec/support.rb#92 + # source://rspec-support//lib/rspec/support.rb#95 def thread_local_data; end # @api private # - # source://rspec-support//lib/rspec/support.rb#132 + # source://rspec-support//lib/rspec/support.rb#140 def warning_notifier; end # @api private # - # source://rspec-support//lib/rspec/support.rb#125 + # source://rspec-support//lib/rspec/support.rb#133 def warning_notifier=(_arg0); end # @api private # - # source://rspec-support//lib/rspec/support.rb#115 + # source://rspec-support//lib/rspec/support.rb#123 def with_failure_notifier(callable); end end end # @private # -# source://rspec-support//lib/rspec/support.rb#137 +# source://rspec-support//lib/rspec/support.rb#145 module RSpec::Support::AllExceptionsExceptOnesWeMustNotRescue class << self - # source://rspec-support//lib/rspec/support.rb#142 + # source://rspec-support//lib/rspec/support.rb#150 def ===(exception); end end end @@ -247,7 +240,7 @@ end # These exceptions are dangerous to rescue as rescuing them # would interfere with things we should not interfere with. # -# source://rspec-support//lib/rspec/support.rb#140 +# source://rspec-support//lib/rspec/support.rb#148 RSpec::Support::AllExceptionsExceptOnesWeMustNotRescue::AVOID_RESCUING = T.let(T.unsafe(nil), Array) # Deals with the slightly different semantics of block arguments. @@ -260,144 +253,144 @@ RSpec::Support::AllExceptionsExceptOnesWeMustNotRescue::AVOID_RESCUING = T.let(T # # @api private # -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#266 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#268 class RSpec::Support::BlockSignature < ::RSpec::Support::MethodSignature # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#268 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#270 def classify_parameters; end end # @private # -# source://rspec-support//lib/rspec/support/comparable_version.rb#4 +# source://rspec-support//lib/rspec/support/comparable_version.rb#6 class RSpec::Support::ComparableVersion include ::Comparable # @return [ComparableVersion] a new instance of ComparableVersion # - # source://rspec-support//lib/rspec/support/comparable_version.rb#9 + # source://rspec-support//lib/rspec/support/comparable_version.rb#11 def initialize(string); end - # source://rspec-support//lib/rspec/support/comparable_version.rb#13 + # source://rspec-support//lib/rspec/support/comparable_version.rb#15 def <=>(other); end - # source://rspec-support//lib/rspec/support/comparable_version.rb#35 + # source://rspec-support//lib/rspec/support/comparable_version.rb#37 def segments; end # Returns the value of attribute string. # - # source://rspec-support//lib/rspec/support/comparable_version.rb#7 + # source://rspec-support//lib/rspec/support/comparable_version.rb#9 def string; end end # @private # -# source://rspec-support//lib/rspec/support.rb#102 +# source://rspec-support//lib/rspec/support.rb#110 RSpec::Support::DEFAULT_FAILURE_NOTIFIER = T.let(T.unsafe(nil), Proc) # @private # -# source://rspec-support//lib/rspec/support.rb#129 +# source://rspec-support//lib/rspec/support.rb#137 RSpec::Support::DEFAULT_WARNING_NOTIFIER = T.let(T.unsafe(nil), Proc) -# source://rspec-support//lib/rspec/support/differ.rb#10 +# source://rspec-support//lib/rspec/support/differ.rb#12 class RSpec::Support::Differ # @return [Differ] a new instance of Differ # - # source://rspec-support//lib/rspec/support/differ.rb#67 + # source://rspec-support//lib/rspec/support/differ.rb#69 def initialize(opts = T.unsafe(nil)); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/differ.rb#63 + # source://rspec-support//lib/rspec/support/differ.rb#65 def color?; end - # source://rspec-support//lib/rspec/support/differ.rb#11 + # source://rspec-support//lib/rspec/support/differ.rb#13 def diff(actual, expected); end - # source://rspec-support//lib/rspec/support/differ.rb#57 + # source://rspec-support//lib/rspec/support/differ.rb#59 def diff_as_object(actual, expected); end - # source://rspec-support//lib/rspec/support/differ.rb#28 + # source://rspec-support//lib/rspec/support/differ.rb#30 def diff_as_string(actual, expected); end private - # source://rspec-support//lib/rspec/support/differ.rb#128 + # source://rspec-support//lib/rspec/support/differ.rb#130 def add_old_hunk_to_hunk(hunk, oldhunk); end - # source://rspec-support//lib/rspec/support/differ.rb#124 + # source://rspec-support//lib/rspec/support/differ.rb#126 def add_to_output(output, string); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/differ.rb#78 + # source://rspec-support//lib/rspec/support/differ.rb#80 def all_strings?(*args); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/differ.rb#82 + # source://rspec-support//lib/rspec/support/differ.rb#84 def any_multiline_strings?(*args); end - # source://rspec-support//lib/rspec/support/differ.rb#153 + # source://rspec-support//lib/rspec/support/differ.rb#155 def blue(text); end - # source://rspec-support//lib/rspec/support/differ.rb#115 + # source://rspec-support//lib/rspec/support/differ.rb#117 def build_hunks(actual, expected); end - # source://rspec-support//lib/rspec/support/differ.rb#90 + # source://rspec-support//lib/rspec/support/differ.rb#92 def coerce_to_string(string_or_array); end - # source://rspec-support//lib/rspec/support/differ.rb#141 + # source://rspec-support//lib/rspec/support/differ.rb#143 def color(text, color_code); end - # source://rspec-support//lib/rspec/support/differ.rb#161 + # source://rspec-support//lib/rspec/support/differ.rb#163 def color_diff(diff); end - # source://rspec-support//lib/rspec/support/differ.rb#95 + # source://rspec-support//lib/rspec/support/differ.rb#97 def diffably_stringify(array); end - # source://rspec-support//lib/rspec/support/differ.rb#119 + # source://rspec-support//lib/rspec/support/differ.rb#121 def finalize_output(output, final_line); end - # source://rspec-support//lib/rspec/support/differ.rb#137 + # source://rspec-support//lib/rspec/support/differ.rb#139 def format_type; end - # source://rspec-support//lib/rspec/support/differ.rb#149 + # source://rspec-support//lib/rspec/support/differ.rb#151 def green(text); end - # source://rspec-support//lib/rspec/support/differ.rb#202 + # source://rspec-support//lib/rspec/support/differ.rb#204 def handle_encoding_errors(actual, expected); end - # source://rspec-support//lib/rspec/support/differ.rb#192 + # source://rspec-support//lib/rspec/support/differ.rb#194 def hash_to_string(hash); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/differ.rb#106 + # source://rspec-support//lib/rspec/support/differ.rb#108 def multiline?(string); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/differ.rb#86 + # source://rspec-support//lib/rspec/support/differ.rb#88 def no_numbers?(*args); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/differ.rb#74 + # source://rspec-support//lib/rspec/support/differ.rb#76 def no_procs?(*args); end - # source://rspec-support//lib/rspec/support/differ.rb#157 + # source://rspec-support//lib/rspec/support/differ.rb#159 def normal(text); end - # source://rspec-support//lib/rspec/support/differ.rb#178 + # source://rspec-support//lib/rspec/support/differ.rb#180 def object_to_string(object); end - # source://rspec-support//lib/rspec/support/differ.rb#145 + # source://rspec-support//lib/rspec/support/differ.rb#147 def red(text); end - # source://rspec-support//lib/rspec/support/differ.rb#132 + # source://rspec-support//lib/rspec/support/differ.rb#134 def safely_flatten(array); end end @@ -406,14 +399,14 @@ end # # @api private # -# source://rspec-support//lib/rspec/support/directory_maker.rb#9 +# source://rspec-support//lib/rspec/support/directory_maker.rb#11 class RSpec::Support::DirectoryMaker class << self # Implements nested directory construction # # @api private # - # source://rspec-support//lib/rspec/support/directory_maker.rb#13 + # source://rspec-support//lib/rspec/support/directory_maker.rb#15 def mkdir_p(path); end private @@ -421,65 +414,65 @@ class RSpec::Support::DirectoryMaker # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/directory_maker.rb#55 + # source://rspec-support//lib/rspec/support/directory_maker.rb#57 def directory_exists?(dirname); end # @api private # - # source://rspec-support//lib/rspec/support/directory_maker.rb#50 + # source://rspec-support//lib/rspec/support/directory_maker.rb#52 def generate_path(stack, part); end # @api private # - # source://rspec-support//lib/rspec/support/directory_maker.rb#47 + # source://rspec-support//lib/rspec/support/directory_maker.rb#49 def generate_stack(path); end end end # @private # -# source://rspec-support//lib/rspec/support/encoded_string.rb#4 +# source://rspec-support//lib/rspec/support/encoded_string.rb#6 class RSpec::Support::EncodedString # @return [EncodedString] a new instance of EncodedString # - # source://rspec-support//lib/rspec/support/encoded_string.rb#14 + # source://rspec-support//lib/rspec/support/encoded_string.rb#16 def initialize(string, encoding = T.unsafe(nil)); end - # source://rspec-support//lib/rspec/support/encoded_string.rb#26 + # source://rspec-support//lib/rspec/support/encoded_string.rb#28 def <<(string); end - # source://rspec-support//lib/rspec/support/encoded_string.rb#23 + # source://rspec-support//lib/rspec/support/encoded_string.rb#25 def ==(*args, &block); end - # source://rspec-support//lib/rspec/support/encoded_string.rb#23 + # source://rspec-support//lib/rspec/support/encoded_string.rb#25 def empty?(*args, &block); end - # source://rspec-support//lib/rspec/support/encoded_string.rb#23 + # source://rspec-support//lib/rspec/support/encoded_string.rb#25 def encoding(*args, &block); end - # source://rspec-support//lib/rspec/support/encoded_string.rb#23 + # source://rspec-support//lib/rspec/support/encoded_string.rb#25 def eql?(*args, &block); end - # source://rspec-support//lib/rspec/support/encoded_string.rb#23 + # source://rspec-support//lib/rspec/support/encoded_string.rb#25 def lines(*args, &block); end # Returns the value of attribute source_encoding. # - # source://rspec-support//lib/rspec/support/encoded_string.rb#19 + # source://rspec-support//lib/rspec/support/encoded_string.rb#21 def source_encoding; end - # source://rspec-support//lib/rspec/support/encoded_string.rb#39 + # source://rspec-support//lib/rspec/support/encoded_string.rb#41 def split(regex_or_string); end - # source://rspec-support//lib/rspec/support/encoded_string.rb#44 + # source://rspec-support//lib/rspec/support/encoded_string.rb#46 def to_s; end - # source://rspec-support//lib/rspec/support/encoded_string.rb#44 + # source://rspec-support//lib/rspec/support/encoded_string.rb#46 def to_str; end private - # source://rspec-support//lib/rspec/support/encoded_string.rb#137 + # source://rspec-support//lib/rspec/support/encoded_string.rb#139 def detect_source_encoding(string); end # Encoding Exceptions: @@ -521,7 +514,7 @@ class RSpec::Support::EncodedString # RangeError: out of char range # e.g. the UTF-16LE emoji: 128169.chr # - # source://rspec-support//lib/rspec/support/encoded_string.rb#91 + # source://rspec-support//lib/rspec/support/encoded_string.rb#93 def matching_encoding(string); end # http://stackoverflow.com/a/8711118/879854 @@ -529,11 +522,11 @@ class RSpec::Support::EncodedString # with invalid encoding, which is a pretty good proxy # for the invalid byte sequence that causes an ArgumentError # - # source://rspec-support//lib/rspec/support/encoded_string.rb#122 + # source://rspec-support//lib/rspec/support/encoded_string.rb#124 def remove_invalid_bytes(string); end class << self - # source://rspec-support//lib/rspec/support/encoded_string.rb#141 + # source://rspec-support//lib/rspec/support/encoded_string.rb#143 def pick_encoding(source_a, source_b); end end end @@ -542,28 +535,28 @@ end # U+FFFD ("\xEF\xBF\xBD"), for Unicode encoding forms, else # ? ("\x3F") # -# source://rspec-support//lib/rspec/support/encoded_string.rb#12 +# source://rspec-support//lib/rspec/support/encoded_string.rb#14 RSpec::Support::EncodedString::REPLACE = T.let(T.unsafe(nil), String) -# source://rspec-support//lib/rspec/support/encoded_string.rb#7 +# source://rspec-support//lib/rspec/support/encoded_string.rb#9 RSpec::Support::EncodedString::US_ASCII = T.let(T.unsafe(nil), String) # Reduce allocations by storing constants. # -# source://rspec-support//lib/rspec/support/encoded_string.rb#6 +# source://rspec-support//lib/rspec/support/encoded_string.rb#8 RSpec::Support::EncodedString::UTF_8 = T.let(T.unsafe(nil), String) # Provides a means to fuzzy-match between two arbitrary objects. # Understands array/hash nesting. Uses `===` or `==` to # perform the matching. # -# source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#6 +# source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#8 module RSpec::Support::FuzzyMatcher class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#8 + # source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#10 def values_match?(expected, actual); end private @@ -571,50 +564,50 @@ module RSpec::Support::FuzzyMatcher # @private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#27 + # source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#29 def arrays_match?(expected_list, actual_list); end # @private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#36 + # source://rspec-support//lib/rspec/support/fuzzy_matcher.rb#38 def hashes_match?(expected_hash, actual_hash); end end end # @private # -# source://rspec-support//lib/rspec/support/hunk_generator.rb#7 +# source://rspec-support//lib/rspec/support/hunk_generator.rb#9 class RSpec::Support::HunkGenerator # @return [HunkGenerator] a new instance of HunkGenerator # - # source://rspec-support//lib/rspec/support/hunk_generator.rb#8 + # source://rspec-support//lib/rspec/support/hunk_generator.rb#10 def initialize(actual, expected); end - # source://rspec-support//lib/rspec/support/hunk_generator.rb#13 + # source://rspec-support//lib/rspec/support/hunk_generator.rb#15 def hunks; end private - # source://rspec-support//lib/rspec/support/hunk_generator.rb#30 + # source://rspec-support//lib/rspec/support/hunk_generator.rb#32 def actual_lines; end - # source://rspec-support//lib/rspec/support/hunk_generator.rb#34 + # source://rspec-support//lib/rspec/support/hunk_generator.rb#36 def build_hunk(piece); end - # source://rspec-support//lib/rspec/support/hunk_generator.rb#42 + # source://rspec-support//lib/rspec/support/hunk_generator.rb#44 def context_lines; end - # source://rspec-support//lib/rspec/support/hunk_generator.rb#22 + # source://rspec-support//lib/rspec/support/hunk_generator.rb#24 def diffs; end - # source://rspec-support//lib/rspec/support/hunk_generator.rb#26 + # source://rspec-support//lib/rspec/support/hunk_generator.rb#28 def expected_lines; end end # @api private # -# source://rspec-support//lib/rspec/support.rb#38 +# source://rspec-support//lib/rspec/support.rb#40 RSpec::Support::KERNEL_METHOD_METHOD = T.let(T.unsafe(nil), UnboundMethod) # Allows matchers to be used instead of providing keyword arguments. In @@ -622,11 +615,11 @@ RSpec::Support::KERNEL_METHOD_METHOD = T.let(T.unsafe(nil), UnboundMethod) # # @private # -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#391 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#395 class RSpec::Support::LooseSignatureVerifier < ::RSpec::Support::MethodSignatureVerifier private - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#394 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#398 def split_args(*args); end end @@ -639,30 +632,30 @@ end # # @private # -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#411 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#415 class RSpec::Support::LooseSignatureVerifier::SignatureWithKeywordArgumentsMatcher # @return [SignatureWithKeywordArgumentsMatcher] a new instance of SignatureWithKeywordArgumentsMatcher # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#412 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#416 def initialize(signature); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#432 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#436 def has_kw_args_in?(args); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#420 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#424 def invalid_kw_args_from(_kw_args); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#416 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#420 def missing_kw_args_from(_kw_args); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#424 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#428 def non_kw_args_arity_description; end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#428 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#432 def valid_non_kw_args?(*args); end end @@ -671,22 +664,22 @@ end # # @private # -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#11 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#13 class RSpec::Support::MethodSignature # @return [MethodSignature] a new instance of MethodSignature # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#14 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#16 def initialize(method); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#96 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#98 def arbitrary_kw_args?; end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#36 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#38 def classify_arity(arity = T.unsafe(nil)); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#104 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#106 def classify_parameters; end # Without considering what the last arg is, could it @@ -694,10 +687,10 @@ class RSpec::Support::MethodSignature # # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#90 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#92 def could_contain_kw_args?(args); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#49 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#51 def description; end # If the last argument is Hash, Ruby will treat only symbol keys as keyword arguments @@ -705,42 +698,42 @@ class RSpec::Support::MethodSignature # # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#82 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#84 def has_kw_args_in?(args); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#75 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#77 def invalid_kw_args_from(given_kw_args); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#12 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#14 def max_non_kw_args; end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#12 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#14 def min_non_kw_args; end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#71 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#73 def missing_kw_args_from(given_kw_args); end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#21 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#23 def non_kw_args_arity_description; end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#12 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#14 def optional_kw_args; end - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#12 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#14 def required_kw_args; end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#100 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#102 def unlimited_args?; end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#29 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#31 def valid_non_kw_args?(positional_arg_count, optional_max_arg_count = T.unsafe(nil)); end end -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#160 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#162 RSpec::Support::MethodSignature::INFINITY = T.let(T.unsafe(nil), Float) # Encapsulates expectations about the number of arguments and @@ -748,70 +741,70 @@ RSpec::Support::MethodSignature::INFINITY = T.let(T.unsafe(nil), Float) # # @api private # -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#217 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#219 class RSpec::Support::MethodSignatureExpectation # @api private # @return [MethodSignatureExpectation] a new instance of MethodSignatureExpectation # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#218 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#220 def initialize; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#245 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#247 def empty?; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#229 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#231 def expect_arbitrary_keywords; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#229 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#231 def expect_arbitrary_keywords=(_arg0); end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#229 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#231 def expect_unlimited_arguments; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#229 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#231 def expect_unlimited_arguments=(_arg0); end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#227 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#229 def keywords; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#252 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#254 def keywords=(values); end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#227 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#229 def max_count; end # @api private # @raise [ArgumentError] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#231 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#233 def max_count=(number); end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#227 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#229 def min_count; end # @api private # @raise [ArgumentError] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#238 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#240 def min_count=(number); end end @@ -819,48 +812,48 @@ end # # @api private # -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#278 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#280 class RSpec::Support::MethodSignatureVerifier # @api private # @return [MethodSignatureVerifier] a new instance of MethodSignatureVerifier # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#281 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#283 def initialize(signature, args = T.unsafe(nil)); end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#324 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#326 def error_message; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#279 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#281 def kw_args; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#279 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#281 def max_non_kw_args; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#279 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#281 def min_non_kw_args; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#279 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#281 def non_kw_args; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#316 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#318 def valid?; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#288 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#290 def with_expectation(expectation); end private @@ -868,82 +861,82 @@ class RSpec::Support::MethodSignatureVerifier # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#355 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#357 def arbitrary_kw_args?; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#351 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#353 def invalid_kw_args; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#347 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#349 def missing_kw_args; end # @api private # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#363 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#365 def split_args(*args); end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#359 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#361 def unlimited_args?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#343 + # source://rspec-support//lib/rspec/support/method_signature_verifier.rb#345 def valid_non_kw_args?; end end # On 1.9 and up, this is in core, so we just use the real one # -# source://rspec-support//lib/rspec/support/reentrant_mutex.rb#63 +# source://rspec-support//lib/rspec/support/reentrant_mutex.rb#65 class RSpec::Support::Mutex < ::Thread::Mutex class << self - # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#68 + # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#70 def new; end end end # If you mock Mutex.new you break our usage of Mutex, so -# instead we capture the original method to return Mutexs. +# instead we capture the original method to return Mutexes. # -# source://rspec-support//lib/rspec/support/reentrant_mutex.rb#66 +# source://rspec-support//lib/rspec/support/reentrant_mutex.rb#68 RSpec::Support::Mutex::NEW_MUTEX_METHOD = T.let(T.unsafe(nil), Method) # Provides query methods for different OS or OS features. # # @api private # -# source://rspec-support//lib/rspec/support/ruby_features.rb#9 +# source://rspec-support//lib/rspec/support/ruby_features.rb#11 module RSpec::Support::OS private # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#12 + # source://rspec-support//lib/rspec/support/ruby_features.rb#14 def windows?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#16 + # source://rspec-support//lib/rspec/support/ruby_features.rb#18 def windows_file_path?; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#12 + # source://rspec-support//lib/rspec/support/ruby_features.rb#14 def windows?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#16 + # source://rspec-support//lib/rspec/support/ruby_features.rb#18 def windows_file_path?; end end end @@ -953,37 +946,37 @@ end # # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#8 +# source://rspec-support//lib/rspec/support/object_formatter.rb#10 class RSpec::Support::ObjectFormatter # @api private # @return [ObjectFormatter] a new instance of ObjectFormatter # - # source://rspec-support//lib/rspec/support/object_formatter.rb#27 + # source://rspec-support//lib/rspec/support/object_formatter.rb#29 def initialize(max_formatted_output_length = T.unsafe(nil)); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#32 + # source://rspec-support//lib/rspec/support/object_formatter.rb#34 def format(object); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#11 + # source://rspec-support//lib/rspec/support/object_formatter.rb#13 def max_formatted_output_length; end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#11 + # source://rspec-support//lib/rspec/support/object_formatter.rb#13 def max_formatted_output_length=(_arg0); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#68 + # source://rspec-support//lib/rspec/support/object_formatter.rb#70 def prepare_array(array); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#92 + # source://rspec-support//lib/rspec/support/object_formatter.rb#94 def prepare_element(element); end # Prepares the provided object to be formatted by wrapping it as needed @@ -998,28 +991,28 @@ class RSpec::Support::ObjectFormatter # # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#56 + # source://rspec-support//lib/rspec/support/object_formatter.rb#58 def prepare_for_inspection(object); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#74 + # source://rspec-support//lib/rspec/support/object_formatter.rb#76 def prepare_hash(input_hash); end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#111 + # source://rspec-support//lib/rspec/support/object_formatter.rb#113 def recursive_structure?(object); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#84 + # source://rspec-support//lib/rspec/support/object_formatter.rb#86 def sort_hash_keys(input_hash); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#104 + # source://rspec-support//lib/rspec/support/object_formatter.rb#106 def with_entering_structure(structure); end private @@ -1031,7 +1024,7 @@ class RSpec::Support::ObjectFormatter # # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#266 + # source://rspec-support//lib/rspec/support/object_formatter.rb#268 def truncate_string(str, start_index, end_index); end class << self @@ -1040,24 +1033,24 @@ class RSpec::Support::ObjectFormatter # # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#15 + # source://rspec-support//lib/rspec/support/object_formatter.rb#17 def default_instance; end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#19 + # source://rspec-support//lib/rspec/support/object_formatter.rb#21 def format(object); end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#23 + # source://rspec-support//lib/rspec/support/object_formatter.rb#25 def prepare_for_inspection(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#125 +# source://rspec-support//lib/rspec/support/object_formatter.rb#127 class RSpec::Support::ObjectFormatter::BaseInspector < ::Struct # Returns the value of attribute formatter # @@ -1073,7 +1066,7 @@ class RSpec::Support::ObjectFormatter::BaseInspector < ::Struct # @api private # @raise [NotImplementedError] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#130 + # source://rspec-support//lib/rspec/support/object_formatter.rb#132 def inspect; end # Returns the value of attribute object @@ -1089,7 +1082,7 @@ class RSpec::Support::ObjectFormatter::BaseInspector < ::Struct # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#134 + # source://rspec-support//lib/rspec/support/object_formatter.rb#136 def pretty_print(pp); end class << self @@ -1099,7 +1092,7 @@ class RSpec::Support::ObjectFormatter::BaseInspector < ::Struct # @raise [NotImplementedError] # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#126 + # source://rspec-support//lib/rspec/support/object_formatter.rb#128 def can_inspect?(_object); end def inspect; end @@ -1111,106 +1104,106 @@ end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#175 +# source://rspec-support//lib/rspec/support/object_formatter.rb#177 class RSpec::Support::ObjectFormatter::BigDecimalInspector < ::RSpec::Support::ObjectFormatter::BaseInspector # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#180 + # source://rspec-support//lib/rspec/support/object_formatter.rb#182 def inspect; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#176 + # source://rspec-support//lib/rspec/support/object_formatter.rb#178 def can_inspect?(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#157 +# source://rspec-support//lib/rspec/support/object_formatter.rb#159 class RSpec::Support::ObjectFormatter::DateTimeInspector < ::RSpec::Support::ObjectFormatter::BaseInspector # ActiveSupport sometimes overrides inspect. If `ActiveSupport` is # defined use a custom format string that includes more time precision. # # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#166 + # source://rspec-support//lib/rspec/support/object_formatter.rb#168 def inspect; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#160 + # source://rspec-support//lib/rspec/support/object_formatter.rb#162 def can_inspect?(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#158 +# source://rspec-support//lib/rspec/support/object_formatter.rb#160 RSpec::Support::ObjectFormatter::DateTimeInspector::FORMAT = T.let(T.unsafe(nil), String) # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#222 +# source://rspec-support//lib/rspec/support/object_formatter.rb#224 class RSpec::Support::ObjectFormatter::DelegatorInspector < ::RSpec::Support::ObjectFormatter::BaseInspector # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#227 + # source://rspec-support//lib/rspec/support/object_formatter.rb#229 def inspect; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#223 + # source://rspec-support//lib/rspec/support/object_formatter.rb#225 def can_inspect?(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#185 +# source://rspec-support//lib/rspec/support/object_formatter.rb#187 class RSpec::Support::ObjectFormatter::DescribableMatcherInspector < ::RSpec::Support::ObjectFormatter::BaseInspector # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#190 + # source://rspec-support//lib/rspec/support/object_formatter.rb#192 def inspect; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#186 + # source://rspec-support//lib/rspec/support/object_formatter.rb#188 def can_inspect?(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#9 +# source://rspec-support//lib/rspec/support/object_formatter.rb#11 RSpec::Support::ObjectFormatter::ELLIPSIS = T.let(T.unsafe(nil), String) # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#245 +# source://rspec-support//lib/rspec/support/object_formatter.rb#247 RSpec::Support::ObjectFormatter::INSPECTOR_CLASSES = T.let(T.unsafe(nil), Array) # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#115 +# source://rspec-support//lib/rspec/support/object_formatter.rb#117 class RSpec::Support::ObjectFormatter::InspectableItem < ::Struct # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#116 + # source://rspec-support//lib/rspec/support/object_formatter.rb#118 def inspect; end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#120 + # source://rspec-support//lib/rspec/support/object_formatter.rb#122 def pretty_print(pp); end # Returns the value of attribute text @@ -1235,109 +1228,109 @@ end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#232 +# source://rspec-support//lib/rspec/support/object_formatter.rb#234 class RSpec::Support::ObjectFormatter::InspectableObjectInspector < ::RSpec::Support::ObjectFormatter::BaseInspector # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#240 + # source://rspec-support//lib/rspec/support/object_formatter.rb#242 def inspect; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#233 + # source://rspec-support//lib/rspec/support/object_formatter.rb#235 def can_inspect?(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#139 +# source://rspec-support//lib/rspec/support/object_formatter.rb#141 class RSpec::Support::ObjectFormatter::TimeInspector < ::RSpec::Support::ObjectFormatter::BaseInspector # for 1.8.7 # # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#147 + # source://rspec-support//lib/rspec/support/object_formatter.rb#149 def inspect; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#142 + # source://rspec-support//lib/rspec/support/object_formatter.rb#144 def can_inspect?(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#140 +# source://rspec-support//lib/rspec/support/object_formatter.rb#142 RSpec::Support::ObjectFormatter::TimeInspector::FORMAT = T.let(T.unsafe(nil), String) # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#195 +# source://rspec-support//lib/rspec/support/object_formatter.rb#197 class RSpec::Support::ObjectFormatter::UninspectableObjectInspector < ::RSpec::Support::ObjectFormatter::BaseInspector # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#205 + # source://rspec-support//lib/rspec/support/object_formatter.rb#207 def inspect; end # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#209 + # source://rspec-support//lib/rspec/support/object_formatter.rb#211 def klass; end # http://stackoverflow.com/a/2818916 # # @api private # - # source://rspec-support//lib/rspec/support/object_formatter.rb#214 + # source://rspec-support//lib/rspec/support/object_formatter.rb#216 def native_object_id; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/object_formatter.rb#198 + # source://rspec-support//lib/rspec/support/object_formatter.rb#200 def can_inspect?(object); end end end # @api private # -# source://rspec-support//lib/rspec/support/object_formatter.rb#196 +# source://rspec-support//lib/rspec/support/object_formatter.rb#198 RSpec::Support::ObjectFormatter::UninspectableObjectInspector::OBJECT_ID_FORMAT = T.let(T.unsafe(nil), String) # Provides recursive constant lookup methods useful for # constant stubbing. # -# source://rspec-support//lib/rspec/support/recursive_const_methods.rb#5 +# source://rspec-support//lib/rspec/support/recursive_const_methods.rb#7 module RSpec::Support::RecursiveConstMethods # @return [Boolean] # - # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#43 + # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#45 def const_defined_on?(mod, const_name); end - # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#51 + # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#53 def constants_defined_on(mod); end # @raise [NameError] # - # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#47 + # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#49 def get_const_defined_on(mod, const_name); end - # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#71 + # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#73 def normalize_const_name(const_name); end # @return [Boolean] # - # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#62 + # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#64 def recursive_const_defined?(const_name); end - # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#56 + # source://rspec-support//lib/rspec/support/recursive_const_methods.rb#58 def recursive_const_get(const_name); end end @@ -1353,22 +1346,22 @@ end # # @private # -# source://rspec-support//lib/rspec/support/reentrant_mutex.rb#14 +# source://rspec-support//lib/rspec/support/reentrant_mutex.rb#16 class RSpec::Support::ReentrantMutex # @return [ReentrantMutex] a new instance of ReentrantMutex # - # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#15 + # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#17 def initialize; end - # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#21 + # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#23 def synchronize; end private - # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#33 + # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#35 def enter; end - # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#38 + # source://rspec-support//lib/rspec/support/reentrant_mutex.rb#40 def exit; end end @@ -1376,85 +1369,85 @@ end # # @api private # -# source://rspec-support//lib/rspec/support/ruby_features.rb#24 +# source://rspec-support//lib/rspec/support/ruby_features.rb#26 module RSpec::Support::Ruby private # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#27 + # source://rspec-support//lib/rspec/support/ruby_features.rb#29 def jruby?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#35 + # source://rspec-support//lib/rspec/support/ruby_features.rb#37 def jruby_9000?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#31 + # source://rspec-support//lib/rspec/support/ruby_features.rb#33 def jruby_version; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#47 + # source://rspec-support//lib/rspec/support/ruby_features.rb#49 def mri?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#43 + # source://rspec-support//lib/rspec/support/ruby_features.rb#45 def non_mri?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#39 + # source://rspec-support//lib/rspec/support/ruby_features.rb#41 def rbx?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#51 + # source://rspec-support//lib/rspec/support/ruby_features.rb#53 def truffleruby?; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#27 + # source://rspec-support//lib/rspec/support/ruby_features.rb#29 def jruby?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#35 + # source://rspec-support//lib/rspec/support/ruby_features.rb#37 def jruby_9000?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#31 + # source://rspec-support//lib/rspec/support/ruby_features.rb#33 def jruby_version; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#47 + # source://rspec-support//lib/rspec/support/ruby_features.rb#49 def mri?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#43 + # source://rspec-support//lib/rspec/support/ruby_features.rb#45 def non_mri?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#39 + # source://rspec-support//lib/rspec/support/ruby_features.rb#41 def rbx?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#51 + # source://rspec-support//lib/rspec/support/ruby_features.rb#53 def truffleruby?; end end end @@ -1464,18 +1457,18 @@ end # # @api private # -# source://rspec-support//lib/rspec/support/ruby_features.rb#60 +# source://rspec-support//lib/rspec/support/ruby_features.rb#62 module RSpec::Support::RubyFeatures private # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#83 + # source://rspec-support//lib/rspec/support/ruby_features.rb#85 def caller_locations_supported?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#132 + # source://rspec-support//lib/rspec/support/ruby_features.rb#155 def distincts_kw_args_from_positional_hash?; end # On JRuby 1.7 `--1.8` mode, `Process.respond_to?(:fork)` returns true, @@ -1488,131 +1481,151 @@ module RSpec::Support::RubyFeatures # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#74 + # source://rspec-support//lib/rspec/support/ruby_features.rb#76 def fork_supported?; end + # https://rubyreferences.github.io/rubychanges/3.0.html#keyword-arguments-are-now-fully-separated-from-positional-arguments + # + # @api private + # @return [Boolean] + # + # source://rspec-support//lib/rspec/support/ruby_features.rb#111 + def kw_arg_separation?; end + # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#137 + # source://rspec-support//lib/rspec/support/ruby_features.rb#160 def kw_args_supported?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#193 + # source://rspec-support//lib/rspec/support/ruby_features.rb#216 def module_prepends_supported?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#189 + # source://rspec-support//lib/rspec/support/ruby_features.rb#212 def module_refinement_supported?; end # @api private # - # source://rspec-support//lib/rspec/support/ruby_features.rb#79 + # source://rspec-support//lib/rspec/support/ruby_features.rb#81 def optional_and_splat_args_supported?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#141 + # source://rspec-support//lib/rspec/support/ruby_features.rb#164 def required_kw_args_supported?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#123 + # source://rspec-support//lib/rspec/support/ruby_features.rb#146 def ripper_supported?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#88 + # source://rspec-support//lib/rspec/support/ruby_features.rb#90 def supports_exception_cause?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#145 + # source://rspec-support//lib/rspec/support/ruby_features.rb#168 def supports_rebinding_module_methods?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#98 + # source://rspec-support//lib/rspec/support/ruby_features.rb#100 + def supports_syntax_suggest?; end + + # @api private + # @return [Boolean] + # + # source://rspec-support//lib/rspec/support/ruby_features.rb#121 def supports_taint?; end class << self # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#83 + # source://rspec-support//lib/rspec/support/ruby_features.rb#85 def caller_locations_supported?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#132 + # source://rspec-support//lib/rspec/support/ruby_features.rb#155 def distincts_kw_args_from_positional_hash?; end - # source://rspec-support//lib/rspec/support/ruby_features.rb#74 + # source://rspec-support//lib/rspec/support/ruby_features.rb#76 def fork_supported?; end - # source://rspec-support//lib/rspec/support/ruby_features.rb#137 + # source://rspec-support//lib/rspec/support/ruby_features.rb#111 + def kw_arg_separation?; end + + # source://rspec-support//lib/rspec/support/ruby_features.rb#160 def kw_args_supported?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#193 + # source://rspec-support//lib/rspec/support/ruby_features.rb#216 def module_prepends_supported?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#189 + # source://rspec-support//lib/rspec/support/ruby_features.rb#212 def module_refinement_supported?; end # @api private # @return [Boolean] # - # source://rspec-support//lib/rspec/support/ruby_features.rb#79 + # source://rspec-support//lib/rspec/support/ruby_features.rb#81 def optional_and_splat_args_supported?; end - # source://rspec-support//lib/rspec/support/ruby_features.rb#141 + # source://rspec-support//lib/rspec/support/ruby_features.rb#164 def required_kw_args_supported?; end - # source://rspec-support//lib/rspec/support/ruby_features.rb#123 + # source://rspec-support//lib/rspec/support/ruby_features.rb#146 def ripper_supported?; end - # source://rspec-support//lib/rspec/support/ruby_features.rb#88 + # source://rspec-support//lib/rspec/support/ruby_features.rb#90 def supports_exception_cause?; end - # source://rspec-support//lib/rspec/support/ruby_features.rb#145 + # source://rspec-support//lib/rspec/support/ruby_features.rb#168 def supports_rebinding_module_methods?; end - # source://rspec-support//lib/rspec/support/ruby_features.rb#98 + # source://rspec-support//lib/rspec/support/ruby_features.rb#100 + def supports_syntax_suggest?; end + + # source://rspec-support//lib/rspec/support/ruby_features.rb#121 def supports_taint?; end end end -# Figures out wether a given method can accept various arguments. +# Figures out whether a given method can accept various arguments. # Surprisingly non-trivial. # # @private # -# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#385 +# source://rspec-support//lib/rspec/support/method_signature_verifier.rb#389 RSpec::Support::StrictSignatureVerifier = RSpec::Support::MethodSignatureVerifier -# source://rspec-support//lib/rspec/support/version.rb#3 +# source://rspec-support//lib/rspec/support/version.rb#5 module RSpec::Support::Version; end -# source://rspec-support//lib/rspec/support/version.rb#4 +# source://rspec-support//lib/rspec/support/version.rb#6 RSpec::Support::Version::STRING = T.let(T.unsafe(nil), String) -# source://rspec-support//lib/rspec/support/warnings.rb#6 +# source://rspec-support//lib/rspec/support/warnings.rb#8 module RSpec::Support::Warnings - # source://rspec-support//lib/rspec/support/warnings.rb#7 + # source://rspec-support//lib/rspec/support/warnings.rb#9 def deprecate(deprecated, options = T.unsafe(nil)); end # Used internally to print deprecation warnings @@ -1620,36 +1633,36 @@ module RSpec::Support::Warnings # # @private # - # source://rspec-support//lib/rspec/support/warnings.rb#15 + # source://rspec-support//lib/rspec/support/warnings.rb#17 def warn_deprecation(message, options = T.unsafe(nil)); end # Used internally to print longer warnings # # @private # - # source://rspec-support//lib/rspec/support/warnings.rb#29 + # source://rspec-support//lib/rspec/support/warnings.rb#31 def warn_with(message, options = T.unsafe(nil)); end # Used internally to print warnings # # @private # - # source://rspec-support//lib/rspec/support/warnings.rb#22 + # source://rspec-support//lib/rspec/support/warnings.rb#24 def warning(text, options = T.unsafe(nil)); end end -# source://rspec-support//lib/rspec/support/with_keywords_when_needed.rb#5 +# source://rspec-support//lib/rspec/support/with_keywords_when_needed.rb#7 module RSpec::Support::WithKeywordsWhenNeeded private # Remove this in RSpec 4 in favour of explicitly passed in kwargs where # this is used. Works around a warning in Ruby 2.7 # - # source://rspec-support//lib/rspec/support/with_keywords_when_needed.rb#15 + # source://rspec-support//lib/rspec/support/with_keywords_when_needed.rb#17 def class_exec(klass, *args, **_arg2, &block); end class << self - # source://rspec-support//lib/rspec/support/with_keywords_when_needed.rb#15 + # source://rspec-support//lib/rspec/support/with_keywords_when_needed.rb#17 def class_exec(klass, *args, **_arg2, &block); end end end diff --git a/sorbet/rbi/gems/rubocop-ast@1.29.0.rbi b/sorbet/rbi/gems/rubocop-ast@1.32.0.rbi similarity index 92% rename from sorbet/rbi/gems/rubocop-ast@1.29.0.rbi rename to sorbet/rbi/gems/rubocop-ast@1.32.0.rbi index 162e6dc0e..202568017 100644 --- a/sorbet/rbi/gems/rubocop-ast@1.29.0.rbi +++ b/sorbet/rbi/gems/rubocop-ast@1.32.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rubocop-ast` gem. # Please instead update this file by running `bin/tapioca gem rubocop-ast`. + class Parser::Source::Range include ::RuboCop::AST::Ext::Range end @@ -159,12 +160,16 @@ class RuboCop::AST::ArrayNode < ::RuboCop::AST::Node # # @return [Boolean] whether the array is enclosed in percent or square # - # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#60 + # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#64 def bracketed?; end - # @deprecated Use `values.each` (a.k.a. `children.each`) + # Calls the given block for each `value` node in the `array` literal. + # If no block is given, an `Enumerator` is returned. + # + # @return [self] if a block is given + # @return [Enumerator] if no block is given # - # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#21 + # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#25 def each_value(&block); end # Checks whether the `array` literal is delimited by percent brackets. @@ -173,14 +178,14 @@ class RuboCop::AST::ArrayNode < ::RuboCop::AST::Node # @overload percent_literal? # @return [Boolean] whether the array is enclosed in percent brackets # - # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#47 + # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#51 def percent_literal?(type = T.unsafe(nil)); end # Checks whether the `array` literal is delimited by square brackets. # # @return [Boolean] whether the array is enclosed in square brackets # - # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#32 + # source://rubocop-ast//lib/rubocop/ast/node/array_node.rb#36 def square_brackets?; end # Returns an array of all value nodes in the `array` literal. @@ -216,7 +221,7 @@ class RuboCop::AST::AsgnNode < ::RuboCop::AST::Node end # Common functionality for primitive literal nodes: `sym`, `str`, -# `int`, `float`, ... +# `int`, `float`, `rational`... # # source://rubocop-ast//lib/rubocop/ast/node/mixin/basic_literal_node.rb#7 module RuboCop::AST::BasicLiteralNode @@ -275,7 +280,7 @@ class RuboCop::AST::BlockNode < ::RuboCop::AST::Node # # @return [Array] # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#42 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#60 def argument_list; end # The arguments of this block. @@ -285,63 +290,81 @@ class RuboCop::AST::BlockNode < ::RuboCop::AST::Node # # @return [Array] # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#30 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#48 def arguments; end # Checks whether this block takes any arguments. # # @return [Boolean] whether this `block` node takes any arguments # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#67 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#85 def arguments?; end # The body of this block. # # @return [Node, nil] the body of the `block` node or `nil` # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#53 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#71 def body; end # Checks whether the `block` literal is delimited by curly braces. # # @return [Boolean] whether the `block` literal is enclosed in braces # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#74 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#92 def braces?; end # The closing delimiter for this `block` literal. # # @return [String] the closing delimiter for the `block` literal # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#102 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#120 def closing_delimiter; end # The delimiters for this `block` literal. # # @return [Array] the delimiters for the `block` literal # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#88 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#106 def delimiters; end + # A shorthand for getting the first argument of this block. + # Equivalent to `arguments.first`. + # + # @return [Node, nil] the first argument of this block, + # or `nil` if there are no arguments + # + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#29 + def first_argument; end + # Checks whether the `block` literal is delimited by `do`-`end` keywords. # # @return [Boolean] whether the `block` literal is enclosed in `do`-`end` # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#81 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#99 def keywords?; end # Checks whether this `block` literal belongs to a lambda. # # @return [Boolean] whether the `block` literal belongs to a lambda # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#125 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#143 def lambda?; end + # A shorthand for getting the last argument of this block. + # Equivalent to `arguments.last`. + # + # @return [Node, nil] the last argument of this block, + # or `nil` if there are no arguments + # + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#38 + def last_argument; end + # The name of the dispatched method as a symbol. # # @return [Symbol] the name of the dispatched method # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#60 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#78 def method_name; end # Checks whether this is a multiline block. This is overridden here @@ -349,14 +372,14 @@ class RuboCop::AST::BlockNode < ::RuboCop::AST::Node # # @return [Boolean] whether the `block` literal is on a several lines # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#118 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#136 def multiline?; end # The opening delimiter for this `block` literal. # # @return [String] the opening delimiter for the `block` literal # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#95 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#113 def opening_delimiter; end # The `send` node associated with this block. @@ -371,21 +394,21 @@ class RuboCop::AST::BlockNode < ::RuboCop::AST::Node # # @return [Boolean] whether the `block` literal is on a single line # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#110 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#128 def single_line?; end # Checks whether this node body is a void context. # # @return [Boolean] whether the `block` node body is a void context # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#132 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#150 def void_context?; end private # Numbered arguments of this `numblock`. # - # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#139 + # source://rubocop-ast//lib/rubocop/ast/node/block_node.rb#157 def numbered_arguments; end end @@ -420,18 +443,18 @@ class RuboCop::AST::Builder < ::Parser::Builders::Default # # @return [Node] the generated node # - # source://rubocop-ast//lib/rubocop/ast/builder.rb#98 + # source://rubocop-ast//lib/rubocop/ast/builder.rb#99 def n(type, children, source_map); end # TODO: Figure out what to do about literal encoding handling... # More details here https://github.com/whitequark/parser/issues/283 # - # source://rubocop-ast//lib/rubocop/ast/builder.rb#104 + # source://rubocop-ast//lib/rubocop/ast/builder.rb#105 def string_value(token); end private - # source://rubocop-ast//lib/rubocop/ast/builder.rb#110 + # source://rubocop-ast//lib/rubocop/ast/builder.rb#111 def node_klass(type); end end @@ -1069,9 +1092,6 @@ module RuboCop::AST::CollectionNode # source://forwardable/1.3.3/forwardable.rb#231 def to_ary(*args, **_arg1, &block); end - # source://forwardable/1.3.3/forwardable.rb#231 - def to_default_s(*args, **_arg1, &block); end - # source://forwardable/1.3.3/forwardable.rb#231 def to_formatted_s(*args, **_arg1, &block); end @@ -1081,6 +1101,9 @@ module RuboCop::AST::CollectionNode # source://forwardable/1.3.3/forwardable.rb#231 def to_h(*args, **_arg1, &block); end + # source://forwardable/1.3.3/forwardable.rb#231 + def to_msgpack(*args, **_arg1, &block); end + # source://forwardable/1.3.3/forwardable.rb#231 def to_sentence(*args, **_arg1, &block); end @@ -1424,11 +1447,6 @@ module RuboCop::AST::Ext::Range def line_span(exclude_end: T.unsafe(nil)); end end -# Refinement to circumvent broken `Range#minmax` for infinity ranges in 2.6- -# -# source://rubocop-ast//lib/rubocop/ast/ext/range_min_max.rb#7 -module RuboCop::AST::Ext::RangeMinMax; end - # A node extension for `float` nodes. This will be used in place of a plain # node when the builder constructs the AST, making its methods available to # all `float` nodes within RuboCop. @@ -1821,7 +1839,7 @@ class RuboCop::AST::IfNode < ::RuboCop::AST::Node # source://rubocop-ast//lib/rubocop/ast/node/if_node.rb#80 def modifier_form?; end - # Chacks whether the `if` node has nested `if` nodes in any of its + # Checks whether the `if` node has nested `if` nodes in any of its # branches. # # @note This performs a shallow search. @@ -2627,19 +2645,19 @@ class RuboCop::AST::Node < ::Parser::AST::Node # @return [Node] a new instance of Node # @see https://www.rubydoc.info/gems/ast/AST/Node:initialize # - # source://rubocop-ast//lib/rubocop/ast/node.rb#92 + # source://rubocop-ast//lib/rubocop/ast/node.rb#113 def initialize(type, children = T.unsafe(nil), properties = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def __ENCODING___type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def __FILE___type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def __LINE___type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def alias_type?; end # Returns an array of ancestor nodes. @@ -2647,173 +2665,173 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Array] an array of ancestor nodes # - # source://rubocop-ast//lib/rubocop/ast/node.rb#247 + # source://rubocop-ast//lib/rubocop/ast/node.rb#268 def ancestors; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def and_asgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def and_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def arg_expr_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def arg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def args_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#464 + # source://rubocop-ast//lib/rubocop/ast/node.rb#474 def argument?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#468 + # source://rubocop-ast//lib/rubocop/ast/node.rb#478 def argument_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def array_pattern_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def array_pattern_with_tail_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def array_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#416 + # source://rubocop-ast//lib/rubocop/ast/node.rb#426 def assignment?; end # Some cops treat the shovel operator as a kind of assignment. # - # source://rubocop-ast//lib/rubocop/ast/node.rb#355 + # source://rubocop-ast//lib/rubocop/ast/node.rb#376 def assignment_or_similar?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def back_ref_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#420 + # source://rubocop-ast//lib/rubocop/ast/node.rb#430 def basic_conditional?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#363 + # source://rubocop-ast//lib/rubocop/ast/node.rb#384 def basic_literal?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def begin_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def block_pass_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def block_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def blockarg_expr_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def blockarg_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#472 + # source://rubocop-ast//lib/rubocop/ast/node.rb#482 def boolean_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def break_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#456 + # source://rubocop-ast//lib/rubocop/ast/node.rb#466 def call_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def case_match_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def case_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def casgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def cbase_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#460 + # source://rubocop-ast//lib/rubocop/ast/node.rb#470 def chained?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#512 + # source://rubocop-ast//lib/rubocop/ast/node.rb#522 def class_constructor?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#530 + # source://rubocop-ast//lib/rubocop/ast/node.rb#540 def class_definition?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def class_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#144 + # source://rubocop-ast//lib/rubocop/ast/node.rb#165 def complete!; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#149 + # source://rubocop-ast//lib/rubocop/ast/node.rb#170 def complete?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def complex_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#424 + # source://rubocop-ast//lib/rubocop/ast/node.rb#434 def conditional?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#293 + # source://rubocop-ast//lib/rubocop/ast/node.rb#314 def const_name; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def const_pattern_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def const_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def csend_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def cvar_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def cvasgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def def_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#314 + # source://rubocop-ast//lib/rubocop/ast/node.rb#335 def defined_module; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#319 + # source://rubocop-ast//lib/rubocop/ast/node.rb#340 def defined_module_name; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def defined_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def defs_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def dstr_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def dsym_type?; end # Calls the given block for each ancestor node from parent to root. @@ -2826,163 +2844,163 @@ class RuboCop::AST::Node < ::Parser::AST::Node # @return [Enumerator] if no block is given # @yieldparam node [Node] each ancestor node # - # source://rubocop-ast//lib/rubocop/ast/node.rb#235 + # source://rubocop-ast//lib/rubocop/ast/node.rb#256 def each_ancestor(*types, &block); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def eflipflop_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def empty_else_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#349 + # source://rubocop-ast//lib/rubocop/ast/node.rb#370 def empty_source?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def ensure_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#408 + # source://rubocop-ast//lib/rubocop/ast/node.rb#418 def equals_asgn?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def erange_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def false_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#371 + # source://rubocop-ast//lib/rubocop/ast/node.rb#392 def falsey_literal?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def find_pattern_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#261 + # source://rubocop-ast//lib/rubocop/ast/node.rb#282 def first_line; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def float_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def for_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def forward_arg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def forward_args_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def forwarded_args_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def forwarded_kwrestarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def forwarded_restarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#509 + # source://rubocop-ast//lib/rubocop/ast/node.rb#519 def global_const?(param0 = T.unsafe(nil), param1); end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#484 + # source://rubocop-ast//lib/rubocop/ast/node.rb#494 def guard_clause?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def gvar_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def gvasgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def hash_pattern_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def hash_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def ident_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def if_guard_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def if_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def iflipflop_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#379 + # source://rubocop-ast//lib/rubocop/ast/node.rb#400 def immutable_literal?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def in_match_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def in_pattern_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def index_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def indexasgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def int_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def irange_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def ivar_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def ivasgn_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#437 + # source://rubocop-ast//lib/rubocop/ast/node.rb#447 def keyword?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def kwarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def kwargs_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def kwbegin_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def kwnilarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def kwoptarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def kwrestarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def kwsplat_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#503 + # source://rubocop-ast//lib/rubocop/ast/node.rb#513 def lambda?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#506 + # source://rubocop-ast//lib/rubocop/ast/node.rb#516 def lambda_or_proc?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def lambda_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#265 + # source://rubocop-ast//lib/rubocop/ast/node.rb#286 def last_line; end # Use is discouraged, this is a potentially slow method and can lead @@ -2990,7 +3008,7 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Node, nil] the left (aka previous) sibling # - # source://rubocop-ast//lib/rubocop/ast/node.rb#187 + # source://rubocop-ast//lib/rubocop/ast/node.rb#208 def left_sibling; end # Use is discouraged, this is a potentially slow method and can lead @@ -2998,94 +3016,94 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Array] the left (aka previous) siblings # - # source://rubocop-ast//lib/rubocop/ast/node.rb#197 + # source://rubocop-ast//lib/rubocop/ast/node.rb#218 def left_siblings; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#269 + # source://rubocop-ast//lib/rubocop/ast/node.rb#290 def line_count; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#359 + # source://rubocop-ast//lib/rubocop/ast/node.rb#380 def literal?; end # NOTE: `loop { }` is a normal method call and thus not a loop keyword. # # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#433 + # source://rubocop-ast//lib/rubocop/ast/node.rb#443 def loop_keyword?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def lvar_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def lvasgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def masgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_alt_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_as_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_current_line_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#491 + # source://rubocop-ast//lib/rubocop/ast/node.rb#501 def match_guard_clause?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_nil_pattern_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_pattern_p_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_pattern_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_rest_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_var_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_with_lvasgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def match_with_trailing_comma_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def mlhs_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#537 + # source://rubocop-ast//lib/rubocop/ast/node.rb#547 def module_definition?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def module_type?; end # Predicates # # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#341 + # source://rubocop-ast//lib/rubocop/ast/node.rb#362 def multiline?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#375 + # source://rubocop-ast//lib/rubocop/ast/node.rb#396 def mutable_literal?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#671 + # source://rubocop-ast//lib/rubocop/ast/node.rb#679 def new_class_or_module_block?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def next_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def nil_type?; end # Common destructuring method. This can be used to normalize @@ -3098,95 +3116,95 @@ class RuboCop::AST::Node < ::Parser::AST::Node # source://ast/2.4.2/lib/ast/node.rb#56 def node_parts; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#275 + # source://rubocop-ast//lib/rubocop/ast/node.rb#296 def nonempty_line_count; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def not_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def nth_ref_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def numargs_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def numblock_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#476 + # source://rubocop-ast//lib/rubocop/ast/node.rb#486 def numeric_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def objc_kwarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def objc_restarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def objc_varargs_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def op_asgn_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#448 + # source://rubocop-ast//lib/rubocop/ast/node.rb#458 def operator_keyword?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def optarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def or_asgn_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def or_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def pair_type?; end # Returns the parent node, or `nil` if the receiver is a root node. # # @return [Node, nil] the parent node or `nil` # - # source://rubocop-ast//lib/rubocop/ast/node.rb#126 + # source://rubocop-ast//lib/rubocop/ast/node.rb#147 def parent; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#135 + # source://rubocop-ast//lib/rubocop/ast/node.rb#156 def parent?; end # Searching the AST # - # source://rubocop-ast//lib/rubocop/ast/node.rb#325 + # source://rubocop-ast//lib/rubocop/ast/node.rb#346 def parent_module_name; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#452 + # source://rubocop-ast//lib/rubocop/ast/node.rb#462 def parenthesized_call?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def pin_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#428 + # source://rubocop-ast//lib/rubocop/ast/node.rb#438 def post_condition_loop?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def postexe_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def preexe_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#496 + # source://rubocop-ast//lib/rubocop/ast/node.rb#506 def proc?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def procarg0_type?; end # Some expressions are evaluated for their value, some for their side @@ -3199,56 +3217,60 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#582 + # source://rubocop-ast//lib/rubocop/ast/node.rb#590 def pure?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#480 + # source://rubocop-ast//lib/rubocop/ast/node.rb#490 def range_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def rational_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#286 + # source://rubocop-ast//lib/rubocop/ast/node.rb#307 def receiver(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#386 + # @return [Boolean] + # + # source://rubocop-ast//lib/rubocop/ast/node.rb#97 def recursive_basic_literal?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#386 + # @return [Boolean] + # + # source://rubocop-ast//lib/rubocop/ast/node.rb#97 def recursive_literal?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def redo_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#404 + # source://rubocop-ast//lib/rubocop/ast/node.rb#414 def reference?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def regexp_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def regopt_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def resbody_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def rescue_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def restarg_expr_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def restarg_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def retry_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def return_type?; end # Use is discouraged, this is a potentially slow method and can lead @@ -3256,7 +3278,7 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Node, nil] the right (aka next) sibling # - # source://rubocop-ast//lib/rubocop/ast/node.rb#178 + # source://rubocop-ast//lib/rubocop/ast/node.rb#199 def right_sibling; end # Use is discouraged, this is a potentially slow method and can lead @@ -3264,18 +3286,18 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Array] the right (aka next) siblings # - # source://rubocop-ast//lib/rubocop/ast/node.rb#206 + # source://rubocop-ast//lib/rubocop/ast/node.rb#227 def right_siblings; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#140 + # source://rubocop-ast//lib/rubocop/ast/node.rb#161 def root?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def sclass_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def self_type?; end # Most nodes are of 'send' type, so this method is defined @@ -3283,15 +3305,15 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#119 + # source://rubocop-ast//lib/rubocop/ast/node.rb#140 def send_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def shadowarg_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#412 + # source://rubocop-ast//lib/rubocop/ast/node.rb#422 def shorthand_asgn?; end # Returns the index of the receiver node in its siblings. (Sibling index @@ -3300,70 +3322,70 @@ class RuboCop::AST::Node < ::Parser::AST::Node # # @return [Integer, nil] the index of the receiver node in its siblings # - # source://rubocop-ast//lib/rubocop/ast/node.rb#171 + # source://rubocop-ast//lib/rubocop/ast/node.rb#192 def sibling_index; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#345 + # source://rubocop-ast//lib/rubocop/ast/node.rb#366 def single_line?; end # NOTE: Some rare nodes may have no source, like `s(:args)` in `foo {}` # # @return [String, nil] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#253 + # source://rubocop-ast//lib/rubocop/ast/node.rb#274 def source; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#279 + # source://rubocop-ast//lib/rubocop/ast/node.rb#300 def source_length; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#257 + # source://rubocop-ast//lib/rubocop/ast/node.rb#278 def source_range; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#444 + # source://rubocop-ast//lib/rubocop/ast/node.rb#454 def special_keyword?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def splat_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#291 + # source://rubocop-ast//lib/rubocop/ast/node.rb#312 def str_content(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def str_type?; end # @deprecated Use `:class_constructor?` # - # source://rubocop-ast//lib/rubocop/ast/node.rb#525 + # source://rubocop-ast//lib/rubocop/ast/node.rb#535 def struct_constructor?(param0 = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def super_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def sym_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def true_type?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#367 + # source://rubocop-ast//lib/rubocop/ast/node.rb#388 def truthy_literal?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def undef_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def unless_guard_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def until_post_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def until_type?; end # Override `AST::Node#updated` so that `AST::Processor` does not try to @@ -3372,7 +3394,7 @@ class RuboCop::AST::Node < ::Parser::AST::Node # identical subtrees. Rather, the entire AST must be copied any time any # part of it is changed. # - # source://rubocop-ast//lib/rubocop/ast/node.rb#160 + # source://rubocop-ast//lib/rubocop/ast/node.rb#181 def updated(type = T.unsafe(nil), children = T.unsafe(nil), properties = T.unsafe(nil)); end # Some expressions are evaluated for their value, some for their side @@ -3383,76 +3405,82 @@ class RuboCop::AST::Node < ::Parser::AST::Node # So, does the return value of this node matter? If we changed it to # `(...; nil)`, might that affect anything? # - # # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#551 + # source://rubocop-ast//lib/rubocop/ast/node.rb#560 def value_used?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#400 + # source://rubocop-ast//lib/rubocop/ast/node.rb#410 def variable?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def when_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def while_post_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def while_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def xstr_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def yield_type?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#111 + # source://rubocop-ast//lib/rubocop/ast/node.rb#132 def zsuper_type?; end protected - # source://rubocop-ast//lib/rubocop/ast/node.rb#130 + # source://rubocop-ast//lib/rubocop/ast/node.rb#151 def parent=(node); end private # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#610 + # source://rubocop-ast//lib/rubocop/ast/node.rb#618 def begin_value_used?; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#621 + # source://rubocop-ast//lib/rubocop/ast/node.rb#629 def case_if_value_used?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#305 + # source://rubocop-ast//lib/rubocop/ast/node.rb#326 def defined_module0(param0 = T.unsafe(nil)); end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#615 + # source://rubocop-ast//lib/rubocop/ast/node.rb#623 def for_value_used?; end - # source://rubocop-ast//lib/rubocop/ast/node.rb#657 + # source://rubocop-ast//lib/rubocop/ast/node.rb#665 def parent_module_name_for_block(ancestor); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#645 + # source://rubocop-ast//lib/rubocop/ast/node.rb#653 def parent_module_name_for_sclass(sclass_node); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#632 + # source://rubocop-ast//lib/rubocop/ast/node.rb#640 def parent_module_name_part(node); end - # source://rubocop-ast//lib/rubocop/ast/node.rb#600 + # source://rubocop-ast//lib/rubocop/ast/node.rb#608 def visit_ancestors(types); end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node.rb#627 + # source://rubocop-ast//lib/rubocop/ast/node.rb#635 def while_until_value_used?; end + + class << self + private + + # source://rubocop-ast//lib/rubocop/ast/node.rb#92 + def def_recursive_literal_predicate(kind); end + end end # @api private @@ -3890,7 +3918,10 @@ class RuboCop::AST::NodePattern::Compiler::Binding # source://rubocop-ast//lib/rubocop/ast/node_pattern/compiler/binding.rb#16 def bind(name); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/compiler/binding.rb#30 + # Yields for each branch of the given union, forbidding unification of + # bindings which only appear in a subset of the union. + # + # source://rubocop-ast//lib/rubocop/ast/node_pattern/compiler/binding.rb#31 def union_bind(enum); end private @@ -4238,7 +4269,6 @@ end # Doc on how this fits in the compiling process: # /docs/modules/ROOT/pages/node_pattern.adoc # -# # source://rubocop-ast//lib/rubocop/ast/node_pattern/compiler/sequence_subcompiler.rb#17 class RuboCop::AST::NodePattern::Compiler::SequenceSubcompiler < ::RuboCop::AST::NodePattern::Compiler::Subcompiler # Calls `compile_sequence`; the actual `compile` method @@ -4392,6 +4422,8 @@ class RuboCop::AST::NodePattern::Compiler::SequenceSubcompiler < ::RuboCop::AST: def within_loop; end end +# Shift of 1 from standard Ruby indices +# # source://rubocop-ast//lib/rubocop/ast/node_pattern/compiler/sequence_subcompiler.rb#18 RuboCop::AST::NodePattern::Compiler::SequenceSubcompiler::DELTA = T.let(T.unsafe(nil), Integer) @@ -4524,7 +4556,7 @@ class RuboCop::AST::NodePattern::LexerRex # The current location in the parse. # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#104 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#103 def location; end # The StringScanner for this lexer. @@ -4539,22 +4571,22 @@ class RuboCop::AST::NodePattern::LexerRex # Lex the next token. # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#113 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#112 def next_token; end # Parse the given string. # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#84 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#83 def parse(str); end # Read in and parse the file at +path+. # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#94 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#93 def parse_file(path); end # The current scanner class. Must be overridden in subclasses. # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#77 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/lexer.rex.rb#76 def scanner_class; end # The StringScanner for this lexer. @@ -4704,212 +4736,212 @@ class RuboCop::AST::NodePattern::Node < ::Parser::AST::Node # # @return [Integer, Range] An Integer for fixed length terms, otherwise a Range. # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#29 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#28 def arity; end # @return [Range] arity as a Range # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#69 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#68 def arity_range; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#23 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#22 def capture?; end # @return [Node] most nodes have only one child # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#48 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#47 def child; end # @return [Array] # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#43 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#42 def children_nodes; end # @return [Array, nil] replace node with result, or `nil` if no change requested. # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#34 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#33 def in_sequence_head; end # that matches within a Set (e.g. `42`, `:sym` but not `/regexp/`) # # @return [Boolean] returns true for nodes having a Ruby literal equivalent # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#64 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#63 def matches_within_set?; end # @return [Integer] nb of captures of that node and its descendants # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#53 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#52 def nb_captures; end # To be overridden by subclasses # # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#19 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#18 def rest?; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#78 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#77 def source_range; end # @return [Boolean] returns whether it matches a variable number of elements # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#58 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#57 def variadic?; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#74 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#73 def with(type: T.unsafe(nil), children: T.unsafe(nil), location: T.unsafe(nil)); end end # Node class for `` # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#180 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#179 class RuboCop::AST::NodePattern::Node::AnyOrder < ::RuboCop::AST::NodePattern::Node include ::RuboCop::AST::NodePattern::Node::ForbidInSeqHead - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#198 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#197 def arity; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#190 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#189 def ends_with_rest?; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#194 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#193 def rest_node; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#186 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#185 def term_nodes; end end -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#183 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#182 RuboCop::AST::NodePattern::Node::AnyOrder::ARITIES = T.let(T.unsafe(nil), Hash) # Node class for `$something` # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#97 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#96 class RuboCop::AST::NodePattern::Node::Capture < ::RuboCop::AST::NodePattern::Node # source://forwardable/1.3.3/forwardable.rb#231 def arity(*args, **_arg1, &block); end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#101 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#100 def capture?; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#109 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#108 def in_sequence_head; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#105 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#104 def nb_captures; end # source://forwardable/1.3.3/forwardable.rb#231 def rest?(*args, **_arg1, &block); end end -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#86 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#85 module RuboCop::AST::NodePattern::Node::ForbidInSeqHead # @raise [NodePattern::Invalid] # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#87 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#86 def in_sequence_head; end end -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#140 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#139 RuboCop::AST::NodePattern::Node::FunctionCall = RuboCop::AST::NodePattern::Node::Predicate -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#82 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#81 RuboCop::AST::NodePattern::Node::INT_TO_RANGE = T.let(T.unsafe(nil), Hash) # Registry # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#250 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#249 RuboCop::AST::NodePattern::Node::MAP = T.let(T.unsafe(nil), Hash) -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#12 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#11 RuboCop::AST::NodePattern::Node::MATCHES_WITHIN_SET = T.let(T.unsafe(nil), Set) # Node class for `predicate?(:arg, :list)` # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#131 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#130 class RuboCop::AST::NodePattern::Node::Predicate < ::RuboCop::AST::NodePattern::Node - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#136 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#135 def arg_list; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#132 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#131 def method_name; end end # Node class for `int+` # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#143 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#142 class RuboCop::AST::NodePattern::Node::Repetition < ::RuboCop::AST::NodePattern::Node include ::RuboCop::AST::NodePattern::Node::ForbidInSeqHead - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#156 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#155 def arity; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#146 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#145 def operator; end end -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#150 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#149 RuboCop::AST::NodePattern::Node::Repetition::ARITIES = T.let(T.unsafe(nil), Hash) # Node class for `...` # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#162 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#161 class RuboCop::AST::NodePattern::Node::Rest < ::RuboCop::AST::NodePattern::Node - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#170 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#169 def arity; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#174 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#173 def in_sequence_head; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#166 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#165 def rest?; end end -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#163 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#162 RuboCop::AST::NodePattern::Node::Rest::ARITY = T.let(T.unsafe(nil), Range) # Node class for `(type first second ...)` # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#118 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#117 class RuboCop::AST::NodePattern::Node::Sequence < ::RuboCop::AST::NodePattern::Node include ::RuboCop::AST::NodePattern::Node::ForbidInSeqHead # @return [Sequence] a new instance of Sequence # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#121 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#120 def initialize(type, children = T.unsafe(nil), properties = T.unsafe(nil)); end end # A list (potentially empty) of nodes; part of a Union # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#206 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#205 class RuboCop::AST::NodePattern::Node::Subsequence < ::RuboCop::AST::NodePattern::Node include ::RuboCop::AST::NodePattern::Node::ForbidInSeqHead - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#209 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#208 def arity; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#214 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#213 def in_sequence_head; end end # Node class for `{ ... }` # -# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#224 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#223 class RuboCop::AST::NodePattern::Node::Union < ::RuboCop::AST::NodePattern::Node - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#225 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#224 def arity; end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#232 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/node.rb#231 def in_sequence_head; end end @@ -4928,116 +4960,116 @@ class RuboCop::AST::NodePattern::Parser < ::Racc::Parser # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.rb#19 def initialize(builder = T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#333 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#335 def _reduce_10(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#337 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#339 def _reduce_11(val, _values); end # reduce 12 omitted # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#343 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#345 def _reduce_13(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#347 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#349 def _reduce_14(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#351 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#353 def _reduce_15(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#355 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#357 def _reduce_16(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#359 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#361 def _reduce_17(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#363 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#365 def _reduce_18(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#367 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#369 def _reduce_19(val, _values); end # reduce 1 omitted # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#301 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#303 def _reduce_2(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#371 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#373 def _reduce_20(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#375 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#377 def _reduce_21(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#379 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#381 def _reduce_22(val, _values); end # reduce 24 omitted # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#387 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#389 def _reduce_25(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#393 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#395 def _reduce_26(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#305 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#307 def _reduce_3(val, _values); end # reduce 32 omitted # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#413 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#415 def _reduce_33(val, _values); end # reduce 36 omitted # - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#423 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#425 def _reduce_37(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#427 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#429 def _reduce_38(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#431 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#433 def _reduce_39(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#309 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#311 def _reduce_4(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#435 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#437 def _reduce_40(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#439 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#441 def _reduce_41(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#443 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#445 def _reduce_42(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#447 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#449 def _reduce_43(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#451 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#453 def _reduce_44(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#455 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#457 def _reduce_45(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#459 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#461 def _reduce_46(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#313 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#315 def _reduce_5(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#317 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#319 def _reduce_6(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#321 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#323 def _reduce_7(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#325 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#327 def _reduce_8(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#329 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#331 def _reduce_9(val, _values); end - # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#463 + # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#465 def _reduce_none(val, _values); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -5097,10 +5129,10 @@ RuboCop::AST::NodePattern::Parser::Lexer = RuboCop::AST::NodePattern::Lexer # source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#227 RuboCop::AST::NodePattern::Parser::Racc_arg = T.let(T.unsafe(nil), Array) -# source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#293 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#295 RuboCop::AST::NodePattern::Parser::Racc_debug_parser = T.let(T.unsafe(nil), FalseClass) -# source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#243 +# source://rubocop-ast//lib/rubocop/ast/node_pattern/parser.racc.rb#244 RuboCop::AST::NodePattern::Parser::Racc_token_to_s_table = T.let(T.unsafe(nil), Array) # Overrides Parser to use `WithMeta` variants and provide additional methods @@ -5248,9 +5280,6 @@ RuboCop::AST::NodePattern::Sets::SET_CLONE_DUP_FREEZE = T.let(T.unsafe(nil), Set # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_COUNT_LENGTH_SIZE = T.let(T.unsafe(nil), Set) -# source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 -RuboCop::AST::NodePattern::Sets::SET_DEFINE_METHOD = T.let(T.unsafe(nil), Set) - # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_DEFINE_METHOD_DEFINE_SINGLETON_METHOD = T.let(T.unsafe(nil), Set) @@ -5260,9 +5289,6 @@ RuboCop::AST::NodePattern::Sets::SET_EACH_WITH_INDEX_WITH_INDEX = T.let(T.unsafe # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_EACH_WITH_OBJECT_WITH_OBJECT = T.let(T.unsafe(nil), Set) -# source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 -RuboCop::AST::NodePattern::Sets::SET_ENV = T.let(T.unsafe(nil), Set) - # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_ESCAPE_ENCODE_UNESCAPE_DECODE = T.let(T.unsafe(nil), Set) @@ -5278,6 +5304,9 @@ RuboCop::AST::NodePattern::Sets::SET_FILE_DIR = T.let(T.unsafe(nil), Set) # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_FILE_FILETEST = T.let(T.unsafe(nil), Set) +# source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 +RuboCop::AST::NodePattern::Sets::SET_FILE_TEMPFILE = T.let(T.unsafe(nil), Set) + # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_FILE_TEMPFILE_STRINGIO = T.let(T.unsafe(nil), Set) @@ -5323,6 +5352,9 @@ RuboCop::AST::NodePattern::Sets::SET_LOAD_RESTORE = T.let(T.unsafe(nil), Set) # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_MAP_COLLECT = T.let(T.unsafe(nil), Set) +# source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 +RuboCop::AST::NodePattern::Sets::SET_MAP_FILTER_MAP = T.let(T.unsafe(nil), Set) + # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_MODULE_FUNCTION_RUBY2_KEYWORDS = T.let(T.unsafe(nil), Set) @@ -5345,7 +5377,7 @@ RuboCop::AST::NodePattern::Sets::SET_PIPELINE_PIPELINE_R_PIPELINE_RW_ETC = T.let RuboCop::AST::NodePattern::Sets::SET_PRESENT_ANY_BLANK_EMPTY = T.let(T.unsafe(nil), Set) # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 -RuboCop::AST::NodePattern::Sets::SET_PRIVATE_PROTECTED = T.let(T.unsafe(nil), Set) +RuboCop::AST::NodePattern::Sets::SET_PRIVATE_PROTECTED_PRIVATE_CLASS_METHOD = T.let(T.unsafe(nil), Set) # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET_PRIVATE_PROTECTED_PUBLIC = T.let(T.unsafe(nil), Set) @@ -5428,6 +5460,9 @@ RuboCop::AST::NodePattern::Sets::SET__FETCH = T.let(T.unsafe(nil), Set) # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET__GLOB = T.let(T.unsafe(nil), Set) +# source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 +RuboCop::AST::NodePattern::Sets::SET__PUSH_APPEND = T.let(T.unsafe(nil), Set) + # source://rubocop-ast//lib/rubocop/ast/node_pattern/sets.rb#10 RuboCop::AST::NodePattern::Sets::SET___ = T.let(T.unsafe(nil), Set) @@ -5485,7 +5520,7 @@ RuboCop::AST::NodePattern::Sets::SET_____2 = T.let(T.unsafe(nil), Set) # source://rubocop-ast//lib/rubocop/ast/node_pattern.rb#55 RuboCop::AST::NodePattern::VAR = T.let(T.unsafe(nil), String) -# Common functionality for primitive numeric nodes: `int`, `float`, ... +# Common functionality for primitive numeric nodes: `int`, `float`, `rational`... # # source://rubocop-ast//lib/rubocop/ast/node/mixin/numeric_node.rb#6 module RuboCop::AST::NumericNode @@ -5822,42 +5857,42 @@ end # and other information such as disabled lines for cops. # It also provides a convenient way to access source lines. # -# source://rubocop-ast//lib/rubocop/ast/processed_source.rb#11 +# source://rubocop-ast//lib/rubocop/ast/processed_source.rb#10 class RuboCop::AST::ProcessedSource # @return [ProcessedSource] a new instance of ProcessedSource # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#26 - def initialize(source, ruby_version, path = T.unsafe(nil)); end + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#28 + def initialize(source, ruby_version, path = T.unsafe(nil), parser_engine: T.unsafe(nil)); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#63 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#72 def [](*args); end # Returns the value of attribute ast. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def ast; end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#41 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#50 def ast_with_comments; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#102 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#111 def blank?; end # Returns the value of attribute buffer. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def buffer; end # Raw source checksum for tracking infinite loops. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#74 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#83 def checksum; end # @return [Comment, nil] the comment at that line, if any. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#107 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#116 def comment_at_line(line); end # Consider using `each_comment_in_lines` instead @@ -5865,173 +5900,181 @@ class RuboCop::AST::ProcessedSource # @deprecated use contains_comment? # @return [Boolean] if any of the lines in the given `source_range` has a comment. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#129 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#138 def commented?(source_range); end # Returns the value of attribute comments. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def comments; end # Should have been called `comments_before_or_at_line`. Doubtful it has of any valid use. # # @deprecated Use `each_comment_in_lines` # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#137 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#146 def comments_before_line(line); end # Consider using `each_comment_in_lines` instead # # @return [Boolean] if any of the lines in the given `source_range` has a comment. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#129 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#138 def contains_comment?(source_range); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#151 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#160 def current_line(token); end # Returns the value of attribute diagnostics. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def diagnostics; end # @deprecated Use `comments.each` # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#79 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#88 def each_comment(&block); end # Enumerates on the comments contained with the given `line_range` # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#117 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#126 def each_comment_in_lines(line_range); end # @deprecated Use `tokens.each` # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#89 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#98 def each_token(&block); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#98 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#107 def file_path; end # @deprecated Use `comment_at_line`, `each_comment_in_lines`, or `comments.find` # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#84 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#93 def find_comment(&block); end # @deprecated Use `tokens.find` # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#94 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#103 def find_token(&block); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#172 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#181 def first_token_of(range_or_node); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#155 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#164 def following_line(token); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#176 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#185 def last_token_of(range_or_node); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#159 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#168 def line_indentation(line_number); end # @return [Boolean] if the given line number has a comment. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#112 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#121 def line_with_comment?(line); end # Returns the source lines, line break characters removed, excluding a # possible __END__ and everything that comes after. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#49 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#58 def lines; end + # Returns the value of attribute parser_engine. + # + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 + def parser_engine; end + # Returns the value of attribute parser_error. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def parser_error; end # Returns the value of attribute path. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def path; end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#147 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#156 def preceding_line(token); end # Returns the value of attribute raw_source. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def raw_source; end # Returns the value of attribute ruby_version. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def ruby_version; end # The tokens list is always sorted by token position, except for cases when heredoc # is passed as a method argument. In this case tokens are interleaved by # heredoc contents' tokens. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#183 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#192 def sorted_tokens; end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#141 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#150 def start_with?(string); end # Returns the value of attribute tokens. # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#18 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#20 def tokens; end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#166 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#175 def tokens_within(range_or_node); end # @return [Boolean] # - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#67 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#76 def valid_syntax?; end private - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#190 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#199 def comment_index; end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#278 - def create_parser(ruby_version); end + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#309 + def create_parser(ruby_version, parser_engine); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#294 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#325 def first_token_index(range_or_node); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#299 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#330 def last_token_index(range_or_node); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#196 - def parse(source, ruby_version); end + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#205 + def parse(source, ruby_version, parser_engine); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#230 - def parser_class(ruby_version); end + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#238 + def parser_class(ruby_version, parser_engine); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#304 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#335 def source_range(range_or_node); end - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#213 + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#222 def tokenize(parser); end class << self - # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#21 - def from_file(path, ruby_version); end + # source://rubocop-ast//lib/rubocop/ast/processed_source.rb#23 + def from_file(path, ruby_version, parser_engine: T.unsafe(nil)); end end end -# source://rubocop-ast//lib/rubocop/ast/processed_source.rb#15 +# source://rubocop-ast//lib/rubocop/ast/processed_source.rb#14 RuboCop::AST::ProcessedSource::INVALID_LEVELS = T.let(T.unsafe(nil), Array) +# source://rubocop-ast//lib/rubocop/ast/processed_source.rb#17 +RuboCop::AST::ProcessedSource::PARSER_ENGINES = T.let(T.unsafe(nil), Array) + # @api private # -# source://rubocop-ast//lib/rubocop/ast/processed_source.rb#13 +# source://rubocop-ast//lib/rubocop/ast/processed_source.rb#12 RuboCop::AST::ProcessedSource::STRING_SOURCE_NAME = T.let(T.unsafe(nil), String) # A node extension for `irange` and `erange` nodes. This will be used in @@ -6047,6 +6090,16 @@ class RuboCop::AST::RangeNode < ::RuboCop::AST::Node def end; end end +# A node extension for `rational` nodes. This will be used in place of a plain +# node when the builder constructs the AST, making its methods available to +# all `rational` nodes within RuboCop. +# +# source://rubocop-ast//lib/rubocop/ast/node/rational_node.rb#8 +class RuboCop::AST::RationalNode < ::RuboCop::AST::Node + include ::RuboCop::AST::BasicLiteralNode + include ::RuboCop::AST::NumericNode +end + # A node extension for `regexp` nodes. This will be used in place of a plain # node when the builder constructs the AST, making its methods available # to all `regexp` nodes within RuboCop. @@ -7088,12 +7141,3 @@ class RuboCop::AST::YieldNode < ::RuboCop::AST::Node # source://rubocop-ast//lib/rubocop/ast/node/yield_node.rb#16 def node_parts; end end - -# source://rubocop/1.52.1/lib/rubocop/ast_aliases.rb#5 -RuboCop::NodePattern = RuboCop::AST::NodePattern - -# source://rubocop/1.52.1/lib/rubocop/ast_aliases.rb#6 -RuboCop::ProcessedSource = RuboCop::AST::ProcessedSource - -# source://rubocop/1.52.1/lib/rubocop/ast_aliases.rb#7 -RuboCop::Token = RuboCop::AST::Token diff --git a/sorbet/rbi/gems/rubocop@1.52.1.rbi b/sorbet/rbi/gems/rubocop@1.65.1.rbi similarity index 90% rename from sorbet/rbi/gems/rubocop@1.52.1.rbi rename to sorbet/rbi/gems/rubocop@1.65.1.rbi index cba6ddd13..15f5b9b75 100644 --- a/sorbet/rbi/gems/rubocop@1.52.1.rbi +++ b/sorbet/rbi/gems/rubocop@1.65.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rubocop` gem. # Please instead update this file by running `bin/tapioca gem rubocop`. + class Parser::Source::Comment include ::RuboCop::Ext::Comment end @@ -20,6 +21,10 @@ class Regexp::Expression::CharacterSet < ::Regexp::Expression::Subexpression include ::RuboCop::Ext::RegexpParser::Expression::CharacterSet end +class Regexp::Expression::Quantifier + include ::RuboCop::Ext::RegexpParser::Expression::Base +end + # source://rubocop//lib/rubocop/version.rb#3 module RuboCop; end @@ -93,41 +98,44 @@ class RuboCop::CLI private - # source://rubocop//lib/rubocop/cli.rb#152 + # source://rubocop//lib/rubocop/cli.rb#156 def act_on_options; end - # source://rubocop//lib/rubocop/cli.rb#186 + # source://rubocop//lib/rubocop/cli.rb#198 def apply_default_formatter; end - # source://rubocop//lib/rubocop/cli.rb#121 + # source://rubocop//lib/rubocop/cli.rb#125 def execute_runners; end + # source://rubocop//lib/rubocop/cli.rb#182 + def handle_editor_mode; end + # @raise [Finished] # - # source://rubocop//lib/rubocop/cli.rb#177 + # source://rubocop//lib/rubocop/cli.rb#187 def handle_exiting_options; end - # source://rubocop//lib/rubocop/cli.rb#140 + # source://rubocop//lib/rubocop/cli.rb#144 def parallel_by_default!; end - # source://rubocop//lib/rubocop/cli.rb#76 + # source://rubocop//lib/rubocop/cli.rb#80 def profile_if_needed; end - # source://rubocop//lib/rubocop/cli.rb#109 + # source://rubocop//lib/rubocop/cli.rb#113 def require_gem(name); end - # source://rubocop//lib/rubocop/cli.rb#117 + # source://rubocop//lib/rubocop/cli.rb#121 def run_command(name); end - # source://rubocop//lib/rubocop/cli.rb#169 + # source://rubocop//lib/rubocop/cli.rb#174 def set_options_to_config_loader; end - # source://rubocop//lib/rubocop/cli.rb#129 + # source://rubocop//lib/rubocop/cli.rb#133 def suggest_extensions; end # @raise [OptionArgumentError] # - # source://rubocop//lib/rubocop/cli.rb#133 + # source://rubocop//lib/rubocop/cli.rb#137 def validate_options_vs_config; end end @@ -162,77 +170,83 @@ end class RuboCop::CLI::Command::AutoGenerateConfig < ::RuboCop::CLI::Command::Base # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#21 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#25 def run; end private # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#97 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#107 def add_formatter; end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#105 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#115 def add_inheritance_from_auto_generated_file(config_file); end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#101 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#111 def execute_runner; end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#126 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#136 def existing_configuration(config_file); end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#59 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#65 def line_length_cop(config); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#47 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#53 def line_length_enabled?(config); end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#55 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#61 def max_line_length(config); end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#30 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#34 def maybe_run_line_length_cop; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#148 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#73 + def only_exclude?; end + + # @api private + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#162 def options_config_in_root?; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#63 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#69 def options_has_only_flag?; end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#139 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#153 def relative_path_to_todo_from_options_config; end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#90 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#100 def reset_config_and_auto_gen_file; end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#81 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#91 def run_all_cops(line_length_contents); end # Do an initial run with only Layout/LineLength so that cops that @@ -241,23 +255,23 @@ class RuboCop::CLI::Command::AutoGenerateConfig < ::RuboCop::CLI::Command::Base # # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#70 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#80 def run_line_length_cop; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#51 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#57 def same_max_line_length?(config1, config2); end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#42 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#48 def skip_line_length_cop(reason); end # @api private # - # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#132 + # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#142 def write_config_file(file_name, file_string, rubocop_yml_contents); end end @@ -268,29 +282,39 @@ RuboCop::CLI::Command::AutoGenerateConfig::AUTO_GENERATED_FILE = T.let(T.unsafe( # @api private # -# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#14 +# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#15 RuboCop::CLI::Command::AutoGenerateConfig::PHASE_1 = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#18 +# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#19 RuboCop::CLI::Command::AutoGenerateConfig::PHASE_1_DISABLED = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#17 +# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#18 RuboCop::CLI::Command::AutoGenerateConfig::PHASE_1_OVERRIDDEN = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#19 -RuboCop::CLI::Command::AutoGenerateConfig::PHASE_1_SKIPPED = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#20 +RuboCop::CLI::Command::AutoGenerateConfig::PHASE_1_SKIPPED_ONLY_COPS = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#15 +# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#22 +RuboCop::CLI::Command::AutoGenerateConfig::PHASE_1_SKIPPED_ONLY_EXCLUDE = T.let(T.unsafe(nil), String) + +# @api private +# +# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#16 RuboCop::CLI::Command::AutoGenerateConfig::PHASE_2 = T.let(T.unsafe(nil), String) +# @api private +# +# source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#13 +RuboCop::CLI::Command::AutoGenerateConfig::PLACEHOLDER = T.let(T.unsafe(nil), String) + # @api private # # source://rubocop//lib/rubocop/cli/command/auto_generate_config.rb#12 @@ -412,6 +436,18 @@ end # source://rubocop//lib/rubocop/cli/command/init_dotfile.rb#9 RuboCop::CLI::Command::InitDotfile::DOTFILE = T.let(T.unsafe(nil), String) +# Start Language Server Protocol of RuboCop. +# +# @api private +# +# source://rubocop//lib/rubocop/cli/command/lsp.rb#10 +class RuboCop::CLI::Command::LSP < ::RuboCop::CLI::Command::Base + # @api private + # + # source://rubocop//lib/rubocop/cli/command/lsp.rb#13 + def run; end +end + # Shows the given cops, or all cops by default, and their configurations # for the current directory. # @@ -709,6 +745,11 @@ class RuboCop::CachedData # source://rubocop//lib/rubocop/cached_data.rb#47 def deserialize_offenses(offenses); end + # @api private + # + # source://rubocop//lib/rubocop/cached_data.rb#56 + def location_from_source_buffer(offense, source_buffer); end + # @api private # # source://rubocop//lib/rubocop/cached_data.rb#40 @@ -925,7 +966,7 @@ end # during a run of the rubocop program, if files in several # directories are inspected. # -# source://rubocop//lib/rubocop/config.rb#14 +# source://rubocop//lib/rubocop/config.rb#12 class RuboCop::Config include ::RuboCop::PathUtil include ::RuboCop::FileFinder @@ -933,7 +974,7 @@ class RuboCop::Config # @return [Config] a new instance of Config # - # source://rubocop//lib/rubocop/config.rb#32 + # source://rubocop//lib/rubocop/config.rb#30 def initialize(hash = T.unsafe(nil), loaded_path = T.unsafe(nil)); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -944,15 +985,15 @@ class RuboCop::Config # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#172 + # source://rubocop//lib/rubocop/config.rb#170 def active_support_extensions_enabled?; end - # source://rubocop//lib/rubocop/config.rb#98 + # source://rubocop//lib/rubocop/config.rb#96 def add_excludes_from_higher_level(highest_config); end # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#195 + # source://rubocop//lib/rubocop/config.rb#193 def allowed_camel_case_file?(file); end # Paths specified in configuration files starting with .rubocop are @@ -961,25 +1002,27 @@ class RuboCop::Config # config/default.yml, for example, are not relative to RuboCop's config # directory since that wouldn't work. # - # source://rubocop//lib/rubocop/config.rb#239 + # source://rubocop//lib/rubocop/config.rb#237 def base_dir_for_path_parameters; end - # source://rubocop//lib/rubocop/config.rb#264 + # @return [String, nil] + # + # source://rubocop//lib/rubocop/config.rb#267 def bundler_lock_file_path; end - # source://rubocop//lib/rubocop/config.rb#53 + # source://rubocop//lib/rubocop/config.rb#51 def check; end # @api private # @return [Boolean] whether config for this badge has 'Include' or 'Exclude' keys # - # source://rubocop//lib/rubocop/config.rb#144 + # source://rubocop//lib/rubocop/config.rb#142 def clusivity_config_for_badge?(badge); end # source://forwardable/1.3.3/forwardable.rb#231 def delete(*args, **_arg1, &block); end - # source://rubocop//lib/rubocop/config.rb#110 + # source://rubocop//lib/rubocop/config.rb#108 def deprecation_check; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -987,7 +1030,7 @@ class RuboCop::Config # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#164 + # source://rubocop//lib/rubocop/config.rb#162 def disabled_new_cops?; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -998,7 +1041,7 @@ class RuboCop::Config # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#168 + # source://rubocop//lib/rubocop/config.rb#166 def enabled_new_cops?; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -1006,22 +1049,22 @@ class RuboCop::Config # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#217 + # source://rubocop//lib/rubocop/config.rb#215 def file_to_exclude?(file); end # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#176 + # source://rubocop//lib/rubocop/config.rb#174 def file_to_include?(file); end - # source://rubocop//lib/rubocop/config.rb#160 + # source://rubocop//lib/rubocop/config.rb#158 def for_all_cops; end # Note: the 'Enabled' attribute is same as that returned by `for_cop` # # @return [Config] for the given cop merged with that of its department (if any) # - # source://rubocop//lib/rubocop/config.rb#130 + # source://rubocop//lib/rubocop/config.rb#128 def for_badge(badge); end # Note: the 'Enabled' attribute is calculated according to the department's @@ -1029,7 +1072,7 @@ class RuboCop::Config # # @return [Config] for the given cop / cop name. # - # source://rubocop//lib/rubocop/config.rb#124 + # source://rubocop//lib/rubocop/config.rb#122 def for_cop(cop); end # Note: the 'Enabled' attribute will be present only if specified @@ -1037,17 +1080,22 @@ class RuboCop::Config # # @return [Config] for the given department name. # - # source://rubocop//lib/rubocop/config.rb#155 + # source://rubocop//lib/rubocop/config.rb#153 def for_department(department_name); end - # source://rubocop//lib/rubocop/config.rb#287 + # Returns target's locked gem versions (i.e. from Gemfile.lock or gems.locked) + # + # source://rubocop//lib/rubocop/config.rb#292 + def gem_versions_in_target; end + + # source://rubocop//lib/rubocop/config.rb#296 def inspect; end # True if this is a config file that is shipped with RuboCop # # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#78 + # source://rubocop//lib/rubocop/config.rb#76 def internal?; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -1056,15 +1104,15 @@ class RuboCop::Config # source://forwardable/1.3.3/forwardable.rb#231 def keys(*args, **_arg1, &block); end - # source://rubocop//lib/rubocop/config.rb#49 + # source://rubocop//lib/rubocop/config.rb#47 def loaded_features; end # Returns the value of attribute loaded_path. # - # source://rubocop//lib/rubocop/config.rb#22 + # source://rubocop//lib/rubocop/config.rb#20 def loaded_path; end - # source://rubocop//lib/rubocop/config.rb#83 + # source://rubocop//lib/rubocop/config.rb#81 def make_excludes_absolute; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -1073,16 +1121,19 @@ class RuboCop::Config # source://forwardable/1.3.3/forwardable.rb#231 def merge(*args, **_arg1, &block); end - # source://rubocop//lib/rubocop/config.rb#230 + # source://rubocop//lib/rubocop/config.rb#247 + def parser_engine; end + + # source://rubocop//lib/rubocop/config.rb#228 def path_relative_to_config(path); end - # source://rubocop//lib/rubocop/config.rb#226 + # source://rubocop//lib/rubocop/config.rb#224 def patterns_to_exclude; end - # source://rubocop//lib/rubocop/config.rb#222 + # source://rubocop//lib/rubocop/config.rb#220 def patterns_to_include; end - # source://rubocop//lib/rubocop/config.rb#275 + # source://rubocop//lib/rubocop/config.rb#278 def pending_cops; end # Returns true if there's a chance that an Include pattern matches hidden @@ -1090,19 +1141,19 @@ class RuboCop::Config # # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#209 + # source://rubocop//lib/rubocop/config.rb#207 def possibly_include_hidden?; end # source://forwardable/1.3.3/forwardable.rb#231 def replace(*args, **_arg1, &block); end - # source://rubocop//lib/rubocop/config.rb#73 + # source://rubocop//lib/rubocop/config.rb#71 def signature; end - # source://rubocop//lib/rubocop/config.rb#260 + # source://rubocop//lib/rubocop/config.rb#262 def smart_loaded_path; end - # source://rubocop//lib/rubocop/config.rb#249 + # source://rubocop//lib/rubocop/config.rb#251 def target_rails_version; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -1114,7 +1165,7 @@ class RuboCop::Config # source://forwardable/1.3.3/forwardable.rb#231 def to_hash(*args, **_arg1, &block); end - # source://rubocop//lib/rubocop/config.rb#69 + # source://rubocop//lib/rubocop/config.rb#67 def to_s; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -1123,32 +1174,45 @@ class RuboCop::Config # source://forwardable/1.3.3/forwardable.rb#231 def validate(*args, **_arg1, &block); end - # source://rubocop//lib/rubocop/config.rb#60 + # source://rubocop//lib/rubocop/config.rb#58 def validate_after_resolution; end private - # source://rubocop//lib/rubocop/config.rb#322 + # source://rubocop//lib/rubocop/config.rb#346 def department_of(qualified_cop_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/config.rb#310 + # source://rubocop//lib/rubocop/config.rb#334 def enable_cop?(qualified_cop_name, cop_options); end - # source://rubocop//lib/rubocop/config.rb#297 + # @param gem_version [Gem::Version] an object like `Gem::Version.new("7.1.2.3")` + # @return [Float] The major and minor version, like `7.1` + # + # source://rubocop//lib/rubocop/config.rb#321 + def gem_version_to_major_minor_float(gem_version); end + + # source://rubocop//lib/rubocop/config.rb#327 + def read_gem_versions_from_target_lockfile; end + + # @return [Float, nil] The Rails version as a `major.minor` Float. + # + # source://rubocop//lib/rubocop/config.rb#308 def read_rails_version_from_bundler_lock_file; end - # source://rubocop//lib/rubocop/config.rb#293 + # @return [Float, nil] The Rails version as a `major.minor` Float. + # + # source://rubocop//lib/rubocop/config.rb#303 def target_rails_version_from_bundler_lock_file; end class << self - # source://rubocop//lib/rubocop/config.rb#24 + # source://rubocop//lib/rubocop/config.rb#22 def create(hash, path, check: T.unsafe(nil)); end end end -# source://rubocop//lib/rubocop/config.rb#19 +# source://rubocop//lib/rubocop/config.rb#17 class RuboCop::Config::CopConfig < ::Struct # Returns the value of attribute metadata # @@ -1181,7 +1245,7 @@ class RuboCop::Config::CopConfig < ::Struct end end -# source://rubocop//lib/rubocop/config.rb#21 +# source://rubocop//lib/rubocop/config.rb#19 RuboCop::Config::DEFAULT_RAILS_VERSION = T.let(T.unsafe(nil), Float) # This class has methods related to finding configuration path. @@ -1215,7 +1279,7 @@ class RuboCop::ConfigFinder # @api private # - # source://rubocop//lib/rubocop/config_finder.rb#59 + # source://rubocop//lib/rubocop/config_finder.rb#69 def expand_path(path); end # @api private @@ -1231,11 +1295,16 @@ class RuboCop::ConfigFinder # @api private # # source://rubocop//lib/rubocop/config_finder.rb#44 + def find_project_root_dot_config; end + + # @api private + # + # source://rubocop//lib/rubocop/config_finder.rb#54 def find_user_dotfile; end # @api private # - # source://rubocop//lib/rubocop/config_finder.rb#52 + # source://rubocop//lib/rubocop/config_finder.rb#62 def find_user_xdg_config; end end end @@ -1266,12 +1335,12 @@ RuboCop::ConfigFinder::XDG_CONFIG = T.let(T.unsafe(nil), String) # during a run of the rubocop program, if files in several # directories are inspected. # -# source://rubocop//lib/rubocop/config_loader.rb#18 +# source://rubocop//lib/rubocop/config_loader.rb#17 class RuboCop::ConfigLoader extend ::RuboCop::FileFinder class << self - # source://rubocop//lib/rubocop/config_loader.rb#138 + # source://rubocop//lib/rubocop/config_loader.rb#137 def add_excludes_from_files(config, config_file); end # Used to add features that were required inside a config or from @@ -1279,13 +1348,13 @@ class RuboCop::ConfigLoader # # @api private # - # source://rubocop//lib/rubocop/config_loader.rb#199 + # source://rubocop//lib/rubocop/config_loader.rb#198 def add_loaded_features(loaded_features); end - # source://rubocop//lib/rubocop/config_loader.rb#81 + # source://rubocop//lib/rubocop/config_loader.rb#80 def add_missing_namespaces(path, hash); end - # source://rubocop//lib/rubocop/config_loader.rb#42 + # source://rubocop//lib/rubocop/config_loader.rb#41 def clear_options; end # Returns the path of .rubocop.yml searching upwards in the @@ -1294,128 +1363,128 @@ class RuboCop::ConfigLoader # user's home directory is checked. If there's no .rubocop.yml # there either, the path to the default file is returned. # - # source://rubocop//lib/rubocop/config_loader.rb#105 + # source://rubocop//lib/rubocop/config_loader.rb#104 def configuration_file_for(target_dir); end - # source://rubocop//lib/rubocop/config_loader.rb#109 + # source://rubocop//lib/rubocop/config_loader.rb#108 def configuration_from_file(config_file, check: T.unsafe(nil)); end # Returns the value of attribute debug. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def debug; end # Sets the attribute debug # # @param value the value to set the attribute debug to. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def debug=(_arg0); end # Returns the value of attribute debug. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def debug?; end - # source://rubocop//lib/rubocop/config_loader.rb#148 + # source://rubocop//lib/rubocop/config_loader.rb#147 def default_configuration; end # Sets the attribute default_configuration # # @param value the value to set the attribute default_configuration to. # - # source://rubocop//lib/rubocop/config_loader.rb#36 + # source://rubocop//lib/rubocop/config_loader.rb#35 def default_configuration=(_arg0); end # Returns the value of attribute disable_pending_cops. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def disable_pending_cops; end # Sets the attribute disable_pending_cops # # @param value the value to set the attribute disable_pending_cops to. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def disable_pending_cops=(_arg0); end # Returns the value of attribute enable_pending_cops. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def enable_pending_cops; end # Sets the attribute enable_pending_cops # # @param value the value to set the attribute enable_pending_cops to. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def enable_pending_cops=(_arg0); end # Returns the value of attribute ignore_parent_exclusion. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def ignore_parent_exclusion; end # Sets the attribute ignore_parent_exclusion # # @param value the value to set the attribute ignore_parent_exclusion to. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def ignore_parent_exclusion=(_arg0); end # Returns the value of attribute ignore_parent_exclusion. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def ignore_parent_exclusion?; end # Returns the value of attribute ignore_unrecognized_cops. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def ignore_unrecognized_cops; end # Sets the attribute ignore_unrecognized_cops # # @param value the value to set the attribute ignore_unrecognized_cops to. # - # source://rubocop//lib/rubocop/config_loader.rb#34 + # source://rubocop//lib/rubocop/config_loader.rb#33 def ignore_unrecognized_cops=(_arg0); end # @api private # - # source://rubocop//lib/rubocop/config_loader.rb#156 + # source://rubocop//lib/rubocop/config_loader.rb#155 def inject_defaults!(project_root); end - # source://rubocop//lib/rubocop/config_loader.rb#48 + # source://rubocop//lib/rubocop/config_loader.rb#47 def load_file(file, check: T.unsafe(nil)); end # @raise [TypeError] # - # source://rubocop//lib/rubocop/config_loader.rb#68 + # source://rubocop//lib/rubocop/config_loader.rb#67 def load_yaml_configuration(absolute_path); end # Returns the value of attribute loaded_features. # - # source://rubocop//lib/rubocop/config_loader.rb#37 + # source://rubocop//lib/rubocop/config_loader.rb#36 def loaded_features; end # Return a recursive merge of two hashes. That is, a normal hash merge, # with the addition that any value that is a hash, and occurs in both # arguments, will also be merged. And so on. # - # source://rubocop//lib/rubocop/config_loader.rb#96 + # source://rubocop//lib/rubocop/config_loader.rb#95 def merge(base_hash, derived_hash); end # Merges the given configuration with the default one. # - # source://rubocop//lib/rubocop/config_loader.rb#192 + # source://rubocop//lib/rubocop/config_loader.rb#191 def merge_with_default(config, config_file, unset_nil: T.unsafe(nil)); end - # source://rubocop//lib/rubocop/config_loader.rb#129 + # source://rubocop//lib/rubocop/config_loader.rb#128 def pending_cops_only_qualified(pending_cops); end # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader.rb#133 + # source://rubocop//lib/rubocop/config_loader.rb#132 def possible_new_cops?(config); end # Returns the path RuboCop inferred as the root of the project. No file @@ -1423,48 +1492,48 @@ class RuboCop::ConfigLoader # # @deprecated Use `RuboCop::ConfigFinder.project_root` instead. # - # source://rubocop//lib/rubocop/config_loader.rb#167 + # source://rubocop//lib/rubocop/config_loader.rb#166 def project_root; end - # source://rubocop//lib/rubocop/config_loader.rb#176 + # source://rubocop//lib/rubocop/config_loader.rb#175 def warn_on_pending_cops(pending_cops); end - # source://rubocop//lib/rubocop/config_loader.rb#184 + # source://rubocop//lib/rubocop/config_loader.rb#183 def warn_pending_cop(cop); end private - # source://rubocop//lib/rubocop/config_loader.rb#213 + # source://rubocop//lib/rubocop/config_loader.rb#212 def check_duplication(yaml_code, absolute_path); end - # source://rubocop//lib/rubocop/config_loader.rb#205 + # source://rubocop//lib/rubocop/config_loader.rb#204 def file_path(file); end # Read the specified file, or exit with a friendly, concise message on # stderr. Care is taken to use the standard OS exit code for a "file not # found" error. # - # source://rubocop//lib/rubocop/config_loader.rb#233 + # source://rubocop//lib/rubocop/config_loader.rb#232 def read_file(absolute_path); end - # source://rubocop//lib/rubocop/config_loader.rb#209 + # source://rubocop//lib/rubocop/config_loader.rb#208 def resolver; end - # source://rubocop//lib/rubocop/config_loader.rb#239 + # source://rubocop//lib/rubocop/config_loader.rb#238 def yaml_safe_load(yaml_code, filename); end - # source://rubocop//lib/rubocop/config_loader.rb#249 + # source://rubocop//lib/rubocop/config_loader.rb#248 def yaml_safe_load!(yaml_code, filename); end end end -# source://rubocop//lib/rubocop/config_loader.rb#21 +# source://rubocop//lib/rubocop/config_loader.rb#20 RuboCop::ConfigLoader::DEFAULT_FILE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/config_loader.rb#19 +# source://rubocop//lib/rubocop/config_loader.rb#18 RuboCop::ConfigLoader::DOTFILE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/config_loader.rb#20 +# source://rubocop//lib/rubocop/config_loader.rb#19 RuboCop::ConfigLoader::RUBOCOP_HOME = T.let(T.unsafe(nil), String) # A help class for ConfigLoader that handles configuration resolution. @@ -1481,7 +1550,7 @@ class RuboCop::ConfigLoaderResolver # @api private # # source://rubocop//lib/rubocop/config_loader_resolver.rb#45 - def fix_include_paths(base_config_path, hash, key, value); end + def fix_include_paths(base_config_path, hash, path, key, value); end # Return a recursive merge of two hashes. That is, a normal hash merge, # with the addition that any value that is a hash, and occurs in both @@ -1490,7 +1559,7 @@ class RuboCop::ConfigLoaderResolver # # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#98 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#99 def merge(base_hash, derived_hash, **opts); end # Merges the given configuration with the default one. If @@ -1501,7 +1570,7 @@ class RuboCop::ConfigLoaderResolver # # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#74 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#75 def merge_with_default(config, config_file, unset_nil:); end # An `Enabled: true` setting in user configuration for a cop overrides an @@ -1509,7 +1578,7 @@ class RuboCop::ConfigLoaderResolver # # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#118 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#119 def override_department_setting_for_cops(base_hash, derived_hash); end # If a cop was previously explicitly enabled, but then superseded by the @@ -1517,7 +1586,7 @@ class RuboCop::ConfigLoaderResolver # # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#135 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#136 def override_enabled_for_disabled_departments(base_hash, derived_hash); end # @api private @@ -1527,7 +1596,7 @@ class RuboCop::ConfigLoaderResolver # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#54 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#55 def resolve_inheritance_from_gems(hash); end # @api private @@ -1539,85 +1608,85 @@ class RuboCop::ConfigLoaderResolver # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#207 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#208 def base_configs(path, inherit_from, file); end # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#175 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#176 def determine_inherit_mode(hash, key); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#151 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#152 def disabled?(hash, department); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#155 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#156 def duplicate_setting?(base_hash, derived_hash, key, inherited_file); end # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#267 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#268 def gem_config_path(gem_name, relative_config_path); end # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#245 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#246 def handle_disabled_by_default(config, new_default_configuration); end # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#219 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#220 def inherited_file(path, inherit_from, file); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#203 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#204 def merge_hashes?(base_hash, derived_hash, key); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#240 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#241 def remote_file?(uri); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#195 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#196 def should_merge?(mode, key); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#199 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#200 def should_override?(mode, key); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#181 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#182 def should_union?(derived_hash, base_hash, root_mode, key); end # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#263 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#264 def transform(config, &block); end # @api private # - # source://rubocop//lib/rubocop/config_loader_resolver.rb#164 + # source://rubocop//lib/rubocop/config_loader_resolver.rb#165 def warn_on_duplicate_setting(base_hash, derived_hash, key, **opts); end end # Raised when a RuboCop configuration file is not found. # -# source://rubocop//lib/rubocop/config_loader.rb#10 +# source://rubocop//lib/rubocop/config_loader.rb#9 class RuboCop::ConfigNotFoundError < ::RuboCop::Error; end # This class handles obsolete configuration. @@ -1629,23 +1698,23 @@ class RuboCop::ConfigObsoletion # @api private # @return [ConfigObsoletion] a new instance of ConfigObsoletion # - # source://rubocop//lib/rubocop/config_obsoletion.rb#33 + # source://rubocop//lib/rubocop/config_obsoletion.rb#35 def initialize(config); end # @api private # @raise [ValidationError] # - # source://rubocop//lib/rubocop/config_obsoletion.rb#39 + # source://rubocop//lib/rubocop/config_obsoletion.rb#41 def reject_obsolete!; end # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#19 + # source://rubocop//lib/rubocop/config_obsoletion.rb#21 def rules; end # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#19 + # source://rubocop//lib/rubocop/config_obsoletion.rb#21 def warnings; end private @@ -1654,7 +1723,7 @@ class RuboCop::ConfigObsoletion # # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#69 + # source://rubocop//lib/rubocop/config_obsoletion.rb#72 def load_cop_rules(rules); end # Parameter rules may apply to multiple cops and multiple parameters @@ -1663,7 +1732,7 @@ class RuboCop::ConfigObsoletion # # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#82 + # source://rubocop//lib/rubocop/config_obsoletion.rb#85 def load_parameter_rules(rules); end # Default rules for obsoletions are in config/obsoletion.yml @@ -1671,28 +1740,28 @@ class RuboCop::ConfigObsoletion # # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#50 + # source://rubocop//lib/rubocop/config_obsoletion.rb#52 def load_rules; end # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#95 + # source://rubocop//lib/rubocop/config_obsoletion.rb#98 def obsoletions; end class << self # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#22 + # source://rubocop//lib/rubocop/config_obsoletion.rb#24 def files; end # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#22 + # source://rubocop//lib/rubocop/config_obsoletion.rb#24 def files=(_arg0); end # @api private # - # source://rubocop//lib/rubocop/config_obsoletion.rb#24 + # source://rubocop//lib/rubocop/config_obsoletion.rb#26 def legacy_cop_names; end end end @@ -1845,6 +1914,11 @@ class RuboCop::ConfigObsoletion::ExtractedCop < ::RuboCop::ConfigObsoletion::Cop def feature_loaded?; end end +# @api private +# +# source://rubocop//lib/rubocop/config_obsoletion.rb#18 +RuboCop::ConfigObsoletion::LOAD_RULES_CACHE = T.let(T.unsafe(nil), Hash) + # @api private # # source://rubocop//lib/rubocop/config_obsoletion.rb#14 @@ -1899,22 +1973,28 @@ class RuboCop::ConfigObsoletion::ParameterRule < ::RuboCop::ConfigObsoletion::Ru # @api private # - # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#31 + # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#39 def alternative; end # @api private # - # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#35 + # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#43 def alternatives; end # @api private + # @return [Boolean] # - # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#39 + # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#31 + def applies_to_current_ruby_version?; end + + # @api private + # + # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#47 def reason; end # @api private # - # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#43 + # source://rubocop//lib/rubocop/config_obsoletion/parameter_rule.rb#51 def severity; end end @@ -2175,13 +2255,13 @@ end # Handles validation of configuration, for example cop names, parameter # names, and Ruby versions. # -# source://rubocop//lib/rubocop/config_validator.rb#8 +# source://rubocop//lib/rubocop/config_validator.rb#6 class RuboCop::ConfigValidator extend ::Forwardable # @return [ConfigValidator] a new instance of ConfigValidator # - # source://rubocop//lib/rubocop/config_validator.rb#27 + # source://rubocop//lib/rubocop/config_validator.rb#26 def initialize(config); end # source://forwardable/1.3.3/forwardable.rb#231 @@ -2190,10 +2270,10 @@ class RuboCop::ConfigValidator # source://forwardable/1.3.3/forwardable.rb#231 def smart_loaded_path(*args, **_arg1, &block); end - # source://rubocop//lib/rubocop/config_validator.rb#63 + # source://rubocop//lib/rubocop/config_validator.rb#62 def target_ruby_version; end - # source://rubocop//lib/rubocop/config_validator.rb#33 + # source://rubocop//lib/rubocop/config_validator.rb#32 def validate; end # Validations that should only be run after all config resolving has @@ -2202,100 +2282,103 @@ class RuboCop::ConfigValidator # chain has been loaded so that only the final value is validated, and # any obsolete but overridden values are ignored. # - # source://rubocop//lib/rubocop/config_validator.rb#59 + # source://rubocop//lib/rubocop/config_validator.rb#58 def validate_after_resolution; end # @raise [ValidationError] # - # source://rubocop//lib/rubocop/config_validator.rb#67 + # source://rubocop//lib/rubocop/config_validator.rb#66 def validate_section_presence(name); end private # @raise [ValidationError] # - # source://rubocop//lib/rubocop/config_validator.rb#104 + # source://rubocop//lib/rubocop/config_validator.rb#103 def alert_about_unrecognized_cops(invalid_cop_names); end # source://rubocop//lib/rubocop/config_validator.rb#253 def check_cop_config_value(hash, parent = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/config_validator.rb#77 + # source://rubocop//lib/rubocop/config_validator.rb#76 def check_obsoletions; end # @raise [ValidationError] # - # source://rubocop//lib/rubocop/config_validator.rb#84 + # source://rubocop//lib/rubocop/config_validator.rb#83 def check_target_ruby; end - # source://rubocop//lib/rubocop/config_validator.rb#195 + # source://rubocop//lib/rubocop/config_validator.rb#194 def each_invalid_parameter(cop_name); end - # source://rubocop//lib/rubocop/config_validator.rb#120 + # source://rubocop//lib/rubocop/config_validator.rb#119 def list_unknown_cops(invalid_cop_names); end # FIXME: Handling colors in exception messages like this is ugly. # - # source://rubocop//lib/rubocop/config_validator.rb#266 - def msg_not_boolean(parent, key, value); end + # source://rubocop//lib/rubocop/config_validator.rb#273 + def param_error_message(parent, key, value, supposed_values); end - # source://rubocop//lib/rubocop/config_validator.rb#242 + # source://rubocop//lib/rubocop/config_validator.rb#241 def reject_conflicting_safe_settings; end # @raise [ValidationError] # - # source://rubocop//lib/rubocop/config_validator.rb#233 + # source://rubocop//lib/rubocop/config_validator.rb#232 def reject_mutually_exclusive_defaults; end - # source://rubocop//lib/rubocop/config_validator.rb#142 + # source://rubocop//lib/rubocop/config_validator.rb#141 def suggestion(name); end # Returns the value of attribute target_ruby. # - # source://rubocop//lib/rubocop/config_validator.rb#75 + # source://rubocop//lib/rubocop/config_validator.rb#74 def target_ruby; end - # source://rubocop//lib/rubocop/config_validator.rb#207 + # source://rubocop//lib/rubocop/config_validator.rb#206 def validate_enforced_styles(valid_cop_names); end # @raise [ValidationError] # - # source://rubocop//lib/rubocop/config_validator.rb#169 + # source://rubocop//lib/rubocop/config_validator.rb#168 def validate_new_cops_parameter; end - # source://rubocop//lib/rubocop/config_validator.rb#180 + # source://rubocop//lib/rubocop/config_validator.rb#179 def validate_parameter_names(valid_cop_names); end - # source://rubocop//lib/rubocop/config_validator.rb#227 + # source://rubocop//lib/rubocop/config_validator.rb#226 def validate_support_and_has_list(name, formats, valid); end # @raise [ValidationError] # - # source://rubocop//lib/rubocop/config_validator.rb#158 + # source://rubocop//lib/rubocop/config_validator.rb#157 def validate_syntax_cop; end end # @api private # -# source://rubocop//lib/rubocop/config_validator.rb#12 +# source://rubocop//lib/rubocop/config_validator.rb#10 RuboCop::ConfigValidator::COMMON_PARAMS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/config_validator.rb#22 +# source://rubocop//lib/rubocop/config_validator.rb#21 +RuboCop::ConfigValidator::CONFIG_CHECK_AUTOCORRECTS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/config_validator.rb#20 RuboCop::ConfigValidator::CONFIG_CHECK_DEPARTMENTS = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/config_validator.rb#21 +# source://rubocop//lib/rubocop/config_validator.rb#19 RuboCop::ConfigValidator::CONFIG_CHECK_KEYS = T.let(T.unsafe(nil), Set) # @api private # -# source://rubocop//lib/rubocop/config_validator.rb#14 +# source://rubocop//lib/rubocop/config_validator.rb#12 RuboCop::ConfigValidator::INTERNAL_PARAMS = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/config_validator.rb#18 +# source://rubocop//lib/rubocop/config_validator.rb#16 RuboCop::ConfigValidator::NEW_COPS_VALUES = T.let(T.unsafe(nil), Array) # source://rubocop//lib/rubocop/cop/util.rb#4 @@ -2329,7 +2412,7 @@ module RuboCop::Cop::Alignment # source://rubocop//lib/rubocop/cop/mixin/alignment.rb#45 def each_bad_alignment(items, base_column); end - # @deprecated Use processed_source.comment_at_line(line) + # @deprecated Use processed_source.line_with_comment?(line) # # source://rubocop//lib/rubocop/cop/mixin/alignment.rb#69 def end_of_line_comment(line); end @@ -2342,7 +2425,7 @@ module RuboCop::Cop::Alignment # @api private # - # source://rubocop//lib/rubocop/cop/mixin/alignment.rb#74 + # source://rubocop//lib/rubocop/cop/mixin/alignment.rb#78 def register_offense(offense_node, message_node); end # @api public @@ -2455,21 +2538,20 @@ module RuboCop::Cop::AllowedMethods # @api public # - # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#21 + # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#27 def allowed_methods; end - # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#29 + # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#35 def cop_config_allowed_methods; end - # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#33 + # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#39 def cop_config_deprecated_values; end - # @api public # @deprecated Use allowed_method? instead # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#13 - def ignored_method?(name); end + # source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#18 + def ignored_method?; end end # This module encapsulates the ability to ignore certain lines when @@ -2484,31 +2566,31 @@ module RuboCop::Cop::AllowedPattern # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#10 def allowed_line?(line); end - # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#30 + # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#42 def allowed_patterns; end - # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#46 + # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#58 def cop_config_deprecated_methods_values; end - # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#40 + # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#52 def cop_config_patterns_values; end # @deprecated Use allowed_line? instead # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#10 - def ignored_line?(line); end + # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#21 + def ignored_line?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#23 + # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#29 def matches_allowed_pattern?(line); end - # @deprecated Use matches_allowed_pattern?? instead + # @deprecated Use matches_allowed_pattern? instead # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#23 - def matches_ignored_pattern?(line); end + # source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#34 + def matches_ignored_pattern?; end end # This module encapsulates the ability to allow certain receivers in a cop. @@ -2716,34 +2798,34 @@ module RuboCop::Cop::AutocorrectLogic private - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#46 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#51 def disable_offense(offense_range); end - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#111 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#118 def disable_offense_at_end_of_line(range, eol_comment); end - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#115 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#122 def disable_offense_before_and_after(range_by_lines); end - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#56 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#61 def disable_offense_with_eol_or_surround_comment(range); end - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#107 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#114 def max_line_length; end # Expand the given range to include all of any lines it covers. Does not # include newline at end of the last line. # - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#97 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#104 def range_by_lines(range); end - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#88 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#95 def range_of_first_line(range); end - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#67 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#72 def surrounding_heredoc(offense_range); end - # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#78 + # source://rubocop//lib/rubocop/cop/autocorrect_logic.rb#83 def surrounding_percent_array(offense_range); end end @@ -2856,18 +2938,18 @@ class RuboCop::Cop::Base # @return [Base] a new instance of Base # - # source://rubocop//lib/rubocop/cop/base.rb#129 + # source://rubocop//lib/rubocop/cop/base.rb#156 def initialize(config = T.unsafe(nil), options = T.unsafe(nil)); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#239 + # source://rubocop//lib/rubocop/cop/base.rb#272 def active_support_extensions_enabled?; end # Adds an offense that has no particular location. # No correction can be applied to global offenses # - # source://rubocop//lib/rubocop/cop/base.rb#162 + # source://rubocop//lib/rubocop/cop/base.rb#189 def add_global_offense(message = T.unsafe(nil), severity: T.unsafe(nil)); end # Adds an offense on the specified range (or node with an expression) @@ -2875,19 +2957,25 @@ class RuboCop::Cop::Base # to provide the cop the opportunity to autocorrect the offense. # If message is not specified, the method `message` will be called. # - # source://rubocop//lib/rubocop/cop/base.rb#172 + # source://rubocop//lib/rubocop/cop/base.rb#201 def add_offense(node_or_range, message: T.unsafe(nil), severity: T.unsafe(nil), &block); end + # @api private + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/base.rb#343 + def always_autocorrect?; end + # Called before any investigation # # @api private # - # source://rubocop//lib/rubocop/cop/base.rb#295 + # source://rubocop//lib/rubocop/cop/base.rb#329 def begin_investigation(processed_source, offset: T.unsafe(nil), original: T.unsafe(nil)); end # @api private # - # source://rubocop//lib/rubocop/cop/base.rb#280 + # source://rubocop//lib/rubocop/cop/base.rb#314 def callbacks_needed; end # Returns the value of attribute config. @@ -2895,23 +2983,29 @@ class RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/base.rb#43 def config; end - # source://rubocop//lib/rubocop/cop/base.rb#223 + # source://rubocop//lib/rubocop/cop/base.rb#252 def config_to_allow_offenses; end - # source://rubocop//lib/rubocop/cop/base.rb#227 + # source://rubocop//lib/rubocop/cop/base.rb#256 def config_to_allow_offenses=(hash); end + # @api private + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/base.rb#349 + def contextual_autocorrect?; end + # Configuration Helpers # - # source://rubocop//lib/rubocop/cop/base.rb#217 + # source://rubocop//lib/rubocop/cop/base.rb#246 def cop_config; end - # source://rubocop//lib/rubocop/cop/base.rb#209 + # source://rubocop//lib/rubocop/cop/base.rb#238 def cop_name; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#251 + # source://rubocop//lib/rubocop/cop/base.rb#285 def excluded_file?(file); end # This method should be overridden when a cop's behavior depends @@ -2930,50 +3024,53 @@ class RuboCop::Cop::Base # ResultCache system when those external dependencies change, # ie when the ResultCache should be invalidated. # - # source://rubocop//lib/rubocop/cop/base.rb#205 + # source://rubocop//lib/rubocop/cop/base.rb#234 def external_dependency_checksum; end - # source://rubocop//lib/rubocop/cop/base.rb#308 + # source://rubocop//lib/rubocop/cop/base.rb#353 def inspect; end # Gets called if no message is specified when calling `add_offense` or # `add_global_offense` # Cops are discouraged to override this; instead pass your message directly # - # source://rubocop//lib/rubocop/cop/base.rb#156 + # source://rubocop//lib/rubocop/cop/base.rb#183 def message(_range = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/base.rb#209 + # source://rubocop//lib/rubocop/cop/base.rb#238 def name; end # @deprecated Make potential errors with previous API more obvious # - # source://rubocop//lib/rubocop/cop/base.rb#271 + # source://rubocop//lib/rubocop/cop/base.rb#305 def offenses; end # Called after all on_... have been called # When refining this method, always call `super` # - # source://rubocop//lib/rubocop/cop/base.rb#143 + # source://rubocop//lib/rubocop/cop/base.rb#170 def on_investigation_end; end # Called before all on_... have been called # When refining this method, always call `super` # - # source://rubocop//lib/rubocop/cop/base.rb#137 + # source://rubocop//lib/rubocop/cop/base.rb#164 def on_new_investigation; end # Called instead of all on_... callbacks for unrecognized files / syntax errors # When refining this method, always call `super` # - # source://rubocop//lib/rubocop/cop/base.rb#149 + # source://rubocop//lib/rubocop/cop/base.rb#176 def on_other_file; end # There should be very limited reasons for a Cop to do it's own parsing # - # source://rubocop//lib/rubocop/cop/base.rb#256 + # source://rubocop//lib/rubocop/cop/base.rb#290 def parse(source, path = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/base.rb#264 + def parser_engine; end + # Returns the value of attribute processed_source. # # source://rubocop//lib/rubocop/cop/base.rb#43 @@ -2983,99 +3080,106 @@ class RuboCop::Cop::Base # # @api private # - # source://rubocop//lib/rubocop/cop/base.rb#262 + # source://rubocop//lib/rubocop/cop/base.rb#296 def ready; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#243 + # source://rubocop//lib/rubocop/cop/base.rb#276 def relevant_file?(file); end - # source://rubocop//lib/rubocop/cop/base.rb#235 + # source://rubocop//lib/rubocop/cop/base.rb#268 def target_rails_version; end - # source://rubocop//lib/rubocop/cop/base.rb#231 + # source://rubocop//lib/rubocop/cop/base.rb#260 def target_ruby_version; end private - # source://rubocop//lib/rubocop/cop/base.rb#436 + # source://rubocop//lib/rubocop/cop/base.rb#471 def annotate(message); end - # source://rubocop//lib/rubocop/cop/base.rb#320 + # source://rubocop//lib/rubocop/cop/base.rb#365 def apply_correction(corrector); end # @return [Symbol] offense status # - # source://rubocop//lib/rubocop/cop/base.rb#400 + # source://rubocop//lib/rubocop/cop/base.rb#435 def attempt_correction(range, corrector); end # Reserved for Cop::Cop # - # source://rubocop//lib/rubocop/cop/base.rb#316 + # source://rubocop//lib/rubocop/cop/base.rb#361 def callback_argument(range); end # Called to complete an investigation # - # source://rubocop//lib/rubocop/cop/base.rb#349 + # source://rubocop//lib/rubocop/cop/base.rb#394 def complete_investigation; end # @return [Symbol, Corrector] offense status # - # source://rubocop//lib/rubocop/cop/base.rb#374 + # source://rubocop//lib/rubocop/cop/base.rb#409 def correct(range); end - # source://rubocop//lib/rubocop/cop/base.rb#334 + # source://rubocop//lib/rubocop/cop/base.rb#379 def current_corrector; end # Reserved for Commissioner: # - # source://rubocop//lib/rubocop/cop/base.rb#326 + # source://rubocop//lib/rubocop/cop/base.rb#371 def current_offense_locations; end - # source://rubocop//lib/rubocop/cop/base.rb#338 + # source://rubocop//lib/rubocop/cop/base.rb#383 def current_offenses; end - # source://rubocop//lib/rubocop/cop/base.rb#330 + # source://rubocop//lib/rubocop/cop/base.rb#375 def currently_disabled_lines; end - # source://rubocop//lib/rubocop/cop/base.rb#464 + # source://rubocop//lib/rubocop/cop/base.rb#499 def custom_severity; end - # source://rubocop//lib/rubocop/cop/base.rb#460 + # source://rubocop//lib/rubocop/cop/base.rb#495 def default_severity; end - # source://rubocop//lib/rubocop/cop/base.rb#414 + # source://rubocop//lib/rubocop/cop/base.rb#449 def disable_uncorrectable(range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#450 + # source://rubocop//lib/rubocop/cop/base.rb#485 def enabled_line?(line_number); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#442 + # source://rubocop//lib/rubocop/cop/base.rb#477 def file_name_matches_any?(file, parameter, default_result); end - # source://rubocop//lib/rubocop/cop/base.rb#432 + # source://rubocop//lib/rubocop/cop/base.rb#467 def find_message(range, message); end - # source://rubocop//lib/rubocop/cop/base.rb#456 + # source://rubocop//lib/rubocop/cop/base.rb#491 def find_severity(_range, severity); end - # source://rubocop//lib/rubocop/cop/base.rb#477 + # source://rubocop//lib/rubocop/cop/base.rb#512 def range_for_original(range); end - # source://rubocop//lib/rubocop/cop/base.rb#421 + # source://rubocop//lib/rubocop/cop/base.rb#456 def range_from_node_or_range(node_or_range); end - # source://rubocop//lib/rubocop/cop/base.rb#369 + # Actually private methods + # + # source://rubocop//lib/rubocop/cop/base.rb#404 def reset_investigation; end + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/base.rb#520 + def target_satisfies_all_gem_version_requirements?; end + # @return [Symbol] offense status # - # source://rubocop//lib/rubocop/cop/base.rb#389 + # source://rubocop//lib/rubocop/cop/base.rb#424 def use_corrector(range, corrector); end class << self @@ -3083,53 +3187,61 @@ class RuboCop::Cop::Base # time as this cop # # @api public - # @return [Array] + # @return [Array] # # source://rubocop//lib/rubocop/cop/base.rb#59 def autocorrect_incompatible_with; end # Naming # - # source://rubocop//lib/rubocop/cop/base.rb#89 + # source://rubocop//lib/rubocop/cop/base.rb#93 def badge; end # @api private # - # source://rubocop//lib/rubocop/cop/base.rb#285 + # source://rubocop//lib/rubocop/cop/base.rb#319 def callbacks_needed; end - # source://rubocop//lib/rubocop/cop/base.rb#93 + # source://rubocop//lib/rubocop/cop/base.rb#97 def cop_name; end - # source://rubocop//lib/rubocop/cop/base.rb#97 + # source://rubocop//lib/rubocop/cop/base.rb#101 def department; end - # Cops (other than builtin) are encouraged to implement this + # Returns an url to view this cops documentation online. + # Requires 'DocumentationBaseURL' to be set for your department. + # Will follow the convention of RuboCops own documentation structure, + # overwrite this method to accommodate your custom layout. # # @api public # @return [String, nil] # - # source://rubocop//lib/rubocop/cop/base.rb#67 - def documentation_url; end + # source://rubocop//lib/rubocop/cop/base.rb#70 + def documentation_url(config = T.unsafe(nil)); end # Call for abstract Cop classes # - # source://rubocop//lib/rubocop/cop/base.rb#77 + # source://rubocop//lib/rubocop/cop/base.rb#81 def exclude_from_registry; end + # Returns the value of attribute gem_requirements. + # + # source://rubocop//lib/rubocop/cop/base.rb#138 + def gem_requirements; end + # @private # - # source://rubocop//lib/rubocop/cop/base.rb#71 + # source://rubocop//lib/rubocop/cop/base.rb#74 def inherited(subclass); end # Override and return the Force class(es) you need to join # - # source://rubocop//lib/rubocop/cop/base.rb#114 + # source://rubocop//lib/rubocop/cop/base.rb#118 def joining_forces; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#101 + # source://rubocop//lib/rubocop/cop/base.rb#105 def lint?; end # Returns true if the cop name or the cop namespace matches any of the @@ -3137,15 +3249,30 @@ class RuboCop::Cop::Base # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#107 + # source://rubocop//lib/rubocop/cop/base.rb#111 def match?(given_names); end + # Register a version requirement for the given gem name. + # This cop will be skipped unless the target satisfies *all* requirements. + # + # @api public + # @param gem_name [String] + # @param version_requirements [Array] The version requirements, + # using the same syntax as a Gemfile, e.g. ">= 1.2.3" + # + # If omitted, any version of the gem will be accepted. + # + # https://guides.rubygems.org/patterns/#declaring-dependencies + # + # source://rubocop//lib/rubocop/cop/base.rb#151 + def requires_gem(gem_name, *version_requirements); end + # Returns if class supports autocorrect. # It is recommended to extend AutoCorrector instead of overriding # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#83 + # source://rubocop//lib/rubocop/cop/base.rb#87 def support_autocorrect?; end # Override if your cop should be called repeatedly for multiple investigations @@ -3158,22 +3285,17 @@ class RuboCop::Cop::Base # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/base.rb#125 + # source://rubocop//lib/rubocop/cop/base.rb#129 def support_multiple_source?; end private - # @return [Boolean] - # - # source://rubocop//lib/rubocop/cop/base.rb#360 - def builtin?; end - - # source://rubocop//lib/rubocop/cop/base.rb#342 + # source://rubocop//lib/rubocop/cop/base.rb#387 def restrict_on_send; end end end -# source://rubocop//lib/rubocop/cop/base.rb#346 +# source://rubocop//lib/rubocop/cop/base.rb#391 RuboCop::Cop::Base::EMPTY_OFFENSES = T.let(T.unsafe(nil), Array) # Reports of an investigation. @@ -3276,38 +3398,121 @@ module RuboCop::Cop::Bundler; end # gem 'rubocop', '~> 0.90.0' # end # -# source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#38 +# source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#39 class RuboCop::Cop::Bundler::DuplicatedGem < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp - # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#57 + # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#58 def gem_declarations(param0); end - # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#44 + # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#45 def on_new_investigation; end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#66 + # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#67 def conditional_declaration?(nodes); end - # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#59 + # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#60 def duplicated_gem_nodes; end - # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#80 + # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#81 def register_offense(node, gem_name, line_of_first_occurrence); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#74 + # source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#75 def within_conditional?(node, conditional_node); end end -# source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#41 +# source://rubocop//lib/rubocop/cop/bundler/duplicated_gem.rb#42 RuboCop::Cop::Bundler::DuplicatedGem::MSG = T.let(T.unsafe(nil), String) +# A Gem group, or a set of groups, should be listed only once in a Gemfile. +# +# For example, if the values of `source`, `git`, `platforms`, or `path` +# surrounding `group` are different, no offense will be registered: +# +# [source,ruby] +# ----- +# platforms :ruby do +# group :default do +# gem 'openssl' +# end +# end +# +# platforms :jruby do +# group :default do +# gem 'jruby-openssl' +# end +# end +# ----- +# +# @example +# # bad +# group :development do +# gem 'rubocop' +# end +# +# group :development do +# gem 'rubocop-rails' +# end +# +# # bad (same set of groups declared twice) +# group :development, :test do +# gem 'rubocop' +# end +# +# group :test, :development do +# gem 'rspec' +# end +# +# # good +# group :development do +# gem 'rubocop' +# end +# +# group :development, :test do +# gem 'rspec' +# end +# +# # good +# gem 'rubocop', groups: [:development, :test] +# gem 'rspec', groups: [:development, :test] +# +# source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#58 +class RuboCop::Cop::Bundler::DuplicatedGroup < ::RuboCop::Cop::Base + include ::RuboCop::Cop::RangeHelp + + # source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#66 + def group_declarations(param0); end + + # source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#68 + def on_new_investigation; end + + private + + # source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#82 + def duplicated_group_nodes; end + + # source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#105 + def find_source_key(node); end + + # source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#115 + def group_attributes(node); end + + # source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#94 + def register_offense(node, group_name, line_of_first_occurrence); end +end + +# source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#61 +RuboCop::Cop::Bundler::DuplicatedGroup::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/bundler/duplicated_group.rb#63 +RuboCop::Cop::Bundler::DuplicatedGroup::SOURCE_BLOCK_NAMES = T.let(T.unsafe(nil), Array) + # Each gem in the Gemfile should have a comment explaining # its purpose in the project, or the reason for its version # or source. @@ -3629,35 +3834,35 @@ class RuboCop::Cop::Bundler::GemVersion < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#113 + # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#111 def forbidden_offense?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#119 + # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#117 def forbidden_style?; end # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#93 - def message(range); end + def message(_range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#103 + # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#101 def offense?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#107 + # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#105 def required_offense?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#123 + # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#121 def required_style?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#127 + # source://rubocop//lib/rubocop/cop/bundler/gem_version.rb#125 def version_specification?(expression); end end @@ -3746,31 +3951,37 @@ RuboCop::Cop::Bundler::InsecureProtocolSource::RESTRICT_ON_SEND = T.let(T.unsafe # gem 'rubocop' # # gem 'rspec' -# -# # good only if TreatCommentsAsGroupSeparators is true +# @example TreatCommentsAsGroupSeparators: true (default) +# # good +# # For code quality +# gem 'rubocop' +# # For tests +# gem 'rspec' +# @example TreatCommentsAsGroupSeparators: false +# # bad # # For code quality # gem 'rubocop' # # For tests # gem 'rspec' # -# source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#27 +# source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#35 class RuboCop::Cop::Bundler::OrderedGems < ::RuboCop::Cop::Base include ::RuboCop::Cop::OrderedGemNode extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#56 + # source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#64 def gem_declarations(param0); end - # source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#35 + # source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#43 def on_new_investigation; end private - # source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#49 + # source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#57 def previous_declaration(node); end end -# source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#31 +# source://rubocop//lib/rubocop/cop/bundler/ordered_gems.rb#39 RuboCop::Cop::Bundler::OrderedGems::MSG = T.let(T.unsafe(nil), String) # Common functionality for checking assignment nodes. @@ -3973,6 +4184,9 @@ module RuboCop::Cop::CodeLength # source://rubocop//lib/rubocop/cop/mixin/code_length.rb#45 def irrelevant_line(source_line); end + # source://rubocop//lib/rubocop/cop/mixin/code_length.rb#58 + def location(node); end + # source://rubocop//lib/rubocop/cop/mixin/code_length.rb#19 def max_length; end @@ -4630,7 +4844,7 @@ module RuboCop::Cop::ConfigurableFormatting # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/configurable_formatting.rb#29 + # source://rubocop//lib/rubocop/cop/mixin/configurable_formatting.rb#30 def class_emitter_method?(node, name); end # source://rubocop//lib/rubocop/cop/mixin/configurable_formatting.rb#17 @@ -4638,14 +4852,14 @@ module RuboCop::Cop::ConfigurableFormatting # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/configurable_formatting.rb#23 + # source://rubocop//lib/rubocop/cop/mixin/configurable_formatting.rb#24 def valid_name?(node, name, given_style = T.unsafe(nil)); end end # Handles `Max` configuration parameters, especially setting them to an # appropriate value with --auto-gen-config. # -# @deprecated Use `exclude_limit ParameterName` instead. +# @deprecated Use `exclude_limit ` instead. # # source://rubocop//lib/rubocop/cop/mixin/configurable_max.rb#8 module RuboCop::Cop::ConfigurableMax @@ -4654,7 +4868,7 @@ module RuboCop::Cop::ConfigurableMax # source://rubocop//lib/rubocop/cop/mixin/configurable_max.rb#11 def max=(value); end - # source://rubocop//lib/rubocop/cop/mixin/configurable_max.rb#19 + # source://rubocop//lib/rubocop/cop/mixin/configurable_max.rb#23 def max_parameter_name; end end @@ -4687,22 +4901,22 @@ RuboCop::Cop::ConfigurableNumbering::FORMATS = T.let(T.unsafe(nil), Hash) # # source://rubocop//lib/rubocop/cop/cop.rb#11 class RuboCop::Cop::Cop < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/cop.rb#53 + # source://rubocop//lib/rubocop/cop/cop.rb#65 def add_offense(node_or_range, location: T.unsafe(nil), message: T.unsafe(nil), severity: T.unsafe(nil), &block); end # Called before any investigation # # @api private # - # source://rubocop//lib/rubocop/cop/cop.rb#103 + # source://rubocop//lib/rubocop/cop/cop.rb#121 def begin_investigation(processed_source, offset: T.unsafe(nil), original: T.unsafe(nil)); end # @deprecated # - # source://rubocop//lib/rubocop/cop/cop.rb#82 + # source://rubocop//lib/rubocop/cop/cop.rb#97 def corrections; end - # source://rubocop//lib/rubocop/cop/cop.rb#70 + # source://rubocop//lib/rubocop/cop/cop.rb#82 def find_location(node, loc); end # Returns the value of attribute offenses. @@ -4712,53 +4926,53 @@ class RuboCop::Cop::Cop < ::RuboCop::Cop::Base # Called after all on_... have been called # - # source://rubocop//lib/rubocop/cop/cop.rb#96 + # source://rubocop//lib/rubocop/cop/cop.rb#114 def on_investigation_end; end # Called before all on_... have been called # - # source://rubocop//lib/rubocop/cop/cop.rb#90 + # source://rubocop//lib/rubocop/cop/cop.rb#108 def on_new_investigation; end # @deprecated Use class method # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/cop.rb#76 + # source://rubocop//lib/rubocop/cop/cop.rb#88 def support_autocorrect?; end private - # source://rubocop//lib/rubocop/cop/cop.rb#121 + # source://rubocop//lib/rubocop/cop/cop.rb#139 def apply_correction(corrector); end # Override Base # - # source://rubocop//lib/rubocop/cop/cop.rb#117 + # source://rubocop//lib/rubocop/cop/cop.rb#135 def callback_argument(_range); end - # source://rubocop//lib/rubocop/cop/cop.rb#138 + # source://rubocop//lib/rubocop/cop/cop.rb#156 def correction_lambda; end - # source://rubocop//lib/rubocop/cop/cop.rb#144 + # source://rubocop//lib/rubocop/cop/cop.rb#162 def dedupe_on_node(node); end # Just for legacy # # @yield [corrector] # - # source://rubocop//lib/rubocop/cop/cop.rb#126 + # source://rubocop//lib/rubocop/cop/cop.rb#144 def emulate_v0_callsequence(corrector); end - # source://rubocop//lib/rubocop/cop/cop.rb#157 + # source://rubocop//lib/rubocop/cop/cop.rb#175 def range_for_original(range); end - # source://rubocop//lib/rubocop/cop/cop.rb#151 + # source://rubocop//lib/rubocop/cop/cop.rb#169 def suppress_clobbering; end class << self # @deprecated Use Registry.all # - # source://rubocop//lib/rubocop/cop/cop.rb#44 + # source://rubocop//lib/rubocop/cop/cop.rb#48 def all; end # source://rubocop//lib/rubocop/cop/cop.rb#29 @@ -4766,7 +4980,7 @@ class RuboCop::Cop::Cop < ::RuboCop::Cop::Base # @deprecated Use Registry.qualified_cop_name # - # source://rubocop//lib/rubocop/cop/cop.rb#49 + # source://rubocop//lib/rubocop/cop/cop.rb#57 def qualified_cop_name(name, origin); end # @deprecated Use Registry.global @@ -4878,7 +5092,7 @@ class RuboCop::Cop::Corrector < ::Parser::Source::TreeRewriter # Legacy # - # source://parser/3.2.2.3/lib/parser/source/tree_rewriter.rb#252 + # source://parser/3.3.4.2/lib/parser/source/tree_rewriter.rb#252 def rewrite; end # Swaps sources at the given ranges. @@ -4949,7 +5163,12 @@ module RuboCop::Cop::Documentation # @api private # - # source://rubocop//lib/rubocop/cop/documentation.rb#34 + # source://rubocop//lib/rubocop/cop/documentation.rb#40 + def builtin?(cop_class); end + + # @api private + # + # source://rubocop//lib/rubocop/cop/documentation.rb#35 def default_base_url; end # @api private @@ -4969,8 +5188,14 @@ module RuboCop::Cop::Documentation def base_url_for(cop_class, config); end # @api private + # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/documentation.rb#34 + # source://rubocop//lib/rubocop/cop/documentation.rb#40 + def builtin?(cop_class); end + + # @api private + # + # source://rubocop//lib/rubocop/cop/documentation.rb#35 def default_base_url; end # @api private @@ -5110,9 +5335,6 @@ class RuboCop::Cop::EachToForCorrector # source://rubocop//lib/rubocop/cop/correctors/each_to_for_corrector.rb#36 def offending_range; end - - # source://rubocop//lib/rubocop/cop/correctors/each_to_for_corrector.rb#44 - def replacement_range(end_pos); end end # source://rubocop//lib/rubocop/cop/correctors/each_to_for_corrector.rb#10 @@ -5268,45 +5490,39 @@ class RuboCop::Cop::ForToEachCorrector private - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#55 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#57 def collection_end; end # Returns the value of attribute collection_node. # - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#23 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#25 def collection_node; end - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#29 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#31 def collection_source; end - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#25 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#27 def correction; end - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#43 - def end_position; end + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#45 + def end_range; end # Returns the value of attribute for_node. # - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#23 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#25 def for_node; end - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#51 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#53 def keyword_begin; end - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#63 - def offending_range; end - - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#67 - def replacement_range(end_pos); end - # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#37 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#39 def requires_parentheses?; end # Returns the value of attribute variable_node. # - # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#23 + # source://rubocop//lib/rubocop/cop/correctors/for_to_each_corrector.rb#25 def variable_node; end end @@ -5319,37 +5535,53 @@ RuboCop::Cop::ForToEachCorrector::CORRECTION = T.let(T.unsafe(nil), String) class RuboCop::Cop::Force # @return [Force] a new instance of Force # - # source://rubocop//lib/rubocop/cop/force.rb#22 + # source://rubocop//lib/rubocop/cop/force.rb#32 def initialize(cops); end # Returns the value of attribute cops. # - # source://rubocop//lib/rubocop/cop/force.rb#7 + # source://rubocop//lib/rubocop/cop/force.rb#17 def cops; end - # source://rubocop//lib/rubocop/cop/force.rb#38 + # source://rubocop//lib/rubocop/cop/force.rb#50 def investigate(_processed_source); end - # source://rubocop//lib/rubocop/cop/force.rb#26 + # source://rubocop//lib/rubocop/cop/force.rb#36 def name; end - # source://rubocop//lib/rubocop/cop/force.rb#30 + # source://rubocop//lib/rubocop/cop/force.rb#40 def run_hook(method_name, *args); end class << self - # source://rubocop//lib/rubocop/cop/force.rb#9 + # source://rubocop//lib/rubocop/cop/force.rb#19 def all; end - # source://rubocop//lib/rubocop/cop/force.rb#18 + # source://rubocop//lib/rubocop/cop/force.rb#28 def force_name; end # @private # - # source://rubocop//lib/rubocop/cop/force.rb#13 + # source://rubocop//lib/rubocop/cop/force.rb#23 def inherited(subclass); end end end +# @api private +# +# source://rubocop//lib/rubocop/cop/force.rb#8 +class RuboCop::Cop::Force::HookError < ::StandardError + # @api private + # @return [HookError] a new instance of HookError + # + # source://rubocop//lib/rubocop/cop/force.rb#11 + def initialize(joining_cop); end + + # @api private + # + # source://rubocop//lib/rubocop/cop/force.rb#9 + def joining_cop; end +end + # Common functionality for dealing with frozen string literals. # # source://rubocop//lib/rubocop/cop/mixin/frozen_string_literal.rb#6 @@ -5410,9 +5642,38 @@ module RuboCop::Cop::GemDeclaration def gem_declaration?(param0 = T.unsafe(nil)); end end -# source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#5 +# source://rubocop//lib/rubocop/cop/gemspec/add_runtime_dependency.rb#5 module RuboCop::Cop::Gemspec; end +# Prefer `add_dependency` over `add_runtime_dependency` as the latter is +# considered soft-deprecated. +# +# @example +# +# # bad +# Gem::Specification.new do |spec| +# spec.add_runtime_dependency('rubocop') +# end +# +# # good +# Gem::Specification.new do |spec| +# spec.add_dependency('rubocop') +# end +# +# source://rubocop//lib/rubocop/cop/gemspec/add_runtime_dependency.rb#21 +class RuboCop::Cop::Gemspec::AddRuntimeDependency < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/gemspec/add_runtime_dependency.rb#28 + def on_send(node); end +end + +# source://rubocop//lib/rubocop/cop/gemspec/add_runtime_dependency.rb#24 +RuboCop::Cop::Gemspec::AddRuntimeDependency::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/gemspec/add_runtime_dependency.rb#26 +RuboCop::Cop::Gemspec::AddRuntimeDependency::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) + # Enforce that gem dependency version specifications or a commit reference (branch, # ref, or tag) are either required or forbidden. # @@ -5480,7 +5741,7 @@ class RuboCop::Cop::Gemspec::DependencyVersion < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#120 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#118 def add_dependency_method?(method_name); end # @return [Boolean] @@ -5493,40 +5754,40 @@ class RuboCop::Cop::Gemspec::DependencyVersion < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#134 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#132 def forbidden_offense?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#140 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#138 def forbidden_style?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#114 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#112 def match_block_variable_name?(receiver_name); end # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#104 - def message(range); end + def message(_range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#124 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#122 def offense?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#128 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#126 def required_offense?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#144 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#142 def required_style?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#148 + # source://rubocop//lib/rubocop/cop/gemspec/dependency_version.rb#146 def version_specification?(expression); end end @@ -5715,8 +5976,8 @@ RuboCop::Cop::Gemspec::DevelopmentDependencies::RESTRICT_ON_SEND = T.let(T.unsaf # # # good # Gem::Specification.new do |spec| -# spec.add_runtime_dependency('parallel', '~> 1.10') -# spec.add_runtime_dependency('parser', '>= 2.3.3.1', '< 3.0') +# spec.add_dependency('parallel', '~> 1.10') +# spec.add_dependency('parser', '>= 2.3.3.1', '< 3.0') # end # # source://rubocop//lib/rubocop/cop/gemspec/duplicated_assignment.rb#37 @@ -5788,34 +6049,40 @@ RuboCop::Cop::Gemspec::DuplicatedAssignment::MSG = T.let(T.unsafe(nil), String) # spec.add_runtime_dependency 'rubocop' # # spec.add_runtime_dependency 'rspec' -# -# # good only if TreatCommentsAsGroupSeparators is true +# @example TreatCommentsAsGroupSeparators: true (default) +# # good +# # For code quality +# spec.add_dependency 'rubocop' +# # For tests +# spec.add_dependency 'rspec' +# @example TreatCommentsAsGroupSeparators: false +# # bad # # For code quality # spec.add_dependency 'rubocop' # # For tests # spec.add_dependency 'rspec' # -# source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#53 +# source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#61 class RuboCop::Cop::Gemspec::OrderedDependencies < ::RuboCop::Cop::Base include ::RuboCop::Cop::OrderedGemNode extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#87 + # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#95 def dependency_declarations(param0); end - # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#61 + # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#69 def on_new_investigation; end private - # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#82 + # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#90 def get_dependency_name(node); end - # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#76 + # source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#84 def previous_declaration(node); end end -# source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#57 +# source://rubocop//lib/rubocop/cop/gemspec/ordered_dependencies.rb#65 RuboCop::Cop::Gemspec::OrderedDependencies::MSG = T.let(T.unsafe(nil), String) # Requires a gemspec to have `rubygems_mfa_required` metadata set. @@ -5973,7 +6240,7 @@ class RuboCop::Cop::Gemspec::RequiredRubyVersion < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#78 def on_new_investigation; end - # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#82 + # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#84 def on_send(node); end # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#65 @@ -5983,13 +6250,13 @@ class RuboCop::Cop::Gemspec::RequiredRubyVersion < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#94 + # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#96 def dynamic_version?(node); end - # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#100 + # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#102 def extract_ruby_version(required_ruby_version); end - # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#116 + # source://rubocop//lib/rubocop/cop/gemspec/required_ruby_version.rb#120 def not_equal_message(required_ruby_version, target_ruby_version); end end @@ -6013,15 +6280,15 @@ RuboCop::Cop::Gemspec::RequiredRubyVersion::RESTRICT_ON_SEND = T.let(T.unsafe(ni # # bad # Gem::Specification.new do |spec| # if RUBY_VERSION >= '3.0' -# spec.add_runtime_dependency 'gem_a' +# spec.add_dependency 'gem_a' # else -# spec.add_runtime_dependency 'gem_b' +# spec.add_dependency 'gem_b' # end # end # # # good # Gem::Specification.new do |spec| -# spec.add_runtime_dependency 'gem_a' +# spec.add_dependency 'gem_a' # end # # source://rubocop//lib/rubocop/cop/gemspec/ruby_version_globals_usage.rb#28 @@ -6406,61 +6673,66 @@ module RuboCop::Cop::HashShorthandSyntax # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#122 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#126 def brackets?(method_dispatch_node); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#152 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#156 def breakdown_value_types_of_hash(hash_node); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#99 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#103 def def_node_that_require_parentheses(node); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#176 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#185 def each_omittable_value_pair(hash_value_type_breakdown, &block); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#172 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#181 def each_omitted_value_pair(hash_value_type_breakdown, &block); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#77 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#81 def enforced_shorthand_syntax; end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#114 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#118 def find_ancestor_method_dispatch_node(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#164 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#168 def hash_with_mixed_shorthand_syntax?(hash_value_type_breakdown); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#168 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#172 def hash_with_values_that_cant_be_omitted?(hash_value_type_breakdown); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#71 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#176 + def ignore_explicit_omissible_hash_shorthand_syntax?(hash_value_type_breakdown); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#75 def ignore_hash_shorthand_syntax?(pair_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#66 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#69 def ignore_mixed_hash_shorthand_syntax?(hash_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#137 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#141 def last_expression?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#145 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#149 def method_dispatch_as_argument?(method_dispatch_node); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#180 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#189 def mixed_shorthand_syntax_check(hash_value_type_breakdown); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#196 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#205 def no_mixed_shorthand_syntax_check(hash_value_type_breakdown); end # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#49 @@ -6468,22 +6740,22 @@ module RuboCop::Cop::HashShorthandSyntax # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#81 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#85 def require_hash_value?(hash_key_source, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#90 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#94 def require_hash_value_for_around_hash_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#126 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#130 def use_element_of_hash_literal_as_receiver?(ancestor, parent); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#131 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#135 def use_modifier_form_without_parenthesized_method_call?(ancestor); end end @@ -6496,12 +6768,12 @@ RuboCop::Cop::HashShorthandSyntax::DO_NOT_MIX_MSG_PREFIX = T.let(T.unsafe(nil), # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#11 RuboCop::Cop::HashShorthandSyntax::DO_NOT_MIX_OMIT_VALUE_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#206 +# source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#216 class RuboCop::Cop::HashShorthandSyntax::DefNode < ::Struct - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#215 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#225 def first_argument; end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#219 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#229 def last_argument; end # Returns the value of attribute node @@ -6515,7 +6787,7 @@ class RuboCop::Cop::HashShorthandSyntax::DefNode < ::Struct # @return [Object] the newly set value def node=(_); end - # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#207 + # source://rubocop//lib/rubocop/cop/mixin/hash_shorthand_syntax.rb#217 def selector; end class << self @@ -6771,7 +7043,7 @@ module RuboCop::Cop::Heredoc # source://rubocop//lib/rubocop/cop/mixin/heredoc.rb#28 def delimiter_string(node); end - # source://rubocop//lib/rubocop/cop/mixin/heredoc.rb#32 + # source://rubocop//lib/rubocop/cop/mixin/heredoc.rb#34 def heredoc_type(node); end # source://rubocop//lib/rubocop/cop/mixin/heredoc.rb#23 @@ -6820,7 +7092,7 @@ RuboCop::Cop::IfThenCorrector::DEFAULT_INDENTATION_WIDTH = T.let(T.unsafe(nil), # @deprecated IgnoredMethods class has been replaced with AllowedMethods. # -# source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#40 +# source://rubocop//lib/rubocop/cop/mixin/allowed_methods.rb#46 RuboCop::Cop::IgnoredMethods = RuboCop::Cop::AllowedMethods # Handles adding and checking ignored nodes. @@ -6848,7 +7120,7 @@ end # @deprecated IgnoredPattern class has been replaced with AllowedPattern. # -# source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#54 +# source://rubocop//lib/rubocop/cop/mixin/allowed_pattern.rb#66 RuboCop::Cop::IgnoredPattern = RuboCop::Cop::AllowedPattern # Common functionality for checking integer nodes. @@ -6899,74 +7171,74 @@ class RuboCop::Cop::LambdaLiteralToMethodCorrector # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#115 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#118 def arg_to_unparenthesized_call?; end # Returns the value of attribute arguments. # - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#31 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#34 def arguments; end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#99 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#102 def arguments_begin_pos; end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#95 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#98 def arguments_end_pos; end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#107 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#110 def block_begin; end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#103 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#106 def block_end; end # Returns the value of attribute block_node. # - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#31 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#34 def block_node; end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#56 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#59 def insert_arguments(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#40 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#43 def insert_separating_space(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#85 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#88 def lambda_arg_string; end # Returns the value of attribute method. # - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#31 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#34 def method; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#89 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#92 def needs_separating_space?; end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#50 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#53 def remove_arguments(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#63 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#66 def remove_leading_whitespace(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#71 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#74 def remove_trailing_whitespace(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#33 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#36 def remove_unparenthesized_whitespace(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#76 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#79 def replace_delimiters(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#46 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#49 def replace_selector(corrector); end - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#111 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#114 def selector_end; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#131 + # source://rubocop//lib/rubocop/cop/correctors/lambda_literal_to_method_corrector.rb#134 def separating_space?; end end @@ -7225,7 +7497,7 @@ RuboCop::Cop::Layout::ArrayAlignment::FIXED_INDENT_MSG = T.let(T.unsafe(nil), St # right-hand-side of a multi-line assignment. # # The indentation of the remaining lines can be corrected with -# other cops such as `IndentationConsistency` and `EndAlignment`. +# other cops such as `Layout/IndentationConsistency` and `Layout/EndAlignment`. # # @example # # bad @@ -7240,7 +7512,7 @@ RuboCop::Cop::Layout::ArrayAlignment::FIXED_INDENT_MSG = T.let(T.unsafe(nil), St # 'bar' # end # -# source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#24 +# source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#25 class RuboCop::Cop::Layout::AssignmentIndentation < ::RuboCop::Cop::Base include ::RuboCop::Cop::CheckAssignment include ::RuboCop::Cop::Alignment @@ -7248,17 +7520,17 @@ class RuboCop::Cop::Layout::AssignmentIndentation < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#42 + # source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#43 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#33 + # source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#34 def check_assignment(node, rhs); end - # source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#46 + # source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#47 def leftmost_multiple_assignment(node); end end -# source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#29 +# source://rubocop//lib/rubocop/cop/layout/assignment_indentation.rb#30 RuboCop::Cop::Layout::AssignmentIndentation::MSG = T.let(T.unsafe(nil), String) # Checks whether the end keyword of `begin` is aligned properly. @@ -7791,7 +8063,7 @@ RuboCop::Cop::Layout::CaseIndentation::MSG = T.let(T.unsafe(nil), String) # end # end # -# source://rubocop//lib/rubocop/cop/layout/class_structure.rb#135 +# source://rubocop//lib/rubocop/cop/layout/class_structure.rb#142 class RuboCop::Cop::Layout::ClassStructure < ::RuboCop::Cop::Base include ::RuboCop::Cop::VisibilityHelp include ::RuboCop::Cop::CommentsHelp @@ -7800,35 +8072,35 @@ class RuboCop::Cop::Layout::ClassStructure < ::RuboCop::Cop::Base # Validates code style on class declaration. # Add offense when find a node out of expected order. # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#151 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#158 def on_class(class_node); end # Validates code style on class declaration. # Add offense when find a node out of expected order. # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#151 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#158 def on_sclass(class_node); end private # Autocorrect by swapping between two nodes autocorrecting them # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#167 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#174 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#298 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#305 def begin_pos_with_comment(node); end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#321 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#328 def buffer; end # Setting categories hash allow you to group methods in group to match # in the {expected_order}. # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#333 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#340 def categories; end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#227 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#234 def class_elements(class_node); end # Classifies a node to match with something in the {expected_order} @@ -7840,21 +8112,21 @@ class RuboCop::Cop::Layout::ClassStructure < ::RuboCop::Cop::Base # by method name # @return String otherwise trying to {humanize_node} of the current node # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#187 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#194 def classify(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#264 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#271 def dynamic_constant?(node); end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#288 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#295 def end_position_for(node); end # Load expected order from `ExpectedOrder` config. # Define new terms in the expected order by adding new {categories}. # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#327 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#334 def expected_order; end # Categorize a node according to the {expected_order} @@ -7864,51 +8136,51 @@ class RuboCop::Cop::Layout::ClassStructure < ::RuboCop::Cop::Base # @param node to be analysed. # @return [String] with the key category or the `method_name` as string # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#205 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#212 def find_category(node); end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#317 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#324 def find_heredoc(node); end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#255 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#262 def humanize_node(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#239 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#246 def ignore?(node, classification); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#246 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#253 def ignore_for_autocorrect?(node, sibling); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#282 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#289 def marked_as_private_constant?(node, name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#272 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#279 def private_constant?(node); end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#313 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#320 def start_line_position(node); end - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#218 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#225 def walk_over_nested_class_definition(class_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#309 + # source://rubocop//lib/rubocop/cop/layout/class_structure.rb#316 def whole_line_comment_at_line?(line); end end -# source://rubocop//lib/rubocop/cop/layout/class_structure.rb#140 +# source://rubocop//lib/rubocop/cop/layout/class_structure.rb#147 RuboCop::Cop::Layout::ClassStructure::HUMANIZED_NODE_TYPE = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/layout/class_structure.rb#147 +# source://rubocop//lib/rubocop/cop/layout/class_structure.rb#154 RuboCop::Cop::Layout::ClassStructure::MSG = T.let(T.unsafe(nil), String) # Checks the indentation of here document closings. @@ -8246,43 +8518,40 @@ RuboCop::Cop::Layout::CommentIndentation::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # if # some_condition # do_something # end -# @example # # # good -# # if some_condition # do_something # end # -# source://rubocop//lib/rubocop/cop/layout/condition_position.rb#25 +# source://rubocop//lib/rubocop/cop/layout/condition_position.rb#21 class RuboCop::Cop::Layout::ConditionPosition < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#31 + # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#27 def on_if(node); end - # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#37 + # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#33 def on_until(node); end - # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#37 + # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#33 def on_while(node); end private - # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#44 + # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#40 def check(node); end - # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#58 + # source://rubocop//lib/rubocop/cop/layout/condition_position.rb#54 def message(condition); end end -# source://rubocop//lib/rubocop/cop/layout/condition_position.rb#29 +# source://rubocop//lib/rubocop/cop/layout/condition_position.rb#25 RuboCop::Cop::Layout::ConditionPosition::MSG = T.let(T.unsafe(nil), String) # Checks whether the end keywords of method definitions are @@ -8373,11 +8642,6 @@ class RuboCop::Cop::Layout::DotPosition < ::RuboCop::Cop::Base private - # @return [Boolean] - # - # source://rubocop//lib/rubocop/cop/layout/dot_position.rb#137 - def ampersand_dot?(node); end - # source://rubocop//lib/rubocop/cop/layout/dot_position.rb#49 def autocorrect(corrector, dot, node); end @@ -8565,42 +8829,58 @@ class RuboCop::Cop::Layout::EmptyComment < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#131 + # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#133 def allow_border_comment?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#135 + # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#137 def allow_margin_comment?; end # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#97 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#127 + # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#129 def comment_text(comment); end # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#108 def concat_consecutive_comments(comments); end - # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#139 + # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#141 def current_token(comment); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#117 + # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#119 def empty_comment_only?(comment_text); end # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#85 def investigate(comments); end - # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#143 + # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#145 def previous_token(node); end end # source://rubocop//lib/rubocop/cop/layout/empty_comment.rb#67 RuboCop::Cop::Layout::EmptyComment::MSG = T.let(T.unsafe(nil), String) -# Enforces empty line after guard clause +# Enforces empty line after guard clause. +# +# This cop allows `# :nocov:` directive after guard clause because +# SimpleCov excludes code from the coverage report by wrapping it in `# :nocov:`: +# +# [source,ruby] +# ---- +# def foo +# # :nocov: +# return if condition +# # :nocov: +# bar +# end +# ---- +# +# Refer to SimpleCov's documentation for more details: +# https://github.com/simplecov-ruby/simplecov#ignoringskipping-code # # @example # @@ -8633,90 +8913,106 @@ RuboCop::Cop::Layout::EmptyComment::MSG = T.let(T.unsafe(nil), String) # end # end # -# source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#38 +# source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#54 class RuboCop::Cop::Layout::EmptyLineAfterGuardClause < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::PathUtil extend ::RuboCop::Cop::Util - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#46 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#63 def on_if(node); end private - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#65 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#84 def autocorrect(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#87 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#106 def contains_guard_clause?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#80 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#99 def correct_style?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#160 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#181 def heredoc?(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#153 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#174 def heredoc_line(node, heredoc_node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#129 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#148 def last_heredoc_argument(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#143 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#162 def last_heredoc_argument_node(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#172 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#199 def multiple_statements_on_line?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#98 - def next_line_empty?(line); end + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#121 + def next_line_allowed_directive_comment?(line); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#91 - def next_line_empty_or_enable_directive_comment?(line); end + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#117 + def next_line_empty?(line); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#102 - def next_line_enable_directive_comment?(line); end + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#110 + def next_line_empty_or_allowed_directive_comment?(line); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#108 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#127 def next_line_rescue_or_ensure?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#122 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#141 def next_sibling_empty_or_guard_clause?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#113 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#132 def next_sibling_parent_empty_or_else?(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#164 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#191 def offense_location(node); end + + # SimpleCov excludes code from the coverage report by wrapping it in `# :nocov:`: + # https://github.com/simplecov-ruby/simplecov#ignoringskipping-code + # + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#208 + def simplecov_directive_comment?(comment); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#185 + def use_heredoc_in_condition?(condition); end end -# source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#44 +# source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#60 RuboCop::Cop::Layout::EmptyLineAfterGuardClause::END_OF_HEREDOC_LINE = T.let(T.unsafe(nil), Integer) -# source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#43 +# source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#59 RuboCop::Cop::Layout::EmptyLineAfterGuardClause::MSG = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/layout/empty_line_after_guard_clause.rb#61 +RuboCop::Cop::Layout::EmptyLineAfterGuardClause::SIMPLE_DIRECTIVE_COMMENT_PATTERN = T.let(T.unsafe(nil), Regexp) + # Checks for a newline after the final magic comment. # # @example @@ -8745,15 +9041,19 @@ class RuboCop::Cop::Layout::EmptyLineAfterMagicComment < ::RuboCop::Cop::Base private + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_magic_comment.rb#61 + def comments_before_code(source); end + # Find the last magic comment in the source file. # - # Take all comments that precede the first line of code, select the + # Take all comments that precede the first line of code (or just take + # them all in the case when there is no code), select the # magic comments, and return the last magic comment in the file. # # @return [Parser::Source::Comment] if magic comments exist before code # @return [nil] otherwise # - # source://rubocop//lib/rubocop/cop/layout/empty_line_after_magic_comment.rb#54 + # source://rubocop//lib/rubocop/cop/layout/empty_line_after_magic_comment.rb#55 def last_magic_comment(source); end # source://rubocop//lib/rubocop/cop/layout/empty_line_after_magic_comment.rb#43 @@ -8964,7 +9264,7 @@ class RuboCop::Cop::Layout::EmptyLineBetweenDefs < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#144 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#145 def autocorrect(corrector, prev_def, node, count); end # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#130 @@ -8983,73 +9283,84 @@ class RuboCop::Cop::Layout::EmptyLineBetweenDefs < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#267 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#290 def allowance_range?; end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#251 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#274 def autocorrect_insert_lines(corrector, newline_pos, count); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#244 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#267 def autocorrect_remove_lines(corrector, newline_pos, count); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#208 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#227 def blank_lines_count_between(first_def_node, second_def_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#162 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#171 def candidate?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#172 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#191 def class_candidate?(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#232 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#255 def def_end(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#228 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#163 + def def_location(correction_node); end + + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#247 def def_start(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#236 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#178 + def empty_line_between_macros; end + + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#259 def end_loc(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#186 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#205 def expected_lines; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#204 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#223 def line_count_allowed?(count); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#220 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#239 def lines_between_defs(first_def_node, second_def_node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#216 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#182 + def macro_candidate?(node); end + + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#235 def maximum_empty_lines; end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#180 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#199 def message(node, count: T.unsafe(nil)); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#168 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#187 def method_candidate?(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#212 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#231 def minimum_empty_lines; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#176 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#195 def module_candidate?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#195 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#214 def multiple_blank_lines_groups?(first_def_node, second_def_node); end - # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#258 + # source://rubocop//lib/rubocop/cop/layout/empty_line_between_defs.rb#281 def node_type(node); end class << self @@ -9723,36 +10034,42 @@ class RuboCop::Cop::Layout::EmptyLinesAroundExceptionHandlingKeywords < ::RuboCo include ::RuboCop::Cop::Layout::EmptyLinesAroundBody extend ::RuboCop::Cop::AutoCorrector + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#67 + def on_block(node); end + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#67 def on_def(node); end # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#67 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#72 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#74 def on_kwbegin(node); end + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#67 + def on_numblock(node); end + private - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#79 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#81 def check_body(body, line_of_def_or_kwbegin); end - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#106 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#108 def keyword_locations(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#123 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#125 def keyword_locations_in_ensure(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#119 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#121 def keyword_locations_in_rescue(node); end - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#94 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#96 def last_rescue_and_end_on_same_line(body); end - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#98 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#100 def message(location, keyword); end - # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#102 + # source://rubocop//lib/rubocop/cop/layout/empty_lines_around_exception_handling_keywords.rb#104 def style; end end @@ -9869,7 +10186,9 @@ RuboCop::Cop::Layout::EmptyLinesAroundModuleBody::KIND = T.let(T.unsafe(nil), St # This `Layout/EndAlignment` cop aligns with keywords (e.g. `if`, `while`, `case`) # by default. On the other hand, `Layout/BeginEndAlignment` cop aligns with # `EnforcedStyleAlignWith: start_of_line` by default due to `||= begin` tends -# to align with the start of the line. These style can be configured by each cop. +# to align with the start of the line. `Layout/DefEndAlignment` cop also aligns with +# `EnforcedStyleAlignWith: start_of_line` by default. +# These style can be configured by each cop. # # @example EnforcedStyleAlignWith: keyword (default) # # bad @@ -9920,7 +10239,7 @@ RuboCop::Cop::Layout::EmptyLinesAroundModuleBody::KIND = T.let(T.unsafe(nil), St # if true # end # -# source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#75 +# source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#77 class RuboCop::Cop::Layout::EndAlignment < ::RuboCop::Cop::Base include ::RuboCop::Cop::CheckAssignment include ::RuboCop::Cop::ConfigurableEnforcedStyle @@ -9928,54 +10247,54 @@ class RuboCop::Cop::Layout::EndAlignment < ::RuboCop::Cop::Base include ::RuboCop::Cop::EndKeywordAlignment extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#105 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#111 def on_case(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#105 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#111 def on_case_match(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#81 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#83 def on_class(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#93 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#99 def on_if(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#89 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#95 def on_module(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#85 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#87 def on_sclass(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#101 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#107 def on_until(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#97 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#103 def on_while(node); end private - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#161 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#167 def alignment_node(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#172 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#184 def alignment_node_for_variable_style(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#142 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#148 def asgn_variable_align_with(outer_node, inner_node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#190 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#202 def assignment_or_operator_method(node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#116 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#122 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#131 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#137 def check_asgn_alignment(outer_node, inner_node); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#120 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#126 def check_assignment(node, rhs); end - # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#152 + # source://rubocop//lib/rubocop/cop/layout/end_alignment.rb#158 def check_other_alignment(node); end end @@ -10078,13 +10397,13 @@ class RuboCop::Cop::Layout::ExtraSpacing < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#176 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#170 def align_column(asgn_token); end - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#153 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#147 def align_equal_sign(corrector, token, align_to); end - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#143 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#137 def align_equal_signs(range, corrector); end # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#52 @@ -10092,46 +10411,46 @@ class RuboCop::Cop::Layout::ExtraSpacing < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#109 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#103 def aligned_tok?(token); end - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#165 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#159 def all_relevant_assignment_lines(line_number); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#185 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#179 def allow_for_trailing_comments?; end - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#78 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#72 def check_assignment(token); end - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#87 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#81 def check_other(token1, token2, ast); end - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#68 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#62 def check_tokens(ast, token1, token2); end # @yield [range_between(start_pos, end_pos)] # - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#97 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#91 def extra_space_range(token1, token2); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#139 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#133 def force_equal_sign_alignment?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#117 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#111 def ignored_range?(ast, start_pos); end # Returns an array of ranges that should not be reported. It's the # extra spaces between the keys and values in a multiline hash, # since those are handled by the Layout/HashAlignment cop. # - # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#124 + # source://rubocop//lib/rubocop/cop/layout/extra_spacing.rb#118 def ignored_ranges(ast); end end @@ -10252,8 +10571,8 @@ RuboCop::Cop::Layout::ExtraSpacing::MSG_UNNECESSARY = T.let(T.unsafe(nil), Strin # second_params # @example EnforcedStyle: special_for_inner_method_call # # The first argument should normally be indented one step more than -# # the preceding line, but if it's a argument for a method call that -# # is itself a argument in a method call, then the inner argument +# # the preceding line, but if it's an argument for a method call that +# # is itself an argument in a method call, then the inner argument # # should be indented relative to the inner method. # # # good @@ -10364,7 +10683,10 @@ RuboCop::Cop::Layout::FirstArgumentIndentation::MSG = T.let(T.unsafe(nil), Strin # Checks the indentation of the first element in an array literal # where the opening bracket and the first element are on separate lines. -# The other elements' indentations are handled by the ArrayAlignment cop. +# The other elements' indentations are handled by `Layout/ArrayAlignment` cop. +# +# This cop will respect `Layout/ArrayAlignment` and will not work when +# `EnforcedStyle: with_fixed_indentation` is specified for `Layout/ArrayAlignment`. # # By default, array literals that are arguments in a method call with # parentheses, and where the opening square bracket of the array is on the @@ -10384,7 +10706,7 @@ RuboCop::Cop::Layout::FirstArgumentIndentation::MSG = T.let(T.unsafe(nil), Strin # # element are on separate lines is indented one step (two spaces) more # # than the position inside the opening parenthesis. # -# #bad +# # bad # array = [ # :value # ] @@ -10392,7 +10714,7 @@ RuboCop::Cop::Layout::FirstArgumentIndentation::MSG = T.let(T.unsafe(nil), Strin # :no_difference # ]) # -# #good +# # good # array = [ # :value # ] @@ -10405,7 +10727,7 @@ RuboCop::Cop::Layout::FirstArgumentIndentation::MSG = T.let(T.unsafe(nil), Strin # # separate lines is indented the same as an array literal which is not # # defined inside a method call. # -# #bad +# # bad # # consistent # array = [ # :value @@ -10414,7 +10736,7 @@ RuboCop::Cop::Layout::FirstArgumentIndentation::MSG = T.let(T.unsafe(nil), Strin # :its_like_this # ]) # -# #good +# # good # array = [ # :value # ] @@ -10425,61 +10747,69 @@ RuboCop::Cop::Layout::FirstArgumentIndentation::MSG = T.let(T.unsafe(nil), Strin # # The `align_brackets` style enforces that the opening and closing # # brackets are indented to the same position. # -# #bad +# # bad # # align_brackets # and_now_for_something = [ # :completely_different # ] # -# #good +# # good # # align_brackets # and_now_for_something = [ # :completely_different # ] # -# source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#82 +# source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#85 class RuboCop::Cop::Layout::FirstArrayElementIndentation < ::RuboCop::Cop::Base include ::RuboCop::Cop::Alignment include ::RuboCop::Cop::ConfigurableEnforcedStyle include ::RuboCop::Cop::MultilineElementIndentation extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#91 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#94 def on_array(node); end - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#95 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#100 def on_csend(node); end - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#95 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#100 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#104 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#191 + def array_alignment_config; end + + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#111 def autocorrect(corrector, node); end # Returns the description of what the correct indentation is based on. # - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#142 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#149 def base_description(indent_base_type); end - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#108 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#115 def brace_alignment_style; end - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#112 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#119 def check(array_node, left_parenthesis); end - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#126 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#133 def check_right_bracket(right_bracket, first_elem, left_bracket, left_parenthesis); end - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#155 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#185 + def enforce_first_argument_with_fixed_indentation?; end + + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#162 def message(base_description); end - # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#163 + # source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#170 def message_for_right_bracket(indent_base_type); end end -# source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#88 +# source://rubocop//lib/rubocop/cop/layout/first_array_element_indentation.rb#91 RuboCop::Cop::Layout::FirstArrayElementIndentation::MSG = T.let(T.unsafe(nil), String) # Checks for a line break before the first element in a @@ -11478,9 +11808,9 @@ RuboCop::Cop::Layout::HeredocArgumentClosingParenthesis::MSG = T.let(T.unsafe(ni # Checks the indentation of the here document bodies. The bodies # are indented one step. # -# Note: When ``Layout/LineLength``'s `AllowHeredoc` is false (not default), +# NOTE: When ``Layout/LineLength``'s `AllowHeredoc` is false (not default), # this cop does not add any offenses for long here documents to -# avoid `Layout/LineLength`'s offenses. +# avoid ``Layout/LineLength``'s offenses. # # @example # # bad @@ -11498,71 +11828,72 @@ class RuboCop::Cop::Layout::HeredocIndentation < ::RuboCop::Cop::Base include ::RuboCop::Cop::Alignment include ::RuboCop::Cop::Heredoc extend ::RuboCop::Cop::AutoCorrector + extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#33 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#36 def on_heredoc(node); end private - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#117 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#120 def adjust_minus(corrector, node); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#112 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#115 def adjust_squiggly(corrector, node); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#141 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#144 def base_indent_level(node); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#152 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#155 def heredoc_body(node); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#156 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#159 def heredoc_end(node); end # Returns '~', '-' or nil # - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#148 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#151 def heredoc_indent_type(node); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#123 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#126 def indented_body(node); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#130 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#133 def indented_end(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#88 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#91 def line_too_long?(node); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#100 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#103 def longest_line(lines); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#108 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#111 def max_line_length; end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#66 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#69 def message(heredoc_indent_type); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#54 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#57 def register_offense(node, heredoc_indent_type); end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#76 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#79 def type_message(indentation_width, current_indent_type); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#104 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#107 def unlimited_heredoc_length?; end - # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#84 + # source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#87 def width_message(indentation_width); end end -# source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#29 +# source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#32 RuboCop::Cop::Layout::HeredocIndentation::TYPE_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#31 +# source://rubocop//lib/rubocop/cop/layout/heredoc_indentation.rb#34 RuboCop::Cop::Layout::HeredocIndentation::WIDTH_MSG = T.let(T.unsafe(nil), String) # Checks for inconsistent indentation. @@ -12222,35 +12553,38 @@ class RuboCop::Cop::Layout::LineContinuationLeadingSpace < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#105 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#113 def autocorrect(corrector, offense_range, insert_pos, spaces); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#101 - def continuation?(line); end + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#106 + def continuation?(line, line_num, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#130 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#138 def enforced_style_leading?; end - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#79 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#76 + def investigate(first_line, second_line, end_of_first_line); end + + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#84 def investigate_leading_style(first_line, second_line, end_of_first_line); end - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#90 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#95 def investigate_trailing_style(first_line, second_line, end_of_first_line); end - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#110 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#118 def leading_offense_range(end_of_first_line, matches); end - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#122 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#130 def message(_range); end - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#75 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#72 def raw_lines(node); end - # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#116 + # source://rubocop//lib/rubocop/cop/layout/line_continuation_leading_space.rb#124 def trailing_offense_range(end_of_first_line, matches); end end @@ -12412,7 +12746,7 @@ class RuboCop::Cop::Layout::LineEndStringConcatenationIndentation < ::RuboCop::C include ::RuboCop::Cop::Alignment extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#95 + # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#97 def autocorrect(corrector, node); end # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#83 @@ -12420,26 +12754,26 @@ class RuboCop::Cop::Layout::LineEndStringConcatenationIndentation < ::RuboCop::C private - # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#135 + # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#137 def add_offense_and_correction(node, message); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#107 + # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#109 def always_indented?(dstr_node); end - # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#126 + # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#128 def base_column(child); end - # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#111 + # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#113 def check_aligned(children, start_index); end - # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#120 + # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#122 def check_indented(children); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#101 + # source://rubocop//lib/rubocop/cop/layout/line_end_string_concatenation_indentation.rb#103 def strings_concatenated_with_backslash?(dstr_node); end end @@ -12464,29 +12798,29 @@ RuboCop::Cop::Layout::LineEndStringConcatenationIndentation::PARENT_TYPES_FOR_IN # split across lines. These include arrays, hashes, and # method calls with argument lists. # -# If autocorrection is enabled, the following Layout cops +# If autocorrection is enabled, the following cops # are recommended to further format the broken lines. # (Many of these are enabled by default.) # -# * ArgumentAlignment -# * ArrayAlignment -# * BlockAlignment -# * BlockDelimiters -# * BlockEndNewline -# * ClosingParenthesisIndentation -# * FirstArgumentIndentation -# * FirstArrayElementIndentation -# * FirstHashElementIndentation -# * FirstParameterIndentation -# * HashAlignment -# * IndentationWidth -# * MultilineArrayLineBreaks -# * MultilineBlockLayout -# * MultilineHashBraceLayout -# * MultilineHashKeyLineBreaks -# * MultilineMethodArgumentLineBreaks -# * MultilineMethodParameterLineBreaks -# * ParameterAlignment +# * `Layout/ArgumentAlignment` +# * `Layout/ArrayAlignment` +# * `Layout/BlockAlignment` +# * `Layout/BlockEndNewline` +# * `LayoutClosingParenthesisIndentation` +# * `LayoutFirstArgumentIndentation` +# * `LayoutFirstArrayElementIndentation` +# * `LayoutFirstHashElementIndentation` +# * `LayoutFirstParameterIndentation` +# * `LayoutHashAlignment` +# * `LayoutIndentationWidth` +# * `LayoutMultilineArrayLineBreaks` +# * `LayoutMultilineBlockLayout` +# * `LayoutMultilineHashBraceLayout` +# * `LayoutMultilineHashKeyLineBreaks` +# * `LayoutMultilineMethodArgumentLineBreaks` +# * `LayoutMultilineMethodParameterLineBreaks` +# * `Layout/ParameterAlignment` +# * `Style/BlockDelimiters` # # Together, these cops will pretty print hashes, arrays, # method calls, etc. For example, let's say the max columns @@ -13416,10 +13750,13 @@ class RuboCop::Cop::Layout::MultilineMethodCallIndentation < ::RuboCop::Cop::Bas # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#101 def extra_indentation(given_style, parent); end - # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#222 + # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#226 + def find_multiline_block_chain_node(node); end + + # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#237 def first_call_has_a_dot(node); end - # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#213 + # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#217 def get_dot_right_above(node); end # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#113 @@ -13433,12 +13770,12 @@ class RuboCop::Cop::Layout::MultilineMethodCallIndentation < ::RuboCop::Cop::Bas # @yield [operation_rhs.first_argument] # - # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#232 + # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#247 def operation_rhs(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#242 + # source://rubocop//lib/rubocop/cop/layout/multiline_method_call_indentation.rb#257 def operator_rhs?(node, receiver); end # a @@ -13897,61 +14234,82 @@ class RuboCop::Cop::Layout::RedundantLineBreak < ::RuboCop::Cop::Base include ::RuboCop::Cop::CheckAssignment extend ::RuboCop::Cop::AutoCorrector + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#55 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#51 + def on_lvasgn(node); end + + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#55 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#64 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#73 def check_assignment(node, _rhs); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#112 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#133 def comment_within?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#82 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#103 def configured_to_not_be_inspected?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#106 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#127 def convertible_block?(node); end - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#132 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#69 + def end_with_percent_blank_string?(processed_source); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#97 + def index_access_call_chained?(node); end + + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#155 def max_line_length; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#77 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#86 def offense?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#89 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#110 def other_cop_takes_precedence?(node); end - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#70 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#79 def register_offense(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#95 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#93 + def require_backslash?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#116 def single_line_block_chain_enabled?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#99 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#120 def suitable_as_single_line?(node); end - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#123 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#146 def to_single_line(source); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#118 + # source://rubocop//lib/rubocop/cop/layout/redundant_line_break.rb#141 def too_long?(node); end end @@ -14086,21 +14444,29 @@ class RuboCop::Cop::Layout::SingleLineBlockChain < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#28 + # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#32 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#32 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#51 + # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#56 def call_method_after_block?(node, dot_range, closing_block_delimiter_line_num); end - # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#35 + # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#40 def offending_range(node); end - # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#57 + # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#62 def selector_range(node); end + + class << self + # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#28 + def autocorrect_incompatible_with; end + end end # source://rubocop//lib/rubocop/cop/layout/single_line_block_chain.rb#26 @@ -14163,6 +14529,13 @@ class RuboCop::Cop::Layout::SpaceAfterComma < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/layout/space_after_comma.rb#21 def space_style_before_rcurly; end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/space_after_comma.rb#32 + def before_semicolon?(token); end end # Checks for space between a method name and a left parenthesis in defs. @@ -14607,7 +14980,7 @@ RuboCop::Cop::Layout::SpaceAroundKeyword::SAFE_NAVIGATION = T.let(T.unsafe(nil), # foo &. bar # foo &. bar&. buzz # RuboCop:: Cop -# RuboCop:: Cop:: Cop +# RuboCop:: Cop:: Base # :: RuboCop::Cop # # # good @@ -14619,7 +14992,7 @@ RuboCop::Cop::Layout::SpaceAroundKeyword::SAFE_NAVIGATION = T.let(T.unsafe(nil), # foo&.bar # foo&.bar&.buzz # RuboCop::Cop -# RuboCop::Cop::Cop +# RuboCop::Cop::Base # ::RuboCop::Cop # # source://rubocop//lib/rubocop/cop/layout/space_around_method_call_operator.rb#37 @@ -14700,149 +15073,166 @@ RuboCop::Cop::Layout::SpaceAroundMethodCallOperator::SPACES_REGEXP = T.let(T.uns # # # good # a ** b +# @example EnforcedStyleForRationalLiterals: no_space (default) +# # bad +# 1 / 48r +# +# # good +# 1/48r +# @example EnforcedStyleForRationalLiterals: space +# # bad +# 1/48r # -# source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#53 +# # good +# 1 / 48r +# +# source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#67 class RuboCop::Cop::Layout::SpaceAroundOperators < ::RuboCop::Cop::Base include ::RuboCop::Cop::PrecedingFollowingAlignment include ::RuboCop::Cop::RangeHelp include ::RuboCop::Cop::RationalLiteral extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#119 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#133 def on_and(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_and_asgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_assignment(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#119 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#133 def on_binary(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#111 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#125 def on_casgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#119 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#133 def on_class(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_cvasgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_gvasgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#78 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#92 def on_if(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_ivasgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_lvasgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_masgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#135 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#149 def on_match_pattern(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#127 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#141 def on_op_asgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#119 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#133 def on_or(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#103 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#117 def on_or_asgn(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#70 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#84 def on_pair(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#85 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#99 def on_resbody(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#66 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#80 def on_sclass(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#93 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#107 def on_send(node); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#127 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#141 def on_special_asgn(node); end private - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#236 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#259 def align_hash_cop_config; end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#179 - def autocorrect(corrector, range); end + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#198 + def autocorrect(corrector, range, right_operand); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#163 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#179 def check_operator(type, operator, right_operand); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#189 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#212 def enclose_operator_with_space(corrector, range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#216 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#239 def excess_leading_space?(type, operator, with_space); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#231 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#254 def excess_trailing_space?(right_operand, with_space); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#248 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#277 def force_equal_sign_alignment?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#240 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#263 def hash_table_style?; end # @yield [msg] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#174 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#193 def offense(type, operator, with_space, right_operand); end - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#202 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#225 def offense_message(type, operator, with_space, right_operand); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#159 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#175 def operator_with_regular_syntax?(send_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#155 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#169 def regular_operator?(send_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#252 - def should_not_have_surrounding_space?(operator); end + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#281 + def should_not_have_surrounding_space?(operator, right_operand); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#244 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#267 def space_around_exponent_operator?; end + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#271 + def space_around_slash_operator?(right_operand); end + class << self - # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#62 + # source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#76 def autocorrect_incompatible_with; end end end -# source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#60 +# source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#74 RuboCop::Cop::Layout::SpaceAroundOperators::EXCESSIVE_SPACE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#59 +# source://rubocop//lib/rubocop/cop/layout/space_around_operators.rb#73 RuboCop::Cop::Layout::SpaceAroundOperators::IRREGULAR_METHODS = T.let(T.unsafe(nil), Array) # Checks that block braces have or don't have a space before the opening @@ -14895,35 +15285,38 @@ class RuboCop::Cop::Layout::SpaceBeforeBlockBraces < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#124 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#133 def autocorrect(corrector, range); end - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#144 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#153 def block_delimiters_style; end # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#83 def check_empty(left_brace, space_plus_brace, used_style); end - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#100 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#109 def check_non_empty(left_brace, space_plus_brace, used_style); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#140 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#149 def conflict_with_block_delimiters?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#148 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#157 def empty_braces?(loc); end - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#115 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#101 + def handle_different_styles_for_empty_braces(used_style); end + + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#124 def space_detected(left_brace, space_plus_brace); end - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#108 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#117 def space_missing(left_brace); end - # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#131 + # source://rubocop//lib/rubocop/cop/layout/space_before_block_braces.rb#140 def style_for_empty_braces; end class << self @@ -15915,23 +16308,20 @@ class RuboCop::Cop::Layout::SpaceInsideStringInterpolation < ::RuboCop::Cop::Bas include ::RuboCop::Cop::ConfigurableEnforcedStyle extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#31 + # source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#30 def on_interpolation(begin_node); end private - # source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#47 + # source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#46 def autocorrect(corrector, begin_node); end - # source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#57 + # source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#56 def delimiters(begin_node); end end # source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#28 -RuboCop::Cop::Layout::SpaceInsideStringInterpolation::NO_SPACE_MSG = T.let(T.unsafe(nil), String) - -# source://rubocop//lib/rubocop/cop/layout/space_inside_string_interpolation.rb#29 -RuboCop::Cop::Layout::SpaceInsideStringInterpolation::SPACE_MSG = T.let(T.unsafe(nil), String) +RuboCop::Cop::Layout::SpaceInsideStringInterpolation::MSG = T.let(T.unsafe(nil), String) # Looks for trailing blank lines and a final newline in the # source code. @@ -15979,13 +16369,18 @@ class RuboCop::Cop::Layout::TrailingEmptyLines < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/layout/trailing_empty_lines.rb#79 + # source://rubocop//lib/rubocop/cop/layout/trailing_empty_lines.rb#90 + def end_with_percent_blank_string?(processed_source); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/layout/trailing_empty_lines.rb#80 def ends_in_end?(processed_source); end - # source://rubocop//lib/rubocop/cop/layout/trailing_empty_lines.rb#89 + # source://rubocop//lib/rubocop/cop/layout/trailing_empty_lines.rb#94 def message(wanted_blank_lines, blank_lines); end - # source://rubocop//lib/rubocop/cop/layout/trailing_empty_lines.rb#66 + # source://rubocop//lib/rubocop/cop/layout/trailing_empty_lines.rb#67 def offense_detected(buffer, wanted_blank_lines, blank_lines, whitespace_at_end); end end @@ -16279,7 +16674,6 @@ RuboCop::Cop::Lint::AmbiguousAssignment::SIMPLE_ASSIGNMENT_TYPES = T.let(T.unsaf # # # bad # some_method a { |val| puts val } -# @example # # # good # # With parentheses, there's no ambiguity. @@ -16312,38 +16706,38 @@ RuboCop::Cop::Lint::AmbiguousAssignment::SIMPLE_ASSIGNMENT_TYPES = T.let(T.unsaf # expect { do_something }.to change { object.attribute } # expect { do_something }.to not_change { object.attribute } # -# source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#54 +# source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#52 class RuboCop::Cop::Lint::AmbiguousBlockAssociation < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedMethods include ::RuboCop::Cop::AllowedPattern extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#64 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#62 def on_csend(node); end - # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#64 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#62 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#85 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#83 def allowed_method_pattern?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#81 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#79 def ambiguous_block_association?(send_node); end - # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#91 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#89 def message(send_node); end - # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#97 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#95 def wrap_in_parentheses(corrector, node); end end -# source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#60 +# source://rubocop//lib/rubocop/cop/lint/ambiguous_block_association.rb#58 RuboCop::Cop::Lint::AmbiguousBlockAssociation::MSG = T.let(T.unsafe(nil), String) # Checks for ambiguous operators in the first argument of a @@ -16356,51 +16750,50 @@ RuboCop::Cop::Lint::AmbiguousBlockAssociation::MSG = T.let(T.unsafe(nil), String # # The `*` is interpreted as a splat operator but it could possibly be # # a `*` method invocation (i.e. `do_something.*(some_array)`). # do_something *some_array -# @example # # # good # # # With parentheses, there's no ambiguity. # do_something(*some_array) # -# source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#23 +# source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#21 class RuboCop::Cop::Lint::AmbiguousOperator < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#45 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#43 def on_new_investigation; end private - # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#64 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#62 def find_offense_node_by(diagnostic); end - # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#82 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#80 def message(diagnostic); end - # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#92 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#90 def offense_node(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#88 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#86 def offense_position?(node, diagnostic); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#101 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#99 def unary_operator?(node, diagnostic); end class << self - # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#41 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#39 def autocorrect_incompatible_with; end end end -# source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#26 +# source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#24 RuboCop::Cop::Lint::AmbiguousOperator::AMBIGUITIES = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#36 +# source://rubocop//lib/rubocop/cop/lint/ambiguous_operator.rb#34 RuboCop::Cop::Lint::AmbiguousOperator::MSG_FORMAT = T.let(T.unsafe(nil), String) # Looks for expressions containing multiple binary operators @@ -16566,40 +16959,39 @@ RuboCop::Cop::Lint::AmbiguousRange::MSG = T.let(T.unsafe(nil), String) # # but it could possibly be `/` method invocations. # # (i.e. `do_something./(pattern)./(i)`) # do_something /pattern/i -# @example # # # good # # # With parentheses, there's no ambiguity. # do_something(/pattern/i) # -# source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#24 +# source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#22 class RuboCop::Cop::Lint::AmbiguousRegexpLiteral < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#31 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#29 def on_new_investigation; end private - # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#56 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#54 def find_offense_node(node, regexp_receiver); end - # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#49 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#47 def find_offense_node_by(diagnostic); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#67 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#65 def first_argument_is_regexp?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#71 + # source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#69 def method_chain_to_regexp_receiver?(node, regexp_receiver); end end -# source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#27 +# source://rubocop//lib/rubocop/cop/lint/ambiguous_regexp_literal.rb#25 RuboCop::Cop::Lint::AmbiguousRegexpLiteral::MSG = T.let(T.unsafe(nil), String) # Checks for assignments in the conditions of @@ -16612,22 +17004,22 @@ RuboCop::Cop::Lint::AmbiguousRegexpLiteral::MSG = T.let(T.unsafe(nil), String) # # @example # # bad -# if some_var = true +# if some_var = value # do_something # end # # # good -# if some_var == true +# if some_var == value # do_something # end # @example AllowSafeAssignment: true (default) # # good -# if (some_var = true) +# if (some_var = value) # do_something # end # @example AllowSafeAssignment: false # # bad -# if (some_var = true) +# if (some_var = value) # do_something # end # @@ -16709,10 +17101,10 @@ RuboCop::Cop::Lint::BigDecimalNew::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array # Checks for places where binary operator has identical operands. # # It covers arithmetic operators: `-`, `/`, `%`; -# comparison operators: `==`, `===`, `=~`, `>`, `>=`, `<`, `<=`; +# comparison operators: `==`, `===`, `=~`, `>`, `>=`, `<`, ``<=``; # bitwise operators: `|`, `^`, `&`; # boolean operators: `&&`, `||` -# and "spaceship" operator - `<=>`. +# and "spaceship" operator - ``<=>``. # # Simple arithmetic operations are allowed by this cop: `+`, `*`, `**`, `<<` and `>>`. # Although these can be rewritten in a different way, it should not be necessary to @@ -16765,7 +17157,6 @@ RuboCop::Cop::Lint::BinaryOperatorWithIdenticalOperands::MSG = T.let(T.unsafe(ni # # # good # true -# @example # # # bad # :false @@ -16773,23 +17164,23 @@ RuboCop::Cop::Lint::BinaryOperatorWithIdenticalOperands::MSG = T.let(T.unsafe(ni # # good # false # -# source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#29 +# source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#27 class RuboCop::Cop::Lint::BooleanSymbol < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#35 + # source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#33 def boolean_symbol?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#37 + # source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#35 def on_sym(node); end private - # source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#50 + # source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#48 def autocorrect(corrector, node); end end -# source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#32 +# source://rubocop//lib/rubocop/cop/lint/boolean_symbol.rb#30 RuboCop::Cop::Lint::BooleanSymbol::MSG = T.let(T.unsafe(nil), String) # Checks for circular argument references in optional keyword @@ -16800,54 +17191,45 @@ RuboCop::Cop::Lint::BooleanSymbol::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # def bake(pie: pie) # pie.heat_up # end -# @example # # # good -# # def bake(pie:) # pie.refrigerate # end -# @example # # # good -# # def bake(pie: self.pie) # pie.feed_to(user) # end -# @example # # # bad -# # def cook(dry_ingredients = dry_ingredients) # dry_ingredients.reduce(&:+) # end -# @example # # # good -# # def cook(dry_ingredients = self.dry_ingredients) # dry_ingredients.combine # end # -# source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#50 +# source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#37 class RuboCop::Cop::Lint::CircularArgumentReference < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#53 + # source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#40 def on_kwoptarg(node); end - # source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#57 + # source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#44 def on_optarg(node); end private - # source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#63 + # source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#50 def check_for_circular_argument_references(arg_name, arg_value); end end -# source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#51 +# source://rubocop//lib/rubocop/cop/lint/circular_argument_reference.rb#38 RuboCop::Cop::Lint::CircularArgumentReference::MSG = T.let(T.unsafe(nil), String) # Do not define constants within a block, since the block's scope does not @@ -16935,7 +17317,7 @@ end # source://rubocop//lib/rubocop/cop/lint/constant_definition_in_block.rb#67 RuboCop::Cop::Lint::ConstantDefinitionInBlock::MSG = T.let(T.unsafe(nil), String) -# Checks for overwriting an exception with an exception result by use `rescue =>`. +# Checks for overwriting an exception with an exception result by use ``rescue =>``. # # You intended to write as `rescue StandardError`. # However, you have written `rescue => StandardError`. @@ -17080,6 +17462,11 @@ RuboCop::Cop::Lint::ConstantResolution::MSG = T.let(T.unsafe(nil), String) # MyDebugger.debug_this # ---- # +# Some gems also ship files that will start a debugging session when required, +# for example `require 'debug/start'` from `ruby/debug`. These requires can +# be configured through `DebuggerRequires`. It has the same structure as +# `DebuggerMethods`, which you can read about above. +# # @example # # # bad (ok during development) @@ -17089,7 +17476,6 @@ RuboCop::Cop::Lint::ConstantResolution::MSG = T.let(T.unsafe(nil), String) # binding.pry # do_something # end -# @example # # # bad (ok during development) # @@ -17098,7 +17484,6 @@ RuboCop::Cop::Lint::ConstantResolution::MSG = T.let(T.unsafe(nil), String) # byebug # do_something # end -# @example # # # good # @@ -17112,30 +17497,56 @@ RuboCop::Cop::Lint::ConstantResolution::MSG = T.let(T.unsafe(nil), String) # def some_method # my_debugger # end +# @example DebuggerRequires: [my_debugger/start] +# +# # bad (ok during development) +# +# require 'my_debugger/start' # -# source://rubocop//lib/rubocop/cop/lint/debugger.rb#67 +# source://rubocop//lib/rubocop/cop/lint/debugger.rb#74 class RuboCop::Cop::Lint::Debugger < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/debugger.rb#70 + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#78 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/lint/debugger.rb#98 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#138 + def assumed_argument?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#117 + def assumed_usage_context?(node); end + + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#127 def chained_method_name(send_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/debugger.rb#92 + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#104 def debugger_method?(send_node); end - # source://rubocop//lib/rubocop/cop/lint/debugger.rb#85 + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#90 def debugger_methods; end - # source://rubocop//lib/rubocop/cop/lint/debugger.rb#81 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#110 + def debugger_require?(send_node); end + + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#97 + def debugger_requires; end + + # source://rubocop//lib/rubocop/cop/lint/debugger.rb#86 def message(node); end end -# source://rubocop//lib/rubocop/cop/lint/debugger.rb#68 +# source://rubocop//lib/rubocop/cop/lint/debugger.rb#76 +RuboCop::Cop::Lint::Debugger::BLOCK_TYPES = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/lint/debugger.rb#75 RuboCop::Cop::Lint::Debugger::MSG = T.let(T.unsafe(nil), String) # Checks for uses of the deprecated class method usages. @@ -17272,25 +17683,17 @@ RuboCop::Cop::Lint::DeprecatedConstants::SUGGEST_GOOD_MSG = T.let(T.unsafe(nil), # # @example # -# # Example for OpenSSL::Cipher instantiation. -# # # bad # OpenSSL::Cipher::AES.new(128, :GCM) # # # good # OpenSSL::Cipher.new('aes-128-gcm') -# @example -# -# # Example for OpenSSL::Digest instantiation. # # # bad # OpenSSL::Digest::SHA256.new # # # good # OpenSSL::Digest.new('SHA256') -# @example -# -# # Example for ::Digest inherited class methods. # # # bad # OpenSSL::Digest::SHA256.digest('foo') @@ -17298,51 +17701,51 @@ RuboCop::Cop::Lint::DeprecatedConstants::SUGGEST_GOOD_MSG = T.let(T.unsafe(nil), # # good # OpenSSL::Digest.digest('SHA256', 'foo') # -# source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#40 +# source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#30 class RuboCop::Cop::Lint::DeprecatedOpenSSLConstant < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#49 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#39 def algorithm_const(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#59 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#49 def digest_const?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#63 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#53 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#110 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#100 def algorithm_name(node); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#75 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#65 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#139 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#129 def build_cipher_arguments(node, algorithm_name, no_arguments); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#102 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#92 def correction_range(node); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#87 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#77 def message(node); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#106 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#96 def openssl_class(node); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#128 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#118 def replacement_args(node); end - # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#120 + # source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#110 def sanitize_arguments(arguments); end end -# source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#44 +# source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#34 RuboCop::Cop::Lint::DeprecatedOpenSSLConstant::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#46 +# source://rubocop//lib/rubocop/cop/lint/deprecated_open_ssl_constant.rb#36 RuboCop::Cop::Lint::DeprecatedOpenSSLConstant::NO_ARG_ALGORITHM = T.let(T.unsafe(nil), Array) # Checks constructors for disjunctive assignments (`||=`) that should @@ -17539,17 +17942,14 @@ RuboCop::Cop::Lint::DuplicateBranch::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # case x # when 'first' # do_something # when 'first' # do_something_else # end -# @example # # # good -# # case x # when 'first' # do_something @@ -17557,13 +17957,13 @@ RuboCop::Cop::Lint::DuplicateBranch::MSG = T.let(T.unsafe(nil), String) # do_something_else # end # -# source://rubocop//lib/rubocop/cop/lint/duplicate_case_condition.rb#30 +# source://rubocop//lib/rubocop/cop/lint/duplicate_case_condition.rb#26 class RuboCop::Cop::Lint::DuplicateCaseCondition < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/duplicate_case_condition.rb#33 + # source://rubocop//lib/rubocop/cop/lint/duplicate_case_condition.rb#29 def on_case(case_node); end end -# source://rubocop//lib/rubocop/cop/lint/duplicate_case_condition.rb#31 +# source://rubocop//lib/rubocop/cop/lint/duplicate_case_condition.rb#27 RuboCop::Cop::Lint::DuplicateCaseCondition::MSG = T.let(T.unsafe(nil), String) # Checks that there are no repeated conditions used in if 'elsif'. @@ -17593,29 +17993,27 @@ end RuboCop::Cop::Lint::DuplicateElsifCondition::MSG = T.let(T.unsafe(nil), String) # Checks for duplicated keys in hash literals. +# This cop considers both primitive types and constants for the hash keys. # # This cop mirrors a warning in Ruby 2.2. # # @example # # # bad -# # hash = { food: 'apple', food: 'orange' } -# @example # # # good -# # hash = { food: 'apple', other_food: 'orange' } # -# source://rubocop//lib/rubocop/cop/lint/duplicate_hash_key.rb#21 +# source://rubocop//lib/rubocop/cop/lint/duplicate_hash_key.rb#18 class RuboCop::Cop::Lint::DuplicateHashKey < ::RuboCop::Cop::Base include ::RuboCop::Cop::Duplication - # source://rubocop//lib/rubocop/cop/lint/duplicate_hash_key.rb#26 + # source://rubocop//lib/rubocop/cop/lint/duplicate_hash_key.rb#23 def on_hash(node); end end -# source://rubocop//lib/rubocop/cop/lint/duplicate_hash_key.rb#24 +# source://rubocop//lib/rubocop/cop/lint/duplicate_hash_key.rb#21 RuboCop::Cop::Lint::DuplicateHashKey::MSG = T.let(T.unsafe(nil), String) # Checks for duplicated magic comments. @@ -17767,7 +18165,6 @@ RuboCop::Cop::Lint::DuplicateMatchPattern::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # def foo # 1 # end @@ -17775,19 +18172,15 @@ RuboCop::Cop::Lint::DuplicateMatchPattern::MSG = T.let(T.unsafe(nil), String) # def foo # 2 # end -# @example # # # bad -# # def foo # 1 # end # # alias foo bar -# @example # # # good -# # def foo # 1 # end @@ -17795,98 +18188,96 @@ RuboCop::Cop::Lint::DuplicateMatchPattern::MSG = T.let(T.unsafe(nil), String) # def bar # 2 # end -# @example # # # good -# # def foo # 1 # end # # alias bar foo # -# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#52 +# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#42 class RuboCop::Cop::Lint::DuplicateMethods < ::RuboCop::Cop::Base # @return [DuplicateMethods] a new instance of DuplicateMethods # - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#57 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#47 def initialize(config = T.unsafe(nil), options = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#98 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#88 def alias_method?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#85 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#75 def method_alias?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#89 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#79 def on_alias(node); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#63 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#53 def on_def(node); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#72 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#62 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#104 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#94 def on_send(node); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#103 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#93 def sym_name(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#117 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#107 def check_const_receiver(node, name, const_name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#124 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#114 def check_self_receiver(node, name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#208 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#198 def found_attr(node, args, readable: T.unsafe(nil), writable: T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#136 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#126 def found_instance_method(node, name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#159 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#149 def found_method(node, method_name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#149 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#139 def found_sclass_method(node, name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#186 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#176 def location(node); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#218 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#208 def lookup_constant(node, const_name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#131 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#121 def message_for_dup(node, method_name, key); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#178 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#168 def method_key(node, method_name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#194 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#184 def on_attr(node, attr_name, args); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#250 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#240 def possible_dsl?(node); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#236 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#226 def qualified_name(enclosing, namespace, mod_name); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#260 + # source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#250 def source_location(node); end end -# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#55 +# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#45 RuboCop::Cop::Lint::DuplicateMethods::DEF_TYPES = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#53 +# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#43 RuboCop::Cop::Lint::DuplicateMethods::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#54 +# source://rubocop//lib/rubocop/cop/lint/duplicate_methods.rb#44 RuboCop::Cop::Lint::DuplicateMethods::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for duplicate elements in Regexp character classes. @@ -17910,26 +18301,40 @@ class RuboCop::Cop::Lint::DuplicateRegexpCharacterClassElement < ::RuboCop::Cop: include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#36 + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#37 def each_repeated_character_class_element_loc(node); end - # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#27 + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#29 def on_regexp(node); end private - # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#83 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#102 + def escaped_octal?(string); end + + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#54 + def group_expressions(node, expressions); end + + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#110 def interpolation_locs(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#65 - def skip_expression?(expr); end + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#106 + def octal?(char); end + + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#71 + def pop_octal_digits(current_child, expressions); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#78 - def start_with_escaped_zero_number?(current_child, next_child); end + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#89 + def skip_expression?(expr); end + + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#80 + def source_range(children); end # Since we blank interpolations with a space for every char of the interpolation, we would # mark every space (except the first) as duplicate if we do not skip regexp_parser nodes @@ -17937,13 +18342,16 @@ class RuboCop::Cop::Lint::DuplicateRegexpCharacterClassElement < ::RuboCop::Cop: # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#72 + # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#96 def within_interpolation?(node, child); end end # source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#25 RuboCop::Cop::Lint::DuplicateRegexpCharacterClassElement::MSG_REPEATED_ELEMENT = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb#27 +RuboCop::Cop::Lint::DuplicateRegexpCharacterClassElement::OCTAL_DIGITS_AFTER_ESCAPE = T.let(T.unsafe(nil), Integer) + # Checks for duplicate ``require``s and ``require_relative``s. # # @example @@ -18026,31 +18434,28 @@ RuboCop::Cop::Lint::DuplicateRescueException::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # sum = numbers.each_with_object(0) { |e, a| a += e } -# @example # # # good -# # num = 0 # sum = numbers.each_with_object(num) { |e, a| a += e } # -# source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#24 +# source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#20 class RuboCop::Cop::Lint::EachWithObjectArgument < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#29 + # source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#25 def each_with_object?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#33 + # source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#29 def on_csend(node); end - # source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#33 + # source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#29 def on_send(node); end end -# source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#25 +# source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#21 RuboCop::Cop::Lint::EachWithObjectArgument::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#26 +# source://rubocop//lib/rubocop/cop/lint/each_with_object_argument.rb#22 RuboCop::Cop::Lint::EachWithObjectArgument::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for odd `else` block layout - like @@ -18070,7 +18475,6 @@ RuboCop::Cop::Lint::EachWithObjectArgument::RESTRICT_ON_SEND = T.let(T.unsafe(ni # else do_this # do_that # end -# @example # # # good # @@ -18090,33 +18494,33 @@ RuboCop::Cop::Lint::EachWithObjectArgument::RESTRICT_ON_SEND = T.let(T.unsafe(ni # do_that # end # -# source://rubocop//lib/rubocop/cop/lint/else_layout.rb#43 +# source://rubocop//lib/rubocop/cop/lint/else_layout.rb#41 class RuboCop::Cop::Lint::ElseLayout < ::RuboCop::Cop::Base include ::RuboCop::Cop::Alignment include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#50 + # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#48 def on_if(node); end private - # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#81 + # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#79 def autocorrect(corrector, node, first_else); end - # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#61 + # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#59 def check(node); end - # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#71 + # source://rubocop//lib/rubocop/cop/lint/else_layout.rb#69 def check_else(node); end end -# source://rubocop//lib/rubocop/cop/lint/else_layout.rb#48 +# source://rubocop//lib/rubocop/cop/lint/else_layout.rb#46 RuboCop::Cop::Lint::ElseLayout::MSG = T.let(T.unsafe(nil), String) # Checks for blocks without a body. # Such empty blocks are typically an oversight or we should provide a comment -# be clearer what we're aiming for. +# to clarify what we're aiming for. # # Empty lambdas and procs are ignored by default. # @@ -18387,52 +18791,45 @@ end # source://rubocop//lib/rubocop/cop/lint/empty_conditional_body.rb#68 RuboCop::Cop::Lint::EmptyConditionalBody::MSG = T.let(T.unsafe(nil), String) -# Checks for empty `ensure` blocks +# Checks for empty `ensure` blocks. # # @example # # # bad -# # def some_method # do_something # ensure # end -# @example # # # bad -# # begin # do_something # ensure # end -# @example # # # good -# # def some_method # do_something # ensure # do_something_else # end -# @example # # # good -# # begin # do_something # ensure # do_something_else # end # -# source://rubocop//lib/rubocop/cop/lint/empty_ensure.rb#45 +# source://rubocop//lib/rubocop/cop/lint/empty_ensure.rb#35 class RuboCop::Cop::Lint::EmptyEnsure < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/empty_ensure.rb#50 + # source://rubocop//lib/rubocop/cop/lint/empty_ensure.rb#40 def on_ensure(node); end end -# source://rubocop//lib/rubocop/cop/lint/empty_ensure.rb#48 +# source://rubocop//lib/rubocop/cop/lint/empty_ensure.rb#38 RuboCop::Cop::Lint::EmptyEnsure::MSG = T.let(T.unsafe(nil), String) # Checks for the presence of empty expressions. @@ -18567,24 +18964,21 @@ RuboCop::Cop::Lint::EmptyInPattern::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # "result is #{}" -# @example # # # good -# # "result is #{some_result}" # -# source://rubocop//lib/rubocop/cop/lint/empty_interpolation.rb#19 +# source://rubocop//lib/rubocop/cop/lint/empty_interpolation.rb#15 class RuboCop::Cop::Lint::EmptyInterpolation < ::RuboCop::Cop::Base include ::RuboCop::Cop::Interpolation extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/empty_interpolation.rb#25 + # source://rubocop//lib/rubocop/cop/lint/empty_interpolation.rb#21 def on_interpolation(begin_node); end end -# source://rubocop//lib/rubocop/cop/lint/empty_interpolation.rb#23 +# source://rubocop//lib/rubocop/cop/lint/empty_interpolation.rb#19 RuboCop::Cop::Lint::EmptyInterpolation::MSG = T.let(T.unsafe(nil), String) # Checks for the presence of `when` branches without a body. @@ -18597,7 +18991,6 @@ RuboCop::Cop::Lint::EmptyInterpolation::MSG = T.let(T.unsafe(nil), String) # do_something # when baz # end -# @example # # # good # case condition @@ -18625,15 +19018,15 @@ RuboCop::Cop::Lint::EmptyInterpolation::MSG = T.let(T.unsafe(nil), String) # # do nothing # end # -# source://rubocop//lib/rubocop/cop/lint/empty_when.rb#47 +# source://rubocop//lib/rubocop/cop/lint/empty_when.rb#45 class RuboCop::Cop::Lint::EmptyWhen < ::RuboCop::Cop::Base include ::RuboCop::Cop::CommentsHelp - # source://rubocop//lib/rubocop/cop/lint/empty_when.rb#52 + # source://rubocop//lib/rubocop/cop/lint/empty_when.rb#50 def on_case(node); end end -# source://rubocop//lib/rubocop/cop/lint/empty_when.rb#50 +# source://rubocop//lib/rubocop/cop/lint/empty_when.rb#48 RuboCop::Cop::Lint::EmptyWhen::MSG = T.let(T.unsafe(nil), String) # Checks for `return` from an `ensure` block. @@ -18646,17 +19039,14 @@ RuboCop::Cop::Lint::EmptyWhen::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # def foo # do_something # ensure # cleanup # return self # end -# @example # # # good -# # def foo # do_something # self @@ -18664,8 +19054,7 @@ RuboCop::Cop::Lint::EmptyWhen::MSG = T.let(T.unsafe(nil), String) # cleanup # end # -# # also good -# +# # good # def foo # begin # do_something @@ -18677,16 +19066,16 @@ RuboCop::Cop::Lint::EmptyWhen::MSG = T.let(T.unsafe(nil), String) # cleanup # end # -# source://rubocop//lib/rubocop/cop/lint/ensure_return.rb#47 +# source://rubocop//lib/rubocop/cop/lint/ensure_return.rb#42 class RuboCop::Cop::Lint::EnsureReturn < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/ensure_return.rb#53 + # source://rubocop//lib/rubocop/cop/lint/ensure_return.rb#48 def on_ensure(node); end end -# source://rubocop//lib/rubocop/cop/lint/ensure_return.rb#51 +# source://rubocop//lib/rubocop/cop/lint/ensure_return.rb#46 RuboCop::Cop::Lint::EnsureReturn::MSG = T.let(T.unsafe(nil), String) # Emulates the following Ruby warnings in Ruby 2.6. @@ -18750,36 +19139,45 @@ class RuboCop::Cop::Lint::ErbNewArguments < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#83 + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#81 def erb_new_with_non_keyword_arguments(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#88 + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#86 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#153 + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#160 def arguments_range(node); end - # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#108 + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#115 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#123 + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#130 def build_kwargs(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#119 + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#126 def correct_arguments?(arguments); end - # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#140 + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#104 + def message(positional_argument_index, arg_value); end + + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#147 def override_by_legacy_args(kwargs, node); end end +# source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#74 +RuboCop::Cop::Lint::ErbNewArguments::MESSAGE_EOUTVAR = T.let(T.unsafe(nil), String) + # source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#68 -RuboCop::Cop::Lint::ErbNewArguments::MESSAGES = T.let(T.unsafe(nil), Array) +RuboCop::Cop::Lint::ErbNewArguments::MESSAGE_SAFE_LEVEL = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#71 +RuboCop::Cop::Lint::ErbNewArguments::MESSAGE_TRIM_MODE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#80 +# source://rubocop//lib/rubocop/cop/lint/erb_new_arguments.rb#78 RuboCop::Cop::Lint::ErbNewArguments::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Looks for uses of flip-flop operator @@ -18821,13 +19219,9 @@ RuboCop::Cop::Lint::FlipFlop::MSG = T.let(T.unsafe(nil), String) # floating-point value representation to be exactly the same, which is very unlikely # if you perform any arithmetic operations involving precision loss. # -# @example -# # bad -# x == 0.1 -# x != 0.1 -# -# # good - using BigDecimal -# x.to_d == 0.1.to_d +# # good - comparing against zero +# x == 0.0 +# x != 0.0 # # # good # (x - 0.1).abs < Float::EPSILON @@ -18839,38 +19233,51 @@ RuboCop::Cop::Lint::FlipFlop::MSG = T.let(T.unsafe(nil), String) # # Or some other epsilon based type of comparison: # # https://www.embeddeduse.com/2019/08/26/qt-compare-two-floats/ # -# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#31 +# @example +# # bad +# x == 0.1 +# x != 0.1 +# +# # good - using BigDecimal +# x.to_d == 0.1.to_d +# +# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#35 class RuboCop::Cop::Lint::FloatComparison < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#40 + # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#44 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#79 + # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#91 def check_numeric_returning_method(node); end - # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#63 + # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#75 def check_send(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#47 + # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#53 def float?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#68 + def literal_zero?(node); end end -# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#34 +# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#38 RuboCop::Cop::Lint::FloatComparison::EQUALITY_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#36 +# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#40 RuboCop::Cop::Lint::FloatComparison::FLOAT_INSTANCE_METHODS = T.let(T.unsafe(nil), Set) -# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#35 +# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#39 RuboCop::Cop::Lint::FloatComparison::FLOAT_RETURNING_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#32 +# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#36 RuboCop::Cop::Lint::FloatComparison::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#38 +# source://rubocop//lib/rubocop/cop/lint/float_comparison.rb#42 RuboCop::Cop::Lint::FloatComparison::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Identifies Float literals which are, like, really really really @@ -18880,21 +19287,18 @@ RuboCop::Cop::Lint::FloatComparison::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arr # @example # # # bad -# # float = 3.0e400 -# @example # # # good -# # float = 42.9 # -# source://rubocop//lib/rubocop/cop/lint/float_out_of_range.rb#21 +# source://rubocop//lib/rubocop/cop/lint/float_out_of_range.rb#17 class RuboCop::Cop::Lint::FloatOutOfRange < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/float_out_of_range.rb#24 + # source://rubocop//lib/rubocop/cop/lint/float_out_of_range.rb#20 def on_float(node); end end -# source://rubocop//lib/rubocop/cop/lint/float_out_of_range.rb#22 +# source://rubocop//lib/rubocop/cop/lint/float_out_of_range.rb#18 RuboCop::Cop::Lint::FloatOutOfRange::MSG = T.let(T.unsafe(nil), String) # This lint sees if there is a mismatch between the number of @@ -18908,138 +19312,131 @@ RuboCop::Cop::Lint::FloatOutOfRange::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # format('A value: %s and another: %i', a_value) -# @example # # # good -# # format('A value: %s and another: %i', a_value, another) -# @example # # # bad -# # format('Unnumbered format: %s and numbered: %2$s', a_value, another) -# @example # # # good -# # format('Numbered format: %1$s and numbered %2$s', a_value, another) # -# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#37 +# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#27 class RuboCop::Cop::Lint::FormatParameterMismatch < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#100 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#90 def called_on_string?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#49 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#39 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#137 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#127 def count_format_matches(node); end - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#119 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#109 def count_matches(node); end - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#141 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#131 def count_percent_matches(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#129 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#119 def countable_format?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#133 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#123 def countable_percent?(node); end - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#153 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#143 def expected_fields_count(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#168 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#158 def format?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#146 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#136 def format_method?(name, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#64 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#54 def format_string?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#115 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#105 def heredoc?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#68 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#58 def invalid_format_string?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#91 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#81 def matched_arguments_count?(expected, passed); end - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#186 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#176 def message(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#105 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#95 def method_with_format_args?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#77 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#67 def offending_node?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#176 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#166 def percent?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#109 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#99 def splat_args?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#172 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#162 def sprintf?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#195 + # source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#185 def string_type?(node); end end -# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#44 +# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#34 RuboCop::Cop::Lint::FormatParameterMismatch::KERNEL = T.let(T.unsafe(nil), String) # http://rubular.com/r/CvpbxkcTzy # -# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#39 +# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#29 RuboCop::Cop::Lint::FormatParameterMismatch::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#41 +# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#31 RuboCop::Cop::Lint::FormatParameterMismatch::MSG_INVALID = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#47 +# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#37 RuboCop::Cop::Lint::FormatParameterMismatch::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#45 +# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#35 RuboCop::Cop::Lint::FormatParameterMismatch::SHOVEL = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#46 +# source://rubocop//lib/rubocop/cop/lint/format_parameter_mismatch.rb#36 RuboCop::Cop::Lint::FormatParameterMismatch::STRING_TYPES = T.let(T.unsafe(nil), Array) # Prefer using `Hash#compare_by_identity` rather than using `object_id` @@ -19064,6 +19461,9 @@ class RuboCop::Cop::Lint::HashCompareByIdentity < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/lint/hash_compare_by_identity.rb#37 def id_as_hash_key?(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/lint/hash_compare_by_identity.rb#41 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/lint/hash_compare_by_identity.rb#41 def on_send(node); end end @@ -19216,12 +19616,9 @@ RuboCop::Cop::Lint::IdentityComparison::RESTRICT_ON_SEND = T.let(T.unsafe(nil), # @example # # # bad -# # array = ['Item 1' 'Item 2'] -# @example # # # good -# # array = ['Item 1Item 2'] # array = ['Item 1' + 'Item 2'] # array = [ @@ -19229,43 +19626,45 @@ RuboCop::Cop::Lint::IdentityComparison::RESTRICT_ON_SEND = T.let(T.unsafe(nil), # 'Item 2' # ] # -# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#25 +# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#21 class RuboCop::Cop::Lint::ImplicitStringConcatenation < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#33 + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#32 def on_dstr(node); end private - # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#83 + # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#86 def display_str(node); end - # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#50 + # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#53 def each_bad_cons(node); end - # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#65 + # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#68 def ending_delimiter(str); end - # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#91 + # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#94 def str_content(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#75 + # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#78 def string_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#79 + # source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#82 def string_literals?(node1, node2); end end -# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#28 +# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#26 RuboCop::Cop::Lint::ImplicitStringConcatenation::FOR_ARRAY = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#30 +# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#28 RuboCop::Cop::Lint::ImplicitStringConcatenation::FOR_METHOD = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#26 +# source://rubocop//lib/rubocop/cop/lint/implicit_string_concatenation.rb#24 RuboCop::Cop::Lint::ImplicitStringConcatenation::MSG = T.let(T.unsafe(nil), String) # Checks for `IO.select` that is incompatible with Fiber Scheduler since Ruby 3.0. @@ -19327,7 +19726,6 @@ RuboCop::Cop::Lint::IncompatibleIoSelectWithFiberScheduler::RESTRICT_ON_SEND = T # @example # # # bad -# # class C # private # @@ -19335,10 +19733,8 @@ RuboCop::Cop::Lint::IncompatibleIoSelectWithFiberScheduler::RESTRICT_ON_SEND = T # puts 'hi' # end # end -# @example # # # good -# # class C # def self.method # puts 'hi' @@ -19346,10 +19742,8 @@ RuboCop::Cop::Lint::IncompatibleIoSelectWithFiberScheduler::RESTRICT_ON_SEND = T # # private_class_method :method # end -# @example # # # good -# # class C # class << self # private @@ -19360,49 +19754,49 @@ RuboCop::Cop::Lint::IncompatibleIoSelectWithFiberScheduler::RESTRICT_ON_SEND = T # end # end # -# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#48 +# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#41 class RuboCop::Cop::Lint::IneffectiveAccessModifier < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#59 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#52 def on_class(node); end - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#59 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#52 def on_module(node); end - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#55 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#48 def private_class_methods(param0); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#109 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#102 def access_modifier?(node); end - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#66 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#59 def check_node(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#113 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#106 def correct_visibility?(node, modifier, ignored_methods); end - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#78 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#71 def format_message(modifier); end - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#91 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#84 def ineffective_modifier(node, ignored_methods = T.unsafe(nil), modifier = T.unsafe(nil), &block); end - # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#74 + # source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#67 def private_class_method_names(node); end end -# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#51 +# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#44 RuboCop::Cop::Lint::IneffectiveAccessModifier::ALTERNATIVE_PRIVATE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#52 +# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#45 RuboCop::Cop::Lint::IneffectiveAccessModifier::ALTERNATIVE_PROTECTED = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#49 +# source://rubocop//lib/rubocop/cop/lint/ineffective_access_modifier.rb#42 RuboCop::Cop::Lint::IneffectiveAccessModifier::MSG = T.let(T.unsafe(nil), String) # Looks for error classes inheriting from `Exception`. @@ -19481,35 +19875,69 @@ RuboCop::Cop::Lint::InheritException::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Ar # @example # # # bad -# # foo = 'something with #{interpolation} inside' -# @example # # # good -# # foo = "something with #{interpolation} inside" # -# source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#25 +# source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#21 class RuboCop::Cop::Lint::InterpolationCheck < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#31 + # source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#27 def on_str(node); end private - # source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#42 + # source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#38 def autocorrect(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#53 + # source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#49 def heredoc?(node); end end -# source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#28 +# source://rubocop//lib/rubocop/cop/lint/interpolation_check.rb#24 RuboCop::Cop::Lint::InterpolationCheck::MSG = T.let(T.unsafe(nil), String) +# Emulates the following Ruby warning in Ruby 3.3. +# +# [source,ruby] +# ---- +# $ ruby -e '0.times { it }' +# -e:1: warning: `it` calls without arguments will refer to the first block param in Ruby 3.4; +# use it() or self.it +# ---- +# +# `it` calls without arguments will refer to the first block param in Ruby 3.4. +# So use `it()` or `self.it` to ensure compatibility. +# +# @example +# +# # bad +# do_something { it } +# +# # good +# do_something { it() } +# do_something { self.it } +# +# source://rubocop//lib/rubocop/cop/lint/it_without_arguments_in_block.rb#27 +class RuboCop::Cop::Lint::ItWithoutArgumentsInBlock < ::RuboCop::Cop::Base + include ::RuboCop::AST::NodePattern::Macros + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/it_without_arguments_in_block.rb#48 + def deprecated_it_method?(node); end + + # source://rubocop//lib/rubocop/cop/lint/it_without_arguments_in_block.rb#33 + def on_block(node); end +end + +# source://rubocop//lib/rubocop/cop/lint/it_without_arguments_in_block.rb#30 +RuboCop::Cop::Lint::ItWithoutArgumentsInBlock::MSG = T.let(T.unsafe(nil), String) + # Checks uses of lambda without a literal block. # It emulates the following warning in Ruby 3.0: # @@ -19644,89 +20072,150 @@ end # source://rubocop//lib/rubocop/cop/lint/literal_as_condition.rb#38 RuboCop::Cop::Lint::LiteralAsCondition::MSG = T.let(T.unsafe(nil), String) -# Checks for interpolated literals. +# Checks for literal assignments in the conditions of `if`, `while`, and `until`. +# It emulates the following Ruby warning: +# +# [source,console] +# ---- +# $ ruby -we 'if x = true; end' +# -e:1: warning: found `= literal' in conditional, should be == +# ---- +# +# As a lint cop, it cannot be determined if `==` is appropriate as intended, +# therefore this cop does not provide autocorrection. # # @example # # # bad +# if x = 42 +# do_something +# end # -# "result is #{10}" -# @example +# # good +# if x == 42 +# do_something +# end # # # good +# if x = y +# do_something +# end # +# source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#35 +class RuboCop::Cop::Lint::LiteralAssignmentInCondition < ::RuboCop::Cop::Base + # source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#39 + def on_if(node); end + + # source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#39 + def on_until(node); end + + # source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#39 + def on_while(node); end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#62 + def all_literals?(node); end + + # source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#79 + def offense_range(asgn_node, rhs); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#75 + def parallel_assignment_with_splat_operator?(node); end + + # @yield [node] + # + # source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#56 + def traverse_node(node, &block); end +end + +# source://rubocop//lib/rubocop/cop/lint/literal_assignment_in_condition.rb#36 +RuboCop::Cop::Lint::LiteralAssignmentInCondition::MSG = T.let(T.unsafe(nil), String) + +# Checks for interpolated literals. +# +# @example +# +# # bad +# "result is #{10}" +# +# # good # "result is 10" # -# source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#19 +# source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#15 class RuboCop::Cop::Lint::LiteralInInterpolation < ::RuboCop::Cop::Base include ::RuboCop::Cop::Interpolation include ::RuboCop::Cop::RangeHelp include ::RuboCop::Cop::PercentLiteral extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#28 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#24 def on_interpolation(begin_node); end private - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#62 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#58 def autocorrected_value(node); end - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#108 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#104 def autocorrected_value_for_array(node); end - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#114 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#110 def autocorrected_value_for_hash(node); end - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#84 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#80 def autocorrected_value_for_string(node); end - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#92 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#88 def autocorrected_value_for_symbol(node); end - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#125 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#121 def autocorrected_value_in_hash(node); end - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#99 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#95 def autocorrected_value_in_hash_for_symbol(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#155 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#151 def ends_heredoc_line?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#163 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#159 def in_array_percent_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#48 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#44 def offending?(node); end # Does node print its own source when converted to a string? # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#146 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#142 def prints_as_self?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#151 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#147 def space_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#56 + # source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#52 def special_keyword?(node); end end -# source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#26 +# source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#22 RuboCop::Cop::Lint::LiteralInInterpolation::COMPOSITE = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#25 +# source://rubocop//lib/rubocop/cop/lint/literal_in_interpolation.rb#21 RuboCop::Cop::Lint::LiteralInInterpolation::MSG = T.let(T.unsafe(nil), String) # Checks for uses of `begin...end while/until something`. @@ -19739,15 +20228,6 @@ RuboCop::Cop::Lint::LiteralInInterpolation::MSG = T.let(T.unsafe(nil), String) # begin # do_something # end while some_condition -# @example -# -# # bad -# -# # using until -# begin -# do_something -# end until some_condition -# @example # # # good # @@ -19756,7 +20236,13 @@ RuboCop::Cop::Lint::LiteralInInterpolation::MSG = T.let(T.unsafe(nil), String) # do_something # break unless some_condition # end -# @example +# +# # bad +# +# # using until +# begin +# do_something +# end until some_condition # # # good # @@ -19766,29 +20252,29 @@ RuboCop::Cop::Lint::LiteralInInterpolation::MSG = T.let(T.unsafe(nil), String) # break if some_condition # end # -# source://rubocop//lib/rubocop/cop/lint/loop.rb#50 +# source://rubocop//lib/rubocop/cop/lint/loop.rb#44 class RuboCop::Cop::Lint::Loop < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/loop.rb#59 + # source://rubocop//lib/rubocop/cop/lint/loop.rb#53 def on_until_post(node); end - # source://rubocop//lib/rubocop/cop/lint/loop.rb#55 + # source://rubocop//lib/rubocop/cop/lint/loop.rb#49 def on_while_post(node); end private - # source://rubocop//lib/rubocop/cop/lint/loop.rb#79 + # source://rubocop//lib/rubocop/cop/lint/loop.rb#73 def build_break_line(node); end - # source://rubocop//lib/rubocop/cop/lint/loop.rb#75 + # source://rubocop//lib/rubocop/cop/lint/loop.rb#69 def keyword_and_condition_range(node); end - # source://rubocop//lib/rubocop/cop/lint/loop.rb#65 + # source://rubocop//lib/rubocop/cop/lint/loop.rb#59 def register_offense(node); end end -# source://rubocop//lib/rubocop/cop/lint/loop.rb#53 +# source://rubocop//lib/rubocop/cop/lint/loop.rb#47 RuboCop::Cop::Lint::Loop::MSG = T.let(T.unsafe(nil), String) # cop disables on wide ranges of code, that latter contributors to @@ -19872,6 +20358,13 @@ RuboCop::Cop::Lint::MissingCopEnableDirective::MSG_BOUND = T.let(T.unsafe(nil), # Autocorrection is not supported because the position of `super` cannot be # determined automatically. # +# `Object` and `BasicObject` are allowed by this cop because of their +# stateless nature. However, sometimes you might want to allow other parent +# classes from this cop, for example in the case of an abstract class that is +# not meant to be called with `super`. In those cases, you can use the +# `AllowedParentClasses` option to specify which classes should be allowed +# *in addition to* `Object` and `BasicObject`. +# # @example # # bad # class Employee < Person @@ -19918,63 +20411,148 @@ RuboCop::Cop::Lint::MissingCopEnableDirective::MSG_BOUND = T.let(T.unsafe(nil), # end # end # -# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#63 +# # good +# class ClassWithNoParent +# def initialize +# do_something +# end +# end +# @example AllowedParentClasses: [MyAbstractClass] +# # good +# class MyConcreteClass < MyAbstractClass +# def initialize +# do_something +# end +# end +# +# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#85 class RuboCop::Cop::Lint::MissingSuper < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#77 + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#99 def class_new_block(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#83 + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#105 def on_def(node); end - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#93 + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#115 def on_defs(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#105 + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#149 + def allowed_class?(node); end + + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#153 + def allowed_classes; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#127 def callback_method_def?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#111 + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#133 def contains_super?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#115 + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#137 def inside_class_with_stateful_parent?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#101 + # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#123 def offender?(node); end - - # @return [Boolean] - # - # source://rubocop//lib/rubocop/cop/lint/missing_super.rb#127 - def stateless_class?(node); end end -# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#74 +# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#96 RuboCop::Cop::Lint::MissingSuper::CALLBACKS = T.let(T.unsafe(nil), Set) -# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#65 +# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#87 RuboCop::Cop::Lint::MissingSuper::CALLBACK_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#69 +# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#91 RuboCop::Cop::Lint::MissingSuper::CLASS_LIFECYCLE_CALLBACKS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#64 +# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#86 RuboCop::Cop::Lint::MissingSuper::CONSTRUCTOR_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#70 +# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#92 RuboCop::Cop::Lint::MissingSuper::METHOD_LIFECYCLE_CALLBACKS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#67 +# source://rubocop//lib/rubocop/cop/lint/missing_super.rb#89 RuboCop::Cop::Lint::MissingSuper::STATELESS_CLASSES = T.let(T.unsafe(nil), Array) +# Checks for mixed-case character ranges since they include likely unintended characters. +# +# Offenses are registered for regexp character classes like `/[A-z]/` +# as well as range objects like `('A'..'z')`. +# +# NOTE: Range objects cannot be autocorrected. +# +# @example +# +# # bad +# r = /[A-z]/ +# +# # good +# r = /[A-Za-z]/ +# +# source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#28 +class RuboCop::Cop::Lint::MixedCaseRange < ::RuboCop::Cop::Base + include ::RuboCop::Cop::RangeHelp + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#58 + def each_unsafe_regexp_range(node); end + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#37 + def on_erange(node); end + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#37 + def on_irange(node); end + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#48 + def on_regexp(node); end + + private + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#74 + def build_source_range(range_start, range_end); end + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#78 + def range_for(char); end + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#84 + def range_pairs(expr); end + + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#104 + def regexp_range(source); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#94 + def skip_expression?(expr); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#98 + def skip_range?(range_start, range_end); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#88 + def unsafe_range?(range_start, range_end); end +end + +# source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#32 +RuboCop::Cop::Lint::MixedCaseRange::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/lint/mixed_case_range.rb#35 +RuboCop::Cop::Lint::MixedCaseRange::RANGES = T.let(T.unsafe(nil), Array) + # Do not mix named captures and numbered captures in a Regexp literal # because numbered capture is ignored if they're mixed. # Replace numbered captures with non-capturing groupings or @@ -20053,7 +20631,6 @@ RuboCop::Cop::Lint::MultipleComparison::SET_OPERATION_OPERATORS = T.let(T.unsafe # def bar # end # end -# @example # # # good # @@ -20061,7 +20638,6 @@ RuboCop::Cop::Lint::MultipleComparison::SET_OPERATION_OPERATORS = T.let(T.unsafe # bar = -> { puts 'hello' } # bar.call # end -# @example # # # good # @@ -20081,7 +20657,6 @@ RuboCop::Cop::Lint::MultipleComparison::SET_OPERATION_OPERATORS = T.let(T.unsafe # end # end # end -# @example # # # good # @@ -20124,37 +20699,37 @@ RuboCop::Cop::Lint::MultipleComparison::SET_OPERATION_OPERATORS = T.let(T.unsafe # end # end # -# source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#97 +# source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#91 class RuboCop::Cop::Lint::NestedMethodDefinition < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedMethods include ::RuboCop::Cop::AllowedPattern - # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#133 + # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#127 def eval_call?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#138 + # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#132 def exec_call?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#103 + # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#97 def on_def(node); end - # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#103 + # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#97 def on_defs(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#126 + # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#120 def allowed_method_name?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#121 + # source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#115 def scoping_method_call?(child); end end -# source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#101 +# source://rubocop//lib/rubocop/cop/lint/nested_method_definition.rb#95 RuboCop::Cop::Lint::NestedMethodDefinition::MSG = T.let(T.unsafe(nil), String) # Checks for nested percent literals. @@ -20220,44 +20795,35 @@ RuboCop::Cop::Lint::NestedPercentLiteral::REGEXES = T.let(T.unsafe(nil), Array) # @example # # # bad -# # result = (1..4).reduce(0) do |acc, i| # next if i.odd? # acc + i # end -# @example # # # good -# # result = (1..4).reduce(0) do |acc, i| # next acc if i.odd? # acc + i # end # -# source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#25 +# source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#21 class RuboCop::Cop::Lint::NextWithoutAccumulator < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#28 + # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#24 def on_block(node); end - # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#51 + # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#38 def on_block_body_of_reduce(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#38 + # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#24 def on_numblock(node); end - # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#56 - def on_numblock_body_of_reduce(param0 = T.unsafe(nil)); end - private - # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#60 + # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#45 def parent_block_node(node); end - - # source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#64 - def parent_numblock_node(node); end end -# source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#26 +# source://rubocop//lib/rubocop/cop/lint/next_without_accumulator.rb#22 RuboCop::Cop::Lint::NextWithoutAccumulator::MSG = T.let(T.unsafe(nil), String) # Checks for the presence of a `return` inside a `begin..end` block @@ -20268,16 +20834,13 @@ RuboCop::Cop::Lint::NextWithoutAccumulator::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # @some_variable ||= begin # return some_value if some_condition_is_met # # do_something # end -# @example # # # good -# # @some_variable ||= begin # if some_condition_is_met # some_value @@ -20287,7 +20850,6 @@ RuboCop::Cop::Lint::NextWithoutAccumulator::MSG = T.let(T.unsafe(nil), String) # end # # # good -# # some_variable = if some_condition_is_met # return if another_condition_is_met # @@ -20296,19 +20858,19 @@ RuboCop::Cop::Lint::NextWithoutAccumulator::MSG = T.let(T.unsafe(nil), String) # do_something # end # -# source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#43 +# source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#38 class RuboCop::Cop::Lint::NoReturnInBeginEndBlocks < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#46 + # source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#41 def on_lvasgn(node); end - # source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#46 + # source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#41 def on_op_asgn(node); end - # source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#46 + # source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#41 def on_or_asgn(node); end end -# source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#44 +# source://rubocop//lib/rubocop/cop/lint/no_return_in_begin_end_blocks.rb#39 RuboCop::Cop::Lint::NoReturnInBeginEndBlocks::MSG = T.let(T.unsafe(nil), String) # Checks for non-atomic file operation. @@ -20346,89 +20908,91 @@ RuboCop::Cop::Lint::NoReturnInBeginEndBlocks::MSG = T.let(T.unsafe(nil), String) # # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#44 class RuboCop::Cop::Lint::NonAtomicFileOperation < ::RuboCop::Cop::Base - include ::RuboCop::Cop::Alignment extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#75 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#76 def explicit_not_force?(param0); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#70 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#71 def force?(param0); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#79 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#80 def on_send(node); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#65 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#66 def receiver_and_method_name(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#60 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#61 def send_exist_node(param0); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#96 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#97 def allowable_use_with_if?(if_node); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#120 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#121 def autocorrect(corrector, node, range); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#131 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#132 def autocorrect_replace_method(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#148 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#151 def force_method?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#156 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#159 def force_method_name?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#152 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#155 def force_option?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#90 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#91 def if_node_child?(node); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#111 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#112 def message_change_force_method(node); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#115 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#116 def message_remove_file_exist_check(node); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#100 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#101 def register_offense(node, exist_node); end - # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#138 + # source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#139 def replacement_method(node); end end -# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#51 +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#50 RuboCop::Cop::Lint::NonAtomicFileOperation::MAKE_FORCE_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#52 +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#51 RuboCop::Cop::Lint::NonAtomicFileOperation::MAKE_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#50 +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#49 RuboCop::Cop::Lint::NonAtomicFileOperation::MSG_CHANGE_FORCE_METHOD = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#48 +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#47 RuboCop::Cop::Lint::NonAtomicFileOperation::MSG_REMOVE_FILE_EXIST_CHECK = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#53 +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#54 +RuboCop::Cop::Lint::NonAtomicFileOperation::RECURSIVE_REMOVE_METHODS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#52 RuboCop::Cop::Lint::NonAtomicFileOperation::REMOVE_FORCE_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#54 +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#53 RuboCop::Cop::Lint::NonAtomicFileOperation::REMOVE_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#56 +# source://rubocop//lib/rubocop/cop/lint/non_atomic_file_operation.rb#55 RuboCop::Cop::Lint::NonAtomicFileOperation::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # `Dir[...]` and `Dir.glob(...)` do not make any guarantees about @@ -20485,10 +21049,10 @@ RuboCop::Cop::Lint::NonAtomicFileOperation::RESTRICT_ON_SEND = T.let(T.unsafe(ni class RuboCop::Cop::Lint::NonDeterministicRequireOrder < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#174 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#172 def loop_variable(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#157 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#155 def method_require?(param0 = T.unsafe(nil)); end # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#65 @@ -20500,19 +21064,19 @@ class RuboCop::Cop::Lint::NonDeterministicRequireOrder < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#77 def on_numblock(node); end - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#147 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#145 def unsorted_dir_block?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#152 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#150 def unsorted_dir_each?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#168 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#166 def unsorted_dir_each_pass?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#162 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#160 def unsorted_dir_glob_pass?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#179 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#177 def var_is_required?(param0, param1); end private @@ -20532,12 +21096,12 @@ class RuboCop::Cop::Lint::NonDeterministicRequireOrder < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#138 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#136 def unsorted_dir_loop?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#142 + # source://rubocop//lib/rubocop/cop/lint/non_deterministic_require_order.rb#140 def unsorted_dir_pass?(node); end end @@ -20612,7 +21176,7 @@ RuboCop::Cop::Lint::NonLocalExitFromIterator::MSG = T.let(T.unsafe(nil), String) # # Conversion with `Integer`, `Float`, etc. will raise an `ArgumentError` # if given input that is not numeric (eg. an empty string), whereas -# `to_i`, etc. will try to convert regardless of input (`''.to_i => 0`). +# `to_i`, etc. will try to convert regardless of input (``''.to_i => 0``). # As such, this cop is disabled by default because it's not necessarily # always correct to raise if a value is not numeric. # @@ -20670,69 +21234,72 @@ class RuboCop::Cop::Lint::NumberConversion < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedPattern extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#102 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#107 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#107 def on_send(node); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#92 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#93 def to_method(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#97 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#98 def to_method_symbol(param0 = T.unsafe(nil)); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#155 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#165 def allow_receiver?(receiver); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#167 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#177 def allowed_method_name?(name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#177 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#187 def conversion_method?(method_name); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#141 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#151 def correct_method(node, receiver); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#145 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#155 def correct_sym_method(to_method); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#124 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#134 def handle_as_symbol(node); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#109 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#115 def handle_conversion_method(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#185 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#195 def ignored_class?(name); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#181 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#191 def ignored_classes; end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#150 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#160 def remove_parentheses(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#171 + # source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#181 def top_receiver(node); end end -# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#88 +# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#89 RuboCop::Cop::Lint::NumberConversion::CONVERSION_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#78 +# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#79 RuboCop::Cop::Lint::NumberConversion::CONVERSION_METHOD_CLASS_MAPPING = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#89 +# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#90 RuboCop::Cop::Lint::NumberConversion::METHODS = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#84 +# source://rubocop//lib/rubocop/cop/lint/number_conversion.rb#85 RuboCop::Cop::Lint::NumberConversion::MSG = T.let(T.unsafe(nil), String) # Checks for uses of numbered parameter assignment. @@ -20991,44 +21558,41 @@ RuboCop::Cop::Lint::ParenthesesAsGroupedExpression::MSG = T.let(T.unsafe(nil), S # @example # # # bad -# # %w('foo', "bar") -# @example # # # good -# # %w(foo bar) # -# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#33 +# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#29 class RuboCop::Cop::Lint::PercentStringArray < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp include ::RuboCop::Cop::PercentLiteral extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#44 + # source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#40 def on_array(node); end - # source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#48 + # source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#44 def on_percent_literal(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#65 + # source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#61 def contains_quotes_or_commas?(node); end end -# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#38 +# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#34 RuboCop::Cop::Lint::PercentStringArray::LEADING_QUOTE = T.let(T.unsafe(nil), Regexp) -# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#41 +# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#37 RuboCop::Cop::Lint::PercentStringArray::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#37 +# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#33 RuboCop::Cop::Lint::PercentStringArray::QUOTES_AND_COMMAS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#39 +# source://rubocop//lib/rubocop/cop/lint/percent_string_array.rb#35 RuboCop::Cop::Lint::PercentStringArray::TRAILING_QUOTE = T.let(T.unsafe(nil), Regexp) # Checks for colons and commas in %i, e.g. `%i(:foo, :bar)` @@ -21040,43 +21604,40 @@ RuboCop::Cop::Lint::PercentStringArray::TRAILING_QUOTE = T.let(T.unsafe(nil), Re # @example # # # bad -# # %i(:foo, :bar) -# @example # # # good -# # %i(foo bar) # -# source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#23 +# source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#19 class RuboCop::Cop::Lint::PercentSymbolArray < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp include ::RuboCop::Cop::PercentLiteral extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#30 + # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#26 def on_array(node); end - # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#34 + # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#30 def on_percent_literal(node); end private - # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#42 + # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#38 def autocorrect(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#52 + # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#48 def contains_colons_or_commas?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#62 + # source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#58 def non_alphanumeric_literal?(literal); end end -# source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#27 +# source://rubocop//lib/rubocop/cop/lint/percent_symbol_array.rb#23 RuboCop::Cop::Lint::PercentSymbolArray::MSG = T.let(T.unsafe(nil), String) # Checks for `raise` or `fail` statements which are @@ -21142,35 +21703,32 @@ RuboCop::Cop::Lint::RaiseException::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arra # @example # # # bad -# # rand 1 # Kernel.rand(-1) # rand 1.0 # rand(-1.0) -# @example # # # good -# # 0 # just use 0 instead # -# source://rubocop//lib/rubocop/cop/lint/rand_one.rb#23 +# source://rubocop//lib/rubocop/cop/lint/rand_one.rb#19 class RuboCop::Cop::Lint::RandOne < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/rand_one.rb#32 + # source://rubocop//lib/rubocop/cop/lint/rand_one.rb#28 def on_send(node); end - # source://rubocop//lib/rubocop/cop/lint/rand_one.rb#28 + # source://rubocop//lib/rubocop/cop/lint/rand_one.rb#24 def rand_one?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/lint/rand_one.rb#40 + # source://rubocop//lib/rubocop/cop/lint/rand_one.rb#36 def message(node); end end -# source://rubocop//lib/rubocop/cop/lint/rand_one.rb#24 +# source://rubocop//lib/rubocop/cop/lint/rand_one.rb#20 RuboCop::Cop::Lint::RandOne::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/rand_one.rb#25 +# source://rubocop//lib/rubocop/cop/lint/rand_one.rb#21 RuboCop::Cop::Lint::RandOne::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # removed without causing any offenses to be reported. It's implemented @@ -21351,13 +21909,14 @@ RuboCop::Cop::Lint::RedundantCopDisableDirective::SIMILAR_COP_NAMES_CACHE = T.le # that cop checks whether any cop was actually enabled. # # @example +# # # bad # foo = 1 # # rubocop:enable Layout/LineLength # # # good # foo = 1 -# @example +# # # bad # # rubocop:disable Style/StringLiterals # foo = "1" @@ -21371,54 +21930,54 @@ RuboCop::Cop::Lint::RedundantCopDisableDirective::SIMILAR_COP_NAMES_CACHE = T.le # # rubocop:enable all # baz # -# source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#37 +# source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#39 class RuboCop::Cop::Lint::RedundantCopEnableDirective < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp include ::RuboCop::Cop::SurroundingSpace extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#44 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#46 def on_new_investigation; end private - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#120 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#122 def all_or_name(name); end - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#76 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#78 def comment_start(comment); end - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#80 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#82 def cop_name_indention(comment, name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#124 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#126 def department?(directive, name); end - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#71 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#73 def range_of_offense(comment, name); end - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#95 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#97 def range_to_remove(begin_pos, end_pos, comment); end - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#84 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#86 def range_with_comma(comment, name); end # If the list of cops is comma-separated, but without a empty space after the comma, # we should **not** remove the prepending empty space, thus begin_pos += 1 # - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#114 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#116 def range_with_comma_after(comment, start, begin_pos, end_pos); end - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#108 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#110 def range_with_comma_before(start, begin_pos, end_pos); end - # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#53 + # source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#55 def register_offense(comment, cop_names); end end -# source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#42 +# source://rubocop//lib/rubocop/cop/lint/redundant_cop_enable_directive.rb#44 RuboCop::Cop::Lint::RedundantCopEnableDirective::MSG = T.let(T.unsafe(nil), String) # Sort globbed results by default in Ruby 3.0. @@ -21465,6 +22024,79 @@ RuboCop::Cop::Lint::RedundantDirGlobSort::MSG = T.let(T.unsafe(nil), String) # source://rubocop//lib/rubocop/cop/lint/redundant_dir_glob_sort.rb#37 RuboCop::Cop::Lint::RedundantDirGlobSort::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) +# Checks for redundant quantifiers inside Regexp literals. +# +# It is always allowed when interpolation is used in a regexp literal, +# because it's unknown what kind of string will be expanded as a result: +# +# [source,ruby] +# ---- +# /(?:a*#{interpolation})?/x +# ---- +# +# @example +# # bad +# /(?:x+)+/ +# +# # good +# /(?:x)+/ +# +# # good +# /(?:x+)/ +# +# # bad +# /(?:x+)?/ +# +# # good +# /(?:x)*/ +# +# # good +# /(?:x*)/ +# +# source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#34 +class RuboCop::Cop::Lint::RedundantRegexpQuantifiers < ::RuboCop::Cop::Base + include ::RuboCop::Cop::RangeHelp + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#42 + def on_regexp(node); end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#83 + def character_set?(expr); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#61 + def each_redundantly_quantified_pair(node); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#87 + def mergeable_quantifier(expr); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#103 + def merged_quantifier(exp1, exp2); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#119 + def message(group, child, replacement); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#115 + def quantifier_range(group, child); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#75 + def redundant_group?(expr); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#79 + def redundantly_quantifiable?(node); end +end + +# source://rubocop//lib/rubocop/cop/lint/redundant_regexp_quantifiers.rb#38 +RuboCop::Cop::Lint::RedundantRegexpQuantifiers::MSG_REDUNDANT_QUANTIFIER = T.let(T.unsafe(nil), String) + # Checks for unnecessary `require` statement. # # The following features are unnecessary `require` statement because @@ -21494,45 +22126,53 @@ RuboCop::Cop::Lint::RedundantDirGlobSort::RESTRICT_ON_SEND = T.let(T.unsafe(nil) # # good # require 'unloaded_feature' # -# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#34 +# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#38 class RuboCop::Cop::Lint::RedundantRequireStatement < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#52 + # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#61 def on_send(node); end - # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#47 + # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#57 + def pp_const?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#51 def redundant_require_statement?(param0 = T.unsafe(nil)); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#71 - def redundant_feature?(feature_name); end + # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#91 + def need_to_require_pp?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#82 - def use_pretty_print_method?; end + # source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#80 + def redundant_feature?(feature_name); end end -# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#38 +# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#42 RuboCop::Cop::Lint::RedundantRequireStatement::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#41 +# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#45 RuboCop::Cop::Lint::RedundantRequireStatement::PRETTY_PRINT_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#39 +# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#43 RuboCop::Cop::Lint::RedundantRequireStatement::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#40 +# source://rubocop//lib/rubocop/cop/lint/redundant_require_statement.rb#44 RuboCop::Cop::Lint::RedundantRequireStatement::RUBY_22_LOADED_FEATURES = T.let(T.unsafe(nil), Array) # Checks for redundant safe navigation calls. -# `instance_of?`, `kind_of?`, `is_a?`, `eql?`, `respond_to?`, and `equal?` methods -# are checked by default. These are customizable with `AllowedMethods` option. +# Use cases where a constant, named in camel case for classes and modules is `nil` are rare, +# and an offense is not detected when the receiver is a constant. The detection also applies +# to literal receivers, except for `nil`. +# +# For all receivers, the `instance_of?`, `kind_of?`, `is_a?`, `eql?`, `respond_to?`, +# and `equal?` methods are checked by default. +# These are customizable with `AllowedMethods` option. # # The `AllowedMethods` option specifies nil-safe methods, # in other words, it is a method that is allowed to skip safe navigation. @@ -21544,6 +22184,9 @@ RuboCop::Cop::Lint::RedundantRequireStatement::RUBY_22_LOADED_FEATURES = T.let(T # # @example # # bad +# CamelCaseConst&.do_something +# +# # bad # do_something if attrs&.respond_to?(:[]) # # # good @@ -21555,12 +22198,31 @@ RuboCop::Cop::Lint::RedundantRequireStatement::RUBY_22_LOADED_FEATURES = T.let(T # end # # # good +# CamelCaseConst.do_something +# +# # good # while node.is_a?(BeginNode) # node = node.parent # end # # # good - without `&.` this will always return `true` # foo&.respond_to?(:to_a) +# +# # bad - for `nil`s conversion methods return default values for the type +# foo&.to_h || {} +# foo&.to_h { |k, v| [k, v] } || {} +# foo&.to_a || [] +# foo&.to_i || 0 +# foo&.to_f || 0.0 +# foo&.to_s || '' +# +# # good +# foo.to_h +# foo.to_h { |k, v| [k, v] } +# foo.to_a +# foo.to_i +# foo.to_f +# foo.to_s # @example AllowedMethods: [nil_safe_method] # # bad # do_something if attrs&.nil_safe_method(:[]) @@ -21569,38 +22231,54 @@ RuboCop::Cop::Lint::RedundantRequireStatement::RUBY_22_LOADED_FEATURES = T.let(T # do_something if attrs.nil_safe_method(:[]) # do_something if attrs&.not_nil_safe_method(:[]) # -# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#51 +# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#78 class RuboCop::Cop::Lint::RedundantSafeNavigation < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedMethods - include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#65 + # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#95 + def conversion_with_default?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#107 def on_csend(node); end - # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#61 + # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#117 + def on_or(node); end + + # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#90 def respond_to_nil_specific_method?(param0 = T.unsafe(nil)); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#75 + # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#133 + def assume_receiver_instance_exists?(receiver); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#139 def check?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#85 + # source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#149 def condition?(parent, node); end end -# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#56 +# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#82 RuboCop::Cop::Lint::RedundantSafeNavigation::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#58 +# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#83 +RuboCop::Cop::Lint::RedundantSafeNavigation::MSG_LITERAL = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#85 RuboCop::Cop::Lint::RedundantSafeNavigation::NIL_SPECIFIC_METHODS = T.let(T.unsafe(nil), Set) -# Checks for unneeded usages of splat expansion +# source://rubocop//lib/rubocop/cop/lint/redundant_safe_navigation.rb#87 +RuboCop::Cop::Lint::RedundantSafeNavigation::SNAKE_CASE = T.let(T.unsafe(nil), Regexp) + +# Checks for unneeded usages of splat expansion. # # @example # @@ -21753,47 +22431,44 @@ RuboCop::Cop::Lint::RedundantSplatExpansion::PERCENT_W = T.let(T.unsafe(nil), St # @example # # # bad -# # "result is #{something.to_s}" # print something.to_s # puts something.to_s # warn something.to_s -# @example # # # good -# # "result is #{something}" # print something # puts something # warn something # -# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#27 +# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#23 class RuboCop::Cop::Lint::RedundantStringCoercion < ::RuboCop::Cop::Base include ::RuboCop::Cop::Interpolation extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#38 + # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#34 def on_interpolation(begin_node); end - # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#46 + # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#42 def on_send(node); end - # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#36 + # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#32 def to_s_without_args?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#58 + # source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#54 def register_offense(node, context); end end -# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#31 +# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#27 RuboCop::Cop::Lint::RedundantStringCoercion::MSG_DEFAULT = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#32 +# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#28 RuboCop::Cop::Lint::RedundantStringCoercion::MSG_SELF = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#33 +# source://rubocop//lib/rubocop/cop/lint/redundant_string_coercion.rb#29 RuboCop::Cop::Lint::RedundantStringCoercion::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for redundant `with_index`. @@ -21824,21 +22499,21 @@ class RuboCop::Cop::Lint::RedundantWithIndex < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#36 + # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#37 def on_block(node); end - # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#36 + # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#37 def on_numblock(node); end - # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#56 + # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#60 def redundant_with_index?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#66 + # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#70 def message(node); end - # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#74 + # source://rubocop//lib/rubocop/cop/lint/redundant_with_index.rb#78 def with_index_range(send); end end @@ -21973,38 +22648,35 @@ RuboCop::Cop::Lint::RegexpAsCondition::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # if day.is? :tuesday && month == :jan # # ... # end -# @example # # # good -# # if day.is?(:tuesday) && month == :jan # # ... # end # -# source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#30 +# source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#26 class RuboCop::Cop::Lint::RequireParentheses < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp - # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#35 + # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#31 def on_csend(node); end - # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#35 + # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#31 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#58 + # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#54 def check_predicate(predicate, node); end - # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#48 + # source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#44 def check_ternary(ternary, node); end end -# source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#33 +# source://rubocop//lib/rubocop/cop/lint/require_parentheses.rb#29 RuboCop::Cop::Lint::RequireParentheses::MSG = T.let(T.unsafe(nil), String) # Checks that a range literal is enclosed in parentheses when the end of the range is @@ -22098,34 +22770,31 @@ RuboCop::Cop::Lint::RequireRelativeSelfPath::RESTRICT_ON_SEND = T.let(T.unsafe(n # @example # # # bad -# # begin # do_something # rescue Exception # handle_exception # end -# @example # # # good -# # begin # do_something # rescue ArgumentError # handle_exception # end # -# source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#27 +# source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#23 class RuboCop::Cop::Lint::RescueException < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#30 + # source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#26 def on_resbody(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#39 + # source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#35 def targets_exception?(rescue_arg_node); end end -# source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#28 +# source://rubocop//lib/rubocop/cop/lint/rescue_exception.rb#24 RuboCop::Cop::Lint::RescueException::MSG = T.let(T.unsafe(nil), String) # Check for arguments to `rescue` that will result in a `TypeError` @@ -22172,13 +22841,13 @@ class RuboCop::Cop::Lint::RescueType < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/lint/rescue_type.rb#71 + # source://rubocop//lib/rubocop/cop/lint/rescue_type.rb#69 def correction(*exceptions); end - # source://rubocop//lib/rubocop/cop/lint/rescue_type.rb#82 + # source://rubocop//lib/rubocop/cop/lint/rescue_type.rb#80 def invalid_exceptions(exceptions); end - # source://rubocop//lib/rubocop/cop/lint/rescue_type.rb#78 + # source://rubocop//lib/rubocop/cop/lint/rescue_type.rb#76 def valid_exceptions(exceptions); end end @@ -22203,7 +22872,6 @@ RuboCop::Cop::Lint::RescueType::MSG = T.let(T.unsafe(nil), String) # def foo=(bar) # return 42 # end -# @example # # # good # def initialize @@ -22216,18 +22884,18 @@ RuboCop::Cop::Lint::RescueType::MSG = T.let(T.unsafe(nil), String) # return # end # -# source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#34 +# source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#32 class RuboCop::Cop::Lint::ReturnInVoidContext < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#37 + # source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#35 def on_return(return_node); end private - # source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#53 + # source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#51 def non_void_context(return_node); end end -# source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#35 +# source://rubocop//lib/rubocop/cop/lint/return_in_void_context.rb#33 RuboCop::Cop::Lint::ReturnInVoidContext::MSG = T.let(T.unsafe(nil), String) # The safe navigation operator returns nil if the receiver is @@ -22239,28 +22907,25 @@ RuboCop::Cop::Lint::ReturnInVoidContext::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # x&.foo.bar # x&.foo + bar # x&.foo[bar] -# @example # # # good -# # x&.foo&.bar # x&.foo || bar # -# source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#26 +# source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#22 class RuboCop::Cop::Lint::SafeNavigationChain < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedMethods include ::RuboCop::Cop::NilMethods extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#37 + # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#33 def bad_method?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#44 + # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#40 def on_send(node); end private @@ -22269,26 +22934,31 @@ class RuboCop::Cop::Lint::SafeNavigationChain < ::RuboCop::Cop::Base # @param send_node [RuboCop::AST::SendNode] # @return [String] # - # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#63 + # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#58 def add_safe_navigation_operator(offense_range:, send_node:); end # @param corrector [RuboCop::Cop::Corrector] # @param offense_range [Parser::Source::Range] # @param send_node [RuboCop::AST::SendNode] # - # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#82 + # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#77 def autocorrect(corrector, offense_range:, send_node:); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#92 + # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#86 def brackets?(send_node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#90 + def require_parentheses?(send_node); end end -# source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#33 +# source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#29 RuboCop::Cop::Lint::SafeNavigationChain::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#34 +# source://rubocop//lib/rubocop/cop/lint/safe_navigation_chain.rb#30 RuboCop::Cop::Lint::SafeNavigationChain::PLUS_MINUS_METHODS = T.let(T.unsafe(nil), Array) # Check to make sure that if safe navigation is used for a method @@ -22411,7 +23081,7 @@ class RuboCop::Cop::Lint::ScriptPermission < ::RuboCop::Cop::Base private # source://rubocop//lib/rubocop/cop/lint/script_permission.rb#55 - def autocorrect(comment); end + def autocorrect; end # @return [Boolean] # @@ -22435,55 +23105,74 @@ RuboCop::Cop::Lint::ScriptPermission::SHEBANG = T.let(T.unsafe(nil), String) # foo = foo # foo, bar = foo, bar # Foo = Foo +# hash['foo'] = hash['foo'] +# obj.attr = obj.attr # # # good # foo = bar # foo, bar = bar, foo # Foo = Bar +# hash['foo'] = hash['bar'] +# obj.attr = obj.attr2 +# +# # good (method calls possibly can return different results) +# hash[foo] = hash[foo] # -# source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#19 +# source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#26 class RuboCop::Cop::Lint::SelfAssignment < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#53 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#69 def on_and_asgn(node); end - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#41 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#57 def on_casgn(node); end - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#29 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#36 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#45 def on_cvasgn(node); end - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#29 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#45 def on_gvasgn(node); end - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#29 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#45 def on_ivasgn(node); end - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#29 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#45 def on_lvasgn(node); end - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#49 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#65 def on_masgn(node); end - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#53 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#69 def on_or_asgn(node); end + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#36 + def on_send(node); end + private + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#103 + def handle_attribute_assignment(node); end + + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#92 + def handle_key_assignment(node); end + # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#61 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#77 def multiple_self_assignment?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#71 + # source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#87 def rhs_matches_lhs?(rhs, lhs); end end -# source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#22 +# source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#29 RuboCop::Cop::Lint::SelfAssignment::ASSIGNMENT_TYPE_TO_RHS_TYPE = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#20 +# source://rubocop//lib/rubocop/cop/lint/self_assignment.rb#27 RuboCop::Cop::Lint::SelfAssignment::MSG = T.let(T.unsafe(nil), String) # Checks for `send`, `public_send`, and `__send__` methods @@ -22623,7 +23312,7 @@ class RuboCop::Cop::Lint::ShadowedArgument < ::RuboCop::Cop::Base # Get argument references without assignments' references # - # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#160 + # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#161 def argument_references(argument); end # Find the first argument assignment, which doesn't reference the @@ -22639,17 +23328,17 @@ class RuboCop::Cop::Lint::ShadowedArgument < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#170 + # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#171 def ignore_implicit_references?; end # Check whether the given node is nested into block or conditional. # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#151 + # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#152 def node_within_block_or_conditional?(node, stop_search_node); end - # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#143 + # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#144 def reference_pos(node); end # source://rubocop//lib/rubocop/cop/lint/shadowed_argument.rb#95 @@ -22772,17 +23461,16 @@ RuboCop::Cop::Lint::ShadowedException::MSG = T.let(T.unsafe(nil), String) # because `Ractor` should not access outer variables. # eg. following style is encouraged: # -# [source,ruby] -# ---- -# worker_id, pipe = env -# Ractor.new(worker_id, pipe) do |worker_id, pipe| -# end -# ---- +# [source,ruby] +# ---- +# worker_id, pipe = env +# Ractor.new(worker_id, pipe) do |worker_id, pipe| +# end +# ---- # # @example # # # bad -# # def some_method # foo = 1 # @@ -22790,10 +23478,8 @@ RuboCop::Cop::Lint::ShadowedException::MSG = T.let(T.unsafe(nil), String) # do_something(foo) # end # end -# @example # # # good -# # def some_method # foo = 1 # @@ -22802,32 +23488,37 @@ RuboCop::Cop::Lint::ShadowedException::MSG = T.let(T.unsafe(nil), String) # end # end # -# source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#45 +# source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#41 class RuboCop::Cop::Lint::ShadowingOuterLocalVariable < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#57 + # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#53 def before_declaring_variable(variable, variable_table); end - # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#93 + # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#89 def find_conditional_node_from_ascendant(node); end - # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#49 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#96 + def node_or_its_ascendant_conditional?(node); end + + # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#45 def ractor_block?(param0 = T.unsafe(nil)); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#69 + # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#65 def same_conditions_node_different_branch?(variable, outer_local_variable); end - # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#83 + # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#79 def variable_node(variable); end class << self - # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#53 + # source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#49 def joining_forces; end end end -# source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#46 +# source://rubocop//lib/rubocop/cop/lint/shadowing_outer_local_variable.rb#42 RuboCop::Cop::Lint::ShadowingOuterLocalVariable::MSG = T.let(T.unsafe(nil), String) # Checks unexpected overrides of the `Struct` built-in methods @@ -23002,6 +23693,7 @@ RuboCop::Cop::Lint::SuppressedException::MSG = T.let(T.unsafe(nil), String) # 'underscored_string'.to_sym # :'underscored_symbol' # 'hyphenated-string'.to_sym +# "string_#{interpolation}".to_sym # # # good # :string @@ -23009,6 +23701,7 @@ RuboCop::Cop::Lint::SuppressedException::MSG = T.let(T.unsafe(nil), String) # :underscored_string # :underscored_symbol # :'hyphenated-string' +# :"string_#{interpolation}" # @example EnforcedStyle: strict (default) # # # bad @@ -23044,60 +23737,60 @@ RuboCop::Cop::Lint::SuppressedException::MSG = T.let(T.unsafe(nil), String) # b: 2 # } # -# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#66 +# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#68 class RuboCop::Cop::Lint::SymbolConversion < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle include ::RuboCop::Cop::SymbolHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#100 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#105 def on_hash(node); end - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#76 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#78 def on_send(node); end - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#83 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#88 def on_sym(node); end private - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#142 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#147 def correct_hash_key(node); end - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#161 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#166 def correct_inconsistent_hash_keys(keys); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#134 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#139 def in_alias?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#138 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#143 def in_percent_literal_array?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#121 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#126 def properly_quoted?(source, value); end - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#117 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#122 def register_offense(node, correction:, message: T.unsafe(nil)); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#130 + # source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#135 def requires_quotes?(sym_node); end end -# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#71 +# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#73 RuboCop::Cop::Lint::SymbolConversion::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#72 +# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#74 RuboCop::Cop::Lint::SymbolConversion::MSG_CONSISTENCY = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#74 +# source://rubocop//lib/rubocop/cop/lint/symbol_conversion.rb#76 RuboCop::Cop::Lint::SymbolConversion::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Repacks Parser's diagnostics/errors @@ -23113,13 +23806,13 @@ class RuboCop::Cop::Lint::Syntax < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/lint/syntax.rb#19 def add_offense_from_diagnostic(diagnostic, ruby_version); end - # source://rubocop//lib/rubocop/cop/lint/syntax.rb#26 + # source://rubocop//lib/rubocop/cop/lint/syntax.rb#29 def add_offense_from_error(error); end - # source://rubocop//lib/rubocop/cop/lint/syntax.rb#31 + # source://rubocop//lib/rubocop/cop/lint/syntax.rb#34 def beautify_message(message); end - # source://rubocop//lib/rubocop/cop/lint/syntax.rb#37 + # source://rubocop//lib/rubocop/cop/lint/syntax.rb#40 def find_severity(_range, _severity); end end @@ -23162,12 +23855,12 @@ class RuboCop::Cop::Lint::ToEnumArguments < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/to_enum_arguments.rb#78 + # source://rubocop//lib/rubocop/cop/lint/to_enum_arguments.rb#76 def argument_match?(send_arg, def_arg); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/to_enum_arguments.rb#63 + # source://rubocop//lib/rubocop/cop/lint/to_enum_arguments.rb#61 def arguments_match?(arguments, def_node); end end @@ -23476,27 +24169,24 @@ RuboCop::Cop::Lint::UnexpectedBlockArity::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # 1.is_a?(Fixnum) # 1.is_a?(Bignum) -# @example # # # good -# # 1.is_a?(Integer) # -# source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#20 +# source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#16 class RuboCop::Cop::Lint::UnifiedInteger < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#26 + # source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#22 def fixnum_or_bignum_const(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#30 + # source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#26 def on_const(node); end end -# source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#23 +# source://rubocop//lib/rubocop/cop/lint/unified_integer.rb#19 RuboCop::Cop::Lint::UnifiedInteger::MSG = T.let(T.unsafe(nil), String) # Looks for `reduce` or `inject` blocks where the value returned (implicitly or @@ -23591,31 +24281,31 @@ class RuboCop::Cop::Lint::UnmodifiedReduceAccumulator < ::RuboCop::Cop::Base # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#190 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#191 def acceptable_return?(return_val, element_name); end # Exclude `begin` nodes inside a `dstr` from being collected by `return_values` # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#198 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#199 def allowed_type?(parent_node); end - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#158 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#159 def block_arg_name(node, index); end - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#141 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#142 def check_return_values(block_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#175 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#176 def potential_offense?(return_values, block_body, element_name, accumulator_name); end # Return values in a block are either the value given to next, # the last line of a multiline block, or the only line of the block # - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#127 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#128 def return_values(block_body_node); end # Look for an index of the accumulator being returned, except where the index @@ -23623,7 +24313,7 @@ class RuboCop::Cop::Lint::UnmodifiedReduceAccumulator < ::RuboCop::Cop::Base # This is always an offense, in order to try to catch potential exceptions # due to type mismatches # - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#166 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#167 def returned_accumulator_index(return_values, accumulator_name, element_name); end # If the accumulator is used in any return value, the node is acceptable since @@ -23631,7 +24321,7 @@ class RuboCop::Cop::Lint::UnmodifiedReduceAccumulator < ::RuboCop::Cop::Base # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#182 + # source://rubocop//lib/rubocop/cop/lint/unmodified_reduce_accumulator.rb#183 def returns_accumulator_anywhere?(return_values, accumulator_name); end end @@ -23648,14 +24338,12 @@ RuboCop::Cop::Lint::UnmodifiedReduceAccumulator::MSG_INDEX = T.let(T.unsafe(nil) # @example # # # bad -# # def some_method # return # do_something # end # # # bad -# # def some_method # if cond # return @@ -23664,40 +24352,38 @@ RuboCop::Cop::Lint::UnmodifiedReduceAccumulator::MSG_INDEX = T.let(T.unsafe(nil) # end # do_something # end -# @example # # # good -# # def some_method # do_something # end # -# source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#37 +# source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#32 class RuboCop::Cop::Lint::UnreachableCode < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#55 + # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#50 def flow_command?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#40 + # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#35 def on_begin(node); end - # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#40 + # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#35 def on_kwbegin(node); end private - # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#87 + # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#82 def check_case(node); end - # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#81 + # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#76 def check_if(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#65 + # source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#60 def flow_expression?(node); end end -# source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#38 +# source://rubocop//lib/rubocop/cop/lint/unreachable_code.rb#33 RuboCop::Cop::Lint::UnreachableCode::MSG = T.let(T.unsafe(nil), String) # Checks for loops that will have at most one iteration. @@ -23826,7 +24512,7 @@ class RuboCop::Cop::Lint::UnreachableLoop < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/unreachable_loop.rb#194 + # source://rubocop//lib/rubocop/cop/lint/unreachable_loop.rb#200 def conditional_continue_keyword?(break_statement); end # @return [Boolean] @@ -23836,7 +24522,7 @@ class RuboCop::Cop::Lint::UnreachableLoop < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/unreachable_loop.rb#184 + # source://rubocop//lib/rubocop/cop/lint/unreachable_loop.rb#190 def preceded_by_continue_statement?(break_statement); end # source://rubocop//lib/rubocop/cop/lint/unreachable_loop.rb#130 @@ -24353,93 +25039,109 @@ RuboCop::Cop::Lint::UselessAccessModifier::MSG = T.let(T.unsafe(nil), String) # scope. # The basic idea for this cop was from the warning of `ruby -cw`: # -# assigned but unused variable - foo +# [source,console] +# ---- +# assigned but unused variable - foo +# ---- # # Currently this cop has advanced logic that detects unreferenced # reassignments and properly handles varied cases such as branch, loop, # rescue, ensure, etc. # +# NOTE: Given the assignment `foo = 1, bar = 2`, removing unused variables +# can lead to a syntax error, so this case is not autocorrected. +# # @example # # # bad -# # def some_method # some_var = 1 # do_something # end -# @example # # # good -# # def some_method # some_var = 1 # do_something(some_var) # end # -# source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#39 +# source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#41 class RuboCop::Cop::Lint::UselessAssignment < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#50 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#52 def after_leaving_scope(scope, _variable_table); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#136 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#158 def autocorrect(corrector, assignment); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#54 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#99 + def chained_assignment?(node); end + + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#57 def check_for_unused_assignments(variable); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#120 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#142 def collect_variable_like_names(scope); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#74 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#75 def message_for_useless_assignment(assignment); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#80 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#103 def message_specification(assignment, variable); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#90 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#113 def multiple_assignment_message(variable_name); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#95 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#81 + def offense_range(assignment); end + + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#118 def operator_assignment_message(scope, assignment); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#153 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#175 def remove_exception_assignment_part(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#177 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#199 def remove_local_variable_assignment_part(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#166 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#188 def remove_trailing_character_from_operator(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#162 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#184 def rename_variable_with_underscore(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#170 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#192 def replace_named_capture_group_with_non_capturing_group(corrector, node, variable_name); end # TODO: More precise handling (rescue, ensure, nested begin, etc.) # - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#110 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#132 def return_value_node_of_scope(scope); end - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#103 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#89 + def sequential_assignment?(node); end + + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#125 def similar_name_message(variable); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#129 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#151 def variable_like_method_invocation?(node); end class << self - # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#46 + # source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#48 def joining_forces; end end end -# source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#44 +# source://rubocop//lib/rubocop/cop/lint/useless_assignment.rb#46 RuboCop::Cop::Lint::UselessAssignment::MSG = T.let(T.unsafe(nil), String) # Checks for useless `else` in `begin..end` without `rescue`. @@ -24449,16 +25151,13 @@ RuboCop::Cop::Lint::UselessAssignment::MSG = T.let(T.unsafe(nil), String) # @example # # # bad -# # begin # do_something # else # do_something_else # This will never be run. # end -# @example # # # good -# # begin # do_something # rescue @@ -24467,13 +25166,13 @@ RuboCop::Cop::Lint::UselessAssignment::MSG = T.let(T.unsafe(nil), String) # do_something_else # end # -# source://rubocop//lib/rubocop/cop/lint/useless_else_without_rescue.rb#31 +# source://rubocop//lib/rubocop/cop/lint/useless_else_without_rescue.rb#27 class RuboCop::Cop::Lint::UselessElseWithoutRescue < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/lint/useless_else_without_rescue.rb#34 + # source://rubocop//lib/rubocop/cop/lint/useless_else_without_rescue.rb#30 def on_new_investigation; end end -# source://rubocop//lib/rubocop/cop/lint/useless_else_without_rescue.rb#32 +# source://rubocop//lib/rubocop/cop/lint/useless_else_without_rescue.rb#28 RuboCop::Cop::Lint::UselessElseWithoutRescue::MSG = T.let(T.unsafe(nil), String) # Checks for useless method definitions, specifically: empty constructors @@ -24701,88 +25400,85 @@ RuboCop::Cop::Lint::UselessRuby2Keywords::RESTRICT_ON_SEND = T.let(T.unsafe(nil) # @example # # # bad -# # def something # x = Something.new # x.attr = 5 # end -# @example # # # good -# # def something # x = Something.new # x.attr = 5 # x # end # -# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#35 +# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#31 class RuboCop::Cop::Lint::UselessSetterCall < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#41 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#37 def on_def(node); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#41 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#37 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#63 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#59 def setter_call_to_local_variable?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#67 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#63 def last_expression(body); end end -# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#39 +# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#35 RuboCop::Cop::Lint::UselessSetterCall::ASSIGNMENT_TYPES = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#38 +# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#34 RuboCop::Cop::Lint::UselessSetterCall::MSG = T.let(T.unsafe(nil), String) # This class tracks variable assignments in a method body # and if a variable contains object passed as argument at the end of # the method. # -# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#76 +# source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#72 class RuboCop::Cop::Lint::UselessSetterCall::MethodVariableTracker # @return [MethodVariableTracker] a new instance of MethodVariableTracker # - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#77 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#73 def initialize(body_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#163 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#159 def constructor?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#82 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#78 def contain_local_object?(variable_name); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#152 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#148 def process_assignment(asgn_node, rhs_node); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#100 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#96 def process_assignment_node(node); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#142 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#138 def process_binary_operator_assignment(op_asgn_node); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#133 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#129 def process_logical_operator_assignment(asgn_node); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#114 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#110 def process_multiple_assignment(masgn_node); end - # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#92 + # source://rubocop//lib/rubocop/cop/lint/useless_setter_call.rb#88 def scan(node, &block); end end # Checks for uses of `Integer#times` that will never yield -# (when the integer <= 0) or that will only ever yield once +# (when the integer ``<= 0``) or that will only ever yield once # (`1.times`). # # @example @@ -24850,6 +25546,16 @@ RuboCop::Cop::Lint::UselessTimes::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for operators, variables, literals, lambda, proc and nonmutating # methods used in void context. # +# `each` blocks are allowed to prevent false positives. +# For example, the expression inside the `each` block below. +# It's not void, especially when the receiver is an `Enumerator`: +# +# [source,ruby] +# ---- +# enumerator = [1, 2, 3].filter +# enumerator.each { |item| item >= 2 } #=> [2, 3] +# ---- +# # @example CheckForMethodsWithNoSideEffects: false (default) # # bad # def some_method @@ -24884,110 +25590,109 @@ RuboCop::Cop::Lint::UselessTimes::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # do_something(some_array) # end # -# source://rubocop//lib/rubocop/cop/lint/void.rb#43 +# source://rubocop//lib/rubocop/cop/lint/void.rb#53 class RuboCop::Cop::Lint::Void < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/lint/void.rb#80 + # source://rubocop//lib/rubocop/cop/lint/void.rb#92 def on_begin(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#71 + # source://rubocop//lib/rubocop/cop/lint/void.rb#82 def on_block(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#80 + # source://rubocop//lib/rubocop/cop/lint/void.rb#92 def on_kwbegin(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#71 + # source://rubocop//lib/rubocop/cop/lint/void.rb#82 def on_numblock(node); end private - # source://rubocop//lib/rubocop/cop/lint/void.rb#200 + # source://rubocop//lib/rubocop/cop/lint/void.rb#222 def autocorrect_nonmutating_send(corrector, node, suggestion); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#196 + # source://rubocop//lib/rubocop/cop/lint/void.rb#216 def autocorrect_void_expression(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#188 - def autocorrect_void_literal(corrector, node); end - - # source://rubocop//lib/rubocop/cop/lint/void.rb#172 + # source://rubocop//lib/rubocop/cop/lint/void.rb#204 def autocorrect_void_op(corrector, node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#192 - def autocorrect_void_self(corrector, node); end - - # source://rubocop//lib/rubocop/cop/lint/void.rb#184 - def autocorrect_void_var(corrector, node); end - - # source://rubocop//lib/rubocop/cop/lint/void.rb#87 + # source://rubocop//lib/rubocop/cop/lint/void.rb#99 def check_begin(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#93 + # source://rubocop//lib/rubocop/cop/lint/void.rb#113 def check_expression(expr); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#122 + # source://rubocop//lib/rubocop/cop/lint/void.rb#154 def check_literal(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#146 + # source://rubocop//lib/rubocop/cop/lint/void.rb#178 def check_nonmutating(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#130 + # source://rubocop//lib/rubocop/cop/lint/void.rb#162 def check_self(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#113 + # source://rubocop//lib/rubocop/cop/lint/void.rb#136 def check_var(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#138 + # source://rubocop//lib/rubocop/cop/lint/void.rb#170 def check_void_expression(node); end - # source://rubocop//lib/rubocop/cop/lint/void.rb#104 - def check_void_op(node); end + # source://rubocop//lib/rubocop/cop/lint/void.rb#125 + def check_void_op(node, &block); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/lint/void.rb#164 + # source://rubocop//lib/rubocop/cop/lint/void.rb#231 + def entirely_literal?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/lint/void.rb#196 def in_void_context?(node); end end -# source://rubocop//lib/rubocop/cop/lint/void.rb#55 +# source://rubocop//lib/rubocop/cop/lint/void.rb#66 RuboCop::Cop::Lint::Void::BINARY_OPERATORS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/void.rb#52 +# source://rubocop//lib/rubocop/cop/lint/void.rb#60 +RuboCop::Cop::Lint::Void::CONST_MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/lint/void.rb#63 RuboCop::Cop::Lint::Void::EXPRESSION_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/void.rb#50 +# source://rubocop//lib/rubocop/cop/lint/void.rb#61 RuboCop::Cop::Lint::Void::LIT_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/void.rb#66 +# source://rubocop//lib/rubocop/cop/lint/void.rb#77 RuboCop::Cop::Lint::Void::METHODS_REPLACEABLE_BY_EACH = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/void.rb#68 +# source://rubocop//lib/rubocop/cop/lint/void.rb#79 RuboCop::Cop::Lint::Void::NONMUTATING_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/void.rb#59 +# source://rubocop//lib/rubocop/cop/lint/void.rb#70 RuboCop::Cop::Lint::Void::NONMUTATING_METHODS_WITH_BANG_VERSION = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/void.rb#53 +# source://rubocop//lib/rubocop/cop/lint/void.rb#64 RuboCop::Cop::Lint::Void::NONMUTATING_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/void.rb#57 +# source://rubocop//lib/rubocop/cop/lint/void.rb#68 RuboCop::Cop::Lint::Void::OPERATORS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/void.rb#48 +# source://rubocop//lib/rubocop/cop/lint/void.rb#58 RuboCop::Cop::Lint::Void::OP_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/void.rb#51 +# source://rubocop//lib/rubocop/cop/lint/void.rb#62 RuboCop::Cop::Lint::Void::SELF_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/void.rb#56 +# source://rubocop//lib/rubocop/cop/lint/void.rb#67 RuboCop::Cop::Lint::Void::UNARY_OPERATORS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/lint/void.rb#49 +# source://rubocop//lib/rubocop/cop/lint/void.rb#59 RuboCop::Cop::Lint::Void::VAR_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/lint/void.rb#58 +# source://rubocop//lib/rubocop/cop/lint/void.rb#69 RuboCop::Cop::Lint::Void::VOID_CONTEXT_TYPES = T.let(T.unsafe(nil), Array) # Common functionality for obtaining source ranges from regexp matches @@ -25171,6 +25876,11 @@ module RuboCop::Cop::MethodComplexity # # source://rubocop//lib/rubocop/cop/mixin/method_complexity.rb#61 def complexity(body); end + + # @api private + # + # source://rubocop//lib/rubocop/cop/mixin/method_complexity.rb#73 + def location(node); end end # Common code for cops that deal with preferred methods. @@ -25199,9 +25909,9 @@ module RuboCop::Cop::Metrics; end # # Interpreting ABC size: # -# * <= 17 satisfactory -# * 18..30 unsatisfactory -# * > 30 dangerous +# * ``<= 17`` satisfactory +# * `18..30` unsatisfactory +# * `>` 30 dangerous # # You can have repeated "attributes" calls count as a single "branch". # For this purpose, attributes are any method with no argument; no attempt @@ -25250,13 +25960,12 @@ RuboCop::Cop::Metrics::AbcSize::MSG = T.let(T.unsafe(nil), String) # Available are: 'array', 'hash', 'heredoc', and 'method_call'. Each construct # will be counted as one line regardless of its actual size. # +# NOTE: This cop does not apply for `Struct` definitions. # # NOTE: The `ExcludedMethods` configuration is deprecated and only kept # for backwards compatibility. Please use `AllowedMethods` and `AllowedPatterns` # instead. By default, there are no methods to allowed. # -# NOTE: This cop does not apply for `Struct` definitions. -# # @example CountAsOne: ['array', 'heredoc', 'method_call'] # # something do @@ -25306,12 +26015,12 @@ end # source://rubocop//lib/rubocop/cop/metrics/block_length.rb#49 RuboCop::Cop::Metrics::BlockLength::LABEL = T.let(T.unsafe(nil), String) -# Checks for excessive nesting of conditional and looping -# constructs. +# Checks for excessive nesting of conditional and looping constructs. # -# You can configure if blocks are considered using the `CountBlocks` -# option. When set to `false` (the default) blocks are not counted -# towards the nesting level. Set to `true` to count blocks as well. +# You can configure if blocks are considered using the `CountBlocks` and `CountModifierForms` +# options. When both are set to `false` (the default) blocks and modifier forms are not +# counted towards the nesting level. Set them to `true` to include these in the nesting level +# calculation as well. # # The maximum level of nesting allowed is configurable. # @@ -25330,15 +26039,25 @@ class RuboCop::Cop::Metrics::BlockNesting < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#44 + # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#52 def consider_node?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#54 + # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#62 def count_blocks?; end - # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#50 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#44 + def count_if_block?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#66 + def count_modifier_forms?; end + + # source://rubocop//lib/rubocop/cop/metrics/block_nesting.rb#58 def message(max); end end @@ -25382,18 +26101,18 @@ RuboCop::Cop::Metrics::BlockNesting::NESTING_BLOCKS = T.let(T.unsafe(nil), Array class RuboCop::Cop::Metrics::ClassLength < ::RuboCop::Cop::Base include ::RuboCop::Cop::CodeLength - # source://rubocop//lib/rubocop/cop/metrics/class_length.rb#47 + # source://rubocop//lib/rubocop/cop/metrics/class_length.rb#52 def on_casgn(node); end # source://rubocop//lib/rubocop/cop/metrics/class_length.rb#42 def on_class(node); end - # source://rubocop//lib/rubocop/cop/metrics/class_length.rb#42 + # source://rubocop//lib/rubocop/cop/metrics/class_length.rb#46 def on_sclass(node); end private - # source://rubocop//lib/rubocop/cop/metrics/class_length.rb#65 + # source://rubocop//lib/rubocop/cop/metrics/class_length.rb#70 def message(length, max_length); end end @@ -25897,18 +26616,18 @@ class RuboCop::Cop::Metrics::Utils::CodeLengthCalculator # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#175 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#182 def another_args?(node); end # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#42 def build_foldable_checks(types); end - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#83 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#90 def classlike_code_length(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#131 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#138 def classlike_node?(node); end # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#66 @@ -25916,53 +26635,61 @@ class RuboCop::Cop::Metrics::Utils::CodeLengthCalculator # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#156 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#163 def count_comments?; end - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#119 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#126 def each_top_level_descendant(node, types, &block); end - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#139 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#146 def extract_body(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#135 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#142 def foldable_node?(node); end - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#114 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#121 def heredoc_length(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#79 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#86 def heredoc_node?(node); end # Returns true for lines that shall not be included in the count. # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#152 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#159 def irrelevant_line?(source_line); end - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#103 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#110 def line_numbers_of_inner_nodes(node, *types); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#99 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#106 def namespace_module?(node); end + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#186 + def node_with_heredoc?(node); end + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#60 def normalize_foldable_types(types); end - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#160 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#167 def omit_length(descendant); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#171 + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#178 def parenthesized?(node); end + + # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#190 + def source_from_node_with_heredoc(node); end end # source://rubocop//lib/rubocop/cop/metrics/utils/code_length_calculator.rb#13 @@ -26260,18 +26987,21 @@ end # # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#7 module RuboCop::Cop::MultilineExpressionIndentation + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#14 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#14 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#131 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#132 def argument_in_method_call(node, kind); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#187 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#188 def assignment_rhs(node); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#64 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#65 def check(range, node, lhs, rhs); end # The correct indentation of `node` is usually `IndentationWidth`, with @@ -26291,62 +27021,62 @@ module RuboCop::Cop::MultilineExpressionIndentation # bar # normal indentation, not special # ``` # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#54 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#55 def correct_indentation(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#159 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#160 def disqualified_rhs?(candidate, ancestor); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#203 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#204 def grouped_expression?(node); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#72 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#73 def incorrect_style_detected(range, node, lhs, rhs); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#84 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#85 def indentation(node); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#121 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#122 def indented_keyword_expression(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#207 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#208 def inside_arg_list_parentheses?(node, ancestor); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#98 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#99 def keyword_message_tail(node); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#106 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#107 def kw_node_with_special_indentation(node); end - # In a chain of method calls, we regard the top send node as the base + # In a chain of method calls, we regard the top call node as the base # for indentation of all lines following the first. For example: # a. # b c { block }. <-- b is indented relative to a # d <-- d is indented relative to a # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#31 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#32 def left_hand_side(lhs); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#197 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#198 def not_for_this_cop?(node); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#88 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#89 def operation_description(node, rhs); end - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#145 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#146 def part_of_assignment_rhs(node, candidate); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#183 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#184 def part_of_block_body?(candidate, block_node); end # Returns true if `node` is a conditional whose `body` and `condition` @@ -26354,29 +27084,29 @@ module RuboCop::Cop::MultilineExpressionIndentation # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#216 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#217 def postfix_conditional?(node); end # The []= operator and setters (a.b = c) are parsed as :send nodes. # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#175 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#176 def valid_method_rhs_candidate?(candidate, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#164 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#165 def valid_rhs?(candidate, ancestor); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#179 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#180 def valid_rhs_candidate?(candidate, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#220 + # source://rubocop//lib/rubocop/cop/mixin/multiline_expression_indentation.rb#221 def within_node?(inner, outer); end end @@ -26789,33 +27519,56 @@ class RuboCop::Cop::Naming::BlockForwarding < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#87 + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#114 def anonymous_block_argument?(node); end - # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#119 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#87 + def block_argument_name_matched?(block_pass_node, last_argument); end + + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#146 def block_forwarding_name; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#73 + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#77 def expected_block_forwarding_style?(node, last_argument); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#91 + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#118 def explicit_block_argument?(node); end - # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#95 + # Prevents the following syntax error: + # + # # foo.rb + # def foo(&) + # block_method do + # bar(&) + # end + # end + # + # $ ruby -vc foo.rb + # ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [x86_64-darwin22] + # foo.rb: foo.rb:4: anonymous block parameter is also used within block (SyntaxError) + # + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#106 + def invalidates_syntax?(block_pass_node); end + + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#122 def register_offense(block_argument, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#111 + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#138 def use_block_argument_as_local_variable?(node, last_argument); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#83 + # source://rubocop//lib/rubocop/cop/naming/block_forwarding.rb#110 def use_kwarg_in_method_definition?(node); end class << self @@ -26924,7 +27677,7 @@ class RuboCop::Cop::Naming::ConstantName < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#27 def class_or_struct_return_method?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#69 + # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#68 def literal_receiver?(param0 = T.unsafe(nil)); end # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#33 @@ -26939,7 +27692,7 @@ class RuboCop::Cop::Naming::ConstantName < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#74 + # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#73 def allowed_conditional_expression_on_rhs?(node); end # @return [Boolean] @@ -26949,7 +27702,7 @@ class RuboCop::Cop::Naming::ConstantName < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#78 + # source://rubocop//lib/rubocop/cop/naming/constant_name.rb#77 def contains_constant?(node); end end @@ -27041,8 +27794,6 @@ class RuboCop::Cop::Naming::FileName < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/naming/file_name.rb#165 def find_definition(node); end - # @yield [source_range(processed_source.buffer, 1, 0), msg] - # # source://rubocop//lib/rubocop/cop/naming/file_name.rb#65 def for_bad_filename(file_path); end @@ -27188,12 +27939,12 @@ class RuboCop::Cop::Naming::HeredocDelimiterNaming < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/naming/heredoc_delimiter_naming.rb#49 + # source://rubocop//lib/rubocop/cop/naming/heredoc_delimiter_naming.rb#51 def forbidden_delimiters; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/heredoc_delimiter_naming.rb#39 + # source://rubocop//lib/rubocop/cop/naming/heredoc_delimiter_naming.rb#41 def meaningful_delimiters?(node); end end @@ -27294,13 +28045,13 @@ class RuboCop::Cop::Naming::InclusiveLanguage < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#126 def check_token?(type); end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#244 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#243 def create_message(word, message = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#218 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#217 def create_multiple_word_message_for_file(words); end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#214 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#213 def create_single_word_message_for_file(word); end # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#189 @@ -27309,10 +28060,10 @@ class RuboCop::Cop::Naming::InclusiveLanguage < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#160 def extract_regexp(term, term_definition); end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#252 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#251 def find_flagged_term(word); end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#266 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#265 def format_suggestions(suggestions); end # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#197 @@ -27321,10 +28072,10 @@ class RuboCop::Cop::Naming::InclusiveLanguage < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#100 def investigate_tokens; end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#232 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#231 def mask_input(str); end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#281 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#280 def offense_range(token, word); end # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#130 @@ -27333,13 +28084,13 @@ class RuboCop::Cop::Naming::InclusiveLanguage < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#144 def preprocess_flagged_terms; end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#259 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#258 def preprocess_suggestions(suggestions); end # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#179 def process_allowed_regex(allowed); end - # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#222 + # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#221 def scan_for_words(input); end # source://rubocop//lib/rubocop/cop/naming/inclusive_language.rb#174 @@ -27689,94 +28440,109 @@ class RuboCop::Cop::Naming::MethodParameterName < ::RuboCop::Cop::Base def on_defs(node); end end -# Checks that predicate methods names end with a question mark and +# Checks that predicate method names end with a question mark and # do not start with a forbidden prefix. # -# A method is determined to be a predicate method if its name starts -# with one of the prefixes defined in the `NamePrefix` configuration. -# You can change what prefixes are considered by changing this option. -# Any method name that starts with one of these prefixes is required by -# the cop to end with a `?`. Other methods can be allowed by adding to -# the `AllowedMethods` configuration. -# -# NOTE: The `is_a?` method is allowed by default. +# A method is determined to be a predicate method if its name starts with +# one of the prefixes listed in the `NamePrefix` configuration. The list +# defaults to `is_`, `has_`, and `have_` but may be overridden. # -# If `ForbiddenPrefixes` is set, methods that start with the configured -# prefixes will not be allowed and will be removed by autocorrection. +# Predicate methods must end with a question mark. # -# In other words, if `ForbiddenPrefixes` is empty, a method named `is_foo` -# will register an offense only due to the lack of question mark (and will be -# autocorrected to `is_foo?`). If `ForbiddenPrefixes` contains `is_`, -# `is_foo` will register an offense both because the ? is missing and because of -# the `is_` prefix, and will be corrected to `foo?`. +# When `ForbiddenPrefixes` is also set (as it is by default), predicate +# methods which begin with a forbidden prefix are not allowed, even if +# they end with a `?`. These methods should be changed to remove the +# prefix. # -# NOTE: `ForbiddenPrefixes` is only applied to prefixes in `NamePrefix`; -# a prefix in the former but not the latter will not be considered by -# this cop. -# -# @example +# @example NamePrefix: ['is_', 'has_', 'have_'] (default) # # bad # def is_even(value) # end # -# def is_even?(value) -# end -# +# # When ForbiddenPrefixes: ['is_', 'has_', 'have_'] (default) # # good # def even?(value) # end # +# # When ForbiddenPrefixes: [] +# # good +# def is_even?(value) +# end +# @example NamePrefix: ['seems_to_be_'] # # bad -# def has_value +# def seems_to_be_even(value) # end # -# def has_value? +# # When ForbiddenPrefixes: ['seems_to_be_'] +# # good +# def even?(value) # end # +# # When ForbiddenPrefixes: [] # # good -# def value? +# def seems_to_be_even?(value) # end # @example AllowedMethods: ['is_a?'] (default) +# # Despite starting with the `is_` prefix, this method is allowed # # good # def is_a?(value) # end +# @example AllowedMethods: ['is_even?'] +# # good +# def is_even?(value) +# end +# @example MethodDefinitionMacros: ['define_method', 'define_singleton_method'] (default) +# # bad +# define_method(:is_even) { |value| } +# +# # good +# define_method(:even?) { |value| } +# @example MethodDefinitionMacros: ['def_node_matcher'] +# # bad +# def_node_matcher(:is_even) { |value| } # -# source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#59 +# # good +# # def_node_matcher(:even?) { |value| } +# +# source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#75 class RuboCop::Cop::Naming::PredicateName < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedMethods - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#63 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#79 def dynamic_method_define(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#82 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#98 def on_def(node); end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#82 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#98 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#69 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#85 def on_send(node); end + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#112 + def validate_config; end + private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#98 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#124 def allowed_method_name?(method_name, prefix); end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#106 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#132 def expected_name(method_name, prefix); end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#120 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#146 def forbidden_prefixes; end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#116 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#142 def message(method_name, new_name); end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#128 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#154 def method_definition_macros(macro_name); end - # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#124 + # source://rubocop//lib/rubocop/cop/naming/predicate_name.rb#150 def predicate_prefixes; end end @@ -27846,31 +28612,31 @@ class RuboCop::Cop::Naming::RescuedExceptionsVariableName < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#96 def autocorrect(corrector, node, range, offending_name, preferred_name); end - # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#116 + # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#117 def correct_node(corrector, node, offending_name, preferred_name); end # If the exception variable is reassigned, that assignment needs to be corrected. # Further `lvar` nodes will not be corrected though since they now refer to a # different variable. # - # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#134 + # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#143 def correct_reassignment(corrector, node, offending_name, preferred_name); end - # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#159 + # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#168 def message(node); end # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#91 def offense_range(resbody); end - # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#143 + # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#152 def preferred_name(variable_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#165 + # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#174 def shadowed_variable_name?(node); end - # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#152 + # source://rubocop//lib/rubocop/cop/naming/rescued_exceptions_variable_name.rb#161 def variable_name(node); end # @return [Boolean] @@ -28723,25 +29489,20 @@ module RuboCop::Cop::PrecedingFollowingAlignment # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#95 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#93 def aligned_assignment?(range, line); end - # @return [Boolean] - # - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#91 - def aligned_char?(range, line); end - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#70 def aligned_comment_lines; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#107 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#105 def aligned_identical?(range, line); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#83 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#81 def aligned_operator?(range, line); end # @return [Boolean] @@ -28766,10 +29527,10 @@ module RuboCop::Cop::PrecedingFollowingAlignment # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#100 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#98 def aligned_with_append_operator?(range, line); end - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#111 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#109 def aligned_with_assignment(token, line_range); end # @return [Boolean] @@ -28795,7 +29556,7 @@ module RuboCop::Cop::PrecedingFollowingAlignment # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#87 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#85 def aligned_words?(range, line); end # @return [Boolean] @@ -28803,16 +29564,16 @@ module RuboCop::Cop::PrecedingFollowingAlignment # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#10 def allow_for_alignment?; end - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#129 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#127 def assignment_lines; end - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#133 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#131 def assignment_tokens; end - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#149 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#147 def relevant_assignment_lines(line_range); end - # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#176 + # source://rubocop//lib/rubocop/cop/mixin/preceding_following_alignment.rb#174 def remove_optarg_equals(asgn_tokens, processed_source); end end @@ -29443,6 +30204,7 @@ RuboCop::Cop::Security::MarshalLoad::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arr # # bad # open(something) # open("| #{something}") +# open("| foo") # URI.open(something) # # # good @@ -29452,7 +30214,6 @@ RuboCop::Cop::Security::MarshalLoad::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arr # # # good (literal strings) # open("foo.text") -# open("| foo") # URI.open("http://example.com") # # source://rubocop//lib/rubocop/cop/security/open.rb#37 @@ -29809,6 +30570,17 @@ module RuboCop::Cop::Style; end # EnforcedStyle config covers only method definitions. # Applications of visibility methods to symbols can be controlled # using AllowModifiersOnSymbols config. +# Also, the visibility of `attr*` methods can be controlled using +# AllowModifiersOnAttrs config. +# +# In Ruby 3.0, `attr*` methods now return an array of defined method names +# as symbols. So we can write the modifier and `attr*` in inline style. +# AllowModifiersOnAttrs config allows `attr*` methods to be written in +# inline style without modifying applications that have been maintained +# for a long time in group style. Furthermore, developers who are not very +# familiar with Ruby may know that the modifier applies to `def`, but they +# may not know that it also applies to `attr*` methods. It would be easier +# to understand if we could write `attr*` methods in inline style. # # @example EnforcedStyle: group (default) # # bad @@ -29860,94 +30632,128 @@ module RuboCop::Cop::Style; end # private :bar, :baz # # end +# @example AllowModifiersOnAttrs: true (default) +# # good +# class Foo +# +# public attr_reader :bar +# protected attr_writer :baz +# private attr_accessor :qux +# private attr :quux +# +# def public_method; end +# +# private # -# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#70 +# def private_method; end +# +# end +# @example AllowModifiersOnAttrs: false +# # bad +# class Foo +# +# public attr_reader :bar +# protected attr_writer :baz +# private attr_accessor :qux +# private attr :quux +# +# end +# +# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#109 class RuboCop::Cop::Style::AccessModifierDeclarations < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#91 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#135 + def access_modifier_with_attr?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#130 def access_modifier_with_symbol?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#95 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#140 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#145 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#195 def access_modifier_is_inlined?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#149 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#199 def access_modifier_is_not_inlined?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#127 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#177 + def allow_modifiers_on_attrs?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#173 def allow_modifiers_on_symbols?(node); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#112 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#158 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#219 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#269 def def_source(node, def_node); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#180 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#230 def find_argument_less_modifier_node(node); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#169 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#219 def find_corresponding_def_node(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#137 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#187 def group_style?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#141 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#191 def inline_style?; end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#211 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#261 def insert_inline_modifier(corrector, node, modifier_name); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#159 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#209 def message(range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#131 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#181 def offense?(node); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#215 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#265 def remove_node(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#194 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#244 def replace_def(corrector, node, def_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#153 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#203 def right_siblings_same_inline_method?(node); end - # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#188 + # source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#238 def select_grouped_def_nodes(node); end end -# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#88 +# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#127 RuboCop::Cop::Style::AccessModifierDeclarations::ALLOWED_NODE_TYPES = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#76 +# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#115 RuboCop::Cop::Style::AccessModifierDeclarations::GROUP_STYLE_MESSAGE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#81 +# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#120 RuboCop::Cop::Style::AccessModifierDeclarations::INLINE_STYLE_MESSAGE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#86 +# source://rubocop//lib/rubocop/cop/style/access_modifier_declarations.rb#125 RuboCop::Cop::Style::AccessModifierDeclarations::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for grouping of accessors in `class` and `module` bodies. @@ -30091,10 +30897,7 @@ class RuboCop::Cop::Style::Alias < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/alias.rb#150 - def identifier(param0 = T.unsafe(nil)); end - - # source://rubocop//lib/rubocop/cop/style/alias.rb#51 + # source://rubocop//lib/rubocop/cop/style/alias.rb#52 def on_alias(node); end # source://rubocop//lib/rubocop/cop/style/alias.rb#41 @@ -30102,44 +30905,47 @@ class RuboCop::Cop::Style::Alias < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/alias.rb#85 + # source://rubocop//lib/rubocop/cop/style/alias.rb#86 def add_offense_for_args(node, &block); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/alias.rb#75 + # source://rubocop//lib/rubocop/cop/style/alias.rb#76 def alias_keyword_possible?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/alias.rb#79 + # source://rubocop//lib/rubocop/cop/style/alias.rb#80 def alias_method_possible?(node); end - # source://rubocop//lib/rubocop/cop/style/alias.rb#65 + # source://rubocop//lib/rubocop/cop/style/alias.rb#66 def autocorrect(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/alias.rb#124 + # source://rubocop//lib/rubocop/cop/style/alias.rb#125 def bareword?(sym_node); end - # source://rubocop//lib/rubocop/cop/style/alias.rb#128 + # source://rubocop//lib/rubocop/cop/style/alias.rb#129 def correct_alias_method_to_alias(corrector, send_node); end - # source://rubocop//lib/rubocop/cop/style/alias.rb#135 + # source://rubocop//lib/rubocop/cop/style/alias.rb#136 def correct_alias_to_alias_method(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/alias.rb#144 + # source://rubocop//lib/rubocop/cop/style/alias.rb#143 def correct_alias_with_symbol_args(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/alias.rb#113 + # source://rubocop//lib/rubocop/cop/style/alias.rb#148 + def identifier(node); end + + # source://rubocop//lib/rubocop/cop/style/alias.rb#114 def lexical_scope_type(node); end # In this expression, will `self` be the same as the innermost enclosing # class or module block (:lexical)? Or will it be something else # (:dynamic)? If we're in an instance_eval block, return that. # - # source://rubocop//lib/rubocop/cop/style/alias.rb#96 + # source://rubocop//lib/rubocop/cop/style/alias.rb#97 def scope_type(node); end end @@ -30263,6 +31069,29 @@ RuboCop::Cop::Style::AndOr::MSG = T.let(T.unsafe(nil), String) # This cop identifies places where `do_something(*args, &block)` # can be replaced by `do_something(...)`. # +# In Ruby 3.1, anonymous block forwarding has been added. +# +# This cop identifies places where `do_something(&block)` can be replaced +# by `do_something(&)`; if desired, this functionality can be disabled +# by setting `UseAnonymousForwarding: false`. +# +# In Ruby 3.2, anonymous args/kwargs forwarding has been added. +# +# This cop also identifies places where `use_args(*args)`/`use_kwargs(**kwargs)` can be +# replaced by `use_args(*)`/`use_kwargs(**)`; if desired, this functionality can be disabled +# by setting `UseAnonymousForwarding: false`. +# +# And this cop has `RedundantRestArgumentNames`, `RedundantKeywordRestArgumentNames`, +# and `RedundantBlockArgumentNames` options. This configuration is a list of redundant names +# that are sufficient for anonymizing meaningless naming. +# +# Meaningless names that are commonly used can be anonymized by default: +# e.g., `*args`, `**options`, `&block`, and so on. +# +# Names not on this list are likely to be meaningful and are allowed by default. +# +# This cop handles not only method forwarding but also forwarding to `super`. +# # @example # # bad # def foo(*args, &block) @@ -30278,7 +31107,28 @@ RuboCop::Cop::Style::AndOr::MSG = T.let(T.unsafe(nil), String) # def foo(...) # bar(...) # end -# @example AllowOnlyRestArgument: true (default) +# @example UseAnonymousForwarding: true (default, only relevant for Ruby >= 3.2) +# # bad +# def foo(*args, **kwargs, &block) +# args_only(*args) +# kwargs_only(**kwargs) +# block_only(&block) +# end +# +# # good +# def foo(*, **, &) +# args_only(*) +# kwargs_only(**) +# block_only(&) +# end +# @example UseAnonymousForwarding: false (only relevant for Ruby >= 3.2) +# # good +# def foo(*args, **kwargs, &block) +# args_only(*args) +# kwargs_only(**kwargs) +# block_only(&block) +# end +# @example AllowOnlyRestArgument: true (default, only relevant for Ruby < 3.2) # # good # def foo(*args) # bar(*args) @@ -30287,7 +31137,7 @@ RuboCop::Cop::Style::AndOr::MSG = T.let(T.unsafe(nil), String) # def foo(**kwargs) # bar(**kwargs) # end -# @example AllowOnlyRestArgument: false +# @example AllowOnlyRestArgument: false (only relevant for Ruby < 3.2) # # bad # # The following code can replace the arguments with `...`, # # but it will change the behavior. Because `...` forwards block also. @@ -30298,60 +31148,255 @@ RuboCop::Cop::Style::AndOr::MSG = T.let(T.unsafe(nil), String) # def foo(**kwargs) # bar(**kwargs) # end +# @example RedundantRestArgumentNames: ['args', 'arguments'] (default) +# # bad +# def foo(*args) +# bar(*args) +# end +# +# # good +# def foo(*) +# bar(*) +# end +# @example RedundantKeywordRestArgumentNames: ['kwargs', 'options', 'opts'] (default) +# # bad +# def foo(**kwargs) +# bar(**kwargs) +# end +# +# # good +# def foo(**) +# bar(**) +# end +# @example RedundantBlockArgumentNames: ['blk', 'block', 'proc'] (default) +# # bad - But it is good with `EnforcedStyle: explicit` set for `Naming/BlockForwarding`. +# def foo(&block) +# bar(&block) +# end +# +# # good +# def foo(&) +# bar(&) +# end # -# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#49 +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#127 class RuboCop::Cop::Style::ArgumentsForwarding < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#72 - def forwarding_method_arguments?(param0 = T.unsafe(nil), param1, param2, param3); end - - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#84 + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#146 def on_def(node); end - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#84 + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#146 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#64 - def only_rest_arguments?(param0 = T.unsafe(nil), param1); end + private - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#59 - def use_rest_arguments?(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#187 + def add_forward_all_offenses(node, send_classifications, forwardable_args); end - private + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#353 + def add_parens_if_missing(node, corrector); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#214 + def add_post_ruby_32_offenses(def_node, send_classifications, forwardable_args); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#116 - def all_lvars_as_forwarding_method_arguments?(def_node, forwarding_method); end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#345 + def allow_only_rest_arguments?; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#337 + def arguments_range(node, first_node); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#265 + def classification_and_forwards(def_node, send_node, referenced_lvars, forwardable_args); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#250 + def classify_send_nodes(def_node, send_nodes, referenced_lvars, forwardable_args); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#149 - def allow_only_rest_arguments?; end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#497 + def explicit_block_name?; end - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#143 - def arguments_range(node); end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#170 + def extract_forwardable_args(args); end - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#103 - def extract_argument_names_from(args); end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#240 + def non_splat_or_block_pass_lvar_references(body); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#110 - def forwarding_method?(node, rest_arg, kwargs, block_arg); end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#182 + def only_forwards_all?(send_classifications); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#294 + def outside_block?(node); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#174 + def redundant_forwardable_named_args(restarg, kwrestarg, blockarg); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#284 + def redundant_named_arg(arg, config_name, keyword); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#327 + def register_forward_all_offense(def_or_send, send_or_arguments, rest_or_splat); end - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#125 - def register_offense_to_forwarding_method_arguments(forwarding_method); end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#300 + def register_forward_args_offense(def_arguments_or_send, rest_arg_or_splat); end - # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#134 - def register_offense_to_method_definition_arguments(method_definition); end + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#316 + def register_forward_block_arg_offense(add_parens, def_arguments_or_send, block_arg); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#308 + def register_forward_kwargs_offense(add_parens, def_arguments_or_send, kwrest_arg_or_splat); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#349 + def use_anonymous_forwarding?; end + + class << self + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#142 + def autocorrect_incompatible_with; end + end end -# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#56 -RuboCop::Cop::Style::ArgumentsForwarding::MSG = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#135 +RuboCop::Cop::Style::ArgumentsForwarding::ADDITIONAL_ARG_TYPES = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#138 +RuboCop::Cop::Style::ArgumentsForwarding::ARGS_MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#140 +RuboCop::Cop::Style::ArgumentsForwarding::BLOCK_MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#134 +RuboCop::Cop::Style::ArgumentsForwarding::FORWARDING_LVAR_TYPES = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#137 +RuboCop::Cop::Style::ArgumentsForwarding::FORWARDING_MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#139 +RuboCop::Cop::Style::ArgumentsForwarding::KWARGS_MSG = T.let(T.unsafe(nil), String) + +# Classifies send nodes for possible rest/kwrest/all (including block) forwarding. +# +# source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#360 +class RuboCop::Cop::Style::ArgumentsForwarding::SendNodeClassifier + extend ::RuboCop::AST::NodePattern::Macros + + # @return [SendNodeClassifier] a new instance of SendNodeClassifier + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#372 + def initialize(def_node, send_node, referenced_lvars, forwardable_args, **config); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#400 + def classification; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#367 + def extract_forwarded_kwrest_arg(param0 = T.unsafe(nil), param1); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#394 + def forwarded_block_arg; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#370 + def forwarded_block_arg?(param0 = T.unsafe(nil), param1); end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#388 + def forwarded_kwrest_arg; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#382 + def forwarded_rest_arg; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#364 + def forwarded_rest_arg?(param0 = T.unsafe(nil), param1); end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#468 + def additional_kwargs?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#464 + def additional_kwargs_or_forwarded_kwargs?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#478 + def allow_offense_for_no_block?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#449 + def any_arg_referenced?; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#433 + def arguments; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#412 + def can_forward_all?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#472 + def forward_additional_kwargs?; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#429 + def forwarded_rest_and_kwrest_args; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#491 + def missing_rest_arg_or_kwrest_arg?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#482 + def no_additional_args?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#457 + def no_post_splat_args?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#425 + def offensive_block_forwarding?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#445 + def referenced_block_arg?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#441 + def referenced_kwrest_arg?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#437 + def referenced_rest_arg?; end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#421 + def ruby_32_missing_rest_or_kwest?; end + + # source://rubocop//lib/rubocop/cop/style/arguments_forwarding.rb#453 + def target_ruby_version; end +end # Enforces the use of `Array()` instead of explicit `Array` check or `[*var]`. # @@ -30391,6 +31436,46 @@ RuboCop::Cop::Style::ArrayCoercion::CHECK_MSG = T.let(T.unsafe(nil), String) # source://rubocop//lib/rubocop/cop/style/array_coercion.rb#44 RuboCop::Cop::Style::ArrayCoercion::SPLAT_MSG = T.let(T.unsafe(nil), String) +# Identifies usages of `arr[0]` and `arr[-1]` and suggests to change +# them to use `arr.first` and `arr.last` instead. +# +# The cop is disabled by default due to safety concerns. +# +# @example +# # bad +# arr[0] +# arr[-1] +# +# # good +# arr.first +# arr.last +# arr[0] = 2 +# arr[0][-2] +# +# source://rubocop//lib/rubocop/cop/style/array_first_last.rb#28 +class RuboCop::Cop::Style::ArrayFirstLast < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/array_first_last.rb#35 + def on_send(node); end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/array_first_last.rb#58 + def brace_method?(node); end + + # source://rubocop//lib/rubocop/cop/style/array_first_last.rb#53 + def innermost_braces_node(node); end +end + +# source://rubocop//lib/rubocop/cop/style/array_first_last.rb#31 +RuboCop::Cop::Style::ArrayFirstLast::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/array_first_last.rb#32 +RuboCop::Cop::Style::ArrayFirstLast::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) + # In Ruby 3.1, `Array#intersect?` has been added. # # This cop identifies places where `(array1 & array2).any?` @@ -30399,6 +31484,15 @@ RuboCop::Cop::Style::ArrayCoercion::SPLAT_MSG = T.let(T.unsafe(nil), String) # The `array1.intersect?(array2)` method is faster than # `(array1 & array2).any?` and is more readable. # +# In cases like the following, compatibility is not ensured, +# so it will not be detected when using block argument. +# +# [source,ruby] +# ---- +# ([1] & [1,2]).any? { |x| false } # => false +# [1].intersect?([1,2]) { |x| false } # => true +# ---- +# # @example # # bad # (array1 & array2).any? @@ -30420,46 +31514,46 @@ RuboCop::Cop::Style::ArrayCoercion::SPLAT_MSG = T.let(T.unsafe(nil), String) # array1.intersect?(array2) # !array1.intersect?(array2) # -# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#40 +# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#49 class RuboCop::Cop::Style::ArrayIntersect < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#56 + # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#65 def active_support_bad_intersection_check?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#70 + # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#79 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#47 + # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#56 def regular_bad_intersection_check?(param0 = T.unsafe(nil)); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#86 + # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#94 def bad_intersection_check?(node); end - # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#98 + # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#106 def message(receiver, argument, method_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#94 + # source://rubocop//lib/rubocop/cop/style/array_intersect.rb#102 def straight?(method_name); end end -# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#64 +# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#73 RuboCop::Cop::Style::ArrayIntersect::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#67 +# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#76 RuboCop::Cop::Style::ArrayIntersect::NEGATED_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#68 +# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#77 RuboCop::Cop::Style::ArrayIntersect::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#66 +# source://rubocop//lib/rubocop/cop/style/array_intersect.rb#75 RuboCop::Cop::Style::ArrayIntersect::STRAIGHT_METHODS = T.let(T.unsafe(nil), Array) # Checks for uses of "*" as a substitute for _join_. @@ -30584,28 +31678,36 @@ RuboCop::Cop::Style::Attr::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # # ... # end # -# source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#19 +# # bad +# f = Tempfile.open('temp') +# +# # good +# Tempfile.open('temp') do |f| +# # ... +# end +# +# source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#27 class RuboCop::Cop::Style::AutoResourceCleanup < ::RuboCop::Cop::Base - # source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#26 + # source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#32 + def file_open_method?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#36 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#41 + # source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#46 def cleanup?(node); end end -# source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#20 +# source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#28 RuboCop::Cop::Style::AutoResourceCleanup::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#24 +# source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#29 RuboCop::Cop::Style::AutoResourceCleanup::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/auto_resource_cleanup.rb#22 -RuboCop::Cop::Style::AutoResourceCleanup::TARGET_METHODS = T.let(T.unsafe(nil), Hash) - # Checks if usage of %() or %Q() matches configuration. # # @example EnforcedStyle: bare_percent (default) @@ -31043,7 +32145,7 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#458 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#459 def array_or_range?(node); end # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#208 @@ -31051,7 +32153,7 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#462 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#463 def begin_required?(block_node); end # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#236 @@ -31059,7 +32161,7 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#399 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#400 def braces_for_chaining_style?(node); end # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#248 @@ -31067,25 +32169,25 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#376 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#377 def braces_required_method?(method_name); end - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#380 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#381 def braces_required_methods; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#409 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#410 def braces_style?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#454 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#455 def conditional?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#413 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#414 def correction_would_break_code?(node); end # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#309 @@ -31093,12 +32195,12 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#423 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#424 def functional_block?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#419 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#420 def functional_method?(method_name); end # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#326 @@ -31106,7 +32208,7 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#384 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#385 def line_count_based_block_style?(node); end # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#218 @@ -31120,12 +32222,12 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#431 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#432 def procedural_method?(method_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#427 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#428 def procedural_oneliners_may_have_braces?; end # @return [Boolean] @@ -31149,17 +32251,17 @@ class RuboCop::Cop::Style::BlockDelimiters < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#447 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#448 def return_value_of_scope?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#435 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#436 def return_value_used?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#388 + # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#389 def semantic_block_style?(node); end # source://rubocop//lib/rubocop/cop/style/block_delimiters.rb#226 @@ -31199,27 +32301,27 @@ RuboCop::Cop::Style::BlockDelimiters::BRACES_REQUIRED_MESSAGE = T.let(T.unsafe(n # Corrector to correct conditional assignment in `case` statements. # -# source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#603 +# source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#604 class RuboCop::Cop::Style::CaseCorrector extend ::RuboCop::Cop::Style::ConditionalAssignmentHelper extend ::RuboCop::Cop::Style::ConditionalCorrectorHelper class << self - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#608 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#609 def correct(corrector, cop, node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#618 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#619 def move_assignment_inside_condition(corrector, node); end private - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#638 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#639 def extract_branches(case_node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#632 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#633 def extract_tail_branches(node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#648 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#649 def move_branch_inside_condition(corrector, branch, condition, assignment, column); end end end @@ -31583,9 +32685,12 @@ class RuboCop::Cop::Style::ClassCheck < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/class_check.rb#44 + # source://rubocop//lib/rubocop/cop/style/class_check.rb#45 def message(node); end + # source://rubocop//lib/rubocop/cop/style/class_check.rb#33 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/class_check.rb#33 def on_send(node); end end @@ -31634,53 +32739,53 @@ RuboCop::Cop::Style::ClassCheck::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # self.class.eq(other.class) && name.eq(other.name) # end # -# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#47 +# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#52 class RuboCop::Cop::Style::ClassEqualityComparison < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp include ::RuboCop::Cop::AllowedMethods include ::RuboCop::Cop::AllowedPattern extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#59 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#64 def class_comparison_candidate?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#65 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#70 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#85 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#92 def class_name(class_node, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#105 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#112 def class_name_method?(method_name); end - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#121 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#128 def offense_range(receiver_node, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#109 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#116 def require_cbase?(class_node); end - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#117 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#124 def trim_string_quotes(class_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#113 + # source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#120 def unable_to_determine_type?(class_node); end end -# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#56 +# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#61 RuboCop::Cop::Style::ClassEqualityComparison::CLASS_NAME_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#53 +# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#58 RuboCop::Cop::Style::ClassEqualityComparison::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#55 +# source://rubocop//lib/rubocop/cop/style/class_equality_comparison.rb#60 RuboCop::Cop::Style::ClassEqualityComparison::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for uses of the class/module name instead of @@ -31887,17 +32992,19 @@ RuboCop::Cop::Style::ClassVars::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # @example # # bad # array.reject(&:nil?) -# array.delete_if(&:nil?) # array.reject { |e| e.nil? } -# array.delete_if { |e| e.nil? } # array.select { |e| !e.nil? } +# array.grep_v(nil) +# array.grep_v(NilClass) # # # good # array.compact # # # bad # hash.reject!(&:nil?) +# array.delete_if(&:nil?) # hash.reject! { |k, v| v.nil? } +# array.delete_if { |e| e.nil? } # hash.select! { |k, v| !v.nil? } # # # good @@ -31906,49 +33013,55 @@ RuboCop::Cop::Style::ClassVars::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # # good # params.reject(&:nil?) # -# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#42 +# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#44 class RuboCop::Cop::Style::CollectionCompact < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedReceivers include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#82 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#85 + def grep_v_with_nil?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#89 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#89 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#62 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#64 def reject_method?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#55 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#57 def reject_method_with_block_pass?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#72 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#74 def select_method?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#119 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#129 def good_method_name(node); end - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#97 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#106 def offense_range(node); end - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#127 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#137 def range(begin_pos_node, end_pos_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#113 + # source://rubocop//lib/rubocop/cop/style/collection_compact.rb#123 def to_enum_method?(node); end end -# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#48 +# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#50 RuboCop::Cop::Style::CollectionCompact::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#49 +# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#51 RuboCop::Cop::Style::CollectionCompact::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#50 +# source://rubocop//lib/rubocop/cop/style/collection_compact.rb#52 RuboCop::Cop::Style::CollectionCompact::TO_ENUM_METHODS = T.let(T.unsafe(nil), Array) # Enforces the use of consistent method names @@ -31968,6 +33081,7 @@ RuboCop::Cop::Style::CollectionCompact::TO_ENUM_METHODS = T.let(T.unsafe(nil), A # # bad # items.collect # items.collect! +# items.collect_concat # items.inject # items.detect # items.find_all @@ -31976,46 +33090,47 @@ RuboCop::Cop::Style::CollectionCompact::TO_ENUM_METHODS = T.let(T.unsafe(nil), A # # good # items.map # items.map! +# items.flat_map # items.reduce # items.find # items.select # items.include? # -# source://rubocop//lib/rubocop/cop/style/collection_methods.rb#41 +# source://rubocop//lib/rubocop/cop/style/collection_methods.rb#43 class RuboCop::Cop::Style::CollectionMethods < ::RuboCop::Cop::Base include ::RuboCop::Cop::MethodPreference extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#47 + # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#49 def on_block(node); end - # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#47 + # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#49 def on_numblock(node); end - # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#53 + # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#55 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#61 + # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#63 def check_method_node(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#70 + # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#72 def implicit_block?(node); end - # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#78 + # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#80 def message(node); end # Some enumerable methods accept a bare symbol (ie. _not_ Symbol#to_proc) instead # of a block. # - # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#84 + # source://rubocop//lib/rubocop/cop/style/collection_methods.rb#86 def methods_accepting_symbol; end end -# source://rubocop//lib/rubocop/cop/style/collection_methods.rb#45 +# source://rubocop//lib/rubocop/cop/style/collection_methods.rb#47 RuboCop::Cop::Style::CollectionMethods::MSG = T.let(T.unsafe(nil), String) # Checks for methods invoked via the `::` operator instead @@ -32129,31 +33244,33 @@ RuboCop::Cop::Style::ColonMethodDefinition::MSG = T.let(T.unsafe(nil), String) # # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#59 class RuboCop::Cop::Style::CombinableLoops < ::RuboCop::Cop::Base - include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#66 + # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#64 def on_block(node); end - # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#78 + # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#77 def on_for(node); end - # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#66 + # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#64 def on_numblock(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#89 + # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#88 def collection_looping_method?(node); end # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#105 def combine_with_left_sibling(corrector, node); end + # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#112 + def correct_end_of_block(corrector, node); end + # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#94 + # source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#93 def same_collection_looping_block?(node, sibling); end # @return [Boolean] @@ -32162,7 +33279,7 @@ class RuboCop::Cop::Style::CombinableLoops < ::RuboCop::Cop::Base def same_collection_looping_for?(node, sibling); end end -# source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#64 +# source://rubocop//lib/rubocop/cop/style/combinable_loops.rb#62 RuboCop::Cop::Style::CombinableLoops::MSG = T.let(T.unsafe(nil), String) # Enforces using `` or %x around command literals. @@ -32440,44 +33557,44 @@ RuboCop::Cop::Style::CommentAnnotation::MSG_SPACE_STYLE = T.let(T.unsafe(nil), S # y # end # -# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#43 +# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#45 class RuboCop::Cop::Style::CommentedKeyword < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#57 + # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#60 def on_new_investigation; end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#80 + # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#83 def offensive?(comment); end - # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#67 + # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#70 def register_offense(comment, matched_keyword); end - # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#86 + # source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#89 def source_line(comment); end end -# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#52 +# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#54 RuboCop::Cop::Style::CommentedKeyword::ALLOWED_COMMENTS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#53 +# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#55 RuboCop::Cop::Style::CommentedKeyword::ALLOWED_COMMENT_REGEXES = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#49 +# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#51 RuboCop::Cop::Style::CommentedKeyword::KEYWORDS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#50 +# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#52 RuboCop::Cop::Style::CommentedKeyword::KEYWORD_REGEXES = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#47 +# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#49 RuboCop::Cop::Style::CommentedKeyword::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#55 +# source://rubocop//lib/rubocop/cop/style/commented_keyword.rb#58 RuboCop::Cop::Style::CommentedKeyword::REGEXP = T.let(T.unsafe(nil), Regexp) # Enforces the use of `Comparable#clamp` instead of comparison by minimum and maximum. @@ -32566,20 +33683,23 @@ RuboCop::Cop::Style::ComparableClamp::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Ar class RuboCop::Cop::Style::ConcatArrayLiterals < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector + # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#34 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#34 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#69 + # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#70 def offense_range(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#86 + # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#87 def percent_literals_includes_only_basic_literals?(node); end - # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#73 + # source://rubocop//lib/rubocop/cop/style/concat_array_literals.rb#74 def preferred_method(node); end end @@ -32593,8 +33713,8 @@ RuboCop::Cop::Style::ConcatArrayLiterals::MSG_FOR_PERCENT_LITERALS = T.let(T.uns RuboCop::Cop::Style::ConcatArrayLiterals::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Check for `if` and `case` statements where each branch is used for -# assignment to the same variable when using the return of the -# condition can be used instead. +# both the assignment and comparison of the same variable +# when using the return of the condition can be used instead. # # @example EnforcedStyle: assign_to_condition (default) # # bad @@ -32932,22 +34052,22 @@ RuboCop::Cop::Style::ConditionalAssignmentHelper::KEYWORD = T.let(T.unsafe(nil), # # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#440 module RuboCop::Cop::Style::ConditionalCorrectorHelper - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#459 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#461 def assignment(node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#489 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#490 def correct_branches(corrector, branches); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#466 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#467 def correct_if_branches(corrector, cop, node); end # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#441 def remove_whitespace_in_branches(corrector, branch, condition, column); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#476 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#477 def replace_branch_assignment(corrector, branch); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#452 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#454 def white_space_range(node, column); end end @@ -33042,36 +34162,36 @@ class RuboCop::Cop::Style::Copyright < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/copyright.rb#47 + # source://rubocop//lib/rubocop/cop/style/copyright.rb#45 + def autocorrect(corrector); end + + # source://rubocop//lib/rubocop/cop/style/copyright.rb#56 def autocorrect_notice; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/copyright.rb#78 + # source://rubocop//lib/rubocop/cop/style/copyright.rb#86 def encoding_token?(processed_source, token_index); end - # source://rubocop//lib/rubocop/cop/style/copyright.rb#64 + # source://rubocop//lib/rubocop/cop/style/copyright.rb#72 def insert_notice_before(processed_source); end - # source://rubocop//lib/rubocop/cop/style/copyright.rb#43 + # source://rubocop//lib/rubocop/cop/style/copyright.rb#52 def notice; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/copyright.rb#85 + # source://rubocop//lib/rubocop/cop/style/copyright.rb#93 def notice_found?(processed_source); end - # source://rubocop//lib/rubocop/cop/style/copyright.rb#51 - def offense_range; end - # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/copyright.rb#71 + # source://rubocop//lib/rubocop/cop/style/copyright.rb#79 def shebang_token?(processed_source, token_index); end # @raise [Warning] # - # source://rubocop//lib/rubocop/cop/style/copyright.rb#55 + # source://rubocop//lib/rubocop/cop/style/copyright.rb#60 def verify_autocorrect_notice!; end end @@ -33169,6 +34289,9 @@ class RuboCop::Cop::Style::DateTime < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/date_time.rb#61 def historic_date?(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/date_time.rb#70 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/date_time.rb#70 def on_send(node); end @@ -33177,12 +34300,12 @@ class RuboCop::Cop::Style::DateTime < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/date_time.rb#85 + # source://rubocop//lib/rubocop/cop/style/date_time.rb#86 def autocorrect(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/date_time.rb#81 + # source://rubocop//lib/rubocop/cop/style/date_time.rb#82 def disallow_coercion?; end end @@ -33216,7 +34339,6 @@ RuboCop::Cop::Style::DateTime::COERCION_MSG = T.let(T.unsafe(nil), String) # # # good (without parentheses it's a syntax error) # def foo() do_something end -# @example # # # bad # def Baz.foo() @@ -33228,18 +34350,18 @@ RuboCop::Cop::Style::DateTime::COERCION_MSG = T.let(T.unsafe(nil), String) # do_something # end # -# source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#42 +# source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#40 class RuboCop::Cop::Style::DefWithParentheses < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#47 + # source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#45 def on_def(node); end - # source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#47 + # source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#45 def on_defs(node); end end -# source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#45 +# source://rubocop//lib/rubocop/cop/style/def_with_parentheses.rb#43 RuboCop::Cop::Style::DefWithParentheses::MSG = T.let(T.unsafe(nil), String) # Checks for places where the `#\_\_dir\_\_` method can replace more @@ -33731,34 +34853,52 @@ RuboCop::Cop::Style::Documentation::MSG = T.let(T.unsafe(nil), String) # def do_something # end # end +# @example AllowedMethods: ['method_missing', 'respond_to_missing?'] +# +# # good +# class Foo +# def method_missing(name, *args) +# end +# +# def respond_to_missing?(symbol, include_private) +# end +# end # -# source://rubocop//lib/rubocop/cop/style/documentation_method.rb#98 +# source://rubocop//lib/rubocop/cop/style/documentation_method.rb#109 class RuboCop::Cop::Style::DocumentationMethod < ::RuboCop::Cop::Base include ::RuboCop::Cop::DocumentationComment include ::RuboCop::Cop::VisibilityHelp include ::RuboCop::Cop::DefNode - # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#105 + # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#116 def modifier_node?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#109 + # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#120 def on_def(node); end - # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#109 + # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#120 def on_defs(node); end private - # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#119 + # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#146 + def allowed_methods; end + + # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#130 def check(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#126 + # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#142 + def method_allowed?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/documentation_method.rb#138 def require_for_non_public_methods?; end end -# source://rubocop//lib/rubocop/cop/style/documentation_method.rb#102 +# source://rubocop//lib/rubocop/cop/style/documentation_method.rb#113 RuboCop::Cop::Style::DocumentationMethod::MSG = T.let(T.unsafe(nil), String) # Detects double disable comments on one line. This is mostly to catch @@ -33898,38 +35038,38 @@ RuboCop::Cop::Style::DoubleNegation::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arr # # # good # 5.times { } -# @example +# # # bad # (0...10).each {} # # # good # 10.times {} # -# source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#25 +# source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#24 class RuboCop::Cop::Style::EachForSimpleLoop < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#53 + # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#52 def each_range(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#65 + # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#64 def each_range_with_zero_origin?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#77 + # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#76 def each_range_without_block_argument?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#30 + # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#29 def on_block(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#48 + # source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#45 def offending?(node); end end -# source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#28 +# source://rubocop//lib/rubocop/cop/style/each_for_simple_loop.rb#27 RuboCop::Cop::Style::EachForSimpleLoop::MSG = T.let(T.unsafe(nil), String) # Looks for inject / reduce calls where the passed in object is @@ -34082,30 +35222,33 @@ class RuboCop::Cop::Style::EmptyCaseCondition < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#44 + # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#46 def on_case(case_node); end private - # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#58 + # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#63 def autocorrect(corrector, case_node); end - # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#65 + # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#70 def correct_case_when(corrector, case_node, when_nodes); end - # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#77 + # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#82 def correct_when_conditions(corrector, when_nodes); end - # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#92 + # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#97 def keep_first_when_comment(case_range, corrector); end - # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#102 + # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#107 def replace_then_with_line_break(corrector, conditions, when_node); end end # source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#42 RuboCop::Cop::Style::EmptyCaseCondition::MSG = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/style/empty_case_condition.rb#43 +RuboCop::Cop::Style::EmptyCaseCondition::NOT_SUPPORTED_PARENT_TYPES = T.let(T.unsafe(nil), Array) + # Checks for empty else-clauses, possibly including comments and/or an # explicit `nil` depending on the EnforcedStyle. # @@ -34738,9 +35881,18 @@ RuboCop::Cop::Style::EnvHome::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # will not attempt to automatically add a binding, or add filename and # line values. # -# This cop works only when a string literal is given as a code string. +# NOTE: This cop works only when a string literal is given as a code string. # No offense is reported if a string variable is given as below: # +# [source,ruby] +# ---- +# code = <<-RUBY +# def do_something +# end +# RUBY +# eval code # not checked. +# ---- +# # @example # # bad # eval <<-RUBY @@ -34765,107 +35917,93 @@ RuboCop::Cop::Style::EnvHome::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # def do_something # end # RUBY -# @example -# # not checked -# code = <<-RUBY -# def do_something -# end -# RUBY -# eval code # -# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#56 +# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#57 class RuboCop::Cop::Style::EvalWithLocation < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#74 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#75 def line_with_offset?(param0 = T.unsafe(nil), param1, param2); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#81 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#82 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#69 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#70 def valid_eval_receiver?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#195 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#187 def add_offense_for_different_line(node, line_node, line_diff); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#142 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#132 def add_offense_for_incorrect_line(method_name, line_node, sign, line_diff); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#210 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#202 def add_offense_for_missing_line(node, code); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#217 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#209 def add_offense_for_missing_location(node, code); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#189 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#181 def add_offense_for_same_line(node, line_node); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#154 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#144 def check_file(node, file_node); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#167 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#157 def check_line(node, code); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#95 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#96 def check_location(node, code); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#202 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#194 def expected_line(sign, line_diff); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#122 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#123 def file_and_line(node); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#177 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#169 def line_difference(line_node, code); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#229 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#221 def missing_line(node, code); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#109 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#110 def register_offense(node, &block); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#114 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#115 def special_file_keyword?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#118 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#119 def special_line_keyword?(node); end - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#181 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#173 def string_first_line(str_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#127 + # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#128 def with_binding?(node); end - - # FIXME: It's a Style/ConditionalAssignment's false positive. - # - # @return [Boolean] - # - # source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#133 - def with_lineno?(node); end end -# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#59 +# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#60 RuboCop::Cop::Style::EvalWithLocation::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#60 +# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#61 RuboCop::Cop::Style::EvalWithLocation::MSG_EVAL = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#61 +# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#62 RuboCop::Cop::Style::EvalWithLocation::MSG_INCORRECT_FILE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#63 +# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#64 RuboCop::Cop::Style::EvalWithLocation::MSG_INCORRECT_LINE = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#66 +# source://rubocop//lib/rubocop/cop/style/eval_with_location.rb#67 RuboCop::Cop::Style::EvalWithLocation::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for places where `Integer#even?` or `Integer#odd?` @@ -34929,6 +36067,9 @@ class RuboCop::Cop::Style::ExactRegexpMatch < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/exact_regexp_match.rb#32 def exact_regexp_match(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/exact_regexp_match.rb#40 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/exact_regexp_match.rb#40 def on_send(node); end @@ -34936,10 +36077,10 @@ class RuboCop::Cop::Style::ExactRegexpMatch < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/exact_regexp_match.rb#55 + # source://rubocop//lib/rubocop/cop/style/exact_regexp_match.rb#57 def exact_match_pattern?(parsed_regexp); end - # source://rubocop//lib/rubocop/cop/style/exact_regexp_match.rb#62 + # source://rubocop//lib/rubocop/cop/style/exact_regexp_match.rb#64 def new_method(node); end end @@ -35371,8 +36512,7 @@ RuboCop::Cop::Style::FileEmpty::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Favor `File.(bin)read` convenience methods. # # @example -# ## text mode -# # bad +# # bad - text mode # File.open(filename).read # File.open(filename, &:read) # File.open(filename) { |f| f.read } @@ -35387,9 +36527,8 @@ RuboCop::Cop::Style::FileEmpty::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # # # good # File.read(filename) -# @example -# ## binary mode -# # bad +# +# # bad - binary mode # File.open(filename, 'rb').read # File.open(filename, 'rb', &:read) # File.open(filename, 'rb') do |f| @@ -35399,49 +36538,49 @@ RuboCop::Cop::Style::FileEmpty::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # # good # File.binread(filename) # -# source://rubocop//lib/rubocop/cop/style/file_read.rb#38 +# source://rubocop//lib/rubocop/cop/style/file_read.rb#35 class RuboCop::Cop::Style::FileRead < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/file_read.rb#65 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#62 def block_read?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/file_read.rb#49 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#46 def file_open?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/file_read.rb#69 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#66 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/file_read.rb#60 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#57 def send_read?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/style/file_read.rb#84 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#81 def evidence(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/file_read.rb#100 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#97 def file_open_read?(node); end - # source://rubocop//lib/rubocop/cop/style/file_read.rb#106 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#103 def read_method(mode); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/file_read.rb#92 + # source://rubocop//lib/rubocop/cop/style/file_read.rb#89 def read_node?(node, block_pass); end end -# source://rubocop//lib/rubocop/cop/style/file_read.rb#42 +# source://rubocop//lib/rubocop/cop/style/file_read.rb#39 RuboCop::Cop::Style::FileRead::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/file_read.rb#46 +# source://rubocop//lib/rubocop/cop/style/file_read.rb#43 RuboCop::Cop::Style::FileRead::READ_FILE_START_TO_FINISH_MODES = T.let(T.unsafe(nil), Set) -# source://rubocop//lib/rubocop/cop/style/file_read.rb#44 +# source://rubocop//lib/rubocop/cop/style/file_read.rb#41 RuboCop::Cop::Style::FileRead::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Favor `File.(bin)write` convenience methods. @@ -35458,8 +36597,7 @@ RuboCop::Cop::Style::FileRead::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # ---- # # @example -# ## text mode -# # bad +# # bad - text mode # File.open(filename, 'w').write(content) # File.open(filename, 'w') do |f| # f.write(content) @@ -35467,9 +36605,8 @@ RuboCop::Cop::Style::FileRead::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # # # good # File.write(filename, content) -# @example -# ## binary mode -# # bad +# +# # bad - binary mode # File.open(filename, 'wb').write(content) # File.open(filename, 'wb') do |f| # f.write(content) @@ -35478,24 +36615,24 @@ RuboCop::Cop::Style::FileRead::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # # good # File.binwrite(filename, content) # -# source://rubocop//lib/rubocop/cop/style/file_write.rb#41 +# source://rubocop//lib/rubocop/cop/style/file_write.rb#38 class RuboCop::Cop::Style::FileWrite < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/file_write.rb#68 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#65 def block_write?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/file_write.rb#85 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#82 def evidence(node); end - # source://rubocop//lib/rubocop/cop/style/file_write.rb#52 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#49 def file_open?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/file_write.rb#72 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#69 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/file_write.rb#63 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#60 def send_write?(param0 = T.unsafe(nil)); end private @@ -35503,31 +36640,31 @@ class RuboCop::Cop::Style::FileWrite < ::RuboCop::Cop::Base # @return [Boolean] # @yield [content] # - # source://rubocop//lib/rubocop/cop/style/file_write.rb#95 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#92 def file_open_write?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/file_write.rb#123 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#120 def heredoc?(write_node); end - # source://rubocop//lib/rubocop/cop/style/file_write.rb#128 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#125 def heredoc_range(first_argument); end - # source://rubocop//lib/rubocop/cop/style/file_write.rb#108 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#105 def replacement(mode, filename, content, write_node); end - # source://rubocop//lib/rubocop/cop/style/file_write.rb#104 + # source://rubocop//lib/rubocop/cop/style/file_write.rb#101 def write_method(mode); end end -# source://rubocop//lib/rubocop/cop/style/file_write.rb#45 +# source://rubocop//lib/rubocop/cop/style/file_write.rb#42 RuboCop::Cop::Style::FileWrite::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/file_write.rb#47 +# source://rubocop//lib/rubocop/cop/style/file_write.rb#44 RuboCop::Cop::Style::FileWrite::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Set) -# source://rubocop//lib/rubocop/cop/style/file_write.rb#49 +# source://rubocop//lib/rubocop/cop/style/file_write.rb#46 RuboCop::Cop::Style::FileWrite::TRUNCATING_WRITE_MODES = T.let(T.unsafe(nil), Set) # Checks for division with integers coerced to floats. @@ -35666,7 +36803,7 @@ class RuboCop::Cop::Style::For < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/for.rb#82 + # source://rubocop//lib/rubocop/cop/style/for.rb#84 def suspect_enumerable?(node); end end @@ -35680,74 +36817,96 @@ RuboCop::Cop::Style::For::PREFER_EACH = T.let(T.unsafe(nil), String) RuboCop::Cop::Style::For::PREFER_FOR = T.let(T.unsafe(nil), String) # Enforces the use of a single string formatting utility. -# Valid options include Kernel#format, Kernel#sprintf and String#%. +# Valid options include `Kernel#format`, `Kernel#sprintf`, and `String#%`. # -# The detection of String#% cannot be implemented in a reliable +# The detection of `String#%` cannot be implemented in a reliable # manner for all cases, so only two scenarios are considered - # if the first argument is a string literal and if the second # argument is an array literal. # +# Autocorrection will be applied when using argument is a literal or known built-in conversion +# methods such as `to_d`, `to_f`, `to_h`, `to_i`, `to_r`, `to_s`, and `to_sym` on variables, +# provided that their return value is not an array. For example, when using `to_s`, +# `'%s' % [1, 2, 3].to_s` can be autocorrected without any incompatibility: +# +# [source,ruby] +# ---- +# '%s' % [1, 2, 3] #=> '1' +# format('%s', [1, 2, 3]) #=> '[1, 2, 3]' +# '%s' % [1, 2, 3].to_s #=> '[1, 2, 3]' +# ---- +# # @example EnforcedStyle: format (default) # # bad -# puts sprintf('%10s', 'hoge') -# puts '%10s' % 'hoge' +# puts sprintf('%10s', 'foo') +# puts '%10s' % 'foo' # # # good -# puts format('%10s', 'hoge') +# puts format('%10s', 'foo') # @example EnforcedStyle: sprintf # # bad -# puts format('%10s', 'hoge') -# puts '%10s' % 'hoge' +# puts format('%10s', 'foo') +# puts '%10s' % 'foo' # # # good -# puts sprintf('%10s', 'hoge') +# puts sprintf('%10s', 'foo') # @example EnforcedStyle: percent # # bad -# puts format('%10s', 'hoge') -# puts sprintf('%10s', 'hoge') +# puts format('%10s', 'foo') +# puts sprintf('%10s', 'foo') # # # good -# puts '%10s' % 'hoge' +# puts '%10s' % 'foo' # -# source://rubocop//lib/rubocop/cop/style/format_string.rb#38 +# source://rubocop//lib/rubocop/cop/style/format_string.rb#50 class RuboCop::Cop::Style::FormatString < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/format_string.rb#46 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#61 def formatter(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/format_string.rb#59 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#74 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/format_string.rb#55 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#70 def variable_argument?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/style/format_string.rb#81 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#102 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/format_string.rb#97 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#118 def autocorrect_from_percent(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/format_string.rb#111 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#132 def autocorrect_to_percent(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/format_string.rb#124 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/format_string.rb#88 + def autocorrectable?(node); end + + # source://rubocop//lib/rubocop/cop/style/format_string.rb#145 def format_single_parameter(arg); end - # source://rubocop//lib/rubocop/cop/style/format_string.rb#73 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#94 def message(detected_style); end - # source://rubocop//lib/rubocop/cop/style/format_string.rb#77 + # source://rubocop//lib/rubocop/cop/style/format_string.rb#98 def method_name(style_name); end end -# source://rubocop//lib/rubocop/cop/style/format_string.rb#42 +# Known conversion methods whose return value is not an array. +# +# source://rubocop//lib/rubocop/cop/style/format_string.rb#58 +RuboCop::Cop::Style::FormatString::AUTOCORRECTABLE_METHODS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/format_string.rb#54 RuboCop::Cop::Style::FormatString::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/format_string.rb#43 +# source://rubocop//lib/rubocop/cop/style/format_string.rb#55 RuboCop::Cop::Style::FormatString::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Use a consistent style for named format string tokens. @@ -35973,10 +37132,10 @@ class RuboCop::Cop::Style::FrozenStringLiteralComment < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#176 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#178 def disabled_offense(processed_source); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#188 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#190 def enable_comment(corrector); end # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#120 @@ -35988,34 +37147,34 @@ class RuboCop::Cop::Style::FrozenStringLiteralComment < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#114 def ensure_no_comment(processed_source); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#212 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#214 def following_comment; end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#150 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#152 def frozen_string_literal_comment(processed_source); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#194 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#196 def insert_comment(corrector); end # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#137 def last_special_comment(processed_source); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#204 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#206 def line_range(line); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#156 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#158 def missing_offense(processed_source); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#162 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#164 def missing_true_offense(processed_source); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#208 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#210 def preceding_comment; end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#184 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#186 def remove_comment(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#168 + # source://rubocop//lib/rubocop/cop/style/frozen_string_literal_comment.rb#170 def unnecessary_comment_offense(processed_source); end end @@ -36070,11 +37229,16 @@ class RuboCop::Cop::Style::GlobalStdStream < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/global_std_stream.rb#64 + # source://rubocop//lib/rubocop/cop/style/global_std_stream.rb#70 def gvar_name(const_name); end - # source://rubocop//lib/rubocop/cop/style/global_std_stream.rb#60 + # source://rubocop//lib/rubocop/cop/style/global_std_stream.rb#62 def message(const_name); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/global_std_stream.rb#66 + def namespaced?(node); end end # source://rubocop//lib/rubocop/cop/style/global_std_stream.rb#37 @@ -36180,6 +37344,25 @@ RuboCop::Cop::Style::GlobalVars::MSG = T.let(T.unsafe(nil), String) # # good # foo || raise('exception') if something # ok +# +# # bad +# define_method(:test) do +# if something +# work +# end +# end +# +# # good +# define_method(:test) do +# return unless something +# +# work +# end +# +# # also good +# define_method(:test) do +# work if something +# end # @example AllowConsecutiveConditionals: false (default) # # bad # def test @@ -36216,7 +37399,7 @@ RuboCop::Cop::Style::GlobalVars::MSG = T.let(T.unsafe(nil), String) # end # end # -# source://rubocop//lib/rubocop/cop/style/guard_clause.rb#95 +# source://rubocop//lib/rubocop/cop/style/guard_clause.rb#114 class RuboCop::Cop::Style::GuardClause < ::RuboCop::Cop::Base include ::RuboCop::Cop::Alignment include ::RuboCop::Cop::LineLengthHelp @@ -36225,83 +37408,89 @@ class RuboCop::Cop::Style::GuardClause < ::RuboCop::Cop::Base include ::RuboCop::Cop::StatementModifier extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#104 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#132 + def on_block(node); end + + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#123 def on_def(node); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#104 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#123 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#113 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#139 def on_if(node); end + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#132 + def on_numblock(node); end + private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#249 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#275 def accepted_form?(node, ending: T.unsafe(nil)); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#257 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#283 def accepted_if?(node, ending); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#271 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#297 def allowed_consecutive_conditionals?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#239 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#265 def and_or_guard_clause?(guard_clause); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#184 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#210 def autocorrect(corrector, node, condition, replacement, guard); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#210 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#236 def autocorrect_heredoc_argument(corrector, node, heredoc_branch, leave_branch, guard); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#133 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#159 def check_ending_body(body); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#144 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#170 def check_ending_if(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#154 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#180 def consecutive_conditionals?(parent, node); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#231 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#257 def guard_clause_source(guard_clause); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#206 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#232 def heredoc?(argument); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#222 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#248 def range_of_branch_to_remove(node, guard); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#162 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#188 def register_offense(node, scope_exiting_keyword, conditional_keyword, guard = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#267 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#293 def remove_whole_lines(corrector, range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#244 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#270 def too_long_for_single_line?(node, example); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#253 + # source://rubocop//lib/rubocop/cop/style/guard_clause.rb#279 def trivial?(node); end end -# source://rubocop//lib/rubocop/cop/style/guard_clause.rb#101 +# source://rubocop//lib/rubocop/cop/style/guard_clause.rb#120 RuboCop::Cop::Style::GuardClause::MSG = T.let(T.unsafe(nil), String) # Checks for presence or absence of braces around hash literal as a last @@ -36394,62 +37583,62 @@ end # # bad # Hash[*ary] # -# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#34 +# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#44 class RuboCop::Cop::Style::HashConversion < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#44 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#54 def hash_from_array?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#46 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#56 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#128 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#138 def allowed_splat_argument?; end - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#121 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#131 def args_to_hash(args); end - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#108 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#118 def multi_argument(node); end - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#84 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#94 def register_offense_for_hash(node, hash_argument); end - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#93 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#103 def register_offense_for_zip_method(node, zip_method); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#103 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#113 def requires_parens?(node); end - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#61 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#71 def single_argument(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#78 + # source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#88 def use_zip_method_without_argument?(first_argument); end end -# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#39 +# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#49 RuboCop::Cop::Style::HashConversion::MSG_LITERAL_HASH_ARG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#38 +# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#48 RuboCop::Cop::Style::HashConversion::MSG_LITERAL_MULTI_ARG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#40 +# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#50 RuboCop::Cop::Style::HashConversion::MSG_SPLAT = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#37 +# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#47 RuboCop::Cop::Style::HashConversion::MSG_TO_H = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#41 +# source://rubocop//lib/rubocop/cop/style/hash_conversion.rb#51 RuboCop::Cop::Style::HashConversion::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for uses of `each_key` and `each_value` Hash methods. @@ -36461,72 +37650,114 @@ RuboCop::Cop::Style::HashConversion::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arr # @example # # bad # hash.keys.each { |k| p k } -# hash.values.each { |v| p v } +# hash.each { |k, unused_value| p k } # # # good # hash.each_key { |k| p k } +# +# # bad +# hash.values.each { |v| p v } +# hash.each { |unused_key, v| p v } +# +# # good # hash.each_value { |v| p v } # @example AllowedReceivers: ['execute'] # # good # execute(sql).keys.each { |v| p v } # execute(sql).values.each { |v| p v } # -# source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#30 +# source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#36 class RuboCop::Cop::Style::HashEachMethods < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedReceivers include ::RuboCop::Cop::Lint::UnusedArgument extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#38 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#74 + def check_unused_block_args(node, key, value); end + + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#51 + def each_arguments(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#46 def kv_each(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#43 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#56 def kv_each_with_block_pass(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#47 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#60 def on_block(node); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#55 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#95 def on_block_pass(node); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#47 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#60 def on_numblock(node); end private - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#86 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#180 def check_argument(variable); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#110 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#204 def correct_args(node, corrector); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#96 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#190 def correct_implicit(node, corrector, method_name); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#101 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#195 def correct_key_value_each(node, corrector); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#82 - def format_message(method_name); end + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#176 + def format_message(method_name, current); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#103 + def handleable?(node); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#117 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#211 def kv_range(outer_node); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#63 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#133 + def message(prefer, method_name, unused_code); end + + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#139 + def register_each_args_offense(node, message, prefer, unused_range); end + + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#110 def register_kv_offense(target, method); end - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#72 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#146 def register_kv_with_block_pass_offense(node, target, method); end + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#167 + def root_receiver(node); end + # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#92 + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#121 + def unused_block_arg_exist?(node, block_arg); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#157 + def use_array_converter_method_as_preceding?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#186 def used?(arg); end end -# source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#35 +# source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#43 +RuboCop::Cop::Style::HashEachMethods::ARRAY_CONVERTER_METHODS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#41 RuboCop::Cop::Style::HashEachMethods::MSG = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/style/hash_each_methods.rb#42 +RuboCop::Cop::Style::HashEachMethods::UNUSED_BLOCK_ARG_MSG = T.let(T.unsafe(nil), String) + # Checks for usages of `Hash#reject`, `Hash#select`, and `Hash#filter` methods # that can be replaced with `Hash#except` method. # @@ -36543,9 +37774,9 @@ RuboCop::Cop::Style::HashEachMethods::MSG = T.let(T.unsafe(nil), String) # {foo: 1, bar: 2, baz: 3}.reject {|k, v| k == :bar } # {foo: 1, bar: 2, baz: 3}.select {|k, v| k != :bar } # {foo: 1, bar: 2, baz: 3}.filter {|k, v| k != :bar } -# {foo: 1, bar: 2, baz: 3}.reject {|k, v| %i[foo bar].include?(k) } -# {foo: 1, bar: 2, baz: 3}.select {|k, v| !%i[foo bar].include?(k) } -# {foo: 1, bar: 2, baz: 3}.filter {|k, v| !%i[foo bar].include?(k) } +# {foo: 1, bar: 2, baz: 3}.reject {|k, v| %i[bar].include?(k) } +# {foo: 1, bar: 2, baz: 3}.select {|k, v| !%i[bar].include?(k) } +# {foo: 1, bar: 2, baz: 3}.filter {|k, v| !%i[bar].include?(k) } # # # good # {foo: 1, bar: 2, baz: 3}.except(:bar) @@ -36562,6 +37793,9 @@ class RuboCop::Cop::Style::HashExcept < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/hash_except.rb#44 def bad_method_with_poro?(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#75 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#75 def on_send(node); end @@ -36569,42 +37803,42 @@ class RuboCop::Cop::Style::HashExcept < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#93 - def bad_method?(block); end + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#95 + def bad_method?(method_name, block); end - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#165 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#169 def decorate_source(value); end - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#173 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#177 def except_key(node); end - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#152 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#156 def except_key_source(key); end - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#146 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#150 def extract_body_if_negated(body); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#127 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#131 def included?(negated, body); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#131 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#135 def not_included?(negated, body); end - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#182 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#186 def offense_range(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#135 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#139 def safe_to_register_offense?(block, except_key); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_except.rb#111 + # source://rubocop//lib/rubocop/cop/style/hash_except.rb#115 def semantically_except_method?(send, block); end end @@ -36693,6 +37927,8 @@ RuboCop::Cop::Style::HashLikeCase::MSG = T.let(T.unsafe(nil), String) # * never - forces use of explicit hash literal value # * either - accepts both shorthand and explicit use of hash literal value # * consistent - forces use of the 3.1 syntax only if all values can be omitted in the hash +# * either_consistent - accepts both shorthand and explicit use of hash literal value, +# but they must be consistent # # @example EnforcedStyle: ruby19 (default) # # bad @@ -36766,85 +38002,101 @@ RuboCop::Cop::Style::HashLikeCase::MSG = T.let(T.unsafe(nil), String) # # # good - can't omit `baz` # {foo: foo, bar: baz} +# @example EnforcedShorthandSyntax: either_consistent +# +# # good - `foo` and `bar` values can be omitted, but they are consistent, so it's accepted +# {foo: foo, bar: bar} # -# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#113 +# # bad - `bar` value can be omitted +# {foo:, bar: bar} +# +# # bad - mixed syntaxes +# {foo:, bar: baz} +# +# # good +# {foo:, bar:} +# +# # good - can't omit `baz` +# {foo: foo, bar: baz} +# +# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#131 class RuboCop::Cop::Style::HashSyntax < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle include ::RuboCop::Cop::HashShorthandSyntax include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#167 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#185 def alternative_style; end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#145 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#163 def hash_rockets_check(pairs); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#159 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#177 def no_mixed_keys_check(pairs); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#123 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#141 def on_hash(node); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#141 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#159 def ruby19_check(pairs); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#149 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#167 def ruby19_no_mixed_keys_check(pairs); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#198 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#217 def acceptable_19_syntax_symbol?(sym_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#252 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#274 def argument_without_space?(node); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#178 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#196 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#256 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#278 def autocorrect_hash_rockets(corrector, pair_node); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#265 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#287 def autocorrect_no_mixed_keys(corrector, pair_node); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#231 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#253 def autocorrect_ruby19(corrector, pair_node); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#216 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#238 def check(pairs, delim, msg); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#273 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#295 def force_hash_rockets?(pairs); end - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#244 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#266 def range_for_autocorrect_ruby19(pair_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#188 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#206 def sym_indices?(pairs); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#192 + # source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#210 def word_symbol_pair?(pair); end end -# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#119 +# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#137 RuboCop::Cop::Style::HashSyntax::MSG_19 = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#121 +# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#139 RuboCop::Cop::Style::HashSyntax::MSG_HASH_ROCKETS = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#120 +# source://rubocop//lib/rubocop/cop/style/hash_syntax.rb#138 RuboCop::Cop::Style::HashSyntax::MSG_NO_MIXED_KEYS = T.let(T.unsafe(nil), String) # Looks for uses of `\_.each_with_object({}) {...}`, @@ -37038,40 +38290,43 @@ class RuboCop::Cop::Style::IdenticalConditionalBranches < ::RuboCop::Cop::Base private + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#184 + def assignable_condition_value(node); end + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#140 def check_branches(node, branches); end - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#167 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#193 def check_expressions(node, expressions, insert_position); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#156 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#173 def duplicated_expressions?(node, expressions); end # `elsif` branches show up in the if node as nested `else` branches. We # need to recursively iterate over all `else` branches. # - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#204 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#233 def expand_elses(branch); end - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#219 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#248 def head(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#188 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#217 def last_child_of_parent?(node); end - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#198 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#227 def message(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#194 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#223 def single_child_branch?(branch_node); end - # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#215 + # source://rubocop//lib/rubocop/cop/style/identical_conditional_branches.rb#244 def tail(node); end end @@ -37080,24 +38335,24 @@ RuboCop::Cop::Style::IdenticalConditionalBranches::MSG = T.let(T.unsafe(nil), St # Corrector to correct conditional assignment in `if` statements. # -# source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#558 +# source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#559 class RuboCop::Cop::Style::IfCorrector extend ::RuboCop::Cop::Style::ConditionalAssignmentHelper extend ::RuboCop::Cop::Style::ConditionalCorrectorHelper class << self - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#563 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#564 def correct(corrector, cop, node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#567 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#568 def move_assignment_inside_condition(corrector, node); end private - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#581 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#582 def extract_tail_branches(node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#588 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#589 def move_branch_inside_condition(corrector, branch, condition, assignment, column); end end end @@ -37454,7 +38709,7 @@ RuboCop::Cop::Style::IfUnlessModifierOfIfUnless::MSG = T.let(T.unsafe(nil), Stri # # # good # foo == bar -# @example +# # # bad # if foo.do_something? # true @@ -37468,61 +38723,61 @@ RuboCop::Cop::Style::IfUnlessModifierOfIfUnless::MSG = T.let(T.unsafe(nil), Stri # # good # num.nonzero? ? true : false # -# source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#62 +# source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#61 class RuboCop::Cop::Style::IfWithBooleanLiteralBranches < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedMethods extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#74 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#73 def double_negative?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#70 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#69 def if_with_boolean_literal_branches?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#76 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#75 def on_if(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#134 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#135 def assume_boolean_value?(condition); end - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#114 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#113 def message(node, keyword); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#96 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#95 def multiple_elsif?(node); end - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#102 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#101 def offense_range_with_keyword(node, condition); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#151 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#152 def opposite_condition?(node); end - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#141 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#142 def replacement_condition(node, condition); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#156 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#157 def require_parentheses?(condition); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#120 + # source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#121 def return_boolean_value?(condition); end end -# source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#66 +# source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#65 RuboCop::Cop::Style::IfWithBooleanLiteralBranches::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#67 +# source://rubocop//lib/rubocop/cop/style/if_with_boolean_literal_branches.rb#66 RuboCop::Cop::Style::IfWithBooleanLiteralBranches::MSG_FOR_ELSIF = T.let(T.unsafe(nil), String) # Checks for uses of semicolon in if statements. @@ -37768,10 +39023,13 @@ class RuboCop::Cop::Style::InverseMethods < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#61 def inverse_candidate?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#91 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#92 def on_block(node); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#91 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#78 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#92 def on_numblock(node); end # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#78 @@ -37781,39 +39039,39 @@ class RuboCop::Cop::Style::InverseMethods < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#176 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#177 def camel_case_constant?(node); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#120 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#121 def correct_inverse_block(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#111 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#112 def correct_inverse_method(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#127 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#128 def correct_inverse_selector(block, corrector); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#180 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#181 def dot_range(loc); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#163 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#166 def end_parentheses(node, method_call); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#149 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#150 def inverse_blocks; end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#144 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#145 def inverse_methods; end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#190 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#191 def message(method, inverse); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#153 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#154 def negated?(node); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#157 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#162 def not_to_receiver(node, method_call); end # When comparing classes, `!(Integer < Numeric)` is not the same as @@ -37821,10 +39079,15 @@ class RuboCop::Cop::Style::InverseMethods < ::RuboCop::Cop::Base # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#171 + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#172 def possible_class_hierarchy_check?(lhs, rhs, method); end - # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#184 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#158 + def relational_comparison_with_safe_navigation?(node); end + + # source://rubocop//lib/rubocop/cop/style/inverse_methods.rb#185 def remove_end_parenthesis(corrector, node, method, method_call); end class << self @@ -37875,12 +39138,14 @@ RuboCop::Cop::Style::InverseMethods::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arr # foo unless x != y # foo unless x >= 10 # foo unless x.even? +# foo unless odd? # # # good # foo if bar # foo if x == y # foo if x < 10 # foo if x.odd? +# foo if even? # # # bad (complex condition) # foo unless x != y || x.even? @@ -37891,36 +39156,45 @@ RuboCop::Cop::Style::InverseMethods::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arr # # good (if) # foo if !condition # -# source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#51 +# source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#53 class RuboCop::Cop::Style::InvertibleUnlessCondition < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#56 + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#58 def on_if(node); end private - # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#91 + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#133 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#104 + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#146 def autocorrect_send_node(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#85 + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#90 def inheritance_check?(node); end - # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#112 + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#154 def inverse_methods; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#70 + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#75 def invertible?(node); end + + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#96 + def preferred_condition(node); end + + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#126 + def preferred_logical_condition(node); end + + # source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#104 + def preferred_send_condition(node); end end -# source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#54 +# source://rubocop//lib/rubocop/cop/style/invertible_unless_condition.rb#56 RuboCop::Cop::Style::InvertibleUnlessCondition::MSG = T.let(T.unsafe(nil), String) # Checks for hardcoded IP addresses, which can make code @@ -38140,34 +39414,34 @@ class RuboCop::Cop::Style::LambdaCall < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#28 + # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#29 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#62 + # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#67 def explicit_style?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#58 + # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#63 def implicit_style?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#46 + # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#51 def offense?(node); end - # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#50 + # source://rubocop//lib/rubocop/cop/style/lambda_call.rb#55 def prefer(node); end end -# source://rubocop//lib/rubocop/cop/style/lambda_call.rb#25 +# source://rubocop//lib/rubocop/cop/style/lambda_call.rb#26 RuboCop::Cop::Style::LambdaCall::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/lambda_call.rb#26 +# source://rubocop//lib/rubocop/cop/style/lambda_call.rb#27 RuboCop::Cop::Style::LambdaCall::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for string literal concatenation at @@ -38476,6 +39750,7 @@ RuboCop::Cop::Style::MagicCommentFormat::MSG_VALUE = T.let(T.unsafe(nil), String RuboCop::Cop::Style::MagicCommentFormat::SNAKE_SEPARATOR = T.let(T.unsafe(nil), String) # Prefer `select` or `reject` over `map { ... }.compact`. +# This cop also handles `filter_map { ... }`, similar to `map { ... }.compact`. # # @example # @@ -38483,6 +39758,9 @@ RuboCop::Cop::Style::MagicCommentFormat::SNAKE_SEPARATOR = T.let(T.unsafe(nil), # array.map { |e| some_condition? ? e : next }.compact # # # bad +# array.filter_map { |e| some_condition? ? e : next } +# +# # bad # array.map do |e| # if some_condition? # e @@ -38509,45 +39787,163 @@ RuboCop::Cop::Style::MagicCommentFormat::SNAKE_SEPARATOR = T.let(T.unsafe(nil), # # good # array.reject { |e| some_condition? } # -# source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#40 +# source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#44 class RuboCop::Cop::Style::MapCompactWithConditionalBlock < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#46 - def map_and_compact?(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#51 + def conditional_block(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#76 + def on_csend(node); end - # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#72 + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#76 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#125 - def range(node); end + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#148 + def current(node); end + + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#162 + def filter_map_range(node); end + + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#96 + def inspect(node, block_argument_node, condition_node, return_value_node, range); end + + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#158 + def map_with_compact_range(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#91 + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#114 def returns_block_argument?(block_argument_node, return_value_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#95 + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#118 def truthy_branch?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#115 + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#138 def truthy_branch_for_guard?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#105 + # source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#128 def truthy_branch_for_if?(node); end end -# source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#43 +# source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#47 RuboCop::Cop::Style::MapCompactWithConditionalBlock::MSG = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/style/map_compact_with_conditional_block.rb#48 +RuboCop::Cop::Style::MapCompactWithConditionalBlock::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) + +# Checks for usages of `each` with `<<`, `push`, or `append` which +# can be replaced by `map`. +# +# If `PreferredMethods` is configured for `map` in `Style/CollectionMethods`, +# this cop uses the specified method for replacement. +# +# NOTE: The return value of `Enumerable#each` is `self`, whereas the +# return value of `Enumerable#map` is an `Array`. They are not autocorrected +# when a return value could be used because these types differ. +# +# NOTE: It only detects when the mapping destination is a local variable +# initialized as an empty array and referred to only by the pushing operation. +# This is because, if not, it's challenging to statically guarantee that the +# mapping destination variable remains an empty array: +# +# [source,ruby] +# ---- +# ret = [] +# src.each { |e| ret << e * 2 } # `<<` method may mutate `ret` +# +# dest = [] +# src.each { |e| dest << transform(e, dest) } # `transform` method may mutate `dest` +# ---- +# +# @example +# # bad +# dest = [] +# src.each { |e| dest << e * 2 } +# dest +# +# # good +# dest = src.map { |e| e * 2 } +# +# # good - contains another operation +# dest = [] +# src.each { |e| dest << e * 2; puts e } +# dest +# +# source://rubocop//lib/rubocop/cop/style/map_into_array.rb#50 +class RuboCop::Cop::Style::MapIntoArray < ::RuboCop::Cop::Base + include ::RuboCop::Cop::RangeHelp + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#75 + def after_leaving_scope(scope, _variable_table); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#57 + def each_block_with_push?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#66 + def empty_array_asgn?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#69 + def lvar_ref?(param0 = T.unsafe(nil), param1); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#79 + def on_block(node); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#79 + def on_numblock(node); end + + private + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#155 + def correct_push_node(corrector, push_node); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#163 + def correct_return_value_handling(corrector, block, dest_var); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#108 + def dest_used_only_for_mapping?(block, dest_var, asgn); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#102 + def find_closest_assignment(block, dest_var); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#94 + def find_dest_var(block); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#127 + def new_method_name; end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#116 + def register_offense(block, dest_var, asgn); end + + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#148 + def remove_assignment(corrector, asgn); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#133 + def return_value_used?(node); end + + class << self + # source://rubocop//lib/rubocop/cop/style/map_into_array.rb#71 + def joining_forces; end + end +end + +# source://rubocop//lib/rubocop/cop/style/map_into_array.rb#54 +RuboCop::Cop::Style::MapIntoArray::MSG = T.let(T.unsafe(nil), String) + # Looks for uses of `map.to_h` or `collect.to_h` that could be # written with just `to_h` in Ruby >= 2.6. # @@ -38575,15 +39971,23 @@ class RuboCop::Cop::Style::MapToHash < ::RuboCop::Cop::Base extend ::RuboCop::Cop::TargetRubyVersion # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#41 - def map_to_h?(param0 = T.unsafe(nil)); end + def map_to_h(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#52 + def on_csend(node); end - # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#48 + # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#52 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#62 + # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#68 def autocorrect(corrector, to_h, map); end + + class << self + # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#48 + def autocorrect_incompatible_with; end + end end # source://rubocop//lib/rubocop/cop/style/map_to_hash.rb#37 @@ -38632,7 +40036,7 @@ RuboCop::Cop::Style::MapToSet::MSG = T.let(T.unsafe(nil), String) RuboCop::Cop::Style::MapToSet::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Enforces the presence (default) or absence of parentheses in -# method calls containing parameters. +# method calls containing arguments. # # In the default style (require_parentheses), macro methods are allowed. # Additional methods can be added to the `AllowedMethods` or @@ -38832,23 +40236,20 @@ class RuboCop::Cop::Style::MethodCallWithArgsParentheses < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#217 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#217 - def on_super(node); end - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#217 def on_yield(node); end private - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#226 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#225 def args_begin(node); end - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#235 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#233 def args_end(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#239 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses.rb#237 def args_parenthesized?(node); end class << self @@ -38865,100 +40266,110 @@ module RuboCop::Cop::Style::MethodCallWithArgsParentheses::OmitParentheses # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#70 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#75 def allowed_camel_case_method_call?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#158 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#179 def allowed_chained_call_with_parentheses?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#154 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#175 def allowed_multiline_call_with_parentheses?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#75 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#80 def allowed_string_interpolation_method_call?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#167 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#188 def ambiguous_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#196 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#217 def assigned_before?(node, target); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#204 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#225 def assignment_in_condition?(node); end - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#31 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#32 def autocorrect(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#141 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#156 def call_as_argument_or_chain?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#99 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#149 + def call_in_argument_with_block?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#105 def call_in_literals?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#110 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#116 def call_in_logical_operators?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#119 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#162 + def call_in_match_pattern?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#125 def call_in_optional_arguments?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#123 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#129 def call_in_single_line_inheritance?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#127 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#133 def call_with_ambiguous_arguments?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#137 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#145 def call_with_braced_block?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#214 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#235 def forwards_anonymous_rest_arguments?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#183 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#204 def hash_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#147 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#168 def hash_literal_in_arguments?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#44 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#45 def inside_endless_method_def?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#200 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#221 def inside_string_interpolation?(node); end # Require hash value omission be enclosed in parentheses to prevent the following issue: @@ -38966,20 +40377,25 @@ module RuboCop::Cop::Style::MethodCallWithArgsParentheses::OmitParentheses # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#58 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#59 def last_expression?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#87 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#92 def legitimate_call_with_parentheses?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#179 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#200 def logical_operator?(node); end - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#40 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#67 + def method_call_before_constant_resolution?(node); end + + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#41 def offense_range(node); end # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#16 @@ -38987,42 +40403,42 @@ module RuboCop::Cop::Style::MethodCallWithArgsParentheses::OmitParentheses # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#80 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#85 def parentheses_at_the_end_of_multiline_call?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#187 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#208 def regexp_slash_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#49 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#50 def require_parentheses_for_hash_value_omission?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#171 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#192 def splat?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#66 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#71 def super_call_without_arguments?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#62 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#63 def syntax_like_method_call?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#175 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#196 def ternary_if?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#191 + # source://rubocop//lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb#212 def unary_literal?(node); end end @@ -39068,6 +40484,9 @@ RuboCop::Cop::Style::MethodCallWithArgsParentheses::RequireParentheses::REQUIRE_ # This cop can be customized allowed methods with `AllowedMethods`. # By default, there are no methods to allowed. # +# NOTE: This cop allows the use of `it()` without arguments in blocks, +# as in `0.times { it() }`, following `Lint/ItWithoutArgumentsInBlock` cop. +# # @example # # bad # object.some_method() @@ -39081,55 +40500,66 @@ RuboCop::Cop::Style::MethodCallWithArgsParentheses::RequireParentheses::REQUIRE_ # # good # object.foo() # -# source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#26 +# source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#29 class RuboCop::Cop::Style::MethodCallWithoutArgsParentheses < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedMethods include ::RuboCop::Cop::AllowedPattern extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#33 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#37 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#60 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#66 def allowed_method_name?(name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#74 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#94 def any_assignment?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#56 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#62 def default_argument?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#52 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#58 def ineligible_node?(node); end - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#97 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#117 def offense_range(node); end - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#45 + # Respects `Lint/ItWithoutArgumentsInBlock` cop and the following Ruby 3.3's warning: + # + # $ ruby -e '0.times { begin; it; end }' + # -e:1: warning: `it` calls without arguments will refer to the first block param in + # Ruby 3.4; use it() or self.it + # + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#86 + def parenthesized_it_method_in_block?(node); end + + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#51 def register_offense(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#64 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#70 def same_name_assignment?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#90 + # source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#110 def variable_in_mass_assignment?(variable_name, node); end end -# source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#31 +# source://rubocop//lib/rubocop/cop/style/method_call_without_args_parentheses.rb#34 RuboCop::Cop::Style::MethodCallWithoutArgsParentheses::MSG = T.let(T.unsafe(nil), String) # Checks for methods called on a do...end block. The point of @@ -39527,15 +40957,10 @@ class RuboCop::Cop::Style::MissingElse < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/missing_else.rb#127 def check(node); end - # source://rubocop//lib/rubocop/cop/style/missing_else.rb#181 + # source://rubocop//lib/rubocop/cop/style/missing_else.rb#177 def empty_else_config; end - # @return [Boolean] - # # source://rubocop//lib/rubocop/cop/style/missing_else.rb#171 - def empty_else_cop_enabled?; end - - # source://rubocop//lib/rubocop/cop/style/missing_else.rb#175 def empty_else_style; end # @return [Boolean] @@ -39568,12 +40993,12 @@ RuboCop::Cop::Style::MissingElse::MSG_NIL = T.let(T.unsafe(nil), String) # defining `respond_to_missing?`. # # @example -# #bad +# # bad # def method_missing(name, *args) # # ... # end # -# #good +# # good # def respond_to_missing?(name, include_private) # # ... # end @@ -40105,33 +41530,33 @@ class RuboCop::Cop::Style::MultilineMethodSignature < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#60 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#69 def arguments_range(node); end - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#41 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#42 def autocorrect(corrector, node, begin_of_arguments); end - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#72 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#81 def closing_line(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#76 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#85 def correction_exceeds_max_line_length?(node); end - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#84 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#93 def definition_width(node); end - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#80 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#89 def indentation_width(node); end - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#56 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#65 def last_line_source_of_arguments(arguments); end - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#88 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#97 def max_line_length; end - # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#68 + # source://rubocop//lib/rubocop/cop/style/multiline_method_signature.rb#77 def opening_line(node); end end @@ -40178,28 +41603,28 @@ class RuboCop::Cop::Style::MultilineTernaryOperator < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#60 + # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#64 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#84 + # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#86 def comments_in_condition(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#90 + # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#92 def enforce_single_line_ternary_operator?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#56 + # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#60 def offense?(node); end - # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#70 + # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#72 def replacement(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#94 + # source://rubocop//lib/rubocop/cop/style/multiline_ternary_operator.rb#96 def use_assignment_method?(node); end end @@ -40247,11 +41672,6 @@ class RuboCop::Cop::Style::MultilineWhenThen < ::RuboCop::Cop::Base private - # @return [Boolean] - # - # source://rubocop//lib/rubocop/cop/style/multiline_when_then.rb#58 - def accept_node_type?(node); end - # Requires `then` for write `when` and its body on the same line. # # @return [Boolean] @@ -41003,16 +42423,13 @@ class RuboCop::Cop::Style::NestedTernaryOperator < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/nested_ternary_operator.rb#48 + # source://rubocop//lib/rubocop/cop/style/nested_ternary_operator.rb#40 def autocorrect(corrector, if_node); end - # source://rubocop//lib/rubocop/cop/style/nested_ternary_operator.rb#41 - def if_node(node); end - - # source://rubocop//lib/rubocop/cop/style/nested_ternary_operator.rb#55 + # source://rubocop//lib/rubocop/cop/style/nested_ternary_operator.rb#47 def remove_parentheses(source); end - # source://rubocop//lib/rubocop/cop/style/nested_ternary_operator.rb#61 + # source://rubocop//lib/rubocop/cop/style/nested_ternary_operator.rb#53 def replace_loc_and_whitespace(corrector, range, replacement); end end @@ -41214,17 +42631,17 @@ class RuboCop::Cop::Style::NilComparison < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/nil_comparison.rb#65 + # source://rubocop//lib/rubocop/cop/style/nil_comparison.rb#67 def message(_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/nil_comparison.rb#77 + # source://rubocop//lib/rubocop/cop/style/nil_comparison.rb#79 def prefer_comparison?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/nil_comparison.rb#69 + # source://rubocop//lib/rubocop/cop/style/nil_comparison.rb#71 def style_check?(node, &block); end end @@ -41775,16 +43192,16 @@ class RuboCop::Cop::Style::NumericPredicate < ::RuboCop::Cop::Base include ::RuboCop::Cop::AllowedPattern extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#166 + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#174 def comparison(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#171 + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#179 def inverted_comparison(param0 = T.unsafe(nil)); end # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#90 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#161 + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#169 def predicate(param0 = T.unsafe(nil)); end private @@ -41797,23 +43214,28 @@ class RuboCop::Cop::Style::NumericPredicate < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#111 def check(node); end - # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#152 + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#154 def invert; end - # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#132 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#162 + def negated?(node); end + + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#134 def parenthesized_source(node); end # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#124 - def replacement(numeric, operation); end + def replacement(node, numeric, operation); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#144 + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#146 def replacement_supported?(operator); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#140 + # source://rubocop//lib/rubocop/cop/style/numeric_predicate.rb#142 def require_parentheses?(node); end end @@ -41864,11 +43286,13 @@ class RuboCop::Cop::Style::ObjectThen < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/object_then.rb#48 def check_method_node(node); end - # source://rubocop//lib/rubocop/cop/style/object_then.rb#68 + # source://rubocop//lib/rubocop/cop/style/object_then.rb#70 def message(node); end - # source://rubocop//lib/rubocop/cop/style/object_then.rb#57 - def preferred_method(node); end + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/object_then.rb#59 + def preferred_method?(node); end end # source://rubocop//lib/rubocop/cop/style/object_then.rb#32 @@ -42000,8 +43424,8 @@ end RuboCop::Cop::Style::OpenStructUse::MSG = T.let(T.unsafe(nil), String) # Checks for redundant dot before operator method call. -# The target operator methods are `|`, `^`, `&`, `<=>`, `==`, `===`, `=~`, `>`, `>=`, `<`, -# `<=`, `<<`, `>>`, `+`, `-`, `*`, `/`, `%`, `**`, `~`, `!`, `!=`, and `!~`. +# The target operator methods are `|`, `^`, `&`, ``<=>``, `==`, `===`, `=~`, `>`, `>=`, `<`, +# ``<=``, `<<`, `>>`, `+`, `-`, `*`, `/`, `%`, `**`, `~`, `!`, `!=`, and `!~`. # # @example # @@ -42017,24 +43441,24 @@ RuboCop::Cop::Style::OpenStructUse::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::Style::OperatorMethodCall < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#26 + # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#27 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#48 + # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#53 def anonymous_forwarding?(argument); end # Checks for an acceptable case of `foo.+(bar).baz`. # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#42 + # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#47 def method_call_with_parenthesized_arg?(argument); end - # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#55 + # source://rubocop//lib/rubocop/cop/style/operator_method_call.rb#60 def wrap_in_parentheses_if_chained(corrector, node); end end @@ -42334,7 +43758,7 @@ class RuboCop::Cop::Style::ParallelAssignment::AssignmentSorter def tsort_each_child(assignment); end # source://rubocop//lib/rubocop/cop/style/parallel_assignment.rb#145 - def tsort_each_node(&block); end + def tsort_each_node(*_arg0, **_arg1, &_arg2); end # source://rubocop//lib/rubocop/cop/style/parallel_assignment.rb#136 def uses_var?(param0, param1); end @@ -42506,20 +43930,20 @@ class RuboCop::Cop::Style::ParenthesesAroundCondition < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#122 + # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#130 def allow_multiline_conditions?; end - # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#110 + # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#118 def message(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#103 + # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#111 def modifier_op?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#116 + # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#124 def parens_allowed?(node); end # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#80 @@ -42527,7 +43951,12 @@ class RuboCop::Cop::Style::ParenthesesAroundCondition < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#95 + # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#96 + def require_parentheses?(node, condition_body); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/parentheses_around_condition.rb#103 def semicolon_separated_expressions?(first_exp, rest_exps); end end @@ -42838,7 +44267,7 @@ RuboCop::Cop::Style::Proc::MSG = T.let(T.unsafe(nil), String) # # String interpolation is always kept in double quotes. # -# Note: `Lint/SymbolConversion` can be used in parallel to ensure that symbols +# NOTE: `Lint/SymbolConversion` can be used in parallel to ensure that symbols # are not quoted that don't need to be. This cop is for configuring the quoting # style to use for symbols that require quotes. # @@ -42948,56 +44377,56 @@ RuboCop::Cop::Style::QuotedSymbols::MSG_SINGLE = T.let(T.unsafe(nil), String) # raise MyCustomError.new(arg1, arg2, arg3) # fail 'message' # -# source://rubocop//lib/rubocop/cop/style/raise_args.rb#44 +# source://rubocop//lib/rubocop/cop/style/raise_args.rb#47 class RuboCop::Cop::Style::RaiseArgs < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#53 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#56 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#129 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#132 def acceptable_exploded_args?(args); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#143 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#146 def allowed_non_exploded_type?(arg); end - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#92 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#95 def check_compact(node); end - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#108 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#111 def check_exploded(node); end - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#66 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#69 def correction_compact_to_exploded(node); end - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#78 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#81 def correction_exploded_to_compact(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#149 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#152 def requires_parens?(parent); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/raise_args.rb#125 + # source://rubocop//lib/rubocop/cop/style/raise_args.rb#128 def use_new_method?(first_arg); end end -# source://rubocop//lib/rubocop/cop/style/raise_args.rb#49 +# source://rubocop//lib/rubocop/cop/style/raise_args.rb#52 RuboCop::Cop::Style::RaiseArgs::COMPACT_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/raise_args.rb#48 +# source://rubocop//lib/rubocop/cop/style/raise_args.rb#51 RuboCop::Cop::Style::RaiseArgs::EXPLODED_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/raise_args.rb#51 +# source://rubocop//lib/rubocop/cop/style/raise_args.rb#54 RuboCop::Cop::Style::RaiseArgs::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for the use of randomly generated numbers, @@ -43092,6 +44521,8 @@ RuboCop::Cop::Style::RandomWithOffset::RESTRICT_ON_SEND = T.let(T.unsafe(nil), A # array.join('') # [1, 2, 3].join("") # array.sum(0) +# exit(true) +# exit!(false) # string.split(" ") # "first\nsecond".split(" ") # string.chomp("\n") @@ -43102,37 +44533,55 @@ RuboCop::Cop::Style::RandomWithOffset::RESTRICT_ON_SEND = T.let(T.unsafe(nil), A # array.join # [1, 2, 3].join # array.sum +# exit +# exit! # string.split # "first second".split # string.chomp # string.chomp! # A.foo # -# source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#53 +# source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#57 class RuboCop::Cop::Style::RedundantArgument < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#59 + # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#64 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#64 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#88 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#108 + def argument_matched?(target_argument, redundant_argument); end + + # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#100 def argument_range(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#81 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#120 + def exclude_cntrl_character?(target_argument, redundant_argument); end + + # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#93 def redundant_arg_for_method(method_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#74 + # source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#80 def redundant_argument?(node); end end -# source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#57 +# source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#61 RuboCop::Cop::Style::RedundantArgument::MSG = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/style/redundant_argument.rb#62 +RuboCop::Cop::Style::RedundantArgument::NO_RECEIVER_METHODS = T.let(T.unsafe(nil), Array) + # Checks for the instantiation of array using redundant `Array` constructor. # Autocorrect replaces to array literal which is the simplest and fastest. # @@ -43223,22 +44672,25 @@ class RuboCop::Cop::Style::RedundantAssignment < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#91 + # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#99 def check_begin_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#57 + # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#58 def check_branch(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#71 + # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#79 + def check_case_match_node(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#74 def check_case_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#87 + # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#95 def check_ensure_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#76 + # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#84 def check_if_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#83 + # source://rubocop//lib/rubocop/cop/style/redundant_assignment.rb#91 def check_rescue_node(node); end end @@ -43337,50 +44789,53 @@ class RuboCop::Cop::Style::RedundantBegin < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#169 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#177 def begin_block_has_multiline_statements?(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#161 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#169 def condition_range(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#173 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#181 def contain_rescue_or_ensure?(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#154 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#162 def correct_modifier_form_after_multiline_begin_block(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#165 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#173 def empty_begin?(node); end # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#110 def register_offense(node); end + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#139 + def remove_begin(corrector, offense_range, node); end + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#127 def replace_begin_with_statement(corrector, offense_range, node); end # Restore comments that occur between "begin" and "first_child". # These comments will be moved to above the assignment line. # - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#141 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#149 def restore_removed_comments(corrector, offense_range, node, first_child); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#148 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#156 def use_modifier_form_after_multiline_begin_block?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#186 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#194 def valid_begin_assignment?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#179 + # source://rubocop//lib/rubocop/cop/style/redundant_begin.rb#187 def valid_context_using_only_begin?(node); end end @@ -43430,7 +44885,7 @@ RuboCop::Cop::Style::RedundantCapitalW::MSG = T.let(T.unsafe(nil), String) # # # good # a = b || c -# @example +# # # bad # if b # b @@ -43448,12 +44903,12 @@ RuboCop::Cop::Style::RedundantCapitalW::MSG = T.let(T.unsafe(nil), String) # c # end # -# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#33 +# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#32 class RuboCop::Cop::Style::RedundantCondition < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#43 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#42 def on_if(node); end private @@ -43463,116 +44918,116 @@ class RuboCop::Cop::Style::RedundantCondition < ::RuboCop::Cop::Base # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#167 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#166 def argument_with_operator?(argument); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#142 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#141 def asgn_type?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#132 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#131 def branches_have_assignment?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#146 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#145 def branches_have_method?(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#240 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#239 def correct_ternary(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#187 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#186 def else_source(else_branch, arithmetic_operation); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#213 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#212 def else_source_if_has_assignment(else_branch); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#203 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#202 def else_source_if_has_method(else_branch); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#175 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#174 def if_source(if_branch, arithmetic_operation); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#223 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#222 def make_ternary_form(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#64 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#63 def message(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#79 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#78 def offense?(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#72 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#71 def range_of_offense(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#88 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#87 def redundant_condition?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#255 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#254 def require_braces?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#248 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#247 def require_parentheses?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#161 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#160 def same_method?(if_branch, else_branch); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#155 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#154 def single_argument_method?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#104 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#103 def synonymous_condition_and_branch?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#259 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#258 def use_arithmetic_operation?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#100 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#99 def use_hash_key_access?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#96 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#95 def use_hash_key_assignment?(else_branch); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#92 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#91 def use_if_branch?(else_branch); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#263 + # source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#262 def without_argument_parentheses_method?(node); end end -# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#39 +# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#38 RuboCop::Cop::Style::RedundantCondition::ARGUMENT_WITH_OPERATOR_TYPES = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#37 +# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#36 RuboCop::Cop::Style::RedundantCondition::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#38 +# source://rubocop//lib/rubocop/cop/style/redundant_condition.rb#37 RuboCop::Cop::Style::RedundantCondition::REDUNDANT_CONDITION = T.let(T.unsafe(nil), String) # Checks for redundant returning of true/false in conditionals. @@ -43613,13 +45068,8 @@ class RuboCop::Cop::Style::RedundantConditional < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/redundant_conditional.rb#86 - def indented_else_node(expression, node); end - - # @return [Boolean] - # # source://rubocop//lib/rubocop/cop/style/redundant_conditional.rb#78 - def invert_expression?(node); end + def indented_else_node(expression, node); end # source://rubocop//lib/rubocop/cop/style/redundant_conditional.rb#48 def message(node); end @@ -43711,6 +45161,34 @@ end # source://rubocop//lib/rubocop/cop/style/redundant_constant_base.rb#46 RuboCop::Cop::Style::RedundantConstantBase::MSG = T.let(T.unsafe(nil), String) +# Checks for uses a redundant current directory in path. +# +# @example +# +# # bad +# require_relative './path/to/feature' +# +# # good +# require_relative 'path/to/feature' +# +# source://rubocop//lib/rubocop/cop/style/redundant_current_directory_in_path.rb#16 +class RuboCop::Cop::Style::RedundantCurrentDirectoryInPath < ::RuboCop::Cop::Base + include ::RuboCop::Cop::RangeHelp + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/redundant_current_directory_in_path.rb#24 + def on_send(node); end +end + +# source://rubocop//lib/rubocop/cop/style/redundant_current_directory_in_path.rb#22 +RuboCop::Cop::Style::RedundantCurrentDirectoryInPath::CURRENT_DIRECTORY_PATH = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/redundant_current_directory_in_path.rb#20 +RuboCop::Cop::Style::RedundantCurrentDirectoryInPath::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/redundant_current_directory_in_path.rb#21 +RuboCop::Cop::Style::RedundantCurrentDirectoryInPath::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) + # Checks for redundant uses of double splat hash braces. # # @example @@ -43721,23 +45199,63 @@ RuboCop::Cop::Style::RedundantConstantBase::MSG = T.let(T.unsafe(nil), String) # # good # do_something(foo: bar, baz: qux) # -# source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#16 +# # bad +# do_something(**{foo: bar, baz: qux}.merge(options)) +# +# # good +# do_something(foo: bar, baz: qux, **options) +# +# source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#22 class RuboCop::Cop::Style::RedundantDoubleSplatHashBraces < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#21 + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#29 def on_hash(node); end private - # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#39 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#45 + def allowed_double_splat_receiver?(kwsplat); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#55 + def autocorrect(corrector, node, kwsplat); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#89 + def autocorrect_merge_methods(corrector, merge_methods, kwsplat); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#85 def closing_brace(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#35 + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#111 + def convert_to_new_arguments(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#107 + def extract_send_methods(kwsplat); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#123 + def mergeable?(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#81 def opening_brace(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#100 + def range_of_merge_methods(merge_methods); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#66 + def root_receiver(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#75 + def select_merge_method_nodes(kwsplat); end end -# source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#19 +# source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#26 +RuboCop::Cop::Style::RedundantDoubleSplatHashBraces::MERGE_METHODS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/redundant_double_splat_hash_braces.rb#25 RuboCop::Cop::Style::RedundantDoubleSplatHashBraces::MSG = T.let(T.unsafe(nil), String) # Checks for redundant `each`. @@ -43768,21 +45286,24 @@ RuboCop::Cop::Style::RedundantDoubleSplatHashBraces::MSG = T.let(T.unsafe(nil), class RuboCop::Cop::Style::RedundantEach < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector + # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#43 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#43 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#93 + # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#96 def message(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#85 + # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#86 def range(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#63 + # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#64 def redundant_each_method(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#104 + # source://rubocop//lib/rubocop/cop/style/redundant_each.rb#107 def remove_redundant_each(corrector, range, redundant_node); end end @@ -43800,48 +45321,64 @@ RuboCop::Cop::Style::RedundantEach::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Arra # Checks for RuntimeError as the argument of raise/fail. # -# It checks for code like this: -# # @example -# # Bad +# # bad # raise RuntimeError, 'message' -# -# # Bad # raise RuntimeError.new('message') # -# # Good +# # good # raise 'message' # -# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#19 +# # bad - message is not a string +# raise RuntimeError, Object.new +# raise RuntimeError.new(Object.new) +# +# # good +# raise Object.new.to_s +# +# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#23 class RuboCop::Cop::Style::RedundantException < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#59 + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#79 def compact?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#54 + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#74 def exploded?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#45 + # Switch `raise RuntimeError, 'message'` to `raise 'message'`, and + # `raise RuntimeError.new('message')` to `raise 'message'`. + # + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#33 + def on_send(node); end + + private + + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#57 def fix_compact(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#33 + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#39 def fix_exploded(node); end - # Switch `raise RuntimeError, 'message'` to `raise 'message'`, and - # `raise RuntimeError.new('message')` to `raise 'message'`. + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#65 + def replaced_compact(message); end + + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#47 + def replaced_exploded(node, command, message); end + + # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#29 - def on_send(node); end + # source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#53 + def string_message?(message); end end -# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#22 +# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#26 RuboCop::Cop::Style::RedundantException::MSG_1 = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#23 +# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#27 RuboCop::Cop::Style::RedundantException::MSG_2 = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#25 +# source://rubocop//lib/rubocop/cop/style/redundant_exception.rb#29 RuboCop::Cop::Style::RedundantException::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Identifies places where `fetch(key) { value }` can be replaced by `fetch(key, value)`. @@ -43930,7 +45467,7 @@ RuboCop::Cop::Style::RedundantFetchBlock::MSG = T.let(T.unsafe(nil), String) # Checks for the presence of superfluous `.rb` extension in # the filename provided to `require` and `require_relative`. # -# Note: If the extension is omitted, Ruby tries adding '.rb', '.so', +# NOTE: If the extension is omitted, Ruby tries adding '.rb', '.so', # and so on to the name until found. If the file named cannot be found, # a `LoadError` will be raised. # There is an edge case where `foo.so` file is loaded instead of a `LoadError` @@ -43994,6 +45531,9 @@ RuboCop::Cop::Style::RedundantFileExtensionInRequire::RESTRICT_ON_SEND = T.let(T # @example AllCops:ActiveSupportExtensionsEnabled: false (default) # # good # arr.select { |x| x > 1 }.many? +# +# # good +# arr.select { |x| x > 1 }.present? # @example AllCops:ActiveSupportExtensionsEnabled: true # # bad # arr.select { |x| x > 1 }.many? @@ -44001,38 +45541,47 @@ RuboCop::Cop::Style::RedundantFileExtensionInRequire::RESTRICT_ON_SEND = T.let(T # # good # arr.many? { |x| x > 1 } # -# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#38 +# # bad +# arr.select { |x| x > 1 }.present? +# +# # good +# arr.any? { |x| x > 1 } +# +# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#53 class RuboCop::Cop::Style::RedundantFilterChain < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#65 + # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#81 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#81 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#47 + # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#62 def select_predicate?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#91 + # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#108 def offense_range(select_node, predicate_node); end - # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#95 + # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#112 def predicate_range(predicate_node); end - # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#77 + # source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#94 def register_offense(select_node, predicate_node); end end -# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#41 +# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#56 RuboCop::Cop::Style::RedundantFilterChain::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#43 +# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#58 RuboCop::Cop::Style::RedundantFilterChain::RAILS_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#56 +# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#71 RuboCop::Cop::Style::RedundantFilterChain::REPLACEMENT_METHODS = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#44 +# source://rubocop//lib/rubocop/cop/style/redundant_filter_chain.rb#59 RuboCop::Cop::Style::RedundantFilterChain::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Check for uses of `Object#freeze` on immutable objects. @@ -44395,42 +45944,47 @@ class RuboCop::Cop::Style::RedundantLineContinuation < ::RuboCop::Cop::Base include ::RuboCop::Cop::MatchRange extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#78 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#79 def on_new_investigation; end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#166 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#183 def argument_is_method?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#134 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#147 def argument_newline?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#100 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#102 def ends_with_backslash_without_comment?(source_line); end - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#146 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#163 def find_node_for_line(line); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#122 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#132 def inside_string_literal?(range, token); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#108 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#110 def inside_string_literal_or_method_with_argument?(range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#173 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#118 + def leading_dot_method_chain_with_blank_line?(range); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#190 def method_call_with_arguments?(node); end # A method call without parentheses such as the following cannot remove `\`: @@ -44440,38 +45994,41 @@ class RuboCop::Cop::Style::RedundantLineContinuation < ::RuboCop::Cop::Base # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#130 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#140 def method_with_argument?(current_token, next_token); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#114 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#124 def redundant_line_continuation?(range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#93 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#94 def require_line_continuation?(range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#152 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#169 def same_line?(node, line); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#177 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#194 def start_with_arithmetic_operator?(source_line); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#104 + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#106 def string_concatenation?(source_line); end end # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#72 RuboCop::Cop::Style::RedundantLineContinuation::ALLOWED_STRING_TOKENS = T.let(T.unsafe(nil), Array) +# source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#77 +RuboCop::Cop::Style::RedundantLineContinuation::ARGUMENT_TAKING_FLOW_TOKEN_TYPES = T.let(T.unsafe(nil), Array) + # source://rubocop//lib/rubocop/cop/style/redundant_line_continuation.rb#73 RuboCop::Cop::Style::RedundantLineContinuation::ARGUMENT_TYPES = T.let(T.unsafe(nil), Array) @@ -44493,41 +46050,43 @@ class RuboCop::Cop::Style::RedundantParentheses < ::RuboCop::Cop::Base include ::RuboCop::Cop::Parentheses extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#33 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#32 def allowed_pin_operator?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#36 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#35 def arg_in_call_with_block?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#220 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#269 def first_send_argument?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#225 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#274 def first_super_argument?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#230 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#279 def first_yield_argument?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#138 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#175 def interpolation?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#27 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#26 def method_node_and_args(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#38 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#37 def on_begin(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#24 - def range_end?(param0 = T.unsafe(nil)); end - - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#30 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#29 def rescue?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#21 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#23 def square_brackets?(param0 = T.unsafe(nil)); end private + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#177 + def allow_in_multiline_conditions?; end + # @return [Boolean] # # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#68 @@ -44535,7 +46094,7 @@ class RuboCop::Cop::Style::RedundantParentheses < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#61 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#60 def allowed_expression?(node); end # @return [Boolean] @@ -44555,51 +46114,54 @@ class RuboCop::Cop::Style::RedundantParentheses < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#234 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#283 def call_chain_starts_with_int?(begin_node, send_node); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#125 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#136 def check(begin_node); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#140 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#184 def check_send(begin_node, node); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#149 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#193 def check_unary(begin_node, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#173 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#217 def disallowed_literal?(begin_node, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#105 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#114 def empty_parentheses?(node); end + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#147 + def find_offense_message(begin_node, node); end + # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#110 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#119 def first_arg_begins_with_hash_literal?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#215 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#258 def first_argument?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#54 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#53 def ignore_syntax?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#169 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#213 def keyword_ancestor?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#188 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#232 def keyword_with_redundant_parentheses?(node); end # @return [Boolean] @@ -44609,35 +46171,38 @@ class RuboCop::Cop::Style::RedundantParentheses < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#201 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#245 def method_call_with_redundant_parentheses?(node); end + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#128 + def method_chain_begins_with_hash_literal(node); end + # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#117 - def method_chain_begins_with_hash_literal?(node); end + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#107 + def multiline_control_flow_statements?(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#159 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#203 def offense(node, msg); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#211 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#254 def only_begin_arg?(args); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#46 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#45 def parens_allowed?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#177 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#221 def raised_to_power_negative_numeric?(begin_node, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#165 + # source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#209 def suspect_unary?(node); end # @return [Boolean] @@ -44646,6 +46211,9 @@ class RuboCop::Cop::Style::RedundantParentheses < ::RuboCop::Cop::Base def ternary_parentheses_required?; end end +# source://rubocop//lib/rubocop/cop/style/redundant_parentheses.rb#20 +RuboCop::Cop::Style::RedundantParentheses::ALLOWED_NODE_TYPES = T.let(T.unsafe(nil), Array) + # Checks for usage of the %q/%Q syntax when '' or "" would do. # # @example @@ -44736,6 +46304,72 @@ RuboCop::Cop::Style::RedundantPercentQ::SINGLE_QUOTE = T.let(T.unsafe(nil), Stri # source://rubocop//lib/rubocop/cop/style/redundant_percent_q.rb#31 RuboCop::Cop::Style::RedundantPercentQ::STRING_INTERPOLATION_REGEXP = T.let(T.unsafe(nil), Regexp) +# Identifies places where argument can be replaced from +# a deterministic regexp to a string. +# +# @example +# # bad +# 'foo'.byteindex(/f/) +# 'foo'.byterindex(/f/) +# 'foo'.gsub(/f/, 'x') +# 'foo'.gsub!(/f/, 'x') +# 'foo'.partition(/f/) +# 'foo'.rpartition(/f/) +# 'foo'.scan(/f/) +# 'foo'.split(/f/) +# 'foo'.start_with?(/f/) +# 'foo'.sub(/f/, 'x') +# 'foo'.sub!(/f/, 'x') +# +# # good +# 'foo'.byteindex('f') +# 'foo'.byterindex('f') +# 'foo'.gsub('f', 'x') +# 'foo'.gsub!('f', 'x') +# 'foo'.partition('f') +# 'foo'.rpartition('f') +# 'foo'.scan('f') +# 'foo'.split('f') +# 'foo'.start_with?('f') +# 'foo'.sub('f', 'x') +# 'foo'.sub!('f', 'x') +# +# source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#35 +class RuboCop::Cop::Style::RedundantRegexpArgument < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#47 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#47 + def on_send(node); end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#64 + def determinist_regexp?(regexp_node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#68 + def preferred_argument(regexp_node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#81 + def replacement(regexp_node); end +end + +# source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#42 +RuboCop::Cop::Style::RedundantRegexpArgument::DETERMINISTIC_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#38 +RuboCop::Cop::Style::RedundantRegexpArgument::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#39 +RuboCop::Cop::Style::RedundantRegexpArgument::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/redundant_regexp_argument.rb#43 +RuboCop::Cop::Style::RedundantRegexpArgument::STR_SPECIAL_CHARS = T.let(T.unsafe(nil), Array) + # Checks for unnecessary single-element Regexp character classes. # # @example @@ -44889,26 +46523,23 @@ class RuboCop::Cop::Style::RedundantRegexpEscape < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#59 + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#60 def allowed_escape?(node, char, index, within_character_class); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#75 + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#76 def char_class_begins_or_ends_with_escaped_hyphen?(node, index); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#91 + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#92 def delimiter?(node, char); end - # Please remove this `else` branch when support for regexp_parser 1.8 will be dropped. - # It's for compatibility with regexp_parser 1.8 and will never be maintained. - # # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#98 def each_escape(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#125 + # source://rubocop//lib/rubocop/cop/style/redundant_regexp_escape.rb#110 def escape_range_at_index(node, index); end end @@ -44943,13 +46574,18 @@ RuboCop::Cop::Style::RedundantRegexpEscape::MSG_REDUNDANT_ESCAPE = T.let(T.unsaf # return something # end # -# # good +# # bad # def test # return something if something_else # end # # # good # def test +# something if something_else +# end +# +# # good +# def test # if x # elsif y # else @@ -44966,79 +46602,82 @@ RuboCop::Cop::Style::RedundantRegexpEscape::MSG_REDUNDANT_ESCAPE = T.let(T.unsaf # return x, y # end # -# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#50 +# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#55 class RuboCop::Cop::Style::RedundantReturn < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#64 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#69 def on_def(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#64 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#69 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#58 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#63 def on_send(node); end private - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#99 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#104 def add_braces(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#94 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#99 def add_brackets(corrector, node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#164 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#175 def allow_multiple_return_values?; end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#159 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#170 def check_begin_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#105 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#110 def check_branch(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#133 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#144 + def check_case_match_node(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#139 def check_case_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#154 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#165 def check_ensure_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#138 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#149 def check_if_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#150 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#161 def check_resbody_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#145 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#156 def check_rescue_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#121 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#127 def check_return_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#75 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#80 def correct_with_arguments(return_node, corrector); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#71 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#76 def correct_without_arguments(return_node, corrector); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#90 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#95 def hash_without_braces?(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#168 + # source://rubocop//lib/rubocop/cop/style/redundant_return.rb#179 def message(node); end end -# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#54 +# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#59 RuboCop::Cop::Style::RedundantReturn::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#55 +# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#60 RuboCop::Cop::Style::RedundantReturn::MULTI_RETURN_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#56 +# source://rubocop//lib/rubocop/cop/style/redundant_return.rb#61 RuboCop::Cop::Style::RedundantReturn::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for redundant uses of `self`. @@ -45055,7 +46694,8 @@ RuboCop::Cop::Style::RedundantReturn::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Ar # protected scope, you cannot send private messages this way. # # Note we allow uses of `self` with operators because it would be awkward -# otherwise. +# otherwise. Also allows the use of `self.it` without arguments in blocks, +# as in `0.times { self.it }`, following `Lint/ItWithoutArgumentsInBlock` cop. # # @example # @@ -45080,114 +46720,125 @@ RuboCop::Cop::Style::RedundantReturn::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Ar # end # end # -# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#44 +# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#45 class RuboCop::Cop::Style::RedundantSelf < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector # @return [RedundantSelf] a new instance of RedundantSelf # - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#59 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#60 def initialize(config = T.unsafe(nil), options = T.unsafe(nil)); end # Assignment of self.x # - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#67 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#68 def on_and_asgn(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#85 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#86 def on_args(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#119 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#120 def on_block(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#89 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#90 def on_blockarg(node); end # Using self.x to distinguish from local variable x # - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#80 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#81 def on_def(node); end # Using self.x to distinguish from local variable x # - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#80 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#81 def on_defs(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#125 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#126 def on_if(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#103 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#104 def on_in_pattern(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#98 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#99 def on_lvasgn(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#93 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#94 def on_masgn(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#119 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#120 def on_numblock(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#73 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#74 def on_op_asgn(node); end # Assignment of self.x # - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#67 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#68 def on_or_asgn(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#107 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#108 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#125 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#126 def on_until(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#125 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#126 def on_while(node); end private - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#181 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#196 def add_lhs_to_local_variables_scopes(rhs, lhs); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#189 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#204 def add_masgn_lhs_variables(rhs, lhs); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#195 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#210 def add_match_var_scopes(in_pattern_node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#143 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#144 def add_scope(node, local_variables = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#175 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#190 def allow_self(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#149 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#150 def allowed_send_node?(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#166 + # Respects `Lint/ItWithoutArgumentsInBlock` cop and the following Ruby 3.3's warning: + # + # $ ruby -e '0.times { begin; it; end }' + # -e:1: warning: `it` calls without arguments will refer to the first block param in + # Ruby 3.4; use it() or self.it + # + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#165 + def it_method_in_block?(node); end + + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#181 def on_argument(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#158 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#173 def regular_method_call?(node); end class << self - # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#55 + # source://rubocop//lib/rubocop/cop/style/redundant_self.rb#56 def autocorrect_incompatible_with; end end end -# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#48 +# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#49 RuboCop::Cop::Style::RedundantSelf::KERNEL_METHODS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#49 +# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#50 RuboCop::Cop::Style::RedundantSelf::KEYWORDS = T.let(T.unsafe(nil), Array) -# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#47 +# source://rubocop//lib/rubocop/cop/style/redundant_self.rb#48 RuboCop::Cop::Style::RedundantSelf::MSG = T.let(T.unsafe(nil), String) # Checks for places where redundant assignments are made for in place @@ -45303,12 +46954,12 @@ class RuboCop::Cop::Style::RedundantSelfAssignmentBranch < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/redundant_self_assignment_branch.rb#64 def multiple_statements?(branch); end - # source://rubocop//lib/rubocop/cop/style/redundant_self_assignment_branch.rb#72 + # source://rubocop//lib/rubocop/cop/style/redundant_self_assignment_branch.rb#74 def register_offense(if_node, offense_branch, opposite_branch, keyword); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_self_assignment_branch.rb#68 + # source://rubocop//lib/rubocop/cop/style/redundant_self_assignment_branch.rb#70 def self_assign?(variable, branch); end # @return [Boolean] @@ -45371,6 +47022,9 @@ class RuboCop::Cop::Style::RedundantSort < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#104 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#104 def on_send(node); end @@ -45382,45 +47036,45 @@ class RuboCop::Cop::Style::RedundantSort < ::RuboCop::Cop::Base # This gets the start of the accessor whether it has a dot # (e.g. `.first`) or doesn't (e.g. `[0]`) # - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#192 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#193 def accessor_start(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#182 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#183 def arg_node(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#186 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#187 def arg_value(node); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#147 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#148 def autocorrect(corrector, node, sort_node, sorter, accessor); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#165 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#166 def base(accessor, arg); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#114 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#115 def find_redundant_sort(*nodes); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#135 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#136 def message(node, sorter, accessor); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#131 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#132 def offense_range(sort_node, node); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#124 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#125 def register_offense(node, sort_node, sorter, accessor); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#156 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#157 def replace_with_logical_operator(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#173 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#174 def suffix(sorter); end - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#161 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#162 def suggestion(sorter, accessor, arg); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#200 + # source://rubocop//lib/rubocop/cop/style/redundant_sort.rb#201 def with_logical_operator?(node); end end @@ -45537,7 +47191,7 @@ class RuboCop::Cop::Style::RedundantStringEscape < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_string_escape.rb#169 + # source://rubocop//lib/rubocop/cop/style/redundant_string_escape.rb#171 def disabling_interpolation?(range); end # @return [Boolean] @@ -45557,7 +47211,7 @@ class RuboCop::Cop::Style::RedundantStringEscape < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/redundant_string_escape.rb#165 + # source://rubocop//lib/rubocop/cop/style/redundant_string_escape.rb#167 def literal_in_interpolated_or_multiline_string?(node); end # source://rubocop//lib/rubocop/cop/style/redundant_string_escape.rb#59 @@ -46033,9 +47687,13 @@ RuboCop::Cop::Style::RescueStandardError::MSG_EXPLICIT = T.let(T.unsafe(nil), St # source://rubocop//lib/rubocop/cop/style/rescue_standard_error.rb#79 RuboCop::Cop::Style::RescueStandardError::MSG_IMPLICIT = T.let(T.unsafe(nil), String) -# Enforces consistency between 'return nil' and 'return'. +# Enforces consistency between `return nil` and `return`. # -# Supported styles are: return, return_nil. +# This cop is disabled by default. Because there seems to be a perceived semantic difference +# between `return` and `return nil`. The former can be seen as just halting evaluation, +# while the latter might be used when the return value is of specific concern. +# +# Supported styles are `return` and `return_nil`. # # @example EnforcedStyle: return (default) # # bad @@ -46058,48 +47716,113 @@ RuboCop::Cop::Style::RescueStandardError::MSG_IMPLICIT = T.let(T.unsafe(nil), St # return nil if arg # end # -# source://rubocop//lib/rubocop/cop/style/return_nil.rb#31 +# source://rubocop//lib/rubocop/cop/style/return_nil.rb#35 class RuboCop::Cop::Style::ReturnNil < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#86 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#90 def chained_send?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#89 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#93 def define_method?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#44 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#48 def on_return(node); end - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#42 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#46 def return_nil_node?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#39 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#43 def return_node?(param0 = T.unsafe(nil)); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#76 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#80 def correct_style?(node); end - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#72 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#76 def message(_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/return_nil.rb#81 + # source://rubocop//lib/rubocop/cop/style/return_nil.rb#85 def scoped_node?(node); end end -# source://rubocop//lib/rubocop/cop/style/return_nil.rb#35 +# source://rubocop//lib/rubocop/cop/style/return_nil.rb#39 RuboCop::Cop::Style::ReturnNil::RETURN_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/return_nil.rb#36 +# source://rubocop//lib/rubocop/cop/style/return_nil.rb#40 RuboCop::Cop::Style::ReturnNil::RETURN_NIL_MSG = T.let(T.unsafe(nil), String) +# Checks if `return` or `return nil` is used in predicate method definitions. +# +# @example +# # bad +# def foo? +# return if condition +# +# do_something? +# end +# +# # bad +# def foo? +# return nil if condition +# +# do_something? +# end +# +# # good +# def foo? +# return false if condition +# +# do_something? +# end +# @example AllowedMethods: ['foo?'] +# # good +# def foo? +# return if condition +# +# do_something? +# end +# @example AllowedPatterns: [/foo/] +# # good +# def foo? +# return if condition +# +# do_something? +# end +# +# source://rubocop//lib/rubocop/cop/style/return_nil_in_predicate_method_definition.rb#50 +class RuboCop::Cop::Style::ReturnNilInPredicateMethodDefinition < ::RuboCop::Cop::Base + include ::RuboCop::Cop::AllowedMethods + include ::RuboCop::Cop::AllowedPattern + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/return_nil_in_predicate_method_definition.rb#62 + def on_def(node); end + + # source://rubocop//lib/rubocop/cop/style/return_nil_in_predicate_method_definition.rb#62 + def on_defs(node); end + + # source://rubocop//lib/rubocop/cop/style/return_nil_in_predicate_method_definition.rb#58 + def return_nil?(param0 = T.unsafe(nil)); end + + private + + # source://rubocop//lib/rubocop/cop/style/return_nil_in_predicate_method_definition.rb#79 + def nil_node_at_the_end_of_method_body(body); end + + # source://rubocop//lib/rubocop/cop/style/return_nil_in_predicate_method_definition.rb#87 + def register_offense(offense_node, replacement); end +end + +# source://rubocop//lib/rubocop/cop/style/return_nil_in_predicate_method_definition.rb#55 +RuboCop::Cop::Style::ReturnNilInPredicateMethodDefinition::MSG = T.let(T.unsafe(nil), String) + # Transforms usages of a method call safeguarded by a non `nil` # check for the variable whose method is being called to # safe navigation (`&.`). If there is a method chain, all of the methods @@ -46313,6 +48036,9 @@ RuboCop::Cop::Style::SafeNavigation::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::Style::Sample < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector + # source://rubocop//lib/rubocop/cop/style/sample.rb#41 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/sample.rb#41 def on_send(node); end @@ -46321,36 +48047,36 @@ class RuboCop::Cop::Style::Sample < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/sample.rb#123 + # source://rubocop//lib/rubocop/cop/style/sample.rb#122 def correction(shuffle_arg, method, method_args); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#139 + # source://rubocop//lib/rubocop/cop/style/sample.rb#138 def extract_source(args); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#117 + # source://rubocop//lib/rubocop/cop/style/sample.rb#116 def message(shuffle_arg, method, method_args, range); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/sample.rb#58 + # source://rubocop//lib/rubocop/cop/style/sample.rb#59 def offensive?(method, method_args); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#95 + # source://rubocop//lib/rubocop/cop/style/sample.rb#96 def range_size(range_node); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#130 + # source://rubocop//lib/rubocop/cop/style/sample.rb#129 def sample_arg(method, method_args); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#69 + # source://rubocop//lib/rubocop/cop/style/sample.rb#70 def sample_size(method_args); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#78 + # source://rubocop//lib/rubocop/cop/style/sample.rb#79 def sample_size_for_one_arg(arg); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#88 + # source://rubocop//lib/rubocop/cop/style/sample.rb#89 def sample_size_for_two_args(first, second); end - # source://rubocop//lib/rubocop/cop/style/sample.rb#111 + # source://rubocop//lib/rubocop/cop/style/sample.rb#112 def source_range(shuffle_node, node); end end @@ -46407,6 +48133,9 @@ class RuboCop::Cop::Style::SelectByRegexp < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#74 def env_const?(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#88 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#88 def on_send(node); end @@ -46415,31 +48144,31 @@ class RuboCop::Cop::Style::SelectByRegexp < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#132 + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#133 def extract_send_node(block_node); end - # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#145 + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#146 def find_regexp(node, block); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#156 + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#157 def match_predicate_without_receiver?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#141 + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#142 def opposite?(regexp_method_send_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#106 + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#107 def receiver_allowed?(node); end - # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#120 + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#121 def register_offense(node, block_node, regexp, replacement); end - # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#112 + # source://rubocop//lib/rubocop/cop/style/select_by_regexp.rb#113 def replacement(regexp_method_send_node, node); end end @@ -46554,48 +48283,53 @@ class RuboCop::Cop::Style::Semicolon < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/semicolon.rb#64 def check_for_line_terminator_or_opener; end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#73 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#70 def each_semicolon; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#105 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#106 def exist_semicolon_after_left_curly_brace?(tokens); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#113 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#110 + def exist_semicolon_after_left_lambda_curly_brace?(tokens); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#118 def exist_semicolon_after_left_string_interpolation_brace?(tokens); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#101 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#102 def exist_semicolon_before_right_curly_brace?(tokens); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#109 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#114 def exist_semicolon_before_right_string_interpolation_brace?(tokens); end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#137 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#142 def expressions_per_line(exprs); end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#151 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#156 def find_range_node(token_before_semicolon); end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#143 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#148 def find_semicolon_positions(line); end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#157 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#162 def range_nodes; end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#117 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#122 def register_semicolon(line, column, after_expression, token_before_semicolon = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#86 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#84 def semicolon_position(tokens); end - # source://rubocop//lib/rubocop/cop/style/semicolon.rb#82 + # source://rubocop//lib/rubocop/cop/style/semicolon.rb#79 def tokens_for_lines; end class << self @@ -46611,12 +48345,12 @@ RuboCop::Cop::Style::Semicolon::MSG = T.let(T.unsafe(nil), String) # # @example # # bad -# Foo.send(:bar) -# quuz.send(:fred) +# Foo.send(bar) +# quuz.send(fred) # # # good -# Foo.__send__(:bar) -# quuz.public_send(:fred) +# Foo.__send__(bar) +# quuz.public_send(fred) # # source://rubocop//lib/rubocop/cop/style/send.rb#16 class RuboCop::Cop::Style::Send < ::RuboCop::Cop::Base @@ -46633,6 +48367,83 @@ RuboCop::Cop::Style::Send::MSG = T.let(T.unsafe(nil), String) # source://rubocop//lib/rubocop/cop/style/send.rb#18 RuboCop::Cop::Style::Send::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) +# Detects the use of the `public_send` method with a literal method name argument. +# Since the `send` method can be used to call private methods, by default, +# only the `public_send` method is detected. +# +# NOTE: Writer methods with names ending in `=` are always permitted because their +# behavior differs as follows: +# +# [source,ruby] +# ---- +# def foo=(foo) +# @foo = foo +# 42 +# end +# +# self.foo = 1 # => 1 +# send(:foo=, 1) # => 42 +# ---- +# +# @example +# # bad +# obj.public_send(:method_name) +# obj.public_send('method_name') +# +# # good +# obj.method_name +# @example AllowSend: true (default) +# # good +# obj.send(:method_name) +# obj.send('method_name') +# obj.__send__(:method_name) +# obj.__send__('method_name') +# @example AllowSend: false +# # bad +# obj.send(:method_name) +# obj.send('method_name') +# obj.__send__(:method_name) +# obj.__send__('method_name') +# +# # good +# obj.method_name +# +# source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#54 +class RuboCop::Cop::Style::SendWithLiteralMethodName < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#68 + def on_send(node); end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#90 + def allow_send?; end + + # source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#94 + def offense_range(node); end + + # source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#98 + def removal_argument_range(first_argument, second_argument); end +end + +# source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#60 +RuboCop::Cop::Style::SendWithLiteralMethodName::METHOD_NAME_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#57 +RuboCop::Cop::Style::SendWithLiteralMethodName::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#61 +RuboCop::Cop::Style::SendWithLiteralMethodName::RESERVED_WORDS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#58 +RuboCop::Cop::Style::SendWithLiteralMethodName::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/send_with_literal_method_name.rb#59 +RuboCop::Cop::Style::SendWithLiteralMethodName::STATIC_METHOD_NAME_NODE_TYPES = T.let(T.unsafe(nil), Array) + # Checks for uses of `fail` and `raise`. # # @example EnforcedStyle: only_raise (default) @@ -46790,8 +48601,11 @@ RuboCop::Cop::Style::SignalException::RAISE_MSG = T.let(T.unsafe(nil), String) # source://rubocop//lib/rubocop/cop/style/signal_exception.rb#114 RuboCop::Cop::Style::SignalException::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) -# Sometimes using dig method ends up with just a single -# argument. In such cases, dig should be replaced with []. +# Sometimes using `dig` method ends up with just a single +# argument. In such cases, dig should be replaced with `[]`. +# +# Since replacing `hash&.dig(:key)` with `hash[:key]` could potentially lead to error, +# calls to the `dig` method using safe navigation will be ignored. # # @example # # bad @@ -46810,21 +48624,24 @@ RuboCop::Cop::Style::SignalException::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Ar # keys = %i[key1 key2] # { key1: { key2: 'value' } }.dig(*keys) # -# source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#31 +# source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#34 class RuboCop::Cop::Style::SingleArgumentDig < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#42 + # source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#46 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#38 + # source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#42 def single_argument_dig?(param0 = T.unsafe(nil)); end end -# source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#34 +# source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#39 +RuboCop::Cop::Style::SingleArgumentDig::IGNORED_ARGUMENT_TYPES = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#37 RuboCop::Cop::Style::SingleArgumentDig::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#35 +# source://rubocop//lib/rubocop/cop/style/single_argument_dig.rb#38 RuboCop::Cop::Style::SingleArgumentDig::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks whether the block parameters of a single-line @@ -46899,6 +48716,50 @@ end # source://rubocop//lib/rubocop/cop/style/single_line_block_params.rb#34 RuboCop::Cop::Style::SingleLineBlockParams::MSG = T.let(T.unsafe(nil), String) +# Checks for single-line `do`...`end` block. +# +# In practice a single line `do`...`end` is autocorrected when `EnforcedStyle: semantic` +# in `Style/BlockDelimiters`. The autocorrection maintains the `do` ... `end` syntax to +# preserve semantics and does not change it to `{`...`}` block. +# +# @example +# +# # bad +# foo do |arg| bar(arg) end +# +# # good +# foo do |arg| +# bar(arg) +# end +# +# # bad +# ->(arg) do bar(arg) end +# +# # good +# ->(arg) { bar(arg) } +# +# source://rubocop//lib/rubocop/cop/style/single_line_do_end_block.rb#28 +class RuboCop::Cop::Style::SingleLineDoEndBlock < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/single_line_do_end_block.rb#34 + def on_block(node); end + + # source://rubocop//lib/rubocop/cop/style/single_line_do_end_block.rb#34 + def on_numblock(node); end + + private + + # source://rubocop//lib/rubocop/cop/style/single_line_do_end_block.rb#55 + def do_line(node); end + + # source://rubocop//lib/rubocop/cop/style/single_line_do_end_block.rb#63 + def x(corrector, node); end +end + +# source://rubocop//lib/rubocop/cop/style/single_line_do_end_block.rb#31 +RuboCop::Cop::Style::SingleLineDoEndBlock::MSG = T.let(T.unsafe(nil), String) + # Checks for single-line method definitions that contain a body. # It will accept single-line methods with no body. # @@ -46986,32 +48847,69 @@ RuboCop::Cop::Style::SingleLineMethods::MSG = T.let(T.unsafe(nil), String) # source://rubocop//lib/rubocop/cop/style/single_line_methods.rb#39 RuboCop::Cop::Style::SingleLineMethods::NOT_SUPPORTED_ENDLESS_METHOD_BODY_TYPES = T.let(T.unsafe(nil), Array) -# Checks that arrays are sliced with endless ranges instead of -# `ary[start..-1]` on Ruby 2.6+. +# Checks that arrays are not sliced with the redundant `ary[0..-1]`, replacing it with `ary`, +# and ensures arrays are sliced with endless ranges instead of `ary[start..-1]` on Ruby 2.6+, +# and with beginless ranges instead of `ary[nil..end]` on Ruby 2.7+. # # @example # # bad -# items[1..-1] +# items[0..-1] +# items[0..nil] +# items[0...nil] +# +# # good +# items +# +# # bad +# items[1..-1] # Ruby 2.6+ +# items[1..nil] # Ruby 2.6+ # # # good -# items[1..] +# items[1..] # Ruby 2.6+ +# +# # bad +# items[nil..42] # Ruby 2.7+ # -# source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#28 +# # good +# items[..42] # Ruby 2.7+ +# items[0..42] # Ruby 2.7+ +# +# source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#46 class RuboCop::Cop::Style::SlicingWithRange < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#40 + # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#77 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#38 + # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#73 + def range_from_zero?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#57 + def range_from_zero_till_minus_one?(param0 = T.unsafe(nil)); end + + # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#65 def range_till_minus_one?(param0 = T.unsafe(nil)); end + + private + + # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#111 + def beginless(range_node); end + + # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#107 + def endless(range_node); end + + # source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#93 + def offense_message_with_removal_range(range_node, selector); end end -# source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#34 +# source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#52 RuboCop::Cop::Style::SlicingWithRange::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#35 +# source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#53 +RuboCop::Cop::Style::SlicingWithRange::MSG_USELESS_RANGE = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/slicing_with_range.rb#54 RuboCop::Cop::Style::SlicingWithRange::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # If the branch of a conditional consists solely of a conditional node, @@ -47068,10 +48966,10 @@ class RuboCop::Cop::Style::SoleNestedConditional < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#240 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#261 def allow_modifier?; end - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#225 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#233 def arguments_range(node); end # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#81 @@ -47089,25 +48987,25 @@ class RuboCop::Cop::Style::SoleNestedConditional < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#145 def correct_for_basic_condition_style(corrector, node, if_branch, and_operator); end - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#175 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#181 def correct_for_comment(corrector, node, if_branch); end # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#136 def correct_for_guard_condition_style(corrector, outer_condition, if_branch, and_operator); end - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#165 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#171 def correct_for_outer_condition_modify_form_style(corrector, node, if_branch); end # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#130 def correct_from_unless_to_if(corrector, node, is_modify_form: T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#182 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#190 def correct_outer_condition(corrector, condition); end - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#195 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#203 def insert_bang(corrector, node, is_modify_form); end - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#208 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#216 def insert_bang_for_and(corrector, node); end # @return [Boolean] @@ -47117,15 +49015,18 @@ class RuboCop::Cop::Style::SoleNestedConditional < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#244 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#265 def outer_condition_modify_form?(node, if_branch); end - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#236 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#254 + def parenthesized_method_arguments(node); end + + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#244 def replace_condition(condition); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#220 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#228 def require_parentheses?(condition); end # @return [Boolean] @@ -47138,7 +49039,7 @@ class RuboCop::Cop::Style::SoleNestedConditional < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#231 + # source://rubocop//lib/rubocop/cop/style/sole_nested_conditional.rb#239 def wrap_condition?(node); end class << self @@ -47155,13 +49056,30 @@ RuboCop::Cop::Style::SoleNestedConditional::MSG = T.let(T.unsafe(nil), String) # will add a require statement to the top of the file if # enabled by RequireEnglish config. # -# Like `use_perl_names` but allows builtin global vars. -# +# @example EnforcedStyle: use_english_names (default) # # good +# require 'English' # or this could be in another file. +# # puts $LOAD_PATH # puts $LOADED_FEATURES # puts $PROGRAM_NAME -# puts ARGV +# puts $ERROR_INFO +# puts $ERROR_POSITION +# puts $FIELD_SEPARATOR # or $FS +# puts $OUTPUT_FIELD_SEPARATOR # or $OFS +# puts $INPUT_RECORD_SEPARATOR # or $RS +# puts $OUTPUT_RECORD_SEPARATOR # or $ORS +# puts $INPUT_LINE_NUMBER # or $NR +# puts $LAST_READ_LINE +# puts $DEFAULT_OUTPUT +# puts $DEFAULT_INPUT +# puts $PROCESS_ID # or $PID +# puts $CHILD_STATUS +# puts $LAST_MATCH_INFO +# puts $IGNORECASE +# puts $ARGV # or ARGV +# @example EnforcedStyle: use_perl_names +# # good # puts $: # puts $" # puts $0 @@ -47180,31 +49098,14 @@ RuboCop::Cop::Style::SoleNestedConditional::MSG = T.let(T.unsafe(nil), String) # puts $~ # puts $= # puts $* +# @example EnforcedStyle: use_builtin_english_names # -# @example EnforcedStyle: use_english_names (default) # # good -# require 'English' # or this could be in another file. -# +# # Like `use_perl_names` but allows builtin global vars. # puts $LOAD_PATH # puts $LOADED_FEATURES # puts $PROGRAM_NAME -# puts $ERROR_INFO -# puts $ERROR_POSITION -# puts $FIELD_SEPARATOR # or $FS -# puts $OUTPUT_FIELD_SEPARATOR # or $OFS -# puts $INPUT_RECORD_SEPARATOR # or $RS -# puts $OUTPUT_RECORD_SEPARATOR # or $ORS -# puts $INPUT_LINE_NUMBER # or $NR -# puts $LAST_READ_LINE -# puts $DEFAULT_OUTPUT -# puts $DEFAULT_INPUT -# puts $PROCESS_ID # or $PID -# puts $CHILD_STATUS -# puts $LAST_MATCH_INFO -# puts $IGNORECASE -# puts $ARGV # or ARGV -# @example EnforcedStyle: use_perl_names -# # good +# puts ARGV # puts $: # puts $" # puts $0 @@ -47223,90 +49124,89 @@ RuboCop::Cop::Style::SoleNestedConditional::MSG = T.let(T.unsafe(nil), String) # puts $~ # puts $= # puts $* -# @example EnforcedStyle: use_builtin_english_names # -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#87 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#86 class RuboCop::Cop::Style::SpecialGlobalVars < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle include ::RuboCop::Cop::RangeHelp include ::RuboCop::Cop::RequireLibrary extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#176 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#175 def autocorrect(corrector, node, global_var); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#168 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#167 def message(global_var); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#152 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#151 def on_gvar(node); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#147 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#146 def on_new_investigation; end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#247 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#246 def add_require_english?; end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#241 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#240 def english_name_replacement(preferred_name, node); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#190 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#189 def format_english_message(global_var); end # For now, we assume that lists are 2 items or less. Easy grammar! # - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#212 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#211 def format_list(items); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#198 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#197 def format_message(english, regular, global); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#235 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#234 def matching_styles(global); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#227 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#226 def preferred_names(global); end - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#216 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#215 def replacement(node, global_var); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#251 + # source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#250 def should_require_english?(global_var); end end -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#128 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#127 RuboCop::Cop::Style::SpecialGlobalVars::BUILTIN_VARS = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#100 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#99 RuboCop::Cop::Style::SpecialGlobalVars::ENGLISH_VARS = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#145 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#144 RuboCop::Cop::Style::SpecialGlobalVars::LIBRARY_NAME = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#93 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#92 RuboCop::Cop::Style::SpecialGlobalVars::MSG_BOTH = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#96 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#95 RuboCop::Cop::Style::SpecialGlobalVars::MSG_ENGLISH = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#98 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#97 RuboCop::Cop::Style::SpecialGlobalVars::MSG_REGULAR = T.let(T.unsafe(nil), String) # Anything *not* in this set is provided by the English library. # -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#122 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#121 RuboCop::Cop::Style::SpecialGlobalVars::NON_ENGLISH_VARS = T.let(T.unsafe(nil), Set) -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#124 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#123 RuboCop::Cop::Style::SpecialGlobalVars::PERL_VARS = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#139 +# source://rubocop//lib/rubocop/cop/style/special_global_vars.rb#138 RuboCop::Cop::Style::SpecialGlobalVars::STYLE_VARS_MAP = T.let(T.unsafe(nil), Hash) # Check for parentheses around stabby lambda arguments. @@ -47505,6 +49405,9 @@ class RuboCop::Cop::Style::StringChars < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector + # source://rubocop//lib/rubocop/cop/style/string_chars.rb#29 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/string_chars.rb#29 def on_send(node); end end @@ -47742,40 +49645,67 @@ end # source://rubocop//lib/rubocop/cop/style/string_literals.rb#35 RuboCop::Cop::Style::StringLiterals::MSG_INCONSISTENT = T.let(T.unsafe(nil), String) -# Checks that quotes inside the string interpolation +# Checks that quotes inside string, symbol, and regexp interpolations # match the configured preference. # # @example EnforcedStyle: single_quotes (default) # # bad -# result = "Tests #{success ? "PASS" : "FAIL"}" +# string = "Tests #{success ? "PASS" : "FAIL"}" +# symbol = :"Tests #{success ? "PASS" : "FAIL"}" +# heredoc = <<~TEXT +# Tests #{success ? "PASS" : "FAIL"} +# TEXT +# regexp = /Tests #{success ? "PASS" : "FAIL"}/ # # # good -# result = "Tests #{success ? 'PASS' : 'FAIL'}" +# string = "Tests #{success ? 'PASS' : 'FAIL'}" +# symbol = :"Tests #{success ? 'PASS' : 'FAIL'}" +# heredoc = <<~TEXT +# Tests #{success ? 'PASS' : 'FAIL'} +# TEXT +# regexp = /Tests #{success ? 'PASS' : 'FAIL'}/ # @example EnforcedStyle: double_quotes # # bad -# result = "Tests #{success ? 'PASS' : 'FAIL'}" +# string = "Tests #{success ? 'PASS' : 'FAIL'}" +# symbol = :"Tests #{success ? 'PASS' : 'FAIL'}" +# heredoc = <<~TEXT +# Tests #{success ? 'PASS' : 'FAIL'} +# TEXT +# regexp = /Tests #{success ? 'PASS' : 'FAIL'}/ # # # good -# result = "Tests #{success ? "PASS" : "FAIL"}" +# string = "Tests #{success ? "PASS" : "FAIL"}" +# symbol = :"Tests #{success ? "PASS" : "FAIL"}" +# heredoc = <<~TEXT +# Tests #{success ? "PASS" : "FAIL"} +# TEXT +# regexp = /Tests #{success ? "PASS" : "FAIL"}/ # -# source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#22 +# source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#42 class RuboCop::Cop::Style::StringLiteralsInInterpolation < ::RuboCop::Cop::Base include ::RuboCop::Cop::ConfigurableEnforcedStyle include ::RuboCop::Cop::StringLiteralsHelp include ::RuboCop::Cop::StringHelp extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#28 + # source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#48 def autocorrect(corrector, node); end + # Cop classes that include the StringHelp module usually ignore regexp + # nodes. Not so for this cop, which is why we override the on_regexp + # definition with an empty one. + # + # source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#55 + def on_regexp(node); end + private - # source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#34 + # source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#59 def message(_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#41 + # source://rubocop//lib/rubocop/cop/style/string_literals_in_interpolation.rb#66 def offense?(node); end end @@ -47825,7 +49755,10 @@ class RuboCop::Cop::Style::Strip < ::RuboCop::Cop::Base # source://rubocop//lib/rubocop/cop/style/strip.rb#24 def lstrip_rstrip(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/strip.rb#29 + # source://rubocop//lib/rubocop/cop/style/strip.rb#31 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/style/strip.rb#31 def on_send(node); end end @@ -47875,6 +49808,141 @@ end # source://rubocop//lib/rubocop/cop/style/struct_inheritance.rb#30 RuboCop::Cop::Style::StructInheritance::MSG = T.let(T.unsafe(nil), String) +# Checks for redundant argument forwarding when calling super with arguments identical to +# the method definition. +# +# Using zero arity `super` within a `define_method` block results in `RuntimeError`: +# +# [source,ruby] +# ---- +# def m +# define_method(:foo) { super() } # => OK +# end +# +# def m +# define_method(:foo) { super } # => RuntimeError +# end +# ---- +# +# Furthermore, any arguments accompanied by a block may potentially be delegating to +# `define_method`, therefore, `super` used within these blocks will be allowed. +# This approach might result in false negatives, yet ensuring safe detection takes precedence. +# +# @example +# # bad +# def method(*args, **kwargs) +# super(*args, **kwargs) +# end +# +# # good - implicitly passing all arguments +# def method(*args, **kwargs) +# super +# end +# +# # good - forwarding a subset of the arguments +# def method(*args, **kwargs) +# super(*args) +# end +# +# # good - forwarding no arguments +# def method(*args, **kwargs) +# super() +# end +# +# # good - assigning to the block variable before calling super +# def method(&block) +# # Assigning to the block variable would pass the old value to super, +# # under this circumstance the block must be referenced explicitly. +# block ||= proc { 'fallback behavior' } +# super(&block) +# end +# +# source://rubocop//lib/rubocop/cop/style/super_arguments.rb#54 +class RuboCop::Cop::Style::SuperArguments < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#62 + def on_super(super_node); end + + private + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#81 + def arguments_identical?(def_node, def_args, super_args); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#136 + def block_arg_same?(def_node, def_arg, super_arg); end + + # Reassigning the block argument will still pass along the original block to super + # https://bugs.ruby-lang.org/issues/20505 + # + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#147 + def block_reassigned?(def_node, block_arg_name); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#158 + def forward_arg_same?(def_arg, super_arg); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#116 + def keyword_arg_same?(def_arg, super_arg); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#126 + def keyword_rest_arg_same?(def_arg, super_arg); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#99 + def positional_arg_same?(def_arg, super_arg); end + + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#106 + def positional_rest_arg_same(def_arg, super_arg); end + + # source://rubocop//lib/rubocop/cop/style/super_arguments.rb#162 + def preprocess_super_args(super_args); end +end + +# source://rubocop//lib/rubocop/cop/style/super_arguments.rb#58 +RuboCop::Cop::Style::SuperArguments::ASSIGN_TYPES = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/super_arguments.rb#57 +RuboCop::Cop::Style::SuperArguments::DEF_TYPES = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/super_arguments.rb#60 +RuboCop::Cop::Style::SuperArguments::MSG = T.let(T.unsafe(nil), String) + +# Enforces the presence of parentheses in `super` containing arguments. +# +# `super` is a keyword and is provided as a distinct cop from those designed for method call. +# +# @example +# +# # bad +# super name, age +# +# # good +# super(name, age) +# +# source://rubocop//lib/rubocop/cop/style/super_with_args_parentheses.rb#18 +class RuboCop::Cop::Style::SuperWithArgsParentheses < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/super_with_args_parentheses.rb#23 + def on_super(node); end +end + +# source://rubocop//lib/rubocop/cop/style/super_with_args_parentheses.rb#21 +RuboCop::Cop::Style::SuperWithArgsParentheses::MSG = T.let(T.unsafe(nil), String) + # Enforces the use of shorthand-style swapping of 2 variables. # # @example @@ -47966,6 +50034,15 @@ RuboCop::Cop::Style::SwapValues::SIMPLE_ASSIGNMENT_TYPES = T.let(T.unsafe(nil), # # # bad # [:foo, :bar, :baz] +# +# # bad (contains spaces) +# %i[foo\ bar baz\ quux] +# +# # bad (contains [] with spaces) +# %i[foo \[ \]] +# +# # bad (contains () with spaces) +# %i(foo \( \)) # @example EnforcedStyle: brackets # # good # [:foo, :bar, :baz] @@ -47973,7 +50050,7 @@ RuboCop::Cop::Style::SwapValues::SIMPLE_ASSIGNMENT_TYPES = T.let(T.unsafe(nil), # # bad # %i[foo bar baz] # -# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#31 +# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#40 class RuboCop::Cop::Style::SymbolArray < ::RuboCop::Cop::Base include ::RuboCop::Cop::ArrayMinSize include ::RuboCop::Cop::ArraySyntax @@ -47982,48 +50059,62 @@ class RuboCop::Cop::Style::SymbolArray < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#48 + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#66 def on_array(node); end private - # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#67 + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#96 def build_bracketed_array(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#90 - def symbol_without_quote?(string); end + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#78 + def complex_content?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#60 - def symbols_contain_spaces?(node); end + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#92 + def invalid_percent_array_contents?(node); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#119 + def symbol_without_quote?(string); end - # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#82 + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#111 def to_symbol_literal(string); end class << self # Returns the value of attribute largest_brackets. # - # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#45 + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#63 def largest_brackets; end # Sets the attribute largest_brackets # # @param value the value to set the attribute largest_brackets to. # - # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#45 + # source://rubocop//lib/rubocop/cop/style/symbol_array.rb#63 def largest_brackets=(_arg0); end end end -# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#42 +# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#51 RuboCop::Cop::Style::SymbolArray::ARRAY_MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#41 +# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#52 +RuboCop::Cop::Style::SymbolArray::DELIMITERS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#50 RuboCop::Cop::Style::SymbolArray::PERCENT_MSG = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#57 +RuboCop::Cop::Style::SymbolArray::REDEFINABLE_OPERATORS = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/symbol_array.rb#53 +RuboCop::Cop::Style::SymbolArray::SPECIAL_GVARS = T.let(T.unsafe(nil), Array) + # Checks symbol literal syntax. # # @example @@ -48091,8 +50182,23 @@ RuboCop::Cop::Style::SymbolLiteral::MSG = T.let(T.unsafe(nil), String) # @example AllowedPatterns: ['map'] (default) # # good # something.map { |s| s.upcase } +# @example AllCops:ActiveSupportExtensionsEnabled: false (default) +# # bad +# ->(x) { x.foo } +# proc { |x| x.foo } +# Proc.new { |x| x.foo } +# +# # good +# lambda(&:foo) +# proc(&:foo) +# Proc.new(&:foo) +# @example AllCops:ActiveSupportExtensionsEnabled: true +# # good +# ->(x) { x.foo } +# proc { |x| x.foo } +# Proc.new { |x| x.foo } # -# source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#87 +# source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#140 class RuboCop::Cop::Style::SymbolProc < ::RuboCop::Cop::Base include ::RuboCop::Cop::CommentsHelp include ::RuboCop::Cop::RangeHelp @@ -48102,117 +50208,123 @@ class RuboCop::Cop::Style::SymbolProc < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#136 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#189 def destructuring_block_argument?(argument_node); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#116 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#170 def on_block(node); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#116 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#170 def on_numblock(node); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#98 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#152 def proc_node?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#104 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#158 def symbol_proc?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#101 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#155 def symbol_proc_receiver?(param0 = T.unsafe(nil)); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#204 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#274 def allow_comments?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#200 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#270 def allow_if_method_has_argument?(send_node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#151 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#204 def allowed_method_name?(name); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#164 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#217 def autocorrect(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#176 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#247 + def autocorrect_lambda_block(corrector, node); end + + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#238 def autocorrect_with_args(corrector, node, args, method_name); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#172 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#225 def autocorrect_without_args(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#190 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#260 def begin_pos_for_replacement(node); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#185 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#255 def block_range_with_space(node); end - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#155 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#208 def register_offense(node, method_name, block_method_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#147 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#200 def unsafe_array_usage?(node); end # See: https://github.com/rubocop/rubocop/issues/10864 # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#143 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#196 def unsafe_hash_usage?(node); end class << self - # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#111 + # source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#165 def autocorrect_incompatible_with; end end end -# source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#94 +# source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#149 +RuboCop::Cop::Style::SymbolProc::LAMBDA_OR_PROC = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#147 RuboCop::Cop::Style::SymbolProc::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#95 +# source://rubocop//lib/rubocop/cop/style/symbol_proc.rb#148 RuboCop::Cop::Style::SymbolProc::SUPER_TYPES = T.let(T.unsafe(nil), Array) # Corrector to correct conditional assignment in ternary conditions. # -# source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#498 +# source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#499 class RuboCop::Cop::Style::TernaryCorrector extend ::RuboCop::Cop::Style::ConditionalAssignmentHelper extend ::RuboCop::Cop::Style::ConditionalCorrectorHelper class << self - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#503 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#504 def correct(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#507 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#508 def move_assignment_inside_condition(corrector, node); end private - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#521 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#522 def correction(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#534 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#535 def element_assignment?(node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#538 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#539 def extract_branches(node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#551 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#552 def move_branch_inside_condition(corrector, branch, assignment); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#546 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#547 def remove_parentheses(corrector, node); end - # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#525 + # source://rubocop//lib/rubocop/cop/style/conditional_assignment.rb#526 def ternary(node); end end end @@ -49361,22 +51473,25 @@ class RuboCop::Cop::Style::UnpackFirst < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector extend ::RuboCop::Cop::TargetRubyVersion - # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#38 + # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#37 + def on_csend(node); end + + # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#37 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#31 + # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#30 def unpack_and_first_element?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#54 + # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#53 def first_element_range(node, unpack_call); end end # source://rubocop//lib/rubocop/cop/style/unpack_first.rb#26 RuboCop::Cop::Style::UnpackFirst::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/unpack_first.rb#28 +# source://rubocop//lib/rubocop/cop/style/unpack_first.rb#27 RuboCop::Cop::Style::UnpackFirst::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for variable interpolation (like "#@ivar"). @@ -49451,7 +51566,6 @@ RuboCop::Cop::Style::WhenThen::MSG = T.let(T.unsafe(nil), String) # while x.any? # do_something(x.pop) # end -# @example # # # bad # until x.empty? do @@ -49463,18 +51577,18 @@ RuboCop::Cop::Style::WhenThen::MSG = T.let(T.unsafe(nil), String) # do_something(x.pop) # end # -# source://rubocop//lib/rubocop/cop/style/while_until_do.rb#31 +# source://rubocop//lib/rubocop/cop/style/while_until_do.rb#29 class RuboCop::Cop::Style::WhileUntilDo < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/while_until_do.rb#36 + # source://rubocop//lib/rubocop/cop/style/while_until_do.rb#34 def on_until(node); end - # source://rubocop//lib/rubocop/cop/style/while_until_do.rb#36 + # source://rubocop//lib/rubocop/cop/style/while_until_do.rb#34 def on_while(node); end end -# source://rubocop//lib/rubocop/cop/style/while_until_do.rb#34 +# source://rubocop//lib/rubocop/cop/style/while_until_do.rb#32 RuboCop::Cop::Style::WhileUntilDo::MSG = T.let(T.unsafe(nil), String) # Checks for while and until statements that would fit on one line @@ -49489,7 +51603,7 @@ RuboCop::Cop::Style::WhileUntilDo::MSG = T.let(T.unsafe(nil), String) # # # good # x += 1 while x < 10 -# @example +# # # bad # until x > 10 # x += 1 @@ -49506,7 +51620,7 @@ RuboCop::Cop::Style::WhileUntilDo::MSG = T.let(T.unsafe(nil), String) # x += 100 # end # -# source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#36 +# source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#35 class RuboCop::Cop::Style::WhileUntilModifier < ::RuboCop::Cop::Base include ::RuboCop::Cop::Alignment include ::RuboCop::Cop::LineLengthHelp @@ -49514,14 +51628,14 @@ class RuboCop::Cop::Style::WhileUntilModifier < ::RuboCop::Cop::Base include ::RuboCop::Cop::StatementModifier extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#42 + # source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#41 def on_until(node); end - # source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#42 + # source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#41 def on_while(node); end end -# source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#40 +# source://rubocop//lib/rubocop/cop/style/while_until_modifier.rb#39 RuboCop::Cop::Style::WhileUntilModifier::MSG = T.let(T.unsafe(nil), String) # Checks for array literals made up of word-like @@ -49651,6 +51765,49 @@ RuboCop::Cop::Style::WordArray::ARRAY_MSG = T.let(T.unsafe(nil), String) # source://rubocop//lib/rubocop/cop/style/word_array.rb#78 RuboCop::Cop::Style::WordArray::PERCENT_MSG = T.let(T.unsafe(nil), String) +# Checks for the use of `YAML.load`, `YAML.safe_load`, and `YAML.parse` with +# `File.read` argument. +# +# NOTE: `YAML.safe_load_file` was introduced in Ruby 3.0. +# +# @example +# +# # bad +# YAML.load(File.read(path)) +# YAML.parse(File.read(path)) +# +# # good +# YAML.load_file(path) +# YAML.parse_file(path) +# +# # bad +# YAML.safe_load(File.read(path)) # Ruby 3.0 and newer +# +# # good +# YAML.safe_load_file(path) # Ruby 3.0 and newer +# +# source://rubocop//lib/rubocop/cop/style/yaml_file_read.rb#27 +class RuboCop::Cop::Style::YAMLFileRead < ::RuboCop::Cop::Base + extend ::RuboCop::Cop::AutoCorrector + + # source://rubocop//lib/rubocop/cop/style/yaml_file_read.rb#41 + def on_send(node); end + + # source://rubocop//lib/rubocop/cop/style/yaml_file_read.rb#34 + def yaml_file_read?(param0 = T.unsafe(nil)); end + + private + + # source://rubocop//lib/rubocop/cop/style/yaml_file_read.rb#60 + def offense_range(node); end +end + +# source://rubocop//lib/rubocop/cop/style/yaml_file_read.rb#30 +RuboCop::Cop::Style::YAMLFileRead::MSG = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/cop/style/yaml_file_read.rb#31 +RuboCop::Cop::Style::YAMLFileRead::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) + # Enforces or forbids Yoda conditions, # i.e. comparison operations where the order of expression is reversed. # eg. `5 == x` @@ -49714,15 +51871,15 @@ class RuboCop::Cop::Style::YodaCondition < ::RuboCop::Cop::Base private - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#147 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#149 def actual_code_range(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#143 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#145 def constant_portion?(node); end - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#136 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#138 def corrected_code(node); end # @return [Boolean] @@ -49737,38 +51894,38 @@ class RuboCop::Cop::Style::YodaCondition < ::RuboCop::Cop::Base # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#171 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#173 def interpolation?(node); end - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#132 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#134 def message(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#155 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#157 def non_equality_operator?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#159 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#161 def noncommutative_operator?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#167 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#169 def program_name?(name); end - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#151 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#153 def reverse_comparison(operator); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#163 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#165 def source_file_path_constant?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#121 + # source://rubocop//lib/rubocop/cop/style/yoda_condition.rb#122 def valid_yoda?(node); end # @return [Boolean] @@ -49806,61 +51963,62 @@ RuboCop::Cop::Style::YodaCondition::REVERSE_COMPARISON = T.let(T.unsafe(nil), Ha # config.server_port = 9000 + ENV["TEST_ENV_NUMBER"].to_i # ---- # -# @example SupportedOperators: ['*', '+', '&''] +# @example SupportedOperators: ['*', '+', '&', '|', '^'] (default) # # bad -# 1 + x # 10 * y +# 1 + x # 1 & z +# 1 | x +# 1 ^ x # 1 + CONST # # # good -# 60 * 24 -# x + 1 # y * 10 +# x + 1 # z & 1 +# x | 1 +# x ^ 1 # CONST + 1 +# 60 * 24 # -# # good -# 1 | x -# -# source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#39 +# source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#40 class RuboCop::Cop::Style::YodaExpression < ::RuboCop::Cop::Base extend ::RuboCop::Cop::AutoCorrector - # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#46 + # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#47 def on_new_investigation; end - # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#50 + # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#51 def on_send(node); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#72 + # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#73 def constant_portion?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#80 + # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#81 def offended_ancestor?(node); end - # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#84 + # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#85 def offended_nodes; end - # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#76 + # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#77 def supported_operators; end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#68 + # source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#69 def yoda_expression_constant?(lhs, rhs); end end -# source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#42 +# source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#43 RuboCop::Cop::Style::YodaExpression::MSG = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#44 +# source://rubocop//lib/rubocop/cop/style/yoda_expression.rb#45 RuboCop::Cop::Style::YodaExpression::RESTRICT_ON_SEND = T.let(T.unsafe(nil), Array) # Checks for numeric comparisons that can be replaced @@ -49897,39 +52055,42 @@ class RuboCop::Cop::Style::ZeroLengthPredicate < ::RuboCop::Cop::Base # implement `#size`, but not `#empty`. We ignore those to # reduce false positives. # - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#139 + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#147 def non_polymorphic_collection?(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#109 + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#114 def nonzero_length_comparison(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#51 + def on_csend(node); end + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#45 def on_send(node); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#130 - def other_receiver(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#138 + def other_length_node(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#101 + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#106 def zero_length_comparison(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#96 - def zero_length_predicate(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#130 + def zero_length_node(param0 = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#122 - def zero_length_receiver(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#101 + def zero_length_predicate?(param0 = T.unsafe(nil)); end private - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#80 + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#85 def check_nonzero_length_comparison(node); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#65 + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#70 def check_zero_length_comparison(node); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#53 + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#58 def check_zero_length_predicate(node); end - # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#114 + # source://rubocop//lib/rubocop/cop/style/zero_length_predicate.rb#119 def replacement(node); end end @@ -50076,12 +52237,12 @@ class RuboCop::Cop::Team # source://rubocop//lib/rubocop/cop/team.rb#51 def errors; end - # source://rubocop//lib/rubocop/cop/team.rb#114 + # source://rubocop//lib/rubocop/cop/team.rb#122 def external_dependency_checksum; end # @deprecated # - # source://rubocop//lib/rubocop/cop/team.rb#110 + # source://rubocop//lib/rubocop/cop/team.rb#114 def forces; end # source://rubocop//lib/rubocop/cop/team.rb#76 @@ -50089,7 +52250,7 @@ class RuboCop::Cop::Team # @return [Commissioner::InvestigationReport] # - # source://rubocop//lib/rubocop/cop/team.rb#81 + # source://rubocop//lib/rubocop/cop/team.rb#85 def investigate(processed_source, offset: T.unsafe(nil), original: T.unsafe(nil)); end # Returns the value of attribute updated_source_file. @@ -50109,57 +52270,57 @@ class RuboCop::Cop::Team private - # source://rubocop//lib/rubocop/cop/team.rb#121 + # source://rubocop//lib/rubocop/cop/team.rb#129 def autocorrect(processed_source, report, original:, offset:); end - # source://rubocop//lib/rubocop/cop/team.rb#182 + # source://rubocop//lib/rubocop/cop/team.rb#193 def autocorrect_report(report, offset:, original:); end - # source://rubocop//lib/rubocop/cop/team.rb#140 + # source://rubocop//lib/rubocop/cop/team.rb#148 def be_ready; end - # source://rubocop//lib/rubocop/cop/team.rb#188 + # source://rubocop//lib/rubocop/cop/team.rb#199 def collate_corrections(report, offset:, original:); end - # source://rubocop//lib/rubocop/cop/team.rb#204 + # source://rubocop//lib/rubocop/cop/team.rb#215 def each_corrector(report); end - # source://rubocop//lib/rubocop/cop/team.rb#254 + # source://rubocop//lib/rubocop/cop/team.rb#267 def handle_error(error, location, cop); end - # source://rubocop//lib/rubocop/cop/team.rb#246 + # source://rubocop//lib/rubocop/cop/team.rb#259 def handle_warning(error, location); end # @return [Commissioner::InvestigationReport] # - # source://rubocop//lib/rubocop/cop/team.rb#154 + # source://rubocop//lib/rubocop/cop/team.rb#162 def investigate_partial(cops, processed_source, offset:, original:); end - # source://rubocop//lib/rubocop/cop/team.rb#231 + # source://rubocop//lib/rubocop/cop/team.rb#242 def process_errors(file, errors); end - # source://rubocop//lib/rubocop/cop/team.rb#148 + # source://rubocop//lib/rubocop/cop/team.rb#156 def reset; end # @return [Array] # - # source://rubocop//lib/rubocop/cop/team.rb#160 + # source://rubocop//lib/rubocop/cop/team.rb#168 def roundup_relevant_cops(processed_source); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/team.rb#176 + # source://rubocop//lib/rubocop/cop/team.rb#184 def support_target_rails_version?(cop); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/team.rb#170 + # source://rubocop//lib/rubocop/cop/team.rb#178 def support_target_ruby_version?(cop); end - # source://rubocop//lib/rubocop/cop/team.rb#219 + # source://rubocop//lib/rubocop/cop/team.rb#230 def suppress_clobbering; end - # source://rubocop//lib/rubocop/cop/team.rb#225 + # source://rubocop//lib/rubocop/cop/team.rb#236 def validate_config; end class << self @@ -50410,19 +52571,19 @@ module RuboCop::Cop::Util private - # source://rubocop//lib/rubocop/cop/util.rb#35 + # source://rubocop//lib/rubocop/cop/util.rb#39 def add_parentheses(node, corrector); end - # source://rubocop//lib/rubocop/cop/util.rb#56 + # source://rubocop//lib/rubocop/cop/util.rb#60 def any_descendant?(node, *types); end - # source://rubocop//lib/rubocop/cop/util.rb#71 + # source://rubocop//lib/rubocop/cop/util.rb#75 def args_begin(node); end - # source://rubocop//lib/rubocop/cop/util.rb#83 + # source://rubocop//lib/rubocop/cop/util.rb#87 def args_end(node); end - # source://rubocop//lib/rubocop/cop/util.rb#104 + # source://rubocop//lib/rubocop/cop/util.rb#108 def begins_its_line?(range); end # This is a bad API @@ -50435,78 +52596,78 @@ module RuboCop::Cop::Util # source://rubocop//lib/rubocop/cop/util.rb#22 def comment_lines?(node); end - # source://rubocop//lib/rubocop/cop/util.rb#192 + # source://rubocop//lib/rubocop/cop/util.rb#198 def compatible_external_encoding_for?(src); end # If converting a string to Ruby string literal source code, must # double quotes be used? # - # source://rubocop//lib/rubocop/cop/util.rb#130 + # source://rubocop//lib/rubocop/cop/util.rb#134 def double_quotes_required?(string); end - # source://rubocop//lib/rubocop/cop/util.rb#144 + # source://rubocop//lib/rubocop/cop/util.rb#148 def escape_string(string); end # Returns, for example, a bare `if` node if the given node is an `if` # with calls chained to the end of it. # - # source://rubocop//lib/rubocop/cop/util.rb#114 + # source://rubocop//lib/rubocop/cop/util.rb#118 def first_part_of_call_chain(node); end - # source://rubocop//lib/rubocop/cop/util.rb#197 + # source://rubocop//lib/rubocop/cop/util.rb#203 def include_or_equal?(source, target); end - # source://rubocop//lib/rubocop/cop/util.rb#179 + # source://rubocop//lib/rubocop/cop/util.rb#185 def indent(node, offset: T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/util.rb#161 + # source://rubocop//lib/rubocop/cop/util.rb#165 def interpret_string_escapes(string); end - # source://rubocop//lib/rubocop/cop/util.rb#165 + # source://rubocop//lib/rubocop/cop/util.rb#169 def line(node_or_range); end - # source://rubocop//lib/rubocop/cop/util.rb#26 + # source://rubocop//lib/rubocop/cop/util.rb#30 def line_range(node); end - # source://rubocop//lib/rubocop/cop/util.rb#140 + # source://rubocop//lib/rubocop/cop/util.rb#144 def needs_escaping?(string); end - # source://rubocop//lib/rubocop/cop/util.rb#87 + # source://rubocop//lib/rubocop/cop/util.rb#91 def on_node(syms, sexp, excludes = T.unsafe(nil), &block); end - # source://rubocop//lib/rubocop/cop/util.rb#30 + # source://rubocop//lib/rubocop/cop/util.rb#34 def parentheses?(node); end - # source://rubocop//lib/rubocop/cop/util.rb#173 + # source://rubocop//lib/rubocop/cop/util.rb#177 def same_line?(node1, node2); end - # source://rubocop//lib/rubocop/cop/util.rb#148 + # source://rubocop//lib/rubocop/cop/util.rb#152 def to_string_literal(string); end - # source://rubocop//lib/rubocop/cop/util.rb#185 + # source://rubocop//lib/rubocop/cop/util.rb#191 def to_supported_styles(enforced_style); end - # source://rubocop//lib/rubocop/cop/util.rb#157 + # source://rubocop//lib/rubocop/cop/util.rb#161 def trim_string_interpolation_escape_character(str); end class << self - # source://rubocop//lib/rubocop/cop/util.rb#35 + # source://rubocop//lib/rubocop/cop/util.rb#39 def add_parentheses(node, corrector); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/util.rb#56 + # source://rubocop//lib/rubocop/cop/util.rb#60 def any_descendant?(node, *types); end - # source://rubocop//lib/rubocop/cop/util.rb#71 + # source://rubocop//lib/rubocop/cop/util.rb#75 def args_begin(node); end - # source://rubocop//lib/rubocop/cop/util.rb#83 + # source://rubocop//lib/rubocop/cop/util.rb#87 def args_end(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/util.rb#104 + # source://rubocop//lib/rubocop/cop/util.rb#108 def begins_its_line?(range); end # This is a bad API @@ -50527,62 +52688,62 @@ module RuboCop::Cop::Util # # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/util.rb#130 + # source://rubocop//lib/rubocop/cop/util.rb#134 def double_quotes_required?(string); end - # source://rubocop//lib/rubocop/cop/util.rb#144 + # source://rubocop//lib/rubocop/cop/util.rb#148 def escape_string(string); end # Returns, for example, a bare `if` node if the given node is an `if` # with calls chained to the end of it. # - # source://rubocop//lib/rubocop/cop/util.rb#114 + # source://rubocop//lib/rubocop/cop/util.rb#118 def first_part_of_call_chain(node); end - # source://rubocop//lib/rubocop/cop/util.rb#179 + # source://rubocop//lib/rubocop/cop/util.rb#185 def indent(node, offset: T.unsafe(nil)); end - # source://rubocop//lib/rubocop/cop/util.rb#161 + # source://rubocop//lib/rubocop/cop/util.rb#165 def interpret_string_escapes(string); end - # source://rubocop//lib/rubocop/cop/util.rb#165 + # source://rubocop//lib/rubocop/cop/util.rb#169 def line(node_or_range); end - # source://rubocop//lib/rubocop/cop/util.rb#26 + # source://rubocop//lib/rubocop/cop/util.rb#30 def line_range(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/util.rb#140 + # source://rubocop//lib/rubocop/cop/util.rb#144 def needs_escaping?(string); end # @yield [sexp] # - # source://rubocop//lib/rubocop/cop/util.rb#87 + # source://rubocop//lib/rubocop/cop/util.rb#91 def on_node(syms, sexp, excludes = T.unsafe(nil), &block); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/util.rb#30 + # source://rubocop//lib/rubocop/cop/util.rb#34 def parentheses?(node); end # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/util.rb#173 + # source://rubocop//lib/rubocop/cop/util.rb#177 def same_line?(node1, node2); end - # source://rubocop//lib/rubocop/cop/util.rb#148 + # source://rubocop//lib/rubocop/cop/util.rb#152 def to_string_literal(string); end - # source://rubocop//lib/rubocop/cop/util.rb#185 + # source://rubocop//lib/rubocop/cop/util.rb#191 def to_supported_styles(enforced_style); end - # source://rubocop//lib/rubocop/cop/util.rb#157 + # source://rubocop//lib/rubocop/cop/util.rb#161 def trim_string_interpolation_escape_character(str); end end end -# source://rubocop//lib/rubocop/cop/util.rb#99 +# source://rubocop//lib/rubocop/cop/util.rb#103 RuboCop::Cop::Util::LINE_BEGINS_REGEX_CACHE = T.let(T.unsafe(nil), Hash) # Match literal regex characters, not including anchors, character @@ -50594,7 +52755,7 @@ RuboCop::Cop::Util::LITERAL_REGEX = T.let(T.unsafe(nil), Regexp) # Arbitrarily chosen value, should be enough to cover # the most nested source code in real world projects. # -# source://rubocop//lib/rubocop/cop/util.rb#98 +# source://rubocop//lib/rubocop/cop/util.rb#102 RuboCop::Cop::Util::MAX_LINE_BEGINS_REGEX_INDEX = T.let(T.unsafe(nil), Integer) # source://rubocop//lib/rubocop/cop/utils/format_string.rb#5 @@ -50749,6 +52910,55 @@ RuboCop::Cop::Utils::FormatString::TYPE = T.let(T.unsafe(nil), Regexp) # source://rubocop//lib/rubocop/cop/utils/format_string.rb#12 RuboCop::Cop::Utils::FormatString::WIDTH = T.let(T.unsafe(nil), Regexp) +# Helper to abstract complexity of building range pairs +# with octal escape reconstruction (needed for regexp_parser < 2.7). +# +# source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#8 +class RuboCop::Cop::Utils::RegexpRanges + # @return [RegexpRanges] a new instance of RegexpRanges + # + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#11 + def initialize(root); end + + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#18 + def compound_token; end + + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#24 + def pairs; end + + # Returns the value of attribute root. + # + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#9 + def root; end + + private + + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#78 + def compose_range(expressions, current); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#90 + def escaped_octal?(expr); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#94 + def octal_digit?(char); end + + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#98 + def pop_octal_digits(expressions); end + + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#44 + def populate(expr); end + + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#32 + def populate_all; end + + # source://rubocop//lib/rubocop/cop/utils/regexp_ranges.rb#63 + def process_set(expressions, current); end +end + # This force provides a way to track local variables and scopes of Ruby. # Cops interact with this force need to override some of the hook methods. # @@ -50778,59 +52988,59 @@ class RuboCop::Cop::VariableForce < ::RuboCop::Cop::Force # # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#76 + # source://rubocop//lib/rubocop/cop/variable_force.rb#79 def investigate(processed_source); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#85 + # source://rubocop//lib/rubocop/cop/variable_force.rb#88 def process_node(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#71 + # source://rubocop//lib/rubocop/cop/variable_force.rb#74 def variable_table; end private - # source://rubocop//lib/rubocop/cop/variable_force.rb#368 + # source://rubocop//lib/rubocop/cop/variable_force.rb#380 def after_declaring_variable(arg); end - # source://rubocop//lib/rubocop/cop/variable_force.rb#368 + # source://rubocop//lib/rubocop/cop/variable_force.rb#380 def after_entering_scope(arg); end - # source://rubocop//lib/rubocop/cop/variable_force.rb#368 + # source://rubocop//lib/rubocop/cop/variable_force.rb#380 def after_leaving_scope(arg); end - # source://rubocop//lib/rubocop/cop/variable_force.rb#368 + # source://rubocop//lib/rubocop/cop/variable_force.rb#380 def before_declaring_variable(arg); end - # source://rubocop//lib/rubocop/cop/variable_force.rb#368 + # source://rubocop//lib/rubocop/cop/variable_force.rb#380 def before_entering_scope(arg); end - # source://rubocop//lib/rubocop/cop/variable_force.rb#368 + # source://rubocop//lib/rubocop/cop/variable_force.rb#380 def before_leaving_scope(arg); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#339 + # source://rubocop//lib/rubocop/cop/variable_force.rb#351 def descendant_reference(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#329 + # source://rubocop//lib/rubocop/cop/variable_force.rb#341 def each_descendant_reference(loop_node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#314 + # source://rubocop//lib/rubocop/cop/variable_force.rb#326 def find_variables_in_loop(loop_node); end # This is called for each scope recursively. # # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#94 + # source://rubocop//lib/rubocop/cop/variable_force.rb#97 def inspect_variables_in_scope(scope_node); end # Mark all assignments which are referenced in the same loop @@ -50839,104 +53049,109 @@ class RuboCop::Cop::VariableForce < ::RuboCop::Cop::Force # # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#295 + # source://rubocop//lib/rubocop/cop/variable_force.rb#307 def mark_assignments_as_referenced_in_loop(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#126 + # source://rubocop//lib/rubocop/cop/variable_force.rb#130 def node_handler_method_name(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#100 + # source://rubocop//lib/rubocop/cop/variable_force.rb#103 def process_children(origin_node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#231 + # source://rubocop//lib/rubocop/cop/variable_force.rb#243 def process_loop(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#160 + # source://rubocop//lib/rubocop/cop/variable_force.rb#182 + def process_pattern_match_variable(node); end + + # @api private + # + # source://rubocop//lib/rubocop/cop/variable_force.rb#164 def process_regexp_named_captures(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#246 + # source://rubocop//lib/rubocop/cop/variable_force.rb#258 def process_rescue(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#265 + # source://rubocop//lib/rubocop/cop/variable_force.rb#277 def process_scope(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#284 + # source://rubocop//lib/rubocop/cop/variable_force.rb#296 def process_send(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#142 + # source://rubocop//lib/rubocop/cop/variable_force.rb#146 def process_variable_assignment(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#130 + # source://rubocop//lib/rubocop/cop/variable_force.rb#134 def process_variable_declaration(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#219 + # source://rubocop//lib/rubocop/cop/variable_force.rb#231 def process_variable_multiple_assignment(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#184 + # source://rubocop//lib/rubocop/cop/variable_force.rb#196 def process_variable_operator_assignment(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#226 + # source://rubocop//lib/rubocop/cop/variable_force.rb#238 def process_variable_referencing(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#257 + # source://rubocop//lib/rubocop/cop/variable_force.rb#269 def process_zero_arity_super(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#178 + # source://rubocop//lib/rubocop/cop/variable_force.rb#190 def regexp_captured_names(node); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/variable_force.rb#351 + # source://rubocop//lib/rubocop/cop/variable_force.rb#363 def scanned_node?(node); end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#355 + # source://rubocop//lib/rubocop/cop/variable_force.rb#367 def scanned_nodes; end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#108 + # source://rubocop//lib/rubocop/cop/variable_force.rb#111 def skip_children!; end # @api private # - # source://rubocop//lib/rubocop/cop/variable_force.rb#278 + # source://rubocop//lib/rubocop/cop/variable_force.rb#290 def twisted_nodes(node); end end # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#32 +# source://rubocop//lib/rubocop/cop/variable_force.rb#35 RuboCop::Cop::VariableForce::ARGUMENT_DECLARATION_TYPES = T.let(T.unsafe(nil), Array) # This class represents each assignment of a variable. @@ -51027,7 +53242,10 @@ class RuboCop::Cop::VariableForce::Assignment private - # source://rubocop//lib/rubocop/cop/variable_force/assignment.rb#120 + # source://rubocop//lib/rubocop/cop/variable_force/assignment.rb#125 + def find_multiple_assignment_node(grandparent_node); end + + # source://rubocop//lib/rubocop/cop/variable_force/assignment.rb#121 def for_assignment_node; end # source://rubocop//lib/rubocop/cop/variable_force/assignment.rb#104 @@ -51036,7 +53254,7 @@ class RuboCop::Cop::VariableForce::Assignment # source://rubocop//lib/rubocop/cop/variable_force/assignment.rb#96 def operator_assignment_node; end - # source://rubocop//lib/rubocop/cop/variable_force/assignment.rb#113 + # source://rubocop//lib/rubocop/cop/variable_force/assignment.rb#114 def rest_assignment_node; end end @@ -51045,12 +53263,12 @@ RuboCop::Cop::VariableForce::Assignment::MULTIPLE_LEFT_HAND_SIDE_TYPE = T.let(T. # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#65 +# source://rubocop//lib/rubocop/cop/variable_force.rb#68 class RuboCop::Cop::VariableForce::AssignmentReference < ::Struct # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/variable_force.rb#66 + # source://rubocop//lib/rubocop/cop/variable_force.rb#69 def assignment?; end # Returns the value of attribute node @@ -51490,32 +53708,37 @@ end # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#39 +# source://rubocop//lib/rubocop/cop/variable_force.rb#42 RuboCop::Cop::VariableForce::LOGICAL_OPERATOR_ASSIGNMENT_TYPES = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#48 +# source://rubocop//lib/rubocop/cop/variable_force.rb#51 RuboCop::Cop::VariableForce::LOOP_TYPES = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#42 +# source://rubocop//lib/rubocop/cop/variable_force.rb#45 RuboCop::Cop::VariableForce::MULTIPLE_ASSIGNMENT_TYPE = T.let(T.unsafe(nil), Symbol) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#112 +# source://rubocop//lib/rubocop/cop/variable_force.rb#115 RuboCop::Cop::VariableForce::NODE_HANDLER_METHOD_NAMES = T.let(T.unsafe(nil), Hash) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#40 +# source://rubocop//lib/rubocop/cop/variable_force.rb#43 RuboCop::Cop::VariableForce::OPERATOR_ASSIGNMENT_TYPES = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#47 +# source://rubocop//lib/rubocop/cop/variable_force.rb#30 +RuboCop::Cop::VariableForce::PATTERN_MATCH_VARIABLE_TYPE = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://rubocop//lib/rubocop/cop/variable_force.rb#50 RuboCop::Cop::VariableForce::POST_CONDITION_LOOP_TYPES = T.let(T.unsafe(nil), Array) # @api private @@ -51525,12 +53748,12 @@ RuboCop::Cop::VariableForce::REGEXP_NAMED_CAPTURE_TYPE = T.let(T.unsafe(nil), Sy # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#50 +# source://rubocop//lib/rubocop/cop/variable_force.rb#53 RuboCop::Cop::VariableForce::RESCUE_TYPE = T.let(T.unsafe(nil), Symbol) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#43 +# source://rubocop//lib/rubocop/cop/variable_force.rb#46 RuboCop::Cop::VariableForce::REST_ASSIGNMENT_TYPE = T.let(T.unsafe(nil), Symbol) # This class represents each reference of a variable. @@ -51580,12 +53803,12 @@ RuboCop::Cop::VariableForce::Reference::VARIABLE_REFERENCE_TYPES = T.let(T.unsaf # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#55 +# source://rubocop//lib/rubocop/cop/variable_force.rb#58 RuboCop::Cop::VariableForce::SCOPE_TYPES = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#57 +# source://rubocop//lib/rubocop/cop/variable_force.rb#60 RuboCop::Cop::VariableForce::SEND_TYPE = T.let(T.unsafe(nil), Symbol) # A Scope represents a context of local variable visibility. @@ -51664,7 +53887,7 @@ RuboCop::Cop::VariableForce::Scope::OUTER_SCOPE_CHILD_INDICES = T.let(T.unsafe(n # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#54 +# source://rubocop//lib/rubocop/cop/variable_force.rb#57 RuboCop::Cop::VariableForce::TWISTED_SCOPE_TYPES = T.let(T.unsafe(nil), Array) # @api private @@ -51674,12 +53897,12 @@ RuboCop::Cop::VariableForce::VARIABLE_ASSIGNMENT_TYPE = T.let(T.unsafe(nil), Sym # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#30 +# source://rubocop//lib/rubocop/cop/variable_force.rb#31 RuboCop::Cop::VariableForce::VARIABLE_ASSIGNMENT_TYPES = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#45 +# source://rubocop//lib/rubocop/cop/variable_force.rb#48 RuboCop::Cop::VariableForce::VARIABLE_REFERENCE_TYPE = T.let(T.unsafe(nil), Symbol) # A Variable represents existence of a local variable. @@ -51796,12 +54019,12 @@ RuboCop::Cop::VariableForce::Variable::VARIABLE_DECLARATION_TYPES = T.let(T.unsa # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#59 +# source://rubocop//lib/rubocop/cop/variable_force.rb#62 class RuboCop::Cop::VariableForce::VariableReference < ::Struct # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/cop/variable_force.rb#60 + # source://rubocop//lib/rubocop/cop/variable_force.rb#63 def assignment?; end # Returns the value of attribute name @@ -51883,7 +54106,7 @@ end # @api private # -# source://rubocop//lib/rubocop/cop/variable_force.rb#52 +# source://rubocop//lib/rubocop/cop/variable_force.rb#55 RuboCop::Cop::VariableForce::ZERO_ARITY_SUPER_TYPE = T.let(T.unsafe(nil), Symbol) # Help methods for determining node visibility. @@ -51937,176 +54160,181 @@ RuboCop::Cop::VisibilityHelp::VISIBILITY_SCOPES = T.let(T.unsafe(nil), Set) class RuboCop::DirectiveComment # @return [DirectiveComment] a new instance of DirectiveComment # - # source://rubocop//lib/rubocop/directive_comment.rb#30 + # source://rubocop//lib/rubocop/directive_comment.rb#32 def initialize(comment, cop_registry = T.unsafe(nil)); end # Checks if all cops specified in this directive # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#80 + # source://rubocop//lib/rubocop/directive_comment.rb#82 def all_cops?; end # Returns the value of attribute comment. # - # source://rubocop//lib/rubocop/directive_comment.rb#28 + # source://rubocop//lib/rubocop/directive_comment.rb#30 def comment; end # Returns array of specified in this directive cop names # - # source://rubocop//lib/rubocop/directive_comment.rb#85 + # source://rubocop//lib/rubocop/directive_comment.rb#87 def cop_names; end # Returns the value of attribute cop_registry. # - # source://rubocop//lib/rubocop/directive_comment.rb#28 + # source://rubocop//lib/rubocop/directive_comment.rb#30 def cop_registry; end # Returns the value of attribute cops. # - # source://rubocop//lib/rubocop/directive_comment.rb#28 + # source://rubocop//lib/rubocop/directive_comment.rb#30 def cops; end # Returns array of specified in this directive department names # when all department disabled # - # source://rubocop//lib/rubocop/directive_comment.rb#91 + # source://rubocop//lib/rubocop/directive_comment.rb#93 def department_names; end - # source://rubocop//lib/rubocop/directive_comment.rb#105 + # source://rubocop//lib/rubocop/directive_comment.rb#107 def directive_count; end # Checks if this directive disables cops # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#60 + # source://rubocop//lib/rubocop/directive_comment.rb#62 def disabled?; end # Checks if this directive disables all cops # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#75 + # source://rubocop//lib/rubocop/directive_comment.rb#77 def disabled_all?; end # Checks if this directive enables cops # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#65 + # source://rubocop//lib/rubocop/directive_comment.rb#67 def enabled?; end # Checks if this directive enables all cops # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#70 + # source://rubocop//lib/rubocop/directive_comment.rb#72 def enabled_all?; end # Checks if directive departments include cop # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#96 + # source://rubocop//lib/rubocop/directive_comment.rb#98 def in_directive_department?(cop); end # Returns line number for directive # - # source://rubocop//lib/rubocop/directive_comment.rb#110 + # source://rubocop//lib/rubocop/directive_comment.rb#112 def line_number; end # Checks if this directive contains all the given cop names # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#42 + # source://rubocop//lib/rubocop/directive_comment.rb#44 def match?(cop_names); end # Returns match captures to directive comment pattern # - # source://rubocop//lib/rubocop/directive_comment.rb#55 + # source://rubocop//lib/rubocop/directive_comment.rb#57 def match_captures; end # Returns the value of attribute mode. # - # source://rubocop//lib/rubocop/directive_comment.rb#28 + # source://rubocop//lib/rubocop/directive_comment.rb#30 def mode; end # Checks if cop department has already used in directive comment # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#101 + # source://rubocop//lib/rubocop/directive_comment.rb#103 def overridden_by_department?(cop); end - # source://rubocop//lib/rubocop/directive_comment.rb#46 + # source://rubocop//lib/rubocop/directive_comment.rb#48 def range; end # Checks if this directive relates to single line # # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#37 + # source://rubocop//lib/rubocop/directive_comment.rb#39 def single_line?; end private - # source://rubocop//lib/rubocop/directive_comment.rb#130 + # source://rubocop//lib/rubocop/directive_comment.rb#133 def all_cop_names; end - # source://rubocop//lib/rubocop/directive_comment.rb#134 + # source://rubocop//lib/rubocop/directive_comment.rb#137 def cop_names_for_department(department); end # @return [Boolean] # - # source://rubocop//lib/rubocop/directive_comment.rb#126 + # source://rubocop//lib/rubocop/directive_comment.rb#129 def department?(name); end - # source://rubocop//lib/rubocop/directive_comment.rb#140 - def exclude_redundant_directive_cop(cops); end + # source://rubocop//lib/rubocop/directive_comment.rb#142 + def exclude_lint_department_cops(cops); end - # source://rubocop//lib/rubocop/directive_comment.rb#120 + # source://rubocop//lib/rubocop/directive_comment.rb#122 def parsed_cop_names; end - # source://rubocop//lib/rubocop/directive_comment.rb#116 + # source://rubocop//lib/rubocop/directive_comment.rb#118 def splitted_cops_string; end class << self - # source://rubocop//lib/rubocop/directive_comment.rb#24 + # source://rubocop//lib/rubocop/directive_comment.rb#26 def before_comment(line); end end end # @api private # -# source://rubocop//lib/rubocop/directive_comment.rb#17 +# source://rubocop//lib/rubocop/directive_comment.rb#19 RuboCop::DirectiveComment::COPS_PATTERN = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/directive_comment.rb#15 +# source://rubocop//lib/rubocop/directive_comment.rb#17 RuboCop::DirectiveComment::COP_NAMES_PATTERN = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/directive_comment.rb#13 +# source://rubocop//lib/rubocop/directive_comment.rb#15 RuboCop::DirectiveComment::COP_NAME_PATTERN = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/directive_comment.rb#19 +# source://rubocop//lib/rubocop/directive_comment.rb#21 RuboCop::DirectiveComment::DIRECTIVE_COMMENT_REGEXP = T.let(T.unsafe(nil), Regexp) +# @api private +# +# source://rubocop//lib/rubocop/directive_comment.rb#9 +RuboCop::DirectiveComment::LINT_DEPARTMENT = T.let(T.unsafe(nil), String) + # @api private # # source://rubocop//lib/rubocop/directive_comment.rb#11 -RuboCop::DirectiveComment::REDUNDANT_DIRECTIVE_COP = T.let(T.unsafe(nil), String) +RuboCop::DirectiveComment::LINT_REDUNDANT_DIRECTIVE_COP = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/directive_comment.rb#9 -RuboCop::DirectiveComment::REDUNDANT_DIRECTIVE_COP_DEPARTMENT = T.let(T.unsafe(nil), String) +# source://rubocop//lib/rubocop/directive_comment.rb#13 +RuboCop::DirectiveComment::LINT_SYNTAX_COP = T.let(T.unsafe(nil), String) # An Error exception is different from an Offense with severity 'error' # When this exception is raised, it means that RuboCop is unable to perform @@ -52228,13 +54456,10 @@ end # # source://rubocop//lib/rubocop/ext/regexp_node.rb#6 module RuboCop::Ext::RegexpNode - # Please remove this `else` branch when support for regexp_parser 1.8 will be dropped. - # It's for compatibility with regexp_parser 1.8 and will never be maintained. - # - # source://rubocop//lib/rubocop/ext/regexp_node.rb#19 + # source://rubocop//lib/rubocop/ext/regexp_node.rb#18 def assign_properties(*_arg0); end - # source://rubocop//lib/rubocop/ext/regexp_node.rb#53 + # source://rubocop//lib/rubocop/ext/regexp_node.rb#31 def each_capture(named: T.unsafe(nil)); end # Note: we extend Regexp nodes to provide `loc` and `expression` @@ -52247,7 +54472,12 @@ module RuboCop::Ext::RegexpNode private - # source://rubocop//lib/rubocop/ext/regexp_node.rb#68 + # @return [Boolean] + # + # source://rubocop//lib/rubocop/ext/regexp_node.rb#43 + def named_capturing?(exp, event, named); end + + # source://rubocop//lib/rubocop/ext/regexp_node.rb#51 def with_interpolations_blanked; end end @@ -52268,7 +54498,7 @@ module RuboCop::Ext::RegexpParser::Expression; end module RuboCop::Ext::RegexpParser::Expression::Base # Shortcut to `loc.expression` # - # source://rubocop//lib/rubocop/ext/regexp_parser.rb#27 + # source://rubocop//lib/rubocop/ext/regexp_parser.rb#26 def expression; end # E.g. @@ -52281,7 +54511,7 @@ module RuboCop::Ext::RegexpParser::Expression::Base # # Please open issue if you need other locations # - # source://rubocop//lib/rubocop/ext/regexp_parser.rb#61 + # source://rubocop//lib/rubocop/ext/regexp_parser.rb#44 def loc; end # Returns the value of attribute origin. @@ -52298,15 +54528,15 @@ module RuboCop::Ext::RegexpParser::Expression::Base private - # source://rubocop//lib/rubocop/ext/regexp_parser.rb#67 + # source://rubocop//lib/rubocop/ext/regexp_parser.rb#50 def build_location; end end # Provide `CharacterSet` with `begin` and `end` locations. # -# source://rubocop//lib/rubocop/ext/regexp_parser.rb#77 +# source://rubocop//lib/rubocop/ext/regexp_parser.rb#62 module RuboCop::Ext::RegexpParser::Expression::CharacterSet - # source://rubocop//lib/rubocop/ext/regexp_parser.rb#78 + # source://rubocop//lib/rubocop/ext/regexp_parser.rb#63 def build_location; end end @@ -52426,32 +54656,31 @@ end module RuboCop::FileFinder # @api private # - # source://rubocop//lib/rubocop/file_finder.rb#17 + # source://rubocop//lib/rubocop/file_finder.rb#13 def find_file_upwards(filename, start_dir, stop_dir = T.unsafe(nil)); end # @api private # - # source://rubocop//lib/rubocop/file_finder.rb#24 + # source://rubocop//lib/rubocop/file_finder.rb#20 def find_last_file_upwards(filename, start_dir, stop_dir = T.unsafe(nil)); end private # @api private # - # source://rubocop//lib/rubocop/file_finder.rb#32 + # source://rubocop//lib/rubocop/file_finder.rb#28 def traverse_files_upwards(filename, start_dir, stop_dir); end class << self # @api private # - # source://rubocop//lib/rubocop/file_finder.rb#9 - def root_level=(level); end + # source://rubocop//lib/rubocop/file_finder.rb#10 + def root_level; end # @api private - # @return [Boolean] # - # source://rubocop//lib/rubocop/file_finder.rb#13 - def root_level?(path, stop_dir); end + # source://rubocop//lib/rubocop/file_finder.rb#10 + def root_level=(_arg0); end end end @@ -52620,10 +54849,10 @@ class RuboCop::Formatter::ClangStyleFormatter < ::RuboCop::Formatter::SimpleText private - # source://rubocop//lib/rubocop/formatter/clang_style_formatter.rb#51 + # source://rubocop//lib/rubocop/formatter/clang_style_formatter.rb#47 def report_highlighted_area(highlighted_area); end - # source://rubocop//lib/rubocop/formatter/clang_style_formatter.rb#41 + # source://rubocop//lib/rubocop/formatter/clang_style_formatter.rb#37 def report_line(location); end # source://rubocop//lib/rubocop/formatter/clang_style_formatter.rb#17 @@ -52631,7 +54860,7 @@ class RuboCop::Formatter::ClangStyleFormatter < ::RuboCop::Formatter::SimpleText # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/clang_style_formatter.rb#37 + # source://rubocop//lib/rubocop/formatter/clang_style_formatter.rb#33 def valid_line?(offense); end end @@ -52687,100 +54916,113 @@ class RuboCop::Formatter::DisabledConfigFormatter < ::RuboCop::Formatter::BaseFo # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#27 def initialize(output, options = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#39 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#40 def file_finished(file, offenses); end # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#33 - def file_started(_file, _file_info); end + def file_started(_file, options); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#47 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#48 def finished(_inspected_files); end private # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#68 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#69 def auto_gen_enforced_style?; end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#72 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#73 def command; end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#156 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#165 def cop_config_params(default_cfg, cfg); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#176 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#185 def default_config(cop_name); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#220 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#229 def excludes(offending_files, cop_name, parent); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#191 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#200 def filtered_config(cfg); end + # Returns true if the given arr include the given elm or if any of the + # given arr is a regexp that matches the given elm. + # # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#241 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#277 + def include_or_match?(arr, elm); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#250 def merge_mode_for_exclude?(cfg); end # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#262 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#271 def no_exclude_limit?; end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#101 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#102 def output_cop(cop_name, offense_count); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#128 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#137 def output_cop_comments(output_buffer, cfg, cop_name, offense_count); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#180 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#189 def output_cop_config(output_buffer, cfg, cop_name); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#163 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#172 def output_cop_param_comments(output_buffer, params, default_cfg); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#210 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#219 def output_exclude_list(output_buffer, offending_files, cop_name); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#245 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#254 def output_exclude_path(output_buffer, exclude_path, parent); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#199 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#208 def output_offending_files(output_buffer, cfg, cop_name); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#95 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#96 def output_offenses; end # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#258 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#267 def safe_autocorrect?(config); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#115 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#116 def set_max(cfg, cop_name); end # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#64 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#125 + def should_set_max?(cop_name); end + + # @return [Boolean] + # + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#65 def show_offense_counts?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#60 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#61 def show_timestamp?; end # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#148 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#157 def supports_safe_autocorrect?(cop_class, default_cfg); end # @return [Boolean] # - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#152 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#161 def supports_unsafe_autocorrect?(cop_class, default_cfg); end - # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#91 + # source://rubocop//lib/rubocop/formatter/disabled_config_formatter.rb#92 def timestamp; end class << self @@ -52850,43 +55092,46 @@ end class RuboCop::Formatter::FormatterSet < ::Array # @return [FormatterSet] a new instance of FormatterSet # - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#39 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#40 def initialize(options = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#55 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#56 def add_formatter(formatter_type, output_path = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#67 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#68 def close_output_files; end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#50 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#51 def file_finished(file, offenses); end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#44 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#45 def file_started(file, options); end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#34 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#35 def finished(*args); end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#34 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#35 def started(*args); end private - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#86 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#87 def builtin_formatter_class(specified_key); end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#99 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#105 def custom_formatter_class(specified_class_name); end - # source://rubocop//lib/rubocop/formatter/formatter_set.rb#75 + # source://rubocop//lib/rubocop/formatter/formatter_set.rb#76 def formatter_class(formatter_type); end end # source://rubocop//lib/rubocop/formatter/formatter_set.rb#11 RuboCop::Formatter::FormatterSet::BUILTIN_FORMATTERS_FOR_KEYS = T.let(T.unsafe(nil), Hash) -# source://rubocop//lib/rubocop/formatter/formatter_set.rb#31 +# source://rubocop//lib/rubocop/formatter/formatter_set.rb#30 +RuboCop::Formatter::FormatterSet::BUILTIN_FORMATTER_NAMES = T.let(T.unsafe(nil), Array) + +# source://rubocop//lib/rubocop/formatter/formatter_set.rb#32 RuboCop::Formatter::FormatterSet::FORMATTER_APIS = T.let(T.unsafe(nil), Array) # This formatter displays a progress bar and shows details of offenses as @@ -52923,68 +55168,84 @@ RuboCop::Formatter::FuubarStyleFormatter::RESET_SEQUENCE = T.let(T.unsafe(nil), # This formatter formats report data as GitHub Workflow commands resulting # in GitHub check annotations when run within GitHub Actions. # -# source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#7 +# source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#7 class RuboCop::Formatter::GitHubActionsFormatter < ::RuboCop::Formatter::BaseFormatter - # source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#14 + # source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#14 def file_finished(file, offenses); end - # source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#18 + # source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#18 def finished(_inspected_files); end - # source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#10 + # source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#10 def started(_target_files); end private - # source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#29 + # source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#29 def github_escape(string); end - # source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#41 + # source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#41 def github_severity(offense); end - # source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#33 + # source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#33 def minimum_severity_to_fail; end - # source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#45 + # source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#45 def report_offense(file, offense); end end -# source://rubocop//lib/rubocop/formatter/git_hub_actions_formatter.rb#8 +# source://rubocop//lib/rubocop/formatter/github_actions_formatter.rb#8 RuboCop::Formatter::GitHubActionsFormatter::ESCAPE_MAP = T.let(T.unsafe(nil), Hash) # This formatter saves the output as an html file. # -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#11 +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#9 class RuboCop::Formatter::HTMLFormatter < ::RuboCop::Formatter::BaseFormatter # @return [HTMLFormatter] a new instance of HTMLFormatter # - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#30 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#29 def initialize(output, options = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#40 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#39 def file_finished(file, offenses); end # Returns the value of attribute files. # - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#28 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#27 def files; end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#45 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#44 def finished(inspected_files); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#51 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#50 def render_html; end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#36 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#35 def started(target_files); end # Returns the value of attribute summary. # - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#28 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#27 def summary; end end -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#15 +# This class provides helper methods used in the ERB CSS template. +# +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#137 +class RuboCop::Formatter::HTMLFormatter::CSSContext + # Make Kernel#binding public. + # + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#148 + def binding; end +end + +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#138 +RuboCop::Formatter::HTMLFormatter::CSSContext::SEVERITY_COLORS = T.let(T.unsafe(nil), Hash) + +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#12 +RuboCop::Formatter::HTMLFormatter::CSS_PATH = T.let(T.unsafe(nil), String) + +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#14 class RuboCop::Formatter::HTMLFormatter::Color < ::Struct # Returns the value of attribute alpha # @@ -53008,7 +55269,7 @@ class RuboCop::Formatter::HTMLFormatter::Color < ::Struct # @return [Object] the newly set value def blue=(_); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#20 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#19 def fade_out(amount); end # Returns the value of attribute green @@ -53033,7 +55294,7 @@ class RuboCop::Formatter::HTMLFormatter::Color < ::Struct # @return [Object] the newly set value def red=(_); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#16 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#15 def to_s; end class << self @@ -53045,68 +55306,68 @@ class RuboCop::Formatter::HTMLFormatter::Color < ::Struct end end -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#12 +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#10 RuboCop::Formatter::HTMLFormatter::ELLIPSES = T.let(T.unsafe(nil), String) # This class provides helper methods used in the ERB template. # -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#62 +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#63 class RuboCop::Formatter::HTMLFormatter::ERBContext include ::RuboCop::PathUtil include ::RuboCop::Formatter::TextUtil # @return [ERBContext] a new instance of ERBContext # - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#78 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#71 def initialize(files, summary); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#125 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#118 def base64_encoded_logo_image; end # Make Kernel#binding public. # - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#85 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#78 def binding; end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#90 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#83 def decorated_message(offense); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#121 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#114 def escape(string); end # Returns the value of attribute files. # - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#76 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#69 def files; end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#101 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#94 def highlight_source_tag(offense); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#94 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#87 def highlighted_source_line(offense); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#117 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#110 def possible_ellipses(location); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#112 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#126 + def render_css; end + + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#105 def source_after_highlight(offense); end - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#107 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#100 def source_before_highlight(offense); end # Returns the value of attribute summary. # - # source://rubocop//lib/rubocop/formatter/html_formatter.rb#76 + # source://rubocop//lib/rubocop/formatter/html_formatter.rb#69 def summary; end end -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#74 +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#67 RuboCop::Formatter::HTMLFormatter::ERBContext::LOGO_IMAGE_PATH = T.let(T.unsafe(nil), String) -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#66 -RuboCop::Formatter::HTMLFormatter::ERBContext::SEVERITY_COLORS = T.let(T.unsafe(nil), Hash) - -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#26 +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#25 class RuboCop::Formatter::HTMLFormatter::FileOffenses < ::Struct # Returns the value of attribute offenses # @@ -53139,7 +55400,7 @@ class RuboCop::Formatter::HTMLFormatter::FileOffenses < ::Struct end end -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#25 +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#24 class RuboCop::Formatter::HTMLFormatter::Summary < ::Struct # Returns the value of attribute inspected_files # @@ -53183,27 +55444,27 @@ class RuboCop::Formatter::HTMLFormatter::Summary < ::Struct end end -# source://rubocop//lib/rubocop/formatter/html_formatter.rb#13 +# source://rubocop//lib/rubocop/formatter/html_formatter.rb#11 RuboCop::Formatter::HTMLFormatter::TEMPLATE_PATH = T.let(T.unsafe(nil), String) # This formatter formats the report data in JSON format. # -# source://rubocop//lib/rubocop/formatter/json_formatter.rb#9 +# source://rubocop//lib/rubocop/formatter/json_formatter.rb#8 class RuboCop::Formatter::JSONFormatter < ::RuboCop::Formatter::BaseFormatter include ::RuboCop::PathUtil # @return [JSONFormatter] a new instance of JSONFormatter # - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#14 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#13 def initialize(output, options = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#23 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#22 def file_finished(file, offenses); end - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#28 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#27 def finished(inspected_files); end - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#43 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#42 def hash_for_file(file, offenses); end # TODO: Consider better solution for Offense#real_column. @@ -53211,21 +55472,21 @@ class RuboCop::Formatter::JSONFormatter < ::RuboCop::Formatter::BaseFormatter # So, the minimum value of `last_column` should be 1. # And non-zero value of `last_column` should be used as is. # - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#65 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#64 def hash_for_location(offense); end - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#50 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#49 def hash_for_offense(offense); end - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#33 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#32 def metadata_hash; end # Returns the value of attribute output_hash. # - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#12 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#11 def output_hash; end - # source://rubocop//lib/rubocop/formatter/json_formatter.rb#19 + # source://rubocop//lib/rubocop/formatter/json_formatter.rb#18 def started(target_files); end end @@ -53331,6 +55592,9 @@ end # # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#16 class RuboCop::Formatter::OffenseCountFormatter < ::RuboCop::Formatter::BaseFormatter + # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#81 + def cop_information(cop_name); end + # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#42 def file_finished(_file, offenses); end @@ -53342,7 +55606,7 @@ class RuboCop::Formatter::OffenseCountFormatter < ::RuboCop::Formatter::BaseForm # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#17 def offense_counts; end - # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#74 + # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#73 def ordered_offense_counts(offense_counts); end # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#56 @@ -53351,7 +55615,7 @@ class RuboCop::Formatter::OffenseCountFormatter < ::RuboCop::Formatter::BaseForm # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#19 def started(target_files); end - # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#78 + # source://rubocop//lib/rubocop/formatter/offense_count_formatter.rb#77 def total_offense_count(offense_counts); end end @@ -53547,10 +55811,10 @@ class RuboCop::Formatter::TapFormatter < ::RuboCop::Formatter::ClangStyleFormatt private - # source://rubocop//lib/rubocop/formatter/tap_formatter.rb#66 + # source://rubocop//lib/rubocop/formatter/tap_formatter.rb#62 def annotate_message(msg); end - # source://rubocop//lib/rubocop/formatter/tap_formatter.rb#70 + # source://rubocop//lib/rubocop/formatter/tap_formatter.rb#66 def message(offense); end # source://rubocop//lib/rubocop/formatter/tap_formatter.rb#39 @@ -53617,38 +55881,338 @@ end # source://rubocop//lib/rubocop/options.rb#8 class RuboCop::IncorrectCopNameError < ::StandardError; end +# The RuboCop's built-in LSP module. +# +# source://rubocop//lib/rubocop/lsp.rb#5 +module RuboCop::LSP + private + + # Disable LSP. + # + # @return [void] + # + # source://rubocop//lib/rubocop/lsp.rb#25 + def disable(&block); end + + # Enable LSP. + # + # @return [void] + # + # source://rubocop//lib/rubocop/lsp.rb#18 + def enable; end + + # Returns true when LSP is enabled, false when disabled. + # + # @return [Boolean] + # + # source://rubocop//lib/rubocop/lsp.rb#11 + def enabled?; end + + class << self + # Disable LSP. + # + # @return [void] + # + # source://rubocop//lib/rubocop/lsp.rb#25 + def disable(&block); end + + # Enable LSP. + # + # @return [void] + # + # source://rubocop//lib/rubocop/lsp.rb#18 + def enable; end + + # Returns true when LSP is enabled, false when disabled. + # + # @return [Boolean] + # + # source://rubocop//lib/rubocop/lsp.rb#11 + def enabled?; end + end +end + +# Log for Language Server Protocol of RuboCop. +# +# @api private +# +# source://rubocop//lib/rubocop/lsp/logger.rb#16 +class RuboCop::LSP::Logger + class << self + # @api private + # + # source://rubocop//lib/rubocop/lsp/logger.rb#17 + def log(message); end + end +end + +# Routes for Language Server Protocol of RuboCop. +# +# @api private +# +# source://rubocop//lib/rubocop/lsp/routes.rb#18 +class RuboCop::LSP::Routes + # @api private + # @return [Routes] a new instance of Routes + # + # source://rubocop//lib/rubocop/lsp/routes.rb#25 + def initialize(server); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#31 + def for(name); end + + # source://rubocop//lib/rubocop/lsp/routes.rb#38 + def handle_initialize(request); end + + # source://rubocop//lib/rubocop/lsp/routes.rb#57 + def handle_initialized(_request); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#167 + def handle_method_missing(request); end + + # source://rubocop//lib/rubocop/lsp/routes.rb#64 + def handle_shutdown(request); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#156 + def handle_unsupported_method(request, method = T.unsafe(nil)); end + + private + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#205 + def diagnostic(file_uri, text); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#175 + def extract_initialization_options_from(request); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#185 + def format_file(file_uri, command: T.unsafe(nil)); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#219 + def remove_file_protocol_from(uri); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#223 + def to_diagnostic(offense); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#235 + def to_range(location); end + + class << self + private + + # @api private + # + # source://rubocop//lib/rubocop/lsp/routes.rb#19 + def handle(name, &block); end + end +end + +# Runtime for Language Server Protocol of RuboCop. +# +# @api private +# +# source://rubocop//lib/rubocop/lsp/runtime.rb#16 +class RuboCop::LSP::Runtime + # @api private + # @return [Runtime] a new instance of Runtime + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#19 + def initialize(config_store); end + + # This abuses the `--stdin` option of rubocop and reads the formatted text + # from the `options[:stdin]` that rubocop mutates. This depends on + # `parallel: false` as well as the fact that RuboCop doesn't otherwise dup + # or reassign that options object. Risky business! + # + # Reassigning `options[:stdin]` is done here: + # https://github.com/rubocop/rubocop/blob/v1.52.0/lib/rubocop/cop/team.rb#L131 + # Printing `options[:stdin]` + # https://github.com/rubocop/rubocop/blob/v1.52.0/lib/rubocop/cli/command/execute_runner.rb#L95 + # Setting `parallel: true` would break this here: + # https://github.com/rubocop/rubocop/blob/v1.52.0/lib/rubocop/runner.rb#L72 + # + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#38 + def format(path, text, command:); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#17 + def layout_mode=(_arg0); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#17 + def lint_mode=(_arg0); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#55 + def offenses(path, text); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#17 + def safe_autocorrect=(_arg0); end + + private + + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#77 + def config_only_options; end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#84 + def redirect_stdout(&block); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/runtime.rb#92 + def run_rubocop(options, path); end +end + +# Language Server Protocol of RuboCop. +# +# @api private +# +# source://rubocop//lib/rubocop/lsp/server.rb#22 +class RuboCop::LSP::Server + # @api private + # @return [Server] a new instance of Server + # + # source://rubocop//lib/rubocop/lsp/server.rb#23 + def initialize(config_store); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/server.rb#61 + def configure(options); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/server.rb#53 + def format(path, text, command:); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/server.rb#57 + def offenses(path, text); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/server.rb#34 + def start; end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/server.rb#67 + def stop(&block); end + + # @api private + # + # source://rubocop//lib/rubocop/lsp/server.rb#49 + def write(response); end +end + +# Severity for Language Server Protocol of RuboCop. +# +# @api private +# +# source://rubocop//lib/rubocop/lsp/severity.rb#7 +class RuboCop::LSP::Severity + class << self + # @api private + # + # source://rubocop//lib/rubocop/lsp/severity.rb#17 + def find_by(rubocop_severity); end + end +end + +# @api private +# +# source://rubocop//lib/rubocop/lsp/severity.rb#8 +RuboCop::LSP::Severity::SEVERITIES = T.let(T.unsafe(nil), Hash) + # Encapsulation of a lockfile for use when checking for gems. # Does not actually resolve gems, just parses the lockfile. # # @api private # -# source://rubocop//lib/rubocop/lockfile.rb#7 +# source://rubocop//lib/rubocop/lockfile.rb#15 class RuboCop::Lockfile - # Gems that the bundle depends on + # @api private + # @param lockfile_path [String, Pathname, nil] + # @return [Lockfile] a new instance of Lockfile + # + # source://rubocop//lib/rubocop/lockfile.rb#17 + def initialize(lockfile_path = T.unsafe(nil)); end + + # Gems that the bundle directly depends on. # # @api private + # @return [Array, nil] # - # source://rubocop//lib/rubocop/lockfile.rb#9 + # source://rubocop//lib/rubocop/lockfile.rb#29 def dependencies; end - # All activated gems, including transitive dependencies + # Returns the locked versions of gems from this lockfile. # # @api private + # @param include_transitive_dependencies: [Boolean] When false, only direct dependencies + # are returned, i.e. those listed explicitly in the `Gemfile`. + # + # source://rubocop//lib/rubocop/lockfile.rb#49 + def gem_versions(include_transitive_dependencies: T.unsafe(nil)); end + + # All activated gems, including transitive dependencies. # - # source://rubocop//lib/rubocop/lockfile.rb#16 + # @api private + # @return [Array, nil] + # + # source://rubocop//lib/rubocop/lockfile.rb#37 def gems; end + # Whether this lockfile includes the named gem, directly or indirectly. + # # @api private + # @param name [String] # @return [Boolean] # - # source://rubocop//lib/rubocop/lockfile.rb#24 + # source://rubocop//lib/rubocop/lockfile.rb#65 def includes_gem?(name); end private # @api private + # @return [Boolean] + # + # source://rubocop//lib/rubocop/lockfile.rb#85 + def bundler_lock_parser_defined?; end + + # @api private + # @return [Bundler::LockfileParser, nil] # - # source://rubocop//lib/rubocop/lockfile.rb#30 + # source://rubocop//lib/rubocop/lockfile.rb#72 def parser; end end @@ -53858,12 +56422,12 @@ RuboCop::MagicComment::KEYWORDS = T.let(T.unsafe(nil), Hash) class RuboCop::MagicComment::SimpleComment < ::RuboCop::MagicComment # Match `encoding` or `coding` # - # source://rubocop//lib/rubocop/magic_comment.rb#263 + # source://rubocop//lib/rubocop/magic_comment.rb#265 def encoding; end # Rewrite the comment without a given token type # - # source://rubocop//lib/rubocop/magic_comment.rb#268 + # source://rubocop//lib/rubocop/magic_comment.rb#270 def without(type); end private @@ -53877,22 +56441,25 @@ class RuboCop::MagicComment::SimpleComment < ::RuboCop::MagicComment # # @see https://github.com/ruby/ruby/blob/78b95b4/parse.y#L7134-L7138 # - # source://rubocop//lib/rubocop/magic_comment.rb#285 + # source://rubocop//lib/rubocop/magic_comment.rb#287 def extract_frozen_string_literal; end - # source://rubocop//lib/rubocop/magic_comment.rb#289 + # source://rubocop//lib/rubocop/magic_comment.rb#291 def extract_shareable_constant_value; end - # source://rubocop//lib/rubocop/magic_comment.rb#293 + # source://rubocop//lib/rubocop/magic_comment.rb#295 def extract_typed; end end +# source://rubocop//lib/rubocop/magic_comment.rb#262 +RuboCop::MagicComment::SimpleComment::FSTRING_LITERAL_COMMENT = T.let(T.unsafe(nil), String) + # IRB's pattern for matching magic comment tokens. # # @see https://github.com/ruby/ruby/blob/b4a55c1/lib/irb/magic-file.rb#L5 # # source://rubocop//lib/rubocop/magic_comment.rb#10 -RuboCop::MagicComment::TOKEN = T.let(T.unsafe(nil), Regexp) +RuboCop::MagicComment::TOKEN = T.let(T.unsafe(nil), String) # Wrapper for Vim style magic comments. # @@ -54006,7 +56573,7 @@ class RuboCop::Options # @api private # - # source://rubocop//lib/rubocop/options.rb#219 + # source://rubocop//lib/rubocop/options.rb#229 def add_additional_modes(opts); end # the autocorrect command-line arguments map to the autocorrect @options values like so: @@ -54018,62 +56585,67 @@ class RuboCop::Options # # @api private # - # source://rubocop//lib/rubocop/options.rb#136 + # source://rubocop//lib/rubocop/options.rb#140 def add_autocorrection_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#201 + # source://rubocop//lib/rubocop/options.rb#205 def add_cache_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#70 + # source://rubocop//lib/rubocop/options.rb#73 def add_check_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#159 + # source://rubocop//lib/rubocop/options.rb#163 def add_config_generation_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#177 + # source://rubocop//lib/rubocop/options.rb#181 def add_cop_selection_csv_option(option, opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#231 + # source://rubocop//lib/rubocop/options.rb#241 def add_general_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#101 + # source://rubocop//lib/rubocop/options.rb#212 + def add_lsp_option(opts); end + + # @api private + # + # source://rubocop//lib/rubocop/options.rb#105 def add_output_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#243 + # source://rubocop//lib/rubocop/options.rb#253 def add_profile_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#208 + # source://rubocop//lib/rubocop/options.rb#218 def add_server_options(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#192 + # source://rubocop//lib/rubocop/options.rb#196 def add_severity_option(opts); end # @api private # - # source://rubocop//lib/rubocop/options.rb#52 + # source://rubocop//lib/rubocop/options.rb#53 def define_options; end # @api private # - # source://rubocop//lib/rubocop/options.rb#253 + # source://rubocop//lib/rubocop/options.rb#263 def handle_deprecated_option(old_option, new_option); end # Finds the option in `args` starting with -- and converts it to a symbol, @@ -54081,7 +56653,7 @@ class RuboCop::Options # # @api private # - # source://rubocop//lib/rubocop/options.rb#287 + # source://rubocop//lib/rubocop/options.rb#297 def long_opt_symbol(args); end # Sets a value in the @options hash, based on the given long option and its @@ -54089,17 +56661,17 @@ class RuboCop::Options # # @api private # - # source://rubocop//lib/rubocop/options.rb#276 + # source://rubocop//lib/rubocop/options.rb#286 def option(opts, *args); end # @api private # - # source://rubocop//lib/rubocop/options.rb#258 + # source://rubocop//lib/rubocop/options.rb#268 def rainbow; end # @api private # - # source://rubocop//lib/rubocop/options.rb#292 + # source://rubocop//lib/rubocop/options.rb#302 def require_feature(file); end # Creates a section of options in order to separate them visually when @@ -54107,7 +56679,7 @@ class RuboCop::Options # # @api private # - # source://rubocop//lib/rubocop/options.rb#268 + # source://rubocop//lib/rubocop/options.rb#278 def section(opts, heading, &_block); end end @@ -54130,141 +56702,141 @@ RuboCop::Options::E_STDIN_NO_PATH = T.let(T.unsafe(nil), String) # # @api private # -# source://rubocop//lib/rubocop/options.rb#488 +# source://rubocop//lib/rubocop/options.rb#498 module RuboCop::OptionsHelp; end # @api private # -# source://rubocop//lib/rubocop/options.rb#490 +# source://rubocop//lib/rubocop/options.rb#500 RuboCop::OptionsHelp::FORMATTER_OPTION_LIST = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/options.rb#489 +# source://rubocop//lib/rubocop/options.rb#499 RuboCop::OptionsHelp::MAX_EXCL = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/options.rb#492 +# source://rubocop//lib/rubocop/options.rb#502 RuboCop::OptionsHelp::TEXT = T.let(T.unsafe(nil), Hash) # Validates option arguments and the options' compatibility with each other. # # @api private # -# source://rubocop//lib/rubocop/options.rb#302 +# source://rubocop//lib/rubocop/options.rb#312 class RuboCop::OptionsValidator # @api private # @return [OptionsValidator] a new instance of OptionsValidator # - # source://rubocop//lib/rubocop/options.rb#340 + # source://rubocop//lib/rubocop/options.rb#350 def initialize(options); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/options.rb#462 + # source://rubocop//lib/rubocop/options.rb#472 def boolean_or_empty_cache?; end # @api private # - # source://rubocop//lib/rubocop/options.rb#428 + # source://rubocop//lib/rubocop/options.rb#442 def disable_parallel_when_invalid_option_combo; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/options.rb#454 - def display_only_fail_level_offenses_with_autocorrect?; end - - # @api private - # @return [Boolean] - # - # source://rubocop//lib/rubocop/options.rb#458 + # source://rubocop//lib/rubocop/options.rb#468 def except_syntax?; end # @api private # - # source://rubocop//lib/rubocop/options.rb#466 + # source://rubocop//lib/rubocop/options.rb#476 def incompatible_options; end # @api private # - # source://rubocop//lib/rubocop/options.rb#441 + # source://rubocop//lib/rubocop/options.rb#455 def invalid_arguments_for_parallel; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/options.rb#449 + # source://rubocop//lib/rubocop/options.rb#463 def only_includes_redundant_disable?; end # @api private # - # source://rubocop//lib/rubocop/options.rb#375 + # source://rubocop//lib/rubocop/options.rb#382 def validate_auto_gen_config; end # @api private # @raise [OptionArgumentError] # - # source://rubocop//lib/rubocop/options.rb#414 + # source://rubocop//lib/rubocop/options.rb#428 def validate_autocorrect; end # @api private # @raise [OptionArgumentError] # - # source://rubocop//lib/rubocop/options.rb#478 + # source://rubocop//lib/rubocop/options.rb#488 def validate_cache_enabled_for_cache_root; end # @api private # @raise [OptionArgumentError] # - # source://rubocop//lib/rubocop/options.rb#349 + # source://rubocop//lib/rubocop/options.rb#359 def validate_compatibility; end # @api private # - # source://rubocop//lib/rubocop/options.rb#344 + # source://rubocop//lib/rubocop/options.rb#354 def validate_cop_options; end # @api private # @raise [OptionArgumentError] # - # source://rubocop//lib/rubocop/options.rb#396 + # source://rubocop//lib/rubocop/options.rb#403 def validate_display_only_correctable_and_autocorrect; end # @api private # @raise [OptionArgumentError] # - # source://rubocop//lib/rubocop/options.rb#388 + # source://rubocop//lib/rubocop/options.rb#395 def validate_display_only_failed; end # @api private # @raise [OptionArgumentError] # - # source://rubocop//lib/rubocop/options.rb#405 + # source://rubocop//lib/rubocop/options.rb#412 def validate_display_only_failed_and_display_only_correctable; end # @api private # @raise [OptionParser::MissingArgument] # - # source://rubocop//lib/rubocop/options.rb#470 + # source://rubocop//lib/rubocop/options.rb#480 def validate_exclude_limit_option; end + # @api private + # @raise [OptionArgumentError] + # + # source://rubocop//lib/rubocop/options.rb#421 + def validate_lsp_and_editor_mode; end + class << self # Cop name validation must be done later than option parsing, so it's not # called from within Options. # # @api private # - # source://rubocop//lib/rubocop/options.rb#309 + # source://rubocop//lib/rubocop/options.rb#319 def validate_cop_list(names); end private # @api private # - # source://rubocop//lib/rubocop/options.rb#326 + # source://rubocop//lib/rubocop/options.rb#336 def format_message_from(name, cop_names); end end end @@ -54277,21 +56849,21 @@ module RuboCop::PathUtil # Returns true for an absolute Unix or Windows path. # - # source://rubocop//lib/rubocop/path_util.rb#72 + # source://rubocop//lib/rubocop/path_util.rb#76 def absolute?(path); end # Returns true for a glob # - # source://rubocop//lib/rubocop/path_util.rb#77 + # source://rubocop//lib/rubocop/path_util.rb#81 def glob?(path); end - # source://rubocop//lib/rubocop/path_util.rb#107 + # source://rubocop//lib/rubocop/path_util.rb#111 def hidden_dir?(path); end - # source://rubocop//lib/rubocop/path_util.rb#90 + # source://rubocop//lib/rubocop/path_util.rb#94 def hidden_file?(path); end - # source://rubocop//lib/rubocop/path_util.rb#81 + # source://rubocop//lib/rubocop/path_util.rb#85 def hidden_file_in_not_hidden_dir?(pattern, path); end # source://rubocop//lib/rubocop/path_util.rb#48 @@ -54299,7 +56871,7 @@ module RuboCop::PathUtil # Loose check to reduce memory allocations # - # source://rubocop//lib/rubocop/path_util.rb#97 + # source://rubocop//lib/rubocop/path_util.rb#101 def maybe_hidden_file?(path); end # source://rubocop//lib/rubocop/path_util.rb#13 @@ -54313,29 +56885,29 @@ module RuboCop::PathUtil # # @return [Boolean] # - # source://rubocop//lib/rubocop/path_util.rb#72 + # source://rubocop//lib/rubocop/path_util.rb#76 def absolute?(path); end # Returns true for a glob # # @return [Boolean] # - # source://rubocop//lib/rubocop/path_util.rb#77 + # source://rubocop//lib/rubocop/path_util.rb#81 def glob?(path); end # @return [Boolean] # - # source://rubocop//lib/rubocop/path_util.rb#107 + # source://rubocop//lib/rubocop/path_util.rb#111 def hidden_dir?(path); end # @return [Boolean] # - # source://rubocop//lib/rubocop/path_util.rb#90 + # source://rubocop//lib/rubocop/path_util.rb#94 def hidden_file?(path); end # @return [Boolean] # - # source://rubocop//lib/rubocop/path_util.rb#81 + # source://rubocop//lib/rubocop/path_util.rb#85 def hidden_file_in_not_hidden_dir?(pattern, path); end # @return [Boolean] @@ -54347,7 +56919,7 @@ module RuboCop::PathUtil # # @return [Boolean] # - # source://rubocop//lib/rubocop/path_util.rb#97 + # source://rubocop//lib/rubocop/path_util.rb#101 def maybe_hidden_file?(path); end # source://rubocop//lib/rubocop/path_util.rb#13 @@ -54370,7 +56942,7 @@ module RuboCop::PathUtil end end -# source://rubocop//lib/rubocop/path_util.rb#94 +# source://rubocop//lib/rubocop/path_util.rb#98 RuboCop::PathUtil::HIDDEN_FILE_PATTERN = T.let(T.unsafe(nil), String) # source://rubocop//lib/rubocop/path_util.rb#31 @@ -54475,39 +57047,39 @@ RuboCop::RemoteConfig::CACHE_LIFETIME = T.let(T.unsafe(nil), Integer) # # @api private # -# source://rubocop//lib/rubocop/result_cache.rb#12 +# source://rubocop//lib/rubocop/result_cache.rb#11 class RuboCop::ResultCache # @api private # @return [ResultCache] a new instance of ResultCache # - # source://rubocop//lib/rubocop/result_cache.rb#88 + # source://rubocop//lib/rubocop/result_cache.rb#87 def initialize(file, team, options, config_store, cache_root = T.unsafe(nil)); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/result_cache.rb#101 + # source://rubocop//lib/rubocop/result_cache.rb#100 def debug?; end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#109 + # source://rubocop//lib/rubocop/result_cache.rb#108 def load; end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#86 + # source://rubocop//lib/rubocop/result_cache.rb#85 def path; end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#114 + # source://rubocop//lib/rubocop/result_cache.rb#113 def save(offenses); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/result_cache.rb#105 + # source://rubocop//lib/rubocop/result_cache.rb#104 def valid?; end private @@ -54515,7 +57087,7 @@ class RuboCop::ResultCache # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/result_cache.rb#147 + # source://rubocop//lib/rubocop/result_cache.rb#146 def any_symlink?(path); end # We combine team and options into a single "context" checksum to avoid @@ -54525,17 +57097,17 @@ class RuboCop::ResultCache # # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#233 + # source://rubocop//lib/rubocop/result_cache.rb#236 def context_checksum(team, options); end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#190 + # source://rubocop//lib/rubocop/result_cache.rb#189 def digest(path); end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#158 + # source://rubocop//lib/rubocop/result_cache.rb#157 def file_checksum(file, config_store); end # Return a hash of the options given at invocation, minus the ones that have @@ -54544,25 +57116,25 @@ class RuboCop::ResultCache # # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#217 + # source://rubocop//lib/rubocop/result_cache.rb#220 def relevant_options_digest(options); end # The checksum of the RuboCop program running the inspection. # # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#175 + # source://rubocop//lib/rubocop/result_cache.rb#174 def rubocop_checksum; end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#201 + # source://rubocop//lib/rubocop/result_cache.rb#200 def rubocop_extra_features; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/result_cache.rb#143 + # source://rubocop//lib/rubocop/result_cache.rb#142 def symlink_protection_triggered?(path); end # The external dependency checksums are cached per RuboCop team so that @@ -54570,19 +57142,19 @@ class RuboCop::ResultCache # # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#224 + # source://rubocop//lib/rubocop/result_cache.rb#227 def team_checksum(team); end class << self # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/result_cache.rb#82 + # source://rubocop//lib/rubocop/result_cache.rb#81 def allow_symlinks_in_cache_location?(config_store); end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#76 + # source://rubocop//lib/rubocop/result_cache.rb#75 def cache_root(config_store); end # Remove old files so that the cache doesn't grow too big. When the @@ -54594,67 +57166,67 @@ class RuboCop::ResultCache # # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#29 + # source://rubocop//lib/rubocop/result_cache.rb#28 def cleanup(config_store, verbose, cache_root = T.unsafe(nil)); end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#171 + # source://rubocop//lib/rubocop/result_cache.rb#170 def inhibit_cleanup; end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#171 + # source://rubocop//lib/rubocop/result_cache.rb#170 def inhibit_cleanup=(_arg0); end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#43 + # source://rubocop//lib/rubocop/result_cache.rb#42 def rubocop_required_features; end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#43 + # source://rubocop//lib/rubocop/result_cache.rb#42 def rubocop_required_features=(_arg0); end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#171 + # source://rubocop//lib/rubocop/result_cache.rb#170 def source_checksum; end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#171 + # source://rubocop//lib/rubocop/result_cache.rb#170 def source_checksum=(_arg0); end private # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#66 + # source://rubocop//lib/rubocop/result_cache.rb#65 def remove_files(files, dirs, remove_count); end # @api private # - # source://rubocop//lib/rubocop/result_cache.rb#53 + # source://rubocop//lib/rubocop/result_cache.rb#52 def remove_oldest_files(files, dirs, cache_root, verbose); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/result_cache.rb#49 + # source://rubocop//lib/rubocop/result_cache.rb#48 def requires_file_removal?(file_count, config_store); end end end # @api private # -# source://rubocop//lib/rubocop/result_cache.rb#17 +# source://rubocop//lib/rubocop/result_cache.rb#16 RuboCop::ResultCache::DL_EXTENSIONS = T.let(T.unsafe(nil), Array) # @api private # -# source://rubocop//lib/rubocop/result_cache.rb#13 +# source://rubocop//lib/rubocop/result_cache.rb#12 RuboCop::ResultCache::NON_CHANGING = T.let(T.unsafe(nil), Array) # This class handles the processing of files, which includes dealing with @@ -54664,145 +57236,145 @@ RuboCop::ResultCache::NON_CHANGING = T.let(T.unsafe(nil), Array) class RuboCop::Runner # @return [Runner] a new instance of Runner # - # source://rubocop//lib/rubocop/runner.rb#59 + # source://rubocop//lib/rubocop/runner.rb#63 def initialize(options, config_store); end # Sets the attribute aborting # # @param value the value to set the attribute aborting to. # - # source://rubocop//lib/rubocop/runner.rb#57 + # source://rubocop//lib/rubocop/runner.rb#61 def aborting=(_arg0); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#83 + # source://rubocop//lib/rubocop/runner.rb#87 def aborting?; end # Returns the value of attribute errors. # - # source://rubocop//lib/rubocop/runner.rb#56 + # source://rubocop//lib/rubocop/runner.rb#60 def errors; end - # source://rubocop//lib/rubocop/runner.rb#67 + # source://rubocop//lib/rubocop/runner.rb#71 def run(paths); end # Returns the value of attribute warnings. # - # source://rubocop//lib/rubocop/runner.rb#56 + # source://rubocop//lib/rubocop/runner.rb#60 def warnings; end private - # source://rubocop//lib/rubocop/runner.rb#196 + # source://rubocop//lib/rubocop/runner.rb#200 def add_redundant_disables(file, offenses, source); end - # source://rubocop//lib/rubocop/runner.rb#170 + # source://rubocop//lib/rubocop/runner.rb#174 def cached_result(file, team); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#250 + # source://rubocop//lib/rubocop/runner.rb#254 def cached_run?; end # Check whether a run created source identical to a previous run, which # means that we definitely have an infinite loop. # - # source://rubocop//lib/rubocop/runner.rb#328 + # source://rubocop//lib/rubocop/runner.rb#332 def check_for_infinite_loop(processed_source, offenses_by_iteration); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#222 + # source://rubocop//lib/rubocop/runner.rb#226 def check_for_redundant_disables?(source); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#423 + # source://rubocop//lib/rubocop/runner.rb#427 def considered_failure?(offense); end - # source://rubocop//lib/rubocop/runner.rb#456 + # source://rubocop//lib/rubocop/runner.rb#460 def default_config(cop_name); end - # source://rubocop//lib/rubocop/runner.rb#272 + # source://rubocop//lib/rubocop/runner.rb#276 def do_inspection_loop(file); end - # source://rubocop//lib/rubocop/runner.rb#133 + # source://rubocop//lib/rubocop/runner.rb#137 def each_inspected_file(files); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#236 + # source://rubocop//lib/rubocop/runner.rb#240 def except_redundant_cop_disable_directive?; end - # source://rubocop//lib/rubocop/runner.rb#357 + # source://rubocop//lib/rubocop/runner.rb#361 def extract_ruby_sources(processed_source); end - # source://rubocop//lib/rubocop/runner.rb#245 + # source://rubocop//lib/rubocop/runner.rb#249 def file_finished(file, offenses); end - # source://rubocop//lib/rubocop/runner.rb#174 + # source://rubocop//lib/rubocop/runner.rb#178 def file_offense_cache(file); end - # source://rubocop//lib/rubocop/runner.rb#162 + # source://rubocop//lib/rubocop/runner.rb#166 def file_offenses(file); end - # source://rubocop//lib/rubocop/runner.rb#240 + # source://rubocop//lib/rubocop/runner.rb#244 def file_started(file); end - # source://rubocop//lib/rubocop/runner.rb#403 + # source://rubocop//lib/rubocop/runner.rb#407 def filter_cop_classes(cop_classes, config); end - # source://rubocop//lib/rubocop/runner.rb#104 + # source://rubocop//lib/rubocop/runner.rb#108 def find_target_files(paths); end - # source://rubocop//lib/rubocop/runner.rb#414 + # source://rubocop//lib/rubocop/runner.rb#418 def formatter_set; end - # source://rubocop//lib/rubocop/runner.rb#468 + # source://rubocop//lib/rubocop/runner.rb#475 def get_processed_source(file); end - # source://rubocop//lib/rubocop/runner.rb#342 + # source://rubocop//lib/rubocop/runner.rb#346 def inspect_file(processed_source, team = T.unsafe(nil)); end - # source://rubocop//lib/rubocop/runner.rb#115 + # source://rubocop//lib/rubocop/runner.rb#119 def inspect_files(files); end - # source://rubocop//lib/rubocop/runner.rb#303 + # source://rubocop//lib/rubocop/runner.rb#307 def iterate_until_no_changes(source, offenses_by_iteration); end - # source://rubocop//lib/rubocop/runner.rb#148 + # source://rubocop//lib/rubocop/runner.rb#152 def list_files(paths); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#452 + # source://rubocop//lib/rubocop/runner.rb#456 def mark_as_safe_by_config?(config); end - # source://rubocop//lib/rubocop/runner.rb#460 + # source://rubocop//lib/rubocop/runner.rb#464 def minimum_severity_to_fail; end - # source://rubocop//lib/rubocop/runner.rb#364 + # source://rubocop//lib/rubocop/runner.rb#368 def mobilize_team(processed_source); end - # source://rubocop//lib/rubocop/runner.rb#369 + # source://rubocop//lib/rubocop/runner.rb#373 def mobilized_cop_classes(config); end - # source://rubocop//lib/rubocop/runner.rb#432 + # source://rubocop//lib/rubocop/runner.rb#436 def offenses_to_report(offenses); end - # source://rubocop//lib/rubocop/runner.rb#152 + # source://rubocop//lib/rubocop/runner.rb#156 def process_file(file); end - # source://rubocop//lib/rubocop/runner.rb#393 + # source://rubocop//lib/rubocop/runner.rb#397 def qualify_option_cop_names; end # @yield [cop] # - # source://rubocop//lib/rubocop/runner.rb#228 + # source://rubocop//lib/rubocop/runner.rb#232 def redundant_cop_disable_directive(file); end - # source://rubocop//lib/rubocop/runner.rb#262 + # source://rubocop//lib/rubocop/runner.rb#266 def save_in_cache(cache, offenses); end # A Cop::Team instance is stateful and may change when inspecting. @@ -54810,41 +57382,41 @@ class RuboCop::Runner # otherwise dormant team that can be used for config- and option- # level caching in ResultCache. # - # source://rubocop//lib/rubocop/runner.rb#490 + # source://rubocop//lib/rubocop/runner.rb#503 def standby_team(config); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#410 + # source://rubocop//lib/rubocop/runner.rb#414 def style_guide_cops_only?(config); end # @return [Boolean] # - # source://rubocop//lib/rubocop/runner.rb#444 + # source://rubocop//lib/rubocop/runner.rb#448 def supports_safe_autocorrect?(offense); end # @yield [team] # - # source://rubocop//lib/rubocop/runner.rb#211 + # source://rubocop//lib/rubocop/runner.rb#215 def team_for_redundant_disables(file, offenses, source); end # Warms up the RuboCop cache by forking a suitable number of RuboCop # instances that each inspects its allotted group of files. # - # source://rubocop//lib/rubocop/runner.rb#91 + # source://rubocop//lib/rubocop/runner.rb#95 def warm_cache(target_files); end class << self # @return [Array<#call>] # - # source://rubocop//lib/rubocop/runner.rb#29 + # source://rubocop//lib/rubocop/runner.rb#33 def ruby_extractors; end private # @return [#call] # - # source://rubocop//lib/rubocop/runner.rb#36 + # source://rubocop//lib/rubocop/runner.rb#40 def default_ruby_extractor; end end end @@ -54867,12 +57439,12 @@ end # @api private # -# source://rubocop//lib/rubocop/runner.rb#49 +# source://rubocop//lib/rubocop/runner.rb#53 RuboCop::Runner::MAX_ITERATIONS = T.let(T.unsafe(nil), Integer) # @api private # -# source://rubocop//lib/rubocop/runner.rb#52 +# source://rubocop//lib/rubocop/runner.rb#56 RuboCop::Runner::REDUNDANT_COP_DISABLE_DIRECTIVE_RULES = T.let(T.unsafe(nil), Array) # Take a string with embedded escapes, and convert the escapes as the Ruby @@ -54907,27 +57479,61 @@ RuboCop::StringInterpreter::STRING_ESCAPES = T.let(T.unsafe(nil), Hash) # source://rubocop//lib/rubocop/string_interpreter.rb#12 RuboCop::StringInterpreter::STRING_ESCAPE_REGEX = T.let(T.unsafe(nil), Regexp) -# This class finds target files to inspect by scanning the directory tree -# and picking ruby files. +# This class finds target files to inspect by scanning the directory tree and picking ruby files. # # @api private # -# source://rubocop//lib/rubocop/target_finder.rb#7 +# source://rubocop//lib/rubocop/target_finder.rb#6 class RuboCop::TargetFinder # @api private # @return [TargetFinder] a new instance of TargetFinder # - # source://rubocop//lib/rubocop/target_finder.rb#10 + # source://rubocop//lib/rubocop/target_finder.rb#9 def initialize(config_store, options = T.unsafe(nil)); end + # Generate a list of target files by expanding globbing patterns (if any). If args is empty, + # recursively find all Ruby source files under the current directory + # # @api private + # @return [Array] array of file paths # - # source://rubocop//lib/rubocop/target_finder.rb#145 + # source://rubocop//lib/rubocop/target_finder.rb#17 + def find(args, mode); end + + # Search for files recursively starting at the given base directory using the given flags that + # determine how the match is made. Excluded files will be removed later by the caller, but as an + # optimization find_files removes the top level directories that are excluded in configuration + # in the normal way (dir/**/*). + # + # @api private + # + # source://rubocop//lib/rubocop/target_finder.rb#58 + def find_files(base_dir, flags); end + + # Finds all Ruby source files under the current or other supplied directory. A Ruby source file + # is defined as a file with the `.rb` extension or a file with no extension that has a ruby + # shebang line as its first line. + # It is possible to specify includes and excludes using the config file, so you can include + # other Ruby files like Rakefiles and gemspecs. + # + # @api private + # @param base_dir Root directory under which to search for + # ruby source files + # @return [Array] Array of filenames + # + # source://rubocop//lib/rubocop/target_finder.rb#41 + def target_files_in_dir(base_dir = T.unsafe(nil)); end + + private + + # @api private + # + # source://rubocop//lib/rubocop/target_finder.rb#120 def all_cops_include; end # @api private # - # source://rubocop//lib/rubocop/target_finder.rb#116 + # source://rubocop//lib/rubocop/target_finder.rb#106 def combined_exclude_glob_patterns(base_dir); end # @api private @@ -54939,141 +57545,114 @@ class RuboCop::TargetFinder # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#19 + # source://rubocop//lib/rubocop/target_finder.rb#208 def debug?; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#23 + # source://rubocop//lib/rubocop/target_finder.rb#212 def fail_fast?; end - # Generate a list of target files by expanding globbing patterns - # (if any). If args is empty, recursively find all Ruby source - # files under the current directory - # # @api private - # @return [Array] array of file paths + # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#31 - def find(args, mode); end + # source://rubocop//lib/rubocop/target_finder.rb#200 + def force_exclusion?; end - # Search for files recursively starting at the given base directory using - # the given flags that determine how the match is made. Excluded files will - # be removed later by the caller, but as an optimization find_files removes - # the top level directories that are excluded in configuration in the - # normal way (dir/**/*). - # # @api private + # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#83 - def find_files(base_dir, flags); end + # source://rubocop//lib/rubocop/target_finder.rb#204 + def ignore_parent_exclusion?; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#15 - def force_exclusion?; end + # source://rubocop//lib/rubocop/target_finder.rb#145 + def included_file?(file); end # @api private - # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#176 - def included_file?(file); end + # source://rubocop//lib/rubocop/target_finder.rb#191 + def order; end # @api private # - # source://rubocop//lib/rubocop/target_finder.rb#180 + # source://rubocop//lib/rubocop/target_finder.rb#124 def process_explicit_path(path, mode); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#149 + # source://rubocop//lib/rubocop/target_finder.rb#176 def ruby_executable?(file); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#123 + # source://rubocop//lib/rubocop/target_finder.rb#157 def ruby_extension?(file); end # @api private # - # source://rubocop//lib/rubocop/target_finder.rb#127 + # source://rubocop//lib/rubocop/target_finder.rb#161 def ruby_extensions; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#168 + # source://rubocop//lib/rubocop/target_finder.rb#149 def ruby_file?(file); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#134 + # source://rubocop//lib/rubocop/target_finder.rb#168 def ruby_filename?(file); end # @api private # - # source://rubocop//lib/rubocop/target_finder.rb#138 + # source://rubocop//lib/rubocop/target_finder.rb#113 def ruby_filenames; end # @api private # - # source://rubocop//lib/rubocop/target_finder.rb#160 + # source://rubocop//lib/rubocop/target_finder.rb#187 def ruby_interpreters(file); end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#164 + # source://rubocop//lib/rubocop/target_finder.rb#153 def stdin?; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#108 + # source://rubocop//lib/rubocop/target_finder.rb#98 def symlink_excluded_or_infinite_loop?(base_dir, current_dir, exclude_pattern, flags); end - # Finds all Ruby source files under the current or other supplied - # directory. A Ruby source file is defined as a file with the `.rb` - # extension or a file with no extension that has a ruby shebang line - # as its first line. - # It is possible to specify includes and excludes using the config file, - # so you can include other Ruby files like Rakefiles and gemspecs. - # - # @api private - # @param base_dir Root directory under which to search for - # ruby source files - # @return [Array] Array of filenames - # - # source://rubocop//lib/rubocop/target_finder.rb#56 - def target_files_in_dir(base_dir = T.unsafe(nil)); end - # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_finder.rb#69 + # source://rubocop//lib/rubocop/target_finder.rb#73 def to_inspect?(file, hidden_files, base_dir_config); end # @api private # - # source://rubocop//lib/rubocop/target_finder.rb#96 + # source://rubocop//lib/rubocop/target_finder.rb#82 def wanted_dir_patterns(base_dir, exclude_pattern, flags); end - private - # @api private # - # source://rubocop//lib/rubocop/target_finder.rb#197 - def order; end + # source://rubocop//lib/rubocop/target_finder.rb#134 + def without_excluded(files); end end # @api private # -# source://rubocop//lib/rubocop/target_finder.rb#8 +# source://rubocop//lib/rubocop/target_finder.rb#7 RuboCop::TargetFinder::HIDDEN_PATH_SUBSTRING = T.let(T.unsafe(nil), String) # The kind of Ruby that code inspected by RuboCop is written in. @@ -55085,34 +57664,34 @@ class RuboCop::TargetRuby # @api private # @return [TargetRuby] a new instance of TargetRuby # - # source://rubocop//lib/rubocop/target_ruby.rb#248 + # source://rubocop//lib/rubocop/target_ruby.rb#254 def initialize(config); end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#264 + # source://rubocop//lib/rubocop/target_ruby.rb#270 def rubocop_version_with_support; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#252 + # source://rubocop//lib/rubocop/target_ruby.rb#258 def source; end # @api private # @return [Boolean] # - # source://rubocop//lib/rubocop/target_ruby.rb#260 + # source://rubocop//lib/rubocop/target_ruby.rb#266 def supported?; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#256 + # source://rubocop//lib/rubocop/target_ruby.rb#262 def version; end class << self # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#234 + # source://rubocop//lib/rubocop/target_ruby.rb#240 def supported_versions; end end end @@ -55121,23 +57700,23 @@ end # # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#107 +# source://rubocop//lib/rubocop/target_ruby.rb#187 class RuboCop::TargetRuby::BundlerLockFile < ::RuboCop::TargetRuby::Source # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#108 + # source://rubocop//lib/rubocop/target_ruby.rb#188 def name; end private # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#141 + # source://rubocop//lib/rubocop/target_ruby.rb#221 def bundler_lock_file_path; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#114 + # source://rubocop//lib/rubocop/target_ruby.rb#194 def find_version; end end @@ -55150,18 +57729,18 @@ RuboCop::TargetRuby::DEFAULT_VERSION = T.let(T.unsafe(nil), Float) # # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#222 +# source://rubocop//lib/rubocop/target_ruby.rb#228 class RuboCop::TargetRuby::Default < ::RuboCop::TargetRuby::Source # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#223 + # source://rubocop//lib/rubocop/target_ruby.rb#229 def name; end private # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#229 + # source://rubocop//lib/rubocop/target_ruby.rb#235 def find_version; end end @@ -55169,62 +57748,62 @@ end # # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#148 +# source://rubocop//lib/rubocop/target_ruby.rb#53 class RuboCop::TargetRuby::GemspecFile < ::RuboCop::TargetRuby::Source extend ::RuboCop::AST::NodePattern::Macros - # source://rubocop//lib/rubocop/target_ruby.rb#159 - def gem_requirement?(param0 = T.unsafe(nil)); end + # source://rubocop//lib/rubocop/target_ruby.rb#64 + def gem_requirement_versions(param0 = T.unsafe(nil)); end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#163 + # source://rubocop//lib/rubocop/target_ruby.rb#70 def name; end - # source://rubocop//lib/rubocop/target_ruby.rb#154 + # source://rubocop//lib/rubocop/target_ruby.rb#59 def required_ruby_version(param0); end private # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#210 + # source://rubocop//lib/rubocop/target_ruby.rb#121 def find_default_minimal_known_ruby(right_hand_side); end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#169 + # source://rubocop//lib/rubocop/target_ruby.rb#76 def find_version; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#179 + # source://rubocop//lib/rubocop/target_ruby.rb#86 def gemspec_filename; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#186 + # source://rubocop//lib/rubocop/target_ruby.rb#93 def gemspec_filepath; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#206 + # source://rubocop//lib/rubocop/target_ruby.rb#117 def version_from_array(array); end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#191 + # source://rubocop//lib/rubocop/target_ruby.rb#98 def version_from_gemspec_file(file); end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#196 + # source://rubocop//lib/rubocop/target_ruby.rb#105 def version_from_right_hand_side(right_hand_side); end end # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#151 +# source://rubocop//lib/rubocop/target_ruby.rb#56 RuboCop::TargetRuby::GemspecFile::GEMSPEC_EXTENSION = T.let(T.unsafe(nil), String) # @api private @@ -55260,49 +57839,49 @@ end # # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#53 +# source://rubocop//lib/rubocop/target_ruby.rb#133 class RuboCop::TargetRuby::RubyVersionFile < ::RuboCop::TargetRuby::Source # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#57 + # source://rubocop//lib/rubocop/target_ruby.rb#137 def name; end private # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#63 + # source://rubocop//lib/rubocop/target_ruby.rb#143 def filename; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#71 + # source://rubocop//lib/rubocop/target_ruby.rb#151 def find_version; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#67 + # source://rubocop//lib/rubocop/target_ruby.rb#147 def pattern; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#78 + # source://rubocop//lib/rubocop/target_ruby.rb#158 def version_file; end end # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#54 +# source://rubocop//lib/rubocop/target_ruby.rb#134 RuboCop::TargetRuby::RubyVersionFile::RUBY_VERSION_FILENAME = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#55 +# source://rubocop//lib/rubocop/target_ruby.rb#135 RuboCop::TargetRuby::RubyVersionFile::RUBY_VERSION_PATTERN = T.let(T.unsafe(nil), Regexp) # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#238 +# source://rubocop//lib/rubocop/target_ruby.rb#244 RuboCop::TargetRuby::SOURCES = T.let(T.unsafe(nil), Array) # A place where information about a target ruby version is found. @@ -55338,34 +57917,34 @@ end # # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#86 +# source://rubocop//lib/rubocop/target_ruby.rb#166 class RuboCop::TargetRuby::ToolVersionsFile < ::RuboCop::TargetRuby::RubyVersionFile # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#90 + # source://rubocop//lib/rubocop/target_ruby.rb#170 def name; end private # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#96 + # source://rubocop//lib/rubocop/target_ruby.rb#176 def filename; end # @api private # - # source://rubocop//lib/rubocop/target_ruby.rb#100 + # source://rubocop//lib/rubocop/target_ruby.rb#180 def pattern; end end # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#87 +# source://rubocop//lib/rubocop/target_ruby.rb#167 RuboCop::TargetRuby::ToolVersionsFile::TOOL_VERSIONS_FILENAME = T.let(T.unsafe(nil), String) # @api private # -# source://rubocop//lib/rubocop/target_ruby.rb#88 +# source://rubocop//lib/rubocop/target_ruby.rb#168 RuboCop::TargetRuby::ToolVersionsFile::TOOL_VERSIONS_PATTERN = T.let(T.unsafe(nil), Regexp) # source://rubocop//lib/rubocop/ast_aliases.rb#7 @@ -55391,12 +57970,12 @@ module RuboCop::Version class << self # @api private # - # source://rubocop//lib/rubocop/version.rb#93 + # source://rubocop//lib/rubocop/version.rb#108 def document_version; end # @api private # - # source://rubocop//lib/rubocop/version.rb#43 + # source://rubocop//lib/rubocop/version.rb#58 def extension_versions(env); end # Returns feature version in one of two ways: @@ -55406,12 +57985,17 @@ module RuboCop::Version # # @api private # - # source://rubocop//lib/rubocop/version.rb#77 + # source://rubocop//lib/rubocop/version.rb#92 def feature_version(feature); end # @api private # - # source://rubocop//lib/rubocop/version.rb#98 + # source://rubocop//lib/rubocop/version.rb#43 + def parser_version; end + + # @api private + # + # source://rubocop//lib/rubocop/version.rb#113 def server_mode; end # @api private @@ -55469,9 +58053,3 @@ end class String include ::Comparable end - -# source://activesupport/7.0.5/lib/active_support/core_ext/object/blank.rb#104 -String::BLANK_RE = T.let(T.unsafe(nil), Regexp) - -# source://activesupport/7.0.5/lib/active_support/core_ext/object/blank.rb#105 -String::ENCODED_BLANKS = T.let(T.unsafe(nil), Concurrent::Map) diff --git a/sorbet/rbi/gems/ruby-lsp@0.5.1.rbi b/sorbet/rbi/gems/ruby-lsp@0.5.1.rbi deleted file mode 100644 index e5e46d4d3..000000000 --- a/sorbet/rbi/gems/ruby-lsp@0.5.1.rbi +++ /dev/null @@ -1,14 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `ruby-lsp` gem. -# Please instead update this file by running `bin/tapioca gem ruby-lsp`. - -# source://ruby-lsp//lib/ruby-lsp.rb#4 -module RubyLsp; end - -# source://ruby-lsp//lib/ruby-lsp.rb#5 -RubyLsp::VERSION = T.let(T.unsafe(nil), String) - -# source://tapioca/0.10.5/lib/tapioca/helpers/source_uri.rb#10 -URI::Source::COMPONENT = T.let(T.unsafe(nil), Array) diff --git a/sorbet/rbi/gems/ruby-openid@2.9.2.rbi b/sorbet/rbi/gems/ruby-openid@2.9.2.rbi index 574606b17..d3595a0a7 100644 --- a/sorbet/rbi/gems/ruby-openid@2.9.2.rbi +++ b/sorbet/rbi/gems/ruby-openid@2.9.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `ruby-openid` gem. # Please instead update this file by running `bin/tapioca gem ruby-openid`. + # Class representing an HTML comment # # source://ruby-openid//lib/openid/yadis/htmltokenizer.rb#209 @@ -217,12 +218,6 @@ class Net::HTTP < ::Net::Protocol def post_connection_check(hostname); end end -# source://net-http/0.3.2/net/http/backward.rb#7 -Net::HTTP::ProxyMod = Net::HTTP::ProxyDelta - -# source://net-http/0.3.2/net/http.rb#382 -Net::HTTP::VERSION = T.let(T.unsafe(nil), String) - # source://ruby-openid//lib/openid.rb#15 module OpenID class << self diff --git a/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi b/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi index fe14ff97d..f832ab1c5 100644 --- a/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +++ b/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `ruby-progressbar` gem. # Please instead update this file by running `bin/tapioca gem ruby-progressbar`. + # source://ruby-progressbar//lib/ruby-progressbar/components/bar.rb#4 class ProgressBar class << self diff --git a/sorbet/rbi/gems/ruby-vips@2.1.4.rbi b/sorbet/rbi/gems/ruby-vips@2.2.2.rbi similarity index 54% rename from sorbet/rbi/gems/ruby-vips@2.1.4.rbi rename to sorbet/rbi/gems/ruby-vips@2.2.2.rbi index b0f3ebcf9..75a746324 100644 --- a/sorbet/rbi/gems/ruby-vips@2.1.4.rbi +++ b/sorbet/rbi/gems/ruby-vips@2.2.2.rbi @@ -4,375 +4,6 @@ # This is an autogenerated file for types exported from the `ruby-vips` gem. # Please instead update this file by running `bin/tapioca gem ruby-vips`. -# source://american_date/1.2.0/lib/american_date.rb#16 -::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) - -# source://ruby-openid/2.9.2/lib/openid/fetchers.rb#13 -::MAX_RESPONSE_KB = T.let(T.unsafe(nil), Integer) - -# source://yard/0.9.34/lib/yard.rb#61 -::RUBY18 = T.let(T.unsafe(nil), FalseClass) - -# source://yard/0.9.34/lib/yard.rb#62 -::RUBY19 = T.let(T.unsafe(nil), TrueClass) - -# source://ruby-vips//lib/vips.rb#36 -module GLib - extend ::FFI::Library - - def g_free(*_arg0); end - def g_log_remove_handler(*_arg0); end - def g_log_set_handler(*_arg0); end - def g_malloc(*_arg0); end - - class << self - def g_free(*_arg0); end - def g_log_remove_handler(*_arg0); end - def g_log_set_handler(*_arg0); end - def g_malloc(*_arg0); end - - # Returns the value of attribute logger. - # - # source://ruby-vips//lib/vips.rb#38 - def logger; end - - # Sets the attribute logger - # - # @param value the value to set the attribute logger to. - # - # source://ruby-vips//lib/vips.rb#38 - def logger=(_arg0); end - - # source://ruby-vips//lib/vips.rb#90 - def remove_log_handler; end - - # source://ruby-vips//lib/vips.rb#97 - def set_log_domain(domain); end - end -end - -# map glib levels to Logger::Severity -# -# source://ruby-vips//lib/vips.rb#71 -GLib::GLIB_TO_SEVERITY = T.let(T.unsafe(nil), Hash) - -# save the FFI::Function that attach will return ... we can use it directly -# as a param for callbacks -# -# source://ruby-vips//lib/vips.rb#51 -GLib::G_FREE = T.let(T.unsafe(nil), FFI::Function) - -# source://ruby-vips//lib/vips.rb#60 -GLib::LOG_FLAG_FATAL = T.let(T.unsafe(nil), Integer) - -# log flags -# -# source://ruby-vips//lib/vips.rb#59 -GLib::LOG_FLAG_RECURSION = T.let(T.unsafe(nil), Integer) - -# module-level, so it's not GCd away -# -# source://ruby-vips//lib/vips.rb#86 -GLib::LOG_HANDLER = T.let(T.unsafe(nil), Proc) - -# always fatal -# -# source://ruby-vips//lib/vips.rb#64 -GLib::LOG_LEVEL_CRITICAL = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#68 -GLib::LOG_LEVEL_DEBUG = T.let(T.unsafe(nil), Integer) - -# GLib log levels -# -# source://ruby-vips//lib/vips.rb#63 -GLib::LOG_LEVEL_ERROR = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#67 -GLib::LOG_LEVEL_INFO = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#66 -GLib::LOG_LEVEL_MESSAGE = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#65 -GLib::LOG_LEVEL_WARNING = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#134 -module GObject - extend ::FFI::Library - - def g_object_get_property(*_arg0); end - def g_object_ref(*_arg0); end - def g_object_set_property(*_arg0); end - def g_object_unref(*_arg0); end - def g_param_spec_get_blurb(*_arg0); end - def g_signal_connect_data(*_arg0); end - def g_type_from_name(*_arg0); end - def g_type_fundamental(*_arg0); end - def g_type_init(*_arg0); end - def g_type_name(*_arg0); end - def g_value_get_boolean(*_arg0); end - def g_value_get_double(*_arg0); end - def g_value_get_enum(*_arg0); end - def g_value_get_flags(*_arg0); end - def g_value_get_int(*_arg0); end - def g_value_get_object(*_arg0); end - def g_value_get_string(*_arg0); end - def g_value_get_uint64(*_arg0); end - def g_value_init(*_arg0); end - def g_value_set_boolean(*_arg0); end - def g_value_set_double(*_arg0); end - def g_value_set_enum(*_arg0); end - def g_value_set_flags(*_arg0); end - def g_value_set_int(*_arg0); end - def g_value_set_object(*_arg0); end - def g_value_set_string(*_arg0); end - def g_value_set_uint64(*_arg0); end - def g_value_unset(*_arg0); end - - class << self - def g_object_get_property(*_arg0); end - def g_object_ref(*_arg0); end - def g_object_set_property(*_arg0); end - def g_object_unref(*_arg0); end - def g_param_spec_get_blurb(*_arg0); end - def g_signal_connect_data(*_arg0); end - def g_type_from_name(*_arg0); end - def g_type_fundamental(*_arg0); end - def g_type_init(*_arg0); end - def g_type_name(*_arg0); end - def g_value_get_boolean(*_arg0); end - def g_value_get_double(*_arg0); end - def g_value_get_enum(*_arg0); end - def g_value_get_flags(*_arg0); end - def g_value_get_int(*_arg0); end - def g_value_get_object(*_arg0); end - def g_value_get_string(*_arg0); end - def g_value_get_uint64(*_arg0); end - def g_value_init(*_arg0); end - def g_value_set_boolean(*_arg0); end - def g_value_set_double(*_arg0); end - def g_value_set_enum(*_arg0); end - def g_value_set_flags(*_arg0); end - def g_value_set_int(*_arg0); end - def g_value_set_object(*_arg0); end - def g_value_set_string(*_arg0); end - def g_value_set_uint64(*_arg0); end - def g_value_unset(*_arg0); end - end -end - -# look up some common gtypes -# -# source://ruby-vips//lib/vips.rb#155 -GObject::GBOOL_TYPE = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#158 -GObject::GDOUBLE_TYPE = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#159 -GObject::GENUM_TYPE = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#160 -GObject::GFLAGS_TYPE = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#156 -GObject::GINT_TYPE = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#162 -GObject::GOBJECT_TYPE = T.let(T.unsafe(nil), Integer) - -# we have a number of things we need to inherit in different ways: -# -# - we want to be able to subclass GObject in Ruby in a simple way -# - the layouts of the nested structs need to inherit -# - we need to be able to cast between structs which share a base struct -# without creating new wrappers or messing up refcounting -# - we need automatic gobject refcounting -# -# the solution is to split the class into four areas which we treat -# differently: -# -# - we have a "wrapper" Ruby class to allow easy subclassing ... this has a -# @struct member which holds the actual pointer -# - we use "forwardable" to forward the various ffi methods on to the -# @struct member ... we arrange things so that subclasses do not need to -# do the forwarding themselves -# - we have two versions of the struct: a plain one which we can use for -# casting that will not change the refcounts -# - and a managed one with an unref which we just use for .new -# - we separate the struct layout into a separate module to avoid repeating -# ourselves -# -# source://ruby-vips//lib/vips/gobject.rb#33 -class GObject::GObject - extend ::Forwardable - extend ::SingleForwardable - - # don't allow ptr == nil, we never want to allocate a GObject struct - # ourselves, we just want to wrap GLib-allocated GObjects - # - # here we use ManagedStruct, not Struct, since this is the ref that will - # need the unref - # - # @return [GObject] a new instance of GObject - # - # source://ruby-vips//lib/vips/gobject.rb#75 - def initialize(ptr); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def [](*args, **_arg1, &block); end - - # access to the managed struct for this class - # - # source://ruby-vips//lib/vips/gobject.rb#100 - def ffi_managed_struct; end - - # access to the casting struct for this class - # - # source://ruby-vips//lib/vips/gobject.rb#85 - def ffi_struct; end - - # get the pointer we were built from ... #to_ptr gets the pointer after we - # have wrapped it up with an auto unref - # - # source://ruby-vips//lib/vips/gobject.rb#91 - def ptr; end - - # Returns the value of attribute references. - # - # source://ruby-vips//lib/vips/gobject.rb#40 - def references; end - - # source://forwardable/1.3.3/forwardable.rb#231 - def to_ptr(*args, **_arg1, &block); end - - class << self - # source://ruby-vips//lib/vips/gobject.rb#105 - def ffi_managed_struct; end - - # source://ruby-vips//lib/vips/gobject.rb#94 - def ffi_struct; end - - # source://forwardable/1.3.3/forwardable.rb#231 - def ptr(*args, **_arg1, &block); end - end -end - -# the layout of the GObject struct -# -# source://ruby-vips//lib/vips/gobject.rb#43 -module GObject::GObject::GObjectLayout - class << self - # @private - # - # source://ruby-vips//lib/vips/gobject.rb#44 - def included(base); end - end -end - -# the struct with unref ... manage object lifetime with this -# -# source://ruby-vips//lib/vips/gobject.rb#54 -class GObject::GObject::ManagedStruct < ::FFI::ManagedStruct - include ::GObject::GObject::GObjectLayout - - class << self - # source://ruby-vips//lib/vips/gobject.rb#57 - def release(ptr); end - end -end - -# the plain struct ... cast with this -# -# source://ruby-vips//lib/vips/gobject.rb#66 -class GObject::GObject::Struct < ::FFI::Struct - include ::GObject::GObject::GObjectLayout -end - -# source://ruby-vips//lib/vips/gobject.rb#111 -class GObject::GParamSpec < ::FFI::Struct; end - -# source://ruby-vips//lib/vips/gobject.rb#120 -class GObject::GParamSpecPtr < ::FFI::Struct; end - -# source://ruby-vips//lib/vips.rb#161 -GObject::GSTR_TYPE = T.let(T.unsafe(nil), Integer) - -# source://ruby-vips//lib/vips.rb#157 -GObject::GUINT64_TYPE = T.let(T.unsafe(nil), Integer) - -# Represent a GValue. Example use: -# -# ```ruby -# gvalue = GValue::alloc -# gvalue.init GObject::GDOUBLE_TYPE -# gvalue.set 3.1415 -# value = gvalue.get -# # optional -- drop any ref the gvalue had -# gvalue.unset -# ``` -# -# Lifetime is managed automatically. It doesn't know about all GType values, -# but it does know the ones that libvips uses. -# -# source://ruby-vips//lib/vips/gvalue.rb#23 -class GObject::GValue < ::FFI::ManagedStruct - # Get the value of a GValue. The value is converted to a Ruby type in - # the obvious way. - # - # @return [Any] the value held by the GValue - # - # source://ruby-vips//lib/vips/gvalue.rb#171 - def get; end - - # Set the type of thing a gvalue can hold. - # - # @param gtype [GType] the type of thing this GValue can hold. - # - # source://ruby-vips//lib/vips/gvalue.rb#79 - def init(gtype); end - - # Set the value of a GValue. The value is converted to the type of the - # GValue, if possible. - # - # @param value [Any] The value to set - # - # source://ruby-vips//lib/vips/gvalue.rb#87 - def set(value); end - - # Clear the thing held by a GValue. - # - # This happens automatically when a GValue is GCed, but this method can be - # handy if you need to drop a reference explicitly for some reason. - # - # source://ruby-vips//lib/vips/gvalue.rb#253 - def unset; end - - class << self - # Allocate memory for a GValue and return a class wrapper. Memory will - # be freed automatically when it goes out of scope. The GValue is inited - # to 0, use {GValue.init} to set a type. - # - # @return [GValue] a new gvalue set to 0 - # - # source://ruby-vips//lib/vips/gvalue.rb#63 - def alloc; end - - # convert an enum value (str/symb/int) into an int ready for libvips - # - # source://ruby-vips//lib/vips/gvalue.rb#28 - def from_nick(gtype, value); end - - # source://ruby-vips//lib/vips/gvalue.rb#53 - def release(ptr); end - - # convert an int enum back into a symbol - # - # source://ruby-vips//lib/vips/gvalue.rb#44 - def to_nick(gtype, enum_value); end - end -end class Object < ::BasicObject include ::Kernel @@ -786,7 +417,7 @@ end # {Image#maxpos}, {Image#minpos}, # {Image#median}. # -# source://ruby-vips//lib/vips.rb#570 +# source://ruby-vips//lib/vips.rb#43 module Vips extend ::FFI::Library end diff --git a/sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi b/sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi index 46bfe6ee6..56c13ae9d 100644 --- a/sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi +++ b/sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `ruby2_keywords` gem. # Please instead update this file by running `bin/tapioca gem ruby2_keywords`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/rubyntlm@0.6.3.rbi b/sorbet/rbi/gems/rubyntlm@0.6.5.rbi similarity index 85% rename from sorbet/rbi/gems/rubyntlm@0.6.3.rbi rename to sorbet/rbi/gems/rubyntlm@0.6.5.rbi index cf2a913a8..855d42850 100644 --- a/sorbet/rbi/gems/rubyntlm@0.6.3.rbi +++ b/sorbet/rbi/gems/rubyntlm@0.6.5.rbi @@ -4,18 +4,20 @@ # This is an autogenerated file for types exported from the `rubyntlm` gem. # Please instead update this file by running `bin/tapioca gem rubyntlm`. + # source://rubyntlm//lib/net/ntlm/exceptions.rb#2 module Net::NTLM class << self - # source://rubyntlm//lib/net/ntlm.rb#125 + # source://rubyntlm//lib/net/ntlm.rb#128 def apply_des(plain, keys); end - # Not sure what this is doing + # Each byte of a DES key contains seven bits of key material and one odd-parity bit. + # The parity bit should be set so that there are an odd number of 1 bits in each byte. # # @api private # @param str [String] String to generate keys for # - # source://rubyntlm//lib/net/ntlm.rb#117 + # source://rubyntlm//lib/net/ntlm.rb#120 def gen_keys(str); end # Takes a string and determines whether it is a valid NTLM Hash @@ -23,56 +25,56 @@ module Net::NTLM # @param the [String] string to validate # @return [Boolean] whether or not the string is a valid NTLM hash # - # source://rubyntlm//lib/net/ntlm.rb#87 + # source://rubyntlm//lib/net/ntlm.rb#89 def is_ntlm_hash?(data); end - # Generates a Lan Manager Hash + # Generates a {https://en.wikipedia.org/wiki/LAN_Manager LAN Manager Hash} # # @param password [String] The password to base the hash on # - # source://rubyntlm//lib/net/ntlm.rb#136 + # source://rubyntlm//lib/net/ntlm.rb#141 def lm_hash(password); end - # source://rubyntlm//lib/net/ntlm.rb#171 + # source://rubyntlm//lib/net/ntlm.rb#187 def lm_response(arg); end - # source://rubyntlm//lib/net/ntlm.rb#226 + # source://rubyntlm//lib/net/ntlm.rb#242 def lmv2_response(arg, opt = T.unsafe(nil)); end - # source://rubyntlm//lib/net/ntlm.rb#242 + # source://rubyntlm//lib/net/ntlm.rb#258 def ntlm2_session(arg, opt = T.unsafe(nil)); end - # Generate a NTLM Hash + # Generate an NTLM Hash # # @option opt # @param password [String] The password to base the hash on # @param opt [Hash] a customizable set of options # - # source://rubyntlm//lib/net/ntlm.rb#144 + # source://rubyntlm//lib/net/ntlm.rb#149 def ntlm_hash(password, opt = T.unsafe(nil)); end - # source://rubyntlm//lib/net/ntlm.rb#183 + # source://rubyntlm//lib/net/ntlm.rb#199 def ntlm_response(arg); end # Generate a NTLMv2 Hash # - # @option opt + # @option [Boolean] # @param user [String] The username # @param password [String] The password # @param target [String] The domain or workstation to authenticate to - # @param opt [Hash] a customizable set of options + # @param [Boolean] [Hash] a customizable set of options # - # source://rubyntlm//lib/net/ntlm.rb#157 + # source://rubyntlm//lib/net/ntlm.rb#162 def ntlmv2_hash(user, password, target, opt = T.unsafe(nil)); end - # source://rubyntlm//lib/net/ntlm.rb#191 + # source://rubyntlm//lib/net/ntlm.rb#207 def ntlmv2_response(arg, opt = T.unsafe(nil)); end - # Conver the value to a 64-Bit Little Endian Int + # Convert the value to a 64-bit little-endian integer # # @param val [String] The string to convert # - # source://rubyntlm//lib/net/ntlm.rb#99 + # source://rubyntlm//lib/net/ntlm.rb#101 def pack_int64le(val); end # Builds an array of strings that are 7 characters long @@ -80,7 +82,7 @@ module Net::NTLM # @api private # @param str [String] The string to split # - # source://rubyntlm//lib/net/ntlm.rb#106 + # source://rubyntlm//lib/net/ntlm.rb#108 def split7(str); end end end @@ -282,99 +284,102 @@ class Net::NTLM::Client::Session # source://rubyntlm//lib/net/ntlm/client/session.rb#13 def client; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#49 + # source://rubyntlm//lib/net/ntlm/client/session.rb#46 def exported_session_key; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#80 + # source://rubyntlm//lib/net/ntlm/client/session.rb#83 + def is_anonymous?; end + + # source://rubyntlm//lib/net/ntlm/client/session.rb#75 def seal_message(message); end - # source://rubyntlm//lib/net/ntlm/client/session.rb#60 + # source://rubyntlm//lib/net/ntlm/client/session.rb#57 def sign_message(message); end - # source://rubyntlm//lib/net/ntlm/client/session.rb#85 + # source://rubyntlm//lib/net/ntlm/client/session.rb#79 def unseal_message(emessage); end - # source://rubyntlm//lib/net/ntlm/client/session.rb#70 + # source://rubyntlm//lib/net/ntlm/client/session.rb#66 def verify_signature(signature, message); end private - # source://rubyntlm//lib/net/ntlm/client/session.rb#211 + # source://rubyntlm//lib/net/ntlm/client/session.rb#202 def blob; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#195 + # source://rubyntlm//lib/net/ntlm/client/session.rb#181 def calculate_user_session_key!; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#145 + # source://rubyntlm//lib/net/ntlm/client/session.rb#130 def client_challenge; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#125 + # source://rubyntlm//lib/net/ntlm/client/session.rb#122 def client_cipher; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#117 + # source://rubyntlm//lib/net/ntlm/client/session.rb#114 def client_seal_key; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#109 + # source://rubyntlm//lib/net/ntlm/client/session.rb#106 def client_sign_key; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#179 + # source://rubyntlm//lib/net/ntlm/client/session.rb#165 def domain; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#199 + # source://rubyntlm//lib/net/ntlm/client/session.rb#190 def lmv2_resp; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#163 + # source://rubyntlm//lib/net/ntlm/client/session.rb#149 def negotiate_key_exchange?; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#207 + # source://rubyntlm//lib/net/ntlm/client/session.rb#198 def nt_proof_str; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#191 + # source://rubyntlm//lib/net/ntlm/client/session.rb#177 def ntlmv2_hash; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#203 + # source://rubyntlm//lib/net/ntlm/client/session.rb#194 def ntlmv2_resp; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#183 + # source://rubyntlm//lib/net/ntlm/client/session.rb#169 def oem_or_unicode_str(str); end - # source://rubyntlm//lib/net/ntlm/client/session.rb#171 + # source://rubyntlm//lib/net/ntlm/client/session.rb#157 def password; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#101 + # source://rubyntlm//lib/net/ntlm/client/session.rb#98 def raw_sequence; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#97 + # source://rubyntlm//lib/net/ntlm/client/session.rb#94 def sequence; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#149 + # source://rubyntlm//lib/net/ntlm/client/session.rb#134 def server_challenge; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#135 + # source://rubyntlm//lib/net/ntlm/client/session.rb#126 def server_cipher; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#121 + # source://rubyntlm//lib/net/ntlm/client/session.rb#118 def server_seal_key; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#113 + # source://rubyntlm//lib/net/ntlm/client/session.rb#110 def server_sign_key; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#222 + # source://rubyntlm//lib/net/ntlm/client/session.rb#213 def target_info; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#155 + # source://rubyntlm//lib/net/ntlm/client/session.rb#140 def timestamp; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#159 + # source://rubyntlm//lib/net/ntlm/client/session.rb#144 def use_oem_strings?; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#93 + # source://rubyntlm//lib/net/ntlm/client/session.rb#90 def user_session_key; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#167 + # source://rubyntlm//lib/net/ntlm/client/session.rb#153 def username; end - # source://rubyntlm//lib/net/ntlm/client/session.rb#175 + # source://rubyntlm//lib/net/ntlm/client/session.rb#161 def workstation; end end @@ -589,31 +594,39 @@ class Net::NTLM::InvalidTargetDataError < ::Net::NTLM::NtlmError def data; end end +# source://rubyntlm//lib/net/ntlm/md4.rb#6 +class Net::NTLM::Md4 + class << self + # source://rubyntlm//lib/net/ntlm/md4.rb#15 + def digest(string); end + end +end + # @private false # -# source://rubyntlm//lib/net/ntlm/message.rb#40 +# source://rubyntlm//lib/net/ntlm/message.rb#47 class Net::NTLM::Message < ::Net::NTLM::FieldSet - # source://rubyntlm//lib/net/ntlm/message.rb#123 + # source://rubyntlm//lib/net/ntlm/message.rb#131 def data_edge; end - # source://rubyntlm//lib/net/ntlm/message.rb#103 + # source://rubyntlm//lib/net/ntlm/message.rb#110 def data_size; end - # source://rubyntlm//lib/net/ntlm/message.rb#97 + # source://rubyntlm//lib/net/ntlm/message.rb#104 def decode64(str); end - # source://rubyntlm//lib/net/ntlm/message.rb#116 + # source://rubyntlm//lib/net/ntlm/message.rb#123 def deflag; end - # source://rubyntlm//lib/net/ntlm/message.rb#84 + # source://rubyntlm//lib/net/ntlm/message.rb#91 def dump_flags; end - # source://rubyntlm//lib/net/ntlm/message.rb#93 + # source://rubyntlm//lib/net/ntlm/message.rb#100 def encode64; end # @return [Boolean] # - # source://rubyntlm//lib/net/ntlm/message.rb#76 + # source://rubyntlm//lib/net/ntlm/message.rb#83 def has_flag?(flag); end # source://rubyntlm//lib/net/ntlm/field_set.rb#99 @@ -621,26 +634,26 @@ class Net::NTLM::Message < ::Net::NTLM::FieldSet # @return [self] # - # source://rubyntlm//lib/net/ntlm/message.rb#64 + # source://rubyntlm//lib/net/ntlm/message.rb#71 def parse(str); end - # source://rubyntlm//lib/net/ntlm/message.rb#112 + # source://rubyntlm//lib/net/ntlm/message.rb#119 def security_buffers; end - # source://rubyntlm//lib/net/ntlm/message.rb#88 + # source://rubyntlm//lib/net/ntlm/message.rb#95 def serialize; end - # source://rubyntlm//lib/net/ntlm/message.rb#80 + # source://rubyntlm//lib/net/ntlm/message.rb#87 def set_flag(flag); end - # source://rubyntlm//lib/net/ntlm/message.rb#107 + # source://rubyntlm//lib/net/ntlm/message.rb#114 def size; end class << self - # source://rubyntlm//lib/net/ntlm/message.rb#58 + # source://rubyntlm//lib/net/ntlm/message.rb#65 def decode64(str); end - # source://rubyntlm//lib/net/ntlm/message.rb#42 + # source://rubyntlm//lib/net/ntlm/message.rb#49 def parse(str); end end end @@ -888,6 +901,23 @@ class Net::NTLM::Message::Type3 < ::Net::NTLM::Message end end +# source://rubyntlm//lib/net/ntlm/rc4.rb#11 +class Net::NTLM::Rc4 + # source://rubyntlm//lib/net/ntlm/rc4.rb#12 + def initialize(str); end + + # source://rubyntlm//lib/net/ntlm/rc4.rb#18 + def encrypt(text); end + + private + + # source://rubyntlm//lib/net/ntlm/rc4.rb#33 + def initialize_state(key); end +end + +# source://rubyntlm//lib/net/ntlm/rc4.rb#30 +Net::NTLM::Rc4::INITIAL_STATE = T.let(T.unsafe(nil), Array) + # source://rubyntlm//lib/net/ntlm/security_buffer.rb#5 class Net::NTLM::SecurityBuffer < ::Net::NTLM::FieldSet # @return [SecurityBuffer] a new instance of SecurityBuffer diff --git a/sorbet/rbi/gems/rubyzip@2.3.2.rbi b/sorbet/rbi/gems/rubyzip@2.3.2.rbi index 0f525aff3..864439694 100644 --- a/sorbet/rbi/gems/rubyzip@2.3.2.rbi +++ b/sorbet/rbi/gems/rubyzip@2.3.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `rubyzip` gem. # Please instead update this file by running `bin/tapioca gem rubyzip`. + # source://rubyzip//lib/zip/constants.rb#1 module Zip extend ::Zip @@ -1796,6 +1797,7 @@ end # # source://rubyzip//lib/zip/ioextras/abstract_input_stream.rb#6 module Zip::IOExtras::AbstractInputStream + include ::ActiveSupport::ToJsonWithActiveSupportEncoder include ::Enumerable include ::Zip::IOExtras::FakeIO @@ -2135,6 +2137,7 @@ end # source://rubyzip//lib/zip/null_input_stream.rb#2 module Zip::NullInputStream include ::Zip::NullDecompressor + include ::ActiveSupport::ToJsonWithActiveSupportEncoder include ::Enumerable include ::Zip::IOExtras::FakeIO include ::Zip::IOExtras::AbstractInputStream diff --git a/sorbet/rbi/gems/sass-listen@4.0.0.rbi b/sorbet/rbi/gems/sass-listen@4.0.0.rbi index e68d3a3e0..d98476274 100644 --- a/sorbet/rbi/gems/sass-listen@4.0.0.rbi +++ b/sorbet/rbi/gems/sass-listen@4.0.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `sass-listen` gem. # Please instead update this file by running `bin/tapioca gem sass-listen`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/sass-rails@6.0.0.rbi b/sorbet/rbi/gems/sass-rails@6.0.0.rbi index 6fee693d0..b37d089a0 100644 --- a/sorbet/rbi/gems/sass-rails@6.0.0.rbi +++ b/sorbet/rbi/gems/sass-rails@6.0.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `sass-rails` gem. # Please instead update this file by running `bin/tapioca gem sass-rails`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/sass@3.7.4.rbi b/sorbet/rbi/gems/sass@3.7.4.rbi index 3054ea91f..47dca63fa 100644 --- a/sorbet/rbi/gems/sass@3.7.4.rbi +++ b/sorbet/rbi/gems/sass@3.7.4.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `sass` gem. # Please instead update this file by running `bin/tapioca gem sass`. + # The module that contains everything Sass-related: # # * {Sass::Engine} is the class used to render Sass/SCSS within Ruby code. diff --git a/sorbet/rbi/gems/sassc-rails@2.1.2.rbi b/sorbet/rbi/gems/sassc-rails@2.1.2.rbi index 0e083d987..3a2945326 100644 --- a/sorbet/rbi/gems/sassc-rails@2.1.2.rbi +++ b/sorbet/rbi/gems/sassc-rails@2.1.2.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `sassc-rails` gem. # Please instead update this file by running `bin/tapioca gem sassc-rails`. + # source://sassc-rails//lib/sassc/rails/version.rb#3 module SassC class << self @@ -167,9 +168,6 @@ end # source://sassc-rails//lib/sassc/rails/version.rb#5 SassC::Rails::VERSION = T.let(T.unsafe(nil), String) -# source://sassc/2.4.0/lib/sassc/version.rb#4 -SassC::VERSION = T.let(T.unsafe(nil), String) - # source://sassc-rails//lib/sassc/rails/functions.rb#5 module Sprockets extend ::Sprockets::Utils @@ -187,9 +185,6 @@ module Sprockets extend ::Sprockets::Paths end -# source://sprockets/4.2.0/lib/sprockets/sass_cache_store.rb#29 -Sprockets::SassCacheStore = Sprockets::SassProcessor::CacheStore - # source://sassc-rails//lib/sassc/rails/compressor.rb#6 class Sprockets::SassCompressor # @return [SassCompressor] a new instance of SassCompressor @@ -197,7 +192,7 @@ class Sprockets::SassCompressor # source://sassc-rails//lib/sassc/rails/compressor.rb#7 def initialize(options = T.unsafe(nil)); end - # source://sprockets/4.2.0/lib/sprockets/sass_compressor.rb#37 + # source://sprockets/4.2.1/lib/sprockets/sass_compressor.rb#37 def cache_key; end # source://sassc-rails//lib/sassc/rails/compressor.rb#17 @@ -209,22 +204,13 @@ class Sprockets::SassCompressor def evaluate(*args); end class << self - # source://sprockets/4.2.0/lib/sprockets/sass_compressor.rb#33 + # source://sprockets/4.2.1/lib/sprockets/sass_compressor.rb#33 def cache_key; end - # source://sprockets/4.2.0/lib/sprockets/sass_compressor.rb#29 + # source://sprockets/4.2.1/lib/sprockets/sass_compressor.rb#29 def call(input); end - # source://sprockets/4.2.0/lib/sprockets/sass_compressor.rb#25 + # source://sprockets/4.2.1/lib/sprockets/sass_compressor.rb#25 def instance; end end end - -# source://sprockets/4.2.0/lib/sprockets/sass_compressor.rb#20 -Sprockets::SassCompressor::VERSION = T.let(T.unsafe(nil), String) - -# source://sprockets/4.2.0/lib/sprockets/sass_processor.rb#312 -Sprockets::SassFunctions = Sprockets::SassProcessor::Functions - -# source://sprockets/4.2.0/lib/sprockets/version.rb#3 -Sprockets::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/sassc@2.4.0.rbi b/sorbet/rbi/gems/sassc@2.4.0.rbi index 4f0d49f39..9db7607ee 100644 --- a/sorbet/rbi/gems/sassc@2.4.0.rbi +++ b/sorbet/rbi/gems/sassc@2.4.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `sassc` gem. # Please instead update this file by running `bin/tapioca gem sassc`. + # source://sassc//lib/sassc.rb#3 module SassC class << self diff --git a/sorbet/rbi/gems/sd_notify@0.1.1.rbi b/sorbet/rbi/gems/sd_notify@0.1.1.rbi new file mode 100644 index 000000000..29d9a3552 --- /dev/null +++ b/sorbet/rbi/gems/sd_notify@0.1.1.rbi @@ -0,0 +1,111 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `sd_notify` gem. +# Please instead update this file by running `bin/tapioca gem sd_notify`. + + +# SdNotify is a pure-Ruby implementation of sd_notify(3). It can be used to +# notify systemd about state changes. Methods of this package are no-op on +# non-systemd systems (eg. Darwin). +# +# The API maps closely to the original implementation of sd_notify(3), +# therefore be sure to check the official man pages prior to using SdNotify. +# +# @see https://www.freedesktop.org/software/systemd/man/sd_notify.html +# +# source://sd_notify//lib/sd_notify.rb#13 +module SdNotify + class << self + # @param errno [Integer] + # + # source://sd_notify//lib/sd_notify.rb#45 + def errno(errno, unset_env = T.unsafe(nil)); end + + # source://sd_notify//lib/sd_notify.rb#58 + def fdstore(unset_env = T.unsafe(nil)); end + + # @param pid [Integer] + # + # source://sd_notify//lib/sd_notify.rb#50 + def mainpid(pid, unset_env = T.unsafe(nil)); end + + # Notify systemd with the provided state, via the notification socket, if + # any. + # + # Generally this method will be used indirectly through the other methods + # of the library. + # + # @param state [String] + # @param unset_env [Boolean] + # @raise [NotifyError] if there was an error communicating with the systemd + # socket + # @return [Fixnum, nil] the number of bytes written to the notification + # socket or nil if there was no socket to report to (eg. the program wasn't + # started by systemd) + # @see https://www.freedesktop.org/software/systemd/man/sd_notify.html + # + # source://sd_notify//lib/sd_notify.rb#106 + def notify(state, unset_env = T.unsafe(nil)); end + + # source://sd_notify//lib/sd_notify.rb#26 + def ready(unset_env = T.unsafe(nil)); end + + # source://sd_notify//lib/sd_notify.rb#30 + def reloading(unset_env = T.unsafe(nil)); end + + # @param status [String] a custom status string that describes the current + # state of the service + # + # source://sd_notify//lib/sd_notify.rb#40 + def status(status, unset_env = T.unsafe(nil)); end + + # source://sd_notify//lib/sd_notify.rb#34 + def stopping(unset_env = T.unsafe(nil)); end + + # source://sd_notify//lib/sd_notify.rb#54 + def watchdog(unset_env = T.unsafe(nil)); end + + # If the $WATCHDOG_USEC environment variable is set, + # and the $WATCHDOG_PID variable is unset or set to the PID of the current + # process + # + # @note Unlike sd_watchdog_enabled(3), this method does not mutate the + # environment. + # @param true [Boolean] if the service manager expects watchdog keep-alive + # notification messages to be sent from this process. + # @return [Boolean] + # + # source://sd_notify//lib/sd_notify.rb#71 + def watchdog?; end + end +end + +# source://sd_notify//lib/sd_notify.rb#21 +SdNotify::ERRNO = T.let(T.unsafe(nil), String) + +# source://sd_notify//lib/sd_notify.rb#24 +SdNotify::FDSTORE = T.let(T.unsafe(nil), String) + +# source://sd_notify//lib/sd_notify.rb#22 +SdNotify::MAINPID = T.let(T.unsafe(nil), String) + +# Exception raised when there's an error writing to the notification socket +# +# source://sd_notify//lib/sd_notify.rb#15 +class SdNotify::NotifyError < ::RuntimeError; end + +# source://sd_notify//lib/sd_notify.rb#17 +SdNotify::READY = T.let(T.unsafe(nil), String) + +# source://sd_notify//lib/sd_notify.rb#18 +SdNotify::RELOADING = T.let(T.unsafe(nil), String) + +# source://sd_notify//lib/sd_notify.rb#20 +SdNotify::STATUS = T.let(T.unsafe(nil), String) + +# source://sd_notify//lib/sd_notify.rb#19 +SdNotify::STOPPING = T.let(T.unsafe(nil), String) + +# source://sd_notify//lib/sd_notify.rb#23 +SdNotify::WATCHDOG = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/securerandom@0.3.1.rbi b/sorbet/rbi/gems/securerandom@0.3.1.rbi new file mode 100644 index 000000000..6e8b28c8d --- /dev/null +++ b/sorbet/rbi/gems/securerandom@0.3.1.rbi @@ -0,0 +1,73 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `securerandom` gem. +# Please instead update this file by running `bin/tapioca gem securerandom`. + + +# == Secure random number generator interface. +# +# This library is an interface to secure random number generators which are +# suitable for generating session keys in HTTP cookies, etc. +# +# You can use this library in your application by requiring it: +# +# require 'securerandom' +# +# It supports the following secure random number generators: +# +# * openssl +# * /dev/urandom +# * Win32 +# +# SecureRandom is extended by the Random::Formatter module which +# defines the following methods: +# +# * alphanumeric +# * base64 +# * choose +# * gen_random +# * hex +# * rand +# * random_bytes +# * random_number +# * urlsafe_base64 +# * uuid +# +# These methods are usable as class methods of SecureRandom such as +# +SecureRandom.hex+. +# +# If a secure random number generator is not available, +# +NotImplementedError+ is raised. +module SecureRandom + extend ::Random::Formatter + + class << self + # Returns a random binary string containing +size+ bytes. + # + # See Random.bytes + # + # source://securerandom//securerandom.rb#50 + def bytes(n); end + + # source://securerandom//securerandom.rb#64 + def gen_random(n); end + + private + + # Implementation using OpenSSL + # + # source://securerandom//securerandom.rb#59 + def gen_random_openssl(n); end + + # Implementation using system random device + # + # source://securerandom//securerandom.rb#64 + def gen_random_urandom(n); end + end +end + +# The version +# +# source://securerandom//securerandom.rb#44 +SecureRandom::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/sentry-rails@5.19.0.rbi b/sorbet/rbi/gems/sentry-rails@5.19.0.rbi new file mode 100644 index 000000000..620d81f59 --- /dev/null +++ b/sorbet/rbi/gems/sentry-rails@5.19.0.rbi @@ -0,0 +1,988 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `sentry-rails` gem. +# Please instead update this file by running `bin/tapioca gem sentry-rails`. + + +# source://sentry-rails//lib/sentry/rails/version.rb#1 +module Sentry + class << self + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#216 + def add_attachment(**opts); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#311 + def add_breadcrumb(breadcrumb, **options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#530 + def add_global_event_processor(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#104 + def apply_patches(config); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#72 + def background_worker; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#72 + def background_worker=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#80 + def backpressure_monitor; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#470 + def capture_check_in(slug, status, **options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#454 + def capture_event(event); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#418 + def capture_exception(exception, **options, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#446 + def capture_message(message, **options, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#348 + def clone_hub_to_current_thread; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#249 + def close; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#156 + def configuration; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#364 + def configure_scope(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#574 + def continue_trace(env, **options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#296 + def csp_report_uri; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#512 + def exception_captured?(exc); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#54 + def exception_locals_tp; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#547 + def get_baggage; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#332 + def get_current_client; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#321 + def get_current_hub; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#340 + def get_current_scope; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#304 + def get_main_hub; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#556 + def get_trace_propagation_headers; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#565 + def get_trace_propagation_meta; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#538 + def get_traceparent; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#227 + def init(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#284 + def initialized?; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#120 + def integrations; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#504 + def last_event_id; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#590 + def logger; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#84 + def metrics_aggregator; end + + # source://railties/7.2.0/lib/rails/engine.rb#412 + def railtie_helpers_paths; end + + # source://railties/7.2.0/lib/rails/engine.rb#395 + def railtie_namespace; end + + # source://railties/7.2.0/lib/rails/engine.rb#416 + def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#128 + def register_integration(name, version); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#89 + def register_patch(key, patch = T.unsafe(nil), target = T.unsafe(nil), &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#111 + def registered_patches; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#595 + def sdk_meta; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#163 + def send_event(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#76 + def session_flusher; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#209 + def set_context(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#195 + def set_extras(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#188 + def set_tags(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#202 + def set_user(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#478 + def start_transaction(**options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#582 + def sys_command(command); end + + # source://railties/7.2.0/lib/rails/engine.rb#401 + def table_name_prefix; end + + # source://railties/7.2.0/lib/rails/engine.rb#408 + def use_relative_model_naming?; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#600 + def utc_now; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#496 + def with_child_span(**attributes, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#435 + def with_exception_captured(**options, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#389 + def with_scope(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#409 + def with_session_tracking(&block); end + end +end + +# source://sentry-rails//lib/sentry/rails/configuration.rb#7 +class Sentry::Configuration + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#351 + def initialize; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#26 + def app_dirs_pattern; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#26 + def app_dirs_pattern=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#33 + def async; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#412 + def async=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#269 + def auto_session_tracking; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#269 + def auto_session_tracking=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#50 + def background_worker_max_queue; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#50 + def background_worker_max_queue=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#43 + def background_worker_threads; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#43 + def background_worker_threads=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#61 + def backtrace_cleanup_callback; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#61 + def backtrace_cleanup_callback=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#70 + def before_breadcrumb; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#453 + def before_breadcrumb=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#84 + def before_send; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#441 + def before_send=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#97 + def before_send_transaction; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#447 + def before_send_transaction=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#109 + def breadcrumbs_logger; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#428 + def breadcrumbs_logger=(logger); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#152 + def capture_exception_frame_locals; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#166 + def capture_exception_frame_locals=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#117 + def context_lines; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#117 + def context_lines=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#237 + def cron; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#542 + def csp_report_uri; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#126 + def debug; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#126 + def debug=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#563 + def detect_release; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#130 + def dsn; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#400 + def dsn=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#275 + def enable_backpressure_handling; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#275 + def enable_backpressure_handling=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#260 + def enable_tracing; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#467 + def enable_tracing=(enable_tracing); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#134 + def enabled_environments; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#134 + def enabled_environments=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#520 + def enabled_in_current_env?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#295 + def enabled_patches; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#295 + def enabled_patches=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#121 + def environment; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#459 + def environment=(environment); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#576 + def error_messages; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#299 + def errors; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#507 + def exception_class_allowed?(exc); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#138 + def exclude_loggers; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#138 + def exclude_loggers=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#143 + def excluded_exceptions; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#143 + def excluded_exceptions=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#299 + def gem_specs; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#152 + def include_local_variables; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#152 + def include_local_variables=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#284 + def instrumenter; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#463 + def instrumenter=(instrumenter); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#472 + def is_numeric_or_nil?(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#178 + def linecache; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#178 + def linecache=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#183 + def logger; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#183 + def logger=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#113 + def max_breadcrumbs; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#113 + def max_breadcrumbs=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#241 + def metrics; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#290 + def profiles_sample_rate; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#481 + def profiles_sample_rate=(profiles_sample_rate); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#535 + def profiling_enabled?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#188 + def project_root; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#188 + def project_root=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#192 + def propagate_traces; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#192 + def propagate_traces=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#196 + def rack_env_whitelist; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#196 + def rack_env_whitelist=(_arg0); end + + # Returns the value of attribute rails. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#8 + def rails; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#201 + def release; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#406 + def release=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#497 + def sample_allowed?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#206 + def sample_rate; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#206 + def sample_rate=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#265 + def send_client_reports; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#265 + def send_client_reports=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#219 + def send_default_pii; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#219 + def send_default_pii=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#210 + def send_modules; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#210 + def send_modules=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#487 + def sending_allowed?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#491 + def sending_to_dsn_allowed?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#400 + def server=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#229 + def server_name; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#229 + def server_name=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#503 + def session_tracking?; end + + # source://sentry-sidekiq/5.19.0/lib/sentry/sidekiq/configuration.rb#3 + def sidekiq; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#223 + def skip_rake_integration; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#223 + def skip_rake_integration=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#160 + def spotlight; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#160 + def spotlight=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#552 + def stacktrace_builder; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#280 + def trace_propagation_targets; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#280 + def trace_propagation_targets=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#245 + def traces_sample_rate; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#476 + def traces_sample_rate=(traces_sample_rate); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#255 + def traces_sampler; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#255 + def traces_sampler=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#529 + def tracing_enabled?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#233 + def transport; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#226 + def trusted_proxies; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#226 + def trusted_proxies=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#524 + def valid_sample_rate?(sample_rate); end + + private + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#618 + def capture_in_environment?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#634 + def environment_from_env; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#589 + def excluded_exception?(incoming_exception); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#595 + def excluded_exception_classes; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#599 + def get_exception_class(x); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#583 + def init_dsn(dsn_string); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#603 + def matches_exception?(excluded_exception_class, incoming_exception); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#658 + def processor_count; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#652 + def run_post_initialization_callbacks; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#648 + def running_on_heroku?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#611 + def safe_const_get(x); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#638 + def server_name_from_env; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#625 + def valid?; end + + class << self + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#346 + def add_post_initialization_callback(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#341 + def post_initialization_callbacks; end + end +end + +# source://sentry-rails//lib/sentry/rails/engine.rb#2 +class Sentry::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end + +# source://sentry-rails//lib/sentry/rails/version.rb#2 +module Sentry::Rails + extend ::Sentry::Integrable +end + +# source://sentry-rails//lib/sentry/rails/configuration.rb#50 +Sentry::Rails::ACTIVE_SUPPORT_LOGGER_SUBSCRIPTION_ITEMS_DEFAULT = T.let(T.unsafe(nil), Hash) + +# source://sentry-rails//lib/sentry/rails/backtrace_cleaner.rb#6 +class Sentry::Rails::BacktraceCleaner < ::ActiveSupport::BacktraceCleaner + # @return [BacktraceCleaner] a new instance of BacktraceCleaner + # + # source://sentry-rails//lib/sentry/rails/backtrace_cleaner.rb#10 + def initialize; end +end + +# source://sentry-rails//lib/sentry/rails/backtrace_cleaner.rb#7 +Sentry::Rails::BacktraceCleaner::APP_DIRS_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://sentry-rails//lib/sentry/rails/backtrace_cleaner.rb#8 +Sentry::Rails::BacktraceCleaner::RENDER_TEMPLATE_PATTERN = T.let(T.unsafe(nil), Regexp) + +# source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#3 +class Sentry::Rails::CaptureExceptions < ::Sentry::Rack::CaptureExceptions + # @return [CaptureExceptions] a new instance of CaptureExceptions + # + # source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#7 + def initialize(_); end + + private + + # source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#26 + def capture_exception(exception, env); end + + # source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#17 + def collect_exception(env); end + + # @return [Boolean] + # + # source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#51 + def show_exceptions?(exception, env); end + + # source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#35 + def start_transaction(env, scope); end + + # source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#22 + def transaction_op; end +end + +# source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#4 +Sentry::Rails::CaptureExceptions::RAILS_7_1 = T.let(T.unsafe(nil), TrueClass) + +# source://sentry-rails//lib/sentry/rails/capture_exceptions.rb#5 +Sentry::Rails::CaptureExceptions::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/configuration.rb#110 +class Sentry::Rails::Configuration + # @return [Configuration] a new instance of Configuration + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#156 + def initialize; end + + # Hash of subscription items that will be shown in breadcrumbs active support logger. + # + # @return [Hash>] + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#154 + def active_support_logger_subscription_items; end + + # Hash of subscription items that will be shown in breadcrumbs active support logger. + # + # @return [Hash>] + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#154 + def active_support_logger_subscription_items=(_arg0); end + + # sentry-rails by default skips asset request' transactions by checking if the path matches + # + # ```rb + # %r(\A/{0,2}#{::Rails.application.config.assets.prefix}) + # ``` + # + # If you want to use a different pattern, you can configure the `assets_regexp` option like: + # + # ```rb + # Sentry.init do |config| + # config.rails.assets_regexp = /my_regexp/ + # end + # ``` + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#150 + def assets_regexp; end + + # sentry-rails by default skips asset request' transactions by checking if the path matches + # + # ```rb + # %r(\A/{0,2}#{::Rails.application.config.assets.prefix}) + # ``` + # + # If you want to use a different pattern, you can configure the `assets_regexp` option like: + # + # ```rb + # Sentry.init do |config| + # config.rails.assets_regexp = /my_regexp/ + # end + # ``` + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#150 + def assets_regexp=(_arg0); end + + # The threshold in milliseconds for the ActiveRecordSubscriber to capture the source location of the query + # in the span data. Default is 100ms. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#135 + def db_query_source_threshold_ms; end + + # The threshold in milliseconds for the ActiveRecordSubscriber to capture the source location of the query + # in the span data. Default is 100ms. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#135 + def db_query_source_threshold_ms=(_arg0); end + + # When the ActiveRecordSubscriber is enabled, capture the source location of the query in the span data. + # This is enabled by default, but can be disabled by setting this to false. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#131 + def enable_db_query_source; end + + # When the ActiveRecordSubscriber is enabled, capture the source location of the query in the span data. + # This is enabled by default, but can be disabled by setting this to false. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#131 + def enable_db_query_source=(_arg0); end + + # Rails 7.0 introduced a new error reporter feature, which the SDK once opted-in by default. + # But after receiving multiple issue reports, the integration seemed to cause serious troubles to some users. + # So the integration is now controlled by this configuration, which is disabled (false) by default. + # More information can be found from: https://github.com/rails/rails/pull/43625#issuecomment-1072514175 + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#115 + def register_error_subscriber; end + + # Rails 7.0 introduced a new error reporter feature, which the SDK once opted-in by default. + # But after receiving multiple issue reports, the integration seemed to cause serious troubles to some users. + # So the integration is now controlled by this configuration, which is disabled (false) by default. + # More information can be found from: https://github.com/rails/rails/pull/43625#issuecomment-1072514175 + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#115 + def register_error_subscriber=(_arg0); end + + # Rails catches exceptions in the ActionDispatch::ShowExceptions or + # ActionDispatch::DebugExceptions middlewares, depending on the environment. + # When `report_rescued_exceptions` is true (it is by default), Sentry will + # report exceptions even when they are rescued by these middlewares. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#121 + def report_rescued_exceptions; end + + # Rails catches exceptions in the ActionDispatch::ShowExceptions or + # ActionDispatch::DebugExceptions middlewares, depending on the environment. + # When `report_rescued_exceptions` is true (it is by default), Sentry will + # report exceptions even when they are rescued by these middlewares. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#121 + def report_rescued_exceptions=(_arg0); end + + # Some adapters, like sidekiq, already have their own sentry integration. + # In those cases, we should skip ActiveJob's reporting to avoid duplicated reports. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#125 + def skippable_job_adapters; end + + # Some adapters, like sidekiq, already have their own sentry integration. + # In those cases, we should skip ActiveJob's reporting to avoid duplicated reports. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#125 + def skippable_job_adapters=(_arg0); end + + # Returns the value of attribute tracing_subscribers. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#127 + def tracing_subscribers; end + + # Sets the attribute tracing_subscribers + # + # @param value the value to set the attribute tracing_subscribers to. + # + # source://sentry-rails//lib/sentry/rails/configuration.rb#127 + def tracing_subscribers=(_arg0); end +end + +# source://sentry-rails//lib/sentry/rails/configuration.rb#33 +Sentry::Rails::IGNORE_DEFAULT = T.let(T.unsafe(nil), Array) + +# source://sentry-rails//lib/sentry/rails/instrument_payload_cleanup_helper.rb#3 +module Sentry::Rails::InstrumentPayloadCleanupHelper + # source://sentry-rails//lib/sentry/rails/instrument_payload_cleanup_helper.rb#6 + def cleanup_data(data); end +end + +# source://sentry-rails//lib/sentry/rails/instrument_payload_cleanup_helper.rb#4 +Sentry::Rails::InstrumentPayloadCleanupHelper::IGNORED_DATA_TYPES = T.let(T.unsafe(nil), Array) + +# source://sentry-rails//lib/sentry/rails/rescued_exception_interceptor.rb#3 +class Sentry::Rails::RescuedExceptionInterceptor + # @return [RescuedExceptionInterceptor] a new instance of RescuedExceptionInterceptor + # + # source://sentry-rails//lib/sentry/rails/rescued_exception_interceptor.rb#4 + def initialize(app); end + + # source://sentry-rails//lib/sentry/rails/rescued_exception_interceptor.rb#8 + def call(env); end + + # @return [Boolean] + # + # source://sentry-rails//lib/sentry/rails/rescued_exception_interceptor.rb#19 + def report_rescued_exceptions?; end +end + +# source://sentry-rails//lib/sentry/rails/tracing.rb#3 +module Sentry::Rails::Tracing + class << self + # source://sentry-rails//lib/sentry/rails/tracing.rb#69 + def get_current_transaction; end + + # this is necessary because instrumentation events don't record absolute start/finish time + # so we need to retrieve the correct time this way + # + # source://sentry-rails//lib/sentry/rails/tracing.rb#42 + def patch_active_support_notifications; end + + # source://sentry-rails//lib/sentry/rails/tracing.rb#6 + def register_subscribers(subscribers); end + + # source://sentry-rails//lib/sentry/rails/tracing.rb#59 + def remove_active_support_notifications_patch; end + + # source://sentry-rails//lib/sentry/rails/tracing.rb#18 + def subscribe_tracing_events; end + + # source://sentry-rails//lib/sentry/rails/tracing.rb#14 + def subscribed_tracing_events; end + + # source://sentry-rails//lib/sentry/rails/tracing.rb#10 + def subscribers; end + + # source://sentry-rails//lib/sentry/rails/tracing.rb#31 + def unsubscribe_tracing_events; end + end +end + +# source://sentry-rails//lib/sentry/rails/tracing/abstract_subscriber.rb#4 +class Sentry::Rails::Tracing::AbstractSubscriber + class << self + # source://sentry-rails//lib/sentry/rails/tracing/abstract_subscriber.rb#39 + def record_on_current_span(duration:, **options); end + + # @raise [NotImplementedError] + # + # source://sentry-rails//lib/sentry/rails/tracing/abstract_subscriber.rb#6 + def subscribe!; end + + # source://sentry-rails//lib/sentry/rails/tracing/abstract_subscriber.rb#28 + def subscribe_to_event(event_names); end + + # source://sentry-rails//lib/sentry/rails/tracing/abstract_subscriber.rb#10 + def unsubscribe!; end + end +end + +# source://sentry-rails//lib/sentry/rails/tracing/action_controller_subscriber.rb#7 +class Sentry::Rails::Tracing::ActionControllerSubscriber < ::Sentry::Rails::Tracing::AbstractSubscriber + extend ::Sentry::Rails::InstrumentPayloadCleanupHelper + + class << self + # source://sentry-rails//lib/sentry/rails/tracing/action_controller_subscriber.rb#14 + def subscribe!; end + end +end + +# source://sentry-rails//lib/sentry/rails/tracing/action_controller_subscriber.rb#10 +Sentry::Rails::Tracing::ActionControllerSubscriber::EVENT_NAMES = T.let(T.unsafe(nil), Array) + +# source://sentry-rails//lib/sentry/rails/tracing/action_controller_subscriber.rb#11 +Sentry::Rails::Tracing::ActionControllerSubscriber::OP_NAME = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/tracing/action_controller_subscriber.rb#12 +Sentry::Rails::Tracing::ActionControllerSubscriber::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/tracing/action_view_subscriber.rb#6 +class Sentry::Rails::Tracing::ActionViewSubscriber < ::Sentry::Rails::Tracing::AbstractSubscriber + class << self + # source://sentry-rails//lib/sentry/rails/tracing/action_view_subscriber.rb#11 + def subscribe!; end + end +end + +# source://sentry-rails//lib/sentry/rails/tracing/action_view_subscriber.rb#7 +Sentry::Rails::Tracing::ActionViewSubscriber::EVENT_NAMES = T.let(T.unsafe(nil), Array) + +# source://sentry-rails//lib/sentry/rails/tracing/action_view_subscriber.rb#9 +Sentry::Rails::Tracing::ActionViewSubscriber::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/tracing/action_view_subscriber.rb#8 +Sentry::Rails::Tracing::ActionViewSubscriber::SPAN_PREFIX = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#8 +class Sentry::Rails::Tracing::ActiveRecordSubscriber < ::Sentry::Rails::Tracing::AbstractSubscriber + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#17 + def backtrace_cleaner; end + + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#17 + def backtrace_cleaner=(_arg0); end + + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#17 + def backtrace_cleaner?; end + + class << self + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#17 + def backtrace_cleaner; end + + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#17 + def backtrace_cleaner=(value); end + + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#17 + def backtrace_cleaner?; end + + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#87 + def query_source_location; end + + # source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#23 + def subscribe!; end + end +end + +# source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#9 +Sentry::Rails::Tracing::ActiveRecordSubscriber::EVENT_NAMES = T.let(T.unsafe(nil), Array) + +# source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#12 +Sentry::Rails::Tracing::ActiveRecordSubscriber::EXCLUDED_EVENTS = T.let(T.unsafe(nil), Array) + +# source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#11 +Sentry::Rails::Tracing::ActiveRecordSubscriber::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#10 +Sentry::Rails::Tracing::ActiveRecordSubscriber::SPAN_PREFIX = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/tracing/active_record_subscriber.rb#14 +Sentry::Rails::Tracing::ActiveRecordSubscriber::SUPPORT_SOURCE_LOCATION = T.let(T.unsafe(nil), TrueClass) + +# source://sentry-rails//lib/sentry/rails/tracing/active_storage_subscriber.rb#6 +class Sentry::Rails::Tracing::ActiveStorageSubscriber < ::Sentry::Rails::Tracing::AbstractSubscriber + class << self + # source://sentry-rails//lib/sentry/rails/tracing/active_storage_subscriber.rb#24 + def subscribe!; end + end +end + +# source://sentry-rails//lib/sentry/rails/tracing/active_storage_subscriber.rb#7 +Sentry::Rails::Tracing::ActiveStorageSubscriber::EVENT_NAMES = T.let(T.unsafe(nil), Array) + +# source://sentry-rails//lib/sentry/rails/tracing/active_storage_subscriber.rb#22 +Sentry::Rails::Tracing::ActiveStorageSubscriber::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/tracing.rb#4 +Sentry::Rails::Tracing::START_TIMESTAMP_NAME = T.let(T.unsafe(nil), Symbol) + +# it's just a container for the extended method +# +# source://sentry-rails//lib/sentry/rails/tracing.rb#74 +module Sentry::Rails::Tracing::SentryNotificationExtension; end + +# source://sentry-rails//lib/sentry/rails/version.rb#3 +Sentry::Rails::VERSION = T.let(T.unsafe(nil), String) + +# source://sentry-rails//lib/sentry/rails/railtie.rb#6 +class Sentry::Railtie < ::Rails::Railtie + # source://sentry-rails//lib/sentry/rails/railtie.rb#125 + def activate_tracing; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#74 + def configure_cron_timezone; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#66 + def configure_project_root; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#70 + def configure_trusted_proxies; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#79 + def extend_controller_methods; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#95 + def inject_breadcrumbs_logger; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#117 + def override_streaming_reporter; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#91 + def patch_background_worker; end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#134 + def register_error_subscriber(app); end + + # source://sentry-rails//lib/sentry/rails/railtie.rb#109 + def setup_backtrace_cleanup_callback; end +end + +class Sentry::SendEventJob < ::ActiveJob::Base + def perform(event, hint = T.unsafe(nil)); end + + class << self + # source://activejob/7.2.0/lib/active_job/logging.rb#26 + def log_arguments; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end diff --git a/sorbet/rbi/gems/sentry-raven@3.1.2.rbi b/sorbet/rbi/gems/sentry-raven@3.1.2.rbi deleted file mode 100644 index 95abb7212..000000000 --- a/sorbet/rbi/gems/sentry-raven@3.1.2.rbi +++ /dev/null @@ -1,3214 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `sentry-raven` gem. -# Please instead update this file by running `bin/tapioca gem sentry-raven`. - -# source://american_date/1.2.0/lib/american_date.rb#16 -::AMERICAN_DATE_RE = T.let(T.unsafe(nil), Regexp) - -# source://ruby-openid/2.9.2/lib/openid/fetchers.rb#13 -::MAX_RESPONSE_KB = T.let(T.unsafe(nil), Integer) - -# source://yard/0.9.34/lib/yard.rb#61 -::RUBY18 = T.let(T.unsafe(nil), FalseClass) - -# source://yard/0.9.34/lib/yard.rb#62 -::RUBY19 = T.let(T.unsafe(nil), TrueClass) - -# source://sentry-raven//lib/raven/core_ext/object/deep_dup.rb#22 -class Array - include ::Enumerable - - # Returns a deep copy of array. - # - # array = [1, [2, 3]] - # dup = array.deep_dup - # dup[1][2] = 4 - # - # array[1][2] # => nil - # dup[1][2] # => 4 - # - # source://sentry-raven//lib/raven/core_ext/object/deep_dup.rb#31 - def deep_dup; end -end - -# source://activesupport/7.0.5/lib/active_support/core_ext/array/deprecated_conversions.rb#4 -Array::NOT_SET = T.let(T.unsafe(nil), Object) - -# source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#107 -class BigDecimal < ::Numeric - # BigDecimals are duplicable: - # - # BigDecimal("1.2").duplicable? # => true - # BigDecimal("1.2").dup # => # - # - # @return [Boolean] - # - # source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#112 - def duplicable?; end -end - -BigDecimal::EXCEPTION_NaN = T.let(T.unsafe(nil), Integer) -BigDecimal::VERSION = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/helpers/deprecation_helper.rb#1 -module DeprecationHelper - class << self - # source://sentry-raven//lib/raven/helpers/deprecation_helper.rb#2 - def deprecate_dasherized_filename(correct_filename); end - - # source://sentry-raven//lib/raven/helpers/deprecation_helper.rb#6 - def deprecate_old_breadcrumbs_configuration(logger); end - end -end - -# source://sentry-raven//lib/raven/core_ext/object/deep_dup.rb#36 -class Hash - include ::Enumerable - - # Returns a deep copy of hash. - # - # hash = { a: { b: 'b' } } - # dup = hash.deep_dup - # dup[:a][:c] = 'c' - # - # hash[:a][:c] # => nil - # dup[:a][:c] # => "c" - # - # source://sentry-raven//lib/raven/core_ext/object/deep_dup.rb#45 - def deep_dup; end -end - -# source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#117 -class Method - # Methods are not duplicable: - # - # method(:puts).duplicable? # => false - # method(:puts).dup # => TypeError: allocator undefined for Method - # - # @return [Boolean] - # - # source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#122 - def duplicable?; end -end - -# source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#92 -class Numeric - include ::Comparable -end - -# source://activesupport/7.0.5/lib/active_support/core_ext/numeric/bytes.rb#9 -Numeric::EXABYTE = T.let(T.unsafe(nil), Integer) - -# source://activesupport/7.0.5/lib/active_support/core_ext/numeric/bytes.rb#6 -Numeric::GIGABYTE = T.let(T.unsafe(nil), Integer) - -# source://activesupport/7.0.5/lib/active_support/core_ext/numeric/bytes.rb#4 -Numeric::KILOBYTE = T.let(T.unsafe(nil), Integer) - -# source://activesupport/7.0.5/lib/active_support/core_ext/numeric/bytes.rb#5 -Numeric::MEGABYTE = T.let(T.unsafe(nil), Integer) - -# source://activesupport/7.0.5/lib/active_support/core_ext/numeric/bytes.rb#8 -Numeric::PETABYTE = T.let(T.unsafe(nil), Integer) - -# source://activesupport/7.0.5/lib/active_support/core_ext/numeric/bytes.rb#7 -Numeric::TERABYTE = T.let(T.unsafe(nil), Integer) - -# -- -# Most objects are cloneable, but not all. For example you can't dup methods: -# -# method(:puts).dup # => TypeError: allocator undefined for Method -# -# Classes may signal their instances are not duplicable removing +dup+/+clone+ -# or raising exceptions from them. So, to dup an arbitrary object you normally -# use an optimistic approach and are ready to catch an exception, say: -# -# arbitrary_object.dup rescue object -# -# Rails dups objects in a few critical spots where they are not that arbitrary. -# That rescue is very expensive (like 40 times slower than a predicate), and it -# is often triggered. -# -# That's why we hardcode the following cases and check duplicable? instead of -# using that rescue idiom. -# ++ -# -# source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#25 -class Object < ::BasicObject - include ::Kernel - include ::PP::ObjectMixin - - # Returns a deep copy of object if it's duplicable. If it's - # not duplicable, returns +self+. - # - # object = Object.new - # dup = object.deep_dup - # dup.instance_variable_set(:@a, 1) - # - # object.instance_variable_defined?(:@a) # => false - # dup.instance_variable_defined?(:@a) # => true - # - # source://sentry-raven//lib/raven/core_ext/object/deep_dup.rb#17 - def deep_dup; end - - # Can you safely dup this object? - # - # False for method objects; - # true otherwise. - # - # @return [Boolean] - # - # source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#30 - def duplicable?; end -end - -# source://sentry-raven//lib/raven/integrations/rake.rb#5 -module Rake - extend ::FileUtils::StreamUtils_ - extend ::FileUtils -end - -# source://sentry-raven//lib/raven/integrations/rake.rb#6 -class Rake::Application - # source://rake/13.0.6/lib/rake/application.rb#49 - def initialize; end - - # source://rake/13.0.6/lib/rake/application.rb#777 - def add_import(fn); end - - # source://rake/13.0.6/lib/rake/application.rb#139 - def add_loader(ext, loader); end - - # source://rake/13.0.6/lib/rake/application.rb#758 - def collect_command_line_tasks(args); end - - # source://rake/13.0.6/lib/rake/application.rb#772 - def default_task_name; end - - # source://rake/13.0.6/lib/rake/application.rb#258 - def deprecate(old_usage, new_usage, call_site); end - - # source://rake/13.0.6/lib/rake/application.rb#222 - def display_cause_details(ex); end - - # source://sentry-raven//lib/raven/integrations/rake.rb#8 - def display_error_message(ex); end - - # source://rake/13.0.6/lib/rake/application.rb#245 - def display_exception_backtrace(ex); end - - # source://rake/13.0.6/lib/rake/application.rb#214 - def display_exception_details(ex); end - - # source://rake/13.0.6/lib/rake/application.rb#229 - def display_exception_details_seen; end - - # source://rake/13.0.6/lib/rake/application.rb#237 - def display_exception_message_details(ex); end - - # source://rake/13.0.6/lib/rake/application.rb#381 - def display_prerequisites; end - - # source://rake/13.0.6/lib/rake/application.rb#298 - def display_tasks_and_comments; end - - # source://rake/13.0.6/lib/rake/application.rb#349 - def dynamic_width; end - - # source://rake/13.0.6/lib/rake/application.rb#353 - def dynamic_width_stty; end - - # source://rake/13.0.6/lib/rake/application.rb#357 - def dynamic_width_tput; end - - # source://rake/13.0.6/lib/rake/application.rb#201 - def exit_because_of_exception(ex); end - - # source://rake/13.0.6/lib/rake/application.rb#678 - def find_rakefile_location; end - - # source://rake/13.0.6/lib/rake/application.rb#644 - def handle_options(argv); end - - # source://rake/13.0.6/lib/rake/application.rb#233 - def has_cause?(ex); end - - # source://rake/13.0.6/lib/rake/application.rb#274 - def have_rakefile; end - - # source://rake/13.0.6/lib/rake/application.rb#88 - def init(app_name = T.unsafe(nil), argv = T.unsafe(nil)); end - - # source://rake/13.0.6/lib/rake/application.rb#157 - def invoke_task(task_string); end - - # source://rake/13.0.6/lib/rake/application.rb#782 - def load_imports; end - - # source://rake/13.0.6/lib/rake/application.rb#102 - def load_rakefile; end - - # source://rake/13.0.6/lib/rake/application.rb#24 - def name; end - - # source://rake/13.0.6/lib/rake/application.rb#145 - def options; end - - # source://rake/13.0.6/lib/rake/application.rb#206 - def orig_display_error_messsage(ex); end - - # source://rake/13.0.6/lib/rake/application.rb#27 - def original_dir; end - - # source://rake/13.0.6/lib/rake/application.rb#163 - def parse_task_string(string); end - - # source://rake/13.0.6/lib/rake/application.rb#690 - def print_rakefile_directory(location); end - - # source://rake/13.0.6/lib/rake/application.rb#664 - def rake_require(file_name, paths = T.unsafe(nil), loaded = T.unsafe(nil)); end - - # source://rake/13.0.6/lib/rake/application.rb#30 - def rakefile; end - - # source://rake/13.0.6/lib/rake/application.rb#798 - def rakefile_location(backtrace = T.unsafe(nil)); end - - # source://rake/13.0.6/lib/rake/application.rb#695 - def raw_load_rakefile; end - - # source://rake/13.0.6/lib/rake/application.rb#79 - def run(argv = T.unsafe(nil)); end - - # source://rake/13.0.6/lib/rake/application.rb#122 - def run_with_threads; end - - # source://rake/13.0.6/lib/rake/application.rb#807 - def set_default_options; end - - # source://rake/13.0.6/lib/rake/application.rb#185 - def standard_exception_handling; end - - # source://rake/13.0.6/lib/rake/application.rb#402 - def standard_rake_options; end - - # source://rake/13.0.6/lib/rake/application.rb#727 - def system_dir; end - - # source://rake/13.0.6/lib/rake/application.rb#33 - def terminal_columns; end - - # source://rake/13.0.6/lib/rake/application.rb#33 - def terminal_columns=(_arg0); end - - # source://rake/13.0.6/lib/rake/application.rb#337 - def terminal_width; end - - # source://rake/13.0.6/lib/rake/application.rb#150 - def thread_pool; end - - # source://rake/13.0.6/lib/rake/application.rb#109 - def top_level; end - - # source://rake/13.0.6/lib/rake/application.rb#36 - def top_level_tasks; end - - # source://rake/13.0.6/lib/rake/application.rb#388 - def trace(*strings); end - - # source://rake/13.0.6/lib/rake/application.rb#370 - def truncate(string, width); end - - # source://rake/13.0.6/lib/rake/application.rb#293 - def truncate_output?; end - - # source://rake/13.0.6/lib/rake/application.rb#39 - def tty_output=(_arg0); end - - # source://rake/13.0.6/lib/rake/application.rb#287 - def tty_output?; end - - # source://rake/13.0.6/lib/rake/application.rb#361 - def unix?; end - - # source://rake/13.0.6/lib/rake/application.rb#366 - def windows?; end - - private - - # source://rake/13.0.6/lib/rake/application.rb#721 - def glob(path, &block); end - - # source://rake/13.0.6/lib/rake/application.rb#267 - def has_chain?(exception); end - - # source://rake/13.0.6/lib/rake/application.rb#620 - def select_tasks_to_show(options, show_tasks, value); end - - # source://rake/13.0.6/lib/rake/application.rb#627 - def select_trace_output(options, trace_option, value); end - - # source://rake/13.0.6/lib/rake/application.rb#393 - def sort_options(options); end - - # source://rake/13.0.6/lib/rake/application.rb#744 - def standard_system_dir; end -end - -# source://rake/13.0.6/lib/rake/application.rb#41 -Rake::Application::DEFAULT_RAKEFILES = T.let(T.unsafe(nil), Array) - -# source://rake/13.0.6/lib/rake/early_time.rb#21 -Rake::EARLY = T.let(T.unsafe(nil), Rake::EarlyTime) - -# source://rake/13.0.6/lib/rake/task_arguments.rb#108 -Rake::EMPTY_TASK_ARGS = T.let(T.unsafe(nil), Rake::TaskArguments) - -# source://rake/13.0.6/lib/rake/late_time.rb#17 -Rake::LATE = T.let(T.unsafe(nil), Rake::LateTime) - -# source://rdoc/6.5.0/rdoc/task.rb#326 -Rake::RDocTask = RDoc::Task - -# source://rake/13.0.6/lib/rake/version.rb#3 -Rake::VERSION = T.let(T.unsafe(nil), String) - -# Based on ActionDispatch::RemoteIp. All security-related precautions from that -# middleware have been removed, because the Event IP just needs to be accurate, -# and spoofing an IP here only makes data inaccurate, not insecure. Don't re-use -# this module if you have to *trust* the IP address. -# -# source://sentry-raven//lib/raven/version.rb#3 -module Raven - class << self - # source://forwardable/1.3.3/forwardable.rb#231 - def annotate(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def annotateException(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def annotate_exception(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def breadcrumbs(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def capture(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def captureException(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def captureMessage(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def capture_exception(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def capture_message(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def capture_type(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def client(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def client=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def configuration(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def configuration=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def configure(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def context(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def extra_context(*args, **_arg1, &block); end - - # Injects various integrations. Default behavior: inject all available integrations - # - # source://sentry-raven//lib/raven/base.rb#63 - def inject; end - - # source://sentry-raven//lib/raven/base.rb#72 - def inject_only(*only_integrations); end - - # source://sentry-raven//lib/raven/base.rb#67 - def inject_without(*exclude_integrations); end - - # source://sentry-raven//lib/raven/base.rb#44 - def instance; end - - # source://forwardable/1.3.3/forwardable.rb#231 - def last_event_id(*args, **_arg1, &block); end - - # source://sentry-raven//lib/raven/base.rb#89 - def load_integration(integration); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def logger(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def rack_context(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def report_ready(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def report_status(*args, **_arg1, &block); end - - # source://sentry-raven//lib/raven/base.rb#95 - def safely_prepend(module_name, opts = T.unsafe(nil)); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def send_event(*args, **_arg1, &block); end - - # source://sentry-raven//lib/raven/base.rb#105 - def sys_command(command); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def tags_context(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def user_context(*args, **_arg1, &block); end - end -end - -# source://sentry-raven//lib/raven/base.rb#36 -Raven::AVAILABLE_INTEGRATIONS = T.let(T.unsafe(nil), Array) - -# Front end to parsing the backtrace for each notice -# -# source://sentry-raven//lib/raven/backtrace.rb#7 -class Raven::Backtrace - # @return [Backtrace] a new instance of Backtrace - # - # source://sentry-raven//lib/raven/backtrace.rb#113 - def initialize(lines); end - - # source://sentry-raven//lib/raven/backtrace.rb#129 - def ==(other); end - - # source://sentry-raven//lib/raven/backtrace.rb#117 - def inspect; end - - # holder for an Array of Backtrace::Line instances - # - # source://sentry-raven//lib/raven/backtrace.rb#92 - def lines; end - - # source://sentry-raven//lib/raven/backtrace.rb#121 - def to_s; end - - private - - # Sets the attribute lines - # - # @param value the value to set the attribute lines to. - # - # source://sentry-raven//lib/raven/backtrace.rb#139 - def lines=(_arg0); end - - class << self - # source://sentry-raven//lib/raven/backtrace.rb#94 - def parse(backtrace, opts = T.unsafe(nil)); end - end -end - -# source://sentry-raven//lib/raven/backtrace.rb#89 -Raven::Backtrace::APP_DIRS_PATTERN = T.let(T.unsafe(nil), Regexp) - -# Handles backtrace parsing line by line -# -# source://sentry-raven//lib/raven/backtrace.rb#9 -class Raven::Backtrace::Line - # @return [Line] a new instance of Line - # - # source://sentry-raven//lib/raven/backtrace.rb#49 - def initialize(file, number, method, module_name); end - - # source://sentry-raven//lib/raven/backtrace.rb#69 - def ==(other); end - - # The file portion of the line (such as app/models/user.rb) - # - # source://sentry-raven//lib/raven/backtrace.rb#22 - def file; end - - # source://sentry-raven//lib/raven/backtrace.rb#56 - def in_app; end - - # source://sentry-raven//lib/raven/backtrace.rb#73 - def inspect; end - - # The method of the line (such as index) - # - # source://sentry-raven//lib/raven/backtrace.rb#28 - def method; end - - # The module name (JRuby) - # - # source://sentry-raven//lib/raven/backtrace.rb#31 - def module_name; end - - # The line number portion of the line - # - # source://sentry-raven//lib/raven/backtrace.rb#25 - def number; end - - # Reconstructs the line in a readable fashion - # - # source://sentry-raven//lib/raven/backtrace.rb#65 - def to_s; end - - private - - # Sets the attribute file - # - # @param value the value to set the attribute file to. - # - # source://sentry-raven//lib/raven/backtrace.rb#86 - def file=(_arg0); end - - # Sets the attribute method - # - # @param value the value to set the attribute method to. - # - # source://sentry-raven//lib/raven/backtrace.rb#86 - def method=(_arg0); end - - # Sets the attribute module_name - # - # @param value the value to set the attribute module_name to. - # - # source://sentry-raven//lib/raven/backtrace.rb#86 - def module_name=(_arg0); end - - # Sets the attribute number - # - # @param value the value to set the attribute number to. - # - # source://sentry-raven//lib/raven/backtrace.rb#86 - def number=(_arg0); end - - class << self - # source://sentry-raven//lib/raven/backtrace.rb#77 - def in_app_pattern; end - - # Parses a single line of a given backtrace - # - # @param unparsed_line [String] The raw line from +caller+ or some backtrace - # @return [Line] The parsed backtrace line - # - # source://sentry-raven//lib/raven/backtrace.rb#36 - def parse(unparsed_line); end - end -end - -# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:170) -# -# source://sentry-raven//lib/raven/backtrace.rb#19 -Raven::Backtrace::Line::JAVA_INPUT_FORMAT = T.let(T.unsafe(nil), Regexp) - -# source://sentry-raven//lib/raven/backtrace.rb#10 -Raven::Backtrace::Line::RB_EXTENSION = T.let(T.unsafe(nil), String) - -# regexp (optional leading X: on windows, or JRuby9000 class-prefix) -# -# source://sentry-raven//lib/raven/backtrace.rb#12 -Raven::Backtrace::Line::RUBY_INPUT_FORMAT = T.let(T.unsafe(nil), Regexp) - -# source://sentry-raven//lib/raven/breadcrumbs.rb#2 -class Raven::Breadcrumb - # @return [Breadcrumb] a new instance of Breadcrumb - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#5 - def initialize; end - - # Returns the value of attribute category. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def category; end - - # Sets the attribute category - # - # @param value the value to set the attribute category to. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def category=(_arg0); end - - # Returns the value of attribute data. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def data; end - - # Sets the attribute data - # - # @param value the value to set the attribute data to. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def data=(_arg0); end - - # Returns the value of attribute level. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def level; end - - # Sets the attribute level - # - # @param value the value to set the attribute level to. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def level=(_arg0); end - - # Returns the value of attribute message. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def message; end - - # Sets the attribute message - # - # @param value the value to set the attribute message to. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def message=(_arg0); end - - # Returns the value of attribute timestamp. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def timestamp; end - - # Sets the attribute timestamp - # - # @param value the value to set the attribute timestamp to. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def timestamp=(_arg0); end - - # source://sentry-raven//lib/raven/breadcrumbs.rb#14 - def to_hash; end - - # Returns the value of attribute type. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def type; end - - # Sets the attribute type - # - # @param value the value to set the attribute type to. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#3 - def type=(_arg0); end -end - -# source://sentry-raven//lib/raven/breadcrumbs.rb#28 -class Raven::BreadcrumbBuffer - include ::Enumerable - - # @return [BreadcrumbBuffer] a new instance of BreadcrumbBuffer - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#41 - def initialize(size = T.unsafe(nil)); end - - # Returns the value of attribute buffer. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#31 - def buffer; end - - # Sets the attribute buffer - # - # @param value the value to set the attribute buffer to. - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#31 - def buffer=(_arg0); end - - # source://sentry-raven//lib/raven/breadcrumbs.rb#62 - def each(&block); end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/breadcrumbs.rb#66 - def empty?; end - - # source://sentry-raven//lib/raven/breadcrumbs.rb#54 - def members; end - - # source://sentry-raven//lib/raven/breadcrumbs.rb#58 - def peek; end - - # source://sentry-raven//lib/raven/breadcrumbs.rb#45 - def record(crumb = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/breadcrumbs.rb#70 - def to_hash; end - - class << self - # source://sentry-raven//lib/raven/breadcrumbs.rb#37 - def clear!; end - - # source://sentry-raven//lib/raven/breadcrumbs.rb#33 - def current; end - end -end - -# source://sentry-raven//lib/raven/cli.rb#2 -class Raven::CLI - class << self - # source://sentry-raven//lib/raven/cli.rb#3 - def test(dsn = T.unsafe(nil), silent = T.unsafe(nil), config = T.unsafe(nil)); end - end -end - -# Encodes events and sends them to the Sentry server. -# -# source://sentry-raven//lib/raven/client.rb#11 -class Raven::Client - # @return [Client] a new instance of Client - # - # source://sentry-raven//lib/raven/client.rb#18 - def initialize(configuration); end - - # Returns the value of attribute configuration. - # - # source://sentry-raven//lib/raven/client.rb#16 - def configuration; end - - # Sets the attribute configuration - # - # @param value the value to set the attribute configuration to. - # - # source://sentry-raven//lib/raven/client.rb#16 - def configuration=(_arg0); end - - # source://sentry-raven//lib/raven/client.rb#24 - def send_event(event, hint = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/client.rb#58 - def transport; end - - private - - # source://sentry-raven//lib/raven/client.rb#74 - def encode(event); end - - # source://sentry-raven//lib/raven/client.rb#118 - def failed_send(e, event); end - - # source://sentry-raven//lib/raven/client.rb#102 - def generate_auth_header; end - - # source://sentry-raven//lib/raven/client.rb#98 - def get_log_message(event); end - - # source://sentry-raven//lib/raven/client.rb#86 - def get_message_from_exception(event); end - - # source://sentry-raven//lib/raven/client.rb#114 - def successful_send; end -end - -# source://sentry-raven//lib/raven/client.rb#14 -Raven::Client::CONTENT_TYPE = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/client.rb#12 -Raven::Client::PROTOCOL_VERSION = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/client.rb#13 -Raven::Client::USER_AGENT = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/client.rb#132 -class Raven::ClientState - # @return [ClientState] a new instance of ClientState - # - # source://sentry-raven//lib/raven/client.rb#133 - def initialize; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/client.rb#164 - def failed?; end - - # source://sentry-raven//lib/raven/client.rb#146 - def failure(retry_after = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/client.rb#157 - def reset; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/client.rb#137 - def should_try?; end - - # source://sentry-raven//lib/raven/client.rb#153 - def success; end -end - -# source://sentry-raven//lib/raven/configuration.rb#4 -class Raven::Configuration - # @return [Configuration] a new instance of Configuration - # - # source://sentry-raven//lib/raven/configuration.rb#248 - def initialize; end - - # Allows config options to be read like a hash - # - # @param option [Symbol] Key for a given attribute - # - # source://sentry-raven//lib/raven/configuration.rb#369 - def [](option); end - - # Directories to be recognized as part of your app. e.g. if you - # have an `engines` dir at the root of your project, you may want - # to set this to something like /(app|config|engines|lib)/ - # - # source://sentry-raven//lib/raven/configuration.rb#8 - def app_dirs_pattern; end - - # Directories to be recognized as part of your app. e.g. if you - # have an `engines` dir at the root of your project, you may want - # to set this to something like /(app|config|engines|lib)/ - # - # source://sentry-raven//lib/raven/configuration.rb#8 - def app_dirs_pattern=(_arg0); end - - # Provide an object that responds to `call` to send events asynchronously. - # E.g.: lambda { |event| Thread.new { Raven.send_event(event) } } - # - # source://sentry-raven//lib/raven/configuration.rb#12 - def async; end - - # source://sentry-raven//lib/raven/configuration.rb#317 - def async=(value); end - - # Provide an object that responds to `call` to send events asynchronously. - # E.g.: lambda { |event| Thread.new { Raven.send_event(event) } } - # - # source://sentry-raven//lib/raven/configuration.rb#12 - def async?; end - - # a proc/lambda that takes an array of stack traces - # it'll be used to silence (reduce) backtrace of the exception - # - # for example: - # - # ```ruby - # Raven.configuration.backtrace_cleanup_callback = lambda do |backtrace| - # Rails.backtrace_cleaner.clean(backtrace) - # end - # ``` - # - # source://sentry-raven//lib/raven/configuration.rb#137 - def backtrace_cleanup_callback; end - - # a proc/lambda that takes an array of stack traces - # it'll be used to silence (reduce) backtrace of the exception - # - # for example: - # - # ```ruby - # Raven.configuration.backtrace_cleanup_callback = lambda do |backtrace| - # Rails.backtrace_cleaner.clean(backtrace) - # end - # ``` - # - # source://sentry-raven//lib/raven/configuration.rb#137 - def backtrace_cleanup_callback=(_arg0); end - - # Optional Proc, called before sending an event to the server/ - # E.g.: lambda { |event, hint| event } - # E.g.: lambda { |event, hint| nil } - # E.g.: lambda { |event, hint| - # event[:message] = 'a' - # event - # } - # - # source://sentry-raven//lib/raven/configuration.rb#188 - def before_send; end - - # source://sentry-raven//lib/raven/configuration.rb#358 - def before_send=(value); end - - # An array of breadcrumbs loggers to be used. Available options are: - # - :sentry_logger - # - :active_support_logger - # - # source://sentry-raven//lib/raven/configuration.rb#18 - def breadcrumbs_logger; end - - # source://sentry-raven//lib/raven/configuration.rb#325 - def breadcrumbs_logger=(logger); end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#377 - def capture_allowed?(message_or_exc = T.unsafe(nil)); end - - # Number of lines of code context to capture, or nil for none - # - # source://sentry-raven//lib/raven/configuration.rb#21 - def context_lines; end - - # Number of lines of code context to capture, or nil for none - # - # source://sentry-raven//lib/raven/configuration.rb#21 - def context_lines=(_arg0); end - - # RACK_ENV by default. - # - # source://sentry-raven//lib/raven/configuration.rb#24 - def current_environment; end - - # source://sentry-raven//lib/raven/configuration.rb#373 - def current_environment=(environment); end - - # the dsn value, whether it's set via `config.dsn=` or `ENV["SENTRY_DSN"]` - # - # source://sentry-raven//lib/raven/configuration.rb#194 - def dsn; end - - # source://sentry-raven//lib/raven/configuration.rb#284 - def dsn=(value); end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#416 - def enabled_in_current_env?; end - - # Encoding type for event bodies. Must be :json or :gzip. - # - # source://sentry-raven//lib/raven/configuration.rb#27 - def encoding; end - - # @raise [Error] - # - # source://sentry-raven//lib/raven/configuration.rb#311 - def encoding=(encoding); end - - # Whitelist of environments that will send notifications to Sentry. Array of Strings. - # - # source://sentry-raven//lib/raven/configuration.rb#30 - def environments; end - - # Whitelist of environments that will send notifications to Sentry. Array of Strings. - # - # source://sentry-raven//lib/raven/configuration.rb#30 - def environments=(_arg0); end - - # source://sentry-raven//lib/raven/configuration.rb#388 - def error_messages; end - - # Errors object - an Array that contains error messages. See # - # - # source://sentry-raven//lib/raven/configuration.rb#191 - def errors; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#403 - def exception_class_allowed?(exc); end - - # Logger 'progname's to exclude from breadcrumbs - # - # source://sentry-raven//lib/raven/configuration.rb#33 - def exclude_loggers; end - - # Logger 'progname's to exclude from breadcrumbs - # - # source://sentry-raven//lib/raven/configuration.rb#33 - def exclude_loggers=(_arg0); end - - # Array of exception classes that should never be sent. See IGNORE_DEFAULT. - # You should probably append to this rather than overwrite it. - # - # source://sentry-raven//lib/raven/configuration.rb#37 - def excluded_exceptions; end - - # Array of exception classes that should never be sent. See IGNORE_DEFAULT. - # You should probably append to this rather than overwrite it. - # - # source://sentry-raven//lib/raven/configuration.rb#37 - def excluded_exceptions=(_arg0); end - - # A Proc yeilding the faraday builder allowing for further configuration - # of the faraday adapter - # - # source://sentry-raven//lib/raven/configuration.rb#51 - def faraday_builder; end - - # A Proc yeilding the faraday builder allowing for further configuration - # of the faraday adapter - # - # source://sentry-raven//lib/raven/configuration.rb#51 - def faraday_builder=(_arg0); end - - # DSN component - set automatically if DSN provided - # - # source://sentry-raven//lib/raven/configuration.rb#44 - def host; end - - # DSN component - set automatically if DSN provided - # - # source://sentry-raven//lib/raven/configuration.rb#44 - def host=(_arg0); end - - # The Faraday adapter to be used. Will default to Net::HTTP when not set. - # - # source://sentry-raven//lib/raven/configuration.rb#47 - def http_adapter; end - - # The Faraday adapter to be used. Will default to Net::HTTP when not set. - # - # source://sentry-raven//lib/raven/configuration.rb#47 - def http_adapter=(_arg0); end - - # Boolean to check nested exceptions when deciding if to exclude. Defaults to false - # - # source://sentry-raven//lib/raven/configuration.rb#40 - def inspect_exception_causes_for_exclusion; end - - # Boolean to check nested exceptions when deciding if to exclude. Defaults to false - # - # source://sentry-raven//lib/raven/configuration.rb#40 - def inspect_exception_causes_for_exclusion=(_arg0); end - - # Boolean to check nested exceptions when deciding if to exclude. Defaults to false - # - # source://sentry-raven//lib/raven/configuration.rb#40 - def inspect_exception_causes_for_exclusion?; end - - # You may provide your own LineCache for matching paths with source files. - # This may be useful if you need to get source code from places other than - # the disk. See Raven::LineCache for the required interface you must implement. - # - # source://sentry-raven//lib/raven/configuration.rb#56 - def linecache; end - - # You may provide your own LineCache for matching paths with source files. - # This may be useful if you need to get source code from places other than - # the disk. See Raven::LineCache for the required interface you must implement. - # - # source://sentry-raven//lib/raven/configuration.rb#56 - def linecache=(_arg0); end - - # Logger used by Raven. In Rails, this is the Rails logger, otherwise - # Raven provides its own Raven::Logger. - # - # source://sentry-raven//lib/raven/configuration.rb#60 - def logger; end - - # Logger used by Raven. In Rails, this is the Rails logger, otherwise - # Raven provides its own Raven::Logger. - # - # source://sentry-raven//lib/raven/configuration.rb#60 - def logger=(_arg0); end - - # Timeout waiting for the Sentry server connection to open in seconds - # - # source://sentry-raven//lib/raven/configuration.rb#63 - def open_timeout; end - - # Timeout waiting for the Sentry server connection to open in seconds - # - # source://sentry-raven//lib/raven/configuration.rb#63 - def open_timeout=(_arg0); end - - # DSN component - set automatically if DSN provided - # - # source://sentry-raven//lib/raven/configuration.rb#66 - def path; end - - # DSN component - set automatically if DSN provided - # - # source://sentry-raven//lib/raven/configuration.rb#66 - def path=(_arg0); end - - # DSN component - set automatically if DSN provided - # - # source://sentry-raven//lib/raven/configuration.rb#69 - def port; end - - # DSN component - set automatically if DSN provided - # - # source://sentry-raven//lib/raven/configuration.rb#69 - def port=(_arg0); end - - # Processors to run on data before sending upstream. See DEFAULT_PROCESSORS. - # You should probably append to this rather than overwrite it. - # - # source://sentry-raven//lib/raven/configuration.rb#73 - def processors; end - - # Processors to run on data before sending upstream. See DEFAULT_PROCESSORS. - # You should probably append to this rather than overwrite it. - # - # source://sentry-raven//lib/raven/configuration.rb#73 - def processors=(_arg0); end - - # Project ID number to send to the Sentry server - # If you provide a DSN, this will be set automatically. - # - # source://sentry-raven//lib/raven/configuration.rb#77 - def project_id; end - - # Project ID number to send to the Sentry server - # If you provide a DSN, this will be set automatically. - # - # source://sentry-raven//lib/raven/configuration.rb#77 - def project_id=(_arg0); end - - # Project directory root for in_app detection. Could be Rails root, etc. - # Set automatically for Rails. - # - # source://sentry-raven//lib/raven/configuration.rb#81 - def project_root; end - - # source://sentry-raven//lib/raven/configuration.rb#393 - def project_root=(root_dir); end - - # Proxy information to pass to the HTTP adapter (via Faraday) - # - # source://sentry-raven//lib/raven/configuration.rb#84 - def proxy; end - - # Proxy information to pass to the HTTP adapter (via Faraday) - # - # source://sentry-raven//lib/raven/configuration.rb#84 - def proxy=(_arg0); end - - # Public key for authentication with the Sentry server - # If you provide a DSN, this will be set automatically. - # - # source://sentry-raven//lib/raven/configuration.rb#88 - def public_key; end - - # Public key for authentication with the Sentry server - # If you provide a DSN, this will be set automatically. - # - # source://sentry-raven//lib/raven/configuration.rb#88 - def public_key=(_arg0); end - - # Array of rack env parameters to be included in the event sent to sentry. - # - # source://sentry-raven//lib/raven/configuration.rb#197 - def rack_env_whitelist; end - - # Array of rack env parameters to be included in the event sent to sentry. - # - # source://sentry-raven//lib/raven/configuration.rb#197 - def rack_env_whitelist=(_arg0); end - - # Turns on ActiveSupport breadcrumbs integration - # - # source://sentry-raven//lib/raven/configuration.rb#91 - def rails_activesupport_breadcrumbs; end - - # source://sentry-raven//lib/raven/configuration.rb#398 - def rails_activesupport_breadcrumbs=(val); end - - # Rails catches exceptions in the ActionDispatch::ShowExceptions or - # ActionDispatch::DebugExceptions middlewares, depending on the environment. - # When `rails_report_rescued_exceptions` is true (it is by default), Raven - # will report exceptions even when they are rescued by these middlewares. - # - # source://sentry-raven//lib/raven/configuration.rb#97 - def rails_report_rescued_exceptions; end - - # Rails catches exceptions in the ActionDispatch::ShowExceptions or - # ActionDispatch::DebugExceptions middlewares, depending on the environment. - # When `rails_report_rescued_exceptions` is true (it is by default), Raven - # will report exceptions even when they are rescued by these middlewares. - # - # source://sentry-raven//lib/raven/configuration.rb#97 - def rails_report_rescued_exceptions=(_arg0); end - - # Release tag to be passed with every event sent to Sentry. - # We automatically try to set this to a git SHA or Capistrano release. - # - # source://sentry-raven//lib/raven/configuration.rb#101 - def release; end - - # Release tag to be passed with every event sent to Sentry. - # We automatically try to set this to a git SHA or Capistrano release. - # - # source://sentry-raven//lib/raven/configuration.rb#101 - def release=(_arg0); end - - # The sampling factor to apply to events. A value of 0.0 will not send - # any events, and a value of 1.0 will send 100% of events. - # - # source://sentry-raven//lib/raven/configuration.rb#105 - def sample_rate; end - - # The sampling factor to apply to events. A value of 0.0 will not send - # any events, and a value of 1.0 will send 100% of events. - # - # source://sentry-raven//lib/raven/configuration.rb#105 - def sample_rate=(_arg0); end - - # Boolean - sanitize values that look like credit card numbers - # - # source://sentry-raven//lib/raven/configuration.rb#108 - def sanitize_credit_cards; end - - # Boolean - sanitize values that look like credit card numbers - # - # source://sentry-raven//lib/raven/configuration.rb#108 - def sanitize_credit_cards=(_arg0); end - - # By default, Sentry censors Hash values when their keys match things like - # "secret", "password", etc. Provide an array of Strings that, when matched in - # a hash key, will be censored and not sent to Sentry. - # - # source://sentry-raven//lib/raven/configuration.rb#113 - def sanitize_fields; end - - # By default, Sentry censors Hash values when their keys match things like - # "secret", "password", etc. Provide an array of Strings that, when matched in - # a hash key, will be censored and not sent to Sentry. - # - # source://sentry-raven//lib/raven/configuration.rb#113 - def sanitize_fields=(_arg0); end - - # If you're sure you want to override the default sanitization values, you can - # add to them to an array of Strings here, e.g. %w(authorization password) - # - # source://sentry-raven//lib/raven/configuration.rb#117 - def sanitize_fields_excluded; end - - # If you're sure you want to override the default sanitization values, you can - # add to them to an array of Strings here, e.g. %w(authorization password) - # - # source://sentry-raven//lib/raven/configuration.rb#117 - def sanitize_fields_excluded=(_arg0); end - - # Sanitize additional HTTP headers - only Authorization is removed by default. - # - # source://sentry-raven//lib/raven/configuration.rb#120 - def sanitize_http_headers; end - - # Sanitize additional HTTP headers - only Authorization is removed by default. - # - # source://sentry-raven//lib/raven/configuration.rb#120 - def sanitize_http_headers=(_arg0); end - - # DSN component - set automatically if DSN provided. - # Otherwise, can be one of "http", "https", or "dummy" - # - # source://sentry-raven//lib/raven/configuration.rb#124 - def scheme; end - - # DSN component - set automatically if DSN provided. - # Otherwise, can be one of "http", "https", or "dummy" - # - # source://sentry-raven//lib/raven/configuration.rb#124 - def scheme=(_arg0); end - - # Secret key for authentication with the Sentry server - # If you provide a DSN, this will be set automatically. - # - # This is deprecated and not necessary for newer Sentry installations any more. - # - # source://sentry-raven//lib/raven/configuration.rb#143 - def secret_key; end - - # Secret key for authentication with the Sentry server - # If you provide a DSN, this will be set automatically. - # - # This is deprecated and not necessary for newer Sentry installations any more. - # - # source://sentry-raven//lib/raven/configuration.rb#143 - def secret_key=(_arg0); end - - # Include module versions in reports - boolean. - # - # source://sentry-raven//lib/raven/configuration.rb#146 - def send_modules; end - - # Include module versions in reports - boolean. - # - # source://sentry-raven//lib/raven/configuration.rb#146 - def send_modules=(_arg0); end - - # If we cannot capture, we cannot send. - # - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#377 - def sending_allowed?(message_or_exc = T.unsafe(nil)); end - - # Simple server string - set this to the DSN found on your Sentry settings. - # - # source://sentry-raven//lib/raven/configuration.rb#149 - def server; end - - # source://sentry-raven//lib/raven/configuration.rb#284 - def server=(value); end - - # Returns the value of attribute server_name. - # - # source://sentry-raven//lib/raven/configuration.rb#151 - def server_name; end - - # Sets the attribute server_name - # - # @param value the value to set the attribute server_name to. - # - # source://sentry-raven//lib/raven/configuration.rb#151 - def server_name=(_arg0); end - - # Provide a configurable callback to determine event capture. - # Note that the object passed into the block will be a String (messages) or - # an exception. - # e.g. lambda { |exc_or_msg| exc_or_msg.some_attr == false } - # - # source://sentry-raven//lib/raven/configuration.rb#157 - def should_capture; end - - # source://sentry-raven//lib/raven/configuration.rb#350 - def should_capture=(value); end - - # Silences ready message when true. - # - # source://sentry-raven//lib/raven/configuration.rb#160 - def silence_ready; end - - # Silences ready message when true. - # - # source://sentry-raven//lib/raven/configuration.rb#160 - def silence_ready=(_arg0); end - - # SSL settings passed directly to Faraday's ssl option - # - # source://sentry-raven//lib/raven/configuration.rb#163 - def ssl; end - - # SSL settings passed directly to Faraday's ssl option - # - # source://sentry-raven//lib/raven/configuration.rb#163 - def ssl=(_arg0); end - - # The path to the SSL certificate file - # - # source://sentry-raven//lib/raven/configuration.rb#166 - def ssl_ca_file; end - - # The path to the SSL certificate file - # - # source://sentry-raven//lib/raven/configuration.rb#166 - def ssl_ca_file=(_arg0); end - - # Should the SSL certificate of the server be verified? - # - # source://sentry-raven//lib/raven/configuration.rb#169 - def ssl_verification; end - - # Should the SSL certificate of the server be verified? - # - # source://sentry-raven//lib/raven/configuration.rb#169 - def ssl_verification=(_arg0); end - - # Default tags for events. Hash. - # - # source://sentry-raven//lib/raven/configuration.rb#172 - def tags; end - - # Default tags for events. Hash. - # - # source://sentry-raven//lib/raven/configuration.rb#172 - def tags=(_arg0); end - - # Timeout when waiting for the server to return data in seconds. - # - # source://sentry-raven//lib/raven/configuration.rb#175 - def timeout; end - - # Timeout when waiting for the server to return data in seconds. - # - # source://sentry-raven//lib/raven/configuration.rb#175 - def timeout=(_arg0); end - - # Optional Proc, called when the Sentry server cannot be contacted for any reason - # E.g. lambda { |event| Thread.new { MyJobProcessor.send_email(event) } } - # - # source://sentry-raven//lib/raven/configuration.rb#179 - def transport_failure_callback; end - - # source://sentry-raven//lib/raven/configuration.rb#342 - def transport_failure_callback=(value); end - - private - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#507 - def capture_allowed_by_callback?(message_or_exc); end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#500 - def capture_in_current_environment?; end - - # source://sentry-raven//lib/raven/configuration.rb#545 - def current_environment_from_env; end - - # source://sentry-raven//lib/raven/configuration.rb#422 - def detect_project_root; end - - # source://sentry-raven//lib/raven/configuration.rb#430 - def detect_release; end - - # source://sentry-raven//lib/raven/configuration.rb#481 - def detect_release_from_capistrano; end - - # source://sentry-raven//lib/raven/configuration.rb#496 - def detect_release_from_env; end - - # source://sentry-raven//lib/raven/configuration.rb#492 - def detect_release_from_git; end - - # source://sentry-raven//lib/raven/configuration.rb#469 - def detect_release_from_heroku; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#439 - def excluded_exception?(incoming_exception); end - - # source://sentry-raven//lib/raven/configuration.rb#445 - def get_exception_class(x); end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#449 - def matches_exception?(excluded_exception_class, incoming_exception); end - - # In Ruby <2.0 const_get can't lookup "SomeModule::SomeClass" in one go - # - # source://sentry-raven//lib/raven/configuration.rb#458 - def qualified_const_get(x); end - - # Try to resolve the hostname to an FQDN, but fall back to whatever - # the load name is. - # - # source://sentry-raven//lib/raven/configuration.rb#540 - def resolve_hostname; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#477 - def running_on_heroku?; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#527 - def sample_allowed?; end - - # source://sentry-raven//lib/raven/configuration.rb#549 - def server_name_from_env; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/configuration.rb#514 - def valid?; end -end - -# source://sentry-raven//lib/raven/configuration.rb#246 -Raven::Configuration::AVAILABLE_BREADCRUMBS_LOGGERS = T.let(T.unsafe(nil), Array) - -# Note the order - we have to remove circular references and bad characters -# before passing to other processors. -# -# source://sentry-raven//lib/raven/configuration.rb#225 -Raven::Configuration::DEFAULT_PROCESSORS = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/configuration.rb#234 -Raven::Configuration::HEROKU_DYNO_METADATA_MESSAGE = T.let(T.unsafe(nil), String) - -# Most of these errors generate 4XX responses. In general, Sentry clients -# only automatically report 5xx responses. -# -# source://sentry-raven//lib/raven/configuration.rb#201 -Raven::Configuration::IGNORE_DEFAULT = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/configuration.rb#243 -Raven::Configuration::LOG_PREFIX = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/configuration.rb#244 -Raven::Configuration::MODULE_SEPARATOR = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/configuration.rb#237 -Raven::Configuration::RACK_ENV_WHITELIST_DEFAULT = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/context.rb#5 -class Raven::Context - # @return [Context] a new instance of Context - # - # source://sentry-raven//lib/raven/context.rb#16 - def initialize; end - - # Returns the value of attribute extra. - # - # source://sentry-raven//lib/raven/context.rb#14 - def extra; end - - # Sets the attribute extra - # - # @param value the value to set the attribute extra to. - # - # source://sentry-raven//lib/raven/context.rb#14 - def extra=(_arg0); end - - # Returns the value of attribute rack_env. - # - # source://sentry-raven//lib/raven/context.rb#14 - def rack_env; end - - # Sets the attribute rack_env - # - # @param value the value to set the attribute rack_env to. - # - # source://sentry-raven//lib/raven/context.rb#14 - def rack_env=(_arg0); end - - # Returns the value of attribute runtime. - # - # source://sentry-raven//lib/raven/context.rb#14 - def runtime; end - - # Sets the attribute runtime - # - # @param value the value to set the attribute runtime to. - # - # source://sentry-raven//lib/raven/context.rb#14 - def runtime=(_arg0); end - - # Returns the value of attribute server_os. - # - # source://sentry-raven//lib/raven/context.rb#14 - def server_os; end - - # Sets the attribute server_os - # - # @param value the value to set the attribute server_os to. - # - # source://sentry-raven//lib/raven/context.rb#14 - def server_os=(_arg0); end - - # Returns the value of attribute tags. - # - # source://sentry-raven//lib/raven/context.rb#14 - def tags; end - - # Sets the attribute tags - # - # @param value the value to set the attribute tags to. - # - # source://sentry-raven//lib/raven/context.rb#14 - def tags=(_arg0); end - - # Returns the value of attribute transaction. - # - # source://sentry-raven//lib/raven/context.rb#14 - def transaction; end - - # Sets the attribute transaction - # - # @param value the value to set the attribute transaction to. - # - # source://sentry-raven//lib/raven/context.rb#14 - def transaction=(_arg0); end - - # Returns the value of attribute user. - # - # source://sentry-raven//lib/raven/context.rb#14 - def user; end - - # Sets the attribute user - # - # @param value the value to set the attribute user to. - # - # source://sentry-raven//lib/raven/context.rb#14 - def user=(_arg0); end - - class << self - # source://sentry-raven//lib/raven/context.rb#10 - def clear!; end - - # source://sentry-raven//lib/raven/context.rb#6 - def current; end - - # source://sentry-raven//lib/raven/context.rb#27 - def os_context; end - - # source://sentry-raven//lib/raven/context.rb#40 - def runtime_context; end - end -end - -# source://sentry-raven//lib/raven/base.rb#38 -class Raven::Error < ::StandardError; end - -# source://sentry-raven//lib/raven/event.rb#7 -class Raven::Event - # @return [Event] a new instance of Event - # @yield [_self] - # @yieldparam _self [Raven::Event] the object that the method was called on - # - # source://sentry-raven//lib/raven/event.rb#23 - def initialize(options); end - - # source://sentry-raven//lib/raven/event.rb#127 - def [](key); end - - # source://sentry-raven//lib/raven/event.rb#131 - def []=(key, value); end - - # source://sentry-raven//lib/raven/event.rb#155 - def add_exception_interface(exc); end - - # Returns the value of attribute backtrace. - # - # source://sentry-raven//lib/raven/event.rb#15 - def backtrace; end - - # Sets the attribute backtrace - # - # @param value the value to set the attribute backtrace to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def backtrace=(_arg0); end - - # Returns the value of attribute breadcrumbs. - # - # source://sentry-raven//lib/raven/event.rb#15 - def breadcrumbs; end - - # Sets the attribute breadcrumbs - # - # @param value the value to set the attribute breadcrumbs to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def breadcrumbs=(_arg0); end - - # Returns the value of attribute checksum. - # - # source://sentry-raven//lib/raven/event.rb#15 - def checksum; end - - # Sets the attribute checksum - # - # @param value the value to set the attribute checksum to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def checksum=(_arg0); end - - # Returns the value of attribute configuration. - # - # source://sentry-raven//lib/raven/event.rb#15 - def configuration; end - - # Sets the attribute configuration - # - # @param value the value to set the attribute configuration to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def configuration=(_arg0); end - - # Returns the value of attribute context. - # - # source://sentry-raven//lib/raven/event.rb#15 - def context; end - - # Sets the attribute context - # - # @param value the value to set the attribute context to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def context=(_arg0); end - - # Returns the value of attribute environment. - # - # source://sentry-raven//lib/raven/event.rb#15 - def environment; end - - # Sets the attribute environment - # - # @param value the value to set the attribute environment to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def environment=(_arg0); end - - # Returns the value of attribute id. - # - # source://sentry-raven//lib/raven/event.rb#15 - def event_id; end - - # Returns the value of attribute extra. - # - # source://sentry-raven//lib/raven/event.rb#15 - def extra; end - - # Sets the attribute extra - # - # @param value the value to set the attribute extra to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def extra=(_arg0); end - - # Returns the value of attribute fingerprint. - # - # source://sentry-raven//lib/raven/event.rb#15 - def fingerprint; end - - # Sets the attribute fingerprint - # - # @param value the value to set the attribute fingerprint to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def fingerprint=(_arg0); end - - # Returns the value of attribute id. - # - # source://sentry-raven//lib/raven/event.rb#15 - def id; end - - # Sets the attribute id - # - # @param value the value to set the attribute id to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def id=(_arg0); end - - # @raise [Error] - # - # source://sentry-raven//lib/raven/event.rb#119 - def interface(name, value = T.unsafe(nil), &block); end - - # Returns the value of attribute level. - # - # source://sentry-raven//lib/raven/event.rb#21 - def level; end - - # needed to meet the Sentry spec - # - # source://sentry-raven//lib/raven/event.rb#115 - def level=(new_level); end - - # Returns the value of attribute logger. - # - # source://sentry-raven//lib/raven/event.rb#15 - def logger; end - - # Sets the attribute logger - # - # @param value the value to set the attribute logger to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def logger=(_arg0); end - - # source://sentry-raven//lib/raven/event.rb#85 - def message; end - - # source://sentry-raven//lib/raven/event.rb#89 - def message=(args); end - - # Returns the value of attribute modules. - # - # source://sentry-raven//lib/raven/event.rb#15 - def modules; end - - # Sets the attribute modules - # - # @param value the value to set the attribute modules to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def modules=(_arg0); end - - # Returns the value of attribute platform. - # - # source://sentry-raven//lib/raven/event.rb#15 - def platform; end - - # Sets the attribute platform - # - # @param value the value to set the attribute platform to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def platform=(_arg0); end - - # Returns the value of attribute release. - # - # source://sentry-raven//lib/raven/event.rb#15 - def release; end - - # Sets the attribute release - # - # @param value the value to set the attribute release to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def release=(_arg0); end - - # Returns the value of attribute runtime. - # - # source://sentry-raven//lib/raven/event.rb#15 - def runtime; end - - # Sets the attribute runtime - # - # @param value the value to set the attribute runtime to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def runtime=(_arg0); end - - # Returns the value of attribute sdk. - # - # source://sentry-raven//lib/raven/event.rb#15 - def sdk; end - - # Sets the attribute sdk - # - # @param value the value to set the attribute sdk to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def sdk=(_arg0); end - - # Returns the value of attribute server_name. - # - # source://sentry-raven//lib/raven/event.rb#15 - def server_name; end - - # Sets the attribute server_name - # - # @param value the value to set the attribute server_name to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def server_name=(_arg0); end - - # Returns the value of attribute server_os. - # - # source://sentry-raven//lib/raven/event.rb#15 - def server_os; end - - # Sets the attribute server_os - # - # @param value the value to set the attribute server_os to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def server_os=(_arg0); end - - # source://sentry-raven//lib/raven/event.rb#177 - def stacktrace_interface_from(backtrace); end - - # Returns the value of attribute tags. - # - # source://sentry-raven//lib/raven/event.rb#15 - def tags; end - - # Sets the attribute tags - # - # @param value the value to set the attribute tags to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def tags=(_arg0); end - - # Returns the value of attribute time_spent. - # - # source://sentry-raven//lib/raven/event.rb#21 - def time_spent; end - - # source://sentry-raven//lib/raven/event.rb#111 - def time_spent=(time); end - - # Returns the value of attribute timestamp. - # - # source://sentry-raven//lib/raven/event.rb#21 - def timestamp; end - - # source://sentry-raven//lib/raven/event.rb#107 - def timestamp=(time); end - - # source://sentry-raven//lib/raven/event.rb#135 - def to_hash; end - - # source://sentry-raven//lib/raven/event.rb#150 - def to_json_compatible; end - - # Returns the value of attribute transaction. - # - # source://sentry-raven//lib/raven/event.rb#15 - def transaction; end - - # Sets the attribute transaction - # - # @param value the value to set the attribute transaction to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def transaction=(_arg0); end - - # Returns the value of attribute user. - # - # source://sentry-raven//lib/raven/event.rb#15 - def user; end - - # Sets the attribute user - # - # @param value the value to set the attribute user to. - # - # source://sentry-raven//lib/raven/event.rb#15 - def user=(_arg0); end - - private - - # source://sentry-raven//lib/raven/event.rb#224 - def add_rack_context; end - - # source://sentry-raven//lib/raven/event.rb#246 - def async_json_processors; end - - # When behind a proxy (or if the user is using a proxy), we can't use - # REMOTE_ADDR to determine the Event IP, and must use other headers instead. - # - # source://sentry-raven//lib/raven/event.rb#237 - def calculate_real_ip_from_rack; end - - # source://sentry-raven//lib/raven/event.rb#250 - def list_gem_specs; end - - # source://sentry-raven//lib/raven/event.rb#205 - def set_core_attributes_from_configuration; end - - # source://sentry-raven//lib/raven/event.rb#212 - def set_core_attributes_from_context; end - - class << self - # source://sentry-raven//lib/raven/event.rb#56 - def captureException(exc, options = T.unsafe(nil), &block); end - - # source://sentry-raven//lib/raven/event.rb#74 - def captureMessage(message, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/event.rb#56 - def capture_exception(exc, options = T.unsafe(nil), &block); end - - # source://sentry-raven//lib/raven/event.rb#74 - def capture_message(message, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/event.rb#56 - def from_exception(exc, options = T.unsafe(nil), &block); end - - # source://sentry-raven//lib/raven/event.rb#74 - def from_message(message, options = T.unsafe(nil)); end - end -end - -# See Sentry server default limits at -# https://github.com/getsentry/sentry/blob/master/src/sentry/conf/server.py -# -# source://sentry-raven//lib/raven/event.rb#10 -Raven::Event::MAX_MESSAGE_SIZE_IN_BYTES = T.let(T.unsafe(nil), Integer) - -# source://sentry-raven//lib/raven/event.rb#11 -Raven::Event::REQUIRED_OPTION_KEYS = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/event.rb#13 -Raven::Event::SDK = T.let(T.unsafe(nil), Hash) - -# source://sentry-raven//lib/raven/interfaces/exception.rb#2 -class Raven::ExceptionInterface < ::Raven::Interface - # source://sentry-raven//lib/raven/interfaces/exception.rb#9 - def to_hash(*args); end - - # Returns the value of attribute values. - # - # source://sentry-raven//lib/raven/interfaces/exception.rb#3 - def values; end - - # Sets the attribute values - # - # @param value the value to set the attribute values to. - # - # source://sentry-raven//lib/raven/interfaces/exception.rb#3 - def values=(_arg0); end - - class << self - # source://sentry-raven//lib/raven/interfaces/exception.rb#5 - def sentry_alias; end - end -end - -# source://sentry-raven//lib/raven/interfaces/http.rb#2 -class Raven::HttpInterface < ::Raven::Interface - include ::Raven::RackInterface - - # @return [HttpInterface] a new instance of HttpInterface - # - # source://sentry-raven//lib/raven/interfaces/http.rb#5 - def initialize(*arguments); end - - # Returns the value of attribute cookies. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def cookies; end - - # Sets the attribute cookies - # - # @param value the value to set the attribute cookies to. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def cookies=(_arg0); end - - # Returns the value of attribute data. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def data; end - - # Sets the attribute data - # - # @param value the value to set the attribute data to. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def data=(_arg0); end - - # Returns the value of attribute env. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def env; end - - # Sets the attribute env - # - # @param value the value to set the attribute env to. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def env=(_arg0); end - - # Returns the value of attribute headers. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def headers; end - - # Sets the attribute headers - # - # @param value the value to set the attribute headers to. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def headers=(_arg0); end - - # Returns the value of attribute method. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def method; end - - # Sets the attribute method - # - # @param value the value to set the attribute method to. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def method=(_arg0); end - - # Returns the value of attribute query_string. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def query_string; end - - # Sets the attribute query_string - # - # @param value the value to set the attribute query_string to. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def query_string=(_arg0); end - - # Returns the value of attribute url. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def url; end - - # Sets the attribute url - # - # @param value the value to set the attribute url to. - # - # source://sentry-raven//lib/raven/interfaces/http.rb#3 - def url=(_arg0); end - - class << self - # source://sentry-raven//lib/raven/interfaces/http.rb#12 - def sentry_alias; end - end -end - -# A copy of Raven's base module class methods, minus some of the integration -# and global hooks since it's meant to be used explicitly. Useful for -# sending errors to multiple sentry projects in a large application. -# -# @example -# class Foo -# def initialize -# @other_raven = Raven::Instance.new -# @other_raven.configure do |config| -# config.server = 'http://...' -# end -# end -# -# def foo -# # ... -# rescue => e -# @other_raven.capture_exception(e) -# end -# end -# -# source://sentry-raven//lib/raven/instance.rb#21 -class Raven::Instance - # @return [Instance] a new instance of Instance - # - # source://sentry-raven//lib/raven/instance.rb#28 - def initialize(context = T.unsafe(nil), config = T.unsafe(nil)); end - - # Provides extra context to the exception prior to it being handled by - # Raven. An exception can have multiple annotations, which are merged - # together. - # - # The options (annotation) is treated the same as the ``options`` - # parameter to ``capture_exception`` or ``Event.from_exception``, and - # can contain the same ``:user``, ``:tags``, etc. options as these - # methods. - # - # These will be merged with the ``options`` parameter to - # ``Event.from_exception`` at the top of execution. - # - # @example - # begin - # raise "Hello" - # rescue => exc - # Raven.annotate_exception(exc, :user => { 'id' => 1, - # 'email' => 'foo@example.com' }) - # end - # - # source://sentry-raven//lib/raven/instance.rb#164 - def annotate_exception(exc, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/instance.rb#229 - def breadcrumbs; end - - # Capture and process any exceptions from the given block. - # - # @example - # Raven.capture do - # MyApp.run - # end - # - # source://sentry-raven//lib/raven/instance.rb#92 - def capture(options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/instance.rb#107 - def capture_exception(obj, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/instance.rb#107 - def capture_message(obj, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/instance.rb#107 - def capture_type(obj, options = T.unsafe(nil)); end - - # The client object is responsible for delivering formatted data to the - # Sentry server. - # - # source://sentry-raven//lib/raven/instance.rb#47 - def client; end - - # See Raven::Client. - # - # source://sentry-raven//lib/raven/instance.rb#23 - def client=(_arg0); end - - # See Raven::Configuration. - # - # source://sentry-raven//lib/raven/instance.rb#26 - def configuration; end - - # See Raven::Configuration. - # - # source://sentry-raven//lib/raven/instance.rb#26 - def configuration=(_arg0); end - - # Call this method to modify defaults in your initializers. - # - # @example - # Raven.configure do |config| - # config.server = 'http://...' - # end - # @yield [configuration] - # - # source://sentry-raven//lib/raven/instance.rb#69 - def configure; end - - # source://sentry-raven//lib/raven/instance.rb#33 - def context; end - - # Bind extra context. Merges with existing context (if any). - # - # Extra context shows up as Additional Data within Sentry, and is - # completely arbitrary. - # - # @example - # Raven.extra_context('my_custom_data' => 'value') - # - # source://sentry-raven//lib/raven/instance.rb#215 - def extra_context(options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/instance.rb#141 - def last_event_id; end - - # source://sentry-raven//lib/raven/instance.rb#41 - def logger; end - - # source://sentry-raven//lib/raven/instance.rb#223 - def rack_context(env); end - - # Tell the log that the client is good to go - # - # source://sentry-raven//lib/raven/instance.rb#52 - def report_status; end - - # Send an event to the configured Sentry server - # - # @example - # evt = Raven::Event.new(:message => "An errore) - # Raven.send_event(evt) - # - # source://sentry-raven//lib/raven/instance.rb#82 - def send_event(event, hint = T.unsafe(nil)); end - - # Bind tags context. Merges with existing context (if any). - # - # Tags are key / value pairs which generally represent things like - # application version, environment, role, and server names. - # - # @example - # Raven.tags_context('my_custom_tag' => 'tag_value') - # - # source://sentry-raven//lib/raven/instance.rb#200 - def tags_context(options = T.unsafe(nil)); end - - # Bind user context. Merges with existing context (if any). - # - # It is recommending that you send at least the ``id`` and ``email`` - # values. All other values are arbitrary. - # - # @example - # Raven.user_context('id' => 1, 'email' => 'foo@example.com') - # - # source://sentry-raven//lib/raven/instance.rb#178 - def user_context(options = T.unsafe(nil)); end - - private - - # source://sentry-raven//lib/raven/instance.rb#235 - def install_at_exit_hook(options); end - - # source://sentry-raven//lib/raven/instance.rb#245 - def make_hint(obj); end -end - -# source://sentry-raven//lib/raven/interface.rb#2 -class Raven::Interface - # @return [Interface] a new instance of Interface - # @yield [_self] - # @yieldparam _self [Raven::Interface] the object that the method was called on - # - # source://sentry-raven//lib/raven/interface.rb#3 - def initialize(attributes = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/interface.rb#21 - def to_hash; end - - class << self - # @private - # - # source://sentry-raven//lib/raven/interface.rb#11 - def inherited(klass); end - - # source://sentry-raven//lib/raven/interface.rb#17 - def registered; end - end -end - -# source://sentry-raven//lib/raven/linecache.rb#2 -class Raven::LineCache - # @return [LineCache] a new instance of LineCache - # - # source://sentry-raven//lib/raven/linecache.rb#3 - def initialize; end - - # Any linecache you provide to Raven must implement this method. - # Returns an Array of Strings representing the lines in the source - # file. The number of lines retrieved is (2 * context) + 1, the middle - # line should be the line requested by lineno. See specs for more information. - # - # source://sentry-raven//lib/raven/linecache.rb#11 - def get_file_context(filename, lineno, context); end - - private - - # source://sentry-raven//lib/raven/linecache.rb#35 - def getline(path, n); end - - # source://sentry-raven//lib/raven/linecache.rb#27 - def getlines(path); end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/linecache.rb#22 - def valid_path?(path); end -end - -# source://sentry-raven//lib/raven/logger.rb#6 -class Raven::Logger < ::Logger - # @return [Logger] a new instance of Logger - # - # source://sentry-raven//lib/raven/logger.rb#10 - def initialize(*_arg0); end -end - -# source://sentry-raven//lib/raven/logger.rb#7 -Raven::Logger::LOG_PREFIX = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/logger.rb#8 -Raven::Logger::PROGNAME = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/interfaces/message.rb#4 -class Raven::MessageInterface < ::Raven::Interface - # @return [MessageInterface] a new instance of MessageInterface - # - # source://sentry-raven//lib/raven/interfaces/message.rb#7 - def initialize(*arguments); end - - # Returns the value of attribute message. - # - # source://sentry-raven//lib/raven/interfaces/message.rb#5 - def message; end - - # Sets the attribute message - # - # @param value the value to set the attribute message to. - # - # source://sentry-raven//lib/raven/interfaces/message.rb#5 - def message=(_arg0); end - - # Returns the value of attribute params. - # - # source://sentry-raven//lib/raven/interfaces/message.rb#5 - def params; end - - # Sets the attribute params - # - # @param value the value to set the attribute params to. - # - # source://sentry-raven//lib/raven/interfaces/message.rb#5 - def params=(_arg0); end - - # source://sentry-raven//lib/raven/interfaces/message.rb#12 - def unformatted_message; end - - class << self - # source://sentry-raven//lib/raven/interfaces/message.rb#16 - def sentry_alias; end - end -end - -# source://sentry-raven//lib/raven/processor.rb#2 -class Raven::Processor - # @return [Processor] a new instance of Processor - # - # source://sentry-raven//lib/raven/processor.rb#7 - def initialize(client = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://sentry-raven//lib/raven/processor.rb#11 - def process(_data); end -end - -# source://sentry-raven//lib/raven/processor/cookies.rb#2 -class Raven::Processor::Cookies < ::Raven::Processor - # source://sentry-raven//lib/raven/processor/cookies.rb#3 - def process(data); end - - private - - # source://sentry-raven//lib/raven/processor/cookies.rb#32 - def generate_masked_cookies(cookies); end - - # source://sentry-raven//lib/raven/processor/cookies.rb#22 - def process_if_string_keys(data); end - - # source://sentry-raven//lib/raven/processor/cookies.rb#12 - def process_if_symbol_keys(data); end -end - -# source://sentry-raven//lib/raven/processor/http_headers.rb#2 -class Raven::Processor::HTTPHeaders < ::Raven::Processor - # source://sentry-raven//lib/raven/processor/http_headers.rb#7 - def initialize(client); end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#12 - def process(data); end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#5 - def sanitize_http_headers; end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#5 - def sanitize_http_headers=(_arg0); end - - private - - # source://sentry-raven//lib/raven/processor/http_headers.rb#41 - def fields_re; end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#37 - def matches_regexes?(k); end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#29 - def process_if_string_keys(data); end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#21 - def process_if_symbol_keys(data); end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#51 - def special_characters?(string); end - - # source://sentry-raven//lib/raven/processor/http_headers.rb#47 - def use_boundary?(string); end -end - -# source://sentry-raven//lib/raven/processor/http_headers.rb#3 -Raven::Processor::HTTPHeaders::DEFAULT_FIELDS = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/processor.rb#4 -Raven::Processor::INT_MASK = T.let(T.unsafe(nil), Integer) - -# source://sentry-raven//lib/raven/processor/post_data.rb#2 -class Raven::Processor::PostData < ::Raven::Processor - # source://sentry-raven//lib/raven/processor/post_data.rb#3 - def process(data); end - - private - - # source://sentry-raven//lib/raven/processor/post_data.rb#18 - def process_if_string_keys(data); end - - # source://sentry-raven//lib/raven/processor/post_data.rb#12 - def process_if_symbol_keys(data); end -end - -# source://sentry-raven//lib/raven/processor.rb#5 -Raven::Processor::REGEX_SPECIAL_CHARACTERS = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/processor/removecircularreferences.rb#2 -class Raven::Processor::RemoveCircularReferences < ::Raven::Processor - # source://sentry-raven//lib/raven/processor/removecircularreferences.rb#4 - def process(value, visited = T.unsafe(nil)); end -end - -# source://sentry-raven//lib/raven/processor/removecircularreferences.rb#3 -Raven::Processor::RemoveCircularReferences::ELISION_STRING = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/processor.rb#3 -Raven::Processor::STRING_MASK = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/processor/sanitizedata.rb#6 -class Raven::Processor::SanitizeData < ::Raven::Processor - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#14 - def initialize(client); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#21 - def process(value, key = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#12 - def sanitize_credit_cards; end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#12 - def sanitize_credit_cards=(_arg0); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#12 - def sanitize_fields; end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#12 - def sanitize_fields=(_arg0); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#12 - def sanitize_fields_excluded; end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#12 - def sanitize_fields_excluded=(_arg0); end - - private - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#105 - def matches_regexes?(k, v); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#128 - def parse_json_or_nil(string); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#54 - def sanitize_array_value(key, value); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#44 - def sanitize_hash_value(key, value); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#77 - def sanitize_query_string(query_string); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#101 - def sanitize_sensitive_string_content(value); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#62 - def sanitize_string_value(key, value); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#110 - def sensitive_fields; end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#124 - def special_characters?(string); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#120 - def use_boundary?(string); end - - # source://sentry-raven//lib/raven/processor/sanitizedata.rb#40 - def utf8_processor; end -end - -# source://sentry-raven//lib/raven/processor/sanitizedata.rb#8 -Raven::Processor::SanitizeData::CREDIT_CARD_RE = T.let(T.unsafe(nil), Regexp) - -# source://sentry-raven//lib/raven/processor/sanitizedata.rb#7 -Raven::Processor::SanitizeData::DEFAULT_FIELDS = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/processor/sanitizedata.rb#10 -Raven::Processor::SanitizeData::JSON_STARTS_WITH = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/processor/sanitizedata.rb#9 -Raven::Processor::SanitizeData::QUERY_STRING = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/processor/utf8conversion.rb#2 -class Raven::Processor::UTF8Conversion < ::Raven::Processor - # source://sentry-raven//lib/raven/processor/utf8conversion.rb#9 - def process(value); end - - private - - # source://sentry-raven//lib/raven/processor/utf8conversion.rb#43 - def remove_invalid_bytes(string); end -end - -# source://sentry-raven//lib/raven/processor/utf8conversion.rb#7 -Raven::Processor::UTF8Conversion::REPLACE = T.let(T.unsafe(nil), String) - -# Middleware for Rack applications. Any errors raised by the upstream -# application will be delivered to Sentry and re-raised. -# -# Synopsis: -# -# require 'rack' -# require 'raven' -# -# Raven.configure do |config| -# config.server = 'http://my_dsn' -# end -# -# app = Rack::Builder.app do -# use Raven::Rack -# run lambda { |env| raise "Rack down" } -# end -# -# Use a standard Raven.configure call to configure your server credentials. -# -# source://sentry-raven//lib/raven/integrations/rack.rb#23 -class Raven::Rack - # @return [Rack] a new instance of Rack - # - # source://sentry-raven//lib/raven/integrations/rack.rb#39 - def initialize(app); end - - # source://sentry-raven//lib/raven/integrations/rack.rb#43 - def call(env); end - - class << self - # source://sentry-raven//lib/raven/integrations/rack.rb#24 - def capture_exception(exception, env, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/integrations/rack.rb#24 - def capture_message(exception, env, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/integrations/rack.rb#24 - def capture_type(exception, env, options = T.unsafe(nil)); end - end -end - -# source://sentry-raven//lib/raven/integrations/rack.rb#69 -module Raven::RackInterface - # source://sentry-raven//lib/raven/integrations/rack.rb#70 - def from_rack(env_hash); end - - private - - # source://sentry-raven//lib/raven/integrations/rack.rb#129 - def format_env_for_sentry(env_hash); end - - # source://sentry-raven//lib/raven/integrations/rack.rb#99 - def format_headers_for_sentry(env_hash); end - - # See Sentry server default limits at - # https://github.com/getsentry/sentry/blob/master/src/sentry/conf/server.py - # - # source://sentry-raven//lib/raven/integrations/rack.rb#87 - def read_data_from(request); end -end - -# source://sentry-raven//lib/raven/integrations/rails.rb#4 -class Raven::Rails < ::Rails::Railtie; end - -# source://sentry-raven//lib/raven/integrations/rails/backtrace_cleaner.rb#6 -class Raven::Rails::BacktraceCleaner < ::ActiveSupport::BacktraceCleaner - # @return [BacktraceCleaner] a new instance of BacktraceCleaner - # - # source://sentry-raven//lib/raven/integrations/rails/backtrace_cleaner.rb#10 - def initialize; end -end - -# source://sentry-raven//lib/raven/integrations/rails/backtrace_cleaner.rb#7 -Raven::Rails::BacktraceCleaner::APP_DIRS_PATTERN = T.let(T.unsafe(nil), Regexp) - -# source://sentry-raven//lib/raven/integrations/rails/backtrace_cleaner.rb#8 -Raven::Rails::BacktraceCleaner::RENDER_TEMPLATE_PATTERN = T.let(T.unsafe(nil), Regexp) - -# source://sentry-raven//lib/raven/integrations/rails/controller_methods.rb#3 -module Raven::Rails::ControllerMethods - # source://sentry-raven//lib/raven/integrations/rails/controller_methods.rb#8 - def capture_exception(exception, options = T.unsafe(nil)); end - - # source://sentry-raven//lib/raven/integrations/rails/controller_methods.rb#4 - def capture_message(message, options = T.unsafe(nil)); end -end - -# source://sentry-raven//lib/raven/integrations/rails/controller_transaction.rb#3 -module Raven::Rails::ControllerTransaction - class << self - # @private - # - # source://sentry-raven//lib/raven/integrations/rails/controller_transaction.rb#4 - def included(base); end - end -end - -# source://sentry-raven//lib/raven/integrations/rails/overrides/streaming_reporter.rb#3 -module Raven::Rails::Overrides; end - -# source://sentry-raven//lib/raven/integrations/rails/overrides/streaming_reporter.rb#11 -module Raven::Rails::Overrides::OldStreamingReporter - # source://sentry-raven//lib/raven/integrations/rails/overrides/streaming_reporter.rb#16 - def log_error_with_raven(exception); end - - class << self - # @private - # - # source://sentry-raven//lib/raven/integrations/rails/overrides/streaming_reporter.rb#12 - def included(base); end - end -end - -# source://sentry-raven//lib/raven/integrations/rails/overrides/streaming_reporter.rb#4 -module Raven::Rails::Overrides::StreamingReporter - # source://sentry-raven//lib/raven/integrations/rails/overrides/streaming_reporter.rb#5 - def log_error(exception); end -end - -# source://sentry-raven//lib/raven/integrations/sidekiq/cleanup_middleware.rb#2 -module Raven::Sidekiq; end - -# source://sentry-raven//lib/raven/integrations/sidekiq/cleanup_middleware.rb#3 -class Raven::Sidekiq::CleanupMiddleware - # source://sentry-raven//lib/raven/integrations/sidekiq/cleanup_middleware.rb#4 - def call(_worker, job, queue); end -end - -# source://sentry-raven//lib/raven/integrations/sidekiq/error_handler.rb#5 -class Raven::Sidekiq::ErrorHandler - # source://sentry-raven//lib/raven/integrations/sidekiq/error_handler.rb#8 - def call(ex, context); end - - private - - # this will change in the future: - # https://github.com/mperham/sidekiq/pull/3161 - # - # source://sentry-raven//lib/raven/integrations/sidekiq/error_handler.rb#24 - def transaction_from_context(context); end -end - -# source://sentry-raven//lib/raven/integrations/sidekiq/error_handler.rb#6 -Raven::Sidekiq::ErrorHandler::SIDEKIQ_NAME = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/interfaces/single_exception.rb#2 -class Raven::SingleExceptionInterface < ::Raven::Interface - # Returns the value of attribute module. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#5 - def module; end - - # Sets the attribute module - # - # @param value the value to set the attribute module to. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#5 - def module=(_arg0); end - - # Returns the value of attribute stacktrace. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#6 - def stacktrace; end - - # Sets the attribute stacktrace - # - # @param value the value to set the attribute stacktrace to. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#6 - def stacktrace=(_arg0); end - - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#8 - def to_hash(*args); end - - # Returns the value of attribute type. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#3 - def type; end - - # Sets the attribute type - # - # @param value the value to set the attribute type to. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#3 - def type=(_arg0); end - - # Returns the value of attribute value. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#4 - def value; end - - # Sets the attribute value - # - # @param value the value to set the attribute value to. - # - # source://sentry-raven//lib/raven/interfaces/single_exception.rb#4 - def value=(_arg0); end -end - -# source://sentry-raven//lib/raven/interfaces/stack_trace.rb#2 -class Raven::StacktraceInterface < ::Raven::Interface - # @return [StacktraceInterface] a new instance of StacktraceInterface - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#5 - def initialize(*arguments); end - - # Returns the value of attribute frames. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#3 - def frames; end - - # Sets the attribute frames - # - # @param value the value to set the attribute frames to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#3 - def frames=(_arg0); end - - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#13 - def to_hash(*args); end - - class << self - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#9 - def sentry_alias; end - end -end - -# Not actually an interface, but I want to use the same style -# -# source://sentry-raven//lib/raven/interfaces/stack_trace.rb#20 -class Raven::StacktraceInterface::Frame < ::Raven::Interface - # @return [Frame] a new instance of Frame - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#24 - def initialize(*arguments); end - - # Returns the value of attribute abs_path. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def abs_path; end - - # Sets the attribute abs_path - # - # @param value the value to set the attribute abs_path to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def abs_path=(_arg0); end - - # Returns the value of attribute context_line. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def context_line; end - - # Sets the attribute context_line - # - # @param value the value to set the attribute context_line to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def context_line=(_arg0); end - - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#28 - def filename; end - - # Returns the value of attribute function. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def function; end - - # Sets the attribute function - # - # @param value the value to set the attribute function to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def function=(_arg0); end - - # Returns the value of attribute in_app. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def in_app; end - - # Sets the attribute in_app - # - # @param value the value to set the attribute in_app to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def in_app=(_arg0); end - - # Returns the value of attribute lineno. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def lineno; end - - # Sets the attribute lineno - # - # @param value the value to set the attribute lineno to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def lineno=(_arg0); end - - # Returns the value of attribute module. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def module; end - - # Sets the attribute module - # - # @param value the value to set the attribute module to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def module=(_arg0); end - - # Returns the value of attribute post_context. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def post_context; end - - # Sets the attribute post_context - # - # @param value the value to set the attribute post_context to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def post_context=(_arg0); end - - # Returns the value of attribute pre_context. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def pre_context; end - - # Sets the attribute pre_context - # - # @param value the value to set the attribute pre_context to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def pre_context=(_arg0); end - - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#44 - def to_hash(*args); end - - # Returns the value of attribute vars. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def vars; end - - # Sets the attribute vars - # - # @param value the value to set the attribute vars to. - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#21 - def vars=(_arg0); end - - private - - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#64 - def longest_load_path; end - - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#60 - def project_root; end - - # @return [Boolean] - # - # source://sentry-raven//lib/raven/interfaces/stack_trace.rb#56 - def under_project_root?; end -end - -# source://sentry-raven//lib/raven/transports.rb#2 -module Raven::Transports; end - -# source://sentry-raven//lib/raven/transports/dummy.rb#3 -class Raven::Transports::Dummy < ::Raven::Transports::Transport - # @return [Dummy] a new instance of Dummy - # - # source://sentry-raven//lib/raven/transports/dummy.rb#6 - def initialize(*_arg0); end - - # Returns the value of attribute events. - # - # source://sentry-raven//lib/raven/transports/dummy.rb#4 - def events; end - - # Sets the attribute events - # - # @param value the value to set the attribute events to. - # - # source://sentry-raven//lib/raven/transports/dummy.rb#4 - def events=(_arg0); end - - # source://sentry-raven//lib/raven/transports/dummy.rb#11 - def send_event(auth_header, data, options = T.unsafe(nil)); end -end - -# source://sentry-raven//lib/raven/transports/http.rb#5 -class Raven::Transports::HTTP < ::Raven::Transports::Transport - # @return [HTTP] a new instance of HTTP - # - # source://sentry-raven//lib/raven/transports/http.rb#8 - def initialize(*args); end - - # Returns the value of attribute adapter. - # - # source://sentry-raven//lib/raven/transports/http.rb#6 - def adapter; end - - # Sets the attribute adapter - # - # @param value the value to set the attribute adapter to. - # - # source://sentry-raven//lib/raven/transports/http.rb#6 - def adapter=(_arg0); end - - # Returns the value of attribute conn. - # - # source://sentry-raven//lib/raven/transports/http.rb#6 - def conn; end - - # Sets the attribute conn - # - # @param value the value to set the attribute conn to. - # - # source://sentry-raven//lib/raven/transports/http.rb#6 - def conn=(_arg0); end - - # source://sentry-raven//lib/raven/transports/http.rb#14 - def send_event(auth_header, data, options = T.unsafe(nil)); end - - private - - # TODO: deprecate and replace where possible w/Faraday Builder - # - # source://sentry-raven//lib/raven/transports/http.rb#53 - def faraday_opts; end - - # source://sentry-raven//lib/raven/transports/http.rb#38 - def set_conn; end - - # source://sentry-raven//lib/raven/transports/http.rb#59 - def ssl_configuration; end -end - -# source://sentry-raven//lib/raven/transports/stdout.rb#3 -class Raven::Transports::Stdout < ::Raven::Transports::Transport - # @return [Stdout] a new instance of Stdout - # - # source://sentry-raven//lib/raven/transports/stdout.rb#6 - def initialize(*_arg0); end - - # Returns the value of attribute events. - # - # source://sentry-raven//lib/raven/transports/stdout.rb#4 - def events; end - - # Sets the attribute events - # - # @param value the value to set the attribute events to. - # - # source://sentry-raven//lib/raven/transports/stdout.rb#4 - def events=(_arg0); end - - # source://sentry-raven//lib/raven/transports/stdout.rb#10 - def send_event(_auth_header, data, _options = T.unsafe(nil)); end -end - -# source://sentry-raven//lib/raven/transports.rb#3 -class Raven::Transports::Transport - # @return [Transport] a new instance of Transport - # - # source://sentry-raven//lib/raven/transports.rb#6 - def initialize(configuration); end - - # Returns the value of attribute configuration. - # - # source://sentry-raven//lib/raven/transports.rb#4 - def configuration; end - - # Sets the attribute configuration - # - # @param value the value to set the attribute configuration to. - # - # source://sentry-raven//lib/raven/transports.rb#4 - def configuration=(_arg0); end - - # (auth_header, data, options = {}) - # - # @raise [NotImplementedError] - # - # source://sentry-raven//lib/raven/transports.rb#10 - def send_event; end -end - -# source://sentry-raven//lib/raven/utils/deep_merge.rb#2 -module Raven::Utils; end - -# source://sentry-raven//lib/raven/utils/context_filter.rb#3 -module Raven::Utils::ContextFilter - class << self - # Once an ActiveJob is queued, ActiveRecord references get serialized into - # some internal reserved keys, such as _aj_globalid. - # - # The problem is, if this job in turn gets queued back into ActiveJob with - # these magic reserved keys, ActiveJob will throw up and error. We want to - # capture these and mutate the keys so we can sanely report it. - # - # source://sentry-raven//lib/raven/utils/context_filter.rb#14 - def filter_context(context); end - - private - - # source://sentry-raven//lib/raven/utils/context_filter.rb#27 - def filter_context_hash(key, value); end - - # source://sentry-raven//lib/raven/utils/context_filter.rb#32 - def format_globalid(context); end - end -end - -# ported from ActiveSupport -# -# source://sentry-raven//lib/raven/utils/deep_merge.rb#4 -module Raven::Utils::DeepMergeHash - class << self - # source://sentry-raven//lib/raven/utils/deep_merge.rb#5 - def deep_merge(hash, other_hash, &block); end - - # source://sentry-raven//lib/raven/utils/deep_merge.rb#9 - def deep_merge!(hash, other_hash, &block); end - end -end - -# source://sentry-raven//lib/raven/utils/exception_cause_chain.rb#3 -module Raven::Utils::ExceptionCauseChain - class << self - # source://sentry-raven//lib/raven/utils/exception_cause_chain.rb#4 - def exception_to_array(exception); end - end -end - -# source://sentry-raven//lib/raven/utils/real_ip.rb#9 -class Raven::Utils::RealIp - # @return [RealIp] a new instance of RealIp - # - # source://sentry-raven//lib/raven/utils/real_ip.rb#21 - def initialize(ip_addresses); end - - # source://sentry-raven//lib/raven/utils/real_ip.rb#25 - def calculate_ip; end - - # Returns the value of attribute ip. - # - # source://sentry-raven//lib/raven/utils/real_ip.rb#19 - def ip; end - - # Sets the attribute ip - # - # @param value the value to set the attribute ip to. - # - # source://sentry-raven//lib/raven/utils/real_ip.rb#19 - def ip=(_arg0); end - - # Returns the value of attribute ip_addresses. - # - # source://sentry-raven//lib/raven/utils/real_ip.rb#19 - def ip_addresses; end - - # Sets the attribute ip_addresses - # - # @param value the value to set the attribute ip_addresses to. - # - # source://sentry-raven//lib/raven/utils/real_ip.rb#19 - def ip_addresses=(_arg0); end - - protected - - # source://sentry-raven//lib/raven/utils/real_ip.rb#57 - def filter_local_addresses(ips); end - - # source://sentry-raven//lib/raven/utils/real_ip.rb#42 - def ips_from(header); end -end - -# source://sentry-raven//lib/raven/utils/real_ip.rb#10 -Raven::Utils::RealIp::LOCAL_ADDRESSES = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/utils/request_id.rb#3 -module Raven::Utils::RequestId - class << self - # Request ID based on ActionDispatch::RequestId - # - # source://sentry-raven//lib/raven/utils/request_id.rb#7 - def read_from(env_hash); end - end -end - -# source://sentry-raven//lib/raven/utils/request_id.rb#4 -Raven::Utils::RequestId::REQUEST_ID_HEADERS = T.let(T.unsafe(nil), Array) - -# source://sentry-raven//lib/raven/version.rb#4 -Raven::VERSION = T.let(T.unsafe(nil), String) - -# source://sentry-raven//lib/raven/core_ext/object/duplicable.rb#77 -class Symbol - include ::Comparable -end diff --git a/sorbet/rbi/gems/sentry-ruby@5.19.0.rbi b/sorbet/rbi/gems/sentry-ruby@5.19.0.rbi new file mode 100644 index 000000000..9079780fc --- /dev/null +++ b/sorbet/rbi/gems/sentry-ruby@5.19.0.rbi @@ -0,0 +1,6103 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `sentry-ruby` gem. +# Please instead update this file by running `bin/tapioca gem sentry-ruby`. + + +# @api private +# +# source://sentry-ruby//lib/sentry/rake.rb#26 +module Rake + extend ::FileUtils::StreamUtils_ + extend ::FileUtils +end + +# @api private +# +# source://sentry-ruby//lib/sentry/rake.rb#27 +class Rake::Application + include ::Sentry::Rake::Application + + # source://rake/13.2.1/lib/rake/application.rb#49 + def initialize; end + + # source://rake/13.2.1/lib/rake/application.rb#807 + def add_import(fn); end + + # source://rake/13.2.1/lib/rake/application.rb#161 + def add_loader(ext, loader); end + + # source://rake/13.2.1/lib/rake/application.rb#788 + def collect_command_line_tasks(args); end + + # source://rake/13.2.1/lib/rake/application.rb#802 + def default_task_name; end + + # source://rake/13.2.1/lib/rake/application.rb#288 + def deprecate(old_usage, new_usage, call_site); end + + # source://rake/13.2.1/lib/rake/application.rb#250 + def display_cause_details(ex); end + + # source://sentry-ruby//lib/sentry/rake.rb#10 + def display_error_message(ex); end + + # source://rake/13.2.1/lib/rake/application.rb#275 + def display_exception_backtrace(ex); end + + # source://rake/13.2.1/lib/rake/application.rb#242 + def display_exception_details(ex); end + + # source://rake/13.2.1/lib/rake/application.rb#257 + def display_exception_details_seen; end + + # source://rake/13.2.1/lib/rake/application.rb#265 + def display_exception_message_details(ex); end + + # source://rake/13.2.1/lib/rake/application.rb#411 + def display_prerequisites; end + + # source://rake/13.2.1/lib/rake/application.rb#328 + def display_tasks_and_comments; end + + # source://rake/13.2.1/lib/rake/application.rb#379 + def dynamic_width; end + + # source://rake/13.2.1/lib/rake/application.rb#383 + def dynamic_width_stty; end + + # source://rake/13.2.1/lib/rake/application.rb#387 + def dynamic_width_tput; end + + # source://rake/13.2.1/lib/rake/application.rb#229 + def exit_because_of_exception(ex); end + + # source://rake/13.2.1/lib/rake/application.rb#708 + def find_rakefile_location; end + + # source://rake/13.2.1/lib/rake/application.rb#674 + def handle_options(argv); end + + # source://rake/13.2.1/lib/rake/application.rb#261 + def has_cause?(ex); end + + # source://rake/13.2.1/lib/rake/application.rb#304 + def have_rakefile; end + + # source://rake/13.2.1/lib/rake/application.rb#88 + def init(app_name = T.unsafe(nil), argv = T.unsafe(nil)); end + + # source://rake/13.2.1/lib/rake/application.rb#185 + def invoke_task(task_string); end + + # source://rake/13.2.1/lib/rake/application.rb#812 + def load_imports; end + + # source://rake/13.2.1/lib/rake/application.rb#124 + def load_rakefile; end + + # source://rake/13.2.1/lib/rake/application.rb#24 + def name; end + + # source://rake/13.2.1/lib/rake/application.rb#167 + def options; end + + # source://rake/13.2.1/lib/rake/application.rb#27 + def original_dir; end + + # source://rake/13.2.1/lib/rake/application.rb#191 + def parse_task_string(string); end + + # source://rake/13.2.1/lib/rake/application.rb#720 + def print_rakefile_directory(location); end + + # source://rake/13.2.1/lib/rake/application.rb#694 + def rake_require(file_name, paths = T.unsafe(nil), loaded = T.unsafe(nil)); end + + # source://rake/13.2.1/lib/rake/application.rb#30 + def rakefile; end + + # source://rake/13.2.1/lib/rake/application.rb#828 + def rakefile_location(backtrace = T.unsafe(nil)); end + + # source://rake/13.2.1/lib/rake/application.rb#725 + def raw_load_rakefile; end + + # source://rake/13.2.1/lib/rake/application.rb#79 + def run(argv = T.unsafe(nil)); end + + # source://rake/13.2.1/lib/rake/application.rb#144 + def run_with_threads; end + + # source://rake/13.2.1/lib/rake/application.rb#837 + def set_default_options; end + + # source://rake/13.2.1/lib/rake/application.rb#213 + def standard_exception_handling; end + + # source://rake/13.2.1/lib/rake/application.rb#432 + def standard_rake_options; end + + # source://rake/13.2.1/lib/rake/application.rb#757 + def system_dir; end + + # source://rake/13.2.1/lib/rake/application.rb#33 + def terminal_columns; end + + # source://rake/13.2.1/lib/rake/application.rb#33 + def terminal_columns=(_arg0); end + + # source://rake/13.2.1/lib/rake/application.rb#367 + def terminal_width; end + + # source://rake/13.2.1/lib/rake/application.rb#178 + def thread_pool; end + + # source://rake/13.2.1/lib/rake/application.rb#131 + def top_level; end + + # source://rake/13.2.1/lib/rake/application.rb#36 + def top_level_tasks; end + + # source://rake/13.2.1/lib/rake/application.rb#418 + def trace(*strings); end + + # source://rake/13.2.1/lib/rake/application.rb#400 + def truncate(string, width); end + + # source://rake/13.2.1/lib/rake/application.rb#323 + def truncate_output?; end + + # source://rake/13.2.1/lib/rake/application.rb#39 + def tty_output=(_arg0); end + + # source://rake/13.2.1/lib/rake/application.rb#317 + def tty_output?; end + + # source://rake/13.2.1/lib/rake/application.rb#391 + def unix?; end + + # source://rake/13.2.1/lib/rake/application.rb#396 + def windows?; end + + private + + # source://rake/13.2.1/lib/rake/application.rb#751 + def glob(path, &block); end + + # source://rake/13.2.1/lib/rake/application.rb#297 + def has_chain?(exception); end + + # source://rake/13.2.1/lib/rake/application.rb#102 + def load_debug_at_stop_feature; end + + # source://rake/13.2.1/lib/rake/application.rb#650 + def select_tasks_to_show(options, show_tasks, value); end + + # source://rake/13.2.1/lib/rake/application.rb#657 + def select_trace_output(options, trace_option, value); end + + # source://rake/13.2.1/lib/rake/application.rb#423 + def sort_options(options); end + + # source://rake/13.2.1/lib/rake/application.rb#774 + def standard_system_dir; end +end + +# Based on ActionDispatch::RemoteIp. All security-related precautions from that +# middleware have been removed, because the Event IP just needs to be accurate, +# and spoofing an IP here only makes data inaccurate, not insecure. Don't re-use +# this module if you have to *trust* the IP address. +# +# source://sentry-ruby//lib/sentry/version.rb#3 +module Sentry + class << self + # source://sentry-ruby//lib/sentry-ruby.rb#216 + def add_attachment(**opts); end + + # Takes an instance of Sentry::Breadcrumb and stores it to the current active scope. + # + # @return [Breadcrumb, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#311 + def add_breadcrumb(breadcrumb, **options); end + + # Add a global event processor [Proc]. + # These run before scope event processors. + # + # @example + # Sentry.add_global_event_processor do |event, hint| + # event.tags = { foo: 42 } + # event + # end + # @return [void] + # @yieldparam event [Event] + # @yieldparam hint [Hash, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#530 + def add_global_event_processor(&block); end + + # source://sentry-ruby//lib/sentry-ruby.rb#104 + def apply_patches(config); end + + # @return [BackgroundWorker] + # + # source://sentry-ruby//lib/sentry-ruby.rb#72 + def background_worker; end + + # Sets the attribute background_worker + # + # @param value the value to set the attribute background_worker to. + # + # source://sentry-ruby//lib/sentry-ruby.rb#72 + def background_worker=(_arg0); end + + # Returns the value of attribute backpressure_monitor. + # + # source://sentry-ruby//lib/sentry-ruby.rb#80 + def backpressure_monitor; end + + # Captures a check-in and sends it to Sentry via the currently active hub. + # + # @option options + # @option options + # @option options + # @param slug [String] identifier of this monitor + # @param status [Symbol] status of this check-in, one of {CheckInEvent::VALID_STATUSES} + # @param options [Hash] extra check-in options + # @return [String, nil] The {CheckInEvent#check_in_id} to use for later updates on the same slug + # + # source://sentry-ruby//lib/sentry-ruby.rb#470 + def capture_check_in(slug, status, **options); end + + # Takes an instance of Sentry::Event and dispatches it to the currently active hub. + # + # @return [Event, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#454 + def capture_event(event); end + + # Takes an exception and reports it to Sentry via the currently active hub. + # + # @return [Event, nil] + # @yieldparam scope [Scope] + # + # source://sentry-ruby//lib/sentry-ruby.rb#418 + def capture_exception(exception, **options, &block); end + + # Takes a message string and reports it to Sentry via the currently active hub. + # + # @return [Event, nil] + # @yieldparam scope [Scope] + # + # source://sentry-ruby//lib/sentry-ruby.rb#446 + def capture_message(message, **options, &block); end + + # Clones the main thread's active hub and stores it to the current thread. + # + # @return [void] + # + # source://sentry-ruby//lib/sentry-ruby.rb#348 + def clone_hub_to_current_thread; end + + # Flushes pending events and cleans up SDK state. + # SDK will stop sending events and all top-level APIs will be no-ops after this. + # + # @return [void] + # + # source://sentry-ruby//lib/sentry-ruby.rb#249 + def close; end + + # source://sentry-ruby//lib/sentry-ruby.rb#156 + def configuration; end + + # Takes a block and yields the current active scope. + # + # @example + # Sentry.configure_scope do |scope| + # scope.set_tags(foo: "bar") + # end + # + # Sentry.capture_message("test message") # this event will have tags { foo: "bar" } + # @return [void] + # @yieldparam scope [Scope] + # + # source://sentry-ruby//lib/sentry-ruby.rb#364 + def configure_scope(&block); end + + # Continue an incoming trace from a rack env like hash. + # + # @param env [Hash] + # @return [Transaction, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#574 + def continue_trace(env, **options); end + + # Returns an uri for security policy reporting that's generated from the given DSN + # (To learn more about security policy reporting: https://docs.sentry.io/product/security-policy-reporting/) + # + # It returns nil if + # - The SDK is not initialized yet. + # - The DSN is not provided or is invalid. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#296 + def csp_report_uri; end + + # Checks if the exception object has been captured by the SDK. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry-ruby.rb#512 + def exception_captured?(exc); end + + # source://sentry-ruby//lib/sentry-ruby.rb#54 + def exception_locals_tp; end + + # Returns the baggage header for distributed tracing. + # Can be either from the currently active span or the propagation context. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#547 + def get_baggage; end + + # Returns the current active client. + # + # @return [Client, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#332 + def get_current_client; end + + # Returns the current active hub. + # If the current thread doesn't have an active hub, it will clone the main thread's active hub, + # stores it in the current thread, and then returns it. + # + # @return [Hub] + # + # source://sentry-ruby//lib/sentry-ruby.rb#321 + def get_current_hub; end + + # Returns the current active scope. + # + # @return [Scope, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#340 + def get_current_scope; end + + # Returns the main thread's active hub. + # + # @return [Hub] + # + # source://sentry-ruby//lib/sentry-ruby.rb#304 + def get_main_hub; end + + # Returns the a Hash containing sentry-trace and baggage. + # Can be either from the currently active span or the propagation context. + # + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#556 + def get_trace_propagation_headers; end + + # Returns the a Hash containing sentry-trace and baggage. + # Can be either from the currently active span or the propagation context. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry-ruby.rb#565 + def get_trace_propagation_meta; end + + # Returns the traceparent (sentry-trace) header for distributed tracing. + # Can be either from the currently active span or the propagation context. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#538 + def get_traceparent; end + + # Initializes the SDK with given configuration. + # + # @return [void] + # @yieldparam config [Configuration] + # + # source://sentry-ruby//lib/sentry-ruby.rb#227 + def init(&block); end + + # Returns true if the SDK is initialized. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry-ruby.rb#284 + def initialized?; end + + # Returns a hash that contains all the integrations that have been registered to the main SDK. + # + # @return [Hash{String=>Hash}] + # + # source://sentry-ruby//lib/sentry-ruby.rb#120 + def integrations; end + + # Returns the id of the lastly reported Sentry::Event. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#504 + def last_event_id; end + + # source://sentry-ruby//lib/sentry-ruby.rb#590 + def logger; end + + # Returns the value of attribute metrics_aggregator. + # + # source://sentry-ruby//lib/sentry-ruby.rb#84 + def metrics_aggregator; end + + # source://railties/7.2.0/lib/rails/engine.rb#412 + def railtie_helpers_paths; end + + # source://railties/7.2.0/lib/rails/engine.rb#395 + def railtie_namespace; end + + # source://railties/7.2.0/lib/rails/engine.rb#416 + def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end + + # Registers the SDK integration with its name and version. + # + # @param name [String] name of the integration + # @param version [String] version of the integration + # + # source://sentry-ruby//lib/sentry-ruby.rb#128 + def register_integration(name, version); end + + # source://sentry-ruby//lib/sentry-ruby.rb#89 + def register_patch(key, patch = T.unsafe(nil), target = T.unsafe(nil), &block); end + + # source://sentry-ruby//lib/sentry-ruby.rb#111 + def registered_patches; end + + # source://sentry-ruby//lib/sentry-ruby.rb#595 + def sdk_meta; end + + # source://sentry-ruby//lib/sentry-ruby.rb#163 + def send_event(*args); end + + # Returns the value of attribute session_flusher. + # + # source://sentry-ruby//lib/sentry-ruby.rb#76 + def session_flusher; end + + # source://sentry-ruby//lib/sentry-ruby.rb#209 + def set_context(*args); end + + # source://sentry-ruby//lib/sentry-ruby.rb#195 + def set_extras(*args); end + + # source://sentry-ruby//lib/sentry-ruby.rb#188 + def set_tags(*args); end + + # source://sentry-ruby//lib/sentry-ruby.rb#202 + def set_user(*args); end + + # Takes or initializes a new Sentry::Transaction and makes a sampling decision for it. + # + # @return [Transaction, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#478 + def start_transaction(**options); end + + # source://sentry-ruby//lib/sentry-ruby.rb#582 + def sys_command(command); end + + # source://railties/7.2.0/lib/rails/engine.rb#401 + def table_name_prefix; end + + # source://railties/7.2.0/lib/rails/engine.rb#408 + def use_relative_model_naming?; end + + # source://sentry-ruby//lib/sentry-ruby.rb#600 + def utc_now; end + + # Records the block's execution as a child of the current span. + # If the current scope doesn't have a span, the block would still be executed but the yield param will be nil. + # + # @example + # Sentry.with_child_span(op: "my operation") do |child_span| + # child_span.set_data(operation_data) + # child_span.set_description(operation_detail) + # # result will be returned + # end + # @param attributes [Hash] attributes for the child span. + # @return yield result + # @yieldparam child_span [Span, nil] + # + # source://sentry-ruby//lib/sentry-ruby.rb#496 + def with_child_span(**attributes, &block); end + + # Takes a block and evaluates it. If the block raised an exception, it reports the exception to Sentry and re-raises it. + # If the block ran without exception, it returns the evaluation result. + # + # @example + # Sentry.with_exception_captured do + # 1/1 #=> 1 will be returned + # end + # + # Sentry.with_exception_captured do + # 1/0 #=> ZeroDivisionError will be reported and re-raised + # end + # + # source://sentry-ruby//lib/sentry-ruby.rb#435 + def with_exception_captured(**options, &block); end + + # Takes a block and yields a temporary scope. + # The temporary scope will inherit all the attributes from the current active scope and replace it to be the active + # scope inside the block. + # + # @example + # Sentry.configure_scope do |scope| + # scope.set_tags(foo: "bar") + # end + # + # Sentry.capture_message("test message") # this event will have tags { foo: "bar" } + # + # Sentry.with_scope do |temp_scope| + # temp_scope.set_tags(foo: "baz") + # Sentry.capture_message("test message 2") # this event will have tags { foo: "baz" } + # end + # + # Sentry.capture_message("test message 3") # this event will have tags { foo: "bar" } + # @return [void] + # @yieldparam scope [Scope] + # + # source://sentry-ruby//lib/sentry-ruby.rb#389 + def with_scope(&block); end + + # Wrap a given block with session tracking. + # Aggregate sessions in minutely buckets will be recorded + # around this block and flushed every minute. + # + # @example + # Sentry.with_session_tracking do + # a = 1 + 1 # new session recorded with :exited status + # end + # + # Sentry.with_session_tracking do + # 1 / 0 + # rescue => e + # Sentry.capture_exception(e) # new session recorded with :errored status + # end + # @return [void] + # + # source://sentry-ruby//lib/sentry-ruby.rb#409 + def with_session_tracking(&block); end + end +end + +# source://sentry-ruby//lib/sentry/utils/argument_checking_helper.rb#4 +module Sentry::ArgumentCheckingHelper + private + + # source://sentry-ruby//lib/sentry/utils/argument_checking_helper.rb#13 + def check_argument_includes!(argument, values); end + + # source://sentry-ruby//lib/sentry/utils/argument_checking_helper.rb#7 + def check_argument_type!(argument, *expected_types); end + + # source://sentry-ruby//lib/sentry/utils/argument_checking_helper.rb#19 + def check_callable!(name, value); end +end + +# source://sentry-ruby//lib/sentry/attachment.rb#4 +class Sentry::Attachment + # @return [Attachment] a new instance of Attachment + # + # source://sentry-ruby//lib/sentry/attachment.rb#9 + def initialize(bytes: T.unsafe(nil), filename: T.unsafe(nil), content_type: T.unsafe(nil), path: T.unsafe(nil)); end + + # Returns the value of attribute bytes. + # + # source://sentry-ruby//lib/sentry/attachment.rb#7 + def bytes; end + + # Returns the value of attribute content_type. + # + # source://sentry-ruby//lib/sentry/attachment.rb#7 + def content_type; end + + # Returns the value of attribute filename. + # + # source://sentry-ruby//lib/sentry/attachment.rb#7 + def filename; end + + # Returns the value of attribute path. + # + # source://sentry-ruby//lib/sentry/attachment.rb#7 + def path; end + + # source://sentry-ruby//lib/sentry/attachment.rb#20 + def payload; end + + # source://sentry-ruby//lib/sentry/attachment.rb#16 + def to_envelope_headers; end + + private + + # source://sentry-ruby//lib/sentry/attachment.rb#32 + def infer_filename(filename, path); end +end + +# source://sentry-ruby//lib/sentry/attachment.rb#5 +class Sentry::Attachment::PathNotFoundError < ::StandardError; end + +# source://sentry-ruby//lib/sentry-ruby.rb#48 +Sentry::BAGGAGE_HEADER_NAME = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/background_worker.rb#8 +class Sentry::BackgroundWorker + include ::Sentry::LoggingHelper + + # @return [BackgroundWorker] a new instance of BackgroundWorker + # + # source://sentry-ruby//lib/sentry/background_worker.rb#18 + def initialize(configuration); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/background_worker.rb#68 + def full?; end + + # @deprecated Use Sentry.logger to retrieve the current logger instead. + # + # source://sentry-ruby//lib/sentry/background_worker.rb#13 + def logger; end + + # Returns the value of attribute max_queue. + # + # source://sentry-ruby//lib/sentry/background_worker.rb#11 + def max_queue; end + + # Returns the value of attribute number_of_threads. + # + # source://sentry-ruby//lib/sentry/background_worker.rb#11 + def number_of_threads; end + + # if you want to monkey-patch this method, please override `_perform` instead + # + # source://sentry-ruby//lib/sentry/background_worker.rb#53 + def perform(&block); end + + # source://sentry-ruby//lib/sentry/background_worker.rb#63 + def shutdown; end + + # Returns the value of attribute shutdown_timeout. + # + # source://sentry-ruby//lib/sentry/background_worker.rb#14 + def shutdown_timeout; end + + # Sets the attribute shutdown_timeout + # + # @param value the value to set the attribute shutdown_timeout to. + # + # source://sentry-ruby//lib/sentry/background_worker.rb#14 + def shutdown_timeout=(_arg0); end + + private + + # source://sentry-ruby//lib/sentry/background_worker.rb#75 + def _perform(&block); end +end + +# source://sentry-ruby//lib/sentry/background_worker.rb#16 +Sentry::BackgroundWorker::DEFAULT_MAX_QUEUE = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/backpressure_monitor.rb#4 +class Sentry::BackpressureMonitor < ::Sentry::ThreadedPeriodicWorker + # @return [BackpressureMonitor] a new instance of BackpressureMonitor + # + # source://sentry-ruby//lib/sentry/backpressure_monitor.rb#8 + def initialize(configuration, client, interval: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/backpressure_monitor.rb#31 + def check_health; end + + # source://sentry-ruby//lib/sentry/backpressure_monitor.rb#21 + def downsample_factor; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/backpressure_monitor.rb#16 + def healthy?; end + + # source://sentry-ruby//lib/sentry/backpressure_monitor.rb#26 + def run; end + + # source://sentry-ruby//lib/sentry/backpressure_monitor.rb#35 + def set_downsample_factor; end +end + +# source://sentry-ruby//lib/sentry/backpressure_monitor.rb#5 +Sentry::BackpressureMonitor::DEFAULT_INTERVAL = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/backpressure_monitor.rb#6 +Sentry::BackpressureMonitor::MAX_DOWNSAMPLE_FACTOR = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://sentry-ruby//lib/sentry/backtrace.rb#7 +class Sentry::Backtrace + # @api private + # @return [Backtrace] a new instance of Backtrace + # + # source://sentry-ruby//lib/sentry/backtrace.rb#104 + def initialize(lines); end + + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#120 + def ==(other); end + + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#108 + def inspect; end + + # holder for an Array of Backtrace::Line instances + # + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#86 + def lines; end + + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#112 + def to_s; end + + class << self + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#88 + def parse(backtrace, project_root, app_dirs_pattern, &backtrace_cleanup_callback); end + end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/backtrace.rb#83 +Sentry::Backtrace::APP_DIRS_PATTERN = T.let(T.unsafe(nil), Regexp) + +# Handles backtrace parsing line by line +# +# @api private +# +# source://sentry-ruby//lib/sentry/backtrace.rb#9 +class Sentry::Backtrace::Line + # @api private + # @return [Line] a new instance of Line + # + # source://sentry-ruby//lib/sentry/backtrace.rb#51 + def initialize(file, number, method, module_name, in_app_pattern); end + + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#74 + def ==(other); end + + # The file portion of the line (such as app/models/user.rb) + # + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#22 + def file; end + + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#59 + def in_app; end + + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#33 + def in_app_pattern; end + + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#78 + def inspect; end + + # The method of the line (such as index) + # + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#28 + def method; end + + # The module name (JRuby) + # + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#31 + def module_name; end + + # The line number portion of the line + # + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#25 + def number; end + + # Reconstructs the line in a readable fashion + # + # @api private + # + # source://sentry-ruby//lib/sentry/backtrace.rb#70 + def to_s; end + + class << self + # Parses a single line of a given backtrace + # + # @api private + # @param unparsed_line [String] The raw line from +caller+ or some backtrace + # @return [Line] The parsed backtrace line + # + # source://sentry-ruby//lib/sentry/backtrace.rb#38 + def parse(unparsed_line, in_app_pattern = T.unsafe(nil)); end + end +end + +# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:170) +# +# @api private +# +# source://sentry-ruby//lib/sentry/backtrace.rb#19 +Sentry::Backtrace::Line::JAVA_INPUT_FORMAT = T.let(T.unsafe(nil), Regexp) + +# @api private +# +# source://sentry-ruby//lib/sentry/backtrace.rb#10 +Sentry::Backtrace::Line::RB_EXTENSION = T.let(T.unsafe(nil), String) + +# regexp (optional leading X: on windows, or JRuby9000 class-prefix) +# +# @api private +# +# source://sentry-ruby//lib/sentry/backtrace.rb#12 +Sentry::Backtrace::Line::RUBY_INPUT_FORMAT = T.let(T.unsafe(nil), Regexp) + +# A {https://www.w3.org/TR/baggage W3C Baggage Header} implementation. +# +# source://sentry-ruby//lib/sentry/baggage.rb#7 +class Sentry::Baggage + # @return [Baggage] a new instance of Baggage + # + # source://sentry-ruby//lib/sentry/baggage.rb#17 + def initialize(items, mutable: T.unsafe(nil)); end + + # A {https://develop.sentry.dev/sdk/performance/dynamic-sampling-context/#envelope-header Dynamic Sampling Context} + # hash to be used in the trace envelope header. + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/baggage.rb#59 + def dynamic_sampling_context; end + + # Make the Baggage immutable. + # + # @return [void] + # + # source://sentry-ruby//lib/sentry/baggage.rb#52 + def freeze!; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/baggage.rb#12 + def items; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/baggage.rb#15 + def mutable; end + + # Serialize the Baggage object back to a string. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/baggage.rb#65 + def serialize; end + + class << self + # Creates a Baggage object from an incoming W3C Baggage header string. + # + # Sentry items are identified with the 'sentry-' prefix and stored in a hash. + # The presence of a Sentry item makes the baggage object immutable. + # + # @param header [String] The incoming Baggage header string. + # @return [Baggage, nil] + # + # source://sentry-ruby//lib/sentry/baggage.rb#29 + def from_incoming_header(header); end + end +end + +# source://sentry-ruby//lib/sentry/baggage.rb#8 +Sentry::Baggage::SENTRY_PREFIX = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/baggage.rb#9 +Sentry::Baggage::SENTRY_PREFIX_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://sentry-ruby//lib/sentry/breadcrumb.rb#4 +class Sentry::Breadcrumb + # @param category [String, nil] + # @param data [Hash, nil] + # @param message [String, nil] + # @param timestamp [Time, Integer, nil] + # @param level [String, nil] + # @param type [String, nil] + # @return [Breadcrumb] a new instance of Breadcrumb + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#26 + def initialize(category: T.unsafe(nil), data: T.unsafe(nil), message: T.unsafe(nil), timestamp: T.unsafe(nil), level: T.unsafe(nil), type: T.unsafe(nil)); end + + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#8 + def category; end + + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#8 + def category=(_arg0); end + + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#10 + def data; end + + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#10 + def data=(_arg0); end + + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#12 + def level; end + + # @param level [String] + # @return [void] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#55 + def level=(level); end + + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#18 + def message; end + + # @param message [String] + # @return [void] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#49 + def message=(message); end + + # @return [Time, Integer, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#14 + def timestamp; end + + # @return [Time, Integer, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#14 + def timestamp=(_arg0); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#36 + def to_hash; end + + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#16 + def type; end + + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb.rb#16 + def type=(_arg0); end + + private + + # source://sentry-ruby//lib/sentry/breadcrumb.rb#61 + def serialized_data; end +end + +# source://sentry-ruby//lib/sentry/breadcrumb.rb#5 +Sentry::Breadcrumb::DATA_SERIALIZATION_ERROR_MESSAGE = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#6 +class Sentry::BreadcrumbBuffer + include ::Enumerable + + # @param size [Integer, nil] If it's not provided, it'll fallback to DEFAULT_SIZE + # @return [BreadcrumbBuffer] a new instance of BreadcrumbBuffer + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#14 + def initialize(size = T.unsafe(nil)); end + + # @return [Array] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#11 + def buffer; end + + # @return [Array] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#11 + def buffer=(_arg0); end + + # @return [BreadcrumbBuffer] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#58 + def dup; end + + # Iterates through all breadcrumbs. + # + # @param block [Proc] + # @return [Array] + # @yieldparam crumb [Breadcrumb] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#41 + def each(&block); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#46 + def empty?; end + + # @return [Array] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#27 + def members; end + + # Returns the last breadcrumb stored in the buffer. If the buffer it's empty, it returns nil. + # + # @return [Breadcrumb, nil] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#33 + def peek; end + + # @param crumb [Breadcrumb] + # @return [void] + # @yield [crumb] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#20 + def record(crumb); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#51 + def to_hash; end +end + +# source://sentry-ruby//lib/sentry/breadcrumb_buffer.rb#7 +Sentry::BreadcrumbBuffer::DEFAULT_SIZE = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry-ruby.rb#42 +Sentry::CAPTURED_SIGNATURE = T.let(T.unsafe(nil), Symbol) + +# source://sentry-ruby//lib/sentry/check_in_event.rb#7 +class Sentry::CheckInEvent < ::Sentry::Event + # @return [CheckInEvent] a new instance of CheckInEvent + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#32 + def initialize(slug:, status:, duration: T.unsafe(nil), monitor_config: T.unsafe(nil), check_in_id: T.unsafe(nil), **options); end + + # uuid to identify this check-in. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#12 + def check_in_id; end + + # uuid to identify this check-in. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#12 + def check_in_id=(_arg0); end + + # Duration of this check since it has started in seconds. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#20 + def duration; end + + # Duration of this check since it has started in seconds. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#20 + def duration=(_arg0); end + + # Monitor configuration to support upserts. + # + # @return [Cron::MonitorConfig, nil] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#24 + def monitor_config; end + + # Monitor configuration to support upserts. + # + # @return [Cron::MonitorConfig, nil] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#24 + def monitor_config=(_arg0); end + + # Identifier of the monitor for this check-in. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#16 + def monitor_slug; end + + # Identifier of the monitor for this check-in. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#16 + def monitor_slug=(_arg0); end + + # Status of this check-in. + # + # @return [Symbol] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#28 + def status; end + + # Status of this check-in. + # + # @return [Symbol] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#28 + def status=(_arg0); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/check_in_event.rb#50 + def to_hash; end +end + +# source://sentry-ruby//lib/sentry/check_in_event.rb#8 +Sentry::CheckInEvent::TYPE = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/check_in_event.rb#30 +Sentry::CheckInEvent::VALID_STATUSES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/client.rb#6 +class Sentry::Client + include ::Sentry::LoggingHelper + + # @param configuration [Configuration] + # @return [Client] a new instance of Client + # + # source://sentry-ruby//lib/sentry/client.rb#24 + def initialize(configuration); end + + # Capture an envelope directly. + # + # @param envelope [Envelope] the envelope to be captured. + # @return [void] + # + # source://sentry-ruby//lib/sentry/client.rb#94 + def capture_envelope(envelope); end + + # Applies the given scope's data to the event and sends it to Sentry. + # + # @param event [Event] the event to be sent. + # @param scope [Scope] the scope with contextual data that'll be applied to the event before it's sent. + # @param hint [Hash] the hint data that'll be passed to `before_send` callback and the scope's event processors. + # @return [Event, nil] + # + # source://sentry-ruby//lib/sentry/client.rb#48 + def capture_event(event, scope, hint = T.unsafe(nil)); end + + # Returns the value of attribute configuration. + # + # source://sentry-ruby//lib/sentry/client.rb#18 + def configuration; end + + # Initializes a CheckInEvent object with the given options. + # + # @param slug [String] identifier of this monitor + # @param status [Symbol] status of this check-in, one of {CheckInEvent::VALID_STATUSES} + # @param hint [Hash] the hint data that'll be passed to `before_send` callback and the scope's event processors. + # @param duration [Integer, nil] seconds elapsed since this monitor started + # @param monitor_config [Cron::MonitorConfig, nil] configuration for this monitor + # @param check_in_id [String, nil] for updating the status of an existing monitor + # @return [Event] + # + # source://sentry-ruby//lib/sentry/client.rb#149 + def event_from_check_in(slug, status, hint = T.unsafe(nil), duration: T.unsafe(nil), monitor_config: T.unsafe(nil), check_in_id: T.unsafe(nil)); end + + # Initializes an Event object with the given exception. Returns `nil` if the exception's class is excluded from reporting. + # + # @param exception [Exception] the exception to be reported. + # @param hint [Hash] the hint data that'll be passed to `before_send` callback and the scope's event processors. + # @return [Event, nil] + # + # source://sentry-ruby//lib/sentry/client.rb#109 + def event_from_exception(exception, hint = T.unsafe(nil)); end + + # Initializes an Event object with the given message. + # + # @param message [String] the message to be reported. + # @param hint [Hash] the hint data that'll be passed to `before_send` callback and the scope's event processors. + # @return [Event] + # + # source://sentry-ruby//lib/sentry/client.rb#129 + def event_from_message(message, hint = T.unsafe(nil), backtrace: T.unsafe(nil)); end + + # Initializes an Event object with the given Transaction object. + # + # @param transaction [Transaction] the transaction to be recorded. + # @return [TransactionEvent] + # + # source://sentry-ruby//lib/sentry/client.rb#173 + def event_from_transaction(transaction); end + + # Flush pending events to Sentry. + # + # @return [void] + # + # source://sentry-ruby//lib/sentry/client.rb#100 + def flush; end + + # Generates a W3C Baggage header for distributed tracing from the given Span. + # Returns `nil` if `config.propagate_traces` is `false`. + # + # @deprecated Use Sentry.get_baggage instead. + # @param span [Span] the span to generate trace from. + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/client.rb#255 + def generate_baggage(span); end + + # Generates a Sentry trace for distribted tracing from the given Span. + # Returns `nil` if `config.propagate_traces` is `false`. + # + # @deprecated use Sentry.get_traceparent instead. + # @param span [Span] the span to generate trace from. + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/client.rb#241 + def generate_sentry_trace(span); end + + # @deprecated Use Sentry.logger to retrieve the current logger instead. + # + # source://sentry-ruby//lib/sentry/client.rb#21 + def logger; end + + # Send an envelope directly to Sentry. + # + # @param envelope [Envelope] the envelope to be sent. + # @return [void] + # + # source://sentry-ruby//lib/sentry/client.rb#222 + def send_envelope(envelope); end + + # source://sentry-ruby//lib/sentry/client.rb#178 + def send_event(event, hint = T.unsafe(nil)); end + + # The Transport object that'll send events for the client. + # + # @return [SpotlightTransport, nil] + # + # source://sentry-ruby//lib/sentry/client.rb#15 + def spotlight_transport; end + + # The Transport object that'll send events for the client. + # + # @return [Transport] + # + # source://sentry-ruby//lib/sentry/client.rb#11 + def transport; end + + private + + # source://sentry-ruby//lib/sentry/client.rb#275 + def dispatch_async_event(async_block, event, hint); end + + # source://sentry-ruby//lib/sentry/client.rb#269 + def dispatch_background_event(event, hint); end +end + +# source://sentry-ruby//lib/sentry/configuration.rb#16 +class Sentry::Configuration + include ::Sentry::CustomInspection + include ::Sentry::LoggingHelper + include ::Sentry::ArgumentCheckingHelper + + # @return [Configuration] a new instance of Configuration + # + # source://sentry-ruby//lib/sentry/configuration.rb#351 + def initialize; end + + # Directories to be recognized as part of your app. e.g. if you + # have an `engines` dir at the root of your project, you may want + # to set this to something like /(app|config|engines|lib)/ + # + # @return [Regexp, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#26 + def app_dirs_pattern; end + + # Directories to be recognized as part of your app. e.g. if you + # have an `engines` dir at the root of your project, you may want + # to set this to something like /(app|config|engines|lib)/ + # + # @return [Regexp, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#26 + def app_dirs_pattern=(_arg0); end + + # Provide an object that responds to `call` to send events asynchronously. + # E.g.: lambda { |event| Thread.new { Sentry.send_event(event) } } + # + # @deprecated It will be removed in the next major release. Please read https://github.com/getsentry/sentry-ruby/issues/1522 for more information + # @return [Proc, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#33 + def async; end + + # source://sentry-ruby//lib/sentry/configuration.rb#412 + def async=(value); end + + # Track sessions in request/response cycles automatically + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#269 + def auto_session_tracking; end + + # Track sessions in request/response cycles automatically + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#269 + def auto_session_tracking=(_arg0); end + + # The maximum queue size for the background worker. + # Jobs will be rejected above this limit. + # + # Default is {BackgroundWorker::DEFAULT_MAX_QUEUE}. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/configuration.rb#50 + def background_worker_max_queue; end + + # The maximum queue size for the background worker. + # Jobs will be rejected above this limit. + # + # Default is {BackgroundWorker::DEFAULT_MAX_QUEUE}. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/configuration.rb#50 + def background_worker_max_queue=(_arg0); end + + # to send events in a non-blocking way, sentry-ruby has its own background worker + # by default, the worker holds a thread pool that has [the number of processors] threads + # but you can configure it with this configuration option + # E.g.: config.background_worker_threads = 5 + # + # if you want to send events synchronously, set the value to 0 + # E.g.: config.background_worker_threads = 0 + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/configuration.rb#43 + def background_worker_threads; end + + # to send events in a non-blocking way, sentry-ruby has its own background worker + # by default, the worker holds a thread pool that has [the number of processors] threads + # but you can configure it with this configuration option + # E.g.: config.background_worker_threads = 5 + # + # if you want to send events synchronously, set the value to 0 + # E.g.: config.background_worker_threads = 0 + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/configuration.rb#43 + def background_worker_threads=(_arg0); end + + # a proc/lambda that takes an array of stack traces + # it'll be used to silence (reduce) backtrace of the exception + # + # @example + # config.backtrace_cleanup_callback = lambda do |backtrace| + # Rails.backtrace_cleaner.clean(backtrace) + # end + # @return [Proc, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#61 + def backtrace_cleanup_callback; end + + # a proc/lambda that takes an array of stack traces + # it'll be used to silence (reduce) backtrace of the exception + # + # @example + # config.backtrace_cleanup_callback = lambda do |backtrace| + # Rails.backtrace_cleaner.clean(backtrace) + # end + # @return [Proc, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#61 + def backtrace_cleanup_callback=(_arg0); end + + # Optional Proc, called before adding the breadcrumb to the current scope + # + # @example + # config.before = lambda do |breadcrumb, hint| + # breadcrumb.message = 'a' + # breadcrumb + # end + # @return [Proc] + # + # source://sentry-ruby//lib/sentry/configuration.rb#70 + def before_breadcrumb; end + + # source://sentry-ruby//lib/sentry/configuration.rb#453 + def before_breadcrumb=(value); end + + # Optional Proc, called before sending an event to the server + # + # @example + # config.before_send = lambda do |event, hint| + # # skip ZeroDivisionError exceptions + # # note: hint[:exception] would be a String if you use async callback + # if hint[:exception].is_a?(ZeroDivisionError) + # nil + # else + # event + # end + # end + # @return [Proc] + # + # source://sentry-ruby//lib/sentry/configuration.rb#84 + def before_send; end + + # source://sentry-ruby//lib/sentry/configuration.rb#441 + def before_send=(value); end + + # Optional Proc, called before sending an event to the server + # + # @example + # config.before_send_transaction = lambda do |event, hint| + # # skip unimportant transactions or strip sensitive data + # if event.transaction == "/healthcheck/route" + # nil + # else + # event + # end + # end + # @return [Proc] + # + # source://sentry-ruby//lib/sentry/configuration.rb#97 + def before_send_transaction; end + + # source://sentry-ruby//lib/sentry/configuration.rb#447 + def before_send_transaction=(value); end + + # An array of breadcrumbs loggers to be used. Available options are: + # - :sentry_logger + # - :http_logger + # - :redis_logger + # + # And if you also use sentry-rails: + # - :active_support_logger + # - :monotonic_active_support_logger + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#109 + def breadcrumbs_logger; end + + # source://sentry-ruby//lib/sentry/configuration.rb#428 + def breadcrumbs_logger=(logger); end + + # Whether to capture local variables from the raised exception's frame. Default is false. + # + # @deprecated Use {#include_local_variables} instead. + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#152 + def capture_exception_frame_locals; end + + # @deprecated Use {#include_local_variables=} instead. + # + # source://sentry-ruby//lib/sentry/configuration.rb#166 + def capture_exception_frame_locals=(value); end + + # Number of lines of code context to capture, or nil for none + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#117 + def context_lines; end + + # Number of lines of code context to capture, or nil for none + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#117 + def context_lines=(_arg0); end + + # Cron related configuration. + # + # @return [Cron::Configuration] + # + # source://sentry-ruby//lib/sentry/configuration.rb#237 + def cron; end + + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#542 + def csp_report_uri; end + + # Whether the SDK should run in the debugging mode. Default is false. + # If set to true, SDK errors will be logged with backtrace + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#126 + def debug; end + + # Whether the SDK should run in the debugging mode. Default is false. + # If set to true, SDK errors will be logged with backtrace + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#126 + def debug=(_arg0); end + + # @api private + # + # source://sentry-ruby//lib/sentry/configuration.rb#563 + def detect_release; end + + # the dsn value, whether it's set via `config.dsn=` or `ENV["SENTRY_DSN"]` + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#130 + def dsn; end + + # source://sentry-ruby//lib/sentry/configuration.rb#400 + def dsn=(value); end + + # Whether to downsample transactions automatically because of backpressure. + # Starts a new monitor thread to check health of the SDK every 10 seconds. + # Default is false + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#275 + def enable_backpressure_handling; end + + # Whether to downsample transactions automatically because of backpressure. + # Starts a new monitor thread to check health of the SDK every 10 seconds. + # Default is false + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#275 + def enable_backpressure_handling=(_arg0); end + + # Easier way to use performance tracing + # If set to true, will set traces_sample_rate to 1.0 + # + # @return [Boolean, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#260 + def enable_tracing; end + + # source://sentry-ruby//lib/sentry/configuration.rb#467 + def enable_tracing=(enable_tracing); end + + # Whitelist of enabled_environments that will send notifications to Sentry. Array of Strings. + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#134 + def enabled_environments; end + + # Whitelist of enabled_environments that will send notifications to Sentry. Array of Strings. + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#134 + def enabled_environments=(_arg0); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#520 + def enabled_in_current_env?; end + + # Array of patches to apply. + # Default is {DEFAULT_PATCHES} + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#295 + def enabled_patches; end + + # Array of patches to apply. + # Default is {DEFAULT_PATCHES} + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#295 + def enabled_patches=(_arg0); end + + # RACK_ENV by default. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#121 + def environment; end + + # source://sentry-ruby//lib/sentry/configuration.rb#459 + def environment=(environment); end + + # @api private + # + # source://sentry-ruby//lib/sentry/configuration.rb#576 + def error_messages; end + + # these are not config options + # + # source://sentry-ruby//lib/sentry/configuration.rb#299 + def errors; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#507 + def exception_class_allowed?(exc); end + + # Logger 'progname's to exclude from breadcrumbs + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#138 + def exclude_loggers; end + + # Logger 'progname's to exclude from breadcrumbs + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#138 + def exclude_loggers=(_arg0); end + + # Array of exception classes that should never be sent. See IGNORE_DEFAULT. + # You should probably append to this rather than overwrite it. + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#143 + def excluded_exceptions; end + + # Array of exception classes that should never be sent. See IGNORE_DEFAULT. + # You should probably append to this rather than overwrite it. + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#143 + def excluded_exceptions=(_arg0); end + + # these are not config options + # + # source://sentry-ruby//lib/sentry/configuration.rb#299 + def gem_specs; end + + # Whether to capture local variables from the raised exception's frame. Default is false. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#152 + def include_local_variables; end + + # Whether to capture local variables from the raised exception's frame. Default is false. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#152 + def include_local_variables=(_arg0); end + + # Boolean to check nested exceptions when deciding if to exclude. Defaults to true + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion; end + + # Boolean to check nested exceptions when deciding if to exclude. Defaults to true + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion=(_arg0); end + + # Boolean to check nested exceptions when deciding if to exclude. Defaults to true + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion?; end + + # The instrumenter to use, :sentry or :otel + # + # @return [Symbol] + # + # source://sentry-ruby//lib/sentry/configuration.rb#284 + def instrumenter; end + + # source://sentry-ruby//lib/sentry/configuration.rb#463 + def instrumenter=(instrumenter); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#472 + def is_numeric_or_nil?(value); end + + # You may provide your own LineCache for matching paths with source files. + # This may be useful if you need to get source code from places other than the disk. + # + # @return [LineCache] + # @see LineCache + # + # source://sentry-ruby//lib/sentry/configuration.rb#178 + def linecache; end + + # You may provide your own LineCache for matching paths with source files. + # This may be useful if you need to get source code from places other than the disk. + # + # @return [LineCache] + # @see LineCache + # + # source://sentry-ruby//lib/sentry/configuration.rb#178 + def linecache=(_arg0); end + + # Logger used by Sentry. In Rails, this is the Rails logger, otherwise + # Sentry provides its own Sentry::Logger. + # + # @return [Logger] + # + # source://sentry-ruby//lib/sentry/configuration.rb#183 + def logger; end + + # Logger used by Sentry. In Rails, this is the Rails logger, otherwise + # Sentry provides its own Sentry::Logger. + # + # @return [Logger] + # + # source://sentry-ruby//lib/sentry/configuration.rb#183 + def logger=(_arg0); end + + # Max number of breadcrumbs a breadcrumb buffer can hold + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/configuration.rb#113 + def max_breadcrumbs; end + + # Max number of breadcrumbs a breadcrumb buffer can hold + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/configuration.rb#113 + def max_breadcrumbs=(_arg0); end + + # Metrics related configuration. + # + # @return [Metrics::Configuration] + # + # source://sentry-ruby//lib/sentry/configuration.rb#241 + def metrics; end + + # Take a float between 0.0 and 1.0 as the sample rate for capturing profiles. + # Note that this rate is relative to traces_sample_rate / traces_sampler, + # i.e. the profile is sampled by this rate after the transaction is sampled. + # + # @return [Float, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#290 + def profiles_sample_rate; end + + # @raise [ArgumentError] + # + # source://sentry-ruby//lib/sentry/configuration.rb#481 + def profiles_sample_rate=(profiles_sample_rate); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#535 + def profiling_enabled?; end + + # Project directory root for in_app detection. Could be Rails root, etc. + # Set automatically for Rails. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#188 + def project_root; end + + # Project directory root for in_app detection. Could be Rails root, etc. + # Set automatically for Rails. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#188 + def project_root=(_arg0); end + + # Insert sentry-trace to outgoing requests' headers + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#192 + def propagate_traces; end + + # Insert sentry-trace to outgoing requests' headers + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#192 + def propagate_traces=(_arg0); end + + # Array of rack env parameters to be included in the event sent to sentry. + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#196 + def rack_env_whitelist; end + + # Array of rack env parameters to be included in the event sent to sentry. + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#196 + def rack_env_whitelist=(_arg0); end + + # source://sentry-rails/5.19.0/lib/sentry/rails/configuration.rb#8 + def rails; end + + # Release tag to be passed with every event sent to Sentry. + # We automatically try to set this to a git SHA or Capistrano release. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#201 + def release; end + + # source://sentry-ruby//lib/sentry/configuration.rb#406 + def release=(value); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#497 + def sample_allowed?; end + + # The sampling factor to apply to events. A value of 0.0 will not send + # any events, and a value of 1.0 will send 100% of events. + # + # @return [Float] + # + # source://sentry-ruby//lib/sentry/configuration.rb#206 + def sample_rate; end + + # The sampling factor to apply to events. A value of 0.0 will not send + # any events, and a value of 1.0 will send 100% of events. + # + # @return [Float] + # + # source://sentry-ruby//lib/sentry/configuration.rb#206 + def sample_rate=(_arg0); end + + # Send diagnostic client reports about dropped events, true by default + # tries to attach to an existing envelope max once every 30s + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#265 + def send_client_reports; end + + # Send diagnostic client reports about dropped events, true by default + # tries to attach to an existing envelope max once every 30s + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#265 + def send_client_reports=(_arg0); end + + # When send_default_pii's value is false (default), sensitive information like + # - user ip + # - user cookie + # - request body + # - query string + # will not be sent to Sentry. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#219 + def send_default_pii; end + + # When send_default_pii's value is false (default), sensitive information like + # - user ip + # - user cookie + # - request body + # - query string + # will not be sent to Sentry. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#219 + def send_default_pii=(_arg0); end + + # Include module versions in reports - boolean. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#210 + def send_modules; end + + # Include module versions in reports - boolean. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#210 + def send_modules=(_arg0); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#487 + def sending_allowed?; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#491 + def sending_to_dsn_allowed?; end + + # source://sentry-ruby//lib/sentry/configuration.rb#400 + def server=(value); end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#229 + def server_name; end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#229 + def server_name=(_arg0); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#503 + def session_tracking?; end + + # source://sentry-sidekiq/5.19.0/lib/sentry/sidekiq/configuration.rb#3 + def sidekiq; end + + # Allow to skip Sentry emails within rake tasks + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#223 + def skip_rake_integration; end + + # Allow to skip Sentry emails within rake tasks + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#223 + def skip_rake_integration=(_arg0); end + + # Whether to capture events and traces into Spotlight. Default is false. + # If you set this to true, Sentry will send events and traces to the local + # Sidecar proxy at http://localhost:8969/stream. + # If you want to use a different Sidecar proxy address, set this to String + # with the proxy URL. + # + # @return [Boolean, String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#160 + def spotlight; end + + # Whether to capture events and traces into Spotlight. Default is false. + # If you set this to true, Sentry will send events and traces to the local + # Sidecar proxy at http://localhost:8969/stream. + # If you want to use a different Sidecar proxy address, set this to String + # with the proxy URL. + # + # @return [Boolean, String] + # + # source://sentry-ruby//lib/sentry/configuration.rb#160 + def spotlight=(_arg0); end + + # @api private + # + # source://sentry-ruby//lib/sentry/configuration.rb#552 + def stacktrace_builder; end + + # Allowlist of outgoing request targets to which sentry-trace and baggage headers are attached. + # Default is all (/.*/) + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#280 + def trace_propagation_targets; end + + # Allowlist of outgoing request targets to which sentry-trace and baggage headers are attached. + # Default is all (/.*/) + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/configuration.rb#280 + def trace_propagation_targets=(_arg0); end + + # Take a float between 0.0 and 1.0 as the sample rate for tracing events (transactions). + # + # @return [Float, nil] + # + # source://sentry-ruby//lib/sentry/configuration.rb#245 + def traces_sample_rate; end + + # @raise [ArgumentError] + # + # source://sentry-ruby//lib/sentry/configuration.rb#476 + def traces_sample_rate=(traces_sample_rate); end + + # Take a Proc that controls the sample rate for every tracing event, e.g. + # + # @example + # config.traces_sampler = lambda do |tracing_context| + # # tracing_context[:transaction_context] contains the information about the transaction + # # tracing_context[:parent_sampled] contains the transaction's parent's sample decision + # true # return value can be a boolean or a float between 0.0 and 1.0 + # end + # @return [Proc] + # + # source://sentry-ruby//lib/sentry/configuration.rb#255 + def traces_sampler; end + + # Take a Proc that controls the sample rate for every tracing event, e.g. + # + # @example + # config.traces_sampler = lambda do |tracing_context| + # # tracing_context[:transaction_context] contains the information about the transaction + # # tracing_context[:parent_sampled] contains the transaction's parent's sample decision + # true # return value can be a boolean or a float between 0.0 and 1.0 + # end + # @return [Proc] + # + # source://sentry-ruby//lib/sentry/configuration.rb#255 + def traces_sampler=(_arg0); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#529 + def tracing_enabled?; end + + # Transport related configuration. + # + # @return [Transport::Configuration] + # + # source://sentry-ruby//lib/sentry/configuration.rb#233 + def transport; end + + # IP ranges for trusted proxies that will be skipped when calculating IP address. + # + # source://sentry-ruby//lib/sentry/configuration.rb#226 + def trusted_proxies; end + + # IP ranges for trusted proxies that will be skipped when calculating IP address. + # + # source://sentry-ruby//lib/sentry/configuration.rb#226 + def trusted_proxies=(_arg0); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#524 + def valid_sample_rate?(sample_rate); end + + private + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#618 + def capture_in_environment?; end + + # source://sentry-ruby//lib/sentry/configuration.rb#634 + def environment_from_env; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#589 + def excluded_exception?(incoming_exception); end + + # source://sentry-ruby//lib/sentry/configuration.rb#595 + def excluded_exception_classes; end + + # source://sentry-ruby//lib/sentry/configuration.rb#599 + def get_exception_class(x); end + + # source://sentry-ruby//lib/sentry/configuration.rb#583 + def init_dsn(dsn_string); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#603 + def matches_exception?(excluded_exception_class, incoming_exception); end + + # source://sentry-ruby//lib/sentry/configuration.rb#658 + def processor_count; end + + # source://sentry-ruby//lib/sentry/configuration.rb#652 + def run_post_initialization_callbacks; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#648 + def running_on_heroku?; end + + # source://sentry-ruby//lib/sentry/configuration.rb#611 + def safe_const_get(x); end + + # source://sentry-ruby//lib/sentry/configuration.rb#638 + def server_name_from_env; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/configuration.rb#625 + def valid?; end + + class << self + # allow extensions to add their hooks to the Configuration class + # + # source://sentry-ruby//lib/sentry/configuration.rb#346 + def add_post_initialization_callback(&block); end + + # Post initialization callbacks are called at the end of initialization process + # allowing extending the configuration of sentry-ruby by multiple extensions + # + # source://sentry-ruby//lib/sentry/configuration.rb#341 + def post_initialization_callbacks; end + end +end + +# source://sentry-ruby//lib/sentry/configuration.rb#336 +Sentry::Configuration::DEFAULT_PATCHES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/configuration.rb#325 +Sentry::Configuration::HEROKU_DYNO_METADATA_MESSAGE = T.let(T.unsafe(nil), String) + +# Most of these errors generate 4XX responses. In general, Sentry clients +# only automatically report 5xx responses. +# +# source://sentry-ruby//lib/sentry/configuration.rb#312 +Sentry::Configuration::IGNORE_DEFAULT = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/configuration.rb#332 +Sentry::Configuration::INSTRUMENTERS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/configuration.rb#328 +Sentry::Configuration::LOG_PREFIX = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/configuration.rb#329 +Sentry::Configuration::MODULE_SEPARATOR = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/configuration.rb#334 +Sentry::Configuration::PROPAGATION_TARGETS_MATCH_ALL = T.let(T.unsafe(nil), Regexp) + +# These exceptions could enter Puma's `lowlevel_error_handler` callback and the SDK's Puma integration +# But they are mostly considered as noise and should be ignored by default +# Please see https://github.com/getsentry/sentry-ruby/pull/2026 for more information +# +# source://sentry-ruby//lib/sentry/configuration.rb#304 +Sentry::Configuration::PUMA_IGNORE_DEFAULT = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/configuration.rb#319 +Sentry::Configuration::RACK_ENV_WHITELIST_DEFAULT = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/configuration.rb#330 +Sentry::Configuration::SKIP_INSPECTION_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/cron/configuration.rb#4 +module Sentry::Cron; end + +# source://sentry-ruby//lib/sentry/cron/configuration.rb#5 +class Sentry::Cron::Configuration + # How long (in minutes) after the expected checkin time will we wait + # until we consider the checkin to have been missed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/configuration.rb#11 + def default_checkin_margin; end + + # How long (in minutes) after the expected checkin time will we wait + # until we consider the checkin to have been missed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/configuration.rb#11 + def default_checkin_margin=(_arg0); end + + # How long (in minutes) is the checkin allowed to run for in in_progress + # before it is considered failed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/configuration.rb#16 + def default_max_runtime; end + + # How long (in minutes) is the checkin allowed to run for in in_progress + # before it is considered failed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/configuration.rb#16 + def default_max_runtime=(_arg0); end + + # tz database style timezone string + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/cron/configuration.rb#20 + def default_timezone; end + + # tz database style timezone string + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/cron/configuration.rb#20 + def default_timezone=(_arg0); end +end + +# source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#3 +module Sentry::Cron::MonitorCheckIns + mixes_in_class_methods ::Sentry::Cron::MonitorCheckIns::ClassMethods + + class << self + # @private + # + # source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#70 + def included(base); end + end +end + +# source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#43 +module Sentry::Cron::MonitorCheckIns::ClassMethods + # source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#44 + def sentry_monitor_check_ins(slug: T.unsafe(nil), monitor_config: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#65 + def sentry_monitor_config; end + + # source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#58 + def sentry_monitor_slug(name: T.unsafe(nil)); end +end + +# source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#4 +Sentry::Cron::MonitorCheckIns::MAX_SLUG_LENGTH = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#6 +module Sentry::Cron::MonitorCheckIns::Patch + # source://sentry-ruby//lib/sentry/cron/monitor_check_ins.rb#7 + def perform(*args, **opts); end +end + +# source://sentry-ruby//lib/sentry/cron/monitor_config.rb#7 +class Sentry::Cron::MonitorConfig + # @return [MonitorConfig] a new instance of MonitorConfig + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#26 + def initialize(schedule, checkin_margin: T.unsafe(nil), max_runtime: T.unsafe(nil), timezone: T.unsafe(nil)); end + + # How long (in minutes) after the expected checkin time will we wait + # until we consider the checkin to have been missed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#15 + def checkin_margin; end + + # How long (in minutes) after the expected checkin time will we wait + # until we consider the checkin to have been missed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#15 + def checkin_margin=(_arg0); end + + # How long (in minutes) is the checkin allowed to run for in in_progress + # before it is considered failed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#20 + def max_runtime; end + + # How long (in minutes) is the checkin allowed to run for in in_progress + # before it is considered failed. + # + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#20 + def max_runtime=(_arg0); end + + # The monitor schedule configuration + # + # @return [MonitorSchedule::Crontab, MonitorSchedule::Interval] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#10 + def schedule; end + + # The monitor schedule configuration + # + # @return [MonitorSchedule::Crontab, MonitorSchedule::Interval] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#10 + def schedule=(_arg0); end + + # tz database style timezone string + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#24 + def timezone; end + + # tz database style timezone string + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#24 + def timezone=(_arg0); end + + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#43 + def to_hash; end + + class << self + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#33 + def from_crontab(crontab, **options); end + + # source://sentry-ruby//lib/sentry/cron/monitor_config.rb#37 + def from_interval(num, unit, **options); end + end +end + +# source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#5 +module Sentry::Cron::MonitorSchedule; end + +# source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#6 +class Sentry::Cron::MonitorSchedule::Crontab + # @return [Crontab] a new instance of Crontab + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#11 + def initialize(value); end + + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#15 + def to_hash; end + + # A crontab formatted string such as "0 * * * *". + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#9 + def value; end + + # A crontab formatted string such as "0 * * * *". + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#9 + def value=(_arg0); end +end + +# source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#20 +class Sentry::Cron::MonitorSchedule::Interval + # @return [Interval] a new instance of Interval + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#31 + def initialize(value, unit); end + + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#36 + def to_hash; end + + # The unit representing duration of the interval. + # + # @return [Symbol] + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#27 + def unit; end + + # The unit representing duration of the interval. + # + # @return [Symbol] + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#27 + def unit=(_arg0); end + + # The number representing duration of the interval. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#23 + def value; end + + # The number representing duration of the interval. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#23 + def value=(_arg0); end +end + +# source://sentry-ruby//lib/sentry/cron/monitor_schedule.rb#29 +Sentry::Cron::MonitorSchedule::Interval::VALID_UNITS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/utils/custom_inspection.rb#4 +module Sentry::CustomInspection + # source://sentry-ruby//lib/sentry/utils/custom_inspection.rb#5 + def inspect; end +end + +# source://sentry-ruby//lib/sentry/dsn.rb#6 +class Sentry::DSN + # @return [DSN] a new instance of DSN + # + # source://sentry-ruby//lib/sentry/dsn.rb#12 + def initialize(dsn_string); end + + # source://sentry-ruby//lib/sentry/dsn.rb#45 + def csp_report_uri; end + + # source://sentry-ruby//lib/sentry/dsn.rb#49 + def envelope_endpoint; end + + # source://sentry-ruby//lib/sentry/dsn.rb#10 + def host; end + + # source://sentry-ruby//lib/sentry/dsn.rb#10 + def path; end + + # source://sentry-ruby//lib/sentry/dsn.rb#10 + def port; end + + # source://sentry-ruby//lib/sentry/dsn.rb#10 + def project_id; end + + # source://sentry-ruby//lib/sentry/dsn.rb#10 + def public_key; end + + # source://sentry-ruby//lib/sentry/dsn.rb#10 + def scheme; end + + # source://sentry-ruby//lib/sentry/dsn.rb#10 + def secret_key; end + + # source://sentry-ruby//lib/sentry/dsn.rb#39 + def server; end + + # source://sentry-ruby//lib/sentry/dsn.rb#35 + def to_s; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/dsn.rb#31 + def valid?; end +end + +# source://sentry-ruby//lib/sentry/dsn.rb#7 +Sentry::DSN::PORT_MAP = T.let(T.unsafe(nil), Hash) + +# source://sentry-ruby//lib/sentry/dsn.rb#8 +Sentry::DSN::REQUIRED_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#4 +class Sentry::DummyTransport < ::Sentry::Transport + # @return [DummyTransport] a new instance of DummyTransport + # + # source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#7 + def initialize(*_arg0); end + + # Returns the value of attribute envelopes. + # + # source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#5 + def envelopes; end + + # Sets the attribute envelopes + # + # @param value the value to set the attribute envelopes to. + # + # source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#5 + def envelopes=(_arg0); end + + # Returns the value of attribute events. + # + # source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#5 + def events; end + + # Sets the attribute events + # + # @param value the value to set the attribute events to. + # + # source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#5 + def events=(_arg0); end + + # source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#17 + def send_envelope(envelope); end + + # source://sentry-ruby//lib/sentry/transport/dummy_transport.rb#13 + def send_event(event); end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/envelope.rb#5 +class Sentry::Envelope + # @api private + # @return [Envelope] a new instance of Envelope + # + # source://sentry-ruby//lib/sentry/envelope.rb#93 + def initialize(headers = T.unsafe(nil)); end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#98 + def add_item(headers, payload); end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#106 + def event_id; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#91 + def headers; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#91 + def headers=(_arg0); end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#102 + def item_types; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#91 + def items; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#91 + def items=(_arg0); end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/envelope.rb#6 +class Sentry::Envelope::Item + # @api private + # @return [Item] a new instance of Item + # + # source://sentry-ruby//lib/sentry/envelope.rb#12 + def initialize(headers, payload); end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#34 + def data_category; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#10 + def headers; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#10 + def headers=(_arg0); end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#10 + def payload; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#10 + def payload=(_arg0); end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#42 + def serialize; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#58 + def size_breakdown; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#38 + def to_s; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#17 + def type; end + + private + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#74 + def reduce_stacktrace!; end + + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#66 + def remove_breadcrumbs!; end + + class << self + # rate limits and client reports use the data_category rather than envelope item type + # + # @api private + # + # source://sentry-ruby//lib/sentry/envelope.rb#22 + def data_category(type); end + end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/envelope.rb#8 +Sentry::Envelope::Item::MAX_SERIALIZED_PAYLOAD_SIZE = T.let(T.unsafe(nil), Integer) + +# @api private +# +# source://sentry-ruby//lib/sentry/envelope.rb#7 +Sentry::Envelope::Item::STACKTRACE_FRAME_LIMIT_ON_OVERSIZED_PAYLOAD = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/exceptions.rb#4 +class Sentry::Error < ::StandardError; end + +# ErrorEvent represents error or normal message events. +# +# source://sentry-ruby//lib/sentry/error_event.rb#5 +class Sentry::ErrorEvent < ::Sentry::Event + # source://sentry-ruby//lib/sentry/error_event.rb#30 + def add_exception_interface(exception, mechanism:); end + + # source://sentry-ruby//lib/sentry/error_event.rb#21 + def add_threads_interface(backtrace: T.unsafe(nil), **options); end + + # @return [ExceptionInterface] + # + # source://sentry-ruby//lib/sentry/error_event.rb#7 + def exception; end + + # @return [ThreadsInterface] + # + # source://sentry-ruby//lib/sentry/error_event.rb#10 + def threads; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/error_event.rb#13 + def to_hash; end +end + +# This is an abstract class that defines the shared attributes of an event. +# Please don't use it directly. The user-facing classes are its child classes. +# +# source://sentry-ruby//lib/sentry/event.rb#14 +class Sentry::Event + include ::Sentry::CustomInspection + + # @param configuration [Configuration] + # @param integration_meta [Hash, nil] + # @param message [String, nil] + # @return [Event] a new instance of Event + # + # source://sentry-ruby//lib/sentry/event.rb#51 + def initialize(configuration:, integration_meta: T.unsafe(nil), message: T.unsafe(nil)); end + + # @return [Array] + # + # source://sentry-ruby//lib/sentry/event.rb#46 + def attachments; end + + # @return [Array] + # + # source://sentry-ruby//lib/sentry/event.rb#46 + def attachments=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def breadcrumbs; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def breadcrumbs=(_arg0); end + + # @deprecated This method will be removed in v5.0.0. Please just use Sentry.configuration + # @return [Configuration] + # + # source://sentry-ruby//lib/sentry/event.rb#85 + def configuration; end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def contexts; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def contexts=(_arg0); end + + # Dynamic Sampling Context (DSC) that gets attached + # as the trace envelope header in the transport. + # + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/event.rb#43 + def dynamic_sampling_context; end + + # Dynamic Sampling Context (DSC) that gets attached + # as the trace envelope header in the transport. + # + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/event.rb#43 + def dynamic_sampling_context=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def environment; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def environment=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def event_id; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def event_id=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def extra; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def extra=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def fingerprint; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def fingerprint=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def level; end + + # Sets the event's level. + # + # @param level [String, Symbol] + # @return [void] + # + # source://sentry-ruby//lib/sentry/event.rb#99 + def level=(level); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def message; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def message=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def modules; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def modules=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def platform; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def platform=(_arg0); end + + # Sets the event's request environment data with RequestInterface. + # + # @param env [Hash] + # @return [void] + # @see RequestInterface + # + # source://sentry-ruby//lib/sentry/event.rb#107 + def rack_env=(env); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def release; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def release=(_arg0); end + + # @return [RequestInterface] + # + # source://sentry-ruby//lib/sentry/event.rb#38 + def request; end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def sdk; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def sdk=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def server_name; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def server_name=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def tags; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def tags=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def timestamp; end + + # Sets the event's timestamp. + # + # @param time [Time, Float] + # @return [void] + # + # source://sentry-ruby//lib/sentry/event.rb#92 + def timestamp=(time); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/event.rb#120 + def to_hash; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/event.rb#128 + def to_json_compatible; end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def transaction; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def transaction=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def transaction_info; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def transaction_info=(_arg0); end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def type; end + + # source://sentry-ruby//lib/sentry/event.rb#35 + def user; end + + # source://sentry-ruby//lib/sentry/event.rb#34 + def user=(_arg0); end + + private + + # source://sentry-ruby//lib/sentry/event.rb#134 + def add_request_interface(env); end + + # When behind a proxy (or if the user is using a proxy), we can't use + # REMOTE_ADDR to determine the Event IP, and must use other headers instead. + # + # source://sentry-ruby//lib/sentry/event.rb#148 + def calculate_real_ip_from_rack(env); end + + # source://sentry-ruby//lib/sentry/event.rb#138 + def serialize_attributes; end +end + +# source://sentry-ruby//lib/sentry/event.rb#28 +Sentry::Event::MAX_MESSAGE_SIZE_IN_BYTES = T.let(T.unsafe(nil), Integer) + +# These are readable attributes. +# +# source://sentry-ruby//lib/sentry/event.rb#17 +Sentry::Event::SERIALIZEABLE_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/event.rb#30 +Sentry::Event::SKIP_INSPECTION_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/event.rb#15 +Sentry::Event::TYPE = T.let(T.unsafe(nil), String) + +# These are writable attributes. +# +# source://sentry-ruby//lib/sentry/event.rb#26 +Sentry::Event::WRITER_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/interfaces/exception.rb#6 +class Sentry::ExceptionInterface < ::Sentry::Interface + # @param exceptions [Array] + # @return [ExceptionInterface] a new instance of ExceptionInterface + # + # source://sentry-ruby//lib/sentry/interfaces/exception.rb#11 + def initialize(exceptions:); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/exception.rb#16 + def to_hash; end + + # @return [] + # + # source://sentry-ruby//lib/sentry/interfaces/exception.rb#8 + def values; end + + class << self + # Builds ExceptionInterface with given exception and stacktrace_builder. + # + # @param exception [Exception] + # @param stacktrace_builder [StacktraceBuilder] + # @param mechanism [Mechanism] + # @return [ExceptionInterface] + # @see SingleExceptionInterface#build_with_stacktrace + # @see SingleExceptionInterface#initialize + # + # source://sentry-ruby//lib/sentry/interfaces/exception.rb#29 + def build(exception:, stacktrace_builder:, mechanism:); end + end +end + +# source://sentry-ruby//lib/sentry/exceptions.rb#7 +class Sentry::ExternalError < ::Sentry::Error; end + +# source://sentry-ruby//lib/sentry/faraday.rb#4 +module Sentry::Faraday; end + +# source://sentry-ruby//lib/sentry/faraday.rb#7 +module Sentry::Faraday::Connection + # Since there's no way to preconfigure Faraday connections and add our instrumentation + # by default, we need to extend the connection constructor and do it there + # + # @see https://lostisland.github.io/faraday/#/customization/index?id=configuration + # + # source://sentry-ruby//lib/sentry/faraday.rb#12 + def initialize(url = T.unsafe(nil), options = T.unsafe(nil)); end +end + +# source://sentry-ruby//lib/sentry/faraday.rb#25 +class Sentry::Faraday::Instrumenter + include ::Sentry::Utils::HttpTracing + + # source://sentry-ruby//lib/sentry/faraday.rb#31 + def instrument(op_name, env, &block); end + + private + + # source://sentry-ruby//lib/sentry/faraday.rb#58 + def extract_request_info(env); end +end + +# source://sentry-ruby//lib/sentry/faraday.rb#27 +Sentry::Faraday::Instrumenter::BREADCRUMB_CATEGORY = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/faraday.rb#26 +Sentry::Faraday::Instrumenter::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/faraday.rb#5 +Sentry::Faraday::OP_NAME = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#7 +class Sentry::HTTPTransport < ::Sentry::Transport + # @return [HTTPTransport] a new instance of HTTPTransport + # + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#27 + def initialize(*args); end + + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#90 + def conn; end + + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#72 + def endpoint; end + + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#76 + def generate_auth_header; end + + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#32 + def send_data(data); end + + private + + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#121 + def handle_rate_limited_response(headers); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#117 + def has_rate_limited_header?(headers); end + + # @param proxy [String, URI, Hash] Proxy config value passed into `config.transport`. + # Accepts either a URI formatted string, URI, or a hash with the `uri`, `user`, and `password` keys. + # @return [Hash] Normalized proxy config that will be passed into `Net::HTTP` + # + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#182 + def normalize_proxy(proxy); end + + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#147 + def parse_rate_limit_header(rate_limit_header); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#175 + def should_compress?(data); end + + # source://sentry-ruby//lib/sentry/transport/http_transport.rb#196 + def ssl_configuration; end +end + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#10 +Sentry::HTTPTransport::CONTENT_TYPE = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#12 +Sentry::HTTPTransport::DEFAULT_DELAY = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#8 +Sentry::HTTPTransport::GZIP_ENCODING = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#9 +Sentry::HTTPTransport::GZIP_THRESHOLD = T.let(T.unsafe(nil), Integer) + +# The list of errors ::Net::HTTP is known to raise +# See https://github.com/ruby/ruby/blob/b0c639f249165d759596f9579fa985cb30533de6/lib/bundler/fetcher.rb#L281-L286 +# +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#19 +Sentry::HTTPTransport::HTTP_ERRORS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#14 +Sentry::HTTPTransport::RATE_LIMIT_HEADER = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#13 +Sentry::HTTPTransport::RETRY_AFTER_HEADER = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport/http_transport.rb#15 +Sentry::HTTPTransport::USER_AGENT = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/hub.rb#8 +class Sentry::Hub + include ::Sentry::ArgumentCheckingHelper + + # @return [Hub] a new instance of Hub + # + # source://sentry-ruby//lib/sentry/hub.rb#13 + def initialize(client, scope); end + + # source://sentry-ruby//lib/sentry/hub.rb#216 + def add_breadcrumb(breadcrumb, hint: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/hub.rb#45 + def bind_client(client); end + + # source://sentry-ruby//lib/sentry/hub.rb#159 + def capture_check_in(slug, status, **options); end + + # source://sentry-ruby//lib/sentry/hub.rb#183 + def capture_event(event, **options, &block); end + + # source://sentry-ruby//lib/sentry/hub.rb#118 + def capture_exception(exception, **options, &block); end + + # source://sentry-ruby//lib/sentry/hub.rb#144 + def capture_message(message, **options, &block); end + + # source://sentry-ruby//lib/sentry/hub.rb#35 + def clone; end + + # source://sentry-ruby//lib/sentry/hub.rb#27 + def configuration; end + + # source://sentry-ruby//lib/sentry/hub.rb#53 + def configure_scope(&block); end + + # source://sentry-ruby//lib/sentry/hub.rb#295 + def continue_trace(env, **options); end + + # source://sentry-ruby//lib/sentry/hub.rb#23 + def current_client; end + + # source://sentry-ruby//lib/sentry/hub.rb#31 + def current_scope; end + + # source://sentry-ruby//lib/sentry/hub.rb#244 + def end_session; end + + # source://sentry-ruby//lib/sentry/hub.rb#270 + def get_baggage; end + + # source://sentry-ruby//lib/sentry/hub.rb#277 + def get_trace_propagation_headers; end + + # source://sentry-ruby//lib/sentry/hub.rb#289 + def get_trace_propagation_meta; end + + # source://sentry-ruby//lib/sentry/hub.rb#263 + def get_traceparent; end + + # Returns the value of attribute last_event_id. + # + # source://sentry-ruby//lib/sentry/hub.rb#11 + def last_event_id; end + + # source://sentry-ruby//lib/sentry/hub.rb#19 + def new_from_top; end + + # source://sentry-ruby//lib/sentry/hub.rb#75 + def pop_scope; end + + # source://sentry-ruby//lib/sentry/hub.rb#64 + def push_scope; end + + # source://sentry-ruby//lib/sentry/hub.rb#239 + def start_session; end + + # source://sentry-ruby//lib/sentry/hub.rb#79 + def start_transaction(transaction: T.unsafe(nil), custom_sampling_context: T.unsafe(nil), instrumenter: T.unsafe(nil), **options); end + + # this doesn't do anything to the already initialized background worker + # but it temporarily disables dispatching events to it + # + # source://sentry-ruby//lib/sentry/hub.rb#230 + def with_background_worker_disabled(&block); end + + # source://sentry-ruby//lib/sentry/hub.rb#98 + def with_child_span(instrumenter: T.unsafe(nil), **attributes, &block); end + + # source://sentry-ruby//lib/sentry/hub.rb#57 + def with_scope(&block); end + + # source://sentry-ruby//lib/sentry/hub.rb#254 + def with_session_tracking(&block); end + + private + + # source://sentry-ruby//lib/sentry/hub.rb#315 + def current_layer; end +end + +# source://sentry-ruby//lib/sentry/hub.rb#319 +class Sentry::Hub::Layer + # @return [Layer] a new instance of Layer + # + # source://sentry-ruby//lib/sentry/hub.rb#323 + def initialize(client, scope); end + + # Returns the value of attribute client. + # + # source://sentry-ruby//lib/sentry/hub.rb#320 + def client; end + + # Sets the attribute client + # + # @param value the value to set the attribute client to. + # + # source://sentry-ruby//lib/sentry/hub.rb#320 + def client=(_arg0); end + + # Returns the value of attribute scope. + # + # source://sentry-ruby//lib/sentry/hub.rb#321 + def scope; end +end + +# source://sentry-ruby//lib/sentry/integrable.rb#4 +module Sentry::Integrable + # source://sentry-ruby//lib/sentry/integrable.rb#30 + def capture_check_in(slug, status, **options, &block); end + + # source://sentry-ruby//lib/sentry/integrable.rb#14 + def capture_exception(exception, **options, &block); end + + # source://sentry-ruby//lib/sentry/integrable.rb#24 + def capture_message(message, **options, &block); end + + # source://sentry-ruby//lib/sentry/integrable.rb#10 + def integration_name; end + + # source://sentry-ruby//lib/sentry/integrable.rb#5 + def register_integration(name:, version:); end +end + +# source://sentry-ruby//lib/sentry/interface.rb#4 +class Sentry::Interface + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interface.rb#6 + def to_hash; end +end + +# source://sentry-ruby//lib/sentry-ruby.rb#44 +Sentry::LOGGER_PROGNAME = T.let(T.unsafe(nil), String) + +# @api private +# +# source://sentry-ruby//lib/sentry/linecache.rb#5 +class Sentry::LineCache + # @api private + # @return [LineCache] a new instance of LineCache + # + # source://sentry-ruby//lib/sentry/linecache.rb#6 + def initialize; end + + # Any linecache you provide to Sentry must implement this method. + # Returns an Array of Strings representing the lines in the source + # file. The number of lines retrieved is (2 * context) + 1, the middle + # line should be the line requested by lineno. See specs for more information. + # + # @api private + # + # source://sentry-ruby//lib/sentry/linecache.rb#14 + def get_file_context(filename, lineno, context); end + + private + + # @api private + # + # source://sentry-ruby//lib/sentry/linecache.rb#38 + def getline(path, n); end + + # @api private + # + # source://sentry-ruby//lib/sentry/linecache.rb#30 + def getlines(path); end + + # @api private + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/linecache.rb#25 + def valid_path?(path); end +end + +# source://sentry-ruby//lib/sentry/logger.rb#6 +class Sentry::Logger < ::Logger + # @return [Logger] a new instance of Logger + # + # source://sentry-ruby//lib/sentry/logger.rb#10 + def initialize(*_arg0); end +end + +# source://sentry-ruby//lib/sentry/logger.rb#7 +Sentry::Logger::LOG_PREFIX = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/logger.rb#8 +Sentry::Logger::PROGNAME = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/utils/logging_helper.rb#4 +module Sentry::LoggingHelper + # source://sentry-ruby//lib/sentry/utils/logging_helper.rb#14 + def log_debug(message); end + + # source://sentry-ruby//lib/sentry/utils/logging_helper.rb#5 + def log_error(message, exception, debug: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/utils/logging_helper.rb#18 + def log_warn(message); end +end + +# source://sentry-ruby//lib/sentry-ruby.rb#40 +Sentry::META = T.let(T.unsafe(nil), Hash) + +# source://sentry-ruby//lib/sentry/interfaces/mechanism.rb#4 +class Sentry::Mechanism < ::Sentry::Interface + # @return [Mechanism] a new instance of Mechanism + # + # source://sentry-ruby//lib/sentry/interfaces/mechanism.rb#15 + def initialize(type: T.unsafe(nil), handled: T.unsafe(nil)); end + + # A manually captured exception has handled set to true, + # false if coming from an integration where we intercept an uncaught exception. + # Defaults to true here and will be set to false explicitly in integrations. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/interfaces/mechanism.rb#13 + def handled; end + + # A manually captured exception has handled set to true, + # false if coming from an integration where we intercept an uncaught exception. + # Defaults to true here and will be set to false explicitly in integrations. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/interfaces/mechanism.rb#13 + def handled=(_arg0); end + + # Generic identifier, mostly the source integration for this exception. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/mechanism.rb#7 + def type; end + + # Generic identifier, mostly the source integration for this exception. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/mechanism.rb#7 + def type=(_arg0); end +end + +# source://sentry-ruby//lib/sentry/metrics/configuration.rb#4 +module Sentry::Metrics + class << self + # source://sentry-ruby//lib/sentry/metrics.rb#25 + def distribution(key, value, unit: T.unsafe(nil), tags: T.unsafe(nil), timestamp: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/metrics.rb#33 + def gauge(key, value, unit: T.unsafe(nil), tags: T.unsafe(nil), timestamp: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/metrics.rb#21 + def increment(key, value = T.unsafe(nil), unit: T.unsafe(nil), tags: T.unsafe(nil), timestamp: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/metrics.rb#29 + def set(key, value, unit: T.unsafe(nil), tags: T.unsafe(nil), timestamp: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/metrics.rb#37 + def timing(key, unit: T.unsafe(nil), tags: T.unsafe(nil), timestamp: T.unsafe(nil), &block); end + end +end + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#5 +class Sentry::Metrics::Aggregator < ::Sentry::ThreadedPeriodicWorker + # @return [Aggregator] a new instance of Aggregator + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#36 + def initialize(configuration, client); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#59 + def add(type, key, value, unit: T.unsafe(nil), tags: T.unsafe(nil), timestamp: T.unsafe(nil), stacklevel: T.unsafe(nil)); end + + # exposed only for testing + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#34 + def buckets; end + + # exposed only for testing + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#34 + def client; end + + # exposed only for testing + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#34 + def code_locations; end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#91 + def flush(force: T.unsafe(nil)); end + + # exposed only for testing + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#34 + def flush_shift; end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#91 + def run(force: T.unsafe(nil)); end + + # exposed only for testing + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#34 + def thread; end + + private + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#151 + def get_code_locations!; end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#134 + def get_flushable_buckets!(force); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#200 + def get_transaction_name; end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#208 + def get_updated_tags(tags); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#225 + def process_bucket(timestamp, key, type, value); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#217 + def process_span_aggregator(key, value); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#239 + def record_code_location(type, key, unit, timestamp, stacklevel: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#184 + def sanitize_key(key); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#192 + def sanitize_tag_key(key); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#196 + def sanitize_tag_value(value); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#188 + def sanitize_unit(unit); end + + # serialize buckets to statsd format + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#160 + def serialize_buckets(buckets); end + + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#172 + def serialize_locations(timestamp, locations); end + + # important to sort for key consistency + # + # source://sentry-ruby//lib/sentry/metrics/aggregator.rb#124 + def serialize_tags(tags); end +end + +# this is how far removed from user code in the backtrace we are +# when we record code locations +# +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#11 +Sentry::Metrics::Aggregator::DEFAULT_STACKLEVEL = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#6 +Sentry::Metrics::Aggregator::FLUSH_INTERVAL = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#13 +Sentry::Metrics::Aggregator::KEY_SANITIZATION_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#26 +Sentry::Metrics::Aggregator::METRIC_TYPES = T.let(T.unsafe(nil), Hash) + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#7 +Sentry::Metrics::Aggregator::ROLLUP_IN_SECONDS = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#15 +Sentry::Metrics::Aggregator::TAG_KEY_SANITIZATION_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#17 +Sentry::Metrics::Aggregator::TAG_VALUE_SANITIZATION_MAP = T.let(T.unsafe(nil), Hash) + +# source://sentry-ruby//lib/sentry/metrics/aggregator.rb#14 +Sentry::Metrics::Aggregator::UNIT_SANITIZATION_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://sentry-ruby//lib/sentry/metrics/configuration.rb#5 +class Sentry::Metrics::Configuration + include ::Sentry::ArgumentCheckingHelper + + # @return [Configuration] a new instance of Configuration + # + # source://sentry-ruby//lib/sentry/metrics/configuration.rb#35 + def initialize; end + + # Optional Proc, called before emitting a metric to the aggregator. + # Use it to filter keys (return false/nil) or update tags. + # Make sure to return true at the end. + # + # @example + # config.metrics.before_emit = lambda do |key, tags| + # return nil if key == 'foo' + # tags[:bar] = 42 + # tags.delete(:baz) + # true + # end + # @return [Proc, nil] + # + # source://sentry-ruby//lib/sentry/metrics/configuration.rb#33 + def before_emit; end + + # source://sentry-ruby//lib/sentry/metrics/configuration.rb#40 + def before_emit=(value); end + + # Enable code location reporting. + # Will be sent once per day. + # True by default. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/metrics/configuration.rb#18 + def enable_code_locations; end + + # Enable code location reporting. + # Will be sent once per day. + # True by default. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/metrics/configuration.rb#18 + def enable_code_locations=(_arg0); end + + # Enable metrics usage. + # Starts a new {Sentry::Metrics::Aggregator} instance to aggregate metrics + # and a thread to aggregate flush every 5 seconds. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/metrics/configuration.rb#12 + def enabled; end + + # Enable metrics usage. + # Starts a new {Sentry::Metrics::Aggregator} instance to aggregate metrics + # and a thread to aggregate flush every 5 seconds. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/metrics/configuration.rb#12 + def enabled=(_arg0); end +end + +# source://sentry-ruby//lib/sentry/metrics/counter_metric.rb#5 +class Sentry::Metrics::CounterMetric < ::Sentry::Metrics::Metric + # @return [CounterMetric] a new instance of CounterMetric + # + # source://sentry-ruby//lib/sentry/metrics/counter_metric.rb#8 + def initialize(value); end + + # source://sentry-ruby//lib/sentry/metrics/counter_metric.rb#12 + def add(value); end + + # source://sentry-ruby//lib/sentry/metrics/counter_metric.rb#16 + def serialize; end + + # Returns the value of attribute value. + # + # source://sentry-ruby//lib/sentry/metrics/counter_metric.rb#6 + def value; end + + # source://sentry-ruby//lib/sentry/metrics/counter_metric.rb#20 + def weight; end +end + +# source://sentry-ruby//lib/sentry/metrics.rb#13 +Sentry::Metrics::DURATION_UNITS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/metrics/distribution_metric.rb#5 +class Sentry::Metrics::DistributionMetric < ::Sentry::Metrics::Metric + # @return [DistributionMetric] a new instance of DistributionMetric + # + # source://sentry-ruby//lib/sentry/metrics/distribution_metric.rb#8 + def initialize(value); end + + # source://sentry-ruby//lib/sentry/metrics/distribution_metric.rb#12 + def add(value); end + + # source://sentry-ruby//lib/sentry/metrics/distribution_metric.rb#16 + def serialize; end + + # Returns the value of attribute value. + # + # source://sentry-ruby//lib/sentry/metrics/distribution_metric.rb#6 + def value; end + + # source://sentry-ruby//lib/sentry/metrics/distribution_metric.rb#20 + def weight; end +end + +# source://sentry-ruby//lib/sentry/metrics.rb#15 +Sentry::Metrics::FRACTIONAL_UNITS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#5 +class Sentry::Metrics::GaugeMetric < ::Sentry::Metrics::Metric + # @return [GaugeMetric] a new instance of GaugeMetric + # + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#8 + def initialize(value); end + + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#17 + def add(value); end + + # Returns the value of attribute count. + # + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#6 + def count; end + + # Returns the value of attribute last. + # + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#6 + def last; end + + # Returns the value of attribute max. + # + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#6 + def max; end + + # Returns the value of attribute min. + # + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#6 + def min; end + + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#26 + def serialize; end + + # Returns the value of attribute sum. + # + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#6 + def sum; end + + # source://sentry-ruby//lib/sentry/metrics/gauge_metric.rb#30 + def weight; end +end + +# source://sentry-ruby//lib/sentry/metrics.rb#14 +Sentry::Metrics::INFORMATION_UNITS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/metrics/local_aggregator.rb#5 +class Sentry::Metrics::LocalAggregator + # @return [LocalAggregator] a new instance of LocalAggregator + # + # source://sentry-ruby//lib/sentry/metrics/local_aggregator.rb#9 + def initialize; end + + # source://sentry-ruby//lib/sentry/metrics/local_aggregator.rb#13 + def add(key, value); end + + # exposed only for testing + # + # source://sentry-ruby//lib/sentry/metrics/local_aggregator.rb#7 + def buckets; end + + # source://sentry-ruby//lib/sentry/metrics/local_aggregator.rb#21 + def to_hash; end + + private + + # source://sentry-ruby//lib/sentry/metrics/local_aggregator.rb#42 + def deserialize_tags(tags); end +end + +# source://sentry-ruby//lib/sentry/metrics/metric.rb#5 +class Sentry::Metrics::Metric + # @raise [NotImplementedError] + # + # source://sentry-ruby//lib/sentry/metrics/metric.rb#6 + def add(value); end + + # @raise [NotImplementedError] + # + # source://sentry-ruby//lib/sentry/metrics/metric.rb#10 + def serialize; end + + # @raise [NotImplementedError] + # + # source://sentry-ruby//lib/sentry/metrics/metric.rb#14 + def weight; end +end + +# source://sentry-ruby//lib/sentry/metrics.rb#17 +Sentry::Metrics::OP_NAME = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/metrics.rb#18 +Sentry::Metrics::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/metrics/set_metric.rb#8 +class Sentry::Metrics::SetMetric < ::Sentry::Metrics::Metric + # @return [SetMetric] a new instance of SetMetric + # + # source://sentry-ruby//lib/sentry/metrics/set_metric.rb#11 + def initialize(value); end + + # source://sentry-ruby//lib/sentry/metrics/set_metric.rb#15 + def add(value); end + + # source://sentry-ruby//lib/sentry/metrics/set_metric.rb#19 + def serialize; end + + # Returns the value of attribute value. + # + # source://sentry-ruby//lib/sentry/metrics/set_metric.rb#9 + def value; end + + # source://sentry-ruby//lib/sentry/metrics/set_metric.rb#23 + def weight; end +end + +# source://sentry-ruby//lib/sentry/metrics/timing.rb#5 +module Sentry::Metrics::Timing + class << self + # source://sentry-ruby//lib/sentry/metrics/timing.rb#33 + def day; end + + # source://sentry-ruby//lib/sentry/metrics/timing.rb#29 + def hour; end + + # source://sentry-ruby//lib/sentry/metrics/timing.rb#12 + def microsecond; end + + # source://sentry-ruby//lib/sentry/metrics/timing.rb#17 + def millisecond; end + + # source://sentry-ruby//lib/sentry/metrics/timing.rb#25 + def minute; end + + # source://sentry-ruby//lib/sentry/metrics/timing.rb#7 + def nanosecond; end + + # source://sentry-ruby//lib/sentry/metrics/timing.rb#21 + def second; end + + # source://sentry-ruby//lib/sentry/metrics/timing.rb#37 + def week; end + end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/net/http.rb#9 +module Sentry::Net; end + +# @api private +# +# source://sentry-ruby//lib/sentry/net/http.rb#10 +module Sentry::Net::HTTP + include ::Sentry::Utils::HttpTracing + + # To explain how the entire thing works, we need to know how the original Net::HTTP#request works + # Here's part of its definition. As you can see, it usually calls itself inside a #start block + # + # ``` + # def request(req, body = nil, &block) + # unless started? + # start { + # req['connection'] ||= 'close' + # return request(req, body, &block) # <- request will be called for the second time from the first call + # } + # end # ..... + # end + # ``` + # + # So we're only instrumenting request when `Net::HTTP` is already started + # + # @api private + # + # source://sentry-ruby//lib/sentry/net/http.rb#32 + def request(req, body = T.unsafe(nil), &block); end + + private + + # @api private + # + # source://sentry-ruby//lib/sentry/net/http.rb#65 + def extract_request_info(req); end + + # @api private + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/net/http.rb#60 + def from_sentry_sdk?; end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/net/http.rb#15 +Sentry::Net::HTTP::BREADCRUMB_CATEGORY = T.let(T.unsafe(nil), String) + +# @api private +# +# source://sentry-ruby//lib/sentry/net/http.rb#13 +Sentry::Net::HTTP::OP_NAME = T.let(T.unsafe(nil), String) + +# @api private +# +# source://sentry-ruby//lib/sentry/net/http.rb#14 +Sentry::Net::HTTP::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/profiler.rb#6 +class Sentry::Profiler + # @return [Profiler] a new instance of Profiler + # + # source://sentry-ruby//lib/sentry/profiler.rb#16 + def initialize(configuration); end + + # Returns the value of attribute event_id. + # + # source://sentry-ruby//lib/sentry/profiler.rb#14 + def event_id; end + + # Returns the value of attribute sampled. + # + # source://sentry-ruby//lib/sentry/profiler.rb#14 + def sampled; end + + # Sets initial sampling decision of the profile. + # + # @return [void] + # + # source://sentry-ruby//lib/sentry/profiler.rb#49 + def set_initial_sample_decision(transaction_sampled); end + + # source://sentry-ruby//lib/sentry/profiler.rb#28 + def start; end + + # Returns the value of attribute started. + # + # source://sentry-ruby//lib/sentry/profiler.rb#14 + def started; end + + # source://sentry-ruby//lib/sentry/profiler.rb#39 + def stop; end + + # source://sentry-ruby//lib/sentry/profiler.rb#76 + def to_hash; end + + private + + # copied from stacktrace.rb since I don't want to touch existing code + # TODO-neel-profiler try to fetch this from stackprof once we patch + # the native extension + # + # source://sentry-ruby//lib/sentry/profiler.rb#199 + def compute_filename(abs_path, in_app); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/profiler.rb#192 + def in_app?(abs_path); end + + # source://sentry-ruby//lib/sentry/profiler.rb#188 + def log(message); end + + # source://sentry-ruby//lib/sentry/profiler.rb#229 + def record_lost_event(reason); end + + # source://sentry-ruby//lib/sentry/profiler.rb#220 + def split_module(name); end +end + +# 101 Hz in microseconds +# +# source://sentry-ruby//lib/sentry/profiler.rb#10 +Sentry::Profiler::DEFAULT_INTERVAL = T.let(T.unsafe(nil), Float) + +# source://sentry-ruby//lib/sentry/profiler.rb#11 +Sentry::Profiler::MICRO_TO_NANO_SECONDS = T.let(T.unsafe(nil), Float) + +# source://sentry-ruby//lib/sentry/profiler.rb#12 +Sentry::Profiler::MIN_SAMPLES_REQUIRED = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/profiler.rb#8 +Sentry::Profiler::PLATFORM = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/profiler.rb#7 +Sentry::Profiler::VERSION = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/propagation_context.rb#7 +class Sentry::PropagationContext + # @return [PropagationContext] a new instance of PropagationContext + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#36 + def initialize(scope, env = T.unsafe(nil)); end + + # This is only for accessing the current baggage variable. + # Please use the #get_baggage method for interfacing outside this class. + # + # @return [Baggage, nil] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#34 + def baggage; end + + # Returns the Baggage from the propagation context or populates as head SDK if empty. + # + # @return [Baggage, nil] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#105 + def get_baggage; end + + # Returns the Dynamic Sampling Context from the baggage. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#112 + def get_dynamic_sampling_context; end + + # Returns the trace context that can be used to embed in an Event. + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#89 + def get_trace_context; end + + # Returns the sentry-trace header from the propagation context. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#99 + def get_traceparent; end + + # Is there an incoming trace or not? + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#30 + def incoming_trace; end + + # The sampling decision of the parent transaction. + # + # @return [Boolean, nil] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#27 + def parent_sampled; end + + # Span parent's span_id. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#24 + def parent_span_id; end + + # An uuid that can be used to identify the span. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#21 + def span_id; end + + # An uuid that can be used to identify a trace. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#18 + def trace_id; end + + private + + # source://sentry-ruby//lib/sentry/propagation_context.rb#118 + def populate_head_baggage; end + + class << self + # Extract the trace_id, parent_span_id and parent_sampled values from a sentry-trace header. + # + # @param sentry_trace [String] the sentry-trace header value from the previous transaction. + # @return [Array, nil] + # + # source://sentry-ruby//lib/sentry/propagation_context.rb#77 + def extract_sentry_trace(sentry_trace); end + end +end + +# source://sentry-ruby//lib/sentry/propagation_context.rb#8 +Sentry::PropagationContext::SENTRY_TRACE_REGEXP = T.let(T.unsafe(nil), Regexp) + +# source://sentry-ruby//lib/sentry/puma.rb#6 +module Sentry::Puma; end + +# source://sentry-ruby//lib/sentry/puma.rb#7 +module Sentry::Puma::Server + # source://sentry-ruby//lib/sentry/puma.rb#10 + def lowlevel_error(e, env, status = T.unsafe(nil)); end +end + +# source://sentry-ruby//lib/sentry/puma.rb#8 +Sentry::Puma::Server::PUMA_4_AND_PRIOR = T.let(T.unsafe(nil), FalseClass) + +# source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#4 +module Sentry::Rack; end + +# source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#5 +class Sentry::Rack::CaptureExceptions + # @return [CaptureExceptions] a new instance of CaptureExceptions + # + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#10 + def initialize(app); end + + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#14 + def call(env); end + + private + + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#60 + def capture_exception(exception, env); end + + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#52 + def collect_exception(env); end + + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#79 + def finish_transaction(transaction, status_code); end + + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#86 + def mechanism; end + + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#66 + def start_transaction(env, scope); end + + # source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#56 + def transaction_op; end +end + +# source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#6 +Sentry::Rack::CaptureExceptions::ERROR_EVENT_ID_KEY = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#7 +Sentry::Rack::CaptureExceptions::MECHANISM_TYPE = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/rack/capture_exceptions.rb#8 +Sentry::Rack::CaptureExceptions::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/rake.rb#7 +module Sentry::Rake; end + +# source://sentry-ruby//lib/sentry/rake.rb#8 +module Sentry::Rake::Application + # @api private + # + # source://sentry-ruby//lib/sentry/rake.rb#10 + def display_error_message(ex); end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/redis.rb#5 +class Sentry::Redis + # @api private + # @return [Redis] a new instance of Redis + # + # source://sentry-ruby//lib/sentry/redis.rb#10 + def initialize(commands, host, port, db); end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#14 + def instrument; end + + private + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#34 + def commands; end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#53 + def commands_description; end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#34 + def db; end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#34 + def host; end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#59 + def parsed_commands; end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#34 + def port; end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#36 + def record_breadcrumb; end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#75 + def server_description; end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/redis.rb#85 +module Sentry::Redis::GlobalRedisInstrumentation + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#86 + def call(command, redis_config); end + + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#92 + def call_pipelined(commands, redis_config); end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/redis.rb#8 +Sentry::Redis::LOGGER_NAME = T.let(T.unsafe(nil), Symbol) + +# @api private +# +# source://sentry-ruby//lib/sentry/redis.rb#6 +Sentry::Redis::OP_NAME = T.let(T.unsafe(nil), String) + +# @api private +# +# source://sentry-ruby//lib/sentry/redis.rb#79 +module Sentry::Redis::OldClientPatch + # @api private + # + # source://sentry-ruby//lib/sentry/redis.rb#80 + def logging(commands, &block); end +end + +# @api private +# +# source://sentry-ruby//lib/sentry/redis.rb#7 +Sentry::Redis::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# @api private +# +# source://sentry-ruby//lib/sentry/release_detector.rb#5 +class Sentry::ReleaseDetector + class << self + # @api private + # + # source://sentry-ruby//lib/sentry/release_detector.rb#7 + def detect_release(project_root:, running_on_heroku:); end + + # @api private + # + # source://sentry-ruby//lib/sentry/release_detector.rb#19 + def detect_release_from_capistrano(project_root); end + + # @api private + # + # source://sentry-ruby//lib/sentry/release_detector.rb#34 + def detect_release_from_env; end + + # @api private + # + # source://sentry-ruby//lib/sentry/release_detector.rb#30 + def detect_release_from_git; end + + # @api private + # + # source://sentry-ruby//lib/sentry/release_detector.rb#14 + def detect_release_from_heroku(running_on_heroku); end + end +end + +# source://sentry-ruby//lib/sentry/interfaces/request.rb#4 +class Sentry::RequestInterface < ::Sentry::Interface + # @param env [Hash] + # @param send_default_pii [Boolean] + # @param rack_env_whitelist [Array] + # @return [RequestInterface] a new instance of RequestInterface + # @see Configuration#send_default_pii + # @see Configuration#rack_env_whitelist + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#44 + def initialize(env:, send_default_pii:, rack_env_whitelist:); end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#31 + def cookies; end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#31 + def cookies=(_arg0); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#25 + def data; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#25 + def data=(_arg0); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#37 + def env; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#37 + def env=(_arg0); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#34 + def headers; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#34 + def headers=(_arg0); end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#22 + def method; end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#22 + def method=(_arg0); end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#28 + def query_string; end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#28 + def query_string=(_arg0); end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#19 + def url; end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#19 + def url=(_arg0); end + + private + + # source://sentry-ruby//lib/sentry/interfaces/request.rb#126 + def filter_and_format_env(env, rack_env_whitelist); end + + # source://sentry-ruby//lib/sentry/interfaces/request.rb#84 + def filter_and_format_headers(env, send_default_pii); end + + # In versions < 3, Rack adds in an incorrect HTTP_VERSION key, which causes downstream + # to think this is a Version header. Instead, this is mapped to + # env['SERVER_PROTOCOL']. But we don't want to ignore a valid header + # if the request has legitimately sent a Version header themselves. + # See: https://github.com/rack/rack/blob/028438f/lib/rack/handler/cgi.rb#L29 + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#119 + def is_server_protocol?(key, value, protocol_version); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/interfaces/request.rb#108 + def is_skippable_header?(key); end + + # source://sentry-ruby//lib/sentry/interfaces/request.rb#71 + def read_data_from(request); end +end + +# source://sentry-ruby//lib/sentry/interfaces/request.rb#6 +Sentry::RequestInterface::CONTENT_HEADERS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/interfaces/request.rb#7 +Sentry::RequestInterface::IP_HEADERS = T.let(T.unsafe(nil), Array) + +# See Sentry server default limits at +# https://github.com/getsentry/sentry/blob/master/src/sentry/conf/server.py +# +# source://sentry-ruby//lib/sentry/interfaces/request.rb#16 +Sentry::RequestInterface::MAX_BODY_LIMIT = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/interfaces/request.rb#5 +Sentry::RequestInterface::REQUEST_ID_HEADERS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry-ruby.rb#46 +Sentry::SENTRY_TRACE_HEADER_NAME = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/scope.rb#9 +class Sentry::Scope + include ::Sentry::ArgumentCheckingHelper + + # @param max_breadcrumbs [Integer] the maximum number of breadcrumbs to be stored in the scope. + # @return [Scope] a new instance of Scope + # + # source://sentry-ruby//lib/sentry/scope.rb#33 + def initialize(max_breadcrumbs: T.unsafe(nil)); end + + # Add a new attachment to the scope. + # + # source://sentry-ruby//lib/sentry/scope.rb#294 + def add_attachment(**opts); end + + # Adds the breadcrumb to the scope's breadcrumbs buffer. + # + # @param breadcrumb [Breadcrumb] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#84 + def add_breadcrumb(breadcrumb); end + + # Adds a new event processor [Proc] to the scope. + # + # @param block [Proc] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#282 + def add_event_processor(&block); end + + # Applies stored attributes and event processors to the given event. + # + # @param event [Event] + # @param hint [Hash] the hint data that'll be passed to event processors. + # @return [Event] + # + # source://sentry-ruby//lib/sentry/scope.rb#48 + def apply_to_event(event, hint = T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def attachments; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def breadcrumbs; end + + # Resets the scope's attributes to defaults. + # + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#40 + def clear; end + + # Clears the scope's breadcrumbs buffer + # + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#90 + def clear_breadcrumbs; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def contexts; end + + # @return [Scope] + # + # source://sentry-ruby//lib/sentry/scope.rb#95 + def dup; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def event_processors; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def extra; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def fingerprint; end + + # Generate a new propagation context either from the incoming env headers or from scratch. + # + # @param env [Hash, nil] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#289 + def generate_propagation_context(env = T.unsafe(nil)); end + + # Returns the associated Span object. + # + # @return [Span, nil] + # + # source://sentry-ruby//lib/sentry/scope.rb#266 + def get_span; end + + # Returns the associated Transaction object. + # + # @return [Transaction, nil] + # + # source://sentry-ruby//lib/sentry/scope.rb#260 + def get_transaction; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def level; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def propagation_context; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def rack_env; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def session; end + + # source://sentry-ruby//lib/sentry/scope.rb#224 + def set_context(key, value); end + + # Updates the scope's contexts attribute by merging with the old value. + # + # @param contexts [Hash] + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/scope.rb#212 + def set_contexts(contexts_hash); end + + # Adds a new key-value pair to current extras. + # + # @param key [String, Symbol] + # @param value [Object] + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/scope.rb#191 + def set_extra(key, value); end + + # source://sentry-ruby//lib/sentry/scope.rb#182 + def set_extras(extras_hash); end + + # Sets the scope's fingerprint attribute. + # + # @param fingerprint [Array] + # @return [Array] + # + # source://sentry-ruby//lib/sentry/scope.rb#273 + def set_fingerprint(fingerprint); end + + # Sets the scope's level attribute. + # + # @param level [String, Symbol] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#232 + def set_level(level); end + + # Sets the scope's rack_env attribute. + # + # @param env [Hash] + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/scope.rb#162 + def set_rack_env(env); end + + # Sets the currently active session on the scope. + # + # @param session [Session, nil] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#248 + def set_session(session); end + + # Sets the scope's span attribute. + # + # @param span [Span] + # @return [Span] + # + # source://sentry-ruby//lib/sentry/scope.rb#170 + def set_span(span); end + + # Adds a new key-value pair to current tags. + # + # @param key [String, Symbol] + # @param value [Object] + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/scope.rb#205 + def set_tag(key, value); end + + # source://sentry-ruby//lib/sentry/scope.rb#196 + def set_tags(tags_hash); end + + # Appends a new transaction name to the scope. + # The "transaction" here does not refer to `Transaction` objects. + # + # @param transaction_name [String] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#240 + def set_transaction_name(transaction_name, source: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/scope.rb#176 + def set_user(user_hash); end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def span; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def tags; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def transaction_name; end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def transaction_source; end + + # These are high cardinality and thus bad. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/scope.rb#254 + def transaction_source_low_quality?; end + + # Updates the scope's data from the given options. + # + # @param contexts [Hash] + # @param extras [Hash] + # @param tags [Hash] + # @param user [Hash] + # @param level [String, Symbol] + # @param fingerprint [Array] + # @param attachments [Array] + # @return [Array] + # + # source://sentry-ruby//lib/sentry/scope.rb#138 + def update_from_options(contexts: T.unsafe(nil), extra: T.unsafe(nil), tags: T.unsafe(nil), user: T.unsafe(nil), level: T.unsafe(nil), fingerprint: T.unsafe(nil), attachments: T.unsafe(nil), **options); end + + # Updates the scope's data from a given scope. + # + # @param scope [Scope] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#115 + def update_from_scope(scope); end + + # source://sentry-ruby//lib/sentry/scope.rb#30 + def user; end + + protected + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def attachments=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def breadcrumbs=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def contexts=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def event_processors=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def extra=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def fingerprint=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def level=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def propagation_context=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def rack_env=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def session=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def span=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def tags=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def transaction_name=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def transaction_source=(_arg0); end + + # source://sentry-ruby//lib/sentry/scope.rb#302 + def user=(_arg0); end + + private + + # source://sentry-ruby//lib/sentry/scope.rb#306 + def set_default_value; end + + # source://sentry-ruby//lib/sentry/scope.rb#324 + def set_new_breadcrumb_buffer; end + + class << self + # Adds a new global event processor [Proc]. + # Sometimes we need a global event processor without needing to configure scope. + # These run before scope event processors. + # + # @param block [Proc] + # @return [void] + # + # source://sentry-ruby//lib/sentry/scope.rb#364 + def add_global_event_processor(&block); end + + # Returns the global event processors array. + # + # @return [Array] + # + # source://sentry-ruby//lib/sentry/scope.rb#354 + def global_event_processors; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/scope.rb#330 + def os_context; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/scope.rb#345 + def runtime_context; end + end +end + +# source://sentry-ruby//lib/sentry/scope.rb#12 +Sentry::Scope::ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/session.rb#4 +class Sentry::Session + # @return [Session] a new instance of Session + # + # source://sentry-ruby//lib/sentry/session.rb#11 + def initialize; end + + # Returns the value of attribute aggregation_key. + # + # source://sentry-ruby//lib/sentry/session.rb#5 + def aggregation_key; end + + # source://sentry-ruby//lib/sentry/session.rb#25 + def close; end + + # source://sentry-ruby//lib/sentry/session.rb#29 + def deep_dup; end + + # Returns the value of attribute started. + # + # source://sentry-ruby//lib/sentry/session.rb#5 + def started; end + + # Returns the value of attribute status. + # + # source://sentry-ruby//lib/sentry/session.rb#5 + def status; end + + # TODO-neel add :crashed after adding handled mechanism + # + # source://sentry-ruby//lib/sentry/session.rb#21 + def update_from_exception(_exception = T.unsafe(nil)); end +end + +# source://sentry-ruby//lib/sentry/session.rb#9 +Sentry::Session::AGGREGATE_STATUSES = T.let(T.unsafe(nil), Array) + +# TODO-neel add :crashed after adding handled mechanism +# +# source://sentry-ruby//lib/sentry/session.rb#8 +Sentry::Session::STATUSES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/session_flusher.rb#4 +class Sentry::SessionFlusher < ::Sentry::ThreadedPeriodicWorker + # @return [SessionFlusher] a new instance of SessionFlusher + # + # source://sentry-ruby//lib/sentry/session_flusher.rb#7 + def initialize(configuration, client); end + + # source://sentry-ruby//lib/sentry/session_flusher.rb#26 + def add_session(session); end + + # source://sentry-ruby//lib/sentry/session_flusher.rb#17 + def flush; end + + # source://sentry-ruby//lib/sentry/session_flusher.rb#17 + def run; end + + private + + # source://sentry-ruby//lib/sentry/session_flusher.rb#54 + def attrs; end + + # source://sentry-ruby//lib/sentry/session_flusher.rb#38 + def init_aggregates(aggregation_key); end + + # source://sentry-ruby//lib/sentry/session_flusher.rb#44 + def pending_envelope; end +end + +# source://sentry-ruby//lib/sentry/session_flusher.rb#5 +Sentry::SessionFlusher::FLUSH_INTERVAL = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#6 +class Sentry::SingleExceptionInterface < ::Sentry::Interface + include ::Sentry::CustomInspection + + # @return [SingleExceptionInterface] a new instance of SingleExceptionInterface + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#17 + def initialize(exception:, mechanism:, stacktrace: T.unsafe(nil)); end + + # Returns the value of attribute mechanism. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#14 + def mechanism; end + + # Returns the value of attribute module. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#14 + def module; end + + # Returns the value of attribute stacktrace. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#14 + def stacktrace; end + + # Returns the value of attribute thread_id. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#14 + def thread_id; end + + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#35 + def to_hash; end + + # Returns the value of attribute type. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#14 + def type; end + + # Returns the value of attribute value. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#15 + def value; end + + # Sets the attribute value + # + # @param value the value to set the attribute value to. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#15 + def value=(_arg0); end + + class << self + # patch this method if you want to change an exception's stacktrace frames + # also see `StacktraceBuilder.build`. + # + # source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#44 + def build_with_stacktrace(exception:, stacktrace_builder:, mechanism:); end + end +end + +# source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#12 +Sentry::SingleExceptionInterface::MAX_LOCAL_BYTES = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#11 +Sentry::SingleExceptionInterface::OMISSION_MARK = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#10 +Sentry::SingleExceptionInterface::PROBLEMATIC_LOCAL_VALUE_REPLACEMENT = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/interfaces/single_exception.rb#9 +Sentry::SingleExceptionInterface::SKIP_INSPECTION_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/span.rb#7 +class Sentry::Span + # @return [Span] a new instance of Span + # + # source://sentry-ruby//lib/sentry/span.rb#112 + def initialize(transaction:, description: T.unsafe(nil), op: T.unsafe(nil), status: T.unsafe(nil), trace_id: T.unsafe(nil), span_id: T.unsafe(nil), parent_span_id: T.unsafe(nil), sampled: T.unsafe(nil), start_timestamp: T.unsafe(nil), timestamp: T.unsafe(nil), origin: T.unsafe(nil)); end + + # Span data + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/span.rb#97 + def data; end + + # source://sentry-ruby//lib/sentry/span.rb#235 + def deep_dup; end + + # Span description + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#85 + def description; end + + # Finishes the span by adding a timestamp. + # + # @return [self] + # + # source://sentry-ruby//lib/sentry/span.rb#142 + def finish(end_timestamp: T.unsafe(nil)); end + + # Returns the span's context that can be used to embed in an Event. + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/span.rb#187 + def get_trace_context; end + + # Collects gauge metrics on the span for metric summaries. + # + # source://sentry-ruby//lib/sentry/span.rb#300 + def metrics_local_aggregator; end + + # source://sentry-ruby//lib/sentry/span.rb#304 + def metrics_summary; end + + # Span operation + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#88 + def op; end + + # Span origin that tracks what kind of instrumentation created a span + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#100 + def origin; end + + # Span parent's span_id. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#73 + def parent_span_id; end + + # Sampling result of the span. + # + # @return [Boolean, nil] + # + # source://sentry-ruby//lib/sentry/span.rb#76 + def sampled; end + + # Inserts a key-value pair to the span's data payload. + # + # @param key [String, Symbol] + # @param value [Object] + # + # source://sentry-ruby//lib/sentry/span.rb#282 + def set_data(key, value); end + + # Sets the span's description. + # + # @param description [String] description of the span. + # + # source://sentry-ruby//lib/sentry/span.rb#247 + def set_description(description); end + + # Sets the span's status with given http status code. + # + # @param status_code [String] example: "500". + # + # source://sentry-ruby//lib/sentry/span.rb#266 + def set_http_status(status_code); end + + # Sets the span's operation. + # + # @param op [String] operation of the span. + # + # source://sentry-ruby//lib/sentry/span.rb#241 + def set_op(op); end + + # Sets the origin of the span. + # + # @param origin [String] + # + # source://sentry-ruby//lib/sentry/span.rb#295 + def set_origin(origin); end + + # Sets the span's status. + # + # @param satus [String] status of the span. + # + # source://sentry-ruby//lib/sentry/span.rb#254 + def set_status(status); end + + # Sets a tag to the span. + # + # @param key [String, Symbol] + # @param value [String] + # + # source://sentry-ruby//lib/sentry/span.rb#289 + def set_tag(key, value); end + + # Sets the span's finish timestamp. + # + # @param timestamp [Float] finished time in float format (most precise). + # + # source://sentry-ruby//lib/sentry/span.rb#260 + def set_timestamp(timestamp); end + + # An uuid that can be used to identify the span. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#70 + def span_id; end + + # The SpanRecorder the current span belongs to. + # SpanRecorder holds all spans under the same Transaction object (including the Transaction itself). + # + # @return [SpanRecorder] + # + # source://sentry-ruby//lib/sentry/span.rb#105 + def span_recorder; end + + # The SpanRecorder the current span belongs to. + # SpanRecorder holds all spans under the same Transaction object (including the Transaction itself). + # + # @return [SpanRecorder] + # + # source://sentry-ruby//lib/sentry/span.rb#105 + def span_recorder=(_arg0); end + + # Starts a child span with given attributes. + # + # @param attributes [Hash] the attributes for the child span. + # + # source://sentry-ruby//lib/sentry/span.rb#202 + def start_child(**attributes); end + + # Starting timestamp of the span. + # + # @return [Float] + # + # source://sentry-ruby//lib/sentry/span.rb#79 + def start_timestamp; end + + # Span status + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#91 + def status; end + + # Span tags + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/span.rb#94 + def tags; end + + # Finishing timestamp of the span. + # + # @return [Float] + # + # source://sentry-ruby//lib/sentry/span.rb#82 + def timestamp; end + + # Generates a W3C Baggage header string for distributed tracing + # from the incoming baggage stored on the transaction. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/span.rb#159 + def to_baggage; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/span.rb#164 + def to_hash; end + + # Generates a trace string that can be used to connect other transactions. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#149 + def to_sentry_trace; end + + # An uuid that can be used to identify a trace. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/span.rb#67 + def trace_id; end + + # The Transaction object the Span belongs to. + # Every span needs to be attached to a Transaction and their child spans will also inherit the same transaction. + # + # @return [Transaction] + # + # source://sentry-ruby//lib/sentry/span.rb#110 + def transaction; end + + # Starts a child span, yield it to the given block, and then finish the span after the block is executed. + # + # @example + # span.with_child_span do |child_span| + # # things happen here will be recorded in a child span + # end + # @param attributes [Hash] the attributes for the child span. + # @param block [Proc] the action to be recorded in the child span. + # @yieldparam child_span [Span] + # + # source://sentry-ruby//lib/sentry/span.rb#223 + def with_child_span(**attributes, &block); end +end + +# source://sentry-ruby//lib/sentry/span.rb#63 +Sentry::Span::DEFAULT_SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# We will try to be consistent with OpenTelemetry on this front going forward. +# https://develop.sentry.dev/sdk/performance/span-data-conventions/ +# +# source://sentry-ruby//lib/sentry/span.rb#10 +module Sentry::Span::DataConventions; end + +# The name of the database being accessed. +# For commands that switch the database, this should be set to the target database +# (even if the command fails). +# Example: myDatabase +# +# source://sentry-ruby//lib/sentry/span.rb#24 +Sentry::Span::DataConventions::DB_NAME = T.let(T.unsafe(nil), String) + +# An identifier for the database management system (DBMS) product being used. +# Example: postgresql +# +# source://sentry-ruby//lib/sentry/span.rb#18 +Sentry::Span::DataConventions::DB_SYSTEM = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#43 +Sentry::Span::DataConventions::FILEPATH = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#45 +Sentry::Span::DataConventions::FUNCTION = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#14 +Sentry::Span::DataConventions::HTTP_METHOD = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#13 +Sentry::Span::DataConventions::HTTP_QUERY = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#12 +Sentry::Span::DataConventions::HTTP_STATUS_CODE = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#44 +Sentry::Span::DataConventions::LINENO = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#46 +Sentry::Span::DataConventions::NAMESPACE = T.let(T.unsafe(nil), String) + +# Name of the database host. +# Example: example.com +# +# source://sentry-ruby//lib/sentry/span.rb#28 +Sentry::Span::DataConventions::SERVER_ADDRESS = T.let(T.unsafe(nil), String) + +# Logical server port number +# Example: 80; 8080; 443 +# +# source://sentry-ruby//lib/sentry/span.rb#32 +Sentry::Span::DataConventions::SERVER_PORT = T.let(T.unsafe(nil), String) + +# Physical server IP address or Unix socket address. +# Example: 10.5.3.2 +# +# source://sentry-ruby//lib/sentry/span.rb#36 +Sentry::Span::DataConventions::SERVER_SOCKET_ADDRESS = T.let(T.unsafe(nil), String) + +# Physical server port. +# Recommended: If different than server.port. +# Example: 16456 +# +# source://sentry-ruby//lib/sentry/span.rb#41 +Sentry::Span::DataConventions::SERVER_SOCKET_PORT = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#11 +Sentry::Span::DataConventions::URL = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/span.rb#49 +Sentry::Span::STATUS_MAP = T.let(T.unsafe(nil), Hash) + +# Designed to just report events to Spotlight in development. +# +# source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#8 +class Sentry::SpotlightTransport < ::Sentry::HTTPTransport + # @return [SpotlightTransport] a new instance of SpotlightTransport + # + # source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#12 + def initialize(configuration); end + + # Similar to HTTPTransport connection, but does not support Proxy and SSL + # + # source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#43 + def conn; end + + # source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#21 + def endpoint; end + + # source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#38 + def on_error; end + + # source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#25 + def send_data(data); end +end + +# source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#9 +Sentry::SpotlightTransport::DEFAULT_SIDECAR_URL = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport/spotlight_transport.rb#10 +Sentry::SpotlightTransport::MAX_FAILED_REQUESTS = T.let(T.unsafe(nil), Integer) + +# source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#4 +class Sentry::StacktraceBuilder + # @param project_root [String] + # @param app_dirs_pattern [Regexp, nil] + # @param linecache [LineCache] + # @param context_lines [Integer, nil] + # @param backtrace_cleanup_callback [Proc, nil] + # @return [StacktraceBuilder] a new instance of StacktraceBuilder + # @see Configuration#project_root + # @see Configuration#app_dirs_pattern + # @see Configuration#linecache + # @see Configuration#context_lines + # @see Configuration#backtrace_cleanup_callback + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#30 + def initialize(project_root:, app_dirs_pattern:, linecache:, context_lines:, backtrace_cleanup_callback: T.unsafe(nil)); end + + # @return [Regexp, nil] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#9 + def app_dirs_pattern; end + + # @return [Proc, nil] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#18 + def backtrace_cleanup_callback; end + + # Generates a StacktraceInterface with the given backtrace. + # You can pass a block to customize/exclude frames: + # + # @example + # builder.build(backtrace) do |frame| + # if frame.module.match?(/a_gem/) + # nil + # else + # frame + # end + # end + # @param backtrace [Array] + # @param frame_callback [Proc] + # @return [StacktraceInterface] + # @yieldparam frame [StacktraceInterface::Frame] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#53 + def build(backtrace:, &frame_callback); end + + # @return [Integer, nil] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#15 + def context_lines; end + + # @return [LineCache] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#12 + def linecache; end + + # Get the code location hash for a single line for where metrics where added. + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#67 + def metrics_code_location(unparsed_line); end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#6 + def project_root; end + + private + + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#75 + def convert_parsed_line_into_frame(line); end + + # source://sentry-ruby//lib/sentry/interfaces/stacktrace_builder.rb#81 + def parse_backtrace_lines(backtrace); end +end + +# source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#4 +class Sentry::StacktraceInterface + # @param frames [] + # @return [StacktraceInterface] a new instance of StacktraceInterface + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#9 + def initialize(frames:); end + + # @return [] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#6 + def frames; end + + # @return [String] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#19 + def inspect; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#14 + def to_hash; end +end + +# Not actually an interface, but I want to use the same style +# +# source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#26 +class Sentry::StacktraceInterface::Frame < ::Sentry::Interface + # @return [Frame] a new instance of Frame + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#30 + def initialize(project_root, line); end + + # Returns the value of attribute abs_path. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def abs_path; end + + # Sets the attribute abs_path + # + # @param value the value to set the attribute abs_path to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def abs_path=(_arg0); end + + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#45 + def compute_filename; end + + # Returns the value of attribute context_line. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def context_line; end + + # Sets the attribute context_line + # + # @param value the value to set the attribute context_line to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def context_line=(_arg0); end + + # Returns the value of attribute filename. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def filename; end + + # Sets the attribute filename + # + # @param value the value to set the attribute filename to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def filename=(_arg0); end + + # Returns the value of attribute function. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def function; end + + # Sets the attribute function + # + # @param value the value to set the attribute function to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def function=(_arg0); end + + # Returns the value of attribute in_app. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def in_app; end + + # Sets the attribute in_app + # + # @param value the value to set the attribute in_app to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def in_app=(_arg0); end + + # Returns the value of attribute lineno. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def lineno; end + + # Sets the attribute lineno + # + # @param value the value to set the attribute lineno to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def lineno=(_arg0); end + + # Returns the value of attribute module. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def module; end + + # Sets the attribute module + # + # @param value the value to set the attribute module to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def module=(_arg0); end + + # Returns the value of attribute post_context. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def post_context; end + + # Sets the attribute post_context + # + # @param value the value to set the attribute post_context to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def post_context=(_arg0); end + + # Returns the value of attribute pre_context. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def pre_context; end + + # Sets the attribute pre_context + # + # @param value the value to set the attribute pre_context to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def pre_context=(_arg0); end + + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#60 + def set_context(linecache, context_lines); end + + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#67 + def to_hash(*args); end + + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#41 + def to_s; end + + # Returns the value of attribute vars. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def vars; end + + # Sets the attribute vars + # + # @param value the value to set the attribute vars to. + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#27 + def vars=(_arg0); end + + private + + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#82 + def longest_load_path; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/interfaces/stacktrace.rb#78 + def under_project_root?; end +end + +# source://sentry-ruby//lib/sentry-ruby.rb#50 +Sentry::THREAD_LOCAL = T.let(T.unsafe(nil), Symbol) + +# source://sentry-ruby//lib/sentry/threaded_periodic_worker.rb#4 +class Sentry::ThreadedPeriodicWorker + include ::Sentry::LoggingHelper + + # @return [ThreadedPeriodicWorker] a new instance of ThreadedPeriodicWorker + # + # source://sentry-ruby//lib/sentry/threaded_periodic_worker.rb#7 + def initialize(logger, internal); end + + # source://sentry-ruby//lib/sentry/threaded_periodic_worker.rb#14 + def ensure_thread; end + + # source://sentry-ruby//lib/sentry/threaded_periodic_worker.rb#32 + def kill; end +end + +# source://sentry-ruby//lib/sentry/interfaces/threads.rb#4 +class Sentry::ThreadsInterface + # @param crashed [Boolean] + # @param stacktrace [Array] + # @return [ThreadsInterface] a new instance of ThreadsInterface + # + # source://sentry-ruby//lib/sentry/interfaces/threads.rb#7 + def initialize(crashed: T.unsafe(nil), stacktrace: T.unsafe(nil)); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/interfaces/threads.rb#16 + def to_hash; end + + class << self + # Builds the ThreadsInterface with given backtrace and stacktrace_builder. + # Patch this method if you want to change a threads interface's stacktrace frames. + # + # @param backtrace [Array] + # @param stacktrace_builder [StacktraceBuilder] + # @param crashed [Hash] + # @return [ThreadsInterface] + # @see StacktraceBuilder.build + # + # source://sentry-ruby//lib/sentry/interfaces/threads.rb#37 + def build(backtrace:, stacktrace_builder:, **options); end + end +end + +# source://sentry-ruby//lib/sentry/transaction.rb#8 +class Sentry::Transaction < ::Sentry::Span + include ::Sentry::LoggingHelper + + # @return [Transaction] a new instance of Transaction + # + # source://sentry-ruby//lib/sentry/transaction.rb#63 + def initialize(hub:, name: T.unsafe(nil), source: T.unsafe(nil), parent_sampled: T.unsafe(nil), baggage: T.unsafe(nil), **options); end + + # The parsed incoming W3C baggage header. + # This is only for accessing the current baggage variable. + # Please use the #get_baggage method for interfacing outside this class. + # + # @return [Baggage, nil] + # + # source://sentry-ruby//lib/sentry/transaction.rb#36 + def baggage; end + + # @deprecated Use Sentry.configuration instead. + # + # source://sentry-ruby//lib/sentry/transaction.rb#46 + def configuration; end + + # Additional contexts stored directly on the transaction object. + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/transaction.rb#57 + def contexts; end + + # @return [Transaction] + # + # source://sentry-ruby//lib/sentry/transaction.rb#156 + def deep_dup; end + + # The effective sample rate at which this transaction was sampled. + # + # @return [Float, nil] + # + # source://sentry-ruby//lib/sentry/transaction.rb#53 + def effective_sample_rate; end + + # Finishes the transaction's recording and send it to Sentry. + # + # @param hub [Hub] the hub that'll send this transaction. (Deprecated) + # @return [TransactionEvent] + # + # source://sentry-ruby//lib/sentry/transaction.rb#242 + def finish(hub: T.unsafe(nil), end_timestamp: T.unsafe(nil)); end + + # Get the existing frozen incoming baggage + # or populate one with sentry- items as the head SDK. + # + # @return [Baggage] + # + # source://sentry-ruby//lib/sentry/transaction.rb#276 + def get_baggage; end + + # @deprecated Use Sentry.get_current_hub instead. + # + # source://sentry-ruby//lib/sentry/transaction.rb#43 + def hub; end + + # @deprecated Use Sentry.logger instead. + # + # source://sentry-ruby//lib/sentry/transaction.rb#49 + def logger; end + + # The measurements added to the transaction. + # + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/transaction.rb#40 + def measurements; end + + # The name of the transaction. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/transaction.rb#22 + def name; end + + # The sampling decision of the parent transaction, which will be considered when making the current transaction's sampling decision. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/transaction.rb#30 + def parent_sampled; end + + # The Profiler instance for this transaction. + # + # @return [Profiler] + # + # source://sentry-ruby//lib/sentry/transaction.rb#61 + def profiler; end + + # Set contexts directly on the transaction. + # + # @param key [String, Symbol] + # @param value [Object] + # @return [void] + # + # source://sentry-ruby//lib/sentry/transaction.rb#295 + def set_context(key, value); end + + # Sets initial sampling decision of the transaction. + # + # @param sampling_context [Hash] a context Hash that'll be passed to `traces_sampler` (if provided). + # @return [void] + # + # source://sentry-ruby//lib/sentry/transaction.rb#181 + def set_initial_sample_decision(sampling_context:); end + + # Sets a custom measurement on the transaction. + # + # @param name [String] name of the measurement + # @param value [Float] value of the measurement + # @param unit [String] unit of the measurement + # @return [void] + # + # source://sentry-ruby//lib/sentry/transaction.rb#174 + def set_measurement(name, value, unit = T.unsafe(nil)); end + + # Set the transaction name directly. + # Considered internal api since it bypasses the usual scope logic. + # + # @param name [String] + # @param source [Symbol] + # @return [void] + # + # source://sentry-ruby//lib/sentry/transaction.rb#286 + def set_name(name, source: T.unsafe(nil)); end + + # The source of the transaction name. + # + # @return [Symbol] + # + # source://sentry-ruby//lib/sentry/transaction.rb#26 + def source; end + + # These are high cardinality and thus bad + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/transaction.rb#307 + def source_low_quality?; end + + # Start the profiler. + # + # @return [void] + # + # source://sentry-ruby//lib/sentry/transaction.rb#301 + def start_profiler!; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/transaction.rb#142 + def to_hash; end + + protected + + # source://sentry-ruby//lib/sentry/transaction.rb#313 + def init_span_recorder(limit = T.unsafe(nil)); end + + private + + # source://sentry-ruby//lib/sentry/transaction.rb#320 + def generate_transaction_description; end + + # source://sentry-ruby//lib/sentry/transaction.rb#327 + def populate_head_baggage; end + + class << self + # @deprecated Use Sentry::PropagationContext.extract_sentry_trace instead. + # @return [Array, nil] + # + # source://sentry-ruby//lib/sentry/transaction.rb#137 + def extract_sentry_trace(sentry_trace); end + + # Initalizes a Transaction instance with a Sentry trace string from another transaction (usually from an external request). + # + # The original transaction will become the parent of the new Transaction instance. And they will share the same `trace_id`. + # + # The child transaction will also store the parent's sampling decision in its `parent_sampled` attribute. + # + # @deprecated use Sentry.continue_trace instead. + # @param sentry_trace [String] the trace string from the previous transaction. + # @param baggage [String, nil] the incoming baggage header string. + # @param hub [Hub] the hub that'll be responsible for sending this transaction when it's finished. + # @param options [Hash] the options you want to use to initialize a Transaction instance. + # @return [Transaction, nil] + # + # source://sentry-ruby//lib/sentry/transaction.rb#104 + def from_sentry_trace(sentry_trace, baggage: T.unsafe(nil), hub: T.unsafe(nil), **options); end + end +end + +# source://sentry-ruby//lib/sentry/transaction.rb#13 +Sentry::Transaction::MESSAGE_PREFIX = T.let(T.unsafe(nil), String) + +# @deprecated Use Sentry::PropagationContext::SENTRY_TRACE_REGEXP instead. +# +# source://sentry-ruby//lib/sentry/transaction.rb#10 +Sentry::Transaction::SENTRY_TRACE_REGEXP = T.let(T.unsafe(nil), Regexp) + +# https://develop.sentry.dev/sdk/event-payloads/transaction/#transaction-annotations +# +# source://sentry-ruby//lib/sentry/transaction.rb#16 +Sentry::Transaction::SOURCES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/transaction.rb#346 +class Sentry::Transaction::SpanRecorder + # @return [SpanRecorder] a new instance of SpanRecorder + # + # source://sentry-ruby//lib/sentry/transaction.rb#349 + def initialize(max_length); end + + # source://sentry-ruby//lib/sentry/transaction.rb#354 + def add(span); end + + # Returns the value of attribute max_length. + # + # source://sentry-ruby//lib/sentry/transaction.rb#347 + def max_length; end + + # Returns the value of attribute spans. + # + # source://sentry-ruby//lib/sentry/transaction.rb#347 + def spans; end +end + +# source://sentry-ruby//lib/sentry/transaction.rb#12 +Sentry::Transaction::UNLABELD_NAME = T.let(T.unsafe(nil), String) + +# TransactionEvent represents events that carry transaction data (type: "transaction"). +# +# source://sentry-ruby//lib/sentry/transaction_event.rb#5 +class Sentry::TransactionEvent < ::Sentry::Event + # @return [TransactionEvent] a new instance of TransactionEvent + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#23 + def initialize(transaction:, **options); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#12 + def measurements; end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#12 + def measurements=(_arg0); end + + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#21 + def metrics_summary; end + + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#21 + def metrics_summary=(_arg0); end + + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#18 + def profile; end + + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#18 + def profile=(_arg0); end + + # @return [] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#9 + def spans; end + + # @return [] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#9 + def spans=(_arg0); end + + # @return [Float, nil] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#15 + def start_timestamp; end + + # Sets the event's start_timestamp. + # + # @param time [Time, Float] + # @return [void] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#46 + def start_timestamp=(time); end + + # @return [Hash] + # + # source://sentry-ruby//lib/sentry/transaction_event.rb#51 + def to_hash; end + + private + + # source://sentry-ruby//lib/sentry/transaction_event.rb#62 + def populate_profile(transaction); end +end + +# source://sentry-ruby//lib/sentry/transaction_event.rb#6 +Sentry::TransactionEvent::TYPE = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport/configuration.rb#4 +class Sentry::Transport + include ::Sentry::LoggingHelper + + # @return [Transport] a new instance of Transport + # + # source://sentry-ruby//lib/sentry/transport.rb#32 + def initialize(configuration); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/transport.rb#113 + def any_rate_limited?; end + + # Returns the value of attribute discarded_events. + # + # source://sentry-ruby//lib/sentry/transport.rb#27 + def discarded_events; end + + # source://sentry-ruby//lib/sentry/transport.rb#117 + def envelope_from_event(event); end + + # source://sentry-ruby//lib/sentry/transport.rb#167 + def flush; end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/transport.rb#91 + def is_rate_limited?(data_category); end + + # Returns the value of attribute last_client_report_sent. + # + # source://sentry-ruby//lib/sentry/transport.rb#27 + def last_client_report_sent; end + + # @deprecated Use Sentry.logger to retrieve the current logger instead. + # + # source://sentry-ruby//lib/sentry/transport.rb#30 + def logger; end + + # Returns the value of attribute rate_limits. + # + # source://sentry-ruby//lib/sentry/transport.rb#27 + def rate_limits; end + + # source://sentry-ruby//lib/sentry/transport.rb#160 + def record_lost_event(reason, data_category, num: T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://sentry-ruby//lib/sentry/transport.rb#45 + def send_data(data, options = T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/transport.rb#56 + def send_envelope(envelope); end + + # source://sentry-ruby//lib/sentry/transport.rb#49 + def send_event(event); end + + # source://sentry-ruby//lib/sentry/transport.rb#69 + def serialize_envelope(envelope); end + + private + + # source://sentry-ruby//lib/sentry/transport.rb#178 + def fetch_pending_client_report(force: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/transport.rb#200 + def reject_rate_limited_items(envelope); end +end + +# source://sentry-ruby//lib/sentry/transport.rb#10 +Sentry::Transport::CLIENT_REPORT_INTERVAL = T.let(T.unsafe(nil), Integer) + +# https://develop.sentry.dev/sdk/client-reports/#envelope-item-payload +# +# source://sentry-ruby//lib/sentry/transport.rb#13 +Sentry::Transport::CLIENT_REPORT_REASONS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/transport/configuration.rb#5 +class Sentry::Transport::Configuration + # @return [Configuration] a new instance of Configuration + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#81 + def initialize; end + + # The encoding to use to compress the request body. + # Default value is `Sentry::HTTPTransport::GZIP_ENCODING`. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#72 + def encoding; end + + # The encoding to use to compress the request body. + # Default value is `Sentry::HTTPTransport::GZIP_ENCODING`. + # + # @return [String] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#72 + def encoding=(_arg0); end + + # The timeout in seconds to read data from Sentry, in seconds. + # Default value is 1. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#16 + def open_timeout; end + + # The timeout in seconds to read data from Sentry, in seconds. + # Default value is 1. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#16 + def open_timeout=(_arg0); end + + # The proxy configuration to use to connect to Sentry. + # Accepts either a URI formatted string, URI, or a hash with the `uri`, + # `user`, and `password` keys. + # + # If you're using the default transport (`Sentry::HTTPTransport`), + # proxy settings will also automatically be read from tne environment + # variables (`HTTP_PROXY`, `HTTPS_PROXY`, `NO_PROXY`). + # + # @example + # # setup proxy using a string: + # config.transport.proxy = "https://user:password@proxyhost:8080" + # + # # setup proxy using a URI: + # config.transport.proxy = URI("https://user:password@proxyhost:8080") + # + # # setup proxy using a hash: + # config.transport.proxy = { + # uri: URI("https://proxyhost:8080"), + # user: "user", + # password: "password" + # } + # @return [String, URI, Hash, nil] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#41 + def proxy; end + + # The proxy configuration to use to connect to Sentry. + # Accepts either a URI formatted string, URI, or a hash with the `uri`, + # `user`, and `password` keys. + # + # If you're using the default transport (`Sentry::HTTPTransport`), + # proxy settings will also automatically be read from tne environment + # variables (`HTTP_PROXY`, `HTTPS_PROXY`, `NO_PROXY`). + # + # @example + # # setup proxy using a string: + # config.transport.proxy = "https://user:password@proxyhost:8080" + # + # # setup proxy using a URI: + # config.transport.proxy = URI("https://user:password@proxyhost:8080") + # + # # setup proxy using a hash: + # config.transport.proxy = { + # uri: URI("https://proxyhost:8080"), + # user: "user", + # password: "password" + # } + # @return [String, URI, Hash, nil] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#41 + def proxy=(_arg0); end + + # The SSL configuration to use to connect to Sentry. + # You can either pass a `Hash` containing `ca_file` and `verification` keys, + # or you can set those options directly on the `Sentry::HTTPTransport::Configuration` object: + # + # @example + # config.transport.ssl = { + # ca_file: "/path/to/ca_file", + # verification: true + # end + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#54 + def ssl; end + + # The SSL configuration to use to connect to Sentry. + # You can either pass a `Hash` containing `ca_file` and `verification` keys, + # or you can set those options directly on the `Sentry::HTTPTransport::Configuration` object: + # + # @example + # config.transport.ssl = { + # ca_file: "/path/to/ca_file", + # verification: true + # end + # @return [Hash, nil] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#54 + def ssl=(_arg0); end + + # The path to the CA file to use to verify the SSL connection. + # Default value is `nil`. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#60 + def ssl_ca_file; end + + # The path to the CA file to use to verify the SSL connection. + # Default value is `nil`. + # + # @return [String, nil] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#60 + def ssl_ca_file=(_arg0); end + + # Whether to verify that the peer certificate is valid in SSL connections. + # Default value is `true`. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#66 + def ssl_verification; end + + # Whether to verify that the peer certificate is valid in SSL connections. + # Default value is `true`. + # + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#66 + def ssl_verification=(_arg0); end + + # The timeout in seconds to open a connection to Sentry, in seconds. + # Default value is 2. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#10 + def timeout; end + + # The timeout in seconds to open a connection to Sentry, in seconds. + # Default value is 2. + # + # @return [Integer] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#10 + def timeout=(_arg0); end + + # The class to use as a transport to connect to Sentry. + # If this option not set, it will return `nil`, and Sentry will use + # `Sentry::HTTPTransport` by default. + # + # @return [Class, nil] + # + # source://sentry-ruby//lib/sentry/transport/configuration.rb#79 + def transport_class; end + + # source://sentry-ruby//lib/sentry/transport/configuration.rb#88 + def transport_class=(klass); end +end + +# source://sentry-ruby//lib/sentry/transport.rb#8 +Sentry::Transport::PROTOCOL_VERSION = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/transport.rb#9 +Sentry::Transport::USER_AGENT = T.let(T.unsafe(nil), String) + +# source://sentry-ruby//lib/sentry/utils/encoding_helper.rb#4 +module Sentry::Utils; end + +# source://sentry-ruby//lib/sentry/utils/encoding_helper.rb#5 +module Sentry::Utils::EncodingHelper + class << self + # source://sentry-ruby//lib/sentry/utils/encoding_helper.rb#6 + def encode_to_utf_8(value); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/utils/encoding_helper.rb#15 + def valid_utf_8?(value); end + end +end + +# source://sentry-ruby//lib/sentry/utils/exception_cause_chain.rb#5 +module Sentry::Utils::ExceptionCauseChain + class << self + # source://sentry-ruby//lib/sentry/utils/exception_cause_chain.rb#6 + def exception_to_array(exception); end + end +end + +# source://sentry-ruby//lib/sentry/utils/http_tracing.rb#5 +module Sentry::Utils::HttpTracing + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/utils/http_tracing.rb#33 + def propagate_trace?(url); end + + # source://sentry-ruby//lib/sentry/utils/http_tracing.rb#18 + def record_sentry_breadcrumb(request_info, response_status); end + + # @return [Boolean] + # + # source://sentry-ruby//lib/sentry/utils/http_tracing.rb#29 + def record_sentry_breadcrumb?; end + + # source://sentry-ruby//lib/sentry/utils/http_tracing.rb#14 + def set_propagation_headers(req); end + + # source://sentry-ruby//lib/sentry/utils/http_tracing.rb#6 + def set_span_info(sentry_span, request_info, response_status); end +end + +# source://sentry-ruby//lib/sentry/utils/real_ip.rb#11 +class Sentry::Utils::RealIp + # @return [RealIp] a new instance of RealIp + # + # source://sentry-ruby//lib/sentry/utils/real_ip.rb#23 + def initialize(remote_addr: T.unsafe(nil), client_ip: T.unsafe(nil), real_ip: T.unsafe(nil), forwarded_for: T.unsafe(nil), trusted_proxies: T.unsafe(nil)); end + + # source://sentry-ruby//lib/sentry/utils/real_ip.rb#43 + def calculate_ip; end + + # Returns the value of attribute ip. + # + # source://sentry-ruby//lib/sentry/utils/real_ip.rb#21 + def ip; end + + protected + + # source://sentry-ruby//lib/sentry/utils/real_ip.rb#79 + def filter_trusted_proxy_addresses(ips); end + + # source://sentry-ruby//lib/sentry/utils/real_ip.rb#64 + def ips_from(header); end +end + +# source://sentry-ruby//lib/sentry/utils/real_ip.rb#12 +Sentry::Utils::RealIp::LOCAL_ADDRESSES = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/utils/request_id.rb#5 +module Sentry::Utils::RequestId + class << self + # Request ID based on ActionDispatch::RequestId + # + # source://sentry-ruby//lib/sentry/utils/request_id.rb#9 + def read_from(env); end + end +end + +# source://sentry-ruby//lib/sentry/utils/request_id.rb#6 +Sentry::Utils::RequestId::REQUEST_ID_HEADERS = T.let(T.unsafe(nil), Array) + +# source://sentry-ruby//lib/sentry/version.rb#4 +Sentry::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/sentry-sidekiq@5.19.0.rbi b/sorbet/rbi/gems/sentry-sidekiq@5.19.0.rbi new file mode 100644 index 000000000..a827ba672 --- /dev/null +++ b/sorbet/rbi/gems/sentry-sidekiq@5.19.0.rbi @@ -0,0 +1,706 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `sentry-sidekiq` gem. +# Please instead update this file by running `bin/tapioca gem sentry-sidekiq`. + + +# source://sentry-sidekiq//lib/sentry/sidekiq/version.rb#1 +module Sentry + class << self + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#216 + def add_attachment(**opts); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#311 + def add_breadcrumb(breadcrumb, **options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#530 + def add_global_event_processor(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#104 + def apply_patches(config); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#72 + def background_worker; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#72 + def background_worker=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#80 + def backpressure_monitor; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#470 + def capture_check_in(slug, status, **options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#454 + def capture_event(event); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#418 + def capture_exception(exception, **options, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#446 + def capture_message(message, **options, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#348 + def clone_hub_to_current_thread; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#249 + def close; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#156 + def configuration; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#364 + def configure_scope(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#574 + def continue_trace(env, **options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#296 + def csp_report_uri; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#512 + def exception_captured?(exc); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#54 + def exception_locals_tp; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#547 + def get_baggage; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#332 + def get_current_client; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#321 + def get_current_hub; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#340 + def get_current_scope; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#304 + def get_main_hub; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#556 + def get_trace_propagation_headers; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#565 + def get_trace_propagation_meta; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#538 + def get_traceparent; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#227 + def init(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#284 + def initialized?; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#120 + def integrations; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#504 + def last_event_id; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#590 + def logger; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#84 + def metrics_aggregator; end + + # source://railties/7.2.0/lib/rails/engine.rb#412 + def railtie_helpers_paths; end + + # source://railties/7.2.0/lib/rails/engine.rb#395 + def railtie_namespace; end + + # source://railties/7.2.0/lib/rails/engine.rb#416 + def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#128 + def register_integration(name, version); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#89 + def register_patch(key, patch = T.unsafe(nil), target = T.unsafe(nil), &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#111 + def registered_patches; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#595 + def sdk_meta; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#163 + def send_event(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#76 + def session_flusher; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#209 + def set_context(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#195 + def set_extras(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#188 + def set_tags(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#202 + def set_user(*args); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#478 + def start_transaction(**options); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#582 + def sys_command(command); end + + # source://railties/7.2.0/lib/rails/engine.rb#401 + def table_name_prefix; end + + # source://railties/7.2.0/lib/rails/engine.rb#408 + def use_relative_model_naming?; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#600 + def utc_now; end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#496 + def with_child_span(**attributes, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#435 + def with_exception_captured(**options, &block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#389 + def with_scope(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry-ruby.rb#409 + def with_session_tracking(&block); end + end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/configuration.rb#2 +class Sentry::Configuration + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#351 + def initialize; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#26 + def app_dirs_pattern; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#26 + def app_dirs_pattern=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#33 + def async; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#412 + def async=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#269 + def auto_session_tracking; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#269 + def auto_session_tracking=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#50 + def background_worker_max_queue; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#50 + def background_worker_max_queue=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#43 + def background_worker_threads; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#43 + def background_worker_threads=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#61 + def backtrace_cleanup_callback; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#61 + def backtrace_cleanup_callback=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#70 + def before_breadcrumb; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#453 + def before_breadcrumb=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#84 + def before_send; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#441 + def before_send=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#97 + def before_send_transaction; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#447 + def before_send_transaction=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#109 + def breadcrumbs_logger; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#428 + def breadcrumbs_logger=(logger); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#152 + def capture_exception_frame_locals; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#166 + def capture_exception_frame_locals=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#117 + def context_lines; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#117 + def context_lines=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#237 + def cron; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#542 + def csp_report_uri; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#126 + def debug; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#126 + def debug=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#563 + def detect_release; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#130 + def dsn; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#400 + def dsn=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#275 + def enable_backpressure_handling; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#275 + def enable_backpressure_handling=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#260 + def enable_tracing; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#467 + def enable_tracing=(enable_tracing); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#134 + def enabled_environments; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#134 + def enabled_environments=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#520 + def enabled_in_current_env?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#295 + def enabled_patches; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#295 + def enabled_patches=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#121 + def environment; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#459 + def environment=(environment); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#576 + def error_messages; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#299 + def errors; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#507 + def exception_class_allowed?(exc); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#138 + def exclude_loggers; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#138 + def exclude_loggers=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#143 + def excluded_exceptions; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#143 + def excluded_exceptions=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#299 + def gem_specs; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#152 + def include_local_variables; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#152 + def include_local_variables=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#147 + def inspect_exception_causes_for_exclusion?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#284 + def instrumenter; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#463 + def instrumenter=(instrumenter); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#472 + def is_numeric_or_nil?(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#178 + def linecache; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#178 + def linecache=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#183 + def logger; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#183 + def logger=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#113 + def max_breadcrumbs; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#113 + def max_breadcrumbs=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#241 + def metrics; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#290 + def profiles_sample_rate; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#481 + def profiles_sample_rate=(profiles_sample_rate); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#535 + def profiling_enabled?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#188 + def project_root; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#188 + def project_root=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#192 + def propagate_traces; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#192 + def propagate_traces=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#196 + def rack_env_whitelist; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#196 + def rack_env_whitelist=(_arg0); end + + # source://sentry-rails/5.19.0/lib/sentry/rails/configuration.rb#8 + def rails; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#201 + def release; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#406 + def release=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#497 + def sample_allowed?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#206 + def sample_rate; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#206 + def sample_rate=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#265 + def send_client_reports; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#265 + def send_client_reports=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#219 + def send_default_pii; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#219 + def send_default_pii=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#210 + def send_modules; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#210 + def send_modules=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#487 + def sending_allowed?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#491 + def sending_to_dsn_allowed?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#400 + def server=(value); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#229 + def server_name; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#229 + def server_name=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#503 + def session_tracking?; end + + # Returns the value of attribute sidekiq. + # + # source://sentry-sidekiq//lib/sentry/sidekiq/configuration.rb#3 + def sidekiq; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#223 + def skip_rake_integration; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#223 + def skip_rake_integration=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#160 + def spotlight; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#160 + def spotlight=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#552 + def stacktrace_builder; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#280 + def trace_propagation_targets; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#280 + def trace_propagation_targets=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#245 + def traces_sample_rate; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#476 + def traces_sample_rate=(traces_sample_rate); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#255 + def traces_sampler; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#255 + def traces_sampler=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#529 + def tracing_enabled?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#233 + def transport; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#226 + def trusted_proxies; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#226 + def trusted_proxies=(_arg0); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#524 + def valid_sample_rate?(sample_rate); end + + private + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#618 + def capture_in_environment?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#634 + def environment_from_env; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#589 + def excluded_exception?(incoming_exception); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#595 + def excluded_exception_classes; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#599 + def get_exception_class(x); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#583 + def init_dsn(dsn_string); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#603 + def matches_exception?(excluded_exception_class, incoming_exception); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#658 + def processor_count; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#652 + def run_post_initialization_callbacks; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#648 + def running_on_heroku?; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#611 + def safe_const_get(x); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#638 + def server_name_from_env; end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#625 + def valid?; end + + class << self + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#346 + def add_post_initialization_callback(&block); end + + # source://sentry-ruby/5.19.0/lib/sentry/configuration.rb#341 + def post_initialization_callbacks; end + end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/version.rb#2 +module Sentry::Sidekiq + extend ::Sentry::Integrable +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/configuration.rb#14 +class Sentry::Sidekiq::Configuration + # @return [Configuration] a new instance of Configuration + # + # source://sentry-sidekiq//lib/sentry/sidekiq/configuration.rb#19 + def initialize; end + + # Set this option to true if you want Sentry to only capture the last job + # retry if it fails. + # + # source://sentry-sidekiq//lib/sentry/sidekiq/configuration.rb#17 + def report_after_job_retries; end + + # Set this option to true if you want Sentry to only capture the last job + # retry if it fails. + # + # source://sentry-sidekiq//lib/sentry/sidekiq/configuration.rb#17 + def report_after_job_retries=(_arg0); end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#3 +class Sentry::Sidekiq::ContextFilter + # @return [ContextFilter] a new instance of ContextFilter + # + # source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#9 + def initialize(context); end + + # Returns the value of attribute context. + # + # source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#7 + def context; end + + # Once an ActiveJob is queued, ActiveRecord references get serialized into + # some internal reserved keys, such as _aj_globalid. + # + # The problem is, if this job in turn gets queued back into ActiveJob with + # these magic reserved keys, ActiveJob will throw up and error. We want to + # capture these and mutate the keys so we can sanely report it. + # + # source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#20 + def filtered; end + + # source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#35 + def transaction_name; end + + private + + # source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#51 + def filter_context(hash); end + + # source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#66 + def filter_context_hash(key, value); end + + # @return [Boolean] + # + # source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#71 + def has_global_id?; end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#4 +Sentry::Sidekiq::ContextFilter::ACTIVEJOB_RESERVED_PREFIX_REGEX = T.let(T.unsafe(nil), Regexp) + +# source://sentry-sidekiq//lib/sentry/sidekiq/context_filter.rb#5 +Sentry::Sidekiq::ContextFilter::SIDEKIQ_NAME = T.let(T.unsafe(nil), String) + +# source://sentry-sidekiq//lib/sentry/sidekiq/cron/job.rb#13 +module Sentry::Sidekiq::Cron; end + +# source://sentry-sidekiq//lib/sentry/sidekiq/cron/job.rb#14 +module Sentry::Sidekiq::Cron::Job + # source://sentry-sidekiq//lib/sentry/sidekiq/cron/job.rb#15 + def save; end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/error_handler.rb#5 +class Sentry::Sidekiq::ErrorHandler + # @param ex [Exception] the exception / error that occured + # @param context [Hash or Array] Sidekiq error context + # @param sidekiq_config [Sidekiq::Config, Hash] Sidekiq configuration, + # Defaults to nil. + # Sidekiq will pass the config in starting Sidekiq 7.1.5, see + # https://github.com/sidekiq/sidekiq/pull/6051 + # + # source://sentry-sidekiq//lib/sentry/sidekiq/error_handler.rb#14 + def call(ex, context, sidekiq_config = T.unsafe(nil)); end + + private + + # Tries to fetch the retry limit from the job config first, + # then falls back to Sidekiq's configuration. + # + # @return [Integer] the number of retries allowed for the job + # + # source://sentry-sidekiq//lib/sentry/sidekiq/error_handler.rb#52 + def retry_limit(context, sidekiq_config); end + + # @return [Boolean] + # + # source://sentry-sidekiq//lib/sentry/sidekiq/error_handler.rb#43 + def retryable?(context); end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/error_handler.rb#6 +Sentry::Sidekiq::ErrorHandler::WITH_SIDEKIQ_7 = T.let(T.unsafe(nil), TrueClass) + +# source://sentry-sidekiq//lib/sentry/sidekiq/configuration.rb#12 +Sentry::Sidekiq::IGNORE_DEFAULT = T.let(T.unsafe(nil), Array) + +# source://sentry-sidekiq//lib/sentry-sidekiq.rb#16 +class Sentry::Sidekiq::Railtie < ::Rails::Railtie; end + +# source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#65 +class Sentry::Sidekiq::SentryContextClientMiddleware + # source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#66 + def call(_worker_class, job, _queue, _redis_pool); end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#7 +class Sentry::Sidekiq::SentryContextServerMiddleware + # source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#41 + def build_tags(tags); end + + # source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#11 + def call(_worker, job, queue); end + + # source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#57 + def finish_transaction(transaction, status); end + + # source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#45 + def start_transaction(scope, env); end +end + +# source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#8 +Sentry::Sidekiq::SentryContextServerMiddleware::OP_NAME = T.let(T.unsafe(nil), String) + +# source://sentry-sidekiq//lib/sentry/sidekiq/sentry_context_middleware.rb#9 +Sentry::Sidekiq::SentryContextServerMiddleware::SPAN_ORIGIN = T.let(T.unsafe(nil), String) + +# source://sentry-sidekiq//lib/sentry/sidekiq/version.rb#3 +Sentry::Sidekiq::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/shoulda-matchers@5.3.0.rbi b/sorbet/rbi/gems/shoulda-matchers@6.3.1.rbi similarity index 85% rename from sorbet/rbi/gems/shoulda-matchers@5.3.0.rbi rename to sorbet/rbi/gems/shoulda-matchers@6.3.1.rbi index 1797d15d7..b4223bd41 100644 --- a/sorbet/rbi/gems/shoulda-matchers@5.3.0.rbi +++ b/sorbet/rbi/gems/shoulda-matchers@6.3.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `shoulda-matchers` gem. # Please instead update this file by running `bin/tapioca gem shoulda-matchers`. + # source://shoulda-matchers//lib/shoulda/matchers/configuration.rb#1 module Shoulda; end @@ -79,7 +80,7 @@ module Shoulda::Matchers::ActionController def filter_param(key); end # The `permit` matcher tests that an action in your controller receives a - # whitelist of parameters using Rails' Strong Parameters feature + # allowlist of parameters using Rails' Strong Parameters feature # (specifically that `permit` was called with the correct arguments). # # Here's an example: @@ -1193,7 +1194,7 @@ class Shoulda::Matchers::ActionController::PermitMatcher # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#274 def action; end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#305 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#303 def actual_permitted_parameter_names; end # Returns the value of attribute context. @@ -1206,7 +1207,7 @@ class Shoulda::Matchers::ActionController::PermitMatcher # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#274 def controller; end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#331 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#329 def default_verb; end # Returns the value of attribute double_collections_by_parameter_name. @@ -1214,7 +1215,7 @@ class Shoulda::Matchers::ActionController::PermitMatcher # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#274 def double_collections_by_parameter_name; end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#321 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#319 def ensure_action_and_verb_present!; end # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#278 @@ -1225,10 +1226,10 @@ class Shoulda::Matchers::ActionController::PermitMatcher # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#274 def expected_permitted_parameter_names; end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#301 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#299 def format_parameter_names(parameter_names); end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#338 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#336 def parameter_names_as_sentence; end # Returns the value of attribute parameters_double_registry. @@ -1236,7 +1237,7 @@ class Shoulda::Matchers::ActionController::PermitMatcher # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#274 def parameters_double_registry; end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#291 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#289 def reality; end # Returns the value of attribute request_params. @@ -1249,7 +1250,7 @@ class Shoulda::Matchers::ActionController::PermitMatcher # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#274 def subparameter_name; end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#317 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#315 def unpermitted_parameter_names; end # Returns the value of attribute verb. @@ -1260,87 +1261,87 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#431 +# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#429 class Shoulda::Matchers::ActionController::PermitMatcher::ActionNotDefinedError < ::StandardError - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#432 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#430 def message; end end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#343 +# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#341 class Shoulda::Matchers::ActionController::PermitMatcher::CompositeParametersDoubleRegistry # @return [CompositeParametersDoubleRegistry] a new instance of CompositeParametersDoubleRegistry # - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#344 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#342 def initialize; end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#360 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#358 def permitted_parameter_names(options = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#348 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#346 def register; end protected # Returns the value of attribute parameters_double_registries. # - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#368 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#366 def parameters_double_registries; end end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#372 +# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#370 class Shoulda::Matchers::ActionController::PermitMatcher::ParametersDoubleRegistry # @return [ParametersDoubleRegistry] a new instance of ParametersDoubleRegistry # - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#379 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#377 def initialize(params); end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#388 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#386 def permitted_parameter_names(args = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#384 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#382 def register; end protected # Returns the value of attribute double_collections_by_parameter_name. # - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#402 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#400 def double_collections_by_parameter_name; end # Returns the value of attribute params. # - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#402 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#400 def params; end private - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#406 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#404 def register_double_for_permit_against(params, subparameter_name); end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#417 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#415 def register_double_for_permit_on(double_collection); end - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#421 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#419 def register_double_for_require_on(double_collection); end class << self - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#375 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#373 def permitted_parameter_names_within(double_collection); end end end -# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#373 +# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#371 Shoulda::Matchers::ActionController::PermitMatcher::ParametersDoubleRegistry::TOP_LEVEL = T.let(T.unsafe(nil), Object) # @private # -# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#438 +# source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#436 class Shoulda::Matchers::ActionController::PermitMatcher::VerbNotDefinedError < ::StandardError - # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#439 + # source://shoulda-matchers//lib/shoulda/matchers/action_controller/permit_matcher.rb#437 def message; end end @@ -2175,6 +2176,36 @@ module Shoulda::Matchers::ActiveModel # on(:create) # end # + # ##### against + # + # Use `against` if the validation is on an attribute + # other than the attribute being validated: + # + # class UserProfile + # include ActiveModel::Model + # attr_accessor :website_url + # + # alias_attribute :url, :website_url + # + # validates_format_of :url, with: URI.regexp + # end + # + # # RSpec + # RSpec.describe UserProfile, type: :model do + # it do + # should allow_value('https://foo.com'). + # for(:website_url). + # against(:url) + # end + # end + # + # # Minitest (Shoulda) + # class UserProfileTest < ActiveSupport::TestCase + # should allow_value('https://foo.com'). + # for(:website_url). + # against(:url) + # end + # # ##### with_message # # Use `with_message` if you are using a custom validation message. @@ -2299,7 +2330,7 @@ module Shoulda::Matchers::ActiveModel # # @return [AllowValueMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#296 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#326 def allow_value(*values); end # The `allow_value` matcher (or its alias, `allow_values`) is used to @@ -2470,6 +2501,36 @@ module Shoulda::Matchers::ActiveModel # on(:create) # end # + # ##### against + # + # Use `against` if the validation is on an attribute + # other than the attribute being validated: + # + # class UserProfile + # include ActiveModel::Model + # attr_accessor :website_url + # + # alias_attribute :url, :website_url + # + # validates_format_of :url, with: URI.regexp + # end + # + # # RSpec + # RSpec.describe UserProfile, type: :model do + # it do + # should allow_value('https://foo.com'). + # for(:website_url). + # against(:url) + # end + # end + # + # # Minitest (Shoulda) + # class UserProfileTest < ActiveSupport::TestCase + # should allow_value('https://foo.com'). + # for(:website_url). + # against(:url) + # end + # # ##### with_message # # Use `with_message` if you are using a custom validation message. @@ -2595,7 +2656,7 @@ module Shoulda::Matchers::ActiveModel # @private # @return [AllowValueMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#296 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#326 def allow_values(*values); end # The `have_secure_password` matcher tests usage of the @@ -2781,6 +2842,282 @@ module Shoulda::Matchers::ActiveModel # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_acceptance_of_matcher.rb#78 def validate_acceptance_of(attr); end + # The `validate_comparison_of` matcher tests usage of the + # `validates_comparison_of` validation. + # + # class Person + # include ActiveModel::Model + # attr_accessor :gpa + # + # validates_comparison_of :gpa, greater_than: 10 + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it { should validate_comparison_of(:gpa).is_greater_than(10) } + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:gpa).is_greater_than(10) + # end + # + # #### Qualifiers + # + # ##### on + # + # Use `on` if your validation applies only under a certain context. + # + # class Person + # include ActiveModel::Model + # attribute :number_of_dependents, :integer + # attr_accessor :number_of_dependents + # + # validates_comparison_of :number_of_dependents, on: :create, greater_than: 0 + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it do + # should validate_comparison_of(:number_of_dependents). + # is_greater_than(0). + # on(:create) + # end + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:number_of_dependents).is_greater_than(0).on(:create) + # end + # + # ##### is_less_than + # + # Use `is_less_than` to test usage of the the `:less_than` option. This + # asserts that the attribute can take a value which is less than the + # given value and cannot take a value which is greater than or equal to + # it. It can also accept methods or procs that returns a given value. + # + # class Person + # include ActiveModel::Model + # attribute :number_of_cars, :integer + # attr_accessor :number_of_cars + # + # validates_comparison_of :number_of_cars, less_than: :current_number_of_cars + # + # def current_number_of_cars + # 10 + # end + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it do + # should validate_comparison_of(:number_of_cars). + # is_less_than(:current_number_of_cars) + # end + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:number_of_cars). + # is_less_than(:current_number_of_cars) + # end + # + # ##### is_less_than_or_equal_to + # + # Use `is_less_than_or_equal_to` to test usage of the + # `:less_than_or_equal_to` option. This asserts that the attribute can + # take a value which is less than or equal to the given value and cannot + # take a value which is greater than it. It can also accept methods or + # procs that returns a given value. + # + # class Person + # include ActiveModel::Model + # attr_accessor :birth_date + # + # validates_comparison_of :birth_date, less_than_or_equal_to: Date.new(1987, 12, 31) + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it do + # should validate_comparison_of(:birth_date). + # is_less_than_or_equal_to(Date.new(1987, 12, 31)) + # end + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:birth_date). + # is_less_than_or_equal_to(Date.new(1987, 12, 31)) + # end + # + # ##### is_greater_than_or_equal_to + # + # Use `is_greater_than_or_equal_to` to test usage of the + # `:greater_than_or_equal_to` option. This asserts that the attribute can + # take a value which is greater than or equal to the given value and + # cannot take a value which is less than it. + # + # class Person + # include ActiveModel::Model + # attribute :birth_date, :date + # attr_accessor :birth_date + # + # validates_comparison_of :birth_date, + # greater_than_or_equal_to: -> { 18.years.ago.to_date } + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it do + # should validate_comparison_of(:birth_date). + # is_greater_than_or_equal_to(-> { 18.years.ago.to_date }) + # end + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:birth_date). + # is_greater_than_or_equal_to(-> { 18.years.ago.to_date }) + # end + # + # ##### is_greater_than + # + # Use `is_greater_than` to test usage of the `:greater_than` option. + # This asserts that the attribute can take a value which is greater than + # the given value and cannot take a value less than or equal to it. + # It can also accept methods or procs that returns a given value. + # + # class Person + # include ActiveModel::Model + # attribute :legal_age, :integer + # attr_accessor :legal_age + # + # validates_comparison_of :legal_age, greater_than: 21 + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it do + # should validate_comparison_of(:legal_age). + # is_greater_than(21) + # end + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:legal_age). + # is_greater_than(21) + # end + # + # ##### is_equal_to + # + # Use `is_equal_to` to test usage of the `:equal_to` option. This asserts + # that the attribute can take a value which is equal to the given value + # and cannot take a value which is not equal. It can also accept methods or + # procs that returns a given value. + # + # class Person + # include ActiveModel::Model + # attribute :favorite_color, :string + # attr_accessor :favorite_color + # + # validates_comparison_of :favorite_color, equal_to: "blue" + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it { should validate_comparison_of(:favorite_color).is_equal_to("blue") } + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:favorite_color).is_equal_to("blue") + # end + # + # + # ##### is_other_than + # + # Use `is_other_than` to test usage of the `:other_than` option. + # This asserts that the attribute can take a number which is not equal to + # the given value. + # + # class Person + # include ActiveModel::Model + # attr_accessor :legal_age + # + # validates_comparison_of :legal_age, other_than: 21 + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it do + # should validate_comparison_of(:legal_age). + # is_other_than(21) + # end + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:legal_age). + # is_other_than(21) + # end + # + # ##### with_message + # + # Use `with_message` if you are using a custom validation message. + # + # class Person + # include ActiveModel::Model + # attr_accessor :number_of_dependents + # + # validates_comparison_of :number_of_dependents, greater_than: 0 + # message: 'Number of dependents must be a number' + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it do + # should validate_comparison_of(:number_of_dependents). + # is_greater_than(0). + # with_message('Number of dependents must be a number') + # end + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should validate_comparison_of(:number_of_dependents). + # is_greater_than(0). + # with_message('Number of dependents must be a number') + # end + # + # ##### allow_nil + # + # Use `allow_nil` to assert that the attribute allows nil. + # + # class Post + # include ActiveModel::Model + # attr_accessor :age + # + # validates_comparison_of :age, greater_than: 0, allow_nil: true + # end + # + # # RSpec + # RSpec.describe Post, type: :model do + # it { should validate_comparison_of(:age).is_greater_than(0).allow_nil } + # end + # + # # Minitest (Shoulda) + # class PostTest < ActiveSupport::TestCase + # should validate_comparison_of(:age).is_greater_than(0).allow_nil + # end + # + # @return [ValidateComparisonOfMatcher] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#277 + def validate_comparison_of(attr); end + # The `validate_confirmation_of` matcher tests usage of the # `validates_confirmation_of` validation. # @@ -2857,10 +3194,10 @@ module Shoulda::Matchers::ActiveModel # The `validate_exclusion_of` matcher tests usage of the # `validates_exclusion_of` validation, asserting that an attribute cannot - # take a blacklist of values, and inversely, can take values outside of + # take a blocklist of values, and inversely, can take values outside of # this list. # - # If your blacklist is an array of values, use `in_array`: + # If your blocklist an array of values, use `in_array`: # # class Game # include ActiveModel::Model @@ -2883,7 +3220,7 @@ module Shoulda::Matchers::ActiveModel # in_array(['Mac', 'Linux']) # end # - # If your blacklist is a range of values, use `in_range`: + # If your blocklist is a range of values, use `in_range`: # # class Game # include ActiveModel::Model @@ -2973,9 +3310,9 @@ module Shoulda::Matchers::ActiveModel # The `validate_inclusion_of` matcher tests usage of the # `validates_inclusion_of` validation, asserting that an attribute can - # take a whitelist of values and cannot take values outside of this list. + # take a allowlist of values and cannot take values outside of this list. # - # If your whitelist is an array of values, use `in_array`: + # If your allowlist is an array of values, use `in_array`: # # class Issue # include ActiveModel::Model @@ -2999,7 +3336,7 @@ module Shoulda::Matchers::ActiveModel # in_array(['open', 'resolved', 'unresolved']) # end # - # If your whitelist is a range of values, use `in_range`: + # If your allowlist is a range of values, use `in_range`: # # class Issue # include ActiveModel::Model @@ -3229,12 +3566,12 @@ module Shoulda::Matchers::ActiveModel # # @return [ValidateInclusionOfMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#267 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#268 def validate_inclusion_of(attr); end # The `validate_length_of` matcher tests usage of the # `validates_length_of` matcher. Note that this matcher is intended to be - # used against string columns and not integer columns. + # used against string columns and associations and not integer columns. # # #### Qualifiers # @@ -3267,7 +3604,8 @@ module Shoulda::Matchers::ActiveModel # # Use `is_at_least` to test usage of the `:minimum` option. This asserts # that the attribute can take a string which is equal to or longer than - # the given length and cannot take a string which is shorter. + # the given length and cannot take a string which is shorter. This qualifier + # also works for associations. # # class User # include ActiveModel::Model @@ -3292,7 +3630,8 @@ module Shoulda::Matchers::ActiveModel # # Use `is_at_most` to test usage of the `:maximum` option. This asserts # that the attribute can take a string which is equal to or shorter than - # the given length and cannot take a string which is longer. + # the given length and cannot take a string which is longer. This qualifier + # also works for associations. # # class User # include ActiveModel::Model @@ -3315,7 +3654,8 @@ module Shoulda::Matchers::ActiveModel # # Use `is_equal_to` to test usage of the `:is` option. This asserts that # the attribute can take a string which is exactly equal to the given - # length and cannot take a string which is shorter or longer. + # length and cannot take a string which is shorter or longer. This qualifier + # also works for associations. # # class User # include ActiveModel::Model @@ -3337,7 +3677,7 @@ module Shoulda::Matchers::ActiveModel # ##### is_at_least + is_at_most # # Use `is_at_least` and `is_at_most` together to test usage of the `:in` - # option. + # option. This qualifies also works for associations. # # class User # include ActiveModel::Model @@ -3489,23 +3829,46 @@ module Shoulda::Matchers::ActiveModel # should validate_length_of(:bio).is_at_least(15).allow_blank # end # - # @return [ValidateLengthOfMatcher] + # ##### as_array # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#263 - def validate_length_of(attr); end - - # The `validate_numericality_of` matcher tests usage of the - # `validates_numericality_of` validation. + # Use `as_array` if you have an ActiveModel model and the attribute being validated + # is designed to store an array. (This is not necessary if you have an ActiveRecord + # model with an array column, as the matcher will detect this automatically.) # - # class Person + # class User # include ActiveModel::Model - # attr_accessor :gpa + # attribute :arr, array: true # - # validates_numericality_of :gpa + # validates_length_of :arr, minimum: 15 # end # # # RSpec - # RSpec.describe Person, type: :model do + # describe User do + # it { should validate_length_of(:arr).as_array.is_at_least(15) } + # end + # + # # Minitest (Shoulda) + # class UserTest < ActiveSupport::TestCase + # should validate_length_of(:arr).as_array.is_at_least(15) + # end + # + # @return [ValidateLengthOfMatcher] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#289 + def validate_length_of(attr); end + + # The `validate_numericality_of` matcher tests usage of the + # `validates_numericality_of` validation. + # + # class Person + # include ActiveModel::Model + # attr_accessor :gpa + # + # validates_numericality_of :gpa + # end + # + # # RSpec + # RSpec.describe Person, type: :model do # it { should validate_numericality_of(:gpa) } # end # @@ -4000,185 +4363,193 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#307 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#337 class Shoulda::Matchers::ActiveModel::AllowValueMatcher include ::Shoulda::Matchers::ActiveModel::Helpers include ::Shoulda::Matchers::ActiveModel::Qualifiers::IgnoringInterferenceByWriter # @return [AllowValueMatcher] a new instance of AllowValueMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#325 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#355 def initialize(*values); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#389 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#425 def _after_setting_value(&callback); end # Returns the value of attribute after_setting_value_callback. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#311 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#341 def after_setting_value_callback; end + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#382 + def against(attribute); end + # Sets the attribute attribute_changed_value_message # # @param value the value to set the attribute attribute_changed_value_message to. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#319 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#349 def attribute_changed_value_message=(_arg0); end # Returns the value of attribute attribute_to_check_message_against. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#311 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#341 def attribute_to_check_message_against; end # Returns the value of attribute attribute_to_set. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#311 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#341 def attribute_to_set; end # Returns the value of attribute context. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#311 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#341 def context; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#502 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#547 def description; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#399 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#435 def does_not_match?(instance); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#366 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#402 def expected_message; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#376 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#412 def expects_custom_validation_message?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#385 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#421 def expects_strict?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#405 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#445 def failure_message; end # Sets the attribute failure_message_preface # # @param value the value to set the attribute failure_message_preface to. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#319 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#349 def failure_message_preface=(_arg0); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#432 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#472 def failure_message_when_negated; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#338 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#368 def for(attribute_name); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#311 + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#441 + def has_any_errors?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#341 def instance; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#514 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#559 def last_attribute_setter_used; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#518 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#563 def last_value_set; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#393 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#429 def matches?(instance); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#510 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#555 def model; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#344 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#374 def on(context); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#506 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#551 def simple_description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#380 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#416 def strict(expects_strict = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#319 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#349 def values_to_preset=(_arg0); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#352 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#388 def with_message(message, given_options = T.unsafe(nil)); end protected # Returns the value of attribute options. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#524 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#569 def options; end # Returns the value of attribute result. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#524 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#569 def result; end # Returns the value of attribute values_to_preset. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#524 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#569 def values_to_preset; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#524 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#569 def values_to_set; end private - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#569 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#614 def attribute_changed_value_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#598 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#643 def attribute_setters_and_validators_for_values_to_set; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#593 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#638 def attribute_setters_for_values_to_preset; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#574 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#619 def default_attribute_changed_value_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#621 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#666 def default_attribute_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#628 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#673 def default_attribute_message_values; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#613 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#658 def default_expected_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#543 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#588 def default_failure_message_preface; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#589 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#634 def description_for_resulting_attribute_setter; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#584 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#629 def descriptions_for_preset_values; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#539 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#584 def failure_message_preface; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#642 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#687 def human_attribute_name; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#564 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#609 def include_attribute_changed_value_message?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#606 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#651 def inspected_values_to_set; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#638 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#683 def model_name; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#533 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/allow_value_matcher.rb#578 def run(strategy); end end @@ -4631,6 +5002,76 @@ class Shoulda::Matchers::ActiveModel::AllowValueMatcher::SuccessfulSetting def successful?; end end +# @private +# +# source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#7 +class Shoulda::Matchers::ActiveModel::ComparisonMatcher < ::Shoulda::Matchers::ActiveModel::ValidationMatcher + # @return [ComparisonMatcher] a new instance of ComparisonMatcher + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#37 + def initialize(matcher, value, operator); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#81 + def comparison_description; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#85 + def comparison_submatchers; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#72 + def expects_custom_validation_message?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#35 + def failure_message(*_arg0, **_arg1, &_arg2); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#35 + def failure_message_when_negated(*_arg0, **_arg1, &_arg2); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#61 + def for(attribute); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#76 + def matches?(subject); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#49 + def simple_description; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#66 + def with_message(message); end + + private + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#114 + def assertions; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#92 + def build_comparison_submatchers; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#100 + def comparison_combos; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#151 + def comparison_expectation; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#131 + def diffs_to_compare; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#145 + def diffs_when_string(diff_to_compare); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#118 + def option_value; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#104 + def submatcher_method_names; end +end + +# source://shoulda-matchers//lib/shoulda/matchers/active_model/comparison_matcher.rb#8 +Shoulda::Matchers::ActiveModel::ComparisonMatcher::ERROR_MESSAGES = T.let(T.unsafe(nil), Hash) + # @private # # source://shoulda-matchers//lib/shoulda/matchers/active_model/errors.rb#5 @@ -4764,10 +5205,10 @@ end class Shoulda::Matchers::ActiveModel::HaveSecurePasswordMatcher # @return [HaveSecurePasswordMatcher] a new instance of HaveSecurePasswordMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#52 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#54 def initialize(attribute); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#56 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#58 def description; end # Returns the value of attribute failure_message. @@ -4775,27 +5216,30 @@ class Shoulda::Matchers::ActiveModel::HaveSecurePasswordMatcher # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#39 def failure_message; end + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#74 + def failure_message_when_negated; end + # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#60 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#62 def matches?(subject); end protected # Returns the value of attribute subject. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#74 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#81 def subject; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#76 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#83 def validate; end private - # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#108 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#115 def authenticate_method; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#98 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/have_secure_password_matcher.rb#105 def expected_methods; end end @@ -4852,70 +5296,6 @@ end # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/numeric_type_matcher.rb#6 module Shoulda::Matchers::ActiveModel::NumericalityMatchers; end -# @private -# -# source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#8 -class Shoulda::Matchers::ActiveModel::NumericalityMatchers::ComparisonMatcher < ::Shoulda::Matchers::ActiveModel::ValidationMatcher - # @return [ComparisonMatcher] a new instance of ComparisonMatcher - # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#38 - def initialize(numericality_matcher, value, operator); end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#82 - def comparison_description; end - - # @return [Boolean] - # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#73 - def expects_custom_validation_message?; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#36 - def failure_message(*_arg0, **_arg1, &_arg2); end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#36 - def failure_message_when_negated(*_arg0, **_arg1, &_arg2); end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#62 - def for(attribute); end - - # @return [Boolean] - # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#77 - def matches?(subject); end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#50 - def simple_description; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#86 - def submatchers; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#67 - def with_message(message); end - - private - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#114 - def assertions; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#92 - def build_submatchers; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#100 - def comparison_combos; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#129 - def comparison_expectation; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#118 - def diffs_to_compare; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#104 - def submatcher_method_names; end -end - -# source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/comparison_matcher.rb#9 -Shoulda::Matchers::ActiveModel::NumericalityMatchers::ComparisonMatcher::ERROR_MESSAGES = T.let(T.unsafe(nil), Hash) - # @private # # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/even_number_matcher.rb#6 @@ -5128,9 +5508,6 @@ class Shoulda::Matchers::ActiveModel::NumericalityMatchers::Submatchers # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#20 def failure_message_when_negated; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#28 - def last_failing_submatcher; end - # @return [Boolean] # # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#11 @@ -5138,8 +5515,17 @@ class Shoulda::Matchers::ActiveModel::NumericalityMatchers::Submatchers private - # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#34 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#42 + def failing_submatcher; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#30 def failing_submatchers; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#46 + def non_failing_submatcher; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/numericality_matchers/submatchers.rb#36 + def non_failing_submatchers; end end # @private @@ -5279,11 +5665,6 @@ class Shoulda::Matchers::ActiveModel::ValidateAbsenceOfMatcher < ::Shoulda::Matc private - # @return [Boolean] - # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_absence_of_matcher.rb#146 - def array_column?; end - # @return [Boolean] # # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_absence_of_matcher.rb#133 @@ -5294,10 +5675,10 @@ class Shoulda::Matchers::ActiveModel::ValidateAbsenceOfMatcher < ::Shoulda::Matc # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_absence_of_matcher.rb#152 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_absence_of_matcher.rb#146 def enum_column?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_absence_of_matcher.rb#157 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_absence_of_matcher.rb#151 def enum_values; end # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_absence_of_matcher.rb#141 @@ -5330,6 +5711,147 @@ class Shoulda::Matchers::ActiveModel::ValidateAcceptanceOfMatcher < ::Shoulda::M def simple_description; end end +# @private +# +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#282 +class Shoulda::Matchers::ActiveModel::ValidateComparisonOfMatcher < ::Shoulda::Matchers::ActiveModel::ValidationMatcher + # @return [ValidateComparisonOfMatcher] a new instance of ValidateComparisonOfMatcher + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#288 + def initialize(attribute); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#296 + def allow_nil; end + + # Returns the value of attribute diff_to_compare. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#286 + def diff_to_compare; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#347 + def does_not_match?(subject); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#302 + def expects_to_allow_nil?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#366 + def failure_message; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#373 + def failure_message_when_negated; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#381 + def given_numeric_column?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#316 + def is_equal_to(value); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#306 + def is_greater_than(value); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#311 + def is_greater_than_or_equal_to(value); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#321 + def is_less_than(value); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#326 + def is_less_than_or_equal_to(value); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#331 + def is_other_than(value); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#336 + def matches?(subject); end + + # Returns the value of attribute number_of_submatchers. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#286 + def number_of_submatchers; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#355 + def simple_description; end + + private + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#416 + def add_submatcher(submatcher); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#522 + def allowed_type_name; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#388 + def attribute_is_active_record_column?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#484 + def build_submatcher_failure_message_for(submatcher, failure_message_method); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#392 + def column_type; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#396 + def columns_hash; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#505 + def comparison_descriptions; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#409 + def comparison_matcher_for(value, operator); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#470 + def failure_message_for_first_submatcher_that_fails_to_match; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#477 + def failure_message_for_first_submatcher_that_fails_to_not_match; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#456 + def first_submatcher_that_fails_to_match; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#463 + def first_submatcher_that_fails_to_not_match; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#448 + def has_been_qualified?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#526 + def non_numeric_value; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#440 + def number_of_submatchers_for_failure_message; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#404 + def prepare_submatcher(submatcher); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#420 + def qualify_submatchers; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#514 + def submatcher_comparison_descriptions; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#452 + def submatcher_qualified?(submatcher); end +end + +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#284 +Shoulda::Matchers::ActiveModel::ValidateComparisonOfMatcher::DEFAULT_DIFF_TO_COMPARE = T.let(T.unsafe(nil), Integer) + +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_comparison_of_matcher.rb#283 +Shoulda::Matchers::ActiveModel::ValidateComparisonOfMatcher::NUMERIC_NAME = T.let(T.unsafe(nil), String) + # @private # # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_confirmation_of_matcher.rb#80 @@ -5461,503 +5983,502 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#272 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#273 class Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher < ::Shoulda::Matchers::ActiveModel::ValidationMatcher # @return [ValidateInclusionOfMatcher] a new instance of ValidateInclusionOfMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#293 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#294 def initialize(attribute); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#316 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#317 def allow_nil; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#385 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#386 def does_not_match?(subject); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#321 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#322 def expects_to_allow_nil?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#304 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#305 def in_array(array); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#309 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#310 def in_range(range); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#370 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#371 def matches?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#352 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#353 def simple_description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#344 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#345 def with_high_message(message); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#335 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#336 def with_low_message(message); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#325 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#326 def with_message(message); end private # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#466 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#479 def allows_all_values_in_array?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#478 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#491 def allows_any_value_outside_of_array?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#458 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#471 def allows_higher_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#430 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#443 def allows_lower_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#450 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#463 def allows_maximum_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#442 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#455 def allows_minimum_value; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#605 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#618 def allows_nil_value?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#571 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#584 def attribute_allows_nil?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#579 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#592 def attribute_column; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#563 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#576 def attribute_type; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#547 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#560 def boolean_outside_values; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#585 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#598 def column_type_to_attribute_type(type); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#499 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#512 def disallows_all_values_outside_of_array?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#472 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#485 def disallows_any_values_in_array?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#462 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#475 def disallows_higher_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#436 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#449 def disallows_lower_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#454 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#467 def disallows_maximum_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#446 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#459 def disallows_minimum_value; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#609 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#622 def disallows_nil_value?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#423 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#436 def does_not_match_for_array?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#409 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#422 def does_not_match_for_range?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#613 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#626 def inspected_array; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#416 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#429 def matches_for_array?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#402 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#415 def matches_for_range?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#528 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#407 + def maximum_range_value; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#403 + def minimum_range_value; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#541 def outside_values; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#593 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#606 def value_to_attribute_type(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#520 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#533 def values_outside_of_array; end end -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#277 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#278 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::ARBITRARY_OUTSIDE_DATE = T.let(T.unsafe(nil), Date) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#278 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#279 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::ARBITRARY_OUTSIDE_DATETIME = T.let(T.unsafe(nil), DateTime) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#276 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#277 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::ARBITRARY_OUTSIDE_DECIMAL = T.let(T.unsafe(nil), BigDecimal) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#275 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#276 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::ARBITRARY_OUTSIDE_INTEGER = T.let(T.unsafe(nil), Integer) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#274 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#275 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::ARBITRARY_OUTSIDE_STRING = T.let(T.unsafe(nil), String) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#279 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#280 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::ARBITRARY_OUTSIDE_TIME = T.let(T.unsafe(nil), Time) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#273 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#274 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::BLANK_VALUES = T.let(T.unsafe(nil), Array) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#280 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#281 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::BOOLEAN_ALLOWS_BOOLEAN_MESSAGE = T.let(T.unsafe(nil), String) -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#286 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#287 Shoulda::Matchers::ActiveModel::ValidateInclusionOfMatcher::BOOLEAN_ALLOWS_NIL_MESSAGE = T.let(T.unsafe(nil), String) # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#268 +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#294 class Shoulda::Matchers::ActiveModel::ValidateLengthOfMatcher < ::Shoulda::Matchers::ActiveModel::ValidationMatcher include ::Shoulda::Matchers::ActiveModel::Helpers # @return [ValidateLengthOfMatcher] a new instance of ValidateLengthOfMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#271 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#297 def initialize(attribute); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#326 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#357 def allow_nil; end + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#304 + def as_array; end + # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#359 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#390 def does_not_match?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#278 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#309 def is_at_least(length); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#284 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#315 def is_at_most(length); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#290 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#321 def is_equal_to(length); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#350 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#381 def matches?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#331 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#362 def simple_description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#317 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#348 def with_long_message(message); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#298 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#329 def with_message(message); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#308 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#339 def with_short_message(message); end private # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#449 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#480 def allow_nil_does_not_match?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#445 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#476 def allow_nil_matches?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#409 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#440 def allows_higher_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#453 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#484 def allows_length_of?(length, message); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#390 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#421 def allows_lower_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#435 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#466 def allows_maximum_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#425 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#456 def allows_minimum_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#417 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#502 + def array_column?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#512 + def association?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#516 + def association_reflection; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#506 + def collection_association?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#448 def disallows_higher_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#457 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#488 def disallows_length_of?(length, message); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#399 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#430 def disallows_lower_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#440 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#471 def disallows_maximum_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#430 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#461 def disallows_minimum_length?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#370 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#401 def expects_to_allow_nil?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#378 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#409 def lower_bound_does_not_match?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#374 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#405 def lower_bound_matches?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#461 - def string_of_length(length); end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#480 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#535 def translated_long_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#465 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#520 def translated_short_message; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#386 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#417 def upper_bound_does_not_match?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#382 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#413 def upper_bound_matches?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_length_of_matcher.rb#492 + def value_of_length(length); end end # @private # # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#360 -class Shoulda::Matchers::ActiveModel::ValidateNumericalityOfMatcher - include ::Shoulda::Matchers::ActiveModel::Qualifiers::IgnoringInterferenceByWriter - +class Shoulda::Matchers::ActiveModel::ValidateNumericalityOfMatcher < ::Shoulda::Matchers::ActiveModel::ValidationMatcher # @return [ValidateNumericalityOfMatcher] a new instance of ValidateNumericalityOfMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#368 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#366 def initialize(attribute); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#398 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#384 def allow_nil; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#505 - def description; end - # Returns the value of attribute diff_to_compare. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#366 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#364 def diff_to_compare; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#483 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#450 def does_not_match?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#419 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#401 def even; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#469 - def expects_custom_validation_message?; end - - # @return [Boolean] - # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#387 - def expects_strict?; end - - # @return [Boolean] - # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#408 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#390 def expects_to_allow_nil?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#509 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#470 def failure_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#516 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#477 def failure_message_when_negated; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#524 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#485 def given_numeric_column?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#436 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#418 def is_equal_to(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#426 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#408 def is_greater_than(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#431 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#413 def is_greater_than_or_equal_to(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#456 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#438 def is_in(range); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#441 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#423 def is_less_than(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#446 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#428 def is_less_than_or_equal_to(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#451 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#433 def is_other_than(value); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#478 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#445 def matches?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#412 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#394 def odd; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#473 - def on(context); end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#391 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#377 def only_integer; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#488 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#455 def simple_description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#382 - def strict; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#463 - def with_message(message); end - private - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#569 - def add_disallow_value_matcher; end + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#515 + def add_disallow_non_numeric_value_matcher; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#589 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#535 def add_submatcher(submatcher); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#553 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#499 def attribute_is_active_record_column?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#671 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#619 def build_submatcher_failure_message_for(submatcher, failure_message_method); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#557 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#503 def column_type; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#561 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#507 def columns_hash; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#696 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#644 def comparison_descriptions; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#583 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#529 def comparison_matcher_for(value, operator); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#657 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#605 def failure_message_for_first_submatcher_that_fails_to_match; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#664 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#612 def failure_message_for_first_submatcher_that_fails_to_not_match; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#643 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#591 def first_submatcher_that_fails_to_match; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#650 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#598 def first_submatcher_that_fails_to_not_match; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#692 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#640 def full_allowed_type; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#636 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#582 def has_been_qualified?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#531 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#492 def matches_or_does_not_match?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#722 - def model; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#726 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#670 def non_numeric_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#628 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#574 def number_of_submatchers_for_failure_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#539 - def overall_failure_message; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#546 - def overall_failure_message_when_negated; end - - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#578 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#524 def prepare_submatcher(submatcher); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#608 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#554 def qualify_submatchers; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#714 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#662 def range_description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#705 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#653 def submatcher_comparison_descriptions; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#586 + def submatcher_qualified?(submatcher); end end # source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_numericality_of_matcher.rb#362 @@ -6197,6 +6718,11 @@ class Shoulda::Matchers::ActiveModel::ValidationMatcher private + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validation_matcher.rb#190 + def array_column?; end + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validation_matcher.rb#186 def blank_values; end @@ -6280,7 +6806,7 @@ class Shoulda::Matchers::ActiveModel::Validator # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#8 def initialize(record, attribute, options = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#36 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#40 def all_formatted_validation_error_messages; end # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#20 @@ -6288,9 +6814,14 @@ class Shoulda::Matchers::ActiveModel::Validator # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#28 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#32 def captured_validation_exception?; end + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#28 + def has_any_errors?; end + # @return [Boolean] # # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#24 @@ -6298,62 +6829,62 @@ class Shoulda::Matchers::ActiveModel::Validator # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#32 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#36 def type_of_message_matched?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#40 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#44 def validation_exception_message; end protected # Returns the value of attribute attribute. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#46 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#50 def attribute; end # Returns the value of attribute context. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#46 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#50 def context; end # Returns the value of attribute record. # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#46 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#50 def record; end private - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#80 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#84 def all_validation_errors; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#76 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#80 def captured_range_error?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#50 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#54 def expects_strict?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#68 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#72 def matched_messages; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#60 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#64 def messages; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#54 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#58 def messages_match?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#92 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#96 def perform_validation; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#84 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#88 def validation_error_messages; end - # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#88 + # source://shoulda-matchers//lib/shoulda/matchers/active_model/validator.rb#92 def validation_result; end end @@ -6595,6 +7126,28 @@ module Shoulda::Matchers::ActiveRecord # with_foreign_key('country_id') # end # + # ##### with_foreign_type + # + # Use `with_foreign_type` to test usage of the `:foreign_type` option. + # + # class Visitor < ActiveRecord::Base + # belongs_to :location, foreign_type: 'facility_type', polymorphic: true + # end + # + # # RSpec + # RSpec.describe Visitor, type: :model do + # it do + # should belong_to(:location). + # with_foreign_type('facility_type') + # end + # end + # + # # Minitest (Shoulda) + # class VisitorTest < ActiveSupport::TestCase + # should belong_to(:location). + # with_foreign_type('facility_type') + # end + # # ##### dependent # # Use `dependent` to assert that the `:dependent` option was specified. @@ -6668,6 +7221,36 @@ module Shoulda::Matchers::ActiveRecord # should belong_to(:organization).touch(true) # end # + # ##### strict_loading + # + # Use `strict_loading` to assert that the `:strict_loading` option was specified. + # + # class Organization < ActiveRecord::Base + # has_many :people, strict_loading: true + # end + # + # # RSpec + # RSpec.describe Organization, type: :model do + # it { should have_many(:people).strict_loading(true) } + # end + # + # # Minitest (Shoulda) + # class OrganizationTest < ActiveSupport::TestCase + # should have_many(:people).strict_loading(true) + # end + # + # Default value is true when no argument is specified + # + # # RSpec + # RSpec.describe Organization, type: :model do + # it { should have_many(:people).strict_loading } + # end + # + # # Minitest (Shoulda) + # class OrganizationTest < ActiveSupport::TestCase + # should have_many(:people).strict_loading + # end + # # ##### autosave # # Use `autosave` to assert that the `:autosave` option was specified. @@ -6773,7 +7356,7 @@ module Shoulda::Matchers::ActiveRecord # # @return [AssociationMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#325 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#377 def belong_to(name); end # The `define_enum_for` matcher is used to test that the `enum` macro has @@ -6962,11 +7545,171 @@ module Shoulda::Matchers::ActiveRecord # without_scopes # end # + # ##### with_default + # + # Use `with_default` to test that the enum is defined with a + # default value. A proc can also be passed, and will be called once each + # time a new value is needed. (If using Time or Date, it's recommended to + # freeze time or date to avoid flaky tests): + # + # class Issue < ActiveRecord::Base + # enum status: [:open, :closed], default: :closed + # end + # + # # RSpec + # RSpec.describe Issue, type: :model do + # it do + # should define_enum_for(:status). + # with_default(:closed) + # end + # end + # + # # Minitest (Shoulda) + # class ProcessTest < ActiveSupport::TestCase + # should define_enum_for(:status). + # with_default(:closed) + # end + # + # ##### validating + # + # Use `validating` to test that the enum is being validated. + # Can take a boolean value and an allowing_nil keyword argument: + # + # class Issue < ActiveRecord::Base + # enum status: [:open, :closed], validate: true + # end + # + # # RSpec + # RSpec.describe Issue, type: :model do + # it do + # should define_enum_for(:status). + # validating + # end + # end + # + # # Minitest (Shoulda) + # class ProcessTest < ActiveSupport::TestCase + # should define_enum_for(:status). + # validating + # end + # + # class Issue < ActiveRecord::Base + # enum status: [:open, :closed], validate: { allow_nil: true } + # end + # + # # RSpec + # RSpec.describe Issue, type: :model do + # it do + # should define_enum_for(:status). + # validating(allowing_nil: true) + # end + # end + # + # # Minitest (Shoulda) + # class ProcessTest < ActiveSupport::TestCase + # should define_enum_for(:status). + # validating(allowing_nil: true) + # end + # + # ##### without_instance_methods + # + # Use `without_instance_methods` to exclude the check for instance methods. + # + # class Issue < ActiveRecord::Base + # enum status: [:open, :closed], instance_methods: false + # end + # + # # RSpec + # RSpec.describe Issue, type: :model do + # it do + # should define_enum_for(:status). + # without_instance_methods + # end + # end + # + # # Minitest (Shoulda) + # class ProcessTest < ActiveSupport::TestCase + # should define_enum_for(:status). + # without_instance_methods + # end + # # @return [DefineEnumForMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#192 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#279 def define_enum_for(attribute_name); end + # The `encrypt` matcher tests usage of the + # `encrypts` macro (Rails 7+ only). + # + # class Survey < ActiveRecord::Base + # encrypts :access_code + # end + # + # # RSpec + # RSpec.describe Survey, type: :model do + # it { should encrypt(:access_code) } + # end + # + # # Minitest (Shoulda) + # class SurveyTest < ActiveSupport::TestCase + # should encrypt(:access_code) + # end + # + # #### Qualifiers + # + # ##### deterministic + # + # class Survey < ActiveRecord::Base + # encrypts :access_code, deterministic: true + # end + # + # # RSpec + # RSpec.describe Survey, type: :model do + # it { should encrypt(:access_code).deterministic(true) } + # end + # + # # Minitest (Shoulda) + # class SurveyTest < ActiveSupport::TestCase + # should encrypt(:access_code).deterministic(true) + # end + # + # ##### downcase + # + # class Survey < ActiveRecord::Base + # encrypts :access_code, downcase: true + # end + # + # # RSpec + # RSpec.describe Survey, type: :model do + # it { should encrypt(:access_code).downcase(true) } + # end + # + # # Minitest (Shoulda) + # class SurveyTest < ActiveSupport::TestCase + # should encrypt(:access_code).downcase(true) + # end + # + # ##### ignore_case + # + # class Survey < ActiveRecord::Base + # encrypts :access_code, deterministic: true, ignore_case: true + # end + # + # # RSpec + # RSpec.describe Survey, type: :model do + # it { should encrypt(:access_code).ignore_case(true) } + # end + # + # # Minitest (Shoulda) + # class SurveyTest < ActiveSupport::TestCase + # should encrypt(:access_code).ignore_case(true) + # end + # + # @return [EncryptMatcher] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#73 + def encrypt(value); end + # The `have_and_belong_to_many` matcher is used to test that a # `has_and_belongs_to_many` association exists on your model and that the # join table exists in the database. @@ -7121,7 +7864,7 @@ module Shoulda::Matchers::ActiveRecord # # @return [AssociationMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#982 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1380 def have_and_belong_to_many(name); end # The `have_db_column` matcher tests that the table that backs your model @@ -7171,6 +7914,30 @@ module Shoulda::Matchers::ActiveRecord # should have_db_column(:camera_aperture).of_type(:decimal) # end # + # ##### of_sql_type + # + # Use `of_sql_type` to assert that a column is defined as a certain sql_type. + # + # class CreatePhones < ActiveRecord::Migration + # def change + # create_table :phones do |t| + # t.string :camera_aperture, limit: 36 + # end + # end + # end + # + # # RSpec + # RSpec.describe Phone, type: :model do + # it do + # should have_db_column(:camera_aperture).of_sql_type('varchar(36)') + # end + # end + # + # # Minitest (Shoulda) + # class PhoneTest < ActiveSupport::TestCase + # should have_db_column(:camera_aperture).of_sql_type('varchar(36)') + # end + # # ##### with_options # # Use `with_options` to assert that a column has been defined with @@ -7201,7 +7968,7 @@ module Shoulda::Matchers::ActiveRecord # # @return [HaveDbColumnMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#81 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#105 def have_db_column(column); end # The `have_db_index` matcher tests that the table that backs your model @@ -7313,27 +8080,354 @@ module Shoulda::Matchers::ActiveRecord # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#110 def have_db_index(columns); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#24 - def have_implicit_order_column(column_name); end - - # The `have_many` matcher is used to test that a `has_many` or `has_many - # :through` association exists on your model. + # The `have_delegated_type` matcher is used to ensure that a `belong_to` association + # exists on your model using the delegated_type macro. # - # class Person < ActiveRecord::Base - # has_many :friends + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck) # end # # # RSpec - # RSpec.describe Person, type: :model do - # it { should have_many(:friends) } + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable) } # end # # # Minitest (Shoulda) - # class PersonTest < ActiveSupport::TestCase - # should have_many(:friends) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable) # end # - # Note that polymorphic associations are automatically detected and do not + # #### Qualifiers + # + # ##### types + # + # Use `types` to test the types that are allowed for the association. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck) + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it do + # should have_delegated_type(:drivable). + # types(%w(Car Truck)) + # end + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable). + # types(%w(Car Truck)) + # end + # + # ##### conditions + # + # Use `conditions` if your association is defined with a scope that sets + # the `where` clause. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), scope: -> { where(with_wheels: true) } + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it do + # should have_delegated_type(:drivable). + # conditions(with_wheels: true) + # end + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable). + # conditions(everyone_is_perfect: false) + # end + # + # ##### order + # + # Use `order` if your association is defined with a scope that sets the + # `order` clause. + # + # class Person < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), scope: -> { order('wheels desc') } + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable).order('wheels desc') } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).order('wheels desc') + # end + # + # ##### with_primary_key + # + # Use `with_primary_key` to test usage of the `:primary_key` option. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), primary_key: 'vehicle_id' + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it do + # should have_delegated_type(:drivable). + # with_primary_key('vehicle_id') + # end + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable). + # with_primary_key('vehicle_id') + # end + # + # ##### with_foreign_key + # + # Use `with_foreign_key` to test usage of the `:foreign_key` option. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), foreign_key: 'drivable_uuid' + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it do + # should have_delegated_type(:drivable). + # with_foreign_key('drivable_uuid') + # end + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable). + # with_foreign_key('drivable_uuid') + # end + # + # ##### dependent + # + # Use `dependent` to assert that the `:dependent` option was specified. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), dependent: :destroy + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable).dependent(:destroy) } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).dependent(:destroy) + # end + # + # To assert that *any* `:dependent` option was specified, use `true`: + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable).dependent(true) } + # end + # + # To assert that *no* `:dependent` option was specified, use `false`: + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck) + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable).dependent(false) } + # end + # + # ##### counter_cache + # + # Use `counter_cache` to assert that the `:counter_cache` option was + # specified. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), counter_cache: true + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable).counter_cache(true) } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).counter_cache(true) + # end + # + # ##### touch + # + # Use `touch` to assert that the `:touch` option was specified. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), touch: true + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable).touch(true) } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).touch(true) + # end + # + # ##### autosave + # + # Use `autosave` to assert that the `:autosave` option was specified. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), autosave: true + # end + # + # # RSpec + # RSpec.describe Vehicle, type: :model do + # it { should have_delegated_type(:drivable).autosave(true) } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).autosave(true) + # end + # + # ##### inverse_of + # + # Use `inverse_of` to assert that the `:inverse_of` option was specified. + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), inverse_of: :vehicle + # end + # + # # RSpec + # describe Vehicle + # it { should have_delegated_type(:drivable).inverse_of(:vehicle) } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).inverse_of(:vehicle) + # end + # + # ##### required + # + # Use `required` to assert that the association is not allowed to be nil. + # (Enabled by default in Rails 5+.) + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), required: true + # end + # + # # RSpec + # describe Vehicle + # it { should have_delegated_type(:drivable).required } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).required + # end + # + # ##### without_validating_presence + # + # Use `without_validating_presence` with `belong_to` to prevent the + # matcher from checking whether the association disallows nil (Rails 5+ + # only). This can be helpful if you have a custom hook that always sets + # the association to a meaningful value: + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck) + # + # before_validation :autoassign_drivable + # + # private + # + # def autoassign_drivable + # self.drivable = Car.create! + # end + # end + # + # # RSpec + # describe Vehicle + # it { should have_delegated_type(:drivable).without_validating_presence } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).without_validating_presence + # end + # + # ##### optional + # + # Use `optional` to assert that the association is allowed to be nil. + # (Rails 5+ only.) + # + # class Vehicle < ActiveRecord::Base + # delegated_type :drivable, types: %w(Car Truck), optional: true + # end + # + # # RSpec + # describe Vehicle + # it { should have_delegated_type(:drivable).optional } + # end + # + # # Minitest (Shoulda) + # class VehicleTest < ActiveSupport::TestCase + # should have_delegated_type(:drivable).optional + # end + # + # @return [AssociationMatcher] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#687 + def have_delegated_type(name); end + + # The `have_implicit_order_column` matcher tests that the model has `implicit_order_column` + # assigned to one of the table columns. + # + # class Product < ApplicationRecord + # self.implicit_order_column = :created_at + # end + # + # # RSpec + # RSpec.describe Product, type: :model do + # it { should have_implicit_order_column(:created_at) } + # end + # + # # Minitest (Shoulda) + # class ProductTest < ActiveSupport::TestCase + # should have_implicit_order_column(:created_at) + # end + # + # @return [HaveImplicitOrderColumnMatcher] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#23 + def have_implicit_order_column(column_name); end + + # The `have_many` matcher is used to test that a `has_many` or `has_many + # :through` association exists on your model. + # + # class Person < ActiveRecord::Base + # has_many :friends + # end + # + # # RSpec + # RSpec.describe Person, type: :model do + # it { should have_many(:friends) } + # end + # + # # Minitest (Shoulda) + # class PersonTest < ActiveSupport::TestCase + # should have_many(:friends) + # end + # + # Note that polymorphic associations are automatically detected and do not # need any qualifiers: # # class Person < ActiveRecord::Base @@ -7445,6 +8539,24 @@ module Shoulda::Matchers::ActiveRecord # should have_many(:worries).with_foreign_key('worrier_id') # end # + # ##### with_foreign_type + # + # Use `with_foreign_type` to test usage of the `:foreign_type` option. + # + # class Hotel < ActiveRecord::Base + # has_many :visitors, foreign_key: 'facility_type', as: :location + # end + # + # # RSpec + # RSpec.describe Hotel, type: :model do + # it { should have_many(:visitors).with_foreign_type('facility_type') } + # end + # + # # Minitest (Shoulda) + # class HotelTest < ActiveSupport::TestCase + # should have_many(:visitors).with_foreign_type('facility_type') + # end + # # ##### dependent # # Use `dependent` to assert that the `:dependent` option was specified. @@ -7582,7 +8694,7 @@ module Shoulda::Matchers::ActiveRecord # # @return [AssociationMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#595 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#975 def have_many(name); end # The `have_many_attached` matcher tests usage of the @@ -7739,6 +8851,24 @@ module Shoulda::Matchers::ActiveRecord # should have_one(:job).with_foreign_key('worker_id') # end # + # ##### with_foreign_type + # + # Use `with_foreign_type` to test usage of the `:foreign_type` option. + # + # class Hotel < ActiveRecord::Base + # has_one :special_guest, foreign_type: 'facility_type', as: :location + # end + # + # # RSpec + # RSpec.describe Hotel, type: :model do + # it { should have_one(:special_guest).with_foreign_type('facility_type') } + # end + # + # # Minitest (Shoulda) + # class HotelTest < ActiveSupport::TestCase + # should have_one(:special_guest).with_foreign_type('facility_type') + # end + # # ##### through # # Use `through` to test usage of the `:through` option. This asserts that @@ -7834,7 +8964,7 @@ module Shoulda::Matchers::ActiveRecord # # @return [AssociationMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#824 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1222 def have_one(name); end # The `have_one_attached` matcher tests usage of the @@ -7898,60 +9028,127 @@ module Shoulda::Matchers::ActiveRecord # end # # # Minitest (Shoulda) - # class PostTest < ActiveSupport::TestCase - # should have_rich_text(:content) + # class PostTest < ActiveSupport::TestCase + # should have_rich_text(:content) + # end + # + # @return [HaveRichTextMatcher] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_rich_text_matcher.rb#25 + def have_rich_text(rich_text_attribute); end + + # The `have_secure_token` matcher tests usage of the + # `has_secure_token` macro. + # + # class User < ActiveRecord + # has_secure_token + # has_secure_token :auth_token + # end + # + # # RSpec + # RSpec.describe User, type: :model do + # it { should have_secure_token } + # it { should have_secure_token(:auth_token) } + # end + # + # # Minitest (Shoulda) + # class UserTest < ActiveSupport::TestCase + # should have_secure_token + # should have_secure_token(:auth_token) + # end + # + # #### Qualifiers + # + # ##### ignoring_check_for_db_index + # + # By default, this matcher tests that an index is defined on your token + # column. Use `ignoring_check_for_db_index` if this is not the case. + # + # class User < ActiveRecord + # has_secure_token :auth_token + # end + # + # # RSpec + # RSpec.describe User, type: :model do + # it { should have_secure_token(:auth_token).ignoring_check_for_db_index } + # end + # + # # Minitest (Shoulda) + # class UserTest < ActiveSupport::TestCase + # should have_secure_token(:auth_token).ignoring_check_for_db_index + # end + # + # @return [HaveSecureToken] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_secure_token_matcher.rb#47 + def have_secure_token(token_attribute = T.unsafe(nil)); end + + # The `normalize` matcher is used to ensure attribute normalizations + # are transforming attribute values as expected. + # + # Take this model for example: + # + # class User < ActiveRecord::Base + # normalizes :email, with: -> email { email.strip.downcase } + # end + # + # You can use `normalize` providing an input and defining the expected + # normalization output: + # + # # RSpec + # RSpec.describe User, type: :model do + # it do + # should normalize(:email).from(" ME@XYZ.COM\n").to("me@xyz.com") + # end + # end + # + # # Minitest (Shoulda) + # class User < ActiveSupport::TestCase + # should normalize(:email).from(" ME@XYZ.COM\n").to("me@xyz.com") # end # - # @return [HaveRichTextMatcher] - # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_rich_text_matcher.rb#25 - def have_rich_text(rich_text_attribute); end - - # The `have_secure_token` matcher tests usage of the - # `has_secure_token` macro. + # You can use `normalize` to test multiple attributes at once: # - # class User < ActiveRecord - # has_secure_token - # has_secure_token :auth_token + # class User < ActiveRecord::Base + # normalizes :email, :handle, with: -> value { value.strip.downcase } # end # # # RSpec # RSpec.describe User, type: :model do - # it { should have_secure_token } - # it { should have_secure_token(:auth_token) } + # it do + # should normalize(:email, :handle).from(" Example\n").to("example") + # end # end # # # Minitest (Shoulda) - # class UserTest < ActiveSupport::TestCase - # should have_secure_token - # should have_secure_token(:auth_token) + # class User < ActiveSupport::TestCase + # should normalize(:email, :handle).from(" Example\n").to("example") # end # - # #### Qualifiers - # - # ##### ignoring_check_for_db_index - # - # By default, this matcher tests that an index is defined on your token - # column. Use `ignoring_check_for_db_index` if this is not the case. + # If the normalization accepts nil values with the `apply_to_nil` option, + # you just need to use `.from(nil).to("Your expected value here")`. # - # class User < ActiveRecord - # has_secure_token :auth_token + # class User < ActiveRecord::Base + # normalizes :name, with: -> name { name&.titleize || 'Untitled' }, + # apply_to_nil: true # end # # # RSpec # RSpec.describe User, type: :model do - # it { should have_secure_token(:auth_token).ignoring_check_for_db_index } + # it { should normalize(:name).from("jane doe").to("Jane Doe") } + # it { should normalize(:name).from(nil).to("Untitled") } # end # # # Minitest (Shoulda) - # class UserTest < ActiveSupport::TestCase - # should have_secure_token(:auth_token).ignoring_check_for_db_index + # class User < ActiveSupport::TestCase + # should normalize(:name).from("jane doe").to("Jane Doe") + # should normalize(:name).from(nil).to("Untitled") # end # - # @return [HaveSecureToken] + # @return [NormalizeMatcher] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_secure_token_matcher.rb#47 - def have_secure_token(token_attribute = T.unsafe(nil)); end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#68 + def normalize(*attributes); end # The `serialize` matcher tests usage of the `serialize` macro. # @@ -8375,286 +9572,354 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#987 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1385 class Shoulda::Matchers::ActiveRecord::AssociationMatcher # @return [AssociationMatcher] a new instance of AssociationMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1000 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1398 def initialize(macro, name); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#995 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1393 def associated_class(*_arg0, **_arg1, &_arg2); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1071 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1474 def autosave(autosave); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1081 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1484 def class_name(class_name); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1066 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1464 def conditions(conditions); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1039 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1437 def counter_cache(counter_cache = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1021 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1419 def dependent(dependent); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1136 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1554 def description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1144 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1562 def failure_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1148 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1566 def failure_message_when_negated; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1076 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1479 def index_errors(index_errors); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1048 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1446 def inverse_of(inverse_of); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1126 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1544 def join_table(join_table_name); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1170 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1592 def join_table_name; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1152 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1570 def matches?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#995 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1393 def model_class(*_arg0, **_arg1, &_arg2); end # Returns the value of attribute name. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#998 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1396 def name; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1174 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1596 def option_verifier; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1106 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1519 def optional(optional = T.unsafe(nil)); end # Returns the value of attribute options. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#998 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1396 def options; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1030 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1428 def order(order); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#995 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1393 def polymorphic?(*_arg0, **_arg1, &_arg2); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#995 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1393 def reflection(*_arg0, **_arg1, &_arg2); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1096 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1509 def required(required = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1057 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1455 def source(source); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1012 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1539 + def strict_loading(strict_loading = T.unsafe(nil)); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1410 def through(through); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#995 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1393 def through?(*_arg0, **_arg1, &_arg2); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1121 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1534 def touch(touch = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1116 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1469 + def types(types); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1529 def validate(validate = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1086 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1489 def with_foreign_key(foreign_key); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1091 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1494 + def with_foreign_type(foreign_type); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1499 def with_primary_key(primary_key); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1131 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1504 + def with_query_constraints(query_constraints); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1549 def without_validating_presence; end protected - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1447 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1968 def actual_foreign_key; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1187 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1609 def add_submatcher(matcher_class, *args); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1232 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1654 def association_exists?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1328 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1783 def autosave_correct?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1274 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1724 def belongs_foreign_key_missing?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1483 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1728 + def belongs_foreign_type_missing?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#2011 def belongs_to_required_by_default?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1320 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1775 def class_exists?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1396 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1890 def class_has_foreign_key?(klass); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1284 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1904 + def class_has_foreign_type?(klass); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1742 def class_name_correct?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1477 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#2005 def column_names_for(klass); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1361 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1816 def conditions_correct?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1202 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1624 def expectation; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1218 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1640 def failing_submatchers; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1419 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1929 def foreign_key_correct?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1266 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1691 def foreign_key_exists?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1426 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1943 def foreign_key_failure_message(klass, foreign_key); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1459 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1980 def foreign_key_reflection; end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1993 + def foreign_type; end + # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1410 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1936 + def foreign_type_correct?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1947 + def foreign_type_failure_message(klass, foreign_type); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1695 + def foreign_type_matches?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1687 + def has_association_not_through?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1920 def has_column?(klass, column); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1278 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1732 def has_foreign_key_missing?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1345 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1737 + def has_foreign_type_missing?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1800 def index_errors_correct?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1301 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1759 def join_table_correct?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1313 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1768 def join_table_matcher; end # Returns the value of attribute macro. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1181 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1603 def macro; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1241 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1663 def macro_correct?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1198 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1620 def macro_description; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1261 - def macro_supports_primary_key?; end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1683 + def macro_is_not_through?; end # Returns the value of attribute missing. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1181 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1603 def missing; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1213 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1635 def missing_options; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1224 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1646 def missing_options_for_failing_submatchers; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1430 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1951 def primary_key_correct?(klass); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1270 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1702 def primary_key_exists?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1183 + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1710 + def query_constraints_correct?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1706 + def query_constraints_exists?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1605 def reflector; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1192 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1614 def remove_submatcher(matcher_class); end + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1875 + def strict_loading_correct?; end + # Returns the value of attribute subject. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1181 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1603 def subject; end # Returns the value of attribute submatchers. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1181 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1603 def submatchers; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1473 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#2001 def submatchers_match?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1387 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1842 def touch_correct?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1378 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1851 + def types_correct?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1833 def validate_correct?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1402 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1896 def validate_foreign_key(klass); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1253 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1675 def validate_inverse_of_through_association; end end -# source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#988 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matcher.rb#1386 Shoulda::Matchers::ActiveRecord::AssociationMatcher::MACROS = T.let(T.unsafe(nil), Hash) # @private @@ -8999,52 +10264,57 @@ class Shoulda::Matchers::ActiveRecord::AssociationMatchers::ModelReflection < :: # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#15 def associated_class; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#54 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#58 def association_foreign_key; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#33 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#37 def association_relation(related_instance); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#44 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#48 def foreign_key; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#69 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#73 def has_and_belongs_to_many_name; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#27 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#31 def join_table_name; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#19 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#23 def polymorphic?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#23 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#77 + def strict_loading?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#27 def through?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#63 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#67 def validate_inverse_of_through_association!; end protected # Returns the value of attribute reflection. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#75 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#83 def reflection; end # Returns the value of attribute subject. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#75 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#83 def subject; end private - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#79 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#87 def has_and_belongs_to_many_name_table_name; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#83 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflection.rb#91 def has_and_belongs_to_many_reflection; end end @@ -9054,7 +10324,7 @@ end class Shoulda::Matchers::ActiveRecord::AssociationMatchers::ModelReflector # @return [ModelReflector] a new instance of ModelReflector # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#24 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#25 def initialize(subject, name); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 @@ -9063,37 +10333,40 @@ class Shoulda::Matchers::ActiveRecord::AssociationMatchers::ModelReflector # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 def association_foreign_key(*_arg0, **_arg1, &_arg2); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#29 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#30 def association_relation; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#49 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#50 def build_relation_with_clause(name, value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#60 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#61 def extract_relation_clause_from(relation, name); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 def foreign_key(*_arg0, **_arg1, &_arg2); end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 + def foreign_type(*_arg0, **_arg1, &_arg2); end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 def has_and_belongs_to_many_name(*_arg0, **_arg1, &_arg2); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 def join_table_name(*_arg0, **_arg1, &_arg2); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#45 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#46 def model_class; end # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 def polymorphic?(*_arg0, **_arg1, &_arg2); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#37 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#38 def reflect_on_association(name); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#33 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#34 def reflection; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#18 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#19 def through?(*_arg0, **_arg1, &_arg2); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#7 @@ -9103,15 +10376,15 @@ class Shoulda::Matchers::ActiveRecord::AssociationMatchers::ModelReflector # Returns the value of attribute name. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#75 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#76 def name; end # Returns the value of attribute subject. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#75 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#76 def subject; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#77 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/model_reflector.rb#78 def value_as_sql(value); end end @@ -9165,12 +10438,15 @@ class Shoulda::Matchers::ActiveRecord::AssociationMatchers::OptionVerifier # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/option_verifier.rb#121 def actual_value_for_class_name; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/option_verifier.rb#125 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/option_verifier.rb#129 def actual_value_for_option(name); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/option_verifier.rb#114 def actual_value_for_relation_clause(name); end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/option_verifier.rb#125 + def actual_value_for_strict_loading; end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/option_verifier.rb#85 def expected_value_for(type, name, value); end @@ -9221,22 +10497,25 @@ class Shoulda::Matchers::ActiveRecord::AssociationMatchers::OptionalMatcher # Returns the value of attribute attribute_name. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#56 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#33 def attribute_name; end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#43 + def build_missing_option; end + # Returns the value of attribute optional. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#56 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#33 def optional; end # Returns the value of attribute submatcher. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#56 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#33 def submatcher; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#58 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/optional_matcher.rb#35 def submatcher_passes?(subject); end end @@ -9337,25 +10616,28 @@ class Shoulda::Matchers::ActiveRecord::AssociationMatchers::RequiredMatcher # Returns the value of attribute attribute_name. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#57 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#34 def attribute_name; end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#48 + def build_missing_option; end + # Returns the value of attribute required. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#57 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#34 def required; end # Returns the value of attribute submatcher. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#57 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#34 def submatcher; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#59 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#36 def submatcher_passes?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#67 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/association_matchers/required_matcher.rb#44 def validation_message_key; end end @@ -9521,160 +10803,261 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#197 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#284 class Shoulda::Matchers::ActiveRecord::DefineEnumForMatcher # @return [DefineEnumForMatcher] a new instance of DefineEnumForMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#198 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#285 def initialize(attribute_name); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#248 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#333 def backed_by_column_of_type(expected_column_type); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#203 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#290 def description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#268 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#365 def failure_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#281 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#378 def failure_message_when_negated; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#258 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#353 def matches?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#230 - def with(expected_enum_values); end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#312 + def validating(value = T.unsafe(nil), allowing_nil: T.unsafe(nil)); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#348 + def with_default(default_value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#238 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#323 def with_prefix(expected_prefix = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#243 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#328 def with_suffix(expected_suffix = T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#225 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#318 def with_values(expected_enum_values); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#253 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#343 + def without_instance_methods; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#338 def without_scopes; end private - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#367 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#657 + def actual_default_value; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#503 def actual_enum_values; end # Returns the value of attribute attribute_name. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#288 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#409 def attribute_name; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#412 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#548 def column; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#396 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#532 def column_type_matches?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#371 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#633 + def default_value_matches?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#507 def enum_defined?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#423 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#559 def enum_value_methods_exist?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#381 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#517 def enum_values_match?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#540 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#743 def exclude_scopes?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#291 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#412 def expectation; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#408 + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#731 + def expected_allowing_nil?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#544 def expected_column_type; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#355 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#653 + def expected_default_value; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#491 def expected_enum_value_names; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#359 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#495 def expected_enum_values; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#508 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#691 def expected_instance_methods; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#520 + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#703 + def expected_instance_methods?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#707 def expected_prefix; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#499 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#682 def expected_singleton_methods; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#530 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#717 def expected_suffix; end + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#727 + def expected_validating?; end + # Returns the value of attribute failure_message_continuation. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#288 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#409 def failure_message_continuation; end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#735 + def find_enum_validator; end + # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#493 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#676 def instance_methods_exist?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#467 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#611 def missing_methods_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#419 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#555 def model; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#363 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#499 def normalized_actual_enum_values; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#351 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#487 def normalized_expected_enum_values; end # Returns the value of attribute options. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#288 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#409 def options; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#341 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#477 def presented_enum_mapping(enum_values); end # Returns the value of attribute record. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#288 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#409 def record; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#437 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#581 def scope_presence_matches?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#337 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#473 def simple_description; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#487 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#670 def singleton_methods_exist?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#554 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#757 def to_array(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#544 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#747 def to_hash(value); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/define_enum_for_matcher.rb#385 + def validating_matches?; end +end + +# @private +# +# source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#78 +class Shoulda::Matchers::ActiveRecord::EncryptMatcher + # @return [EncryptMatcher] a new instance of EncryptMatcher + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#79 + def initialize(attribute); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#125 + def description; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#86 + def deterministic(deterministic); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#90 + def downcase(downcase); end + + # Returns the value of attribute failure_message. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#84 + def failure_message; end + + # Returns the value of attribute failure_message_when_negated. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#84 + def failure_message_when_negated; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#94 + def ignore_case(ignore_case); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#98 + def matches?(subject); end + + private + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#168 + def class_name; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#164 + def encrypted_attribute_scheme; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#160 + def encrypted_attributes; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#131 + def encrypted_attributes_included?; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#145 + def options_correct?(*opts); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/encrypt_matcher.rb#140 + def with_option(option_name, value); end end # @private @@ -9763,127 +11146,135 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#86 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#110 class Shoulda::Matchers::ActiveRecord::HaveDbColumnMatcher # @return [HaveDbColumnMatcher] a new instance of HaveDbColumnMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#89 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#113 def initialize(column); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#130 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#160 def description; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#122 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#152 def failure_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#126 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#156 def failure_message_when_negated; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#109 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#138 def matches?(subject); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#94 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#123 + def of_sql_type(sql_column_type); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#118 def of_type(column_type); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#99 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#128 def with_options(opts = T.unsafe(nil)); end protected # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#296 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#336 def actual_primary?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#292 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#332 def actual_scale; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#158 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#185 def column_exists?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#262 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#302 def correct_array?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#168 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#195 def correct_column_type?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#207 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#247 def correct_default?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#194 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#234 def correct_limit?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#220 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#260 def correct_null?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#181 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#221 def correct_precision?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#245 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#285 def correct_primary?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#233 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#273 def correct_scale?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#300 + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#208 + def correct_sql_column_type?; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#340 def expectation; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#279 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#319 def matched_column; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#288 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#328 def model_class; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#148 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#175 def validate_options(opts); end end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#305 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#345 class Shoulda::Matchers::ActiveRecord::HaveDbColumnMatcher::DecoratedColumn < ::SimpleDelegator # @return [DecoratedColumn] a new instance of DecoratedColumn # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#306 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#346 def initialize(model, column); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#315 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#355 def primary?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#311 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#351 def type_cast_default; end protected # Returns the value of attribute model. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#321 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#361 def model; end end -# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#87 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_column_matcher.rb#111 Shoulda::Matchers::ActiveRecord::HaveDbColumnMatcher::OPTIONS = T.let(T.unsafe(nil), Array) # @private @@ -9914,15 +11305,12 @@ class Shoulda::Matchers::ActiveRecord::HaveDbIndexMatcher private - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#210 - def actual_indexes; end - # @return [Boolean] # # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#181 def correct_unique?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#214 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#225 def described_table_name; end # Returns the value of attribute expected_columns. @@ -9930,7 +11318,7 @@ class Shoulda::Matchers::ActiveRecord::HaveDbIndexMatcher # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#171 def expected_columns; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#260 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#271 def formatted_expected_columns; end # @return [Boolean] @@ -9938,25 +11326,25 @@ class Shoulda::Matchers::ActiveRecord::HaveDbIndexMatcher # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#177 def index_exists?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#252 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#263 def index_type; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#244 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#255 def inspected_expected_columns; end # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#197 def matched_index; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#270 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#281 def model; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#240 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#251 def negative_expectation; end # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#173 def normalize_columns_to_array(columns); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#226 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#237 def positive_expectation; end # Returns the value of attribute qualifiers. @@ -9969,69 +11357,75 @@ class Shoulda::Matchers::ActiveRecord::HaveDbIndexMatcher # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#171 def reason; end + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#210 + def sorted_indexes; end + # Returns the value of attribute subject. # # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#171 def subject; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#222 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#233 def table_name; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_db_index_matcher.rb#221 + def unsorted_indexes; end end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#30 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#28 class Shoulda::Matchers::ActiveRecord::HaveImplicitOrderColumnMatcher # @return [HaveImplicitOrderColumnMatcher] a new instance of HaveImplicitOrderColumnMatcher # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#33 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#31 def initialize(column_name); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#61 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#59 def description; end # Returns the value of attribute failure_message. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#31 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#29 def failure_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#55 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#53 def failure_message_when_negated; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#37 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#35 def matches?(subject); end private - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#69 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#67 def check_column_exists!; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#80 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#78 def check_implicit_order_column_matches!; end # Returns the value of attribute column_name. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#67 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#65 def column_name; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#97 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#95 def expectation; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#93 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#91 def model; end # Returns the value of attribute subject. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#67 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#65 def subject; end end -# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#102 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#100 class Shoulda::Matchers::ActiveRecord::HaveImplicitOrderColumnMatcher::PrimaryCheckFailedError < ::StandardError; end -# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#101 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/have_implicit_order_column.rb#99 class Shoulda::Matchers::ActiveRecord::HaveImplicitOrderColumnMatcher::SecondaryCheckFailedError < ::StandardError; end # @private @@ -10185,6 +11579,83 @@ class Shoulda::Matchers::ActiveRecord::HaveSecureTokenMatcher def table_name; end end +# @private +# +# source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#77 +class Shoulda::Matchers::ActiveRecord::NormalizeMatcher + # @return [NormalizeMatcher] a new instance of NormalizeMatcher + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#81 + def initialize(*attributes); end + + # Returns the value of attribute attributes. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#78 + def attributes; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#85 + def description; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#108 + def does_not_match?(subject); end + + # Returns the value of attribute failure_message. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#78 + def failure_message; end + + # Returns the value of attribute failure_message_when_negated. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#78 + def failure_message_when_negated; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#92 + def from(value); end + + # Returns the value of attribute from_value. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#78 + def from_value; end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#104 + def matches?(subject); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#98 + def to(value); end + + # Returns the value of attribute to_value. + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#78 + def to_value; end + + private + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#124 + def attribute_does_not_match?(subject, attribute); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#114 + def attribute_matches?(subject, attribute); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#135 + def build_failure_message(attribute, attribute_value); end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#142 + def build_failure_message_when_negated(attribute); end + + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/active_record/normalize_matcher.rb#131 + def normalize_attribute?(subject, attribute); end +end + # @private # # source://shoulda-matchers//lib/shoulda/matchers/active_record/serialize_matcher.rb#93 @@ -10279,19 +11750,19 @@ class Shoulda::Matchers::ActiveRecord::Uniqueness::Model # source://shoulda-matchers//lib/shoulda/matchers/active_record/uniqueness/model.rb#31 def symlink_to(parent); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/uniqueness/model.rb#35 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/uniqueness/model.rb#47 def to_s; end protected # Returns the value of attribute name. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/uniqueness/model.rb#41 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/uniqueness/model.rb#53 def name; end # Returns the value of attribute namespace. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/uniqueness/model.rb#41 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/uniqueness/model.rb#53 def namespace; end class << self @@ -10450,187 +11921,190 @@ class Shoulda::Matchers::ActiveRecord::ValidateUniquenessOfMatcher < ::Shoulda:: private - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#485 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#503 def actual_sets_of_scopes; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#836 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#850 def all_scopes_are_booleans?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#561 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#579 def arbitrary_non_blank_value; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#980 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#992 def attribute_changed_value_message; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#899 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#913 def attribute_names_under_test; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#610 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#628 def attribute_present_on_model?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1028 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1040 def attribute_setter_descriptions_for_new_record; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#890 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#904 def attribute_setter_for_existing_record; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#894 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#908 def attribute_setters_for_new_record; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#855 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#869 def available_enum_values_for(scope, previous_value); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#842 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#856 def boolean_value?(value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#903 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#917 def build_attribute_setter(record, attribute_name, value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#577 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#434 + def build_failure_reason; end + + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#595 def build_new_record; end # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#380 def case_sensitivity_strategy; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#926 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#940 def column_for(scope); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#930 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#944 def column_limit_for(attribute); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#542 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#560 def create_existing_record; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#846 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#860 def defined_as_enum?(scope); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#995 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1007 def description_for_attribute_setter(attribute_setter, same_as_existing: T.unsafe(nil)); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#393 def description_for_case_sensitive_qualifier; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1024 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1036 def descriptions_for_attribute_setters_for_new_record; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#514 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#532 def does_not_match_allow_blank?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#498 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#516 def does_not_match_allow_nil?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#600 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#618 def does_not_match_presence_of_attribute?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#640 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#656 def does_not_match_presence_of_scopes?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#434 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#452 def does_not_match_scopes_configuration?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#718 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#732 def does_not_match_uniqueness_with_case_sensitivity_strategy?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#765 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#779 def does_not_match_uniqueness_with_scopes?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#685 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#699 def does_not_match_uniqueness_without_scopes?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#803 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#817 def dummy_scalar_value_for(column); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#793 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#807 def dummy_value_for(scope); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1041 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1053 def existing_and_new_values_are_same?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#521 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#539 def existing_record; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#914 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#928 def existing_value_read; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#918 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#932 def existing_value_written; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#481 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#499 def expected_scopes; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#938 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#952 def failure_message_preface; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#538 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#556 def find_existing_record; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#529 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#547 def find_or_create_existing_record; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#573 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#591 def has_secure_password?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#462 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#480 def inspected_actual_scopes; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#469 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#487 def inspected_actual_sets_of_scopes; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#458 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#476 def inspected_expected_scopes; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1045 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1057 def last_attribute_setter_used_on_new_record; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1049 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1061 def last_value_set_on_new_record; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#507 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#525 def matches_allow_blank?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#491 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#509 def matches_allow_nil?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#590 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#608 def matches_presence_of_attribute?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#615 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#633 def matches_presence_of_scopes?; end # @return [Boolean] @@ -10640,73 +12114,73 @@ class Shoulda::Matchers::ActiveRecord::ValidateUniquenessOfMatcher < ::Shoulda:: # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#695 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#709 def matches_uniqueness_with_case_sensitivity_strategy?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#755 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#769 def matches_uniqueness_with_scopes?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#677 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#691 def matches_uniqueness_without_scopes?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#934 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#948 def model; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#749 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#763 def model_class?(model_name); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#384 def new_record; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#815 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#829 def next_scalar_value_for(scope, previous_value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#807 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#821 def next_value_for(scope, previous_value); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#851 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#865 def polymorphic_type_attribute?(scope, previous_value); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#453 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#471 def scopes_match?; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#671 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#685 def scopes_missing_on_model; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#665 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#679 def scopes_present_on_model; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#861 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#875 def set_attribute_on!(record_type, record, attribute_name, value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#872 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#886 def set_attribute_on_existing_record!(attribute_name, value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#881 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#895 def set_attribute_on_new_record!(attribute_name, value); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#776 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#790 def setting_next_value_for(scope); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#743 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#757 def should_test_case_sensitivity?; end # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#384 def subject; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#550 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#568 def update_existing_record!(value); end # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#404 @@ -10715,96 +12189,96 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1054 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1066 class Shoulda::Matchers::ActiveRecord::ValidateUniquenessOfMatcher::AttributeSetters include ::Enumerable # @return [AttributeSetters] a new instance of AttributeSetters # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1057 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1069 def initialize; end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1071 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1083 def +(other_attribute_setters); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1061 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1073 def <<(given_attribute_setter); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1079 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1091 def each(&block); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1083 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1095 def last; end private - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1089 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1101 def find_index_of(given_attribute_setter); end end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1125 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1137 class Shoulda::Matchers::ActiveRecord::ValidateUniquenessOfMatcher::ExistingRecordInvalid < ::Shoulda::Matchers::Error include ::Shoulda::Matchers::ActiveModel::Helpers - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1130 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1142 def message; end # Returns the value of attribute underlying_exception. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1128 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1140 def underlying_exception; end # Sets the attribute underlying_exception # # @param value the value to set the attribute underlying_exception to. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1128 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1140 def underlying_exception=(_arg0); end end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1098 +# source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1110 class Shoulda::Matchers::ActiveRecord::ValidateUniquenessOfMatcher::NonCaseSwappableValueError < ::Shoulda::Matchers::Error # Returns the value of attribute attribute. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1099 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1111 def attribute; end # Sets the attribute attribute # # @param value the value to set the attribute attribute to. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1099 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1111 def attribute=(_arg0); end - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1101 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1113 def message; end # Returns the value of attribute model. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1099 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1111 def model; end # Sets the attribute model # # @param value the value to set the attribute model to. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1099 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1111 def model=(_arg0); end # Returns the value of attribute value. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1099 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1111 def value; end # Sets the attribute value # # @param value the value to set the attribute value to. # - # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1099 + # source://shoulda-matchers//lib/shoulda/matchers/active_record/validate_uniqueness_of_matcher.rb#1111 def value=(_arg0); end end @@ -10861,15 +12335,15 @@ end # @private # -# source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#7 +# source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#6 module Shoulda::Matchers::Doublespeak class << self - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#22 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#21 def debug(&block); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#18 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#17 def debugging_enabled?; end # source://forwardable/1.3.3/forwardable.rb#231 @@ -10878,7 +12352,7 @@ module Shoulda::Matchers::Doublespeak # source://forwardable/1.3.3/forwardable.rb#231 def with_doubles_activated(*args, **_arg1, &block); end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#14 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak.rb#13 def world; end end end @@ -10966,13 +12440,13 @@ class Shoulda::Matchers::Doublespeak::DoubleCollection # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#20 def activate; end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#32 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#28 def calls_by_method_name; end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#38 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#34 def calls_to(method_name); end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#26 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#24 def deactivate; end # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#16 @@ -10985,20 +12459,20 @@ class Shoulda::Matchers::Doublespeak::DoubleCollection # Returns the value of attribute doubles_by_method_name. # - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#50 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#46 def doubles_by_method_name; end # Returns the value of attribute klass. # - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#50 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#46 def klass; end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#52 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#48 def register_double(method_name, implementation_type); end # Returns the value of attribute world. # - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#50 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/double_collection.rb#46 def world; end end @@ -11216,16 +12690,16 @@ class Shoulda::Matchers::Doublespeak::World # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#41 def activate; end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#47 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#45 def deactivate; end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#53 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#49 def double_collections_by_class; end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#57 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#53 def original_methods_by_class; end - # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#61 + # source://shoulda-matchers//lib/shoulda/matchers/doublespeak/world.rb#57 def original_methods_for_class(klass); end end @@ -11250,7 +12724,9 @@ class Shoulda::Matchers::Error < ::StandardError end end -# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#6 +# @private +# +# source://shoulda-matchers//lib/shoulda/matchers/active_model/validate_inclusion_of_matcher.rb#7 class Shoulda::Matchers::ExampleClass; end # This module provides matchers that are used to test behavior outside of @@ -11704,9 +13180,7 @@ class Shoulda::Matchers::Integrations::Libraries::ActionController # source://shoulda-matchers//lib/shoulda/matchers/integrations/libraries/action_controller.rb#12 def integrate_with(test_framework); end - private - - # source://shoulda-matchers//lib/shoulda/matchers/integrations/libraries/action_controller.rb#24 + # source://shoulda-matchers//lib/shoulda/matchers/integrations/libraries/action_controller.rb#26 def matchers_module; end end @@ -11778,9 +13252,7 @@ class Shoulda::Matchers::Integrations::Libraries::Routing # source://shoulda-matchers//lib/shoulda/matchers/integrations/libraries/routing.rb#12 def integrate_with(test_framework); end - private - - # source://shoulda-matchers//lib/shoulda/matchers/integrations/libraries/routing.rb#20 + # source://shoulda-matchers//lib/shoulda/matchers/integrations/libraries/routing.rb#22 def matchers_module; end end @@ -12122,65 +13594,65 @@ module Shoulda::Matchers::RailsShim # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#32 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#28 def active_model_lt_7?; end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#28 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#24 def active_model_st_6_1?; end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#22 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#18 def active_model_version; end - # @return [Boolean] - # # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#12 - def active_record_gte_6?; end - - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#16 def active_record_version; end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#75 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#72 def attribute_serialization_coder_for(model, attribute_name); end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#134 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#131 def attribute_type_for(model, attribute_name); end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#120 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#117 def attribute_types_for(model); end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#100 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#97 def digestible_attributes_in(record); end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#36 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#32 def generate_validation_message(record, attribute, type, model_name, options); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#91 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#88 def has_secure_password?(record, attribute_name); end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#83 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#80 def parent_of(mod); end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#114 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#111 def secure_password_module; end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#62 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#58 def serialized_attributes_for(model); end # @return [Boolean] # - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#144 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#141 def supports_full_attributes_api?(model); end - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#79 + # @return [Boolean] + # + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#146 + def validates_column_options?; end + + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#76 def verb_for_update; end private - # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#151 + # source://shoulda-matchers//lib/shoulda/matchers/rails_shim.rb#152 def simply_generate_validation_message(attribute, type, model_name, options); end end end @@ -12224,31 +13696,31 @@ Shoulda::Matchers::Text::LIST_ITEM_REGEXP = T.let(T.unsafe(nil), Regexp) # source://shoulda-matchers//lib/shoulda/matchers/util.rb#6 module Shoulda::Matchers::Util class << self - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#42 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#40 def a_or_an(next_word); end # source://shoulda-matchers//lib/shoulda/matchers/util.rb#9 def deconstantize(path); end - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#88 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#86 def dummy_value_for(column_type, array: T.unsafe(nil)); end - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#35 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#33 def indent(string, width); end - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#74 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#72 def inspect_hash(hash); end - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#70 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#68 def inspect_range(range); end - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#50 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#48 def inspect_value(value); end - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#66 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#64 def inspect_values(values); end - # source://shoulda-matchers//lib/shoulda/matchers/util.rb#20 + # source://shoulda-matchers//lib/shoulda/matchers/util.rb#19 def safe_constantize(camel_cased_word); end end end diff --git a/sorbet/rbi/gems/sidekiq-cron@1.10.1.rbi b/sorbet/rbi/gems/sidekiq-cron@1.12.0.rbi similarity index 60% rename from sorbet/rbi/gems/sidekiq-cron@1.10.1.rbi rename to sorbet/rbi/gems/sidekiq-cron@1.12.0.rbi index a4ef4be51..0425818f9 100644 --- a/sorbet/rbi/gems/sidekiq-cron@1.10.1.rbi +++ b/sorbet/rbi/gems/sidekiq-cron@1.12.0.rbi @@ -4,133 +4,68 @@ # This is an autogenerated file for types exported from the `sidekiq-cron` gem. # Please instead update this file by running `bin/tapioca gem sidekiq-cron`. + # https://github.com/rails/rails/blob/352865d0f835c24daa9a2e9863dcc9dde9e5371a/activesupport/lib/active_support/inflector/methods.rb#L270 # # source://sidekiq-cron//lib/sidekiq/cron/support.rb#3 module Sidekiq class << self - # source://sidekiq/6.5.9/lib/sidekiq.rb#106 - def [](key); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#110 - def []=(key, val); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#303 - def average_scheduled_poll_interval=(interval); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#209 - def client_middleware; end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#60 - def concurrency=(val); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#151 + # source://sidekiq/7.3.0/lib/sidekiq.rb#135 def configure_client; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#141 - def configure_server; end + # source://sidekiq/7.3.0/lib/sidekiq.rb#123 + def configure_embed(&block); end - # source://sidekiq/6.5.9/lib/sidekiq.rb#250 - def death_handlers; end + # source://sidekiq/7.3.0/lib/sidekiq.rb#97 + def configure_server(&block); end - # source://sidekiq/6.5.9/lib/sidekiq.rb#84 - def default_error_handler(ex, ctx); end + # source://sidekiq/7.3.0/lib/sidekiq.rb#89 + def default_configuration; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#237 + # source://sidekiq/7.3.0/lib/sidekiq.rb#85 def default_job_options; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#229 + # source://sidekiq/7.3.0/lib/sidekiq.rb#81 def default_job_options=(hash); end - # source://sidekiq/6.5.9/lib/sidekiq.rb#221 - def default_server_middleware; end - - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def default_worker_options(*args, **_arg1, &block); end - - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def default_worker_options=(*args, **_arg1, &block); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#258 + # source://sidekiq/7.3.0/lib/sidekiq.rb#57 def dump_json(object); end - # source://sidekiq/6.5.9/lib/sidekiq.rb#294 + # source://sidekiq/7.3.0/lib/sidekiq.rb#65 def ent?; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#314 - def error_handlers; end + # source://sidekiq/7.3.0/lib/sidekiq.rb#102 + def freeze!; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#118 - def fetch(*args, &block); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#122 - def handle_exception(ex, ctx = T.unsafe(nil)); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#254 + # source://sidekiq/7.3.0/lib/sidekiq.rb#53 def load_json(string); end - # source://sidekiq/6.5.9/lib/sidekiq.rb#262 - def log_formatter; end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#270 - def log_formatter=(log_formatter); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#275 + # source://sidekiq/7.3.0/lib/sidekiq.rb#93 def logger; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#279 - def logger=(logger); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#114 - def merge!(hash); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#326 - def on(event, &block); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#96 - def options; end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#101 - def options=(opts); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#290 + # source://sidekiq/7.3.0/lib/sidekiq.rb#61 def pro?; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#73 - def queues=(val); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#159 - def redis; end + # source://sidekiq/7.3.0/lib/sidekiq.rb#73 + def redis(&block); end - # source://sidekiq/6.5.9/lib/sidekiq.rb#201 - def redis=(hash); end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#181 - def redis_info; end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#197 + # source://sidekiq/7.3.0/lib/sidekiq.rb#69 def redis_pool; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#155 + # source://sidekiq/7.3.0/lib/sidekiq.rb#49 def server?; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#215 - def server_middleware; end - - # source://sidekiq/6.5.9/lib/sidekiq.rb#332 + # source://sidekiq/7.3.0/lib/sidekiq.rb#77 def strict_args!(mode = T.unsafe(nil)); end - # source://sidekiq/6.5.9/lib/sidekiq/transaction_aware_client.rb#33 + # source://sidekiq/7.3.0/lib/sidekiq/transaction_aware_client.rb#40 def transactional_push!; end - # source://sidekiq/6.5.9/lib/sidekiq.rb#55 + # source://sidekiq/7.3.0/lib/sidekiq.rb#45 def ❨╯°□°❩╯︵┻━┻; end end end -# source://sidekiq/6.5.9/lib/sidekiq/middleware/modules.rb#20 -Sidekiq::ClientMiddleware = Sidekiq::ServerMiddleware - # source://sidekiq-cron//lib/sidekiq/cron/support.rb#4 module Sidekiq::Cron; end @@ -144,10 +79,10 @@ class Sidekiq::Cron::Job # Active Job has different structure how it is loading data from Sidekiq # queue, it creates a wrapper around job. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#135 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#136 def active_job_message; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#489 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#491 def add_jid_history(jid); end # Returns the value of attribute args. @@ -159,8 +94,8 @@ class Sidekiq::Cron::Job # # @param value the value to set the attribute args to. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#269 - def args=(_arg0); end + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#569 + def args=(args); end # Returns the value of attribute cron. # @@ -176,7 +111,7 @@ class Sidekiq::Cron::Job # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#87 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#88 def date_as_argument?; end # Returns the value of attribute description. @@ -191,45 +126,45 @@ class Sidekiq::Cron::Job # source://sidekiq-cron//lib/sidekiq/cron/job.rb#269 def description=(_arg0); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#504 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#506 def destroy; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#348 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#349 def disable!; end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#362 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#363 def disabled?; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#353 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#354 def enable!; end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#358 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#359 def enabled?; end # Enqueue cron job to queue. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#51 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#52 def enque!(time = T.unsafe(nil)); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#96 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#97 def enqueue_active_job(klass_const); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#91 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#92 def enqueue_args; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#100 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#101 def enqueue_sidekiq_worker(klass_const); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#428 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#430 def errors; end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#559 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#561 def exists?; end # Returns the value of attribute fetch_missing_args. @@ -237,18 +172,18 @@ class Sidekiq::Cron::Job # source://sidekiq-cron//lib/sidekiq/cron/job.rb#270 def fetch_missing_args; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#544 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#546 def formatted_enqueue_time(now = T.unsafe(nil)); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#548 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#550 def formatted_last_time(now = T.unsafe(nil)); end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#81 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#82 def is_active_job?(klass = T.unsafe(nil)); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#393 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#394 def jid_history_from_redis; end # Returns the value of attribute klass. @@ -263,7 +198,7 @@ class Sidekiq::Cron::Job # source://sidekiq-cron//lib/sidekiq/cron/job.rb#269 def klass=(_arg0); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#452 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#454 def klass_valid; end # Returns the value of attribute last_enqueue_time. @@ -271,13 +206,13 @@ class Sidekiq::Cron::Job # source://sidekiq-cron//lib/sidekiq/cron/job.rb#270 def last_enqueue_time; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#383 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#384 def last_enqueue_time_from_redis; end # Parse cron specification '* * * * *' and returns # time when last run should be performed # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#540 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#542 def last_time(now = T.unsafe(nil)); end # Returns the value of attribute message. @@ -304,22 +239,22 @@ class Sidekiq::Cron::Job # source://sidekiq-cron//lib/sidekiq/cron/job.rb#269 def name=(_arg0); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#366 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#367 def pretty_message; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#111 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#112 def queue_name_with_prefix; end # Remove previous information about run times, # this will clear Redis and make sure that Redis will not overflow with memory. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#35 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#36 def remove_previous_enques(time); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#462 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#464 def save; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#482 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#484 def save_last_enqueue_time; end # Crucial part of whole enqueuing job. @@ -331,104 +266,109 @@ class Sidekiq::Cron::Job # Sidekiq worker message. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#105 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#106 def sidekiq_worker_message; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#563 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#565 def sort_name; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#344 + # Returns the value of attribute source. + # + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#270 + def source; end + + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#345 def status; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#372 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#373 def status_from_redis; end # Test if job should be enqueued. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#42 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#43 def test_and_enque_for_time!(time); end # Export job data to hash. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#405 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#406 def to_hash; end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#432 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#434 def valid?; end private - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#670 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#676 def convert_to_global_id_hash(argument); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#677 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#683 def deserialize_argument(argument); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#698 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#704 def deserialize_global_id(hash); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#662 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#668 def jid_history_key; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#658 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#664 def job_enqueued_key; end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#573 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#579 def not_enqueued_after?(time); end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#628 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#634 def not_past_scheduled_time?(current_time); end # Try parsing inbound args into an array. # Args from Redis will be encoded JSON, # try to load JSON, then failover to string array. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#580 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#586 def parse_args(args); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#622 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#628 def parse_enqueue_time(timestamp); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#569 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#575 def parsed_cron; end # Redis key for storing one cron job. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#645 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#651 def redis_key; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#702 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#708 def serialize_argument(argument); end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#694 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#700 def serialized_global_id?(hash); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#666 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#672 def serialized_last_enqueue_time; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#606 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#612 def symbolize_args(input); end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#602 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#608 def symbolize_args?; end class << self # Get all cron jobs. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#215 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#216 def all; end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#231 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#232 def count; end # Create new instance of cron job. @@ -443,33 +383,33 @@ class Sidekiq::Cron::Job # Remove all job from cron. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#523 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#525 def destroy_all!; end # Remove "removed jobs" between current jobs and new jobs # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#531 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#533 def destroy_removed_jobs(new_job_names); end # @return [Boolean] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#552 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#554 def exists?(name); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#239 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#240 def find(name); end - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#654 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#660 def jid_history_key(name); end # Redis key for storing one cron job run times (when poller added job to queue) # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#650 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#656 def job_enqueued_key(name); end # Redis key for set of all cron jobs. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#635 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#641 def jobs_key; end # Load cron jobs from Array. @@ -489,14 +429,14 @@ class Sidekiq::Cron::Job # } # ] # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#197 - def load_from_array(array); end + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#198 + def load_from_array(array, options = T.unsafe(nil)); end # Like #load_from_array. # If exists old jobs in Redis but removed from args, destroy old jobs. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#208 - def load_from_array!(array); end + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#209 + def load_from_array!(array, options = T.unsafe(nil)); end # Load cron jobs from Hash. # Input structure should look like: @@ -513,18 +453,18 @@ class Sidekiq::Cron::Job # } # } # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#165 - def load_from_hash(hash); end + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#166 + def load_from_hash(hash, options = T.unsafe(nil)); end # Like #load_from_hash. # If exists old jobs in Redis but removed from args, destroy old jobs. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#175 - def load_from_hash!(hash); end + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#176 + def load_from_hash!(hash, options = T.unsafe(nil)); end # Redis key for storing one cron job. # - # source://sidekiq-cron//lib/sidekiq/cron/job.rb#640 + # source://sidekiq-cron//lib/sidekiq/cron/job.rb#646 def redis_key(name); end end end @@ -612,24 +552,6 @@ module Sidekiq::Cron::Support end end -# source://sidekiq/6.5.9/lib/sidekiq.rb#20 -Sidekiq::DEFAULTS = T.let(T.unsafe(nil), Hash) - -# source://sidekiq/6.5.9/lib/sidekiq.rb#93 -Sidekiq::DEFAULT_ERROR_HANDLER = T.let(T.unsafe(nil), Method) - -# source://sidekiq/6.5.9/lib/sidekiq.rb#47 -Sidekiq::FAKE_INFO = T.let(T.unsafe(nil), Hash) - -# source://sidekiq/6.5.9/lib/sidekiq/job.rb#12 -Sidekiq::Job = Sidekiq::Worker - -# source://sidekiq/6.5.9/lib/sidekiq.rb#18 -Sidekiq::LICENSE = T.let(T.unsafe(nil), String) - -# source://sidekiq/6.5.9/lib/sidekiq.rb#17 -Sidekiq::NAME = T.let(T.unsafe(nil), String) - # source://sidekiq-cron//lib/sidekiq/options.rb#4 module Sidekiq::Options class << self @@ -640,9 +562,9 @@ module Sidekiq::Options def []=(key, value); end # source://sidekiq-cron//lib/sidekiq/options.rb#13 + def config; end + + # source://sidekiq-cron//lib/sidekiq/options.rb#17 def options_field; end end end - -# source://sidekiq/6.5.9/lib/sidekiq/version.rb#4 -Sidekiq::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/sidekiq@6.5.9.rbi b/sorbet/rbi/gems/sidekiq@6.5.9.rbi deleted file mode 100644 index 40e8278ca..000000000 --- a/sorbet/rbi/gems/sidekiq@6.5.9.rbi +++ /dev/null @@ -1,1267 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `sidekiq` gem. -# Please instead update this file by running `bin/tapioca gem sidekiq`. - -# Use `Sidekiq.transactional_push!` in your sidekiq.rb initializer -# -# source://sidekiq//lib/sidekiq/version.rb#3 -module Sidekiq - class << self - # source://sidekiq//lib/sidekiq.rb#106 - def [](key); end - - # source://sidekiq//lib/sidekiq.rb#110 - def []=(key, val); end - - # How frequently Redis should be checked by a random Sidekiq process for - # scheduled and retriable jobs. Each individual process will take turns by - # waiting some multiple of this value. - # - # See sidekiq/scheduled.rb for an in-depth explanation of this value - # - # source://sidekiq//lib/sidekiq.rb#303 - def average_scheduled_poll_interval=(interval); end - - # @yield [@client_chain] - # - # source://sidekiq//lib/sidekiq.rb#209 - def client_middleware; end - - # config.concurrency = 5 - # - # source://sidekiq//lib/sidekiq.rb#60 - def concurrency=(val); end - - # Configuration for Sidekiq client, use like: - # - # Sidekiq.configure_client do |config| - # config.redis = { size: 1, url: 'redis://myhost:8877/0' } - # end - # - # @yield [_self] - # @yieldparam _self [Sidekiq] the object that the method was called on - # - # source://sidekiq//lib/sidekiq.rb#151 - def configure_client; end - - # Configuration for Sidekiq server, use like: - # - # Sidekiq.configure_server do |config| - # config.server_middleware do |chain| - # chain.add MyServerHook - # end - # end - # - # @yield [_self] - # @yieldparam _self [Sidekiq] the object that the method was called on - # - # source://sidekiq//lib/sidekiq.rb#141 - def configure_server; end - - # Death handlers are called when all retries for a job have been exhausted and - # the job dies. It's the notification to your application - # that this job will not succeed without manual intervention. - # - # Sidekiq.configure_server do |config| - # config.death_handlers << ->(job, ex) do - # end - # end - # - # source://sidekiq//lib/sidekiq.rb#250 - def death_handlers; end - - # Private APIs - # - # source://sidekiq//lib/sidekiq.rb#84 - def default_error_handler(ex, ctx); end - - # source://sidekiq//lib/sidekiq.rb#237 - def default_job_options; end - - # source://sidekiq//lib/sidekiq.rb#229 - def default_job_options=(hash); end - - # source://sidekiq//lib/sidekiq.rb#221 - def default_server_middleware; end - - # deprecated - # - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def default_worker_options(*args, **_arg1, &block); end - - # deprecated - # - # source://activesupport/7.0.5/lib/active_support/deprecation/method_wrappers.rb#63 - def default_worker_options=(*args, **_arg1, &block); end - - # source://sidekiq//lib/sidekiq.rb#258 - def dump_json(object); end - - # @return [Boolean] - # - # source://sidekiq//lib/sidekiq.rb#294 - def ent?; end - - # Register a proc to handle any error which occurs within the Sidekiq process. - # - # Sidekiq.configure_server do |config| - # config.error_handlers << proc {|ex,ctx_hash| MyErrorService.notify(ex, ctx_hash) } - # end - # - # The default error handler logs errors to Sidekiq.logger. - # - # source://sidekiq//lib/sidekiq.rb#314 - def error_handlers; end - - # source://sidekiq//lib/sidekiq.rb#118 - def fetch(*args, &block); end - - # source://sidekiq//lib/sidekiq.rb#122 - def handle_exception(ex, ctx = T.unsafe(nil)); end - - # source://sidekiq//lib/sidekiq.rb#254 - def load_json(string); end - - # source://sidekiq//lib/sidekiq.rb#262 - def log_formatter; end - - # source://sidekiq//lib/sidekiq.rb#270 - def log_formatter=(log_formatter); end - - # source://sidekiq//lib/sidekiq.rb#275 - def logger; end - - # source://sidekiq//lib/sidekiq.rb#279 - def logger=(logger); end - - # source://sidekiq//lib/sidekiq.rb#114 - def merge!(hash); end - - # Register a block to run at a point in the Sidekiq lifecycle. - # :startup, :quiet or :shutdown are valid events. - # - # Sidekiq.configure_server do |config| - # config.on(:shutdown) do - # puts "Goodbye cruel world!" - # end - # end - # - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq.rb#326 - def on(event, &block); end - - # source://sidekiq//lib/sidekiq.rb#96 - def options; end - - # source://sidekiq//lib/sidekiq.rb#101 - def options=(opts); end - - # @return [Boolean] - # - # source://sidekiq//lib/sidekiq.rb#290 - def pro?; end - - # config.queues = %w( high default low ) # strict - # config.queues = %w( high,3 default,2 low,1 ) # weighted - # config.queues = %w( feature1,1 feature2,1 feature3,1 ) # random - # - # With weighted priority, queue will be checked first (weight / total) of the time. - # high will be checked first (3/6) or 50% of the time. - # I'd recommend setting weights between 1-10. Weights in the hundreds or thousands - # are ridiculous and unnecessarily expensive. You can get random queue ordering - # by explicitly setting all weights to 1. - # - # source://sidekiq//lib/sidekiq.rb#73 - def queues=(val); end - - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq.rb#159 - def redis; end - - # source://sidekiq//lib/sidekiq.rb#201 - def redis=(hash); end - - # source://sidekiq//lib/sidekiq.rb#181 - def redis_info; end - - # source://sidekiq//lib/sidekiq.rb#197 - def redis_pool; end - - # @return [Boolean] - # - # source://sidekiq//lib/sidekiq.rb#155 - def server?; end - - # @yield [@server_chain] - # - # source://sidekiq//lib/sidekiq.rb#215 - def server_middleware; end - - # source://sidekiq//lib/sidekiq.rb#332 - def strict_args!(mode = T.unsafe(nil)); end - - # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#33 - def transactional_push!; end - - # source://sidekiq//lib/sidekiq.rb#55 - def ❨╯°□°❩╯︵┻━┻; end - end -end - -# source://sidekiq//lib/sidekiq/client.rb#8 -class Sidekiq::Client - include ::Sidekiq::JobUtil - - # Sidekiq::Client normally uses the default Redis pool but you may - # pass a custom ConnectionPool if you want to shard your - # Sidekiq jobs across several Redis instances (for scalability - # reasons, e.g.) - # - # Sidekiq::Client.new(ConnectionPool.new { Redis.new }) - # - # Generally this is only needed for very large Sidekiq installs processing - # thousands of jobs per second. I don't recommend sharding unless you - # cannot scale any other way (e.g. splitting your app into smaller apps). - # - # @return [Client] a new instance of Client - # - # source://sidekiq//lib/sidekiq/client.rb#44 - def initialize(redis_pool = T.unsafe(nil)); end - - # Define client-side middleware: - # - # client = Sidekiq::Client.new - # client.middleware do |chain| - # chain.use MyClientMiddleware - # end - # client.push('class' => 'SomeJob', 'args' => [1,2,3]) - # - # All client instances default to the globally-defined - # Sidekiq.client_middleware but you can change as necessary. - # - # source://sidekiq//lib/sidekiq/client.rb#23 - def middleware(&block); end - - # The main method used to push a job to Redis. Accepts a number of options: - # - # queue - the named queue to use, default 'default' - # class - the job class to call, required - # args - an array of simple arguments to the perform method, must be JSON-serializable - # at - timestamp to schedule the job (optional), must be Numeric (e.g. Time.now.to_f) - # retry - whether to retry this job if it fails, default true or an integer number of retries - # backtrace - whether to save any error backtrace, default false - # - # If class is set to the class name, the jobs' options will be based on Sidekiq's default - # job options. Otherwise, they will be based on the job class's options. - # - # Any options valid for a job class's sidekiq_options are also available here. - # - # All options must be strings, not symbols. NB: because we are serializing to JSON, all - # symbols in 'args' will be converted to strings. Note that +backtrace: true+ can take quite a bit of - # space in Redis; a large volume of failing jobs can start Redis swapping if you aren't careful. - # - # Returns a unique Job ID. If middleware stops the job, nil will be returned instead. - # - # Example: - # push('queue' => 'my_queue', 'class' => MyJob, 'args' => ['foo', 1, :bat => 'bar']) - # - # source://sidekiq//lib/sidekiq/client.rb#72 - def push(item); end - - # Push a large number of jobs to Redis. This method cuts out the redis - # network round trip latency. I wouldn't recommend pushing more than - # 1000 per call but YMMV based on network quality, size of job args, etc. - # A large number of jobs can cause a bit of Redis command processing latency. - # - # Takes the same arguments as #push except that args is expected to be - # an Array of Arrays. All other keys are duplicated for each job. Each job - # is run through the client middleware pipeline and each job gets its own Job ID - # as normal. - # - # Returns an array of the of pushed jobs' jids. The number of jobs pushed can be less - # than the number given if the middleware stopped processing for one or more jobs. - # - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/client.rb#97 - def push_bulk(items); end - - # Returns the value of attribute redis_pool. - # - # source://sidekiq//lib/sidekiq/client.rb#32 - def redis_pool; end - - # Sets the attribute redis_pool - # - # @param value the value to set the attribute redis_pool to. - # - # source://sidekiq//lib/sidekiq/client.rb#32 - def redis_pool=(_arg0); end - - private - - # source://sidekiq//lib/sidekiq/client.rb#221 - def atomic_push(conn, payloads); end - - # source://sidekiq//lib/sidekiq/client.rb#197 - def raw_push(payloads); end - - class << self - # Resque compatibility helpers. Note all helpers - # should go through Sidekiq::Job#client_push. - # - # Example usage: - # Sidekiq::Client.enqueue(MyJob, 'foo', 1, :bat => 'bar') - # - # Messages are enqueued to the 'default' queue. - # - # source://sidekiq//lib/sidekiq/client.rb#162 - def enqueue(klass, *args); end - - # Example usage: - # Sidekiq::Client.enqueue_in(3.minutes, MyJob, 'foo', 1, :bat => 'bar') - # - # source://sidekiq//lib/sidekiq/client.rb#190 - def enqueue_in(interval, klass, *args); end - - # Example usage: - # Sidekiq::Client.enqueue_to(:queue_name, MyJob, 'foo', 1, :bat => 'bar') - # - # source://sidekiq//lib/sidekiq/client.rb#169 - def enqueue_to(queue, klass, *args); end - - # Example usage: - # Sidekiq::Client.enqueue_to_in(:queue_name, 3.minutes, MyJob, 'foo', 1, :bat => 'bar') - # - # source://sidekiq//lib/sidekiq/client.rb#176 - def enqueue_to_in(queue, interval, klass, *args); end - - # source://sidekiq//lib/sidekiq/client.rb#146 - def push(item); end - - # source://sidekiq//lib/sidekiq/client.rb#150 - def push_bulk(items); end - - # Allows sharding of jobs across any number of Redis instances. All jobs - # defined within the block will use the given Redis connection pool. - # - # pool = ConnectionPool.new { Redis.new } - # Sidekiq::Client.via(pool) do - # SomeJob.perform_async(1,2,3) - # SomeOtherJob.perform_async(1,2,3) - # end - # - # Generally this is only needed for very large Sidekiq installs processing - # thousands of jobs per second. I do not recommend sharding unless - # you cannot scale any other way (e.g. splitting your app into smaller apps). - # - # source://sidekiq//lib/sidekiq/client.rb#136 - def via(pool); end - end -end - -# no difference for now -# -# source://sidekiq//lib/sidekiq/middleware/modules.rb#20 -Sidekiq::ClientMiddleware = Sidekiq::ServerMiddleware - -# Sidekiq::Component assumes a config instance is available at @config -# -# source://sidekiq//lib/sidekiq/component.rb#4 -module Sidekiq::Component - # source://sidekiq//lib/sidekiq/component.rb#5 - def config; end - - # source://sidekiq//lib/sidekiq/component.rb#49 - def fire_event(event, options = T.unsafe(nil)); end - - # source://sidekiq//lib/sidekiq/component.rb#45 - def handle_exception(ex, ctx = T.unsafe(nil)); end - - # source://sidekiq//lib/sidekiq/component.rb#33 - def hostname; end - - # source://sidekiq//lib/sidekiq/component.rb#41 - def identity; end - - # source://sidekiq//lib/sidekiq/component.rb#21 - def logger; end - - # source://sidekiq//lib/sidekiq/component.rb#37 - def process_nonce; end - - # source://sidekiq//lib/sidekiq/component.rb#25 - def redis(&block); end - - # source://sidekiq//lib/sidekiq/component.rb#14 - def safe_thread(name, &block); end - - # source://sidekiq//lib/sidekiq/component.rb#29 - def tid; end - - # source://sidekiq//lib/sidekiq/component.rb#7 - def watchdog(last_words); end -end - -# source://sidekiq//lib/sidekiq/logger.rb#7 -module Sidekiq::Context - class << self - # source://sidekiq//lib/sidekiq/logger.rb#20 - def add(k, v); end - - # source://sidekiq//lib/sidekiq/logger.rb#16 - def current; end - - # source://sidekiq//lib/sidekiq/logger.rb#8 - def with(hash); end - end -end - -# source://sidekiq//lib/sidekiq.rb#20 -Sidekiq::DEFAULTS = T.let(T.unsafe(nil), Hash) - -# DEFAULT_ERROR_HANDLER is a constant that allows the default error handler to -# be referenced. It must be defined here, after the default_error_handler -# method is defined. -# -# source://sidekiq//lib/sidekiq.rb#93 -Sidekiq::DEFAULT_ERROR_HANDLER = T.let(T.unsafe(nil), Method) - -# source://sidekiq//lib/sidekiq/delay.rb#4 -module Sidekiq::Extensions - class << self - # source://sidekiq//lib/sidekiq/delay.rb#5 - def enable_delay!; end - end -end - -# source://sidekiq//lib/sidekiq/delay.rb#28 -module Sidekiq::Extensions::PsychAutoload - # source://sidekiq//lib/sidekiq/delay.rb#29 - def resolve_class(klass_name); end -end - -# source://sidekiq//lib/sidekiq.rb#47 -Sidekiq::FAKE_INFO = T.let(T.unsafe(nil), Hash) - -# source://sidekiq//lib/sidekiq/job.rb#12 -Sidekiq::Job = Sidekiq::Worker - -# source://sidekiq//lib/sidekiq/job_util.rb#5 -module Sidekiq::JobUtil - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/job_util.rb#35 - def normalize_item(item); end - - # source://sidekiq//lib/sidekiq/job_util.rb#56 - def normalized_hash(item_class); end - - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/job_util.rb#10 - def validate(item); end - - # source://sidekiq//lib/sidekiq/job_util.rb#18 - def verify_json(item); end - - private - - # @return [Boolean] - # - # source://sidekiq//lib/sidekiq/job_util.rb#67 - def json_safe?(item); end -end - -# These functions encapsulate various job utilities. -# -# source://sidekiq//lib/sidekiq/job_util.rb#8 -Sidekiq::JobUtil::TRANSIENT_ATTRIBUTES = T.let(T.unsafe(nil), Array) - -# source://sidekiq//lib/sidekiq.rb#18 -Sidekiq::LICENSE = T.let(T.unsafe(nil), String) - -# source://sidekiq//lib/sidekiq/logger.rb#95 -class Sidekiq::Logger < ::Logger - include ::Sidekiq::LoggingUtils - - # @return [Logger] a new instance of Logger - # - # source://sidekiq//lib/sidekiq/logger.rb#98 - def initialize(*args, **kwargs); end -end - -# source://sidekiq//lib/sidekiq/logger.rb#103 -module Sidekiq::Logger::Formatters; end - -# source://sidekiq//lib/sidekiq/logger.rb#104 -class Sidekiq::Logger::Formatters::Base < ::Logger::Formatter - # source://sidekiq//lib/sidekiq/logger.rb#109 - def ctx; end - - # source://sidekiq//lib/sidekiq/logger.rb#113 - def format_context; end - - # source://sidekiq//lib/sidekiq/logger.rb#105 - def tid; end -end - -# source://sidekiq//lib/sidekiq/logger.rb#139 -class Sidekiq::Logger::Formatters::JSON < ::Sidekiq::Logger::Formatters::Base - # source://sidekiq//lib/sidekiq/logger.rb#140 - def call(severity, time, program_name, message); end -end - -# source://sidekiq//lib/sidekiq/logger.rb#127 -class Sidekiq::Logger::Formatters::Pretty < ::Sidekiq::Logger::Formatters::Base - # source://sidekiq//lib/sidekiq/logger.rb#128 - def call(severity, time, program_name, message); end -end - -# source://sidekiq//lib/sidekiq/logger.rb#133 -class Sidekiq::Logger::Formatters::WithoutTimestamp < ::Sidekiq::Logger::Formatters::Pretty - # source://sidekiq//lib/sidekiq/logger.rb#134 - def call(severity, time, program_name, message); end -end - -# source://sidekiq//lib/sidekiq/logger.rb#25 -module Sidekiq::LoggingUtils - # Redefined to check severity against #level, and thus the thread-local level, rather than +@level+. - # FIXME: Remove when the minimum Ruby version supports overriding Logger#level. - # - # source://sidekiq//lib/sidekiq/logger.rb#76 - def add(severity, message = T.unsafe(nil), progname = T.unsafe(nil), &block); end - - # source://sidekiq//lib/sidekiq/logger.rb#39 - def debug?; end - - # source://sidekiq//lib/sidekiq/logger.rb#39 - def error?; end - - # source://sidekiq//lib/sidekiq/logger.rb#39 - def fatal?; end - - # source://sidekiq//lib/sidekiq/logger.rb#39 - def info?; end - - # source://sidekiq//lib/sidekiq/logger.rb#61 - def level; end - - # source://sidekiq//lib/sidekiq/logger.rb#44 - def local_level; end - - # source://sidekiq//lib/sidekiq/logger.rb#48 - def local_level=(level); end - - # Change the thread-local level for the duration of the given block. - # - # source://sidekiq//lib/sidekiq/logger.rb#66 - def log_at(level); end - - # source://sidekiq//lib/sidekiq/logger.rb#39 - def warn?; end -end - -# source://sidekiq//lib/sidekiq/logger.rb#26 -Sidekiq::LoggingUtils::LEVELS = T.let(T.unsafe(nil), Hash) - -# Middleware is code configured to run before/after -# a job is processed. It is patterned after Rack -# middleware. Middleware exists for the client side -# (pushing jobs onto the queue) as well as the server -# side (when jobs are actually processed). -# -# Callers will register middleware Classes and Sidekiq will -# create new instances of the middleware for every job. This -# is important so that instance state is not shared accidentally -# between job executions. -# -# To add middleware for the client: -# -# Sidekiq.configure_client do |config| -# config.client_middleware do |chain| -# chain.add MyClientHook -# end -# end -# -# To modify middleware for the server, just call -# with another block: -# -# Sidekiq.configure_server do |config| -# config.server_middleware do |chain| -# chain.add MyServerHook -# chain.remove ActiveRecord -# end -# end -# -# To insert immediately preceding another entry: -# -# Sidekiq.configure_client do |config| -# config.client_middleware do |chain| -# chain.insert_before ActiveRecord, MyClientHook -# end -# end -# -# To insert immediately after another entry: -# -# Sidekiq.configure_client do |config| -# config.client_middleware do |chain| -# chain.insert_after ActiveRecord, MyClientHook -# end -# end -# -# This is an example of a minimal server middleware: -# -# class MyServerHook -# include Sidekiq::ServerMiddleware -# -# def call(job_instance, msg, queue) -# logger.info "Before job" -# redis {|conn| conn.get("foo") } # do something in Redis -# yield -# logger.info "After job" -# end -# end -# -# This is an example of a minimal client middleware, note -# the method must return the result or the job will not push -# to Redis: -# -# class MyClientHook -# include Sidekiq::ClientMiddleware -# -# def call(job_class, msg, queue, redis_pool) -# logger.info "Before push" -# result = yield -# logger.info "After push" -# result -# end -# end -# -# source://sidekiq//lib/sidekiq/middleware/chain.rb#79 -module Sidekiq::Middleware; end - -# source://sidekiq//lib/sidekiq/middleware/chain.rb#80 -class Sidekiq::Middleware::Chain - include ::Enumerable - - # @api private - # @return [Chain] a new instance of Chain - # @yield [_self] - # @yieldparam _self [Sidekiq::Middleware::Chain] the object that the method was called on - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#98 - def initialize(config = T.unsafe(nil)); end - - # Add the given middleware to the end of the chain. - # Sidekiq will call `klass.new(*args)` to create a clean - # copy of your middleware for every job executed. - # - # chain.add(Statsd::Metrics, { collector: "localhost:8125" }) - # - # @param klass [Class] Your middleware class - # @param *args [Array] Set of arguments to pass to every instance of your middleware - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#122 - def add(klass, *args); end - - # source://sidekiq//lib/sidekiq/middleware/chain.rb#165 - def clear; end - - # Iterate through each middleware in the chain - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#93 - def each(&block); end - - # @return [Boolean] if the chain contains no middleware - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#157 - def empty?; end - - # source://sidekiq//lib/sidekiq/middleware/chain.rb#104 - def entries; end - - # @return [Boolean] if the given class is already in the chain - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#152 - def exists?(klass); end - - # Inserts +newklass+ after +oldklass+ in the chain. - # Useful if one middleware must run after another middleware. - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#144 - def insert_after(oldklass, newklass, *args); end - - # Inserts +newklass+ before +oldklass+ in the chain. - # Useful if one middleware must run before another middleware. - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#135 - def insert_before(oldklass, newklass, *args); end - - # Used by Sidekiq to execute the middleware at runtime - # - # @api private - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#171 - def invoke(*args); end - - # Identical to {#add} except the middleware is added to the front of the chain. - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#128 - def prepend(klass, *args); end - - # Remove all middleware matching the given Class - # - # @param klass [Class] - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#110 - def remove(klass); end - - # source://sidekiq//lib/sidekiq/middleware/chain.rb#161 - def retrieve; end - - private - - # A unique instance of the middleware chain is created for - # each job executed in order to be thread-safe. - # - # @param copy [Sidekiq::Middleware::Chain] New instance of Chain - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#87 - def initialize_copy(copy); end -end - -# Represents each link in the middleware chain -# -# @api private -# -# source://sidekiq//lib/sidekiq/middleware/chain.rb#190 -class Sidekiq::Middleware::Entry - # @api private - # @return [Entry] a new instance of Entry - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#193 - def initialize(config, klass, *args); end - - # @api private - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#191 - def klass; end - - # @api private - # - # source://sidekiq//lib/sidekiq/middleware/chain.rb#199 - def make_new; end -end - -# source://sidekiq//lib/sidekiq.rb#17 -Sidekiq::NAME = T.let(T.unsafe(nil), String) - -# source://sidekiq//lib/sidekiq/rails.rb#6 -class Sidekiq::Rails < ::Rails::Engine; end - -# source://sidekiq//lib/sidekiq/rails.rb#7 -class Sidekiq::Rails::Reloader - # @return [Reloader] a new instance of Reloader - # - # source://sidekiq//lib/sidekiq/rails.rb#8 - def initialize(app = T.unsafe(nil)); end - - # source://sidekiq//lib/sidekiq/rails.rb#12 - def call; end - - # source://sidekiq//lib/sidekiq/rails.rb#18 - def inspect; end -end - -# source://sidekiq//lib/sidekiq/redis_connection.rb#8 -module Sidekiq::RedisConnection - class << self - # Returns the value of attribute adapter. - # - # source://sidekiq//lib/sidekiq/redis_connection.rb#63 - def adapter; end - - # RedisConnection.adapter = :redis - # RedisConnection.adapter = :redis_client - # - # source://sidekiq//lib/sidekiq/redis_connection.rb#67 - def adapter=(adapter); end - - # source://sidekiq//lib/sidekiq/redis_connection.rb#81 - def create(options = T.unsafe(nil)); end - - private - - # source://sidekiq//lib/sidekiq/redis_connection.rb#150 - def determine_redis_provider; end - - # source://sidekiq//lib/sidekiq/redis_connection.rb#125 - def log_info(options); end - - # Sidekiq needs many concurrent Redis connections. - # - # We need a connection for each Processor. - # We need a connection for Pro's real-time change listener - # We need a connection to various features to call Redis every few seconds: - # - the process heartbeat. - # - enterprise's leader election - # - enterprise's cron support - # - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/redis_connection.rb#121 - def verify_sizing(size, concurrency); end - end -end - -# source://sidekiq//lib/sidekiq/redis_connection.rb#9 -class Sidekiq::RedisConnection::RedisAdapter - # @return [RedisAdapter] a new instance of RedisAdapter - # - # source://sidekiq//lib/sidekiq/redis_connection.rb#13 - def initialize(options); end - - # source://sidekiq//lib/sidekiq/redis_connection.rb#18 - def new_client; end - - private - - # source://sidekiq//lib/sidekiq/redis_connection.rb#38 - def client_opts(options); end -end - -# source://sidekiq//lib/sidekiq/redis_connection.rb#10 -Sidekiq::RedisConnection::RedisAdapter::BaseError = Redis::BaseError - -# source://sidekiq//lib/sidekiq/redis_connection.rb#11 -Sidekiq::RedisConnection::RedisAdapter::CommandError = Redis::CommandError - -# source://sidekiq//lib/sidekiq/scheduled.rb#7 -module Sidekiq::Scheduled; end - -# source://sidekiq//lib/sidekiq/scheduled.rb#10 -class Sidekiq::Scheduled::Enq - # @return [Enq] a new instance of Enq - # - # source://sidekiq//lib/sidekiq/scheduled.rb#20 - def initialize; end - - # source://sidekiq//lib/sidekiq/scheduled.rb#25 - def enqueue_jobs(sorted_sets = T.unsafe(nil)); end - - # source://sidekiq//lib/sidekiq/scheduled.rb#42 - def terminate; end - - private - - # source://sidekiq//lib/sidekiq/scheduled.rb#48 - def zpopbyscore(conn, keys: T.unsafe(nil), argv: T.unsafe(nil)); end -end - -# source://sidekiq//lib/sidekiq/scheduled.rb#11 -Sidekiq::Scheduled::Enq::LUA_ZPOPBYSCORE = T.let(T.unsafe(nil), String) - -# The Poller checks Redis every N seconds for jobs in the retry or scheduled -# set have passed their timestamp and should be enqueued. If so, it -# just pops the job back onto its original queue so the -# workers can pick it up like any other job. -# -# source://sidekiq//lib/sidekiq/scheduled.rb#68 -class Sidekiq::Scheduled::Poller - include ::Sidekiq::Component - - # @return [Poller] a new instance of Poller - # - # source://sidekiq//lib/sidekiq/scheduled.rb#73 - def initialize(options); end - - # source://sidekiq//lib/sidekiq/scheduled.rb#107 - def enqueue; end - - # source://sidekiq//lib/sidekiq/scheduled.rb#95 - def start; end - - # Shut down this instance, will pause until the thread is dead. - # - # source://sidekiq//lib/sidekiq/scheduled.rb#83 - def terminate; end - - private - - # A copy of Sidekiq::ProcessSet#cleanup because server - # should never depend on sidekiq/api. - # - # source://sidekiq//lib/sidekiq/scheduled.rb#195 - def cleanup; end - - # source://sidekiq//lib/sidekiq/scheduled.rb#219 - def initial_wait; end - - # We do our best to tune the poll interval to the size of the active Sidekiq - # cluster. If you have 30 processes and poll every 15 seconds, that means one - # Sidekiq is checking Redis every 0.5 seconds - way too often for most people - # and really bad if the retry or scheduled sets are large. - # - # Instead try to avoid polling more than once every 15 seconds. If you have - # 30 Sidekiq processes, we'll poll every 30 * 15 or 450 seconds. - # To keep things statistically random, we'll sleep a random amount between - # 225 and 675 seconds for each poll or 450 seconds on average. Otherwise restarting - # all your Sidekiq processes at the same time will lead to them all polling at - # the same time: the thundering herd problem. - # - # We only do this if poll_interval_average is unset (the default). - # - # source://sidekiq//lib/sidekiq/scheduled.rb#176 - def poll_interval_average(count); end - - # source://sidekiq//lib/sidekiq/scheduled.rb#187 - def process_count; end - - # source://sidekiq//lib/sidekiq/scheduled.rb#130 - def random_poll_interval; end - - # Calculates an average poll interval based on the number of known Sidekiq processes. - # This minimizes a single point of failure by dispersing check-ins but without taxing - # Redis if you run many Sidekiq processes. - # - # source://sidekiq//lib/sidekiq/scheduled.rb#183 - def scaled_poll_interval(process_count); end - - # source://sidekiq//lib/sidekiq/scheduled.rb#118 - def wait; end -end - -# source://sidekiq//lib/sidekiq/scheduled.rb#71 -Sidekiq::Scheduled::Poller::INITIAL_WAIT = T.let(T.unsafe(nil), Integer) - -# source://sidekiq//lib/sidekiq/scheduled.rb#8 -Sidekiq::Scheduled::SETS = T.let(T.unsafe(nil), Array) - -# Server-side middleware must import this Module in order -# to get access to server resources during `call`. -# -# source://sidekiq//lib/sidekiq/middleware/modules.rb#4 -module Sidekiq::ServerMiddleware - # Returns the value of attribute config. - # - # source://sidekiq//lib/sidekiq/middleware/modules.rb#5 - def config; end - - # Sets the attribute config - # - # @param value the value to set the attribute config to. - # - # source://sidekiq//lib/sidekiq/middleware/modules.rb#5 - def config=(_arg0); end - - # source://sidekiq//lib/sidekiq/middleware/modules.rb#10 - def logger; end - - # source://sidekiq//lib/sidekiq/middleware/modules.rb#14 - def redis(&block); end - - # source://sidekiq//lib/sidekiq/middleware/modules.rb#6 - def redis_pool; end -end - -# We are shutting down Sidekiq but what about threads that -# are working on some long job? This error is -# raised in jobs that have not finished within the hard -# timeout limit. This is needed to rollback db transactions, -# otherwise Ruby's Thread#kill will commit. See #377. -# DO NOT RESCUE THIS ERROR IN YOUR JOBS -# -# source://sidekiq//lib/sidekiq.rb#342 -class Sidekiq::Shutdown < ::Interrupt; end - -# source://sidekiq//lib/sidekiq/transaction_aware_client.rb#7 -class Sidekiq::TransactionAwareClient - # @return [TransactionAwareClient] a new instance of TransactionAwareClient - # - # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#8 - def initialize(redis_pool); end - - # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#12 - def push(item); end - - # We don't provide transactionality for push_bulk because we don't want - # to hold potentially hundreds of thousands of job records in memory due to - # a long running enqueue process. - # - # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#24 - def push_bulk(items); end -end - -# source://sidekiq//lib/sidekiq/version.rb#4 -Sidekiq::VERSION = T.let(T.unsafe(nil), String) - -# Include this module in your worker class and you can easily create -# asynchronous jobs: -# -# class HardWorker -# include Sidekiq::Worker -# sidekiq_options queue: 'critical', retry: 5 -# -# def perform(*args) -# # do some work -# end -# end -# -# Then in your Rails app, you can do this: -# -# HardWorker.perform_async(1, 2, 3) -# -# Note that perform_async is a class method, perform is an instance method. -# -# Sidekiq::Worker also includes several APIs to provide compatibility with -# ActiveJob. -# -# class SomeWorker -# include Sidekiq::Worker -# queue_as :critical -# -# def perform(...) -# end -# end -# -# SomeWorker.set(wait_until: 1.hour).perform_async(123) -# -# Note that arguments passed to the job must still obey Sidekiq's -# best practice for simple, JSON-native data types. Sidekiq will not -# implement ActiveJob's more complex argument serialization. For -# this reason, we don't implement `perform_later` as our call semantics -# are very different. -# -# source://sidekiq//lib/sidekiq/worker.rb#44 -module Sidekiq::Worker - include ::Sidekiq::Worker::Options - - mixes_in_class_methods ::Sidekiq::Worker::Options::ClassMethods - mixes_in_class_methods ::Sidekiq::Worker::ClassMethods - - # Returns the value of attribute jid. - # - # source://sidekiq//lib/sidekiq/worker.rb#156 - def jid; end - - # Sets the attribute jid - # - # @param value the value to set the attribute jid to. - # - # source://sidekiq//lib/sidekiq/worker.rb#156 - def jid=(_arg0); end - - # source://sidekiq//lib/sidekiq/worker.rb#165 - def logger; end - - class << self - # @private - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/worker.rb#158 - def included(base); end - end -end - -# source://sidekiq//lib/sidekiq/worker.rb#267 -module Sidekiq::Worker::ClassMethods - # source://sidekiq//lib/sidekiq/worker.rb#363 - def build_client; end - - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/worker.rb#358 - def client_push(item); end - - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/worker.rb#268 - def delay(*args); end - - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/worker.rb#272 - def delay_for(*args); end - - # @raise [ArgumentError] - # - # source://sidekiq//lib/sidekiq/worker.rb#276 - def delay_until(*args); end - - # source://sidekiq//lib/sidekiq/worker.rb#288 - def perform_async(*args); end - - # +interval+ must be a timestamp, numeric or something that acts - # numeric (like an activesupport time interval). - # - # source://sidekiq//lib/sidekiq/worker.rb#324 - def perform_at(interval, *args); end - - # Push a large number of jobs to Redis, while limiting the batch of - # each job payload to 1,000. This method helps cut down on the number - # of round trips to Redis, which can increase the performance of enqueueing - # large numbers of jobs. - # - # +items+ must be an Array of Arrays. - # - # For finer-grained control, use `Sidekiq::Client.push_bulk` directly. - # - # Example (3 Redis round trips): - # - # SomeWorker.perform_async(1) - # SomeWorker.perform_async(2) - # SomeWorker.perform_async(3) - # - # Would instead become (1 Redis round trip): - # - # SomeWorker.perform_bulk([[1], [2], [3]]) - # - # source://sidekiq//lib/sidekiq/worker.rb#318 - def perform_bulk(*args, **kwargs); end - - # +interval+ must be a timestamp, numeric or something that acts - # numeric (like an activesupport time interval). - # - # source://sidekiq//lib/sidekiq/worker.rb#324 - def perform_in(interval, *args); end - - # Inline execution of job's perform method after passing through Sidekiq.client_middleware and Sidekiq.server_middleware - # - # source://sidekiq//lib/sidekiq/worker.rb#293 - def perform_inline(*args); end - - # Inline execution of job's perform method after passing through Sidekiq.client_middleware and Sidekiq.server_middleware - # - # source://sidekiq//lib/sidekiq/worker.rb#293 - def perform_sync(*args); end - - # source://sidekiq//lib/sidekiq/worker.rb#280 - def queue_as(q); end - - # source://sidekiq//lib/sidekiq/worker.rb#284 - def set(options); end - - # Allows customization for this type of Worker. - # Legal options: - # - # queue - use a named queue for this Worker, default 'default' - # retry - enable retries via JobRetry, *true* to use the default - # or *Integer* count - # backtrace - whether to save any error backtrace in the retry payload to display in web UI, - # can be true, false or an integer number of lines to save, default *false* - # pool - use the given Redis connection pool to push this type of job to a given shard. - # - # In practice, any option is allowed. This is the main mechanism to configure the - # options for a specific job. - # - # These options will be saved into the serialized job when enqueued by - # the client. - # - # source://sidekiq//lib/sidekiq/worker.rb#354 - def sidekiq_options(opts = T.unsafe(nil)); end -end - -# The Options module is extracted so we can include it in ActiveJob::Base -# and allow native AJs to configure Sidekiq features/internals. -# -# source://sidekiq//lib/sidekiq/worker.rb#48 -module Sidekiq::Worker::Options - mixes_in_class_methods ::Sidekiq::Worker::Options::ClassMethods - - class << self - # @private - # - # source://sidekiq//lib/sidekiq/worker.rb#49 - def included(base); end - end -end - -# source://sidekiq//lib/sidekiq/worker.rb#56 -module Sidekiq::Worker::Options::ClassMethods - # source://sidekiq//lib/sidekiq/worker.rb#84 - def get_sidekiq_options; end - - # source://sidekiq//lib/sidekiq/worker.rb#88 - def sidekiq_class_attribute(*attrs); end - - # Allows customization for this type of Worker. - # Legal options: - # - # queue - name of queue to use for this job type, default *default* - # retry - enable retries for this Worker in case of error during execution, - # *true* to use the default or *Integer* count - # backtrace - whether to save any error backtrace in the retry payload to display in web UI, - # can be true, false or an integer number of lines to save, default *false* - # - # In practice, any option is allowed. This is the main mechanism to configure the - # options for a specific job. - # - # source://sidekiq//lib/sidekiq/worker.rb#71 - def sidekiq_options(opts = T.unsafe(nil)); end - - # source://sidekiq//lib/sidekiq/worker.rb#80 - def sidekiq_retries_exhausted(&block); end - - # source://sidekiq//lib/sidekiq/worker.rb#76 - def sidekiq_retry_in(&block); end -end - -# source://sidekiq//lib/sidekiq/worker.rb#57 -Sidekiq::Worker::Options::ClassMethods::ACCESSOR_MUTEX = T.let(T.unsafe(nil), Thread::Mutex) - -# This helper class encapsulates the set options for `set`, e.g. -# -# SomeWorker.set(queue: 'foo').perform_async(....) -# -# source://sidekiq//lib/sidekiq/worker.rb#173 -class Sidekiq::Worker::Setter - include ::Sidekiq::JobUtil - - # @return [Setter] a new instance of Setter - # - # source://sidekiq//lib/sidekiq/worker.rb#176 - def initialize(klass, opts); end - - # source://sidekiq//lib/sidekiq/worker.rb#194 - def perform_async(*args); end - - # +interval+ must be a timestamp, numeric or something that acts - # numeric (like an activesupport time interval). - # - # source://sidekiq//lib/sidekiq/worker.rb#250 - def perform_at(interval, *args); end - - # source://sidekiq//lib/sidekiq/worker.rb#239 - def perform_bulk(args, batch_size: T.unsafe(nil)); end - - # +interval+ must be a timestamp, numeric or something that acts - # numeric (like an activesupport time interval). - # - # source://sidekiq//lib/sidekiq/worker.rb#250 - def perform_in(interval, *args); end - - # Explicit inline execution of a job. Returns nil if the job did not - # execute, true otherwise. - # - # source://sidekiq//lib/sidekiq/worker.rb#204 - def perform_inline(*args); end - - # Explicit inline execution of a job. Returns nil if the job did not - # execute, true otherwise. - # - # source://sidekiq//lib/sidekiq/worker.rb#204 - def perform_sync(*args); end - - # source://sidekiq//lib/sidekiq/worker.rb#186 - def set(options); end - - private - - # source://sidekiq//lib/sidekiq/worker.rb#257 - def at(interval); end -end diff --git a/sorbet/rbi/gems/sidekiq@7.3.0.rbi b/sorbet/rbi/gems/sidekiq@7.3.0.rbi new file mode 100644 index 000000000..37e550f04 --- /dev/null +++ b/sorbet/rbi/gems/sidekiq@7.3.0.rbi @@ -0,0 +1,1880 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `sidekiq` gem. +# Please instead update this file by running `bin/tapioca gem sidekiq`. + + +# Use `Sidekiq.transactional_push!` in your sidekiq.rb initializer +# +# source://sidekiq//lib/sidekiq/version.rb#3 +module Sidekiq + class << self + # @yield [default_configuration] + # + # source://sidekiq//lib/sidekiq.rb#135 + def configure_client; end + + # Creates a Sidekiq::Config instance that is more tuned for embedding + # within an arbitrary Ruby process. Notably it reduces concurrency by + # default so there is less contention for CPU time with other threads. + # + # inst = Sidekiq.configure_embed do |config| + # config.queues = %w[critical default low] + # end + # inst.run + # sleep 10 + # inst.stop + # + # NB: it is really easy to overload a Ruby process with threads due to the GIL. + # I do not recommend setting concurrency higher than 2-3. + # + # NB: Sidekiq only supports one instance in memory. You will get undefined behavior + # if you try to embed Sidekiq twice in the same process. + # + # @yield [cfg] + # + # source://sidekiq//lib/sidekiq.rb#123 + def configure_embed(&block); end + + # @yield [default_configuration] + # + # source://sidekiq//lib/sidekiq.rb#97 + def configure_server(&block); end + + # source://sidekiq//lib/sidekiq.rb#89 + def default_configuration; end + + # source://sidekiq//lib/sidekiq.rb#85 + def default_job_options; end + + # source://sidekiq//lib/sidekiq.rb#81 + def default_job_options=(hash); end + + # source://sidekiq//lib/sidekiq.rb#57 + def dump_json(object); end + + # @return [Boolean] + # + # source://sidekiq//lib/sidekiq.rb#65 + def ent?; end + + # source://sidekiq//lib/sidekiq.rb#102 + def freeze!; end + + # source://sidekiq//lib/sidekiq.rb#53 + def load_json(string); end + + # source://sidekiq//lib/sidekiq.rb#93 + def logger; end + + # @return [Boolean] + # + # source://sidekiq//lib/sidekiq.rb#61 + def pro?; end + + # source://sidekiq//lib/sidekiq.rb#73 + def redis(&block); end + + # source://sidekiq//lib/sidekiq.rb#69 + def redis_pool; end + + # @return [Boolean] + # + # source://sidekiq//lib/sidekiq.rb#49 + def server?; end + + # source://sidekiq//lib/sidekiq.rb#77 + def strict_args!(mode = T.unsafe(nil)); end + + # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#40 + def transactional_push!; end + + # source://sidekiq//lib/sidekiq.rb#45 + def ❨╯°□°❩╯︵┻━┻; end + end +end + +# source://sidekiq//lib/sidekiq/client.rb#8 +class Sidekiq::Client + include ::Sidekiq::JobUtil + + # Sidekiq::Client is responsible for pushing job payloads to Redis. + # Requires the :pool or :config keyword argument. + # + # Sidekiq::Client.new(pool: Sidekiq::RedisConnection.create) + # + # Inside the Sidekiq process, you can reuse the configured resources: + # + # Sidekiq::Client.new(config: config) + # + # @param pool [ConnectionPool] explicit Redis pool to use + # @param config [Sidekiq::Config] use the pool and middleware from the given Sidekiq container + # @param chain [Sidekiq::Middleware::Chain] use the given middleware chain + # @return [Client] a new instance of Client + # + # source://sidekiq//lib/sidekiq/client.rb#45 + def initialize(*args, **kwargs); end + + # Define client-side middleware: + # + # client = Sidekiq::Client.new + # client.middleware do |chain| + # chain.use MyClientMiddleware + # end + # client.push('class' => 'SomeJob', 'args' => [1,2,3]) + # + # All client instances default to the globally-defined + # Sidekiq.client_middleware but you can change as necessary. + # + # source://sidekiq//lib/sidekiq/client.rb#23 + def middleware(&block); end + + # The main method used to push a job to Redis. Accepts a number of options: + # + # queue - the named queue to use, default 'default' + # class - the job class to call, required + # args - an array of simple arguments to the perform method, must be JSON-serializable + # at - timestamp to schedule the job (optional), must be Numeric (e.g. Time.now.to_f) + # retry - whether to retry this job if it fails, default true or an integer number of retries + # retry_for - relative amount of time to retry this job if it fails, default nil + # backtrace - whether to save any error backtrace, default false + # + # If class is set to the class name, the jobs' options will be based on Sidekiq's default + # job options. Otherwise, they will be based on the job class's options. + # + # Any options valid for a job class's sidekiq_options are also available here. + # + # All keys must be strings, not symbols. NB: because we are serializing to JSON, all + # symbols in 'args' will be converted to strings. Note that +backtrace: true+ can take quite a bit of + # space in Redis; a large volume of failing jobs can start Redis swapping if you aren't careful. + # + # Returns a unique Job ID. If middleware stops the job, nil will be returned instead. + # + # Example: + # push('queue' => 'my_queue', 'class' => MyJob, 'args' => ['foo', 1, :bat => 'bar']) + # + # source://sidekiq//lib/sidekiq/client.rb#86 + def push(item); end + + # Push a large number of jobs to Redis. This method cuts out the redis + # network round trip latency. It pushes jobs in batches if more than + # `:batch_size` (1000 by default) of jobs are passed. I wouldn't recommend making `:batch_size` + # larger than 1000 but YMMV based on network quality, size of job args, etc. + # A large number of jobs can cause a bit of Redis command processing latency. + # + # Takes the same arguments as #push except that args is expected to be + # an Array of Arrays. All other keys are duplicated for each job. Each job + # is run through the client middleware pipeline and each job gets its own Job ID + # as normal. + # + # Returns an array of the of pushed jobs' jids, may contain nils if any client middleware + # prevented a job push. + # + # Example (pushing jobs in batches): + # push_bulk('class' => MyJob, 'args' => (1..100_000).to_a, batch_size: 1_000) + # + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/client.rb#116 + def push_bulk(items); end + + # Returns the value of attribute redis_pool. + # + # source://sidekiq//lib/sidekiq/client.rb#31 + def redis_pool; end + + # Sets the attribute redis_pool + # + # @param value the value to set the attribute redis_pool to. + # + # source://sidekiq//lib/sidekiq/client.rb#31 + def redis_pool=(_arg0); end + + private + + # source://sidekiq//lib/sidekiq/client.rb#248 + def atomic_push(conn, payloads); end + + # source://sidekiq//lib/sidekiq/client.rb#224 + def raw_push(payloads); end + + class << self + # Resque compatibility helpers. Note all helpers + # should go through Sidekiq::Job#client_push. + # + # Example usage: + # Sidekiq::Client.enqueue(MyJob, 'foo', 1, :bat => 'bar') + # + # Messages are enqueued to the 'default' queue. + # + # source://sidekiq//lib/sidekiq/client.rb#189 + def enqueue(klass, *args); end + + # Example usage: + # Sidekiq::Client.enqueue_in(3.minutes, MyJob, 'foo', 1, :bat => 'bar') + # + # source://sidekiq//lib/sidekiq/client.rb#217 + def enqueue_in(interval, klass, *args); end + + # Example usage: + # Sidekiq::Client.enqueue_to(:queue_name, MyJob, 'foo', 1, :bat => 'bar') + # + # source://sidekiq//lib/sidekiq/client.rb#196 + def enqueue_to(queue, klass, *args); end + + # Example usage: + # Sidekiq::Client.enqueue_to_in(:queue_name, 3.minutes, MyJob, 'foo', 1, :bat => 'bar') + # + # source://sidekiq//lib/sidekiq/client.rb#203 + def enqueue_to_in(queue, interval, klass, *args); end + + # source://sidekiq//lib/sidekiq/client.rb#173 + def push(item); end + + # source://sidekiq//lib/sidekiq/client.rb#177 + def push_bulk(*_arg0, **_arg1, &_arg2); end + + # Allows sharding of jobs across any number of Redis instances. All jobs + # defined within the block will use the given Redis connection pool. + # + # pool = ConnectionPool.new { Redis.new } + # Sidekiq::Client.via(pool) do + # SomeJob.perform_async(1,2,3) + # SomeOtherJob.perform_async(1,2,3) + # end + # + # Generally this is only needed for very large Sidekiq installs processing + # thousands of jobs per second. I do not recommend sharding unless + # you cannot scale any other way (e.g. splitting your app into smaller apps). + # + # source://sidekiq//lib/sidekiq/client.rb#163 + def via(pool); end + end +end + +# no difference for now +# +# source://sidekiq//lib/sidekiq/middleware/modules.rb#20 +Sidekiq::ClientMiddleware = Sidekiq::ServerMiddleware + +# Sidekiq::Component assumes a config instance is available at @config +# +# source://sidekiq//lib/sidekiq/component.rb#6 +module Sidekiq::Component + # source://sidekiq//lib/sidekiq/component.rb#7 + def config; end + + # source://sidekiq//lib/sidekiq/component.rb#51 + def fire_event(event, options = T.unsafe(nil)); end + + # source://sidekiq//lib/sidekiq/component.rb#47 + def handle_exception(ex, ctx = T.unsafe(nil)); end + + # source://sidekiq//lib/sidekiq/component.rb#35 + def hostname; end + + # source://sidekiq//lib/sidekiq/component.rb#43 + def identity; end + + # source://sidekiq//lib/sidekiq/component.rb#23 + def logger; end + + # source://sidekiq//lib/sidekiq/component.rb#39 + def process_nonce; end + + # source://sidekiq//lib/sidekiq/component.rb#27 + def redis(&block); end + + # source://sidekiq//lib/sidekiq/component.rb#16 + def safe_thread(name, &block); end + + # source://sidekiq//lib/sidekiq/component.rb#31 + def tid; end + + # source://sidekiq//lib/sidekiq/component.rb#9 + def watchdog(last_words); end +end + +# Sidekiq::Config represents the global configuration for an instance of Sidekiq. +# +# source://sidekiq//lib/sidekiq/config.rb#8 +class Sidekiq::Config + extend ::Forwardable + + # @return [Config] a new instance of Config + # + # source://sidekiq//lib/sidekiq/config.rb#51 + def initialize(options = T.unsafe(nil)); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def [](*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def []=(*args, **_arg1, &block); end + + # How frequently Redis should be checked by a random Sidekiq process for + # scheduled and retriable jobs. Each individual process will take turns by + # waiting some multiple of this value. + # + # See sidekiq/scheduled.rb for an in-depth explanation of this value + # + # source://sidekiq//lib/sidekiq/config.rb#216 + def average_scheduled_poll_interval=(interval); end + + # register a new queue processing subsystem + # + # @yield [cap] + # + # source://sidekiq//lib/sidekiq/config.rb#115 + def capsule(name); end + + # Returns the value of attribute capsules. + # + # source://sidekiq//lib/sidekiq/config.rb#60 + def capsules; end + + # @yield [@client_chain] + # + # source://sidekiq//lib/sidekiq/config.rb#98 + def client_middleware; end + + # source://sidekiq//lib/sidekiq/config.rb#72 + def concurrency; end + + # LEGACY: edits the default capsule + # config.concurrency = 5 + # + # source://sidekiq//lib/sidekiq/config.rb#68 + def concurrency=(val); end + + # Death handlers are called when all retries for a job have been exhausted and + # the job dies. It's the notification to your application + # that this job will not succeed without manual intervention. + # + # Sidekiq.configure_server do |config| + # config.death_handlers << ->(job, ex) do + # end + # end + # + # source://sidekiq//lib/sidekiq/config.rb#207 + def death_handlers; end + + # source://sidekiq//lib/sidekiq/config.rb#110 + def default_capsule(&block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def dig(*args, **_arg1, &block); end + + # Register a proc to handle any error which occurs within the Sidekiq process. + # + # Sidekiq.configure_server do |config| + # config.error_handlers << proc {|ex,ctx_hash| MyErrorService.notify(ex, ctx_hash) } + # end + # + # The default error handler logs errors to @logger. + # + # source://sidekiq//lib/sidekiq/config.rb#227 + def error_handlers; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def fetch(*args, **_arg1, &block); end + + # INTERNAL USE ONLY + # + # source://sidekiq//lib/sidekiq/config.rb#271 + def handle_exception(ex, ctx = T.unsafe(nil)); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def has_key?(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def key?(*args, **_arg1, &block); end + + # source://sidekiq//lib/sidekiq/config.rb#245 + def logger; end + + # source://sidekiq//lib/sidekiq/config.rb#256 + def logger=(logger); end + + # find a singleton + # + # source://sidekiq//lib/sidekiq/config.rb#190 + def lookup(name, default_class = T.unsafe(nil)); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def merge!(*args, **_arg1, &block); end + + # source://sidekiq//lib/sidekiq/config.rb#140 + def new_redis_pool(size, name = T.unsafe(nil)); end + + # Register a block to run at a point in the Sidekiq lifecycle. + # :startup, :quiet or :shutdown are valid events. + # + # Sidekiq.configure_server do |config| + # config.on(:shutdown) do + # puts "Goodbye cruel world!" + # end + # end + # + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/config.rb#239 + def on(event, &block); end + + # source://sidekiq//lib/sidekiq/config.rb#94 + def queues; end + + # Edit the default capsule. + # config.queues = %w( high default low ) # strict + # config.queues = %w( high,3 default,2 low,1 ) # weighted + # config.queues = %w( feature1,1 feature2,1 feature3,1 ) # random + # + # With weighted priority, queue will be checked first (weight / total) of the time. + # high will be checked first (3/6) or 50% of the time. + # I'd recommend setting weights between 1-10. Weights in the hundreds or thousands + # are ridiculous and unnecessarily expensive. You can get random queue ordering + # by explicitly setting all weights to 1. + # + # source://sidekiq//lib/sidekiq/config.rb#90 + def queues=(val); end + + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/config.rb#162 + def redis; end + + # All capsules must use the same Redis configuration + # + # source://sidekiq//lib/sidekiq/config.rb#126 + def redis=(hash); end + + # source://sidekiq//lib/sidekiq/config.rb#146 + def redis_info; end + + # source://sidekiq//lib/sidekiq/config.rb#130 + def redis_pool; end + + # register global singletons which can be accessed elsewhere + # + # source://sidekiq//lib/sidekiq/config.rb#185 + def register(name, instance); end + + # @yield [@server_chain] + # + # source://sidekiq//lib/sidekiq/config.rb#104 + def server_middleware; end + + # source://sidekiq//lib/sidekiq/config.rb#62 + def to_json(*_arg0); end + + # source://sidekiq//lib/sidekiq/config.rb#76 + def total_concurrency; end + + private + + # source://sidekiq//lib/sidekiq/config.rb#134 + def local_redis_pool; end + + # source://sidekiq//lib/sidekiq/config.rb#265 + def parameter_size(handler); end +end + +# source://sidekiq//lib/sidekiq/config.rb#11 +Sidekiq::Config::DEFAULTS = T.let(T.unsafe(nil), Hash) + +# source://sidekiq//lib/sidekiq/config.rb#41 +Sidekiq::Config::ERROR_HANDLER = T.let(T.unsafe(nil), Proc) + +# source://sidekiq//lib/sidekiq/logger.rb#7 +module Sidekiq::Context + class << self + # source://sidekiq//lib/sidekiq/logger.rb#20 + def add(k, v); end + + # source://sidekiq//lib/sidekiq/logger.rb#16 + def current; end + + # source://sidekiq//lib/sidekiq/logger.rb#8 + def with(hash); end + end +end + +# source://sidekiq//lib/sidekiq/iterable_job.rb#32 +module Sidekiq::IterableJob + include ::Sidekiq::Job::Options + include ::Sidekiq::Job + include ::Sidekiq::Job::Iterable + + mixes_in_class_methods ::Sidekiq::Job::Options::ClassMethods + mixes_in_class_methods ::Sidekiq::Job::ClassMethods + mixes_in_class_methods ::Sidekiq::Job::Iterable::ClassMethods + + class << self + # @private + # + # source://sidekiq//lib/sidekiq/iterable_job.rb#33 + def included(base); end + end +end + +# Include this module in your job class and you can easily create +# asynchronous jobs: +# +# class HardJob +# include Sidekiq::Job +# sidekiq_options queue: 'critical', retry: 5 +# +# def perform(*args) +# # do some work +# end +# end +# +# Then in your Rails app, you can do this: +# +# HardJob.perform_async(1, 2, 3) +# +# Note that perform_async is a class method, perform is an instance method. +# +# Sidekiq::Job also includes several APIs to provide compatibility with +# ActiveJob. +# +# class SomeJob +# include Sidekiq::Job +# queue_as :critical +# +# def perform(...) +# end +# end +# +# SomeJob.set(wait_until: 1.hour).perform_async(123) +# +# Note that arguments passed to the job must still obey Sidekiq's +# best practice for simple, JSON-native data types. Sidekiq will not +# implement ActiveJob's more complex argument serialization. For +# this reason, we don't implement `perform_later` as our call semantics +# are very different. +# +# source://sidekiq//lib/sidekiq/job.rb#44 +module Sidekiq::Job + include ::Sidekiq::Job::Options + + mixes_in_class_methods ::Sidekiq::Job::Options::ClassMethods + mixes_in_class_methods ::Sidekiq::Job::ClassMethods + + # This attribute is implementation-specific and not a public API + # + # source://sidekiq//lib/sidekiq/job.rb#163 + def _context; end + + # This attribute is implementation-specific and not a public API + # + # source://sidekiq//lib/sidekiq/job.rb#163 + def _context=(_arg0); end + + # @return [Boolean] + # + # source://sidekiq//lib/sidekiq/job.rb#176 + def interrupted?; end + + # Returns the value of attribute jid. + # + # source://sidekiq//lib/sidekiq/job.rb#160 + def jid; end + + # Sets the attribute jid + # + # @param value the value to set the attribute jid to. + # + # source://sidekiq//lib/sidekiq/job.rb#160 + def jid=(_arg0); end + + # source://sidekiq//lib/sidekiq/job.rb#172 + def logger; end + + class << self + # @private + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/job.rb#165 + def included(base); end + end +end + +# The Sidekiq testing infrastructure overrides perform_async +# so that it does not actually touch the network. Instead it +# stores the asynchronous jobs in a per-class array so that +# their presence/absence can be asserted by your tests. +# +# This is similar to ActionMailer's :test delivery_method and its +# ActionMailer::Base.deliveries array. +# +# Example: +# +# require 'sidekiq/testing' +# +# assert_equal 0, HardJob.jobs.size +# HardJob.perform_async(:something) +# assert_equal 1, HardJob.jobs.size +# assert_equal :something, HardJob.jobs[0]['args'][0] +# +# You can also clear and drain all job types: +# +# Sidekiq::Job.clear_all # or .drain_all +# +# This can be useful to make sure jobs don't linger between tests: +# +# RSpec.configure do |config| +# config.before(:each) do +# Sidekiq::Job.clear_all +# end +# end +# +# or for acceptance testing, i.e. with cucumber: +# +# AfterStep do +# Sidekiq::Job.drain_all +# end +# +# When I sign up as "foo@example.com" +# Then I should receive a welcome email to "foo@example.com" +# +# source://sidekiq//lib/sidekiq/job.rb#275 +module Sidekiq::Job::ClassMethods + # source://sidekiq//lib/sidekiq/job.rb#378 + def build_client; end + + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/job.rb#363 + def client_push(item); end + + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/job.rb#276 + def delay(*args); end + + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/job.rb#280 + def delay_for(*args); end + + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/job.rb#284 + def delay_until(*args); end + + # source://sidekiq//lib/sidekiq/job.rb#296 + def perform_async(*args); end + + # +interval+ must be a timestamp, numeric or something that acts + # numeric (like an activesupport time interval). + # + # source://sidekiq//lib/sidekiq/job.rb#332 + def perform_at(interval, *args); end + + # Push a large number of jobs to Redis, while limiting the batch of + # each job payload to 1,000. This method helps cut down on the number + # of round trips to Redis, which can increase the performance of enqueueing + # large numbers of jobs. + # + # +items+ must be an Array of Arrays. + # + # For finer-grained control, use `Sidekiq::Client.push_bulk` directly. + # + # Example (3 Redis round trips): + # + # SomeJob.perform_async(1) + # SomeJob.perform_async(2) + # SomeJob.perform_async(3) + # + # Would instead become (1 Redis round trip): + # + # SomeJob.perform_bulk([[1], [2], [3]]) + # + # source://sidekiq//lib/sidekiq/job.rb#326 + def perform_bulk(*args, **kwargs); end + + # +interval+ must be a timestamp, numeric or something that acts + # numeric (like an activesupport time interval). + # + # source://sidekiq//lib/sidekiq/job.rb#332 + def perform_in(interval, *args); end + + # Inline execution of job's perform method after passing through Sidekiq.client_middleware and Sidekiq.server_middleware + # + # source://sidekiq//lib/sidekiq/job.rb#301 + def perform_inline(*args); end + + # Inline execution of job's perform method after passing through Sidekiq.client_middleware and Sidekiq.server_middleware + # + # source://sidekiq//lib/sidekiq/job.rb#301 + def perform_sync(*args); end + + # source://sidekiq//lib/sidekiq/job.rb#288 + def queue_as(q); end + + # source://sidekiq//lib/sidekiq/job.rb#292 + def set(options); end + + # Allows customization for this type of Job. + # Legal options: + # + # queue - use a named queue for this Job, default 'default' + # retry - enable the RetryJobs middleware for this Job, *true* to use the default + # or *Integer* count + # backtrace - whether to save any error backtrace in the retry payload to display in web UI, + # can be true, false or an integer number of lines to save, default *false* + # pool - use the given Redis connection pool to push this type of job to a given shard. + # + # In practice, any option is allowed. This is the main mechanism to configure the + # options for a specific job. + # + # source://sidekiq//lib/sidekiq/job.rb#359 + def sidekiq_options(opts = T.unsafe(nil)); end +end + +# source://sidekiq//lib/sidekiq/job/iterable.rb#7 +class Sidekiq::Job::Interrupted < ::RuntimeError; end + +# source://sidekiq//lib/sidekiq/job/iterable/active_record_enumerator.rb#5 +module Sidekiq::Job::Iterable + include ::Sidekiq::Job::Iterable::Enumerators + + mixes_in_class_methods ::Sidekiq::Job::Iterable::ClassMethods + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#26 + def initialize; end + + # A hook to override that will be called around each iteration. + # + # Can be useful for some metrics collection, performance tracking etc. + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#46 + def around_iteration; end + + # The enumerator to be iterated over. + # + # @raise [NotImplementedError] with a message advising subclasses to + # implement an override for this method. + # @return [Enumerator] + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#74 + def build_enumerator(*_arg0); end + + # The action to be performed on each item from the enumerator. + # + # @raise [NotImplementedError] with a message advising subclasses to + # implement an override for this method. + # @return [void] + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#85 + def each_iteration(*_arg0); end + + # source://sidekiq//lib/sidekiq/job/iterable.rb#89 + def iteration_key; end + + # A hook to override that will be called when the job finished iterating. + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#64 + def on_complete; end + + # A hook to override that will be called when the job resumes iterating. + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#52 + def on_resume; end + + # A hook to override that will be called when the job starts iterating. + # + # It is called only once, for the first time. + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#39 + def on_start; end + + # A hook to override that will be called each time the job is interrupted. + # + # This can be due to interruption or sidekiq stopping. + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#59 + def on_stop; end + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#94 + def perform(*arguments); end + + private + + # source://sidekiq//lib/sidekiq/job/iterable.rb#180 + def assert_enumerator!(enum); end + + # source://sidekiq//lib/sidekiq/job/iterable.rb#211 + def cleanup; end + + # source://sidekiq//lib/sidekiq/job/iterable.rb#131 + def fetch_previous_iteration_state; end + + # source://sidekiq//lib/sidekiq/job/iterable.rb#195 + def flush_state; end + + # source://sidekiq//lib/sidekiq/job/iterable.rb#218 + def handle_completed(completed); end + + # one month + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#146 + def iterate_with_enumerator(enumerator, arguments); end + + # @raise [Interrupted] + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#173 + def reenqueue_iteration_job; end + + class << self + # @api private + # @private + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#13 + def included(base); end + end +end + +# @api private +# +# source://sidekiq//lib/sidekiq/job/iterable/active_record_enumerator.rb#7 +class Sidekiq::Job::Iterable::ActiveRecordEnumerator + # @api private + # @return [ActiveRecordEnumerator] a new instance of ActiveRecordEnumerator + # + # source://sidekiq//lib/sidekiq/job/iterable/active_record_enumerator.rb#8 + def initialize(relation, cursor: T.unsafe(nil), **options); end + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable/active_record_enumerator.rb#22 + def batches; end + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable/active_record_enumerator.rb#14 + def records; end + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable/active_record_enumerator.rb#30 + def relations; end + + private + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable/active_record_enumerator.rb#46 + def relations_size; end +end + +# @api private +# +# source://sidekiq//lib/sidekiq/job/iterable.rb#18 +module Sidekiq::Job::Iterable::ClassMethods + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable.rb#19 + def method_added(method_name); end +end + +# @api private +# +# source://sidekiq//lib/sidekiq/job/iterable/csv_enumerator.rb#7 +class Sidekiq::Job::Iterable::CsvEnumerator + # @api private + # @return [CsvEnumerator] a new instance of CsvEnumerator + # + # source://sidekiq//lib/sidekiq/job/iterable/csv_enumerator.rb#8 + def initialize(csv); end + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable/csv_enumerator.rb#23 + def batches(cursor:, batch_size: T.unsafe(nil)); end + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable/csv_enumerator.rb#16 + def rows(cursor:); end + + private + + # @api private + # + # source://sidekiq//lib/sidekiq/job/iterable/csv_enumerator.rb#33 + def count_of_rows_in_file; end +end + +# source://sidekiq//lib/sidekiq/job/iterable/enumerators.rb#9 +module Sidekiq::Job::Iterable::Enumerators + # Builds Enumerator from `ActiveRecord::Relation` and enumerates on batches of records. + # Each Enumerator tick moves the cursor `:batch_size` rows forward. + # + # @example + # def build_enumerator(product_id, cursor:) + # active_record_batches_enumerator( + # Comment.where(product_id: product_id).select(:id), + # cursor: cursor, + # batch_size: 100 + # ) + # end + # + # def each_iteration(batch_of_comments, product_id) + # comment_ids = batch_of_comments.map(&:id) + # CommentService.call(comment_ids: comment_ids) + # end + # @see #active_record_records_enumerator + # + # source://sidekiq//lib/sidekiq/job/iterable/enumerators.rb#68 + def active_record_batches_enumerator(relation, cursor:, **options); end + + # Builds Enumerator from `ActiveRecord::Relation`. + # Each Enumerator tick moves the cursor one row forward. + # + # @example + # def build_enumerator(cursor:) + # active_record_records_enumerator(User.all, cursor: cursor) + # end + # + # def each_iteration(user) + # user.notify_about_something + # end + # @param relation [ActiveRecord::Relation] relation to iterate + # @param cursor [Object] offset id to start iteration from + # @param options [Hash] additional options that will be passed to relevant + # ActiveRecord batching methods + # @return [ActiveRecordEnumerator] + # + # source://sidekiq//lib/sidekiq/job/iterable/enumerators.rb#46 + def active_record_records_enumerator(relation, cursor:, **options); end + + # Builds Enumerator from `ActiveRecord::Relation` and enumerates on batches, + # yielding `ActiveRecord::Relation`s. + # + # @example + # def build_enumerator(product_id, cursor:) + # active_record_relations_enumerator( + # Product.find(product_id).comments, + # cursor: cursor, + # batch_size: 100, + # ) + # end + # + # def each_iteration(batch_of_comments, product_id) + # # batch_of_comments will be a Comment::ActiveRecord_Relation + # batch_of_comments.update_all(deleted: true) + # end + # @see #active_record_records_enumerator + # + # source://sidekiq//lib/sidekiq/job/iterable/enumerators.rb#90 + def active_record_relations_enumerator(relation, cursor:, **options); end + + # Builds Enumerator object from a given array, using +cursor+ as an offset. + # + # @example + # array_enumerator(['build', 'enumerator', 'from', 'any', 'array'], cursor: cursor) + # @param array [Array] + # @param cursor [Integer] offset to start iteration from + # @raise [ArgumentError] + # @return [Enumerator] + # + # source://sidekiq//lib/sidekiq/job/iterable/enumerators.rb#20 + def array_enumerator(array, cursor:); end + + # Builds Enumerator from a CSV file and enumerates on batches of records. + # + # @example + # def build_enumerator(import_id, cursor:) + # import = Import.find(import_id) + # csv_batches_enumerator(import.csv, cursor: cursor) + # end + # + # def each_iteration(batch_of_csv_rows) + # # ... + # end + # @option options + # @param csv [CSV] an instance of CSV object + # @param cursor [Integer] offset to start iteration from + # @param options [Hash] a customizable set of options + # + # source://sidekiq//lib/sidekiq/job/iterable/enumerators.rb#129 + def csv_batches_enumerator(csv, cursor:, **options); end + + # Builds Enumerator from a CSV file. + # + # @example + # def build_enumerator(import_id, cursor:) + # import = Import.find(import_id) + # csv_enumerator(import.csv, cursor: cursor) + # end + # + # def each_iteration(csv_row) + # # insert csv_row into database + # end + # @param csv [CSV] an instance of CSV object + # @param cursor [Integer] offset to start iteration from + # + # source://sidekiq//lib/sidekiq/job/iterable/enumerators.rb#109 + def csv_enumerator(csv, cursor:); end +end + +# seconds +# +# source://sidekiq//lib/sidekiq/job/iterable.rb#141 +Sidekiq::Job::Iterable::STATE_FLUSH_INTERVAL = T.let(T.unsafe(nil), Integer) + +# we need to keep the state around as long as the job +# might be retrying +# +# source://sidekiq//lib/sidekiq/job/iterable.rb#144 +Sidekiq::Job::Iterable::STATE_TTL = T.let(T.unsafe(nil), Integer) + +# The Options module is extracted so we can include it in ActiveJob::Base +# and allow native AJs to configure Sidekiq features/internals. +# +# source://sidekiq//lib/sidekiq/job.rb#48 +module Sidekiq::Job::Options + mixes_in_class_methods ::Sidekiq::Job::Options::ClassMethods + + class << self + # @private + # + # source://sidekiq//lib/sidekiq/job.rb#49 + def included(base); end + end +end + +# source://sidekiq//lib/sidekiq/job.rb#56 +module Sidekiq::Job::Options::ClassMethods + # source://sidekiq//lib/sidekiq/job.rb#88 + def get_sidekiq_options; end + + # source://sidekiq//lib/sidekiq/job.rb#92 + def sidekiq_class_attribute(*attrs); end + + # Allows customization for this type of Job. + # Legal options: + # + # queue - name of queue to use for this job type, default *default* + # retry - enable retries for this Job in case of error during execution, + # *true* to use the default or *Integer* count + # backtrace - whether to save any error backtrace in the retry payload to display in web UI, + # can be true, false or an integer number of lines to save, default *false* + # + # In practice, any option is allowed. This is the main mechanism to configure the + # options for a specific job. + # + # source://sidekiq//lib/sidekiq/job.rb#71 + def sidekiq_options(opts = T.unsafe(nil)); end + + # source://sidekiq//lib/sidekiq/job.rb#84 + def sidekiq_retries_exhausted(&block); end + + # source://sidekiq//lib/sidekiq/job.rb#80 + def sidekiq_retry_in(&block); end +end + +# source://sidekiq//lib/sidekiq/job.rb#57 +Sidekiq::Job::Options::ClassMethods::ACCESSOR_MUTEX = T.let(T.unsafe(nil), Thread::Mutex) + +# This helper class encapsulates the set options for `set`, e.g. +# +# SomeJob.set(queue: 'foo').perform_async(....) +# +# source://sidekiq//lib/sidekiq/job.rb#184 +class Sidekiq::Job::Setter + include ::Sidekiq::JobUtil + + # @return [Setter] a new instance of Setter + # + # source://sidekiq//lib/sidekiq/job.rb#187 + def initialize(klass, opts); end + + # source://sidekiq//lib/sidekiq/job.rb#205 + def perform_async(*args); end + + # +interval+ must be a timestamp, numeric or something that acts + # numeric (like an activesupport time interval). + # + # source://sidekiq//lib/sidekiq/job.rb#258 + def perform_at(interval, *args); end + + # source://sidekiq//lib/sidekiq/job.rb#251 + def perform_bulk(args, batch_size: T.unsafe(nil)); end + + # +interval+ must be a timestamp, numeric or something that acts + # numeric (like an activesupport time interval). + # + # source://sidekiq//lib/sidekiq/job.rb#258 + def perform_in(interval, *args); end + + # Explicit inline execution of a job. Returns nil if the job did not + # execute, true otherwise. + # + # source://sidekiq//lib/sidekiq/job.rb#215 + def perform_inline(*args); end + + # Explicit inline execution of a job. Returns nil if the job did not + # execute, true otherwise. + # + # source://sidekiq//lib/sidekiq/job.rb#215 + def perform_sync(*args); end + + # source://sidekiq//lib/sidekiq/job.rb#197 + def set(options); end + + private + + # source://sidekiq//lib/sidekiq/job.rb#265 + def at(interval); end +end + +# source://sidekiq//lib/sidekiq/job_util.rb#5 +module Sidekiq::JobUtil + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/job_util.rb#41 + def normalize_item(item); end + + # source://sidekiq//lib/sidekiq/job_util.rb#63 + def normalized_hash(item_class); end + + # @raise [ArgumentError] + # + # source://sidekiq//lib/sidekiq/job_util.rb#10 + def validate(item); end + + # source://sidekiq//lib/sidekiq/job_util.rb#19 + def verify_json(item); end + + private + + # @return [Boolean] + # + # source://sidekiq//lib/sidekiq/job_util.rb#103 + def json_unsafe?(item); end +end + +# source://sidekiq//lib/sidekiq/job_util.rb#74 +Sidekiq::JobUtil::RECURSIVE_JSON_UNSAFE = T.let(T.unsafe(nil), Hash) + +# These functions encapsulate various job utilities. +# +# source://sidekiq//lib/sidekiq/job_util.rb#8 +Sidekiq::JobUtil::TRANSIENT_ATTRIBUTES = T.let(T.unsafe(nil), Array) + +# source://sidekiq//lib/sidekiq.rb#43 +Sidekiq::LICENSE = T.let(T.unsafe(nil), String) + +# source://sidekiq//lib/sidekiq/logger.rb#75 +class Sidekiq::Logger < ::Logger + include ::Sidekiq::LoggingUtils +end + +# source://sidekiq//lib/sidekiq/logger.rb#78 +module Sidekiq::Logger::Formatters; end + +# source://sidekiq//lib/sidekiq/logger.rb#79 +class Sidekiq::Logger::Formatters::Base < ::Logger::Formatter + # source://sidekiq//lib/sidekiq/logger.rb#84 + def ctx; end + + # source://sidekiq//lib/sidekiq/logger.rb#88 + def format_context; end + + # source://sidekiq//lib/sidekiq/logger.rb#80 + def tid; end +end + +# source://sidekiq//lib/sidekiq/logger.rb#114 +class Sidekiq::Logger::Formatters::JSON < ::Sidekiq::Logger::Formatters::Base + # source://sidekiq//lib/sidekiq/logger.rb#115 + def call(severity, time, program_name, message); end +end + +# source://sidekiq//lib/sidekiq/logger.rb#102 +class Sidekiq::Logger::Formatters::Pretty < ::Sidekiq::Logger::Formatters::Base + # source://sidekiq//lib/sidekiq/logger.rb#103 + def call(severity, time, program_name, message); end +end + +# source://sidekiq//lib/sidekiq/logger.rb#108 +class Sidekiq::Logger::Formatters::WithoutTimestamp < ::Sidekiq::Logger::Formatters::Pretty + # source://sidekiq//lib/sidekiq/logger.rb#109 + def call(severity, time, program_name, message); end +end + +# source://sidekiq//lib/sidekiq/logger.rb#25 +module Sidekiq::LoggingUtils + # source://sidekiq//lib/sidekiq/logger.rb#39 + def debug?; end + + # source://sidekiq//lib/sidekiq/logger.rb#39 + def error?; end + + # source://sidekiq//lib/sidekiq/logger.rb#39 + def fatal?; end + + # source://sidekiq//lib/sidekiq/logger.rb#39 + def info?; end + + # source://sidekiq//lib/sidekiq/logger.rb#61 + def level; end + + # source://sidekiq//lib/sidekiq/logger.rb#44 + def local_level; end + + # source://sidekiq//lib/sidekiq/logger.rb#48 + def local_level=(level); end + + # Change the thread-local level for the duration of the given block. + # + # source://sidekiq//lib/sidekiq/logger.rb#66 + def log_at(level); end + + # source://sidekiq//lib/sidekiq/logger.rb#39 + def warn?; end +end + +# source://sidekiq//lib/sidekiq/logger.rb#26 +Sidekiq::LoggingUtils::LEVELS = T.let(T.unsafe(nil), Hash) + +# source://sidekiq//lib/sidekiq/version.rb#5 +Sidekiq::MAJOR = T.let(T.unsafe(nil), Integer) + +# Middleware is code configured to run before/after +# a job is processed. It is patterned after Rack +# middleware. Middleware exists for the client side +# (pushing jobs onto the queue) as well as the server +# side (when jobs are actually processed). +# +# Callers will register middleware Classes and Sidekiq will +# create new instances of the middleware for every job. This +# is important so that instance state is not shared accidentally +# between job executions. +# +# To add middleware for the client: +# +# Sidekiq.configure_client do |config| +# config.client_middleware do |chain| +# chain.add MyClientHook +# end +# end +# +# To modify middleware for the server, just call +# with another block: +# +# Sidekiq.configure_server do |config| +# config.server_middleware do |chain| +# chain.add MyServerHook +# chain.remove ActiveRecord +# end +# end +# +# To insert immediately preceding another entry: +# +# Sidekiq.configure_client do |config| +# config.client_middleware do |chain| +# chain.insert_before ActiveRecord, MyClientHook +# end +# end +# +# To insert immediately after another entry: +# +# Sidekiq.configure_client do |config| +# config.client_middleware do |chain| +# chain.insert_after ActiveRecord, MyClientHook +# end +# end +# +# This is an example of a minimal server middleware: +# +# class MyServerHook +# include Sidekiq::ServerMiddleware +# +# def call(job_instance, msg, queue) +# logger.info "Before job" +# redis {|conn| conn.get("foo") } # do something in Redis +# yield +# logger.info "After job" +# end +# end +# +# This is an example of a minimal client middleware, note +# the method must return the result or the job will not push +# to Redis: +# +# class MyClientHook +# include Sidekiq::ClientMiddleware +# +# def call(job_class, msg, queue, redis_pool) +# logger.info "Before push" +# result = yield +# logger.info "After push" +# result +# end +# end +# +# source://sidekiq//lib/sidekiq/middleware/chain.rb#79 +module Sidekiq::Middleware; end + +# source://sidekiq//lib/sidekiq/middleware/chain.rb#80 +class Sidekiq::Middleware::Chain + include ::Enumerable + + # @api private + # @return [Chain] a new instance of Chain + # @yield [_self] + # @yieldparam _self [Sidekiq::Middleware::Chain] the object that the method was called on + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#89 + def initialize(config = T.unsafe(nil)); end + + # Add the given middleware to the end of the chain. + # Sidekiq will call `klass.new(*args)` to create a clean + # copy of your middleware for every job executed. + # + # chain.add(Statsd::Metrics, { collector: "localhost:8125" }) + # + # @param klass [Class] Your middleware class + # @param *args [Array] Set of arguments to pass to every instance of your middleware + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#119 + def add(klass, *args); end + + # source://sidekiq//lib/sidekiq/middleware/chain.rb#163 + def clear; end + + # source://sidekiq//lib/sidekiq/middleware/chain.rb#99 + def copy_for(capsule); end + + # Iterate through each middleware in the chain + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#84 + def each(&block); end + + # @return [Boolean] if the chain contains no middleware + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#155 + def empty?; end + + # source://sidekiq//lib/sidekiq/middleware/chain.rb#95 + def entries; end + + # @return [Boolean] if the given class is already in the chain + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#149 + def exists?(klass); end + + # @return [Boolean] if the given class is already in the chain + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#149 + def include?(klass); end + + # Inserts +newklass+ after +oldklass+ in the chain. + # Useful if one middleware must run after another middleware. + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#141 + def insert_after(oldklass, newklass, *args); end + + # Inserts +newklass+ before +oldklass+ in the chain. + # Useful if one middleware must run before another middleware. + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#132 + def insert_before(oldklass, newklass, *args); end + + # Used by Sidekiq to execute the middleware at runtime + # + # @api private + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#169 + def invoke(*args, &block); end + + # Identical to {#add} except the middleware is added to the front of the chain. + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#125 + def prepend(klass, *args); end + + # Remove all middleware matching the given Class + # + # @param klass [Class] + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#107 + def remove(klass); end + + # source://sidekiq//lib/sidekiq/middleware/chain.rb#159 + def retrieve; end + + private + + # source://sidekiq//lib/sidekiq/middleware/chain.rb#178 + def traverse(chain, index, args, &block); end +end + +# Represents each link in the middleware chain +# +# @api private +# +# source://sidekiq//lib/sidekiq/middleware/chain.rb#191 +class Sidekiq::Middleware::Entry + # @api private + # @return [Entry] a new instance of Entry + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#194 + def initialize(config, klass, *args); end + + # @api private + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#192 + def klass; end + + # @api private + # + # source://sidekiq//lib/sidekiq/middleware/chain.rb#200 + def make_new; end +end + +# source://sidekiq//lib/sidekiq.rb#42 +Sidekiq::NAME = T.let(T.unsafe(nil), String) + +# source://sidekiq//lib/sidekiq/rails.rb#7 +class Sidekiq::Rails < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end + +# source://sidekiq//lib/sidekiq/rails.rb#8 +class Sidekiq::Rails::Reloader + # @return [Reloader] a new instance of Reloader + # + # source://sidekiq//lib/sidekiq/rails.rb#9 + def initialize(app = T.unsafe(nil)); end + + # source://sidekiq//lib/sidekiq/rails.rb#13 + def call; end + + # source://sidekiq//lib/sidekiq/rails.rb#20 + def inspect; end + + # source://sidekiq//lib/sidekiq/rails.rb#24 + def to_hash; end +end + +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#8 +class Sidekiq::RedisClientAdapter + # @return [RedisClientAdapter] a new instance of RedisClientAdapter + # + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#63 + def initialize(options); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#79 + def new_client; end + + private + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#85 + def client_opts(options); end +end + +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#9 +Sidekiq::RedisClientAdapter::BaseError = RedisClient::Error + +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#10 +Sidekiq::RedisClientAdapter::CommandError = RedisClient::CommandError + +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#0 +class Sidekiq::RedisClientAdapter::CompatClient < ::RedisClient::Decorator::Client + include ::Sidekiq::RedisClientAdapter::CompatMethods + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#58 + def config; end +end + +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#0 +class Sidekiq::RedisClientAdapter::CompatClient::Pipeline < ::RedisClient::Decorator::Pipeline + include ::Sidekiq::RedisClientAdapter::CompatMethods +end + +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#15 +module Sidekiq::RedisClientAdapter::CompatMethods + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def bitfield(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def bitfield_ro(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def del(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#20 + def evalsha(sha, keys, argv); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def exists(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def expire(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def flushdb(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def get(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hdel(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hget(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hgetall(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hincrby(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hlen(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hmget(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hset(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def hsetnx(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def incr(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def incrby(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#16 + def info; end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def lindex(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def llen(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def lmove(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def lpop(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def lpush(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def lrange(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def lrem(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def mget(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def mset(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def ping(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def pttl(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def publish(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def rpop(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def rpush(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def sadd(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def scard(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def script(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def set(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def sismember(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def smembers(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def srem(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def ttl(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def type(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def unlink(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def zadd(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def zcard(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def zincrby(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def zrange(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def zrem(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def zremrangebyrank(*args, **kwargs); end + + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#35 + def zremrangebyscore(*args, **kwargs); end + + private + + # this allows us to use methods like `conn.hmset(...)` instead of having to use + # redis-client's native `conn.call("hmset", ...)` + # + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#44 + def method_missing(*args, **_arg1, &block); end + + # @return [Boolean] + # + # source://sidekiq//lib/sidekiq/redis_client_adapter.rb#50 + def respond_to_missing?(name, include_private = T.unsafe(nil)); end +end + +# this is the set of Redis commands used by Sidekiq. Not guaranteed +# to be comprehensive, we use this as a performance enhancement to +# avoid calling method_missing on most commands +# +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#27 +Sidekiq::RedisClientAdapter::CompatMethods::USED_COMMANDS = T.let(T.unsafe(nil), Array) + +# You can add/remove items or clear the whole thing if you don't want deprecation warnings. +# +# source://sidekiq//lib/sidekiq/redis_client_adapter.rb#13 +Sidekiq::RedisClientAdapter::DEPRECATED_COMMANDS = T.let(T.unsafe(nil), Set) + +# source://sidekiq//lib/sidekiq/redis_connection.rb#8 +module Sidekiq::RedisConnection + class << self + # source://sidekiq//lib/sidekiq/redis_connection.rb#10 + def create(options = T.unsafe(nil)); end + + private + + # source://sidekiq//lib/sidekiq/redis_connection.rb#41 + def deep_symbolize_keys(object); end + + # source://sidekiq//lib/sidekiq/redis_connection.rb#74 + def determine_redis_provider; end + + # source://sidekiq//lib/sidekiq/redis_connection.rb#54 + def scrub(options); end + end +end + +# source://sidekiq//lib/sidekiq/scheduled.rb#7 +module Sidekiq::Scheduled; end + +# source://sidekiq//lib/sidekiq/scheduled.rb#10 +class Sidekiq::Scheduled::Enq + include ::Sidekiq::Component + + # @return [Enq] a new instance of Enq + # + # source://sidekiq//lib/sidekiq/scheduled.rb#22 + def initialize(container); end + + # source://sidekiq//lib/sidekiq/scheduled.rb#29 + def enqueue_jobs(sorted_sets = T.unsafe(nil)); end + + # source://sidekiq//lib/sidekiq/scheduled.rb#46 + def terminate; end + + private + + # source://sidekiq//lib/sidekiq/scheduled.rb#52 + def zpopbyscore(conn, keys: T.unsafe(nil), argv: T.unsafe(nil)); end +end + +# source://sidekiq//lib/sidekiq/scheduled.rb#13 +Sidekiq::Scheduled::Enq::LUA_ZPOPBYSCORE = T.let(T.unsafe(nil), String) + +# The Poller checks Redis every N seconds for jobs in the retry or scheduled +# set have passed their timestamp and should be enqueued. If so, it +# just pops the job back onto its original queue so the +# workers can pick it up like any other job. +# +# source://sidekiq//lib/sidekiq/scheduled.rb#71 +class Sidekiq::Scheduled::Poller + include ::Sidekiq::Component + + # @return [Poller] a new instance of Poller + # + # source://sidekiq//lib/sidekiq/scheduled.rb#76 + def initialize(config); end + + # source://sidekiq//lib/sidekiq/scheduled.rb#106 + def enqueue; end + + # source://sidekiq//lib/sidekiq/scheduled.rb#94 + def start; end + + # Shut down this instance, will pause until the thread is dead. + # + # source://sidekiq//lib/sidekiq/scheduled.rb#86 + def terminate; end + + private + + # A copy of Sidekiq::ProcessSet#cleanup because server + # should never depend on sidekiq/api. + # + # source://sidekiq//lib/sidekiq/scheduled.rb#194 + def cleanup; end + + # source://sidekiq//lib/sidekiq/scheduled.rb#218 + def initial_wait; end + + # We do our best to tune the poll interval to the size of the active Sidekiq + # cluster. If you have 30 processes and poll every 15 seconds, that means one + # Sidekiq is checking Redis every 0.5 seconds - way too often for most people + # and really bad if the retry or scheduled sets are large. + # + # Instead try to avoid polling more than once every 15 seconds. If you have + # 30 Sidekiq processes, we'll poll every 30 * 15 or 450 seconds. + # To keep things statistically random, we'll sleep a random amount between + # 225 and 675 seconds for each poll or 450 seconds on average. Otherwise restarting + # all your Sidekiq processes at the same time will lead to them all polling at + # the same time: the thundering herd problem. + # + # We only do this if poll_interval_average is unset (the default). + # + # source://sidekiq//lib/sidekiq/scheduled.rb#175 + def poll_interval_average(count); end + + # source://sidekiq//lib/sidekiq/scheduled.rb#186 + def process_count; end + + # source://sidekiq//lib/sidekiq/scheduled.rb#129 + def random_poll_interval; end + + # Calculates an average poll interval based on the number of known Sidekiq processes. + # This minimizes a single point of failure by dispersing check-ins but without taxing + # Redis if you run many Sidekiq processes. + # + # source://sidekiq//lib/sidekiq/scheduled.rb#182 + def scaled_poll_interval(process_count); end + + # source://sidekiq//lib/sidekiq/scheduled.rb#117 + def wait; end +end + +# source://sidekiq//lib/sidekiq/scheduled.rb#74 +Sidekiq::Scheduled::Poller::INITIAL_WAIT = T.let(T.unsafe(nil), Integer) + +# source://sidekiq//lib/sidekiq/scheduled.rb#8 +Sidekiq::Scheduled::SETS = T.let(T.unsafe(nil), Array) + +# Server-side middleware must import this Module in order +# to get access to server resources during `call`. +# +# source://sidekiq//lib/sidekiq/middleware/modules.rb#4 +module Sidekiq::ServerMiddleware + # Returns the value of attribute config. + # + # source://sidekiq//lib/sidekiq/middleware/modules.rb#5 + def config; end + + # Sets the attribute config + # + # @param value the value to set the attribute config to. + # + # source://sidekiq//lib/sidekiq/middleware/modules.rb#5 + def config=(_arg0); end + + # source://sidekiq//lib/sidekiq/middleware/modules.rb#10 + def logger; end + + # source://sidekiq//lib/sidekiq/middleware/modules.rb#14 + def redis(&block); end + + # source://sidekiq//lib/sidekiq/middleware/modules.rb#6 + def redis_pool; end +end + +# We are shutting down Sidekiq but what about threads that +# are working on some long job? This error is +# raised in jobs that have not finished within the hard +# timeout limit. This is needed to rollback db transactions, +# otherwise Ruby's Thread#kill will commit. See #377. +# DO NOT RESCUE THIS ERROR IN YOUR JOBS +# +# source://sidekiq//lib/sidekiq.rb#145 +class Sidekiq::Shutdown < ::Interrupt; end + +# source://sidekiq//lib/sidekiq/transaction_aware_client.rb#7 +class Sidekiq::TransactionAwareClient + # @return [TransactionAwareClient] a new instance of TransactionAwareClient + # + # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#8 + def initialize(pool: T.unsafe(nil), config: T.unsafe(nil)); end + + # @return [Boolean] + # + # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#12 + def batching?; end + + # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#16 + def push(item); end + + # We don't provide transactionality for push_bulk because we don't want + # to hold potentially hundreds of thousands of job records in memory due to + # a long running enqueue process. + # + # source://sidekiq//lib/sidekiq/transaction_aware_client.rb#31 + def push_bulk(items); end +end + +# source://sidekiq//lib/sidekiq/version.rb#4 +Sidekiq::VERSION = T.let(T.unsafe(nil), String) + +# Sidekiq::Job is a new alias for Sidekiq::Worker as of Sidekiq 6.3.0. +# Use `include Sidekiq::Job` rather than `include Sidekiq::Worker`. +# +# The term "worker" is too generic and overly confusing, used in several +# different contexts meaning different things. Many people call a Sidekiq +# process a "worker". Some people call the thread that executes jobs a +# "worker". This change brings Sidekiq closer to ActiveJob where your job +# classes extend ApplicationJob. +# +# source://sidekiq//lib/sidekiq/worker_compatibility_alias.rb#12 +Sidekiq::Worker = Sidekiq::Job diff --git a/sorbet/rbi/gems/simple_form@5.2.0.rbi b/sorbet/rbi/gems/simple_form@5.3.1.rbi similarity index 90% rename from sorbet/rbi/gems/simple_form@5.2.0.rbi rename to sorbet/rbi/gems/simple_form@5.3.1.rbi index c4d127e60..5a3ec249e 100644 --- a/sorbet/rbi/gems/simple_form@5.2.0.rbi +++ b/sorbet/rbi/gems/simple_form@5.3.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `simple_form` gem. # Please instead update this file by running `bin/tapioca gem simple_form`. + # source://simple_form//lib/simple_form/action_view_extensions/builder.rb#34 module ActionView::Helpers include ::ActionView::Helpers::SanitizeHelper @@ -19,7 +20,7 @@ module ActionView::Helpers mixes_in_class_methods ::ActionView::Helpers::SanitizeHelper::ClassMethods class << self - # source://actionview/7.0.5/lib/action_view/helpers.rb#34 + # source://actionview/7.2.0/lib/action_view/helpers.rb#35 def eager_load!; end end end @@ -28,210 +29,210 @@ end class ActionView::Helpers::FormBuilder include ::SimpleForm::ActionViewExtensions::Builder - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1700 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1717 def initialize(object_name, object, template, options); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2614 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2649 def button(value = T.unsafe(nil), options = T.unsafe(nil), &block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2438 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2474 def check_box(method, options = T.unsafe(nil), checked_value = T.unsafe(nil), unchecked_value = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#907 + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#908 def collection_check_boxes(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#919 + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#920 def collection_radio_buttons(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#859 + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#860 def collection_select(method, collection, value_method, text_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2042 def color_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2070 def date_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/date_helper.rb#1239 + # source://actionview/7.2.0/lib/action_view/helpers/date_helper.rb#1237 def date_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2084 def datetime_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2091 def datetime_local_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/date_helper.rb#1263 + # source://actionview/7.2.0/lib/action_view/helpers/date_helper.rb#1261 def datetime_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2119 def email_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2635 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2670 def emitted_hidden_id?; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 def field_helpers; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 def field_helpers=(_arg0); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 def field_helpers?; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1757 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1774 def field_id(method, *suffixes, namespace: T.unsafe(nil), index: T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1777 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1794 def field_name(method, *methods, multiple: T.unsafe(nil), index: T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2294 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2328 def fields(scope = T.unsafe(nil), model: T.unsafe(nil), **options, &block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2257 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2290 def fields_for(record_name, record_object = T.unsafe(nil), fields_options = T.unsafe(nil), &block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2521 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2557 def file_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#871 + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#872 def grouped_collection_select(method, collection, group_method, group_label_method, option_key_method, option_value_method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2482 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2518 def hidden_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1737 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1754 def id; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1677 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1694 def index; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2369 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2405 def label(method, text = T.unsafe(nil), options = T.unsafe(nil), &block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2098 def month_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1677 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1694 def multipart; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1680 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1697 def multipart=(multipart); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1677 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1694 def multipart?; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2126 def number_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 def object; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 def object=(_arg0); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 def object_name; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 def object_name=(_arg0); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 def options; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1675 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1692 def options=(_arg0); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2028 def password_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2063 def phone_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2460 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2496 def radio_button(method, tag_value, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2133 def range_field(method, options = T.unsafe(nil)); end def rich_text_area(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2049 def search_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#847 + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#848 def select(method, choices = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil), &block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2553 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2589 def submit(value = T.unsafe(nil), options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2056 def telephone_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2035 def text_area(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2021 def text_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2077 def time_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/date_helper.rb#1251 + # source://actionview/7.2.0/lib/action_view/helpers/date_helper.rb#1249 def time_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#883 + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#884 def time_zone_select(method, priority_zones = T.unsafe(nil), options = T.unsafe(nil), html_options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1696 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1713 def to_model; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1692 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1709 def to_partial_path; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2112 def url_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2006 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2105 def week_field(method, options = T.unsafe(nil)); end - # source://actionview/7.0.5/lib/action_view/helpers/form_options_helper.rb#895 + # source://actionview/7.2.0/lib/action_view/helpers/form_options_helper.rb#896 def weekday_select(method, options = T.unsafe(nil), html_options = T.unsafe(nil)); end private - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2720 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2755 def convert_to_legacy_options(options); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2702 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2737 def fields_for_nested_model(name, object, fields_options, block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2673 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2708 def fields_for_with_nested_attributes(association_name, association, options, block); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2669 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2704 def nested_attributes_association?(association_name); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2715 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2750 def nested_child_index(name); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2640 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2675 def objectify_options(options); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2646 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2681 def submit_default_value; end class << self - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1688 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1705 def _to_partial_path; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 def field_helpers; end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 def field_helpers=(value); end - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#1665 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#1682 def field_helpers?; end end end @@ -250,273 +251,273 @@ end module SimpleForm extend ::ActiveSupport::Autoload - # source://simple_form//lib/simple_form.rb#198 + # source://simple_form//lib/simple_form.rb#202 def boolean_label_class; end - # source://simple_form//lib/simple_form.rb#198 + # source://simple_form//lib/simple_form.rb#202 def boolean_label_class=(val); end - # source://simple_form//lib/simple_form.rb#109 + # source://simple_form//lib/simple_form.rb#113 def boolean_style; end - # source://simple_form//lib/simple_form.rb#109 + # source://simple_form//lib/simple_form.rb#113 def boolean_style=(val); end - # source://simple_form//lib/simple_form.rb#131 + # source://simple_form//lib/simple_form.rb#135 def browser_validations; end - # source://simple_form//lib/simple_form.rb#131 + # source://simple_form//lib/simple_form.rb#135 def browser_validations=(val); end - # source://simple_form//lib/simple_form.rb#178 + # source://simple_form//lib/simple_form.rb#182 def button_class; end - # source://simple_form//lib/simple_form.rb#178 + # source://simple_form//lib/simple_form.rb#182 def button_class=(val); end - # source://simple_form//lib/simple_form.rb#174 + # source://simple_form//lib/simple_form.rb#178 def cache_discovery; end - # source://simple_form//lib/simple_form.rb#174 + # source://simple_form//lib/simple_form.rb#178 def cache_discovery=(val); end - # source://simple_form//lib/simple_form.rb#73 + # source://simple_form//lib/simple_form.rb#77 def collection_label_methods; end - # source://simple_form//lib/simple_form.rb#73 + # source://simple_form//lib/simple_form.rb#77 def collection_label_methods=(val); end - # source://simple_form//lib/simple_form.rb#77 + # source://simple_form//lib/simple_form.rb#81 def collection_value_methods; end - # source://simple_form//lib/simple_form.rb#77 + # source://simple_form//lib/simple_form.rb#81 def collection_value_methods=(val); end - # source://simple_form//lib/simple_form.rb#85 + # source://simple_form//lib/simple_form.rb#89 def collection_wrapper_class; end - # source://simple_form//lib/simple_form.rb#85 + # source://simple_form//lib/simple_form.rb#89 def collection_wrapper_class=(val); end - # source://simple_form//lib/simple_form.rb#81 + # source://simple_form//lib/simple_form.rb#85 def collection_wrapper_tag; end - # source://simple_form//lib/simple_form.rb#81 + # source://simple_form//lib/simple_form.rb#85 def collection_wrapper_tag=(val); end - # source://simple_form//lib/simple_form.rb#161 + # source://simple_form//lib/simple_form.rb#165 def country_priority; end - # source://simple_form//lib/simple_form.rb#161 + # source://simple_form//lib/simple_form.rb#165 def country_priority=(val); end - # source://simple_form//lib/simple_form.rb#153 + # source://simple_form//lib/simple_form.rb#157 def custom_inputs_namespaces; end - # source://simple_form//lib/simple_form.rb#153 + # source://simple_form//lib/simple_form.rb#157 def custom_inputs_namespaces=(val); end - # source://simple_form//lib/simple_form.rb#119 + # source://simple_form//lib/simple_form.rb#123 def default_form_class; end - # source://simple_form//lib/simple_form.rb#119 + # source://simple_form//lib/simple_form.rb#123 def default_form_class=(val); end # WRAPPER CONFIGURATION # The default wrapper to be used by the FormBuilder. # - # source://simple_form//lib/simple_form.rb#203 + # source://simple_form//lib/simple_form.rb#207 def default_wrapper; end - # source://simple_form//lib/simple_form.rb#203 + # source://simple_form//lib/simple_form.rb#207 def default_wrapper=(val); end - # source://simple_form//lib/simple_form.rb#61 + # source://simple_form//lib/simple_form.rb#65 def error_method; end - # source://simple_form//lib/simple_form.rb#61 + # source://simple_form//lib/simple_form.rb#65 def error_method=(val); end - # source://simple_form//lib/simple_form.rb#69 + # source://simple_form//lib/simple_form.rb#73 def error_notification_class; end - # source://simple_form//lib/simple_form.rb#69 + # source://simple_form//lib/simple_form.rb#73 def error_notification_class=(val); end - # source://simple_form//lib/simple_form.rb#65 + # source://simple_form//lib/simple_form.rb#69 def error_notification_tag; end - # source://simple_form//lib/simple_form.rb#65 + # source://simple_form//lib/simple_form.rb#69 def error_notification_tag=(val); end - # source://simple_form//lib/simple_form.rb#184 + # source://simple_form//lib/simple_form.rb#188 def field_error_proc; end - # source://simple_form//lib/simple_form.rb#184 + # source://simple_form//lib/simple_form.rb#188 def field_error_proc=(val); end - # source://simple_form//lib/simple_form.rb#114 + # source://simple_form//lib/simple_form.rb#118 def form_class; end - # source://simple_form//lib/simple_form.rb#123 + # source://simple_form//lib/simple_form.rb#127 def generate_additional_classes_for; end - # source://simple_form//lib/simple_form.rb#123 + # source://simple_form//lib/simple_form.rb#127 def generate_additional_classes_for=(val); end - # source://simple_form//lib/simple_form.rb#207 + # source://simple_form//lib/simple_form.rb#211 def i18n_scope; end - # source://simple_form//lib/simple_form.rb#207 + # source://simple_form//lib/simple_form.rb#211 def i18n_scope=(val); end - # source://simple_form//lib/simple_form.rb#194 + # source://simple_form//lib/simple_form.rb#198 def include_default_input_wrapper_class; end - # source://simple_form//lib/simple_form.rb#194 + # source://simple_form//lib/simple_form.rb#198 def include_default_input_wrapper_class=(val); end - # source://simple_form//lib/simple_form.rb#190 + # source://simple_form//lib/simple_form.rb#194 def input_class; end - # source://simple_form//lib/simple_form.rb#190 + # source://simple_form//lib/simple_form.rb#194 def input_class=(val); end - # source://simple_form//lib/simple_form.rb#210 + # source://simple_form//lib/simple_form.rb#214 def input_field_error_class; end - # source://simple_form//lib/simple_form.rb#210 + # source://simple_form//lib/simple_form.rb#214 def input_field_error_class=(val); end - # source://simple_form//lib/simple_form.rb#213 + # source://simple_form//lib/simple_form.rb#217 def input_field_valid_class; end - # source://simple_form//lib/simple_form.rb#213 + # source://simple_form//lib/simple_form.rb#217 def input_field_valid_class=(val); end - # source://simple_form//lib/simple_form.rb#137 + # source://simple_form//lib/simple_form.rb#141 def input_mappings; end - # source://simple_form//lib/simple_form.rb#137 + # source://simple_form//lib/simple_form.rb#141 def input_mappings=(val); end - # source://simple_form//lib/simple_form.rb#170 + # source://simple_form//lib/simple_form.rb#174 def inputs_discovery; end - # source://simple_form//lib/simple_form.rb#170 + # source://simple_form//lib/simple_form.rb#174 def inputs_discovery=(val); end - # source://simple_form//lib/simple_form.rb#95 + # source://simple_form//lib/simple_form.rb#99 def item_wrapper_class; end - # source://simple_form//lib/simple_form.rb#95 + # source://simple_form//lib/simple_form.rb#99 def item_wrapper_class=(val); end - # source://simple_form//lib/simple_form.rb#91 + # source://simple_form//lib/simple_form.rb#95 def item_wrapper_tag; end - # source://simple_form//lib/simple_form.rb#91 + # source://simple_form//lib/simple_form.rb#95 def item_wrapper_tag=(val); end - # source://simple_form//lib/simple_form.rb#103 + # source://simple_form//lib/simple_form.rb#107 def label_class; end - # source://simple_form//lib/simple_form.rb#103 + # source://simple_form//lib/simple_form.rb#107 def label_class=(val); end - # source://simple_form//lib/simple_form.rb#99 + # source://simple_form//lib/simple_form.rb#103 def label_text; end - # source://simple_form//lib/simple_form.rb#99 + # source://simple_form//lib/simple_form.rb#103 def label_text=(val); end - # source://simple_form//lib/simple_form.rb#127 + # source://simple_form//lib/simple_form.rb#131 def required_by_default; end - # source://simple_form//lib/simple_form.rb#127 + # source://simple_form//lib/simple_form.rb#131 def required_by_default=(val); end - # source://simple_form//lib/simple_form.rb#157 + # source://simple_form//lib/simple_form.rb#161 def time_zone_priority; end - # source://simple_form//lib/simple_form.rb#157 + # source://simple_form//lib/simple_form.rb#161 def time_zone_priority=(val); end - # source://simple_form//lib/simple_form.rb#166 + # source://simple_form//lib/simple_form.rb#170 def translate_labels; end - # source://simple_form//lib/simple_form.rb#166 + # source://simple_form//lib/simple_form.rb#170 def translate_labels=(val); end - # source://simple_form//lib/simple_form.rb#145 + # source://simple_form//lib/simple_form.rb#149 def wrapper_mappings; end - # source://simple_form//lib/simple_form.rb#145 + # source://simple_form//lib/simple_form.rb#149 def wrapper_mappings=(val); end class << self - # source://simple_form//lib/simple_form.rb#260 + # source://simple_form//lib/simple_form.rb#264 def additional_classes_for(component); end - # source://simple_form//lib/simple_form.rb#198 + # source://simple_form//lib/simple_form.rb#202 def boolean_label_class; end - # source://simple_form//lib/simple_form.rb#198 + # source://simple_form//lib/simple_form.rb#202 def boolean_label_class=(val); end - # source://simple_form//lib/simple_form.rb#109 + # source://simple_form//lib/simple_form.rb#113 def boolean_style; end - # source://simple_form//lib/simple_form.rb#109 + # source://simple_form//lib/simple_form.rb#113 def boolean_style=(val); end - # source://simple_form//lib/simple_form.rb#131 + # source://simple_form//lib/simple_form.rb#135 def browser_validations; end - # source://simple_form//lib/simple_form.rb#131 + # source://simple_form//lib/simple_form.rb#135 def browser_validations=(val); end # Builds a new wrapper using SimpleForm::Wrappers::Builder. # # @yield [builder] # - # source://simple_form//lib/simple_form.rb#238 + # source://simple_form//lib/simple_form.rb#242 def build(options = T.unsafe(nil)); end - # source://simple_form//lib/simple_form.rb#178 + # source://simple_form//lib/simple_form.rb#182 def button_class; end - # source://simple_form//lib/simple_form.rb#178 + # source://simple_form//lib/simple_form.rb#182 def button_class=(val); end - # source://simple_form//lib/simple_form.rb#174 + # source://simple_form//lib/simple_form.rb#178 def cache_discovery; end - # source://simple_form//lib/simple_form.rb#174 + # source://simple_form//lib/simple_form.rb#178 def cache_discovery=(val); end - # source://simple_form//lib/simple_form.rb#73 + # source://simple_form//lib/simple_form.rb#77 def collection_label_methods; end - # source://simple_form//lib/simple_form.rb#73 + # source://simple_form//lib/simple_form.rb#77 def collection_label_methods=(val); end - # source://simple_form//lib/simple_form.rb#77 + # source://simple_form//lib/simple_form.rb#81 def collection_value_methods; end - # source://simple_form//lib/simple_form.rb#77 + # source://simple_form//lib/simple_form.rb#81 def collection_value_methods=(val); end - # source://simple_form//lib/simple_form.rb#85 + # source://simple_form//lib/simple_form.rb#89 def collection_wrapper_class; end - # source://simple_form//lib/simple_form.rb#85 + # source://simple_form//lib/simple_form.rb#89 def collection_wrapper_class=(val); end - # source://simple_form//lib/simple_form.rb#81 + # source://simple_form//lib/simple_form.rb#85 def collection_wrapper_tag; end - # source://simple_form//lib/simple_form.rb#81 + # source://simple_form//lib/simple_form.rb#85 def collection_wrapper_tag=(val); end # @return [Boolean] @@ -524,84 +525,87 @@ module SimpleForm # source://simple_form//lib/simple_form.rb#54 def configured?; end - # source://simple_form//lib/simple_form.rb#161 + # source://simple_form//lib/simple_form.rb#165 def country_priority; end - # source://simple_form//lib/simple_form.rb#161 + # source://simple_form//lib/simple_form.rb#165 def country_priority=(val); end - # source://simple_form//lib/simple_form.rb#153 + # source://simple_form//lib/simple_form.rb#157 def custom_inputs_namespaces; end - # source://simple_form//lib/simple_form.rb#153 + # source://simple_form//lib/simple_form.rb#157 def custom_inputs_namespaces=(val); end - # source://simple_form//lib/simple_form.rb#119 + # source://simple_form//lib/simple_form.rb#123 def default_form_class; end - # source://simple_form//lib/simple_form.rb#119 + # source://simple_form//lib/simple_form.rb#123 def default_form_class=(val); end # SETUP # - # source://simple_form//lib/simple_form.rb#266 + # source://simple_form//lib/simple_form.rb#270 def default_input_size=(*_arg0); end - # source://simple_form//lib/simple_form.rb#203 + # source://simple_form//lib/simple_form.rb#207 def default_wrapper; end - # source://simple_form//lib/simple_form.rb#203 + # source://simple_form//lib/simple_form.rb#207 def default_wrapper=(val); end + # source://simple_form//lib/simple_form.rb#58 + def deprecator; end + # source://simple_form//lib/simple_form.rb#23 def eager_load!; end - # source://simple_form//lib/simple_form.rb#61 + # source://simple_form//lib/simple_form.rb#65 def error_method; end - # source://simple_form//lib/simple_form.rb#61 + # source://simple_form//lib/simple_form.rb#65 def error_method=(val); end - # source://simple_form//lib/simple_form.rb#69 + # source://simple_form//lib/simple_form.rb#73 def error_notification_class; end - # source://simple_form//lib/simple_form.rb#69 + # source://simple_form//lib/simple_form.rb#73 def error_notification_class=(val); end - # source://simple_form//lib/simple_form.rb#65 + # source://simple_form//lib/simple_form.rb#69 def error_notification_tag; end - # source://simple_form//lib/simple_form.rb#65 + # source://simple_form//lib/simple_form.rb#69 def error_notification_tag=(val); end - # source://simple_form//lib/simple_form.rb#184 + # source://simple_form//lib/simple_form.rb#188 def field_error_proc; end - # source://simple_form//lib/simple_form.rb#184 + # source://simple_form//lib/simple_form.rb#188 def field_error_proc=(val); end - # source://simple_form//lib/simple_form.rb#280 + # source://simple_form//lib/simple_form.rb#284 def file_methods; end - # source://simple_form//lib/simple_form.rb#275 + # source://simple_form//lib/simple_form.rb#279 def file_methods=(file_methods); end - # source://simple_form//lib/simple_form.rb#114 + # source://simple_form//lib/simple_form.rb#118 def form_class; end - # source://simple_form//lib/simple_form.rb#270 + # source://simple_form//lib/simple_form.rb#274 def form_class=(value); end - # source://simple_form//lib/simple_form.rb#123 + # source://simple_form//lib/simple_form.rb#127 def generate_additional_classes_for; end - # source://simple_form//lib/simple_form.rb#123 + # source://simple_form//lib/simple_form.rb#127 def generate_additional_classes_for=(val); end - # source://simple_form//lib/simple_form.rb#207 + # source://simple_form//lib/simple_form.rb#211 def i18n_scope; end - # source://simple_form//lib/simple_form.rb#207 + # source://simple_form//lib/simple_form.rb#211 def i18n_scope=(val); end # Includes a component to be used by Simple Form. Methods defined in a @@ -639,73 +643,73 @@ module SimpleForm # <%= f.input :title, prepend: true %> # <% end %> # - # source://simple_form//lib/simple_form.rb#327 + # source://simple_form//lib/simple_form.rb#331 def include_component(component); end - # source://simple_form//lib/simple_form.rb#194 + # source://simple_form//lib/simple_form.rb#198 def include_default_input_wrapper_class; end - # source://simple_form//lib/simple_form.rb#194 + # source://simple_form//lib/simple_form.rb#198 def include_default_input_wrapper_class=(val); end - # source://simple_form//lib/simple_form.rb#190 + # source://simple_form//lib/simple_form.rb#194 def input_class; end - # source://simple_form//lib/simple_form.rb#190 + # source://simple_form//lib/simple_form.rb#194 def input_class=(val); end - # source://simple_form//lib/simple_form.rb#210 + # source://simple_form//lib/simple_form.rb#214 def input_field_error_class; end - # source://simple_form//lib/simple_form.rb#210 + # source://simple_form//lib/simple_form.rb#214 def input_field_error_class=(val); end - # source://simple_form//lib/simple_form.rb#213 + # source://simple_form//lib/simple_form.rb#217 def input_field_valid_class; end - # source://simple_form//lib/simple_form.rb#213 + # source://simple_form//lib/simple_form.rb#217 def input_field_valid_class=(val); end - # source://simple_form//lib/simple_form.rb#137 + # source://simple_form//lib/simple_form.rb#141 def input_mappings; end - # source://simple_form//lib/simple_form.rb#137 + # source://simple_form//lib/simple_form.rb#141 def input_mappings=(val); end - # source://simple_form//lib/simple_form.rb#170 + # source://simple_form//lib/simple_form.rb#174 def inputs_discovery; end - # source://simple_form//lib/simple_form.rb#170 + # source://simple_form//lib/simple_form.rb#174 def inputs_discovery=(val); end - # source://simple_form//lib/simple_form.rb#95 + # source://simple_form//lib/simple_form.rb#99 def item_wrapper_class; end - # source://simple_form//lib/simple_form.rb#95 + # source://simple_form//lib/simple_form.rb#99 def item_wrapper_class=(val); end - # source://simple_form//lib/simple_form.rb#91 + # source://simple_form//lib/simple_form.rb#95 def item_wrapper_tag; end - # source://simple_form//lib/simple_form.rb#91 + # source://simple_form//lib/simple_form.rb#95 def item_wrapper_tag=(val); end - # source://simple_form//lib/simple_form.rb#103 + # source://simple_form//lib/simple_form.rb#107 def label_class; end - # source://simple_form//lib/simple_form.rb#103 + # source://simple_form//lib/simple_form.rb#107 def label_class=(val); end - # source://simple_form//lib/simple_form.rb#99 + # source://simple_form//lib/simple_form.rb#103 def label_text; end - # source://simple_form//lib/simple_form.rb#99 + # source://simple_form//lib/simple_form.rb#103 def label_text=(val); end - # source://simple_form//lib/simple_form.rb#127 + # source://simple_form//lib/simple_form.rb#131 def required_by_default; end - # source://simple_form//lib/simple_form.rb#127 + # source://simple_form//lib/simple_form.rb#131 def required_by_default=(val); end # Default way to setup Simple Form. Run rails generate simple_form:install @@ -714,36 +718,36 @@ module SimpleForm # @yield [_self] # @yieldparam _self [SimpleForm] the object that the method was called on # - # source://simple_form//lib/simple_form.rb#287 + # source://simple_form//lib/simple_form.rb#291 def setup; end - # source://simple_form//lib/simple_form.rb#157 + # source://simple_form//lib/simple_form.rb#161 def time_zone_priority; end - # source://simple_form//lib/simple_form.rb#157 + # source://simple_form//lib/simple_form.rb#161 def time_zone_priority=(val); end - # source://simple_form//lib/simple_form.rb#166 + # source://simple_form//lib/simple_form.rb#170 def translate_labels; end - # source://simple_form//lib/simple_form.rb#166 + # source://simple_form//lib/simple_form.rb#170 def translate_labels=(val); end # Retrieves a given wrapper # - # source://simple_form//lib/simple_form.rb#217 + # source://simple_form//lib/simple_form.rb#221 def wrapper(name); end - # source://simple_form//lib/simple_form.rb#145 + # source://simple_form//lib/simple_form.rb#149 def wrapper_mappings; end - # source://simple_form//lib/simple_form.rb#145 + # source://simple_form//lib/simple_form.rb#149 def wrapper_mappings=(val); end # Define a new wrapper using SimpleForm::Wrappers::Builder # and store it in the given name. # - # source://simple_form//lib/simple_form.rb#227 + # source://simple_form//lib/simple_form.rb#231 def wrappers(*args, &block); end end end @@ -1265,7 +1269,7 @@ class SimpleForm::FormBuilder < ::ActionView::Helpers::FormBuilder # button implementation (3.2 forward (to delegate to the original when # calling `f.button :button`. # - # source://actionview/7.0.5/lib/action_view/helpers/form_helper.rb#2614 + # source://actionview/7.2.0/lib/action_view/helpers/form_helper.rb#2649 def button_button(value = T.unsafe(nil), options = T.unsafe(nil), &block); end # Creates a collection of check boxes for each item in the collection, @@ -1827,6 +1831,8 @@ end class SimpleForm::Inputs::Base include ::ERB::Escape include ::ERB::Util + include ::ActiveSupport::CoreExt::ERBUtil + include ::ActiveSupport::CoreExt::ERBUtilPrivate include ::ActionView::Helpers::CaptureHelper include ::ActionView::Helpers::OutputSafetyHelper include ::ActionView::Helpers::TagHelper @@ -1867,10 +1873,10 @@ class SimpleForm::Inputs::Base # source://simple_form//lib/simple_form/inputs/base.rb#28 def column; end - # source://actionview/7.0.5/lib/action_view/helpers/translation_helper.rb#18 + # source://actionview/7.2.0/lib/action_view/helpers/translation_helper.rb#18 def debug_missing_translation; end - # source://actionview/7.0.5/lib/action_view/helpers/translation_helper.rb#18 + # source://actionview/7.2.0/lib/action_view/helpers/translation_helper.rb#18 def debug_missing_translation=(val); end # source://simple_form//lib/simple_form/inputs/base.rb#33 @@ -2018,10 +2024,10 @@ class SimpleForm::Inputs::Base def translate_from_namespace(namespace, default = T.unsafe(nil)); end class << self - # source://actionview/7.0.5/lib/action_view/helpers/translation_helper.rb#18 + # source://actionview/7.2.0/lib/action_view/helpers/translation_helper.rb#18 def debug_missing_translation; end - # source://actionview/7.0.5/lib/action_view/helpers/translation_helper.rb#18 + # source://actionview/7.2.0/lib/action_view/helpers/translation_helper.rb#18 def debug_missing_translation=(val); end # source://simple_form//lib/simple_form/inputs/base.rb#33 @@ -2462,7 +2468,7 @@ end # Raised when fails to find a given wrapper name # -# source://simple_form//lib/simple_form.rb#222 +# source://simple_form//lib/simple_form.rb#226 class SimpleForm::WrapperNotFound < ::StandardError; end # source://simple_form//lib/simple_form/wrappers.rb#3 diff --git a/sorbet/rbi/gems/simplecov-html@0.10.2.rbi b/sorbet/rbi/gems/simplecov-html@0.10.2.rbi index 854b3d7bc..44835e55c 100644 --- a/sorbet/rbi/gems/simplecov-html@0.10.2.rbi +++ b/sorbet/rbi/gems/simplecov-html@0.10.2.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `simplecov-html` gem. # Please instead update this file by running `bin/tapioca gem simplecov-html`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/simplecov@0.16.1.rbi b/sorbet/rbi/gems/simplecov@0.16.1.rbi index b16537825..1958acbc8 100644 --- a/sorbet/rbi/gems/simplecov@0.16.1.rbi +++ b/sorbet/rbi/gems/simplecov@0.16.1.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `simplecov` gem. # Please instead update this file by running `bin/tapioca gem simplecov`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/solargraph@0.49.0.rbi b/sorbet/rbi/gems/solargraph@0.50.0.rbi similarity index 99% rename from sorbet/rbi/gems/solargraph@0.49.0.rbi rename to sorbet/rbi/gems/solargraph@0.50.0.rbi index 1befd933f..2d87e0a8f 100644 --- a/sorbet/rbi/gems/solargraph@0.49.0.rbi +++ b/sorbet/rbi/gems/solargraph@0.50.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `solargraph` gem. # Please instead update this file by running `bin/tapioca gem solargraph`. + # source://solargraph//lib/solargraph/converters/dl.rb#1 module ReverseMarkdown class << self @@ -53,9 +54,6 @@ class ReverseMarkdown::Converters::Dt < ::ReverseMarkdown::Converters::Base def convert(node, state = T.unsafe(nil)); end end -# source://reverse_markdown/2.1.1/lib/reverse_markdown/version.rb#2 -ReverseMarkdown::VERSION = T.let(T.unsafe(nil), String) - # source://solargraph//lib/solargraph/parser/rubyvm.rb#13 class RubyVM::AbstractSyntaxTree::Node # source://solargraph//lib/solargraph/parser/rubyvm.rb#18 @@ -876,24 +874,24 @@ module Solargraph::Cache # source://solargraph//lib/solargraph/cache.rb#9 def base_dir; end - # source://solargraph//lib/solargraph/cache.rb#46 + # source://solargraph//lib/solargraph/cache.rb#48 def clear; end # @return [Array, nil] # - # source://solargraph//lib/solargraph/cache.rb#25 + # source://solargraph//lib/solargraph/cache.rb#27 def load(*path); end # @return [Boolean] # - # source://solargraph//lib/solargraph/cache.rb#36 + # source://solargraph//lib/solargraph/cache.rb#38 def save(*path, pins); end # The working directory for the current Ruby and Solargraph versions. # # @return [String] # - # source://solargraph//lib/solargraph/cache.rb#18 + # source://solargraph//lib/solargraph/cache.rb#20 def work_dir; end end end @@ -3463,14 +3461,14 @@ class Solargraph::Library # source://solargraph//lib/solargraph/library.rb#67 def attached?(filename); end - # source://solargraph//lib/solargraph/library.rb#386 + # source://solargraph//lib/solargraph/library.rb#390 def bench; end # Update the ApiMap from the library's workspace and open files. # # @return [void] # - # source://solargraph//lib/solargraph/library.rb#372 + # source://solargraph//lib/solargraph/library.rb#376 def catalog; end # Close a file in the library. Closing a file will make it unavailable for @@ -3561,13 +3559,13 @@ class Solargraph::Library # @param filename [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#339 + # source://solargraph//lib/solargraph/library.rb#343 def diagnose(filename); end # @param query [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#286 + # source://solargraph//lib/solargraph/library.rb#290 def document(query); end # Get an array of document symbols. @@ -3579,10 +3577,10 @@ class Solargraph::Library # @param filename [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#312 + # source://solargraph//lib/solargraph/library.rb#316 def document_symbols(filename); end - # source://solargraph//lib/solargraph/library.rb#466 + # source://solargraph//lib/solargraph/library.rb#470 def external_requires; end # Get an array of foldable ranges for the specified file. @@ -3592,7 +3590,7 @@ class Solargraph::Library # @param filename [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#401 + # source://solargraph//lib/solargraph/library.rb#405 def folding_ranges(filename); end # Get an array of pins that match a path. @@ -3600,7 +3598,7 @@ class Solargraph::Library # @param path [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#280 + # source://solargraph//lib/solargraph/library.rb#284 def get_path_pins(path); end # source://solargraph//lib/solargraph/library.rb#28 @@ -3614,15 +3612,20 @@ class Solargraph::Library # source://solargraph//lib/solargraph/library.rb#257 def locate_pins(location); end - # source://solargraph//lib/solargraph/library.rb#261 + # Match a require reference to a file. + # + # @param location [Location] + # @return [Location, nil] + # + # source://solargraph//lib/solargraph/library.rb#265 def locate_ref(location); end - # source://solargraph//lib/solargraph/library.rb#454 + # source://solargraph//lib/solargraph/library.rb#458 def map!; end # @return [Boolean] # - # source://solargraph//lib/solargraph/library.rb#434 + # source://solargraph//lib/solargraph/library.rb#438 def mapped?; end # Try to merge a source into the library's workspace. If the workspace is @@ -3631,7 +3634,7 @@ class Solargraph::Library # @param source [Source] # @return [Boolean] True if the source was merged into the workspace. # - # source://solargraph//lib/solargraph/library.rb#419 + # source://solargraph//lib/solargraph/library.rb#423 def merge(source); end # @return [String, nil] @@ -3639,7 +3642,7 @@ class Solargraph::Library # source://solargraph//lib/solargraph/library.rb#15 def name; end - # source://solargraph//lib/solargraph/library.rb#438 + # source://solargraph//lib/solargraph/library.rb#442 def next_map; end # True if the specified file is currently attached. @@ -3653,10 +3656,10 @@ class Solargraph::Library # @param path [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#318 + # source://solargraph//lib/solargraph/library.rb#322 def path_pins(path); end - # source://solargraph//lib/solargraph/library.rb#462 + # source://solargraph//lib/solargraph/library.rb#466 def pins; end # Get an array of all symbols in the workspace that match the query. @@ -3664,7 +3667,7 @@ class Solargraph::Library # @param query [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#300 + # source://solargraph//lib/solargraph/library.rb#304 def query_symbols(query); end # Get the current text of a file in the library. @@ -3672,7 +3675,7 @@ class Solargraph::Library # @param filename [String] # @return [String] # - # source://solargraph//lib/solargraph/library.rb#330 + # source://solargraph//lib/solargraph/library.rb#334 def read_text(filename); end # @param filename [String] @@ -3689,7 +3692,7 @@ class Solargraph::Library # @param query [String] # @return [Array] # - # source://solargraph//lib/solargraph/library.rb#292 + # source://solargraph//lib/solargraph/library.rb#296 def search(query); end # Get signature suggestions for the method at the specified file and @@ -3704,10 +3707,10 @@ class Solargraph::Library # source://solargraph//lib/solargraph/library.rb#210 def signatures_at(filename, line, column); end - # source://solargraph//lib/solargraph/library.rb#430 + # source://solargraph//lib/solargraph/library.rb#434 def source_map_hash; end - # source://solargraph//lib/solargraph/library.rb#322 + # source://solargraph//lib/solargraph/library.rb#326 def source_maps; end # True if the ApiMap is up to date with the library's workspace and open @@ -3727,26 +3730,26 @@ class Solargraph::Library # @return [ApiMap] # - # source://solargraph//lib/solargraph/library.rb#495 + # source://solargraph//lib/solargraph/library.rb#499 def api_map; end - # source://solargraph//lib/solargraph/library.rb#378 + # source://solargraph//lib/solargraph/library.rb#382 def catalog_inlock; end # @param source_map [SourceMap] # - # source://solargraph//lib/solargraph/library.rb#477 + # source://solargraph//lib/solargraph/library.rb#481 def find_external_requires(source_map); end - # source://solargraph//lib/solargraph/library.rb#513 + # source://solargraph//lib/solargraph/library.rb#517 def handle_file_not_found(filename, error); end - # source://solargraph//lib/solargraph/library.rb#522 + # source://solargraph//lib/solargraph/library.rb#526 def maybe_map(source); end # @return [Mutex] # - # source://solargraph//lib/solargraph/library.rb#490 + # source://solargraph//lib/solargraph/library.rb#494 def mutex; end # Get the source for an open file or create a new source if the file @@ -3758,10 +3761,10 @@ class Solargraph::Library # @raise [FileNotFoundError] if the file does not exist # @return [Solargraph::Source] # - # source://solargraph//lib/solargraph/library.rb#507 + # source://solargraph//lib/solargraph/library.rb#511 def read(filename); end - # source://solargraph//lib/solargraph/library.rb#472 + # source://solargraph//lib/solargraph/library.rb#476 def source_map_external_require_hash; end class << self @@ -3771,7 +3774,7 @@ class Solargraph::Library # @param name [String, nil] # @return [Solargraph::Library] # - # source://solargraph//lib/solargraph/library.rb#410 + # source://solargraph//lib/solargraph/library.rb#414 def load(directory = T.unsafe(nil), name = T.unsafe(nil)); end end end @@ -6814,12 +6817,10 @@ class Solargraph::Shell < ::Thor # source://solargraph//lib/solargraph/shell.rb#102 def available_cores; end - # source://solargraph//lib/solargraph/shell.rb#204 + # source://solargraph//lib/solargraph/shell.rb#214 def bundle; end - # @deprecated - # - # source://solargraph//lib/solargraph/shell.rb#112 + # source://solargraph//lib/solargraph/shell.rb#111 def clear; end # source://solargraph//lib/solargraph/shell.rb#52 @@ -6830,18 +6831,21 @@ class Solargraph::Shell < ::Thor # source://solargraph//lib/solargraph/shell.rb#80 def download_core(_version = T.unsafe(nil)); end + # source://solargraph//lib/solargraph/shell.rb#200 + def list; end + # @deprecated # # source://solargraph//lib/solargraph/shell.rb#91 def list_cores; end - # source://solargraph//lib/solargraph/shell.rb#212 + # source://solargraph//lib/solargraph/shell.rb#222 def rdoc(_gem, _version = T.unsafe(nil)); end - # source://solargraph//lib/solargraph/shell.rb#131 + # source://solargraph//lib/solargraph/shell.rb#130 def reporters; end - # source://solargraph//lib/solargraph/shell.rb#176 + # source://solargraph//lib/solargraph/shell.rb#175 def scan; end # source://solargraph//lib/solargraph/shell.rb#19 @@ -6850,12 +6854,12 @@ class Solargraph::Shell < ::Thor # source://solargraph//lib/solargraph/shell.rb#36 def stdio; end - # source://solargraph//lib/solargraph/shell.rb#144 + # source://solargraph//lib/solargraph/shell.rb#143 def typecheck(*files); end # @raise [ArgumentError] # - # source://solargraph//lib/solargraph/shell.rb#120 + # source://solargraph//lib/solargraph/shell.rb#119 def uncache(*gems); end # source://solargraph//lib/solargraph/shell.rb#12 @@ -6866,7 +6870,7 @@ class Solargraph::Shell < ::Thor # @param pin [Solargraph::Pin::Base] # @return [String] # - # source://solargraph//lib/solargraph/shell.rb#220 + # source://solargraph//lib/solargraph/shell.rb#230 def pin_description(pin); end end @@ -8281,7 +8285,7 @@ class Solargraph::SourceMap::Mapper # @return [Boolean] # - # source://solargraph//lib/solargraph/source_map/mapper.rb#204 + # source://solargraph//lib/solargraph/source_map/mapper.rb#206 def no_empty_lines?(line1, line2); end # @return [Array] @@ -8294,7 +8298,7 @@ class Solargraph::SourceMap::Mapper # @return [void] # - # source://solargraph//lib/solargraph/source_map/mapper.rb#228 + # source://solargraph//lib/solargraph/source_map/mapper.rb#230 def process_comment_directives; end # @param source_position [Position] @@ -8305,7 +8309,7 @@ class Solargraph::SourceMap::Mapper # source://solargraph//lib/solargraph/source_map/mapper.rb#98 def process_directive(source_position, comment_position, directive); end - # source://solargraph//lib/solargraph/source_map/mapper.rb#208 + # source://solargraph//lib/solargraph/source_map/mapper.rb#210 def remove_inline_comment_hashes(comment); end # @param filename [String] @@ -8329,7 +8333,7 @@ class Solargraph::SourceMap::Mapper end # source://solargraph//lib/solargraph/source_map/mapper.rb#15 -Solargraph::SourceMap::Mapper::MACRO_REGEXP = T.let(T.unsafe(nil), Regexp) +Solargraph::SourceMap::Mapper::DIRECTIVE_REGEXP = T.let(T.unsafe(nil), Regexp) # source://solargraph//lib/solargraph.rb#14 class Solargraph::SourceNotAvailableError < ::StandardError; end diff --git a/sorbet/rbi/gems/spoom@1.1.15.rbi b/sorbet/rbi/gems/spoom@1.1.15.rbi deleted file mode 100644 index 5fd99efa1..000000000 --- a/sorbet/rbi/gems/spoom@1.1.15.rbi +++ /dev/null @@ -1,2383 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `spoom` gem. -# Please instead update this file by running `bin/tapioca gem spoom`. - -# source://spoom//lib/spoom.rb#7 -module Spoom - class << self - # source://spoom//lib/spoom.rb#45 - sig { params(cmd: ::String, arg: ::String, path: ::String, capture_err: T::Boolean).returns(::Spoom::ExecResult) } - def exec(cmd, *arg, path: T.unsafe(nil), capture_err: T.unsafe(nil)); end - end -end - -# source://spoom//lib/spoom/cli/helper.rb#9 -module Spoom::Cli; end - -# source://spoom//lib/spoom/cli/bump.rb#9 -class Spoom::Cli::Bump < ::Thor - include ::Spoom::Colorize - include ::Spoom::Cli::Helper - - # source://spoom//lib/spoom/cli/bump.rb#33 - sig { params(directory: ::String).void } - def bump(directory = T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/bump.rb#170 - def config_files(path: T.unsafe(nil)); end - - def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/bump.rb#144 - def print_changes(files, command:, from: T.unsafe(nil), to: T.unsafe(nil), dry: T.unsafe(nil), path: T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/bump.rb#166 - def undo_changes(files, from_strictness); end -end - -# source://spoom//lib/spoom/cli/config.rb#9 -class Spoom::Cli::Config < ::Thor - include ::Spoom::Colorize - include ::Spoom::Cli::Helper - - def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/config.rb#15 - def show; end -end - -# source://spoom//lib/spoom/cli/coverage.rb#9 -class Spoom::Cli::Coverage < ::Thor - include ::Spoom::Colorize - include ::Spoom::Cli::Helper - - # source://spoom//lib/spoom/cli/coverage.rb#186 - def bundle_install(path, sha); end - - def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/coverage.rb#198 - def message_no_data(file); end - - # source://spoom//lib/spoom/cli/coverage.rb#161 - def open(file = T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/coverage.rb#177 - def parse_time(string, option); end - - # source://spoom//lib/spoom/cli/coverage.rb#130 - def report; end - - # source://spoom//lib/spoom/cli/coverage.rb#20 - def snapshot; end - - # source://spoom//lib/spoom/cli/coverage.rb#43 - def timeline; end -end - -# source://spoom//lib/spoom/cli/coverage.rb#12 -Spoom::Cli::Coverage::DATA_DIR = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/cli/helper.rb#10 -module Spoom::Cli::Helper - include ::Spoom::Colorize - - requires_ancestor { Thor } - - # source://spoom//lib/spoom/cli/helper.rb#143 - sig { params(string: ::String).returns(::String) } - def blue(string); end - - # source://spoom//lib/spoom/cli/helper.rb#87 - sig { params(exit_code: ::Integer, block: T.nilable(T.proc.void)).void } - def check_sorbet_segfault(exit_code, &block); end - - # Is the `--color` option true? - # - # source://spoom//lib/spoom/cli/helper.rb#107 - sig { returns(T::Boolean) } - def color?; end - - # Colorize a string if `color?` - # - # source://spoom//lib/spoom/cli/helper.rb#136 - sig { params(string: ::String, color: ::Spoom::Color).returns(::String) } - def colorize(string, *color); end - - # source://spoom//lib/spoom/cli/helper.rb#148 - sig { params(string: ::String).returns(::String) } - def cyan(string); end - - # Return the path specified through `--path` - # - # source://spoom//lib/spoom/cli/helper.rb#72 - sig { returns(::String) } - def exec_path; end - - # source://spoom//lib/spoom/cli/helper.rb#153 - sig { params(string: ::String).returns(::String) } - def gray(string); end - - # source://spoom//lib/spoom/cli/helper.rb#158 - sig { params(string: ::String).returns(::String) } - def green(string); end - - # source://spoom//lib/spoom/cli/helper.rb#112 - sig { params(string: ::String).returns(::String) } - def highlight(string); end - - # Enforce that `spoom` is ran inside a project with a `sorbet/config` file - # - # Display an error message and exit otherwise. - # - # source://spoom//lib/spoom/cli/helper.rb#59 - sig { void } - def in_sorbet_project!; end - - # Is `spoom` ran inside a project with a `sorbet/config` file? - # - # source://spoom//lib/spoom/cli/helper.rb#51 - sig { returns(T::Boolean) } - def in_sorbet_project?; end - - # source://spoom//lib/spoom/cli/helper.rb#163 - sig { params(string: ::String).returns(::String) } - def red(string); end - - # Print `message` on `$stdout` - # - # source://spoom//lib/spoom/cli/helper.rb#20 - sig { params(message: ::String).void } - def say(message); end - - # Print `message` on `$stderr` - # - # The message is prefixed by a status (default: `Error`). - # - # source://spoom//lib/spoom/cli/helper.rb#39 - sig { params(message: ::String, status: T.nilable(::String), nl: T::Boolean).void } - def say_error(message, status: T.unsafe(nil), nl: T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/helper.rb#82 - sig { returns(::Spoom::Sorbet::Config) } - def sorbet_config; end - - # source://spoom//lib/spoom/cli/helper.rb#77 - sig { returns(::String) } - def sorbet_config_file; end - - # source://spoom//lib/spoom/cli/helper.rb#168 - sig { params(string: ::String).returns(::String) } - def yellow(string); end -end - -# source://spoom//lib/spoom/cli/lsp.rb#10 -class Spoom::Cli::LSP < ::Thor - include ::Spoom::Colorize - include ::Spoom::Cli::Helper - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#54 - def defs(file, line, col); end - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#64 - def find(query); end - - def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#40 - def hover(file, line, col); end - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#25 - def list; end - - # source://spoom//lib/spoom/cli/lsp.rb#113 - def lsp_client; end - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#84 - def refs(file, line, col); end - - # source://spoom//lib/spoom/cli/lsp.rb#135 - def run(&block); end - - # source://spoom//lib/spoom/cli/lsp.rb#16 - def show; end - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#94 - def sigs(file, line, col); end - - # source://spoom//lib/spoom/cli/lsp.rb#127 - def symbol_printer; end - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#74 - def symbols(file); end - - # source://spoom//lib/spoom/cli/lsp.rb#160 - def to_uri(path); end - - # TODO: options, filter, limit, kind etc.. filter rbi - # - # source://spoom//lib/spoom/cli/lsp.rb#104 - def types(file, line, col); end -end - -# source://spoom//lib/spoom/cli.rb#16 -class Spoom::Cli::Main < ::Thor - include ::Spoom::Colorize - include ::Spoom::Cli::Helper - - # source://spoom//lib/spoom/cli.rb#68 - def __print_version; end - - # source://thor/1.2.2/lib/thor.rb#239 - def bump(*args); end - - # source://thor/1.2.2/lib/thor.rb#239 - def config(*args); end - - # source://thor/1.2.2/lib/thor.rb#239 - def coverage(*args); end - - # source://spoom//lib/spoom/cli.rb#43 - def files; end - - # source://thor/1.2.2/lib/thor.rb#239 - def lsp(*args); end - - # source://thor/1.2.2/lib/thor.rb#239 - def tc(*args); end - - class << self - # @return [Boolean] - # - # source://spoom//lib/spoom/cli.rb#75 - def exit_on_failure?; end - end -end - -# source://spoom//lib/spoom/cli/run.rb#6 -class Spoom::Cli::Run < ::Thor - include ::Spoom::Colorize - include ::Spoom::Cli::Helper - - # source://spoom//lib/spoom/cli/run.rb#124 - def colorize_message(message); end - - # source://spoom//lib/spoom/cli/run.rb#115 - def format_error(error, format); end - - def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end - - # source://spoom//lib/spoom/cli/run.rb#26 - def tc(*paths_to_select); end -end - -# source://spoom//lib/spoom/cli/run.rb#15 -Spoom::Cli::Run::DEFAULT_FORMAT = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/cli/run.rb#11 -Spoom::Cli::Run::SORT_CODE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/cli/run.rb#13 -Spoom::Cli::Run::SORT_ENUM = T.let(T.unsafe(nil), Array) - -# source://spoom//lib/spoom/cli/run.rb#12 -Spoom::Cli::Run::SORT_LOC = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/colors.rb#5 -class Spoom::Color < ::T::Enum - enums do - CLEAR = new - BOLD = new - BLACK = new - RED = new - GREEN = new - YELLOW = new - BLUE = new - MAGENTA = new - CYAN = new - WHITE = new - LIGHT_BLACK = new - LIGHT_RED = new - LIGHT_GREEN = new - LIGHT_YELLOW = new - LIGHT_BLUE = new - LIGHT_MAGENTA = new - LIGHT_CYAN = new - LIGHT_WHITE = new - end - - # source://spoom//lib/spoom/colors.rb#32 - sig { returns(::String) } - def ansi_code; end -end - -# source://spoom//lib/spoom/colors.rb#37 -module Spoom::Colorize - # source://spoom//lib/spoom/colors.rb#41 - sig { params(string: ::String, color: ::Spoom::Color).returns(::String) } - def set_color(string, *color); end -end - -# An abstraction to a Ruby project context -# -# A context maps to a directory in the file system. -# It is used to manipulate files and run commands in the context of this directory. -# -# source://spoom//lib/spoom/context.rb#12 -class Spoom::Context - # Create a new context about `absolute_path` - # - # The directory will not be created if it doesn't exist. - # Call `#make!` to create it. - # - # source://spoom//lib/spoom/context.rb#37 - sig { params(absolute_path: ::String).void } - def initialize(absolute_path); end - - # The absolute path to the directory this context is about - # - # source://spoom//lib/spoom/context.rb#17 - sig { returns(::String) } - def absolute_path; end - - # Returns the absolute path to `relative_path` in the context's directory - # - # source://spoom//lib/spoom/context.rb#43 - sig { params(relative_path: ::String).returns(::String) } - def absolute_path_to(relative_path); end - - # Run a command with `bundle` in this context directory - # - # source://spoom//lib/spoom/context.rb#156 - sig { params(command: ::String, version: T.nilable(::String)).returns(::Spoom::ExecResult) } - def bundle(command, version: T.unsafe(nil)); end - - # Run a command `bundle exec` in this context directory - # - # source://spoom//lib/spoom/context.rb#169 - sig { params(command: ::String, version: T.nilable(::String)).returns(::Spoom::ExecResult) } - def bundle_exec(command, version: T.unsafe(nil)); end - - # Run `bundle install` in this context directory - # - # source://spoom//lib/spoom/context.rb#163 - sig { params(version: T.nilable(::String)).returns(::Spoom::ExecResult) } - def bundle_install!(version: T.unsafe(nil)); end - - # Delete this context and its content - # - # Warning: it will `rm -rf` the context directory on the file system. - # - # source://spoom//lib/spoom/context.rb#118 - sig { void } - def destroy!; end - - # Run a command in this context directory - # - # source://spoom//lib/spoom/context.rb#126 - sig { params(command: ::String, capture_err: T::Boolean).returns(::Spoom::ExecResult) } - def exec(command, capture_err: T.unsafe(nil)); end - - # Does the context directory at `absolute_path` exist and is a directory? - # - # source://spoom//lib/spoom/context.rb#51 - sig { returns(T::Boolean) } - def exist?; end - - # Does `relative_path` point to an existing file in this context directory? - # - # source://spoom//lib/spoom/context.rb#78 - sig { params(relative_path: ::String).returns(T::Boolean) } - def file?(relative_path); end - - # Run a command prefixed by `git` in this context directory - # - # source://spoom//lib/spoom/context.rb#177 - sig { params(command: ::String).returns(::Spoom::ExecResult) } - def git(command); end - - # Run `git checkout` in this context directory - # - # source://spoom//lib/spoom/context.rb#189 - sig { params(ref: ::String).returns(::Spoom::ExecResult) } - def git_checkout!(ref: T.unsafe(nil)); end - - # Get the current git branch in this context directory - # - # source://spoom//lib/spoom/context.rb#195 - sig { returns(T.nilable(::String)) } - def git_current_branch; end - - # Run `git init` in this context directory - # - # source://spoom//lib/spoom/context.rb#183 - sig { params(branch: ::String).void } - def git_init!(branch: T.unsafe(nil)); end - - # Get the last commit in the currently checked out branch - # - # source://spoom//lib/spoom/context.rb#201 - sig { params(short_sha: T::Boolean).returns(T.nilable(::Spoom::Git::Commit)) } - def git_last_commit(short_sha: T.unsafe(nil)); end - - # List all files in this context matching `pattern` - # - # source://spoom//lib/spoom/context.rb#64 - sig { params(pattern: ::String).returns(T::Array[::String]) } - def glob(pattern = T.unsafe(nil)); end - - # List all files at the top level of this context directory - # - # source://spoom//lib/spoom/context.rb#72 - sig { returns(T::Array[::String]) } - def list; end - - # Create the context directory at `absolute_path` - # - # source://spoom//lib/spoom/context.rb#57 - sig { void } - def mkdir!; end - - # Move the file or directory from `from_relative_path` to `to_relative_path` - # - # source://spoom//lib/spoom/context.rb#108 - sig { params(from_relative_path: ::String, to_relative_path: ::String).void } - def move!(from_relative_path, to_relative_path); end - - # Return the contents of the file at `relative_path` in this context directory - # - # Will raise if the file doesn't exist. - # - # source://spoom//lib/spoom/context.rb#86 - sig { params(relative_path: ::String).returns(::String) } - def read(relative_path); end - - # Read the strictness sigil from the file at `relative_path` (returns `nil` if no sigil) - # - # source://spoom//lib/spoom/context.rb#227 - sig { params(relative_path: ::String).returns(T.nilable(::String)) } - def read_file_strictness(relative_path); end - - # Read the `contents` of the Gemfile in this context directory - # - # source://spoom//lib/spoom/context.rb#144 - sig { returns(T.nilable(::String)) } - def read_gemfile; end - - # Read the contents of `sorbet/config` in this context directory - # - # source://spoom//lib/spoom/context.rb#215 - sig { returns(::String) } - def read_sorbet_config; end - - # Remove the path at `relative_path` (recursive + force) in this context directory - # - # source://spoom//lib/spoom/context.rb#102 - sig { params(relative_path: ::String).void } - def remove!(relative_path); end - - # Run `bundle exec srb` in this context directory - # - # source://spoom//lib/spoom/context.rb#209 - sig { params(command: ::String).returns(::Spoom::ExecResult) } - def srb(command); end - - # Write `contents` in the file at `relative_path` in this context directory - # - # Append to the file if `append` is true. - # - # source://spoom//lib/spoom/context.rb#94 - sig { params(relative_path: ::String, contents: ::String, append: T::Boolean).void } - def write!(relative_path, contents = T.unsafe(nil), append: T.unsafe(nil)); end - - # Set the `contents` of the Gemfile in this context directory - # - # source://spoom//lib/spoom/context.rb#150 - sig { params(contents: ::String, append: T::Boolean).void } - def write_gemfile!(contents, append: T.unsafe(nil)); end - - # Set the `contents` of `sorbet/config` in this context directory - # - # source://spoom//lib/spoom/context.rb#221 - sig { params(contents: ::String, append: T::Boolean).void } - def write_sorbet_config!(contents, append: T.unsafe(nil)); end - - class << self - # Create a new context in the system's temporary directory - # - # `name` is used as prefix to the temporary directory name. - # The directory will be created if it doesn't exist. - # - # source://spoom//lib/spoom/context.rb#27 - sig { params(name: T.nilable(::String)).returns(T.attached_class) } - def mktmp!(name = T.unsafe(nil)); end - end -end - -# source://spoom//lib/spoom/coverage/snapshot.rb#5 -module Spoom::Coverage - class << self - # source://spoom//lib/spoom/coverage.rb#90 - sig do - params( - snapshots: T::Array[::Spoom::Coverage::Snapshot], - palette: ::Spoom::Coverage::D3::ColorPalette, - path: ::String - ).returns(::Spoom::Coverage::Report) - end - def report(snapshots, palette:, path: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage.rb#109 - sig { params(path: ::String).returns(::Spoom::FileTree) } - def sigils_tree(path: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage.rb#16 - sig do - params( - path: ::String, - rbi: T::Boolean, - sorbet_bin: T.nilable(::String) - ).returns(::Spoom::Coverage::Snapshot) - end - def snapshot(path: T.unsafe(nil), rbi: T.unsafe(nil), sorbet_bin: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage.rb#104 - sig { params(path: ::String).returns(::Spoom::Sorbet::Config) } - def sorbet_config(path: T.unsafe(nil)); end - end -end - -# source://spoom//lib/spoom/coverage/report.rb#88 -module Spoom::Coverage::Cards; end - -# source://spoom//lib/spoom/coverage/report.rb#89 -class Spoom::Coverage::Cards::Card < ::Spoom::Coverage::Template - # source://spoom//lib/spoom/coverage/report.rb#98 - sig { params(template: ::String, title: T.nilable(::String), body: T.nilable(::String)).void } - def initialize(template: T.unsafe(nil), title: T.unsafe(nil), body: T.unsafe(nil)); end - - # @return [String, nil] - # - # source://spoom//lib/spoom/coverage/report.rb#95 - def body; end - - # source://spoom//lib/spoom/coverage/report.rb#95 - sig { returns(T.nilable(::String)) } - def title; end -end - -# source://spoom//lib/spoom/coverage/report.rb#92 -Spoom::Coverage::Cards::Card::TEMPLATE = T.let(T.unsafe(nil), String) - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/coverage/report.rb#105 -class Spoom::Coverage::Cards::Erb < ::Spoom::Coverage::Cards::Card - abstract! - - # source://spoom//lib/spoom/coverage/report.rb#112 - sig { void } - def initialize; end - - # @abstract - # - # source://spoom//lib/spoom/coverage/report.rb#120 - sig { abstract.returns(::String) } - def erb; end - - # source://spoom//lib/spoom/coverage/report.rb#115 - sig { override.returns(::String) } - def html; end -end - -# source://spoom//lib/spoom/coverage/report.rb#153 -class Spoom::Coverage::Cards::Map < ::Spoom::Coverage::Cards::Card - # source://spoom//lib/spoom/coverage/report.rb#157 - sig { params(sigils_tree: ::Spoom::FileTree, title: ::String).void } - def initialize(sigils_tree:, title: T.unsafe(nil)); end -end - -# source://spoom//lib/spoom/coverage/report.rb#123 -class Spoom::Coverage::Cards::Snapshot < ::Spoom::Coverage::Cards::Card - # source://spoom//lib/spoom/coverage/report.rb#132 - sig { params(snapshot: ::Spoom::Coverage::Snapshot, title: ::String).void } - def initialize(snapshot:, title: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/report.rb#143 - sig { returns(::Spoom::Coverage::D3::Pie::Calls) } - def pie_calls; end - - # source://spoom//lib/spoom/coverage/report.rb#138 - sig { returns(::Spoom::Coverage::D3::Pie::Sigils) } - def pie_sigils; end - - # source://spoom//lib/spoom/coverage/report.rb#148 - sig { returns(::Spoom::Coverage::D3::Pie::Sigs) } - def pie_sigs; end - - # source://spoom//lib/spoom/coverage/report.rb#129 - sig { returns(::Spoom::Coverage::Snapshot) } - def snapshot; end -end - -# source://spoom//lib/spoom/coverage/report.rb#126 -Spoom::Coverage::Cards::Snapshot::TEMPLATE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/coverage/report.rb#225 -class Spoom::Coverage::Cards::SorbetIntro < ::Spoom::Coverage::Cards::Erb - # source://spoom//lib/spoom/coverage/report.rb#229 - sig { params(sorbet_intro_commit: T.nilable(::String), sorbet_intro_date: T.nilable(::Time)).void } - def initialize(sorbet_intro_commit: T.unsafe(nil), sorbet_intro_date: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/report.rb#235 - sig { override.returns(::String) } - def erb; end -end - -# source://spoom//lib/spoom/coverage/report.rb#162 -class Spoom::Coverage::Cards::Timeline < ::Spoom::Coverage::Cards::Card - # source://spoom//lib/spoom/coverage/report.rb#166 - sig { params(title: ::String, timeline: ::Spoom::Coverage::D3::Timeline).void } - def initialize(title:, timeline:); end -end - -# source://spoom//lib/spoom/coverage/report.rb#179 -class Spoom::Coverage::Cards::Timeline::Calls < ::Spoom::Coverage::Cards::Timeline - # source://spoom//lib/spoom/coverage/report.rb#183 - sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } - def initialize(snapshots:, title: T.unsafe(nil)); end -end - -# source://spoom//lib/spoom/coverage/report.rb#197 -class Spoom::Coverage::Cards::Timeline::RBIs < ::Spoom::Coverage::Cards::Timeline - # source://spoom//lib/spoom/coverage/report.rb#201 - sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } - def initialize(snapshots:, title: T.unsafe(nil)); end -end - -# source://spoom//lib/spoom/coverage/report.rb#215 -class Spoom::Coverage::Cards::Timeline::Runtimes < ::Spoom::Coverage::Cards::Timeline - # source://spoom//lib/spoom/coverage/report.rb#219 - sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } - def initialize(snapshots:, title: T.unsafe(nil)); end -end - -# source://spoom//lib/spoom/coverage/report.rb#170 -class Spoom::Coverage::Cards::Timeline::Sigils < ::Spoom::Coverage::Cards::Timeline - # source://spoom//lib/spoom/coverage/report.rb#174 - sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } - def initialize(snapshots:, title: T.unsafe(nil)); end -end - -# source://spoom//lib/spoom/coverage/report.rb#188 -class Spoom::Coverage::Cards::Timeline::Sigs < ::Spoom::Coverage::Cards::Timeline - # source://spoom//lib/spoom/coverage/report.rb#192 - sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } - def initialize(snapshots:, title: T.unsafe(nil)); end -end - -# source://spoom//lib/spoom/coverage/report.rb#206 -class Spoom::Coverage::Cards::Timeline::Versions < ::Spoom::Coverage::Cards::Timeline - # source://spoom//lib/spoom/coverage/report.rb#210 - sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } - def initialize(snapshots:, title: T.unsafe(nil)); end -end - -# source://spoom//lib/spoom/coverage/d3/base.rb#6 -module Spoom::Coverage::D3 - class << self - # source://spoom//lib/spoom/coverage/d3.rb#61 - sig { params(palette: ::Spoom::Coverage::D3::ColorPalette).returns(::String) } - def header_script(palette); end - - # source://spoom//lib/spoom/coverage/d3.rb#21 - sig { returns(::String) } - def header_style; end - end -end - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/coverage/d3/base.rb#7 -class Spoom::Coverage::D3::Base - abstract! - - # source://spoom//lib/spoom/coverage/d3/base.rb#17 - sig { params(id: ::String, data: T.untyped).void } - def initialize(id, data); end - - # source://spoom//lib/spoom/coverage/d3/base.rb#37 - sig { returns(::String) } - def html; end - - # source://spoom//lib/spoom/coverage/d3/base.rb#14 - sig { returns(::String) } - def id; end - - # @abstract - # - # source://spoom//lib/spoom/coverage/d3/base.rb#50 - sig { abstract.returns(::String) } - def script; end - - # source://spoom//lib/spoom/coverage/d3/base.rb#45 - sig { returns(::String) } - def tooltip; end - - class << self - # source://spoom//lib/spoom/coverage/d3/base.rb#31 - sig { returns(::String) } - def header_script; end - - # source://spoom//lib/spoom/coverage/d3/base.rb#26 - sig { returns(::String) } - def header_style; end - end -end - -# source://spoom//lib/spoom/coverage/d3.rb#12 -Spoom::Coverage::D3::COLOR_FALSE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/coverage/d3.rb#11 -Spoom::Coverage::D3::COLOR_IGNORE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/coverage/d3.rb#14 -Spoom::Coverage::D3::COLOR_STRICT = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/coverage/d3.rb#15 -Spoom::Coverage::D3::COLOR_STRONG = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/coverage/d3.rb#13 -Spoom::Coverage::D3::COLOR_TRUE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/coverage/d3/circle_map.rb#9 -class Spoom::Coverage::D3::CircleMap < ::Spoom::Coverage::D3::Base - # source://spoom//lib/spoom/coverage/d3/circle_map.rb#59 - sig { override.returns(::String) } - def script; end - - class << self - # source://spoom//lib/spoom/coverage/d3/circle_map.rb#40 - sig { returns(::String) } - def header_script; end - - # source://spoom//lib/spoom/coverage/d3/circle_map.rb#14 - sig { returns(::String) } - def header_style; end - end -end - -# source://spoom//lib/spoom/coverage/d3/circle_map.rb#148 -class Spoom::Coverage::D3::CircleMap::Sigils < ::Spoom::Coverage::D3::CircleMap - # source://spoom//lib/spoom/coverage/d3/circle_map.rb#152 - sig { params(id: ::String, sigils_tree: ::Spoom::FileTree).void } - def initialize(id, sigils_tree); end - - # source://spoom//lib/spoom/coverage/d3/circle_map.rb#181 - sig { params(node: ::Spoom::FileTree::Node).returns(::Float) } - def tree_node_score(node); end - - # source://spoom//lib/spoom/coverage/d3/circle_map.rb#173 - sig { params(node: ::Spoom::FileTree::Node).returns(T.nilable(::String)) } - def tree_node_strictness(node); end - - # source://spoom//lib/spoom/coverage/d3/circle_map.rb#160 - sig { params(node: ::Spoom::FileTree::Node).returns(T::Hash[::Symbol, T.untyped]) } - def tree_node_to_json(node); end -end - -# source://spoom//lib/spoom/coverage/d3.rb#103 -class Spoom::Coverage::D3::ColorPalette < ::T::Struct - prop :ignore, ::String - prop :false, ::String - prop :true, ::String - prop :strict, ::String - prop :strong, ::String - - class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/coverage/d3/pie.rb#9 -class Spoom::Coverage::D3::Pie < ::Spoom::Coverage::D3::Base - abstract! - - # source://spoom//lib/spoom/coverage/d3/pie.rb#16 - sig { params(id: ::String, title: ::String, data: T.untyped).void } - def initialize(id, title, data); end - - # source://spoom//lib/spoom/coverage/d3/pie.rb#56 - sig { override.returns(::String) } - def script; end - - class << self - # source://spoom//lib/spoom/coverage/d3/pie.rb#43 - sig { returns(::String) } - def header_script; end - - # source://spoom//lib/spoom/coverage/d3/pie.rb#25 - sig { returns(::String) } - def header_style; end - end -end - -# source://spoom//lib/spoom/coverage/d3/pie.rb#141 -class Spoom::Coverage::D3::Pie::Calls < ::Spoom::Coverage::D3::Pie - # source://spoom//lib/spoom/coverage/d3/pie.rb#145 - sig { params(id: ::String, title: ::String, snapshot: ::Spoom::Coverage::Snapshot).void } - def initialize(id, title, snapshot); end - - # source://spoom//lib/spoom/coverage/d3/pie.rb#150 - sig { override.returns(::String) } - def tooltip; end -end - -# source://spoom//lib/spoom/coverage/d3/pie.rb#123 -class Spoom::Coverage::D3::Pie::Sigils < ::Spoom::Coverage::D3::Pie - # source://spoom//lib/spoom/coverage/d3/pie.rb#127 - sig { params(id: ::String, title: ::String, snapshot: ::Spoom::Coverage::Snapshot).void } - def initialize(id, title, snapshot); end - - # source://spoom//lib/spoom/coverage/d3/pie.rb#132 - sig { override.returns(::String) } - def tooltip; end -end - -# source://spoom//lib/spoom/coverage/d3/pie.rb#159 -class Spoom::Coverage::D3::Pie::Sigs < ::Spoom::Coverage::D3::Pie - # source://spoom//lib/spoom/coverage/d3/pie.rb#163 - sig { params(id: ::String, title: ::String, snapshot: ::Spoom::Coverage::Snapshot).void } - def initialize(id, title, snapshot); end - - # source://spoom//lib/spoom/coverage/d3/pie.rb#172 - sig { override.returns(::String) } - def tooltip; end -end - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/coverage/d3/timeline.rb#9 -class Spoom::Coverage::D3::Timeline < ::Spoom::Coverage::D3::Base - abstract! - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#16 - sig { params(id: ::String, data: T.untyped, keys: T::Array[::String]).void } - def initialize(id, data, keys); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#187 - sig { params(y: ::String, color: ::String, curve: ::String).returns(::String) } - def area(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#203 - sig { params(y: ::String, color: ::String, curve: ::String).returns(::String) } - def line(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end - - # @abstract - # - # source://spoom//lib/spoom/coverage/d3/timeline.rb#126 - sig { abstract.returns(::String) } - def plot; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#217 - sig { params(y: ::String).returns(::String) } - def points(y:); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#101 - sig { override.returns(::String) } - def script; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#129 - sig { returns(::String) } - def x_scale; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#145 - sig { returns(::String) } - def x_ticks; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#158 - sig { params(min: ::String, max: ::String, ticks: ::String).returns(::String) } - def y_scale(min:, max:, ticks:); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#174 - sig { params(ticks: ::String, format: ::String, padding: ::Integer).returns(::String) } - def y_ticks(ticks:, format:, padding:); end - - class << self - # source://spoom//lib/spoom/coverage/d3/timeline.rb#79 - sig { returns(::String) } - def header_script; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#25 - sig { returns(::String) } - def header_style; end - end -end - -# source://spoom//lib/spoom/coverage/d3/timeline.rb#448 -class Spoom::Coverage::D3::Timeline::Calls < ::Spoom::Coverage::D3::Timeline::Stacked - # source://spoom//lib/spoom/coverage/d3/timeline.rb#452 - sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } - def initialize(id, snapshots); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#466 - sig { override.returns(::String) } - def tooltip; end -end - -# source://spoom//lib/spoom/coverage/d3/timeline.rb#505 -class Spoom::Coverage::D3::Timeline::RBIs < ::Spoom::Coverage::D3::Timeline::Stacked - # source://spoom//lib/spoom/coverage/d3/timeline.rb#509 - sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } - def initialize(id, snapshots); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#577 - sig { override.params(y: ::String, color: ::String, curve: ::String).returns(::String) } - def line(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#617 - sig { override.returns(::String) } - def plot; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#537 - sig { override.returns(::String) } - def script; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#523 - sig { override.returns(::String) } - def tooltip; end -end - -# source://spoom//lib/spoom/coverage/d3/timeline.rb#282 -class Spoom::Coverage::D3::Timeline::Runtimes < ::Spoom::Coverage::D3::Timeline - # source://spoom//lib/spoom/coverage/d3/timeline.rb#286 - sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } - def initialize(id, snapshots); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#311 - sig { override.returns(::String) } - def plot; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#298 - sig { override.returns(::String) } - def tooltip; end -end - -# source://spoom//lib/spoom/coverage/d3/timeline.rb#421 -class Spoom::Coverage::D3::Timeline::Sigils < ::Spoom::Coverage::D3::Timeline::Stacked - # source://spoom//lib/spoom/coverage/d3/timeline.rb#425 - sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } - def initialize(id, snapshots); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#439 - sig { override.returns(::String) } - def tooltip; end -end - -# source://spoom//lib/spoom/coverage/d3/timeline.rb#475 -class Spoom::Coverage::D3::Timeline::Sigs < ::Spoom::Coverage::D3::Timeline::Stacked - # source://spoom//lib/spoom/coverage/d3/timeline.rb#479 - sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } - def initialize(id, snapshots); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#496 - sig { override.returns(::String) } - def tooltip; end -end - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/coverage/d3/timeline.rb#329 -class Spoom::Coverage::D3::Timeline::Stacked < ::Spoom::Coverage::D3::Timeline - abstract! - - # source://sorbet-runtime/0.5.10601/lib/types/private/abstract/declare.rb#37 - def initialize(*args, **_arg1, &blk); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#388 - sig { override.params(y: ::String, color: ::String, curve: ::String).returns(::String) } - def line(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#377 - sig { override.returns(::String) } - def plot; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#336 - sig { override.returns(::String) } - def script; end -end - -# source://spoom//lib/spoom/coverage/d3/timeline.rb#232 -class Spoom::Coverage::D3::Timeline::Versions < ::Spoom::Coverage::D3::Timeline - # source://spoom//lib/spoom/coverage/d3/timeline.rb#236 - sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } - def initialize(id, snapshots); end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#263 - sig { override.returns(::String) } - def plot; end - - # source://spoom//lib/spoom/coverage/d3/timeline.rb#249 - sig { override.returns(::String) } - def tooltip; end -end - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/coverage/report.rb#38 -class Spoom::Coverage::Page < ::Spoom::Coverage::Template - abstract! - - # source://spoom//lib/spoom/coverage/report.rb#53 - sig { params(title: ::String, palette: ::Spoom::Coverage::D3::ColorPalette, template: ::String).void } - def initialize(title:, palette:, template: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/report.rb#75 - sig { returns(::String) } - def body_html; end - - # @abstract - # - # source://spoom//lib/spoom/coverage/report.rb#80 - sig { abstract.returns(T::Array[::Spoom::Coverage::Cards::Card]) } - def cards; end - - # source://spoom//lib/spoom/coverage/report.rb#83 - sig { returns(::String) } - def footer_html; end - - # source://spoom//lib/spoom/coverage/report.rb#70 - sig { returns(::String) } - def header_html; end - - # source://spoom//lib/spoom/coverage/report.rb#65 - sig { returns(::String) } - def header_script; end - - # source://spoom//lib/spoom/coverage/report.rb#60 - sig { returns(::String) } - def header_style; end - - # source://spoom//lib/spoom/coverage/report.rb#50 - sig { returns(::Spoom::Coverage::D3::ColorPalette) } - def palette; end - - # source://spoom//lib/spoom/coverage/report.rb#47 - sig { returns(::String) } - def title; end -end - -# source://spoom//lib/spoom/coverage/report.rb#44 -Spoom::Coverage::Page::TEMPLATE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/coverage/report.rb#246 -class Spoom::Coverage::Report < ::Spoom::Coverage::Page - # source://spoom//lib/spoom/coverage/report.rb#274 - sig do - params( - project_name: ::String, - palette: ::Spoom::Coverage::D3::ColorPalette, - snapshots: T::Array[::Spoom::Coverage::Snapshot], - sigils_tree: ::Spoom::FileTree, - sorbet_intro_commit: T.nilable(::String), - sorbet_intro_date: T.nilable(::Time) - ).void - end - def initialize(project_name:, palette:, snapshots:, sigils_tree:, sorbet_intro_commit: T.unsafe(nil), sorbet_intro_date: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/report.rb#302 - sig { override.returns(T::Array[::Spoom::Coverage::Cards::Card]) } - def cards; end - - # source://spoom//lib/spoom/coverage/report.rb#291 - sig { override.returns(::String) } - def header_html; end - - # source://spoom//lib/spoom/coverage/report.rb#250 - sig { returns(::String) } - def project_name; end - - # source://spoom//lib/spoom/coverage/report.rb#262 - sig { returns(::Spoom::FileTree) } - def sigils_tree; end - - # source://spoom//lib/spoom/coverage/report.rb#259 - sig { returns(T::Array[::Spoom::Coverage::Snapshot]) } - def snapshots; end - - # source://spoom//lib/spoom/coverage/report.rb#253 - sig { returns(T.nilable(::String)) } - def sorbet_intro_commit; end - - # source://spoom//lib/spoom/coverage/report.rb#256 - sig { returns(T.nilable(::Time)) } - def sorbet_intro_date; end -end - -# source://spoom//lib/spoom/coverage/snapshot.rb#6 -class Spoom::Coverage::Snapshot < ::T::Struct - prop :timestamp, ::Integer, default: T.unsafe(nil) - prop :version_static, T.nilable(::String), default: T.unsafe(nil) - prop :version_runtime, T.nilable(::String), default: T.unsafe(nil) - prop :duration, ::Integer, default: T.unsafe(nil) - prop :commit_sha, T.nilable(::String), default: T.unsafe(nil) - prop :commit_timestamp, T.nilable(::Integer), default: T.unsafe(nil) - prop :files, ::Integer, default: T.unsafe(nil) - prop :rbi_files, ::Integer, default: T.unsafe(nil) - prop :modules, ::Integer, default: T.unsafe(nil) - prop :classes, ::Integer, default: T.unsafe(nil) - prop :singleton_classes, ::Integer, default: T.unsafe(nil) - prop :methods_without_sig, ::Integer, default: T.unsafe(nil) - prop :methods_with_sig, ::Integer, default: T.unsafe(nil) - prop :calls_untyped, ::Integer, default: T.unsafe(nil) - prop :calls_typed, ::Integer, default: T.unsafe(nil) - prop :sigils, T::Hash[::String, ::Integer], default: T.unsafe(nil) - prop :methods_with_sig_excluding_rbis, ::Integer, default: T.unsafe(nil) - prop :methods_without_sig_excluding_rbis, ::Integer, default: T.unsafe(nil) - prop :sigils_excluding_rbis, T::Hash[::String, ::Integer], default: T.unsafe(nil) - - # source://spoom//lib/spoom/coverage/snapshot.rb#33 - sig { params(out: T.any(::IO, ::StringIO), colors: T::Boolean, indent_level: ::Integer).void } - def print(out: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil)); end - - # source://spoom//lib/spoom/coverage/snapshot.rb#39 - sig { params(arg: T.untyped).returns(::String) } - def to_json(*arg); end - - class << self - # source://spoom//lib/spoom/coverage/snapshot.rb#47 - sig { params(json: ::String).returns(::Spoom::Coverage::Snapshot) } - def from_json(json); end - - # source://spoom//lib/spoom/coverage/snapshot.rb#52 - sig { params(obj: T::Hash[::String, T.untyped]).returns(::Spoom::Coverage::Snapshot) } - def from_obj(obj); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# The strictness name as found in the Sorbet metrics file -# -# source://spoom//lib/spoom/coverage/snapshot.rb#30 -Spoom::Coverage::Snapshot::STRICTNESSES = T.let(T.unsafe(nil), Array) - -# source://spoom//lib/spoom/coverage/snapshot.rb#95 -class Spoom::Coverage::SnapshotPrinter < ::Spoom::Printer - # source://spoom//lib/spoom/coverage/snapshot.rb#99 - sig { params(snapshot: ::Spoom::Coverage::Snapshot).void } - def print_snapshot(snapshot); end - - private - - # source://spoom//lib/spoom/coverage/snapshot.rb#158 - sig { params(value: T.nilable(::Integer), total: T.nilable(::Integer)).returns(::String) } - def percent(value, total); end - - # source://spoom//lib/spoom/coverage/snapshot.rb#147 - sig { params(hash: T::Hash[::String, ::Integer], total: ::Integer).void } - def print_map(hash, total); end -end - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/coverage/report.rb#10 -class Spoom::Coverage::Template - abstract! - - # Create a new template from an Erb file path - # - # source://spoom//lib/spoom/coverage/report.rb#18 - sig { params(template: ::String).void } - def initialize(template:); end - - # source://spoom//lib/spoom/coverage/report.rb#23 - sig { returns(::String) } - def erb; end - - # source://spoom//lib/spoom/coverage/report.rb#33 - sig { returns(::Binding) } - def get_binding; end - - # source://spoom//lib/spoom/coverage/report.rb#28 - sig { returns(::String) } - def html; end -end - -# source://spoom//lib/spoom.rb#12 -class Spoom::Error < ::StandardError; end - -# source://spoom//lib/spoom.rb#14 -class Spoom::ExecResult < ::T::Struct - const :out, ::String - const :err, ::String - const :status, T::Boolean - const :exit_code, ::Integer - - # source://spoom//lib/spoom.rb#23 - sig { returns(::String) } - def to_s; end - - class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# Build a file hierarchy from a set of file paths. -# -# source://spoom//lib/spoom/file_tree.rb#6 -class Spoom::FileTree - # source://spoom//lib/spoom/file_tree.rb#13 - sig { params(paths: T::Enumerable[::String], strip_prefix: T.nilable(::String)).void } - def initialize(paths = T.unsafe(nil), strip_prefix: T.unsafe(nil)); end - - # Add a `path` to the tree - # - # This will create all nodes until the root of `path`. - # - # source://spoom//lib/spoom/file_tree.rb#29 - sig { params(path: ::String).returns(::Spoom::FileTree::Node) } - def add_path(path); end - - # Add all `paths` to the tree - # - # source://spoom//lib/spoom/file_tree.rb#21 - sig { params(paths: T::Enumerable[::String]).void } - def add_paths(paths); end - - # All the nodes in this tree - # - # source://spoom//lib/spoom/file_tree.rb#51 - sig { returns(T::Array[::Spoom::FileTree::Node]) } - def nodes; end - - # All the paths in this tree - # - # source://spoom//lib/spoom/file_tree.rb#59 - sig { returns(T::Array[::String]) } - def paths; end - - # source://spoom//lib/spoom/file_tree.rb#71 - sig do - params( - out: T.any(::IO, ::StringIO), - show_strictness: T::Boolean, - colors: T::Boolean, - indent_level: ::Integer - ).void - end - def print(out: T.unsafe(nil), show_strictness: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil)); end - - # All root nodes - # - # source://spoom//lib/spoom/file_tree.rb#45 - sig { returns(T::Array[::Spoom::FileTree::Node]) } - def roots; end - - # source://spoom//lib/spoom/file_tree.rb#10 - sig { returns(T.nilable(::String)) } - def strip_prefix; end - - private - - # source://spoom//lib/spoom/file_tree.rb#85 - sig do - params( - node: ::Spoom::FileTree::Node, - collected_nodes: T::Array[::Spoom::FileTree::Node] - ).returns(T::Array[::Spoom::FileTree::Node]) - end - def collect_nodes(node, collected_nodes = T.unsafe(nil)); end -end - -# A node representing either a file or a directory inside a FileTree -# -# source://spoom//lib/spoom/file_tree.rb#92 -class Spoom::FileTree::Node < ::T::Struct - const :parent, T.nilable(::Spoom::FileTree::Node) - const :name, ::String - const :children, T::Hash[::String, ::Spoom::FileTree::Node], default: T.unsafe(nil) - - # Full path to this node from root - # - # source://spoom//lib/spoom/file_tree.rb#106 - sig { returns(::String) } - def path; end - - class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# An internal class used to print a FileTree -# -# See `FileTree#print` -# -# source://spoom//lib/spoom/file_tree.rb#117 -class Spoom::FileTree::TreePrinter < ::Spoom::Printer - # source://spoom//lib/spoom/file_tree.rb#132 - sig do - params( - tree: ::Spoom::FileTree, - out: T.any(::IO, ::StringIO), - show_strictness: T::Boolean, - colors: T::Boolean, - indent_level: ::Integer - ).void - end - def initialize(tree:, out: T.unsafe(nil), show_strictness: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil)); end - - # source://spoom//lib/spoom/file_tree.rb#144 - sig { params(node: ::Spoom::FileTree::Node).void } - def print_node(node); end - - # source://spoom//lib/spoom/file_tree.rb#171 - sig { params(nodes: T::Array[::Spoom::FileTree::Node]).void } - def print_nodes(nodes); end - - # source://spoom//lib/spoom/file_tree.rb#139 - sig { void } - def print_tree; end - - # source://spoom//lib/spoom/file_tree.rb#121 - sig { returns(::Spoom::FileTree) } - def tree; end - - private - - # source://spoom//lib/spoom/file_tree.rb#178 - sig { params(node: ::Spoom::FileTree::Node).returns(T.nilable(::String)) } - def node_strictness(node); end - - # source://spoom//lib/spoom/file_tree.rb#186 - sig { params(strictness: T.nilable(::String)).returns(::Spoom::Color) } - def strictness_color(strictness); end -end - -# Execute git commands -# -# source://spoom//lib/spoom/git.rb#8 -module Spoom::Git - class << self - # Git commands - # - # source://spoom//lib/spoom/git.rb#48 - sig { params(arg: ::String, path: ::String).returns(::Spoom::ExecResult) } - def checkout(*arg, path: T.unsafe(nil)); end - - # source://spoom//lib/spoom/git.rb#68 - sig { params(path: ::String).returns(T.nilable(::String)) } - def current_branch(path: T.unsafe(nil)); end - - # source://spoom//lib/spoom/git.rb#53 - sig { params(arg: ::String, path: ::String).returns(::Spoom::ExecResult) } - def diff(*arg, path: T.unsafe(nil)); end - - # Execute a `command` - # - # source://spoom//lib/spoom/git.rb#26 - sig { params(command: ::String, arg: ::String, path: ::String).returns(::Spoom::ExecResult) } - def exec(command, *arg, path: T.unsafe(nil)); end - - # Get the last commit in the currently checked out branch - # - # source://spoom//lib/spoom/git.rb#79 - sig { params(path: ::String, short_sha: T::Boolean).returns(T.nilable(::Spoom::Git::Commit)) } - def last_commit(path: T.unsafe(nil), short_sha: T.unsafe(nil)); end - - # source://spoom//lib/spoom/git.rb#58 - sig { params(arg: ::String, path: ::String).returns(::Spoom::ExecResult) } - def log(*arg, path: T.unsafe(nil)); end - - # Parse a line formated as `%h %at` into a `Commit` - # - # source://spoom//lib/spoom/git.rb#121 - sig { params(string: ::String).returns(T.nilable(::Spoom::Git::Commit)) } - def parse_commit(string); end - - # source://spoom//lib/spoom/git.rb#63 - sig { params(arg: ::String, path: ::String).returns(::Spoom::ExecResult) } - def show(*arg, path: T.unsafe(nil)); end - - # Get the commit introducing the `sorbet/config` file - # - # source://spoom//lib/spoom/git.rb#97 - sig { params(path: ::String).returns(T.nilable(::Spoom::Git::Commit)) } - def sorbet_intro_commit(path: T.unsafe(nil)); end - - # Get the commit removing the `sorbet/config` file - # - # source://spoom//lib/spoom/git.rb#109 - sig { params(path: ::String).returns(T.nilable(::Spoom::Git::Commit)) } - def sorbet_removal_commit(path: T.unsafe(nil)); end - - # Is there uncommited changes in `path`? - # - # source://spoom//lib/spoom/git.rb#91 - sig { params(path: ::String).returns(T::Boolean) } - def workdir_clean?(path: T.unsafe(nil)); end - end -end - -# source://spoom//lib/spoom/git.rb#9 -class Spoom::Git::Commit < ::T::Struct - const :sha, ::String - const :time, ::Time - - # source://spoom//lib/spoom/git.rb#16 - sig { returns(::Integer) } - def timestamp; end - - class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# source://spoom//lib/spoom/sorbet/lsp/base.rb#5 -module Spoom::LSP; end - -# source://spoom//lib/spoom/sorbet/lsp.rb#13 -class Spoom::LSP::Client - # source://spoom//lib/spoom/sorbet/lsp.rb#17 - sig { params(sorbet_bin: ::String, sorbet_args: ::String, path: ::String).void } - def initialize(sorbet_bin, *sorbet_args, path: T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#229 - sig { void } - def close; end - - # source://spoom//lib/spoom/sorbet/lsp.rb#131 - sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T::Array[::Spoom::LSP::Location]) } - def definitions(uri, line, column); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#212 - sig { params(uri: ::String).returns(T::Array[::Spoom::LSP::DocumentSymbol]) } - def document_symbols(uri); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#89 - sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T.nilable(::Spoom::LSP::Hover)) } - def hover(uri, line, column); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#27 - sig { returns(::Integer) } - def next_id; end - - # LSP requests - # - # @raise [Error::AlreadyOpen] - # - # source://spoom//lib/spoom/sorbet/lsp.rb#72 - sig { params(workspace_path: ::String).void } - def open(workspace_path); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#54 - sig { returns(T.nilable(T::Hash[T.untyped, T.untyped])) } - def read; end - - # @raise [Error::BadHeaders] - # - # source://spoom//lib/spoom/sorbet/lsp.rb#43 - sig { returns(T.nilable(::String)) } - def read_raw; end - - # source://spoom//lib/spoom/sorbet/lsp.rb#173 - sig do - params( - uri: ::String, - line: ::Integer, - column: ::Integer, - include_decl: T::Boolean - ).returns(T::Array[::Spoom::LSP::Location]) - end - def references(uri, line, column, include_decl = T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#37 - sig { params(message: ::Spoom::LSP::Message).returns(T.nilable(T::Hash[T.untyped, T.untyped])) } - def send(message); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#32 - sig { params(json_string: ::String).void } - def send_raw(json_string); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#110 - sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T::Array[::Spoom::LSP::SignatureHelp]) } - def signatures(uri, line, column); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#197 - sig { params(query: ::String).returns(T::Array[::Spoom::LSP::DocumentSymbol]) } - def symbols(query); end - - # source://spoom//lib/spoom/sorbet/lsp.rb#152 - sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T::Array[::Spoom::LSP::Location]) } - def type_definitions(uri, line, column); end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#178 -class Spoom::LSP::Diagnostic < ::T::Struct - include ::Spoom::LSP::PrintableSymbol - - const :range, ::Spoom::LSP::Range - const :code, ::Integer - const :message, ::String - const :informations, ::Object - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#202 - sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#207 - sig { returns(::String) } - def to_s; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#191 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Diagnostic) } - def from_json(json); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#212 -class Spoom::LSP::DocumentSymbol < ::T::Struct - include ::Spoom::LSP::PrintableSymbol - - const :name, ::String - const :detail, T.nilable(::String) - const :kind, ::Integer - const :location, T.nilable(::Spoom::LSP::Location) - const :range, T.nilable(::Spoom::LSP::Range) - const :children, T::Array[::Spoom::LSP::DocumentSymbol] - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#240 - sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#272 - sig { returns(::String) } - def kind_string; end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#267 - sig { returns(::String) } - def to_s; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#227 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::DocumentSymbol) } - def from_json(json); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#276 -Spoom::LSP::DocumentSymbol::SYMBOL_KINDS = T.let(T.unsafe(nil), Hash) - -# source://spoom//lib/spoom/sorbet/lsp/errors.rb#6 -class Spoom::LSP::Error < ::StandardError; end - -# source://spoom//lib/spoom/sorbet/lsp/errors.rb#7 -class Spoom::LSP::Error::AlreadyOpen < ::Spoom::LSP::Error; end - -# source://spoom//lib/spoom/sorbet/lsp/errors.rb#8 -class Spoom::LSP::Error::BadHeaders < ::Spoom::LSP::Error; end - -# source://spoom//lib/spoom/sorbet/lsp/errors.rb#10 -class Spoom::LSP::Error::Diagnostics < ::Spoom::LSP::Error - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#32 - sig { params(uri: ::String, diagnostics: T::Array[::Spoom::LSP::Diagnostic]).void } - def initialize(uri, diagnostics); end - - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#17 - sig { returns(T::Array[::Spoom::LSP::Diagnostic]) } - def diagnostics; end - - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#14 - sig { returns(::String) } - def uri; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#23 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Error::Diagnostics) } - def from_json(json); end - end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#19 -class Spoom::LSP::Hover < ::T::Struct - include ::Spoom::LSP::PrintableSymbol - - const :contents, ::String - const :range, T.nilable(T::Range[T.untyped]) - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#39 - sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#45 - sig { returns(::String) } - def to_s; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#30 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Hover) } - def from_json(json); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#112 -class Spoom::LSP::Location < ::T::Struct - include ::Spoom::LSP::PrintableSymbol - - const :uri, ::String - const :range, ::Spoom::LSP::Range - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#132 - sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#138 - sig { returns(::String) } - def to_s; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#123 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Location) } - def from_json(json); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# A general message as defined by JSON-RPC. -# -# The language server protocol always uses `"2.0"` as the `jsonrpc` version. -# -# source://spoom//lib/spoom/sorbet/lsp/base.rb#12 -class Spoom::LSP::Message - # source://spoom//lib/spoom/sorbet/lsp/base.rb#19 - sig { void } - def initialize; end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#24 - sig { returns(T::Hash[T.untyped, T.untyped]) } - def as_json; end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#16 - sig { returns(::String) } - def jsonrpc; end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#32 - sig { params(args: T.untyped).returns(::String) } - def to_json(*args); end -end - -# A notification message. -# -# A processed notification message must not send a response back. They work like events. -# -# source://spoom//lib/spoom/sorbet/lsp/base.rb#64 -class Spoom::LSP::Notification < ::Spoom::LSP::Message - # source://spoom//lib/spoom/sorbet/lsp/base.rb#74 - sig { params(method: ::String, params: T::Hash[T.untyped, T.untyped]).void } - def initialize(method, params); end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#68 - sig { returns(::String) } - def method; end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#71 - sig { returns(T::Hash[T.untyped, T.untyped]) } - def params; end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#50 -class Spoom::LSP::Position < ::T::Struct - include ::Spoom::LSP::PrintableSymbol - - const :line, ::Integer - const :char, ::Integer - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#70 - sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#75 - sig { returns(::String) } - def to_s; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#61 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Position) } - def from_json(json); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# @abstract Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#9 -module Spoom::LSP::PrintableSymbol - interface! - - # @abstract - # - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#16 - sig { abstract.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#80 -class Spoom::LSP::Range < ::T::Struct - include ::Spoom::LSP::PrintableSymbol - - const :start, ::Spoom::LSP::Position - const :end, ::Spoom::LSP::Position - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#100 - sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#107 - sig { returns(::String) } - def to_s; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#91 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Range) } - def from_json(json); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# A request message to describe a request between the client and the server. -# -# Every processed request must send a response back to the sender of the request. -# -# source://spoom//lib/spoom/sorbet/lsp/base.rb#40 -class Spoom::LSP::Request < ::Spoom::LSP::Message - # source://spoom//lib/spoom/sorbet/lsp/base.rb#53 - sig { params(id: ::Integer, method: ::String, params: T::Hash[T.untyped, T.untyped]).void } - def initialize(id, method, params); end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#44 - sig { returns(::Integer) } - def id; end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#47 - sig { returns(::String) } - def method; end - - # source://spoom//lib/spoom/sorbet/lsp/base.rb#50 - sig { returns(T::Hash[T.untyped, T.untyped]) } - def params; end -end - -# source://spoom//lib/spoom/sorbet/lsp/errors.rb#40 -class Spoom::LSP::ResponseError < ::Spoom::LSP::Error - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#63 - sig { params(code: ::Integer, message: ::String, data: T::Hash[T.untyped, T.untyped]).void } - def initialize(code, message, data); end - - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#44 - sig { returns(::Integer) } - def code; end - - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#47 - sig { returns(T::Hash[T.untyped, T.untyped]) } - def data; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/errors.rb#53 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::ResponseError) } - def from_json(json); end - end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#143 -class Spoom::LSP::SignatureHelp < ::T::Struct - include ::Spoom::LSP::PrintableSymbol - - const :label, T.nilable(::String) - const :doc, ::Object - const :params, T::Array[T.untyped] - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#165 - sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } - def accept_printer(printer); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#173 - sig { returns(::String) } - def to_s; end - - class << self - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#155 - sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::SignatureHelp) } - def from_json(json); end - - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 - def inherited(s); end - end -end - -# source://spoom//lib/spoom/sorbet/lsp/structures.rb#306 -class Spoom::LSP::SymbolPrinter < ::Spoom::Printer - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#323 - sig do - params( - out: T.any(::IO, ::StringIO), - colors: T::Boolean, - indent_level: ::Integer, - prefix: T.nilable(::String) - ).void - end - def initialize(out: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil), prefix: T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#345 - sig { params(uri: ::String).returns(::String) } - def clean_uri(uri); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#313 - sig { returns(T.nilable(::String)) } - def prefix; end - - # @return [String, nil] - # - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#313 - def prefix=(_arg0); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#353 - sig { params(objects: T::Array[::Spoom::LSP::PrintableSymbol]).void } - def print_list(objects); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#333 - sig { params(object: T.nilable(::Spoom::LSP::PrintableSymbol)).void } - def print_object(object); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#340 - sig { params(objects: T::Array[::Spoom::LSP::PrintableSymbol]).void } - def print_objects(objects); end - - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#310 - sig { returns(T::Set[::Integer]) } - def seen; end - - # @return [Set] - # - # source://spoom//lib/spoom/sorbet/lsp/structures.rb#310 - def seen=(_arg0); end -end - -# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. -# -# source://spoom//lib/spoom/printer.rb#7 -class Spoom::Printer - include ::Spoom::Colorize - - abstract! - - # source://spoom//lib/spoom/printer.rb#19 - sig { params(out: T.any(::IO, ::StringIO), colors: T::Boolean, indent_level: ::Integer).void } - def initialize(out: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil)); end - - # Colorize `string` with color if `@colors` - # - # source://spoom//lib/spoom/printer.rb#80 - sig { params(string: ::String, color: ::Spoom::Color).returns(::String) } - def colorize(string, *color); end - - # Decrease indent level - # - # source://spoom//lib/spoom/printer.rb#33 - sig { void } - def dedent; end - - # Increase indent level - # - # source://spoom//lib/spoom/printer.rb#27 - sig { void } - def indent; end - - # source://spoom//lib/spoom/printer.rb#16 - sig { returns(T.any(::IO, ::StringIO)) } - def out; end - - # @return [IO, StringIO] - # - # source://spoom//lib/spoom/printer.rb#16 - def out=(_arg0); end - - # Print `string` into `out` - # - # source://spoom//lib/spoom/printer.rb#39 - sig { params(string: T.nilable(::String)).void } - def print(string); end - - # Print `string` colored with `color` into `out` - # - # Does not use colors unless `@colors`. - # - # source://spoom//lib/spoom/printer.rb#49 - sig { params(string: T.nilable(::String), color: ::Spoom::Color).void } - def print_colored(string, *color); end - - # Print `string` with indent and newline - # - # source://spoom//lib/spoom/printer.rb#64 - sig { params(string: T.nilable(::String)).void } - def printl(string); end - - # Print a new line into `out` - # - # source://spoom//lib/spoom/printer.rb#58 - sig { void } - def printn; end - - # Print an indent space into `out` - # - # source://spoom//lib/spoom/printer.rb#74 - sig { void } - def printt; end -end - -# source://spoom//lib/spoom.rb#10 -Spoom::SPOOM_PATH = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/config.rb#5 -module Spoom::Sorbet - class << self - # source://spoom//lib/spoom/sorbet.rb#31 - sig do - params( - arg: ::String, - path: ::String, - capture_err: T::Boolean, - sorbet_bin: T.nilable(::String) - ).returns(::Spoom::ExecResult) - end - def srb(*arg, path: T.unsafe(nil), capture_err: T.unsafe(nil), sorbet_bin: T.unsafe(nil)); end - - # List all files typechecked by Sorbet from its `config` - # - # source://spoom//lib/spoom/sorbet.rb#55 - sig { params(config: ::Spoom::Sorbet::Config, path: ::String).returns(T::Array[::String]) } - def srb_files(config, path: T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet.rb#93 - sig do - params( - arg: ::String, - path: ::String, - capture_err: T::Boolean, - sorbet_bin: T.nilable(::String) - ).returns(T.nilable(T::Hash[::String, ::Integer])) - end - def srb_metrics(*arg, path: T.unsafe(nil), capture_err: T.unsafe(nil), sorbet_bin: T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet.rb#48 - sig do - params( - arg: ::String, - path: ::String, - capture_err: T::Boolean, - sorbet_bin: T.nilable(::String) - ).returns(::Spoom::ExecResult) - end - def srb_tc(*arg, path: T.unsafe(nil), capture_err: T.unsafe(nil), sorbet_bin: T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet.rb#71 - sig do - params( - arg: ::String, - path: ::String, - capture_err: T::Boolean, - sorbet_bin: T.nilable(::String) - ).returns(T.nilable(::String)) - end - def srb_version(*arg, path: T.unsafe(nil), capture_err: T.unsafe(nil), sorbet_bin: T.unsafe(nil)); end - - # Get `gem` version from the `Gemfile.lock` content - # - # Returns `nil` if `gem` cannot be found in the Gemfile. - # - # source://spoom//lib/spoom/sorbet.rb#116 - sig { params(gem: ::String, path: ::String).returns(T.nilable(::String)) } - def version_from_gemfile_lock(gem: T.unsafe(nil), path: T.unsafe(nil)); end - end -end - -# source://spoom//lib/spoom/sorbet.rb#16 -Spoom::Sorbet::BIN_PATH = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet.rb#14 -Spoom::Sorbet::CONFIG_PATH = T.let(T.unsafe(nil), String) - -# Parse Sorbet config files -# -# Parses a Sorbet config file: -# -# ```ruby -# config = Spoom::Sorbet::Config.parse_file("sorbet/config") -# puts config.paths # "." -# ``` -# -# Parses a Sorbet config string: -# -# ```ruby -# config = Spoom::Sorbet::Config.parse_string(<<~CONFIG) -# a -# --file=b -# --ignore=c -# CONFIG -# puts config.paths # "a", "b" -# puts config.ignore # "c" -# ``` -# -# source://spoom//lib/spoom/sorbet/config.rb#26 -class Spoom::Sorbet::Config - # source://spoom//lib/spoom/sorbet/config.rb#36 - sig { void } - def initialize; end - - # @return [Array] - # - # source://spoom//lib/spoom/sorbet/config.rb#30 - def allowed_extensions; end - - # source://spoom//lib/spoom/sorbet/config.rb#44 - sig { returns(::Spoom::Sorbet::Config) } - def copy; end - - # @return [Array] - # - # source://spoom//lib/spoom/sorbet/config.rb#30 - def ignore; end - - # source://spoom//lib/spoom/sorbet/config.rb#33 - sig { returns(T::Boolean) } - def no_stdlib; end - - # @return [Boolean] - # - # source://spoom//lib/spoom/sorbet/config.rb#33 - def no_stdlib=(_arg0); end - - # Returns self as a string of options that can be passed to Sorbet - # - # Example: - # ~~~rb - # config = Sorbet::Config.new - # config.paths << "/foo" - # config.paths << "/bar" - # config.ignore << "/baz" - # config.allowed_extensions << ".rb" - # - # puts config.options_string # "/foo /bar --ignore /baz --allowed-extension .rb" - # ~~~ - # - # source://spoom//lib/spoom/sorbet/config.rb#66 - sig { returns(::String) } - def options_string; end - - # source://spoom//lib/spoom/sorbet/config.rb#30 - sig { returns(T::Array[::String]) } - def paths; end - - class << self - # source://spoom//lib/spoom/sorbet/config.rb#79 - sig { params(sorbet_config_path: ::String).returns(::Spoom::Sorbet::Config) } - def parse_file(sorbet_config_path); end - - # source://spoom//lib/spoom/sorbet/config.rb#84 - sig { params(sorbet_config: ::String).returns(::Spoom::Sorbet::Config) } - def parse_string(sorbet_config); end - - private - - # source://spoom//lib/spoom/sorbet/config.rb#148 - sig { params(line: ::String).returns(::String) } - def parse_option(line); end - end -end - -# source://spoom//lib/spoom/sorbet/errors.rb#6 -module Spoom::Sorbet::Errors - class << self - # source://spoom//lib/spoom/sorbet/errors.rb#13 - sig { params(errors: T::Array[::Spoom::Sorbet::Errors::Error]).returns(T::Array[::Spoom::Sorbet::Errors::Error]) } - def sort_errors_by_code(errors); end - end -end - -# source://spoom//lib/spoom/sorbet/errors.rb#7 -Spoom::Sorbet::Errors::DEFAULT_ERROR_URL_BASE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/errors.rb#122 -class Spoom::Sorbet::Errors::Error - include ::Comparable - - # source://spoom//lib/spoom/sorbet/errors.rb#148 - sig do - params( - file: T.nilable(::String), - line: T.nilable(::Integer), - message: T.nilable(::String), - code: T.nilable(::Integer), - more: T::Array[::String] - ).void - end - def initialize(file, line, message, code, more = T.unsafe(nil)); end - - # By default errors are sorted by location - # - # source://spoom//lib/spoom/sorbet/errors.rb#159 - sig { params(other: T.untyped).returns(::Integer) } - def <=>(other); end - - # @return [Integer, nil] - # - # source://spoom//lib/spoom/sorbet/errors.rb#130 - def code; end - - # source://spoom//lib/spoom/sorbet/errors.rb#127 - sig { returns(T.nilable(::String)) } - def file; end - - # Other files associated with the error - # - # source://spoom//lib/spoom/sorbet/errors.rb#137 - sig { returns(T::Set[::String]) } - def files_from_error_sections; end - - # source://spoom//lib/spoom/sorbet/errors.rb#130 - sig { returns(T.nilable(::Integer)) } - def line; end - - # @return [String, nil] - # - # source://spoom//lib/spoom/sorbet/errors.rb#127 - def message; end - - # source://spoom//lib/spoom/sorbet/errors.rb#133 - sig { returns(T::Array[::String]) } - def more; end - - # source://spoom//lib/spoom/sorbet/errors.rb#166 - sig { returns(::String) } - def to_s; end -end - -# Parse errors from Sorbet output -# -# source://spoom//lib/spoom/sorbet/errors.rb#18 -class Spoom::Sorbet::Errors::Parser - # source://spoom//lib/spoom/sorbet/errors.rb#40 - sig { params(error_url_base: ::String).void } - def initialize(error_url_base: T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet/errors.rb#47 - sig { params(output: ::String).returns(T::Array[::Spoom::Sorbet::Errors::Error]) } - def parse(output); end - - private - - # source://spoom//lib/spoom/sorbet/errors.rb#111 - sig { params(line: ::String).void } - def append_error(line); end - - # source://spoom//lib/spoom/sorbet/errors.rb#103 - sig { void } - def close_error; end - - # source://spoom//lib/spoom/sorbet/errors.rb#70 - sig { params(error_url_base: ::String).returns(::Regexp) } - def error_line_match_regexp(error_url_base); end - - # source://spoom//lib/spoom/sorbet/errors.rb#87 - sig { params(line: ::String).returns(T.nilable(::Spoom::Sorbet::Errors::Error)) } - def match_error_line(line); end - - # source://spoom//lib/spoom/sorbet/errors.rb#96 - sig { params(error: ::Spoom::Sorbet::Errors::Error).void } - def open_error(error); end - - class << self - # source://spoom//lib/spoom/sorbet/errors.rb#33 - sig { params(output: ::String, error_url_base: ::String).returns(T::Array[::Spoom::Sorbet::Errors::Error]) } - def parse_string(output, error_url_base: T.unsafe(nil)); end - end -end - -# source://spoom//lib/spoom/sorbet/errors.rb#21 -Spoom::Sorbet::Errors::Parser::HEADER = T.let(T.unsafe(nil), Array) - -# source://spoom//lib/spoom/sorbet.rb#15 -Spoom::Sorbet::GEM_PATH = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/metrics.rb#8 -module Spoom::Sorbet::MetricsParser - class << self - # source://spoom//lib/spoom/sorbet/metrics.rb#15 - sig { params(path: ::String, prefix: ::String).returns(T::Hash[::String, ::Integer]) } - def parse_file(path, prefix = T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet/metrics.rb#25 - sig { params(obj: T::Hash[::String, T.untyped], prefix: ::String).returns(T::Hash[::String, ::Integer]) } - def parse_hash(obj, prefix = T.unsafe(nil)); end - - # source://spoom//lib/spoom/sorbet/metrics.rb#20 - sig { params(string: ::String, prefix: ::String).returns(T::Hash[::String, ::Integer]) } - def parse_string(string, prefix = T.unsafe(nil)); end - end -end - -# source://spoom//lib/spoom/sorbet/metrics.rb#9 -Spoom::Sorbet::MetricsParser::DEFAULT_PREFIX = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet.rb#18 -Spoom::Sorbet::SEGFAULT_CODE = T.let(T.unsafe(nil), Integer) - -# source://spoom//lib/spoom/sorbet/sigils.rb#9 -module Spoom::Sorbet::Sigils - class << self - # changes the sigil in the file at the passed path to the specified new strictness - # - # source://spoom//lib/spoom/sorbet/sigils.rb#69 - sig { params(path: T.any(::Pathname, ::String), new_strictness: ::String).returns(T::Boolean) } - def change_sigil_in_file(path, new_strictness); end - - # changes the sigil to have a new strictness in a list of files - # - # source://spoom//lib/spoom/sorbet/sigils.rb#80 - sig { params(path_list: T::Array[::String], new_strictness: ::String).returns(T::Array[::String]) } - def change_sigil_in_files(path_list, new_strictness); end - - # returns a string containing the strictness of a sigil in a file at the passed path - # * returns nil if no sigil - # - # source://spoom//lib/spoom/sorbet/sigils.rb#60 - sig { params(path: T.any(::Pathname, ::String)).returns(T.nilable(::String)) } - def file_strictness(path); end - - # finds all files in the specified directory with the passed strictness - # - # source://spoom//lib/spoom/sorbet/sigils.rb#94 - sig do - params( - directory: T.any(::Pathname, ::String), - strictness: ::String, - extension: ::String - ).returns(T::Array[::String]) - end - def files_with_sigil_strictness(directory, strictness, extension: T.unsafe(nil)); end - - # returns the full sigil comment string for the passed strictness - # - # source://spoom//lib/spoom/sorbet/sigils.rb#35 - sig { params(strictness: ::String).returns(::String) } - def sigil_string(strictness); end - - # returns the strictness of a sigil in the passed file content string (nil if no sigil) - # - # source://spoom//lib/spoom/sorbet/sigils.rb#47 - sig { params(content: ::String).returns(T.nilable(::String)) } - def strictness_in_content(content); end - - # returns a string which is the passed content but with the sigil updated to a new strictness - # - # source://spoom//lib/spoom/sorbet/sigils.rb#53 - sig { params(content: ::String, new_strictness: ::String).returns(::String) } - def update_sigil(content, new_strictness); end - - # returns true if the passed string is a valid strictness (else false) - # - # source://spoom//lib/spoom/sorbet/sigils.rb#41 - sig { params(strictness: ::String).returns(T::Boolean) } - def valid_strictness?(strictness); end - end -end - -# source://spoom//lib/spoom/sorbet/sigils.rb#28 -Spoom::Sorbet::Sigils::SIGIL_REGEXP = T.let(T.unsafe(nil), Regexp) - -# source://spoom//lib/spoom/sorbet/sigils.rb#13 -Spoom::Sorbet::Sigils::STRICTNESS_FALSE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/sigils.rb#12 -Spoom::Sorbet::Sigils::STRICTNESS_IGNORE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/sigils.rb#17 -Spoom::Sorbet::Sigils::STRICTNESS_INTERNAL = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/sigils.rb#15 -Spoom::Sorbet::Sigils::STRICTNESS_STRICT = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/sigils.rb#16 -Spoom::Sorbet::Sigils::STRICTNESS_STRONG = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/sigils.rb#14 -Spoom::Sorbet::Sigils::STRICTNESS_TRUE = T.let(T.unsafe(nil), String) - -# source://spoom//lib/spoom/sorbet/sigils.rb#19 -Spoom::Sorbet::Sigils::VALID_STRICTNESS = T.let(T.unsafe(nil), Array) - -# source://spoom//lib/spoom/timeline.rb#7 -class Spoom::Timeline - # source://spoom//lib/spoom/timeline.rb#11 - sig { params(from: ::Time, to: ::Time, path: ::String).void } - def initialize(from, to, path: T.unsafe(nil)); end - - # Return one commit for each date in `dates` - # - # source://spoom//lib/spoom/timeline.rb#38 - sig { params(dates: T::Array[::Time]).returns(T::Array[::Spoom::Git::Commit]) } - def commits_for_dates(dates); end - - # Return all months between `from` and `to` - # - # source://spoom//lib/spoom/timeline.rb#25 - sig { returns(T::Array[::Time]) } - def months; end - - # Return one commit for each month between `from` and `to` - # - # source://spoom//lib/spoom/timeline.rb#19 - sig { returns(T::Array[::Spoom::Git::Commit]) } - def ticks; end -end - -# source://spoom//lib/spoom/version.rb#5 -Spoom::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/spoom@1.4.2.rbi b/sorbet/rbi/gems/spoom@1.4.2.rbi new file mode 100644 index 000000000..851872bd6 --- /dev/null +++ b/sorbet/rbi/gems/spoom@1.4.2.rbi @@ -0,0 +1,4932 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `spoom` gem. +# Please instead update this file by running `bin/tapioca gem spoom`. + + +# source://spoom//lib/spoom.rb#7 +module Spoom + class << self + # source://spoom//lib/spoom/parse.rb#13 + sig { params(ruby: ::String, file: ::String).returns(::Prism::Node) } + def parse_ruby(ruby, file:); end + end +end + +# source://spoom//lib/spoom/cli/helper.rb#9 +module Spoom::Cli; end + +# source://spoom//lib/spoom/cli/deadcode.rb#8 +class Spoom::Cli::Deadcode < ::Thor + include ::Spoom::Colorize + include ::Spoom::Cli::Helper + + # source://spoom//lib/spoom/cli/deadcode.rb#52 + sig { params(paths: ::String).void } + def deadcode(*paths); end + + def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli/deadcode.rb#154 + def remove(location_string); end +end + +# source://spoom//lib/spoom/cli/helper.rb#10 +module Spoom::Cli::Helper + include ::Spoom::Colorize + + requires_ancestor { Thor } + + # source://spoom//lib/spoom/cli/helper.rb#139 + sig { params(string: ::String).returns(::String) } + def blue(string); end + + # Is the `--color` option true? + # + # source://spoom//lib/spoom/cli/helper.rb#103 + sig { returns(T::Boolean) } + def color?; end + + # Colorize a string if `color?` + # + # source://spoom//lib/spoom/cli/helper.rb#132 + sig { params(string: ::String, color: ::Spoom::Color).returns(::String) } + def colorize(string, *color); end + + # Returns the context at `--path` (by default the current working directory) + # + # source://spoom//lib/spoom/cli/helper.rb#71 + sig { returns(::Spoom::Context) } + def context; end + + # Raise if `spoom` is not ran inside a context with a `sorbet/config` file + # + # source://spoom//lib/spoom/cli/helper.rb#77 + sig { returns(::Spoom::Context) } + def context_requiring_sorbet!; end + + # source://spoom//lib/spoom/cli/helper.rb#144 + sig { params(string: ::String).returns(::String) } + def cyan(string); end + + # Return the path specified through `--path` + # + # source://spoom//lib/spoom/cli/helper.rb#92 + sig { returns(::String) } + def exec_path; end + + # source://spoom//lib/spoom/cli/helper.rb#149 + sig { params(string: ::String).returns(::String) } + def gray(string); end + + # source://spoom//lib/spoom/cli/helper.rb#154 + sig { params(string: ::String).returns(::String) } + def green(string); end + + # source://spoom//lib/spoom/cli/helper.rb#108 + sig { params(string: ::String).returns(::String) } + def highlight(string); end + + # source://spoom//lib/spoom/cli/helper.rb#159 + sig { params(string: ::String).returns(::String) } + def red(string); end + + # Print `message` on `$stdout` + # + # source://spoom//lib/spoom/cli/helper.rb#20 + sig { params(message: ::String).void } + def say(message); end + + # Print `message` on `$stderr` + # + # The message is prefixed by a status (default: `Error`). + # + # source://spoom//lib/spoom/cli/helper.rb#39 + sig { params(message: ::String, status: T.nilable(::String), nl: T::Boolean).void } + def say_error(message, status: T.unsafe(nil), nl: T.unsafe(nil)); end + + # Print `message` on `$stderr` + # + # The message is prefixed by a status (default: `Warning`). + # + # source://spoom//lib/spoom/cli/helper.rb#59 + sig { params(message: ::String, status: T.nilable(::String), nl: T::Boolean).void } + def say_warning(message, status: T.unsafe(nil), nl: T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli/helper.rb#164 + sig { params(string: ::String).returns(::String) } + def yellow(string); end +end + +# source://spoom//lib/spoom/cli.rb#12 +class Spoom::Cli::Main < ::Thor + include ::Spoom::Colorize + include ::Spoom::Cli::Helper + + # source://spoom//lib/spoom/cli.rb#101 + def __print_version; end + + # source://spoom//lib/spoom/cli.rb#58 + sig { params(directory: ::String).void } + def bump(directory = T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli.rb#65 + def coverage(*args); end + + # source://thor/1.3.1/lib/thor.rb#334 + def deadcode(*args); end + + # source://spoom//lib/spoom/cli.rb#75 + def lsp(*args); end + + # source://thor/1.3.1/lib/thor.rb#334 + def srb(*args); end + + # source://spoom//lib/spoom/cli.rb#94 + def tc(*paths_to_select); end + + class << self + # @return [Boolean] + # + # source://spoom//lib/spoom/cli.rb#108 + def exit_on_failure?; end + end +end + +# source://spoom//lib/spoom/cli.rb#81 +Spoom::Cli::Main::SORT_CODE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/cli.rb#83 +Spoom::Cli::Main::SORT_ENUM = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/cli.rb#82 +Spoom::Cli::Main::SORT_LOC = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/cli/srb/bump.rb#9 +module Spoom::Cli::Srb; end + +# source://spoom//lib/spoom/cli/srb/bump.rb#10 +class Spoom::Cli::Srb::Bump < ::Thor + include ::Spoom::Colorize + include ::Spoom::Cli::Helper + + # source://spoom//lib/spoom/cli/srb/bump.rb#50 + sig { params(directory: ::String).void } + def bump(directory = T.unsafe(nil)); end + + def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli/srb/bump.rb#171 + def print_changes(files, command:, from: T.unsafe(nil), to: T.unsafe(nil), dry: T.unsafe(nil), path: T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli/srb/bump.rb#193 + def undo_changes(files, from_strictness); end +end + +# source://spoom//lib/spoom/cli/srb/coverage.rb#10 +class Spoom::Cli::Srb::Coverage < ::Thor + include ::Spoom::Colorize + include ::Spoom::Cli::Helper + + # source://spoom//lib/spoom/cli/srb/coverage.rb#199 + def bundle_install(path, sha); end + + def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli/srb/coverage.rb#211 + def message_no_data(file); end + + # source://spoom//lib/spoom/cli/srb/coverage.rb#174 + def open(file = T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli/srb/coverage.rb#190 + def parse_time(string, option); end + + # source://spoom//lib/spoom/cli/srb/coverage.rb#143 + def report; end + + # source://spoom//lib/spoom/cli/srb/coverage.rb#21 + def snapshot; end + + # source://spoom//lib/spoom/cli/srb/coverage.rb#43 + def timeline; end +end + +# source://spoom//lib/spoom/cli/srb/coverage.rb#13 +Spoom::Cli::Srb::Coverage::DATA_DIR = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/cli/srb/lsp.rb#11 +class Spoom::Cli::Srb::LSP < ::Thor + include ::Spoom::Colorize + include ::Spoom::Cli::Helper + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#45 + def defs(file, line, col); end + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#55 + def find(query); end + + def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#31 + def hover(file, line, col); end + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#16 + def list; end + + # source://spoom//lib/spoom/cli/srb/lsp.rb#104 + def lsp_client; end + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#75 + def refs(file, line, col); end + + # source://spoom//lib/spoom/cli/srb/lsp.rb#127 + def run(&block); end + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#85 + def sigs(file, line, col); end + + # source://spoom//lib/spoom/cli/srb/lsp.rb#119 + def symbol_printer; end + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#65 + def symbols(file); end + + # source://spoom//lib/spoom/cli/srb/lsp.rb#152 + def to_uri(path); end + + # TODO: options, filter, limit, kind etc.. filter rbi + # + # source://spoom//lib/spoom/cli/srb/lsp.rb#95 + def types(file, line, col); end +end + +# source://spoom//lib/spoom/cli/srb.rb#12 +class Spoom::Cli::Srb::Main < ::Thor + # source://thor/1.3.1/lib/thor.rb#334 + def bump(*args); end + + # source://thor/1.3.1/lib/thor.rb#334 + def coverage(*args); end + + def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end + + # source://thor/1.3.1/lib/thor.rb#334 + def lsp(*args); end + + # source://thor/1.3.1/lib/thor.rb#334 + def tc(*args); end +end + +# source://spoom//lib/spoom/cli/srb/tc.rb#7 +class Spoom::Cli::Srb::Tc < ::Thor + include ::Spoom::Colorize + include ::Spoom::Cli::Helper + + # source://spoom//lib/spoom/cli/srb/tc.rb#132 + def colorize_message(message); end + + # source://spoom//lib/spoom/cli/srb/tc.rb#123 + def format_error(error, format); end + + def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end + + # source://spoom//lib/spoom/cli/srb/tc.rb#27 + def tc(*paths_to_select); end +end + +# source://spoom//lib/spoom/cli/srb/tc.rb#16 +Spoom::Cli::Srb::Tc::DEFAULT_FORMAT = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/cli/srb/tc.rb#12 +Spoom::Cli::Srb::Tc::SORT_CODE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/cli/srb/tc.rb#14 +Spoom::Cli::Srb::Tc::SORT_ENUM = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/cli/srb/tc.rb#13 +Spoom::Cli::Srb::Tc::SORT_LOC = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/colors.rb#5 +class Spoom::Color < ::T::Enum + enums do + CLEAR = new + BOLD = new + BLACK = new + RED = new + GREEN = new + YELLOW = new + BLUE = new + MAGENTA = new + CYAN = new + WHITE = new + LIGHT_BLACK = new + LIGHT_RED = new + LIGHT_GREEN = new + LIGHT_YELLOW = new + LIGHT_BLUE = new + LIGHT_MAGENTA = new + LIGHT_CYAN = new + LIGHT_WHITE = new + end + + # source://spoom//lib/spoom/colors.rb#32 + sig { returns(::String) } + def ansi_code; end +end + +# source://spoom//lib/spoom/colors.rb#37 +module Spoom::Colorize + # source://spoom//lib/spoom/colors.rb#41 + sig { params(string: ::String, color: ::Spoom::Color).returns(::String) } + def set_color(string, *color); end +end + +# An abstraction to a Ruby project context +# +# A context maps to a directory in the file system. +# It is used to manipulate files and run commands in the context of this directory. +# +# source://spoom//lib/spoom/context/bundle.rb#5 +class Spoom::Context + include ::Spoom::Context::Bundle + include ::Spoom::Context::Exec + include ::Spoom::Context::FileSystem + include ::Spoom::Context::Git + include ::Spoom::Context::Sorbet + + # Create a new context about `absolute_path` + # + # The directory will not be created if it doesn't exist. + # Call `#make!` to create it. + # + # source://spoom//lib/spoom/context.rb#51 + sig { params(absolute_path: ::String).void } + def initialize(absolute_path); end + + # The absolute path to the directory this context is about + # + # source://spoom//lib/spoom/context.rb#44 + sig { returns(::String) } + def absolute_path; end + + class << self + # Create a new context in the system's temporary directory + # + # `name` is used as prefix to the temporary directory name. + # The directory will be created if it doesn't exist. + # + # source://spoom//lib/spoom/context.rb#37 + sig { params(name: T.nilable(::String)).returns(T.attached_class) } + def mktmp!(name = T.unsafe(nil)); end + end +end + +# Bundle features for a context +# +# source://spoom//lib/spoom/context/bundle.rb#7 +module Spoom::Context::Bundle + requires_ancestor { Spoom::Context } + + # Run a command with `bundle` in this context directory + # + # source://spoom//lib/spoom/context/bundle.rb#33 + sig { params(command: ::String, version: T.nilable(::String), capture_err: T::Boolean).returns(::Spoom::ExecResult) } + def bundle(command, version: T.unsafe(nil), capture_err: T.unsafe(nil)); end + + # Run a command `bundle exec` in this context directory + # + # source://spoom//lib/spoom/context/bundle.rb#46 + sig { params(command: ::String, version: T.nilable(::String), capture_err: T::Boolean).returns(::Spoom::ExecResult) } + def bundle_exec(command, version: T.unsafe(nil), capture_err: T.unsafe(nil)); end + + # Run `bundle install` in this context directory + # + # source://spoom//lib/spoom/context/bundle.rb#40 + sig { params(version: T.nilable(::String), capture_err: T::Boolean).returns(::Spoom::ExecResult) } + def bundle_install!(version: T.unsafe(nil), capture_err: T.unsafe(nil)); end + + # Get `gem` version from the `Gemfile.lock` content + # + # Returns `nil` if `gem` cannot be found in the Gemfile. + # + # source://spoom//lib/spoom/context/bundle.rb#62 + sig { params(gem: ::String).returns(T.nilable(::String)) } + def gem_version_from_gemfile_lock(gem); end + + # source://spoom//lib/spoom/context/bundle.rb#51 + sig { returns(T::Hash[::String, ::Bundler::LazySpecification]) } + def gemfile_lock_specs; end + + # Read the contents of the Gemfile in this context directory + # + # source://spoom//lib/spoom/context/bundle.rb#15 + sig { returns(T.nilable(::String)) } + def read_gemfile; end + + # Read the contents of the Gemfile.lock in this context directory + # + # source://spoom//lib/spoom/context/bundle.rb#21 + sig { returns(T.nilable(::String)) } + def read_gemfile_lock; end + + # Set the `contents` of the Gemfile in this context directory + # + # source://spoom//lib/spoom/context/bundle.rb#27 + sig { params(contents: ::String, append: T::Boolean).void } + def write_gemfile!(contents, append: T.unsafe(nil)); end +end + +# Execution features for a context +# +# source://spoom//lib/spoom/context/exec.rb#27 +module Spoom::Context::Exec + requires_ancestor { Spoom::Context } + + # Run a command in this context directory + # + # source://spoom//lib/spoom/context/exec.rb#35 + sig { params(command: ::String, capture_err: T::Boolean).returns(::Spoom::ExecResult) } + def exec(command, capture_err: T.unsafe(nil)); end +end + +# File System features for a context +# +# source://spoom//lib/spoom/context/file_system.rb#7 +module Spoom::Context::FileSystem + requires_ancestor { Spoom::Context } + + # Returns the absolute path to `relative_path` in the context's directory + # + # source://spoom//lib/spoom/context/file_system.rb#15 + sig { params(relative_path: ::String).returns(::String) } + def absolute_path_to(relative_path); end + + # source://spoom//lib/spoom/context/file_system.rb#53 + sig do + params( + allow_extensions: T::Array[::String], + allow_mime_types: T::Array[::String], + exclude_patterns: T::Array[::String] + ).returns(T::Array[::String]) + end + def collect_files(allow_extensions: T.unsafe(nil), allow_mime_types: T.unsafe(nil), exclude_patterns: T.unsafe(nil)); end + + # Delete this context and its content + # + # Warning: it will `rm -rf` the context directory on the file system. + # + # source://spoom//lib/spoom/context/file_system.rb#105 + sig { void } + def destroy!; end + + # Does the context directory at `absolute_path` exist and is a directory? + # + # source://spoom//lib/spoom/context/file_system.rb#21 + sig { returns(T::Boolean) } + def exist?; end + + # Does `relative_path` point to an existing file in this context directory? + # + # source://spoom//lib/spoom/context/file_system.rb#65 + sig { params(relative_path: ::String).returns(T::Boolean) } + def file?(relative_path); end + + # List all files in this context matching `pattern` + # + # source://spoom//lib/spoom/context/file_system.rb#34 + sig { params(pattern: ::String).returns(T::Array[::String]) } + def glob(pattern = T.unsafe(nil)); end + + # List all files at the top level of this context directory + # + # source://spoom//lib/spoom/context/file_system.rb#42 + sig { returns(T::Array[::String]) } + def list; end + + # Create the context directory at `absolute_path` + # + # source://spoom//lib/spoom/context/file_system.rb#27 + sig { void } + def mkdir!; end + + # Move the file or directory from `from_relative_path` to `to_relative_path` + # + # source://spoom//lib/spoom/context/file_system.rb#95 + sig { params(from_relative_path: ::String, to_relative_path: ::String).void } + def move!(from_relative_path, to_relative_path); end + + # Return the contents of the file at `relative_path` in this context directory + # + # Will raise if the file doesn't exist. + # + # source://spoom//lib/spoom/context/file_system.rb#73 + sig { params(relative_path: ::String).returns(::String) } + def read(relative_path); end + + # Remove the path at `relative_path` (recursive + force) in this context directory + # + # source://spoom//lib/spoom/context/file_system.rb#89 + sig { params(relative_path: ::String).void } + def remove!(relative_path); end + + # Write `contents` in the file at `relative_path` in this context directory + # + # Append to the file if `append` is true. + # + # source://spoom//lib/spoom/context/file_system.rb#81 + sig { params(relative_path: ::String, contents: ::String, append: T::Boolean).void } + def write!(relative_path, contents = T.unsafe(nil), append: T.unsafe(nil)); end +end + +# Git features for a context +# +# source://spoom//lib/spoom/context/git.rb#35 +module Spoom::Context::Git + requires_ancestor { Spoom::Context } + + # Run a command prefixed by `git` in this context directory + # + # source://spoom//lib/spoom/context/git.rb#43 + sig { params(command: ::String).returns(::Spoom::ExecResult) } + def git(command); end + + # Run `git checkout` in this context directory + # + # source://spoom//lib/spoom/context/git.rb#62 + sig { params(ref: ::String).returns(::Spoom::ExecResult) } + def git_checkout!(ref: T.unsafe(nil)); end + + # Run `git checkout -b ` in this context directory + # + # source://spoom//lib/spoom/context/git.rb#68 + sig { params(branch_name: ::String, ref: T.nilable(::String)).returns(::Spoom::ExecResult) } + def git_checkout_new_branch!(branch_name, ref: T.unsafe(nil)); end + + # Run `git add . && git commit` in this context directory + # + # source://spoom//lib/spoom/context/git.rb#78 + sig { params(message: ::String, time: ::Time, allow_empty: T::Boolean).returns(::Spoom::ExecResult) } + def git_commit!(message: T.unsafe(nil), time: T.unsafe(nil), allow_empty: T.unsafe(nil)); end + + # Get the current git branch in this context directory + # + # source://spoom//lib/spoom/context/git.rb#89 + sig { returns(T.nilable(::String)) } + def git_current_branch; end + + # Run `git diff` in this context directory + # + # source://spoom//lib/spoom/context/git.rb#98 + sig { params(arg: ::String).returns(::Spoom::ExecResult) } + def git_diff(*arg); end + + # Run `git init` in this context directory + # + # Warning: passing a branch will run `git init -b ` which is only available in git 2.28+. + # In older versions, use `git_init!` followed by `git("checkout -b ")`. + # + # source://spoom//lib/spoom/context/git.rb#52 + sig { params(branch: T.nilable(::String)).returns(::Spoom::ExecResult) } + def git_init!(branch: T.unsafe(nil)); end + + # Get the last commit in the currently checked out branch + # + # source://spoom//lib/spoom/context/git.rb#104 + sig { params(short_sha: T::Boolean).returns(T.nilable(::Spoom::Git::Commit)) } + def git_last_commit(short_sha: T.unsafe(nil)); end + + # source://spoom//lib/spoom/context/git.rb#115 + sig { params(arg: ::String).returns(::Spoom::ExecResult) } + def git_log(*arg); end + + # Run `git push ` in this context directory + # + # source://spoom//lib/spoom/context/git.rb#121 + sig { params(remote: ::String, ref: ::String, force: T::Boolean).returns(::Spoom::ExecResult) } + def git_push!(remote, ref, force: T.unsafe(nil)); end + + # source://spoom//lib/spoom/context/git.rb#126 + sig { params(arg: ::String).returns(::Spoom::ExecResult) } + def git_show(*arg); end + + # Is there uncommitted changes in this context directory? + # + # source://spoom//lib/spoom/context/git.rb#132 + sig { params(path: ::String).returns(T::Boolean) } + def git_workdir_clean?(path: T.unsafe(nil)); end +end + +# Sorbet features for a context +# +# source://spoom//lib/spoom/context/sorbet.rb#7 +module Spoom::Context::Sorbet + requires_ancestor { Spoom::Context } + + # Does this context has a `sorbet/config` file? + # + # source://spoom//lib/spoom/context/sorbet.rb#119 + sig { returns(T::Boolean) } + def has_sorbet_config?; end + + # Read the strictness sigil from the file at `relative_path` (returns `nil` if no sigil) + # + # source://spoom//lib/spoom/context/sorbet.rb#142 + sig { params(relative_path: ::String).returns(T.nilable(::String)) } + def read_file_strictness(relative_path); end + + # Read the contents of `sorbet/config` in this context directory + # + # source://spoom//lib/spoom/context/sorbet.rb#130 + sig { returns(::String) } + def read_sorbet_config; end + + # source://spoom//lib/spoom/context/sorbet.rb#124 + sig { returns(::Spoom::Sorbet::Config) } + def sorbet_config; end + + # Get the commit introducing the `sorbet/config` file + # + # source://spoom//lib/spoom/context/sorbet.rb#148 + sig { returns(T.nilable(::Spoom::Git::Commit)) } + def sorbet_intro_commit; end + + # Get the commit removing the `sorbet/config` file + # + # source://spoom//lib/spoom/context/sorbet.rb#160 + sig { returns(T.nilable(::Spoom::Git::Commit)) } + def sorbet_removal_commit; end + + # Run `bundle exec srb` in this context directory + # + # source://spoom//lib/spoom/context/sorbet.rb#15 + sig { params(arg: ::String, sorbet_bin: T.nilable(::String), capture_err: T::Boolean).returns(::Spoom::ExecResult) } + def srb(*arg, sorbet_bin: T.unsafe(nil), capture_err: T.unsafe(nil)); end + + # List all files typechecked by Sorbet from its `config` + # + # source://spoom//lib/spoom/context/sorbet.rb#65 + sig { params(with_config: T.nilable(::Spoom::Sorbet::Config), include_rbis: T::Boolean).returns(T::Array[::String]) } + def srb_files(with_config: T.unsafe(nil), include_rbis: T.unsafe(nil)); end + + # List all files typechecked by Sorbet from its `config` that matches `strictness` + # + # source://spoom//lib/spoom/context/sorbet.rb#104 + sig do + params( + strictness: ::String, + with_config: T.nilable(::Spoom::Sorbet::Config), + include_rbis: T::Boolean + ).returns(T::Array[::String]) + end + def srb_files_with_strictness(strictness, with_config: T.unsafe(nil), include_rbis: T.unsafe(nil)); end + + # source://spoom//lib/spoom/context/sorbet.rb#45 + sig do + params( + arg: ::String, + sorbet_bin: T.nilable(::String), + capture_err: T::Boolean + ).returns(T.nilable(T::Hash[::String, ::Integer])) + end + def srb_metrics(*arg, sorbet_bin: T.unsafe(nil), capture_err: T.unsafe(nil)); end + + # source://spoom//lib/spoom/context/sorbet.rb#33 + sig { params(arg: ::String, sorbet_bin: T.nilable(::String), capture_err: T::Boolean).returns(::Spoom::ExecResult) } + def srb_tc(*arg, sorbet_bin: T.unsafe(nil), capture_err: T.unsafe(nil)); end + + # source://spoom//lib/spoom/context/sorbet.rb#110 + sig { params(arg: ::String, sorbet_bin: T.nilable(::String), capture_err: T::Boolean).returns(T.nilable(::String)) } + def srb_version(*arg, sorbet_bin: T.unsafe(nil), capture_err: T.unsafe(nil)); end + + # Set the `contents` of `sorbet/config` in this context directory + # + # source://spoom//lib/spoom/context/sorbet.rb#136 + sig { params(contents: ::String, append: T::Boolean).void } + def write_sorbet_config!(contents, append: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/snapshot.rb#5 +module Spoom::Coverage + class << self + # source://spoom//lib/spoom/coverage.rb#103 + sig { params(context: ::Spoom::Context).returns(::Spoom::FileTree) } + def file_tree(context); end + + # source://spoom//lib/spoom/coverage.rb#83 + sig do + params( + context: ::Spoom::Context, + snapshots: T::Array[::Spoom::Coverage::Snapshot], + palette: ::Spoom::Coverage::D3::ColorPalette + ).returns(::Spoom::Coverage::Report) + end + def report(context, snapshots, palette:); end + + # source://spoom//lib/spoom/coverage.rb#16 + sig do + params( + context: ::Spoom::Context, + rbi: T::Boolean, + sorbet_bin: T.nilable(::String) + ).returns(::Spoom::Coverage::Snapshot) + end + def snapshot(context, rbi: T.unsafe(nil), sorbet_bin: T.unsafe(nil)); end + end +end + +# source://spoom//lib/spoom/coverage/report.rb#88 +module Spoom::Coverage::Cards; end + +# source://spoom//lib/spoom/coverage/report.rb#89 +class Spoom::Coverage::Cards::Card < ::Spoom::Coverage::Template + # source://spoom//lib/spoom/coverage/report.rb#98 + sig { params(template: ::String, title: T.nilable(::String), body: T.nilable(::String)).void } + def initialize(template: T.unsafe(nil), title: T.unsafe(nil), body: T.unsafe(nil)); end + + # @return [String, nil] + # + # source://spoom//lib/spoom/coverage/report.rb#95 + def body; end + + # source://spoom//lib/spoom/coverage/report.rb#95 + sig { returns(T.nilable(::String)) } + def title; end +end + +# source://spoom//lib/spoom/coverage/report.rb#92 +Spoom::Coverage::Cards::Card::TEMPLATE = T.let(T.unsafe(nil), String) + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/coverage/report.rb#105 +class Spoom::Coverage::Cards::Erb < ::Spoom::Coverage::Cards::Card + abstract! + + # source://spoom//lib/spoom/coverage/report.rb#112 + sig { void } + def initialize; end + + # @abstract + # + # source://spoom//lib/spoom/coverage/report.rb#120 + sig { abstract.returns(::String) } + def erb; end + + # source://spoom//lib/spoom/coverage/report.rb#115 + sig { override.returns(::String) } + def html; end +end + +# source://spoom//lib/spoom/coverage/report.rb#153 +class Spoom::Coverage::Cards::Map < ::Spoom::Coverage::Cards::Card + # source://spoom//lib/spoom/coverage/report.rb#164 + sig do + params( + file_tree: ::Spoom::FileTree, + nodes_strictnesses: T::Hash[::Spoom::FileTree::Node, T.nilable(::String)], + nodes_strictness_scores: T::Hash[::Spoom::FileTree::Node, ::Float], + title: ::String + ).void + end + def initialize(file_tree:, nodes_strictnesses:, nodes_strictness_scores:, title: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/report.rb#123 +class Spoom::Coverage::Cards::Snapshot < ::Spoom::Coverage::Cards::Card + # source://spoom//lib/spoom/coverage/report.rb#132 + sig { params(snapshot: ::Spoom::Coverage::Snapshot, title: ::String).void } + def initialize(snapshot:, title: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/report.rb#143 + sig { returns(::Spoom::Coverage::D3::Pie::Calls) } + def pie_calls; end + + # source://spoom//lib/spoom/coverage/report.rb#138 + sig { returns(::Spoom::Coverage::D3::Pie::Sigils) } + def pie_sigils; end + + # source://spoom//lib/spoom/coverage/report.rb#148 + sig { returns(::Spoom::Coverage::D3::Pie::Sigs) } + def pie_sigs; end + + # source://spoom//lib/spoom/coverage/report.rb#129 + sig { returns(::Spoom::Coverage::Snapshot) } + def snapshot; end +end + +# source://spoom//lib/spoom/coverage/report.rb#126 +Spoom::Coverage::Cards::Snapshot::TEMPLATE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/coverage/report.rb#240 +class Spoom::Coverage::Cards::SorbetIntro < ::Spoom::Coverage::Cards::Erb + # source://spoom//lib/spoom/coverage/report.rb#244 + sig { params(sorbet_intro_commit: T.nilable(::String), sorbet_intro_date: T.nilable(::Time)).void } + def initialize(sorbet_intro_commit: T.unsafe(nil), sorbet_intro_date: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/report.rb#250 + sig { override.returns(::String) } + def erb; end +end + +# source://spoom//lib/spoom/coverage/report.rb#177 +class Spoom::Coverage::Cards::Timeline < ::Spoom::Coverage::Cards::Card + # source://spoom//lib/spoom/coverage/report.rb#181 + sig { params(title: ::String, timeline: ::Spoom::Coverage::D3::Timeline).void } + def initialize(title:, timeline:); end +end + +# source://spoom//lib/spoom/coverage/report.rb#194 +class Spoom::Coverage::Cards::Timeline::Calls < ::Spoom::Coverage::Cards::Timeline + # source://spoom//lib/spoom/coverage/report.rb#198 + sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } + def initialize(snapshots:, title: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/report.rb#212 +class Spoom::Coverage::Cards::Timeline::RBIs < ::Spoom::Coverage::Cards::Timeline + # source://spoom//lib/spoom/coverage/report.rb#216 + sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } + def initialize(snapshots:, title: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/report.rb#230 +class Spoom::Coverage::Cards::Timeline::Runtimes < ::Spoom::Coverage::Cards::Timeline + # source://spoom//lib/spoom/coverage/report.rb#234 + sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } + def initialize(snapshots:, title: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/report.rb#185 +class Spoom::Coverage::Cards::Timeline::Sigils < ::Spoom::Coverage::Cards::Timeline + # source://spoom//lib/spoom/coverage/report.rb#189 + sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } + def initialize(snapshots:, title: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/report.rb#203 +class Spoom::Coverage::Cards::Timeline::Sigs < ::Spoom::Coverage::Cards::Timeline + # source://spoom//lib/spoom/coverage/report.rb#207 + sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } + def initialize(snapshots:, title: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/report.rb#221 +class Spoom::Coverage::Cards::Timeline::Versions < ::Spoom::Coverage::Cards::Timeline + # source://spoom//lib/spoom/coverage/report.rb#225 + sig { params(snapshots: T::Array[::Spoom::Coverage::Snapshot], title: ::String).void } + def initialize(snapshots:, title: T.unsafe(nil)); end +end + +# source://spoom//lib/spoom/coverage/d3/base.rb#6 +module Spoom::Coverage::D3 + class << self + # source://spoom//lib/spoom/coverage/d3.rb#61 + sig { params(palette: ::Spoom::Coverage::D3::ColorPalette).returns(::String) } + def header_script(palette); end + + # source://spoom//lib/spoom/coverage/d3.rb#21 + sig { returns(::String) } + def header_style; end + end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/coverage/d3/base.rb#7 +class Spoom::Coverage::D3::Base + abstract! + + # source://spoom//lib/spoom/coverage/d3/base.rb#17 + sig { params(id: ::String, data: T.untyped).void } + def initialize(id, data); end + + # source://spoom//lib/spoom/coverage/d3/base.rb#37 + sig { returns(::String) } + def html; end + + # source://spoom//lib/spoom/coverage/d3/base.rb#14 + sig { returns(::String) } + def id; end + + # @abstract + # + # source://spoom//lib/spoom/coverage/d3/base.rb#50 + sig { abstract.returns(::String) } + def script; end + + # source://spoom//lib/spoom/coverage/d3/base.rb#45 + sig { returns(::String) } + def tooltip; end + + class << self + # source://spoom//lib/spoom/coverage/d3/base.rb#31 + sig { returns(::String) } + def header_script; end + + # source://spoom//lib/spoom/coverage/d3/base.rb#26 + sig { returns(::String) } + def header_style; end + end +end + +# source://spoom//lib/spoom/coverage/d3.rb#12 +Spoom::Coverage::D3::COLOR_FALSE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/coverage/d3.rb#11 +Spoom::Coverage::D3::COLOR_IGNORE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/coverage/d3.rb#14 +Spoom::Coverage::D3::COLOR_STRICT = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/coverage/d3.rb#15 +Spoom::Coverage::D3::COLOR_STRONG = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/coverage/d3.rb#13 +Spoom::Coverage::D3::COLOR_TRUE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/coverage/d3/circle_map.rb#9 +class Spoom::Coverage::D3::CircleMap < ::Spoom::Coverage::D3::Base + # source://spoom//lib/spoom/coverage/d3/circle_map.rb#59 + sig { override.returns(::String) } + def script; end + + class << self + # source://spoom//lib/spoom/coverage/d3/circle_map.rb#40 + sig { returns(::String) } + def header_script; end + + # source://spoom//lib/spoom/coverage/d3/circle_map.rb#14 + sig { returns(::String) } + def header_style; end + end +end + +# source://spoom//lib/spoom/coverage/d3/circle_map.rb#148 +class Spoom::Coverage::D3::CircleMap::Sigils < ::Spoom::Coverage::D3::CircleMap + # source://spoom//lib/spoom/coverage/d3/circle_map.rb#159 + sig do + params( + id: ::String, + file_tree: ::Spoom::FileTree, + nodes_strictnesses: T::Hash[::Spoom::FileTree::Node, T.nilable(::String)], + nodes_scores: T::Hash[::Spoom::FileTree::Node, ::Float] + ).void + end + def initialize(id, file_tree, nodes_strictnesses, nodes_scores); end + + # source://spoom//lib/spoom/coverage/d3/circle_map.rb#166 + sig { params(node: ::Spoom::FileTree::Node).returns(T::Hash[::Symbol, T.untyped]) } + def tree_node_to_json(node); end +end + +# source://spoom//lib/spoom/coverage/d3.rb#103 +class Spoom::Coverage::D3::ColorPalette < ::T::Struct + prop :ignore, ::String + prop :false, ::String + prop :true, ::String + prop :strict, ::String + prop :strong, ::String + + class << self + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/coverage/d3/pie.rb#9 +class Spoom::Coverage::D3::Pie < ::Spoom::Coverage::D3::Base + abstract! + + # source://spoom//lib/spoom/coverage/d3/pie.rb#16 + sig { params(id: ::String, title: ::String, data: T.untyped).void } + def initialize(id, title, data); end + + # source://spoom//lib/spoom/coverage/d3/pie.rb#56 + sig { override.returns(::String) } + def script; end + + class << self + # source://spoom//lib/spoom/coverage/d3/pie.rb#43 + sig { returns(::String) } + def header_script; end + + # source://spoom//lib/spoom/coverage/d3/pie.rb#25 + sig { returns(::String) } + def header_style; end + end +end + +# source://spoom//lib/spoom/coverage/d3/pie.rb#141 +class Spoom::Coverage::D3::Pie::Calls < ::Spoom::Coverage::D3::Pie + # source://spoom//lib/spoom/coverage/d3/pie.rb#145 + sig { params(id: ::String, title: ::String, snapshot: ::Spoom::Coverage::Snapshot).void } + def initialize(id, title, snapshot); end + + # source://spoom//lib/spoom/coverage/d3/pie.rb#150 + sig { override.returns(::String) } + def tooltip; end +end + +# source://spoom//lib/spoom/coverage/d3/pie.rb#123 +class Spoom::Coverage::D3::Pie::Sigils < ::Spoom::Coverage::D3::Pie + # source://spoom//lib/spoom/coverage/d3/pie.rb#127 + sig { params(id: ::String, title: ::String, snapshot: ::Spoom::Coverage::Snapshot).void } + def initialize(id, title, snapshot); end + + # source://spoom//lib/spoom/coverage/d3/pie.rb#132 + sig { override.returns(::String) } + def tooltip; end +end + +# source://spoom//lib/spoom/coverage/d3/pie.rb#159 +class Spoom::Coverage::D3::Pie::Sigs < ::Spoom::Coverage::D3::Pie + # source://spoom//lib/spoom/coverage/d3/pie.rb#163 + sig { params(id: ::String, title: ::String, snapshot: ::Spoom::Coverage::Snapshot).void } + def initialize(id, title, snapshot); end + + # source://spoom//lib/spoom/coverage/d3/pie.rb#172 + sig { override.returns(::String) } + def tooltip; end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/coverage/d3/timeline.rb#9 +class Spoom::Coverage::D3::Timeline < ::Spoom::Coverage::D3::Base + abstract! + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#16 + sig { params(id: ::String, data: T.untyped, keys: T::Array[::String]).void } + def initialize(id, data, keys); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#187 + sig { params(y: ::String, color: ::String, curve: ::String).returns(::String) } + def area(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#203 + sig { params(y: ::String, color: ::String, curve: ::String).returns(::String) } + def line(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end + + # @abstract + # + # source://spoom//lib/spoom/coverage/d3/timeline.rb#126 + sig { abstract.returns(::String) } + def plot; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#217 + sig { params(y: ::String).returns(::String) } + def points(y:); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#101 + sig { override.returns(::String) } + def script; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#129 + sig { returns(::String) } + def x_scale; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#145 + sig { returns(::String) } + def x_ticks; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#158 + sig { params(min: ::String, max: ::String, ticks: ::String).returns(::String) } + def y_scale(min:, max:, ticks:); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#174 + sig { params(ticks: ::String, format: ::String, padding: ::Integer).returns(::String) } + def y_ticks(ticks:, format:, padding:); end + + class << self + # source://spoom//lib/spoom/coverage/d3/timeline.rb#79 + sig { returns(::String) } + def header_script; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#25 + sig { returns(::String) } + def header_style; end + end +end + +# source://spoom//lib/spoom/coverage/d3/timeline.rb#448 +class Spoom::Coverage::D3::Timeline::Calls < ::Spoom::Coverage::D3::Timeline::Stacked + # source://spoom//lib/spoom/coverage/d3/timeline.rb#452 + sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } + def initialize(id, snapshots); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#466 + sig { override.returns(::String) } + def tooltip; end +end + +# source://spoom//lib/spoom/coverage/d3/timeline.rb#505 +class Spoom::Coverage::D3::Timeline::RBIs < ::Spoom::Coverage::D3::Timeline::Stacked + # source://spoom//lib/spoom/coverage/d3/timeline.rb#509 + sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } + def initialize(id, snapshots); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#577 + sig { override.params(y: ::String, color: ::String, curve: ::String).returns(::String) } + def line(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#617 + sig { override.returns(::String) } + def plot; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#537 + sig { override.returns(::String) } + def script; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#523 + sig { override.returns(::String) } + def tooltip; end +end + +# source://spoom//lib/spoom/coverage/d3/timeline.rb#282 +class Spoom::Coverage::D3::Timeline::Runtimes < ::Spoom::Coverage::D3::Timeline + # source://spoom//lib/spoom/coverage/d3/timeline.rb#286 + sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } + def initialize(id, snapshots); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#311 + sig { override.returns(::String) } + def plot; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#298 + sig { override.returns(::String) } + def tooltip; end +end + +# source://spoom//lib/spoom/coverage/d3/timeline.rb#421 +class Spoom::Coverage::D3::Timeline::Sigils < ::Spoom::Coverage::D3::Timeline::Stacked + # source://spoom//lib/spoom/coverage/d3/timeline.rb#425 + sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } + def initialize(id, snapshots); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#439 + sig { override.returns(::String) } + def tooltip; end +end + +# source://spoom//lib/spoom/coverage/d3/timeline.rb#475 +class Spoom::Coverage::D3::Timeline::Sigs < ::Spoom::Coverage::D3::Timeline::Stacked + # source://spoom//lib/spoom/coverage/d3/timeline.rb#479 + sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } + def initialize(id, snapshots); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#496 + sig { override.returns(::String) } + def tooltip; end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/coverage/d3/timeline.rb#329 +class Spoom::Coverage::D3::Timeline::Stacked < ::Spoom::Coverage::D3::Timeline + abstract! + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#388 + sig { override.params(y: ::String, color: ::String, curve: ::String).returns(::String) } + def line(y:, color: T.unsafe(nil), curve: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#377 + sig { override.returns(::String) } + def plot; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#336 + sig { override.returns(::String) } + def script; end +end + +# source://spoom//lib/spoom/coverage/d3/timeline.rb#232 +class Spoom::Coverage::D3::Timeline::Versions < ::Spoom::Coverage::D3::Timeline + # source://spoom//lib/spoom/coverage/d3/timeline.rb#236 + sig { params(id: ::String, snapshots: T::Array[::Spoom::Coverage::Snapshot]).void } + def initialize(id, snapshots); end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#263 + sig { override.returns(::String) } + def plot; end + + # source://spoom//lib/spoom/coverage/d3/timeline.rb#249 + sig { override.returns(::String) } + def tooltip; end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/coverage/report.rb#38 +class Spoom::Coverage::Page < ::Spoom::Coverage::Template + abstract! + + # source://spoom//lib/spoom/coverage/report.rb#53 + sig { params(title: ::String, palette: ::Spoom::Coverage::D3::ColorPalette, template: ::String).void } + def initialize(title:, palette:, template: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/report.rb#75 + sig { returns(::String) } + def body_html; end + + # @abstract + # + # source://spoom//lib/spoom/coverage/report.rb#80 + sig { abstract.returns(T::Array[::Spoom::Coverage::Cards::Card]) } + def cards; end + + # source://spoom//lib/spoom/coverage/report.rb#83 + sig { returns(::String) } + def footer_html; end + + # source://spoom//lib/spoom/coverage/report.rb#70 + sig { returns(::String) } + def header_html; end + + # source://spoom//lib/spoom/coverage/report.rb#65 + sig { returns(::String) } + def header_script; end + + # source://spoom//lib/spoom/coverage/report.rb#60 + sig { returns(::String) } + def header_style; end + + # source://spoom//lib/spoom/coverage/report.rb#50 + sig { returns(::Spoom::Coverage::D3::ColorPalette) } + def palette; end + + # source://spoom//lib/spoom/coverage/report.rb#47 + sig { returns(::String) } + def title; end +end + +# source://spoom//lib/spoom/coverage/report.rb#44 +Spoom::Coverage::Page::TEMPLATE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/coverage/report.rb#261 +class Spoom::Coverage::Report < ::Spoom::Coverage::Page + # source://spoom//lib/spoom/coverage/report.rb#276 + sig do + params( + project_name: ::String, + palette: ::Spoom::Coverage::D3::ColorPalette, + snapshots: T::Array[::Spoom::Coverage::Snapshot], + file_tree: ::Spoom::FileTree, + nodes_strictnesses: T::Hash[::Spoom::FileTree::Node, T.nilable(::String)], + nodes_strictness_scores: T::Hash[::Spoom::FileTree::Node, ::Float], + sorbet_intro_commit: T.nilable(::String), + sorbet_intro_date: T.nilable(::Time) + ).void + end + def initialize(project_name:, palette:, snapshots:, file_tree:, nodes_strictnesses:, nodes_strictness_scores:, sorbet_intro_commit: T.unsafe(nil), sorbet_intro_date: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/report.rb#308 + sig { override.returns(T::Array[::Spoom::Coverage::Cards::Card]) } + def cards; end + + # source://spoom//lib/spoom/coverage/report.rb#297 + sig { override.returns(::String) } + def header_html; end +end + +# source://spoom//lib/spoom/coverage/snapshot.rb#6 +class Spoom::Coverage::Snapshot < ::T::Struct + prop :timestamp, ::Integer, default: T.unsafe(nil) + prop :version_static, T.nilable(::String), default: T.unsafe(nil) + prop :version_runtime, T.nilable(::String), default: T.unsafe(nil) + prop :duration, ::Integer, default: T.unsafe(nil) + prop :commit_sha, T.nilable(::String), default: T.unsafe(nil) + prop :commit_timestamp, T.nilable(::Integer), default: T.unsafe(nil) + prop :files, ::Integer, default: T.unsafe(nil) + prop :rbi_files, ::Integer, default: T.unsafe(nil) + prop :modules, ::Integer, default: T.unsafe(nil) + prop :classes, ::Integer, default: T.unsafe(nil) + prop :singleton_classes, ::Integer, default: T.unsafe(nil) + prop :methods_without_sig, ::Integer, default: T.unsafe(nil) + prop :methods_with_sig, ::Integer, default: T.unsafe(nil) + prop :calls_untyped, ::Integer, default: T.unsafe(nil) + prop :calls_typed, ::Integer, default: T.unsafe(nil) + prop :sigils, T::Hash[::String, ::Integer], default: T.unsafe(nil) + prop :methods_with_sig_excluding_rbis, ::Integer, default: T.unsafe(nil) + prop :methods_without_sig_excluding_rbis, ::Integer, default: T.unsafe(nil) + prop :sigils_excluding_rbis, T::Hash[::String, ::Integer], default: T.unsafe(nil) + + # source://spoom//lib/spoom/coverage/snapshot.rb#33 + sig { params(out: T.any(::IO, ::StringIO), colors: T::Boolean, indent_level: ::Integer).void } + def print(out: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil)); end + + # source://spoom//lib/spoom/coverage/snapshot.rb#39 + sig { params(arg: T.untyped).returns(::String) } + def to_json(*arg); end + + class << self + # source://spoom//lib/spoom/coverage/snapshot.rb#47 + sig { params(json: ::String).returns(::Spoom::Coverage::Snapshot) } + def from_json(json); end + + # source://spoom//lib/spoom/coverage/snapshot.rb#52 + sig { params(obj: T::Hash[::String, T.untyped]).returns(::Spoom::Coverage::Snapshot) } + def from_obj(obj); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# The strictness name as found in the Sorbet metrics file +# +# source://spoom//lib/spoom/coverage/snapshot.rb#30 +Spoom::Coverage::Snapshot::STRICTNESSES = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/coverage/snapshot.rb#95 +class Spoom::Coverage::SnapshotPrinter < ::Spoom::Printer + # source://spoom//lib/spoom/coverage/snapshot.rb#99 + sig { params(snapshot: ::Spoom::Coverage::Snapshot).void } + def print_snapshot(snapshot); end + + private + + # source://spoom//lib/spoom/coverage/snapshot.rb#158 + sig { params(value: T.nilable(::Integer), total: T.nilable(::Integer)).returns(::String) } + def percent(value, total); end + + # source://spoom//lib/spoom/coverage/snapshot.rb#147 + sig { params(hash: T::Hash[::String, ::Integer], total: ::Integer).void } + def print_map(hash, total); end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/coverage/report.rb#10 +class Spoom::Coverage::Template + abstract! + + # Create a new template from an Erb file path + # + # source://spoom//lib/spoom/coverage/report.rb#18 + sig { params(template: ::String).void } + def initialize(template:); end + + # source://spoom//lib/spoom/coverage/report.rb#23 + sig { returns(::String) } + def erb; end + + # source://spoom//lib/spoom/coverage/report.rb#33 + sig { returns(::Binding) } + def get_binding; end + + # source://spoom//lib/spoom/coverage/report.rb#28 + sig { returns(::String) } + def html; end +end + +# source://spoom//lib/spoom/deadcode/erb.rb#27 +module Spoom::Deadcode + class << self + # source://spoom//lib/spoom/deadcode/plugins.rb#75 + sig { params(context: ::Spoom::Context).returns(T::Array[T.class_of(Spoom::Deadcode::Plugins::Base)]) } + def load_custom_plugins(context); end + + # source://spoom//lib/spoom/deadcode/plugins.rb#61 + sig { params(context: ::Spoom::Context).returns(T::Set[T.class_of(Spoom::Deadcode::Plugins::Base)]) } + def plugins_from_gemfile_lock(context); end + end +end + +# source://spoom//lib/spoom/deadcode/plugins.rb#26 +Spoom::Deadcode::DEFAULT_CUSTOM_PLUGINS_PATH = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/deadcode/plugins.rb#28 +Spoom::Deadcode::DEFAULT_PLUGINS = T.let(T.unsafe(nil), Set) + +# A definition is a class, module, method, constant, etc. being defined in the code +# +# source://spoom//lib/spoom/deadcode/definition.rb#7 +class Spoom::Deadcode::Definition < ::T::Struct + const :kind, ::Spoom::Deadcode::Definition::Kind + const :name, ::String + const :full_name, ::String + const :location, ::Spoom::Location + const :status, ::Spoom::Deadcode::Definition::Status, default: T.unsafe(nil) + + # source://spoom//lib/spoom/deadcode/definition.rb#78 + sig { void } + def alive!; end + + # Status + # + # source://spoom//lib/spoom/deadcode/definition.rb#73 + sig { returns(T::Boolean) } + def alive?; end + + # Kind + # + # source://spoom//lib/spoom/deadcode/definition.rb#41 + sig { returns(T::Boolean) } + def attr_reader?; end + + # source://spoom//lib/spoom/deadcode/definition.rb#46 + sig { returns(T::Boolean) } + def attr_writer?; end + + # source://spoom//lib/spoom/deadcode/definition.rb#51 + sig { returns(T::Boolean) } + def class?; end + + # source://spoom//lib/spoom/deadcode/definition.rb#56 + sig { returns(T::Boolean) } + def constant?; end + + # source://spoom//lib/spoom/deadcode/definition.rb#83 + sig { returns(T::Boolean) } + def dead?; end + + # source://spoom//lib/spoom/deadcode/definition.rb#93 + sig { void } + def ignored!; end + + # source://spoom//lib/spoom/deadcode/definition.rb#88 + sig { returns(T::Boolean) } + def ignored?; end + + # source://spoom//lib/spoom/deadcode/definition.rb#61 + sig { returns(T::Boolean) } + def method?; end + + # source://spoom//lib/spoom/deadcode/definition.rb#66 + sig { returns(T::Boolean) } + def module?; end + + # Utils + # + # source://spoom//lib/spoom/deadcode/definition.rb#100 + sig { params(args: T.untyped).returns(::String) } + def to_json(*args); end + + class << self + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://spoom//lib/spoom/deadcode/definition.rb#10 +class Spoom::Deadcode::Definition::Kind < ::T::Enum + enums do + AttrReader = new + AttrWriter = new + Class = new + Constant = new + Method = new + Module = new + end +end + +# source://spoom//lib/spoom/deadcode/definition.rb#21 +class Spoom::Deadcode::Definition::Status < ::T::Enum + enums do + ALIVE = new + DEAD = new + IGNORED = new + end +end + +# Custom engine to handle ERB templates as used by Rails +# +# source://spoom//lib/spoom/deadcode/erb.rb#29 +class Spoom::Deadcode::ERB < ::Erubi::Engine + # source://spoom//lib/spoom/deadcode/erb.rb#33 + sig { params(input: T.untyped, properties: T.untyped).void } + def initialize(input, properties = T.unsafe(nil)); end + + private + + # source://spoom//lib/spoom/deadcode/erb.rb#83 + sig { override.params(code: T.untyped).void } + def add_code(code); end + + # source://spoom//lib/spoom/deadcode/erb.rb#66 + sig { override.params(indicator: T.untyped, code: T.untyped).void } + def add_expression(indicator, code); end + + # source://spoom//lib/spoom/deadcode/erb.rb#89 + sig { override.params(_: T.untyped).void } + def add_postamble(_); end + + # source://spoom//lib/spoom/deadcode/erb.rb#48 + sig { override.params(text: T.untyped).void } + def add_text(text); end + + # source://spoom//lib/spoom/deadcode/erb.rb#95 + sig { params(src: T.untyped).void } + def flush_newline_if_pending(src); end +end + +# source://spoom//lib/spoom/deadcode/erb.rb#63 +Spoom::Deadcode::ERB::BLOCK_EXPR = T.let(T.unsafe(nil), Regexp) + +# source://spoom//lib/spoom/deadcode/index.rb#6 +class Spoom::Deadcode::Index + # source://spoom//lib/spoom/deadcode/index.rb#29 + sig { params(model: ::Spoom::Model).void } + def initialize(model); end + + # source://spoom//lib/spoom/deadcode/index.rb#219 + sig { returns(T::Array[::Spoom::Deadcode::Definition]) } + def all_definitions; end + + # source://spoom//lib/spoom/deadcode/index.rb#224 + sig { returns(T::Array[::Spoom::Model::Reference]) } + def all_references; end + + # source://spoom//lib/spoom/deadcode/index.rb#99 + sig { params(plugins: T::Array[::Spoom::Deadcode::Plugins::Base]).void } + def apply_plugins!(plugins); end + + # source://spoom//lib/spoom/deadcode/index.rb#79 + sig { params(definition: ::Spoom::Deadcode::Definition).void } + def define(definition); end + + # source://spoom//lib/spoom/deadcode/index.rb#23 + sig { returns(T::Hash[::String, T::Array[::Spoom::Deadcode::Definition]]) } + def definitions; end + + # Utils + # + # source://spoom//lib/spoom/deadcode/index.rb#214 + sig { params(name: ::String).returns(T::Array[::Spoom::Deadcode::Definition]) } + def definitions_for_name(name); end + + # Mark all definitions having a reference of the same name as `alive` + # + # To be called once all the files have been indexed and all the definitions and references discovered. + # + # source://spoom//lib/spoom/deadcode/index.rb#122 + sig { void } + def finalize!; end + + # source://spoom//lib/spoom/deadcode/index.rb#94 + sig { params(symbol_def: ::Spoom::Model::SymbolDef).void } + def ignore(symbol_def); end + + # source://spoom//lib/spoom/deadcode/index.rb#50 + sig { params(erb: ::String, file: ::String, plugins: T::Array[::Spoom::Deadcode::Plugins::Base]).void } + def index_erb(erb, file:, plugins: T.unsafe(nil)); end + + # Indexing + # + # source://spoom//lib/spoom/deadcode/index.rb#39 + sig { params(file: ::String, plugins: T::Array[::Spoom::Deadcode::Plugins::Base]).void } + def index_file(file, plugins: T.unsafe(nil)); end + + # source://spoom//lib/spoom/deadcode/index.rb#55 + sig { params(rb: ::String, file: ::String, plugins: T::Array[::Spoom::Deadcode::Plugins::Base]).void } + def index_ruby(rb, file:, plugins: T.unsafe(nil)); end + + # source://spoom//lib/spoom/deadcode/index.rb#20 + sig { returns(::Spoom::Model) } + def model; end + + # source://spoom//lib/spoom/deadcode/index.rb#84 + sig { params(name: ::String, location: ::Spoom::Location).void } + def reference_constant(name, location); end + + # source://spoom//lib/spoom/deadcode/index.rb#89 + sig { params(name: ::String, location: ::Spoom::Location).void } + def reference_method(name, location); end + + # source://spoom//lib/spoom/deadcode/index.rb#26 + sig { returns(T::Hash[::String, T::Array[::Spoom::Model::Reference]]) } + def references; end +end + +# source://spoom//lib/spoom/deadcode/index.rb#9 +class Spoom::Deadcode::Index::Error < ::Spoom::Error + # source://spoom//lib/spoom/deadcode/index.rb#13 + sig { params(message: ::String, parent: ::Exception).void } + def initialize(message, parent:); end +end + +# source://spoom//lib/spoom/deadcode/indexer.rb#6 +class Spoom::Deadcode::Indexer < ::Spoom::Visitor + # source://spoom//lib/spoom/deadcode/indexer.rb#16 + sig do + params( + path: ::String, + index: ::Spoom::Deadcode::Index, + plugins: T::Array[::Spoom::Deadcode::Plugins::Base] + ).void + end + def initialize(path, index, plugins: T.unsafe(nil)); end + + # source://spoom//lib/spoom/deadcode/indexer.rb#13 + sig { returns(::Spoom::Deadcode::Index) } + def index; end + + # source://spoom//lib/spoom/deadcode/indexer.rb#10 + sig { returns(::String) } + def path; end + + # Visit + # + # source://spoom//lib/spoom/deadcode/indexer.rb#27 + sig { override.params(node: ::Prism::CallNode).void } + def visit_call_node(node); end +end + +# source://spoom//lib/spoom/deadcode/plugins.rb#36 +Spoom::Deadcode::PLUGINS_FOR_GEM = T.let(T.unsafe(nil), Hash) + +# source://spoom//lib/spoom/deadcode/plugins/base.rb#8 +module Spoom::Deadcode::Plugins; end + +# source://spoom//lib/spoom/deadcode/plugins/action_mailer.rb#7 +class Spoom::Deadcode::Plugins::ActionMailer < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/action_mailer.rb#11 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end +end + +# source://spoom//lib/spoom/deadcode/plugins/action_mailer_preview.rb#7 +class Spoom::Deadcode::Plugins::ActionMailerPreview < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/action_mailer_preview.rb#13 + sig { override.params(definition: ::Spoom::Model::Method).void } + def on_define_method(definition); end +end + +# source://spoom//lib/spoom/deadcode/plugins/actionpack.rb#7 +class Spoom::Deadcode::Plugins::ActionPack < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/actionpack.rb#31 + sig { override.params(definition: ::Spoom::Model::Method).void } + def on_define_method(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/actionpack.rb#39 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end +end + +# source://spoom//lib/spoom/deadcode/plugins/actionpack.rb#12 +Spoom::Deadcode::Plugins::ActionPack::CALLBACKS = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/deadcode/plugins/active_job.rb#7 +class Spoom::Deadcode::Plugins::ActiveJob < ::Spoom::Deadcode::Plugins::Base; end + +# source://spoom//lib/spoom/deadcode/plugins/active_model.rb#7 +class Spoom::Deadcode::Plugins::ActiveModel < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/active_model.rb#14 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end +end + +# source://spoom//lib/spoom/deadcode/plugins/active_record.rb#7 +class Spoom::Deadcode::Plugins::ActiveRecord < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/active_record.rb#74 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end +end + +# source://spoom//lib/spoom/deadcode/plugins/active_record.rb#64 +Spoom::Deadcode::Plugins::ActiveRecord::ARRAY_METHODS = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/deadcode/plugins/active_record.rb#20 +Spoom::Deadcode::Plugins::ActiveRecord::CALLBACKS = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/deadcode/plugins/active_record.rb#49 +Spoom::Deadcode::Plugins::ActiveRecord::CRUD_METHODS = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/deadcode/plugins/active_support.rb#7 +class Spoom::Deadcode::Plugins::ActiveSupport < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/active_support.rb#22 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end +end + +# source://spoom//lib/spoom/deadcode/plugins/active_support.rb#19 +Spoom::Deadcode::Plugins::ActiveSupport::SETUP_AND_TEARDOWN_METHODS = T.let(T.unsafe(nil), Array) + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/deadcode/plugins/base.rb#9 +class Spoom::Deadcode::Plugins::Base + abstract! + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#132 + sig { params(index: ::Spoom::Deadcode::Index).void } + def initialize(index); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#129 + sig { returns(::Spoom::Deadcode::Index) } + def index; end + + # Do not override this method, use `on_define_accessor` instead. + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#158 + sig { params(definition: ::Spoom::Model::Attr).void } + def internal_on_define_accessor(definition); end + + # Do not override this method, use `on_define_class` instead. + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#182 + sig { params(definition: ::Spoom::Model::Class).void } + def internal_on_define_class(definition); end + + # Do not override this method, use `on_define_constant` instead. + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#212 + sig { params(definition: ::Spoom::Model::Constant).void } + def internal_on_define_constant(definition); end + + # Do not override this method, use `on_define_method` instead. + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#238 + sig { params(definition: ::Spoom::Model::Method).void } + def internal_on_define_method(definition); end + + # Do not override this method, use `on_define_module` instead. + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#264 + sig { params(definition: ::Spoom::Model::Module).void } + def internal_on_define_module(definition); end + + # Called when an accessor is defined. + # + # Will be called when the indexer processes a `attr_reader`, `attr_writer` or `attr_accessor` node. + # Note that when this method is called, the definition for the node has already been added to the index. + # It is still possible to ignore it from the plugin: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # def on_define_accessor(definition) + # @index.ignore(definition) if symbol_def.name == "foo" + # end + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#152 + sig { params(definition: ::Spoom::Model::Attr).void } + def on_define_accessor(definition); end + + # Called when a class is defined. + # + # Will be called when the indexer processes a `class` node. + # Note that when this method is called, the definition for the node has already been added to the index. + # It is still possible to ignore it from the plugin: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # def on_define_class(definition) + # @index.ignore(definition) if definition.name == "Foo" + # end + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#176 + sig { params(definition: ::Spoom::Model::Class).void } + def on_define_class(definition); end + + # Called when a constant is defined. + # + # Will be called when the indexer processes a `CONST =` node. + # Note that when this method is called, the definition for the node has already been added to the index. + # It is still possible to ignore it from the plugin: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # def on_define_constant(definition) + # @index.ignore(definition) if definition.name == "FOO" + # end + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#206 + sig { params(definition: ::Spoom::Model::Constant).void } + def on_define_constant(definition); end + + # Called when a method is defined. + # + # Will be called when the indexer processes a `def` or `defs` node. + # Note that when this method is called, the definition for the node has already been added to the index. + # It is still possible to ignore it from the plugin: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # def on_define_method(definition) + # @index.ignore(definition) if definition.name == "foo" + # end + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#232 + sig { params(definition: ::Spoom::Model::Method).void } + def on_define_method(definition); end + + # Called when a module is defined. + # + # Will be called when the indexer processes a `module` node. + # Note that when this method is called, the definition for the node has already been added to the index. + # It is still possible to ignore it from the plugin: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # def on_define_module(definition) + # @index.ignore(definition) if definition.name == "Foo" + # end + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#258 + sig { params(definition: ::Spoom::Model::Module).void } + def on_define_module(definition); end + + # Called when a send is being processed + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # def on_send(send) + # return unless send.name == "dsl_method" + # return if send.args.empty? + # + # method_name = send.args.first.slice.delete_prefix(":") + # @index.reference_method(method_name, send.node, send.loc) + # end + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#284 + sig { params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end + + private + + # Plugin utils + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#352 + sig { params(name: ::String).returns(::String) } + def camelize(name); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#301 + sig { params(name: T.nilable(::String)).returns(T::Boolean) } + def ignored_class_name?(name); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#320 + sig { params(name: ::String).returns(T::Boolean) } + def ignored_constant_name?(name); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#325 + sig { params(name: ::String).returns(T::Boolean) } + def ignored_method_name?(name); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#330 + sig { params(name: ::String).returns(T::Boolean) } + def ignored_module_name?(name); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#335 + sig { params(name: ::String, names_variable: ::Symbol, patterns_variable: ::Symbol).returns(T::Boolean) } + def ignored_name?(name, names_variable, patterns_variable); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#308 + sig { params(definition: ::Spoom::Model::Class).returns(T::Boolean) } + def ignored_subclass?(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#340 + sig { params(const: ::Symbol).returns(T::Set[::String]) } + def names(const); end + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#345 + sig { params(const: ::Symbol).returns(T::Array[::Regexp]) } + def patterns(const); end + + # DSL support + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#293 + sig { params(definition: ::Spoom::Model::Namespace, superclass_name: ::String).returns(T::Boolean) } + def subclass_of?(definition, superclass_name); end + + class << self + # Mark classes directly subclassing a class matching `names` as ignored. + # + # Names can be either strings or regexps: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # ignore_classes_inheriting_from( + # "Foo", + # "Bar", + # /Baz.*/, + # ) + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#52 + sig { params(names: T.any(::Regexp, ::String)).void } + def ignore_classes_inheriting_from(*names); end + + # Mark classes matching `names` as ignored. + # + # Names can be either strings or regexps: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # ignore_class_names( + # "Foo", + # "Bar", + # /Baz.*/, + # ) + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#34 + sig { params(names: T.any(::Regexp, ::String)).void } + def ignore_classes_named(*names); end + + # Mark constants matching `names` as ignored. + # + # Names can be either strings or regexps: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # ignore_class_names( + # "FOO", + # "BAR", + # /BAZ.*/, + # ) + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#70 + sig { params(names: T.any(::Regexp, ::String)).void } + def ignore_constants_named(*names); end + + # Mark methods matching `names` as ignored. + # + # Names can be either strings or regexps: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # ignore_method_names( + # "foo", + # "bar", + # /baz.*/, + # ) + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#88 + sig { params(names: T.any(::Regexp, ::String)).void } + def ignore_methods_named(*names); end + + # Mark modules matching `names` as ignored. + # + # Names can be either strings or regexps: + # + # ~~~rb + # class MyPlugin < Spoom::Deadcode::Plugins::Base + # ignore_class_names( + # "Foo", + # "Bar", + # /Baz.*/, + # ) + # end + # ~~~ + # + # source://spoom//lib/spoom/deadcode/plugins/base.rb#106 + sig { params(names: T.any(::Regexp, ::String)).void } + def ignore_modules_named(*names); end + + private + + # source://spoom//lib/spoom/deadcode/plugins/base.rb#113 + sig do + params( + names: T::Array[T.any(::Regexp, ::String)], + names_variable: ::Symbol, + patterns_variable: ::Symbol + ).void + end + def save_names_and_patterns(names, names_variable, patterns_variable); end + end +end + +# source://spoom//lib/spoom/deadcode/plugins/graphql.rb#7 +class Spoom::Deadcode::Plugins::GraphQL < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/graphql.rb#28 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end +end + +# source://spoom//lib/spoom/deadcode/plugins/minitest.rb#7 +class Spoom::Deadcode::Plugins::Minitest < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/minitest.rb#22 + sig { override.params(definition: ::Spoom::Model::Method).void } + def on_define_method(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/minitest.rb#28 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end +end + +# source://spoom//lib/spoom/deadcode/plugins/namespaces.rb#7 +class Spoom::Deadcode::Plugins::Namespaces < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/namespaces.rb#11 + sig { override.params(definition: ::Spoom::Model::Class).void } + def on_define_class(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/namespaces.rb#16 + sig { override.params(definition: ::Spoom::Model::Module).void } + def on_define_module(definition); end + + private + + # source://spoom//lib/spoom/deadcode/plugins/namespaces.rb#23 + sig { params(symbol_def: ::Spoom::Model::Namespace).returns(T::Boolean) } + def used_as_namespace?(symbol_def); end +end + +# source://spoom//lib/spoom/deadcode/plugins/rspec.rb#7 +class Spoom::Deadcode::Plugins::RSpec < ::Spoom::Deadcode::Plugins::Base; end + +# source://spoom//lib/spoom/deadcode/plugins/rails.rb#7 +class Spoom::Deadcode::Plugins::Rails < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/rails.rb#13 + sig { override.params(definition: ::Spoom::Model::Class).void } + def on_define_class(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/rails.rb#18 + sig { override.params(definition: ::Spoom::Model::Module).void } + def on_define_module(definition); end + + private + + # source://spoom//lib/spoom/deadcode/plugins/rails.rb#25 + sig { params(symbol_def: ::Spoom::Model::Namespace).returns(T::Boolean) } + def file_is_helper?(symbol_def); end +end + +# source://spoom//lib/spoom/deadcode/plugins/rake.rb#7 +class Spoom::Deadcode::Plugins::Rake < ::Spoom::Deadcode::Plugins::Base; end + +# source://spoom//lib/spoom/deadcode/plugins/rubocop.rb#7 +class Spoom::Deadcode::Plugins::Rubocop < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/rubocop.rb#18 + sig { override.params(definition: ::Spoom::Model::Constant).void } + def on_define_constant(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/rubocop.rb#26 + sig { override.params(definition: ::Spoom::Model::Method).void } + def on_define_method(definition); end +end + +# source://spoom//lib/spoom/deadcode/plugins/rubocop.rb#10 +Spoom::Deadcode::Plugins::Rubocop::RUBOCOP_CONSTANTS = T.let(T.unsafe(nil), Set) + +# source://spoom//lib/spoom/deadcode/plugins/ruby.rb#7 +class Spoom::Deadcode::Plugins::Ruby < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/ruby.rb#24 + sig { override.params(send: ::Spoom::Deadcode::Send).void } + def on_send(send); end + + private + + # source://spoom//lib/spoom/deadcode/plugins/ruby.rb#43 + sig { params(send: ::Spoom::Deadcode::Send, node: ::Prism::Node).void } + def reference_symbol_as_constant(send, node); end +end + +# source://spoom//lib/spoom/deadcode/plugins/sorbet.rb#7 +class Spoom::Deadcode::Plugins::Sorbet < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/sorbet.rb#11 + sig { override.params(definition: ::Spoom::Model::Constant).void } + def on_define_constant(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/sorbet.rb#16 + sig { override.params(definition: ::Spoom::Model::Method).void } + def on_define_method(definition); end + + private + + # source://spoom//lib/spoom/deadcode/plugins/sorbet.rb#28 + sig { params(definition: ::Spoom::Model::Constant).returns(T::Boolean) } + def sorbet_enum_constant?(definition); end + + # source://spoom//lib/spoom/deadcode/plugins/sorbet.rb#23 + sig { params(definition: ::Spoom::Model::Constant).returns(T::Boolean) } + def sorbet_type_member?(definition); end +end + +# source://spoom//lib/spoom/deadcode/plugins/thor.rb#7 +class Spoom::Deadcode::Plugins::Thor < ::Spoom::Deadcode::Plugins::Base + # source://spoom//lib/spoom/deadcode/plugins/thor.rb#13 + sig { override.params(definition: ::Spoom::Model::Method).void } + def on_define_method(definition); end +end + +# source://spoom//lib/spoom/deadcode/remover.rb#6 +class Spoom::Deadcode::Remover + # source://spoom//lib/spoom/deadcode/remover.rb#12 + sig { params(context: ::Spoom::Context).void } + def initialize(context); end + + # source://spoom//lib/spoom/deadcode/remover.rb#17 + sig { params(kind: T.nilable(::Spoom::Deadcode::Definition::Kind), location: ::Spoom::Location).returns(::String) } + def remove_location(kind, location); end +end + +# source://spoom//lib/spoom/deadcode/remover.rb#9 +class Spoom::Deadcode::Remover::Error < ::Spoom::Error; end + +# source://spoom//lib/spoom/deadcode/remover.rb#372 +class Spoom::Deadcode::Remover::NodeContext + # source://spoom//lib/spoom/deadcode/remover.rb#392 + sig do + params( + source: ::String, + comments: T::Hash[::Integer, ::Prism::Comment], + node: ::Prism::Node, + nesting: T::Array[::Prism::Node] + ).void + end + def initialize(source, comments, node, nesting); end + + # source://spoom//lib/spoom/deadcode/remover.rb#506 + sig { params(node: ::Prism::Node).returns(T::Array[::Prism::Comment]) } + def attached_comments(node); end + + # source://spoom//lib/spoom/deadcode/remover.rb#534 + sig { returns(T.nilable(::Prism::CallNode)) } + def attached_sig; end + + # source://spoom//lib/spoom/deadcode/remover.rb#521 + sig { returns(T::Array[::Prism::Node]) } + def attached_sigs; end + + # source://spoom//lib/spoom/deadcode/remover.rb#376 + sig { returns(T::Hash[::Integer, ::Prism::Comment]) } + def comments; end + + # source://spoom//lib/spoom/deadcode/remover.rb#494 + sig { params(start_line: ::Integer, end_line: ::Integer).returns(T::Array[::Prism::Comment]) } + def comments_between_lines(start_line, end_line); end + + # source://spoom//lib/spoom/deadcode/remover.rb#382 + sig { returns(T::Array[::Prism::Node]) } + def nesting; end + + # @return [Array] + # + # source://spoom//lib/spoom/deadcode/remover.rb#382 + def nesting=(_arg0); end + + # source://spoom//lib/spoom/deadcode/remover.rb#444 + sig { returns(T.nilable(::Prism::Node)) } + def next_node; end + + # @raise [Error] + # + # source://spoom//lib/spoom/deadcode/remover.rb#433 + sig { returns(T::Array[::Prism::Node]) } + def next_nodes; end + + # source://spoom//lib/spoom/deadcode/remover.rb#379 + sig { returns(::Prism::Node) } + def node; end + + # @raise [Error] + # + # source://spoom//lib/spoom/deadcode/remover.rb#408 + sig { returns(::Spoom::Deadcode::Remover::NodeContext) } + def parent_context; end + + # @raise [Error] + # + # source://spoom//lib/spoom/deadcode/remover.rb#400 + sig { returns(::Prism::Node) } + def parent_node; end + + # source://spoom//lib/spoom/deadcode/remover.rb#428 + sig { returns(T.nilable(::Prism::Node)) } + def previous_node; end + + # @raise [Error] + # + # source://spoom//lib/spoom/deadcode/remover.rb#417 + sig { returns(T::Array[::Prism::Node]) } + def previous_nodes; end + + # source://spoom//lib/spoom/deadcode/remover.rb#449 + sig { returns(T.nilable(::Spoom::Deadcode::Remover::NodeContext)) } + def sclass_context; end + + # source://spoom//lib/spoom/deadcode/remover.rb#482 + sig { params(node: T.nilable(::Prism::Node)).returns(T::Boolean) } + def sorbet_extend_sig?(node); end + + # source://spoom//lib/spoom/deadcode/remover.rb#477 + sig { params(node: T.nilable(::Prism::Node)).returns(T::Boolean) } + def sorbet_signature?(node); end +end + +# source://spoom//lib/spoom/deadcode/remover.rb#549 +class Spoom::Deadcode::Remover::NodeFinder < ::Spoom::Visitor + # source://spoom//lib/spoom/deadcode/remover.rb#621 + sig { params(location: ::Spoom::Location, kind: T.nilable(::Spoom::Deadcode::Definition::Kind)).void } + def initialize(location, kind); end + + # source://spoom//lib/spoom/deadcode/remover.rb#615 + sig { returns(T.nilable(::Prism::Node)) } + def node; end + + # source://spoom//lib/spoom/deadcode/remover.rb#618 + sig { returns(T::Array[::Prism::Node]) } + def nodes_nesting; end + + # source://spoom//lib/spoom/deadcode/remover.rb#630 + sig { override.params(node: T.nilable(::Prism::Node)).void } + def visit(node); end + + class << self + # source://spoom//lib/spoom/deadcode/remover.rb#556 + sig do + params( + source: ::String, + location: ::Spoom::Location, + kind: T.nilable(::Spoom::Deadcode::Definition::Kind) + ).returns(::Spoom::Deadcode::Remover::NodeContext) + end + def find(source, location, kind); end + + # source://spoom//lib/spoom/deadcode/remover.rb#590 + sig { params(node: ::Prism::Node, kind: ::Spoom::Deadcode::Definition::Kind).returns(T::Boolean) } + def node_match_kind?(node, kind); end + end +end + +# source://spoom//lib/spoom/deadcode/remover.rb#29 +class Spoom::Deadcode::Remover::NodeRemover + # source://spoom//lib/spoom/deadcode/remover.rb#36 + sig do + params( + source: ::String, + kind: T.nilable(::Spoom::Deadcode::Definition::Kind), + location: ::Spoom::Location + ).void + end + def initialize(source, kind, location); end + + # source://spoom//lib/spoom/deadcode/remover.rb#46 + sig { void } + def apply_edit; end + + # source://spoom//lib/spoom/deadcode/remover.rb#33 + sig { returns(::String) } + def new_source; end + + private + + # source://spoom//lib/spoom/deadcode/remover.rb#153 + sig { params(context: ::Spoom::Deadcode::Remover::NodeContext).void } + def delete_attr_accessor(context); end + + # source://spoom//lib/spoom/deadcode/remover.rb#331 + sig { params(start_char: ::Integer, end_char: ::Integer).void } + def delete_chars(start_char, end_char); end + + # source://spoom//lib/spoom/deadcode/remover.rb#73 + sig { params(context: ::Spoom::Deadcode::Remover::NodeContext).void } + def delete_constant_assignment(context); end + + # source://spoom//lib/spoom/deadcode/remover.rb#324 + sig { params(start_line: ::Integer, end_line: ::Integer).void } + def delete_lines(start_line, end_line); end + + # source://spoom//lib/spoom/deadcode/remover.rb#261 + sig { params(context: ::Spoom::Deadcode::Remover::NodeContext).void } + def delete_node_and_comments_and_sigs(context); end + + # source://spoom//lib/spoom/deadcode/remover.rb#218 + sig do + params( + node: ::Prism::Node, + send_context: ::Spoom::Deadcode::Remover::NodeContext, + was_removed: T::Boolean + ).void + end + def insert_accessor(node, send_context, was_removed:); end + + # source://spoom//lib/spoom/deadcode/remover.rb#336 + sig { params(start_char: ::Integer, end_char: ::Integer, replacement: ::String).void } + def replace_chars(start_char, end_char, replacement); end + + # source://spoom//lib/spoom/deadcode/remover.rb#341 + sig do + params( + node: ::Prism::CallNode, + name: ::String, + kind: T.nilable(::Spoom::Deadcode::Definition::Kind) + ).returns(::String) + end + def transform_sig(node, name:, kind:); end +end + +# An abstraction to simplify handling of Prism::CallNode nodes. +# +# source://spoom//lib/spoom/deadcode/send.rb#7 +class Spoom::Deadcode::Send < ::T::Struct + const :node, ::Prism::CallNode + const :name, ::String + const :recv, T.nilable(::Prism::Node), default: T.unsafe(nil) + const :args, T::Array[::Prism::Node], default: T.unsafe(nil) + const :block, T.nilable(::Prism::Node), default: T.unsafe(nil) + const :location, ::Spoom::Location + + # source://spoom//lib/spoom/deadcode/send.rb#22 + sig do + type_parameters(:T) + .params( + arg_type: T::Class[T.type_parameter(:T)], + block: T.proc.params(arg: T.type_parameter(:T)).void + ).void + end + def each_arg(arg_type, &block); end + + # source://spoom//lib/spoom/deadcode/send.rb#29 + sig { params(block: T.proc.params(key: ::Prism::Node, value: T.nilable(::Prism::Node)).void).void } + def each_arg_assoc(&block); end + + class << self + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://spoom//lib/spoom.rb#12 +class Spoom::Error < ::StandardError; end + +# source://spoom//lib/spoom/context/exec.rb#5 +class Spoom::ExecResult < ::T::Struct + const :out, ::String + const :err, T.nilable(::String) + const :status, T::Boolean + const :exit_code, ::Integer + + # source://spoom//lib/spoom/context/exec.rb#14 + sig { returns(::String) } + def to_s; end + + class << self + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://spoom//lib/spoom/file_collector.rb#5 +class Spoom::FileCollector + # Initialize a new file collector + # + # If `allow_extensions` is empty, all files are collected. + # If `allow_extensions` is an array of extensions, only files with one of these extensions are collected. + # + # If `allow_mime_types` is empty, all files are collected. + # If `allow_mime_types` is an array of mimetypes, files without an extension are collected if their mimetype is in + # the list. + # + # source://spoom//lib/spoom/file_collector.rb#26 + sig do + params( + allow_extensions: T::Array[::String], + allow_mime_types: T::Array[::String], + exclude_patterns: T::Array[::String] + ).void + end + def initialize(allow_extensions: T.unsafe(nil), allow_mime_types: T.unsafe(nil), exclude_patterns: T.unsafe(nil)); end + + # source://spoom//lib/spoom/file_collector.rb#9 + sig { returns(T::Array[::String]) } + def files; end + + # source://spoom//lib/spoom/file_collector.rb#39 + sig { params(path: ::String).void } + def visit_path(path); end + + # source://spoom//lib/spoom/file_collector.rb#34 + sig { params(paths: T::Array[::String]).void } + def visit_paths(paths); end + + private + + # source://spoom//lib/spoom/file_collector.rb#56 + sig { params(path: ::String).returns(::String) } + def clean_path(path); end + + # source://spoom//lib/spoom/file_collector.rb#73 + sig { params(path: ::String).returns(T::Boolean) } + def excluded_file?(path); end + + # source://spoom//lib/spoom/file_collector.rb#88 + sig { params(path: ::String).returns(T::Boolean) } + def excluded_path?(path); end + + # source://spoom//lib/spoom/file_collector.rb#97 + sig { params(path: ::String).returns(T.nilable(::String)) } + def mime_type_for(path); end + + # source://spoom//lib/spoom/file_collector.rb#68 + sig { params(path: ::String).void } + def visit_directory(path); end + + # source://spoom//lib/spoom/file_collector.rb#61 + sig { params(path: ::String).void } + def visit_file(path); end +end + +# Build a file hierarchy from a set of file paths. +# +# source://spoom//lib/spoom/file_tree.rb#6 +class Spoom::FileTree + # source://spoom//lib/spoom/file_tree.rb#10 + sig { params(paths: T::Enumerable[::String]).void } + def initialize(paths = T.unsafe(nil)); end + + # Add a `path` to the tree + # + # This will create all nodes until the root of `path`. + # + # source://spoom//lib/spoom/file_tree.rb#25 + sig { params(path: ::String).returns(::Spoom::FileTree::Node) } + def add_path(path); end + + # Add all `paths` to the tree + # + # source://spoom//lib/spoom/file_tree.rb#17 + sig { params(paths: T::Enumerable[::String]).void } + def add_paths(paths); end + + # All the nodes in this tree + # + # source://spoom//lib/spoom/file_tree.rb#45 + sig { returns(T::Array[::Spoom::FileTree::Node]) } + def nodes; end + + # Return a map of typing scores for each node in the tree + # + # source://spoom//lib/spoom/file_tree.rb#59 + sig { params(context: ::Spoom::Context).returns(T::Hash[::Spoom::FileTree::Node, ::Float]) } + def nodes_strictness_scores(context); end + + # All the paths in this tree + # + # source://spoom//lib/spoom/file_tree.rb#53 + sig { returns(T::Array[::String]) } + def paths; end + + # Return a map of typing scores for each path in the tree + # + # source://spoom//lib/spoom/file_tree.rb#67 + sig { params(context: ::Spoom::Context).returns(T::Hash[::String, ::Float]) } + def paths_strictness_scores(context); end + + # source://spoom//lib/spoom/file_tree.rb#72 + sig { params(out: T.any(::IO, ::StringIO), colors: T::Boolean).void } + def print(out: T.unsafe(nil), colors: T.unsafe(nil)); end + + # All root nodes + # + # source://spoom//lib/spoom/file_tree.rb#39 + sig { returns(T::Array[::Spoom::FileTree::Node]) } + def roots; end +end + +# A visitor that collects all the nodes in a tree +# +# source://spoom//lib/spoom/file_tree.rb#124 +class Spoom::FileTree::CollectNodes < ::Spoom::FileTree::Visitor + # source://spoom//lib/spoom/file_tree.rb#131 + sig { void } + def initialize; end + + # source://spoom//lib/spoom/file_tree.rb#128 + sig { returns(T::Array[::Spoom::FileTree::Node]) } + def nodes; end + + # source://spoom//lib/spoom/file_tree.rb#137 + sig { override.params(node: ::Spoom::FileTree::Node).void } + def visit_node(node); end +end + +# A visitor that collects the typing score of each node in a tree +# +# source://spoom//lib/spoom/file_tree.rb#167 +class Spoom::FileTree::CollectScores < ::Spoom::FileTree::CollectStrictnesses + # source://spoom//lib/spoom/file_tree.rb#174 + sig { params(context: ::Spoom::Context).void } + def initialize(context); end + + # source://spoom//lib/spoom/file_tree.rb#171 + sig { returns(T::Hash[::Spoom::FileTree::Node, ::Float]) } + def scores; end + + # source://spoom//lib/spoom/file_tree.rb#181 + sig { override.params(node: ::Spoom::FileTree::Node).void } + def visit_node(node); end + + private + + # source://spoom//lib/spoom/file_tree.rb#190 + sig { params(node: ::Spoom::FileTree::Node).returns(::Float) } + def node_score(node); end + + # source://spoom//lib/spoom/file_tree.rb#199 + sig { params(strictness: T.nilable(::String)).returns(::Float) } + def strictness_score(strictness); end +end + +# A visitor that collects the strictness of each node in a tree +# +# source://spoom//lib/spoom/file_tree.rb#144 +class Spoom::FileTree::CollectStrictnesses < ::Spoom::FileTree::Visitor + # source://spoom//lib/spoom/file_tree.rb#151 + sig { params(context: ::Spoom::Context).void } + def initialize(context); end + + # source://spoom//lib/spoom/file_tree.rb#148 + sig { returns(T::Hash[::Spoom::FileTree::Node, T.nilable(::String)]) } + def strictnesses; end + + # source://spoom//lib/spoom/file_tree.rb#158 + sig { override.params(node: ::Spoom::FileTree::Node).void } + def visit_node(node); end +end + +# A node representing either a file or a directory inside a FileTree +# +# source://spoom//lib/spoom/file_tree.rb#78 +class Spoom::FileTree::Node < ::T::Struct + const :parent, T.nilable(::Spoom::FileTree::Node) + const :name, ::String + const :children, T::Hash[::String, ::Spoom::FileTree::Node], default: T.unsafe(nil) + + # Full path to this node from root + # + # source://spoom//lib/spoom/file_tree.rb#92 + sig { returns(::String) } + def path; end + + class << self + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# An internal class used to print a FileTree +# +# See `FileTree#print` +# +# source://spoom//lib/spoom/file_tree.rb#212 +class Spoom::FileTree::Printer < ::Spoom::FileTree::Visitor + # source://spoom//lib/spoom/file_tree.rb#222 + sig do + params( + strictnesses: T::Hash[::Spoom::FileTree::Node, T.nilable(::String)], + out: T.any(::IO, ::StringIO), + colors: T::Boolean + ).void + end + def initialize(strictnesses, out: T.unsafe(nil), colors: T.unsafe(nil)); end + + # source://spoom//lib/spoom/file_tree.rb#230 + sig { override.params(node: ::Spoom::FileTree::Node).void } + def visit_node(node); end + + private + + # source://spoom//lib/spoom/file_tree.rb#255 + sig { params(strictness: T.nilable(::String)).returns(::Spoom::Color) } + def strictness_color(strictness); end +end + +# An abstract visitor for FileTree +# +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/file_tree.rb#101 +class Spoom::FileTree::Visitor + abstract! + + # source://spoom//lib/spoom/file_tree.rb#113 + sig { params(node: ::Spoom::FileTree::Node).void } + def visit_node(node); end + + # source://spoom//lib/spoom/file_tree.rb#118 + sig { params(nodes: T::Array[::Spoom::FileTree::Node]).void } + def visit_nodes(nodes); end + + # source://spoom//lib/spoom/file_tree.rb#108 + sig { params(tree: ::Spoom::FileTree).void } + def visit_tree(tree); end +end + +# source://spoom//lib/spoom/context/git.rb#5 +module Spoom::Git; end + +# source://spoom//lib/spoom/context/git.rb#6 +class Spoom::Git::Commit < ::T::Struct + const :sha, ::String + const :time, ::Time + + # source://spoom//lib/spoom/context/git.rb#27 + sig { returns(::Integer) } + def timestamp; end + + class << self + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + + # Parse a line formatted as `%h %at` into a `Commit` + # + # source://spoom//lib/spoom/context/git.rb#14 + sig { params(string: ::String).returns(T.nilable(::Spoom::Git::Commit)) } + def parse_line(string); end + end +end + +# source://spoom//lib/spoom/sorbet/lsp/base.rb#5 +module Spoom::LSP; end + +# source://spoom//lib/spoom/sorbet/lsp.rb#13 +class Spoom::LSP::Client + # source://spoom//lib/spoom/sorbet/lsp.rb#17 + sig { params(sorbet_bin: ::String, sorbet_args: ::String, path: ::String).void } + def initialize(sorbet_bin, *sorbet_args, path: T.unsafe(nil)); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#229 + sig { void } + def close; end + + # source://spoom//lib/spoom/sorbet/lsp.rb#131 + sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T::Array[::Spoom::LSP::Location]) } + def definitions(uri, line, column); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#212 + sig { params(uri: ::String).returns(T::Array[::Spoom::LSP::DocumentSymbol]) } + def document_symbols(uri); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#89 + sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T.nilable(::Spoom::LSP::Hover)) } + def hover(uri, line, column); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#27 + sig { returns(::Integer) } + def next_id; end + + # LSP requests + # + # @raise [Error::AlreadyOpen] + # + # source://spoom//lib/spoom/sorbet/lsp.rb#72 + sig { params(workspace_path: ::String).void } + def open(workspace_path); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#54 + sig { returns(T.nilable(T::Hash[T.untyped, T.untyped])) } + def read; end + + # @raise [Error::BadHeaders] + # + # source://spoom//lib/spoom/sorbet/lsp.rb#43 + sig { returns(T.nilable(::String)) } + def read_raw; end + + # source://spoom//lib/spoom/sorbet/lsp.rb#173 + sig do + params( + uri: ::String, + line: ::Integer, + column: ::Integer, + include_decl: T::Boolean + ).returns(T::Array[::Spoom::LSP::Location]) + end + def references(uri, line, column, include_decl = T.unsafe(nil)); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#37 + sig { params(message: ::Spoom::LSP::Message).returns(T.nilable(T::Hash[T.untyped, T.untyped])) } + def send(message); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#32 + sig { params(json_string: ::String).void } + def send_raw(json_string); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#110 + sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T::Array[::Spoom::LSP::SignatureHelp]) } + def signatures(uri, line, column); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#197 + sig { params(query: ::String).returns(T::Array[::Spoom::LSP::DocumentSymbol]) } + def symbols(query); end + + # source://spoom//lib/spoom/sorbet/lsp.rb#152 + sig { params(uri: ::String, line: ::Integer, column: ::Integer).returns(T::Array[::Spoom::LSP::Location]) } + def type_definitions(uri, line, column); end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#178 +class Spoom::LSP::Diagnostic < ::T::Struct + include ::Spoom::LSP::PrintableSymbol + + const :range, ::Spoom::LSP::Range + const :code, ::Integer + const :message, ::String + const :information, ::Object + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#202 + sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#207 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#191 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Diagnostic) } + def from_json(json); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#212 +class Spoom::LSP::DocumentSymbol < ::T::Struct + include ::Spoom::LSP::PrintableSymbol + + const :name, ::String + const :detail, T.nilable(::String) + const :kind, ::Integer + const :location, T.nilable(::Spoom::LSP::Location) + const :range, T.nilable(::Spoom::LSP::Range) + const :children, T::Array[::Spoom::LSP::DocumentSymbol] + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#240 + sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#272 + sig { returns(::String) } + def kind_string; end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#267 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#227 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::DocumentSymbol) } + def from_json(json); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#276 +Spoom::LSP::DocumentSymbol::SYMBOL_KINDS = T.let(T.unsafe(nil), Hash) + +# source://spoom//lib/spoom/sorbet/lsp/errors.rb#6 +class Spoom::LSP::Error < ::Spoom::Error; end + +# source://spoom//lib/spoom/sorbet/lsp/errors.rb#7 +class Spoom::LSP::Error::AlreadyOpen < ::Spoom::LSP::Error; end + +# source://spoom//lib/spoom/sorbet/lsp/errors.rb#8 +class Spoom::LSP::Error::BadHeaders < ::Spoom::LSP::Error; end + +# source://spoom//lib/spoom/sorbet/lsp/errors.rb#10 +class Spoom::LSP::Error::Diagnostics < ::Spoom::LSP::Error + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#32 + sig { params(uri: ::String, diagnostics: T::Array[::Spoom::LSP::Diagnostic]).void } + def initialize(uri, diagnostics); end + + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#17 + sig { returns(T::Array[::Spoom::LSP::Diagnostic]) } + def diagnostics; end + + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#14 + sig { returns(::String) } + def uri; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#23 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Error::Diagnostics) } + def from_json(json); end + end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#19 +class Spoom::LSP::Hover < ::T::Struct + include ::Spoom::LSP::PrintableSymbol + + const :contents, ::String + const :range, T.nilable(T::Range[T.untyped]) + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#39 + sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#45 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#30 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Hover) } + def from_json(json); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#112 +class Spoom::LSP::Location < ::T::Struct + include ::Spoom::LSP::PrintableSymbol + + const :uri, ::String + const :range, ::Spoom::LSP::Range + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#132 + sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#138 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#123 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Location) } + def from_json(json); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# A general message as defined by JSON-RPC. +# +# The language server protocol always uses `"2.0"` as the `jsonrpc` version. +# +# source://spoom//lib/spoom/sorbet/lsp/base.rb#12 +class Spoom::LSP::Message + # source://spoom//lib/spoom/sorbet/lsp/base.rb#16 + sig { void } + def initialize; end + + # source://spoom//lib/spoom/sorbet/lsp/base.rb#21 + sig { returns(T::Hash[T.untyped, T.untyped]) } + def as_json; end + + # source://spoom//lib/spoom/sorbet/lsp/base.rb#29 + sig { params(args: T.untyped).returns(::String) } + def to_json(*args); end +end + +# A notification message. +# +# A processed notification message must not send a response back. They work like events. +# +# source://spoom//lib/spoom/sorbet/lsp/base.rb#58 +class Spoom::LSP::Notification < ::Spoom::LSP::Message + # source://spoom//lib/spoom/sorbet/lsp/base.rb#68 + sig { params(method: ::String, params: T::Hash[T.untyped, T.untyped]).void } + def initialize(method, params); end + + # source://spoom//lib/spoom/sorbet/lsp/base.rb#62 + sig { returns(::String) } + def method; end + + # source://spoom//lib/spoom/sorbet/lsp/base.rb#65 + sig { returns(T::Hash[T.untyped, T.untyped]) } + def params; end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#50 +class Spoom::LSP::Position < ::T::Struct + include ::Spoom::LSP::PrintableSymbol + + const :line, ::Integer + const :char, ::Integer + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#70 + sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#75 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#61 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Position) } + def from_json(json); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# @abstract Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#9 +module Spoom::LSP::PrintableSymbol + interface! + + # @abstract + # + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#16 + sig { abstract.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#80 +class Spoom::LSP::Range < ::T::Struct + include ::Spoom::LSP::PrintableSymbol + + const :start, ::Spoom::LSP::Position + const :end, ::Spoom::LSP::Position + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#100 + sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#107 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#91 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::Range) } + def from_json(json); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# A request message to describe a request between the client and the server. +# +# Every processed request must send a response back to the sender of the request. +# +# source://spoom//lib/spoom/sorbet/lsp/base.rb#37 +class Spoom::LSP::Request < ::Spoom::LSP::Message + # source://spoom//lib/spoom/sorbet/lsp/base.rb#47 + sig { params(id: ::Integer, method: ::String, params: T::Hash[T.untyped, T.untyped]).void } + def initialize(id, method, params); end + + # source://spoom//lib/spoom/sorbet/lsp/base.rb#41 + sig { returns(::Integer) } + def id; end + + # source://spoom//lib/spoom/sorbet/lsp/base.rb#44 + sig { returns(T::Hash[T.untyped, T.untyped]) } + def params; end +end + +# source://spoom//lib/spoom/sorbet/lsp/errors.rb#40 +class Spoom::LSP::ResponseError < ::Spoom::LSP::Error + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#63 + sig { params(code: ::Integer, message: ::String, data: T::Hash[T.untyped, T.untyped]).void } + def initialize(code, message, data); end + + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#44 + sig { returns(::Integer) } + def code; end + + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#47 + sig { returns(T::Hash[T.untyped, T.untyped]) } + def data; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/errors.rb#53 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::ResponseError) } + def from_json(json); end + end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#143 +class Spoom::LSP::SignatureHelp < ::T::Struct + include ::Spoom::LSP::PrintableSymbol + + const :label, T.nilable(::String) + const :doc, ::Object + const :params, T::Array[T.untyped] + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#165 + sig { override.params(printer: ::Spoom::LSP::SymbolPrinter).void } + def accept_printer(printer); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#173 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#155 + sig { params(json: T::Hash[T.untyped, T.untyped]).returns(::Spoom::LSP::SignatureHelp) } + def from_json(json); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://spoom//lib/spoom/sorbet/lsp/structures.rb#309 +class Spoom::LSP::SymbolPrinter < ::Spoom::Printer + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#326 + sig do + params( + out: T.any(::IO, ::StringIO), + colors: T::Boolean, + indent_level: ::Integer, + prefix: T.nilable(::String) + ).void + end + def initialize(out: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil), prefix: T.unsafe(nil)); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#348 + sig { params(uri: ::String).returns(::String) } + def clean_uri(uri); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#316 + sig { returns(T.nilable(::String)) } + def prefix; end + + # @return [String, nil] + # + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#316 + def prefix=(_arg0); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#356 + sig { params(objects: T::Array[::Spoom::LSP::PrintableSymbol]).void } + def print_list(objects); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#336 + sig { params(object: T.nilable(::Spoom::LSP::PrintableSymbol)).void } + def print_object(object); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#343 + sig { params(objects: T::Array[::Spoom::LSP::PrintableSymbol]).void } + def print_objects(objects); end + + # source://spoom//lib/spoom/sorbet/lsp/structures.rb#313 + sig { returns(T::Set[::Integer]) } + def seen; end +end + +# source://spoom//lib/spoom/location.rb#5 +class Spoom::Location + include ::Comparable + + # @raise [LocationError] + # + # source://spoom//lib/spoom/location.rb#73 + sig do + params( + file: ::String, + start_line: T.nilable(::Integer), + start_column: T.nilable(::Integer), + end_line: T.nilable(::Integer), + end_column: T.nilable(::Integer) + ).void + end + def initialize(file, start_line: T.unsafe(nil), start_column: T.unsafe(nil), end_line: T.unsafe(nil), end_column: T.unsafe(nil)); end + + # source://spoom//lib/spoom/location.rb#106 + sig { override.params(other: ::BasicObject).returns(T.nilable(::Integer)) } + def <=>(other); end + + # @return [Integer, nil] + # + # source://spoom//lib/spoom/location.rb#62 + def end_column; end + + # @return [Integer, nil] + # + # source://spoom//lib/spoom/location.rb#62 + def end_line; end + + # source://spoom//lib/spoom/location.rb#59 + sig { returns(::String) } + def file; end + + # source://spoom//lib/spoom/location.rb#93 + sig { params(other: ::Spoom::Location).returns(T::Boolean) } + def include?(other); end + + # @return [Integer, nil] + # + # source://spoom//lib/spoom/location.rb#62 + def start_column; end + + # source://spoom//lib/spoom/location.rb#62 + sig { returns(T.nilable(::Integer)) } + def start_line; end + + # source://spoom//lib/spoom/location.rb#129 + sig { returns(::String) } + def to_s; end + + class << self + # source://spoom//lib/spoom/location.rb#47 + sig { params(file: ::String, location: ::Prism::Location).returns(::Spoom::Location) } + def from_prism(file, location); end + + # @raise [LocationError] + # + # source://spoom//lib/spoom/location.rb#16 + sig { params(location_string: ::String).returns(::Spoom::Location) } + def from_string(location_string); end + end +end + +# source://spoom//lib/spoom/location.rb#10 +class Spoom::Location::LocationError < ::Spoom::Error; end + +# source://spoom//lib/spoom/model/model.rb#5 +class Spoom::Model + # source://spoom//lib/spoom/model/model.rb#238 + sig { void } + def initialize; end + + # Get a symbol by it's full name + # + # Raises an error if the symbol is not found + # + # @raise [Error] + # + # source://spoom//lib/spoom/model/model.rb#247 + sig { params(full_name: ::String).returns(::Spoom::Model::Symbol) } + def [](full_name); end + + # source://spoom//lib/spoom/model/model.rb#296 + sig { void } + def finalize!; end + + # Register a new symbol by it's full name + # + # If the symbol already exists, it will be returned. + # + # source://spoom//lib/spoom/model/model.rb#258 + sig { params(full_name: ::String).returns(::Spoom::Model::Symbol) } + def register_symbol(full_name); end + + # source://spoom//lib/spoom/model/model.rb#263 + sig { params(full_name: ::String, context: ::Spoom::Model::Symbol).returns(::Spoom::Model::Symbol) } + def resolve_symbol(full_name, context:); end + + # source://spoom//lib/spoom/model/model.rb#290 + sig { params(symbol: ::Spoom::Model::Symbol).returns(T::Array[::Spoom::Model::Symbol]) } + def subtypes(symbol); end + + # source://spoom//lib/spoom/model/model.rb#284 + sig { params(symbol: ::Spoom::Model::Symbol).returns(T::Array[::Spoom::Model::Symbol]) } + def supertypes(symbol); end + + # All the symbols registered in this model + # + # source://spoom//lib/spoom/model/model.rb#232 + sig { returns(T::Hash[::String, ::Spoom::Model::Symbol]) } + def symbols; end + + # source://spoom//lib/spoom/model/model.rb#235 + sig { returns(Spoom::Poset[::Spoom::Model::Symbol]) } + def symbols_hierarchy; end + + private + + # source://spoom//lib/spoom/model/model.rb#303 + sig { void } + def compute_symbols_hierarchy!; end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/model/model.rb#179 +class Spoom::Model::Attr < ::Spoom::Model::Property + abstract! +end + +# source://spoom//lib/spoom/model/model.rb#185 +class Spoom::Model::AttrAccessor < ::Spoom::Model::Attr; end + +# source://spoom//lib/spoom/model/model.rb#183 +class Spoom::Model::AttrReader < ::Spoom::Model::Attr; end + +# source://spoom//lib/spoom/model/model.rb#184 +class Spoom::Model::AttrWriter < ::Spoom::Model::Attr; end + +# Populate a Model by visiting the nodes from a Ruby file +# +# source://spoom//lib/spoom/model/builder.rb#7 +class Spoom::Model::Builder < ::Spoom::Model::NamespaceVisitor + # source://spoom//lib/spoom/model/builder.rb#11 + sig { params(model: ::Spoom::Model, file: ::String).void } + def initialize(model, file); end + + # Accessors + # + # source://spoom//lib/spoom/model/builder.rb#146 + sig { override.params(node: ::Prism::CallNode).void } + def visit_call_node(node); end + + # Classes + # + # source://spoom//lib/spoom/model/builder.rb#24 + sig { override.params(node: ::Prism::ClassNode).void } + def visit_class_node(node); end + + # Constants + # + # source://spoom//lib/spoom/model/builder.rb#71 + sig { override.params(node: ::Prism::ConstantPathWriteNode).void } + def visit_constant_path_write_node(node); end + + # source://spoom//lib/spoom/model/builder.rb#92 + sig { override.params(node: ::Prism::ConstantWriteNode).void } + def visit_constant_write_node(node); end + + # Methods + # + # source://spoom//lib/spoom/model/builder.rb#127 + sig { override.params(node: ::Prism::DefNode).void } + def visit_def_node(node); end + + # Modules + # + # source://spoom//lib/spoom/model/builder.rb#55 + sig { override.params(node: ::Prism::ModuleNode).void } + def visit_module_node(node); end + + # source://spoom//lib/spoom/model/builder.rb#106 + sig { override.params(node: ::Prism::MultiWriteNode).void } + def visit_multi_write_node(node); end + + # source://spoom//lib/spoom/model/builder.rb#39 + sig { override.params(node: ::Prism::SingletonClassNode).void } + def visit_singleton_class_node(node); end + + private + + # source://spoom//lib/spoom/model/builder.rb#234 + sig { returns(T::Array[::Spoom::Model::Sig]) } + def collect_sigs; end + + # source://spoom//lib/spoom/model/builder.rb#229 + sig { returns(::Spoom::Model::Visibility) } + def current_visibility; end + + # source://spoom//lib/spoom/model/builder.rb#241 + sig { params(node: ::Prism::Node).returns(::Spoom::Location) } + def node_location(node); end +end + +# source://spoom//lib/spoom/model/model.rb#117 +class Spoom::Model::Class < ::Spoom::Model::Namespace + # source://spoom//lib/spoom/model/model.rb#129 + sig do + params( + symbol: ::Spoom::Model::Symbol, + owner: T.nilable(::Spoom::Model::Namespace), + location: ::Spoom::Location, + superclass_name: T.nilable(::String) + ).void + end + def initialize(symbol, owner:, location:, superclass_name: T.unsafe(nil)); end + + # source://spoom//lib/spoom/model/model.rb#119 + sig { returns(T.nilable(::String)) } + def superclass_name; end + + # @return [String, nil] + # + # source://spoom//lib/spoom/model/model.rb#119 + def superclass_name=(_arg0); end +end + +# source://spoom//lib/spoom/model/model.rb#138 +class Spoom::Model::Constant < ::Spoom::Model::SymbolDef + # source://spoom//lib/spoom/model/model.rb#143 + sig do + params( + symbol: ::Spoom::Model::Symbol, + owner: T.nilable(::Spoom::Model::Namespace), + location: ::Spoom::Location, + value: ::String + ).void + end + def initialize(symbol, owner:, location:, value:); end + + # source://spoom//lib/spoom/model/model.rb#140 + sig { returns(::String) } + def value; end +end + +# source://spoom//lib/spoom/model/model.rb#8 +class Spoom::Model::Error < ::Spoom::Error; end + +# source://spoom//lib/spoom/model/model.rb#213 +class Spoom::Model::Extend < ::Spoom::Model::Mixin; end + +# source://spoom//lib/spoom/model/model.rb#211 +class Spoom::Model::Include < ::Spoom::Model::Mixin; end + +# source://spoom//lib/spoom/model/model.rb#177 +class Spoom::Model::Method < ::Spoom::Model::Property; end + +# A mixin (include, prepend, extend) to a namespace +# +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/model/model.rb#196 +class Spoom::Model::Mixin + abstract! + + # source://spoom//lib/spoom/model/model.rb#206 + sig { params(name: ::String).void } + def initialize(name); end + + # source://spoom//lib/spoom/model/model.rb#203 + sig { returns(::String) } + def name; end +end + +# source://spoom//lib/spoom/model/model.rb#136 +class Spoom::Model::Module < ::Spoom::Model::Namespace; end + +# A class or module +# +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/model/model.rb#97 +class Spoom::Model::Namespace < ::Spoom::Model::SymbolDef + abstract! + + # source://spoom//lib/spoom/model/model.rb#107 + sig do + params( + symbol: ::Spoom::Model::Symbol, + owner: T.nilable(::Spoom::Model::Namespace), + location: ::Spoom::Location + ).void + end + def initialize(symbol, owner:, location:); end + + # source://spoom//lib/spoom/model/model.rb#101 + sig { returns(T::Array[::Spoom::Model::SymbolDef]) } + def children; end + + # source://spoom//lib/spoom/model/model.rb#104 + sig { returns(T::Array[::Spoom::Model::Mixin]) } + def mixins; end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/model/namespace_visitor.rb#6 +class Spoom::Model::NamespaceVisitor < ::Spoom::Visitor + abstract! + + # source://spoom//lib/spoom/model/namespace_visitor.rb#12 + sig { void } + def initialize; end + + # source://spoom//lib/spoom/model/namespace_visitor.rb#19 + sig { override.params(node: T.nilable(::Prism::Node)).void } + def visit(node); end +end + +# source://spoom//lib/spoom/model/model.rb#212 +class Spoom::Model::Prepend < ::Spoom::Model::Mixin; end + +# A method or an attribute accessor +# +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/model/model.rb#151 +class Spoom::Model::Property < ::Spoom::Model::SymbolDef + abstract! + + # source://spoom//lib/spoom/model/model.rb#169 + sig do + params( + symbol: ::Spoom::Model::Symbol, + owner: T.nilable(::Spoom::Model::Namespace), + location: ::Spoom::Location, + visibility: ::Spoom::Model::Visibility, + sigs: T::Array[::Spoom::Model::Sig] + ).void + end + def initialize(symbol, owner:, location:, visibility:, sigs: T.unsafe(nil)); end + + # source://spoom//lib/spoom/model/model.rb#158 + sig { returns(T::Array[::Spoom::Model::Sig]) } + def sigs; end + + # source://spoom//lib/spoom/model/model.rb#155 + sig { returns(::Spoom::Model::Visibility) } + def visibility; end +end + +# A reference to something that looks like a constant or a method +# +# Constants could be classes, modules, or actual constants. +# Methods could be accessors, instance or class methods, aliases, etc. +# +# source://spoom//lib/spoom/model/reference.rb#10 +class Spoom::Model::Reference < ::T::Struct + const :kind, ::Spoom::Model::Reference::Kind + const :name, ::String + const :location, ::Spoom::Location + + # source://spoom//lib/spoom/model/reference.rb#39 + sig { returns(T::Boolean) } + def constant?; end + + # source://spoom//lib/spoom/model/reference.rb#44 + sig { returns(T::Boolean) } + def method?; end + + class << self + # source://spoom//lib/spoom/model/reference.rb#24 + sig { params(name: ::String, location: ::Spoom::Location).returns(::Spoom::Model::Reference) } + def constant(name, location); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + + # source://spoom//lib/spoom/model/reference.rb#29 + sig { params(name: ::String, location: ::Spoom::Location).returns(::Spoom::Model::Reference) } + def method(name, location); end + end +end + +# source://spoom//lib/spoom/model/reference.rb#13 +class Spoom::Model::Reference::Kind < ::T::Enum + enums do + Constant = new + Method = new + end +end + +# Visit a file to collect all the references to constants and methods +# +# source://spoom//lib/spoom/model/references_visitor.rb#7 +class Spoom::Model::ReferencesVisitor < ::Spoom::Visitor + # source://spoom//lib/spoom/model/references_visitor.rb#14 + sig { params(file: ::String).void } + def initialize(file); end + + # source://spoom//lib/spoom/model/references_visitor.rb#11 + sig { returns(T::Array[::Spoom::Model::Reference]) } + def references; end + + # source://spoom//lib/spoom/model/references_visitor.rb#22 + sig { override.params(node: ::Prism::AliasMethodNode).void } + def visit_alias_method_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#27 + sig { override.params(node: ::Prism::AndNode).void } + def visit_and_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#33 + sig { override.params(node: ::Prism::BlockArgumentNode).void } + def visit_block_argument_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#44 + sig { override.params(node: ::Prism::CallAndWriteNode).void } + def visit_call_and_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#68 + sig { override.params(node: ::Prism::CallNode).void } + def visit_call_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#52 + sig { override.params(node: ::Prism::CallOperatorWriteNode).void } + def visit_call_operator_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#60 + sig { override.params(node: ::Prism::CallOrWriteNode).void } + def visit_call_or_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#85 + sig { override.params(node: ::Prism::ClassNode).void } + def visit_class_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#91 + sig { override.params(node: ::Prism::ConstantAndWriteNode).void } + def visit_constant_and_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#97 + sig { override.params(node: ::Prism::ConstantOperatorWriteNode).void } + def visit_constant_operator_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#103 + sig { override.params(node: ::Prism::ConstantOrWriteNode).void } + def visit_constant_or_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#109 + sig { override.params(node: ::Prism::ConstantPathNode).void } + def visit_constant_path_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#115 + sig { override.params(node: ::Prism::ConstantPathWriteNode).void } + def visit_constant_path_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#121 + sig { override.params(node: ::Prism::ConstantReadNode).void } + def visit_constant_read_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#126 + sig { override.params(node: ::Prism::ConstantWriteNode).void } + def visit_constant_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#131 + sig { override.params(node: ::Prism::LocalVariableAndWriteNode).void } + def visit_local_variable_and_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#139 + sig { override.params(node: ::Prism::LocalVariableOperatorWriteNode).void } + def visit_local_variable_operator_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#147 + sig { override.params(node: ::Prism::LocalVariableOrWriteNode).void } + def visit_local_variable_or_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#155 + sig { override.params(node: ::Prism::LocalVariableWriteNode).void } + def visit_local_variable_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#161 + sig { override.params(node: ::Prism::ModuleNode).void } + def visit_module_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#166 + sig { override.params(node: ::Prism::MultiWriteNode).void } + def visit_multi_write_node(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#177 + sig { override.params(node: ::Prism::OrNode).void } + def visit_or_node(node); end + + private + + # source://spoom//lib/spoom/model/references_visitor.rb#195 + sig { params(node: ::Prism::Node).returns(::Spoom::Location) } + def node_location(node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#185 + sig { params(name: ::String, node: ::Prism::Node).void } + def reference_constant(name, node); end + + # source://spoom//lib/spoom/model/references_visitor.rb#190 + sig { params(name: ::String, node: ::Prism::Node).void } + def reference_method(name, node); end +end + +# A Sorbet signature (sig block) +# +# source://spoom//lib/spoom/model/model.rb#216 +class Spoom::Model::Sig + # source://spoom//lib/spoom/model/model.rb#223 + sig { params(string: ::String).void } + def initialize(string); end + + # source://spoom//lib/spoom/model/model.rb#220 + sig { returns(::String) } + def string; end +end + +# source://spoom//lib/spoom/model/model.rb#115 +class Spoom::Model::SingletonClass < ::Spoom::Model::Namespace; end + +# A Symbol is a uniquely named entity in the Ruby codebase +# +# A symbol can have multiple definitions, e.g. a class can be reopened. +# Sometimes a symbol can have multiple definitions of different types, +# e.g. `foo` method can be defined both as a method and as an attribute accessor. +# +# source://spoom//lib/spoom/model/model.rb#15 +class Spoom::Model::Symbol + # source://spoom//lib/spoom/model/model.rb#27 + sig { params(full_name: ::String).void } + def initialize(full_name); end + + # The definitions of this symbol (where it exists in the code) + # + # source://spoom//lib/spoom/model/model.rb#24 + sig { returns(T::Array[::Spoom::Model::SymbolDef]) } + def definitions; end + + # The full, unique name of this symbol + # + # source://spoom//lib/spoom/model/model.rb#20 + sig { returns(::String) } + def full_name; end + + # The short name of this symbol + # + # source://spoom//lib/spoom/model/model.rb#34 + sig { returns(::String) } + def name; end + + # source://spoom//lib/spoom/model/model.rb#39 + sig { returns(::String) } + def to_s; end +end + +# A SymbolDef is a definition of a Symbol +# +# It can be a class, module, constant, method, etc. +# A SymbolDef has a location pointing to the actual code that defines the symbol. +# +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://spoom//lib/spoom/model/model.rb#55 +class Spoom::Model::SymbolDef + abstract! + + # source://spoom//lib/spoom/model/model.rb#74 + sig do + params( + symbol: ::Spoom::Model::Symbol, + owner: T.nilable(::Spoom::Model::Namespace), + location: ::Spoom::Location + ).void + end + def initialize(symbol, owner:, location:); end + + # The full name of the symbol this definition belongs to + # + # source://spoom//lib/spoom/model/model.rb#85 + sig { returns(::String) } + def full_name; end + + # The actual code location of this definition + # + # source://spoom//lib/spoom/model/model.rb#71 + sig { returns(::Spoom::Location) } + def location; end + + # The short name of the symbol this definition belongs to + # + # source://spoom//lib/spoom/model/model.rb#91 + sig { returns(::String) } + def name; end + + # The enclosing namespace this definition belongs to + # + # source://spoom//lib/spoom/model/model.rb#67 + sig { returns(T.nilable(::Spoom::Model::Namespace)) } + def owner; end + + # The symbol this definition belongs to + # + # source://spoom//lib/spoom/model/model.rb#63 + sig { returns(::Spoom::Model::Symbol) } + def symbol; end +end + +# source://spoom//lib/spoom/model/model.rb#44 +class Spoom::Model::UnresolvedSymbol < ::Spoom::Model::Symbol + # source://spoom//lib/spoom/model/model.rb#46 + sig { override.returns(::String) } + def to_s; end +end + +# source://spoom//lib/spoom/model/model.rb#187 +class Spoom::Model::Visibility < ::T::Enum + enums do + Public = new + Protected = new + Private = new + end +end + +# source://spoom//lib/spoom/parse.rb#7 +class Spoom::ParseError < ::Spoom::Error; end + +# A Poset is a set of elements with a partial order relation. +# +# The partial order relation is a binary relation that is reflexive, antisymmetric, and transitive. +# It can be used to represent a hierarchy of classes or modules, the dependencies between gems, etc. +# +# source://spoom//lib/spoom/poset.rb#9 +class Spoom::Poset + extend T::Generic + + E = type_member { { upper: Object } } + + # source://spoom//lib/spoom/poset.rb#18 + sig { void } + def initialize; end + + # Get the POSet element for a given value + # + # Raises if the element is not found + # + # @raise [Error] + # + # source://spoom//lib/spoom/poset.rb#26 + sig { params(value: E).returns(Spoom::Poset::Element[E]) } + def [](value); end + + # Add a direct edge from one element to another + # + # Transitive edges (transitive closure) are automatically computed. + # Adds the elements if they don't exist. + # If the direct edge already exists, nothing is done. + # + # source://spoom//lib/spoom/poset.rb#54 + sig { params(from: E, to: E).void } + def add_direct_edge(from, to); end + + # Add an element to the POSet + # + # source://spoom//lib/spoom/poset.rb#35 + sig { params(value: E).returns(Spoom::Poset::Element[E]) } + def add_element(value); end + + # Is there a direct edge from `from` to `to`? + # + # source://spoom//lib/spoom/poset.rb#101 + sig { params(from: E, to: E).returns(T::Boolean) } + def direct_edge?(from, to); end + + # Is there an edge (direct or indirect) from `from` to `to`? + # + # source://spoom//lib/spoom/poset.rb#92 + sig { params(from: E, to: E).returns(T::Boolean) } + def edge?(from, to); end + + # Is the given value a element in the POSet? + # + # source://spoom//lib/spoom/poset.rb#44 + sig { params(value: E).returns(T::Boolean) } + def element?(value); end + + # Show the POSet as a DOT graph using xdot (used for debugging) + # + # source://spoom//lib/spoom/poset.rb#107 + sig { params(direct: T::Boolean, transitive: T::Boolean).void } + def show_dot(direct: T.unsafe(nil), transitive: T.unsafe(nil)); end + + # Return the POSet as a DOT graph + # + # source://spoom//lib/spoom/poset.rb#116 + sig { params(direct: T::Boolean, transitive: T::Boolean).returns(::String) } + def to_dot(direct: T.unsafe(nil), transitive: T.unsafe(nil)); end +end + +# An element in a POSet +# +# source://spoom//lib/spoom/poset.rb#136 +class Spoom::Poset::Element + extend T::Generic + include ::Comparable + + E = type_member { { upper: Object } } + + # source://spoom//lib/spoom/poset.rb#152 + sig { params(value: E).void } + def initialize(value); end + + # source://spoom//lib/spoom/poset.rb#161 + sig { params(other: T.untyped).returns(T.nilable(::Integer)) } + def <=>(other); end + + # Direct and indirect ancestors of this element + # + # source://spoom//lib/spoom/poset.rb#180 + sig { returns(T::Array[E]) } + def ancestors; end + + # Direct children of this element + # + # source://spoom//lib/spoom/poset.rb#186 + sig { returns(T::Array[E]) } + def children; end + + # Direct and indirect descendants of this element + # + # source://spoom//lib/spoom/poset.rb#192 + sig { returns(T::Array[E]) } + def descendants; end + + # Edges (direct and indirect) from this element to other elements in the same POSet + # + # @return [Set] + # + # source://spoom//lib/spoom/poset.rb#149 + def dfroms; end + + # Edges (direct and indirect) from this element to other elements in the same POSet + # + # source://spoom//lib/spoom/poset.rb#149 + sig { returns(T::Set[Spoom::Poset::Element[E]]) } + def dtos; end + + # Edges (direct and indirect) from this element to other elements in the same POSet + # + # @return [Set] + # + # source://spoom//lib/spoom/poset.rb#149 + def froms; end + + # Direct parents of this element + # + # source://spoom//lib/spoom/poset.rb#174 + sig { returns(T::Array[E]) } + def parents; end + + # Edges (direct and indirect) from this element to other elements in the same POSet + # + # @return [Set] + # + # source://spoom//lib/spoom/poset.rb#149 + def tos; end + + # The value held by this element + # + # source://spoom//lib/spoom/poset.rb#145 + sig { returns(E) } + def value; end +end + +# source://spoom//lib/spoom/poset.rb#13 +class Spoom::Poset::Error < ::Spoom::Error; end + +# source://spoom//lib/spoom/printer.rb#7 +class Spoom::Printer + include ::Spoom::Colorize + + # source://spoom//lib/spoom/printer.rb#17 + sig { params(out: T.any(::IO, ::StringIO), colors: T::Boolean, indent_level: ::Integer).void } + def initialize(out: T.unsafe(nil), colors: T.unsafe(nil), indent_level: T.unsafe(nil)); end + + # Colorize `string` with color if `@colors` + # + # source://spoom//lib/spoom/printer.rb#78 + sig { params(string: ::String, color: ::Spoom::Color).returns(::String) } + def colorize(string, *color); end + + # Decrease indent level + # + # source://spoom//lib/spoom/printer.rb#31 + sig { void } + def dedent; end + + # Increase indent level + # + # source://spoom//lib/spoom/printer.rb#25 + sig { void } + def indent; end + + # source://spoom//lib/spoom/printer.rb#14 + sig { returns(T.any(::IO, ::StringIO)) } + def out; end + + # @return [IO, StringIO] + # + # source://spoom//lib/spoom/printer.rb#14 + def out=(_arg0); end + + # Print `string` into `out` + # + # source://spoom//lib/spoom/printer.rb#37 + sig { params(string: T.nilable(::String)).void } + def print(string); end + + # Print `string` colored with `color` into `out` + # + # Does not use colors unless `@colors`. + # + # source://spoom//lib/spoom/printer.rb#47 + sig { params(string: T.nilable(::String), color: ::Spoom::Color).void } + def print_colored(string, *color); end + + # Print `string` with indent and newline + # + # source://spoom//lib/spoom/printer.rb#62 + sig { params(string: T.nilable(::String)).void } + def printl(string); end + + # Print a new line into `out` + # + # source://spoom//lib/spoom/printer.rb#56 + sig { void } + def printn; end + + # Print an indent space into `out` + # + # source://spoom//lib/spoom/printer.rb#72 + sig { void } + def printt; end +end + +# source://spoom//lib/spoom.rb#10 +Spoom::SPOOM_PATH = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/config.rb#5 +module Spoom::Sorbet; end + +# source://spoom//lib/spoom/sorbet.rb#39 +Spoom::Sorbet::BIN_PATH = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet.rb#36 +Spoom::Sorbet::CONFIG_PATH = T.let(T.unsafe(nil), String) + +# Parse Sorbet config files +# +# Parses a Sorbet config file: +# +# ```ruby +# config = Spoom::Sorbet::Config.parse_file("sorbet/config") +# puts config.paths # "." +# ``` +# +# Parses a Sorbet config string: +# +# ```ruby +# config = Spoom::Sorbet::Config.parse_string(<<~CONFIG) +# a +# --file=b +# --ignore=c +# CONFIG +# puts config.paths # "a", "b" +# puts config.ignore # "c" +# ``` +# +# source://spoom//lib/spoom/sorbet/config.rb#26 +class Spoom::Sorbet::Config + # source://spoom//lib/spoom/sorbet/config.rb#38 + sig { void } + def initialize; end + + # @return [Array] + # + # source://spoom//lib/spoom/sorbet/config.rb#32 + def allowed_extensions; end + + # @return [Array] + # + # source://spoom//lib/spoom/sorbet/config.rb#32 + def allowed_extensions=(_arg0); end + + # source://spoom//lib/spoom/sorbet/config.rb#46 + sig { returns(::Spoom::Sorbet::Config) } + def copy; end + + # @return [Array] + # + # source://spoom//lib/spoom/sorbet/config.rb#32 + def ignore; end + + # @return [Array] + # + # source://spoom//lib/spoom/sorbet/config.rb#32 + def ignore=(_arg0); end + + # source://spoom//lib/spoom/sorbet/config.rb#35 + sig { returns(T::Boolean) } + def no_stdlib; end + + # @return [Boolean] + # + # source://spoom//lib/spoom/sorbet/config.rb#35 + def no_stdlib=(_arg0); end + + # Returns self as a string of options that can be passed to Sorbet + # + # Example: + # ~~~rb + # config = Sorbet::Config.new + # config.paths << "/foo" + # config.paths << "/bar" + # config.ignore << "/baz" + # config.allowed_extensions << ".rb" + # + # puts config.options_string # "/foo /bar --ignore /baz --allowed-extension .rb" + # ~~~ + # + # source://spoom//lib/spoom/sorbet/config.rb#68 + sig { returns(::String) } + def options_string; end + + # source://spoom//lib/spoom/sorbet/config.rb#32 + sig { returns(T::Array[::String]) } + def paths; end + + # @return [Array] + # + # source://spoom//lib/spoom/sorbet/config.rb#32 + def paths=(_arg0); end + + class << self + # source://spoom//lib/spoom/sorbet/config.rb#81 + sig { params(sorbet_config_path: ::String).returns(::Spoom::Sorbet::Config) } + def parse_file(sorbet_config_path); end + + # source://spoom//lib/spoom/sorbet/config.rb#86 + sig { params(sorbet_config: ::String).returns(::Spoom::Sorbet::Config) } + def parse_string(sorbet_config); end + + private + + # source://spoom//lib/spoom/sorbet/config.rb#150 + sig { params(line: ::String).returns(::String) } + def parse_option(line); end + end +end + +# source://spoom//lib/spoom/sorbet/config.rb#29 +Spoom::Sorbet::Config::DEFAULT_ALLOWED_EXTENSIONS = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/sorbet.rb#14 +class Spoom::Sorbet::Error < ::Spoom::Error + # source://spoom//lib/spoom/sorbet.rb#29 + sig { params(message: ::String, result: ::Spoom::ExecResult).void } + def initialize(message, result); end + + # source://spoom//lib/spoom/sorbet.rb#21 + sig { returns(::Spoom::ExecResult) } + def result; end +end + +# source://spoom//lib/spoom/sorbet.rb#17 +class Spoom::Sorbet::Error::Killed < ::Spoom::Sorbet::Error; end + +# source://spoom//lib/spoom/sorbet.rb#18 +class Spoom::Sorbet::Error::Segfault < ::Spoom::Sorbet::Error; end + +# source://spoom//lib/spoom/sorbet/errors.rb#6 +module Spoom::Sorbet::Errors + class << self + # source://spoom//lib/spoom/sorbet/errors.rb#13 + sig { params(errors: T::Array[::Spoom::Sorbet::Errors::Error]).returns(T::Array[::Spoom::Sorbet::Errors::Error]) } + def sort_errors_by_code(errors); end + end +end + +# source://spoom//lib/spoom/sorbet/errors.rb#7 +Spoom::Sorbet::Errors::DEFAULT_ERROR_URL_BASE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/errors.rb#127 +class Spoom::Sorbet::Errors::Error + include ::Comparable + + # source://spoom//lib/spoom/sorbet/errors.rb#153 + sig do + params( + file: T.nilable(::String), + line: T.nilable(::Integer), + message: T.nilable(::String), + code: T.nilable(::Integer), + more: T::Array[::String] + ).void + end + def initialize(file, line, message, code, more = T.unsafe(nil)); end + + # By default errors are sorted by location + # + # source://spoom//lib/spoom/sorbet/errors.rb#164 + sig { params(other: T.untyped).returns(::Integer) } + def <=>(other); end + + # @return [Integer, nil] + # + # source://spoom//lib/spoom/sorbet/errors.rb#135 + def code; end + + # source://spoom//lib/spoom/sorbet/errors.rb#132 + sig { returns(T.nilable(::String)) } + def file; end + + # Other files associated with the error + # + # source://spoom//lib/spoom/sorbet/errors.rb#142 + sig { returns(T::Set[::String]) } + def files_from_error_sections; end + + # source://spoom//lib/spoom/sorbet/errors.rb#135 + sig { returns(T.nilable(::Integer)) } + def line; end + + # @return [String, nil] + # + # source://spoom//lib/spoom/sorbet/errors.rb#132 + def message; end + + # source://spoom//lib/spoom/sorbet/errors.rb#138 + sig { returns(T::Array[::String]) } + def more; end + + # source://spoom//lib/spoom/sorbet/errors.rb#171 + sig { returns(::String) } + def to_s; end +end + +# Parse errors from Sorbet output +# +# source://spoom//lib/spoom/sorbet/errors.rb#18 +class Spoom::Sorbet::Errors::Parser + # source://spoom//lib/spoom/sorbet/errors.rb#45 + sig { params(error_url_base: ::String).void } + def initialize(error_url_base: T.unsafe(nil)); end + + # source://spoom//lib/spoom/sorbet/errors.rb#52 + sig { params(output: ::String).returns(T::Array[::Spoom::Sorbet::Errors::Error]) } + def parse(output); end + + private + + # @raise [ParseError] + # + # source://spoom//lib/spoom/sorbet/errors.rb#116 + sig { params(line: ::String).void } + def append_error(line); end + + # @raise [ParseError] + # + # source://spoom//lib/spoom/sorbet/errors.rb#108 + sig { void } + def close_error; end + + # source://spoom//lib/spoom/sorbet/errors.rb#75 + sig { params(error_url_base: ::String).returns(::Regexp) } + def error_line_match_regexp(error_url_base); end + + # source://spoom//lib/spoom/sorbet/errors.rb#92 + sig { params(line: ::String).returns(T.nilable(::Spoom::Sorbet::Errors::Error)) } + def match_error_line(line); end + + # @raise [ParseError] + # + # source://spoom//lib/spoom/sorbet/errors.rb#101 + sig { params(error: ::Spoom::Sorbet::Errors::Error).void } + def open_error(error); end + + class << self + # source://spoom//lib/spoom/sorbet/errors.rb#38 + sig { params(output: ::String, error_url_base: ::String).returns(T::Array[::Spoom::Sorbet::Errors::Error]) } + def parse_string(output, error_url_base: T.unsafe(nil)); end + end +end + +# source://spoom//lib/spoom/sorbet/errors.rb#23 +Spoom::Sorbet::Errors::Parser::HEADER = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/sorbet/errors.rb#21 +class Spoom::Sorbet::Errors::Parser::ParseError < ::Spoom::Error; end + +# source://spoom//lib/spoom/sorbet.rb#37 +Spoom::Sorbet::GEM_PATH = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet.rb#38 +Spoom::Sorbet::GEM_VERSION = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet.rb#41 +Spoom::Sorbet::KILLED_CODE = T.let(T.unsafe(nil), Integer) + +# source://spoom//lib/spoom/sorbet/metrics.rb#8 +module Spoom::Sorbet::MetricsParser + class << self + # source://spoom//lib/spoom/sorbet/metrics.rb#15 + sig { params(path: ::String, prefix: ::String).returns(T::Hash[::String, ::Integer]) } + def parse_file(path, prefix = T.unsafe(nil)); end + + # source://spoom//lib/spoom/sorbet/metrics.rb#25 + sig { params(obj: T::Hash[::String, T.untyped], prefix: ::String).returns(T::Hash[::String, ::Integer]) } + def parse_hash(obj, prefix = T.unsafe(nil)); end + + # source://spoom//lib/spoom/sorbet/metrics.rb#20 + sig { params(string: ::String, prefix: ::String).returns(T::Hash[::String, ::Integer]) } + def parse_string(string, prefix = T.unsafe(nil)); end + end +end + +# source://spoom//lib/spoom/sorbet/metrics.rb#9 +Spoom::Sorbet::MetricsParser::DEFAULT_PREFIX = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet.rb#42 +Spoom::Sorbet::SEGFAULT_CODE = T.let(T.unsafe(nil), Integer) + +# source://spoom//lib/spoom/sorbet/sigils.rb#9 +module Spoom::Sorbet::Sigils + class << self + # changes the sigil in the file at the passed path to the specified new strictness + # + # source://spoom//lib/spoom/sorbet/sigils.rb#72 + sig { params(path: T.any(::Pathname, ::String), new_strictness: ::String).returns(T::Boolean) } + def change_sigil_in_file(path, new_strictness); end + + # changes the sigil to have a new strictness in a list of files + # + # source://spoom//lib/spoom/sorbet/sigils.rb#83 + sig { params(path_list: T::Array[::String], new_strictness: ::String).returns(T::Array[::String]) } + def change_sigil_in_files(path_list, new_strictness); end + + # returns a string containing the strictness of a sigil in a file at the passed path + # * returns nil if no sigil + # + # source://spoom//lib/spoom/sorbet/sigils.rb#63 + sig { params(path: T.any(::Pathname, ::String)).returns(T.nilable(::String)) } + def file_strictness(path); end + + # returns the full sigil comment string for the passed strictness + # + # source://spoom//lib/spoom/sorbet/sigils.rb#38 + sig { params(strictness: ::String).returns(::String) } + def sigil_string(strictness); end + + # returns the strictness of a sigil in the passed file content string (nil if no sigil) + # + # source://spoom//lib/spoom/sorbet/sigils.rb#50 + sig { params(content: ::String).returns(T.nilable(::String)) } + def strictness_in_content(content); end + + # returns a string which is the passed content but with the sigil updated to a new strictness + # + # source://spoom//lib/spoom/sorbet/sigils.rb#56 + sig { params(content: ::String, new_strictness: ::String).returns(::String) } + def update_sigil(content, new_strictness); end + + # returns true if the passed string is a valid strictness (else false) + # + # source://spoom//lib/spoom/sorbet/sigils.rb#44 + sig { params(strictness: ::String).returns(T::Boolean) } + def valid_strictness?(strictness); end + end +end + +# source://spoom//lib/spoom/sorbet/sigils.rb#31 +Spoom::Sorbet::Sigils::SIGIL_REGEXP = T.let(T.unsafe(nil), Regexp) + +# source://spoom//lib/spoom/sorbet/sigils.rb#13 +Spoom::Sorbet::Sigils::STRICTNESS_FALSE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/sigils.rb#12 +Spoom::Sorbet::Sigils::STRICTNESS_IGNORE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/sigils.rb#17 +Spoom::Sorbet::Sigils::STRICTNESS_INTERNAL = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/sigils.rb#15 +Spoom::Sorbet::Sigils::STRICTNESS_STRICT = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/sigils.rb#16 +Spoom::Sorbet::Sigils::STRICTNESS_STRONG = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/sigils.rb#14 +Spoom::Sorbet::Sigils::STRICTNESS_TRUE = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/sorbet/sigils.rb#19 +Spoom::Sorbet::Sigils::VALID_STRICTNESS = T.let(T.unsafe(nil), Array) + +# source://spoom//lib/spoom/timeline.rb#5 +class Spoom::Timeline + # source://spoom//lib/spoom/timeline.rb#9 + sig { params(context: ::Spoom::Context, from: ::Time, to: ::Time).void } + def initialize(context, from, to); end + + # Return one commit for each date in `dates` + # + # source://spoom//lib/spoom/timeline.rb#36 + sig { params(dates: T::Array[::Time]).returns(T::Array[::Spoom::Git::Commit]) } + def commits_for_dates(dates); end + + # Return all months between `from` and `to` + # + # source://spoom//lib/spoom/timeline.rb#23 + sig { returns(T::Array[::Time]) } + def months; end + + # Return one commit for each month between `from` and `to` + # + # source://spoom//lib/spoom/timeline.rb#17 + sig { returns(T::Array[::Spoom::Git::Commit]) } + def ticks; end +end + +# source://spoom//lib/spoom/version.rb#5 +Spoom::VERSION = T.let(T.unsafe(nil), String) + +# source://spoom//lib/spoom/visitor.rb#7 +class Spoom::Visitor < ::Prism::Visitor + # source://spoom//lib/spoom/visitor.rb#16 + sig { override.params(node: ::Prism::AliasGlobalVariableNode).void } + def visit_alias_global_variable_node(node); end + + # source://spoom//lib/spoom/visitor.rb#21 + sig { override.params(node: ::Prism::AliasMethodNode).void } + def visit_alias_method_node(node); end + + # source://spoom//lib/spoom/visitor.rb#26 + sig { override.params(node: ::Prism::AlternationPatternNode).void } + def visit_alternation_pattern_node(node); end + + # source://spoom//lib/spoom/visitor.rb#31 + sig { override.params(node: ::Prism::AndNode).void } + def visit_and_node(node); end + + # source://spoom//lib/spoom/visitor.rb#36 + sig { override.params(node: ::Prism::ArgumentsNode).void } + def visit_arguments_node(node); end + + # source://spoom//lib/spoom/visitor.rb#41 + sig { override.params(node: ::Prism::ArrayNode).void } + def visit_array_node(node); end + + # source://spoom//lib/spoom/visitor.rb#46 + sig { override.params(node: ::Prism::ArrayPatternNode).void } + def visit_array_pattern_node(node); end + + # source://spoom//lib/spoom/visitor.rb#51 + sig { override.params(node: ::Prism::AssocNode).void } + def visit_assoc_node(node); end + + # source://spoom//lib/spoom/visitor.rb#56 + sig { override.params(node: ::Prism::AssocSplatNode).void } + def visit_assoc_splat_node(node); end + + # source://spoom//lib/spoom/visitor.rb#61 + sig { override.params(node: ::Prism::BackReferenceReadNode).void } + def visit_back_reference_read_node(node); end + + # source://spoom//lib/spoom/visitor.rb#66 + sig { override.params(node: ::Prism::BeginNode).void } + def visit_begin_node(node); end + + # source://spoom//lib/spoom/visitor.rb#71 + sig { override.params(node: ::Prism::BlockArgumentNode).void } + def visit_block_argument_node(node); end + + # source://spoom//lib/spoom/visitor.rb#76 + sig { override.params(node: ::Prism::BlockLocalVariableNode).void } + def visit_block_local_variable_node(node); end + + # source://spoom//lib/spoom/visitor.rb#81 + sig { override.params(node: ::Prism::BlockNode).void } + def visit_block_node(node); end + + # source://spoom//lib/spoom/visitor.rb#86 + sig { override.params(node: ::Prism::BlockParameterNode).void } + def visit_block_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#91 + sig { override.params(node: ::Prism::BlockParametersNode).void } + def visit_block_parameters_node(node); end + + # source://spoom//lib/spoom/visitor.rb#96 + sig { override.params(node: ::Prism::BreakNode).void } + def visit_break_node(node); end + + # source://spoom//lib/spoom/visitor.rb#101 + sig { override.params(node: ::Prism::CallAndWriteNode).void } + def visit_call_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#106 + sig { override.params(node: ::Prism::CallNode).void } + def visit_call_node(node); end + + # source://spoom//lib/spoom/visitor.rb#111 + sig { override.params(node: ::Prism::CallOperatorWriteNode).void } + def visit_call_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#116 + sig { override.params(node: ::Prism::CallOrWriteNode).void } + def visit_call_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#121 + sig { override.params(node: ::Prism::CallTargetNode).void } + def visit_call_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#126 + sig { override.params(node: ::Prism::CapturePatternNode).void } + def visit_capture_pattern_node(node); end + + # source://spoom//lib/spoom/visitor.rb#131 + sig { override.params(node: ::Prism::CaseMatchNode).void } + def visit_case_match_node(node); end + + # source://spoom//lib/spoom/visitor.rb#136 + sig { override.params(node: ::Prism::CaseNode).void } + def visit_case_node(node); end + + # source://spoom//lib/spoom/visitor.rb#11 + sig { override.params(node: ::Prism::Node).void } + def visit_child_nodes(node); end + + # source://spoom//lib/spoom/visitor.rb#141 + sig { override.params(node: ::Prism::ClassNode).void } + def visit_class_node(node); end + + # source://spoom//lib/spoom/visitor.rb#146 + sig { override.params(node: ::Prism::ClassVariableAndWriteNode).void } + def visit_class_variable_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#151 + sig { override.params(node: ::Prism::ClassVariableOperatorWriteNode).void } + def visit_class_variable_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#156 + sig { override.params(node: ::Prism::ClassVariableOrWriteNode).void } + def visit_class_variable_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#161 + sig { override.params(node: ::Prism::ClassVariableReadNode).void } + def visit_class_variable_read_node(node); end + + # source://spoom//lib/spoom/visitor.rb#166 + sig { override.params(node: ::Prism::ClassVariableTargetNode).void } + def visit_class_variable_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#171 + sig { override.params(node: ::Prism::ClassVariableWriteNode).void } + def visit_class_variable_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#176 + sig { override.params(node: ::Prism::ConstantAndWriteNode).void } + def visit_constant_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#181 + sig { override.params(node: ::Prism::ConstantOperatorWriteNode).void } + def visit_constant_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#186 + sig { override.params(node: ::Prism::ConstantOrWriteNode).void } + def visit_constant_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#191 + sig { override.params(node: ::Prism::ConstantPathAndWriteNode).void } + def visit_constant_path_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#196 + sig { override.params(node: ::Prism::ConstantPathNode).void } + def visit_constant_path_node(node); end + + # source://spoom//lib/spoom/visitor.rb#201 + sig { override.params(node: ::Prism::ConstantPathOperatorWriteNode).void } + def visit_constant_path_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#206 + sig { override.params(node: ::Prism::ConstantPathOrWriteNode).void } + def visit_constant_path_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#211 + sig { override.params(node: ::Prism::ConstantPathTargetNode).void } + def visit_constant_path_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#216 + sig { override.params(node: ::Prism::ConstantPathWriteNode).void } + def visit_constant_path_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#221 + sig { override.params(node: ::Prism::ConstantReadNode).void } + def visit_constant_read_node(node); end + + # source://spoom//lib/spoom/visitor.rb#226 + sig { override.params(node: ::Prism::ConstantTargetNode).void } + def visit_constant_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#231 + sig { override.params(node: ::Prism::ConstantWriteNode).void } + def visit_constant_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#236 + sig { override.params(node: ::Prism::DefNode).void } + def visit_def_node(node); end + + # source://spoom//lib/spoom/visitor.rb#241 + sig { override.params(node: ::Prism::DefinedNode).void } + def visit_defined_node(node); end + + # source://spoom//lib/spoom/visitor.rb#246 + sig { override.params(node: ::Prism::ElseNode).void } + def visit_else_node(node); end + + # source://spoom//lib/spoom/visitor.rb#251 + sig { override.params(node: ::Prism::EmbeddedStatementsNode).void } + def visit_embedded_statements_node(node); end + + # source://spoom//lib/spoom/visitor.rb#256 + sig { override.params(node: ::Prism::EmbeddedVariableNode).void } + def visit_embedded_variable_node(node); end + + # source://spoom//lib/spoom/visitor.rb#261 + sig { override.params(node: ::Prism::EnsureNode).void } + def visit_ensure_node(node); end + + # source://spoom//lib/spoom/visitor.rb#266 + sig { override.params(node: ::Prism::FalseNode).void } + def visit_false_node(node); end + + # source://spoom//lib/spoom/visitor.rb#271 + sig { override.params(node: ::Prism::FindPatternNode).void } + def visit_find_pattern_node(node); end + + # source://spoom//lib/spoom/visitor.rb#276 + sig { override.params(node: ::Prism::FlipFlopNode).void } + def visit_flip_flop_node(node); end + + # source://spoom//lib/spoom/visitor.rb#281 + sig { override.params(node: ::Prism::FloatNode).void } + def visit_float_node(node); end + + # source://spoom//lib/spoom/visitor.rb#286 + sig { override.params(node: ::Prism::ForNode).void } + def visit_for_node(node); end + + # source://spoom//lib/spoom/visitor.rb#291 + sig { override.params(node: ::Prism::ForwardingArgumentsNode).void } + def visit_forwarding_arguments_node(node); end + + # source://spoom//lib/spoom/visitor.rb#296 + sig { override.params(node: ::Prism::ForwardingParameterNode).void } + def visit_forwarding_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#301 + sig { override.params(node: ::Prism::ForwardingSuperNode).void } + def visit_forwarding_super_node(node); end + + # source://spoom//lib/spoom/visitor.rb#306 + sig { override.params(node: ::Prism::GlobalVariableAndWriteNode).void } + def visit_global_variable_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#311 + sig { override.params(node: ::Prism::GlobalVariableOperatorWriteNode).void } + def visit_global_variable_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#316 + sig { override.params(node: ::Prism::GlobalVariableOrWriteNode).void } + def visit_global_variable_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#321 + sig { override.params(node: ::Prism::GlobalVariableReadNode).void } + def visit_global_variable_read_node(node); end + + # source://spoom//lib/spoom/visitor.rb#326 + sig { override.params(node: ::Prism::GlobalVariableTargetNode).void } + def visit_global_variable_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#331 + sig { override.params(node: ::Prism::GlobalVariableWriteNode).void } + def visit_global_variable_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#336 + sig { override.params(node: ::Prism::HashNode).void } + def visit_hash_node(node); end + + # source://spoom//lib/spoom/visitor.rb#341 + sig { override.params(node: ::Prism::HashPatternNode).void } + def visit_hash_pattern_node(node); end + + # source://spoom//lib/spoom/visitor.rb#346 + sig { override.params(node: ::Prism::IfNode).void } + def visit_if_node(node); end + + # source://spoom//lib/spoom/visitor.rb#351 + sig { override.params(node: ::Prism::ImaginaryNode).void } + def visit_imaginary_node(node); end + + # source://spoom//lib/spoom/visitor.rb#356 + sig { override.params(node: ::Prism::ImplicitNode).void } + def visit_implicit_node(node); end + + # source://spoom//lib/spoom/visitor.rb#361 + sig { override.params(node: ::Prism::ImplicitRestNode).void } + def visit_implicit_rest_node(node); end + + # source://spoom//lib/spoom/visitor.rb#366 + sig { override.params(node: ::Prism::InNode).void } + def visit_in_node(node); end + + # source://spoom//lib/spoom/visitor.rb#371 + sig { override.params(node: ::Prism::IndexAndWriteNode).void } + def visit_index_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#376 + sig { override.params(node: ::Prism::IndexOperatorWriteNode).void } + def visit_index_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#381 + sig { override.params(node: ::Prism::IndexOrWriteNode).void } + def visit_index_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#386 + sig { override.params(node: ::Prism::IndexTargetNode).void } + def visit_index_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#391 + sig { override.params(node: ::Prism::InstanceVariableAndWriteNode).void } + def visit_instance_variable_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#396 + sig { override.params(node: ::Prism::InstanceVariableOperatorWriteNode).void } + def visit_instance_variable_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#401 + sig { override.params(node: ::Prism::InstanceVariableOrWriteNode).void } + def visit_instance_variable_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#406 + sig { override.params(node: ::Prism::InstanceVariableReadNode).void } + def visit_instance_variable_read_node(node); end + + # source://spoom//lib/spoom/visitor.rb#411 + sig { override.params(node: ::Prism::InstanceVariableTargetNode).void } + def visit_instance_variable_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#416 + sig { override.params(node: ::Prism::InstanceVariableWriteNode).void } + def visit_instance_variable_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#421 + sig { override.params(node: ::Prism::IntegerNode).void } + def visit_integer_node(node); end + + # source://spoom//lib/spoom/visitor.rb#426 + sig { override.params(node: ::Prism::InterpolatedMatchLastLineNode).void } + def visit_interpolated_match_last_line_node(node); end + + # source://spoom//lib/spoom/visitor.rb#431 + sig { override.params(node: ::Prism::InterpolatedRegularExpressionNode).void } + def visit_interpolated_regular_expression_node(node); end + + # source://spoom//lib/spoom/visitor.rb#436 + sig { override.params(node: ::Prism::InterpolatedStringNode).void } + def visit_interpolated_string_node(node); end + + # source://spoom//lib/spoom/visitor.rb#441 + sig { override.params(node: ::Prism::InterpolatedSymbolNode).void } + def visit_interpolated_symbol_node(node); end + + # source://spoom//lib/spoom/visitor.rb#446 + sig { override.params(node: ::Prism::InterpolatedXStringNode).void } + def visit_interpolated_x_string_node(node); end + + # source://spoom//lib/spoom/visitor.rb#451 + sig { override.params(node: ::Prism::KeywordHashNode).void } + def visit_keyword_hash_node(node); end + + # source://spoom//lib/spoom/visitor.rb#456 + sig { override.params(node: ::Prism::KeywordRestParameterNode).void } + def visit_keyword_rest_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#461 + sig { override.params(node: ::Prism::LambdaNode).void } + def visit_lambda_node(node); end + + # source://spoom//lib/spoom/visitor.rb#466 + sig { override.params(node: ::Prism::LocalVariableAndWriteNode).void } + def visit_local_variable_and_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#471 + sig { override.params(node: ::Prism::LocalVariableOperatorWriteNode).void } + def visit_local_variable_operator_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#476 + sig { override.params(node: ::Prism::LocalVariableOrWriteNode).void } + def visit_local_variable_or_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#481 + sig { override.params(node: ::Prism::LocalVariableReadNode).void } + def visit_local_variable_read_node(node); end + + # source://spoom//lib/spoom/visitor.rb#486 + sig { override.params(node: ::Prism::LocalVariableTargetNode).void } + def visit_local_variable_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#491 + sig { override.params(node: ::Prism::LocalVariableWriteNode).void } + def visit_local_variable_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#496 + sig { override.params(node: ::Prism::MatchLastLineNode).void } + def visit_match_last_line_node(node); end + + # source://spoom//lib/spoom/visitor.rb#501 + sig { override.params(node: ::Prism::MatchPredicateNode).void } + def visit_match_predicate_node(node); end + + # source://spoom//lib/spoom/visitor.rb#506 + sig { override.params(node: ::Prism::MatchRequiredNode).void } + def visit_match_required_node(node); end + + # source://spoom//lib/spoom/visitor.rb#511 + sig { override.params(node: ::Prism::MatchWriteNode).void } + def visit_match_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#516 + sig { override.params(node: ::Prism::MissingNode).void } + def visit_missing_node(node); end + + # source://spoom//lib/spoom/visitor.rb#521 + sig { override.params(node: ::Prism::ModuleNode).void } + def visit_module_node(node); end + + # source://spoom//lib/spoom/visitor.rb#526 + sig { override.params(node: ::Prism::MultiTargetNode).void } + def visit_multi_target_node(node); end + + # source://spoom//lib/spoom/visitor.rb#531 + sig { override.params(node: ::Prism::MultiWriteNode).void } + def visit_multi_write_node(node); end + + # source://spoom//lib/spoom/visitor.rb#536 + sig { override.params(node: ::Prism::NextNode).void } + def visit_next_node(node); end + + # source://spoom//lib/spoom/visitor.rb#541 + sig { override.params(node: ::Prism::NilNode).void } + def visit_nil_node(node); end + + # source://spoom//lib/spoom/visitor.rb#546 + sig { override.params(node: ::Prism::NoKeywordsParameterNode).void } + def visit_no_keywords_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#551 + sig { override.params(node: ::Prism::NumberedParametersNode).void } + def visit_numbered_parameters_node(node); end + + # source://spoom//lib/spoom/visitor.rb#556 + sig { override.params(node: ::Prism::NumberedReferenceReadNode).void } + def visit_numbered_reference_read_node(node); end + + # source://spoom//lib/spoom/visitor.rb#561 + sig { override.params(node: ::Prism::OptionalKeywordParameterNode).void } + def visit_optional_keyword_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#566 + sig { override.params(node: ::Prism::OptionalParameterNode).void } + def visit_optional_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#571 + sig { override.params(node: ::Prism::OrNode).void } + def visit_or_node(node); end + + # source://spoom//lib/spoom/visitor.rb#576 + sig { override.params(node: ::Prism::ParametersNode).void } + def visit_parameters_node(node); end + + # source://spoom//lib/spoom/visitor.rb#581 + sig { override.params(node: ::Prism::ParenthesesNode).void } + def visit_parentheses_node(node); end + + # source://spoom//lib/spoom/visitor.rb#586 + sig { override.params(node: ::Prism::PinnedExpressionNode).void } + def visit_pinned_expression_node(node); end + + # source://spoom//lib/spoom/visitor.rb#591 + sig { override.params(node: ::Prism::PinnedVariableNode).void } + def visit_pinned_variable_node(node); end + + # source://spoom//lib/spoom/visitor.rb#596 + sig { override.params(node: ::Prism::PostExecutionNode).void } + def visit_post_execution_node(node); end + + # source://spoom//lib/spoom/visitor.rb#601 + sig { override.params(node: ::Prism::PreExecutionNode).void } + def visit_pre_execution_node(node); end + + # source://spoom//lib/spoom/visitor.rb#606 + sig { override.params(node: ::Prism::ProgramNode).void } + def visit_program_node(node); end + + # source://spoom//lib/spoom/visitor.rb#611 + sig { override.params(node: ::Prism::RangeNode).void } + def visit_range_node(node); end + + # source://spoom//lib/spoom/visitor.rb#616 + sig { override.params(node: ::Prism::RationalNode).void } + def visit_rational_node(node); end + + # source://spoom//lib/spoom/visitor.rb#621 + sig { override.params(node: ::Prism::RedoNode).void } + def visit_redo_node(node); end + + # source://spoom//lib/spoom/visitor.rb#626 + sig { override.params(node: ::Prism::RegularExpressionNode).void } + def visit_regular_expression_node(node); end + + # source://spoom//lib/spoom/visitor.rb#631 + sig { override.params(node: ::Prism::RequiredKeywordParameterNode).void } + def visit_required_keyword_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#636 + sig { override.params(node: ::Prism::RequiredParameterNode).void } + def visit_required_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#641 + sig { override.params(node: ::Prism::RescueModifierNode).void } + def visit_rescue_modifier_node(node); end + + # source://spoom//lib/spoom/visitor.rb#646 + sig { override.params(node: ::Prism::RescueNode).void } + def visit_rescue_node(node); end + + # source://spoom//lib/spoom/visitor.rb#651 + sig { override.params(node: ::Prism::RestParameterNode).void } + def visit_rest_parameter_node(node); end + + # source://spoom//lib/spoom/visitor.rb#656 + sig { override.params(node: ::Prism::RetryNode).void } + def visit_retry_node(node); end + + # source://spoom//lib/spoom/visitor.rb#661 + sig { override.params(node: ::Prism::ReturnNode).void } + def visit_return_node(node); end + + # source://spoom//lib/spoom/visitor.rb#666 + sig { override.params(node: ::Prism::SelfNode).void } + def visit_self_node(node); end + + # source://spoom//lib/spoom/visitor.rb#671 + sig { override.params(node: ::Prism::SingletonClassNode).void } + def visit_singleton_class_node(node); end + + # source://spoom//lib/spoom/visitor.rb#676 + sig { override.params(node: ::Prism::SourceEncodingNode).void } + def visit_source_encoding_node(node); end + + # source://spoom//lib/spoom/visitor.rb#681 + sig { override.params(node: ::Prism::SourceFileNode).void } + def visit_source_file_node(node); end + + # source://spoom//lib/spoom/visitor.rb#686 + sig { override.params(node: ::Prism::SourceLineNode).void } + def visit_source_line_node(node); end + + # source://spoom//lib/spoom/visitor.rb#691 + sig { override.params(node: ::Prism::SplatNode).void } + def visit_splat_node(node); end + + # source://spoom//lib/spoom/visitor.rb#696 + sig { override.params(node: ::Prism::StatementsNode).void } + def visit_statements_node(node); end + + # source://spoom//lib/spoom/visitor.rb#701 + sig { override.params(node: ::Prism::StringNode).void } + def visit_string_node(node); end + + # source://spoom//lib/spoom/visitor.rb#706 + sig { override.params(node: ::Prism::SuperNode).void } + def visit_super_node(node); end + + # source://spoom//lib/spoom/visitor.rb#711 + sig { override.params(node: ::Prism::SymbolNode).void } + def visit_symbol_node(node); end + + # source://spoom//lib/spoom/visitor.rb#716 + sig { override.params(node: ::Prism::TrueNode).void } + def visit_true_node(node); end + + # source://spoom//lib/spoom/visitor.rb#721 + sig { override.params(node: ::Prism::UndefNode).void } + def visit_undef_node(node); end + + # source://spoom//lib/spoom/visitor.rb#726 + sig { override.params(node: ::Prism::UnlessNode).void } + def visit_unless_node(node); end + + # source://spoom//lib/spoom/visitor.rb#731 + sig { override.params(node: ::Prism::UntilNode).void } + def visit_until_node(node); end + + # source://spoom//lib/spoom/visitor.rb#736 + sig { override.params(node: ::Prism::WhenNode).void } + def visit_when_node(node); end + + # source://spoom//lib/spoom/visitor.rb#741 + sig { override.params(node: ::Prism::WhileNode).void } + def visit_while_node(node); end + + # source://spoom//lib/spoom/visitor.rb#746 + sig { override.params(node: ::Prism::XStringNode).void } + def visit_x_string_node(node); end + + # source://spoom//lib/spoom/visitor.rb#751 + sig { override.params(node: ::Prism::YieldNode).void } + def visit_yield_node(node); end +end diff --git a/sorbet/rbi/gems/sprockets-rails@3.4.2.rbi b/sorbet/rbi/gems/sprockets-rails@3.4.2.rbi deleted file mode 100644 index e55769666..000000000 --- a/sorbet/rbi/gems/sprockets-rails@3.4.2.rbi +++ /dev/null @@ -1,1277 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `sprockets-rails` gem. -# Please instead update this file by running `bin/tapioca gem sprockets-rails`. - -# source://sprockets-rails//lib/sprockets/railtie.rb#17 -module Rails - class << self - # source://railties/7.0.5/lib/rails.rb#38 - def app_class; end - - # source://railties/7.0.5/lib/rails.rb#38 - def app_class=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#39 - def application; end - - # source://railties/7.0.5/lib/rails.rb#37 - def application=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#123 - def autoloaders; end - - # source://railties/7.0.5/lib/rails.rb#50 - def backtrace_cleaner; end - - # source://railties/7.0.5/lib/rails.rb#38 - def cache; end - - # source://railties/7.0.5/lib/rails.rb#38 - def cache=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#46 - def configuration; end - - # source://railties/7.0.5/lib/rails.rb#72 - def env; end - - # source://railties/7.0.5/lib/rails.rb#79 - def env=(environment); end - - # source://railties/7.0.5/lib/rails.rb#90 - def error; end - - # source://railties/7.0.5/lib/rails/gem_version.rb#5 - def gem_version; end - - # source://railties/7.0.5/lib/rails.rb#103 - def groups(*groups); end - - # source://railties/7.0.5/lib/rails.rb#43 - def initialize!(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails.rb#43 - def initialized?(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails.rb#38 - def logger; end - - # source://railties/7.0.5/lib/rails.rb#38 - def logger=(_arg0); end - - # source://railties/7.0.5/lib/rails.rb#119 - def public_path; end - - # source://railties/7.0.5/lib/rails.rb#63 - def root; end - - # source://railties/7.0.5/lib/rails/version.rb#7 - def version; end - end -end - -# source://sprockets-rails//lib/sprockets/railtie.rb#18 -class Rails::Application < ::Rails::Engine - # source://railties/7.0.5/lib/rails/application.rb#106 - def initialize(initial_variable_values = T.unsafe(nil), &block); end - - # Called from asset helpers to alert you if you reference an asset URL that - # isn't precompiled and hence won't be available in production. - # - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/railtie.rb#37 - def asset_precompiled?(logical_path); end - - # Returns Sprockets::Environment for app config. - # - # source://sprockets-rails//lib/sprockets/railtie.rb#30 - def assets; end - - # Returns Sprockets::Environment for app config. - # - # source://sprockets-rails//lib/sprockets/railtie.rb#30 - def assets=(_arg0); end - - # Returns Sprockets::Manifest for app config. - # - # source://sprockets-rails//lib/sprockets/railtie.rb#33 - def assets_manifest; end - - # Returns Sprockets::Manifest for app config. - # - # source://sprockets-rails//lib/sprockets/railtie.rb#33 - def assets_manifest=(_arg0); end - - # source://railties/7.0.5/lib/rails/application.rb#99 - def autoloaders; end - - # source://railties/7.0.5/lib/rails/engine.rb#511 - def build_middleware_stack; end - - # source://railties/7.0.5/lib/rails/application.rb#383 - def config; end - - # source://railties/7.0.5/lib/rails/application.rb#387 - def config=(_arg0); end - - # source://railties/7.0.5/lib/rails/application.rb#221 - def config_for(name, env: T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/application.rb#303 - def console(&blk); end - - # source://railties/7.0.5/lib/rails/application.rb#439 - def credentials; end - - # source://railties/7.0.5/lib/rails/application.rb#403 - def credentials=(_arg0); end - - # source://railties/7.0.5/lib/rails/application.rb#101 - def default_url_options(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails/application.rb#101 - def default_url_options=(arg); end - - # source://railties/7.0.5/lib/rails/application.rb#492 - def eager_load!; end - - # source://railties/7.0.5/lib/rails/application.rb#458 - def encrypted(path, key_path: T.unsafe(nil), env_key: T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/application.rb#250 - def env_config; end - - # source://railties/7.0.5/lib/rails/application.rb#99 - def executor; end - - # source://railties/7.0.5/lib/rails/application.rb#309 - def generators(&blk); end - - # source://railties/7.0.5/lib/rails/application.rb#471 - def helpers_paths; end - - # source://importmap-rails/1.2.1/lib/importmap/engine.rb#4 - def importmap; end - - # source://importmap-rails/1.2.1/lib/importmap/engine.rb#4 - def importmap=(_arg0); end - - # source://railties/7.0.5/lib/rails/application.rb#370 - def initialize!(group = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/application.rb#129 - def initialized?; end - - # source://railties/7.0.5/lib/rails/application.rb#291 - def initializer(name, opts = T.unsafe(nil), &block); end - - # source://railties/7.0.5/lib/rails/application.rb#377 - def initializers; end - - # source://railties/7.0.5/lib/rails/application.rb#320 - def isolate_namespace(mod); end - - # source://railties/7.0.5/lib/rails/application.rb#153 - def key_generator; end - - # source://railties/7.0.5/lib/rails/application.rb#179 - def message_verifier(verifier_name); end - - # source://railties/7.0.5/lib/rails/application.rb#487 - def migration_railties; end - - # Lazy-load the precompile list so we don't cause asset compilation at app - # boot time, but ensure we cache the list so we don't recompute it for each - # request or test case. - # - # source://sprockets-rails//lib/sprockets/railtie.rb#51 - def precompiled_assets(clear_cache = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/application.rb#284 - def rake_tasks(&block); end - - # source://railties/7.0.5/lib/rails/application.rb#148 - def reload_routes!; end - - # source://railties/7.0.5/lib/rails/application.rb#99 - def reloader; end - - # source://railties/7.0.5/lib/rails/application.rb#99 - def reloaders; end - - # source://railties/7.0.5/lib/rails/application.rb#346 - def require_environment!; end - - # source://railties/7.0.5/lib/rails/application.rb#351 - def routes_reloader; end - - # source://railties/7.0.5/lib/rails/application.rb#133 - def run_load_hooks!; end - - # source://railties/7.0.5/lib/rails/application.rb#297 - def runner(&blk); end - - # source://railties/7.0.5/lib/rails/application.rb#97 - def sandbox; end - - # source://railties/7.0.5/lib/rails/application.rb#97 - def sandbox=(_arg0); end - - # source://railties/7.0.5/lib/rails/application.rb#97 - def sandbox?; end - - # source://railties/7.0.5/lib/rails/application.rb#415 - def secret_key_base; end - - # source://railties/7.0.5/lib/rails/application.rb#389 - def secrets; end - - # source://railties/7.0.5/lib/rails/application.rb#403 - def secrets=(_arg0); end - - # source://railties/7.0.5/lib/rails/application.rb#315 - def server(&blk); end - - # source://railties/7.0.5/lib/rails/application.rb#467 - def to_app; end - - # source://railties/7.0.5/lib/rails/application.rb#358 - def watchable_args; end - - protected - - # source://railties/7.0.5/lib/rails/application.rb#565 - def default_middleware_stack; end - - # source://railties/7.0.5/lib/rails/application.rb#531 - def ordered_railties; end - - # source://railties/7.0.5/lib/rails/application.rb#553 - def railties_initializers(current); end - - # source://railties/7.0.5/lib/rails/application.rb#520 - def run_console_blocks(app); end - - # source://railties/7.0.5/lib/rails/application.rb#510 - def run_generators_blocks(app); end - - # source://railties/7.0.5/lib/rails/application.rb#515 - def run_runner_blocks(app); end - - # source://railties/7.0.5/lib/rails/application.rb#525 - def run_server_blocks(app); end - - # source://railties/7.0.5/lib/rails/application.rb#499 - def run_tasks_blocks(app); end - - # source://railties/7.0.5/lib/rails/application.rb#570 - def validate_secret_key_base(secret_key_base); end - - private - - # source://railties/7.0.5/lib/rails/application.rb#604 - def build_middleware; end - - # source://railties/7.0.5/lib/rails/application.rb#597 - def build_request(env); end - - # source://railties/7.0.5/lib/rails/application.rb#608 - def coerce_same_site_protection(protection); end - - # source://railties/7.0.5/lib/rails/application.rb#581 - def generate_development_secret; end - - class << self - # source://railties/7.0.5/lib/rails/application.rb#339 - def add_lib_to_load_path!(root); end - - # source://railties/7.0.5/lib/rails/application.rb#81 - def create(initial_variable_values = T.unsafe(nil), &block); end - - # source://railties/7.0.5/lib/rails/application.rb#85 - def find_root(from); end - - # source://railties/7.0.5/lib/rails/application.rb#70 - def inherited(base); end - - # source://railties/7.0.5/lib/rails/application.rb#77 - def instance; end - - def new(*_arg0); end - end -end - -# Hack: We need to remove Rails' built in config.assets so we can -# do our own thing. -# -# source://sprockets-rails//lib/sprockets/railtie.rb#21 -class Rails::Application::Configuration < ::Rails::Engine::Configuration - # source://railties/7.0.5/lib/rails/application/configuration.rb#28 - def initialize(*_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def add_autoload_paths_to_load_path; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def add_autoload_paths_to_load_path=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def allow_concurrency; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def allow_concurrency=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#415 - def annotations; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#26 - def api_only; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#276 - def api_only=(value); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def asset_host; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def asset_host=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def autoflush_log; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def autoflush_log=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def beginning_of_week; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def beginning_of_week=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def cache_classes; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def cache_classes=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def cache_store; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def cache_store=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#361 - def colorize_logging; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#365 - def colorize_logging=(val); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def consider_all_requests_local; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def consider_all_requests_local=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def console; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def console=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#420 - def content_security_policy(&block); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def content_security_policy_nonce_directives; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def content_security_policy_nonce_directives=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def content_security_policy_nonce_generator; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def content_security_policy_nonce_generator=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def content_security_policy_report_only; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def content_security_policy_report_only=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def credentials; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def credentials=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#330 - def database_configuration; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#283 - def debug_exception_response_format; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#287 - def debug_exception_response_format=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#437 - def default_log_file; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def disable_sandbox; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def disable_sandbox=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def eager_load; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def eager_load=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def enable_dependency_loading; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def enable_dependency_loading=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#26 - def encoding; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#268 - def encoding=(value); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def exceptions_app; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def exceptions_app=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def file_watcher; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def file_watcher=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def filter_parameters; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def filter_parameters=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def filter_redirect; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def filter_redirect=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def force_ssl; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def force_ssl=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def helpers_paths; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def helpers_paths=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def host_authorization; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def host_authorization=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def hosts; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def hosts=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#312 - def load_database_yaml; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#88 - def load_defaults(target_version); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#26 - def loaded_config_version; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def log_formatter; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def log_formatter=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def log_level; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def log_level=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def log_tags; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def log_tags=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def logger; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def logger=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#289 - def paths; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#429 - def permissions_policy(&block); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def public_file_server; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def public_file_server=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def railties_order; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def railties_order=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def rake_eager_load; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def rake_eager_load=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def read_encrypted_secrets; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def read_encrypted_secrets=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def relative_url_root; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def relative_url_root=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def reload_classes_only_on_change; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def reload_classes_only_on_change=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def require_master_key; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def require_master_key=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def secret_key_base; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def secret_key_base=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def server_timing; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def server_timing=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def session_options; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def session_options=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#384 - def session_store(new_session_store = T.unsafe(nil), **options); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#411 - def session_store?; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def ssl_options; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def ssl_options=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def time_zone; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def time_zone=(_arg0); end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def x; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#13 - def x=(_arg0); end - - private - - # source://railties/7.0.5/lib/rails/application/configuration.rb#486 - def credentials_available_for_current_env?; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#470 - def default_credentials_content_path; end - - # source://railties/7.0.5/lib/rails/application/configuration.rb#478 - def default_credentials_key_path; end -end - -# source://railties/7.0.5/lib/rails/application.rb#103 -Rails::Application::INITIAL_VARIABLES = T.let(T.unsafe(nil), Array) - -# source://sprockets-rails//lib/sprockets/railtie.rb#57 -class Rails::Engine < ::Rails::Railtie - # source://railties/7.0.5/lib/rails/engine.rb#432 - def initialize; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#940 - def _load_seed_callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#928 - def _run_load_seed_callbacks(&block); end - - # source://railties/7.0.5/lib/rails/engine.rb#511 - def app; end - - # source://railties/7.0.5/lib/rails/engine.rb#528 - def call(env); end - - # source://railties/7.0.5/lib/rails/engine.rb#547 - def config; end - - # source://railties/7.0.5/lib/rails/engine.rb#484 - def eager_load!; end - - # source://railties/7.0.5/lib/rails/engine.rb#523 - def endpoint; end - - # source://railties/7.0.5/lib/rails/engine.rb#430 - def engine_name(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails/engine.rb#534 - def env_config; end - - # source://railties/7.0.5/lib/rails/engine.rb#494 - def helpers; end - - # source://railties/7.0.5/lib/rails/engine.rb#506 - def helpers_paths; end - - # source://railties/7.0.5/lib/rails/engine.rb#430 - def isolated?(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails/engine.rb#446 - def load_console(app = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#470 - def load_generators(app = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#455 - def load_runner(app = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#555 - def load_seed; end - - # source://railties/7.0.5/lib/rails/engine.rb#479 - def load_server(app = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#462 - def load_tasks(app = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#429 - def middleware(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails/engine.rb#429 - def paths(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails/engine.rb#489 - def railties; end - - # source://railties/7.0.5/lib/rails/engine.rb#429 - def root(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails/engine.rb#540 - def routes(&block); end - - # source://railties/7.0.5/lib/rails/engine.rb#654 - def routes?; end - - protected - - # source://railties/7.0.5/lib/rails/engine.rb#659 - def run_tasks_blocks(*_arg0); end - - private - - # source://railties/7.0.5/lib/rails/engine.rb#691 - def _all_autoload_once_paths; end - - # source://railties/7.0.5/lib/rails/engine.rb#695 - def _all_autoload_paths; end - - # source://railties/7.0.5/lib/rails/engine.rb#704 - def _all_load_paths(add_autoload_paths_to_load_path); end - - # source://railties/7.0.5/lib/rails/engine.rb#723 - def build_middleware; end - - # source://railties/7.0.5/lib/rails/engine.rb#715 - def build_request(env); end - - # source://railties/7.0.5/lib/rails/engine.rb#687 - def default_middleware_stack; end - - # source://railties/7.0.5/lib/rails/engine.rb#671 - def has_migrations?; end - - # source://railties/7.0.5/lib/rails/engine.rb#665 - def load_config_initializer(initializer); end - - class << self - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks=(value); end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#68 - def __callbacks?; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#932 - def _load_seed_callbacks; end - - # source://activesupport/7.0.5/lib/active_support/callbacks.rb#936 - def _load_seed_callbacks=(value); end - - # source://railties/7.0.5/lib/rails/engine.rb#353 - def called_from; end - - # source://railties/7.0.5/lib/rails/engine.rb#353 - def called_from=(_arg0); end - - # source://railties/7.0.5/lib/rails/engine.rb#358 - def eager_load!(*_arg0, **_arg1, &_arg2); end - - # source://railties/7.0.5/lib/rails/engine.rb#378 - def endpoint(endpoint = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/railtie.rb#176 - def engine_name(name = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#416 - def find(path); end - - # source://railties/7.0.5/lib/rails/engine.rb#374 - def find_root(from); end - - # source://railties/7.0.5/lib/rails/engine.rb#675 - def find_root_with_flag(flag, root_path, default = T.unsafe(nil)); end - - # source://railties/7.0.5/lib/rails/engine.rb#360 - def inherited(base); end - - # source://railties/7.0.5/lib/rails/engine.rb#384 - def isolate_namespace(mod); end - - # source://railties/7.0.5/lib/rails/engine.rb#353 - def isolated; end - - # source://railties/7.0.5/lib/rails/engine.rb#353 - def isolated=(_arg0); end - - # source://railties/7.0.5/lib/rails/engine.rb#353 - def isolated?; end - end -end - -# source://rails-html-sanitizer/1.6.0/lib/rails-html-sanitizer.rb#11 -Rails::Html = Rails::HTML - -# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#1 -module Sprockets - extend ::Sprockets::Utils - extend ::Sprockets::URIUtils - extend ::Sprockets::PathUtils - extend ::Sprockets::DigestUtils - extend ::Sprockets::PathDigestUtils - extend ::Sprockets::Dependencies - extend ::Sprockets::Compressing - extend ::Sprockets::Exporting - extend ::Sprockets::Processing - extend ::Sprockets::HTTPUtils - extend ::Sprockets::Transformers - extend ::Sprockets::Mime - extend ::Sprockets::Paths -end - -# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#2 -module Sprockets::Rails; end - -# Resolve assets referenced in CSS `url()` calls and replace them with the digested paths -# -# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#4 -class Sprockets::Rails::AssetUrlProcessor - class << self - # source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#6 - def call(input); end - end -end - -# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#5 -Sprockets::Rails::AssetUrlProcessor::REGEX = T.let(T.unsafe(nil), Regexp) - -# source://sprockets-rails//lib/sprockets/rails/context.rb#6 -module Sprockets::Rails::Context - include ::ActionView::Helpers::AssetUrlHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::ActionView::Helpers::AssetTagHelper - include GeneratedInstanceMethods - - mixes_in_class_methods GeneratedClassMethods - - # source://sprockets-rails//lib/sprockets/rails/context.rb#16 - def compute_asset_path(path, options = T.unsafe(nil)); end - - class << self - # @private - # - # source://sprockets-rails//lib/sprockets/rails/context.rb#10 - def included(klass); end - end - - module GeneratedClassMethods - def assets_prefix; end - def assets_prefix=(value); end - def assets_prefix?; end - def config; end - def config=(value); end - def config?; end - def digest_assets; end - def digest_assets=(value); end - def digest_assets?; end - end - - module GeneratedInstanceMethods - def assets_prefix; end - def assets_prefix=(value); end - def assets_prefix?; end - def config; end - def config=(value); end - def config?; end - def digest_assets; end - def digest_assets=(value); end - def digest_assets?; end - end -end - -# source://sprockets-rails//lib/sprockets/rails/helper.rb#8 -module Sprockets::Rails::Helper - include ::ActionView::Helpers::AssetUrlHelper - include ::ActionView::Helpers::CaptureHelper - include ::ActionView::Helpers::OutputSafetyHelper - include ::ActionView::Helpers::TagHelper - include ::ActionView::Helpers::AssetTagHelper - include ::Sprockets::Rails::Utils - include GeneratedInstanceMethods - - mixes_in_class_methods GeneratedClassMethods - - # Expand asset path to digested form. - # - # path - String path - # options - Hash options - # - # Returns String path or nil if no asset was found. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#113 - def asset_digest_path(path, options = T.unsafe(nil)); end - - # Experimental: Get integrity for asset path. - # - # path - String path - # options - Hash options - # - # Returns String integrity attribute or nil if no asset was found. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#125 - def asset_integrity(path, options = T.unsafe(nil)); end - - # Writes over the built in ActionView::Helpers::AssetUrlHelper#compute_asset_path - # to use the asset pipeline. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#77 - def compute_asset_path(path, options = T.unsafe(nil)); end - - # Override javascript tag helper to provide debugging support. - # - # Eventually will be deprecated and replaced by source maps. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#136 - def javascript_include_tag(*sources); end - - # Resolve the asset path against the Sprockets manifest or environment. - # Returns nil if it's an asset we don't know about. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#101 - def resolve_asset_path(path, allow_non_precompiled = T.unsafe(nil)); end - - # Override stylesheet tag helper to provide debugging support. - # - # Eventually will be deprecated and replaced by source maps. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#165 - def stylesheet_link_tag(*sources); end - - protected - - # List of resolvers in `config.assets.resolve_with` order. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#250 - def asset_resolver_strategies; end - - # This is awkward: `integrity` is a boolean option indicating whether - # we want to include or omit the subresource integrity hash, but the - # options hash is also passed through as literal tag attributes. - # That means we have to delete the shortcut boolean option so it - # doesn't bleed into the tag attributes, but also check its value if - # it's boolean-ish. - # - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#198 - def compute_integrity?(options); end - - # Append ?body=1 if debug is on and we're on old Sprockets. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#258 - def legacy_debug_path(path, debug); end - - # Internal method to support multifile debugging. Will - # eventually be removed w/ Sprockets 3.x. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#226 - def lookup_debug_asset(path, options = T.unsafe(nil)); end - - # compute_asset_extname is in AV::Helpers::AssetUrlHelper - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#235 - def path_with_extname(path, options); end - - # Enable split asset debugging. Eventually will be deprecated - # and replaced by source maps in Sprockets 3.x. - # - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#218 - def request_debug_assets?; end - - # Try each asset resolver and return the first non-nil result. - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#241 - def resolve_asset; end - - # Only serve integrity metadata for HTTPS requests: - # http://www.w3.org/TR/SRI/#non-secure-contexts-remain-non-secure - # - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#212 - def secure_subresource_integrity_context?; end - - class << self - # @private - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#60 - def extended(obj); end - - # @private - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#43 - def included(klass); end - end - - module GeneratedClassMethods - def assets_environment; end - def assets_environment=(value); end - def assets_environment?; end - def assets_manifest; end - def assets_manifest=(value); end - def assets_manifest?; end - def assets_precompile; end - def assets_precompile=(value); end - def assets_precompile?; end - def assets_prefix; end - def assets_prefix=(value); end - def assets_prefix?; end - def check_precompiled_asset; end - def check_precompiled_asset=(value); end - def check_precompiled_asset?; end - def debug_assets; end - def debug_assets=(value); end - def debug_assets?; end - def digest_assets; end - def digest_assets=(value); end - def digest_assets?; end - def precompiled_asset_checker; end - def precompiled_asset_checker=(value); end - def precompiled_asset_checker?; end - def resolve_assets_with; end - def resolve_assets_with=(value); end - def resolve_assets_with?; end - def unknown_asset_fallback; end - def unknown_asset_fallback=(value); end - def unknown_asset_fallback?; end - end - - module GeneratedInstanceMethods - def assets_environment; end - def assets_environment=(value); end - def assets_environment?; end - def assets_manifest; end - def assets_manifest=(value); end - def assets_manifest?; end - def assets_precompile; end - def assets_precompile=(value); end - def assets_precompile?; end - def assets_prefix; end - def assets_prefix=(value); end - def assets_prefix?; end - def check_precompiled_asset; end - def check_precompiled_asset=(value); end - def check_precompiled_asset?; end - def debug_assets; end - def debug_assets=(value); end - def debug_assets?; end - def digest_assets; end - def digest_assets=(value); end - def digest_assets?; end - def precompiled_asset_checker; end - def precompiled_asset_checker=(value); end - def precompiled_asset_checker?; end - def resolve_assets_with; end - def resolve_assets_with=(value); end - def resolve_assets_with?; end - def unknown_asset_fallback; end - def unknown_asset_fallback=(value); end - def unknown_asset_fallback?; end - end -end - -# source://sprockets-rails//lib/sprockets/rails/helper.rb#9 -class Sprockets::Rails::Helper::AssetNotFound < ::StandardError; end - -# source://sprockets-rails//lib/sprockets/rails/helper.rb#10 -class Sprockets::Rails::Helper::AssetNotPrecompiled < ::StandardError; end - -# source://sprockets-rails//lib/sprockets/rails/helper.rb#12 -class Sprockets::Rails::Helper::AssetNotPrecompiledError < ::Sprockets::Rails::Helper::AssetNotPrecompiled - include ::Sprockets::Rails::Utils - - # @return [AssetNotPrecompiledError] a new instance of AssetNotPrecompiledError - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#14 - def initialize(source); end -end - -# source://sprockets-rails//lib/sprockets/rails/helper.rb#35 -Sprockets::Rails::Helper::VIEW_ACCESSORS = T.let(T.unsafe(nil), Array) - -# Use a separate module since Helper is mixed in and we needn't pollute -# the class namespace with our internals. -# -# source://sprockets-rails//lib/sprockets/rails/helper.rb#269 -module Sprockets::Rails::HelperAssetResolvers - class << self - # source://sprockets-rails//lib/sprockets/rails/helper.rb#270 - def [](name); end - end -end - -# source://sprockets-rails//lib/sprockets/rails/helper.rb#315 -class Sprockets::Rails::HelperAssetResolvers::Environment - # @raise [ArgumentError] - # @return [Environment] a new instance of Environment - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#316 - def initialize(view); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#323 - def asset_path(path, digest, allow_non_precompiled = T.unsafe(nil)); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#336 - def digest_path(path, allow_non_precompiled = T.unsafe(nil)); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#357 - def find_asset(path, options = T.unsafe(nil)); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#347 - def find_debug_asset(path); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#343 - def integrity(path); end - - private - - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#367 - def precompiled?(path); end - - # @raise [Helper::AssetNotPrecompiledError] - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#371 - def raise_unless_precompiled_asset(path); end -end - -# source://sprockets-rails//lib/sprockets/rails/helper.rb#281 -class Sprockets::Rails::HelperAssetResolvers::Manifest - # @raise [ArgumentError] - # @return [Manifest] a new instance of Manifest - # - # source://sprockets-rails//lib/sprockets/rails/helper.rb#282 - def initialize(view); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#287 - def asset_path(path, digest, allow_non_precompiled = T.unsafe(nil)); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#293 - def digest_path(path, allow_non_precompiled = T.unsafe(nil)); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#303 - def find_debug_asset(path); end - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#297 - def integrity(path); end - - private - - # source://sprockets-rails//lib/sprockets/rails/helper.rb#308 - def metadata(path); end -end - -# source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#3 -class Sprockets::Rails::QuietAssets - # @return [QuietAssets] a new instance of QuietAssets - # - # source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#4 - def initialize(app); end - - # source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#9 - def call(env); end -end - -# source://sprockets-rails//lib/sprockets/rails/route_wrapper.rb#3 -module Sprockets::Rails::RouteWrapper - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/rails/route_wrapper.rb#9 - def internal?; end - - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/rails/route_wrapper.rb#5 - def internal_assets_path?; end - - class << self - # @private - # - # source://sprockets-rails//lib/sprockets/rails/route_wrapper.rb#13 - def included(klass); end - end -end - -# Rewrites source mapping urls with the digested paths and protect against semicolon appending with a dummy comment line -# -# source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#4 -class Sprockets::Rails::SourcemappingUrlProcessor - class << self - # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#8 - def call(input); end - - private - - # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#25 - def combine_sourcemap_logical_path(sourcefile:, sourcemap:); end - - # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#47 - def removed_sourcemap_comment(sourcemap_logical_path, filename:, env:); end - - # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#33 - def resolved_sourcemap_comment(sourcemap_logical_path, context:); end - - # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#37 - def sourcemap_asset_path(sourcemap_logical_path, context:); end - end -end - -# source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#5 -Sprockets::Rails::SourcemappingUrlProcessor::REGEX = T.let(T.unsafe(nil), Regexp) - -# source://sprockets-rails//lib/sprockets/rails/utils.rb#5 -module Sprockets::Rails::Utils - # @return [Boolean] - # - # source://sprockets-rails//lib/sprockets/rails/utils.rb#6 - def using_sprockets4?; end -end - -# source://sprockets-rails//lib/sprockets/rails/version.rb#3 -Sprockets::Rails::VERSION = T.let(T.unsafe(nil), String) - -# source://sprockets-rails//lib/sprockets/railtie.rb#70 -class Sprockets::Railtie < ::Rails::Railtie - include ::Sprockets::Rails::Utils - - # source://sprockets-rails//lib/sprockets/railtie.rb#182 - def build_environment(app, initialized = T.unsafe(nil)); end - - class << self - # source://sprockets-rails//lib/sprockets/railtie.rb#213 - def build_manifest(app); end - end -end - -# source://sprockets-rails//lib/sprockets/railtie.rb#88 -Sprockets::Railtie::LOOSE_APP_ASSETS = T.let(T.unsafe(nil), Proc) - -# source://sprockets-rails//lib/sprockets/railtie.rb#73 -class Sprockets::Railtie::ManifestNeededError < ::StandardError - # @return [ManifestNeededError] a new instance of ManifestNeededError - # - # source://sprockets-rails//lib/sprockets/railtie.rb#74 - def initialize; end -end - -# source://sprockets-rails//lib/sprockets/railtie.rb#93 -class Sprockets::Railtie::OrderedOptions < ::ActiveSupport::OrderedOptions - # source://sprockets-rails//lib/sprockets/railtie.rb#94 - def configure(&block); end -end - -# source://sprockets/4.2.0/lib/sprockets/sass_cache_store.rb#29 -Sprockets::SassCacheStore = Sprockets::SassProcessor::CacheStore - -# source://sprockets/4.2.0/lib/sprockets/sass_processor.rb#312 -Sprockets::SassFunctions = Sprockets::SassProcessor::Functions - -# source://sprockets/4.2.0/lib/sprockets/version.rb#3 -Sprockets::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/sprockets-rails@3.5.2.rbi b/sorbet/rbi/gems/sprockets-rails@3.5.2.rbi new file mode 100644 index 000000000..3d974fd04 --- /dev/null +++ b/sorbet/rbi/gems/sprockets-rails@3.5.2.rbi @@ -0,0 +1,1157 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `sprockets-rails` gem. +# Please instead update this file by running `bin/tapioca gem sprockets-rails`. + + +# source://sprockets-rails//lib/sprockets/railtie.rb#18 +module Rails + class << self + # source://railties/7.2.0/lib/rails.rb#44 + def app_class; end + + # source://railties/7.2.0/lib/rails.rb#44 + def app_class=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#45 + def application; end + + # source://railties/7.2.0/lib/rails.rb#43 + def application=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#126 + def autoloaders; end + + # source://railties/7.2.0/lib/rails.rb#56 + def backtrace_cleaner; end + + # source://railties/7.2.0/lib/rails.rb#44 + def cache; end + + # source://railties/7.2.0/lib/rails.rb#44 + def cache=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#52 + def configuration; end + + # source://railties/7.2.0/lib/rails/deprecator.rb#4 + def deprecator; end + + # source://railties/7.2.0/lib/rails.rb#75 + def env; end + + # source://railties/7.2.0/lib/rails.rb#82 + def env=(environment); end + + # source://railties/7.2.0/lib/rails.rb#93 + def error; end + + # source://railties/7.2.0/lib/rails/gem_version.rb#5 + def gem_version; end + + # source://railties/7.2.0/lib/rails.rb#106 + def groups(*groups); end + + # source://railties/7.2.0/lib/rails.rb#49 + def initialize!(*_arg0, **_arg1, &_arg2); end + + # source://railties/7.2.0/lib/rails.rb#49 + def initialized?(*_arg0, **_arg1, &_arg2); end + + # source://railties/7.2.0/lib/rails.rb#44 + def logger; end + + # source://railties/7.2.0/lib/rails.rb#44 + def logger=(_arg0); end + + # source://railties/7.2.0/lib/rails.rb#122 + def public_path; end + + # source://railties/7.2.0/lib/rails.rb#65 + def root; end + + # source://railties/7.2.0/lib/rails/version.rb#7 + def version; end + end +end + +# source://sprockets-rails//lib/sprockets/railtie.rb#19 +class Rails::Application < ::Rails::Engine + # source://railties/7.2.0/lib/rails/application.rb#108 + def initialize(initial_variable_values = T.unsafe(nil), &block); end + + # Called from asset helpers to alert you if you reference an asset URL that + # isn't precompiled and hence won't be available in production. + # + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/railtie.rb#38 + def asset_precompiled?(logical_path); end + + # Returns Sprockets::Environment for app config. + # + # source://sprockets-rails//lib/sprockets/railtie.rb#31 + def assets; end + + # Returns Sprockets::Environment for app config. + # + # source://sprockets-rails//lib/sprockets/railtie.rb#31 + def assets=(_arg0); end + + # Returns Sprockets::Manifest for app config. + # + # source://sprockets-rails//lib/sprockets/railtie.rb#34 + def assets_manifest; end + + # Returns Sprockets::Manifest for app config. + # + # source://sprockets-rails//lib/sprockets/railtie.rb#34 + def assets_manifest=(_arg0); end + + # source://railties/7.2.0/lib/rails/application.rb#101 + def autoloaders; end + + # source://railties/7.2.0/lib/rails/engine.rb#516 + def build_middleware_stack; end + + # source://railties/7.2.0/lib/rails/application.rb#439 + def config; end + + # source://railties/7.2.0/lib/rails/application.rb#443 + def config=(_arg0); end + + # source://railties/7.2.0/lib/rails/application.rb#276 + def config_for(name, env: T.unsafe(nil)); end + + # source://railties/7.2.0/lib/rails/application.rb#359 + def console(&blk); end + + # source://railties/7.2.0/lib/rails/application.rb#480 + def credentials; end + + # source://railties/7.2.0/lib/rails/application.rb#444 + def credentials=(_arg0); end + + # source://railties/7.2.0/lib/rails/application.rb#103 + def default_url_options(*_arg0, **_arg1, &_arg2); end + + # source://railties/7.2.0/lib/rails/application.rb#103 + def default_url_options=(arg); end + + # source://railties/7.2.0/lib/rails/application.rb#232 + def deprecators; end + + # source://railties/7.2.0/lib/rails/application.rb#538 + def eager_load!; end + + # source://railties/7.2.0/lib/rails/application.rb#499 + def encrypted(path, key_path: T.unsafe(nil), env_key: T.unsafe(nil)); end + + # source://railties/7.2.0/lib/rails/application.rb#305 + def env_config; end + + # source://railties/7.2.0/lib/rails/application.rb#101 + def executor; end + + # source://railties/7.2.0/lib/rails/application.rb#365 + def generators(&blk); end + + # source://railties/7.2.0/lib/rails/application.rb#512 + def helpers_paths; end + + # source://importmap-rails/2.0.1/lib/importmap/engine.rb#4 + def importmap; end + + # source://importmap-rails/2.0.1/lib/importmap/engine.rb#4 + def importmap=(_arg0); end + + # source://railties/7.2.0/lib/rails/application.rb#426 + def initialize!(group = T.unsafe(nil)); end + + # source://railties/7.2.0/lib/rails/application.rb#133 + def initialized?; end + + # source://railties/7.2.0/lib/rails/application.rb#347 + def initializer(name, opts = T.unsafe(nil), &block); end + + # source://railties/7.2.0/lib/rails/application.rb#433 + def initializers; end + + # source://railties/7.2.0/lib/rails/application.rb#376 + def isolate_namespace(mod); end + + # source://railties/7.2.0/lib/rails/application.rb#160 + def key_generator(secret_key_base = T.unsafe(nil)); end + + # source://railties/7.2.0/lib/rails/application.rb#532 + def load_generators(app = T.unsafe(nil)); end + + # source://railties/7.2.0/lib/rails/application.rb#224 + def message_verifier(verifier_name); end + + # source://railties/7.2.0/lib/rails/application.rb#196 + def message_verifiers; end + + # source://railties/7.2.0/lib/rails/application.rb#528 + def migration_railties; end + + # Lazy-load the precompile list so we don't cause asset compilation at app + # boot time, but ensure we cache the list so we don't recompute it for each + # request or test case. + # + # source://sprockets-rails//lib/sprockets/railtie.rb#52 + def precompiled_assets(clear_cache = T.unsafe(nil)); end + + # source://railties/7.2.0/lib/rails/application.rb#340 + def rake_tasks(&block); end + + # source://railties/7.2.0/lib/rails/application.rb#152 + def reload_routes!; end + + # source://railties/7.2.0/lib/rails/application.rb#101 + def reloader; end + + # source://railties/7.2.0/lib/rails/application.rb#101 + def reloaders; end + + # source://railties/7.2.0/lib/rails/application.rb#402 + def require_environment!; end + + # source://railties/7.2.0/lib/rails/application.rb#407 + def routes_reloader; end + + # source://railties/7.2.0/lib/rails/application.rb#137 + def run_load_hooks!; end + + # source://railties/7.2.0/lib/rails/application.rb#353 + def runner(&blk); end + + # source://railties/7.2.0/lib/rails/application.rb#99 + def sandbox; end + + # source://railties/7.2.0/lib/rails/application.rb#99 + def sandbox=(_arg0); end + + # source://railties/7.2.0/lib/rails/application.rb#99 + def sandbox?; end + + # source://railties/7.2.0/lib/rails/application.rb#462 + def secret_key_base; end + + # source://railties/7.2.0/lib/rails/application.rb#371 + def server(&blk); end + + # source://railties/7.2.0/lib/rails/application.rb#508 + def to_app; end + + # source://railties/7.2.0/lib/rails/application.rb#414 + def watchable_args; end + + protected + + # source://railties/7.2.0/lib/rails/application.rb#611 + def default_middleware_stack; end + + # source://railties/7.2.0/lib/rails/application.rb#616 + def ensure_generator_templates_added; end + + # source://railties/7.2.0/lib/rails/application.rb#577 + def ordered_railties; end + + # source://railties/7.2.0/lib/rails/application.rb#599 + def railties_initializers(current); end + + # source://railties/7.2.0/lib/rails/application.rb#566 + def run_console_blocks(app); end + + # source://railties/7.2.0/lib/rails/application.rb#556 + def run_generators_blocks(app); end + + # source://railties/7.2.0/lib/rails/application.rb#561 + def run_runner_blocks(app); end + + # source://railties/7.2.0/lib/rails/application.rb#571 + def run_server_blocks(app); end + + # source://railties/7.2.0/lib/rails/application.rb#545 + def run_tasks_blocks(app); end + + private + + # source://railties/7.2.0/lib/rails/application.rb#629 + def build_middleware; end + + # source://railties/7.2.0/lib/rails/application.rb#622 + def build_request(env); end + + # source://railties/7.2.0/lib/rails/application.rb#633 + def coerce_same_site_protection(protection); end + + # source://railties/7.2.0/lib/rails/application.rb#637 + def filter_parameters; end + + class << self + # source://railties/7.2.0/lib/rails/application.rb#395 + def add_lib_to_load_path!(root); end + + # source://railties/7.2.0/lib/rails/application.rb#83 + def create(initial_variable_values = T.unsafe(nil), &block); end + + # source://railties/7.2.0/lib/rails/application.rb#87 + def find_root(from); end + + # source://railties/7.2.0/lib/rails/application.rb#70 + def inherited(base); end + + # source://railties/7.2.0/lib/rails/application.rb#79 + def instance; end + + def new(*_arg0); end + end +end + +# Hack: We need to remove Rails' built in config.assets so we can +# do our own thing. +# +# source://sprockets-rails//lib/sprockets/railtie.rb#22 +class Rails::Application::Configuration < ::Rails::Engine::Configuration + # source://railties/7.2.0/lib/rails/application/configuration.rb#30 + def initialize(*_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def add_autoload_paths_to_load_path; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def add_autoload_paths_to_load_path=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def allow_concurrency; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def allow_concurrency=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#558 + def annotations; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#28 + def api_only; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#373 + def api_only=(value); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def asset_host; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def asset_host=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def assume_ssl; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def assume_ssl=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def autoflush_log; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def autoflush_log=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#468 + def autoload_lib(ignore:); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#480 + def autoload_lib_once(ignore:); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def beginning_of_week; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def beginning_of_week=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#385 + def broadcast_log_level; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def cache_classes; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def cache_classes=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def cache_store; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def cache_store=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#492 + def colorize_logging; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#496 + def colorize_logging=(val); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def consider_all_requests_local; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def consider_all_requests_local=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def console; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def console=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#563 + def content_security_policy(&block); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def content_security_policy_nonce_directives; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def content_security_policy_nonce_directives=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def content_security_policy_nonce_generator; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def content_security_policy_nonce_generator=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def content_security_policy_report_only; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def content_security_policy_report_only=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def credentials; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def credentials=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#431 + def database_configuration; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#387 + def debug_exception_response_format; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#391 + def debug_exception_response_format=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#580 + def default_log_file; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def disable_sandbox; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def disable_sandbox=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def dom_testing_default_html_version; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def dom_testing_default_html_version=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def eager_load; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def eager_load=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#349 + def enable_reloading; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#353 + def enable_reloading=(value); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#28 + def encoding; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#365 + def encoding=(value); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def exceptions_app; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def exceptions_app=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def file_watcher; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def file_watcher=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def filter_parameters; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def filter_parameters=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def filter_redirect; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def filter_redirect=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def force_ssl; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def force_ssl=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def helpers_paths; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def helpers_paths=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def host_authorization; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def host_authorization=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def hosts; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def hosts=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#592 + def inspect; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#413 + def load_database_yaml; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#91 + def load_defaults(target_version); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#28 + def loaded_config_version; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def log_file_size; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def log_file_size=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def log_formatter; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def log_formatter=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#28 + def log_level; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#380 + def log_level=(level); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def log_tags; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def log_tags=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def logger; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def logger=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#393 + def paths; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#572 + def permissions_policy(&block); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def precompile_filter_parameters; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def precompile_filter_parameters=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def public_file_server; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def public_file_server=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def railties_order; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def railties_order=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def rake_eager_load; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def rake_eager_load=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#357 + def read_encrypted_secrets; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#361 + def read_encrypted_secrets=(value); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def relative_url_root; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def relative_url_root=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def reload_classes_only_on_change; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def reload_classes_only_on_change=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#345 + def reloading_enabled?; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def require_master_key; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def require_master_key=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def sandbox_by_default; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def sandbox_by_default=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#501 + def secret_key_base; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#511 + def secret_key_base=(new_secret_key_base); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def server_timing; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def server_timing=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def session_options; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def session_options=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#538 + def session_store(new_session_store = T.unsafe(nil), **options); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#554 + def session_store?; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def ssl_options; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def ssl_options=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def time_zone; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def time_zone=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def x; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def x=(_arg0); end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def yjit; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#14 + def yjit=(_arg0); end + + private + + # source://railties/7.2.0/lib/rails/application/configuration.rb#619 + def credentials_defaults; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#629 + def generate_local_secret; end + + # source://railties/7.2.0/lib/rails/application/configuration.rb#641 + def generate_local_secret?; end +end + +# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#1 +module Sprockets + extend ::Sprockets::Utils + extend ::Sprockets::URIUtils + extend ::Sprockets::PathUtils + extend ::Sprockets::DigestUtils + extend ::Sprockets::PathDigestUtils + extend ::Sprockets::Dependencies + extend ::Sprockets::Compressing + extend ::Sprockets::Exporting + extend ::Sprockets::Processing + extend ::Sprockets::HTTPUtils + extend ::Sprockets::Transformers + extend ::Sprockets::Mime + extend ::Sprockets::Paths +end + +# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#2 +module Sprockets::Rails + class << self + # source://sprockets-rails//lib/sprockets/rails/deprecator.rb#7 + def deprecator; end + end +end + +# Resolve assets referenced in CSS `url()` calls and replace them with the digested paths +# +# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#4 +class Sprockets::Rails::AssetUrlProcessor + class << self + # source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#6 + def call(input); end + end +end + +# source://sprockets-rails//lib/sprockets/rails/asset_url_processor.rb#5 +Sprockets::Rails::AssetUrlProcessor::REGEX = T.let(T.unsafe(nil), Regexp) + +# source://sprockets-rails//lib/sprockets/rails/context.rb#6 +module Sprockets::Rails::Context + include ::ActionView::Helpers::AssetUrlHelper + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::ActionView::Helpers::AssetTagHelper + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + # source://sprockets-rails//lib/sprockets/rails/context.rb#16 + def compute_asset_path(path, options = T.unsafe(nil)); end + + class << self + # @private + # + # source://sprockets-rails//lib/sprockets/rails/context.rb#10 + def included(klass); end + end + + module GeneratedClassMethods + def assets_prefix; end + def assets_prefix=(value); end + def assets_prefix?; end + def config; end + def config=(value); end + def config?; end + def digest_assets; end + def digest_assets=(value); end + def digest_assets?; end + end + + module GeneratedInstanceMethods + def assets_prefix; end + def assets_prefix=(value); end + def assets_prefix?; end + def config; end + def config=(value); end + def config?; end + def digest_assets; end + def digest_assets=(value); end + def digest_assets?; end + end +end + +# source://sprockets-rails//lib/sprockets/rails/helper.rb#8 +module Sprockets::Rails::Helper + include ::ActionView::Helpers::AssetUrlHelper + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::ActionView::Helpers::AssetTagHelper + include ::Sprockets::Rails::Utils + include GeneratedInstanceMethods + + mixes_in_class_methods GeneratedClassMethods + + # Expand asset path to digested form. + # + # path - String path + # options - Hash options + # + # Returns String path or nil if no asset was found. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#112 + def asset_digest_path(path, options = T.unsafe(nil)); end + + # Experimental: Get integrity for asset path. + # + # path - String path + # options - Hash options + # + # Returns String integrity attribute or nil if no asset was found. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#124 + def asset_integrity(path, options = T.unsafe(nil)); end + + # Writes over the built in ActionView::Helpers::AssetUrlHelper#compute_asset_path + # to use the asset pipeline. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#77 + def compute_asset_path(path, options = T.unsafe(nil)); end + + # Override javascript tag helper to provide debugging support. + # + # Eventually will be deprecated and replaced by source maps. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#135 + def javascript_include_tag(*sources); end + + # Resolve the asset path against the Sprockets manifest or environment. + # Returns nil if it's an asset we don't know about. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#100 + def resolve_asset_path(path, allow_non_precompiled = T.unsafe(nil)); end + + # Override stylesheet tag helper to provide debugging support. + # + # Eventually will be deprecated and replaced by source maps. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#164 + def stylesheet_link_tag(*sources); end + + protected + + # List of resolvers in `config.assets.resolve_with` order. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#249 + def asset_resolver_strategies; end + + # This is awkward: `integrity` is a boolean option indicating whether + # we want to include or omit the subresource integrity hash, but the + # options hash is also passed through as literal tag attributes. + # That means we have to delete the shortcut boolean option so it + # doesn't bleed into the tag attributes, but also check its value if + # it's boolean-ish. + # + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#197 + def compute_integrity?(options); end + + # Append ?body=1 if debug is on and we're on old Sprockets. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#257 + def legacy_debug_path(path, debug); end + + # Internal method to support multifile debugging. Will + # eventually be removed w/ Sprockets 3.x. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#225 + def lookup_debug_asset(path, options = T.unsafe(nil)); end + + # compute_asset_extname is in AV::Helpers::AssetUrlHelper + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#234 + def path_with_extname(path, options); end + + # Enable split asset debugging. Eventually will be deprecated + # and replaced by source maps in Sprockets 3.x. + # + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#217 + def request_debug_assets?; end + + # Try each asset resolver and return the first non-nil result. + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#240 + def resolve_asset; end + + # Only serve integrity metadata for HTTPS requests: + # http://www.w3.org/TR/SRI/#non-secure-contexts-remain-non-secure + # + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#211 + def secure_subresource_integrity_context?; end + + class << self + # @private + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#60 + def extended(obj); end + + # @private + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#43 + def included(klass); end + end + + module GeneratedClassMethods + def assets_environment; end + def assets_environment=(value); end + def assets_environment?; end + def assets_manifest; end + def assets_manifest=(value); end + def assets_manifest?; end + def assets_precompile; end + def assets_precompile=(value); end + def assets_precompile?; end + def assets_prefix; end + def assets_prefix=(value); end + def assets_prefix?; end + def check_precompiled_asset; end + def check_precompiled_asset=(value); end + def check_precompiled_asset?; end + def debug_assets; end + def debug_assets=(value); end + def debug_assets?; end + def digest_assets; end + def digest_assets=(value); end + def digest_assets?; end + def precompiled_asset_checker; end + def precompiled_asset_checker=(value); end + def precompiled_asset_checker?; end + def resolve_assets_with; end + def resolve_assets_with=(value); end + def resolve_assets_with?; end + def unknown_asset_fallback; end + def unknown_asset_fallback=(value); end + def unknown_asset_fallback?; end + end + + module GeneratedInstanceMethods + def assets_environment; end + def assets_environment=(value); end + def assets_environment?; end + def assets_manifest; end + def assets_manifest=(value); end + def assets_manifest?; end + def assets_precompile; end + def assets_precompile=(value); end + def assets_precompile?; end + def assets_prefix; end + def assets_prefix=(value); end + def assets_prefix?; end + def check_precompiled_asset; end + def check_precompiled_asset=(value); end + def check_precompiled_asset?; end + def debug_assets; end + def debug_assets=(value); end + def debug_assets?; end + def digest_assets; end + def digest_assets=(value); end + def digest_assets?; end + def precompiled_asset_checker; end + def precompiled_asset_checker=(value); end + def precompiled_asset_checker?; end + def resolve_assets_with; end + def resolve_assets_with=(value); end + def resolve_assets_with?; end + def unknown_asset_fallback; end + def unknown_asset_fallback=(value); end + def unknown_asset_fallback?; end + end +end + +# source://sprockets-rails//lib/sprockets/rails/helper.rb#9 +class Sprockets::Rails::Helper::AssetNotFound < ::StandardError; end + +# source://sprockets-rails//lib/sprockets/rails/helper.rb#10 +class Sprockets::Rails::Helper::AssetNotPrecompiled < ::StandardError; end + +# source://sprockets-rails//lib/sprockets/rails/helper.rb#12 +class Sprockets::Rails::Helper::AssetNotPrecompiledError < ::Sprockets::Rails::Helper::AssetNotPrecompiled + include ::Sprockets::Rails::Utils + + # @return [AssetNotPrecompiledError] a new instance of AssetNotPrecompiledError + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#14 + def initialize(source); end +end + +# source://sprockets-rails//lib/sprockets/rails/helper.rb#35 +Sprockets::Rails::Helper::VIEW_ACCESSORS = T.let(T.unsafe(nil), Array) + +# Use a separate module since Helper is mixed in and we needn't pollute +# the class namespace with our internals. +# +# source://sprockets-rails//lib/sprockets/rails/helper.rb#268 +module Sprockets::Rails::HelperAssetResolvers + class << self + # source://sprockets-rails//lib/sprockets/rails/helper.rb#269 + def [](name); end + end +end + +# source://sprockets-rails//lib/sprockets/rails/helper.rb#314 +class Sprockets::Rails::HelperAssetResolvers::Environment + # @raise [ArgumentError] + # @return [Environment] a new instance of Environment + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#315 + def initialize(view); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#322 + def asset_path(path, digest, allow_non_precompiled = T.unsafe(nil)); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#335 + def digest_path(path, allow_non_precompiled = T.unsafe(nil)); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#356 + def find_asset(path, options = T.unsafe(nil)); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#346 + def find_debug_asset(path); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#342 + def integrity(path); end + + private + + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#366 + def precompiled?(path); end + + # @raise [Helper::AssetNotPrecompiledError] + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#370 + def raise_unless_precompiled_asset(path); end +end + +# source://sprockets-rails//lib/sprockets/rails/helper.rb#280 +class Sprockets::Rails::HelperAssetResolvers::Manifest + # @raise [ArgumentError] + # @return [Manifest] a new instance of Manifest + # + # source://sprockets-rails//lib/sprockets/rails/helper.rb#281 + def initialize(view); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#286 + def asset_path(path, digest, allow_non_precompiled = T.unsafe(nil)); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#292 + def digest_path(path, allow_non_precompiled = T.unsafe(nil)); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#302 + def find_debug_asset(path); end + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#296 + def integrity(path); end + + private + + # source://sprockets-rails//lib/sprockets/rails/helper.rb#307 + def metadata(path); end +end + +# source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#3 +class Sprockets::Rails::LoggerSilenceError < ::StandardError; end + +# source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#5 +class Sprockets::Rails::QuietAssets + # @return [QuietAssets] a new instance of QuietAssets + # + # source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#6 + def initialize(app); end + + # source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#11 + def call(env); end + + private + + # @raise [LoggerSilenceError] + # + # source://sprockets-rails//lib/sprockets/rails/quiet_assets.rb#22 + def raise_logger_silence_error; end +end + +# source://sprockets-rails//lib/sprockets/rails/route_wrapper.rb#3 +module Sprockets::Rails::RouteWrapper + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/rails/route_wrapper.rb#8 + def internal?; end + + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/rails/route_wrapper.rb#4 + def internal_assets_path?; end +end + +# Rewrites source mapping urls with the digested paths and protect against semicolon appending with a dummy comment line +# +# source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#4 +class Sprockets::Rails::SourcemappingUrlProcessor + class << self + # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#8 + def call(input); end + + private + + # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#25 + def combine_sourcemap_logical_path(sourcefile:, sourcemap:); end + + # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#47 + def removed_sourcemap_comment(sourcemap_logical_path, filename:, env:); end + + # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#33 + def resolved_sourcemap_comment(sourcemap_logical_path, context:); end + + # source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#37 + def sourcemap_asset_path(sourcemap_logical_path, context:); end + end +end + +# source://sprockets-rails//lib/sprockets/rails/sourcemapping_url_processor.rb#5 +Sprockets::Rails::SourcemappingUrlProcessor::REGEX = T.let(T.unsafe(nil), Regexp) + +# source://sprockets-rails//lib/sprockets/rails/utils.rb#5 +module Sprockets::Rails::Utils + # @return [Boolean] + # + # source://sprockets-rails//lib/sprockets/rails/utils.rb#6 + def using_sprockets4?; end +end + +# source://sprockets-rails//lib/sprockets/rails/version.rb#3 +Sprockets::Rails::VERSION = T.let(T.unsafe(nil), String) + +# source://sprockets-rails//lib/sprockets/railtie.rb#60 +class Sprockets::Railtie < ::Rails::Railtie + include ::Sprockets::Rails::Utils + + # source://sprockets-rails//lib/sprockets/railtie.rb#182 + def build_environment(app, initialized = T.unsafe(nil)); end + + class << self + # source://sprockets-rails//lib/sprockets/railtie.rb#213 + def build_manifest(app); end + end +end + +# source://sprockets-rails//lib/sprockets/railtie.rb#78 +Sprockets::Railtie::LOOSE_APP_ASSETS = T.let(T.unsafe(nil), Proc) + +# source://sprockets-rails//lib/sprockets/railtie.rb#63 +class Sprockets::Railtie::ManifestNeededError < ::StandardError + # @return [ManifestNeededError] a new instance of ManifestNeededError + # + # source://sprockets-rails//lib/sprockets/railtie.rb#64 + def initialize; end +end + +# source://sprockets-rails//lib/sprockets/railtie.rb#83 +class Sprockets::Railtie::OrderedOptions < ::ActiveSupport::OrderedOptions + # source://sprockets-rails//lib/sprockets/railtie.rb#84 + def configure(&block); end +end diff --git a/sorbet/rbi/gems/sprockets@4.2.0.rbi b/sorbet/rbi/gems/sprockets@4.2.1.rbi similarity index 99% rename from sorbet/rbi/gems/sprockets@4.2.0.rbi rename to sorbet/rbi/gems/sprockets@4.2.1.rbi index 539eb901a..6693eeef7 100644 --- a/sorbet/rbi/gems/sprockets@4.2.0.rbi +++ b/sorbet/rbi/gems/sprockets@4.2.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `sprockets` gem. # Please instead update this file by running `bin/tapioca gem sprockets`. + # Define some basic Sprockets error classes # # source://sprockets//lib/sprockets/version.rb#2 @@ -150,7 +151,7 @@ class Sprockets::Asset # source://sprockets//lib/sprockets/asset.rb#207 def eql?(other); end - # Pubic: ETag String of Asset. + # Public: ETag String of Asset. # # source://sprockets//lib/sprockets/asset.rb#141 def etag; end @@ -2672,7 +2673,7 @@ module Sprockets::Loader # When this happens the dependencies for the returned asset are added to the "history", and older # entries are removed if the "history" is above `limit`. # - # source://sprockets//lib/sprockets/loader.rb#323 + # source://sprockets//lib/sprockets/loader.rb#325 def fetch_asset_from_dependency_cache(unloaded, limit = T.unsafe(nil)); end # Internal: Loads an asset and saves it to cache @@ -2703,7 +2704,7 @@ module Sprockets::Loader # # Returns array of resolved dependencies # - # source://sprockets//lib/sprockets/loader.rb#287 + # source://sprockets//lib/sprockets/loader.rb#289 def resolve_dependencies(uris); end # Internal: Save a given asset to the cache @@ -2714,7 +2715,7 @@ module Sprockets::Loader # This method converts all absolute paths to "compressed" paths # which are relative if they're in the root. # - # source://sprockets//lib/sprockets/loader.rb#237 + # source://sprockets//lib/sprockets/loader.rb#239 def store_asset(asset, unloaded); end end @@ -4516,70 +4517,70 @@ module Sprockets::Server # A request for `"/assets/foo/bar.js"` will search your # environment for `"foo/bar.js"`. # - # source://sprockets//lib/sprockets/server.rb#27 + # source://sprockets//lib/sprockets/server.rb#37 def call(env); end private # Returns a 400 Forbidden response tuple # - # source://sprockets//lib/sprockets/server.rb#149 + # source://sprockets//lib/sprockets/server.rb#159 def bad_request_response(env); end - # source://sprockets//lib/sprockets/server.rb#257 + # source://sprockets//lib/sprockets/server.rb#267 def cache_headers(env, etag); end # Returns a CSS response that hides all elements on the page and # displays the exception # - # source://sprockets//lib/sprockets/server.rb#197 + # source://sprockets//lib/sprockets/server.rb#207 def css_exception_response(exception); end # Escape special characters for use inside a CSS content("...") string # - # source://sprockets//lib/sprockets/server.rb#249 + # source://sprockets//lib/sprockets/server.rb#259 def escape_css_content(content); end # @return [Boolean] # - # source://sprockets//lib/sprockets/server.rb#122 + # source://sprockets//lib/sprockets/server.rb#132 def forbidden_request?(path); end # Returns a 403 Forbidden response tuple # - # source://sprockets//lib/sprockets/server.rb#158 + # source://sprockets//lib/sprockets/server.rb#168 def forbidden_response(env); end # @return [Boolean] # - # source://sprockets//lib/sprockets/server.rb#130 + # source://sprockets//lib/sprockets/server.rb#140 def head_request?(env); end - # source://sprockets//lib/sprockets/server.rb#278 + # source://sprockets//lib/sprockets/server.rb#288 def headers(env, asset, length); end # Returns a JavaScript response that re-throws a Ruby exception # in the browser # - # source://sprockets//lib/sprockets/server.rb#189 + # source://sprockets//lib/sprockets/server.rb#199 def javascript_exception_response(exception); end - # source://sprockets//lib/sprockets/server.rb#175 + # source://sprockets//lib/sprockets/server.rb#185 def method_not_allowed_response; end # Returns a 404 Not Found response tuple # - # source://sprockets//lib/sprockets/server.rb#167 + # source://sprockets//lib/sprockets/server.rb#177 def not_found_response(env); end # Returns a 304 Not Modified response tuple # - # source://sprockets//lib/sprockets/server.rb#144 + # source://sprockets//lib/sprockets/server.rb#154 def not_modified_response(env, etag); end # Returns a 200 OK response tuple # - # source://sprockets//lib/sprockets/server.rb#135 + # source://sprockets//lib/sprockets/server.rb#145 def ok_response(asset, env); end # Gets ETag fingerprint. @@ -4587,10 +4588,10 @@ module Sprockets::Server # "foo-0aa2105d29558f3eb790d411d7d8fb66.js" # # => "0aa2105d29558f3eb790d411d7d8fb66" # - # source://sprockets//lib/sprockets/server.rb#301 + # source://sprockets//lib/sprockets/server.rb#311 def path_fingerprint(path); end - # source://sprockets//lib/sprockets/server.rb#179 + # source://sprockets//lib/sprockets/server.rb#189 def precondition_failed_response(env); end end @@ -4599,6 +4600,12 @@ end # source://sprockets//lib/sprockets/server.rb#12 Sprockets::Server::ALLOWED_REQUEST_METHODS = T.let(T.unsafe(nil), Set) +# source://sprockets//lib/sprockets/server.rb#17 +Sprockets::Server::VARY = T.let(T.unsafe(nil), String) + +# source://sprockets//lib/sprockets/server.rb#16 +Sprockets::Server::X_CASCADE = T.let(T.unsafe(nil), String) + # The purpose of this class is to generate a source map file # that can be read and understood by browsers. # diff --git a/sorbet/rbi/gems/sshkit@1.21.4.rbi b/sorbet/rbi/gems/sshkit@1.23.0.rbi similarity index 99% rename from sorbet/rbi/gems/sshkit@1.21.4.rbi rename to sorbet/rbi/gems/sshkit@1.23.0.rbi index 1575e51bd..938489213 100644 --- a/sorbet/rbi/gems/sshkit@1.21.4.rbi +++ b/sorbet/rbi/gems/sshkit@1.23.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `sshkit` gem. # Please instead update this file by running `bin/tapioca gem sshkit`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/ssrf_filter@1.1.1.rbi b/sorbet/rbi/gems/ssrf_filter@1.1.1.rbi deleted file mode 100644 index a8fc7ff73..000000000 --- a/sorbet/rbi/gems/ssrf_filter@1.1.1.rbi +++ /dev/null @@ -1,167 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `ssrf_filter` gem. -# Please instead update this file by running `bin/tapioca gem ssrf_filter`. - -# source://ssrf_filter//lib/ssrf_filter/patch/resolv.rb#5 -class SsrfFilter - class << self - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 - def delete(url, options = T.unsafe(nil), &block); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 - def get(url, options = T.unsafe(nil), &block); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 - def head(url, options = T.unsafe(nil), &block); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 - def patch(url, options = T.unsafe(nil), &block); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 - def post(url, options = T.unsafe(nil), &block); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 - def put(url, options = T.unsafe(nil), &block); end - - private - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#167 - def fetch_once(uri, ip, verb, options, &block); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#156 - def host_header(hostname, uri); end - - # @return [Boolean] - # - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#150 - def ipaddr_has_mask?(ipaddr); end - - # @raise [ArgumentError] - # - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#9 - def prefixlen_from_ipaddr(ipaddr); end - - # @return [Boolean] - # - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#140 - def unsafe_ip_address?(ip_address); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#211 - def validate_request(request); end - - # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#224 - def with_forced_hostname(hostname, ip, &_block); end - end -end - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#104 -class SsrfFilter::CRLFInjection < ::SsrfFilter::Error; end - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#75 -SsrfFilter::DEFAULT_MAX_REDIRECTS = T.let(T.unsafe(nil), Integer) - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#71 -SsrfFilter::DEFAULT_RESOLVER = T.let(T.unsafe(nil), Proc) - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#69 -SsrfFilter::DEFAULT_SCHEME_WHITELIST = T.let(T.unsafe(nil), Array) - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#89 -class SsrfFilter::Error < ::StandardError; end - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#87 -SsrfFilter::FIBER_ADDRESS_KEY = T.let(T.unsafe(nil), Symbol) - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#86 -SsrfFilter::FIBER_HOSTNAME_KEY = T.let(T.unsafe(nil), Symbol) - -# https://en.wikipedia.org/wiki/Reserved_IP_addresses -# -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#28 -SsrfFilter::IPV4_BLACKLIST = T.let(T.unsafe(nil), Array) - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#47 -SsrfFilter::IPV6_BLACKLIST = T.let(T.unsafe(nil), Array) - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#92 -class SsrfFilter::InvalidUriScheme < ::SsrfFilter::Error; end - -# source://ssrf_filter//lib/ssrf_filter/patch/resolv.rb#6 -module SsrfFilter::Patch; end - -# source://ssrf_filter//lib/ssrf_filter/patch/resolv.rb#7 -module SsrfFilter::Patch::Resolv - class << self - # source://ssrf_filter//lib/ssrf_filter/patch/resolv.rb#32 - def apply!; end - end -end - -# As described in ssl_socket.rb, we want to patch ruby's http connection code to allow us to make outbound network -# requests while ensuring that both: -# 1) we're connecting to a public / non-private ip address -# 2) https connections continue to work -# -# This used to work fine prior to this change in ruby's net/http library: -# https://github.com/ruby/net-http/pull/36 -# After this changed was introduced our patch no longer works - we need to set the hostname to the correct -# value on the SSLSocket (`s.hostname = ssl_host_address`), but that code path no longer executes due to the -# modification in the linked pull request. -# -# To work around this we introduce the patch below, which forces our ip address string to not match against the -# Resolv IPv4/IPv6 regular expressions. This is ugly and cumbersome but I didn't see any better path. -# -# source://ssrf_filter//lib/ssrf_filter/patch/resolv.rb#21 -class SsrfFilter::Patch::Resolv::PatchedRegexp < ::Regexp - # source://ssrf_filter//lib/ssrf_filter/patch/resolv.rb#22 - def ===(other); end -end - -# source://ssrf_filter//lib/ssrf_filter/patch/ssl_socket.rb#5 -module SsrfFilter::Patch::SSLSocket - class << self - # When fetching a url we'd like to have the following workflow: - # 1) resolve the hostname www.example.com, and choose a public ip address to connect to - # 2) connect to that specific ip address, to prevent things like DNS TOCTTOU bugs or other trickery - # - # Ideally this would happen by the ruby http library giving us control over DNS resolution, - # but it doesn't. Instead, when making the request we set the uri.hostname to the chosen ip address, - # and send a 'Host' header of the original hostname, i.e. connect to 'http://93.184.216.34/' and send - # a 'Host: www.example.com' header. - # - # This works for the http case, http://www.example.com. For the https case, this causes certificate - # validation failures, since the server certificate for https://www.example.com will not have a - # Subject Alternate Name for 93.184.216.34. - # - # Thus we perform the monkey-patch below, modifying SSLSocket's `post_connection_check(hostname)` - # and `hostname=(hostname)` methods: - # If our fiber local variable is set, use that for the hostname instead, otherwise behave as usual. - # The only time the variable will be set is if you are executing inside a `with_forced_hostname` block, - # which is used in ssrf_filter.rb. - # - # An alternative approach could be to pass in our own OpenSSL::X509::Store with a custom - # `verify_callback` to the ::Net::HTTP.start call, but this would require reimplementing certification - # validation, which is dangerous. This way we can piggyback on the existing validation and simply pretend - # that we connected to the desired hostname. - # - # source://ssrf_filter//lib/ssrf_filter/patch/ssl_socket.rb#30 - def apply!; end - end -end - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#95 -class SsrfFilter::PrivateIPAddress < ::SsrfFilter::Error; end - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#101 -class SsrfFilter::TooManyRedirects < ::SsrfFilter::Error; end - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#98 -class SsrfFilter::UnresolvedHostname < ::SsrfFilter::Error; end - -# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#77 -SsrfFilter::VERB_MAP = T.let(T.unsafe(nil), Hash) - -# source://ssrf_filter//lib/ssrf_filter/version.rb#4 -SsrfFilter::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/ssrf_filter@1.1.2.rbi b/sorbet/rbi/gems/ssrf_filter@1.1.2.rbi new file mode 100644 index 000000000..82a7aecf9 --- /dev/null +++ b/sorbet/rbi/gems/ssrf_filter@1.1.2.rbi @@ -0,0 +1,116 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `ssrf_filter` gem. +# Please instead update this file by running `bin/tapioca gem ssrf_filter`. + + +# source://ssrf_filter//lib/ssrf_filter/patch/ssl_socket.rb#3 +class SsrfFilter + class << self + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 + def delete(url, options = T.unsafe(nil), &block); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 + def get(url, options = T.unsafe(nil), &block); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 + def head(url, options = T.unsafe(nil), &block); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 + def patch(url, options = T.unsafe(nil), &block); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 + def post(url, options = T.unsafe(nil), &block); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#108 + def put(url, options = T.unsafe(nil), &block); end + + private + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#170 + def fetch_once(uri, ip, verb, options, &block); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#159 + def host_header(hostname, uri); end + + # @return [Boolean] + # + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#153 + def ipaddr_has_mask?(ipaddr); end + + # @raise [ArgumentError] + # + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#9 + def prefixlen_from_ipaddr(ipaddr); end + + # @return [Boolean] + # + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#143 + def unsafe_ip_address?(ip_address); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#214 + def validate_request(request); end + + # source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#227 + def with_forced_hostname(hostname, &_block); end + end +end + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#104 +class SsrfFilter::CRLFInjection < ::SsrfFilter::Error; end + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#75 +SsrfFilter::DEFAULT_ALLOW_UNFOLLOWED_REDIRECTS = T.let(T.unsafe(nil), FalseClass) + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#76 +SsrfFilter::DEFAULT_MAX_REDIRECTS = T.let(T.unsafe(nil), Integer) + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#71 +SsrfFilter::DEFAULT_RESOLVER = T.let(T.unsafe(nil), Proc) + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#69 +SsrfFilter::DEFAULT_SCHEME_WHITELIST = T.let(T.unsafe(nil), Array) + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#89 +class SsrfFilter::Error < ::StandardError; end + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#87 +SsrfFilter::FIBER_HOSTNAME_KEY = T.let(T.unsafe(nil), Symbol) + +# https://en.wikipedia.org/wiki/Reserved_IP_addresses +# +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#28 +SsrfFilter::IPV4_BLACKLIST = T.let(T.unsafe(nil), Array) + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#47 +SsrfFilter::IPV6_BLACKLIST = T.let(T.unsafe(nil), Array) + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#92 +class SsrfFilter::InvalidUriScheme < ::SsrfFilter::Error; end + +# source://ssrf_filter//lib/ssrf_filter/patch/ssl_socket.rb#4 +module SsrfFilter::Patch; end + +# source://ssrf_filter//lib/ssrf_filter/patch/ssl_socket.rb#5 +module SsrfFilter::Patch::SSLSocket + class << self + # source://ssrf_filter//lib/ssrf_filter/patch/ssl_socket.rb#6 + def apply!; end + end +end + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#95 +class SsrfFilter::PrivateIPAddress < ::SsrfFilter::Error; end + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#101 +class SsrfFilter::TooManyRedirects < ::SsrfFilter::Error; end + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#98 +class SsrfFilter::UnresolvedHostname < ::SsrfFilter::Error; end + +# source://ssrf_filter//lib/ssrf_filter/ssrf_filter.rb#78 +SsrfFilter::VERB_MAP = T.let(T.unsafe(nil), Hash) + +# source://ssrf_filter//lib/ssrf_filter/version.rb#4 +SsrfFilter::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/steam-condenser@1.3.11-2d1a1acc2e76631e91cb25a263b3d00373371695.rbi b/sorbet/rbi/gems/steam-condenser@1.3.11-2d1a1acc2e76631e91cb25a263b3d00373371695.rbi index b9b462665..351802946 100644 --- a/sorbet/rbi/gems/steam-condenser@1.3.11-2d1a1acc2e76631e91cb25a263b3d00373371695.rbi +++ b/sorbet/rbi/gems/steam-condenser@1.3.11-2d1a1acc2e76631e91cb25a263b3d00373371695.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `steam-condenser` gem. # Please instead update this file by running `bin/tapioca gem steam-condenser`. + # This module is used as a wrapper around Steam Condenser's classes # # It does not provide any own functionality, but this file is used as an entry @@ -4322,5 +4323,3 @@ class StringIO def alloc(size); end end end - -StringIO::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/stimulus-rails@1.2.1.rbi b/sorbet/rbi/gems/stimulus-rails@1.3.3.rbi similarity index 82% rename from sorbet/rbi/gems/stimulus-rails@1.2.1.rbi rename to sorbet/rbi/gems/stimulus-rails@1.3.3.rbi index c31669fc1..d95ed5383 100644 --- a/sorbet/rbi/gems/stimulus-rails@1.2.1.rbi +++ b/sorbet/rbi/gems/stimulus-rails@1.3.3.rbi @@ -4,11 +4,17 @@ # This is an autogenerated file for types exported from the `stimulus-rails` gem. # Please instead update this file by running `bin/tapioca gem stimulus-rails`. + # source://stimulus-rails//lib/stimulus-rails.rb#1 module Stimulus; end # source://stimulus-rails//lib/stimulus/engine.rb#2 -class Stimulus::Engine < ::Rails::Engine; end +class Stimulus::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end # If you don't want to precompile Stimulus's assets (e.g., you're using jsbundling), # you can do this in an initializer: diff --git a/sorbet/rbi/gems/stringio@3.1.1.rbi b/sorbet/rbi/gems/stringio@3.1.1.rbi new file mode 100644 index 000000000..0b17e9140 --- /dev/null +++ b/sorbet/rbi/gems/stringio@3.1.1.rbi @@ -0,0 +1,9 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `stringio` gem. +# Please instead update this file by running `bin/tapioca gem stringio`. + + +# THIS IS AN EMPTY RBI FILE. +# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/stripe@12.5.0.rbi b/sorbet/rbi/gems/stripe@12.5.0.rbi new file mode 100644 index 000000000..157aa7164 --- /dev/null +++ b/sorbet/rbi/gems/stripe@12.5.0.rbi @@ -0,0 +1,9025 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `stripe` gem. +# Please instead update this file by running `bin/tapioca gem stripe`. + + +# File generated from our OpenAPI spec +# +# source://stripe//lib/stripe/api_version.rb#4 +module Stripe + class << self + # source://forwardable/1.3.3/forwardable.rb#231 + def api_base(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def api_base=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def api_key(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def api_key=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def api_version(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def api_version=(*args, **_arg1, &block); end + + # Gets the application for a plugin that's identified some. See + # #set_app_info. + # + # source://stripe//lib/stripe.rb#99 + def app_info; end + + # source://stripe//lib/stripe.rb#103 + def app_info=(info); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def ca_bundle_path(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def ca_bundle_path=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def ca_store(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def client_id(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def client_id=(*args, **_arg1, &block); end + + # Returns the value of attribute config. + # + # source://stripe//lib/stripe.rb#70 + def config; end + + # source://forwardable/1.3.3/forwardable.rb#231 + def connect_base(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def connect_base=(*args, **_arg1, &block); end + + # source://stripe//lib/stripe.rb#141 + def deserialize(data); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def enable_telemetry=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def enable_telemetry?(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def initial_network_retry_delay(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def log_level(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def log_level=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def logger(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def logger=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def max_network_retries(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def max_network_retries=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def max_network_retry_delay(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def open_timeout(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def open_timeout=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def proxy(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def proxy=(*args, **_arg1, &block); end + + # Sends a request to Stripe REST API + # + # source://stripe//lib/stripe.rb#136 + def raw_request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def read_timeout(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def read_timeout=(*args, **_arg1, &block); end + + # Sets some basic information about the running application that's sent along + # with API requests. Useful for plugin authors to identify their plugin when + # communicating with Stripe. + # + # Takes a name and optional partner program ID, plugin URL, and version. + # + # source://stripe//lib/stripe.rb#112 + def set_app_info(name, partner_id: T.unsafe(nil), url: T.unsafe(nil), version: T.unsafe(nil)); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def stripe_account(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def stripe_account=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def uploads_base(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def uploads_base=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def verify_ssl_certs(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def verify_ssl_certs=(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def write_timeout(*args, **_arg1, &block); end + + # source://forwardable/1.3.3/forwardable.rb#231 + def write_timeout=(*args, **_arg1, &block); end + end +end + +# APIConnectionError is raised in the event that the SDK can't connect to +# Stripe's servers. That can be for a variety of different reasons from a +# downed network to a bad TLS certificate. +# +# source://stripe//lib/stripe/errors.rb#55 +class Stripe::APIConnectionError < ::Stripe::StripeError; end + +# APIError is a generic error that may be raised in cases where none of the +# other named errors cover the problem. It could also be raised in the case +# that a new error has been introduced in the API, but this version of the +# Ruby SDK doesn't know how to handle it. +# +# source://stripe//lib/stripe/errors.rb#62 +class Stripe::APIError < ::Stripe::StripeError; end + +# source://stripe//lib/stripe/api_operations/create.rb#4 +module Stripe::APIOperations; end + +# source://stripe//lib/stripe/api_operations/create.rb#5 +module Stripe::APIOperations::Create + # source://stripe//lib/stripe/api_operations/create.rb#6 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end +end + +# source://stripe//lib/stripe/api_operations/delete.rb#5 +module Stripe::APIOperations::Delete + mixes_in_class_methods ::Stripe::APIOperations::Delete::ClassMethods + + # source://stripe//lib/stripe/api_operations/delete.rb#30 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # @private + # + # source://stripe//lib/stripe/api_operations/delete.rb#39 + def included(base); end + end +end + +# source://stripe//lib/stripe/api_operations/delete.rb#6 +module Stripe::APIOperations::Delete::ClassMethods + # Deletes an API resource + # + # Deletes the identified resource with the passed in parameters. + # + # ==== Attributes + # + # * +id+ - ID of the resource to delete. + # * +params+ - A hash of parameters to pass to the API + # * +opts+ - A Hash of additional options (separate from the params / + # object values) to be added to the request. E.g. to allow for an + # idempotency_key to be passed in the request headers, or for the + # api_key to be overwritten. See + # {APIOperations::Request.execute_resource_request}. + # + # source://stripe//lib/stripe/api_operations/delete.rb#20 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end +end + +# source://stripe//lib/stripe/api_operations/list.rb#5 +module Stripe::APIOperations::List + # source://stripe//lib/stripe/api_operations/list.rb#6 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end +end + +# Adds methods to help manipulate a subresource from its parent resource so +# that it's possible to do so from a static context (i.e. without a +# pre-existing collection of subresources on the parent). +# +# For example, a transfer gains the static methods for reversals so that the +# methods `.create_reversal`, `.retrieve_reversal`, `.update_reversal`, +# etc. all become available. +# +# source://stripe//lib/stripe/api_operations/nested_resource.rb#12 +module Stripe::APIOperations::NestedResource + # @raise [ArgumentError] + # + # source://stripe//lib/stripe/api_operations/nested_resource.rb#13 + def nested_resource_class_methods(resource, path: T.unsafe(nil), operations: T.unsafe(nil), resource_plural: T.unsafe(nil)); end + + private + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#39 + def define_operation(resource, operation, resource_url_method, resource_plural); end +end + +# source://stripe//lib/stripe/api_operations/request.rb#5 +module Stripe::APIOperations::Request + extend ::Gem::Deprecate + + mixes_in_class_methods ::Stripe::APIOperations::Request::ClassMethods + + # See notes on `alias` above. + def request(*args, **_arg1, &block); end + + protected + + # source://stripe//lib/stripe/api_operations/request.rb#117 + def _deprecated_request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), usage = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/request.rb#117 + def execute_resource_request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), usage = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/request.rb#123 + def execute_resource_request_stream(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), &read_body_chunk_block); end + + private + + # source://stripe//lib/stripe/api_operations/request.rb#132 + def request_stripe_object(method:, path:, params:, opts: T.unsafe(nil), usage: T.unsafe(nil)); end + + class << self + # @private + # + # source://stripe//lib/stripe/api_operations/request.rb#113 + def included(base); end + end +end + +# source://stripe//lib/stripe/api_operations/request.rb#6 +module Stripe::APIOperations::Request::ClassMethods + extend ::Gem::Deprecate + + # source://stripe//lib/stripe/api_operations/request.rb#7 + def _deprecated_request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), usage = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/request.rb#7 + def execute_resource_request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), usage = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/request.rb#14 + def execute_resource_request_stream(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), usage = T.unsafe(nil), &read_body_chunk_block); end + + # TODO: (major) + # This method used to be called `request`, but it's such a short name + # that it eventually conflicted with the name of a field on an API + # resource (specifically, `Event#request`), so it was renamed to + # something more unique. + # + # The former name had been around for just about forever though, and + # although all internal uses have been renamed, I've left this alias in + # place for backwards compatibility. Consider removing it on the next + # major. + def request(*args, **_arg1, &block); end + + private + + # @raise [ArgumentError] + # + # source://stripe//lib/stripe/api_operations/request.rb#98 + def error_on_invalid_params(params); end + + # source://stripe//lib/stripe/api_operations/request.rb#84 + def error_on_non_string_user_opts(opts); end + + # source://stripe//lib/stripe/api_operations/request.rb#33 + def execute_resource_request_internal(client_request_method_sym, method, url, params, opts, usage, &read_body_chunk_block); end + + # source://stripe//lib/stripe/api_operations/request.rb#28 + def request_stripe_object(method:, path:, params:, opts: T.unsafe(nil), usage: T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/request.rb#106 + def warn_on_opts_in_params(params); end +end + +# source://stripe//lib/stripe/api_operations/save.rb#5 +module Stripe::APIOperations::Save + extend ::Gem::Deprecate + + mixes_in_class_methods ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/api_operations/save.rb#54 + def _deprecated_save(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # The `save` method is DEPRECATED and will be removed in a future major + # version of the library. Use the `update` method on the resource instead. + # + # Creates or updates an API resource. + # + # If the resource doesn't yet have an assigned ID and the resource is one + # that can be created, then the method attempts to create the resource. + # The resource is updated otherwise. + # + # ==== Attributes + # + # * +params+ - Overrides any parameters in the resource's serialized data + # and includes them in the create or update. If +:req_url:+ is included + # in the list, it overrides the update URL used for the create or + # update. + # * +opts+ - A Hash of additional options (separate from the params / + # object values) to be added to the request. E.g. to allow for an + # idempotency_key to be passed in the request headers, or for the + # api_key to be overwritten. See + # {APIOperations::Request.execute_resource_request}. + def save(*args, **_arg1, &block); end + + private + + # source://stripe//lib/stripe/api_operations/save.rb#90 + def save_url; end + + class << self + # @private + # + # source://stripe//lib/stripe/api_operations/save.rb#77 + def included(base); end + end +end + +# source://stripe//lib/stripe/api_operations/save.rb#6 +module Stripe::APIOperations::Save::ClassMethods + # Updates an API resource + # + # Updates the identified resource with the passed in parameters. + # + # ==== Attributes + # + # * +id+ - ID of the resource to update. + # * +params+ - A hash of parameters to pass to the API + # * +opts+ - A Hash of additional options (separate from the params / + # object values) to be added to the request. E.g. to allow for an + # idempotency_key to be passed in the request headers, or for the + # api_key to be overwritten. See + # {APIOperations::Request.execute_resource_request}. + # + # source://stripe//lib/stripe/api_operations/save.rb#20 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end +end + +# The _search method via API Operations is deprecated. +# Please use the search method from within the resource instead. +# +# source://stripe//lib/stripe/api_operations/search.rb#7 +module Stripe::APIOperations::Search + extend ::Gem::Deprecate + + # source://stripe//lib/stripe/api_operations/search.rb#8 + def _deprecated__search(search_url, filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + def _search(*args, **_arg1, &block); end +end + +# source://stripe//lib/stripe/api_operations/singleton_save.rb#5 +module Stripe::APIOperations::SingletonSave + extend ::Gem::Deprecate + + mixes_in_class_methods ::Stripe::APIOperations::SingletonSave::ClassMethods + + # source://stripe//lib/stripe/api_operations/singleton_save.rb#53 + def _deprecated_save(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # The `save` method is DEPRECATED and will be removed in a future major + # version of the library. Use the `update` method on the resource instead. + # + # Updates a singleton API resource. + # + # If the resource doesn't yet have an assigned ID and the resource is one + # that can be created, then the method attempts to create the resource. + # The resource is updated otherwise. + # + # ==== Attributes + # + # * +params+ - Overrides any parameters in the resource's serialized data + # and includes them in the create or update. If +:req_url:+ is included + # in the list, it overrides the update URL used for the create or + # update. + # * +opts+ - A Hash of additional options (separate from the params / + # object values) to be added to the request. E.g. to allow for an + # idempotency_key to be passed in the request headers, or for the + # api_key to be overwritten. See + # {APIOperations::Request.execute_resource_request}. + def save(*args, **_arg1, &block); end + + class << self + # @private + # + # source://stripe//lib/stripe/api_operations/singleton_save.rb#72 + def included(base); end + end +end + +# source://stripe//lib/stripe/api_operations/singleton_save.rb#6 +module Stripe::APIOperations::SingletonSave::ClassMethods + # Updates a singleton API resource + # + # Updates the identified resource with the passed in parameters. + # + # ==== Attributes + # + # * +params+ - A hash of parameters to pass to the API + # * +opts+ - A Hash of additional options (separate from the params / + # object values) to be added to the request. E.g. to allow for an + # idempotency_key to be passed in the request headers, or for the + # api_key to be overwritten. See + # {APIOperations::Request.execute_resource_request}. + # + # source://stripe//lib/stripe/api_operations/singleton_save.rb#19 + def update(params = T.unsafe(nil), opts = T.unsafe(nil)); end +end + +# source://stripe//lib/stripe/api_resource.rb#4 +class Stripe::APIResource < ::Stripe::StripeObject + include ::Stripe::APIOperations::Request + extend ::Stripe::APIOperations::Request::ClassMethods + + # source://stripe//lib/stripe/api_resource.rb#89 + def refresh; end + + # source://stripe//lib/stripe/api_resource.rb#102 + def request_stripe_object(method:, path:, params:, opts: T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_resource.rb#78 + def resource_url; end + + # A flag that can be set a behavior that will cause this resource to be + # encoded and sent up along with an update of its parent resource. This is + # usually not desirable because resources are updated individually on their + # own endpoints, but there are certain cases, replacing a customer's source + # for example, where this is allowed. + # + # source://stripe//lib/stripe/api_resource.rb#12 + def save_with_parent; end + + # A flag that can be set a behavior that will cause this resource to be + # encoded and sent up along with an update of its parent resource. This is + # usually not desirable because resources are updated individually on their + # own endpoints, but there are certain cases, replacing a customer's source + # for example, where this is allowed. + # + # source://stripe//lib/stripe/api_resource.rb#12 + def save_with_parent=(_arg0); end + + protected + + # source://stripe//lib/stripe/api_resource.rb#113 + def request_stream(method:, path:, params:, opts: T.unsafe(nil), &read_body_chunk_block); end + + class << self + # source://stripe//lib/stripe/api_resource.rb#23 + def class_name; end + + # Adds a custom method to a resource class. This is used to add support for + # non-CRUDL API requests, e.g. capturing charges. custom_method takes the + # following parameters: + # - name: the name of the custom method to create (as a symbol) + # - http_verb: the HTTP verb for the API request (:get, :post, or :delete) + # - http_path: the path to append to the resource's URL. If not provided, + # the name is used as the path + # + # For example, this call: + # custom_method :capture, http_verb: post + # adds a `capture` class method to the resource class that, when called, + # will send a POST request to `/v1//capture`. + # + # source://stripe//lib/stripe/api_resource.rb#74 + def custom_method(name, http_verb:, http_path: T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_resource.rb#19 + def object_name; end + + # source://stripe//lib/stripe/api_resource.rb#27 + def resource_url; end + + # source://stripe//lib/stripe/api_resource.rb#95 + def retrieve(id, opts = T.unsafe(nil)); end + + # A metaprogramming call that specifies that a field of a resource can be + # its own type of API resource (say a nested card under an account for + # example), and if that resource is set, it should be transmitted to the + # API on a create or update. Doing so is not the default behavior because + # API resources should normally be persisted on their own RESTful + # endpoints. + # + # source://stripe//lib/stripe/api_resource.rb#44 + def save_nested_resource(name); end + end +end + +# TODO: (major) Remove OBJECT_NAME and stop using const_get here +# This is a workaround to avoid breaking users who have defined their own +# APIResource subclasses with a custom OBJECT_NAME. We should never fallback +# on this case otherwise. +# +# source://stripe//lib/stripe/api_resource.rb#18 +Stripe::APIResource::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# The base class for nested TestHelpers classes in resource objects. +# The APIResourceTestHelpers handles URL generation and custom method +# support for test-helper methods. +# +# class MyAPIResource < APIResource +# class TestHelpers < APIResourceTestHelpers +# +# source://stripe//lib/stripe/api_resource_test_helpers.rb#10 +class Stripe::APIResourceTestHelpers + include ::Stripe::APIOperations::Request + extend ::Stripe::APIOperations::Request::ClassMethods + + # @return [APIResourceTestHelpers] a new instance of APIResourceTestHelpers + # + # source://stripe//lib/stripe/api_resource_test_helpers.rb#13 + def initialize(resource); end + + # source://stripe//lib/stripe/api_resource_test_helpers.rb#42 + def resource_url; end + + class << self + # Adds a custom method to a test helper. This is used to add support for + # non-CRUDL API requests, e.g. capturing charges. custom_method takes the + # following parameters: + # - name: the name of the custom method to create (as a symbol) + # - http_verb: the HTTP verb for the API request (:get, :post, or :delete) + # - http_path: the path to append to the resource's URL. If not provided, + # the name is used as the path + # + # For example, this call: + # custom_method :capture, http_verb: post + # adds a `capture` class method to the resource class that, when called, + # will send a POST request to `/v1//capture`. + # + # source://stripe//lib/stripe/api_resource_test_helpers.rb#33 + def custom_method(name, http_verb:, http_path: T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_resource_test_helpers.rb#17 + def resource_class; end + + # source://stripe//lib/stripe/api_resource_test_helpers.rb#37 + def resource_url; end + end +end + +# This is an object representing a Stripe account. You can retrieve it to see +# properties on the account like its current requirements or if the account is +# enabled to make live charges or receive payouts. +# +# For accounts where [controller.requirement_collection](https://stripe.com/api/accounts/object#account_object-controller-requirement_collection) +# is `application`, which includes Custom accounts, the properties below are always +# returned. +# +# For accounts where [controller.requirement_collection](https://stripe.com/api/accounts/object#account_object-controller-requirement_collection) +# is `stripe`, which includes Standard and Express accounts, some properties are only returned +# until you create an [Account Link](https://stripe.com/api/account_links) or [Account Session](https://stripe.com/api/account_sessions) +# to start Connect Onboarding. Learn about the [differences between accounts](https://stripe.com/connect/accounts). +# +# source://stripe//lib/stripe/resources/account.rb#17 +class Stripe::Account < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/account.rb#234 + def deauthorize(client_id = T.unsafe(nil), opts = T.unsafe(nil)); end + + # With [Connect](https://stripe.com/connect), you can delete accounts you manage. + # + # Test-mode accounts can be deleted at any time. + # + # Live-mode accounts where Stripe is responsible for negative account balances cannot be deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be deleted when all [balances](https://stripe.com/api/balance/balanace_object) are zero. + # + # If you want to delete your own account, use the [account information tab in your account settings](https://dashboard.stripe.com/settings/account) instead. + # + # source://stripe//lib/stripe/resources/account.rb#70 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_resource.rb#45 + def external_account=(value); end + + # source://stripe//lib/stripe/resources/account.rb#223 + def legal_entity; end + + # @raise [NoMethodError] + # + # source://stripe//lib/stripe/resources/account.rb#227 + def legal_entity=(_legal_entity); end + + # Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. + # + # source://stripe//lib/stripe/resources/account.rb#85 + def persons(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # With [Connect](https://stripe.com/connect), you can reject accounts that you have flagged as suspicious. + # + # Only accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time. Live-mode accounts can only be rejected after all balances are zero. + # + # source://stripe//lib/stripe/resources/account.rb#107 + def reject(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/account.rb#152 + def resource_url; end + + # Somewhat unfortunately, we attempt to do a special encoding trick when + # serializing `additional_owners` under an account: when updating a value, + # we actually send the update parameters up as an integer-indexed hash + # rather than an array. So instead of this: + # + # field[]=item1&field[]=item2&field[]=item3 + # + # We send this: + # + # field[0]=item1&field[1]=item2&field[2]=item3 + # + # There are two major problems with this technique: + # + # * Entities are addressed by array index, which is not stable and can + # easily result in unexpected results between two different requests. + # + # * A replacement of the array's contents is ambiguous with setting a + # subset of the array. Because of this, the only way to shorten an + # array is to unset it completely by making sure it goes into the + # server as an empty string, then setting its contents again. + # + # We're trying to get this overturned on the server side, but for now, + # patch in a special allowance. + # + # source://stripe//lib/stripe/resources/account.rb#203 + def serialize_params(options = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/account.rb#207 + def serialize_params_account(_obj, update_hash, options = T.unsafe(nil)); end + + private + + # source://stripe//lib/stripe/resources/account.rb#243 + def serialize_additional_owners(legal_entity, additional_owners); end + + class << self + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def capabilitys_url(id, nested_id = T.unsafe(nil)); end + + # With [Connect](https://stripe.com/docs/connect), you can create Stripe accounts for your users. + # To do this, you'll first need to [register your platform](https://dashboard.stripe.com/account/applications/settings). + # + # If you've already collected information for your connected accounts, you [can prefill that information](https://stripe.com/docs/connect/best-practices#onboarding) when + # creating the account. Connect Onboarding won't ask for the prefilled information during account onboarding. + # You can prefill any information on the account. + # + # source://stripe//lib/stripe/resources/account.rb#43 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_external_account(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_login_link(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_person(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # With [Connect](https://stripe.com/connect), you can delete accounts you manage. + # + # Test-mode accounts can be deleted at any time. + # + # Live-mode accounts where Stripe is responsible for negative account balances cannot be deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be deleted when all [balances](https://stripe.com/api/balance/balanace_object) are zero. + # + # If you want to delete your own account, use the [account information tab in your account settings](https://dashboard.stripe.com/settings/account) instead. + # + # source://stripe//lib/stripe/resources/account.rb#54 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#96 + def delete_external_account(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#96 + def delete_person(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def external_accounts_url(id, nested_id = T.unsafe(nil)); end + + # Returns a list of accounts connected to your platform via [Connect](https://stripe.com/docs/connect). If you're not a platform, the list is empty. + # + # source://stripe//lib/stripe/resources/account.rb#80 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_capabilities(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_external_accounts(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_persons(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def login_links_url(id, nested_id = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/account.rb#25 + def object_name; end + + # Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. + # + # source://stripe//lib/stripe/resources/account.rb#95 + def persons(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def persons_url(id, nested_id = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/account.rb#219 + def protected_fields; end + + # With [Connect](https://stripe.com/connect), you can reject accounts that you have flagged as suspicious. + # + # Only accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time. Live-mode accounts can only be rejected after all balances are zero. + # + # source://stripe//lib/stripe/resources/account.rb#119 + def reject(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/account.rb#161 + def retrieve(id = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_capability(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_external_account(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_person(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # Updates a [connected account](https://stripe.com/connect/accounts) by setting the values of the parameters passed. Any parameters not provided are + # left unchanged. + # + # For accounts where [controller.requirement_collection](https://stripe.com/api/accounts/object#account_object-controller-requirement_collection) + # is application, which includes Custom accounts, you can update any information on the account. + # + # For accounts where [controller.requirement_collection](https://stripe.com/api/accounts/object#account_object-controller-requirement_collection) + # is stripe, which includes Standard and Express accounts, you can update all information until you create + # an [Account Link or Account Session](https://stripe.com/api/account_links) to start Connect onboarding, + # after which some properties can no longer be updated. + # + # To update your own account, use the [Dashboard](https://dashboard.stripe.com/settings/account). Refer to our + # [Connect](https://stripe.com/docs/connect/updating-accounts) documentation to learn more about updating accounts. + # + # source://stripe//lib/stripe/resources/account.rb#141 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#86 + def update_capability(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#86 + def update_external_account(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#86 + def update_person(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/account.rb#24 +Stripe::Account::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Account Links are the means by which a Connect platform grants a connected account permission to access +# Stripe-hosted applications, such as Connect Onboarding. +# +# Related guide: [Connect Onboarding](https://stripe.com/docs/connect/custom/hosted-onboarding) +# +# source://stripe//lib/stripe/resources/account_link.rb#9 +class Stripe::AccountLink < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow. + # + # source://stripe//lib/stripe/resources/account_link.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/account_link.rb#13 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/account_link.rb#12 +Stripe::AccountLink::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# An AccountSession allows a Connect platform to grant access to a connected account in Connect embedded components. +# +# We recommend that you create an AccountSession each time you need to display an embedded component +# to your user. Do not save AccountSessions to your database as they expire relatively +# quickly, and cannot be used more than once. +# +# Related guide: [Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components) +# +# source://stripe//lib/stripe/resources/account_session.rb#12 +class Stripe::AccountSession < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access. + # + # source://stripe//lib/stripe/resources/account_session.rb#21 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/account_session.rb#16 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/account_session.rb#15 +Stripe::AccountSession::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/api_version.rb#5 +module Stripe::ApiVersion; end + +# source://stripe//lib/stripe/api_version.rb#6 +Stripe::ApiVersion::CURRENT = T.let(T.unsafe(nil), String) + +# Domains registered for Apple Pay on the Web +# +# source://stripe//lib/stripe/resources/apple_pay_domain.rb#6 +class Stripe::ApplePayDomain < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + + # Delete an apple pay domain. + # + # source://stripe//lib/stripe/resources/apple_pay_domain.rb#37 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Create an apple pay domain. + # + # source://stripe//lib/stripe/resources/apple_pay_domain.rb#17 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Delete an apple pay domain. + # + # source://stripe//lib/stripe/resources/apple_pay_domain.rb#27 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # List apple pay domains. + # + # source://stripe//lib/stripe/resources/apple_pay_domain.rb#47 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/apple_pay_domain.rb#12 + def object_name; end + + # source://stripe//lib/stripe/resources/apple_pay_domain.rb#56 + def resource_url; end + end +end + +# source://stripe//lib/stripe/resources/apple_pay_domain.rb#11 +Stripe::ApplePayDomain::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/application_fee.rb#5 +class Stripe::ApplicationFee < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + + class << self + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_refund(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of application fees you've previously collected. The application fees are returned in sorted order, with the most recent fees appearing first. + # + # source://stripe//lib/stripe/resources/application_fee.rb#17 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_refunds(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/application_fee.rb#10 + def object_name; end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def refunds_url(id, nested_id = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_refund(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#86 + def update_refund(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/application_fee.rb#9 +Stripe::ApplicationFee::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# `Application Fee Refund` objects allow you to refund an application fee that +# has previously been created but not yet refunded. Funds will be refunded to +# the Stripe account from which the fee was originally collected. +# +# Related guide: [Refunding application fees](https://stripe.com/docs/connect/destination-charges#refunding-app-fee) +# +# source://stripe//lib/stripe/resources/application_fee_refund.rb#10 +class Stripe::ApplicationFeeRefund < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/application_fee_refund.rb#18 + def resource_url; end + + class << self + # source://stripe//lib/stripe/resources/application_fee_refund.rb#14 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/application_fee_refund.rb#31 + def retrieve(_id, _api_key = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/application_fee_refund.rb#23 + def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/application_fee_refund.rb#13 +Stripe::ApplicationFeeRefund::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/apps/secret.rb#5 +module Stripe::Apps; end + +# Secret Store is an API that allows Stripe Apps developers to securely persist secrets for use by UI Extensions and app backends. +# +# The primary resource in Secret Store is a `secret`. Other apps can't view secrets created by an app. Additionally, secrets are scoped to provide further permission control. +# +# All Dashboard users and the app backend share `account` scoped secrets. Use the `account` scope for secrets that don't change per-user, like a third-party API key. +# +# A `user` scoped secret is accessible by the app backend and one specific Dashboard user. Use the `user` scope for per-user secrets like per-user OAuth tokens, where different users might have different permissions. +# +# Related guide: [Store data between page reloads](https://stripe.com/docs/stripe-apps/store-auth-data-custom-objects) +# +# source://stripe//lib/stripe/resources/apps/secret.rb#15 +class Stripe::Apps::Secret < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + class << self + # Create or replace a secret in the secret store. + # + # source://stripe//lib/stripe/resources/apps/secret.rb#25 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a secret from the secret store by name and scope. + # + # source://stripe//lib/stripe/resources/apps/secret.rb#30 + def delete_where(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Finds a secret in the secret store by name and scope. + # + # source://stripe//lib/stripe/resources/apps/secret.rb#40 + def find(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # List all secrets stored on the given scope. + # + # source://stripe//lib/stripe/resources/apps/secret.rb#50 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/apps/secret.rb#20 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/apps/secret.rb#19 +Stripe::Apps::Secret::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# AuthenticationError is raised when invalid credentials are used to connect +# to Stripe's servers. +# +# source://stripe//lib/stripe/errors.rb#49 +class Stripe::AuthenticationError < ::Stripe::StripeError; end + +# This is an object representing your Stripe balance. You can retrieve it to see +# the balance currently on your Stripe account. +# +# You can also retrieve the balance history, which contains a list of +# [transactions](https://stripe.com/docs/reporting/balance-transaction-types) that contributed to the balance +# (charges, payouts, and so forth). +# +# The available and pending amounts for each currency are broken down further by +# payment source types. +# +# Related guide: [Understanding Connect account balances](https://stripe.com/docs/connect/account-balances) +# +# source://stripe//lib/stripe/resources/balance.rb#16 +class Stripe::Balance < ::Stripe::SingletonAPIResource + class << self + # source://stripe//lib/stripe/resources/balance.rb#18 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/balance.rb#17 +Stripe::Balance::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Balance transactions represent funds moving through your Stripe account. +# Stripe creates them for every type of transaction that enters or leaves your Stripe account balance. +# +# Related guide: [Balance transaction types](https://stripe.com/docs/reports/balance-transaction-types) +# +# source://stripe//lib/stripe/resources/balance_transaction.rb#9 +class Stripe::BalanceTransaction < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first. + # + # Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history. + # + # source://stripe//lib/stripe/resources/balance_transaction.rb#20 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/balance_transaction.rb#13 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/balance_transaction.rb#12 +Stripe::BalanceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# These bank accounts are payment methods on `Customer` objects. +# +# On the other hand [External Accounts](https://stripe.com/api#external_accounts) are transfer +# destinations on `Account` objects for connected accounts. +# They can be bank accounts or debit cards as well, and are documented in the links above. +# +# Related guide: [Bank debits and transfers](https://stripe.com/payments/bank-debits-transfers) +# +# source://stripe//lib/stripe/resources/bank_account.rb#12 +class Stripe::BankAccount < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/bank_account.rb#75 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/bank_account.rb#40 + def resource_url; end + + # source://stripe//lib/stripe/resources/bank_account.rb#22 + def verify(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/bank_account.rb#66 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/bank_account.rb#84 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/bank_account.rb#18 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/bank_account.rb#57 + def retrieve(_id, _opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/bank_account.rb#48 + def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/bank_account.rb#31 + def verify(customer, id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/bank_account.rb#17 +Stripe::BankAccount::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/billing/alert.rb#5 +module Stripe::Billing; end + +# A billing alert is a resource that notifies you when a certain usage threshold on a meter is crossed. For example, you might create a billing alert to notify you when a certain user made 100 API requests. +# +# source://stripe//lib/stripe/resources/billing/alert.rb#7 +class Stripe::Billing::Alert < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + # Reactivates this alert, allowing it to trigger again. + # + # source://stripe//lib/stripe/resources/billing/alert.rb#17 + def activate(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Archives this alert, removing it from the list view and APIs. This is non-reversible. + # + # source://stripe//lib/stripe/resources/billing/alert.rb#37 + def archive(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deactivates this alert, preventing it from triggering. + # + # source://stripe//lib/stripe/resources/billing/alert.rb#62 + def deactivate(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Reactivates this alert, allowing it to trigger again. + # + # source://stripe//lib/stripe/resources/billing/alert.rb#27 + def activate(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Archives this alert, removing it from the list view and APIs. This is non-reversible. + # + # source://stripe//lib/stripe/resources/billing/alert.rb#47 + def archive(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a billing alert + # + # source://stripe//lib/stripe/resources/billing/alert.rb#57 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deactivates this alert, preventing it from triggering. + # + # source://stripe//lib/stripe/resources/billing/alert.rb#72 + def deactivate(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Lists billing active and inactive alerts + # + # source://stripe//lib/stripe/resources/billing/alert.rb#82 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/billing/alert.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/billing/alert.rb#11 +Stripe::Billing::Alert::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A billing meter is a resource that allows you to track usage of a particular event. For example, you might create a billing meter to track the number of API calls made by a particular user. You can then attach the billing meter to a price and attach the price to a subscription to charge the user for the number of API calls they make. +# +# source://stripe//lib/stripe/resources/billing/meter.rb#7 +class Stripe::Billing::Meter < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Save::ClassMethods + + # Deactivates a billing meter + # + # source://stripe//lib/stripe/resources/billing/meter.rb#28 + def deactivate(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Reactivates a billing meter + # + # source://stripe//lib/stripe/resources/billing/meter.rb#53 + def reactivate(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a billing meter + # + # source://stripe//lib/stripe/resources/billing/meter.rb#23 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deactivates a billing meter + # + # source://stripe//lib/stripe/resources/billing/meter.rb#38 + def deactivate(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def event_summarys_url(id, nested_id = T.unsafe(nil)); end + + # Retrieve a list of billing meters. + # + # source://stripe//lib/stripe/resources/billing/meter.rb#48 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_event_summaries(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/billing/meter.rb#14 + def object_name; end + + # Reactivates a billing meter + # + # source://stripe//lib/stripe/resources/billing/meter.rb#63 + def reactivate(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates a billing meter + # + # source://stripe//lib/stripe/resources/billing/meter.rb#73 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/billing/meter.rb#13 +Stripe::Billing::Meter::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A billing meter event represents a customer's usage of a product. Meter events are used to bill a customer based on their usage. +# Meter events are associated with billing meters, which define the shape of the event's payload and how those events are aggregated for billing. +# +# source://stripe//lib/stripe/resources/billing/meter_event.rb#8 +class Stripe::Billing::MeterEvent < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # Creates a billing meter event + # + # source://stripe//lib/stripe/resources/billing/meter_event.rb#17 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/billing/meter_event.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/billing/meter_event.rb#11 +Stripe::Billing::MeterEvent::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A billing meter event adjustment is a resource that allows you to cancel a meter event. For example, you might create a billing meter event adjustment to cancel a meter event that was created in error or attached to the wrong customer. +# +# source://stripe//lib/stripe/resources/billing/meter_event_adjustment.rb#7 +class Stripe::Billing::MeterEventAdjustment < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # Creates a billing meter event adjustment + # + # source://stripe//lib/stripe/resources/billing/meter_event_adjustment.rb#16 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/billing/meter_event_adjustment.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/billing/meter_event_adjustment.rb#10 +Stripe::Billing::MeterEventAdjustment::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A billing meter event summary represents an aggregated view of a customer's billing meter events within a specified timeframe. It indicates how much +# usage was accrued by a customer for that period. +# +# source://stripe//lib/stripe/resources/billing/meter_event_summary.rb#8 +class Stripe::Billing::MeterEventSummary < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/billing/meter_event_summary.rb#10 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/billing/meter_event_summary.rb#9 +Stripe::Billing::MeterEventSummary::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/billing_portal/configuration.rb#5 +module Stripe::BillingPortal; end + +# A portal configuration describes the functionality and behavior of a portal session. +# +# source://stripe//lib/stripe/resources/billing_portal/configuration.rb#7 +class Stripe::BillingPortal::Configuration < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a configuration that describes the functionality and behavior of a PortalSession + # + # source://stripe//lib/stripe/resources/billing_portal/configuration.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of configurations that describe the functionality of the customer portal. + # + # source://stripe//lib/stripe/resources/billing_portal/configuration.rb#28 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/billing_portal/configuration.rb#13 + def object_name; end + + # Updates a configuration that describes the functionality of the customer portal. + # + # source://stripe//lib/stripe/resources/billing_portal/configuration.rb#38 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/billing_portal/configuration.rb#12 +Stripe::BillingPortal::Configuration::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# The Billing customer portal is a Stripe-hosted UI for subscription and +# billing management. +# +# A portal configuration describes the functionality and features that you +# want to provide to your customers through the portal. +# +# A portal session describes the instantiation of the customer portal for +# a particular customer. By visiting the session's URL, the customer +# can manage their subscriptions and billing details. For security reasons, +# sessions are short-lived and will expire if the customer does not visit the URL. +# Create sessions on-demand when customers intend to manage their subscriptions +# and billing details. +# +# Related guide: [Customer management](https://stripe.com/customer-management) +# +# source://stripe//lib/stripe/resources/billing_portal/session.rb#20 +class Stripe::BillingPortal::Session < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # Creates a session of the customer portal. + # + # source://stripe//lib/stripe/resources/billing_portal/session.rb#29 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/billing_portal/session.rb#24 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/billing_portal/session.rb#23 +Stripe::BillingPortal::Session::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# This is an object representing a capability for a Stripe account. +# +# Related guide: [Account capabilities](https://stripe.com/docs/connect/account-capabilities) +# +# source://stripe//lib/stripe/resources/capability.rb#8 +class Stripe::Capability < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/capability.rb#16 + def resource_url; end + + class << self + # source://stripe//lib/stripe/resources/capability.rb#12 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/capability.rb#25 + def retrieve(_id, _opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/capability.rb#32 + def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/capability.rb#11 +Stripe::Capability::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# You can store multiple cards on a customer in order to charge the customer +# later. You can also store multiple debit cards on a recipient in order to +# transfer to those cards later. +# +# Related guide: [Card payments with Sources](https://stripe.com/docs/sources/cards) +# +# source://stripe//lib/stripe/resources/card.rb#10 +class Stripe::Card < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/card.rb#52 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/card.rb#20 + def resource_url; end + + class << self + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/card.rb#44 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/card.rb#61 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/card.rb#16 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/card.rb#36 + def retrieve(_id, _opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/card.rb#28 + def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/card.rb#15 +Stripe::Card::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# CardError is raised when a user enters a card that can't be charged for +# some reason. +# +# source://stripe//lib/stripe/errors.rb#67 +class Stripe::CardError < ::Stripe::StripeError + # @return [CardError] a new instance of CardError + # + # source://stripe//lib/stripe/errors.rb#70 + def initialize(message, param, code: T.unsafe(nil), http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil)); end + + # Returns the value of attribute param. + # + # source://stripe//lib/stripe/errors.rb#68 + def param; end +end + +# A customer's `Cash balance` represents real funds. Customers can add funds to their cash balance by sending a bank transfer. These funds can be used for payment and can eventually be paid out to your bank account. +# +# source://stripe//lib/stripe/resources/cash_balance.rb#6 +class Stripe::CashBalance < ::Stripe::APIResource + # source://stripe//lib/stripe/resources/cash_balance.rb#12 + def resource_url; end + + class << self + # source://stripe//lib/stripe/resources/cash_balance.rb#8 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/cash_balance.rb#20 + def retrieve(_id, _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/cash_balance.rb#7 +Stripe::CashBalance::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# The `Charge` object represents a single attempt to move money into your Stripe account. +# PaymentIntent confirmation is the most common way to create Charges, but transferring +# money to a different Stripe account through Connect also creates Charges. +# Some legacy payment flows create Charges directly, which is not recommended for new integrations. +# +# source://stripe//lib/stripe/resources/charge.rb#9 +class Stripe::Charge < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Search + extend ::Stripe::APIOperations::Save::ClassMethods + + # Capture the payment of an existing, uncaptured charge that was created with the capture option set to false. + # + # Uncaptured payments expire a set number of days after they are created ([7 by default](https://stripe.com/docs/charges/placing-a-hold)), after which they are marked as refunded and capture attempts will fail. + # + # Don't use this method to capture a PaymentIntent-initiated charge. Use [Capture a PaymentIntent](https://stripe.com/docs/api/payment_intents/capture). + # + # source://stripe//lib/stripe/resources/charge.rb#28 + def capture(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Capture the payment of an existing, uncaptured charge that was created with the capture option set to false. + # + # Uncaptured payments expire a set number of days after they are created ([7 by default](https://stripe.com/docs/charges/placing-a-hold)), after which they are marked as refunded and capture attempts will fail. + # + # Don't use this method to capture a PaymentIntent-initiated charge. Use [Capture a PaymentIntent](https://stripe.com/docs/api/payment_intents/capture). + # + # source://stripe//lib/stripe/resources/charge.rb#42 + def capture(charge, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # This method is no longer recommended—use the [Payment Intents API](https://stripe.com/docs/api/payment_intents) + # to initiate a new payment instead. Confirmation of the PaymentIntent creates the Charge + # object used to request payment. + # + # source://stripe//lib/stripe/resources/charge.rb#54 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of charges you've previously created. The charges are returned in sorted order, with the most recent charges appearing first. + # + # source://stripe//lib/stripe/resources/charge.rb#59 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_refunds(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/charge.rb#17 + def object_name; end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def refunds_url(id, nested_id = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_refund(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/charge.rb#63 + def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/charge.rb#67 + def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end + + # Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/charge.rb#72 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/charge.rb#16 +Stripe::Charge::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/checkout/session.rb#5 +module Stripe::Checkout; end + +# A Checkout Session represents your customer's session as they pay for +# one-time purchases or subscriptions through [Checkout](https://stripe.com/docs/payments/checkout) +# or [Payment Links](https://stripe.com/docs/payments/payment-links). We recommend creating a +# new Session each time your customer attempts to pay. +# +# Once payment is successful, the Checkout Session will contain a reference +# to the [Customer](https://stripe.com/docs/api/customers), and either the successful +# [PaymentIntent](https://stripe.com/docs/api/payment_intents) or an active +# [Subscription](https://stripe.com/docs/api/subscriptions). +# +# You can create a Checkout Session on your server and redirect to its URL +# to begin Checkout. +# +# Related guide: [Checkout quickstart](https://stripe.com/docs/checkout/quickstart) +# +# source://stripe//lib/stripe/resources/checkout/session.rb#20 +class Stripe::Checkout::Session < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # A Session can be expired when it is in one of these statuses: open + # + # After it expires, a customer can't complete a Session and customers loading the Session see a message saying the Session is expired. + # + # source://stripe//lib/stripe/resources/checkout/session.rb#43 + def expire(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/checkout/session.rb#75 + def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a Session object. + # + # source://stripe//lib/stripe/resources/checkout/session.rb#31 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # A Session can be expired when it is in one of these statuses: open + # + # After it expires, a customer can't complete a Session and customers loading the Session see a message saying the Session is expired. + # + # source://stripe//lib/stripe/resources/checkout/session.rb#55 + def expire(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Checkout Sessions. + # + # source://stripe//lib/stripe/resources/checkout/session.rb#65 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/checkout/session.rb#85 + def list_line_items(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/checkout/session.rb#26 + def object_name; end + + # Updates a Session object. + # + # source://stripe//lib/stripe/resources/checkout/session.rb#95 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/checkout/session.rb#25 +Stripe::Checkout::Session::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/climate/order.rb#5 +module Stripe::Climate; end + +# Orders represent your intent to purchase a particular Climate product. When you create an order, the +# payment is deducted from your merchant balance. +# +# source://stripe//lib/stripe/resources/climate/order.rb#8 +class Stripe::Climate::Order < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the + # reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier + # might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe + # provides 90 days advance notice and refunds the amount_total. + # + # source://stripe//lib/stripe/resources/climate/order.rb#22 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the + # reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier + # might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe + # provides 90 days advance notice and refunds the amount_total. + # + # source://stripe//lib/stripe/resources/climate/order.rb#35 + def cancel(order, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a Climate order object for a given Climate product. The order will be processed immediately + # after creation and payment will be deducted your Stripe balance. + # + # source://stripe//lib/stripe/resources/climate/order.rb#46 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Lists all Climate order objects. The orders are returned sorted by creation date, with the + # most recently created orders appearing first. + # + # source://stripe//lib/stripe/resources/climate/order.rb#52 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/climate/order.rb#14 + def object_name; end + + # Updates the specified order by setting the values of the parameters passed. + # + # source://stripe//lib/stripe/resources/climate/order.rb#57 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/climate/order.rb#13 +Stripe::Climate::Order::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Climate product represents a type of carbon removal unit available for reservation. +# You can retrieve it to see the current price and availability. +# +# source://stripe//lib/stripe/resources/climate/product.rb#8 +class Stripe::Climate::Product < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Lists all available Climate product objects. + # + # source://stripe//lib/stripe/resources/climate/product.rb#17 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/climate/product.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/climate/product.rb#11 +Stripe::Climate::Product::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A supplier of carbon removal. +# +# source://stripe//lib/stripe/resources/climate/supplier.rb#7 +class Stripe::Climate::Supplier < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Lists all available Climate supplier objects. + # + # source://stripe//lib/stripe/resources/climate/supplier.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/climate/supplier.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/climate/supplier.rb#10 +Stripe::Climate::Supplier::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# ConfirmationTokens help transport client side data collected by Stripe JS over +# to your server for confirming a PaymentIntent or SetupIntent. If the confirmation +# is successful, values present on the ConfirmationToken are written onto the Intent. +# +# To learn more about how to use ConfirmationToken, visit the related guides: +# - [Finalize payments on the server](https://stripe.com/docs/payments/finalize-payments-on-the-server) +# - [Build two-step confirmation](https://stripe.com/docs/payments/build-a-two-step-confirmation). +# +# source://stripe//lib/stripe/resources/confirmation_token.rb#12 +class Stripe::ConfirmationToken < ::Stripe::APIResource + # source://stripe//lib/stripe/resources/confirmation_token.rb#18 + def test_helpers; end + + class << self + # source://stripe//lib/stripe/resources/confirmation_token.rb#14 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/confirmation_token.rb#13 +Stripe::ConfirmationToken::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/confirmation_token.rb#22 +class Stripe::ConfirmationToken::TestHelpers < ::Stripe::APIResourceTestHelpers + class << self + # Creates a test mode Confirmation Token server side for your integration tests. + # + # source://stripe//lib/stripe/resources/confirmation_token.rb#29 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/confirmation_token.rb#24 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/confirmation_token.rb#23 +Stripe::ConfirmationToken::TestHelpers::RESOURCE_CLASS = Stripe::ConfirmationToken + +# Manages connections across multiple hosts which is useful because the +# library may connect to multiple hosts during a typical session (main API, +# Connect, Uploads). Ruby doesn't provide an easy way to make this happen +# easily, so this class is designed to track what we're connected to and +# manage the lifecycle of those connections. +# +# Note that this class in itself is *not* thread safe. We expect it to be +# instantiated once per thread. +# +# source://stripe//lib/stripe/connection_manager.rb#12 +class Stripe::ConnectionManager + # @return [ConnectionManager] a new instance of ConnectionManager + # + # source://stripe//lib/stripe/connection_manager.rb#20 + def initialize(config = T.unsafe(nil)); end + + # Finishes any active connections by closing their TCP connection and + # clears them from internal tracking. + # + # source://stripe//lib/stripe/connection_manager.rb#37 + def clear; end + + # Returns the value of attribute config. + # + # source://stripe//lib/stripe/connection_manager.rb#18 + def config; end + + # Gets a connection for a given URI. This is for internal use only as it's + # subject to change (we've moved between HTTP client schemes in the past + # and may do it again). + # + # `uri` is expected to be a string. + # + # source://stripe//lib/stripe/connection_manager.rb#51 + def connection_for(uri); end + + # Executes an HTTP request to the given URI with the given method. Also + # allows a request body, headers, and query string to be specified. + # + # @raise [ArgumentError] + # + # source://stripe//lib/stripe/connection_manager.rb#69 + def execute_request(method, uri, body: T.unsafe(nil), headers: T.unsafe(nil), query: T.unsafe(nil), &block); end + + # Timestamp (in seconds procured from the system's monotonic clock) + # indicating when the connection manager last made a request. This is used + # by `StripeClient` to determine whether a connection manager should be + # garbage collected or not. + # + # source://stripe//lib/stripe/connection_manager.rb#17 + def last_used; end + + private + + # `uri` should be a parsed `URI` object. + # + # source://stripe//lib/stripe/connection_manager.rb#141 + def create_connection(uri); end + + # `Net::HTTP` somewhat awkwardly requires each component of a proxy URI + # (host, port, etc.) rather than the URI itself. This method simply parses + # out those pieces to make passing them into a new connection a little less + # ugly. + # + # source://stripe//lib/stripe/connection_manager.rb#179 + def proxy_parts; end + + # source://stripe//lib/stripe/connection_manager.rb#188 + def warn_ssl_verify_none; end +end + +# Stripe needs to collect certain pieces of information about each account +# created. These requirements can differ depending on the account's country. The +# Country Specs API makes these rules available to your integration. +# +# You can also view the information from this API call as [an online +# guide](https://stripe.com/docs/connect/required-verification-information). +# +# source://stripe//lib/stripe/resources/country_spec.rb#11 +class Stripe::CountrySpec < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Lists all Country Spec objects available in the API. + # + # source://stripe//lib/stripe/resources/country_spec.rb#20 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/country_spec.rb#15 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/country_spec.rb#14 +Stripe::CountrySpec::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A coupon contains information about a percent-off or amount-off discount you +# might want to apply to a customer. Coupons may be applied to [subscriptions](https://stripe.com/docs/api#subscriptions), [invoices](https://stripe.com/docs/api#invoices), +# [checkout sessions](https://stripe.com/docs/api/checkout/sessions), [quotes](https://stripe.com/docs/api#quotes), and more. Coupons do not work with conventional one-off [charges](https://stripe.com/docs/api#create_charge) or [payment intents](https://stripe.com/docs/api/payment_intents). +# +# source://stripe//lib/stripe/resources/coupon.rb#8 +class Stripe::Coupon < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API. + # + # source://stripe//lib/stripe/resources/coupon.rb#37 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # You can create coupons easily via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly. + # + # A coupon has either a percent_off or an amount_off and currency. If you set an amount_off, that amount will be subtracted from any invoice's subtotal. For example, an invoice with a subtotal of 100 will have a final total of 0 if a coupon with an amount_off of 200 is applied to it and an invoice with a subtotal of 300 will have a final total of 100 if a coupon with an amount_off of 200 is applied to it. + # + # source://stripe//lib/stripe/resources/coupon.rb#22 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API. + # + # source://stripe//lib/stripe/resources/coupon.rb#27 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your coupons. + # + # source://stripe//lib/stripe/resources/coupon.rb#47 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/coupon.rb#15 + def object_name; end + + # Updates the metadata of a coupon. Other coupon details (currency, duration, amount_off) are, by design, not editable. + # + # source://stripe//lib/stripe/resources/coupon.rb#52 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/coupon.rb#14 +Stripe::Coupon::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Issue a credit note to adjust an invoice's amount after the invoice is finalized. +# +# Related guide: [Credit notes](https://stripe.com/docs/billing/invoices/credit-notes) +# +# source://stripe//lib/stripe/resources/credit_note.rb#8 +class Stripe::CreditNote < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Marks a credit note as void. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). + # + # source://stripe//lib/stripe/resources/credit_note.rb#72 + def void_credit_note(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Issue a credit note to adjust the amount of a finalized invoice. For a status=open invoice, a credit note reduces + # its amount_due. For a status=paid invoice, a credit note does not affect its amount_due. Instead, it can result + # in any combination of the following: + # + # + # Refund: create a new refund (using refund_amount) or link an existing refund (using refund). + # Customer balance credit: credit the customer's balance (using credit_amount) which will be automatically applied to their next invoice when it's finalized. + # Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount). + # + # + # For post-payment credit notes the sum of the refund, credit and outside of Stripe amounts must equal the credit note total. + # + # You may issue multiple credit notes for an invoice. Each credit note will increment the invoice's pre_payment_credit_notes_amount + # or post_payment_credit_notes_amount depending on its status at the time of credit note creation. + # + # source://stripe//lib/stripe/resources/credit_note.rb#32 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of credit notes. + # + # source://stripe//lib/stripe/resources/credit_note.rb#37 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a credit note preview, you'll get a lines property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/credit_note.rb#42 + def list_preview_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/credit_note.rb#14 + def object_name; end + + # Get a preview of a credit note without creating it. + # + # source://stripe//lib/stripe/resources/credit_note.rb#52 + def preview(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates an existing credit note. + # + # source://stripe//lib/stripe/resources/credit_note.rb#62 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Marks a credit note as void. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding). + # + # source://stripe//lib/stripe/resources/credit_note.rb#82 + def void_credit_note(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/credit_note.rb#13 +Stripe::CreditNote::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# The credit note line item object +# +# source://stripe//lib/stripe/resources/credit_note_line_item.rb#6 +class Stripe::CreditNoteLineItem < ::Stripe::StripeObject + class << self + # source://stripe//lib/stripe/resources/credit_note_line_item.rb#8 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/credit_note_line_item.rb#7 +Stripe::CreditNoteLineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# This object represents a customer of your business. Use it to create recurring charges and track payments that belong to the same customer. +# +# Related guide: [Save a card during payment](https://stripe.com/docs/payments/save-during-payment) +# +# source://stripe//lib/stripe/resources/customer.rb#8 +class Stripe::Customer < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Search + extend ::Stripe::APIOperations::Save::ClassMethods + + # Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new + # funding instructions will be created. If funding instructions have already been created for a given customer, the same + # funding instructions will be retrieved. In other words, we will return the same funding instructions each time. + # + # source://stripe//lib/stripe/resources/customer.rb#34 + def create_funding_instructions(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer. + # + # source://stripe//lib/stripe/resources/customer.rb#66 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Removes the currently applied discount on a customer. + # + # source://stripe//lib/stripe/resources/customer.rb#76 + def delete_discount(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of PaymentMethods for a given Customer + # + # source://stripe//lib/stripe/resources/customer.rb#101 + def list_payment_methods(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Retrieves a PaymentMethod object for a given Customer. + # + # source://stripe//lib/stripe/resources/customer.rb#131 + def retrieve_payment_method(payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_resource.rb#45 + def source=(value); end + + # source://stripe//lib/stripe/resources/customer.rb#188 + def test_helpers; end + + class << self + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def balance_transactions_url(id, nested_id = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def cash_balance_transactions_url(id, nested_id = T.unsafe(nil)); end + + # Creates a new customer object. + # + # source://stripe//lib/stripe/resources/customer.rb#27 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_balance_transaction(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new + # funding instructions will be created. If funding instructions have already been created for a given customer, the same + # funding instructions will be retrieved. In other words, we will return the same funding instructions each time. + # + # source://stripe//lib/stripe/resources/customer.rb#46 + def create_funding_instructions(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_source(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_tax_id(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer. + # + # source://stripe//lib/stripe/resources/customer.rb#56 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Removes the currently applied discount on a customer. + # + # source://stripe//lib/stripe/resources/customer.rb#86 + def delete_discount(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#96 + def delete_source(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#96 + def delete_tax_id(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#96 + def detach_source(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your customers. The customers are returned sorted by creation date, with the most recent customers appearing first. + # + # source://stripe//lib/stripe/resources/customer.rb#96 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_balance_transactions(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_cash_balance_transactions(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of PaymentMethods for a given Customer + # + # source://stripe//lib/stripe/resources/customer.rb#111 + def list_payment_methods(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_sources(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_tax_ids(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/customer.rb#17 + def object_name; end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_balance_transaction(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # Retrieves a customer's cash balance. + # + # source://stripe//lib/stripe/resources/customer.rb#121 + def retrieve_cash_balance(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_cash_balance_transaction(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # Retrieves a PaymentMethod object for a given Customer. + # + # source://stripe//lib/stripe/resources/customer.rb#141 + def retrieve_payment_method(customer, payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_source(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_tax_id(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/customer.rb#150 + def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/customer.rb#154 + def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def sources_url(id, nested_id = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def tax_ids_url(id, nested_id = T.unsafe(nil)); end + + # Updates the specified customer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. For example, if you pass the source parameter, that becomes the customer's active source (e.g., a card) to be used for all charges in the future. When you update a customer to a new valid card source by passing the source parameter: for each of the customer's current subscriptions, if the subscription bills automatically and is in the past_due state, then the latest open invoice for the subscription with automatic collection enabled will be retried. This retry will not count as an automatic retry, and will not affect the next regularly scheduled payment for the invoice. Changing the default_source for a customer will not trigger this behavior. + # + # This request accepts mostly the same arguments as the customer creation call. + # + # source://stripe//lib/stripe/resources/customer.rb#161 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#86 + def update_balance_transaction(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Changes the settings on a customer's cash balance. + # + # source://stripe//lib/stripe/resources/customer.rb#171 + def update_cash_balance(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#86 + def update_source(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/customer.rb#16 +Stripe::Customer::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/customer.rb#192 +class Stripe::Customer::TestHelpers < ::Stripe::APIResourceTestHelpers + # Create an incoming testmode bank transfer + # + # source://stripe//lib/stripe/resources/customer.rb#209 + def fund_cash_balance(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Create an incoming testmode bank transfer + # + # source://stripe//lib/stripe/resources/customer.rb#199 + def fund_cash_balance(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/customer.rb#194 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/customer.rb#193 +Stripe::Customer::TestHelpers::RESOURCE_CLASS = Stripe::Customer + +# Each customer has a [Balance](https://stripe.com/docs/api/customers/object#customer_object-balance) value, +# which denotes a debit or credit that's automatically applied to their next invoice upon finalization. +# You may modify the value directly by using the [update customer API](https://stripe.com/docs/api/customers/update), +# or by creating a Customer Balance Transaction, which increments or decrements the customer's `balance` by the specified `amount`. +# +# Related guide: [Customer balance](https://stripe.com/docs/billing/customer/balance) +# +# source://stripe//lib/stripe/resources/customer_balance_transaction.rb#11 +class Stripe::CustomerBalanceTransaction < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/customer_balance_transaction.rb#19 + def resource_url; end + + class << self + # source://stripe//lib/stripe/resources/customer_balance_transaction.rb#15 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/customer_balance_transaction.rb#27 + def retrieve(_id, _opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/customer_balance_transaction.rb#33 + def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/customer_balance_transaction.rb#14 +Stripe::CustomerBalanceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Customers with certain payments enabled have a cash balance, representing funds that were paid +# by the customer to a merchant, but have not yet been allocated to a payment. Cash Balance Transactions +# represent when funds are moved into or out of this balance. This includes funding by the customer, allocation +# to payments, and refunds to the customer. +# +# source://stripe//lib/stripe/resources/customer_cash_balance_transaction.rb#9 +class Stripe::CustomerCashBalanceTransaction < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/customer_cash_balance_transaction.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/customer_cash_balance_transaction.rb#10 +Stripe::CustomerCashBalanceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Customer Session allows you to grant Stripe's frontend SDKs (like Stripe.js) client-side access +# control over a Customer. +# +# source://stripe//lib/stripe/resources/customer_session.rb#7 +class Stripe::CustomerSession < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # Creates a Customer Session object that includes a single-use client secret that you can use on your front-end to grant client-side API access for certain customer resources. + # + # source://stripe//lib/stripe/resources/customer_session.rb#16 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/customer_session.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/customer_session.rb#10 +Stripe::CustomerSession::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe.rb#56 +Stripe::DEFAULT_CA_BUNDLE_PATH = T.let(T.unsafe(nil), String) + +# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes). +# It contains information about when the discount began, when it will end, and what it is applied to. +# +# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts) +# +# source://stripe//lib/stripe/resources/discount.rb#9 +class Stripe::Discount < ::Stripe::StripeObject + class << self + # source://stripe//lib/stripe/resources/discount.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/discount.rb#10 +Stripe::Discount::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A dispute occurs when a customer questions your charge with their card issuer. +# When this happens, you have the opportunity to respond to the dispute with +# evidence that shows that the charge is legitimate. +# +# Related guide: [Disputes and fraud](https://stripe.com/docs/disputes) +# +# source://stripe//lib/stripe/resources/dispute.rb#10 +class Stripe::Dispute < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost. + # + # The status of the dispute will change from needs_response to lost. Closing a dispute is irreversible. + # + # source://stripe//lib/stripe/resources/dispute.rb#22 + def close(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost. + # + # The status of the dispute will change from needs_response to lost. Closing a dispute is irreversible. + # + # source://stripe//lib/stripe/resources/dispute.rb#34 + def close(dispute, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your disputes. + # + # source://stripe//lib/stripe/resources/dispute.rb#44 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/dispute.rb#15 + def object_name; end + + # When you get a dispute, contacting your customer is always the best first step. If that doesn't work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your [dashboard](https://dashboard.stripe.com/disputes), but if you prefer, you can use the API to submit evidence programmatically. + # + # Depending on your dispute type, different evidence fields will give you a better chance of winning your dispute. To figure out which evidence fields to provide, see our [guide to dispute types](https://stripe.com/docs/disputes/categories). + # + # source://stripe//lib/stripe/resources/dispute.rb#51 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/dispute.rb#14 +Stripe::Dispute::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/entitlements/active_entitlement.rb#5 +module Stripe::Entitlements; end + +# An active entitlement describes access to a feature for a customer. +# +# source://stripe//lib/stripe/resources/entitlements/active_entitlement.rb#7 +class Stripe::Entitlements::ActiveEntitlement < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Retrieve a list of active entitlements for a customer + # + # source://stripe//lib/stripe/resources/entitlements/active_entitlement.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/entitlements/active_entitlement.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/entitlements/active_entitlement.rb#10 +Stripe::Entitlements::ActiveEntitlement::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A feature represents a monetizable ability or functionality in your system. +# Features can be assigned to products, and when those products are purchased, Stripe will create an entitlement to the feature for the purchasing customer. +# +# source://stripe//lib/stripe/resources/entitlements/feature.rb#8 +class Stripe::Entitlements::Feature < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a feature + # + # source://stripe//lib/stripe/resources/entitlements/feature.rb#19 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Retrieve a list of features + # + # source://stripe//lib/stripe/resources/entitlements/feature.rb#29 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/entitlements/feature.rb#14 + def object_name; end + + # Update a feature's metadata or permanently deactivate it. + # + # source://stripe//lib/stripe/resources/entitlements/feature.rb#39 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/entitlements/feature.rb#13 +Stripe::Entitlements::Feature::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/ephemeral_key.rb#5 +class Stripe::EphemeralKey < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + + # Invalidates a short-lived API key for a given resource. + # + # source://stripe//lib/stripe/resources/ephemeral_key.rb#25 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # source://stripe//lib/stripe/resources/ephemeral_key.rb#34 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Invalidates a short-lived API key for a given resource. + # + # source://stripe//lib/stripe/resources/ephemeral_key.rb#15 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/ephemeral_key.rb#10 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/ephemeral_key.rb#9 +Stripe::EphemeralKey::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Represents an error object as returned by the API. +# +# @see https://stripe.com/docs/api/errors +# +# source://stripe//lib/stripe/error_object.rb#7 +class Stripe::ErrorObject < ::Stripe::StripeObject + # For card errors, the ID of the failed charge. + # + # source://stripe//lib/stripe/error_object.rb#15 + def charge; end + + # For some errors that could be handled programmatically, a short string + # indicating the error code reported. + # + # source://stripe//lib/stripe/error_object.rb#21 + def code; end + + # For card errors resulting from a card issuer decline, a short string + # indicating the card issuer's reason for the decline if they provide one. + # + # source://stripe//lib/stripe/error_object.rb#27 + def decline_code; end + + # A URL to more information about the error code reported. + # + # source://stripe//lib/stripe/error_object.rb#32 + def doc_url; end + + # A human-readable message providing more details about the error. For card + # errors, these messages can be shown to your users. + # + # source://stripe//lib/stripe/error_object.rb#38 + def message; end + + # If the error is parameter-specific, the parameter related to the error. + # For example, you can use this to display a message near the correct form + # field. + # + # source://stripe//lib/stripe/error_object.rb#45 + def param; end + + # The PaymentIntent object for errors returned on a request involving a + # PaymentIntent. + # + # source://stripe//lib/stripe/error_object.rb#51 + def payment_intent; end + + # The PaymentMethod object for errors returned on a request involving a + # PaymentMethod. + # + # source://stripe//lib/stripe/error_object.rb#57 + def payment_method; end + + # The SetupIntent object for errors returned on a request involving a + # SetupIntent. + # + # source://stripe//lib/stripe/error_object.rb#63 + def setup_intent; end + + # The source object for errors returned on a request involving a source. + # + # source://stripe//lib/stripe/error_object.rb#68 + def source; end + + # The type of error returned. One of `api_error`, `card_error`, + # `idempotency_error`, or `invalid_request_error`. + # + # source://stripe//lib/stripe/error_object.rb#74 + def type; end +end + +# Events are our way of letting you know when something interesting happens in +# your account. When an interesting event occurs, we create a new `Event` +# object. For example, when a charge succeeds, we create a `charge.succeeded` +# event, and when an invoice payment attempt fails, we create an +# `invoice.payment_failed` event. Certain API requests might create multiple +# events. For example, if you create a new subscription for a +# customer, you receive both a `customer.subscription.created` event and a +# `charge.succeeded` event. +# +# Events occur when the state of another API resource changes. The event's data +# field embeds the resource's state at the time of the change. For +# example, a `charge.succeeded` event contains a charge, and an +# `invoice.payment_failed` event contains an invoice. +# +# As with other API resources, you can use endpoints to retrieve an +# [individual event](https://stripe.com/docs/api#retrieve_event) or a [list of events](https://stripe.com/docs/api#list_events) +# from the API. We also have a separate +# [webhooks](http://en.wikipedia.org/wiki/Webhook) system for sending the +# `Event` objects directly to an endpoint on your server. You can manage +# webhooks in your +# [account settings](https://dashboard.stripe.com/account/webhooks). Learn how +# to [listen for events](https://docs.stripe.com/webhooks) +# so that your integration can automatically trigger reactions. +# +# When using [Connect](https://docs.stripe.com/connect), you can also receive event notifications +# that occur in connected accounts. For these events, there's an +# additional `account` attribute in the received `Event` object. +# +# We only guarantee access to events through the [Retrieve Event API](https://stripe.com/docs/api#retrieve_event) +# for 30 days. +# +# source://stripe//lib/stripe/resources/event.rb#35 +class Stripe::Event < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # List events, going back up to 30 days. Each event data is rendered according to Stripe API version at its creation time, specified in [event object](https://docs.stripe.com/api/events/object) api_version attribute (not according to your current Stripe API version or Stripe-Version header). + # + # source://stripe//lib/stripe/resources/event.rb#44 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/event.rb#39 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/event.rb#38 +Stripe::Event::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# `ExchangeRate` objects allow you to determine the rates that Stripe is currently +# using to convert from one currency to another. Since this number is variable +# throughout the day, there are various reasons why you might want to know the current +# rate (for example, to dynamically price an item for a user with a default +# payment in a foreign currency). +# +# Please refer to our [Exchange Rates API](https://stripe.com/docs/fx-rates) guide for more details. +# +# *[Note: this integration path is supported but no longer recommended]* Additionally, +# you can guarantee that a charge is made with an exchange rate that you expect is +# current. To do so, you must pass in the exchange_rate to charges endpoints. If the +# value is no longer up to date, the charge won't go through. Please refer to our +# [Using with charges](https://stripe.com/docs/exchange-rates) guide for more details. +# +# ----- +# +#   +# +# *This Exchange Rates API is a Beta Service and is subject to Stripe's terms of service. You may use the API solely for the purpose of transacting on Stripe. For example, the API may be queried in order to:* +# +# - *localize prices for processing payments on Stripe* +# - *reconcile Stripe transactions* +# - *determine how much money to send to a connected account* +# - *determine app fees to charge a connected account* +# +# *Using this Exchange Rates API beta for any purpose other than to transact on Stripe is strictly prohibited and constitutes a violation of Stripe's terms of service.* +# +# source://stripe//lib/stripe/resources/exchange_rate.rb#31 +class Stripe::ExchangeRate < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a list of objects that contain the rates at which foreign currencies are converted to one another. Only shows the currencies for which Stripe supports. + # + # source://stripe//lib/stripe/resources/exchange_rate.rb#40 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/exchange_rate.rb#35 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/exchange_rate.rb#34 +Stripe::ExchangeRate::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# This object represents files hosted on Stripe's servers. You can upload +# files with the [create file](https://stripe.com/docs/api#create_file) request +# (for example, when uploading dispute evidence). Stripe also +# creates files independently (for example, the results of a [Sigma scheduled +# query](https://stripe.com/docs/api#scheduled_queries)). +# +# Related guide: [File upload guide](https://stripe.com/docs/file-upload) +# +# source://stripe//lib/stripe/resources/file.rb#12 +class Stripe::File < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + class << self + # source://stripe//lib/stripe/resources/file.rb#39 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of the files that your account has access to. Stripe sorts and returns the files by their creation dates, placing the most recently created files at the top. + # + # source://stripe//lib/stripe/resources/file.rb#22 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/file.rb#17 + def object_name; end + + # source://stripe//lib/stripe/resources/file.rb#31 + def object_name_alt; end + + # source://stripe//lib/stripe/resources/file.rb#35 + def resource_url; end + end +end + +# source://stripe//lib/stripe/resources/file.rb#16 +Stripe::File::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# This resource can have two different object names. In latter API +# versions, only `file` is used, but since stripe-ruby may be used with +# any API version, we need to support deserializing the older +# `file_upload` object into the same class. +# +# source://stripe//lib/stripe/resources/file.rb#30 +Stripe::File::OBJECT_NAME_ALT = T.let(T.unsafe(nil), String) + +# To share the contents of a `File` object with non-Stripe users, you can +# create a `FileLink`. `FileLink`s contain a URL that you can use to +# retrieve the contents of the file without authentication. +# +# source://stripe//lib/stripe/resources/file_link.rb#8 +class Stripe::FileLink < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a new file link object. + # + # source://stripe//lib/stripe/resources/file_link.rb#19 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of file links. + # + # source://stripe//lib/stripe/resources/file_link.rb#24 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/file_link.rb#14 + def object_name; end + + # Updates an existing file link object. Expired links can no longer be updated. + # + # source://stripe//lib/stripe/resources/file_link.rb#29 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/file_link.rb#13 +Stripe::FileLink::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/financial_connections/account.rb#5 +module Stripe::FinancialConnections; end + +# A Financial Connections Account represents an account that exists outside of Stripe, to which you have been granted some degree of access. +# +# source://stripe//lib/stripe/resources/financial_connections/account.rb#7 +class Stripe::FinancialConnections::Account < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + # Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions). + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#16 + def disconnect(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Lists all owners for a given Account + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#46 + def list_owners(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Refreshes the data associated with a Financial Connections Account. + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#66 + def refresh_account(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Subscribes to periodic refreshes of data associated with a Financial Connections Account. + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#86 + def subscribe(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Unsubscribes from periodic refreshes of data associated with a Financial Connections Account. + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#106 + def unsubscribe(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions). + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#26 + def disconnect(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Financial Connections Account objects. + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#36 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Lists all owners for a given Account + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#56 + def list_owners(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/financial_connections/account.rb#11 + def object_name; end + + # Refreshes the data associated with a Financial Connections Account. + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#76 + def refresh_account(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Subscribes to periodic refreshes of data associated with a Financial Connections Account. + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#96 + def subscribe(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Unsubscribes from periodic refreshes of data associated with a Financial Connections Account. + # + # source://stripe//lib/stripe/resources/financial_connections/account.rb#116 + def unsubscribe(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/financial_connections/account.rb#10 +Stripe::FinancialConnections::Account::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Describes an owner of an account. +# +# source://stripe//lib/stripe/resources/financial_connections/account_owner.rb#7 +class Stripe::FinancialConnections::AccountOwner < ::Stripe::StripeObject + class << self + # source://stripe//lib/stripe/resources/financial_connections/account_owner.rb#9 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/financial_connections/account_owner.rb#8 +Stripe::FinancialConnections::AccountOwner::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Describes a snapshot of the owners of an account at a particular point in time. +# +# source://stripe//lib/stripe/resources/financial_connections/account_ownership.rb#7 +class Stripe::FinancialConnections::AccountOwnership < ::Stripe::StripeObject + class << self + # source://stripe//lib/stripe/resources/financial_connections/account_ownership.rb#9 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/financial_connections/account_ownership.rb#8 +Stripe::FinancialConnections::AccountOwnership::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Financial Connections Session is the secure way to programmatically launch the client-side Stripe.js modal that lets your users link their accounts. +# +# source://stripe//lib/stripe/resources/financial_connections/session.rb#7 +class Stripe::FinancialConnections::Session < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # To launch the Financial Connections authorization flow, create a Session. The session's client_secret can be used to launch the flow using Stripe.js. + # + # source://stripe//lib/stripe/resources/financial_connections/session.rb#16 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/financial_connections/session.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/financial_connections/session.rb#10 +Stripe::FinancialConnections::Session::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Transaction represents a real transaction that affects a Financial Connections Account balance. +# +# source://stripe//lib/stripe/resources/financial_connections/transaction.rb#7 +class Stripe::FinancialConnections::Transaction < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a list of Financial Connections Transaction objects. + # + # source://stripe//lib/stripe/resources/financial_connections/transaction.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/financial_connections/transaction.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/financial_connections/transaction.rb#10 +Stripe::FinancialConnections::Transaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/forwarding/request.rb#5 +module Stripe::Forwarding; end + +# Instructs Stripe to make a request on your behalf using the destination URL. The destination URL +# is activated by Stripe at the time of onboarding. Stripe verifies requests with your credentials +# provided during onboarding, and injects card details from the payment_method into the request. +# +# Stripe redacts all sensitive fields and headers, including authentication credentials and card numbers, +# before storing the request and response data in the forwarding Request object, which are subject to a +# 30-day retention period. +# +# You can provide a Stripe idempotency key to make sure that requests with the same key result in only one +# outbound request. The Stripe idempotency key provided should be unique and different from any idempotency +# keys provided on the underlying third-party request. +# +# Forwarding Requests are synchronous requests that return a response or time out according to +# Stripe's limits. +# +# Related guide: [Forward card details to third-party API endpoints](https://docs.stripe.com/payments/forwarding). +# +# source://stripe//lib/stripe/resources/forwarding/request.rb#22 +class Stripe::Forwarding::Request < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + class << self + # Creates a ForwardingRequest object. + # + # source://stripe//lib/stripe/resources/forwarding/request.rb#32 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Lists all ForwardingRequest objects. + # + # source://stripe//lib/stripe/resources/forwarding/request.rb#42 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/forwarding/request.rb#27 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/forwarding/request.rb#26 +Stripe::Forwarding::Request::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Each customer has a [`balance`](https://stripe.com/docs/api/customers/object#customer_object-balance) that is +# automatically applied to future invoices and payments using the `customer_balance` payment method. +# Customers can fund this balance by initiating a bank transfer to any account in the +# `financial_addresses` field. +# Related guide: [Customer balance funding instructions](https://stripe.com/docs/payments/customer-balance/funding-instructions) +# +# source://stripe//lib/stripe/resources/funding_instructions.rb#10 +class Stripe::FundingInstructions < ::Stripe::APIResource + # source://stripe//lib/stripe/resources/funding_instructions.rb#16 + def resource_url; end + + class << self + # source://stripe//lib/stripe/resources/funding_instructions.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/funding_instructions.rb#11 +Stripe::FundingInstructions::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# IdempotencyError is raised in cases where an idempotency key was used +# improperly. +# +# source://stripe//lib/stripe/errors.rb#81 +class Stripe::IdempotencyError < ::Stripe::StripeError; end + +# source://stripe//lib/stripe/resources/identity/verification_report.rb#5 +module Stripe::Identity; end + +# A VerificationReport is the result of an attempt to collect and verify data from a user. +# The collection of verification checks performed is determined from the `type` and `options` +# parameters used. You can find the result of each verification check performed in the +# appropriate sub-resource: `document`, `id_number`, `selfie`. +# +# Each VerificationReport contains a copy of any data collected by the user as well as +# reference IDs which can be used to access collected images through the [FileUpload](https://stripe.com/docs/api/files) +# API. To configure and create VerificationReports, use the +# [VerificationSession](https://stripe.com/docs/api/identity/verification_sessions) API. +# +# Related guide: [Accessing verification results](https://stripe.com/docs/identity/verification-sessions#results). +# +# source://stripe//lib/stripe/resources/identity/verification_report.rb#17 +class Stripe::Identity::VerificationReport < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # List all verification reports. + # + # source://stripe//lib/stripe/resources/identity/verification_report.rb#26 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/identity/verification_report.rb#21 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/identity/verification_report.rb#20 +Stripe::Identity::VerificationReport::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A VerificationSession guides you through the process of collecting and verifying the identities +# of your users. It contains details about the type of verification, such as what [verification +# check](https://stripe.com/docs/identity/verification-checks) to perform. Only create one VerificationSession for +# each verification in your system. +# +# A VerificationSession transitions through [multiple +# statuses](https://stripe.com/docs/identity/how-sessions-work) throughout its lifetime as it progresses through +# the verification flow. The VerificationSession contains the user's verified data after +# verification checks are complete. +# +# Related guide: [The Verification Sessions API](https://stripe.com/docs/identity/verification-sessions) +# +# source://stripe//lib/stripe/resources/identity/verification_session.rb#17 +class Stripe::Identity::VerificationSession < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # A VerificationSession object can be canceled when it is in requires_input [status](https://stripe.com/docs/identity/how-sessions-work). + # + # Once canceled, future submission attempts are disabled. This cannot be undone. [Learn more](https://stripe.com/docs/identity/verification-sessions#cancel). + # + # source://stripe//lib/stripe/resources/identity/verification_session.rb#30 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Redact a VerificationSession to remove all collected information from Stripe. This will redact + # the VerificationSession and all objects related to it, including VerificationReports, Events, + # request logs, etc. + # + # A VerificationSession object can be redacted when it is in requires_input or verified + # [status](https://stripe.com/docs/identity/how-sessions-work). Redacting a VerificationSession in requires_action + # state will automatically cancel it. + # + # The redaction process may take up to four days. When the redaction process is in progress, the + # VerificationSession's redaction.status field will be set to processing; when the process is + # finished, it will change to redacted and an identity.verification_session.redacted event + # will be emitted. + # + # Redaction is irreversible. Redacted objects are still accessible in the Stripe API, but all the + # fields that contain personal data will be replaced by the string [redacted] or a similar + # placeholder. The metadata field will also be erased. Redacted objects cannot be updated or + # used for any purpose. + # + # [Learn more](https://stripe.com/docs/identity/verification-sessions#redact). + # + # source://stripe//lib/stripe/resources/identity/verification_session.rb#96 + def redact(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # A VerificationSession object can be canceled when it is in requires_input [status](https://stripe.com/docs/identity/how-sessions-work). + # + # Once canceled, future submission attempts are disabled. This cannot be undone. [Learn more](https://stripe.com/docs/identity/verification-sessions#cancel). + # + # source://stripe//lib/stripe/resources/identity/verification_session.rb#42 + def cancel(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a VerificationSession object. + # + # After the VerificationSession is created, display a verification modal using the session client_secret or send your users to the session's url. + # + # If your API key is in test mode, verification checks won't actually process, though everything else will occur as if in live mode. + # + # Related guide: [Verify your users' identity documents](https://stripe.com/docs/identity/verify-identity-documents) + # + # source://stripe//lib/stripe/resources/identity/verification_session.rb#58 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of VerificationSessions + # + # source://stripe//lib/stripe/resources/identity/verification_session.rb#68 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/identity/verification_session.rb#23 + def object_name; end + + # Redact a VerificationSession to remove all collected information from Stripe. This will redact + # the VerificationSession and all objects related to it, including VerificationReports, Events, + # request logs, etc. + # + # A VerificationSession object can be redacted when it is in requires_input or verified + # [status](https://stripe.com/docs/identity/how-sessions-work). Redacting a VerificationSession in requires_action + # state will automatically cancel it. + # + # The redaction process may take up to four days. When the redaction process is in progress, the + # VerificationSession's redaction.status field will be set to processing; when the process is + # finished, it will change to redacted and an identity.verification_session.redacted event + # will be emitted. + # + # Redaction is irreversible. Redacted objects are still accessible in the Stripe API, but all the + # fields that contain personal data will be replaced by the string [redacted] or a similar + # placeholder. The metadata field will also be erased. Redacted objects cannot be updated or + # used for any purpose. + # + # [Learn more](https://stripe.com/docs/identity/verification-sessions#redact). + # + # source://stripe//lib/stripe/resources/identity/verification_session.rb#124 + def redact(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates a VerificationSession object. + # + # When the session status is requires_input, you can use this method to update the + # verification check and options. + # + # source://stripe//lib/stripe/resources/identity/verification_session.rb#137 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/identity/verification_session.rb#22 +Stripe::Identity::VerificationSession::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/instrumentation.rb#4 +class Stripe::Instrumentation + class << self + # Returns true if there are a non-zero number of subscribers on the given + # topic, and false otherwise. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/instrumentation.rb#84 + def any_subscribers?(topic); end + + # source://stripe//lib/stripe/instrumentation.rb#97 + def notify(topic, event); end + + # source://stripe//lib/stripe/instrumentation.rb#88 + def subscribe(topic, name = T.unsafe(nil), &block); end + + # source://stripe//lib/stripe/instrumentation.rb#93 + def unsubscribe(topic, name); end + + private + + # source://stripe//lib/stripe/instrumentation.rb#101 + def subscribers; end + end +end + +# Event emitted on `request_begin` callback. +# +# source://stripe//lib/stripe/instrumentation.rb#6 +class Stripe::Instrumentation::RequestBeginEvent + # @return [RequestBeginEvent] a new instance of RequestBeginEvent + # + # source://stripe//lib/stripe/instrumentation.rb#19 + def initialize(method:, path:, user_data:); end + + # Returns the value of attribute method. + # + # source://stripe//lib/stripe/instrumentation.rb#7 + def method; end + + # Returns the value of attribute path. + # + # source://stripe//lib/stripe/instrumentation.rb#7 + def path; end + + # Arbitrary user-provided data in the form of a Ruby hash that's passed + # from subscribers on `request_begin` to subscribers on `request_end`. + # `request_begin` subscribers can set keys which will then be available + # in `request_end`. + # + # Note that all subscribers of `request_begin` share the same object, so + # they must be careful to set unique keys so as to not conflict with data + # set by other subscribers. + # + # source://stripe//lib/stripe/instrumentation.rb#17 + def user_data; end +end + +# source://stripe//lib/stripe/instrumentation.rb#55 +class Stripe::Instrumentation::RequestContext + # @return [RequestContext] a new instance of RequestContext + # + # source://stripe//lib/stripe/instrumentation.rb#58 + def initialize(duration:, context:, header:); end + + # Returns the value of attribute body. + # + # source://stripe//lib/stripe/instrumentation.rb#56 + def body; end + + # Returns the value of attribute duration. + # + # source://stripe//lib/stripe/instrumentation.rb#56 + def duration; end + + # Returns the value of attribute header. + # + # source://stripe//lib/stripe/instrumentation.rb#56 + def header; end + + # Returns the value of attribute method. + # + # source://stripe//lib/stripe/instrumentation.rb#56 + def method; end + + # Returns the value of attribute path. + # + # source://stripe//lib/stripe/instrumentation.rb#56 + def path; end + + # Returns the value of attribute request_id. + # + # source://stripe//lib/stripe/instrumentation.rb#56 + def request_id; end +end + +# Event emitted on `request_end` callback. +# +# source://stripe//lib/stripe/instrumentation.rb#28 +class Stripe::Instrumentation::RequestEndEvent + # @return [RequestEndEvent] a new instance of RequestEndEvent + # + # source://stripe//lib/stripe/instrumentation.rb#38 + def initialize(request_context:, response_context:, num_retries:, user_data: T.unsafe(nil)); end + + # Returns the value of attribute duration. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def duration; end + + # Returns the value of attribute http_status. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def http_status; end + + # Returns the value of attribute method. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def method; end + + # Returns the value of attribute num_retries. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def num_retries; end + + # Returns the value of attribute path. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def path; end + + # Returns the value of attribute request_body. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def request_body; end + + # Returns the value of attribute request_header. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def request_header; end + + # Returns the value of attribute request_id. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def request_id; end + + # Returns the value of attribute response_body. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def response_body; end + + # Returns the value of attribute response_header. + # + # source://stripe//lib/stripe/instrumentation.rb#29 + def response_header; end + + # Arbitrary user-provided data in the form of a Ruby hash that's passed + # from subscribers on `request_begin` to subscribers on `request_end`. + # `request_begin` subscribers can set keys which will then be available + # in `request_end`. + # + # source://stripe//lib/stripe/instrumentation.rb#36 + def user_data; end +end + +# This class was renamed for consistency. This alias is here for backwards +# compatibility. +# +# source://stripe//lib/stripe/instrumentation.rb#80 +Stripe::Instrumentation::RequestEvent = Stripe::Instrumentation::RequestEndEvent + +# source://stripe//lib/stripe/instrumentation.rb#68 +class Stripe::Instrumentation::ResponseContext + # @return [ResponseContext] a new instance of ResponseContext + # + # source://stripe//lib/stripe/instrumentation.rb#71 + def initialize(http_status:, response:); end + + # Returns the value of attribute body. + # + # source://stripe//lib/stripe/instrumentation.rb#69 + def body; end + + # Returns the value of attribute header. + # + # source://stripe//lib/stripe/instrumentation.rb#69 + def header; end + + # Returns the value of attribute http_status. + # + # source://stripe//lib/stripe/instrumentation.rb#69 + def http_status; end +end + +# InvalidRequestError is raised when a request is initiated with invalid +# parameters. +# +# source://stripe//lib/stripe/errors.rb#86 +class Stripe::InvalidRequestError < ::Stripe::StripeError + # @return [InvalidRequestError] a new instance of InvalidRequestError + # + # source://stripe//lib/stripe/errors.rb#89 + def initialize(message, param, http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil), code: T.unsafe(nil)); end + + # Returns the value of attribute param. + # + # source://stripe//lib/stripe/errors.rb#87 + def param; end + + # Sets the attribute param + # + # @param value the value to set the attribute param to. + # + # source://stripe//lib/stripe/errors.rb#87 + def param=(_arg0); end +end + +# Invoices are statements of amounts owed by a customer, and are either +# generated one-off, or generated periodically from a subscription. +# +# They contain [invoice items](https://stripe.com/docs/api#invoiceitems), and proration adjustments +# that may be caused by subscription upgrades/downgrades (if necessary). +# +# If your invoice is configured to be billed through automatic charges, +# Stripe automatically finalizes your invoice and attempts payment. Note +# that finalizing the invoice, +# [when automatic](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection), does +# not happen immediately as the invoice is created. Stripe waits +# until one hour after the last webhook was successfully sent (or the last +# webhook timed out after failing). If you (and the platforms you may have +# connected to) have no webhooks configured, Stripe waits one hour after +# creation to finalize the invoice. +# +# If your invoice is configured to be billed by sending an email, then based on your +# [email settings](https://dashboard.stripe.com/account/billing/automatic), +# Stripe will email the invoice to your customer and await payment. These +# emails can contain a link to a hosted page to pay the invoice. +# +# Stripe applies any customer credit on the account before determining the +# amount due for the invoice (i.e., the amount that will be actually +# charged). If the amount due for the invoice is less than Stripe's [minimum allowed charge +# per currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts), the +# invoice is automatically marked paid, and we add the amount due to the +# customer's credit balance which is applied to the next invoice. +# +# More details on the customer's credit balance are +# [here](https://stripe.com/docs/billing/customer/balance). +# +# Related guide: [Send invoices to customers](https://stripe.com/docs/billing/invoices/sending) +# +# source://stripe//lib/stripe/resources/invoice.rb#37 +class Stripe::Invoice < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Search + extend ::Stripe::APIOperations::Save::ClassMethods + + # Adds multiple line items to an invoice. This is only possible when an invoice is still a draft. + # + # source://stripe//lib/stripe/resources/invoice.rb#53 + def add_lines(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://stripe.com/docs/api#void_invoice). + # + # source://stripe//lib/stripe/resources/invoice.rb#104 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method. + # + # source://stripe//lib/stripe/resources/invoice.rb#114 + def finalize_invoice(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes. + # + # source://stripe//lib/stripe/resources/invoice.rb#149 + def mark_uncollectible(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so. + # + # source://stripe//lib/stripe/resources/invoice.rb#169 + def pay(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Removes multiple line items from an invoice. This is only possible when an invoice is still a draft. + # + # source://stripe//lib/stripe/resources/invoice.rb#189 + def remove_lines(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Stripe will automatically send invoices to customers according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email. + # + # Requests made in test-mode result in no emails being sent, despite sending an invoice.sent event. + # + # source://stripe//lib/stripe/resources/invoice.rb#219 + def send_invoice(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates multiple line items on an invoice. This is only possible when an invoice is still a draft. + # + # source://stripe//lib/stripe/resources/invoice.rb#267 + def update_lines(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://stripe.com/docs/api#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found. + # + # Consult with local regulations to determine whether and how an invoice might be amended, canceled, or voided in the jurisdiction you're doing business in. You might need to [issue another invoice or credit note](https://stripe.com/docs/api#create_invoice) instead. Stripe recommends that you consult with your legal counsel for advice specific to your business. + # + # source://stripe//lib/stripe/resources/invoice.rb#289 + def void_invoice(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Adds multiple line items to an invoice. This is only possible when an invoice is still a draft. + # + # source://stripe//lib/stripe/resources/invoice.rb#63 + def add_lines(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # This endpoint creates a draft invoice for a given customer. The invoice remains a draft until you [finalize the invoice, which allows you to [pay](#pay_invoice) or send](https://stripe.com/docs/api#finalize_invoice) the invoice to your customers. + # + # source://stripe//lib/stripe/resources/invoice.rb#73 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice. + # + # Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer's discount. + # + # You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass the subscription_details.proration_date parameter when doing the actual subscription update. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_details.proration_date value passed in the request. + # + # Note: Currency conversion calculations use the latest exchange rates. Exchange rates may vary between the time of the preview and the time of the actual invoice creation. [Learn more](https://docs.stripe.com/currencies/conversions) + # + # source://stripe//lib/stripe/resources/invoice.rb#84 + def create_preview(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://stripe.com/docs/api#void_invoice). + # + # source://stripe//lib/stripe/resources/invoice.rb#94 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method. + # + # source://stripe//lib/stripe/resources/invoice.rb#124 + def finalize_invoice(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def lines_url(id, nested_id = T.unsafe(nil)); end + + # You can list all invoices, or list the invoices for a specific customer. The invoices are returned sorted by creation date, with the most recently created invoices appearing first. + # + # source://stripe//lib/stripe/resources/invoice.rb#134 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_lines(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving an upcoming invoice, you'll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/invoice.rb#139 + def list_upcoming_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes. + # + # source://stripe//lib/stripe/resources/invoice.rb#159 + def mark_uncollectible(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/invoice.rb#46 + def object_name; end + + # Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so. + # + # source://stripe//lib/stripe/resources/invoice.rb#179 + def pay(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Removes multiple line items from an invoice. This is only possible when an invoice is still a draft. + # + # source://stripe//lib/stripe/resources/invoice.rb#199 + def remove_lines(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/invoice.rb#208 + def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/invoice.rb#212 + def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end + + # Stripe will automatically send invoices to customers according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email. + # + # Requests made in test-mode result in no emails being sent, despite sending an invoice.sent event. + # + # source://stripe//lib/stripe/resources/invoice.rb#231 + def send_invoice(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice. + # + # Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer's discount. + # + # You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass the subscription_details.proration_date parameter when doing the actual subscription update. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_details.proration_date value passed in the request. + # + # Note: Currency conversion calculations use the latest exchange rates. Exchange rates may vary between the time of the preview and the time of the actual invoice creation. [Learn more](https://docs.stripe.com/currencies/conversions) + # + # source://stripe//lib/stripe/resources/invoice.rb#247 + def upcoming(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Draft invoices are fully editable. Once an invoice is [finalized](https://stripe.com/docs/billing/invoices/workflow#finalized), + # monetary values, as well as collection_method, become uneditable. + # + # If you would like to stop the Stripe Billing engine from automatically finalizing, reattempting payments on, + # sending reminders for, or [automatically reconciling](https://stripe.com/docs/billing/invoices/reconciliation) invoices, pass + # auto_advance=false. + # + # source://stripe//lib/stripe/resources/invoice.rb#257 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates multiple line items on an invoice. This is only possible when an invoice is still a draft. + # + # source://stripe//lib/stripe/resources/invoice.rb#277 + def update_lines(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://stripe.com/docs/api#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found. + # + # Consult with local regulations to determine whether and how an invoice might be amended, canceled, or voided in the jurisdiction you're doing business in. You might need to [issue another invoice or credit note](https://stripe.com/docs/api#create_invoice) instead. Stripe recommends that you consult with your legal counsel for advice specific to your business. + # + # source://stripe//lib/stripe/resources/invoice.rb#301 + def void_invoice(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/invoice.rb#45 +Stripe::Invoice::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Invoice Items represent the component lines of an [invoice](https://stripe.com/docs/api/invoices). An invoice item is added to an +# invoice by creating or updating it with an `invoice` field, at which point it will be included as +# [an invoice line item](https://stripe.com/docs/api/invoices/line_item) within +# [invoice.lines](https://stripe.com/docs/api/invoices/object#invoice_object-lines). +# +# Invoice Items can be created before you are ready to actually send the invoice. This can be particularly useful when combined +# with a [subscription](https://stripe.com/docs/api/subscriptions). Sometimes you want to add a charge or credit to a customer, but actually charge +# or credit the customer's card only at the end of a regular billing cycle. This is useful for combining several charges +# (to minimize per-transaction fees), or for having Stripe tabulate your usage-based billing totals. +# +# Related guides: [Integrate with the Invoicing API](https://stripe.com/docs/invoicing/integration), [Subscription Invoices](https://stripe.com/docs/billing/invoices/subscription#adding-upcoming-invoice-items). +# +# source://stripe//lib/stripe/resources/invoice_item.rb#16 +class Stripe::InvoiceItem < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice. + # + # source://stripe//lib/stripe/resources/invoice_item.rb#43 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates an item to be added to a draft invoice (up to 250 items per invoice). If no invoice is specified, the item will be on the next invoice created for the customer specified. + # + # source://stripe//lib/stripe/resources/invoice_item.rb#28 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice. + # + # source://stripe//lib/stripe/resources/invoice_item.rb#33 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first. + # + # source://stripe//lib/stripe/resources/invoice_item.rb#53 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/invoice_item.rb#23 + def object_name; end + + # Updates the amount or description of an invoice item on an upcoming invoice. Updating an invoice item is only possible before the invoice it's attached to is closed. + # + # source://stripe//lib/stripe/resources/invoice_item.rb#58 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/invoice_item.rb#22 +Stripe::InvoiceItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/invoice_line_item.rb#5 +class Stripe::InvoiceLineItem < ::Stripe::StripeObject + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # source://stripe//lib/stripe/resources/invoice_line_item.rb#9 + def object_name; end + + # Updates an invoice's line item. Some fields, such as tax_amounts, only live on the invoice line item, + # so they can only be updated through this endpoint. Other fields, such as amount, live on both the invoice + # item and the invoice line item, so updates on this endpoint will propagate to the invoice item as well. + # Updating an invoice's line item is only possible before the invoice is finalized. + # + # source://stripe//lib/stripe/resources/invoice_line_item.rb#17 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/invoice_line_item.rb#8 +Stripe::InvoiceLineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/issuing/authorization.rb#5 +module Stripe::Issuing; end + +# When an [issued card](https://stripe.com/docs/issuing) is used to make a purchase, an Issuing `Authorization` +# object is created. [Authorizations](https://stripe.com/docs/issuing/purchases/authorizations) must be approved for the +# purchase to be completed successfully. +# +# Related guide: [Issued card authorizations](https://stripe.com/docs/issuing/purchases/authorizations) +# +# source://stripe//lib/stripe/resources/issuing/authorization.rb#11 +class Stripe::Issuing::Authorization < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Gem::Deprecate + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/issuing/authorization.rb#23 + def _deprecated_approve(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/authorization.rb#50 + def _deprecated_decline(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations) flow. + # This method is deprecated. Instead, [respond directly to the webhook request to approve an authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling). + def approve(*args, **_arg1, &block); end + + # [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations) flow. + # This method is deprecated. Instead, [respond directly to the webhook request to decline an authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling). + def decline(*args, **_arg1, &block); end + + # source://stripe//lib/stripe/resources/issuing/authorization.rb#95 + def test_helpers; end + + class << self + # source://stripe//lib/stripe/resources/issuing/authorization.rb#35 + def _deprecated_approve(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/authorization.rb#62 + def _deprecated_decline(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations) flow. + # This method is deprecated. Instead, [respond directly to the webhook request to approve an authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling). + def approve(*args, **_arg1, &block); end + + # [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations) flow. + # This method is deprecated. Instead, [respond directly to the webhook request to decline an authorization](https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling). + def decline(*args, **_arg1, &block); end + + # Returns a list of Issuing Authorization objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#76 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/authorization.rb#17 + def object_name; end + + # Updates the specified Issuing Authorization object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#86 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/authorization.rb#16 +Stripe::Issuing::Authorization::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/issuing/authorization.rb#99 +class Stripe::Issuing::Authorization::TestHelpers < ::Stripe::APIResourceTestHelpers + # Capture a test-mode authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#116 + def capture(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Expire a test-mode Authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#146 + def expire(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#166 + def finalize_amount(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Increment a test-mode Authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#186 + def increment(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Reverse a test-mode Authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#206 + def reverse(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Capture a test-mode authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#106 + def capture(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Create a test-mode authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#126 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Expire a test-mode Authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#136 + def expire(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#156 + def finalize_amount(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Increment a test-mode Authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#176 + def increment(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/authorization.rb#101 + def resource_class; end + + # Reverse a test-mode Authorization. + # + # source://stripe//lib/stripe/resources/issuing/authorization.rb#196 + def reverse(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/authorization.rb#100 +Stripe::Issuing::Authorization::TestHelpers::RESOURCE_CLASS = Stripe::Issuing::Authorization + +# You can [create physical or virtual cards](https://stripe.com/docs/issuing/cards) that are issued to cardholders. +# +# source://stripe//lib/stripe/resources/issuing/card.rb#7 +class Stripe::Issuing::Card < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/issuing/card.rb#37 + def test_helpers; end + + class << self + # Creates an Issuing Card object. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Issuing Card objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#23 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/card.rb#13 + def object_name; end + + # Updates the specified Issuing Card object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#28 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/card.rb#12 +Stripe::Issuing::Card::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/issuing/card.rb#41 +class Stripe::Issuing::Card::TestHelpers < ::Stripe::APIResourceTestHelpers + # Updates the shipping status of the specified Issuing Card object to delivered. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#58 + def deliver_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the shipping status of the specified Issuing Card object to failure. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#78 + def fail_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the shipping status of the specified Issuing Card object to returned. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#98 + def return_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the shipping status of the specified Issuing Card object to shipped. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#118 + def ship_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Updates the shipping status of the specified Issuing Card object to delivered. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#48 + def deliver_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the shipping status of the specified Issuing Card object to failure. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#68 + def fail_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/card.rb#43 + def resource_class; end + + # Updates the shipping status of the specified Issuing Card object to returned. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#88 + def return_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the shipping status of the specified Issuing Card object to shipped. + # + # source://stripe//lib/stripe/resources/issuing/card.rb#108 + def ship_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/card.rb#42 +Stripe::Issuing::Card::TestHelpers::RESOURCE_CLASS = Stripe::Issuing::Card + +# An Issuing `Cardholder` object represents an individual or business entity who is [issued](https://stripe.com/docs/issuing) cards. +# +# Related guide: [How to create a cardholder](https://stripe.com/docs/issuing/cards#create-cardholder) +# +# source://stripe//lib/stripe/resources/issuing/cardholder.rb#9 +class Stripe::Issuing::Cardholder < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a new Issuing Cardholder object that can be issued cards. + # + # source://stripe//lib/stripe/resources/issuing/cardholder.rb#20 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Issuing Cardholder objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/issuing/cardholder.rb#30 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/cardholder.rb#15 + def object_name; end + + # Updates the specified Issuing Cardholder object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/issuing/cardholder.rb#40 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/cardholder.rb#14 +Stripe::Issuing::Cardholder::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# As a [card issuer](https://stripe.com/docs/issuing), you can dispute transactions that the cardholder does not recognize, suspects to be fraudulent, or has other issues with. +# +# Related guide: [Issuing disputes](https://stripe.com/docs/issuing/purchases/disputes) +# +# source://stripe//lib/stripe/resources/issuing/dispute.rb#9 +class Stripe::Issuing::Dispute < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence). + # + # source://stripe//lib/stripe/resources/issuing/dispute.rb#40 + def submit(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates an Issuing Dispute object. Individual pieces of evidence within the evidence object are optional at this point. Stripe only validates that required evidence is present during submission. Refer to [Dispute reasons and evidence](https://stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence) for more details about evidence requirements. + # + # source://stripe//lib/stripe/resources/issuing/dispute.rb#20 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Issuing Dispute objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/issuing/dispute.rb#30 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/dispute.rb#15 + def object_name; end + + # Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence). + # + # source://stripe//lib/stripe/resources/issuing/dispute.rb#50 + def submit(dispute, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the specified Issuing Dispute object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Properties on the evidence object can be unset by passing in an empty string. + # + # source://stripe//lib/stripe/resources/issuing/dispute.rb#60 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/dispute.rb#14 +Stripe::Issuing::Dispute::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Personalization Design is a logical grouping of a Physical Bundle, card logo, and carrier text that represents a product line. +# +# source://stripe//lib/stripe/resources/issuing/personalization_design.rb#7 +class Stripe::Issuing::PersonalizationDesign < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#47 + def test_helpers; end + + class << self + # Creates a personalization design object. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of personalization design objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#28 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#13 + def object_name; end + + # Updates a card personalization object. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#38 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/personalization_design.rb#12 +Stripe::Issuing::PersonalizationDesign::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/issuing/personalization_design.rb#51 +class Stripe::Issuing::PersonalizationDesign::TestHelpers < ::Stripe::APIResourceTestHelpers + # Updates the status of the specified testmode personalization design object to active. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#68 + def activate(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the status of the specified testmode personalization design object to inactive. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#88 + def deactivate(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the status of the specified testmode personalization design object to rejected. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#108 + def reject(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Updates the status of the specified testmode personalization design object to active. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#58 + def activate(personalization_design, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the status of the specified testmode personalization design object to inactive. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#78 + def deactivate(personalization_design, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the status of the specified testmode personalization design object to rejected. + # + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#98 + def reject(personalization_design, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/personalization_design.rb#53 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/issuing/personalization_design.rb#52 +Stripe::Issuing::PersonalizationDesign::TestHelpers::RESOURCE_CLASS = Stripe::Issuing::PersonalizationDesign + +# A Physical Bundle represents the bundle of physical items - card stock, carrier letter, and envelope - that is shipped to a cardholder when you create a physical card. +# +# source://stripe//lib/stripe/resources/issuing/physical_bundle.rb#7 +class Stripe::Issuing::PhysicalBundle < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a list of physical bundle objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/issuing/physical_bundle.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/physical_bundle.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/issuing/physical_bundle.rb#10 +Stripe::Issuing::PhysicalBundle::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# An issuing token object is created when an issued card is added to a digital wallet. As a [card issuer](https://stripe.com/docs/issuing), you can [view and manage these tokens](https://stripe.com/docs/issuing/controls/token-management) through Stripe. +# +# source://stripe//lib/stripe/resources/issuing/token.rb#7 +class Stripe::Issuing::Token < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Lists all Issuing Token objects for a given card. + # + # source://stripe//lib/stripe/resources/issuing/token.rb#17 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/token.rb#12 + def object_name; end + + # Attempts to update the specified Issuing Token object to the status specified. + # + # source://stripe//lib/stripe/resources/issuing/token.rb#22 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/token.rb#11 +Stripe::Issuing::Token::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Any use of an [issued card](https://stripe.com/docs/issuing) that results in funds entering or leaving +# your Stripe account, such as a completed purchase or refund, is represented by an Issuing +# `Transaction` object. +# +# Related guide: [Issued card transactions](https://stripe.com/docs/issuing/purchases/transactions) +# +# source://stripe//lib/stripe/resources/issuing/transaction.rb#11 +class Stripe::Issuing::Transaction < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/issuing/transaction.rb#40 + def test_helpers; end + + class << self + # Returns a list of Issuing Transaction objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/issuing/transaction.rb#21 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/transaction.rb#16 + def object_name; end + + # Updates the specified Issuing Transaction object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/issuing/transaction.rb#31 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/issuing/transaction.rb#15 +Stripe::Issuing::Transaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/issuing/transaction.rb#44 +class Stripe::Issuing::Transaction::TestHelpers < ::Stripe::APIResourceTestHelpers + # Refund a test-mode Transaction. + # + # source://stripe//lib/stripe/resources/issuing/transaction.rb#81 + def refund(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Allows the user to capture an arbitrary amount, also known as a forced capture. + # + # source://stripe//lib/stripe/resources/issuing/transaction.rb#51 + def create_force_capture(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Allows the user to refund an arbitrary amount, also known as a unlinked refund. + # + # source://stripe//lib/stripe/resources/issuing/transaction.rb#61 + def create_unlinked_refund(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Refund a test-mode Transaction. + # + # source://stripe//lib/stripe/resources/issuing/transaction.rb#71 + def refund(transaction, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/issuing/transaction.rb#46 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/issuing/transaction.rb#45 +Stripe::Issuing::Transaction::TestHelpers::RESOURCE_CLASS = Stripe::Issuing::Transaction + +# map to the same values as the standard library's logger +# +# source://stripe//lib/stripe.rb#59 +Stripe::LEVEL_DEBUG = T.let(T.unsafe(nil), Integer) + +# source://stripe//lib/stripe.rb#60 +Stripe::LEVEL_ERROR = T.let(T.unsafe(nil), Integer) + +# source://stripe//lib/stripe.rb#61 +Stripe::LEVEL_INFO = T.let(T.unsafe(nil), Integer) + +# A line item. +# +# source://stripe//lib/stripe/resources/line_item.rb#6 +class Stripe::LineItem < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/line_item.rb#8 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/line_item.rb#7 +Stripe::LineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/list_object.rb#4 +class Stripe::ListObject < ::Stripe::StripeObject + include ::Stripe::APIOperations::List + include ::Stripe::APIOperations::Request + include ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Request::ClassMethods + + # @return [ListObject] a new instance of ListObject + # + # source://stripe//lib/stripe/list_object.rb#27 + def initialize(*args); end + + # source://stripe//lib/stripe/list_object.rb#32 + def [](key); end + + # Iterates through each resource in all pages, making additional fetches to + # the API as necessary. + # + # The default iteration direction is forwards according to Stripe's API + # "natural" ordering direction -- newer objects first, and moving towards + # older objects. + # + # However, if the initial list object was fetched using an `ending_before` + # cursor (and only `ending_before`, `starting_after` cannot also be + # included), the method assumes that the user is trying to iterate + # backwards compared to natural ordering and returns results that way -- + # older objects first, and moving towards newer objects. + # + # Note that this method will make as many API calls as necessary to fetch + # all resources. For more granular control, please see +each+ and + # +next_page+. + # + # source://stripe//lib/stripe/list_object.rb#70 + def auto_paging_each(&blk); end + + # Iterates through each resource in the page represented by the current + # `ListObject`. + # + # Note that this method makes no effort to fetch a new page when it gets to + # the end of the current page's resources. See also +auto_paging_each+. + # + # source://stripe//lib/stripe/list_object.rb#50 + def each(&blk); end + + # Returns true if the page object contains no elements. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/list_object.rb#92 + def empty?; end + + # This accessor allows a `ListObject` to inherit various filters that were + # given to a predecessor. This allows for things like consistent limits, + # expansions, and predicates as a user pages through resources. + # + # source://stripe//lib/stripe/list_object.rb#18 + def filters; end + + # This accessor allows a `ListObject` to inherit various filters that were + # given to a predecessor. This allows for things like consistent limits, + # expansions, and predicates as a user pages through resources. + # + # source://stripe//lib/stripe/list_object.rb#18 + def filters=(_arg0); end + + # Fetches the next page in the resource list (if there is one). + # + # This method will try to respect the limit of the current page. If none + # was given, the default limit will be fetched again. + # + # source://stripe//lib/stripe/list_object.rb#107 + def next_page(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Fetches the previous page in the resource list (if there is one). + # + # This method will try to respect the limit of the current page. If none + # was given, the default limit will be fetched again. + # + # source://stripe//lib/stripe/list_object.rb#121 + def previous_page(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/list_object.rb#131 + def resource_url; end + + # source://stripe//lib/stripe/list_object.rb#96 + def retrieve(id, opts = T.unsafe(nil)); end + + # Iterates through each resource in the page represented by the current + # `ListObject` in reverse. + # + # source://stripe//lib/stripe/list_object.rb#138 + def reverse_each(&blk); end + + class << self + # An empty list object. This is returned from +next+ when we know that + # there isn't a next page in order to replicate the behavior of the API + # when it attempts to return a page beyond the last. + # + # source://stripe//lib/stripe/list_object.rb#23 + def empty_list(opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/list_object.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/list_object.rb#10 +Stripe::ListObject::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Login Links are single-use URLs for a connected account to access the Express Dashboard. The connected account's [account.controller.stripe_dashboard.type](https://stripe.com/api/accounts/object#account_object-controller-stripe_dashboard-type) must be `express` to have access to the Express Dashboard. +# +# source://stripe//lib/stripe/resources/login_link.rb#6 +class Stripe::LoginLink < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/login_link.rb#8 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/login_link.rb#12 + def retrieve(_id, _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/login_link.rb#7 +Stripe::LoginLink::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Mandate is a record of the permission that your customer gives you to debit their payment method. +# +# source://stripe//lib/stripe/resources/mandate.rb#6 +class Stripe::Mandate < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/mandate.rb#8 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/mandate.rb#7 +Stripe::Mandate::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Encodes parameters into a `multipart/form-data` payload as described by RFC +# 2388: +# +# https://tools.ietf.org/html/rfc2388 +# +# This is most useful for transferring file-like objects. +# +# Parameters should be added with `#encode`. When ready, use `#body` to get +# the encoded result and `#content_type` to get the value that should be +# placed in the `Content-Type` header of a subsequent request (which includes +# a boundary value). +# +# source://stripe//lib/stripe/multipart_encoder.rb#18 +class Stripe::MultipartEncoder + # Initializes a new multipart encoder. + # + # @return [MultipartEncoder] a new instance of MultipartEncoder + # + # source://stripe//lib/stripe/multipart_encoder.rb#37 + def initialize; end + + # Gets the encoded body. `#close` must be called first. + # + # source://stripe//lib/stripe/multipart_encoder.rb#52 + def body; end + + # Gets the object's randomly generated boundary string. + # + # source://stripe//lib/stripe/multipart_encoder.rb#34 + def boundary; end + + # Finalizes the object by writing the final boundary. + # + # source://stripe//lib/stripe/multipart_encoder.rb#59 + def close; end + + # Gets the value including boundary that should be put into a multipart + # request's `Content-Type`. + # + # source://stripe//lib/stripe/multipart_encoder.rb#72 + def content_type; end + + # Encodes a set of parameters to the body. + # + # Note that parameters are expected to be a hash, but a "flat" hash such + # that complex substructures like hashes and arrays have already been + # appropriately Stripe-encoded. Pass a complex structure through + # `Util.flatten_params` first before handing it off to this method. + # + # source://stripe//lib/stripe/multipart_encoder.rb#82 + def encode(params); end + + private + + # Escapes double quotes so that the given value can be used in a + # double-quoted string and replaces any linebreak characters with spaces. + # + # source://stripe//lib/stripe/multipart_encoder.rb#104 + def escape(str); end + + # source://stripe//lib/stripe/multipart_encoder.rb#108 + def write_field(name, data, filename:); end + + class << self + # A shortcut for encoding a single set of parameters and finalizing a + # result. + # + # Returns an encoded body and the value that should be set in the content + # type header of a subsequent request. + # + # source://stripe//lib/stripe/multipart_encoder.rb#26 + def encode(params); end + end +end + +# source://stripe//lib/stripe/multipart_encoder.rb#19 +Stripe::MultipartEncoder::MULTIPART_FORM_DATA = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/errors.rb#120 +module Stripe::OAuth + class << self + # source://stripe//lib/stripe/oauth.rb#31 + def authorize_url(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/oauth.rb#55 + def deauthorize(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/oauth.rb#17 + def get_client_id(params = T.unsafe(nil)); end + + # source://stripe//lib/stripe/oauth.rb#45 + def token(params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# InvalidClientError is raised when the client doesn't belong to you, or +# the API key mode (live or test) doesn't match the client mode. Or the +# stripe_user_id doesn't exist or isn't connected to your application. +# +# source://stripe//lib/stripe/errors.rb#140 +class Stripe::OAuth::InvalidClientError < ::Stripe::OAuth::OAuthError; end + +# InvalidGrantError is raised when a specified code doesn't exist, is +# expired, has been used, or doesn't belong to you; a refresh token doesn't +# exist, or doesn't belong to you; or if an API key's mode (live or test) +# doesn't match the mode of a code or refresh token. +# +# source://stripe//lib/stripe/errors.rb#147 +class Stripe::OAuth::InvalidGrantError < ::Stripe::OAuth::OAuthError; end + +# InvalidRequestError is raised when a code, refresh token, or grant type +# parameter is not provided, but was required. +# +# source://stripe//lib/stripe/errors.rb#152 +class Stripe::OAuth::InvalidRequestError < ::Stripe::OAuth::OAuthError; end + +# InvalidScopeError is raised when an invalid scope parameter is provided. +# +# source://stripe//lib/stripe/errors.rb#156 +class Stripe::OAuth::InvalidScopeError < ::Stripe::OAuth::OAuthError; end + +# OAuthError is raised when the OAuth API returns an error. +# +# source://stripe//lib/stripe/errors.rb#122 +class Stripe::OAuth::OAuthError < ::Stripe::StripeError + # @return [OAuthError] a new instance of OAuthError + # + # source://stripe//lib/stripe/errors.rb#123 + def initialize(code, description, http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil)); end + + # source://stripe//lib/stripe/errors.rb#130 + def construct_error_object; end +end + +# source://stripe//lib/stripe/oauth.rb#5 +module Stripe::OAuth::OAuthOperations + extend ::Stripe::APIOperations::Request::ClassMethods + + class << self + # source://stripe//lib/stripe/oauth.rb#8 + def execute_resource_request(method, url, params, opts); end + end +end + +# UnsupportedGrantTypeError is raised when an unuspported grant type +# parameter is specified. +# +# source://stripe//lib/stripe/errors.rb#161 +class Stripe::OAuth::UnsupportedGrantTypeError < ::Stripe::OAuth::OAuthError; end + +# UnsupportedResponseTypeError is raised when an unsupported response type +# parameter is specified. +# +# source://stripe//lib/stripe/errors.rb#166 +class Stripe::OAuth::UnsupportedResponseTypeError < ::Stripe::OAuth::OAuthError; end + +# Represents on OAuth error returned by the OAuth API. +# +# @see https://stripe.com/docs/connect/oauth-reference#post-token-errors +# +# source://stripe//lib/stripe/error_object.rb#82 +class Stripe::OAuthErrorObject < ::Stripe::StripeObject + # A unique error code per error type. + # + # source://stripe//lib/stripe/error_object.rb#84 + def error; end + + # A human readable description of the error. + # + # source://stripe//lib/stripe/error_object.rb#89 + def error_description; end +end + +# source://stripe//lib/stripe/object_types.rb#7 +module Stripe::ObjectTypes + class << self + # source://stripe//lib/stripe/object_types.rb#8 + def object_names_to_classes; end + end +end + +# A PaymentIntent guides you through the process of collecting a payment from your customer. +# We recommend that you create exactly one PaymentIntent for each order or +# customer session in your system. You can reference the PaymentIntent later to +# see the history of payment attempts for a particular session. +# +# A PaymentIntent transitions through +# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses) +# throughout its lifetime as it interfaces with Stripe.js to perform +# authentication flows and ultimately creates at most one successful charge. +# +# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents) +# +# source://stripe//lib/stripe/resources/payment_intent.rb#16 +class Stripe::PaymentIntent < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Search + extend ::Stripe::APIOperations::Save::ClassMethods + + # Manually reconcile the remaining amount for a customer_balance PaymentIntent. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#28 + def apply_customer_balance(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://stripe.com/docs/payments/intents), processing. + # + # After it's canceled, no additional charges are made by the PaymentIntent and any operations on the PaymentIntent fail with an error. For PaymentIntents with a status of requires_capture, the remaining amount_capturable is automatically refunded. + # + # You can't cancel the PaymentIntent for a Checkout Session. [Expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#52 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture. + # + # Uncaptured PaymentIntents are cancelled a set number of days (7 by default) after their creation. + # + # Learn more about [separate authorization and capture](https://stripe.com/docs/payments/capture-later). + # + # source://stripe//lib/stripe/resources/payment_intent.rb#80 + def capture(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Confirm that your customer intends to pay with current or provided + # payment method. Upon confirmation, the PaymentIntent will attempt to initiate + # a payment. + # If the selected payment method requires additional authentication steps, the + # PaymentIntent will transition to the requires_action status and + # suggest additional actions via next_action. If payment fails, + # the PaymentIntent transitions to the requires_payment_method status or the + # canceled status if the confirmation limit is reached. If + # payment succeeds, the PaymentIntent will transition to the succeeded + # status (or requires_capture, if capture_method is set to manual). + # If the confirmation_method is automatic, payment may be attempted + # using our [client SDKs](https://stripe.com/docs/stripe-js/reference#stripe-handle-card-payment) + # and the PaymentIntent's [client_secret](https://stripe.com/docs/api#payment_intent_object-client_secret). + # After next_actions are handled by the client, no additional + # confirmation is required to complete the payment. + # If the confirmation_method is manual, all payment attempts must be + # initiated using a secret key. + # If any actions are required for the payment, the PaymentIntent will + # return to the requires_confirmation state + # after those actions are completed. Your server needs to then + # explicitly re-confirm the PaymentIntent to initiate the next payment + # attempt. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#125 + def confirm(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Perform an incremental authorization on an eligible + # [PaymentIntent](https://stripe.com/docs/api/payment_intents/object). To be eligible, the + # PaymentIntent's status must be requires_capture and + # [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) + # must be true. + # + # Incremental authorizations attempt to increase the authorized amount on + # your customer's card to the new, higher amount provided. Similar to the + # initial authorization, incremental authorizations can be declined. A + # single PaymentIntent can call this endpoint multiple times to further + # increase the authorized amount. + # + # If the incremental authorization succeeds, the PaymentIntent object + # returns with the updated + # [amount](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-amount). + # If the incremental authorization fails, a + # [card_declined](https://stripe.com/docs/error-codes#card-declined) error returns, and no other + # fields on the PaymentIntent or Charge update. The PaymentIntent + # object remains capturable for the previously authorized amount. + # + # Each PaymentIntent can have a maximum of 10 incremental authorization attempts, including declines. + # After it's captured, a PaymentIntent can no longer be incremented. + # + # Learn more about [incremental authorizations](https://stripe.com/docs/terminal/features/incremental-authorizations). + # + # source://stripe//lib/stripe/resources/payment_intent.rb#203 + def increment_authorization(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Verifies microdeposits on a PaymentIntent object. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#280 + def verify_microdeposits(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Manually reconcile the remaining amount for a customer_balance PaymentIntent. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#38 + def apply_customer_balance(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://stripe.com/docs/payments/intents), processing. + # + # After it's canceled, no additional charges are made by the PaymentIntent and any operations on the PaymentIntent fail with an error. For PaymentIntents with a status of requires_capture, the remaining amount_capturable is automatically refunded. + # + # You can't cancel the PaymentIntent for a Checkout Session. [Expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#66 + def cancel(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture. + # + # Uncaptured PaymentIntents are cancelled a set number of days (7 by default) after their creation. + # + # Learn more about [separate authorization and capture](https://stripe.com/docs/payments/capture-later). + # + # source://stripe//lib/stripe/resources/payment_intent.rb#94 + def capture(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Confirm that your customer intends to pay with current or provided + # payment method. Upon confirmation, the PaymentIntent will attempt to initiate + # a payment. + # If the selected payment method requires additional authentication steps, the + # PaymentIntent will transition to the requires_action status and + # suggest additional actions via next_action. If payment fails, + # the PaymentIntent transitions to the requires_payment_method status or the + # canceled status if the confirmation limit is reached. If + # payment succeeds, the PaymentIntent will transition to the succeeded + # status (or requires_capture, if capture_method is set to manual). + # If the confirmation_method is automatic, payment may be attempted + # using our [client SDKs](https://stripe.com/docs/stripe-js/reference#stripe-handle-card-payment) + # and the PaymentIntent's [client_secret](https://stripe.com/docs/api#payment_intent_object-client_secret). + # After next_actions are handled by the client, no additional + # confirmation is required to complete the payment. + # If the confirmation_method is manual, all payment attempts must be + # initiated using a secret key. + # If any actions are required for the payment, the PaymentIntent will + # return to the requires_confirmation state + # after those actions are completed. Your server needs to then + # explicitly re-confirm the PaymentIntent to initiate the next payment + # attempt. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#156 + def confirm(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a PaymentIntent object. + # + # After the PaymentIntent is created, attach a payment method and [confirm](https://stripe.com/docs/api/payment_intents/confirm) + # to continue the payment. Learn more about the available payment flows + # with the Payment Intents API. + # + # When you use confirm=true during creation, it's equivalent to creating + # and confirming the PaymentIntent in the same call. You can use any parameters + # available in the [confirm API](https://stripe.com/docs/api/payment_intents/confirm) when you supply + # confirm=true. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#175 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Perform an incremental authorization on an eligible + # [PaymentIntent](https://stripe.com/docs/api/payment_intents/object). To be eligible, the + # PaymentIntent's status must be requires_capture and + # [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) + # must be true. + # + # Incremental authorizations attempt to increase the authorized amount on + # your customer's card to the new, higher amount provided. Similar to the + # initial authorization, incremental authorizations can be declined. A + # single PaymentIntent can call this endpoint multiple times to further + # increase the authorized amount. + # + # If the incremental authorization succeeds, the PaymentIntent object + # returns with the updated + # [amount](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-amount). + # If the incremental authorization fails, a + # [card_declined](https://stripe.com/docs/error-codes#card-declined) error returns, and no other + # fields on the PaymentIntent or Charge update. The PaymentIntent + # object remains capturable for the previously authorized amount. + # + # Each PaymentIntent can have a maximum of 10 incremental authorization attempts, including declines. + # After it's captured, a PaymentIntent can no longer be incremented. + # + # Learn more about [incremental authorizations](https://stripe.com/docs/terminal/features/incremental-authorizations). + # + # source://stripe//lib/stripe/resources/payment_intent.rb#236 + def increment_authorization(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of PaymentIntents. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#246 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/payment_intent.rb#23 + def object_name; end + + # source://stripe//lib/stripe/resources/payment_intent.rb#250 + def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/payment_intent.rb#259 + def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end + + # Updates properties on a PaymentIntent object without confirming. + # + # Depending on which properties you update, you might need to confirm the + # PaymentIntent again. For example, updating the payment_method + # always requires you to confirm the PaymentIntent again. If you prefer to + # update and confirm at the same time, we recommend updating properties through + # the [confirm API](https://stripe.com/docs/api/payment_intents/confirm) instead. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#270 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Verifies microdeposits on a PaymentIntent object. + # + # source://stripe//lib/stripe/resources/payment_intent.rb#290 + def verify_microdeposits(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/payment_intent.rb#22 +Stripe::PaymentIntent::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A payment link is a shareable URL that will take your customers to a hosted payment page. A payment link can be shared and used multiple times. +# +# When a customer opens a payment link it will open a new [checkout session](https://stripe.com/docs/api/checkout/sessions) to render the payment page. You can use [checkout session events](https://stripe.com/docs/api/events/types#event_types-checkout.session.completed) to track payments through payment links. +# +# Related guide: [Payment Links API](https://stripe.com/docs/payment-links) +# +# source://stripe//lib/stripe/resources/payment_link.rb#10 +class Stripe::PaymentLink < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/payment_link.rb#31 + def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a payment link. + # + # source://stripe//lib/stripe/resources/payment_link.rb#21 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your payment links. + # + # source://stripe//lib/stripe/resources/payment_link.rb#26 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/payment_link.rb#41 + def list_line_items(payment_link, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/payment_link.rb#16 + def object_name; end + + # Updates a payment link. + # + # source://stripe//lib/stripe/resources/payment_link.rb#51 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/payment_link.rb#15 +Stripe::PaymentLink::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# PaymentMethod objects represent your customer's payment instruments. +# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to +# Customer objects to store instrument details for future payments. +# +# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios). +# +# source://stripe//lib/stripe/resources/payment_method.rb#10 +class Stripe::PaymentMethod < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Attaches a PaymentMethod object to a Customer. + # + # To attach a new PaymentMethod to a customer for future payments, we recommend you use a [SetupIntent](https://stripe.com/docs/api/setup_intents) + # or a PaymentIntent with [setup_future_usage](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage). + # These approaches will perform any necessary steps to set up the PaymentMethod for future payments. Using the /v1/payment_methods/:id/attach + # endpoint without first using a SetupIntent or PaymentIntent with setup_future_usage does not optimize the PaymentMethod for + # future use, which makes later declines and payment friction more likely. + # See [Optimizing cards for future payments](https://stripe.com/docs/payments/payment-intents#future-usage) for more information about setting up + # future payments. + # + # To use this PaymentMethod as the default for invoice or subscription payments, + # set [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method), + # on the Customer to the PaymentMethod's ID. + # + # source://stripe//lib/stripe/resources/payment_method.rb#33 + def attach(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer. + # + # source://stripe//lib/stripe/resources/payment_method.rb#72 + def detach(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Attaches a PaymentMethod object to a Customer. + # + # To attach a new PaymentMethod to a customer for future payments, we recommend you use a [SetupIntent](https://stripe.com/docs/api/setup_intents) + # or a PaymentIntent with [setup_future_usage](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage). + # These approaches will perform any necessary steps to set up the PaymentMethod for future payments. Using the /v1/payment_methods/:id/attach + # endpoint without first using a SetupIntent or PaymentIntent with setup_future_usage does not optimize the PaymentMethod for + # future use, which makes later declines and payment friction more likely. + # See [Optimizing cards for future payments](https://stripe.com/docs/payments/payment-intents#future-usage) for more information about setting up + # future payments. + # + # To use this PaymentMethod as the default for invoice or subscription payments, + # set [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method), + # on the Customer to the PaymentMethod's ID. + # + # source://stripe//lib/stripe/resources/payment_method.rb#55 + def attach(payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a PaymentMethod object. Read the [Stripe.js reference](https://stripe.com/docs/stripe-js/reference#stripe-create-payment-method) to learn how to create PaymentMethods via Stripe.js. + # + # Instead of creating a PaymentMethod directly, we recommend using the [PaymentIntents API to accept a payment immediately or the SetupIntent](https://stripe.com/docs/payments/accept-a-payment) API to collect payment method details ahead of a future payment. + # + # source://stripe//lib/stripe/resources/payment_method.rb#67 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer. + # + # source://stripe//lib/stripe/resources/payment_method.rb#82 + def detach(payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of PaymentMethods for Treasury flows. If you want to list the PaymentMethods attached to a Customer for payments, you should use the [List a Customer's PaymentMethods](https://stripe.com/docs/api/payment_methods/customer_list) API instead. + # + # source://stripe//lib/stripe/resources/payment_method.rb#92 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/payment_method.rb#16 + def object_name; end + + # Updates a PaymentMethod object. A PaymentMethod must be attached a customer to be updated. + # + # source://stripe//lib/stripe/resources/payment_method.rb#97 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/payment_method.rb#15 +Stripe::PaymentMethod::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# PaymentMethodConfigurations control which payment methods are displayed to your customers when you don't explicitly specify payment method types. You can have multiple configurations with different sets of payment methods for different scenarios. +# +# There are two types of PaymentMethodConfigurations. Which is used depends on the [charge type](https://stripe.com/docs/connect/charges): +# +# **Direct** configurations apply to payments created on your account, including Connect destination charges, Connect separate charges and transfers, and payments not involving Connect. +# +# **Child** configurations apply to payments created on your connected accounts using direct charges, and charges with the on_behalf_of parameter. +# +# Child configurations have a `parent` that sets default values and controls which settings connected accounts may override. You can specify a parent ID at payment time, and Stripe will automatically resolve the connected account's associated child configuration. Parent configurations are [managed in the dashboard](https://dashboard.stripe.com/settings/payment_methods/connected_accounts) and are not available in this API. +# +# Related guides: +# - [Payment Method Configurations API](https://stripe.com/docs/connect/payment-method-configurations) +# - [Multiple configurations on dynamic payment methods](https://stripe.com/docs/payments/multiple-payment-method-configs) +# - [Multiple configurations for your Connect accounts](https://stripe.com/docs/connect/multiple-payment-method-configurations) +# +# source://stripe//lib/stripe/resources/payment_method_configuration.rb#19 +class Stripe::PaymentMethodConfiguration < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a payment method configuration + # + # source://stripe//lib/stripe/resources/payment_method_configuration.rb#30 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # List payment method configurations + # + # source://stripe//lib/stripe/resources/payment_method_configuration.rb#40 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/payment_method_configuration.rb#25 + def object_name; end + + # Update payment method configuration + # + # source://stripe//lib/stripe/resources/payment_method_configuration.rb#50 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/payment_method_configuration.rb#24 +Stripe::PaymentMethodConfiguration::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A payment method domain represents a web domain that you have registered with Stripe. +# Stripe Elements use registered payment method domains to control where certain payment methods are shown. +# +# Related guide: [Payment method domains](https://stripe.com/docs/payments/payment-methods/pmd-registration). +# +# source://stripe//lib/stripe/resources/payment_method_domain.rb#9 +class Stripe::PaymentMethodDomain < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Some payment methods such as Apple Pay require additional steps to verify a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain. + # The payment method doesn't appear in Elements for this domain until it is active. + # + # To activate a payment method on an existing payment method domain, complete the required validation steps specific to the payment method, and then validate the payment method domain with this endpoint. + # + # Related guides: [Payment method domains](https://stripe.com/docs/payments/payment-methods/pmd-registration). + # + # source://stripe//lib/stripe/resources/payment_method_domain.rb#55 + def validate(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a payment method domain. + # + # source://stripe//lib/stripe/resources/payment_method_domain.rb#20 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Lists the details of existing payment method domains. + # + # source://stripe//lib/stripe/resources/payment_method_domain.rb#30 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/payment_method_domain.rb#15 + def object_name; end + + # Updates an existing payment method domain. + # + # source://stripe//lib/stripe/resources/payment_method_domain.rb#40 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Some payment methods such as Apple Pay require additional steps to verify a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain. + # The payment method doesn't appear in Elements for this domain until it is active. + # + # To activate a payment method on an existing payment method domain, complete the required validation steps specific to the payment method, and then validate the payment method domain with this endpoint. + # + # Related guides: [Payment method domains](https://stripe.com/docs/payments/payment-methods/pmd-registration). + # + # source://stripe//lib/stripe/resources/payment_method_domain.rb#70 + def validate(payment_method_domain, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/payment_method_domain.rb#14 +Stripe::PaymentMethodDomain::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A `Payout` object is created when you receive funds from Stripe, or when you +# initiate a payout to either a bank account or debit card of a [connected +# Stripe account](https://stripe.com/docs/connect/bank-debit-card-payouts). You can retrieve individual payouts, +# and list all payouts. Payouts are made on [varying +# schedules](https://stripe.com/docs/connect/manage-payout-schedule), depending on your country and +# industry. +# +# Related guide: [Receiving payouts](https://stripe.com/docs/payouts) +# +# source://stripe//lib/stripe/resources/payout.rb#13 +class Stripe::Payout < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts. + # + # source://stripe//lib/stripe/resources/payout.rb#24 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead. + # + # By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the authorized signatory of the selected bank account authorizes the debit on the bank account and that no other authorization is required. + # + # source://stripe//lib/stripe/resources/payout.rb#60 + def reverse(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts. + # + # source://stripe//lib/stripe/resources/payout.rb#34 + def cancel(payout, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # To send funds to your own bank account, create a new payout object. Your [Stripe balance](https://stripe.com/docs/api#balance) must cover the payout amount. If it doesn't, you receive an “Insufficient Funds” error. + # + # If your API key is in test mode, money won't actually be sent, though every other action occurs as if you're in live mode. + # + # If you create a manual payout on a Stripe account that uses multiple payment source types, you need to specify the source type balance that the payout draws from. The [balance object](https://stripe.com/docs/api#balance_object) details available and pending amounts by source type. + # + # source://stripe//lib/stripe/resources/payout.rb#48 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of existing payouts sent to third-party bank accounts or payouts that Stripe sent to you. The payouts return in sorted order, with the most recently created payouts appearing first. + # + # source://stripe//lib/stripe/resources/payout.rb#53 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/payout.rb#19 + def object_name; end + + # Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead. + # + # By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the authorized signatory of the selected bank account authorizes the debit on the bank account and that no other authorization is required. + # + # source://stripe//lib/stripe/resources/payout.rb#72 + def reverse(payout, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the specified payout by setting the values of the parameters you pass. We don't change parameters that you don't provide. This request only accepts the metadata as arguments. + # + # source://stripe//lib/stripe/resources/payout.rb#82 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/payout.rb#18 +Stripe::Payout::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# PermissionError is raised in cases where access was attempted on a resource +# that wasn't allowed. +# +# source://stripe//lib/stripe/errors.rb#100 +class Stripe::PermissionError < ::Stripe::StripeError; end + +# This is an object representing a person associated with a Stripe account. +# +# A platform cannot access a person for an account where [account.controller.requirement_collection](https://stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `stripe`, which includes Standard and Express accounts, after creating an Account Link or Account Session to start Connect onboarding. +# +# See the [Standard onboarding](https://stripe.com/connect/standard-accounts) or [Express onboarding](https://stripe.com/connect/express-accounts) documentation for information about prefilling information and account onboarding steps. Learn more about [handling identity verification with the API](https://stripe.com/connect/handling-api-verification#person-information). +# +# source://stripe//lib/stripe/resources/person.rb#10 +class Stripe::Person < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/person.rb#18 + def resource_url; end + + class << self + # source://stripe//lib/stripe/resources/person.rb#14 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/person.rb#26 + def retrieve(_id, _opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/person.rb#32 + def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/person.rb#13 +Stripe::Person::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# You can now model subscriptions more flexibly using the [Prices API](https://stripe.com/docs/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration. +# +# Plans define the base price, currency, and billing cycle for recurring purchases of products. +# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and plans help you track pricing. Different physical goods or levels of service should be represented by products, and pricing options should be represented by plans. This approach lets you change prices without having to change your provisioning scheme. +# +# For example, you might have a single "gold" product that has plans for $10/month, $100/year, €9/month, and €90/year. +# +# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/products-prices/overview). +# +# source://stripe//lib/stripe/resources/plan.rb#13 +class Stripe::Plan < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Deleting plans means new subscribers can't be added. Existing subscribers aren't affected. + # + # source://stripe//lib/stripe/resources/plan.rb#40 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # You can now model subscriptions more flexibly using the [Prices API](https://stripe.com/docs/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration. + # + # source://stripe//lib/stripe/resources/plan.rb#25 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deleting plans means new subscribers can't be added. Existing subscribers aren't affected. + # + # source://stripe//lib/stripe/resources/plan.rb#30 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your plans. + # + # source://stripe//lib/stripe/resources/plan.rb#50 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/plan.rb#20 + def object_name; end + + # Updates the specified plan by setting the values of the parameters passed. Any parameters not provided are left unchanged. By design, you cannot change a plan's ID, amount, currency, or billing cycle. + # + # source://stripe//lib/stripe/resources/plan.rb#55 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/plan.rb#19 +Stripe::Plan::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Prices define the unit cost, currency, and (optional) billing cycle for both recurring and one-time purchases of products. +# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and prices help you track payment terms. Different physical goods or levels of service should be represented by products, and pricing options should be represented by prices. This approach lets you change prices without having to change your provisioning scheme. +# +# For example, you might have a single "gold" product that has prices for $10/month, $100/year, and €9 once. +# +# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), [create an invoice](https://stripe.com/docs/billing/invoices/create), and more about [products and prices](https://stripe.com/docs/products-prices/overview). +# +# source://stripe//lib/stripe/resources/price.rb#11 +class Stripe::Price < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Search + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a new price for an existing product. The price can be recurring or one-time. + # + # source://stripe//lib/stripe/resources/price.rb#23 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your active prices, excluding [inline prices](https://stripe.com/docs/products-prices/pricing-models#inline-pricing). For the list of inactive prices, set active to false. + # + # source://stripe//lib/stripe/resources/price.rb#28 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/price.rb#18 + def object_name; end + + # source://stripe//lib/stripe/resources/price.rb#32 + def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/price.rb#36 + def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end + + # Updates the specified price by setting the values of the parameters passed. Any parameters not provided are left unchanged. + # + # source://stripe//lib/stripe/resources/price.rb#41 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/price.rb#17 +Stripe::Price::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Products describe the specific goods or services you offer to your customers. +# For example, you might offer a Standard and Premium version of your goods or service; each version would be a separate Product. +# They can be used in conjunction with [Prices](https://stripe.com/docs/api#prices) to configure pricing in Payment Links, Checkout, and Subscriptions. +# +# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), +# [share a Payment Link](https://stripe.com/docs/payment-links), +# [accept payments with Checkout](https://stripe.com/docs/payments/accept-a-payment#create-product-prices-upfront), +# and more about [Products and Prices](https://stripe.com/docs/products-prices/overview) +# +# source://stripe//lib/stripe/resources/product.rb#13 +class Stripe::Product < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Search + extend ::Stripe::APIOperations::Save::ClassMethods + + # Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it. + # + # source://stripe//lib/stripe/resources/product.rb#44 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new product object. + # + # source://stripe//lib/stripe/resources/product.rb#29 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_feature(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it. + # + # source://stripe//lib/stripe/resources/product.rb#34 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#96 + def delete_feature(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def features_url(id, nested_id = T.unsafe(nil)); end + + # Returns a list of your products. The products are returned sorted by creation date, with the most recently created products appearing first. + # + # source://stripe//lib/stripe/resources/product.rb#54 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_features(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/product.rb#22 + def object_name; end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_feature(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/product.rb#58 + def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/product.rb#62 + def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end + + # Updates the specific product by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/product.rb#67 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/product.rb#21 +Stripe::Product::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A product_feature represents an attachment between a feature and a product. +# When a product is purchased that has a feature attached, Stripe will create an entitlement to the feature for the purchasing customer. +# +# source://stripe//lib/stripe/resources/product_feature.rb#7 +class Stripe::ProductFeature < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/product_feature.rb#9 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/product_feature.rb#8 +Stripe::ProductFeature::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Promotion Code represents a customer-redeemable code for a [coupon](https://stripe.com/docs/api#coupons). It can be used to +# create multiple codes for a single coupon. +# +# source://stripe//lib/stripe/resources/promotion_code.rb#7 +class Stripe::PromotionCode < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # A promotion code points to a coupon. You can optionally restrict the code to a specific customer, redemption limit, and expiration date. + # + # source://stripe//lib/stripe/resources/promotion_code.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your promotion codes. + # + # source://stripe//lib/stripe/resources/promotion_code.rb#23 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/promotion_code.rb#13 + def object_name; end + + # Updates the specified promotion code by setting the values of the parameters passed. Most fields are, by design, not editable. + # + # source://stripe//lib/stripe/resources/promotion_code.rb#28 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/promotion_code.rb#12 +Stripe::PromotionCode::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Quote is a way to model prices that you'd like to provide to a customer. +# Once accepted, it will automatically create an invoice, subscription or subscription schedule. +# +# source://stripe//lib/stripe/resources/quote.rb#7 +class Stripe::Quote < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Accepts the specified quote. + # + # source://stripe//lib/stripe/resources/quote.rb#18 + def accept(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Cancels the quote. + # + # source://stripe//lib/stripe/resources/quote.rb#38 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Finalizes the quote. + # + # source://stripe//lib/stripe/resources/quote.rb#63 + def finalize_quote(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a quote, there is an includable [computed.upfront.line_items](https://stripe.com/docs/api/quotes/object#quote_object-computed-upfront-line_items) property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items. + # + # source://stripe//lib/stripe/resources/quote.rb#88 + def list_computed_upfront_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/quote.rb#108 + def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.corp.stripe.com/quotes/overview#quote_pdf) + # + # source://stripe//lib/stripe/resources/quote.rb#128 + def pdf(params = T.unsafe(nil), opts = T.unsafe(nil), &read_body_chunk_block); end + + class << self + # Accepts the specified quote. + # + # source://stripe//lib/stripe/resources/quote.rb#28 + def accept(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Cancels the quote. + # + # source://stripe//lib/stripe/resources/quote.rb#48 + def cancel(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # A quote models prices and services for a customer. Default options for header, description, footer, and expires_at can be set in the dashboard via the [quote template](https://dashboard.stripe.com/settings/billing/quote). + # + # source://stripe//lib/stripe/resources/quote.rb#58 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Finalizes the quote. + # + # source://stripe//lib/stripe/resources/quote.rb#73 + def finalize_quote(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your quotes. + # + # source://stripe//lib/stripe/resources/quote.rb#83 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a quote, there is an includable [computed.upfront.line_items](https://stripe.com/docs/api/quotes/object#quote_object-computed-upfront-line_items) property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items. + # + # source://stripe//lib/stripe/resources/quote.rb#98 + def list_computed_upfront_line_items(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. + # + # source://stripe//lib/stripe/resources/quote.rb#118 + def list_line_items(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/quote.rb#13 + def object_name; end + + # Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.corp.stripe.com/quotes/overview#quote_pdf) + # + # source://stripe//lib/stripe/resources/quote.rb#141 + def pdf(quote, params = T.unsafe(nil), opts = T.unsafe(nil), &read_body_chunk_block); end + + # A quote models prices and services for a customer. + # + # source://stripe//lib/stripe/resources/quote.rb#154 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/quote.rb#12 +Stripe::Quote::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#5 +module Stripe::Radar; end + +# An early fraud warning indicates that the card issuer has notified us that a +# charge may be fraudulent. +# +# Related guide: [Early fraud warnings](https://stripe.com/docs/disputes/measuring#early-fraud-warnings) +# +# source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#10 +class Stripe::Radar::EarlyFraudWarning < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a list of early fraud warnings. + # + # source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#19 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#14 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#13 +Stripe::Radar::EarlyFraudWarning::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Value lists allow you to group values together which can then be referenced in rules. +# +# Related guide: [Default Stripe lists](https://stripe.com/docs/radar/lists#managing-list-items) +# +# source://stripe//lib/stripe/resources/radar/value_list.rb#9 +class Stripe::Radar::ValueList < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules. + # + # source://stripe//lib/stripe/resources/radar/value_list.rb#41 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new ValueList object, which can then be referenced in rules. + # + # source://stripe//lib/stripe/resources/radar/value_list.rb#21 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules. + # + # source://stripe//lib/stripe/resources/radar/value_list.rb#31 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of ValueList objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/radar/value_list.rb#51 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/radar/value_list.rb#16 + def object_name; end + + # Updates a ValueList object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Note that item_type is immutable. + # + # source://stripe//lib/stripe/resources/radar/value_list.rb#61 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/radar/value_list.rb#15 +Stripe::Radar::ValueList::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Value list items allow you to add specific values to a given Radar value list, which can then be used in rules. +# +# Related guide: [Managing list items](https://stripe.com/docs/radar/lists#managing-list-items) +# +# source://stripe//lib/stripe/resources/radar/value_list_item.rb#9 +class Stripe::Radar::ValueListItem < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + + # Deletes a ValueListItem object, removing it from its parent value list. + # + # source://stripe//lib/stripe/resources/radar/value_list_item.rb#40 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new ValueListItem object, which is added to the specified parent value list. + # + # source://stripe//lib/stripe/resources/radar/value_list_item.rb#20 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a ValueListItem object, removing it from its parent value list. + # + # source://stripe//lib/stripe/resources/radar/value_list_item.rb#30 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of ValueListItem objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/radar/value_list_item.rb#50 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/radar/value_list_item.rb#15 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/radar/value_list_item.rb#14 +Stripe::Radar::ValueListItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# RateLimitError is raised in cases where an account is putting too much load +# on Stripe's API servers (usually by performing too many requests). Please +# back off on request rate. +# +# source://stripe//lib/stripe/errors.rb#106 +class Stripe::RateLimitError < ::Stripe::StripeError; end + +# source://stripe//lib/stripe.rb#121 +class Stripe::RawRequest + include ::Stripe::APIOperations::Request + extend ::Stripe::APIOperations::Request::ClassMethods + + # @return [RawRequest] a new instance of RawRequest + # + # source://stripe//lib/stripe.rb#124 + def initialize; end + + # source://stripe//lib/stripe.rb#128 + def execute(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), usage = T.unsafe(nil)); end +end + +# Refund objects allow you to refund a previously created charge that isn't +# refunded yet. Funds are refunded to the credit or debit card that's +# initially charged. +# +# Related guide: [Refunds](https://stripe.com/docs/refunds) +# +# source://stripe//lib/stripe/resources/refund.rb#10 +class Stripe::Refund < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Cancels a refund with a status of requires_action. + # + # You can't cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state. + # + # source://stripe//lib/stripe/resources/refund.rb#23 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/refund.rb#76 + def test_helpers; end + + class << self + # Cancels a refund with a status of requires_action. + # + # You can't cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state. + # + # source://stripe//lib/stripe/resources/refund.rb#35 + def cancel(refund, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it. + # + # Creating a new refund will refund a charge that has previously been created but not yet refunded. + # Funds will be refunded to the credit or debit card that was originally charged. + # + # You can optionally refund only part of a charge. + # You can do so multiple times, until the entire charge has been refunded. + # + # Once entirely refunded, a charge can't be refunded again. + # This method will raise an error when called on an already-refunded charge, + # or when trying to refund more money than is left on a charge. + # + # source://stripe//lib/stripe/resources/refund.rb#55 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object. + # + # source://stripe//lib/stripe/resources/refund.rb#60 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/refund.rb#16 + def object_name; end + + # Updates the refund that you specify by setting the values of the passed parameters. Any parameters that you don't provide remain unchanged. + # + # This request only accepts metadata as an argument. + # + # source://stripe//lib/stripe/resources/refund.rb#67 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/refund.rb#15 +Stripe::Refund::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/refund.rb#80 +class Stripe::Refund::TestHelpers < ::Stripe::APIResourceTestHelpers + # Expire a refund with a status of requires_action. + # + # source://stripe//lib/stripe/resources/refund.rb#97 + def expire(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Expire a refund with a status of requires_action. + # + # source://stripe//lib/stripe/resources/refund.rb#87 + def expire(refund, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/refund.rb#82 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/refund.rb#81 +Stripe::Refund::TestHelpers::RESOURCE_CLASS = Stripe::Refund + +# source://stripe//lib/stripe/resources/reporting/report_run.rb#5 +module Stripe::Reporting; end + +# The Report Run object represents an instance of a report type generated with +# specific run parameters. Once the object is created, Stripe begins processing the report. +# When the report has finished running, it will give you a reference to a file +# where you can retrieve your results. For an overview, see +# [API Access to Reports](https://stripe.com/docs/reporting/statements/api). +# +# Note that certain report types can only be run based on your live-mode data (not test-mode +# data), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes). +# +# source://stripe//lib/stripe/resources/reporting/report_run.rb#14 +class Stripe::Reporting::ReportRun < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + class << self + # Creates a new object and begin running the report. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).) + # + # source://stripe//lib/stripe/resources/reporting/report_run.rb#24 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Report Runs, with the most recent appearing first. + # + # source://stripe//lib/stripe/resources/reporting/report_run.rb#34 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/reporting/report_run.rb#19 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/reporting/report_run.rb#18 +Stripe::Reporting::ReportRun::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# The Report Type resource corresponds to a particular type of report, such as +# the "Activity summary" or "Itemized payouts" reports. These objects are +# identified by an ID belonging to a set of enumerated values. See +# [API Access to Reports documentation](https://stripe.com/docs/reporting/statements/api) +# for those Report Type IDs, along with required and optional parameters. +# +# Note that certain report types can only be run based on your live-mode data (not test-mode +# data), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes). +# +# source://stripe//lib/stripe/resources/reporting/report_type.rb#14 +class Stripe::Reporting::ReportType < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a full list of Report Types. + # + # source://stripe//lib/stripe/resources/reporting/report_type.rb#23 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/reporting/report_type.rb#18 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/reporting/report_type.rb#17 +Stripe::Reporting::ReportType::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# [Stripe Connect](https://stripe.com/docs/connect) platforms can reverse transfers made to a +# connected account, either entirely or partially, and can also specify whether +# to refund any related application fees. Transfer reversals add to the +# platform's balance and subtract from the destination account's balance. +# +# Reversing a transfer that was made for a [destination +# charge](https://stripe.com/docs/connect/destination-charges) is allowed only up to the amount of +# the charge. It is possible to reverse a +# [transfer_group](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) +# transfer only if the destination account has enough balance to cover the +# reversal. +# +# Related guide: [Reverse transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#reverse-transfers) +# +# source://stripe//lib/stripe/resources/reversal.rb#18 +class Stripe::Reversal < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Save::ClassMethods + + # source://stripe//lib/stripe/resources/reversal.rb#26 + def resource_url; end + + class << self + # source://stripe//lib/stripe/resources/reversal.rb#22 + def object_name; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/reversal.rb#38 + def retrieve(_id, _opts = T.unsafe(nil)); end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/resources/reversal.rb#31 + def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/reversal.rb#21 +Stripe::Reversal::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Reviews can be used to supplement automated fraud detection with human expertise. +# +# Learn more about [Radar](https://stripe.com/radar) and reviewing payments +# [here](https://stripe.com/docs/radar/reviews). +# +# source://stripe//lib/stripe/resources/review.rb#9 +class Stripe::Review < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + # Approves a Review object, closing it and removing it from the list of reviews. + # + # source://stripe//lib/stripe/resources/review.rb#18 + def approve(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Approves a Review object, closing it and removing it from the list of reviews. + # + # source://stripe//lib/stripe/resources/review.rb#28 + def approve(review, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Review objects that have open set to true. The objects are sorted in descending order by creation date, with the most recently created object appearing first. + # + # source://stripe//lib/stripe/resources/review.rb#38 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/review.rb#13 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/review.rb#12 +Stripe::Review::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/search_result_object.rb#4 +class Stripe::SearchResultObject < ::Stripe::StripeObject + include ::Stripe::APIOperations::Search + include ::Stripe::APIOperations::Request + extend ::Stripe::APIOperations::Request::ClassMethods + + # @return [SearchResultObject] a new instance of SearchResultObject + # + # source://stripe//lib/stripe/search_result_object.rb#26 + def initialize(*args); end + + # source://stripe//lib/stripe/search_result_object.rb#31 + def [](key); end + + # Iterates through each resource in all pages, making additional fetches to + # the API as necessary. + # + # Note that this method will make as many API calls as necessary to fetch + # all resources. For more granular control, please see +each+ and + # +next_search_result_page+. + # + # source://stripe//lib/stripe/search_result_object.rb#64 + def auto_paging_each(&blk); end + + # Iterates through each resource in the page represented by the current + # `SearchListObject`. + # + # Note that this method makes no effort to fetch a new page when it gets to + # the end of the current page's resources. See also +auto_paging_each+. + # + # source://stripe//lib/stripe/search_result_object.rb#49 + def each(&blk); end + + # Returns true if the page object contains no elements. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/search_result_object.rb#54 + def empty?; end + + # This accessor allows a `SearchResultObject` to inherit various filters + # that were given to a predecessor. This allows for things like consistent + # limits, expansions, and predicates as a user pages through resources. + # + # source://stripe//lib/stripe/search_result_object.rb#17 + def filters; end + + # This accessor allows a `SearchResultObject` to inherit various filters + # that were given to a predecessor. This allows for things like consistent + # limits, expansions, and predicates as a user pages through resources. + # + # source://stripe//lib/stripe/search_result_object.rb#17 + def filters=(_arg0); end + + # Fetches the next page in the resource list (if there is one). + # + # This method will try to respect the limit of the current page. If none + # was given, the default limit will be fetched again. + # + # source://stripe//lib/stripe/search_result_object.rb#81 + def next_search_result_page(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # An empty search result object. This is returned from +next+ when we know + # that there isn't a next page in order to replicate the behavior of the API + # when it attempts to return a page beyond the last. + # + # source://stripe//lib/stripe/search_result_object.rb#22 + def empty_search_result(opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/search_result_object.rb#10 + def object_name; end + end +end + +# source://stripe//lib/stripe/search_result_object.rb#9 +Stripe::SearchResultObject::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A SetupAttempt describes one attempted confirmation of a SetupIntent, +# whether that confirmation is successful or unsuccessful. You can use +# SetupAttempts to inspect details of a specific attempt at setting up a +# payment method using a SetupIntent. +# +# source://stripe//lib/stripe/resources/setup_attempt.rb#9 +class Stripe::SetupAttempt < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a list of SetupAttempts that associate with a provided SetupIntent. + # + # source://stripe//lib/stripe/resources/setup_attempt.rb#18 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/setup_attempt.rb#13 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/setup_attempt.rb#12 +Stripe::SetupAttempt::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments. +# For example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment. +# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow. +# +# Create a SetupIntent when you're ready to collect your customer's payment credentials. +# Don't maintain long-lived, unconfirmed SetupIntents because they might not be valid. +# The SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides +# you through the setup process. +# +# Successful SetupIntents result in payment credentials that are optimized for future payments. +# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through +# [Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection +# to streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents). +# If you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer), +# it automatically attaches the resulting payment method to that Customer after successful setup. +# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on +# PaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods. +# +# By using SetupIntents, you can reduce friction for your customers, even as regulations change over time. +# +# Related guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents) +# +# source://stripe//lib/stripe/resources/setup_intent.rb#26 +class Stripe::SetupIntent < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. + # + # After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#39 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Confirm that your customer intends to set up the current or + # provided payment method. For example, you would confirm a SetupIntent + # when a customer hits the “Save” button on a payment method management + # page on your website. + # + # If the selected payment method does not require any additional + # steps from the customer, the SetupIntent will transition to the + # succeeded status. + # + # Otherwise, it will transition to the requires_action status and + # suggest additional actions via next_action. If setup fails, + # the SetupIntent will transition to the + # requires_payment_method status or the canceled status if the + # confirmation limit is reached. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#74 + def confirm(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Verifies microdeposits on a SetupIntent object. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#130 + def verify_microdeposits(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. + # + # After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#51 + def cancel(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Confirm that your customer intends to set up the current or + # provided payment method. For example, you would confirm a SetupIntent + # when a customer hits the “Save” button on a payment method management + # page on your website. + # + # If the selected payment method does not require any additional + # steps from the customer, the SetupIntent will transition to the + # succeeded status. + # + # Otherwise, it will transition to the requires_action status and + # suggest additional actions via next_action. If setup fails, + # the SetupIntent will transition to the + # requires_payment_method status or the canceled status if the + # confirmation limit is reached. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#97 + def confirm(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a SetupIntent object. + # + # After you create the SetupIntent, attach a payment method and [confirm](https://stripe.com/docs/api/setup_intents/confirm) + # it to collect any required permissions to charge the payment method later. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#110 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of SetupIntents. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#115 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/setup_intent.rb#32 + def object_name; end + + # Updates a SetupIntent object. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#120 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Verifies microdeposits on a SetupIntent object. + # + # source://stripe//lib/stripe/resources/setup_intent.rb#140 + def verify_microdeposits(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/setup_intent.rb#31 +Stripe::SetupIntent::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Shipping rates describe the price of shipping presented to your customers and +# applied to a purchase. For more information, see [Charge for shipping](https://stripe.com/docs/payments/during-payment/charge-shipping). +# +# source://stripe//lib/stripe/resources/shipping_rate.rb#7 +class Stripe::ShippingRate < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a new shipping rate object. + # + # source://stripe//lib/stripe/resources/shipping_rate.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your shipping rates. + # + # source://stripe//lib/stripe/resources/shipping_rate.rb#23 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/shipping_rate.rb#13 + def object_name; end + + # Updates an existing shipping rate object. + # + # source://stripe//lib/stripe/resources/shipping_rate.rb#28 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/shipping_rate.rb#12 +Stripe::ShippingRate::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#5 +module Stripe::Sigma; end + +# If you have [scheduled a Sigma query](https://stripe.com/docs/sigma/scheduled-queries), you'll +# receive a `sigma.scheduled_query_run.created` webhook each time the query +# runs. The webhook contains a `ScheduledQueryRun` object, which you can use to +# retrieve the query results. +# +# source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#10 +class Stripe::Sigma::ScheduledQueryRun < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Returns a list of scheduled query runs. + # + # source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#19 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#14 + def object_name; end + + # source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#28 + def resource_url; end + end +end + +# source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#13 +Stripe::Sigma::ScheduledQueryRun::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# SignatureVerificationError is raised when the signature verification for a +# webhook fails +# +# source://stripe//lib/stripe/errors.rb#111 +class Stripe::SignatureVerificationError < ::Stripe::StripeError + # @return [SignatureVerificationError] a new instance of SignatureVerificationError + # + # source://stripe//lib/stripe/errors.rb#114 + def initialize(message, sig_header, http_body: T.unsafe(nil)); end + + # Returns the value of attribute sig_header. + # + # source://stripe//lib/stripe/errors.rb#112 + def sig_header; end + + # Sets the attribute sig_header + # + # @param value the value to set the attribute sig_header to. + # + # source://stripe//lib/stripe/errors.rb#112 + def sig_header=(_arg0); end +end + +# source://stripe//lib/stripe/singleton_api_resource.rb#4 +class Stripe::SingletonAPIResource < ::Stripe::APIResource + # source://stripe//lib/stripe/singleton_api_resource.rb#16 + def resource_url; end + + class << self + # source://stripe//lib/stripe/singleton_api_resource.rb#5 + def resource_url; end + + # source://stripe//lib/stripe/singleton_api_resource.rb#20 + def retrieve(params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + end +end + +# `Source` objects allow you to accept a variety of payment methods. They +# represent a customer's payment instrument, and can be used with the Stripe API +# just like a `Card` object: once chargeable, they can be charged, or can be +# attached to customers. +# +# Stripe doesn't recommend using the deprecated [Sources API](https://stripe.com/docs/api/sources). +# We recommend that you adopt the [PaymentMethods API](https://stripe.com/docs/api/payment_methods). +# This newer API provides access to our latest features and payment method types. +# +# Related guides: [Sources API](https://stripe.com/docs/sources) and [Sources & Customers](https://stripe.com/docs/sources/customers). +# +# source://stripe//lib/stripe/resources/source.rb#15 +class Stripe::Source < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Save::ClassMethods + extend ::Gem::Deprecate + + # source://stripe//lib/stripe/resources/source.rb#77 + def _deprecated_source_transactions(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/source.rb#64 + def detach(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + def source_transactions(*args, **_arg1, &block); end + + # Verify a given source. + # + # source://stripe//lib/stripe/resources/source.rb#45 + def verify(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new source object. + # + # source://stripe//lib/stripe/resources/source.rb#28 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_source_transactions(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/source.rb#21 + def object_name; end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_source_transaction(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def source_transactions_url(id, nested_id = T.unsafe(nil)); end + + # Updates the specified source by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # This request accepts the metadata and owner as arguments. It is also possible to update type specific information for selected payment methods. Please refer to our [payment method guides](https://stripe.com/docs/sources) for more detail. + # + # source://stripe//lib/stripe/resources/source.rb#35 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Verify a given source. + # + # source://stripe//lib/stripe/resources/source.rb#55 + def verify(source, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/source.rb#20 +Stripe::Source::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Some payment methods have no required amount that a customer must send. +# Customers can be instructed to send any amount, and it can be made up of +# multiple transactions. As such, sources can have multiple associated +# transactions. +# +# source://stripe//lib/stripe/resources/source_transaction.rb#9 +class Stripe::SourceTransaction < ::Stripe::StripeObject + class << self + # source://stripe//lib/stripe/resources/source_transaction.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/source_transaction.rb#10 +Stripe::SourceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# StripeClient executes requests against the Stripe API and allows a user to +# recover both a resource a call returns as well as a response object that +# contains information on the HTTP call. +# +# source://stripe//lib/stripe/stripe_client.rb#9 +class Stripe::StripeClient + extend ::Gem::Deprecate + + # Initializes a new StripeClient + # + # @return [StripeClient] a new instance of StripeClient + # + # source://stripe//lib/stripe/stripe_client.rb#17 + def initialize(config_arg = T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_client.rb#182 + def _deprecated_connection_manager; end + + # source://stripe//lib/stripe/stripe_client.rb#194 + def _deprecated_request; end + + # Returns the value of attribute config. + # + # source://stripe//lib/stripe/stripe_client.rb#44 + def config; end + + # Gets the connection manager in use for the current `StripeClient`. + # + # This method is DEPRECATED and for backwards compatibility only. + def connection_manager(*args, **_arg1, &block); end + + # source://stripe//lib/stripe/stripe_client.rb#219 + def execute_request(method, path, api_base: T.unsafe(nil), api_key: T.unsafe(nil), headers: T.unsafe(nil), params: T.unsafe(nil), usage: T.unsafe(nil)); end + + # Executes a request and returns the body as a stream instead of converting + # it to a StripeObject. This should be used for any request where we expect + # an arbitrary binary response. + # + # A `read_body_chunk` block can be passed, which will be called repeatedly + # with the body chunks read from the socket. + # + # If a block is passed, a StripeHeadersOnlyResponse is returned as the + # block is expected to do all the necessary body processing. If no block is + # passed, then a StripeStreamResponse is returned containing an IO stream + # with the response body. + # + # source://stripe//lib/stripe/stripe_client.rb#250 + def execute_request_stream(method, path, api_base: T.unsafe(nil), api_key: T.unsafe(nil), usage: T.unsafe(nil), headers: T.unsafe(nil), params: T.unsafe(nil), &read_body_chunk_block); end + + # @return [Boolean] + # + # source://stripe//lib/stripe/stripe_client.rb#277 + def last_response_has_key?(object_id); end + + # Returns the value of attribute options. + # + # source://stripe//lib/stripe/stripe_client.rb#44 + def options; end + + # Executes the API call within the given block. Usage looks like: + # + # client = StripeClient.new + # charge, resp = client.request { Charge.create } + def request(*args, **_arg1, &block); end + + # source://stripe//lib/stripe/stripe_client.rb#271 + def store_last_response(object_id, resp); end + + private + + # source://stripe//lib/stripe/stripe_client.rb#515 + def api_url(url = T.unsafe(nil), api_base = T.unsafe(nil)); end + + # @raise [AuthenticationError] + # + # source://stripe//lib/stripe/stripe_client.rb#519 + def check_api_key!(api_key); end + + # Encodes a set of body parameters using multipart if `Content-Type` is set + # for that, or standard form-encoding otherwise. Returns the encoded body + # and a version of the encoded body that's safe to be logged. + # + # source://stripe//lib/stripe/stripe_client.rb#539 + def encode_body(body_params, headers); end + + # @raise [ArgumentError] + # + # source://stripe//lib/stripe/stripe_client.rb#438 + def execute_request_internal(method, path, api_base, api_key, headers, params, usage, &read_body_chunk_block); end + + # source://stripe//lib/stripe/stripe_client.rb#572 + def execute_request_with_rescues(api_base, headers, usage, context); end + + # Formats a plugin "app info" hash into a string that we can tack onto the + # end of a User-Agent string where it'll be fairly prominent in places like + # the Dashboard. Note that this formatting has been implemented to match + # other libraries, and shouldn't be changed without universal consensus. + # + # source://stripe//lib/stripe/stripe_client.rb#699 + def format_app_info(info); end + + # source://stripe//lib/stripe/stripe_client.rb#689 + def general_api_error(status, body); end + + # source://stripe//lib/stripe/stripe_client.rb#706 + def handle_error_response(http_resp, context); end + + # @raise [APIConnectionError] + # + # source://stripe//lib/stripe/stripe_client.rb#834 + def handle_network_error(error, context, num_retries, api_base = T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_client.rb#901 + def log_request(context, num_retries); end + + # source://stripe//lib/stripe/stripe_client.rb#920 + def log_response(context, request_start, status, body, resp); end + + # source://stripe//lib/stripe/stripe_client.rb#951 + def log_response_error(context, request_start, error); end + + # Works around an edge case where we end up with both query parameters from + # parameteers and query parameters that were appended onto the end of the + # given path. + # + # Decode any parameters that were added onto the end of a path and add them + # to a unified query parameter hash so that all parameters end up in one + # place and all of them are correctly included in the final request. + # + # source://stripe//lib/stripe/stripe_client.rb#733 + def merge_query_params(query_params, path); end + + # source://stripe//lib/stripe/stripe_client.rb#646 + def notify_request_begin(context); end + + # source://stripe//lib/stripe/stripe_client.rb#661 + def notify_request_end(context, duration, http_status, num_retries, user_data, resp, headers); end + + # source://stripe//lib/stripe/stripe_client.rb#860 + def request_headers(api_key, method); end + + # source://stripe//lib/stripe/stripe_client.rb#568 + def should_handle_as_error(http_status); end + + # source://stripe//lib/stripe/stripe_client.rb#748 + def specific_api_error(resp, error_data, context); end + + # Attempts to look at a response's error code and return an OAuth error if + # one matches. Will return `nil` if the code isn't recognized. + # + # source://stripe//lib/stripe/stripe_client.rb#798 + def specific_oauth_error(resp, error_code, context); end + + class << self + # Gets a currently active `StripeClient`. Set for the current thread when + # `StripeClient#request` is being run so that API operations being executed + # inside of that block can find the currently active client. It's reset to + # the original value (hopefully `nil`) after the block ends. + # + # For internal use only. Does not provide a stable API and may be broken + # with future non-major changes. + # + # source://stripe//lib/stripe/stripe_client.rb#53 + def active_client; end + + # Finishes any active connections by closing their TCP connection and + # clears them from internal tracking in all connection managers across all + # threads. + # + # If passed a `config` object, only clear connection managers for that + # particular configuration. + # + # For internal use only. Does not provide a stable API and may be broken + # with future non-major changes. + # + # source://stripe//lib/stripe/stripe_client.rb#66 + def clear_all_connection_managers(config: T.unsafe(nil)); end + + # Access data stored for `StripeClient` within the thread's current + # context. Returns `ThreadContext`. + # + # For internal use only. Does not provide a stable API and may be broken + # with future non-major changes. + # + # source://stripe//lib/stripe/stripe_client.rb#386 + def current_thread_context; end + + # A default client for the current thread. + # + # source://stripe//lib/stripe/stripe_client.rb#95 + def default_client; end + + # A default connection manager for the current thread scoped to the + # configuration object that may be provided. + # + # source://stripe//lib/stripe/stripe_client.rb#101 + def default_connection_manager(config = T.unsafe(nil)); end + + # Garbage collects connection managers that haven't been used in some time, + # with the idea being that we want to remove old connection managers that + # belong to dead threads and the like. + # + # Prefixed with `maybe_` because garbage collection will only run + # periodically so that we're not constantly engaged in busy work. If + # connection managers live a little passed their useful age it's not + # harmful, so it's not necessary to get them right away. + # + # For testability, returns `nil` if it didn't run and the number of + # connection managers that were garbage collected otherwise. + # + # IMPORTANT: This method is not thread-safe and expects to be called inside + # a lock on `@thread_contexts_with_connection_managers_mutex`. + # + # For internal use only. Does not provide a stable API and may be broken + # with future non-major changes. + # + # source://stripe//lib/stripe/stripe_client.rb#407 + def maybe_gc_connection_managers; end + + # Checks if an error is a problem that we should retry on. This includes + # both socket errors that may represent an intermittent problem and some + # special HTTP statuses. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/stripe_client.rb#117 + def should_retry?(error, num_retries:, config: T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_client.rb#162 + def sleep_time(num_retries, config: T.unsafe(nil)); end + end +end + +# Time (in seconds) that a connection manager has not been used before it's +# eligible for garbage collection. +# +# source://stripe//lib/stripe/stripe_client.rb#287 +Stripe::StripeClient::CONNECTION_MANAGER_GC_LAST_USED_EXPIRY = T.let(T.unsafe(nil), Integer) + +# How often to check (in seconds) for connection managers that haven't been +# used in a long time and which should be garbage collected. +# +# source://stripe//lib/stripe/stripe_client.rb#291 +Stripe::StripeClient::CONNECTION_MANAGER_GC_PERIOD = T.let(T.unsafe(nil), Integer) + +# source://stripe//lib/stripe/stripe_client.rb#293 +Stripe::StripeClient::ERROR_MESSAGE_CONNECTION = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/stripe_client.rb#298 +Stripe::StripeClient::ERROR_MESSAGE_SSL = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/stripe_client.rb#311 +Stripe::StripeClient::ERROR_MESSAGE_TIMEOUT_CONNECT = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/stripe_client.rb#316 +Stripe::StripeClient::ERROR_MESSAGE_TIMEOUT_READ = T.let(T.unsafe(nil), String) + +# Common error suffix sared by both connect and read timeout messages. +# +# source://stripe//lib/stripe/stripe_client.rb#305 +Stripe::StripeClient::ERROR_MESSAGE_TIMEOUT_SUFFIX = T.let(T.unsafe(nil), String) + +# Maps types of exceptions that we're likely to see during a network +# request to more user-friendly messages that we put in front of people. +# The original error message is also appended onto the final exception for +# full transparency. +# +# source://stripe//lib/stripe/stripe_client.rb#325 +Stripe::StripeClient::NETWORK_ERROR_MESSAGES_MAP = T.let(T.unsafe(nil), Hash) + +# RequestLogContext stores information about a request that's begin made so +# that we can log certain information. It's useful because it means that we +# don't have to pass around as many parameters. +# +# source://stripe//lib/stripe/stripe_client.rb#965 +class Stripe::StripeClient::RequestLogContext + # Returns the value of attribute account. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def account; end + + # Sets the attribute account + # + # @param value the value to set the attribute account to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def account=(_arg0); end + + # Returns the value of attribute api_key. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def api_key; end + + # Sets the attribute api_key + # + # @param value the value to set the attribute api_key to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def api_key=(_arg0); end + + # Returns the value of attribute api_version. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def api_version; end + + # Sets the attribute api_version + # + # @param value the value to set the attribute api_version to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def api_version=(_arg0); end + + # Returns the value of attribute body. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def body; end + + # Sets the attribute body + # + # @param value the value to set the attribute body to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def body=(_arg0); end + + # The idea with this method is that we might want to update some of + # context information because a response that we've received from the API + # contains information that's more authoritative than what we started + # with for a request. For example, we should trust whatever came back in + # a `Stripe-Version` header beyond what configuration information that we + # might have had available. + # + # source://stripe//lib/stripe/stripe_client.rb#974 + def dup_from_response_headers(headers); end + + # Returns the value of attribute idempotency_key. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def idempotency_key; end + + # Sets the attribute idempotency_key + # + # @param value the value to set the attribute idempotency_key to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def idempotency_key=(_arg0); end + + # Returns the value of attribute method. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def method; end + + # Sets the attribute method + # + # @param value the value to set the attribute method to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def method=(_arg0); end + + # Returns the value of attribute path. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def path; end + + # Sets the attribute path + # + # @param value the value to set the attribute path to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def path=(_arg0); end + + # Returns the value of attribute query. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def query; end + + # Sets the attribute query + # + # @param value the value to set the attribute query to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def query=(_arg0); end + + # Returns the value of attribute request_id. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def request_id; end + + # Sets the attribute request_id + # + # @param value the value to set the attribute request_id to. + # + # source://stripe//lib/stripe/stripe_client.rb#966 + def request_id=(_arg0); end +end + +# StripeRequestMetrics tracks metadata to be reported to stripe for metrics +# collection +# +# source://stripe//lib/stripe/stripe_client.rb#1043 +class Stripe::StripeClient::StripeRequestMetrics + # @return [StripeRequestMetrics] a new instance of StripeRequestMetrics + # + # source://stripe//lib/stripe/stripe_client.rb#1053 + def initialize(request_id, request_duration_ms, usage: T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_client.rb#1059 + def payload; end + + # Request duration in milliseconds + # + # source://stripe//lib/stripe/stripe_client.rb#1048 + def request_duration_ms; end + + # Request duration in milliseconds + # + # source://stripe//lib/stripe/stripe_client.rb#1048 + def request_duration_ms=(_arg0); end + + # The Stripe request ID of the response. + # + # source://stripe//lib/stripe/stripe_client.rb#1045 + def request_id; end + + # The Stripe request ID of the response. + # + # source://stripe//lib/stripe/stripe_client.rb#1045 + def request_id=(_arg0); end + + # list of names of tracked behaviors associated with this request + # + # source://stripe//lib/stripe/stripe_client.rb#1051 + def usage; end + + # list of names of tracked behaviors associated with this request + # + # source://stripe//lib/stripe/stripe_client.rb#1051 + def usage=(_arg0); end +end + +# SystemProfiler extracts information about the system that we're running +# in so that we can generate a rich user agent header to help debug +# integrations. +# +# source://stripe//lib/stripe/stripe_client.rb#987 +class Stripe::StripeClient::SystemProfiler + # @return [SystemProfiler] a new instance of SystemProfiler + # + # source://stripe//lib/stripe/stripe_client.rb#1019 + def initialize; end + + # source://stripe//lib/stripe/stripe_client.rb#1023 + def user_agent; end + + class << self + # source://stripe//lib/stripe/stripe_client.rb#988 + def uname; end + + # source://stripe//lib/stripe/stripe_client.rb#1003 + def uname_from_system; end + + # source://stripe//lib/stripe/stripe_client.rb#1011 + def uname_from_system_ver; end + end +end + +# A record representing any data that `StripeClient` puts into +# `Thread.current`. Making it a class likes this gives us a little extra +# type safety and lets us document what each field does. +# +# For internal use only. Does not provide a stable API and may be broken +# with future non-major changes. +# +# source://stripe//lib/stripe/stripe_client.rb#346 +class Stripe::StripeClient::ThreadContext + # A `StripeClient` that's been flagged as currently active within a + # thread by `StripeClient#request`. A client stays active until the + # completion of the request block. + # + # source://stripe//lib/stripe/stripe_client.rb#350 + def active_client; end + + # A `StripeClient` that's been flagged as currently active within a + # thread by `StripeClient#request`. A client stays active until the + # completion of the request block. + # + # source://stripe//lib/stripe/stripe_client.rb#350 + def active_client=(_arg0); end + + # A default `StripeClient` object for the thread. Used in all cases where + # the user hasn't specified their own. + # + # source://stripe//lib/stripe/stripe_client.rb#354 + def default_client; end + + # A default `StripeClient` object for the thread. Used in all cases where + # the user hasn't specified their own. + # + # source://stripe//lib/stripe/stripe_client.rb#354 + def default_client=(_arg0); end + + # A map of connection managers for the thread. Normally shared between + # all `StripeClient` objects on a particular thread, and created so as to + # minimize the number of open connections that an application needs. + # + # source://stripe//lib/stripe/stripe_client.rb#372 + def default_connection_managers; end + + # A temporary map of object IDs to responses from last executed API + # calls. Used to return a responses from calls to `StripeClient#request`. + # + # Stored in the thread data to make the use of a single `StripeClient` + # object safe across multiple threads. Stored as a map so that multiple + # `StripeClient` objects can run concurrently on the same thread. + # + # Responses are only left in as long as they're needed, which means + # they're removed as soon as a call leaves `StripeClient#request`, and + # because that's wrapped in an `ensure` block, they should never leave + # garbage in `Thread.current`. + # + # source://stripe//lib/stripe/stripe_client.rb#367 + def last_responses; end + + # A temporary map of object IDs to responses from last executed API + # calls. Used to return a responses from calls to `StripeClient#request`. + # + # Stored in the thread data to make the use of a single `StripeClient` + # object safe across multiple threads. Stored as a map so that multiple + # `StripeClient` objects can run concurrently on the same thread. + # + # Responses are only left in as long as they're needed, which means + # they're removed as soon as a call leaves `StripeClient#request`, and + # because that's wrapped in an `ensure` block, they should never leave + # garbage in `Thread.current`. + # + # source://stripe//lib/stripe/stripe_client.rb#367 + def last_responses=(_arg0); end + + # source://stripe//lib/stripe/stripe_client.rb#376 + def reset_connection_managers; end +end + +# Configurable options: +# +# =ca_bundle_path= +# The location of a file containing a bundle of CA certificates. By default +# the library will use an included bundle that can successfully validate +# Stripe certificates. +# +# =log_level= +# When set prompts the library to log some extra information to $stdout and +# $stderr about what it's doing. For example, it'll produce information about +# requests, responses, and errors that are received. Valid log levels are +# `debug` and `info`, with `debug` being a little more verbose in places. +# +# Use of this configuration is only useful when `.logger` is _not_ set. When +# it is, the decision what levels to print is entirely deferred to the logger. +# +# =logger= +# The logger should support the same interface as the `Logger` class that's +# part of Ruby's standard library (hint, anything in `Rails.logger` will +# likely be suitable). +# +# If `.logger` is set, the value of `.log_level` is ignored. The decision on +# what levels to print is entirely deferred to the logger. +# +# source://stripe//lib/stripe/stripe_configuration.rb#27 +class Stripe::StripeConfiguration + # @return [StripeConfiguration] a new instance of StripeConfiguration + # + # source://stripe//lib/stripe/stripe_configuration.rb#51 + def initialize; end + + # Returns the value of attribute api_base. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def api_base; end + + # source://stripe//lib/stripe/stripe_configuration.rb#139 + def api_base=(api_base); end + + # Returns the value of attribute api_key. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def api_key; end + + # Sets the attribute api_key + # + # @param value the value to set the attribute api_key to. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def api_key=(_arg0); end + + # Returns the value of attribute api_version. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def api_version; end + + # Sets the attribute api_version + # + # @param value the value to set the attribute api_version to. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def api_version=(_arg0); end + + # Returns the value of attribute ca_bundle_path. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def ca_bundle_path; end + + # source://stripe//lib/stripe/stripe_configuration.rb#144 + def ca_bundle_path=(path); end + + # A certificate store initialized from the the bundle in #ca_bundle_path and + # which is used to validate TLS on every request. + # + # This was added to the give the gem "pseudo thread safety" in that it seems + # when initiating many parallel requests marshaling the certificate store is + # the most likely point of failure (see issue #382). Any program attempting + # to leverage this pseudo safety should make a call to this method (i.e. + # `Stripe.ca_store`) in their initialization code because it marshals lazily + # and is itself not thread safe. + # + # source://stripe//lib/stripe/stripe_configuration.rb#162 + def ca_store; end + + # Returns the value of attribute client_id. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def client_id; end + + # Sets the attribute client_id + # + # @param value the value to set the attribute client_id to. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def client_id=(_arg0); end + + # Returns the value of attribute connect_base. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def connect_base; end + + # source://stripe//lib/stripe/stripe_configuration.rb#134 + def connect_base=(connect_base); end + + # Returns the value of attribute enable_telemetry. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def enable_telemetry; end + + # Sets the attribute enable_telemetry + # + # @param value the value to set the attribute enable_telemetry to. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def enable_telemetry=(_arg0); end + + # @return [Boolean] + # + # source://stripe//lib/stripe/stripe_configuration.rb#170 + def enable_telemetry?; end + + # Returns the value of attribute initial_network_retry_delay. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def initial_network_retry_delay; end + + # source://stripe//lib/stripe/stripe_configuration.rb#98 + def initial_network_retry_delay=(val); end + + # Generates a deterministic key to identify configuration objects with + # identical configuration values. + # + # source://stripe//lib/stripe/stripe_configuration.rb#176 + def key; end + + # Returns the value of attribute log_level. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def log_level; end + + # source://stripe//lib/stripe/stripe_configuration.rb#70 + def log_level=(val); end + + # Returns the value of attribute logger. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def logger; end + + # Sets the attribute logger + # + # @param value the value to set the attribute logger to. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def logger=(_arg0); end + + # Returns the value of attribute max_network_retries. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def max_network_retries; end + + # source://stripe//lib/stripe/stripe_configuration.rb#90 + def max_network_retries=(val); end + + # Returns the value of attribute max_network_retry_delay. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def max_network_retry_delay; end + + # source://stripe//lib/stripe/stripe_configuration.rb#94 + def max_network_retry_delay=(val); end + + # Returns the value of attribute open_timeout. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def open_timeout; end + + # source://stripe//lib/stripe/stripe_configuration.rb#102 + def open_timeout=(open_timeout); end + + # Returns the value of attribute proxy. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def proxy; end + + # source://stripe//lib/stripe/stripe_configuration.rb#119 + def proxy=(proxy); end + + # Returns the value of attribute read_timeout. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def read_timeout; end + + # source://stripe//lib/stripe/stripe_configuration.rb#107 + def read_timeout=(read_timeout); end + + # Create a new config based off an existing one. This is useful when the + # caller wants to override the global configuration + # + # source://stripe//lib/stripe/stripe_configuration.rb#43 + def reverse_duplicate_merge(hash); end + + # Returns the value of attribute stripe_account. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def stripe_account; end + + # Sets the attribute stripe_account + # + # @param value the value to set the attribute stripe_account to. + # + # source://stripe//lib/stripe/stripe_configuration.rb#28 + def stripe_account=(_arg0); end + + # Returns the value of attribute uploads_base. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def uploads_base; end + + # source://stripe//lib/stripe/stripe_configuration.rb#129 + def uploads_base=(uploads_base); end + + # Returns the value of attribute verify_ssl_certs. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def verify_ssl_certs; end + + # source://stripe//lib/stripe/stripe_configuration.rb#124 + def verify_ssl_certs=(verify_ssl_certs); end + + # Returns the value of attribute write_timeout. + # + # source://stripe//lib/stripe/stripe_configuration.rb#30 + def write_timeout; end + + # @raise [NotImplementedError] + # + # source://stripe//lib/stripe/stripe_configuration.rb#112 + def write_timeout=(write_timeout); end + + class << self + # source://stripe//lib/stripe/stripe_configuration.rb#35 + def setup; end + end +end + +# StripeError is the base error from which all other more specific Stripe +# errors derive. +# +# source://stripe//lib/stripe/errors.rb#6 +class Stripe::StripeError < ::StandardError + # Initializes a StripeError. + # + # @return [StripeError] a new instance of StripeError + # + # source://stripe//lib/stripe/errors.rb#14 + def initialize(message = T.unsafe(nil), http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil), code: T.unsafe(nil)); end + + # Returns the value of attribute code. + # + # source://stripe//lib/stripe/errors.rb#7 + def code; end + + # source://stripe//lib/stripe/errors.rb#27 + def construct_error_object; end + + # Returns the value of attribute error. + # + # source://stripe//lib/stripe/errors.rb#7 + def error; end + + # Returns the value of attribute http_body. + # + # source://stripe//lib/stripe/errors.rb#7 + def http_body; end + + # Returns the value of attribute http_headers. + # + # source://stripe//lib/stripe/errors.rb#7 + def http_headers; end + + # Returns the value of attribute http_status. + # + # source://stripe//lib/stripe/errors.rb#7 + def http_status; end + + # Whether the error was the result of an idempotent replay, meaning that it + # originally occurred on a previous request and is being replayed back + # because the user sent the same idempotency key for this one. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/errors.rb#36 + def idempotent_replayed?; end + + # Returns the value of attribute json_body. + # + # source://stripe//lib/stripe/errors.rb#7 + def json_body; end + + # Returns the value of attribute message. + # + # source://stripe//lib/stripe/errors.rb#7 + def message; end + + # Returns the value of attribute request_id. + # + # source://stripe//lib/stripe/errors.rb#7 + def request_id; end + + # Response contains a StripeResponse object that has some basic information + # about the response that conveyed the error. + # + # source://stripe//lib/stripe/errors.rb#11 + def response; end + + # Response contains a StripeResponse object that has some basic information + # about the response that conveyed the error. + # + # source://stripe//lib/stripe/errors.rb#11 + def response=(_arg0); end + + # source://stripe//lib/stripe/errors.rb#40 + def to_s; end +end + +# StripeHeadersOnlyResponse includes only header-related vitals of the +# response. This is used for streaming requests where the response was read +# directly in a block and we explicitly don't want to store the body of the +# response in memory. +# +# source://stripe//lib/stripe/stripe_response.rb#97 +class Stripe::StripeHeadersOnlyResponse + include ::Stripe::StripeResponseBase + + class << self + # Initializes a StripeHeadersOnlyResponse object from a + # Net::HTTP::HTTPResponse object. + # + # source://stripe//lib/stripe/stripe_response.rb#102 + def from_net_http(http_resp); end + end +end + +# source://stripe//lib/stripe/stripe_object.rb#4 +class Stripe::StripeObject + include ::Enumerable + + # @return [StripeObject] a new instance of StripeObject + # + # source://stripe//lib/stripe/stripe_object.rb#75 + def initialize(id = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Determines the equality of two Stripe objects. Stripe objects are + # considered to be equal if they have the same set of values and each one + # of those values is the same. + # + # source://stripe//lib/stripe/stripe_object.rb#98 + def ==(other); end + + # source://stripe//lib/stripe/stripe_object.rb#160 + def [](key); end + + # source://stripe//lib/stripe/stripe_object.rb#164 + def []=(key, value); end + + # source://stripe//lib/stripe/stripe_object.rb#181 + def as_json(*opts); end + + # Indicates whether or not the resource has been deleted on the server. + # Note that some, but not all, resources can indicate whether they have + # been deleted. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/stripe_object.rb#119 + def deleted?; end + + # Sets all keys within the StripeObject as unsaved so that they will be + # included with an update when #serialize_params is called. This method is + # also recursive, so any StripeObjects contained as values or which are + # values in a tenant array are also marked as dirty. + # + # source://stripe//lib/stripe/stripe_object.rb#210 + def dirty!; end + + # source://stripe//lib/stripe/stripe_object.rb#202 + def each(&blk); end + + # Hash equality. As with `#==`, we consider two equivalent Stripe objects + # equal. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/stripe_object.rb#105 + def eql?(other); end + + # As with equality in `#==` and `#eql?`, we hash two Stripe objects to the + # same value if they're equivalent objects. + # + # source://stripe//lib/stripe/stripe_object.rb#112 + def hash; end + + # source://stripe//lib/stripe/stripe_object.rb#127 + def inspect; end + + # source://stripe//lib/stripe/stripe_object.rb#168 + def keys; end + + # Returns the value of attribute last_response. + # + # source://stripe//lib/stripe/stripe_object.rb#7 + def last_response; end + + # Implements custom encoding for Ruby's Marshal. The data produced by this + # method should be comprehendable by #marshal_load. + # + # This allows us to remove certain features that cannot or should not be + # serialized. + # + # source://stripe//lib/stripe/stripe_object.rb#222 + def marshal_dump; end + + # Implements custom decoding for Ruby's Marshal. Consumes data that's + # produced by #marshal_dump. + # + # source://stripe//lib/stripe/stripe_object.rb#233 + def marshal_load(data); end + + # source://stripe//lib/stripe/stripe_object.rb#239 + def serialize_params(options = T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_object.rb#185 + def to_hash; end + + # source://stripe//lib/stripe/stripe_object.rb#176 + def to_json(*_opts); end + + # source://stripe//lib/stripe/stripe_object.rb#123 + def to_s(*_args); end + + # Mass assigns attributes on the model. + # + # This is a version of +update_attributes+ that takes some extra options + # for internal use. + # + # ==== Attributes + # + # * +values+ - Hash of values to use to update the current attributes of + # the object. If you are on ruby 2.7 or higher make sure to wrap in curly + # braces to be ruby 3 compatible. + # * +opts+ - Options for +StripeObject+ like an API key that will be reused + # on subsequent API calls. + # + # ==== Options + # + # * +:dirty+ - Whether values should be initiated as "dirty" (unsaved) and + # which applies only to new StripeObjects being initiated under this + # StripeObject. Defaults to true. + # + # source://stripe//lib/stripe/stripe_object.rb#151 + def update_attributes(values, opts = T.unsafe(nil), dirty: T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_object.rb#172 + def values; end + + protected + + # source://stripe//lib/stripe/stripe_object.rb#334 + def add_accessors(keys, values); end + + # Re-initializes the object based on a hash of values (usually one that's + # come back from an API call). Adds or removes value accessors as necessary + # and updates the state of internal data. + # + # Protected on purpose! Please do not expose. + # + # ==== Options + # + # * +:values:+ Hash used to update accessors and values. + # * +:opts:+ Options for StripeObject like an API key. + # * +:partial:+ Indicates that the re-initialization should not attempt to + # remove accessors. + # + # source://stripe//lib/stripe/stripe_object.rb#430 + def initialize_from(values, opts, last_response = T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_object.rb#294 + def metaclass; end + + # Disabling the cop because it's confused by the fact that the methods are + # protected, but we do define `#respond_to_missing?` just below. Hopefully + # this is fixed in more recent Rubocop versions. + # + # source://stripe//lib/stripe/stripe_object.rb#373 + def method_missing(name, *args); end + + # source://stripe//lib/stripe/stripe_object.rb#298 + def remove_accessors(keys); end + + # @return [Boolean] + # + # source://stripe//lib/stripe/stripe_object.rb#414 + def respond_to_missing?(symbol, include_private = T.unsafe(nil)); end + + # source://stripe//lib/stripe/stripe_object.rb#464 + def serialize_params_value(value, original, unsaved, force, key: T.unsafe(nil)); end + + private + + # source://stripe//lib/stripe/stripe_object.rb#564 + def dirty_value!(value); end + + # Returns a hash of empty values for all the values that are in the given + # StripeObject. + # + # source://stripe//lib/stripe/stripe_object.rb#575 + def empty_values(obj); end + + class << self + # Sets the given parameter name to one which is known to be an additive + # object. + # + # Additive objects are subobjects in the API that don't have the same + # semantics as most subobjects, which are fully replaced when they're set. + # This is best illustrated by example. The `source` parameter sent when + # updating a subscription is *not* additive; if we set it: + # + # source[object]=card&source[number]=123 + # + # We expect the old `source` object to have been overwritten completely. If + # the previous source had an `address_state` key associated with it and we + # didn't send one this time, that value of `address_state` is gone. + # + # By contrast, additive objects are those that will have new data added to + # them while keeping any existing data in place. The only known case of its + # use is for `metadata`, but it could in theory be more general. As an + # example, say we have a `metadata` object that looks like this on the + # server side: + # + # metadata = { old: "old_value" } + # + # If we update the object with `metadata[new]=new_value`, the server side + # object now has *both* fields: + # + # metadata = { old: "old_value", new: "new_value" } + # + # This is okay in itself because usually users will want to treat it as + # additive: + # + # obj.metadata[:new] = "new_value" + # obj.save + # + # However, in other cases, they may want to replace the entire existing + # contents: + # + # obj.metadata = { new: "new_value" } + # obj.save + # + # This is where things get a little bit tricky because in order to clear + # any old keys that may have existed, we actually have to send an explicit + # empty string to the server. So the operation above would have to send + # this form to get the intended behavior: + # + # metadata[old]=&metadata[new]=new_value + # + # This method allows us to track which parameters are considered additive, + # and lets us behave correctly where appropriate when serializing + # parameters to be sent. + # + # source://stripe//lib/stripe/stripe_object.rb#63 + def additive_object_param(name); end + + # Returns whether the given name is an additive object parameter. See + # `.additive_object_param` for details. + # + # @return [Boolean] + # + # source://stripe//lib/stripe/stripe_object.rb#70 + def additive_object_param?(name); end + + # source://stripe//lib/stripe/stripe_object.rb#88 + def construct_from(values, opts = T.unsafe(nil), last_response = T.unsafe(nil)); end + + # A protected field is one that doesn't get an accessor assigned to it + # (i.e. `obj.public = ...`) and one which is not allowed to be updated via + # the class level `Model.update(id, { ... })`. + # + # source://stripe//lib/stripe/stripe_object.rb#269 + def protected_fields; end + + private + + # Produces a deep copy of the given object including support for arrays, + # hashes, and StripeObjects. + # + # source://stripe//lib/stripe/stripe_object.rb#543 + def deep_copy(obj); end + end +end + +# When designing APIs, we now make a conscious effort server-side to avoid +# naming fields after important built-ins in various languages (e.g. class, +# method, etc.). +# +# However, a long time ago we made the mistake (either consciously or by +# accident) of initializing our `metadata` fields as instances of +# `StripeObject`, and metadata can have a wide range of different keys +# defined in it. This is somewhat a convenient in that it allows users to +# access data like `obj.metadata.my_field`, but is almost certainly not +# worth the cost. +# +# Naming metadata fields bad things like `class` causes `initialize_from` +# to produce strange results, so we ban known offenders here. +# +# In a future major version we should consider leaving `metadata` as a hash +# and forcing people to access it with `obj.metadata[:my_field]` because +# the potential for trouble is just too high. For now, reserve names. +# +# source://stripe//lib/stripe/stripe_object.rb#290 +Stripe::StripeObject::RESERVED_FIELD_NAMES = T.let(T.unsafe(nil), Array) + +# StripeResponse encapsulates some vitals of a response that came back from +# the Stripe API. +# +# source://stripe//lib/stripe/stripe_response.rb#68 +class Stripe::StripeResponse + include ::Stripe::StripeResponseBase + + # The data contained by the HTTP body of the response deserialized from + # JSON. + # + # source://stripe//lib/stripe/stripe_response.rb#72 + def data; end + + # The data contained by the HTTP body of the response deserialized from + # JSON. + # + # source://stripe//lib/stripe/stripe_response.rb#72 + def data=(_arg0); end + + # The raw HTTP body of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#75 + def http_body; end + + # The raw HTTP body of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#75 + def http_body=(_arg0); end + + class << self + # Initializes a StripeResponse object from a Net::HTTP::HTTPResponse + # object. + # + # source://stripe//lib/stripe/stripe_response.rb#79 + def from_net_http(http_resp); end + end +end + +# We have to alias StripeResponseHeaders to StripeResponse::Headers, as this +# class used to be embedded within StripeResponse and we want to be backwards +# compatible. +# +# source://stripe//lib/stripe/stripe_response.rb#91 +Stripe::StripeResponse::Headers = Stripe::StripeResponseHeaders + +# source://stripe//lib/stripe/stripe_response.rb#49 +module Stripe::StripeResponseBase + # A Hash of the HTTP headers of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#51 + def http_headers; end + + # A Hash of the HTTP headers of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#51 + def http_headers=(_arg0); end + + # The integer HTTP status code of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#54 + def http_status; end + + # The integer HTTP status code of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#54 + def http_status=(_arg0); end + + # The Stripe request ID of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#57 + def request_id; end + + # The Stripe request ID of the response. + # + # source://stripe//lib/stripe/stripe_response.rb#57 + def request_id=(_arg0); end + + class << self + # source://stripe//lib/stripe/stripe_response.rb#59 + def populate_for_net_http(resp, http_resp); end + end +end + +# Headers provides an access wrapper to an API response's header data. It +# mainly exists so that we don't need to expose the entire +# `Net::HTTPResponse` object while still getting some of its benefits like +# case-insensitive access to header names and flattening of header values. +# +# source://stripe//lib/stripe/stripe_response.rb#8 +class Stripe::StripeResponseHeaders + # `hash` is expected to be a hash mapping header names to arrays of + # header values. This is the default format generated by calling + # `#to_hash` on a `Net::HTTPResponse` object because headers can be + # repeated multiple times. Using `#[]` will collapse values down to just + # the first. + # + # @return [StripeResponseHeaders] a new instance of StripeResponseHeaders + # + # source://stripe//lib/stripe/stripe_response.rb#19 + def initialize(hash); end + + # source://stripe//lib/stripe/stripe_response.rb#42 + def [](name); end + + class << self + # Initializes a Headers object from a Net::HTTP::HTTPResponse object. + # + # source://stripe//lib/stripe/stripe_response.rb#10 + def from_net_http(resp); end + end +end + +# Subscriptions allow you to charge a customer on a recurring basis. +# +# Related guide: [Creating subscriptions](https://stripe.com/docs/billing/subscriptions/creating) +# +# source://stripe//lib/stripe/resources/subscription.rb#8 +class Stripe::Subscription < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Search + extend ::Stripe::APIOperations::Save::ClassMethods + + # Cancels a customer's subscription immediately. The customer will not be charged again for the subscription. + # + # Note, however, that any pending invoice items that you've created will still be charged for at the end of the period, unless manually [deleted](https://stripe.com/docs/api#delete_invoiceitem). If you've set the subscription to cancel at the end of the period, any pending prorations will also be left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations will be removed. + # + # By default, upon subscription cancellation, Stripe will stop automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all. + # + # source://stripe//lib/stripe/resources/subscription.rb#24 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Removes the currently applied discount on a subscription. + # + # source://stripe//lib/stripe/resources/subscription.rb#59 + def delete_discount(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date. + # + # source://stripe//lib/stripe/resources/subscription.rb#84 + def resume(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_resource.rb#45 + def source=(value); end + + class << self + # Cancels a customer's subscription immediately. The customer will not be charged again for the subscription. + # + # Note, however, that any pending invoice items that you've created will still be charged for at the end of the period, unless manually [deleted](https://stripe.com/docs/api#delete_invoiceitem). If you've set the subscription to cancel at the end of the period, any pending prorations will also be left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations will be removed. + # + # By default, upon subscription cancellation, Stripe will stop automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all. + # + # source://stripe//lib/stripe/resources/subscription.rb#38 + def cancel(subscription_exposed_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a new subscription on an existing customer. Each customer can have up to 500 active or scheduled subscriptions. + # + # When you create a subscription with collection_method=charge_automatically, the first invoice is finalized as part of the request. + # The payment_behavior parameter determines the exact behavior of the initial payment. + # + # To start subscriptions where the first invoice always begins in a draft status, use [subscription schedules](https://stripe.com/docs/billing/subscriptions/subscription-schedules#managing) instead. + # Schedules provide the flexibility to model more complex billing configurations that change over time. + # + # source://stripe//lib/stripe/resources/subscription.rb#54 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Removes the currently applied discount on a subscription. + # + # source://stripe//lib/stripe/resources/subscription.rb#69 + def delete_discount(subscription_exposed_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # By default, returns a list of subscriptions that have not been canceled. In order to list canceled subscriptions, specify status=canceled. + # + # source://stripe//lib/stripe/resources/subscription.rb#79 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/subscription.rb#15 + def object_name; end + + # Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date. + # + # source://stripe//lib/stripe/resources/subscription.rb#94 + def resume(subscription, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/subscription.rb#103 + def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/subscription.rb#112 + def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end + + # Updates an existing subscription to match the specified parameters. + # When changing prices or quantities, we optionally prorate the price we charge next month to make up for any price changes. + # To preview how the proration is calculated, use the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint. + # + # By default, we prorate subscription changes. For example, if a customer signs up on May 1 for a 100 price, they'll be billed 100 immediately. If on May 15 they switch to a 200 price, then on June 1 they'll be billed 250 (200 for a renewal of her subscription, plus a 50 prorating adjustment for half of the previous month's 100 difference). Similarly, a downgrade generates a credit that is applied to the next invoice. We also prorate when you make quantity changes. + # + # Switching prices does not normally change the billing date or generate an immediate charge unless: + # + # + # The billing interval is changed (for example, from monthly to yearly). + # The subscription moves from free to paid. + # A trial starts or ends. + # + # + # In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how [Stripe immediately attempts payment for subscription changes](https://stripe.com/billing/subscriptions/upgrade-downgrade#immediate-payment). + # + # If you want to charge for an upgrade immediately, pass proration_behavior as always_invoice to create prorations, automatically invoice the customer for those proration adjustments, and attempt to collect payment. If you pass create_prorations, the prorations are created but not automatically invoiced. If you want to bill the customer for the prorations before the subscription's renewal date, you need to manually [invoice the customer](https://stripe.com/docs/api/invoices/create). + # + # If you don't want to prorate, set the proration_behavior option to none. With this option, the customer is billed 100 on May 1 and 200 on June 1. Similarly, if you set proration_behavior to none when switching between different billing intervals (for example, from monthly to yearly), we don't generate any credits for the old subscription's unused time. We still reset the billing date and bill immediately for the new subscription. + # + # Updating the quantity on a subscription many times in an hour may result in [rate limiting. If you need to bill for a frequently changing quantity, consider integrating usage-based billing](https://stripe.com/docs/rate-limits) instead. + # + # source://stripe//lib/stripe/resources/subscription.rb#137 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/subscription.rb#14 +Stripe::Subscription::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Subscription items allow you to create customer subscriptions with more than +# one plan, making it easy to represent complex billing relationships. +# +# source://stripe//lib/stripe/resources/subscription_item.rb#7 +class Stripe::SubscriptionItem < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Save::ClassMethods + + # Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription. + # + # source://stripe//lib/stripe/resources/subscription_item.rb#45 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Adds a new item to an existing subscription. No existing items will be changed or replaced. + # + # source://stripe//lib/stripe/resources/subscription_item.rb#25 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_usage_record(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription. + # + # source://stripe//lib/stripe/resources/subscription_item.rb#35 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your subscription items for a given subscription. + # + # source://stripe//lib/stripe/resources/subscription_item.rb#55 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_usage_record_summaries(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/subscription_item.rb#15 + def object_name; end + + # Updates the plan or quantity of an item on a current subscription. + # + # source://stripe//lib/stripe/resources/subscription_item.rb#65 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def usage_record_summarys_url(id, nested_id = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def usage_records_url(id, nested_id = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/subscription_item.rb#14 +Stripe::SubscriptionItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A subscription schedule allows you to create and manage the lifecycle of a subscription by predefining expected changes. +# +# Related guide: [Subscription schedules](https://stripe.com/docs/billing/subscriptions/subscription-schedules) +# +# source://stripe//lib/stripe/resources/subscription_schedule.rb#8 +class Stripe::SubscriptionSchedule < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active. + # + # source://stripe//lib/stripe/resources/subscription_schedule.rb#19 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription's ID to the released_subscription property. + # + # source://stripe//lib/stripe/resources/subscription_schedule.rb#59 + def release(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active. + # + # source://stripe//lib/stripe/resources/subscription_schedule.rb#29 + def cancel(schedule, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions. + # + # source://stripe//lib/stripe/resources/subscription_schedule.rb#39 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Retrieves the list of your subscription schedules. + # + # source://stripe//lib/stripe/resources/subscription_schedule.rb#49 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/subscription_schedule.rb#14 + def object_name; end + + # Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription's ID to the released_subscription property. + # + # source://stripe//lib/stripe/resources/subscription_schedule.rb#69 + def release(schedule, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates an existing subscription schedule. + # + # source://stripe//lib/stripe/resources/subscription_schedule.rb#79 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/subscription_schedule.rb#13 +Stripe::SubscriptionSchedule::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/tax/calculation.rb#5 +module Stripe::Tax; end + +# A Tax Calculation allows you to calculate the tax to collect from your customer. +# +# Related guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom) +# +# source://stripe//lib/stripe/resources/tax/calculation.rb#9 +class Stripe::Tax::Calculation < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + # Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired. + # + # source://stripe//lib/stripe/resources/tax/calculation.rb#28 + def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Calculates tax based on the input and returns a Tax Calculation object. + # + # source://stripe//lib/stripe/resources/tax/calculation.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired. + # + # source://stripe//lib/stripe/resources/tax/calculation.rb#38 + def list_line_items(calculation, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/tax/calculation.rb#13 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/tax/calculation.rb#12 +Stripe::Tax::Calculation::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/tax/calculation_line_item.rb#6 +class Stripe::Tax::CalculationLineItem < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/tax/calculation_line_item.rb#8 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/tax/calculation_line_item.rb#7 +Stripe::Tax::CalculationLineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Tax `Registration` lets us know that your business is registered to collect tax on payments within a region, enabling you to [automatically collect tax](https://stripe.com/docs/tax). +# +# Stripe doesn't register on your behalf with the relevant authorities when you create a Tax `Registration` object. For more information on how to register to collect tax, see [our guide](https://stripe.com/docs/tax/registering). +# +# Related guide: [Using the Registrations API](https://stripe.com/docs/tax/registrations-api) +# +# source://stripe//lib/stripe/resources/tax/registration.rb#11 +class Stripe::Tax::Registration < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a new Tax Registration object. + # + # source://stripe//lib/stripe/resources/tax/registration.rb#22 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Tax Registration objects. + # + # source://stripe//lib/stripe/resources/tax/registration.rb#32 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/tax/registration.rb#17 + def object_name; end + + # Updates an existing Tax Registration object. + # + # A registration cannot be deleted after it has been created. If you wish to end a registration you may do so by setting expires_at. + # + # source://stripe//lib/stripe/resources/tax/registration.rb#44 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/tax/registration.rb#16 +Stripe::Tax::Registration::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# You can use Tax `Settings` to manage configurations used by Stripe Tax calculations. +# +# Related guide: [Using the Settings API](https://stripe.com/docs/tax/settings-api) +# +# source://stripe//lib/stripe/resources/tax/settings.rb#9 +class Stripe::Tax::Settings < ::Stripe::SingletonAPIResource + include ::Stripe::APIOperations::SingletonSave + extend ::Stripe::APIOperations::SingletonSave::ClassMethods + + class << self + # source://stripe//lib/stripe/resources/tax/settings.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/tax/settings.rb#11 +Stripe::Tax::Settings::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Tax Transaction records the tax collected from or refunded to your customer. +# +# Related guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom#tax-transaction) +# +# source://stripe//lib/stripe/resources/tax/transaction.rb#9 +class Stripe::Tax::Transaction < ::Stripe::APIResource + # Retrieves the line items of a committed standalone transaction as a collection. + # + # source://stripe//lib/stripe/resources/tax/transaction.rb#36 + def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days. + # + # source://stripe//lib/stripe/resources/tax/transaction.rb#16 + def create_from_calculation(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Partially or fully reverses a previously created Transaction. + # + # source://stripe//lib/stripe/resources/tax/transaction.rb#26 + def create_reversal(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Retrieves the line items of a committed standalone transaction as a collection. + # + # source://stripe//lib/stripe/resources/tax/transaction.rb#46 + def list_line_items(transaction, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/tax/transaction.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/tax/transaction.rb#10 +Stripe::Tax::Transaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/tax/transaction_line_item.rb#6 +class Stripe::Tax::TransactionLineItem < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/tax/transaction_line_item.rb#8 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/tax/transaction_line_item.rb#7 +Stripe::Tax::TransactionLineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# [Tax codes](https://stripe.com/docs/tax/tax-categories) classify goods and services for tax purposes. +# +# source://stripe//lib/stripe/resources/tax_code.rb#6 +class Stripe::TaxCode < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # A list of [all tax codes available](https://stripe.com/docs/tax/tax-categories) to add to Products in order to allow specific tax calculations. + # + # source://stripe//lib/stripe/resources/tax_code.rb#15 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/tax_code.rb#10 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/tax_code.rb#9 +Stripe::TaxCode::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# You can add one or multiple tax IDs to a [customer](https://stripe.com/docs/api/customers) or account. +# Customer and account tax IDs get displayed on related invoices and credit notes. +# +# Related guides: [Customer tax identification numbers](https://stripe.com/docs/billing/taxes/tax-ids), [Account tax IDs](https://stripe.com/docs/invoicing/connect#account-tax-ids) +# +# source://stripe//lib/stripe/resources/tax_id.rb#9 +class Stripe::TaxId < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + + # Deletes an existing account or customer tax_id object. + # + # source://stripe//lib/stripe/resources/tax_id.rb#35 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new account or customer tax_id object. + # + # source://stripe//lib/stripe/resources/tax_id.rb#20 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes an existing account or customer tax_id object. + # + # source://stripe//lib/stripe/resources/tax_id.rb#25 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of tax IDs. + # + # source://stripe//lib/stripe/resources/tax_id.rb#45 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/tax_id.rb#15 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/tax_id.rb#14 +Stripe::TaxId::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Tax rates can be applied to [invoices](https://stripe.com/docs/billing/invoices/tax-rates), [subscriptions](https://stripe.com/docs/billing/subscriptions/taxes) and [Checkout Sessions](https://stripe.com/docs/payments/checkout/set-up-a-subscription#tax-rates) to collect tax. +# +# Related guide: [Tax rates](https://stripe.com/docs/billing/taxes/tax-rates) +# +# source://stripe//lib/stripe/resources/tax_rate.rb#8 +class Stripe::TaxRate < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # Creates a new tax rate. + # + # source://stripe//lib/stripe/resources/tax_rate.rb#19 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first. + # + # source://stripe//lib/stripe/resources/tax_rate.rb#24 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/tax_rate.rb#14 + def object_name; end + + # Updates an existing tax rate. + # + # source://stripe//lib/stripe/resources/tax_rate.rb#29 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/tax_rate.rb#13 +Stripe::TaxRate::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/terminal/configuration.rb#5 +module Stripe::Terminal; end + +# A Configurations object represents how features should be configured for terminal readers. +# +# source://stripe//lib/stripe/resources/terminal/configuration.rb#7 +class Stripe::Terminal::Configuration < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Deletes a Configuration object. + # + # source://stripe//lib/stripe/resources/terminal/configuration.rb#39 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new Configuration object. + # + # source://stripe//lib/stripe/resources/terminal/configuration.rb#19 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a Configuration object. + # + # source://stripe//lib/stripe/resources/terminal/configuration.rb#29 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Configuration objects. + # + # source://stripe//lib/stripe/resources/terminal/configuration.rb#49 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/terminal/configuration.rb#14 + def object_name; end + + # Updates a new Configuration object. + # + # source://stripe//lib/stripe/resources/terminal/configuration.rb#59 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/terminal/configuration.rb#13 +Stripe::Terminal::Configuration::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Connection Token is used by the Stripe Terminal SDK to connect to a reader. +# +# Related guide: [Fleet management](https://stripe.com/docs/terminal/fleet/locations) +# +# source://stripe//lib/stripe/resources/terminal/connection_token.rb#9 +class Stripe::Terminal::ConnectionToken < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # To connect to a reader the Stripe Terminal SDK needs to retrieve a short-lived connection token from Stripe, proxied through your server. On your backend, add an endpoint that creates and returns a connection token. + # + # source://stripe//lib/stripe/resources/terminal/connection_token.rb#18 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/terminal/connection_token.rb#13 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/terminal/connection_token.rb#12 +Stripe::Terminal::ConnectionToken::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Location represents a grouping of readers. +# +# Related guide: [Fleet management](https://stripe.com/docs/terminal/fleet/locations) +# +# source://stripe//lib/stripe/resources/terminal/location.rb#9 +class Stripe::Terminal::Location < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Deletes a Location object. + # + # source://stripe//lib/stripe/resources/terminal/location.rb#42 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new Location object. + # For further details, including which address fields are required in each country, see the [Manage locations](https://stripe.com/docs/terminal/fleet/locations) guide. + # + # source://stripe//lib/stripe/resources/terminal/location.rb#22 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a Location object. + # + # source://stripe//lib/stripe/resources/terminal/location.rb#32 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Location objects. + # + # source://stripe//lib/stripe/resources/terminal/location.rb#52 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/terminal/location.rb#16 + def object_name; end + + # Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/terminal/location.rb#62 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/terminal/location.rb#15 +Stripe::Terminal::Location::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A Reader represents a physical device for accepting payment details. +# +# Related guide: [Connecting to a reader](https://stripe.com/docs/terminal/payments/connect-reader) +# +# source://stripe//lib/stripe/resources/terminal/reader.rb#9 +class Stripe::Terminal::Reader < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Cancels the current reader action. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#21 + def cancel_action(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a Reader object. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#61 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Initiates a payment flow on a Reader. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#81 + def process_payment_intent(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Initiates a setup intent flow on a Reader. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#101 + def process_setup_intent(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Initiates a refund on a Reader + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#121 + def refund_payment(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Sets reader display to show cart details. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#141 + def set_reader_display(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/terminal/reader.rb#170 + def test_helpers; end + + class << self + # Cancels the current reader action. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#31 + def cancel_action(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a new Reader object. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#41 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a Reader object. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#51 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of Reader objects. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#71 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/terminal/reader.rb#16 + def object_name; end + + # Initiates a payment flow on a Reader. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#91 + def process_payment_intent(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Initiates a setup intent flow on a Reader. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#111 + def process_setup_intent(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Initiates a refund on a Reader + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#131 + def refund_payment(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Sets reader display to show cart details. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#151 + def set_reader_display(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates a Reader object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#161 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/terminal/reader.rb#15 +Stripe::Terminal::Reader::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/terminal/reader.rb#174 +class Stripe::Terminal::Reader::TestHelpers < ::Stripe::APIResourceTestHelpers + # Presents a payment method on a simulated reader. Can be used to simulate accepting a payment, saving a card or refunding a transaction. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#191 + def present_payment_method(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Presents a payment method on a simulated reader. Can be used to simulate accepting a payment, saving a card or refunding a transaction. + # + # source://stripe//lib/stripe/resources/terminal/reader.rb#181 + def present_payment_method(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/terminal/reader.rb#176 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/terminal/reader.rb#175 +Stripe::Terminal::Reader::TestHelpers::RESOURCE_CLASS = Stripe::Terminal::Reader + +# source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#5 +module Stripe::TestHelpers; end + +# A test clock enables deterministic control over objects in testmode. With a test clock, you can create +# objects at a frozen time in the past or future, and advance to a specific future time to observe webhooks and state changes. After the clock advances, +# you can either validate the current state of your scenario (and test your assumptions), change the current state of your scenario (and test more complex scenarios), or keep advancing forward in time. +# +# source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#9 +class Stripe::TestHelpers::TestClock < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + + # Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready. + # + # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#20 + def advance(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a test clock. + # + # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#60 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready. + # + # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#30 + def advance(test_clock, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates a new test clock that can be attached to new customers and quotes. + # + # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#40 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Deletes a test clock. + # + # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#50 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your test clocks. + # + # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#70 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#15 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#14 +Stripe::TestHelpers::TestClock::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Tokenization is the process Stripe uses to collect sensitive card or bank +# account details, or personally identifiable information (PII), directly from +# your customers in a secure manner. A token representing this information is +# returned to your server to use. Use our +# [recommended payments integrations](https://stripe.com/docs/payments) to perform this process +# on the client-side. This guarantees that no sensitive card data touches your server, +# and allows your integration to operate in a PCI-compliant way. +# +# If you can't use client-side tokenization, you can also create tokens using +# the API with either your publishable or secret API key. If +# your integration uses this method, you're responsible for any PCI compliance +# that it might require, and you must keep your secret API key safe. Unlike with +# client-side tokenization, your customer's information isn't sent directly to +# Stripe, so we can't determine how it's handled or stored. +# +# You can't store or use tokens more than once. To store card or bank account +# information for later use, create [Customer](https://stripe.com/docs/api#customers) +# objects or [External accounts](https://stripe.com/api#external_accounts). +# [Radar](https://stripe.com/docs/radar), our integrated solution for automatic fraud protection, +# performs best with integrations that use client-side tokenization. +# +# source://stripe//lib/stripe/resources/token.rb#25 +class Stripe::Token < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + + class << self + # Creates a single-use token that represents a bank account's details. + # You can use this token with any API method in place of a bank account dictionary. You can only use this token once. To do so, attach it to a [connected account](https://stripe.com/docs/api#accounts) where [controller.requirement_collection](https://stripe.com/api/accounts/object#account_object-controller-requirement_collection) is application, which includes Custom accounts. + # + # source://stripe//lib/stripe/resources/token.rb#35 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/token.rb#29 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/token.rb#28 +Stripe::Token::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# To top up your Stripe balance, you create a top-up object. You can retrieve +# individual top-ups, as well as list all top-ups. Top-ups are identified by a +# unique, random ID. +# +# Related guide: [Topping up your platform account](https://stripe.com/docs/connect/top-ups) +# +# source://stripe//lib/stripe/resources/topup.rb#10 +class Stripe::Topup < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Cancels a top-up. Only pending top-ups can be canceled. + # + # source://stripe//lib/stripe/resources/topup.rb#21 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Cancels a top-up. Only pending top-ups can be canceled. + # + # source://stripe//lib/stripe/resources/topup.rb#31 + def cancel(topup, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Top up the balance of an account + # + # source://stripe//lib/stripe/resources/topup.rb#41 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of top-ups. + # + # source://stripe//lib/stripe/resources/topup.rb#46 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/topup.rb#16 + def object_name; end + + # Updates the metadata of a top-up. Other top-up details are not editable by design. + # + # source://stripe//lib/stripe/resources/topup.rb#51 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/topup.rb#15 +Stripe::Topup::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# A `Transfer` object is created when you move funds between Stripe accounts as +# part of Connect. +# +# Before April 6, 2017, transfers also represented movement of funds from a +# Stripe account to a card or bank account. This behavior has since been split +# out into a [Payout](https://stripe.com/docs/api#payout_object) object, with corresponding payout endpoints. For more +# information, read about the +# [transfer/payout split](https://stripe.com/docs/transfer-payout-split). +# +# Related guide: [Creating separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) +# +# source://stripe//lib/stripe/resources/transfer.rb#15 +class Stripe::Transfer < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::NestedResource + extend ::Stripe::APIOperations::Save::ClassMethods + + class << self + # To send funds from your Stripe account to a connected account, you create a new transfer object. Your [Stripe balance](https://stripe.com/docs/api#balance) must be able to cover the transfer amount, or you'll receive an “Insufficient Funds” error. + # + # source://stripe//lib/stripe/resources/transfer.rb#29 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#48 + def create_reversal(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first. + # + # source://stripe//lib/stripe/resources/transfer.rb#34 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#106 + def list_reversals(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/transfer.rb#22 + def object_name; end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#59 + def retrieve_reversal(id, nested_id, params_or_opts = T.unsafe(nil), definitely_opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 + def reversals_url(id, nested_id = T.unsafe(nil)); end + + # Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. + # + # This request accepts only metadata as an argument. + # + # source://stripe//lib/stripe/resources/transfer.rb#41 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/api_operations/nested_resource.rb#86 + def update_reversal(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/transfer.rb#21 +Stripe::Transfer::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#5 +module Stripe::Treasury; end + +# You can reverse some [ReceivedCredits](https://stripe.com/docs/api#received_credits) depending on their network and source flow. Reversing a ReceivedCredit leads to the creation of a new object known as a CreditReversal. +# +# source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#7 +class Stripe::Treasury::CreditReversal < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + class << self + # Reverses a ReceivedCredit and creates a CreditReversal object. + # + # source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#17 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of CreditReversals. + # + # source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#27 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#11 +Stripe::Treasury::CreditReversal::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# You can reverse some [ReceivedDebits](https://stripe.com/docs/api#received_debits) depending on their network and source flow. Reversing a ReceivedDebit leads to the creation of a new object known as a DebitReversal. +# +# source://stripe//lib/stripe/resources/treasury/debit_reversal.rb#7 +class Stripe::Treasury::DebitReversal < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + class << self + # Reverses a ReceivedDebit and creates a DebitReversal object. + # + # source://stripe//lib/stripe/resources/treasury/debit_reversal.rb#17 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of DebitReversals. + # + # source://stripe//lib/stripe/resources/treasury/debit_reversal.rb#27 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/debit_reversal.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/debit_reversal.rb#11 +Stripe::Treasury::DebitReversal::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Stripe Treasury provides users with a container for money called a FinancialAccount that is separate from their Payments balance. +# FinancialAccounts serve as the source and destination of Treasury's money movement APIs. +# +# source://stripe//lib/stripe/resources/treasury/financial_account.rb#8 +class Stripe::Treasury::FinancialAccount < ::Stripe::APIResource + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # Retrieves Features information associated with the FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#39 + def retrieve_features(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the Features associated with a FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#69 + def update_features(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Creates a new FinancialAccount. For now, each connected account can only have one FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#19 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of FinancialAccounts. + # + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#29 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#14 + def object_name; end + + # Retrieves Features information associated with the FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#49 + def retrieve_features(financial_account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the details of a FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#59 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates the Features associated with a FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/financial_account.rb#79 + def update_features(financial_account, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/treasury/financial_account.rb#13 +Stripe::Treasury::FinancialAccount::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Encodes whether a FinancialAccount has access to a particular Feature, with a `status` enum and associated `status_details`. +# Stripe or the platform can control Features via the requested field. +# +# source://stripe//lib/stripe/resources/treasury/financial_account_features.rb#8 +class Stripe::Treasury::FinancialAccountFeatures < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/treasury/financial_account_features.rb#10 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/financial_account_features.rb#9 +Stripe::Treasury::FinancialAccountFeatures::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Use [InboundTransfers](https://stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers) to add funds to your [FinancialAccount](https://stripe.com/docs/api#financial_accounts) via a PaymentMethod that is owned by you. The funds will be transferred via an ACH debit. +# +# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#7 +class Stripe::Treasury::InboundTransfer < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + # Cancels an InboundTransfer. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#17 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#56 + def test_helpers; end + + class << self + # Cancels an InboundTransfer. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#27 + def cancel(inbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates an InboundTransfer. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#37 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of InboundTransfers sent from the specified FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#47 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#12 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#11 +Stripe::Treasury::InboundTransfer::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#60 +class Stripe::Treasury::InboundTransfer::TestHelpers < ::Stripe::APIResourceTestHelpers + # Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#77 + def fail(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#97 + def return_inbound_transfer(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#117 + def succeed(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#67 + def fail(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#62 + def resource_class; end + + # Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#87 + def return_inbound_transfer(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#107 + def succeed(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#61 +Stripe::Treasury::InboundTransfer::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::InboundTransfer + +# Use OutboundPayments to send funds to another party's external bank account or [FinancialAccount](https://stripe.com/docs/api#financial_accounts). To send money to an account belonging to the same user, use an [OutboundTransfer](https://stripe.com/docs/api#outbound_transfers). +# +# Simulate OutboundPayment state changes with the `/v1/test_helpers/treasury/outbound_payments` endpoints. These methods can only be called on test mode objects. +# +# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#9 +class Stripe::Treasury::OutboundPayment < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + # Cancel an OutboundPayment. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#19 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#58 + def test_helpers; end + + class << self + # Cancel an OutboundPayment. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#29 + def cancel(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates an OutboundPayment. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#39 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of OutboundPayments sent from the specified FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#49 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#14 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#13 +Stripe::Treasury::OutboundPayment::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#62 +class Stripe::Treasury::OutboundPayment::TestHelpers < ::Stripe::APIResourceTestHelpers + # Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#79 + def fail(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#99 + def post(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#119 + def return_outbound_payment(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#139 + def update(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#69 + def fail(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#89 + def post(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#64 + def resource_class; end + + # Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#109 + def return_outbound_payment(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states. + # + # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#129 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#63 +Stripe::Treasury::OutboundPayment::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::OutboundPayment + +# Use OutboundTransfers to transfer funds from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) to a PaymentMethod belonging to the same entity. To send funds to a different party, use [OutboundPayments](https://stripe.com/docs/api#outbound_payments) instead. You can send funds over ACH rails or through a domestic wire transfer to a user's own external bank account. +# +# Simulate OutboundTransfer state changes with the `/v1/test_helpers/treasury/outbound_transfers` endpoints. These methods can only be called on test mode objects. +# +# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#9 +class Stripe::Treasury::OutboundTransfer < ::Stripe::APIResource + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::List + + # An OutboundTransfer can be canceled if the funds have not yet been paid out. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#19 + def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#58 + def test_helpers; end + + class << self + # An OutboundTransfer can be canceled if the funds have not yet been paid out. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#29 + def cancel(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Creates an OutboundTransfer. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#39 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of OutboundTransfers sent from the specified FinancialAccount. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#49 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#14 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#13 +Stripe::Treasury::OutboundTransfer::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#62 +class Stripe::Treasury::OutboundTransfer::TestHelpers < ::Stripe::APIResourceTestHelpers + # Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#79 + def fail(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#99 + def post(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#119 + def return_outbound_transfer(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#139 + def update(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#69 + def fail(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#89 + def post(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#64 + def resource_class; end + + # Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#109 + def return_outbound_transfer(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states. + # + # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#129 + def update(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#63 +Stripe::Treasury::OutboundTransfer::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::OutboundTransfer + +# ReceivedCredits represent funds sent to a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) (for example, via ACH or wire). These money movements are not initiated from the FinancialAccount. +# +# source://stripe//lib/stripe/resources/treasury/received_credit.rb#7 +class Stripe::Treasury::ReceivedCredit < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + # source://stripe//lib/stripe/resources/treasury/received_credit.rb#25 + def test_helpers; end + + class << self + # Returns a list of ReceivedCredits. + # + # source://stripe//lib/stripe/resources/treasury/received_credit.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/received_credit.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/received_credit.rb#10 +Stripe::Treasury::ReceivedCredit::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/treasury/received_credit.rb#29 +class Stripe::Treasury::ReceivedCredit::TestHelpers < ::Stripe::APIResourceTestHelpers + class << self + # Use this endpoint to simulate a test mode ReceivedCredit initiated by a third party. In live mode, you can't directly create ReceivedCredits initiated by third parties. + # + # source://stripe//lib/stripe/resources/treasury/received_credit.rb#36 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/received_credit.rb#31 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/treasury/received_credit.rb#30 +Stripe::Treasury::ReceivedCredit::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::ReceivedCredit + +# ReceivedDebits represent funds pulled from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts). These are not initiated from the FinancialAccount. +# +# source://stripe//lib/stripe/resources/treasury/received_debit.rb#7 +class Stripe::Treasury::ReceivedDebit < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + # source://stripe//lib/stripe/resources/treasury/received_debit.rb#25 + def test_helpers; end + + class << self + # Returns a list of ReceivedDebits. + # + # source://stripe//lib/stripe/resources/treasury/received_debit.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/received_debit.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/received_debit.rb#10 +Stripe::Treasury::ReceivedDebit::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/treasury/received_debit.rb#29 +class Stripe::Treasury::ReceivedDebit::TestHelpers < ::Stripe::APIResourceTestHelpers + class << self + # Use this endpoint to simulate a test mode ReceivedDebit initiated by a third party. In live mode, you can't directly create ReceivedDebits initiated by third parties. + # + # source://stripe//lib/stripe/resources/treasury/received_debit.rb#36 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/received_debit.rb#31 + def resource_class; end + end +end + +# source://stripe//lib/stripe/resources/treasury/received_debit.rb#30 +Stripe::Treasury::ReceivedDebit::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::ReceivedDebit + +# Transactions represent changes to a [FinancialAccount's](https://stripe.com/docs/api#financial_accounts) balance. +# +# source://stripe//lib/stripe/resources/treasury/transaction.rb#7 +class Stripe::Treasury::Transaction < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Retrieves a list of Transaction objects. + # + # source://stripe//lib/stripe/resources/treasury/transaction.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/transaction.rb#11 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/treasury/transaction.rb#10 +Stripe::Treasury::Transaction::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# TransactionEntries represent individual units of money movements within a single [Transaction](https://stripe.com/docs/api#transactions). +# +# source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#7 +class Stripe::Treasury::TransactionEntry < ::Stripe::APIResource + extend ::Stripe::APIOperations::List + + class << self + # Retrieves a list of TransactionEntry objects. + # + # source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#16 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#11 + def object_name; end + + # source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#25 + def resource_url; end + end +end + +# source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#10 +Stripe::Treasury::TransactionEntry::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# Usage records allow you to report customer usage and metrics to Stripe for +# metered billing of subscription prices. +# +# Related guide: [Metered billing](https://stripe.com/docs/billing/subscriptions/metered-billing) +# +# This is our legacy usage-based billing API. See the [updated usage-based billing docs](https://docs.stripe.com/billing/subscriptions/usage-based). +# +# source://stripe//lib/stripe/resources/usage_record.rb#11 +class Stripe::UsageRecord < ::Stripe::APIResource + class << self + # source://stripe//lib/stripe/resources/usage_record.rb#13 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/usage_record.rb#12 +Stripe::UsageRecord::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/resources/usage_record_summary.rb#5 +class Stripe::UsageRecordSummary < ::Stripe::StripeObject + class << self + # source://stripe//lib/stripe/resources/usage_record_summary.rb#7 + def object_name; end + end +end + +# source://stripe//lib/stripe/resources/usage_record_summary.rb#6 +Stripe::UsageRecordSummary::OBJECT_NAME = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/util.rb#6 +module Stripe::Util + class << self + # @raise [TypeError] + # + # source://stripe//lib/stripe/util.rb#297 + def check_api_key!(key); end + + # @raise [TypeError] + # + # source://stripe//lib/stripe/util.rb#291 + def check_string_argument!(key); end + + # Converts a hash of fields or an array of hashes into a +StripeObject+ or + # array of +StripeObject+s. These new objects will be created as a concrete + # type as dictated by their `object` field (e.g. an `object` value of + # `charge` would create an instance of +Charge+), but if `object` is not + # present or of an unknown type, the newly created instance will fall back + # to being a +StripeObject+. + # + # ==== Attributes + # + # * +data+ - Hash of fields and values to be converted into a StripeObject. + # * +params+ - Params for +StripeObject+ like filters used in search that + # will be reused on subsequent API calls. + # * +opts+ - Options for +StripeObject+ like an API key that will be reused + # on subsequent API calls. + # + # source://stripe//lib/stripe/util.rb#111 + def convert_to_stripe_object(data, opts = T.unsafe(nil)); end + + # Converts a hash of fields or an array of hashes into a +StripeObject+ or + # array of +StripeObject+s. These new objects will be created as a concrete + # type as dictated by their `object` field (e.g. an `object` value of + # `charge` would create an instance of +Charge+), but if `object` is not + # present or of an unknown type, the newly created instance will fall back + # to being a +StripeObject+. + # + # ==== Attributes + # + # * +data+ - Hash of fields and values to be converted into a StripeObject. + # * +opts+ - Options for +StripeObject+ like an API key that will be reused + # on subsequent API calls. + # + # source://stripe//lib/stripe/util.rb#127 + def convert_to_stripe_object_with_params(data, params, opts = T.unsafe(nil), last_response = T.unsafe(nil)); end + + # Adds a custom method to a resource class. This is used to add support for + # non-CRUDL API requests, e.g. capturing charges. custom_method takes the + # following parameters: + # - name: the name of the custom method to create (as a symbol) + # - http_verb: the HTTP verb for the API request (:get, :post, or :delete) + # - http_path: the path to append to the resource's URL. If not provided, + # the name is used as the path + # - resource: the resource implementation class + # - target: the class that custom static method will be added to + # + # For example, this call: + # custom_method :capture, http_verb: post + # adds a `capture` class method to the resource class that, when called, + # will send a POST request to `/v1//capture`. + # + # source://stripe//lib/stripe/util.rb#64 + def custom_method(resource, target, name, http_verb, http_path); end + + # Encodes a hash of parameters in a way that's suitable for use as query + # parameters in a URI or as form parameters in a request body. This mainly + # involves escaping special characters from parameter keys and values (e.g. + # `&`). + # + # source://stripe//lib/stripe/util.rb#204 + def encode_parameters(params); end + + # source://stripe//lib/stripe/util.rb#220 + def flatten_params(params, parent_key = T.unsafe(nil)); end + + # source://stripe//lib/stripe/util.rb#239 + def flatten_params_array(value, calculated_key); end + + # source://stripe//lib/stripe/util.rb#170 + def log_debug(message, data = T.unsafe(nil)); end + + # source://stripe//lib/stripe/util.rb#150 + def log_error(message, data = T.unsafe(nil)); end + + # source://stripe//lib/stripe/util.rb#160 + def log_info(message, data = T.unsafe(nil)); end + + # `Time.now` can be unstable in cases like an administrator manually + # updating its value or a reconcilation via NTP. For this reason, prefer + # the use of the system's monotonic clock especially where comparing times + # to calculate an elapsed duration. + # + # Shortcut for getting monotonic time, mostly for purposes of line length + # and test stubbing. Returns time in seconds since the event used for + # monotonic reference purposes by the platform (e.g. system boot time). + # + # source://stripe//lib/stripe/util.rb#261 + def monotonic_time; end + + # Normalizes header keys so that they're all lower case and each + # hyphen-delimited section starts with a single capitalized letter. For + # example, `request-id` becomes `Request-Id`. This is useful for extracting + # certain key values when the user could have set them with a variety of + # diffent naming schemes. + # + # source://stripe//lib/stripe/util.rb#308 + def normalize_headers(headers); end + + # source://stripe//lib/stripe/util.rb#265 + def normalize_id(id); end + + # The secondary opts argument can either be a string or hash + # Turn this value into an api_key and a set of headers + # + # source://stripe//lib/stripe/util.rb#277 + def normalize_opts(opts); end + + # source://stripe//lib/stripe/util.rb#42 + def object_classes; end + + # @return [Boolean] + # + # source://stripe//lib/stripe/util.rb#46 + def object_name_matches_class?(object_name, klass); end + + # source://stripe//lib/stripe/util.rb#27 + def objects_to_ids(obj); end + + # Generates a Dashboard link to inspect a request ID based off of a request + # ID value and an API key, which is used to attempt to extract whether the + # environment is livemode or testmode. + # + # source://stripe//lib/stripe/util.rb#320 + def request_id_dashboard_url(request_id, api_key); end + + # Constant time string comparison to prevent timing attacks + # Code borrowed from ActiveSupport + # + # source://stripe//lib/stripe/util.rb#327 + def secure_compare(str_a, str_b); end + + # source://stripe//lib/stripe/util.rb#180 + def symbolize_names(object); end + + # Encodes a string in a way that makes it suitable for use in a set of + # query parameters in a URI or in a set of form parameters in a request + # body. + # + # source://stripe//lib/stripe/util.rb#212 + def url_encode(key); end + + private + + # Uses an ANSI escape code to colorize text if it's going to be sent to a + # TTY. + # + # source://stripe//lib/stripe/util.rb#356 + def colorize(val, color, isatty); end + + # Turns an integer log level into a printable name. + # + # source://stripe//lib/stripe/util.rb#368 + def level_name(level); end + + # source://stripe//lib/stripe/util.rb#378 + def log_internal(message, data = T.unsafe(nil), color:, level:, logger:, out:); end + + # Wraps a value in double quotes if it looks sufficiently complex so that + # it can be read by logfmt parsers. + # + # source://stripe//lib/stripe/util.rb#410 + def wrap_logfmt_value(val); end + end +end + +# private +# +# source://stripe//lib/stripe/util.rb#341 +Stripe::Util::COLOR_CODES = T.let(T.unsafe(nil), Hash) + +# Options that should be copyable from one StripeObject to another +# including options that may be internal. +# +# source://stripe//lib/stripe/util.rb#17 +Stripe::Util::OPTS_COPYABLE = T.let(T.unsafe(nil), Set) + +# Options that should be persisted between API requests. This includes +# client, which is an object containing an HTTP client to reuse. +# +# source://stripe//lib/stripe/util.rb#23 +Stripe::Util::OPTS_PERSISTABLE = T.let(T.unsafe(nil), Set) + +# Options that a user is allowed to specify. +# +# source://stripe//lib/stripe/util.rb#8 +Stripe::Util::OPTS_USER_SPECIFIED = T.let(T.unsafe(nil), Set) + +# source://stripe//lib/stripe/version.rb#4 +Stripe::VERSION = T.let(T.unsafe(nil), String) + +# source://stripe//lib/stripe/webhook.rb#4 +module Stripe::Webhook + class << self + # Initializes an Event object from a JSON payload. + # + # This may raise JSON::ParserError if the payload is not valid JSON, or + # SignatureVerificationError if the signature verification fails. + # + # source://stripe//lib/stripe/webhook.rb#11 + def construct_event(payload, sig_header, secret, tolerance: T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/webhook.rb#5 +Stripe::Webhook::DEFAULT_TOLERANCE = T.let(T.unsafe(nil), Integer) + +# source://stripe//lib/stripe/webhook.rb#24 +module Stripe::Webhook::Signature + class << self + # Computes a webhook signature given a time (probably the current time), + # a payload, and a signing secret. + # + # @raise [ArgumentError] + # + # source://stripe//lib/stripe/webhook.rb#29 + def compute_signature(timestamp, payload, secret); end + + # Generates a value that would be added to a `Stripe-Signature` for a + # given webhook payload. + # + # Note that this isn't needed to verify webhooks in any way, and is + # mainly here for use in test cases (those that are both within this + # project and without). + # + # @raise [ArgumentError] + # + # source://stripe//lib/stripe/webhook.rb#48 + def generate_header(timestamp, signature, scheme: T.unsafe(nil)); end + + # Verifies the signature header for a given payload. + # + # Raises a SignatureVerificationError in the following cases: + # - the header does not match the expected format + # - no signatures found with the expected scheme + # - no signatures matching the expected signature + # - a tolerance is provided and the timestamp is not within the + # tolerance + # + # Returns true otherwise + # + # source://stripe//lib/stripe/webhook.rb#79 + def verify_header(payload, header, secret, tolerance: T.unsafe(nil)); end + + private + + # Extracts the timestamp and the signature(s) with the desired scheme + # from the header + # + # source://stripe//lib/stripe/webhook.rb#61 + def get_timestamp_and_signatures(header, scheme); end + end +end + +# source://stripe//lib/stripe/webhook.rb#25 +Stripe::Webhook::Signature::EXPECTED_SCHEME = T.let(T.unsafe(nil), String) + +# You can configure [webhook endpoints](https://docs.stripe.com/webhooks/) via the API to be +# notified about events that happen in your Stripe account or connected +# accounts. +# +# Most users configure webhooks from [the dashboard](https://dashboard.stripe.com/webhooks), which provides a user interface for registering and testing your webhook endpoints. +# +# Related guide: [Setting up webhooks](https://docs.stripe.com/webhooks/configure) +# +# source://stripe//lib/stripe/resources/webhook_endpoint.rb#12 +class Stripe::WebhookEndpoint < ::Stripe::APIResource + include ::Stripe::APIOperations::Delete + include ::Stripe::APIOperations::Save + extend ::Stripe::APIOperations::Create + extend ::Stripe::APIOperations::Delete::ClassMethods + extend ::Stripe::APIOperations::List + extend ::Stripe::APIOperations::Save::ClassMethods + + # You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard. + # + # source://stripe//lib/stripe/resources/webhook_endpoint.rb#44 + def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + class << self + # A webhook endpoint must have a url and a list of enabled_events. You may optionally specify the Boolean connect parameter. If set to true, then a Connect webhook endpoint that notifies the specified url about events from all connected accounts is created; otherwise an account webhook endpoint that notifies the specified url only about events from your account is created. You can also create webhook endpoints in the [webhooks settings](https://dashboard.stripe.com/account/webhooks) section of the Dashboard. + # + # source://stripe//lib/stripe/resources/webhook_endpoint.rb#24 + def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard. + # + # source://stripe//lib/stripe/resources/webhook_endpoint.rb#34 + def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + + # Returns a list of your webhook endpoints. + # + # source://stripe//lib/stripe/resources/webhook_endpoint.rb#54 + def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end + + # source://stripe//lib/stripe/resources/webhook_endpoint.rb#19 + def object_name; end + + # Updates the webhook endpoint. You may edit the url, the list of enabled_events, and the status of your endpoint. + # + # source://stripe//lib/stripe/resources/webhook_endpoint.rb#64 + def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end + end +end + +# source://stripe//lib/stripe/resources/webhook_endpoint.rb#18 +Stripe::WebhookEndpoint::OBJECT_NAME = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/stripe@8.5.0.rbi b/sorbet/rbi/gems/stripe@8.5.0.rbi deleted file mode 100644 index 392e8843a..000000000 --- a/sorbet/rbi/gems/stripe@8.5.0.rbi +++ /dev/null @@ -1,5611 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `stripe` gem. -# Please instead update this file by running `bin/tapioca gem stripe`. - -# File generated from our OpenAPI spec -# -# source://stripe//lib/stripe/version.rb#3 -module Stripe - class << self - # source://forwardable/1.3.3/forwardable.rb#231 - def api_base(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def api_base=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def api_key(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def api_key=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def api_version(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def api_version=(*args, **_arg1, &block); end - - # Gets the application for a plugin that's identified some. See - # #set_app_info. - # - # source://stripe//lib/stripe.rb#97 - def app_info; end - - # source://stripe//lib/stripe.rb#101 - def app_info=(info); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def ca_bundle_path(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def ca_bundle_path=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def ca_store(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def client_id(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def client_id=(*args, **_arg1, &block); end - - # Returns the value of attribute config. - # - # source://stripe//lib/stripe.rb#68 - def config; end - - # source://forwardable/1.3.3/forwardable.rb#231 - def connect_base(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def connect_base=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def enable_telemetry=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def enable_telemetry?(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def initial_network_retry_delay(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def log_level(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def log_level=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def logger(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def logger=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def max_network_retries(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def max_network_retries=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def max_network_retry_delay(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def open_timeout(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def open_timeout=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def proxy(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def proxy=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def read_timeout(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def read_timeout=(*args, **_arg1, &block); end - - # Sets some basic information about the running application that's sent along - # with API requests. Useful for plugin authors to identify their plugin when - # communicating with Stripe. - # - # Takes a name and optional partner program ID, plugin URL, and version. - # - # source://stripe//lib/stripe.rb#110 - def set_app_info(name, partner_id: T.unsafe(nil), url: T.unsafe(nil), version: T.unsafe(nil)); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def stripe_account(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def stripe_account=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def uploads_base(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def uploads_base=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def verify_ssl_certs(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def verify_ssl_certs=(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def write_timeout(*args, **_arg1, &block); end - - # source://forwardable/1.3.3/forwardable.rb#231 - def write_timeout=(*args, **_arg1, &block); end - end -end - -# APIConnectionError is raised in the event that the SDK can't connect to -# Stripe's servers. That can be for a variety of different reasons from a -# downed network to a bad TLS certificate. -# -# source://stripe//lib/stripe/errors.rb#63 -class Stripe::APIConnectionError < ::Stripe::StripeError; end - -# APIError is a generic error that may be raised in cases where none of the -# other named errors cover the problem. It could also be raised in the case -# that a new error has been introduced in the API, but this version of the -# Ruby SDK doesn't know how to handle it. -# -# source://stripe//lib/stripe/errors.rb#70 -class Stripe::APIError < ::Stripe::StripeError; end - -# source://stripe//lib/stripe/api_operations/create.rb#4 -module Stripe::APIOperations; end - -# source://stripe//lib/stripe/api_operations/create.rb#5 -module Stripe::APIOperations::Create - # source://stripe//lib/stripe/api_operations/create.rb#6 - def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end -end - -# source://stripe//lib/stripe/api_operations/delete.rb#5 -module Stripe::APIOperations::Delete - mixes_in_class_methods ::Stripe::APIOperations::Delete::ClassMethods - - # source://stripe//lib/stripe/api_operations/delete.rb#30 - def delete(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # @private - # - # source://stripe//lib/stripe/api_operations/delete.rb#39 - def included(base); end - end -end - -# source://stripe//lib/stripe/api_operations/delete.rb#6 -module Stripe::APIOperations::Delete::ClassMethods - # Deletes an API resource - # - # Deletes the identified resource with the passed in parameters. - # - # ==== Attributes - # - # * +id+ - ID of the resource to delete. - # * +params+ - A hash of parameters to pass to the API - # * +opts+ - A Hash of additional options (separate from the params / - # object values) to be added to the request. E.g. to allow for an - # idempotency_key to be passed in the request headers, or for the - # api_key to be overwritten. See - # {APIOperations::Request.execute_resource_request}. - # - # source://stripe//lib/stripe/api_operations/delete.rb#20 - def delete(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end -end - -# source://stripe//lib/stripe/api_operations/list.rb#5 -module Stripe::APIOperations::List - # source://stripe//lib/stripe/api_operations/list.rb#6 - def list(filters = T.unsafe(nil), opts = T.unsafe(nil)); end -end - -# Adds methods to help manipulate a subresource from its parent resource so -# that it's possible to do so from a static context (i.e. without a -# pre-existing collection of subresources on the parent). -# -# For example, a transfer gains the static methods for reversals so that the -# methods `.create_reversal`, `.retrieve_reversal`, `.update_reversal`, -# etc. all become available. -# -# source://stripe//lib/stripe/api_operations/nested_resource.rb#12 -module Stripe::APIOperations::NestedResource - # @raise [ArgumentError] - # - # source://stripe//lib/stripe/api_operations/nested_resource.rb#13 - def nested_resource_class_methods(resource, path: T.unsafe(nil), operations: T.unsafe(nil), resource_plural: T.unsafe(nil)); end - - private - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#38 - def define_operation(resource, operation, resource_url_method, resource_plural); end -end - -# source://stripe//lib/stripe/api_operations/request.rb#5 -module Stripe::APIOperations::Request - mixes_in_class_methods ::Stripe::APIOperations::Request::ClassMethods - - protected - - # source://stripe//lib/stripe/api_operations/request.rb#115 - def execute_resource_request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/request.rb#121 - def execute_resource_request_stream(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), &read_body_chunk_block); end - - # See notes on `alias` above. - # - # source://stripe//lib/stripe/api_operations/request.rb#115 - def request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - private - - # source://stripe//lib/stripe/api_operations/request.rb#130 - def request_stripe_object(method:, path:, params:, opts: T.unsafe(nil)); end - - class << self - # @private - # - # source://stripe//lib/stripe/api_operations/request.rb#111 - def included(base); end - end -end - -# source://stripe//lib/stripe/api_operations/request.rb#6 -module Stripe::APIOperations::Request::ClassMethods - # source://stripe//lib/stripe/api_operations/request.rb#7 - def execute_resource_request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/request.rb#14 - def execute_resource_request_stream(method, url, params = T.unsafe(nil), opts = T.unsafe(nil), &read_body_chunk_block); end - - # This method used to be called `request`, but it's such a short name - # that it eventually conflicted with the name of a field on an API - # resource (specifically, `Event#request`), so it was renamed to - # something more unique. - # - # The former name had been around for just about forever though, and - # although all internal uses have been renamed, I've left this alias in - # place for backwards compatibility. Consider removing it on the next - # major. - # - # source://stripe//lib/stripe/api_operations/request.rb#7 - def request(method, url, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - private - - # @raise [ArgumentError] - # - # source://stripe//lib/stripe/api_operations/request.rb#94 - def error_on_invalid_params(params); end - - # source://stripe//lib/stripe/api_operations/request.rb#80 - def error_on_non_string_user_opts(opts); end - - # source://stripe//lib/stripe/api_operations/request.rb#32 - def execute_resource_request_internal(client_request_method_sym, method, url, params, opts, &read_body_chunk_block); end - - # source://stripe//lib/stripe/api_operations/request.rb#27 - def request_stripe_object(method:, path:, params:, opts: T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/request.rb#102 - def warn_on_opts_in_params(params); end -end - -# source://stripe//lib/stripe/api_operations/save.rb#5 -module Stripe::APIOperations::Save - extend ::Gem::Deprecate - - mixes_in_class_methods ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/api_operations/save.rb#56 - def _deprecated_save(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # The `save` method is DEPRECATED and will be removed in a future major - # version of the library. Use the `update` method on the resource instead. - # - # Creates or updates an API resource. - # - # If the resource doesn't yet have an assigned ID and the resource is one - # that can be created, then the method attempts to create the resource. - # The resource is updated otherwise. - # - # ==== Attributes - # - # * +params+ - Overrides any parameters in the resource's serialized data - # and includes them in the create or update. If +:req_url:+ is included - # in the list, it overrides the update URL used for the create or - # update. - # * +opts+ - A Hash of additional options (separate from the params / - # object values) to be added to the request. E.g. to allow for an - # idempotency_key to be passed in the request headers, or for the - # api_key to be overwritten. See - # {APIOperations::Request.execute_resource_request}. - def save(*args, **_arg1, &block); end - - private - - # source://stripe//lib/stripe/api_operations/save.rb#92 - def save_url; end - - class << self - # @private - # - # source://stripe//lib/stripe/api_operations/save.rb#79 - def included(base); end - end -end - -# source://stripe//lib/stripe/api_operations/save.rb#6 -module Stripe::APIOperations::Save::ClassMethods - # Updates an API resource - # - # Updates the identified resource with the passed in parameters. - # - # ==== Attributes - # - # * +id+ - ID of the resource to update. - # * +params+ - A hash of parameters to pass to the API - # * +opts+ - A Hash of additional options (separate from the params / - # object values) to be added to the request. E.g. to allow for an - # idempotency_key to be passed in the request headers, or for the - # api_key to be overwritten. See - # {APIOperations::Request.execute_resource_request}. - # - # source://stripe//lib/stripe/api_operations/save.rb#20 - def update(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end -end - -# source://stripe//lib/stripe/api_operations/search.rb#5 -module Stripe::APIOperations::Search - # source://stripe//lib/stripe/api_operations/search.rb#6 - def _search(search_url, filters = T.unsafe(nil), opts = T.unsafe(nil)); end -end - -# source://stripe//lib/stripe/api_resource.rb#4 -class Stripe::APIResource < ::Stripe::StripeObject - include ::Stripe::APIOperations::Request - extend ::Stripe::APIOperations::Request::ClassMethods - - # source://stripe//lib/stripe/api_resource.rb#80 - def refresh; end - - # source://stripe//lib/stripe/api_resource.rb#93 - def request_stripe_object(method:, path:, params:, opts: T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_resource.rb#69 - def resource_url; end - - # A flag that can be set a behavior that will cause this resource to be - # encoded and sent up along with an update of its parent resource. This is - # usually not desirable because resources are updated individually on their - # own endpoints, but there are certain cases, replacing a customer's source - # for example, where this is allowed. - # - # source://stripe//lib/stripe/api_resource.rb#12 - def save_with_parent; end - - # A flag that can be set a behavior that will cause this resource to be - # encoded and sent up along with an update of its parent resource. This is - # usually not desirable because resources are updated individually on their - # own endpoints, but there are certain cases, replacing a customer's source - # for example, where this is allowed. - # - # source://stripe//lib/stripe/api_resource.rb#12 - def save_with_parent=(_arg0); end - - protected - - # source://stripe//lib/stripe/api_resource.rb#104 - def request_stream(method:, path:, params:, opts: T.unsafe(nil), &read_body_chunk_block); end - - class << self - # source://stripe//lib/stripe/api_resource.rb#14 - def class_name; end - - # Adds a custom method to a resource class. This is used to add support for - # non-CRUDL API requests, e.g. capturing charges. custom_method takes the - # following parameters: - # - name: the name of the custom method to create (as a symbol) - # - http_verb: the HTTP verb for the API request (:get, :post, or :delete) - # - http_path: the path to append to the resource's URL. If not provided, - # the name is used as the path - # - # For example, this call: - # custom_method :capture, http_verb: post - # adds a `capture` class method to the resource class that, when called, - # will send a POST request to `/v1//capture`. - # - # source://stripe//lib/stripe/api_resource.rb#65 - def custom_method(name, http_verb:, http_path: T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_resource.rb#18 - def resource_url; end - - # source://stripe//lib/stripe/api_resource.rb#86 - def retrieve(id, opts = T.unsafe(nil)); end - - # A metaprogramming call that specifies that a field of a resource can be - # its own type of API resource (say a nested card under an account for - # example), and if that resource is set, it should be transmitted to the - # API on a create or update. Doing so is not the default behavior because - # API resources should normally be persisted on their own RESTful - # endpoints. - # - # source://stripe//lib/stripe/api_resource.rb#35 - def save_nested_resource(name); end - end -end - -# The base class for nested TestHelpers classes in resource objects. -# The APIResourceTestHelpers handles URL generation and custom method -# support for test-helper methods. -# -# class MyAPIResource < APIResource -# class TestHelpers < APIResourceTestHelpers -# -# source://stripe//lib/stripe/api_resource_test_helpers.rb#10 -class Stripe::APIResourceTestHelpers - include ::Stripe::APIOperations::Request - extend ::Stripe::APIOperations::Request::ClassMethods - - # @return [APIResourceTestHelpers] a new instance of APIResourceTestHelpers - # - # source://stripe//lib/stripe/api_resource_test_helpers.rb#13 - def initialize(resource); end - - # source://stripe//lib/stripe/api_resource_test_helpers.rb#38 - def resource_url; end - - class << self - # Adds a custom method to a test helper. This is used to add support for - # non-CRUDL API requests, e.g. capturing charges. custom_method takes the - # following parameters: - # - name: the name of the custom method to create (as a symbol) - # - http_verb: the HTTP verb for the API request (:get, :post, or :delete) - # - http_path: the path to append to the resource's URL. If not provided, - # the name is used as the path - # - # For example, this call: - # custom_method :capture, http_verb: post - # adds a `capture` class method to the resource class that, when called, - # will send a POST request to `/v1//capture`. - # - # source://stripe//lib/stripe/api_resource_test_helpers.rb#29 - def custom_method(name, http_verb:, http_path: T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_resource_test_helpers.rb#33 - def resource_url; end - end -end - -# This is an object representing a Stripe account. You can retrieve it to see -# properties on the account like its current requirements or if the account is -# enabled to make live charges or receive payouts. -# -# For Custom accounts, the properties below are always returned. For other accounts, some properties are returned until that -# account has started to go through Connect Onboarding. Once you create an [Account Link](https://stripe.com/docs/api/account_links) -# for a Standard or Express account, some parameters are no longer returned. These are marked as **Custom Only** or **Custom and Express** -# below. Learn about the differences [between accounts](https://stripe.com/docs/connect/accounts). -# -# source://stripe//lib/stripe/resources/account.rb#13 -class Stripe::Account < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Gem::Deprecate - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - extend ::Stripe::APIOperations::NestedResource - - # source://stripe//lib/stripe/resources/account.rb#157 - def deauthorize(client_id = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_resource.rb#36 - def external_account=(value); end - - # source://stripe//lib/stripe/resources/account.rb#146 - def legal_entity; end - - # @raise [NoMethodError] - # - # source://stripe//lib/stripe/resources/account.rb#150 - def legal_entity=(_legal_entity); end - - # source://stripe//lib/stripe/resources/account.rb#29 - def persons(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/account.rb#38 - def reject(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/account.rb#71 - def resource_url; end - - # Somewhat unfortunately, we attempt to do a special encoding trick when - # serializing `additional_owners` under an account: when updating a value, - # we actually send the update parameters up as an integer-indexed hash - # rather than an array. So instead of this: - # - # field[]=item1&field[]=item2&field[]=item3 - # - # We send this: - # - # field[0]=item1&field[1]=item2&field[2]=item3 - # - # There are two major problems with this technique: - # - # * Entities are addressed by array index, which is not stable and can - # easily result in unexpected results between two different requests. - # - # * A replacement of the array's contents is ambiguous with setting a - # subset of the array. Because of this, the only way to shorten an - # array is to unset it completely by making sure it goes into the - # server as an empty string, then setting its contents again. - # - # We're trying to get this overturned on the server side, but for now, - # patch in a special allowance. - # - # source://stripe//lib/stripe/resources/account.rb#122 - def serialize_params(options = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/account.rb#126 - def serialize_params_account(_obj, update_hash, options = T.unsafe(nil)); end - - private - - # source://stripe//lib/stripe/resources/account.rb#166 - def serialize_additional_owners(legal_entity, additional_owners); end - - class << self - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def capabilitys_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_external_account(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_login_link(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_person(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#77 - def delete_external_account(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#77 - def delete_person(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def external_accounts_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_capabilities(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_external_accounts(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_persons(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def login_links_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/account.rb#47 - def persons(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def persons_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/account.rb#142 - def protected_fields; end - - # source://stripe//lib/stripe/resources/account.rb#56 - def reject(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/account.rb#80 - def retrieve(id = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_capability(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_external_account(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_person(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#67 - def update_capability(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#67 - def update_external_account(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#67 - def update_person(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/account.rb#21 -Stripe::Account::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Account Links are the means by which a Connect platform grants a connected account permission to access -# Stripe-hosted applications, such as Connect Onboarding. -# -# Related guide: [Connect Onboarding](https://stripe.com/docs/connect/connect-onboarding). -# -# source://stripe//lib/stripe/resources/account_link.rb#9 -class Stripe::AccountLink < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create -end - -# source://stripe//lib/stripe/resources/account_link.rb#12 -Stripe::AccountLink::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Domains registered for Apple Pay on the Web -# -# source://stripe//lib/stripe/resources/apple_pay_domain.rb#6 -class Stripe::ApplePayDomain < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - - class << self - # source://stripe//lib/stripe/resources/apple_pay_domain.rb#13 - def resource_url; end - end -end - -# source://stripe//lib/stripe/resources/apple_pay_domain.rb#11 -Stripe::ApplePayDomain::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/application_fee.rb#5 -class Stripe::ApplicationFee < ::Stripe::APIResource - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::NestedResource - - class << self - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_refund(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_refunds(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def refunds_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_refund(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#67 - def update_refund(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/application_fee.rb#9 -Stripe::ApplicationFee::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# `Application Fee Refund` objects allow you to refund an application fee that -# has previously been created but not yet refunded. Funds will be refunded to -# the Stripe account from which the fee was originally collected. -# -# Related guide: [Refunding Application Fees](https://stripe.com/docs/connect/destination-charges#refunding-app-fee). -# -# source://stripe//lib/stripe/resources/application_fee_refund.rb#10 -class Stripe::ApplicationFeeRefund < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/application_fee_refund.rb#16 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/application_fee_refund.rb#29 - def retrieve(_id, _api_key = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/application_fee_refund.rb#21 - def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/application_fee_refund.rb#14 -Stripe::ApplicationFeeRefund::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/apps/secret.rb#5 -module Stripe::Apps; end - -# Secret Store is an API that allows Stripe Apps developers to securely persist secrets for use by UI Extensions and app backends. -# -# The primary resource in Secret Store is a `secret`. Other apps can't view secrets created by an app. Additionally, secrets are scoped to provide further permission control. -# -# All Dashboard users and the app backend share `account` scoped secrets. Use the `account` scope for secrets that don't change per-user, like a third-party API key. -# -# A `user` scoped secret is accessible by the app backend and one specific Dashboard user. Use the `user` scope for per-user secrets like per-user OAuth tokens, where different users might have different permissions. -# -# Related guide: [Store data between page reloads](https://stripe.com/docs/stripe-apps/store-auth-data-custom-objects). -# -# source://stripe//lib/stripe/resources/apps/secret.rb#15 -class Stripe::Apps::Secret < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - - class << self - # source://stripe//lib/stripe/resources/apps/secret.rb#21 - def delete_where(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/apps/secret.rb#30 - def find(params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/apps/secret.rb#19 -Stripe::Apps::Secret::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# AuthenticationError is raised when invalid credentials are used to connect -# to Stripe's servers. -# -# source://stripe//lib/stripe/errors.rb#57 -class Stripe::AuthenticationError < ::Stripe::StripeError; end - -# This is an object representing your Stripe balance. You can retrieve it to see -# the balance currently on your Stripe account. -# -# You can also retrieve the balance history, which contains a list of -# [transactions](https://stripe.com/docs/reporting/balance-transaction-types) that contributed to the balance -# (charges, payouts, and so forth). -# -# The available and pending amounts for each currency are broken down further by -# payment source types. -# -# Related guide: [Understanding Connect Account Balances](https://stripe.com/docs/connect/account-balances). -# -# source://stripe//lib/stripe/resources/balance.rb#16 -class Stripe::Balance < ::Stripe::SingletonAPIResource; end - -# source://stripe//lib/stripe/resources/balance.rb#17 -Stripe::Balance::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Balance transactions represent funds moving through your Stripe account. -# They're created for every type of transaction that comes into or flows out of your Stripe account balance. -# -# Related guide: [Balance Transaction Types](https://stripe.com/docs/reports/balance-transaction-types). -# -# source://stripe//lib/stripe/resources/balance_transaction.rb#9 -class Stripe::BalanceTransaction < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/balance_transaction.rb#12 -Stripe::BalanceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# These bank accounts are payment methods on `Customer` objects. -# -# On the other hand [External Accounts](https://stripe.com/docs/api#external_accounts) are transfer -# destinations on `Account` objects for [Custom accounts](https://stripe.com/docs/connect/custom-accounts). -# They can be bank accounts or debit cards as well, and are documented in the links above. -# -# Related guide: [Bank Debits and Transfers](https://stripe.com/docs/payments/bank-debits-transfers). -# -# source://stripe//lib/stripe/resources/bank_account.rb#12 -class Stripe::BankAccount < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/bank_account.rb#24 - def resource_url; end - - # source://stripe//lib/stripe/resources/bank_account.rb#19 - def verify(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/bank_account.rb#41 - def retrieve(_id, _opts = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/bank_account.rb#32 - def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/bank_account.rb#17 -Stripe::BankAccount::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/billing_portal/configuration.rb#5 -module Stripe::BillingPortal; end - -# A portal configuration describes the functionality and behavior of a portal session. -# -# source://stripe//lib/stripe/resources/billing_portal/configuration.rb#7 -class Stripe::BillingPortal::Configuration < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/billing_portal/configuration.rb#12 -Stripe::BillingPortal::Configuration::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# The Billing customer portal is a Stripe-hosted UI for subscription and -# billing management. -# -# A portal configuration describes the functionality and features that you -# want to provide to your customers through the portal. -# -# A portal session describes the instantiation of the customer portal for -# a particular customer. By visiting the session's URL, the customer -# can manage their subscriptions and billing details. For security reasons, -# sessions are short-lived and will expire if the customer does not visit the URL. -# Create sessions on-demand when customers intend to manage their subscriptions -# and billing details. -# -# Learn more in the [integration guide](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal). -# -# source://stripe//lib/stripe/resources/billing_portal/session.rb#20 -class Stripe::BillingPortal::Session < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create -end - -# source://stripe//lib/stripe/resources/billing_portal/session.rb#23 -Stripe::BillingPortal::Session::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# This is an object representing a capability for a Stripe account. -# -# Related guide: [Account capabilities](https://stripe.com/docs/connect/account-capabilities). -# -# source://stripe//lib/stripe/resources/capability.rb#8 -class Stripe::Capability < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/capability.rb#14 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/capability.rb#23 - def retrieve(_id, _opts = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/capability.rb#30 - def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/capability.rb#12 -Stripe::Capability::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# You can store multiple cards on a customer in order to charge the customer -# later. You can also store multiple debit cards on a recipient in order to -# transfer to those cards later. -# -# Related guide: [Card Payments with Sources](https://stripe.com/docs/sources/cards). -# -# source://stripe//lib/stripe/resources/card.rb#10 -class Stripe::Card < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/card.rb#17 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/card.rb#33 - def retrieve(_id, _opts = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/card.rb#25 - def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/card.rb#15 -Stripe::Card::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# CardError is raised when a user enters a card that can't be charged for -# some reason. -# -# source://stripe//lib/stripe/errors.rb#75 -class Stripe::CardError < ::Stripe::StripeError - # @return [CardError] a new instance of CardError - # - # source://stripe//lib/stripe/errors.rb#78 - def initialize(message, param, code: T.unsafe(nil), http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil)); end - - # Returns the value of attribute param. - # - # source://stripe//lib/stripe/errors.rb#76 - def param; end -end - -# A customer's `Cash balance` represents real funds. Customers can add funds to their cash balance by sending a bank transfer. These funds can be used for payment and can eventually be paid out to your bank account. -# -# source://stripe//lib/stripe/resources/cash_balance.rb#6 -class Stripe::CashBalance < ::Stripe::APIResource - # source://stripe//lib/stripe/resources/cash_balance.rb#9 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/cash_balance.rb#17 - def retrieve(_id, _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/cash_balance.rb#7 -Stripe::CashBalance::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# To charge a credit or a debit card, you create a `Charge` object. You can -# retrieve and refund individual charges as well as list all charges. Charges -# are identified by a unique, random ID. -# -# Related guide: [Accept a payment with the Charges API](https://stripe.com/docs/payments/accept-a-payment-charges). -# -# source://stripe//lib/stripe/resources/charge.rb#10 -class Stripe::Charge < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Search - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/charge.rb#18 - def capture(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/charge.rb#27 - def capture(charge, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/charge.rb#36 - def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/charge.rb#40 - def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end - end -end - -# source://stripe//lib/stripe/resources/charge.rb#16 -Stripe::Charge::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/checkout/session.rb#5 -module Stripe::Checkout; end - -# A Checkout Session represents your customer's session as they pay for -# one-time purchases or subscriptions through [Checkout](https://stripe.com/docs/payments/checkout) -# or [Payment Links](https://stripe.com/docs/payments/payment-links). We recommend creating a -# new Session each time your customer attempts to pay. -# -# Once payment is successful, the Checkout Session will contain a reference -# to the [Customer](https://stripe.com/docs/api/customers), and either the successful -# [PaymentIntent](https://stripe.com/docs/api/payment_intents) or an active -# [Subscription](https://stripe.com/docs/api/subscriptions). -# -# You can create a Checkout Session on your server and redirect to its URL -# to begin Checkout. -# -# Related guide: [Checkout Quickstart](https://stripe.com/docs/checkout/quickstart). -# -# source://stripe//lib/stripe/resources/checkout/session.rb#20 -class Stripe::Checkout::Session < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/checkout/session.rb#26 - def expire(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/checkout/session.rb#35 - def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/checkout/session.rb#44 - def expire(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/checkout/session.rb#53 - def list_line_items(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/checkout/session.rb#24 -Stripe::Checkout::Session::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Manages connections across multiple hosts which is useful because the -# library may connect to multiple hosts during a typical session (main API, -# Connect, Uploads). Ruby doesn't provide an easy way to make this happen -# easily, so this class is designed to track what we're connected to and -# manage the lifecycle of those connections. -# -# Note that this class in itself is *not* thread safe. We expect it to be -# instantiated once per thread. -# -# source://stripe//lib/stripe/connection_manager.rb#12 -class Stripe::ConnectionManager - # @return [ConnectionManager] a new instance of ConnectionManager - # - # source://stripe//lib/stripe/connection_manager.rb#20 - def initialize(config = T.unsafe(nil)); end - - # Finishes any active connections by closing their TCP connection and - # clears them from internal tracking. - # - # source://stripe//lib/stripe/connection_manager.rb#37 - def clear; end - - # Returns the value of attribute config. - # - # source://stripe//lib/stripe/connection_manager.rb#18 - def config; end - - # Gets a connection for a given URI. This is for internal use only as it's - # subject to change (we've moved between HTTP client schemes in the past - # and may do it again). - # - # `uri` is expected to be a string. - # - # source://stripe//lib/stripe/connection_manager.rb#51 - def connection_for(uri); end - - # Executes an HTTP request to the given URI with the given method. Also - # allows a request body, headers, and query string to be specified. - # - # @raise [ArgumentError] - # - # source://stripe//lib/stripe/connection_manager.rb#69 - def execute_request(method, uri, body: T.unsafe(nil), headers: T.unsafe(nil), query: T.unsafe(nil), &block); end - - # Timestamp (in seconds procured from the system's monotonic clock) - # indicating when the connection manager last made a request. This is used - # by `StripeClient` to determine whether a connection manager should be - # garbage collected or not. - # - # source://stripe//lib/stripe/connection_manager.rb#17 - def last_used; end - - private - - # `uri` should be a parsed `URI` object. - # - # source://stripe//lib/stripe/connection_manager.rb#141 - def create_connection(uri); end - - # `Net::HTTP` somewhat awkwardly requires each component of a proxy URI - # (host, port, etc.) rather than the URI itself. This method simply parses - # out those pieces to make passing them into a new connection a little less - # ugly. - # - # source://stripe//lib/stripe/connection_manager.rb#181 - def proxy_parts; end - - # source://stripe//lib/stripe/connection_manager.rb#190 - def warn_ssl_verify_none; end -end - -# Stripe needs to collect certain pieces of information about each account -# created. These requirements can differ depending on the account's country. The -# Country Specs API makes these rules available to your integration. -# -# You can also view the information from this API call as [an online -# guide](https://stripe.com/docs/connect/required-verification-information). -# -# source://stripe//lib/stripe/resources/country_spec.rb#11 -class Stripe::CountrySpec < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/country_spec.rb#14 -Stripe::CountrySpec::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A coupon contains information about a percent-off or amount-off discount you -# might want to apply to a customer. Coupons may be applied to [subscriptions](https://stripe.com/docs/api#subscriptions), [invoices](https://stripe.com/docs/api#invoices), -# [checkout sessions](https://stripe.com/docs/api/checkout/sessions), [quotes](https://stripe.com/docs/api#quotes), and more. Coupons do not work with conventional one-off [charges](https://stripe.com/docs/api#create_charge) or [payment intents](https://stripe.com/docs/api/payment_intents). -# -# source://stripe//lib/stripe/resources/coupon.rb#8 -class Stripe::Coupon < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/coupon.rb#14 -Stripe::Coupon::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Issue a credit note to adjust an invoice's amount after the invoice is finalized. -# -# Related guide: [Credit Notes](https://stripe.com/docs/billing/invoices/credit-notes). -# -# source://stripe//lib/stripe/resources/credit_note.rb#8 -class Stripe::CreditNote < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/credit_note.rb#15 - def void_credit_note(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/credit_note.rb#24 - def list_preview_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/credit_note.rb#33 - def preview(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/credit_note.rb#42 - def void_credit_note(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/credit_note.rb#13 -Stripe::CreditNote::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/credit_note_line_item.rb#5 -class Stripe::CreditNoteLineItem < ::Stripe::StripeObject; end - -# source://stripe//lib/stripe/resources/credit_note_line_item.rb#6 -Stripe::CreditNoteLineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# This object represents a customer of your business. It lets you create recurring charges and track payments that belong to the same customer. -# -# Related guide: [Save a card during payment](https://stripe.com/docs/payments/save-during-payment). -# -# source://stripe//lib/stripe/resources/customer.rb#8 -class Stripe::Customer < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Search - extend ::Stripe::APIOperations::Save::ClassMethods - extend ::Stripe::APIOperations::NestedResource - - # source://stripe//lib/stripe/resources/customer.rb#25 - def create_funding_instructions(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#34 - def delete_discount(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#43 - def list_payment_methods(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#52 - def retrieve_payment_method(payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_resource.rb#36 - def source=(value); end - - # source://stripe//lib/stripe/resources/customer.rb#138 - def test_helpers; end - - class << self - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def balance_transactions_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def cash_balance_transactions_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_balance_transaction(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#61 - def create_funding_instructions(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_source(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_tax_id(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#70 - def delete_discount(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#77 - def delete_source(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#77 - def delete_tax_id(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#77 - def detach_source(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_balance_transactions(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_cash_balance_transactions(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#79 - def list_payment_methods(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_sources(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_tax_ids(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_balance_transaction(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#120 - def retrieve_cash_balance(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_cash_balance_transaction(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#88 - def retrieve_payment_method(customer, payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_source(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_tax_id(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#112 - def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#116 - def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def sources_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def tax_ids_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#67 - def update_balance_transaction(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/customer.rb#129 - def update_cash_balance(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#67 - def update_source(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/customer.rb#16 -Stripe::Customer::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/customer.rb#142 -class Stripe::Customer::TestHelpers < ::Stripe::APIResourceTestHelpers - # source://stripe//lib/stripe/resources/customer.rb#154 - def fund_cash_balance(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/customer.rb#145 - def fund_cash_balance(customer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/customer.rb#143 -Stripe::Customer::TestHelpers::RESOURCE_CLASS = Stripe::Customer - -# Each customer has a [`balance`](https://stripe.com/docs/api/customers/object#customer_object-balance) value, -# which denotes a debit or credit that's automatically applied to their next invoice upon finalization. -# You may modify the value directly by using the [update customer API](https://stripe.com/docs/api/customers/update), -# or by creating a Customer Balance Transaction, which increments or decrements the customer's `balance` by the specified `amount`. -# -# Related guide: [Customer Balance](https://stripe.com/docs/billing/customer/balance) to learn more. -# -# source://stripe//lib/stripe/resources/customer_balance_transaction.rb#11 -class Stripe::CustomerBalanceTransaction < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/customer_balance_transaction.rb#17 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/customer_balance_transaction.rb#25 - def retrieve(_id, _opts = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/customer_balance_transaction.rb#31 - def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/customer_balance_transaction.rb#15 -Stripe::CustomerBalanceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Customers with certain payments enabled have a cash balance, representing funds that were paid -# by the customer to a merchant, but have not yet been allocated to a payment. Cash Balance Transactions -# represent when funds are moved into or out of this balance. This includes funding by the customer, allocation -# to payments, and refunds to the customer. -# -# source://stripe//lib/stripe/resources/customer_cash_balance_transaction.rb#9 -class Stripe::CustomerCashBalanceTransaction < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/customer_cash_balance_transaction.rb#12 -Stripe::CustomerCashBalanceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe.rb#54 -Stripe::DEFAULT_CA_BUNDLE_PATH = T.let(T.unsafe(nil), String) - -# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes). -# It contains information about when the discount began, when it will end, and what it is applied to. -# -# Related guide: [Applying Discounts to Subscriptions](https://stripe.com/docs/billing/subscriptions/discounts). -# -# source://stripe//lib/stripe/resources/discount.rb#9 -class Stripe::Discount < ::Stripe::StripeObject; end - -# source://stripe//lib/stripe/resources/discount.rb#10 -Stripe::Discount::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A dispute occurs when a customer questions your charge with their card issuer. -# When this happens, you're given the opportunity to respond to the dispute with -# evidence that shows that the charge is legitimate. You can find more -# information about the dispute process in our [Disputes and -# Fraud](https://stripe.com/docs/disputes) documentation. -# -# Related guide: [Disputes and Fraud](https://stripe.com/docs/disputes). -# -# source://stripe//lib/stripe/resources/dispute.rb#12 -class Stripe::Dispute < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/dispute.rb#18 - def close(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/dispute.rb#27 - def close(dispute, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/dispute.rb#16 -Stripe::Dispute::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/ephemeral_key.rb#5 -class Stripe::EphemeralKey < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - - class << self - # source://stripe//lib/stripe/resources/ephemeral_key.rb#11 - def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/ephemeral_key.rb#9 -Stripe::EphemeralKey::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Represents an error object as returned by the API. -# -# @see https://stripe.com/docs/api/errors -# -# source://stripe//lib/stripe/error_object.rb#7 -class Stripe::ErrorObject < ::Stripe::StripeObject - # For card errors, the ID of the failed charge. - # - # source://stripe//lib/stripe/error_object.rb#15 - def charge; end - - # For some errors that could be handled programmatically, a short string - # indicating the error code reported. - # - # source://stripe//lib/stripe/error_object.rb#21 - def code; end - - # For card errors resulting from a card issuer decline, a short string - # indicating the card issuer's reason for the decline if they provide one. - # - # source://stripe//lib/stripe/error_object.rb#27 - def decline_code; end - - # A URL to more information about the error code reported. - # - # source://stripe//lib/stripe/error_object.rb#32 - def doc_url; end - - # A human-readable message providing more details about the error. For card - # errors, these messages can be shown to your users. - # - # source://stripe//lib/stripe/error_object.rb#38 - def message; end - - # If the error is parameter-specific, the parameter related to the error. - # For example, you can use this to display a message near the correct form - # field. - # - # source://stripe//lib/stripe/error_object.rb#45 - def param; end - - # The PaymentIntent object for errors returned on a request involving a - # PaymentIntent. - # - # source://stripe//lib/stripe/error_object.rb#51 - def payment_intent; end - - # The PaymentMethod object for errors returned on a request involving a - # PaymentMethod. - # - # source://stripe//lib/stripe/error_object.rb#57 - def payment_method; end - - # The SetupIntent object for errors returned on a request involving a - # SetupIntent. - # - # source://stripe//lib/stripe/error_object.rb#63 - def setup_intent; end - - # The source object for errors returned on a request involving a source. - # - # source://stripe//lib/stripe/error_object.rb#68 - def source; end - - # The type of error returned. One of `api_error`, `card_error`, - # `idempotency_error`, or `invalid_request_error`. - # - # source://stripe//lib/stripe/error_object.rb#74 - def type; end -end - -# Events are our way of letting you know when something interesting happens in -# your account. When an interesting event occurs, we create a new `Event` -# object. For example, when a charge succeeds, we create a `charge.succeeded` -# event; and when an invoice payment attempt fails, we create an -# `invoice.payment_failed` event. Note that many API requests may cause multiple -# events to be created. For example, if you create a new subscription for a -# customer, you will receive both a `customer.subscription.created` event and a -# `charge.succeeded` event. -# -# Events occur when the state of another API resource changes. The state of that -# resource at the time of the change is embedded in the event's data field. For -# example, a `charge.succeeded` event will contain a charge, and an -# `invoice.payment_failed` event will contain an invoice. -# -# As with other API resources, you can use endpoints to retrieve an -# [individual event](https://stripe.com/docs/api#retrieve_event) or a [list of events](https://stripe.com/docs/api#list_events) -# from the API. We also have a separate -# [webhooks](http://en.wikipedia.org/wiki/Webhook) system for sending the -# `Event` objects directly to an endpoint on your server. Webhooks are managed -# in your -# [account settings](https://dashboard.stripe.com/account/webhooks), -# and our [Using Webhooks](https://stripe.com/docs/webhooks) guide will help you get set up. -# -# When using [Connect](https://stripe.com/docs/connect), you can also receive notifications of -# events that occur in connected accounts. For these events, there will be an -# additional `account` attribute in the received `Event` object. -# -# **NOTE:** Right now, access to events through the [Retrieve Event API](https://stripe.com/docs/api#retrieve_event) is -# guaranteed only for 30 days. -# -# source://stripe//lib/stripe/resources/event.rb#34 -class Stripe::Event < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/event.rb#37 -Stripe::Event::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# `Exchange Rate` objects allow you to determine the rates that Stripe is -# currently using to convert from one currency to another. Since this number is -# variable throughout the day, there are various reasons why you might want to -# know the current rate (for example, to dynamically price an item for a user -# with a default payment in a foreign currency). -# -# If you want a guarantee that the charge is made with a certain exchange rate -# you expect is current, you can pass in `exchange_rate` to charges endpoints. -# If the value is no longer up to date, the charge won't go through. Please -# refer to our [Exchange Rates API](https://stripe.com/docs/exchange-rates) guide for more -# details. -# -# source://stripe//lib/stripe/resources/exchange_rate.rb#16 -class Stripe::ExchangeRate < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/exchange_rate.rb#19 -Stripe::ExchangeRate::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# This is an object representing a file hosted on Stripe's servers. The -# file may have been uploaded by yourself using the [create file](https://stripe.com/docs/api#create_file) -# request (for example, when uploading dispute evidence) or it may have -# been created by Stripe (for example, the results of a [Sigma scheduled -# query](https://stripe.com/docs/api#scheduled_queries)). -# -# Related guide: [File Upload Guide](https://stripe.com/docs/file-upload). -# -# source://stripe//lib/stripe/resources/file.rb#12 -class Stripe::File < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - - class << self - # source://stripe//lib/stripe/resources/file.rb#28 - def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/file.rb#24 - def resource_url; end - end -end - -# source://stripe//lib/stripe/resources/file.rb#16 -Stripe::File::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# This resource can have two different object names. In latter API -# versions, only `file` is used, but since stripe-ruby may be used with -# any API version, we need to support deserializing the older -# `file_upload` object into the same class. -# -# source://stripe//lib/stripe/resources/file.rb#22 -Stripe::File::OBJECT_NAME_ALT = T.let(T.unsafe(nil), String) - -# To share the contents of a `File` object with non-Stripe users, you can -# create a `FileLink`. `FileLink`s contain a URL that can be used to -# retrieve the contents of the file without authentication. -# -# source://stripe//lib/stripe/resources/file_link.rb#8 -class Stripe::FileLink < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/file_link.rb#13 -Stripe::FileLink::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/financial_connections/account.rb#5 -module Stripe::FinancialConnections; end - -# A Financial Connections Account represents an account that exists outside of Stripe, to which you have been granted some degree of access. -# -# source://stripe//lib/stripe/resources/financial_connections/account.rb#7 -class Stripe::FinancialConnections::Account < ::Stripe::APIResource - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/financial_connections/account.rb#12 - def disconnect(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/financial_connections/account.rb#21 - def list_owners(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/financial_connections/account.rb#30 - def refresh_account(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/financial_connections/account.rb#39 - def disconnect(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/financial_connections/account.rb#48 - def list_owners(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/financial_connections/account.rb#57 - def refresh_account(account, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/financial_connections/account.rb#10 -Stripe::FinancialConnections::Account::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/financial_connections/account_owner.rb#6 -class Stripe::FinancialConnections::AccountOwner < ::Stripe::StripeObject; end - -# source://stripe//lib/stripe/resources/financial_connections/account_owner.rb#7 -Stripe::FinancialConnections::AccountOwner::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Describes a snapshot of the owners of an account at a particular point in time. -# -# source://stripe//lib/stripe/resources/financial_connections/account_ownership.rb#7 -class Stripe::FinancialConnections::AccountOwnership < ::Stripe::StripeObject; end - -# source://stripe//lib/stripe/resources/financial_connections/account_ownership.rb#8 -Stripe::FinancialConnections::AccountOwnership::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Financial Connections Session is the secure way to programmatically launch the client-side Stripe.js modal that lets your users link their accounts. -# -# source://stripe//lib/stripe/resources/financial_connections/session.rb#7 -class Stripe::FinancialConnections::Session < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create -end - -# source://stripe//lib/stripe/resources/financial_connections/session.rb#10 -Stripe::FinancialConnections::Session::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Each customer has a [`balance`](https://stripe.com/docs/api/customers/object#customer_object-balance) that is -# automatically applied to future invoices and payments using the `customer_balance` payment method. -# Customers can fund this balance by initiating a bank transfer to any account in the -# `financial_addresses` field. -# Related guide: [Customer Balance - Funding Instructions](https://stripe.com/docs/payments/customer-balance/funding-instructions) to learn more -# -# source://stripe//lib/stripe/resources/funding_instructions.rb#10 -class Stripe::FundingInstructions < ::Stripe::APIResource - # source://stripe//lib/stripe/resources/funding_instructions.rb#13 - def resource_url; end -end - -# source://stripe//lib/stripe/resources/funding_instructions.rb#11 -Stripe::FundingInstructions::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# IdempotencyError is raised in cases where an idempotency key was used -# improperly. -# -# source://stripe//lib/stripe/errors.rb#89 -class Stripe::IdempotencyError < ::Stripe::StripeError; end - -# source://stripe//lib/stripe/resources/identity/verification_report.rb#5 -module Stripe::Identity; end - -# A VerificationReport is the result of an attempt to collect and verify data from a user. -# The collection of verification checks performed is determined from the `type` and `options` -# parameters used. You can find the result of each verification check performed in the -# appropriate sub-resource: `document`, `id_number`, `selfie`. -# -# Each VerificationReport contains a copy of any data collected by the user as well as -# reference IDs which can be used to access collected images through the [FileUpload](https://stripe.com/docs/api/files) -# API. To configure and create VerificationReports, use the -# [VerificationSession](https://stripe.com/docs/api/identity/verification_sessions) API. -# -# Related guides: [Accessing verification results](https://stripe.com/docs/identity/verification-sessions#results). -# -# source://stripe//lib/stripe/resources/identity/verification_report.rb#17 -class Stripe::Identity::VerificationReport < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/identity/verification_report.rb#20 -Stripe::Identity::VerificationReport::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A VerificationSession guides you through the process of collecting and verifying the identities -# of your users. It contains details about the type of verification, such as what [verification -# check](https://stripe.com/docs/identity/verification-checks) to perform. Only create one VerificationSession for -# each verification in your system. -# -# A VerificationSession transitions through [multiple -# statuses](https://stripe.com/docs/identity/how-sessions-work) throughout its lifetime as it progresses through -# the verification flow. The VerificationSession contains the user's verified data after -# verification checks are complete. -# -# Related guide: [The Verification Sessions API](https://stripe.com/docs/identity/verification-sessions) -# -# source://stripe//lib/stripe/resources/identity/verification_session.rb#17 -class Stripe::Identity::VerificationSession < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/identity/verification_session.rb#24 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/identity/verification_session.rb#33 - def redact(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/identity/verification_session.rb#42 - def cancel(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/identity/verification_session.rb#51 - def redact(session, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/identity/verification_session.rb#22 -Stripe::Identity::VerificationSession::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/instrumentation.rb#4 -class Stripe::Instrumentation - class << self - # Returns true if there are a non-zero number of subscribers on the given - # topic, and false otherwise. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/instrumentation.rb#100 - def any_subscribers?(topic); end - - # source://stripe//lib/stripe/instrumentation.rb#113 - def notify(topic, event); end - - # source://stripe//lib/stripe/instrumentation.rb#104 - def subscribe(topic, name = T.unsafe(nil), &block); end - - # source://stripe//lib/stripe/instrumentation.rb#109 - def unsubscribe(topic, name); end - - private - - # source://stripe//lib/stripe/instrumentation.rb#117 - def subscribers; end - end -end - -# Event emitted on `request_begin` callback. -# -# source://stripe//lib/stripe/instrumentation.rb#6 -class Stripe::Instrumentation::RequestBeginEvent - # @return [RequestBeginEvent] a new instance of RequestBeginEvent - # - # source://stripe//lib/stripe/instrumentation.rb#20 - def initialize(method:, path:, user_data:); end - - # Returns the value of attribute method. - # - # source://stripe//lib/stripe/instrumentation.rb#7 - def method; end - - # Returns the value of attribute path. - # - # source://stripe//lib/stripe/instrumentation.rb#8 - def path; end - - # Arbitrary user-provided data in the form of a Ruby hash that's passed - # from subscribers on `request_begin` to subscribers on `request_end`. - # `request_begin` subscribers can set keys which will then be available - # in `request_end`. - # - # Note that all subscribers of `request_begin` share the same object, so - # they must be careful to set unique keys so as to not conflict with data - # set by other subscribers. - # - # source://stripe//lib/stripe/instrumentation.rb#18 - def user_data; end -end - -# source://stripe//lib/stripe/instrumentation.rb#64 -class Stripe::Instrumentation::RequestContext - # @return [RequestContext] a new instance of RequestContext - # - # source://stripe//lib/stripe/instrumentation.rb#72 - def initialize(duration:, context:, header:); end - - # Returns the value of attribute body. - # - # source://stripe//lib/stripe/instrumentation.rb#69 - def body; end - - # Returns the value of attribute duration. - # - # source://stripe//lib/stripe/instrumentation.rb#65 - def duration; end - - # Returns the value of attribute header. - # - # source://stripe//lib/stripe/instrumentation.rb#70 - def header; end - - # Returns the value of attribute method. - # - # source://stripe//lib/stripe/instrumentation.rb#66 - def method; end - - # Returns the value of attribute path. - # - # source://stripe//lib/stripe/instrumentation.rb#67 - def path; end - - # Returns the value of attribute request_id. - # - # source://stripe//lib/stripe/instrumentation.rb#68 - def request_id; end -end - -# Event emitted on `request_end` callback. -# -# source://stripe//lib/stripe/instrumentation.rb#29 -class Stripe::Instrumentation::RequestEndEvent - # @return [RequestEndEvent] a new instance of RequestEndEvent - # - # source://stripe//lib/stripe/instrumentation.rb#47 - def initialize(request_context:, response_context:, num_retries:, user_data: T.unsafe(nil)); end - - # Returns the value of attribute duration. - # - # source://stripe//lib/stripe/instrumentation.rb#30 - def duration; end - - # Returns the value of attribute http_status. - # - # source://stripe//lib/stripe/instrumentation.rb#31 - def http_status; end - - # Returns the value of attribute method. - # - # source://stripe//lib/stripe/instrumentation.rb#32 - def method; end - - # Returns the value of attribute num_retries. - # - # source://stripe//lib/stripe/instrumentation.rb#33 - def num_retries; end - - # Returns the value of attribute path. - # - # source://stripe//lib/stripe/instrumentation.rb#34 - def path; end - - # Returns the value of attribute request_body. - # - # source://stripe//lib/stripe/instrumentation.rb#39 - def request_body; end - - # Returns the value of attribute request_header. - # - # source://stripe//lib/stripe/instrumentation.rb#38 - def request_header; end - - # Returns the value of attribute request_id. - # - # source://stripe//lib/stripe/instrumentation.rb#35 - def request_id; end - - # Returns the value of attribute response_body. - # - # source://stripe//lib/stripe/instrumentation.rb#37 - def response_body; end - - # Returns the value of attribute response_header. - # - # source://stripe//lib/stripe/instrumentation.rb#36 - def response_header; end - - # Arbitrary user-provided data in the form of a Ruby hash that's passed - # from subscribers on `request_begin` to subscribers on `request_end`. - # `request_begin` subscribers can set keys which will then be available - # in `request_end`. - # - # source://stripe//lib/stripe/instrumentation.rb#45 - def user_data; end -end - -# This class was renamed for consistency. This alias is here for backwards -# compatibility. -# -# source://stripe//lib/stripe/instrumentation.rb#96 -Stripe::Instrumentation::RequestEvent = Stripe::Instrumentation::RequestEndEvent - -# source://stripe//lib/stripe/instrumentation.rb#82 -class Stripe::Instrumentation::ResponseContext - # @return [ResponseContext] a new instance of ResponseContext - # - # source://stripe//lib/stripe/instrumentation.rb#87 - def initialize(http_status:, response:); end - - # Returns the value of attribute body. - # - # source://stripe//lib/stripe/instrumentation.rb#84 - def body; end - - # Returns the value of attribute header. - # - # source://stripe//lib/stripe/instrumentation.rb#85 - def header; end - - # Returns the value of attribute http_status. - # - # source://stripe//lib/stripe/instrumentation.rb#83 - def http_status; end -end - -# InvalidRequestError is raised when a request is initiated with invalid -# parameters. -# -# source://stripe//lib/stripe/errors.rb#94 -class Stripe::InvalidRequestError < ::Stripe::StripeError - # @return [InvalidRequestError] a new instance of InvalidRequestError - # - # source://stripe//lib/stripe/errors.rb#97 - def initialize(message, param, http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil), code: T.unsafe(nil)); end - - # Returns the value of attribute param. - # - # source://stripe//lib/stripe/errors.rb#95 - def param; end - - # Sets the attribute param - # - # @param value the value to set the attribute param to. - # - # source://stripe//lib/stripe/errors.rb#95 - def param=(_arg0); end -end - -# Invoices are statements of amounts owed by a customer, and are either -# generated one-off, or generated periodically from a subscription. -# -# They contain [invoice items](https://stripe.com/docs/api#invoiceitems), and proration adjustments -# that may be caused by subscription upgrades/downgrades (if necessary). -# -# If your invoice is configured to be billed through automatic charges, -# Stripe automatically finalizes your invoice and attempts payment. Note -# that finalizing the invoice, -# [when automatic](https://stripe.com/docs/billing/invoices/workflow/#auto_advance), does -# not happen immediately as the invoice is created. Stripe waits -# until one hour after the last webhook was successfully sent (or the last -# webhook timed out after failing). If you (and the platforms you may have -# connected to) have no webhooks configured, Stripe waits one hour after -# creation to finalize the invoice. -# -# If your invoice is configured to be billed by sending an email, then based on your -# [email settings](https://dashboard.stripe.com/account/billing/automatic), -# Stripe will email the invoice to your customer and await payment. These -# emails can contain a link to a hosted page to pay the invoice. -# -# Stripe applies any customer credit on the account before determining the -# amount due for the invoice (i.e., the amount that will be actually -# charged). If the amount due for the invoice is less than Stripe's [minimum allowed charge -# per currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts), the -# invoice is automatically marked paid, and we add the amount due to the -# customer's credit balance which is applied to the next invoice. -# -# More details on the customer's credit balance are -# [here](https://stripe.com/docs/billing/customer/balance). -# -# Related guide: [Send Invoices to Customers](https://stripe.com/docs/billing/invoices/sending). -# -# source://stripe//lib/stripe/resources/invoice.rb#37 -class Stripe::Invoice < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Search - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/invoice.rb#46 - def finalize_invoice(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#55 - def mark_uncollectible(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#64 - def pay(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#73 - def send_invoice(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#82 - def void_invoice(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/invoice.rb#91 - def finalize_invoice(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#100 - def list_upcoming_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#109 - def mark_uncollectible(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#118 - def pay(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#154 - def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#158 - def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end - - # source://stripe//lib/stripe/resources/invoice.rb#127 - def send_invoice(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#136 - def upcoming(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/invoice.rb#145 - def void_invoice(invoice, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/invoice.rb#44 -Stripe::Invoice::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Invoice Items represent the component lines of an [invoice](https://stripe.com/docs/api/invoices). An invoice item is added to an -# invoice by creating or updating it with an `invoice` field, at which point it will be included as -# [an invoice line item](https://stripe.com/docs/api/invoices/line_item) within -# [invoice.lines](https://stripe.com/docs/api/invoices/object#invoice_object-lines). -# -# Invoice Items can be created before you are ready to actually send the invoice. This can be particularly useful when combined -# with a [subscription](https://stripe.com/docs/api/subscriptions). Sometimes you want to add a charge or credit to a customer, but actually charge -# or credit the customer's card only at the end of a regular billing cycle. This is useful for combining several charges -# (to minimize per-transaction fees), or for having Stripe tabulate your usage-based billing totals. -# -# Related guides: [Integrate with the Invoicing API](https://stripe.com/docs/invoicing/integration), [Subscription Invoices](https://stripe.com/docs/billing/invoices/subscription#adding-upcoming-invoice-items). -# -# source://stripe//lib/stripe/resources/invoice_item.rb#16 -class Stripe::InvoiceItem < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/invoice_item.rb#22 -Stripe::InvoiceItem::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/invoice_line_item.rb#5 -class Stripe::InvoiceLineItem < ::Stripe::StripeObject; end - -# source://stripe//lib/stripe/resources/invoice_line_item.rb#6 -Stripe::InvoiceLineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/issuing/authorization.rb#5 -module Stripe::Issuing; end - -# When an [issued card](https://stripe.com/docs/issuing) is used to make a purchase, an Issuing `Authorization` -# object is created. [Authorizations](https://stripe.com/docs/issuing/purchases/authorizations) must be approved for the -# purchase to be completed successfully. -# -# Related guide: [Issued Card Authorizations](https://stripe.com/docs/issuing/purchases/authorizations). -# -# source://stripe//lib/stripe/resources/issuing/authorization.rb#11 -class Stripe::Issuing::Authorization < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/issuing/authorization.rb#17 - def approve(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/authorization.rb#26 - def decline(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/issuing/authorization.rb#35 - def approve(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/authorization.rb#44 - def decline(authorization, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/issuing/authorization.rb#15 -Stripe::Issuing::Authorization::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# You can [create physical or virtual cards](https://stripe.com/docs/issuing/cards) that are issued to cardholders. -# -# source://stripe//lib/stripe/resources/issuing/card.rb#7 -class Stripe::Issuing::Card < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/issuing/card.rb#14 - def test_helpers; end -end - -# source://stripe//lib/stripe/resources/issuing/card.rb#12 -Stripe::Issuing::Card::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/issuing/card.rb#18 -class Stripe::Issuing::Card::TestHelpers < ::Stripe::APIResourceTestHelpers - # source://stripe//lib/stripe/resources/issuing/card.rb#57 - def deliver_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/card.rb#66 - def fail_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/card.rb#75 - def return_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/card.rb#84 - def ship_card(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/issuing/card.rb#21 - def deliver_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/card.rb#30 - def fail_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/card.rb#39 - def return_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/issuing/card.rb#48 - def ship_card(card, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/issuing/card.rb#19 -Stripe::Issuing::Card::TestHelpers::RESOURCE_CLASS = Stripe::Issuing::Card - -# An Issuing `Cardholder` object represents an individual or business entity who is [issued](https://stripe.com/docs/issuing) cards. -# -# Related guide: [How to create a Cardholder](https://stripe.com/docs/issuing/cards#create-cardholder) -# -# source://stripe//lib/stripe/resources/issuing/cardholder.rb#9 -class Stripe::Issuing::Cardholder < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/issuing/cardholder.rb#14 -Stripe::Issuing::Cardholder::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# As a [card issuer](https://stripe.com/docs/issuing), you can dispute transactions that the cardholder does not recognize, suspects to be fraudulent, or has other issues with. -# -# Related guide: [Disputing Transactions](https://stripe.com/docs/issuing/purchases/disputes) -# -# source://stripe//lib/stripe/resources/issuing/dispute.rb#9 -class Stripe::Issuing::Dispute < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/issuing/dispute.rb#16 - def submit(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/issuing/dispute.rb#25 - def submit(dispute, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/issuing/dispute.rb#14 -Stripe::Issuing::Dispute::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Any use of an [issued card](https://stripe.com/docs/issuing) that results in funds entering or leaving -# your Stripe account, such as a completed purchase or refund, is represented by an Issuing -# `Transaction` object. -# -# Related guide: [Issued Card Transactions](https://stripe.com/docs/issuing/purchases/transactions). -# -# source://stripe//lib/stripe/resources/issuing/transaction.rb#11 -class Stripe::Issuing::Transaction < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/issuing/transaction.rb#15 -Stripe::Issuing::Transaction::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# map to the same values as the standard library's logger -# -# source://stripe//lib/stripe.rb#57 -Stripe::LEVEL_DEBUG = T.let(T.unsafe(nil), Integer) - -# source://stripe//lib/stripe.rb#58 -Stripe::LEVEL_ERROR = T.let(T.unsafe(nil), Integer) - -# source://stripe//lib/stripe.rb#59 -Stripe::LEVEL_INFO = T.let(T.unsafe(nil), Integer) - -# A line item. -# -# source://stripe//lib/stripe/resources/line_item.rb#6 -class Stripe::LineItem < ::Stripe::APIResource; end - -# source://stripe//lib/stripe/resources/line_item.rb#7 -Stripe::LineItem::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/list_object.rb#4 -class Stripe::ListObject < ::Stripe::StripeObject - include ::Stripe::APIOperations::List - include ::Stripe::APIOperations::Request - include ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Request::ClassMethods - - # @return [ListObject] a new instance of ListObject - # - # source://stripe//lib/stripe/list_object.rb#24 - def initialize(*args); end - - # source://stripe//lib/stripe/list_object.rb#29 - def [](key); end - - # Iterates through each resource in all pages, making additional fetches to - # the API as necessary. - # - # The default iteration direction is forwards according to Stripe's API - # "natural" ordering direction -- newer objects first, and moving towards - # older objects. - # - # However, if the initial list object was fetched using an `ending_before` - # cursor (and only `ending_before`, `starting_after` cannot also be - # included), the method assumes that the user is trying to iterate - # backwards compared to natural ordering and returns results that way -- - # older objects first, and moving towards newer objects. - # - # Note that this method will make as many API calls as necessary to fetch - # all resources. For more granular control, please see +each+ and - # +next_page+. - # - # source://stripe//lib/stripe/list_object.rb#67 - def auto_paging_each(&blk); end - - # Iterates through each resource in the page represented by the current - # `ListObject`. - # - # Note that this method makes no effort to fetch a new page when it gets to - # the end of the current page's resources. See also +auto_paging_each+. - # - # source://stripe//lib/stripe/list_object.rb#47 - def each(&blk); end - - # Returns true if the page object contains no elements. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/list_object.rb#89 - def empty?; end - - # This accessor allows a `ListObject` to inherit various filters that were - # given to a predecessor. This allows for things like consistent limits, - # expansions, and predicates as a user pages through resources. - # - # source://stripe//lib/stripe/list_object.rb#15 - def filters; end - - # This accessor allows a `ListObject` to inherit various filters that were - # given to a predecessor. This allows for things like consistent limits, - # expansions, and predicates as a user pages through resources. - # - # source://stripe//lib/stripe/list_object.rb#15 - def filters=(_arg0); end - - # Fetches the next page in the resource list (if there is one). - # - # This method will try to respect the limit of the current page. If none - # was given, the default limit will be fetched again. - # - # source://stripe//lib/stripe/list_object.rb#104 - def next_page(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # Fetches the previous page in the resource list (if there is one). - # - # This method will try to respect the limit of the current page. If none - # was given, the default limit will be fetched again. - # - # source://stripe//lib/stripe/list_object.rb#118 - def previous_page(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/list_object.rb#128 - def resource_url; end - - # source://stripe//lib/stripe/list_object.rb#93 - def retrieve(id, opts = T.unsafe(nil)); end - - # Iterates through each resource in the page represented by the current - # `ListObject` in reverse. - # - # source://stripe//lib/stripe/list_object.rb#135 - def reverse_each(&blk); end - - class << self - # An empty list object. This is returned from +next+ when we know that - # there isn't a next page in order to replicate the behavior of the API - # when it attempts to return a page beyond the last. - # - # source://stripe//lib/stripe/list_object.rb#20 - def empty_list(opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/list_object.rb#10 -Stripe::ListObject::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/login_link.rb#5 -class Stripe::LoginLink < ::Stripe::APIResource - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/login_link.rb#8 - def retrieve(_id, _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/login_link.rb#6 -Stripe::LoginLink::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Mandate is a record of the permission a customer has given you to debit their payment method. -# -# source://stripe//lib/stripe/resources/mandate.rb#6 -class Stripe::Mandate < ::Stripe::APIResource; end - -# source://stripe//lib/stripe/resources/mandate.rb#7 -Stripe::Mandate::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Encodes parameters into a `multipart/form-data` payload as described by RFC -# 2388: -# -# https://tools.ietf.org/html/rfc2388 -# -# This is most useful for transferring file-like objects. -# -# Parameters should be added with `#encode`. When ready, use `#body` to get -# the encoded result and `#content_type` to get the value that should be -# placed in the `Content-Type` header of a subsequent request (which includes -# a boundary value). -# -# source://stripe//lib/stripe/multipart_encoder.rb#18 -class Stripe::MultipartEncoder - # Initializes a new multipart encoder. - # - # @return [MultipartEncoder] a new instance of MultipartEncoder - # - # source://stripe//lib/stripe/multipart_encoder.rb#37 - def initialize; end - - # Gets the encoded body. `#close` must be called first. - # - # source://stripe//lib/stripe/multipart_encoder.rb#52 - def body; end - - # Gets the object's randomly generated boundary string. - # - # source://stripe//lib/stripe/multipart_encoder.rb#34 - def boundary; end - - # Finalizes the object by writing the final boundary. - # - # source://stripe//lib/stripe/multipart_encoder.rb#59 - def close; end - - # Gets the value including boundary that should be put into a multipart - # request's `Content-Type`. - # - # source://stripe//lib/stripe/multipart_encoder.rb#72 - def content_type; end - - # Encodes a set of parameters to the body. - # - # Note that parameters are expected to be a hash, but a "flat" hash such - # that complex substructures like hashes and arrays have already been - # appropriately Stripe-encoded. Pass a complex structure through - # `Util.flatten_params` first before handing it off to this method. - # - # source://stripe//lib/stripe/multipart_encoder.rb#82 - def encode(params); end - - private - - # Escapes double quotes so that the given value can be used in a - # double-quoted string and replaces any linebreak characters with spaces. - # - # source://stripe//lib/stripe/multipart_encoder.rb#104 - def escape(str); end - - # source://stripe//lib/stripe/multipart_encoder.rb#108 - def write_field(name, data, filename:); end - - class << self - # A shortcut for encoding a single set of parameters and finalizing a - # result. - # - # Returns an encoded body and the value that should be set in the content - # type header of a subsequent request. - # - # source://stripe//lib/stripe/multipart_encoder.rb#26 - def encode(params); end - end -end - -# source://stripe//lib/stripe/multipart_encoder.rb#19 -Stripe::MultipartEncoder::MULTIPART_FORM_DATA = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/errors.rb#128 -module Stripe::OAuth - class << self - # source://stripe//lib/stripe/oauth.rb#31 - def authorize_url(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/oauth.rb#55 - def deauthorize(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/oauth.rb#17 - def get_client_id(params = T.unsafe(nil)); end - - # source://stripe//lib/stripe/oauth.rb#45 - def token(params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# InvalidClientError is raised when the client doesn't belong to you, or -# the API key mode (live or test) doesn't match the client mode. Or the -# stripe_user_id doesn't exist or isn't connected to your application. -# -# source://stripe//lib/stripe/errors.rb#148 -class Stripe::OAuth::InvalidClientError < ::Stripe::OAuth::OAuthError; end - -# InvalidGrantError is raised when a specified code doesn't exist, is -# expired, has been used, or doesn't belong to you; a refresh token doesn't -# exist, or doesn't belong to you; or if an API key's mode (live or test) -# doesn't match the mode of a code or refresh token. -# -# source://stripe//lib/stripe/errors.rb#155 -class Stripe::OAuth::InvalidGrantError < ::Stripe::OAuth::OAuthError; end - -# InvalidRequestError is raised when a code, refresh token, or grant type -# parameter is not provided, but was required. -# -# source://stripe//lib/stripe/errors.rb#160 -class Stripe::OAuth::InvalidRequestError < ::Stripe::OAuth::OAuthError; end - -# InvalidScopeError is raised when an invalid scope parameter is provided. -# -# source://stripe//lib/stripe/errors.rb#164 -class Stripe::OAuth::InvalidScopeError < ::Stripe::OAuth::OAuthError; end - -# OAuthError is raised when the OAuth API returns an error. -# -# source://stripe//lib/stripe/errors.rb#130 -class Stripe::OAuth::OAuthError < ::Stripe::StripeError - # @return [OAuthError] a new instance of OAuthError - # - # source://stripe//lib/stripe/errors.rb#131 - def initialize(code, description, http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil)); end - - # source://stripe//lib/stripe/errors.rb#138 - def construct_error_object; end -end - -# source://stripe//lib/stripe/oauth.rb#5 -module Stripe::OAuth::OAuthOperations - extend ::Stripe::APIOperations::Request::ClassMethods - - class << self - # source://stripe//lib/stripe/oauth.rb#8 - def execute_resource_request(method, url, params, opts); end - end -end - -# UnsupportedGrantTypeError is raised when an unuspported grant type -# parameter is specified. -# -# source://stripe//lib/stripe/errors.rb#169 -class Stripe::OAuth::UnsupportedGrantTypeError < ::Stripe::OAuth::OAuthError; end - -# UnsupportedResponseTypeError is raised when an unsupported response type -# parameter is specified. -# -# source://stripe//lib/stripe/errors.rb#174 -class Stripe::OAuth::UnsupportedResponseTypeError < ::Stripe::OAuth::OAuthError; end - -# Represents on OAuth error returned by the OAuth API. -# -# @see https://stripe.com/docs/connect/oauth-reference#post-token-errors -# -# source://stripe//lib/stripe/error_object.rb#82 -class Stripe::OAuthErrorObject < ::Stripe::StripeObject - # A unique error code per error type. - # - # source://stripe//lib/stripe/error_object.rb#84 - def error; end - - # A human readable description of the error. - # - # source://stripe//lib/stripe/error_object.rb#89 - def error_description; end -end - -# source://stripe//lib/stripe/object_types.rb#7 -module Stripe::ObjectTypes - class << self - # source://stripe//lib/stripe/object_types.rb#8 - def object_names_to_classes; end - end -end - -# A PaymentIntent guides you through the process of collecting a payment from your customer. -# We recommend that you create exactly one PaymentIntent for each order or -# customer session in your system. You can reference the PaymentIntent later to -# see the history of payment attempts for a particular session. -# -# A PaymentIntent transitions through -# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses) -# throughout its lifetime as it interfaces with Stripe.js to perform -# authentication flows and ultimately creates at most one successful charge. -# -# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents). -# -# source://stripe//lib/stripe/resources/payment_intent.rb#16 -class Stripe::PaymentIntent < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Search - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/payment_intent.rb#24 - def apply_customer_balance(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#33 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#42 - def capture(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#51 - def confirm(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#60 - def increment_authorization(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#69 - def verify_microdeposits(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/payment_intent.rb#78 - def apply_customer_balance(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#87 - def cancel(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#96 - def capture(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#105 - def confirm(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#114 - def increment_authorization(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#132 - def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#136 - def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end - - # source://stripe//lib/stripe/resources/payment_intent.rb#123 - def verify_microdeposits(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/payment_intent.rb#22 -Stripe::PaymentIntent::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A payment link is a shareable URL that will take your customers to a hosted payment page. A payment link can be shared and used multiple times. -# -# When a customer opens a payment link it will open a new [checkout session](https://stripe.com/docs/api/checkout/sessions) to render the payment page. You can use [checkout session events](https://stripe.com/docs/api/events/types#event_types-checkout.session.completed) to track payments through payment links. -# -# Related guide: [Payment Links API](https://stripe.com/docs/payment-links) -# -# source://stripe//lib/stripe/resources/payment_link.rb#10 -class Stripe::PaymentLink < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/payment_link.rb#17 - def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/payment_link.rb#26 - def list_line_items(payment_link, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/payment_link.rb#15 -Stripe::PaymentLink::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# PaymentMethod objects represent your customer's payment instruments. -# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to -# Customer objects to store instrument details for future payments. -# -# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios). -# -# source://stripe//lib/stripe/resources/payment_method.rb#10 -class Stripe::PaymentMethod < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/payment_method.rb#17 - def attach(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_method.rb#26 - def detach(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/payment_method.rb#35 - def attach(payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payment_method.rb#44 - def detach(payment_method, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/payment_method.rb#15 -Stripe::PaymentMethod::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A `Payout` object is created when you receive funds from Stripe, or when you -# initiate a payout to either a bank account or debit card of a [connected -# Stripe account](https://stripe.com/docs/connect/bank-debit-card-payouts). You can retrieve individual payouts, -# as well as list all payouts. Payouts are made on [varying -# schedules](https://stripe.com/docs/connect/manage-payout-schedule), depending on your country and -# industry. -# -# Related guide: [Receiving Payouts](https://stripe.com/docs/payouts). -# -# source://stripe//lib/stripe/resources/payout.rb#13 -class Stripe::Payout < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/payout.rb#20 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payout.rb#29 - def reverse(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/payout.rb#38 - def cancel(payout, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/payout.rb#47 - def reverse(payout, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/payout.rb#18 -Stripe::Payout::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# PermissionError is raised in cases where access was attempted on a resource -# that wasn't allowed. -# -# source://stripe//lib/stripe/errors.rb#108 -class Stripe::PermissionError < ::Stripe::StripeError; end - -# This is an object representing a person associated with a Stripe account. -# -# A platform cannot access a Standard or Express account's persons after the account starts onboarding, such as after generating an account link for the account. -# See the [Standard onboarding](https://stripe.com/docs/connect/standard-accounts) or [Express onboarding documentation](https://stripe.com/docs/connect/express-accounts) for information about platform pre-filling and account onboarding steps. -# -# Related guide: [Handling Identity Verification with the API](https://stripe.com/docs/connect/identity-verification-api#person-information). -# -# source://stripe//lib/stripe/resources/person.rb#11 -class Stripe::Person < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/person.rb#17 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/person.rb#25 - def retrieve(_id, _opts = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/person.rb#31 - def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/person.rb#15 -Stripe::Person::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# You can now model subscriptions more flexibly using the [Prices API](https://stripe.com/docs/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration. -# -# Plans define the base price, currency, and billing cycle for recurring purchases of products. -# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and plans help you track pricing. Different physical goods or levels of service should be represented by products, and pricing options should be represented by plans. This approach lets you change prices without having to change your provisioning scheme. -# -# For example, you might have a single "gold" product that has plans for $10/month, $100/year, €9/month, and €90/year. -# -# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/products-prices/overview). -# -# source://stripe//lib/stripe/resources/plan.rb#13 -class Stripe::Plan < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/plan.rb#19 -Stripe::Plan::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Prices define the unit cost, currency, and (optional) billing cycle for both recurring and one-time purchases of products. -# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and prices help you track payment terms. Different physical goods or levels of service should be represented by products, and pricing options should be represented by prices. This approach lets you change prices without having to change your provisioning scheme. -# -# For example, you might have a single "gold" product that has prices for $10/month, $100/year, and €9 once. -# -# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), [create an invoice](https://stripe.com/docs/billing/invoices/create), and more about [products and prices](https://stripe.com/docs/products-prices/overview). -# -# source://stripe//lib/stripe/resources/price.rb#11 -class Stripe::Price < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Search - extend ::Stripe::APIOperations::Save::ClassMethods - - class << self - # source://stripe//lib/stripe/resources/price.rb#19 - def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/price.rb#23 - def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end - end -end - -# source://stripe//lib/stripe/resources/price.rb#17 -Stripe::Price::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Products describe the specific goods or services you offer to your customers. -# For example, you might offer a Standard and Premium version of your goods or service; each version would be a separate Product. -# They can be used in conjunction with [Prices](https://stripe.com/docs/api#prices) to configure pricing in Payment Links, Checkout, and Subscriptions. -# -# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), -# [share a Payment Link](https://stripe.com/docs/payment-links), -# [accept payments with Checkout](https://stripe.com/docs/payments/accept-a-payment#create-product-prices-upfront), -# and more about [Products and Prices](https://stripe.com/docs/products-prices/overview) -# -# source://stripe//lib/stripe/resources/product.rb#13 -class Stripe::Product < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Search - extend ::Stripe::APIOperations::Save::ClassMethods - - class << self - # source://stripe//lib/stripe/resources/product.rb#22 - def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/product.rb#26 - def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end - end -end - -# source://stripe//lib/stripe/resources/product.rb#20 -Stripe::Product::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Promotion Code represents a customer-redeemable code for a [coupon](https://stripe.com/docs/api#coupons). It can be used to -# create multiple codes for a single coupon. -# -# source://stripe//lib/stripe/resources/promotion_code.rb#7 -class Stripe::PromotionCode < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/promotion_code.rb#12 -Stripe::PromotionCode::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Quote is a way to model prices that you'd like to provide to a customer. -# Once accepted, it will automatically create an invoice, subscription or subscription schedule. -# -# source://stripe//lib/stripe/resources/quote.rb#7 -class Stripe::Quote < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/quote.rb#14 - def accept(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#23 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#32 - def finalize_quote(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#41 - def list_computed_upfront_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#50 - def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#104 - def pdf(params = T.unsafe(nil), opts = T.unsafe(nil), &read_body_chunk_block); end - - class << self - # source://stripe//lib/stripe/resources/quote.rb#59 - def accept(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#68 - def cancel(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#77 - def finalize_quote(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#86 - def list_computed_upfront_line_items(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#95 - def list_line_items(quote, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/quote.rb#122 - def pdf(id, params = T.unsafe(nil), opts = T.unsafe(nil), &read_body_chunk_block); end - end -end - -# source://stripe//lib/stripe/resources/quote.rb#12 -Stripe::Quote::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#5 -module Stripe::Radar; end - -# An early fraud warning indicates that the card issuer has notified us that a -# charge may be fraudulent. -# -# Related guide: [Early Fraud Warnings](https://stripe.com/docs/disputes/measuring#early-fraud-warnings). -# -# source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#10 -class Stripe::Radar::EarlyFraudWarning < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/radar/early_fraud_warning.rb#13 -Stripe::Radar::EarlyFraudWarning::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Value lists allow you to group values together which can then be referenced in rules. -# -# Related guide: [Default Stripe Lists](https://stripe.com/docs/radar/lists#managing-list-items). -# -# source://stripe//lib/stripe/resources/radar/value_list.rb#9 -class Stripe::Radar::ValueList < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/radar/value_list.rb#15 -Stripe::Radar::ValueList::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Value list items allow you to add specific values to a given Radar value list, which can then be used in rules. -# -# Related guide: [Managing List Items](https://stripe.com/docs/radar/lists#managing-list-items). -# -# source://stripe//lib/stripe/resources/radar/value_list_item.rb#9 -class Stripe::Radar::ValueListItem < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/radar/value_list_item.rb#14 -Stripe::Radar::ValueListItem::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# RateLimitError is raised in cases where an account is putting too much load -# on Stripe's API servers (usually by performing too many requests). Please -# back off on request rate. -# -# source://stripe//lib/stripe/errors.rb#114 -class Stripe::RateLimitError < ::Stripe::StripeError; end - -# `Refund` objects allow you to refund a charge that has previously been created -# but not yet refunded. Funds will be refunded to the credit or debit card that -# was originally charged. -# -# Related guide: [Refunds](https://stripe.com/docs/refunds). -# -# source://stripe//lib/stripe/resources/refund.rb#10 -class Stripe::Refund < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/refund.rb#17 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/refund.rb#35 - def test_helpers; end - - class << self - # source://stripe//lib/stripe/resources/refund.rb#26 - def cancel(refund, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/refund.rb#15 -Stripe::Refund::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/refund.rb#39 -class Stripe::Refund::TestHelpers < ::Stripe::APIResourceTestHelpers - # source://stripe//lib/stripe/resources/refund.rb#51 - def expire(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/refund.rb#42 - def expire(refund, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/refund.rb#40 -Stripe::Refund::TestHelpers::RESOURCE_CLASS = Stripe::Refund - -# source://stripe//lib/stripe/resources/reporting/report_run.rb#5 -module Stripe::Reporting; end - -# The Report Run object represents an instance of a report type generated with -# specific run parameters. Once the object is created, Stripe begins processing the report. -# When the report has finished running, it will give you a reference to a file -# where you can retrieve your results. For an overview, see -# [API Access to Reports](https://stripe.com/docs/reporting/statements/api). -# -# Note that certain report types can only be run based on your live-mode data (not test-mode -# data), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes). -# -# source://stripe//lib/stripe/resources/reporting/report_run.rb#14 -class Stripe::Reporting::ReportRun < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/reporting/report_run.rb#18 -Stripe::Reporting::ReportRun::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# The Report Type resource corresponds to a particular type of report, such as -# the "Activity summary" or "Itemized payouts" reports. These objects are -# identified by an ID belonging to a set of enumerated values. See -# [API Access to Reports documentation](https://stripe.com/docs/reporting/statements/api) -# for those Report Type IDs, along with required and optional parameters. -# -# Note that certain report types can only be run based on your live-mode data (not test-mode -# data), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes). -# -# source://stripe//lib/stripe/resources/reporting/report_type.rb#14 -class Stripe::Reporting::ReportType < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/reporting/report_type.rb#17 -Stripe::Reporting::ReportType::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# [Stripe Connect](https://stripe.com/docs/connect) platforms can reverse transfers made to a -# connected account, either entirely or partially, and can also specify whether -# to refund any related application fees. Transfer reversals add to the -# platform's balance and subtract from the destination account's balance. -# -# Reversing a transfer that was made for a [destination -# charge](https://stripe.com/docs/connect/destination-charges) is allowed only up to the amount of -# the charge. It is possible to reverse a -# [transfer_group](https://stripe.com/docs/connect/charges-transfers#transfer-options) -# transfer only if the destination account has enough balance to cover the -# reversal. -# -# Related guide: [Reversing Transfers](https://stripe.com/docs/connect/charges-transfers#reversing-transfers). -# -# source://stripe//lib/stripe/resources/reversal.rb#18 -class Stripe::Reversal < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/reversal.rb#24 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/reversal.rb#36 - def retrieve(_id, _opts = T.unsafe(nil)); end - - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/reversal.rb#29 - def update(_id, _params = T.unsafe(nil), _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/reversal.rb#22 -Stripe::Reversal::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Reviews can be used to supplement automated fraud detection with human expertise. -# -# Learn more about [Radar](https://stripe.com/radar) and reviewing payments -# [here](https://stripe.com/docs/radar/reviews). -# -# source://stripe//lib/stripe/resources/review.rb#9 -class Stripe::Review < ::Stripe::APIResource - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/review.rb#14 - def approve(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/review.rb#23 - def approve(review, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/review.rb#12 -Stripe::Review::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/search_result_object.rb#4 -class Stripe::SearchResultObject < ::Stripe::StripeObject - include ::Stripe::APIOperations::Search - include ::Stripe::APIOperations::Request - extend ::Stripe::APIOperations::Request::ClassMethods - - # @return [SearchResultObject] a new instance of SearchResultObject - # - # source://stripe//lib/stripe/search_result_object.rb#23 - def initialize(*args); end - - # source://stripe//lib/stripe/search_result_object.rb#28 - def [](key); end - - # Iterates through each resource in all pages, making additional fetches to - # the API as necessary. - # - # Note that this method will make as many API calls as necessary to fetch - # all resources. For more granular control, please see +each+ and - # +next_search_result_page+. - # - # source://stripe//lib/stripe/search_result_object.rb#61 - def auto_paging_each(&blk); end - - # Iterates through each resource in the page represented by the current - # `SearchListObject`. - # - # Note that this method makes no effort to fetch a new page when it gets to - # the end of the current page's resources. See also +auto_paging_each+. - # - # source://stripe//lib/stripe/search_result_object.rb#46 - def each(&blk); end - - # Returns true if the page object contains no elements. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/search_result_object.rb#51 - def empty?; end - - # This accessor allows a `SearchResultObject` to inherit various filters - # that were given to a predecessor. This allows for things like consistent - # limits, expansions, and predicates as a user pages through resources. - # - # source://stripe//lib/stripe/search_result_object.rb#14 - def filters; end - - # This accessor allows a `SearchResultObject` to inherit various filters - # that were given to a predecessor. This allows for things like consistent - # limits, expansions, and predicates as a user pages through resources. - # - # source://stripe//lib/stripe/search_result_object.rb#14 - def filters=(_arg0); end - - # Fetches the next page in the resource list (if there is one). - # - # This method will try to respect the limit of the current page. If none - # was given, the default limit will be fetched again. - # - # source://stripe//lib/stripe/search_result_object.rb#78 - def next_search_result_page(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # An empty search result object. This is returned from +next+ when we know - # that there isn't a next page in order to replicate the behavior of the API - # when it attempts to return a page beyond the last. - # - # source://stripe//lib/stripe/search_result_object.rb#19 - def empty_search_result(opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/search_result_object.rb#9 -Stripe::SearchResultObject::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A SetupAttempt describes one attempted confirmation of a SetupIntent, -# whether that confirmation was successful or unsuccessful. You can use -# SetupAttempts to inspect details of a specific attempt at setting up a -# payment method using a SetupIntent. -# -# source://stripe//lib/stripe/resources/setup_attempt.rb#9 -class Stripe::SetupAttempt < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/setup_attempt.rb#12 -Stripe::SetupAttempt::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments. -# For example, you could use a SetupIntent to set up and save your customer's card without immediately collecting a payment. -# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow. -# -# Create a SetupIntent as soon as you're ready to collect your customer's payment credentials. -# Do not maintain long-lived, unconfirmed SetupIntents as they may no longer be valid. -# The SetupIntent then transitions through multiple [statuses](https://stripe.com/docs/payments/intents#intent-statuses) as it guides -# you through the setup process. -# -# Successful SetupIntents result in payment credentials that are optimized for future payments. -# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) may need to be run through -# [Strong Customer Authentication](https://stripe.com/docs/strong-customer-authentication) at the time of payment method collection -# in order to streamline later [off-session payments](https://stripe.com/docs/payments/setup-intents). -# If the SetupIntent is used with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer), upon success, -# it will automatically attach the resulting payment method to that Customer. -# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on -# PaymentIntents to save payment methods in order to prevent saving invalid or unoptimized payment methods. -# -# By using SetupIntents, you ensure that your customers experience the minimum set of required friction, -# even as regulations change over time. -# -# Related guide: [Setup Intents API](https://stripe.com/docs/payments/setup-intents). -# -# source://stripe//lib/stripe/resources/setup_intent.rb#27 -class Stripe::SetupIntent < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/setup_intent.rb#34 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/setup_intent.rb#43 - def confirm(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/setup_intent.rb#52 - def verify_microdeposits(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/setup_intent.rb#61 - def cancel(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/setup_intent.rb#70 - def confirm(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/setup_intent.rb#79 - def verify_microdeposits(intent, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/setup_intent.rb#32 -Stripe::SetupIntent::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Shipping rates describe the price of shipping presented to your customers and can be -# applied to [Checkout Sessions](https://stripe.com/docs/payments/checkout/shipping) -# and [Orders](https://stripe.com/docs/orders/shipping) to collect shipping costs. -# -# source://stripe//lib/stripe/resources/shipping_rate.rb#8 -class Stripe::ShippingRate < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/shipping_rate.rb#13 -Stripe::ShippingRate::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#5 -module Stripe::Sigma; end - -# If you have [scheduled a Sigma query](https://stripe.com/docs/sigma/scheduled-queries), you'll -# receive a `sigma.scheduled_query_run.created` webhook each time the query -# runs. The webhook contains a `ScheduledQueryRun` object, which you can use to -# retrieve the query results. -# -# source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#10 -class Stripe::Sigma::ScheduledQueryRun < ::Stripe::APIResource - extend ::Stripe::APIOperations::List - - class << self - # source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#15 - def resource_url; end - end -end - -# source://stripe//lib/stripe/resources/sigma/scheduled_query_run.rb#13 -Stripe::Sigma::ScheduledQueryRun::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# SignatureVerificationError is raised when the signature verification for a -# webhook fails -# -# source://stripe//lib/stripe/errors.rb#119 -class Stripe::SignatureVerificationError < ::Stripe::StripeError - # @return [SignatureVerificationError] a new instance of SignatureVerificationError - # - # source://stripe//lib/stripe/errors.rb#122 - def initialize(message, sig_header, http_body: T.unsafe(nil)); end - - # Returns the value of attribute sig_header. - # - # source://stripe//lib/stripe/errors.rb#120 - def sig_header; end - - # Sets the attribute sig_header - # - # @param value the value to set the attribute sig_header to. - # - # source://stripe//lib/stripe/errors.rb#120 - def sig_header=(_arg0); end -end - -# source://stripe//lib/stripe/singleton_api_resource.rb#4 -class Stripe::SingletonAPIResource < ::Stripe::APIResource - # source://stripe//lib/stripe/singleton_api_resource.rb#16 - def resource_url; end - - class << self - # source://stripe//lib/stripe/singleton_api_resource.rb#5 - def resource_url; end - - # source://stripe//lib/stripe/singleton_api_resource.rb#20 - def retrieve(opts = T.unsafe(nil)); end - end -end - -# `Source` objects allow you to accept a variety of payment methods. They -# represent a customer's payment instrument, and can be used with the Stripe API -# just like a `Card` object: once chargeable, they can be charged, or can be -# attached to customers. -# -# Stripe doesn't recommend using the deprecated [Sources API](https://stripe.com/docs/api/sources). -# We recommend that you adopt the [PaymentMethods API](https://stripe.com/docs/api/payment_methods). -# This newer API provides access to our latest features and payment method types. -# -# Related guides: [Sources API](https://stripe.com/docs/sources) and [Sources & Customers](https://stripe.com/docs/sources/customers). -# -# source://stripe//lib/stripe/resources/source.rb#15 -class Stripe::Source < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Save::ClassMethods - extend ::Stripe::APIOperations::NestedResource - extend ::Gem::Deprecate - - # source://stripe//lib/stripe/resources/source.rb#56 - def _deprecated_source_transactions(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/source.rb#43 - def detach(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - def source_transactions(*args, **_arg1, &block); end - - # source://stripe//lib/stripe/resources/source.rb#25 - def verify(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_source_transactions(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_source_transaction(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def source_transactions_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/source.rb#34 - def verify(source, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/source.rb#20 -Stripe::Source::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Some payment methods have no required amount that a customer must send. -# Customers can be instructed to send any amount, and it can be made up of -# multiple transactions. As such, sources can have multiple associated -# transactions. -# -# source://stripe//lib/stripe/resources/source_transaction.rb#9 -class Stripe::SourceTransaction < ::Stripe::StripeObject; end - -# source://stripe//lib/stripe/resources/source_transaction.rb#10 -Stripe::SourceTransaction::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# StripeClient executes requests against the Stripe API and allows a user to -# recover both a resource a call returns as well as a response object that -# contains information on the HTTP call. -# -# source://stripe//lib/stripe/stripe_client.rb#9 -class Stripe::StripeClient - extend ::Gem::Deprecate - - # Initializes a new StripeClient - # - # @return [StripeClient] a new instance of StripeClient - # - # source://stripe//lib/stripe/stripe_client.rb#17 - def initialize(config_arg = T.unsafe(nil)); end - - # source://stripe//lib/stripe/stripe_client.rb#183 - def _deprecated_connection_manager; end - - # Returns the value of attribute config. - # - # source://stripe//lib/stripe/stripe_client.rb#39 - def config; end - - # Gets the connection manager in use for the current `StripeClient`. - # - # This method is DEPRECATED and for backwards compatibility only. - def connection_manager(*args, **_arg1, &block); end - - # source://stripe//lib/stripe/stripe_client.rb#214 - def execute_request(method, path, api_base: T.unsafe(nil), api_key: T.unsafe(nil), headers: T.unsafe(nil), params: T.unsafe(nil)); end - - # Executes a request and returns the body as a stream instead of converting - # it to a StripeObject. This should be used for any request where we expect - # an arbitrary binary response. - # - # A `read_body_chunk` block can be passed, which will be called repeatedly - # with the body chunks read from the socket. - # - # If a block is passed, a StripeHeadersOnlyResponse is returned as the - # block is expected to do all the necessary body processing. If no block is - # passed, then a StripeStreamResponse is returned containing an IO stream - # with the response body. - # - # source://stripe//lib/stripe/stripe_client.rb#245 - def execute_request_stream(method, path, api_base: T.unsafe(nil), api_key: T.unsafe(nil), headers: T.unsafe(nil), params: T.unsafe(nil), &read_body_chunk_block); end - - # @return [Boolean] - # - # source://stripe//lib/stripe/stripe_client.rb#272 - def last_response_has_key?(object_id); end - - # Returns the value of attribute options. - # - # source://stripe//lib/stripe/stripe_client.rb#40 - def options; end - - # Executes the API call within the given block. Usage looks like: - # - # client = StripeClient.new - # charge, resp = client.request { Charge.create } - # - # source://stripe//lib/stripe/stripe_client.rb#194 - def request; end - - # source://stripe//lib/stripe/stripe_client.rb#266 - def store_last_response(object_id, resp); end - - private - - # source://stripe//lib/stripe/stripe_client.rb#511 - def api_url(url = T.unsafe(nil), api_base = T.unsafe(nil)); end - - # @raise [AuthenticationError] - # - # source://stripe//lib/stripe/stripe_client.rb#515 - def check_api_key!(api_key); end - - # Encodes a set of body parameters using multipart if `Content-Type` is set - # for that, or standard form-encoding otherwise. Returns the encoded body - # and a version of the encoded body that's safe to be logged. - # - # source://stripe//lib/stripe/stripe_client.rb#535 - def encode_body(body_params, headers); end - - # @raise [ArgumentError] - # - # source://stripe//lib/stripe/stripe_client.rb#433 - def execute_request_internal(method, path, api_base, api_key, headers, params, &read_body_chunk_block); end - - # source://stripe//lib/stripe/stripe_client.rb#568 - def execute_request_with_rescues(method, api_base, headers, context); end - - # Formats a plugin "app info" hash into a string that we can tack onto the - # end of a User-Agent string where it'll be fairly prominent in places like - # the Dashboard. Note that this formatting has been implemented to match - # other libraries, and shouldn't be changed without universal consensus. - # - # source://stripe//lib/stripe/stripe_client.rb#698 - def format_app_info(info); end - - # source://stripe//lib/stripe/stripe_client.rb#688 - def general_api_error(status, body); end - - # source://stripe//lib/stripe/stripe_client.rb#705 - def handle_error_response(http_resp, context); end - - # @raise [APIConnectionError] - # - # source://stripe//lib/stripe/stripe_client.rb#833 - def handle_network_error(error, context, num_retries, api_base = T.unsafe(nil)); end - - # source://stripe//lib/stripe/stripe_client.rb#901 - def log_request(context, num_retries); end - - # source://stripe//lib/stripe/stripe_client.rb#920 - def log_response(context, request_start, status, body, resp); end - - # source://stripe//lib/stripe/stripe_client.rb#951 - def log_response_error(context, request_start, error); end - - # Works around an edge case where we end up with both query parameters from - # parameteers and query parameters that were appended onto the end of the - # given path. - # - # Decode any parameters that were added onto the end of a path and add them - # to a unified query parameter hash so that all parameters end up in one - # place and all of them are correctly included in the final request. - # - # source://stripe//lib/stripe/stripe_client.rb#732 - def merge_query_params(query_params, path); end - - # source://stripe//lib/stripe/stripe_client.rb#645 - def notify_request_begin(context); end - - # source://stripe//lib/stripe/stripe_client.rb#660 - def notify_request_end(context, duration, http_status, num_retries, user_data, resp, headers); end - - # source://stripe//lib/stripe/stripe_client.rb#859 - def request_headers(api_key, method); end - - # source://stripe//lib/stripe/stripe_client.rb#564 - def should_handle_as_error(http_status); end - - # source://stripe//lib/stripe/stripe_client.rb#747 - def specific_api_error(resp, error_data, context); end - - # Attempts to look at a response's error code and return an OAuth error if - # one matches. Will return `nil` if the code isn't recognized. - # - # source://stripe//lib/stripe/stripe_client.rb#797 - def specific_oauth_error(resp, error_code, context); end - - class << self - # Gets a currently active `StripeClient`. Set for the current thread when - # `StripeClient#request` is being run so that API operations being executed - # inside of that block can find the currently active client. It's reset to - # the original value (hopefully `nil`) after the block ends. - # - # For internal use only. Does not provide a stable API and may be broken - # with future non-major changes. - # - # source://stripe//lib/stripe/stripe_client.rb#49 - def active_client; end - - # Finishes any active connections by closing their TCP connection and - # clears them from internal tracking in all connection managers across all - # threads. - # - # If passed a `config` object, only clear connection managers for that - # particular configuration. - # - # For internal use only. Does not provide a stable API and may be broken - # with future non-major changes. - # - # source://stripe//lib/stripe/stripe_client.rb#62 - def clear_all_connection_managers(config: T.unsafe(nil)); end - - # Access data stored for `StripeClient` within the thread's current - # context. Returns `ThreadContext`. - # - # For internal use only. Does not provide a stable API and may be broken - # with future non-major changes. - # - # source://stripe//lib/stripe/stripe_client.rb#381 - def current_thread_context; end - - # A default client for the current thread. - # - # source://stripe//lib/stripe/stripe_client.rb#93 - def default_client; end - - # A default connection manager for the current thread scoped to the - # configuration object that may be provided. - # - # source://stripe//lib/stripe/stripe_client.rb#99 - def default_connection_manager(config = T.unsafe(nil)); end - - # Garbage collects connection managers that haven't been used in some time, - # with the idea being that we want to remove old connection managers that - # belong to dead threads and the like. - # - # Prefixed with `maybe_` because garbage collection will only run - # periodically so that we're not constantly engaged in busy work. If - # connection managers live a little passed their useful age it's not - # harmful, so it's not necessary to get them right away. - # - # For testability, returns `nil` if it didn't run and the number of - # connection managers that were garbage collected otherwise. - # - # IMPORTANT: This method is not thread-safe and expects to be called inside - # a lock on `@thread_contexts_with_connection_managers_mutex`. - # - # For internal use only. Does not provide a stable API and may be broken - # with future non-major changes. - # - # source://stripe//lib/stripe/stripe_client.rb#402 - def maybe_gc_connection_managers; end - - # Checks if an error is a problem that we should retry on. This includes - # both socket errors that may represent an intermittent problem and some - # special HTTP statuses. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/stripe_client.rb#115 - def should_retry?(error, method:, num_retries:, config: T.unsafe(nil)); end - - # source://stripe//lib/stripe/stripe_client.rb#163 - def sleep_time(num_retries, config: T.unsafe(nil)); end - end -end - -# Time (in seconds) that a connection manager has not been used before it's -# eligible for garbage collection. -# -# source://stripe//lib/stripe/stripe_client.rb#282 -Stripe::StripeClient::CONNECTION_MANAGER_GC_LAST_USED_EXPIRY = T.let(T.unsafe(nil), Integer) - -# How often to check (in seconds) for connection managers that haven't been -# used in a long time and which should be garbage collected. -# -# source://stripe//lib/stripe/stripe_client.rb#286 -Stripe::StripeClient::CONNECTION_MANAGER_GC_PERIOD = T.let(T.unsafe(nil), Integer) - -# source://stripe//lib/stripe/stripe_client.rb#288 -Stripe::StripeClient::ERROR_MESSAGE_CONNECTION = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/stripe_client.rb#293 -Stripe::StripeClient::ERROR_MESSAGE_SSL = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/stripe_client.rb#306 -Stripe::StripeClient::ERROR_MESSAGE_TIMEOUT_CONNECT = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/stripe_client.rb#311 -Stripe::StripeClient::ERROR_MESSAGE_TIMEOUT_READ = T.let(T.unsafe(nil), String) - -# Common error suffix sared by both connect and read timeout messages. -# -# source://stripe//lib/stripe/stripe_client.rb#300 -Stripe::StripeClient::ERROR_MESSAGE_TIMEOUT_SUFFIX = T.let(T.unsafe(nil), String) - -# Maps types of exceptions that we're likely to see during a network -# request to more user-friendly messages that we put in front of people. -# The original error message is also appended onto the final exception for -# full transparency. -# -# source://stripe//lib/stripe/stripe_client.rb#320 -Stripe::StripeClient::NETWORK_ERROR_MESSAGES_MAP = T.let(T.unsafe(nil), Hash) - -# RequestLogContext stores information about a request that's begin made so -# that we can log certain information. It's useful because it means that we -# don't have to pass around as many parameters. -# -# source://stripe//lib/stripe/stripe_client.rb#965 -class Stripe::StripeClient::RequestLogContext - # Returns the value of attribute account. - # - # source://stripe//lib/stripe/stripe_client.rb#967 - def account; end - - # Sets the attribute account - # - # @param value the value to set the attribute account to. - # - # source://stripe//lib/stripe/stripe_client.rb#967 - def account=(_arg0); end - - # Returns the value of attribute api_key. - # - # source://stripe//lib/stripe/stripe_client.rb#968 - def api_key; end - - # Sets the attribute api_key - # - # @param value the value to set the attribute api_key to. - # - # source://stripe//lib/stripe/stripe_client.rb#968 - def api_key=(_arg0); end - - # Returns the value of attribute api_version. - # - # source://stripe//lib/stripe/stripe_client.rb#969 - def api_version; end - - # Sets the attribute api_version - # - # @param value the value to set the attribute api_version to. - # - # source://stripe//lib/stripe/stripe_client.rb#969 - def api_version=(_arg0); end - - # Returns the value of attribute body. - # - # source://stripe//lib/stripe/stripe_client.rb#966 - def body; end - - # Sets the attribute body - # - # @param value the value to set the attribute body to. - # - # source://stripe//lib/stripe/stripe_client.rb#966 - def body=(_arg0); end - - # The idea with this method is that we might want to update some of - # context information because a response that we've received from the API - # contains information that's more authoritative than what we started - # with for a request. For example, we should trust whatever came back in - # a `Stripe-Version` header beyond what configuration information that we - # might have had available. - # - # source://stripe//lib/stripe/stripe_client.rb#982 - def dup_from_response_headers(headers); end - - # Returns the value of attribute idempotency_key. - # - # source://stripe//lib/stripe/stripe_client.rb#970 - def idempotency_key; end - - # Sets the attribute idempotency_key - # - # @param value the value to set the attribute idempotency_key to. - # - # source://stripe//lib/stripe/stripe_client.rb#970 - def idempotency_key=(_arg0); end - - # Returns the value of attribute method. - # - # source://stripe//lib/stripe/stripe_client.rb#971 - def method; end - - # Sets the attribute method - # - # @param value the value to set the attribute method to. - # - # source://stripe//lib/stripe/stripe_client.rb#971 - def method=(_arg0); end - - # Returns the value of attribute path. - # - # source://stripe//lib/stripe/stripe_client.rb#972 - def path; end - - # Sets the attribute path - # - # @param value the value to set the attribute path to. - # - # source://stripe//lib/stripe/stripe_client.rb#972 - def path=(_arg0); end - - # Returns the value of attribute query. - # - # source://stripe//lib/stripe/stripe_client.rb#973 - def query; end - - # Sets the attribute query - # - # @param value the value to set the attribute query to. - # - # source://stripe//lib/stripe/stripe_client.rb#973 - def query=(_arg0); end - - # Returns the value of attribute request_id. - # - # source://stripe//lib/stripe/stripe_client.rb#974 - def request_id; end - - # Sets the attribute request_id - # - # @param value the value to set the attribute request_id to. - # - # source://stripe//lib/stripe/stripe_client.rb#974 - def request_id=(_arg0); end -end - -# StripeRequestMetrics tracks metadata to be reported to stripe for metrics -# collection -# -# source://stripe//lib/stripe/stripe_client.rb#1051 -class Stripe::StripeClient::StripeRequestMetrics - # @return [StripeRequestMetrics] a new instance of StripeRequestMetrics - # - # source://stripe//lib/stripe/stripe_client.rb#1058 - def initialize(request_id, request_duration_ms); end - - # source://stripe//lib/stripe/stripe_client.rb#1063 - def payload; end - - # Request duration in milliseconds - # - # source://stripe//lib/stripe/stripe_client.rb#1056 - def request_duration_ms; end - - # Request duration in milliseconds - # - # source://stripe//lib/stripe/stripe_client.rb#1056 - def request_duration_ms=(_arg0); end - - # The Stripe request ID of the response. - # - # source://stripe//lib/stripe/stripe_client.rb#1053 - def request_id; end - - # The Stripe request ID of the response. - # - # source://stripe//lib/stripe/stripe_client.rb#1053 - def request_id=(_arg0); end -end - -# SystemProfiler extracts information about the system that we're running -# in so that we can generate a rich user agent header to help debug -# integrations. -# -# source://stripe//lib/stripe/stripe_client.rb#995 -class Stripe::StripeClient::SystemProfiler - # @return [SystemProfiler] a new instance of SystemProfiler - # - # source://stripe//lib/stripe/stripe_client.rb#1027 - def initialize; end - - # source://stripe//lib/stripe/stripe_client.rb#1031 - def user_agent; end - - class << self - # source://stripe//lib/stripe/stripe_client.rb#996 - def uname; end - - # source://stripe//lib/stripe/stripe_client.rb#1011 - def uname_from_system; end - - # source://stripe//lib/stripe/stripe_client.rb#1019 - def uname_from_system_ver; end - end -end - -# A record representing any data that `StripeClient` puts into -# `Thread.current`. Making it a class likes this gives us a little extra -# type safety and lets us document what each field does. -# -# For internal use only. Does not provide a stable API and may be broken -# with future non-major changes. -# -# source://stripe//lib/stripe/stripe_client.rb#341 -class Stripe::StripeClient::ThreadContext - # A `StripeClient` that's been flagged as currently active within a - # thread by `StripeClient#request`. A client stays active until the - # completion of the request block. - # - # source://stripe//lib/stripe/stripe_client.rb#345 - def active_client; end - - # A `StripeClient` that's been flagged as currently active within a - # thread by `StripeClient#request`. A client stays active until the - # completion of the request block. - # - # source://stripe//lib/stripe/stripe_client.rb#345 - def active_client=(_arg0); end - - # A default `StripeClient` object for the thread. Used in all cases where - # the user hasn't specified their own. - # - # source://stripe//lib/stripe/stripe_client.rb#349 - def default_client; end - - # A default `StripeClient` object for the thread. Used in all cases where - # the user hasn't specified their own. - # - # source://stripe//lib/stripe/stripe_client.rb#349 - def default_client=(_arg0); end - - # A map of connection mangers for the thread. Normally shared between - # all `StripeClient` objects on a particular thread, and created so as to - # minimize the number of open connections that an application needs. - # - # source://stripe//lib/stripe/stripe_client.rb#367 - def default_connection_managers; end - - # A temporary map of object IDs to responses from last executed API - # calls. Used to return a responses from calls to `StripeClient#request`. - # - # Stored in the thread data to make the use of a single `StripeClient` - # object safe across multiple threads. Stored as a map so that multiple - # `StripeClient` objects can run concurrently on the same thread. - # - # Responses are only left in as long as they're needed, which means - # they're removed as soon as a call leaves `StripeClient#request`, and - # because that's wrapped in an `ensure` block, they should never leave - # garbage in `Thread.current`. - # - # source://stripe//lib/stripe/stripe_client.rb#362 - def last_responses; end - - # A temporary map of object IDs to responses from last executed API - # calls. Used to return a responses from calls to `StripeClient#request`. - # - # Stored in the thread data to make the use of a single `StripeClient` - # object safe across multiple threads. Stored as a map so that multiple - # `StripeClient` objects can run concurrently on the same thread. - # - # Responses are only left in as long as they're needed, which means - # they're removed as soon as a call leaves `StripeClient#request`, and - # because that's wrapped in an `ensure` block, they should never leave - # garbage in `Thread.current`. - # - # source://stripe//lib/stripe/stripe_client.rb#362 - def last_responses=(_arg0); end - - # source://stripe//lib/stripe/stripe_client.rb#371 - def reset_connection_managers; end -end - -# Configurable options: -# -# =ca_bundle_path= -# The location of a file containing a bundle of CA certificates. By default -# the library will use an included bundle that can successfully validate -# Stripe certificates. -# -# =log_level= -# When set prompts the library to log some extra information to $stdout and -# $stderr about what it's doing. For example, it'll produce information about -# requests, responses, and errors that are received. Valid log levels are -# `debug` and `info`, with `debug` being a little more verbose in places. -# -# Use of this configuration is only useful when `.logger` is _not_ set. When -# it is, the decision what levels to print is entirely deferred to the logger. -# -# =logger= -# The logger should support the same interface as the `Logger` class that's -# part of Ruby's standard library (hint, anything in `Rails.logger` will -# likely be suitable). -# -# If `.logger` is set, the value of `.log_level` is ignored. The decision on -# what levels to print is entirely deferred to the logger. -# -# source://stripe//lib/stripe/stripe_configuration.rb#27 -class Stripe::StripeConfiguration - # @return [StripeConfiguration] a new instance of StripeConfiguration - # - # source://stripe//lib/stripe/stripe_configuration.rb#65 - def initialize; end - - # Returns the value of attribute api_base. - # - # source://stripe//lib/stripe/stripe_configuration.rb#35 - def api_base; end - - # source://stripe//lib/stripe/stripe_configuration.rb#151 - def api_base=(api_base); end - - # Returns the value of attribute api_key. - # - # source://stripe//lib/stripe/stripe_configuration.rb#28 - def api_key; end - - # Sets the attribute api_key - # - # @param value the value to set the attribute api_key to. - # - # source://stripe//lib/stripe/stripe_configuration.rb#28 - def api_key=(_arg0); end - - # Returns the value of attribute api_version. - # - # source://stripe//lib/stripe/stripe_configuration.rb#29 - def api_version; end - - # Sets the attribute api_version - # - # @param value the value to set the attribute api_version to. - # - # source://stripe//lib/stripe/stripe_configuration.rb#29 - def api_version=(_arg0); end - - # Returns the value of attribute ca_bundle_path. - # - # source://stripe//lib/stripe/stripe_configuration.rb#38 - def ca_bundle_path; end - - # source://stripe//lib/stripe/stripe_configuration.rb#156 - def ca_bundle_path=(path); end - - # A certificate store initialized from the the bundle in #ca_bundle_path and - # which is used to validate TLS on every request. - # - # This was added to the give the gem "pseudo thread safety" in that it seems - # when initiating many parallel requests marshaling the certificate store is - # the most likely point of failure (see issue #382). Any program attempting - # to leverage this pseudo safety should make a call to this method (i.e. - # `Stripe.ca_store`) in their initialization code because it marshals lazily - # and is itself not thread safe. - # - # source://stripe//lib/stripe/stripe_configuration.rb#174 - def ca_store; end - - # Returns the value of attribute client_id. - # - # source://stripe//lib/stripe/stripe_configuration.rb#30 - def client_id; end - - # Sets the attribute client_id - # - # @param value the value to set the attribute client_id to. - # - # source://stripe//lib/stripe/stripe_configuration.rb#30 - def client_id=(_arg0); end - - # Returns the value of attribute connect_base. - # - # source://stripe//lib/stripe/stripe_configuration.rb#37 - def connect_base; end - - # source://stripe//lib/stripe/stripe_configuration.rb#146 - def connect_base=(connect_base); end - - # Returns the value of attribute enable_telemetry. - # - # source://stripe//lib/stripe/stripe_configuration.rb#31 - def enable_telemetry; end - - # Sets the attribute enable_telemetry - # - # @param value the value to set the attribute enable_telemetry to. - # - # source://stripe//lib/stripe/stripe_configuration.rb#31 - def enable_telemetry=(_arg0); end - - # @return [Boolean] - # - # source://stripe//lib/stripe/stripe_configuration.rb#182 - def enable_telemetry?; end - - # Returns the value of attribute initial_network_retry_delay. - # - # source://stripe//lib/stripe/stripe_configuration.rb#40 - def initial_network_retry_delay; end - - # source://stripe//lib/stripe/stripe_configuration.rb#108 - def initial_network_retry_delay=(val); end - - # Generates a deterministic key to identify configuration objects with - # identical configuration values. - # - # source://stripe//lib/stripe/stripe_configuration.rb#188 - def key; end - - # Returns the value of attribute log_level. - # - # source://stripe//lib/stripe/stripe_configuration.rb#39 - def log_level; end - - # source://stripe//lib/stripe/stripe_configuration.rb#83 - def log_level=(val); end - - # Returns the value of attribute logger. - # - # source://stripe//lib/stripe/stripe_configuration.rb#32 - def logger; end - - # Sets the attribute logger - # - # @param value the value to set the attribute logger to. - # - # source://stripe//lib/stripe/stripe_configuration.rb#32 - def logger=(_arg0); end - - # Returns the value of attribute max_network_retries. - # - # source://stripe//lib/stripe/stripe_configuration.rb#41 - def max_network_retries; end - - # source://stripe//lib/stripe/stripe_configuration.rb#100 - def max_network_retries=(val); end - - # Returns the value of attribute max_network_retry_delay. - # - # source://stripe//lib/stripe/stripe_configuration.rb#42 - def max_network_retry_delay; end - - # source://stripe//lib/stripe/stripe_configuration.rb#104 - def max_network_retry_delay=(val); end - - # Returns the value of attribute open_timeout. - # - # source://stripe//lib/stripe/stripe_configuration.rb#43 - def open_timeout; end - - # source://stripe//lib/stripe/stripe_configuration.rb#112 - def open_timeout=(open_timeout); end - - # Returns the value of attribute proxy. - # - # source://stripe//lib/stripe/stripe_configuration.rb#46 - def proxy; end - - # source://stripe//lib/stripe/stripe_configuration.rb#131 - def proxy=(proxy); end - - # Returns the value of attribute read_timeout. - # - # source://stripe//lib/stripe/stripe_configuration.rb#44 - def read_timeout; end - - # source://stripe//lib/stripe/stripe_configuration.rb#117 - def read_timeout=(read_timeout); end - - # Create a new config based off an existing one. This is useful when the - # caller wants to override the global configuration - # - # source://stripe//lib/stripe/stripe_configuration.rb#57 - def reverse_duplicate_merge(hash); end - - # Returns the value of attribute stripe_account. - # - # source://stripe//lib/stripe/stripe_configuration.rb#33 - def stripe_account; end - - # Sets the attribute stripe_account - # - # @param value the value to set the attribute stripe_account to. - # - # source://stripe//lib/stripe/stripe_configuration.rb#33 - def stripe_account=(_arg0); end - - # Returns the value of attribute uploads_base. - # - # source://stripe//lib/stripe/stripe_configuration.rb#36 - def uploads_base; end - - # source://stripe//lib/stripe/stripe_configuration.rb#141 - def uploads_base=(uploads_base); end - - # Returns the value of attribute verify_ssl_certs. - # - # source://stripe//lib/stripe/stripe_configuration.rb#47 - def verify_ssl_certs; end - - # source://stripe//lib/stripe/stripe_configuration.rb#136 - def verify_ssl_certs=(verify_ssl_certs); end - - # Returns the value of attribute write_timeout. - # - # source://stripe//lib/stripe/stripe_configuration.rb#45 - def write_timeout; end - - # source://stripe//lib/stripe/stripe_configuration.rb#122 - def write_timeout=(write_timeout); end - - class << self - # source://stripe//lib/stripe/stripe_configuration.rb#49 - def setup; end - end -end - -# StripeError is the base error from which all other more specific Stripe -# errors derive. -# -# source://stripe//lib/stripe/errors.rb#6 -class Stripe::StripeError < ::StandardError - # Initializes a StripeError. - # - # @return [StripeError] a new instance of StripeError - # - # source://stripe//lib/stripe/errors.rb#22 - def initialize(message = T.unsafe(nil), http_status: T.unsafe(nil), http_body: T.unsafe(nil), json_body: T.unsafe(nil), http_headers: T.unsafe(nil), code: T.unsafe(nil)); end - - # Returns the value of attribute code. - # - # source://stripe//lib/stripe/errors.rb#13 - def code; end - - # source://stripe//lib/stripe/errors.rb#35 - def construct_error_object; end - - # Returns the value of attribute error. - # - # source://stripe//lib/stripe/errors.rb#14 - def error; end - - # Returns the value of attribute http_body. - # - # source://stripe//lib/stripe/errors.rb#15 - def http_body; end - - # Returns the value of attribute http_headers. - # - # source://stripe//lib/stripe/errors.rb#16 - def http_headers; end - - # Returns the value of attribute http_status. - # - # source://stripe//lib/stripe/errors.rb#17 - def http_status; end - - # Whether the error was the result of an idempotent replay, meaning that it - # originally occurred on a previous request and is being replayed back - # because the user sent the same idempotency key for this one. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/errors.rb#44 - def idempotent_replayed?; end - - # equivalent to #data - # - # source://stripe//lib/stripe/errors.rb#18 - def json_body; end - - # Returns the value of attribute message. - # - # source://stripe//lib/stripe/errors.rb#7 - def message; end - - # Returns the value of attribute request_id. - # - # source://stripe//lib/stripe/errors.rb#19 - def request_id; end - - # Response contains a StripeResponse object that has some basic information - # about the response that conveyed the error. - # - # source://stripe//lib/stripe/errors.rb#11 - def response; end - - # Response contains a StripeResponse object that has some basic information - # about the response that conveyed the error. - # - # source://stripe//lib/stripe/errors.rb#11 - def response=(_arg0); end - - # source://stripe//lib/stripe/errors.rb#48 - def to_s; end -end - -# StripeHeadersOnlyResponse includes only header-related vitals of the -# response. This is used for streaming requests where the response was read -# directly in a block and we explicitly don't want to store the body of the -# response in memory. -# -# source://stripe//lib/stripe/stripe_response.rb#99 -class Stripe::StripeHeadersOnlyResponse - include ::Stripe::StripeResponseBase - - class << self - # Initializes a StripeHeadersOnlyResponse object from a - # Net::HTTP::HTTPResponse object. - # - # source://stripe//lib/stripe/stripe_response.rb#104 - def from_net_http(http_resp); end - end -end - -# source://stripe//lib/stripe/stripe_object.rb#4 -class Stripe::StripeObject - include ::Enumerable - - # @return [StripeObject] a new instance of StripeObject - # - # source://stripe//lib/stripe/stripe_object.rb#73 - def initialize(id = T.unsafe(nil), opts = T.unsafe(nil)); end - - # Determines the equality of two Stripe objects. Stripe objects are - # considered to be equal if they have the same set of values and each one - # of those values is the same. - # - # source://stripe//lib/stripe/stripe_object.rb#95 - def ==(other); end - - # source://stripe//lib/stripe/stripe_object.rb#157 - def [](key); end - - # source://stripe//lib/stripe/stripe_object.rb#161 - def []=(key, value); end - - # source://stripe//lib/stripe/stripe_object.rb#178 - def as_json(*opts); end - - # Indicates whether or not the resource has been deleted on the server. - # Note that some, but not all, resources can indicate whether they have - # been deleted. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/stripe_object.rb#116 - def deleted?; end - - # Sets all keys within the StripeObject as unsaved so that they will be - # included with an update when #serialize_params is called. This method is - # also recursive, so any StripeObjects contained as values or which are - # values in a tenant array are also marked as dirty. - # - # source://stripe//lib/stripe/stripe_object.rb#207 - def dirty!; end - - # source://stripe//lib/stripe/stripe_object.rb#199 - def each(&blk); end - - # Hash equality. As with `#==`, we consider two equivalent Stripe objects - # equal. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/stripe_object.rb#102 - def eql?(other); end - - # As with equality in `#==` and `#eql?`, we hash two Stripe objects to the - # same value if they're equivalent objects. - # - # source://stripe//lib/stripe/stripe_object.rb#109 - def hash; end - - # source://stripe//lib/stripe/stripe_object.rb#124 - def inspect; end - - # source://stripe//lib/stripe/stripe_object.rb#165 - def keys; end - - # Implements custom encoding for Ruby's Marshal. The data produced by this - # method should be comprehendable by #marshal_load. - # - # This allows us to remove certain features that cannot or should not be - # serialized. - # - # source://stripe//lib/stripe/stripe_object.rb#219 - def marshal_dump; end - - # Implements custom decoding for Ruby's Marshal. Consumes data that's - # produced by #marshal_dump. - # - # source://stripe//lib/stripe/stripe_object.rb#230 - def marshal_load(data); end - - # source://stripe//lib/stripe/stripe_object.rb#236 - def serialize_params(options = T.unsafe(nil)); end - - # source://stripe//lib/stripe/stripe_object.rb#182 - def to_hash; end - - # source://stripe//lib/stripe/stripe_object.rb#173 - def to_json(*_opts); end - - # source://stripe//lib/stripe/stripe_object.rb#120 - def to_s(*_args); end - - # Mass assigns attributes on the model. - # - # This is a version of +update_attributes+ that takes some extra options - # for internal use. - # - # ==== Attributes - # - # * +values+ - Hash of values to use to update the current attributes of - # the object. If you are on ruby 2.7 or higher make sure to wrap in curly - # braces to be ruby 3 compatible. - # * +opts+ - Options for +StripeObject+ like an API key that will be reused - # on subsequent API calls. - # - # ==== Options - # - # * +:dirty+ - Whether values should be initiated as "dirty" (unsaved) and - # which applies only to new StripeObjects being initiated under this - # StripeObject. Defaults to true. - # - # source://stripe//lib/stripe/stripe_object.rb#148 - def update_attributes(values, opts = T.unsafe(nil), dirty: T.unsafe(nil)); end - - # source://stripe//lib/stripe/stripe_object.rb#169 - def values; end - - protected - - # source://stripe//lib/stripe/stripe_object.rb#331 - def add_accessors(keys, values); end - - # Re-initializes the object based on a hash of values (usually one that's - # come back from an API call). Adds or removes value accessors as necessary - # and updates the state of internal data. - # - # Protected on purpose! Please do not expose. - # - # ==== Options - # - # * +:values:+ Hash used to update accessors and values. - # * +:opts:+ Options for StripeObject like an API key. - # * +:partial:+ Indicates that the re-initialization should not attempt to - # remove accessors. - # - # source://stripe//lib/stripe/stripe_object.rb#432 - def initialize_from(values, opts); end - - # source://stripe//lib/stripe/stripe_object.rb#291 - def metaclass; end - - # Disabling the cop because it's confused by the fact that the methods are - # protected, but we do define `#respond_to_missing?` just below. Hopefully - # this is fixed in more recent Rubocop versions. - # - # source://stripe//lib/stripe/stripe_object.rb#373 - def method_missing(name, *args); end - - # source://stripe//lib/stripe/stripe_object.rb#295 - def remove_accessors(keys); end - - # @return [Boolean] - # - # source://stripe//lib/stripe/stripe_object.rb#416 - def respond_to_missing?(symbol, include_private = T.unsafe(nil)); end - - # source://stripe//lib/stripe/stripe_object.rb#463 - def serialize_params_value(value, original, unsaved, force, key: T.unsafe(nil)); end - - private - - # source://stripe//lib/stripe/stripe_object.rb#562 - def dirty_value!(value); end - - # Returns a hash of empty values for all the values that are in the given - # StripeObject. - # - # source://stripe//lib/stripe/stripe_object.rb#573 - def empty_values(obj); end - - class << self - # Sets the given parameter name to one which is known to be an additive - # object. - # - # Additive objects are subobjects in the API that don't have the same - # semantics as most subobjects, which are fully replaced when they're set. - # This is best illustrated by example. The `source` parameter sent when - # updating a subscription is *not* additive; if we set it: - # - # source[object]=card&source[number]=123 - # - # We expect the old `source` object to have been overwritten completely. If - # the previous source had an `address_state` key associated with it and we - # didn't send one this time, that value of `address_state` is gone. - # - # By contrast, additive objects are those that will have new data added to - # them while keeping any existing data in place. The only known case of its - # use is for `metadata`, but it could in theory be more general. As an - # example, say we have a `metadata` object that looks like this on the - # server side: - # - # metadata = { old: "old_value" } - # - # If we update the object with `metadata[new]=new_value`, the server side - # object now has *both* fields: - # - # metadata = { old: "old_value", new: "new_value" } - # - # This is okay in itself because usually users will want to treat it as - # additive: - # - # obj.metadata[:new] = "new_value" - # obj.save - # - # However, in other cases, they may want to replace the entire existing - # contents: - # - # obj.metadata = { new: "new_value" } - # obj.save - # - # This is where things get a little bit tricky because in order to clear - # any old keys that may have existed, we actually have to send an explicit - # empty string to the server. So the operation above would have to send - # this form to get the intended behavior: - # - # metadata[old]=&metadata[new]=new_value - # - # This method allows us to track which parameters are considered additive, - # and lets us behave correctly where appropriate when serializing - # parameters to be sent. - # - # source://stripe//lib/stripe/stripe_object.rb#61 - def additive_object_param(name); end - - # Returns whether the given name is an additive object parameter. See - # `.additive_object_param` for details. - # - # @return [Boolean] - # - # source://stripe//lib/stripe/stripe_object.rb#68 - def additive_object_param?(name); end - - # source://stripe//lib/stripe/stripe_object.rb#85 - def construct_from(values, opts = T.unsafe(nil)); end - - # A protected field is one that doesn't get an accessor assigned to it - # (i.e. `obj.public = ...`) and one which is not allowed to be updated via - # the class level `Model.update(id, { ... })`. - # - # source://stripe//lib/stripe/stripe_object.rb#266 - def protected_fields; end - - private - - # Produces a deep copy of the given object including support for arrays, - # hashes, and StripeObjects. - # - # source://stripe//lib/stripe/stripe_object.rb#541 - def deep_copy(obj); end - end -end - -# When designing APIs, we now make a conscious effort server-side to avoid -# naming fields after important built-ins in various languages (e.g. class, -# method, etc.). -# -# However, a long time ago we made the mistake (either consciously or by -# accident) of initializing our `metadata` fields as instances of -# `StripeObject`, and metadata can have a wide range of different keys -# defined in it. This is somewhat a convenient in that it allows users to -# access data like `obj.metadata.my_field`, but is almost certainly not -# worth the cost. -# -# Naming metadata fields bad things like `class` causes `initialize_from` -# to produce strange results, so we ban known offenders here. -# -# In a future major version we should consider leaving `metadata` as a hash -# and forcing people to access it with `obj.metadata[:my_field]` because -# the potential for trouble is just too high. For now, reserve names. -# -# source://stripe//lib/stripe/stripe_object.rb#287 -Stripe::StripeObject::RESERVED_FIELD_NAMES = T.let(T.unsafe(nil), Array) - -# StripeResponse encapsulates some vitals of a response that came back from -# the Stripe API. -# -# source://stripe//lib/stripe/stripe_response.rb#70 -class Stripe::StripeResponse - include ::Stripe::StripeResponseBase - - # The data contained by the HTTP body of the response deserialized from - # JSON. - # - # source://stripe//lib/stripe/stripe_response.rb#74 - def data; end - - # The data contained by the HTTP body of the response deserialized from - # JSON. - # - # source://stripe//lib/stripe/stripe_response.rb#74 - def data=(_arg0); end - - # The raw HTTP body of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#77 - def http_body; end - - # The raw HTTP body of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#77 - def http_body=(_arg0); end - - class << self - # Initializes a StripeResponse object from a Net::HTTP::HTTPResponse - # object. - # - # source://stripe//lib/stripe/stripe_response.rb#81 - def from_net_http(http_resp); end - end -end - -# We have to alias StripeResponseHeaders to StripeResponse::Headers, as this -# class used to be embedded within StripeResponse and we want to be backwards -# compatible. -# -# source://stripe//lib/stripe/stripe_response.rb#93 -Stripe::StripeResponse::Headers = Stripe::StripeResponseHeaders - -# source://stripe//lib/stripe/stripe_response.rb#51 -module Stripe::StripeResponseBase - # A Hash of the HTTP headers of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#53 - def http_headers; end - - # A Hash of the HTTP headers of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#53 - def http_headers=(_arg0); end - - # The integer HTTP status code of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#56 - def http_status; end - - # The integer HTTP status code of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#56 - def http_status=(_arg0); end - - # The Stripe request ID of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#59 - def request_id; end - - # The Stripe request ID of the response. - # - # source://stripe//lib/stripe/stripe_response.rb#59 - def request_id=(_arg0); end - - class << self - # source://stripe//lib/stripe/stripe_response.rb#61 - def populate_for_net_http(resp, http_resp); end - end -end - -# Headers provides an access wrapper to an API response's header data. It -# mainly exists so that we don't need to expose the entire -# `Net::HTTPResponse` object while still getting some of its benefits like -# case-insensitive access to header names and flattening of header values. -# -# source://stripe//lib/stripe/stripe_response.rb#8 -class Stripe::StripeResponseHeaders - # `hash` is expected to be a hash mapping header names to arrays of - # header values. This is the default format generated by calling - # `#to_hash` on a `Net::HTTPResponse` object because headers can be - # repeated multiple times. Using `#[]` will collapse values down to just - # the first. - # - # @return [StripeResponseHeaders] a new instance of StripeResponseHeaders - # - # source://stripe//lib/stripe/stripe_response.rb#19 - def initialize(hash); end - - # source://stripe//lib/stripe/stripe_response.rb#42 - def [](name); end - - class << self - # Initializes a Headers object from a Net::HTTP::HTTPResponse object. - # - # source://stripe//lib/stripe/stripe_response.rb#10 - def from_net_http(resp); end - end -end - -# Subscriptions allow you to charge a customer on a recurring basis. -# -# Related guide: [Creating Subscriptions](https://stripe.com/docs/billing/subscriptions/creating). -# -# source://stripe//lib/stripe/resources/subscription.rb#8 -class Stripe::Subscription < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Search - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/subscription.rb#16 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription.rb#25 - def delete_discount(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription.rb#34 - def resume(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_resource.rb#36 - def source=(value); end - - class << self - # source://stripe//lib/stripe/resources/subscription.rb#43 - def cancel(subscription_exposed_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription.rb#52 - def delete_discount(subscription_exposed_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription.rb#61 - def resume(subscription, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription.rb#72 - def search(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription.rb#76 - def search_auto_paging_each(params = T.unsafe(nil), opts = T.unsafe(nil), &blk); end - end -end - -# source://stripe//lib/stripe/resources/subscription.rb#14 -Stripe::Subscription::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Subscription items allow you to create customer subscriptions with more than -# one plan, making it easy to represent complex billing relationships. -# -# source://stripe//lib/stripe/resources/subscription_item.rb#7 -class Stripe::SubscriptionItem < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - extend ::Stripe::APIOperations::NestedResource - - class << self - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_usage_record(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_usage_record_summaries(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def usage_record_summarys_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def usage_records_url(id, nested_id = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/subscription_item.rb#14 -Stripe::SubscriptionItem::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A subscription schedule allows you to create and manage the lifecycle of a subscription by predefining expected changes. -# -# Related guide: [Subscription Schedules](https://stripe.com/docs/billing/subscriptions/subscription-schedules). -# -# source://stripe//lib/stripe/resources/subscription_schedule.rb#8 -class Stripe::SubscriptionSchedule < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/subscription_schedule.rb#15 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription_schedule.rb#24 - def release(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/subscription_schedule.rb#33 - def cancel(schedule, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/subscription_schedule.rb#42 - def release(schedule, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/subscription_schedule.rb#13 -Stripe::SubscriptionSchedule::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/tax/calculation.rb#5 -module Stripe::Tax; end - -# A Tax `Calculation` allows you to calculate the tax to collect from your customer. -# -# source://stripe//lib/stripe/resources/tax/calculation.rb#7 -class Stripe::Tax::Calculation < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - - # source://stripe//lib/stripe/resources/tax/calculation.rb#12 - def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/tax/calculation.rb#21 - def list_line_items(calculation, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/tax/calculation.rb#10 -Stripe::Tax::Calculation::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Tax transaction records the tax collected from or refunded to your customer. -# -# source://stripe//lib/stripe/resources/tax/transaction.rb#7 -class Stripe::Tax::Transaction < ::Stripe::APIResource - # source://stripe//lib/stripe/resources/tax/transaction.rb#10 - def list_line_items(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/tax/transaction.rb#19 - def create_from_calculation(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/tax/transaction.rb#28 - def create_reversal(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/tax/transaction.rb#37 - def list_line_items(transaction, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/tax/transaction.rb#8 -Stripe::Tax::Transaction::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# [Tax codes](https://stripe.com/docs/tax/tax-categories) classify goods and services for tax purposes. -# -# source://stripe//lib/stripe/resources/tax_code.rb#6 -class Stripe::TaxCode < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/tax_code.rb#9 -Stripe::TaxCode::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# You can add one or multiple tax IDs to a [customer](https://stripe.com/docs/api/customers). -# A customer's tax IDs are displayed on invoices and credit notes issued for the customer. -# -# Related guide: [Customer Tax Identification Numbers](https://stripe.com/docs/billing/taxes/tax-ids). -# -# source://stripe//lib/stripe/resources/tax_id.rb#9 -class Stripe::TaxId < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/tax_id.rb#15 - def resource_url; end - - class << self - # @raise [NotImplementedError] - # - # source://stripe//lib/stripe/resources/tax_id.rb#24 - def retrieve(_id, _opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/tax_id.rb#13 -Stripe::TaxId::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Tax rates can be applied to [invoices](https://stripe.com/docs/billing/invoices/tax-rates), [subscriptions](https://stripe.com/docs/billing/subscriptions/taxes) and [Checkout Sessions](https://stripe.com/docs/payments/checkout/set-up-a-subscription#tax-rates) to collect tax. -# -# Related guide: [Tax Rates](https://stripe.com/docs/billing/taxes/tax-rates). -# -# source://stripe//lib/stripe/resources/tax_rate.rb#8 -class Stripe::TaxRate < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/tax_rate.rb#13 -Stripe::TaxRate::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/terminal/configuration.rb#5 -module Stripe::Terminal; end - -# A Configurations object represents how features should be configured for terminal readers. -# -# source://stripe//lib/stripe/resources/terminal/configuration.rb#7 -class Stripe::Terminal::Configuration < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/terminal/configuration.rb#13 -Stripe::Terminal::Configuration::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Connection Token is used by the Stripe Terminal SDK to connect to a reader. -# -# Related guide: [Fleet Management](https://stripe.com/docs/terminal/fleet/locations). -# -# source://stripe//lib/stripe/resources/terminal/connection_token.rb#9 -class Stripe::Terminal::ConnectionToken < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create -end - -# source://stripe//lib/stripe/resources/terminal/connection_token.rb#12 -Stripe::Terminal::ConnectionToken::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Location represents a grouping of readers. -# -# Related guide: [Fleet Management](https://stripe.com/docs/terminal/fleet/locations). -# -# source://stripe//lib/stripe/resources/terminal/location.rb#9 -class Stripe::Terminal::Location < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/terminal/location.rb#15 -Stripe::Terminal::Location::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A Reader represents a physical device for accepting payment details. -# -# Related guide: [Connecting to a Reader](https://stripe.com/docs/terminal/payments/connect-reader). -# -# source://stripe//lib/stripe/resources/terminal/reader.rb#9 -class Stripe::Terminal::Reader < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/terminal/reader.rb#17 - def cancel_action(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#26 - def process_payment_intent(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#35 - def process_setup_intent(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#44 - def refund_payment(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#53 - def set_reader_display(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#107 - def test_helpers; end - - class << self - # source://stripe//lib/stripe/resources/terminal/reader.rb#62 - def cancel_action(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#71 - def process_payment_intent(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#80 - def process_setup_intent(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#89 - def refund_payment(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/terminal/reader.rb#98 - def set_reader_display(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/terminal/reader.rb#15 -Stripe::Terminal::Reader::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/terminal/reader.rb#111 -class Stripe::Terminal::Reader::TestHelpers < ::Stripe::APIResourceTestHelpers - # source://stripe//lib/stripe/resources/terminal/reader.rb#123 - def present_payment_method(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/terminal/reader.rb#114 - def present_payment_method(reader, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/terminal/reader.rb#112 -Stripe::Terminal::Reader::TestHelpers::RESOURCE_CLASS = Stripe::Terminal::Reader - -# source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#5 -module Stripe::TestHelpers; end - -# A test clock enables deterministic control over objects in testmode. With a test clock, you can create -# objects at a frozen time in the past or future, and advance to a specific future time to observe webhooks and state changes. After the clock advances, -# you can either validate the current state of your scenario (and test your assumptions), change the current state of your scenario (and test more complex scenarios), or keep advancing forward in time. -# -# source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#9 -class Stripe::TestHelpers::TestClock < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#16 - def advance(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#25 - def advance(test_clock, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/test_helpers/test_clock.rb#14 -Stripe::TestHelpers::TestClock::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Tokenization is the process Stripe uses to collect sensitive card or bank -# account details, or personally identifiable information (PII), directly from -# your customers in a secure manner. A token representing this information is -# returned to your server to use. You should use our -# [recommended payments integrations](https://stripe.com/docs/payments) to perform this process -# client-side. This ensures that no sensitive card data touches your server, -# and allows your integration to operate in a PCI-compliant way. -# -# If you cannot use client-side tokenization, you can also create tokens using -# the API with either your publishable or secret API key. Keep in mind that if -# your integration uses this method, you are responsible for any PCI compliance -# that may be required, and you must keep your secret API key safe. Unlike with -# client-side tokenization, your customer's information is not sent directly to -# Stripe, so we cannot determine how it is handled or stored. -# -# Tokens cannot be stored or used more than once. To store card or bank account -# information for later use, you can create [Customer](https://stripe.com/docs/api#customers) -# objects or [Custom accounts](https://stripe.com/docs/api#external_accounts). Note that -# [Radar](https://stripe.com/docs/radar), our integrated solution for automatic fraud protection, -# performs best with integrations that use client-side tokenization. -# -# Related guide: [Accept a payment](https://stripe.com/docs/payments/accept-a-payment-charges#web-create-token) -# -# source://stripe//lib/stripe/resources/token.rb#27 -class Stripe::Token < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create -end - -# source://stripe//lib/stripe/resources/token.rb#30 -Stripe::Token::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# To top up your Stripe balance, you create a top-up object. You can retrieve -# individual top-ups, as well as list all top-ups. Top-ups are identified by a -# unique, random ID. -# -# Related guide: [Topping Up your Platform Account](https://stripe.com/docs/connect/top-ups). -# -# source://stripe//lib/stripe/resources/topup.rb#10 -class Stripe::Topup < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/topup.rb#17 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/topup.rb#26 - def cancel(topup, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/topup.rb#15 -Stripe::Topup::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# A `Transfer` object is created when you move funds between Stripe accounts as -# part of Connect. -# -# Before April 6, 2017, transfers also represented movement of funds from a -# Stripe account to a card or bank account. This behavior has since been split -# out into a [Payout](https://stripe.com/docs/api#payout_object) object, with corresponding payout endpoints. For more -# information, read about the -# [transfer/payout split](https://stripe.com/docs/transfer-payout-split). -# -# Related guide: [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/charges-transfers). -# -# source://stripe//lib/stripe/resources/transfer.rb#15 -class Stripe::Transfer < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - extend ::Stripe::APIOperations::NestedResource - - class << self - # source://stripe//lib/stripe/api_operations/nested_resource.rb#47 - def create_reversal(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#87 - def list_reversals(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#57 - def retrieve_reversal(id, nested_id, opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#22 - def reversals_url(id, nested_id = T.unsafe(nil)); end - - # source://stripe//lib/stripe/api_operations/nested_resource.rb#67 - def update_reversal(id, nested_id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/transfer.rb#21 -Stripe::Transfer::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#5 -module Stripe::Treasury; end - -# You can reverse some [ReceivedCredits](https://stripe.com/docs/api#received_credits) depending on their network and source flow. Reversing a ReceivedCredit leads to the creation of a new object known as a CreditReversal. -# -# source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#7 -class Stripe::Treasury::CreditReversal < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/treasury/credit_reversal.rb#11 -Stripe::Treasury::CreditReversal::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# You can reverse some [ReceivedDebits](https://stripe.com/docs/api#received_debits) depending on their network and source flow. Reversing a ReceivedDebit leads to the creation of a new object known as a DebitReversal. -# -# source://stripe//lib/stripe/resources/treasury/debit_reversal.rb#7 -class Stripe::Treasury::DebitReversal < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/treasury/debit_reversal.rb#11 -Stripe::Treasury::DebitReversal::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Stripe Treasury provides users with a container for money called a FinancialAccount that is separate from their Payments balance. -# FinancialAccounts serve as the source and destination of Treasury's money movement APIs. -# -# source://stripe//lib/stripe/resources/treasury/financial_account.rb#8 -class Stripe::Treasury::FinancialAccount < ::Stripe::APIResource - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods - - # source://stripe//lib/stripe/resources/treasury/financial_account.rb#15 - def retrieve_features(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/financial_account.rb#24 - def update_features(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/treasury/financial_account.rb#33 - def retrieve_features(financial_account, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/financial_account.rb#42 - def update_features(financial_account, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/financial_account.rb#13 -Stripe::Treasury::FinancialAccount::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Use [InboundTransfers](https://stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers) to add funds to your [FinancialAccount](https://stripe.com/docs/api#financial_accounts) via a PaymentMethod that is owned by you. The funds will be transferred via an ACH debit. -# -# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#7 -class Stripe::Treasury::InboundTransfer < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#13 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#31 - def test_helpers; end - - class << self - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#22 - def cancel(inbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#11 -Stripe::Treasury::InboundTransfer::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#35 -class Stripe::Treasury::InboundTransfer::TestHelpers < ::Stripe::APIResourceTestHelpers - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#65 - def fail(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#74 - def return_inbound_transfer(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#83 - def succeed(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#38 - def fail(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#47 - def return_inbound_transfer(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#56 - def succeed(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/inbound_transfer.rb#36 -Stripe::Treasury::InboundTransfer::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::InboundTransfer - -# Use OutboundPayments to send funds to another party's external bank account or [FinancialAccount](https://stripe.com/docs/api#financial_accounts). To send money to an account belonging to the same user, use an [OutboundTransfer](https://stripe.com/docs/api#outbound_transfers). -# -# Simulate OutboundPayment state changes with the `/v1/test_helpers/treasury/outbound_payments` endpoints. These methods can only be called on test mode objects. -# -# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#9 -class Stripe::Treasury::OutboundPayment < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#15 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#33 - def test_helpers; end - - class << self - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#24 - def cancel(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#13 -Stripe::Treasury::OutboundPayment::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#37 -class Stripe::Treasury::OutboundPayment::TestHelpers < ::Stripe::APIResourceTestHelpers - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#67 - def fail(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#76 - def post(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#85 - def return_outbound_payment(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#40 - def fail(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#49 - def post(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#58 - def return_outbound_payment(id, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/outbound_payment.rb#38 -Stripe::Treasury::OutboundPayment::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::OutboundPayment - -# Use OutboundTransfers to transfer funds from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) to a PaymentMethod belonging to the same entity. To send funds to a different party, use [OutboundPayments](https://stripe.com/docs/api#outbound_payments) instead. You can send funds over ACH rails or through a domestic wire transfer to a user's own external bank account. -# -# Simulate OutboundTransfer state changes with the `/v1/test_helpers/treasury/outbound_transfers` endpoints. These methods can only be called on test mode objects. -# -# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#9 -class Stripe::Treasury::OutboundTransfer < ::Stripe::APIResource - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#15 - def cancel(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#33 - def test_helpers; end - - class << self - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#24 - def cancel(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#13 -Stripe::Treasury::OutboundTransfer::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#37 -class Stripe::Treasury::OutboundTransfer::TestHelpers < ::Stripe::APIResourceTestHelpers - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#71 - def fail(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#80 - def post(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#89 - def return_outbound_transfer(params = T.unsafe(nil), opts = T.unsafe(nil)); end - - class << self - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#40 - def fail(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#49 - def post(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - - # source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#58 - def return_outbound_transfer(outbound_transfer, params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/outbound_transfer.rb#38 -Stripe::Treasury::OutboundTransfer::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::OutboundTransfer - -# ReceivedCredits represent funds sent to a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) (for example, via ACH or wire). These money movements are not initiated from the FinancialAccount. -# -# source://stripe//lib/stripe/resources/treasury/received_credit.rb#7 -class Stripe::Treasury::ReceivedCredit < ::Stripe::APIResource - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/treasury/received_credit.rb#12 - def test_helpers; end -end - -# source://stripe//lib/stripe/resources/treasury/received_credit.rb#10 -Stripe::Treasury::ReceivedCredit::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/treasury/received_credit.rb#16 -class Stripe::Treasury::ReceivedCredit::TestHelpers < ::Stripe::APIResourceTestHelpers - class << self - # source://stripe//lib/stripe/resources/treasury/received_credit.rb#19 - def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/received_credit.rb#17 -Stripe::Treasury::ReceivedCredit::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::ReceivedCredit - -# ReceivedDebits represent funds pulled from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts). These are not initiated from the FinancialAccount. -# -# source://stripe//lib/stripe/resources/treasury/received_debit.rb#7 -class Stripe::Treasury::ReceivedDebit < ::Stripe::APIResource - extend ::Stripe::APIOperations::List - - # source://stripe//lib/stripe/resources/treasury/received_debit.rb#12 - def test_helpers; end -end - -# source://stripe//lib/stripe/resources/treasury/received_debit.rb#10 -Stripe::Treasury::ReceivedDebit::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/treasury/received_debit.rb#16 -class Stripe::Treasury::ReceivedDebit::TestHelpers < ::Stripe::APIResourceTestHelpers - class << self - # source://stripe//lib/stripe/resources/treasury/received_debit.rb#19 - def create(params = T.unsafe(nil), opts = T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/resources/treasury/received_debit.rb#17 -Stripe::Treasury::ReceivedDebit::TestHelpers::RESOURCE_CLASS = Stripe::Treasury::ReceivedDebit - -# Transactions represent changes to a [FinancialAccount's](https://stripe.com/docs/api#financial_accounts) balance. -# -# source://stripe//lib/stripe/resources/treasury/transaction.rb#7 -class Stripe::Treasury::Transaction < ::Stripe::APIResource - extend ::Stripe::APIOperations::List -end - -# source://stripe//lib/stripe/resources/treasury/transaction.rb#10 -Stripe::Treasury::Transaction::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# TransactionEntries represent individual units of money movements within a single [Transaction](https://stripe.com/docs/api#transactions). -# -# source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#7 -class Stripe::Treasury::TransactionEntry < ::Stripe::APIResource - extend ::Stripe::APIOperations::List - - class << self - # source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#12 - def resource_url; end - end -end - -# source://stripe//lib/stripe/resources/treasury/transaction_entry.rb#10 -Stripe::Treasury::TransactionEntry::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# Usage records allow you to report customer usage and metrics to Stripe for -# metered billing of subscription prices. -# -# Related guide: [Metered Billing](https://stripe.com/docs/billing/subscriptions/metered-billing). -# -# source://stripe//lib/stripe/resources/usage_record.rb#9 -class Stripe::UsageRecord < ::Stripe::APIResource; end - -# source://stripe//lib/stripe/resources/usage_record.rb#10 -Stripe::UsageRecord::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/resources/usage_record_summary.rb#5 -class Stripe::UsageRecordSummary < ::Stripe::StripeObject; end - -# source://stripe//lib/stripe/resources/usage_record_summary.rb#6 -Stripe::UsageRecordSummary::OBJECT_NAME = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/util.rb#6 -module Stripe::Util - class << self - # @raise [TypeError] - # - # source://stripe//lib/stripe/util.rb#299 - def check_api_key!(key); end - - # @raise [TypeError] - # - # source://stripe//lib/stripe/util.rb#293 - def check_string_argument!(key); end - - # Converts a hash of fields or an array of hashes into a +StripeObject+ or - # array of +StripeObject+s. These new objects will be created as a concrete - # type as dictated by their `object` field (e.g. an `object` value of - # `charge` would create an instance of +Charge+), but if `object` is not - # present or of an unknown type, the newly created instance will fall back - # to being a +StripeObject+. - # - # ==== Attributes - # - # * +data+ - Hash of fields and values to be converted into a StripeObject. - # * +params+ - Params for +StripeObject+ like filters used in search that - # will be reused on subsequent API calls. - # * +opts+ - Options for +StripeObject+ like an API key that will be reused - # on subsequent API calls. - # - # source://stripe//lib/stripe/util.rb#111 - def convert_to_stripe_object(data, opts = T.unsafe(nil)); end - - # Converts a hash of fields or an array of hashes into a +StripeObject+ or - # array of +StripeObject+s. These new objects will be created as a concrete - # type as dictated by their `object` field (e.g. an `object` value of - # `charge` would create an instance of +Charge+), but if `object` is not - # present or of an unknown type, the newly created instance will fall back - # to being a +StripeObject+. - # - # ==== Attributes - # - # * +data+ - Hash of fields and values to be converted into a StripeObject. - # * +opts+ - Options for +StripeObject+ like an API key that will be reused - # on subsequent API calls. - # - # source://stripe//lib/stripe/util.rb#127 - def convert_to_stripe_object_with_params(data, params, opts = T.unsafe(nil)); end - - # Adds a custom method to a resource class. This is used to add support for - # non-CRUDL API requests, e.g. capturing charges. custom_method takes the - # following parameters: - # - name: the name of the custom method to create (as a symbol) - # - http_verb: the HTTP verb for the API request (:get, :post, or :delete) - # - http_path: the path to append to the resource's URL. If not provided, - # the name is used as the path - # - resource: the resource implementation class - # - target: the class that custom static method will be added to - # - # For example, this call: - # custom_method :capture, http_verb: post - # adds a `capture` class method to the resource class that, when called, - # will send a POST request to `/v1//capture`. - # - # source://stripe//lib/stripe/util.rb#64 - def custom_method(resource, target, name, http_verb, http_path); end - - # Encodes a hash of parameters in a way that's suitable for use as query - # parameters in a URI or as form parameters in a request body. This mainly - # involves escaping special characters from parameter keys and values (e.g. - # `&`). - # - # source://stripe//lib/stripe/util.rb#206 - def encode_parameters(params); end - - # source://stripe//lib/stripe/util.rb#222 - def flatten_params(params, parent_key = T.unsafe(nil)); end - - # source://stripe//lib/stripe/util.rb#241 - def flatten_params_array(value, calculated_key); end - - # source://stripe//lib/stripe/util.rb#172 - def log_debug(message, data = T.unsafe(nil)); end - - # source://stripe//lib/stripe/util.rb#152 - def log_error(message, data = T.unsafe(nil)); end - - # source://stripe//lib/stripe/util.rb#162 - def log_info(message, data = T.unsafe(nil)); end - - # `Time.now` can be unstable in cases like an administrator manually - # updating its value or a reconcilation via NTP. For this reason, prefer - # the use of the system's monotonic clock especially where comparing times - # to calculate an elapsed duration. - # - # Shortcut for getting monotonic time, mostly for purposes of line length - # and test stubbing. Returns time in seconds since the event used for - # monotonic reference purposes by the platform (e.g. system boot time). - # - # source://stripe//lib/stripe/util.rb#263 - def monotonic_time; end - - # Normalizes header keys so that they're all lower case and each - # hyphen-delimited section starts with a single capitalized letter. For - # example, `request-id` becomes `Request-Id`. This is useful for extracting - # certain key values when the user could have set them with a variety of - # diffent naming schemes. - # - # source://stripe//lib/stripe/util.rb#310 - def normalize_headers(headers); end - - # source://stripe//lib/stripe/util.rb#267 - def normalize_id(id); end - - # The secondary opts argument can either be a string or hash - # Turn this value into an api_key and a set of headers - # - # source://stripe//lib/stripe/util.rb#279 - def normalize_opts(opts); end - - # source://stripe//lib/stripe/util.rb#42 - def object_classes; end - - # @return [Boolean] - # - # source://stripe//lib/stripe/util.rb#46 - def object_name_matches_class?(object_name, klass); end - - # source://stripe//lib/stripe/util.rb#27 - def objects_to_ids(obj); end - - # Generates a Dashboard link to inspect a request ID based off of a request - # ID value and an API key, which is used to attempt to extract whether the - # environment is livemode or testmode. - # - # source://stripe//lib/stripe/util.rb#322 - def request_id_dashboard_url(request_id, api_key); end - - # Constant time string comparison to prevent timing attacks - # Code borrowed from ActiveSupport - # - # source://stripe//lib/stripe/util.rb#329 - def secure_compare(str_a, str_b); end - - # source://stripe//lib/stripe/util.rb#182 - def symbolize_names(object); end - - # Encodes a string in a way that makes it suitable for use in a set of - # query parameters in a URI or in a set of form parameters in a request - # body. - # - # source://stripe//lib/stripe/util.rb#214 - def url_encode(key); end - - private - - # Uses an ANSI escape code to colorize text if it's going to be sent to a - # TTY. - # - # source://stripe//lib/stripe/util.rb#358 - def colorize(val, color, isatty); end - - # Turns an integer log level into a printable name. - # - # source://stripe//lib/stripe/util.rb#370 - def level_name(level); end - - # source://stripe//lib/stripe/util.rb#380 - def log_internal(message, data = T.unsafe(nil), color:, level:, logger:, out:); end - - # Wraps a value in double quotes if it looks sufficiently complex so that - # it can be read by logfmt parsers. - # - # source://stripe//lib/stripe/util.rb#412 - def wrap_logfmt_value(val); end - end -end - -# private -# -# source://stripe//lib/stripe/util.rb#343 -Stripe::Util::COLOR_CODES = T.let(T.unsafe(nil), Hash) - -# Options that should be copyable from one StripeObject to another -# including options that may be internal. -# -# source://stripe//lib/stripe/util.rb#17 -Stripe::Util::OPTS_COPYABLE = T.let(T.unsafe(nil), Set) - -# Options that should be persisted between API requests. This includes -# client, which is an object containing an HTTP client to reuse. -# -# source://stripe//lib/stripe/util.rb#23 -Stripe::Util::OPTS_PERSISTABLE = T.let(T.unsafe(nil), Set) - -# Options that a user is allowed to specify. -# -# source://stripe//lib/stripe/util.rb#8 -Stripe::Util::OPTS_USER_SPECIFIED = T.let(T.unsafe(nil), Set) - -# source://stripe//lib/stripe/version.rb#4 -Stripe::VERSION = T.let(T.unsafe(nil), String) - -# source://stripe//lib/stripe/webhook.rb#4 -module Stripe::Webhook - class << self - # Initializes an Event object from a JSON payload. - # - # This may raise JSON::ParserError if the payload is not valid JSON, or - # SignatureVerificationError if the signature verification fails. - # - # source://stripe//lib/stripe/webhook.rb#11 - def construct_event(payload, sig_header, secret, tolerance: T.unsafe(nil)); end - end -end - -# source://stripe//lib/stripe/webhook.rb#5 -Stripe::Webhook::DEFAULT_TOLERANCE = T.let(T.unsafe(nil), Integer) - -# source://stripe//lib/stripe/webhook.rb#24 -module Stripe::Webhook::Signature - class << self - # Computes a webhook signature given a time (probably the current time), - # a payload, and a signing secret. - # - # @raise [ArgumentError] - # - # source://stripe//lib/stripe/webhook.rb#29 - def compute_signature(timestamp, payload, secret); end - - # Generates a value that would be added to a `Stripe-Signature` for a - # given webhook payload. - # - # Note that this isn't needed to verify webhooks in any way, and is - # mainly here for use in test cases (those that are both within this - # project and without). - # - # @raise [ArgumentError] - # - # source://stripe//lib/stripe/webhook.rb#48 - def generate_header(timestamp, signature, scheme: T.unsafe(nil)); end - - # Verifies the signature header for a given payload. - # - # Raises a SignatureVerificationError in the following cases: - # - the header does not match the expected format - # - no signatures found with the expected scheme - # - no signatures matching the expected signature - # - a tolerance is provided and the timestamp is not within the - # tolerance - # - # Returns true otherwise - # - # source://stripe//lib/stripe/webhook.rb#79 - def verify_header(payload, header, secret, tolerance: T.unsafe(nil)); end - - private - - # Extracts the timestamp and the signature(s) with the desired scheme - # from the header - # - # source://stripe//lib/stripe/webhook.rb#61 - def get_timestamp_and_signatures(header, scheme); end - end -end - -# source://stripe//lib/stripe/webhook.rb#25 -Stripe::Webhook::Signature::EXPECTED_SCHEME = T.let(T.unsafe(nil), String) - -# You can configure [webhook endpoints](https://stripe.com/docs/webhooks/) via the API to be -# notified about events that happen in your Stripe account or connected -# accounts. -# -# Most users configure webhooks from [the dashboard](https://dashboard.stripe.com/webhooks), which provides a user interface for registering and testing your webhook endpoints. -# -# Related guide: [Setting up Webhooks](https://stripe.com/docs/webhooks/configure). -# -# source://stripe//lib/stripe/resources/webhook_endpoint.rb#12 -class Stripe::WebhookEndpoint < ::Stripe::APIResource - include ::Stripe::APIOperations::Delete - include ::Stripe::APIOperations::Save - extend ::Stripe::APIOperations::Create - extend ::Stripe::APIOperations::Delete::ClassMethods - extend ::Stripe::APIOperations::List - extend ::Stripe::APIOperations::Save::ClassMethods -end - -# source://stripe//lib/stripe/resources/webhook_endpoint.rb#18 -Stripe::WebhookEndpoint::OBJECT_NAME = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/strscan@3.1.0.rbi b/sorbet/rbi/gems/strscan@3.1.0.rbi new file mode 100644 index 000000000..1f754d979 --- /dev/null +++ b/sorbet/rbi/gems/strscan@3.1.0.rbi @@ -0,0 +1,9 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `strscan` gem. +# Please instead update this file by running `bin/tapioca gem strscan`. + + +# THIS IS AN EMPTY RBI FILE. +# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/sync@0.5.0.rbi b/sorbet/rbi/gems/sync@0.5.0.rbi index 7da0b5ba7..652c27fbc 100644 --- a/sorbet/rbi/gems/sync@0.5.0.rbi +++ b/sorbet/rbi/gems/sync@0.5.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `sync` gem. # Please instead update this file by running `bin/tapioca gem sync`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/syntax_tree@6.1.1.rbi b/sorbet/rbi/gems/syntax_tree@6.1.1.rbi deleted file mode 100644 index ad0078698..000000000 --- a/sorbet/rbi/gems/syntax_tree@6.1.1.rbi +++ /dev/null @@ -1,8 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `syntax_tree` gem. -# Please instead update this file by running `bin/tapioca gem syntax_tree`. - -# THIS IS AN EMPTY RBI FILE. -# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/sys-uname@1.2.3.rbi b/sorbet/rbi/gems/sys-uname@1.3.0.rbi similarity index 77% rename from sorbet/rbi/gems/sys-uname@1.2.3.rbi rename to sorbet/rbi/gems/sys-uname@1.3.0.rbi index 715cbb4ee..36be9b851 100644 --- a/sorbet/rbi/gems/sys-uname@1.2.3.rbi +++ b/sorbet/rbi/gems/sys-uname@1.3.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `sys-uname` gem. # Please instead update this file by running `bin/tapioca gem sys-uname`. + # The Sys module provides a namespace only. # # source://sys-uname//lib/sys/uname.rb#3 @@ -18,42 +19,35 @@ class Sys::Platform # # @return [Boolean] # - # source://sys-uname//lib/sys/platform.rb#54 + # source://sys-uname//lib/sys/platform.rb#47 def bsd?; end # Returns whether or not you're on Linux # # @return [Boolean] # - # source://sys-uname//lib/sys/platform.rb#44 + # source://sys-uname//lib/sys/platform.rb#42 def linux?; end # Returns whether or not you're on a mac, i.e. OSX # # @return [Boolean] # - # source://sys-uname//lib/sys/platform.rb#39 + # source://sys-uname//lib/sys/platform.rb#37 def mac?; end - # Returns whether or not you're on Solaris - # - # @return [Boolean] - # - # source://sys-uname//lib/sys/platform.rb#49 - def solaris?; end - # Returns whether or not you're on a Unixy (non-Windows) OS # # @return [Boolean] # - # source://sys-uname//lib/sys/platform.rb#34 + # source://sys-uname//lib/sys/platform.rb#32 def unix?; end # Returns whether or not you're on a Windows OS # # @return [Boolean] # - # source://sys-uname//lib/sys/platform.rb#29 + # source://sys-uname//lib/sys/platform.rb#27 def windows?; end end end @@ -84,38 +78,37 @@ Sys::Platform::VERSION = T.let(T.unsafe(nil), String) class Sys::Uname extend ::FFI::Library - def sysctl(*_arg0); end def sysinfo(*_arg0); end def uname_c(*_arg0); end class << self # Returns the CPU architecture, e.g. "x86" # - # source://sys-uname//lib/sys/unix/uname.rb#241 + # source://sys-uname//lib/sys/unix/uname.rb#205 def architecture; end # The string consisting of the ASCII hexidecimal encoding of the name # of the interface configured by boot(1M) followed by the DHCPACK reply # from the server. # - # source://sys-uname//lib/sys/unix/uname.rb#255 + # source://sys-uname//lib/sys/unix/uname.rb#219 def dhcp_cache; end # The name of the of the hardware provider. # - # source://sys-uname//lib/sys/unix/uname.rb#275 + # source://sys-uname//lib/sys/unix/uname.rb#239 def hw_provider; end # The ASCII representation of the hardware-specific serial number # of the physical machine on which the function is executed. # - # source://sys-uname//lib/sys/unix/uname.rb#269 + # source://sys-uname//lib/sys/unix/uname.rb#233 def hw_serial; end # The variant instruction set architectures executable on the # current system. # - # source://sys-uname//lib/sys/unix/uname.rb#262 + # source://sys-uname//lib/sys/unix/uname.rb#226 def isa_list; end # Returns the machine hardware type. e.g. "i686". @@ -124,7 +117,7 @@ class Sys::Uname # were unknown to the OS when the OS was originally released. It # appears that MS doesn't necessarily patch this, either. # - # source://sys-uname//lib/sys/unix/uname.rb#221 + # source://sys-uname//lib/sys/unix/uname.rb#185 def machine; end # Returns the model type. @@ -133,40 +126,40 @@ class Sys::Uname # # Uname.model # => 'MacBookPro5,3' # - # source://sys-uname//lib/sys/unix/uname.rb#232 + # source://sys-uname//lib/sys/unix/uname.rb#196 def model; end # Returns the nodename. This is usually, but not necessarily, the # same as the system's hostname. # - # source://sys-uname//lib/sys/unix/uname.rb#191 + # source://sys-uname//lib/sys/unix/uname.rb#155 def nodename; end # The specific model of the hardware platform, e.g Sun-Blade-1500, etc. # - # source://sys-uname//lib/sys/unix/uname.rb#247 + # source://sys-uname//lib/sys/unix/uname.rb#211 def platform; end # Returns the release number, e.g. 5.1.2600. # - # source://sys-uname//lib/sys/unix/uname.rb#201 + # source://sys-uname//lib/sys/unix/uname.rb#165 def release; end # The Secure Remote Procedure Call domain name. # - # source://sys-uname//lib/sys/unix/uname.rb#281 + # source://sys-uname//lib/sys/unix/uname.rb#245 def srpc_domain; end # Returns the operating system name, e.g. "Microsoft Windows XP Home" # - # source://sys-uname//lib/sys/unix/uname.rb#179 + # source://sys-uname//lib/sys/unix/uname.rb#143 def sysname; end # Returns a struct of type UnameStruct that contains sysname, nodename, # machine, version, and release, as well as a plethora of other fields. # Please see the MSDN documentation for what each of these fields mean. # - # source://sys-uname//lib/sys/unix/uname.rb#126 + # source://sys-uname//lib/sys/unix/uname.rb#109 def uname; end # Returns the version plus patch information of the operating system, @@ -176,22 +169,16 @@ class Sys::Uname # the 'InstancesOf' method to get the data we need, rather than # including it as part of the connection. # - # source://sys-uname//lib/sys/unix/uname.rb#211 + # source://sys-uname//lib/sys/unix/uname.rb#175 def version; end private # Returns the model for systems that define sysctl(). # - # source://sys-uname//lib/sys/unix/uname.rb#290 + # source://sys-uname//lib/sys/unix/uname.rb#254 def get_model; end - # Returns the various sysinfo information based on +flag+. - # - # source://sys-uname//lib/sys/unix/uname.rb#304 - def get_si(flag); end - - def sysctl(*_arg0); end def sysinfo(*_arg0); end def uname_c(*_arg0); end end @@ -200,61 +187,55 @@ end # source://sys-uname//lib/sys/unix/uname.rb#22 Sys::Uname::BUFSIZE = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#38 -Sys::Uname::CTL_HW = T.let(T.unsafe(nil), Integer) - # This is the error raised if any of the Sys::Uname methods should fail. # # source://sys-uname//lib/sys/unix/uname.rb#15 class Sys::Uname::Error < ::StandardError; end -# source://sys-uname//lib/sys/unix/uname.rb#39 -Sys::Uname::HW_MODEL = T.let(T.unsafe(nil), Integer) - -# source://sys-uname//lib/sys/unix/uname.rb#53 +# source://sys-uname//lib/sys/unix/uname.rb#51 Sys::Uname::SI_ARCHITECTURE = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#59 +# source://sys-uname//lib/sys/unix/uname.rb#57 Sys::Uname::SI_DHCP_CACHE = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#49 +# source://sys-uname//lib/sys/unix/uname.rb#47 Sys::Uname::SI_HOSTNAME = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#55 +# source://sys-uname//lib/sys/unix/uname.rb#53 Sys::Uname::SI_HW_PROVIDER = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#54 +# source://sys-uname//lib/sys/unix/uname.rb#52 Sys::Uname::SI_HW_SERIAL = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#58 +# source://sys-uname//lib/sys/unix/uname.rb#56 Sys::Uname::SI_ISALIST = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#52 +# source://sys-uname//lib/sys/unix/uname.rb#50 Sys::Uname::SI_MACHINE = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#57 +# source://sys-uname//lib/sys/unix/uname.rb#55 Sys::Uname::SI_PLATFORM = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#50 +# source://sys-uname//lib/sys/unix/uname.rb#48 Sys::Uname::SI_RELEASE = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#56 +# source://sys-uname//lib/sys/unix/uname.rb#54 Sys::Uname::SI_SRPC_DOMAIN = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#48 +# source://sys-uname//lib/sys/unix/uname.rb#46 Sys::Uname::SI_SYSNAME = T.let(T.unsafe(nil), Integer) -# source://sys-uname//lib/sys/unix/uname.rb#51 +# source://sys-uname//lib/sys/unix/uname.rb#49 Sys::Uname::SI_VERSION = T.let(T.unsafe(nil), Integer) # FFI class passed to the underlying C uname function. # -# source://sys-uname//lib/sys/unix/uname.rb#65 +# source://sys-uname//lib/sys/unix/uname.rb#63 class Sys::Uname::UnameFFIStruct < ::FFI::Struct; end # The UnameStruct is used to store platform information for some methods. # -# source://sys-uname//lib/sys/unix/uname.rb#109 +# source://sys-uname//lib/sys/unix/uname.rb#94 Sys::Uname::UnameStruct = Struct # The version of the sys-uname gem. diff --git a/sorbet/rbi/gems/tapioca@0.10.5.rbi b/sorbet/rbi/gems/tapioca@0.16.0.rbi similarity index 73% rename from sorbet/rbi/gems/tapioca@0.10.5.rbi rename to sorbet/rbi/gems/tapioca@0.16.0.rbi index e5749af72..9ef5d7a3b 100644 --- a/sorbet/rbi/gems/tapioca@0.10.5.rbi +++ b/sorbet/rbi/gems/tapioca@0.16.0.rbi @@ -1,11 +1,31 @@ -# typed: false +# typed: true # DO NOT EDIT MANUALLY # This is an autogenerated file for types exported from the `tapioca` gem. # Please instead update this file by running `bin/tapioca gem tapioca`. + class Bundler::Dependency < ::Gem::Dependency - include ::Tapioca::Gemfile::AutoRequireHook + include ::Tapioca::BundlerExt::AutoRequireHook +end + +# source://tapioca//lib/tapioca/helpers/git_attributes.rb#4 +class GitAttributes + class << self + # source://tapioca//lib/tapioca/helpers/git_attributes.rb#9 + sig { params(path: ::Pathname).void } + def create_generated_attribute_file(path); end + + # source://tapioca//lib/tapioca/helpers/git_attributes.rb#16 + sig { params(path: ::Pathname).void } + def create_vendored_attribute_file(path); end + + private + + # source://tapioca//lib/tapioca/helpers/git_attributes.rb#25 + sig { params(path: ::Pathname, content: ::String).void } + def create_gitattributes_file(path, content); end + end end # We need to do the alias-method-chain dance since Bootsnap does the same, @@ -30,21 +50,12 @@ class Module def prepend_features(constant); end end -# source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#13 -Module::DELEGATION_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) - -# source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#14 -Module::DELEGATION_RESERVED_METHOD_NAMES = T.let(T.unsafe(nil), Set) - -# source://activesupport/7.0.5/lib/active_support/core_ext/module/delegation.rb#10 -Module::RUBY_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array) - # source://tapioca//lib/tapioca/rbi_ext/model.rb#4 module RBI; end # source://tapioca//lib/tapioca/rbi_ext/model.rb#5 class RBI::Tree < ::RBI::NodeWithComments - # source://rbi/0.0.16/lib/rbi/model.rb#115 + # source://rbi/0.1.14/lib/rbi/model.rb#121 sig do params( loc: T.nilable(::RBI::Loc), @@ -54,19 +65,15 @@ class RBI::Tree < ::RBI::NodeWithComments end def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end - # source://rbi/0.0.16/lib/rbi/model.rb#122 + # source://rbi/0.1.14/lib/rbi/model.rb#128 sig { params(node: ::RBI::Node).void } def <<(node); end - # source://rbi/0.0.16/lib/rbi/printer.rb#224 - sig { override.params(v: ::RBI::Printer).void } - def accept_printer(v); end - - # source://rbi/0.0.16/lib/rbi/rewriters/add_sig_templates.rb#66 + # source://rbi/0.1.14/lib/rbi/rewriters/add_sig_templates.rb#66 sig { params(with_todo_comment: T::Boolean).void } def add_sig_templates!(with_todo_comment: T.unsafe(nil)); end - # source://rbi/0.0.16/lib/rbi/rewriters/annotate.rb#48 + # source://rbi/0.1.14/lib/rbi/rewriters/annotate.rb#49 sig { params(annotation: ::String, annotate_scopes: T::Boolean, annotate_properties: T::Boolean).void } def annotate!(annotation, annotate_scopes: T.unsafe(nil), annotate_properties: T.unsafe(nil)); end @@ -92,18 +99,19 @@ class RBI::Tree < ::RBI::NodeWithComments sig { params(name: ::String).void } def create_include(name); end - # source://tapioca//lib/tapioca/rbi_ext/model.rb#89 + # source://tapioca//lib/tapioca/rbi_ext/model.rb#90 sig do params( name: ::String, parameters: T::Array[::RBI::TypedParam], - return_type: ::String, + return_type: T.nilable(::String), class_method: T::Boolean, visibility: ::RBI::Visibility, - comments: T::Array[::RBI::Comment] + comments: T::Array[::RBI::Comment], + block: T.nilable(T.proc.params(node: ::RBI::Method).void) ).void end - def create_method(name, parameters: T.unsafe(nil), return_type: T.unsafe(nil), class_method: T.unsafe(nil), visibility: T.unsafe(nil), comments: T.unsafe(nil)); end + def create_method(name, parameters: T.unsafe(nil), return_type: T.unsafe(nil), class_method: T.unsafe(nil), visibility: T.unsafe(nil), comments: T.unsafe(nil), &block); end # source://tapioca//lib/tapioca/rbi_ext/model.rb#60 sig { params(name: ::String).void } @@ -114,7 +122,7 @@ class RBI::Tree < ::RBI::NodeWithComments def create_module(name, &block); end # source://tapioca//lib/tapioca/rbi_ext/model.rb#9 - sig { params(constant: ::Module, block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)).void } + sig { params(constant: ::Module, block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)).returns(::RBI::Scope) } def create_path(constant, &block); end # source://tapioca//lib/tapioca/rbi_ext/model.rb#74 @@ -130,23 +138,27 @@ class RBI::Tree < ::RBI::NodeWithComments end def create_type_variable(name, type:, variance: T.unsafe(nil), fixed: T.unsafe(nil), upper: T.unsafe(nil), lower: T.unsafe(nil)); end - # source://rbi/0.0.16/lib/rbi/rewriters/deannotate.rb#40 + # source://rbi/0.1.14/lib/rbi/rewriters/deannotate.rb#41 sig { params(annotation: ::String).void } def deannotate!(annotation); end - # source://rbi/0.0.16/lib/rbi/model.rb#128 + # source://rbi/0.1.14/lib/rbi/model.rb#134 sig { returns(T::Boolean) } def empty?; end - # source://rbi/0.0.16/lib/rbi/rewriters/group_nodes.rb#38 + # source://rbi/0.1.14/lib/rbi/rewriters/filter_versions.rb#118 + sig { params(version: ::Gem::Version).void } + def filter_versions!(version); end + + # source://rbi/0.1.14/lib/rbi/rewriters/group_nodes.rb#81 sig { void } def group_nodes!; end - # source://rbi/0.0.16/lib/rbi/index.rb#64 + # source://rbi/0.1.14/lib/rbi/index.rb#68 sig { returns(::RBI::Index) } def index; end - # source://rbi/0.0.16/lib/rbi/rewriters/merge_trees.rb#318 + # source://rbi/0.1.14/lib/rbi/rewriters/merge_trees.rb#324 sig do params( other: ::RBI::Tree, @@ -157,61 +169,63 @@ class RBI::Tree < ::RBI::NodeWithComments end def merge(other, left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end - # source://rbi/0.0.16/lib/rbi/rewriters/nest_non_public_methods.rb#45 + # source://rbi/0.1.14/lib/rbi/rewriters/nest_non_public_methods.rb#46 sig { void } def nest_non_public_methods!; end - # source://rbi/0.0.16/lib/rbi/rewriters/nest_singleton_methods.rb#35 + # source://rbi/0.1.14/lib/rbi/rewriters/nest_singleton_methods.rb#36 sig { void } def nest_singleton_methods!; end - # source://rbi/0.0.16/lib/rbi/model.rb#106 + # source://rbi/0.1.14/lib/rbi/model.rb#112 sig { returns(T::Array[::RBI::Node]) } def nodes; end - # source://rbi/0.0.16/lib/rbi/printer.rb#231 - sig { override.returns(T::Boolean) } - def oneline?; end + # source://rbi/0.1.14/lib/rbi/rewriters/attr_to_methods.rb#53 + sig { void } + def replace_attributes_with_methods!; end - # source://rbi/0.0.16/lib/rbi/rewriters/sort_nodes.rb#107 + # source://rbi/0.1.14/lib/rbi/rewriters/sort_nodes.rb#119 sig { void } def sort_nodes!; end private - # source://tapioca//lib/tapioca/rbi_ext/model.rb#116 + # source://tapioca//lib/tapioca/rbi_ext/model.rb#123 sig { params(node: ::RBI::Node).returns(::RBI::Node) } def create_node(node); end - # source://tapioca//lib/tapioca/rbi_ext/model.rb#111 + # source://tapioca//lib/tapioca/rbi_ext/model.rb#118 sig { returns(T::Hash[::String, ::RBI::Node]) } def nodes_cache; end end -# source://tapioca//lib/tapioca/rbi_ext/model.rb#126 +# source://tapioca//lib/tapioca/rbi_ext/model.rb#133 class RBI::TypedParam < ::T::Struct const :param, ::RBI::Param const :type, ::String class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 def inherited(s); end end end -# source://rbi/0.0.16/lib/rbi/version.rb#5 -RBI::VERSION = T.let(T.unsafe(nil), String) - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#5 module T::Generic + include ::Kernel + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#13 def [](*types); end + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#47 + def has_attached_class!(variance = T.unsafe(nil), &bounds_proc); end + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#21 - def type_member(variance = T.unsafe(nil), fixed: T.unsafe(nil), lower: T.unsafe(nil), upper: T.unsafe(nil), &bounds_proc); end + def type_member(variance = T.unsafe(nil), &bounds_proc); end - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#37 - def type_template(variance = T.unsafe(nil), fixed: T.unsafe(nil), lower: T.unsafe(nil), upper: T.unsafe(nil), &bounds_proc); end + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#34 + def type_template(variance = T.unsafe(nil), &bounds_proc); end end # This module intercepts calls to generic type instantiations and type variable definitions. @@ -226,11 +240,14 @@ module T::Generic::TypeStoragePatch # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#13 def [](*types); end + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#47 + def has_attached_class!(variance = T.unsafe(nil), &bounds_proc); end + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#21 - def type_member(variance = T.unsafe(nil), fixed: T.unsafe(nil), lower: T.unsafe(nil), upper: T.unsafe(nil), &bounds_proc); end + def type_member(variance = T.unsafe(nil), &bounds_proc); end - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#37 - def type_template(variance = T.unsafe(nil), fixed: T.unsafe(nil), lower: T.unsafe(nil), upper: T.unsafe(nil), &bounds_proc); end + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#34 + def type_template(variance = T.unsafe(nil), &bounds_proc); end end # source://tapioca//lib/tapioca/sorbet_ext/proc_bind_patch.rb#28 @@ -241,9 +258,6 @@ module T::Private::Methods end end -# source://sorbet-runtime/0.5.10601/lib/types/private/methods/_methods.rb#29 -T::Private::Methods::ARG_NOT_PROVIDED = T.let(T.unsafe(nil), Object) - class T::Private::Methods::Declaration < ::Struct def bind; end def bind=(_); end @@ -298,18 +312,12 @@ class T::Private::Methods::DeclarationBlock < ::Struct end end -# source://sorbet-runtime/0.5.10601/lib/types/private/methods/_methods.rb#30 -T::Private::Methods::PROC_TYPE = T.let(T.unsafe(nil), Object) - # source://tapioca//lib/tapioca/sorbet_ext/proc_bind_patch.rb#29 module T::Private::Methods::ProcBindPatch # source://tapioca//lib/tapioca/sorbet_ext/proc_bind_patch.rb#30 def finalize_proc(decl); end end -# source://sorbet-runtime/0.5.10601/lib/types/private/methods/_methods.rb#581 -T::Private::Methods::TOP_SELF = T.let(T.unsafe(nil), Object) - class T::Types::Proc < ::T::Types::Base; end # source://tapioca//lib/tapioca/sorbet_ext/proc_bind_patch.rb#6 @@ -323,18 +331,18 @@ end # source://tapioca//lib/tapioca/sorbet_ext/name_patch.rb#6 class T::Types::Simple < ::T::Types::Base - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#64 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#70 def name; end end -# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#59 +# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#65 module T::Types::Simple::GenericPatch # This method intercepts calls to the `name` method for simple types, so that # it can ask the name to the type if the type is generic, since, by this point, # we've created a clone of that type with the `name` method returning the # appropriate name for that specific concrete type. # - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#64 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#70 def name; end end @@ -350,24 +358,24 @@ end # source://tapioca//lib/tapioca/sorbet_ext/name_patch.rb#8 T::Types::Simple::NamePatch::NAME_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#84 +# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#87 module T::Utils::Private class << self - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#86 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#89 def coerce_and_check_module_types(val, check_val, check_module_type); end end end -# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#85 +# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#88 module T::Utils::Private::PrivateCoercePatch - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#86 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#89 def coerce_and_check_module_types(val, check_val, check_module_type); end end # source://tapioca//lib/tapioca/runtime/trackers/autoload.rb#4 module Tapioca class << self - # source://tapioca//lib/tapioca.rb#19 + # source://tapioca//lib/tapioca.rb#20 sig do type_parameters(:Result) .params( @@ -378,16 +386,53 @@ module Tapioca end end -# source://tapioca//lib/tapioca.rb#37 +# source://tapioca//lib/tapioca.rb#39 Tapioca::BINARY_FILE = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#60 +# source://tapioca//lib/tapioca/bundler_ext/auto_require_hook.rb#5 +module Tapioca::BundlerExt; end + +# This is a module that gets prepended to `Bundler::Dependency` and +# makes sure even gems marked as `require: false` are required during +# `Bundler.require`. +# +# source://tapioca//lib/tapioca/bundler_ext/auto_require_hook.rb#9 +module Tapioca::BundlerExt::AutoRequireHook + requires_ancestor { Bundler::Dependency } + + # source://tapioca//lib/tapioca/bundler_ext/auto_require_hook.rb#46 + sig { returns(T.untyped) } + def autorequire; end + + class << self + # @return [Boolean] + # + # source://tapioca//lib/tapioca/bundler_ext/auto_require_hook.rb#26 + def enabled?; end + + # source://tapioca//lib/tapioca/bundler_ext/auto_require_hook.rb#22 + sig { params(name: T.untyped).returns(T::Boolean) } + def excluded?(name); end + + # source://tapioca//lib/tapioca/bundler_ext/auto_require_hook.rb#36 + sig do + type_parameters(:Result) + .params( + exclude: T::Array[::String], + blk: T.proc.returns(T.type_parameter(:Result)) + ).returns(T.type_parameter(:Result)) + end + def override_require_false(exclude:, &blk); end + end +end + +# source://tapioca//lib/tapioca.rb#62 Tapioca::CENTRAL_REPO_ANNOTATIONS_DIR = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#59 +# source://tapioca//lib/tapioca.rb#61 Tapioca::CENTRAL_REPO_INDEX_PATH = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#58 +# source://tapioca//lib/tapioca.rb#60 Tapioca::CENTRAL_REPO_ROOT_URI = T.let(T.unsafe(nil), String) # source://tapioca//lib/tapioca/cli.rb#5 @@ -396,40 +441,42 @@ class Tapioca::Cli < ::Thor include ::Tapioca::ConfigHelper include ::Tapioca::EnvHelper - # source://tapioca//lib/tapioca/cli.rb#332 + # source://tapioca//lib/tapioca/cli.rb#366 def __print_version; end - # source://tapioca//lib/tapioca/cli.rb#312 + # source://tapioca//lib/tapioca/cli.rb#348 def annotations; end - # source://tapioca//lib/tapioca/cli.rb#282 + # source://tapioca//lib/tapioca/cli.rb#320 def check_shims; end - # source://tapioca//lib/tapioca/cli.rb#41 + # source://tapioca//lib/tapioca/cli.rb#46 def configure; end - # source://tapioca//lib/tapioca/cli.rb#133 - def dsl(*constants); end + # source://tapioca//lib/tapioca/cli.rb#147 + def dsl(*constant_or_paths); end - # source://tapioca//lib/tapioca/cli.rb#234 + # @raise [MalformattedArgumentError] + # + # source://tapioca//lib/tapioca/cli.rb#264 def gem(*gems); end # source://tapioca//lib/tapioca/cli.rb#27 def init; end - # source://tapioca//lib/tapioca/cli.rb#52 + # source://tapioca//lib/tapioca/cli.rb#57 def require; end - # source://tapioca//lib/tapioca/cli.rb#71 + # source://tapioca//lib/tapioca/cli.rb#74 def todo; end private - # source://tapioca//lib/tapioca/cli.rb#346 + # source://tapioca//lib/tapioca/cli.rb#380 def print_init_next_steps; end class << self - # source://tapioca//lib/tapioca/cli.rb#338 + # source://tapioca//lib/tapioca/cli.rb#372 def exit_on_failure?; end end end @@ -457,6 +504,241 @@ end # source://tapioca//lib/tapioca/commands.rb#5 module Tapioca::Commands; end +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://tapioca//lib/tapioca/commands/abstract_dsl.rb#6 +class Tapioca::Commands::AbstractDsl < ::Tapioca::Commands::CommandWithoutTracker + include ::Tapioca::SorbetHelper + include ::Tapioca::RBIFilesHelper + + abstract! + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#33 + sig do + params( + requested_constants: T::Array[::String], + requested_paths: T::Array[::Pathname], + outpath: ::Pathname, + only: T::Array[::String], + exclude: T::Array[::String], + file_header: T::Boolean, + tapioca_path: ::String, + skip_constant: T::Array[::String], + quiet: T::Boolean, + verbose: T::Boolean, + number_of_workers: T.nilable(::Integer), + auto_strictness: T::Boolean, + gem_dir: ::String, + rbi_formatter: ::Tapioca::RBIFormatter, + app_root: ::String, + halt_upon_load_error: T::Boolean, + compiler_options: T::Hash[::String, T.untyped] + ).void + end + def initialize(requested_constants:, requested_paths:, outpath:, only:, exclude:, file_header:, tapioca_path:, skip_constant: T.unsafe(nil), quiet: T.unsafe(nil), verbose: T.unsafe(nil), number_of_workers: T.unsafe(nil), auto_strictness: T.unsafe(nil), gem_dir: T.unsafe(nil), rbi_formatter: T.unsafe(nil), app_root: T.unsafe(nil), halt_upon_load_error: T.unsafe(nil), compiler_options: T.unsafe(nil)); end + + private + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#100 + sig { returns(T::Array[::String]) } + def all_requested_constants; end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#293 + sig { params(cause: ::Symbol, files: T::Array[::String]).returns(::String) } + def build_error_for_files(cause, files); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#217 + sig do + params( + constant_name: ::String, + rbi: ::RBI::File, + outpath: ::Pathname, + quiet: T::Boolean + ).returns(T.nilable(::Pathname)) + end + def compile_dsl_rbi(constant_name, rbi, outpath: T.unsafe(nil), quiet: T.unsafe(nil)); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#154 + sig { params(constant_names: T::Array[::String], ignore_missing: T::Boolean).returns(T::Array[::Module]) } + def constantize(constant_names, ignore_missing: T.unsafe(nil)); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#177 + sig { params(compiler_names: T::Array[::String]).returns(T::Array[T.class_of(Tapioca::Dsl::Compiler)]) } + def constantize_compilers(compiler_names); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#353 + sig { returns(T::Array[::String]) } + def constants_from_requested_paths; end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#123 + sig { returns(::Tapioca::Dsl::Pipeline) } + def create_pipeline; end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#256 + sig { params(constant_name: ::String).returns(::Pathname) } + def dsl_rbi_filename(constant_name); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#140 + sig { params(requested_constants: T::Array[::String], path: ::Pathname).returns(T::Set[::Pathname]) } + def existing_rbi_filenames(requested_constants, path: T.unsafe(nil)); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#348 + sig { params(constant: ::String).returns(::String) } + def generate_command_for(constant); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#76 + sig { params(outpath: ::Pathname, quiet: T::Boolean).returns(T::Set[::Pathname]) } + def generate_dsl_rbi_files(outpath, quiet:); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#113 + sig { void } + def load_application; end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#235 + sig { params(dir: ::Pathname).void } + def perform_dsl_verification(dir); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#108 + sig { returns(::Tapioca::Dsl::Pipeline) } + def pipeline; end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#244 + sig { params(files: T::Set[::Pathname]).void } + def purge_stale_dsl_rbi_files(files); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#343 + sig { params(constant: ::String).returns(::String) } + def rbi_filename_for(constant); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#324 + sig { params(path: ::Pathname).returns(T::Array[::Pathname]) } + def rbi_files_in(path); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#302 + sig { params(diff: T::Hash[::String, ::Symbol], command: ::Symbol).void } + def report_diff_and_exit_if_out_of_date(diff, command); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#197 + sig { params(name: ::String).returns(T.nilable(T.class_of(Tapioca::Dsl::Compiler))) } + def resolve(name); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#331 + sig { params(class_name: ::String).returns(::String) } + def underscore(class_name); end + + # source://tapioca//lib/tapioca/commands/abstract_dsl.rb#261 + sig { params(tmp_dir: ::Pathname).returns(T::Hash[::String, ::Symbol]) } + def verify_dsl_rbi(tmp_dir:); end +end + +# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below. +# +# source://tapioca//lib/tapioca/commands/abstract_gem.rb#6 +class Tapioca::Commands::AbstractGem < ::Tapioca::Commands::Command + include ::Tapioca::SorbetHelper + include ::Tapioca::RBIFilesHelper + + abstract! + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#32 + sig do + params( + gem_names: T::Array[::String], + exclude: T::Array[::String], + include_dependencies: T::Boolean, + prerequire: T.nilable(::String), + postrequire: ::String, + typed_overrides: T::Hash[::String, ::String], + outpath: ::Pathname, + file_header: T::Boolean, + include_doc: T::Boolean, + include_loc: T::Boolean, + include_exported_rbis: T::Boolean, + number_of_workers: T.nilable(::Integer), + auto_strictness: T::Boolean, + dsl_dir: ::String, + rbi_formatter: ::Tapioca::RBIFormatter, + halt_upon_load_error: T::Boolean + ).void + end + def initialize(gem_names:, exclude:, include_dependencies:, prerequire:, postrequire:, typed_overrides:, outpath:, file_header:, include_doc:, include_loc:, include_exported_rbis:, number_of_workers: T.unsafe(nil), auto_strictness: T.unsafe(nil), dsl_dir: T.unsafe(nil), rbi_formatter: T.unsafe(nil), halt_upon_load_error: T.unsafe(nil)); end + + private + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#223 + sig { returns(T::Array[::String]) } + def added_rbis; end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#284 + sig { params(cause: ::Symbol, files: T::Array[::String]).returns(::String) } + def build_error_for_files(cause, files); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#110 + sig { params(gem: ::Tapioca::Gemfile::GemSpec).void } + def compile_gem_rbi(gem); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#218 + sig { params(gem_name: ::String).returns(::Pathname) } + def existing_rbi(gem_name); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#266 + sig { returns(T::Hash[::String, ::String]) } + def existing_rbis; end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#230 + sig { params(gem_name: ::String).returns(::Pathname) } + def expected_rbi(gem_name); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#272 + sig { returns(T::Hash[::String, ::String]) } + def expected_rbis; end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#98 + sig do + params( + gem: ::Tapioca::Gemfile::GemSpec, + dependencies: T::Array[::Tapioca::Gemfile::GemSpec] + ).returns(T::Array[::Tapioca::Gemfile::GemSpec]) + end + def gem_dependencies(gem, dependencies = T.unsafe(nil)); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#235 + sig { params(gem_name: ::String).returns(T::Boolean) } + def gem_rbi_exists?(gem_name); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#279 + sig { params(gem_name: ::String, version: ::String).returns(::Pathname) } + def gem_rbi_filename(gem_name, version); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#77 + sig { params(gem_names: T::Array[::String]).returns(T::Array[::Tapioca::Gemfile::GemSpec]) } + def gems_to_generate(gem_names); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#289 + sig { params(gem: ::Tapioca::Gemfile::GemSpec, file: ::RBI::File).void } + def merge_with_exported_rbi(gem, file); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#260 + sig { params(old_filename: ::Pathname, new_filename: ::Pathname).void } + def move(old_filename, new_filename); end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#170 + sig { void } + def perform_additions; end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#143 + sig { void } + def perform_removals; end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#213 + sig { returns(T::Array[::String]) } + def removed_rbis; end + + # source://tapioca//lib/tapioca/commands/abstract_gem.rb#240 + sig { params(diff: T::Hash[::String, ::Symbol], command: ::Symbol).void } + def report_diff_and_exit_if_out_of_date(diff, command); end +end + # source://tapioca//lib/tapioca/commands/annotations.rb#6 class Tapioca::Commands::Annotations < ::Tapioca::Commands::CommandWithoutTracker # source://tapioca//lib/tapioca/commands/annotations.rb#18 @@ -471,69 +753,73 @@ class Tapioca::Commands::Annotations < ::Tapioca::Commands::CommandWithoutTracke end def initialize(central_repo_root_uris:, auth: T.unsafe(nil), netrc_file: T.unsafe(nil), central_repo_index_path: T.unsafe(nil), typed_overrides: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/commands/annotations.rb#36 - sig { override.void } - def execute; end - private - # source://tapioca//lib/tapioca/commands/annotations.rb#191 + # source://tapioca//lib/tapioca/commands/annotations.rb#197 sig { params(name: ::String, content: ::String).returns(::String) } def add_header(name, content); end - # source://tapioca//lib/tapioca/commands/annotations.rb#209 + # source://tapioca//lib/tapioca/commands/annotations.rb#217 sig { params(name: ::String, content: ::String).returns(::String) } def apply_typed_override(name, content); end - # source://tapioca//lib/tapioca/commands/annotations.rb#132 - sig { params(repo_uris: T::Array[::String], gem_name: ::String).void } - def fetch_annotation(repo_uris, gem_name); end + # source://tapioca//lib/tapioca/commands/annotations.rb#39 + sig { override.void } + def execute; end + + # source://tapioca//lib/tapioca/commands/annotations.rb#136 + sig { params(repo_uris: T::Array[::String], gem_info: ::Tapioca::GemInfo).void } + def fetch_annotation(repo_uris, gem_info); end - # source://tapioca//lib/tapioca/commands/annotations.rb#109 - sig { params(gem_names: T::Array[::String]).returns(T::Array[::String]) } - def fetch_annotations(gem_names); end + # source://tapioca//lib/tapioca/commands/annotations.rb#113 + sig { params(project_gems: T::Array[::Tapioca::GemInfo]).returns(T::Array[::String]) } + def fetch_annotations(project_gems); end - # source://tapioca//lib/tapioca/commands/annotations.rb#150 + # source://tapioca//lib/tapioca/commands/annotations.rb#156 sig { params(repo_uri: ::String, path: ::String).returns(T.nilable(::String)) } def fetch_file(repo_uri, path); end - # source://tapioca//lib/tapioca/commands/annotations.rb#167 + # source://tapioca//lib/tapioca/commands/annotations.rb#173 sig { params(repo_uri: ::String, path: ::String).returns(T.nilable(::String)) } def fetch_http_file(repo_uri, path); end - # source://tapioca//lib/tapioca/commands/annotations.rb#98 + # source://tapioca//lib/tapioca/commands/annotations.rb#102 sig { params(repo_uri: ::String, repo_number: T.nilable(::Integer)).returns(T.nilable(Tapioca::RepoIndex)) } def fetch_index(repo_uri, repo_number:); end - # source://tapioca//lib/tapioca/commands/annotations.rb#77 + # source://tapioca//lib/tapioca/commands/annotations.rb#81 sig { returns(T::Hash[::String, Tapioca::RepoIndex]) } def fetch_indexes; end - # source://tapioca//lib/tapioca/commands/annotations.rb#159 + # source://tapioca//lib/tapioca/commands/annotations.rb#165 sig { params(repo_uri: ::String, path: ::String).returns(T.nilable(::String)) } def fetch_local_file(repo_uri, path); end - # source://tapioca//lib/tapioca/commands/annotations.rb#46 - sig { returns(T::Array[::String]) } + # source://tapioca//lib/tapioca/commands/annotations.rb#229 + sig { params(gem_version: ::Gem::Version, content: ::String).returns(::String) } + def filter_versions(gem_version, content); end + + # source://tapioca//lib/tapioca/commands/annotations.rb#50 + sig { returns(T::Array[::Tapioca::GemInfo]) } def list_gemfile_gems; end - # source://tapioca//lib/tapioca/commands/annotations.rb#221 + # source://tapioca//lib/tapioca/commands/annotations.rb#237 sig { params(gem_name: ::String, contents: T::Array[::String]).returns(T.nilable(::String)) } def merge_files(gem_name, contents); end - # source://tapioca//lib/tapioca/commands/annotations.rb#56 - sig { params(project_gems: T::Array[::String]).void } + # source://tapioca//lib/tapioca/commands/annotations.rb#60 + sig { params(project_gems: T::Array[::Tapioca::GemInfo]).void } def remove_expired_annotations(project_gems); end - # source://tapioca//lib/tapioca/commands/annotations.rb#248 + # source://tapioca//lib/tapioca/commands/annotations.rb#264 sig { returns(T::Hash[::String, T.nilable(::String)]) } def repo_tokens; end - # source://tapioca//lib/tapioca/commands/annotations.rb#276 + # source://tapioca//lib/tapioca/commands/annotations.rb#292 sig { params(path: ::String, repo_uri: ::String, message: ::String).void } def say_http_error(path, repo_uri, message:); end - # source://tapioca//lib/tapioca/commands/annotations.rb#260 + # source://tapioca//lib/tapioca/commands/annotations.rb#276 sig { params(repo_uri: ::String).returns(T.nilable(::String)) } def token_for(repo_uri); end end @@ -557,7 +843,9 @@ class Tapioca::Commands::CheckShims < ::Tapioca::Commands::CommandWithoutTracker end def initialize(gem_rbi_dir:, dsl_rbi_dir:, annotations_rbi_dir:, shim_rbi_dir:, todo_rbi_file:, payload:, number_of_workers:); end - # source://tapioca//lib/tapioca/commands/check_shims.rb#42 + private + + # source://tapioca//lib/tapioca/commands/check_shims.rb#44 sig { override.void } def execute; end end @@ -579,19 +867,17 @@ class Tapioca::Commands::Command sig { void } def initialize; end - # @abstract - # - # source://tapioca//lib/tapioca/commands/command.rb#25 - sig { abstract.void } - def execute; end - - # source://thor/1.2.2/lib/thor/base.rb#139 + # source://thor/1.3.1/lib/thor/base.rb#155 sig { returns(::Thor::Actions) } def file_writer; end + # source://tapioca//lib/tapioca/commands/command.rb#25 + sig(:final) { void } + def run; end + private - # source://tapioca//lib/tapioca/commands/command.rb#46 + # source://tapioca//lib/tapioca/commands/command.rb#53 sig do params( path: T.any(::Pathname, ::String), @@ -603,11 +889,17 @@ class Tapioca::Commands::Command end def create_file(path, content, force: T.unsafe(nil), skip: T.unsafe(nil), verbose: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/commands/command.rb#30 + # source://tapioca//lib/tapioca/commands/command.rb#37 sig { params(command: ::Symbol, args: ::String).returns(::String) } def default_command(command, *args); end - # source://tapioca//lib/tapioca/commands/command.rb#56 + # @abstract + # + # source://tapioca//lib/tapioca/commands/command.rb#34 + sig { abstract.void } + def execute; end + + # source://tapioca//lib/tapioca/commands/command.rb#63 sig { params(path: T.any(::Pathname, ::String), verbose: T::Boolean).void } def remove_file(path, verbose: T.unsafe(nil)); end end @@ -635,17 +927,13 @@ class Tapioca::Commands::Configure < ::Tapioca::Commands::CommandWithoutTracker sig { params(sorbet_config: ::String, tapioca_config: ::String, default_postrequire: ::String).void } def initialize(sorbet_config:, tapioca_config:, default_postrequire:); end - # source://tapioca//lib/tapioca/commands/configure.rb#30 - sig { override.void } - def execute; end - private - # source://tapioca//lib/tapioca/commands/configure.rb#78 + # source://tapioca//lib/tapioca/commands/configure.rb#79 sig { void } def create_binstub; end - # source://tapioca//lib/tapioca/commands/configure.rb#68 + # source://tapioca//lib/tapioca/commands/configure.rb#69 sig { void } def create_post_require; end @@ -653,230 +941,79 @@ class Tapioca::Commands::Configure < ::Tapioca::Commands::CommandWithoutTracker sig { void } def create_sorbet_config; end - # source://tapioca//lib/tapioca/commands/configure.rb#49 + # source://tapioca//lib/tapioca/commands/configure.rb#50 sig { void } def create_tapioca_config; end - # source://tapioca//lib/tapioca/commands/configure.rb#91 + # source://tapioca//lib/tapioca/commands/configure.rb#32 + sig { override.void } + def execute; end + + # source://tapioca//lib/tapioca/commands/configure.rb#92 sig { returns(::Bundler::Installer) } def installer; end - # source://tapioca//lib/tapioca/commands/configure.rb#96 + # source://tapioca//lib/tapioca/commands/configure.rb#97 sig { returns(T.any(::Bundler::StubSpecification, ::Gem::Specification)) } def spec; end end -# source://tapioca//lib/tapioca/commands/dsl.rb#6 -class Tapioca::Commands::Dsl < ::Tapioca::Commands::CommandWithoutTracker - include ::Tapioca::SorbetHelper - include ::Tapioca::RBIFilesHelper - - # source://tapioca//lib/tapioca/commands/dsl.rb#28 - sig do - params( - requested_constants: T::Array[::String], - outpath: ::Pathname, - only: T::Array[::String], - exclude: T::Array[::String], - file_header: T::Boolean, - tapioca_path: ::String, - should_verify: T::Boolean, - quiet: T::Boolean, - verbose: T::Boolean, - number_of_workers: T.nilable(::Integer), - auto_strictness: T::Boolean, - gem_dir: ::String, - rbi_formatter: ::Tapioca::RBIFormatter, - app_root: ::String - ).void - end - def initialize(requested_constants:, outpath:, only:, exclude:, file_header:, tapioca_path:, should_verify: T.unsafe(nil), quiet: T.unsafe(nil), verbose: T.unsafe(nil), number_of_workers: T.unsafe(nil), auto_strictness: T.unsafe(nil), gem_dir: T.unsafe(nil), rbi_formatter: T.unsafe(nil), app_root: T.unsafe(nil)); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#90 - sig { override.void } - def execute; end - - # source://tapioca//lib/tapioca/commands/dsl.rb#63 - sig { void } - def list_compilers; end - +# source://tapioca//lib/tapioca/commands/dsl_compiler_list.rb#6 +class Tapioca::Commands::DslCompilerList < ::Tapioca::Commands::AbstractDsl private - # source://tapioca//lib/tapioca/commands/dsl.rb#317 - sig { params(cause: ::Symbol, files: T::Array[::String]).returns(::String) } - def build_error_for_files(cause, files); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#241 - sig do - params( - constant_name: ::String, - rbi: ::RBI::File, - outpath: ::Pathname, - quiet: T::Boolean - ).returns(T.nilable(::Pathname)) - end - def compile_dsl_rbi(constant_name, rbi, outpath: T.unsafe(nil), quiet: T.unsafe(nil)); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#179 - sig { params(constant_names: T::Array[::String]).returns(T::Array[::Module]) } - def constantize(constant_names); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#202 - sig { params(compiler_names: T::Array[::String]).returns(T::Array[T.class_of(Tapioca::Dsl::Compiler)]) } - def constantize_compilers(compiler_names); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#153 - sig { returns(::Tapioca::Dsl::Pipeline) } - def create_pipeline; end - - # source://tapioca//lib/tapioca/commands/dsl.rb#280 - sig { params(constant_name: ::String).returns(::Pathname) } - def dsl_rbi_filename(constant_name); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#166 - sig { params(requested_constants: T::Array[::String], path: ::Pathname).returns(T::Set[::Pathname]) } - def existing_rbi_filenames(requested_constants, path: T.unsafe(nil)); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#370 - sig { params(constant: ::String).returns(::String) } - def generate_command_for(constant); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#259 - sig { params(dir: ::Pathname).void } - def perform_dsl_verification(dir); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#268 - sig { params(files: T::Set[::Pathname]).void } - def purge_stale_dsl_rbi_files(files); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#365 - sig { params(constant: ::String).returns(::String) } - def rbi_filename_for(constant); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#346 - sig { params(path: ::Pathname).returns(T::Array[::Pathname]) } - def rbi_files_in(path); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#326 - sig { params(diff: T::Hash[::String, ::Symbol], command: ::Symbol).void } - def report_diff_and_exit_if_out_of_date(diff, command); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#221 - sig { params(name: ::String).returns(T.nilable(T.class_of(Tapioca::Dsl::Compiler))) } - def resolve(name); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#353 - sig { params(class_name: ::String).returns(::String) } - def underscore(class_name); end - - # source://tapioca//lib/tapioca/commands/dsl.rb#285 - sig { params(tmp_dir: ::Pathname).returns(T::Hash[::String, ::Symbol]) } - def verify_dsl_rbi(tmp_dir:); end -end - -# source://tapioca//lib/tapioca/commands/gem.rb#6 -class Tapioca::Commands::Gem < ::Tapioca::Commands::Command - include ::Tapioca::SorbetHelper - include ::Tapioca::RBIFilesHelper - - # source://tapioca//lib/tapioca/commands/gem.rb#28 - sig do - params( - gem_names: T::Array[::String], - exclude: T::Array[::String], - prerequire: T.nilable(::String), - postrequire: ::String, - typed_overrides: T::Hash[::String, ::String], - outpath: ::Pathname, - file_header: T::Boolean, - include_doc: T::Boolean, - include_loc: T::Boolean, - include_exported_rbis: T::Boolean, - number_of_workers: T.nilable(::Integer), - auto_strictness: T::Boolean, - dsl_dir: ::String, - rbi_formatter: ::Tapioca::RBIFormatter - ).void - end - def initialize(gem_names:, exclude:, prerequire:, postrequire:, typed_overrides:, outpath:, file_header:, include_doc:, include_loc:, include_exported_rbis:, number_of_workers: T.unsafe(nil), auto_strictness: T.unsafe(nil), dsl_dir: T.unsafe(nil), rbi_formatter: T.unsafe(nil)); end - - # source://tapioca//lib/tapioca/commands/gem.rb#67 - sig { override.void } - def execute; end - - # source://tapioca//lib/tapioca/commands/gem.rb#105 - sig { params(should_verify: T::Boolean, exclude: T::Array[::String]).void } - def sync(should_verify: T.unsafe(nil), exclude: T.unsafe(nil)); end - - private - - # source://tapioca//lib/tapioca/commands/gem.rb#283 - sig { returns(T::Array[::String]) } - def added_rbis; end - - # source://tapioca//lib/tapioca/commands/gem.rb#344 - sig { params(cause: ::Symbol, files: T::Array[::String]).returns(::String) } - def build_error_for_files(cause, files); end - - # source://tapioca//lib/tapioca/commands/gem.rb#154 - sig { params(gem: ::Tapioca::Gemfile::GemSpec).void } - def compile_gem_rbi(gem); end - - # source://tapioca//lib/tapioca/commands/gem.rb#278 - sig { params(gem_name: ::String).returns(::Pathname) } - def existing_rbi(gem_name); end - - # source://tapioca//lib/tapioca/commands/gem.rb#326 - sig { returns(T::Hash[::String, ::String]) } - def existing_rbis; end - - # source://tapioca//lib/tapioca/commands/gem.rb#290 - sig { params(gem_name: ::String).returns(::Pathname) } - def expected_rbi(gem_name); end + # source://tapioca//lib/tapioca/commands/dsl_compiler_list.rb#10 + sig { override.void } + def execute; end +end - # source://tapioca//lib/tapioca/commands/gem.rb#332 - sig { returns(T::Hash[::String, ::String]) } - def expected_rbis; end +# source://tapioca//lib/tapioca/commands/dsl_generate.rb#6 +class Tapioca::Commands::DslGenerate < ::Tapioca::Commands::AbstractDsl + private - # source://tapioca//lib/tapioca/commands/gem.rb#295 - sig { params(gem_name: ::String).returns(T::Boolean) } - def gem_rbi_exists?(gem_name); end + # source://tapioca//lib/tapioca/commands/dsl_generate.rb#10 + sig { override.void } + def execute; end +end - # source://tapioca//lib/tapioca/commands/gem.rb#339 - sig { params(gem_name: ::String, version: ::String).returns(::Pathname) } - def gem_rbi_filename(gem_name, version); end +# source://tapioca//lib/tapioca/commands/dsl_verify.rb#6 +class Tapioca::Commands::DslVerify < ::Tapioca::Commands::AbstractDsl + private - # source://tapioca//lib/tapioca/commands/gem.rb#139 - sig { params(gem_names: T::Array[::String]).returns(T::Array[::Tapioca::Gemfile::GemSpec]) } - def gems_to_generate(gem_names); end + # source://tapioca//lib/tapioca/commands/dsl_verify.rb#10 + sig { override.void } + def execute; end +end - # source://tapioca//lib/tapioca/commands/gem.rb#349 - sig { params(gem: ::Tapioca::Gemfile::GemSpec, file: ::RBI::File).void } - def merge_with_exported_rbi(gem, file); end +# source://tapioca//lib/tapioca/commands/gem_generate.rb#6 +class Tapioca::Commands::GemGenerate < ::Tapioca::Commands::AbstractGem + private - # source://tapioca//lib/tapioca/commands/gem.rb#320 - sig { params(old_filename: ::Pathname, new_filename: ::Pathname).void } - def move(old_filename, new_filename); end + # source://tapioca//lib/tapioca/commands/gem_generate.rb#10 + sig { override.void } + def execute; end +end - # source://tapioca//lib/tapioca/commands/gem.rb#231 - sig { void } - def perform_additions; end +# source://tapioca//lib/tapioca/commands/gem_sync.rb#6 +class Tapioca::Commands::GemSync < ::Tapioca::Commands::AbstractGem + private - # source://tapioca//lib/tapioca/commands/gem.rb#204 - sig { void } - def perform_removals; end + # source://tapioca//lib/tapioca/commands/gem_sync.rb#10 + sig { override.void } + def execute; end +end - # source://tapioca//lib/tapioca/commands/gem.rb#185 - sig { params(exclude: T::Array[::String]).void } - def perform_sync_verification(exclude: T.unsafe(nil)); end +# source://tapioca//lib/tapioca/commands/gem_verify.rb#6 +class Tapioca::Commands::GemVerify < ::Tapioca::Commands::AbstractGem + private - # source://tapioca//lib/tapioca/commands/gem.rb#273 - sig { returns(T::Array[::String]) } - def removed_rbis; end + # source://tapioca//lib/tapioca/commands/gem_verify.rb#10 + sig { override.void } + def execute; end - # source://tapioca//lib/tapioca/commands/gem.rb#300 - sig { params(diff: T::Hash[::String, ::Symbol], command: ::Symbol).void } - def report_diff_and_exit_if_out_of_date(diff, command); end + # source://tapioca//lib/tapioca/commands/gem_verify.rb#17 + sig { void } + def perform_sync_verification; end end # source://tapioca//lib/tapioca/commands/require.rb#6 @@ -885,7 +1022,9 @@ class Tapioca::Commands::Require < ::Tapioca::Commands::CommandWithoutTracker sig { params(requires_path: ::String, sorbet_config_path: ::String).void } def initialize(requires_path:, sorbet_config_path:); end - # source://tapioca//lib/tapioca/commands/require.rb#21 + private + + # source://tapioca//lib/tapioca/commands/require.rb#23 sig { override.void } def execute; end end @@ -894,25 +1033,32 @@ end class Tapioca::Commands::Todo < ::Tapioca::Commands::CommandWithoutTracker include ::Tapioca::SorbetHelper - # source://tapioca//lib/tapioca/commands/todo.rb#15 + # source://tapioca//lib/tapioca/commands/todo.rb#26 sig { params(todo_file: ::String, file_header: T::Boolean).void } def initialize(todo_file:, file_header:); end - # source://tapioca//lib/tapioca/commands/todo.rb#23 - sig { override.void } - def execute; end + # source://tapioca//lib/tapioca/commands/todo.rb#34 + sig { void } + def run_with_deprecation; end private - # source://tapioca//lib/tapioca/commands/todo.rb#49 + # source://tapioca//lib/tapioca/commands/todo.rb#44 + sig { override.void } + def execute; end + + # source://tapioca//lib/tapioca/commands/todo.rb#68 sig { params(constants: T::Array[::String], command: ::String).returns(::RBI::File) } def rbi(constants, command:); end - # source://tapioca//lib/tapioca/commands/todo.rb#69 + # source://tapioca//lib/tapioca/commands/todo.rb#88 sig { returns(T::Array[::String]) } def unresolved_constants; end end +# source://tapioca//lib/tapioca/commands/todo.rb#9 +Tapioca::Commands::Todo::DEPRECATION_MESSAGE = T.let(T.unsafe(nil), String) + # source://tapioca//lib/tapioca/helpers/config_helper.rb#5 module Tapioca::ConfigHelper requires_ancestor { Thor } @@ -935,11 +1081,11 @@ module Tapioca::ConfigHelper private - # source://tapioca//lib/tapioca/helpers/config_helper.rb#151 + # source://tapioca//lib/tapioca/helpers/config_helper.rb#153 sig { params(msg: ::String).returns(::Tapioca::ConfigHelper::ConfigError) } def build_error(msg); end - # source://tapioca//lib/tapioca/helpers/config_helper.rb#176 + # source://tapioca//lib/tapioca/helpers/config_helper.rb#178 sig { params(config_file: ::String, errors: T::Array[::Tapioca::ConfigHelper::ConfigError]).returns(::String) } def build_error_message(config_file, errors); end @@ -955,7 +1101,7 @@ module Tapioca::ConfigHelper sig { params(options: T::Hash[::Symbol, ::Thor::Option]).void } def filter_defaults(options); end - # source://tapioca//lib/tapioca/helpers/config_helper.rb#194 + # source://tapioca//lib/tapioca/helpers/config_helper.rb#196 sig do params( options: T.nilable(::Thor::CoreExt::HashWithIndifferentAccess) @@ -978,58 +1124,58 @@ module Tapioca::ConfigHelper def validate_config_options(command_options, config_key, config_options); end end -# source://tapioca//lib/tapioca/helpers/config_helper.rb#146 +# source://tapioca//lib/tapioca/helpers/config_helper.rb#148 class Tapioca::ConfigHelper::ConfigError < ::T::Struct const :message_parts, T::Array[::Tapioca::ConfigHelper::ConfigErrorMessagePart] class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 def inherited(s); end end end -# source://tapioca//lib/tapioca/helpers/config_helper.rb#141 +# source://tapioca//lib/tapioca/helpers/config_helper.rb#143 class Tapioca::ConfigHelper::ConfigErrorMessagePart < ::T::Struct const :message, ::String const :colors, T::Array[::Symbol] class << self - # source://sorbet-runtime/0.5.10601/lib/types/struct.rb#13 + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 def inherited(s); end end end -# source://tapioca//lib/tapioca.rb#44 +# source://tapioca//lib/tapioca.rb#46 Tapioca::DEFAULT_ANNOTATIONS_DIR = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#40 +# source://tapioca//lib/tapioca.rb#42 Tapioca::DEFAULT_DSL_DIR = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#56 +# source://tapioca//lib/tapioca.rb#58 Tapioca::DEFAULT_ENVIRONMENT = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#41 +# source://tapioca//lib/tapioca.rb#43 Tapioca::DEFAULT_GEM_DIR = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#46 +# source://tapioca//lib/tapioca.rb#48 Tapioca::DEFAULT_OVERRIDES = T.let(T.unsafe(nil), Hash) -# source://tapioca//lib/tapioca.rb#38 +# source://tapioca//lib/tapioca.rb#40 Tapioca::DEFAULT_POSTREQUIRE_FILE = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#39 +# source://tapioca//lib/tapioca.rb#41 Tapioca::DEFAULT_RBI_DIR = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca/rbi_formatter.rb#29 +# source://tapioca//lib/tapioca/rbi_formatter.rb#31 Tapioca::DEFAULT_RBI_FORMATTER = T.let(T.unsafe(nil), Tapioca::RBIFormatter) -# source://tapioca//lib/tapioca.rb#55 +# source://tapioca//lib/tapioca.rb#57 Tapioca::DEFAULT_RBI_MAX_LINE_LENGTH = T.let(T.unsafe(nil), Integer) -# source://tapioca//lib/tapioca.rb#42 +# source://tapioca//lib/tapioca.rb#44 Tapioca::DEFAULT_SHIM_DIR = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#43 +# source://tapioca//lib/tapioca.rb#45 Tapioca::DEFAULT_TODO_FILE = T.let(T.unsafe(nil), String) # source://tapioca//lib/tapioca/dsl/compilers.rb#5 @@ -1042,24 +1188,33 @@ class Tapioca::Dsl::Compiler extend T::Generic include ::Tapioca::SorbetHelper include ::Tapioca::RBIHelper + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection + extend ::Tapioca::Runtime::AttachedClassOf extend ::Tapioca::Runtime::Reflection abstract! ConstantType = type_member { { upper: Module } } - # source://tapioca//lib/tapioca/dsl/compiler.rb#60 - sig { params(pipeline: ::Tapioca::Dsl::Pipeline, root: ::RBI::Tree, constant: ConstantType).void } - def initialize(pipeline, root, constant); end + # source://tapioca//lib/tapioca/dsl/compiler.rb#74 + sig do + params( + pipeline: ::Tapioca::Dsl::Pipeline, + root: ::RBI::Tree, + constant: ConstantType, + options: T::Hash[::String, T.untyped] + ).void + end + def initialize(pipeline, root, constant, options = T.unsafe(nil)); end # NOTE: This should eventually accept an `Error` object or `Exception` rather than simply a `String`. # - # source://tapioca//lib/tapioca/dsl/compiler.rb#77 + # source://tapioca//lib/tapioca/dsl/compiler.rb#92 sig { params(error: ::String).void } def add_error(error); end - # source://tapioca//lib/tapioca/dsl/compiler.rb#68 + # source://tapioca//lib/tapioca/dsl/compiler.rb#83 sig { params(compiler_name: ::String).returns(T::Boolean) } def compiler_enabled?(compiler_name); end @@ -1069,56 +1224,60 @@ class Tapioca::Dsl::Compiler # @abstract # - # source://tapioca//lib/tapioca/dsl/compiler.rb#73 + # source://tapioca//lib/tapioca/dsl/compiler.rb#88 sig { abstract.void } def decorate; end + # source://tapioca//lib/tapioca/dsl/compiler.rb#26 + sig { returns(T::Hash[::String, T.untyped]) } + def options; end + # source://tapioca//lib/tapioca/dsl/compiler.rb#23 sig { returns(::RBI::Tree) } def root; end private - # source://tapioca//lib/tapioca/dsl/compiler.rb#126 + # source://tapioca//lib/tapioca/dsl/compiler.rb#141 sig { params(method_def: T.any(::Method, ::UnboundMethod)).returns(T::Array[::RBI::TypedParam]) } def compile_method_parameters_to_rbi(method_def); end - # source://tapioca//lib/tapioca/dsl/compiler.rb#162 + # source://tapioca//lib/tapioca/dsl/compiler.rb#177 sig { params(method_def: T.any(::Method, ::UnboundMethod)).returns(::String) } def compile_method_return_type_to_rbi(method_def); end - # source://tapioca//lib/tapioca/dsl/compiler.rb#116 + # source://tapioca//lib/tapioca/dsl/compiler.rb#131 sig { params(scope: ::RBI::Scope, method_def: T.any(::Method, ::UnboundMethod), class_method: T::Boolean).void } def create_method_from_def(scope, method_def, class_method: T.unsafe(nil)); end # Get the types of each parameter from a method signature # - # source://tapioca//lib/tapioca/dsl/compiler.rb#90 + # source://tapioca//lib/tapioca/dsl/compiler.rb#105 sig { params(method_def: T.any(::Method, ::UnboundMethod), signature: T.untyped).returns(T::Array[::String]) } def parameters_types_from_signature(method_def, signature); end class << self # @abstract # - # source://tapioca//lib/tapioca/dsl/compiler.rb#34 + # source://tapioca//lib/tapioca/dsl/compiler.rb#37 sig { abstract.returns(T::Enumerable[::Module]) } def gather_constants; end - # source://tapioca//lib/tapioca/dsl/compiler.rb#29 + # source://tapioca//lib/tapioca/dsl/compiler.rb#32 sig { params(constant: ::Module).returns(T::Boolean) } def handles?(constant); end - # source://tapioca//lib/tapioca/dsl/compiler.rb#37 + # source://tapioca//lib/tapioca/dsl/compiler.rb#40 sig { returns(T::Set[::Module]) } def processable_constants; end private - # source://tapioca//lib/tapioca/dsl/compiler.rb#47 - sig { returns(T::Enumerable[::Class]) } + # source://tapioca//lib/tapioca/dsl/compiler.rb#50 + sig { returns(T::Enumerable[T::Class[T.anything]]) } def all_classes; end - # source://tapioca//lib/tapioca/dsl/compiler.rb#53 + # source://tapioca//lib/tapioca/dsl/compiler.rb#58 sig { returns(T::Enumerable[::Module]) } def all_modules; end end @@ -1139,39 +1298,42 @@ Tapioca::Dsl::Compilers::NAMESPACES = T.let(T.unsafe(nil), Array) # source://tapioca//lib/tapioca/dsl/pipeline.rb#6 class Tapioca::Dsl::Pipeline - # source://tapioca//lib/tapioca/dsl/pipeline.rb#30 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#39 sig do params( requested_constants: T::Array[::Module], + requested_paths: T::Array[::Pathname], requested_compilers: T::Array[T.class_of(Tapioca::Dsl::Compiler)], excluded_compilers: T::Array[T.class_of(Tapioca::Dsl::Compiler)], error_handler: T.proc.params(error: ::String).void, - number_of_workers: T.nilable(::Integer) + skipped_constants: T::Array[::Module], + number_of_workers: T.nilable(::Integer), + compiler_options: T::Hash[::String, T.untyped] ).void end - def initialize(requested_constants:, requested_compilers: T.unsafe(nil), excluded_compilers: T.unsafe(nil), error_handler: T.unsafe(nil), number_of_workers: T.unsafe(nil)); end + def initialize(requested_constants:, requested_paths: T.unsafe(nil), requested_compilers: T.unsafe(nil), excluded_compilers: T.unsafe(nil), error_handler: T.unsafe(nil), skipped_constants: T.unsafe(nil), number_of_workers: T.unsafe(nil), compiler_options: T.unsafe(nil)); end # source://tapioca//lib/tapioca/dsl/pipeline.rb#10 sig { returns(T::Enumerable[T.class_of(Tapioca::Dsl::Compiler)]) } def active_compilers; end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#82 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#102 sig { params(error: ::String).void } def add_error(error); end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#87 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#107 sig { params(compiler_name: ::String).returns(T::Boolean) } def compiler_enabled?(compiler_name); end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#96 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#116 sig { returns(T::Array[T.class_of(Tapioca::Dsl::Compiler)]) } def compilers; end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#16 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#22 sig { returns(T.proc.params(error: ::String).void) } def error_handler; end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#19 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#25 sig { returns(T::Array[::String]) } def errors; end @@ -1179,7 +1341,11 @@ class Tapioca::Dsl::Pipeline sig { returns(T::Array[::Module]) } def requested_constants; end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#52 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#16 + sig { returns(T::Array[::Pathname]) } + def requested_paths; end + + # source://tapioca//lib/tapioca/dsl/pipeline.rb#67 sig do type_parameters(:T) .params( @@ -1188,13 +1354,21 @@ class Tapioca::Dsl::Pipeline end def run(&blk); end + # source://tapioca//lib/tapioca/dsl/pipeline.rb#19 + sig { returns(T::Array[::Module]) } + def skipped_constants; end + private - # source://tapioca//lib/tapioca/dsl/pipeline.rb#128 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#223 + sig { void } + def abort_if_pending_migrations!; end + + # source://tapioca//lib/tapioca/dsl/pipeline.rb#168 sig { params(constants: T::Set[::Module]).returns(T::Set[::Module]) } def filter_anonymous_and_reloaded_constants(constants); end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#111 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#133 sig do params( requested_compilers: T::Array[T.class_of(Tapioca::Dsl::Compiler)], @@ -1203,15 +1377,21 @@ class Tapioca::Dsl::Pipeline end def gather_active_compilers(requested_compilers, excluded_compilers); end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#119 - sig { params(requested_constants: T::Array[::Module]).returns(T::Set[::Module]) } - def gather_constants(requested_constants); end + # source://tapioca//lib/tapioca/dsl/pipeline.rb#147 + sig do + params( + requested_constants: T::Array[::Module], + requested_paths: T::Array[::Pathname], + skipped_constants: T::Array[::Module] + ).returns(T::Set[::Module]) + end + def gather_constants(requested_constants, requested_paths, skipped_constants); end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#156 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#197 sig { params(constant: ::Module).returns(T.nilable(::RBI::File)) } def rbi_for_constant(constant); end - # source://tapioca//lib/tapioca/dsl/pipeline.rb#175 + # source://tapioca//lib/tapioca/dsl/pipeline.rb#216 sig { params(error: ::String).returns(T.noreturn) } def report_error(error); end end @@ -1241,6 +1421,12 @@ class Tapioca::Executor ).returns(T::Array[T.type_parameter(:T)]) end def run_in_parallel(&block); end + + private + + # source://tapioca//lib/tapioca/executor.rb#37 + sig { returns(::Integer) } + def max_processors; end end # source://tapioca//lib/tapioca/executor.rb#8 @@ -1280,9 +1466,6 @@ end # source://tapioca//lib/tapioca/gem/events.rb#6 class Tapioca::Gem::Event abstract! - - # source://sorbet-runtime/0.5.10601/lib/types/private/abstract/declare.rb#37 - def initialize(*args, **_arg1, &blk); end end # source://tapioca//lib/tapioca/gem/events.rb#43 @@ -1337,6 +1520,7 @@ end # source://tapioca//lib/tapioca/gem/listeners/dynamic_mixins.rb#7 class Tapioca::Gem::Listeners::DynamicMixins < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private @@ -1352,6 +1536,7 @@ end # source://tapioca//lib/tapioca/gem/listeners/foreign_constants.rb#7 class Tapioca::Gem::Listeners::ForeignConstants < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private @@ -1373,15 +1558,24 @@ end class Tapioca::Gem::Listeners::Methods < ::Tapioca::Gem::Listeners::Base include ::Tapioca::SorbetHelper include ::Tapioca::RBIHelper + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private - # source://tapioca//lib/tapioca/gem/listeners/methods.rb#34 - sig { params(tree: ::RBI::Tree, module_name: ::String, mod: ::Module, for_visibility: T::Array[::Symbol]).void } - def compile_directly_owned_methods(tree, module_name, mod, for_visibility = T.unsafe(nil)); end + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#35 + sig do + params( + tree: ::RBI::Tree, + module_name: ::String, + mod: ::Module, + for_visibility: T::Array[::Symbol], + attached_class: T.nilable(::Module) + ).void + end + def compile_directly_owned_methods(tree, module_name, mod, for_visibility = T.unsafe(nil), attached_class: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/gem/listeners/methods.rb#63 + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#71 sig do params( tree: ::RBI::Tree, @@ -1393,18 +1587,22 @@ class Tapioca::Gem::Listeners::Methods < ::Tapioca::Gem::Listeners::Base end def compile_method(tree, symbol_name, constant, method, visibility = T.unsafe(nil)); end - # source://tapioca//lib/tapioca/gem/listeners/methods.rb#191 + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#211 sig { override.params(event: ::Tapioca::Gem::NodeAdded).returns(T::Boolean) } def ignore?(event); end - # source://tapioca//lib/tapioca/gem/listeners/methods.rb#184 + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#204 sig { params(constant: ::Module).returns(T.nilable(::UnboundMethod)) } def initialize_method_for(constant); end - # source://tapioca//lib/tapioca/gem/listeners/methods.rb#165 + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#172 sig { params(mod: ::Module).returns(T::Hash[::Symbol, T::Array[::Symbol]]) } def method_names_by_visibility(mod); end + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#196 + sig { params(attached_class: T.nilable(::Module), method_name: ::Symbol).returns(T.nilable(T::Boolean)) } + def method_new_in_abstract_class?(attached_class, method_name); end + # Check whether the method is defined by the constant. # # In most cases, it works to check that the constant is the method owner. However, @@ -1415,7 +1613,7 @@ class Tapioca::Gem::Listeners::Methods < ::Tapioca::Gem::Listeners::Base # It walks up the ancestor tree via the `super_method` method; if any of the super # methods are owned by the constant, it means that the constant declares the method. # - # source://tapioca//lib/tapioca/gem/listeners/methods.rb#151 + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#158 sig { params(method: ::UnboundMethod, constant: ::Module).returns(T::Boolean) } def method_owned_by_constant?(method, constant); end @@ -1423,13 +1621,14 @@ class Tapioca::Gem::Listeners::Methods < ::Tapioca::Gem::Listeners::Base sig { override.params(event: ::Tapioca::Gem::ScopeNodeAdded).void } def on_scope(event); end - # source://tapioca//lib/tapioca/gem/listeners/methods.rb#174 + # source://tapioca//lib/tapioca/gem/listeners/methods.rb#181 sig { params(constant: ::Module, method_name: ::String).returns(T::Boolean) } def struct_method?(constant, method_name); end end # source://tapioca//lib/tapioca/gem/listeners/mixins.rb#7 class Tapioca::Gem::Listeners::Mixins < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private @@ -1470,6 +1669,7 @@ end # source://tapioca//lib/tapioca/gem/listeners/remove_empty_payload_scopes.rb#7 class Tapioca::Gem::Listeners::RemoveEmptyPayloadScopes < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private @@ -1498,11 +1698,12 @@ end # source://tapioca//lib/tapioca/gem/listeners/sorbet_helpers.rb#7 class Tapioca::Gem::Listeners::SorbetHelpers < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private - # source://tapioca//lib/tapioca/gem/listeners/sorbet_helpers.rb#28 + # source://tapioca//lib/tapioca/gem/listeners/sorbet_helpers.rb#27 sig { override.params(event: ::Tapioca::Gem::NodeAdded).returns(T::Boolean) } def ignore?(event); end @@ -1513,13 +1714,16 @@ end # source://tapioca//lib/tapioca/gem/listeners/sorbet_props.rb#7 class Tapioca::Gem::Listeners::SorbetProps < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::SorbetHelper + include ::Tapioca::RBIHelper + private - # source://tapioca//lib/tapioca/gem/listeners/sorbet_props.rb#32 + # source://tapioca//lib/tapioca/gem/listeners/sorbet_props.rb#33 sig { override.params(event: ::Tapioca::Gem::NodeAdded).returns(T::Boolean) } def ignore?(event); end - # source://tapioca//lib/tapioca/gem/listeners/sorbet_props.rb#13 + # source://tapioca//lib/tapioca/gem/listeners/sorbet_props.rb#14 sig { override.params(event: ::Tapioca::Gem::ScopeNodeAdded).void } def on_scope(event); end end @@ -1539,6 +1743,7 @@ end # source://tapioca//lib/tapioca/gem/listeners/sorbet_signatures.rb#7 class Tapioca::Gem::Listeners::SorbetSignatures < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection include ::Tapioca::SorbetHelper include ::Tapioca::RBIHelper @@ -1549,7 +1754,7 @@ class Tapioca::Gem::Listeners::SorbetSignatures < ::Tapioca::Gem::Listeners::Bas sig { params(signature: T.untyped, parameters: T::Array[[::Symbol, ::String]]).returns(::RBI::Sig) } def compile_signature(signature, parameters); end - # source://tapioca//lib/tapioca/gem/listeners/sorbet_signatures.rb#78 + # source://tapioca//lib/tapioca/gem/listeners/sorbet_signatures.rb#79 sig { override.params(event: ::Tapioca::Gem::NodeAdded).returns(T::Boolean) } def ignore?(event); end @@ -1567,6 +1772,7 @@ Tapioca::Gem::Listeners::SorbetSignatures::TYPE_PARAMETER_MATCHER = T.let(T.unsa # source://tapioca//lib/tapioca/gem/listeners/sorbet_type_variables.rb#7 class Tapioca::Gem::Listeners::SorbetTypeVariables < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private @@ -1575,10 +1781,14 @@ class Tapioca::Gem::Listeners::SorbetTypeVariables < ::Tapioca::Gem::Listeners:: sig { params(tree: ::RBI::Tree, constant: ::Module).void } def compile_type_variable_declarations(tree, constant); end - # source://tapioca//lib/tapioca/gem/listeners/sorbet_type_variables.rb#50 + # source://tapioca//lib/tapioca/gem/listeners/sorbet_type_variables.rb#63 sig { override.params(event: ::Tapioca::Gem::NodeAdded).returns(T::Boolean) } def ignore?(event); end + # source://tapioca//lib/tapioca/gem/listeners/sorbet_type_variables.rb#50 + sig { params(type_variable: ::Tapioca::TypeVariableModule).returns(T.nilable(::RBI::Node)) } + def node_from_type_variable(type_variable); end + # source://tapioca//lib/tapioca/gem/listeners/sorbet_type_variables.rb#15 sig { override.params(event: ::Tapioca::Gem::ScopeNodeAdded).void } def on_scope(event); end @@ -1607,6 +1817,7 @@ end # source://tapioca//lib/tapioca/gem/listeners/subconstants.rb#7 class Tapioca::Gem::Listeners::Subconstants < ::Tapioca::Gem::Listeners::Base + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection private @@ -1628,23 +1839,23 @@ class Tapioca::Gem::Listeners::YardDoc < ::Tapioca::Gem::Listeners::Base private - # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#54 + # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#55 sig { params(name: ::String, sigs: T::Array[::RBI::Sig]).returns(T::Array[::RBI::Comment]) } def documentation_comments(name, sigs: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#98 + # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#99 sig { override.params(event: ::Tapioca::Gem::NodeAdded).returns(T::Boolean) } def ignore?(event); end - # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#35 + # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#36 sig { override.params(event: ::Tapioca::Gem::ConstNodeAdded).void } def on_const(event); end - # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#45 + # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#46 sig { override.params(event: ::Tapioca::Gem::MethodNodeAdded).void } def on_method(event); end - # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#40 + # source://tapioca//lib/tapioca/gem/listeners/yard_doc.rb#41 sig { override.params(event: ::Tapioca::Gem::ScopeNodeAdded).void } def on_scope(event); end end @@ -1708,6 +1919,7 @@ end # source://tapioca//lib/tapioca/gem/pipeline.rb#6 class Tapioca::Gem::Pipeline + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection include ::Tapioca::SorbetHelper include ::Tapioca::RBIHelper @@ -1720,35 +1932,41 @@ class Tapioca::Gem::Pipeline sig { returns(::RBI::Tree) } def compile; end + # source://tapioca//lib/tapioca/gem/pipeline.rb#119 + sig { params(name: T.any(::String, ::Symbol)).returns(T::Boolean) } + def constant_in_gem?(name); end + # source://tapioca//lib/tapioca/gem/pipeline.rb#14 sig { returns(::Tapioca::Gemfile::GemSpec) } def gem; end - # source://tapioca//lib/tapioca/gem/pipeline.rb#110 + # source://tapioca//lib/tapioca/gem/pipeline.rb#137 sig { params(method: ::UnboundMethod).returns(T::Boolean) } def method_in_gem?(method); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#118 + # Helpers + # + # source://tapioca//lib/tapioca/gem/pipeline.rb#147 sig { params(constant: ::Module).returns(T.nilable(::String)) } def name_of(constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#69 + # source://tapioca//lib/tapioca/gem/pipeline.rb#71 sig { params(symbol: ::String, constant: ::Module, node: ::RBI::Const).void } def push_const(symbol, constant, node); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#59 + # source://tapioca//lib/tapioca/gem/pipeline.rb#61 sig { params(symbol: ::String, constant: ::BasicObject).void } def push_constant(symbol, constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#64 + # source://tapioca//lib/tapioca/gem/pipeline.rb#66 sig { params(symbol: ::String, constant: ::Module).void } def push_foreign_constant(symbol, constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#83 + # source://tapioca//lib/tapioca/gem/pipeline.rb#85 sig { params(symbol: ::String, constant: ::Module, node: ::RBI::Scope).void } def push_foreign_scope(symbol, constant, node); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#97 + # source://tapioca//lib/tapioca/gem/pipeline.rb#99 sig do params( symbol: ::String, @@ -1761,103 +1979,148 @@ class Tapioca::Gem::Pipeline end def push_method(symbol, constant, method, node, signature, parameters); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#76 + # source://tapioca//lib/tapioca/gem/pipeline.rb#78 sig { params(symbol: ::String, constant: ::Module, node: ::RBI::Scope).void } def push_scope(symbol, constant, node); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#54 + # Events handling + # + # source://tapioca//lib/tapioca/gem/pipeline.rb#56 sig { params(symbol: ::String).void } def push_symbol(symbol); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#102 + # Constants and properties filtering + # + # source://tapioca//lib/tapioca/gem/pipeline.rb#106 sig { params(symbol_name: ::String).returns(T::Boolean) } def symbol_in_payload?(symbol_name); end private - # source://tapioca//lib/tapioca/gem/pipeline.rb#362 + # source://tapioca//lib/tapioca/gem/pipeline.rb#440 sig { params(name: ::String).void } def add_to_alias_namespace(name); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#367 + # source://tapioca//lib/tapioca/gem/pipeline.rb#445 sig { params(name: ::String).returns(T::Boolean) } def alias_namespaced?(name); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#213 + # source://tapioca//lib/tapioca/gem/pipeline.rb#244 sig { params(name: ::String, constant: ::Module).void } def compile_alias(name, constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#199 + # source://tapioca//lib/tapioca/gem/pipeline.rb#230 sig { params(symbol: ::String, constant: ::BasicObject).void } def compile_constant(symbol, constant); end - # Compile + # Compiling # - # source://tapioca//lib/tapioca/gem/pipeline.rb#194 + # source://tapioca//lib/tapioca/gem/pipeline.rb#219 sig { params(symbol: ::String, constant: ::Module).void } def compile_foreign_constant(symbol, constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#269 - sig { params(name: ::String, constant: ::Module, foreign_constant: T::Boolean).void } - def compile_module(name, constant, foreign_constant: T.unsafe(nil)); end + # source://tapioca//lib/tapioca/gem/pipeline.rb#298 + sig { params(name: ::String, constant: ::Module).void } + def compile_module(name, constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#234 + # source://tapioca//lib/tapioca/gem/pipeline.rb#265 sig { params(name: ::String, value: ::BasicObject).void } def compile_object(name, value); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#294 - sig { params(constant: ::Class).returns(T.nilable(::String)) } + # source://tapioca//lib/tapioca/gem/pipeline.rb#309 + sig { params(name: ::String, constant: ::Module).returns(::RBI::Scope) } + def compile_scope(name, constant); end + + # source://tapioca//lib/tapioca/gem/pipeline.rb#323 + sig { params(constant: T::Class[T.anything]).returns(T.nilable(::String)) } def compile_superclass(constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#343 + # source://tapioca//lib/tapioca/gem/pipeline.rb#421 sig { params(constant: ::Module, strict: T::Boolean).returns(T::Boolean) } def defined_in_gem?(constant, strict: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#146 + # source://tapioca//lib/tapioca/gem/pipeline.rb#177 sig { params(event: ::Tapioca::Gem::Event).void } def dispatch(event); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#384 + # Helpers + # + # source://tapioca//lib/tapioca/gem/pipeline.rb#464 sig { params(constant: T.all(::Module, ::T::Generic)).returns(::String) } def generic_name_of(constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#355 + # source://tapioca//lib/tapioca/gem/pipeline.rb#433 sig { params(constant: ::Module).returns(T::Set[::String]) } def get_file_candidates(constant); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#133 + # source://tapioca//lib/tapioca/gem/pipeline.rb#162 sig { params(gem: ::Tapioca::Gemfile::GemSpec).returns(T::Set[::String]) } def load_bootstrap_symbols(gem); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#374 - sig { params(name: ::String).void } - def mark_seen(name); end - - # source://tapioca//lib/tapioca/gem/pipeline.rb#400 + # source://tapioca//lib/tapioca/gem/pipeline.rb#480 sig { params(constant: ::Module, class_name: T.nilable(::String)).returns(T.nilable(::String)) } def name_of_proxy_target(constant, class_name); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#141 + # Events handling + # + # source://tapioca//lib/tapioca/gem/pipeline.rb#172 sig { returns(::Tapioca::Gem::Event) } def next_event; end - # source://tapioca//lib/tapioca/gem/pipeline.rb#169 + # source://tapioca//lib/tapioca/gem/pipeline.rb#200 sig { params(event: ::Tapioca::Gem::ConstantFound).void } def on_constant(event); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#187 + # source://tapioca//lib/tapioca/gem/pipeline.rb#212 sig { params(event: ::Tapioca::Gem::NodeAdded).void } def on_node(event); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#160 + # source://tapioca//lib/tapioca/gem/pipeline.rb#191 sig { params(event: ::Tapioca::Gem::SymbolFound).void } def on_symbol(event); end - # source://tapioca//lib/tapioca/gem/pipeline.rb#379 + # source://tapioca//lib/tapioca/gem/pipeline.rb#452 + sig { params(name: ::String).void } + def seen!(name); end + + # source://tapioca//lib/tapioca/gem/pipeline.rb#457 sig { params(name: ::String).returns(T::Boolean) } def seen?(name); end + + # source://tapioca//lib/tapioca/gem/pipeline.rb#391 + sig { params(name: ::String, constant: ::Module).returns(T::Boolean) } + def skip_alias?(name, constant); end + + # source://tapioca//lib/tapioca/gem/pipeline.rb#379 + sig { params(name: ::String, constant: T.anything).returns(T::Boolean) } + def skip_constant?(name, constant); end + + # source://tapioca//lib/tapioca/gem/pipeline.rb#408 + sig { params(name: ::String, constant: ::Module).returns(T::Boolean) } + def skip_foreign_constant?(name, constant); end + + # source://tapioca//lib/tapioca/gem/pipeline.rb#413 + sig { params(name: ::String, constant: ::Module).returns(T::Boolean) } + def skip_module?(name, constant); end + + # source://tapioca//lib/tapioca/gem/pipeline.rb#400 + sig { params(name: ::String, constant: ::BasicObject).returns(T::Boolean) } + def skip_object?(name, constant); end + + # Constants and properties filtering + # + # source://tapioca//lib/tapioca/gem/pipeline.rb#374 + sig { params(name: ::String).returns(T::Boolean) } + def skip_symbol?(name); end end +# this looks something like: +# "(eval at /path/to/file.rb:123)" +# and we are just interested in the "/path/to/file.rb" part +# +# source://tapioca//lib/tapioca/gem/pipeline.rb#116 +Tapioca::Gem::Pipeline::EVAL_SOURCE_FILE_PATTERN = T.let(T.unsafe(nil), Regexp) + # source://tapioca//lib/tapioca/gem/pipeline.rb#11 Tapioca::Gem::Pipeline::IGNORED_SYMBOLS = T.let(T.unsafe(nil), Array) @@ -1894,277 +2157,292 @@ module Tapioca::GemHelper def gem_in_bundle_path?(full_gem_path); end # source://tapioca//lib/tapioca/helpers/gem_helper.rb#22 + sig { params(full_gem_path: ::String).returns(T::Boolean) } + def gem_in_ruby_path?(full_gem_path); end + + # source://tapioca//lib/tapioca/helpers/gem_helper.rb#27 sig { params(path: T.any(::Pathname, ::String)).returns(::String) } def to_realpath(path); end private - # source://tapioca//lib/tapioca/helpers/gem_helper.rb#31 + # source://tapioca//lib/tapioca/helpers/gem_helper.rb#36 sig { params(path: T.any(::Pathname, ::String), dir: T.any(::Pathname, ::String)).returns(T::Boolean) } def path_in_dir?(path, dir); end end -# source://tapioca//lib/tapioca/gemfile.rb#5 +# source://tapioca//lib/tapioca/gem_info.rb#5 +class Tapioca::GemInfo < ::T::Struct + const :name, ::String + const :version, ::Gem::Version + + class << self + # source://tapioca//lib/tapioca/gem_info.rb#13 + sig { params(spec: ::Bundler::LazySpecification).returns(::Tapioca::GemInfo) } + def from_spec(spec); end + + # source://sorbet-runtime/0.5.11520/lib/types/struct.rb#13 + def inherited(s); end + end +end + +# source://tapioca//lib/tapioca/gemfile.rb#7 class Tapioca::Gemfile - # source://tapioca//lib/tapioca/gemfile.rb#69 - sig { params(exclude: T::Array[::String]).void } - def initialize(exclude); end + # source://tapioca//lib/tapioca/gemfile.rb#27 + sig { params(excluded_gems: T::Array[::String]).void } + def initialize(excluded_gems); end - # source://tapioca//lib/tapioca/gemfile.rb#60 + # source://tapioca//lib/tapioca/gemfile.rb#18 sig { returns(::Bundler::Definition) } def definition; end - # source://tapioca//lib/tapioca/gemfile.rb#63 + # source://tapioca//lib/tapioca/gemfile.rb#21 sig { returns(T::Array[::Tapioca::Gemfile::GemSpec]) } def dependencies; end - # source://tapioca//lib/tapioca/gemfile.rb#80 + # source://tapioca//lib/tapioca/gemfile.rb#40 sig { params(gem_name: ::String).returns(T.nilable(::Tapioca::Gemfile::GemSpec)) } def gem(gem_name); end - # source://tapioca//lib/tapioca/gemfile.rb#66 + # source://tapioca//lib/tapioca/gemfile.rb#24 sig { returns(T::Array[::String]) } def missing_specs; end - # source://tapioca//lib/tapioca/gemfile.rb#85 + # source://tapioca//lib/tapioca/gemfile.rb#45 sig { void } def require_bundle; end private - # source://tapioca//lib/tapioca/gemfile.rb#131 + # source://tapioca//lib/tapioca/gemfile.rb#92 sig { returns(::String) } def dir; end - # source://tapioca//lib/tapioca/gemfile.rb#92 + # source://tapioca//lib/tapioca/gemfile.rb#54 sig { returns(::File) } def gemfile; end - # source://tapioca//lib/tapioca/gemfile.rb#126 + # source://tapioca//lib/tapioca/gemfile.rb#87 sig { returns(T::Array[::Symbol]) } def groups; end - # source://tapioca//lib/tapioca/gemfile.rb#95 + # source://tapioca//lib/tapioca/gemfile.rb#57 sig { returns([T::Array[::Tapioca::Gemfile::GemSpec], T::Array[::String]]) } def load_dependencies; end # @return [File] # - # source://tapioca//lib/tapioca/gemfile.rb#92 + # source://tapioca//lib/tapioca/gemfile.rb#54 def lockfile; end - # source://tapioca//lib/tapioca/gemfile.rb#106 + # source://tapioca//lib/tapioca/gemfile.rb#68 sig { returns([T::Enumerable[T.any(::Bundler::StubSpecification, ::Gem::Specification)], T::Array[::String]]) } def materialize_deps; end - # source://tapioca//lib/tapioca/gemfile.rb#121 + # source://tapioca//lib/tapioca/gemfile.rb#82 sig { returns(::Bundler::Runtime) } def runtime; end end -# This is a module that gets prepended to `Bundler::Dependency` and -# makes sure even gems marked as `require: false` are required during -# `Bundler.require`. -# -# source://tapioca//lib/tapioca/gemfile.rb#18 -module Tapioca::Gemfile::AutoRequireHook - requires_ancestor { Bundler::Dependency } - - # source://tapioca//lib/tapioca/gemfile.rb#39 - sig { returns(T.untyped) } - def autorequire; end - - class << self - # source://tapioca//lib/tapioca/gemfile.rb#30 - sig { params(exclude: T::Array[::String]).returns(T::Array[::String]) } - def exclude=(exclude); end - - # source://tapioca//lib/tapioca/gemfile.rb#33 - sig { params(name: T.untyped).returns(T::Boolean) } - def excluded?(name); end - end -end - -# source://tapioca//lib/tapioca/gemfile.rb#135 +# source://tapioca//lib/tapioca/gemfile.rb#96 class Tapioca::Gemfile::GemSpec include ::Tapioca::GemHelper - # source://tapioca//lib/tapioca/gemfile.rb#174 + # source://tapioca//lib/tapioca/gemfile.rb#136 sig { params(spec: T.any(::Bundler::StubSpecification, ::Gem::Specification)).void } def initialize(spec); end - # source://tapioca//lib/tapioca/gemfile.rb#184 + # source://tapioca//lib/tapioca/gemfile.rb#146 sig { params(other: ::BasicObject).returns(T::Boolean) } def ==(other); end - # source://tapioca//lib/tapioca/gemfile.rb#204 + # source://tapioca//lib/tapioca/gemfile.rb#171 sig { params(path: ::String).returns(T::Boolean) } def contains_path?(path); end - # source://tapioca//lib/tapioca/gemfile.rb#223 + # source://tapioca//lib/tapioca/gemfile.rb#161 + sig { returns(T::Array[::Gem::Dependency]) } + def dependencies; end + + # source://tapioca//lib/tapioca/gemfile.rb#201 sig { returns(T::Boolean) } def export_rbi_files?; end - # source://tapioca//lib/tapioca/gemfile.rb#218 + # source://tapioca//lib/tapioca/gemfile.rb#196 sig { returns(T::Array[::String]) } def exported_rbi_files; end - # source://tapioca//lib/tapioca/gemfile.rb#228 + # source://tapioca//lib/tapioca/gemfile.rb#206 sig { returns(::RBI::MergeTree) } def exported_rbi_tree; end - # source://tapioca//lib/tapioca/gemfile.rb#171 + # source://tapioca//lib/tapioca/gemfile.rb#133 sig { returns(T::Array[::Pathname]) } def files; end - # source://tapioca//lib/tapioca/gemfile.rb#168 + # source://tapioca//lib/tapioca/gemfile.rb#130 sig { returns(::String) } def full_gem_path; end - # source://tapioca//lib/tapioca/gemfile.rb#189 + # source://tapioca//lib/tapioca/gemfile.rb#151 sig { params(gemfile_dir: ::String).returns(T::Boolean) } def ignore?(gemfile_dir); end - # source://tapioca//lib/tapioca/gemfile.rb#194 + # source://tapioca//lib/tapioca/gemfile.rb#156 sig { returns(::String) } def name; end - # source://tapioca//lib/tapioca/gemfile.rb#213 + # source://tapioca//lib/tapioca/gemfile.rb#180 sig { void } def parse_yard_docs; end - # source://tapioca//lib/tapioca/gemfile.rb#199 + # source://tapioca//lib/tapioca/gemfile.rb#166 sig { returns(::String) } def rbi_file_name; end - # source://tapioca//lib/tapioca/gemfile.rb#240 + # source://tapioca//lib/tapioca/gemfile.rb#218 sig { params(file: ::Pathname).returns(::Pathname) } def relative_path_for(file); end # @return [String] # - # source://tapioca//lib/tapioca/gemfile.rb#168 + # source://tapioca//lib/tapioca/gemfile.rb#130 def version; end private - # source://tapioca//lib/tapioca/gemfile.rb#251 + # source://tapioca//lib/tapioca/gemfile.rb#229 sig { returns(T::Array[::Pathname]) } def collect_files; end - # source://tapioca//lib/tapioca/gemfile.rb#266 + # source://tapioca//lib/tapioca/gemfile.rb#244 sig { returns(T.nilable(T::Boolean)) } def default_gem?; end - # source://tapioca//lib/tapioca/gemfile.rb#324 + # source://tapioca//lib/tapioca/gemfile.rb#303 sig { returns(T::Boolean) } def gem_ignored?; end - # source://tapioca//lib/tapioca/gemfile.rb#303 + # source://tapioca//lib/tapioca/gemfile.rb#282 sig { params(path: ::String).returns(T::Boolean) } def has_parent_gemspec?(path); end - # source://tapioca//lib/tapioca/gemfile.rb#271 + # source://tapioca//lib/tapioca/gemfile.rb#249 sig { returns(::Regexp) } def require_paths_prefix_matcher; end - # source://tapioca//lib/tapioca/gemfile.rb#282 + # source://tapioca//lib/tapioca/gemfile.rb#261 sig { params(file: ::String).returns(::Pathname) } def resolve_to_ruby_lib_dir(file); end - # source://tapioca//lib/tapioca/gemfile.rb#296 + # source://tapioca//lib/tapioca/gemfile.rb#275 sig { returns(::String) } def version_string; end class << self - # source://tapioca//lib/tapioca/gemfile.rb#143 + # source://tapioca//lib/tapioca/gemfile.rb#104 sig { returns(T::Hash[::String, ::Tapioca::Gemfile::GemSpec]) } def spec_lookup_by_file_path; end end end -# source://tapioca//lib/tapioca/gemfile.rb#155 +# source://tapioca//lib/tapioca/gemfile.rb#116 Tapioca::Gemfile::GemSpec::IGNORED_GEMS = T.let(T.unsafe(nil), Array) -# source://tapioca//lib/tapioca/gemfile.rb#8 +# source://tapioca//lib/tapioca/gemfile.rb#10 Tapioca::Gemfile::Spec = T.type_alias { T.any(::Bundler::StubSpecification, ::Gem::Specification) } +# source://tapioca//lib/tapioca.rb#33 +Tapioca::LIB_ROOT_DIR = T.let(T.unsafe(nil), String) + # source://tapioca//lib/tapioca/loaders/loader.rb#5 module Tapioca::Loaders; end # source://tapioca//lib/tapioca/loaders/dsl.rb#6 class Tapioca::Loaders::Dsl < ::Tapioca::Loaders::Loader - # source://tapioca//lib/tapioca/loaders/dsl.rb#30 - sig { params(tapioca_path: ::String, eager_load: T::Boolean, app_root: ::String).void } - def initialize(tapioca_path:, eager_load: T.unsafe(nil), app_root: T.unsafe(nil)); end + # source://tapioca//lib/tapioca/loaders/dsl.rb#38 + sig do + params( + tapioca_path: ::String, + eager_load: T::Boolean, + app_root: ::String, + halt_upon_load_error: T::Boolean + ).void + end + def initialize(tapioca_path:, eager_load: T.unsafe(nil), app_root: T.unsafe(nil), halt_upon_load_error: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/loaders/dsl.rb#20 + # source://tapioca//lib/tapioca/loaders/dsl.rb#27 sig { override.void } def load; end protected - # source://tapioca//lib/tapioca/loaders/dsl.rb#75 - sig { void } - def abort_if_pending_migrations!; end - - # source://tapioca//lib/tapioca/loaders/dsl.rb#62 + # source://tapioca//lib/tapioca/loaders/dsl.rb#88 sig { void } def load_application; end - # source://tapioca//lib/tapioca/loaders/dsl.rb#44 + # source://tapioca//lib/tapioca/loaders/dsl.rb#63 sig { void } def load_dsl_compilers; end - # source://tapioca//lib/tapioca/loaders/dsl.rb#39 + # source://tapioca//lib/tapioca/loaders/dsl.rb#48 sig { void } def load_dsl_extensions; end class << self - # source://tapioca//lib/tapioca/loaders/dsl.rb#13 - sig { params(tapioca_path: ::String, eager_load: T::Boolean, app_root: ::String).void } - def load_application(tapioca_path:, eager_load: T.unsafe(nil), app_root: T.unsafe(nil)); end + # source://tapioca//lib/tapioca/loaders/dsl.rb#15 + sig do + params( + tapioca_path: ::String, + eager_load: T::Boolean, + app_root: ::String, + halt_upon_load_error: T::Boolean + ).void + end + def load_application(tapioca_path:, eager_load: T.unsafe(nil), app_root: T.unsafe(nil), halt_upon_load_error: T.unsafe(nil)); end end end # source://tapioca//lib/tapioca/loaders/gem.rb#6 class Tapioca::Loaders::Gem < ::Tapioca::Loaders::Loader - # source://tapioca//lib/tapioca/loaders/gem.rb#46 + # source://tapioca//lib/tapioca/loaders/gem.rb#49 sig do params( bundle: ::Tapioca::Gemfile, prerequire: T.nilable(::String), postrequire: ::String, - default_command: ::String + default_command: ::String, + halt_upon_load_error: T::Boolean ).void end - def initialize(bundle:, prerequire:, postrequire:, default_command:); end + def initialize(bundle:, prerequire:, postrequire:, default_command:, halt_upon_load_error:); end - # source://tapioca//lib/tapioca/loaders/gem.rb#32 + # source://tapioca//lib/tapioca/loaders/gem.rb#34 sig { override.void } def load; end protected - # source://tapioca//lib/tapioca/loaders/gem.rb#76 + # source://tapioca//lib/tapioca/loaders/gem.rb#80 sig { params(file: ::String, error: ::LoadError).void } def explain_failed_require(file, error); end - # source://tapioca//lib/tapioca/loaders/gem.rb#56 + # source://tapioca//lib/tapioca/loaders/gem.rb#60 sig { void } def require_gem_file; end class << self - # source://tapioca//lib/tapioca/loaders/gem.rb#20 + # source://tapioca//lib/tapioca/loaders/gem.rb#21 sig do params( bundle: ::Tapioca::Gemfile, prerequire: T.nilable(::String), postrequire: ::String, - default_command: ::String + default_command: ::String, + halt_upon_load_error: T::Boolean ).void end - def load_application(bundle:, prerequire:, postrequire:, default_command:); end + def load_application(bundle:, prerequire:, postrequire:, default_command:, halt_upon_load_error:); end end end @@ -2182,9 +2460,6 @@ class Tapioca::Loaders::Loader abstract! - # source://sorbet-runtime/0.5.10601/lib/types/private/abstract/declare.rb#37 - def initialize(*args, **_arg1, &blk); end - # @abstract # # source://tapioca//lib/tapioca/loaders/loader.rb#17 @@ -2193,43 +2468,76 @@ class Tapioca::Loaders::Loader private - # source://tapioca//lib/tapioca/loaders/loader.rb#112 + # Rails 7.2 renamed `eager_load_paths` to `all_eager_load_paths`, which maintains the same original functionality. + # The `eager_load_paths` method still exists, but doesn't return all paths anymore and causes Tapioca to miss some + # engine paths. The following commit is the change: + # https://github.com/rails/rails/commit/ebfca905db14020589c22e6937382e6f8f687664 + # + # source://tapioca//lib/tapioca/loaders/loader.rb#234 + sig { params(engine: T.class_of(Rails::Engine)).returns(T::Array[::String]) } + def eager_load_paths(engine); end + + # source://tapioca//lib/tapioca/loaders/loader.rb#199 sig { void } def eager_load_rails_app; end - # source://tapioca//lib/tapioca/loaders/loader.rb#24 + # @return [Array] + # + # source://tapioca//lib/tapioca/loaders/loader.rb#178 + def engines; end + + # source://tapioca//lib/tapioca/loaders/loader.rb#29 sig do params( gemfile: ::Tapioca::Gemfile, initialize_file: T.nilable(::String), - require_file: T.nilable(::String) + require_file: T.nilable(::String), + halt_upon_load_error: T::Boolean ).void end - def load_bundle(gemfile, initialize_file, require_file); end + def load_bundle(gemfile, initialize_file, require_file, halt_upon_load_error); end - # source://tapioca//lib/tapioca/loaders/loader.rb#37 - sig { params(environment_load: T::Boolean, eager_load: T::Boolean, app_root: ::String).void } - def load_rails_application(environment_load: T.unsafe(nil), eager_load: T.unsafe(nil), app_root: T.unsafe(nil)); end + # source://tapioca//lib/tapioca/loaders/loader.rb#136 + sig { void } + def load_engines_in_classic_mode; end - # source://tapioca//lib/tapioca/loaders/loader.rb#60 + # source://tapioca//lib/tapioca/loaders/loader.rb#114 sig { void } - def load_rails_engines; end + def load_engines_in_zeitwerk_mode; end + + # source://tapioca//lib/tapioca/loaders/loader.rb#49 + sig do + params( + environment_load: T::Boolean, + eager_load: T::Boolean, + app_root: ::String, + halt_upon_load_error: T::Boolean + ).void + end + def load_rails_application(environment_load: T.unsafe(nil), eager_load: T.unsafe(nil), app_root: T.unsafe(nil), halt_upon_load_error: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/loaders/loader.rb#83 - sig { returns(T::Array[T.untyped]) } - def rails_engines; end + # source://tapioca//lib/tapioca/loaders/loader.rb#89 + sig { void } + def load_rails_engines; end - # source://tapioca//lib/tapioca/loaders/loader.rb#138 + # source://tapioca//lib/tapioca/loaders/loader.rb#220 sig { params(file: T.nilable(::String)).void } def require_helper(file); end - # source://tapioca//lib/tapioca/loaders/loader.rb#97 + # source://tapioca//lib/tapioca/loaders/loader.rb#103 + def run_initializers; end + + # source://tapioca//lib/tapioca/loaders/loader.rb#192 sig { params(path: ::String).void } def safe_require(path); end - # source://tapioca//lib/tapioca/loaders/loader.rb#104 - sig { void } - def silence_deprecations; end + # source://tapioca//lib/tapioca/loaders/loader.rb#161 + sig { params(blk: T.proc.void).void } + def with_rails_application(&blk); end + + # source://tapioca//lib/tapioca/loaders/loader.rb#154 + sig { returns(T::Boolean) } + def zeitwerk_mode?; end end # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#5 @@ -2267,26 +2575,26 @@ module Tapioca::RBIFilesHelper dsl_dir: ::String, auto_strictness: T::Boolean, gems: T::Array[::Tapioca::Gemfile::GemSpec], - compilers: T::Enumerable[::Class] + compilers: T::Enumerable[T.class_of(Tapioca::Dsl::Compiler)] ).void end def validate_rbi_files(command:, gem_dir:, dsl_dir:, auto_strictness:, gems: T.unsafe(nil), compilers: T.unsafe(nil)); end private - # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#209 + # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#223 sig { params(nodes: T::Array[::RBI::Node]).returns(T::Array[::RBI::Scope]) } def extract_empty_scopes(nodes); end - # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#214 + # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#228 sig { params(nodes: T::Array[::RBI::Node]).returns(T::Array[T.any(::RBI::Attr, ::RBI::Method)]) } def extract_methods_and_attrs(nodes); end - # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#224 + # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#238 sig { params(nodes: T::Array[::RBI::Node]).returns(T::Array[T.any(::RBI::Mixin, ::RBI::RequiresAncestor)]) } def extract_mixins(nodes); end - # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#234 + # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#248 sig do params( nodes: T::Array[T.any(::RBI::Attr, ::RBI::Method)] @@ -2294,7 +2602,7 @@ module Tapioca::RBIFilesHelper end def extract_nodes_with_sigs(nodes); end - # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#202 + # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#216 sig do params( nodes: T::Array[::RBI::Node], @@ -2304,7 +2612,7 @@ module Tapioca::RBIFilesHelper end def extract_shims_and_todos(nodes, shim_rbi_dir:, todo_rbi_file:); end - # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#266 + # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#280 sig { params(path: ::String).returns(::String) } def gem_name_from_rbi_path(path); end @@ -2316,14 +2624,14 @@ module Tapioca::RBIFilesHelper sig { params(nodes: T::Array[::RBI::Node], shim_rbi_dir: ::String, todo_rbi_file: ::String).returns(T::Boolean) } def shims_or_todos_have_duplicates?(nodes, shim_rbi_dir:, todo_rbi_file:); end - # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#239 + # source://tapioca//lib/tapioca/helpers/rbi_files_helper.rb#253 sig { params(errors: T::Array[::Spoom::Sorbet::Errors::Error], gem_dir: ::String).void } def update_gem_rbis_strictnesses(errors, gem_dir); end end # source://tapioca//lib/tapioca/rbi_formatter.rb#5 class Tapioca::RBIFormatter < ::RBI::Formatter - # source://tapioca//lib/tapioca/rbi_formatter.rb#22 + # source://tapioca//lib/tapioca/rbi_formatter.rb#24 sig { params(file: ::RBI::File).void } def write_empty_body_comment!(file); end @@ -2342,6 +2650,10 @@ module Tapioca::RBIHelper sig { params(type: ::String).returns(::String) } def as_nilable_type(type); end + # source://tapioca//lib/tapioca/helpers/rbi_helper.rb#100 + sig { params(type: ::String).returns(::String) } + def as_non_nilable_type(type); end + # source://tapioca//lib/tapioca/helpers/rbi_helper.rb#72 sig { params(name: ::String, type: ::String).returns(::RBI::TypedParam) } def create_block_param(name, type:); end @@ -2378,11 +2690,11 @@ module Tapioca::RBIHelper sig { params(sig_string: ::String).returns(::String) } def sanitize_signature_types(sig_string); end - # source://tapioca//lib/tapioca/helpers/rbi_helper.rb#100 + # source://tapioca//lib/tapioca/helpers/rbi_helper.rb#109 sig { params(name: ::String).returns(T::Boolean) } def valid_method_name?(name); end - # source://tapioca//lib/tapioca/helpers/rbi_helper.rb#114 + # source://tapioca//lib/tapioca/helpers/rbi_helper.rb#123 sig { params(name: ::String).returns(T::Boolean) } def valid_parameter_name?(name); end @@ -2433,8 +2745,19 @@ end # source://tapioca//lib/tapioca/runtime/trackers/autoload.rb#5 module Tapioca::Runtime; end +# This module should only be included when running versions of Ruby +# older than 3.2. Because the Class#attached_object method is not +# available, it implements finding the attached class of a singleton +# class by iterating through ObjectSpace. +module Tapioca::Runtime::AttachedClassOf + # source://tapioca//lib/tapioca/runtime/attached_class_of_32.rb#14 + sig { params(singleton_class: ::Class).returns(T.nilable(::Module)) } + def attached_class_of(singleton_class); end +end + # source://tapioca//lib/tapioca/runtime/dynamic_mixin_compiler.rb#6 class Tapioca::Runtime::DynamicMixinCompiler + include ::Tapioca::Runtime::AttachedClassOf include ::Tapioca::Runtime::Reflection # source://tapioca//lib/tapioca/runtime/dynamic_mixin_compiler.rb#20 @@ -2565,7 +2888,7 @@ module Tapioca::Runtime::GenericTypeRegistry def create_generic_type(constant, name); end # source://tapioca//lib/tapioca/runtime/generic_type_registry.rb#155 - sig { params(constant: ::Class).returns(::Class) } + sig { params(constant: T::Class[T.anything]).returns(T::Class[T.anything]) } def create_safe_subclass(constant); end # source://tapioca//lib/tapioca/runtime/generic_type_registry.rb#182 @@ -2586,35 +2909,37 @@ class Tapioca::Runtime::GenericTypeRegistry::GenericType < ::T::Types::Simple end module Tapioca::Runtime::Reflection + include ::Tapioca::Runtime::AttachedClassOf + extend ::Tapioca::Runtime::AttachedClassOf extend ::Tapioca::Runtime::Reflection - # source://tapioca//lib/tapioca/runtime/reflection.rb#66 + # source://tapioca//lib/tapioca/runtime/reflection.rb#196 + sig { params(constant: ::Module).returns(T.untyped) } + def abstract_type_of(constant); end + + # source://tapioca//lib/tapioca/runtime/reflection.rb#77 sig { params(constant: ::Module).returns(T::Array[::Module]) } def ancestors_of(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#81 + # source://tapioca//lib/tapioca/runtime/reflection.rb#92 sig { params(object: ::BasicObject, other: ::BasicObject).returns(T::Boolean) } def are_equal?(object, other); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#178 - sig { params(singleton_class: ::Module).returns(T.nilable(::Module)) } - def attached_class_of(singleton_class); end - - # source://tapioca//lib/tapioca/runtime/reflection.rb#45 - sig { params(object: ::BasicObject).returns(::Class) } + # source://tapioca//lib/tapioca/runtime/reflection.rb#56 + sig { params(object: ::BasicObject).returns(T::Class[T.anything]) } def class_of(object); end # @param constant [BasicObject] # @return [Boolean] # - # source://tapioca//lib/tapioca/runtime/reflection.rb#27 + # source://tapioca//lib/tapioca/runtime/reflection.rb#38 def constant_defined?(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#38 + # source://tapioca//lib/tapioca/runtime/reflection.rb#49 sig { params(symbol: ::String, inherit: T::Boolean, namespace: ::Module).returns(::BasicObject) } def constantize(symbol, inherit: T.unsafe(nil), namespace: T.unsafe(nil)); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#50 + # source://tapioca//lib/tapioca/runtime/reflection.rb#61 sig { params(constant: ::Module).returns(T::Array[::Symbol]) } def constants_of(constant); end @@ -2632,52 +2957,56 @@ module Tapioca::Runtime::Reflection # class D < C; end # descendants_of(C) # => [B, A, D] # - # source://tapioca//lib/tapioca/runtime/reflection.rb#156 + # source://tapioca//lib/tapioca/runtime/reflection.rb#167 sig do type_parameters(:U) .params( - klass: T.all(::Class, T.type_parameter(:U)) + klass: T.all(T.type_parameter(:U), T::Class[T.anything]) ).returns(T::Array[T.type_parameter(:U)]) end def descendants_of(klass); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#188 + # source://tapioca//lib/tapioca/runtime/reflection.rb#189 sig { params(constant: ::Module).returns(T::Set[::String]) } def file_candidates_for(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#101 + # source://tapioca//lib/tapioca/runtime/reflection.rb#202 + sig { params(constant: ::Module).returns(T::Boolean) } + def final_module?(constant); end + + # source://tapioca//lib/tapioca/runtime/reflection.rb#112 sig { params(constant: ::Module).returns(T::Array[::Module]) } def inherited_ancestors_of(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#134 + # source://tapioca//lib/tapioca/runtime/reflection.rb#145 sig { params(constant: ::Module, method: ::Symbol).returns(::Method) } def method_of(constant, method); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#55 + # source://tapioca//lib/tapioca/runtime/reflection.rb#66 sig { params(constant: ::Module).returns(T.nilable(::String)) } def name_of(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#129 + # source://tapioca//lib/tapioca/runtime/reflection.rb#140 sig { params(type: ::T::Types::Base).returns(::String) } def name_of_type(type); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#76 + # source://tapioca//lib/tapioca/runtime/reflection.rb#87 sig { params(object: ::BasicObject).returns(::Integer) } def object_id_of(object); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#96 + # source://tapioca//lib/tapioca/runtime/reflection.rb#107 sig { params(constant: ::Module).returns(T::Array[::Symbol]) } def private_instance_methods_of(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#91 + # source://tapioca//lib/tapioca/runtime/reflection.rb#102 sig { params(constant: ::Module).returns(T::Array[::Symbol]) } def protected_instance_methods_of(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#86 + # source://tapioca//lib/tapioca/runtime/reflection.rb#97 sig { params(constant: ::Module).returns(T::Array[::Symbol]) } def public_instance_methods_of(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#110 + # source://tapioca//lib/tapioca/runtime/reflection.rb#121 sig { params(constant: ::Module).returns(T.nilable(::String)) } def qualified_name_of(constant); end @@ -2685,78 +3014,86 @@ module Tapioca::Runtime::Reflection # by searching for the label "". If none is found, it returns the location # labeled "
", which is the original call site. # - # source://tapioca//lib/tapioca/runtime/reflection.rb#168 + # source://tapioca//lib/tapioca/runtime/reflection.rb#179 sig { params(locations: T.nilable(T::Array[::Thread::Backtrace::Location])).returns(::String) } def resolve_loc(locations); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#122 + # source://tapioca//lib/tapioca/runtime/reflection.rb#207 + sig { params(constant: ::Module).returns(T::Boolean) } + def sealed_module?(constant); end + + # source://tapioca//lib/tapioca/runtime/reflection.rb#133 sig { params(method: T.any(::Method, ::UnboundMethod)).returns(T.untyped) } def signature_of(method); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#61 - sig { params(constant: ::Module).returns(::Class) } + # source://tapioca//lib/tapioca/runtime/reflection.rb#72 + sig { params(constant: ::Module).returns(T::Class[T.anything]) } def singleton_class_of(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#71 - sig { params(constant: ::Class).returns(T.nilable(::Class)) } + # source://tapioca//lib/tapioca/runtime/reflection.rb#82 + sig { params(constant: T::Class[T.anything]).returns(T.nilable(T::Class[T.anything])) } def superclass_of(constant); end private - # source://tapioca//lib/tapioca/runtime/reflection.rb#227 + # source://tapioca//lib/tapioca/runtime/reflection.rb#244 sig { params(parent: ::Module, name: ::String).returns(T.nilable(::Module)) } def child_module_for_parent_with_name(parent, name); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#238 + # source://tapioca//lib/tapioca/runtime/reflection.rb#260 + sig { params(name: ::String).returns(T::Boolean) } + def has_aliased_namespace?(name); end + + # source://tapioca//lib/tapioca/runtime/reflection.rb#255 sig { params(method: ::UnboundMethod).returns(T::Boolean) } def method_defined_by_forwardable_module?(method); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#213 + # source://tapioca//lib/tapioca/runtime/reflection.rb#230 sig { params(constant: ::Module).returns(T::Array[::UnboundMethod]) } def methods_for(constant); end - # source://tapioca//lib/tapioca/runtime/reflection.rb#197 + # source://tapioca//lib/tapioca/runtime/reflection.rb#214 sig { params(constant: ::Module).returns(T::Array[::UnboundMethod]) } def relevant_methods_for(constant); end end -# source://tapioca//lib/tapioca/runtime/reflection.rb#14 +# source://tapioca//lib/tapioca/runtime/reflection.rb#25 Tapioca::Runtime::Reflection::ANCESTORS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#10 +# source://tapioca//lib/tapioca/runtime/reflection.rb#21 Tapioca::Runtime::Reflection::CLASS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#11 +# source://tapioca//lib/tapioca/runtime/reflection.rb#22 Tapioca::Runtime::Reflection::CONSTANTS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#17 +# source://tapioca//lib/tapioca/runtime/reflection.rb#28 Tapioca::Runtime::Reflection::EQUAL_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#21 +# source://tapioca//lib/tapioca/runtime/reflection.rb#32 Tapioca::Runtime::Reflection::METHOD_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#12 +# source://tapioca//lib/tapioca/runtime/reflection.rb#23 Tapioca::Runtime::Reflection::NAME_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#16 +# source://tapioca//lib/tapioca/runtime/reflection.rb#27 Tapioca::Runtime::Reflection::OBJECT_ID_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#20 +# source://tapioca//lib/tapioca/runtime/reflection.rb#31 Tapioca::Runtime::Reflection::PRIVATE_INSTANCE_METHODS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#19 +# source://tapioca//lib/tapioca/runtime/reflection.rb#30 Tapioca::Runtime::Reflection::PROTECTED_INSTANCE_METHODS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#18 +# source://tapioca//lib/tapioca/runtime/reflection.rb#29 Tapioca::Runtime::Reflection::PUBLIC_INSTANCE_METHODS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#24 +# source://tapioca//lib/tapioca/runtime/reflection.rb#35 Tapioca::Runtime::Reflection::REQUIRED_FROM_LABELS = T.let(T.unsafe(nil), Array) -# source://tapioca//lib/tapioca/runtime/reflection.rb#13 +# source://tapioca//lib/tapioca/runtime/reflection.rb#24 Tapioca::Runtime::Reflection::SINGLETON_CLASS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tapioca//lib/tapioca/runtime/reflection.rb#15 +# source://tapioca//lib/tapioca/runtime/reflection.rb#26 Tapioca::Runtime::Reflection::SUPERCLASS_METHOD = T.let(T.unsafe(nil), UnboundMethod) # source://tapioca//lib/tapioca/runtime/trackers/autoload.rb#6 @@ -2814,6 +3151,7 @@ Tapioca::Runtime::Trackers::Autoload::NOOP_METHOD = T.let(T.unsafe(nil), Proc) # available in the ruby runtime without extra accounting. module Tapioca::Runtime::Trackers::ConstantDefinition extend ::Tapioca::Runtime::Trackers::Tracker + extend ::Tapioca::Runtime::AttachedClassOf extend ::Tapioca::Runtime::Reflection class << self @@ -2946,28 +3284,28 @@ module Tapioca::Runtime::Trackers::Tracker end end -# source://tapioca//lib/tapioca.rb#33 +# source://tapioca//lib/tapioca.rb#35 Tapioca::SORBET_CONFIG_FILE = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#32 +# source://tapioca//lib/tapioca.rb#34 Tapioca::SORBET_DIR = T.let(T.unsafe(nil), String) # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#5 module Tapioca::SorbetHelper - # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#31 + # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#32 sig { params(sorbet_args: ::String).returns(::Spoom::ExecResult) } def sorbet(*sorbet_args); end - # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#36 + # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#37 sig { returns(::String) } def sorbet_path; end - # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#43 + # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#44 sig { params(feature: ::Symbol, version: T.nilable(::Gem::Version)).returns(T::Boolean) } def sorbet_supports?(feature, version: T.unsafe(nil)); end end -# source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#22 +# source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#24 Tapioca::SorbetHelper::FEATURE_REQUIREMENTS = T.let(T.unsafe(nil), Hash) # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#13 @@ -2982,6 +3320,9 @@ Tapioca::SorbetHelper::SORBET_GEM_SPEC = T.let(T.unsafe(nil), Gem::Specification # source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#20 Tapioca::SorbetHelper::SORBET_PAYLOAD_URL = T.let(T.unsafe(nil), String) +# source://tapioca//lib/tapioca/helpers/sorbet_helper.rb#22 +Tapioca::SorbetHelper::SPOOM_CONTEXT = T.let(T.unsafe(nil), Spoom::Context) + # source://tapioca//lib/tapioca/static/symbol_table_parser.rb#5 module Tapioca::Static; end @@ -3017,6 +3358,7 @@ end # source://tapioca//lib/tapioca/static/symbol_loader.rb#6 module Tapioca::Static::SymbolLoader extend ::Tapioca::SorbetHelper + extend ::Tapioca::Runtime::AttachedClassOf extend ::Tapioca::Runtime::Reflection class << self @@ -3024,7 +3366,7 @@ module Tapioca::Static::SymbolLoader sig { params(gem: ::Tapioca::Gemfile::GemSpec).returns(T::Set[::String]) } def engine_symbols(gem); end - # source://tapioca//lib/tapioca/static/symbol_loader.rb#40 + # source://tapioca//lib/tapioca/static/symbol_loader.rb#48 sig { params(gem: ::Tapioca::Gemfile::GemSpec).returns(T::Set[::String]) } def gem_symbols(gem); end @@ -3032,19 +3374,19 @@ module Tapioca::Static::SymbolLoader sig { returns(T::Set[::String]) } def payload_symbols; end + # source://tapioca//lib/tapioca/static/symbol_loader.rb#53 + sig { params(paths: T::Array[::Pathname]).returns(T::Set[::String]) } + def symbols_from_paths(paths); end + private - # source://tapioca//lib/tapioca/static/symbol_loader.rb#47 + # source://tapioca//lib/tapioca/static/symbol_loader.rb#69 sig { returns(T::Array[T.class_of(Rails::Engine)]) } def engines; end - # source://tapioca//lib/tapioca/static/symbol_loader.rb#59 + # source://tapioca//lib/tapioca/static/symbol_loader.rb#82 sig { params(input: ::String, table_type: ::String).returns(::String) } def symbol_table_json_from(input, table_type: T.unsafe(nil)); end - - # source://tapioca//lib/tapioca/static/symbol_loader.rb#64 - sig { params(paths: T::Array[::Pathname]).returns(T::Set[::String]) } - def symbols_from_paths(paths); end end end @@ -3076,22 +3418,22 @@ end # source://tapioca//lib/tapioca/static/symbol_table_parser.rb#9 Tapioca::Static::SymbolTableParser::SKIP_PARSE_KINDS = T.let(T.unsafe(nil), Array) -# source://tapioca//lib/tapioca.rb#35 +# source://tapioca//lib/tapioca.rb#37 Tapioca::TAPIOCA_CONFIG_FILE = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca.rb#34 +# source://tapioca//lib/tapioca.rb#36 Tapioca::TAPIOCA_DIR = T.let(T.unsafe(nil), String) -# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#122 +# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#108 class Tapioca::TypeVariable < ::T::Types::TypeVariable # @return [TypeVariable] a new instance of TypeVariable # - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#123 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#109 def initialize(name, variance); end # Returns the value of attribute name. # - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#128 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#114 def name; end end @@ -3101,69 +3443,55 @@ end # need to do any matching of constants to type variables to bind their names, Ruby will # do that automatically for us and we get the `name` method for free from `Module`. # -# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#136 +# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#122 class Tapioca::TypeVariableModule < ::Module - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#158 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#146 sig do params( context: ::Module, type: ::Tapioca::TypeVariableModule::Type, variance: ::Symbol, - fixed: T.untyped, - lower: T.untyped, - upper: T.untyped, bounds_proc: T.nilable(T.proc.returns(T::Hash[::Symbol, T.untyped])) ).void end - def initialize(context, type, variance, fixed, lower, upper, bounds_proc); end + def initialize(context, type, variance, bounds_proc); end - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#212 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#181 sig { returns(::Tapioca::TypeVariable) } def coerce_to_type_variable; end - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#192 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#161 sig { returns(T::Boolean) } def fixed?; end - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#173 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#155 sig { returns(T.nilable(::String)) } def name; end - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#197 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#166 sig { returns(::String) } def serialize; end + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#136 + sig { returns(::Tapioca::TypeVariableModule::Type) } + def type; end + private - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#246 + # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#188 sig { returns(T::Hash[::Symbol, T.untyped]) } def bounds; end - - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#222 - sig do - params( - fixed: T.untyped, - lower: T.untyped, - upper: T.untyped - ).returns(T.proc.returns(T::Hash[::Symbol, T.untyped])) - end - def build_bounds_proc(fixed, lower, upper); end - - # source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#236 - sig do - type_parameters(:Result) - .params( - block: T.proc.returns(T.type_parameter(:Result)) - ).returns(T.type_parameter(:Result)) - end - def with_bound_name_pre_3_0(&block); end end -# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#139 +# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#133 +Tapioca::TypeVariableModule::DEFAULT_BOUNDS_PROC = T.let(T.unsafe(nil), Proc) + +# source://tapioca//lib/tapioca/sorbet_ext/generic_name_patch.rb#125 class Tapioca::TypeVariableModule::Type < ::T::Enum enums do Member = new Template = new + HasAttachedClass = new end end @@ -3176,14 +3504,14 @@ class URI::Source < ::URI::File sig { params(v: T.nilable(::String)).returns(T::Boolean) } def check_host(v); end - # source://uri/0.12.0/uri/generic.rb#243 + # source://uri/0.13.0/uri/generic.rb#243 def gem_name; end # source://tapioca//lib/tapioca/helpers/source_uri.rb#25 sig { returns(T.nilable(::String)) } def gem_version; end - # source://uri/0.12.0/uri/generic.rb#283 + # source://uri/0.13.0/uri/generic.rb#283 def line_number; end # source://tapioca//lib/tapioca/helpers/source_uri.rb#51 diff --git a/sorbet/rbi/gems/temple@0.10.2.rbi b/sorbet/rbi/gems/temple@0.10.3.rbi similarity index 98% rename from sorbet/rbi/gems/temple@0.10.2.rbi rename to sorbet/rbi/gems/temple@0.10.3.rbi index f33bed99c..a9f665491 100644 --- a/sorbet/rbi/gems/temple@0.10.2.rbi +++ b/sorbet/rbi/gems/temple@0.10.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `temple` gem. # Please instead update this file by running `bin/tapioca gem temple`. + # source://temple//lib/temple/version.rb#2 module Temple; end @@ -220,6 +221,22 @@ class Temple::Filters::DynamicInliner < ::Temple::Filter def on_multi(*exps); end end +# Compile [:multi, [:static, 'foo'], [:dynamic, 'bar']] to [:dynamic, '"foo#{bar}"'] +# +# source://temple//lib/temple/filters/dynamic_merger.rb#5 +class Temple::Filters::DynamicMerger < ::Temple::Filter + # source://temple//lib/temple/filters/dynamic_merger.rb#6 + def on_multi(*exps); end + + private + + # source://temple//lib/temple/filters/dynamic_merger.rb#56 + def count_newline(exps); end + + # source://temple//lib/temple/filters/dynamic_merger.rb#34 + def merge_dynamic(exps); end +end + # Try to encode input string # # @api public @@ -685,7 +702,7 @@ Temple::Grammar::HTMLAttr = T.let(T.unsafe(nil), Temple::Mixins::GrammarDSL::Roo # source://temple//lib/temple/mixins/grammar_dsl.rb#168 Temple::Grammar::HTMLIdentifier = T.let(T.unsafe(nil), Temple::Mixins::GrammarDSL::Root) -# source://temple//lib/temple.rb#60 +# source://temple//lib/temple.rb#61 module Temple::HTML; end # This filter merges html attributes (e.g. used for id and class) diff --git a/sorbet/rbi/gems/term-ansicolor@1.7.1.rbi b/sorbet/rbi/gems/term-ansicolor@1.11.2.rbi similarity index 99% rename from sorbet/rbi/gems/term-ansicolor@1.7.1.rbi rename to sorbet/rbi/gems/term-ansicolor@1.11.2.rbi index 36166e5db..38b53aadb 100644 --- a/sorbet/rbi/gems/term-ansicolor@1.7.1.rbi +++ b/sorbet/rbi/gems/term-ansicolor@1.11.2.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `term-ansicolor` gem. # Please instead update this file by running `bin/tapioca gem term-ansicolor`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/terser@1.1.16.rbi b/sorbet/rbi/gems/terser@1.2.3.rbi similarity index 78% rename from sorbet/rbi/gems/terser@1.1.16.rbi rename to sorbet/rbi/gems/terser@1.2.3.rbi index b465c83c6..bf98c7afe 100644 --- a/sorbet/rbi/gems/terser@1.1.16.rbi +++ b/sorbet/rbi/gems/terser@1.2.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `terser` gem. # Please instead update this file by running `bin/tapioca gem terser`. + # A wrapper around the Terser interface # # source://terser//lib/terser/railtie.rb#5 @@ -14,7 +15,7 @@ class Terser # @raise [ArgumentError] # @return [Terser] a new instance of Terser # - # source://terser//lib/terser.rb#150 + # source://terser//lib/terser.rb#151 def initialize(options = T.unsafe(nil)); end # Minifies JavaScript code @@ -23,7 +24,7 @@ class Terser # @param source_map_options [Hash] optional # @return [String] minified code. # - # source://terser//lib/terser.rb#162 + # source://terser//lib/terser.rb#163 def compile(source, source_map_options = T.unsafe(nil)); end # Minifies JavaScript code and generates a source map @@ -32,7 +33,7 @@ class Terser # @param source_map_options [Hash] optional # @return [Array(String, String)] minified code and source map. # - # source://terser//lib/terser.rb#179 + # source://terser//lib/terser.rb#180 def compile_with_map(source, source_map_options = T.unsafe(nil)); end # Minifies JavaScript code @@ -41,112 +42,112 @@ class Terser # @param source_map_options [Hash] optional # @return [String] minified code. # - # source://terser//lib/terser.rb#162 + # source://terser//lib/terser.rb#163 def compress(source, source_map_options = T.unsafe(nil)); end private - # source://terser//lib/terser.rb#359 + # source://terser//lib/terser.rb#360 def comment_options; end - # source://terser//lib/terser.rb#390 + # source://terser//lib/terser.rb#391 def comment_setting; end - # source://terser//lib/terser.rb#334 + # source://terser//lib/terser.rb#335 def compressor_options; end - # source://terser//lib/terser.rb#470 + # source://terser//lib/terser.rb#471 def conditional_option(value, defaults, overrides = T.unsafe(nil)); end - # source://terser//lib/terser.rb#185 + # source://terser//lib/terser.rb#186 def context; end - # source://terser//lib/terser.rb#263 + # source://terser//lib/terser.rb#264 def context_lines_message(source, line_number, column); end - # source://terser//lib/terser.rb#450 + # source://terser//lib/terser.rb#451 def enclose_options; end - # source://terser//lib/terser.rb#460 + # source://terser//lib/terser.rb#461 def encode_regexp(regexp); end - # source://terser//lib/terser.rb#235 + # source://terser//lib/terser.rb#236 def error_context_format_options(low, high, line_index, column); end - # source://terser//lib/terser.rb#231 + # source://terser//lib/terser.rb#232 def error_context_lines; end - # source://terser//lib/terser.rb#277 + # source://terser//lib/terser.rb#278 def error_message(result, options); end - # source://terser//lib/terser.rb#492 + # source://terser//lib/terser.rb#493 def extract_source_mapping_url(source); end - # source://terser//lib/terser.rb#246 + # source://terser//lib/terser.rb#247 def format_error_line(line, options); end - # source://terser//lib/terser.rb#253 + # source://terser//lib/terser.rb#254 def format_lines(lines, options); end - # source://terser//lib/terser.rb#502 + # source://terser//lib/terser.rb#503 def input_source_map(source, generate_map, options); end # @return [Boolean] # - # source://terser//lib/terser.rb#414 + # source://terser//lib/terser.rb#415 def keep_classnames?(type); end # @return [Boolean] # - # source://terser//lib/terser.rb#405 + # source://terser//lib/terser.rb#406 def keep_fnames?(type); end - # source://terser//lib/terser.rb#301 + # source://terser//lib/terser.rb#302 def mangle_options; end - # source://terser//lib/terser.rb#315 + # source://terser//lib/terser.rb#316 def mangle_properties_options; end # Prevent negate_iife when wrap_iife is true # - # source://terser//lib/terser.rb#351 + # source://terser//lib/terser.rb#352 def negate_iife_block; end - # source://terser//lib/terser.rb#400 + # source://terser//lib/terser.rb#401 def output_options; end - # source://terser//lib/terser.rb#437 + # source://terser//lib/terser.rb#438 def parse_options(source_map_options); end # @raise [Error] # - # source://terser//lib/terser.rb#283 + # source://terser//lib/terser.rb#284 def parse_result(result, generate_map, options, source_map_options = T.unsafe(nil)); end - # source://terser//lib/terser.rb#442 + # source://terser//lib/terser.rb#443 def parse_source_map_options(source_map_options); end - # source://terser//lib/terser.rb#374 + # source://terser//lib/terser.rb#375 def quote_style; end - # source://terser//lib/terser.rb#293 + # source://terser//lib/terser.rb#294 def read_source(source); end # Run TerserJS for given source code # - # source://terser//lib/terser.rb#216 + # source://terser//lib/terser.rb#217 def run_terserjs(input, generate_map, source_map_options = T.unsafe(nil)); end - # source://terser//lib/terser.rb#480 + # source://terser//lib/terser.rb#481 def sanitize_map_root(map); end - # source://terser//lib/terser.rb#199 + # source://terser//lib/terser.rb#200 def source_map_comments(source_map_options); end - # source://terser//lib/terser.rb#423 + # source://terser//lib/terser.rb#424 def source_map_options(input_map, source_map_options); end - # source://terser//lib/terser.rb#208 + # source://terser//lib/terser.rb#209 def source_with(path); end class << self @@ -156,7 +157,7 @@ class Terser # @param options [Hash] optional overrides to +Terser::DEFAULTS+ # @return [String] minified code. # - # source://terser//lib/terser.rb#134 + # source://terser//lib/terser.rb#135 def compile(source, options = T.unsafe(nil)); end # Minifies JavaScript code and generates a source map using implicit context. @@ -165,7 +166,7 @@ class Terser # @param options [Hash] optional overrides to +Terser::DEFAULTS+ # @return [Array(String, String)] minified code and source map. # - # source://terser//lib/terser.rb#143 + # source://terser//lib/terser.rb#144 def compile_with_map(source, options = T.unsafe(nil)); end end end @@ -212,7 +213,7 @@ Terser::DEFAULTS = T.let(T.unsafe(nil), Hash) # source://terser//lib/terser.rb#22 Terser::ES5FallbackPath = T.let(T.unsafe(nil), String) -# source://terser//lib/terser.rb#107 +# source://terser//lib/terser.rb#108 Terser::EXTRA_OPTIONS = T.let(T.unsafe(nil), Array) # Error class for compilation errors. @@ -220,7 +221,7 @@ Terser::EXTRA_OPTIONS = T.let(T.unsafe(nil), Array) # source://terser//lib/terser.rb#15 class Terser::Error < ::StandardError; end -# source://terser//lib/terser.rb#109 +# source://terser//lib/terser.rb#110 Terser::MANGLE_PROPERTIES_DEFAULTS = T.let(T.unsafe(nil), Hash) # Railtie for Rails @@ -228,7 +229,7 @@ Terser::MANGLE_PROPERTIES_DEFAULTS = T.let(T.unsafe(nil), Hash) # source://terser//lib/terser/railtie.rb#7 class Terser::Railtie < ::Rails::Railtie; end -# source://terser//lib/terser.rb#117 +# source://terser//lib/terser.rb#118 Terser::SOURCE_MAP_DEFAULTS = T.let(T.unsafe(nil), Hash) # Source Map path diff --git a/sorbet/rbi/gems/text@1.3.1.rbi b/sorbet/rbi/gems/text@1.3.1.rbi index 94215cf08..41b4904a4 100644 --- a/sorbet/rbi/gems/text@1.3.1.rbi +++ b/sorbet/rbi/gems/text@1.3.1.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `text` gem. # Please instead update this file by running `bin/tapioca gem text`. + # Ruby implementation of the Soundex algorithm, # as described by Knuth in volume 3 of The Art of Computer Programming. # diff --git a/sorbet/rbi/gems/tf2_line_parser@0.2.3.rbi b/sorbet/rbi/gems/tf2_line_parser@0.2.3.rbi index aa9c01950..b0664503d 100644 --- a/sorbet/rbi/gems/tf2_line_parser@0.2.3.rbi +++ b/sorbet/rbi/gems/tf2_line_parser@0.2.3.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `tf2_line_parser` gem. # Please instead update this file by running `bin/tapioca gem tf2_line_parser`. + # source://tf2_line_parser//lib/tf2_line_parser/version.rb#3 module TF2LineParser; end diff --git a/sorbet/rbi/gems/thor@1.2.2.rbi b/sorbet/rbi/gems/thor@1.3.1.rbi similarity index 79% rename from sorbet/rbi/gems/thor@1.2.2.rbi rename to sorbet/rbi/gems/thor@1.3.1.rbi index dcb11ee22..18cf03564 100644 --- a/sorbet/rbi/gems/thor@1.2.2.rbi +++ b/sorbet/rbi/gems/thor@1.3.1.rbi @@ -4,6 +4,31 @@ # This is an autogenerated file for types exported from the `thor` gem. # Please instead update this file by running `bin/tapioca gem thor`. + +# source://thor//lib/thor/shell/lcs_diff.rb#1 +module LCSDiff + protected + + # Overwrite show_diff to show diff with colors if Diff::LCS is + # available. + # + # source://thor//lib/thor/shell/lcs_diff.rb#6 + def show_diff(destination, content); end + + private + + # Check if Diff::LCS is loaded. If it is, use it to create pretty output + # for diff. + # + # @return [Boolean] + # + # source://thor//lib/thor/shell/lcs_diff.rb#37 + def diff_lcs_loaded?; end + + # source://thor//lib/thor/shell/lcs_diff.rb#21 + def output_diff_line(diff); end +end + # source://thor//lib/thor/command.rb#1 class Thor include ::Thor::Base @@ -12,23 +37,63 @@ class Thor extend ::Thor::Base::ClassMethods extend ::Thor::Invocation::ClassMethods - # source://thor//lib/thor.rb#505 + # source://thor//lib/thor.rb#652 def help(command = T.unsafe(nil), subcommand = T.unsafe(nil)); end class << self + # Adds and declares option group for required at least one of options in the + # block of arguments. You can declare options as the outside of the block. + # + # If :for is given as option, it allows you to change the options from + # a previous defined command. + # + # ==== Parameters + # Array[Thor::Option.name] + # options:: :for is applied for previous defined command. + # + # ==== Examples + # + # at_least_one do + # option :one + # option :two + # end + # + # Or + # + # option :one + # option :two + # at_least_one :one, :two + # + # If you do not give "--one" and "--two" AtLeastOneRequiredArgumentError + # will be raised. + # + # You can use at_least_one and exclusive at the same time. + # + # exclusive do + # at_least_one do + # option :one + # option :two + # end + # end + # + # Then it is required either only one of "--one" or "--two". + # + # source://thor//lib/thor.rb#246 + def at_least_one(*args, &block); end + # Extend check unknown options to accept a hash of conditions. # # === Parameters # options: A hash containing :only and/or :except keys # - # source://thor//lib/thor.rb#255 + # source://thor//lib/thor.rb#350 def check_unknown_options!(options = T.unsafe(nil)); end # Overwrite check_unknown_options? to take subcommands and options into account. # # @return [Boolean] # - # source://thor//lib/thor.rb#268 + # source://thor//lib/thor.rb#363 def check_unknown_options?(config); end # Prints help information for the given command. @@ -37,7 +102,7 @@ class Thor # shell # command_name # - # source://thor//lib/thor.rb#172 + # source://thor//lib/thor.rb#258 def command_help(shell, command_name); end # Sets the default command when thor is executed without an explicit command to be called. @@ -76,28 +141,64 @@ class Thor # ==== Parameters # Symbol ...:: A list of commands that should be affected. # - # source://thor//lib/thor.rb#339 + # source://thor//lib/thor.rb#434 def disable_required_check!(*command_names); end # @return [Boolean] # - # source://thor//lib/thor.rb#343 + # source://thor//lib/thor.rb#438 def disable_required_check?(command); end + # Adds and declares option group for exclusive options in the + # block and arguments. You can declare options as the outside of the block. + # + # If :for is given as option, it allows you to change the options from + # a previous defined command. + # + # ==== Parameters + # Array[Thor::Option.name] + # options:: :for is applied for previous defined command. + # + # ==== Examples + # + # exclusive do + # option :one + # option :two + # end + # + # Or + # + # option :one + # option :two + # exclusive :one, :two + # + # If you give "--one" and "--two" at the same time ExclusiveArgumentsError + # will be raised. + # + # source://thor//lib/thor.rb#203 + def exclusive(*args, &block); end + # Prints help information for this class. # # ==== Parameters # shell # - # source://thor//lib/thor.rb#195 + # source://thor//lib/thor.rb#288 def help(shell, subcommand = T.unsafe(nil)); end # Defines the long description of the next command. # + # Long description is by default indented, line-wrapped and repeated whitespace merged. + # In order to print long description verbatim, with indentation and spacing exactly + # as found in the code, use the +wrap+ option + # + # long_desc 'your very long description', wrap: false + # # ==== Parameters # long description + # options # - # source://thor//lib/thor.rb#71 + # source://thor//lib/thor.rb#78 def long_desc(long_description, options = T.unsafe(nil)); end # Maps an input to a command. If you define: @@ -113,9 +214,78 @@ class Thor # ==== Parameters # Hash[String|Array => Symbol]:: Maps the string or the strings in the array to the given command. # - # source://thor//lib/thor.rb#93 + # source://thor//lib/thor.rb#101 def map(mappings = T.unsafe(nil), **kw); end + # Adds and declares option group for required at least one of options in the + # block of arguments. You can declare options as the outside of the block. + # + # If :for is given as option, it allows you to change the options from + # a previous defined command. + # + # ==== Parameters + # Array[Thor::Option.name] + # options:: :for is applied for previous defined command. + # + # ==== Examples + # + # at_least_one do + # option :one + # option :two + # end + # + # Or + # + # option :one + # option :two + # at_least_one :one, :two + # + # If you do not give "--one" and "--two" AtLeastOneRequiredArgumentError + # will be raised. + # + # You can use at_least_one and exclusive at the same time. + # + # exclusive do + # at_least_one do + # option :one + # option :two + # end + # end + # + # Then it is required either only one of "--one" or "--two". + # + # source://thor//lib/thor.rb#246 + def method_at_least_one(*args, &block); end + + # Adds and declares option group for exclusive options in the + # block and arguments. You can declare options as the outside of the block. + # + # If :for is given as option, it allows you to change the options from + # a previous defined command. + # + # ==== Parameters + # Array[Thor::Option.name] + # options:: :for is applied for previous defined command. + # + # ==== Examples + # + # exclusive do + # option :one + # option :two + # end + # + # Or + # + # option :one + # option :two + # exclusive :one, :two + # + # If you give "--one" and "--two" at the same time ExclusiveArgumentsError + # will be raised. + # + # source://thor//lib/thor.rb#203 + def method_exclusive(*args, &block); end + # Adds an option to the set of method options. If :for is given as option, # it allows you to change the options from a previous defined command. # @@ -123,7 +293,7 @@ class Thor # # magic # end # - # method_option :foo => :bar, :for => :previous_command + # method_option :foo, :for => :previous_command # # def next_command # # magic @@ -142,7 +312,7 @@ class Thor # :banner - String to show on usage notes. # :hide - If you want to hide this option from the help. # - # source://thor//lib/thor.rb#155 + # source://thor//lib/thor.rb#163 def method_option(name, options = T.unsafe(nil)); end # Declares the options for the next command to be declared. @@ -152,7 +322,7 @@ class Thor # is the type of the option. Can be :string, :array, :hash, :boolean, :numeric # or :required (string). If you give a value, the type of the value is used. # - # source://thor//lib/thor.rb#121 + # source://thor//lib/thor.rb#129 def method_options(options = T.unsafe(nil)); end # Adds an option to the set of method options. If :for is given as option, @@ -162,7 +332,7 @@ class Thor # # magic # end # - # method_option :foo => :bar, :for => :previous_command + # method_option :foo, :for => :previous_command # # def next_command # # magic @@ -181,7 +351,7 @@ class Thor # :banner - String to show on usage notes. # :hide - If you want to hide this option from the help. # - # source://thor//lib/thor.rb#155 + # source://thor//lib/thor.rb#163 def option(name, options = T.unsafe(nil)); end # Declares the options for the next command to be declared. @@ -191,7 +361,7 @@ class Thor # is the type of the option. Can be :string, :array, :hash, :boolean, :numeric # or :required (string). If you give a value, the type of the value is used. # - # source://thor//lib/thor.rb#121 + # source://thor//lib/thor.rb#129 def options(options = T.unsafe(nil)); end # Allows for custom "Command" package naming. @@ -205,12 +375,12 @@ class Thor # Returns commands ready to be printed. # - # source://thor//lib/thor.rb#214 + # source://thor//lib/thor.rb#309 def printable_commands(all = T.unsafe(nil), subcommand = T.unsafe(nil)); end # Returns commands ready to be printed. # - # source://thor//lib/thor.rb#214 + # source://thor//lib/thor.rb#309 def printable_tasks(all = T.unsafe(nil), subcommand = T.unsafe(nil)); end # Registers another Thor subclass as a command. @@ -262,27 +432,27 @@ class Thor # ==== Parameters # Symbol ...:: A list of commands that should be affected. # - # source://thor//lib/thor.rb#325 + # source://thor//lib/thor.rb#420 def stop_on_unknown_option!(*command_names); end # @return [Boolean] # - # source://thor//lib/thor.rb#329 + # source://thor//lib/thor.rb#424 def stop_on_unknown_option?(command); end - # source://thor//lib/thor.rb#234 + # source://thor//lib/thor.rb#329 def subcommand(subcommand, subcommand_class); end - # source://thor//lib/thor.rb#230 + # source://thor//lib/thor.rb#325 def subcommand_classes; end - # source://thor//lib/thor.rb#225 + # source://thor//lib/thor.rb#320 def subcommands; end - # source://thor//lib/thor.rb#234 + # source://thor//lib/thor.rb#329 def subtask(subcommand, subcommand_class); end - # source://thor//lib/thor.rb#225 + # source://thor//lib/thor.rb#320 def subtasks; end # Prints help information for the given command. @@ -291,7 +461,7 @@ class Thor # shell # command_name # - # source://thor//lib/thor.rb#172 + # source://thor//lib/thor.rb#258 def task_help(shell, command_name); end protected @@ -301,50 +471,66 @@ class Thor # the command that is going to be invoked and a boolean which indicates if # the namespace should be displayed as arguments. # - # source://thor//lib/thor.rb#400 + # source://thor//lib/thor.rb#535 def banner(command, namespace = T.unsafe(nil), subcommand = T.unsafe(nil)); end - # source://thor//lib/thor.rb#406 + # source://thor//lib/thor.rb#541 def baseclass; end - # source://thor//lib/thor.rb#414 + # source://thor//lib/thor.rb#549 def create_command(meth); end - # source://thor//lib/thor.rb#414 + # source://thor//lib/thor.rb#549 def create_task(meth); end # help command has the required check disabled by default. # - # source://thor//lib/thor.rb#354 + # source://thor//lib/thor.rb#467 def disable_required_check; end # The method responsible for dispatching given the args. # # @yield [instance] # - # source://thor//lib/thor.rb#359 + # source://thor//lib/thor.rb#494 def dispatch(meth, given_args, given_opts, config); end - # source://thor//lib/thor.rb#410 + # source://thor//lib/thor.rb#545 def dynamic_command_class; end # this is the logic that takes the command name passed in by the user # and determines whether it is an unambiguous substrings of a command or # alias name. # - # source://thor//lib/thor.rb#476 + # source://thor//lib/thor.rb#615 def find_command_possibilities(meth); end # this is the logic that takes the command name passed in by the user # and determines whether it is an unambiguous substrings of a command or # alias name. # - # source://thor//lib/thor.rb#476 + # source://thor//lib/thor.rb#615 def find_task_possibilities(meth); end - # source://thor//lib/thor.rb#436 + # source://thor//lib/thor.rb#575 def initialize_added; end + # Returns this class at least one of required options array set. + # + # ==== Returns + # Array[Array[Thor::Option.name]] + # + # source://thor//lib/thor.rb#458 + def method_at_least_one_option_names; end + + # Returns this class exclusive options array set. + # + # ==== Returns + # Array[Array[Thor::Option.name]] + # + # source://thor//lib/thor.rb#449 + def method_exclusive_option_names; end + # receives a (possibly nil) command name and returns a name that is in # the commands hash. In addition to normalizing aliases, this logic # will determine if a shortened command is an unambiguous substring of @@ -355,7 +541,7 @@ class Thor # # @raise [AmbiguousTaskError] # - # source://thor//lib/thor.rb#455 + # source://thor//lib/thor.rb#594 def normalize_command_name(meth); end # receives a (possibly nil) command name and returns a name that is in @@ -368,26 +554,40 @@ class Thor # # @raise [AmbiguousTaskError] # - # source://thor//lib/thor.rb#455 + # source://thor//lib/thor.rb#594 def normalize_task_name(meth); end + # source://thor//lib/thor.rb#482 + def print_at_least_one_required_options(shell, command = T.unsafe(nil)); end + + # source://thor//lib/thor.rb#471 + def print_exclusive_options(shell, command = T.unsafe(nil)); end + # Retrieve the command name from given args. # - # source://thor//lib/thor.rb#442 + # source://thor//lib/thor.rb#581 def retrieve_command_name(args); end # Retrieve the command name from given args. # - # source://thor//lib/thor.rb#442 + # source://thor//lib/thor.rb#581 def retrieve_task_name(args); end - # source://thor//lib/thor.rb#349 + # Sort the commands, lexicographically by default. + # + # Can be overridden in the subclass to change the display order of the + # commands. + # + # source://thor//lib/thor.rb#642 + def sort_commands!(list); end + + # source://thor//lib/thor.rb#462 def stop_on_unknown_option; end - # source://thor//lib/thor.rb#491 + # source://thor//lib/thor.rb#630 def subcommand_help(cmd); end - # source://thor//lib/thor.rb#491 + # source://thor//lib/thor.rb#630 def subtask_help(cmd); end end end @@ -463,7 +663,7 @@ module Thor::Actions # 'config.gem "rspec"' # end # - # source://thor//lib/thor/actions/file_manipulation.rb#195 + # source://thor//lib/thor/actions/file_manipulation.rb#192 def append_file(path, *args, &block); end # Append text to a file. Since it depends on insert_into_file, it's reversible. @@ -481,7 +681,7 @@ module Thor::Actions # 'config.gem "rspec"' # end # - # source://thor//lib/thor/actions/file_manipulation.rb#195 + # source://thor//lib/thor/actions/file_manipulation.rb#192 def append_to_file(path, *args, &block); end # Loads an external file and execute it in the instance binding. @@ -522,7 +722,7 @@ module Thor::Actions # # chmod "script/server", 0755 # - # source://thor//lib/thor/actions/file_manipulation.rb#148 + # source://thor//lib/thor/actions/file_manipulation.rb#145 def chmod(path, mode, config = T.unsafe(nil)); end # Comment all lines matching a given regex. It will leave the space @@ -538,16 +738,25 @@ module Thor::Actions # # comment_lines 'config/initializers/session_store.rb', /cookie_store/ # - # source://thor//lib/thor/actions/file_manipulation.rb#312 + # source://thor//lib/thor/actions/file_manipulation.rb#308 def comment_lines(path, flag, *args); end + # Copies the file from the relative source to the relative destination. If + # the destination is not given it's assumed to be equal to the source. + # + # ==== Parameters + # source:: the relative path to the source root. + # destination:: the relative path to the destination root. + # config:: give :verbose => false to not log the status, and + # :mode => :preserve, to preserve the file mode from the source. + # # ==== Examples # # copy_file "README", "doc/README" # # copy_file "doc/README" # - # source://thor//lib/thor/actions/file_manipulation.rb#21 + # source://thor//lib/thor/actions/file_manipulation.rb#20 def copy_file(source, *args, &block); end # Create a new file relative to the destination root with the given data, @@ -673,17 +882,20 @@ module Thor::Actions # ==== Parameters # source:: the address of the given content. # destination:: the relative path to the destination root. - # config:: give :verbose => false to not log the status. + # config:: give :verbose => false to not log the status, and + # :http_headers => to add headers to an http request. # # ==== Examples # # get "http://gist.github.com/103208", "doc/README" # + # get "http://gist.github.com/103208", "doc/README", :http_headers => {"Content-Type" => "application/json"} + # # get "http://gist.github.com/103208" do |content| # content.split("\n").first # end # - # source://thor//lib/thor/actions/file_manipulation.rb#79 + # source://thor//lib/thor/actions/file_manipulation.rb#81 def get(source, *args, &block); end # Run a regular expression replacement on a file. @@ -703,7 +915,7 @@ module Thor::Actions # match << " no more. Use thor!" # end # - # source://thor//lib/thor/actions/file_manipulation.rb#265 + # source://thor//lib/thor/actions/file_manipulation.rb#262 def gsub_file(path, flag, *args, &block); end # Goes to the root and execute the given block. @@ -728,7 +940,7 @@ module Thor::Actions # " filter_parameter :password\n" # end # - # source://thor//lib/thor/actions/file_manipulation.rb#219 + # source://thor//lib/thor/actions/file_manipulation.rb#216 def inject_into_class(path, klass, *args, &block); end # source://thor//lib/thor/actions/inject_into_file.rb#26 @@ -751,7 +963,7 @@ module Thor::Actions # " def help; 'help'; end\n" # end # - # source://thor//lib/thor/actions/file_manipulation.rb#242 + # source://thor//lib/thor/actions/file_manipulation.rb#239 def inject_into_module(path, module_name, *args, &block); end # source://thor//lib/thor/actions/inject_into_file.rb#26 @@ -785,7 +997,7 @@ module Thor::Actions # # link_file "doc/README" # - # source://thor//lib/thor/actions/file_manipulation.rb#51 + # source://thor//lib/thor/actions/file_manipulation.rb#50 def link_file(source, *args); end # Prepend text to a file. Since it depends on insert_into_file, it's reversible. @@ -803,7 +1015,7 @@ module Thor::Actions # 'config.gem "rspec"' # end # - # source://thor//lib/thor/actions/file_manipulation.rb#173 + # source://thor//lib/thor/actions/file_manipulation.rb#170 def prepend_file(path, *args, &block); end # Prepend text to a file. Since it depends on insert_into_file, it's reversible. @@ -821,7 +1033,7 @@ module Thor::Actions # 'config.gem "rspec"' # end # - # source://thor//lib/thor/actions/file_manipulation.rb#173 + # source://thor//lib/thor/actions/file_manipulation.rb#170 def prepend_to_file(path, *args, &block); end # Returns the given path relative to the absolute root (ie, root where @@ -841,7 +1053,7 @@ module Thor::Actions # remove_file 'README' # remove_file 'app/controllers/application_controller.rb' # - # source://thor//lib/thor/actions/file_manipulation.rb#329 + # source://thor//lib/thor/actions/file_manipulation.rb#325 def remove_dir(path, config = T.unsafe(nil)); end # Removes a file at the given location. @@ -855,7 +1067,7 @@ module Thor::Actions # remove_file 'README' # remove_file 'app/controllers/application_controller.rb' # - # source://thor//lib/thor/actions/file_manipulation.rb#329 + # source://thor//lib/thor/actions/file_manipulation.rb#325 def remove_file(path, config = T.unsafe(nil)); end # Executes a command returning the contents of the command. @@ -871,7 +1083,7 @@ module Thor::Actions # run('ln -s ~/edge rails') # end # - # source://thor//lib/thor/actions.rb#249 + # source://thor//lib/thor/actions.rb#248 def run(command, config = T.unsafe(nil)); end # Executes a ruby script (taking into account WIN32 platform quirks). @@ -880,7 +1092,7 @@ module Thor::Actions # command:: the command to be executed. # config:: give :verbose => false to not log the status. # - # source://thor//lib/thor/actions.rb#286 + # source://thor//lib/thor/actions.rb#285 def run_ruby_script(command, config = T.unsafe(nil)); end # Holds source paths in instance so they can be manipulated. @@ -903,7 +1115,7 @@ module Thor::Actions # # template "doc/README" # - # source://thor//lib/thor/actions/file_manipulation.rb#115 + # source://thor//lib/thor/actions/file_manipulation.rb#117 def template(source, *args, &block); end # Run a thor command. A hash of options can be given and it's converted to @@ -924,12 +1136,11 @@ module Thor::Actions # thor :list, :all => true, :substring => 'rails' # #=> thor list --all --substring=rails # - # source://thor//lib/thor/actions.rb#309 + # source://thor//lib/thor/actions.rb#308 def thor(command, *args); end - # Uncomment all lines matching a given regex. It will leave the space - # which existed before the comment hash in tact but will remove any spacing - # between the comment hash and the beginning of the line. + # Uncomment all lines matching a given regex. Preserves indentation before + # the comment hash and removes the hash and any immediate following space. # # ==== Parameters # path:: path of the file to be changed @@ -940,40 +1151,40 @@ module Thor::Actions # # uncomment_lines 'config/initializers/session_store.rb', /active_record/ # - # source://thor//lib/thor/actions/file_manipulation.rb#293 + # source://thor//lib/thor/actions/file_manipulation.rb#289 def uncomment_lines(path, flag, *args); end protected - # source://thor//lib/thor/actions.rb#330 + # source://thor//lib/thor/actions.rb#329 def _cleanup_options_and_set(options, key); end # Allow current root to be shared between invocations. # - # source://thor//lib/thor/actions.rb#326 + # source://thor//lib/thor/actions.rb#325 def _shared_configuration; end private - # source://thor//lib/thor/actions/file_manipulation.rb#350 + # source://thor//lib/thor/actions/file_manipulation.rb#346 def capture(*args); end - # source://thor//lib/thor/actions/file_manipulation.rb#346 + # source://thor//lib/thor/actions/file_manipulation.rb#342 def concat(string); end # Returns the value of attribute output_buffer. # - # source://thor//lib/thor/actions/file_manipulation.rb#341 + # source://thor//lib/thor/actions/file_manipulation.rb#337 def output_buffer; end # Sets the attribute output_buffer # # @param value the value to set the attribute output_buffer to. # - # source://thor//lib/thor/actions/file_manipulation.rb#341 + # source://thor//lib/thor/actions/file_manipulation.rb#337 def output_buffer=(_arg0); end - # source://thor//lib/thor/actions/file_manipulation.rb#354 + # source://thor//lib/thor/actions/file_manipulation.rb#350 def with_output_buffer(buf = T.unsafe(nil)); end class << self @@ -985,9 +1196,9 @@ end # Thor::Actions#capture depends on what kind of buffer is used in ERB. # Thus CapturableERB fixes ERB to use String buffer. # -# source://thor//lib/thor/actions/file_manipulation.rb#366 +# source://thor//lib/thor/actions/file_manipulation.rb#362 class Thor::Actions::CapturableERB < ::ERB - # source://thor//lib/thor/actions/file_manipulation.rb#367 + # source://thor//lib/thor/actions/file_manipulation.rb#363 def set_eoutvar(compiler, eoutvar = T.unsafe(nil)); end end @@ -1043,12 +1254,12 @@ class Thor::Actions::CreateFile < ::Thor::Actions::EmptyDirectory # source://thor//lib/thor/actions/create_file.rb#45 def identical?; end - # source://thor//lib/thor/actions/create_file.rb#59 + # source://thor//lib/thor/actions/create_file.rb#60 def invoke!; end # Holds the content to be added to the file. # - # source://thor//lib/thor/actions/create_file.rb#51 + # source://thor//lib/thor/actions/create_file.rb#52 def render; end protected @@ -1057,19 +1268,19 @@ class Thor::Actions::CreateFile < ::Thor::Actions::EmptyDirectory # # @return [Boolean] # - # source://thor//lib/thor/actions/create_file.rb#99 + # source://thor//lib/thor/actions/create_file.rb#100 def force_on_collision?; end # If force is true, run the action, otherwise check if it's not being # skipped. If both are false, show the file_collision menu, if the menu # returns true, force it, otherwise skip. # - # source://thor//lib/thor/actions/create_file.rb#85 + # source://thor//lib/thor/actions/create_file.rb#86 def force_or_skip_or_conflict(force, skip, &block); end # Now on conflict we check if the file is identical or not. # - # source://thor//lib/thor/actions/create_file.rb#72 + # source://thor//lib/thor/actions/create_file.rb#73 def on_conflict_behavior(&block); end end @@ -1261,17 +1472,25 @@ class Thor::Actions::InjectIntoFile < ::Thor::Actions::EmptyDirectory # source://thor//lib/thor/actions/inject_into_file.rb#37 def replacement; end - # source://thor//lib/thor/actions/inject_into_file.rb#72 + # source://thor//lib/thor/actions/inject_into_file.rb#74 def revoke!; end protected + # source://thor//lib/thor/actions/inject_into_file.rb#110 + def content; end + # Adds the content to the file. # - # source://thor//lib/thor/actions/inject_into_file.rb#108 + # source://thor//lib/thor/actions/inject_into_file.rb#120 def replace!(regexp, string, force); end - # source://thor//lib/thor/actions/inject_into_file.rb#88 + # @return [Boolean] + # + # source://thor//lib/thor/actions/inject_into_file.rb#114 + def replacement_present?; end + + # source://thor//lib/thor/actions/inject_into_file.rb#90 def say_status(behavior, warning: T.unsafe(nil), color: T.unsafe(nil)); end end @@ -1297,10 +1516,10 @@ end # source://thor//lib/thor/actions/inject_into_file.rb#24 Thor::Actions::WARNINGS = T.let(T.unsafe(nil), Hash) -# source://thor//lib/thor/error.rb#68 +# source://thor//lib/thor/error.rb#57 class Thor::AmbiguousCommandError < ::Thor::Error; end -# source://thor//lib/thor/error.rb#70 +# source://thor//lib/thor/error.rb#59 Thor::AmbiguousTaskError = Thor::AmbiguousCommandError # source://thor//lib/thor/parser/argument.rb#2 @@ -1331,6 +1550,9 @@ class Thor::Argument # source://thor//lib/thor/parser/argument.rb#5 def enum; end + # source://thor//lib/thor/parser/argument.rb#52 + def enum_to_s; end + # Returns the value of attribute name. # # source://thor//lib/thor/parser/argument.rb#5 @@ -1341,6 +1563,9 @@ class Thor::Argument # source://thor//lib/thor/parser/argument.rb#5 def name; end + # source://thor//lib/thor/parser/argument.rb#27 + def print_default; end + # Returns the value of attribute required. # # source://thor//lib/thor/parser/argument.rb#5 @@ -1348,12 +1573,12 @@ class Thor::Argument # @return [Boolean] # - # source://thor//lib/thor/parser/argument.rb#31 + # source://thor//lib/thor/parser/argument.rb#39 def required?; end # @return [Boolean] # - # source://thor//lib/thor/parser/argument.rb#35 + # source://thor//lib/thor/parser/argument.rb#43 def show_default?; end # Returns the value of attribute type. @@ -1361,22 +1586,22 @@ class Thor::Argument # source://thor//lib/thor/parser/argument.rb#5 def type; end - # source://thor//lib/thor/parser/argument.rb#27 + # source://thor//lib/thor/parser/argument.rb#35 def usage; end protected - # source://thor//lib/thor/parser/argument.rb#55 + # source://thor//lib/thor/parser/argument.rb#71 def default_banner; end # @return [Boolean] # - # source://thor//lib/thor/parser/argument.rb#51 + # source://thor//lib/thor/parser/argument.rb#67 def valid_type?(type); end # @raise [ArgumentError] # - # source://thor//lib/thor/parser/argument.rb#46 + # source://thor//lib/thor/parser/argument.rb#62 def validate!; end end @@ -1392,10 +1617,10 @@ class Thor::Arguments # source://thor//lib/thor/parser/arguments.rb#26 def initialize(arguments = T.unsafe(nil)); end - # source://thor//lib/thor/parser/arguments.rb#44 + # source://thor//lib/thor/parser/arguments.rb#40 def parse(args); end - # source://thor//lib/thor/parser/arguments.rb#57 + # source://thor//lib/thor/parser/arguments.rb#53 def remaining; end private @@ -1404,22 +1629,22 @@ class Thor::Arguments # # @raise [RequiredArgumentMissingError] # - # source://thor//lib/thor/parser/arguments.rb#170 + # source://thor//lib/thor/parser/arguments.rb#186 def check_requirement!; end # @return [Boolean] # - # source://thor//lib/thor/parser/arguments.rb#88 + # source://thor//lib/thor/parser/arguments.rb#84 def current_is_value?; end # @return [Boolean] # - # source://thor//lib/thor/parser/arguments.rb#68 + # source://thor//lib/thor/parser/arguments.rb#64 def last?; end # @return [Boolean] # - # source://thor//lib/thor/parser/arguments.rb#63 + # source://thor//lib/thor/parser/arguments.rb#59 def no_or_skip?(arg); end # Runs through the argument array getting all strings until no string is @@ -1431,7 +1656,7 @@ class Thor::Arguments # # ["a", "b", "c"] # - # source://thor//lib/thor/parser/arguments.rb#122 + # source://thor//lib/thor/parser/arguments.rb#118 def parse_array(name); end # Runs through the argument array getting strings that contains ":" and @@ -1443,14 +1668,14 @@ class Thor::Arguments # # { "name" => "string", "age" => "integer" } # - # source://thor//lib/thor/parser/arguments.rb#101 + # source://thor//lib/thor/parser/arguments.rb#97 def parse_hash(name); end # Check if the peek is numeric format and return a Float or Integer. # Check if the peek is included in enum if enum is provided. # Otherwise raises an error. # - # source://thor//lib/thor/parser/arguments.rb#133 + # source://thor//lib/thor/parser/arguments.rb#139 def parse_numeric(name); end # Parse string: @@ -1458,18 +1683,23 @@ class Thor::Arguments # for --no-string-arg, nil # Check if the peek is included in enum if enum is provided. Otherwise raises an error. # - # source://thor//lib/thor/parser/arguments.rb#154 + # source://thor//lib/thor/parser/arguments.rb#158 def parse_string(name); end - # source://thor//lib/thor/parser/arguments.rb#72 + # source://thor//lib/thor/parser/arguments.rb#68 def peek; end - # source://thor//lib/thor/parser/arguments.rb#76 + # source://thor//lib/thor/parser/arguments.rb#72 def shift; end - # source://thor//lib/thor/parser/arguments.rb#80 + # source://thor//lib/thor/parser/arguments.rb#76 def unshift(arg); end + # Raises an error if the switch is an enum and the values aren't included on it. + # + # source://thor//lib/thor/parser/arguments.rb#172 + def validate_enum_value!(name, value, message); end + class << self # source://thor//lib/thor/parser/arguments.rb#19 def parse(*args); end @@ -1485,6 +1715,9 @@ end # source://thor//lib/thor/parser/arguments.rb#3 Thor::Arguments::NUMERIC = T.let(T.unsafe(nil), Regexp) +# source://thor//lib/thor/error.rb#104 +class Thor::AtLeastOneRequiredArgumentError < ::Thor::InvocationError; end + # source://thor//lib/thor/shell.rb#4 module Thor::Base include ::Thor::Invocation @@ -1549,13 +1782,13 @@ module Thor::Base def parent_options=(_arg0); end class << self - # source://thor//lib/thor/base.rb#100 + # source://thor//lib/thor/base.rb#116 def included(base); end # Whenever a class inherits from Thor or Thor::Group, we should track the # class and the file on Thor::Base. This is the method responsible for it. # - # source://thor//lib/thor/base.rb#128 + # source://thor//lib/thor/base.rb#144 def register_klass_file(klass); end # Returns the shell used in all Thor classes. If you are in a Unix platform @@ -1576,7 +1809,7 @@ module Thor::Base # ==== Returns # Hash[path => Class] # - # source://thor//lib/thor/base.rb#121 + # source://thor//lib/thor/base.rb#137 def subclass_files; end # Returns the classes that inherits from Thor or Thor::Group. @@ -1584,12 +1817,12 @@ module Thor::Base # ==== Returns # Array[Class] # - # source://thor//lib/thor/base.rb#112 + # source://thor//lib/thor/base.rb#128 def subclasses; end end end -# source://thor//lib/thor/base.rb#137 +# source://thor//lib/thor/base.rb#153 module Thor::Base::ClassMethods # Returns the commands for this Thor class and all subclasses. # @@ -1597,7 +1830,7 @@ module Thor::Base::ClassMethods # Hash:: An ordered hash with commands names as keys and Thor::Command # objects as values. # - # source://thor//lib/thor/base.rb#383 + # source://thor//lib/thor/base.rb#482 def all_commands; end # Returns the commands for this Thor class and all subclasses. @@ -1606,13 +1839,13 @@ module Thor::Base::ClassMethods # Hash:: An ordered hash with commands names as keys and Thor::Command # objects as values. # - # source://thor//lib/thor/base.rb#383 + # source://thor//lib/thor/base.rb#482 def all_tasks; end # If you want to use defaults that don't match the type of an option, # either specify `check_default_type: false` or call `allow_incompatible_default_type!` # - # source://thor//lib/thor/base.rb#173 + # source://thor//lib/thor/base.rb#189 def allow_incompatible_default_type!; end # Adds an argument to the class and creates an attr_accessor for it. @@ -1650,7 +1883,7 @@ module Thor::Base::ClassMethods # ==== Errors # ArgumentError:: Raised if you supply a required argument after a non required one. # - # source://thor//lib/thor/base.rb#245 + # source://thor//lib/thor/base.rb#261 def argument(name, options = T.unsafe(nil)); end # Returns this class arguments, looking up in the ancestors chain. @@ -1658,42 +1891,116 @@ module Thor::Base::ClassMethods # ==== Returns # Array[Thor::Argument] # - # source://thor//lib/thor/base.rb#277 + # source://thor//lib/thor/base.rb#293 def arguments; end - # source://thor//lib/thor/base.rb#146 + # source://thor//lib/thor/base.rb#162 def attr_accessor(*_arg0); end - # source://thor//lib/thor/base.rb#138 + # source://thor//lib/thor/base.rb#154 def attr_reader(*_arg0); end - # source://thor//lib/thor/base.rb#142 + # source://thor//lib/thor/base.rb#158 def attr_writer(*_arg0); end - # source://thor//lib/thor/base.rb#177 + # source://thor//lib/thor/base.rb#193 def check_default_type; end # If you want to raise an error when the default value of an option does not match # the type call check_default_type! # This will be the default; for compatibility a deprecation warning is issued if necessary. # - # source://thor//lib/thor/base.rb#167 + # source://thor//lib/thor/base.rb#183 def check_default_type!; end - # source://thor//lib/thor/base.rb#156 + # source://thor//lib/thor/base.rb#172 def check_unknown_options; end # If you want to raise an error for unknown options, call check_unknown_options! # This is disabled by default to allow dynamic invocations. # - # source://thor//lib/thor/base.rb#152 + # source://thor//lib/thor/base.rb#168 def check_unknown_options!; end # @return [Boolean] # - # source://thor//lib/thor/base.rb#160 + # source://thor//lib/thor/base.rb#176 def check_unknown_options?(config); end + # Adds and declares option group for required at least one of options in the + # block and arguments. You can declare options as the outside of the block. + # + # ==== Examples + # + # class_at_least_one do + # class_option :one + # class_option :two + # end + # + # Or + # + # class_option :one + # class_option :two + # class_at_least_one :one, :two + # + # If you do not give "--one" and "--two" AtLeastOneRequiredArgumentError + # will be raised. + # + # You can use class_at_least_one and class_exclusive at the same time. + # + # class_exclusive do + # class_at_least_one do + # class_option :one + # class_option :two + # end + # end + # + # Then it is required either only one of "--one" or "--two". + # + # source://thor//lib/thor/base.rb#392 + def class_at_least_one(*args, &block); end + + # Returns this class at least one of required options array set, looking up in the ancestors chain. + # + # ==== Returns + # Array[Array[Thor::Option.name]] + # + # source://thor//lib/thor/base.rb#411 + def class_at_least_one_option_names; end + + # Adds and declares option group for exclusive options in the + # block and arguments. You can declare options as the outside of the block. + # + # ==== Parameters + # Array[Thor::Option.name] + # + # ==== Examples + # + # class_exclusive do + # class_option :one + # class_option :two + # end + # + # Or + # + # class_option :one + # class_option :two + # class_exclusive :one, :two + # + # If you give "--one" and "--two" at the same time ExclusiveArgumentsError + # will be raised. + # + # source://thor//lib/thor/base.rb#357 + def class_exclusive(*args, &block); end + + # Returns this class exclusive options array set, looking up in the ancestors chain. + # + # ==== Returns + # Array[Array[Thor::Option.name]] + # + # source://thor//lib/thor/base.rb#402 + def class_exclusive_option_names; end + # Adds an option to the set of class options # # ==== Parameters @@ -1710,7 +2017,7 @@ module Thor::Base::ClassMethods # :banner:: -- String to show on usage notes. # :hide:: -- If you want to hide this option from the help. # - # source://thor//lib/thor/base.rb#312 + # source://thor//lib/thor/base.rb#328 def class_option(name, options = T.unsafe(nil)); end # Adds a bunch of options to the set of class options. @@ -1722,7 +2029,7 @@ module Thor::Base::ClassMethods # ==== Parameters # Hash[Symbol => Object] # - # source://thor//lib/thor/base.rb#290 + # source://thor//lib/thor/base.rb#306 def class_options(options = T.unsafe(nil)); end # Returns the commands for this Thor class. @@ -1731,7 +2038,7 @@ module Thor::Base::ClassMethods # Hash:: An ordered hash with commands names as keys and Thor::Command # objects as values. # - # source://thor//lib/thor/base.rb#372 + # source://thor//lib/thor/base.rb#471 def commands; end # If true, option set will not suspend the execution of the command when @@ -1739,14 +2046,14 @@ module Thor::Base::ClassMethods # # @return [Boolean] # - # source://thor//lib/thor/base.rb#191 + # source://thor//lib/thor/base.rb#207 def disable_required_check?(command_name); end # A flag that makes the process exit with status 1 if any error happens. # # @return [Boolean] # - # source://thor//lib/thor/base.rb#529 + # source://thor//lib/thor/base.rb#628 def exit_on_failure?; end # Defines the group. This is used when thor list is invoked so you can specify @@ -1755,22 +2062,22 @@ module Thor::Base::ClassMethods # ==== Parameters # name # - # source://thor//lib/thor/base.rb#358 + # source://thor//lib/thor/base.rb#457 def group(name = T.unsafe(nil)); end # @raise [InvocationError] # - # source://thor//lib/thor/base.rb#519 + # source://thor//lib/thor/base.rb#618 def handle_argument_error(command, error, args, arity); end # @raise [UndefinedCommandError] # - # source://thor//lib/thor/base.rb#514 + # source://thor//lib/thor/base.rb#613 def handle_no_command_error(command, has_namespace = T.unsafe(nil)); end # @raise [UndefinedCommandError] # - # source://thor//lib/thor/base.rb#514 + # source://thor//lib/thor/base.rb#613 def handle_no_task_error(command, has_namespace = T.unsafe(nil)); end # Sets the namespace for the Thor or Thor::Group class. By default the @@ -1795,7 +2102,7 @@ module Thor::Base::ClassMethods # # thor :my_command # - # source://thor//lib/thor/base.rb#467 + # source://thor//lib/thor/base.rb#566 def namespace(name = T.unsafe(nil)); end # All methods defined inside the given block are not added as commands. @@ -1817,15 +2124,15 @@ module Thor::Base::ClassMethods # remove_command :this_is_not_a_command # end # - # source://thor//lib/thor/base.rb#431 + # source://thor//lib/thor/base.rb#530 def no_commands(&block); end # @return [Boolean] # - # source://thor//lib/thor/base.rb#441 + # source://thor//lib/thor/base.rb#540 def no_commands?; end - # source://thor//lib/thor/base.rb#437 + # source://thor//lib/thor/base.rb#536 def no_commands_context; end # All methods defined inside the given block are not added as commands. @@ -1847,7 +2154,7 @@ module Thor::Base::ClassMethods # remove_command :this_is_not_a_command # end # - # source://thor//lib/thor/base.rb#431 + # source://thor//lib/thor/base.rb#530 def no_tasks(&block); end # Allows to use private methods from parent in child classes as commands. @@ -1860,7 +2167,7 @@ module Thor::Base::ClassMethods # public_command :foo # public_command :foo, :bar, :baz # - # source://thor//lib/thor/base.rb#507 + # source://thor//lib/thor/base.rb#606 def public_command(*names); end # Allows to use private methods from parent in child classes as commands. @@ -1873,7 +2180,7 @@ module Thor::Base::ClassMethods # public_command :foo # public_command :foo, :bar, :baz # - # source://thor//lib/thor/base.rb#507 + # source://thor//lib/thor/base.rb#606 def public_task(*names); end # Removes a previous defined argument. If :undefine is given, undefine @@ -1887,7 +2194,7 @@ module Thor::Base::ClassMethods # remove_argument :foo # remove_argument :foo, :bar, :baz, :undefine => true # - # source://thor//lib/thor/base.rb#327 + # source://thor//lib/thor/base.rb#426 def remove_argument(*names); end # Removes a previous defined class option. @@ -1900,7 +2207,7 @@ module Thor::Base::ClassMethods # remove_class_option :foo # remove_class_option :foo, :bar, :baz # - # source://thor//lib/thor/base.rb#346 + # source://thor//lib/thor/base.rb#445 def remove_class_option(*names); end # Removes a given command from this Thor class. This is usually done if you @@ -1915,7 +2222,7 @@ module Thor::Base::ClassMethods # options:: You can give :undefine => true if you want commands the method # to be undefined from the class as well. # - # source://thor//lib/thor/base.rb#401 + # source://thor//lib/thor/base.rb#500 def remove_command(*names); end # Removes a given command from this Thor class. This is usually done if you @@ -1930,7 +2237,7 @@ module Thor::Base::ClassMethods # options:: You can give :undefine => true if you want commands the method # to be undefined from the class as well. # - # source://thor//lib/thor/base.rb#401 + # source://thor//lib/thor/base.rb#500 def remove_task(*names); end # Parses the command and options from the given args, instantiate the class @@ -1941,7 +2248,7 @@ module Thor::Base::ClassMethods # script = MyScript.new(args, options, config) # script.invoke(:command, first_arg, second_arg, third_arg) # - # source://thor//lib/thor/base.rb#483 + # source://thor//lib/thor/base.rb#582 def start(given_args = T.unsafe(nil), config = T.unsafe(nil)); end # If true, option parsing is suspended as soon as an unknown option or a @@ -1950,22 +2257,22 @@ module Thor::Base::ClassMethods # # @return [Boolean] # - # source://thor//lib/thor/base.rb#185 + # source://thor//lib/thor/base.rb#201 def stop_on_unknown_option?(command_name); end - # source://thor//lib/thor/base.rb#202 + # source://thor//lib/thor/base.rb#218 def strict_args_position; end # If you want only strict string args (useful when cascading thor classes), # call strict_args_position! This is disabled by default to allow dynamic # invocations. # - # source://thor//lib/thor/base.rb#198 + # source://thor//lib/thor/base.rb#214 def strict_args_position!; end # @return [Boolean] # - # source://thor//lib/thor/base.rb#206 + # source://thor//lib/thor/base.rb#222 def strict_args_position?(config); end # Returns the commands for this Thor class. @@ -1974,7 +2281,7 @@ module Thor::Base::ClassMethods # Hash:: An ordered hash with commands names as keys and Thor::Command # objects as values. # - # source://thor//lib/thor/base.rb#372 + # source://thor//lib/thor/base.rb#471 def tasks; end protected @@ -1982,12 +2289,12 @@ module Thor::Base::ClassMethods # SIGNATURE: Sets the baseclass. This is where the superclass lookup # finishes. # - # source://thor//lib/thor/base.rb#678 + # source://thor//lib/thor/base.rb#777 def baseclass; end # The basename of the program invoking the thor class. # - # source://thor//lib/thor/base.rb#672 + # source://thor//lib/thor/base.rb#771 def basename; end # Build an option and adds it to the given scope. @@ -1997,7 +2304,7 @@ module Thor::Base::ClassMethods # options:: Described in both class_option and method_option. # scope:: Options hash that is being built up # - # source://thor//lib/thor/base.rb#589 + # source://thor//lib/thor/base.rb#688 def build_option(name, options, scope); end # Receives a hash of options, parse them and add to the scope. This is a @@ -2008,83 +2315,100 @@ module Thor::Base::ClassMethods # ==== Parameters # Hash[Symbol => Object] # - # source://thor//lib/thor/base.rb#600 + # source://thor//lib/thor/base.rb#699 def build_options(options, scope); end + # Get target(method_options or class_options) options + # of before and after by block evaluation. + # + # source://thor//lib/thor/base.rb#808 + def built_option_names(target, opt = T.unsafe(nil), &block); end + # Prints the class options per group. If an option does not belong to # any group, it's printed as Class option. # - # source://thor//lib/thor/base.rb#539 + # source://thor//lib/thor/base.rb#638 def class_options_help(shell, groups = T.unsafe(nil)); end + # Get command scope member by name. + # + # source://thor//lib/thor/base.rb#816 + def command_scope_member(name, options = T.unsafe(nil)); end + # SIGNATURE: Creates a new command if valid_command? is true. This method is # called when a new method is added to the class. # - # source://thor//lib/thor/base.rb#683 + # source://thor//lib/thor/base.rb#782 def create_command(meth); end # SIGNATURE: Creates a new command if valid_command? is true. This method is # called when a new method is added to the class. # - # source://thor//lib/thor/base.rb#683 + # source://thor//lib/thor/base.rb#782 def create_task(meth); end # SIGNATURE: The hook invoked by start. # # @raise [NotImplementedError] # - # source://thor//lib/thor/base.rb#693 + # source://thor//lib/thor/base.rb#792 def dispatch(command, given_args, given_opts, config); end # Finds a command with the given name. If the command belongs to the current # class, just return it, otherwise dup it and add the fresh copy to the # current command hash. # - # source://thor//lib/thor/base.rb#609 + # source://thor//lib/thor/base.rb#708 def find_and_refresh_command(name); end # Finds a command with the given name. If the command belongs to the current # class, just return it, otherwise dup it and add the fresh copy to the # current command hash. # - # source://thor//lib/thor/base.rb#609 + # source://thor//lib/thor/base.rb#708 def find_and_refresh_task(name); end # Retrieves a value from superclass. If it reaches the baseclass, # returns default. # - # source://thor//lib/thor/base.rb#650 + # source://thor//lib/thor/base.rb#749 def from_superclass(method, default = T.unsafe(nil)); end # Every time someone inherits from a Thor class, register the klass # and file into baseclass. # - # source://thor//lib/thor/base.rb#622 + # source://thor//lib/thor/base.rb#721 def inherited(klass); end # SIGNATURE: Defines behavior when the initialize method is added to the # class. # - # source://thor//lib/thor/base.rb#689 + # source://thor//lib/thor/base.rb#788 def initialize_added; end # Raises an error if the word given is a Thor reserved word. # # @return [Boolean] # - # source://thor//lib/thor/base.rb#578 + # source://thor//lib/thor/base.rb#677 def is_thor_reserved_word?(word, type); end # Fire this callback whenever a method is added. Added methods are # tracked as commands by invoking the create_command method. # - # source://thor//lib/thor/base.rb#630 + # source://thor//lib/thor/base.rb#729 def method_added(meth); end # Receives a set of options and print them. # - # source://thor//lib/thor/base.rb#557 + # source://thor//lib/thor/base.rb#656 def print_options(shell, options, group_name = T.unsafe(nil)); end + + # Register a relation of options for target(method_option/class_option) + # by args and block. + # + # source://thor//lib/thor/base.rb#798 + def register_options_relation_for(target, relation, *args, &block); end end # source://thor//lib/thor/command.rb#2 @@ -2092,68 +2416,74 @@ class Thor::Command < ::Struct # @return [Command] a new instance of Command # # source://thor//lib/thor/command.rb#5 - def initialize(name, description, long_description, usage, options = T.unsafe(nil)); end + def initialize(name, description, long_description, wrap_long_description, usage, options = T.unsafe(nil), options_relation = T.unsafe(nil)); end # Returns the formatted usage by injecting given required arguments # and required options into the given usage. # - # source://thor//lib/thor/command.rb#41 + # source://thor//lib/thor/command.rb#42 def formatted_usage(klass, namespace = T.unsafe(nil), subcommand = T.unsafe(nil)); end # @return [Boolean] # - # source://thor//lib/thor/command.rb#14 + # source://thor//lib/thor/command.rb#15 def hidden?; end + # source://thor//lib/thor/command.rb#70 + def method_at_least_one_option_names; end + + # source://thor//lib/thor/command.rb#66 + def method_exclusive_option_names; end + # By default, a command invokes a method in the thor class. You can change this # implementation to create custom commands. # - # source://thor//lib/thor/command.rb#20 + # source://thor//lib/thor/command.rb#21 def run(instance, args = T.unsafe(nil)); end protected # @return [Boolean] # - # source://thor//lib/thor/command.rb#105 + # source://thor//lib/thor/command.rb#114 def handle_argument_error?(instance, error, caller); end # @return [Boolean] # - # source://thor//lib/thor/command.rb#112 + # source://thor//lib/thor/command.rb#121 def handle_no_method_error?(instance, error, caller); end # @return [Boolean] # - # source://thor//lib/thor/command.rb#95 + # source://thor//lib/thor/command.rb#104 def local_method?(instance, name); end # @return [Boolean] # - # source://thor//lib/thor/command.rb#78 + # source://thor//lib/thor/command.rb#87 def not_debugging?(instance); end # @return [Boolean] # - # source://thor//lib/thor/command.rb#91 + # source://thor//lib/thor/command.rb#100 def private_method?(instance); end # Given a target, checks if this class name is a public method. # # @return [Boolean] # - # source://thor//lib/thor/command.rb#87 + # source://thor//lib/thor/command.rb#96 def public_method?(instance); end # Add usage with required arguments # - # source://thor//lib/thor/command.rb#68 + # source://thor//lib/thor/command.rb#77 def required_arguments_for(klass, usage); end - # source://thor//lib/thor/command.rb#82 + # source://thor//lib/thor/command.rb#91 def required_options; end - # source://thor//lib/thor/command.rb#100 + # source://thor//lib/thor/command.rb#109 def sans_backtrace(backtrace, caller); end private @@ -2200,35 +2530,38 @@ class Thor::CoreExt::HashWithIndifferentAccess < ::Hash # @return [Boolean] # - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#41 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#45 def key?(key); end - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#49 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#53 def merge(other); end - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#53 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#57 def merge!(other); end - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#68 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#72 def replace(other_hash); end - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#60 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#64 def reverse_merge(other); end - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#64 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#68 def reverse_merge!(other_hash); end + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#41 + def slice(*keys); end + # Convert to a Hash with String keys. # - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#73 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#77 def to_hash; end - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#45 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#49 def values_at(*indices); end protected - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#79 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#83 def convert_key(key); end # Magic predicates. For instance: @@ -2237,33 +2570,33 @@ class Thor::CoreExt::HashWithIndifferentAccess < ::Hash # options.shebang # => "/usr/lib/local/ruby" # options.test_framework?(:rspec) # => options[:test_framework] == :rspec # - # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#89 + # source://thor//lib/thor/core_ext/hash_with_indifferent_access.rb#93 def method_missing(method, *args); end end -# source://thor//lib/thor/error.rb#14 +# source://thor//lib/thor/error.rb#3 module Thor::Correctable - # source://thor//lib/thor/error.rb#19 + # source://thor//lib/thor/error.rb#8 def corrections; end - # source://thor//lib/thor/error.rb#15 + # source://thor//lib/thor/error.rb#4 def to_s; end end # A dynamic command that handles method missing scenarios. # -# source://thor//lib/thor/command.rb#128 +# source://thor//lib/thor/command.rb#137 class Thor::DynamicCommand < ::Thor::Command # @return [DynamicCommand] a new instance of DynamicCommand # - # source://thor//lib/thor/command.rb#129 + # source://thor//lib/thor/command.rb#138 def initialize(name, options = T.unsafe(nil)); end - # source://thor//lib/thor/command.rb#133 + # source://thor//lib/thor/command.rb#142 def run(instance, args = T.unsafe(nil)); end end -# source://thor//lib/thor/command.rb#141 +# source://thor//lib/thor/command.rb#150 Thor::DynamicTask = Thor::DynamicCommand # Thor::Error is raised when it's caused by wrong usage of thor classes. Those @@ -2273,9 +2606,12 @@ Thor::DynamicTask = Thor::DynamicCommand # overwrites a thor keyword, SHOULD NOT raise a Thor::Error. This way, we # ensure that developer errors are shown with full backtrace. # -# source://thor//lib/thor/error.rb#31 +# source://thor//lib/thor/error.rb#20 class Thor::Error < ::StandardError; end +# source://thor//lib/thor/error.rb#101 +class Thor::ExclusiveArgumentError < ::Thor::InvocationError; end + # Thor has a special class called Thor::Group. The main difference to Thor class # is that it invokes all commands at once. It also include some methods that allows # invocations to be done at the class method, which are not available to Thor @@ -2449,15 +2785,15 @@ Thor::HELP_MAPPINGS = T.let(T.unsafe(nil), Array) # A command that is hidden in help messages but still invocable. # -# source://thor//lib/thor/command.rb#120 +# source://thor//lib/thor/command.rb#129 class Thor::HiddenCommand < ::Thor::Command # @return [Boolean] # - # source://thor//lib/thor/command.rb#121 + # source://thor//lib/thor/command.rb#130 def hidden?; end end -# source://thor//lib/thor/command.rb#125 +# source://thor//lib/thor/command.rb#134 Thor::HiddenTask = Thor::HiddenCommand # source://thor//lib/thor/invocation.rb#2 @@ -2611,7 +2947,7 @@ end # Raised when a command was found, but not invoked properly. # -# source://thor//lib/thor/error.rb#73 +# source://thor//lib/thor/error.rb#62 class Thor::InvocationError < ::Thor::Error; end # source://thor//lib/thor/line_editor/basic.rb#2 @@ -2724,7 +3060,7 @@ class Thor::LineEditor::Readline::PathCompletion def text; end end -# source://thor//lib/thor/error.rb#109 +# source://thor//lib/thor/error.rb#98 class Thor::MalformattedArgumentError < ::Thor::InvocationError; end # source://thor//lib/thor/nested_context.rb#2 @@ -2751,12 +3087,6 @@ class Thor::NestedContext def push; end end -# source://thor//lib/thor/error.rb#8 -class Thor::NoKwargSpellChecker < ::DidYouMean::SpellChecker - # source://thor//lib/thor/error.rb#9 - def initialize(dictionary); end -end - # source://thor//lib/thor/parser/option.rb#2 class Thor::Option < ::Thor::Argument # @return [Option] a new instance of Option @@ -2772,10 +3102,10 @@ class Thor::Option < ::Thor::Argument # source://thor//lib/thor/parser/option.rb#99 def aliases_for_usage; end - # source://thor//lib/thor/parser/option.rb#109 + # source://thor//lib/thor/parser/option.rb#118 def array?; end - # source://thor//lib/thor/parser/option.rb#109 + # source://thor//lib/thor/parser/option.rb#118 def boolean?; end # Returns the value of attribute group. @@ -2783,7 +3113,7 @@ class Thor::Option < ::Thor::Argument # source://thor//lib/thor/parser/option.rb#3 def group; end - # source://thor//lib/thor/parser/option.rb#109 + # source://thor//lib/thor/parser/option.rb#118 def hash?; end # Returns the value of attribute hide. @@ -2799,7 +3129,7 @@ class Thor::Option < ::Thor::Argument # source://thor//lib/thor/parser/option.rb#3 def lazy_default; end - # source://thor//lib/thor/parser/option.rb#109 + # source://thor//lib/thor/parser/option.rb#118 def numeric?; end # Returns the value of attribute repeatable. @@ -2807,7 +3137,12 @@ class Thor::Option < ::Thor::Argument # source://thor//lib/thor/parser/option.rb#3 def repeatable; end - # source://thor//lib/thor/parser/option.rb#109 + # @return [Boolean] + # + # source://thor//lib/thor/parser/option.rb#107 + def show_default?; end + + # source://thor//lib/thor/parser/option.rb#118 def string?; end # source://thor//lib/thor/parser/option.rb#75 @@ -2818,25 +3153,30 @@ class Thor::Option < ::Thor::Argument protected - # source://thor//lib/thor/parser/option.rb#159 + # source://thor//lib/thor/parser/option.rb#168 def dasherize(str); end # @return [Boolean] # - # source://thor//lib/thor/parser/option.rb#151 + # source://thor//lib/thor/parser/option.rb#160 def dasherized?; end - # source://thor//lib/thor/parser/option.rb#155 + # source://thor//lib/thor/parser/option.rb#164 def undasherize(str); end # @raise [ArgumentError] # - # source://thor//lib/thor/parser/option.rb#117 + # source://thor//lib/thor/parser/option.rb#126 def validate!; end - # source://thor//lib/thor/parser/option.rb#122 + # source://thor//lib/thor/parser/option.rb#131 def validate_default_type!; end + private + + # source://thor//lib/thor/parser/option.rb#174 + def normalize_aliases(aliases); end + class << self # This parse quick options given as method_options. It makes several # assumptions, but you can be more specific using the option method. @@ -2883,31 +3223,37 @@ class Thor::Options < ::Thor::Arguments # @return [Options] a new instance of Options # # source://thor//lib/thor/parser/options.rb#32 - def initialize(hash_options = T.unsafe(nil), defaults = T.unsafe(nil), stop_on_unknown = T.unsafe(nil), disable_required_check = T.unsafe(nil)); end + def initialize(hash_options = T.unsafe(nil), defaults = T.unsafe(nil), stop_on_unknown = T.unsafe(nil), disable_required_check = T.unsafe(nil), relations = T.unsafe(nil)); end + + # source://thor//lib/thor/parser/options.rb#156 + def check_at_least_one!; end + + # source://thor//lib/thor/parser/options.rb#144 + def check_exclusive!; end # @raise [UnknownArgumentError] # - # source://thor//lib/thor/parser/options.rb#141 + # source://thor//lib/thor/parser/options.rb#168 def check_unknown!; end - # source://thor//lib/thor/parser/options.rb#88 + # source://thor//lib/thor/parser/options.rb#89 def parse(args); end - # source://thor//lib/thor/parser/options.rb#64 + # source://thor//lib/thor/parser/options.rb#65 def peek; end - # source://thor//lib/thor/parser/options.rb#60 + # source://thor//lib/thor/parser/options.rb#61 def remaining; end - # source://thor//lib/thor/parser/options.rb#78 + # source://thor//lib/thor/parser/options.rb#79 def shift; end - # source://thor//lib/thor/parser/options.rb#83 + # source://thor//lib/thor/parser/options.rb#84 def unshift(arg, is_value: T.unsafe(nil)); end protected - # source://thor//lib/thor/parser/options.rb#151 + # source://thor//lib/thor/parser/options.rb#189 def assign_result!(option, result); end # Check if the current value in peek is a registered switch. @@ -2917,45 +3263,51 @@ class Thor::Options < ::Thor::Arguments # # @return [Boolean] # - # source://thor//lib/thor/parser/options.rb#165 + # source://thor//lib/thor/parser/options.rb#203 def current_is_switch?; end # @return [Boolean] # - # source://thor//lib/thor/parser/options.rb#177 + # source://thor//lib/thor/parser/options.rb#215 def current_is_switch_formatted?; end # @return [Boolean] # - # source://thor//lib/thor/parser/options.rb#187 + # source://thor//lib/thor/parser/options.rb#225 def current_is_value?; end + # Option names changes to swith name or human name + # + # source://thor//lib/thor/parser/options.rb#179 + def names_to_switch_names(names = T.unsafe(nil)); end + # Check if the given argument is actually a shortcut. # - # source://thor//lib/thor/parser/options.rb#206 + # source://thor//lib/thor/parser/options.rb#244 def normalize_switch(arg); end - # Parse boolean values which can be given as --foo=true, --foo or --no-foo. + # Parse boolean values which can be given as --foo=true or --foo for true values, or + # --foo=false, --no-foo or --skip-foo for false values. # - # source://thor//lib/thor/parser/options.rb#217 + # source://thor//lib/thor/parser/options.rb#256 def parse_boolean(switch); end # Parse the value at the peek analyzing if it requires an input or not. # - # source://thor//lib/thor/parser/options.rb#235 + # source://thor//lib/thor/parser/options.rb#274 def parse_peek(switch, option); end # @return [Boolean] # - # source://thor//lib/thor/parser/options.rb#210 + # source://thor//lib/thor/parser/options.rb#248 def parsing_options?; end # @return [Boolean] # - # source://thor//lib/thor/parser/options.rb#192 + # source://thor//lib/thor/parser/options.rb#230 def switch?(arg); end - # source://thor//lib/thor/parser/options.rb#196 + # source://thor//lib/thor/parser/options.rb#234 def switch_option(arg); end class << self @@ -3019,7 +3371,7 @@ module Thor::RakeCompat end end -# source://thor//lib/thor/error.rb#106 +# source://thor//lib/thor/error.rb#95 class Thor::RequiredArgumentMissingError < ::Thor::InvocationError; end # source://thor//lib/thor/util.rb#4 @@ -3108,13 +3460,13 @@ module Thor::Shell def _shared_configuration; end end -# source://thor//lib/thor/shell/basic.rb#3 +# source://thor//lib/thor/shell/basic.rb#7 class Thor::Shell::Basic # Initialize base, mute and padding to nil. # # @return [Basic] a new instance of Basic # - # source://thor//lib/thor/shell/basic.rb#11 + # source://thor//lib/thor/shell/basic.rb#13 def initialize; end # Asks something to the user and receives a response. @@ -3137,29 +3489,29 @@ class Thor::Shell::Basic # Readline. # # ==== Example - # ask("What is your name?") + # ask("What is your name?") # - # ask("What is the planet furthest from the sun?", :default => "Pluto") + # ask("What is the planet furthest from the sun?", :default => "Neptune") # - # ask("What is your favorite Neopolitan flavor?", :limited_to => ["strawberry", "chocolate", "vanilla"]) + # ask("What is your favorite Neopolitan flavor?", :limited_to => ["strawberry", "chocolate", "vanilla"]) # - # ask("What is your password?", :echo => false) + # ask("What is your password?", :echo => false) # - # ask("Where should the file be saved?", :path => true) + # ask("Where should the file be saved?", :path => true) # - # source://thor//lib/thor/shell/basic.rb#78 + # source://thor//lib/thor/shell/basic.rb#80 def ask(statement, *args); end # Returns the value of attribute base. # - # source://thor//lib/thor/shell/basic.rb#6 + # source://thor//lib/thor/shell/basic.rb#8 def base; end # Sets the attribute base # # @param value the value to set the attribute base to. # - # source://thor//lib/thor/shell/basic.rb#6 + # source://thor//lib/thor/shell/basic.rb#8 def base=(_arg0); end # Called if something goes wrong during the execution. This is used by Thor @@ -3167,7 +3519,7 @@ class Thor::Shell::Basic # wrong, you can always raise an exception. If you raise a Thor::Error, it # will be rescued and wrapped in the method below. # - # source://thor//lib/thor/shell/basic.rb#342 + # source://thor//lib/thor/shell/basic.rb#251 def error(statement); end # Deals with file collision and returns true if the file should be @@ -3178,42 +3530,42 @@ class Thor::Shell::Basic # destination:: the destination file to solve conflicts # block:: an optional block that returns the value to be used in diff and merge # - # source://thor//lib/thor/shell/basic.rb#285 + # source://thor//lib/thor/shell/basic.rb#207 def file_collision(destination); end # Sets the output padding while executing a block and resets it. # - # source://thor//lib/thor/shell/basic.rb#41 + # source://thor//lib/thor/shell/basic.rb#43 def indent(count = T.unsafe(nil)); end # Mute everything that's inside given block # - # source://thor//lib/thor/shell/basic.rb#20 + # source://thor//lib/thor/shell/basic.rb#22 def mute; end # Check if base is muted # # @return [Boolean] # - # source://thor//lib/thor/shell/basic.rb#29 + # source://thor//lib/thor/shell/basic.rb#31 def mute?; end - # Make a question the to user and returns true if the user replies "n" or + # Asks the user a question and returns true if the user replies "n" or # "no". # # @return [Boolean] # - # source://thor//lib/thor/shell/basic.rb#154 + # source://thor//lib/thor/shell/basic.rb#156 def no?(statement, color = T.unsafe(nil)); end # Returns the value of attribute padding. # - # source://thor//lib/thor/shell/basic.rb#7 + # source://thor//lib/thor/shell/basic.rb#9 def padding; end # Sets the output padding, not allowing less than zero values. # - # source://thor//lib/thor/shell/basic.rb#35 + # source://thor//lib/thor/shell/basic.rb#37 def padding=(value); end # Prints values in columns @@ -3221,7 +3573,7 @@ class Thor::Shell::Basic # ==== Parameters # Array[String, String, ...] # - # source://thor//lib/thor/shell/basic.rb#163 + # source://thor//lib/thor/shell/basic.rb#165 def print_in_columns(array); end # Prints a table. @@ -3232,8 +3584,9 @@ class Thor::Shell::Basic # ==== Options # indent:: Indent the first column by indent value. # colwidth:: Force the first column to colwidth spaces wide. + # borders:: Adds ascii borders. # - # source://thor//lib/thor/shell/basic.rb#185 + # source://thor//lib/thor/shell/basic.rb#180 def print_table(array, options = T.unsafe(nil)); end # Prints a long string, word-wrapping the text to the current width of the @@ -3245,7 +3598,7 @@ class Thor::Shell::Basic # ==== Options # indent:: Indent each line of the printed paragraph by indent value. # - # source://thor//lib/thor/shell/basic.rb#247 + # source://thor//lib/thor/shell/basic.rb#194 def print_wrapped(message, options = T.unsafe(nil)); end # Say (print) something to the user. If the sentence ends with a whitespace @@ -3253,9 +3606,9 @@ class Thor::Shell::Basic # are passed straight to puts (behavior got from Highline). # # ==== Example - # say("I know you knew that.") + # say("I know you knew that.") # - # source://thor//lib/thor/shell/basic.rb#96 + # source://thor//lib/thor/shell/basic.rb#98 def say(message = T.unsafe(nil), color = T.unsafe(nil), force_new_line = T.unsafe(nil)); end # Say (print) an error to the user. If the sentence ends with a whitespace @@ -3263,9 +3616,9 @@ class Thor::Shell::Basic # are passed straight to puts (behavior got from Highline). # # ==== Example - # say_error("error: something went wrong") + # say_error("error: something went wrong") # - # source://thor//lib/thor/shell/basic.rb#113 + # source://thor//lib/thor/shell/basic.rb#115 def say_error(message = T.unsafe(nil), color = T.unsafe(nil), force_new_line = T.unsafe(nil)); end # Say a status with the given color and appends the message. Since this @@ -3273,110 +3626,89 @@ class Thor::Shell::Basic # in log_status, avoiding the message from being shown. If a Symbol is # given in log_status, it's used as the color. # - # source://thor//lib/thor/shell/basic.rb#128 + # source://thor//lib/thor/shell/basic.rb#130 def say_status(status, message, log_status = T.unsafe(nil)); end # Apply color to the given string with optional bold. Disabled in the # Thor::Shell::Basic class. # - # source://thor//lib/thor/shell/basic.rb#349 + # source://thor//lib/thor/shell/basic.rb#258 def set_color(string, *_arg1); end - # source://thor//lib/thor/shell/basic.rb#326 - def terminal_width; end - - # Make a question the to user and returns true if the user replies "y" or + # Asks the user a question and returns true if the user replies "y" or # "yes". # # @return [Boolean] # - # source://thor//lib/thor/shell/basic.rb#147 + # source://thor//lib/thor/shell/basic.rb#149 def yes?(statement, color = T.unsafe(nil)); end protected - # source://thor//lib/thor/shell/basic.rb#486 + # source://thor//lib/thor/shell/basic.rb#362 def answer_match(possibilities, answer, case_insensitive); end - # source://thor//lib/thor/shell/basic.rb#443 - def as_unicode; end - - # source://thor//lib/thor/shell/basic.rb#473 + # source://thor//lib/thor/shell/basic.rb#349 def ask_filtered(statement, color, options); end - # source://thor//lib/thor/shell/basic.rb#456 + # source://thor//lib/thor/shell/basic.rb#332 def ask_simply(statement, color, options); end # @return [Boolean] # - # source://thor//lib/thor/shell/basic.rb#360 + # source://thor//lib/thor/shell/basic.rb#269 def can_display_colors?; end - # Calculate the dynamic width of the terminal - # - # source://thor//lib/thor/shell/basic.rb#415 - def dynamic_width; end - - # source://thor//lib/thor/shell/basic.rb#419 - def dynamic_width_stty; end + # source://thor//lib/thor/shell/basic.rb#296 + def file_collision_help(block_given); end - # source://thor//lib/thor/shell/basic.rb#423 - def dynamic_width_tput; end - - # source://thor//lib/thor/shell/basic.rb#387 - def file_collision_help; end - - # source://thor//lib/thor/shell/basic.rb#507 + # source://thor//lib/thor/shell/basic.rb#383 def git_merge_tool; end # @return [Boolean] # - # source://thor//lib/thor/shell/basic.rb#377 + # source://thor//lib/thor/shell/basic.rb#286 def is?(value); end - # source://thor//lib/thor/shell/basic.rb#364 + # source://thor//lib/thor/shell/basic.rb#273 def lookup_color(color); end - # source://thor//lib/thor/shell/basic.rb#494 + # source://thor//lib/thor/shell/basic.rb#370 def merge(destination, content); end - # source://thor//lib/thor/shell/basic.rb#503 + # source://thor//lib/thor/shell/basic.rb#379 def merge_tool; end - # source://thor//lib/thor/shell/basic.rb#355 + # source://thor//lib/thor/shell/basic.rb#264 def prepare_message(message, *color); end # @return [Boolean] # - # source://thor//lib/thor/shell/basic.rb#410 + # source://thor//lib/thor/shell/basic.rb#324 def quiet?; end - # source://thor//lib/thor/shell/basic.rb#399 + # source://thor//lib/thor/shell/basic.rb#313 def show_diff(destination, content); end - # source://thor//lib/thor/shell/basic.rb#373 + # source://thor//lib/thor/shell/basic.rb#282 def stderr; end - # source://thor//lib/thor/shell/basic.rb#369 + # source://thor//lib/thor/shell/basic.rb#278 def stdout; end - # source://thor//lib/thor/shell/basic.rb#431 - def truncate(string, width); end - # @return [Boolean] # - # source://thor//lib/thor/shell/basic.rb#427 + # source://thor//lib/thor/shell/basic.rb#328 def unix?; end end -# source://thor//lib/thor/shell/basic.rb#4 -Thor::Shell::Basic::DEFAULT_TERMINAL_WIDTH = T.let(T.unsafe(nil), Integer) - # Inherit from Thor::Shell::Basic and add set_color behavior. Check # Thor::Shell::Basic to see all available methods. # -# source://thor//lib/thor/shell/color.rb#8 +# source://thor//lib/thor/shell/color.rb#9 class Thor::Shell::Color < ::Thor::Shell::Basic + include ::LCSDiff + # Set color by using a string or one of the defined constants. If a third # option is set to true, it also adds bold to the string. This is based # on Highline implementation and it automatically appends CLEAR to the end @@ -3409,149 +3741,155 @@ class Thor::Shell::Color < ::Thor::Shell::Basic # :on_cyan # :on_white # - # source://thor//lib/thor/shell/color.rb#79 + # source://thor//lib/thor/shell/color.rb#82 def set_color(string, *colors); end protected # @return [Boolean] # - # source://thor//lib/thor/shell/color.rb#107 + # source://thor//lib/thor/shell/color.rb#110 def are_colors_disabled?; end # @return [Boolean] # - # source://thor//lib/thor/shell/color.rb#103 + # source://thor//lib/thor/shell/color.rb#106 def are_colors_supported?; end # @return [Boolean] # - # source://thor//lib/thor/shell/color.rb#99 + # source://thor//lib/thor/shell/color.rb#102 def can_display_colors?; end - - # Check if Diff::LCS is loaded. If it is, use it to create pretty output - # for diff. - # - # @return [Boolean] - # - # source://thor//lib/thor/shell/color.rb#144 - def diff_lcs_loaded?; end - - # source://thor//lib/thor/shell/color.rb#127 - def output_diff_line(diff); end - - # Overwrite show_diff to show diff with colors if Diff::LCS is - # available. - # - # source://thor//lib/thor/shell/color.rb#114 - def show_diff(destination, content); end end # Set the terminal's foreground ANSI color to black. # -# source://thor//lib/thor/shell/color.rb#15 +# source://thor//lib/thor/shell/color.rb#18 Thor::Shell::Color::BLACK = T.let(T.unsafe(nil), String) # Set the terminal's foreground ANSI color to blue. # -# source://thor//lib/thor/shell/color.rb#23 +# source://thor//lib/thor/shell/color.rb#26 Thor::Shell::Color::BLUE = T.let(T.unsafe(nil), String) # The start of an ANSI bold sequence. # -# source://thor//lib/thor/shell/color.rb#12 +# source://thor//lib/thor/shell/color.rb#15 Thor::Shell::Color::BOLD = T.let(T.unsafe(nil), String) # Embed in a String to clear all previous ANSI sequences. # -# source://thor//lib/thor/shell/color.rb#10 +# source://thor//lib/thor/shell/color.rb#13 Thor::Shell::Color::CLEAR = T.let(T.unsafe(nil), String) # Set the terminal's foreground ANSI color to cyan. # -# source://thor//lib/thor/shell/color.rb#27 +# source://thor//lib/thor/shell/color.rb#30 Thor::Shell::Color::CYAN = T.let(T.unsafe(nil), String) # Set the terminal's foreground ANSI color to green. # -# source://thor//lib/thor/shell/color.rb#19 +# source://thor//lib/thor/shell/color.rb#22 Thor::Shell::Color::GREEN = T.let(T.unsafe(nil), String) # Set the terminal's foreground ANSI color to magenta. # -# source://thor//lib/thor/shell/color.rb#25 +# source://thor//lib/thor/shell/color.rb#28 Thor::Shell::Color::MAGENTA = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to black. # -# source://thor//lib/thor/shell/color.rb#32 +# source://thor//lib/thor/shell/color.rb#35 Thor::Shell::Color::ON_BLACK = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to blue. # -# source://thor//lib/thor/shell/color.rb#40 +# source://thor//lib/thor/shell/color.rb#43 Thor::Shell::Color::ON_BLUE = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to cyan. # -# source://thor//lib/thor/shell/color.rb#44 +# source://thor//lib/thor/shell/color.rb#47 Thor::Shell::Color::ON_CYAN = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to green. # -# source://thor//lib/thor/shell/color.rb#36 +# source://thor//lib/thor/shell/color.rb#39 Thor::Shell::Color::ON_GREEN = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to magenta. # -# source://thor//lib/thor/shell/color.rb#42 +# source://thor//lib/thor/shell/color.rb#45 Thor::Shell::Color::ON_MAGENTA = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to red. # -# source://thor//lib/thor/shell/color.rb#34 +# source://thor//lib/thor/shell/color.rb#37 Thor::Shell::Color::ON_RED = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to white. # -# source://thor//lib/thor/shell/color.rb#46 +# source://thor//lib/thor/shell/color.rb#49 Thor::Shell::Color::ON_WHITE = T.let(T.unsafe(nil), String) # Set the terminal's background ANSI color to yellow. # -# source://thor//lib/thor/shell/color.rb#38 +# source://thor//lib/thor/shell/color.rb#41 Thor::Shell::Color::ON_YELLOW = T.let(T.unsafe(nil), String) # Set the terminal's foreground ANSI color to red. # -# source://thor//lib/thor/shell/color.rb#17 +# source://thor//lib/thor/shell/color.rb#20 Thor::Shell::Color::RED = T.let(T.unsafe(nil), String) # Set the terminal's foreground ANSI color to white. # -# source://thor//lib/thor/shell/color.rb#29 +# source://thor//lib/thor/shell/color.rb#32 Thor::Shell::Color::WHITE = T.let(T.unsafe(nil), String) # Set the terminal's foreground ANSI color to yellow. # -# source://thor//lib/thor/shell/color.rb#21 +# source://thor//lib/thor/shell/color.rb#24 Thor::Shell::Color::YELLOW = T.let(T.unsafe(nil), String) +# source://thor//lib/thor/shell/column_printer.rb#5 +class Thor::Shell::ColumnPrinter + # @return [ColumnPrinter] a new instance of ColumnPrinter + # + # source://thor//lib/thor/shell/column_printer.rb#8 + def initialize(stdout, options = T.unsafe(nil)); end + + # Returns the value of attribute options. + # + # source://thor//lib/thor/shell/column_printer.rb#6 + def options; end + + # source://thor//lib/thor/shell/column_printer.rb#14 + def print(array); end + + # Returns the value of attribute stdout. + # + # source://thor//lib/thor/shell/column_printer.rb#6 + def stdout; end +end + # Inherit from Thor::Shell::Basic and add set_color behavior. Check # Thor::Shell::Basic to see all available methods. # -# source://thor//lib/thor/shell/html.rb#8 +# source://thor//lib/thor/shell/html.rb#9 class Thor::Shell::HTML < ::Thor::Shell::Basic + include ::LCSDiff + # Ask something to the user and receives a response. # # ==== Example - # ask("What is your name?") + # ask("What is your name?") # # TODO: Implement #ask for Thor::Shell::HTML # # @raise [NotImplementedError] # - # source://thor//lib/thor/shell/html.rb#70 + # source://thor//lib/thor/shell/html.rb#73 def ask(statement, color = T.unsafe(nil)); end # Set color by using a string or one of the defined constants. If a third @@ -3559,122 +3897,171 @@ class Thor::Shell::HTML < ::Thor::Shell::Basic # on Highline implementation and it automatically appends CLEAR to the end # of the returned String. # - # source://thor//lib/thor/shell/html.rb#51 + # source://thor//lib/thor/shell/html.rb#54 def set_color(string, *colors); end protected # @return [Boolean] # - # source://thor//lib/thor/shell/html.rb#76 + # source://thor//lib/thor/shell/html.rb#79 def can_display_colors?; end - - # Check if Diff::LCS is loaded. If it is, use it to create pretty output - # for diff. - # - # @return [Boolean] - # - # source://thor//lib/thor/shell/html.rb#113 - def diff_lcs_loaded?; end - - # source://thor//lib/thor/shell/html.rb#96 - def output_diff_line(diff); end - - # Overwrite show_diff to show diff with colors if Diff::LCS is - # available. - # - # source://thor//lib/thor/shell/html.rb#83 - def show_diff(destination, content); end end # Set the terminal's foreground HTML color to black. # -# source://thor//lib/thor/shell/html.rb#13 +# source://thor//lib/thor/shell/html.rb#16 Thor::Shell::HTML::BLACK = T.let(T.unsafe(nil), String) # Set the terminal's foreground HTML color to blue. # -# source://thor//lib/thor/shell/html.rb#21 +# source://thor//lib/thor/shell/html.rb#24 Thor::Shell::HTML::BLUE = T.let(T.unsafe(nil), String) # The start of an HTML bold sequence. # -# source://thor//lib/thor/shell/html.rb#10 +# source://thor//lib/thor/shell/html.rb#13 Thor::Shell::HTML::BOLD = T.let(T.unsafe(nil), String) # Set the terminal's foreground HTML color to cyan. # -# source://thor//lib/thor/shell/html.rb#25 +# source://thor//lib/thor/shell/html.rb#28 Thor::Shell::HTML::CYAN = T.let(T.unsafe(nil), String) # Set the terminal's foreground HTML color to green. # -# source://thor//lib/thor/shell/html.rb#17 +# source://thor//lib/thor/shell/html.rb#20 Thor::Shell::HTML::GREEN = T.let(T.unsafe(nil), String) # Set the terminal's foreground HTML color to magenta. # -# source://thor//lib/thor/shell/html.rb#23 +# source://thor//lib/thor/shell/html.rb#26 Thor::Shell::HTML::MAGENTA = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to black. # -# source://thor//lib/thor/shell/html.rb#30 +# source://thor//lib/thor/shell/html.rb#33 Thor::Shell::HTML::ON_BLACK = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to blue. # -# source://thor//lib/thor/shell/html.rb#38 +# source://thor//lib/thor/shell/html.rb#41 Thor::Shell::HTML::ON_BLUE = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to cyan. # -# source://thor//lib/thor/shell/html.rb#42 +# source://thor//lib/thor/shell/html.rb#45 Thor::Shell::HTML::ON_CYAN = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to green. # -# source://thor//lib/thor/shell/html.rb#34 +# source://thor//lib/thor/shell/html.rb#37 Thor::Shell::HTML::ON_GREEN = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to magenta. # -# source://thor//lib/thor/shell/html.rb#40 +# source://thor//lib/thor/shell/html.rb#43 Thor::Shell::HTML::ON_MAGENTA = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to red. # -# source://thor//lib/thor/shell/html.rb#32 +# source://thor//lib/thor/shell/html.rb#35 Thor::Shell::HTML::ON_RED = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to white. # -# source://thor//lib/thor/shell/html.rb#44 +# source://thor//lib/thor/shell/html.rb#47 Thor::Shell::HTML::ON_WHITE = T.let(T.unsafe(nil), String) # Set the terminal's background HTML color to yellow. # -# source://thor//lib/thor/shell/html.rb#36 +# source://thor//lib/thor/shell/html.rb#39 Thor::Shell::HTML::ON_YELLOW = T.let(T.unsafe(nil), String) # Set the terminal's foreground HTML color to red. # -# source://thor//lib/thor/shell/html.rb#15 +# source://thor//lib/thor/shell/html.rb#18 Thor::Shell::HTML::RED = T.let(T.unsafe(nil), String) # Set the terminal's foreground HTML color to white. # -# source://thor//lib/thor/shell/html.rb#27 +# source://thor//lib/thor/shell/html.rb#30 Thor::Shell::HTML::WHITE = T.let(T.unsafe(nil), String) # Set the terminal's foreground HTML color to yellow. # -# source://thor//lib/thor/shell/html.rb#19 +# source://thor//lib/thor/shell/html.rb#22 Thor::Shell::HTML::YELLOW = T.let(T.unsafe(nil), String) # source://thor//lib/thor/shell.rb#24 Thor::Shell::SHELL_DELEGATED_METHODS = T.let(T.unsafe(nil), Array) +# source://thor//lib/thor/shell/table_printer.rb#6 +class Thor::Shell::TablePrinter < ::Thor::Shell::ColumnPrinter + # @return [TablePrinter] a new instance of TablePrinter + # + # source://thor//lib/thor/shell/table_printer.rb#9 + def initialize(stdout, options = T.unsafe(nil)); end + + # source://thor//lib/thor/shell/table_printer.rb#18 + def print(array); end + + private + + # source://thor//lib/thor/shell/table_printer.rb#72 + def format_cell(column, row_size, index); end + + # source://thor//lib/thor/shell/table_printer.rb#113 + def indentation; end + + # source://thor//lib/thor/shell/table_printer.rb#47 + def prepare(array); end + + # source://thor//lib/thor/shell/table_printer.rb#96 + def print_border_separator; end + + # source://thor//lib/thor/shell/table_printer.rb#103 + def truncate(string); end +end + +# source://thor//lib/thor/shell/table_printer.rb#7 +Thor::Shell::TablePrinter::BORDER_SEPARATOR = T.let(T.unsafe(nil), Symbol) + +# source://thor//lib/thor/shell/terminal.rb#3 +module Thor::Shell::Terminal + class << self + # source://thor//lib/thor/shell/terminal.rb#9 + def terminal_width; end + + # @return [Boolean] + # + # source://thor//lib/thor/shell/terminal.rb#20 + def unix?; end + + private + + # Calculate the dynamic width of the terminal + # + # source://thor//lib/thor/shell/terminal.rb#27 + def dynamic_width; end + + # source://thor//lib/thor/shell/terminal.rb#31 + def dynamic_width_stty; end + + # source://thor//lib/thor/shell/terminal.rb#35 + def dynamic_width_tput; end + end +end + +# source://thor//lib/thor/shell/terminal.rb#4 +Thor::Shell::Terminal::DEFAULT_TERMINAL_WIDTH = T.let(T.unsafe(nil), Integer) + +# source://thor//lib/thor/shell/wrapped_printer.rb#6 +class Thor::Shell::WrappedPrinter < ::Thor::Shell::ColumnPrinter + # source://thor//lib/thor/shell/wrapped_printer.rb#7 + def print(message); end +end + # source://thor//lib/thor/base.rb#23 Thor::TEMPLATE_EXTNAME = T.let(T.unsafe(nil), String) @@ -3683,89 +4070,89 @@ Thor::TEMPLATE_EXTNAME = T.let(T.unsafe(nil), String) # source://thor//lib/thor/base.rb#20 Thor::THOR_RESERVED_WORDS = T.let(T.unsafe(nil), Array) -# source://thor//lib/thor/command.rb#117 +# source://thor//lib/thor/command.rb#126 Thor::Task = Thor::Command # Raised when a command was not found. # -# source://thor//lib/thor/error.rb#35 +# source://thor//lib/thor/error.rb#24 class Thor::UndefinedCommandError < ::Thor::Error include ::Thor::Correctable # @return [UndefinedCommandError] a new instance of UndefinedCommandError # - # source://thor//lib/thor/error.rb#54 + # source://thor//lib/thor/error.rb#43 def initialize(command, all_commands, namespace); end # Returns the value of attribute all_commands. # - # source://thor//lib/thor/error.rb#52 + # source://thor//lib/thor/error.rb#41 def all_commands; end # Returns the value of attribute command. # - # source://thor//lib/thor/error.rb#52 + # source://thor//lib/thor/error.rb#41 def command; end end -# source://thor//lib/thor/error.rb#36 +# source://thor//lib/thor/error.rb#25 class Thor::UndefinedCommandError::SpellChecker # @return [SpellChecker] a new instance of SpellChecker # - # source://thor//lib/thor/error.rb#39 + # source://thor//lib/thor/error.rb#28 def initialize(error); end - # source://thor//lib/thor/error.rb#43 + # source://thor//lib/thor/error.rb#32 def corrections; end # Returns the value of attribute error. # - # source://thor//lib/thor/error.rb#37 + # source://thor//lib/thor/error.rb#26 def error; end - # source://thor//lib/thor/error.rb#47 + # source://thor//lib/thor/error.rb#36 def spell_checker; end end -# source://thor//lib/thor/error.rb#66 +# source://thor//lib/thor/error.rb#55 Thor::UndefinedTaskError = Thor::UndefinedCommandError -# source://thor//lib/thor/error.rb#76 +# source://thor//lib/thor/error.rb#65 class Thor::UnknownArgumentError < ::Thor::Error include ::Thor::Correctable # @return [UnknownArgumentError] a new instance of UnknownArgumentError # - # source://thor//lib/thor/error.rb#96 + # source://thor//lib/thor/error.rb#85 def initialize(switches, unknown); end # Returns the value of attribute switches. # - # source://thor//lib/thor/error.rb#94 + # source://thor//lib/thor/error.rb#83 def switches; end # Returns the value of attribute unknown. # - # source://thor//lib/thor/error.rb#94 + # source://thor//lib/thor/error.rb#83 def unknown; end end -# source://thor//lib/thor/error.rb#77 +# source://thor//lib/thor/error.rb#66 class Thor::UnknownArgumentError::SpellChecker # @return [SpellChecker] a new instance of SpellChecker # - # source://thor//lib/thor/error.rb#80 + # source://thor//lib/thor/error.rb#69 def initialize(error); end - # source://thor//lib/thor/error.rb#84 + # source://thor//lib/thor/error.rb#73 def corrections; end # Returns the value of attribute error. # - # source://thor//lib/thor/error.rb#78 + # source://thor//lib/thor/error.rb#67 def error; end - # source://thor//lib/thor/error.rb#89 + # source://thor//lib/thor/error.rb#78 def spell_checker; end end @@ -3806,7 +4193,7 @@ module Thor::Util # ==== Returns # String # - # source://thor//lib/thor/util.rb#263 + # source://thor//lib/thor/util.rb#264 def escape_globs(path); end # Returns a string that has had any HTML characters escaped. @@ -3821,7 +4208,7 @@ module Thor::Util # ==== Returns # String # - # source://thor//lib/thor/util.rb#279 + # source://thor//lib/thor/util.rb#280 def escape_html(string); end # Receives a namespace and search for it in the Thor::Base subclasses. @@ -3884,13 +4271,13 @@ module Thor::Util # Where to look for Thor files. # - # source://thor//lib/thor/util.rb#212 + # source://thor//lib/thor/util.rb#213 def globs_for(path); end # Receives a path and load the thor file in the path. The file is evaluated # inside the sandbox to avoid namespacing conflicts. # - # source://thor//lib/thor/util.rb#152 + # source://thor//lib/thor/util.rb#153 def load_thorfile(path, content = T.unsafe(nil), debug = T.unsafe(nil)); end # Receives a constant and converts it to a Thor namespace. Since Thor @@ -3925,7 +4312,7 @@ module Thor::Util # Return the path to the ruby interpreter taking into account multiple # installations and windows extensions. # - # source://thor//lib/thor/util.rb#220 + # source://thor//lib/thor/util.rb#221 def ruby_command; end # Receives a string and convert it to snake case. SnakeCase returns snake_case. @@ -3946,7 +4333,7 @@ module Thor::Util # Returns the root where thor files are located, depending on the OS. # - # source://thor//lib/thor/util.rb#191 + # source://thor//lib/thor/util.rb#192 def thor_root; end # Returns the files in the thor root. On Windows thor_root will be something @@ -3956,10 +4343,10 @@ module Thor::Util # # If we don't #gsub the \ character, Dir.glob will fail. # - # source://thor//lib/thor/util.rb#202 + # source://thor//lib/thor/util.rb#203 def thor_root_glob; end - # source://thor//lib/thor/util.rb#167 + # source://thor//lib/thor/util.rb#168 def user_home; end end end diff --git a/sorbet/rbi/gems/tilt@2.2.0.rbi b/sorbet/rbi/gems/tilt@2.4.0.rbi similarity index 90% rename from sorbet/rbi/gems/tilt@2.2.0.rbi rename to sorbet/rbi/gems/tilt@2.4.0.rbi index f6d3e5f4e..a3c5a1b6c 100644 --- a/sorbet/rbi/gems/tilt@2.2.0.rbi +++ b/sorbet/rbi/gems/tilt@2.4.0.rbi @@ -4,6 +4,7 @@ # This is an autogenerated file for types exported from the `tilt` gem. # Please instead update this file by running `bin/tapioca gem tilt`. + # Namespace for Tilt. This module is not intended to be included anywhere. # # source://tilt//lib/tilt/template.rb#2 @@ -11,22 +12,12 @@ module Tilt class << self # @see Tilt::Mapping#[] # - # source://tilt//lib/tilt.rb#69 + # source://tilt//lib/tilt.rb#71 def [](file); end - # @example - # tmpl = Tilt['index.erb'].new { '<%= Tilt.current_template %>' } - # tmpl.render == tmpl.to_s - # @note This is currently an experimental feature and might return nil - # in the future. - # @return the template object that is currently rendering. - # - # source://tilt//lib/tilt.rb#91 - def current_template; end - # @return [Tilt::Mapping] the main mapping object # - # source://tilt//lib/tilt.rb#98 + # source://tilt//lib/tilt.rb#87 def default_mapping; end # Replace the default mapping with a finalized version of the default @@ -40,50 +31,50 @@ module Tilt # @private # - # source://tilt//lib/tilt.rb#39 + # source://tilt//lib/tilt.rb#41 def lazy_map; end # @see Tilt::Mapping#new # - # source://tilt//lib/tilt.rb#64 + # source://tilt//lib/tilt.rb#66 def new(file, line = T.unsafe(nil), options = T.unsafe(nil), &block); end # Alias register as prefer for Tilt 1.x compatibility. # # @see Tilt::Mapping#register # - # source://tilt//lib/tilt.rb#44 + # source://tilt//lib/tilt.rb#46 def prefer(template_class, *extensions); end # @see Tilt::Mapping#register # - # source://tilt//lib/tilt.rb#44 + # source://tilt//lib/tilt.rb#46 def register(template_class, *extensions); end # @see Tilt::Mapping#register_lazy # - # source://tilt//lib/tilt.rb#49 + # source://tilt//lib/tilt.rb#51 def register_lazy(class_name, file, *extensions); end # @see Tilt::Mapping#register_pipeline # - # source://tilt//lib/tilt.rb#54 + # source://tilt//lib/tilt.rb#56 def register_pipeline(ext, options = T.unsafe(nil)); end # @return [Boolean] # @see Tilt::Mapping#registered? # - # source://tilt//lib/tilt.rb#59 + # source://tilt//lib/tilt.rb#61 def registered?(ext); end # @see Tilt::Mapping#template_for # - # source://tilt//lib/tilt.rb#74 + # source://tilt//lib/tilt.rb#76 def template_for(file); end # @see Tilt::Mapping#templates_for # - # source://tilt//lib/tilt.rb#79 + # source://tilt//lib/tilt.rb#81 def templates_for(file); end end end @@ -220,16 +211,16 @@ end # key#hash and key#eql? should not change. # If this is too limiting for you, use a different cache implementation. # -# source://tilt//lib/tilt.rb#122 +# source://tilt//lib/tilt.rb#111 class Tilt::Cache # @return [Cache] a new instance of Cache # - # source://tilt//lib/tilt.rb#123 + # source://tilt//lib/tilt.rb#112 def initialize; end # Clears the cache. # - # source://tilt//lib/tilt.rb#140 + # source://tilt//lib/tilt.rb#129 def clear; end # Caches a value for key, or returns the previously cached value. @@ -240,16 +231,16 @@ class Tilt::Cache # @yield # @yieldreturn the value to cache for key # - # source://tilt//lib/tilt.rb#133 + # source://tilt//lib/tilt.rb#122 def fetch(*key); end end -# source://tilt//lib/tilt/coffee.rb#43 +# source://tilt//lib/tilt/coffee.rb#31 class Tilt::CoffeeScriptLiterateTemplate < ::Tilt::CoffeeScriptTemplate class << self # @return [Boolean] # - # source://tilt//lib/tilt/coffee.rb#46 + # source://tilt//lib/tilt/coffee.rb#34 def literate?; end end end @@ -261,7 +252,7 @@ end # # source://tilt//lib/tilt/coffee.rb#10 class Tilt::CoffeeScriptTemplate < ::Tilt::StaticTemplate - # source://tilt//lib/tilt/coffee.rb#34 + # source://tilt//lib/tilt/coffee.rb#22 def prepare; end class << self @@ -277,19 +268,9 @@ class Tilt::CoffeeScriptTemplate < ::Tilt::StaticTemplate # source://tilt//lib/tilt/coffee.rb#15 def default_bare=(_arg0); end - # :nocov: - # - # source://tilt//lib/tilt/coffee.rb#19 - def default_no_wrap; end - - # source://tilt//lib/tilt/coffee.rb#24 - def default_no_wrap=(value); end - - # :nocov: - # # @return [Boolean] # - # source://tilt//lib/tilt/coffee.rb#30 + # source://tilt//lib/tilt/coffee.rb#18 def literate?; end end end @@ -309,37 +290,26 @@ Tilt::EMPTY_HASH = T.let(T.unsafe(nil), Hash) class Tilt::ERBTemplate < ::Tilt::Template # @return [Boolean] # - # source://tilt//lib/tilt/erb.rb#74 + # source://tilt//lib/tilt/erb.rb#60 def freeze_string_literals?; end # ERB generates a line to specify the character coding of the generated # source in 1.9. Account for this in the line offset. # - # source://tilt//lib/tilt/erb.rb#69 + # source://tilt//lib/tilt/erb.rb#55 def precompiled(locals); end - # source://tilt//lib/tilt/erb.rb#58 + # source://tilt//lib/tilt/erb.rb#44 def precompiled_postamble(locals); end - # source://tilt//lib/tilt/erb.rb#50 + # source://tilt//lib/tilt/erb.rb#36 def precompiled_preamble(locals); end - # source://tilt//lib/tilt/erb.rb#45 + # source://tilt//lib/tilt/erb.rb#31 def precompiled_template(locals); end - # source://tilt//lib/tilt/erb.rb#25 + # source://tilt//lib/tilt/erb.rb#11 def prepare; end - - class << self - # source://tilt//lib/tilt/erb.rb#13 - def _default_output_variable; end - - # source://tilt//lib/tilt/erb.rb#16 - def default_output_variable; end - - # source://tilt//lib/tilt/erb.rb#20 - def default_output_variable=(name); end - end end # source://tilt//lib/tilt/erb.rb#9 @@ -720,21 +690,21 @@ end class Tilt::SassTemplate < ::Tilt::StaticTemplate private - # source://tilt//lib/tilt/sass.rb#44 + # source://tilt//lib/tilt/sass.rb#53 def _prepare_output; end - # source://tilt//lib/tilt/sass.rb#48 + # source://tilt//lib/tilt/sass.rb#57 def sass_options; end end -# source://tilt//lib/tilt/sass.rb#32 +# source://tilt//lib/tilt/sass.rb#41 Tilt::SassTemplate::Engine = SassC::Engine -# source://tilt//lib/tilt/sass.rb#58 +# source://tilt//lib/tilt/sass.rb#67 class Tilt::ScssTemplate < ::Tilt::SassTemplate private - # source://tilt//lib/tilt/sass.rb#63 + # source://tilt//lib/tilt/sass.rb#72 def sass_options; end end @@ -783,10 +753,15 @@ end # # source://tilt//lib/tilt/string.rb#7 class Tilt::StringTemplate < ::Tilt::Template - # source://tilt//lib/tilt/string.rb#17 + # @return [Boolean] + # + # source://tilt//lib/tilt/string.rb#23 + def freeze_string_literals?; end + + # source://tilt//lib/tilt/string.rb#18 def precompiled(locals); end - # source://tilt//lib/tilt/string.rb#13 + # source://tilt//lib/tilt/string.rb#14 def precompiled_template(locals); end # source://tilt//lib/tilt/string.rb#8 @@ -819,7 +794,7 @@ class Tilt::Template # The basename of the template file. # - # source://tilt//lib/tilt/template.rb#110 + # source://tilt//lib/tilt/template.rb#106 def basename(suffix = T.unsafe(nil)); end # The compiled method for the locals keys and scope_class provided. @@ -827,7 +802,7 @@ class Tilt::Template # directly on the scope class, which are much faster to call than # Tilt's normal rendering. # - # source://tilt//lib/tilt/template.rb#151 + # source://tilt//lib/tilt/template.rb#147 def compiled_method(locals_keys, scope_class = T.unsafe(nil)); end # A path ending in .rb that the template code will be written to, then @@ -840,7 +815,7 @@ class Tilt::Template # Set the prefix to use for compiled paths. # - # source://tilt//lib/tilt/template.rb#137 + # source://tilt//lib/tilt/template.rb#133 def compiled_path=(path); end # Template source; loaded from a file or given directly. @@ -850,7 +825,7 @@ class Tilt::Template # The filename used in backtraces to describe the template. # - # source://tilt//lib/tilt/template.rb#122 + # source://tilt//lib/tilt/template.rb#118 def eval_file; end # The name of the file where the template data was loaded from. @@ -866,12 +841,12 @@ class Tilt::Template # An empty Hash that the template engine can populate with various # metadata. # - # source://tilt//lib/tilt/template.rb#128 + # source://tilt//lib/tilt/template.rb#124 def metadata; end # The template file's basename with all extensions chomped off. # - # source://tilt//lib/tilt/template.rb#115 + # source://tilt//lib/tilt/template.rb#111 def name; end # A Hash of template engine specific options. This is passed directly @@ -895,7 +870,7 @@ class Tilt::Template # in your template class if you have a better hint of the data's # encoding. # - # source://tilt//lib/tilt/template.rb#173 + # source://tilt//lib/tilt/template.rb#169 def default_encoding; end # Execute the compiled template and return the result string. Template @@ -905,7 +880,7 @@ class Tilt::Template # This method is only used by source generating templates. Subclasses that # override render() may not support all features. # - # source://tilt//lib/tilt/template.rb#196 + # source://tilt//lib/tilt/template.rb#192 def evaluate(scope, locals, &block); end # Generates all template source by combining the preamble, template, and @@ -918,13 +893,13 @@ class Tilt::Template # offset. In most cases, overriding the #precompiled_template method is # easier and more appropriate. # - # source://tilt//lib/tilt/template.rb#228 + # source://tilt//lib/tilt/template.rb#224 def precompiled(local_keys); end - # source://tilt//lib/tilt/template.rb#266 + # source://tilt//lib/tilt/template.rb#262 def precompiled_postamble(local_keys); end - # source://tilt//lib/tilt/template.rb#262 + # source://tilt//lib/tilt/template.rb#258 def precompiled_preamble(local_keys); end # A string containing the (Ruby) source code for the template. The @@ -936,7 +911,7 @@ class Tilt::Template # # @raise [NotImplementedError] # - # source://tilt//lib/tilt/template.rb#258 + # source://tilt//lib/tilt/template.rb#254 def precompiled_template(local_keys); end # Do whatever preparation is necessary to setup the underlying template @@ -945,12 +920,12 @@ class Tilt::Template # # Empty by default as some subclasses do not need separate preparation. # - # source://tilt//lib/tilt/template.rb#184 + # source://tilt//lib/tilt/template.rb#180 def prepare; end # @return [Boolean] # - # source://tilt//lib/tilt/template.rb#175 + # source://tilt//lib/tilt/template.rb#171 def skip_compiled_encoding_detection?; end private @@ -958,10 +933,10 @@ class Tilt::Template # source://tilt//lib/tilt/template.rb#407 def binary(string); end - # source://tilt//lib/tilt/template.rb#345 + # source://tilt//lib/tilt/template.rb#341 def bind_compiled_method(method_source, offset, scope_class); end - # source://tilt//lib/tilt/template.rb#322 + # source://tilt//lib/tilt/template.rb#318 def compile_template_method(local_keys, scope_class = T.unsafe(nil)); end # source://tilt//lib/tilt/template.rb#370 @@ -981,16 +956,16 @@ class Tilt::Template # source://tilt//lib/tilt/template.rb#374 def load_compiled_method(path, method_source); end - # source://tilt//lib/tilt/template.rb#301 + # source://tilt//lib/tilt/template.rb#297 def local_extraction(local_keys); end - # source://tilt//lib/tilt/template.rb#274 + # source://tilt//lib/tilt/template.rb#270 def process_arg(arg); end - # source://tilt//lib/tilt/template.rb#288 + # source://tilt//lib/tilt/template.rb#284 def read_template_file; end - # source://tilt//lib/tilt/template.rb#297 + # source://tilt//lib/tilt/template.rb#293 def set_compiled_method_cache; end # source://tilt//lib/tilt/template.rb#382 @@ -1015,10 +990,10 @@ class Tilt::Template end end -# source://tilt//lib/tilt/template.rb#187 +# source://tilt//lib/tilt/template.rb#183 Tilt::Template::CLASS_METHOD = T.let(T.unsafe(nil), UnboundMethod) -# source://tilt//lib/tilt/template.rb#188 +# source://tilt//lib/tilt/template.rb#184 Tilt::Template::USE_BIND_CALL = T.let(T.unsafe(nil), TrueClass) # Current version. diff --git a/sorbet/rbi/gems/time@0.3.0.rbi b/sorbet/rbi/gems/time@0.3.0.rbi new file mode 100644 index 000000000..f6b018e11 --- /dev/null +++ b/sorbet/rbi/gems/time@0.3.0.rbi @@ -0,0 +1,438 @@ +# typed: false + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `time` gem. +# Please instead update this file by running `bin/tapioca gem time`. + + +# :startdoc: +class Time + include ::Comparable + + # Returns a string which represents the time as RFC 1123 date of HTTP-date + # defined by RFC 2616: + # + # day-of-week, DD month-name CCYY hh:mm:ss GMT + # + # Note that the result is always UTC (GMT). + # + # require 'time' + # + # t = Time.now + # t.httpdate # => "Thu, 06 Oct 2011 02:26:12 GMT" + # + # You must require 'time' to use this method. + # + # source://time//time.rb#692 + def httpdate; end + + # Returns a string which represents the time as a dateTime defined by XML + # Schema: + # + # CCYY-MM-DDThh:mm:ssTZD + # CCYY-MM-DDThh:mm:ss.sssTZD + # + # where TZD is Z or [+-]hh:mm. + # + # If self is a UTC time, Z is used as TZD. [+-]hh:mm is used otherwise. + # + # +fraction_digits+ specifies a number of digits to use for fractional + # seconds. Its default value is 0. + # + # require 'time' + # + # t = Time.now + # t.iso8601 # => "2011-10-05T22:26:12-04:00" + # + # You must require 'time' to use this method. + # + # source://time//time.rb#717 + def iso8601(fraction_digits = T.unsafe(nil)); end + + # Returns a string which represents the time as date-time defined by RFC 2822: + # + # day-of-week, DD month-name CCYY hh:mm:ss zone + # + # where zone is [+-]hhmm. + # + # If +self+ is a UTC time, -0000 is used as zone. + # + # require 'time' + # + # t = Time.now + # t.rfc2822 # => "Wed, 05 Oct 2011 22:26:12 -0400" + # + # You must require 'time' to use this method. + # + # source://time//time.rb#672 + def rfc2822; end + + # source://time//time.rb#717 + def rfc3339(fraction_digits = T.unsafe(nil)); end + + # Returns a string which represents the time as date-time defined by RFC 2822: + # + # day-of-week, DD month-name CCYY hh:mm:ss zone + # + # where zone is [+-]hhmm. + # + # If +self+ is a UTC time, -0000 is used as zone. + # + # require 'time' + # + # t = Time.now + # t.rfc2822 # => "Wed, 05 Oct 2011 22:26:12 -0400" + # + # You must require 'time' to use this method. + # + # source://time//time.rb#672 + def rfc822; end + + # Returns a string which represents the time as a dateTime defined by XML + # Schema: + # + # CCYY-MM-DDThh:mm:ssTZD + # CCYY-MM-DDThh:mm:ss.sssTZD + # + # where TZD is Z or [+-]hh:mm. + # + # If self is a UTC time, Z is used as TZD. [+-]hh:mm is used otherwise. + # + # +fraction_digits+ specifies a number of digits to use for fractional + # seconds. Its default value is 0. + # + # require 'time' + # + # t = Time.now + # t.iso8601 # => "2011-10-05T22:26:12-04:00" + # + # You must require 'time' to use this method. + # + # source://time//time.rb#717 + def xmlschema(fraction_digits = T.unsafe(nil)); end + + class << self + # Parses +date+ as an HTTP-date defined by RFC 2616 and converts it to a + # Time object. + # + # ArgumentError is raised if +date+ is not compliant with RFC 2616 or if + # the Time class cannot represent specified date. + # + # See #httpdate for more information on this format. + # + # require 'time' + # + # Time.httpdate("Thu, 06 Oct 2011 02:26:12 GMT") + # #=> 2011-10-06 02:26:12 UTC + # + # You must require 'time' to use this method. + # + # source://time//time.rb#566 + def httpdate(date); end + + # Parses +time+ as a dateTime defined by the XML Schema and converts it to + # a Time object. The format is a restricted version of the format defined + # by ISO 8601. + # + # ArgumentError is raised if +time+ is not compliant with the format or if + # the Time class cannot represent the specified time. + # + # See #xmlschema for more information on this format. + # + # require 'time' + # + # Time.xmlschema("2011-10-05T22:26:12-04:00") + # #=> 2011-10-05 22:26:12-04:00 + # + # You must require 'time' to use this method. + # + # source://time//time.rb#620 + def iso8601(time); end + + # Takes a string representation of a Time and attempts to parse it + # using a heuristic. + # + # This method **does not** function as a validator. If the input + # string does not match valid formats strictly, you may get a + # cryptic result. Should consider to use `Time.strptime` instead + # of this method as possible. + # + # require 'time' + # + # Time.parse("2010-10-31") #=> 2010-10-31 00:00:00 -0500 + # + # Any missing pieces of the date are inferred based on the current date. + # + # require 'time' + # + # # assuming the current date is "2011-10-31" + # Time.parse("12:00") #=> 2011-10-31 12:00:00 -0500 + # + # We can change the date used to infer our missing elements by passing a second + # object that responds to #mon, #day and #year, such as Date, Time or DateTime. + # We can also use our own object. + # + # require 'time' + # + # class MyDate + # attr_reader :mon, :day, :year + # + # def initialize(mon, day, year) + # @mon, @day, @year = mon, day, year + # end + # end + # + # d = Date.parse("2010-10-28") + # t = Time.parse("2010-10-29") + # dt = DateTime.parse("2010-10-30") + # md = MyDate.new(10,31,2010) + # + # Time.parse("12:00", d) #=> 2010-10-28 12:00:00 -0500 + # Time.parse("12:00", t) #=> 2010-10-29 12:00:00 -0500 + # Time.parse("12:00", dt) #=> 2010-10-30 12:00:00 -0500 + # Time.parse("12:00", md) #=> 2010-10-31 12:00:00 -0500 + # + # If a block is given, the year described in +date+ is converted + # by the block. This is specifically designed for handling two + # digit years. For example, if you wanted to treat all two digit + # years prior to 70 as the year 2000+ you could write this: + # + # require 'time' + # + # Time.parse("01-10-31") {|year| year + (year < 70 ? 2000 : 1900)} + # #=> 2001-10-31 00:00:00 -0500 + # Time.parse("70-10-31") {|year| year + (year < 70 ? 2000 : 1900)} + # #=> 1970-10-31 00:00:00 -0500 + # + # If the upper components of the given time are broken or missing, they are + # supplied with those of +now+. For the lower components, the minimum + # values (1 or 0) are assumed if broken or missing. For example: + # + # require 'time' + # + # # Suppose it is "Thu Nov 29 14:33:20 2001" now and + # # your time zone is EST which is GMT-5. + # now = Time.parse("Thu Nov 29 14:33:20 2001") + # Time.parse("16:30", now) #=> 2001-11-29 16:30:00 -0500 + # Time.parse("7/23", now) #=> 2001-07-23 00:00:00 -0500 + # Time.parse("Aug 31", now) #=> 2001-08-31 00:00:00 -0500 + # Time.parse("Aug 2000", now) #=> 2000-08-01 00:00:00 -0500 + # + # Since there are numerous conflicts among locally defined time zone + # abbreviations all over the world, this method is not intended to + # understand all of them. For example, the abbreviation "CST" is + # used variously as: + # + # -06:00 in America/Chicago, + # -05:00 in America/Havana, + # +08:00 in Asia/Harbin, + # +09:30 in Australia/Darwin, + # +10:30 in Australia/Adelaide, + # etc. + # + # Based on this fact, this method only understands the time zone + # abbreviations described in RFC 822 and the system time zone, in the + # order named. (i.e. a definition in RFC 822 overrides the system + # time zone definition.) The system time zone is taken from + # Time.local(year, 1, 1).zone and + # Time.local(year, 7, 1).zone. + # If the extracted time zone abbreviation does not match any of them, + # it is ignored and the given time is regarded as a local time. + # + # ArgumentError is raised if Date._parse cannot extract information from + # +date+ or if the Time class cannot represent specified date. + # + # This method can be used as a fail-safe for other parsing methods as: + # + # Time.rfc2822(date) rescue Time.parse(date) + # Time.httpdate(date) rescue Time.parse(date) + # Time.xmlschema(date) rescue Time.parse(date) + # + # A failure of Time.parse should be checked, though. + # + # You must require 'time' to use this method. + # + # source://time//time.rb#381 + def parse(date, now = T.unsafe(nil)); end + + # Parses +date+ as date-time defined by RFC 2822 and converts it to a Time + # object. The format is identical to the date format defined by RFC 822 and + # updated by RFC 1123. + # + # ArgumentError is raised if +date+ is not compliant with RFC 2822 + # or if the Time class cannot represent specified date. + # + # See #rfc2822 for more information on this format. + # + # require 'time' + # + # Time.rfc2822("Wed, 05 Oct 2011 22:26:12 -0400") + # #=> 2010-10-05 22:26:12 -0400 + # + # You must require 'time' to use this method. + # + # source://time//time.rb#508 + def rfc2822(date); end + + # Parses +date+ as date-time defined by RFC 2822 and converts it to a Time + # object. The format is identical to the date format defined by RFC 822 and + # updated by RFC 1123. + # + # ArgumentError is raised if +date+ is not compliant with RFC 2822 + # or if the Time class cannot represent specified date. + # + # See #rfc2822 for more information on this format. + # + # require 'time' + # + # Time.rfc2822("Wed, 05 Oct 2011 22:26:12 -0400") + # #=> 2010-10-05 22:26:12 -0400 + # + # You must require 'time' to use this method. + # + # source://time//time.rb#508 + def rfc822(date); end + + # Works similar to +parse+ except that instead of using a + # heuristic to detect the format of the input string, you provide + # a second argument that describes the format of the string. + # + # If a block is given, the year described in +date+ is converted by the + # block. For example: + # + # Time.strptime(...) {|y| y < 100 ? (y >= 69 ? y + 1900 : y + 2000) : y} + # + # Below is a list of the formatting options: + # + # %a :: The abbreviated weekday name ("Sun") + # %A :: The full weekday name ("Sunday") + # %b :: The abbreviated month name ("Jan") + # %B :: The full month name ("January") + # %c :: The preferred local date and time representation + # %C :: Century (20 in 2009) + # %d :: Day of the month (01..31) + # %D :: Date (%m/%d/%y) + # %e :: Day of the month, blank-padded ( 1..31) + # %F :: Equivalent to %Y-%m-%d (the ISO 8601 date format) + # %g :: The last two digits of the commercial year + # %G :: The week-based year according to ISO-8601 (week 1 starts on Monday + # and includes January 4) + # %h :: Equivalent to %b + # %H :: Hour of the day, 24-hour clock (00..23) + # %I :: Hour of the day, 12-hour clock (01..12) + # %j :: Day of the year (001..366) + # %k :: hour, 24-hour clock, blank-padded ( 0..23) + # %l :: hour, 12-hour clock, blank-padded ( 0..12) + # %L :: Millisecond of the second (000..999) + # %m :: Month of the year (01..12) + # %M :: Minute of the hour (00..59) + # %n :: Newline (\n) + # %N :: Fractional seconds digits + # %p :: Meridian indicator ("AM" or "PM") + # %P :: Meridian indicator ("am" or "pm") + # %r :: time, 12-hour (same as %I:%M:%S %p) + # %R :: time, 24-hour (%H:%M) + # %s :: Number of seconds since 1970-01-01 00:00:00 UTC. + # %S :: Second of the minute (00..60) + # %t :: Tab character (\t) + # %T :: time, 24-hour (%H:%M:%S) + # %u :: Day of the week as a decimal, Monday being 1. (1..7) + # %U :: Week number of the current year, starting with the first Sunday as + # the first day of the first week (00..53) + # %v :: VMS date (%e-%b-%Y) + # %V :: Week number of year according to ISO 8601 (01..53) + # %W :: Week number of the current year, starting with the first Monday + # as the first day of the first week (00..53) + # %w :: Day of the week (Sunday is 0, 0..6) + # %x :: Preferred representation for the date alone, no time + # %X :: Preferred representation for the time alone, no date + # %y :: Year without a century (00..99) + # %Y :: Year which may include century, if provided + # %z :: Time zone as hour offset from UTC (e.g. +0900) + # %Z :: Time zone name + # %% :: Literal "%" character + # %+ :: date(1) (%a %b %e %H:%M:%S %Z %Y) + # + # require 'time' + # + # Time.strptime("2000-10-31", "%Y-%m-%d") #=> 2000-10-31 00:00:00 -0500 + # + # You must require 'time' to use this method. + # + # @raise [ArgumentError] + # + # source://time//time.rb#456 + def strptime(date, format, now = T.unsafe(nil)); end + + # Parses +time+ as a dateTime defined by the XML Schema and converts it to + # a Time object. The format is a restricted version of the format defined + # by ISO 8601. + # + # ArgumentError is raised if +time+ is not compliant with the format or if + # the Time class cannot represent the specified time. + # + # See #xmlschema for more information on this format. + # + # require 'time' + # + # Time.xmlschema("2011-10-05T22:26:12-04:00") + # #=> 2011-10-05 22:26:12-04:00 + # + # You must require 'time' to use this method. + # + # source://time//time.rb#620 + def xmlschema(time); end + + # Return the number of seconds the specified time zone differs + # from UTC. + # + # Numeric time zones that include minutes, such as + # -10:00 or +1330 will work, as will + # simpler hour-only time zones like -10 or + # +13. + # + # Textual time zones listed in ZoneOffset are also supported. + # + # If the time zone does not match any of the above, +zone_offset+ + # will check if the local time zone (both with and without + # potential Daylight Saving \Time changes being in effect) matches + # +zone+. Specifying a value for +year+ will change the year used + # to find the local time zone. + # + # If +zone_offset+ is unable to determine the offset, nil will be + # returned. + # + # require 'time' + # + # Time.zone_offset("EST") #=> -18000 + # + # You must require 'time' to use this method. + # + # source://time//time.rb#82 + def zone_offset(zone, year = T.unsafe(nil)); end + + private + + # source://time//time.rb#153 + def apply_offset(year, mon, day, hour, min, sec, off); end + + # source://time//time.rb#124 + def force_zone!(t, zone, offset = T.unsafe(nil)); end + + # source://time//time.rb#197 + def make_time(date, year, yday, mon, day, hour, min, sec, sec_fraction, zone, now); end + + # source://time//time.rb#144 + def month_days(y, m); end + + # :stopdoc: + # + # @return [Boolean] + # + # source://time//time.rb#100 + def zone_utc?(zone); end + end +end + +# source://time//time.rb#29 +Time::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/timeout@0.3.2.rbi b/sorbet/rbi/gems/timeout@0.4.1.rbi similarity index 81% rename from sorbet/rbi/gems/timeout@0.3.2.rbi rename to sorbet/rbi/gems/timeout@0.4.1.rbi index 70a2ee465..4e7629003 100644 --- a/sorbet/rbi/gems/timeout@0.3.2.rbi +++ b/sorbet/rbi/gems/timeout@0.4.1.rbi @@ -1,10 +1,10 @@ -# typed: false +# typed: true # DO NOT EDIT MANUALLY # This is an autogenerated file for types exported from the `timeout` gem. # Please instead update this file by running `bin/tapioca gem timeout`. -# source://timeout//lib/timeout.rb#25 + module Timeout private @@ -34,11 +34,11 @@ module Timeout # Timeout into your classes so they have a #timeout method, as well as # a module method, so you can call it directly as Timeout.timeout(). # - # source://timeout//lib/timeout.rb#172 + # source://timeout//timeout.rb#169 def timeout(sec, klass = T.unsafe(nil), message = T.unsafe(nil), &block); end class << self - # source://timeout//lib/timeout.rb#130 + # source://timeout//timeout.rb#127 def ensure_timeout_thread_created; end # Perform an operation in a block, raising an error if it takes longer than @@ -67,82 +67,77 @@ module Timeout # Timeout into your classes so they have a #timeout method, as well as # a module method, so you can call it directly as Timeout.timeout(). # - # source://timeout//lib/timeout.rb#172 + # source://timeout//timeout.rb#169 def timeout(sec, klass = T.unsafe(nil), message = T.unsafe(nil), &block); end private - # source://timeout//lib/timeout.rb#100 + # source://timeout//timeout.rb#97 def create_timeout_thread; end end end # :stopdoc: # -# source://timeout//lib/timeout.rb#53 +# source://timeout//timeout.rb#50 Timeout::CONDVAR = T.let(T.unsafe(nil), Thread::ConditionVariable) # Raised by Timeout.timeout when the block times out. -# -# source://timeout//lib/timeout.rb#29 class Timeout::Error < ::RuntimeError - # source://timeout//lib/timeout.rb#39 - def exception(*_arg0); end - - # Returns the value of attribute thread. - # - # source://timeout//lib/timeout.rb#30 - def thread; end - class << self - # source://timeout//lib/timeout.rb#32 - def catch(*args); end + # source://timeout//timeout.rb#37 + def handle_timeout(message); end end end +# Internal error raised to when a timeout is triggered. +class Timeout::ExitException < ::Exception + # source://timeout//timeout.rb#30 + def exception(*_arg0); end +end + # We keep a private reference so that time mocking libraries won't break # Timeout. # -# source://timeout//lib/timeout.rb#142 +# source://timeout//timeout.rb#139 Timeout::GET_TIME = T.let(T.unsafe(nil), Method) -# source://timeout//lib/timeout.rb#54 +# source://timeout//timeout.rb#51 Timeout::QUEUE = T.let(T.unsafe(nil), Thread::Queue) -# source://timeout//lib/timeout.rb#55 +# source://timeout//timeout.rb#52 Timeout::QUEUE_MUTEX = T.let(T.unsafe(nil), Thread::Mutex) -# source://timeout//lib/timeout.rb#60 class Timeout::Request # @return [Request] a new instance of Request # - # source://timeout//lib/timeout.rb#63 + # source://timeout//timeout.rb#60 def initialize(thread, timeout, exception_class, message); end # Returns the value of attribute deadline. # - # source://timeout//lib/timeout.rb#61 + # source://timeout//timeout.rb#58 def deadline; end # @return [Boolean] # - # source://timeout//lib/timeout.rb#73 + # source://timeout//timeout.rb#70 def done?; end # @return [Boolean] # - # source://timeout//lib/timeout.rb#79 + # source://timeout//timeout.rb#76 def expired?(now); end - # source://timeout//lib/timeout.rb#92 + # source://timeout//timeout.rb#89 def finished; end - # source://timeout//lib/timeout.rb#83 + # source://timeout//timeout.rb#80 def interrupt; end end -# source://timeout//lib/timeout.rb#56 +# source://timeout//timeout.rb#53 Timeout::TIMEOUT_THREAD_MUTEX = T.let(T.unsafe(nil), Thread::Mutex) -# source://timeout//lib/timeout.rb#26 +# source://timeout//timeout.rb#26 Timeout::VERSION = T.let(T.unsafe(nil), String) diff --git a/sorbet/rbi/gems/tins@1.32.1.rbi b/sorbet/rbi/gems/tins@1.33.0.rbi similarity index 99% rename from sorbet/rbi/gems/tins@1.32.1.rbi rename to sorbet/rbi/gems/tins@1.33.0.rbi index 7ddb2eaf8..d2de3e5aa 100644 --- a/sorbet/rbi/gems/tins@1.32.1.rbi +++ b/sorbet/rbi/gems/tins@1.33.0.rbi @@ -4,5 +4,6 @@ # This is an autogenerated file for types exported from the `tins` gem. # Please instead update this file by running `bin/tapioca gem tins`. + # THIS IS AN EMPTY RBI FILE. # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem diff --git a/sorbet/rbi/gems/turbo-rails@1.4.0.rbi b/sorbet/rbi/gems/turbo-rails@1.4.0.rbi deleted file mode 100644 index d25afc2bd..000000000 --- a/sorbet/rbi/gems/turbo-rails@1.4.0.rbi +++ /dev/null @@ -1,131 +0,0 @@ -# typed: true - -# DO NOT EDIT MANUALLY -# This is an autogenerated file for types exported from the `turbo-rails` gem. -# Please instead update this file by running `bin/tapioca gem turbo-rails`. - -# source://turbo-rails//lib/turbo/test_assertions.rb#1 -module Turbo - extend ::ActiveSupport::Autoload - - class << self - # source://railties/7.0.5/lib/rails/engine.rb#405 - def railtie_helpers_paths; end - - # source://railties/7.0.5/lib/rails/engine.rb#394 - def railtie_namespace; end - - # source://railties/7.0.5/lib/rails/engine.rb#409 - def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end - - # source://turbo-rails//lib/turbo-rails.rb#9 - def signed_stream_verifier; end - - # source://turbo-rails//lib/turbo-rails.rb#13 - def signed_stream_verifier_key; end - - # Sets the attribute signed_stream_verifier_key - # - # @param value the value to set the attribute signed_stream_verifier_key to. - # - # source://turbo-rails//lib/turbo-rails.rb#7 - def signed_stream_verifier_key=(_arg0); end - - # source://railties/7.0.5/lib/rails/engine.rb#397 - def table_name_prefix; end - - # source://railties/7.0.5/lib/rails/engine.rb#401 - def use_relative_model_naming?; end - end -end - -module Turbo::Broadcastable - extend ::ActiveSupport::Concern - - mixes_in_class_methods ::Turbo::Broadcastable::ClassMethods - - def broadcast_action(action, target: T.unsafe(nil), **rendering); end - def broadcast_action_later(action:, target: T.unsafe(nil), **rendering); end - def broadcast_action_later_to(*streamables, action:, target: T.unsafe(nil), **rendering); end - def broadcast_action_to(*streamables, action:, target: T.unsafe(nil), **rendering); end - def broadcast_after_to(*streamables, target:, **rendering); end - def broadcast_append(target: T.unsafe(nil), **rendering); end - def broadcast_append_later(target: T.unsafe(nil), **rendering); end - def broadcast_append_later_to(*streamables, target: T.unsafe(nil), **rendering); end - def broadcast_append_to(*streamables, target: T.unsafe(nil), **rendering); end - def broadcast_before_to(*streamables, target:, **rendering); end - def broadcast_prepend(target: T.unsafe(nil), **rendering); end - def broadcast_prepend_later(target: T.unsafe(nil), **rendering); end - def broadcast_prepend_later_to(*streamables, target: T.unsafe(nil), **rendering); end - def broadcast_prepend_to(*streamables, target: T.unsafe(nil), **rendering); end - def broadcast_remove; end - def broadcast_remove_to(*streamables, target: T.unsafe(nil)); end - def broadcast_render(**rendering); end - def broadcast_render_later(**rendering); end - def broadcast_render_later_to(*streamables, **rendering); end - def broadcast_render_to(*streamables, **rendering); end - def broadcast_replace(**rendering); end - def broadcast_replace_later(**rendering); end - def broadcast_replace_later_to(*streamables, **rendering); end - def broadcast_replace_to(*streamables, **rendering); end - def broadcast_update(**rendering); end - def broadcast_update_later(**rendering); end - def broadcast_update_later_to(*streamables, **rendering); end - def broadcast_update_to(*streamables, **rendering); end - - private - - def broadcast_rendering_with_defaults(options); end - def broadcast_target_default; end -end - -module Turbo::Broadcastable::ClassMethods - def broadcast_target_default; end - def broadcasts(stream = T.unsafe(nil), inserts_by: T.unsafe(nil), target: T.unsafe(nil), **rendering); end - def broadcasts_to(stream, inserts_by: T.unsafe(nil), target: T.unsafe(nil), **rendering); end -end - -module Turbo::DriveHelper - def turbo_exempts_page_from_cache; end - def turbo_exempts_page_from_preview; end - def turbo_page_requires_reload; end -end - -# source://turbo-rails//lib/turbo/engine.rb#5 -class Turbo::Engine < ::Rails::Engine; end - -# If you don't want to precompile Turbo's assets (eg. because you're using webpack), -# you can do this in an intiailzer: -# -# config.after_initialize do -# config.assets.precompile -= Turbo::Engine::PRECOMPILE_ASSETS -# end -# -# source://turbo-rails//lib/turbo/engine.rb#29 -Turbo::Engine::PRECOMPILE_ASSETS = T.let(T.unsafe(nil), Array) - -module Turbo::FramesHelper - def turbo_frame_tag(*ids, src: T.unsafe(nil), target: T.unsafe(nil), **attributes, &block); end -end - -module Turbo::IncludesHelper - def turbo_include_tags; end -end - -class Turbo::StreamsChannel < ::ActionCable::Channel::Base; end - -module Turbo::StreamsHelper - def turbo_stream; end - def turbo_stream_from(*streamables, **attributes); end -end - -# source://turbo-rails//lib/turbo/test_assertions.rb#2 -module Turbo::TestAssertions - extend ::ActiveSupport::Concern - - # source://turbo-rails//lib/turbo/test_assertions.rb#19 - def assert_no_turbo_stream(action:, target: T.unsafe(nil), targets: T.unsafe(nil)); end - - # source://turbo-rails//lib/turbo/test_assertions.rb#10 - def assert_turbo_stream(action:, target: T.unsafe(nil), targets: T.unsafe(nil), status: T.unsafe(nil), &block); end -end diff --git a/sorbet/rbi/gems/turbo-rails@2.0.6.rbi b/sorbet/rbi/gems/turbo-rails@2.0.6.rbi new file mode 100644 index 000000000..0056df6ce --- /dev/null +++ b/sorbet/rbi/gems/turbo-rails@2.0.6.rbi @@ -0,0 +1,1300 @@ +# typed: true + +# DO NOT EDIT MANUALLY +# This is an autogenerated file for types exported from the `turbo-rails` gem. +# Please instead update this file by running `bin/tapioca gem turbo-rails`. + + +class ActionController::Base < ::ActionController::Metal + include ::ActionDispatch::Routing::PolymorphicRoutes + include ::ActionController::Head + include ::AbstractController::Caching::ConfigMethods + include ::ActionController::BasicImplicitRender + include ::Devise::Controllers::SignInOut + include ::Devise::Controllers::StoreLocation + extend ::AbstractController::Helpers::Resolution + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 + def _helper_methods; end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 + def _helper_methods=(_arg0); end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 + def _helper_methods?; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#924 + def _process_action_callbacks; end + + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 + def _renderers; end + + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 + def _renderers=(_arg0); end + + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 + def _renderers?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#912 + def _run_process_action_callbacks(&block); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 + def _view_cache_dependencies; end + + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 + def _view_cache_dependencies=(_arg0); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 + def _view_cache_dependencies?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 + def _wrapper_options; end + + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 + def _wrapper_options=(_arg0); end + + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 + def _wrapper_options?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#38 + def alert; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def allow_forgery_protection; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def allow_forgery_protection=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def asset_host; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def asset_host=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def assets_dir; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def assets_dir=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_static_extension; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_static_extension=(value); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 + def default_url_options; end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 + def default_url_options=(_arg0); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 + def default_url_options?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def enable_fragment_cache_logging; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def enable_fragment_cache_logging=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 + def etag_with_template_digest; end + + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 + def etag_with_template_digest=(_arg0); end + + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 + def etag_with_template_digest?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 + def etaggers; end + + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 + def etaggers=(_arg0); end + + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 + def etaggers?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#12 + def flash(*_arg0, **_arg1, &_arg2); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def forgery_protection_origin_check; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def forgery_protection_origin_check=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def forgery_protection_strategy; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def forgery_protection_strategy=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 + def fragment_cache_keys; end + + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 + def fragment_cache_keys=(_arg0); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 + def fragment_cache_keys?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 + def helpers_path; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 + def helpers_path=(_arg0); end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 + def helpers_path?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 + def include_all_helpers; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 + def include_all_helpers=(_arg0); end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 + def include_all_helpers?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def javascripts_dir; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def javascripts_dir=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def log_warning_on_csrf_failure; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def log_warning_on_csrf_failure=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def logger; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def logger=(value); end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def mimes_for_respond_to; end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def mimes_for_respond_to=(_arg0); end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def mimes_for_respond_to?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#38 + def notice; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def per_form_csrf_tokens; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def per_form_csrf_tokens=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def perform_caching; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def perform_caching=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 + def raise_on_open_redirects; end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 + def raise_on_open_redirects=(val); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def relative_url_root; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def relative_url_root=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def request_forgery_protection_token; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def request_forgery_protection_token=(value); end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers=(_arg0); end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers?; end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def responder; end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def responder=(_arg0); end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def responder?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def stylesheets_dir; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def stylesheets_dir=(value); end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + # source://actionpack/7.2.0/lib/action_controller/base.rb#324 + def _protected_ivars; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks=(value); end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks?; end + + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 + def _default_form_builder; end + + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 + def _default_form_builder=(value); end + + # source://actionpack/7.2.0/lib/action_controller/form_builder.rb#35 + def _default_form_builder?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 + def _flash_types; end + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 + def _flash_types=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#10 + def _flash_types?; end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 + def _helper_methods; end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 + def _helper_methods=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#13 + def _helper_methods?; end + + # source://actionpack/7.2.0/lib/abstract_controller/helpers.rb#17 + def _helpers; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 + def _layout; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 + def _layout=(value); end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#211 + def _layout?; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions; end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions=(value); end + + # source://actionview/7.2.0/lib/action_view/layouts.rb#212 + def _layout_conditions?; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#916 + def _process_action_callbacks; end + + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#920 + def _process_action_callbacks=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 + def _renderers; end + + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 + def _renderers=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/renderers.rb#33 + def _renderers?; end + + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 + def _view_cache_dependencies; end + + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 + def _view_cache_dependencies=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#44 + def _view_cache_dependencies?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 + def _wrapper_options; end + + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 + def _wrapper_options=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/params_wrapper.rb#185 + def _wrapper_options?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def allow_forgery_protection; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def allow_forgery_protection=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def asset_host; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def asset_host=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def assets_dir; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def assets_dir=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def csrf_token_storage_strategy; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def csrf_token_storage_strategy=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_asset_host_protocol; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_asset_host_protocol=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def default_static_extension; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def default_static_extension=(value); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 + def default_url_options; end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 + def default_url_options=(value); end + + # source://actionpack/7.2.0/lib/action_dispatch/routing/url_for.rb#100 + def default_url_options?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def enable_fragment_cache_logging; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def enable_fragment_cache_logging=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 + def etag_with_template_digest; end + + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 + def etag_with_template_digest=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/etag_with_template_digest.rb#31 + def etag_with_template_digest?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 + def etaggers; end + + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 + def etaggers=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/conditional_get.rb#15 + def etaggers?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def forgery_protection_origin_check; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def forgery_protection_origin_check=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def forgery_protection_strategy; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def forgery_protection_strategy=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 + def fragment_cache_keys; end + + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 + def fragment_cache_keys=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#26 + def fragment_cache_keys?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 + def helpers_path; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 + def helpers_path=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#70 + def helpers_path?; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 + def include_all_helpers; end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 + def include_all_helpers=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal/helpers.rb#71 + def include_all_helpers?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def javascripts_dir; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def javascripts_dir=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def log_warning_on_csrf_failure; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def log_warning_on_csrf_failure=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def logger; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def logger=(value); end + + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def mimes_for_respond_to; end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def mimes_for_respond_to=(value); end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def mimes_for_respond_to?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def per_form_csrf_tokens; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def per_form_csrf_tokens=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def perform_caching; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def perform_caching=(value); end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions; end + + # source://actionpack/7.2.0/lib/abstract_controller/callbacks.rb#36 + def raise_on_missing_callback_actions=(val); end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 + def raise_on_open_redirects; end + + # source://actionpack/7.2.0/lib/action_controller/metal/redirecting.rb#17 + def raise_on_open_redirects=(val); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def relative_url_root; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def relative_url_root=(value); end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def request_forgery_protection_token; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def request_forgery_protection_token=(value); end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers=(value); end + + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers?; end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def responder; end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def responder=(value); end + + # source://responders/3.1.1/lib/action_controller/respond_with.rb#11 + def responder?; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#115 + def stylesheets_dir; end + + # source://activesupport/7.2.0/lib/active_support/configurable.rb#116 + def stylesheets_dir=(value); end + + # source://actionpack/7.2.0/lib/action_controller/base.rb#222 + def without_modules(*modules); end + end +end + +module ActionController::Base::HelperMethods + include ::ActionText::ContentHelper + include ::ActionText::TagHelper + include ::Turbo::DriveHelper + include ::Turbo::FramesHelper + include ::Turbo::IncludesHelper + include ::Turbo::StreamsHelper + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::Turbo::Streams::ActionHelper + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#41 + def alert(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching/fragments.rb#34 + def combined_fragment_cache_key(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/action_controller/metal/content_security_policy.rb#13 + def content_security_policy?(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/action_controller/metal/content_security_policy.rb#14 + def content_security_policy_nonce(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/action_controller/metal/cookies.rb#10 + def cookies(*_arg0, **_arg1, &_arg2); end + + # source://devise/4.9.4/lib/devise/controllers/helpers.rb#13 + def devise_controller?(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/action_controller/metal/request_forgery_protection.rb#102 + def form_authenticity_token(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/action_controller/metal/flash.rb#41 + def notice(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/action_controller/metal/request_forgery_protection.rb#103 + def protect_against_forgery?(*_arg0, **_arg1, &_arg2); end + + # source://devise/4.9.4/lib/devise/controllers/helpers.rb#13 + def signed_in?(*_arg0, **_arg1, &_arg2); end + + def turbo_frame_request?(*_arg0, **_arg1, &_arg2); end + def turbo_frame_request_id(*_arg0, **_arg1, &_arg2); end + def turbo_native_app?(*_arg0, **_arg1, &_arg2); end + + # source://actionpack/7.2.0/lib/abstract_controller/caching.rb#45 + def view_cache_dependencies(*_arg0, **_arg1, &_arg2); end + + # source://devise/4.9.4/lib/devise/controllers/helpers.rb#13 + def warden(*_arg0, **_arg1, &_arg2); end +end + +# source://turbo-rails//lib/turbo/engine.rb#3 +module Turbo + extend ::ActiveSupport::Autoload + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#74 + def current_request_id; end + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#116 + def current_request_id=(obj); end + + # source://turbo-rails//lib/turbo-rails.rb#7 + def draw_routes; end + + # source://turbo-rails//lib/turbo-rails.rb#7 + def draw_routes=(val); end + + class << self + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#49 + def current_request_id; end + + # source://activesupport/7.2.0/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb#108 + def current_request_id=(obj); end + + # source://turbo-rails//lib/turbo-rails.rb#7 + def draw_routes; end + + # source://turbo-rails//lib/turbo-rails.rb#7 + def draw_routes=(val); end + + # source://railties/7.2.0/lib/rails/engine.rb#412 + def railtie_helpers_paths; end + + # source://railties/7.2.0/lib/rails/engine.rb#395 + def railtie_namespace; end + + # source://railties/7.2.0/lib/rails/engine.rb#416 + def railtie_routes_url_helpers(include_path_helpers = T.unsafe(nil)); end + + # source://turbo-rails//lib/turbo-rails.rb#14 + def signed_stream_verifier; end + + # source://turbo-rails//lib/turbo-rails.rb#18 + def signed_stream_verifier_key; end + + # Sets the attribute signed_stream_verifier_key + # + # @param value the value to set the attribute signed_stream_verifier_key to. + # + # source://turbo-rails//lib/turbo-rails.rb#12 + def signed_stream_verifier_key=(_arg0); end + + # source://railties/7.2.0/lib/rails/engine.rb#401 + def table_name_prefix; end + + # source://railties/7.2.0/lib/rails/engine.rb#408 + def use_relative_model_naming?; end + + # source://turbo-rails//lib/turbo-rails.rb#22 + def with_request_id(request_id); end + end +end + +module Turbo::Broadcastable + extend ::ActiveSupport::Concern + + mixes_in_class_methods ::Turbo::Broadcastable::ClassMethods + + def broadcast_action(action, target: T.unsafe(nil), attributes: T.unsafe(nil), **rendering); end + def broadcast_action_later(action:, target: T.unsafe(nil), attributes: T.unsafe(nil), **rendering); end + def broadcast_action_later_to(*streamables, action:, target: T.unsafe(nil), attributes: T.unsafe(nil), **rendering); end + def broadcast_action_to(*streamables, action:, target: T.unsafe(nil), attributes: T.unsafe(nil), **rendering); end + def broadcast_after_to(*streamables, target:, **rendering); end + def broadcast_append(target: T.unsafe(nil), **rendering); end + def broadcast_append_later(target: T.unsafe(nil), **rendering); end + def broadcast_append_later_to(*streamables, target: T.unsafe(nil), **rendering); end + def broadcast_append_to(*streamables, target: T.unsafe(nil), **rendering); end + def broadcast_before_to(*streamables, target:, **rendering); end + def broadcast_prepend(target: T.unsafe(nil), **rendering); end + def broadcast_prepend_later(target: T.unsafe(nil), **rendering); end + def broadcast_prepend_later_to(*streamables, target: T.unsafe(nil), **rendering); end + def broadcast_prepend_to(*streamables, target: T.unsafe(nil), **rendering); end + def broadcast_refresh; end + def broadcast_refresh_later; end + def broadcast_refresh_later_to(*streamables); end + def broadcast_refresh_to(*streamables); end + def broadcast_remove; end + def broadcast_remove_to(*streamables, target: T.unsafe(nil)); end + def broadcast_render(**rendering); end + def broadcast_render_later(**rendering); end + def broadcast_render_later_to(*streamables, **rendering); end + def broadcast_render_to(*streamables, **rendering); end + def broadcast_replace(**rendering); end + def broadcast_replace_later(**rendering); end + def broadcast_replace_later_to(*streamables, **rendering); end + def broadcast_replace_to(*streamables, **rendering); end + def broadcast_update(**rendering); end + def broadcast_update_later(**rendering); end + def broadcast_update_later_to(*streamables, **rendering); end + def broadcast_update_to(*streamables, **rendering); end + + private + + def broadcast_rendering_with_defaults(options); end + def broadcast_target_default; end +end + +module Turbo::Broadcastable::ClassMethods + def broadcast_target_default; end + def broadcasts(stream = T.unsafe(nil), inserts_by: T.unsafe(nil), target: T.unsafe(nil), **rendering); end + def broadcasts_refreshes(stream = T.unsafe(nil)); end + def broadcasts_refreshes_to(stream); end + def broadcasts_to(stream, inserts_by: T.unsafe(nil), target: T.unsafe(nil), **rendering); end + def suppressed_turbo_broadcasts?; end + def suppressing_turbo_broadcasts(&block); end +end + +# source://turbo-rails//lib/turbo/broadcastable/test_helper.rb#3 +module Turbo::Broadcastable::TestHelper + extend ::ActiveSupport::Concern + include ::ActionCable::TestHelper + include ::Turbo::Streams::StreamName + + # Asserts that no `` elements were broadcast over Action Cable + # + # ==== Arguments + # + # * stream_name_or_object the objects used to generate the + # channel Action Cable name, or the name itself + # * &block optional block executed before the + # assertion + # + # Asserts that no `` elements were broadcast: + # + # message = Message.find(1) + # message.broadcast_replace_to "messages" + # + # assert_no_turbo_stream_broadcasts "messages" # fails with MiniTest::Assertion error + # + # You can pass a block to run before the assertion: + # + # message = Message.find(1) + # + # assert_no_turbo_stream_broadcasts "messages" do + # # do something other than broadcast to "messages" + # end + # + # In addition to a String, the helper also accepts an Object or Array to + # determine the name of the channel the elements are broadcast to: + # + # message = Message.find(1) + # + # assert_no_turbo_stream_broadcasts message do + # # do something other than broadcast to "message_1" + # end + # + # source://turbo-rails//lib/turbo/broadcastable/test_helper.rb#104 + def assert_no_turbo_stream_broadcasts(stream_name_or_object, &block); end + + # Asserts that `` elements were broadcast over Action Cable + # + # ==== Arguments + # + # * stream_name_or_object the objects used to generate the + # channel Action Cable name, or the name itself + # * &block optional block executed before the + # assertion + # + # ==== Options + # + # * count: the number of `` elements that are + # expected to be broadcast + # + # Asserts `` elements were broadcast: + # + # message = Message.find(1) + # message.broadcast_replace_to "messages" + # + # assert_turbo_stream_broadcasts "messages" + # + # Asserts that two `` elements were broadcast: + # + # message = Message.find(1) + # message.broadcast_replace_to "messages" + # message.broadcast_remove_to "messages" + # + # assert_turbo_stream_broadcasts "messages", count: 2 + # + # You can pass a block to run before the assertion: + # + # message = Message.find(1) + # + # assert_turbo_stream_broadcasts "messages" do + # message.broadcast_append_to "messages" + # end + # + # In addition to a String, the helper also accepts an Object or Array to + # determine the name of the channel the elements are broadcast to: + # + # message = Message.find(1) + # + # assert_turbo_stream_broadcasts message do + # message.broadcast_replace + # end + # + # source://turbo-rails//lib/turbo/broadcastable/test_helper.rb#58 + def assert_turbo_stream_broadcasts(stream_name_or_object, count: T.unsafe(nil), &block); end + + # Captures any `` elements that were broadcast over Action Cable + # + # ==== Arguments + # + # * stream_name_or_object the objects used to generate the + # channel Action Cable name, or the name itself + # * &block optional block to capture broadcasts during execution + # + # Returns any `` elements that have been broadcast as an + # Array of Nokogiri::XML::Element instances + # + # message = Message.find(1) + # message.broadcast_append_to "messages" + # message.broadcast_prepend_to "messages" + # + # turbo_streams = capture_turbo_stream_broadcasts "messages" + # + # assert_equal "append", turbo_streams.first["action"] + # assert_equal "prepend", turbo_streams.second["action"] + # + # You can pass a block to limit the scope of the broadcasts being captured: + # + # message = Message.find(1) + # + # turbo_streams = capture_turbo_stream_broadcasts "messages" do + # message.broadcast_append_to "messages" + # end + # + # assert_equal "append", turbo_streams.first["action"] + # + # In addition to a String, the helper also accepts an Object or Array to + # determine the name of the channel the elements are broadcast to: + # + # message = Message.find(1) + # + # replace, remove = capture_turbo_stream_broadcasts message do + # message.broadcast_replace + # message.broadcast_remove + # end + # + # assert_equal "replace", replace["action"] + # assert_equal "replace", remove["action"] + # + # source://turbo-rails//lib/turbo/broadcastable/test_helper.rb#157 + def capture_turbo_stream_broadcasts(stream_name_or_object, &block); end +end + +class Turbo::Debouncer + def initialize(delay: T.unsafe(nil)); end + + def debounce(&block); end + def delay; end + def scheduled_task; end + def wait; end + + private + + def wait_timeout; end +end + +Turbo::Debouncer::DEFAULT_DELAY = T.let(T.unsafe(nil), Float) + +module Turbo::DriveHelper + def turbo_exempts_page_from_cache; end + def turbo_exempts_page_from_cache_tag; end + def turbo_exempts_page_from_preview; end + def turbo_exempts_page_from_preview_tag; end + def turbo_page_requires_reload; end + def turbo_page_requires_reload_tag; end + def turbo_refresh_method_tag(method = T.unsafe(nil)); end + def turbo_refresh_scroll_tag(scroll = T.unsafe(nil)); end + def turbo_refreshes_with(method: T.unsafe(nil), scroll: T.unsafe(nil)); end +end + +# source://turbo-rails//lib/turbo/engine.rb#4 +class Turbo::Engine < ::Rails::Engine + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end + +# If you don't want to precompile Turbo's assets (eg. because you're using webpack), +# you can do this in an intiailzer: +# +# config.after_initialize do +# config.assets.precompile -= Turbo::Engine::PRECOMPILE_ASSETS +# end +# +# source://turbo-rails//lib/turbo/engine.rb#45 +Turbo::Engine::PRECOMPILE_ASSETS = T.let(T.unsafe(nil), Array) + +module Turbo::Frames; end + +module Turbo::Frames::FrameRequest + extend ::ActiveSupport::Concern + + private + + def turbo_frame_request?; end + def turbo_frame_request_id; end +end + +module Turbo::FramesHelper + def turbo_frame_tag(*ids, src: T.unsafe(nil), target: T.unsafe(nil), **attributes, &block); end +end + +module Turbo::IncludesHelper + def turbo_include_tags; end +end + +module Turbo::Native; end + +module Turbo::Native::Navigation + extend ::ActiveSupport::Concern + + def recede_or_redirect_back_or_to(url, **options); end + def recede_or_redirect_to(url, **options); end + def refresh_or_redirect_back_or_to(url, **options); end + def refresh_or_redirect_to(url, **options); end + def resume_or_redirect_back_or_to(url, **options); end + def resume_or_redirect_to(url, **options); end + def turbo_native_app?; end + + private + + def turbo_native_action_or_redirect(url, action, redirect_type, options = T.unsafe(nil)); end +end + +class Turbo::Native::NavigationController < ::ActionController::Base + def recede; end + def refresh; end + def resume; end + + private + + # source://actionview/7.2.0/lib/action_view/layouts.rb#328 + def _layout(lookup_context, formats); end + + def _layout_from_proc; end + + class << self + # source://actionpack/7.2.0/lib/action_controller/metal.rb#288 + def middleware_stack; end + end +end + +module Turbo::RequestIdTracking + extend ::ActiveSupport::Concern + + private + + def turbo_tracking_request_id(&block); end +end + +module Turbo::Streams; end + +class Turbo::Streams::ActionBroadcastJob < ::ActiveJob::Base + def perform(stream, action:, target:, attributes: T.unsafe(nil), **rendering); end + + class << self + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +module Turbo::Streams::ActionHelper + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + + def turbo_stream_action_tag(action, target: T.unsafe(nil), targets: T.unsafe(nil), template: T.unsafe(nil), **attributes); end + def turbo_stream_refresh_tag(request_id: T.unsafe(nil), **attributes); end + + private + + def convert_to_turbo_stream_dom_id(target, include_selector: T.unsafe(nil)); end +end + +class Turbo::Streams::BroadcastJob < ::ActiveJob::Base + def perform(stream, **rendering); end + + class << self + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +class Turbo::Streams::BroadcastStreamJob < ::ActiveJob::Base + def perform(stream, content:); end + + class << self + # source://activesupport/7.2.0/lib/active_support/rescuable.rb#15 + def rescue_handlers; end + end +end + +module Turbo::Streams::Broadcasts + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::Turbo::Streams::ActionHelper + + def broadcast_action_later_to(*streamables, action:, target: T.unsafe(nil), targets: T.unsafe(nil), attributes: T.unsafe(nil), **rendering); end + def broadcast_action_to(*streamables, action:, target: T.unsafe(nil), targets: T.unsafe(nil), attributes: T.unsafe(nil), **rendering); end + def broadcast_after_later_to(*streamables, **opts); end + def broadcast_after_to(*streamables, **opts); end + def broadcast_append_later_to(*streamables, **opts); end + def broadcast_append_to(*streamables, **opts); end + def broadcast_before_later_to(*streamables, **opts); end + def broadcast_before_to(*streamables, **opts); end + def broadcast_prepend_later_to(*streamables, **opts); end + def broadcast_prepend_to(*streamables, **opts); end + def broadcast_refresh_later_to(*streamables, request_id: T.unsafe(nil), **opts); end + def broadcast_refresh_to(*streamables, **opts); end + def broadcast_remove_to(*streamables, **opts); end + def broadcast_render_later_to(*streamables, **rendering); end + def broadcast_render_to(*streamables, **rendering); end + def broadcast_replace_later_to(*streamables, **opts); end + def broadcast_replace_to(*streamables, **opts); end + def broadcast_stream_to(*streamables, content:); end + def broadcast_update_later_to(*streamables, **opts); end + def broadcast_update_to(*streamables, **opts); end + def refresh_debouncer_for(*streamables, request_id: T.unsafe(nil)); end + + private + + def render_format(format, **rendering); end +end + +module Turbo::Streams::StreamName + def signed_stream_name(streamables); end + def verified_stream_name(signed_stream_name); end + + private + + def stream_name_from(streamables); end +end + +module Turbo::Streams::StreamName::ClassMethods + def verified_stream_name_from_params; end +end + +class Turbo::Streams::TagBuilder + include ::ActionView::Helpers::CaptureHelper + include ::ActionView::Helpers::OutputSafetyHelper + include ::ActionView::Helpers::TagHelper + include ::Turbo::Streams::ActionHelper + + def initialize(view_context); end + + def action(name, target, content = T.unsafe(nil), allow_inferred_rendering: T.unsafe(nil), **rendering, &block); end + def action_all(name, targets, content = T.unsafe(nil), allow_inferred_rendering: T.unsafe(nil), **rendering, &block); end + def after(target, content = T.unsafe(nil), **rendering, &block); end + def after_all(targets, content = T.unsafe(nil), **rendering, &block); end + def append(target, content = T.unsafe(nil), **rendering, &block); end + def append_all(targets, content = T.unsafe(nil), **rendering, &block); end + def before(target, content = T.unsafe(nil), **rendering, &block); end + def before_all(targets, content = T.unsafe(nil), **rendering, &block); end + def morph(target, content = T.unsafe(nil), **rendering, &block); end + def morph_all(targets, content = T.unsafe(nil), **rendering, &block); end + def prepend(target, content = T.unsafe(nil), **rendering, &block); end + def prepend_all(targets, content = T.unsafe(nil), **rendering, &block); end + def remove(target); end + def remove_all(targets); end + def replace(target, content = T.unsafe(nil), **rendering, &block); end + def replace_all(targets, content = T.unsafe(nil), **rendering, &block); end + def update(target, content = T.unsafe(nil), **rendering, &block); end + def update_all(targets, content = T.unsafe(nil), **rendering, &block); end + + private + + def render_record(possible_record); end + def render_template(target, content = T.unsafe(nil), allow_inferred_rendering: T.unsafe(nil), **rendering, &block); end +end + +module Turbo::Streams::TurboStreamsTagBuilder + private + + def turbo_stream; end +end + +class Turbo::StreamsChannel < ::ActionCable::Channel::Base + include ::Turbo::Streams::StreamName::ClassMethods + extend ::Turbo::Streams::StreamName + extend ::ActionView::Helpers::CaptureHelper + extend ::ActionView::Helpers::OutputSafetyHelper + extend ::ActionView::Helpers::TagHelper + extend ::Turbo::Streams::ActionHelper + extend ::Turbo::Streams::Broadcasts + + def subscribed; end + + class << self + # source://activesupport/7.2.0/lib/active_support/callbacks.rb#70 + def __callbacks; end + end +end + +module Turbo::StreamsHelper + def turbo_stream; end + def turbo_stream_from(*streamables, **attributes); end +end + +# source://turbo-rails//lib/turbo/test_assertions.rb#2 +module Turbo::TestAssertions + extend ::ActiveSupport::Concern + + # Assert that the rendered fragment of HTML does not contain a `` + # element. + # + # ==== Options + # + # * :action [String] matches the element's [action] + # attribute + # * :target [String, #to_key] matches the element's + # [target] attribute. If the value responds to #to_key, + # the value will be transformed by calling dom_id + # * :targets [String] matches the element's [targets] + # attribute + # + # Given the following HTML fragment: + # + # + # + # The following assertion would fail: + # + # assert_no_turbo_stream action: "remove", target: "message_1" + # + # source://turbo-rails//lib/turbo/test_assertions.rb#76 + def assert_no_turbo_stream(action:, target: T.unsafe(nil), targets: T.unsafe(nil)); end + + # Assert that the rendered fragment of HTML contains a `` + # element. + # + # ==== Options + # + # * :action [String] matches the element's [action] + # attribute + # * :target [String, #to_key] matches the element's + # [target] attribute. If the value responds to #to_key, + # the value will be transformed by calling dom_id + # * :targets [String] matches the element's [targets] + # attribute + # * :count [Integer] indicates how many turbo streams are expected. + # Defaults to 1. + # + # Given the following HTML fragment: + # + # + # + # The following assertion would pass: + # + # assert_turbo_stream action: "remove", target: "message_1" + # + # You can also pass a block make assertions about the contents of the + # element. Given the following HTML fragment: + # + # + #